@syncfusion/ej2-navigations 27.1.57 → 27.2.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.
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * filename: index.d.ts
3
- * version : 27.1.57
3
+ * version : 27.2.2
4
4
  * Copyright Syncfusion Inc. 2001 - 2023. All rights reserved.
5
5
  * Use of this code is subject to the terms of our license.
6
6
  * A copy of the current license can be obtained at any time by e-mailing
package/package.json CHANGED
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "_from": "@syncfusion/ej2-navigations@*",
3
- "_id": "@syncfusion/ej2-navigations@27.1.56",
3
+ "_id": "@syncfusion/ej2-navigations@27.1.58",
4
4
  "_inBundle": false,
5
- "_integrity": "sha512-ZDAWdA6fBNMFkRYrcHpnXH2hWArR6H8bnNZjKUVMlNYtFip7BocpLDscSblqIUP6DQmnfX6TGKwb5Voai/KIMQ==",
5
+ "_integrity": "sha512-NuGUkRUegiDf3K1JwEmZA5KTRuPPBQef7sVWP+qlW9nJuyckRl7gzgOgQ9yzbx+nakva45vcCB+KzpImZy6yGw==",
6
6
  "_location": "/@syncfusion/ej2-navigations",
7
7
  "_phantomChildren": {},
8
8
  "_requested": {
@@ -40,8 +40,8 @@
40
40
  "/@syncfusion/ej2-spreadsheet",
41
41
  "/@syncfusion/ej2-vue-navigations"
42
42
  ],
43
- "_resolved": "https://nexus.syncfusioninternal.com/repository/ej2-hotfix-new/@syncfusion/ej2-navigations/-/ej2-navigations-27.1.56.tgz",
44
- "_shasum": "276263b5f6d2e6fdd2e161b7142b894edfb7cd53",
43
+ "_resolved": "https://nexus.syncfusioninternal.com/repository/ej2-hotfix-new/@syncfusion/ej2-navigations/-/ej2-navigations-27.1.58.tgz",
44
+ "_shasum": "2a85735daee93b4d38ef699c1cb27c0ce0c0826d",
45
45
  "_spec": "@syncfusion/ej2-navigations@*",
46
46
  "_where": "/jenkins/workspace/elease-automation_release_27.1.1/packages/included",
47
47
  "author": {
@@ -52,12 +52,12 @@
52
52
  },
53
53
  "bundleDependencies": false,
54
54
  "dependencies": {
55
- "@syncfusion/ej2-base": "~27.1.55",
56
- "@syncfusion/ej2-buttons": "~27.1.53",
57
- "@syncfusion/ej2-data": "~27.1.52",
58
- "@syncfusion/ej2-inputs": "~27.1.55",
59
- "@syncfusion/ej2-lists": "~27.1.50",
60
- "@syncfusion/ej2-popups": "~27.1.57"
55
+ "@syncfusion/ej2-base": "~27.2.2",
56
+ "@syncfusion/ej2-buttons": "~27.2.2",
57
+ "@syncfusion/ej2-data": "~27.2.2",
58
+ "@syncfusion/ej2-inputs": "~27.2.2",
59
+ "@syncfusion/ej2-lists": "~27.2.2",
60
+ "@syncfusion/ej2-popups": "~27.2.2"
61
61
  },
62
62
  "deprecated": false,
63
63
  "description": "A package of Essential JS 2 navigation components such as Tree-view, Tab, Toolbar, Context-menu, and Accordion which is used to navigate from one page to another",
@@ -162,6 +162,6 @@
162
162
  "url": "git+https://github.com/syncfusion/ej2-javascript-ui-controls.git"
163
163
  },
164
164
  "typings": "index.d.ts",
165
- "version": "27.1.57",
165
+ "version": "27.2.2",
166
166
  "sideEffects": false
167
167
  }
@@ -319,6 +319,9 @@ var MenuBase = /** @class */ (function (_super) {
319
319
  this.delegateMouseDownHandler = this.mouseDownHandler.bind(this);
320
320
  EventHandler.add(this.isMenu ? document : wrapper, 'mouseover', this.delegateMoverHandler, this);
321
321
  EventHandler.add(document, 'mousedown', this.delegateMouseDownHandler, this);
322
+ if (!this.isMenu && !this.target) {
323
+ EventHandler.add(document, 'scroll', this.scrollHandler, this);
324
+ }
322
325
  }
323
326
  this.delegateClickHandler = this.clickHandler.bind(this);
324
327
  EventHandler.add(document, 'click', this.delegateClickHandler, this);
@@ -684,7 +687,7 @@ var MenuBase = /** @class */ (function (_super) {
684
687
  _this.afterCloseMenu(e);
685
688
  }
686
689
  else if (isOpen && !_this.hamburgerMode && closedLi && !trgtLi && _this.keyType !== 'left' && (_this.navIdx.length || !_this.isMenu && _this.navIdx.length === 0)) {
687
- var ele = (e && (e.target.classList.contains('e-vscroll') || e.target.classList.contains('e-scroll-nav')))
690
+ var ele = (e && e.target.classList && (e.target.classList.contains('e-vscroll') || e.target.classList.contains('e-scroll-nav')))
688
691
  ? closest(e.target, '.e-menu-wrapper') : null;
689
692
  if (ele) {
690
693
  ele = ele.querySelector('.e-menu-item');
@@ -693,7 +696,7 @@ var MenuBase = /** @class */ (function (_super) {
693
696
  }
694
697
  }
695
698
  else {
696
- if (!(e && e.target.classList.contains('e-nav-arrow'))) {
699
+ if (!(e && e.target.classList && e.target.classList.contains('e-nav-arrow'))) {
697
700
  _this.closeMenu(_this.navIdx[_this.navIdx.length - 1], e);
698
701
  }
699
702
  }
@@ -1906,6 +1909,9 @@ var MenuBase = /** @class */ (function (_super) {
1906
1909
  if (!Browser.isDevice) {
1907
1910
  EventHandler.remove(this.isMenu ? document : wrapper, 'mouseover', this.delegateMoverHandler);
1908
1911
  EventHandler.remove(document, 'mousedown', this.delegateMouseDownHandler);
1912
+ if (!this.isMenu && !this.target) {
1913
+ EventHandler.remove(document, 'scroll', this.scrollHandler);
1914
+ }
1909
1915
  }
1910
1916
  EventHandler.remove(document, 'click', this.delegateClickHandler);
1911
1917
  this.unWireKeyboardEvent(wrapper);
package/src/tab/tab.d.ts CHANGED
@@ -506,6 +506,16 @@ export declare class Tab extends Component<HTMLElement> implements INotifyProper
506
506
  * @returns {void}
507
507
  */
508
508
  refresh(): void;
509
+ /**
510
+ * Reorganizes and adjusts the Tab headers to fit the available width without re-rendering the entire Tab component.
511
+ *
512
+ * This method is useful for optimizing the layout when:
513
+ * - A hidden tab item becomes visible.
514
+ * - The number of tab items changes dynamically.
515
+ *
516
+ * @returns {void} This method does not return a value.
517
+ */
518
+ refreshOverflow(): void;
509
519
  /**
510
520
  * Initialize component
511
521
  *
package/src/tab/tab.js CHANGED
@@ -274,6 +274,20 @@ var Tab = /** @class */ (function (_super) {
274
274
  this.renderReactTemplates();
275
275
  }
276
276
  };
277
+ /**
278
+ * Reorganizes and adjusts the Tab headers to fit the available width without re-rendering the entire Tab component.
279
+ *
280
+ * This method is useful for optimizing the layout when:
281
+ * - A hidden tab item becomes visible.
282
+ * - The number of tab items changes dynamically.
283
+ *
284
+ * @returns {void} This method does not return a value.
285
+ */
286
+ Tab.prototype.refreshOverflow = function () {
287
+ if (!isNOU(this.tbObj)) {
288
+ this.tbObj.refreshOverflow();
289
+ }
290
+ };
277
291
  /**
278
292
  * Initialize component
279
293
  *
@@ -319,9 +333,7 @@ var Tab = /** @class */ (function (_super) {
319
333
  this.initRender = false;
320
334
  if (this.isReact && this.portals && this.portals.length > 0) {
321
335
  this.renderReactTemplates(function () {
322
- if (!isNOU(_this.tbObj)) {
323
- _this.tbObj.refreshOverflow();
324
- }
336
+ _this.refreshOverflow();
325
337
  _this.refreshActiveBorder();
326
338
  });
327
339
  }
@@ -618,7 +630,7 @@ var Tab = /** @class */ (function (_super) {
618
630
  else {
619
631
  trg.classList.remove(CLS_CLOSE_SHOW);
620
632
  }
621
- this.tbObj.refreshOverflow();
633
+ this.refreshOverflow();
622
634
  this.refreshActiveTabBorder();
623
635
  };
624
636
  Tab.prototype.prevCtnAnimation = function (prev, current) {
@@ -1784,6 +1796,11 @@ var Tab = /** @class */ (function (_super) {
1784
1796
  var _this = this;
1785
1797
  var addArgs = { addedItems: items, cancel: false };
1786
1798
  if (!this.isReplace) {
1799
+ for (var _i = 0, items_1 = items; _i < items_1.length; _i++) {
1800
+ var item = items_1[_i];
1801
+ item.disabled = item.disabled || false;
1802
+ item.visible = item.visible || true;
1803
+ }
1787
1804
  this.trigger('adding', addArgs, function (tabAddingArgs) {
1788
1805
  if (!tabAddingArgs.cancel) {
1789
1806
  _this.addingTabContent(items, index);
@@ -1989,11 +2006,15 @@ var Tab = /** @class */ (function (_super) {
1989
2006
  }
1990
2007
  }
1991
2008
  this.setActiveBorder();
2009
+ if (!isNOU(this.items[index])) {
2010
+ this.items[index].visible = !value;
2011
+ this.dataBind();
2012
+ }
1992
2013
  if (!isNullOrUndefined(item.firstElementChild)) {
1993
2014
  item.firstElementChild.setAttribute('aria-hidden', '' + value);
1994
2015
  }
1995
- if (this.overflowMode === 'Popup' && this.tbObj) {
1996
- this.tbObj.refreshOverflow();
2016
+ if (this.overflowMode === 'Popup') {
2017
+ this.refreshOverflow();
1997
2018
  }
1998
2019
  };
1999
2020
  Tab.prototype.selectTab = function (args, event, isInteracted) {
@@ -1587,9 +1587,9 @@ var Toolbar = /** @class */ (function (_super) {
1587
1587
  return;
1588
1588
  }
1589
1589
  var alignDiv = [];
1590
- alignDiv.push(this.createElement('div', { className: CLS_TBARLEFT }));
1591
- alignDiv.push(this.createElement('div', { className: CLS_TBARCENTER }));
1592
- alignDiv.push(this.createElement('div', { className: CLS_TBARRIGHT }));
1590
+ alignDiv.push(this.createElement('div', { className: CLS_TBARLEFT, attrs: { role: 'group' } }));
1591
+ alignDiv.push(this.createElement('div', { className: CLS_TBARCENTER, attrs: { role: 'group' } }));
1592
+ alignDiv.push(this.createElement('div', { className: CLS_TBARRIGHT, attrs: { role: 'group' } }));
1593
1593
  if (pos === 0 && item.align !== 'Left') {
1594
1594
  alignDiv.forEach(function (ele) {
1595
1595
  itemEle.appendChild(ele);
@@ -801,7 +801,7 @@ var TreeView = /** @class */ (function (_super) {
801
801
  if (this.showCheckBox) {
802
802
  var checkboxEle = createCheckBox(this.createElement, true, { cssClass: this.touchClass });
803
803
  checkboxEle.classList.add(CHECKBOXWRAP);
804
- var icon = select('div.' + ICON, e.item);
804
+ var icon = select('div.' + EXPANDABLE + ', div.' + COLLAPSIBLE, e.item);
805
805
  var id = e.item.getAttribute('data-uid');
806
806
  e.item.childNodes[0].insertBefore(checkboxEle, e.item.childNodes[0].childNodes[isNOU(icon) ? 0 : 1]);
807
807
  var checkValue = getValue(e.fields.isChecked, e.curData);
@@ -1033,7 +1033,7 @@ var TreeView = /** @class */ (function (_super) {
1033
1033
  }
1034
1034
  count = childItems.length;
1035
1035
  }
1036
- if (this.autoCheck && this.showCheckBox) {
1036
+ if (this.autoCheck && this.showCheckBox && !(this.fields.dataSource instanceof DataManager)) {
1037
1037
  var selectedChildNodeDetails = this.getSelectedChildNodeDetails(dataUid_1);
1038
1038
  matchedChildNodes = selectedChildNodeDetails;
1039
1039
  oldChildCount = new DataManager(this.checkActionNodes)
@@ -3769,7 +3769,7 @@ var TreeView = /** @class */ (function (_super) {
3769
3769
  if (isNOU(dropIcon)) {
3770
3770
  ListBase.generateIcon(this.createElement, dropLi, EXPANDABLE, this.listBaseOption);
3771
3771
  }
3772
- var icon = select('div.' + ICON, dropLi);
3772
+ var icon = select('div.' + EXPANDABLE + ', div.' + COLLAPSIBLE, dropLi);
3773
3773
  if (icon) {
3774
3774
  icon.classList.add('e-icon-expandable');
3775
3775
  }
@@ -3792,7 +3792,7 @@ var TreeView = /** @class */ (function (_super) {
3792
3792
  if (isNOU(dropIcon)) {
3793
3793
  ListBase.generateIcon(this.createElement, dropLi, COLLAPSIBLE, this.listBaseOption);
3794
3794
  }
3795
- var icon = select('div.' + ICON, dropLi);
3795
+ var icon = select('div.' + EXPANDABLE + ', div.' + COLLAPSIBLE, dropLi);
3796
3796
  if (icon) {
3797
3797
  removeClass([icon], EXPANDABLE);
3798
3798
  }
@@ -3806,6 +3806,12 @@ var TreeView = /** @class */ (function (_super) {
3806
3806
  this.addExpand(dropLi);
3807
3807
  this.trigger('nodeExpanded', this.getExpandEvent(dropLi, null));
3808
3808
  }
3809
+ var collapseIcon = select('div.' + COLLAPSIBLE, dropLi);
3810
+ if (!isNOU(dropUl) && collapseIcon && this.preventExpand) {
3811
+ removeClass([collapseIcon], COLLAPSIBLE);
3812
+ dropLi.setAttribute('aria-expanded', 'false');
3813
+ addClass([collapseIcon], EXPANDABLE);
3814
+ }
3809
3815
  return dropUl;
3810
3816
  };
3811
3817
  TreeView.prototype.updateElement = function (dragParentUl, dragParentLi) {
@@ -4131,7 +4137,7 @@ var TreeView = /** @class */ (function (_super) {
4131
4137
  if (!isNullOrUndefined(dropLi)) {
4132
4138
  dropIcon1 = select('div.' + ICON, dropLi);
4133
4139
  }
4134
- if (this.dataType === 1 && dropIcon1 && dropIcon1.classList.contains(EXPANDABLE) && !isNOU(this.element.offsetParent) && !this.element.offsetParent.parentElement.classList.contains('e-filemanager')) {
4140
+ if (this.dataType === 1 && dropIcon1 && dropIcon1.classList.contains(EXPANDABLE) && this.preventExpand && !isNOU(this.element.offsetParent) && !this.element.offsetParent.parentElement.classList.contains('e-filemanager')) {
4135
4141
  this.preventExpand = true;
4136
4142
  }
4137
4143
  if (this.dataType !== 1) {
@@ -4152,7 +4158,7 @@ var TreeView = /** @class */ (function (_super) {
4152
4158
  for (var i = 0; i < li.length; i++) {
4153
4159
  dropUl.insertBefore(li[parseInt(i.toString(), 10)], refNode);
4154
4160
  }
4155
- if (this.dataType === 1 && !isNullOrUndefined(dropLi) && !isNOU(this.element.offsetParent) && !this.element.offsetParent.parentElement.classList.contains('e-filemanager')) {
4161
+ if (this.dataType === 1 && !isNullOrUndefined(dropLi) && !this.preventExpand && !isNOU(this.element.offsetParent) && !this.element.offsetParent.parentElement.classList.contains('e-filemanager')) {
4156
4162
  this.preventExpand = false;
4157
4163
  var dropIcon = select('div.' + ICON, dropLi);
4158
4164
  if (dropIcon && dropIcon.classList.contains(EXPANDABLE) && (isNOU(args) || args.name !== 'nodeExpanding')) {
@@ -4165,7 +4171,7 @@ var TreeView = /** @class */ (function (_super) {
4165
4171
  for (var i = 0; i < li.length; i++) {
4166
4172
  dropUl.insertBefore(li[parseInt(i.toString(), 10)], refNode);
4167
4173
  }
4168
- if (this.dataType === 1 && !isNullOrUndefined(dropLi) && !isNOU(this.element.offsetParent) && !this.element.offsetParent.parentElement.classList.contains('e-filemanager')) {
4174
+ if (this.dataType === 1 && !isNullOrUndefined(dropLi) && !this.preventExpand && !isNOU(this.element.offsetParent) && !this.element.offsetParent.parentElement.classList.contains('e-filemanager')) {
4169
4175
  this.preventExpand = false;
4170
4176
  var dropIcon = select('div.' + ICON, dropLi);
4171
4177
  if (dropIcon && dropIcon.classList.contains(EXPANDABLE) && (isNOU(args) || args.name !== 'nodeExpanding')) {
@@ -7261,8 +7261,7 @@ ejs-sidebar {
7261
7261
 
7262
7262
  .e-sidebar-overlay {
7263
7263
  opacity: 0.5;
7264
- -webkit-backdrop-filter: blur(2px);
7265
- backdrop-filter: blur(2px);
7264
+ backdrop-filter: blur(2px);
7266
7265
  position: fixed;
7267
7266
  width: 100%;
7268
7267
  }
@@ -9391,8 +9391,7 @@ ejs-sidebar {
9391
9391
 
9392
9392
  .e-sidebar-overlay {
9393
9393
  opacity: 0.5;
9394
- -webkit-backdrop-filter: blur(2px);
9395
- backdrop-filter: blur(2px);
9394
+ backdrop-filter: blur(2px);
9396
9395
  position: fixed;
9397
9396
  width: 100%;
9398
9397
  }
@@ -197,8 +197,7 @@ ejs-sidebar {
197
197
 
198
198
  .e-sidebar-overlay {
199
199
  opacity: 0.5;
200
- -webkit-backdrop-filter: blur(2px);
201
- backdrop-filter: blur(2px);
200
+ backdrop-filter: blur(2px);
202
201
  position: fixed;
203
202
  width: 100%;
204
203
  }