介紹
支持兩種模式,周晾蜘、月邻眷;類似于釘釘日歷交互;
插件效果
http://merrylmr.top/admin-vuetify/#/calendar
安裝
npm install v-calendar-mobile
// or
yarn add v-calendar-mobile
使用
- main.js
import vCalendarMobile from 'v-calendar-mobile'
Vue.use(vCalendarMobile)
- 組件中使用:
<v-calendar-mobile
:changeMode="true">
</v-calendar-mobile>
參數(shù)
參數(shù) | 說明 |
---|---|
mode | 日歷的模式(week/month)默認值為:week |
changeMoe | 是否支持切換日歷模式(默認:false) |
swiperActive | 切換頁是否默認選中一個日期(默認:true) |
事件
事件名稱 | 說明 | 回調(diào)參數(shù) |
---|---|---|
change | 切換日期 | 選中的日期 |
slot
name | 說明 |
---|---|
dateCell | 每個單元格插槽笙纤,參數(shù)為{day} |
<v-calendar-mobile
:changeMode="true">
<template slot="dateCell" slot-scope="{day}">
{{day.day}}
</template>
</v-calendar-mobile>
github地址
https://github.com/merrylmr/v-calendar-mobile#readme
參考文檔
https://blog.csdn.net/yxgd_1442962728/article/details/109717249