feat: add system mode to the theme selector (#7853)

Co-authored-by: dwelle <5153846+dwelle@users.noreply.github.com>
This commit is contained in:
Arnost Pleskot
2024-04-08 16:46:24 +02:00
committed by GitHub
co-authored by dwelle
parent 92bc08207c
commit cd50aa719f
21 changed files with 301 additions and 56 deletions
+2 -1
View File
@@ -19,6 +19,7 @@ import {
FONT_FAMILY,
FRAME_STYLE,
SVG_NS,
THEME,
THEME_FILTER,
} from "../constants";
import { getDefaultAppState } from "../appState";
@@ -237,7 +238,7 @@ export const exportToCanvas = async (
scrollY: -minY + exportPadding,
zoom: defaultAppState.zoom,
shouldCacheIgnoreZoom: false,
theme: appState.exportWithDarkMode ? "dark" : "light",
theme: appState.exportWithDarkMode ? THEME.DARK : THEME.LIGHT,
},
renderConfig: {
canvasBackgroundColor: viewBackgroundColor,