Skip to content

Commit

Permalink
disable light mode
Browse files Browse the repository at this point in the history
  • Loading branch information
m-krebs authored Dec 11, 2024
1 parent ffd1dd9 commit ba250a4
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/app.html
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,11 @@
<script>
try {
if (!("theme" in localStorage)) {
// TODO: #39 allow only dark mode as light mode isn't finished
localStorage.theme = window.matchMedia("(prefers-color-scheme: dark)")
.matches
? "dark"
: "light";
: "dark";
}
document.querySelector("html").classList.add(localStorage.theme);
} catch (error) {
Expand Down

0 comments on commit ba250a4

Please sign in to comment.