Forms

Checkbox

A native checkbox under a drawn box. The check draws itself in on the brand fill. Takes a label, a muted description, and an indeterminate state for a select all.

view .md
Preview
needed by card
Installation
terminal
bash
npx @entrepta/cli@latest add checkbox

// Resolves dependencies, copies the source, and installs npm packages automatically.

Usage
checkbox.tsx
tsx
import { Checkbox } from "@/components/entrepta/checkbox"

<Checkbox label="button" defaultChecked />
<Checkbox label="diamond" description="needed by card" checked disabled />
<Checkbox
  label="primitives"
  checked={all}
  indeterminate={some && !all}
  onChange={toggleAll}
/>
Props
PropTypeDefaultDescription
labelReactNode-Clickable label beside the box
descriptionReactNode-Muted line under the label, read as the description
indeterminatebooleanfalseThe mixed state, a dash on the brand fill
checkedboolean-Controlled state, like a native input
Active theme: entrepta, dark mode.