mirror of
https://akkoma.dev/AkkomaGang/akkoma-fe.git
synced 2024-11-08 17:39:09 +00:00
Simplified and fixed and/or oopsie
This commit is contained in:
parent
e2125c57d6
commit
91eab22d77
1 changed files with 2 additions and 6 deletions
|
@ -11,17 +11,13 @@ const StillImage = {
|
||||||
],
|
],
|
||||||
data () {
|
data () {
|
||||||
return {
|
return {
|
||||||
stopGifs: this.$store.getters.mergedConfig.stopGifs,
|
stopGifs: this.$store.getters.mergedConfig.stopGifs || window.matchMedia('(prefers-reduced-motion: reduce)').matches,
|
||||||
isAnimated: false,
|
isAnimated: false,
|
||||||
prefersReducedMotion: true
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
created () {
|
|
||||||
this.prefersReducedMotion = window.matchMedia('(prefers-reduced-motion: reduce)').matches
|
|
||||||
},
|
|
||||||
computed: {
|
computed: {
|
||||||
animated () {
|
animated () {
|
||||||
return this.stopGifs && this.isAnimated && this.prefersReducedMotion
|
return this.stopGifs && this.isAnimated
|
||||||
},
|
},
|
||||||
style () {
|
style () {
|
||||||
const appendPx = (str) => /\d$/.test(str) ? str + 'px' : str
|
const appendPx = (str) => /\d$/.test(str) ? str + 'px' : str
|
||||||
|
|
Loading…
Reference in a new issue