# m3e/tab

Tab is an interactive element that, when activated, presents an associated tab panel.

This file was generated: By: m3e/generator version 0.1.0 At: 2026-05-05T14:38:23+10:00

         DO NOT EDIT

# Types

## Config

</>

Config is a public record for configuring this component.

    pub type Config {
      Config(
        disabled: Disabled,
        for: option.Option(String),
        selected: Selected,
      )
    }

### Constructors

-     Config(
        disabled: Disabled,
        for: option.Option(String),
        selected: Selected,
      )

## Disabled

</>

Disabled is whether the element is disabled.

    pub type Disabled {
      IsDisabled
      IsNotDisabled
    }

### Constructors

-     IsDisabled

-     IsNotDisabled

## Selected

</>

Selected is whether the element is selected.

    pub type Selected {
      IsSelected
      IsNotSelected
    }

### Constructors

-     IsSelected

-     IsNotSelected

## Slot

</>

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

    pub type Slot {
      Icon
    }

### Constructors

-     Icon

## Tab

opaque </>

Tab is a View Model for this component

## Fields:

- disabled: Whether the element is disabled.
- for: The identifier of the interactive control to which this element is attached.
- selected: Whether the element is selected.

    pub opaque type Tab

# Values

## default_config

</>

    pub fn default_config() -> Config

default_config is the default configuration for this component.

## default_disabled

</>

    pub const default_disabled: Disabled

## default_for

</>

    pub const default_for: option.Option(String)

## default_selected

</>

    pub const default_selected: Selected

## disabled

</>

    pub fn disabled(record: Tab, disabled: Disabled) -> Tab

disabled sets the value of disabled for this Tab.

## for

</>

    pub fn for(record: Tab, for: option.Option(String)) -> Tab

for sets the value of for for this Tab.

## from_config

</>

    pub fn from_config(config: Config) -> Tab

from_config creates a new Tab from the given configuration.

## new

</>

    pub fn new() -> Tab

new creates a new Tab with the default configuration.

## render

</>

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

render creates a Lustre Element for a Tab

## render_config

</>

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

## selected

</>

    pub fn selected(record: Tab, selected: Selected) -> Tab

selected sets the value of selected for this Tab.

## slot

</>

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

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

✨