We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 419a907 commit 8eab7b1Copy full SHA for 8eab7b1
src/App.tsx
@@ -18,6 +18,20 @@ function App() {
18
setSelectedTheme(theme);
19
}, [themeLoaded]);
20
21
+ useEffect(() => {
22
+ if (document) {
23
+ document!
24
+ .querySelector('meta[name="theme-color"]')!
25
+ .setAttribute("content", theme.colors.body);
26
27
+ .querySelector('meta[name="msapplication-TileColor"]')!
28
29
30
+ .querySelector('link[rel="mask-icon"]')!
31
+ .setAttribute("color", theme.colors.body);
32
+ }
33
+ }, [selectedTheme]);
34
+
35
const themeSwitcher = (switchTheme: Theme) => {
36
setSelectedTheme(switchTheme);
37
setMode(switchTheme);
0 commit comments