elementUI修改messageBox弹框样式
发表于:2022-05-18 | 分类: 前端
字数统计: 71 | 阅读时长: 1分钟 | 阅读量:
elementUI messageBox 组件自定义样式方法:添加属性’customClass’
1
2
3
4
5
6
7
8
this.$confirm('确认?','告警',{
confirmButtonText: '确定',
cancelButtonText: '',
type: 'warning',
customClass: 'myBox' // 👈
}).then(function(){
// do some
})
注意 放 customClass 的 style 不能加 scoped
1
2
3
4
5
6
<style>
.myBox {
background: green;
......
}
</style>
上一篇:
mapbox关闭/取消图层的点击事件
下一篇:
记录Promise.all用法