Date/time pickers — Fluxon-compatible API composed from LanternUI primitives.
<.date_picker field={@form[:due]} label="Due date" />
<.date_time_picker field={@form[:starts_at]} precision={:millisecond} />
<.time_picker name="alarm" value="08:45:00.000" />The trigger is a segmented, directly-editable datetime_field (keyboard-first:
type straight into the segments); the calendar popover is for mouse users and
APG-grid keyboard navigation. time_picker is segments-only (no popover) —
a LanternUI extension Fluxon doesn't offer.
Value contract
The hidden input submits the canonical string (YYYY-MM-DD,
HH:MM:SS.mmm, YYYY-MM-DDTHH:MM:SS.mmm); empty = null. value accepts
that string or a Date / Time / NaiveDateTime / DateTime struct.
Fluxon compatibility
Attrs mirror Fluxon's pickers: field/name/value, label, sublabel,
description, help_text, errors, size, disabled, min/max,
week_start, and the inner/outer_prefix/suffix slots. display_format /
time_format are accepted for drop-in compatibility but not yet honored —
v1 renders the fixed segmented US format (m/d/yyyy, h:mm AM).
Summary
Functions
Date-only picker (YYYY-MM-DD).
Date + time picker (YYYY-MM-DDTHH:MM:SS.mmm).
Time-only picker (HH:MM:SS.mmm, segments only — no popover).
Functions
Date-only picker (YYYY-MM-DD).
Attributes
id(:any) - Defaults tonil.label(:string) - Defaults tonil.sublabel(:string) - Defaults tonil.description(:string) - Defaults tonil.help_text(:string) - Defaults tonil.class(:any) - Defaults tonil.size(:string) - Defaults to"md". Must be one of"xs","sm","md","lg", or"xl".disabled(:boolean) - Defaults tofalse.field(Phoenix.HTML.FormField) - Defaults tonil.value(:any) - Defaults tonil.name(:any) - Defaults tonil.errors(:list) - Defaults to[].min(:string) - Defaults tonil.max(:string) - Defaults tonil.week_start(:integer) - Defaults to0. Must be one of0,1,2,3,4,5, or6.display_format(:string) - accepted for Fluxon compat; not yet honored. Defaults tonil.- Global attributes are accepted.
Slots
inner_prefixouter_prefixinner_suffixouter_suffix
Date + time picker (YYYY-MM-DDTHH:MM:SS.mmm).
Attributes
id(:any) - Defaults tonil.label(:string) - Defaults tonil.sublabel(:string) - Defaults tonil.description(:string) - Defaults tonil.help_text(:string) - Defaults tonil.class(:any) - Defaults tonil.size(:string) - Defaults to"md". Must be one of"xs","sm","md","lg", or"xl".disabled(:boolean) - Defaults tofalse.field(Phoenix.HTML.FormField) - Defaults tonil.value(:any) - Defaults tonil.name(:any) - Defaults tonil.errors(:list) - Defaults to[].min(:string) - Defaults tonil.max(:string) - Defaults tonil.week_start(:integer) - Defaults to0. Must be one of0,1,2,3,4,5, or6.precision(:atom) - Defaults to:minute. Must be one of:minute,:second, or:millisecond.display_format(:string) - accepted for Fluxon compat; not yet honored. Defaults tonil.time_format(:string) - accepted for Fluxon compat; not yet honored. Defaults tonil.- Global attributes are accepted.
Slots
inner_prefixouter_prefixinner_suffixouter_suffix
Time-only picker (HH:MM:SS.mmm, segments only — no popover).
Attributes
id(:any) - Defaults tonil.label(:string) - Defaults tonil.sublabel(:string) - Defaults tonil.description(:string) - Defaults tonil.help_text(:string) - Defaults tonil.class(:any) - Defaults tonil.size(:string) - Defaults to"md". Must be one of"xs","sm","md","lg", or"xl".disabled(:boolean) - Defaults tofalse.field(Phoenix.HTML.FormField) - Defaults tonil.value(:any) - Defaults tonil.name(:any) - Defaults tonil.errors(:list) - Defaults to[].precision(:atom) - Defaults to:minute. Must be one of:minute,:second, or:millisecond.- Global attributes are accepted.
Slots
inner_prefixouter_prefixinner_suffixouter_suffix