PhoenixKitWeb.Components.Core.Select (phoenix_kit v1.7.113)

Copy Markdown View Source

Provides a default select UI component.

Summary

Functions

select(assigns)

Attributes

  • field (Phoenix.HTML.FormField)
  • id (:any) - Defaults to nil.
  • name (:any)
  • label (:string) - Defaults to nil.
  • value (:any)
  • options (:list)
  • multiple (:boolean) - Defaults to false.
  • prompt (:string) - Defaults to nil.
  • errors (:list) - Defaults to [].
  • class (:any) - extra classes merged onto the daisyUI <label class="select"> wrapper — use this for daisyUI modifiers like select-sm, select-primary, or project-specific focus styles like transition-colors focus-within:select-primary. Defaults to nil.
  • Global attributes are accepted. Supports all globals plus: ["autocomplete", "cols", "maxlength", "disabled", "placeholder", "readonly", "required", "rows"].