Skip to main content

Calendar

The Calendar component in Plateau Studio offers you to display data in daily, weekly, monthly, or category views.

info

For more details about Vuetify’s usage of Calendar component, click Calendar page.
For more prop explanations, click Vuetify Calendar API page.

In the daily view, the component provides dedicated slots for displaying both all-day and timed elements. This enables users to visualize their schedule and appointments throughout the day.

For the weekly and monthly views, the Calendar component offers a dedicated slot for each day, allowing you to easily navigate and explore the schedule across different time frames.

  • The category view enhances the organization of information by providing a slot for each category within the day. You can define categories and assign them to events, allowing for efficient categorization and filtering of data.

  • You have the option to pass in an array of events, which will be automatically rendered and positioned over the appropriate days and times within the calendar.

Props

AttributeDescriptionTypeDefault
qValueA date in the format of YYYY-MM-DD which determines what span of time for the calendar.string-number-dateundefined
categoriesSpecifies what categories to display in the category view. This controls the order of the categories as well. If the calendar uses events any categories specified in those events not specified in this value are dynamically rendered in the view unless category-hide-dynamic is true.array-stringundefined
categoryDaysThe number of days to render in the category view.number-string1
categoryForInvalidThe category to place events in that have invalid categories. A category is invalid when it is not a string. By default events without a category are not displayed until this value is specified.stringundefined
categoryHideDynamicsSets whether categories specified in an event should be hidden if it’s not defined in categoriesbooleanfalse
categoryShowAllSet whether the category view should show all defined categories even if there are no events for a category.booleanfalse
categoryTextIf categories is a list of objects, you can use this to determine what property to print out as the category text on the calendar. You can provide a function to do some logic or just define the prop name.string-functionundefined
darkApplies the dark theme.booleanfalse
dayFormatFormats day of the month string that appears in a day to a specified localefunctionnull
endThe ending date on the calendar (inclusive) in the format of YYYY-MM-DD. This may be ignored depending on the type of the calendar.string-number-dateundefined
eventCategorySet property of event’s category. Instead of a property a function can be given which takes an event and returns the category.string-functioncategory
eventEndSet property of event’s end timestamp.string'end'
eventHeightThe height of an event in pixels in the month view and at the top of the day viewsnumber20
eventMarginBottomMargin bottom for eventnumber1
eventMoreWhether the more ‘button’ is displayed on a calendar with too many events in a given day. It will say something like ‘5 more’ and when clicked generates a click:more event.booleantrue
eventMoreTextThe text to display in the more ‘button’ given the number of hidden events.string''
eventNameSet property of event’s displayed name, or a function which accepts an event object passed to the calendar as the first argument and a flag signalling whether the name is for a timed event (true) or an event over a day.string-function'name'
eventColorA background color for all events or a function which accepts an event object passed to the calendar to return a color.string-function'primary'
eventOverlapModeOne of stack, column, or a custom render functionstring-function'stack'
eventOverlapThresholdA value in minutes that’s used to determine whether two timed events should be placed in column beside each other or should be treated as slightly overlapping events.string-number60
eventRippleApplies the v-ripple directive.boolean-objectundefined
eventStartSet property of event’s start timestamp.string'start'
eventTextColorA text color for all events or a function which accepts an event object passed to the calendar to return a color.string-function'white'
eventTimedIf Dates or milliseconds are used as the start or end timestamp of an event, this prop can be a string to a property on the event that is truthy if the event is a timed event or a function which takes the event and returns a truthy value if the event is a timed event.string-fynction'timed'
eventsAn array of event objects with a property for a start timestamp and optionally a name and end timestamp. If an end timestamp is not given, the value of start will be used. If no name is given, you must provide an implementation for the event slot.array[]
firstIntervalThe first interval to display in the day view. If intervalMinutes is set to 60 and this is set to 9 the first time in the view is 9amnumber-string0
firstTimeThe first time to display in the day view. If specified, this overwrites any firstInterval value specified. This can be the number of minutes since midnight, a string in the format of HH:mm, or an object with number properties hour and minute.number-string-objectundefined
hideHeaderIf the header at the top of the day view should be visible.booleanfalse
intervalCountThe number of intervals to display in the day view.number-string24
intervalFormatFormats time of day string that appears in the interval gutter of the day and week view to specified localefunctionnull
intervalHeightThe height of an interval in pixels in the day view.number-string48
intervalMinutesThe number of minutes the intervals are in the day view. A common interval is 60 minutes so the intervals are an hour.number-string60
intervalStyleReturns CSS styling to apply to the interval.functionnull
intervalWidthThe width of the interval gutter on the left side in the day view.number-string60
lightApplies the light theme.booleanfalse
localeThe locale of the calendar.stringundefined
localeFirstDayOfYearSets the day that determines the first week of the year, starting with 0 for Sunday. For ISO 8601 this should be 4string-number0
maxDaysThe maximum number of days to display in the custom calendar if an end day is not set.number7
minWeeksThe minimum number of weeks to display in the month or week view.any1
monthFormatFormats month string that appears in a day to specified localefunctionnull
nowOverride the day & time which is considered now. This is in the format of YYYY-MM-DD hh:mm:ss. The calendar is styled according to now.stringundefined
shortIntervalsIf true, the intervals in the day view will be 9 AM as opposed to 09:00 AMbooleantrue
shortMonthsWhether the short versions of a month should be used (Jan vs January).booleantrue
shortWeekdaysWhether the short versions of a weekday should be used (Mon vs Monday).booleantrue
showIntervalLabelChecks if a given day and time should be displayed in the interval gutter of the day view.functionnull
showMonthOnFirstWhether the name of the month should be displayed on the first day of the month.booleantrue
showWeekWhether week numbers should be displayed when using the month view.booleanfalse
startThe starting date on the calendar (inclusive) in the format of YYYY-MM-DD. This may be ignored depending on the type of the calendar.string-number-dateundefined
typeA string which is one of month, week, day, 4day, custom-weekly, custom-daily, and category. The custom types look at the start and end dates passed to the component as opposed to the value.string'month'
weekdayFormatFormats day of the week string that appears in the header to specified localefunctionnull
weekdaysSpecifies which days of the week to display. To display Monday through Friday only, a value of [1, 2, 3, 4, 5] can be used. To display a week starting on Monday a value of [1, 2, 3, 4, 5, 6, 0] can be used.array-string[0,1,2,3,4,5,6]
visibleVisibility of Calendar componentbooleantrue

Events

AttributeDescription
changeThe range of days displayed on the calendar changed. This is triggered on initialization. The event passed is an object with start and end date objects.
click:dateThe click event on the day of the month link. The event passed is the day & time object. Native mouse event is passed as a second argument.
click:dayhe click event on a day. The event passed is the day object. Native mouse event is passed as a second argument.
click:day-categoryThe click event on a day in the category view. The event passed is the day object. Native mouse event is passed as a second argument.
click-eventThe click event on a specific event. The event passed is the day & time object.
click:intervalThe click event at a specific interval label in the day view. The event passed is the day & time object. Native mouse event is passed as a second argument.
click:moreThe click event on the X more button on views with too many events in a day. Native mouse event is passed as a second argument.
click:timeThe click event at a specific time in the day view. The event passed is the day & time object. Native mouse event is passed as a second argument.
click:time-categoryThe click event at a specific time in the category view. The event passed is the day & time object. Native mouse event is passed as a second argument.
contextmenu:dateThe right-click event on the day of the month link. The event passed is the day & time object. Native mouse event is passed as a second argument.
contextmenu:dayThe right-click event on a day. The event passed is the day object. Native mouse event is passed as a second argument.
contextmenu:day-categoryThe right-click event on a day in the category view. The event passed is the day object. Native mouse event is passed as a second argument.
contextmenu:eventThe right-click event on an event. The event passed is the day & time object.
contextmenu:intervalThe right-click event at a specific interval label in the day view. The event passed is the day & time object. Native mouse event is passed as a second argument.
contextmenu:timeThe right-click event at a specific time in the day view. The event passed is the day & time object. Native mouse event is passed as a second argument.
contextmenu:time-categoryThe right-click event at a specific time in the category view. The event passed is the day & time object. Native mouse event is passed as a second argument.
inputAn alias to the click:date event used to support v-model.
mousedown:dayThe mousedown event on a day. The event passed is the day object. Native mouse event is passed as a second argument.
mousedown:day-categoryThe mousedown event on a day in the category view. The event passed is the day object. Native mouse event is passed as a second argument.
mousedown:eventThe mousedown event on an event. The event passed is the day & time object.
mousedown:intervalThe mousedown event at a specific interval label in the day view. The event passed is the day & time object. Native mouse event is passed as a second argument.
mousedown:timeThe mousedown event at a specific time in the day view. The event passed is the day & time object. Native mouse event is passed as a second argument.
mousedown:time-categoryThe mousedown event at a specific time in the category view. The event passed is the day & time object. Native mouse event is passed as a second argument.
mouseenter:dayThe mouseenter event on a day. The event passed is the day object. Native mouse event is passed as a second argument.
mouseenter:day-categoryThe mouseenter event on a day in the category view. The event passed is the day object. Native mouse event is passed as a second argument.
mouseenter:eventThe mouseenter event on an event. The event passed is the day & time object.
mouseenter:intervalThe mouseenter event at a specific interval label in the day view. The event passed is the day & time object. Native mouse event is passed as a second argument.
mouseenter:timeThe mouseenter event at a specific time in the day view. The event passed is the day & time object. Native mouse event is passed as a second argument.
mouseenter:time-categoryThe mouseenter event at a specific time in the category view. The event passed is the day & time object. Native mouse event is passed as a second argument.
mouseleave:dayThe mouseleave event on a day. The event passed is the day object. Native mouse event is passed as a second argument.
mouseleave:day-categoryThe mouseleave event on a day in the category view. The event passed is the day object. Native mouse event is passed as a second argument.
mouseleave:eventThe mouseleave event on an event. The event passed is the day & time object.
mouseleave:intervalThe mouseleave event at a specific interval label in the day view. The event passed is the day & time object. Native mouse event is passed as a second argument.
mouseleave:timeThe mouseleave event at a specific time in the day view. The event passed is the day & time object. Native mouse event is passed as a second argument.
mouseleave:time-categoryThe mouseleave event at a specific time in the category view. The event passed is the day & time object. Native mouse event is passed as a second argument.
mousemove:dayThe mousemove event on a day. The event passed is the day object. Native mouse event is passed as a second argument.
mousemove:day-categoryThe mousemove event on a day in the category view. The event passed is the day object. Native mouse event is passed as a second argument.
mousemove:eventThe mousemove event on an event. The event passed is the day & time object.
mousemove:intervalThe mousemove event at a specific interval label in the day view. The event passed is the day & time object. Native mouse event is passed as a second argument.
mousemove:timeThe mousemove event at a specific time in the day view. The event passed is the day & time object. Native mouse event is passed as a second argument.
mousemove:time-categoryThe mousemove event at a specific time in the category view. The event passed is the day & time object. Native mouse event is passed as a second argument.
mouseup:dayThe mouseup event on a day. The event passed is the day object. Native mouse event is passed as a second argument.
mouseup:day-categoryThe mouseup event on a day in the category view. The event passed is the day object. Native mouse event is passed as a second argument.
mouseup:eventThe mouseup event on an event. The event passed is the day & time object.
mouseup:intervalThe mouseup event at a specific interval label in the day view. The event passed is the day & time object. Native mouse event is passed as a second argument.
mouseup:timeThe mouseup event at a specific time in the day view. The event passed is the day & time object. Native mouse event is passed as a second argument.
mouseup:time-categoryThe mouseup event at a specific time in the category view. The event passed is the day & time object. Native mouse event is passed as a second argument.
movedOne of the functions next, prev, and move was called. The event passed is the day object calculated for the movement.
touchend:dayThe touchend event on a day. The event passed is the day object. Native mouse event is passed as a second argument.
touchend:day-categoryThe touchend event on a day in the category view. The event passed is the day object. Native mouse event is passed as a second argument.
touchend:eventThe touchend event on am view. The event passed is the day & time object.
touchend:intervalThe touchend event at a specific interval label in the day view. The event passed is the day & time object. Native mouse event is passed as a second argument.
touchend:timeThe touchend event at a specific time in the day view. The event passed is the day & time object. Native mouse event is passed as a second argument.
touchend:time-categoryThe touchend event at a specific time in the category view. The event passed is the day & time object. Native mouse event is passed as a second argument.
touchmove:dayThe touchmove event on a day. The event passed is the day object. Native mouse event is passed as a second argument.
touchmove:day-categoryThe touchmove event on a day in the category view. The event passed is the day object. Native mouse event is passed as a second argument.
touchmove:eventThe touchmove event on an event view. The event passed is the day & time object.
touchmove:intervalThe touchmove event at a specific interval label in the day view. The event passed is the day & time object. Native mouse event is passed as a second argument.
touchmove:timeThe touchmove event at a specific time in the day view. The event passed is the day & time object. Native mouse event is passed as a second argument.
touchmove:time-categoryThe touchmove event at a specific time in the category view. The event passed is the day & time object. Native mouse event is passed as a second argument.
touchstart:dayThe touchstart event on a day. The event passed is the day object. Native mouse event is passed as a second argument.
touchstart:day-categoryThe touchstart event on a day in the category view. The event passed is the day object. Native mouse event is passed as a second argument.
touchstart:eventThe touchstart event on an event view. The event passed is the day & time object.
touchstart:intervalThe touchstart event at a specific interval label in the day view. The event passed is the day & time object. Native mouse event is passed as a second argument.
touchstart:timeThe touchstart event at a specific time in the day view. The event passed is the day & time object. Native mouse event is passed as a second argument.
touchstart:time-categoryThe touchstart event at a specific time in the category view. The event passed is the day & time object Native mouse event is passed as a second argument.

Samples Component

Calendar usage example

Calendar click more event usage example

Samples Qjson

CalendarUsageExample
CalendarClickMoreExample