先給大家分享一下源碼:https://github.com/lx544690189/vue-mobile-calendar
從策劃到設(shè)計制作,每一步都追求做到細膩,制作可持續(xù)發(fā)展的企業(yè)網(wǎng)站。為客戶提供做網(wǎng)站、網(wǎng)站制作、網(wǎng)站策劃、網(wǎng)頁設(shè)計、國際域名空間、虛擬空間、網(wǎng)絡(luò)營銷、VI設(shè)計、 網(wǎng)站改版、漏洞修補等服務(wù)。為客戶提供更好的一站式互聯(lián)網(wǎng)解決方案,以客戶的口碑塑造優(yōu)易品牌,攜手廣大客戶,共同發(fā)展進步。
Build Setup
# install dependencies npm install # build for production with minification npm run build
Usage
install
npm install vue-mobile-calendar
or:(from the dist folder)
Quickstart
import Vue from 'vue' import Calendar from 'vue-mobile-calendar' Vue.use(Calendar)
Attributes
option | description | type | default |
---|---|---|---|
v-model | show/hide the calendar | Boolean | false |
format | format date | String | "yyyy-MM-dd" |
defaultDate | default selected date | Date | new Date() |
minDate | optional minimum date | Date | null |
maxDate | optional maximum date | Date | null |
closeByClickmask | close by mask | Boolean | true |
month | text of month | Array | ["一月", "二月", "三月", "四月", "五月", "六月", "七月", "八月", "九月", "十月", "十一月", "十二月"] |
week | text of day | Array | ["周一", "周二", "周三", "周四", "周五", "周六", "周日"] |
Events
event name | description | parameter of callback |
---|---|---|
change | when date change | (date,formatDate) |
Reference
framework7
mint-ui