Add dark mode (#199)
* Add passive dark mode to everything but codemirror * Add dark theme support for Codemirror * Make theme a user setting * Fix button text size * guard against undefined window * Formatting and test fix
This commit is contained in:
@ -18,6 +18,10 @@
|
||||
height: calc(var(--toggle-size) + var(--padding));
|
||||
}
|
||||
|
||||
:global(.dark) .toggle > span {
|
||||
@apply border-chalkboard-40;
|
||||
}
|
||||
|
||||
.toggle > span::after {
|
||||
content: '';
|
||||
@apply absolute w-4 h-4 rounded-sm bg-chalkboard-110;
|
||||
@ -27,6 +31,10 @@
|
||||
transition: translate 0.08s ease-out;
|
||||
}
|
||||
|
||||
:global(.dark) .toggle > span::after {
|
||||
@apply bg-chalkboard-10;
|
||||
}
|
||||
|
||||
.toggle input:checked + span::after {
|
||||
translate: calc(50% - var(--padding)) -50%;
|
||||
}
|
||||
|
Reference in New Issue
Block a user