Apply color theme to HTML page itself (#2132)

This commit is contained in:
Eric Bailey
2023-12-07 13:00:44 -06:00
committed by GitHub
parent 17c27581b6
commit cdc1d08267
3 changed files with 3 additions and 0 deletions
+1
View File
@@ -71,6 +71,7 @@
overflow-y: auto;
overscroll-behavior-y: none;
text-rendering: optimizeLegibility;
background-color: var(--background);
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
-ms-overflow-style: scrollbar;
+1
View File
@@ -23,6 +23,7 @@ export function Provider({children}: React.PropsWithChildren<{}>) {
)
React.useEffect(() => {
updateDocument(persisted.get('colorMode')) // set on load
return persisted.onUpdate(() => {
setState(persisted.get('colorMode'))
updateDocument(persisted.get('colorMode'))
+1
View File
@@ -75,6 +75,7 @@
overflow-y: auto;
overscroll-behavior-y: none;
text-rendering: optimizeLegibility;
background-color: var(--background);
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
-ms-overflow-style: scrollbar;