Skip to content

Commit e140373

Browse files
committed
fix(Table): wrong row height in ExpandTable with Lock, close #2943
1 parent 35c62b5 commit e140373

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/table/lock.jsx

+3-1
Original file line numberDiff line numberDiff line change
@@ -513,7 +513,9 @@ export default function lock(BaseComponent) {
513513
if (this.isLock()) {
514514
this.tableInc.props.dataSource.forEach((item, index) => {
515515
// record may be a string
516-
const rowIndex = typeof item === 'object' && '__rowIndex' in item ? item.__rowIndex : index;
516+
const rowIndex = `${typeof item === 'object' && '__rowIndex' in item ? item.__rowIndex : index}${
517+
item.__expanded ? '_expanded' : ''
518+
}`;
517519

518520
// 同步左侧的锁列
519521
this.setRowHeight(rowIndex, 'left');

0 commit comments

Comments
 (0)