fix portrait PWA nav dead while playing by making body the scroll container

This commit is contained in:
Jonathan Sykes
2026-07-10 13:55:31 +08:00
parent b72c079fb4
commit 88c89d66af
3 changed files with 137 additions and 27 deletions

View File

@@ -1765,14 +1765,17 @@ input[type="range"]::-webkit-slider-thumb:hover { transform: scale(1.25); }
z-index: 50;
}
/* --- Body: vertical stack (player above list) -------------------------- */
/* --- Body: vertical stack (player above list), THE scroll container ---- */
.body {
flex-direction: column;
overflow: hidden;
/* Body itself does NOT scroll — player-pane is fixed height,
list-pane takes remaining space and scrolls independently.
This keeps the player always visible and gives the list/settings
the full remaining viewport to scroll in. */
overflow-y: auto;
overflow-x: hidden;
overscroll-behavior: contain;
/* The body is the single scroll container in portrait. A playing player
pane (stage + control deck + meta + up-next + related) is taller than
the whole viewport, so it must be able to scroll out of the way — with
overflow:hidden here the list-pane sat unreachable below the fold and
every sidebar/bottom-nav tap looked dead while a track was playing. */
}
/* --- Player pane: full width, compact vertical padding ----------------- */
@@ -1808,14 +1811,16 @@ input[type="range"]::-webkit-slider-thumb:hover { transform: scale(1.25); }
gap: 6px;
}
/* --- List pane: full width below player, fills remaining height, scrolls independently --- */
/* --- List pane: full width below player, flows in the body scroll ------ */
.list-pane {
flex: 1;
min-height: 0; /* required for flex children to shrink below content size */
flex: none;
/* At least one full body-height so navigating always yields a full-screen
page; longer content just grows the body scroll. */
min-height: 100%;
width: 100%;
border-left: none;
border-top: 1px solid var(--line-soft);
overflow-y: auto;
overflow-y: visible;
overflow-x: hidden;
padding-left: env(safe-area-inset-left);
padding-right: env(safe-area-inset-right);