m3e/fab_menu

Types

FabMenu ia a menu, opened from a floating action button (FAB), used to display multiple related actions

Fields:

  • id: the id of the menu, linked to the FabMenuTrigger
  • variant: The appearance variant of the menu
pub opaque type FabMenu

Variant is the appearance variant of the menu

pub type Variant {
  Primary
  Secondary
  Tertiary
}

Constructors

  • Primary
  • Secondary
  • Tertiary

Values

pub const default_variant: Variant
pub fn id(f: FabMenu, id: String) -> FabMenu

id sets the id field

pub fn new(id: String) -> FabMenu

new creates a new FabMenu

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

render creates a Lustre Element from a FabMenu

Parameters:

  • f: a FabMenu
  • attributes: a list of additional Attributes
  • children: a list of child Elements
pub fn variant(f: FabMenu, variant: Variant) -> FabMenu

variant sets the variant field

Search Document