@syncfusion/ej2-dropdowns 20.1.59 → 20.2.36
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 +1 -61
- 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 +106 -100
- package/dist/es6/ej2-dropdowns.es2015.js.map +1 -1
- package/dist/es6/ej2-dropdowns.es5.js +69 -63
- 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/helpers/e2e/autocomplete.js +59 -43
- package/helpers/e2e/combobox.js +62 -46
- package/helpers/e2e/dropdownlist.js +71 -55
- package/helpers/e2e/index.js +11 -9
- package/helpers/e2e/listboxHelper.js +55 -38
- package/helpers/e2e/multiselect.js +104 -88
- package/package.json +11 -11
- package/src/common/incremental-search.js +1 -1
- package/src/drop-down-base/drop-down-base-model.d.ts +1 -1
- package/src/drop-down-base/drop-down-base.d.ts +5 -1
- package/src/drop-down-base/drop-down-base.js +3 -5
- package/src/drop-down-list/drop-down-list.js +12 -14
- package/src/drop-down-tree/drop-down-tree-model.d.ts +2 -2
- package/src/drop-down-tree/drop-down-tree.js +5 -5
- package/src/list-box/list-box.d.ts +1 -0
- package/src/list-box/list-box.js +22 -13
- package/src/multi-select/multi-select-model.d.ts +1 -1
- package/src/multi-select/multi-select.d.ts +2 -1
- package/src/multi-select/multi-select.js +26 -25
- package/styles/auto-complete/_fusionnew-definition.scss +2 -0
- package/styles/auto-complete/_material3-definition.scss +2 -0
- package/styles/bootstrap-dark.css +38 -2
- package/styles/bootstrap.css +38 -2
- package/styles/bootstrap4.css +38 -2
- package/styles/bootstrap5-dark.css +38 -2
- package/styles/bootstrap5.css +38 -2
- package/styles/combo-box/_fusionnew-definition.scss +2 -0
- package/styles/combo-box/_material3-definition.scss +2 -0
- package/styles/drop-down-base/_fusionnew-definition.scss +111 -0
- package/styles/drop-down-base/_material3-definition.scss +111 -0
- package/styles/drop-down-list/_fusionnew-definition.scss +201 -0
- package/styles/drop-down-list/_material3-definition.scss +201 -0
- package/styles/drop-down-list/icons/_fusionnew.scss +14 -0
- package/styles/drop-down-list/icons/_material3.scss +14 -0
- package/styles/drop-down-tree/_fusionnew-definition.scss +60 -0
- package/styles/drop-down-tree/_material3-definition.scss +60 -0
- package/styles/drop-down-tree/icons/_fusionnew.scss +11 -0
- package/styles/drop-down-tree/icons/_material3.scss +11 -0
- package/styles/fabric-dark.css +38 -2
- package/styles/fabric.css +38 -2
- package/styles/fluent-dark.css +38 -2
- package/styles/fluent.css +38 -2
- package/styles/highcontrast-light.css +38 -2
- package/styles/highcontrast.css +38 -2
- package/styles/list-box/_bootstrap-dark-definition.scss +5 -1
- package/styles/list-box/_bootstrap-definition.scss +5 -1
- package/styles/list-box/_bootstrap4-definition.scss +5 -1
- package/styles/list-box/_bootstrap5-definition.scss +7 -0
- package/styles/list-box/_fabric-dark-definition.scss +5 -1
- package/styles/list-box/_fabric-definition.scss +5 -1
- package/styles/list-box/_fluent-definition.scss +7 -0
- package/styles/list-box/_fusionnew-definition.scss +113 -0
- package/styles/list-box/_highcontrast-definition.scss +5 -1
- package/styles/list-box/_highcontrast-light-definition.scss +5 -1
- package/styles/list-box/_layout.scss +36 -1
- package/styles/list-box/_material-dark-definition.scss +6 -2
- package/styles/list-box/_material-definition.scss +6 -2
- package/styles/list-box/_material3-definition.scss +119 -0
- package/styles/list-box/_tailwind-definition.scss +6 -0
- package/styles/list-box/_theme.scss +19 -0
- package/styles/list-box/bootstrap-dark.css +28 -2
- package/styles/list-box/bootstrap.css +38 -2
- package/styles/list-box/bootstrap4.css +38 -2
- package/styles/list-box/bootstrap5-dark.css +38 -2
- package/styles/list-box/bootstrap5.css +38 -2
- package/styles/list-box/fabric-dark.css +28 -2
- package/styles/list-box/fabric.css +38 -2
- package/styles/list-box/fluent-dark.css +38 -2
- package/styles/list-box/fluent.css +38 -2
- package/styles/list-box/highcontrast-light.css +28 -2
- package/styles/list-box/highcontrast.css +38 -2
- package/styles/list-box/icons/_fusionnew.scss +25 -0
- package/styles/list-box/icons/_material3.scss +25 -0
- package/styles/list-box/material-dark.css +30 -4
- package/styles/list-box/material.css +40 -4
- package/styles/list-box/tailwind-dark.css +38 -2
- package/styles/list-box/tailwind.css +38 -2
- package/styles/material-dark.css +40 -4
- package/styles/material.css +40 -4
- package/styles/multi-select/_fusionnew-definition.scss +219 -0
- package/styles/multi-select/_material3-definition.scss +219 -0
- package/styles/multi-select/icons/_fusionnew.scss +27 -0
- package/styles/multi-select/icons/_material3.scss +27 -0
- package/styles/tailwind-dark.css +38 -2
- package/styles/tailwind.css +38 -2
|
@@ -1,89 +1,105 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
1
|
+
var __extends = (this && this.__extends) || (function () {
|
|
2
|
+
var extendStatics = function (d, b) {
|
|
3
|
+
extendStatics = Object.setPrototypeOf ||
|
|
4
|
+
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
5
|
+
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
|
|
6
|
+
return extendStatics(d, b);
|
|
7
|
+
};
|
|
8
|
+
return function (d, b) {
|
|
9
|
+
extendStatics(d, b);
|
|
10
|
+
function __() { this.constructor = d; }
|
|
11
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
12
|
+
};
|
|
13
|
+
})();
|
|
14
|
+
define(["require", "exports", "@syncfusion/ej2-base/helpers/e2e"], function (require, exports, e2e_1) {
|
|
15
|
+
"use strict";
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
var MultiSelectHelper = (function (_super) {
|
|
18
|
+
__extends(MultiSelectHelper, _super);
|
|
19
|
+
function MultiSelectHelper(id, wrapperFn) {
|
|
20
|
+
var _this = _super.call(this) || this;
|
|
21
|
+
_this.id = id;
|
|
22
|
+
if (wrapperFn !== undefined) {
|
|
23
|
+
_this.wrapperFn = wrapperFn;
|
|
24
|
+
}
|
|
25
|
+
return _this;
|
|
10
26
|
}
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
return
|
|
87
|
-
}
|
|
88
|
-
|
|
89
|
-
|
|
27
|
+
MultiSelectHelper.prototype.selector = function (arg) {
|
|
28
|
+
return (this.wrapperFn ? this.wrapperFn(arg) : arg);
|
|
29
|
+
};
|
|
30
|
+
MultiSelectHelper.prototype.getInputElement = function () {
|
|
31
|
+
return this.selector('#' + this.id);
|
|
32
|
+
};
|
|
33
|
+
MultiSelectHelper.prototype.getPopupElement = function () {
|
|
34
|
+
return this.selector('#' + this.id + '_popup');
|
|
35
|
+
};
|
|
36
|
+
MultiSelectHelper.prototype.getListItemElement = function () {
|
|
37
|
+
return this.selector('.e-popup .e-content .e-list-parent .e-list-item');
|
|
38
|
+
};
|
|
39
|
+
MultiSelectHelper.prototype.getListGroupingElemnt = function () {
|
|
40
|
+
return this.selector('.e-popup .e-content .e-list-parent .e-list-group-item');
|
|
41
|
+
};
|
|
42
|
+
MultiSelectHelper.prototype.getInputFocusElement = function () {
|
|
43
|
+
return this.selector('.e-multiselect.e-input-group.e-input-focus');
|
|
44
|
+
};
|
|
45
|
+
MultiSelectHelper.prototype.getWrapperElement = function () {
|
|
46
|
+
return this.selector('.e-multiselect.e-input-group .e-multi-select-wrapper');
|
|
47
|
+
};
|
|
48
|
+
MultiSelectHelper.prototype.getValueElement = function () {
|
|
49
|
+
return this.selector('.e-multiselect.e-input-group .e-multi-select-wrapper .e-multi-hidden');
|
|
50
|
+
};
|
|
51
|
+
MultiSelectHelper.prototype.getDropdownBaseInputElement = function () {
|
|
52
|
+
return this.selector('.e-multiselect.e-input-group .e-multi-select-wrapper .e-dropdownbase');
|
|
53
|
+
};
|
|
54
|
+
MultiSelectHelper.prototype.getSpinnerElement = function () {
|
|
55
|
+
return this.selector('.e-multiselect.e-input-group .e-multi-select-wrapper .e-chips-close .e-spinner-pane');
|
|
56
|
+
};
|
|
57
|
+
MultiSelectHelper.prototype.getSpinnerInnerElement = function () {
|
|
58
|
+
return this.selector('.e-multiselect.e-input-group .e-multi-select-wrapper .e-chips-close .e-spinner-pane .e-spinner-inner');
|
|
59
|
+
};
|
|
60
|
+
MultiSelectHelper.prototype.getDelimValuesElement = function () {
|
|
61
|
+
return this.selector('.e-multiselect.e-input-group .e-multi-select-wrapper .e-delim-view');
|
|
62
|
+
};
|
|
63
|
+
MultiSelectHelper.prototype.getChipCollectionElement = function () {
|
|
64
|
+
return this.selector('.e-multiselect.e-input-group .e-multi-select-wrapper .e-chips-collection');
|
|
65
|
+
};
|
|
66
|
+
MultiSelectHelper.prototype.getSearcherElement = function () {
|
|
67
|
+
return this.selector('.e-multiselect.e-input-group .e-multi-select-wrapper .e-searcher');
|
|
68
|
+
};
|
|
69
|
+
MultiSelectHelper.prototype.getChipCloseElement = function () {
|
|
70
|
+
return this.selector('.e-multiselect.e-input-group .e-multi-select-wrapper .e-chips-close');
|
|
71
|
+
};
|
|
72
|
+
MultiSelectHelper.prototype.getInputGroupIconElemet = function () {
|
|
73
|
+
return this.selector('.e-multiselect.e-input-group .e-multi-select-wrapper .e-input-group-icon');
|
|
74
|
+
};
|
|
75
|
+
MultiSelectHelper.prototype.getFilterParentElement = function () {
|
|
76
|
+
return this.selector('.e-popup .e-filter-parent');
|
|
77
|
+
};
|
|
78
|
+
MultiSelectHelper.prototype.getfilterInputGroupElement = function () {
|
|
79
|
+
return this.selector('.e-popup .e-filter-parent .e-input-group');
|
|
80
|
+
};
|
|
81
|
+
MultiSelectHelper.prototype.getFilterInputElement = function () {
|
|
82
|
+
return this.selector('.e-popup .e-filter-parent .e-input-group .e-input-filter');
|
|
83
|
+
};
|
|
84
|
+
MultiSelectHelper.prototype.getFilterClearIconElement = function () {
|
|
85
|
+
return this.selector('.e-popup .e-filter-parent .e-input-group .e-clear-icon');
|
|
86
|
+
};
|
|
87
|
+
MultiSelectHelper.prototype.getSelectAllElement = function () {
|
|
88
|
+
return this.selector('.e-popup .e-selectall-parent');
|
|
89
|
+
};
|
|
90
|
+
MultiSelectHelper.prototype.getSelectionReorderElement = function () {
|
|
91
|
+
return this.selector('.e-popup .e-content .e-list-parent.e-ul.e-reorder');
|
|
92
|
+
};
|
|
93
|
+
MultiSelectHelper.prototype.getSelectionDisabledElement = function () {
|
|
94
|
+
return this.selector('.e-popup .e-content .e-list-parent .e-list-item.e-disable');
|
|
95
|
+
};
|
|
96
|
+
MultiSelectHelper.prototype.getSelectAllCheckboxElement = function () {
|
|
97
|
+
return this.selector('.e-popup .e-selectall-parent .e-checkbox-wrapper');
|
|
98
|
+
};
|
|
99
|
+
MultiSelectHelper.prototype.getListItemCheckBoxElement = function () {
|
|
100
|
+
return this.selector('.e-popup .e-content .e-list-parent .e-list-item .e-checkbox-wrapper');
|
|
101
|
+
};
|
|
102
|
+
return MultiSelectHelper;
|
|
103
|
+
}(e2e_1.TestHelper));
|
|
104
|
+
exports.MultiSelectHelper = MultiSelectHelper;
|
|
105
|
+
});
|
package/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"_from": "@syncfusion/ej2-dropdowns@*",
|
|
3
|
-
"_id": "@syncfusion/ej2-dropdowns@
|
|
3
|
+
"_id": "@syncfusion/ej2-dropdowns@18.37.4",
|
|
4
4
|
"_inBundle": false,
|
|
5
|
-
"_integrity": "sha512-
|
|
5
|
+
"_integrity": "sha512-ImC+pSQKT4ls3VGNz3udyVhLktKTuqZQdW+JlmLRRe1ZAcliTdUj7zjKmntcFRzZpvQv76KKXIKoBBAp6rR+TQ==",
|
|
6
6
|
"_location": "/@syncfusion/ej2-dropdowns",
|
|
7
7
|
"_phantomChildren": {},
|
|
8
8
|
"_requested": {
|
|
@@ -33,8 +33,8 @@
|
|
|
33
33
|
"/@syncfusion/ej2-spreadsheet",
|
|
34
34
|
"/@syncfusion/ej2-vue-dropdowns"
|
|
35
35
|
],
|
|
36
|
-
"_resolved": "http://nexus.syncfusion.com/repository/ej2-
|
|
37
|
-
"_shasum": "
|
|
36
|
+
"_resolved": "http://nexus.syncfusion.com/repository/ej2-release/@syncfusion/ej2-dropdowns/-/ej2-dropdowns-18.37.4.tgz",
|
|
37
|
+
"_shasum": "43499295a10a192983bc1112c07ca99d72d88651",
|
|
38
38
|
"_spec": "@syncfusion/ej2-dropdowns@*",
|
|
39
39
|
"_where": "/jenkins/workspace/automation_release_19.1.0.1-ZPMUBNQ6AUYH6YGEFBPVYMEQLRRW2SLD4XCZ6GATNZJFYJ3RIAOA/packages/included",
|
|
40
40
|
"author": {
|
|
@@ -42,12 +42,12 @@
|
|
|
42
42
|
},
|
|
43
43
|
"bundleDependencies": false,
|
|
44
44
|
"dependencies": {
|
|
45
|
-
"@syncfusion/ej2-base": "~20.
|
|
46
|
-
"@syncfusion/ej2-data": "~20.
|
|
47
|
-
"@syncfusion/ej2-inputs": "~20.
|
|
48
|
-
"@syncfusion/ej2-lists": "~20.
|
|
49
|
-
"@syncfusion/ej2-navigations": "~20.
|
|
50
|
-
"@syncfusion/ej2-popups": "~20.
|
|
45
|
+
"@syncfusion/ej2-base": "~20.2.36",
|
|
46
|
+
"@syncfusion/ej2-data": "~20.2.36",
|
|
47
|
+
"@syncfusion/ej2-inputs": "~20.2.36",
|
|
48
|
+
"@syncfusion/ej2-lists": "~20.2.36",
|
|
49
|
+
"@syncfusion/ej2-navigations": "~20.2.36",
|
|
50
|
+
"@syncfusion/ej2-popups": "~20.2.36"
|
|
51
51
|
},
|
|
52
52
|
"deprecated": false,
|
|
53
53
|
"description": "Essential JS 2 DropDown Components",
|
|
@@ -72,6 +72,6 @@
|
|
|
72
72
|
"module": "./index.js",
|
|
73
73
|
"name": "@syncfusion/ej2-dropdowns",
|
|
74
74
|
"typings": "index.d.ts",
|
|
75
|
-
"version": "20.
|
|
75
|
+
"version": "20.2.36",
|
|
76
76
|
"sideEffects": false
|
|
77
77
|
}
|
|
@@ -84,7 +84,7 @@ export function Search(inputVal, items, searchType, ignoreCase) {
|
|
|
84
84
|
for (var i = 0, itemsData = listItems; i < itemsData.length; i++) {
|
|
85
85
|
var item = itemsData[i];
|
|
86
86
|
var text = (ignoreCase ? item.textContent.toLocaleLowerCase() : item.textContent).replace(/^\s+|\s+$/g, '');
|
|
87
|
-
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,
|
|
87
|
+
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))) {
|
|
88
88
|
itemData.item = item;
|
|
89
89
|
itemData.index = i;
|
|
90
90
|
return { item: item, index: i };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Component, EventHandler, addClass, append, Property, Event, KeyboardEvents, EmitType, L10n, compile } from '@syncfusion/ej2-base';import { setStyleAttribute, extend, removeClass, prepend, isNullOrUndefined, detach, getValue, AnimationModel } from '@syncfusion/ej2-base';import { NotifyPropertyChanges, INotifyPropertyChanged, rippleEffect, RippleOptions, ChildProperty, Complex } from '@syncfusion/ej2-base';import { DataManager, Query, DataOptions, DataUtil } from '@syncfusion/ej2-data';import { ListBase, SortOrder } from '@syncfusion/ej2-lists';import { Popup } from '@syncfusion/ej2-popups';import { remove, select, selectAll } from '@syncfusion/ej2-base';
|
|
1
|
+
import { Component, EventHandler, addClass, append, Property, Event, KeyboardEvents, EmitType, L10n, compile, KeyboardEventArgs } from '@syncfusion/ej2-base';import { setStyleAttribute, extend, removeClass, prepend, isNullOrUndefined, detach, getValue, AnimationModel } from '@syncfusion/ej2-base';import { NotifyPropertyChanges, INotifyPropertyChanged, rippleEffect, RippleOptions, ChildProperty, Complex } from '@syncfusion/ej2-base';import { DataManager, Query, DataOptions, DataUtil } from '@syncfusion/ej2-data';import { ListBase, SortOrder } from '@syncfusion/ej2-lists';import { Popup } from '@syncfusion/ej2-popups';import { remove, select, selectAll } from '@syncfusion/ej2-base';
|
|
2
2
|
import {FilterType,SelectEventArgs} from "./drop-down-base";
|
|
3
3
|
import {ComponentModel} from '@syncfusion/ej2-base';
|
|
4
4
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Component, KeyboardEvents, EmitType, L10n } from '@syncfusion/ej2-base';
|
|
1
|
+
import { Component, KeyboardEvents, EmitType, L10n, KeyboardEventArgs } from '@syncfusion/ej2-base';
|
|
2
2
|
import { AnimationModel } from '@syncfusion/ej2-base';
|
|
3
3
|
import { INotifyPropertyChanged, ChildProperty } from '@syncfusion/ej2-base';
|
|
4
4
|
import { DataManager, Query } from '@syncfusion/ej2-data';
|
|
@@ -720,6 +720,10 @@ export interface PopupEventArgs {
|
|
|
720
720
|
* Specifies the animation Object.
|
|
721
721
|
*/
|
|
722
722
|
animation?: AnimationModel;
|
|
723
|
+
/**
|
|
724
|
+
* Specifies the event.
|
|
725
|
+
*/
|
|
726
|
+
event?: MouseEvent | KeyboardEventArgs;
|
|
723
727
|
}
|
|
724
728
|
export interface FocusEventArgs {
|
|
725
729
|
/**
|
|
@@ -159,8 +159,7 @@ var DropDownBase = /** @class */ (function (_super) {
|
|
|
159
159
|
compareValue_1 = value;
|
|
160
160
|
dataSource.filter(function (item) {
|
|
161
161
|
var itemValue = getValue(fields.value, item);
|
|
162
|
-
if (!isNullOrUndefined(itemValue) && !isNullOrUndefined(value)
|
|
163
|
-
&& itemValue.toString() === compareValue_1.toString()) {
|
|
162
|
+
if (!isNullOrUndefined(itemValue) && !isNullOrUndefined(value) && itemValue.toString() === compareValue_1.toString()) {
|
|
164
163
|
value = getValue(fields.text, item);
|
|
165
164
|
}
|
|
166
165
|
});
|
|
@@ -586,7 +585,7 @@ var DropDownBase = /** @class */ (function (_super) {
|
|
|
586
585
|
if (this.getModuleName() === 'multiselect' && this.properties.allowCustomValue && this.fields.groupBy) {
|
|
587
586
|
for (var i = 0; i < ulElement.childElementCount; i++) {
|
|
588
587
|
if (ulElement.children[i].classList.contains('e-list-group-item')) {
|
|
589
|
-
if (isNullOrUndefined(ulElement.children[i].innerHTML) || ulElement.children[i].innerHTML
|
|
588
|
+
if (isNullOrUndefined(ulElement.children[i].innerHTML) || ulElement.children[i].innerHTML == "") {
|
|
590
589
|
addClass([ulElement.children[i]], HIDE_GROUPLIST);
|
|
591
590
|
}
|
|
592
591
|
}
|
|
@@ -1073,8 +1072,7 @@ var DropDownBase = /** @class */ (function (_super) {
|
|
|
1073
1072
|
}
|
|
1074
1073
|
if (this.itemTemplate && !isHeader) {
|
|
1075
1074
|
var itemCheck = this.templateCompiler(this.itemTemplate);
|
|
1076
|
-
var compiledString = itemCheck ?
|
|
1077
|
-
compile(select(this.itemTemplate, document).innerHTML.trim()) : compile(this.itemTemplate);
|
|
1075
|
+
var compiledString = itemCheck ? compile(select(this.itemTemplate, document).innerHTML.trim()) : compile(this.itemTemplate);
|
|
1078
1076
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
1079
1077
|
var addItemTemplate = compiledString(item, this, 'itemTemplate', this.itemTemplateId, this.isStringTemplate, null, li);
|
|
1080
1078
|
if (addItemTemplate) {
|
|
@@ -286,7 +286,7 @@ var DropDownList = /** @class */ (function (_super) {
|
|
|
286
286
|
return {
|
|
287
287
|
'aria-disabled': 'false',
|
|
288
288
|
'aria-owns': this.element.id + '_options',
|
|
289
|
-
'role': '
|
|
289
|
+
'role': 'combobox',
|
|
290
290
|
'aria-haspopup': 'true',
|
|
291
291
|
'aria-expanded': 'false',
|
|
292
292
|
'aria-activedescendant': 'null',
|
|
@@ -552,7 +552,7 @@ var DropDownList = /** @class */ (function (_super) {
|
|
|
552
552
|
}
|
|
553
553
|
else {
|
|
554
554
|
var delay = 100;
|
|
555
|
-
this.closePopup(delay);
|
|
555
|
+
this.closePopup(delay, e);
|
|
556
556
|
}
|
|
557
557
|
};
|
|
558
558
|
DropDownList.prototype.onMouseOver = function (e) {
|
|
@@ -776,7 +776,7 @@ var DropDownList = /** @class */ (function (_super) {
|
|
|
776
776
|
this.isSelectCustom = false;
|
|
777
777
|
this.onChangeEvent(e);
|
|
778
778
|
}
|
|
779
|
-
this.hidePopup();
|
|
779
|
+
this.hidePopup(e);
|
|
780
780
|
this.focusDropDown(e);
|
|
781
781
|
}
|
|
782
782
|
else {
|
|
@@ -1011,11 +1011,9 @@ var DropDownList = /** @class */ (function (_super) {
|
|
|
1011
1011
|
if (this.setValue(e)) {
|
|
1012
1012
|
return;
|
|
1013
1013
|
}
|
|
1014
|
-
|
|
1015
|
-
|
|
1016
|
-
|
|
1017
|
-
attributes(this.filterInput, { 'aria-activedescendant': this.selectedLI ? this.selectedLI.id : null });
|
|
1018
|
-
}
|
|
1014
|
+
attributes(this.targetElement(), { 'aria-activedescendant': this.selectedLI ? this.selectedLI.id : null });
|
|
1015
|
+
if (this.isFilterLayout() && this.filterInput) {
|
|
1016
|
+
attributes(this.filterInput, { 'aria-activedescendant': this.selectedLI ? this.selectedLI.id : null });
|
|
1019
1017
|
}
|
|
1020
1018
|
if ((!this.isPopupOpen && !isNullOrUndefined(li)) || (this.isPopupOpen && !isNullOrUndefined(e) &&
|
|
1021
1019
|
(e.type !== 'keydown' || e.type === 'keydown' && e.action === 'enter'))) {
|
|
@@ -1951,7 +1949,7 @@ var DropDownList = /** @class */ (function (_super) {
|
|
|
1951
1949
|
}
|
|
1952
1950
|
}
|
|
1953
1951
|
};
|
|
1954
|
-
DropDownList.prototype.closePopup = function (delay) {
|
|
1952
|
+
DropDownList.prototype.closePopup = function (delay, e) {
|
|
1955
1953
|
var _this = this;
|
|
1956
1954
|
this.isTyped = false;
|
|
1957
1955
|
if (!(this.popupObj && document.body.contains(this.popupObj.element) && this.beforePopupOpen)) {
|
|
@@ -1989,7 +1987,7 @@ var DropDownList = /** @class */ (function (_super) {
|
|
|
1989
1987
|
EventHandler.remove(this.filterInput, 'paste', this.pasteHandler);
|
|
1990
1988
|
this.filterInput = null;
|
|
1991
1989
|
}
|
|
1992
|
-
attributes(this.targetElement(), { 'aria-expanded': 'false'
|
|
1990
|
+
attributes(this.targetElement(), { 'aria-expanded': 'false' });
|
|
1993
1991
|
this.inputWrapper.container.classList.remove(dropDownListClasses.iconAnimation);
|
|
1994
1992
|
if (this.isFiltering()) {
|
|
1995
1993
|
this.actionCompleteData.isUpdated = false;
|
|
@@ -2001,7 +1999,7 @@ var DropDownList = /** @class */ (function (_super) {
|
|
|
2001
1999
|
delay: delay ? delay : 0
|
|
2002
2000
|
};
|
|
2003
2001
|
var popupInstance = this.popupObj;
|
|
2004
|
-
var eventArgs = { popup: popupInstance, cancel: false, animation: animModel };
|
|
2002
|
+
var eventArgs = { popup: popupInstance, cancel: false, animation: animModel, event: e || null };
|
|
2005
2003
|
this.trigger('close', eventArgs, function (eventArgs) {
|
|
2006
2004
|
if (!isNullOrUndefined(_this.popupObj) &&
|
|
2007
2005
|
!isNullOrUndefined(_this.popupObj.element.querySelector('.e-fixed-head'))) {
|
|
@@ -2222,7 +2220,7 @@ var DropDownList = /** @class */ (function (_super) {
|
|
|
2222
2220
|
|| (!(props.dataSource instanceof DataManager) && props.dataSource.length === 0)))) {
|
|
2223
2221
|
this.clearAll(null, props);
|
|
2224
2222
|
}
|
|
2225
|
-
if ((this.fields.groupBy && props.fields) && !this.isGroupChecking) {
|
|
2223
|
+
if ((this.fields.groupBy && props.fields) && !this.isGroupChecking && this.list) {
|
|
2226
2224
|
EventHandler.remove(this.list, 'scroll', this.setFloatingHeader);
|
|
2227
2225
|
EventHandler.add(this.list, 'scroll', this.setFloatingHeader, this);
|
|
2228
2226
|
}
|
|
@@ -2514,7 +2512,7 @@ var DropDownList = /** @class */ (function (_super) {
|
|
|
2514
2512
|
if (!this.enabled) {
|
|
2515
2513
|
return;
|
|
2516
2514
|
}
|
|
2517
|
-
if (this.isFiltering() && this.dataSource instanceof DataManager && (this.actionData.list
|
|
2515
|
+
if (this.isFiltering() && this.dataSource instanceof DataManager && (this.actionData.list != this.actionCompleteData.list) &&
|
|
2518
2516
|
this.actionData.list && this.actionData.ulElement) {
|
|
2519
2517
|
this.actionCompleteData = this.actionData;
|
|
2520
2518
|
this.onActionComplete(this.actionCompleteData.ulElement, this.actionCompleteData.list, null, true);
|
|
@@ -2576,7 +2574,7 @@ var DropDownList = /** @class */ (function (_super) {
|
|
|
2576
2574
|
this.resetSelection();
|
|
2577
2575
|
}
|
|
2578
2576
|
}
|
|
2579
|
-
this.closePopup();
|
|
2577
|
+
this.closePopup(0, e);
|
|
2580
2578
|
var dataItem = this.getItemData();
|
|
2581
2579
|
var isSelectVal = !isNullOrUndefined(this.selectedLI);
|
|
2582
2580
|
if (this.inputElement && this.inputElement.value.trim() === '' && !this.isInteracted && (this.isSelectCustom ||
|
|
@@ -172,7 +172,7 @@ export interface DropDownTreeModel extends ComponentModel{
|
|
|
172
172
|
cssClass?: string;
|
|
173
173
|
|
|
174
174
|
/**
|
|
175
|
-
* This property is used to customize the display text of the selected items in the Dropdown Tree. The given custom template is
|
|
175
|
+
* This property is used to customize the display text of the selected items in the Dropdown Tree. The given custom template is
|
|
176
176
|
* added to the input instead of the selected item text in the Dropdown Tree when the multi-selection or checkbox support is enabled.
|
|
177
177
|
*
|
|
178
178
|
* @default "${value.length} item(s) selected"
|
|
@@ -308,7 +308,7 @@ export interface DropDownTreeModel extends ComponentModel{
|
|
|
308
308
|
* * Delimiter : Selected items will be visualized in the text content.
|
|
309
309
|
* * Default : On focus in component will act in the box mode. On blur component will act in the delimiter mode.
|
|
310
310
|
* * Custom : Selected items will be visualized with the given custom template value. The given custom template
|
|
311
|
-
* is added to the input instead of the selected item text in the Dropdown Tree when the multi-selection or checkbox support is enabled.
|
|
311
|
+
* is added to the input instead of the selected item text in the Dropdown Tree when the multi-selection or checkbox support is enabled.
|
|
312
312
|
*/
|
|
313
313
|
mode?: Mode;
|
|
314
314
|
|
|
@@ -2278,7 +2278,7 @@ var DropDownTree = /** @class */ (function (_super) {
|
|
|
2278
2278
|
addClass([this.inputWrapper], SHOW_CHIP);
|
|
2279
2279
|
}
|
|
2280
2280
|
var chip = this.createElement('span', {
|
|
2281
|
-
className: CHIP
|
|
2281
|
+
className: CHIP,
|
|
2282
2282
|
});
|
|
2283
2283
|
if (!this.inputEle.classList.contains(CHIP_INPUT)) {
|
|
2284
2284
|
addClass([this.inputEle], CHIP_INPUT);
|
|
@@ -2415,7 +2415,7 @@ var DropDownTree = /** @class */ (function (_super) {
|
|
|
2415
2415
|
this.ensurePlaceHolder();
|
|
2416
2416
|
};
|
|
2417
2417
|
DropDownTree.prototype.resetValue = function (isDynamicChange) {
|
|
2418
|
-
if (this.value
|
|
2418
|
+
if (this.value == [] && this.text == null) {
|
|
2419
2419
|
return;
|
|
2420
2420
|
}
|
|
2421
2421
|
Input.setValue(null, this.inputEle, this.floatLabelType);
|
|
@@ -2797,10 +2797,10 @@ var DropDownTree = /** @class */ (function (_super) {
|
|
|
2797
2797
|
this.updateTreeSettings(newProp);
|
|
2798
2798
|
break;
|
|
2799
2799
|
case 'customTemplate':
|
|
2800
|
-
if (this.mode !==
|
|
2800
|
+
if (this.mode !== "Custom") {
|
|
2801
2801
|
return;
|
|
2802
2802
|
}
|
|
2803
|
-
this.chipCollection.innerHTML =
|
|
2803
|
+
this.chipCollection.innerHTML = "";
|
|
2804
2804
|
this.setTagValues();
|
|
2805
2805
|
break;
|
|
2806
2806
|
case 'sortOrder':
|
|
@@ -3017,7 +3017,7 @@ var DropDownTree = /** @class */ (function (_super) {
|
|
|
3017
3017
|
Property('')
|
|
3018
3018
|
], DropDownTree.prototype, "cssClass", void 0);
|
|
3019
3019
|
__decorate([
|
|
3020
|
-
Property(
|
|
3020
|
+
Property("${value.length} item(s) selected")
|
|
3021
3021
|
], DropDownTree.prototype, "customTemplate", void 0);
|
|
3022
3022
|
__decorate([
|
|
3023
3023
|
Property(',')
|
|
@@ -119,6 +119,7 @@ export declare class ListBox extends DropDownBase {
|
|
|
119
119
|
private jsonData;
|
|
120
120
|
private toolbarAction;
|
|
121
121
|
private isDataSourceUpdate;
|
|
122
|
+
private dragValue;
|
|
122
123
|
/**
|
|
123
124
|
* Sets the CSS classes to root element of this component, which helps to customize the
|
|
124
125
|
* complete styles.
|
package/src/list-box/list-box.js
CHANGED
|
@@ -134,6 +134,7 @@ var ListBox = /** @class */ (function (_super) {
|
|
|
134
134
|
};
|
|
135
135
|
ListBox.prototype.initWrapper = function () {
|
|
136
136
|
var hiddenSelect = this.createElement('select', { className: 'e-hidden-select', attrs: { 'multiple': '' } });
|
|
137
|
+
hiddenSelect.style.visibility = 'hidden';
|
|
137
138
|
this.list.classList.add('e-listbox-wrapper');
|
|
138
139
|
if (this.itemTemplate) {
|
|
139
140
|
this.list.classList.add('e-list-template');
|
|
@@ -426,10 +427,10 @@ var ListBox = /** @class */ (function (_super) {
|
|
|
426
427
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
427
428
|
var event = args.event;
|
|
428
429
|
var wrapper;
|
|
429
|
-
if (args.target && (args.target.classList.contains(
|
|
430
|
-
|| args.target.classList.contains(
|
|
431
|
-
if (args.target.classList.contains(
|
|
432
|
-
|| args.target.classList.contains(
|
|
430
|
+
if (args.target && (args.target.classList.contains("e-listbox-wrapper") || args.target.classList.contains("e-list-item")
|
|
431
|
+
|| args.target.classList.contains("e-filter-parent") || args.target.classList.contains("e-input-group"))) {
|
|
432
|
+
if (args.target.classList.contains("e-list-item") || args.target.classList.contains("e-filter-parent")
|
|
433
|
+
|| args.target.classList.contains("e-input-group")) {
|
|
433
434
|
wrapper = args.target.closest('.e-listbox-wrapper');
|
|
434
435
|
}
|
|
435
436
|
else {
|
|
@@ -462,12 +463,12 @@ var ListBox = /** @class */ (function (_super) {
|
|
|
462
463
|
}
|
|
463
464
|
};
|
|
464
465
|
ListBox.prototype.beforeDragEnd = function (args) {
|
|
465
|
-
|
|
466
|
-
if (this.value.indexOf(dragValue) > -1) {
|
|
466
|
+
this.dragValue = this.getFormattedValue(args.droppedElement.getAttribute('data-value'));
|
|
467
|
+
if (this.value.indexOf(this.dragValue) > -1) {
|
|
467
468
|
args.items = this.getDataByValues(this.value);
|
|
468
469
|
}
|
|
469
470
|
else {
|
|
470
|
-
args.items = this.getDataByValues([dragValue]);
|
|
471
|
+
args.items = this.getDataByValues([this.dragValue]);
|
|
471
472
|
}
|
|
472
473
|
this.trigger('beforeDrop', args);
|
|
473
474
|
};
|
|
@@ -484,8 +485,7 @@ var ListBox = /** @class */ (function (_super) {
|
|
|
484
485
|
var getArgs = this.getDragArgs({ target: args.droppedElement }, true);
|
|
485
486
|
var sourceArgs = { previousData: this.dataSource };
|
|
486
487
|
var destArgs = { previousData: listObj.dataSource };
|
|
487
|
-
var dragArgs = extend({}, getArgs, { target: args.target, source: { previousData: this.dataSource },
|
|
488
|
-
previousIndex: args.previousIndex, currentIndex: args.currentIndex });
|
|
488
|
+
var dragArgs = extend({}, getArgs, { target: args.target, source: { previousData: this.dataSource }, previousIndex: args.previousIndex, currentIndex: args.currentIndex });
|
|
489
489
|
if (listObj !== this) {
|
|
490
490
|
var sourceArgs1 = extend(sourceArgs, { currentData: this.listData });
|
|
491
491
|
dragArgs = extend(dragArgs, { source: sourceArgs1, destination: destArgs });
|
|
@@ -616,7 +616,7 @@ var ListBox = /** @class */ (function (_super) {
|
|
|
616
616
|
};
|
|
617
617
|
ListBox.prototype.updateListItems = function (sourceElem, destElem) {
|
|
618
618
|
var i = 0;
|
|
619
|
-
destElem.innerHTML =
|
|
619
|
+
destElem.innerHTML = "";
|
|
620
620
|
while (i < sourceElem.childNodes.length) {
|
|
621
621
|
destElem.appendChild(sourceElem.childNodes[i]);
|
|
622
622
|
}
|
|
@@ -1600,6 +1600,15 @@ var ListBox = /** @class */ (function (_super) {
|
|
|
1600
1600
|
return listObj;
|
|
1601
1601
|
};
|
|
1602
1602
|
ListBox.prototype.getGrabbedItems = function () {
|
|
1603
|
+
for (var i = 0; i < this.value.length; i++) {
|
|
1604
|
+
if (this.value[i] === this.dragValue) {
|
|
1605
|
+
var liColl = this.list.querySelectorAll('[aria-selected="true"]');
|
|
1606
|
+
for (var i_1 = 0; i_1 < liColl.length; i_1++) {
|
|
1607
|
+
liColl[i_1].classList.add('e-grabbed');
|
|
1608
|
+
}
|
|
1609
|
+
break;
|
|
1610
|
+
}
|
|
1611
|
+
}
|
|
1603
1612
|
var elems = Array.prototype.slice.call(this.element.querySelectorAll('.e-grabbed'));
|
|
1604
1613
|
return elems;
|
|
1605
1614
|
};
|
|
@@ -1656,7 +1665,7 @@ var ListBox = /** @class */ (function (_super) {
|
|
|
1656
1665
|
}
|
|
1657
1666
|
}
|
|
1658
1667
|
}
|
|
1659
|
-
else if (e.keyCode !== 37 && e.keyCode !== 39 && e.code !==
|
|
1668
|
+
else if (e.keyCode !== 37 && e.keyCode !== 39 && e.code !== "KeyA") {
|
|
1660
1669
|
this.upDownKeyHandler(e);
|
|
1661
1670
|
}
|
|
1662
1671
|
}
|
|
@@ -1700,8 +1709,8 @@ var ListBox = /** @class */ (function (_super) {
|
|
|
1700
1709
|
}
|
|
1701
1710
|
if (this.selectionSettings.showCheckbox && e.ctrlKey && e.shiftKey && (e.keyCode === 36 || e.keyCode === 35)) {
|
|
1702
1711
|
var selectedidx = Array.prototype.indexOf.call(ul.children, fli);
|
|
1703
|
-
var sidx = e.code ===
|
|
1704
|
-
var eidx = e.code ===
|
|
1712
|
+
var sidx = e.code === "Home" ? 0 : selectedidx;
|
|
1713
|
+
var eidx = e.code === "Home" ? selectedidx : ul.children.length - 1;
|
|
1705
1714
|
for (var i = sidx; i <= eidx; i++) {
|
|
1706
1715
|
var item = ul.children[i];
|
|
1707
1716
|
this.notify('updatelist', { li: item, e: {
|
|
@@ -450,7 +450,7 @@ export interface MultiSelectModel extends DropDownBaseModel{
|
|
|
450
450
|
*
|
|
451
451
|
* @default false
|
|
452
452
|
*/
|
|
453
|
-
addTagOnBlur?: boolean;
|
|
453
|
+
addTagOnBlur?: boolean;
|
|
454
454
|
|
|
455
455
|
/**
|
|
456
456
|
* Fires each time when selection changes happened in list items after model and input value get affected.
|
|
@@ -46,6 +46,7 @@ export declare class MultiSelect extends DropDownBase implements IInput {
|
|
|
46
46
|
private keyAction;
|
|
47
47
|
private isSelectAll;
|
|
48
48
|
private clearIconWidth;
|
|
49
|
+
private previousFilterText;
|
|
49
50
|
/**
|
|
50
51
|
* The `fields` property maps the columns of the data table and binds the data to the component.
|
|
51
52
|
* * text - Maps the text column from data table for each list item.
|
|
@@ -816,7 +817,7 @@ export declare class MultiSelect extends DropDownBase implements IInput {
|
|
|
816
817
|
*
|
|
817
818
|
* @returns {void}
|
|
818
819
|
*/
|
|
819
|
-
hidePopup(): void;
|
|
820
|
+
hidePopup(e?: MouseEvent | KeyboardEventArgs): void;
|
|
820
821
|
/**
|
|
821
822
|
* Shows the popup, if the popup in a closed state.
|
|
822
823
|
*
|