-
Notifications
You must be signed in to change notification settings - Fork 2k
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
[experiment] Allow users to use system's appearance (dark / light) mode #3703
base: main
Are you sure you want to change the base?
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
1 Ignored Deployment
|
this is sick 🎸 |
From a UX perspective I'm in agreement, great feature! Adding @ds300 as a reviewer here just to be sure that the user preferences stuff is compatible. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
great improvement! i think the inferDarkMode
behaviour was a little broken by this but should be easy enough to fix. happy to merge after 🙇🏼
case 'system': | ||
return this.systemColorScheme.get() === 'dark' | ||
default: | ||
return this.inferDarkMode ? this.systemColorScheme.get() === 'dark' : false |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
as mentioned elsewhere, inferDarkMode
will only be respected when colorScheme
is undefined, but at the moment that can't happen without the sdk user explicitly setting it to undefined
because our default user preferences sets it to 'light'
Co-authored-by: David Sheldrick <d.j.sheldrick@gmail.com>
24e4e52
to
5bcb803
Compare
Yeah, nice catch. Updated with your recommendation and brought it up to date. |
Allow the users to fully use the same colour scheme as their system. Allows the users to either: force dark colour scheme, force light colour scheme, or use the system one.
It's reactive to the system changes.
CleanShot.2024-05-06.at.17.28.27.mp4
Change Type
sdk
— Changes the tldraw SDKdotcom
— Changes the tldraw.com web appdocs
— Changes to the documentation, examples, or templates.vs code
— Changes to the vscode plugininternal
— Does not affect user-facing stuffbugfix
— Bug fixfeature
— New featureimprovement
— Improving existing featureschore
— Updating dependencies, other boring stuffgalaxy brain
— Architectural changestests
— Changes to any test codetools
— Changes to infrastructure, CI, internal scripts, debugging tools, etc.dunno
— I don't knowTest Plan
Release Notes