Skip to content

CalendarView-DEMO


vue
<fv-CalendarView></fv-CalendarView>

CalendarView Multiple Choose


vue
<fv-CalendarView :modelValue="resetValue" multiple="multiple"></fv-CalendarView>
javascript
reset () {
    this.resetValue = new Date(this.resetValue);
}

CalendarView Specific Day


vue
<fv-CalendarView :modelValue="value" multiple="multiple"></fv-CalendarView>

CalendarView Range Choose


vue
<fv-CalendarView multiple="range"></fv-CalendarView>
javascript
export default {
    data () {
        return {
            currentChoosen: []
        }
    },
    mounted () {
        let year = new Date().getFullYear();
        let month = new Date().getMonth();
        let day = new Date().getDate();
        for (let i = 0; i < 10; i++) {
            this.currentChoosen.push(new Date(
                year,
                month,
                day + i
            ));
        }
    }
}

CalendarView Dark Theme


vue
<fv-CalendarView theme="dark"></fv-CalendarView>

CalendarView Custom Theme


Custom Selected Color

vue
<fv-CalendarView theme="dark" background="rgba(30, 19, 57, 1)" foreground="rgba(0, 204, 153, 1)" nowDayColor="rgba(0, 180, 153, 1)" rangeChooseColorFE="rgba(0, 220, 153, 0.9)" rangeChooseColorMiddle="rgba(0, 220, 153, 0.6)" borderRadius="50" multiple="range"></fv-CalendarView>

Properties


PropertyTypeRequiredDefaultDescription
modelValuefunctionNo() => new Date()
multiplestringNo'single'
choosenDatesarrayNo[]CalendarViewInitial selected date.
foregroundstringNo''See the CalendarView foreground option.
backgroundstringNo''See the CalendarView background option.
nowDayColorstringNo''Color for today.
rangeChooseColorFEstringNo''See the CalendarView rangeChooseColorFE option.
rangeChooseColorMiddlestringNo''See the CalendarView rangeChooseColorMiddle option.
themestringNo'global'Theme style. Supports global, light, dark, system, and custom.
startnumberNo1900See the CalendarView start option.
weekdaysarrayNo['Su', 'Mo', 'Tu', 'We', 'Th', 'Fr', 'Sa']See the CalendarView weekdays option.
monthListarrayNo[ 'January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December' ]See the CalendarView monthList option.
borderRadiusstringNo''See the CalendarView borderRadius option.
disabledbooleanNofalseSee the CalendarView disabled option.
langstringNo"global"See the CalendarView lang option.

Events


EventArgumentsDescription
choose-yearstringSee the component choose-year option.
choose-monthstringSee the component choose-month option.
update:choosenDatesarraySee the component update:choosenDates option.
choose-datedateSee the component choose-date option.
choosen-datesarraySee the component choosen-dates option.
choosen-dates-objarrayReturns an array of Date values.

Slots


  1. Statement
vue
<template v-slot:statement="x">
    <p></p>
</template>
  1. Weekday Content
vue
<template v-slot:weekday_content>
    <p></p>
</template>

MIT Licensed