# m3e/autocomplete

Autocomplete is enhances a text input with suggested options.

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

         DO NOT EDIT

# Types

## AutoActivate

</>

AutoActivate is whether the first option should be automatically activated.

    pub type AutoActivate {
      IsAutoActivate
      IsNotAutoActivate
    }

### Constructors

-     IsAutoActivate

-     IsNotAutoActivate

## Autocomplete

opaque </>

Autocomplete is a View Model for this component

## Fields:

- auto_activate: Whether the first option should be automatically activated.
- case_sensitive: Whether filtering is case sensitive.
- filter: Mode in which to filter options.
- hide_selection_indicator: Whether to hide the selection indicator.
- hide_loading: Whether to hide the menu when loading options.
- hide_no_data: Whether to hide the menu when there are no options to show.
- loading: Whether options are being loaded.
- loading_label: The text announced and presented when loading options.
- no_data_label: The text announced and presented when no options are available for the current term.
- panel_class: Class or list of classes to be applied to the autocomplete’s overlay panel.
- required: Whether the user is required to make a selection when interacting with the autocomplete.
- results_label: The text announced when available options change for the current term.
- for: The identifier of the interactive control to which this element is attached.

    pub opaque type Autocomplete

## CaseSensitive

</>

CaseSensitive is whether filtering is case sensitive.

    pub type CaseSensitive {
      IsCaseSensitive
      IsNotCaseSensitive
    }

### Constructors

-     IsCaseSensitive

-     IsNotCaseSensitive

## Config

</>

Config is a public record for configuring this component.

    pub type Config {
      Config(
        auto_activate: AutoActivate,
        case_sensitive: CaseSensitive,
        filter: autocomplete_filter_mode.AutocompleteFilterMode,
        hide_selection_indicator: HideSelectionIndicator,
        hide_loading: HideLoading,
        hide_no_data: HideNoData,
        loading: Loading,
        loading_label: String,
        no_data_label: String,
        panel_class: String,
        required: Required,
        results_label: String,
        for: option.Option(String),
      )
    }

### Constructors

-     Config(
        auto_activate: AutoActivate,
        case_sensitive: CaseSensitive,
        filter: autocomplete_filter_mode.AutocompleteFilterMode,
        hide_selection_indicator: HideSelectionIndicator,
        hide_loading: HideLoading,
        hide_no_data: HideNoData,
        loading: Loading,
        loading_label: String,
        no_data_label: String,
        panel_class: String,
        required: Required,
        results_label: String,
        for: option.Option(String),
      )

## HideLoading

</>

HideLoading is whether to hide the menu when loading options.

    pub type HideLoading {
      IsHideLoading
      IsNotHideLoading
    }

### Constructors

-     IsHideLoading

-     IsNotHideLoading

## HideNoData

</>

HideNoData is whether to hide the menu when there are no options to show.

    pub type HideNoData {
      IsHideNoData
      IsNotHideNoData
    }

### Constructors

-     IsHideNoData

-     IsNotHideNoData

## HideSelectionIndicator

</>

HideSelectionIndicator is whether to hide the selection indicator.

    pub type HideSelectionIndicator {
      IsHideSelectionIndicator
      IsNotHideSelectionIndicator
    }

### Constructors

-     IsHideSelectionIndicator

-     IsNotHideSelectionIndicator

## Loading

</>

Loading is whether options are being loaded.

    pub type Loading {
      IsLoading
      IsNotLoading
    }

### Constructors

-     IsLoading

-     IsNotLoading

## Required

</>

Required is whether the user is required to make a selection when interacting with the autocomplete.

    pub type Required {
      IsRequired
      IsNotRequired
    }

### Constructors

-     IsRequired

-     IsNotRequired

## Slot

</>

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

    pub type Slot {
      Loading
      NoData
    }

### Constructors

-     Loading

-     NoData

# Values

## auto_activate

</>

    pub fn auto_activate(
      record: Autocomplete,
      auto_activate: AutoActivate,
    ) -> Autocomplete

auto_activate sets the value of auto_activate for this Autocomplete.

## case_sensitive

</>

    pub fn case_sensitive(
      record: Autocomplete,
      case_sensitive: CaseSensitive,
    ) -> Autocomplete

case_sensitive sets the value of case_sensitive for this Autocomplete.

## default_auto_activate

</>

    pub const default_auto_activate: AutoActivate

## default_case_sensitive

</>

    pub const default_case_sensitive: CaseSensitive

## default_config

</>

    pub fn default_config() -> Config

default_config is the default configuration for this component.

## default_filter

</>

    pub const default_filter: autocomplete_filter_mode.AutocompleteFilterMode

## default_for

</>

    pub const default_for: option.Option(String)

## default_hide_loading

</>

    pub const default_hide_loading: HideLoading

## default_hide_no_data

</>

    pub const default_hide_no_data: HideNoData

## default_hide_selection_indicator

</>

    pub const default_hide_selection_indicator: HideSelectionIndicator

## default_loading

</>

    pub const default_loading: Loading

## default_loading_label

</>

    pub const default_loading_label: String

## default_no_data_label

</>

    pub const default_no_data_label: String

## default_panel_class

</>

    pub const default_panel_class: String

## default_required

</>

    pub const default_required: Required

## default_results_label

</>

    pub const default_results_label: String

## filter

</>

    pub fn filter(
      record: Autocomplete,
      filter: autocomplete_filter_mode.AutocompleteFilterMode,
    ) -> Autocomplete

filter sets the value of filter for this Autocomplete.

## for

</>

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

for sets the value of for for this Autocomplete.

## from_config

</>

    pub fn from_config(config: Config) -> Autocomplete

from_config creates a new Autocomplete from the given configuration.

## hide_loading

</>

    pub fn hide_loading(
      record: Autocomplete,
      hide_loading: HideLoading,
    ) -> Autocomplete

hide_loading sets the value of hide_loading for this Autocomplete.

## hide_no_data

</>

    pub fn hide_no_data(
      record: Autocomplete,
      hide_no_data: HideNoData,
    ) -> Autocomplete

hide_no_data sets the value of hide_no_data for this Autocomplete.

## hide_selection_indicator

</>

    pub fn hide_selection_indicator(
      record: Autocomplete,
      hide_selection_indicator: HideSelectionIndicator,
    ) -> Autocomplete

hide_selection_indicator sets the value of hide_selection_indicator for this Autocomplete.

## loading

</>

    pub fn loading(
      record: Autocomplete,
      loading: Loading,
    ) -> Autocomplete

loading sets the value of loading for this Autocomplete.

## loading_label

</>

    pub fn loading_label(
      record: Autocomplete,
      loading_label: String,
    ) -> Autocomplete

loading_label sets the value of loading_label for this Autocomplete.

## new

</>

    pub fn new() -> Autocomplete

new creates a new Autocomplete with the default configuration.

## no_data_label

</>

    pub fn no_data_label(
      record: Autocomplete,
      no_data_label: String,
    ) -> Autocomplete

no_data_label sets the value of no_data_label for this Autocomplete.

## panel_class

</>

    pub fn panel_class(
      record: Autocomplete,
      panel_class: String,
    ) -> Autocomplete

panel_class sets the value of panel_class for this Autocomplete.

## render

</>

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

render creates a Lustre Element for a Autocomplete

## 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 Autocomplete Config

## required

</>

    pub fn required(
      record: Autocomplete,
      required: Required,
    ) -> Autocomplete

required sets the value of required for this Autocomplete.

## results_label

</>

    pub fn results_label(
      record: Autocomplete,
      results_label: String,
    ) -> Autocomplete

results_label sets the value of results_label for this Autocomplete.

## slot

</>

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

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

✨