Every sidebar/rail column across the app (feed's left filter panel and right rail, post detail's left/right rails, profile's sidebar, the leaderboard's two rails, the dashboard sidebar, and the DeepSearch citations pane) is `position: sticky` with no max-height or overflow of its own. When a column's content is taller than the viewport, it doesn't scroll with the page while pinned - it renders past the bottom of the screen, unreachable until it "un-sticks" and flies past during a fast page scroll. Confirmed live: the docs nav sidebar alone is ~4300px of links against a ~900px viewport. Each sticky column now gets a max-height matched to its own top offset, `overflow-y: auto`, `overscroll-behavior: contain`, and a hidden scrollbar (scrollbar-width/-ms-overflow-style/::-webkit- scrollbar), the same invisible-scroll recipe already used by the messages page. Purely additive CSS - no template changes, since every target already had a distinguishing class. Fixing the shared `.sidebar-card` component in sidebar.css covers feed, admin, docs, gists, projects, battles, quizzes, and every /tools/* page in one place. Also caught and fixed a latent bug along the way: post.css already neutralized nested `.sidebar-card`s inside `.post-page-sidebar` (position: static) to stop them independently double-sticking, but the identical setup on the quiz page (`.feed-right` wrapping the scoreboard's two `.sidebar-card`s) never got that override - added the matching `.feed-right .sidebar-card` rule. Verified live with Playwright at a squeezed viewport height on feed, post, profile, leaderboard, docs, and the quiz scoreboard: every column's scrollTop reaches its true end independently, the center column never moves, and no scrollbar is visible in any screenshot. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Vnp7vzE4hvsytMo5YjszJm
113 lines
2.1 KiB
CSS
113 lines
2.1 KiB
CSS
/* retoor <retoor@molodetz.nl> */
|
|
|
|
.sidebar-card {
|
|
position: sticky;
|
|
top: calc(var(--nav-height) + 1rem);
|
|
max-height: calc(100vh - var(--nav-height) - 2rem);
|
|
overflow-y: auto;
|
|
overscroll-behavior: contain;
|
|
scrollbar-width: none;
|
|
-ms-overflow-style: none;
|
|
background: var(--bg-card);
|
|
border: 1px solid var(--border);
|
|
border-radius: var(--radius-lg);
|
|
box-shadow: var(--shadow-sm);
|
|
padding: 1rem;
|
|
}
|
|
|
|
.sidebar-card::-webkit-scrollbar {
|
|
width: 0;
|
|
height: 0;
|
|
}
|
|
|
|
.sidebar-card .sidebar-heading {
|
|
font-size: 0.75rem;
|
|
font-weight: 700;
|
|
text-transform: uppercase;
|
|
letter-spacing: 0.1em;
|
|
color: var(--text-muted);
|
|
margin-bottom: 0.75rem;
|
|
}
|
|
|
|
.sidebar-card .sidebar-tier {
|
|
margin-top: 1.4rem;
|
|
padding-top: 0.85rem;
|
|
border-top: 1px solid var(--border);
|
|
font-size: 0.8rem;
|
|
color: var(--text-primary);
|
|
}
|
|
|
|
.sidebar-card .sidebar-tier:first-of-type {
|
|
margin-top: 0.85rem;
|
|
}
|
|
|
|
.sidebar-card .sidebar-subheading {
|
|
margin-top: 0.6rem;
|
|
margin-bottom: 0.4rem;
|
|
text-transform: none;
|
|
letter-spacing: 0;
|
|
font-size: 0.8rem;
|
|
color: var(--accent);
|
|
}
|
|
|
|
.sidebar-link-nested {
|
|
padding-left: 1.75rem;
|
|
}
|
|
|
|
.sidebar-section {
|
|
margin-bottom: 1rem;
|
|
}
|
|
|
|
.sidebar-section:last-child {
|
|
margin-bottom: 0;
|
|
}
|
|
|
|
.sidebar-nav {
|
|
display: flex;
|
|
flex-direction: column;
|
|
gap: 0.125rem;
|
|
}
|
|
|
|
.sidebar-link {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 0.625rem;
|
|
padding: 0.5rem 0.75rem;
|
|
border-radius: var(--radius);
|
|
font-size: 0.875rem;
|
|
color: var(--text-secondary);
|
|
}
|
|
|
|
.sidebar-link:hover {
|
|
background: var(--bg-card-hover);
|
|
color: var(--text-primary);
|
|
text-decoration: none;
|
|
}
|
|
|
|
.sidebar-link.active,
|
|
.sidebar-link.active:hover {
|
|
background: var(--accent);
|
|
color: var(--on-accent);
|
|
font-weight: 600;
|
|
}
|
|
|
|
.sidebar-dot {
|
|
width: 8px;
|
|
height: 8px;
|
|
border-radius: 50%;
|
|
flex-shrink: 0;
|
|
}
|
|
|
|
.sidebar-icon {
|
|
font-size: 1rem;
|
|
width: 20px;
|
|
text-align: center;
|
|
flex-shrink: 0;
|
|
}
|
|
|
|
@media (max-width: 1024px) {
|
|
.sidebar-card {
|
|
display: none;
|
|
}
|
|
}
|