docs(rate): update type definition (#5474)

pull/5477/head
bqy_fe 2022-04-09 22:19:46 +08:00 committed by GitHub
parent 4724c0415e
commit 8fbdbb13a6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 20 additions and 20 deletions

View File

@ -15,14 +15,14 @@ Rate component.
## API ## API
| Property | Description | type | Default | | Property | Description | type | Default |
| --- | --- | --- | --- | | -------------- | --------------------------------------- | -------------- | ------------------ |
| allowClear | whether to allow clear when click again | boolean | true | | allowClear | whether to allow clear when click again | boolean | true |
| allowHalf | whether to allow semi selection | boolean | false | | allowHalf | whether to allow semi selection | boolean | false |
| autofocus | get focus when component mounted | boolean | false | | autofocus | get focus when component mounted | boolean | false |
| character | custom character of rate | String or slot="character" | `<StarOutlined />` | | character | custom character of rate | string \| slot | `<StarOutlined />` |
| count | star count | number | 5 | | count | star count | number | 5 |
| disabled | read only, unable to interact | boolean | false | | disabled | read only, unable to interact | boolean | false |
| tooltips | Customize tooltip by each character | string\[] | - | | tooltips | Customize tooltip by each character | string[] | - |
| value(v-model) | current value | number | - | | value(v-model) | current value | number | - |
### events ### events

View File

@ -16,14 +16,14 @@ cover: https://gw.alipayobjects.com/zos/alicdn/R5uiIWmxe/Rate.svg
## API ## API
| 属性 | 说明 | 类型 | 默认值 | | 属性 | 说明 | 类型 | 默认值 |
| -------------- | ---------------------- | -------------------------- | ------------------ | | -------------- | ---------------------- | -------------- | ------------------ |
| allowClear | 是否允许再次点击后清除 | boolean | true | | allowClear | 是否允许再次点击后清除 | boolean | true |
| allowHalf | 是否允许半选 | boolean | false | | allowHalf | 是否允许半选 | boolean | false |
| autofocus | 自动获取焦点 | boolean | false | | autofocus | 自动获取焦点 | boolean | false |
| character | 自定义字符 | String or slot="character" | `<StarOutlined />` | | character | 自定义字符 | string \| slot | `<StarOutlined />` |
| count | star 总数 | number | 5 | | count | star 总数 | number | 5 |
| disabled | 只读,无法进行交互 | boolean | false | | disabled | 只读,无法进行交互 | boolean | false |
| tooltips | 自定义每项的提示信息 | string\[] | - | | tooltips | 自定义每项的提示信息 | string[] | - |
| value(v-model) | 当前数,受控值 | number | - | | value(v-model) | 当前数,受控值 | number | - |
### 事件 ### 事件