mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-05-24 07:29:16 +08:00
[Doc] optimize data structure table (#3854)
This commit is contained in:
parent
5c70473f87
commit
d15315b8e4
@ -117,12 +117,12 @@ export default {
|
||||
| close | Triggered when close ActionSheet | - |
|
||||
| closed | Triggered when closed ActionSheet | - |
|
||||
|
||||
### Data struct of Action
|
||||
### Data Structure of Action
|
||||
|
||||
| key | Description |
|
||||
|------|------|
|
||||
| name | Title |
|
||||
| subname | Subtitle |
|
||||
| className | className for the option |
|
||||
| loading | Whether to be loading status |
|
||||
| disabled | Whether to be disabled |
|
||||
| Key | Description | Type |
|
||||
|------|------|------|
|
||||
| name | Title | `string` |
|
||||
| subname | Subtitle | `string` |
|
||||
| className | className for the option | `any` |
|
||||
| loading | Whether to be loading status | `boolean` |
|
||||
| disabled | Whether to be disabled | `boolean` |
|
||||
|
@ -128,10 +128,10 @@ export default {
|
||||
|
||||
`Props`中的`actions`为一个对象数组,数组中的每一个对象配置每一列,每一列有以下`key`:
|
||||
|
||||
| key | 说明 |
|
||||
|------|------|
|
||||
| name | 标题 |
|
||||
| subname | 二级标题 |
|
||||
| className | 为对应列添加额外的 class |
|
||||
| loading | 是否为加载状态 |
|
||||
| disabled | 是否为禁用状态 |
|
||||
| 键名 | 说明 | 类型 |
|
||||
|------|------|------|
|
||||
| name | 标题 | `string` |
|
||||
| subname | 二级标题 | `string` |
|
||||
| className | 为对应列添加额外的 class | `any` |
|
||||
| loading | 是否为加载状态 | `boolean` |
|
||||
| disabled | 是否为禁用状态 | `boolean` |
|
||||
|
@ -86,9 +86,9 @@ export default {
|
||||
| edit-disabled | Triggered when edit disabled address | item: address object,index |
|
||||
| select-disabled | Triggered when select disabled address | item: address object,index |
|
||||
|
||||
### Address Data Structure
|
||||
### Data Structure of Address
|
||||
|
||||
| key | Description | Type |
|
||||
| Key | Description | Type |
|
||||
|------|------|------|
|
||||
| id | Id | `string | number` |
|
||||
| name | Name | `string` |
|
||||
|
@ -89,7 +89,7 @@ export default {
|
||||
|
||||
### Address 数据结构
|
||||
|
||||
| key | 说明 | 类型 |
|
||||
| 键名 | 说明 | 类型 |
|
||||
|------|------|------|
|
||||
| id | 每条地址的唯一标识 | `string | number` |
|
||||
| name | 收货人姓名 | `string` |
|
||||
|
@ -180,7 +180,7 @@ export default {
|
||||
| save | Triggered when click save button | content:contact info |
|
||||
| delete | Triggered when click delete button | content:contact info |
|
||||
|
||||
### Contact Data Structure
|
||||
### Data Structure of Contact
|
||||
|
||||
| key | Description | Type |
|
||||
|------|------|------|
|
||||
|
@ -186,7 +186,7 @@ export default {
|
||||
|
||||
### Contact 数据结构
|
||||
|
||||
| key | 说明 | 类型 |
|
||||
| 键名 | 说明 | 类型 |
|
||||
|------|------|------|
|
||||
| id | 每位联系人的唯一标识 | `string | number` |
|
||||
| name | 联系人姓名 | `string` |
|
||||
|
@ -105,9 +105,9 @@ export default {
|
||||
| change | Triggered when change chosen coupon | index: index of chosen coupon |
|
||||
| exchange | Triggered when exchange coupon | code: exchange code |
|
||||
|
||||
### Coupon Data Structure
|
||||
### Data Structure of Coupon
|
||||
|
||||
| key | Description | Type |
|
||||
| Key | Description | Type |
|
||||
|------|------|------|
|
||||
| id | Id | `string` |
|
||||
| name | Name | `string` |
|
||||
|
@ -109,7 +109,7 @@ export default {
|
||||
|
||||
### Coupon 数据结构
|
||||
|
||||
| key | 说明 | 类型 |
|
||||
| 键名 | 说明 | 类型 |
|
||||
|------|------|------|
|
||||
| id | 优惠券 id | `string` |
|
||||
| name | 优惠券名称 | `string` |
|
||||
|
@ -213,13 +213,13 @@ Picker events will pass different parameters according to the columns are single
|
||||
|------|------|
|
||||
| title | Custom title |
|
||||
|
||||
### Column Data Struct
|
||||
### Data Structure of Column
|
||||
|
||||
| key | Description |
|
||||
|------|------|
|
||||
| values | Value of column |
|
||||
| defaultIndex | Default value index |
|
||||
| className | ClassName for this column |
|
||||
| Key | Description | Type |
|
||||
|------|------|------|
|
||||
| values | Value of column | `string[]` |
|
||||
| defaultIndex | Default value index | `number` |
|
||||
| className | ClassName for this column | `any` |
|
||||
|
||||
### Methods
|
||||
|
||||
|
@ -225,11 +225,11 @@ Picker 组件的事件会根据 columns 是单列或多列返回不同的参数
|
||||
|
||||
当传入多列数据时,`columns`为一个对象数组,数组中的每一个对象配置每一列,每一列有以下`key`
|
||||
|
||||
| key | 说明 |
|
||||
|------|------|
|
||||
| values | 列中对应的备选值 |
|
||||
| defaultIndex | 初始选中项的索引,默认为 0 |
|
||||
| className | 为对应列添加额外的`class` |
|
||||
| 键名 | 说明 | 类型 |
|
||||
|------|------|------|
|
||||
| values | 列中对应的备选值 | `string[]`
|
||||
| defaultIndex | 初始选中项的索引,默认为 0 | `number` |
|
||||
| className | 为对应列添加额外的类名 | `any` |
|
||||
|
||||
### 方法
|
||||
|
||||
|
@ -62,7 +62,7 @@ export default {
|
||||
| navclick | triggered when parent node is selected | index: index of selected parent |
|
||||
| itemclick | triggered when item is selected | data: selected item |
|
||||
|
||||
### Item Data Structure
|
||||
### Data Structure of Item
|
||||
|
||||
`items` should be an array contains specified tree objects.
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user