Skip to content
satin

Selectable checkbox

Pick any number of options, each a card with a line of explanation and an icon.

Installation

Terminal
npm i @uisatin/ui
Import
import { SelectableCheckbox } from '@uisatin/ui/selectable-checkbox'

About 16.2 kB of JavaScript, minified and gzipped, with what it imports (React aside). The stylesheet is one file for every component.

First time with Satin? Set it up once, styles and fonts included, with the installation guide.

API Reference

The SelectableCheckbox component is a Checkbox inside a card that is its label, the box at the right edge. The whole card toggles it.

PropTypeDefault
checked
boolean"indeterminate"
—
defaultChecked
boolean
—
onCheckedChange
(checked) => void
—
title
ReactNode
—
description
ReactNode
—
icon
ReactNode
—
size
"sm""md"
"md"
disabled
boolean
false

Accessibility

A Checkbox (role="checkbox", aria-checked) inside a card that is its label, so the whole card toggles it. The box is labelled by the card’s title and described by its description. The icon tile is hidden. For one legend over several cards, put them in a FieldGroup.

KeyAction
SpaceChecks or unchecks the focused card.