windicss / windicss-analysis

🔍 A visual analyzer for Windi CSS

Home Page:https://analysis-demo.windicss.org

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

[STYLE] improve code block

alexanderniebuhr opened this issue · comments

it's prism code block, so style set. But should make it more dynamic to match VS Code themes, somehow. (dark theme with white code block, is bad for eyes at night)

Bildschirmfoto 2021-03-30 um 17 11 57

Use this to check the theme and rewrite <html class="dark"> when serving the HTML

https://antfu.me/notes#color-scheme-for-vs-code-extensions

It actually does not work that way.. if i set it, it is set in HTML, but on load it is switched back to light mode. Is it because the vue darkMode button switch overrides it on load?

Try injecting script

localStorage.setItem('vueuse-color-scheme', 'dark' | 'light')