mirror of
https://github.com/youzan/vant.git
synced 2025-10-22 11:54:02 +00:00
[Doc] update changelog
This commit is contained in:
@@ -77,7 +77,7 @@ Actionsheet will get another style if there is a `title` prop.
|
||||
### API
|
||||
|
||||
| Attribute | Description | Type | Default |
|
||||
|-----------|-----------|-----------|-------------|
|
||||
|------|------|------|------|
|
||||
| actions | Options | `Array` | `[]` |
|
||||
| title | Title | `String` | - |
|
||||
| cancel-text | Text of cancel button | `String` | - |
|
||||
@@ -89,14 +89,14 @@ Actionsheet will get another style if there is a `title` prop.
|
||||
### Event
|
||||
|
||||
| Event | Description | Arguments |
|
||||
|-----------|-----------|-----------|
|
||||
|------|------|------|
|
||||
| select | Triggered when click option | item |
|
||||
| cancel | Triggered when cancel click | - |
|
||||
|
||||
### Data struct of actions
|
||||
|
||||
| key | Description |
|
||||
|-----------|-----------|
|
||||
|------|------|
|
||||
| name | Title |
|
||||
| subname | Subtitle |
|
||||
| className | className for the option |
|
||||
|
@@ -10,6 +10,7 @@ Vue.use(Actionsheet);
|
||||
### 代码演示
|
||||
|
||||
#### 基础用法
|
||||
|
||||
需要传入一个`actions`的数组,数组的每一项是一个对象,对象属性见文档下方表格。
|
||||
|
||||
```html
|
||||
@@ -80,20 +81,20 @@ export default {
|
||||
|
||||
### API
|
||||
|
||||
| 参数 | 说明 | 类型 | 默认值 |
|
||||
|-----------|-----------|-----------|-------------|
|
||||
| actions | 菜单选项 | `Array` | `[]` |
|
||||
| title | 标题 | `String` | - |
|
||||
| cancel-text | 取消按钮文字,为空时不展示取消按钮 | `String` | - |
|
||||
| overlay | 是否显示遮罩层 | `Boolean` | `true` |
|
||||
| close-on-click-overlay | 点击遮罩是否关闭菜单 | `Boolean` | `true` |
|
||||
| lazy-render | 是否在首次显示弹层时才渲染 DOM 节点 | `Boolean` | `true` |
|
||||
| get-container | 指定挂载的节点,可以传入 CSS 选择器,<br>或一个返回 DOM 节点的函数 | `String | () => HTMLElement` | - |
|
||||
| 参数 | 说明 | 类型 | 默认值 | 版本 |
|
||||
|------|------|------|------|------|
|
||||
| actions | 菜单选项 | `Array` | `[]` | - |
|
||||
| title | 标题 | `String` | - | - |
|
||||
| cancel-text | 取消按钮文字,为空时不展示取消按钮 | `String` | - | - |
|
||||
| overlay | 是否显示遮罩层 | `Boolean` | `true` | - |
|
||||
| close-on-click-overlay | 是否在点击蒙层后关闭 | `Boolean` | `true` | - |
|
||||
| lazy-render | 是否在显示弹层时才渲染节点 | `Boolean` | `true` | 1.1.11 |
|
||||
| get-container | 指定挂载的节点,可以传入选择器,<br>或一个返回节点的函数 | `String | () => HTMLElement` | - | - |
|
||||
|
||||
### Event
|
||||
|
||||
| 事件名 | 说明 | 参数 |
|
||||
|-----------|-----------|-----------|
|
||||
|------|------|------|
|
||||
| select | 选中选项时触发,禁用或加载状态下不会触发 | item: 选项对应的对象 |
|
||||
| cancel | 取消按钮点击时触发 | - |
|
||||
|
||||
@@ -102,21 +103,9 @@ export default {
|
||||
`API`中的`actions`为一个对象数组,数组中的每一个对象配置每一列,每一列有以下`key`:
|
||||
|
||||
| key | 说明 |
|
||||
|-----------|-----------|
|
||||
|------|------|
|
||||
| name | 标题 |
|
||||
| subname | 二级标题 |
|
||||
| className | 为对应列添加额外的 class |
|
||||
| loading | 是否为加载状态 |
|
||||
| disabled | 是否为禁用状态 |
|
||||
|
||||
### 更新日志
|
||||
|
||||
| 版本 | 类型 | 内容 |
|
||||
|-----------|-----------|-----------|
|
||||
| 1.1.16 | feature | 新增 select 事件 |
|
||||
| 1.1.16 | bugfix | 修复选项加载中时仍然有点击态的问题 |
|
||||
| 1.1.11 | feature | 新增 lazy-render 属性 |
|
||||
| 1.1.9 | feature | 支持禁用选项 |
|
||||
| 1.1.8 | bugfix | 修复在 rem 布局下标题文字大小错误的问题 |
|
||||
| 1.0.4 | feature | 新增 cancel 事件 |
|
||||
| 1.0.0 | bugfix | 修复下边框未展示的问题 |
|
||||
|
Reference in New Issue
Block a user