AnyLumino
API referenceastryxinputs

TimeInput

Render an Astryx time input.

Astryx Props

JSON-safe TimeInput props forwarded to Astryx.

Supported Astryx props include:

  • label (string; required): Label text for the input (required for accessibility).
  • isLabelHidden (boolean): Visually hides the label while keeping it accessible to screen readers.
  • description (string): Description text displayed between the label and input.
  • isOptional (boolean): Shows an "(optional)" indicator next to the label. Mutually exclusive with isRequired.
  • isRequired (boolean): Marks the field as required and sets aria-required. Mutually exclusive with isOptional.
  • isDisabled (boolean): Disables the input and suppresses interactions.
  • value (ISOTimeString): Controlled time value in ISO format (HH:MM or HH:MM:SS).
  • onChange ((value: ISOTimeString or undefined) => void): Callback fired when the time changes. Receives undefined when the input is cleared.
  • changeAction ((value: ISOTimeString or undefined) => void or Promise<void>): Async action fired after onChange. Wrapped in a React transition to provide optimistic UI; triggers the loading spinner while pending.
  • isLoading (boolean): Puts the input into a loading state, displaying a spinner.
  • min (ISOTimeString): Minimum selectable time in ISO format. Values outside the range are rejected.
  • max (ISOTimeString): Maximum selectable time in ISO format. Values outside the range are rejected.
  • hasSeconds (boolean): Includes seconds in the time display and parsing.
  • hasClear (boolean): Shows a clear button when a value is set and the input is not disabled.
  • hourFormat ('12h' or '24h'): Controls the display format. '12h' shows AM/PM (e.g. '2:30 PM'); '24h' uses 24-hour notation (e.g. '14:30').
  • increment (number): Number of minutes to add or subtract when the user presses the up or down arrow key.
  • placeholder (string): Placeholder text shown when no time is selected. When the input is focused and empty, a format hint overrides this text.
  • size ('sm' or 'md' or 'lg'): Controls the height of the input element.
  • status (InputStatus): Status indicator that colors the border and displays an icon. When a message is provided it is rendered below the input.
  • labelTooltip (string): Tooltip text rendered as an info icon at the end of the label row.
  • xstyle (StyleXStyles): StyleX styles for layout customization (margins, positioning, sizing). Must be a stylex.create() value, not an inline style object like style={{}}.

Props typed as React nodes, render functions, event handlers, refs, or StyleX styles are documented for Astryx parity but cannot be serialized directly from Python unless the wrapper adapts them.

See Astryx component docs: https://astryx.atmeta.com/components/TimeInput.

Functions

constructor__init__(value=None, *, label='', disabled=False, min=None, max=None, seconds=None, clear=None, hour_format=None, increment=None, placeholder=None, size=None, **props) -> None
paramvaluestr | None
= None

Synchronized component value.

paramlabelstr
= ''

Visible or accessible label for the component.

paramdisabledbool
= False

Whether the input is disabled.

paramminstr | None
= None

Minimum ISO time.

parammaxstr | None
= None

Maximum ISO time.

paramsecondsbool | None
= None

Whether to include seconds.

paramclearbool | None
= None

Whether to show a clear button.

paramhour_formatstr | None
= None

Twelve- or twenty-four-hour display format.

paramincrementint | None
= None

Arrow-key minute increment.

paramplaceholderstr | None
= None

Placeholder text.

paramsizestr | None
= None

Input size.

parampropsAny
= {}

Returns

None

On this page