@syncfusion/ej2-dropdowns 20.4.38 → 20.4.42
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 +37 -0
- package/README.md +1 -1
- 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 +40 -8
- package/dist/es6/ej2-dropdowns.es2015.js.map +1 -1
- package/dist/es6/ej2-dropdowns.es5.js +39 -7
- 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 +13 -12
- package/src/drop-down-base/drop-down-base.js +1 -1
- package/src/drop-down-tree/drop-down-tree.js +3 -0
- package/src/list-box/list-box-model.d.ts +6 -6
- package/src/list-box/list-box.js +11 -3
- package/src/mention/mention.js +12 -3
- package/src/multi-select/multi-select.d.ts +2 -0
- package/src/multi-select/multi-select.js +12 -0
|
@@ -655,10 +655,10 @@ var DropDownBase = /** @__PURE__ @class */ (function (_super) {
|
|
|
655
655
|
_this.isDataFetched = true;
|
|
656
656
|
}
|
|
657
657
|
ulElement = _this.renderItems(listItems, fields);
|
|
658
|
+
_this.onActionComplete(ulElement, listItems, e);
|
|
658
659
|
if (_this.groupTemplate) {
|
|
659
660
|
_this.renderGroupTemplate(ulElement);
|
|
660
661
|
}
|
|
661
|
-
_this.onActionComplete(ulElement, listItems, e);
|
|
662
662
|
_this.isRequested = false;
|
|
663
663
|
_this.bindChildItems(listItems, ulElement, fields, e);
|
|
664
664
|
}
|
|
@@ -6057,6 +6057,9 @@ var DropDownTree = /** @__PURE__ @class */ (function (_super) {
|
|
|
6057
6057
|
}
|
|
6058
6058
|
var eventArgs = { data: args.data };
|
|
6059
6059
|
this.trigger('dataBound', eventArgs);
|
|
6060
|
+
if (this.filterObj === null) {
|
|
6061
|
+
this.isFilteredData = false;
|
|
6062
|
+
}
|
|
6060
6063
|
if (this.isFilteredData) {
|
|
6061
6064
|
this.treeObj.expandAll();
|
|
6062
6065
|
}
|
|
@@ -9088,6 +9091,8 @@ var MultiSelect = /** @__PURE__ @class */ (function (_super) {
|
|
|
9088
9091
|
_this.isValidKey = false;
|
|
9089
9092
|
_this.selectAllEventData = [];
|
|
9090
9093
|
_this.selectAllEventEle = [];
|
|
9094
|
+
_this.resetMainList = null;
|
|
9095
|
+
_this.resetFilteredData = false;
|
|
9091
9096
|
_this.scrollFocusStatus = false;
|
|
9092
9097
|
_this.keyDownStatus = false;
|
|
9093
9098
|
return _this;
|
|
@@ -9834,6 +9839,10 @@ var MultiSelect = /** @__PURE__ @class */ (function (_super) {
|
|
|
9834
9839
|
}
|
|
9835
9840
|
}
|
|
9836
9841
|
this.updateDataList();
|
|
9842
|
+
if (this.resetMainList) {
|
|
9843
|
+
this.mainList = this.resetMainList;
|
|
9844
|
+
this.resetMainList = null;
|
|
9845
|
+
}
|
|
9837
9846
|
this.refreshListItems(null);
|
|
9838
9847
|
if (this.mode !== 'Box' && this.mode !== 'CheckBox') {
|
|
9839
9848
|
this.updateDelimView();
|
|
@@ -11249,6 +11258,7 @@ var MultiSelect = /** @__PURE__ @class */ (function (_super) {
|
|
|
11249
11258
|
};
|
|
11250
11259
|
MultiSelect.prototype.search = function (e) {
|
|
11251
11260
|
var _this = this;
|
|
11261
|
+
this.resetFilteredData = true;
|
|
11252
11262
|
if (!isNullOrUndefined(e)) {
|
|
11253
11263
|
this.keyCode = e.keyCode;
|
|
11254
11264
|
}
|
|
@@ -12443,6 +12453,11 @@ var MultiSelect = /** @__PURE__ @class */ (function (_super) {
|
|
|
12443
12453
|
MultiSelect.prototype.onPropertyChanged = function (newProp, oldProp) {
|
|
12444
12454
|
if (newProp.dataSource && !isNullOrUndefined(Object.keys(newProp.dataSource))
|
|
12445
12455
|
|| newProp.query && !isNullOrUndefined(Object.keys(newProp.query))) {
|
|
12456
|
+
if (this.resetFilteredData) {
|
|
12457
|
+
// The filtered data is not being reset in the component after the user focuses out.
|
|
12458
|
+
this.resetMainList = !this.resetMainList ? this.mainList : this.resetMainList;
|
|
12459
|
+
this.resetFilteredData = false;
|
|
12460
|
+
}
|
|
12446
12461
|
this.mainList = null;
|
|
12447
12462
|
this.mainData = null;
|
|
12448
12463
|
this.isFirstClick = false;
|
|
@@ -14366,6 +14381,7 @@ var ListBox = /** @__PURE__ @class */ (function (_super) {
|
|
|
14366
14381
|
dragArgs = extend(dragArgs, { destination: dragArgs1 });
|
|
14367
14382
|
}
|
|
14368
14383
|
this.trigger('drop', dragArgs);
|
|
14384
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
14369
14385
|
var liCollElem = dragArgs.elements;
|
|
14370
14386
|
if (liCollElem.length) {
|
|
14371
14387
|
for (var i = 0; i < liCollElem.length; i++) {
|
|
@@ -15263,7 +15279,7 @@ var ListBox = /** @__PURE__ @class */ (function (_super) {
|
|
|
15263
15279
|
var isRefresh = tListBox.sortOrder !== 'None' || (tListBox.selectionSettings.showCheckbox !==
|
|
15264
15280
|
fListBox.selectionSettings.showCheckbox) || tListBox.fields.groupBy || tListBox.itemTemplate || fListBox.itemTemplate;
|
|
15265
15281
|
this.removeSelected(fListBox, fListBox.getSelectedItems());
|
|
15266
|
-
var tempItems = [].slice.call(fListBox.
|
|
15282
|
+
var tempItems = [].slice.call(fListBox.listData);
|
|
15267
15283
|
var localDataArgs = { cancel: false, items: tempItems, eventName: this.toolbarAction };
|
|
15268
15284
|
fListBox.trigger('actionBegin', localDataArgs);
|
|
15269
15285
|
if (localDataArgs.cancel) {
|
|
@@ -15308,11 +15324,18 @@ var ListBox = /** @__PURE__ @class */ (function (_super) {
|
|
|
15308
15324
|
fListBox.value = [];
|
|
15309
15325
|
listData = listData
|
|
15310
15326
|
.filter(function (data) { return data.isHeader !== true; });
|
|
15311
|
-
|
|
15327
|
+
var sortedData = listData.filter(function (val) {
|
|
15328
|
+
return tListBox.jsonData.indexOf(val) === -1;
|
|
15329
|
+
});
|
|
15330
|
+
for (var i = 0; i < sortedData.length; i++) {
|
|
15331
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
15332
|
+
tListBox.jsonData.splice(index + i, 0, sortedData[i]);
|
|
15333
|
+
}
|
|
15334
|
+
tListBox.listData = listData;
|
|
15312
15335
|
if (fListBox.listData.length === fListBox.jsonData.length) {
|
|
15313
15336
|
fListBox.listData = fListBox.sortedData = fListBox.jsonData = [];
|
|
15314
15337
|
}
|
|
15315
|
-
else if (
|
|
15338
|
+
else if (fListBox.allowFiltering) {
|
|
15316
15339
|
for (var i = 0; i < fListBox.listData.length; i++) {
|
|
15317
15340
|
for (var j = 0; j < fListBox.jsonData.length; j++) {
|
|
15318
15341
|
if (fListBox.listData[i] === fListBox.jsonData[j]) {
|
|
@@ -16707,9 +16730,18 @@ var Mention = /** @__PURE__ @class */ (function (_super) {
|
|
|
16707
16730
|
var args = { cancel: false };
|
|
16708
16731
|
this.trigger('beforeOpen', args, function (args) {
|
|
16709
16732
|
if (!args.cancel) {
|
|
16710
|
-
var popupEle_1
|
|
16711
|
-
|
|
16712
|
-
|
|
16733
|
+
var popupEle_1;
|
|
16734
|
+
if (isNullOrUndefined(_this.target)) {
|
|
16735
|
+
popupEle_1 = _this.createElement('div', {
|
|
16736
|
+
id: _this.inputElement.id + '_popup', className: 'e-mention e-popup ' + (_this.cssClass != null ? _this.cssClass : '')
|
|
16737
|
+
});
|
|
16738
|
+
}
|
|
16739
|
+
else {
|
|
16740
|
+
popupEle_1 = _this.element;
|
|
16741
|
+
if (_this.cssClass != null) {
|
|
16742
|
+
addClass([popupEle_1], _this.cssClass.split(' '));
|
|
16743
|
+
}
|
|
16744
|
+
}
|
|
16713
16745
|
if (!isNullOrUndefined(_this.target)) {
|
|
16714
16746
|
popupEle_1.id = _this.inputElement.id + '_popup';
|
|
16715
16747
|
addClass([popupEle_1], ['e-mention', 'e-popup', 'e-popup-close']);
|