@syncfusion/ej2-splitbuttons 22.2.8 → 23.1.41
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 +2 -10
- package/dist/ej2-splitbuttons.min.js +3 -3
- package/dist/ej2-splitbuttons.umd.min.js +3 -3
- package/dist/ej2-splitbuttons.umd.min.js.map +1 -1
- package/dist/es6/ej2-splitbuttons.es2015.js +19 -7
- package/dist/es6/ej2-splitbuttons.es2015.js.map +1 -1
- package/dist/es6/ej2-splitbuttons.es5.js +19 -7
- package/dist/es6/ej2-splitbuttons.es5.js.map +1 -1
- package/dist/global/ej2-splitbuttons.min.js +3 -3
- package/dist/global/ej2-splitbuttons.min.js.map +1 -1
- package/dist/global/index.d.ts +2 -2
- package/package.json +8 -8
- package/src/drop-down-button/drop-down-button-model.d.ts +1 -1
- package/src/drop-down-button/drop-down-button.d.ts +1 -0
- package/src/drop-down-button/drop-down-button.js +15 -5
- package/src/progress-button/progress-button-model.d.ts +1 -1
- package/src/progress-button/progress-button.js +2 -2
- package/src/split-button/split-button.js +2 -1
- package/styles/button-group/bootstrap-dark.scss +1 -1
- package/styles/button-group/bootstrap.scss +1 -1
- package/styles/button-group/bootstrap4.scss +1 -1
- package/styles/button-group/bootstrap5-dark.scss +1 -1
- package/styles/button-group/bootstrap5.scss +1 -1
- package/styles/button-group/fabric-dark.scss +1 -1
- package/styles/button-group/fabric.scss +1 -1
- package/styles/button-group/fluent-dark.scss +1 -1
- package/styles/button-group/fluent.scss +1 -1
- package/styles/button-group/highcontrast-light.scss +1 -1
- package/styles/button-group/highcontrast.scss +1 -1
- package/styles/button-group/material-dark.css +0 -1
- package/styles/button-group/material-dark.scss +1 -1
- package/styles/button-group/material.css +0 -1
- package/styles/button-group/material.scss +1 -1
- package/styles/button-group/material3-dark.css +0 -1
- package/styles/button-group/material3-dark.scss +1 -1
- package/styles/button-group/material3.css +0 -1
- package/styles/button-group/material3.scss +1 -1
- package/styles/button-group/tailwind-dark.css +0 -1
- package/styles/button-group/tailwind-dark.scss +1 -1
- package/styles/button-group/tailwind.css +0 -1
- package/styles/button-group/tailwind.scss +1 -1
- package/styles/drop-down-button/bootstrap-dark.scss +1 -1
- package/styles/drop-down-button/bootstrap.scss +1 -1
- package/styles/drop-down-button/bootstrap4.scss +1 -1
- package/styles/drop-down-button/bootstrap5-dark.scss +1 -1
- package/styles/drop-down-button/bootstrap5.scss +1 -1
- package/styles/drop-down-button/fabric-dark.scss +1 -1
- package/styles/drop-down-button/fabric.scss +1 -1
- package/styles/drop-down-button/fluent-dark.scss +1 -1
- package/styles/drop-down-button/fluent.scss +1 -1
- package/styles/drop-down-button/highcontrast-light.scss +1 -1
- package/styles/drop-down-button/highcontrast.scss +1 -1
- package/styles/drop-down-button/material-dark.css +0 -1
- package/styles/drop-down-button/material-dark.scss +1 -1
- package/styles/drop-down-button/material.css +0 -1
- package/styles/drop-down-button/material.scss +1 -1
- package/styles/drop-down-button/material3-dark.css +0 -1
- package/styles/drop-down-button/material3-dark.scss +1 -1
- package/styles/drop-down-button/material3.css +0 -1
- package/styles/drop-down-button/material3.scss +1 -1
- package/styles/drop-down-button/tailwind-dark.css +0 -1
- package/styles/drop-down-button/tailwind-dark.scss +1 -1
- package/styles/drop-down-button/tailwind.css +0 -1
- package/styles/drop-down-button/tailwind.scss +1 -1
- package/styles/material-dark.css +0 -1
- package/styles/material.css +0 -1
- package/styles/material3-dark.css +0 -1
- package/styles/material3-dark.scss +1 -1
- package/styles/material3.css +0 -1
- package/styles/material3.scss +1 -1
- package/styles/progress-button/bootstrap-dark.scss +1 -1
- package/styles/progress-button/bootstrap.scss +1 -1
- package/styles/progress-button/bootstrap4.scss +1 -1
- package/styles/progress-button/bootstrap5-dark.scss +1 -1
- package/styles/progress-button/bootstrap5.scss +1 -1
- package/styles/progress-button/fabric-dark.scss +1 -1
- package/styles/progress-button/fabric.scss +1 -1
- package/styles/progress-button/fluent-dark.scss +1 -1
- package/styles/progress-button/fluent.scss +1 -1
- package/styles/progress-button/highcontrast-light.scss +1 -1
- package/styles/progress-button/highcontrast.scss +1 -1
- package/styles/progress-button/material-dark.css +0 -1
- package/styles/progress-button/material-dark.scss +1 -1
- package/styles/progress-button/material.css +0 -1
- package/styles/progress-button/material.scss +1 -1
- package/styles/progress-button/material3-dark.css +0 -1
- package/styles/progress-button/material3-dark.scss +1 -1
- package/styles/progress-button/material3.css +0 -1
- package/styles/progress-button/material3.scss +1 -1
- package/styles/progress-button/tailwind-dark.css +0 -1
- package/styles/progress-button/tailwind-dark.scss +1 -1
- package/styles/progress-button/tailwind.css +0 -1
- package/styles/progress-button/tailwind.scss +1 -1
- package/styles/split-button/bootstrap-dark.scss +1 -1
- package/styles/split-button/bootstrap.scss +1 -1
- package/styles/split-button/bootstrap4.scss +1 -1
- package/styles/split-button/bootstrap5-dark.scss +1 -1
- package/styles/split-button/bootstrap5.scss +1 -1
- package/styles/split-button/fabric-dark.scss +1 -1
- package/styles/split-button/fabric.scss +1 -1
- package/styles/split-button/fluent-dark.scss +1 -1
- package/styles/split-button/fluent.scss +1 -1
- package/styles/split-button/highcontrast-light.scss +1 -1
- package/styles/split-button/highcontrast.scss +1 -1
- package/styles/split-button/material-dark.css +0 -1
- package/styles/split-button/material-dark.scss +1 -1
- package/styles/split-button/material.css +0 -1
- package/styles/split-button/material.scss +1 -1
- package/styles/split-button/material3-dark.css +0 -1
- package/styles/split-button/material3-dark.scss +1 -1
- package/styles/split-button/material3.css +0 -1
- package/styles/split-button/material3.scss +1 -1
- package/styles/split-button/tailwind-dark.css +0 -1
- package/styles/split-button/tailwind-dark.scss +1 -1
- package/styles/split-button/tailwind.css +0 -1
- package/styles/split-button/tailwind.scss +1 -1
- package/styles/tailwind-dark.css +0 -4
- package/styles/tailwind.css +0 -4
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Animation, ChildProperty, Collection, Complex, Component, Event, EventHandler, KeyboardEvents, NotifyPropertyChanges, Property, SanitizeHtmlHelper, addClass, attributes, classList, closest, createElement, deleteObject, detach, extend, getComponent, getInstance, getUniqueID, getValue, isNullOrUndefined, isRippleEnabled, remove, removeClass, rippleEffect, select, setValue } from '@syncfusion/ej2-base';
|
|
1
|
+
import { Animation, ChildProperty, Collection, Complex, Component, Event, EventHandler, KeyboardEvents, NotifyPropertyChanges, Property, SanitizeHtmlHelper, addClass, animationMode, attributes, classList, closest, createElement, deleteObject, detach, extend, getComponent, getInstance, getUniqueID, getValue, isNullOrUndefined, isRippleEnabled, remove, removeClass, rippleEffect, select, setValue } from '@syncfusion/ej2-base';
|
|
2
2
|
import { Button } from '@syncfusion/ej2-buttons';
|
|
3
3
|
import { Popup, createSpinner, hideSpinner, showSpinner } from '@syncfusion/ej2-popups';
|
|
4
4
|
|
|
@@ -346,17 +346,23 @@ var DropDownButton = /** @__PURE__ @class */ (function (_super) {
|
|
|
346
346
|
content: this.target ? this.getTargetElement() : '',
|
|
347
347
|
enableRtl: this.enableRtl
|
|
348
348
|
});
|
|
349
|
+
if (!isNullOrUndefined(this.popupContent)) {
|
|
350
|
+
this.popupContent.style.display = '';
|
|
351
|
+
}
|
|
349
352
|
if (this.dropDown.element.style.position === 'fixed') {
|
|
350
353
|
this.dropDown.refreshPosition(this.element);
|
|
351
354
|
}
|
|
352
355
|
this.dropDown.hide();
|
|
353
|
-
attributes(this.element, (_a = {}, _a['aria-haspopup'] = this.items.length || this.target ? 'true' : 'false', _a['aria-expanded'] = 'false', _a['type'] = 'button', _a
|
|
356
|
+
attributes(this.element, (_a = {}, _a['aria-haspopup'] = this.items.length || this.target ? 'true' : 'false', _a['aria-expanded'] = 'false', _a['type'] = 'button', _a));
|
|
354
357
|
if (this.cssClass) {
|
|
355
358
|
addClass([div], this.cssClass.replace(/\s+/g, ' ').trim().split(' '));
|
|
356
359
|
}
|
|
357
360
|
this.isPopupCreated = true;
|
|
358
361
|
};
|
|
359
362
|
DropDownButton.prototype.getTargetElement = function () {
|
|
363
|
+
if (this.createPopupOnClick && !this.isColorPicker() && !isNullOrUndefined(this.popupContent)) {
|
|
364
|
+
return this.popupContent;
|
|
365
|
+
}
|
|
360
366
|
return typeof (this.target) === 'string' ? select(this.target) : this.target;
|
|
361
367
|
};
|
|
362
368
|
DropDownButton.prototype.createItems = function (appendItems) {
|
|
@@ -446,11 +452,16 @@ var DropDownButton = /** @__PURE__ @class */ (function (_super) {
|
|
|
446
452
|
}
|
|
447
453
|
this.appendArrowSpan();
|
|
448
454
|
this.setActiveElem([this.element]);
|
|
449
|
-
|
|
455
|
+
this.element.setAttribute('aria-label', this.element.textContent ? this.element.textContent : 'dropdownbutton');
|
|
456
|
+
if ((this.target && !this.isColorPicker() && !this.createPopupOnClick) || !this.createPopupOnClick) {
|
|
450
457
|
this.createPopup();
|
|
451
458
|
}
|
|
452
459
|
else {
|
|
453
460
|
this.isPopupCreated = false;
|
|
461
|
+
if (this.target && !this.isColorPicker() && this.createPopupOnClick) {
|
|
462
|
+
this.popupContent = this.getTargetElement();
|
|
463
|
+
this.popupContent.style.display = 'none';
|
|
464
|
+
}
|
|
454
465
|
}
|
|
455
466
|
};
|
|
456
467
|
DropDownButton.prototype.isColorPicker = function () {
|
|
@@ -691,7 +702,7 @@ var DropDownButton = /** @__PURE__ @class */ (function (_super) {
|
|
|
691
702
|
DropDownButton.prototype.clickHandler = function (e) {
|
|
692
703
|
var trgt = e.target;
|
|
693
704
|
if (closest(trgt, '[id="' + this.element.id + '"]')) {
|
|
694
|
-
if (!this.createPopupOnClick || (this.target && this.target !== '' && !this.isColorPicker())) {
|
|
705
|
+
if (!this.createPopupOnClick || (this.target && this.target !== '' && !this.isColorPicker() && !this.createPopupOnClick)) {
|
|
695
706
|
if (this.getPopUpElement().classList.contains('e-popup-close')) {
|
|
696
707
|
this.openPopUp(e);
|
|
697
708
|
}
|
|
@@ -814,7 +825,7 @@ var DropDownButton = /** @__PURE__ @class */ (function (_super) {
|
|
|
814
825
|
if (!_this.target && ul_2) {
|
|
815
826
|
detach(ul_2);
|
|
816
827
|
}
|
|
817
|
-
if (!_this.target || _this.isColorPicker()) {
|
|
828
|
+
if (!_this.target || _this.isColorPicker() || (_this.target && !_this.isColorPicker())) {
|
|
818
829
|
if (_this.createPopupOnClick) {
|
|
819
830
|
_this.destroyPopup();
|
|
820
831
|
}
|
|
@@ -1196,7 +1207,7 @@ var SplitButton = /** @__PURE__ @class */ (function (_super) {
|
|
|
1196
1207
|
SplitButton.prototype.setAria = function () {
|
|
1197
1208
|
attributes(this.element, {
|
|
1198
1209
|
'aria-expanded': 'false', 'aria-haspopup': 'true',
|
|
1199
|
-
'aria-label': this.element.textContent + ' splitbutton', 'aria-owns': this.element.id + '_dropdownbtn-popup'
|
|
1210
|
+
'aria-label': this.element.textContent ? this.element.textContent + ' splitbutton' : 'splitbutton', 'aria-owns': this.element.id + '_dropdownbtn-popup'
|
|
1200
1211
|
});
|
|
1201
1212
|
};
|
|
1202
1213
|
/**
|
|
@@ -1241,6 +1252,7 @@ var SplitButton = /** @__PURE__ @class */ (function (_super) {
|
|
|
1241
1252
|
this.unWireEvents();
|
|
1242
1253
|
}
|
|
1243
1254
|
}
|
|
1255
|
+
this.wrapper = null;
|
|
1244
1256
|
this.primaryBtnObj.destroy();
|
|
1245
1257
|
this.secondaryBtnObj.destroy();
|
|
1246
1258
|
_super.prototype.destroy.call(this);
|
|
@@ -1828,7 +1840,7 @@ var ProgressButton = /** @__PURE__ @class */ (function (_super) {
|
|
|
1828
1840
|
var ele = this.element.getElementsByClassName(CONTENTCLS)[0];
|
|
1829
1841
|
if (this.animationSettings.effect !== 'None') {
|
|
1830
1842
|
(new Animation({})).animate(ele, {
|
|
1831
|
-
duration: this.animationSettings.duration,
|
|
1843
|
+
duration: (this.animationSettings.duration === 0 && animationMode === 'Enable') ? 400 : this.animationSettings.duration,
|
|
1832
1844
|
name: 'Progress' + this.animationSettings.effect,
|
|
1833
1845
|
timingFunction: this.animationSettings.easing,
|
|
1834
1846
|
begin: function () {
|