Merge pull request #1438 from tomazed/LocalizedStatsPage

Localized stats page
This commit is contained in:
advplyr 2023-01-24 17:30:32 -06:00 committed by GitHub
commit 030c20b12e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
10 changed files with 44 additions and 11 deletions

View File

@ -27,7 +27,7 @@
<div class="absolute -bottom-2 left-0 flex ml-6">
<template v-for="dayObj in last7Days">
<div :key="dayObj.date" :style="{ width: daySpacing + daySpacing / 14 + 'px' }">
<p class="text-sm font-book">{{ dayObj.dayOfWeek.slice(0, 3) }}</p>
<p class="text-sm font-book">{{ dayObj.dayOfWeekAbbr }}</p>
</div>
</template>
</div>
@ -108,6 +108,7 @@ export default {
var _date = this.$addDaysToToday(i * -1)
days.push({
dayOfWeek: this.$formatJsDate(_date, 'EEEE'),
dayOfWeekAbbr: this.$strings[`Weekday${this.$formatJsDate(_date, 'EEE')}`],
date: this.$formatJsDate(_date, 'yyyy-MM-dd')
})
}
@ -218,4 +219,4 @@ export default {
},
mounted() {}
}
</script>
</script>

View File

@ -208,7 +208,7 @@ export default {
const date = i === 0 ? this.firstWeekStart : this.$addDaysToDate(this.firstWeekStart, i)
const dateString = this.$formatJsDate(date, 'yyyy-MM-dd')
const datePretty = this.$formatJsDate(date, 'MMM d, yyyy')
const monthString = this.$formatJsDate(date, 'MMM')
const monthString = this.$strings[`Month${this.$formatJsDate(date, 'MMM')}`]
const value = this.daysListening[dateString] || 0
const x = col * 13
const y = row * 13
@ -270,4 +270,4 @@ export default {
},
beforeDestroy() {}
}
</script>
</script>

View File

@ -630,10 +630,14 @@
"WeekdayFriday": "Freitag",
"WeekdayMon": "Mon",
"WeekdayMonday": "Montag",
"WeekdaySat": "Sat",
"WeekdaySaturday": "Samstag",
"WeekdaySun": "Sun",
"WeekdaySunday": "Sonntag",
"WeekdayThu": "Thu",
"WeekdayThursday": "Donnerstag",
"WeekdayTue": "Tue",
"WeekdayTuesday": "Dienstag",
"WeekdayWed": "Wed",
"WeekdayWednesday": "Mittwoch"
}
}

View File

@ -630,10 +630,14 @@
"WeekdayFriday": "Friday",
"WeekdayMon": "Mon",
"WeekdayMonday": "Monday",
"WeekdaySat": "Sat",
"WeekdaySaturday": "Saturday",
"WeekdaySun": "Sun",
"WeekdaySunday": "Sunday",
"WeekdayThu": "Thu",
"WeekdayThursday": "Thursday",
"WeekdayTue": "Tue",
"WeekdayTuesday": "Tuesday",
"WeekdayWed": "Wed",
"WeekdayWednesday": "Wednesday"
}
}

View File

@ -630,10 +630,14 @@
"WeekdayFriday": "Friday",
"WeekdayMon": "Mon",
"WeekdayMonday": "Monday",
"WeekdaySat": "Sat",
"WeekdaySaturday": "Saturday",
"WeekdaySun": "Sun",
"WeekdaySunday": "Sunday",
"WeekdayThu": "Thu",
"WeekdayThursday": "Thursday",
"WeekdayTue": "Tue",
"WeekdayTuesday": "Tuesday",
"WeekdayWed": "Wed",
"WeekdayWednesday": "Wednesday"
}
}

View File

@ -630,9 +630,13 @@
"WeekdayFriday": "Vendredi",
"WeekdayMon": "Lun",
"WeekdayMonday": "Lundi",
"WeekdaySat": "Sam",
"WeekdaySaturday": "Samedi",
"WeekdaySun": "Dim",
"WeekdaySunday": "Dimanche",
"WeekdayThu": "Jeu",
"WeekdayThursday": "Jeudi",
"WeekdayTue": "Mar",
"WeekdayTuesday": "Mardi",
"WeekdayWed": "Mer",
"WeekdayWednesday": "Mercredi"

View File

@ -630,10 +630,14 @@
"WeekdayFriday": "Petak",
"WeekdayMon": "Mon",
"WeekdayMonday": "Ponedjeljak",
"WeekdaySat": "Sat",
"WeekdaySaturday": "Subota",
"WeekdaySun": "Sun",
"WeekdaySunday": "Nedjelja",
"WeekdayThu": "Thu",
"WeekdayThursday": "Četvrtak",
"WeekdayTue": "Tue",
"WeekdayTuesday": "Utorak",
"WeekdayWed": "Wed",
"WeekdayWednesday": "Srijeda"
}
}

View File

@ -630,10 +630,14 @@
"WeekdayFriday": "Venerdì",
"WeekdayMon": "Lun",
"WeekdayMonday": "Lunedì",
"WeekdaySat": "Sat",
"WeekdaySaturday": "Sabato",
"WeekdaySun": "Sun",
"WeekdaySunday": "Domenica",
"WeekdayThu": "Thu",
"WeekdayThursday": "Giovedì",
"WeekdayTue": "Tue",
"WeekdayTuesday": "Martedì",
"WeekdayWed": "Mer",
"WeekdayWednesday": "Mercoledì"
}
}

View File

@ -630,10 +630,14 @@
"WeekdayFriday": "Piątek",
"WeekdayMon": "Mon",
"WeekdayMonday": "Poniedziałek",
"WeekdaySat": "Sat",
"WeekdaySaturday": "Sobota",
"WeekdaySun": "Sun",
"WeekdaySunday": "Niedziela",
"WeekdayThu": "Thu",
"WeekdayThursday": "Czwartek",
"WeekdayTue": "Tue",
"WeekdayTuesday": "Wtorek",
"WeekdayWed": "Wed",
"WeekdayWednesday": "Środa"
}
}

View File

@ -630,10 +630,14 @@
"WeekdayFriday": "星期五",
"WeekdayMon": "Mon",
"WeekdayMonday": "星期一",
"WeekdaySat": "Sat",
"WeekdaySaturday": "星期六",
"WeekdaySun": "Sun",
"WeekdaySunday": "星期日",
"WeekdayThu": "Thu",
"WeekdayThursday": "星期四",
"WeekdayTue": "Tue",
"WeekdayTuesday": "星期二",
"WeekdayWed": "Wed",
"WeekdayWednesday": "星期三"
}
}