aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/assets/player
diff options
context:
space:
mode:
authorEwout van Mansom <ewout@vanmansom.name>2022-09-14 18:27:50 +0200
committerChocobozzz <chocobozzz@cpy.re>2022-09-16 10:19:30 +0200
commit192edf169c70f44543c4e6843cac567bdbd91c59 (patch)
tree9a1cd60a8c2dc57b6cb98be68ffb8a325cee5e59 /client/src/assets/player
parente1eada8bae03d06dcd9549c06c67392a55a0fc96 (diff)
downloadPeerTube-192edf169c70f44543c4e6843cac567bdbd91c59.tar.gz
PeerTube-192edf169c70f44543c4e6843cac567bdbd91c59.tar.zst
PeerTube-192edf169c70f44543c4e6843cac567bdbd91c59.zip
Translate more strings in player stats
Diffstat (limited to 'client/src/assets/player')
-rw-r--r--client/src/assets/player/shared/stats/stats-card.ts10
1 files changed, 6 insertions, 4 deletions
diff --git a/client/src/assets/player/shared/stats/stats-card.ts b/client/src/assets/player/shared/stats/stats-card.ts
index ed2910fa2..f23ae48be 100644
--- a/client/src/assets/player/shared/stats/stats-card.ts
+++ b/client/src/assets/player/shared/stats/stats-card.ts
@@ -260,12 +260,13 @@ class StatsCard extends Component {
260 const vw = Math.max(document.documentElement.clientWidth || 0, window.innerWidth || 0) 260 const vw = Math.max(document.documentElement.clientWidth || 0, window.innerWidth || 0)
261 const vh = Math.max(document.documentElement.clientHeight || 0, window.innerHeight || 0) 261 const vh = Math.max(document.documentElement.clientHeight || 0, window.innerHeight || 0)
262 const pr = (window.devicePixelRatio || 1).toFixed(2) 262 const pr = (window.devicePixelRatio || 1).toFixed(2)
263 const frames = `${vw}x${vh}*${pr} / ${videoQuality.droppedVideoFrames} dropped of ${videoQuality.totalVideoFrames}` 263 const vp = `${vw}x${vh}*${pr}`
264 264 const { droppedVideoFrames, totalVideoFrames } = videoQuality
265 const frames = player.localize('{1} / {2} dropped of {3}', [ vp, droppedVideoFrames + '', totalVideoFrames + '' ])
265 const duration = player.duration() 266 const duration = player.duration()
266 267
267 let volume = `${Math.round(player.volume() * 100)}` 268 let volume = `${Math.round(player.volume() * 100)}`
268 if (player.muted()) volume += ' (muted)' 269 if (player.muted()) volume += player.localize(' (muted)')
269 270
270 const networkActivity = playerNetworkInfo.downloadSpeed 271 const networkActivity = playerNetworkInfo.downloadSpeed
271 ? `${playerNetworkInfo.downloadSpeed} &dArr; / ${playerNetworkInfo.uploadSpeed} &uArr;` 272 ? `${playerNetworkInfo.downloadSpeed} &dArr; / ${playerNetworkInfo.uploadSpeed} &uArr;`
@@ -274,8 +275,9 @@ class StatsCard extends Component {
274 const totalTransferred = playerNetworkInfo.totalDownloaded 275 const totalTransferred = playerNetworkInfo.totalDownloaded
275 ? `${playerNetworkInfo.totalDownloaded} &dArr; / ${playerNetworkInfo.totalUploaded} &uArr;` 276 ? `${playerNetworkInfo.totalDownloaded} &dArr; / ${playerNetworkInfo.totalUploaded} &uArr;`
276 : undefined 277 : undefined
278 const { downloadedFromServer, downloadedFromPeers } = playerNetworkInfo
277 const downloadBreakdown = playerNetworkInfo.downloadedFromServer 279 const downloadBreakdown = playerNetworkInfo.downloadedFromServer
278 ? `${playerNetworkInfo.downloadedFromServer} from servers · ${playerNetworkInfo.downloadedFromPeers} from peers` 280 ? player.localize('{1} from servers · {2} from peers', [ downloadedFromServer, downloadedFromPeers ])
279 : undefined 281 : undefined
280 282
281 const bufferProgress = progress !== undefined 283 const bufferProgress = progress !== undefined