m3e/callout

Callout is a supporting container used to present content with visual emphasis.

This file was generated by m3e/generator

     DO NOT EDIT

Types

Callout is a View Model for this component

Fields:

  • variant: The appearance variant of the callout.
  • shape: The shape of the callout.
pub opaque type Callout

Config is a public record for configuring this component.

pub type Config {
  Config(
    variant: callout_variant.CalloutVariant,
    shape: callout_shape.CalloutShape,
  )
}

Constructors

Slots are used in child elements to insert content into this component

pub type Slot {
  Icon
  Label
}

Constructors

  • Icon
  • Label

Values

pub fn default_config() -> Config

default_config is the default configuration for this component.

pub fn from_config(config: Config) -> Callout

from_config creates a new Callout from the given configuration.

pub fn new() -> Callout

new creates a new Callout with the default configuration.

pub fn render(
  model: Callout,
  attributes: List(attribute.Attribute(msg)),
  children: List(element.Element(msg)),
) -> element.Element(msg)

render creates a Lustre Element for a Callout

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 Callout Config

pub fn shape(
  record: Callout,
  shape: callout_shape.CalloutShape,
) -> Callout

shape sets the value of shape for this Callout.

pub fn slot(s: Slot) -> attribute.Attribute(msg)

slot returns a Lustre Attribute(msg) for the given slot name

pub fn variant(
  record: Callout,
  variant: callout_variant.CalloutVariant,
) -> Callout

variant sets the value of variant for this Callout.

✨ Search Document