@visactor/vtable-calendar 1.14.0 → 1.14.2

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.
@@ -591,6 +591,31 @@
591
591
  return function (target, key) {
592
592
  decorator(target, key, paramIndex);
593
593
  };
594
+ },
595
+ __awaiter$b = undefined && undefined.__awaiter || function (thisArg, _arguments, P, generator) {
596
+ return new (P || (P = Promise))(function (resolve, reject) {
597
+ function fulfilled(value) {
598
+ try {
599
+ step(generator.next(value));
600
+ } catch (e) {
601
+ reject(e);
602
+ }
603
+ }
604
+ function rejected(value) {
605
+ try {
606
+ step(generator.throw(value));
607
+ } catch (e) {
608
+ reject(e);
609
+ }
610
+ }
611
+ function step(result) {
612
+ var value;
613
+ result.done ? resolve(result.value) : (value = result.value, value instanceof P ? value : new P(function (resolve) {
614
+ resolve(value);
615
+ })).then(fulfilled, rejected);
616
+ }
617
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
618
+ });
594
619
  };
595
620
  let DefaultGlobal = class {
596
621
  get env() {
@@ -716,6 +741,11 @@
716
741
  loadBlob(url) {
717
742
  return this._env || this.setEnv("browser"), this.envContribution.loadBlob(url);
718
743
  }
744
+ loadFont(name, source, descriptors) {
745
+ return __awaiter$b(this, void 0, void 0, function* () {
746
+ return this._env || this.setEnv("browser"), this.envContribution.loadFont(name, source, descriptors);
747
+ });
748
+ }
719
749
  isChrome() {
720
750
  return null != this._isChrome || (this._env || this.setEnv("browser"), this._isChrome = "browser" === this._env && navigator.userAgent.indexOf("Chrome") > -1), this._isChrome;
721
751
  }
@@ -1794,19 +1824,10 @@
1794
1824
  }
1795
1825
  function isRotateAABBIntersect(box1, box2) {
1796
1826
  let isDeg = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : !1;
1797
- let ctx = arguments.length > 3 ? arguments[3] : undefined;
1798
1827
  const rect1 = toRect(box1, isDeg),
1799
1828
  rect2 = toRect(box2, isDeg),
1800
- vector = (start, end) => [end.x - start.x, end.y - start.y];
1801
- ctx && (ctx.save(), ctx.fillStyle = "red", ctx.globalAlpha = .6, rect1.forEach((item, index) => {
1802
- 0 === index ? ctx.moveTo(item.x, item.y) : ctx.lineTo(item.x, item.y);
1803
- }), ctx.fill(), ctx.restore(), ctx.save(), ctx.fillStyle = "green", ctx.globalAlpha = .6, rect2.forEach((item, index) => {
1804
- 0 === index ? ctx.moveTo(item.x, item.y) : ctx.lineTo(item.x, item.y);
1805
- }), ctx.fill(), ctx.restore());
1806
- const p1 = getCenterPoint(box1),
1807
- p2 = getCenterPoint(box2);
1808
- ctx && ctx.fillRect(p1.x, p1.y, 2, 2), ctx && ctx.fillRect(p2.x, p2.y, 2, 2);
1809
- const vp1p2 = vector(p1, p2),
1829
+ vector = (start, end) => [end.x - start.x, end.y - start.y],
1830
+ vp1p2 = vector(getCenterPoint(box1), getCenterPoint(box2)),
1810
1831
  AB = vector(rect1[0], rect1[1]),
1811
1832
  BC = vector(rect1[1], rect1[2]),
1812
1833
  A1B1 = vector(rect2[0], rect2[1]),
@@ -2195,7 +2216,8 @@
2195
2216
  class OBBBounds extends Bounds$1 {
2196
2217
  constructor(bounds) {
2197
2218
  let angle = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
2198
- super(bounds), bounds && (this.angle = angle);
2219
+ var _a;
2220
+ super(bounds), bounds && (this.angle = null !== (_a = bounds.angle) && void 0 !== _a ? _a : angle);
2199
2221
  }
2200
2222
  intersects(b) {
2201
2223
  return isRotateAABBIntersect(this, b);
@@ -2208,6 +2230,9 @@
2208
2230
  let angle = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : 0;
2209
2231
  return super.setValue(x1, y1, x2, y2), this.angle = angle, this;
2210
2232
  }
2233
+ clone() {
2234
+ return new OBBBounds(this);
2235
+ }
2211
2236
  }
2212
2237
 
2213
2238
  class Matrix {
@@ -5653,7 +5678,7 @@
5653
5678
  return null;
5654
5679
  }
5655
5680
 
5656
- var __awaiter$8 = undefined && undefined.__awaiter || function (thisArg, _arguments, P, generator) {
5681
+ var __awaiter$a = undefined && undefined.__awaiter || function (thisArg, _arguments, P, generator) {
5657
5682
  return new (P || (P = Promise))(function (resolve, reject) {
5658
5683
  function fulfilled(value) {
5659
5684
  try {
@@ -5723,7 +5748,7 @@
5723
5748
  }
5724
5749
  forEachChildrenAsync(cb) {
5725
5750
  let reverse = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : !1;
5726
- return __awaiter$8(this, void 0, void 0, function* () {
5751
+ return __awaiter$a(this, void 0, void 0, function* () {
5727
5752
  if (reverse) {
5728
5753
  let child = this._lastChild,
5729
5754
  i = 0;
@@ -10353,68 +10378,6 @@
10353
10378
  const defaultRectTextureRenderContribution = defaultBaseTextureRenderContribution;
10354
10379
  const defaultRectBackgroundRenderContribution = defaultBaseBackgroundRenderContribution;
10355
10380
 
10356
- class DefaultImageBackgroundRenderContribution extends DefaultBaseBackgroundRenderContribution {
10357
- constructor() {
10358
- super(...arguments), this.time = BaseRenderContributionTime.beforeFillStroke;
10359
- }
10360
- drawShape(graphic, context, x, y, doFill, doStroke, fVisible, sVisible, graphicAttribute, drawContext, fillCb, strokeCb) {
10361
- const {
10362
- background: background,
10363
- backgroundMode = graphicAttribute.backgroundMode,
10364
- backgroundFit = graphicAttribute.backgroundFit
10365
- } = graphic.attribute;
10366
- if (background) if (graphic.backgroundImg) {
10367
- const res = graphic.resources.get(background);
10368
- if ("success" !== res.state || !res.data) return;
10369
- if (context.save(), graphic.parent && !graphic.transMatrix.onlyTranslate()) {
10370
- const groupAttribute = getTheme(graphic.parent).group,
10371
- {
10372
- scrollX = groupAttribute.scrollX,
10373
- scrollY = groupAttribute.scrollY
10374
- } = graphic.parent.attribute;
10375
- context.setTransformFromMatrix(graphic.parent.globalTransMatrix, !0), context.translate(scrollX, scrollY);
10376
- }
10377
- const b = graphic.AABBBounds;
10378
- this.doDrawImage(context, res.data, b, backgroundMode, backgroundFit), context.restore(), graphic.transMatrix.onlyTranslate() || context.setTransformForCurrent();
10379
- } else if (isObject$6(background)) {
10380
- const {
10381
- stroke: stroke,
10382
- fill: fill,
10383
- lineWidth = 1,
10384
- cornerRadius = 0,
10385
- expandX = 0,
10386
- expandY = 0
10387
- } = background;
10388
- if (!stroke && !fill) return;
10389
- context.beginPath();
10390
- const {
10391
- x: x,
10392
- y: y,
10393
- width: width,
10394
- height: height
10395
- } = getActualPosition(graphic);
10396
- cornerRadius ? createRectPath(context, x - expandX, y - expandY, width + 2 * expandX, height + 2 * expandY, cornerRadius) : context.rect(x - expandX, y - expandY, width + 2 * expandX, height + 2 * expandY), context.globalAlpha = 1, fill && (context.fillStyle = fill, context.fill()), stroke && lineWidth > 0 && (context.lineWidth = lineWidth, context.strokeStyle = stroke, context.stroke());
10397
- } else {
10398
- context.beginPath();
10399
- const b = graphic.AABBBounds;
10400
- context.rect(x, y, b.width(), b.height()), context.fillStyle = background, context.globalAlpha = 1, context.fill();
10401
- }
10402
- }
10403
- }
10404
- function getActualPosition(graphic) {
10405
- const boundsPadding = parsePadding(graphic.attribute.boundsPadding),
10406
- bounds = graphic.AABBBounds;
10407
- let x = bounds.x1,
10408
- y = bounds.y1,
10409
- width = bounds.width(),
10410
- height = bounds.height();
10411
- return isNumber$4(boundsPadding) ? (x += boundsPadding, y += boundsPadding, width -= 2 * boundsPadding, height -= 2 * boundsPadding) : (x += boundsPadding[3], y += boundsPadding[0], width -= boundsPadding[1] + boundsPadding[3], height -= boundsPadding[0] + boundsPadding[2]), {
10412
- x: x,
10413
- y: y,
10414
- width: width,
10415
- height: height
10416
- };
10417
- }
10418
10381
  class DefaultImageRenderContribution extends DefaultRectRenderContribution {
10419
10382
  constructor() {
10420
10383
  super(...arguments), this.time = BaseRenderContributionTime.afterFillStroke, this.useStyle = !0, this.order = 0;
@@ -10424,7 +10387,7 @@
10424
10387
  }
10425
10388
  }
10426
10389
  const defaultImageRenderContribution = new DefaultImageRenderContribution();
10427
- const defaultImageBackgroundRenderContribution = new DefaultImageBackgroundRenderContribution();
10390
+ const defaultImageBackgroundRenderContribution = defaultBaseBackgroundRenderContribution;
10428
10391
 
10429
10392
  class DefaultSymbolRenderContribution {
10430
10393
  constructor() {
@@ -12102,26 +12065,25 @@
12102
12065
  doFill: doFill,
12103
12066
  doStroke: doStroke
12104
12067
  } = data;
12105
- context.setShadowBlendStyle && context.setShadowBlendStyle(image, imageAttribute), this.beforeRenderStep(image, context, x, y, doFill, !1, fVisible, !1, imageAttribute, drawContext, fillCb);
12068
+ if (!url || !image.resources) return;
12069
+ const res = image.resources.get(url);
12070
+ if ("success" !== res.state) return;
12071
+ let needRestore = !1;
12072
+ 0 === cornerRadius || isArray$3(cornerRadius) && cornerRadius.every(num => 0 === num) || (context.beginPath(), createRectPath(context, x, y, width, height, cornerRadius), needRestore = !0), context.setShadowBlendStyle && context.setShadowBlendStyle(image, image.attribute, imageAttribute);
12106
12073
  const _runFill = () => {
12107
12074
  if (doFill) if (fillCb) fillCb(context, image.attribute, imageAttribute);else if (fVisible) {
12108
- if (!url || !image.resources) return;
12109
- const res = image.resources.get(url);
12110
- if ("success" !== res.state) return;
12111
- let needRestore = !1;
12112
- 0 === cornerRadius || isArray$3(cornerRadius) && cornerRadius.every(num => 0 === num) || (context.beginPath(), createRectPath(context, x, y, width, height, cornerRadius), context.save(), context.clip(), needRestore = !0), context.setCommonStyle(image, image.attribute, x, y, imageAttribute);
12075
+ context.setCommonStyle(image, image.attribute, x, y, imageAttribute);
12113
12076
  let repeat = 0;
12114
12077
  if ("repeat" === repeatX && (repeat |= 1), "repeat" === repeatY && (repeat |= 2), repeat) {
12115
12078
  const pattern = context.createPattern(res.data, repeatStr[repeat]);
12116
12079
  context.fillStyle = pattern, context.translate(x, y, !0), context.fillRect(0, 0, width, height), context.translate(-x, -y, !0);
12117
12080
  } else context.drawImage(res.data, x, y, width, height);
12118
- needRestore && context.restore();
12119
12081
  }
12120
12082
  },
12121
12083
  _runStroke = () => {
12122
12084
  doStroke && (strokeCb ? strokeCb(context, image.attribute, imageAttribute) : sVisible && (context.setStrokeStyle(image, image.attribute, originX - x, originY - y, imageAttribute), context.stroke()));
12123
12085
  };
12124
- fillStrokeOrder ? (_runStroke(), _runFill()) : (_runFill(), _runStroke()), this.afterRenderStep(image, context, x, y, doFill, !1, fVisible, !1, imageAttribute, drawContext, fillCb);
12086
+ fillStrokeOrder ? (_runStroke(), needRestore && (context.save(), context.clip()), this.beforeRenderStep(image, context, x, y, doFill, !1, fVisible, !1, imageAttribute, drawContext, fillCb), _runFill(), needRestore && context.restore()) : (needRestore && (context.save(), context.clip()), this.beforeRenderStep(image, context, x, y, doFill, !1, fVisible, !1, imageAttribute, drawContext, fillCb), _runFill(), needRestore && context.restore(), _runStroke()), this.afterRenderStep(image, context, x, y, doFill, !1, fVisible, !1, imageAttribute, drawContext, fillCb);
12125
12087
  }
12126
12088
  draw(image, renderService, drawContext) {
12127
12089
  const {
@@ -15338,7 +15300,7 @@
15338
15300
  container.load(envModules), container.load(textMeasureModules), container.load(layerHandlerModules);
15339
15301
  }
15340
15302
 
15341
- var __awaiter$7 = undefined && undefined.__awaiter || function (thisArg, _arguments, P, generator) {
15303
+ var __awaiter$9 = undefined && undefined.__awaiter || function (thisArg, _arguments, P, generator) {
15342
15304
  return new (P || (P = Promise))(function (resolve, reject) {
15343
15305
  function fulfilled(value) {
15344
15306
  try {
@@ -15411,7 +15373,7 @@
15411
15373
  }
15412
15374
  function foreachAsync(graphic, defaultZIndex, cb) {
15413
15375
  let reverse = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : !1;
15414
- return __awaiter$7(this, void 0, void 0, function* () {
15376
+ return __awaiter$9(this, void 0, void 0, function* () {
15415
15377
  yield graphic.forEachChildrenAsync(cb, reverse);
15416
15378
  });
15417
15379
  }
@@ -15772,7 +15734,7 @@
15772
15734
  decorator(target, key, paramIndex);
15773
15735
  };
15774
15736
  },
15775
- __awaiter$6 = undefined && undefined.__awaiter || function (thisArg, _arguments, P, generator) {
15737
+ __awaiter$8 = undefined && undefined.__awaiter || function (thisArg, _arguments, P, generator) {
15776
15738
  return new (P || (P = Promise))(function (resolve, reject) {
15777
15739
  function fulfilled(value) {
15778
15740
  try {
@@ -15807,7 +15769,7 @@
15807
15769
  }, this.defaultRenderMap.set(this.lineRender.numberType, this.lineRender), this.defaultRenderMap.set(this.areaRender.numberType, this.areaRender);
15808
15770
  }
15809
15771
  draw(renderService, drawContext) {
15810
- return __awaiter$6(this, void 0, void 0, function* () {
15772
+ return __awaiter$8(this, void 0, void 0, function* () {
15811
15773
  if (this.checkingForDrawPromise) return;
15812
15774
  this.lastRenderService = renderService, this.lastDrawContext = drawContext, this.checkingForDrawPromise = this.checkForDraw(drawContext);
15813
15775
  const skipDraw = yield this.checkingForDrawPromise;
@@ -15828,15 +15790,15 @@
15828
15790
  });
15829
15791
  }
15830
15792
  _increaseRender(group, drawContext) {
15831
- return __awaiter$6(this, void 0, void 0, function* () {
15793
+ return __awaiter$8(this, void 0, void 0, function* () {
15832
15794
  this.rendering = !0, yield this._renderIncrementalGroup(group, drawContext);
15833
15795
  });
15834
15796
  }
15835
15797
  _renderIncrementalGroup(group, drawContext) {
15836
- return __awaiter$6(this, void 0, void 0, function* () {
15798
+ return __awaiter$8(this, void 0, void 0, function* () {
15837
15799
  this.count = group.count, yield new Promise(resolve => {
15838
15800
  this.renderItem(group, drawContext, {
15839
- drawingCb: () => __awaiter$6(this, void 0, void 0, function* () {
15801
+ drawingCb: () => __awaiter$8(this, void 0, void 0, function* () {
15840
15802
  if (2 !== group.count) yield foreachAsync(group, DefaultAttribute.zIndex, (item, i) => {
15841
15803
  if (this.status === STATUS.STOP) return !0;
15842
15804
  if (item.isContainer) return !1;
@@ -15857,7 +15819,7 @@
15857
15819
  });
15858
15820
  }
15859
15821
  waitToNextFrame() {
15860
- return __awaiter$6(this, void 0, void 0, function* () {
15822
+ return __awaiter$8(this, void 0, void 0, function* () {
15861
15823
  return new Promise(resolve => {
15862
15824
  this.global.getRequestAnimationFrame()(() => {
15863
15825
  resolve(!1);
@@ -15866,13 +15828,13 @@
15866
15828
  });
15867
15829
  }
15868
15830
  checkForDraw(drawContext) {
15869
- return __awaiter$6(this, void 0, void 0, function* () {
15831
+ return __awaiter$8(this, void 0, void 0, function* () {
15870
15832
  let skip = this.rendering;
15871
15833
  return drawContext.restartIncremental && (skip = !1, yield this.forceStop(), this.resetToInit()), skip;
15872
15834
  });
15873
15835
  }
15874
15836
  forceStop() {
15875
- return __awaiter$6(this, void 0, void 0, function* () {
15837
+ return __awaiter$8(this, void 0, void 0, function* () {
15876
15838
  this.rendering && (this.status = STATUS.STOP, yield new Promise(resolve => {
15877
15839
  this.hooks.completeDraw.tap("stopCb", () => {
15878
15840
  this.status = STATUS.NORMAL, this.hooks.completeDraw.taps = this.hooks.completeDraw.taps.filter(item => "stopCb" !== item.name), resolve(!1);
@@ -15884,11 +15846,11 @@
15884
15846
  this.currFrameStartAt = 0, this.currentIdx = 0;
15885
15847
  }
15886
15848
  renderGroup(group, drawContext) {
15887
- return __awaiter$6(this, void 0, void 0, function* () {
15849
+ return __awaiter$8(this, void 0, void 0, function* () {
15888
15850
  if (!drawContext.break && !1 !== group.attribute.visibleAll) return group.incremental && drawContext.startAtId === group._uid ? (yield this._increaseRender(group, drawContext), void (drawContext.break = !0)) : void (yield new Promise(resolve => {
15889
15851
  this.renderItem(group, drawContext, {
15890
- drawingCb: () => __awaiter$6(this, void 0, void 0, function* () {
15891
- yield foreachAsync(group, DefaultAttribute.zIndex, item => __awaiter$6(this, void 0, void 0, function* () {
15852
+ drawingCb: () => __awaiter$8(this, void 0, void 0, function* () {
15853
+ yield foreachAsync(group, DefaultAttribute.zIndex, item => __awaiter$8(this, void 0, void 0, function* () {
15892
15854
  drawContext.break || item.isContainer && (yield this.renderGroup(item, drawContext));
15893
15855
  })), resolve(!1);
15894
15856
  })
@@ -16688,12 +16650,37 @@
16688
16650
  BaseCanvas.env = "browser";
16689
16651
 
16690
16652
  var __decorate$E = undefined && undefined.__decorate || function (decorators, target, key, desc) {
16691
- var d,
16692
- c = arguments.length,
16693
- r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
16694
- if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
16695
- return c > 3 && r && Object.defineProperty(target, key, r), r;
16696
- };
16653
+ var d,
16654
+ c = arguments.length,
16655
+ r = c < 3 ? target : null === desc ? desc = Object.getOwnPropertyDescriptor(target, key) : desc;
16656
+ if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(decorators, target, key, desc);else for (var i = decorators.length - 1; i >= 0; i--) (d = decorators[i]) && (r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r);
16657
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
16658
+ },
16659
+ __awaiter$7 = undefined && undefined.__awaiter || function (thisArg, _arguments, P, generator) {
16660
+ return new (P || (P = Promise))(function (resolve, reject) {
16661
+ function fulfilled(value) {
16662
+ try {
16663
+ step(generator.next(value));
16664
+ } catch (e) {
16665
+ reject(e);
16666
+ }
16667
+ }
16668
+ function rejected(value) {
16669
+ try {
16670
+ step(generator.throw(value));
16671
+ } catch (e) {
16672
+ reject(e);
16673
+ }
16674
+ }
16675
+ function step(result) {
16676
+ var value;
16677
+ result.done ? resolve(result.value) : (value = result.value, value instanceof P ? value : new P(function (resolve) {
16678
+ resolve(value);
16679
+ })).then(fulfilled, rejected);
16680
+ }
16681
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
16682
+ });
16683
+ };
16697
16684
  let BaseEnvContribution = class {
16698
16685
  configure(service) {
16699
16686
  service.env === this.type && service.setActiveEnvContribution(this);
@@ -16762,6 +16749,13 @@
16762
16749
  left: 0
16763
16750
  };
16764
16751
  }
16752
+ loadFont(font, source, descriptors) {
16753
+ return __awaiter$7(this, void 0, void 0, function* () {
16754
+ return {
16755
+ loadState: "fail"
16756
+ };
16757
+ });
16758
+ }
16765
16759
  };
16766
16760
  BaseEnvContribution = __decorate$E([injectable()], BaseEnvContribution);
16767
16761
 
@@ -16997,7 +16991,7 @@
16997
16991
  const fVisible = fillVisible(opacity, fillOpacity, !0),
16998
16992
  sVisible = fillVisible(opacity, strokeOpacity, !0);
16999
16993
  if (!fVisible) return;
17000
- context.translate(x, y), this.beforeRenderStep(richtext, context, x, y, fVisible, sVisible, fVisible, sVisible, richtextAttribute, drawContext);
16994
+ context.setShadowBlendStyle && context.setShadowBlendStyle(richtext, richtext.attribute, richtextAttribute), context.translate(x, y), this.beforeRenderStep(richtext, context, x, y, fVisible, sVisible, fVisible, sVisible, richtextAttribute, drawContext);
17001
16995
  richtext.getFrameCache().draw(context, this.drawIcon), this.afterRenderStep(richtext, context, x, y, fVisible, sVisible, fVisible, sVisible, richtextAttribute, drawContext);
17002
16996
  }
17003
16997
  drawIcon(icon, context, x, y, baseline) {
@@ -17375,10 +17369,17 @@
17375
17369
  this.render(), this.bindEvents();
17376
17370
  });
17377
17371
  }
17378
- setAttribute(key, value, forceUpdateTag) {
17372
+ setAttribute(key, value, forceUpdateTag, context) {
17373
+ const params = this.onBeforeAttributeUpdate && this.onBeforeAttributeUpdate({
17374
+ [key]: value
17375
+ }, this.attribute, key, context);
17376
+ if (params) return this._setAttributes(params, forceUpdateTag);
17379
17377
  isPlainObject$3(this.attribute[key]) && isPlainObject$3(value) && !isFunction$3(this.attribute[key]) && !isFunction$3(value) ? merge$1(this.attribute[key], value) : this.attribute[key] = value, GROUP_ATTRIBUTES.includes(key) || this.render(), this.valid = this.isValid(), this.updateShapeAndBoundsTagSetted() || !forceUpdateTag && !this.needUpdateTag(key) ? this.addUpdateBoundTag() : this.addUpdateShapeAndBoundsTag(), this.addUpdatePositionTag(), this.onAttributeUpdate();
17380
17378
  }
17381
- setAttributes(params, forceUpdateTag) {
17379
+ setAttributes(params, forceUpdateTag, context) {
17380
+ return params = this.onBeforeAttributeUpdate && this.onBeforeAttributeUpdate(params, this.attribute, null, context) || params, this._setAttributes(params, forceUpdateTag);
17381
+ }
17382
+ _setAttributes(params, forceUpdateTag) {
17382
17383
  const keys = Object.keys(params);
17383
17384
  this._mergeAttributes(params, keys), keys.every(key => GROUP_ATTRIBUTES.includes(key)) || this.render(), this.valid = this.isValid(), this.updateShapeAndBoundsTagSetted() || !forceUpdateTag && !this.needUpdateTags(keys) ? this.addUpdateBoundTag() : this.addUpdateShapeAndBoundsTag(), this.addUpdatePositionTag(), this.onAttributeUpdate();
17384
17385
  }
@@ -17685,6 +17686,7 @@
17685
17686
  });
17686
17687
  }
17687
17688
  emitEvent(type, e) {
17689
+ if (!this.element) return;
17688
17690
  const listeners = this.element._events[WILDCARD];
17689
17691
  if (listeners) if ("fn" in listeners) listeners.fn.call(listeners.context, e, type);else for (let i = 0, j = listeners.length; i < j && !e.propagationImmediatelyStopped; i++) listeners[i].fn.call(listeners[i].context, e, type);
17690
17692
  this.emit(type, e);
@@ -18561,6 +18563,31 @@
18561
18563
  },
18562
18564
  __metadata$j = undefined && undefined.__metadata || function (k, v) {
18563
18565
  if ("object" == typeof Reflect && "function" == typeof Reflect.metadata) return Reflect.metadata(k, v);
18566
+ },
18567
+ __awaiter$6 = undefined && undefined.__awaiter || function (thisArg, _arguments, P, generator) {
18568
+ return new (P || (P = Promise))(function (resolve, reject) {
18569
+ function fulfilled(value) {
18570
+ try {
18571
+ step(generator.next(value));
18572
+ } catch (e) {
18573
+ reject(e);
18574
+ }
18575
+ }
18576
+ function rejected(value) {
18577
+ try {
18578
+ step(generator.throw(value));
18579
+ } catch (e) {
18580
+ reject(e);
18581
+ }
18582
+ }
18583
+ function step(result) {
18584
+ var value;
18585
+ result.done ? resolve(result.value) : (value = result.value, value instanceof P ? value : new P(function (resolve) {
18586
+ resolve(value);
18587
+ })).then(fulfilled, rejected);
18588
+ }
18589
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
18590
+ });
18564
18591
  };
18565
18592
  class DynamicB {
18566
18593
  get x1() {
@@ -18756,6 +18783,19 @@
18756
18783
  left: actualLeft
18757
18784
  };
18758
18785
  }
18786
+ loadFont(font, source, descriptors) {
18787
+ return __awaiter$6(this, void 0, void 0, function* () {
18788
+ return new FontFace(font, isString$4(source) ? `url(${source})` : source, descriptors).load().then(function (loadedFont) {
18789
+ return document.fonts.add(loadedFont), {
18790
+ loadState: "success"
18791
+ };
18792
+ }).catch(function (error) {
18793
+ return {
18794
+ loadState: "fail"
18795
+ };
18796
+ });
18797
+ });
18798
+ }
18759
18799
  };
18760
18800
  BrowserEnvContribution = __decorate$v([injectable(), __metadata$j("design:paramtypes", [])], BrowserEnvContribution);
18761
18801
 
@@ -21104,6 +21144,52 @@
21104
21144
  zIndex: 1
21105
21145
  };
21106
21146
 
21147
+ function genNormalBounds(item) {
21148
+ const bounds = item.AABBBounds;
21149
+ return {
21150
+ x1: bounds.x1,
21151
+ x2: bounds.x2,
21152
+ y1: bounds.y1,
21153
+ y2: bounds.y2,
21154
+ centerX: item.attribute.x,
21155
+ centerY: item.attribute.y,
21156
+ angle: item.attribute.angle
21157
+ };
21158
+ }
21159
+ function genRotateBounds(items) {
21160
+ items.forEach(item => {
21161
+ if (item.rotatedBounds || !item.attribute.angle) return;
21162
+ const bounds = genNormalBounds(item),
21163
+ rotatedCenter = rotatePoint({
21164
+ x: item.attribute.x,
21165
+ y: item.attribute.y
21166
+ }, bounds.angle, {
21167
+ x: bounds.centerX,
21168
+ y: bounds.centerY
21169
+ }),
21170
+ deltaX = rotatedCenter.x - bounds.centerX,
21171
+ deltaY = rotatedCenter.y - bounds.centerY;
21172
+ bounds.x1 += deltaX, bounds.x2 += deltaX, bounds.y1 += deltaY, bounds.y2 += deltaY, bounds.centerX += deltaX, bounds.centerY += deltaY, item.rotatedBounds = bounds;
21173
+ });
21174
+ }
21175
+ function itemIntersect(item1, item2) {
21176
+ var _a, _b;
21177
+ return (null === (_a = item1.OBBBounds) || void 0 === _a ? void 0 : _a.empty()) || (null === (_b = item2.OBBBounds) || void 0 === _b ? void 0 : _b.empty()) ? isRectIntersect(item1.AABBBounds, item2.AABBBounds, !1) && (!item1.rotatedBounds || !item2.rotatedBounds || isRotateAABBIntersect(item1.rotatedBounds, item2.rotatedBounds, !0)) : item1.OBBBounds.intersects(item2.OBBBounds);
21178
+ }
21179
+ const DELTA_ANGLE = Math.sin(Math.PI / 10);
21180
+ function isAngleVertical(angle) {
21181
+ let delta = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : DELTA_ANGLE;
21182
+ const hasAngle = !isNil$3(angle) && 0 !== angle,
21183
+ cos = hasAngle ? Math.cos(angle) : 1;
21184
+ return hasAngle && Math.abs(cos) <= delta;
21185
+ }
21186
+ function isAngleHorizontal(angle) {
21187
+ let delta = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : DELTA_ANGLE;
21188
+ const hasAngle = !isNil$3(angle) && 0 !== angle,
21189
+ sin = hasAngle ? Math.sin(angle) : 0;
21190
+ return !hasAngle || Math.abs(sin) <= delta;
21191
+ }
21192
+
21107
21193
  function getCircleLabelPosition(tickPosition, tickVector) {
21108
21194
  return {
21109
21195
  x: tickPosition.x + tickVector[0],
@@ -21151,9 +21237,11 @@
21151
21237
  return getCircleLabelPosition(labelPoint, getCircleVerticalVector(labelOffset || 1, labelPoint, center, inside));
21152
21238
  }
21153
21239
  function textIntersect(textA, textB, sep) {
21154
- let a = textA.OBBBounds,
21155
- b = textB.OBBBounds;
21156
- return a && b && !a.empty() && !b.empty() ? a.intersects(b) : (a = textA.AABBBounds, b = textB.AABBBounds, sep > Math.max(b.x1 - a.x2, a.x1 - b.x2, b.y1 - a.y2, a.y1 - b.y2));
21240
+ var _a;
21241
+ let a, b;
21242
+ const angle = null === (_a = textA.attribute) || void 0 === _a ? void 0 : _a.angle,
21243
+ isAABBIntersects = (textA, textB, sep) => (a = textA.AABBBounds, b = textB.AABBBounds, sep > Math.max(b.x1 - a.x2, a.x1 - b.x2, b.y1 - a.y2, a.y1 - b.y2));
21244
+ return isAngleHorizontal(angle, Number.EPSILON) ? isAABBIntersects(textA, textB, sep) : (a = textA.OBBBounds, b = textB.OBBBounds, !a || !b || a.empty() || b.empty() ? isAABBIntersects(textA, textB, sep) : a.intersects(b));
21157
21245
  }
21158
21246
  function hasOverlap(items, pad) {
21159
21247
  for (let b, i = 1, n = items.length, a = items[0]; i < n; a = b, ++i) if (b = items[i], textIntersect(a, b, pad)) return !0;
@@ -21323,7 +21411,10 @@
21323
21411
  isFunction$3(labelState[key]) && (labelState[key] = labelState[key](item, index, data, layer));
21324
21412
  }), text.states = labelState;
21325
21413
  }
21326
- labelGroup.add(text);
21414
+ text.data = Object.assign(Object.assign({}, item), {
21415
+ index: index,
21416
+ layer: layer
21417
+ }), labelGroup.add(text);
21327
21418
  }), labelGroup;
21328
21419
  }
21329
21420
  renderTitle(container) {
@@ -21537,50 +21628,6 @@
21537
21628
  });
21538
21629
  }
21539
21630
 
21540
- function genNormalBounds(item) {
21541
- const bounds = item.AABBBounds;
21542
- return {
21543
- x1: bounds.x1,
21544
- x2: bounds.x2,
21545
- y1: bounds.y1,
21546
- y2: bounds.y2,
21547
- centerX: item.attribute.x,
21548
- centerY: item.attribute.y,
21549
- angle: item.attribute.angle
21550
- };
21551
- }
21552
- function genRotateBounds(items) {
21553
- items.forEach(item => {
21554
- if (item.rotatedBounds || !item.attribute.angle) return;
21555
- const bounds = genNormalBounds(item),
21556
- rotatedCenter = rotatePoint({
21557
- x: item.attribute.x,
21558
- y: item.attribute.y
21559
- }, bounds.angle, {
21560
- x: bounds.centerX,
21561
- y: bounds.centerY
21562
- }),
21563
- deltaX = rotatedCenter.x - bounds.centerX,
21564
- deltaY = rotatedCenter.y - bounds.centerY;
21565
- bounds.x1 += deltaX, bounds.x2 += deltaX, bounds.y1 += deltaY, bounds.y2 += deltaY, bounds.centerX += deltaX, bounds.centerY += deltaY, item.rotatedBounds = bounds;
21566
- });
21567
- }
21568
- function itemIntersect(item1, item2) {
21569
- var _a, _b;
21570
- return (null === (_a = item1.OBBBounds) || void 0 === _a ? void 0 : _a.empty()) || (null === (_b = item2.OBBBounds) || void 0 === _b ? void 0 : _b.empty()) ? isRectIntersect(item1.AABBBounds, item2.AABBBounds, !1) && (!item1.rotatedBounds || !item2.rotatedBounds || isRotateAABBIntersect(item1.rotatedBounds, item2.rotatedBounds, !0)) : item1.OBBBounds.intersects(item2.OBBBounds);
21571
- }
21572
- const DELTA_ANGLE = Math.sin(Math.PI / 10);
21573
- function isAngleVertical(angle) {
21574
- const hasAngle = !isNil$3(angle) && 0 !== angle,
21575
- cos = hasAngle ? Math.cos(angle) : 1;
21576
- return hasAngle && Math.abs(cos) <= DELTA_ANGLE;
21577
- }
21578
- function isAngleHorizontal(angle) {
21579
- const hasAngle = !isNil$3(angle) && 0 !== angle,
21580
- sin = hasAngle ? Math.sin(angle) : 0;
21581
- return !hasAngle || Math.abs(sin) <= DELTA_ANGLE;
21582
- }
21583
-
21584
21631
  function autoRotate(items, rotateConfig) {
21585
21632
  if (isEmpty$1(items)) return;
21586
21633
  const {
@@ -22816,7 +22863,7 @@
22816
22863
  breakData: breakData
22817
22864
  } = op;
22818
22865
  let scaleTicks;
22819
- if (isValid$3(tickStep)) scaleTicks = scale.stepTicks(tickStep);else if (isValid$3(forceTickCount)) scaleTicks = getScaleTicks(op, scale, forceTickCount, (count, subDomain) => subDomain && subDomain.length ? scale.domain(subDomain, !0).forceTicks(count) : scale.forceTicks(count));else if ("d3" === op.tickMode) {
22866
+ if (isValid$3(tickStep)) ticks = scale.stepTicks(tickStep), breakDomains = breakData && breakData() ? breakData().breakDomains : null, scaleTicks = breakDomains && breakDomains.length ? ticks.filter(tick => breakDomains.every(breakDomain => tick < breakDomain[0] || tick > breakDomain[1])) : ticks;else if (isValid$3(forceTickCount)) scaleTicks = getScaleTicks(op, scale, forceTickCount, (count, subDomain) => subDomain && subDomain.length ? scale.domain(subDomain, !0).forceTicks(count) : scale.forceTicks(count));else if ("d3" === op.tickMode) {
22820
22867
  const count = null !== (_a = isFunction$3(tickCount) ? tickCount({
22821
22868
  axisLength: rangeSize,
22822
22869
  labelStyle: labelStyle
@@ -22840,19 +22887,30 @@
22840
22887
  customTicks: customTicks
22841
22888
  }));
22842
22889
  }
22890
+ var ticks, breakDomains;
22843
22891
  const domain = scale.domain();
22844
22892
  if (op.labelFirstVisible && domain[0] !== scaleTicks[0] && !scaleTicks.includes(domain[0]) && scaleTicks.unshift(domain[0]), op.labelLastVisible && domain[domain.length - 1] !== scaleTicks[scaleTicks.length - 1] && !scaleTicks.includes(domain[domain.length - 1]) && scaleTicks.push(domain[domain.length - 1]), op.sampling && scaleTicks.length > 1 && ("cartesian" === op.coordinateType || "polar" === op.coordinateType && "radius" === op.axisOrientType)) {
22845
22893
  const {
22846
- labelGap = 4,
22847
- labelFlush: labelFlush
22848
- } = op;
22849
- let items = getCartesianLabelBounds(scale, scaleTicks, op).map((bounds, i) => ({
22894
+ labelGap = 4,
22895
+ labelFlush: labelFlush
22896
+ } = op,
22897
+ MIN_FONT_SIZE = 6;
22898
+ let items;
22899
+ if (scaleTicks.length * MIN_FONT_SIZE > rangeSize) {
22900
+ const samplingScaleTicks = [],
22901
+ step = Math.floor(scaleTicks.length * MIN_FONT_SIZE / rangeSize);
22902
+ scaleTicks.forEach((tick, index) => {
22903
+ index % step != 0 && index !== scaleTicks.length - 1 || samplingScaleTicks.push(tick);
22904
+ }), items = getCartesianLabelBounds(scale, samplingScaleTicks, op).map((bounds, i) => ({
22905
+ AABBBounds: bounds,
22906
+ value: samplingScaleTicks[i]
22907
+ }));
22908
+ } else items = getCartesianLabelBounds(scale, scaleTicks, op).map((bounds, i) => ({
22850
22909
  AABBBounds: bounds,
22851
22910
  value: scaleTicks[i]
22852
22911
  }));
22853
- const source = [...items],
22854
- firstSourceItem = source[0],
22855
- lastSourceItem = last$1(source),
22912
+ const firstSourceItem = items[0],
22913
+ lastSourceItem = last$1(items),
22856
22914
  samplingMethod = breakData && breakData() ? methods.greedy : methods.parity;
22857
22915
  for (; items.length >= 3 && hasOverlap(items, labelGap);) items = samplingMethod(items, labelGap);
22858
22916
  const checkFirst = op.labelFirstVisible;
@@ -23422,7 +23480,8 @@
23422
23480
  } = this.attribute,
23423
23481
  {
23424
23482
  spaceCol = DEFAULT_ITEM_SPACE_COL,
23425
- spaceRow = DEFAULT_ITEM_SPACE_ROW
23483
+ spaceRow = DEFAULT_ITEM_SPACE_ROW,
23484
+ verticalAlign = "middle"
23426
23485
  } = itemAttrs,
23427
23486
  itemsContainer = this._itemsContainer,
23428
23487
  {
@@ -23441,7 +23500,9 @@
23441
23500
  startY: startY,
23442
23501
  pages: pages
23443
23502
  } = this._itemContext,
23444
- lastItemWidth = 0;
23503
+ lastItemWidth = 0,
23504
+ lastLineHeight = 0;
23505
+ const lastLineItemGroup = [];
23445
23506
  for (let index = startIndex, len = legendItems.length; index < len && !(lazyload && pages > this._itemContext.currentPage * maxPages); index++) {
23446
23507
  lazyload && (this._itemContext.startIndex = index + 1), item = legendItems[index], item.id || (item.id = item.label), item.index = index;
23447
23508
  let isSelected = !0;
@@ -23449,15 +23510,23 @@
23449
23510
  const itemGroup = this._renderEachItem(item, isSelected, index, legendItems),
23450
23511
  itemWidth = itemGroup.attribute.width,
23451
23512
  itemHeight = itemGroup.attribute.height;
23452
- this._itemHeight = Math.max(this._itemHeight, itemHeight), maxWidthInCol = Math.max(itemWidth, maxWidthInCol), this._itemMaxWidth = Math.max(itemWidth, this._itemMaxWidth), isHorizontal ? (isValid$3(maxWidth) && (isScrollbar && autoPage ? (pages = Math.ceil((startX + itemWidth) / maxWidth), doWrap = pages > 1) : startX + itemWidth > maxWidth && (doWrap = !0, startX > 0 && (pages += 1, startX = 0, startY += itemHeight + spaceRow))), 0 === startX && 0 === startY || itemGroup.setAttributes({
23513
+ this._itemHeight = Math.max(this._itemHeight, itemHeight), maxWidthInCol = Math.max(itemWidth, maxWidthInCol), this._itemMaxWidth = Math.max(itemWidth, this._itemMaxWidth), isHorizontal ? (isValid$3(maxWidth) && (isScrollbar && autoPage ? (pages = Math.ceil((startX + itemWidth) / maxWidth), doWrap = pages > 1) : startX + itemWidth > maxWidth && (doWrap = !0, startX > 0 && ("middle" !== verticalAlign && "bottom" !== verticalAlign || lastLineItemGroup.forEach(i => {
23514
+ i.setAttributes({
23515
+ y: i.attribute.y + (lastLineHeight - i.attribute.height) / ("middle" === verticalAlign ? 2 : 1)
23516
+ });
23517
+ }), pages += 1, startX = 0, startY += lastLineHeight + spaceRow, lastLineHeight = 0, lastLineItemGroup.length = 0))), 0 === startX && 0 === startY || itemGroup.setAttributes({
23453
23518
  x: startX,
23454
23519
  y: startY
23455
- }), startX += spaceCol + itemWidth) : (isValid$3(maxHeight) && (isScrollbar && autoPage ? (pages = Math.ceil((startY + itemHeight) / maxHeight), doWrap = pages > 1) : maxHeight <= itemHeight ? (pages += 1, doWrap = !0, startY = 0, index > 0 && (startX += lastItemWidth + spaceCol)) : maxHeight < startY + itemHeight && (pages += 1, doWrap = !0, startY = 0, startX += maxWidthInCol + spaceCol, maxWidthInCol = 0)), 0 === startX && 0 === startY || itemGroup.setAttributes({
23520
+ }), startX += spaceCol + itemWidth, lastLineHeight = Math.max(lastLineHeight, itemHeight), lastLineItemGroup.push(itemGroup)) : (isValid$3(maxHeight) && (isScrollbar && autoPage ? (pages = Math.ceil((startY + itemHeight) / maxHeight), doWrap = pages > 1) : maxHeight <= itemHeight ? (pages += 1, doWrap = !0, startY = 0, index > 0 && (startX += lastItemWidth + spaceCol)) : maxHeight < startY + itemHeight && (pages += 1, doWrap = !0, startY = 0, startX += maxWidthInCol + spaceCol, maxWidthInCol = 0)), 0 === startX && 0 === startY || itemGroup.setAttributes({
23456
23521
  x: startX,
23457
23522
  y: startY
23458
23523
  }), startY += spaceRow + itemHeight), itemsContainer.add(itemGroup), lastItemWidth = itemWidth;
23459
23524
  }
23460
- return this._itemContext.doWrap = doWrap, this._itemContext.startX = startX, this._itemContext.startY = startY, this._itemContext.maxWidthInCol = maxWidthInCol, this._itemContext.pages = pages, this._itemContext.maxPages = maxPages, isScrollbar && (this._itemContext.totalPage = pages), lazyload || (this._itemContext.startIndex = legendItems.length), this._itemContext;
23525
+ return !isHorizontal || "middle" !== verticalAlign && "bottom" !== verticalAlign || lastLineItemGroup.forEach(i => {
23526
+ i.setAttributes({
23527
+ y: i.attribute.y + (lastLineHeight - i.attribute.height) / ("middle" === verticalAlign ? 2 : 1)
23528
+ });
23529
+ }), this._itemContext.doWrap = doWrap, this._itemContext.startX = startX, this._itemContext.startY = startY, this._itemContext.maxWidthInCol = maxWidthInCol, this._itemContext.pages = pages, this._itemContext.maxPages = maxPages, isScrollbar && (this._itemContext.totalPage = pages), lazyload || (this._itemContext.startIndex = legendItems.length), this._itemContext;
23461
23530
  }
23462
23531
  _renderContent() {
23463
23532
  const {
@@ -34715,8 +34784,7 @@
34715
34784
  for (let col = 0; col < scene.table.colCount; col++) {
34716
34785
  const distHeight = maxHeight,
34717
34786
  cell = scene.highPerformanceGetCell(col, row);
34718
- if ("empty" === cell.role) return;
34719
- updateCellHeightForRow(scene, cell, col, row, distHeight, distHeight - cell.attribute.height, scene.table.isHeader(col, row));
34787
+ "empty" !== cell.role && updateCellHeightForRow(scene, cell, col, row, distHeight, distHeight - cell.attribute.height, scene.table.isHeader(col, row));
34720
34788
  }
34721
34789
  }
34722
34790
 
@@ -36495,22 +36563,22 @@
36495
36563
  if (strokeTop) {
36496
36564
  const deltaLeft = (isWidthNumber ? widthInfo.width : strokeArrayWidth[0]) / 2,
36497
36565
  deltaRight = (isWidthNumber ? widthInfo.width : strokeArrayWidth[0]) / 2;
36498
- isPart && Array.isArray(part[0]) ? (context.moveTo(x - deltaLeft + (width + deltaLeft + deltaRight) * part[0][0], y), context.lineTo(x - deltaLeft + (width + deltaLeft + deltaRight) * (part[0][1] - part[0][0]), y), context.moveTo(x + width + deltaRight, y)) : (context.moveTo(x - deltaLeft, y), context.lineTo(x + width + deltaRight, y)), (isSplitDraw || isDash) && (strokeArrayColor && strokeArrayColor[0] ? context.strokeStyle = strokeArrayColor[0] : context.strokeStyle = "transparent", isWidthNumber || (context.lineWidth = strokeArrayWidth[0]), context.lineDashOffset = context.currentMatrix.e / context.currentMatrix.a, isDash && context.setLineDash(null !== (_a = lineDash[0]) && void 0 !== _a ? _a : []), context.stroke(), context.beginPath(), context.moveTo(x + width, y));
36566
+ isPart && Array.isArray(part[0]) ? (context.moveTo(x - deltaLeft + (width + deltaLeft + deltaRight) * part[0][0], y), context.lineTo(x - deltaLeft + (width + deltaLeft + deltaRight) * (part[0][1] - part[0][0]), y), context.moveTo(x + width + deltaRight, y)) : (context.moveTo(x - deltaLeft, y), context.lineTo(x + width + deltaRight, y)), (isSplitDraw || isDash) && (strokeArrayColor && strokeArrayColor[0] ? context.strokeStyle = strokeArrayColor[0] : strokeArrayColor && !strokeArrayColor[0] && (context.strokeStyle = "transparent"), isWidthNumber || (context.lineWidth = strokeArrayWidth[0]), context.lineDashOffset = context.currentMatrix.e / context.currentMatrix.a, isDash && context.setLineDash(null !== (_a = lineDash[0]) && void 0 !== _a ? _a : []), context.stroke(), context.beginPath(), context.moveTo(x + width, y));
36499
36567
  } else context.moveTo(x + width, y);
36500
36568
  if (strokeRight) {
36501
36569
  const deltaTop = (isWidthNumber ? widthInfo.width : strokeArrayWidth[1]) / 2,
36502
36570
  deltaBottom = (isWidthNumber ? widthInfo.width : strokeArrayWidth[1]) / 2;
36503
- isPart && Array.isArray(part[1]) ? (context.moveTo(x + width, y - deltaTop + height * part[1][0]), context.lineTo(x + width, y - deltaTop + (height + deltaTop + deltaBottom) * (part[1][1] - part[1][0])), context.moveTo(x + width, y + height + deltaBottom)) : (context.moveTo(x + width, y - deltaTop), context.lineTo(x + width, y + height + deltaBottom)), (isSplitDraw || isDash) && (strokeArrayColor && strokeArrayColor[1] ? context.strokeStyle = strokeArrayColor[1] : context.strokeStyle = "transparent", isWidthNumber || (context.lineWidth = strokeArrayWidth[1]), context.lineDashOffset = context.currentMatrix.f / context.currentMatrix.d, isDash && context.setLineDash(null !== (_b = lineDash[1]) && void 0 !== _b ? _b : []), context.stroke(), context.beginPath(), context.moveTo(x + width, y + height));
36571
+ isPart && Array.isArray(part[1]) ? (context.moveTo(x + width, y - deltaTop + height * part[1][0]), context.lineTo(x + width, y - deltaTop + (height + deltaTop + deltaBottom) * (part[1][1] - part[1][0])), context.moveTo(x + width, y + height + deltaBottom)) : (context.moveTo(x + width, y - deltaTop), context.lineTo(x + width, y + height + deltaBottom)), (isSplitDraw || isDash) && (strokeArrayColor && strokeArrayColor[1] ? context.strokeStyle = strokeArrayColor[1] : strokeArrayColor && !strokeArrayColor[1] && (context.strokeStyle = "transparent"), isWidthNumber || (context.lineWidth = strokeArrayWidth[1]), context.lineDashOffset = context.currentMatrix.f / context.currentMatrix.d, isDash && context.setLineDash(null !== (_b = lineDash[1]) && void 0 !== _b ? _b : []), context.stroke(), context.beginPath(), context.moveTo(x + width, y + height));
36504
36572
  } else context.moveTo(x + width, y + height);
36505
36573
  if (strokeBottom) {
36506
36574
  const deltaLeft = (isWidthNumber ? widthInfo.width : strokeArrayWidth[2]) / 2,
36507
36575
  deltaRight = (isWidthNumber ? widthInfo.width : strokeArrayWidth[2]) / 2;
36508
- isPart && Array.isArray(part[2]) ? (context.moveTo(x - deltaLeft + (width + deltaLeft + deltaRight) * part[2][0], y + height), context.lineTo(x - deltaLeft + (width + deltaLeft + deltaRight) * (part[2][1] - part[2][0]), y + height), context.moveTo(x - deltaLeft, y + height)) : (context.moveTo(x - deltaLeft, y + height), context.lineTo(x + width + deltaRight, y + height)), (isSplitDraw || isDash) && (strokeArrayColor && strokeArrayColor[2] ? context.strokeStyle = strokeArrayColor[2] : context.strokeStyle = "transparent", isWidthNumber || (context.lineWidth = strokeArrayWidth[2]), context.lineDashOffset = context.currentMatrix.e / context.currentMatrix.a, isDash && context.setLineDash(null !== (_c = lineDash[2]) && void 0 !== _c ? _c : []), context.stroke(), context.beginPath(), context.moveTo(x, y + height));
36576
+ isPart && Array.isArray(part[2]) ? (context.moveTo(x - deltaLeft + (width + deltaLeft + deltaRight) * part[2][0], y + height), context.lineTo(x - deltaLeft + (width + deltaLeft + deltaRight) * (part[2][1] - part[2][0]), y + height), context.moveTo(x - deltaLeft, y + height)) : (context.moveTo(x - deltaLeft, y + height), context.lineTo(x + width + deltaRight, y + height)), (isSplitDraw || isDash) && (strokeArrayColor && strokeArrayColor[2] ? context.strokeStyle = strokeArrayColor[2] : strokeArrayColor && !strokeArrayColor[2] && (context.strokeStyle = "transparent"), isWidthNumber || (context.lineWidth = strokeArrayWidth[2]), context.lineDashOffset = context.currentMatrix.e / context.currentMatrix.a, isDash && context.setLineDash(null !== (_c = lineDash[2]) && void 0 !== _c ? _c : []), context.stroke(), context.beginPath(), context.moveTo(x, y + height));
36509
36577
  } else context.moveTo(x, y + height);
36510
36578
  if (strokeLeft) {
36511
36579
  const deltaTop = (isWidthNumber ? widthInfo.width : strokeArrayWidth[3]) / 2,
36512
36580
  deltaBottom = (isWidthNumber ? widthInfo.width : strokeArrayWidth[3]) / 2;
36513
- isPart && Array.isArray(part[3]) ? (context.moveTo(x, y - deltaTop + (height + deltaTop + deltaBottom) * part[3][0]), context.lineTo(x, y - deltaTop + (height + deltaTop + deltaBottom) * (part[3][1] - part[3][0])), context.moveTo(x, y - deltaTop)) : (context.moveTo(x, y - deltaTop), context.lineTo(x, y + height + deltaBottom)), (isSplitDraw || isDash) && (strokeArrayColor && strokeArrayColor[3] ? context.strokeStyle = strokeArrayColor[3] : context.strokeStyle = "transparent", isWidthNumber || (context.lineWidth = strokeArrayWidth[3]), context.lineDashOffset = context.currentMatrix.f / context.currentMatrix.d, isDash && context.setLineDash(null !== (_d = lineDash[3]) && void 0 !== _d ? _d : []), context.stroke(), context.beginPath(), context.moveTo(x, y));
36581
+ isPart && Array.isArray(part[3]) ? (context.moveTo(x, y - deltaTop + (height + deltaTop + deltaBottom) * part[3][0]), context.lineTo(x, y - deltaTop + (height + deltaTop + deltaBottom) * (part[3][1] - part[3][0])), context.moveTo(x, y - deltaTop)) : (context.moveTo(x, y - deltaTop), context.lineTo(x, y + height + deltaBottom)), (isSplitDraw || isDash) && (strokeArrayColor && strokeArrayColor[3] ? context.strokeStyle = strokeArrayColor[3] : strokeArrayColor && !strokeArrayColor[3] && (context.strokeStyle = "transparent"), isWidthNumber || (context.lineWidth = strokeArrayWidth[3]), context.lineDashOffset = context.currentMatrix.f / context.currentMatrix.d, isDash && context.setLineDash(null !== (_d = lineDash[3]) && void 0 !== _d ? _d : []), context.stroke(), context.beginPath(), context.moveTo(x, y));
36514
36582
  } else context.moveTo(x, y);
36515
36583
  isSplitDraw || isDash || (!isWidthNumber && widthInfo.width && (context.lineWidth = widthInfo.width), context.stroke()), context.lineDashOffset = 0, context.setLineDash([]);
36516
36584
  }
@@ -36781,19 +36849,19 @@
36781
36849
  strokeLeft = (isStrokeTrue || stroke[3]) && (isWidthNumber || strokeArrayWidth[3]);
36782
36850
  if (strokeTop && 0 === i) {
36783
36851
  isWidthNumber ? widthInfo.width : strokeArrayWidth[0], isWidthNumber ? widthInfo.width : strokeArrayWidth[0];
36784
- context.moveTo(x1, y1), context.lineTo(x2, y2), (isSplitDraw || isDash) && (strokeArrayColor && strokeArrayColor[0] ? context.strokeStyle = strokeArrayColor[0] : context.strokeStyle = "transparent", isWidthNumber || (context.lineWidth = strokeArrayWidth[0]), context.lineDashOffset = context.currentMatrix.e / context.currentMatrix.a, isDash && context.setLineDash(null !== (_a = lineDash[0]) && void 0 !== _a ? _a : []), context.stroke(), context.beginPath());
36852
+ context.moveTo(x1, y1), context.lineTo(x2, y2), (isSplitDraw || isDash) && (strokeArrayColor && strokeArrayColor[0] ? context.strokeStyle = strokeArrayColor[0] : strokeArrayColor && !strokeArrayColor[0] && (context.strokeStyle = "transparent"), isWidthNumber || (context.lineWidth = strokeArrayWidth[0]), context.lineDashOffset = context.currentMatrix.e / context.currentMatrix.a, isDash && context.setLineDash(null !== (_a = lineDash[0]) && void 0 !== _a ? _a : []), context.stroke(), context.beginPath());
36785
36853
  } else 0 === i && context.moveTo(x + width, y);
36786
36854
  if (strokeRight && 1 === i) {
36787
36855
  isWidthNumber ? widthInfo.width : strokeArrayWidth[1], isWidthNumber ? widthInfo.width : strokeArrayWidth[1];
36788
- context.moveTo(x1, y1), context.lineTo(x2, y2), (isSplitDraw || isDash) && (strokeArrayColor && strokeArrayColor[1] ? context.strokeStyle = strokeArrayColor[1] : context.strokeStyle = "transparent", isWidthNumber || (context.lineWidth = strokeArrayWidth[1]), context.lineDashOffset = context.currentMatrix.f / context.currentMatrix.d, isDash && context.setLineDash(null !== (_b = lineDash[1]) && void 0 !== _b ? _b : []), context.stroke(), context.beginPath(), context.moveTo(x + width, y + height));
36856
+ context.moveTo(x1, y1), context.lineTo(x2, y2), (isSplitDraw || isDash) && (strokeArrayColor && strokeArrayColor[1] ? context.strokeStyle = strokeArrayColor[1] : strokeArrayColor && !strokeArrayColor[1] && (context.strokeStyle = "transparent"), isWidthNumber || (context.lineWidth = strokeArrayWidth[1]), context.lineDashOffset = context.currentMatrix.f / context.currentMatrix.d, isDash && context.setLineDash(null !== (_b = lineDash[1]) && void 0 !== _b ? _b : []), context.stroke(), context.beginPath(), context.moveTo(x + width, y + height));
36789
36857
  } else 1 === i && context.moveTo(x + width, y + height);
36790
36858
  if (strokeBottom && 2 === i) {
36791
36859
  isWidthNumber ? widthInfo.width : strokeArrayWidth[2], isWidthNumber ? widthInfo.width : strokeArrayWidth[2];
36792
- context.moveTo(x1, y1), context.lineTo(x2, y2), (isSplitDraw || isDash) && (strokeArrayColor && strokeArrayColor[2] ? context.strokeStyle = strokeArrayColor[2] : context.strokeStyle = "transparent", isWidthNumber || (context.lineWidth = strokeArrayWidth[2]), context.lineDashOffset = context.currentMatrix.e / context.currentMatrix.a, isDash && context.setLineDash(null !== (_c = lineDash[2]) && void 0 !== _c ? _c : []), context.stroke(), context.beginPath(), context.moveTo(x, y + height));
36860
+ context.moveTo(x1, y1), context.lineTo(x2, y2), (isSplitDraw || isDash) && (strokeArrayColor && strokeArrayColor[2] ? context.strokeStyle = strokeArrayColor[2] : strokeArrayColor && !strokeArrayColor[2] && (context.strokeStyle = "transparent"), isWidthNumber || (context.lineWidth = strokeArrayWidth[2]), context.lineDashOffset = context.currentMatrix.e / context.currentMatrix.a, isDash && context.setLineDash(null !== (_c = lineDash[2]) && void 0 !== _c ? _c : []), context.stroke(), context.beginPath(), context.moveTo(x, y + height));
36793
36861
  } else 2 === i && context.moveTo(x, y + height);
36794
36862
  if (strokeLeft && 3 === i) {
36795
36863
  isWidthNumber ? widthInfo.width : strokeArrayWidth[3], isWidthNumber ? widthInfo.width : strokeArrayWidth[3];
36796
- context.moveTo(x1, y1), context.lineTo(x2, y2), (isSplitDraw || isDash) && (strokeArrayColor && strokeArrayColor[3] ? context.strokeStyle = strokeArrayColor[3] : context.strokeStyle = "transparent", isWidthNumber || (context.lineWidth = strokeArrayWidth[3]), context.lineDashOffset = context.currentMatrix.f / context.currentMatrix.d, isDash && context.setLineDash(null !== (_d = lineDash[3]) && void 0 !== _d ? _d : []), context.stroke(), context.beginPath(), context.moveTo(x, y));
36864
+ context.moveTo(x1, y1), context.lineTo(x2, y2), (isSplitDraw || isDash) && (strokeArrayColor && strokeArrayColor[3] ? context.strokeStyle = strokeArrayColor[3] : strokeArrayColor && !strokeArrayColor[3] && (context.strokeStyle = "transparent"), isWidthNumber || (context.lineWidth = strokeArrayWidth[3]), context.lineDashOffset = context.currentMatrix.f / context.currentMatrix.d, isDash && context.setLineDash(null !== (_d = lineDash[3]) && void 0 !== _d ? _d : []), context.stroke(), context.beginPath(), context.moveTo(x, y));
36797
36865
  } else 3 === i && context.moveTo(x, y);
36798
36866
  isSplitDraw || isDash || (!isWidthNumber && widthInfo.width && (context.lineWidth = widthInfo.width), context.stroke()), context.lineDashOffset = 0, context.setLineDash([]), context.closePath();
36799
36867
  }
@@ -37436,7 +37504,7 @@
37436
37504
  rightBottomCornerGroup: rightBottomCornerGroup
37437
37505
  } = table.scenegraph;
37438
37506
  let distCol, distRow, distColForCompute, distRowForCompute;
37439
- proxy.setParamsForRow(), proxy.setParamsForColumn(), "adaptive" === table.widthMode || table.options.autoWrapText && ("adaptive" === table.heightMode || table.isAutoRowHeight()) ? (distColForCompute = table.colCount - 1, distCol = Math.min(proxy.firstScreenColLimit, table.colCount - 1)) : distCol = Math.min(proxy.firstScreenColLimit, table.colCount - 1), "adaptive" === table.heightMode ? (distRowForCompute = table.rowCount - 1, distRow = Math.min(proxy.firstScreenRowLimit, table.rowCount - 1)) : distRow = Math.min(proxy.firstScreenRowLimit, table.rowCount - 1), 0 === table.internalProps._widthResizedColMap.size && computeColsWidth(table, 0, null != distColForCompute ? distColForCompute : distCol), 0 === table.internalProps._heightResizedRowMap.size && computeRowsHeight(table, 0, null != distRowForCompute ? distRowForCompute : distRow), distCol < table.colCount - table.rightFrozenColCount && computeColsWidth(table, table.colCount - table.rightFrozenColCount, table.colCount - 1), distRow < table.rowCount - table.bottomFrozenRowCount && computeRowsHeight(table, table.rowCount - table.bottomFrozenRowCount, table.rowCount - 1), table.scenegraph.colHeaderGroup.setAttribute("x", table.getFrozenColsWidth()), table.scenegraph.rowHeaderGroup.setAttribute("y", table.getFrozenRowsHeight()), table.scenegraph.bottomFrozenGroup.setAttribute("x", table.getFrozenColsWidth()), table.scenegraph.rightFrozenGroup.setAttribute("y", table.getFrozenRowsHeight()), table.scenegraph.bodyGroup.setAttributes({
37507
+ proxy.setParamsForRow(), proxy.setParamsForColumn(), "adaptive" === table.widthMode || table.options.autoWrapText && ("adaptive" === table.heightMode || table.isAutoRowHeight()) ? (distColForCompute = table.colCount - 1, distCol = Math.min(proxy.firstScreenColLimit - 1, table.colCount - 1)) : distCol = Math.min(proxy.firstScreenColLimit - 1, table.colCount - 1), "adaptive" === table.heightMode ? (distRowForCompute = table.rowCount - 1, distRow = Math.min(proxy.firstScreenRowLimit - 1, table.rowCount - 1)) : distRow = Math.min(proxy.firstScreenRowLimit - 1, table.rowCount - 1), 0 === table.internalProps._widthResizedColMap.size && computeColsWidth(table, 0, null != distColForCompute ? distColForCompute : distCol), 0 === table.internalProps._heightResizedRowMap.size && computeRowsHeight(table, 0, null != distRowForCompute ? distRowForCompute : distRow), distCol < table.colCount - table.rightFrozenColCount && computeColsWidth(table, table.colCount - table.rightFrozenColCount, table.colCount - 1), distRow < table.rowCount - table.bottomFrozenRowCount && computeRowsHeight(table, table.rowCount - table.bottomFrozenRowCount, table.rowCount - 1), table.scenegraph.colHeaderGroup.setAttribute("x", table.getFrozenColsWidth()), table.scenegraph.rowHeaderGroup.setAttribute("y", table.getFrozenRowsHeight()), table.scenegraph.bottomFrozenGroup.setAttribute("x", table.getFrozenColsWidth()), table.scenegraph.rightFrozenGroup.setAttribute("y", table.getFrozenRowsHeight()), table.scenegraph.bodyGroup.setAttributes({
37440
37508
  x: table.getFrozenColsWidth(),
37441
37509
  y: table.getFrozenRowsHeight()
37442
37510
  }), createColGroup(cornerHeaderGroup, xOrigin, yOrigin, 0, table.frozenColCount - 1, 0, table.frozenRowCount - 1, table.isListTable() ? "columnHeader" : "cornerHeader", table), distCol - table.rightFrozenColCount >= table.frozenColCount && createColGroup(colHeaderGroup, xOrigin, yOrigin, table.frozenColCount, distCol - table.rightFrozenColCount, 0, table.frozenRowCount - 1, "columnHeader", table), table.frozenColCount > 0 && (table.leftRowSeriesNumberCount > 0 && createColGroup(rowHeaderGroup, xOrigin, yOrigin, 0, table.leftRowSeriesNumberCount - 1, table.frozenRowCount, distRow - table.bottomFrozenRowCount, "rowHeader", table), table.rowHeaderLevelCount > 0 && createColGroup(rowHeaderGroup, xOrigin, yOrigin, table.leftRowSeriesNumberCount, table.leftRowSeriesNumberCount + table.rowHeaderLevelCount - 1, table.frozenRowCount, distRow - table.bottomFrozenRowCount, "rowHeader", table), table.frozenColCount > table.rowHeaderLevelCount + table.leftRowSeriesNumberCount && createColGroup(rowHeaderGroup, xOrigin, yOrigin, table.rowHeaderLevelCount + table.leftRowSeriesNumberCount, table.frozenColCount - 1, table.frozenRowCount, distRow - table.bottomFrozenRowCount, "body", table)), table.bottomFrozenRowCount > 0 && (table.frozenColCount > 0 && (table.leftRowSeriesNumberCount > 0 && createColGroup(leftBottomCornerGroup, xOrigin, yOrigin, 0, table.leftRowSeriesNumberCount - 1, table.rowCount - 1 - table.bottomFrozenRowCount + 1, table.rowCount - 1, "rowHeader", table), table.rowHeaderLevelCount > 0 && createColGroup(leftBottomCornerGroup, xOrigin, yOrigin, table.leftRowSeriesNumberCount, table.leftRowSeriesNumberCount + table.rowHeaderLevelCount - 1, table.rowCount - 1 - table.bottomFrozenRowCount + 1, table.rowCount - 1, "rowHeader", table), table.frozenColCount > table.rowHeaderLevelCount + table.leftRowSeriesNumberCount && createColGroup(leftBottomCornerGroup, xOrigin, yOrigin, table.rowHeaderLevelCount + table.leftRowSeriesNumberCount, table.frozenColCount - 1, table.rowCount - 1 - table.bottomFrozenRowCount + 1, table.rowCount - 1, "body", table)), distCol - table.rightFrozenColCount >= table.frozenColCount && createColGroup(bottomFrozenGroup, xOrigin, yOrigin, table.frozenColCount, distCol - table.rightFrozenColCount, table.rowCount - 1 - table.bottomFrozenRowCount + 1, table.rowCount - 1, table.isPivotChart() ? "rowHeader" : "body", table)), table.rightFrozenColCount > 0 && (createColGroup(rightTopCornerGroup, xOrigin, yOrigin, table.colCount - 1 - table.rightFrozenColCount + 1, table.colCount - 1, 0, table.frozenRowCount - 1, "columnHeader", table), createColGroup(rightFrozenGroup, xOrigin, yOrigin, table.colCount - 1 - table.rightFrozenColCount + 1, table.colCount - 1, table.frozenRowCount, distRow - table.bottomFrozenRowCount, table.isPivotChart() ? "rowHeader" : "body", table)), table.bottomFrozenRowCount > 0 && table.rightFrozenColCount > 0 && createColGroup(rightBottomCornerGroup, xOrigin, yOrigin, table.colCount - 1 - table.rightFrozenColCount + 1, table.colCount - 1, table.rowCount - 1 - table.bottomFrozenRowCount + 1, table.rowCount - 1, "body", table), distCol - table.rightFrozenColCount >= table.frozenColCount && createColGroup(bodyGroup, xOrigin, yOrigin, table.frozenColCount, distCol - table.rightFrozenColCount, table.frozenRowCount, distRow - table.bottomFrozenRowCount, "body", table), bodyGroup.firstChild || colHeaderGroup.firstChild || cornerHeaderGroup.firstChild || rowHeaderGroup.firstChild ? (proxy.currentRow = null !== (_d = null !== (_b = null === (_a = bodyGroup.firstChild) || void 0 === _a ? void 0 : _a.rowNumber) && void 0 !== _b ? _b : null === (_c = rowHeaderGroup.firstChild) || void 0 === _c ? void 0 : _c.rowNumber) && void 0 !== _d ? _d : proxy.totalRow, proxy.rowEnd = proxy.currentRow, proxy.rowUpdatePos = proxy.rowEnd + 1, proxy.referenceRow = proxy.rowStart + Math.floor((proxy.rowEnd - proxy.rowStart) / 2), proxy.currentCol = null !== (_m = null !== (_k = null !== (_h = null !== (_f = null === (_e = bodyGroup.lastChild) || void 0 === _e ? void 0 : _e.col) && void 0 !== _f ? _f : null === (_g = colHeaderGroup.lastChild) || void 0 === _g ? void 0 : _g.col) && void 0 !== _h ? _h : null === (_j = rowHeaderGroup.lastChild) || void 0 === _j ? void 0 : _j.col) && void 0 !== _k ? _k : null === (_l = cornerHeaderGroup.lastChild) || void 0 === _l ? void 0 : _l.col) && void 0 !== _m ? _m : proxy.totalCol, proxy.colEnd = proxy.currentCol, proxy.colUpdatePos = proxy.colEnd + 1, proxy.referenceCol = proxy.colStart + Math.floor((proxy.colEnd - proxy.colStart) / 2), proxy.progress()) : (proxy.currentRow = proxy.totalRow, proxy.rowEnd = proxy.currentRow, proxy.rowUpdatePos = proxy.rowEnd + 1, proxy.referenceRow = proxy.rowStart + Math.floor((proxy.rowEnd - proxy.rowStart) / 2), proxy.currentCol = proxy.totalCol, proxy.colEnd = proxy.currentCol, proxy.colUpdatePos = proxy.colEnd + 1, proxy.referenceCol = proxy.colStart + Math.floor((proxy.colEnd - proxy.colStart) / 2));
@@ -37444,12 +37512,12 @@
37444
37512
 
37445
37513
  function getFirstChild(containerGroup) {
37446
37514
  let child = containerGroup.firstChild;
37447
- for (; "group" !== child.type;) child = child._next;
37515
+ for (; child && "group" !== child.type;) child = child._next;
37448
37516
  return child;
37449
37517
  }
37450
37518
  function getLastChild(containerGroup) {
37451
37519
  let child = containerGroup.lastChild;
37452
- for (; "group" !== child.type;) child = child._prev;
37520
+ for (; child && "group" !== child.type;) child = child._prev;
37453
37521
  return child;
37454
37522
  }
37455
37523
  function getPrevGroup(group) {
@@ -37611,7 +37679,7 @@
37611
37679
  const colGroup = proxy.table.scenegraph.getColGroup(col);
37612
37680
  colGroup && updateColGroupContentAsync(colGroup, proxy);
37613
37681
  }
37614
- proxy.progress();
37682
+ updateColumnContainerWidth(proxy.table.scenegraph.colHeaderGroup), updateColumnContainerWidth(proxy.table.scenegraph.bottomFrozenGroup), updateColumnContainerWidth(proxy.table.scenegraph.bodyGroup), proxy.progress();
37615
37683
  }
37616
37684
  function updateAllColPosition(distStartColY, count, direction, proxy) {
37617
37685
  proxy.table.scenegraph.colHeaderGroup.forEachChildren((colGroup, index) => {
@@ -37622,6 +37690,11 @@
37622
37690
  "group" === colGroup.type && updateColGroupPosition(colGroup, "left" === direction ? colGroup.col + count : colGroup.col - count, 0 === index ? distStartColY : colGroup._prev.attribute.x + proxy.table.getColWidth(colGroup._prev.col));
37623
37691
  });
37624
37692
  }
37693
+ function updateColumnContainerWidth(containerGroup) {
37694
+ var _a;
37695
+ const lastColGroup = getLastChild(containerGroup);
37696
+ lastColGroup && (containerGroup.setAttribute("width", lastColGroup.attribute.x + lastColGroup.attribute.width), null === (_a = containerGroup.border) || void 0 === _a || _a.setAttribute("width", lastColGroup.attribute.x + lastColGroup.attribute.width));
37697
+ }
37625
37698
 
37626
37699
  function updateAutoRow(colStart, colEnd, rowStart, rowEnd, table) {
37627
37700
  let direction = arguments.length > 5 && arguments[5] !== undefined ? arguments[5] : "up";
@@ -40017,7 +40090,7 @@
40017
40090
  var _a, _b;
40018
40091
  this.table.animationManager.clear(), (this.table.isPivotChart() || this.table._hasCustomRenderOrLayout()) && this.stage.pluginService.findPluginsByName("poptipForText").forEach(plugin => {
40019
40092
  plugin.deactivate(this.stage.pluginService);
40020
- }), this.clear = !0, this.hasFrozen = !1, this.mergeMap.clear(), this.colHeaderGroup.clear(), this.rowHeaderGroup.clear(), this.cornerHeaderGroup.clear(), this.bodyGroup.clear(), this.bottomFrozenGroup.clear(), this.rightFrozenGroup.clear(), this.rightTopCornerGroup.clear(), this.rightBottomCornerGroup.clear(), this.leftBottomCornerGroup.clear(), this.colHeaderGroup.setAttributes({
40093
+ }), this.clear = !0, this.hasFrozen = !1, this.mergeMap.clear(), this.colHeaderGroup.clear(), delete this.colHeaderGroup.border, this.rowHeaderGroup.clear(), delete this.rowHeaderGroup.border, this.cornerHeaderGroup.clear(), delete this.cornerHeaderGroup.border, this.bodyGroup.clear(), delete this.bodyGroup.border, this.bottomFrozenGroup.clear(), delete this.bottomFrozenGroup.border, this.rightFrozenGroup.clear(), delete this.rightFrozenGroup.border, this.rightTopCornerGroup.clear(), delete this.rightTopCornerGroup.border, this.rightBottomCornerGroup.clear(), delete this.rightBottomCornerGroup.border, this.leftBottomCornerGroup.clear(), delete this.leftBottomCornerGroup.border, this.colHeaderGroup.setAttributes({
40021
40094
  x: 0,
40022
40095
  y: 0,
40023
40096
  width: 0,
@@ -41651,7 +41724,7 @@
41651
41724
  table: table
41652
41725
  } = state;
41653
41726
  let source, target;
41654
- if (table.internalProps.transpose ? (sourceIndex = table.getRecordShowIndexByCell(sourceIndex, 0), targetIndex = table.getRecordShowIndexByCell(targetIndex, 0)) : (source = table.getRecordIndexByCell(0, sourceIndex), target = table.getRecordIndexByCell(0, targetIndex)), isNumber$2(source) && isNumber$2(target)) {
41727
+ if (table.internalProps.transpose ? (sourceIndex = table.getRecordShowIndexByCell(sourceIndex, 0), targetIndex = table.getRecordShowIndexByCell(targetIndex, 0)) : (source = table.isPivotTable() ? void 0 : table.getRecordIndexByCell(0, sourceIndex), target = table.isPivotTable() ? void 0 : table.getRecordIndexByCell(0, targetIndex)), isNumber$2(source) && isNumber$2(target)) {
41655
41728
  if (sourceIndex > targetIndex) {
41656
41729
  const sourceRecord = checkedState.get(sourceIndex.toString());
41657
41730
  for (let i = sourceIndex; i > targetIndex; i--) checkedState.set(i.toString(), checkedState.get((i - 1).toString()));
@@ -46481,7 +46554,7 @@
46481
46554
  constructor(container) {
46482
46555
  let options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
46483
46556
  var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
46484
- if (super(), this.showFrozenIcon = !0, this.version = "1.14.0", this.id = `VTable${Date.now()}`, this.isReleased = !1, this._chartEventMap = {}, this.throttleInvalidate = throttle2(this.render.bind(this), 200), !container && "node" !== options.mode && !options.canvas) throw new Error("vtable's container is undefined");
46557
+ if (super(), this.showFrozenIcon = !0, this.version = "1.14.2", this.id = `VTable${Date.now()}`, this.isReleased = !1, this._chartEventMap = {}, this.throttleInvalidate = throttle2(this.render.bind(this), 200), !container && "node" !== options.mode && !options.canvas) throw new Error("vtable's container is undefined");
46485
46558
  const {
46486
46559
  frozenColCount = 0,
46487
46560
  frozenRowCount: frozenRowCount,
@@ -46786,15 +46859,13 @@
46786
46859
  heightWithoutPadding = 0;
46787
46860
  if (this.canvasSizeSeted) widthWithoutPadding = this.canvasWidth, heightWithoutPadding = this.canvasHeight;else if (element.parentElement) {
46788
46861
  const computedStyle = element.parentElement.style || window.getComputedStyle(element.parentElement);
46789
- widthWithoutPadding = element.parentElement.offsetWidth - parseInt(computedStyle.paddingLeft || "0px", 10) - parseInt(computedStyle.paddingRight || "0px", 10), heightWithoutPadding = element.parentElement.offsetHeight - parseInt(computedStyle.paddingTop || "0px", 10) - parseInt(computedStyle.paddingBottom || "0px", 20);
46862
+ widthWithoutPadding = element.parentElement.offsetWidth - parseInt(computedStyle.paddingLeft || "0px", 10) - parseInt(computedStyle.paddingRight || "0px", 10), heightWithoutPadding = element.parentElement.offsetHeight - parseInt(computedStyle.paddingTop || "0px", 10) - parseInt(computedStyle.paddingBottom || "0px", 20), widthWithoutPadding = (null != widthWithoutPadding ? widthWithoutPadding : 1) - (this.options.tableSizeAntiJitter ? 1 : 0), heightWithoutPadding = (null != heightWithoutPadding ? heightWithoutPadding : 1) - (this.options.tableSizeAntiJitter ? 1 : 0);
46790
46863
  }
46791
- const width1 = null != widthWithoutPadding ? widthWithoutPadding : 0,
46792
- height1 = null != heightWithoutPadding ? heightWithoutPadding : 0;
46793
- element.style.width = width1 && width1 - padding.left - padding.right + "px" || "0px", element.style.height = height1 && height1 - padding.top - padding.bottom + "px" || "0px";
46864
+ element.style.width = widthWithoutPadding && widthWithoutPadding - padding.left - padding.right + "px" || "0px", element.style.height = heightWithoutPadding && heightWithoutPadding - padding.top - padding.bottom + "px" || "0px";
46794
46865
  const {
46795
46866
  canvas: canvas
46796
46867
  } = this.internalProps;
46797
- widthP = null !== (_c = null === (_b = canvas.parentElement) || void 0 === _b ? void 0 : _b.offsetWidth) && void 0 !== _c ? _c : 0, heightP = null !== (_e = null === (_d = canvas.parentElement) || void 0 === _d ? void 0 : _d.offsetHeight) && void 0 !== _e ? _e : 0, (null === (_f = null == this ? void 0 : this.scenegraph) || void 0 === _f ? void 0 : _f.stage) ? this.scenegraph.stage.resize(widthP, heightP) : (canvas.style.width = "", canvas.style.height = "", canvas.width = widthP, canvas.height = heightP, canvas.style.width = `${widthP}px`, canvas.style.height = `${heightP}px`);
46868
+ widthP = (null !== (_c = null === (_b = canvas.parentElement) || void 0 === _b ? void 0 : _b.offsetWidth) && void 0 !== _c ? _c : 1) - (this.options.tableSizeAntiJitter ? 1 : 0), heightP = (null !== (_e = null === (_d = canvas.parentElement) || void 0 === _d ? void 0 : _d.offsetHeight) && void 0 !== _e ? _e : 1) - (this.options.tableSizeAntiJitter ? 1 : 0), (null === (_f = null == this ? void 0 : this.scenegraph) || void 0 === _f ? void 0 : _f.stage) ? this.scenegraph.stage.resize(widthP, heightP) : (canvas.style.width = "", canvas.style.height = "", canvas.width = widthP, canvas.height = heightP, canvas.style.width = `${widthP}px`, canvas.style.height = `${heightP}px`);
46798
46869
  } else "node" === Env.mode && (widthP = this.canvasWidth - 1, heightP = this.canvasHeight - 1);
46799
46870
  const width = Math.floor(widthP - getVerticalScrollBarSize(this.getTheme().scrollStyle)),
46800
46871
  height = Math.floor(heightP - getHorizontalScrollBarSize(this.getTheme().scrollStyle));
@@ -49857,12 +49928,13 @@
49857
49928
  newHeight = computeRowHeight(row, 0, table.colCount - 1, table);
49858
49929
  table.scenegraph.updateRowHeight(row, newHeight - oldHeight);
49859
49930
  }
49860
- table.fireListeners(TABLE_EVENT_TYPE.CHANGE_CELL_VALUE, {
49931
+ const changedValue = table.getCellOriginValue(col, row);
49932
+ oldValue !== changedValue && table.fireListeners(TABLE_EVENT_TYPE.CHANGE_CELL_VALUE, {
49861
49933
  col: col,
49862
49934
  row: row,
49863
49935
  rawValue: beforeChangeValue,
49864
49936
  currentValue: oldValue,
49865
- changedValue: table.getCellOriginValue(col, row)
49937
+ changedValue: changedValue
49866
49938
  }), table.scenegraph.updateNextFrame();
49867
49939
  }
49868
49940
  }
@@ -49908,12 +49980,14 @@
49908
49980
  } = table.internalProps.layoutMap.getBody(startCol + j, startRow + i),
49909
49981
  beforeChangeValue = beforeChangeValues[i][j],
49910
49982
  oldValue = oldValues[i][j];
49911
- table.isHeader(startCol + j, startRow + i) ? table.internalProps.layoutMap.updateColumnTitle(startCol + j, startRow + i, value) : table.dataSource.changeFieldValue(value, recordIndex, field, startCol + j, startRow + i, table), table.fireListeners(TABLE_EVENT_TYPE.CHANGE_CELL_VALUE, {
49983
+ table.isHeader(startCol + j, startRow + i) ? table.internalProps.layoutMap.updateColumnTitle(startCol + j, startRow + i, value) : table.dataSource.changeFieldValue(value, recordIndex, field, startCol + j, startRow + i, table);
49984
+ const changedValue = table.getCellOriginValue(startCol + j, startRow + i);
49985
+ oldValue !== changedValue && table.fireListeners(TABLE_EVENT_TYPE.CHANGE_CELL_VALUE, {
49912
49986
  col: startCol + j,
49913
49987
  row: startRow + i,
49914
49988
  rawValue: beforeChangeValue,
49915
49989
  currentValue: oldValue,
49916
- changedValue: table.getCellOriginValue(startCol + j, startRow + i)
49990
+ changedValue: changedValue
49917
49991
  });
49918
49992
  }
49919
49993
  }