Skip to content

global dark mode #6002

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

Open
drma-tech opened this issue Mar 5, 2025 · 3 comments
Open

global dark mode #6002

drma-tech opened this issue Mar 5, 2025 · 3 comments
Labels
Type: Feature ⚙ Request or idea for a new feature.

Comments

@drma-tech
Copy link

<html lang="en" data-bs-theme="dark">

I recently discovered that the latest Bootstrap has the feature of activating dark mode in all components automatically.
I looked in the Blazorise documentation and didn't see anything similar (only if you manually define colors for all components separately).

There could be something similar in the ThemeProvider or something else. I don't know if other themes (besides Bootstrap) offer this.

@drma-tech drma-tech added the Type: Feature ⚙ Request or idea for a new feature. label Mar 5, 2025
@stsrki
Copy link
Collaborator

stsrki commented Mar 5, 2025

It's a feature specific to Bootstrap. Or that is, the way it is applied to the HTML tag element. So it wouldn't make sense to abstract it for other CSS frameworks, as they work differently for dark mode.

@drma-tech
Copy link
Author

but the components already have native properties such as: Background, Theme Contrast, etc. so in practice it would be possible to do it.

@drma-tech
Copy link
Author

I researched the others. All of them, with one exception, have native support for dark mode.
But all of them can be activated with javascript and/or some css. I don't see how difficult it would be to make this happen.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Feature ⚙ Request or idea for a new feature.
Projects
None yet
Development

No branches or pull requests

2 participants