Detect and match system dark mode as default theme

This commit is contained in:
Reckless_Satoshi 2022-08-15 04:00:16 -07:00
parent 4152e54430
commit cc3ec7ac65
No known key found for this signature in database
GPG Key ID: 9C4585B561315571

View File

@ -18,7 +18,7 @@ export default class App extends Component {
constructor(props) {
super(props);
this.state = {
dark: false,
dark: window.matchMedia && window.matchMedia('(prefers-color-scheme: dark)').matches,
openLearn: false,
}
}