mirror of
https://github.com/13hannes11/hugo-coder-timeline.git
synced 2024-09-04 00:50:58 +02:00
fix word (#507)
* fix word * Update CONTRIBUTORS.md add @tianheg (my name)
This commit is contained in:
@@ -88,6 +88,7 @@
|
|||||||
- [Arafat Hasan](https://github.com/arafat-hasan)
|
- [Arafat Hasan](https://github.com/arafat-hasan)
|
||||||
- [YUJI](https://yuji.ne.jp/)
|
- [YUJI](https://yuji.ne.jp/)
|
||||||
- [JaeSang Yoo](https://github.com/JSYoo5B)
|
- [JaeSang Yoo](https://github.com/JSYoo5B)
|
||||||
|
- [tianheg](https://github.com/tianheg)
|
||||||
- [Felix](https://github.com/lazyyz)
|
- [Felix](https://github.com/lazyyz)
|
||||||
- [Peter Duchnovsky](https://pduchnovsky.com)
|
- [Peter Duchnovsky](https://pduchnovsky.com)
|
||||||
- [Alex Miranda](https://ammiranda.com)
|
- [Alex Miranda](https://ammiranda.com)
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ const body = document.body;
|
|||||||
const darkModeToggle = document.getElementById('dark-mode-toggle');
|
const darkModeToggle = document.getElementById('dark-mode-toggle');
|
||||||
const darkModeMediaQuery = window.matchMedia('(prefers-color-scheme: dark)');
|
const darkModeMediaQuery = window.matchMedia('(prefers-color-scheme: dark)');
|
||||||
|
|
||||||
// Check if user preference is set, if not check value of body class for light or dark else it means that colorsheme = auto
|
// Check if user preference is set, if not check value of body class for light or dark else it means that colorscheme = auto
|
||||||
if (localStorage.getItem("colorscheme")) {
|
if (localStorage.getItem("colorscheme")) {
|
||||||
setTheme(localStorage.getItem("colorscheme"));
|
setTheme(localStorage.getItem("colorscheme"));
|
||||||
} else if (body.classList.contains('colorscheme-light') || body.classList.contains('colorscheme-dark')) {
|
} else if (body.classList.contains('colorscheme-light') || body.classList.contains('colorscheme-dark')) {
|
||||||
|
|||||||
Reference in New Issue
Block a user