this might be it
This commit is contained in:
parent
6293621f68
commit
12dcb2e8ac
1 changed files with 11 additions and 7 deletions
18
src/App.js
18
src/App.js
|
@ -46,13 +46,7 @@ export default {
|
||||||
}),
|
}),
|
||||||
watch: {
|
watch: {
|
||||||
themeApplied (value) {
|
themeApplied (value) {
|
||||||
this.$nextTick(() => {
|
this.removeSplash()
|
||||||
document.querySelector('#status').textContent = this.$t('splash.fun_' + Math.ceil(Math.random() * 4))
|
|
||||||
/* eslint-disable no-debugger */
|
|
||||||
debugger
|
|
||||||
document.querySelector('#splash').classList.add('hidden')
|
|
||||||
document.querySelector('#app').classList.remove('hidden')
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
created () {
|
created () {
|
||||||
|
@ -61,6 +55,11 @@ export default {
|
||||||
this.$store.dispatch('setOption', { name: 'interfaceLanguage', value: val })
|
this.$store.dispatch('setOption', { name: 'interfaceLanguage', value: val })
|
||||||
window.addEventListener('resize', this.updateMobileState)
|
window.addEventListener('resize', this.updateMobileState)
|
||||||
},
|
},
|
||||||
|
mounted () {
|
||||||
|
if (themeApplied) {
|
||||||
|
this.removeSplash()
|
||||||
|
}
|
||||||
|
}
|
||||||
unmounted () {
|
unmounted () {
|
||||||
window.removeEventListener('resize', this.updateMobileState)
|
window.removeEventListener('resize', this.updateMobileState)
|
||||||
},
|
},
|
||||||
|
@ -144,6 +143,11 @@ export default {
|
||||||
updateMobileState () {
|
updateMobileState () {
|
||||||
this.$store.dispatch('setLayoutWidth', windowWidth())
|
this.$store.dispatch('setLayoutWidth', windowWidth())
|
||||||
this.$store.dispatch('setLayoutHeight', windowHeight())
|
this.$store.dispatch('setLayoutHeight', windowHeight())
|
||||||
|
},
|
||||||
|
removeSplash() {
|
||||||
|
document.querySelector('#status').textContent = this.$t('splash.fun_' + Math.ceil(Math.random() * 4))
|
||||||
|
document.querySelector('#splash').classList.add('hidden')
|
||||||
|
document.querySelector('#app').classList.remove('hidden')
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue