From e5696dc489403c2970c733e9ba914f5d48717f52 Mon Sep 17 00:00:00 2001 From: Tom Coleman Date: Tue, 5 Mar 2019 11:27:24 +1100 Subject: [PATCH] Ensure the theme is insta-loaded from local storage --- lib/ui/src/core/layout.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/ui/src/core/layout.js b/lib/ui/src/core/layout.js index 51d6bef0b530..52b9dd5c701b 100644 --- a/lib/ui/src/core/layout.js +++ b/lib/ui/src/core/layout.js @@ -174,7 +174,7 @@ export default function({ store }) { }, }; - const fromState = pick(store.getState(), 'layout', 'ui', 'selectedPanel'); + const fromState = pick(store.getState(), 'layout', 'ui', 'selectedPanel', 'theme'); const initial = { ui: { @@ -192,7 +192,7 @@ export default function({ store }) { theme: themes.light, }; - const state = merge(fromState, initial); + const state = merge(initial, fromState); return { api, state }; }