Forms / Checkbox

Forms

Checkbox

A labelled on/off choice, with an optional hint, and checkgroup for a set of related choices under one legend.

import { EcoCheckbox, EcoCheckboxGroup } from "vue-ecosphere"

States

The indeterminate box follows the group below.

With a hint

Group

Columns to export

Value: ["request","owner"]

Group in a row, invalid

One message for the group, not one per box. Check any option to clear it.

Notify by

Choose at least one way to be notified.

Value: []

EcoCheckbox

NameTypeDefaultDescription
v-modelbooleanfalseChecked state.
labelstring—The thing that becomes true when checked. Default slot overrides.
hintstring—Second line (checkbox__h), wired with aria-describedby.
indeterminatebooleanfalseSet as a property on the input, for a partly checked parent.
disabledbooleanfalseSay why in the hint.
invalidbooleanfalsearia-invalid on the box.
value / namestring—Native form attributes.

EcoCheckboxGroup

NameTypeDefaultDescription
v-model(string | number)[][]The checked values.
optionsEcoOption[]—{ label, value, hint?, disabled? }
label / required——The legend (field__l) and its req mark.
rowbooleanfalseShort options side by side (checkgroup--row).
hint / errorstring—One line under the group; the error marks every box invalid.
disabled / name——Applied to every box.