aboutsummaryrefslogtreecommitdiffhomepage
path: root/client
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2022-05-18 09:18:39 +0200
committerChocobozzz <me@florianbigard.com>2022-05-18 09:18:39 +0200
commit305ec384966303bbcedb72b905c5ec4f32d9c7ad (patch)
tree4e0f722a5f0d4638484cb188c9205e53c11b4e89 /client
parent0cc253c9719b1e361d33d62adcef4c292cc98be9 (diff)
downloadPeerTube-305ec384966303bbcedb72b905c5ec4f32d9c7ad.tar.gz
PeerTube-305ec384966303bbcedb72b905c5ec4f32d9c7ad.tar.zst
PeerTube-305ec384966303bbcedb72b905c5ec4f32d9c7ad.zip
Add total viewers overall stat
Diffstat (limited to 'client')
-rw-r--r--client/src/app/+stats/video/video-stats.component.scss5
-rw-r--r--client/src/app/+stats/video/video-stats.component.ts6
2 files changed, 10 insertions, 1 deletions
diff --git a/client/src/app/+stats/video/video-stats.component.scss b/client/src/app/+stats/video/video-stats.component.scss
index e4c2d899f..5733b3286 100644
--- a/client/src/app/+stats/video/video-stats.component.scss
+++ b/client/src/app/+stats/video/video-stats.component.scss
@@ -23,6 +23,11 @@
23 23
24 .cards { 24 .cards {
25 display: flex; 25 display: flex;
26 flex-wrap: wrap;
27 }
28
29 .date-filter-wrapper {
30 margin-bottom: 10px;
26 } 31 }
27} 32}
28 33
diff --git a/client/src/app/+stats/video/video-stats.component.ts b/client/src/app/+stats/video/video-stats.component.ts
index 51738f8dc..4ce14902d 100644
--- a/client/src/app/+stats/video/video-stats.component.ts
+++ b/client/src/app/+stats/video/video-stats.component.ts
@@ -223,7 +223,7 @@ export class VideoStatsComponent implements OnInit {
223 private buildLiveFilter (session: LiveVideoSession) { 223 private buildLiveFilter (session: LiveVideoSession) {
224 return { 224 return {
225 id: session.startDate + '|' + session.endDate, 225 id: session.startDate + '|' + session.endDate,
226 label: $localize`Of live of ${new Date(session.startDate).toLocaleString()}` 226 label: $localize`Live as of ${new Date(session.startDate).toLocaleString()}`
227 } 227 }
228 } 228 }
229 229
@@ -276,6 +276,10 @@ export class VideoStatsComponent implements OnInit {
276 moreInfo: overallStats.viewersPeak !== 0 276 moreInfo: overallStats.viewersPeak !== 0
277 ? $localize`at ${new Date(overallStats.viewersPeakDate).toLocaleString()}` 277 ? $localize`at ${new Date(overallStats.viewersPeakDate).toLocaleString()}`
278 : undefined 278 : undefined
279 },
280 {
281 label: $localize`Unique viewers`,
282 value: this.numberFormatter.transform(overallStats.totalViewers)
279 } 283 }
280 ] 284 ]
281 285