From 704c37f97fee30aa12d3b104befeb3e1fb0e9284 Mon Sep 17 00:00:00 2001 From: edde746 <86283021+edde746@users.noreply.github.com> Date: Thu, 28 May 2026 08:16:27 +0200 Subject: [PATCH] fix(ui): tighten media detail spacing --- lib/screens/media_detail_screen.dart | 4 ++-- lib/widgets/tv_browse_rail.dart | 4 +++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/lib/screens/media_detail_screen.dart b/lib/screens/media_detail_screen.dart index 3a4bff91..01e1756c 100644 --- a/lib/screens/media_detail_screen.dart +++ b/lib/screens/media_detail_screen.dart @@ -3885,7 +3885,7 @@ class _MediaDetailScreenState extends State const innerPadding = 3.0; final imageSize = cardWidth; // image + inner padding + text area + outer list padding + focus scale headroom - final containerHeight = imageSize + innerPadding * 2 + 66 + 16; + final containerHeight = imageSize + innerPadding * 2 + 58 + 10; final theme = Theme.of(context); final actorNameStyle = theme.textTheme.bodyMedium?.copyWith(fontWeight: FontWeight.w600); @@ -3988,7 +3988,7 @@ class _MediaDetailScreenState extends State final cardWidth = _getResponsiveCardWidth(); // 16:9 aspect ratio for clip thumbnails (cardWidth includes 8px padding on each side) final posterHeight = (cardWidth - 16) * (9 / 16); - final containerHeight = posterHeight + 66; + final containerHeight = posterHeight + 52; return Focus( focusNode: _extrasFocusNode, diff --git a/lib/widgets/tv_browse_rail.dart b/lib/widgets/tv_browse_rail.dart index dd82395d..d94185fb 100644 --- a/lib/widgets/tv_browse_rail.dart +++ b/lib/widgets/tv_browse_rail.dart @@ -68,6 +68,8 @@ class TvBrowseRailLayout { static double railInteractionExpansionForScale(double scale) => (12 * scale).clamp(8, 18).toDouble(); + static double itemGapForScale(double _) => 0; + static double hubStripHeightForScale(double scale) => 36 * scale; static double hubStripGapForScale(double _) => 0; @@ -114,7 +116,7 @@ class TvBrowseRailLayout { }) { final focusExtra = FocusTheme.focusBorderWidth * 2 * scale; final railEdgePadding = focusExtra + (12 * scale); - final itemGap = 8 * scale; + final itemGap = itemGapForScale(scale); final isPersonHub = TvBrowseRailLayout.isPersonHub(hub); final hasWide = !isPersonHub && hub.items.any((item) => item.usesWideAspectRatio(episodePosterMode)); final hasTall = !isPersonHub && hub.items.any((item) => !item.usesWideAspectRatio(episodePosterMode));