Logobaseui-cn

Checkbox

A control that allows the user to toggle between checked and unchecked states.

forminteractive
Loading preview...

Installation

npx baseui-cn add checkbox

Usage

import { Checkbox } from "@/components/ui/checkbox"
<Checkbox />

Examples

Basic

A simple checkbox.

Loading preview...

With label

Pair with a Field and Label.

Loading preview...

Indeterminate

Use the indeterminate state for partial selections.

Loading preview...

Disabled

A disabled checkbox.

Loading preview...

API Reference

See the Base UI Checkbox documentation for the full API reference, including all props, data attributes, and CSS classes.