@visactor/vtable 1.26.4 → 1.26.6
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 +5 -1
- package/cjs/ListTable.js +41 -11
- package/cjs/ListTable.js.map +1 -1
- package/cjs/body-helper/body-helper.d.ts +1 -0
- package/cjs/body-helper/body-helper.js +4 -3
- package/cjs/body-helper/body-helper.js.map +1 -1
- package/cjs/body-helper/style.js +2 -1
- package/cjs/components/legend/discrete-legend/discrete-legend.d.ts +1 -1
- package/cjs/core/BaseTable.d.ts +1 -0
- package/cjs/core/BaseTable.js +37 -27
- package/cjs/core/BaseTable.js.map +1 -1
- package/cjs/core/row-series-number-helper.d.ts +1 -0
- package/cjs/core/row-series-number-helper.js +3 -1
- package/cjs/core/row-series-number-helper.js.map +1 -1
- package/cjs/data/CachedDataSource.js +5 -3
- package/cjs/data/CachedDataSource.js.map +1 -1
- package/cjs/data/DataSource.js +1 -2
- package/cjs/dataset/DataStatistics.js +2 -1
- package/cjs/header-helper/header-helper.d.ts +1 -0
- package/cjs/header-helper/header-helper.js +4 -3
- package/cjs/header-helper/header-helper.js.map +1 -1
- package/cjs/header-helper/style.js +2 -1
- package/cjs/index.d.ts +1 -1
- package/cjs/index.js +1 -1
- package/cjs/index.js.map +1 -1
- package/cjs/plugins/custom-cell-style.js +1 -1
- package/cjs/plugins/interface.d.ts +2 -1
- package/cjs/plugins/interface.js.map +1 -1
- package/cjs/plugins/plugin-manager.d.ts +1 -1
- package/cjs/plugins/plugin-manager.js +11 -6
- package/cjs/plugins/plugin-manager.js.map +1 -1
- package/cjs/scenegraph/animation/appear.js +18 -3
- package/cjs/scenegraph/animation/appear.js.map +1 -1
- package/cjs/scenegraph/component/custom.js +3 -3
- package/cjs/scenegraph/component/custom.js.map +1 -1
- package/cjs/scenegraph/component/menu.js +4 -4
- package/cjs/scenegraph/component/menu.js.map +1 -1
- package/cjs/scenegraph/graphic/chart.d.ts +6 -1
- package/cjs/scenegraph/graphic/chart.js +38 -4
- package/cjs/scenegraph/graphic/chart.js.map +1 -1
- package/cjs/scenegraph/graphic/contributions/chart-render-helper.js +2 -1
- package/cjs/scenegraph/graphic/contributions/chart-render-helper.js.map +1 -1
- package/cjs/scenegraph/graphic/group.d.ts +3 -1
- package/cjs/scenegraph/graphic/group.js +21 -3
- package/cjs/scenegraph/graphic/group.js.map +1 -1
- package/cjs/scenegraph/group-creater/cell-helper.js +4 -3
- package/cjs/scenegraph/group-creater/cell-helper.js.map +1 -1
- package/cjs/scenegraph/group-creater/cell-type/button-cell.js +2 -2
- package/cjs/scenegraph/group-creater/cell-type/button-cell.js.map +1 -1
- package/cjs/scenegraph/group-creater/cell-type/chart-cell.js +4 -4
- package/cjs/scenegraph/group-creater/cell-type/chart-cell.js.map +1 -1
- package/cjs/scenegraph/group-creater/cell-type/checkbox-cell.js +2 -2
- package/cjs/scenegraph/group-creater/cell-type/checkbox-cell.js.map +1 -1
- package/cjs/scenegraph/group-creater/cell-type/image-cell.js +2 -2
- package/cjs/scenegraph/group-creater/cell-type/image-cell.js.map +1 -1
- package/cjs/scenegraph/group-creater/cell-type/radio-cell.js +2 -2
- package/cjs/scenegraph/group-creater/cell-type/radio-cell.js.map +1 -1
- package/cjs/scenegraph/group-creater/cell-type/spark-line-cell.js +2 -2
- package/cjs/scenegraph/group-creater/cell-type/spark-line-cell.js.map +1 -1
- package/cjs/scenegraph/group-creater/cell-type/switch-cell.js +2 -2
- package/cjs/scenegraph/group-creater/cell-type/switch-cell.js.map +1 -1
- package/cjs/scenegraph/group-creater/cell-type/text-cell.js +6 -6
- package/cjs/scenegraph/group-creater/cell-type/text-cell.js.map +1 -1
- package/cjs/scenegraph/group-creater/cell-type/video-cell.js +10 -7
- package/cjs/scenegraph/group-creater/cell-type/video-cell.js.map +1 -1
- package/cjs/scenegraph/group-creater/column-helper.js +3 -2
- package/cjs/scenegraph/group-creater/column-helper.js.map +1 -1
- package/cjs/scenegraph/group-creater/progress/create-group-for-first-screen.js +24 -8
- package/cjs/scenegraph/group-creater/progress/create-group-for-first-screen.js.map +1 -1
- package/cjs/scenegraph/layout/compute-row-height.js +15 -4
- package/cjs/scenegraph/layout/compute-row-height.js.map +1 -1
- package/cjs/scenegraph/layout/update-row.js +24 -3
- package/cjs/scenegraph/layout/update-row.js.map +1 -1
- package/cjs/scenegraph/runtime-contributions.d.ts +2 -0
- package/cjs/scenegraph/runtime-contributions.js +28 -0
- package/cjs/scenegraph/runtime-contributions.js.map +1 -0
- package/cjs/scenegraph/scenegraph.d.ts +4 -1
- package/cjs/scenegraph/scenegraph.js +81 -35
- package/cjs/scenegraph/scenegraph.js.map +1 -1
- package/cjs/scenegraph/utils/text-icon-layout.d.ts +4 -0
- package/cjs/scenegraph/utils/text-icon-layout.js +27 -9
- package/cjs/scenegraph/utils/text-icon-layout.js.map +1 -1
- package/cjs/scenegraph/utils/text-measure.js.map +1 -1
- package/cjs/state/checkbox/checkbox.d.ts +3 -0
- package/cjs/state/checkbox/checkbox.js +138 -2
- package/cjs/state/checkbox/checkbox.js.map +1 -1
- package/cjs/ts-types/base-table.d.ts +5 -1
- package/cjs/ts-types/base-table.js.map +1 -1
- package/cjs/ts-types/table-engine.d.ts +7 -1
- package/cjs/ts-types/table-engine.js.map +1 -1
- package/cjs/vrender-app.d.ts +20 -0
- package/cjs/vrender-app.js +141 -0
- package/cjs/vrender-app.js.map +1 -0
- package/cjs/vrender.d.ts +17 -1
- package/cjs/vrender.js +36 -15
- package/cjs/vrender.js.map +1 -1
- package/dist/vtable.js +106194 -96838
- package/dist/vtable.min.js +1 -1
- package/es/ListTable.d.ts +5 -1
- package/es/ListTable.js +41 -11
- package/es/ListTable.js.map +1 -1
- package/es/body-helper/body-helper.d.ts +1 -0
- package/es/body-helper/body-helper.js +4 -3
- package/es/body-helper/body-helper.js.map +1 -1
- package/es/body-helper/style.js +2 -1
- package/es/components/legend/discrete-legend/discrete-legend.d.ts +1 -1
- package/es/core/BaseTable.d.ts +1 -0
- package/es/core/BaseTable.js +39 -29
- package/es/core/BaseTable.js.map +1 -1
- package/es/core/row-series-number-helper.d.ts +1 -0
- package/es/core/row-series-number-helper.js +3 -1
- package/es/core/row-series-number-helper.js.map +1 -1
- package/es/data/CachedDataSource.js +5 -3
- package/es/data/CachedDataSource.js.map +1 -1
- package/es/data/DataSource.js +1 -2
- package/es/dataset/DataStatistics.js +2 -1
- package/es/header-helper/header-helper.d.ts +1 -0
- package/es/header-helper/header-helper.js +4 -3
- package/es/header-helper/header-helper.js.map +1 -1
- package/es/header-helper/style.js +2 -1
- package/es/index.d.ts +1 -1
- package/es/index.js +1 -1
- package/es/index.js.map +1 -1
- package/es/plugins/custom-cell-style.js +1 -1
- package/es/plugins/interface.d.ts +2 -1
- package/es/plugins/interface.js.map +1 -1
- package/es/plugins/plugin-manager.d.ts +1 -1
- package/es/plugins/plugin-manager.js +11 -6
- package/es/plugins/plugin-manager.js.map +1 -1
- package/es/scenegraph/animation/appear.js +18 -3
- package/es/scenegraph/animation/appear.js.map +1 -1
- package/es/scenegraph/component/custom.js +3 -3
- package/es/scenegraph/component/custom.js.map +1 -1
- package/es/scenegraph/component/menu.js +4 -4
- package/es/scenegraph/component/menu.js.map +1 -1
- package/es/scenegraph/graphic/chart.d.ts +6 -1
- package/es/scenegraph/graphic/chart.js +39 -3
- package/es/scenegraph/graphic/chart.js.map +1 -1
- package/es/scenegraph/graphic/contributions/chart-render-helper.js +2 -1
- package/es/scenegraph/graphic/contributions/chart-render-helper.js.map +1 -1
- package/es/scenegraph/graphic/group.d.ts +3 -1
- package/es/scenegraph/graphic/group.js +21 -3
- package/es/scenegraph/graphic/group.js.map +1 -1
- package/es/scenegraph/group-creater/cell-helper.js +4 -3
- package/es/scenegraph/group-creater/cell-helper.js.map +1 -1
- package/es/scenegraph/group-creater/cell-type/button-cell.js +2 -2
- package/es/scenegraph/group-creater/cell-type/button-cell.js.map +1 -1
- package/es/scenegraph/group-creater/cell-type/chart-cell.js +4 -4
- package/es/scenegraph/group-creater/cell-type/chart-cell.js.map +1 -1
- package/es/scenegraph/group-creater/cell-type/checkbox-cell.js +2 -2
- package/es/scenegraph/group-creater/cell-type/checkbox-cell.js.map +1 -1
- package/es/scenegraph/group-creater/cell-type/image-cell.js +2 -2
- package/es/scenegraph/group-creater/cell-type/image-cell.js.map +1 -1
- package/es/scenegraph/group-creater/cell-type/radio-cell.js +2 -2
- package/es/scenegraph/group-creater/cell-type/radio-cell.js.map +1 -1
- package/es/scenegraph/group-creater/cell-type/spark-line-cell.js +2 -2
- package/es/scenegraph/group-creater/cell-type/spark-line-cell.js.map +1 -1
- package/es/scenegraph/group-creater/cell-type/switch-cell.js +2 -2
- package/es/scenegraph/group-creater/cell-type/switch-cell.js.map +1 -1
- package/es/scenegraph/group-creater/cell-type/text-cell.js +5 -5
- package/es/scenegraph/group-creater/cell-type/text-cell.js.map +1 -1
- package/es/scenegraph/group-creater/cell-type/video-cell.js +10 -7
- package/es/scenegraph/group-creater/cell-type/video-cell.js.map +1 -1
- package/es/scenegraph/group-creater/column-helper.js +3 -2
- package/es/scenegraph/group-creater/column-helper.js.map +1 -1
- package/es/scenegraph/group-creater/progress/create-group-for-first-screen.js +24 -8
- package/es/scenegraph/group-creater/progress/create-group-for-first-screen.js.map +1 -1
- package/es/scenegraph/layout/compute-row-height.js +15 -4
- package/es/scenegraph/layout/compute-row-height.js.map +1 -1
- package/es/scenegraph/layout/update-row.js +25 -2
- package/es/scenegraph/layout/update-row.js.map +1 -1
- package/es/scenegraph/runtime-contributions.d.ts +2 -0
- package/es/scenegraph/runtime-contributions.js +20 -0
- package/es/scenegraph/runtime-contributions.js.map +1 -0
- package/es/scenegraph/scenegraph.d.ts +4 -1
- package/es/scenegraph/scenegraph.js +83 -35
- package/es/scenegraph/scenegraph.js.map +1 -1
- package/es/scenegraph/utils/text-icon-layout.d.ts +4 -0
- package/es/scenegraph/utils/text-icon-layout.js +25 -8
- package/es/scenegraph/utils/text-icon-layout.js.map +1 -1
- package/es/scenegraph/utils/text-measure.js.map +1 -1
- package/es/state/checkbox/checkbox.d.ts +3 -0
- package/es/state/checkbox/checkbox.js +133 -0
- package/es/state/checkbox/checkbox.js.map +1 -1
- package/es/ts-types/base-table.d.ts +5 -1
- package/es/ts-types/base-table.js.map +1 -1
- package/es/ts-types/table-engine.d.ts +7 -1
- package/es/ts-types/table-engine.js.map +1 -1
- package/es/vrender-app.d.ts +20 -0
- package/es/vrender-app.js +161 -0
- package/es/vrender-app.js.map +1 -0
- package/es/vrender.d.ts +17 -1
- package/es/vrender.js +27 -8
- package/es/vrender.js.map +1 -1
- package/package.json +10 -9
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var __importDefault = this && this.__importDefault || function(mod) {
|
|
4
|
+
return mod && mod.__esModule ? mod : {
|
|
5
|
+
default: mod
|
|
6
|
+
};
|
|
7
|
+
};
|
|
8
|
+
|
|
9
|
+
Object.defineProperty(exports, "__esModule", {
|
|
10
|
+
value: !0
|
|
11
|
+
}), exports.installVTableRuntimeContributions = void 0;
|
|
12
|
+
|
|
13
|
+
const runtime_contribution_1 = require("@visactor/vrender/entries/runtime-contribution"), constants_1 = require("@visactor/vrender-kits/picker/contributions/constants"), contributions_1 = __importDefault(require("./graphic/contributions")), text_measure_1 = __importDefault(require("./utils/text-measure"));
|
|
14
|
+
|
|
15
|
+
function installVTableRuntimeContributions(app) {
|
|
16
|
+
(0, runtime_contribution_1.installRuntimeContributionModule)(contributions_1.default, {
|
|
17
|
+
app: app,
|
|
18
|
+
targets: [ "graphic-renderer", "draw-contribution", {
|
|
19
|
+
picker: constants_1.CanvasPickerContribution
|
|
20
|
+
} ]
|
|
21
|
+
}), (0, runtime_contribution_1.installRuntimeContributionModule)(text_measure_1.default, {
|
|
22
|
+
app: app,
|
|
23
|
+
targets: [ "graphic-renderer" ]
|
|
24
|
+
});
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
exports.installVTableRuntimeContributions = installVTableRuntimeContributions;
|
|
28
|
+
//# sourceMappingURL=runtime-contributions.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/scenegraph/runtime-contributions.ts"],"names":[],"mappings":";;;;;;AACA,yFAAkG;AAClG,qFAAiG;AAEjG,4EAAkD;AAClD,wEAAqD;AAErD,SAAgB,iCAAiC,CAAC,GAAU;IAC1D,IAAA,uDAAgC,EAAC,uBAAW,EAAE;QAC5C,GAAG;QACH,OAAO,EAAE,CAAC,kBAAkB,EAAE,mBAAmB,EAAE,EAAE,MAAM,EAAE,oCAAwB,EAAE,CAAC;KACzF,CAAC,CAAC;IAEH,IAAA,uDAAgC,EAAC,sBAAiB,EAAE;QAClD,GAAG;QACH,OAAO,EAAE,CAAC,kBAAkB,CAAC;KAC9B,CAAC,CAAC;AACL,CAAC;AAVD,8EAUC","file":"runtime-contributions.js","sourcesContent":["import type { IApp } from '@visactor/vrender-core';\nimport { installRuntimeContributionModule } from '@visactor/vrender/entries/runtime-contribution';\nimport { CanvasPickerContribution } from '@visactor/vrender-kits/picker/contributions/constants';\n\nimport splitModule from './graphic/contributions';\nimport textMeasureModule from './utils/text-measure';\n\nexport function installVTableRuntimeContributions(app?: IApp): void {\n installRuntimeContributionModule(splitModule, {\n app,\n targets: ['graphic-renderer', 'draw-contribution', { picker: CanvasPickerContribution }]\n });\n\n installRuntimeContributionModule(textMeasureModule, {\n app,\n targets: ['graphic-renderer']\n });\n}\n"]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { type IRect, type IRectGraphicAttribute, type IStage } from './../vrender';
|
|
2
2
|
import type { CellRange, CellSubLocation } from '../ts-types';
|
|
3
3
|
import { type CellAddress, type SortOrder } from '../ts-types';
|
|
4
4
|
import type { Group } from './graphic/group';
|
|
@@ -49,6 +49,8 @@ export declare class Scenegraph {
|
|
|
49
49
|
lastSelectId: string;
|
|
50
50
|
component: TableComponent;
|
|
51
51
|
stage: IStage;
|
|
52
|
+
stageOwned: boolean;
|
|
53
|
+
releaseVRenderAppRef?: () => void;
|
|
52
54
|
table: BaseTableAPI;
|
|
53
55
|
isPivot: boolean;
|
|
54
56
|
hasFrozen: boolean;
|
|
@@ -81,6 +83,7 @@ export declare class Scenegraph {
|
|
|
81
83
|
initSceneGraph(): void;
|
|
82
84
|
canvasShowMenu(): void;
|
|
83
85
|
clearCells(): void;
|
|
86
|
+
releaseStage(): void;
|
|
84
87
|
updateStageBackground(): void;
|
|
85
88
|
createComponent(): void;
|
|
86
89
|
updateComponent(): void;
|
|
@@ -23,35 +23,34 @@ var __createBinding = this && this.__createBinding || (Object.create ? function(
|
|
|
23
23
|
var result = {};
|
|
24
24
|
if (null != mod) for (var k in mod) "default" !== k && Object.prototype.hasOwnProperty.call(mod, k) && __createBinding(result, mod, k);
|
|
25
25
|
return __setModuleDefault(result, mod), result;
|
|
26
|
-
}, __importDefault = this && this.__importDefault || function(mod) {
|
|
27
|
-
return mod && mod.__esModule ? mod : {
|
|
28
|
-
default: mod
|
|
29
|
-
};
|
|
30
26
|
};
|
|
31
27
|
|
|
32
28
|
Object.defineProperty(exports, "__esModule", {
|
|
33
29
|
value: !0
|
|
34
30
|
}), exports.Scenegraph = void 0;
|
|
35
31
|
|
|
36
|
-
const vrender_1 = require("./../vrender"), ts_types_1 = require("../ts-types"), get_cell_merge_1 = require("./utils/get-cell-merge"), update_width_1 = require("./layout/update-width"), table_component_1 = require("./component/table-component"), update_height_1 = require("./layout/update-height"), image_cell_1 = require("./group-creater/cell-type/image-cell"), padding_1 = require("./utils/padding"), frame_border_1 = require("./style/frame-border"),
|
|
32
|
+
const vrender_1 = require("./../vrender"), vrender_app_1 = require("../vrender-app"), ts_types_1 = require("../ts-types"), get_cell_merge_1 = require("./utils/get-cell-merge"), update_width_1 = require("./layout/update-width"), table_component_1 = require("./component/table-component"), update_height_1 = require("./layout/update-height"), image_cell_1 = require("./group-creater/cell-type/image-cell"), padding_1 = require("./utils/padding"), frame_border_1 = require("./style/frame-border"), get_prop_1 = require("./utils/get-prop"), text_icon_layout_1 = require("./utils/text-icon-layout"), proxy_1 = require("./group-creater/progress/proxy"), compute_col_width_1 = require("./layout/compute-col-width"), move_cell_1 = require("./layout/move-cell"), cell_helper_1 = require("./group-creater/cell-helper"), update_select_border_1 = require("./select/update-select-border"), create_select_border_1 = require("./select/create-select-border"), move_select_border_1 = require("./select/move-select-border"), delete_select_border_1 = require("./select/delete-select-border"), update_row_1 = require("./layout/update-row"), stick_text_1 = require("./stick-text"), compute_row_height_1 = require("./layout/compute-row-height"), empty_group_1 = require("./utils/empty-group"), frozen_1 = require("./layout/frozen"), update_chart_1 = require("./refresh-node/update-chart"), init_scenegraph_1 = require("./group-creater/init-scenegraph"), update_container_1 = require("./utils/update-container"), runtime_contributions_1 = require("./runtime-contributions"), icon_update_1 = require("./icon/icon-update"), env_1 = require("../tools/env"), corner_cell_1 = require("./style/corner-cell"), update_col_1 = require("./layout/update-col"), util_1 = require("../tools/util"), appear_1 = require("./animation/appear"), frozen_react_1 = require("./layout/frozen-react"), registerIcons = __importStar(require("../icons")), update_select_style_1 = require("./select/update-select-style"), TABLE_EVENT_TYPE_1 = require("../core/TABLE_EVENT_TYPE"), util_2 = require("../event/util"), active_cell_chart_list_1 = require("./graphic/active-cell-chart-list");
|
|
37
33
|
|
|
38
|
-
(0, vrender_1.registerForVrender)(),
|
|
39
|
-
vrender_1.container.load(text_measure_1.default);
|
|
34
|
+
(0, vrender_1.registerForVrender)(), (0, runtime_contributions_1.installVTableRuntimeContributions)();
|
|
40
35
|
|
|
41
36
|
class Scenegraph {
|
|
42
37
|
constructor(table) {
|
|
38
|
+
var _a, _b;
|
|
43
39
|
let width, height;
|
|
44
|
-
this.
|
|
45
|
-
this.mergeMap = new Map, this.brushingChartInstance = void 0, this.brushingChartInstanceCellPos = {
|
|
40
|
+
this.stageOwned = !0, this._needUpdateContainer = !1, this.table = table, this.hasFrozen = !1,
|
|
41
|
+
this.clear = !0, this.mergeMap = new Map, this.brushingChartInstance = void 0, this.brushingChartInstanceCellPos = {
|
|
46
42
|
col: -1,
|
|
47
43
|
row: -1
|
|
48
44
|
}, this.chartInstanceListColumnByColumnDirection = {}, this.chartInstanceListRowByRowDirection = {},
|
|
49
45
|
this.delayRunDimensionHoverTimerForColumnDirection = [], this.delayRunDimensionHoverTimerForRowDirection = [],
|
|
50
46
|
this.delayRunDimensionHoverTimerForViewRange = [], this.disabledTooltipToAllChartInstances = !1,
|
|
51
|
-
(0,
|
|
52
|
-
|
|
53
|
-
width = table.options.
|
|
54
|
-
|
|
47
|
+
(0, vrender_1.setPoptipTheme)(this.table.theme.textPopTipStyle);
|
|
48
|
+
const mode = null !== (_a = table.options.mode) && void 0 !== _a ? _a : "node" === env_1.Env.mode ? "node" : "browser";
|
|
49
|
+
"node" === mode ? (width = table.canvasWidth, height = table.canvasHeight) : table.options.canvas && table.options.viewBox ? (width = table.options.viewBox.x2 - table.options.viewBox.x1,
|
|
50
|
+
height = table.options.viewBox.y2 - table.options.viewBox.y1) : (width = table.canvas.width,
|
|
51
|
+
height = table.canvas.height);
|
|
52
|
+
const {stage: stage, releaseAppRef: releaseAppRef, stageOwned: stageOwned} = (0,
|
|
53
|
+
vrender_app_1.createStageFromVRenderApp)(Object.assign({
|
|
55
54
|
canvas: table.canvas,
|
|
56
55
|
width: width,
|
|
57
56
|
height: height,
|
|
@@ -66,8 +65,19 @@ class Scenegraph {
|
|
|
66
65
|
this.table.options.afterRender && this.table.options.afterRender(stage), this.table.fireListeners("after_render", null);
|
|
67
66
|
},
|
|
68
67
|
canvasControled: !table.options.canvas,
|
|
69
|
-
viewBox: table.options.viewBox
|
|
70
|
-
|
|
68
|
+
viewBox: table.options.viewBox,
|
|
69
|
+
context: {
|
|
70
|
+
appName: "vtable"
|
|
71
|
+
}
|
|
72
|
+
}, table.options.renderOption), {
|
|
73
|
+
mode: mode,
|
|
74
|
+
scope: null !== (_b = table.options.vRenderAppScope) && void 0 !== _b ? _b : "vtable",
|
|
75
|
+
app: table.options.vRenderApp,
|
|
76
|
+
stage: table.options.stage,
|
|
77
|
+
envParams: table.options.modeParams
|
|
78
|
+
});
|
|
79
|
+
this.stage = stage, this.stageOwned = stageOwned, this.releaseVRenderAppRef = releaseAppRef,
|
|
80
|
+
this.stage.defaultLayer.setTheme({
|
|
71
81
|
group: {
|
|
72
82
|
boundsPadding: 0,
|
|
73
83
|
strokeBoundsBuffer: 0,
|
|
@@ -250,6 +260,20 @@ class Scenegraph {
|
|
|
250
260
|
delete this.tableGroup.border), null === (_u = this.proxy) || void 0 === _u || _u.release(),
|
|
251
261
|
null === (_v = this.table.reactCustomLayout) || void 0 === _v || _v.clearCache();
|
|
252
262
|
}
|
|
263
|
+
releaseStage() {
|
|
264
|
+
var _a, _b, _c;
|
|
265
|
+
const releaseAppRef = this.releaseVRenderAppRef;
|
|
266
|
+
this.releaseVRenderAppRef = void 0;
|
|
267
|
+
try {
|
|
268
|
+
if (this.stageOwned) null === (_a = this.stage) || void 0 === _a || _a.release(); else {
|
|
269
|
+
const tableGroup = this.tableGroup, tableGroupParent = null == tableGroup ? void 0 : tableGroup.parent;
|
|
270
|
+
null === (_b = null == tableGroupParent ? void 0 : tableGroupParent.removeChild) || void 0 === _b || _b.call(tableGroupParent, tableGroup),
|
|
271
|
+
null === (_c = null == tableGroup ? void 0 : tableGroup.release) || void 0 === _c || _c.call(tableGroup, !0);
|
|
272
|
+
}
|
|
273
|
+
} finally {
|
|
274
|
+
null == releaseAppRef || releaseAppRef();
|
|
275
|
+
}
|
|
276
|
+
}
|
|
253
277
|
updateStageBackground() {
|
|
254
278
|
this.stage.background = this.table.theme.underlayBackgroundColor, this.stage.renderNextFrame();
|
|
255
279
|
}
|
|
@@ -586,27 +610,49 @@ class Scenegraph {
|
|
|
586
610
|
height: this.tableGroup.attribute.height
|
|
587
611
|
})));
|
|
588
612
|
}
|
|
589
|
-
this.table.
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
|
|
613
|
+
const hasFrozenCols = this.table.frozenColCount > 0, hasRightFrozenCols = this.table.rightFrozenColCount > 0, hasFrozenRows = this.table.frozenRowCount > 0, hasBottomFrozenRows = this.table.bottomFrozenRowCount > 0;
|
|
614
|
+
if (hasBottomFrozenRows) {
|
|
615
|
+
const bottomFrozenRowsHeight = this.table.getBottomFrozenRowsHeight(), topFrozenBottom = Math.max(this.colHeaderGroup.attribute.y + this.colHeaderGroup.attribute.height, this.cornerHeaderGroup.attribute.y + this.cornerHeaderGroup.attribute.height, this.rightTopCornerGroup.attribute.y + this.rightTopCornerGroup.attribute.height), middleContentBottom = Math.max(this.rowHeaderGroup.attribute.y + this.rowHeaderGroup.attribute.height, this.bodyGroup.attribute.y + this.bodyGroup.attribute.height, this.rightFrozenGroup.attribute.y + this.rightFrozenGroup.attribute.height, topFrozenBottom), bottomFrozenY = Math.min(this.tableGroup.attribute.height - bottomFrozenRowsHeight, middleContentBottom);
|
|
616
|
+
this.bottomFrozenGroup.setAttribute("y", bottomFrozenY), this.leftBottomCornerGroup.setAttributes({
|
|
617
|
+
visible: hasFrozenCols,
|
|
618
|
+
y: bottomFrozenY,
|
|
619
|
+
height: bottomFrozenRowsHeight,
|
|
620
|
+
width: hasFrozenCols ? this.table.getFrozenColsWidth() : 0
|
|
621
|
+
}), this.rightBottomCornerGroup.setAttributes({
|
|
622
|
+
visible: hasRightFrozenCols,
|
|
623
|
+
x: 0,
|
|
624
|
+
y: bottomFrozenY,
|
|
625
|
+
width: 0,
|
|
626
|
+
height: bottomFrozenRowsHeight
|
|
627
|
+
});
|
|
628
|
+
} else this.leftBottomCornerGroup.setAttributes({
|
|
629
|
+
visible: !1,
|
|
630
|
+
width: 0,
|
|
631
|
+
height: 0
|
|
605
632
|
}), this.rightBottomCornerGroup.setAttributes({
|
|
606
|
-
visible: !
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
})
|
|
633
|
+
visible: !1,
|
|
634
|
+
width: 0,
|
|
635
|
+
height: 0
|
|
636
|
+
});
|
|
637
|
+
if (hasRightFrozenCols) {
|
|
638
|
+
const rightFrozenColsWidth = this.table.getRightFrozenColsWidth(), middleContentRight = Math.max(this.colHeaderGroup.attribute.x + this.colHeaderGroup.attribute.width, this.bodyGroup.attribute.x + this.bodyGroup.attribute.width, this.bottomFrozenGroup.attribute.x + this.bottomFrozenGroup.attribute.width), rightFrozenX = Math.min(this.tableGroup.attribute.width - rightFrozenColsWidth, middleContentRight);
|
|
639
|
+
this.rightFrozenGroup.setAttribute("x", rightFrozenX), this.rightTopCornerGroup.setAttributes({
|
|
640
|
+
visible: hasFrozenRows,
|
|
641
|
+
x: rightFrozenX,
|
|
642
|
+
width: hasFrozenRows ? rightFrozenColsWidth : 0,
|
|
643
|
+
height: hasFrozenRows ? this.table.getFrozenRowsHeight() : 0
|
|
644
|
+
}), this.rightBottomCornerGroup.setAttributes({
|
|
645
|
+
visible: hasBottomFrozenRows,
|
|
646
|
+
x: rightFrozenX,
|
|
647
|
+
width: hasBottomFrozenRows ? rightFrozenColsWidth : 0,
|
|
648
|
+
height: hasBottomFrozenRows ? this.table.getBottomFrozenRowsHeight() : 0
|
|
649
|
+
});
|
|
650
|
+
} else this.rightTopCornerGroup.setAttributes({
|
|
651
|
+
visible: !1,
|
|
652
|
+
width: 0,
|
|
653
|
+
height: 0
|
|
654
|
+
});
|
|
655
|
+
this.updateDomContainer();
|
|
610
656
|
}
|
|
611
657
|
updateRowHeight(row, detaY, skipTableHeightMap) {
|
|
612
658
|
detaY = Math.round(detaY), (0, update_height_1.updateRowHeight)(this, row, detaY, skipTableHeightMap),
|