Skip to content

Commit e9666db

Browse files
authored
docs(components): [date-picker] attribute type description (element-plus#9357)
* docs(components): fix 'date-picker' attribute type description * docs(components): revert 'date-picker' attribute description * docs(components): fix 'datetime-picker' attribute type description * docs(components): fix 'time-picker' attribute type description * docs(components): format * docs(components): fix type, optimization description
1 parent e1f8d7e commit e9666db

File tree

7 files changed

+71
-65
lines changed

7 files changed

+71
-65
lines changed

β€Ždocs/en-US/component/date-picker.mdβ€Ž

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ Note, date time locale (month name, first day of the week ...) are also configur
141141

142142
| Attribute | Description | Type | Accepted Values | Default |
143143
| --------------------- | ----------------------------------------------------------------------------------------------------- | ------------------------------------------------ | ----------------------------------------------------------------------------------------------------------------- | ----------- |
144-
| model-value / v-model | binding value | date(DatePicker) / array(DateRangePicker) | β€” | β€” |
144+
| model-value / v-model | binding value, if it is an array, the length should be 2 | Date / number / string / Array | β€” | β€” |
145145
| readonly | whether DatePicker is read only | boolean | β€” | false |
146146
| disabled | whether DatePicker is disabled | boolean | β€” | false |
147147
| size | size of Input | string | large/default/small | default |
@@ -154,15 +154,15 @@ Note, date time locale (month name, first day of the week ...) are also configur
154154
| format | format of the displayed value in the input box | string | see [date formats](/en-US/component/date-picker#date-formats) | YYYY-MM-DD |
155155
| popper-class | custom class name for DatePicker's dropdown | string | β€” | β€” |
156156
| range-separator | range separator | string | β€” | '-' |
157-
| default-value | optional, default date of the calendar | Date | anything accepted by `new Date()` | β€” |
158-
| default-time | optional, the time value to use when selecting date range | Date[] | Array with length 2, each item is a Date. The first item for the start date and then second item for the end date | β€” |
157+
| default-value | optional, default date of the calendar | Date / [Date, Date] | β€” | β€” |
158+
| default-time | optional, the time value to use when selecting date range | Date / [Date, Date] | Array with length 2, each item is a Date. The first item for the start date and then second item for the end date | β€” |
159159
| value-format | optional, format of binding value. If not specified, the binding value will be a Date object | string | see [date formats](/en-US/component/date-picker#date-formats) | β€” |
160-
| id | same as `id` in native input | string / array(string) | String `id="my-date"` or array `:id="['my-range-start', 'my-range-end']"` for date range | - |
160+
| id | same as `id` in native input | string / array(string) | String `id="my-date"` or array `:id="['my-range-start', 'my-range-end']"` for date range | β€” |
161161
| name | same as `name` in native input | string | β€” | β€” |
162162
| unlink-panels | unlink two date-panels in range-picker | boolean | β€” | false |
163163
| prefix-icon | custom prefix icon component | `string \| Component` | β€” | Date |
164164
| clear-icon | custom clear icon component | `string \| Component` | β€” | CircleClose |
165-
| validate-event | whether to trigger form validation | boolean | - | true |
165+
| validate-event | whether to trigger form validation | boolean | β€” | true |
166166
| disabled-date | a function determining if a date is disabled with that date as its parameter. Should return a Boolean | function | β€” | β€” |
167167
| shortcuts | an object array to set shortcut options | object[{ text: string, value: date / function }] | β€” | β€” |
168168
| cell-class-name | set custom className | Function(Date) | β€” | β€” |

0 commit comments

Comments
Β (0)