From ca949d22dee5bc49c671227d28cf910a8b16fc31 Mon Sep 17 00:00:00 2001 From: npeter83 Date: Thu, 8 Oct 2026 02:25:58 +0200 Subject: [PATCH] fix(player): the channel line wraps instead of squeezing the meta into a column On a narrow card (a tablet, a zoomed window) the unwrapped row of name, meta and actions left the meta a one-word column. The row now wraps: the meta keeps at least 12rem, and the actions move down together. --- frontend/src/components/PlayerModal.tsx | 103 ++++++++++++------------ 1 file changed, 53 insertions(+), 50 deletions(-) diff --git a/frontend/src/components/PlayerModal.tsx b/frontend/src/components/PlayerModal.tsx index 6d9cac7f..ae4f2b94 100644 --- a/frontend/src/components/PlayerModal.tsx +++ b/frontend/src/components/PlayerModal.tsx @@ -145,6 +145,9 @@ const metaSep = ( ); const META_OWN_LINE = "w-full [&>span:first-child>[data-meta-sep]]:hidden"; +// Beside the channel name the meta takes what is left of the line, but never less than this: under it +// the line wraps and the meta, or the actions after it, move down instead of squeezing. +const META_MIN = "min-w-48 flex-1"; export default function PlayerModal({ video, @@ -961,10 +964,13 @@ export default function PlayerModal({ - {/* Channel + meta on one line, with the watched toggle pushed to the right. + {/* Channel + meta on one line, with the actions pushed to the right. When navigated to a linked video we only have its author (from the player), - so we show that as plain text and hide feed-video-specific bits. */} -
+ so we show that as plain text and hide feed-video-specific bits. + It wraps: the meta never gets narrower than META_MIN, and the actions move down as one + group. Unwrapped, a narrow card (a tablet, a zoomed window) squeezed the meta into a + one-word column between the name and the buttons. */} +
{!navigated && ( {active.view_count != null && ( @@ -1043,7 +1049,7 @@ export default function PlayerModal({ ) : ( // Linked video's stats come from the (already-fetched) video detail.
{detail.data?.view_count != null && ( @@ -1076,51 +1082,48 @@ export default function PlayerModal({ own (which hides our chrome). Mirrors the F key (maximise, a CSS big view); from there the docked bar offers OUR true fullscreen. */} {!navigated && ( - - - - )} - {!navigated && } - {!navigated && ( - - )} - {!navigated && onRemoveFromList && ( - void removeFromList()} - // Named with its object, like the list's menu row: a bare "Remove" among Fullscreen / - // Download / Mark watched reads as "delete this video". - label={t("playlists.removeItemOf", { title: active.title })} - title={t("playlists.removeItem")} - > - - - )} - {!navigated && ( - + // Narrow: the actions end the channel line. Wide: their own line in the panel. +
+ + + + + + {onRemoveFromList && ( + void removeFromList()} + // Named with its object, like the list's menu row: a bare "Remove" among Fullscreen / + // Download / Mark watched reads as "delete this video". + label={t("playlists.removeItemOf", { title: active.title })} + title={t("playlists.removeItem")} + > + + + )} + +
)}
{wide && (