@syncfusion/ej2-navigations 33.2.7 → 33.2.10
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.
- package/dist/ej2-navigations.min.js +2 -2
- package/dist/ej2-navigations.umd.min.js +2 -2
- package/dist/ej2-navigations.umd.min.js.map +1 -1
- package/dist/es6/ej2-navigations.es2015.js +60 -3
- package/dist/es6/ej2-navigations.es2015.js.map +1 -1
- package/dist/es6/ej2-navigations.es5.js +60 -3
- package/dist/es6/ej2-navigations.es5.js.map +1 -1
- package/dist/global/ej2-navigations.min.js +2 -2
- package/dist/global/ej2-navigations.min.js.map +1 -1
- package/dist/global/index.d.ts +1 -1
- package/package.json +2 -2
- package/src/accordion/accordion.d.ts +3 -0
- package/src/accordion/accordion.js +27 -2
- package/src/common/menu-base.js +3 -0
- package/src/sidebar/sidebar.d.ts +1 -0
- package/src/sidebar/sidebar.js +9 -1
- package/src/tab/tab.d.ts +1 -0
- package/src/tab/tab.js +21 -0
- package/styles/accordion/_layout.scss +10 -4
- package/styles/accordion/_material3-dark-definition.scss +1 -1
- package/styles/accordion/_material3-definition.scss +1 -1
- package/styles/accordion/_tailwind3-definition.scss +1 -1
- package/styles/accordion/_theme.scss +0 -4
- package/styles/accordion/bds.css +8 -8
- package/styles/accordion/bootstrap-dark.css +8 -8
- package/styles/accordion/bootstrap.css +8 -8
- package/styles/accordion/bootstrap4.css +8 -8
- package/styles/accordion/bootstrap5-dark.css +8 -8
- package/styles/accordion/bootstrap5.3.css +8 -8
- package/styles/accordion/bootstrap5.css +8 -8
- package/styles/accordion/fabric-dark.css +8 -8
- package/styles/accordion/fabric.css +8 -8
- package/styles/accordion/fluent-dark.css +8 -8
- package/styles/accordion/fluent.css +8 -8
- package/styles/accordion/fluent2.css +8 -16
- package/styles/accordion/highcontrast-light.css +8 -8
- package/styles/accordion/highcontrast.css +8 -8
- package/styles/accordion/material-dark.css +8 -8
- package/styles/accordion/material.css +8 -8
- package/styles/accordion/material3-dark.css +8 -8
- package/styles/accordion/material3.css +8 -8
- package/styles/accordion/tailwind-dark.css +8 -8
- package/styles/accordion/tailwind.css +8 -8
- package/styles/accordion/tailwind3.css +8 -16
- package/styles/bds-lite.css +8 -8
- package/styles/bds.css +8 -8
- package/styles/bootstrap-dark-lite.css +8 -8
- package/styles/bootstrap-dark.css +9 -9
- package/styles/bootstrap-lite.css +8 -8
- package/styles/bootstrap.css +9 -9
- package/styles/bootstrap4-lite.css +8 -8
- package/styles/bootstrap4.css +8 -8
- package/styles/bootstrap5-dark-lite.css +8 -8
- package/styles/bootstrap5-dark.css +8 -8
- package/styles/bootstrap5-lite.css +8 -8
- package/styles/bootstrap5.3-lite.css +8 -8
- package/styles/bootstrap5.3.css +8 -8
- package/styles/bootstrap5.css +8 -8
- package/styles/fabric-dark-lite.css +8 -8
- package/styles/fabric-dark.css +9 -9
- package/styles/fabric-lite.css +8 -8
- package/styles/fabric.css +9 -9
- package/styles/fluent-dark-lite.css +8 -8
- package/styles/fluent-dark.css +8 -8
- package/styles/fluent-lite.css +8 -8
- package/styles/fluent.css +8 -8
- package/styles/fluent2-lite.css +8 -16
- package/styles/fluent2.css +8 -16
- package/styles/highcontrast-light-lite.css +8 -8
- package/styles/highcontrast-light.css +9 -9
- package/styles/highcontrast-lite.css +8 -8
- package/styles/highcontrast.css +9 -9
- package/styles/material-dark-lite.css +9 -9
- package/styles/material-dark.css +10 -10
- package/styles/material-lite.css +9 -9
- package/styles/material.css +10 -10
- package/styles/material3-dark-lite.css +8 -8
- package/styles/material3-dark.css +8 -8
- package/styles/material3-lite.css +8 -8
- package/styles/material3.css +8 -8
- package/styles/tailwind-dark-lite.css +8 -8
- package/styles/tailwind-dark.css +8 -8
- package/styles/tailwind-lite.css +8 -8
- package/styles/tailwind.css +8 -8
- package/styles/tailwind3-lite.css +8 -16
- package/styles/tailwind3.css +8 -16
- package/styles/treeview/_bootstrap-dark-definition.scss +1 -1
- package/styles/treeview/_bootstrap-definition.scss +1 -1
- package/styles/treeview/_fabric-dark-definition.scss +1 -1
- package/styles/treeview/_fabric-definition.scss +1 -1
- package/styles/treeview/_highcontrast-definition.scss +1 -1
- package/styles/treeview/_highcontrast-light-definition.scss +1 -1
- package/styles/treeview/_material-dark-definition.scss +2 -2
- package/styles/treeview/_material-definition.scss +2 -2
- package/styles/treeview/bootstrap-dark.css +1 -1
- package/styles/treeview/bootstrap.css +1 -1
- package/styles/treeview/fabric-dark.css +1 -1
- package/styles/treeview/fabric.css +1 -1
- package/styles/treeview/highcontrast-light.css +1 -1
- package/styles/treeview/highcontrast.css +1 -1
- package/styles/treeview/material-dark.css +2 -2
- package/styles/treeview/material.css +2 -2
|
@@ -1341,6 +1341,9 @@ var MenuBase = /** @__PURE__ @class */ (function (_super) {
|
|
|
1341
1341
|
}
|
|
1342
1342
|
}
|
|
1343
1343
|
this.defaultOption = this.showItemOnClick;
|
|
1344
|
+
if (isNullOrUndefined(this.animation)) {
|
|
1345
|
+
this.animation = new Animation({});
|
|
1346
|
+
}
|
|
1344
1347
|
};
|
|
1345
1348
|
MenuBase.prototype.renderItems = function () {
|
|
1346
1349
|
if (!this.items.length) {
|
|
@@ -6296,6 +6299,7 @@ var CLS_ACRDN_ROOT = 'e-acrdn-root';
|
|
|
6296
6299
|
var CLS_ROOT$2 = 'e-accordion';
|
|
6297
6300
|
var CLS_ITEM$1 = 'e-acrdn-item';
|
|
6298
6301
|
var CLS_ITEMFOCUS = 'e-item-focus';
|
|
6302
|
+
var CLS_KEYBOARDFOCUS = 'e-focused';
|
|
6299
6303
|
var CLS_ITEMHIDE = 'e-hide';
|
|
6300
6304
|
var CLS_HEADER = 'e-acrdn-header';
|
|
6301
6305
|
var CLS_HEADERICN = 'e-acrdn-header-icon';
|
|
@@ -6405,6 +6409,7 @@ var Accordion = /** @__PURE__ @class */ (function (_super) {
|
|
|
6405
6409
|
*/
|
|
6406
6410
|
function Accordion(options, element) {
|
|
6407
6411
|
var _this = _super.call(this, options, element) || this;
|
|
6412
|
+
_this.isKeyboardNavigation = false;
|
|
6408
6413
|
/**
|
|
6409
6414
|
* Contains the keyboard configuration of the Accordion.
|
|
6410
6415
|
*/
|
|
@@ -6519,6 +6524,9 @@ var Accordion = /** @__PURE__ @class */ (function (_super) {
|
|
|
6519
6524
|
};
|
|
6520
6525
|
Accordion.prototype.unWireEvents = function () {
|
|
6521
6526
|
EventHandler.remove(this.element, 'click', this.clickHandler);
|
|
6527
|
+
EventHandler.remove(this.element, 'keydown', this.keyDownHandler);
|
|
6528
|
+
EventHandler.remove(document, 'keydown', this.keyDownHandler);
|
|
6529
|
+
EventHandler.remove(this.element, 'mousedown', this.mouseDownHandler);
|
|
6522
6530
|
if (!isNullOrUndefined(this.keyModule)) {
|
|
6523
6531
|
this.keyModule.destroy();
|
|
6524
6532
|
}
|
|
@@ -6530,6 +6538,9 @@ var Accordion = /** @__PURE__ @class */ (function (_super) {
|
|
|
6530
6538
|
};
|
|
6531
6539
|
Accordion.prototype.wireEvents = function () {
|
|
6532
6540
|
EventHandler.add(this.element, 'click', this.clickHandler, this);
|
|
6541
|
+
EventHandler.add(this.element, 'keydown', this.keyDownHandler, this);
|
|
6542
|
+
EventHandler.add(document, 'keydown', this.keyDownHandler, this);
|
|
6543
|
+
EventHandler.add(this.element, 'mousedown', this.mouseDownHandler, this);
|
|
6533
6544
|
if (!this.isNested && !this.isDestroy) {
|
|
6534
6545
|
this.removeRippleEffect = rippleEffect(this.element, { selector: '.' + CLS_HEADER });
|
|
6535
6546
|
}
|
|
@@ -6574,10 +6585,27 @@ var Accordion = /** @__PURE__ @class */ (function (_super) {
|
|
|
6574
6585
|
return this.itemTemplateFn;
|
|
6575
6586
|
};
|
|
6576
6587
|
Accordion.prototype.focusIn = function (e) {
|
|
6577
|
-
e.target.parentElement
|
|
6588
|
+
var targetItem = e.target.parentElement;
|
|
6589
|
+
targetItem.classList.add(CLS_ITEMFOCUS);
|
|
6590
|
+
if (this.isKeyboardNavigation) {
|
|
6591
|
+
targetItem.classList.add(CLS_KEYBOARDFOCUS);
|
|
6592
|
+
this.isKeyboardNavigation = false;
|
|
6593
|
+
}
|
|
6578
6594
|
};
|
|
6579
6595
|
Accordion.prototype.focusOut = function (e) {
|
|
6580
|
-
e.target.parentElement
|
|
6596
|
+
var targetItem = e.target.parentElement;
|
|
6597
|
+
targetItem.classList.remove(CLS_ITEMFOCUS);
|
|
6598
|
+
targetItem.classList.remove(CLS_KEYBOARDFOCUS);
|
|
6599
|
+
};
|
|
6600
|
+
Accordion.prototype.keyDownHandler = function (e) {
|
|
6601
|
+
if (e.key === 'Tab' || e.key === 'ArrowUp' || e.key === 'ArrowDown') {
|
|
6602
|
+
this.isKeyboardNavigation = true;
|
|
6603
|
+
}
|
|
6604
|
+
};
|
|
6605
|
+
Accordion.prototype.mouseDownHandler = function (e) {
|
|
6606
|
+
this.isKeyboardNavigation = false;
|
|
6607
|
+
var targetItem = e.target.parentElement;
|
|
6608
|
+
targetItem.classList.remove(CLS_KEYBOARDFOCUS);
|
|
6581
6609
|
};
|
|
6582
6610
|
Accordion.prototype.ctrlTemplate = function () {
|
|
6583
6611
|
this.ctrlTem = this.element.cloneNode(true);
|
|
@@ -8397,6 +8425,7 @@ var Tab = /** @__PURE__ @class */ (function (_super) {
|
|
|
8397
8425
|
Tab.prototype.refreshOverflow = function () {
|
|
8398
8426
|
if (!isNullOrUndefined(this.tbObj)) {
|
|
8399
8427
|
this.tbObj.refreshOverflow();
|
|
8428
|
+
this.updatePopupIconAriaLabel();
|
|
8400
8429
|
}
|
|
8401
8430
|
};
|
|
8402
8431
|
/**
|
|
@@ -8563,6 +8592,7 @@ var Tab = /** @__PURE__ @class */ (function (_super) {
|
|
|
8563
8592
|
this.hdrEle.setAttribute('aria-labelledby', this.element.getAttribute('aria-labelledby'));
|
|
8564
8593
|
this.element.removeAttribute('aria-labelledby');
|
|
8565
8594
|
}
|
|
8595
|
+
this.updatePopupIconAriaLabel();
|
|
8566
8596
|
this.setCloseButton(this.showCloseButton);
|
|
8567
8597
|
var toolbarHeader = this.tbObj.element.querySelector('.' + CLS_TB_ITEMS);
|
|
8568
8598
|
if (!isNullOrUndefined(toolbarHeader)) {
|
|
@@ -8571,6 +8601,21 @@ var Tab = /** @__PURE__ @class */ (function (_super) {
|
|
|
8571
8601
|
}
|
|
8572
8602
|
}
|
|
8573
8603
|
};
|
|
8604
|
+
Tab.prototype.updatePopupIconAriaLabel = function () {
|
|
8605
|
+
if (isNullOrUndefined(this.hdrEle) || isNullOrUndefined(this.tbObj) || this.tbObj.overflowMode !== 'Popup') {
|
|
8606
|
+
return;
|
|
8607
|
+
}
|
|
8608
|
+
var nav = this.hdrEle.querySelector('.' + CLS_HOR_NAV);
|
|
8609
|
+
if (isNullOrUndefined(nav)) {
|
|
8610
|
+
return;
|
|
8611
|
+
}
|
|
8612
|
+
var raw = window.getComputedStyle(nav, '::before').getPropertyValue('content');
|
|
8613
|
+
var beforeText = (raw || '').trim().replace(/^['"]|['"]$/g, '').replace(/\\(["'])/g, '$1').replace(/\\\\/g, '\\');
|
|
8614
|
+
var label = (beforeText && beforeText !== 'none' && beforeText !== 'normal')
|
|
8615
|
+
? beforeText
|
|
8616
|
+
: 'overflow';
|
|
8617
|
+
nav.setAttribute('aria-label', label);
|
|
8618
|
+
};
|
|
8574
8619
|
Tab.prototype.createContentElement = function (index) {
|
|
8575
8620
|
var contentElement = this.createElement('div', {
|
|
8576
8621
|
id: CLS_CONTENT$1 + this.tabId + '_' + index, className: CLS_ITEM$2,
|
|
@@ -10018,11 +10063,13 @@ var Tab = /** @__PURE__ @class */ (function (_super) {
|
|
|
10018
10063
|
this.trigger('adding', addArgs, function (tabAddingArgs) {
|
|
10019
10064
|
if (!tabAddingArgs.cancel) {
|
|
10020
10065
|
_this.addingTabContent(items, index);
|
|
10066
|
+
_this.updatePopupIconAriaLabel();
|
|
10021
10067
|
}
|
|
10022
10068
|
});
|
|
10023
10069
|
}
|
|
10024
10070
|
else {
|
|
10025
10071
|
this.addingTabContent(items, index);
|
|
10072
|
+
this.updatePopupIconAriaLabel();
|
|
10026
10073
|
}
|
|
10027
10074
|
if (this.isReact) {
|
|
10028
10075
|
this.renderReactTemplates();
|
|
@@ -10469,6 +10516,7 @@ var Tab = /** @__PURE__ @class */ (function (_super) {
|
|
|
10469
10516
|
this.tbObj.overflowMode = newProp.overflowMode;
|
|
10470
10517
|
this.tbObj.dataBind();
|
|
10471
10518
|
this.refreshActiveTabBorder();
|
|
10519
|
+
this.updatePopupIconAriaLabel();
|
|
10472
10520
|
break;
|
|
10473
10521
|
case 'heightAdjustMode':
|
|
10474
10522
|
this.setContentHeight(false);
|
|
@@ -10637,6 +10685,7 @@ var Tab = /** @__PURE__ @class */ (function (_super) {
|
|
|
10637
10685
|
this.select(this.getEleIndex(activeEle));
|
|
10638
10686
|
}
|
|
10639
10687
|
this.refreshActiveBorder();
|
|
10688
|
+
this.updatePopupIconAriaLabel();
|
|
10640
10689
|
};
|
|
10641
10690
|
__decorate$7([
|
|
10642
10691
|
Collection([], TabItem)
|
|
@@ -16744,6 +16793,7 @@ var Sidebar = /** @__PURE__ @class */ (function (_super) {
|
|
|
16744
16793
|
var _this = _super.call(this, options, element) || this;
|
|
16745
16794
|
_this.documentClickContext = _this.documentclickHandler.bind(_this);
|
|
16746
16795
|
_this.resizeHandler = _this.resize.bind(_this);
|
|
16796
|
+
_this.preventClose = false;
|
|
16747
16797
|
return _this;
|
|
16748
16798
|
}
|
|
16749
16799
|
Sidebar.prototype.preRender = function () {
|
|
@@ -16940,6 +16990,10 @@ var Sidebar = /** @__PURE__ @class */ (function (_super) {
|
|
|
16940
16990
|
setTimeout(function () { return _this.setTimeOut(); }, 50);
|
|
16941
16991
|
}
|
|
16942
16992
|
EventHandler.add(_this.element, 'transitionend', _this.transitionEnd, _this);
|
|
16993
|
+
_this.preventClose = false;
|
|
16994
|
+
}
|
|
16995
|
+
else {
|
|
16996
|
+
_this.preventClose = true;
|
|
16943
16997
|
}
|
|
16944
16998
|
});
|
|
16945
16999
|
};
|
|
@@ -17197,9 +17251,12 @@ var Sidebar = /** @__PURE__ @class */ (function (_super) {
|
|
|
17197
17251
|
case 'type':
|
|
17198
17252
|
this.checkType(false);
|
|
17199
17253
|
removeClass([this.element], [VISIBILITY]);
|
|
17200
|
-
this.
|
|
17254
|
+
if (!this.preventClose) {
|
|
17255
|
+
this.addClass();
|
|
17256
|
+
}
|
|
17201
17257
|
addClass([this.element], this.type === 'Auto' ? (Browser.isDevice ? ['e-over'] :
|
|
17202
17258
|
['e-push']) : ['e-' + this.type.toLowerCase()]);
|
|
17259
|
+
this.setType(this.type);
|
|
17203
17260
|
break;
|
|
17204
17261
|
case 'position':
|
|
17205
17262
|
this.element.style.transform = '';
|