Time Picker
A configurable time picker with 12/24 hour modes, seconds, custom step increments, and an inline variant.
Basic Usage
Default Time Picker
24-hour format by default. Type directly or pick from the dropdown.
import { TimePicker } from 'fluxo-ui';
const [time, setTime] = useState<string | null>('09:30');
<TimePicker value={time} onChange={(v) => setTime(v as string | null)} />
<TimePicker defaultValue="14:45" />
<TimePicker placeholder="Meeting time" />Formats
12/24 Hour & Seconds
Toggle between 12-hour and 24-hour clocks, and optionally include seconds.
<TimePicker defaultValue="14:30" />
<TimePicker defaultValue="14:30" format12 />
<TimePicker defaultValue="14:30:45" showSeconds />
<TimePicker defaultValue="14:30:45" format12 showSeconds />Step Increments
Step Increments
Limit the options in each column with hourStep, minuteStep, and secondStep. Great for appointment slots.
<TimePicker defaultValue="09:00" minuteStep={15} />
<TimePicker defaultValue="09:00" minuteStep={5} />
<TimePicker defaultValue="09:00:00" showSeconds secondStep={10} />Sizes
Sizes
Three trigger sizes for different form densities.
<TimePicker size="sm" defaultValue="09:30" />
<TimePicker size="md" defaultValue="09:30" />
<TimePicker size="lg" defaultValue="09:30" />Confirm & Inline
Confirm & Inline
Require explicit confirmation before committing, or render the panel inline without a trigger.
<TimePicker defaultValue="12:00" showConfirm autoClose={false} />
<TimePicker defaultValue="12:00" showNow showConfirm />
<TimePicker variant="inline" defaultValue="12:00" format12 />Import
import { TimePicker } from 'fluxo-ui';
import type { TimePickerProps, TimePickerValue } from 'fluxo-ui';Props
valueDate | string | TimeValue | nullControlled time value. Accepts Date, string (HH:mm[:ss]), or object.
valueDate | string | TimeValue | nullControlled time value. Accepts Date, string (HH:mm[:ss]), or object.
defaultValueDate | string | TimeValue | nullInitial value for uncontrolled usage.
defaultValueDate | string | TimeValue | nullInitial value for uncontrolled usage.
format12boolean"false"Use 12-hour clock with AM/PM column.
format12boolean"false"Use 12-hour clock with AM/PM column.
showSecondsboolean"false"Include a seconds column.
showSecondsboolean"false"Include a seconds column.
hourStepnumber"1"Step between available hour values.
hourStepnumber"1"Step between available hour values.
minuteStepnumber"1"Step between available minute values.
minuteStepnumber"1"Step between available minute values.
secondStepnumber"1"Step between available second values.
secondStepnumber"1"Step between available second values.
valueType'date' | 'string' | 'object'"'string'"Shape of the value passed to onChange.
valueType'date' | 'string' | 'object'"'string'"Shape of the value passed to onChange.
size'sm' | 'md' | 'lg'"'md'"Trigger size.
size'sm' | 'md' | 'lg'"'md'"Trigger size.
variant'input' | 'inline'"'input'"Trigger style, or render the panel inline.
variant'input' | 'inline'"'input'"Trigger style, or render the panel inline.
disabledboolean"false"Disable interaction.
disabledboolean"false"Disable interaction.
readOnlyboolean"false"Display-only mode.
readOnlyboolean"false"Display-only mode.
clearableboolean"true"Show a clear button when a value is set.
clearableboolean"true"Show a clear button when a value is set.
placeholderstring"'Select time'"Placeholder shown when empty.
placeholderstring"'Select time'"Placeholder shown when empty.
showNowboolean"true"Show the Now shortcut button.
showNowboolean"true"Show the Now shortcut button.
showConfirmboolean"false"Require an explicit OK click to commit.
showConfirmboolean"false"Require an explicit OK click to commit.
autoClosebooleanClose the popover immediately on selection. Defaults to the opposite of showConfirm.
autoClosebooleanClose the popover immediately on selection. Defaults to the opposite of showConfirm.
onChange(value: Date | string | TimeValue | null) => voidCalled when the time changes.
onChange(value: Date | string | TimeValue | null) => voidCalled when the time changes.
onOpenChange(open: boolean) => voidCalled when the popover opens or closes.
onOpenChange(open: boolean) => voidCalled when the popover opens or closes.
Features
12/24 Hour
Full support for 12-hour clocks with AM/PM column or straight 24-hour mode.
Step Increments
Limit minute or second columns to appointment-friendly increments like 5, 15, or 30.
Flexible Values
Accepts Date objects, HH:mm strings, or plain time objects and emits the same.
Inline Or Popover
Render as a compact input with a portal popover, or inline directly in the page.