From 2475467dd058516699689d226292b0de3b0ee47e Mon Sep 17 00:00:00 2001
From: Meru Patel <2017180@iiitdmj.ac.in>
Date: Wed, 12 Sep 2018 10:30:29 +0530
Subject: [PATCH] Fixes #677
---
client/modules/IDE/components/Console.jsx | 12 ++++++++++--
client/modules/IDE/components/Preferences.jsx | 2 ++
client/modules/IDE/pages/IDEView.jsx | 1 +
3 files changed, 13 insertions(+), 2 deletions(-)
diff --git a/client/modules/IDE/components/Console.jsx b/client/modules/IDE/components/Console.jsx
index 4f394f13..bc2e0d5d 100644
--- a/client/modules/IDE/components/Console.jsx
+++ b/client/modules/IDE/components/Console.jsx
@@ -23,6 +23,11 @@ class Console extends React.Component {
this.props.clearConsole();
this.props.dispatchConsoleEvent(this.props.consoleEvents);
}
+
+ if(this.props.consoleFontSize !== prevProps.consoleFontSize){
+ this.props.clearConsole();
+ this.props.dispatchConsoleEvent(this.props.consoleEvents);
+ }
}
getConsoleFeedStyle(theme, times) {
@@ -31,13 +36,16 @@ class Console extends React.Component {
LOG_WARN_ICON: `url(${warnLightUrl})`,
LOG_ERROR_ICON: `url(${errorLightUrl})`,
LOG_DEBUG_ICON: `url(${debugLightUrl})`,
- LOG_INFO_ICON: `url(${infoLightUrl})`
+ LOG_INFO_ICON: `url(${infoLightUrl})`,
+ BASE_FONT_SIZE: `${this.props.consoleFontSize}`
};
const CONSOLE_FEED_DARK_ICONS = {
LOG_WARN_ICON: `url(${warnDarkUrl})`,
LOG_ERROR_ICON: `url(${errorDarkUrl})`,
LOG_DEBUG_ICON: `url(${debugDarkUrl})`,
- LOG_INFO_ICON: `url(${infoDarkUrl})`
+ LOG_INFO_ICON: `url(${infoDarkUrl})`,
+ BASE_FONT_SIZE: `${this.props.consoleFontSize}`
+
};
if (times > 1) {
Object.assign(style, CONSOLE_FEED_WITHOUT_ICONS);
diff --git a/client/modules/IDE/components/Preferences.jsx b/client/modules/IDE/components/Preferences.jsx
index 2f7b2b0b..130d2745 100644
--- a/client/modules/IDE/components/Preferences.jsx
+++ b/client/modules/IDE/components/Preferences.jsx
@@ -131,6 +131,7 @@ class Preferences extends React.Component {