Date/month picker

The v-date-picker is stand-alone component that can be utilized in many existing Vuetify components. It offers the user a visual representation for selecting date/month.

Usage

Date pickers come in two orientation variations, portrait (default) and landscape. By default they are emitting input event when the day (for date picker) or month (for month picker), but with reactive prop they can update the model even after clicking year/month.

API

v-date-picker
Name
allowed-dates
Default
null
Type
function

Restricts which dates can be selected

Name
color
Default
undefined
Type
string

Applies specified color to the control - it can be the name of material color (for example success or purple) or css color (#033 or rgba(255, 0, 0, 0.5))

Name
dark
Default
false
Type
boolean

Applies the dark theme variant

Name
day-format
Default
null
Type
function

Allows you to customize the format of the day string that appears in the date table. Called with date (ISO 8601 string) arguments.

Name
disabled New in — v1.4
Default
false
Type
boolean

Disables interaction with the picker

Name
event-color
Default
warning
Type
array | function | object | string

Sets the color for event dot. It can be string (all events will have the same color) or object where attribute is the event date and value is boolean/color/array of colors for specified date or function taking date as a parameter and returning boolean/color/array of colors for that date

Name
events
Default
null
Type
array | function | object

Array of dates or object defining events or colors or function returning boolean/color/array of colors

Name
first-day-of-week
Default
0
Type
string | number

Sets the first day of the week, starting with 0 for Sunday.

Name
full-width
Default
false
Type
boolean

Forces 100% width

Name
header-color
Default
undefined
Type
string

Defines the header color. If not specified it will use the color defined by color prop or the default picker color

Name
header-date-format
Default
null
Type
function

Allows you to customize the format of the month string that appears in the header of the calendar. Called with date (ISO 8601 string) arguments.

Name
landscape
Default
false
Type
boolean

Orients picker horizontal

Name
light
Default
false
Type
boolean

Applies the light theme variant

Name
locale
Default
'en-us'
Type
string

Sets the locale. Accepts a string with a BCP 47 language tag.

Name
max
Default
undefined
Type
string

Maximum allowed date/month (ISO 8601 format)

Name
min
Default
undefined
Type
string

Minimum allowed date/month (ISO 8601 format)

Name
month-format
Default
null
Type
function

Formatting function used for displaying months in the months table. Called with date (ISO 8601 string) arguments.

Name
multiple New in — v1.2
Default
false
Type
boolean

Allow the selection of multiple dates

Name
next-icon
Default
'$vuetify.icons.next'
Type
string

Sets the icon for next month/year button

Name
no-title
Default
false
Type
boolean

Hide the picker title

Name
picker-date
Default
undefined
Type
string

Displayed year/month

Name
prev-icon
Default
'$vuetify.icons.prev'
Type
string

Sets the icon for previous month/year button

Name
reactive
Default
false
Type
boolean

Updates the picker model when changing months/years automatically

Name
readonly
Default
false
Type
boolean

Makes the picker readonly (doesnt't allow to select new date)

Name
scrollable
Default
false
Type
boolean

Allows changing displayed month with mouse scroll

Name
show-current
Default
true
Type
boolean | string

Toggles visibility of the current date/month outline or shows the provided date/month as a current

Name
show-week New in — v1.4
Default
false
Type
boolean

Toggles visibility of the week numbers in the body of the calendar

Name
title-date-format
Default
null
Type
function

Allows you to customize the format of the date string that appears in the title of the date picker. Called with date (ISO 8601 string) arguments.

Name
type
Default
'date'
Type
string

Determines the type of the picker - date for date picker, month for month picker

Name
value
Default
undefined
Type
array | string

Date picker model (ISO 8601 format, YY-mm-dd or YY-mm)

Name
weekday-format New in — v1.3
Default
null
Type
function

Allows you to customize the format of the weekday string that appears in the body of the calendar. Called with date (ISO 8601 string) arguments.

Name
width
Default
290
Type
number | string

The width of the content

Name
year-format
Default
null
Type
function

Allows you to customize the format of the year string that appears in the header of the calendar. Called with date (ISO 8601 string) arguments.

Name
year-icon
Default
undefined
Type
string

Sets the icon in the year selection button

Examples

Date pickers - Colors

Date picker colors can be set using the color and header-color props. If header-color prop is not provided header will use the color prop value.

Date pickers - In dialog and menu

When integrating a picker into a v-text-field, it is recommended to use the readonly prop. This will prevent mobile keyboards from triggering. To save vertical space, you can also hide the picker title.

Pickers expose a scoped slot that allow you to hook into save and cancel functionality. This will maintain an old value which can be replaced if the user cancels.

Date pickers - formatting date

If you need to display date in the custom format (different than YYYY-MM-DD) you need to use the formatting function.

Date pickers - formatting date using external libs

Formatting dates is possible also with external libs such as Moment.js or date-fns

Date pickers - Allowed dates

You can specify allowed dates using arrays, objects, and functions.

Date pickers - Mutiple

Date picker can now select multiple dates with the multiple prop. If using multiple then date picker expects its model to be an array.

Date pickers - Setting picker width

You can specify allowed the picker's width or make it full width.

Date pickers - birthday picker

Starting with year picker by default, resticting dates range and closing the picker menu after selecting the day make the perfect birthday picker.

Date pickers - react to displayed month/year change

You can watch the pickerDate which is the displayed month/year (depending on the picker type and active view) to perform some action when it changes.

Date pickers - Events

You can specify events using arrays, objects or functions. To change the default color of the event use event-color prop. Your events function or object can return an array of colors (material or css) in case you want to display multiple event indicators.

Date pickers - Internationalization

The date picker supports internationalization through the JavaScript Date object. Specify a BCP 47 language tag using the locale prop, and then set the first day of the week with the first-day-of-week prop.

Date pickers - icons

You can override the default icons used in the picker.

Date pickers - read only

Selecting new date could be disabled by adding readonly prop.

Date pickers - current date indicator

By default the current date is displayed using outline button - show-current prop allows you to remove the border or select different date to be displayed as the current one.

Month pickers

Month pickers come in two orientation variations, portrait (default) and landscape.

Month pickers - Colors

Month picker colors can be set using the color and header-color props. If header-color prop is not provided header will use the color prop value.

Month pickers - In dialog and menu

When integrating a picker into a v-text-field, it is recommended to use the readonly prop. This will prevent mobile keyboards from triggering. To save vertical space, you can also hide the picker title.

Pickers expose a scoped slot that allow you to hook into save and cancel functionality. This will maintain an old value which can be replaced if the user cancels.

Month pickers - Allowed months

You can specify allowed months using arrays, objects or functions.

Month pickers - Multiple

Month pickers can now select multiple months with the multiple prop. If using multiple then the month picker expects its model to be an array.

Month pickers - Setting picker width

You can specify allowed the picker's width or make it full width.

Month pickers - Internationalization

The month picker supports internationalization through the JavaScript Date object. Specify a BCP 47 language tag using the locale prop, and then set the first day of the week with the first-day-of-week prop.

Month pickers - icons

You can override the default icons used in the picker.

Month pickers - read only

Selecting new date could be disabled by adding readonly prop.

Month pickers - current month indicator

By default the current month is displayed using outline button - show-current prop allows you to remove the border or select different month to be displayed as the current one.

Edit this page | language on Github
Vuetify 3 is now available!The latest version of Vuetify is now available!
Learn about Vuetify 3's new features and functionality for modern Vue applications
Start exploringExplore