问题描述
Ant Design Vue 中table 表格 取消划过效果,正常使用类找到效果并修改后 会出现闪白的情况。
.ant-table-cell-row-hover:hover:not(.ant-table-expanded-row) > td{background-color: green !important;
}
原因分析:
代码运行自上而下并因为权重原因出现此问题
解决方案:
::v-deep :where(.css-dev-only-do-not-override-udyjmm).ant-table-wrapper .ant-table-tbody >tr.ant-table-row:hover>td, ::v-deep :where(.css-dev-only-do-not-override-udyjmm).ant-table-wrapper .ant-table-tbody >tr >td.ant-table-cell-row-hover {background-color: transparent;}
}