Checkbox
A single checkbox: a hairline square that darkens on hover and a check that draws itself.
Installation
Install Checkbox from the Fluid Effect UI registry.
Basic
With a description
One email a month, never more.
Invalid and disabled
Required to join the event
API Reference
Types come from the public API. A dash indicates no default is documented here.
Checkbox props
Public source| Prop | Type | Default | Description |
|---|---|---|---|
key | KeepAliveKey<K, Ends> | undefined | '' | The child's identity among its parent's children of one component, or a kept child's among its author's. The empty string by default. |
onEmit | Show type((events: { readonly _tag: "ChangeRequested"; readonly checked: boolean; readonly indeterminate: boolean; }) => NoInfer<Msg> | undefined) | { readonly ChangeRequested: (event: { readonly _tag: "ChangeRequested"; readonly checked: boolean; readonly indeterminate: boolean; }) => NoInfer<Msg> | undefined; } | undefined | — | Handle the child's events with a callback, or supply one handler per tag for tagged events. Return a parent message to dispatch it, or `undefined` to ignore the event. |
props.label | string | Required | |
props.id | string | Required | |
props.checked | boolean | Required | |
props.form | string | — | |
props.disabled | boolean | — | |
props.value | string | 'on' | |
props.size | "default" | "compact" | 'default' | |
props.reducedMotion | "user" | "always" | "never" | — | |
props.required | boolean | — | |
props.invalid | boolean | — | |
props.className | string | — | |
props.shape | "rounded" | "pill" | "sharp" | — | |
props.name | string | — | |
props.readOnly | boolean | — | |
props.describedBy | string | — | |
props.externalLabel | boolean | — | |
props.indeterminate | boolean | — |