client lint first pass

This commit is contained in:
Matteo Pagliazzi
2019-10-11 20:35:49 +02:00
parent 07cffe9e16
commit a625e83b53
104 changed files with 1053 additions and 893 deletions

View File

@@ -144,7 +144,9 @@ export default {
if (this.notification.type === 'gp') localeKey += 'Gold';
if (this.notification.type === 'streak') localeKey = 'streakCoins';
return this.$t(localeKey);
// This requires eight translatable strings, but that gives the translators the most flexibility for matching gender/number and for using idioms for lost/spent/used/gained.
// This requires eight translatable strings, but that gives the
// translators the most flexibility for matching gender/number
// and for using idioms for lost/spent/used/gained.
},
negative () {
return this.notification.sign === '-' ? 'negative' : 'positive';
@@ -159,7 +161,8 @@ export default {
},
},
created () {
const timeout = this.notification.hasOwnProperty('timeout') ? this.notification.timeout : true;
const timeout = this.notification && this.notification.timeout
? this.notification.timeout : true;
if (timeout) {
let delay = this.notification.delay || 1500;
delay += this.$store.state.notificationStore.length * 1000;