mirror of
https://gitee.com/baidu/amis.git
synced 2024-11-29 18:48:45 +08:00
fix: 修复CRUD固定表头不生效问题 (#8332)
* fix: 修复固定表头不生效 * 修复低版本浏览器固定表头不生效问题 --------- Co-authored-by: huangxj29 <huangxuejuan@xgd.com>
This commit is contained in:
parent
419bb28210
commit
6119616055
@ -1146,12 +1146,12 @@ export const TableStore = iRendererStore
|
||||
return;
|
||||
}
|
||||
const cols = [].slice.call(
|
||||
table.querySelectorAll(':scope>colgroup>col[data-index]')!
|
||||
table.querySelectorAll(':scope>thead>tr>th[data-index]')
|
||||
);
|
||||
cols.forEach((col: HTMLElement) => {
|
||||
const index = parseInt(col.getAttribute('data-index')!, 10);
|
||||
const column = self.columns[index];
|
||||
column.setRealWidth(col.clientWidth);
|
||||
column.setRealWidth(col.offsetWidth);
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -46,6 +46,10 @@
|
||||
position: absolute;
|
||||
}
|
||||
}
|
||||
|
||||
.#{$ns}Table-table {
|
||||
table-layout: fixed;
|
||||
}
|
||||
}
|
||||
|
||||
&-heading {
|
||||
|
Loading…
Reference in New Issue
Block a user