mirror of
https://github.com/jakejarvis/jarv.is.git
synced 2025-07-03 17:46:39 -04:00
fix style regressions (code was never actually using Hack font I think..?)
and allow default theme (light or dark) to be set in Hugo config and reflected in both HTML & JS
This commit is contained in:
@ -17,7 +17,8 @@
|
||||
var light = "light";
|
||||
|
||||
// which class is <body> set to initially?
|
||||
var default_theme = light;
|
||||
// eslint-disable-next-line
|
||||
var default_theme = "{{ .Site.Params.defaultTheme }}";
|
||||
|
||||
// use an element with class `dark-mode-toggle` to trigger swap when clicked
|
||||
var toggle = doc.querySelector(".dark-mode-toggle");
|
||||
|
Reference in New Issue
Block a user