ui/chip
Types
Messages for chip keyboard navigation
pub type Msg {
MoveNext
MovePrev
MoveFirst
MoveLast
Remove
Activate
}
Constructors
-
MoveNext -
MovePrev -
MoveFirst -
MoveLast -
Remove -
Activate
Values
pub fn chip(
attributes: List(attribute.Attribute(a)),
children: List(element.Element(a)),
) -> element.Element(a)
pub fn chip_group(
label: String,
attributes: List(attribute.Attribute(a)),
children: List(element.Element(a)),
) -> element.Element(a)
pub fn icon() -> attribute.Attribute(a)
pub fn keymap(key_event: keyboard.KeyEvent) -> option.Option(Msg)
Keymap for chip group keyboard navigation
Keyboard interactions:
- Arrow keys: Navigate between chips
- Delete: Remove chip
- Enter/Space: Activate chip
- Home: First chip
- End: Last chip
Follows WAI-ARIA Tag Group pattern.
pub fn size(s: Size) -> attribute.Attribute(a)
pub fn variant(v: Variant) -> attribute.Attribute(a)