@syncfusion/ej2-layouts 20.3.58 → 20.4.38

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.
@@ -158,8 +158,18 @@ var Splitter = /** @__PURE__ @class */ (function (_super) {
158
158
  case 'paneSettings': {
159
159
  if (!(newProp.paneSettings instanceof Array && oldProp.paneSettings instanceof Array)) {
160
160
  var paneCounts = Object.keys(newProp.paneSettings);
161
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any
161
162
  if (this.isReact) {
162
- this.clearTemplate();
163
+ var cPaneCount = 0;
164
+ for (var k = 0; k < this.paneSettings.length; k++) {
165
+ if (typeof (this.paneSettings[k].content) === 'function') {
166
+ cPaneCount = cPaneCount + 1;
167
+ }
168
+ }
169
+ var hasAllContent = cPaneCount === this.paneSettings.length;
170
+ if (hasAllContent) {
171
+ this.clearTemplate();
172
+ }
163
173
  }
164
174
  for (var i = 0; i < paneCounts.length; i++) {
165
175
  var index = parseInt(Object.keys(newProp.paneSettings)[i], 10);
@@ -168,7 +178,7 @@ var Splitter = /** @__PURE__ @class */ (function (_super) {
168
178
  var property = Object.keys(newProp.paneSettings[index])[j];
169
179
  switch (property) {
170
180
  case 'content': {
171
- var newValue = Object(newProp.paneSettings[index])[property];
181
+ var newValue = Object(newProp.paneSettings[index])["" + property];
172
182
  if (!isNullOrUndefined(newValue)) {
173
183
  this.allPanes[index].innerHTML = '';
174
184
  this.setTemplate(newValue, this.allPanes[index]);
@@ -176,7 +186,7 @@ var Splitter = /** @__PURE__ @class */ (function (_super) {
176
186
  break;
177
187
  }
178
188
  case 'resizable': {
179
- var newVal = Object(newProp.paneSettings[index])[property];
189
+ var newVal = Object(newProp.paneSettings[index])["" + property];
180
190
  this.resizableModel(index, newVal);
181
191
  break;
182
192
  }
@@ -188,10 +198,11 @@ var Splitter = /** @__PURE__ @class */ (function (_super) {
188
198
  newProp.paneSettings[index].collapsed ? this.isCollapsed(index) : this.collapsedOnchange(index);
189
199
  break;
190
200
  case 'cssClass':
201
+ // eslint-disable-next-line max-len
191
202
  this.setCssClass(this.allPanes[index], newProp.paneSettings[index].cssClass);
192
203
  break;
193
204
  case 'size': {
194
- var newValSize = Object(newProp.paneSettings[index])[property];
205
+ var newValSize = Object(newProp.paneSettings[index])["" + property];
195
206
  if (newValSize !== '' && !isNullOrUndefined(newValSize)) {
196
207
  this.updatePaneSize(newValSize, index);
197
208
  }
@@ -401,7 +412,6 @@ var Splitter = /** @__PURE__ @class */ (function (_super) {
401
412
  }
402
413
  };
403
414
  Splitter.prototype.getMinInPixel = function (minValue) {
404
- var min;
405
415
  if (isNullOrUndefined(minValue)) {
406
416
  return 0;
407
417
  }
@@ -409,7 +419,7 @@ var Splitter = /** @__PURE__ @class */ (function (_super) {
409
419
  if (minValue.indexOf('%') > 0) {
410
420
  paneMinRange = this.convertPercentageToPixel(minValue);
411
421
  }
412
- min = this.convertPixelToNumber((paneMinRange).toString());
422
+ var min = this.convertPixelToNumber((paneMinRange).toString());
413
423
  return min;
414
424
  };
415
425
  /**
@@ -643,6 +653,7 @@ var Splitter = /** @__PURE__ @class */ (function (_super) {
643
653
  _this.updateIsCollapsed(index, _this.targetArrows().collapseArrow, _this.targetArrows().lastBarArrow);
644
654
  for (var i = 0; i < collapsedindex.length; i++) {
645
655
  if (!_this.allPanes[collapsedindex[i]].classList.contains(COLLAPSE_PANE)) {
656
+ // eslint-disable-next-line max-len
646
657
  _this.updateIsCollapsed(collapsedindex[i], _this.targetArrows().collapseArrow, _this.targetArrows().lastBarArrow);
647
658
  }
648
659
  }
@@ -1032,6 +1043,7 @@ var Splitter = /** @__PURE__ @class */ (function (_super) {
1032
1043
  }
1033
1044
  for (var j = 0, len = this.allBars.length; j < len; j++) {
1034
1045
  totalWidth += this.orientation === 'Horizontal' ? parseInt(getComputedStyle(this.allBars[j]).marginLeft, 10) +
1046
+ // eslint-disable-next-line max-len
1035
1047
  parseInt(getComputedStyle(this.allBars[j]).marginLeft, 10) : parseInt(getComputedStyle(this.allBars[j]).marginTop, 10) +
1036
1048
  parseInt(getComputedStyle(this.allBars[j]).marginBottom, 10);
1037
1049
  }
@@ -1766,13 +1778,13 @@ var Splitter = /** @__PURE__ @class */ (function (_super) {
1766
1778
  }
1767
1779
  var allFlexiblePanes = flexPaneCount === this.allPanes.length;
1768
1780
  // Two flexible Pane Case.
1769
- if (this.previousPane.style.flexBasis == '' && this.nextPane.style.flexBasis == '' && !allFlexiblePanes) {
1781
+ if (this.previousPane.style.flexBasis === '' && this.nextPane.style.flexBasis == '' && !allFlexiblePanes) {
1770
1782
  var middlePaneIndex = this.allPanes.length % this.allBars.length;
1771
1783
  if (this.prevPaneIndex === middlePaneIndex) {
1772
1784
  this.nextPane.style.flexBasis = this.nextPaneCurrentWidth;
1773
1785
  addClass([this.nextPane], STATIC_PANE);
1774
1786
  }
1775
- else if (this.nextPaneIndex == middlePaneIndex) {
1787
+ else if (this.nextPaneIndex === middlePaneIndex) {
1776
1788
  this.previousPane.style.flexBasis = this.prevPaneCurrentWidth;
1777
1789
  addClass([this.previousPane], STATIC_PANE);
1778
1790
  }
@@ -1786,16 +1798,16 @@ var Splitter = /** @__PURE__ @class */ (function (_super) {
1786
1798
  addClass([this.previousPane], STATIC_PANE);
1787
1799
  this.nextPane.style.flexBasis = this.nextPaneCurrentWidth;
1788
1800
  addClass([this.nextPane], STATIC_PANE);
1789
- } // Two Panesa are Static Pane
1801
+ } // Two Panesa are Static Pane
1790
1802
  else {
1791
- if (this.previousPane.style.flexBasis !== "" && this.previousPane.classList.contains(STATIC_PANE)) {
1803
+ if (this.previousPane.style.flexBasis !== '' && this.previousPane.classList.contains(STATIC_PANE)) {
1792
1804
  this.previousPane.style.flexBasis = this.prevPaneCurrentWidth;
1793
1805
  }
1794
- if (this.nextPane.style.flexBasis !== "" && this.nextPane.classList.contains(STATIC_PANE)) {
1806
+ if (this.nextPane.style.flexBasis !== '' && this.nextPane.classList.contains(STATIC_PANE)) {
1795
1807
  this.nextPane.style.flexBasis = this.nextPaneCurrentWidth;
1796
1808
  }
1797
1809
  }
1798
- var isStaticPanes = this.previousPane.style.flexBasis !== "" && this.nextPane.style.flexBasis !== "";
1810
+ var isStaticPanes = this.previousPane.style.flexBasis !== '' && this.nextPane.style.flexBasis !== '';
1799
1811
  if (!(this.allPanes.length > 2) && isStaticPanes) {
1800
1812
  this.updateSplitterSize();
1801
1813
  }
@@ -4061,7 +4073,7 @@ var DashboardLayout = /** @__PURE__ @class */ (function (_super) {
4061
4073
  if (this.collisionChecker[this.panels[i].id] && this.collisionChecker[this.panels[i].id] !== null) {
4062
4074
  this.overlapElement = [this.collisionChecker[this.panels[i].id].ele];
4063
4075
  var key = this.panels[i].id;
4064
- this.updateRowColumn(this.collisionChecker[key].row, this.overlapElement, this.collisionChecker[key].srcEle);
4076
+ this.updateRowColumn(this.collisionChecker["" + key].row, this.overlapElement, this.collisionChecker["" + key].srcEle);
4065
4077
  }
4066
4078
  }
4067
4079
  };
@@ -4451,7 +4463,7 @@ var DashboardLayout = /** @__PURE__ @class */ (function (_super) {
4451
4463
  }
4452
4464
  // eslint-disable-next-line guard-for-in
4453
4465
  for (var k in source[i]) {
4454
- target[i][k] = source[i][k];
4466
+ target[i]["" + k] = source[i]["" + k];
4455
4467
  }
4456
4468
  }
4457
4469
  return target;