mirror of https://github.com/dirtbags/moth.git
handle prefers-reduced-motion
This commit is contained in:
parent
cc74318e15
commit
0696e7c61c
|
@ -55,6 +55,11 @@ canvas.wallpaper {
|
|||
opacity: 0.2;
|
||||
image-rendering: pixelated;
|
||||
}
|
||||
@media (prefers-reduced-motion) {
|
||||
canvas.wallpaper {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
main {
|
||||
max-width: 40em;
|
||||
margin: 1em auto;
|
||||
|
|
|
@ -92,7 +92,6 @@ export class Workspace {
|
|||
this.runButton.addEventListener("click", () => this.run())
|
||||
this.revertButton.addEventListener("click", () => this.revert())
|
||||
this.fontButton.addEventListener("click", () => this.font())
|
||||
|
||||
}
|
||||
|
||||
initLanguage(language) {
|
||||
|
@ -229,7 +228,7 @@ export class Workspace {
|
|||
}
|
||||
}
|
||||
|
||||
font(force) {
|
||||
this.element.classList.toggle("fixed", force)
|
||||
font() {
|
||||
this.element.classList.toggle("fixed")
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue