mirror of
https://github.com/excalidraw/excalidraw.git
synced 2025-05-03 10:00:07 -04:00
feat: add system mode to the theme selector (#7853)
Co-authored-by: dwelle <5153846+dwelle@users.noreply.github.com>
This commit is contained in:
parent
92bc08207c
commit
cd50aa719f
21 changed files with 301 additions and 56 deletions
|
@ -1014,7 +1014,7 @@ class App extends React.Component<AppProps, AppState> {
|
|||
width: 100%;
|
||||
height: 100%;
|
||||
color: ${
|
||||
this.state.theme === "dark" ? "white" : "black"
|
||||
this.state.theme === THEME.DARK ? "white" : "black"
|
||||
};
|
||||
}
|
||||
body {
|
||||
|
@ -1281,7 +1281,7 @@ class App extends React.Component<AppProps, AppState> {
|
|||
return null;
|
||||
}
|
||||
|
||||
const isDarkTheme = this.state.theme === "dark";
|
||||
const isDarkTheme = this.state.theme === THEME.DARK;
|
||||
|
||||
let frameIndex = 0;
|
||||
let magicFrameIndex = 0;
|
||||
|
@ -2730,7 +2730,7 @@ class App extends React.Component<AppProps, AppState> {
|
|||
|
||||
this.excalidrawContainerRef.current?.classList.toggle(
|
||||
"theme--dark",
|
||||
this.state.theme === "dark",
|
||||
this.state.theme === THEME.DARK,
|
||||
);
|
||||
|
||||
if (
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue