Skip to content

Reference

an-date-picker

A date, a time or both, through whatever each platform puts up for it.

UIDatePicker on iOS, NSDatePicker on the Mac, a SwiftUI DatePicker on the watch. On Android it is the system dialog — Material’s date and time pickers are dialogs, not inline controls, and putting an inline one there would be inventing a control the platform does not have.

Not on tvOS. value takes a Date or milliseconds; (change) reports milliseconds.

iOS · iPadOS Android macOS tvOS visionOS watchOS Wear OS
iOS · iPadOS Android macOS watchOS
UIDatePicker system dialog NSDatePicker DatePicker
Prop Type Default
value number | Date | null null
mode 'date' | 'time' | 'dateAndTime' | null 'date'
Output Payload
(change) { value: number }
<an-date-picker
[value]="departure()"
[mode]="'dateAndTime'"
(change)="departure.set(new Date($event.value))" />

Every primitive also carries the base props — background, border, opacity, the transforms, animate, the accessibility contract — and every gesture. See Components for the full base, Events for the payloads.