m3e/collapsible
Collapsible is a container used to expand and collapse content.
This file was generated by m3e/generator
DO NOT EDIT
Types
Collapsible is a View Model for this component
Fields:
- open: Whether content is visible.
- orientation: Orientation of collapsible content.
- no_animate: Whether to disable animation.
pub opaque type Collapsible
Config is a public record for configuring this component.
pub type Config {
Config(
open: Open,
orientation: collapsible_orientation.CollapsibleOrientation,
no_animate: NoAnimate,
)
}
Constructors
-
Config( open: Open, orientation: collapsible_orientation.CollapsibleOrientation, no_animate: NoAnimate, )
NoAnimate is whether to disable animation.
pub type NoAnimate {
IsNoAnimate
IsNotNoAnimate
}
Constructors
-
IsNoAnimate -
IsNotNoAnimate
Values
pub fn default_config() -> Config
default_config is the default configuration for this component.
pub const default_no_animate: NoAnimate
pub const default_open: Open
pub const default_orientation: collapsible_orientation.CollapsibleOrientation
pub fn from_config(config: Config) -> Collapsible
from_config creates a new Collapsible from the given configuration.
pub fn no_animate(
record: Collapsible,
no_animate: NoAnimate,
) -> Collapsible
no_animate sets the value of no_animate for this Collapsible.
pub fn open(record: Collapsible, open: Open) -> Collapsible
open sets the value of open for this Collapsible.
pub fn orientation(
record: Collapsible,
orientation: collapsible_orientation.CollapsibleOrientation,
) -> Collapsible
orientation sets the value of orientation for this Collapsible.
pub fn render(
model: Collapsible,
attributes: List(attribute.Attribute(msg)),
children: List(element.Element(msg)),
) -> element.Element(msg)
render creates a Lustre Element for a Collapsible
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 Collapsible Config