Ant Design Vue Drawer组件 样式覆盖的问题


覆盖Ant Design Vue Drawer组件的默认样式

 1,在组件的html中设置wrapClassName="drawer-style"

<a-drawer
      :mask-style="{'background':'rgba(51, 51, 51, 0)'}"
      width="512px"
      placement="right"
      :closable="false"
      :visible="showRightBox"
      :get-container="false"
      :wrap-style="{ position: 'absolute' }"
      :destroyOnClose="true"
      wrapClassName="drawer-style"
      @close="
        showRightBox = false;
        chooseType = '';
        chooseComId = '';
        setComps = '';
      "
    >
...

</a-drawer>

2,输入less覆盖样式(:global是关键)

:global(.drawer-style .ant-drawer-content) {
  background-color: rgba(255, 255, 255, 0);
}


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM