From 011f25dc4f0654385986ccf3b08c7158461aa0c3 Mon Sep 17 00:00:00 2001 From: Mike Fix Date: Fri, 19 Apr 2019 14:42:00 -0700 Subject: [PATCH] bug fix for creating custom themes --- components/Carbon.js | 2 +- components/Editor.js | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/components/Carbon.js b/components/Carbon.js index a4057e9..fed2446 100644 --- a/components/Carbon.js +++ b/components/Carbon.js @@ -93,7 +93,7 @@ class Carbon extends React.PureComponent { (this.props.config.backgroundImage && this.props.config.backgroundImageSelection) || this.props.config.backgroundImage - const themeConfig = THEMES_HASH[config.theme] + const themeConfig = this.props.theme || THEMES_HASH[config.theme] const content = (
diff --git a/components/Editor.js b/components/Editor.js index 46d436b..02cd3cd 100644 --- a/components/Editor.js +++ b/components/Editor.js @@ -379,6 +379,7 @@ class Editor extends React.Component { config={this.state} onChange={this.updateCode} loading={this.state.loading} + theme={theme} > {code != null ? code : DEFAULT_CODE}