From 02da95377e4b7797b0c6dbf382dbc0cb1b721b8f Mon Sep 17 00:00:00 2001 From: advplyr Date: Sat, 13 Nov 2021 19:17:33 -0600 Subject: [PATCH] Add: Listening statistics and chart on stats page #167 --- client/assets/fonts.css | 4 +- .../components/stats/DailyListeningChart.vue | 221 ++++++++++++++++++ client/components/stats/PreviewIcons.vue | 99 ++++++++ client/components/ui/Tooltip.vue | 2 +- client/pages/config.vue | 5 +- client/pages/config/stats.vue | 66 ++---- client/plugins/init.client.js | 11 +- 7 files changed, 357 insertions(+), 51 deletions(-) create mode 100644 client/components/stats/DailyListeningChart.vue create mode 100644 client/components/stats/PreviewIcons.vue diff --git a/client/assets/fonts.css b/client/assets/fonts.css index 43de8964..b4a7b190 100644 --- a/client/assets/fonts.css +++ b/client/assets/fonts.css @@ -26,7 +26,7 @@ -webkit-font-feature-settings: 'liga'; -webkit-font-smoothing: antialiased; } -.material-icons:not(.text-xs):not(.text-sm):not(.text-md):not(.text-base):not(.text-lg):not(.text-xl):not(.text-2xl):not(.text-3xl):not(.text-4xl):not(.text-5xl):not(.text-6xl) { +.material-icons:not(.text-xs):not(.text-sm):not(.text-md):not(.text-base):not(.text-lg):not(.text-xl):not(.text-2xl):not(.text-3xl):not(.text-4xl):not(.text-5xl):not(.text-6xl):not(.text-7xl):not(.text-8xl) { font-size: 1.5rem; } .material-icons-outlined { @@ -43,7 +43,7 @@ -webkit-font-feature-settings: 'liga'; -webkit-font-smoothing: antialiased; } -.material-icons-outlined:not(.text-xs):not(.text-sm):not(.text-md):not(.text-base):not(.text-lg):not(.text-xl):not(.text-2xl):not(.text-3xl):not(.text-4xl):not(.text-5xl):not(.text-6xl) { +.material-icons-outlined:not(.text-xs):not(.text-sm):not(.text-md):not(.text-base):not(.text-lg):not(.text-xl):not(.text-2xl):not(.text-3xl):not(.text-4xl):not(.text-5xl):not(.text-6xl):not(.text-7xl):not(.text-8xl) { font-size: 1.5rem; } diff --git a/client/components/stats/DailyListeningChart.vue b/client/components/stats/DailyListeningChart.vue new file mode 100644 index 00000000..ed2b895a --- /dev/null +++ b/client/components/stats/DailyListeningChart.vue @@ -0,0 +1,221 @@ + + + \ No newline at end of file diff --git a/client/components/stats/PreviewIcons.vue b/client/components/stats/PreviewIcons.vue new file mode 100644 index 00000000..63606799 --- /dev/null +++ b/client/components/stats/PreviewIcons.vue @@ -0,0 +1,99 @@ + + + \ No newline at end of file diff --git a/client/components/ui/Tooltip.vue b/client/components/ui/Tooltip.vue index cea02dd9..e797632d 100644 --- a/client/components/ui/Tooltip.vue +++ b/client/components/ui/Tooltip.vue @@ -8,7 +8,7 @@ export default { props: { text: { - type: String, + type: [String, Number], required: true }, direction: { diff --git a/client/pages/config.vue b/client/pages/config.vue index 073f8108..e4811f6d 100644 --- a/client/pages/config.vue +++ b/client/pages/config.vue @@ -1,7 +1,7 @@