el-table列固定后行列不对齐

最近在使用elmentUI 的table时发现,当使用列固定,且出现滚动条后就会出现行不对齐的情况,就算doLayout() 都没用

问题情况

在这里插入图片描述

解决方法

/deep/ .el-table__fixed-body-wrapper .el-table__body {
    
      
	padding-bottom: 17px !important; // 滚动条高度
}
/deep/ .el-table__fixed,/deep/ .el-table__fixed-right{
    
    
	// background: #fff;
	height: calc( 100% - 14px) !important;
}

具体多少px,要根据滚动条的样式

猜你喜欢

转载自blog.csdn.net/weixin_44646763/article/details/129986347