We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 09b135d commit ded0e41Copy full SHA for ded0e41
src/theme/book.js
@@ -360,13 +360,13 @@ function playground_text(playground, hidden = true) {
360
}
361
362
var previousTheme = get_theme();
363
-
+ var themeId = theme.replace(/\W+/g, '_').toLowerCase();
364
if (store) {
365
- try { localStorage.setItem('mdbook-theme', theme); } catch (e) { }
+ try { localStorage.setItem('mdbook-theme', themeId); } catch (e) { }
366
367
368
html.classList.remove(previousTheme);
369
- html.classList.add(theme);
+ html.classList.add(themeId);
370
updateThemeSelected();
371
372
0 commit comments