Skip to content

Calendar

Overview

A full-featured calendar component built on CalendarRoot with optional month/year navigation dropdowns. Supports single and multiple date selection, date range constraints, and configurable heading layouts.

Theme entry: Calendar

Props

NameTypeRequiredDefaultDescription
iconOverrideObjectnullA partial icon registry ({ [componentName]: { [iconName]: { component, props } } }) merged with inherited and default icon entries; scopes icon overrides to this component and its descendants.
themeOverrideString|Object|ArraynullA partial theme object merged with the component's default theme; accepts a class string, class array, or theme object.
classstring|array|objectundefinedAdditional CSS classes to apply to the calendar root.
layoutstringundefinedThe heading layout style: "month-and-year", "month-only", "year-only", or default heading.
modelValueobjectundefinedThe currently selected date value (use with v-model).
defaultPlaceholderobjectundefinedThe default placeholder date shown when no date is selected.
placeholderobjectundefinedThe current placeholder date (use with v-model:placeholder).
localestringundefinedThe locale string used for date formatting.
minValueobjectundefinedThe minimum selectable date value.
maxValueobjectundefinedThe maximum selectable date value.
yearRangearrayundefinedAn explicit array of year date values to populate the year dropdown.
fixedWeeksbooleanundefinedWhether to always display a fixed number of weeks.
isDateDisabledfuncundefinedA function that returns true for dates that should be disabled.
isDateUnavailablefuncundefinedA function that returns true for dates that are unavailable.
numberOfMonthsnumberundefinedThe number of months to display at once.
pagedNavigationbooleanundefinedWhether to use paged navigation (advance by numberOfMonths at a time).
preventDeselectbooleanundefinedWhether to prevent deselecting an already-selected date.
weekStartsOnnumberundefinedThe day of the week the calendar starts on (0 = Sunday).
weekdayFormatstringundefinedThe format of weekday labels: "narrow", "short", or "long".
calendarLabelstringundefinedAn accessible label for the calendar.
disabledbooleanundefinedWhether the calendar is disabled.
readonlybooleanundefinedWhether the calendar is read-only.
initialFocusbooleanundefinedWhether to focus the calendar on mount.
multiplebooleanundefinedWhether multiple dates can be selected.

Slots

calendar-heading

Scoped slot.

Bindings

NameDescription
date
month
year

Events

NameDescription
update:modelValueEmitted when the value changes.
update:placeholderEmitted when the placeholder date changes.

Full event reference

Source

client/lib/controls/calendar/Calendar.vue

Documents matching: server v3.0.0a1.post1client v3.0.0-alpha.2