蒙层

 

利用z-index:

.mui-backdrop-other {
    position: fixed;
    top: 44px;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 2;
    background-color: rgba(0, 0, 0, .3);
}

 

.element {
    position: relative;
}

.element:after {
    content: "哈哈哈,我是遮罩";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    box-sizing: border-box;
    padding: 100px;
    background-color: rgba(0, 0, 0, .6);
    color: #fff;
    text-align: center;
}

 

相关文章:

  • 2021-08-16
  • 2021-10-31
  • 2022-12-23
  • 2021-12-22
  • 2021-12-23
  • 2021-10-30
  • 2021-04-09
  • 2021-12-31
猜你喜欢
  • 2022-01-28
  • 2021-06-01
  • 2021-08-04
  • 2022-12-23
  • 2021-12-30
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案