naive-ui/demo/documentation/components/collapse/zhCN/index.md

47 lines
888 B
Markdown
Raw Normal View History

2020-02-03 21:20:21 +08:00
# 折叠面板 Collapse
2020-02-03 21:07:58 +08:00
我看到它总被用在界面边栏的控制面板上。
## 演示
2019-12-02 03:57:34 +08:00
```demo
basic
accordion
nested
item-header-click
2019-12-02 03:57:34 +08:00
```
2020-02-03 21:07:58 +08:00
## V-model
|Prop|Event|
|-|-|
|expanded-names|expanded-names-change|
2020-02-03 21:07:58 +08:00
## Props
### Collapse Props
2020-02-07 23:40:07 +08:00
|名称|类型|默认值|说明|
2020-02-03 21:07:58 +08:00
|-|-|-|-|
2020-03-12 21:32:47 +08:00
|theme|`'light' \| 'dark'`|`null`||
|expanded-names|`Array`|`null`||
2020-02-03 21:07:58 +08:00
|accordion|`boolean`|`false`||
### Collapse Item Props
2020-02-07 23:40:07 +08:00
|名称|类型|默认值|说明|
2020-02-03 21:07:58 +08:00
|-|-|-|-|
|title|`string \| number`|`null`||
|name|`string \| number`||**必需**|
2020-02-03 21:20:21 +08:00
## Slots
### Collapse Slots
2020-02-07 23:40:07 +08:00
|名称|参数|说明|
2020-02-03 21:20:21 +08:00
|-|-|-|
|default|`()`||
### Collapse Item Slots
2020-02-07 23:40:07 +08:00
|名称|参数|说明|
2020-02-03 21:20:21 +08:00
|-|-|-|
|default|`()`||
|header|`()`||
2020-02-03 21:20:21 +08:00
2020-02-03 21:07:58 +08:00
## Event
### Collapse Event
2020-02-07 23:40:07 +08:00
|名称|参数|说明|
2020-02-03 21:07:58 +08:00
|-|-|-|
|expanded-names-change|`(expandedNames: Array<string>)`||
|item-header-click|`({ name: string, expanded: boolean, event: MouseEvent })`||