问题:
在el-table透明化时,组件总是有白色底,无法透明化。
修改方案:
//透明化整体
.el-table,
.el-table__expanded-cell {
background-color: transparent !important;
}
//透明化行、单元格
el-table th,
.el-table tr,
.el-table td {
background-color: transparent !important;
}
//hover时样式
.el-table tbody tr:hover>td {
background-color: #367f7f78 !important
}
//偶数行样式
.el-table__row--striped td {
background-color: #45797b33 !important
}
//奇数行样式
.el-table__row:not(.el-table__row--striped) {
background: #1439391c !important;
}
效果: