mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-06 03:57:59 +08:00
[improvement] SwipeCell: add click event (#1848)
This commit is contained in:
parent
40d965db67
commit
86c1d255f8
@ -72,6 +72,12 @@ export default {
|
||||
| left | content of left scrollable area |
|
||||
| right | content of right scrollabe area |
|
||||
|
||||
### Event
|
||||
|
||||
| Event | Description | Arguments |
|
||||
|-----------|-----------|-----------|
|
||||
| click | Triggered when clicked | Click positon (`left` `right` `cell` `outside`) |
|
||||
|
||||
### onClose Params
|
||||
|
||||
| Argument | Type | Description |
|
||||
|
@ -137,6 +137,8 @@ export default create({
|
||||
},
|
||||
|
||||
onClick(position = 'outside') {
|
||||
this.$emit('click', position);
|
||||
|
||||
if (!this.offset) {
|
||||
return;
|
||||
}
|
||||
|
@ -72,6 +72,12 @@ export default {
|
||||
| left | 左侧滑动内容 |
|
||||
| right | 右侧滑动内容 |
|
||||
|
||||
### Event
|
||||
|
||||
| 事件名 | 说明 | 参数 |
|
||||
|-----------|-----------|-----------|
|
||||
| click | 点击时触发 | 关闭时的点击位置 (`left` `right` `cell` `outside`) |
|
||||
|
||||
### onClose 参数
|
||||
|
||||
| 参数 | 类型 | 说明 |
|
||||
|
Loading…
x
Reference in New Issue
Block a user