Props API (Reference)

The TimePicker component offers a variety of props to control its behavior, appearance, and returned values. Below is a detailed breakdown of each prop and its default value.

PropTypeDefaultDescription
onTimeChange(time: string, isValid: boolean) => voidundefinedCallback fired when the selected time changes.
placeholderstringauto-generatedCustom placeholder text for the input.
valuestring | number | Date | nullundefinedControlled value of the time picker.
returnType"string" | "number" | "Date"auto-detectedFormat of the returned value.
setValue(value: any) => voidvalue => valueSetter for the controlled value.
iconReactNode<ClockIcon />Custom icon to display inside the input.
cancelButtonTextstring"Cancel"Text for the Cancel button.
confirmButtonTextstring"OK"Text for the OK button.
idstring"arc_timepicker"Unique ID for the input element.
classNamestring""Custom CSS classes for the wrapper.
classNamesobjectsee belowCustom class names for internal elements (wrapper, input, lists, buttons, etc.).
clockClassNamesobjectsee belowCustom class names for clock elements (clock, hand, numbers, etc.).

The classNames prop accepts an object with the following keys: wrapper, modeWrapper, modeButtons, modeButtonHour, modeButton, modeButtonMinute, formatButtons, formatButton, formatActiveButton, contentWrapper, content, times, time, timeActive, timesCenter, timesCenterPoint, handle, modeDivider — each key lets you override the respective element’s styling.