2.4.11 Design — the `DatePicker` calendar component
Estimate: 45m
The design for a design-system calendar date-picker. The issue Due-date fields (create modal 2.3.3 / edit form 2.3.6 / detail core-fields rail 2.4.2) currently fall back to the native <input type="date"> — its FIELD now uses the Input primitive, but the native browser CALENDAR POPUP is OS chrome and doesn't match the design system. This designs the replacement so 2.4.12 isn't improvising UI (the design gate — there is no calendar in the system today). Produce, under design/work-items/, a datepicker.mock.html (built from the live design system — components/ui/* + --el-* tokens, so the coding agent composes the same primitives) + a design-notes.md section, covering:
- The trigger — an
Input-styled field showing the selected date (formatted likeformatDate→ "Jun 4, 2026") or a placeholder, with a calendar glyph, and a Clear affordance (Due date is nullable). - The calendar popover (anchored via the
Popoverprimitive): the month/year caption + prev/next-month nav, the weekday header row, and the day grid — with the selected day, today, hover, focused, and disabled day states all specified through--el-*tokens (AA-safe, finding #35; selection not conveyed by colour alone). - The placeholder / cleared state.
- A documented keyboard model for 2.4.12: arrows move days, PageUp/Down change months, Home/End jump to week start/end, Enter selects, Esc closes.
Mirror the prior design subtasks' output convention (1.0.5 / 2.4.7 / 2.4.8 / 2.5.7). Colour only through --el-*.
Acceptance criteria
- A
design/work-items/datepicker.mock.html+ adesign-notes.mdentry exist, naming the composing primitives (Popover+Input-styled trigger), copy, and every day-cell state (selected / today / hover / focus / disabled). - Trigger, open calendar, and placeholder/cleared states are all drawn (multi-panel); colour flows only through
--el-*; AA-safe. - The keyboard interaction model is documented for the code subtask to implement.
Context refs
design/work-items/relationships.mock.html(2.4.7) — the in-repo HTML-mockup convention to mirrorcomponents/ui/Popover.tsx+Input.tsx+Combobox.tsx— the anchored-popover + field chrome to composeapp/globals.css--el-*tiers + the/tokensroute convention