Action chips offer actions related to primary content. They should appear dynamically and contextually in a UI.
An alternative to action chips are buttons, which should appear persistently and consistently.
import Material.Chip.Action as ActionChip
import Material.ChipSet.Action as ActionChipSet
type Msg
= Clicked String
main =
ActionChipSet.chipSet []
[ ActionChip.chip
(ActionChip.config
|> ActionChip.setOnClick Clicked "Chip One"
)
"Chip One"
, ActionChip.chip ActionChip.config "Chip Two"
]Default configuration of an action chip
Specify a message when the user clicks on a chip
Specify whether the chip displays an icon
Specify additional attributes
Action chip view function
Action chip type
Configuration of an action chip