@syncfusion/ej2-navigations 20.3.60 → 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.
Files changed (226) hide show
  1. package/.eslintrc.json +16 -1
  2. package/CHANGELOG.md +17 -0
  3. package/dist/ej2-navigations.min.js +2 -2
  4. package/dist/ej2-navigations.umd.min.js +2 -2
  5. package/dist/ej2-navigations.umd.min.js.map +1 -1
  6. package/dist/es6/ej2-navigations.es2015.js +253 -205
  7. package/dist/es6/ej2-navigations.es2015.js.map +1 -1
  8. package/dist/es6/ej2-navigations.es5.js +250 -202
  9. package/dist/es6/ej2-navigations.es5.js.map +1 -1
  10. package/dist/global/ej2-navigations.min.js +2 -2
  11. package/dist/global/ej2-navigations.min.js.map +1 -1
  12. package/dist/global/index.d.ts +1 -1
  13. package/package.json +11 -11
  14. package/src/accordion/accordion.js +20 -19
  15. package/src/appbar/appbar-model.d.ts +15 -15
  16. package/src/appbar/appbar.d.ts +15 -15
  17. package/src/appbar/appbar.js +3 -3
  18. package/src/breadcrumb/breadcrumb-model.d.ts +1 -1
  19. package/src/breadcrumb/breadcrumb.js +10 -5
  20. package/src/carousel/carousel.js +10 -10
  21. package/src/common/menu-base.js +9 -5
  22. package/src/menu/menu.js +2 -2
  23. package/src/sidebar/sidebar.d.ts +1 -0
  24. package/src/sidebar/sidebar.js +6 -2
  25. package/src/tab/tab-model.d.ts +9 -0
  26. package/src/tab/tab.d.ts +9 -0
  27. package/src/tab/tab.js +28 -18
  28. package/src/toolbar/toolbar-model.d.ts +9 -0
  29. package/src/toolbar/toolbar.d.ts +11 -0
  30. package/src/toolbar/toolbar.js +132 -123
  31. package/src/treeview/treeview-model.d.ts +133 -45
  32. package/src/treeview/treeview.d.ts +135 -48
  33. package/src/treeview/treeview.js +30 -14
  34. package/styles/accordion/_bootstrap-dark-definition.scss +100 -0
  35. package/styles/accordion/_bootstrap-definition.scss +100 -0
  36. package/styles/accordion/_bootstrap4-definition.scss +95 -1
  37. package/styles/accordion/_bootstrap5-definition.scss +99 -3
  38. package/styles/accordion/_fabric-dark-definition.scss +100 -0
  39. package/styles/accordion/_fabric-definition.scss +100 -0
  40. package/styles/accordion/_fluent-definition.scss +98 -2
  41. package/styles/accordion/_fusionnew-definition.scss +99 -3
  42. package/styles/accordion/_highcontrast-definition.scss +98 -3
  43. package/styles/accordion/_highcontrast-light-definition.scss +98 -3
  44. package/styles/accordion/_layout.scss +25 -91
  45. package/styles/accordion/_material-dark-definition.scss +100 -0
  46. package/styles/accordion/_material-definition.scss +100 -0
  47. package/styles/accordion/_material3-definition.scss +99 -3
  48. package/styles/accordion/_tailwind-definition.scss +99 -2
  49. package/styles/accordion/_theme.scss +184 -345
  50. package/styles/accordion/bootstrap-dark.css +202 -16
  51. package/styles/accordion/bootstrap.css +202 -16
  52. package/styles/accordion/bootstrap4.css +171 -17
  53. package/styles/accordion/bootstrap5-dark.css +202 -13
  54. package/styles/accordion/bootstrap5.css +202 -13
  55. package/styles/accordion/fabric-dark.css +209 -11
  56. package/styles/accordion/fabric.css +209 -11
  57. package/styles/accordion/fluent-dark.css +217 -5
  58. package/styles/accordion/fluent.css +217 -5
  59. package/styles/accordion/highcontrast-light.css +186 -52
  60. package/styles/accordion/highcontrast.css +186 -52
  61. package/styles/accordion/material-dark.css +210 -16
  62. package/styles/accordion/material.css +209 -15
  63. package/styles/accordion/tailwind-dark.css +199 -8
  64. package/styles/accordion/tailwind.css +199 -8
  65. package/styles/bootstrap-dark.css +999 -145
  66. package/styles/bootstrap.css +986 -132
  67. package/styles/bootstrap4.css +888 -167
  68. package/styles/bootstrap5-dark.css +949 -179
  69. package/styles/bootstrap5.css +949 -179
  70. package/styles/context-menu/_layout.scss +0 -3
  71. package/styles/context-menu/bootstrap5-dark.css +0 -1
  72. package/styles/context-menu/bootstrap5.css +0 -1
  73. package/styles/context-menu/fluent-dark.css +0 -1
  74. package/styles/context-menu/fluent.css +0 -1
  75. package/styles/context-menu/tailwind-dark.css +0 -1
  76. package/styles/context-menu/tailwind.css +0 -1
  77. package/styles/fabric-dark.css +1068 -232
  78. package/styles/fabric.css +1067 -231
  79. package/styles/fluent-dark.css +1014 -123
  80. package/styles/fluent.css +1012 -121
  81. package/styles/h-scroll/_bootstrap-dark-definition.scss +8 -0
  82. package/styles/h-scroll/_bootstrap-definition.scss +8 -0
  83. package/styles/h-scroll/_bootstrap4-definition.scss +8 -0
  84. package/styles/h-scroll/_bootstrap5-definition.scss +8 -0
  85. package/styles/h-scroll/_fabric-dark-definition.scss +8 -0
  86. package/styles/h-scroll/_fabric-definition.scss +8 -0
  87. package/styles/h-scroll/_fluent-definition.scss +8 -0
  88. package/styles/h-scroll/_fusionnew-definition.scss +8 -0
  89. package/styles/h-scroll/_highcontrast-definition.scss +6 -1
  90. package/styles/h-scroll/_highcontrast-light-definition.scss +6 -1
  91. package/styles/h-scroll/_layout.scss +1 -4
  92. package/styles/h-scroll/_material-dark-definition.scss +8 -0
  93. package/styles/h-scroll/_material-definition.scss +8 -0
  94. package/styles/h-scroll/_material3-definition.scss +8 -0
  95. package/styles/h-scroll/_tailwind-definition.scss +8 -0
  96. package/styles/h-scroll/_theme.scss +12 -40
  97. package/styles/h-scroll/bootstrap-dark.css +13 -0
  98. package/styles/h-scroll/bootstrap.css +13 -0
  99. package/styles/h-scroll/bootstrap4.css +7 -0
  100. package/styles/h-scroll/bootstrap5-dark.css +12 -0
  101. package/styles/h-scroll/bootstrap5.css +12 -0
  102. package/styles/h-scroll/fabric-dark.css +15 -2
  103. package/styles/h-scroll/fabric.css +15 -2
  104. package/styles/h-scroll/fluent-dark.css +13 -0
  105. package/styles/h-scroll/fluent.css +13 -0
  106. package/styles/h-scroll/highcontrast-light.css +8 -7
  107. package/styles/h-scroll/highcontrast.css +10 -9
  108. package/styles/h-scroll/icons/_fabric-dark.scss +2 -2
  109. package/styles/h-scroll/icons/_fabric.scss +2 -2
  110. package/styles/h-scroll/icons/_highcontrast.scss +2 -2
  111. package/styles/h-scroll/material-dark.css +13 -2
  112. package/styles/h-scroll/material.css +13 -2
  113. package/styles/h-scroll/tailwind-dark.css +12 -0
  114. package/styles/h-scroll/tailwind.css +12 -0
  115. package/styles/highcontrast-light.css +918 -369
  116. package/styles/highcontrast.css +925 -370
  117. package/styles/material-dark.css +1184 -114
  118. package/styles/material.css +1162 -92
  119. package/styles/menu/_theme.scss +1 -1
  120. package/styles/menu/fluent-dark.css +1 -1
  121. package/styles/menu/fluent.css +1 -1
  122. package/styles/tab/_bootstrap-dark-definition.scss +271 -15
  123. package/styles/tab/_bootstrap-definition.scss +266 -9
  124. package/styles/tab/_bootstrap4-definition.scss +266 -9
  125. package/styles/tab/_bootstrap5-definition.scss +270 -13
  126. package/styles/tab/_fabric-dark-definition.scss +270 -13
  127. package/styles/tab/_fabric-definition.scss +270 -13
  128. package/styles/tab/_fluent-definition.scss +269 -12
  129. package/styles/tab/_fusionnew-definition.scss +268 -11
  130. package/styles/tab/_highcontrast-definition.scss +271 -14
  131. package/styles/tab/_highcontrast-light-definition.scss +271 -14
  132. package/styles/tab/_layout.scss +295 -988
  133. package/styles/tab/_material-dark-definition.scss +266 -9
  134. package/styles/tab/_material-definition.scss +266 -9
  135. package/styles/tab/_material3-definition.scss +268 -11
  136. package/styles/tab/_tailwind-definition.scss +267 -10
  137. package/styles/tab/_theme.scss +305 -843
  138. package/styles/tab/bootstrap-dark.css +587 -109
  139. package/styles/tab/bootstrap.css +574 -96
  140. package/styles/tab/bootstrap4.css +546 -114
  141. package/styles/tab/bootstrap5-dark.css +523 -134
  142. package/styles/tab/bootstrap5.css +523 -134
  143. package/styles/tab/fabric-dark.css +614 -199
  144. package/styles/tab/fabric.css +612 -197
  145. package/styles/tab/fluent-dark.css +546 -102
  146. package/styles/tab/fluent.css +546 -102
  147. package/styles/tab/highcontrast-light.css +520 -250
  148. package/styles/tab/highcontrast.css +520 -244
  149. package/styles/tab/icons/_bootstrap-dark.scss +0 -33
  150. package/styles/tab/icons/_bootstrap.scss +0 -33
  151. package/styles/tab/icons/_bootstrap4.scss +0 -26
  152. package/styles/tab/icons/_bootstrap5.scss +0 -37
  153. package/styles/tab/icons/_fabric-dark.scss +0 -33
  154. package/styles/tab/icons/_fabric.scss +0 -33
  155. package/styles/tab/icons/_fluent.scss +0 -33
  156. package/styles/tab/icons/_fusionnew.scss +0 -37
  157. package/styles/tab/icons/_highcontrast-light.scss +0 -37
  158. package/styles/tab/icons/_highcontrast.scss +0 -26
  159. package/styles/tab/icons/_material-dark.scss +0 -37
  160. package/styles/tab/icons/_material.scss +0 -37
  161. package/styles/tab/icons/_material3.scss +0 -37
  162. package/styles/tab/icons/_tailwind.scss +0 -37
  163. package/styles/tab/material-dark.css +705 -54
  164. package/styles/tab/material.css +705 -54
  165. package/styles/tab/tailwind-dark.css +706 -71
  166. package/styles/tab/tailwind.css +706 -71
  167. package/styles/tailwind-dark.css +1145 -99
  168. package/styles/tailwind.css +1144 -98
  169. package/styles/toolbar/_bootstrap-dark-definition.scss +93 -0
  170. package/styles/toolbar/_bootstrap-definition.scss +93 -0
  171. package/styles/toolbar/_bootstrap4-definition.scss +94 -1
  172. package/styles/toolbar/_bootstrap5-definition.scss +94 -8
  173. package/styles/toolbar/_fabric-dark-definition.scss +92 -3
  174. package/styles/toolbar/_fabric-definition.scss +92 -3
  175. package/styles/toolbar/_fluent-definition.scss +96 -8
  176. package/styles/toolbar/_fusionnew-definition.scss +94 -8
  177. package/styles/toolbar/_highcontrast-definition.scss +93 -4
  178. package/styles/toolbar/_highcontrast-light-definition.scss +93 -4
  179. package/styles/toolbar/_layout.scss +48 -177
  180. package/styles/toolbar/_material-dark-definition.scss +93 -0
  181. package/styles/toolbar/_material-definition.scss +93 -0
  182. package/styles/toolbar/_material3-definition.scss +94 -8
  183. package/styles/toolbar/_tailwind-definition.scss +94 -6
  184. package/styles/toolbar/_theme.scss +169 -278
  185. package/styles/toolbar/bootstrap-dark.css +196 -19
  186. package/styles/toolbar/bootstrap.css +196 -19
  187. package/styles/toolbar/bootstrap4.css +164 -36
  188. package/styles/toolbar/bootstrap5-dark.css +210 -29
  189. package/styles/toolbar/bootstrap5.css +210 -29
  190. package/styles/toolbar/fabric-dark.css +219 -9
  191. package/styles/toolbar/fabric.css +220 -10
  192. package/styles/toolbar/fluent-dark.css +233 -10
  193. package/styles/toolbar/fluent.css +233 -10
  194. package/styles/toolbar/highcontrast-light.css +199 -43
  195. package/styles/toolbar/highcontrast.css +200 -44
  196. package/styles/toolbar/material-dark.css +233 -19
  197. package/styles/toolbar/material.css +233 -19
  198. package/styles/toolbar/tailwind-dark.css +224 -15
  199. package/styles/toolbar/tailwind.css +223 -14
  200. package/styles/treeview/_material-definition.scss +1 -1
  201. package/styles/treeview/_theme.scss +11 -1
  202. package/styles/treeview/fluent-dark.css +2 -2
  203. package/styles/treeview/material.css +2 -2
  204. package/styles/treeview/tailwind.css +2 -2
  205. package/styles/v-scroll/_highcontrast-definition.scss +0 -1
  206. package/styles/v-scroll/_highcontrast-light-definition.scss +0 -1
  207. package/styles/v-scroll/_theme.scss +0 -26
  208. package/styles/v-scroll/bootstrap5-dark.css +2 -2
  209. package/styles/v-scroll/bootstrap5.css +2 -2
  210. package/styles/v-scroll/fabric-dark.css +2 -2
  211. package/styles/v-scroll/fabric.css +2 -2
  212. package/styles/v-scroll/fluent-dark.css +2 -2
  213. package/styles/v-scroll/fluent.css +2 -2
  214. package/styles/v-scroll/highcontrast-light.css +2 -14
  215. package/styles/v-scroll/highcontrast.css +2 -14
  216. package/styles/v-scroll/icons/_bootstrap5.scss +2 -2
  217. package/styles/v-scroll/icons/_fabric-dark.scss +2 -2
  218. package/styles/v-scroll/icons/_fabric.scss +2 -2
  219. package/styles/v-scroll/icons/_fluent.scss +2 -2
  220. package/styles/v-scroll/icons/_fusionnew.scss +2 -2
  221. package/styles/v-scroll/icons/_highcontrast-light.scss +2 -2
  222. package/styles/v-scroll/icons/_highcontrast.scss +2 -2
  223. package/styles/v-scroll/icons/_material3.scss +2 -2
  224. package/styles/v-scroll/icons/_tailwind.scss +2 -2
  225. package/styles/v-scroll/tailwind-dark.css +2 -2
  226. package/styles/v-scroll/tailwind.css +2 -2
@@ -1273,6 +1273,7 @@ var MenuBase = /** @__PURE__ @class */ (function (_super) {
1273
1273
  this.wireEvents();
1274
1274
  this.renderComplete();
1275
1275
  var wrapper = this.getWrapper();
1276
+ // eslint-disable-next-line
1276
1277
  if (this.template && this.enableScrolling && (this.isReact || this.isAngular)) {
1277
1278
  requestAnimationFrame(function () {
1278
1279
  addScrolling(_this.createElement, wrapper, _this.element, 'hscroll', _this.enableRtl);
@@ -1659,6 +1660,7 @@ var MenuBase = /** @__PURE__ @class */ (function (_super) {
1659
1660
  _this.isCMenu = false;
1660
1661
  }
1661
1662
  if (_this.isMenu && trgtpopUp && popupId.length) {
1663
+ // eslint-disable-next-line
1662
1664
  trgtliId = new RegExp('(.*)-ej2menu-' + _this.element.id + '-popup').exec(popupId)[1];
1663
1665
  closedLi = trgtpopUp.querySelector('[id="' + trgtliId + '"]');
1664
1666
  trgtLi = (liElem_1 && trgtpopUp.querySelector('[id="' + liElem_1.id + '"]'));
@@ -1667,7 +1669,7 @@ var MenuBase = /** @__PURE__ @class */ (function (_super) {
1667
1669
  if (isOpen && _this.hamburgerMode && ulIndex && !(submenus.length)) {
1668
1670
  _this.afterCloseMenu(e);
1669
1671
  }
1670
- else if (isOpen && !_this.hamburgerMode && _this.navIdx.length && closedLi && !trgtLi && _this.keyType !== "left") {
1672
+ else if (isOpen && !_this.hamburgerMode && _this.navIdx.length && closedLi && !trgtLi && _this.keyType !== 'left') {
1671
1673
  var ele = (e && e.target.classList.contains('e-vscroll'))
1672
1674
  ? closest(e.target, '.e-menu-wrapper') : null;
1673
1675
  if (ele) {
@@ -1708,7 +1710,7 @@ var MenuBase = /** @__PURE__ @class */ (function (_super) {
1708
1710
  if (sli_1) {
1709
1711
  sli_1.setAttribute('aria-expanded', 'false');
1710
1712
  sli_1.classList.remove(SELECTED);
1711
- if (observedCloseArgs.isFocused && liElem_1 || _this.keyType === "left") {
1713
+ if (observedCloseArgs.isFocused && liElem_1 || _this.keyType === 'left') {
1712
1714
  sli_1.classList.add(FOCUSED);
1713
1715
  sli_1.focus();
1714
1716
  }
@@ -1981,6 +1983,7 @@ var MenuBase = /** @__PURE__ @class */ (function (_super) {
1981
1983
  _this.isNestedOrVertical ? _this.left - _this.popupWrapper.offsetWidth - _this.lItem.parentElement.offsetWidth + 2
1982
1984
  : _this.left - _this.popupWrapper.offsetWidth + _this.lItem.offsetWidth;
1983
1985
  }
1986
+ // eslint-disable-next-line
1984
1987
  if (_this.template && (_this.isReact || _this.isAngular)) {
1985
1988
  requestAnimationFrame(function () {
1986
1989
  _this.collision();
@@ -2238,6 +2241,7 @@ var MenuBase = /** @__PURE__ @class */ (function (_super) {
2238
2241
  if (args.item.classList.contains('e-has-child')) {
2239
2242
  args.item.classList.remove('e-has-child');
2240
2243
  }
2244
+ args.item.removeAttribute('aria-level');
2241
2245
  }
2242
2246
  var eventArgs = { item: args.curData, element: args.item };
2243
2247
  _this.trigger('beforeItemRender', eventArgs);
@@ -2337,7 +2341,7 @@ var MenuBase = /** @__PURE__ @class */ (function (_super) {
2337
2341
  };
2338
2342
  MenuBase.prototype.getField = function (propName, level) {
2339
2343
  if (level === void 0) { level = 0; }
2340
- var fieldName = this.fields[propName];
2344
+ var fieldName = this.fields["" + propName];
2341
2345
  return typeof fieldName === 'string' ? fieldName :
2342
2346
  (!fieldName[level] ? fieldName[fieldName.length - 1].toString()
2343
2347
  : fieldName[level].toString());
@@ -2355,7 +2359,7 @@ var MenuBase = /** @__PURE__ @class */ (function (_super) {
2355
2359
  };
2356
2360
  MenuBase.prototype.hasField = function (items, field) {
2357
2361
  for (var i = 0, len = items.length; i < len; i++) {
2358
- if (items[i][field]) {
2362
+ if (items[i]["" + field]) {
2359
2363
  return true;
2360
2364
  }
2361
2365
  }
@@ -2896,7 +2900,7 @@ var MenuBase = /** @__PURE__ @class */ (function (_super) {
2896
2900
  else {
2897
2901
  var ele = this.getWrapper().children[this.getIdx(this.getWrapper(), ul) - 1];
2898
2902
  if (this.currentTarget) {
2899
- if (!(this.currentTarget.classList.contains("e-numerictextbox") || this.currentTarget.classList.contains("e-textbox") || this.currentTarget.tagName === 'INPUT')) {
2903
+ if (!(this.currentTarget.classList.contains('e-numerictextbox') || this.currentTarget.classList.contains('e-textbox') || this.currentTarget.tagName === 'INPUT')) {
2900
2904
  if (ele) {
2901
2905
  ele.querySelector('.' + SELECTED).focus();
2902
2906
  }
@@ -3433,6 +3437,9 @@ var Item = /** @__PURE__ @class */ (function (_super) {
3433
3437
  __decorate$3([
3434
3438
  Event()
3435
3439
  ], Item.prototype, "click", void 0);
3440
+ __decorate$3([
3441
+ Property(-1)
3442
+ ], Item.prototype, "tabIndex", void 0);
3436
3443
  return Item;
3437
3444
  }(ChildProperty));
3438
3445
  /**
@@ -3518,7 +3525,7 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
3518
3525
  removeClass([this.element], this.cssClass.split(' '));
3519
3526
  }
3520
3527
  this.element.removeAttribute('style');
3521
- ['aria-disabled', 'aria-orientation', 'aria-haspopup', 'role'].forEach(function (attrb) {
3528
+ ['aria-disabled', 'aria-orientation', 'role'].forEach(function (attrb) {
3522
3529
  return _this.element.removeAttribute(attrb);
3523
3530
  });
3524
3531
  _super.prototype.destroy.call(this);
@@ -3558,7 +3565,16 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
3558
3565
  keyConfigs: this.keyConfigs
3559
3566
  });
3560
3567
  EventHandler.add(this.element, 'keydown', this.docKeyDown, this);
3561
- this.element.setAttribute('tabIndex', '0');
3568
+ this.updateTabIndex('0');
3569
+ };
3570
+ Toolbar.prototype.updateTabIndex = function (tabIndex) {
3571
+ var ele = this.element.querySelector('.' + CLS_ITEM + ':not(.' + CLS_DISABLE$2 + ' ):not(.' + CLS_SEPARATOR + ' ):not(.' + CLS_HIDDEN + ' )');
3572
+ if (!isNullOrUndefined(ele) && !isNullOrUndefined(ele.firstElementChild)) {
3573
+ var dataTabIndex = ele.firstElementChild.getAttribute('data-tabindex');
3574
+ if (dataTabIndex && dataTabIndex === '-1' && ele.firstElementChild.tagName !== 'INPUT') {
3575
+ ele.firstElementChild.setAttribute('tabindex', tabIndex);
3576
+ }
3577
+ }
3562
3578
  };
3563
3579
  Toolbar.prototype.unwireKeyboardEvent = function () {
3564
3580
  if (this.keyModule) {
@@ -3762,7 +3778,6 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
3762
3778
  this.activeEleRemove(ele_1);
3763
3779
  ele_1.focus();
3764
3780
  }
3765
- this.element.removeAttribute('tabindex');
3766
3781
  }
3767
3782
  }
3768
3783
  break;
@@ -3813,9 +3828,8 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
3813
3828
  else {
3814
3829
  rootEle.classList.remove(CLS_DISABLE$2);
3815
3830
  }
3816
- rootEle.setAttribute('tabindex', !value ? '0' : '-1');
3817
3831
  if (this.activeEle) {
3818
- this.activeEle.setAttribute('tabindex', !value ? '0' : '-1');
3832
+ this.activeEle.setAttribute('tabindex', this.activeEle.getAttribute('data-tabindex'));
3819
3833
  }
3820
3834
  if (this.scrollModule) {
3821
3835
  this.scrollModule.disable(value);
@@ -3952,7 +3966,7 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
3952
3966
  }
3953
3967
  setStyleAttribute(this.element, { 'width': width });
3954
3968
  var ariaAttr = {
3955
- 'role': 'toolbar', 'aria-disabled': 'false', 'aria-haspopup': 'false',
3969
+ 'role': 'toolbar', 'aria-disabled': 'false',
3956
3970
  'aria-orientation': !this.isVertical ? 'horizontal' : 'vertical'
3957
3971
  };
3958
3972
  attributes(this.element, ariaAttr);
@@ -3984,17 +3998,17 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
3984
3998
  this.tbarEle = [];
3985
3999
  }
3986
4000
  for (var i = 0; i < items.length; i++) {
3987
- innerItem = this.renderSubComponent(items[i], i);
4001
+ innerItem = this.renderSubComponent(items[parseInt(i.toString(), 10)], i);
3988
4002
  if (this.tbarEle.indexOf(innerItem) === -1) {
3989
4003
  this.tbarEle.push(innerItem);
3990
4004
  }
3991
4005
  if (!this.tbarAlign) {
3992
- this.tbarItemAlign(items[i], itemEleDom, i);
4006
+ this.tbarItemAlign(items[parseInt(i.toString(), 10)], itemEleDom, i);
3993
4007
  }
3994
- innerPos = itemEleDom.querySelector('.e-toolbar-' + items[i].align.toLowerCase());
4008
+ innerPos = itemEleDom.querySelector('.e-toolbar-' + items[parseInt(i.toString(), 10)].align.toLowerCase());
3995
4009
  if (innerPos) {
3996
- if (!(items[i].showAlwaysInPopup && items[i].overflow !== 'Show')) {
3997
- this.tbarAlgEle[(items[i].align + 's').toLowerCase()].push(innerItem);
4010
+ if (!(items[parseInt(i.toString(), 10)].showAlwaysInPopup && items[parseInt(i.toString(), 10)].overflow !== 'Show')) {
4011
+ this.tbarAlgEle[(items[parseInt(i.toString(), 10)].align + 's').toLowerCase()].push(innerItem);
3998
4012
  }
3999
4013
  innerPos.appendChild(innerItem);
4000
4014
  }
@@ -4004,7 +4018,7 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
4004
4018
  }
4005
4019
  if (this.isReact) {
4006
4020
  var portals = 'portals';
4007
- this.notify('render-react-toolbar-template', this[portals]);
4021
+ this.notify('render-react-toolbar-template', this["" + portals]);
4008
4022
  this.renderReactTemplates();
4009
4023
  }
4010
4024
  };
@@ -4161,8 +4175,11 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
4161
4175
  };
4162
4176
  Toolbar.prototype.setOverflowAttributes = function (ele) {
4163
4177
  this.createPopupEle(ele, [].slice.call(selectAll('.' + CLS_ITEMS + ' .' + CLS_ITEM, ele)));
4164
- this.element.querySelector('.' + CLS_TBARNAV).setAttribute('tabIndex', '0');
4165
- this.element.querySelector('.' + CLS_TBARNAV).setAttribute('role', 'list');
4178
+ var ariaAttr = {
4179
+ 'tabindex': '0', 'role': 'button', 'aria-haspopup': 'true',
4180
+ 'aria-label': 'overflow'
4181
+ };
4182
+ attributes(this.element.querySelector('.' + CLS_TBARNAV), ariaAttr);
4166
4183
  };
4167
4184
  Toolbar.prototype.separator = function () {
4168
4185
  var element = this.element;
@@ -4179,12 +4196,12 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
4179
4196
  }
4180
4197
  }
4181
4198
  for (var i = 0; i <= eleItem.length - 1; i++) {
4182
- if (eleItem[i].offsetLeft < 30 && eleItem[i].offsetLeft !== 0) {
4199
+ if (eleItem[parseInt(i.toString(), 10)].offsetLeft < 30 && eleItem[parseInt(i.toString(), 10)].offsetLeft !== 0) {
4183
4200
  if (this.overflowMode === 'MultiRow') {
4184
- eleItem[i].classList.add(CLS_MULTIROW_SEPARATOR);
4201
+ eleItem[parseInt(i.toString(), 10)].classList.add(CLS_MULTIROW_SEPARATOR);
4185
4202
  }
4186
4203
  else if (this.overflowMode === 'Extended') {
4187
- eleItem[i].classList.add(CLS_EXTENDABLE_SEPARATOR);
4204
+ eleItem[parseInt(i.toString(), 10)].classList.add(CLS_EXTENDABLE_SEPARATOR);
4188
4205
  }
4189
4206
  }
4190
4207
  }
@@ -4217,7 +4234,7 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
4217
4234
  nodes = selectAll('.' + CLS_TBAROVERFLOW, ele);
4218
4235
  if (el.classList.contains(CLS_TBAROVERFLOW) && nodes.length > 0) {
4219
4236
  if (tbarObj.tbResize && nodes.length > index) {
4220
- ele.insertBefore(el, nodes[index]);
4237
+ ele.insertBefore(el, nodes[parseInt(index.toString(), 10)]);
4221
4238
  ++nodePri;
4222
4239
  }
4223
4240
  else {
@@ -4255,7 +4272,7 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
4255
4272
  });
4256
4273
  var tbarEle = selectAll('.' + CLS_ITEM, element.querySelector('.' + CLS_ITEMS));
4257
4274
  for (var i = tbarEle.length - 1; i >= 0; i--) {
4258
- var tbarElement = tbarEle[i];
4275
+ var tbarElement = tbarEle[parseInt(i.toString(), 10)];
4259
4276
  if (tbarElement.classList.contains(CLS_SEPARATOR) && this.overflowMode !== 'Extended') {
4260
4277
  setStyleAttribute(tbarElement, { display: 'none' });
4261
4278
  }
@@ -4310,11 +4327,11 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
4310
4327
  collision: { Y: this.enableCollision ? 'flip' : 'none' },
4311
4328
  position: this.enableRtl ? { X: 'left', Y: 'top' } : { X: 'right', Y: 'top' }
4312
4329
  });
4313
- popup.appendTo(ele);
4314
4330
  if (this.overflowMode === 'Extended') {
4315
4331
  popup.width = parseFloat(eleStyles.width) + ((parseFloat(eleStyles.borderRightWidth)) * 2);
4316
4332
  popup.offsetX = 0;
4317
4333
  }
4334
+ popup.appendTo(ele);
4318
4335
  EventHandler.add(document, 'scroll', this.docEvent.bind(this));
4319
4336
  EventHandler.add(document, 'click ', this.docEvent.bind(this));
4320
4337
  popup.element.style.maxHeight = popup.element.offsetHeight + 'px';
@@ -4331,7 +4348,6 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
4331
4348
  popup.hide();
4332
4349
  }
4333
4350
  this.popObj = popup;
4334
- this.element.setAttribute('aria-haspopup', 'true');
4335
4351
  }
4336
4352
  else {
4337
4353
  var popupEle = this.popObj.element;
@@ -4359,6 +4375,7 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
4359
4375
  var popupEle = this.popObj.element;
4360
4376
  var toolEle = this.popObj.element.parentElement;
4361
4377
  var popupNav = toolEle.querySelector('.' + CLS_TBARNAV);
4378
+ popupNav.setAttribute('aria-expanded', 'true');
4362
4379
  setStyleAttribute(popObj.element, { height: 'auto', maxHeight: '' });
4363
4380
  popObj.element.style.maxHeight = popObj.element.offsetHeight + 'px';
4364
4381
  if (this.overflowMode === 'Extended') {
@@ -4374,7 +4391,7 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
4374
4391
  var overflowHeight = (popupEle.offsetHeight - ((popupElePos - window.innerHeight - scrollVal) + 5));
4375
4392
  popObj.height = overflowHeight + 'px';
4376
4393
  for (var i = 0; i <= popupEle.childElementCount; i++) {
4377
- var ele = popupEle.children[i];
4394
+ var ele = popupEle.children[parseInt(i.toString(), 10)];
4378
4395
  if (ele.offsetTop + ele.offsetHeight > overflowHeight) {
4379
4396
  overflowHeight = ele.offsetTop;
4380
4397
  break;
@@ -4399,6 +4416,7 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
4399
4416
  Toolbar.prototype.popupClose = function (e) {
4400
4417
  var element = this.element;
4401
4418
  var popupNav = element.querySelector('.' + CLS_TBARNAV);
4419
+ popupNav.setAttribute('aria-expanded', 'false');
4402
4420
  var popIcon = popupNav.firstElementChild;
4403
4421
  popupNav.classList.remove(CLS_TBARNAVACT);
4404
4422
  classList(popIcon, [CLS_POPUPDOWN], [CLS_POPUPICON]);
@@ -4424,7 +4442,7 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
4424
4442
  };
4425
4443
  for (var i = len - 1; i >= 0; i--) {
4426
4444
  var mrgn = void 0;
4427
- var compuStyle = window.getComputedStyle(inEle[i]);
4445
+ var compuStyle = window.getComputedStyle(inEle[parseInt(i.toString(), 10)]);
4428
4446
  if (this.isVertical) {
4429
4447
  mrgn = parseFloat((compuStyle).marginTop);
4430
4448
  mrgn += parseFloat((compuStyle).marginBottom);
@@ -4433,35 +4451,37 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
4433
4451
  mrgn = parseFloat((compuStyle).marginRight);
4434
4452
  mrgn += parseFloat((compuStyle).marginLeft);
4435
4453
  }
4436
- var fstEleCheck = inEle[i] === this.tbarEle[0];
4454
+ var fstEleCheck = inEle[parseInt(i.toString(), 10)] === this.tbarEle[0];
4437
4455
  if (fstEleCheck) {
4438
4456
  this.tbarEleMrgn = mrgn;
4439
4457
  }
4440
- eleOffset = this.isVertical ? inEle[i].offsetHeight : inEle[i].offsetWidth;
4458
+ eleOffset = this.isVertical ? inEle[parseInt(i.toString(), 10)].offsetHeight : inEle[parseInt(i.toString(), 10)].offsetWidth;
4441
4459
  var eleWid_1 = fstEleCheck ? (eleOffset + mrgn) : eleOffset;
4442
- if (checkClass(inEle[i], [CLS_POPPRI]) && popPriority) {
4443
- inEle[i].classList.add(CLS_POPUP);
4460
+ if (checkClass(inEle[parseInt(i.toString(), 10)], [CLS_POPPRI]) && popPriority) {
4461
+ inEle[parseInt(i.toString(), 10)].classList.add(CLS_POPUP);
4444
4462
  if (this.isVertical) {
4445
- setStyleAttribute(inEle[i], { display: 'none', minHeight: eleWid_1 + 'px' });
4463
+ setStyleAttribute(inEle[parseInt(i.toString(), 10)], { display: 'none', minHeight: eleWid_1 + 'px' });
4446
4464
  }
4447
4465
  else {
4448
- setStyleAttribute(inEle[i], { display: 'none', minWidth: eleWid_1 + 'px' });
4466
+ setStyleAttribute(inEle[parseInt(i.toString(), 10)], { display: 'none', minWidth: eleWid_1 + 'px' });
4449
4467
  }
4450
4468
  itemPopCount++;
4451
4469
  }
4452
4470
  if (this.isVertical) {
4453
- checkoffset = (inEle[i].offsetTop + inEle[i].offsetHeight + mrgn) > eleWidth;
4471
+ checkoffset =
4472
+ (inEle[parseInt(i.toString(), 10)].offsetTop + inEle[parseInt(i.toString(), 10)].offsetHeight + mrgn) > eleWidth;
4454
4473
  }
4455
4474
  else {
4456
- checkoffset = (inEle[i].offsetLeft + inEle[i].offsetWidth + mrgn) > eleWidth;
4475
+ checkoffset =
4476
+ (inEle[parseInt(i.toString(), 10)].offsetLeft + inEle[parseInt(i.toString(), 10)].offsetWidth + mrgn) > eleWidth;
4457
4477
  }
4458
4478
  if (checkoffset) {
4459
- if (inEle[i].classList.contains(CLS_SEPARATOR)) {
4479
+ if (inEle[parseInt(i.toString(), 10)].classList.contains(CLS_SEPARATOR)) {
4460
4480
  if (this.overflowMode === 'Extended') {
4461
4481
  if (itemCount === itemPopCount) {
4462
- var sepEle = inEle[i];
4482
+ var sepEle = inEle[parseInt(i.toString(), 10)];
4463
4483
  if (checkClass(sepEle, [CLS_SEPARATOR, CLS_TBARIGNORE])) {
4464
- inEle[i].classList.add(CLS_POPUP);
4484
+ inEle[parseInt(i.toString(), 10)].classList.add(CLS_POPUP);
4465
4485
  itemPopCount++;
4466
4486
  }
4467
4487
  }
@@ -4482,21 +4502,23 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
4482
4502
  else {
4483
4503
  itemCount++;
4484
4504
  }
4485
- if (inEle[i].classList.contains(CLS_TBAROVERFLOW) && pre) {
4486
- eleWidth -= ((this.isVertical ? inEle[i].offsetHeight : inEle[i].offsetWidth) + (mrgn));
4505
+ if (inEle[parseInt(i.toString(), 10)].classList.contains(CLS_TBAROVERFLOW) && pre) {
4506
+ eleWidth -= ((this.isVertical ? inEle[parseInt(i.toString(), 10)].offsetHeight :
4507
+ inEle[parseInt(i.toString(), 10)].offsetWidth) + (mrgn));
4487
4508
  }
4488
- else if (!checkClass(inEle[i], [CLS_SEPARATOR, CLS_TBARIGNORE])) {
4489
- inEle[i].classList.add(CLS_POPUP);
4509
+ else if (!checkClass(inEle[parseInt(i.toString(), 10)], [CLS_SEPARATOR, CLS_TBARIGNORE])) {
4510
+ inEle[parseInt(i.toString(), 10)].classList.add(CLS_POPUP);
4490
4511
  if (this.isVertical) {
4491
- setStyleAttribute(inEle[i], { display: 'none', minHeight: eleWid_1 + 'px' });
4512
+ setStyleAttribute(inEle[parseInt(i.toString(), 10)], { display: 'none', minHeight: eleWid_1 + 'px' });
4492
4513
  }
4493
4514
  else {
4494
- setStyleAttribute(inEle[i], { display: 'none', minWidth: eleWid_1 + 'px' });
4515
+ setStyleAttribute(inEle[parseInt(i.toString(), 10)], { display: 'none', minWidth: eleWid_1 + 'px' });
4495
4516
  }
4496
4517
  itemPopCount++;
4497
4518
  }
4498
4519
  else {
4499
- eleWidth -= ((this.isVertical ? inEle[i].offsetHeight : inEle[i].offsetWidth) + (mrgn));
4520
+ eleWidth -= ((this.isVertical ? inEle[parseInt(i.toString(), 10)].offsetHeight :
4521
+ inEle[parseInt(i.toString(), 10)].offsetWidth) + (mrgn));
4500
4522
  }
4501
4523
  }
4502
4524
  }
@@ -4516,7 +4538,7 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
4516
4538
  var navItem = this.createElement('div', { className: CLS_POPUPDOWN + ' e-icons' });
4517
4539
  nav.appendChild(navItem);
4518
4540
  nav.setAttribute('tabindex', '0');
4519
- nav.setAttribute('role', 'list');
4541
+ nav.setAttribute('role', 'button');
4520
4542
  element.appendChild(nav);
4521
4543
  };
4522
4544
  Toolbar.prototype.tbarPriRef = function (inEle, indx, sepPri, el, des, elWid, wid, ig) {
@@ -4590,7 +4612,6 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
4590
4612
  this.popObj.destroy();
4591
4613
  detach(this.popObj.element);
4592
4614
  this.popObj = null;
4593
- ele.setAttribute('aria-haspopup', 'false');
4594
4615
  }
4595
4616
  };
4596
4617
  Toolbar.prototype.ignoreEleFetch = function (index, innerEle) {
@@ -4669,7 +4690,7 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
4669
4690
  }
4670
4691
  index = this_1.tbarEle.indexOf(el);
4671
4692
  if (this_1.tbarAlign) {
4672
- var pos = this_1.items[index].align;
4693
+ var pos = this_1.items[parseInt(index.toString(), 10)].align;
4673
4694
  index = this_1.tbarAlgEle[(pos + 's').toLowerCase()].indexOf(el);
4674
4695
  eleSplice = this_1.tbarAlgEle[(pos + 's').toLowerCase()];
4675
4696
  innerEle = this_1.element.querySelector('.' + CLS_ITEMS + ' .' + 'e-toolbar-' + pos.toLowerCase());
@@ -4865,12 +4886,12 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
4865
4886
  var key = Object.keys(attr);
4866
4887
  var keyVal;
4867
4888
  for (var i = 0; i < key.length; i++) {
4868
- keyVal = key[i];
4889
+ keyVal = key[parseInt(i.toString(), 10)];
4869
4890
  if (keyVal === 'class') {
4870
- this.add(element, attr[keyVal]);
4891
+ this.add(element, attr["" + keyVal]);
4871
4892
  }
4872
4893
  else {
4873
- element.setAttribute(keyVal, attr[keyVal]);
4894
+ element.setAttribute(keyVal, attr["" + keyVal]);
4874
4895
  }
4875
4896
  }
4876
4897
  };
@@ -4901,14 +4922,14 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
4901
4922
  };
4902
4923
  if (!isNullOrUndefined(len) && len >= 1) {
4903
4924
  for (var a = 0, element = [].slice.call(elements); a < len; a++) {
4904
- var itemElement = element[a];
4925
+ var itemElement = element[parseInt(a.toString(), 10)];
4905
4926
  if (typeof (itemElement) === 'number') {
4906
4927
  ele = this.getElementByIndex(itemElement);
4907
4928
  if (isNullOrUndefined(ele)) {
4908
4929
  return;
4909
4930
  }
4910
4931
  else {
4911
- elements[a] = ele;
4932
+ elements[parseInt(a.toString(), 10)] = ele;
4912
4933
  }
4913
4934
  }
4914
4935
  else {
@@ -4937,8 +4958,8 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
4937
4958
  }
4938
4959
  };
4939
4960
  Toolbar.prototype.getElementByIndex = function (index) {
4940
- if (this.tbarEle[index]) {
4941
- return this.tbarEle[index];
4961
+ if (this.tbarEle[parseInt(index.toString(), 10)]) {
4962
+ return this.tbarEle[parseInt(index.toString(), 10)];
4942
4963
  }
4943
4964
  return null;
4944
4965
  };
@@ -4984,14 +5005,14 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
4984
5005
  if (!this.tbarAlign && itemAgn !== 'Left') {
4985
5006
  this.tbarItemAlign(item, itemsDiv, 1);
4986
5007
  this.tbarAlign = true;
4987
- ele = closest(innerItems[0], '.' + CLS_ITEMS).children[algIndex];
5008
+ ele = closest(innerItems[0], '.' + CLS_ITEMS).children[parseInt(algIndex.toString(), 10)];
4988
5009
  ele.appendChild(innerEle);
4989
5010
  this.tbarAlgEle[(item.align + 's').toLowerCase()].push(innerEle);
4990
5011
  this.refreshPositioning();
4991
5012
  }
4992
5013
  else if (this.tbarAlign) {
4993
- ele = closest(innerItems[0], '.' + CLS_ITEMS).children[algIndex];
4994
- ele.insertBefore(innerEle, ele.children[index]);
5014
+ ele = closest(innerItems[0], '.' + CLS_ITEMS).children[parseInt(algIndex.toString(), 10)];
5015
+ ele.insertBefore(innerEle, ele.children[parseInt(index.toString(), 10)]);
4995
5016
  this.tbarAlgEle[(item.align + 's').toLowerCase()].splice(index, 0, innerEle);
4996
5017
  this.refreshPositioning();
4997
5018
  }
@@ -5000,7 +5021,7 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
5000
5021
  innerItems[0].appendChild(innerEle);
5001
5022
  }
5002
5023
  else {
5003
- innerItems[0].parentNode.insertBefore(innerEle, innerItems[index]);
5024
+ innerItems[0].parentNode.insertBefore(innerEle, innerItems[parseInt(index.toString(), 10)]);
5004
5025
  }
5005
5026
  this.items.splice(index, 0, item);
5006
5027
  if (item.template) {
@@ -5050,20 +5071,20 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
5050
5071
  this.resize();
5051
5072
  };
5052
5073
  Toolbar.prototype.removeItemByIndex = function (index, innerItems) {
5053
- if (this.tbarEle[index] && innerItems[index]) {
5054
- var eleIdx = this.tbarEle.indexOf(innerItems[index]);
5074
+ if (this.tbarEle[parseInt(index.toString(), 10)] && innerItems[parseInt(index.toString(), 10)]) {
5075
+ var eleIdx = this.tbarEle.indexOf(innerItems[parseInt(index.toString(), 10)]);
5055
5076
  if (this.tbarAlign) {
5056
- var indexAgn = this.tbarAlgEle[(this.items[eleIdx].align + 's').toLowerCase()].indexOf(this.tbarEle[eleIdx]);
5057
- this.tbarAlgEle[(this.items[eleIdx].align + 's').toLowerCase()].splice(indexAgn, 1);
5077
+ var indexAgn = this.tbarAlgEle[(this.items[parseInt(eleIdx.toString(), 10)].align + 's').toLowerCase()].indexOf(this.tbarEle[parseInt(eleIdx.toString(), 10)]);
5078
+ this.tbarAlgEle[(this.items[parseInt(eleIdx.toString(), 10)].align + 's').toLowerCase()].splice(parseInt(indexAgn.toString(), 10), 1);
5058
5079
  }
5059
5080
  if (this.isReact) {
5060
5081
  this.clearTemplate();
5061
5082
  }
5062
- var btnItem = innerItems[index].querySelector('.e-control.e-btn');
5083
+ var btnItem = innerItems[parseInt(index.toString(), 10)].querySelector('.e-control.e-btn');
5063
5084
  if (!isNullOrUndefined(btnItem) && !isNullOrUndefined(btnItem.ej2_instances[0]) && !(btnItem.ej2_instances[0].isDestroyed)) {
5064
5085
  btnItem.ej2_instances[0].destroy();
5065
5086
  }
5066
- detach(innerItems[index]);
5087
+ detach(innerItems[parseInt(index.toString(), 10)]);
5067
5088
  this.items.splice(eleIdx, 1);
5068
5089
  this.tbarEle.splice(eleIdx, 1);
5069
5090
  }
@@ -5196,7 +5217,8 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
5196
5217
  switch (item.type) {
5197
5218
  case 'Button':
5198
5219
  dom = this.buttonRendering(item, innerEle);
5199
- dom.setAttribute('tabindex', '-1');
5220
+ dom.setAttribute('tabindex', isNullOrUndefined(item.tabIndex) ? '-1' : item.tabIndex.toString());
5221
+ dom.setAttribute('data-tabindex', isNullOrUndefined(item.tabIndex) ? '-1' : item.tabIndex.toString());
5200
5222
  dom.setAttribute('aria-label', (item.text || item.tooltipText));
5201
5223
  innerEle.appendChild(dom);
5202
5224
  innerEle.addEventListener('click', this.itemClick.bind(this));
@@ -5239,6 +5261,9 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
5239
5261
  }
5240
5262
  return innerEle;
5241
5263
  };
5264
+ Toolbar.prototype.getDataTabindex = function (ele) {
5265
+ return isNullOrUndefined(ele.getAttribute('data-tabindex')) ? '-1' : ele.getAttribute('data-tabindex');
5266
+ };
5242
5267
  Toolbar.prototype.itemClick = function (e) {
5243
5268
  this.activeEleSwitch(e.currentTarget);
5244
5269
  };
@@ -5248,14 +5273,17 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
5248
5273
  };
5249
5274
  Toolbar.prototype.activeEleRemove = function (curEle) {
5250
5275
  if (!isNullOrUndefined(this.activeEle)) {
5251
- this.activeEle.setAttribute('tabindex', '-1');
5276
+ this.activeEle.setAttribute('tabindex', this.getDataTabindex(this.activeEle));
5252
5277
  }
5253
5278
  this.activeEle = curEle;
5254
- if (isNullOrUndefined(this.trgtEle) && !curEle.parentElement.classList.contains(CLS_TEMPLATE)) {
5255
- curEle.removeAttribute('tabindex');
5256
- }
5257
- else {
5258
- this.activeEle.setAttribute('tabindex', '0');
5279
+ if (this.getDataTabindex(this.activeEle) === '-1') {
5280
+ if (isNullOrUndefined(this.trgtEle) && !curEle.parentElement.classList.contains(CLS_TEMPLATE)) {
5281
+ this.updateTabIndex('-1');
5282
+ curEle.removeAttribute('tabindex');
5283
+ }
5284
+ else {
5285
+ this.activeEle.setAttribute('tabindex', this.getDataTabindex(this.activeEle));
5286
+ }
5259
5287
  }
5260
5288
  };
5261
5289
  Toolbar.prototype.getPersistData = function () {
@@ -5337,6 +5365,26 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
5337
5365
  this.isExtendedOpen = sib.classList.contains(CLS_POPUPOPEN);
5338
5366
  }
5339
5367
  };
5368
+ Toolbar.prototype.updateHideEleTabIndex = function (ele, isHidden, isElement, eleIndex, innerItems) {
5369
+ if (isElement) {
5370
+ eleIndex = innerItems.indexOf(ele);
5371
+ }
5372
+ var nextEle = innerItems[++eleIndex];
5373
+ while (nextEle) {
5374
+ var skipEle = this.eleContains(nextEle);
5375
+ if (!skipEle) {
5376
+ var dataTabIndex = nextEle.firstElementChild.getAttribute('data-tabindex');
5377
+ if (isHidden && dataTabIndex === '-1') {
5378
+ nextEle.firstElementChild.setAttribute('tabindex', '0');
5379
+ }
5380
+ else if (dataTabIndex !== nextEle.firstElementChild.getAttribute('tabindex')) {
5381
+ nextEle.firstElementChild.setAttribute('tabindex', dataTabIndex);
5382
+ }
5383
+ break;
5384
+ }
5385
+ nextEle = innerItems[++eleIndex];
5386
+ }
5387
+ };
5340
5388
  /**
5341
5389
  * Gets called when the model property changes.The data that describes the old and new values of the property that changed.
5342
5390
  *
@@ -5356,9 +5404,9 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
5356
5404
  if (!(newProp.items instanceof Array && oldProp.items instanceof Array)) {
5357
5405
  var changedProb = Object.keys(newProp.items);
5358
5406
  for (var i = 0; i < changedProb.length; i++) {
5359
- var index = parseInt(Object.keys(newProp.items)[i], 10);
5360
- var property = Object.keys(newProp.items[index])[0];
5361
- var newProperty = Object(newProp.items[index])[property];
5407
+ var index = parseInt(Object.keys(newProp.items)[parseInt(i.toString(), 10)], 10);
5408
+ var property = Object.keys(newProp.items[parseInt(index.toString(), 10)])[0];
5409
+ var newProperty = Object(newProp.items[parseInt(index.toString(), 10)])["" + property];
5362
5410
  if (typeof newProperty !== 'function') {
5363
5411
  if (this.tbarAlign || property === 'align') {
5364
5412
  this.refresh();
@@ -5367,7 +5415,7 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
5367
5415
  }
5368
5416
  var popupPriCheck = property === 'showAlwaysInPopup' && !newProperty;
5369
5417
  var booleanCheck = property === 'overflow' && this.popupPriCount !== 0;
5370
- if ((popupPriCheck) || (this.items[index].showAlwaysInPopup) && booleanCheck) {
5418
+ if ((popupPriCheck) || (this.items[parseInt(index.toString(), 10)].showAlwaysInPopup) && booleanCheck) {
5371
5419
  --this.popupPriCount;
5372
5420
  }
5373
5421
  if (isNullOrUndefined(this.scrollModule)) {
@@ -5377,11 +5425,11 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
5377
5425
  if (this.isReact) {
5378
5426
  this.clearTemplate();
5379
5427
  }
5380
- detach(itemCol[index]);
5428
+ detach(itemCol[parseInt(index.toString(), 10)]);
5381
5429
  this.tbarEle.splice(index, 1);
5382
- this.addItems([this.items[index]], index);
5430
+ this.addItems([this.items[parseInt(index.toString(), 10)]], index);
5383
5431
  this.items.splice(index, 1);
5384
- if (this.items[index].template) {
5432
+ if (this.items[parseInt(index.toString(), 10)].template) {
5385
5433
  this.tbarEle.splice(this.items.length, 1);
5386
5434
  }
5387
5435
  }
@@ -5473,67 +5521,32 @@ var Toolbar = /** @__PURE__ @class */ (function (_super) {
5473
5521
  Toolbar.prototype.hideItem = function (index, value) {
5474
5522
  var isElement = (typeof (index) === 'object') ? true : false;
5475
5523
  var eleIndex = index;
5476
- var initIndex;
5477
5524
  var ele;
5525
+ if (!isElement && isNullOrUndefined(eleIndex)) {
5526
+ return;
5527
+ }
5478
5528
  var innerItems = [].slice.call(selectAll('.' + CLS_ITEM, this.element));
5479
5529
  if (isElement) {
5480
5530
  ele = index;
5481
5531
  }
5482
- else if (this.tbarEle[eleIndex]) {
5532
+ else if (this.tbarEle[parseInt(eleIndex.toString(), 10)]) {
5483
5533
  var innerItems_1 = [].slice.call(selectAll('.' + CLS_ITEM, this.element));
5484
- ele = innerItems_1[eleIndex];
5534
+ ele = innerItems_1[parseInt(eleIndex.toString(), 10)];
5485
5535
  }
5486
5536
  if (ele) {
5487
5537
  if (value) {
5488
5538
  ele.classList.add(CLS_HIDDEN);
5489
- }
5490
- else {
5491
- ele.classList.remove(CLS_HIDDEN);
5492
- }
5493
- if (value && isNullOrUndefined(this.element.getAttribute('tabindex')) && !ele.classList.contains(CLS_SEPARATOR)) {
5494
- if (isNullOrUndefined(ele.firstElementChild.getAttribute('tabindex'))) {
5495
- ele.firstElementChild.setAttribute('tabindex', '-1');
5496
- var innerItems_2 = [].slice.call(selectAll('.' + CLS_ITEM, this.element));
5497
- if (isElement) {
5498
- eleIndex = innerItems_2.indexOf(ele);
5499
- }
5500
- var nextEle = innerItems_2[++eleIndex];
5501
- while (nextEle) {
5502
- var skipEle = this.eleContains(nextEle);
5503
- if (!skipEle) {
5504
- nextEle.firstElementChild.removeAttribute('tabindex');
5505
- break;
5506
- }
5507
- nextEle = innerItems_2[++eleIndex];
5539
+ if (!ele.classList.contains(CLS_SEPARATOR)) {
5540
+ if (isNullOrUndefined(ele.firstElementChild.getAttribute('tabindex')) ||
5541
+ ele.firstElementChild.getAttribute('tabindex') !== '-1') {
5542
+ this.updateHideEleTabIndex(ele, value, isElement, eleIndex, innerItems);
5508
5543
  }
5509
5544
  }
5510
5545
  }
5511
- else if (isNullOrUndefined(this.element.getAttribute('tabindex')) && !ele.classList.contains(CLS_SEPARATOR)) {
5512
- initIndex = 0;
5513
- var setFlag = false;
5514
- var removeFlag = false;
5515
- var initELe = innerItems[initIndex];
5516
- while (initELe) {
5517
- if (!initELe.classList.contains(CLS_SEPARATOR)) {
5518
- if (isNullOrUndefined(initELe.firstElementChild.getAttribute('tabindex'))) {
5519
- initELe.firstElementChild.setAttribute('tabindex', '-1');
5520
- setFlag = true;
5521
- }
5522
- else {
5523
- if (setFlag && removeFlag) {
5524
- break;
5525
- }
5526
- var skipEle = this.eleContains(initELe);
5527
- if (!skipEle) {
5528
- initELe.firstElementChild.removeAttribute('tabindex');
5529
- removeFlag = true;
5530
- }
5531
- initELe = innerItems[++initIndex];
5532
- }
5533
- }
5534
- else {
5535
- initELe = innerItems[++initIndex];
5536
- }
5546
+ else {
5547
+ ele.classList.remove(CLS_HIDDEN);
5548
+ if (!ele.classList.contains(CLS_SEPARATOR)) {
5549
+ this.updateHideEleTabIndex(ele, value, isElement, eleIndex, innerItems);
5537
5550
  }
5538
5551
  }
5539
5552
  this.refreshOverflow();
@@ -5929,7 +5942,7 @@ var Accordion = /** @__PURE__ @class */ (function (_super) {
5929
5942
  }
5930
5943
  else {
5931
5944
  for (var i = 0; i < len; i++) {
5932
- this.expandItem(true, this.initExpand[i]);
5945
+ this.expandItem(true, this.initExpand[parseInt(i.toString(), 10)]);
5933
5946
  }
5934
5947
  }
5935
5948
  if (this.isReact) {
@@ -6291,14 +6304,15 @@ var Accordion = /** @__PURE__ @class */ (function (_super) {
6291
6304
  if (this.isReact) {
6292
6305
  this.renderReactTemplates();
6293
6306
  }
6294
- append(this.getItemTemplate()(this.dataSource[index], this, 'itemTemplate', this.element.id + '_itemTemplate', false), ctn);
6307
+ append(this.getItemTemplate()(this.dataSource[parseInt(index.toString(), 10)], this, 'itemTemplate', this.element.id + '_itemTemplate', false), ctn);
6295
6308
  itemcnt.appendChild(ctn);
6296
6309
  }
6297
6310
  else {
6298
- if (this.enableHtmlSanitizer && typeof (this.items[index].content)) {
6299
- this.items[index].content = SanitizeHtmlHelper.sanitize(this.items[index].content);
6311
+ if (this.enableHtmlSanitizer && typeof (this.items[parseInt(index.toString(), 10)].content)) {
6312
+ this.items[parseInt(index.toString(), 10)].content =
6313
+ SanitizeHtmlHelper.sanitize(this.items[parseInt(index.toString(), 10)].content);
6300
6314
  }
6301
- itemcnt.appendChild(this.fetchElement(ctn, this.items[index].content, index, false));
6315
+ itemcnt.appendChild(this.fetchElement(ctn, this.items[parseInt(index.toString(), 10)].content, index, false));
6302
6316
  }
6303
6317
  return itemcnt;
6304
6318
  };
@@ -6545,7 +6559,7 @@ var Accordion = /** @__PURE__ @class */ (function (_super) {
6545
6559
  ele.appendChild(innerItemEle);
6546
6560
  }
6547
6561
  else {
6548
- ele.insertBefore(innerItemEle, itemEle[itemIndex]);
6562
+ ele.insertBefore(innerItemEle, itemEle[parseInt(itemIndex.toString(), 10)]);
6549
6563
  }
6550
6564
  EventHandler.add(innerItemEle.querySelector('.' + CLS_HEADER), 'focus', _this.focusIn, _this);
6551
6565
  EventHandler.add(innerItemEle.querySelector('.' + CLS_HEADER), 'blur', _this.focusOut, _this);
@@ -6581,7 +6595,7 @@ var Accordion = /** @__PURE__ @class */ (function (_super) {
6581
6595
  this.clearTemplate(['headerTemplate', 'itemTemplate'], index);
6582
6596
  }
6583
6597
  var itemEle = this.getItemElements();
6584
- var ele = itemEle[index];
6598
+ var ele = itemEle[parseInt(index.toString(), 10)];
6585
6599
  var items = this.getItems();
6586
6600
  if (isNullOrUndefined(ele)) {
6587
6601
  return;
@@ -6600,7 +6614,7 @@ var Accordion = /** @__PURE__ @class */ (function (_super) {
6600
6614
  */
6601
6615
  Accordion.prototype.select = function (index) {
6602
6616
  var itemEle = this.getItemElements();
6603
- var ele = itemEle[index];
6617
+ var ele = itemEle[parseInt(index.toString(), 10)];
6604
6618
  if (isNullOrUndefined(ele) || isNullOrUndefined(select('.' + CLS_HEADER, ele))) {
6605
6619
  return;
6606
6620
  }
@@ -6616,7 +6630,7 @@ var Accordion = /** @__PURE__ @class */ (function (_super) {
6616
6630
  */
6617
6631
  Accordion.prototype.hideItem = function (index, isHidden) {
6618
6632
  var itemEle = this.getItemElements();
6619
- var ele = itemEle[index];
6633
+ var ele = itemEle[parseInt(index.toString(), 10)];
6620
6634
  if (isNullOrUndefined(ele)) {
6621
6635
  return;
6622
6636
  }
@@ -6640,7 +6654,7 @@ var Accordion = /** @__PURE__ @class */ (function (_super) {
6640
6654
  */
6641
6655
  Accordion.prototype.enableItem = function (index, isEnable) {
6642
6656
  var itemEle = this.getItemElements();
6643
- var ele = itemEle[index];
6657
+ var ele = itemEle[parseInt(index.toString(), 10)];
6644
6658
  if (isNullOrUndefined(ele)) {
6645
6659
  return;
6646
6660
  }
@@ -6692,7 +6706,7 @@ var Accordion = /** @__PURE__ @class */ (function (_super) {
6692
6706
  }
6693
6707
  }
6694
6708
  else {
6695
- var ele = itemEle[index];
6709
+ var ele = itemEle[parseInt(index.toString(), 10)];
6696
6710
  if (isNullOrUndefined(ele) || !ele.classList.contains(CLS_SLCT) || (ele.classList.contains(CLS_ACTIVE) && isExpand)) {
6697
6711
  return;
6698
6712
  }
@@ -6742,7 +6756,7 @@ var Accordion = /** @__PURE__ @class */ (function (_super) {
6742
6756
  ctnElePos = this.element;
6743
6757
  }
6744
6758
  else {
6745
- ctnElePos = this.element.querySelectorAll('.' + CLS_ITEM$1)[index];
6759
+ ctnElePos = this.element.querySelectorAll('.' + CLS_ITEM$1)[parseInt(index.toString(), 10)];
6746
6760
  }
6747
6761
  this.templateEle.forEach(function (eleStr) {
6748
6762
  if (!isNullOrUndefined(ctnElePos.querySelector(eleStr))) {
@@ -6753,7 +6767,7 @@ var Accordion = /** @__PURE__ @class */ (function (_super) {
6753
6767
  Accordion.prototype.updateItem = function (item, index) {
6754
6768
  if (!isNullOrUndefined(item)) {
6755
6769
  var items = this.getItems();
6756
- var itemObj = items[index];
6770
+ var itemObj = items[parseInt(index.toString(), 10)];
6757
6771
  items.splice(index, 1);
6758
6772
  this.restoreContent(index);
6759
6773
  detach(item);
@@ -6798,11 +6812,11 @@ var Accordion = /** @__PURE__ @class */ (function (_super) {
6798
6812
  if (!(newProp.items instanceof Array && oldProp.items instanceof Array)) {
6799
6813
  var changedProp = Object.keys(newProp.items);
6800
6814
  for (var j = 0; j < changedProp.length; j++) {
6801
- var index = parseInt(Object.keys(newProp.items)[j], 10);
6802
- var property = Object.keys(newProp.items[index])[0];
6803
- var item = selectAll('.' + CLS_ITEM$1, this.element)[index];
6804
- var oldVal = Object(oldProp.items[index])[property];
6805
- var newVal = Object(newProp.items[index])[property];
6815
+ var index = parseInt(Object.keys(newProp.items)[parseInt(j.toString(), 10)], 10);
6816
+ var property = Object.keys(newProp.items[parseInt(index.toString(), 10)])[0];
6817
+ var item = selectAll('.' + CLS_ITEM$1, this.element)[parseInt(index.toString(), 10)];
6818
+ var oldVal = Object(oldProp.items[parseInt(index.toString(), 10)])["" + property];
6819
+ var newVal = Object(newProp.items[parseInt(index.toString(), 10)])["" + property];
6806
6820
  var temp = property;
6807
6821
  if (temp === 'header' || temp === 'iconCss' || temp === 'expanded' || ((temp === 'content') && (oldVal === ''))) {
6808
6822
  this.updateItem(item, index);
@@ -6816,7 +6830,7 @@ var Accordion = /** @__PURE__ @class */ (function (_super) {
6816
6830
  }
6817
6831
  }
6818
6832
  if (property === 'visible' && !isNullOrUndefined(item)) {
6819
- if (Object(newProp.items[index])[property] === false) {
6833
+ if (Object(newProp.items[parseInt(index.toString(), 10)])["" + property] === false) {
6820
6834
  item.classList.add(CLS_ITEMHIDE);
6821
6835
  }
6822
6836
  else {
@@ -7298,8 +7312,8 @@ var Menu = /** @__PURE__ @class */ (function (_super) {
7298
7312
  var i;
7299
7313
  var items = this.items;
7300
7314
  var pIdField = this.getField('parentId');
7301
- if (item[pIdField]) {
7302
- idx = this.getIndex(item[pIdField].toString(), true);
7315
+ if (item["" + pIdField]) {
7316
+ idx = this.getIndex(item["" + pIdField].toString(), true);
7303
7317
  for (i = 0; i < idx.length; i++) {
7304
7318
  if (!items[idx[i]].items) {
7305
7319
  items[idx[i]].items = [];
@@ -7509,6 +7523,9 @@ var TabItem = /** @__PURE__ @class */ (function (_super) {
7509
7523
  __decorate$7([
7510
7524
  Property()
7511
7525
  ], TabItem.prototype, "id", void 0);
7526
+ __decorate$7([
7527
+ Property(-1)
7528
+ ], TabItem.prototype, "tabIndex", void 0);
7512
7529
  return TabItem;
7513
7530
  }(ChildProperty));
7514
7531
  /**
@@ -7712,9 +7729,10 @@ var Tab = /** @__PURE__ @class */ (function (_super) {
7712
7729
  this.setContentHeight(true);
7713
7730
  this.select(this.selectedItem);
7714
7731
  }
7732
+ this.tbItem = selectAll('.' + CLS_TB_ITEM, this.hdrEle);
7715
7733
  if (!isNullOrUndefined(this.tbItem)) {
7716
7734
  for (var i = 0; i < this.items.length; i++) {
7717
- if (this.items[i]) {
7735
+ if (this.tbItem[i]) {
7718
7736
  var tabID = this.items[i].id;
7719
7737
  this.tbItem[i].setAttribute('data-id', tabID);
7720
7738
  }
@@ -7817,7 +7835,7 @@ var Tab = /** @__PURE__ @class */ (function (_super) {
7817
7835
  if (!this.isReplace && tbItems.length > 0) {
7818
7836
  var idList_1 = [];
7819
7837
  tbItems.forEach(function (item) {
7820
- idList_1.push(parseInt(item.id.slice(item.id.indexOf('_') + 1), 10));
7838
+ idList_1.push(_this.getIndexFromEle(item.id));
7821
7839
  });
7822
7840
  maxId = Math.max.apply(Math, idList_1);
7823
7841
  }
@@ -7838,8 +7856,7 @@ var Tab = /** @__PURE__ @class */ (function (_super) {
7838
7856
  }
7839
7857
  var itemIndex;
7840
7858
  if (_this.isReplace && !isNullOrUndefined(_this.tbId) && _this.tbId !== '') {
7841
- var num = (_this.tbId.indexOf('_'));
7842
- itemIndex = parseInt(_this.tbId.substring(num + 1), 10);
7859
+ itemIndex = parseInt(_this.tbId.substring(_this.tbId.lastIndexOf('_') + 1), 10);
7843
7860
  _this.tbId = '';
7844
7861
  }
7845
7862
  else {
@@ -7881,7 +7898,8 @@ var Tab = /** @__PURE__ @class */ (function (_super) {
7881
7898
  _this.isIconAlone = true;
7882
7899
  }
7883
7900
  }
7884
- var wrapAttrs = (item.disabled) ? {} : { tabIndex: '-1' };
7901
+ var tabIndex = isNullOrUndefined(item.tabIndex) ? '-1' : item.tabIndex.toString();
7902
+ var wrapAttrs = (item.disabled) ? {} : { tabIndex: tabIndex, 'data-tabindex': tabIndex };
7885
7903
  tCont.appendChild(_this.btnCls.cloneNode(true));
7886
7904
  var wrap = _this.createElement('div', { className: CLS_WRAP, attrs: wrapAttrs });
7887
7905
  wrap.appendChild(tCont);
@@ -8326,14 +8344,14 @@ var Tab = /** @__PURE__ @class */ (function (_super) {
8326
8344
  }
8327
8345
  else {
8328
8346
  if (!this.isVertical()) {
8329
- setStyleAttribute(this.cntEle, { 'height': (this.element.offsetHeight - hdrEle.offsetHeight) + 'px' });
8347
+ setStyleAttribute(this.cntEle, { 'height': (this.element.clientHeight - hdrEle.offsetHeight) + 'px' });
8330
8348
  }
8331
8349
  }
8332
8350
  }
8333
8351
  else if (this.heightAdjustMode === 'Fill') {
8334
8352
  addClass([this.element], [CLS_FILL]);
8335
8353
  setStyleAttribute(this.element, { 'height': '100%' });
8336
- setStyleAttribute(this.cntEle, { 'height': (this.element.offsetHeight - hdrEle.offsetHeight) + 'px' });
8354
+ this.cntEle.style.height = 'calc(100% - ' + this.hdrEle.offsetHeight + 'px)';
8337
8355
  }
8338
8356
  else if (this.heightAdjustMode === 'Auto') {
8339
8357
  if (this.isTemplate === true) {
@@ -8673,12 +8691,14 @@ var Tab = /** @__PURE__ @class */ (function (_super) {
8673
8691
  case 'shiftTab':
8674
8692
  if (trg.classList.contains(CLS_WRAP)
8675
8693
  && closest(trg, '.' + CLS_TB_ITEM).classList.contains(CLS_ACTIVE$1) === false) {
8676
- trg.setAttribute('tabindex', '-1');
8694
+ trg.setAttribute('tabindex', trg.getAttribute('data-tabindex'));
8677
8695
  }
8678
8696
  if (this.popObj && isVisible(this.popObj.element)) {
8679
8697
  this.popObj.hide(this.hide);
8680
8698
  }
8681
- actEle.children.item(0).setAttribute('tabindex', '0');
8699
+ if (!isNullOrUndefined(actEle) && actEle.children.item(0).getAttribute('tabindex') === '-1') {
8700
+ actEle.children.item(0).setAttribute('tabindex', '0');
8701
+ }
8682
8702
  break;
8683
8703
  case 'moveLeft':
8684
8704
  case 'moveRight':
@@ -8728,6 +8748,9 @@ var Tab = /** @__PURE__ @class */ (function (_super) {
8728
8748
  return;
8729
8749
  }
8730
8750
  };
8751
+ Tab.prototype.getIndexFromEle = function (id) {
8752
+ return parseInt(id.substring(id.lastIndexOf('_') + 1), 10);
8753
+ };
8731
8754
  Tab.prototype.hoverHandler = function (e) {
8732
8755
  var trg = e.target;
8733
8756
  if (!isNullOrUndefined(trg.classList) && trg.classList.contains(CLS_ICON_CLOSE)) {
@@ -8746,8 +8769,7 @@ var Tab = /** @__PURE__ @class */ (function (_super) {
8746
8769
  var hdr = this.element.querySelectorAll('.' + CLS_TB_ITEM)[index];
8747
8770
  var itemIndex = void 0;
8748
8771
  if (hdr && !isNullOrUndefined(hdr.id) && hdr.id !== '') {
8749
- var num = (hdr.id.lastIndexOf('_'));
8750
- itemIndex = parseInt(hdr.id.substring(num + 1), 10);
8772
+ itemIndex = this.getIndexFromEle(hdr.id);
8751
8773
  }
8752
8774
  else {
8753
8775
  itemIndex = index;
@@ -9065,7 +9087,7 @@ var Tab = /** @__PURE__ @class */ (function (_super) {
9065
9087
  }
9066
9088
  if (value === true) {
9067
9089
  tbItems.classList.remove(CLS_DISABLE$4, CLS_OVERLAY$2);
9068
- tbItems.firstElementChild.setAttribute('tabindex', '-1');
9090
+ tbItems.firstElementChild.setAttribute('tabindex', tbItems.firstElementChild.getAttribute('data-tabindex'));
9069
9091
  }
9070
9092
  else {
9071
9093
  tbItems.classList.add(CLS_DISABLE$4, CLS_OVERLAY$2);
@@ -9326,7 +9348,7 @@ var Tab = /** @__PURE__ @class */ (function (_super) {
9326
9348
  this.selectingID = this.extIndex(trg.id);
9327
9349
  }
9328
9350
  if (!isNullOrUndefined(this.prevItem) && !this.prevItem.classList.contains(CLS_DISABLE$4)) {
9329
- this.prevItem.children.item(0).setAttribute('tabindex', '-1');
9351
+ this.prevItem.children.item(0).setAttribute('tabindex', this.prevItem.firstElementChild.getAttribute('tabindex'));
9330
9352
  }
9331
9353
  var eventArg = {
9332
9354
  event: event,
@@ -9574,7 +9596,8 @@ var Tab = /** @__PURE__ @class */ (function (_super) {
9574
9596
  this.isIconAlone = true;
9575
9597
  }
9576
9598
  }
9577
- var wrapAtt = (item.disabled) ? {} : { tabIndex: '-1' };
9599
+ var tabIndex = isNullOrUndefined(item.tabIndex) ? '-1' : item.tabIndex.toString();
9600
+ var wrapAtt = (item.disabled) ? {} : { tabIndex: tabIndex, 'data-tabindex': tabIndex };
9578
9601
  tConts.appendChild(this.btnCls.cloneNode(true));
9579
9602
  var wraper = this.createElement('div', { className: CLS_WRAP, attrs: wrapAtt });
9580
9603
  wraper.appendChild(tConts);
@@ -9618,9 +9641,7 @@ var Tab = /** @__PURE__ @class */ (function (_super) {
9618
9641
  else {
9619
9642
  var tabItems = this.element.querySelector('.' + CLS_TB_ITEMS);
9620
9643
  var element = this.element.querySelector('.' + CLS_TB_ITEM + '.' + CLS_ACTIVE$1);
9621
- var id = element.id;
9622
- var num = (id.indexOf('_'));
9623
- var index = parseInt(id.substring(num + 1), 10);
9644
+ var index = this.getIndexFromEle(element.id);
9624
9645
  var header = element.innerText;
9625
9646
  var detachContent = this.element.querySelector('.' + CLS_CONTENT$1).querySelector('.' + CLS_ACTIVE$1).children[0];
9626
9647
  var mainContents = detachContent.innerHTML;
@@ -9639,7 +9660,10 @@ var Tab = /** @__PURE__ @class */ (function (_super) {
9639
9660
  var conte = this.createElement('div', {
9640
9661
  className: CLS_TEXT_WRAP, innerHTML: txtString + this.btnCls.outerHTML
9641
9662
  }).outerHTML;
9642
- var wrap = this.createElement('div', { className: CLS_WRAP, innerHTML: conte, attrs: { tabIndex: '-1' } });
9663
+ var tabIndex = element.firstElementChild.getAttribute('data-tabindex');
9664
+ var wrap = this.createElement('div', {
9665
+ className: CLS_WRAP, innerHTML: conte, attrs: { tabIndex: tabIndex, 'data-tabindex': tabIndex }
9666
+ });
9643
9667
  tabItems.insertBefore(this.createElement('div', attr), tabItems.children[index + 1]);
9644
9668
  this.element.querySelector('.' + CLS_TB_ITEM + '.' + CLS_ACTIVE$1).appendChild(wrap);
9645
9669
  var crElem = this.createElement('div', { innerHTML: mainContents });
@@ -9824,6 +9848,7 @@ var SMALL = 'e-small';
9824
9848
  var CHILD = 'e-has-child';
9825
9849
  var ITEM_ANIMATION_ACTIVE = 'e-animation-active';
9826
9850
  var DISABLED$1 = 'e-disabled';
9851
+ var PREVENTSELECT = 'e-prevent';
9827
9852
  var treeAriaAttr = {
9828
9853
  treeRole: 'group',
9829
9854
  itemRole: 'treeitem',
@@ -9872,6 +9897,9 @@ var FieldsSettings = /** @__PURE__ @class */ (function (_super) {
9872
9897
  __decorate$8([
9873
9898
  Property(null)
9874
9899
  ], FieldsSettings.prototype, "query", void 0);
9900
+ __decorate$8([
9901
+ Property('selectable')
9902
+ ], FieldsSettings.prototype, "selectable", void 0);
9875
9903
  __decorate$8([
9876
9904
  Property('selected')
9877
9905
  ], FieldsSettings.prototype, "selected", void 0);
@@ -9928,11 +9956,11 @@ var NodeAnimationSettings = /** @__PURE__ @class */ (function (_super) {
9928
9956
  * The TreeView component is used to represent hierarchical data in a tree like structure with advanced
9929
9957
  * functions to perform edit, drag and drop, selection with check-box, and more.
9930
9958
  * ```html
9931
- * <div id="tree"></div>
9959
+ * <div id="tree"></div>
9932
9960
  * ```
9933
9961
  * ```typescript
9934
- * let treeObj: TreeView = new TreeView();
9935
- * treeObj.appendTo('#tree');
9962
+ * let treeObj: TreeView = new TreeView();
9963
+ * treeObj.appendTo('#tree');
9936
9964
  * ```
9937
9965
  */
9938
9966
  var TreeView = /** @__PURE__ @class */ (function (_super) {
@@ -9951,7 +9979,7 @@ var TreeView = /** @__PURE__ @class */ (function (_super) {
9951
9979
  _this.changeDataSource = false;
9952
9980
  _this.hasTemplate = false;
9953
9981
  _this.isFirstRender = false;
9954
- // Specifies whether the node is dropped or not
9982
+ // Specifies whether the node is dropped or not
9955
9983
  _this.isNodeDropped = false;
9956
9984
  _this.mouseDownStatus = false;
9957
9985
  return _this;
@@ -10003,7 +10031,9 @@ var TreeView = /** @__PURE__ @class */ (function (_super) {
10003
10031
  csEnter: 'ctrl+shift+enter',
10004
10032
  csHome: 'ctrl+shift+home',
10005
10033
  csEnd: 'ctrl+shift+end',
10006
- space: 'space'
10034
+ space: 'space',
10035
+ shiftSpace: 'shift+space',
10036
+ ctrlSpace: 'ctrl+space'
10007
10037
  };
10008
10038
  this.listBaseOption = {
10009
10039
  expandCollapse: true,
@@ -10526,6 +10556,10 @@ var TreeView = /** @__PURE__ @class */ (function (_super) {
10526
10556
  };
10527
10557
  if (!this.isRefreshed) {
10528
10558
  this.trigger('drawNode', eventArgs);
10559
+ if (e.curData[this.fields.selectable] === false && !this.showCheckBox) {
10560
+ e.item.classList.add(PREVENTSELECT);
10561
+ e.item.firstElementChild.setAttribute('style', 'cursor: not-allowed');
10562
+ }
10529
10563
  }
10530
10564
  };
10531
10565
  TreeView.prototype.frameMouseHandler = function (e) {
@@ -11215,7 +11249,7 @@ var TreeView = /** @__PURE__ @class */ (function (_super) {
11215
11249
  else {
11216
11250
  var classList$$1 = target.classList;
11217
11251
  var li = closest(target, '.' + LISTITEM);
11218
- if (!li) {
11252
+ if (!li || (li.classList.contains(PREVENTSELECT) && !(classList$$1.contains(EXPANDABLE) || classList$$1.contains(COLLAPSIBLE)))) {
11219
11253
  return;
11220
11254
  }
11221
11255
  else if (event.originalEvent.which !== 3) {
@@ -11689,7 +11723,7 @@ var TreeView = /** @__PURE__ @class */ (function (_super) {
11689
11723
  if (this.isLoaded) {
11690
11724
  eventArgs = this.getSelectEvent(li, 'select', e);
11691
11725
  this.trigger('nodeSelecting', eventArgs, function (observedArgs) {
11692
- if (!observedArgs.cancel) {
11726
+ if (!observedArgs.cancel && !observedArgs.node.classList.contains(PREVENTSELECT)) {
11693
11727
  _this.nodeSelectAction(li, e, observedArgs, multiSelect);
11694
11728
  }
11695
11729
  });
@@ -11907,6 +11941,9 @@ var TreeView = /** @__PURE__ @class */ (function (_super) {
11907
11941
  if (_this.showCheckBox) {
11908
11942
  _this.checkNode(e);
11909
11943
  }
11944
+ else {
11945
+ _this.toggleSelect(focusedNode, e);
11946
+ }
11910
11947
  break;
11911
11948
  case 'moveRight':
11912
11949
  _this.openNode(_this.enableRtl ? false : true, e);
@@ -11946,6 +11983,8 @@ var TreeView = /** @__PURE__ @class */ (function (_super) {
11946
11983
  case 'ctrlEnter':
11947
11984
  case 'shiftEnter':
11948
11985
  case 'csEnter':
11986
+ case 'shiftSpace':
11987
+ case 'ctrlSpace':
11949
11988
  _this.toggleSelect(focusedNode, e);
11950
11989
  break;
11951
11990
  case 'f2':
@@ -12339,7 +12378,7 @@ var TreeView = /** @__PURE__ @class */ (function (_super) {
12339
12378
  };
12340
12379
  TreeView.prototype.setFocus = function (preNode, nextNode) {
12341
12380
  removeClass([preNode], [HOVER, FOCUS]);
12342
- if (!nextNode.classList.contains('e-disable')) {
12381
+ if (!nextNode.classList.contains('e-disable') && !nextNode.classList.contains(PREVENTSELECT)) {
12343
12382
  addClass([nextNode], [HOVER, FOCUS]);
12344
12383
  this.updateIdAttr(preNode, nextNode);
12345
12384
  }
@@ -12376,7 +12415,7 @@ var TreeView = /** @__PURE__ @class */ (function (_super) {
12376
12415
  }
12377
12416
  };
12378
12417
  TreeView.prototype.setHover = function (li) {
12379
- if (!li.classList.contains(HOVER)) {
12418
+ if (!li.classList.contains(HOVER) && !li.classList.contains(PREVENTSELECT)) {
12380
12419
  this.removeHover();
12381
12420
  addClass([li], HOVER);
12382
12421
  }
@@ -12400,6 +12439,7 @@ var TreeView = /** @__PURE__ @class */ (function (_super) {
12400
12439
  var pNode = closest(currLi.parentNode, '.' + LISTITEM);
12401
12440
  var pid = pNode ? pNode.getAttribute('data-uid') : null;
12402
12441
  var selected = currLi.classList.contains(ACTIVE);
12442
+ var selectable = currLi.classList.contains(PREVENTSELECT) ? false : true;
12403
12443
  var expanded = (currLi.getAttribute('aria-expanded') === 'true') ? true : false;
12404
12444
  var hasChildren = currLi.getAttribute('aria-expanded') !== null ? true : (select('.' + EXPANDABLE, currLi) || select('.' + COLLAPSIBLE, currLi)) != null ? true : false;
12405
12445
  var checked = null;
@@ -12408,7 +12448,7 @@ var TreeView = /** @__PURE__ @class */ (function (_super) {
12408
12448
  checked = checkboxElement.getAttribute('aria-checked');
12409
12449
  }
12410
12450
  return {
12411
- id: id, text: text, parentID: pid, selected: selected, expanded: expanded,
12451
+ id: id, text: text, parentID: pid, selected: selected, selectable: selectable, expanded: expanded,
12412
12452
  isChecked: checked, hasChildren: hasChildren
12413
12453
  };
12414
12454
  }
@@ -13436,7 +13476,7 @@ var TreeView = /** @__PURE__ @class */ (function (_super) {
13436
13476
  dropUl = dropEle;
13437
13477
  }
13438
13478
  refNode = dropUl.childNodes[index];
13439
- if (!this.isFirstRender || (this.dataType === 1)) {
13479
+ if (!this.isFirstRender || this.dataType === 1) {
13440
13480
  if (refNode || this.sortOrder === 'None') {
13441
13481
  for (var i = 0; i < li.length; i++) {
13442
13482
  dropUl.insertBefore(li[i], refNode);
@@ -14368,8 +14408,8 @@ var TreeView = /** @__PURE__ @class */ (function (_super) {
14368
14408
  }
14369
14409
  };
14370
14410
  /**
14371
- * Instead of clicking on the TreeView node for editing, we can enable it by using
14372
- * `beginEdit` property. On passing the node ID or element through this property, the edit textBox
14411
+ * Editing can also be enabled by using the `beginEdit` property, instead of clicking on the
14412
+ * TreeView node. On passing the node ID or element through this property, the edit textBox
14373
14413
  * will be created for the particular node thus allowing us to edit it.
14374
14414
  * @param {string | Element} node - Specifies ID of TreeView node/TreeView node.
14375
14415
  */
@@ -14480,7 +14520,7 @@ var TreeView = /** @__PURE__ @class */ (function (_super) {
14480
14520
  return disabledNodes;
14481
14521
  };
14482
14522
  /**
14483
- * Get the node's data such as id, text, parentID, selected, isChecked, and expanded by passing the node element or it's ID.
14523
+ * Gets the node's data such as id, text, parentID, selected, isChecked, and expanded by passing the node element or it's ID.
14484
14524
  * @param {string | Element} node - Specifies ID of TreeView node/TreeView node.
14485
14525
  */
14486
14526
  TreeView.prototype.getNode = function (node) {
@@ -14860,7 +14900,6 @@ var CLOSE = 'e-close';
14860
14900
  var OPEN = 'e-open';
14861
14901
  var TRASITION = 'e-transition';
14862
14902
  var DEFAULTBACKDROP = 'e-sidebar-overlay';
14863
- var CONTEXTBACKDROP = 'e-backdrop';
14864
14903
  var RTL$2 = 'e-rtl';
14865
14904
  var RIGHT = 'e-right';
14866
14905
  var LEFT = 'e-left';
@@ -15032,7 +15071,7 @@ var Sidebar = /** @__PURE__ @class */ (function (_super) {
15032
15071
  Sidebar.prototype.destroyBackDrop = function () {
15033
15072
  var sibling = document.querySelector('.e-main-content') || this.targetEle;
15034
15073
  if (this.target && this.showBackdrop && sibling) {
15035
- removeClass([sibling], CONTEXTBACKDROP);
15074
+ removeClass([this.defaultBackdropDiv], DEFAULTBACKDROP);
15036
15075
  }
15037
15076
  else if (this.showBackdrop && this.modal) {
15038
15077
  this.modal.style.display = 'none';
@@ -15170,8 +15209,12 @@ var Sidebar = /** @__PURE__ @class */ (function (_super) {
15170
15209
  };
15171
15210
  Sidebar.prototype.createBackDrop = function () {
15172
15211
  if (this.target && this.showBackdrop && this.getState()) {
15212
+ var targetString = this.target;
15173
15213
  var sibling = document.querySelector('.e-main-content') || this.targetEle;
15174
- addClass([sibling], CONTEXTBACKDROP);
15214
+ this.defaultBackdropDiv = this.createElement('div');
15215
+ addClass([this.defaultBackdropDiv], DEFAULTBACKDROP);
15216
+ setStyleAttribute(this.defaultBackdropDiv, { height: targetString.style.height });
15217
+ sibling.appendChild(this.defaultBackdropDiv);
15175
15218
  }
15176
15219
  else if (this.showBackdrop && !this.modal && this.getState()) {
15177
15220
  this.modal = this.createElement('div');
@@ -15784,11 +15827,13 @@ var Breadcrumb = /** @__PURE__ @class */ (function (_super) {
15784
15827
  }
15785
15828
  if (args.curData.isEmptyUrl) {
15786
15829
  args.item.children[0].removeAttribute('href');
15787
- if ((!isLastItem || (isLastItem && _this.enableActiveItemNavigation)) && !(eventArgs.item.disabled || _this.disabled)) {
15830
+ if ((!isLastItem || (isLastItem && _this.enableActiveItemNavigation)) && !(eventArgs.item.disabled
15831
+ || _this.disabled)) {
15788
15832
  args.item.children[0].setAttribute(TABINDEX, '0');
15789
15833
  EventHandler.add(args.item.children[0], 'keydown', _this.keyDownHandler, _this);
15790
15834
  }
15791
15835
  }
15836
+ args.item.removeAttribute('role');
15792
15837
  if (isLastItem) {
15793
15838
  args.item.setAttribute('data-active-item', '');
15794
15839
  }
@@ -15798,7 +15843,8 @@ var Breadcrumb = /** @__PURE__ @class */ (function (_super) {
15798
15843
  }
15799
15844
  };
15800
15845
  for (var i = 0; i < len; i % 2 && j_1++, i++) {
15801
- isActiveItem = (this.activeItem && (this.activeItem === items[j_1].url || this.activeItem === items[j_1].text));
15846
+ isActiveItem = (this.activeItem && (this.activeItem === items[j_1].url ||
15847
+ this.activeItem === items[j_1].text));
15802
15848
  if (isCollasped && i > 1 && i < len - 2) {
15803
15849
  continue;
15804
15850
  }
@@ -15824,7 +15870,8 @@ var Breadcrumb = /** @__PURE__ @class */ (function (_super) {
15824
15870
  else {
15825
15871
  isSingleLevel = true;
15826
15872
  }
15827
- item = [extend({}, items[j_1].properties ? items[j_1].properties
15873
+ item = [extend({}, items[j_1].properties ?
15874
+ items[j_1].properties
15828
15875
  : items[j_1])];
15829
15876
  if (!item[0].url && !this.itemTemplate) {
15830
15877
  item = [extend({}, item[0], { isEmptyUrl: true, url: '#' })];
@@ -15912,7 +15959,8 @@ var Breadcrumb = /** @__PURE__ @class */ (function (_super) {
15912
15959
  for (var i = 0; i < liElems.length - 2; i++) {
15913
15960
  if (liWidth > width) {
15914
15961
  maxItems = Math.ceil((i - 1) / 2) + ((this.overflowMode === 'Menu' && i <= 2) ? 0 : 1);
15915
- if (((this.maxItems > maxItems && !(this.maxItems > -1 && maxItems == -1)) || this.maxItems == -1) && this._maxItems != maxItems) {
15962
+ if (((this.maxItems > maxItems && !(this.maxItems > -1 && maxItems === -1)) ||
15963
+ this.maxItems === -1) && this._maxItems !== maxItems) {
15916
15964
  this._maxItems = maxItems;
15917
15965
  this.initPvtProps();
15918
15966
  return this.reRenderItems();
@@ -15955,7 +16003,7 @@ var Breadcrumb = /** @__PURE__ @class */ (function (_super) {
15955
16003
  };
15956
16004
  Breadcrumb.prototype.hasField = function (items, field) {
15957
16005
  for (var i = 0, len = items.length; i < len; i++) {
15958
- if (items[i][field]) {
16006
+ if (items[i]["" + field]) {
15959
16007
  return true;
15960
16008
  }
15961
16009
  }
@@ -16857,15 +16905,15 @@ var Carousel = /** @__PURE__ @class */ (function (_super) {
16857
16905
  if (isNullOrUndefined(activeSlide) && this.showIndicators) {
16858
16906
  var activeIndicator = this.element.querySelector("." + CLS_INDICATOR_BAR + "." + CLS_ACTIVE$2);
16859
16907
  var activeIndex_1 = parseInt(activeIndicator.dataset.index, 10);
16860
- addClass([allSlides[activeIndex_1]], CLS_ACTIVE$2);
16908
+ addClass([allSlides[parseInt(activeIndex_1.toString(), 10)]], CLS_ACTIVE$2);
16861
16909
  return;
16862
16910
  }
16863
16911
  else if (isNullOrUndefined(activeSlide)) {
16864
- addClass([allSlides[currentIndex]], CLS_ACTIVE$2);
16912
+ addClass([allSlides[parseInt(currentIndex.toString(), 10)]], CLS_ACTIVE$2);
16865
16913
  return;
16866
16914
  }
16867
16915
  var activeIndex = parseInt(activeSlide.dataset.index, 10);
16868
- var currentSlide = allSlides[currentIndex];
16916
+ var currentSlide = allSlides[parseInt(currentIndex.toString(), 10)];
16869
16917
  var eventArgs = {
16870
16918
  currentIndex: activeIndex,
16871
16919
  nextIndex: currentIndex,
@@ -16884,10 +16932,10 @@ var Carousel = /** @__PURE__ @class */ (function (_super) {
16884
16932
  attributes(args.nextSlide, { 'aria-hidden': 'false' });
16885
16933
  var slideIndicators = [].slice.call(_this.element.querySelectorAll("." + CLS_INDICATOR_BAR));
16886
16934
  if (slideIndicators.length > 0) {
16887
- attributes(slideIndicators[activeIndex], { 'aria-current': 'false' });
16888
- attributes(slideIndicators[currentIndex], { 'aria-current': 'true' });
16935
+ attributes(slideIndicators[parseInt(activeIndex.toString(), 10)], { 'aria-current': 'false' });
16936
+ attributes(slideIndicators[parseInt(currentIndex.toString(), 10)], { 'aria-current': 'true' });
16889
16937
  removeClass(slideIndicators, CLS_ACTIVE$2);
16890
- addClass([slideIndicators[currentIndex]], CLS_ACTIVE$2);
16938
+ addClass([slideIndicators[parseInt(currentIndex.toString(), 10)]], CLS_ACTIVE$2);
16891
16939
  }
16892
16940
  _this.slideChangedEventArgs = {
16893
16941
  currentIndex: args.nextIndex,
@@ -16899,7 +16947,7 @@ var Carousel = /** @__PURE__ @class */ (function (_super) {
16899
16947
  };
16900
16948
  if (_this.partialVisible) {
16901
16949
  var container = _this.element.querySelector('.' + CLS_ITEMS$2);
16902
- var slideWidth = allSlides[currentIndex].clientWidth;
16950
+ var slideWidth = allSlides[parseInt(currentIndex.toString(), 10)].clientWidth;
16903
16951
  container.style.transitionProperty = 'transform';
16904
16952
  if (_this.loop) {
16905
16953
  if (_this.slideChangedEventArgs.currentIndex === 0 && _this.slideChangedEventArgs.slideDirection === 'Next') {
@@ -16973,10 +17021,10 @@ var Carousel = /** @__PURE__ @class */ (function (_super) {
16973
17021
  for (var _i = 0, keys_1 = keys; _i < keys_1.length; _i++) {
16974
17022
  var key = keys_1[_i];
16975
17023
  if (key === 'class') {
16976
- addClass([element], attribute[key]);
17024
+ addClass([element], attribute["" + key]);
16977
17025
  }
16978
17026
  else {
16979
- element.setAttribute(key, attribute[key]);
17027
+ element.setAttribute(key, attribute["" + key]);
16980
17028
  }
16981
17029
  }
16982
17030
  };
@@ -17091,7 +17139,7 @@ var Carousel = /** @__PURE__ @class */ (function (_super) {
17091
17139
  }
17092
17140
  };
17093
17141
  Carousel.prototype.swipeHandler = function (e) {
17094
- if (this.element.classList.contains(CLS_HOVER)) {
17142
+ if (this.element.classList.contains(CLS_HOVER) || isNullOrUndefined(this.slideItems) || this.slideItems.length <= 1) {
17095
17143
  return;
17096
17144
  }
17097
17145
  var direction = (e.swipeDirection === 'Right') ? 'Previous' : 'Next';
@@ -17515,7 +17563,7 @@ var AppBar = /** @__PURE__ @class */ (function (_super) {
17515
17563
  for (var _b = 0, keys_1 = keys; _b < keys_1.length; _b++) {
17516
17564
  var key = keys_1[_b];
17517
17565
  if (key === 'class') {
17518
- removeClass([this.element], oldProp.htmlAttributes[key]);
17566
+ removeClass([this.element], oldProp.htmlAttributes["" + key]);
17519
17567
  }
17520
17568
  else {
17521
17569
  this.element.removeAttribute(key);
@@ -17545,10 +17593,10 @@ var AppBar = /** @__PURE__ @class */ (function (_super) {
17545
17593
  for (var _i = 0, keys_2 = keys; _i < keys_2.length; _i++) {
17546
17594
  var key = keys_2[_i];
17547
17595
  if (key === 'class') {
17548
- addClass([element], attribute[key]);
17596
+ addClass([element], attribute["" + key]);
17549
17597
  }
17550
17598
  else {
17551
- element.setAttribute(key, attribute[key]);
17599
+ element.setAttribute(key, attribute["" + key]);
17552
17600
  }
17553
17601
  }
17554
17602
  };