1import type { Signal } from "@preact/signals";2import { Button } from "../components/Button.tsx";34interface CounterProps {5 count: Signal<number>;6}78export default function Counter(props: CounterProps) {9 return (10 <div class="flex gap-8 py-6">11 <Button id="decrement" onClick={() => props.count.value -= 1}>-1</Button>12 <p class="text-3xl tabular-nums">{props.count}</p>13 <Button id="increment" onClick={() => props.count.value += 1}>+1</Button>14 </div>15 );16}