mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-06 03:57:59 +08:00
feat(Toast): change default duration to 2s (#4886)
This commit is contained in:
parent
f856bcae74
commit
02e84d1e15
@ -147,7 +147,7 @@ Toast.resetDefaultOptions('loading');
|
||||
| forbidClick | Whether to forbid click background | *boolean* | `false` | - |
|
||||
| closeOnClick | Whether to close after clicked | *boolean* | `false` | 2.1.5 |
|
||||
| loadingType | Loading icon type, can be set to `spinner` | *string* | `circular` | - |
|
||||
| duration | Toast duration(ms), won't disappear if value is 0 | *number* | `3000` | - |
|
||||
| duration | Toast duration(ms), won't disappear if value is 0 | *number* | `2000` | - |
|
||||
| className | Custom className | *any* | - | - |
|
||||
| onOpened | Callback function after opened | *Function* | - | - |
|
||||
| onClose | Callback function after close | *Function* | - | - |
|
||||
|
@ -150,7 +150,7 @@ Toast.resetDefaultOptions('loading');
|
||||
| forbidClick | 是否禁止背景点击 | *boolean* | `false` | - |
|
||||
| closeOnClick | 是否在点击后关闭 | *boolean* | `false` | 2.1.5 |
|
||||
| loadingType | 加载图标类型, 可选值为 `spinner` | *string* | `circular` | - |
|
||||
| duration | 展示时长(ms),值为 0 时,toast 不会消失 | *number* | `3000` | - |
|
||||
| duration | 展示时长(ms),值为 0 时,toast 不会消失 | *number* | `2000` | - |
|
||||
| className | 自定义类名 | *any* | - | - |
|
||||
| onOpened | 完全展示后的回调函数 | *Function* | - | - |
|
||||
| onClose | 关闭时的回调函数 | *Function* | - | - |
|
||||
|
@ -11,7 +11,7 @@ const defaultOptions = {
|
||||
className: '',
|
||||
onClose: null,
|
||||
onOpened: null,
|
||||
duration: 3000,
|
||||
duration: 2000,
|
||||
iconPrefix: undefined,
|
||||
position: 'middle',
|
||||
transition: 'van-fade',
|
||||
|
Loading…
x
Reference in New Issue
Block a user