Skip to content

Commit 7bdc9ca

Browse files
committed
fix: emptyNode should not shaked when horizontal scroll
1 parent d999347 commit 7bdc9ca

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

src/Body/ExpandedRow.tsx

+2
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,8 @@ function ExpandedRow(props: ExpandedRowProps) {
6161
className={className}
6262
style={{
6363
display: expanded ? null : 'none',
64+
// fix https://github.com/ant-design/ant-design/issues/49279
65+
visibility: isEmpty && horizonScroll && !componentWidth ? 'hidden' : null,
6466
}}
6567
>
6668
<Cell component={cellComponent} prefixCls={prefixCls} colSpan={colSpan}>

tests/__snapshots__/FixedColumn.spec.tsx.snap

+2
Original file line numberDiff line numberDiff line change
@@ -1819,6 +1819,7 @@ exports[`Table.FixedColumn > renders correctly > scrollX - without data 1`] = `
18191819
</tr>
18201820
<tr
18211821
class="rc-table-placeholder"
1822+
style=""
18221823
>
18231824
<td
18241825
class="rc-table-cell"
@@ -2975,6 +2976,7 @@ exports[`Table.FixedColumn > renders correctly > scrollXY - without data 1`] = `
29752976
</tr>
29762977
<tr
29772978
class="rc-table-placeholder"
2979+
style=""
29782980
>
29792981
<td
29802982
class="rc-table-cell"

0 commit comments

Comments
 (0)