Blazorise icon indicating copy to clipboard operation
Blazorise copied to clipboard

global dark mode

Open drma-tech opened this issue 10 months ago • 3 comments

<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 avatar Mar 05 '25 15:03 drma-tech

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.

stsrki avatar Mar 05 '25 16:03 stsrki

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 avatar Mar 05 '25 17:03 drma-tech

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.

drma-tech avatar Mar 16 '25 15:03 drma-tech