Skip to content

Commit 4c6ddfb

Browse files
samejrclaude
andcommitted
fix(webapp): notch the contrast track at the default mark
Doubles the mark's height and hangs background-coloured borders either side of the 1px line, so it cuts through the track instead of blending into it. The border colour is a theme token, so it follows light mode too. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
1 parent 4d5645d commit 4c6ddfb

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

apps/webapp/app/components/primitives/Slider.tsx

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,10 @@ export function Slider({
102102
<span
103103
key={mark}
104104
aria-hidden
105-
className="absolute top-1/2 h-2 w-px -translate-x-1/2 -translate-y-1/2 bg-text-dimmed"
105+
// box-content keeps the line 1px wide and hangs the background-
106+
// coloured borders outside it, notching the track either side so
107+
// the mark reads in both themes.
108+
className="absolute top-1/2 box-content h-4 w-px -translate-x-1/2 -translate-y-1/2 border-x border-background-bright bg-text-dimmed"
106109
style={{ left: `calc(${percent}% + ${offset}px)` }}
107110
/>
108111
);

0 commit comments

Comments
 (0)