www: use tabular-nums on Counter count (#242)

`font-variant-numeric: tabular-nums` make each number glyph take up
the same amount of space, which in turn makes the add and subtract
buttons move less about when altering the count.
This commit is contained in:
Sindre Bøyum
2022-06-16 21:44:29 +00:00
committed by GitHub
parent f8262c656a
commit af9c7d4eb9
+1 -1
View File
@@ -22,7 +22,7 @@ export default function Counter(props: CounterProps) {
>
<IconMinus />
</RoundedButton>
<div class={tw`text-3xl`}>{count}</div>
<div class={tw`text-3xl tabular-nums`}>{count}</div>
<RoundedButton
title="Add 1"
onClick={() => setCount(count + 1)}