@syncfusion/ej2-dropdowns 25.2.3 → 25.2.5
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 +44 -0
- package/dist/ej2-dropdowns.min.js +2 -2
- package/dist/ej2-dropdowns.umd.min.js +2 -2
- package/dist/ej2-dropdowns.umd.min.js.map +1 -1
- package/dist/es6/ej2-dropdowns.es2015.js +236 -138
- package/dist/es6/ej2-dropdowns.es2015.js.map +1 -1
- package/dist/es6/ej2-dropdowns.es5.js +246 -147
- package/dist/es6/ej2-dropdowns.es5.js.map +1 -1
- package/dist/global/ej2-dropdowns.min.js +2 -2
- package/dist/global/ej2-dropdowns.min.js.map +1 -1
- package/dist/global/index.d.ts +1 -1
- package/package.json +9 -9
- package/src/drop-down-base/drop-down-base.d.ts +8 -3
- package/src/drop-down-base/drop-down-base.js +40 -18
- package/src/drop-down-list/drop-down-list.d.ts +1 -0
- package/src/drop-down-list/drop-down-list.js +33 -10
- package/src/drop-down-tree/drop-down-tree.js +10 -6
- package/src/multi-select/float-label.js +1 -0
- package/src/multi-select/multi-select.d.ts +2 -0
- package/src/multi-select/multi-select.js +162 -113
- package/styles/material3-dark.css +10 -7
- package/styles/material3.css +10 -7
- package/styles/multi-select/_layout.scss +2 -2
- package/styles/multi-select/icons/_material3.scss +8 -5
- package/styles/multi-select/material3-dark.css +10 -7
- package/styles/multi-select/material3.css +10 -7
package/dist/global/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* filename: index.d.ts
|
|
3
|
-
* version : 25.2.
|
|
3
|
+
* version : 25.2.5
|
|
4
4
|
* Copyright Syncfusion Inc. 2001 - 2023. 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
|
package/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"_from": "@syncfusion/ej2-dropdowns@*",
|
|
3
|
-
"_id": "@syncfusion/ej2-dropdowns@25.
|
|
3
|
+
"_id": "@syncfusion/ej2-dropdowns@25.2.4",
|
|
4
4
|
"_inBundle": false,
|
|
5
|
-
"_integrity": "sha512
|
|
5
|
+
"_integrity": "sha512-+bOuBJ3Sj4/1+MUHLBZoq0Q4D4CtXIfWmx27xKQVV5/MXZNLrt30dZP0CqYX++WGnTSDGIE7R1oH4yisOlvGqg==",
|
|
6
6
|
"_location": "/@syncfusion/ej2-dropdowns",
|
|
7
7
|
"_phantomChildren": {},
|
|
8
8
|
"_requested": {
|
|
@@ -34,8 +34,8 @@
|
|
|
34
34
|
"/@syncfusion/ej2-spreadsheet",
|
|
35
35
|
"/@syncfusion/ej2-vue-dropdowns"
|
|
36
36
|
],
|
|
37
|
-
"_resolved": "https://nexus.syncfusioninternal.com/repository/ej2-hotfix-new/@syncfusion/ej2-dropdowns/-/ej2-dropdowns-25.
|
|
38
|
-
"_shasum": "
|
|
37
|
+
"_resolved": "https://nexus.syncfusioninternal.com/repository/ej2-hotfix-new/@syncfusion/ej2-dropdowns/-/ej2-dropdowns-25.2.4.tgz",
|
|
38
|
+
"_shasum": "85b44dd649937186171bfa6b897f07d569f21f7b",
|
|
39
39
|
"_spec": "@syncfusion/ej2-dropdowns@*",
|
|
40
40
|
"_where": "/jenkins/workspace/elease-automation_release_25.1.1/packages/included",
|
|
41
41
|
"author": {
|
|
@@ -43,13 +43,13 @@
|
|
|
43
43
|
},
|
|
44
44
|
"bundleDependencies": false,
|
|
45
45
|
"dependencies": {
|
|
46
|
-
"@syncfusion/ej2-base": "~25.2.
|
|
46
|
+
"@syncfusion/ej2-base": "~25.2.5",
|
|
47
47
|
"@syncfusion/ej2-data": "~25.2.3",
|
|
48
|
-
"@syncfusion/ej2-inputs": "~25.2.
|
|
48
|
+
"@syncfusion/ej2-inputs": "~25.2.5",
|
|
49
49
|
"@syncfusion/ej2-lists": "~25.2.3",
|
|
50
|
-
"@syncfusion/ej2-navigations": "~25.2.
|
|
50
|
+
"@syncfusion/ej2-navigations": "~25.2.4",
|
|
51
51
|
"@syncfusion/ej2-notifications": "~25.2.3",
|
|
52
|
-
"@syncfusion/ej2-popups": "~25.2.
|
|
52
|
+
"@syncfusion/ej2-popups": "~25.2.4"
|
|
53
53
|
},
|
|
54
54
|
"deprecated": false,
|
|
55
55
|
"description": "Essential JS 2 DropDown Components",
|
|
@@ -74,7 +74,7 @@
|
|
|
74
74
|
"module": "./index.js",
|
|
75
75
|
"name": "@syncfusion/ej2-dropdowns",
|
|
76
76
|
"typings": "index.d.ts",
|
|
77
|
-
"version": "25.2.
|
|
77
|
+
"version": "25.2.5",
|
|
78
78
|
"sideEffects": false,
|
|
79
79
|
"homepage": "https://www.syncfusion.com/javascript-ui-controls"
|
|
80
80
|
}
|
|
@@ -280,9 +280,11 @@ export declare class DropDownBase extends Component<HTMLElement> implements INot
|
|
|
280
280
|
protected preventPopupOpen: boolean;
|
|
281
281
|
protected setCurrentView: boolean;
|
|
282
282
|
protected customFilterQuery: Query;
|
|
283
|
+
protected virtualSelectAllState: boolean;
|
|
284
|
+
protected CurrentEvent: KeyboardEventArgs | MouseEvent;
|
|
283
285
|
protected virtualSelectAllData: {
|
|
284
286
|
[key: string]: Object;
|
|
285
|
-
}[] |
|
|
287
|
+
}[] | string[] | number[] | boolean[];
|
|
286
288
|
protected firstItem: string | number | boolean | object;
|
|
287
289
|
protected virtualListInfo: VirtualInfo;
|
|
288
290
|
protected viewPortInfo: VirtualInfo;
|
|
@@ -567,6 +569,7 @@ export declare class DropDownBase extends Component<HTMLElement> implements INot
|
|
|
567
569
|
private setListData;
|
|
568
570
|
protected handleVirtualKeyboardActions(e: KeyboardEventArgs, pageCount: number): void;
|
|
569
571
|
protected updatePopupState(): void;
|
|
572
|
+
protected virtualSelectionAll(state: boolean, li: NodeListOf<HTMLElement> | HTMLElement[], event: MouseEvent | KeyboardEventArgs): void;
|
|
570
573
|
protected updateRemoteData(): void;
|
|
571
574
|
private bindChildItems;
|
|
572
575
|
protected isObjectInArray(objectToFind: any, array: any[]): boolean;
|
|
@@ -606,7 +609,9 @@ export declare class DropDownBase extends Component<HTMLElement> implements INot
|
|
|
606
609
|
* @param {FieldSettingsModel} fields - Maps the columns of the data table and binds the data to the component.
|
|
607
610
|
* @returns {HTMLElement} Return the ul li list items.
|
|
608
611
|
*/
|
|
609
|
-
|
|
612
|
+
protected createListItems(dataSource: {
|
|
613
|
+
[key: string]: Object;
|
|
614
|
+
}[], fields: FieldSettingsModel): HTMLElement;
|
|
610
615
|
protected listOption(dataSource: {
|
|
611
616
|
[key: string]: Object;
|
|
612
617
|
}[] | string[] | number[] | boolean[], fields: FieldSettingsModel): FieldSettingsModel;
|
|
@@ -651,7 +656,7 @@ export declare class DropDownBase extends Component<HTMLElement> implements INot
|
|
|
651
656
|
* @param {string | number | boolean} value - Specifies given value.
|
|
652
657
|
* @returns {number} Returns the index of the item.
|
|
653
658
|
*/
|
|
654
|
-
protected getIndexByValueFilter(value: string | number | boolean): number;
|
|
659
|
+
protected getIndexByValueFilter(value: string | number | boolean, ulElement: HTMLElement): number | null;
|
|
655
660
|
/**
|
|
656
661
|
* To dispatch the event manually
|
|
657
662
|
*
|
|
@@ -130,6 +130,8 @@ var DropDownBase = /** @class */ (function (_super) {
|
|
|
130
130
|
_this.appendUncheckList = false;
|
|
131
131
|
_this.getInitialData = false;
|
|
132
132
|
_this.preventPopupOpen = true;
|
|
133
|
+
_this.virtualSelectAllState = false;
|
|
134
|
+
_this.CurrentEvent = null;
|
|
133
135
|
_this.virtualListInfo = {
|
|
134
136
|
currentPageNumber: null,
|
|
135
137
|
direction: null,
|
|
@@ -729,8 +731,8 @@ var DropDownBase = /** @class */ (function (_super) {
|
|
|
729
731
|
if (!isWhereExist_1) {
|
|
730
732
|
_this.remoteDataCount = e.count;
|
|
731
733
|
}
|
|
732
|
-
_this.dataCount = e.count;
|
|
733
|
-
_this.totalItemCount = e.count;
|
|
734
|
+
_this.dataCount = !_this.virtualSelectAll ? e.count : _this.dataCount;
|
|
735
|
+
_this.totalItemCount = !_this.virtualSelectAll ? e.count : _this.totalItemCount;
|
|
734
736
|
ulElement = _this.renderItems(listItems, fields);
|
|
735
737
|
_this.appendUncheckList = false;
|
|
736
738
|
_this.onActionComplete(ulElement, listItems, e);
|
|
@@ -756,6 +758,12 @@ var DropDownBase = /** @class */ (function (_super) {
|
|
|
756
758
|
if (_this.isVirtualizationEnabled) {
|
|
757
759
|
_this.getFilteringSkeletonCount();
|
|
758
760
|
}
|
|
761
|
+
if (_this.virtualSelectAll && _this.virtualSelectAllData) {
|
|
762
|
+
_this.virtualSelectionAll(_this.virtualSelectAllState, _this.liCollections, _this.CurrentEvent);
|
|
763
|
+
_this.virtualSelectAllState = false;
|
|
764
|
+
_this.CurrentEvent = null;
|
|
765
|
+
_this.virtualSelectAll = false;
|
|
766
|
+
}
|
|
759
767
|
}
|
|
760
768
|
});
|
|
761
769
|
}).catch(function (e) {
|
|
@@ -807,11 +815,11 @@ var DropDownBase = /** @class */ (function (_super) {
|
|
|
807
815
|
}
|
|
808
816
|
}
|
|
809
817
|
}
|
|
810
|
-
if (isReOrder && (!(_this.dataSource instanceof DataManager) && !_this.isCustomDataUpdated)) {
|
|
818
|
+
if (isReOrder && (!(_this.dataSource instanceof DataManager) && !_this.isCustomDataUpdated) && !_this.virtualSelectAll) {
|
|
811
819
|
// eslint-disable @typescript-eslint/no-explicit-any
|
|
812
820
|
_this.dataCount = _this.totalItemCount = _this.virtualSelectAll ? listItems.length : listItems.count;
|
|
813
821
|
}
|
|
814
|
-
listItems = _this.isVirtualizationEnabled
|
|
822
|
+
listItems = _this.isVirtualizationEnabled ? listItems.result : listItems;
|
|
815
823
|
// eslint-enable @typescript-eslint/no-explicit-any
|
|
816
824
|
var localDataArgs = { cancel: false, result: listItems };
|
|
817
825
|
_this.isPreventChange = _this.isAngular && _this.preventChange ? true : _this.isPreventChange;
|
|
@@ -850,6 +858,9 @@ var DropDownBase = /** @class */ (function (_super) {
|
|
|
850
858
|
DropDownBase.prototype.updatePopupState = function () {
|
|
851
859
|
// Used this method in component side.
|
|
852
860
|
};
|
|
861
|
+
DropDownBase.prototype.virtualSelectionAll = function (state, li, event) {
|
|
862
|
+
// Used this method in component side.
|
|
863
|
+
};
|
|
853
864
|
DropDownBase.prototype.updateRemoteData = function () {
|
|
854
865
|
this.setListData(this.dataSource, this.fields, this.query);
|
|
855
866
|
};
|
|
@@ -1147,10 +1158,14 @@ var DropDownBase = /** @class */ (function (_super) {
|
|
|
1147
1158
|
}
|
|
1148
1159
|
};
|
|
1149
1160
|
DropDownBase.prototype.updateGroupFixedHeader = function (element, target) {
|
|
1150
|
-
this.fixedHeaderElement
|
|
1151
|
-
|
|
1152
|
-
|
|
1153
|
-
|
|
1161
|
+
if (this.fixedHeaderElement) {
|
|
1162
|
+
if (!isNullOrUndefined(element.innerHTML)) {
|
|
1163
|
+
this.fixedHeaderElement.innerHTML = element.innerHTML;
|
|
1164
|
+
}
|
|
1165
|
+
this.fixedHeaderElement.style.position = 'fixed';
|
|
1166
|
+
this.fixedHeaderElement.style.top = (this.list.parentElement.offsetTop + this.list.offsetTop) - window.scrollY + 'px';
|
|
1167
|
+
this.fixedHeaderElement.style.display = 'block';
|
|
1168
|
+
}
|
|
1154
1169
|
};
|
|
1155
1170
|
DropDownBase.prototype.getValidLi = function () {
|
|
1156
1171
|
if (this.isVirtualizationEnabled) {
|
|
@@ -1341,12 +1356,15 @@ var DropDownBase = /** @class */ (function (_super) {
|
|
|
1341
1356
|
* @param {string | number | boolean} value - Specifies given value.
|
|
1342
1357
|
* @returns {number} Returns the index of the item.
|
|
1343
1358
|
*/
|
|
1344
|
-
DropDownBase.prototype.getIndexByValueFilter = function (value) {
|
|
1359
|
+
DropDownBase.prototype.getIndexByValueFilter = function (value, ulElement) {
|
|
1345
1360
|
var index;
|
|
1346
|
-
|
|
1347
|
-
|
|
1348
|
-
|
|
1349
|
-
|
|
1361
|
+
if (!ulElement) {
|
|
1362
|
+
return null;
|
|
1363
|
+
}
|
|
1364
|
+
var listItems = ulElement.querySelectorAll('li' + ':not(.e-list-group-item)');
|
|
1365
|
+
if (listItems) {
|
|
1366
|
+
for (var i = 0; i < listItems.length; i++) {
|
|
1367
|
+
if (!isNullOrUndefined(value) && listItems[i].getAttribute('data-value') === value.toString()) {
|
|
1350
1368
|
index = i;
|
|
1351
1369
|
break;
|
|
1352
1370
|
}
|
|
@@ -1508,6 +1526,7 @@ var DropDownBase = /** @class */ (function (_super) {
|
|
|
1508
1526
|
var group = this.element.querySelector('select>optgroup');
|
|
1509
1527
|
if ((this.fields.groupBy || !isNullOrUndefined(group)) && !this.isGroupChecking) {
|
|
1510
1528
|
EventHandler.add(this.list, 'scroll', this.setFloatingHeader, this);
|
|
1529
|
+
EventHandler.add(document, 'scroll', this.updateGroupFixedHeader, this);
|
|
1511
1530
|
}
|
|
1512
1531
|
if (this.getModuleName() === 'dropdownbase') {
|
|
1513
1532
|
if (this.element.getAttribute('tabindex')) {
|
|
@@ -1761,12 +1780,15 @@ var DropDownBase = /** @class */ (function (_super) {
|
|
|
1761
1780
|
* @returns {void}
|
|
1762
1781
|
*/
|
|
1763
1782
|
DropDownBase.prototype.destroy = function () {
|
|
1764
|
-
if (document
|
|
1765
|
-
EventHandler.remove(
|
|
1766
|
-
if (
|
|
1767
|
-
this.
|
|
1783
|
+
if (document) {
|
|
1784
|
+
EventHandler.remove(document, 'scroll', this.updateGroupFixedHeader);
|
|
1785
|
+
if (document.body.contains(this.list)) {
|
|
1786
|
+
EventHandler.remove(this.list, 'scroll', this.setFloatingHeader);
|
|
1787
|
+
if (!isNullOrUndefined(this.rippleFun)) {
|
|
1788
|
+
this.rippleFun();
|
|
1789
|
+
}
|
|
1790
|
+
detach(this.list);
|
|
1768
1791
|
}
|
|
1769
|
-
detach(this.list);
|
|
1770
1792
|
}
|
|
1771
1793
|
this.liCollections = null;
|
|
1772
1794
|
this.ulElement = null;
|
|
@@ -620,6 +620,7 @@ export declare class DropDownList extends DropDownBase implements IInput {
|
|
|
620
620
|
* @returns {void}
|
|
621
621
|
*/
|
|
622
622
|
focusOut(e?: MouseEvent | KeyboardEventArgs): void;
|
|
623
|
+
removeAllChildren: (element: any) => void;
|
|
623
624
|
/**
|
|
624
625
|
* Removes the component from the DOM and detaches all its related event handlers. Also it removes the attributes and classes.
|
|
625
626
|
*
|
|
@@ -93,6 +93,12 @@ var DropDownList = /** @class */ (function (_super) {
|
|
|
93
93
|
_this.IsScrollerAtEnd = function () {
|
|
94
94
|
return this.list && this.list.scrollTop + this.list.clientHeight >= this.list.scrollHeight;
|
|
95
95
|
};
|
|
96
|
+
_this.removeAllChildren = function (element) {
|
|
97
|
+
while (element.children[0]) {
|
|
98
|
+
this.removeAllChildren(element.children[0]);
|
|
99
|
+
element.removeChild(element.children[0]);
|
|
100
|
+
}
|
|
101
|
+
};
|
|
96
102
|
return _this;
|
|
97
103
|
}
|
|
98
104
|
/**
|
|
@@ -982,7 +988,7 @@ var DropDownList = /** @class */ (function (_super) {
|
|
|
982
988
|
}
|
|
983
989
|
if (this.allowFiltering && !this.enableVirtualization && this.getModuleName() !== 'autocomplete') {
|
|
984
990
|
var value_4 = this.getItemData().value;
|
|
985
|
-
var filterIndex = this.getIndexByValueFilter(value_4);
|
|
991
|
+
var filterIndex = this.getIndexByValueFilter(value_4, this.actionCompleteData.ulElement);
|
|
986
992
|
if (!isNullOrUndefined(filterIndex)) {
|
|
987
993
|
this.activeIndex = filterIndex;
|
|
988
994
|
}
|
|
@@ -1325,7 +1331,7 @@ var DropDownList = /** @class */ (function (_super) {
|
|
|
1325
1331
|
value = 'null';
|
|
1326
1332
|
}
|
|
1327
1333
|
if (this.allowFiltering && !this.enableVirtualization && this.getModuleName() !== 'autocomplete') {
|
|
1328
|
-
var filterIndex = this.getIndexByValueFilter(value);
|
|
1334
|
+
var filterIndex = this.getIndexByValueFilter(value, this.actionCompleteData.ulElement);
|
|
1329
1335
|
if (!isNullOrUndefined(filterIndex)) {
|
|
1330
1336
|
this.activeIndex = filterIndex;
|
|
1331
1337
|
}
|
|
@@ -1367,7 +1373,7 @@ var DropDownList = /** @class */ (function (_super) {
|
|
|
1367
1373
|
this.inputElement.style.display = 'block';
|
|
1368
1374
|
}
|
|
1369
1375
|
if (!isNullOrUndefined(dataItem.value) && !this.enableVirtualization && this.allowFiltering) {
|
|
1370
|
-
this.activeIndex = this.getIndexByValueFilter(dataItem.value);
|
|
1376
|
+
this.activeIndex = this.getIndexByValueFilter(dataItem.value, this.actionCompleteData.ulElement);
|
|
1371
1377
|
}
|
|
1372
1378
|
var clearIcon = dropDownListClasses.clearIcon;
|
|
1373
1379
|
var isFilterElement = this.isFiltering() && this.filterInput && (this.getModuleName() === 'combobox');
|
|
@@ -2454,7 +2460,7 @@ var DropDownList = /** @class */ (function (_super) {
|
|
|
2454
2460
|
_this.popupContentElement.setAttribute('id', 'no-record');
|
|
2455
2461
|
}
|
|
2456
2462
|
_this.inputElement.setAttribute('aria-expanded', 'true');
|
|
2457
|
-
_this.inputElement.setAttribute('aria-controls', _this.element.id);
|
|
2463
|
+
_this.inputElement.setAttribute('aria-controls', _this.element.id + '_popup');
|
|
2458
2464
|
var inputParent = _this.isFiltering() ? _this.filterInput.parentElement : _this.inputWrapper.container;
|
|
2459
2465
|
addClass([inputParent], [dropDownListClasses.inputFocus]);
|
|
2460
2466
|
var animModel = { name: 'FadeIn', duration: 100 };
|
|
@@ -2836,6 +2842,14 @@ var DropDownList = /** @class */ (function (_super) {
|
|
|
2836
2842
|
this.keyboardEvent = null;
|
|
2837
2843
|
EventHandler.remove(document, 'mousedown', this.onDocumentClick);
|
|
2838
2844
|
this.isActive = false;
|
|
2845
|
+
if (this.getModuleName() === 'dropdownlist') {
|
|
2846
|
+
Input.destroy({
|
|
2847
|
+
element: this.filterInput,
|
|
2848
|
+
floatLabelType: this.floatLabelType,
|
|
2849
|
+
properties: { placeholder: this.filterBarPlaceholder },
|
|
2850
|
+
buttons: this.clearIconElement,
|
|
2851
|
+
}, this.clearIconElement);
|
|
2852
|
+
}
|
|
2839
2853
|
this.filterInputObj = null;
|
|
2840
2854
|
this.isDropDownClick = false;
|
|
2841
2855
|
this.preventAutoFill = false;
|
|
@@ -2867,6 +2881,11 @@ var DropDownList = /** @class */ (function (_super) {
|
|
|
2867
2881
|
}
|
|
2868
2882
|
if (this.allowFiltering && this.getModuleName() === 'dropdownlist') {
|
|
2869
2883
|
this.filterInput.removeAttribute('aria-activedescendant');
|
|
2884
|
+
this.filterInput.removeAttribute('aria-disabled');
|
|
2885
|
+
this.filterInput.removeAttribute('role');
|
|
2886
|
+
this.filterInput.removeAttribute('autocomplete');
|
|
2887
|
+
this.filterInput.removeAttribute('autocapitalize');
|
|
2888
|
+
this.filterInput.removeAttribute('spellcheck');
|
|
2870
2889
|
}
|
|
2871
2890
|
this.filterInput = null;
|
|
2872
2891
|
}
|
|
@@ -2986,6 +3005,7 @@ var DropDownList = /** @class */ (function (_super) {
|
|
|
2986
3005
|
DropDownList.prototype.destroyPopup = function () {
|
|
2987
3006
|
this.isPopupOpen = false;
|
|
2988
3007
|
this.isFilterFocus = false;
|
|
3008
|
+
this.inputElement.removeAttribute('aria-controls');
|
|
2989
3009
|
if (this.popupObj) {
|
|
2990
3010
|
this.popupObj.destroy();
|
|
2991
3011
|
detach(this.popupObj.element);
|
|
@@ -3076,7 +3096,6 @@ var DropDownList = /** @class */ (function (_super) {
|
|
|
3076
3096
|
attributes(this.targetElement(), { 'aria-label': this.getModuleName() });
|
|
3077
3097
|
this.inputElement.setAttribute('aria-label', this.getModuleName());
|
|
3078
3098
|
this.inputElement.setAttribute('aria-expanded', 'false');
|
|
3079
|
-
this.inputElement.setAttribute('aria-controls', this.element.id + '_popups');
|
|
3080
3099
|
}
|
|
3081
3100
|
attributes(this.targetElement(), this.getAriaAttributes());
|
|
3082
3101
|
this.updateDataAttribute(this.htmlAttributes);
|
|
@@ -3294,8 +3313,8 @@ var DropDownList = /** @class */ (function (_super) {
|
|
|
3294
3313
|
DropDownList.prototype.onPropertyChanged = function (newProp, oldProp) {
|
|
3295
3314
|
var _this = this;
|
|
3296
3315
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
3297
|
-
if (!isNullOrUndefined(newProp.dataSource) && !this.isTouched && (isNullOrUndefined(newProp.value) && isNullOrUndefined(newProp.index)) && !isNullOrUndefined(this.preselectedIndex)) {
|
|
3298
|
-
newProp.index = this.
|
|
3316
|
+
if (!isNullOrUndefined(newProp.dataSource) && !this.isTouched && (isNullOrUndefined(newProp.value) && isNullOrUndefined(newProp.index)) && !isNullOrUndefined(this.preselectedIndex) && !isNullOrUndefined(this.index)) {
|
|
3317
|
+
newProp.index = this.index;
|
|
3299
3318
|
}
|
|
3300
3319
|
if (!isNullOrUndefined(newProp.value) || !isNullOrUndefined(newProp.index)) {
|
|
3301
3320
|
this.isTouched = true;
|
|
@@ -3816,10 +3835,12 @@ var DropDownList = /** @class */ (function (_super) {
|
|
|
3816
3835
|
this.inputWrapper.container.parentElement.insertBefore(this.element, this.inputWrapper.container);
|
|
3817
3836
|
detach(this.inputWrapper.container);
|
|
3818
3837
|
}
|
|
3819
|
-
this.hiddenElement
|
|
3838
|
+
delete this.hiddenElement;
|
|
3820
3839
|
this.filterInput = null;
|
|
3821
|
-
this.inputWrapper = null;
|
|
3822
3840
|
this.keyboardModule = null;
|
|
3841
|
+
if (!isNullOrUndefined(this.ulElement)) {
|
|
3842
|
+
this.removeAllChildren(this.ulElement);
|
|
3843
|
+
}
|
|
3823
3844
|
this.ulElement = null;
|
|
3824
3845
|
this.list = null;
|
|
3825
3846
|
this.clearIconElement = null;
|
|
@@ -3843,10 +3864,12 @@ var DropDownList = /** @class */ (function (_super) {
|
|
|
3843
3864
|
Input.destroy({
|
|
3844
3865
|
element: this.inputElement,
|
|
3845
3866
|
floatLabelType: this.floatLabelType,
|
|
3846
|
-
properties: this.properties
|
|
3867
|
+
properties: this.properties,
|
|
3868
|
+
buttons: this.inputWrapper.container.querySelectorAll('.e-input-group-icon')[0],
|
|
3847
3869
|
}, this.clearButton);
|
|
3848
3870
|
this.clearButton = null;
|
|
3849
3871
|
this.inputElement = null;
|
|
3872
|
+
this.inputWrapper = null;
|
|
3850
3873
|
_super.prototype.destroy.call(this);
|
|
3851
3874
|
};
|
|
3852
3875
|
/* eslint-disable valid-jsdoc, jsdoc/require-returns-description */
|
|
@@ -1617,10 +1617,14 @@ var DropDownTree = /** @class */ (function (_super) {
|
|
|
1617
1617
|
focusedElement.focus();
|
|
1618
1618
|
addClass([focusedElement], ['e-node-focus']);
|
|
1619
1619
|
}
|
|
1620
|
-
if (_this.
|
|
1621
|
-
var
|
|
1622
|
-
_this.
|
|
1623
|
-
_this.checkSelectAll
|
|
1620
|
+
if (_this.treeObj.checkedNodes.length > 0) {
|
|
1621
|
+
var nodes = _this.treeObj.element.querySelectorAll('li');
|
|
1622
|
+
var checkedNodes = _this.treeObj.element.querySelectorAll('li[aria-checked=true]');
|
|
1623
|
+
if ((checkedNodes.length === nodes.length || _this.checkSelectAll) && _this.checkBoxElement) {
|
|
1624
|
+
var wrap = closest(_this.checkBoxElement, '.' + CHECKBOXWRAP);
|
|
1625
|
+
_this.changeState(wrap, 'check');
|
|
1626
|
+
_this.checkSelectAll = false;
|
|
1627
|
+
}
|
|
1624
1628
|
}
|
|
1625
1629
|
if (_this.allowFiltering) {
|
|
1626
1630
|
removeClass([_this.inputWrapper], [INPUTFOCUS]);
|
|
@@ -1968,6 +1972,8 @@ var DropDownTree = /** @class */ (function (_super) {
|
|
|
1968
1972
|
if (this.showCheckBox) {
|
|
1969
1973
|
return;
|
|
1970
1974
|
}
|
|
1975
|
+
var eventArgs = this.getEventArgs(args);
|
|
1976
|
+
this.trigger('select', eventArgs);
|
|
1971
1977
|
var selectedText;
|
|
1972
1978
|
if (args.isInteracted) {
|
|
1973
1979
|
var id = getValue('id', args.nodeData).toString();
|
|
@@ -1995,8 +2001,6 @@ var DropDownTree = /** @class */ (function (_super) {
|
|
|
1995
2001
|
this.setMultiSelect();
|
|
1996
2002
|
}
|
|
1997
2003
|
}
|
|
1998
|
-
var eventArgs = this.getEventArgs(args);
|
|
1999
|
-
this.trigger('select', eventArgs);
|
|
2000
2004
|
if (this.isValueChange && !this.changeOnBlur) {
|
|
2001
2005
|
this.triggerChangeEvent(this.keyEventArgs);
|
|
2002
2006
|
this.isValueChange = false;
|
|
@@ -27,6 +27,7 @@ export function createFloatLabel(overAllWrapper, searchWrapper, element, inputEl
|
|
|
27
27
|
element.id = id;
|
|
28
28
|
if (!isNullOrUndefined(element.id) && element.id !== '') {
|
|
29
29
|
floatLabelElement.id = 'label_' + element.id.replace(/ /g, '_');
|
|
30
|
+
floatLabelElement.setAttribute('for', element.id);
|
|
30
31
|
attributes(inputElement, { 'aria-labelledby': floatLabelElement.id });
|
|
31
32
|
}
|
|
32
33
|
if (!isNullOrUndefined(inputElement.placeholder) && inputElement.placeholder !== '') {
|
|
@@ -610,6 +610,7 @@ export declare class MultiSelect extends DropDownBase implements IInput {
|
|
|
610
610
|
private resetFilteredData;
|
|
611
611
|
private preventSetCurrentData;
|
|
612
612
|
private virtualCustomData;
|
|
613
|
+
private isSelectAllLoop;
|
|
613
614
|
private enableRTL;
|
|
614
615
|
requiredModules(): ModuleDeclaration[];
|
|
615
616
|
private updateHTMLAttribute;
|
|
@@ -820,6 +821,7 @@ export declare class MultiSelect extends DropDownBase implements IInput {
|
|
|
820
821
|
private getOverflowVal;
|
|
821
822
|
private unWireEvent;
|
|
822
823
|
private selectAllItem;
|
|
824
|
+
protected virtualSelectionAll(state: boolean, li: NodeListOf<HTMLElement> | HTMLElement[], event: MouseEvent | KeyboardEventArgs): void;
|
|
823
825
|
private updateValue;
|
|
824
826
|
private updateHiddenElement;
|
|
825
827
|
private updatedataValueItems;
|