mirror of
https://github.com/john-okeefe/foliate-js.git
synced 2026-10-24 22:59:51 -04:00
Improve invertibility
- Don't use multiply - Set background on separate div
This commit is contained in:
1 parent
2c452719d0
commit
99624d013a
2 files changed
+13
-7
No files matched your search
@@ -10,11 +10,6 @@ export class Overlayer {
|
||||
width: '100%', height: '100%',
|
||||
pointerEvents: 'none',
|
||||
})
|
||||
const darkMode = matchMedia('(prefers-color-scheme: dark)')
|
||||
const setBlendMode = () => this.#svg.style.mixBlendMode =
|
||||
darkMode.matches ? 'normal' : 'multiply'
|
||||
darkMode.addEventListener('change', setBlendMode)
|
||||
setBlendMode()
|
||||
}
|
||||
get element() {
|
||||
return this.#svg
|
||||
|
||||
Reference in new issue
Block a user