├── .github
└── workflows
│ └── npm-publish.yml
├── .gitignore
├── README.md
├── babel.config.js
├── dist
├── calendar.common.js
├── calendar.common.js.map
├── calendar.css
├── calendar.umd.js
├── calendar.umd.js.map
├── calendar.umd.min.js
├── calendar.umd.min.js.map
└── demo.html
├── example
├── demo1.html
├── demo2.html
├── demo3.html
├── demo4.html
├── demo5.html
├── demo6.html
├── demo7.html
├── index.html
└── lib
│ ├── style.css
│ └── vue.min.js
├── package-lock.json
├── package.json
├── public
├── favicon.ico
└── index.html
└── src
├── App.vue
├── assets
├── calendar.js
└── styles.scss
├── components
├── index.vue
├── item.vue
├── main.js
└── title-bar.vue
└── main.js
/.github/workflows/npm-publish.yml:
--------------------------------------------------------------------------------
1 | name: NPM Publish
2 | on:
3 | push:
4 | branches:
5 | - master
6 | jobs:
7 | publish:
8 | runs-on: ubuntu-latest
9 | steps:
10 | - uses: actions/checkout@v1
11 | - uses: actions/setup-node@v1
12 | with:
13 | node-version: 10
14 | - run: npm install
15 | - run: npm run package
16 | - uses: JS-DevTools/npm-publish@v1
17 | with:
18 | token: ${{ secrets.NPM_AUTH_TOKEN }}
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | .DS_Store
2 | node_modules
3 |
4 |
5 | # local env files
6 | .env.local
7 | .env.*.local
8 |
9 | # Log files
10 | npm-debug.log*
11 | yarn-debug.log*
12 | yarn-error.log*
13 | pnpm-debug.log*
14 |
15 | # Editor directories and files
16 | .idea
17 | .vscode
18 | *.suo
19 | *.ntvs*
20 | *.njsproj
21 | *.sln
22 | *.sw?
23 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # Calendar 日历
2 |
3 |     
4 |
5 | * 😊 基于 vue 2.0 开发的轻量,高性能日历组件;
6 | * 😘 支持农历,节气,假日显示;
7 | * 😍 原生 js 开发,无第三方库;
8 | * 😂 支持现代浏览器(IE >= 9);
9 | * 👍 感谢 [calendar.js](https://github.com/jjonline/calendar.js)
10 |
11 | ## 安装
12 |
13 | ### NPM
14 |
15 | ```bash
16 | npm i vue-lunar-calendar-pro --save
17 | ```
18 |
19 | ### CDN
20 |
21 | 目前可以通过 [unpkg.com/vue-lunar-calendar-pro](https://unpkg.com/vue-lunar-calendar-pro) 或者 [www.jsdelivr.com/package/npm/vue-lunar-calendar-pro](https://www.jsdelivr.com/package/npm/vue-lunar-calendar-pro) 获取到最新版本的资源,在页面上引入 js 和 css 文件即可开始使用。
22 |
23 | 🚩 建议使用 CDN 引入组件的用户在链接地址上锁定版本,以免将来组件升级时受到非兼容性更新的影响。🚩
24 |
25 | ```html
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 | ```
37 |
38 | ## 使用
39 |
40 | ### 全局使用
41 |
42 | ```js
43 | // main.js
44 | import Vue from 'vue'
45 | import App from './App.vue'
46 | // ...
47 | import 'vue-lunar-calendar-pro/dist/calendar.css';
48 | import Calandar from 'vue-lunar-calendar-pro'
49 | Vue.use(Calandar)
50 |
51 | // ...
52 |
53 | new Vue({
54 | el: '#app',
55 | render: h => h(App)
56 | })
57 | ```
58 |
59 | ```html
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
72 | ```
73 |
74 | ### 本地注册
75 | ```html
76 |
77 |
78 |
79 |
80 |
81 |
82 |
83 |
91 | ```
92 |
93 | ## 例子
94 |
95 | ### 基本单选
96 |
97 | 🔸 设置 `default-date` 来指定当前显示的月份。如果 `default-date` 未指定,则显示当月。
98 |
99 | 基本单选: [demo1](http://demo.const.team/calendar/demo1.html)
100 |
101 | ```html
102 |
103 |
104 |
105 | 默认日期:{{defaultDate}}
106 | 选中日期:{{date}}
107 |
108 |
109 |
119 | ```
120 |
121 | ### 基本多选
122 |
123 | 🔸 设置 `multiple` 开启日期多选。
124 |
125 | 基本多选: [demo2](http://demo.const.team/calendar/demo2.html)
126 |
127 | ```html
128 |
129 |
130 |
131 | 选中日期:{{date}}
132 |
133 |
134 |
143 | ```
144 |
145 | ### 设置周起始日
146 |
147 | 🔸 设置 `first-day-of-week` 来指定周起始日。如果 `first-day-of-week` 未指定则按照周日为起始日。
148 |
149 | 设置周起始日: [demo3](http://demo.const.team/calendar/demo3.html)
150 |
151 | ```html
152 |
153 |
154 |
155 | 选中日期:{{date}}
156 |
157 |
158 |
167 | ```
168 |
169 | ### 高亮日期
170 |
171 | 🔸 设置 `highlighter-date` 高亮日期。
172 |
173 | 高亮日期: [demo4](http://demo.const.team/calendar/demo4.html)
174 |
175 | ```html
176 |
177 |
178 |
179 | 选中日期:{{date}}
180 | 高亮日期:{{highlighter}}
181 |
182 |
183 |
193 | ```
194 |
195 | ### 某些日期不可选
196 |
197 | 🔸 设置 `disabled-date` 来指定当哪些日期不可选。
198 |
199 | 某些日期不可选: [demo5](http://demo.const.team/calendar/demo5.html)
200 |
201 | ```html
202 |
203 |
204 |
205 | 选中日期:{{date}}
206 | 不可选日期:{{disableddate}}
207 |
208 |
209 |
219 | ```
220 |
221 | ### 设置日期区间
222 |
223 | 🔸 设置 `max-date` 和 `min-date` 来设置日期区间。
224 |
225 | 设置日期区间: [demo6](http://demo.const.team/calendar/demo6.html)
226 |
227 | ```html
228 |
229 |
230 |
231 | 选中日期:{{date}}
232 | 日期区间:2019-05-01 至 2019-12-31
233 | 不可选日期:{{disableddate}}
234 |
235 |
236 |
246 | ```
247 |
248 | ### 自定义Render
249 |
250 | 🔸 内置 `render` 方法,参数为`year, month`,配合其他组件使用。另外,通过设置名为 `dateCell` 的 `scoped-slot` 来自定义日历单元格中显示的内容。在 `scoped-slot` 可以获取到 `date`(当前单元格的日期对象),详情解释参考下方的 `API` 文档。
251 |
252 | 自定义Render: [demo7](http://demo.const.team/calendar/demo7.html)
253 |
254 | ```html
255 |
256 |
257 |
263 |
264 |
265 |
266 |
267 |
268 |
272 |
273 | - 属性:
274 | - date:{{date.date}}
275 | - year:{{date.year}}
276 | - month:{{date.month}}
277 | - day:{{date.day}}
278 | - weekDay:{{date.weekDay}}
279 | - gzDay:{{date.gzDay}}
280 | - gzMonth:{{date.gzMonth}}
281 | - gzYear:{{date.gzYear}}
282 | - lunarMonth:{{date.lunarMonth}}
283 | - lunar:{{date.lunar}}
284 | - animal:{{date.animal}}
285 | - astro:{{date.astro}}
286 |
287 | 点击
288 |
289 |
290 |
291 |
292 | 选中日期:{{date}}
293 |
294 |
311 | ```
312 |
313 | ## 属性
314 | | 参数 | 说明 | 类型 | 可选值 | 默认值 |
315 | |-----------------|-------------- |---------- |------------ |-------- |
316 | | default-date|默认渲染日期|Date,String|能被new Date()解析的|new Date()|
317 | | select-date | 绑定值 | Array | — | — |
318 | | highlighter-date | 高亮日期 | Array | — | — |
319 | | disabled-date | 不可选日期 | Array | — | — |
320 | | max-date | 最大可选日期 | Date,String | 能被new Date()解析的 | — |
321 | | min-date | 最小可选日期 | Date,String | 能被new Date()解析的 | — |
322 | | show-lunar | 是否渲染农历 | Boolean | — | true |
323 | | show-festival | 是否渲染节日 | Boolean | — | true |
324 | | show-term | 是否渲染节气 | Boolean | — | true |
325 | | show-week | 是否高亮周末 | Boolean | — | true |
326 | | show-title | 是否显示头部标题栏(年月日/按钮) | Boolean | — | true |
327 | | week-count | 每月显示的行的数量 | Number | — | 6 |
328 | | first-day-of-week | 周起始日 | Number | 1 到 7 | 7 |
329 | | multiple | 是否多选 | Boolean | — | false |
330 |
331 | ## 事件
332 |
333 | | 事件名 | 说明 | 参数 |
334 | |---|---|---|
335 | | year-change | 当前渲染的年份变化时会触发该事件 | year,month |
336 | | month-change | 当前渲染的月份变化时会触发该事件 | year,month |
337 | | date-click | 点击某个日期格子时会触发该事件 | date |
338 |
339 | ## 插槽
340 | | 参数 | 说明 |
341 | |---|---|
342 | | dateCell | 当前单元格的日期对象 |
343 |
344 | ## Date 对象
345 |
346 | | 字段 | 说明 |
347 | |---|---|
348 | | date | Date对象 |
349 | | year | 年 |
350 | | month | 月 |
351 | | day | 日 |
352 | | weekDay | 周几(0-6) |
353 | | lunar | 农历日 |
354 | | lunarMonth | 农历日 |
355 | | festival | 节日 |
356 | | lunarFestival | 农历节日 |
357 | | term | 节气 |
358 | | astro | 星座 |
359 | | animal | 属相 |
360 | | gzDay | 干支天 |
361 | | gzMonth | 干支月 |
362 | | gzYear | 干支年 |
363 | | isToday | 是否为今天 |
364 | | isSelect | 是否选中 |
365 | | isWeekend | 是否为周末 |
366 | | isOtherMonthDay | 是否属于当前渲染月份 |
367 | | renderYear | 当前渲染年份 |
368 | | renderMonth | 当前渲染月份 |
369 | | isDefaultDate | 是否是默认日期 |
--------------------------------------------------------------------------------
/babel.config.js:
--------------------------------------------------------------------------------
1 | module.exports = {
2 | presets: [
3 | '@vue/cli-plugin-babel/preset'
4 | ]
5 | }
6 |
--------------------------------------------------------------------------------
/dist/calendar.css:
--------------------------------------------------------------------------------
1 | .calendar-pro{background-color:#fff;width:100%;height:100%}.calendar-pro__title{*zoom:1;margin-bottom:20px}.calendar-pro__title:after,.calendar-pro__title:before{content:"";display:table;height:0}.calendar-pro__title:after{clear:both}.calendar-pro__title-info{float:left;display:inline;color:#17233d;font-size:18px}.calendar-pro__tool{float:right;display:inline;position:relative;display:inline-block;vertical-align:middle}.calendar-pro__tool button{padding:5px 15px;border:1px solid #dcdee2;color:#515a6e;background-color:transparent;position:relative}.calendar-pro__tool button:hover{color:#57a3f3;background-color:#fff;border-color:#57a3f3;cursor:pointer;z-index:2}.calendar-pro__tool button:first-child{margin-left:0}.calendar-pro__tool button+button{margin-left:-1px}.calendar-pro.showWeek .weekend{background-color:#efefef}.calendar-pro__body table{border-collapse:collapse}.calendar-pro__body table th{padding:10px 0;font-weight:400}.calendar-pro__body table td{position:relative;border:1px solid #d2d2d2;width:300px;cursor:pointer}.calendar-pro__body table td:hover .day-box{background-color:#e8f4ff}.calendar-pro__body table td .day-box{position:relative;height:68px;padding:10px;font-size:14px}.calendar-pro__body table td .day-box.highlighter{background-color:#f0f9e8}.calendar-pro__body table td .day-box.highlighter .info-date{color:#66bf16}.calendar-pro__body table td .day-box.select{width:auto;background-color:#e8f4ff}.calendar-pro__body table td .day-box.select .info-date{color:#1890ff}.calendar-pro__body table td .day-box.disabled{cursor:not-allowed;background-color:#e5e5e5;color:#999}.calendar-pro__body table td .day-box.other-month-day{opacity:.6}.calendar-pro__body table td .day-box.today{outline:2px solid #1890ff;z-index:2}.calendar-pro__body table td .info-date{font-size:18px;font-weight:bolder}.calendar-pro__body table td .info-festival{margin-top:3px;text-align:center}.calendar-pro__body table td .info-lunar{position:absolute;bottom:10px;right:10px}.calendar-pro__body table td .info-term{position:absolute;bottom:10px;left:10px}
--------------------------------------------------------------------------------
/dist/calendar.umd.min.js:
--------------------------------------------------------------------------------
1 | (function(e,t){"object"===typeof exports&&"object"===typeof module?module.exports=t():"function"===typeof define&&define.amd?define([],t):"object"===typeof exports?exports["calendar"]=t():e["calendar"]=t()})("undefined"!==typeof self?self:this,(function(){return function(e){var t={};function n(r){if(t[r])return t[r].exports;var c=t[r]={i:r,l:!1,exports:{}};return e[r].call(c.exports,c,c.exports,n),c.l=!0,c.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"===typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var c in e)n.d(r,c,function(t){return e[t]}.bind(null,c));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e["default"]}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s="fb15")}({"00ee":function(e,t,n){var r=n("b622"),c=r("toStringTag"),f={};f[c]="z",e.exports="[object z]"===String(f)},"06cf":function(e,t,n){var r=n("83ab"),c=n("d1e7"),f=n("5c6c"),a=n("fc6a"),o=n("c04e"),i=n("5135"),b=n("0cfb"),u=Object.getOwnPropertyDescriptor;t.f=r?u:function(e,t){if(e=a(e),t=o(t,!0),b)try{return u(e,t)}catch(n){}if(i(e,t))return f(!c.f.call(e,t),e[t])}},"0cfb":function(e,t,n){var r=n("83ab"),c=n("d039"),f=n("cc12");e.exports=!r&&!c((function(){return 7!=Object.defineProperty(f("div"),"a",{get:function(){return 7}}).a}))},"1be4":function(e,t,n){var r=n("d066");e.exports=r("document","documentElement")},"1d80":function(e,t){e.exports=function(e){if(void 0==e)throw TypeError("Can't call method on "+e);return e}},"1dde":function(e,t,n){var r=n("d039"),c=n("b622"),f=n("2d00"),a=c("species");e.exports=function(e){return f>=51||!r((function(){var t=[],n=t.constructor={};return n[a]=function(){return{foo:1}},1!==t[e](Boolean).foo}))}},"23cb":function(e,t,n){var r=n("a691"),c=Math.max,f=Math.min;e.exports=function(e,t){var n=r(e);return n<0?c(n+t,0):f(n,t)}},"23e7":function(e,t,n){var r=n("da84"),c=n("06cf").f,f=n("9112"),a=n("6eeb"),o=n("ce4e"),i=n("e893"),b=n("94ca");e.exports=function(e,t){var n,u,s,l,d,h,p=e.target,v=e.global,g=e.stat;if(u=v?r:g?r[p]||o(p,{}):(r[p]||{}).prototype,u)for(s in t){if(d=t[s],e.noTargetGet?(h=c(u,s),l=h&&h.value):l=u[s],n=b(v?s:p+(g?".":"#")+s,e.forced),!n&&void 0!==l){if(typeof d===typeof l)continue;i(d,l)}(e.sham||l&&l.sham)&&f(d,"sham",!0),a(u,s,d,e)}}},"241c":function(e,t,n){var r=n("ca84"),c=n("7839"),f=c.concat("length","prototype");t.f=Object.getOwnPropertyNames||function(e){return r(e,f)}},"25f0":function(e,t,n){"use strict";var r=n("6eeb"),c=n("825a"),f=n("d039"),a=n("ad6d"),o="toString",i=RegExp.prototype,b=i[o],u=f((function(){return"/a/b"!=b.call({source:"a",flags:"b"})})),s=b.name!=o;(u||s)&&r(RegExp.prototype,o,(function(){var e=c(this),t=String(e.source),n=e.flags,r=String(void 0===n&&e instanceof RegExp&&!("flags"in i)?a.call(e):n);return"/"+t+"/"+r}),{unsafe:!0})},"2d00":function(e,t,n){var r,c,f=n("da84"),a=n("342f"),o=f.process,i=o&&o.versions,b=i&&i.v8;b?(r=b.split("."),c=r[0]+r[1]):a&&(r=a.match(/Edge\/(\d+)/),(!r||r[1]>=74)&&(r=a.match(/Chrome\/(\d+)/),r&&(c=r[1]))),e.exports=c&&+c},"2fc4":function(e,t,n){},"342f":function(e,t,n){var r=n("d066");e.exports=r("navigator","userAgent")||""},"37e8":function(e,t,n){var r=n("83ab"),c=n("9bf2"),f=n("825a"),a=n("df75");e.exports=r?Object.defineProperties:function(e,t){f(e);var n,r=a(t),o=r.length,i=0;while(o>i)c.f(e,n=r[i++],t[n]);return e}},"3bbe":function(e,t,n){var r=n("861d");e.exports=function(e){if(!r(e)&&null!==e)throw TypeError("Can't set "+String(e)+" as a prototype");return e}},"428f":function(e,t,n){var r=n("da84");e.exports=r},"44ad":function(e,t,n){var r=n("d039"),c=n("c6b6"),f="".split;e.exports=r((function(){return!Object("z").propertyIsEnumerable(0)}))?function(e){return"String"==c(e)?f.call(e,""):Object(e)}:Object},4930:function(e,t,n){var r=n("d039");e.exports=!!Object.getOwnPropertySymbols&&!r((function(){return!String(Symbol())}))},"4d64":function(e,t,n){var r=n("fc6a"),c=n("50c4"),f=n("23cb"),a=function(e){return function(t,n,a){var o,i=r(t),b=c(i.length),u=f(a,b);if(e&&n!=n){while(b>u)if(o=i[u++],o!=o)return!0}else for(;b>u;u++)if((e||u in i)&&i[u]===n)return e||u||0;return!e&&-1}};e.exports={includes:a(!0),indexOf:a(!1)}},"50c4":function(e,t,n){var r=n("a691"),c=Math.min;e.exports=function(e){return e>0?c(r(e),9007199254740991):0}},5135:function(e,t){var n={}.hasOwnProperty;e.exports=function(e,t){return n.call(e,t)}},5692:function(e,t,n){var r=n("c430"),c=n("c6cd");(e.exports=function(e,t){return c[e]||(c[e]=void 0!==t?t:{})})("versions",[]).push({version:"3.8.1",mode:r?"pure":"global",copyright:"© 2020 Denis Pushkarev (zloirock.ru)"})},"56ef":function(e,t,n){var r=n("d066"),c=n("241c"),f=n("7418"),a=n("825a");e.exports=r("Reflect","ownKeys")||function(e){var t=c.f(a(e)),n=f.f;return n?t.concat(n(e)):t}},5899:function(e,t){e.exports="\t\n\v\f\r \u2028\u2029\ufeff"},"58a8":function(e,t,n){var r=n("1d80"),c=n("5899"),f="["+c+"]",a=RegExp("^"+f+f+"*"),o=RegExp(f+f+"*$"),i=function(e){return function(t){var n=String(r(t));return 1&e&&(n=n.replace(a,"")),2&e&&(n=n.replace(o,"")),n}};e.exports={start:i(1),end:i(2),trim:i(3)}},"5c6c":function(e,t){e.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},"65f0":function(e,t,n){var r=n("861d"),c=n("e8b5"),f=n("b622"),a=f("species");e.exports=function(e,t){var n;return c(e)&&(n=e.constructor,"function"!=typeof n||n!==Array&&!c(n.prototype)?r(n)&&(n=n[a],null===n&&(n=void 0)):n=void 0),new(void 0===n?Array:n)(0===t?0:t)}},"69f3":function(e,t,n){var r,c,f,a=n("7f9a"),o=n("da84"),i=n("861d"),b=n("9112"),u=n("5135"),s=n("c6cd"),l=n("f772"),d=n("d012"),h=o.WeakMap,p=function(e){return f(e)?c(e):r(e,{})},v=function(e){return function(t){var n;if(!i(t)||(n=c(t)).type!==e)throw TypeError("Incompatible receiver, "+e+" required");return n}};if(a){var g=s.state||(s.state=new h),y=g.get,m=g.has,D=g.set;r=function(e,t){return t.facade=e,D.call(g,e,t),t},c=function(e){return y.call(g,e)||{}},f=function(e){return m.call(g,e)}}else{var x=l("state");d[x]=!0,r=function(e,t){return t.facade=e,b(e,x,t),t},c=function(e){return u(e,x)?e[x]:{}},f=function(e){return u(e,x)}}e.exports={set:r,get:c,has:f,enforce:p,getterFor:v}},"6eeb":function(e,t,n){var r=n("da84"),c=n("9112"),f=n("5135"),a=n("ce4e"),o=n("8925"),i=n("69f3"),b=i.get,u=i.enforce,s=String(String).split("String");(e.exports=function(e,t,n,o){var i,b=!!o&&!!o.unsafe,l=!!o&&!!o.enumerable,d=!!o&&!!o.noTargetGet;"function"==typeof n&&("string"!=typeof t||f(n,"name")||c(n,"name",t),i=u(n),i.source||(i.source=s.join("string"==typeof t?t:""))),e!==r?(b?!d&&e[t]&&(l=!0):delete e[t],l?e[t]=n:c(e,t,n)):l?e[t]=n:a(t,n)})(Function.prototype,"toString",(function(){return"function"==typeof this&&b(this).source||o(this)}))},7156:function(e,t,n){var r=n("861d"),c=n("d2bb");e.exports=function(e,t,n){var f,a;return c&&"function"==typeof(f=t.constructor)&&f!==n&&r(a=f.prototype)&&a!==n.prototype&&c(e,a),e}},7418:function(e,t){t.f=Object.getOwnPropertySymbols},7839:function(e,t){e.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},"7b0b":function(e,t,n){var r=n("1d80");e.exports=function(e){return Object(r(e))}},"7c73":function(e,t,n){var r,c=n("825a"),f=n("37e8"),a=n("7839"),o=n("d012"),i=n("1be4"),b=n("cc12"),u=n("f772"),s=">",l="<",d="prototype",h="script",p=u("IE_PROTO"),v=function(){},g=function(e){return l+h+s+e+l+"/"+h+s},y=function(e){e.write(g("")),e.close();var t=e.parentWindow.Object;return e=null,t},m=function(){var e,t=b("iframe"),n="java"+h+":";return t.style.display="none",i.appendChild(t),t.src=String(n),e=t.contentWindow.document,e.open(),e.write(g("document.F=Object")),e.close(),e.F},D=function(){try{r=document.domain&&new ActiveXObject("htmlfile")}catch(t){}D=r?y(r):m();var e=a.length;while(e--)delete D[d][a[e]];return D()};o[p]=!0,e.exports=Object.create||function(e,t){var n;return null!==e?(v[d]=c(e),n=new v,v[d]=null,n[p]=e):n=D(),void 0===t?n:f(n,t)}},"7f9a":function(e,t,n){var r=n("da84"),c=n("8925"),f=r.WeakMap;e.exports="function"===typeof f&&/native code/.test(c(f))},"825a":function(e,t,n){var r=n("861d");e.exports=function(e){if(!r(e))throw TypeError(String(e)+" is not an object");return e}},"83ab":function(e,t,n){var r=n("d039");e.exports=!r((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]}))},8418:function(e,t,n){"use strict";var r=n("c04e"),c=n("9bf2"),f=n("5c6c");e.exports=function(e,t,n){var a=r(t);a in e?c.f(e,a,f(0,n)):e[a]=n}},"861d":function(e,t){e.exports=function(e){return"object"===typeof e?null!==e:"function"===typeof e}},8875:function(e,t,n){var r,c,f;(function(n,a){c=[],r=a,f="function"===typeof r?r.apply(t,c):r,void 0===f||(e.exports=f)})("undefined"!==typeof self&&self,(function(){function e(){var t=Object.getOwnPropertyDescriptor(document,"currentScript");if(!t&&"currentScript"in document&&document.currentScript)return document.currentScript;if(t&&t.get!==e&&document.currentScript)return document.currentScript;try{throw new Error}catch(d){var n,r,c,f=/.*at [^(]*\((.*):(.+):(.+)\)$/gi,a=/@([^@]*):(\d+):(\d+)\s*$/gi,o=f.exec(d.stack)||a.exec(d.stack),i=o&&o[1]||!1,b=o&&o[2]||!1,u=document.location.href.replace(document.location.hash,""),s=document.getElementsByTagName("script");i===u&&(n=document.documentElement.outerHTML,r=new RegExp("(?:[^\\n]+?\\n){0,"+(b-2)+"}[^<]*
4 |
5 |
6 |
7 |
8 |
11 |
--------------------------------------------------------------------------------
/example/demo1.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | 基本单选
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
默认日期:{{defaultDate}}
15 |
选中日期:{{date}}
16 |
17 |
26 |
27 |
28 |
--------------------------------------------------------------------------------
/example/demo2.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | 基本多选
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
选中日期:{{date}}
15 |
16 |
24 |
25 |
26 |
--------------------------------------------------------------------------------
/example/demo3.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | 设置周起始日
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
选中日期:{{date}}
15 |
16 |
24 |
25 |
26 |
--------------------------------------------------------------------------------
/example/demo4.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | 高亮日期
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
选中日期:{{date}}
15 |
高亮日期:{{highlighter}}
16 |
17 |
26 |
27 |
28 |
--------------------------------------------------------------------------------
/example/demo5.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | 某些日期不可选
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
选中日期:{{date}}
15 |
不可选日期:{{disableddate}}
16 |
17 |
26 |
27 |
28 |
--------------------------------------------------------------------------------
/example/demo6.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | 设置日期区间
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
选中日期:{{date}}
15 |
不可选日期:{{disableddate}}
16 |
区间:2019-05-01至2019-12-31
17 |
18 |
27 |
28 |
29 |
--------------------------------------------------------------------------------
/example/demo7.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Render方法
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
23 |
24 |
25 |
26 |
27 |
31 |
32 | - 属性:
33 | - date:{{date.date}}
34 | - year:{{date.year}}
35 | - month:{{date.month}}
36 | - day:{{date.day}}
37 | - weekDay:{{date.weekDay}}
38 | - gzDay:{{date.gzDay}}
39 | - gzMonth:{{date.gzMonth}}
40 | - gzYear:{{date.gzYear}}
41 | - lunarMonth:{{date.lunarMonth}}
42 | - lunar:{{date.lunar}}
43 | - animal:{{date.animal}}
44 | - astro:{{date.astro}}
45 |
46 | 点击
47 |
48 |
49 |
50 |
51 |
67 |
78 |
79 |
80 |
--------------------------------------------------------------------------------
/example/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | Calendar 日历
6 |
7 |
8 |
19 |
20 |
21 |
--------------------------------------------------------------------------------
/example/lib/style.css:
--------------------------------------------------------------------------------
1 | .demonstration{
2 | font-size: 16px;
3 | color:#8492a6;
4 | margin: 20px 0 0;
5 | }
--------------------------------------------------------------------------------
/example/lib/vue.min.js:
--------------------------------------------------------------------------------
1 | /*!
2 | * Vue.js v2.5.13
3 | * (c) 2014-2017 Evan You
4 | * Released under the MIT License.
5 | */
6 | !function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):t.Vue=e()}(this,function(){"use strict";function t(t){return void 0===t||null===t}function e(t){return void 0!==t&&null!==t}function n(t){return!0===t}function r(t){return"string"==typeof t||"number"==typeof t||"symbol"==typeof t||"boolean"==typeof t}function i(t){return null!==t&&"object"==typeof t}function o(t){return"[object Object]"===Nn.call(t)}function a(t){var e=parseFloat(String(t));return e>=0&&Math.floor(e)===e&&isFinite(t)}function s(t){return null==t?"":"object"==typeof t?JSON.stringify(t,null,2):String(t)}function c(t){var e=parseFloat(t);return isNaN(e)?t:e}function u(t,e){for(var n=Object.create(null),r=t.split(","),i=0;i-1)return t.splice(n,1)}}function f(t,e){return Mn.call(t,e)}function p(t){var e=Object.create(null);return function(n){return e[n]||(e[n]=t(n))}}function d(t,e){function n(n){var r=arguments.length;return r?r>1?t.apply(e,arguments):t.call(e,n):t.call(e)}return n._length=t.length,n}function v(t,e){e=e||0;for(var n=t.length-e,r=new Array(n);n--;)r[n]=t[n+e];return r}function h(t,e){for(var n in e)t[n]=e[n];return t}function m(t){for(var e={},n=0;n0&&(tt((s=et(s,(o||"")+"_"+a))[0])&&tt(u)&&(l[c]=x(u.text+s[0].text),s.shift()),l.push.apply(l,s)):r(s)?tt(u)?l[c]=x(u.text+s):""!==s&&l.push(x(s)):tt(s)&&tt(u)?l[c]=x(u.text+s.text):(n(i._isVList)&&e(s.tag)&&t(s.key)&&e(o)&&(s.key="__vlist"+o+"_"+a+"__"),l.push(s)));return l}function nt(t,e){return(t.__esModule||fr&&"Module"===t[Symbol.toStringTag])&&(t=t.default),i(t)?e.extend(t):t}function rt(t){return t.isComment&&t.asyncFactory}function it(t){if(Array.isArray(t))for(var n=0;n=0||n.indexOf(t[i])<0)&&r.push(t[i]);return r}return t}}(n[o],r[o],i[o]));return e}(t);r&&h(t.extendOptions,r),(e=t.options=F(n,t.extendOptions)).name&&(e.components[e.name]=t)}}return e}function Rt(t){this._init(t)}function Ht(t){t.cid=0;var e=1;t.extend=function(t){t=t||{};var n=this,r=n.cid,i=t._Ctor||(t._Ctor={});if(i[r])return i[r];var o=t.name||n.options.name,a=function(t){this._init(t)};return a.prototype=Object.create(n.prototype),a.prototype.constructor=a,a.cid=e++,a.options=F(n.options,t),a.super=n,a.options.props&&function(t){var e=t.options.props;for(var n in e)mt(t.prototype,"_props",n)}(a),a.options.computed&&function(t){var e=t.options.computed;for(var n in e)gt(t.prototype,n,e[n])}(a),a.extend=n.extend,a.mixin=n.mixin,a.use=n.use,zn.forEach(function(t){a[t]=n[t]}),o&&(a.options.components[o]=a),a.superOptions=n.options,a.extendOptions=t,a.sealedOptions=h({},a.options),i[r]=a,a}}function Bt(t){return t&&(t.Ctor.options.name||t.tag)}function Ut(t,e){return Array.isArray(t)?t.indexOf(e)>-1:"string"==typeof t?t.split(",").indexOf(e)>-1:!!function(t){return"[object RegExp]"===Nn.call(t)}(t)&&t.test(e)}function Vt(t,e){var n=t.cache,r=t.keys,i=t._vnode;for(var o in n){var a=n[o];if(a){var s=Bt(a.componentOptions);s&&!e(s)&&zt(n,o,r,i)}}}function zt(t,e,n,r){var i=t[e];!i||r&&i.tag===r.tag||i.componentInstance.$destroy(),t[e]=null,l(n,e)}function Kt(t){for(var n=t.data,r=t,i=t;e(i.componentInstance);)(i=i.componentInstance._vnode)&&i.data&&(n=Jt(i.data,n));for(;e(r=r.parent);)r&&r.data&&(n=Jt(n,r.data));return function(t,n){if(e(t)||e(n))return qt(t,Wt(n));return""}(n.staticClass,n.class)}function Jt(t,n){return{staticClass:qt(t.staticClass,n.staticClass),class:e(t.class)?[t.class,n.class]:n.class}}function qt(t,e){return t?e?t+" "+e:t:e||""}function Wt(t){return Array.isArray(t)?function(t){for(var n,r="",i=0,o=t.length;i=0&&" "===(m=t.charAt(h));h--);m&&Ii.test(m)||(l=!0)}}else void 0===o?(v=i+1,o=t.slice(0,i).trim()):e();if(void 0===o?o=t.slice(0,i).trim():0!==v&&e(),a)for(i=0;i-1?{exp:t.slice(0,ii),key:'"'+t.slice(ii+1)+'"'}:{exp:t,key:null};ni=t,ii=oi=ai=0;for(;!_e();)be(ri=ge())?$e(ri):91===ri&&function(t){var e=1;oi=ii;for(;!_e();)if(t=ge(),be(t))$e(t);else if(91===t&&e++,93===t&&e--,0===e){ai=ii;break}}(ri);return{exp:t.slice(0,oi),key:t.slice(oi+1,ai)}}(t);return null===n.key?t+"="+e:"$set("+n.exp+", "+n.key+", "+e+")"}function ge(){return ni.charCodeAt(++ii)}function _e(){return ii>=ei}function be(t){return 34===t||39===t}function $e(t){for(var e=t;!_e()&&(t=ge())!==e;);}function Ce(t,e,n,r,i){e=function(t){return t._withTask||(t._withTask=function(){Er=!0;var e=t.apply(null,arguments);return Er=!1,e})}(e),n&&(e=function(t,e,n){var r=si;return function i(){null!==t.apply(null,arguments)&&we(e,i,n,r)}}(e,t,r)),si.addEventListener(t,e,or?{capture:r,passive:i}:r)}function we(t,e,n,r){(r||si).removeEventListener(t,e._withTask||e,n)}function xe(n,r){if(!t(n.data.on)||!t(r.data.on)){var i=r.data.on||{},o=n.data.on||{};si=r.elm,function(t){if(e(t[Li])){var n=Qn?"change":"input";t[n]=[].concat(t[Li],t[n]||[]),delete t[Li]}e(t[Mi])&&(t.change=[].concat(t[Mi],t.change||[]),delete t[Mi])}(i),X(i,o,Ce,we,r.context),si=void 0}}function ke(n,r){if(!t(n.data.domProps)||!t(r.data.domProps)){var i,o,a=r.elm,s=n.data.domProps||{},u=r.data.domProps||{};e(u.__ob__)&&(u=r.data.domProps=h({},u));for(i in s)t(u[i])&&(a[i]="");for(i in u){if(o=u[i],"textContent"===i||"innerHTML"===i){if(r.children&&(r.children.length=0),o===s[i])continue;1===a.childNodes.length&&a.removeChild(a.childNodes[0])}if("value"===i){a._value=o;var l=t(o)?"":String(o);(function(t,n){return!t.composing&&("OPTION"===t.tagName||function(t,e){var n=!0;try{n=document.activeElement!==t}catch(t){}return n&&t.value!==e}(t,n)||function(t,n){var r=t.value,i=t._vModifiers;if(e(i)){if(i.lazy)return!1;if(i.number)return c(r)!==c(n);if(i.trim)return r.trim()!==n.trim()}return r!==n}(t,n))})(a,l)&&(a.value=l)}else a[i]=o}}}function Ae(t){var e=Oe(t.style);return t.staticStyle?h(t.staticStyle,e):e}function Oe(t){return Array.isArray(t)?m(t):"string"==typeof t?Fi(t):t}function Se(n,r){var i=r.data,o=n.data;if(!(t(i.staticStyle)&&t(i.style)&&t(o.staticStyle)&&t(o.style))){var a,s,c=r.elm,u=o.staticStyle,l=o.normalizedStyle||o.style||{},f=u||l,p=Oe(r.data.style)||{};r.data.normalizedStyle=e(p.__ob__)?h({},p):p;var d=function(t,e){var n,r={};if(e)for(var i=t;i.componentInstance;)(i=i.componentInstance._vnode)&&i.data&&(n=Ae(i.data))&&h(r,n);(n=Ae(t.data))&&h(r,n);for(var o=t;o=o.parent;)o.data&&(n=Ae(o.data))&&h(r,n);return r}(r,!0);for(s in f)t(d[s])&&Bi(c,s,"");for(s in d)(a=d[s])!==f[s]&&Bi(c,s,null==a?"":a)}}function Te(t,e){if(e&&(e=e.trim()))if(t.classList)e.indexOf(" ")>-1?e.split(/\s+/).forEach(function(e){return t.classList.add(e)}):t.classList.add(e);else{var n=" "+(t.getAttribute("class")||"")+" ";n.indexOf(" "+e+" ")<0&&t.setAttribute("class",(n+e).trim())}}function Ee(t,e){if(e&&(e=e.trim()))if(t.classList)e.indexOf(" ")>-1?e.split(/\s+/).forEach(function(e){return t.classList.remove(e)}):t.classList.remove(e),t.classList.length||t.removeAttribute("class");else{for(var n=" "+(t.getAttribute("class")||"")+" ",r=" "+e+" ";n.indexOf(r)>=0;)n=n.replace(r," ");(n=n.trim())?t.setAttribute("class",n):t.removeAttribute("class")}}function je(t){if(t){if("object"==typeof t){var e={};return!1!==t.css&&h(e,Ki(t.name||"v")),h(e,t),e}return"string"==typeof t?Ki(t):void 0}}function Ne(t){Qi(function(){Qi(t)})}function Ie(t,e){var n=t._transitionClasses||(t._transitionClasses=[]);n.indexOf(e)<0&&(n.push(e),Te(t,e))}function Le(t,e){t._transitionClasses&&l(t._transitionClasses,e),Ee(t,e)}function Me(t,e,n){var r=De(t,e),i=r.type,o=r.timeout,a=r.propCount;if(!i)return n();var s=i===qi?Zi:Yi,c=0,u=function(){t.removeEventListener(s,l),n()},l=function(e){e.target===t&&++c>=a&&u()};setTimeout(function(){c0&&(n=qi,l=a,f=o.length):e===Wi?u>0&&(n=Wi,l=u,f=c.length):f=(n=(l=Math.max(a,u))>0?a>u?qi:Wi:null)?n===qi?o.length:c.length:0;return{type:n,timeout:l,propCount:f,hasTransform:n===qi&&to.test(r[Gi+"Property"])}}function Pe(t,e){for(;t.length1}function Ve(t,e){!0!==e.data.show&&Re(e)}function ze(t,e,n){Ke(t,e,n),(Qn||er)&&setTimeout(function(){Ke(t,e,n)},0)}function Ke(t,e,n){var r=e.value,i=t.multiple;if(!i||Array.isArray(r)){for(var o,a,s=0,c=t.options.length;s-1,a.selected!==o&&(a.selected=o);else if(g(qe(a),r))return void(t.selectedIndex!==s&&(t.selectedIndex=s));i||(t.selectedIndex=-1)}}function Je(t,e){return e.every(function(e){return!g(e,t)})}function qe(t){return"_value"in t?t._value:t.value}function We(t){t.target.composing=!0}function Ge(t){t.target.composing&&(t.target.composing=!1,Ze(t.target,"input"))}function Ze(t,e){var n=document.createEvent("HTMLEvents");n.initEvent(e,!0,!0),t.dispatchEvent(n)}function Xe(t){return!t.componentInstance||t.data&&t.data.transition?t:Xe(t.componentInstance._vnode)}function Ye(t){var e=t&&t.componentOptions;return e&&e.Ctor.options.abstract?Ye(it(e.children)):t}function Qe(t){var e={},n=t.$options;for(var r in n.propsData)e[r]=t[r];var i=n._parentListeners;for(var o in i)e[Pn(o)]=i[o];return e}function tn(t,e){if(/\d-keep-alive$/.test(e.tag))return t("keep-alive",{props:e.componentOptions.propsData})}function en(t){t.elm._moveCb&&t.elm._moveCb(),t.elm._enterCb&&t.elm._enterCb()}function nn(t){t.data.newPos=t.elm.getBoundingClientRect()}function rn(t){var e=t.data.pos,n=t.data.newPos,r=e.left-n.left,i=e.top-n.top;if(r||i){t.data.moved=!0;var o=t.elm.style;o.transform=o.WebkitTransform="translate("+r+"px,"+i+"px)",o.transitionDuration="0s"}}function on(t,e){var n=e?zo:Vo;return t.replace(n,function(t){return Uo[t]})}function an(t,e,n){return{type:1,tag:t,attrsList:e,attrsMap:function(t){for(var e={},n=0,r=t.length;n=0&&a[i].lowerCasedTag!==s;i--);else i=0;if(i>=0){for(var c=a.length-1;c>=i;c--)e.end&&e.end(a[c].tag,n,r);a.length=i,o=i&&a[i-1].tag}else"br"===s?e.start&&e.start(t,[],!0,n,r):"p"===s&&(e.start&&e.start(t,[],!1,n,r),e.end&&e.end(t,n,r))}for(var i,o,a=[],s=e.expectHTML,c=e.isUnaryTag||Bn,u=e.canBeLeftOpenTag||Bn,l=0;t;){if(i=t,o&&Ho(o)){var f=0,p=o.toLowerCase(),d=Bo[p]||(Bo[p]=new RegExp("([\\s\\S]*?)("+p+"[^>]*>)","i")),v=t.replace(d,function(t,n,r){return f=r.length,Ho(p)||"noscript"===p||(n=n.replace(//g,"$1").replace(//g,"$1")),Jo(p,n)&&(n=n.slice(1)),e.chars&&e.chars(n),""});l+=t.length-v.length,t=v,r(p,l-f,l)}else{var h=t.indexOf("<");if(0===h){if(Ao.test(t)){var m=t.indexOf("--\x3e");if(m>=0){e.shouldKeepComment&&e.comment(t.substring(4,m)),n(m+3);continue}}if(Oo.test(t)){var y=t.indexOf("]>");if(y>=0){n(y+2);continue}}var g=t.match(ko);if(g){n(g[0].length);continue}var _=t.match(xo);if(_){var b=l;n(_[0].length),r(_[1],b,l);continue}var $=function(){var e=t.match(Co);if(e){var r={tagName:e[1],attrs:[],start:l};n(e[0].length);for(var i,o;!(i=t.match(wo))&&(o=t.match(_o));)n(o[0].length),r.attrs.push(o);if(i)return r.unarySlash=i[1],n(i[0].length),r.end=l,r}}();if($){!function(t){var n=t.tagName,i=t.unarySlash;s&&("p"===o&&go(n)&&r(o),u(n)&&o===n&&r(n));for(var l=c(n)||!!i,f=t.attrs.length,p=new Array(f),d=0;d=0){for(w=t.slice(h);!(xo.test(w)||Co.test(w)||Ao.test(w)||Oo.test(w)||(x=w.indexOf("<",1))<0);)h+=x,w=t.slice(h);C=t.substring(0,h),n(h)}h<0&&(C=t,t=""),e.chars&&C&&e.chars(C)}if(t===i){e.chars&&e.chars(t);break}}r()}(t,{warn:To,expectHTML:e.expectHTML,isUnaryTag:e.isUnaryTag,canBeLeftOpenTag:e.canBeLeftOpenTag,shouldDecodeNewlines:e.shouldDecodeNewlines,shouldDecodeNewlinesForHref:e.shouldDecodeNewlinesForHref,shouldKeepComment:e.comments,start:function(t,a,u){var l=i&&i.ns||Do(t);Qn&&"svg"===l&&(a=function(t){for(var e=[],n=0;nc&&(s.push(o=t.slice(c,i)),a.push(JSON.stringify(o)));var u=ae(r[1].trim());a.push("_s("+u+")"),s.push({"@binding":u}),c=i+r[0].length}return c':'',Ro.innerHTML.indexOf("
")>0}var jn=Object.freeze({}),Nn=Object.prototype.toString,In=u("slot,component",!0),Ln=u("key,ref,slot,slot-scope,is"),Mn=Object.prototype.hasOwnProperty,Dn=/-(\w)/g,Pn=p(function(t){return t.replace(Dn,function(t,e){return e?e.toUpperCase():""})}),Fn=p(function(t){return t.charAt(0).toUpperCase()+t.slice(1)}),Rn=/\B([A-Z])/g,Hn=p(function(t){return t.replace(Rn,"-$1").toLowerCase()}),Bn=function(t,e,n){return!1},Un=function(t){return t},Vn="data-server-rendered",zn=["component","directive","filter"],Kn=["beforeCreate","created","beforeMount","mounted","beforeUpdate","updated","beforeDestroy","destroyed","activated","deactivated","errorCaptured"],Jn={optionMergeStrategies:Object.create(null),silent:!1,productionTip:!1,devtools:!1,performance:!1,errorHandler:null,warnHandler:null,ignoredElements:[],keyCodes:Object.create(null),isReservedTag:Bn,isReservedAttr:Bn,isUnknownElement:Bn,getTagNamespace:y,parsePlatformTagName:Un,mustUseProp:Bn,_lifecycleHooks:Kn},qn=/[^\w.$]/,Wn="__proto__"in{},Gn="undefined"!=typeof window,Zn="undefined"!=typeof WXEnvironment&&!!WXEnvironment.platform,Xn=Zn&&WXEnvironment.platform.toLowerCase(),Yn=Gn&&window.navigator.userAgent.toLowerCase(),Qn=Yn&&/msie|trident/.test(Yn),tr=Yn&&Yn.indexOf("msie 9.0")>0,er=Yn&&Yn.indexOf("edge/")>0,nr=Yn&&Yn.indexOf("android")>0||"android"===Xn,rr=Yn&&/iphone|ipad|ipod|ios/.test(Yn)||"ios"===Xn,ir=(Yn&&/chrome\/\d+/.test(Yn),{}.watch),or=!1;if(Gn)try{var ar={};Object.defineProperty(ar,"passive",{get:function(){or=!0}}),window.addEventListener("test-passive",null,ar)}catch(t){}var sr,cr,ur=function(){return void 0===sr&&(sr=!Gn&&"undefined"!=typeof global&&"server"===global.process.env.VUE_ENV),sr},lr=Gn&&window.__VUE_DEVTOOLS_GLOBAL_HOOK__,fr="undefined"!=typeof Symbol&&w(Symbol)&&"undefined"!=typeof Reflect&&w(Reflect.ownKeys);cr="undefined"!=typeof Set&&w(Set)?Set:function(){function t(){this.set=Object.create(null)}return t.prototype.has=function(t){return!0===this.set[t]},t.prototype.add=function(t){this.set[t]=!0},t.prototype.clear=function(){this.set=Object.create(null)},t}();var pr=y,dr=0,vr=function(){this.id=dr++,this.subs=[]};vr.prototype.addSub=function(t){this.subs.push(t)},vr.prototype.removeSub=function(t){l(this.subs,t)},vr.prototype.depend=function(){vr.target&&vr.target.addDep(this)},vr.prototype.notify=function(){for(var t=this.subs.slice(),e=0,n=t.length;eVr&&Fr[n].id>t.id;)n--;Fr.splice(n+1,0,t)}else Fr.push(t);Br||(Br=!0,q(ht))}}(this)},Kr.prototype.run=function(){if(this.active){var t=this.get();if(t!==this.value||i(t)||this.deep){var e=this.value;if(this.value=t,this.user)try{this.cb.call(this.vm,t,e)}catch(t){V(t,this.vm,'callback for watcher "'+this.expression+'"')}else this.cb.call(this.vm,t,e)}}},Kr.prototype.evaluate=function(){this.value=this.get(),this.dirty=!1},Kr.prototype.depend=function(){for(var t=this.deps.length;t--;)this.deps[t].depend()},Kr.prototype.teardown=function(){if(this.active){this.vm._isBeingDestroyed||l(this.vm._watchers,this);for(var t=this.deps.length;t--;)this.deps[t].removeSub(this);this.active=!1}};var Jr={enumerable:!0,configurable:!0,get:y,set:y},qr={lazy:!0};Nt(It.prototype);var Wr={init:function(t,n,r,i){if(!t.componentInstance||t.componentInstance._isDestroyed){(t.componentInstance=function(t,n,r,i){var o={_isComponent:!0,parent:n,_parentVnode:t,_parentElm:r||null,_refElm:i||null},a=t.data.inlineTemplate;return e(a)&&(o.render=a.render,o.staticRenderFns=a.staticRenderFns),new t.componentOptions.Ctor(o)}(t,Pr,r,i)).$mount(n?t.elm:void 0,n)}else if(t.data.keepAlive){var o=t;Wr.prepatch(o,o)}},prepatch:function(t,e){var n=e.componentOptions;!function(t,e,n,r,i){var o=!!(i||t.$options._renderChildren||r.data.scopedSlots||t.$scopedSlots!==jn);if(t.$options._parentVnode=r,t.$vnode=r,t._vnode&&(t._vnode.parent=r),t.$options._renderChildren=i,t.$attrs=r.data&&r.data.attrs||jn,t.$listeners=n||jn,e&&t.$options.props){Cr.shouldConvert=!1;for(var a=t._props,s=t.$options._propKeys||[],c=0;c1?v(n):n;for(var r=v(arguments,1),i=0,o=n.length;iparseInt(this.max)&&zt(a,s[0],s,this._vnode)),e.data.keepAlive=!0}return e||t&&t[0]}}};!function(t){var e={};e.get=function(){return Jn},Object.defineProperty(t,"config",e),t.util={warn:pr,extend:h,mergeOptions:F,defineReactive:E},t.set=j,t.delete=N,t.nextTick=q,t.options=Object.create(null),zn.forEach(function(e){t.options[e+"s"]=Object.create(null)}),t.options._base=t,h(t.options.components,ti),function(t){t.use=function(t){var e=this._installedPlugins||(this._installedPlugins=[]);if(e.indexOf(t)>-1)return this;var n=v(arguments,1);return n.unshift(this),"function"==typeof t.install?t.install.apply(t,n):"function"==typeof t&&t.apply(null,n),e.push(t),this}}(t),function(t){t.mixin=function(t){return this.options=F(this.options,t),this}}(t),Ht(t),function(t){zn.forEach(function(e){t[e]=function(t,n){return n?("component"===e&&o(n)&&(n.name=n.name||t,n=this.options._base.extend(n)),"directive"===e&&"function"==typeof n&&(n={bind:n,update:n}),this.options[e+"s"][t]=n,n):this.options[e+"s"][t]}})}(t)}(Rt),Object.defineProperty(Rt.prototype,"$isServer",{get:ur}),Object.defineProperty(Rt.prototype,"$ssrContext",{get:function(){return this.$vnode&&this.$vnode.ssrContext}}),Rt.version="2.5.13";var ei,ni,ri,ii,oi,ai,si,ci,ui=u("style,class"),li=u("input,textarea,option,select,progress"),fi=function(t,e,n){return"value"===n&&li(t)&&"button"!==e||"selected"===n&&"option"===t||"checked"===n&&"input"===t||"muted"===n&&"video"===t},pi=u("contenteditable,draggable,spellcheck"),di=u("allowfullscreen,async,autofocus,autoplay,checked,compact,controls,declare,default,defaultchecked,defaultmuted,defaultselected,defer,disabled,enabled,formnovalidate,hidden,indeterminate,inert,ismap,itemscope,loop,multiple,muted,nohref,noresize,noshade,novalidate,nowrap,open,pauseonexit,readonly,required,reversed,scoped,seamless,selected,sortable,translate,truespeed,typemustmatch,visible"),vi="http://www.w3.org/1999/xlink",hi=function(t){return":"===t.charAt(5)&&"xlink"===t.slice(0,5)},mi=function(t){return hi(t)?t.slice(6,t.length):""},yi=function(t){return null==t||!1===t},gi={svg:"http://www.w3.org/2000/svg",math:"http://www.w3.org/1998/Math/MathML"},_i=u("html,body,base,head,link,meta,style,title,address,article,aside,footer,header,h1,h2,h3,h4,h5,h6,hgroup,nav,section,div,dd,dl,dt,figcaption,figure,picture,hr,img,li,main,ol,p,pre,ul,a,b,abbr,bdi,bdo,br,cite,code,data,dfn,em,i,kbd,mark,q,rp,rt,rtc,ruby,s,samp,small,span,strong,sub,sup,time,u,var,wbr,area,audio,map,track,video,embed,object,param,source,canvas,script,noscript,del,ins,caption,col,colgroup,table,thead,tbody,td,th,tr,button,datalist,fieldset,form,input,label,legend,meter,optgroup,option,output,progress,select,textarea,details,dialog,menu,menuitem,summary,content,element,shadow,template,blockquote,iframe,tfoot"),bi=u("svg,animate,circle,clippath,cursor,defs,desc,ellipse,filter,font-face,foreignObject,g,glyph,image,line,marker,mask,missing-glyph,path,pattern,polygon,polyline,rect,switch,symbol,text,textpath,tspan,use,view",!0),$i=function(t){return _i(t)||bi(t)},Ci=Object.create(null),wi=u("text,number,password,search,email,tel,url"),xi=Object.freeze({createElement:function(t,e){var n=document.createElement(t);return"select"!==t?n:(e.data&&e.data.attrs&&void 0!==e.data.attrs.multiple&&n.setAttribute("multiple","multiple"),n)},createElementNS:function(t,e){return document.createElementNS(gi[t],e)},createTextNode:function(t){return document.createTextNode(t)},createComment:function(t){return document.createComment(t)},insertBefore:function(t,e,n){t.insertBefore(e,n)},removeChild:function(t,e){t.removeChild(e)},appendChild:function(t,e){t.appendChild(e)},parentNode:function(t){return t.parentNode},nextSibling:function(t){return t.nextSibling},tagName:function(t){return t.tagName},setTextContent:function(t,e){t.textContent=e},setAttribute:function(t,e,n){t.setAttribute(e,n)}}),ki={create:function(t,e){Xt(e)},update:function(t,e){t.data.ref!==e.data.ref&&(Xt(t,!0),Xt(e))},destroy:function(t){Xt(t,!0)}},Ai=new mr("",{},[]),Oi=["create","activate","update","remove","destroy"],Si={create:te,update:te,destroy:function(t){te(t,Ai)}},Ti=Object.create(null),Ei=[ki,Si],ji={create:re,update:re},Ni={create:oe,update:oe},Ii=/[\w).+\-_$\]]/,Li="__r",Mi="__c",Di={create:xe,update:xe},Pi={create:ke,update:ke},Fi=p(function(t){var e={},n=/:(.+)/;return t.split(/;(?![^(]*\))/g).forEach(function(t){if(t){var r=t.split(n);r.length>1&&(e[r[0].trim()]=r[1].trim())}}),e}),Ri=/^--/,Hi=/\s*!important$/,Bi=function(t,e,n){if(Ri.test(e))t.style.setProperty(e,n);else if(Hi.test(n))t.style.setProperty(e,n.replace(Hi,""),"important");else{var r=Vi(e);if(Array.isArray(n))for(var i=0,o=n.length;id?v(n,t(i[g+1])?null:i[g+1].elm,i,p,g,o):p>g&&m(0,r,f,d)}function _(r,i,o,a){if(r!==i){var s=i.elm=r.elm;if(n(r.isAsyncPlaceholder))e(i.asyncFactory.resolved)?$(r.elm,i,o):i.isAsyncPlaceholder=!0;else if(n(i.isStatic)&&n(r.isStatic)&&i.key===r.key&&(n(i.isCloned)||n(i.isOnce)))i.componentInstance=r.componentInstance;else{var c,u=i.data;e(u)&&e(c=u.hook)&&e(c=c.prepatch)&&c(r,i);var l=r.children,p=i.children;if(e(u)&&f(i)){for(c=0;c-1?Ci[t]=e.constructor===window.HTMLUnknownElement||e.constructor===window.HTMLElement:Ci[t]=/HTMLUnknownElement/.test(e.toString())},h(Rt.options.directives,ro),h(Rt.options.components,so),Rt.prototype.__patch__=Gn?eo:y,Rt.prototype.$mount=function(t,e){return t=t&&Gn?Zt(t):void 0,function(t,e,n){t.$el=e,t.$options.render||(t.$options.render=gr),vt(t,"beforeMount");var r;return r=function(){t._update(t._render(),n)},new Kr(t,r,y,null,!0),n=!1,null==t.$vnode&&(t._isMounted=!0,vt(t,"mounted")),t}(this,t,e)},Rt.nextTick(function(){Jn.devtools&&lr&&lr.emit("init",Rt)},0);var co,uo=/\{\{((?:.|\n)+?)\}\}/g,lo=/[-.*+?^${}()|[\]\/\\]/g,fo=p(function(t){var e=t[0].replace(lo,"\\$&"),n=t[1].replace(lo,"\\$&");return new RegExp(e+"((?:.|\\n)+?)"+n,"g")}),po={staticKeys:["staticClass"],transformNode:function(t,e){e.warn;var n=he(t,"class");n&&(t.staticClass=JSON.stringify(n));var r=ve(t,"class",!1);r&&(t.classBinding=r)},genData:function(t){var e="";return t.staticClass&&(e+="staticClass:"+t.staticClass+","),t.classBinding&&(e+="class:"+t.classBinding+","),e}},vo={staticKeys:["staticStyle"],transformNode:function(t,e){e.warn;var n=he(t,"style");n&&(t.staticStyle=JSON.stringify(Fi(n)));var r=ve(t,"style",!1);r&&(t.styleBinding=r)},genData:function(t){var e="";return t.staticStyle&&(e+="staticStyle:"+t.staticStyle+","),t.styleBinding&&(e+="style:("+t.styleBinding+"),"),e}},ho=function(t){return co=co||document.createElement("div"),co.innerHTML=t,co.textContent},mo=u("area,base,br,col,embed,frame,hr,img,input,isindex,keygen,link,meta,param,source,track,wbr"),yo=u("colgroup,dd,dt,li,options,p,td,tfoot,th,thead,tr,source"),go=u("address,article,aside,base,blockquote,body,caption,col,colgroup,dd,details,dialog,div,dl,dt,fieldset,figcaption,figure,footer,form,h1,h2,h3,h4,h5,h6,head,header,hgroup,hr,html,legend,li,menuitem,meta,optgroup,option,param,rp,rt,source,style,summary,tbody,td,tfoot,th,thead,title,tr,track"),_o=/^\s*([^\s"'<>\/=]+)(?:\s*(=)\s*(?:"([^"]*)"+|'([^']*)'+|([^\s"'=<>`]+)))?/,bo="[a-zA-Z_][\\w\\-\\.]*",$o="((?:"+bo+"\\:)?"+bo+")",Co=new RegExp("^<"+$o),wo=/^\s*(\/?)>/,xo=new RegExp("^<\\/"+$o+"[^>]*>"),ko=/^]+>/i,Ao=/^
16 |