handsontable 0.0.0-next-a28bea1-20230831 → 0.0.0-next-091c0be-20230904

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of handsontable might be problematic. Click here for more details.

@@ -423,6 +423,11 @@ function offset(element) {
423
423
  if (elementToCheck === rootDocument.body) {
424
424
  break;
425
425
  }
426
+ // If the element is inside an SVG context, the `offsetParent` can be
427
+ // a <foreignObject> that does not have properties `offsetLeft` and `offsetTop` defined.
428
+ if (!('offsetLeft' in elementToCheck)) {
429
+ break;
430
+ }
426
431
  offsetLeft += elementToCheck.offsetLeft;
427
432
  offsetTop += elementToCheck.offsetTop;
428
433
  lastElem = elementToCheck;
@@ -370,6 +370,11 @@ export function offset(element) {
370
370
  if (elementToCheck === rootDocument.body) {
371
371
  break;
372
372
  }
373
+ // If the element is inside an SVG context, the `offsetParent` can be
374
+ // a <foreignObject> that does not have properties `offsetLeft` and `offsetTop` defined.
375
+ if (!('offsetLeft' in elementToCheck)) {
376
+ break;
377
+ }
373
378
  offsetLeft += elementToCheck.offsetLeft;
374
379
  offsetTop += elementToCheck.offsetTop;
375
380
  lastElem = elementToCheck;
package/helpers/mixed.js CHANGED
@@ -134,7 +134,7 @@ const domMessages = {
134
134
  function _injectProductInfo(key, element) {
135
135
  const hasValidType = !isEmpty(key);
136
136
  const isNonCommercial = typeof key === 'string' && key.toLowerCase() === 'non-commercial-and-evaluation';
137
- const hotVersion = "0.0.0-next-a28bea1-20230831";
137
+ const hotVersion = "0.0.0-next-091c0be-20230904";
138
138
  let keyValidityDate;
139
139
  let consoleMessageState = 'invalid';
140
140
  let domMessageState = 'invalid';
package/helpers/mixed.mjs CHANGED
@@ -124,7 +124,7 @@ const domMessages = {
124
124
  export function _injectProductInfo(key, element) {
125
125
  const hasValidType = !isEmpty(key);
126
126
  const isNonCommercial = typeof key === 'string' && key.toLowerCase() === 'non-commercial-and-evaluation';
127
- const hotVersion = "0.0.0-next-a28bea1-20230831";
127
+ const hotVersion = "0.0.0-next-091c0be-20230904";
128
128
  let keyValidityDate;
129
129
  let consoleMessageState = 'invalid';
130
130
  let domMessageState = 'invalid';
package/package.json CHANGED
@@ -10,7 +10,7 @@
10
10
  "url": "https://github.com/handsontable/handsontable/issues"
11
11
  },
12
12
  "author": "Handsoncode <hello@handsontable.com>",
13
- "version": "0.0.0-next-a28bea1-20230831",
13
+ "version": "0.0.0-next-091c0be-20230904",
14
14
  "main": "index",
15
15
  "module": "index.mjs",
16
16
  "jsnext:main": "index.mjs",
@@ -437,16 +437,13 @@ class NestedRows extends _base.BasePlugin {
437
437
  * @private
438
438
  */
439
439
  onAfterInit() {
440
- const deepestLevel = Math.max(...this.dataManager.cache.levels);
441
- if (deepestLevel > 0) {
442
- this.headersUI.updateRowHeaderWidth(deepestLevel);
443
- }
440
+ this.headersUI.updateRowHeaderWidth();
444
441
  }
445
442
 
446
443
  /**
447
444
  * `beforeViewRender` hook callback.
448
445
  *
449
- * @param {boolean} force Indicates if the render call was trigered by a change of settings or data.
446
+ * @param {boolean} force Indicates if the render call was triggered by a change of settings or data.
450
447
  * @param {object} skipRender An object, holder for skipRender functionality.
451
448
  * @private
452
449
  */
@@ -431,16 +431,13 @@ export class NestedRows extends BasePlugin {
431
431
  * @private
432
432
  */
433
433
  onAfterInit() {
434
- const deepestLevel = Math.max(...this.dataManager.cache.levels);
435
- if (deepestLevel > 0) {
436
- this.headersUI.updateRowHeaderWidth(deepestLevel);
437
- }
434
+ this.headersUI.updateRowHeaderWidth();
438
435
  }
439
436
 
440
437
  /**
441
438
  * `beforeViewRender` hook callback.
442
439
  *
443
- * @param {boolean} force Indicates if the render call was trigered by a change of settings or data.
440
+ * @param {boolean} force Indicates if the render call was triggered by a change of settings or data.
444
441
  * @param {object} skipRender An object, holder for skipRender functionality.
445
442
  * @private
446
443
  */