@visactor/vtable 1.5.6 → 1.5.7-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.
@@ -97,4 +97,5 @@ export class EditManeger {
97
97
  null === (_d = (_c = this.editingEditor).onEnd) || void 0 === _d || _d.call(_c),
98
98
  this.editingEditor = null);
99
99
  }
100
- }
100
+ }
101
+ //# sourceMappingURL=edit-manager.js.map
@@ -2,5 +2,4 @@ export const editors = {};
2
2
 
3
3
  export function get(editorName) {
4
4
  if (editors[editorName]) return editors[editorName];
5
- }
6
- //# sourceMappingURL=editors.js.map
5
+ }
package/es/index.d.ts CHANGED
@@ -20,7 +20,7 @@ export { getDataCellPath } from './tools/get-data-path';
20
20
  export * from './render/jsx';
21
21
  export { getTargetCell } from './event/util';
22
22
  import * as VRender from './vrender';
23
- export declare const version = "1.5.6";
23
+ export declare const version = "1.5.7-alpha.0";
24
24
  export { TYPES, core, ListTable, ListTableSimple, ListTableConstructorOptions, PivotTable, PivotTableSimple, 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, updateCell, renderChart, graphicUtil, setCustomAlphabetCharSet, restoreMeasureText, VRender };
25
25
  declare function getIcons(): {
26
26
  [key: string]: TYPES.ColumnIconOption;
package/es/index.js CHANGED
@@ -42,7 +42,7 @@ export { getTargetCell } from "./event/util";
42
42
 
43
43
  import * as VRender from "./vrender";
44
44
 
45
- export const version = "1.5.6";
45
+ export const version = "1.5.7-alpha.0";
46
46
 
47
47
  export { TYPES, core, ListTable, ListTableSimple, PivotTable, PivotTableSimple, PivotChart, themes, data, getIcons, clearGlobal, register, DataStatistics, CustomLayout, updateCell, renderChart, graphicUtil, setCustomAlphabetCharSet, restoreMeasureText, VRender };
48
48
 
package/es/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,WAAW,EAAE,kBAAkB,EAAE,MAAM,WAAW,CAAC;AAC5D,kBAAkB,EAAE,CAAC;AAErB,OAAO,KAAK,KAAK,MAAM,YAAY,CAAC;AACpC,OAAO,KAAK,IAAI,MAAM,QAAQ,CAAC;AAC/B,OAAO,KAAK,IAAI,MAAM,QAAQ,CAAC;AAC/B,OAAO,KAAK,KAAK,MAAM,SAAS,CAAC;AACjC,OAAO,KAAK,QAAQ,MAAM,YAAY,CAAC;AACvC,OAAO,KAAK,MAAM,MAAM,UAAU,CAAC;AACnC,OAAO,KAAK,cAAc,MAAM,0BAA0B,CAAC;AAsB3D,OAAO,EAAE,YAAY,IAAI,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAC5D,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAErD,OAAO,EAAE,aAAa,IAAI,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAC/D,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AACvD,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAE1C,OAAO,KAAK,YAAY,MAAM,iBAAiB,CAAC;AAEhD,OAAO,EAAE,UAAU,EAAE,MAAM,wCAAwC,CAAC;AACpE,OAAO,EAAE,WAAW,EAAE,MAAM,wDAAwD,CAAC;AACrF,OAAO,EAAE,kBAAkB,EAAE,wBAAwB,EAAE,MAAM,iCAAiC,CAAC;AAK/F,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AACxD,cAAc,cAAc,CAAC;AAC7B,OAAO,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAG7C,OAAO,KAAK,OAAO,MAAM,WAAW,CAAC;AAErC,MAAM,CAAC,MAAM,OAAO,GAAG,OAAO,CAAC;AAI/B,OAAO,EAKL,KAAK,EACL,IAAI,EACJ,SAAS,EACT,eAAe,EAEf,UAAU,EACV,gBAAgB,EAGhB,UAAU,EAiBV,MAAM,EACN,IAAI,EAEJ,QAAQ,EACR,WAAW,EAEX,QAAQ,EAIR,cAAc,EACd,YAAY,EACZ,UAAU,EACV,WAAW,EACX,WAAW,EACX,wBAAwB,EACxB,kBAAkB,EAClB,OAAO,EACR,CAAC;AAGF,SAAS,QAAQ;IAGf,OAAO,KAAK,CAAC,GAAG,EAAE,CAAC;AACrB,CAAC;AAED,SAAS,WAAW;IAClB,QAAQ,CAAC,QAAQ,EAAE,CAAC;AAGtB,CAAC;AACD,KAAK,CAAC,eAAe,CAAC;AAEtB,cAAc,cAAc,CAAC;AAC7B,cAAc,sCAAsC,CAAC","file":"index.js","sourcesContent":["/* eslint-disable sort-imports */\nimport { graphicUtil, registerForVrender } from './vrender';\nregisterForVrender();\n\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 { ListTableAll as ListTable } from './ListTable-all';\nimport { ListTableSimple } from './ListTable-simple';\n// import { PivotTable } from './PivotTable';\nimport { PivotTableAll as PivotTable } from './PivotTable-all';\nimport { PivotTableSimple } from './PivotTable-simple';\nimport { PivotChart } from './PivotChart';\nimport type { MousePointerCellEvent } from './ts-types/events';\nimport * as CustomLayout from './render/layout';\n\nimport { updateCell } from './scenegraph/group-creater/cell-helper';\nimport { renderChart } from './scenegraph/graphic/contributions/chart-render-helper';\nimport { restoreMeasureText, setCustomAlphabetCharSet } from './scenegraph/utils/text-measure';\n\n// import { container, loadCanvasPicker } from '@src/vrender';\n// loadCanvasPicker(container);\n\nexport { getDataCellPath } from './tools/get-data-path';\nexport * from './render/jsx';\nexport { getTargetCell } from './event/util';\n\n// export * as VRender from './vrender';\nimport * as VRender from './vrender';\n\nexport const version = \"1.5.6\";\n/**\n * @namespace VTable\n */\nexport {\n /**\n * Types\n * @namespace VTable.TYPES\n */\n TYPES,\n core,\n ListTable,\n ListTableSimple,\n ListTableConstructorOptions,\n PivotTable,\n PivotTableSimple,\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 updateCell,\n renderChart,\n graphicUtil,\n setCustomAlphabetCharSet,\n restoreMeasureText,\n VRender\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\nexport * from './components';\nexport * from './scenegraph/group-creater/cell-type';\n"]}
1
+ {"version":3,"sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,WAAW,EAAE,kBAAkB,EAAE,MAAM,WAAW,CAAC;AAC5D,kBAAkB,EAAE,CAAC;AAErB,OAAO,KAAK,KAAK,MAAM,YAAY,CAAC;AACpC,OAAO,KAAK,IAAI,MAAM,QAAQ,CAAC;AAC/B,OAAO,KAAK,IAAI,MAAM,QAAQ,CAAC;AAC/B,OAAO,KAAK,KAAK,MAAM,SAAS,CAAC;AACjC,OAAO,KAAK,QAAQ,MAAM,YAAY,CAAC;AACvC,OAAO,KAAK,MAAM,MAAM,UAAU,CAAC;AACnC,OAAO,KAAK,cAAc,MAAM,0BAA0B,CAAC;AAsB3D,OAAO,EAAE,YAAY,IAAI,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAC5D,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAErD,OAAO,EAAE,aAAa,IAAI,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAC/D,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AACvD,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAE1C,OAAO,KAAK,YAAY,MAAM,iBAAiB,CAAC;AAEhD,OAAO,EAAE,UAAU,EAAE,MAAM,wCAAwC,CAAC;AACpE,OAAO,EAAE,WAAW,EAAE,MAAM,wDAAwD,CAAC;AACrF,OAAO,EAAE,kBAAkB,EAAE,wBAAwB,EAAE,MAAM,iCAAiC,CAAC;AAK/F,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AACxD,cAAc,cAAc,CAAC;AAC7B,OAAO,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAG7C,OAAO,KAAK,OAAO,MAAM,WAAW,CAAC;AAErC,MAAM,CAAC,MAAM,OAAO,GAAG,eAAe,CAAC;AAIvC,OAAO,EAKL,KAAK,EACL,IAAI,EACJ,SAAS,EACT,eAAe,EAEf,UAAU,EACV,gBAAgB,EAGhB,UAAU,EAiBV,MAAM,EACN,IAAI,EAEJ,QAAQ,EACR,WAAW,EAEX,QAAQ,EAIR,cAAc,EACd,YAAY,EACZ,UAAU,EACV,WAAW,EACX,WAAW,EACX,wBAAwB,EACxB,kBAAkB,EAClB,OAAO,EACR,CAAC;AAGF,SAAS,QAAQ;IAGf,OAAO,KAAK,CAAC,GAAG,EAAE,CAAC;AACrB,CAAC;AAED,SAAS,WAAW;IAClB,QAAQ,CAAC,QAAQ,EAAE,CAAC;AAGtB,CAAC;AACD,KAAK,CAAC,eAAe,CAAC;AAEtB,cAAc,cAAc,CAAC;AAC7B,cAAc,sCAAsC,CAAC","file":"index.js","sourcesContent":["/* eslint-disable sort-imports */\nimport { graphicUtil, registerForVrender } from './vrender';\nregisterForVrender();\n\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 { ListTableAll as ListTable } from './ListTable-all';\nimport { ListTableSimple } from './ListTable-simple';\n// import { PivotTable } from './PivotTable';\nimport { PivotTableAll as PivotTable } from './PivotTable-all';\nimport { PivotTableSimple } from './PivotTable-simple';\nimport { PivotChart } from './PivotChart';\nimport type { MousePointerCellEvent } from './ts-types/events';\nimport * as CustomLayout from './render/layout';\n\nimport { updateCell } from './scenegraph/group-creater/cell-helper';\nimport { renderChart } from './scenegraph/graphic/contributions/chart-render-helper';\nimport { restoreMeasureText, setCustomAlphabetCharSet } from './scenegraph/utils/text-measure';\n\n// import { container, loadCanvasPicker } from '@src/vrender';\n// loadCanvasPicker(container);\n\nexport { getDataCellPath } from './tools/get-data-path';\nexport * from './render/jsx';\nexport { getTargetCell } from './event/util';\n\n// export * as VRender from './vrender';\nimport * as VRender from './vrender';\n\nexport const version = \"1.5.7-alpha.0\";\n/**\n * @namespace VTable\n */\nexport {\n /**\n * Types\n * @namespace VTable.TYPES\n */\n TYPES,\n core,\n ListTable,\n ListTableSimple,\n ListTableConstructorOptions,\n PivotTable,\n PivotTableSimple,\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 updateCell,\n renderChart,\n graphicUtil,\n setCustomAlphabetCharSet,\n restoreMeasureText,\n VRender\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\nexport * from './components';\nexport * from './scenegraph/group-creater/cell-type';\n"]}
@@ -23,7 +23,7 @@ const defaultDimension = {
23
23
 
24
24
  export class PivotHeaderLayoutMap {
25
25
  constructor(table, dataset, columnDimensionTree, rowDimensionTree) {
26
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t;
26
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s;
27
27
  this.colIndex = 0, this._showHeader = !0, this.columnHeaderObjs = [], this.rowHeaderObjs = [],
28
28
  this._cornerHeaderCellFullPathIds = [], this._columnHeaderCellFullPathIds = [],
29
29
  this._rowHeaderCellFullPathIds = [], this._rowHeaderCellFullPathIds_FULL = [], this._cornerHeaderCellIds = [],
@@ -51,10 +51,11 @@ export class PivotHeaderLayoutMap {
51
51
  this.rowExpandLevel = null !== (_j = table.options.rowExpandLevel) && void 0 !== _j ? _j : 1,
52
52
  this.rowHierarchyIndent = null !== (_k = table.options.rowHierarchyIndent) && void 0 !== _k ? _k : 20,
53
53
  this.rowHierarchyTextStartAlignment = table.options.rowHierarchyTextStartAlignment,
54
- this.cornerSetting = null !== (_l = table.options.corner) && void 0 !== _l ? _l : {
55
- titleOnDimension: "column"
56
- }, dataset && (this.rowTree = dataset.rowHeaderTree, this.columnTree = dataset.colHeaderTree),
57
- null === (_m = this.indicatorsDefine) || void 0 === _m || _m.forEach((indicator => {
54
+ this.cornerSetting = Object.assign({
55
+ titleOnDimension: "column",
56
+ forceShowHeader: !1
57
+ }, table.options.corner), dataset && (this.rowTree = dataset.rowHeaderTree, this.columnTree = dataset.colHeaderTree),
58
+ null === (_l = this.indicatorsDefine) || void 0 === _l || _l.forEach((indicator => {
58
59
  "string" == typeof indicator ? this.indicatorKeys.push(indicator) : this.indicatorKeys.push(indicator.indicatorKey);
59
60
  })), this.columnDimensionTree = columnDimensionTree, this.rowDimensionTree = rowDimensionTree,
60
61
  this.colDimensionKeys = this.columnDimensionTree.dimensionKeys.valueArr(), this.rowDimensionKeys = this.rowDimensionTree.dimensionKeys.valueArr(),
@@ -68,7 +69,7 @@ export class PivotHeaderLayoutMap {
68
69
  return !1;
69
70
  }))), this.resetColumnHeaderLevelCount(), this._generateColHeaderIds(), this.colIndex = 0,
70
71
  this._generateRowHeaderIds(), this._rowHeaderCellFullPathIds_FULL = transpose(this._rowHeaderCellFullPathIds_FULL),
71
- "tree" === table.options.rowHierarchyType && (null === (_o = this.extensionRows) || void 0 === _o ? void 0 : _o.length) >= 1 && (this.generateExtensionRowTree(),
72
+ "tree" === table.options.rowHierarchyType && (null === (_m = this.extensionRows) || void 0 === _m ? void 0 : _m.length) >= 1 && (this.generateExtensionRowTree(),
72
73
  this.extensionRows.forEach((extensionRow => {
73
74
  const rowKeys = [];
74
75
  extensionRow.rows.forEach((row => {
@@ -76,17 +77,17 @@ export class PivotHeaderLayoutMap {
76
77
  })), this._extensionRowDimensionKeys.push(rowKeys), this.fullRowDimensionKeys = this.fullRowDimensionKeys.concat(rowKeys);
77
78
  }))), this.sharedVar.seqId = Math.max(this.sharedVar.seqId, this._headerObjects.length);
78
79
  let rowDimensionKeys, colDimensionKeys = this.columnDimensionTree.dimensionKeysIncludeVirtual.valueArr();
79
- !this.dataset || 0 !== (null !== (_q = null === (_p = this.dataset.records) || void 0 === _p ? void 0 : _p.length) && void 0 !== _q ? _q : 0) || this.dataset.customColTree || this.dataset.customRowTree || (colDimensionKeys = this.columnsDefine.map((define => "string" == typeof define ? define : define.dimensionKey)),
80
+ !this.dataset || 0 !== (null !== (_p = null === (_o = this.dataset.records) || void 0 === _o ? void 0 : _o.length) && void 0 !== _p ? _p : 0) || this.dataset.customColTree || this.dataset.customRowTree || (colDimensionKeys = this.columnsDefine.map((define => "string" == typeof define ? define : define.dimensionKey)),
80
81
  this.indicatorsAsCol && colDimensionKeys.push(this.indicatorDimensionKey)), colDimensionKeys = this.columnHeaderTitle ? [ "" ].concat(colDimensionKeys) : colDimensionKeys;
81
82
  let extensionRowDimensions = [];
82
- if ("tree" === this.rowHierarchyType && (null === (_r = this.extensionRows) || void 0 === _r ? void 0 : _r.length) >= 1) {
83
+ if ("tree" === this.rowHierarchyType && (null === (_q = this.extensionRows) || void 0 === _q ? void 0 : _q.length) >= 1) {
83
84
  const rowTreeFirstKey = [];
84
85
  rowTreeFirstKey.push(this.rowDimensionKeys[0]), this._extensionRowDimensionKeys.forEach((extensionRowKeys => {
85
86
  rowTreeFirstKey.push(extensionRowKeys[0]);
86
87
  })), extensionRowDimensions = this.extensionRows.reduce(((dimensions, cur) => dimensions.concat(cur.rows)), []),
87
88
  rowDimensionKeys = this.rowHeaderTitle ? [ "" ].concat(rowTreeFirstKey) : rowTreeFirstKey;
88
89
  } else rowDimensionKeys = this.rowDimensionTree.dimensionKeysIncludeVirtual.valueArr(),
89
- !this.dataset || 0 !== (null !== (_t = null === (_s = this.dataset.records) || void 0 === _s ? void 0 : _s.length) && void 0 !== _t ? _t : 0) || this.dataset.customColTree || this.dataset.customRowTree || (rowDimensionKeys = this.rowsDefine.map((define => "string" == typeof define ? define : define.dimensionKey)),
90
+ !this.dataset || 0 !== (null !== (_s = null === (_r = this.dataset.records) || void 0 === _r ? void 0 : _r.length) && void 0 !== _s ? _s : 0) || this.dataset.customColTree || this.dataset.customRowTree || (rowDimensionKeys = this.rowsDefine.map((define => "string" == typeof define ? define : define.dimensionKey)),
90
91
  this.indicatorsAsCol || rowDimensionKeys.push(this.indicatorDimensionKey)), rowDimensionKeys = this.rowHeaderTitle ? [ "" ].concat(rowDimensionKeys) : rowDimensionKeys;
91
92
  this.cornerHeaderObjs = this._addCornerHeaders(colDimensionKeys, rowDimensionKeys, this.columnsDefine.concat(...this.rowsDefine, ...extensionRowDimensions)),
92
93
  this.colIndex = 0, this._headerObjectMap = this._headerObjects.reduce(((o, e) => (o[e.id] = e,
@@ -639,19 +640,18 @@ export class PivotHeaderLayoutMap {
639
640
  return this.columnHeaderLevelCount;
640
641
  }
641
642
  resetColumnHeaderLevelCount() {
642
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
643
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l;
643
644
  if (this.showHeader && this.showColumnHeader) {
644
645
  if (this._table.isPivotChart() && this.indicatorsAsCol && !(null === (_b = null === (_a = this.dataset) || void 0 === _a ? void 0 : _a.colKeys) || void 0 === _b ? void 0 : _b.length) && 0 === (null === (_d = null === (_c = this.columnDimensionTree) || void 0 === _c ? void 0 : _c.tree) || void 0 === _d ? void 0 : _d.level) && !this.hasTwoIndicatorAxes) return void (this.columnHeaderLevelCount = 0);
645
646
  let count = this.indicatorsAsCol && this.hideIndicatorName && this.colDimensionKeys[this.colDimensionKeys.length - 1] === this.indicatorDimensionKey ? this.columnDimensionTree.totalLevel - 1 : this.columnDimensionTree.totalLevel;
646
647
  return this.columnHeaderTitle && (count += 1), this._table.isPivotChart() && this.indicatorsAsCol && !this.hasTwoIndicatorAxes && checkHasCartesianChart(this.indicatorsDefine) && (count -= 1),
647
- 0 !== count || !this.dataset || this.dataset.customColTree || this.dataset.customRowTree ? !this.dataset || 0 !== (null !== (_j = null === (_h = this.dataset.records) || void 0 === _h ? void 0 : _h.length) && void 0 !== _j ? _j : 0) || this.dataset.customColTree || this.dataset.customRowTree || "column" !== this.cornerSetting.titleOnDimension && "all" !== this.cornerSetting.titleOnDimension || (count = null !== (_k = this.columnsDefine.length) && void 0 !== _k ? _k : 0,
648
- !this.hideIndicatorName && this.indicatorsAsCol && count++) : "row" === this.cornerSetting.titleOnDimension ? count = 1 : 0 !== (null !== (_f = null === (_e = this.dataset.records) || void 0 === _e ? void 0 : _e.length) && void 0 !== _f ? _f : 0) || "column" !== this.cornerSetting.titleOnDimension && "all" !== this.cornerSetting.titleOnDimension || (count = null !== (_g = this.columnsDefine.length) && void 0 !== _g ? _g : 0),
649
- void (this.columnHeaderLevelCount = count);
648
+ 0 === count && this.dataset && !(null === (_e = this.dataset.customColTree) || void 0 === _e ? void 0 : _e.length) ? "row" === this.cornerSetting.titleOnDimension && this.cornerSetting.forceShowHeader ? count = 1 : 0 !== (null !== (_g = null === (_f = this.dataset.records) || void 0 === _f ? void 0 : _f.length) && void 0 !== _g ? _g : 0) || "column" !== this.cornerSetting.titleOnDimension && "all" !== this.cornerSetting.titleOnDimension || (count = null !== (_h = this.columnsDefine.length) && void 0 !== _h ? _h : 0) : !this.dataset || 0 !== (null !== (_k = null === (_j = this.dataset.records) || void 0 === _j ? void 0 : _j.length) && void 0 !== _k ? _k : 0) || this.dataset.customColTree || this.dataset.customRowTree || "column" !== this.cornerSetting.titleOnDimension && "all" !== this.cornerSetting.titleOnDimension || (count = null !== (_l = this.columnsDefine.length) && void 0 !== _l ? _l : 0,
649
+ !this.hideIndicatorName && this.indicatorsAsCol && count++), void (this.columnHeaderLevelCount = count);
650
650
  }
651
651
  this.columnHeaderLevelCount = this.indicatorsAsCol ? this.hideIndicatorName ? 0 : 1 : 0;
652
652
  }
653
653
  resetRowHeaderLevelCount() {
654
- var _a, _b, _c, _d, _e, _f, _g;
654
+ var _a, _b, _c, _d, _e, _f, _g, _h;
655
655
  if (this.showHeader && this.showRowHeader) {
656
656
  if ("tree" === this.rowHierarchyType) {
657
657
  const extensionRowCount = null !== (_b = null === (_a = this.extensionRows) || void 0 === _a ? void 0 : _a.length) && void 0 !== _b ? _b : 0;
@@ -660,9 +660,8 @@ export class PivotHeaderLayoutMap {
660
660
  const rowLevelCount = this.rowDimensionTree.totalLevel;
661
661
  let count = rowLevelCount;
662
662
  return this.indicatorsAsCol || this.hideIndicatorName && this.rowDimensionKeys[this.rowDimensionKeys.length - 1] === this.indicatorDimensionKey && (count = rowLevelCount - 1),
663
- this.rowHeaderTitle && (count += 1), 0 !== count || !this.dataset || this.dataset.customColTree || this.dataset.customRowTree ? !this.dataset || 0 !== (null !== (_g = null === (_f = this.dataset.records) || void 0 === _f ? void 0 : _f.length) && void 0 !== _g ? _g : 0) || this.dataset.customColTree || this.dataset.customRowTree || "row" !== this.cornerSetting.titleOnDimension && "all" !== this.cornerSetting.titleOnDimension || (count = this.rowsDefine.length,
664
- this.hideIndicatorName || this.indicatorsAsCol || count++) : "column" === this.cornerSetting.titleOnDimension ? count = 1 : 0 !== (null !== (_d = null === (_c = this.dataset.records) || void 0 === _c ? void 0 : _c.length) && void 0 !== _d ? _d : 0) || "row" !== this.cornerSetting.titleOnDimension && "all" !== this.cornerSetting.titleOnDimension || (count = null !== (_e = this.rowsDefine.length) && void 0 !== _e ? _e : 0),
665
- void (this.rowHeaderLevelCount = count);
663
+ this.rowHeaderTitle && (count += 1), 0 === count && this.dataset && !(null === (_c = this.dataset.customRowTree) || void 0 === _c ? void 0 : _c.length) ? "column" === this.cornerSetting.titleOnDimension && this.cornerSetting.forceShowHeader ? count = 1 : 0 !== (null !== (_e = null === (_d = this.dataset.records) || void 0 === _d ? void 0 : _d.length) && void 0 !== _e ? _e : 0) || "row" !== this.cornerSetting.titleOnDimension && "all" !== this.cornerSetting.titleOnDimension || (count = null !== (_f = this.rowsDefine.length) && void 0 !== _f ? _f : 0) : !this.dataset || 0 !== (null !== (_h = null === (_g = this.dataset.records) || void 0 === _g ? void 0 : _g.length) && void 0 !== _h ? _h : 0) || this.dataset.customColTree || this.dataset.customRowTree || "row" !== this.cornerSetting.titleOnDimension && "all" !== this.cornerSetting.titleOnDimension || (count = this.rowsDefine.length,
664
+ this.hideIndicatorName || this.indicatorsAsCol || count++), void (this.rowHeaderLevelCount = count);
666
665
  }
667
666
  this.rowHeaderLevelCount = this.indicatorsAsCol || this.hideIndicatorName ? 0 : 1;
668
667
  }