diff options
author | Paul Duncan <pabs@pablotron.org> | 2025-04-01 00:39:09 -0400 |
---|---|---|
committer | Paul Duncan <pabs@pablotron.org> | 2025-04-01 00:39:09 -0400 |
commit | d7b1c6b124fe8ea9bc159da62ddbf7139c13558f (patch) | |
tree | fd20fa0c0dd0cd4b01cc4cfa7575ebc673c917b7 | |
parent | b0f57851570b3229b034eb0f2e05ebdf67bbf0e6 (diff) | |
download | pablotron.org-d7b1c6b124fe8ea9bc159da62ddbf7139c13558f.tar.xz pablotron.org-d7b1c6b124fe8ea9bc159da62ddbf7139c13558f.zip |
themes/hugo-pt2021/assets/script.js: shrink, update comments
-rw-r--r-- | themes/hugo-pt2021/assets/script.js | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/themes/hugo-pt2021/assets/script.js b/themes/hugo-pt2021/assets/script.js index 8eb527c..1ab4045 100644 --- a/themes/hugo-pt2021/assets/script.js +++ b/themes/hugo-pt2021/assets/script.js @@ -6,18 +6,18 @@ // - set theme on page load // - bind theme switcher and burger menu event handlers // +// current sizes (2025-04-01): +// - minified: 699 bytes +// - minified/compressed: 508 bytes +// +// notes below are slightly out of date... +// // theme switcher (2024-05-27) // --------------------------- // does the following: // // 1. checks for user setting and use that, if present. -// 2. otherwise check browser for preferred color scheme and use that. -// -// this works in conjunction with the styles in `assets/dark.sass` and -// has one minor quirk: there is a brief flash when the user transitions -// to a new page and has dark mode enabled. this can be removed by -// uncommenting the block at the top of `dark.sass`, but doing this -// currently breaks the light color scheme :/. +// 2. otherwise default to dark mode. // // refs: // https://developer.mozilla.org/en-US/docs/Web/CSS/@media/prefers-color-scheme |