void;
testIdPrefix: string;
className?: string;
+ // Optional: when provided, the checked-checkbox accent matches the
+ // parent note's color (pink note → pink check, etc.). Falls back to
+ // amber when omitted or unknown — see colorAccent().
+ noteColor?: string | null;
}) {
if (items.length === 0) return null;
+ const accent = colorAccent(noteColor);
return (
onToggle?.(it.id, e.target.checked)}
- className="mt-0.5 h-4 w-4 rounded border-black/30 accent-amber-500 disabled:cursor-default"
+ className={`mt-0.5 h-4 w-4 rounded border-black/30 ${accent} disabled:cursor-default`}
data-testid={`${testIdPrefix}-check-${it.id}`}
/>