Corex.List
(Corex v0.1.0-beta.3)
View Source
Flat selectable items for Combobox, Listbox, and Select.
Build items with Corex.List.new/1 or Corex.List.Item.new/1. Each row is a Corex.List.Item with required :label and optional :id (defaults to a monotonic list-<integer> from generate_id/0), :to, :redirect, :new_tab, :disabled, :group, and :meta.
When the parent sets redirect, selection can navigate using each item’s :to or id as destination; per-item :redirect is :href, :patch, :navigate, or false to opt out. With redirect enabled, the client runs single-select in Zag even if the form uses multiple.
Summary
Functions
Creates a list of List.Item structs from a list of attribute maps.
Functions
Creates a list of List.Item structs from a list of attribute maps.
Raises ArgumentError if items is not a list or contains invalid items.