Lab

Schedule

Slant / Controls

A “Schedule a review” form: a DatePicker from today on, a segmented TimeField and two Selects, checked when you submit and read back as one sentence.

The theme follows the link: share a page with ?theme=moon.

Usage

  • Each control sits in a <Field>: a DatePicker with min set to today, a TimeField with minuteStep={15}, and Selects for the duration (default 30 minutes) and the repeat. The field names each one and wires its description and error.
  • All four are controlled: the date is a local-midnight Date or null, the start a 24-hour "HH:mm" string or null, the selects strings. Each name submits through a hidden input: 2026-11-03, 14:30, 30, weekly.
  • The form is noValidate: Schedule checks the date and the time, turns the failing Fields invalid, and moves focus to the first, the date input or the time’s first segment. A date the picker refused (not a date, or before today) fails too.
  • Once booked, the status line reads it back ("Review scheduled for Tuesday, November 3 at 2:30 PM for 30 minutes, every week.") and Change returns to the form with everything kept.

Keyboard

Tabmoves through the date, its calendar button, the time’s segments, the two selects and Schedule
Digitstype a date, or the hour and the minute, which move on by themselves
Alt + ↓opens the calendar from the date input; the arrows move by day and week, Enter picks
↑ / ↓steps the focused time segment (minutes by 15), or opens a select and moves through it
A / Psets AM or PM on the time
Enter / Spaceopens a select, or chooses its highlighted option
Escapecloses the calendar or a list without choosing

Accessibility

  • Each control is named by its Field label: the date input through for, the time’s group and the selects through aria-labelledby. An error joins aria-describedby only while it shows, and its control is aria-invalid.
  • A status region counts the fields that need attention, then reads the booking back; focus moves to the first problem, or to Change.
  • The selects keep focus on their button and point at the highlighted option with aria-activedescendant; the calendar takes focus while it is open and hands it back to its button.

Schedule in React and SwiftUI.

Source

The React tab is the component’s real source; the SwiftUI tab is its twin in TUTTNKit.