@syncfusion/ej2-splitbuttons 20.2.38 → 20.2.43
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/CHANGELOG.md +12 -0
- package/dist/ej2-splitbuttons.umd.min.js +2 -2
- package/dist/ej2-splitbuttons.umd.min.js.map +1 -1
- package/dist/es6/ej2-splitbuttons.es2015.js +21 -2
- package/dist/es6/ej2-splitbuttons.es2015.js.map +1 -1
- package/dist/es6/ej2-splitbuttons.es5.js +21 -2
- package/dist/es6/ej2-splitbuttons.es5.js.map +1 -1
- package/dist/global/ej2-splitbuttons.min.js +2 -2
- package/dist/global/ej2-splitbuttons.min.js.map +1 -1
- package/dist/global/index.d.ts +1 -1
- package/package.json +7 -7
- package/src/drop-down-button/drop-down-button-model.d.ts +7 -0
- package/src/drop-down-button/drop-down-button.d.ts +7 -0
- package/src/drop-down-button/drop-down-button.js +21 -2
- package/styles/bootstrap-dark.css +5 -5
- package/styles/bootstrap4.css +1 -1
- package/styles/highcontrast.css +2 -2
- package/styles/progress-button/_bootstrap-dark-definition.scss +5 -5
- package/styles/progress-button/_bootstrap4-definition.scss +1 -1
- package/styles/progress-button/_highcontrast-definition.scss +1 -1
- package/styles/progress-button/bootstrap-dark.css +5 -5
- package/styles/progress-button/bootstrap4.css +1 -1
- package/styles/progress-button/highcontrast.css +2 -2
|
@@ -525,6 +525,9 @@ let DropDownButton = class DropDownButton extends Component {
|
|
|
525
525
|
if (popupElement) {
|
|
526
526
|
EventHandler.add(popupElement, 'click', this.clickHandler, this);
|
|
527
527
|
EventHandler.add(popupElement, 'keydown', this.keyBoardHandler, this);
|
|
528
|
+
if (this.closeActionEvents) {
|
|
529
|
+
EventHandler.add(popupElement, this.closeActionEvents, this.focusoutHandler, this);
|
|
530
|
+
}
|
|
528
531
|
}
|
|
529
532
|
this.rippleFn = rippleEffect(popupElement, { selector: '.' + classNames.ITEM });
|
|
530
533
|
}
|
|
@@ -536,6 +539,9 @@ let DropDownButton = class DropDownButton extends Component {
|
|
|
536
539
|
if (popupElement && popupElement.parentElement) {
|
|
537
540
|
EventHandler.remove(popupElement, 'click', this.clickHandler);
|
|
538
541
|
EventHandler.remove(popupElement, 'keydown', this.keyBoardHandler);
|
|
542
|
+
if (this.closeActionEvents) {
|
|
543
|
+
EventHandler.remove(popupElement, this.closeActionEvents, this.focusoutHandler);
|
|
544
|
+
}
|
|
539
545
|
}
|
|
540
546
|
}
|
|
541
547
|
/**
|
|
@@ -603,6 +609,11 @@ let DropDownButton = class DropDownButton extends Component {
|
|
|
603
609
|
this.closePopup(e);
|
|
604
610
|
}
|
|
605
611
|
}
|
|
612
|
+
focusoutHandler(e) {
|
|
613
|
+
if (this.isPopupCreated && !this.canOpen()) {
|
|
614
|
+
this.closePopup(e);
|
|
615
|
+
}
|
|
616
|
+
}
|
|
606
617
|
clickHandler(e) {
|
|
607
618
|
const trgt = e.target;
|
|
608
619
|
if (closest(trgt, '[id="' + this.element.id + '"]')) {
|
|
@@ -671,7 +682,9 @@ let DropDownButton = class DropDownButton extends Component {
|
|
|
671
682
|
this.dropDown.show(null, this.element);
|
|
672
683
|
addClass([this.element], 'e-active');
|
|
673
684
|
this.element.setAttribute('aria-expanded', 'true');
|
|
674
|
-
ul
|
|
685
|
+
if (ul) {
|
|
686
|
+
ul.focus();
|
|
687
|
+
}
|
|
675
688
|
const openArgs = { element: ul, items: this.items };
|
|
676
689
|
this.trigger('open', openArgs);
|
|
677
690
|
}
|
|
@@ -688,7 +701,10 @@ let DropDownButton = class DropDownButton extends Component {
|
|
|
688
701
|
if (!observedArgs.cancel) {
|
|
689
702
|
this.popupUnWireEvents();
|
|
690
703
|
const ul = this.getULElement();
|
|
691
|
-
|
|
704
|
+
let selectedLi;
|
|
705
|
+
if (ul) {
|
|
706
|
+
selectedLi = ul.querySelector('.e-selected');
|
|
707
|
+
}
|
|
692
708
|
if (selectedLi) {
|
|
693
709
|
selectedLi.classList.remove('e-selected');
|
|
694
710
|
}
|
|
@@ -831,6 +847,9 @@ __decorate$1([
|
|
|
831
847
|
__decorate$1([
|
|
832
848
|
Property('')
|
|
833
849
|
], DropDownButton.prototype, "target", void 0);
|
|
850
|
+
__decorate$1([
|
|
851
|
+
Property('')
|
|
852
|
+
], DropDownButton.prototype, "closeActionEvents", void 0);
|
|
834
853
|
__decorate$1([
|
|
835
854
|
Event()
|
|
836
855
|
], DropDownButton.prototype, "beforeItemRender", void 0);
|