【问题标题】:element-ui's $notify encounters special character style disorderelement-ui $notify 遇到特殊字符样式紊乱
【发布时间】:2022-07-04 20:22:14
【问题描述】:

我在使用element-ui的$notify的时候,遇到特殊字符样式的时候,显示会混乱。有没有大神指点一下如何解决?

<template>
<div>
   <el-button
     plain
     @click="open2">
     does not close automatically
     </el-button>
</div>
</template>

<script>
export default {
   methods: {
     open2() {
       this.$notify({
         title: 'Tips',
         message: 'The comparison version MP16_SM6125_10.0_202101121904_user is under analysis, please check back later. ',
         duration: 0
       })
     }
   }
}
</script>

【问题讨论】:

    标签: elementary


    【解决方案1】:

    自己添加样式封面

    this.$notify({
             title: 'Tips',
             message: '<div style="word-break: break-all;">Compared version MP16_SM6125_10.0_202101121904_user is under analysis, please check back later. </div>',
             duration: 0,
             dangerouslyUseHTMLString: true
           })
    

    【讨论】:

      猜你喜欢
      • 2015-01-20
      • 2011-06-12
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2020-05-23
      相关资源
      最近更新 更多