mirror of
https://gitee.com/element-plus/element-plus.git
synced 2024-12-03 11:47:48 +08:00
fix(components): [table] fit set to false bottom border error (#17023)
This commit is contained in:
parent
39ac0b5a0d
commit
afab17c51a
@ -24,12 +24,12 @@
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
height: 100%;
|
||||
|
||||
// 表格底部伪 border,总是有的
|
||||
&::before {
|
||||
@include extend-rule(border-pseudo);
|
||||
left: 0;
|
||||
bottom: 0px;
|
||||
width: 100%;
|
||||
bottom: 0;
|
||||
height: 1px;
|
||||
}
|
||||
}
|
||||
@ -125,6 +125,12 @@
|
||||
.#{$namespace}-table__cell.gutter {
|
||||
border-right-width: 1px;
|
||||
}
|
||||
|
||||
@include e(inner-wrapper) {
|
||||
&::before {
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
thead {
|
||||
@ -150,6 +156,7 @@
|
||||
position: relative;
|
||||
text-align: left;
|
||||
z-index: getCssVar('table-index');
|
||||
|
||||
@include when(center) {
|
||||
text-align: center;
|
||||
}
|
||||
@ -190,9 +197,11 @@
|
||||
@each $size in (large, default, small) {
|
||||
@include m($size) {
|
||||
font-size: map.get($table-font-size, $size);
|
||||
|
||||
.#{$namespace}-table__cell {
|
||||
padding: map.get($table-padding, $size);
|
||||
}
|
||||
|
||||
.cell {
|
||||
padding: map.get($table-cell-padding, $size);
|
||||
}
|
||||
@ -314,6 +323,7 @@
|
||||
|
||||
@include e((header-wrapper, body-wrapper, footer-wrapper)) {
|
||||
width: 100%;
|
||||
|
||||
tr {
|
||||
td,
|
||||
th {
|
||||
@ -322,6 +332,7 @@
|
||||
position: sticky !important;
|
||||
background: inherit;
|
||||
z-index: calc(getCssVar('table-index') + 1);
|
||||
|
||||
&.is-last-column,
|
||||
&.is-first-column {
|
||||
&::before {
|
||||
@ -337,11 +348,13 @@
|
||||
pointer-events: none;
|
||||
}
|
||||
}
|
||||
|
||||
&.is-first-column {
|
||||
&::before {
|
||||
left: -10px;
|
||||
}
|
||||
}
|
||||
|
||||
&.is-last-column {
|
||||
&::before {
|
||||
right: -10px;
|
||||
@ -349,6 +362,7 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&.#{$namespace}-table__fixed-right-patch {
|
||||
position: sticky !important;
|
||||
z-index: calc(getCssVar('table-index') + 1);
|
||||
@ -361,6 +375,7 @@
|
||||
|
||||
@include e(header-wrapper) {
|
||||
flex-shrink: 0;
|
||||
|
||||
tr {
|
||||
th {
|
||||
&.#{$namespace}-table-fixed-column--left,
|
||||
@ -402,6 +417,7 @@
|
||||
align-items: center;
|
||||
height: 23px;
|
||||
}
|
||||
|
||||
.#{$namespace}-checkbox {
|
||||
height: unset;
|
||||
}
|
||||
@ -414,6 +430,7 @@
|
||||
box-shadow: getCssVar('table-fixed-right-column');
|
||||
}
|
||||
}
|
||||
|
||||
&.#{$namespace}-table--border {
|
||||
.#{$namespace}-table-fixed-column--left {
|
||||
&.is-last-column {
|
||||
@ -423,6 +440,7 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
th.#{$namespace}-table-fixed-column--left {
|
||||
background-color: getCssVar('table-header-bg-color');
|
||||
}
|
||||
@ -434,9 +452,11 @@
|
||||
box-shadow: getCssVar('table-fixed-left-column');
|
||||
}
|
||||
}
|
||||
|
||||
.#{$namespace}-table-fixed-column--left.is-last-column.#{$namespace}-table__cell {
|
||||
border-right: none;
|
||||
}
|
||||
|
||||
th.#{$namespace}-table-fixed-column--right {
|
||||
background-color: getCssVar('table-header-bg-color');
|
||||
}
|
||||
@ -446,11 +466,13 @@
|
||||
.#{$namespace}-table-fixed-column--left.is-last-column.#{$namespace}-table__cell {
|
||||
border-right: none;
|
||||
}
|
||||
|
||||
.#{$namespace}-table-fixed-column--right.is-first-column {
|
||||
&::before {
|
||||
box-shadow: getCssVar('table-fixed-right-column');
|
||||
}
|
||||
}
|
||||
|
||||
.#{$namespace}-table-fixed-column--left.is-last-column {
|
||||
&::before {
|
||||
box-shadow: getCssVar('table-fixed-left-column');
|
||||
@ -479,6 +501,7 @@
|
||||
overflow: hidden;
|
||||
position: relative;
|
||||
flex: 1;
|
||||
|
||||
.#{$namespace}-scrollbar__bar {
|
||||
z-index: calc(getCssVar('table-index') + 2);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user