@syncfusion/ej2-dropdowns 19.3.48 → 19.4.38
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 +32 -0
- package/README.md +1 -1
- 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 +123 -42
- package/dist/es6/ej2-dropdowns.es2015.js.map +1 -1
- package/dist/es6/ej2-dropdowns.es5.js +125 -42
- 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 +11 -11
- package/src/combo-box/combo-box.js +2 -2
- package/src/common/incremental-search.d.ts +1 -1
- package/src/common/incremental-search.js +1 -1
- package/src/drop-down-base/drop-down-base.js +17 -0
- package/src/drop-down-list/drop-down-list.js +1 -1
- package/src/drop-down-tree/drop-down-tree.d.ts +1 -0
- package/src/drop-down-tree/drop-down-tree.js +21 -6
- package/src/list-box/list-box.d.ts +0 -4
- package/src/list-box/list-box.js +0 -3
- package/src/multi-select/checkbox-selection.js +1 -1
- package/src/multi-select/multi-select-model.d.ts +10 -1
- package/src/multi-select/multi-select.d.ts +10 -0
- package/src/multi-select/multi-select.js +82 -28
- package/styles/auto-complete/_fluent-definition.scss +2 -0
- package/styles/bootstrap5-dark.css +12 -5
- package/styles/bootstrap5.css +12 -5
- package/styles/combo-box/_fluent-definition.scss +2 -0
- package/styles/drop-down-base/_fluent-definition.scss +109 -0
- package/styles/drop-down-list/_fluent-definition.scss +193 -0
- package/styles/drop-down-list/icons/_bootstrap5.scss +0 -1
- package/styles/drop-down-list/icons/_fluent.scss +14 -0
- package/styles/drop-down-tree/_bootstrap5-definition.scss +59 -58
- package/styles/drop-down-tree/_fluent-definition.scss +71 -0
- package/styles/drop-down-tree/_layout.scss +12 -4
- package/styles/drop-down-tree/_tailwind-definition.scss +1 -0
- package/styles/drop-down-tree/bootstrap5-dark.css +11 -4
- package/styles/drop-down-tree/bootstrap5.css +11 -4
- package/styles/drop-down-tree/icons/_bootstrap5.scss +11 -11
- package/styles/drop-down-tree/icons/_fluent.scss +11 -0
- package/styles/drop-down-tree/icons/_tailwind-dark.scss +11 -11
- package/styles/drop-down-tree/tailwind-dark.css +1 -0
- package/styles/drop-down-tree/tailwind.css +1 -0
- package/styles/list-box/_bootstrap5-definition.scss +2 -2
- package/styles/list-box/_fluent-definition.scss +115 -0
- package/styles/list-box/_layout.scss +1 -6
- package/styles/list-box/bootstrap5-dark.css +1 -1
- package/styles/list-box/bootstrap5.css +1 -1
- package/styles/list-box/icons/_fluent.scss +25 -0
- package/styles/list-box/icons/_tailwind-dark.scss +2 -2
- package/styles/list-box/tailwind-dark.css +3 -3
- package/styles/list-box/tailwind.css +1 -1
- package/styles/material-dark.css +0 -94
- package/styles/material.css +0 -94
- package/styles/multi-select/_fluent-definition.scss +214 -0
- package/styles/multi-select/_layout.scss +0 -116
- package/styles/multi-select/_material-dark-definition.scss +0 -22
- package/styles/multi-select/_material-definition.scss +0 -22
- package/styles/multi-select/icons/_fluent.scss +27 -0
- package/styles/multi-select/material-dark.css +0 -94
- package/styles/multi-select/material.css +0 -94
- package/styles/tailwind-dark.css +4 -3
- package/styles/tailwind.css +2 -1
- package/styles/_all.scss +0 -3
|
@@ -91,7 +91,7 @@ function Search(inputVal, items, searchType, ignoreCase) {
|
|
|
91
91
|
for (var i = 0, itemsData = listItems; i < itemsData.length; i++) {
|
|
92
92
|
var item = itemsData[i];
|
|
93
93
|
var text = (ignoreCase ? item.textContent.toLocaleLowerCase() : item.textContent).replace(/^\s+|\s+$/g, '');
|
|
94
|
-
if ((searchType === 'Equal' && text === queryStr) || (searchType === 'StartsWith' && text.substr(0, strLength) === queryStr)) {
|
|
94
|
+
if ((searchType === 'Equal' && text === queryStr) || (searchType === 'StartsWith' && text.substr(0, strLength) === queryStr) || (searchType === 'EndsWith' && text.substr(text.length - queryStr.length) === queryStr) || (searchType === 'Contains' && new RegExp(queryStr, "g").test(text))) {
|
|
95
95
|
itemData.item = item;
|
|
96
96
|
itemData.index = i;
|
|
97
97
|
return { item: item, index: i };
|
|
@@ -659,6 +659,11 @@ var DropDownBase = /** @__PURE__ @class */ (function (_super) {
|
|
|
659
659
|
_this.renderGroupTemplate(ulElement);
|
|
660
660
|
}
|
|
661
661
|
_this.bindChildItems(localDataArgs.result, ulElement, fields);
|
|
662
|
+
setTimeout(function () {
|
|
663
|
+
if (_this.getModuleName() === 'multiselect' && _this.itemTemplate != null && (ulElement.childElementCount > 0 && ulElement.children[0].childElementCount > 0)) {
|
|
664
|
+
_this.updateDataList();
|
|
665
|
+
}
|
|
666
|
+
});
|
|
662
667
|
}
|
|
663
668
|
});
|
|
664
669
|
}
|
|
@@ -790,10 +795,22 @@ var DropDownBase = /** @__PURE__ @class */ (function (_super) {
|
|
|
790
795
|
var groupValue = select(this.groupTemplate, document).innerHTML.trim();
|
|
791
796
|
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
792
797
|
var tempHeaders = ListBase.renderGroupTemplate(groupValue, dataSource, this.fields.properties, headerItems, option, this);
|
|
798
|
+
//EJ2-55168- Group checkbox is not working with group template
|
|
799
|
+
if (this.isGroupChecking) {
|
|
800
|
+
for (var i = 0; i < tempHeaders.length; i++) {
|
|
801
|
+
this.notify('addItem', { module: 'CheckBoxSelection', item: tempHeaders[i] });
|
|
802
|
+
}
|
|
803
|
+
}
|
|
793
804
|
}
|
|
794
805
|
else {
|
|
795
806
|
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
796
807
|
var tempHeaders = ListBase.renderGroupTemplate(this.groupTemplate, dataSource, this.fields.properties, headerItems, option, this);
|
|
808
|
+
//EJ2-55168- Group checkbox is not working with group template
|
|
809
|
+
if (this.isGroupChecking) {
|
|
810
|
+
for (var i = 0; i < tempHeaders.length; i++) {
|
|
811
|
+
this.notify('addItem', { module: 'CheckBoxSelection', item: tempHeaders[i] });
|
|
812
|
+
}
|
|
813
|
+
}
|
|
797
814
|
}
|
|
798
815
|
this.renderReactTemplates();
|
|
799
816
|
}
|
|
@@ -2129,7 +2146,7 @@ var DropDownList = /** @__PURE__ @class */ (function (_super) {
|
|
|
2129
2146
|
if (this.isSelectFocusItem(focusEle)) {
|
|
2130
2147
|
this.setSelection(focusEle, e);
|
|
2131
2148
|
}
|
|
2132
|
-
else {
|
|
2149
|
+
else if (!isNullOrUndefined(this.liCollections)) {
|
|
2133
2150
|
var index = e.action === 'down' ? this.activeIndex + 1 : this.activeIndex - 1;
|
|
2134
2151
|
var startIndex = 0;
|
|
2135
2152
|
if (this.getModuleName() === 'autocomplete') {
|
|
@@ -4319,6 +4336,7 @@ var DropDownTree = /** @__PURE__ @class */ (function (_super) {
|
|
|
4319
4336
|
// eslint-disable-next-line
|
|
4320
4337
|
_this.selectedData = [];
|
|
4321
4338
|
_this.filterDelayTime = 300;
|
|
4339
|
+
_this.isClicked = false;
|
|
4322
4340
|
return _this;
|
|
4323
4341
|
}
|
|
4324
4342
|
/**
|
|
@@ -5290,8 +5308,10 @@ var DropDownTree = /** @__PURE__ @class */ (function (_super) {
|
|
|
5290
5308
|
}
|
|
5291
5309
|
this.checkWrapper = closest(target, '.' + CHECKBOXWRAP);
|
|
5292
5310
|
if (!isNullOrUndefined(this.checkWrapper)) {
|
|
5311
|
+
this.isClicked = true;
|
|
5293
5312
|
var checkElement = select('.' + CHECKBOXFRAME, this.checkWrapper);
|
|
5294
5313
|
this.changeState(this.checkWrapper, checkElement.classList.contains(CHECK) ? 'uncheck' : 'check', e);
|
|
5314
|
+
this.isClicked = false;
|
|
5295
5315
|
}
|
|
5296
5316
|
e.preventDefault();
|
|
5297
5317
|
};
|
|
@@ -5513,6 +5533,7 @@ var DropDownTree = /** @__PURE__ @class */ (function (_super) {
|
|
|
5513
5533
|
}
|
|
5514
5534
|
};
|
|
5515
5535
|
DropDownTree.prototype.setValidValue = function () {
|
|
5536
|
+
var _this = this;
|
|
5516
5537
|
if (!this.showCheckBox && !this.allowMultiSelection) {
|
|
5517
5538
|
Input.setValue(this.text, this.inputEle, this.floatLabelType);
|
|
5518
5539
|
var id = this.value[0].toString();
|
|
@@ -5522,9 +5543,14 @@ var DropDownTree = /** @__PURE__ @class */ (function (_super) {
|
|
|
5522
5543
|
}
|
|
5523
5544
|
else {
|
|
5524
5545
|
if (this.showCheckBox) {
|
|
5525
|
-
|
|
5526
|
-
|
|
5527
|
-
|
|
5546
|
+
var difference = this.value.filter(function (e) {
|
|
5547
|
+
return _this.treeObj.checkedNodes.indexOf(e) === -1;
|
|
5548
|
+
});
|
|
5549
|
+
if (difference.length > 0 || this.treeSettings.autoCheck) {
|
|
5550
|
+
this.treeObj.checkedNodes = this.value.slice();
|
|
5551
|
+
this.treeObj.dataBind();
|
|
5552
|
+
this.setMultiSelect();
|
|
5553
|
+
}
|
|
5528
5554
|
}
|
|
5529
5555
|
else {
|
|
5530
5556
|
this.treeObj.selectedNodes = this.value.slice();
|
|
@@ -5990,7 +6016,7 @@ var DropDownTree = /** @__PURE__ @class */ (function (_super) {
|
|
|
5990
6016
|
}
|
|
5991
6017
|
var eventArgs = {
|
|
5992
6018
|
action: this.showCheckBox ? state : args.action,
|
|
5993
|
-
isInteracted: args.isInteracted,
|
|
6019
|
+
isInteracted: this.isClicked ? true : args.isInteracted,
|
|
5994
6020
|
item: args.node,
|
|
5995
6021
|
itemData: this.showCheckBox ? checkData[0] : selectData
|
|
5996
6022
|
};
|
|
@@ -6061,6 +6087,7 @@ var DropDownTree = /** @__PURE__ @class */ (function (_super) {
|
|
|
6061
6087
|
}
|
|
6062
6088
|
var target = args.event.target;
|
|
6063
6089
|
if ((target.classList.contains('e-fullrow') || target.classList.contains('e-list-text')) && this.showCheckBox) {
|
|
6090
|
+
this.isClicked = true;
|
|
6064
6091
|
// eslint-disable-next-line
|
|
6065
6092
|
var getNodeDetails = this.treeObj.getNode(args.node);
|
|
6066
6093
|
if (getNodeDetails.isChecked === 'true') {
|
|
@@ -6069,6 +6096,7 @@ var DropDownTree = /** @__PURE__ @class */ (function (_super) {
|
|
|
6069
6096
|
else {
|
|
6070
6097
|
this.treeObj.checkAll([args.node]);
|
|
6071
6098
|
}
|
|
6099
|
+
this.isClicked = false;
|
|
6072
6100
|
this.setMultiSelect();
|
|
6073
6101
|
this.ensurePlaceHolder();
|
|
6074
6102
|
}
|
|
@@ -6560,6 +6588,9 @@ var DropDownTree = /** @__PURE__ @class */ (function (_super) {
|
|
|
6560
6588
|
this.ensurePlaceHolder();
|
|
6561
6589
|
};
|
|
6562
6590
|
DropDownTree.prototype.resetValue = function (isDynamicChange) {
|
|
6591
|
+
if (this.value == [] && this.text == null) {
|
|
6592
|
+
return;
|
|
6593
|
+
}
|
|
6563
6594
|
Input.setValue(null, this.inputEle, this.floatLabelType);
|
|
6564
6595
|
if (!isDynamicChange) {
|
|
6565
6596
|
this.oldValue = this.value;
|
|
@@ -6571,7 +6602,8 @@ var DropDownTree = /** @__PURE__ @class */ (function (_super) {
|
|
|
6571
6602
|
setValue('selectedNodes', [], this.treeObj);
|
|
6572
6603
|
this.hiddenElement.innerHTML = '';
|
|
6573
6604
|
if (this.showCheckBox) {
|
|
6574
|
-
this.treeObj.
|
|
6605
|
+
this.treeObj.checkedNodes = [];
|
|
6606
|
+
this.treeObj.dataBind();
|
|
6575
6607
|
this.setMultiSelect();
|
|
6576
6608
|
this.clearCheckAll();
|
|
6577
6609
|
}
|
|
@@ -6949,8 +6981,8 @@ var DropDownTree = /** @__PURE__ @class */ (function (_super) {
|
|
|
6949
6981
|
this.updateTemplate();
|
|
6950
6982
|
}
|
|
6951
6983
|
this.treeObj.sortOrder = newProp.sortOrder;
|
|
6952
|
-
this.updateValue(this.value);
|
|
6953
6984
|
this.treeObj.dataBind();
|
|
6985
|
+
this.updateValue(this.value);
|
|
6954
6986
|
break;
|
|
6955
6987
|
case 'showDropDownIcon':
|
|
6956
6988
|
this.updateDropDownIconState(newProp.showDropDownIcon);
|
|
@@ -7532,7 +7564,7 @@ var ComboBox = /** @__PURE__ @class */ (function (_super) {
|
|
|
7532
7564
|
if ((Browser.isDevice && !this.isDropDownClick || !Browser.isDevice) &&
|
|
7533
7565
|
!isNullOrUndefined(this.liCollections) && this.liCollections.length > 0) {
|
|
7534
7566
|
var inputValue = this.inputElement.value;
|
|
7535
|
-
var activeItem = Search(inputValue, this.liCollections,
|
|
7567
|
+
var activeItem = Search(inputValue, this.liCollections, this.filterType, true);
|
|
7536
7568
|
var activeElement = activeItem.item;
|
|
7537
7569
|
if (!isNullOrUndefined(activeElement)) {
|
|
7538
7570
|
var count = this.getIndexByValue(activeElement.getAttribute('data-value')) - 1;
|
|
@@ -7689,7 +7721,7 @@ var ComboBox = /** @__PURE__ @class */ (function (_super) {
|
|
|
7689
7721
|
else {
|
|
7690
7722
|
this.activeIndex = null;
|
|
7691
7723
|
this.removeSelection();
|
|
7692
|
-
if (this.liCollections && this.liCollections.length
|
|
7724
|
+
if (this.liCollections && this.liCollections.length > 0 && !this.isCustomFilter) {
|
|
7693
7725
|
this.removeFocus();
|
|
7694
7726
|
}
|
|
7695
7727
|
}
|
|
@@ -9117,7 +9149,7 @@ var MultiSelect = /** @__PURE__ @class */ (function (_super) {
|
|
|
9117
9149
|
this.mainData = list;
|
|
9118
9150
|
this.mainListCollection = this.liCollections;
|
|
9119
9151
|
}
|
|
9120
|
-
else if (
|
|
9152
|
+
else if (isNullOrUndefined(this.mainData) || this.mainData.length === 0) {
|
|
9121
9153
|
this.mainData = list;
|
|
9122
9154
|
}
|
|
9123
9155
|
if ((this.remoteCustomValue || list.length <= 0) && this.allowCustomValue && this.inputFocus && this.allowFiltering &&
|
|
@@ -9511,6 +9543,18 @@ var MultiSelect = /** @__PURE__ @class */ (function (_super) {
|
|
|
9511
9543
|
}
|
|
9512
9544
|
this.inputFocus = false;
|
|
9513
9545
|
this.overAllWrapper.classList.remove(FOCUS);
|
|
9546
|
+
if (this.addTagOnBlur) {
|
|
9547
|
+
var dataChecks = this.getValueByText(this.inputElement.value, this.ignoreCase, this.ignoreAccent);
|
|
9548
|
+
var listLiElement = this.findListElement(this.list, 'li', 'data-value', dataChecks);
|
|
9549
|
+
var className = this.hideSelectedItem ? HIDE_LIST : dropDownBaseClasses.selected;
|
|
9550
|
+
var allowChipAddition = (listLiElement && !listLiElement.classList.contains(className)) ? true : false;
|
|
9551
|
+
if (allowChipAddition) {
|
|
9552
|
+
this.updateListSelection(listLiElement, eve);
|
|
9553
|
+
if (this.mode === 'Delimiter') {
|
|
9554
|
+
this.updateDelimeter(this.delimiterChar);
|
|
9555
|
+
}
|
|
9556
|
+
}
|
|
9557
|
+
}
|
|
9514
9558
|
this.refreshListItems(null);
|
|
9515
9559
|
if (this.mode !== 'Box' && this.mode !== 'CheckBox') {
|
|
9516
9560
|
this.updateDelimView();
|
|
@@ -9733,6 +9777,13 @@ var MultiSelect = /** @__PURE__ @class */ (function (_super) {
|
|
|
9733
9777
|
var focusedItem = this.list.querySelector('.' + dropDownBaseClasses.focus);
|
|
9734
9778
|
if (!isNullOrUndefined(focusedItem)) {
|
|
9735
9779
|
this.inputElement.setAttribute('aria-activedescendant', focusedItem.id);
|
|
9780
|
+
if (this.allowFiltering) {
|
|
9781
|
+
var filterInput = this.popupWrapper.querySelector('.' + FILTERINPUT);
|
|
9782
|
+
filterInput && filterInput.setAttribute('aria-activedescendant', focusedItem.id);
|
|
9783
|
+
}
|
|
9784
|
+
else if (this.mode == "CheckBox") {
|
|
9785
|
+
this.overAllWrapper.setAttribute('aria-activedescendant', focusedItem.id);
|
|
9786
|
+
}
|
|
9736
9787
|
}
|
|
9737
9788
|
};
|
|
9738
9789
|
MultiSelect.prototype.homeNavigation = function (isHome) {
|
|
@@ -9848,7 +9899,6 @@ var MultiSelect = /** @__PURE__ @class */ (function (_super) {
|
|
|
9848
9899
|
this.keyAction = true;
|
|
9849
9900
|
if (document.activeElement.classList.contains(FILTERINPUT)
|
|
9850
9901
|
|| (this.mode === 'CheckBox' && !this.allowFiltering && document.activeElement !== this.list)) {
|
|
9851
|
-
this.list.focus();
|
|
9852
9902
|
EventHandler.add(this.list, 'keydown', this.onKeyDown, this);
|
|
9853
9903
|
}
|
|
9854
9904
|
this.updateAriaAttribute();
|
|
@@ -10871,7 +10921,7 @@ var MultiSelect = /** @__PURE__ @class */ (function (_super) {
|
|
|
10871
10921
|
EventHandler.add(this.inputElement, 'input', this.onInput, this);
|
|
10872
10922
|
}
|
|
10873
10923
|
EventHandler.add(this.inputElement, 'blur', this.onBlurHandler, this);
|
|
10874
|
-
EventHandler.add(this.componentWrapper, '
|
|
10924
|
+
EventHandler.add(this.componentWrapper, 'mouseover', this.mouseIn, this);
|
|
10875
10925
|
var formElement = closest(this.inputElement, 'form');
|
|
10876
10926
|
if (formElement) {
|
|
10877
10927
|
EventHandler.add(formElement, 'reset', this.resetValueHandler, this);
|
|
@@ -11121,7 +11171,9 @@ var MultiSelect = /** @__PURE__ @class */ (function (_super) {
|
|
|
11121
11171
|
MultiSelect.prototype.updateActionCompleteData = function (li, item) {
|
|
11122
11172
|
if (this.value && this.value.indexOf(li.getAttribute('data-value')) > -1) {
|
|
11123
11173
|
this.mainList = this.ulElement;
|
|
11124
|
-
|
|
11174
|
+
if (this.hideSelectedItem) {
|
|
11175
|
+
addClass([li], HIDE_LIST);
|
|
11176
|
+
}
|
|
11125
11177
|
}
|
|
11126
11178
|
};
|
|
11127
11179
|
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
@@ -11139,7 +11191,7 @@ var MultiSelect = /** @__PURE__ @class */ (function (_super) {
|
|
|
11139
11191
|
}
|
|
11140
11192
|
};
|
|
11141
11193
|
MultiSelect.prototype.updateDataList = function () {
|
|
11142
|
-
if (this.mainList && this.ulElement && this.mainList.childElementCount < this.ulElement.childElementCount) {
|
|
11194
|
+
if (this.mainList && this.ulElement && (this.mainList.childElementCount < this.ulElement.childElementCount || ((this.ulElement.childElementCount > 0 && this.ulElement.children[0].childElementCount > 0) && (this.mainList.children[0].childElementCount < this.ulElement.children[0].childElementCount)))) {
|
|
11143
11195
|
this.mainList = this.ulElement.cloneNode ? this.ulElement.cloneNode(true) : this.ulElement;
|
|
11144
11196
|
}
|
|
11145
11197
|
};
|
|
@@ -11767,7 +11819,7 @@ var MultiSelect = /** @__PURE__ @class */ (function (_super) {
|
|
|
11767
11819
|
EventHandler.remove(formElement, 'reset', this.resetValueHandler);
|
|
11768
11820
|
}
|
|
11769
11821
|
EventHandler.remove(this.inputElement, 'blur', this.onBlurHandler);
|
|
11770
|
-
EventHandler.remove(this.componentWrapper, '
|
|
11822
|
+
EventHandler.remove(this.componentWrapper, 'mouseover', this.mouseIn);
|
|
11771
11823
|
EventHandler.remove(this.componentWrapper, 'mouseout', this.mouseOut);
|
|
11772
11824
|
EventHandler.remove(this.overAllClear, 'mousedown', this.clearAll);
|
|
11773
11825
|
EventHandler.remove(this.inputElement, 'paste', this.pasteHandler);
|
|
@@ -12185,6 +12237,25 @@ var MultiSelect = /** @__PURE__ @class */ (function (_super) {
|
|
|
12185
12237
|
}
|
|
12186
12238
|
this.renderPopup();
|
|
12187
12239
|
};
|
|
12240
|
+
MultiSelect.prototype.presentItemValue = function (ulElement) {
|
|
12241
|
+
var valuecheck = [];
|
|
12242
|
+
for (var i = 0; i < this.value.length; i++) {
|
|
12243
|
+
var checkEle = this.findListElement(((this.allowFiltering && !isNullOrUndefined(this.mainList)) ? this.mainList : ulElement), 'li', 'data-value', this.value[i]);
|
|
12244
|
+
if (!checkEle) {
|
|
12245
|
+
valuecheck.push(this.value[i]);
|
|
12246
|
+
}
|
|
12247
|
+
}
|
|
12248
|
+
return valuecheck;
|
|
12249
|
+
};
|
|
12250
|
+
|
|
12251
|
+
MultiSelect.prototype.addNonPresentItems = function (valuecheck, ulElement, list, event) {
|
|
12252
|
+
var _this = this;
|
|
12253
|
+
this.dataSource.executeQuery(this.getForQuery(valuecheck)).then(function (e) {
|
|
12254
|
+
_this.addItem(e.result, list.length);
|
|
12255
|
+
_this.updateActionList(ulElement, list, event);
|
|
12256
|
+
});
|
|
12257
|
+
};
|
|
12258
|
+
|
|
12188
12259
|
MultiSelect.prototype.updateVal = function (newProp, oldProp, prop) {
|
|
12189
12260
|
if (!this.list) {
|
|
12190
12261
|
this.onLoadSelect();
|
|
@@ -12193,31 +12264,43 @@ var MultiSelect = /** @__PURE__ @class */ (function (_super) {
|
|
|
12193
12264
|
this.onLoadSelect();
|
|
12194
12265
|
}
|
|
12195
12266
|
else {
|
|
12196
|
-
|
|
12197
|
-
|
|
12198
|
-
|
|
12199
|
-
}
|
|
12200
|
-
if (isNullOrUndefined(this.value) || this.value.length === 0) {
|
|
12201
|
-
this.tempValues = oldProp;
|
|
12202
|
-
}
|
|
12203
|
-
// eslint-disable-next-line
|
|
12204
|
-
if (this.allowCustomValue && (this.mode === 'Default' || this.mode === 'Box') && this.isReact && this.inputFocus
|
|
12205
|
-
&& this.isPopupOpen() && this.mainData !== this.listData) {
|
|
12206
|
-
var list = this.mainList.cloneNode ? this.mainList.cloneNode(true) : this.mainList;
|
|
12207
|
-
this.onActionComplete(list, this.mainData);
|
|
12208
|
-
}
|
|
12209
|
-
this.initialValueUpdate();
|
|
12210
|
-
if (this.mode !== 'Box' && !this.inputFocus) {
|
|
12211
|
-
this.updateDelimView();
|
|
12267
|
+
var valuecheck = [];
|
|
12268
|
+
if (!isNullOrUndefined(this.value) && !this.allowCustomValue) {
|
|
12269
|
+
valuecheck = this.presentItemValue(this.ulElement);
|
|
12212
12270
|
}
|
|
12213
|
-
if (!this.
|
|
12214
|
-
this.
|
|
12271
|
+
if (prop == 'value' && valuecheck.length > 0 && this.dataSource instanceof DataManager && !isNullOrUndefined(this.value)
|
|
12272
|
+
&& this.listData != null) {
|
|
12273
|
+
this.mainData = null;
|
|
12274
|
+
this.setDynValue = true;
|
|
12275
|
+
this.addNonPresentItems(valuecheck, this.ulElement, this.listData);
|
|
12215
12276
|
}
|
|
12216
|
-
|
|
12217
|
-
|
|
12218
|
-
|
|
12277
|
+
else {
|
|
12278
|
+
if (prop === 'text') {
|
|
12279
|
+
this.initialTextUpdate();
|
|
12280
|
+
newProp = this.value;
|
|
12281
|
+
}
|
|
12282
|
+
if (isNullOrUndefined(this.value) || this.value.length === 0) {
|
|
12283
|
+
this.tempValues = oldProp;
|
|
12284
|
+
}
|
|
12285
|
+
// eslint-disable-next-line
|
|
12286
|
+
if (this.allowCustomValue && (this.mode === 'Default' || this.mode === 'Box') && this.isReact && this.inputFocus
|
|
12287
|
+
&& this.isPopupOpen() && this.mainData !== this.listData) {
|
|
12288
|
+
var list = this.mainList.cloneNode ? this.mainList.cloneNode(true) : this.mainList;
|
|
12289
|
+
this.onActionComplete(list, this.mainData);
|
|
12290
|
+
}
|
|
12291
|
+
this.initialValueUpdate();
|
|
12292
|
+
if (this.mode !== 'Box' && !this.inputFocus) {
|
|
12293
|
+
this.updateDelimView();
|
|
12294
|
+
}
|
|
12295
|
+
if (!this.inputFocus) {
|
|
12296
|
+
this.refreshInputHight();
|
|
12297
|
+
}
|
|
12298
|
+
this.refreshPlaceHolder();
|
|
12299
|
+
if (this.mode !== 'CheckBox' && this.changeOnBlur) {
|
|
12300
|
+
this.updateValueState(null, newProp, oldProp);
|
|
12301
|
+
}
|
|
12302
|
+
this.checkPlaceholderSize();
|
|
12219
12303
|
}
|
|
12220
|
-
this.checkPlaceholderSize();
|
|
12221
12304
|
}
|
|
12222
12305
|
if (!this.changeOnBlur) {
|
|
12223
12306
|
this.updateValueState(null, newProp, oldProp);
|
|
@@ -12738,6 +12821,9 @@ var MultiSelect = /** @__PURE__ @class */ (function (_super) {
|
|
|
12738
12821
|
__decorate$5([
|
|
12739
12822
|
Property(true)
|
|
12740
12823
|
], MultiSelect.prototype, "openOnClick", void 0);
|
|
12824
|
+
__decorate$5([
|
|
12825
|
+
Property(false)
|
|
12826
|
+
], MultiSelect.prototype, "addTagOnBlur", void 0);
|
|
12741
12827
|
__decorate$5([
|
|
12742
12828
|
Event()
|
|
12743
12829
|
], MultiSelect.prototype, "change", void 0);
|
|
@@ -12931,7 +13017,7 @@ var CheckBoxSelection = /** @__PURE__ @class */ (function () {
|
|
|
12931
13017
|
}
|
|
12932
13018
|
if (this.parent.list.classList.contains('e-nodata') || (this.parent.listData && this.parent.listData.length <= 1 &&
|
|
12933
13019
|
!(this.parent.isDynamicDataChange)) || (this.parent.isDynamicDataChange &&
|
|
12934
|
-
|
|
13020
|
+
this.parent.listData && this.parent.listData.length <= 1)) {
|
|
12935
13021
|
this.checkAllParent.style.display = 'none';
|
|
12936
13022
|
}
|
|
12937
13023
|
else {
|
|
@@ -13727,9 +13813,6 @@ var ListBox = /** @__PURE__ @class */ (function (_super) {
|
|
|
13727
13813
|
args.items = this.getDataByValues([dragValue]);
|
|
13728
13814
|
}
|
|
13729
13815
|
this.trigger('beforeDrop', args);
|
|
13730
|
-
if (args.isDragAll !== null) {
|
|
13731
|
-
this.allowDragAll = args.isDragAll;
|
|
13732
|
-
}
|
|
13733
13816
|
};
|
|
13734
13817
|
ListBox.prototype.dragEnd = function (args) {
|
|
13735
13818
|
var _this = this;
|