Files
plainleaf/plug-api/ui/checkbox.tsx
T
Zef Hemel 3a8aaf2486 Beginnings of a design system for UI components
Right now mostly extracted from configuration-manager and SilverBullet+'s dashboard. Will be used in more plugs moving forward.
2026-06-01 13:16:57 +02:00

11 lines
328 B
TypeScript

import type { JSX } from "preact";
import { cx } from "./cx.ts";
export type CheckboxProps =
& Omit<JSX.IntrinsicElements["input"], "class" | "type">
& { class?: string };
export function Checkbox({ class: extra, ...rest }: CheckboxProps) {
return <input type="checkbox" class={cx("sb-checkbox", extra)} {...rest} />;
}