fix(client): size the turn strip to the scroll content instead of the viewport
As an in-flow child of the horizontal scroller, .lc-turns capped at the viewport width (clientWidth) and its overflow:hidden clipped every turn block past the first screen: on a scrollable chart the strip stopped mid-bars, and the visible-slice-centered label could drift off or vanish beyond the clip edge. Give the strip the same max-content/min-width sizing as .lc-chart so it always spans the full column grid; the label centering needs no change.
This commit is contained in:
1 parent
4ac3bba1cf
commit
a05e2819af
1 file changed
+4
-1
@@ -76,7 +76,10 @@
|
||||
/*
|
||||
Turn strip: NEUTRAL zebra fills (inline, see TURN_FILLS) — never the category palette, or the strip reads as a detached bottom segment of the bars.
|
||||
*/
|
||||
.lc-turns { display: flex; gap: 2px; overflow: hidden; margin-top: 4px; }
|
||||
/* Same sizing as .lc-chart: as an in-flow child of the scroller the strip would otherwise cap at the
|
||||
viewport width (clientWidth) and overflow:hidden would clip every block past the first screen — the
|
||||
strip must span the full scrollable column grid instead. */
|
||||
.lc-turns { display: flex; gap: 2px; overflow: hidden; margin-top: 4px; width: max-content; min-width: 100%; }
|
||||
.lc-turn { flex: none; box-sizing: border-box; text-align: center; font-size: 10px; line-height: 14px; font-weight: 600; color: var(--dsw-alias-label-secondary); border-radius: 3px; height: 14px; white-space: nowrap; cursor: pointer; transition: filter var(--ds-transition-duration, 0.2s) var(--ds-ease-in-out, ease-in-out), opacity var(--ds-transition-duration, 0.2s) var(--ds-ease-in-out, ease-in-out); }
|
||||
.lc-turn-on { filter: brightness(1.35); color: var(--dsw-alias-label-primary); }
|
||||
/* Labels render at natural width, centered over their block — a 2-digit "12" over a 14px turn bar overflows the
|
||||
|
||||
Reference in new issue
Block a user