Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Consider more dynamic light/dark mode handling #61

Closed
AttemptToCallNil opened this issue Apr 22, 2021 · 2 comments
Closed

Consider more dynamic light/dark mode handling #61

AttemptToCallNil opened this issue Apr 22, 2021 · 2 comments
Labels
enhancement New feature or request

Comments

@AttemptToCallNil
Copy link
Contributor

Currently using light or dark mode is determined once, when MAGE starts up. It's also hard-bound to the light/dark setting of the OS. I'm not sure this is even possible, but if it is, a more advanced approach might have some advantages. Defaulting to the OS mode with the ability to switch modes at runtime will let people specifically use a mode not configured for their OS (in case they have MAGE-specific mode preferences), but (arguably, more importantly) this could seriously simplify light/dark mode testing for developers. Right now I'd have to close MAGE and re-run pnpm run electron:serve whenever I want to test MAGE with a different mode.

@RheingoldRiver RheingoldRiver added the enhancement New feature or request label Apr 22, 2021
@Helcostr
Copy link
Member

Helcostr commented Apr 23, 2021

Here is what I'm thinking

https://github.com/justjavac/is-dark-theme

Use this package to auto detect (hopefully it works cross platform), then save the variable. Any future changes to OS shouldn't matter, as the initial launch has happen and we are using a variable inside the application to control light/dark.

@AttemptToCallNil
Copy link
Contributor Author

Hm, yeah, that might work

AttemptToCallNil added a commit to AttemptToCallNil/MAGE that referenced this issue Jun 14, 2021
@pcjcos pcjcos closed this as completed in 95a2fdb Jun 14, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants