aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/App.scss3
l---------[-rw-r--r--]src/assets/pleromatan_apology.pngbin405742 -> 35 bytes
-rw-r--r--src/main.js23
3 files changed, 14 insertions, 12 deletions
diff --git a/src/App.scss b/src/App.scss
index 5e7d3656..d5bb6469 100644
--- a/src/App.scss
+++ b/src/App.scss
@@ -954,8 +954,7 @@ option {
&.dead {
animation-name: dead;
- animation-duration: 3s;
- // animation-iteration-count: 1;
+ animation-duration: 2s;
animation-iteration-count: 1;
transform: rotateX(90deg) rotateY(0) rotateZ(-45deg);
}
diff --git a/src/assets/pleromatan_apology.png b/src/assets/pleromatan_apology.png
index 36ad7aeb..a7f6191f 100644..120000
--- a/src/assets/pleromatan_apology.png
+++ b/src/assets/pleromatan_apology.png
Binary files differ
diff --git a/src/main.js b/src/main.js
index 4ccdabb9..81fa09db 100644
--- a/src/main.js
+++ b/src/main.js
@@ -48,16 +48,6 @@ const i18n = createI18n({
messages.setLanguage(i18n.global, currentLocale)
-const splashError = (i18n, e) => {
- document.querySelector('#mascot').src = (Math.floor(Math.random() * 2) > 0)
- ? '/static/pleromatan_orz_fox.png'
- : '/static/pleromatan_orz.png'
- document.querySelector('#mascot').classList.add('orz')
- document.querySelector('#throbber').classList.add('dead')
- document.querySelector('#status').textContent = i18n.global.t('splash.error')
- console.error('PleromaFE failed to initialize: ', e)
-}
-
const persistedStateOptions = {
paths: [
'serverSideStorage.cache',
@@ -68,6 +58,18 @@ const persistedStateOptions = {
};
(async () => {
+ const isFox = Math.floor(Math.random() * 2) > 0 ? '_fox' : ''
+
+ const splashError = (i18n, e) => {
+ const throbber = document.querySelector('#throbber')
+ throbber.addEventListener('animationend', () => {
+ document.querySelector('#mascot').src = `/static/pleromatan_orz${isFox}.png`
+ })
+ throbber.classList.add('dead')
+ document.querySelector('#status').textContent = i18n.global.t('splash.error')
+ console.error('PleromaFE failed to initialize: ', e)
+ }
+
try {
let storageError
const plugins = [pushNotifications]
@@ -78,6 +80,7 @@ const persistedStateOptions = {
console.error('Storage error', e)
storageError = e
}
+ document.querySelector('#mascot').src = `/static/pleromatan_apology${isFox}.png`
document.querySelector('#status').removeAttribute('class')
document.querySelector('#status').textContent = i18n.global.t('splash.loading')
document.querySelector('#splash-credit').textContent = i18n.global.t('update.art_by', { linkToArtist: 'pipivovott' })