Skip to main content

upp-time

A time selector component that opens a modal with:

  • up/down controls for hour and minute
  • manual typing in each field
  • optional vertical swipe to change values faster

It is designed for touch-first flows and supports Angular Reactive Forms through ControlValueAccessor.

When to Use

  • You need a reusable HH:mm picker with large typography.
  • You want both tactile controls (buttons/swipe) and direct text editing.
  • You need form integration with formControlName.

Demo

Source Code

<ion-item lines="none" [formGroup]="form">
<upp-time
formControlName="time"
title="Start time"
placeholder="HH:mm"
[step]="5"
[swipeEnabled]="swipeEnabled"
[swipeThreshold]="12"
></upp-time>
</ion-item>

API Reference

UppTimeComponent (upp-time, alias upp-time-picker)

PropertyTypeDefaultDescription
formControlNamestring''Form control name in a parent FormGroup.
disabledbooleanfalseDisables opening the picker.
placeholderstring''Placeholder shown when no time is selected.
titlestring''Title shown in trigger and modal header.
iconstring'time-outline'Ionicon name shown on the trigger button.
minstring | nullnullMinimum allowed time (HH:mm).
maxstring | nullnullMaximum allowed time (HH:mm).
stepnumber1Minute increment/decrement step.
swipeEnabledbooleantrueEnables vertical swipe for fast changes.
swipeThresholdnumber14Vertical pixels required per swipe step.

Outputs

EventPayloadDescription
Changedstring | nullEmitted when the selected time changes.