Message 消息提示
用法
基本用法
消息提示组件
常用于主动操作后的反馈提示
点击查看代码
<wd-button @click="showMessage">show Message</wd-button>
<script>
import {WdMessage} from '@inagora/wd-view'
cosnt showMessage = () => {
WdMessage({
message: '提示消息',
type: 'info'
});
}
</script>
1
2
3
4
5
6
7
8
9
10
2
3
4
5
6
7
8
9
10
属性
参数 | 说明 | 类型 | 可选值 | 默认值 |
---|---|---|---|---|
duration | 消息提示显示时长 | number | - | 3 |
message | 提示内容 | string | - | '' |
offset | 提示框距离顶部的位置 | number | - | - |
type | 消息类型 | string | info\success\warning\error | info |
事件
事件名称 | 说明 | 回调参数 |
---|---|---|
destroy | Message组件销毁 | Function() |