Time Picker
A native time selector with support for 12/24 hour formats.
Installation
Install the component
templui add timepickerAdd the JavaScript to your layout
@timepicker.Script() @popover.Script()Call this template in your base layout file (e.g., in the <head> section).
Examples
12h Format
With Label
With Custom Placeholder
With Selected Time
With Step Intervals
With Min/Max Range
With Form
Select a time from the dropdown.
Please select a time
API Reference
TimePicker
Time picker component for selecting time values with 12/24 hour format support.
| Name | Type | Default |
|---|---|---|
Unique identifier for the time picker element. | | - |
Additional CSS classes to apply to the time picker. | | - |
Additional HTML attributes to apply to the time picker element. | | - |
Name attribute for the hidden input field. | | - |
Selected time value. | | - |
Minimum selectable time. Times before this will be disabled. | | - |
Maximum selectable time. Times after this will be disabled. | | - |
Minute intervals for selection (e.g., 5, 10, 15, 30). Must be a divisor of 60. | | |
Whether to use 12-hour format (AM/PM) or 24-hour format. | | |
Label for AM period in 12-hour format. | | |
Label for PM period in 12-hour format. | | |
Placeholder text when no time is selected. | | |
Whether the time picker is disabled and non-interactive. | | |
Whether the time picker has an error state (applies error styling). | | |