From 44248cb4eb0839a111e9f5db91c96b707d76d78e Mon Sep 17 00:00:00 2001 From: "Thomas F. K. Jorna" Date: Fri, 23 Jul 2021 16:38:14 +0200 Subject: add orphan toggle --- pages/_app.tsx | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'pages/_app.tsx') diff --git a/pages/_app.tsx b/pages/_app.tsx index 262ac69..68ac321 100644 --- a/pages/_app.tsx +++ b/pages/_app.tsx @@ -38,16 +38,14 @@ function MyApp({ Component, pageProps }: AppProps) { trackTheme.addEventListener('message', (e) => { const themeData = JSON.parse(e.data) setEmacsTheme(themeData) - console.log(themeData) - console.log(themeData['fg-alt']) }) }, []) - const borderColor = emacsTheme.violet + 'aa' - const theme = + const theme = useMemo(() => { //useMemo(() => { //console.log("theme change") - extendTheme({ + const borderColor = emacsTheme.violet + 'aa' + return extendTheme({ colors: { white: emacsTheme.bg, black: emacsTheme.fg, @@ -97,6 +95,7 @@ function MyApp({ Component, pageProps }: AppProps) { outline: '0 0 0 3px ' + borderColor, }, }) + }, [JSON.stringify(emacsTheme)]) // }, [emacsTheme.base1]) return ( -- cgit v1.2.3