Files
familienarchiv/frontend/src/lib/document/TimelineYAxis.svelte
Marcel 219d9a816e refactor(documents): extract Y-axis and X-axis components (#385)
Felix's review named "TimelineAxes" as one of four split targets.
The Y-axis and X-axis don't sit adjacent in the DOM — Y is a flex
sibling of the bars+X column — so two single-purpose components
beats a discriminator-prop component. tickIndicesFor and the
omitTickYear derivation move to TimelineXAxis where they belong.
Closes part 2 of Felix's component-split concern.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-08 10:06:46 +02:00

20 lines
365 B
Svelte

<script lang="ts">
let {
maxCount,
barAreaHeight
}: {
maxCount: number;
barAreaHeight: number;
} = $props();
</script>
<div
class="flex flex-col justify-between pr-1.5 text-right font-sans text-xs leading-none text-ink-3"
style="height: {barAreaHeight}px;"
aria-hidden="true"
data-testid="timeline-y-axis"
>
<span>{maxCount}</span>
<span>0</span>
</div>