Calendar
A calendar component with month/year modes, supporting selection, disabled dates, week numbers, and keyboard grid navigation; date descriptions use Intl.DateTimeFormat (locale-aware).
Basic Usage
Month view (mode=month)
Click a date to select it and dispatch oas-change; the title opens a month-selection panel for quick month jumps.
Year View
Year view (mode=year)
In year mode, selecting a month dispatches yyyy-MM.
Disabled Range
min / max limits
Disabled Callback
disabled-date (disable weekends)
disabledDate is passed in via a property callback (functions cannot be expressed in JSON).
Week Numbers
Show week numbers (show-week-number)
Events
oas-change event
API
Attributes
| Attribute | Description | Type | Default |
|---|---|---|---|
disabledDate | Disabled callback (property) | ((d: Date) => boolean) | null | — |
max | Selectable range (ISO dates) | string | — |
min | Selectable range (ISO dates) | string | — |
mode | month / year | string | month |
show-week-number | Show the ISO week number column | boolean | — |
value | Selected value (ISO) | string | — |
Events
| Event | Description |
|---|---|
oas-change | Selection change, detail: { value } |
Keyboard: ↑/↓/←/→ to move within the grid, Enter to select.