@syncfusion/ej2-dropdowns 25.1.35 → 25.1.39

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.
Files changed (48) hide show
  1. package/CHANGELOG.md +48 -0
  2. package/dist/ej2-dropdowns.min.js +2 -2
  3. package/dist/ej2-dropdowns.umd.min.js +2 -2
  4. package/dist/ej2-dropdowns.umd.min.js.map +1 -1
  5. package/dist/es6/ej2-dropdowns.es2015.js +270 -109
  6. package/dist/es6/ej2-dropdowns.es2015.js.map +1 -1
  7. package/dist/es6/ej2-dropdowns.es5.js +272 -111
  8. package/dist/es6/ej2-dropdowns.es5.js.map +1 -1
  9. package/dist/global/ej2-dropdowns.min.js +2 -2
  10. package/dist/global/ej2-dropdowns.min.js.map +1 -1
  11. package/dist/global/index.d.ts +1 -1
  12. package/package.json +9 -9
  13. package/src/auto-complete/auto-complete.js +45 -29
  14. package/src/combo-box/combo-box.js +1 -4
  15. package/src/common/highlight-search.js +4 -0
  16. package/src/common/interface.d.ts +1 -0
  17. package/src/common/virtual-scroll.js +5 -5
  18. package/src/drop-down-base/drop-down-base.d.ts +3 -0
  19. package/src/drop-down-base/drop-down-base.js +37 -4
  20. package/src/drop-down-list/drop-down-list.js +71 -34
  21. package/src/drop-down-tree/drop-down-tree.js +21 -9
  22. package/src/list-box/list-box-model.d.ts +13 -1
  23. package/src/list-box/list-box.d.ts +12 -0
  24. package/src/list-box/list-box.js +4 -1
  25. package/src/mention/mention.js +1 -1
  26. package/src/multi-select/checkbox-selection.d.ts +2 -0
  27. package/src/multi-select/checkbox-selection.js +8 -1
  28. package/src/multi-select/multi-select-model.d.ts +1 -1
  29. package/src/multi-select/multi-select.d.ts +1 -0
  30. package/src/multi-select/multi-select.js +75 -22
  31. package/styles/fluent-dark.css +1 -1
  32. package/styles/fluent.css +1 -1
  33. package/styles/list-box/_layout.scss +6 -2
  34. package/styles/list-box/tailwind-dark.css +0 -10
  35. package/styles/list-box/tailwind.css +0 -10
  36. package/styles/material-dark.css +9 -0
  37. package/styles/material.css +9 -0
  38. package/styles/multi-select/_fluent-definition.scss +1 -1
  39. package/styles/multi-select/_material-dark-definition.scss +11 -0
  40. package/styles/multi-select/_material-definition.scss +11 -0
  41. package/styles/multi-select/fluent-dark.css +1 -1
  42. package/styles/multi-select/fluent.css +1 -1
  43. package/styles/multi-select/material-dark.css +9 -0
  44. package/styles/multi-select/material.css +9 -0
  45. package/styles/tailwind-dark.css +0 -10
  46. package/styles/tailwind.css +0 -10
  47. package/.eslintrc.json +0 -260
  48. package/tslint.json +0 -111
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  * filename: index.d.ts
3
- * version : 25.1.35
3
+ * version : 25.1.39
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@18.66.23",
3
+ "_id": "@syncfusion/ej2-dropdowns@25.1.37",
4
4
  "_inBundle": false,
5
- "_integrity": "sha512-ATUs2n/OfHPBOZTOz019wmibQIF/WpeSgQUQ8e078Lj1tWx+q7fJmH1wh0/kTbBhsmi1bQLbpxetN60PDoHsxQ==",
5
+ "_integrity": "sha512-mhkVQdSPfHiI3IWloRnDEpl4Zpov6PyJV+2YDZlNI0wN6T0+l5/qgIA/sZrUtYkOJqVFtmRO4zY7ObZf6V0BJQ==",
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-release/@syncfusion/ej2-dropdowns/-/ej2-dropdowns-18.66.23.tgz",
38
- "_shasum": "c913d1cfaa53ad097cd8da189c693a8bfdde8d27",
37
+ "_resolved": "https://nexus.syncfusioninternal.com/repository/ej2-hotfix-new/@syncfusion/ej2-dropdowns/-/ej2-dropdowns-25.1.37.tgz",
38
+ "_shasum": "b6d5a0912a9b0892cd7d87c466b08709aa0aed14",
39
39
  "_spec": "@syncfusion/ej2-dropdowns@*",
40
40
  "_where": "/jenkins/workspace/elease-automation_release_25.1.1/packages/included",
41
41
  "author": {
@@ -45,11 +45,11 @@
45
45
  "dependencies": {
46
46
  "@syncfusion/ej2-base": "~25.1.35",
47
47
  "@syncfusion/ej2-data": "~25.1.35",
48
- "@syncfusion/ej2-inputs": "~25.1.35",
49
- "@syncfusion/ej2-lists": "~25.1.35",
50
- "@syncfusion/ej2-navigations": "~25.1.35",
48
+ "@syncfusion/ej2-inputs": "~25.1.38",
49
+ "@syncfusion/ej2-lists": "~25.1.39",
50
+ "@syncfusion/ej2-navigations": "~25.1.39",
51
51
  "@syncfusion/ej2-notifications": "~25.1.35",
52
- "@syncfusion/ej2-popups": "~25.1.35"
52
+ "@syncfusion/ej2-popups": "~25.1.39"
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.1.35",
77
+ "version": "25.1.39",
78
78
  "sideEffects": false,
79
79
  "homepage": "https://www.syncfusion.com/javascript-ui-controls"
80
80
  }
@@ -78,7 +78,12 @@ var AutoComplete = /** @class */ (function (_super) {
78
78
  var filterType = (this.queryString === '' && !isNullOrUndefined(value)) ? 'equal' : this.filterType;
79
79
  var queryString = (this.queryString === '' && !isNullOrUndefined(value)) ? value : this.queryString;
80
80
  if (this.isFiltered) {
81
- return filterQuery;
81
+ if ((this.enableVirtualization && !isNullOrUndefined(this.customFilterQuery))) {
82
+ filterQuery = this.customFilterQuery.clone();
83
+ }
84
+ else if (!this.enableVirtualization) {
85
+ return filterQuery;
86
+ }
82
87
  }
83
88
  if (this.queryString !== null && this.queryString !== '') {
84
89
  var dataType = this.typeOfData(this.dataSource).typeof;
@@ -104,48 +109,61 @@ var AutoComplete = /** @class */ (function (_super) {
104
109
  if (this.enableVirtualization && (!(this.dataSource instanceof DataManager) || (this.dataSource instanceof DataManager && this.virtualGroupDataSource))) {
105
110
  var queryTakeValue = 0;
106
111
  var querySkipValue = 0;
107
- if (this.query && this.query.queries.length > 0) {
108
- for (var queryElements = 0; queryElements < this.query.queries.length; queryElements++) {
109
- if (this.query.queries[queryElements].fn === 'onSkip') {
110
- querySkipValue = this.query.queries[queryElements].e.nos;
112
+ var takeValue = this.getTakeValue();
113
+ if (filterQuery && filterQuery.queries.length > 0) {
114
+ for (var queryElements = 0; queryElements < filterQuery.queries.length; queryElements++) {
115
+ if (filterQuery.queries[queryElements].fn === 'onSkip') {
116
+ querySkipValue = filterQuery.queries[queryElements].e.nos;
111
117
  }
118
+ if (filterQuery.queries[queryElements].fn === 'onTake') {
119
+ queryTakeValue = takeValue <= filterQuery.queries[queryElements].e.nos ? filterQuery.queries[queryElements].e.nos : takeValue;
120
+ }
121
+ }
122
+ }
123
+ if (queryTakeValue <= 0 && this.query && this.query.queries.length > 0) {
124
+ for (var queryElements = 0; queryElements < this.query.queries.length; queryElements++) {
112
125
  if (this.query.queries[queryElements].fn === 'onTake') {
113
126
  queryTakeValue = takeValue <= this.query.queries[queryElements].e.nos ? this.query.queries[queryElements].e.nos : takeValue;
114
127
  }
115
128
  }
116
129
  }
117
- var skipExists = false;
118
- var takeExists = false;
119
130
  if (filterQuery && filterQuery.queries.length > 0) {
120
131
  for (var queryElements = 0; queryElements < filterQuery.queries.length; queryElements++) {
121
132
  if (filterQuery.queries[queryElements].fn === 'onSkip') {
122
- skipExists = true;
133
+ querySkipValue = filterQuery.queries[queryElements].e.nos;
134
+ filterQuery.queries.splice(queryElements, 1);
135
+ --queryElements;
136
+ continue;
123
137
  }
124
138
  if (filterQuery.queries[queryElements].fn === 'onTake') {
125
- takeExists = true;
126
- filterQuery.queries[queryElements].e.nos = filterQuery.queries[queryElements].e.nos <= queryTakeValue ? queryTakeValue : filterQuery.queries[queryElements].e.nos;
139
+ queryTakeValue = filterQuery.queries[queryElements].e.nos <= queryTakeValue ? queryTakeValue : filterQuery.queries[queryElements].e.nos;
140
+ filterQuery.queries.splice(queryElements, 1);
141
+ --queryElements;
127
142
  }
128
143
  }
129
144
  }
130
- var takeValue = this.getTakeValue();
131
- if (!skipExists) {
132
- if (querySkipValue > 0 && this.virtualItemStartIndex <= querySkipValue) {
133
- filterQuery.skip(querySkipValue);
134
- }
135
- else {
136
- filterQuery.skip(this.virtualItemStartIndex);
137
- }
145
+ if (querySkipValue > 0 && this.virtualItemStartIndex <= querySkipValue) {
146
+ filterQuery.skip(querySkipValue);
138
147
  }
139
- if (!takeExists) {
140
- if (queryTakeValue > 0 && takeValue <= queryTakeValue) {
141
- filterQuery.take(queryTakeValue);
142
- }
143
- else {
144
- filterQuery.take(takeValue);
145
- }
148
+ else {
149
+ filterQuery.skip(this.virtualItemStartIndex);
150
+ }
151
+ if (queryTakeValue > 0 && takeValue <= queryTakeValue) {
152
+ filterQuery.take(queryTakeValue);
153
+ }
154
+ else {
155
+ filterQuery.take(takeValue);
146
156
  }
147
157
  filterQuery.requiresCount();
148
158
  }
159
+ else if (this.enableVirtualization && (this.dataSource instanceof DataManager && !this.virtualGroupDataSource)) {
160
+ for (var queryElements = 0; queryElements < filterQuery.queries.length; queryElements++) {
161
+ if (filterQuery.queries[queryElements].fn === 'onSkip' || filterQuery.queries[queryElements].fn === 'onTake') {
162
+ filterQuery.queries.splice(queryElements, 1);
163
+ --queryElements;
164
+ }
165
+ }
166
+ }
149
167
  return filterQuery;
150
168
  };
151
169
  AutoComplete.prototype.searchLists = function (e) {
@@ -174,6 +192,7 @@ var AutoComplete = /** @class */ (function (_super) {
174
192
  return;
175
193
  }
176
194
  _this_1.isFiltered = true;
195
+ _this_1.customFilterQuery = query;
177
196
  _this_1.filterAction(dataSource, query, fields);
178
197
  },
179
198
  cancel: false
@@ -304,10 +323,6 @@ var AutoComplete = /** @class */ (function (_super) {
304
323
  }, 0);
305
324
  }
306
325
  else {
307
- var isHtmlElement = /<[^>]*>/g.test(e.item.innerText);
308
- if (isHtmlElement) {
309
- e.item.innerText = e.item.innerText.replace(/[\u00A0-\u9999<>&]/g, function (match) { return "&#" + match.charCodeAt(0) + ";"; });
310
- }
311
326
  highlightSearch(e.item, _this_1.queryString, _this_1.ignoreCase, _this_1.filterType);
312
327
  }
313
328
  }
@@ -456,6 +471,7 @@ var AutoComplete = /** @class */ (function (_super) {
456
471
  revertHighlightSearch(this.liCollections[i]);
457
472
  highlightSearch(this.liCollections[i], this.queryString, this.ignoreCase, this.filterType);
458
473
  }
474
+ isHighlight = null;
459
475
  }
460
476
  }
461
477
  };
@@ -500,7 +500,7 @@ var ComboBox = /** @class */ (function (_super) {
500
500
  this.preventAutoFill = this.inputElement.value === '' ? false : this.preventAutoFill;
501
501
  this.setAutoFill(activeElement, isKeyNavigate);
502
502
  }
503
- else if (this.inputElement.value === '') {
503
+ else if (!isNullOrUndefined(this.inputElement) && this.inputElement.value === '') {
504
504
  this.activeIndex = null;
505
505
  if (!isNullOrUndefined(this.list)) {
506
506
  if (!this.enableVirtualization) {
@@ -757,9 +757,6 @@ var ComboBox = /** @class */ (function (_super) {
757
757
  ComboBox.prototype.render = function () {
758
758
  _super.prototype.render.call(this);
759
759
  this.setSearchBox();
760
- if (this.isFiltering() && this.getModuleName() === 'combobox' && isNullOrUndefined(this.list)) {
761
- _super.prototype.renderList.call(this);
762
- }
763
760
  this.renderComplete();
764
761
  };
765
762
  /**
@@ -8,6 +8,10 @@
8
8
  * @returns {void}
9
9
  */
10
10
  export function highlightSearch(element, query, ignoreCase, type) {
11
+ var isHtmlElement = /<[^>]*>/g.test(element.innerText);
12
+ if (isHtmlElement) {
13
+ element.innerText = element.innerText.replace(/[\u00A0-\u9999<>&]/g, function (match) { return "&#" + match.charCodeAt(0) + ";"; });
14
+ }
11
15
  if (query === '') {
12
16
  return;
13
17
  }
@@ -43,6 +43,7 @@ export interface IDropdownlist extends Component<HTMLElement> {
43
43
  typedString: string;
44
44
  isVirtualScrolling: boolean;
45
45
  isCustomFilter: boolean;
46
+ customFilterQuery: Query;
46
47
  allowFiltering: boolean;
47
48
  isPopupOpen: boolean;
48
49
  isTyped: boolean;
@@ -234,10 +234,8 @@ var VirtualScroll = /** @class */ (function () {
234
234
  this.parent.list.querySelector('.e-virtual-ddl-content').removeChild(reOrderList);
235
235
  }
236
236
  var query = this.parent.getForQuery(this.parent.value).clone();
237
- if (!this.parent.allowFiltering) { //need to check with allowFiltering false
238
- var skipvalue = this.parent.viewPortInfo.startIndex - this.parent.value.length >= 0 ? this.parent.viewPortInfo.startIndex - this.parent.value.length : 0;
239
- query = query.skip(skipvalue);
240
- }
237
+ var skipvalue = this.parent.viewPortInfo.startIndex - this.parent.value.length >= 0 ? this.parent.viewPortInfo.startIndex - this.parent.value.length : 0;
238
+ query = query.skip(skipvalue);
241
239
  this.parent.resetList(this.parent.dataSource, this.parent.fields, query);
242
240
  isListUpdated = false;
243
241
  }
@@ -403,7 +401,9 @@ var VirtualScroll = /** @class */ (function () {
403
401
  if (this.parent.keyboardEvent != null) {
404
402
  this.parent.handleVirtualKeyboardActions(this.parent.keyboardEvent, this.parent.pageCount);
405
403
  }
406
- this.parent.isCustomFilter = false;
404
+ if (!this.parent.customFilterQuery) {
405
+ this.parent.isCustomFilter = false;
406
+ }
407
407
  return [2 /*return*/];
408
408
  }
409
409
  });
@@ -275,6 +275,9 @@ export declare class DropDownBase extends Component<HTMLElement> implements INot
275
275
  protected incrementalPreQueryString: string;
276
276
  protected isObjectCustomValue: boolean;
277
277
  protected appendUncheckList: boolean;
278
+ protected getInitialData: boolean;
279
+ protected preventPopupOpen: boolean;
280
+ protected customFilterQuery: Query;
278
281
  protected virtualSelectAllData: {
279
282
  [key: string]: Object;
280
283
  }[] | DataManager | string[] | number[] | boolean[];
@@ -127,6 +127,9 @@ var DropDownBase = /** @class */ (function (_super) {
127
127
  _this.incrementalPreQueryString = '';
128
128
  _this.isObjectCustomValue = false;
129
129
  _this.appendUncheckList = false;
130
+ _this.getInitialData = false;
131
+ _this.preventPopupOpen = true;
132
+ _this.customFilterQuery = new Query();
130
133
  _this.virtualListInfo = {
131
134
  currentPageNumber: null,
132
135
  direction: null,
@@ -441,6 +444,7 @@ var DropDownBase = /** @class */ (function (_super) {
441
444
  var actualCount = this.virtualListHeight > 0 ? Math.floor(this.virtualListHeight / this.listItemHeight) : 0;
442
445
  this.skeletonCount = actualCount * 2 < this.itemCount ? this.itemCount : actualCount * 2;
443
446
  this.itemCount = retainSkeleton ? this.itemCount : this.skeletonCount;
447
+ this.virtualItemCount = this.itemCount;
444
448
  this.skeletonCount = Math.floor(this.skeletonCount / 2) + 2;
445
449
  };
446
450
  DropDownBase.prototype.GetVirtualTrackHeight = function () {
@@ -534,6 +538,7 @@ var DropDownBase = /** @class */ (function (_super) {
534
538
  */
535
539
  DropDownBase.prototype.initialize = function (e) {
536
540
  this.bindEvent = true;
541
+ this.preventPopupOpen = true;
537
542
  this.actionFailureTemplateId = "" + this.element.id + ACTIONFAILURETEMPLATE_PROPERTY;
538
543
  if (this.element.tagName === 'UL') {
539
544
  var jsonElement = ListBase.createJsonFromElement(this.element);
@@ -719,6 +724,12 @@ var DropDownBase = /** @class */ (function (_super) {
719
724
  }
720
725
  _this.isRequested = false;
721
726
  _this.bindChildItems(listItems, ulElement, fields, e);
727
+ if (_this.getInitialData) {
728
+ _this.setListData(dataSource, fields, query, event);
729
+ _this.getInitialData = false;
730
+ _this.preventPopupOpen = false;
731
+ return;
732
+ }
722
733
  }
723
734
  });
724
735
  }).catch(function (e) {
@@ -790,6 +801,11 @@ var DropDownBase = /** @class */ (function (_super) {
790
801
  _this.renderGroupTemplate(ulElement);
791
802
  }
792
803
  _this.bindChildItems(localDataArgs.result, ulElement, fields);
804
+ if (_this.getInitialData) {
805
+ _this.getInitialData = false;
806
+ _this.preventPopupOpen = false;
807
+ return;
808
+ }
793
809
  setTimeout(function () {
794
810
  if (_this.getModuleName() === 'multiselect' && _this.itemTemplate != null && (ulElement.childElementCount > 0 && (ulElement.children[0].childElementCount > 0 || (_this.fields.groupBy && ulElement.children[1] && ulElement.children[1].childElementCount > 0)))) {
795
811
  _this.updateDataList();
@@ -891,7 +907,7 @@ var DropDownBase = /** @class */ (function (_super) {
891
907
  DropDownBase.prototype.onActionComplete = function (ulElement, list, e) {
892
908
  /* eslint-enable @typescript-eslint/no-unused-vars */
893
909
  this.listData = list;
894
- if (this.isVirtualizationEnabled && !this.isCustomDataUpdated) {
910
+ if (this.isVirtualizationEnabled && !this.isCustomDataUpdated && !this.virtualSelectAll) {
895
911
  this.notify("setGeneratedData", {
896
912
  module: "VirtualScroll",
897
913
  });
@@ -1113,6 +1129,9 @@ var DropDownBase = /** @class */ (function (_super) {
1113
1129
  this.fixedHeaderElement.style.display = 'block';
1114
1130
  };
1115
1131
  DropDownBase.prototype.getValidLi = function () {
1132
+ if (this.isVirtualizationEnabled) {
1133
+ return this.liCollections[0].classList.contains('e-virtual-list') ? this.liCollections[this.skeletonCount] : this.liCollections[0];
1134
+ }
1116
1135
  return this.liCollections[0];
1117
1136
  };
1118
1137
  /**
@@ -1187,7 +1206,7 @@ var DropDownBase = /** @class */ (function (_super) {
1187
1206
  }
1188
1207
  this.updateListElements(listData);
1189
1208
  }
1190
- else if ((!virtualUlElement)) {
1209
+ else if ((!virtualUlElement) || (!virtualUlElement.firstChild)) {
1191
1210
  this.list.innerHTML = '';
1192
1211
  this.createVirtualContent();
1193
1212
  this.list.querySelector('.e-virtual-ddl-content').appendChild(ulElement);
@@ -1532,6 +1551,7 @@ var DropDownBase = /** @class */ (function (_super) {
1532
1551
  }
1533
1552
  }
1534
1553
  var itemsCount = this.getItems().length;
1554
+ var isListboxEmpty = itemsCount === 0;
1535
1555
  var selectedItemValue = this.list.querySelector('.' + dropDownBaseClasses.selected);
1536
1556
  items = (items instanceof Array ? items : [items]);
1537
1557
  var index;
@@ -1566,11 +1586,24 @@ var DropDownBase = /** @class */ (function (_super) {
1566
1586
  li.setAttribute('role', 'option');
1567
1587
  this.notify('addItem', { module: 'CheckBoxSelection', item: li });
1568
1588
  liCollections.push(li);
1569
- this.listData.push(item);
1589
+ if (this.getModuleName() === 'listbox') {
1590
+ this.listData.splice(isListboxEmpty ? this.listData.length : index, 0, item);
1591
+ if (this.listData.length !== this.sortedData.length) {
1592
+ this.sortedData = this.listData;
1593
+ }
1594
+ }
1595
+ else {
1596
+ this.listData.push(item);
1597
+ }
1570
1598
  if (this.sortOrder === 'None' && isNullOrUndefined(itemIndex) && index === 0) {
1571
1599
  index = null;
1572
1600
  }
1573
- this.updateActionCompleteData(li, item, index);
1601
+ if (this.getModuleName() === 'listbox') {
1602
+ this.updateActionCompleteData(li, item, isListboxEmpty ? null : index);
1603
+ }
1604
+ else {
1605
+ this.updateActionCompleteData(li, item, index);
1606
+ }
1574
1607
  //Listbox event
1575
1608
  this.trigger('beforeItemRender', { element: li, item: item });
1576
1609
  }
@@ -1678,6 +1678,10 @@ var DropDownList = /** @class */ (function (_super) {
1678
1678
  e.preventDefault();
1679
1679
  break;
1680
1680
  default:
1681
+ if (this.isFiltering() && this.getModuleName() === 'combobox' && isNullOrUndefined(this.list)) {
1682
+ this.getInitialData = true;
1683
+ this.renderList();
1684
+ }
1681
1685
  this.typedString = this.filterInput.value;
1682
1686
  this.preventAutoFill = false;
1683
1687
  this.searchLists(e);
@@ -1726,13 +1730,13 @@ var DropDownList = /** @class */ (function (_super) {
1726
1730
  if (!(this.dataSource instanceof DataManager) && dataType === 'string' || dataType === 'number') {
1727
1731
  filterQuery.where('', filterType, this.typedString, this.ignoreCase, this.ignoreAccent);
1728
1732
  }
1729
- else {
1733
+ else if (((this.getModuleName() !== 'combobox') || this.enableVirtualization) || (this.isFiltering() && this.getModuleName() === 'combobox' && this.typedString !== '')) {
1730
1734
  var fields = (this.fields.text) ? this.fields.text : '';
1731
1735
  filterQuery.where(fields, filterType, this.typedString, this.ignoreCase, this.ignoreAccent);
1732
1736
  }
1733
1737
  }
1734
1738
  else {
1735
- filterQuery = query ? query.clone() : this.query ? this.query.clone() : new Query();
1739
+ filterQuery = (this.enableVirtualization && !isNullOrUndefined(this.customFilterQuery)) ? this.customFilterQuery.clone() : query ? query.clone() : this.query ? this.query.clone() : new Query();
1736
1740
  }
1737
1741
  if (this.enableVirtualization && (this.viewPortInfo.endIndex != 0) && (!(this.dataSource instanceof DataManager) || (this.dataSource instanceof DataManager && this.virtualGroupDataSource))) {
1738
1742
  var takeValue = this.getTakeValue();
@@ -1747,26 +1751,36 @@ var DropDownList = /** @class */ (function (_super) {
1747
1751
  }
1748
1752
  var queryTakeValue = 0;
1749
1753
  var querySkipValue = 0;
1750
- if (this.query && this.query.queries.length > 0) {
1751
- for (var queryElements_1 = 0; queryElements_1 < this.query.queries.length; queryElements_1++) {
1752
- if (this.query.queries[queryElements_1].fn === 'onSkip') {
1753
- querySkipValue = this.query.queries[queryElements_1].e.nos;
1754
+ if (filterQuery && filterQuery.queries.length > 0) {
1755
+ for (var queryElements_1 = 0; queryElements_1 < filterQuery.queries.length; queryElements_1++) {
1756
+ if (filterQuery.queries[queryElements_1].fn === 'onSkip') {
1757
+ querySkipValue = filterQuery.queries[queryElements_1].e.nos;
1758
+ }
1759
+ if (filterQuery.queries[queryElements_1].fn === 'onTake') {
1760
+ queryTakeValue = takeValue <= filterQuery.queries[queryElements_1].e.nos ? filterQuery.queries[queryElements_1].e.nos : takeValue;
1754
1761
  }
1755
- if (this.query.queries[queryElements_1].fn === 'onTake') {
1756
- queryTakeValue = takeValue <= this.query.queries[queryElements_1].e.nos ? this.query.queries[queryElements_1].e.nos : takeValue;
1762
+ }
1763
+ }
1764
+ if (queryTakeValue <= 0 && this.query && this.query.queries.length > 0) {
1765
+ for (var queryElements_2 = 0; queryElements_2 < this.query.queries.length; queryElements_2++) {
1766
+ if (this.query.queries[queryElements_2].fn === 'onTake') {
1767
+ queryTakeValue = takeValue <= this.query.queries[queryElements_2].e.nos ? this.query.queries[queryElements_2].e.nos : takeValue;
1757
1768
  }
1758
1769
  }
1759
1770
  }
1760
1771
  var skipExists = false;
1761
- var takeExists = false;
1762
1772
  if (filterQuery && filterQuery.queries.length > 0) {
1763
- for (var queryElements_2 = 0; queryElements_2 < filterQuery.queries.length; queryElements_2++) {
1764
- if (filterQuery.queries[queryElements_2].fn === 'onSkip') {
1765
- skipExists = true;
1773
+ for (var queryElements_3 = 0; queryElements_3 < filterQuery.queries.length; queryElements_3++) {
1774
+ if (filterQuery.queries[queryElements_3].fn === 'onSkip') {
1775
+ querySkipValue = filterQuery.queries[queryElements_3].e.nos;
1776
+ filterQuery.queries.splice(queryElements_3, 1);
1777
+ --queryElements_3;
1778
+ continue;
1766
1779
  }
1767
- if (filterQuery.queries[queryElements_2].fn === 'onTake') {
1768
- takeExists = true;
1769
- filterQuery.queries[queryElements_2].e.nos = filterQuery.queries[queryElements_2].e.nos <= queryTakeValue ? queryTakeValue : filterQuery.queries[queryElements_2].e.nos;
1780
+ if (filterQuery.queries[queryElements_3].fn === 'onTake') {
1781
+ queryTakeValue = filterQuery.queries[queryElements_3].e.nos <= queryTakeValue ? queryTakeValue : filterQuery.queries[queryElements_3].e.nos;
1782
+ filterQuery.queries.splice(queryElements_3, 1);
1783
+ --queryElements_3;
1770
1784
  }
1771
1785
  }
1772
1786
  }
@@ -1782,17 +1796,23 @@ var DropDownList = /** @class */ (function (_super) {
1782
1796
  filterQuery.take(this.incrementalEndIndex);
1783
1797
  }
1784
1798
  else {
1785
- if (!takeExists) {
1786
- if (queryTakeValue > 0) {
1787
- filterQuery.take(queryTakeValue);
1788
- }
1789
- else {
1790
- filterQuery.take(takeValue);
1791
- }
1799
+ if (queryTakeValue > 0) {
1800
+ filterQuery.take(queryTakeValue);
1801
+ }
1802
+ else {
1803
+ filterQuery.take(takeValue);
1792
1804
  }
1793
1805
  }
1794
1806
  filterQuery.requiresCount();
1795
1807
  }
1808
+ else if (this.enableVirtualization && (this.dataSource instanceof DataManager && !this.virtualGroupDataSource)) {
1809
+ for (var queryElements_4 = 0; queryElements_4 < filterQuery.queries.length; queryElements_4++) {
1810
+ if (filterQuery.queries[queryElements_4].fn === 'onSkip' || filterQuery.queries[queryElements_4].fn === 'onTake') {
1811
+ filterQuery.queries.splice(queryElements_4, 1);
1812
+ --queryElements_4;
1813
+ }
1814
+ }
1815
+ }
1796
1816
  return filterQuery;
1797
1817
  };
1798
1818
  DropDownList.prototype.getSelectionPoints = function () {
@@ -1819,6 +1839,7 @@ var DropDownList = /** @class */ (function (_super) {
1819
1839
  return;
1820
1840
  }
1821
1841
  _this.isCustomFilter = true;
1842
+ _this.customFilterQuery = query;
1822
1843
  _this.filteringAction(dataSource, query, fields);
1823
1844
  },
1824
1845
  baseEventArgs: e,
@@ -1846,7 +1867,7 @@ var DropDownList = /** @class */ (function (_super) {
1846
1867
  };
1847
1868
  DropDownList.prototype.filteringAction = function (dataSource, query, fields) {
1848
1869
  if (!isNullOrUndefined(this.filterInput)) {
1849
- this.beforePopupOpen = (!this.isPopupOpen && this.getModuleName() === 'combobox' && this.filterInput.value === '') ?
1870
+ this.beforePopupOpen = ((!this.isPopupOpen && this.getModuleName() === 'combobox' && this.filterInput.value === '') || this.getInitialData) ?
1850
1871
  false : true;
1851
1872
  var isNoData = this.list.classList.contains(dropDownBaseClasses.noData);
1852
1873
  if (this.filterInput.value.trim() === '' && !this.itemTemplate) {
@@ -1854,6 +1875,12 @@ var DropDownList = /** @class */ (function (_super) {
1854
1875
  this.isTyped = false;
1855
1876
  if (!isNullOrUndefined(this.actionCompleteData.ulElement) && !isNullOrUndefined(this.actionCompleteData.list)) {
1856
1877
  if (this.enableVirtualization) {
1878
+ if (this.isFiltering()) {
1879
+ this.isPreventScrollAction = true;
1880
+ this.list.scrollTop = 0;
1881
+ this.previousStartIndex = 0;
1882
+ this.virtualListInfo = null;
1883
+ }
1857
1884
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
1858
1885
  this.totalItemCount = this.dataSource && this.dataSource.length ? this.dataSource.length : 0;
1859
1886
  this.resetList(dataSource, fields, query);
@@ -2024,6 +2051,13 @@ var DropDownList = /** @class */ (function (_super) {
2024
2051
  this.isNotSearchList = false;
2025
2052
  return;
2026
2053
  }
2054
+ if (this.getInitialData) {
2055
+ this.updateActionCompleteDataValues(ulElement, list);
2056
+ }
2057
+ if (!this.preventPopupOpen && this.getModuleName() === 'combobox') {
2058
+ this.beforePopupOpen = true;
2059
+ this.preventPopupOpen = true;
2060
+ }
2027
2061
  var tempItemCount = this.itemCount;
2028
2062
  if (this.isActive || !isNullOrUndefined(ulElement)) {
2029
2063
  var selectedItem = this.selectedLI ? this.selectedLI.cloneNode(true) : null;
@@ -2207,7 +2241,7 @@ var DropDownList = /** @class */ (function (_super) {
2207
2241
  else {
2208
2242
  this.actionCompleteData.ulElement.appendChild(li.cloneNode(true));
2209
2243
  }
2210
- if (this.isFiltering() && this.actionCompleteData.list.indexOf(item) < 0) {
2244
+ if (this.isFiltering() && this.actionCompleteData.list && this.actionCompleteData.list.indexOf(item) < 0) {
2211
2245
  this.actionCompleteData.list.push(item);
2212
2246
  }
2213
2247
  };
@@ -2263,7 +2297,7 @@ var DropDownList = /** @class */ (function (_super) {
2263
2297
  popupEle.setAttribute('aria-label', _this.element.id);
2264
2298
  popupEle.setAttribute('role', 'dialog');
2265
2299
  var searchBox = _this.setSearchBox(popupEle);
2266
- _this.listContainerHeight = formatUnit(_this.popupHeight);
2300
+ _this.listContainerHeight = _this.allowFiltering && _this.getModuleName() === 'dropdownlist' && Browser.isDevice ? formatUnit(Math.round(window.outerHeight).toString() + 'px') : formatUnit(_this.popupHeight);
2267
2301
  if (_this.headerTemplate) {
2268
2302
  _this.setHeaderTemplate(popupEle);
2269
2303
  }
@@ -2278,6 +2312,8 @@ var DropDownList = /** @class */ (function (_super) {
2278
2312
  _this.listItemHeight = listitems.length > 0 ? Math.ceil(listitems[0].getBoundingClientRect().height) : 0;
2279
2313
  }
2280
2314
  if (_this.enableVirtualization && !_this.list.classList.contains(dropDownBaseClasses.noData)) {
2315
+ _this.getSkeletonCount();
2316
+ _this.skeletonCount = _this.totalItemCount < (_this.itemCount * 2) ? 0 : _this.skeletonCount;
2281
2317
  if (!_this.list.querySelector('.e-virtual-ddl-content')) {
2282
2318
  _this.list.appendChild(_this.createElement('div', {
2283
2319
  className: 'e-virtual-ddl-content',
@@ -2584,7 +2620,7 @@ var DropDownList = /** @class */ (function (_super) {
2584
2620
  var inputWidth = this.inputWrapper.container.offsetWidth * parseFloat(width) / 100;
2585
2621
  width = inputWidth.toString() + 'px';
2586
2622
  }
2587
- if (Browser.isDevice && (!this.allowFiltering && (this.getModuleName() === 'dropdownlist' ||
2623
+ if (Browser.isDevice && (width.indexOf('px') > -1) && (!this.allowFiltering && (this.getModuleName() === 'dropdownlist' ||
2588
2624
  (this.isDropDownClick && this.getModuleName() === 'combobox')))) {
2589
2625
  var firstItem = this.isEmptyList() ? this.list : this.liCollections[0];
2590
2626
  width = (parseInt(width, 10) + (parseInt(getComputedStyle(firstItem).textIndent, 10) -
@@ -2889,7 +2925,7 @@ var DropDownList = /** @class */ (function (_super) {
2889
2925
  // eslint-disable-next-line @typescript-eslint/no-explicit-any
2890
2926
  dataSourceCount = this.dataSource && this.dataSource.length ? this.dataSource.length : 0;
2891
2927
  }
2892
- if (this.enableVirtualization && this.isFiltering() && this.value != null && isFilterValue && this.totalItemCount !== dataSourceCount) {
2928
+ if (this.enableVirtualization && this.isFiltering() && isFilterValue && this.totalItemCount !== dataSourceCount) {
2893
2929
  this.updateInitialData();
2894
2930
  this.checkAndResetCache();
2895
2931
  }
@@ -3010,7 +3046,7 @@ var DropDownList = /** @class */ (function (_super) {
3010
3046
  this.setFields();
3011
3047
  this.inputWrapper.container.style.width = formatUnit(this.width);
3012
3048
  this.inputWrapper.container.classList.add('e-ddl');
3013
- if (this.floatLabelType === 'Auto') {
3049
+ if (this.floatLabelType !== 'Never') {
3014
3050
  Input.calculateWidth(this.inputElement, this.inputWrapper.container);
3015
3051
  }
3016
3052
  if (!isNullOrUndefined(this.inputWrapper.buttons[0]) && this.inputWrapper.container.getElementsByClassName('e-float-text-content')[0] && this.floatLabelType !== 'Never') {
@@ -3660,6 +3696,7 @@ var DropDownList = /** @class */ (function (_super) {
3660
3696
  }
3661
3697
  }
3662
3698
  this.isVirtualTrackHeight = false;
3699
+ this.customFilterQuery = null;
3663
3700
  this.closePopup(0, e);
3664
3701
  var dataItem = this.getItemData();
3665
3702
  var isSelectVal = !isNullOrUndefined(this.selectedLI);
@@ -3697,7 +3734,7 @@ var DropDownList = /** @class */ (function (_super) {
3697
3734
  }
3698
3735
  addClass([this.inputWrapper.container], [dropDownListClasses.inputFocus]);
3699
3736
  this.onFocus(e);
3700
- if (this.floatLabelType === 'Auto') {
3737
+ if (this.floatLabelType !== 'Never') {
3701
3738
  Input.calculateWidth(this.inputElement, this.inputWrapper.container);
3702
3739
  }
3703
3740
  };
@@ -3719,7 +3756,7 @@ var DropDownList = /** @class */ (function (_super) {
3719
3756
  this.targetElement().blur();
3720
3757
  }
3721
3758
  removeClass([this.inputWrapper.container], [dropDownListClasses.inputFocus]);
3722
- if (this.floatLabelType === 'Auto' && this.inputElement.value === '') {
3759
+ if (this.floatLabelType !== 'Never') {
3723
3760
  Input.calculateWidth(this.inputElement, this.inputWrapper.container);
3724
3761
  }
3725
3762
  };
@@ -3770,17 +3807,18 @@ var DropDownList = /** @class */ (function (_super) {
3770
3807
  detach(this.inputWrapper.container);
3771
3808
  }
3772
3809
  this.hiddenElement = null;
3810
+ this.filterInput = null;
3773
3811
  this.inputWrapper = null;
3774
3812
  this.keyboardModule = null;
3775
3813
  this.ulElement = null;
3776
3814
  this.list = null;
3815
+ this.clearIconElement = null;
3777
3816
  this.popupObj = null;
3778
3817
  this.popupContentElement = null;
3779
3818
  this.rippleFun = null;
3780
3819
  this.selectedLI = null;
3781
3820
  this.liCollections = null;
3782
3821
  this.item = null;
3783
- this.inputWrapper = null;
3784
3822
  this.footer = null;
3785
3823
  this.header = null;
3786
3824
  this.previousSelectedLI = null;
@@ -3797,9 +3835,8 @@ var DropDownList = /** @class */ (function (_super) {
3797
3835
  floatLabelType: this.floatLabelType,
3798
3836
  properties: this.properties
3799
3837
  }, this.clearButton);
3800
- if (this.isAngular) {
3801
- this.inputElement = null;
3802
- }
3838
+ this.clearButton = null;
3839
+ this.inputElement = null;
3803
3840
  _super.prototype.destroy.call(this);
3804
3841
  };
3805
3842
  /* eslint-disable valid-jsdoc, jsdoc/require-returns-description */