美文网首页
解决使用vant/Dialog出现模糊的问题

解决使用vant/Dialog出现模糊的问题

作者: 饼饼phoebe | 来源:发表于2021-04-02 05:13 被阅读0次

是由于transform: translate(-50%, -50%, 0); 造成的。
只需要改变dialog垂直居中的方式

.van-dialog {
  width:315px;
  height: 150px;
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  margin: auto;
  transform: translate3d(0,0,0)
}

此时如果样式不生效,可以添加一个新的<style>标签 去掉scoped

相关文章

网友评论

      本文标题:解决使用vant/Dialog出现模糊的问题

      本文链接:https://www.haomeiwen.com/subject/qncfkltx.html