Skip to content
LyEve UI v0.60.1

Form controls

CheckboxGroup

A managed set of checkboxes bound to an array of values, with a legend, a hint and an error message for the set as a whole. It renders a real fieldset, so the group is announced as a group rather than as loose controls. For one standalone box use Checkbox.

Basic

The bound array is ordered by options and not by click order, so ticking the third option and then the first submits the same value as ticking them the other way round.

Token scopes

A token with no scope can read nothing.

Value: ["read"]

The same options as RadioGroup

RadioGroup declares the same ChoiceOption shape, so one option list drives either control. The only difference is what the value is: an array of every chosen value here, a single value there.

Notify me on
Value: ["email"]
Primary channel
Value: "email"

Horizontal, as cards

Deploy to

Error state

Confirm before deleting(required)

Tick at least one.

Under a touch screen

Each option takes a 44px target of its own. The options sit far enough apart that no two targets overlap, in a column and in a horizontal row that wraps, so a tap near the bottom of one option never picks the option below it. Options drawn as cards keep their spacing, and a mouse keeps the tighter list.

API

PropTypeDefaultDescription
value string[][]Bindable chosen values, ordered by options rather than by click order.
options requiredChoiceOption[] no defaultThe option list.
label requiredstring no defaultThe group legend. Required, because an unnamed group announces as a bare set of controls.
labelHidden booleanfalseKeep the legend for screen readers and take it off the screen.
hint string no defaultSubdued hint below the group.
error string no defaultError message. Replaces the hint.
name string no defaultNative form name shared by every option. Generated when omitted.
orientation 'vertical' | 'horizontal''vertical'Lay the options out down a column or across a row.
size 'sm' | 'md' | 'lg''md'Scale of the box, the icon slot and the label.
variant 'inline' | 'card''inline'Card draws a bordered option whose whole surface is the target.
required booleanfalseAdd a red asterisk to the legend.
disabled booleanfalseDisable every option in the group.
class string no defaultExtra classes on the fieldset.
onchange (value: string[]) => void no defaultFires on every toggle, with the whole new array.
noAI booleanfalseKeep the value from an assistant: a FormAssist never reports it or fills it, and the control is marked data-no-ai for a browser agent.

ChoiceOption

PropTypeDefaultDescription
value requiredstring no defaultThe submitted value, and the key the option renders under.
label requiredstring no defaultNames this one choice. The group is named by the legend.
description string no defaultA second line under the label.
icon Component no defaultA lucide component, drawn before the label. The group sizes it.
disabled booleanfalseBlock this option alone. A disabled group blocks every option.