1.el-table悬停高亮打开后,css穿透修改悬停颜色
::v-deep tr {
background-color: transparent;
color: #111111;
th.el-table__cell {
background-color: transparent;
color: #fff;
&.is-leaf {
border: none;
}
}
td.el-table__cell {
border: none;
}
&:hover > td {
// 悬停颜色 上面的不用管
background-color: #e1f6f6 !important;
}
}
2.如果加了斑马纹
::v-deep .el-table__body .el-table__row--striped.hover-row td{
background-color: #e1f6f6!important;
}
3.点击高亮选中态同理
// 选中高亮
::v-deep .el-table__body tr.current-row > td.el-table__cell {
background-color: rgb(115, 177, 201);
}
// 加了斑马纹后选中高亮
::v-deep .el-table__body .el-table__row--striped.current-row td.el-table__cell{
background-color: rgb(115, 177, 201)!important;
}