@syncfusion/ej2-pivotview 20.1.61 → 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 +12 -0
- package/dist/ej2-pivotview.umd.min.js +2 -2
- package/dist/ej2-pivotview.umd.min.js.map +1 -1
- package/dist/es6/ej2-pivotview.es2015.js +281 -99
- package/dist/es6/ej2-pivotview.es2015.js.map +1 -1
- package/dist/es6/ej2-pivotview.es5.js +283 -100
- package/dist/es6/ej2-pivotview.es5.js.map +1 -1
- package/dist/global/ej2-pivotview.min.js +2 -2
- package/dist/global/ej2-pivotview.min.js.map +1 -1
- package/dist/global/index.d.ts +1 -1
- package/helpers/e2e/index.js +9 -7
- package/helpers/e2e/pivotfieldlist.js +47 -31
- package/helpers/e2e/pivotview.js +68 -52
- package/package.json +22 -22
- package/src/base/engine.js +2 -2
- package/src/base/olap/engine.js +12 -0
- package/src/base/olap/mdx-query.js +1 -1
- package/src/common/actions/event-base.d.ts +4 -2
- package/src/common/actions/event-base.js +18 -10
- package/src/common/actions/field-list.js +2 -1
- package/src/common/actions/pivot-button.js +4 -4
- package/src/common/base/css-constant.d.ts +16 -0
- package/src/common/base/css-constant.js +16 -0
- package/src/common/calculatedfield/calculated-field.js +24 -15
- package/src/common/conditionalformatting/conditional-formatting.js +5 -5
- package/src/common/grouping-bar/grouping-bar.js +1 -1
- package/src/common/popups/aggregate-menu.js +4 -3
- package/src/common/popups/drillthrough-dialog.js +5 -4
- package/src/common/popups/error-dialog.js +1 -1
- package/src/common/popups/filter-dialog.js +25 -14
- package/src/common/popups/formatting-dialog.js +2 -2
- package/src/common/popups/grouping.js +14 -7
- package/src/common/popups/toolbar.js +11 -10
- package/src/pivotfieldlist/base/field-list-model.d.ts +5 -0
- package/src/pivotfieldlist/base/field-list.d.ts +4 -0
- package/src/pivotfieldlist/base/field-list.js +5 -0
- package/src/pivotfieldlist/renderer/dialog-renderer.js +17 -9
- package/src/pivotfieldlist/renderer/tree-renderer.d.ts +4 -0
- package/src/pivotfieldlist/renderer/tree-renderer.js +102 -8
- package/src/pivotview/base/pivotview-model.d.ts +7 -0
- package/src/pivotview/base/pivotview.d.ts +6 -0
- package/src/pivotview/base/pivotview.js +9 -3
- package/src/pivotview/renderer/render.js +3 -0
- package/styles/bootstrap-dark.css +165 -32
- package/styles/bootstrap.css +165 -32
- package/styles/bootstrap4.css +166 -36
- package/styles/bootstrap5-dark.css +209 -45
- package/styles/bootstrap5.css +209 -45
- package/styles/fabric-dark.css +165 -32
- package/styles/fabric.css +165 -32
- package/styles/fluent-dark.css +183 -49
- package/styles/fluent.css +183 -49
- package/styles/highcontrast-light.css +165 -32
- package/styles/highcontrast.css +165 -32
- package/styles/material-dark.css +165 -32
- package/styles/material.css +165 -32
- package/styles/pivotfieldlist/_bootstrap-dark-definition.scss +10 -0
- package/styles/pivotfieldlist/_bootstrap-definition.scss +10 -0
- package/styles/pivotfieldlist/_bootstrap4-definition.scss +11 -1
- package/styles/pivotfieldlist/_bootstrap5-definition.scss +15 -6
- package/styles/pivotfieldlist/_fabric-dark-definition.scss +10 -1
- package/styles/pivotfieldlist/_fabric-definition.scss +10 -0
- package/styles/pivotfieldlist/_fluent-definition.scss +18 -8
- package/styles/pivotfieldlist/_fusionnew-definition.scss +189 -0
- package/styles/pivotfieldlist/_highcontrast-definition.scss +10 -0
- package/styles/pivotfieldlist/_highcontrast-light-definition.scss +10 -0
- package/styles/pivotfieldlist/_layout.scss +30 -14
- package/styles/pivotfieldlist/_material-dark-definition.scss +10 -0
- package/styles/pivotfieldlist/_material-definition.scss +10 -0
- package/styles/pivotfieldlist/_material3-definition.scss +189 -0
- package/styles/pivotfieldlist/_tailwind-definition.scss +19 -10
- package/styles/pivotfieldlist/_theme.scss +142 -7
- package/styles/pivotfieldlist/bootstrap-dark.css +146 -10
- package/styles/pivotfieldlist/bootstrap.css +146 -10
- package/styles/pivotfieldlist/bootstrap4.css +147 -11
- package/styles/pivotfieldlist/bootstrap5-dark.css +151 -15
- package/styles/pivotfieldlist/bootstrap5.css +151 -15
- package/styles/pivotfieldlist/fabric-dark.css +146 -10
- package/styles/pivotfieldlist/fabric.css +146 -10
- package/styles/pivotfieldlist/fluent-dark.css +154 -18
- package/styles/pivotfieldlist/fluent.css +154 -18
- package/styles/pivotfieldlist/highcontrast-light.css +146 -10
- package/styles/pivotfieldlist/highcontrast.css +146 -10
- package/styles/pivotfieldlist/icons/_bootstrap-dark.scss +5 -0
- package/styles/pivotfieldlist/icons/_bootstrap.scss +5 -0
- package/styles/pivotfieldlist/icons/_bootstrap4.scss +5 -0
- package/styles/pivotfieldlist/icons/_bootstrap5.scss +5 -0
- package/styles/pivotfieldlist/icons/_fabric-dark.scss +5 -0
- package/styles/pivotfieldlist/icons/_fabric.scss +5 -0
- package/styles/pivotfieldlist/icons/_fluent.scss +5 -0
- package/styles/pivotfieldlist/icons/_fusionnew.scss +352 -0
- package/styles/pivotfieldlist/icons/_highcontrast-light.scss +5 -0
- package/styles/pivotfieldlist/icons/_highcontrast.scss +5 -0
- package/styles/pivotfieldlist/icons/_material-dark.scss +5 -0
- package/styles/pivotfieldlist/icons/_material.scss +4 -0
- package/styles/pivotfieldlist/icons/_material3.scss +352 -0
- package/styles/pivotfieldlist/icons/_tailwind-dark.scss +4 -0
- package/styles/pivotfieldlist/icons/_tailwind.scss +4 -0
- package/styles/pivotfieldlist/material-dark.css +146 -10
- package/styles/pivotfieldlist/material.css +146 -10
- package/styles/pivotfieldlist/tailwind-dark.css +155 -21
- package/styles/pivotfieldlist/tailwind.css +156 -21
- package/styles/pivotview/_bootstrap-dark-definition.scss +4 -2
- package/styles/pivotview/_bootstrap-definition.scss +4 -2
- package/styles/pivotview/_bootstrap4-definition.scss +4 -2
- package/styles/pivotview/_bootstrap5-definition.scss +9 -8
- package/styles/pivotview/_fabric-dark-definition.scss +4 -1
- package/styles/pivotview/_fabric-definition.scss +4 -2
- package/styles/pivotview/_fluent-definition.scss +11 -9
- package/styles/pivotview/_fusionnew-definition.scss +131 -0
- package/styles/pivotview/_highcontrast-definition.scss +4 -2
- package/styles/pivotview/_highcontrast-light-definition.scss +4 -2
- package/styles/pivotview/_layout.scss +3 -17
- package/styles/pivotview/_material-dark-definition.scss +4 -1
- package/styles/pivotview/_material-definition.scss +4 -2
- package/styles/pivotview/_material3-definition.scss +131 -0
- package/styles/pivotview/_tailwind-definition.scss +8 -5
- package/styles/pivotview/_theme.scss +47 -27
- package/styles/pivotview/bootstrap-dark.css +19 -22
- package/styles/pivotview/bootstrap.css +19 -22
- package/styles/pivotview/bootstrap4.css +19 -25
- package/styles/pivotview/bootstrap5-dark.css +58 -30
- package/styles/pivotview/bootstrap5.css +58 -30
- package/styles/pivotview/fabric-dark.css +19 -22
- package/styles/pivotview/fabric.css +19 -22
- package/styles/pivotview/fluent-dark.css +29 -31
- package/styles/pivotview/fluent.css +29 -31
- package/styles/pivotview/highcontrast-light.css +19 -22
- package/styles/pivotview/highcontrast.css +19 -22
- package/styles/pivotview/icons/_fusionnew.scss +183 -0
- package/styles/pivotview/icons/_material3.scss +183 -0
- package/styles/pivotview/material-dark.css +19 -22
- package/styles/pivotview/material.css +19 -22
- package/styles/pivotview/tailwind-dark.css +27 -31
- package/styles/pivotview/tailwind.css +27 -31
- package/styles/tailwind-dark.css +182 -52
- package/styles/tailwind.css +183 -52
|
@@ -43,6 +43,12 @@ var DialogRenderer = /** @class */ (function () {
|
|
|
43
43
|
if (this.parent.cssClass) {
|
|
44
44
|
addClass([fieldListWrappper], this.parent.cssClass);
|
|
45
45
|
}
|
|
46
|
+
if (this.parent.enableFieldSearching) {
|
|
47
|
+
addClass([fieldListWrappper], cls.FIELD_LIST_SEARCH_MODE_CLASS);
|
|
48
|
+
}
|
|
49
|
+
else {
|
|
50
|
+
removeClass([fieldListWrappper], cls.FIELD_LIST_SEARCH_MODE_CLASS);
|
|
51
|
+
}
|
|
46
52
|
this.parentElement = createElement('div', { className: cls.CONTAINER_CLASS });
|
|
47
53
|
this.parent.element.appendChild(fieldListWrappper);
|
|
48
54
|
if (this.parent.isAdaptive) {
|
|
@@ -87,13 +93,14 @@ var DialogRenderer = /** @class */ (function () {
|
|
|
87
93
|
checked: true,
|
|
88
94
|
enableRtl: this.parent.enableRtl,
|
|
89
95
|
locale: this.parent.locale,
|
|
90
|
-
change: this.onCheckChange.bind(this)
|
|
96
|
+
change: this.onCheckChange.bind(this),
|
|
97
|
+
cssClass: this.parent.cssClass
|
|
91
98
|
});
|
|
92
99
|
this.deferUpdateCheckBox.isStringTemplate = true;
|
|
93
100
|
this.deferUpdateCheckBox.appendTo('#' + this.parent.element.id + 'DeferUpdateCheckBox');
|
|
94
101
|
this.deferUpdateApplyButton = new Button({
|
|
95
102
|
cssClass: cls.DEFER_APPLY_BUTTON + ' ' + cls.DEFER_UPDATE_BUTTON + (this.parent.renderMode === 'Popup' ?
|
|
96
|
-
(' ' + cls.BUTTON_FLAT_CLASS) : ''),
|
|
103
|
+
(' ' + cls.BUTTON_FLAT_CLASS) : '') + (this.parent.cssClass ? (' ' + this.parent.cssClass) : ''),
|
|
97
104
|
content: this.parent.localeObj.getConstant('apply'),
|
|
98
105
|
enableRtl: this.parent.enableRtl,
|
|
99
106
|
locale: this.parent.locale,
|
|
@@ -106,7 +113,7 @@ var DialogRenderer = /** @class */ (function () {
|
|
|
106
113
|
}
|
|
107
114
|
this.deferUpdateCancelButton = new Button({
|
|
108
115
|
cssClass: cls.DEFER_CANCEL_BUTTON + ' ' + cls.CANCEL_BUTTON_CLASS + (this.parent.renderMode === 'Popup' ?
|
|
109
|
-
(' ' + cls.BUTTON_FLAT_CLASS) : ''),
|
|
116
|
+
(' ' + cls.BUTTON_FLAT_CLASS) : '') + (this.parent.cssClass ? (' ' + this.parent.cssClass) : ''),
|
|
110
117
|
content: this.parent.allowDeferLayoutUpdate ? this.parent.localeObj.getConstant('cancel') :
|
|
111
118
|
this.parent.localeObj.getConstant('close'),
|
|
112
119
|
enableRtl: this.parent.enableRtl, isPrimary: !this.parent.allowDeferLayoutUpdate, locale: this.parent.locale
|
|
@@ -224,7 +231,7 @@ var DialogRenderer = /** @class */ (function () {
|
|
|
224
231
|
var buttons = [{
|
|
225
232
|
click: this.showFieldListDialog.bind(this),
|
|
226
233
|
buttonModel: {
|
|
227
|
-
cssClass: cls.ADAPTIVE_FIELD_LIST_BUTTON_CLASS + ' ' + cls.BUTTON_SMALL_CLASS + ' ' + cls.BUTTON_ROUND_CLASS,
|
|
234
|
+
cssClass: cls.ADAPTIVE_FIELD_LIST_BUTTON_CLASS + ' ' + cls.BUTTON_SMALL_CLASS + ' ' + cls.BUTTON_ROUND_CLASS + (this.parent.cssClass ? (' ' + this.parent.cssClass) : ''),
|
|
228
235
|
iconCss: cls.ICON + ' ' + cls.ADD_ICON_CLASS,
|
|
229
236
|
isPrimary: true
|
|
230
237
|
}
|
|
@@ -232,7 +239,7 @@ var DialogRenderer = /** @class */ (function () {
|
|
|
232
239
|
click: this.showCalculatedField.bind(this),
|
|
233
240
|
buttonModel: {
|
|
234
241
|
cssClass: cls.ADAPTIVE_CALCULATED_FIELD_BUTTON_CLASS +
|
|
235
|
-
' ' + cls.BUTTON_SMALL_CLASS + ' ' + cls.BUTTON_ROUND_CLASS + ' ' + cls.ICON_DISABLE,
|
|
242
|
+
' ' + cls.BUTTON_SMALL_CLASS + ' ' + cls.BUTTON_ROUND_CLASS + ' ' + cls.ICON_DISABLE + (this.parent.cssClass ? (' ' + this.parent.cssClass) : ''),
|
|
236
243
|
iconCss: cls.ICON + ' ' + cls.ADD_ICON_CLASS, enableRtl: this.parent.enableRtl,
|
|
237
244
|
isPrimary: true
|
|
238
245
|
}
|
|
@@ -370,7 +377,8 @@ var DialogRenderer = /** @class */ (function () {
|
|
|
370
377
|
height: '100%',
|
|
371
378
|
enableRtl: this.parent.enableRtl,
|
|
372
379
|
locale: this.parent.locale,
|
|
373
|
-
selected: this.tabSelect.bind(this)
|
|
380
|
+
selected: this.tabSelect.bind(this),
|
|
381
|
+
cssClass: this.parent.cssClass
|
|
374
382
|
});
|
|
375
383
|
if (this.parent.renderMode === 'Fixed') {
|
|
376
384
|
layoutFooter.appendChild(this.createAddButton());
|
|
@@ -416,7 +424,7 @@ var DialogRenderer = /** @class */ (function () {
|
|
|
416
424
|
}
|
|
417
425
|
});
|
|
418
426
|
var calculateField = new Button({
|
|
419
|
-
cssClass: cls.CALCULATED_FIELD_CLASS + ' ' + cls.ICON_DISABLE,
|
|
427
|
+
cssClass: cls.CALCULATED_FIELD_CLASS + ' ' + cls.ICON_DISABLE + (this.parent.cssClass ? (' ' + this.parent.cssClass) : ''),
|
|
420
428
|
content: this.parent.localeObj.getConstant('CalculatedField'),
|
|
421
429
|
enableRtl: this.parent.enableRtl, locale: this.parent.locale
|
|
422
430
|
});
|
|
@@ -436,12 +444,12 @@ var DialogRenderer = /** @class */ (function () {
|
|
|
436
444
|
var calculatedButton = createElement('div', {});
|
|
437
445
|
var calculateField = new Button({
|
|
438
446
|
cssClass: cls.ADAPTIVE_CALCULATED_FIELD_BUTTON_CLASS +
|
|
439
|
-
' ' + cls.BUTTON_SMALL_CLASS + ' ' + cls.BUTTON_ROUND_CLASS + ' ' + cls.ICON_DISABLE,
|
|
447
|
+
' ' + cls.BUTTON_SMALL_CLASS + ' ' + cls.BUTTON_ROUND_CLASS + ' ' + cls.ICON_DISABLE + (this.parent.cssClass ? (' ' + this.parent.cssClass) : ''),
|
|
440
448
|
iconCss: cls.ICON + ' ' + cls.ADD_ICON_CLASS,
|
|
441
449
|
enableRtl: this.parent.enableRtl, locale: this.parent.locale
|
|
442
450
|
});
|
|
443
451
|
var fieldList = new Button({
|
|
444
|
-
cssClass: cls.ADAPTIVE_FIELD_LIST_BUTTON_CLASS + ' ' + cls.BUTTON_SMALL_CLASS + ' ' + cls.BUTTON_ROUND_CLASS,
|
|
452
|
+
cssClass: cls.ADAPTIVE_FIELD_LIST_BUTTON_CLASS + ' ' + cls.BUTTON_SMALL_CLASS + ' ' + cls.BUTTON_ROUND_CLASS + (this.parent.cssClass ? (' ' + this.parent.cssClass) : ''),
|
|
445
453
|
iconCss: cls.ICON + ' ' + cls.ADD_ICON_CLASS,
|
|
446
454
|
enableRtl: this.parent.enableRtl, locale: this.parent.locale
|
|
447
455
|
});
|
|
@@ -15,6 +15,10 @@ export declare class TreeViewRenderer implements IAction {
|
|
|
15
15
|
private editorSearch;
|
|
16
16
|
private selectedNodes;
|
|
17
17
|
private fieldListSort;
|
|
18
|
+
private fieldSearch;
|
|
19
|
+
private nonSearchList;
|
|
20
|
+
private isSearching;
|
|
21
|
+
private parentIDs;
|
|
18
22
|
/** Constructor for render module
|
|
19
23
|
* @param {PivotFieldList} parent - Instance of field list.
|
|
20
24
|
*/
|
|
@@ -4,7 +4,7 @@ import * as cls from '../../common/base/css-constant';
|
|
|
4
4
|
import * as events from '../../common/base/constant';
|
|
5
5
|
import { TreeView } from '@syncfusion/ej2-navigations';
|
|
6
6
|
import { Dialog } from '@syncfusion/ej2-popups';
|
|
7
|
-
import { MaskedTextBox } from '@syncfusion/ej2-inputs';
|
|
7
|
+
import { MaskedTextBox, TextBox } from '@syncfusion/ej2-inputs';
|
|
8
8
|
import { PivotUtil } from '../../base/util';
|
|
9
9
|
/**
|
|
10
10
|
* Module to render Field List
|
|
@@ -16,6 +16,8 @@ var TreeViewRenderer = /** @class */ (function () {
|
|
|
16
16
|
*/
|
|
17
17
|
function TreeViewRenderer(parent) {
|
|
18
18
|
this.selectedNodes = [];
|
|
19
|
+
this.isSearching = false;
|
|
20
|
+
this.parentIDs = [];
|
|
19
21
|
this.parent = parent;
|
|
20
22
|
this.addEventListener();
|
|
21
23
|
}
|
|
@@ -36,15 +38,42 @@ var TreeViewRenderer = /** @class */ (function () {
|
|
|
36
38
|
className: cls.FIELD_HEADER_CLASS,
|
|
37
39
|
innerHTML: this.parent.localeObj.getConstant('allFields')
|
|
38
40
|
});
|
|
39
|
-
var
|
|
41
|
+
var searchWrapper = createElement('div', {
|
|
42
|
+
id: this.parent.element.id + '_SearchDiv', attrs: { 'tabindex': '-1' },
|
|
43
|
+
className: cls.FIELD_LIST_SEARCH_CLASS
|
|
44
|
+
});
|
|
45
|
+
var searchInput = createElement('input', { attrs: { 'type': 'text' } });
|
|
46
|
+
searchWrapper.appendChild(searchInput);
|
|
47
|
+
this.fieldSearch = new TextBox({
|
|
48
|
+
placeholder: this.parent.localeObj.getConstant('search'),
|
|
49
|
+
enableRtl: this.parent.enableRtl,
|
|
50
|
+
locale: this.parent.locale,
|
|
51
|
+
cssClass: cls.FIELD_LIST_SEARCH_INPUT_CLASS + (this.parent.cssClass ? (' ' + this.parent.cssClass) : ''),
|
|
52
|
+
input: this.textChange.bind(this),
|
|
53
|
+
showClearButton: true
|
|
54
|
+
});
|
|
55
|
+
this.fieldSearch.isStringTemplate = true;
|
|
56
|
+
this.fieldSearch.appendTo(searchInput);
|
|
57
|
+
this.fieldSearch.addIcon('append', cls.FIELD_LIST_SEARCH_ICON_CLASS + ' ' + cls.ICON);
|
|
58
|
+
var promptDiv = createElement('div', {
|
|
59
|
+
className: cls.EMPTY_MEMBER_CLASS + ' ' + cls.ICON_DISABLE,
|
|
60
|
+
innerHTML: this.parent.localeObj.getConstant('noMatches')
|
|
61
|
+
});
|
|
62
|
+
var treeOuterDiv = createElement('div', {
|
|
63
|
+
className: cls.FIELD_LIST_TREE_OUTER_DIV_CLASS + ' ' + cls.TREE_CONTAINER
|
|
64
|
+
});
|
|
40
65
|
this.treeViewElement = createElement('div', {
|
|
41
66
|
id: this.parent.element.id + '_TreeView',
|
|
42
67
|
className: cls.FIELD_LIST_CLASS + ' ' + (this.parent.dataType === 'olap' ? cls.OLAP_FIELD_LIST_CLASS : '')
|
|
43
68
|
});
|
|
44
|
-
var fieldHeaderWrappper = createElement('div', { className:
|
|
69
|
+
var fieldHeaderWrappper = createElement('div', { className: cls.FIELD_HEADER_CONTAINER_CLASS });
|
|
45
70
|
fieldHeaderWrappper.appendChild(treeHeader);
|
|
46
71
|
fieldTable.appendChild(fieldHeaderWrappper);
|
|
47
72
|
this.updateSortElements(fieldHeaderWrappper);
|
|
73
|
+
if (this.parent.enableFieldSearching) {
|
|
74
|
+
fieldTable.appendChild(searchWrapper);
|
|
75
|
+
fieldTable.appendChild(promptDiv);
|
|
76
|
+
}
|
|
48
77
|
treeOuterDiv.appendChild(this.treeViewElement);
|
|
49
78
|
fieldTable.appendChild(treeOuterDiv);
|
|
50
79
|
this.parentElement.appendChild(fieldTable);
|
|
@@ -168,6 +197,40 @@ var TreeViewRenderer = /** @class */ (function () {
|
|
|
168
197
|
if (args.node.querySelector('.' + cls.NODE_CHECK_CLASS)) {
|
|
169
198
|
addClass([args.node.querySelector('.' + cls.LIST_TEXT_CLASS)], cls.LIST_SELECT_CLASS);
|
|
170
199
|
}
|
|
200
|
+
if (this.parent.enableFieldSearching && this.isSearching) {
|
|
201
|
+
var liElement = args.node;
|
|
202
|
+
if (this.parent.dataType === 'olap') {
|
|
203
|
+
var id = liElement.getAttribute('data-uid');
|
|
204
|
+
var searchItem = this.parent.pivotCommon.eventBase.searchListItem;
|
|
205
|
+
for (var i = 0; i < this.parentIDs.length; i++) {
|
|
206
|
+
if (id === this.parentIDs[i]) {
|
|
207
|
+
addClass([liElement], cls.ICON_DISABLE);
|
|
208
|
+
}
|
|
209
|
+
for (var _i = 0, searchItem_1 = searchItem; _i < searchItem_1.length; _i++) {
|
|
210
|
+
var li2 = searchItem_1[_i];
|
|
211
|
+
var parentID = this.parent.pivotCommon.eventBase.getParentIDs(this.fieldTable, li2.getAttribute('data-uid'), []);
|
|
212
|
+
if (PivotUtil.inArray(id, parentID) > -1) {
|
|
213
|
+
removeClass([liElement], cls.ICON_DISABLE);
|
|
214
|
+
break;
|
|
215
|
+
}
|
|
216
|
+
}
|
|
217
|
+
}
|
|
218
|
+
}
|
|
219
|
+
else {
|
|
220
|
+
for (var i = 0; i < this.nonSearchList.length; i++) {
|
|
221
|
+
if (liElement.textContent === this.nonSearchList[i].textContent) {
|
|
222
|
+
addClass([liElement], cls.ICON_DISABLE);
|
|
223
|
+
break;
|
|
224
|
+
}
|
|
225
|
+
else {
|
|
226
|
+
if (liElement.innerText === this.nonSearchList[i].textContent) {
|
|
227
|
+
addClass([liElement], cls.ICON_DISABLE);
|
|
228
|
+
break;
|
|
229
|
+
}
|
|
230
|
+
}
|
|
231
|
+
}
|
|
232
|
+
}
|
|
233
|
+
}
|
|
171
234
|
};
|
|
172
235
|
TreeViewRenderer.prototype.updateOlapTreeNode = function (args) {
|
|
173
236
|
var allowDrag = false;
|
|
@@ -223,12 +286,12 @@ var TreeViewRenderer = /** @class */ (function () {
|
|
|
223
286
|
buttons: [{
|
|
224
287
|
click: this.closeTreeDialog.bind(this),
|
|
225
288
|
buttonModel: {
|
|
226
|
-
cssClass: cls.CANCEL_BUTTON_CLASS, content: this.parent.localeObj.getConstant('cancel')
|
|
289
|
+
cssClass: cls.CANCEL_BUTTON_CLASS + (this.parent.cssClass ? (' ' + this.parent.cssClass) : ''), content: this.parent.localeObj.getConstant('cancel')
|
|
227
290
|
}
|
|
228
291
|
}, {
|
|
229
292
|
click: this.onFieldAdd.bind(this),
|
|
230
293
|
buttonModel: {
|
|
231
|
-
cssClass: cls.OK_BUTTON_CLASS, content: this.parent.localeObj.getConstant('add'),
|
|
294
|
+
cssClass: cls.OK_BUTTON_CLASS + (this.parent.cssClass ? (' ' + this.parent.cssClass) : ''), content: this.parent.localeObj.getConstant('add'),
|
|
232
295
|
isPrimary: true
|
|
233
296
|
}
|
|
234
297
|
}],
|
|
@@ -257,7 +320,7 @@ var TreeViewRenderer = /** @class */ (function () {
|
|
|
257
320
|
});
|
|
258
321
|
var editorSearch = createElement('input', { attrs: { 'type': 'text' } });
|
|
259
322
|
searchWrapper.appendChild(editorSearch);
|
|
260
|
-
var treeOuterDiv = createElement('div', { className: cls.
|
|
323
|
+
var treeOuterDiv = createElement('div', { className: cls.FIELD_LIST_TREE_OUTER_DIV_CLASS });
|
|
261
324
|
var treeViewContainer = createElement('div', {
|
|
262
325
|
className: cls.EDITOR_TREE_CONTAINER_CLASS + ' ' + (this.parent.dataType === 'olap' ? 'e-olap-field-list-tree' : '')
|
|
263
326
|
});
|
|
@@ -267,7 +330,7 @@ var TreeViewRenderer = /** @class */ (function () {
|
|
|
267
330
|
placeholder: this.parent.localeObj.getConstant('search'),
|
|
268
331
|
enableRtl: this.parent.enableRtl,
|
|
269
332
|
locale: this.parent.locale,
|
|
270
|
-
cssClass: cls.EDITOR_SEARCH_CLASS,
|
|
333
|
+
cssClass: cls.EDITOR_SEARCH_CLASS + (this.parent.cssClass ? (' ' + this.parent.cssClass) : ''),
|
|
271
334
|
change: this.textChange.bind(this)
|
|
272
335
|
});
|
|
273
336
|
this.editorSearch.isStringTemplate = true;
|
|
@@ -303,14 +366,41 @@ var TreeViewRenderer = /** @class */ (function () {
|
|
|
303
366
|
};
|
|
304
367
|
TreeViewRenderer.prototype.textChange = function (e) {
|
|
305
368
|
this.parent.pivotCommon.eventBase.searchTreeNodes(e, this.fieldTable, true);
|
|
306
|
-
var promptDiv
|
|
369
|
+
var promptDiv;
|
|
370
|
+
var treeOuterDiv;
|
|
371
|
+
if (this.parent.isAdaptive) {
|
|
372
|
+
promptDiv = this.fieldDialog.element.querySelector('.' + cls.EMPTY_MEMBER_CLASS);
|
|
373
|
+
}
|
|
374
|
+
else {
|
|
375
|
+
promptDiv = this.parentElement.querySelector('.' + cls.EMPTY_MEMBER_CLASS);
|
|
376
|
+
treeOuterDiv = this.parentElement.querySelector('.' + cls.TREE_CONTAINER);
|
|
377
|
+
}
|
|
307
378
|
var liList = [].slice.call(this.fieldTable.element.querySelectorAll('li'));
|
|
308
379
|
var disabledList = [].slice.call(this.fieldTable.element.querySelectorAll('li.' + cls.ICON_DISABLE));
|
|
309
380
|
if (liList.length === disabledList.length) {
|
|
310
381
|
removeClass([promptDiv], cls.ICON_DISABLE);
|
|
382
|
+
if (!this.parent.isAdaptive) {
|
|
383
|
+
addClass([treeOuterDiv], cls.ICON_DISABLE);
|
|
384
|
+
removeClass([treeOuterDiv], cls.FIELD_LIST_TREE_OUTER_DIV_SEARCH_CLASS);
|
|
385
|
+
}
|
|
311
386
|
}
|
|
312
387
|
else {
|
|
313
388
|
addClass([promptDiv], cls.ICON_DISABLE);
|
|
389
|
+
if (!this.parent.isAdaptive) {
|
|
390
|
+
removeClass([treeOuterDiv], cls.ICON_DISABLE);
|
|
391
|
+
addClass([treeOuterDiv], cls.FIELD_LIST_TREE_OUTER_DIV_SEARCH_CLASS);
|
|
392
|
+
}
|
|
393
|
+
}
|
|
394
|
+
this.isSearching = disabledList.length > 0 ? true : false;
|
|
395
|
+
this.nonSearchList = disabledList;
|
|
396
|
+
if (this.parent.dataType === 'olap') {
|
|
397
|
+
this.parentIDs = [];
|
|
398
|
+
for (var i = 0; i < liList.length; i++) {
|
|
399
|
+
if (liList[i].classList.contains("e-level-1")) {
|
|
400
|
+
var id = liList[i].getAttribute('data-uid');
|
|
401
|
+
this.parentIDs.push(id);
|
|
402
|
+
}
|
|
403
|
+
}
|
|
314
404
|
}
|
|
315
405
|
};
|
|
316
406
|
TreeViewRenderer.prototype.dragStart = function (args) {
|
|
@@ -965,6 +1055,10 @@ var TreeViewRenderer = /** @class */ (function () {
|
|
|
965
1055
|
this.editorSearch.destroy();
|
|
966
1056
|
this.editorSearch = null;
|
|
967
1057
|
}
|
|
1058
|
+
if (this.fieldSearch && !this.fieldSearch.isDestroyed) {
|
|
1059
|
+
this.fieldSearch.destroy();
|
|
1060
|
+
this.fieldSearch = null;
|
|
1061
|
+
}
|
|
968
1062
|
};
|
|
969
1063
|
return TreeViewRenderer;
|
|
970
1064
|
}());
|
|
@@ -565,6 +565,13 @@ export interface PivotViewModel extends ComponentModel{
|
|
|
565
565
|
*/
|
|
566
566
|
allowCalculatedField?: boolean;
|
|
567
567
|
|
|
568
|
+
/**
|
|
569
|
+
* It enables the search option in the field list UI, which can be used to search specific fields at runtime.
|
|
570
|
+
* > This option is only available when the pivot table's built-in popup field list is enabled using the `showFieldList` property.
|
|
571
|
+
* @default false
|
|
572
|
+
*/
|
|
573
|
+
enableFieldSearching?: boolean;
|
|
574
|
+
|
|
568
575
|
/**
|
|
569
576
|
* Allows you to sort individual value field and its aggregated values either in row or column axis to ascending or descending order.
|
|
570
577
|
* You can sort the values by clicking directly on the value field header positioned either in row or column axis of the pivot table.
|
|
@@ -799,6 +799,12 @@ export declare class PivotView extends Component<HTMLElement> implements INotify
|
|
|
799
799
|
* @default false
|
|
800
800
|
*/
|
|
801
801
|
allowCalculatedField: boolean;
|
|
802
|
+
/**
|
|
803
|
+
* It enables the search option in the field list UI, which can be used to search specific fields at runtime.
|
|
804
|
+
* > This option is only available when the pivot table's built-in popup field list is enabled using the `showFieldList` property.
|
|
805
|
+
* @default false
|
|
806
|
+
*/
|
|
807
|
+
enableFieldSearching: boolean;
|
|
802
808
|
/**
|
|
803
809
|
* Allows you to sort individual value field and its aggregated values either in row or column axis to ascending or descending order.
|
|
804
810
|
* You can sort the values by clicking directly on the value field header positioned either in row or column axis of the pivot table.
|
|
@@ -689,8 +689,8 @@ var PivotView = /** @class */ (function (_super) {
|
|
|
689
689
|
if (this.showTooltip) {
|
|
690
690
|
if (this.tooltipTemplate) {
|
|
691
691
|
this.tooltip = new Tooltip({
|
|
692
|
-
target: 'td.e-valuescontent'
|
|
693
|
-
cssClass: 'e-pivottooltiptemplate',
|
|
692
|
+
target: 'td.e-valuescontent',
|
|
693
|
+
cssClass: 'e-pivottooltiptemplate' + (this.cssClass ? (' ' + this.cssClass) : ''),
|
|
694
694
|
showTipPointer: false,
|
|
695
695
|
position: 'BottomRight',
|
|
696
696
|
mouseTrail: true,
|
|
@@ -702,7 +702,8 @@ var PivotView = /** @class */ (function (_super) {
|
|
|
702
702
|
}
|
|
703
703
|
else {
|
|
704
704
|
this.tooltip = new Tooltip({
|
|
705
|
-
target: 'td.e-valuescontent'
|
|
705
|
+
target: 'td.e-valuescontent',
|
|
706
|
+
cssClass: this.cssClass,
|
|
706
707
|
showTipPointer: false,
|
|
707
708
|
position: 'BottomRight',
|
|
708
709
|
mouseTrail: true,
|
|
@@ -1629,6 +1630,8 @@ var PivotView = /** @class */ (function (_super) {
|
|
|
1629
1630
|
this.pivotFieldListModule.axisFieldModule.render();
|
|
1630
1631
|
}
|
|
1631
1632
|
break;
|
|
1633
|
+
case 'enableFieldSearching':
|
|
1634
|
+
this.pivotFieldListModule.enableFieldSearching = this.enableFieldSearching;
|
|
1632
1635
|
}
|
|
1633
1636
|
}
|
|
1634
1637
|
};
|
|
@@ -4226,6 +4229,9 @@ var PivotView = /** @class */ (function (_super) {
|
|
|
4226
4229
|
__decorate([
|
|
4227
4230
|
Property(false)
|
|
4228
4231
|
], PivotView.prototype, "allowCalculatedField", void 0);
|
|
4232
|
+
__decorate([
|
|
4233
|
+
Property(false)
|
|
4234
|
+
], PivotView.prototype, "enableFieldSearching", void 0);
|
|
4229
4235
|
__decorate([
|
|
4230
4236
|
Property(false)
|
|
4231
4237
|
], PivotView.prototype, "enableValueSorting", void 0);
|
|
@@ -350,6 +350,9 @@ var Render = /** @class */ (function () {
|
|
|
350
350
|
/* eslint-disable */
|
|
351
351
|
Render.prototype.contextMenuOpen = function (args) {
|
|
352
352
|
var _this = this;
|
|
353
|
+
if (args.element && this.parent.cssClass) {
|
|
354
|
+
addClass([args.element.parentElement], this.parent.cssClass);
|
|
355
|
+
}
|
|
353
356
|
var _loop_1 = function (item) {
|
|
354
357
|
var cellTarget = this_1.parent.lastCellClicked;
|
|
355
358
|
var elem = null;
|