diff --git a/solara/server/templates/solara.html.j2 b/solara/server/templates/solara.html.j2 index c858800a9..f8c6b8f9b 100644 --- a/solara/server/templates/solara.html.j2 +++ b/solara/server/templates/solara.html.j2 @@ -252,6 +252,11 @@ window.matchMedia('(prefers-color-scheme: dark)').addEventListener('change', event => { this.$vuetify.theme.dark = inDarkMode(); }); + if (this.$vuetify.theme.dark) { + this.changeThemeCSS('dark'); + } else { + this.changeThemeCSS('light'); + } }, methods: { stateReset() {