mirror of
https://github.com/VisActor/VTable
synced 2024-11-22 10:03:28 +00:00
fix: fix merge cell text position #2858
This commit is contained in:
parent
103b5b79f5
commit
72422d2317
@ -0,0 +1,10 @@
|
|||||||
|
{
|
||||||
|
"changes": [
|
||||||
|
{
|
||||||
|
"packageName": "@visactor/vtable",
|
||||||
|
"comment": "fix: fix merge cell text position #2858",
|
||||||
|
"type": "none"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"packageName": "@visactor/vtable"
|
||||||
|
}
|
@ -994,7 +994,15 @@ export function resizeCellGroup(
|
|||||||
) {
|
) {
|
||||||
const { col, row } = cellGroup;
|
const { col, row } = cellGroup;
|
||||||
const dx = -table.getColsWidth(range.start.col, col - 1);
|
const dx = -table.getColsWidth(range.start.col, col - 1);
|
||||||
const dy = -table.getRowsHeight(range.start.row, row - 1);
|
let dy = 0;
|
||||||
|
if (table.options.customConfig?._disableColumnAndRowSizeRound) {
|
||||||
|
// temply fix for fs merge position; bugserverId: 673af513801d3000b3cd9e8f
|
||||||
|
for (let i = range.start.row; i <= row - 1; i++) {
|
||||||
|
dy -= table.getRowHeight(i);
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
dy = -table.getRowsHeight(range.start.row, row - 1);
|
||||||
|
}
|
||||||
|
|
||||||
cellGroup.forEachChildren((child: IGraphic) => {
|
cellGroup.forEachChildren((child: IGraphic) => {
|
||||||
// 利用_dx hack解决掉 合并单元格的范围内的格子依次执行该方法 如果挨个调用updateCell的话 执行多次后dx累计问题
|
// 利用_dx hack解决掉 合并单元格的范围内的格子依次执行该方法 如果挨个调用updateCell的话 执行多次后dx累计问题
|
||||||
|
Loading…
Reference in New Issue
Block a user