@syncfusion/ej2-dropdowns 31.1.20 → 31.1.23
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-dropdowns.min.js +3 -3
- package/dist/ej2-dropdowns.umd.min.js +3 -3
- package/dist/ej2-dropdowns.umd.min.js.map +1 -1
- package/dist/es6/ej2-dropdowns.es2015.js +79 -11
- package/dist/es6/ej2-dropdowns.es2015.js.map +1 -1
- package/dist/es6/ej2-dropdowns.es5.js +106 -37
- package/dist/es6/ej2-dropdowns.es5.js.map +1 -1
- package/dist/global/ej2-dropdowns.min.js +3 -3
- package/dist/global/ej2-dropdowns.min.js.map +1 -1
- package/dist/global/index.d.ts +2 -2
- package/package.json +4 -4
- package/src/combo-box/combo-box.js +1 -1
- package/src/drop-down-base/drop-down-base.js +10 -3
- package/src/drop-down-list/drop-down-list.js +45 -29
- package/src/drop-down-tree/drop-down-tree.js +11 -1
- package/src/multi-select/multi-select.d.ts +2 -0
- package/src/multi-select/multi-select.js +39 -3
- package/styles/bootstrap4-lite.css +1 -0
- package/styles/bootstrap4.css +5 -4
- package/styles/bootstrap5.3-lite.css +2 -0
- package/styles/bootstrap5.3.css +4 -2
- package/styles/fluent-dark.css +3 -3
- package/styles/fluent.css +3 -3
- package/styles/fluent2-lite.css +2 -0
- package/styles/fluent2.css +4 -2
- package/styles/highcontrast-light.css +0 -1
- package/styles/highcontrast-lite.css +1 -0
- package/styles/highcontrast.css +3 -3
- package/styles/material.css +2 -2
- package/styles/multi-select/_bigger.scss +4 -4
- package/styles/multi-select/_bootstrap4-definition.scss +1 -1
- package/styles/multi-select/_bootstrap5.3-definition.scss +1 -1
- package/styles/multi-select/_fluent-definition.scss +1 -1
- package/styles/multi-select/_fluent2-definition.scss +1 -1
- package/styles/multi-select/_highcontrast-definition.scss +1 -1
- package/styles/multi-select/_material-definition.scss +1 -1
- package/styles/multi-select/_tailwind-definition.scss +2 -2
- package/styles/multi-select/_tailwind3-definition.scss +1 -1
- package/styles/multi-select/bootstrap4.css +5 -4
- package/styles/multi-select/bootstrap5.3.css +4 -2
- package/styles/multi-select/fluent-dark.css +3 -3
- package/styles/multi-select/fluent.css +3 -3
- package/styles/multi-select/fluent2.css +4 -2
- package/styles/multi-select/highcontrast-light.css +0 -1
- package/styles/multi-select/highcontrast.css +3 -3
- package/styles/multi-select/icons/_bootstrap4.scss +1 -0
- package/styles/multi-select/icons/_bootstrap5.3.scss +2 -0
- package/styles/multi-select/icons/_fluent2.scss +2 -0
- package/styles/multi-select/icons/_highcontrast.scss +1 -0
- package/styles/multi-select/icons/_tailwind3.scss +2 -0
- package/styles/multi-select/material.css +2 -2
- package/styles/multi-select/tailwind-dark.css +5 -5
- package/styles/multi-select/tailwind.css +5 -5
- package/styles/multi-select/tailwind3.css +4 -2
- package/styles/tailwind-dark-lite.css +1 -1
- package/styles/tailwind-dark.css +5 -5
- package/styles/tailwind-lite.css +1 -1
- package/styles/tailwind.css +5 -5
- package/styles/tailwind3-lite.css +2 -0
- package/styles/tailwind3.css +4 -2
package/dist/global/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* filename: index.d.ts
|
|
3
|
-
* version : 31.1.
|
|
4
|
-
* Copyright Syncfusion Inc. 2001 -
|
|
3
|
+
* version : 31.1.23
|
|
4
|
+
* Copyright Syncfusion Inc. 2001 - 2025. All rights reserved.
|
|
5
5
|
* Use of this code is subject to the terms of our license.
|
|
6
6
|
* A copy of the current license can be obtained at any time by e-mailing
|
|
7
7
|
* licensing@syncfusion.com. Any infringement will be prosecuted under
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@syncfusion/ej2-dropdowns",
|
|
3
|
-
"version": "31.1.
|
|
3
|
+
"version": "31.1.23",
|
|
4
4
|
"description": "Essential JS 2 DropDown Components",
|
|
5
5
|
"author": "Syncfusion Inc.",
|
|
6
6
|
"license": "SEE LICENSE IN license",
|
|
@@ -8,9 +8,9 @@
|
|
|
8
8
|
"module": "./index.js",
|
|
9
9
|
"es2015": "./dist/es6/ej2-dropdowns.es5.js",
|
|
10
10
|
"dependencies": {
|
|
11
|
-
"@syncfusion/ej2-base": "~31.1.
|
|
12
|
-
"@syncfusion/ej2-data": "~31.1.
|
|
13
|
-
"@syncfusion/ej2-inputs": "~31.1.
|
|
11
|
+
"@syncfusion/ej2-base": "~31.1.22",
|
|
12
|
+
"@syncfusion/ej2-data": "~31.1.23",
|
|
13
|
+
"@syncfusion/ej2-inputs": "~31.1.23",
|
|
14
14
|
"@syncfusion/ej2-lists": "~31.1.17",
|
|
15
15
|
"@syncfusion/ej2-navigations": "~31.1.20",
|
|
16
16
|
"@syncfusion/ej2-notifications": "~31.1.17",
|
|
@@ -633,7 +633,7 @@ var ComboBox = /** @class */ (function (_super) {
|
|
|
633
633
|
}
|
|
634
634
|
};
|
|
635
635
|
ComboBox.prototype.getValueByText = function (text) {
|
|
636
|
-
return _super.prototype.getValueByText.call(this, text,
|
|
636
|
+
return _super.prototype.getValueByText.call(this, text, this.ignoreCase, this.ignoreAccent);
|
|
637
637
|
};
|
|
638
638
|
ComboBox.prototype.unWireEvent = function () {
|
|
639
639
|
if (this.getModuleName() === 'combobox') {
|
|
@@ -205,7 +205,14 @@ var DropDownBase = /** @class */ (function (_super) {
|
|
|
205
205
|
var item = dataSource_1[_i];
|
|
206
206
|
if (!isNullOrUndefined(item)) {
|
|
207
207
|
if (ignoreAccent) {
|
|
208
|
-
|
|
208
|
+
if (ignoreCase) {
|
|
209
|
+
if (this.checkIgnoreCase(String(item), text)) {
|
|
210
|
+
value = this.checkingAccent(String(item), text, ignoreCase);
|
|
211
|
+
}
|
|
212
|
+
}
|
|
213
|
+
else {
|
|
214
|
+
value = this.checkingAccent(String(item), text, ignoreCase);
|
|
215
|
+
}
|
|
209
216
|
}
|
|
210
217
|
else {
|
|
211
218
|
if (ignoreCase) {
|
|
@@ -677,9 +684,9 @@ var DropDownBase = /** @class */ (function (_super) {
|
|
|
677
684
|
for (var _i = 0, options_1 = options; _i < options_1.length; _i++) {
|
|
678
685
|
var option = options_1[_i];
|
|
679
686
|
var json = {};
|
|
680
|
-
json[fields.text] = option.
|
|
687
|
+
json[fields.text] = option.innerHTML;
|
|
681
688
|
json[fields.value] = !isNullOrUndefined(option.getAttribute(fields.value)) ?
|
|
682
|
-
option.getAttribute(fields.value) : option.
|
|
689
|
+
option.getAttribute(fields.value) : option.innerHTML;
|
|
683
690
|
if (!isNullOrUndefined(category)) {
|
|
684
691
|
json[fields.groupBy] = category;
|
|
685
692
|
}
|
|
@@ -191,10 +191,10 @@ var DropDownList = /** @class */ (function (_super) {
|
|
|
191
191
|
DropDownList.prototype.floatLabelChange = function () {
|
|
192
192
|
if (this.getModuleName() === 'dropdownlist' && this.floatLabelType === 'Auto') {
|
|
193
193
|
var floatElement = this.inputWrapper.container.querySelector('.e-float-text');
|
|
194
|
-
if (this.inputElement.value !== '' || this.isInteracted) {
|
|
194
|
+
if (floatElement && this.inputElement.value !== '' || this.isInteracted) {
|
|
195
195
|
classList(floatElement, ['e-label-top'], ['e-label-bottom']);
|
|
196
196
|
}
|
|
197
|
-
else {
|
|
197
|
+
else if (floatElement) {
|
|
198
198
|
classList(floatElement, ['e-label-bottom'], ['e-label-top']);
|
|
199
199
|
}
|
|
200
200
|
}
|
|
@@ -2609,29 +2609,29 @@ var DropDownList = /** @class */ (function (_super) {
|
|
|
2609
2609
|
this.trigger('beforeOpen', args, function (args) {
|
|
2610
2610
|
var initialPopupHeight;
|
|
2611
2611
|
if (!args.cancel) {
|
|
2612
|
-
var
|
|
2612
|
+
var popupEle_1 = _this.createElement('div', {
|
|
2613
2613
|
id: _this.element.id + '_popup', className: 'e-ddl e-popup ' + (_this.cssClass !== null ? _this.cssClass : '')
|
|
2614
2614
|
});
|
|
2615
|
-
|
|
2616
|
-
|
|
2617
|
-
var searchBox = _this.setSearchBox(
|
|
2615
|
+
popupEle_1.setAttribute('aria-label', _this.element.id);
|
|
2616
|
+
popupEle_1.setAttribute('role', 'dialog');
|
|
2617
|
+
var searchBox = _this.setSearchBox(popupEle_1);
|
|
2618
2618
|
_this.listContainerHeight = _this.allowFiltering && _this.getModuleName() === 'dropdownlist' && Browser.isDevice && _this.isDeviceFullScreen ?
|
|
2619
2619
|
formatUnit(Math.round(window.outerHeight).toString() + 'px') : formatUnit(_this.popupHeight);
|
|
2620
2620
|
if (_this.headerTemplate) {
|
|
2621
|
-
_this.setHeaderTemplate(
|
|
2621
|
+
_this.setHeaderTemplate(popupEle_1);
|
|
2622
2622
|
_this.isUpdateHeaderHeight = _this.header.offsetHeight !== 0;
|
|
2623
2623
|
}
|
|
2624
|
-
append([_this.list],
|
|
2624
|
+
append([_this.list], popupEle_1);
|
|
2625
2625
|
if (_this.footerTemplate) {
|
|
2626
|
-
_this.setFooterTemplate(
|
|
2626
|
+
_this.setFooterTemplate(popupEle_1);
|
|
2627
2627
|
_this.isUpdateFooterHeight = _this.footer.offsetHeight !== 0;
|
|
2628
2628
|
}
|
|
2629
|
-
document.body.appendChild(
|
|
2630
|
-
|
|
2631
|
-
initialPopupHeight =
|
|
2629
|
+
document.body.appendChild(popupEle_1);
|
|
2630
|
+
popupEle_1.style.top = '0px';
|
|
2631
|
+
initialPopupHeight = popupEle_1.clientHeight;
|
|
2632
2632
|
if (_this.enableVirtualization && (_this.itemTemplate || _this.isAngular)) {
|
|
2633
|
-
var listitems =
|
|
2634
|
-
var virtualListitems =
|
|
2633
|
+
var listitems = popupEle_1.querySelectorAll('li.e-list-item:not(.e-virtual-list)');
|
|
2634
|
+
var virtualListitems = popupEle_1.querySelectorAll('li.e-virtual-list');
|
|
2635
2635
|
var listitemsHeight = listitems && listitems.length > 0 ?
|
|
2636
2636
|
Math.ceil(listitems[0].getBoundingClientRect().height) +
|
|
2637
2637
|
parseInt(window.getComputedStyle(listitems[0]).marginBottom, 10) : 0;
|
|
@@ -2669,14 +2669,14 @@ var DropDownList = /** @class */ (function (_super) {
|
|
|
2669
2669
|
className: 'e-virtual-ddl'
|
|
2670
2670
|
});
|
|
2671
2671
|
virtualElement.style.cssText = _this.GetVirtualTrackHeight();
|
|
2672
|
-
|
|
2672
|
+
popupEle_1.querySelector('.e-dropdownbase').appendChild(virtualElement);
|
|
2673
2673
|
}
|
|
2674
2674
|
else {
|
|
2675
2675
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
2676
2676
|
_this.list.getElementsByClassName('e-virtual-ddl')[0].style = _this.GetVirtualTrackHeight();
|
|
2677
2677
|
}
|
|
2678
2678
|
}
|
|
2679
|
-
|
|
2679
|
+
popupEle_1.style.visibility = 'hidden';
|
|
2680
2680
|
if (_this.popupHeight !== 'auto') {
|
|
2681
2681
|
_this.searchBoxHeight = 0;
|
|
2682
2682
|
if (!isNullOrUndefined(searchBox.container) &&
|
|
@@ -2685,22 +2685,22 @@ var DropDownList = /** @class */ (function (_super) {
|
|
|
2685
2685
|
_this.listContainerHeight = (parseInt(_this.listContainerHeight, 10) - (_this.searchBoxHeight)).toString() + 'px';
|
|
2686
2686
|
}
|
|
2687
2687
|
if (_this.headerTemplate) {
|
|
2688
|
-
_this.header = _this.header ? _this.header :
|
|
2688
|
+
_this.header = _this.header ? _this.header : popupEle_1.querySelector('.e-ddl-header');
|
|
2689
2689
|
var height = Math.round(_this.header.getBoundingClientRect().height);
|
|
2690
2690
|
_this.listContainerHeight = (parseInt(_this.listContainerHeight, 10) -
|
|
2691
2691
|
(height + _this.searchBoxHeight)).toString() + 'px';
|
|
2692
2692
|
}
|
|
2693
2693
|
if (_this.footerTemplate) {
|
|
2694
|
-
_this.footer = _this.footer ? _this.footer :
|
|
2694
|
+
_this.footer = _this.footer ? _this.footer : popupEle_1.querySelector('.e-ddl-footer');
|
|
2695
2695
|
var height = Math.round(_this.footer.getBoundingClientRect().height);
|
|
2696
2696
|
_this.listContainerHeight = (parseInt(_this.listContainerHeight, 10) -
|
|
2697
2697
|
(height + _this.searchBoxHeight)).toString() + 'px';
|
|
2698
2698
|
}
|
|
2699
2699
|
_this.list.style.maxHeight = (parseInt(_this.listContainerHeight, 10) - 2).toString() + 'px'; // due to box-sizing property
|
|
2700
|
-
|
|
2700
|
+
popupEle_1.style.maxHeight = formatUnit(_this.popupHeight);
|
|
2701
2701
|
}
|
|
2702
2702
|
else {
|
|
2703
|
-
|
|
2703
|
+
popupEle_1.style.height = 'auto';
|
|
2704
2704
|
}
|
|
2705
2705
|
var offsetValue = 0;
|
|
2706
2706
|
var left = void 0;
|
|
@@ -2716,7 +2716,7 @@ var DropDownList = /** @class */ (function (_super) {
|
|
|
2716
2716
|
}
|
|
2717
2717
|
if (Browser.isDevice && _this.isDeviceFullScreen && (!_this.allowFiltering && (_this.getModuleName() === 'dropdownlist' ||
|
|
2718
2718
|
(_this.isDropDownClick && _this.getModuleName() === 'combobox')))) {
|
|
2719
|
-
offsetValue = _this.getOffsetValue(
|
|
2719
|
+
offsetValue = _this.getOffsetValue(popupEle_1);
|
|
2720
2720
|
var firstItem = _this.isEmptyList() ? _this.list : _this.liCollections[0];
|
|
2721
2721
|
if (!isNullOrUndefined(_this.inputElement)) {
|
|
2722
2722
|
left = -(parseInt(getComputedStyle(firstItem).textIndent, 10) -
|
|
@@ -2724,10 +2724,10 @@ var DropDownList = /** @class */ (function (_super) {
|
|
|
2724
2724
|
parseInt(getComputedStyle(_this.inputElement.parentElement).borderLeftWidth, 10));
|
|
2725
2725
|
}
|
|
2726
2726
|
}
|
|
2727
|
-
_this.createPopup(
|
|
2727
|
+
_this.createPopup(popupEle_1, offsetValue, left);
|
|
2728
2728
|
_this.popupContentElement = _this.popupObj.element.querySelector('.e-content');
|
|
2729
2729
|
_this.getFocusElement();
|
|
2730
|
-
_this.checkCollision(
|
|
2730
|
+
_this.checkCollision(popupEle_1);
|
|
2731
2731
|
if (Browser.isDevice) {
|
|
2732
2732
|
if ((parseInt(_this.popupWidth.toString(), 10) > window.outerWidth) &&
|
|
2733
2733
|
!(_this.getModuleName() === 'dropdownlist' && _this.allowFiltering)) {
|
|
@@ -2751,8 +2751,8 @@ var DropDownList = /** @class */ (function (_super) {
|
|
|
2751
2751
|
EventHandler.add(_this.clearIconElement, 'click', _this.clearText, _this);
|
|
2752
2752
|
}
|
|
2753
2753
|
}
|
|
2754
|
-
|
|
2755
|
-
addClass([
|
|
2754
|
+
popupEle_1.style.visibility = 'visible';
|
|
2755
|
+
addClass([popupEle_1], 'e-popup-close');
|
|
2756
2756
|
var scrollParentElements = _this.popupObj.getScrollableParent(_this.inputWrapper.container);
|
|
2757
2757
|
for (var _i = 0, scrollParentElements_1 = scrollParentElements; _i < scrollParentElements_1.length; _i++) {
|
|
2758
2758
|
var element = scrollParentElements_1[_i];
|
|
@@ -2832,7 +2832,7 @@ var DropDownList = /** @class */ (function (_super) {
|
|
|
2832
2832
|
}
|
|
2833
2833
|
});
|
|
2834
2834
|
if (_this.allowResize && (_this.getModuleName() !== 'dropdownlist' || !(Browser.isDevice && _this.isDeviceFullScreen && _this.allowFiltering))) {
|
|
2835
|
-
var
|
|
2835
|
+
var resizePaddingBottom_1 = 16;
|
|
2836
2836
|
// Create the resizer div
|
|
2837
2837
|
_this.resizer = _this.createElement('div', {
|
|
2838
2838
|
id: _this.element.id + '_resize-popup',
|
|
@@ -2844,9 +2844,25 @@ var DropDownList = /** @class */ (function (_super) {
|
|
|
2844
2844
|
if (_this.popupHeight.toString().toLowerCase() !== 'auto' && initialPopupHeight >= (parseInt(_this.popupHeight.toString(), 10) - 2)) {
|
|
2845
2845
|
_this.list.parentElement.style.height = '100%';
|
|
2846
2846
|
}
|
|
2847
|
-
_this.list.parentElement.style.paddingBottom = (_this.getModuleName() === 'dropdownlist' && _this.allowFiltering && _this.searchBoxHeight) ? (_this.searchBoxHeight +
|
|
2848
|
-
if (_this.
|
|
2849
|
-
|
|
2847
|
+
_this.list.parentElement.style.paddingBottom = (_this.getModuleName() === 'dropdownlist' && _this.allowFiltering && _this.searchBoxHeight) ? (_this.searchBoxHeight + resizePaddingBottom_1).toString() + 'px' : resizePaddingBottom_1.toString() + 'px';
|
|
2848
|
+
if (_this.isReact && _this.footer) {
|
|
2849
|
+
var listMaxHeight_1 = _this.list.style.maxHeight;
|
|
2850
|
+
var listParentElementMaxHeight_1 = _this.list.parentElement.style.maxHeight;
|
|
2851
|
+
var containerHeight_1 = _this.listContainerHeight;
|
|
2852
|
+
setTimeout(function () {
|
|
2853
|
+
_this.footer = _this.footer ? _this.footer : popupEle_1.querySelector('.e-ddl-footer');
|
|
2854
|
+
var height = Math.round(_this.footer.getBoundingClientRect().height);
|
|
2855
|
+
if (height > 0) {
|
|
2856
|
+
containerHeight_1 = (parseInt(containerHeight_1, 10) - height).toString() + 'px';
|
|
2857
|
+
listMaxHeight_1 = (parseInt(containerHeight_1, 10) - 2).toString() + 'px';
|
|
2858
|
+
_this.list.parentElement.style.paddingBottom = ((parseInt(listParentElementMaxHeight_1, 10) - parseInt(listMaxHeight_1, 10)) + resizePaddingBottom_1).toString() + 'px';
|
|
2859
|
+
}
|
|
2860
|
+
}, 1);
|
|
2861
|
+
}
|
|
2862
|
+
else {
|
|
2863
|
+
if (_this.header || _this.footer || _this.itemTemplate) {
|
|
2864
|
+
_this.list.parentElement.style.paddingBottom = ((parseInt(_this.list.parentElement.style.maxHeight, 10) - parseInt(_this.list.style.maxHeight, 10)) + resizePaddingBottom_1).toString() + 'px';
|
|
2865
|
+
}
|
|
2850
2866
|
}
|
|
2851
2867
|
_this.list.parentElement.appendChild(_this.resizer);
|
|
2852
2868
|
//hold the popup resize
|
|
@@ -1192,8 +1192,14 @@ var DropDownTree = /** @class */ (function (_super) {
|
|
|
1192
1192
|
return remainElement;
|
|
1193
1193
|
};
|
|
1194
1194
|
DropDownTree.prototype.getOverflowVal = function (index) {
|
|
1195
|
+
var textSelected;
|
|
1195
1196
|
var selectedData = this.getSelectedData(this.value[parseInt(index.toString(), 10)]);
|
|
1196
|
-
|
|
1197
|
+
var node = this.treeObj.getNode(this.value[index]);
|
|
1198
|
+
textSelected = getValue(this.treeSettings.loadOnDemand ? this.fields.text : 'text', selectedData);
|
|
1199
|
+
if (isNOU(textSelected) && !isNOU(node.text)) {
|
|
1200
|
+
textSelected = node.text.toString();
|
|
1201
|
+
}
|
|
1202
|
+
return textSelected;
|
|
1197
1203
|
};
|
|
1198
1204
|
DropDownTree.prototype.updateDelimMode = function () {
|
|
1199
1205
|
if (this.mode !== 'Box') {
|
|
@@ -2550,7 +2556,11 @@ var DropDownTree = /** @class */ (function (_super) {
|
|
|
2550
2556
|
var compiledString = this.initializeValueTemplate();
|
|
2551
2557
|
for (var i = 0, len = this.value.length; i < len; i++) {
|
|
2552
2558
|
selectedData = this.getSelectedData(this.value[i]);
|
|
2559
|
+
var node = this.treeObj.getNode(this.value[i]);
|
|
2553
2560
|
text = getValue(this.treeSettings.loadOnDemand ? this.fields.text : 'text', selectedData);
|
|
2561
|
+
if (isNOU(text) && !isNOU(node.text)) {
|
|
2562
|
+
text = node.text.toString();
|
|
2563
|
+
}
|
|
2554
2564
|
this.selectedText.push(text);
|
|
2555
2565
|
temp = this.selectedText[this.selectedText.length - 1];
|
|
2556
2566
|
if (this.selectedText.length > 1) {
|
|
@@ -720,6 +720,7 @@ export declare class MultiSelect extends DropDownBase implements IInput {
|
|
|
720
720
|
private dataUpdater;
|
|
721
721
|
private tempQuery;
|
|
722
722
|
private tempValues;
|
|
723
|
+
private secureRandom;
|
|
723
724
|
private checkForCustomValue;
|
|
724
725
|
protected getNgDirective(): string;
|
|
725
726
|
private wrapperClick;
|
|
@@ -788,6 +789,7 @@ export declare class MultiSelect extends DropDownBase implements IInput {
|
|
|
788
789
|
private updateChipStatus;
|
|
789
790
|
private indexOfObjectInArray;
|
|
790
791
|
private addValue;
|
|
792
|
+
private updateListItemsState;
|
|
791
793
|
private checkMaxSelection;
|
|
792
794
|
private dispatchSelect;
|
|
793
795
|
private addChip;
|
|
@@ -1112,6 +1112,11 @@ var MultiSelect = /** @class */ (function (_super) {
|
|
|
1112
1112
|
this.removeFocus();
|
|
1113
1113
|
}
|
|
1114
1114
|
};
|
|
1115
|
+
MultiSelect.prototype.secureRandom = function () {
|
|
1116
|
+
var array = new Uint32Array(1);
|
|
1117
|
+
window.crypto.getRandomValues(array);
|
|
1118
|
+
return array[0] / (0xFFFFFFFF + 1);
|
|
1119
|
+
};
|
|
1115
1120
|
MultiSelect.prototype.checkForCustomValue = function (query, fields) {
|
|
1116
1121
|
var dataChecks = !this.getValueByText(this.inputElement.value, this.ignoreCase);
|
|
1117
1122
|
var field = fields ? fields : this.fields;
|
|
@@ -1125,7 +1130,7 @@ var MultiSelect = /** @class */ (function (_super) {
|
|
|
1125
1130
|
setValue(field.text, value, dataItem_1);
|
|
1126
1131
|
if (typeof getValue((this.fields.value ? this.fields.value : 'value'), customData)
|
|
1127
1132
|
=== 'number' && this.fields.value !== this.fields.text) {
|
|
1128
|
-
setValue(field.value,
|
|
1133
|
+
setValue(field.value, this.secureRandom(), dataItem_1);
|
|
1129
1134
|
}
|
|
1130
1135
|
else {
|
|
1131
1136
|
setValue(field.value, value, dataItem_1);
|
|
@@ -1246,6 +1251,9 @@ var MultiSelect = /** @class */ (function (_super) {
|
|
|
1246
1251
|
e.preventDefault();
|
|
1247
1252
|
}
|
|
1248
1253
|
this.checkAndScrollParent();
|
|
1254
|
+
if (this.maximumSelectionLength === 0) {
|
|
1255
|
+
this.checkMaxSelection();
|
|
1256
|
+
}
|
|
1249
1257
|
};
|
|
1250
1258
|
MultiSelect.prototype.checkAndScrollParent = function () {
|
|
1251
1259
|
var scrollElement = this.overAllWrapper ? this.overAllWrapper.parentElement : null;
|
|
@@ -2855,8 +2863,21 @@ var MultiSelect = /** @class */ (function (_super) {
|
|
|
2855
2863
|
this.updateChipStatus();
|
|
2856
2864
|
this.checkMaxSelection();
|
|
2857
2865
|
};
|
|
2866
|
+
MultiSelect.prototype.updateListItemsState = function (list) {
|
|
2867
|
+
var activeItems = list.querySelectorAll('li.' + dropDownBaseClasses.li + '.e-active');
|
|
2868
|
+
removeClass(activeItems, 'e-disable');
|
|
2869
|
+
var inactiveItems = list.querySelectorAll('li.' + dropDownBaseClasses.li + ':not(.e-active)');
|
|
2870
|
+
addClass(inactiveItems, 'e-disable');
|
|
2871
|
+
};
|
|
2858
2872
|
MultiSelect.prototype.checkMaxSelection = function () {
|
|
2859
2873
|
var limit = this.value && this.value.length ? this.value.length : 0;
|
|
2874
|
+
if (this.maximumSelectionLength === 0) {
|
|
2875
|
+
this.updateListItemsState(this.list);
|
|
2876
|
+
if (this.mainList) {
|
|
2877
|
+
this.updateListItemsState(this.mainList);
|
|
2878
|
+
}
|
|
2879
|
+
return;
|
|
2880
|
+
}
|
|
2860
2881
|
if (limit === this.maximumSelectionLength) {
|
|
2861
2882
|
var activeItems = this.list.querySelectorAll('li.'
|
|
2862
2883
|
+ dropDownBaseClasses.li + '.e-active');
|
|
@@ -6042,6 +6063,7 @@ var MultiSelect = /** @class */ (function (_super) {
|
|
|
6042
6063
|
this.renderComplete();
|
|
6043
6064
|
};
|
|
6044
6065
|
MultiSelect.prototype.setResize = function () {
|
|
6066
|
+
var _this = this;
|
|
6045
6067
|
var resizePaddingBottom = 16;
|
|
6046
6068
|
if (this.list && this.list.parentElement && isNullOrUndefined(this.list.parentElement.querySelector('.e-resizer-right.e-icons'))) {
|
|
6047
6069
|
this.resizer = this.createElement('div', {
|
|
@@ -6059,8 +6081,22 @@ var MultiSelect = /** @class */ (function (_super) {
|
|
|
6059
6081
|
this.list.parentElement.style.height = '100%';
|
|
6060
6082
|
}
|
|
6061
6083
|
this.list.parentElement.style.boxSizing = 'border-box'; // Ensures padding doesn't affect element size
|
|
6062
|
-
var
|
|
6063
|
-
this.
|
|
6084
|
+
var paddingBottom_1 = this.mode === 'CheckBox' && this.searchBoxHeight ? this.searchBoxHeight + resizePaddingBottom + (this.showSelectAll ? this.storedSelectAllHeight : 0) : resizePaddingBottom;
|
|
6085
|
+
if (this.footer) {
|
|
6086
|
+
var listMaxHeight_1 = this.list.style.maxHeight;
|
|
6087
|
+
var listParentElementMaxHeight_1 = this.list.parentElement.style.maxHeight;
|
|
6088
|
+
setTimeout(function () {
|
|
6089
|
+
var height = Math.round(_this.footer.getBoundingClientRect().height);
|
|
6090
|
+
var containerHeight = (parseInt(listParentElementMaxHeight_1, 10) - height).toString() + 'px';
|
|
6091
|
+
listMaxHeight_1 = (parseInt(containerHeight, 10) - 2).toString() + 'px';
|
|
6092
|
+
if (height > 0) {
|
|
6093
|
+
_this.list.parentElement.style.paddingBottom = ((parseInt(listParentElementMaxHeight_1, 10) - parseInt(listMaxHeight_1, 10)) + paddingBottom_1).toString() + 'px';
|
|
6094
|
+
}
|
|
6095
|
+
}, 1);
|
|
6096
|
+
}
|
|
6097
|
+
else {
|
|
6098
|
+
this.list.parentElement.style.paddingBottom = paddingBottom_1 + "px";
|
|
6099
|
+
}
|
|
6064
6100
|
this.list.parentElement.appendChild(this.resizer);
|
|
6065
6101
|
this.list.parentElement.style.width = this.resizeWidth + 'px';
|
|
6066
6102
|
this.list.parentElement.style.height = this.resizeHeight + 'px';
|
package/styles/bootstrap4.css
CHANGED
|
@@ -1436,6 +1436,7 @@ ejs-dropdownlist {
|
|
|
1436
1436
|
}
|
|
1437
1437
|
|
|
1438
1438
|
.e-multi-select-wrapper .e-close-hooker::before {
|
|
1439
|
+
font-size: 16px;
|
|
1439
1440
|
content: "\e745";
|
|
1440
1441
|
cursor: pointer;
|
|
1441
1442
|
height: 10px;
|
|
@@ -2466,12 +2467,12 @@ ejs-multiselect {
|
|
|
2466
2467
|
}
|
|
2467
2468
|
|
|
2468
2469
|
.e-bigger .e-multi-select-wrapper .e-chips-close.e-close-hooker {
|
|
2469
|
-
margin-top: -
|
|
2470
|
+
margin-top: -32px;
|
|
2470
2471
|
}
|
|
2471
2472
|
|
|
2472
2473
|
.e-bigger .e-multiselect.e-control-container .e-multi-select-wrapper .e-clear-icon,
|
|
2473
2474
|
.e-bigger.e-multiselect.e-control-container .e-multi-select-wrapper .e-clear-icon {
|
|
2474
|
-
margin-top: -
|
|
2475
|
+
margin-top: -32px;
|
|
2475
2476
|
}
|
|
2476
2477
|
|
|
2477
2478
|
.e-bigger .e-multi-select-wrapper .e-chips-close.e-close-hooker,
|
|
@@ -2797,7 +2798,7 @@ ejs-multiselect {
|
|
|
2797
2798
|
|
|
2798
2799
|
.e-bigger .e-input-group.e-multiselect.e-control-wrapper .e-input-group-icon.e-ddl-icon::before,
|
|
2799
2800
|
.e-bigger.e-input-group.e-multiselect.e-control-wrapper .e-input-group-icon.e-ddl-icon::before {
|
|
2800
|
-
font-size:
|
|
2801
|
+
font-size: 16px;
|
|
2801
2802
|
}
|
|
2802
2803
|
|
|
2803
2804
|
.e-small.e-bigger .e-input-group.e-multiselect.e-control-wrapper .e-input-group-icon.e-ddl-icon::before,
|
|
@@ -2838,7 +2839,7 @@ ejs-multiselect {
|
|
|
2838
2839
|
|
|
2839
2840
|
.e-bigger .e-multiselect.e-input-group.e-control-container .e-multi-select-wrapper .e-clear-icon {
|
|
2840
2841
|
height: 36px;
|
|
2841
|
-
margin-top: -
|
|
2842
|
+
margin-top: -32px;
|
|
2842
2843
|
}
|
|
2843
2844
|
|
|
2844
2845
|
.e-listbox-tool .e-moveup::before {
|
package/styles/bootstrap5.3.css
CHANGED
|
@@ -1375,6 +1375,8 @@ ejs-dropdownlist {
|
|
|
1375
1375
|
}
|
|
1376
1376
|
|
|
1377
1377
|
.e-multi-select-wrapper .e-close-hooker::before {
|
|
1378
|
+
height: 16px;
|
|
1379
|
+
font-size: 16px;
|
|
1378
1380
|
content: "\e7e7";
|
|
1379
1381
|
cursor: pointer;
|
|
1380
1382
|
left: 6px;
|
|
@@ -2407,12 +2409,12 @@ ejs-multiselect {
|
|
|
2407
2409
|
}
|
|
2408
2410
|
|
|
2409
2411
|
.e-bigger .e-multi-select-wrapper .e-chips-close.e-close-hooker {
|
|
2410
|
-
margin-top: -
|
|
2412
|
+
margin-top: -35px;
|
|
2411
2413
|
}
|
|
2412
2414
|
|
|
2413
2415
|
.e-bigger .e-multiselect.e-control-container .e-multi-select-wrapper .e-clear-icon,
|
|
2414
2416
|
.e-bigger.e-multiselect.e-control-container .e-multi-select-wrapper .e-clear-icon {
|
|
2415
|
-
margin-top: -
|
|
2417
|
+
margin-top: -35px;
|
|
2416
2418
|
margin-top: -2.15em;
|
|
2417
2419
|
}
|
|
2418
2420
|
|
package/styles/fluent-dark.css
CHANGED
|
@@ -2501,13 +2501,13 @@ ejs-multiselect {
|
|
|
2501
2501
|
}
|
|
2502
2502
|
|
|
2503
2503
|
.e-bigger .e-multi-select-wrapper .e-chips-close.e-close-hooker {
|
|
2504
|
-
margin-top: -
|
|
2504
|
+
margin-top: -32px;
|
|
2505
2505
|
font-size: 14px;
|
|
2506
2506
|
}
|
|
2507
2507
|
|
|
2508
2508
|
.e-bigger .e-multiselect.e-control-container .e-multi-select-wrapper .e-clear-icon,
|
|
2509
2509
|
.e-bigger.e-multiselect.e-control-container .e-multi-select-wrapper .e-clear-icon {
|
|
2510
|
-
margin-top: -
|
|
2510
|
+
margin-top: -32px;
|
|
2511
2511
|
margin-top: -2.25em;
|
|
2512
2512
|
}
|
|
2513
2513
|
|
|
@@ -2806,7 +2806,7 @@ ejs-multiselect {
|
|
|
2806
2806
|
|
|
2807
2807
|
.e-bigger .e-multiselect.e-control-container .e-multi-select-wrapper.e-down-icon .e-clear-icon,
|
|
2808
2808
|
.e-bigger.e-multiselect.e-control-container .e-multi-select-wrapper.e-down-icon .e-clear-icon {
|
|
2809
|
-
margin-top: -
|
|
2809
|
+
margin-top: -24px;
|
|
2810
2810
|
}
|
|
2811
2811
|
|
|
2812
2812
|
.e-listbox-tool .e-moveup::before {
|
package/styles/fluent.css
CHANGED
|
@@ -2501,13 +2501,13 @@ ejs-multiselect {
|
|
|
2501
2501
|
}
|
|
2502
2502
|
|
|
2503
2503
|
.e-bigger .e-multi-select-wrapper .e-chips-close.e-close-hooker {
|
|
2504
|
-
margin-top: -
|
|
2504
|
+
margin-top: -32px;
|
|
2505
2505
|
font-size: 14px;
|
|
2506
2506
|
}
|
|
2507
2507
|
|
|
2508
2508
|
.e-bigger .e-multiselect.e-control-container .e-multi-select-wrapper .e-clear-icon,
|
|
2509
2509
|
.e-bigger.e-multiselect.e-control-container .e-multi-select-wrapper .e-clear-icon {
|
|
2510
|
-
margin-top: -
|
|
2510
|
+
margin-top: -32px;
|
|
2511
2511
|
margin-top: -2.25em;
|
|
2512
2512
|
}
|
|
2513
2513
|
|
|
@@ -2806,7 +2806,7 @@ ejs-multiselect {
|
|
|
2806
2806
|
|
|
2807
2807
|
.e-bigger .e-multiselect.e-control-container .e-multi-select-wrapper.e-down-icon .e-clear-icon,
|
|
2808
2808
|
.e-bigger.e-multiselect.e-control-container .e-multi-select-wrapper.e-down-icon .e-clear-icon {
|
|
2809
|
-
margin-top: -
|
|
2809
|
+
margin-top: -24px;
|
|
2810
2810
|
}
|
|
2811
2811
|
|
|
2812
2812
|
.e-listbox-tool .e-moveup::before {
|
package/styles/fluent2-lite.css
CHANGED
package/styles/fluent2.css
CHANGED
|
@@ -1565,6 +1565,8 @@ ejs-dropdownlist {
|
|
|
1565
1565
|
}
|
|
1566
1566
|
|
|
1567
1567
|
.e-multi-select-wrapper .e-close-hooker::before {
|
|
1568
|
+
height: 18px;
|
|
1569
|
+
font-size: 18px;
|
|
1568
1570
|
content: "\e7e7";
|
|
1569
1571
|
cursor: pointer;
|
|
1570
1572
|
margin: auto;
|
|
@@ -2605,12 +2607,12 @@ ejs-multiselect {
|
|
|
2605
2607
|
}
|
|
2606
2608
|
|
|
2607
2609
|
.e-bigger .e-multi-select-wrapper .e-chips-close.e-close-hooker {
|
|
2608
|
-
margin-top: -
|
|
2610
|
+
margin-top: -36px;
|
|
2609
2611
|
}
|
|
2610
2612
|
|
|
2611
2613
|
.e-bigger .e-multiselect.e-control-container .e-multi-select-wrapper .e-clear-icon,
|
|
2612
2614
|
.e-bigger.e-multiselect.e-control-container .e-multi-select-wrapper .e-clear-icon {
|
|
2613
|
-
margin-top: -
|
|
2615
|
+
margin-top: -32px;
|
|
2614
2616
|
}
|
|
2615
2617
|
|
|
2616
2618
|
.e-bigger .e-multi-select-wrapper input[type=text],
|
|
@@ -2407,7 +2407,6 @@ e-ddl.e-popup.e-multi-select-list-wrapper.e-multiselct-group.e-checkbox .e-list-
|
|
|
2407
2407
|
.e-bigger .e-multiselect.e-control-container .e-multi-select-wrapper .e-clear-icon,
|
|
2408
2408
|
.e-bigger.e-multiselect.e-control-container .e-multi-select-wrapper .e-clear-icon {
|
|
2409
2409
|
margin-top: -3.5em;
|
|
2410
|
-
margin-top: -3.2em;
|
|
2411
2410
|
}
|
|
2412
2411
|
|
|
2413
2412
|
.e-bigger .e-multi-select-wrapper input[type=text],
|
package/styles/highcontrast.css
CHANGED
|
@@ -1402,6 +1402,7 @@ ejs-dropdownlist {
|
|
|
1402
1402
|
}
|
|
1403
1403
|
|
|
1404
1404
|
.e-multi-select-wrapper .e-close-hooker::before {
|
|
1405
|
+
font-size: 12px;
|
|
1405
1406
|
content: "\e7a7";
|
|
1406
1407
|
cursor: pointer;
|
|
1407
1408
|
left: 0;
|
|
@@ -2442,13 +2443,12 @@ e-ddl.e-popup.e-multi-select-list-wrapper.e-multiselct-group.e-checkbox .e-list-
|
|
|
2442
2443
|
}
|
|
2443
2444
|
|
|
2444
2445
|
.e-bigger .e-multi-select-wrapper .e-chips-close.e-close-hooker {
|
|
2445
|
-
margin-top: -
|
|
2446
|
+
margin-top: -34px;
|
|
2446
2447
|
}
|
|
2447
2448
|
|
|
2448
2449
|
.e-bigger .e-multiselect.e-control-container .e-multi-select-wrapper .e-clear-icon,
|
|
2449
2450
|
.e-bigger.e-multiselect.e-control-container .e-multi-select-wrapper .e-clear-icon {
|
|
2450
|
-
margin-top: -
|
|
2451
|
-
margin-top: -3.2em;
|
|
2451
|
+
margin-top: -34px;
|
|
2452
2452
|
}
|
|
2453
2453
|
|
|
2454
2454
|
.e-bigger .e-multi-select-wrapper input[type=text],
|
package/styles/material.css
CHANGED
|
@@ -3287,12 +3287,12 @@ ejs-multiselect {
|
|
|
3287
3287
|
}
|
|
3288
3288
|
|
|
3289
3289
|
.e-bigger .e-multi-select-wrapper .e-chips-close.e-close-hooker {
|
|
3290
|
-
margin-top: -
|
|
3290
|
+
margin-top: -32px;
|
|
3291
3291
|
}
|
|
3292
3292
|
|
|
3293
3293
|
.e-bigger .e-multiselect.e-control-container .e-multi-select-wrapper .e-clear-icon,
|
|
3294
3294
|
.e-bigger.e-multiselect.e-control-container .e-multi-select-wrapper .e-clear-icon {
|
|
3295
|
-
margin-top: -
|
|
3295
|
+
margin-top: -32px;
|
|
3296
3296
|
}
|
|
3297
3297
|
|
|
3298
3298
|
.e-bigger .e-multi-select-wrapper input[type=text],
|
|
@@ -157,7 +157,7 @@
|
|
|
157
157
|
margin-top: $ddl-closer-margin-top-bigger;
|
|
158
158
|
}
|
|
159
159
|
@if $ddl-multiselect-skin-name == 'fluent2' {
|
|
160
|
-
margin-top: -
|
|
160
|
+
margin-top: -32px;
|
|
161
161
|
}
|
|
162
162
|
@if $ddl-multiselect-skin-name == 'FluentUI' {
|
|
163
163
|
margin-top: $ddl-bigger-clear-margin-top;
|
|
@@ -168,7 +168,7 @@
|
|
|
168
168
|
@if $ddl-multiselect-skin-name == 'bootstrap5' or $ddl-multiselect-skin-name == 'bootstrap5.3' {
|
|
169
169
|
margin-top: -2.15em;
|
|
170
170
|
}
|
|
171
|
-
@if $ddl-multiselect-skin-name == '
|
|
171
|
+
@if $ddl-multiselect-skin-name == 'fabric' {
|
|
172
172
|
margin-top: -3.2em;
|
|
173
173
|
}
|
|
174
174
|
@if $ddl-multiselect-skin-name == 'tailwind' {
|
|
@@ -1935,7 +1935,7 @@
|
|
|
1935
1935
|
@if $skin-name == 'bootstrap4' {
|
|
1936
1936
|
.e-bigger .e-input-group.e-multiselect.e-control-wrapper .e-input-group-icon.e-ddl-icon::before,
|
|
1937
1937
|
.e-bigger.e-input-group.e-multiselect.e-control-wrapper .e-input-group-icon.e-ddl-icon::before {
|
|
1938
|
-
font-size:
|
|
1938
|
+
font-size: 16px;
|
|
1939
1939
|
}
|
|
1940
1940
|
.e-small.e-bigger .e-input-group.e-multiselect.e-control-wrapper .e-input-group-icon.e-ddl-icon::before,
|
|
1941
1941
|
.e-small.e-bigger.e-input-group.e-multiselect.e-control-wrapper .e-input-group-icon.e-ddl-icon::before {
|
|
@@ -1984,7 +1984,7 @@
|
|
|
1984
1984
|
@if $skin-name == 'FluentUI' {
|
|
1985
1985
|
.e-bigger .e-multiselect.e-control-container .e-multi-select-wrapper.e-down-icon .e-clear-icon,
|
|
1986
1986
|
.e-bigger.e-multiselect.e-control-container .e-multi-select-wrapper.e-down-icon .e-clear-icon {
|
|
1987
|
-
margin-top: -
|
|
1987
|
+
margin-top: -24px;
|
|
1988
1988
|
}
|
|
1989
1989
|
}
|
|
1990
1990
|
@if $skin-name == 'highcontrast' or $skin-name == 'highcontrast-light' {
|
|
@@ -37,7 +37,7 @@ $ddl-icon-margin-top-bigger: -2.25em !default;
|
|
|
37
37
|
$ddl-small-ddl-icon-top: -1.85em !default;
|
|
38
38
|
$ddl-bigger-small-ddl-icon-top: -2.85em !default;
|
|
39
39
|
$ddl-clear-margin-top: -2.9em !default;
|
|
40
|
-
$ddl-closer-margin-top-bigger: -
|
|
40
|
+
$ddl-closer-margin-top-bigger: -32px !default;
|
|
41
41
|
$ddl-chip-close-top: 8px !default;
|
|
42
42
|
$ddl-chip-close-left: 0 !default;
|
|
43
43
|
$ddl-chip-close-margin: 10px 10px 10px 0 !default;
|