File tree 3 files changed +36
-2
lines changed
3 files changed +36
-2
lines changed Original file line number Diff line number Diff line change 5
5
| 属性 | 说明 | 类型 | 默认 | 是否必传 |
6
6
| :-------------------------- | :---------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :------------------------------------------------------------------------------------------------------------------------------------------------------------: | :------------: | :------: |
7
7
| visible | 控制日历组件的显示或隐藏,需使用 ` v-model:visible ` | Boolean | false | 否 |
8
- | scrollChangeDate | 控制滑动的时候是否修改选中的日期 | Boolean | true | 否 |
8
+ | scroll-change-date | 控制滑动的时候是否修改选中的日期 | Boolean | true | 否 |
9
9
| model | 日历组件以哪种形式展示。inline:内联的方式。dialog:弹窗的方式 | String | inline | 否 |
10
- | defaultDatetime | 指定默认时间。 | Date | 当前时间 | 否 |
10
+ | default-datetime | 指定默认时间。 | Date | 当前时间 | 否 |
11
11
| minDate | 指定日历最小日期范围,设置之后只能在该范围内滑动日历。 | Date | -- | 否 |
12
12
| maxDate | 指定日历最大日期范围,设置之后只能在该范围内滑动日历。 | Date | -- | 否 |
13
13
| format | 确认日期时,回调事件返回的日期格式。如“YY/MM/DD hh: mm ” 、“YY 年 MM 月第 DD 天,当前时间 hh 时 mm 分”、“MM DD,YY at hh: mm F” | String | YY/MM/DD hh: mm | 否 |
Original file line number Diff line number Diff line change
1
+ # default-datetime
2
+
3
+ ## 当前时间
4
+
5
+ ### 代码演示
6
+
7
+ ``` html
8
+ <vue-hash-calendar :default-datetime =" new Date()" />
9
+ ```
10
+
11
+ ## 2022/11/05
12
+
13
+ ### 代码演示
14
+
15
+ ``` html
16
+ <vue-hash-calendar :default-datetime =" new Date(2022/11/05)" />
17
+ ```
Original file line number Diff line number Diff line change
1
+ <template >
2
+ <h1 class =" demo-title" >当前时间</h1 >
3
+ <vue-hash-calendar :default-datetime =" new Date()" />
4
+
5
+ <h1 class =" demo-title" >2022/11/05</h1 >
6
+ <vue-hash-calendar :default-datetime =" new Date(2022 / 11 / 05)" />
7
+ </template >
8
+
9
+ <script setup>
10
+ import VueHashCalendar from ' ../../calendar' ;
11
+ </script >
12
+
13
+ <style >
14
+ .demo-title {
15
+ margin : 24px ;
16
+ }
17
+ </style >
You can’t perform that action at this time.
0 commit comments