Joins inputs, addons, selects and buttons into one row with shared borders.
<.input_group>
<.input_group_addon>R$</.input_group_addon>
<.input name="amount" variant="plain" />
<.input_group_addon>,00</.input_group_addon>
</.input_group>
<.input_group label="Price" size="sm" errors={["must be positive"]}>
<.input_group_addon variant="filled">$</.input_group_addon>
<.input name="amount" variant="plain" size="sm" state="error" />
</.input_group>The row is a role="group" named by the caption (aria-labelledby; give each group an id
when two share a label). With errors (or state="error") every border of the row turns red,
and the row gets aria-invalid and an aria-describedby that points at the messages.
The group draws the shared border, so an input/1 inside it takes variant="plain".
Summary
Functions
Renders the row; label adds a caption above it, help and errors a line below.
A text or icon box at either end (or between the inputs) of an input_group.
Functions
Renders the row; label adds a caption above it, help and errors a line below.
Attributes
id(:string) - Defaults tonil.shape(:string) - Defaults to"rounded". Must be one of"rounded", or"pill".size(:string) - Defaults to"md". Must be one of"sm","md", or"lg".variant(:string) - Defaults to"outlined". Must be one of"outlined", or"filled".label(:string) - Defaults tonil.label_class(:any) - Defaults tonil.help(:string) - Defaults tonil.errors(:list) - Defaults to[].state(:string) - Defaults tonil.Must be one ofnil,"","success", or"error".wrapper_class(:any) - Defaults tonil.class(:any) - Defaults tonil.- Global attributes are accepted.
Slots
inner_block(required)
A text or icon box at either end (or between the inputs) of an input_group.
Attributes
variant(:string) - Defaults to"outline". Must be one of"outline", or"filled".size(:string) - Defaults to"md". Must be one of"sm","md", or"lg".class(:any) - Defaults tonil.- Global attributes are accepted.
Slots
inner_block(required)