Changed resolution to show the actual streaming resolution (transcode target) instead of the source file's, formatted as e.g. 1080p instead of 1920x1080

This commit is contained in:
Bergasha committed 2026-08-19 13:33:14 +10:00
1 parent c6f77cec2e
commit 6cac34e968
1 file changed
+6 -2
@@ -300,8 +300,12 @@ export default function MediaServerWidget({
const status = getPlaybackStatus(currentlyPlaying?.metadata?.transcoding);
const location = showLocation ? currentlyPlaying?.location : null;
const bitrateLabel = showBitrate ? formatBitrate(currentlyPlaying?.metadata?.bitrateKbps) : null;
const resolution = currentlyPlaying?.metadata?.video.resolution;
const resolutionLabel = resolution ? `${resolution.width}x${resolution.height}` : null;
// The transcoding resolution reflects what's actually being streamed - fall back to the
// source's own resolution when it isn't set (direct play, or a transcode that only
// touches audio/container and leaves the video resolution untouched).
const resolution =
currentlyPlaying?.metadata?.transcoding.resolution ?? currentlyPlaying?.metadata?.video.resolution;
const resolutionLabel = resolution ? `${resolution.height}p` : null;
const toggleDetails = () => setSelectedRowId((current) => (current === rowId ? null : rowId));
return (