Tesserae

TimePicker

Description

The TimePicker component provides a native browser control for selecting a time. It stores the selected value as a DateTimeOffset and is useful for schedules, reminders, cut-off times, and other time-only inputs.

Usage

Create a TimePicker() with or without an initial value. You can combine it with min/max validation, browser fallback attributes, and change handlers.

API reference

class

TimePicker

public class TimePicker : MomentPickerBase<TimePicker, DateTimeOffset>

A TimePicker component that allows users to select a time using a native HTML time input.

Constructors

Constructor
TimePicker
public TimePicker(DateTimeOffset? time = null) : base("time", time.HasValue ? FormatDateTime(time.Value) : string.Empty)

Initializes a new instance of the TimePicker class.

Parameters

time
The initial time value.

Properties

Property
TimePicker.Time
public DateTimeOffset Time

Gets the selected time as a DateTimeOffset.

Methods

Method
TimePicker.WithBrowserFallback
public TimePicker WithBrowserFallback()

Adds the pattern attribute to the underlying input element for graceful degradation when retrieving the user selected value on older browsers.

Returns

The current instance of the type.

See also

Referenced by

© 2026 Tesserae. All rights reserved.