@visactor/vtable 0.17.2 → 0.17.3-alpha.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/cjs/ListTable.d.ts +1 -0
- package/cjs/ListTable.js +3 -0
- package/cjs/ListTable.js.map +1 -1
- package/cjs/core/BaseTable.d.ts +8 -0
- package/cjs/core/BaseTable.js +13 -1
- package/cjs/core/BaseTable.js.map +1 -1
- package/cjs/index.d.ts +1 -1
- package/cjs/index.js +1 -1
- package/cjs/index.js.map +1 -1
- package/cjs/scenegraph/group-creater/progress/update-position/dynamic-set-x.js +2 -2
- package/cjs/scenegraph/group-creater/progress/update-position/dynamic-set-x.js.map +1 -1
- package/cjs/scenegraph/group-creater/progress/update-position/dynamic-set-y.js +2 -1
- package/cjs/scenegraph/group-creater/progress/update-position/dynamic-set-y.js.map +1 -1
- package/cjs/ts-types/base-table.d.ts +2 -0
- package/cjs/ts-types/base-table.js.map +1 -1
- package/dist/vtable.js +23 -5
- package/dist/vtable.min.js +1 -1
- package/es/ListTable.d.ts +1 -0
- package/es/ListTable.js +3 -0
- package/es/ListTable.js.map +1 -1
- package/es/core/BaseTable.d.ts +8 -0
- package/es/core/BaseTable.js +13 -1
- package/es/core/BaseTable.js.map +1 -1
- package/es/index.d.ts +1 -1
- package/es/index.js +1 -1
- package/es/index.js.map +1 -1
- package/es/scenegraph/group-creater/progress/update-position/dynamic-set-x.js +2 -2
- package/es/scenegraph/group-creater/progress/update-position/dynamic-set-x.js.map +1 -1
- package/es/scenegraph/group-creater/progress/update-position/dynamic-set-y.js +2 -1
- package/es/scenegraph/group-creater/progress/update-position/dynamic-set-y.js.map +1 -1
- package/es/ts-types/base-table.d.ts +2 -0
- package/es/ts-types/base-table.js.map +1 -1
- package/package.json +5 -5
package/cjs/index.d.ts
CHANGED
|
@@ -12,7 +12,7 @@ import type { MousePointerCellEvent } from './ts-types/events';
|
|
|
12
12
|
import * as CustomLayout from './render/layout';
|
|
13
13
|
export { getDataCellPath } from './tools/get-data-path';
|
|
14
14
|
export * from './render/jsx';
|
|
15
|
-
export declare const version = "0.17.
|
|
15
|
+
export declare const version = "0.17.3-alpha.0";
|
|
16
16
|
export { TYPES, core, ListTable, ListTableConstructorOptions, PivotTable, PivotTableConstructorOptions, PivotChartConstructorOptions, PivotChart, IHeaderTreeDefine, IDimension, IIndicator, ITitleDefine, ICornerDefine, ColumnsDefine, ColumnDefine, LinkColumnDefine, ChartColumnDefine, ImageColumnDefine, SparklineColumnDefine, ProgressbarColumnDefine, TextColumnDefine, GroupColumnDefine, TextAlignType, TextBaselineType, themes, data, MousePointerCellEvent, getIcons, clearGlobal, register, DataStatistics, CustomLayout };
|
|
17
17
|
declare function getIcons(): {
|
|
18
18
|
[key: string]: TYPES.ColumnIconOption;
|
package/cjs/index.js
CHANGED
|
@@ -101,6 +101,6 @@ Object.defineProperty(exports, "getDataCellPath", {
|
|
|
101
101
|
get: function() {
|
|
102
102
|
return get_data_path_1.getDataCellPath;
|
|
103
103
|
}
|
|
104
|
-
}), __exportStar(require("./render/jsx"), exports), exports.version = "0.17.
|
|
104
|
+
}), __exportStar(require("./render/jsx"), exports), exports.version = "0.17.3-alpha.0",
|
|
105
105
|
exports.getIcons = getIcons, exports.clearGlobal = clearGlobal, TYPES.AggregationType;
|
|
106
106
|
//# sourceMappingURL=index.js.map
|
package/cjs/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACA,kDAAoC;AAiDlC,sBAAK;AAhDP,6CAA+B;AAiD7B,oBAAI;AAhDN,6CAA+B;AAwE7B,oBAAI;AAvEN,+CAAiC;AACjC,qDAAuC;AA2ErC,4BAAQ;AA1EV,iDAAmC;AAoEjC,wBAAM;AAnER,yEAA2D;AA6EzD,wCAAc;AAvDhB,2CAAwC;AAuBtC,0FAvBO,qBAAS,OAuBP;AAtBX,6CAA0C;AAwBxC,2FAxBO,uBAAU,OAwBP;AAvBZ,6CAA0C;AA0BxC,2FA1BO,uBAAU,OA0BP;AAxBZ,8DAAgD;AAoD9C,oCAAY;AA/Cd,uDAAwD;AAA/C,gHAAA,eAAe,OAAA;AACxB,+CAA6B;AAEhB,QAAA,OAAO,GAAG,
|
|
1
|
+
{"version":3,"sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACA,kDAAoC;AAiDlC,sBAAK;AAhDP,6CAA+B;AAiD7B,oBAAI;AAhDN,6CAA+B;AAwE7B,oBAAI;AAvEN,+CAAiC;AACjC,qDAAuC;AA2ErC,4BAAQ;AA1EV,iDAAmC;AAoEjC,wBAAM;AAnER,yEAA2D;AA6EzD,wCAAc;AAvDhB,2CAAwC;AAuBtC,0FAvBO,qBAAS,OAuBP;AAtBX,6CAA0C;AAwBxC,2FAxBO,uBAAU,OAwBP;AAvBZ,6CAA0C;AA0BxC,2FA1BO,uBAAU,OA0BP;AAxBZ,8DAAgD;AAoD9C,oCAAY;AA/Cd,uDAAwD;AAA/C,gHAAA,eAAe,OAAA;AACxB,+CAA6B;AAEhB,QAAA,OAAO,GAAG,gBAAgB,CAAC;AAgDxC,SAAS,QAAQ;IAGf,OAAO,KAAK,CAAC,GAAG,EAAE,CAAC;AACrB,CAAC;AAhBC,4BAAQ;AAkBV,SAAS,WAAW;IAClB,QAAQ,CAAC,QAAQ,EAAE,CAAC;AAGtB,CAAC;AArBC,kCAAW;AAsBb,KAAK,CAAC,eAAe,CAAC","file":"index.js","sourcesContent":["/* eslint-disable sort-imports */\nimport * as TYPES from './ts-types';\nimport * as core from './core';\nimport * as data from './data';\nimport * as icons from './icons';\nimport * as register from './register';\nimport * as themes from './themes';\nimport * as DataStatistics from './dataset/DataStatistics';\nimport type {\n ColumnDefine,\n ColumnsDefine,\n LinkColumnDefine,\n ChartColumnDefine,\n ImageColumnDefine,\n SparklineColumnDefine,\n ProgressbarColumnDefine,\n TextColumnDefine,\n GroupColumnDefine,\n ListTableConstructorOptions,\n PivotTableConstructorOptions,\n PivotChartConstructorOptions,\n IHeaderTreeDefine,\n IDimension,\n IIndicator,\n ITitleDefine,\n ICornerDefine,\n TextAlignType,\n TextBaselineType\n} from './ts-types';\nimport { ListTable } from './ListTable';\nimport { PivotTable } from './PivotTable';\nimport { PivotChart } from './PivotChart';\nimport type { MousePointerCellEvent } from './ts-types/events';\nimport * as CustomLayout from './render/layout';\n\n// import { container, loadCanvasPicker } from '@visactor/vrender';\n// loadCanvasPicker(container);\n\nexport { getDataCellPath } from './tools/get-data-path';\nexport * from './render/jsx';\n\nexport const version = \"0.17.3-alpha.0\";\n/**\n * @namespace VTable\n */\nexport {\n /**\n * Types\n * @namespace VTable.TYPES\n */\n TYPES,\n core,\n ListTable,\n ListTableConstructorOptions,\n PivotTable,\n PivotTableConstructorOptions,\n PivotChartConstructorOptions,\n PivotChart,\n IHeaderTreeDefine,\n IDimension,\n IIndicator,\n ITitleDefine,\n ICornerDefine,\n ColumnsDefine,\n ColumnDefine,\n LinkColumnDefine,\n ChartColumnDefine,\n ImageColumnDefine,\n SparklineColumnDefine,\n ProgressbarColumnDefine,\n TextColumnDefine,\n GroupColumnDefine,\n TextAlignType,\n TextBaselineType,\n themes,\n data,\n MousePointerCellEvent,\n getIcons,\n clearGlobal,\n //plugin registers\n register,\n /**\n * 暂不推荐使用\n */\n DataStatistics,\n CustomLayout\n};\n\n/** @private */\nfunction getIcons(): {\n [key: string]: TYPES.ColumnIconOption;\n} {\n return icons.get();\n}\n/** 清理内部的全局变量 如注册的icon theme等 以及共享的header column类实例 */\nfunction clearGlobal() {\n register.clearAll();\n // headers.type.clearGlobal();\n // columns.type.clearGlobal();\n}\nTYPES.AggregationType;\n"]}
|
|
@@ -52,8 +52,8 @@ function move(deltaCol, screenLeftCol, screenLeftX, x, proxy) {
|
|
|
52
52
|
function moveColumn(count, direction, screenLeftCol, screenLeftX, x, proxy) {
|
|
53
53
|
return __awaiter(this, void 0, void 0, (function*() {
|
|
54
54
|
if ("left" === direction && proxy.colEnd + count > proxy.bodyRightCol ? count = proxy.bodyRightCol - proxy.colEnd : "right" === direction && proxy.colStart - count < proxy.bodyLeftCol && (count = proxy.colStart - proxy.bodyLeftCol),
|
|
55
|
-
count < 0 && (direction = "left" === direction ? "right" : "left",
|
|
56
|
-
|
|
55
|
+
0 !== count) if (count < 0 && (direction = "left" === direction ? "right" : "left",
|
|
56
|
+
count = -count), count < proxy.colEnd - proxy.colStart) {
|
|
57
57
|
const startCol = "left" === direction ? proxy.colStart : proxy.colEnd - count + 1, endCol = "left" === direction ? proxy.colStart + count - 1 : proxy.colEnd, distStartCol = "left" === direction ? proxy.colEnd + 1 : proxy.colStart - count, distEndCol = "left" === direction ? proxy.colEnd + count : proxy.colStart - 1;
|
|
58
58
|
(0, compute_col_width_1.computeColsWidth)(proxy.table, distStartCol, distEndCol),
|
|
59
59
|
updatePartColPosition(startCol, endCol, direction, proxy);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/scenegraph/group-creater/progress/update-position/dynamic-set-x.ts"],"names":[],"mappings":";;;;;;;;;;;;AAEA,yEAAqE;AAErE,6DAAwD;AACxD,iCAAyE;AAEzE,SAAsB,WAAW,CAAC,CAAS,EAAE,KAAiB;;QAC5D,MAAM,UAAU,GAAI,KAAK,CAAC,KAAsB,CAAC,cAAc,CAC7D,CAAC,GAAG,KAAK,CAAC,KAAK,CAAC,UAAU,CAAC,cAAc,CAAC,SAAS,CAAC,KAAK,CAC1D,CAAC;QACF,IAAI,CAAC,UAAU,EAAE;YACf,OAAO;SACR;QACD,MAAM,aAAa,GAAG,UAAU,CAAC,GAAG,CAAC;QACrC,MAAM,WAAW,GAAG,UAAU,CAAC,IAAI,CAAC;QACpC,KAAK,CAAC,aAAa,GAAG,aAAa,CAAC;QACpC,MAAM,QAAQ,GAAG,KAAK,CAAC,aAAa,GAAG,KAAK,CAAC,YAAY,CAAC;QAE1D,IAAI,C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,GAAG,KAAK,CAAC,KAAK,CAAC,WAAW,CAAE,QAAQ,CAAC,KAAe,CAAC,GAAG,CAAC,CACnG,CAAC;SACH;IACH,CAAC,CAAC,CAAC;AACL,CAAC","file":"dynamic-set-x.js","sourcesContent":["import type { BaseTableAPI } from '../../../../ts-types/base-table';\nimport type { Group } from '../../../graphic/group';\nimport { computeColsWidth } from '../../../layout/compute-col-width';\nimport type { SceneProxy } from '../proxy';\nimport { updateAutoColumn } from './update-auto-column';\nimport { checkFirstColMerge, getFirstChild, getLastChild } from './util';\n\nexport async function dynamicSetX(x: number, proxy: SceneProxy) {\n const screenLeft = (proxy.table as BaseTableAPI).getTargetColAt(\n x + proxy.table.scenegraph.rowHeaderGroup.attribute.width\n );\n if (!screenLeft) {\n return;\n }\n const screenLeftCol = screenLeft.col;\n const screenLeftX = screenLeft.left;\n proxy.screenLeftCol = screenLeftCol;\n const deltaCol = proxy.screenLeftCol - proxy.referenceCol;\n\n move(deltaCol, screenLeftCol, screenLeftX, x, proxy);\n proxy.table.scenegraph.updateNextFrame();\n}\n\nfunction move(deltaCol: number, screenLeftCol: number, screenLeftX: number, x: number, proxy: SceneProxy) {\n if (deltaCol > 0) {\n // 向右滚动,左部column group移到右部\n moveColumn(deltaCol, 'left', proxy.screenLeftCol, screenLeftX, x, proxy);\n proxy.table.scenegraph.setBodyAndColHeaderX(-x + proxy.deltaX);\n } else if (deltaCol < 0) {\n // 向左滚动,右部cell group移到左部\n moveColumn(-deltaCol, 'right', proxy.screenLeftCol, screenLeftX, x, proxy);\n proxy.table.scenegraph.setBodyAndColHeaderX(-x + proxy.deltaX);\n } else {\n // 不改变row,更新body group范围\n proxy.table.scenegraph.setBodyAndColHeaderX(-x + proxy.deltaX);\n }\n}\n\nasync function moveColumn(\n count: number,\n direction: 'left' | 'right',\n screenLeftCol: number,\n screenLeftX: number,\n x: number,\n proxy: SceneProxy\n) {\n // 限制count范围\n if (direction === 'left' && proxy.colEnd + count > proxy.bodyRightCol) {\n count = proxy.bodyRightCol - proxy.colEnd;\n } else if (direction === 'right' && proxy.colStart - count < proxy.bodyLeftCol) {\n count = proxy.colStart - proxy.bodyLeftCol;\n }\n if (count < 0) {\n direction = direction === 'left' ? 'right' : 'left';\n count = -count;\n }\n\n if (count <= 0) {\n return;\n }\n\n // 两种更新模式\n // 1. count < colEnd - colStart:从顶/底部移动count数量的单元格到底/顶部\n // 2. count >= colEnd - colStart:整体移动到目标位置\n if (count < proxy.colEnd - proxy.colStart) {\n // 计算更新区域\n const startCol = direction === 'left' ? proxy.colStart : proxy.colEnd - count + 1;\n const endCol = direction === 'left' ? proxy.colStart + count - 1 : proxy.colEnd;\n const distStartCol = direction === 'left' ? proxy.colEnd + 1 : proxy.colStart - count;\n const distEndCol = direction === 'left' ? proxy.colEnd + count : proxy.colStart - 1;\n // update column width\n computeColsWidth(proxy.table, distStartCol, distEndCol);\n updatePartColPosition(startCol, endCol, direction, proxy);\n\n const syncLeftCol = distStartCol;\n const syncRightCol = distEndCol;\n\n proxy.colStart = direction === 'left' ? proxy.colStart + count : proxy.colStart - count;\n proxy.colEnd = direction === 'left' ? proxy.colEnd + count : proxy.colEnd - count;\n\n updateColContent(syncLeftCol, syncRightCol, proxy);\n\n updateAutoColumn(\n syncLeftCol, // colStart\n syncRightCol, // colEnd\n proxy.table,\n direction\n );\n\n const colGroup =\n proxy.table.scenegraph.getColGroup(screenLeftCol) || proxy.table.scenegraph.getColGroup(screenLeftCol, true);\n const deltaX =\n screenLeftX - (colGroup.attribute.x + proxy.table.getFrozenColsWidth() + proxy.table.scenegraph.proxy.deltaX);\n proxy.table.scenegraph.proxy.deltaX += deltaX;\n\n proxy.currentCol = direction === 'left' ? proxy.currentCol + count : proxy.currentCol - count;\n proxy.totalCol = direction === 'left' ? proxy.totalCol + count : proxy.totalCol - count;\n proxy.referenceCol = proxy.colStart + Math.floor((proxy.colEnd - proxy.colStart) / 2);\n proxy.colUpdatePos = distStartCol;\n proxy.colUpdateDirection = direction;\n\n proxy.table.scenegraph.updateNextFrame();\n\n // 开始异步任务\n // await proxy.progress();\n } else {\n const distStartCol = direction === 'left' ? proxy.colStart + count : proxy.colStart - count;\n const distEndCol = direction === 'left' ? proxy.colEnd + count : proxy.colEnd - count;\n\n // update column width\n computeColsWidth(proxy.table, distStartCol, distEndCol);\n const distStartColY = proxy.table.getColsWidth(proxy.bodyLeftCol, distStartCol - 1);\n\n // 更新同步范围\n updateAllColPosition(distStartColY, count, direction, proxy);\n const syncLeftCol = distStartCol;\n const syncRightCol = distEndCol;\n\n proxy.colStart = distStartCol;\n proxy.colEnd = distEndCol;\n updateColContent(syncLeftCol, syncRightCol, proxy);\n\n updateAutoColumn(\n syncLeftCol, // colStart\n syncRightCol, // colEnd\n proxy.table,\n distEndCol > proxy.bodyRightCol - (proxy.colEnd - proxy.colStart + 1) ? 'right' : 'left' // 跳转到右侧时,从右向左对齐\n );\n // update body position when click scroll bar\n if (syncLeftCol === proxy.bodyLeftCol) {\n const colGroup = proxy.table.scenegraph.getColGroup(syncLeftCol);\n const deltaX = colGroup.attribute.x - x;\n proxy.table.scenegraph.proxy.deltaX = deltaX;\n } else if (syncRightCol === proxy.bodyRightCol) {\n const colGroup = proxy.table.scenegraph.getColGroup(syncRightCol);\n const deltaX =\n colGroup.attribute.x +\n colGroup.attribute.width -\n (proxy.table.tableNoFrameWidth - proxy.table.getFrozenColsWidth()) -\n x;\n proxy.table.scenegraph.proxy.deltaX = -deltaX;\n } else {\n // proxy.table.scenegraph.proxy.deltaX = 0;\n const colGroup =\n proxy.table.scenegraph.getColGroup(screenLeftCol) || proxy.table.scenegraph.getColGroup(screenLeftCol, true);\n const deltaX =\n screenLeftX - (colGroup.attribute.x + proxy.table.getFrozenColsWidth() + proxy.table.scenegraph.proxy.deltaX);\n proxy.table.scenegraph.proxy.deltaX = deltaX;\n }\n\n proxy.currentCol = direction === 'left' ? proxy.currentCol + count : proxy.currentCol - count;\n proxy.totalCol = direction === 'left' ? proxy.totalCol + count : proxy.totalCol - count;\n proxy.referenceCol = proxy.colStart + Math.floor((proxy.colEnd - proxy.colStart) / 2);\n proxy.colUpdatePos = proxy.colStart;\n proxy.colUpdateDirection = distEndCol > proxy.bodyRightCol - (proxy.colEnd - proxy.colStart + 1) ? 'right' : 'left';\n\n proxy.table.scenegraph.updateNextFrame();\n // await proxy.progress();\n }\n}\n\nfunction updateColGroupPosition(colGroup: Group, newCol: number, x: number) {\n // 更新位置&col\n colGroup.col = newCol;\n colGroup.forEachChildren((cellGroup: Group) => {\n cellGroup.col = newCol;\n cellGroup.needUpdate = true;\n });\n colGroup.setAttribute('x', x);\n colGroup.needUpdate = true;\n}\n\nfunction updateColGroupContent(colGroup: Group, proxy: SceneProxy) {\n if (!colGroup) {\n return;\n }\n // colGroup.forEachChildren((cellGroup: Group) => {\n // proxy.updateCellGroupContent(cellGroup);\n // });\n // for (let row = (colGroup.firstChild as Group).row; row <= (colGroup.lastChild as Group).row; row++) {\n // const cellGroup = proxy.highPerformanceGetCell(colGroup.col, row);\n // proxy.updateCellGroupContent(cellGroup);\n // }\n let cellGroup = colGroup.firstChild;\n while (cellGroup) {\n const newCellGroup = proxy.updateCellGroupContent(cellGroup as Group);\n cellGroup = newCellGroup._next;\n }\n colGroup.needUpdate = false;\n colGroup.setAttribute('width', proxy.table.getColWidth(colGroup.col));\n}\n\nfunction updatePartColPosition(startCol: number, endCol: number, direction: 'left' | 'right', proxy: SceneProxy) {\n for (let col = startCol; col <= endCol; col++) {\n if (\n proxy.table.scenegraph.bodyGroup.childrenCount > 0 &&\n proxy.table.scenegraph.bodyGroup.firstChild.type === 'group'\n ) {\n updateColPosition(proxy.table.scenegraph.bodyGroup, direction, proxy);\n }\n if (\n proxy.table.scenegraph.colHeaderGroup.childrenCount > 0 &&\n proxy.table.scenegraph.colHeaderGroup.firstChild.type === 'group'\n ) {\n updateColPosition(proxy.table.scenegraph.colHeaderGroup, direction, proxy);\n }\n if (\n proxy.table.scenegraph.bottomFrozenGroup.childrenCount > 0 &&\n proxy.table.scenegraph.bottomFrozenGroup.firstChild.type === 'group'\n ) {\n updateColPosition(proxy.table.scenegraph.bottomFrozenGroup, direction, proxy);\n }\n }\n}\n\nfunction updateColPosition(containerGroup: Group, direction: 'left' | 'right', proxy: SceneProxy) {\n if (direction === 'left') {\n const colGroup = getFirstChild(containerGroup);\n const lastChild = getLastChild(containerGroup);\n updateColGroupPosition(colGroup, lastChild.col + 1, lastChild.attribute.x + proxy.table.getColWidth(lastChild.col));\n containerGroup.appendChild(colGroup);\n // console.log('after', colGroup.col, colGroup.attribute.x, containerGroup._uid);\n if (containerGroup.border) {\n containerGroup.appendChild(containerGroup.border);\n }\n } else {\n const colGroup = getLastChild(containerGroup);\n const firstChild = getFirstChild(containerGroup);\n updateColGroupPosition(\n colGroup,\n firstChild.col - 1,\n firstChild.attribute.x - proxy.table.getColWidth(firstChild.col - 1)\n );\n containerGroup.insertBefore(colGroup, containerGroup.firstChild);\n }\n}\n\nexport function updateColContent(syncLeftCol: number, syncRightCol: number, proxy: SceneProxy) {\n for (let col = syncLeftCol; col <= syncRightCol; col++) {\n const colGroup = proxy.table.scenegraph.getColGroup(col);\n colGroup && updateColGroupContent(colGroup, proxy);\n\n const colHeaderColGroup = proxy.table.scenegraph.getColGroup(col, true);\n colHeaderColGroup && updateColGroupContent(colHeaderColGroup, proxy);\n\n const bottomColGroup = proxy.table.scenegraph.getColGroupInBottom(col);\n bottomColGroup && updateColGroupContent(bottomColGroup, proxy);\n\n const rightTopColGroup = proxy.table.scenegraph.getColGroupInRightTopCorner(col);\n rightTopColGroup && updateColGroupContent(rightTopColGroup, proxy);\n\n const rightBottomColGroup = proxy.table.scenegraph.getColGroupInRightBottomCorner(col);\n rightBottomColGroup && updateColGroupContent(rightBottomColGroup, proxy);\n }\n}\n\nfunction updateAllColPosition(distStartColY: number, count: number, direction: 'left' | 'right', proxy: SceneProxy) {\n proxy.table.scenegraph.colHeaderGroup.forEachChildren((colGroup: Group, index: number) => {\n if (colGroup.type === 'group') {\n updateColGroupPosition(\n colGroup,\n direction === 'left' ? colGroup.col + count : colGroup.col - count,\n // (bodyGroup.lastChild as Group).attribute.x + (bodyGroup.lastChild as Group).attribute.width\n index === 0 // row === proxy.rowStart\n ? distStartColY\n : (colGroup._prev as Group).attribute.x + proxy.table.getColWidth((colGroup._prev as Group).col)\n );\n }\n });\n proxy.table.scenegraph.bottomFrozenGroup.forEachChildren((colGroup: Group, index: number) => {\n if (colGroup.type === 'group') {\n updateColGroupPosition(\n colGroup,\n direction === 'left' ? colGroup.col + count : colGroup.col - count,\n // (bodyGroup.lastChild as Group).attribute.x + (bodyGroup.lastChild as Group).attribute.width\n index === 0 // row === proxy.rowStart\n ? distStartColY\n : (colGroup._prev as Group).attribute.x + proxy.table.getColWidth((colGroup._prev as Group).col)\n );\n }\n });\n proxy.table.scenegraph.bodyGroup.forEachChildren((colGroup: Group, index: number) => {\n if (colGroup.type === 'group') {\n updateColGroupPosition(\n colGroup,\n direction === 'left' ? colGroup.col + count : colGroup.col - count,\n // (bodyGroup.lastChild as Group).attribute.x + (bodyGroup.lastChild as Group).attribute.width\n index === 0 // row === proxy.rowStart\n ? distStartColY\n : (colGroup._prev as Group).attribute.x + proxy.table.getColWidth((colGroup._prev as Group).col)\n );\n }\n });\n}\n"]}
|
|
1
|
+
{"version":3,"sources":["../src/scenegraph/group-creater/progress/update-position/dynamic-set-x.ts"],"names":[],"mappings":";;;;;;;;;;;;AAEA,yEAAqE;AAErE,6DAAwD;AACxD,iCAAyE;AAEzE,SAAsB,WAAW,CAAC,CAAS,EAAE,KAAiB;;QAC5D,MAAM,UAAU,GAAI,KAAK,CAAC,KAAsB,CAAC,cAAc,CAC7D,CAAC,GAAG,KAAK,CAAC,KAAK,CAAC,UAAU,CAAC,cAAc,CAAC,SAAS,CAAC,KAAK,CAC1D,CAAC;QACF,IAAI,CAAC,UAAU,EAAE;YACf,OAAO;SACR;QACD,MAAM,aAAa,GAAG,UAAU,CAAC,GAAG,CAAC;QACrC,MAAM,WA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AAK,CAAC,CAAC,CAAC,QAAQ,CAAC,GAAG,GAAG,KAAK,EAElE,KAAK,KAAK,CAAC;gBACT,CAAC,CAAC,aAAa;gBACf,CAAC,CAAE,QAAQ,CAAC,KAAe,CAAC,SAAS,CAAC,CAAC,GAAG,KAAK,CAAC,KAAK,CAAC,WAAW,CAAE,QAAQ,CAAC,KAAe,CAAC,GAAG,CAAC,CACnG,CAAC;SACH;IACH,CAAC,CAAC,CAAC;AACL,CAAC","file":"dynamic-set-x.js","sourcesContent":["import type { BaseTableAPI } from '../../../../ts-types/base-table';\nimport type { Group } from '../../../graphic/group';\nimport { computeColsWidth } from '../../../layout/compute-col-width';\nimport type { SceneProxy } from '../proxy';\nimport { updateAutoColumn } from './update-auto-column';\nimport { checkFirstColMerge, getFirstChild, getLastChild } from './util';\n\nexport async function dynamicSetX(x: number, proxy: SceneProxy) {\n const screenLeft = (proxy.table as BaseTableAPI).getTargetColAt(\n x + proxy.table.scenegraph.rowHeaderGroup.attribute.width\n );\n if (!screenLeft) {\n return;\n }\n const screenLeftCol = screenLeft.col;\n const screenLeftX = screenLeft.left;\n proxy.screenLeftCol = screenLeftCol;\n const deltaCol = proxy.screenLeftCol - proxy.referenceCol;\n\n move(deltaCol, screenLeftCol, screenLeftX, x, proxy);\n proxy.table.scenegraph.updateNextFrame();\n}\n\nfunction move(deltaCol: number, screenLeftCol: number, screenLeftX: number, x: number, proxy: SceneProxy) {\n if (deltaCol > 0) {\n // 向右滚动,左部column group移到右部\n moveColumn(deltaCol, 'left', proxy.screenLeftCol, screenLeftX, x, proxy);\n proxy.table.scenegraph.setBodyAndColHeaderX(-x + proxy.deltaX);\n } else if (deltaCol < 0) {\n // 向左滚动,右部cell group移到左部\n moveColumn(-deltaCol, 'right', proxy.screenLeftCol, screenLeftX, x, proxy);\n proxy.table.scenegraph.setBodyAndColHeaderX(-x + proxy.deltaX);\n } else {\n // 不改变row,更新body group范围\n proxy.table.scenegraph.setBodyAndColHeaderX(-x + proxy.deltaX);\n }\n}\n\nasync function moveColumn(\n count: number,\n direction: 'left' | 'right',\n screenLeftCol: number,\n screenLeftX: number,\n x: number,\n proxy: SceneProxy\n) {\n // 限制count范围\n if (direction === 'left' && proxy.colEnd + count > proxy.bodyRightCol) {\n count = proxy.bodyRightCol - proxy.colEnd;\n } else if (direction === 'right' && proxy.colStart - count < proxy.bodyLeftCol) {\n count = proxy.colStart - proxy.bodyLeftCol;\n }\n if (count === 0) {\n return;\n }\n if (count < 0) {\n direction = direction === 'left' ? 'right' : 'left';\n count = -count;\n }\n // 两种更新模式\n // 1. count < colEnd - colStart:从顶/底部移动count数量的单元格到底/顶部\n // 2. count >= colEnd - colStart:整体移动到目标位置\n if (count < proxy.colEnd - proxy.colStart) {\n // 计算更新区域\n const startCol = direction === 'left' ? proxy.colStart : proxy.colEnd - count + 1;\n const endCol = direction === 'left' ? proxy.colStart + count - 1 : proxy.colEnd;\n const distStartCol = direction === 'left' ? proxy.colEnd + 1 : proxy.colStart - count;\n const distEndCol = direction === 'left' ? proxy.colEnd + count : proxy.colStart - 1;\n // update column width\n computeColsWidth(proxy.table, distStartCol, distEndCol);\n updatePartColPosition(startCol, endCol, direction, proxy);\n\n const syncLeftCol = distStartCol;\n const syncRightCol = distEndCol;\n\n proxy.colStart = direction === 'left' ? proxy.colStart + count : proxy.colStart - count;\n proxy.colEnd = direction === 'left' ? proxy.colEnd + count : proxy.colEnd - count;\n\n updateColContent(syncLeftCol, syncRightCol, proxy);\n\n updateAutoColumn(\n syncLeftCol, // colStart\n syncRightCol, // colEnd\n proxy.table,\n direction\n );\n\n const colGroup =\n proxy.table.scenegraph.getColGroup(screenLeftCol) || proxy.table.scenegraph.getColGroup(screenLeftCol, true);\n const deltaX =\n screenLeftX - (colGroup.attribute.x + proxy.table.getFrozenColsWidth() + proxy.table.scenegraph.proxy.deltaX);\n proxy.table.scenegraph.proxy.deltaX += deltaX;\n\n proxy.currentCol = direction === 'left' ? proxy.currentCol + count : proxy.currentCol - count;\n proxy.totalCol = direction === 'left' ? proxy.totalCol + count : proxy.totalCol - count;\n proxy.referenceCol = proxy.colStart + Math.floor((proxy.colEnd - proxy.colStart) / 2);\n proxy.colUpdatePos = distStartCol;\n proxy.colUpdateDirection = direction;\n\n proxy.table.scenegraph.updateNextFrame();\n\n // 开始异步任务\n // await proxy.progress();\n } else {\n const distStartCol = direction === 'left' ? proxy.colStart + count : proxy.colStart - count;\n const distEndCol = direction === 'left' ? proxy.colEnd + count : proxy.colEnd - count;\n\n // update column width\n computeColsWidth(proxy.table, distStartCol, distEndCol);\n const distStartColY = proxy.table.getColsWidth(proxy.bodyLeftCol, distStartCol - 1);\n\n // 更新同步范围\n updateAllColPosition(distStartColY, count, direction, proxy);\n const syncLeftCol = distStartCol;\n const syncRightCol = distEndCol;\n\n proxy.colStart = distStartCol;\n proxy.colEnd = distEndCol;\n updateColContent(syncLeftCol, syncRightCol, proxy);\n\n updateAutoColumn(\n syncLeftCol, // colStart\n syncRightCol, // colEnd\n proxy.table,\n distEndCol > proxy.bodyRightCol - (proxy.colEnd - proxy.colStart + 1) ? 'right' : 'left' // 跳转到右侧时,从右向左对齐\n );\n // update body position when click scroll bar\n if (syncLeftCol === proxy.bodyLeftCol) {\n const colGroup = proxy.table.scenegraph.getColGroup(syncLeftCol);\n const deltaX = colGroup.attribute.x - x;\n proxy.table.scenegraph.proxy.deltaX = deltaX;\n } else if (syncRightCol === proxy.bodyRightCol) {\n const colGroup = proxy.table.scenegraph.getColGroup(syncRightCol);\n const deltaX =\n colGroup.attribute.x +\n colGroup.attribute.width -\n (proxy.table.tableNoFrameWidth - proxy.table.getFrozenColsWidth()) -\n x;\n proxy.table.scenegraph.proxy.deltaX = -deltaX;\n } else {\n // proxy.table.scenegraph.proxy.deltaX = 0;\n const colGroup =\n proxy.table.scenegraph.getColGroup(screenLeftCol) || proxy.table.scenegraph.getColGroup(screenLeftCol, true);\n const deltaX =\n screenLeftX - (colGroup.attribute.x + proxy.table.getFrozenColsWidth() + proxy.table.scenegraph.proxy.deltaX);\n proxy.table.scenegraph.proxy.deltaX = deltaX;\n }\n\n proxy.currentCol = direction === 'left' ? proxy.currentCol + count : proxy.currentCol - count;\n proxy.totalCol = direction === 'left' ? proxy.totalCol + count : proxy.totalCol - count;\n proxy.referenceCol = proxy.colStart + Math.floor((proxy.colEnd - proxy.colStart) / 2);\n proxy.colUpdatePos = proxy.colStart;\n proxy.colUpdateDirection = distEndCol > proxy.bodyRightCol - (proxy.colEnd - proxy.colStart + 1) ? 'right' : 'left';\n\n proxy.table.scenegraph.updateNextFrame();\n // await proxy.progress();\n }\n}\n\nfunction updateColGroupPosition(colGroup: Group, newCol: number, x: number) {\n // 更新位置&col\n colGroup.col = newCol;\n colGroup.forEachChildren((cellGroup: Group) => {\n cellGroup.col = newCol;\n cellGroup.needUpdate = true;\n });\n colGroup.setAttribute('x', x);\n colGroup.needUpdate = true;\n}\n\nfunction updateColGroupContent(colGroup: Group, proxy: SceneProxy) {\n if (!colGroup) {\n return;\n }\n // colGroup.forEachChildren((cellGroup: Group) => {\n // proxy.updateCellGroupContent(cellGroup);\n // });\n // for (let row = (colGroup.firstChild as Group).row; row <= (colGroup.lastChild as Group).row; row++) {\n // const cellGroup = proxy.highPerformanceGetCell(colGroup.col, row);\n // proxy.updateCellGroupContent(cellGroup);\n // }\n let cellGroup = colGroup.firstChild;\n while (cellGroup) {\n const newCellGroup = proxy.updateCellGroupContent(cellGroup as Group);\n cellGroup = newCellGroup._next;\n }\n colGroup.needUpdate = false;\n colGroup.setAttribute('width', proxy.table.getColWidth(colGroup.col));\n}\n\nfunction updatePartColPosition(startCol: number, endCol: number, direction: 'left' | 'right', proxy: SceneProxy) {\n for (let col = startCol; col <= endCol; col++) {\n if (\n proxy.table.scenegraph.bodyGroup.childrenCount > 0 &&\n proxy.table.scenegraph.bodyGroup.firstChild.type === 'group'\n ) {\n updateColPosition(proxy.table.scenegraph.bodyGroup, direction, proxy);\n }\n if (\n proxy.table.scenegraph.colHeaderGroup.childrenCount > 0 &&\n proxy.table.scenegraph.colHeaderGroup.firstChild.type === 'group'\n ) {\n updateColPosition(proxy.table.scenegraph.colHeaderGroup, direction, proxy);\n }\n if (\n proxy.table.scenegraph.bottomFrozenGroup.childrenCount > 0 &&\n proxy.table.scenegraph.bottomFrozenGroup.firstChild.type === 'group'\n ) {\n updateColPosition(proxy.table.scenegraph.bottomFrozenGroup, direction, proxy);\n }\n }\n}\n\nfunction updateColPosition(containerGroup: Group, direction: 'left' | 'right', proxy: SceneProxy) {\n if (direction === 'left') {\n const colGroup = getFirstChild(containerGroup);\n const lastChild = getLastChild(containerGroup);\n updateColGroupPosition(colGroup, lastChild.col + 1, lastChild.attribute.x + proxy.table.getColWidth(lastChild.col));\n containerGroup.appendChild(colGroup);\n // console.log('after', colGroup.col, colGroup.attribute.x, containerGroup._uid);\n if (containerGroup.border) {\n containerGroup.appendChild(containerGroup.border);\n }\n } else {\n const colGroup = getLastChild(containerGroup);\n const firstChild = getFirstChild(containerGroup);\n updateColGroupPosition(\n colGroup,\n firstChild.col - 1,\n firstChild.attribute.x - proxy.table.getColWidth(firstChild.col - 1)\n );\n containerGroup.insertBefore(colGroup, containerGroup.firstChild);\n }\n}\n\nexport function updateColContent(syncLeftCol: number, syncRightCol: number, proxy: SceneProxy) {\n for (let col = syncLeftCol; col <= syncRightCol; col++) {\n const colGroup = proxy.table.scenegraph.getColGroup(col);\n colGroup && updateColGroupContent(colGroup, proxy);\n\n const colHeaderColGroup = proxy.table.scenegraph.getColGroup(col, true);\n colHeaderColGroup && updateColGroupContent(colHeaderColGroup, proxy);\n\n const bottomColGroup = proxy.table.scenegraph.getColGroupInBottom(col);\n bottomColGroup && updateColGroupContent(bottomColGroup, proxy);\n\n const rightTopColGroup = proxy.table.scenegraph.getColGroupInRightTopCorner(col);\n rightTopColGroup && updateColGroupContent(rightTopColGroup, proxy);\n\n const rightBottomColGroup = proxy.table.scenegraph.getColGroupInRightBottomCorner(col);\n rightBottomColGroup && updateColGroupContent(rightBottomColGroup, proxy);\n }\n}\n\nfunction updateAllColPosition(distStartColY: number, count: number, direction: 'left' | 'right', proxy: SceneProxy) {\n proxy.table.scenegraph.colHeaderGroup.forEachChildren((colGroup: Group, index: number) => {\n if (colGroup.type === 'group') {\n updateColGroupPosition(\n colGroup,\n direction === 'left' ? colGroup.col + count : colGroup.col - count,\n // (bodyGroup.lastChild as Group).attribute.x + (bodyGroup.lastChild as Group).attribute.width\n index === 0 // row === proxy.rowStart\n ? distStartColY\n : (colGroup._prev as Group).attribute.x + proxy.table.getColWidth((colGroup._prev as Group).col)\n );\n }\n });\n proxy.table.scenegraph.bottomFrozenGroup.forEachChildren((colGroup: Group, index: number) => {\n if (colGroup.type === 'group') {\n updateColGroupPosition(\n colGroup,\n direction === 'left' ? colGroup.col + count : colGroup.col - count,\n // (bodyGroup.lastChild as Group).attribute.x + (bodyGroup.lastChild as Group).attribute.width\n index === 0 // row === proxy.rowStart\n ? distStartColY\n : (colGroup._prev as Group).attribute.x + proxy.table.getColWidth((colGroup._prev as Group).col)\n );\n }\n });\n proxy.table.scenegraph.bodyGroup.forEachChildren((colGroup: Group, index: number) => {\n if (colGroup.type === 'group') {\n updateColGroupPosition(\n colGroup,\n direction === 'left' ? colGroup.col + count : colGroup.col - count,\n // (bodyGroup.lastChild as Group).attribute.x + (bodyGroup.lastChild as Group).attribute.width\n index === 0 // row === proxy.rowStart\n ? distStartColY\n : (colGroup._prev as Group).attribute.x + proxy.table.getColWidth((colGroup._prev as Group).col)\n );\n }\n });\n}\n"]}
|
|
@@ -50,7 +50,8 @@ function move(deltaRow, screenTopRow, screenTopY, y, proxy) {
|
|
|
50
50
|
function moveCell(count, direction, screenTopRow, screenTopY, y, proxy) {
|
|
51
51
|
return __awaiter(this, void 0, void 0, (function*() {
|
|
52
52
|
if ("up" === direction && proxy.rowEnd + count > proxy.bodyBottomRow ? count = proxy.bodyBottomRow - proxy.rowEnd : "down" === direction && proxy.rowStart - count < proxy.bodyTopRow && (count = proxy.rowStart - proxy.bodyTopRow),
|
|
53
|
-
count < 0 && (direction = "up" === direction ? "down" : "up", count = -count),
|
|
53
|
+
0 !== count) if (count < 0 && (direction = "up" === direction ? "down" : "up", count = -count),
|
|
54
|
+
count < proxy.rowEnd - proxy.rowStart) {
|
|
54
55
|
const startRow = "up" === direction ? proxy.rowStart : proxy.rowEnd - count + 1, endRow = "up" === direction ? proxy.rowStart + count - 1 : proxy.rowEnd, distStartRow = "up" === direction ? proxy.rowEnd + 1 : proxy.rowStart - count, distEndRow = "up" === direction ? proxy.rowEnd + count : proxy.rowStart - 1;
|
|
55
56
|
let syncTopRow, syncBottomRow;
|
|
56
57
|
if ("autoHeight" === proxy.table.heightMode) syncTopRow = distStartRow, syncBottomRow = distEndRow; else {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/scenegraph/group-creater/progress/update-position/dynamic-set-y.ts"],"names":[],"mappings":";;;;;;;;;;;;AACA,2EAAuE;AAEvE,uDAAkD;AAElD,SAAsB,WAAW,CAAC,CAAS,EAAE,KAAiB;;QAG5D,MAAM,SAAS,GAAI,KAAK,CAAC,KAAa,CAAC,cAAc,CAAC,CAAC,GAAG,KAAK,CAAC,KAAK,CAAC,UAAU,CAAC,cAAc,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC;QAClH,IAAI,CAAC,SAAS,EAAE;YACd,OAAO;SACR;QACD,MAAM,YAAY,GAAG,SAAS,CAAC,GAAG,CAAC;QACnC,MAAM,UAAU,GAAG,SAAS,CAAC,GAAG,CAAC;QACjC,KAAK,CAAC,YAAY,GAAG,YAAY,CAAC;QAClC,MAAM,QAAQ,GAAG,YAAY,GAAG,KAAK,CAAC,YAAY,CAAC;QACnD,IAAI,CAAC,QAAQ,EAAE,YAAY,EAAE,UAAU,EAAE,CAAC,EAAE,KAAK,CAAC,CAAC;IAErD,CAAC;CAAA;AAbD,kCAaC;AAED,SAAS,IAAI,CAAC,QAAgB,EAAE,YAAoB,EAAE,UAAkB,EAAE,CAA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GAAG,GAAG,KAAK,CAAC,WAAW,EAAE,GAAG,IAAI,KAAK,CAAC,YAAY,EAAE,GAAG,EAAE,EAAE;QAClE,KAAK,IAAI,GAAG,GAAG,UAAU,EAAE,GAAG,IAAI,aAAa,EAAE,GAAG,EAAE,EAAE;YAEtD,MAAM,SAAS,GAAG,KAAK,CAAC,sBAAsB,CAAC,GAAG,EAAE,GAAG,CAAC,CAAC;YACzD,KAAK,CAAC,sBAAsB,CAAC,SAAS,CAAC,CAAC;SACzC;KACF;IACD,KAAK,CAAC,KAAK,CAAC,UAAU,CAAC,eAAe,EAAE,CAAC;AAC3C,CAAC;AA1BD,4CA0BC","file":"dynamic-set-y.js","sourcesContent":["import type { Group } from '../../../graphic/group';\nimport { computeRowsHeight } from '../../../layout/compute-row-height';\nimport type { SceneProxy } from '../proxy';\nimport { updateAutoRow } from './update-auto-row';\n\nexport async function dynamicSetY(y: number, proxy: SceneProxy) {\n // 计算变动row range\n // const screenTopRow = proxy.table.getRowAt(y).row;\n const screenTop = (proxy.table as any).getTargetRowAt(y + proxy.table.scenegraph.colHeaderGroup.attribute.height);\n if (!screenTop) {\n return;\n }\n const screenTopRow = screenTop.row;\n const screenTopY = screenTop.top;\n proxy.screenTopRow = screenTopRow;\n const deltaRow = screenTopRow - proxy.referenceRow;\n move(deltaRow, screenTopRow, screenTopY, y, proxy);\n // proxy.table.scenegraph.updateNextFrame();\n}\n\nfunction move(deltaRow: number, screenTopRow: number, screenTopY: number, y: number, proxy: SceneProxy) {\n if (deltaRow > 0) {\n // 向下滚动,顶部cell group移到底部\n moveCell(deltaRow, 'up', screenTopRow, screenTopY, y, proxy);\n proxy.updateBody(y - proxy.deltaY);\n } else if (deltaRow < 0) {\n // 向上滚动,底部cell group移到顶部\n moveCell(-deltaRow, 'down', screenTopRow, screenTopY, y, proxy);\n proxy.updateBody(y - proxy.deltaY);\n } else {\n // 不改变row,更新body group范围\n proxy.updateBody(y - proxy.deltaY);\n }\n}\n\nasync function moveCell(\n count: number,\n direction: 'up' | 'down',\n screenTopRow: number,\n screenTopY: number,\n y: number,\n proxy: SceneProxy\n) {\n // 限制count范围\n if (direction === 'up' && proxy.rowEnd + count > proxy.bodyBottomRow) {\n count = proxy.bodyBottomRow - proxy.rowEnd;\n } else if (direction === 'down' && proxy.rowStart - count < proxy.bodyTopRow) {\n count = proxy.rowStart - proxy.bodyTopRow;\n }\n if (count < 0) {\n direction = direction === 'up' ? 'down' : 'up';\n count = -count;\n }\n\n // 两种更新模式\n // 1. count < rowEnd - rowStart:从顶/底部移动count数量的单元格到底/顶部\n // 2. count >= rowEnd - rowStart:整体移动到目标位置\n if (count < proxy.rowEnd - proxy.rowStart) {\n // 计算更新区域\n const startRow = direction === 'up' ? proxy.rowStart : proxy.rowEnd - count + 1;\n const endRow = direction === 'up' ? proxy.rowStart + count - 1 : proxy.rowEnd;\n const distStartRow = direction === 'up' ? proxy.rowEnd + 1 : proxy.rowStart - count;\n const distEndRow = direction === 'up' ? proxy.rowEnd + count : proxy.rowStart - 1;\n\n // 更新同步范围\n let syncTopRow;\n let syncBottomRow;\n if (proxy.table.heightMode === 'autoHeight') {\n syncTopRow = distStartRow;\n syncBottomRow = distEndRow;\n } else {\n const topRow = Math.max(proxy.bodyTopRow, screenTopRow - proxy.screenRowCount * 1);\n const bottomRow = Math.min(proxy.bodyBottomRow, screenTopRow + proxy.screenRowCount * 2);\n // get coincide of distStartRow&distEndRow and topRow&BottomRow\n // syncTopRow = Math.max(distStartRow, topRow);\n // syncBottomRow = Math.min(distEndRow, bottomRow);\n syncTopRow = topRow;\n syncBottomRow = bottomRow;\n }\n\n // const syncTopRow = Math.max(proxy.bodyTopRow, screenTopRow - proxy.screenRowCount * 1);\n // const syncBottomRow = Math.min(proxy.bodyBottomRow, screenTopRow + proxy.screenRowCount * 2);\n computeRowsHeight(proxy.table, syncTopRow, syncBottomRow, proxy.table.heightMode === 'autoHeight');\n\n // console.log('move', startRow, endRow, direction);\n updatePartRowPosition(startRow, endRow, direction, proxy);\n\n proxy.rowStart = direction === 'up' ? proxy.rowStart + count : proxy.rowStart - count;\n proxy.rowEnd = direction === 'up' ? proxy.rowEnd + count : proxy.rowEnd - count;\n\n updateRowContent(syncTopRow, syncBottomRow, proxy);\n\n if (proxy.table.heightMode === 'autoHeight') {\n // body group\n updateAutoRow(\n proxy.bodyLeftCol, // colStart\n proxy.bodyRightCol, // colEnd\n syncTopRow, // rowStart\n syncBottomRow, // rowEnd\n proxy.table,\n distEndRow > proxy.bodyBottomRow - (proxy.rowEnd - proxy.rowStart + 1) ? 'down' : 'up' // 跳转到底部时,从下向上对齐\n );\n\n // row header group\n updateAutoRow(\n 0, // colStart\n proxy.table.frozenColCount - 1, // colEnd\n syncTopRow, // rowStart\n syncBottomRow, // rowEnd\n proxy.table,\n distEndRow > proxy.bodyBottomRow - (proxy.rowEnd - proxy.rowStart + 1) ? 'down' : 'up' // 跳转到底部时,从下向上对齐\n );\n\n // right frozen group\n updateAutoRow(\n proxy.table.colCount - proxy.table.rightFrozenColCount, // colStart\n proxy.table.colCount - 1, // colEnd\n syncTopRow, // rowStart\n syncBottomRow, // rowEnd\n proxy.table,\n distEndRow > proxy.bodyBottomRow - (proxy.rowEnd - proxy.rowStart + 1) ? 'down' : 'up' // 跳转到底部时,从下向上对齐\n );\n\n const cellGroup = proxy.table.scenegraph.highPerformanceGetCell(proxy.bodyLeftCol, screenTopRow, true);\n const deltaY =\n screenTopY - (cellGroup.attribute.y + proxy.table.getFrozenRowsHeight() + proxy.table.scenegraph.proxy.deltaY);\n proxy.table.scenegraph.proxy.deltaY += deltaY;\n }\n\n proxy.currentRow = direction === 'up' ? proxy.currentRow + count : proxy.currentRow - count;\n proxy.totalRow = Math.max(\n 0,\n Math.min(proxy.table.rowCount - 1, direction === 'up' ? proxy.totalRow + count : proxy.totalRow - count)\n );\n proxy.referenceRow = proxy.rowStart + Math.floor((proxy.rowEnd - proxy.rowStart) / 2);\n proxy.rowUpdatePos = Math.min(proxy.rowUpdatePos, distStartRow);\n proxy.rowUpdateDirection = direction;\n\n proxy.table.scenegraph.updateNextFrame();\n if (proxy.table.heightMode !== 'autoHeight') {\n await proxy.progress();\n }\n } else {\n const distStartRow = direction === 'up' ? proxy.rowStart + count : proxy.rowStart - count;\n const distEndRow = direction === 'up' ? proxy.rowEnd + count : proxy.rowEnd - count;\n const distStartRowY = proxy.table.getRowsHeight(proxy.bodyTopRow, distStartRow - 1);\n\n let syncTopRow;\n let syncBottomRow;\n if (proxy.table.heightMode === 'autoHeight') {\n syncTopRow = distStartRow;\n syncBottomRow = distEndRow;\n } else {\n syncTopRow = Math.max(proxy.bodyTopRow, screenTopRow - proxy.screenRowCount * 1);\n syncBottomRow = Math.min(proxy.bodyBottomRow, screenTopRow + proxy.screenRowCount * 2);\n }\n //console.log('更新同步范围', syncTopRow, syncBottomRow);\n\n computeRowsHeight(proxy.table, syncTopRow, syncBottomRow);\n\n // 更新同步范围\n updateAllRowPosition(distStartRowY, count, direction, proxy);\n\n proxy.rowStart = distStartRow;\n proxy.rowEnd = distEndRow;\n\n updateRowContent(syncTopRow, syncBottomRow, proxy);\n\n if (proxy.table.heightMode === 'autoHeight') {\n // body group\n updateAutoRow(\n proxy.bodyLeftCol, // colStart\n proxy.bodyRightCol, // colEnd\n syncTopRow, // rowStart\n syncBottomRow, // rowEnd\n proxy.table,\n distEndRow > proxy.bodyBottomRow - (proxy.rowEnd - proxy.rowStart + 1) ? 'down' : 'up' // 跳转到底部时,从下向上对齐\n );\n\n // row header group\n updateAutoRow(\n 0, // colStart\n proxy.table.frozenColCount - 1, // colEnd\n syncTopRow, // rowStart\n syncBottomRow, // rowEnd\n proxy.table,\n distEndRow > proxy.bodyBottomRow - (proxy.rowEnd - proxy.rowStart + 1) ? 'down' : 'up' // 跳转到底部时,从下向上对齐\n );\n\n // right frozen group\n updateAutoRow(\n proxy.table.colCount - proxy.table.rightFrozenColCount, // colStart\n proxy.table.colCount - 1, // colEnd\n syncTopRow, // rowStart\n syncBottomRow, // rowEnd\n proxy.table,\n distEndRow > proxy.bodyBottomRow - (proxy.rowEnd - proxy.rowStart + 1) ? 'down' : 'up' // 跳转到底部时,从下向上对齐\n );\n }\n\n // update body position when click scroll bar\n if (syncTopRow === proxy.bodyTopRow) {\n const cellGroup = proxy.table.scenegraph.highPerformanceGetCell(proxy.bodyLeftCol, syncTopRow, true);\n const deltaY = cellGroup.attribute.y - y;\n proxy.table.scenegraph.proxy.deltaY = deltaY;\n } else if (syncBottomRow === proxy.bodyBottomRow) {\n const cellGroup = proxy.table.scenegraph.highPerformanceGetCell(proxy.bodyLeftCol, syncBottomRow, true);\n const deltaY =\n cellGroup.attribute.y +\n cellGroup.attribute.height -\n (proxy.table.tableNoFrameHeight - proxy.table.getFrozenRowsHeight()) -\n y;\n proxy.table.scenegraph.proxy.deltaY = -deltaY;\n } else {\n const cellGroup = proxy.table.scenegraph.highPerformanceGetCell(proxy.bodyLeftCol, screenTopRow, true);\n const deltaY =\n screenTopY - (cellGroup.attribute.y + proxy.table.getFrozenRowsHeight() + proxy.table.scenegraph.proxy.deltaY);\n proxy.table.scenegraph.proxy.deltaY = deltaY;\n }\n\n proxy.currentRow = direction === 'up' ? proxy.currentRow + count : proxy.currentRow - count;\n proxy.totalRow = Math.max(\n 0,\n Math.min(proxy.table.rowCount - 1, direction === 'up' ? proxy.totalRow + count : proxy.totalRow - count)\n );\n proxy.referenceRow = proxy.rowStart + Math.floor((proxy.rowEnd - proxy.rowStart) / 2);\n proxy.rowUpdatePos = proxy.rowStart;\n proxy.rowUpdateDirection = distEndRow > proxy.bodyBottomRow - (proxy.rowEnd - proxy.rowStart + 1) ? 'down' : 'up';\n\n proxy.table.scenegraph.updateNextFrame();\n if (proxy.table.heightMode !== 'autoHeight') {\n await proxy.progress();\n }\n }\n}\n\nfunction updatePartRowPosition(startRow: number, endRow: number, direction: 'up' | 'down', proxy: SceneProxy) {\n // row header group\n for (let col = 0; col < proxy.table.frozenColCount; col++) {\n const colGroup = proxy.table.scenegraph.getColGroup(col);\n if (!colGroup) {\n continue;\n }\n for (let row = startRow; row <= endRow; row++) {\n updateCellGroupPosition(colGroup, direction, proxy);\n }\n }\n // right frozen group\n for (let col = proxy.table.colCount - proxy.table.rightFrozenColCount; col < proxy.table.colCount; col++) {\n const colGroup = proxy.table.scenegraph.getColGroup(col);\n if (!colGroup) {\n continue;\n }\n for (let row = startRow; row <= endRow; row++) {\n updateCellGroupPosition(colGroup, direction, proxy);\n }\n }\n // body group\n for (let col = proxy.bodyLeftCol; col <= proxy.bodyRightCol; col++) {\n const colGroup = proxy.table.scenegraph.getColGroup(col);\n if (colGroup) {\n for (let row = startRow; row <= endRow; row++) {\n updateCellGroupPosition(colGroup, direction, proxy);\n }\n }\n }\n}\n\nfunction updateCellGroupPosition(colGroup: Group, direction: 'up' | 'down', proxy: SceneProxy) {\n if (direction === 'up') {\n const cellGroup = colGroup.firstChild as Group;\n proxy.updateCellGroupPosition(\n cellGroup,\n (colGroup.lastChild as Group).row + 1,\n (colGroup.lastChild as Group).attribute.y + proxy.table.getRowHeight((colGroup.lastChild as Group).row) // (colGroup.lastChild as Group).attribute.height\n );\n colGroup.appendChild(cellGroup);\n } else {\n const cellGroup = colGroup.lastChild as Group;\n proxy.updateCellGroupPosition(\n cellGroup,\n (colGroup.firstChild as Group).row - 1,\n (colGroup.firstChild as Group).attribute.y - proxy.table.getRowHeight((cellGroup as Group).row) // cellGroup.attribute.height\n );\n colGroup.insertBefore(cellGroup, colGroup.firstChild);\n }\n}\n\nfunction updateAllRowPosition(distStartRowY: number, count: number, direction: 'up' | 'down', proxy: SceneProxy) {\n // row header group\n for (let col = 0; col < proxy.table.frozenColCount; col++) {\n const colGroup = proxy.table.scenegraph.getColGroup(col);\n colGroup?.forEachChildren((cellGroup: Group, index) => {\n // 这里使用colGroup变量而不是for proxy.rowStart to proxy.rowEndproxy.rowEnd是因为在更新内可能出现row号码重复的情况\n proxy.updateCellGroupPosition(\n cellGroup,\n direction === 'up' ? cellGroup.row + count : cellGroup.row - count,\n index === 0 // row === proxy.rowStart\n ? distStartRowY\n : (cellGroup._prev as Group).attribute.y + proxy.table.getRowHeight((cellGroup._prev as Group).row)\n );\n });\n }\n // right frozen group\n for (let col = proxy.table.colCount - proxy.table.rightFrozenColCount; col < proxy.table.colCount; col++) {\n const colGroup = proxy.table.scenegraph.getColGroup(col);\n colGroup?.forEachChildren((cellGroup: Group, index) => {\n // 这里使用colGroup变量而不是for proxy.rowStart to proxy.rowEndproxy.rowEnd是因为在更新内可能出现row号码重复的情况\n proxy.updateCellGroupPosition(\n cellGroup,\n direction === 'up' ? cellGroup.row + count : cellGroup.row - count,\n index === 0 // row === proxy.rowStart\n ? distStartRowY\n : (cellGroup._prev as Group).attribute.y + proxy.table.getRowHeight((cellGroup._prev as Group).row)\n );\n });\n }\n // body group\n for (let col = proxy.bodyLeftCol; col <= proxy.bodyRightCol; col++) {\n const colGroup = proxy.table.scenegraph.getColGroup(col);\n colGroup?.forEachChildren((cellGroup: Group, index) => {\n // 这里使用colGroup变量而不是for proxy.rowStart to proxy.rowEndproxy.rowEnd是因为在更新内可能出现row号码重复的情况\n proxy.updateCellGroupPosition(\n cellGroup,\n direction === 'up' ? cellGroup.row + count : cellGroup.row - count,\n index === 0 // row === proxy.rowStart\n ? distStartRowY\n : (cellGroup._prev as Group).attribute.y + proxy.table.getRowHeight((cellGroup._prev as Group).row)\n );\n });\n }\n}\n\nexport function updateRowContent(syncTopRow: number, syncBottomRow: number, proxy: SceneProxy) {\n // row header group\n for (let col = 0; col < proxy.table.frozenColCount; col++) {\n for (let row = syncTopRow; row <= syncBottomRow; row++) {\n // const cellGroup = proxy.table.scenegraph.getCell(col, row);\n const cellGroup = proxy.highPerformanceGetCell(col, row, true);\n proxy.updateCellGroupContent(cellGroup);\n }\n }\n // right frozen group\n for (let col = proxy.table.colCount - proxy.table.rightFrozenColCount; col < proxy.table.colCount; col++) {\n for (let row = syncTopRow; row <= syncBottomRow; row++) {\n // const cellGroup = proxy.table.scenegraph.getCell(col, row);\n const cellGroup = proxy.highPerformanceGetCell(col, row);\n proxy.updateCellGroupContent(cellGroup);\n }\n }\n // body group\n for (let col = proxy.bodyLeftCol; col <= proxy.bodyRightCol; col++) {\n for (let row = syncTopRow; row <= syncBottomRow; row++) {\n // const cellGroup = proxy.table.scenegraph.getCell(col, row);\n const cellGroup = proxy.highPerformanceGetCell(col, row);\n proxy.updateCellGroupContent(cellGroup);\n }\n }\n proxy.table.scenegraph.updateNextFrame();\n}\n"]}
|
|
1
|
+
{"version":3,"sources":["../src/scenegraph/group-creater/progress/update-position/dynamic-set-y.ts"],"names":[],"mappings":";;;;;;;;;;;;AACA,2EAAuE;AAEvE,uDAAkD;AAElD,SAAsB,WAAW,CAAC,CAAS,EAAE,KAAiB;;QAG5D,MAAM,SAAS,GAAI,KAAK,CAAC,KAAa,CAAC,cAAc,CAAC,CAAC,GAAG,KAAK,CAAC,KAAK,CAAC,UAAU,CAAC,cAAc,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC;QAClH,IAAI,CAAC,SAAS,EAAE;YACd,OAAO;SACR;QACD,MAAM,YAAY,GAAG,SAAS,CAAC,GAAG,CAAC;QACnC,MAAM,UAAU,GAAG,SAAS,CAAC,GAAG,CAAC;QACjC,KAAK,CAAC,YAAY,GAAG,YAAY,CAAC;QAClC,MAAM,QAAQ,GAAG,YAAY,GAAG,KAAK,CAAC,YAAY,CAAC;QACnD,IAAI,CAAC,QAAQ,EAAE,YAAY,EAAE,UAAU,EAAE,CAAC,EAAE,KAAK,CAAC,CAAC;IAErD,CAAC;CAAA;AAbD,kCAaC;AAED,SAAS,IAAI,CAAC,QAAgB,EAAE,YAAoB,EAAE,UAAkB,EAAE,CAAS,EAAE,KAAiB;IACpG,IAAI,QAAQ,GAAG,CAAC,EAAE;QAEhB,QAAQ,CAAC,QAAQ,EAAE,IAAI,EAAE,YAAY,EAAE,UAAU,EAAE,CAAC,EAAE,KAAK,CAAC,CAAC;QAC7D,KAAK,CAAC,UAAU,CAAC,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AAG,IAAI,aAAa,EAAE,GAAG,EAAE,EAAE;YAEtD,MAAM,SAAS,GAAG,KAAK,CAAC,sBAAsB,CAAC,GAAG,EAAE,GAAG,CAAC,CAAC;YACzD,KAAK,CAAC,sBAAsB,CAAC,SAAS,CAAC,CAAC;SACzC;KACF;IACD,KAAK,CAAC,KAAK,CAAC,UAAU,CAAC,eAAe,EAAE,CAAC;AAC3C,CAAC;AA1BD,4CA0BC","file":"dynamic-set-y.js","sourcesContent":["import type { Group } from '../../../graphic/group';\nimport { computeRowsHeight } from '../../../layout/compute-row-height';\nimport type { SceneProxy } from '../proxy';\nimport { updateAutoRow } from './update-auto-row';\n\nexport async function dynamicSetY(y: number, proxy: SceneProxy) {\n // 计算变动row range\n // const screenTopRow = proxy.table.getRowAt(y).row;\n const screenTop = (proxy.table as any).getTargetRowAt(y + proxy.table.scenegraph.colHeaderGroup.attribute.height);\n if (!screenTop) {\n return;\n }\n const screenTopRow = screenTop.row;\n const screenTopY = screenTop.top;\n proxy.screenTopRow = screenTopRow;\n const deltaRow = screenTopRow - proxy.referenceRow;\n move(deltaRow, screenTopRow, screenTopY, y, proxy);\n // proxy.table.scenegraph.updateNextFrame();\n}\n\nfunction move(deltaRow: number, screenTopRow: number, screenTopY: number, y: number, proxy: SceneProxy) {\n if (deltaRow > 0) {\n // 向下滚动,顶部cell group移到底部\n moveCell(deltaRow, 'up', screenTopRow, screenTopY, y, proxy);\n proxy.updateBody(y - proxy.deltaY);\n } else if (deltaRow < 0) {\n // 向上滚动,底部cell group移到顶部\n moveCell(-deltaRow, 'down', screenTopRow, screenTopY, y, proxy);\n proxy.updateBody(y - proxy.deltaY);\n } else {\n // 不改变row,更新body group范围\n proxy.updateBody(y - proxy.deltaY);\n }\n}\n\nasync function moveCell(\n count: number,\n direction: 'up' | 'down',\n screenTopRow: number,\n screenTopY: number,\n y: number,\n proxy: SceneProxy\n) {\n // 限制count范围\n if (direction === 'up' && proxy.rowEnd + count > proxy.bodyBottomRow) {\n count = proxy.bodyBottomRow - proxy.rowEnd;\n } else if (direction === 'down' && proxy.rowStart - count < proxy.bodyTopRow) {\n count = proxy.rowStart - proxy.bodyTopRow;\n }\n if (count === 0) {\n return;\n }\n if (count < 0) {\n direction = direction === 'up' ? 'down' : 'up';\n count = -count;\n }\n\n // 两种更新模式\n // 1. count < rowEnd - rowStart:从顶/底部移动count数量的单元格到底/顶部\n // 2. count >= rowEnd - rowStart:整体移动到目标位置\n if (count < proxy.rowEnd - proxy.rowStart) {\n // 计算更新区域\n const startRow = direction === 'up' ? proxy.rowStart : proxy.rowEnd - count + 1;\n const endRow = direction === 'up' ? proxy.rowStart + count - 1 : proxy.rowEnd;\n const distStartRow = direction === 'up' ? proxy.rowEnd + 1 : proxy.rowStart - count;\n const distEndRow = direction === 'up' ? proxy.rowEnd + count : proxy.rowStart - 1;\n\n // 更新同步范围\n let syncTopRow;\n let syncBottomRow;\n if (proxy.table.heightMode === 'autoHeight') {\n syncTopRow = distStartRow;\n syncBottomRow = distEndRow;\n } else {\n const topRow = Math.max(proxy.bodyTopRow, screenTopRow - proxy.screenRowCount * 1);\n const bottomRow = Math.min(proxy.bodyBottomRow, screenTopRow + proxy.screenRowCount * 2);\n // get coincide of distStartRow&distEndRow and topRow&BottomRow\n // syncTopRow = Math.max(distStartRow, topRow);\n // syncBottomRow = Math.min(distEndRow, bottomRow);\n syncTopRow = topRow;\n syncBottomRow = bottomRow;\n }\n\n // const syncTopRow = Math.max(proxy.bodyTopRow, screenTopRow - proxy.screenRowCount * 1);\n // const syncBottomRow = Math.min(proxy.bodyBottomRow, screenTopRow + proxy.screenRowCount * 2);\n computeRowsHeight(proxy.table, syncTopRow, syncBottomRow, proxy.table.heightMode === 'autoHeight');\n\n // console.log('move', startRow, endRow, direction);\n updatePartRowPosition(startRow, endRow, direction, proxy);\n\n proxy.rowStart = direction === 'up' ? proxy.rowStart + count : proxy.rowStart - count;\n proxy.rowEnd = direction === 'up' ? proxy.rowEnd + count : proxy.rowEnd - count;\n\n updateRowContent(syncTopRow, syncBottomRow, proxy);\n\n if (proxy.table.heightMode === 'autoHeight') {\n // body group\n updateAutoRow(\n proxy.bodyLeftCol, // colStart\n proxy.bodyRightCol, // colEnd\n syncTopRow, // rowStart\n syncBottomRow, // rowEnd\n proxy.table,\n distEndRow > proxy.bodyBottomRow - (proxy.rowEnd - proxy.rowStart + 1) ? 'down' : 'up' // 跳转到底部时,从下向上对齐\n );\n\n // row header group\n updateAutoRow(\n 0, // colStart\n proxy.table.frozenColCount - 1, // colEnd\n syncTopRow, // rowStart\n syncBottomRow, // rowEnd\n proxy.table,\n distEndRow > proxy.bodyBottomRow - (proxy.rowEnd - proxy.rowStart + 1) ? 'down' : 'up' // 跳转到底部时,从下向上对齐\n );\n\n // right frozen group\n updateAutoRow(\n proxy.table.colCount - proxy.table.rightFrozenColCount, // colStart\n proxy.table.colCount - 1, // colEnd\n syncTopRow, // rowStart\n syncBottomRow, // rowEnd\n proxy.table,\n distEndRow > proxy.bodyBottomRow - (proxy.rowEnd - proxy.rowStart + 1) ? 'down' : 'up' // 跳转到底部时,从下向上对齐\n );\n\n const cellGroup = proxy.table.scenegraph.highPerformanceGetCell(proxy.bodyLeftCol, screenTopRow, true);\n const deltaY =\n screenTopY - (cellGroup.attribute.y + proxy.table.getFrozenRowsHeight() + proxy.table.scenegraph.proxy.deltaY);\n proxy.table.scenegraph.proxy.deltaY += deltaY;\n }\n\n proxy.currentRow = direction === 'up' ? proxy.currentRow + count : proxy.currentRow - count;\n proxy.totalRow = Math.max(\n 0,\n Math.min(proxy.table.rowCount - 1, direction === 'up' ? proxy.totalRow + count : proxy.totalRow - count)\n );\n proxy.referenceRow = proxy.rowStart + Math.floor((proxy.rowEnd - proxy.rowStart) / 2);\n proxy.rowUpdatePos = Math.min(proxy.rowUpdatePos, distStartRow);\n proxy.rowUpdateDirection = direction;\n\n proxy.table.scenegraph.updateNextFrame();\n if (proxy.table.heightMode !== 'autoHeight') {\n await proxy.progress();\n }\n } else {\n const distStartRow = direction === 'up' ? proxy.rowStart + count : proxy.rowStart - count;\n const distEndRow = direction === 'up' ? proxy.rowEnd + count : proxy.rowEnd - count;\n const distStartRowY = proxy.table.getRowsHeight(proxy.bodyTopRow, distStartRow - 1);\n\n let syncTopRow;\n let syncBottomRow;\n if (proxy.table.heightMode === 'autoHeight') {\n syncTopRow = distStartRow;\n syncBottomRow = distEndRow;\n } else {\n syncTopRow = Math.max(proxy.bodyTopRow, screenTopRow - proxy.screenRowCount * 1);\n syncBottomRow = Math.min(proxy.bodyBottomRow, screenTopRow + proxy.screenRowCount * 2);\n }\n //console.log('更新同步范围', syncTopRow, syncBottomRow);\n\n computeRowsHeight(proxy.table, syncTopRow, syncBottomRow);\n\n // 更新同步范围\n updateAllRowPosition(distStartRowY, count, direction, proxy);\n\n proxy.rowStart = distStartRow;\n proxy.rowEnd = distEndRow;\n\n updateRowContent(syncTopRow, syncBottomRow, proxy);\n\n if (proxy.table.heightMode === 'autoHeight') {\n // body group\n updateAutoRow(\n proxy.bodyLeftCol, // colStart\n proxy.bodyRightCol, // colEnd\n syncTopRow, // rowStart\n syncBottomRow, // rowEnd\n proxy.table,\n distEndRow > proxy.bodyBottomRow - (proxy.rowEnd - proxy.rowStart + 1) ? 'down' : 'up' // 跳转到底部时,从下向上对齐\n );\n\n // row header group\n updateAutoRow(\n 0, // colStart\n proxy.table.frozenColCount - 1, // colEnd\n syncTopRow, // rowStart\n syncBottomRow, // rowEnd\n proxy.table,\n distEndRow > proxy.bodyBottomRow - (proxy.rowEnd - proxy.rowStart + 1) ? 'down' : 'up' // 跳转到底部时,从下向上对齐\n );\n\n // right frozen group\n updateAutoRow(\n proxy.table.colCount - proxy.table.rightFrozenColCount, // colStart\n proxy.table.colCount - 1, // colEnd\n syncTopRow, // rowStart\n syncBottomRow, // rowEnd\n proxy.table,\n distEndRow > proxy.bodyBottomRow - (proxy.rowEnd - proxy.rowStart + 1) ? 'down' : 'up' // 跳转到底部时,从下向上对齐\n );\n }\n\n // update body position when click scroll bar\n if (syncTopRow === proxy.bodyTopRow) {\n const cellGroup = proxy.table.scenegraph.highPerformanceGetCell(proxy.bodyLeftCol, syncTopRow, true);\n const deltaY = cellGroup.attribute.y - y;\n proxy.table.scenegraph.proxy.deltaY = deltaY;\n } else if (syncBottomRow === proxy.bodyBottomRow) {\n const cellGroup = proxy.table.scenegraph.highPerformanceGetCell(proxy.bodyLeftCol, syncBottomRow, true);\n const deltaY =\n cellGroup.attribute.y +\n cellGroup.attribute.height -\n (proxy.table.tableNoFrameHeight - proxy.table.getFrozenRowsHeight()) -\n y;\n proxy.table.scenegraph.proxy.deltaY = -deltaY;\n } else {\n const cellGroup = proxy.table.scenegraph.highPerformanceGetCell(proxy.bodyLeftCol, screenTopRow, true);\n const deltaY =\n screenTopY - (cellGroup.attribute.y + proxy.table.getFrozenRowsHeight() + proxy.table.scenegraph.proxy.deltaY);\n proxy.table.scenegraph.proxy.deltaY = deltaY;\n }\n\n proxy.currentRow = direction === 'up' ? proxy.currentRow + count : proxy.currentRow - count;\n proxy.totalRow = Math.max(\n 0,\n Math.min(proxy.table.rowCount - 1, direction === 'up' ? proxy.totalRow + count : proxy.totalRow - count)\n );\n proxy.referenceRow = proxy.rowStart + Math.floor((proxy.rowEnd - proxy.rowStart) / 2);\n proxy.rowUpdatePos = proxy.rowStart;\n proxy.rowUpdateDirection = distEndRow > proxy.bodyBottomRow - (proxy.rowEnd - proxy.rowStart + 1) ? 'down' : 'up';\n\n proxy.table.scenegraph.updateNextFrame();\n if (proxy.table.heightMode !== 'autoHeight') {\n await proxy.progress();\n }\n }\n}\n\nfunction updatePartRowPosition(startRow: number, endRow: number, direction: 'up' | 'down', proxy: SceneProxy) {\n // row header group\n for (let col = 0; col < proxy.table.frozenColCount; col++) {\n const colGroup = proxy.table.scenegraph.getColGroup(col);\n if (!colGroup) {\n continue;\n }\n for (let row = startRow; row <= endRow; row++) {\n updateCellGroupPosition(colGroup, direction, proxy);\n }\n }\n // right frozen group\n for (let col = proxy.table.colCount - proxy.table.rightFrozenColCount; col < proxy.table.colCount; col++) {\n const colGroup = proxy.table.scenegraph.getColGroup(col);\n if (!colGroup) {\n continue;\n }\n for (let row = startRow; row <= endRow; row++) {\n updateCellGroupPosition(colGroup, direction, proxy);\n }\n }\n // body group\n for (let col = proxy.bodyLeftCol; col <= proxy.bodyRightCol; col++) {\n const colGroup = proxy.table.scenegraph.getColGroup(col);\n if (colGroup) {\n for (let row = startRow; row <= endRow; row++) {\n updateCellGroupPosition(colGroup, direction, proxy);\n }\n }\n }\n}\n\nfunction updateCellGroupPosition(colGroup: Group, direction: 'up' | 'down', proxy: SceneProxy) {\n if (direction === 'up') {\n const cellGroup = colGroup.firstChild as Group;\n proxy.updateCellGroupPosition(\n cellGroup,\n (colGroup.lastChild as Group).row + 1,\n (colGroup.lastChild as Group).attribute.y + proxy.table.getRowHeight((colGroup.lastChild as Group).row) // (colGroup.lastChild as Group).attribute.height\n );\n colGroup.appendChild(cellGroup);\n } else {\n const cellGroup = colGroup.lastChild as Group;\n proxy.updateCellGroupPosition(\n cellGroup,\n (colGroup.firstChild as Group).row - 1,\n (colGroup.firstChild as Group).attribute.y - proxy.table.getRowHeight((cellGroup as Group).row) // cellGroup.attribute.height\n );\n colGroup.insertBefore(cellGroup, colGroup.firstChild);\n }\n}\n\nfunction updateAllRowPosition(distStartRowY: number, count: number, direction: 'up' | 'down', proxy: SceneProxy) {\n // row header group\n for (let col = 0; col < proxy.table.frozenColCount; col++) {\n const colGroup = proxy.table.scenegraph.getColGroup(col);\n colGroup?.forEachChildren((cellGroup: Group, index) => {\n // 这里使用colGroup变量而不是for proxy.rowStart to proxy.rowEndproxy.rowEnd是因为在更新内可能出现row号码重复的情况\n proxy.updateCellGroupPosition(\n cellGroup,\n direction === 'up' ? cellGroup.row + count : cellGroup.row - count,\n index === 0 // row === proxy.rowStart\n ? distStartRowY\n : (cellGroup._prev as Group).attribute.y + proxy.table.getRowHeight((cellGroup._prev as Group).row)\n );\n });\n }\n // right frozen group\n for (let col = proxy.table.colCount - proxy.table.rightFrozenColCount; col < proxy.table.colCount; col++) {\n const colGroup = proxy.table.scenegraph.getColGroup(col);\n colGroup?.forEachChildren((cellGroup: Group, index) => {\n // 这里使用colGroup变量而不是for proxy.rowStart to proxy.rowEndproxy.rowEnd是因为在更新内可能出现row号码重复的情况\n proxy.updateCellGroupPosition(\n cellGroup,\n direction === 'up' ? cellGroup.row + count : cellGroup.row - count,\n index === 0 // row === proxy.rowStart\n ? distStartRowY\n : (cellGroup._prev as Group).attribute.y + proxy.table.getRowHeight((cellGroup._prev as Group).row)\n );\n });\n }\n // body group\n for (let col = proxy.bodyLeftCol; col <= proxy.bodyRightCol; col++) {\n const colGroup = proxy.table.scenegraph.getColGroup(col);\n colGroup?.forEachChildren((cellGroup: Group, index) => {\n // 这里使用colGroup变量而不是for proxy.rowStart to proxy.rowEndproxy.rowEnd是因为在更新内可能出现row号码重复的情况\n proxy.updateCellGroupPosition(\n cellGroup,\n direction === 'up' ? cellGroup.row + count : cellGroup.row - count,\n index === 0 // row === proxy.rowStart\n ? distStartRowY\n : (cellGroup._prev as Group).attribute.y + proxy.table.getRowHeight((cellGroup._prev as Group).row)\n );\n });\n }\n}\n\nexport function updateRowContent(syncTopRow: number, syncBottomRow: number, proxy: SceneProxy) {\n // row header group\n for (let col = 0; col < proxy.table.frozenColCount; col++) {\n for (let row = syncTopRow; row <= syncBottomRow; row++) {\n // const cellGroup = proxy.table.scenegraph.getCell(col, row);\n const cellGroup = proxy.highPerformanceGetCell(col, row, true);\n proxy.updateCellGroupContent(cellGroup);\n }\n }\n // right frozen group\n for (let col = proxy.table.colCount - proxy.table.rightFrozenColCount; col < proxy.table.colCount; col++) {\n for (let row = syncTopRow; row <= syncBottomRow; row++) {\n // const cellGroup = proxy.table.scenegraph.getCell(col, row);\n const cellGroup = proxy.highPerformanceGetCell(col, row);\n proxy.updateCellGroupContent(cellGroup);\n }\n }\n // body group\n for (let col = proxy.bodyLeftCol; col <= proxy.bodyRightCol; col++) {\n for (let row = syncTopRow; row <= syncBottomRow; row++) {\n // const cellGroup = proxy.table.scenegraph.getCell(col, row);\n const cellGroup = proxy.highPerformanceGetCell(col, row);\n proxy.updateCellGroupContent(cellGroup);\n }\n }\n proxy.table.scenegraph.updateNextFrame();\n}\n"]}
|
|
@@ -401,6 +401,8 @@ export interface BaseTableAPI {
|
|
|
401
401
|
rowEnd: number;
|
|
402
402
|
};
|
|
403
403
|
hasCustomRenderOrLayout: () => boolean;
|
|
404
|
+
getBodyIndexByTableIndex: (col: number, row: number) => CellAddress;
|
|
405
|
+
getTableIndexByBodyIndex: (col: number, row: number) => CellAddress;
|
|
404
406
|
}
|
|
405
407
|
export interface ListTableProtected extends IBaseTableProtected {
|
|
406
408
|
records: any[] | null;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/ts-types/base-table.ts"],"names":[],"mappings":"","file":"base-table.js","sourcesContent":["import type { ITextSize } from '@visactor/vutils';\nimport type { RectProps, MaybePromiseOrUndefined, ICellHeaderPaths, CellInfo } from './common';\nimport type {\n TableEventListener,\n TableEventHandlersEventArgumentMap,\n TableEventHandlersReturnMap,\n EventListenerId,\n MousePointerCellEvent\n} from './events';\nimport type { MenuListItem, DropDownMenuEventInfo, DropDownMenuHighlightInfo } from './menu';\nimport type { CellStyle } from './style-define';\nimport type { ColumnIconOption } from './icon';\nimport type { ColumnData, ColumnDefine, ColumnsDefine, HeaderData, IndicatorData } from './list-table/layout-map/api';\nexport type { HeaderData } from './list-table/layout-map/api';\nimport type { TableTheme } from '../themes/theme';\nimport type { ICustomRender } from './customElement';\nexport type LayoutObjectId = number | string;\nimport type { Rect } from '../tools/Rect';\nimport type { Scenegraph } from '../scenegraph/scenegraph';\nimport type { StateManager } from '../state/state';\nimport type { EventManager } from '../event/event';\nimport type {\n CellAddress,\n CellRange,\n CellLocation,\n ColumnTypeOption,\n DataSourceAPI,\n FieldData,\n FieldDef,\n FieldFormat,\n FullExtendStyle,\n HeaderValues,\n HeightModeDef,\n HierarchyState,\n IDataConfig,\n IPagination,\n ITableThemeDefine,\n SortState,\n TableKeyboardOptions,\n WidthModeDef,\n IHeaderTreeDefine,\n IDimension,\n IIndicator,\n StickCell,\n CustomMergeCell,\n CustomMerge,\n IColumnDimension,\n IRowDimension\n} from '.';\nimport type { TooltipOptions } from './tooltip';\nimport type { IWrapTextGraphicAttribute } from '../scenegraph/graphic/text';\nimport type { ICustomLayout } from './customLayout';\nimport type { CachedDataSource, DataSource } from '../data';\nimport type { MenuHandler } from '../components/menu/dom/MenuHandler';\nimport type { PivotHeaderLayoutMap } from '../layout/pivot-header-layout';\nimport type { SimpleHeaderLayoutMap } from '../layout';\nimport type { TooltipHandler } from '../components/tooltip/TooltipHandler';\nimport type { BodyHelper } from '../body-helper/body-helper';\nimport type { HeaderHelper } from '../header-helper/header-helper';\nimport type { EventHandler } from '../event/EventHandler';\nimport type { NumberMap } from '../tools/NumberMap';\nimport type { FocusInput } from '../core/FouseInput';\nimport type { ITableLegendOption } from './component/legend';\nimport type { DataSet } from '@visactor/vdataset';\nimport type { Title } from '../components/title/title';\nimport type { ITitle } from './component/title';\nimport type { DiscreteTableLegend } from '../components/legend/discrete-legend/discrete-legend';\nimport type { ContinueTableLegend } from '../components/legend/continue-legend/continue-legend';\n\nexport interface IBaseTableProtected {\n element: HTMLElement;\n // scrollable: Scrollable;\n handler: EventHandler;\n focusControl: FocusInput;\n canvas: HTMLCanvasElement;\n context: CanvasRenderingContext2D;\n rowCount: number;\n colCount: number;\n frozenColCount: number;\n allowFrozenColCount: number;\n\n frozenRowCount: number;\n rightFrozenColCount: number;\n bottomFrozenRowCount: number;\n defaultRowHeight: number;\n /**表头默认行高 可以按逐行设置 如果没有就取defaultRowHeight */\n defaultHeaderRowHeight: (number | 'auto') | (number | 'auto')[];\n defaultColWidth: number;\n defaultHeaderColWidth: (number | 'auto') | (number | 'auto')[];\n // font?: string;\n // underlayBackgroundColor?: string;\n keyboardOptions?: TableKeyboardOptions;\n\n // disableRowHeaderColumnResize?: boolean;\n // 列宽调整模式(全列调整;全列不可调整;仅表头单元格可调整;仅内容单元格可调整)\n columnResizeMode?: 'all' | 'none' | 'header' | 'body';\n columnResizeType?: 'column' | 'indicator' | 'all' | 'indicatorGroup';\n /** 控制拖拽表头移动位置顺序开关 */\n dragHeaderMode?: 'all' | 'none' | 'column' | 'row';\n\n cachedRecordsRowHeightMap: NumberMap<string | number>; //存储每一条记录对应行的行高,只有当设置为自动换行随内容撑开才会起作用\n // headerRowHeightsMap: NumberMap<number>; //目前是用来存储了表头各行的高度,从headerRowHeight计算而来,headerRowHeight可以设置为数组的形式\n _rowHeightsMap: NumberMap<number>; //存储数据条目每行高度\n _colWidthsMap: NumberMap<string | number>; //存储各列的宽度\n _colContentWidthsMap: NumberMap<string | number>; //存储各列的内容宽度\n _colWidthsLimit: {\n //存储各列的宽度限制\n [col: number]: {\n max?: string | number;\n min?: string | number;\n };\n };\n calcWidthContext: {\n _: IBaseTableProtected;\n full: number;\n // em: number;\n };\n\n _rowRangeHeightsMap: Map<string, number>; //存储指定行范围的总高度\n _colRangeWidthsMap: Map<string, number>; //存储指定列范围的总宽度\n\n _widthResizedColMap: Set<number>; //记录下被手动调整过列宽的列号\n\n bodyHelper: BodyHelper;\n headerHelper: HeaderHelper;\n\n cellTextOverflows: { [at: string]: string };\n // headerDescriptions: { [at: string]: string };\n focusedTable: boolean;\n\n config:\n | {\n [name: string]: any;\n }\n | undefined;\n // scroll: {\n // left: number;\n // top: number;\n // };\n releaseList?: { release: () => void }[] | null;\n theme: TableTheme;\n transpose?: boolean; //是否转置\n // autoRowHeight?: boolean; //是否自动撑开高度 对于设置了autoWrapText的multilineText的列生效\n pixelRatio?: number;\n /** 下拉菜单的相关配置。消失时机:显示后点击菜单区域外自动消失*/\n menu: {\n /** 代替原来的option.menuType */\n renderMode?: 'canvas' | 'html';\n /** 内置下拉菜单的全局设置项 目前只针对基本表格有效 会对每个表头单元格开启默认的下拉菜单功能。代替原来的option.dropDownMenu*/\n defaultHeaderMenuItems?: MenuListItem[];\n /** 右键菜单。代替原来的option.contextmenu */\n contextMenuItems?: MenuListItem[] | ((field: FieldDef, row: number) => MenuListItem[]);\n /** 设置选中状态的菜单。代替原来的option.dropDownMenuHighlight */\n dropDownMenuHighlight?: DropDownMenuHighlightInfo[];\n };\n /** 提示弹框的相关配置。消失时机:显示后鼠标移动到指定区域外或者进入新的单元格后自动消失*/\n tooltip: {\n renderMode: 'html' | 'canvas';\n /** 代替原来hover:isShowTooltip配置 */\n isShowOverflowTextTooltip: boolean;\n /** 弹框是否需要限定在表格区域内 */\n confine: boolean;\n };\n\n dataSourceEventIds?: EventListenerId[];\n // headerEvents?: EventListenerId[];\n layoutMap: SimpleHeaderLayoutMap | PivotHeaderLayoutMap;\n headerValues?: HeaderValues;\n tooltipHandler: TooltipHandler;\n\n // headerRowHeight: number[] | number;//移到了BaseTable\n sortState: SortState | SortState[];\n\n dataSource: DataSource | CachedDataSource;\n records?: any;\n allowRangePaste: boolean;\n //重新思考逻辑:如果为false,行高按设置的rowHeight;如果设置为true,则按lineHeight及是否自动换行综合计算行高 2021.11.19 by:lff\n\n autoWrapText?: boolean;\n\n menuHandler: MenuHandler;\n\n /**\n * 计算列宽时 指定最大列宽 可设置boolean或者具体的值 默认为450\n */\n limitMaxAutoWidth?: boolean | number;\n\n /**\n * 限制列宽最小值。\n */\n limitMinWidth?: number;\n\n title?: Title;\n legends?: DiscreteTableLegend | ContinueTableLegend;\n\n //是否开启图表异步渲染\n renderChartAsync?: boolean;\n // // 开启图表异步渲染 每批次渐进渲染图表个数\n // renderChartAsyncBatchCount?: number;\n\n stick: { changedCells: StickCell[] };\n\n customMergeCell?: CustomMergeCell;\n /**\n * 'auto':和浏览器滚动行为一致 表格滚动到顶部/底部时 触发浏览器默认行为;\n * 设置为 'none' 时, 表格滚动到顶部/底部时, 不再触发父容器滚动\n * */\n overscrollBehavior?: 'auto' | 'none';\n}\nexport interface BaseTableConstructorOptions {\n // /** 指定表格的行数 */\n // rowCount?: number;\n\n // /** 指定表格的列数 */\n // colCount?: number;\n /**\n * 当前需要冻结的列数 基本表格生效\n */\n frozenColCount?: number;\n rightFrozenColCount?: number;\n bottomFrozenRowCount?: number;\n\n // /** 待实现 TODO */\n // frozenRowCount?: number;\n /** 可冻结列数,表示前多少列会出现冻结操作按钮 基本表格生效 */\n allowFrozenColCount?: number;\n /**\n * 默认行高. 默认 40\n */\n defaultRowHeight?: number;\n /** 列表头默认行高 可以按逐行设置 如果没有就取defaultRowHeight */\n defaultHeaderRowHeight?: (number | 'auto') | (number | 'auto')[];\n /**\n * 默认列宽. 默认 80\n */\n defaultColWidth?: number;\n /** 行表头默认列宽 可以按逐列设置 如果没有就取defaultColWidth */\n defaultHeaderColWidth?: (number | 'auto') | (number | 'auto')[];\n /** 快捷键功能设置 */\n keyboardOptions?: TableKeyboardOptions;\n /**\n * Canvas container\n */\n container?: HTMLElement | null;\n\n /**\n * 调整列宽 可操作范围。'all' | 'none' | 'header' | 'body'; 整列间隔线|禁止调整|只能在表头处间隔线|只能在body间隔线\n */\n columnResizeMode?: 'all' | 'none' | 'header' | 'body';\n /** 控制拖拽表头移动位置顺序开关 */\n dragHeaderMode?: 'all' | 'none' | 'column' | 'row';\n /**\n * 是否显示固定列图钉 基本表格生效\n */\n showFrozenIcon?: boolean;\n\n padding?:\n | {\n top?: number;\n bottom?: number;\n left?: number;\n right?: number;\n }\n | number;\n /** hover交互配置 */\n hover?: {\n /** hover交互响应模式:十字交叉 整列 整行 或者单个单元格 */\n highlightMode: 'cross' | 'column' | 'row' | 'cell';\n /** 不响应鼠标hover交互 */\n disableHover?: boolean;\n /** 单独设置表头不响应鼠标hover交互 */\n disableHeaderHover?: boolean;\n /** 单独设置坐标轴不响应鼠标hover交互 */\n disableAxisHover?: boolean;\n };\n /** 选择单元格交互配置 */\n select?: {\n /** 点击表头单元格时连带body整行或整列选中 或仅选中当前单元格,默认或整行或整列选中*/\n headerSelectMode?: 'inline' | 'cell';\n /** 不响应鼠标select交互 */\n disableSelect?: boolean;\n /** 单独设置表头不响应鼠标select交互 */\n disableHeaderSelect?: boolean;\n };\n /** 下拉菜单的相关配置。消失时机:显示后点击菜单区域外自动消失*/\n menu?: {\n /** 代替原来的option.menuType html目前实现较完整 先默认html渲染方式*/\n renderMode?: 'canvas' | 'html';\n /** 内置下拉菜单的全局设置项 目前只针对基本表格有效 会对每个表头单元格开启默认的下拉菜单功能。代替原来的option.dropDownMenu*/\n defaultHeaderMenuItems?: MenuListItem[];\n /** 右键菜单。代替原来的option.contextmenu */\n contextMenuItems?: MenuListItem[] | ((field: string, row: number) => MenuListItem[]);\n /** 设置选中状态的菜单。代替原来的option.dropDownMenuHighlight */\n dropDownMenuHighlight?: DropDownMenuHighlightInfo[];\n };\n /** tooltip相关配置 */\n tooltip?: {\n /** html目前实现较完整 先默认html渲染方式 */\n renderMode?: 'html'; // 目前暂不支持canvas方案\n /** 代替原来hover:isShowTooltip配置 暂时需要将renderMode配置为html才能显示,canvas的还未开发*/\n isShowOverflowTextTooltip?: boolean;\n /** 是否将 tooltip 框限制在画布区域内,默认开启。针对renderMode:\"html\"有效 */\n confine?: boolean;\n };\n /**\n * Theme\n */\n theme?: ITableThemeDefine;\n /** 宽度模式 */\n widthMode?: 'standard' | 'adaptive' | 'autoWidth';\n /** 高度模式 */\n heightMode?: 'standard' | 'adaptive' | 'autoHeight';\n /** 当列宽度不能占满容器时,是否需要自动拉宽来填充容器的宽度。默认false */\n autoFillWidth?: boolean;\n /** 当行高度不能占满容器时,是否需要自动拉高来填充容器的高度。默认false */\n autoFillHeight?: boolean;\n // /** 行高是否根据内容来计算 */\n // autoRowHeight?: boolean;\n /** 设备的像素比 不配的话默认获取window.devicePixelRatio */\n pixelRatio?: number;\n /** 自定义渲染 函数形式*/\n customRender?: ICustomRender;\n /** 开启自动换行 默认false */\n autoWrapText?: boolean;\n /** 单元格中可显示最大字符数 默认200 */\n maxCharactersNumber?: number; //\n // /** toolip最大字符数 */\n // maxTooltipCharactersNumber?: number;\n /** 最大可操作条目数 如copy操作可复制出最大数据条目数 */\n maxOperatableRecordCount?: number;\n /**\n * 计算列宽时 指定最大列宽 可设置boolean或者具体的值 默认为450。手动拖拽列宽的话不收这个限制\n */\n limitMaxAutoWidth?: boolean | number;\n /**\n * 限制列宽最小值。如设置为true 则拖拽改变列宽时限制列宽最小为10px,设置为false则不进行限制。默认为10px\n */\n limitMinWidth?: boolean | number;\n\n // maximum number of data items maintained in table instance\n maintainedDataCount?: number;\n\n legends?: ITableLegendOption;\n title?: ITitle;\n\n /** 是否开启图表异步渲染 */\n renderChartAsync?: boolean;\n /** 开启图表异步渲染 每批次渐进渲染图表个数 默认是5个 */\n renderChartAsyncBatchCount?: number;\n\n customMergeCell?: CustomMergeCell;\n\n // for nodejs\n mode?: 'node' | 'broswer';\n modeParams?: any;\n canvasWidth?: number;\n canvasHeight?: number;\n /**\n * 'auto':和浏览器滚动行为一致 表格滚动到顶部/底部时 触发浏览器默认行为;\n * 设置为 'none' 时, 表格滚动到顶部/底部时, 不再触发父容器滚动\n * */\n overscrollBehavior?: 'auto' | 'none';\n\n // resize response time\n resizeTime?: number;\n}\nexport interface BaseTableAPI {\n /** 表格的行数 */\n rowCount: number;\n /** 表格的列数 */\n colCount: number;\n /** 表格除去外层frame后的宽度 */\n tableNoFrameWidth: number;\n /** 表格除去外层frame后的高度 */\n tableNoFrameHeight: number;\n /** 表格的冻结行数 包括表头在内 */\n frozenRowCount: number;\n /** 表格的冻结列数 包括表头在内 */\n frozenColCount: number;\n\n bottomFrozenRowCount: number;\n rightFrozenColCount: number;\n /** 当前表格默认表头行高 */\n defaultHeaderRowHeight: (number | 'auto') | (number | 'auto')[];\n /** 当前表格默认行高 */\n defaultRowHeight: number;\n /** 当前表格默认列宽 */\n defaultColWidth: number;\n /** 当前表格默认表头列宽 */\n defaultHeaderColWidth: (number | 'auto') | (number | 'auto')[];\n /** 当前表格快捷键设置 */\n keyboardOptions: TableKeyboardOptions | null;\n /**\n * 是否显示图钉\n */\n showFrozenIcon: boolean;\n readonly canvas: HTMLCanvasElement;\n /** 表格可视区域的行数 */\n readonly visibleRowCount: number;\n /** 表格可视区域的列数 */\n readonly visibleColCount: number;\n /** 表格滚动值left */\n scrollLeft: number;\n /** 表格滚动值top */\n scrollTop: number;\n /** 用户设置的options 不要修改这个这个 */\n options: BaseTableConstructorOptions;\n /** 设置的全局下拉菜单列表项配置 */\n globalDropDownMenu?: MenuListItem[];\n /** 设置的全局自定义渲染函数 */\n customRender?: ICustomRender;\n\n /** 表格数据管理对象 */\n dataSource: DataSourceAPI;\n /** 设置的表格主题 */\n theme: TableTheme;\n /** 可允许设置冻结的最大列数 */\n allowFrozenColCount: number;\n\n /** 存储内部用到的属性 变量等 */\n internalProps: IBaseTableProtected;\n /** 分页信息 */\n pagination?: IPagination;\n\n /** 表格偏移像素值 水平方向 */\n tableX: number;\n /** 表格偏移像素值 垂直方向 */\n tableY: number;\n /** 表格宽度模式 */\n widthMode: WidthModeDef;\n /** 表格宽度模式 */\n heightMode: HeightModeDef;\n /** 当列宽度不能占满容器时,是否需要自动拉宽来填充容器的宽度。默认false */\n autoFillWidth: boolean;\n /** 当行高度不能占满容器时,是否需要自动拉高来填充容器的高度。默认false */\n autoFillHeight?: boolean;\n\n isReleased: boolean;\n\n rowHeightsMap: NumberMap<number>;\n colWidthsMap: NumberMap<string | number>;\n\n on: <TYPE extends keyof TableEventHandlersEventArgumentMap>(\n type: TYPE,\n listener: TableEventListener<TYPE> //(event: TableEventHandlersEventArgumentMap[TYPE]) => TableEventHandlersReturnMap[TYPE]\n ) => EventListenerId;\n // &(<T extends keyof TableEventHandlersEventArgumentMap>(type: string, listener: AnyListener<T>) => EventListenerId);\n\n _vDataSet: DataSet;\n /** 场景树对象 */\n scenegraph: Scenegraph;\n /** 状态管理模块 */\n stateManager?: StateManager;\n /** 事件管理模块 */\n eventManager?: EventManager;\n /** 行表头的层数 */\n rowHeaderLevelCount: number;\n /** 列表头的层数 */\n columnHeaderLevelCount: number;\n\n canvasWidth?: number;\n canvasHeight?: number;\n\n /** 获取表格绘制的范围 不包括frame的宽度 */\n getDrawRange: () => Rect;\n /** 将鼠标坐标值 转换成表格坐标系中的坐标位置 */\n _getMouseAbstractPoint: (\n evt: TouchEvent | MouseEvent | undefined,\n isAddScroll?: boolean\n ) => { x: number; y: number; inTable: boolean };\n getElement: () => HTMLElement;\n getContainer: () => HTMLElement;\n\n setFrozenColCount: (count: number) => void;\n _setFrozenColCount: (count: number) => void;\n _updateSize: () => void;\n\n render: () => void;\n throttleInvalidate: () => void;\n getRowHeight: (row: number) => number;\n getDefaultRowHeight: (row: number) => number | 'auto';\n _setRowHeight: (row: number, height: number, clearCache?: boolean) => void;\n getColWidth: (col: number) => number;\n getColWidthDefined: (col: number) => string | number;\n // setColWidthDefined: (col: number, width: number) => void;\n getColWidthDefinedNumber: (col: number) => number;\n // getColWidthDefine: (col: number) => string | number;\n _setColWidth: (col: number, width: number | string, clearCache?: boolean, skipCheckFrozen?: boolean) => void;\n _getColContentWidth: (col: number) => number;\n _setColContentWidth: (col: number, width: number | string, clearCache?: boolean) => void;\n getMaxColWidth: (col: number) => number;\n setMaxColWidth: (col: number, maxwidth: string | number) => void;\n getMinColWidth: (col: number) => number;\n setMinColWidth: (col: number, minwidth: string | number) => void;\n getCellRect: (col: number, row: number) => RectProps;\n getCellRelativeRect: (col: number, row: number) => RectProps;\n getCellsRect: (startCol: number, startRow: number, endCol: number, endRow: number) => RectProps;\n getCellRangeRect: (cellRange: CellRange | CellAddress) => RectProps;\n getCellRangeRelativeRect: (cellRange: CellRange | CellAddress) => RectProps;\n getVisibleCellRangeRelativeRect: (cellRange: CellRange | CellAddress) => RectProps;\n isFrozenCell: (col: number, row: number) => { row: boolean; col: boolean } | null;\n getRowAt: (absoluteY: number) => { top: number; row: number; bottom: number };\n getColAt: (absoluteX: number) => { left: number; col: number; right: number };\n getCellAt: (absoluteX: number, absoluteY: number) => CellAddress;\n _makeVisibleCell: (col: number, row: number) => void;\n // setFocusCursor(col: number, row: number): void;\n // focusCell(col: number, row: number): void;\n getCellOverflowText: (col: number, row: number) => string | null;\n getColsWidth: (startCol: number, endCol: number) => number;\n getRowsHeight: (startRow: number, endRow: number) => number;\n\n release: () => void;\n addReleaseObj: (releaseObj: { release: () => void }) => void;\n _getCellStyle: (col: number, row: number) => FullExtendStyle;\n clearCellStyleCache: () => void;\n\n getFrozenRowsHeight: () => number;\n getFrozenColsWidth: () => number;\n getBottomFrozenRowsHeight: () => number;\n getRightFrozenColsWidth: () => number;\n selectCell: (col: number, row: number) => void;\n selectCells: (cellRanges: CellRange[]) => void;\n getAllRowsHeight: () => number;\n getAllColsWidth: () => number;\n\n off: (id: EventListenerId) => void;\n getBodyField: (col: number, row: number) => FieldDef | undefined;\n /**\n * 根据单元格获取对应的源数据\n * @param col\n * @param row\n * @returns\n */\n getRecordByCell: (col: number, row: number) => MaybePromiseOrUndefined;\n /**\n * 根据数据源的index 获取显示到表格中的index 行号或者列号(与转置相关)。注:ListTable特有接口\n * @param recordIndex\n */\n getTableIndexByRecordIndex: (recordIndex: number) => number;\n /**\n * 根据数据源的field 获取显示到表格中的index 行号或者列号(与转置相关)。注:ListTable特有接口\n * @param recordIndex\n */\n getTableIndexByField: (field: FieldDef) => number;\n /**\n * 根据数据源中的index和field获取单元格行列号。注:ListTable特有接口\n * @param field\n * @param recordIndex\n * @returns\n */\n getCellAddrByFieldRecord: (field: FieldDef, recordIndex: number) => CellAddress;\n getRecordShowIndexByCell: (col: number, row: number) => number;\n getRecordStartRowByRecordIndex: (index: number) => number;\n\n getHeaderField: (col: number, row: number) => any | undefined;\n getHeaderFieldKey: (col: number, row: number) => any | undefined;\n\n _getHeaderCellBySortState: (sortState: SortState) => CellAddress | undefined;\n getHeaderDefine: (col: number, row: number) => ColumnDefine;\n _getHeaderLayoutMap: (col: number, row: number) => HeaderData;\n getContext: () => CanvasRenderingContext2D;\n getCellRange: (col: number, row: number) => CellRange;\n _resetFrozenColCount: () => void;\n isCellRangeEqual: (col: number, row: number, targetCol: number, targetRow: number) => boolean;\n _getLayoutCellId: (col: number, row: number) => LayoutObjectId;\n _getBodyLayoutMap: (col: number, row: number) => ColumnData | IndicatorData;\n getBodyColumnDefine: (col: number, row: number) => ColumnDefine;\n getBodyColumnType: (col: number, row: number) => ColumnTypeOption;\n getCellType: (col: number, row: number) => ColumnTypeOption;\n fireListeners: <TYPE extends keyof TableEventHandlersEventArgumentMap>(\n type: TYPE,\n event: TableEventHandlersEventArgumentMap[TYPE]\n ) => TableEventHandlersReturnMap[TYPE][];\n\n //更新分页\n updatePagination: (cof: IPagination) => void;\n //hover\n\n getHeaderDescription: (col: number, row: number) => string | undefined;\n /** 获取单元格展示值 */\n getCellValue: (col: number, row: number) => string | null;\n /** 获取单元格展示数据的format前的值 */\n getCellOriginValue: (col: number, row: number) => any;\n /** 获取单元格展示数据源最原始值 */\n getCellRawValue: (col: number, row: number) => FieldData;\n /** 获取单元格展示数据的format前的record源数据 */\n getCellOriginRecord: (col: number, row: number) => MaybePromiseOrUndefined;\n /** 获取单元格展示源数据 */\n getCellRawRecord: (col: number, row: number) => MaybePromiseOrUndefined;\n\n _dropDownMenuIsHighlight: (col: number, row: number, index: number) => boolean;\n // bindEvents(): void;\n refreshRowColCount: () => void;\n // getFieldData: (field: FieldDef | FieldFormat | undefined, col: number, row: number) => FieldData;\n _hasField: (field: FieldDef, col: number, row: number) => boolean;\n getCellHeaderPaths: (col: number, row: number) => ICellHeaderPaths;\n getCellLocation: (col: number, row: number) => CellLocation;\n // isHitIcon(col: number, row: number, x: number, y: number, iconType: IconFuncTypeEnum): boolean;\n getCellIcons: (col: number, row: number) => ColumnIconOption[];\n\n getMenuInfo: (col: number, row: number, type: string) => DropDownMenuEventInfo;\n /**\n * 获取某个单元格的样式 共业务方调用\n * @param col\n * @param row\n */\n getCellStyle: (col: number, row: number) => CellStyle; // 计算后style\n\n getHierarchyState: (col: number, row: number) => HierarchyState | null;\n\n _hasHierarchyTreeHeader: () => boolean;\n\n _canDragHeaderPosition: (col: number, row: number) => boolean;\n\n isHeader: (col: number, row: number) => boolean;\n\n isColumnHeader: (col: number, row: number) => boolean;\n\n isCornerHeader: (col: number, row: number) => boolean;\n\n isRowHeader: (col: number, row: number) => boolean;\n\n getCopyValue: () => string;\n\n getSelectedCellInfos: () => CellInfo[][];\n getCellInfo: (col: number, row: number) => Omit<MousePointerCellEvent, 'target'>;\n\n showTooltip: (col: number, row: number, tooltipOptions?: TooltipOptions) => void;\n\n measureText: (\n text: string,\n font: { fontSize: number; fontWeight?: string | number; fontFamily: string }\n ) => ITextSize;\n\n _canResizeColumn: (col: number, row: number) => boolean;\n\n getCustomRender: (col: number, row: number) => ICustomRender;\n getCustomLayout: (col: number, row: number) => ICustomLayout;\n isListTable: () => boolean;\n isPivotTable: (() => boolean) & (() => boolean);\n isPivotChart: (() => boolean) & (() => boolean);\n _clearColRangeWidthsMap: (col?: number) => void;\n _clearRowRangeHeightsMap: (row?: number) => void;\n clearRowHeightCache: () => void;\n clearColWidthCache: () => void;\n toggleHierarchyState: (col: number, row: number) => void;\n\n resize: () => void;\n\n getMergeCellRect: (col: number, row: number) => Rect;\n\n getTargetColAt: (absoluteX: number) => { col: number; left: number; right: number; width: number } | null;\n getTargetRowAt: (absoluteY: number) => { row: number; top: number; bottom: number; height: number } | null;\n\n renderWithRecreateCells: () => void;\n //#endregion tableAPI\n\n _adjustColWidth: (col: number, orgWidth: number) => number;\n _colWidthDefineToPxWidth: (width: string | number) => number;\n isFrozenColumn: (col: number, row?: number) => boolean;\n isLeftFrozenColumn: (col: number, row?: number) => boolean;\n isRightFrozenColumn: (col: number, row?: number) => boolean;\n isFrozenRow: (col: number, row?: number) => boolean;\n isTopFrozenRow: (col: number, row?: number) => boolean;\n isBottomFrozenRow: (col: number, row?: number) => boolean;\n\n getCustomMerge: (col: number, row: number) => undefined | (Omit<CustomMerge, 'style'> & { style?: FullExtendStyle });\n /** 获取表格body部分的显示单元格范围 */\n getBodyVisibleCellRange: () => { rowStart: number; colStart: number; rowEnd: number; colEnd: number };\n /** 获取表格body部分的显示列号范围 */\n getBodyVisibleColRange: () => { colStart: number; colEnd: number };\n /** 获取表格body部分的显示行号范围 */\n getBodyVisibleRowRange: () => { rowStart: number; rowEnd: number };\n\n hasCustomRenderOrLayout: () => boolean;\n}\nexport interface ListTableProtected extends IBaseTableProtected {\n /** 表格数据 */\n records: any[] | null;\n columns: ColumnsDefine;\n layoutMap: SimpleHeaderLayoutMap;\n}\n\nexport interface PivotTableProtected extends IBaseTableProtected {\n /** 表格数据 */\n records: any[] | null;\n layoutMap: PivotHeaderLayoutMap;\n dataConfig?: IDataConfig;\n /**\n * 透视表是否开启数据分析\n * 如果传入数据是明细数据需要聚合分析则开启\n * 如传入数据是经过聚合好的为了提升性能这里设置为false,同时需要传入columnTree和rowTree\n */\n enableDataAnalysis?: boolean;\n\n /** 列表头树型结构 */\n columnTree?: IHeaderTreeDefine[];\n /** 行表头树型结构 */\n rowTree?: IHeaderTreeDefine[];\n /** 定义行上各个维度具体配置项和样式定义 */\n rows?: (IRowDimension | string)[]; // (string | IDimension)[]; 后续支持数据分析的透视表 支持string配置\n /** 定义列上各个维度具体配置项和样式定义 */\n columns?: (IColumnDimension | string)[]; // (string | IDimension)[];\n /** 定义指标具体配置项和样式定义 包含表头和body的定义*/\n indicators?: (IIndicator | string)[]; // (string | IIndicator)[];\n}\nexport interface PivotChartProtected extends IBaseTableProtected {\n /** 表格数据 */\n records: any[] | Record<string, any[]>;\n layoutMap: PivotHeaderLayoutMap;\n dataConfig?: IDataConfig;\n columnTree?: IHeaderTreeDefine[];\n /** 行表头维度结构 */\n rowTree?: IHeaderTreeDefine[];\n /** 定义行上各个维度具体配置项和样式定义 */\n rows?: (IRowDimension | string)[]; // (string | IDimension)[]; 后续支持数据分析的透视表 支持string配置\n /** 定义列上各个维度具体配置项和样式定义 */\n columns?: (IColumnDimension | string)[]; // (string | IDimension)[];\n /** 定义指标具体配置项和样式定义 包含表头和body的定义*/\n indicators?: (IIndicator | string)[]; // (string | IIndicator)[];\n}\n"]}
|
|
1
|
+
{"version":3,"sources":["../src/ts-types/base-table.ts"],"names":[],"mappings":"","file":"base-table.js","sourcesContent":["import type { ITextSize } from '@visactor/vutils';\nimport type { RectProps, MaybePromiseOrUndefined, ICellHeaderPaths, CellInfo } from './common';\nimport type {\n TableEventListener,\n TableEventHandlersEventArgumentMap,\n TableEventHandlersReturnMap,\n EventListenerId,\n MousePointerCellEvent\n} from './events';\nimport type { MenuListItem, DropDownMenuEventInfo, DropDownMenuHighlightInfo } from './menu';\nimport type { CellStyle } from './style-define';\nimport type { ColumnIconOption } from './icon';\nimport type { ColumnData, ColumnDefine, ColumnsDefine, HeaderData, IndicatorData } from './list-table/layout-map/api';\nexport type { HeaderData } from './list-table/layout-map/api';\nimport type { TableTheme } from '../themes/theme';\nimport type { ICustomRender } from './customElement';\nexport type LayoutObjectId = number | string;\nimport type { Rect } from '../tools/Rect';\nimport type { Scenegraph } from '../scenegraph/scenegraph';\nimport type { StateManager } from '../state/state';\nimport type { EventManager } from '../event/event';\nimport type {\n CellAddress,\n CellRange,\n CellLocation,\n ColumnTypeOption,\n DataSourceAPI,\n FieldData,\n FieldDef,\n FieldFormat,\n FullExtendStyle,\n HeaderValues,\n HeightModeDef,\n HierarchyState,\n IDataConfig,\n IPagination,\n ITableThemeDefine,\n SortState,\n TableKeyboardOptions,\n WidthModeDef,\n IHeaderTreeDefine,\n IDimension,\n IIndicator,\n StickCell,\n CustomMergeCell,\n CustomMerge,\n IColumnDimension,\n IRowDimension\n} from '.';\nimport type { TooltipOptions } from './tooltip';\nimport type { IWrapTextGraphicAttribute } from '../scenegraph/graphic/text';\nimport type { ICustomLayout } from './customLayout';\nimport type { CachedDataSource, DataSource } from '../data';\nimport type { MenuHandler } from '../components/menu/dom/MenuHandler';\nimport type { PivotHeaderLayoutMap } from '../layout/pivot-header-layout';\nimport type { SimpleHeaderLayoutMap } from '../layout';\nimport type { TooltipHandler } from '../components/tooltip/TooltipHandler';\nimport type { BodyHelper } from '../body-helper/body-helper';\nimport type { HeaderHelper } from '../header-helper/header-helper';\nimport type { EventHandler } from '../event/EventHandler';\nimport type { NumberMap } from '../tools/NumberMap';\nimport type { FocusInput } from '../core/FouseInput';\nimport type { ITableLegendOption } from './component/legend';\nimport type { DataSet } from '@visactor/vdataset';\nimport type { Title } from '../components/title/title';\nimport type { ITitle } from './component/title';\nimport type { DiscreteTableLegend } from '../components/legend/discrete-legend/discrete-legend';\nimport type { ContinueTableLegend } from '../components/legend/continue-legend/continue-legend';\n\nexport interface IBaseTableProtected {\n element: HTMLElement;\n // scrollable: Scrollable;\n handler: EventHandler;\n focusControl: FocusInput;\n canvas: HTMLCanvasElement;\n context: CanvasRenderingContext2D;\n rowCount: number;\n colCount: number;\n frozenColCount: number;\n allowFrozenColCount: number;\n\n frozenRowCount: number;\n rightFrozenColCount: number;\n bottomFrozenRowCount: number;\n defaultRowHeight: number;\n /**表头默认行高 可以按逐行设置 如果没有就取defaultRowHeight */\n defaultHeaderRowHeight: (number | 'auto') | (number | 'auto')[];\n defaultColWidth: number;\n defaultHeaderColWidth: (number | 'auto') | (number | 'auto')[];\n // font?: string;\n // underlayBackgroundColor?: string;\n keyboardOptions?: TableKeyboardOptions;\n\n // disableRowHeaderColumnResize?: boolean;\n // 列宽调整模式(全列调整;全列不可调整;仅表头单元格可调整;仅内容单元格可调整)\n columnResizeMode?: 'all' | 'none' | 'header' | 'body';\n columnResizeType?: 'column' | 'indicator' | 'all' | 'indicatorGroup';\n /** 控制拖拽表头移动位置顺序开关 */\n dragHeaderMode?: 'all' | 'none' | 'column' | 'row';\n\n cachedRecordsRowHeightMap: NumberMap<string | number>; //存储每一条记录对应行的行高,只有当设置为自动换行随内容撑开才会起作用\n // headerRowHeightsMap: NumberMap<number>; //目前是用来存储了表头各行的高度,从headerRowHeight计算而来,headerRowHeight可以设置为数组的形式\n _rowHeightsMap: NumberMap<number>; //存储数据条目每行高度\n _colWidthsMap: NumberMap<string | number>; //存储各列的宽度\n _colContentWidthsMap: NumberMap<string | number>; //存储各列的内容宽度\n _colWidthsLimit: {\n //存储各列的宽度限制\n [col: number]: {\n max?: string | number;\n min?: string | number;\n };\n };\n calcWidthContext: {\n _: IBaseTableProtected;\n full: number;\n // em: number;\n };\n\n _rowRangeHeightsMap: Map<string, number>; //存储指定行范围的总高度\n _colRangeWidthsMap: Map<string, number>; //存储指定列范围的总宽度\n\n _widthResizedColMap: Set<number>; //记录下被手动调整过列宽的列号\n\n bodyHelper: BodyHelper;\n headerHelper: HeaderHelper;\n\n cellTextOverflows: { [at: string]: string };\n // headerDescriptions: { [at: string]: string };\n focusedTable: boolean;\n\n config:\n | {\n [name: string]: any;\n }\n | undefined;\n // scroll: {\n // left: number;\n // top: number;\n // };\n releaseList?: { release: () => void }[] | null;\n theme: TableTheme;\n transpose?: boolean; //是否转置\n // autoRowHeight?: boolean; //是否自动撑开高度 对于设置了autoWrapText的multilineText的列生效\n pixelRatio?: number;\n /** 下拉菜单的相关配置。消失时机:显示后点击菜单区域外自动消失*/\n menu: {\n /** 代替原来的option.menuType */\n renderMode?: 'canvas' | 'html';\n /** 内置下拉菜单的全局设置项 目前只针对基本表格有效 会对每个表头单元格开启默认的下拉菜单功能。代替原来的option.dropDownMenu*/\n defaultHeaderMenuItems?: MenuListItem[];\n /** 右键菜单。代替原来的option.contextmenu */\n contextMenuItems?: MenuListItem[] | ((field: FieldDef, row: number) => MenuListItem[]);\n /** 设置选中状态的菜单。代替原来的option.dropDownMenuHighlight */\n dropDownMenuHighlight?: DropDownMenuHighlightInfo[];\n };\n /** 提示弹框的相关配置。消失时机:显示后鼠标移动到指定区域外或者进入新的单元格后自动消失*/\n tooltip: {\n renderMode: 'html' | 'canvas';\n /** 代替原来hover:isShowTooltip配置 */\n isShowOverflowTextTooltip: boolean;\n /** 弹框是否需要限定在表格区域内 */\n confine: boolean;\n };\n\n dataSourceEventIds?: EventListenerId[];\n // headerEvents?: EventListenerId[];\n layoutMap: SimpleHeaderLayoutMap | PivotHeaderLayoutMap;\n headerValues?: HeaderValues;\n tooltipHandler: TooltipHandler;\n\n // headerRowHeight: number[] | number;//移到了BaseTable\n sortState: SortState | SortState[];\n\n dataSource: DataSource | CachedDataSource;\n records?: any;\n allowRangePaste: boolean;\n //重新思考逻辑:如果为false,行高按设置的rowHeight;如果设置为true,则按lineHeight及是否自动换行综合计算行高 2021.11.19 by:lff\n\n autoWrapText?: boolean;\n\n menuHandler: MenuHandler;\n\n /**\n * 计算列宽时 指定最大列宽 可设置boolean或者具体的值 默认为450\n */\n limitMaxAutoWidth?: boolean | number;\n\n /**\n * 限制列宽最小值。\n */\n limitMinWidth?: number;\n\n title?: Title;\n legends?: DiscreteTableLegend | ContinueTableLegend;\n\n //是否开启图表异步渲染\n renderChartAsync?: boolean;\n // // 开启图表异步渲染 每批次渐进渲染图表个数\n // renderChartAsyncBatchCount?: number;\n\n stick: { changedCells: StickCell[] };\n\n customMergeCell?: CustomMergeCell;\n /**\n * 'auto':和浏览器滚动行为一致 表格滚动到顶部/底部时 触发浏览器默认行为;\n * 设置为 'none' 时, 表格滚动到顶部/底部时, 不再触发父容器滚动\n * */\n overscrollBehavior?: 'auto' | 'none';\n}\nexport interface BaseTableConstructorOptions {\n // /** 指定表格的行数 */\n // rowCount?: number;\n\n // /** 指定表格的列数 */\n // colCount?: number;\n /**\n * 当前需要冻结的列数 基本表格生效\n */\n frozenColCount?: number;\n rightFrozenColCount?: number;\n bottomFrozenRowCount?: number;\n\n // /** 待实现 TODO */\n // frozenRowCount?: number;\n /** 可冻结列数,表示前多少列会出现冻结操作按钮 基本表格生效 */\n allowFrozenColCount?: number;\n /**\n * 默认行高. 默认 40\n */\n defaultRowHeight?: number;\n /** 列表头默认行高 可以按逐行设置 如果没有就取defaultRowHeight */\n defaultHeaderRowHeight?: (number | 'auto') | (number | 'auto')[];\n /**\n * 默认列宽. 默认 80\n */\n defaultColWidth?: number;\n /** 行表头默认列宽 可以按逐列设置 如果没有就取defaultColWidth */\n defaultHeaderColWidth?: (number | 'auto') | (number | 'auto')[];\n /** 快捷键功能设置 */\n keyboardOptions?: TableKeyboardOptions;\n /**\n * Canvas container\n */\n container?: HTMLElement | null;\n\n /**\n * 调整列宽 可操作范围。'all' | 'none' | 'header' | 'body'; 整列间隔线|禁止调整|只能在表头处间隔线|只能在body间隔线\n */\n columnResizeMode?: 'all' | 'none' | 'header' | 'body';\n /** 控制拖拽表头移动位置顺序开关 */\n dragHeaderMode?: 'all' | 'none' | 'column' | 'row';\n /**\n * 是否显示固定列图钉 基本表格生效\n */\n showFrozenIcon?: boolean;\n\n padding?:\n | {\n top?: number;\n bottom?: number;\n left?: number;\n right?: number;\n }\n | number;\n /** hover交互配置 */\n hover?: {\n /** hover交互响应模式:十字交叉 整列 整行 或者单个单元格 */\n highlightMode: 'cross' | 'column' | 'row' | 'cell';\n /** 不响应鼠标hover交互 */\n disableHover?: boolean;\n /** 单独设置表头不响应鼠标hover交互 */\n disableHeaderHover?: boolean;\n /** 单独设置坐标轴不响应鼠标hover交互 */\n disableAxisHover?: boolean;\n };\n /** 选择单元格交互配置 */\n select?: {\n /** 点击表头单元格时连带body整行或整列选中 或仅选中当前单元格,默认或整行或整列选中*/\n headerSelectMode?: 'inline' | 'cell';\n /** 不响应鼠标select交互 */\n disableSelect?: boolean;\n /** 单独设置表头不响应鼠标select交互 */\n disableHeaderSelect?: boolean;\n };\n /** 下拉菜单的相关配置。消失时机:显示后点击菜单区域外自动消失*/\n menu?: {\n /** 代替原来的option.menuType html目前实现较完整 先默认html渲染方式*/\n renderMode?: 'canvas' | 'html';\n /** 内置下拉菜单的全局设置项 目前只针对基本表格有效 会对每个表头单元格开启默认的下拉菜单功能。代替原来的option.dropDownMenu*/\n defaultHeaderMenuItems?: MenuListItem[];\n /** 右键菜单。代替原来的option.contextmenu */\n contextMenuItems?: MenuListItem[] | ((field: string, row: number) => MenuListItem[]);\n /** 设置选中状态的菜单。代替原来的option.dropDownMenuHighlight */\n dropDownMenuHighlight?: DropDownMenuHighlightInfo[];\n };\n /** tooltip相关配置 */\n tooltip?: {\n /** html目前实现较完整 先默认html渲染方式 */\n renderMode?: 'html'; // 目前暂不支持canvas方案\n /** 代替原来hover:isShowTooltip配置 暂时需要将renderMode配置为html才能显示,canvas的还未开发*/\n isShowOverflowTextTooltip?: boolean;\n /** 是否将 tooltip 框限制在画布区域内,默认开启。针对renderMode:\"html\"有效 */\n confine?: boolean;\n };\n /**\n * Theme\n */\n theme?: ITableThemeDefine;\n /** 宽度模式 */\n widthMode?: 'standard' | 'adaptive' | 'autoWidth';\n /** 高度模式 */\n heightMode?: 'standard' | 'adaptive' | 'autoHeight';\n /** 当列宽度不能占满容器时,是否需要自动拉宽来填充容器的宽度。默认false */\n autoFillWidth?: boolean;\n /** 当行高度不能占满容器时,是否需要自动拉高来填充容器的高度。默认false */\n autoFillHeight?: boolean;\n // /** 行高是否根据内容来计算 */\n // autoRowHeight?: boolean;\n /** 设备的像素比 不配的话默认获取window.devicePixelRatio */\n pixelRatio?: number;\n /** 自定义渲染 函数形式*/\n customRender?: ICustomRender;\n /** 开启自动换行 默认false */\n autoWrapText?: boolean;\n /** 单元格中可显示最大字符数 默认200 */\n maxCharactersNumber?: number; //\n // /** toolip最大字符数 */\n // maxTooltipCharactersNumber?: number;\n /** 最大可操作条目数 如copy操作可复制出最大数据条目数 */\n maxOperatableRecordCount?: number;\n /**\n * 计算列宽时 指定最大列宽 可设置boolean或者具体的值 默认为450。手动拖拽列宽的话不收这个限制\n */\n limitMaxAutoWidth?: boolean | number;\n /**\n * 限制列宽最小值。如设置为true 则拖拽改变列宽时限制列宽最小为10px,设置为false则不进行限制。默认为10px\n */\n limitMinWidth?: boolean | number;\n\n // maximum number of data items maintained in table instance\n maintainedDataCount?: number;\n\n legends?: ITableLegendOption;\n title?: ITitle;\n\n /** 是否开启图表异步渲染 */\n renderChartAsync?: boolean;\n /** 开启图表异步渲染 每批次渐进渲染图表个数 默认是5个 */\n renderChartAsyncBatchCount?: number;\n\n customMergeCell?: CustomMergeCell;\n\n // for nodejs\n mode?: 'node' | 'broswer';\n modeParams?: any;\n canvasWidth?: number;\n canvasHeight?: number;\n /**\n * 'auto':和浏览器滚动行为一致 表格滚动到顶部/底部时 触发浏览器默认行为;\n * 设置为 'none' 时, 表格滚动到顶部/底部时, 不再触发父容器滚动\n * */\n overscrollBehavior?: 'auto' | 'none';\n\n // resize response time\n resizeTime?: number;\n}\nexport interface BaseTableAPI {\n /** 表格的行数 */\n rowCount: number;\n /** 表格的列数 */\n colCount: number;\n /** 表格除去外层frame后的宽度 */\n tableNoFrameWidth: number;\n /** 表格除去外层frame后的高度 */\n tableNoFrameHeight: number;\n /** 表格的冻结行数 包括表头在内 */\n frozenRowCount: number;\n /** 表格的冻结列数 包括表头在内 */\n frozenColCount: number;\n\n bottomFrozenRowCount: number;\n rightFrozenColCount: number;\n /** 当前表格默认表头行高 */\n defaultHeaderRowHeight: (number | 'auto') | (number | 'auto')[];\n /** 当前表格默认行高 */\n defaultRowHeight: number;\n /** 当前表格默认列宽 */\n defaultColWidth: number;\n /** 当前表格默认表头列宽 */\n defaultHeaderColWidth: (number | 'auto') | (number | 'auto')[];\n /** 当前表格快捷键设置 */\n keyboardOptions: TableKeyboardOptions | null;\n /**\n * 是否显示图钉\n */\n showFrozenIcon: boolean;\n readonly canvas: HTMLCanvasElement;\n /** 表格可视区域的行数 */\n readonly visibleRowCount: number;\n /** 表格可视区域的列数 */\n readonly visibleColCount: number;\n /** 表格滚动值left */\n scrollLeft: number;\n /** 表格滚动值top */\n scrollTop: number;\n /** 用户设置的options 不要修改这个这个 */\n options: BaseTableConstructorOptions;\n /** 设置的全局下拉菜单列表项配置 */\n globalDropDownMenu?: MenuListItem[];\n /** 设置的全局自定义渲染函数 */\n customRender?: ICustomRender;\n\n /** 表格数据管理对象 */\n dataSource: DataSourceAPI;\n /** 设置的表格主题 */\n theme: TableTheme;\n /** 可允许设置冻结的最大列数 */\n allowFrozenColCount: number;\n\n /** 存储内部用到的属性 变量等 */\n internalProps: IBaseTableProtected;\n /** 分页信息 */\n pagination?: IPagination;\n\n /** 表格偏移像素值 水平方向 */\n tableX: number;\n /** 表格偏移像素值 垂直方向 */\n tableY: number;\n /** 表格宽度模式 */\n widthMode: WidthModeDef;\n /** 表格宽度模式 */\n heightMode: HeightModeDef;\n /** 当列宽度不能占满容器时,是否需要自动拉宽来填充容器的宽度。默认false */\n autoFillWidth: boolean;\n /** 当行高度不能占满容器时,是否需要自动拉高来填充容器的高度。默认false */\n autoFillHeight?: boolean;\n\n isReleased: boolean;\n\n rowHeightsMap: NumberMap<number>;\n colWidthsMap: NumberMap<string | number>;\n\n on: <TYPE extends keyof TableEventHandlersEventArgumentMap>(\n type: TYPE,\n listener: TableEventListener<TYPE> //(event: TableEventHandlersEventArgumentMap[TYPE]) => TableEventHandlersReturnMap[TYPE]\n ) => EventListenerId;\n // &(<T extends keyof TableEventHandlersEventArgumentMap>(type: string, listener: AnyListener<T>) => EventListenerId);\n\n _vDataSet: DataSet;\n /** 场景树对象 */\n scenegraph: Scenegraph;\n /** 状态管理模块 */\n stateManager?: StateManager;\n /** 事件管理模块 */\n eventManager?: EventManager;\n /** 行表头的层数 */\n rowHeaderLevelCount: number;\n /** 列表头的层数 */\n columnHeaderLevelCount: number;\n\n canvasWidth?: number;\n canvasHeight?: number;\n\n /** 获取表格绘制的范围 不包括frame的宽度 */\n getDrawRange: () => Rect;\n /** 将鼠标坐标值 转换成表格坐标系中的坐标位置 */\n _getMouseAbstractPoint: (\n evt: TouchEvent | MouseEvent | undefined,\n isAddScroll?: boolean\n ) => { x: number; y: number; inTable: boolean };\n getElement: () => HTMLElement;\n getContainer: () => HTMLElement;\n\n setFrozenColCount: (count: number) => void;\n _setFrozenColCount: (count: number) => void;\n _updateSize: () => void;\n\n render: () => void;\n throttleInvalidate: () => void;\n getRowHeight: (row: number) => number;\n getDefaultRowHeight: (row: number) => number | 'auto';\n _setRowHeight: (row: number, height: number, clearCache?: boolean) => void;\n getColWidth: (col: number) => number;\n getColWidthDefined: (col: number) => string | number;\n // setColWidthDefined: (col: number, width: number) => void;\n getColWidthDefinedNumber: (col: number) => number;\n // getColWidthDefine: (col: number) => string | number;\n _setColWidth: (col: number, width: number | string, clearCache?: boolean, skipCheckFrozen?: boolean) => void;\n _getColContentWidth: (col: number) => number;\n _setColContentWidth: (col: number, width: number | string, clearCache?: boolean) => void;\n getMaxColWidth: (col: number) => number;\n setMaxColWidth: (col: number, maxwidth: string | number) => void;\n getMinColWidth: (col: number) => number;\n setMinColWidth: (col: number, minwidth: string | number) => void;\n getCellRect: (col: number, row: number) => RectProps;\n getCellRelativeRect: (col: number, row: number) => RectProps;\n getCellsRect: (startCol: number, startRow: number, endCol: number, endRow: number) => RectProps;\n getCellRangeRect: (cellRange: CellRange | CellAddress) => RectProps;\n getCellRangeRelativeRect: (cellRange: CellRange | CellAddress) => RectProps;\n getVisibleCellRangeRelativeRect: (cellRange: CellRange | CellAddress) => RectProps;\n isFrozenCell: (col: number, row: number) => { row: boolean; col: boolean } | null;\n getRowAt: (absoluteY: number) => { top: number; row: number; bottom: number };\n getColAt: (absoluteX: number) => { left: number; col: number; right: number };\n getCellAt: (absoluteX: number, absoluteY: number) => CellAddress;\n _makeVisibleCell: (col: number, row: number) => void;\n // setFocusCursor(col: number, row: number): void;\n // focusCell(col: number, row: number): void;\n getCellOverflowText: (col: number, row: number) => string | null;\n getColsWidth: (startCol: number, endCol: number) => number;\n getRowsHeight: (startRow: number, endRow: number) => number;\n\n release: () => void;\n addReleaseObj: (releaseObj: { release: () => void }) => void;\n _getCellStyle: (col: number, row: number) => FullExtendStyle;\n clearCellStyleCache: () => void;\n\n getFrozenRowsHeight: () => number;\n getFrozenColsWidth: () => number;\n getBottomFrozenRowsHeight: () => number;\n getRightFrozenColsWidth: () => number;\n selectCell: (col: number, row: number) => void;\n selectCells: (cellRanges: CellRange[]) => void;\n getAllRowsHeight: () => number;\n getAllColsWidth: () => number;\n\n off: (id: EventListenerId) => void;\n getBodyField: (col: number, row: number) => FieldDef | undefined;\n /**\n * 根据单元格获取对应的源数据\n * @param col\n * @param row\n * @returns\n */\n getRecordByCell: (col: number, row: number) => MaybePromiseOrUndefined;\n /**\n * 根据数据源的index 获取显示到表格中的index 行号或者列号(与转置相关)。注:ListTable特有接口\n * @param recordIndex\n */\n getTableIndexByRecordIndex: (recordIndex: number) => number;\n /**\n * 根据数据源的field 获取显示到表格中的index 行号或者列号(与转置相关)。注:ListTable特有接口\n * @param recordIndex\n */\n getTableIndexByField: (field: FieldDef) => number;\n /**\n * 根据数据源中的index和field获取单元格行列号。注:ListTable特有接口\n * @param field\n * @param recordIndex\n * @returns\n */\n getCellAddrByFieldRecord: (field: FieldDef, recordIndex: number) => CellAddress;\n getRecordShowIndexByCell: (col: number, row: number) => number;\n getRecordStartRowByRecordIndex: (index: number) => number;\n\n getHeaderField: (col: number, row: number) => any | undefined;\n getHeaderFieldKey: (col: number, row: number) => any | undefined;\n\n _getHeaderCellBySortState: (sortState: SortState) => CellAddress | undefined;\n getHeaderDefine: (col: number, row: number) => ColumnDefine;\n _getHeaderLayoutMap: (col: number, row: number) => HeaderData;\n getContext: () => CanvasRenderingContext2D;\n getCellRange: (col: number, row: number) => CellRange;\n _resetFrozenColCount: () => void;\n isCellRangeEqual: (col: number, row: number, targetCol: number, targetRow: number) => boolean;\n _getLayoutCellId: (col: number, row: number) => LayoutObjectId;\n _getBodyLayoutMap: (col: number, row: number) => ColumnData | IndicatorData;\n getBodyColumnDefine: (col: number, row: number) => ColumnDefine;\n getBodyColumnType: (col: number, row: number) => ColumnTypeOption;\n getCellType: (col: number, row: number) => ColumnTypeOption;\n fireListeners: <TYPE extends keyof TableEventHandlersEventArgumentMap>(\n type: TYPE,\n event: TableEventHandlersEventArgumentMap[TYPE]\n ) => TableEventHandlersReturnMap[TYPE][];\n\n //更新分页\n updatePagination: (cof: IPagination) => void;\n //hover\n\n getHeaderDescription: (col: number, row: number) => string | undefined;\n /** 获取单元格展示值 */\n getCellValue: (col: number, row: number) => string | null;\n /** 获取单元格展示数据的format前的值 */\n getCellOriginValue: (col: number, row: number) => any;\n /** 获取单元格展示数据源最原始值 */\n getCellRawValue: (col: number, row: number) => FieldData;\n /** 获取单元格展示数据的format前的record源数据 */\n getCellOriginRecord: (col: number, row: number) => MaybePromiseOrUndefined;\n /** 获取单元格展示源数据 */\n getCellRawRecord: (col: number, row: number) => MaybePromiseOrUndefined;\n\n _dropDownMenuIsHighlight: (col: number, row: number, index: number) => boolean;\n // bindEvents(): void;\n refreshRowColCount: () => void;\n // getFieldData: (field: FieldDef | FieldFormat | undefined, col: number, row: number) => FieldData;\n _hasField: (field: FieldDef, col: number, row: number) => boolean;\n getCellHeaderPaths: (col: number, row: number) => ICellHeaderPaths;\n getCellLocation: (col: number, row: number) => CellLocation;\n // isHitIcon(col: number, row: number, x: number, y: number, iconType: IconFuncTypeEnum): boolean;\n getCellIcons: (col: number, row: number) => ColumnIconOption[];\n\n getMenuInfo: (col: number, row: number, type: string) => DropDownMenuEventInfo;\n /**\n * 获取某个单元格的样式 共业务方调用\n * @param col\n * @param row\n */\n getCellStyle: (col: number, row: number) => CellStyle; // 计算后style\n\n getHierarchyState: (col: number, row: number) => HierarchyState | null;\n\n _hasHierarchyTreeHeader: () => boolean;\n\n _canDragHeaderPosition: (col: number, row: number) => boolean;\n\n isHeader: (col: number, row: number) => boolean;\n\n isColumnHeader: (col: number, row: number) => boolean;\n\n isCornerHeader: (col: number, row: number) => boolean;\n\n isRowHeader: (col: number, row: number) => boolean;\n\n getCopyValue: () => string;\n\n getSelectedCellInfos: () => CellInfo[][];\n getCellInfo: (col: number, row: number) => Omit<MousePointerCellEvent, 'target'>;\n\n showTooltip: (col: number, row: number, tooltipOptions?: TooltipOptions) => void;\n\n measureText: (\n text: string,\n font: { fontSize: number; fontWeight?: string | number; fontFamily: string }\n ) => ITextSize;\n\n _canResizeColumn: (col: number, row: number) => boolean;\n\n getCustomRender: (col: number, row: number) => ICustomRender;\n getCustomLayout: (col: number, row: number) => ICustomLayout;\n isListTable: () => boolean;\n isPivotTable: (() => boolean) & (() => boolean);\n isPivotChart: (() => boolean) & (() => boolean);\n _clearColRangeWidthsMap: (col?: number) => void;\n _clearRowRangeHeightsMap: (row?: number) => void;\n clearRowHeightCache: () => void;\n clearColWidthCache: () => void;\n toggleHierarchyState: (col: number, row: number) => void;\n\n resize: () => void;\n\n getMergeCellRect: (col: number, row: number) => Rect;\n\n getTargetColAt: (absoluteX: number) => { col: number; left: number; right: number; width: number } | null;\n getTargetRowAt: (absoluteY: number) => { row: number; top: number; bottom: number; height: number } | null;\n\n renderWithRecreateCells: () => void;\n //#endregion tableAPI\n\n _adjustColWidth: (col: number, orgWidth: number) => number;\n _colWidthDefineToPxWidth: (width: string | number) => number;\n isFrozenColumn: (col: number, row?: number) => boolean;\n isLeftFrozenColumn: (col: number, row?: number) => boolean;\n isRightFrozenColumn: (col: number, row?: number) => boolean;\n isFrozenRow: (col: number, row?: number) => boolean;\n isTopFrozenRow: (col: number, row?: number) => boolean;\n isBottomFrozenRow: (col: number, row?: number) => boolean;\n\n getCustomMerge: (col: number, row: number) => undefined | (Omit<CustomMerge, 'style'> & { style?: FullExtendStyle });\n /** 获取表格body部分的显示单元格范围 */\n getBodyVisibleCellRange: () => { rowStart: number; colStart: number; rowEnd: number; colEnd: number };\n /** 获取表格body部分的显示列号范围 */\n getBodyVisibleColRange: () => { colStart: number; colEnd: number };\n /** 获取表格body部分的显示行号范围 */\n getBodyVisibleRowRange: () => { rowStart: number; rowEnd: number };\n\n hasCustomRenderOrLayout: () => boolean;\n /** 根据表格单元格的行列号 获取在body部分的列索引及行索引 */\n getBodyIndexByTableIndex: (col: number, row: number) => CellAddress;\n /** 根据body部分的列索引及行索引,获取单元格的行列号 */\n getTableIndexByBodyIndex: (col: number, row: number) => CellAddress;\n}\nexport interface ListTableProtected extends IBaseTableProtected {\n /** 表格数据 */\n records: any[] | null;\n columns: ColumnsDefine;\n layoutMap: SimpleHeaderLayoutMap;\n}\n\nexport interface PivotTableProtected extends IBaseTableProtected {\n /** 表格数据 */\n records: any[] | null;\n layoutMap: PivotHeaderLayoutMap;\n dataConfig?: IDataConfig;\n /**\n * 透视表是否开启数据分析\n * 如果传入数据是明细数据需要聚合分析则开启\n * 如传入数据是经过聚合好的为了提升性能这里设置为false,同时需要传入columnTree和rowTree\n */\n enableDataAnalysis?: boolean;\n\n /** 列表头树型结构 */\n columnTree?: IHeaderTreeDefine[];\n /** 行表头树型结构 */\n rowTree?: IHeaderTreeDefine[];\n /** 定义行上各个维度具体配置项和样式定义 */\n rows?: (IRowDimension | string)[]; // (string | IDimension)[]; 后续支持数据分析的透视表 支持string配置\n /** 定义列上各个维度具体配置项和样式定义 */\n columns?: (IColumnDimension | string)[]; // (string | IDimension)[];\n /** 定义指标具体配置项和样式定义 包含表头和body的定义*/\n indicators?: (IIndicator | string)[]; // (string | IIndicator)[];\n}\nexport interface PivotChartProtected extends IBaseTableProtected {\n /** 表格数据 */\n records: any[] | Record<string, any[]>;\n layoutMap: PivotHeaderLayoutMap;\n dataConfig?: IDataConfig;\n columnTree?: IHeaderTreeDefine[];\n /** 行表头维度结构 */\n rowTree?: IHeaderTreeDefine[];\n /** 定义行上各个维度具体配置项和样式定义 */\n rows?: (IRowDimension | string)[]; // (string | IDimension)[]; 后续支持数据分析的透视表 支持string配置\n /** 定义列上各个维度具体配置项和样式定义 */\n columns?: (IColumnDimension | string)[]; // (string | IDimension)[];\n /** 定义指标具体配置项和样式定义 包含表头和body的定义*/\n indicators?: (IIndicator | string)[]; // (string | IIndicator)[];\n}\n"]}
|
package/dist/vtable.js
CHANGED
|
@@ -56150,13 +56150,13 @@
|
|
|
56150
56150
|
else if (direction === 'right' && proxy.colStart - count < proxy.bodyLeftCol) {
|
|
56151
56151
|
count = proxy.colStart - proxy.bodyLeftCol;
|
|
56152
56152
|
}
|
|
56153
|
+
if (count === 0) {
|
|
56154
|
+
return;
|
|
56155
|
+
}
|
|
56153
56156
|
if (count < 0) {
|
|
56154
56157
|
direction = direction === 'left' ? 'right' : 'left';
|
|
56155
56158
|
count = -count;
|
|
56156
56159
|
}
|
|
56157
|
-
if (count <= 0) {
|
|
56158
|
-
return;
|
|
56159
|
-
}
|
|
56160
56160
|
if (count < proxy.colEnd - proxy.colStart) {
|
|
56161
56161
|
const startCol = direction === 'left' ? proxy.colStart : proxy.colEnd - count + 1;
|
|
56162
56162
|
const endCol = direction === 'left' ? proxy.colStart + count - 1 : proxy.colEnd;
|
|
@@ -56385,6 +56385,9 @@
|
|
|
56385
56385
|
else if (direction === 'down' && proxy.rowStart - count < proxy.bodyTopRow) {
|
|
56386
56386
|
count = proxy.rowStart - proxy.bodyTopRow;
|
|
56387
56387
|
}
|
|
56388
|
+
if (count === 0) {
|
|
56389
|
+
return;
|
|
56390
|
+
}
|
|
56388
56391
|
if (count < 0) {
|
|
56389
56392
|
direction = direction === 'up' ? 'down' : 'up';
|
|
56390
56393
|
count = -count;
|
|
@@ -66578,7 +66581,7 @@
|
|
|
66578
66581
|
return TABLE_EVENT_TYPE;
|
|
66579
66582
|
}
|
|
66580
66583
|
options;
|
|
66581
|
-
version = "0.17.
|
|
66584
|
+
version = "0.17.3-alpha.0";
|
|
66582
66585
|
pagination;
|
|
66583
66586
|
id = `VTable${Date.now()}`;
|
|
66584
66587
|
headerStyleCache;
|
|
@@ -68806,6 +68809,18 @@
|
|
|
68806
68809
|
}
|
|
68807
68810
|
return null;
|
|
68808
68811
|
}
|
|
68812
|
+
getBodyIndexByTableIndex(col, row) {
|
|
68813
|
+
return {
|
|
68814
|
+
col: col - this.rowHeaderLevelCount,
|
|
68815
|
+
row: row - this.columnHeaderLevelCount
|
|
68816
|
+
};
|
|
68817
|
+
}
|
|
68818
|
+
getTableIndexByBodyIndex(col, row) {
|
|
68819
|
+
return {
|
|
68820
|
+
col: col + this.rowHeaderLevelCount,
|
|
68821
|
+
row: row + this.columnHeaderLevelCount
|
|
68822
|
+
};
|
|
68823
|
+
}
|
|
68809
68824
|
}
|
|
68810
68825
|
|
|
68811
68826
|
var core = /*#__PURE__*/Object.freeze({
|
|
@@ -70204,6 +70219,9 @@
|
|
|
70204
70219
|
this.renderAsync();
|
|
70205
70220
|
this.eventManager.updateEventBinder();
|
|
70206
70221
|
}
|
|
70222
|
+
get columns() {
|
|
70223
|
+
return this.internalProps.columns;
|
|
70224
|
+
}
|
|
70207
70225
|
get header() {
|
|
70208
70226
|
return this.internalProps.columns;
|
|
70209
70227
|
}
|
|
@@ -77190,7 +77208,7 @@
|
|
|
77190
77208
|
return new Tag$1(params ? params.attribute : {});
|
|
77191
77209
|
}
|
|
77192
77210
|
|
|
77193
|
-
const version = "0.17.
|
|
77211
|
+
const version = "0.17.3-alpha.0";
|
|
77194
77212
|
function getIcons() {
|
|
77195
77213
|
return get$2();
|
|
77196
77214
|
}
|