# KptDatepicker (kpt-datepicker) Picking a date/time with a custom calendar (CDK Overlay), Signal Forms. The granularity comes from `selectionMode`: date (the default), month+year, year, month, date+time, time only. The panel is a stack of views - **decade -> years -> months -> days**: clicking a cell goes one level down, clicking the title goes one level up. The starting level is set by `startView` - for a date of birth use `startView="decade"` (decade -> year -> month -> day, four clicks instead of hundreds of arrow presses). The time is picked on a clock dial (two stages: hours -> minutes, click or drag), in 12/24h format. Display follows `displayFormat` ('pl'/'iso'/'locale'). The week starts by the language (see below), today is marked, min/max range supported. Requires the CDK overlay styles: `import '@angular/cdk/overlay-prebuilt.css';` Import: `import { KptDatepicker } from '@konce-pt/angular';` ## Usage ## Inputs - `value`: model; `minDate`/`maxDate`: string|null; `placeholder`: string - `selectionMode`: 'date' | 'monthYear' | 'year' | 'month' | 'datetime' | 'time' (default 'date'). The value format depends on the mode: 'YYYY-MM-DD' / 'YYYY-MM' / 'YYYY' / 'MM' / 'YYYY-MM-DDTHH:mm' (datetime) / 'HH:mm' (time). - `startView`: 'day' | 'month' | 'year' | 'decade' | null (default null) - the level the panel opens at. `null` = the level at which the mode commits a value: 'day' for 'date'/'datetime', 'month' for 'monthYear'/'month', 'year' for 'year'. It will not go below that level - `startView="day"` in 'year' mode is raised to 'year'. The 'month' mode stays on 'month' (the value is just 'MM', there is nothing to navigate), and the 'time' mode ignores the input. - `hourFormat`: 12 | 24 (default 24) - an AM/PM dial (12) or one with a 13-00 ring (24); the value is always 24h. - `minuteStep`: number (default 1) - minute snapping on the dial. - `monthDisplay`: 'long' | 'number' (default 'long') - in 'month' mode and in month labels: as a word (January) or a number (01) - `displayFormat`: 'pl' | 'iso' | 'locale' (default 'pl') - the display format and the default placeholder - `disabled`/`invalid`/`touched`: boolean; the `touch` output. - `open`: model (two-way `[(open)]`, the `(openChange)` output) - the calendar state. It lets you open it from outside and know when the user is done choosing - that is what inline editing in `kpt-data-table` does, see `data-table/llms.txt`. `touch` fires when the panel closes and when focus leaves the closed trigger; focus moving into the calendar does not count as leaving. - `ariaLabel`: string|null - the accessible name when no `