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

Use system theme by default #18203

Closed
Palid opened this issue Jul 23, 2021 · 11 comments
Closed

Use system theme by default #18203

Palid opened this issue Jul 23, 2021 · 11 comments
Labels
A-Developer-Experience A-Themes-Official Official themes (light, dark) A-User-Settings O-Uncommon Most users are unlikely to come across this or unexpected workflow S-Tolerable Low/no impact on users T-Defect

Comments

@Palid
Copy link
Contributor

Palid commented Jul 23, 2021

Currently the web client doesn't use system theme by default upon first login, which, for dark theme users, can end up in a very unpleasant flash of white in their eyes.

@t3chguy
Copy link
Member

t3chguy commented Jul 23, 2021

@t3chguy
Copy link
Member

t3chguy commented Jul 23, 2021

Is this just a duplicate of #4895 ?

the OP is unclear on when/what this white flash is. Proper repro steps/screenshot/gif would be appreciated.

@t3chguy t3chguy added the X-Needs-Info This issue is blocked awaiting information from the reporter label Jul 23, 2021
@Palid
Copy link
Contributor Author

Palid commented Jul 23, 2021

@t3chguy could be, did a quick search and didn't find in issues. Will provide reproduction steps shortly.

@ShadowJonathan
Copy link
Contributor

I've also had such a "white flash", often when I preview netifly builds, I have to log into my own account, which has dark mode set always-on.

When the main interface is loading, it's set to default to white theme before loading in my preferences and switching to dark mode. I'm gonna guess this is related to what happens with the system-decided theme, where the main interface loads before the preferences kick in.

@Palid
Copy link
Contributor Author

Palid commented Jul 23, 2021

That's weird, I have 100% reproducability on dev env, but can't reproduce it on production. Sounds very much like some kind of a race condition, exactly like @ShadowJonathan described.

@ShadowJonathan
Copy link
Contributor

I think it's safe to assume that this is a side-effect of using a developer environment, where it may need to load extra resources (maps and debug symbols) before it can properly execute. @Palid you said you didn't get this when using a production environment, can you confirm that? Then I think this issue can be considered solved, as the (minor) issue only pertains to dev environments.

@Palid
Copy link
Contributor Author

Palid commented Aug 1, 2021

I'll test that on RC on monday too. If that's only a problem for dev indeed then I think we can try figuring it out after hot reload for css gets merged in.

@SimonBrandner SimonBrandner added Help Wanted Extra attention is needed and removed Z-Bite-Sized Help Wanted Extra attention is needed labels Aug 27, 2021
@SimonBrandner
Copy link
Contributor

@Palid, what is the status on this?

@Palid
Copy link
Contributor Author

Palid commented Aug 27, 2021

I think it's more DX at this point, so it'd be nice to figure out but nothing super important.

@Palid Palid added A-Developer-Experience O-Uncommon Most users are unlikely to come across this or unexpected workflow S-Tolerable Low/no impact on users and removed X-Needs-Info This issue is blocked awaiting information from the reporter labels Aug 27, 2021
@Palid
Copy link
Contributor Author

Palid commented Aug 27, 2021

@SimonBrandner basically to make this better we'd need to rewrite a chunk of how we load styles and change themes, which isn't really that hard, but requires figuring it out; from what I can say now is that we'd definitely prefer a way to add new css DOM elements on theme change instead of just enabling/disabling those, but it also requires tiny webpack changes.

@kittykat
Copy link
Contributor

I'm closing this in favour of #4895 as it sounds like the same problem. Please reopen and update issue description if you feel that it isn't.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-Developer-Experience A-Themes-Official Official themes (light, dark) A-User-Settings O-Uncommon Most users are unlikely to come across this or unexpected workflow S-Tolerable Low/no impact on users T-Defect
Projects
None yet
Development

No branches or pull requests

6 participants