m3e/button_group
ButtonGroup is organizes buttons and adds interactions between them.
This file was generated: By: m3e/generator version 0.1.0 At: 2026-05-05T14:38:23+10:00
DO NOT EDIT
Types
ButtonGroup is a View Model for this component
Fields:
- multi: Whether multiple toggle buttons can be selected.
- size: The size of the group.
- variant: The appearance variant of the group.
pub opaque type ButtonGroup
Config is a public record for configuring this component.
pub type Config {
Config(
multi: Multi,
size: button_group_size.ButtonGroupSize,
variant: button_group_variant.ButtonGroupVariant,
)
}
Constructors
-
Config( multi: Multi, size: button_group_size.ButtonGroupSize, variant: button_group_variant.ButtonGroupVariant, )
Values
pub fn default_config() -> Config
default_config is the default configuration for this component.
pub const default_multi: Multi
pub const default_size: button_group_size.ButtonGroupSize
pub const default_variant: button_group_variant.ButtonGroupVariant
pub fn from_config(config: Config) -> ButtonGroup
from_config creates a new ButtonGroup from the given configuration.
pub fn multi(record: ButtonGroup, multi: Multi) -> ButtonGroup
multi sets the value of multi for this ButtonGroup.
pub fn render(
model: ButtonGroup,
attributes: List(attribute.Attribute(msg)),
children: List(element.Element(msg)),
) -> element.Element(msg)
render creates a Lustre Element for a ButtonGroup
pub fn render_config(
c: Config,
attributes: List(attribute.Attribute(msg)),
children: List(element.Element(msg)),
) -> element.Element(msg)
render_config creates a Lustre Element from a ButtonGroup Config
pub fn size(
record: ButtonGroup,
size: button_group_size.ButtonGroupSize,
) -> ButtonGroup
size sets the value of size for this ButtonGroup.
pub fn variant(
record: ButtonGroup,
variant: button_group_variant.ButtonGroupVariant,
) -> ButtonGroup
variant sets the value of variant for this ButtonGroup.