Checkbox
Checkbox, alebo tiež začiarkavacie políčko, je element, ktorý umožňuje používateľom vybrať jednu alebo viac možností z množiny. Kliknutím na checkbox zmeníte jeho stav na true
alebo false
.
Základné použitie
Indeterminate checkbox
Po pridaní atribútu indeterminate
sa zobrazí checkbox, ktorého predvolený stav je neutrálny, tzn. ani true
ani false
.
Variant
Pridaní atribútu variant
s hodnotou circle
zobrazíte checkbox v okrúhlom tvare.
Atribúty a Vlastnosti
checked
Description | If true , the default state of the checkbox is changed to true |
Attribute | checked |
Type | boolean |
Default | false |
color
Description | Specifies the background color of the checkbox. The default options are "primary" , "secondary" , "tertiary" , "success" , "warning" , "danger" , "light" , "medium" , and "dark" . For more information, go to: theming. |
Attribute | color |
Type | "danger." | "primary" | "success" | "neutral" | "complete" | "warning" | string | undefined |
Default | undefined |
disabled
Description | If true , the checkbox cannot be interacted with |
Attribute | disabled |
Type | boolean |
Default | false |
indeterminate
Description | If true , displays a checkbox whose default state is neutral. |
Attribute | indeterminate |
Type | boolean |
Default | false |
Option
Description | If true , the appearance of the checkbox is changed to round. |
Attribute | Option |
Type | "circle" |
Default | undefined |
Eventy
No events available for this component.
Metódy
No public methods available for this component.
CSS Shadow Parts
No CSS shadow parts available for this component.
CSS Custom Vlastnosti
Name | Description |
---|---|
--wj-checkbox-height | Specifies the minimum height of the checkbox |
--wj-checkbox-margin-bottom | Size of the outer bottom edge |
--wj-checkbox-margin-inline | Size of outer edges left and right |
--wj-checkbox-margin-top | Size of the outer upper edge |
--wj-checkbox-width | Specifies the minimum width of the checkbox |
Sloty
No slots available for this component.