@syncfusion/ej2-splitbuttons 19.2.62 → 19.3.47
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/.eslintrc.json +1 -1
- package/CHANGELOG.md +1 -1
- 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 +39 -8
- package/dist/es6/ej2-splitbuttons.es2015.js.map +1 -1
- package/dist/es6/ej2-splitbuttons.es5.js +38 -7
- 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/helpers/e2e/dropdownbuttonHelper.d.ts +42 -0
- package/helpers/e2e/dropdownbuttonHelper.js +39 -0
- package/helpers/e2e/index.d.ts +3 -0
- package/helpers/e2e/index.js +8 -0
- package/helpers/e2e/progressbuttonHelper.d.ts +37 -0
- package/helpers/e2e/progressbuttonHelper.js +36 -0
- package/helpers/e2e/splitbuttonHelper.d.ts +45 -0
- package/helpers/e2e/splitbuttonHelper.js +42 -0
- package/package.json +7 -7
- package/src/drop-down-button/drop-down-button.d.ts +2 -0
- package/src/drop-down-button/drop-down-button.js +37 -6
- package/src/split-button/split-button.d.ts +1 -1
- package/src/split-button/split-button.js +1 -1
- package/styles/bootstrap-dark.css +1 -31
- package/styles/bootstrap.css +1 -19
- package/styles/bootstrap4.css +1 -31
- package/styles/bootstrap5-dark.css +2105 -0
- package/styles/bootstrap5-dark.scss +4 -0
- package/styles/bootstrap5.css +2105 -0
- package/styles/bootstrap5.scss +4 -0
- package/styles/button-group/_bootstrap5-dark-definition.scss +1 -0
- package/styles/button-group/_bootstrap5-definition.scss +31 -0
- package/styles/button-group/_tailwind-dark-definition.scss +1 -30
- package/styles/button-group/_tailwind-definition.scss +1 -0
- package/styles/button-group/_theme.scss +35 -47
- package/styles/button-group/bootstrap-dark.css +1 -31
- package/styles/button-group/bootstrap.css +1 -19
- package/styles/button-group/bootstrap4.css +1 -31
- package/styles/button-group/bootstrap5-dark.css +842 -0
- package/styles/button-group/bootstrap5-dark.scss +4 -0
- package/styles/button-group/bootstrap5.css +842 -0
- package/styles/button-group/bootstrap5.scss +4 -0
- package/styles/button-group/fabric-dark.css +1 -31
- package/styles/button-group/fabric.css +1 -31
- package/styles/button-group/highcontrast-light.css +1 -31
- package/styles/button-group/highcontrast.css +1 -31
- package/styles/button-group/material-dark.css +5 -35
- package/styles/button-group/material.css +1 -31
- package/styles/button-group/tailwind-dark.css +1 -31
- package/styles/button-group/tailwind.css +1 -31
- package/styles/drop-down-button/_bootstrap5-dark-definition.scss +1 -0
- package/styles/drop-down-button/_bootstrap5-definition.scss +51 -0
- package/styles/drop-down-button/_layout.scss +12 -5
- package/styles/drop-down-button/_tailwind-dark-definition.scss +1 -48
- package/styles/drop-down-button/_tailwind-definition.scss +19 -17
- package/styles/drop-down-button/_theme.scss +6 -1
- package/styles/drop-down-button/bootstrap5-dark.css +248 -0
- package/styles/drop-down-button/bootstrap5-dark.scss +6 -0
- package/styles/drop-down-button/bootstrap5.css +248 -0
- package/styles/drop-down-button/bootstrap5.scss +6 -0
- package/styles/drop-down-button/icons/_bootstrap5-dark.scss +1 -0
- package/styles/drop-down-button/icons/_bootstrap5.scss +10 -0
- package/styles/drop-down-button/tailwind-dark.css +5 -0
- package/styles/drop-down-button/tailwind.css +5 -0
- package/styles/fabric-dark.css +1 -31
- package/styles/fabric.css +1 -31
- package/styles/highcontrast-light.css +1 -31
- package/styles/highcontrast.css +1 -31
- package/styles/material-dark.css +15 -45
- package/styles/material.css +2 -32
- package/styles/progress-button/_bootstrap5-dark-definition.scss +1 -0
- package/styles/progress-button/_bootstrap5-definition.scss +21 -0
- package/styles/progress-button/_tailwind-dark-definition.scss +1 -24
- package/styles/progress-button/_tailwind-definition.scss +6 -9
- package/styles/progress-button/_theme.scss +2 -2
- package/styles/progress-button/bootstrap5-dark.css +645 -0
- package/styles/progress-button/bootstrap5-dark.scss +5 -0
- package/styles/progress-button/bootstrap5.css +645 -0
- package/styles/progress-button/bootstrap5.scss +5 -0
- package/styles/progress-button/material-dark.css +9 -9
- package/styles/progress-button/tailwind-dark.css +10 -10
- package/styles/split-button/_bootstrap5-dark-definition.scss +1 -0
- package/styles/split-button/_bootstrap5-definition.scss +25 -0
- package/styles/split-button/_layout.scss +13 -9
- package/styles/split-button/_tailwind-dark-definition.scss +1 -23
- package/styles/split-button/_tailwind-definition.scss +7 -5
- package/styles/split-button/bootstrap5-dark.css +367 -0
- package/styles/split-button/bootstrap5-dark.scss +6 -0
- package/styles/split-button/bootstrap5.css +367 -0
- package/styles/split-button/bootstrap5.scss +6 -0
- package/styles/split-button/material-dark.css +1 -1
- package/styles/split-button/material.css +1 -1
- package/styles/split-button/tailwind-dark.css +2 -0
- package/styles/split-button/tailwind.css +2 -0
- package/styles/tailwind-dark.css +18 -41
- package/styles/tailwind.css +8 -31
|
@@ -425,13 +425,23 @@ var DropDownButton = /** @__PURE__ @class */ (function (_super) {
|
|
|
425
425
|
}
|
|
426
426
|
this.appendArrowSpan();
|
|
427
427
|
this.setActiveElem([this.element]);
|
|
428
|
-
if (this.target || !this.createPopupOnClick) {
|
|
428
|
+
if ((this.target && !this.isColorPicker()) || !this.createPopupOnClick) {
|
|
429
429
|
this.createPopup();
|
|
430
430
|
}
|
|
431
431
|
else {
|
|
432
432
|
this.isPopupCreated = false;
|
|
433
433
|
}
|
|
434
434
|
};
|
|
435
|
+
DropDownButton.prototype.isColorPicker = function () {
|
|
436
|
+
if (!this.element) {
|
|
437
|
+
return false;
|
|
438
|
+
}
|
|
439
|
+
var prevElem = this.element.previousSibling;
|
|
440
|
+
if (prevElem && prevElem.classList && prevElem.classList.contains('e-split-colorpicker')) {
|
|
441
|
+
return true;
|
|
442
|
+
}
|
|
443
|
+
return false;
|
|
444
|
+
};
|
|
435
445
|
DropDownButton.prototype.appendArrowSpan = function () {
|
|
436
446
|
this.element.appendChild(this.createElement('span', {
|
|
437
447
|
className: 'e-btn-icon e-icons ' + 'e-icon-' + (this.cssClass.indexOf(classNames.VERTICAL) > -1
|
|
@@ -483,6 +493,7 @@ var DropDownButton = /** @__PURE__ @class */ (function (_super) {
|
|
|
483
493
|
attrList.forEach(function (key) {
|
|
484
494
|
_this.element.removeAttribute(key);
|
|
485
495
|
});
|
|
496
|
+
this.popupUnWireEvents();
|
|
486
497
|
this.destroyPopup();
|
|
487
498
|
this.isPopupCreated = false;
|
|
488
499
|
if (!this.disabled) {
|
|
@@ -524,16 +535,33 @@ var DropDownButton = /** @__PURE__ @class */ (function (_super) {
|
|
|
524
535
|
};
|
|
525
536
|
DropDownButton.prototype.wireEvents = function () {
|
|
526
537
|
this.delegateMousedownHandler = this.mousedownHandler.bind(this);
|
|
527
|
-
|
|
538
|
+
if (!this.createPopupOnClick) {
|
|
539
|
+
EventHandler.add(document, 'mousedown touchstart', this.delegateMousedownHandler, this);
|
|
540
|
+
}
|
|
528
541
|
EventHandler.add(this.element, 'click', this.clickHandler, this);
|
|
529
542
|
EventHandler.add(this.element, 'keydown', this.keyBoardHandler, this);
|
|
530
543
|
};
|
|
531
544
|
DropDownButton.prototype.popupWireEvents = function () {
|
|
532
545
|
var popupElement = this.getPopUpElement();
|
|
533
|
-
|
|
534
|
-
|
|
546
|
+
if (this.createPopupOnClick) {
|
|
547
|
+
EventHandler.add(document, 'mousedown touchstart', this.delegateMousedownHandler, this);
|
|
548
|
+
}
|
|
549
|
+
if (popupElement) {
|
|
550
|
+
EventHandler.add(popupElement, 'click', this.clickHandler, this);
|
|
551
|
+
EventHandler.add(popupElement, 'keydown', this.keyBoardHandler, this);
|
|
552
|
+
}
|
|
535
553
|
this.rippleFn = rippleEffect(popupElement, { selector: '.' + classNames.ITEM });
|
|
536
554
|
};
|
|
555
|
+
DropDownButton.prototype.popupUnWireEvents = function () {
|
|
556
|
+
var popupElement = this.getPopUpElement();
|
|
557
|
+
if (this.createPopupOnClick) {
|
|
558
|
+
EventHandler.remove(document, 'mousedown touchstart', this.delegateMousedownHandler);
|
|
559
|
+
}
|
|
560
|
+
if (popupElement && popupElement.parentElement) {
|
|
561
|
+
EventHandler.remove(popupElement, 'click', this.clickHandler);
|
|
562
|
+
EventHandler.remove(popupElement, 'keydown', this.keyBoardHandler);
|
|
563
|
+
}
|
|
564
|
+
};
|
|
537
565
|
/**
|
|
538
566
|
* Handles the keyboard interactions.
|
|
539
567
|
*
|
|
@@ -602,7 +630,7 @@ var DropDownButton = /** @__PURE__ @class */ (function (_super) {
|
|
|
602
630
|
DropDownButton.prototype.clickHandler = function (e) {
|
|
603
631
|
var trgt = e.target;
|
|
604
632
|
if (closest(trgt, '[id="' + this.element.id + '"]')) {
|
|
605
|
-
if (!this.createPopupOnClick || this.target) {
|
|
633
|
+
if (!this.createPopupOnClick || (this.target && !this.isColorPicker())) {
|
|
606
634
|
if (this.getPopUpElement().classList.contains('e-popup-close')) {
|
|
607
635
|
this.openPopUp(e);
|
|
608
636
|
}
|
|
@@ -668,6 +696,7 @@ var DropDownButton = /** @__PURE__ @class */ (function (_super) {
|
|
|
668
696
|
}
|
|
669
697
|
this.trigger('beforeClose', beforeCloseArgs, function (observedArgs) {
|
|
670
698
|
if (!observedArgs.cancel) {
|
|
699
|
+
_this.popupUnWireEvents();
|
|
671
700
|
var ul_2 = _this.getULElement();
|
|
672
701
|
var selectedLi = ul_2.querySelector('.e-selected');
|
|
673
702
|
if (selectedLi) {
|
|
@@ -696,7 +725,9 @@ var DropDownButton = /** @__PURE__ @class */ (function (_super) {
|
|
|
696
725
|
});
|
|
697
726
|
};
|
|
698
727
|
DropDownButton.prototype.unWireEvents = function () {
|
|
699
|
-
|
|
728
|
+
if (!this.createPopupOnClick) {
|
|
729
|
+
EventHandler.remove(document, 'mousedown touchstart', this.delegateMousedownHandler);
|
|
730
|
+
}
|
|
700
731
|
EventHandler.remove(this.element, 'click', this.clickHandler);
|
|
701
732
|
EventHandler.remove(this.element, 'keydown', this.keyBoardHandler);
|
|
702
733
|
if (this.isPopupCreated) {
|
|
@@ -918,7 +949,7 @@ var SplitButton = /** @__PURE__ @class */ (function (_super) {
|
|
|
918
949
|
}
|
|
919
950
|
};
|
|
920
951
|
/**
|
|
921
|
-
* Initialize the Component rendering
|
|
952
|
+
* Initialize the Component rendering.
|
|
922
953
|
*
|
|
923
954
|
* @returns {void}
|
|
924
955
|
* @private
|