@syncfusion/ej2-navigations 20.4.52 → 20.4.53

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.
@@ -9251,6 +9251,21 @@ var Tab = /** @__PURE__ @class */ (function (_super) {
9251
9251
  _this.refreshActiveBorder();
9252
9252
  var cntTrg = select('#' + CLS_CONTENT$1 + _this.tabId + '_' + _this.extIndex(trg.id), select('.' + CLS_CONTENT$1, _this.element));
9253
9253
  if (!isNullOrUndefined(cntTrg)) {
9254
+ var registeredTemplate = _this.registeredTemplate;
9255
+ if (registeredTemplate && registeredTemplate.content) {
9256
+ var templateToClear = [];
9257
+ for (var i = 0; i < registeredTemplate.content.length; i++) {
9258
+ var registeredItem = registeredTemplate.content[i].rootNodes[0];
9259
+ var closestItem = closest(registeredItem, '.' + CLS_ITEM$2);
9260
+ if (!isNullOrUndefined(registeredItem) && closestItem === cntTrg) {
9261
+ templateToClear.push(registeredTemplate.content[i]);
9262
+ break;
9263
+ }
9264
+ }
9265
+ if (templateToClear.length > 0) {
9266
+ _this.clearTemplate(['content'], templateToClear);
9267
+ }
9268
+ }
9254
9269
  detach(cntTrg);
9255
9270
  }
9256
9271
  _this.trigger('removed', tabRemovingArgs);
@@ -12434,7 +12449,7 @@ var TreeView = /** @__PURE__ @class */ (function (_super) {
12434
12449
  TreeView.prototype.focusIn = function () {
12435
12450
  if (!this.mouseDownStatus) {
12436
12451
  var focusedElement = this.getFocusedNode();
12437
- focusedElement.setAttribute("tanindex", "0");
12452
+ focusedElement.setAttribute("tabindex", "0");
12438
12453
  addClass([focusedElement], [HOVER, FOCUS]);
12439
12454
  EventHandler.add(focusedElement, 'blur', this.focusOut, this);
12440
12455
  }
@@ -12847,7 +12862,7 @@ var TreeView = /** @__PURE__ @class */ (function (_super) {
12847
12862
  });
12848
12863
  this.dropObj = new Droppable(this.element, {
12849
12864
  out: function (e) {
12850
- if (!isNullOrUndefined(e) && !e.target.classList.contains(SIBLING)) {
12865
+ if (!isNullOrUndefined(e) && !e.target.classList.contains(SIBLING) && (_this.dropObj.dragData.default && _this.dropObj.dragData.default.helper.classList.contains(ROOT))) {
12851
12866
  document.body.style.cursor = 'not-allowed';
12852
12867
  }
12853
12868
  },
@@ -13546,15 +13561,29 @@ var TreeView = /** @__PURE__ @class */ (function (_super) {
13546
13561
  }
13547
13562
  }
13548
13563
  if (!refNode && ((this.sortOrder === 'Ascending') || (this.sortOrder === 'Descending'))) {
13549
- var cNodes = dropUl.childNodes;
13550
- for (var i = 0; i < li.length; i++) {
13551
- for (var j = 0; j < cNodes.length; j++) {
13552
- var returnValue = (this.sortOrder === 'Ascending') ? cNodes[j].textContent.toUpperCase() > li[i].innerText.toUpperCase() : cNodes[j].textContent.toUpperCase() < li[i].innerText.toUpperCase();
13553
- if (returnValue) {
13554
- dropUl.insertBefore(li[i], cNodes[j]);
13555
- break;
13564
+ if (dropUl.childNodes.length === 0) {
13565
+ for (var i = 0; i < li.length; i++) {
13566
+ dropUl.insertBefore(li[i], refNode);
13567
+ }
13568
+ if (this.dataType === 1 && !isNullOrUndefined(dropLi) && !isNullOrUndefined(this.element.offsetParent) && !this.element.offsetParent.parentElement.classList.contains('e-filemanager')) {
13569
+ this.preventExpand = false;
13570
+ var dropIcon = select('div.' + ICON, dropLi);
13571
+ if (dropIcon && dropIcon.classList.contains(EXPANDABLE)) {
13572
+ this.expandAction(dropLi, dropIcon, null);
13573
+ }
13574
+ }
13575
+ }
13576
+ else {
13577
+ var cNodes = dropUl.childNodes;
13578
+ for (var i = 0; i < li.length; i++) {
13579
+ for (var j = 0; j < cNodes.length; j++) {
13580
+ var returnValue = (this.sortOrder === 'Ascending') ? cNodes[j].textContent.toUpperCase() > li[i].innerText.toUpperCase() : cNodes[j].textContent.toUpperCase() < li[i].innerText.toUpperCase();
13581
+ if (returnValue) {
13582
+ dropUl.insertBefore(li[i], cNodes[j]);
13583
+ break;
13584
+ }
13585
+ dropUl.insertBefore(li[i], cNodes[cNodes.length]);
13556
13586
  }
13557
- dropUl.insertBefore(li[i], cNodes[cNodes.length]);
13558
13587
  }
13559
13588
  }
13560
13589
  }