@progress/kendo-angular-pivotgrid 0.1.5 → 0.2.0-dev.202208181339
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/bundles/kendo-angular-pivotgrid.umd.js +1 -1
- package/configurator/configurator.component.d.ts +96 -0
- package/configurator/configurator.service.d.ts +17 -0
- package/configurator/draggable.directive.d.ts +32 -0
- package/configurator/drop-cue.service.d.ts +22 -0
- package/configurator/drop-target.directive.d.ts +32 -0
- package/data-binding/base-binding-directive.d.ts +27 -5
- package/data-binding/local-binding.directive.d.ts +8 -1
- package/data-binding/olap-binding.directive.d.ts +13 -1
- package/data-binding/pivotgrid-data.service.d.ts +13 -4
- package/esm2015/configurator/configurator.component.js +512 -0
- package/esm2015/configurator/configurator.service.js +38 -0
- package/esm2015/configurator/draggable.directive.js +94 -0
- package/esm2015/configurator/drop-cue.service.js +64 -0
- package/esm2015/configurator/drop-target.directive.js +82 -0
- package/esm2015/data-binding/base-binding-directive.js +68 -9
- package/esm2015/data-binding/local-binding.directive.js +20 -8
- package/esm2015/data-binding/olap-binding.directive.js +131 -6
- package/esm2015/data-binding/pivotgrid-data.service.js +26 -3
- package/esm2015/localization/custom-messages.component.js +41 -0
- package/esm2015/localization/localized-messages.directive.js +36 -0
- package/esm2015/localization/messages.js +71 -0
- package/esm2015/main.js +8 -0
- package/esm2015/models/configuration-change-event.js +18 -0
- package/esm2015/models/configurator-settings.js +14 -0
- package/esm2015/models/expanded-change-event.js +18 -0
- package/esm2015/package-metadata.js +1 -1
- package/esm2015/pivotgrid.component.js +350 -59
- package/esm2015/pivotgrid.module.js +43 -16
- package/esm2015/rendering/pivotgrid-cell.directive.js +6 -3
- package/esm2015/rendering/pivotgrid-table.component.js +38 -13
- package/esm2015/util.js +86 -0
- package/fesm2015/kendo-angular-pivotgrid.js +1744 -198
- package/localization/custom-messages.component.d.ts +18 -0
- package/localization/localized-messages.directive.d.ts +16 -0
- package/localization/messages.d.ts +160 -0
- package/main.d.ts +6 -0
- package/models/configuration-change-event.d.ts +36 -0
- package/models/configurator-settings.d.ts +32 -0
- package/models/expanded-change-event.d.ts +27 -0
- package/package.json +12 -6
- package/pivotgrid.component.d.ts +34 -3
- package/pivotgrid.module.d.ts +15 -7
- package/rendering/pivotgrid-table.component.d.ts +5 -3
- package/util.d.ts +31 -0
|
@@ -3,19 +3,27 @@
|
|
|
3
3
|
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
4
|
*-------------------------------------------------------------------------------------------*/
|
|
5
5
|
import * as i0 from '@angular/core';
|
|
6
|
-
import { EventEmitter, Injectable, Output, Component, HostBinding, Input, ElementRef, ViewChild,
|
|
6
|
+
import { EventEmitter, Injectable, Output, Component, HostBinding, Input, Directive, Optional, forwardRef, ElementRef, ViewChild, NgModule } from '@angular/core';
|
|
7
7
|
import { validatePackage } from '@progress/kendo-licensing';
|
|
8
|
-
import * as
|
|
9
|
-
import { isDocumentAvailable, anyChanged, EventsModule } from '@progress/kendo-angular-common';
|
|
10
|
-
import { toTree, toRows, toColumns, toData, HEADERS_ACTION, headersReducer, createDataTree, createLocalDataState, rootFields, fetchData, createDataState } from '@progress/kendo-pivotgrid-common';
|
|
8
|
+
import * as i3 from '@progress/kendo-angular-common';
|
|
9
|
+
import { isDocumentAvailable, PreventableEvent, hasObservers, anyChanged, EventsModule, DraggableModule } from '@progress/kendo-angular-common';
|
|
10
|
+
import { toTree, toRows, toColumns, toData, configuratorReducer, PIVOT_CONFIGURATOR_ACTION, HEADERS_ACTION, headersReducer, createFlatSchemaDimensions, createDataTree, createLocalDataState, rootFields, fetchData, createDataState, fetchDiscover, addKPI, buildKPIMeasures } from '@progress/kendo-pivotgrid-common';
|
|
11
11
|
export { averageAggregate, maxAggregate, minAggregate, sumAggregate } from '@progress/kendo-pivotgrid-common';
|
|
12
|
-
import { BehaviorSubject, Subscription, fromEvent } from 'rxjs';
|
|
13
|
-
import { merge } from 'rxjs/operators';
|
|
14
|
-
import * as i2 from '@angular
|
|
12
|
+
import { BehaviorSubject, Subscription, from, of, fromEvent } from 'rxjs';
|
|
13
|
+
import { mergeMap, merge } from 'rxjs/operators';
|
|
14
|
+
import * as i2 from '@progress/kendo-angular-l10n';
|
|
15
|
+
import { ComponentMessages, LocalizationService, L10N_PREFIX } from '@progress/kendo-angular-l10n';
|
|
16
|
+
import * as i6 from '@angular/common';
|
|
15
17
|
import { CommonModule } from '@angular/common';
|
|
16
|
-
import * as
|
|
18
|
+
import * as i5$1 from '@progress/kendo-angular-indicators';
|
|
17
19
|
import { IndicatorsModule } from '@progress/kendo-angular-indicators';
|
|
18
|
-
import
|
|
20
|
+
import * as i4 from '@progress/kendo-angular-treeview';
|
|
21
|
+
import { TreeViewModule } from '@progress/kendo-angular-treeview';
|
|
22
|
+
import * as i5 from '@progress/kendo-angular-buttons';
|
|
23
|
+
import { ButtonsModule } from '@progress/kendo-angular-buttons';
|
|
24
|
+
import * as i7 from '@progress/kendo-angular-inputs';
|
|
25
|
+
import { InputsModule } from '@progress/kendo-angular-inputs';
|
|
26
|
+
import { __awaiter } from 'tslib';
|
|
19
27
|
|
|
20
28
|
/**
|
|
21
29
|
* @hidden
|
|
@@ -24,46 +32,11 @@ const packageMetadata = {
|
|
|
24
32
|
name: '@progress/kendo-angular-pivotgrid',
|
|
25
33
|
productName: 'Kendo UI for Angular',
|
|
26
34
|
productCodes: ['KENDOUIANGULAR', 'KENDOUICOMPLETE'],
|
|
27
|
-
publishDate:
|
|
35
|
+
publishDate: 1660829909,
|
|
28
36
|
version: '',
|
|
29
37
|
licensingDocsUrl: 'https://www.telerik.com/kendo-angular-ui/my-license/?utm_medium=product&utm_source=kendoangular&utm_campaign=kendo-ui-angular-purchase-license-keys-warning'
|
|
30
38
|
};
|
|
31
39
|
|
|
32
|
-
/**
|
|
33
|
-
* @hidden
|
|
34
|
-
*/
|
|
35
|
-
class PivotGridDataService {
|
|
36
|
-
constructor() {
|
|
37
|
-
this.expandedStateChange = new EventEmitter();
|
|
38
|
-
this.columnHeaderRows = new BehaviorSubject([]);
|
|
39
|
-
this.columnHeaderCols = new BehaviorSubject([]);
|
|
40
|
-
this.rowHeaderCols = new BehaviorSubject([]);
|
|
41
|
-
this.rowHeaderRows = new BehaviorSubject([]);
|
|
42
|
-
this.valuesRows = new BehaviorSubject([]);
|
|
43
|
-
this.loading = new BehaviorSubject(false);
|
|
44
|
-
}
|
|
45
|
-
updateRowsAndCols() {
|
|
46
|
-
const rowsTree = toTree((this.rows || []).slice());
|
|
47
|
-
const [rowHeaderRows, rowHeaderLeaves, rowHeaderDepth, rowHeaderBreadth] = toRows(rowsTree);
|
|
48
|
-
const columnsTree = toTree((this.columns || []).slice());
|
|
49
|
-
const [columnHeaderRows, columnHeaderLeaves, columnHeaderBreadth] = toColumns(columnsTree);
|
|
50
|
-
this.columnHeaderLeaves = columnHeaderLeaves;
|
|
51
|
-
this.columnHeaderCols.next(columnHeaderLeaves);
|
|
52
|
-
this.columnHeaderRows.next(columnHeaderRows);
|
|
53
|
-
this.rowHeaderLeaves = rowHeaderLeaves;
|
|
54
|
-
this.rowHeaderCols.next(new Array(rowHeaderBreadth).fill({}));
|
|
55
|
-
this.rowHeaderRows.next(rowHeaderRows);
|
|
56
|
-
this.valuesRows.next(toData((this.normalizedData || []).slice(), columnHeaderLeaves, rowHeaderLeaves, columnHeaderBreadth, rowHeaderDepth));
|
|
57
|
-
}
|
|
58
|
-
}
|
|
59
|
-
PivotGridDataService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PivotGridDataService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
60
|
-
PivotGridDataService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PivotGridDataService });
|
|
61
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PivotGridDataService, decorators: [{
|
|
62
|
-
type: Injectable
|
|
63
|
-
}], propDecorators: { expandedStateChange: [{
|
|
64
|
-
type: Output
|
|
65
|
-
}] } });
|
|
66
|
-
|
|
67
40
|
/**
|
|
68
41
|
* @hidden
|
|
69
42
|
*/
|
|
@@ -126,6 +99,148 @@ const syncWheel = (event, tables, prop, axis) => {
|
|
|
126
99
|
tables[1][prop] += delta;
|
|
127
100
|
}
|
|
128
101
|
};
|
|
102
|
+
/**
|
|
103
|
+
* @hidden
|
|
104
|
+
*/
|
|
105
|
+
function cloneTo(obj, result) {
|
|
106
|
+
for (let field in obj) {
|
|
107
|
+
if (obj.hasOwnProperty(field)) {
|
|
108
|
+
const value = obj[field];
|
|
109
|
+
if (Array.isArray(value)) {
|
|
110
|
+
result[field] = value.slice(0);
|
|
111
|
+
}
|
|
112
|
+
else if (value && typeof value === 'object' && !(value instanceof Date)) {
|
|
113
|
+
result[field] = result[field] || {};
|
|
114
|
+
cloneTo(value, result[field]);
|
|
115
|
+
}
|
|
116
|
+
else {
|
|
117
|
+
result[field] = value;
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
/**
|
|
123
|
+
* @hidden
|
|
124
|
+
*/
|
|
125
|
+
function clone(obj) {
|
|
126
|
+
const result = {};
|
|
127
|
+
cloneTo(obj, result);
|
|
128
|
+
return result;
|
|
129
|
+
}
|
|
130
|
+
/**
|
|
131
|
+
* @hidden
|
|
132
|
+
*/
|
|
133
|
+
const getDocument = element => element.ownerDocument.documentElement;
|
|
134
|
+
/**
|
|
135
|
+
* @hidden
|
|
136
|
+
*/
|
|
137
|
+
const getWindow = element => element.ownerDocument.defaultView;
|
|
138
|
+
/**
|
|
139
|
+
* @hidden
|
|
140
|
+
*/
|
|
141
|
+
const offset = element => {
|
|
142
|
+
const { clientTop, clientLeft } = getDocument(element);
|
|
143
|
+
const { pageYOffset, pageXOffset } = getWindow(element);
|
|
144
|
+
const { top, left } = element.getBoundingClientRect();
|
|
145
|
+
return {
|
|
146
|
+
top: top + pageYOffset - clientTop,
|
|
147
|
+
left: left + pageXOffset - clientLeft
|
|
148
|
+
};
|
|
149
|
+
};
|
|
150
|
+
/**
|
|
151
|
+
* @hidden
|
|
152
|
+
*/
|
|
153
|
+
const matchAriaAttributes = (wrapper) => {
|
|
154
|
+
const rowHeaderRows = wrapper.querySelectorAll('.k-pivotgrid-row-headers .k-pivotgrid-row');
|
|
155
|
+
const colHeaderCells = wrapper.querySelectorAll('.k-pivotgrid-column-headers th');
|
|
156
|
+
const valueTableCells = wrapper.querySelectorAll('.k-pivotgrid-values td');
|
|
157
|
+
rowHeaderRows.forEach((row, index) => {
|
|
158
|
+
const valueCellsIds = filterAndMap(Array.from(valueTableCells), c => c.getAttribute('id').split('-')[4] === (index + 1).toString(), c => c.getAttribute('id'));
|
|
159
|
+
row.setAttribute('aria-owns', valueCellsIds.join(' '));
|
|
160
|
+
});
|
|
161
|
+
valueTableCells.forEach(cell => {
|
|
162
|
+
const cellColIndex = +cell.getAttribute('id').split('-')[5];
|
|
163
|
+
const colHeaderCellsIds = filterAndMap(Array.from(colHeaderCells), c => {
|
|
164
|
+
const headerCellColIndex = +c.getAttribute('id').split('-')[5];
|
|
165
|
+
const headerCellColspan = +c.getAttribute('colspan');
|
|
166
|
+
const colIndexIsEqual = cellColIndex === headerCellColIndex;
|
|
167
|
+
const cellColIndexIsWithinHeaderCellRange = headerCellColspan > 1 && (headerCellColIndex + headerCellColspan - 1 >= cellColIndex);
|
|
168
|
+
return colIndexIsEqual || cellColIndexIsWithinHeaderCellRange;
|
|
169
|
+
}, c => c.getAttribute('id'));
|
|
170
|
+
cell.setAttribute('aria-describedby', colHeaderCellsIds.join(' '));
|
|
171
|
+
});
|
|
172
|
+
};
|
|
173
|
+
/**
|
|
174
|
+
* @hidden
|
|
175
|
+
*/
|
|
176
|
+
const position = (target, before) => {
|
|
177
|
+
const targetRect = offset(target);
|
|
178
|
+
const { offsetWidth, offsetHeight } = target;
|
|
179
|
+
const left = targetRect.left + (before ? 0 : offsetWidth);
|
|
180
|
+
const top = targetRect.top + offsetHeight / 2;
|
|
181
|
+
const height = offsetHeight;
|
|
182
|
+
return { left, top, height };
|
|
183
|
+
};
|
|
184
|
+
/**
|
|
185
|
+
* @hidden
|
|
186
|
+
*/
|
|
187
|
+
const filterAndMap = (arr, predicate, mapper) => arr.reduce((acc, curr) => predicate(curr) ? [...acc, mapper(curr)] : acc, []);
|
|
188
|
+
|
|
189
|
+
/**
|
|
190
|
+
* @hidden
|
|
191
|
+
*/
|
|
192
|
+
let nextPivotGridId = 0;
|
|
193
|
+
/**
|
|
194
|
+
* @hidden
|
|
195
|
+
*/
|
|
196
|
+
class PivotGridDataService {
|
|
197
|
+
constructor(ngZone) {
|
|
198
|
+
this.ngZone = ngZone;
|
|
199
|
+
this.expandedStateChange = new EventEmitter();
|
|
200
|
+
this.configuratorFieldChange = new EventEmitter();
|
|
201
|
+
this.expandedFieldChange = new EventEmitter();
|
|
202
|
+
this.columnHeaderRows = new BehaviorSubject([]);
|
|
203
|
+
this.columnHeaderCols = new BehaviorSubject([]);
|
|
204
|
+
this.rowHeaderCols = new BehaviorSubject([]);
|
|
205
|
+
this.rowHeaderRows = new BehaviorSubject([]);
|
|
206
|
+
this.valuesRows = new BehaviorSubject([]);
|
|
207
|
+
this.loading = new BehaviorSubject(false);
|
|
208
|
+
this.fields = new BehaviorSubject([]);
|
|
209
|
+
this.configuredFields = new BehaviorSubject([]);
|
|
210
|
+
this.pivotGridId = nextPivotGridId++;
|
|
211
|
+
}
|
|
212
|
+
updateRowsAndCols() {
|
|
213
|
+
const rowsTree = toTree((this.rows || []).slice());
|
|
214
|
+
const [rowHeaderRows, rowHeaderLeaves, rowHeaderDepth, rowHeaderBreadth] = toRows(rowsTree);
|
|
215
|
+
const columnsTree = toTree((this.columns || []).slice());
|
|
216
|
+
const [columnHeaderRows, columnHeaderLeaves, columnHeaderBreadth] = toColumns(columnsTree);
|
|
217
|
+
this.columnHeaderLeaves = columnHeaderLeaves;
|
|
218
|
+
this.columnHeaderCols.next(columnHeaderLeaves);
|
|
219
|
+
this.columnHeaderRows.next(columnHeaderRows);
|
|
220
|
+
this.rowHeaderLeaves = rowHeaderLeaves;
|
|
221
|
+
this.rowHeaderCols.next(new Array(rowHeaderBreadth).fill({}));
|
|
222
|
+
this.rowHeaderRows.next(rowHeaderRows);
|
|
223
|
+
this.valuesRows.next(toData((this.normalizedData || []).slice(), columnHeaderLeaves, rowHeaderLeaves, columnHeaderBreadth, rowHeaderDepth));
|
|
224
|
+
if (isDocumentAvailable()) {
|
|
225
|
+
this.ngZone.runOutsideAngular(() => {
|
|
226
|
+
// needed because all tables need to be rendered in accordance with the new settings
|
|
227
|
+
// before applying the required DOM attributes
|
|
228
|
+
setTimeout(() => matchAriaAttributes(this.wrapper));
|
|
229
|
+
});
|
|
230
|
+
}
|
|
231
|
+
}
|
|
232
|
+
}
|
|
233
|
+
PivotGridDataService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PivotGridDataService, deps: [{ token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
234
|
+
PivotGridDataService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PivotGridDataService });
|
|
235
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PivotGridDataService, decorators: [{
|
|
236
|
+
type: Injectable
|
|
237
|
+
}], ctorParameters: function () { return [{ type: i0.NgZone }]; }, propDecorators: { expandedStateChange: [{
|
|
238
|
+
type: Output
|
|
239
|
+
}], configuratorFieldChange: [{
|
|
240
|
+
type: Output
|
|
241
|
+
}], expandedFieldChange: [{
|
|
242
|
+
type: Output
|
|
243
|
+
}] } });
|
|
129
244
|
|
|
130
245
|
/**
|
|
131
246
|
* @hidden
|
|
@@ -149,15 +264,16 @@ class PivotGridCellDirective {
|
|
|
149
264
|
return ((_a = this.kendoPivotGridCell) === null || _a === void 0 ? void 0 : _a.hasChildren) && this.kendoPivotGridCell.children.length;
|
|
150
265
|
}
|
|
151
266
|
ngOnInit() {
|
|
267
|
+
var _a, _b, _c;
|
|
152
268
|
const nativeElement = this.hostEl.nativeElement;
|
|
153
269
|
this.renderer.setAttribute(nativeElement, 'rowspan', this.kendoPivotGridCell.rowSpan || 1);
|
|
154
270
|
this.renderer.setAttribute(nativeElement, 'colspan', this.kendoPivotGridCell.colSpan || 1);
|
|
155
271
|
const classesToAdd = {
|
|
156
|
-
'k-pivotgrid-header-total': this.kendoPivotGridCell.total || (this.tableType === 'values'
|
|
272
|
+
'k-pivotgrid-header-total': ((_a = this.kendoPivotGridCell) === null || _a === void 0 ? void 0 : _a.total) || (this.tableType === 'values'
|
|
157
273
|
&& (this.dataService.rowHeaderLeaves[this.rowIndex].total ||
|
|
158
274
|
this.dataService.columnHeaderLeaves[this.colIndex].total)),
|
|
159
|
-
'k-pivotgrid-header-root': this.kendoPivotGridCell.levelNum === 0,
|
|
160
|
-
'k-pivotgrid-expanded': this.kendoPivotGridCell.hasChildren && this.kendoPivotGridCell.children.length,
|
|
275
|
+
'k-pivotgrid-header-root': ((_b = this.kendoPivotGridCell) === null || _b === void 0 ? void 0 : _b.levelNum) === 0,
|
|
276
|
+
'k-pivotgrid-expanded': ((_c = this.kendoPivotGridCell) === null || _c === void 0 ? void 0 : _c.hasChildren) && this.kendoPivotGridCell.children.length,
|
|
161
277
|
'k-first': this.colIndex > 0
|
|
162
278
|
};
|
|
163
279
|
for (let prop in classesToAdd) {
|
|
@@ -172,13 +288,14 @@ PivotGridCellDirective.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0",
|
|
|
172
288
|
<span
|
|
173
289
|
*ngIf="kendoPivotGridCell.hasChildren && !kendoPivotGridCell.total"
|
|
174
290
|
class="k-icon"
|
|
291
|
+
aria-hidden="true"
|
|
175
292
|
[kendoEventsOutsideAngular]="{
|
|
176
293
|
click: handleClick
|
|
177
294
|
}"
|
|
178
295
|
[ngClass]="{
|
|
179
296
|
'k-i-arrow-chevron-up': expanded,
|
|
180
297
|
'k-i-arrow-chevron-down': !expanded
|
|
181
|
-
}"></span>{{ kendoPivotGridCell.data ? kendoPivotGridCell.data.fmtValue : kendoPivotGridCell.caption }}`, isInline: true, directives: [{ type:
|
|
298
|
+
}"></span>{{ kendoPivotGridCell.data ? kendoPivotGridCell.data.fmtValue : kendoPivotGridCell.caption }}`, isInline: true, directives: [{ type: i6.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i3.EventsOutsideAngularDirective, selector: "[kendoEventsOutsideAngular]", inputs: ["kendoEventsOutsideAngular", "scope"] }, { type: i6.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }] });
|
|
182
299
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PivotGridCellDirective, decorators: [{
|
|
183
300
|
type: Component,
|
|
184
301
|
args: [{
|
|
@@ -188,6 +305,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
|
|
|
188
305
|
<span
|
|
189
306
|
*ngIf="kendoPivotGridCell.hasChildren && !kendoPivotGridCell.total"
|
|
190
307
|
class="k-icon"
|
|
308
|
+
aria-hidden="true"
|
|
191
309
|
[kendoEventsOutsideAngular]="{
|
|
192
310
|
click: handleClick
|
|
193
311
|
}"
|
|
@@ -217,6 +335,9 @@ class PivotGridTableComponent {
|
|
|
217
335
|
this.dataService = dataService;
|
|
218
336
|
this.dataChangeSubs = new Subscription();
|
|
219
337
|
}
|
|
338
|
+
get pivotGridId() {
|
|
339
|
+
return `kendo-pivotgrid-${this.dataService.pivotGridId}-`;
|
|
340
|
+
}
|
|
220
341
|
ngOnInit() {
|
|
221
342
|
this.dataChangeSubs.add(this.dataService[`${this.tableType}Rows`].subscribe(rows => this.rows = rows));
|
|
222
343
|
this.dataChangeSubs.add(this.tableType === 'values' ?
|
|
@@ -227,91 +348,957 @@ class PivotGridTableComponent {
|
|
|
227
348
|
this.dataChangeSubs.unsubscribe();
|
|
228
349
|
}
|
|
229
350
|
}
|
|
230
|
-
PivotGridTableComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PivotGridTableComponent, deps: [{ token: PivotGridDataService }], target: i0.ɵɵFactoryTarget.Component });
|
|
231
|
-
PivotGridTableComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: PivotGridTableComponent, selector: "kendo-pivotgrid-table", inputs: { tableType: "tableType" }, ngImport: i0, template: `
|
|
232
|
-
<table
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
[
|
|
249
|
-
|
|
250
|
-
[
|
|
251
|
-
[
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
351
|
+
PivotGridTableComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PivotGridTableComponent, deps: [{ token: PivotGridDataService }], target: i0.ɵɵFactoryTarget.Component });
|
|
352
|
+
PivotGridTableComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: PivotGridTableComponent, selector: "kendo-pivotgrid-table", inputs: { tableType: "tableType", colWidth: "colWidth" }, ngImport: i0, template: `
|
|
353
|
+
<table
|
|
354
|
+
class="k-pivotgrid-table"
|
|
355
|
+
role="presentation">
|
|
356
|
+
<colgroup>
|
|
357
|
+
<col
|
|
358
|
+
*ngFor="let item of headerItems;"
|
|
359
|
+
[style.width]="tableType !== 'rowHeader' ? colWidth >= 0 ? colWidth + 'px' : '200px' : undefined" />
|
|
360
|
+
</colgroup>
|
|
361
|
+
<tbody class="k-pivotgrid-tbody" role="rowgroup">
|
|
362
|
+
<tr *ngFor="let row of rows; index as rowIndex"
|
|
363
|
+
class="k-pivotgrid-row"
|
|
364
|
+
role="row">
|
|
365
|
+
<ng-container *ngFor="let cell of row.cells; index as colIndex">
|
|
366
|
+
<th
|
|
367
|
+
*ngIf="cell && tableType !== 'values'"
|
|
368
|
+
[kendoPivotGridCell]="cell"
|
|
369
|
+
[tableType]="tableType"
|
|
370
|
+
[colIndex]="colIndex"
|
|
371
|
+
[rowIndex]="rowIndex"
|
|
372
|
+
[attr.aria-expanded]="cell.hasChildren && cell.children.length ? 'true' : 'false'"
|
|
373
|
+
[attr.role]="tableType === 'columnHeader' ? 'columnheader' : 'rowheader'"
|
|
374
|
+
[attr.id]="pivotGridId + (tableType === 'columnHeader' ? 'ch-' : 'rh-') + (rowIndex + 1) + '-' + (colIndex + 1)"></th>
|
|
375
|
+
<td
|
|
376
|
+
*ngIf="cell && tableType === 'values'"
|
|
377
|
+
[kendoPivotGridCell]="cell"
|
|
378
|
+
tableType="values"
|
|
379
|
+
[colIndex]="colIndex"
|
|
380
|
+
[rowIndex]="rowIndex"
|
|
381
|
+
role="gridcell"
|
|
382
|
+
[attr.id]="pivotGridId + 'cell-' + (rowIndex + 1) + '-' + (colIndex + 1)"></td>
|
|
383
|
+
</ng-container>
|
|
384
|
+
</tr>
|
|
385
|
+
</tbody>
|
|
386
|
+
</table>
|
|
387
|
+
`, isInline: true, components: [{ type: PivotGridCellDirective, selector: "[kendoPivotGridCell]", inputs: ["kendoPivotGridCell", "tableType", "rowIndex", "colIndex"] }], directives: [{ type: i6.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i6.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
|
|
388
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PivotGridTableComponent, decorators: [{
|
|
389
|
+
type: Component,
|
|
390
|
+
args: [{
|
|
391
|
+
selector: 'kendo-pivotgrid-table',
|
|
392
|
+
template: `
|
|
393
|
+
<table
|
|
394
|
+
class="k-pivotgrid-table"
|
|
395
|
+
role="presentation">
|
|
396
|
+
<colgroup>
|
|
397
|
+
<col
|
|
398
|
+
*ngFor="let item of headerItems;"
|
|
399
|
+
[style.width]="tableType !== 'rowHeader' ? colWidth >= 0 ? colWidth + 'px' : '200px' : undefined" />
|
|
400
|
+
</colgroup>
|
|
401
|
+
<tbody class="k-pivotgrid-tbody" role="rowgroup">
|
|
402
|
+
<tr *ngFor="let row of rows; index as rowIndex"
|
|
403
|
+
class="k-pivotgrid-row"
|
|
404
|
+
role="row">
|
|
405
|
+
<ng-container *ngFor="let cell of row.cells; index as colIndex">
|
|
406
|
+
<th
|
|
407
|
+
*ngIf="cell && tableType !== 'values'"
|
|
408
|
+
[kendoPivotGridCell]="cell"
|
|
409
|
+
[tableType]="tableType"
|
|
410
|
+
[colIndex]="colIndex"
|
|
411
|
+
[rowIndex]="rowIndex"
|
|
412
|
+
[attr.aria-expanded]="cell.hasChildren && cell.children.length ? 'true' : 'false'"
|
|
413
|
+
[attr.role]="tableType === 'columnHeader' ? 'columnheader' : 'rowheader'"
|
|
414
|
+
[attr.id]="pivotGridId + (tableType === 'columnHeader' ? 'ch-' : 'rh-') + (rowIndex + 1) + '-' + (colIndex + 1)"></th>
|
|
415
|
+
<td
|
|
416
|
+
*ngIf="cell && tableType === 'values'"
|
|
417
|
+
[kendoPivotGridCell]="cell"
|
|
418
|
+
tableType="values"
|
|
419
|
+
[colIndex]="colIndex"
|
|
420
|
+
[rowIndex]="rowIndex"
|
|
421
|
+
role="gridcell"
|
|
422
|
+
[attr.id]="pivotGridId + 'cell-' + (rowIndex + 1) + '-' + (colIndex + 1)"></td>
|
|
423
|
+
</ng-container>
|
|
424
|
+
</tr>
|
|
425
|
+
</tbody>
|
|
426
|
+
</table>
|
|
427
|
+
`
|
|
428
|
+
}]
|
|
429
|
+
}], ctorParameters: function () { return [{ type: PivotGridDataService }]; }, propDecorators: { tableType: [{
|
|
430
|
+
type: Input
|
|
431
|
+
}], colWidth: [{
|
|
432
|
+
type: Input
|
|
433
|
+
}] } });
|
|
434
|
+
|
|
435
|
+
/**
|
|
436
|
+
* @hidden
|
|
437
|
+
*/
|
|
438
|
+
class ConfiguratorService {
|
|
439
|
+
constructor() {
|
|
440
|
+
this.configuratorStateChange = new EventEmitter();
|
|
441
|
+
}
|
|
442
|
+
parseConfiguratorState(action) {
|
|
443
|
+
const newState = configuratorReducer({
|
|
444
|
+
filter: [],
|
|
445
|
+
sort: [],
|
|
446
|
+
rowAxes: this.state.rowAxes,
|
|
447
|
+
columnAxes: this.state.columnAxes,
|
|
448
|
+
measureAxes: this.state.measureAxes,
|
|
449
|
+
dragItem: this.state.dragItem,
|
|
450
|
+
dropDirection: this.state.dropDirection,
|
|
451
|
+
dropTarget: this.state.dropTarget,
|
|
452
|
+
dropZone: this.state.dropZone
|
|
453
|
+
}, action);
|
|
454
|
+
Object.keys(newState).forEach(key => newState[key] === undefined && delete newState[key]);
|
|
455
|
+
this.state = Object.assign(Object.assign({}, this.state), newState);
|
|
456
|
+
this.configuratorStateChange.emit(this.state);
|
|
457
|
+
}
|
|
458
|
+
}
|
|
459
|
+
ConfiguratorService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ConfiguratorService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
460
|
+
ConfiguratorService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ConfiguratorService });
|
|
461
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: ConfiguratorService, decorators: [{
|
|
462
|
+
type: Injectable
|
|
463
|
+
}], propDecorators: { configuratorStateChange: [{
|
|
464
|
+
type: Output
|
|
465
|
+
}] } });
|
|
466
|
+
|
|
467
|
+
/**
|
|
468
|
+
* @hidden
|
|
469
|
+
*/
|
|
470
|
+
const append = (element) => {
|
|
471
|
+
let appended = false;
|
|
472
|
+
return () => {
|
|
473
|
+
if (!appended) {
|
|
474
|
+
document.body.appendChild(element);
|
|
475
|
+
appended = true;
|
|
476
|
+
}
|
|
477
|
+
return element;
|
|
478
|
+
};
|
|
479
|
+
};
|
|
480
|
+
/**
|
|
481
|
+
* @hidden
|
|
482
|
+
*/
|
|
483
|
+
class DropCueService {
|
|
484
|
+
create() {
|
|
485
|
+
this.dom = document.createElement('span');
|
|
486
|
+
this.dom.style.position = 'absolute';
|
|
487
|
+
const wrapper = document.createElement('div');
|
|
488
|
+
wrapper.classList.add('k-drop-hint', 'k-drop-hint-v');
|
|
489
|
+
const hintStart = document.createElement('div');
|
|
490
|
+
hintStart.classList.add('k-drop-hint-start');
|
|
491
|
+
const hintLine = document.createElement('div');
|
|
492
|
+
hintLine.classList.add('k-drop-hint-line');
|
|
493
|
+
const hintEnd = document.createElement('div');
|
|
494
|
+
hintEnd.classList.add('k-drop-hint-end');
|
|
495
|
+
wrapper.append(hintStart, hintLine, hintEnd);
|
|
496
|
+
this.dom.append(wrapper);
|
|
497
|
+
this.hide();
|
|
498
|
+
}
|
|
499
|
+
attach() {
|
|
500
|
+
return append(this.dom)();
|
|
501
|
+
}
|
|
502
|
+
remove() {
|
|
503
|
+
if (this.dom && this.dom.parentElement) {
|
|
504
|
+
document.body.removeChild(this.dom);
|
|
505
|
+
this.dom = null;
|
|
506
|
+
}
|
|
507
|
+
}
|
|
508
|
+
hide() {
|
|
509
|
+
this.dom.style.display = "none";
|
|
510
|
+
}
|
|
511
|
+
position({ left, top, height }) {
|
|
512
|
+
this.dom.style.display = 'block';
|
|
513
|
+
this.dom.style.height = height + 'px';
|
|
514
|
+
this.dom.style.top = top + 'px';
|
|
515
|
+
this.dom.style.zIndex = '1000';
|
|
516
|
+
const width = this.dom.offsetWidth / 2;
|
|
517
|
+
this.dom.style.left = left - width + 'px';
|
|
518
|
+
}
|
|
519
|
+
}
|
|
520
|
+
DropCueService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: DropCueService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
521
|
+
DropCueService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: DropCueService });
|
|
522
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: DropCueService, decorators: [{
|
|
523
|
+
type: Injectable
|
|
524
|
+
}] });
|
|
525
|
+
|
|
526
|
+
/**
|
|
527
|
+
* @hidden
|
|
528
|
+
*/
|
|
529
|
+
class DropTargetDirective {
|
|
530
|
+
constructor(element, configuratorService, cue, renderer, zone) {
|
|
531
|
+
this.element = element;
|
|
532
|
+
this.configuratorService = configuratorService;
|
|
533
|
+
this.cue = cue;
|
|
534
|
+
this.renderer = renderer;
|
|
535
|
+
this.zone = zone;
|
|
536
|
+
this.subs = new Subscription();
|
|
537
|
+
}
|
|
538
|
+
ngOnInit() {
|
|
539
|
+
const element = this.element.nativeElement;
|
|
540
|
+
this.elementType = element.nodeName === 'KENDO-CHIP' ? 'chip' : 'container';
|
|
541
|
+
this.zone.runOutsideAngular(() => {
|
|
542
|
+
this.subs.add(this.renderer.listen(element, 'mouseenter', this.handleMouseEnter.bind(this)));
|
|
543
|
+
this.subs.add(this.renderer.listen(element, 'mousemove', this.handleMouseMove.bind(this)));
|
|
544
|
+
this.subs.add(this.renderer.listen(element, 'mouseleave', this.handleMouseLeave.bind(this)));
|
|
545
|
+
});
|
|
546
|
+
}
|
|
547
|
+
ngOnDestroy() {
|
|
548
|
+
this.subs.unsubscribe();
|
|
549
|
+
}
|
|
550
|
+
handleMouseEnter(event) {
|
|
551
|
+
if (this.configuratorService.state.dragItem) {
|
|
552
|
+
if (this.elementType === 'chip') {
|
|
553
|
+
this.configuratorService.parseConfiguratorState({ type: PIVOT_CONFIGURATOR_ACTION.setDropTarget, payload: this.item });
|
|
554
|
+
this.targetElement = event.target;
|
|
555
|
+
this.cue.position(position(event.target, this.configuratorService.state.dropDirection === 'before'));
|
|
556
|
+
}
|
|
557
|
+
this.configuratorService.parseConfiguratorState({ type: PIVOT_CONFIGURATOR_ACTION.setDropZone, payload: this.axes });
|
|
558
|
+
}
|
|
559
|
+
}
|
|
560
|
+
handleMouseMove($event) {
|
|
561
|
+
if (this.configuratorService.state.dragItem) {
|
|
562
|
+
if (this.elementType !== 'chip') {
|
|
563
|
+
return;
|
|
564
|
+
}
|
|
565
|
+
if (this.element.nativeElement) {
|
|
566
|
+
const rect = this.element.nativeElement.getBoundingClientRect();
|
|
567
|
+
const x = $event.clientX - rect.left;
|
|
568
|
+
const direction = x < rect.width / 2 ? 'before' : 'after';
|
|
569
|
+
if ((direction !== this.configuratorService.state.dropDirection) && this.targetElement) {
|
|
570
|
+
this.cue.position(position(this.targetElement, direction === 'before'));
|
|
571
|
+
}
|
|
572
|
+
this.configuratorService.parseConfiguratorState({ type: PIVOT_CONFIGURATOR_ACTION.setDropDirection, payload: direction });
|
|
573
|
+
}
|
|
574
|
+
}
|
|
575
|
+
}
|
|
576
|
+
handleMouseLeave() {
|
|
577
|
+
if (this.elementType === 'chip') {
|
|
578
|
+
return;
|
|
579
|
+
}
|
|
580
|
+
if (this.configuratorService.state.dragItem) {
|
|
581
|
+
this.configuratorService.parseConfiguratorState({ type: PIVOT_CONFIGURATOR_ACTION.setDropZone, payload: null });
|
|
582
|
+
}
|
|
583
|
+
}
|
|
584
|
+
}
|
|
585
|
+
DropTargetDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: DropTargetDirective, deps: [{ token: i0.ElementRef }, { token: ConfiguratorService }, { token: DropCueService }, { token: i0.Renderer2 }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Directive });
|
|
586
|
+
DropTargetDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: DropTargetDirective, selector: "[kendoDropTarget]", inputs: { item: "item", axes: "axes" }, ngImport: i0 });
|
|
587
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: DropTargetDirective, decorators: [{
|
|
588
|
+
type: Directive,
|
|
589
|
+
args: [{
|
|
590
|
+
selector: '[kendoDropTarget]'
|
|
591
|
+
}]
|
|
592
|
+
}], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: ConfiguratorService }, { type: DropCueService }, { type: i0.Renderer2 }, { type: i0.NgZone }]; }, propDecorators: { item: [{
|
|
593
|
+
type: Input
|
|
594
|
+
}], axes: [{
|
|
595
|
+
type: Input
|
|
596
|
+
}] } });
|
|
597
|
+
|
|
598
|
+
/**
|
|
599
|
+
* @hidden
|
|
600
|
+
*/
|
|
601
|
+
class DraggableChipDirective {
|
|
602
|
+
constructor(draggable, element, zone, service, cue) {
|
|
603
|
+
this.draggable = draggable;
|
|
604
|
+
this.element = element;
|
|
605
|
+
this.zone = zone;
|
|
606
|
+
this.service = service;
|
|
607
|
+
this.cue = cue;
|
|
608
|
+
this.touchActions = 'none';
|
|
609
|
+
this.initialX = {};
|
|
610
|
+
this.initialY = {};
|
|
611
|
+
this.subs = new Subscription();
|
|
612
|
+
}
|
|
613
|
+
get pointerEvents() {
|
|
614
|
+
return this.drag ? 'none' : undefined;
|
|
615
|
+
}
|
|
616
|
+
ngOnInit() {
|
|
617
|
+
this.zone.runOutsideAngular(() => this.subs.add(this.draggable.kendoPress
|
|
618
|
+
.subscribe((event) => {
|
|
619
|
+
if (isDocumentAvailable()) {
|
|
620
|
+
this.cue.create();
|
|
621
|
+
this.cue.attach();
|
|
622
|
+
this.initialX.current = event.clientX;
|
|
623
|
+
this.initialY.current = event.clientY;
|
|
624
|
+
}
|
|
625
|
+
})));
|
|
626
|
+
this.zone.runOutsideAngular(() => this.subs.add(this.draggable.kendoDrag
|
|
627
|
+
.subscribe((event) => {
|
|
628
|
+
if (isDocumentAvailable()) {
|
|
629
|
+
if (Math.abs(this.initialX.current - event.clientX) < 10 &&
|
|
630
|
+
Math.abs(this.initialY.current - event.clientY) < 10) {
|
|
631
|
+
return;
|
|
632
|
+
}
|
|
633
|
+
if (this.element.nativeElement) {
|
|
634
|
+
this.element.nativeElement.style.transform = `translate(${event.clientX - this.initialX.current}px, ${event.clientY - this.initialY.current}px)`;
|
|
635
|
+
}
|
|
636
|
+
}
|
|
637
|
+
this.drag = true;
|
|
638
|
+
this.service.parseConfiguratorState({ type: PIVOT_CONFIGURATOR_ACTION.setDragItem, payload: this.item });
|
|
639
|
+
})));
|
|
640
|
+
this.zone.runOutsideAngular(() => this.subs.add(this.draggable.kendoRelease
|
|
641
|
+
.subscribe(() => {
|
|
642
|
+
this.drag = false;
|
|
643
|
+
if (this.service.state.dragItem) {
|
|
644
|
+
if (isDocumentAvailable()) {
|
|
645
|
+
if (this.element.nativeElement) {
|
|
646
|
+
this.element.nativeElement.style.transform = '';
|
|
647
|
+
}
|
|
648
|
+
this.cue.remove();
|
|
649
|
+
}
|
|
650
|
+
this.service.parseConfiguratorState({ type: PIVOT_CONFIGURATOR_ACTION.drop, payload: this.item });
|
|
651
|
+
this.service.state.dragItem = null;
|
|
652
|
+
this.service.state.dropDirection = null;
|
|
653
|
+
this.service.state.dropTarget = null;
|
|
654
|
+
this.service.state.dropZone = null;
|
|
655
|
+
}
|
|
656
|
+
})));
|
|
657
|
+
}
|
|
658
|
+
ngOnDestroy() {
|
|
659
|
+
this.subs.unsubscribe();
|
|
660
|
+
}
|
|
661
|
+
}
|
|
662
|
+
DraggableChipDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: DraggableChipDirective, deps: [{ token: i3.DraggableDirective, optional: true }, { token: i0.ElementRef }, { token: i0.NgZone }, { token: ConfiguratorService }, { token: DropCueService }], target: i0.ɵɵFactoryTarget.Directive });
|
|
663
|
+
DraggableChipDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: DraggableChipDirective, selector: "[kendoChipDraggable]", inputs: { item: "item" }, host: { properties: { "style.pointerEvents": "this.pointerEvents", "style.touch-action": "this.touchActions" } }, ngImport: i0 });
|
|
664
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: DraggableChipDirective, decorators: [{
|
|
665
|
+
type: Directive,
|
|
666
|
+
args: [{
|
|
667
|
+
selector: '[kendoChipDraggable]'
|
|
668
|
+
}]
|
|
669
|
+
}], ctorParameters: function () { return [{ type: i3.DraggableDirective, decorators: [{
|
|
670
|
+
type: Optional
|
|
671
|
+
}] }, { type: i0.ElementRef }, { type: i0.NgZone }, { type: ConfiguratorService }, { type: DropCueService }]; }, propDecorators: { pointerEvents: [{
|
|
672
|
+
type: HostBinding,
|
|
673
|
+
args: ['style.pointerEvents']
|
|
674
|
+
}], touchActions: [{
|
|
675
|
+
type: HostBinding,
|
|
676
|
+
args: ['style.touch-action']
|
|
677
|
+
}], item: [{
|
|
678
|
+
type: Input
|
|
679
|
+
}] } });
|
|
680
|
+
|
|
681
|
+
/**
|
|
682
|
+
* @hidden
|
|
683
|
+
* Represents the Kendo UI PivotGrid Configurator component for Angular.
|
|
684
|
+
*/
|
|
685
|
+
class PivotGridConfiguratorComponent {
|
|
686
|
+
constructor(dataService, localization, configuratorService, cdr) {
|
|
687
|
+
this.dataService = dataService;
|
|
688
|
+
this.localization = localization;
|
|
689
|
+
this.configuratorService = configuratorService;
|
|
690
|
+
this.cdr = cdr;
|
|
691
|
+
this.hostClass = true;
|
|
692
|
+
this.horizontal = false;
|
|
693
|
+
this.checked = [];
|
|
694
|
+
this.subs = new Subscription();
|
|
695
|
+
/**
|
|
696
|
+
* A function which determines if a specific node has child nodes.
|
|
697
|
+
*/
|
|
698
|
+
this.hasChildren = (node) => !('hierarchyUniqueName' in node) && !('aggregator' in node);
|
|
699
|
+
/**
|
|
700
|
+
* A function which provides the child nodes for a given parent node.
|
|
701
|
+
*/
|
|
702
|
+
this.children = (node) => {
|
|
703
|
+
if (this.dataService.directive.type === 'olap') {
|
|
704
|
+
const observable = from(this.dataService.directive.fetchChildren(node, this.fields));
|
|
705
|
+
return observable.pipe(mergeMap(value => of(value)));
|
|
706
|
+
}
|
|
707
|
+
return of(node.children);
|
|
708
|
+
};
|
|
709
|
+
}
|
|
710
|
+
ngOnInit() {
|
|
711
|
+
this.subs.add(this.dataService.fields
|
|
712
|
+
.subscribe(res => {
|
|
713
|
+
this.fields = res;
|
|
714
|
+
}));
|
|
715
|
+
this.subs.add(this.dataService.configuredFields
|
|
716
|
+
.subscribe(res => {
|
|
717
|
+
this.originalState = clone(res);
|
|
718
|
+
this.setState(clone(res));
|
|
719
|
+
this.setChecked();
|
|
720
|
+
}));
|
|
721
|
+
this.subs.add(this.configuratorService.configuratorStateChange
|
|
722
|
+
.subscribe(res => {
|
|
723
|
+
this.state = res;
|
|
724
|
+
this.cdr.detectChanges();
|
|
725
|
+
}));
|
|
726
|
+
}
|
|
727
|
+
ngOnDestroy() {
|
|
728
|
+
this.subs.unsubscribe();
|
|
729
|
+
}
|
|
730
|
+
getName(name) {
|
|
731
|
+
return name.toString();
|
|
732
|
+
}
|
|
733
|
+
setState(state) {
|
|
734
|
+
this.state = state;
|
|
735
|
+
this.configuratorService.state = state;
|
|
736
|
+
}
|
|
737
|
+
/**
|
|
738
|
+
* Returns the localized message for a given token
|
|
739
|
+
*/
|
|
740
|
+
messageFor(localizationToken) {
|
|
741
|
+
return this.localization.get(localizationToken);
|
|
742
|
+
}
|
|
743
|
+
/**
|
|
744
|
+
* Retrieves the 'Columns' section item names
|
|
745
|
+
*/
|
|
746
|
+
get columnHierarchies() {
|
|
747
|
+
return this.extractDefaultFields(this.state.columnAxes);
|
|
748
|
+
}
|
|
749
|
+
;
|
|
750
|
+
/**
|
|
751
|
+
* Retrieves the 'Rows' section item names
|
|
752
|
+
*/
|
|
753
|
+
get rowHierarchies() {
|
|
754
|
+
return this.extractDefaultFields(this.state.rowAxes);
|
|
755
|
+
}
|
|
756
|
+
;
|
|
757
|
+
/**
|
|
758
|
+
* Retrieves the 'Value' section item names
|
|
759
|
+
*/
|
|
760
|
+
get measureHierarchies() {
|
|
761
|
+
return this.extractDefaultFields(this.state.measureAxes);
|
|
762
|
+
}
|
|
763
|
+
;
|
|
764
|
+
/**
|
|
765
|
+
* Constructs an array with all selected fields.
|
|
766
|
+
* @param fields - used for when child nodes are loaded on demand.
|
|
767
|
+
* Child nodes are concatinated to the root level nodes.
|
|
768
|
+
*/
|
|
769
|
+
setChecked(fields = []) {
|
|
770
|
+
const allFields = [...this.fields, ...fields];
|
|
771
|
+
const checked = this.getFieldsFlatMap(allFields).filter((f) => [
|
|
772
|
+
...this.columnHierarchies,
|
|
773
|
+
...this.rowHierarchies,
|
|
774
|
+
...this.measureHierarchies
|
|
775
|
+
].some((h) => (h === f.uniqueName || h === f.defaultHierarchy)));
|
|
776
|
+
this.checked = checked;
|
|
777
|
+
}
|
|
778
|
+
/**
|
|
779
|
+
* A function which determines if a specific node is checked/
|
|
780
|
+
*/
|
|
781
|
+
isItemChecked(node) {
|
|
782
|
+
var _a, _b;
|
|
783
|
+
const res = this.checked.some(s => node.defaultHierarchy
|
|
784
|
+
? s.defaultHierarchy === node.defaultHierarchy
|
|
785
|
+
: s.uniqueName === node.uniqueName)
|
|
786
|
+
|| (((_a = node.children) === null || _a === void 0 ? void 0 : _a.length) && ((_b = node.children) === null || _b === void 0 ? void 0 : _b.every((c) => c.checked)));
|
|
787
|
+
return res || null;
|
|
788
|
+
}
|
|
789
|
+
/**
|
|
790
|
+
* Determines if a checkbox should be rendered.
|
|
791
|
+
*/
|
|
792
|
+
isSelectable(node) {
|
|
793
|
+
const hasChildren = !('hierarchyUniqueName' in node) && !('aggregator' in node);
|
|
794
|
+
return !Boolean((!hasChildren && !node.aggregator && !node.measure)
|
|
795
|
+
|| (node.type === 2)
|
|
796
|
+
|| node.uniqueName === '[KPIs]');
|
|
797
|
+
}
|
|
798
|
+
/**
|
|
799
|
+
* Check if the newly loaded child nodes have checked items.
|
|
800
|
+
* (Only for OLAP data-binding directive)
|
|
801
|
+
*/
|
|
802
|
+
handleChildrenLoaded(event) {
|
|
803
|
+
if (this.dataService.directive.type === 'local') {
|
|
804
|
+
return;
|
|
805
|
+
}
|
|
806
|
+
const fields = event.children.map(item => item.dataItem);
|
|
807
|
+
this.setChecked(fields);
|
|
808
|
+
}
|
|
809
|
+
handleCheckedChange(event, item) {
|
|
810
|
+
if (event.target.checked) {
|
|
811
|
+
this.checked = [...this.checked, item];
|
|
812
|
+
}
|
|
813
|
+
else {
|
|
814
|
+
const itemIndex = this.checked.findIndex(checkedItem => checkedItem.uniqueName === item.uniqueName);
|
|
815
|
+
this.checked.splice(itemIndex, 1);
|
|
816
|
+
}
|
|
817
|
+
const action = {
|
|
818
|
+
type: 'PIVOT_CONFIGURATOR_ACTION_TOGGLE_SELECTION',
|
|
819
|
+
payload: item
|
|
820
|
+
};
|
|
821
|
+
this.configuratorService.parseConfiguratorState(action);
|
|
822
|
+
}
|
|
823
|
+
handleSubmit() {
|
|
824
|
+
this.dataService.configuratorFieldChange.emit(this.state);
|
|
825
|
+
}
|
|
826
|
+
/**
|
|
827
|
+
* Reset the configurator to the last saved state
|
|
828
|
+
*/
|
|
829
|
+
handleReset() {
|
|
830
|
+
this.setState(clone(this.originalState));
|
|
831
|
+
this.setChecked();
|
|
832
|
+
}
|
|
833
|
+
/**
|
|
834
|
+
* Flattens all available fields.
|
|
835
|
+
*/
|
|
836
|
+
getFieldsFlatMap(nodes = []) {
|
|
837
|
+
let result = [...nodes];
|
|
838
|
+
(nodes || []).forEach((child) => {
|
|
839
|
+
result = result.concat(this.getFieldsFlatMap(child.children));
|
|
840
|
+
});
|
|
841
|
+
return result;
|
|
842
|
+
}
|
|
843
|
+
/**
|
|
844
|
+
* Creates an array containing only the field names, e.g. '[Date].[Calendar]' or 'Product'
|
|
845
|
+
*/
|
|
846
|
+
extractDefaultFields(columns = []) {
|
|
847
|
+
const result = new Set();
|
|
848
|
+
columns.forEach((column) => {
|
|
849
|
+
result.add(String(column.name));
|
|
850
|
+
});
|
|
851
|
+
return Array.from(result);
|
|
852
|
+
}
|
|
853
|
+
;
|
|
854
|
+
}
|
|
855
|
+
PivotGridConfiguratorComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PivotGridConfiguratorComponent, deps: [{ token: PivotGridDataService }, { token: i2.LocalizationService }, { token: ConfiguratorService }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
856
|
+
PivotGridConfiguratorComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: PivotGridConfiguratorComponent, selector: "kendo-pivotgrid-configurator", inputs: { horizontal: "horizontal" }, host: { properties: { "class.k-pivotgrid-configurator": "this.hostClass" } }, providers: [
|
|
857
|
+
ConfiguratorService,
|
|
858
|
+
DropCueService
|
|
859
|
+
], ngImport: i0, template: `
|
|
860
|
+
<div
|
|
861
|
+
class="k-pivotgrid-configurator-panel k-pivotgrid-configurator-push"
|
|
862
|
+
[ngClass]="{
|
|
863
|
+
'k-pivotgrid-configurator-horizontal': horizontal,
|
|
864
|
+
'k-pivotgrid-configurator-vertical': !horizontal
|
|
865
|
+
}"
|
|
866
|
+
>
|
|
867
|
+
<div class="k-pivotgrid-configurator-header">
|
|
868
|
+
<div class="k-pivotgrid-configurator-header-text">{{messageFor('configuratorHeaderText')}}</div>
|
|
869
|
+
</div>
|
|
870
|
+
|
|
871
|
+
<div class="k-pivotgrid-configurator-content">
|
|
872
|
+
<div class="k-form" [class.k-form-horizontal]="horizontal">
|
|
873
|
+
<div class="k-form-field-wrapper">
|
|
874
|
+
<div class="k-form-field">
|
|
875
|
+
<span class="k-label">{{messageFor('configuratorFieldsText')}}</span>
|
|
876
|
+
</div>
|
|
877
|
+
|
|
878
|
+
<div class="k-form-field">
|
|
879
|
+
<div class="k-fields-list-wrapper">
|
|
880
|
+
<kendo-treeview
|
|
881
|
+
[nodes]="fields"
|
|
882
|
+
textField="caption"
|
|
883
|
+
[children]="children"
|
|
884
|
+
[hasChildren]="hasChildren"
|
|
885
|
+
kendoTreeViewExpandable
|
|
886
|
+
(childrenLoaded)="handleChildrenLoaded($event)"
|
|
887
|
+
>
|
|
888
|
+
<ng-template kendoTreeViewNodeTemplate let-dataItem>
|
|
889
|
+
<input kendoCheckBox
|
|
890
|
+
*ngIf="isSelectable(dataItem)"
|
|
891
|
+
type="checkbox"
|
|
892
|
+
kendoCheckBox
|
|
893
|
+
[checked]="isItemChecked(dataItem)"
|
|
894
|
+
(change)="handleCheckedChange($event, dataItem)"/>
|
|
895
|
+
{{ dataItem.caption }}
|
|
896
|
+
</ng-template>
|
|
897
|
+
</kendo-treeview>
|
|
898
|
+
|
|
899
|
+
</div>
|
|
900
|
+
</div>
|
|
901
|
+
</div>
|
|
902
|
+
|
|
903
|
+
<div *ngIf="horizontal; else verticalTemplate" class="k-form-field-wrapper">
|
|
904
|
+
<ng-container *ngTemplateOutlet="verticalTemplate"></ng-container>
|
|
905
|
+
</div>
|
|
906
|
+
|
|
907
|
+
<ng-template #verticalTemplate>
|
|
908
|
+
<div class="k-form-field" kendoDropTarget axes="columnAxes">
|
|
909
|
+
<span class="k-label">{{messageFor('configuratorColumnsText')}}</span>
|
|
910
|
+
</div>
|
|
911
|
+
|
|
912
|
+
<kendo-chiplist
|
|
913
|
+
*ngIf="state.columnAxes && state.columnAxes.length; else noColumnAxes"
|
|
914
|
+
kendoDropTarget
|
|
915
|
+
axes="columnAxes"
|
|
916
|
+
>
|
|
917
|
+
<kendo-chip *ngFor="let item of state.columnAxes"
|
|
918
|
+
kendoChipDraggable
|
|
919
|
+
kendoDraggable
|
|
920
|
+
kendoDropTarget
|
|
921
|
+
[item]="item"
|
|
922
|
+
axes="columnAxes"
|
|
923
|
+
rounded="full"
|
|
924
|
+
[removable]="true"
|
|
925
|
+
>
|
|
926
|
+
{{ getName(item.name) }}
|
|
927
|
+
</kendo-chip>
|
|
928
|
+
</kendo-chiplist>
|
|
929
|
+
|
|
930
|
+
<ng-template #noColumnAxes>
|
|
931
|
+
<div class="k-settings-description" kendoDropTarget axes="columnAxes">
|
|
932
|
+
Select some fields to begin setup
|
|
933
|
+
</div>
|
|
934
|
+
</ng-template>
|
|
935
|
+
|
|
936
|
+
<div class="k-form-field" kendoDropTarget axes="rowAxes">
|
|
937
|
+
<span class="k-label">{{messageFor('configuratorRowsText')}}</span>
|
|
938
|
+
</div>
|
|
939
|
+
|
|
940
|
+
<kendo-chiplist
|
|
941
|
+
*ngIf="state.rowAxes && state.rowAxes.length; else noRowAxes"
|
|
942
|
+
kendoDropTarget
|
|
943
|
+
axes="rowAxes"
|
|
944
|
+
>
|
|
945
|
+
<kendo-chip *ngFor="let item of state.rowAxes"
|
|
946
|
+
kendoChipDraggable
|
|
947
|
+
kendoDraggable
|
|
948
|
+
kendoDropTarget
|
|
949
|
+
[item]="item"
|
|
950
|
+
axes="rowAxes"
|
|
951
|
+
rounded="full"
|
|
952
|
+
[removable]="true"
|
|
953
|
+
>
|
|
954
|
+
{{ getName(item.name) }}
|
|
955
|
+
</kendo-chip>
|
|
956
|
+
</kendo-chiplist>
|
|
957
|
+
|
|
958
|
+
<ng-template #noRowAxes>
|
|
959
|
+
<div class="k-settings-description" kendoDropTarget axes="rowAxes">
|
|
960
|
+
Select some fields to begin setup
|
|
961
|
+
</div>
|
|
962
|
+
</ng-template>
|
|
963
|
+
</ng-template>
|
|
964
|
+
|
|
965
|
+
<div *ngIf="horizontal; else elseTpl2" class="k-form-field-wrapper">
|
|
966
|
+
<ng-container *ngTemplateOutlet="elseTpl2"></ng-container>
|
|
967
|
+
</div>
|
|
968
|
+
|
|
969
|
+
<ng-template #elseTpl2>
|
|
970
|
+
<div class="k-form-field" kendoDropTarget axes="measureAxes">
|
|
971
|
+
<span class="k-label">{{messageFor('configuratorValuesText')}}</span>
|
|
972
|
+
</div>
|
|
973
|
+
|
|
974
|
+
<kendo-chiplist
|
|
975
|
+
*ngIf="state.measureAxes && state.measureAxes.length; else noMeasureAxes"
|
|
976
|
+
kendoDropTarget
|
|
977
|
+
axes="measureAxes"
|
|
978
|
+
>
|
|
979
|
+
<kendo-chip *ngFor="let item of state.measureAxes"
|
|
980
|
+
kendoChipDraggable
|
|
981
|
+
kendoDraggable
|
|
982
|
+
kendoDropTarget
|
|
983
|
+
[item]="item"
|
|
984
|
+
axes="measureAxes"
|
|
985
|
+
|
|
986
|
+
rounded="full"
|
|
987
|
+
[removable]="true"
|
|
988
|
+
>
|
|
989
|
+
{{ getName(item.name) }}
|
|
990
|
+
</kendo-chip>
|
|
991
|
+
</kendo-chiplist>
|
|
992
|
+
|
|
993
|
+
<ng-template #noMeasureAxes>
|
|
994
|
+
<div class="k-settings-description" kendoDropTarget axes="measureAxes">
|
|
995
|
+
Select some fields to begin setup
|
|
996
|
+
</div>
|
|
997
|
+
</ng-template>
|
|
998
|
+
</ng-template>
|
|
999
|
+
|
|
1000
|
+
</div>
|
|
1001
|
+
</div>
|
|
1002
|
+
<div class="k-pivotgrid-configurator-actions k-actions k-hstack k-justify-content-end">
|
|
1003
|
+
<button kendoButton type="button" (click)="handleReset()">{{messageFor('configuratorCancelButtonText')}}</button>
|
|
1004
|
+
<button kendoButton themeColor="primary" type="button" (click)="handleSubmit()">{{messageFor('configuratorApplyButtonText')}}</button>
|
|
1005
|
+
</div>
|
|
1006
|
+
</div>
|
|
1007
|
+
`, isInline: true, components: [{ type: i4.TreeViewComponent, selector: "kendo-treeview", inputs: ["filterInputPlaceholder", "expandDisabledNodes", "animate", "nodeTemplate", "loadMoreButtonTemplate", "trackBy", "nodes", "textField", "hasChildren", "isChecked", "isDisabled", "isExpanded", "isSelected", "isVisible", "navigable", "children", "loadOnDemand", "filterable", "filter", "size", "disableParentNodesOnly"], outputs: ["childrenLoaded", "blur", "focus", "expand", "collapse", "nodeDragStart", "nodeDrag", "filterStateChange", "nodeDrop", "nodeDragEnd", "addItem", "removeItem", "checkedChange", "selectionChange", "filterChange", "nodeClick", "nodeDblClick"], exportAs: ["kendoTreeView"] }, { type: i5.ChipListComponent, selector: "kendo-chiplist, kendo-chip-list", inputs: ["selection", "size"], outputs: ["selectedChange", "remove"] }, { type: i5.ChipComponent, selector: "kendo-chip", inputs: ["label", "icon", "iconClass", "avatarClass", "selected", "removable", "removeIcon", "disabled", "size", "rounded", "fillMode", "themeColor"], outputs: ["remove", "contentClick"] }], directives: [{ type: i6.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i4.ExpandDirective, selector: "[kendoTreeViewExpandable]", inputs: ["isExpanded", "expandBy", "expandOnFilter", "expandedKeys"], outputs: ["expandedKeysChange"] }, { type: i4.NodeTemplateDirective, selector: "[kendoTreeViewNodeTemplate]" }, { type: i6.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i7.CheckBoxDirective, selector: "input[kendoCheckBox]", inputs: ["size", "rounded"] }, { type: i6.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }, { type: DropTargetDirective, selector: "[kendoDropTarget]", inputs: ["item", "axes"] }, { type: i6.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: DraggableChipDirective, selector: "[kendoChipDraggable]", inputs: ["item"] }, { type: i3.DraggableDirective, selector: "[kendoDraggable]", inputs: ["enableDrag"], outputs: ["kendoPress", "kendoDrag", "kendoRelease"] }, { type: i5.ButtonDirective, selector: "button[kendoButton], span[kendoButton]", inputs: ["toggleable", "togglable", "selected", "tabIndex", "icon", "iconClass", "imageUrl", "disabled", "size", "rounded", "fillMode", "themeColor", "role", "primary", "look"], outputs: ["selectedChange", "click"], exportAs: ["kendoButton"] }] });
|
|
1008
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PivotGridConfiguratorComponent, decorators: [{
|
|
1009
|
+
type: Component,
|
|
1010
|
+
args: [{
|
|
1011
|
+
selector: 'kendo-pivotgrid-configurator',
|
|
1012
|
+
providers: [
|
|
1013
|
+
ConfiguratorService,
|
|
1014
|
+
DropCueService
|
|
1015
|
+
],
|
|
1016
|
+
template: `
|
|
1017
|
+
<div
|
|
1018
|
+
class="k-pivotgrid-configurator-panel k-pivotgrid-configurator-push"
|
|
1019
|
+
[ngClass]="{
|
|
1020
|
+
'k-pivotgrid-configurator-horizontal': horizontal,
|
|
1021
|
+
'k-pivotgrid-configurator-vertical': !horizontal
|
|
1022
|
+
}"
|
|
1023
|
+
>
|
|
1024
|
+
<div class="k-pivotgrid-configurator-header">
|
|
1025
|
+
<div class="k-pivotgrid-configurator-header-text">{{messageFor('configuratorHeaderText')}}</div>
|
|
1026
|
+
</div>
|
|
1027
|
+
|
|
1028
|
+
<div class="k-pivotgrid-configurator-content">
|
|
1029
|
+
<div class="k-form" [class.k-form-horizontal]="horizontal">
|
|
1030
|
+
<div class="k-form-field-wrapper">
|
|
1031
|
+
<div class="k-form-field">
|
|
1032
|
+
<span class="k-label">{{messageFor('configuratorFieldsText')}}</span>
|
|
1033
|
+
</div>
|
|
1034
|
+
|
|
1035
|
+
<div class="k-form-field">
|
|
1036
|
+
<div class="k-fields-list-wrapper">
|
|
1037
|
+
<kendo-treeview
|
|
1038
|
+
[nodes]="fields"
|
|
1039
|
+
textField="caption"
|
|
1040
|
+
[children]="children"
|
|
1041
|
+
[hasChildren]="hasChildren"
|
|
1042
|
+
kendoTreeViewExpandable
|
|
1043
|
+
(childrenLoaded)="handleChildrenLoaded($event)"
|
|
1044
|
+
>
|
|
1045
|
+
<ng-template kendoTreeViewNodeTemplate let-dataItem>
|
|
1046
|
+
<input kendoCheckBox
|
|
1047
|
+
*ngIf="isSelectable(dataItem)"
|
|
1048
|
+
type="checkbox"
|
|
1049
|
+
kendoCheckBox
|
|
1050
|
+
[checked]="isItemChecked(dataItem)"
|
|
1051
|
+
(change)="handleCheckedChange($event, dataItem)"/>
|
|
1052
|
+
{{ dataItem.caption }}
|
|
1053
|
+
</ng-template>
|
|
1054
|
+
</kendo-treeview>
|
|
1055
|
+
|
|
1056
|
+
</div>
|
|
1057
|
+
</div>
|
|
1058
|
+
</div>
|
|
1059
|
+
|
|
1060
|
+
<div *ngIf="horizontal; else verticalTemplate" class="k-form-field-wrapper">
|
|
1061
|
+
<ng-container *ngTemplateOutlet="verticalTemplate"></ng-container>
|
|
1062
|
+
</div>
|
|
1063
|
+
|
|
1064
|
+
<ng-template #verticalTemplate>
|
|
1065
|
+
<div class="k-form-field" kendoDropTarget axes="columnAxes">
|
|
1066
|
+
<span class="k-label">{{messageFor('configuratorColumnsText')}}</span>
|
|
1067
|
+
</div>
|
|
1068
|
+
|
|
1069
|
+
<kendo-chiplist
|
|
1070
|
+
*ngIf="state.columnAxes && state.columnAxes.length; else noColumnAxes"
|
|
1071
|
+
kendoDropTarget
|
|
1072
|
+
axes="columnAxes"
|
|
1073
|
+
>
|
|
1074
|
+
<kendo-chip *ngFor="let item of state.columnAxes"
|
|
1075
|
+
kendoChipDraggable
|
|
1076
|
+
kendoDraggable
|
|
1077
|
+
kendoDropTarget
|
|
1078
|
+
[item]="item"
|
|
1079
|
+
axes="columnAxes"
|
|
1080
|
+
rounded="full"
|
|
1081
|
+
[removable]="true"
|
|
1082
|
+
>
|
|
1083
|
+
{{ getName(item.name) }}
|
|
1084
|
+
</kendo-chip>
|
|
1085
|
+
</kendo-chiplist>
|
|
1086
|
+
|
|
1087
|
+
<ng-template #noColumnAxes>
|
|
1088
|
+
<div class="k-settings-description" kendoDropTarget axes="columnAxes">
|
|
1089
|
+
Select some fields to begin setup
|
|
1090
|
+
</div>
|
|
1091
|
+
</ng-template>
|
|
1092
|
+
|
|
1093
|
+
<div class="k-form-field" kendoDropTarget axes="rowAxes">
|
|
1094
|
+
<span class="k-label">{{messageFor('configuratorRowsText')}}</span>
|
|
1095
|
+
</div>
|
|
1096
|
+
|
|
1097
|
+
<kendo-chiplist
|
|
1098
|
+
*ngIf="state.rowAxes && state.rowAxes.length; else noRowAxes"
|
|
1099
|
+
kendoDropTarget
|
|
1100
|
+
axes="rowAxes"
|
|
1101
|
+
>
|
|
1102
|
+
<kendo-chip *ngFor="let item of state.rowAxes"
|
|
1103
|
+
kendoChipDraggable
|
|
1104
|
+
kendoDraggable
|
|
1105
|
+
kendoDropTarget
|
|
1106
|
+
[item]="item"
|
|
1107
|
+
axes="rowAxes"
|
|
1108
|
+
rounded="full"
|
|
1109
|
+
[removable]="true"
|
|
1110
|
+
>
|
|
1111
|
+
{{ getName(item.name) }}
|
|
1112
|
+
</kendo-chip>
|
|
1113
|
+
</kendo-chiplist>
|
|
1114
|
+
|
|
1115
|
+
<ng-template #noRowAxes>
|
|
1116
|
+
<div class="k-settings-description" kendoDropTarget axes="rowAxes">
|
|
1117
|
+
Select some fields to begin setup
|
|
1118
|
+
</div>
|
|
1119
|
+
</ng-template>
|
|
1120
|
+
</ng-template>
|
|
1121
|
+
|
|
1122
|
+
<div *ngIf="horizontal; else elseTpl2" class="k-form-field-wrapper">
|
|
1123
|
+
<ng-container *ngTemplateOutlet="elseTpl2"></ng-container>
|
|
1124
|
+
</div>
|
|
1125
|
+
|
|
1126
|
+
<ng-template #elseTpl2>
|
|
1127
|
+
<div class="k-form-field" kendoDropTarget axes="measureAxes">
|
|
1128
|
+
<span class="k-label">{{messageFor('configuratorValuesText')}}</span>
|
|
1129
|
+
</div>
|
|
1130
|
+
|
|
1131
|
+
<kendo-chiplist
|
|
1132
|
+
*ngIf="state.measureAxes && state.measureAxes.length; else noMeasureAxes"
|
|
1133
|
+
kendoDropTarget
|
|
1134
|
+
axes="measureAxes"
|
|
1135
|
+
>
|
|
1136
|
+
<kendo-chip *ngFor="let item of state.measureAxes"
|
|
1137
|
+
kendoChipDraggable
|
|
1138
|
+
kendoDraggable
|
|
1139
|
+
kendoDropTarget
|
|
1140
|
+
[item]="item"
|
|
1141
|
+
axes="measureAxes"
|
|
1142
|
+
|
|
1143
|
+
rounded="full"
|
|
1144
|
+
[removable]="true"
|
|
1145
|
+
>
|
|
1146
|
+
{{ getName(item.name) }}
|
|
1147
|
+
</kendo-chip>
|
|
1148
|
+
</kendo-chiplist>
|
|
1149
|
+
|
|
1150
|
+
<ng-template #noMeasureAxes>
|
|
1151
|
+
<div class="k-settings-description" kendoDropTarget axes="measureAxes">
|
|
1152
|
+
Select some fields to begin setup
|
|
1153
|
+
</div>
|
|
1154
|
+
</ng-template>
|
|
1155
|
+
</ng-template>
|
|
1156
|
+
|
|
1157
|
+
</div>
|
|
1158
|
+
</div>
|
|
1159
|
+
<div class="k-pivotgrid-configurator-actions k-actions k-hstack k-justify-content-end">
|
|
1160
|
+
<button kendoButton type="button" (click)="handleReset()">{{messageFor('configuratorCancelButtonText')}}</button>
|
|
1161
|
+
<button kendoButton themeColor="primary" type="button" (click)="handleSubmit()">{{messageFor('configuratorApplyButtonText')}}</button>
|
|
1162
|
+
</div>
|
|
1163
|
+
</div>
|
|
1164
|
+
`
|
|
1165
|
+
}]
|
|
1166
|
+
}], ctorParameters: function () { return [{ type: PivotGridDataService }, { type: i2.LocalizationService }, { type: ConfiguratorService }, { type: i0.ChangeDetectorRef }]; }, propDecorators: { hostClass: [{
|
|
1167
|
+
type: HostBinding,
|
|
1168
|
+
args: ['class.k-pivotgrid-configurator']
|
|
1169
|
+
}], horizontal: [{
|
|
1170
|
+
type: Input
|
|
1171
|
+
}] } });
|
|
1172
|
+
|
|
1173
|
+
/**
|
|
1174
|
+
* @hidden
|
|
1175
|
+
*/
|
|
1176
|
+
class PivotGridMessages extends ComponentMessages {
|
|
1177
|
+
}
|
|
1178
|
+
PivotGridMessages.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PivotGridMessages, deps: null, target: i0.ɵɵFactoryTarget.Directive });
|
|
1179
|
+
PivotGridMessages.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: PivotGridMessages, inputs: { fieldMenuFilterItemLabel: "fieldMenuFilterItemLabel", fieldMenuSortAscendingItemLabel: "fieldMenuSortAscendingItemLabel", fieldMenuSortDescendingItemLabel: "fieldMenuSortDescendingItemLabel", filterInputLabel: "filterInputLabel", filterOperatorsDropDownLabel: "filterOperatorsDropDownLabel", filterEqOperator: "filterEqOperator", filterNotEqOperator: "filterNotEqOperator", filterIsNullOperator: "filterIsNullOperator", filterIsNotNullOperator: "filterIsNotNullOperator", filterIsEmptyOperator: "filterIsEmptyOperator", filterIsNotEmptyOperator: "filterIsNotEmptyOperator", filterStartsWithOperator: "filterStartsWithOperator", filterContainsOperator: "filterContainsOperator", filterNotContainsOperator: "filterNotContainsOperator", filterEndsWithOperator: "filterEndsWithOperator", filterFilterButton: "filterFilterButton", filterClearButton: "filterClearButton", loading: "loading", emptyCellLabel: "emptyCellLabel", configuratorButtonText: "configuratorButtonText", configuratorHeaderText: "configuratorHeaderText", configuratorFieldsText: "configuratorFieldsText", configuratorColumnsText: "configuratorColumnsText", configuratorRowsText: "configuratorRowsText", configuratorValuesText: "configuratorValuesText", configuratorCancelButtonText: "configuratorCancelButtonText", configuratorApplyButtonText: "configuratorApplyButtonText" }, usesInheritance: true, ngImport: i0 });
|
|
1180
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PivotGridMessages, decorators: [{
|
|
1181
|
+
type: Directive
|
|
1182
|
+
}], propDecorators: { fieldMenuFilterItemLabel: [{
|
|
1183
|
+
type: Input
|
|
1184
|
+
}], fieldMenuSortAscendingItemLabel: [{
|
|
1185
|
+
type: Input
|
|
1186
|
+
}], fieldMenuSortDescendingItemLabel: [{
|
|
1187
|
+
type: Input
|
|
1188
|
+
}], filterInputLabel: [{
|
|
1189
|
+
type: Input
|
|
1190
|
+
}], filterOperatorsDropDownLabel: [{
|
|
1191
|
+
type: Input
|
|
1192
|
+
}], filterEqOperator: [{
|
|
1193
|
+
type: Input
|
|
1194
|
+
}], filterNotEqOperator: [{
|
|
1195
|
+
type: Input
|
|
1196
|
+
}], filterIsNullOperator: [{
|
|
1197
|
+
type: Input
|
|
1198
|
+
}], filterIsNotNullOperator: [{
|
|
1199
|
+
type: Input
|
|
1200
|
+
}], filterIsEmptyOperator: [{
|
|
1201
|
+
type: Input
|
|
1202
|
+
}], filterIsNotEmptyOperator: [{
|
|
1203
|
+
type: Input
|
|
1204
|
+
}], filterStartsWithOperator: [{
|
|
1205
|
+
type: Input
|
|
1206
|
+
}], filterContainsOperator: [{
|
|
1207
|
+
type: Input
|
|
1208
|
+
}], filterNotContainsOperator: [{
|
|
1209
|
+
type: Input
|
|
1210
|
+
}], filterEndsWithOperator: [{
|
|
1211
|
+
type: Input
|
|
1212
|
+
}], filterFilterButton: [{
|
|
1213
|
+
type: Input
|
|
1214
|
+
}], filterClearButton: [{
|
|
1215
|
+
type: Input
|
|
1216
|
+
}], loading: [{
|
|
1217
|
+
type: Input
|
|
1218
|
+
}], emptyCellLabel: [{
|
|
1219
|
+
type: Input
|
|
1220
|
+
}], configuratorButtonText: [{
|
|
1221
|
+
type: Input
|
|
1222
|
+
}], configuratorHeaderText: [{
|
|
1223
|
+
type: Input
|
|
1224
|
+
}], configuratorFieldsText: [{
|
|
1225
|
+
type: Input
|
|
1226
|
+
}], configuratorColumnsText: [{
|
|
1227
|
+
type: Input
|
|
1228
|
+
}], configuratorRowsText: [{
|
|
1229
|
+
type: Input
|
|
1230
|
+
}], configuratorValuesText: [{
|
|
1231
|
+
type: Input
|
|
1232
|
+
}], configuratorCancelButtonText: [{
|
|
1233
|
+
type: Input
|
|
1234
|
+
}], configuratorApplyButtonText: [{
|
|
1235
|
+
type: Input
|
|
1236
|
+
}] } });
|
|
1237
|
+
|
|
1238
|
+
/**
|
|
1239
|
+
* @hidden
|
|
1240
|
+
*/
|
|
1241
|
+
class LocalizedMessagesDirective extends PivotGridMessages {
|
|
1242
|
+
constructor(service) {
|
|
1243
|
+
super();
|
|
1244
|
+
this.service = service;
|
|
1245
|
+
}
|
|
1246
|
+
}
|
|
1247
|
+
LocalizedMessagesDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: LocalizedMessagesDirective, deps: [{ token: i2.LocalizationService }], target: i0.ɵɵFactoryTarget.Directive });
|
|
1248
|
+
LocalizedMessagesDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: LocalizedMessagesDirective, selector: "[kendoPivotGridLocalizedMessages]", providers: [
|
|
1249
|
+
{
|
|
1250
|
+
provide: PivotGridMessages,
|
|
1251
|
+
useExisting: forwardRef(() => LocalizedMessagesDirective)
|
|
1252
|
+
}
|
|
1253
|
+
], usesInheritance: true, ngImport: i0 });
|
|
1254
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: LocalizedMessagesDirective, decorators: [{
|
|
1255
|
+
type: Directive,
|
|
259
1256
|
args: [{
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
<tr *ngFor="let row of rows; index as rowIndex"
|
|
268
|
-
class="k-pivotgrid-row">
|
|
269
|
-
<ng-container *ngFor="let cell of row.cells; index as colIndex">
|
|
270
|
-
<th
|
|
271
|
-
*ngIf="cell && tableType !== 'values'"
|
|
272
|
-
[kendoPivotGridCell]="cell"
|
|
273
|
-
[tableType]="tableType"
|
|
274
|
-
[colIndex]="colIndex"
|
|
275
|
-
[rowIndex]="rowIndex"></th>
|
|
276
|
-
<td
|
|
277
|
-
*ngIf="cell && tableType === 'values'"
|
|
278
|
-
[kendoPivotGridCell]="cell"
|
|
279
|
-
tableType="values"
|
|
280
|
-
[colIndex]="colIndex"
|
|
281
|
-
[rowIndex]="rowIndex"></td>
|
|
282
|
-
</ng-container>
|
|
283
|
-
</tr>
|
|
284
|
-
</tbody>
|
|
285
|
-
</table>
|
|
286
|
-
`
|
|
1257
|
+
providers: [
|
|
1258
|
+
{
|
|
1259
|
+
provide: PivotGridMessages,
|
|
1260
|
+
useExisting: forwardRef(() => LocalizedMessagesDirective)
|
|
1261
|
+
}
|
|
1262
|
+
],
|
|
1263
|
+
selector: '[kendoPivotGridLocalizedMessages]'
|
|
287
1264
|
}]
|
|
288
|
-
}], ctorParameters: function () { return [{ type:
|
|
289
|
-
type: Input
|
|
290
|
-
}] } });
|
|
1265
|
+
}], ctorParameters: function () { return [{ type: i2.LocalizationService }]; } });
|
|
291
1266
|
|
|
292
1267
|
const DEFAULT_LOADER_SETTINGS = {
|
|
293
1268
|
type: 'converging-spinner',
|
|
294
1269
|
themeColor: 'primary',
|
|
295
1270
|
size: 'large'
|
|
296
1271
|
};
|
|
1272
|
+
const DEFAULT_CONFIGURATOR_SETTINGS = {
|
|
1273
|
+
position: 'right',
|
|
1274
|
+
horizontal: false
|
|
1275
|
+
};
|
|
297
1276
|
/**
|
|
298
1277
|
* Represents the Kendo UI PivotGrid component for Angular.
|
|
299
1278
|
*/
|
|
300
1279
|
class PivotGridComponent {
|
|
301
|
-
constructor(hostEl, zone, dataService, _scrollbarWidthService) {
|
|
302
|
-
this.hostEl = hostEl;
|
|
1280
|
+
constructor(hostEl, zone, dataService, localization, _scrollbarWidthService) {
|
|
303
1281
|
this.zone = zone;
|
|
304
1282
|
this.dataService = dataService;
|
|
1283
|
+
this.localization = localization;
|
|
305
1284
|
this.hostClass = true;
|
|
1285
|
+
this.ariaRole = 'grid';
|
|
1286
|
+
/**
|
|
1287
|
+
* Specify the width of the column header and data cells. Value is treated as pixels.
|
|
1288
|
+
*
|
|
1289
|
+
* @default 200
|
|
1290
|
+
*/
|
|
1291
|
+
this.columnHeadersWidth = 200;
|
|
306
1292
|
this.resizeObservers = [];
|
|
307
1293
|
this._loaderSettings = DEFAULT_LOADER_SETTINGS;
|
|
308
1294
|
this.subs = new Subscription();
|
|
1295
|
+
this.rtl = false;
|
|
309
1296
|
this.resizeContainer = (axis, element) => {
|
|
310
1297
|
const isRows = axis === 'Rows';
|
|
311
|
-
const
|
|
1298
|
+
const table = this.table.nativeElement;
|
|
312
1299
|
const size = isRows ? 'offsetHeight' : 'offsetWidth';
|
|
313
|
-
|
|
314
|
-
|
|
1300
|
+
table.style[`gridTemplate${axis}`] = '';
|
|
1301
|
+
table.style[`gridTemplate${axis}`] = `${element[size]}px 1fr`;
|
|
315
1302
|
};
|
|
316
1303
|
this.handleScroll = (event) => {
|
|
317
1304
|
if (event.target === this.valuesTable.nativeElement) {
|
|
@@ -328,6 +1315,30 @@ class PivotGridComponent {
|
|
|
328
1315
|
}
|
|
329
1316
|
};
|
|
330
1317
|
validatePackage(packageMetadata);
|
|
1318
|
+
this.subs.add(this.localization.changes.subscribe(({ rtl }) => {
|
|
1319
|
+
this.rtl = rtl;
|
|
1320
|
+
this.direction = this.rtl ? 'rtl' : 'ltr';
|
|
1321
|
+
}));
|
|
1322
|
+
dataService.wrapper = hostEl.nativeElement;
|
|
1323
|
+
}
|
|
1324
|
+
get rightPositionClass() {
|
|
1325
|
+
var _a;
|
|
1326
|
+
return ((_a = this.configuratorSettings) === null || _a === void 0 ? void 0 : _a.position) === 'right';
|
|
1327
|
+
}
|
|
1328
|
+
get leftPositionClass() {
|
|
1329
|
+
var _a;
|
|
1330
|
+
return ((_a = this.configuratorSettings) === null || _a === void 0 ? void 0 : _a.position) === 'left';
|
|
1331
|
+
}
|
|
1332
|
+
get bottomPositionClass() {
|
|
1333
|
+
var _a;
|
|
1334
|
+
return ((_a = this.configuratorSettings) === null || _a === void 0 ? void 0 : _a.position) === 'bottom';
|
|
1335
|
+
}
|
|
1336
|
+
get topPositionClass() {
|
|
1337
|
+
var _a;
|
|
1338
|
+
return ((_a = this.configuratorSettings) === null || _a === void 0 ? void 0 : _a.position) === 'top';
|
|
1339
|
+
}
|
|
1340
|
+
get dir() {
|
|
1341
|
+
return this.direction;
|
|
331
1342
|
}
|
|
332
1343
|
/**
|
|
333
1344
|
* Specify the type, size and color of the PivotGrid's loader.
|
|
@@ -344,6 +1355,15 @@ class PivotGridComponent {
|
|
|
344
1355
|
get loaderSettings() {
|
|
345
1356
|
return this._loaderSettings;
|
|
346
1357
|
}
|
|
1358
|
+
/**
|
|
1359
|
+
* @hidden
|
|
1360
|
+
*/
|
|
1361
|
+
get loadingText() {
|
|
1362
|
+
return this.localization.get('loading');
|
|
1363
|
+
}
|
|
1364
|
+
get configuratorSettings() {
|
|
1365
|
+
return this.configurator && Object.assign({}, DEFAULT_CONFIGURATOR_SETTINGS, this.configurator);
|
|
1366
|
+
}
|
|
347
1367
|
ngAfterViewInit() {
|
|
348
1368
|
if (isDocumentAvailable()) {
|
|
349
1369
|
this.zone.runOutsideAngular(() => {
|
|
@@ -366,63 +1386,277 @@ class PivotGridComponent {
|
|
|
366
1386
|
this.resizeObservers.forEach(o => o.disconnect());
|
|
367
1387
|
this.subs.unsubscribe();
|
|
368
1388
|
}
|
|
1389
|
+
/**
|
|
1390
|
+
* @hidden
|
|
1391
|
+
*/
|
|
1392
|
+
messageFor(localizationToken) {
|
|
1393
|
+
return this.localization.get(localizationToken);
|
|
1394
|
+
}
|
|
369
1395
|
}
|
|
370
|
-
PivotGridComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PivotGridComponent, deps: [{ token: i0.ElementRef }, { token: i0.NgZone }, { token: PivotGridDataService }, { token: i2
|
|
371
|
-
PivotGridComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: PivotGridComponent, selector: "kendo-pivotgrid", inputs: { loaderSettings: "loaderSettings" }, host: { properties: { "class.k-
|
|
372
|
-
PivotGridDataService
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
<
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
1396
|
+
PivotGridComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PivotGridComponent, deps: [{ token: i0.ElementRef }, { token: i0.NgZone }, { token: PivotGridDataService }, { token: i2.LocalizationService }, { token: i3.ScrollbarWidthService }], target: i0.ɵɵFactoryTarget.Component });
|
|
1397
|
+
PivotGridComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: PivotGridComponent, selector: "kendo-pivotgrid", inputs: { loaderSettings: "loaderSettings", configurator: "configurator", columnHeadersWidth: "columnHeadersWidth" }, host: { properties: { "class.k-d-flex": "this.hostClass", "class.k-pos-relative": "this.hostClass", "class.k-flex-row": "this.rightPositionClass", "class.k-flex-row-reverse": "this.leftPositionClass", "class.k-flex-column": "this.bottomPositionClass", "class.k-flex-column-reverse": "this.topPositionClass", "attr.dir": "this.dir", "attr.role": "this.ariaRole" } }, providers: [
|
|
1398
|
+
PivotGridDataService,
|
|
1399
|
+
LocalizationService,
|
|
1400
|
+
{
|
|
1401
|
+
provide: L10N_PREFIX,
|
|
1402
|
+
useValue: 'kendo.pivotgrid'
|
|
1403
|
+
}
|
|
1404
|
+
], viewQueries: [{ propertyName: "colHeadersTable", first: true, predicate: ["colHeadersTable"], descendants: true, read: ElementRef }, { propertyName: "rowHeadersTable", first: true, predicate: ["rowHeadersTable"], descendants: true, read: ElementRef }, { propertyName: "valuesTable", first: true, predicate: ["valuesTable"], descendants: true, read: ElementRef }, { propertyName: "table", first: true, predicate: ["table"], descendants: true, read: ElementRef }], ngImport: i0, template: `
|
|
1405
|
+
<ng-container kendoPivotGridLocalizedMessages
|
|
1406
|
+
i18n-loading="kendo.pivotgrid.loading|The loading text"
|
|
1407
|
+
loading="Loading"
|
|
1408
|
+
|
|
1409
|
+
i18n-emptyCellLabel="kendo.pivotgrid.emptyCellLabel|The value of the aria-label attribute placed on the focusable empty cell element"
|
|
1410
|
+
emptyCellLabel="PivotGrid Empty Cell"
|
|
1411
|
+
|
|
1412
|
+
i18n-fieldMenuFilterItemLabel="kendo.pivotgrid.fieldMenuFilterItemLabel|The text content of the filter item in the column and row fields menu"
|
|
1413
|
+
fieldMenuFilterItemLabel="Filter"
|
|
1414
|
+
|
|
1415
|
+
i18n-fieldMenuSortAscendingItemLabel="kendo.pivotgrid.fieldMenuSortAscendingItemLabel|The text content of the sort ascending item in the column and row fields menu"
|
|
1416
|
+
fieldMenuSortAscendingItemLabel="Sort ascending"
|
|
1417
|
+
|
|
1418
|
+
i18n-fieldMenuSortDescendingItemLabel="kendo.pivotgrid.fieldMenuSortDescendingItemLabel|The text content of the sort descending item in the column and row fields menu"
|
|
1419
|
+
fieldMenuSortDescendingItemLabel="Sort descending"
|
|
1420
|
+
|
|
1421
|
+
i18n-filterInputLabel="kendo.pivotgrid.filterInputLabel|The label of the filter input"
|
|
1422
|
+
filterInputLabel="{{ '{fields} Filter' }}"
|
|
1423
|
+
|
|
1424
|
+
i18n-filterOperatorsDropDownLabel="kendo.pivotgrid.filterOperatorsDropDownLabel|The label of the filter operators DropDownList"
|
|
1425
|
+
filterOperatorsDropDownLabel="{{ '{fields} Filter Operators' }}"
|
|
1426
|
+
|
|
1427
|
+
i18n-filterEqOperator="kendo.pivotgrid.filterEqOperator|The text of the equal filter operator"
|
|
1428
|
+
filterEqOperator="Is equal to"
|
|
1429
|
+
|
|
1430
|
+
i18n-filterNotEqOperator="kendo.pivotgrid.filterNotEqOperator|The text of the not equal filter operator"
|
|
1431
|
+
filterNotEqOperator="Is not equal to"
|
|
1432
|
+
|
|
1433
|
+
i18n-filterIsNullOperator="kendo.pivotgrid.filterIsNullOperator|The text of the is null filter operator"
|
|
1434
|
+
filterIsNullOperator="Is null"
|
|
1435
|
+
|
|
1436
|
+
i18n-filterIsNotNullOperator="kendo.pivotgrid.filterIsNotNullOperator|The text of the is not null filter operator"
|
|
1437
|
+
filterIsNotNullOperator="Is not null"
|
|
1438
|
+
|
|
1439
|
+
i18n-filterIsEmptyOperator="kendo.pivotgrid.filterIsEmptyOperator|The text of the is empty filter operator"
|
|
1440
|
+
filterIsEmptyOperator="Is empty"
|
|
1441
|
+
|
|
1442
|
+
i18n-filterIsNotEmptyOperator="kendo.pivotgrid.filterIsNotEmptyOperator|The text of the is not empty filter operator"
|
|
1443
|
+
filterIsNotEmptyOperator="Is not empty"
|
|
1444
|
+
|
|
1445
|
+
i18n-filterStartsWithOperator="kendo.pivotgrid.filterStartsWithOperator|The text of the starts with filter operator"
|
|
1446
|
+
filterStartsWithOperator="Starts with"
|
|
1447
|
+
|
|
1448
|
+
i18n-filterContainsOperator="kendo.pivotgrid.filterContainsOperator|The text of the contains filter operator"
|
|
1449
|
+
filterContainsOperator="Contains"
|
|
1450
|
+
|
|
1451
|
+
i18n-filterNotContainsOperator="kendo.pivotgrid.filterNotContainsOperator|The text of the does not contain filter operator"
|
|
1452
|
+
filterNotContainsOperator="Does not contain"
|
|
1453
|
+
|
|
1454
|
+
i18n-filterEndsWithOperator="kendo.pivotgrid.filterEndsWithOperator|The text of the ends with filter operator"
|
|
1455
|
+
filterEndsWithOperator="Ends with"
|
|
1456
|
+
|
|
1457
|
+
i18n-filterFilterButton="kendo.pivotgrid.filterFilterButton|The text of the filter button"
|
|
1458
|
+
filterFilterButton="Filter"
|
|
1459
|
+
|
|
1460
|
+
i18n-filterClearButton="kendo.pivotgrid.filterClearButton|The text of the clear filter button"
|
|
1461
|
+
filterClearButton="Clear"
|
|
1462
|
+
|
|
1463
|
+
i18n-configuratorButtonText="kendo.pivotgrid.configuratorButtonText|The text content of the button that opens and closes the PivotGrid configurator"
|
|
1464
|
+
configuratorButtonText="Change Settings"
|
|
1465
|
+
|
|
1466
|
+
i18n-configuratorHeaderText="kendo.pivotgrid.configuratorHeaderText|The text content of the PivotGrid configurator title element"
|
|
1467
|
+
configuratorHeaderText="Settings"
|
|
1468
|
+
|
|
1469
|
+
i18n-configuratorFieldsText="kendo.pivotgrid.configuratorFieldsText|The text content of the PivotGrid configurator fields section title element"
|
|
1470
|
+
configuratorFieldsText="Fields"
|
|
1471
|
+
|
|
1472
|
+
i18n-configuratorColumnsText="kendo.pivotgrid.configuratorColumnsText|The text content of the PivotGrid configurator columns section title element"
|
|
1473
|
+
configuratorColumnsText="Columns"
|
|
1474
|
+
|
|
1475
|
+
i18n-configuratorRowsText="kendo.pivotgrid.configuratorRowsText|The text content of the PivotGrid configurator rows section title element"
|
|
1476
|
+
configuratorRowsText="Rows"
|
|
1477
|
+
|
|
1478
|
+
i18n-configuratorValuesText="kendo.pivotgrid.configuratorValuesText|The text content of the PivotGrid configurator values section title element"
|
|
1479
|
+
configuratorValuesText="Values"
|
|
1480
|
+
|
|
1481
|
+
i18n-configuratorCancelButtonText="kendo.pivotgrid.configuratorCancelButtonText|The text content of the PivotGrid configurator configurator Cancel button"
|
|
1482
|
+
configuratorCancelButtonText="Cancel"
|
|
1483
|
+
|
|
1484
|
+
i18n-configuratorApplyButtonText="kendo.pivotgrid.configuratorApplyButtonText|The text content of the PivotGrid configurator configurator Apply button"
|
|
1485
|
+
configuratorApplyButtonText="Apply"></ng-container>
|
|
1486
|
+
|
|
1487
|
+
<div #table class="k-pivotgrid">
|
|
1488
|
+
<span class="k-pivotgrid-empty-cell" [attr.aria-label]="messageFor('emptyCellLabel')"></span>
|
|
1489
|
+
<kendo-pivotgrid-table
|
|
1490
|
+
#colHeadersTable
|
|
1491
|
+
[colWidth]="columnHeadersWidth"
|
|
1492
|
+
class="k-pivotgrid-column-headers"
|
|
1493
|
+
tableType="columnHeader"></kendo-pivotgrid-table>
|
|
1494
|
+
<kendo-pivotgrid-table
|
|
1495
|
+
#rowHeadersTable
|
|
1496
|
+
class="k-pivotgrid-row-headers"
|
|
1497
|
+
tableType="rowHeader"></kendo-pivotgrid-table>
|
|
1498
|
+
<kendo-pivotgrid-table
|
|
1499
|
+
#valuesTable
|
|
1500
|
+
[colWidth]="columnHeadersWidth"
|
|
1501
|
+
class="k-pivotgrid-values"
|
|
1502
|
+
tableType="values"></kendo-pivotgrid-table>
|
|
1503
|
+
|
|
1504
|
+
<div *ngIf="loading" class="k-loader">
|
|
1505
|
+
<kendo-loader
|
|
1506
|
+
[type]="loaderSettings?.type"
|
|
1507
|
+
[themeColor]="loaderSettings?.themeColor"
|
|
1508
|
+
[size]="loaderSettings?.size"
|
|
1509
|
+
>
|
|
1510
|
+
</kendo-loader>
|
|
1511
|
+
<span class="k-loading-text">{{ loadingText }}</span>
|
|
1512
|
+
</div>
|
|
1513
|
+
</div>
|
|
1514
|
+
|
|
1515
|
+
<kendo-pivotgrid-configurator
|
|
1516
|
+
*ngIf="showConfigurator"
|
|
1517
|
+
[horizontal]="configuratorSettings.horizontal">
|
|
1518
|
+
</kendo-pivotgrid-configurator>
|
|
1519
|
+
|
|
1520
|
+
<div *ngIf="configurator"
|
|
1521
|
+
class="k-pivotgrid-configurator-button"
|
|
1522
|
+
(click)="showConfigurator = !showConfigurator">
|
|
1523
|
+
<span>{{ messageFor('configuratorButtonText') }}<span class="k-icon k-i-gear k-color-inherit"></span>
|
|
1524
|
+
</span>
|
|
395
1525
|
</div>
|
|
396
|
-
`, isInline: true, styles: ["\n /** TODO: Remove if added to themes */\n div.k-loader {\n position: absolute;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%);\n }\n "], components: [{ type: PivotGridTableComponent, selector: "kendo-pivotgrid-table", inputs: ["tableType"] }, { type:
|
|
1526
|
+
`, isInline: true, styles: ["\n /** TODO: Remove if added to themes */\n div.k-loader {\n position: absolute;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%);\n }\n "], components: [{ type: PivotGridTableComponent, selector: "kendo-pivotgrid-table", inputs: ["tableType", "colWidth"] }, { type: i5$1.LoaderComponent, selector: "kendo-loader", inputs: ["type", "themeColor", "size"] }, { type: PivotGridConfiguratorComponent, selector: "kendo-pivotgrid-configurator", inputs: ["horizontal"] }], directives: [{ type: LocalizedMessagesDirective, selector: "[kendoPivotGridLocalizedMessages]" }, { type: i6.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
|
|
397
1527
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PivotGridComponent, decorators: [{
|
|
398
1528
|
type: Component,
|
|
399
1529
|
args: [{
|
|
400
1530
|
selector: 'kendo-pivotgrid',
|
|
401
1531
|
providers: [
|
|
402
|
-
PivotGridDataService
|
|
1532
|
+
PivotGridDataService,
|
|
1533
|
+
LocalizationService,
|
|
1534
|
+
{
|
|
1535
|
+
provide: L10N_PREFIX,
|
|
1536
|
+
useValue: 'kendo.pivotgrid'
|
|
1537
|
+
}
|
|
403
1538
|
],
|
|
404
1539
|
template: `
|
|
405
|
-
<
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
1540
|
+
<ng-container kendoPivotGridLocalizedMessages
|
|
1541
|
+
i18n-loading="kendo.pivotgrid.loading|The loading text"
|
|
1542
|
+
loading="Loading"
|
|
1543
|
+
|
|
1544
|
+
i18n-emptyCellLabel="kendo.pivotgrid.emptyCellLabel|The value of the aria-label attribute placed on the focusable empty cell element"
|
|
1545
|
+
emptyCellLabel="PivotGrid Empty Cell"
|
|
1546
|
+
|
|
1547
|
+
i18n-fieldMenuFilterItemLabel="kendo.pivotgrid.fieldMenuFilterItemLabel|The text content of the filter item in the column and row fields menu"
|
|
1548
|
+
fieldMenuFilterItemLabel="Filter"
|
|
1549
|
+
|
|
1550
|
+
i18n-fieldMenuSortAscendingItemLabel="kendo.pivotgrid.fieldMenuSortAscendingItemLabel|The text content of the sort ascending item in the column and row fields menu"
|
|
1551
|
+
fieldMenuSortAscendingItemLabel="Sort ascending"
|
|
1552
|
+
|
|
1553
|
+
i18n-fieldMenuSortDescendingItemLabel="kendo.pivotgrid.fieldMenuSortDescendingItemLabel|The text content of the sort descending item in the column and row fields menu"
|
|
1554
|
+
fieldMenuSortDescendingItemLabel="Sort descending"
|
|
1555
|
+
|
|
1556
|
+
i18n-filterInputLabel="kendo.pivotgrid.filterInputLabel|The label of the filter input"
|
|
1557
|
+
filterInputLabel="{{ '{fields} Filter' }}"
|
|
1558
|
+
|
|
1559
|
+
i18n-filterOperatorsDropDownLabel="kendo.pivotgrid.filterOperatorsDropDownLabel|The label of the filter operators DropDownList"
|
|
1560
|
+
filterOperatorsDropDownLabel="{{ '{fields} Filter Operators' }}"
|
|
1561
|
+
|
|
1562
|
+
i18n-filterEqOperator="kendo.pivotgrid.filterEqOperator|The text of the equal filter operator"
|
|
1563
|
+
filterEqOperator="Is equal to"
|
|
1564
|
+
|
|
1565
|
+
i18n-filterNotEqOperator="kendo.pivotgrid.filterNotEqOperator|The text of the not equal filter operator"
|
|
1566
|
+
filterNotEqOperator="Is not equal to"
|
|
1567
|
+
|
|
1568
|
+
i18n-filterIsNullOperator="kendo.pivotgrid.filterIsNullOperator|The text of the is null filter operator"
|
|
1569
|
+
filterIsNullOperator="Is null"
|
|
1570
|
+
|
|
1571
|
+
i18n-filterIsNotNullOperator="kendo.pivotgrid.filterIsNotNullOperator|The text of the is not null filter operator"
|
|
1572
|
+
filterIsNotNullOperator="Is not null"
|
|
1573
|
+
|
|
1574
|
+
i18n-filterIsEmptyOperator="kendo.pivotgrid.filterIsEmptyOperator|The text of the is empty filter operator"
|
|
1575
|
+
filterIsEmptyOperator="Is empty"
|
|
1576
|
+
|
|
1577
|
+
i18n-filterIsNotEmptyOperator="kendo.pivotgrid.filterIsNotEmptyOperator|The text of the is not empty filter operator"
|
|
1578
|
+
filterIsNotEmptyOperator="Is not empty"
|
|
1579
|
+
|
|
1580
|
+
i18n-filterStartsWithOperator="kendo.pivotgrid.filterStartsWithOperator|The text of the starts with filter operator"
|
|
1581
|
+
filterStartsWithOperator="Starts with"
|
|
1582
|
+
|
|
1583
|
+
i18n-filterContainsOperator="kendo.pivotgrid.filterContainsOperator|The text of the contains filter operator"
|
|
1584
|
+
filterContainsOperator="Contains"
|
|
1585
|
+
|
|
1586
|
+
i18n-filterNotContainsOperator="kendo.pivotgrid.filterNotContainsOperator|The text of the does not contain filter operator"
|
|
1587
|
+
filterNotContainsOperator="Does not contain"
|
|
1588
|
+
|
|
1589
|
+
i18n-filterEndsWithOperator="kendo.pivotgrid.filterEndsWithOperator|The text of the ends with filter operator"
|
|
1590
|
+
filterEndsWithOperator="Ends with"
|
|
1591
|
+
|
|
1592
|
+
i18n-filterFilterButton="kendo.pivotgrid.filterFilterButton|The text of the filter button"
|
|
1593
|
+
filterFilterButton="Filter"
|
|
1594
|
+
|
|
1595
|
+
i18n-filterClearButton="kendo.pivotgrid.filterClearButton|The text of the clear filter button"
|
|
1596
|
+
filterClearButton="Clear"
|
|
1597
|
+
|
|
1598
|
+
i18n-configuratorButtonText="kendo.pivotgrid.configuratorButtonText|The text content of the button that opens and closes the PivotGrid configurator"
|
|
1599
|
+
configuratorButtonText="Change Settings"
|
|
1600
|
+
|
|
1601
|
+
i18n-configuratorHeaderText="kendo.pivotgrid.configuratorHeaderText|The text content of the PivotGrid configurator title element"
|
|
1602
|
+
configuratorHeaderText="Settings"
|
|
1603
|
+
|
|
1604
|
+
i18n-configuratorFieldsText="kendo.pivotgrid.configuratorFieldsText|The text content of the PivotGrid configurator fields section title element"
|
|
1605
|
+
configuratorFieldsText="Fields"
|
|
1606
|
+
|
|
1607
|
+
i18n-configuratorColumnsText="kendo.pivotgrid.configuratorColumnsText|The text content of the PivotGrid configurator columns section title element"
|
|
1608
|
+
configuratorColumnsText="Columns"
|
|
1609
|
+
|
|
1610
|
+
i18n-configuratorRowsText="kendo.pivotgrid.configuratorRowsText|The text content of the PivotGrid configurator rows section title element"
|
|
1611
|
+
configuratorRowsText="Rows"
|
|
1612
|
+
|
|
1613
|
+
i18n-configuratorValuesText="kendo.pivotgrid.configuratorValuesText|The text content of the PivotGrid configurator values section title element"
|
|
1614
|
+
configuratorValuesText="Values"
|
|
1615
|
+
|
|
1616
|
+
i18n-configuratorCancelButtonText="kendo.pivotgrid.configuratorCancelButtonText|The text content of the PivotGrid configurator configurator Cancel button"
|
|
1617
|
+
configuratorCancelButtonText="Cancel"
|
|
1618
|
+
|
|
1619
|
+
i18n-configuratorApplyButtonText="kendo.pivotgrid.configuratorApplyButtonText|The text content of the PivotGrid configurator configurator Apply button"
|
|
1620
|
+
configuratorApplyButtonText="Apply"></ng-container>
|
|
1621
|
+
|
|
1622
|
+
<div #table class="k-pivotgrid">
|
|
1623
|
+
<span class="k-pivotgrid-empty-cell" [attr.aria-label]="messageFor('emptyCellLabel')"></span>
|
|
1624
|
+
<kendo-pivotgrid-table
|
|
1625
|
+
#colHeadersTable
|
|
1626
|
+
[colWidth]="columnHeadersWidth"
|
|
1627
|
+
class="k-pivotgrid-column-headers"
|
|
1628
|
+
tableType="columnHeader"></kendo-pivotgrid-table>
|
|
1629
|
+
<kendo-pivotgrid-table
|
|
1630
|
+
#rowHeadersTable
|
|
1631
|
+
class="k-pivotgrid-row-headers"
|
|
1632
|
+
tableType="rowHeader"></kendo-pivotgrid-table>
|
|
1633
|
+
<kendo-pivotgrid-table
|
|
1634
|
+
#valuesTable
|
|
1635
|
+
[colWidth]="columnHeadersWidth"
|
|
1636
|
+
class="k-pivotgrid-values"
|
|
1637
|
+
tableType="values"></kendo-pivotgrid-table>
|
|
1638
|
+
|
|
1639
|
+
<div *ngIf="loading" class="k-loader">
|
|
1640
|
+
<kendo-loader
|
|
1641
|
+
[type]="loaderSettings?.type"
|
|
1642
|
+
[themeColor]="loaderSettings?.themeColor"
|
|
1643
|
+
[size]="loaderSettings?.size"
|
|
1644
|
+
>
|
|
1645
|
+
</kendo-loader>
|
|
1646
|
+
<span class="k-loading-text">{{ loadingText }}</span>
|
|
1647
|
+
</div>
|
|
1648
|
+
</div>
|
|
1649
|
+
|
|
1650
|
+
<kendo-pivotgrid-configurator
|
|
1651
|
+
*ngIf="showConfigurator"
|
|
1652
|
+
[horizontal]="configuratorSettings.horizontal">
|
|
1653
|
+
</kendo-pivotgrid-configurator>
|
|
1654
|
+
|
|
1655
|
+
<div *ngIf="configurator"
|
|
1656
|
+
class="k-pivotgrid-configurator-button"
|
|
1657
|
+
(click)="showConfigurator = !showConfigurator">
|
|
1658
|
+
<span>{{ messageFor('configuratorButtonText') }}<span class="k-icon k-i-gear k-color-inherit"></span>
|
|
1659
|
+
</span>
|
|
426
1660
|
</div>
|
|
427
1661
|
`,
|
|
428
1662
|
styles: [`
|
|
@@ -435,9 +1669,30 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
|
|
|
435
1669
|
}
|
|
436
1670
|
`]
|
|
437
1671
|
}]
|
|
438
|
-
}], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i0.NgZone }, { type: PivotGridDataService }, { type: i2
|
|
1672
|
+
}], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i0.NgZone }, { type: PivotGridDataService }, { type: i2.LocalizationService }, { type: i3.ScrollbarWidthService }]; }, propDecorators: { hostClass: [{
|
|
1673
|
+
type: HostBinding,
|
|
1674
|
+
args: ['class.k-d-flex']
|
|
1675
|
+
}, {
|
|
1676
|
+
type: HostBinding,
|
|
1677
|
+
args: ['class.k-pos-relative']
|
|
1678
|
+
}], rightPositionClass: [{
|
|
1679
|
+
type: HostBinding,
|
|
1680
|
+
args: ['class.k-flex-row']
|
|
1681
|
+
}], leftPositionClass: [{
|
|
1682
|
+
type: HostBinding,
|
|
1683
|
+
args: ['class.k-flex-row-reverse']
|
|
1684
|
+
}], bottomPositionClass: [{
|
|
1685
|
+
type: HostBinding,
|
|
1686
|
+
args: ['class.k-flex-column']
|
|
1687
|
+
}], topPositionClass: [{
|
|
439
1688
|
type: HostBinding,
|
|
440
|
-
args: ['class.k-
|
|
1689
|
+
args: ['class.k-flex-column-reverse']
|
|
1690
|
+
}], dir: [{
|
|
1691
|
+
type: HostBinding,
|
|
1692
|
+
args: ['attr.dir']
|
|
1693
|
+
}], ariaRole: [{
|
|
1694
|
+
type: HostBinding,
|
|
1695
|
+
args: ['attr.role']
|
|
441
1696
|
}], colHeadersTable: [{
|
|
442
1697
|
type: ViewChild,
|
|
443
1698
|
args: ['colHeadersTable', { read: ElementRef }]
|
|
@@ -447,10 +1702,56 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
|
|
|
447
1702
|
}], valuesTable: [{
|
|
448
1703
|
type: ViewChild,
|
|
449
1704
|
args: ['valuesTable', { read: ElementRef }]
|
|
1705
|
+
}], table: [{
|
|
1706
|
+
type: ViewChild,
|
|
1707
|
+
args: ['table', { read: ElementRef }]
|
|
450
1708
|
}], loaderSettings: [{
|
|
451
1709
|
type: Input
|
|
1710
|
+
}], configurator: [{
|
|
1711
|
+
type: Input
|
|
1712
|
+
}], columnHeadersWidth: [{
|
|
1713
|
+
type: Input
|
|
452
1714
|
}] } });
|
|
453
1715
|
|
|
1716
|
+
/**
|
|
1717
|
+
* @hidden
|
|
1718
|
+
*/
|
|
1719
|
+
class PivotGridState {
|
|
1720
|
+
constructor(columnAxes, rowAxes, measureAxes) {
|
|
1721
|
+
this.columnAxes = columnAxes;
|
|
1722
|
+
this.rowAxes = rowAxes;
|
|
1723
|
+
this.measureAxes = measureAxes;
|
|
1724
|
+
}
|
|
1725
|
+
}
|
|
1726
|
+
|
|
1727
|
+
/**
|
|
1728
|
+
* The event data for the ExpandChangeEvent
|
|
1729
|
+
*/
|
|
1730
|
+
class ExpandChangeEvent extends PreventableEvent {
|
|
1731
|
+
/**
|
|
1732
|
+
* @hidden
|
|
1733
|
+
*/
|
|
1734
|
+
constructor(args) {
|
|
1735
|
+
super();
|
|
1736
|
+
Object.assign(this, args);
|
|
1737
|
+
}
|
|
1738
|
+
}
|
|
1739
|
+
;
|
|
1740
|
+
|
|
1741
|
+
/**
|
|
1742
|
+
* The event data for the ConfigurationChangeEvent
|
|
1743
|
+
*/
|
|
1744
|
+
class ConfigurationChangeEvent extends PreventableEvent {
|
|
1745
|
+
/**
|
|
1746
|
+
* @hidden
|
|
1747
|
+
*/
|
|
1748
|
+
constructor(args) {
|
|
1749
|
+
super();
|
|
1750
|
+
Object.assign(this, args);
|
|
1751
|
+
}
|
|
1752
|
+
}
|
|
1753
|
+
;
|
|
1754
|
+
|
|
454
1755
|
/**
|
|
455
1756
|
* @hidden
|
|
456
1757
|
* A directive which binds the PivotGrid to an array of objects.
|
|
@@ -471,11 +1772,28 @@ class PivotBaseBindingDirective {
|
|
|
471
1772
|
* Represents the measure axes configuration of the PivotGrid.
|
|
472
1773
|
*/
|
|
473
1774
|
this.measureAxes = [];
|
|
474
|
-
|
|
1775
|
+
/**
|
|
1776
|
+
* Fires each time a row or column header gets expanded or collapsed by the end user. The event is preventable.
|
|
1777
|
+
* If you prevent the event, the PivotGrid will not be rerendered with the new state, resulting from the end user interaction.
|
|
1778
|
+
*/
|
|
1779
|
+
this.expandChange = new EventEmitter();
|
|
1780
|
+
/**
|
|
1781
|
+
* Fires when the Configurator Apply button is pressed. The event is preventable.
|
|
1782
|
+
* If you prevent the event, the PivotGrid will not be rerendered with the new state, resulting from the configuration changes, applied through the configurator interface.
|
|
1783
|
+
*/
|
|
1784
|
+
this.configurationChange = new EventEmitter();
|
|
1785
|
+
this.subs = new Subscription();
|
|
1786
|
+
}
|
|
1787
|
+
/**
|
|
1788
|
+
* @hidden
|
|
1789
|
+
*/
|
|
1790
|
+
get state() {
|
|
1791
|
+
return new PivotGridState(this.columnAxes, this.rowAxes, this.measureAxes);
|
|
475
1792
|
}
|
|
476
1793
|
ngOnInit() {
|
|
477
|
-
this.loadData();
|
|
478
|
-
this.
|
|
1794
|
+
this.loadData(this.state);
|
|
1795
|
+
this.loadFields();
|
|
1796
|
+
this.subs.add(this.dataService.expandedStateChange.subscribe((state) => {
|
|
479
1797
|
this.zone.run(() => {
|
|
480
1798
|
const isCol = state.tableType === 'columnHeader';
|
|
481
1799
|
const axes = isCol ? 'columnAxes' : 'rowAxes';
|
|
@@ -483,10 +1801,28 @@ class PivotBaseBindingDirective {
|
|
|
483
1801
|
const tree = toTree((isCol ? this.dataService.columns : this.dataService.rows || []).slice());
|
|
484
1802
|
this.updateHeaders(axes, tree, state.cell.path);
|
|
485
1803
|
});
|
|
486
|
-
});
|
|
1804
|
+
}));
|
|
1805
|
+
this.subs.add(this.dataService.configuratorFieldChange.subscribe((state) => {
|
|
1806
|
+
this.zone.run(() => {
|
|
1807
|
+
if (hasObservers(this.configurationChange)) {
|
|
1808
|
+
const event = new ConfigurationChangeEvent(state);
|
|
1809
|
+
this.configurationChange.emit(event);
|
|
1810
|
+
if (event.isDefaultPrevented()) {
|
|
1811
|
+
return;
|
|
1812
|
+
}
|
|
1813
|
+
}
|
|
1814
|
+
this.dataService.configuredFields.next({
|
|
1815
|
+
columnAxes: state.columnAxes,
|
|
1816
|
+
rowAxes: state.rowAxes,
|
|
1817
|
+
measureAxes: state.measureAxes
|
|
1818
|
+
});
|
|
1819
|
+
this.loadData(state);
|
|
1820
|
+
});
|
|
1821
|
+
}));
|
|
1822
|
+
this.dataService.directive = this;
|
|
487
1823
|
}
|
|
488
1824
|
ngOnDestroy() {
|
|
489
|
-
this.
|
|
1825
|
+
this.subs.unsubscribe();
|
|
490
1826
|
}
|
|
491
1827
|
updateDataServiceFields() {
|
|
492
1828
|
this.dataService.normalizedData = this.dataState.data;
|
|
@@ -494,6 +1830,14 @@ class PivotBaseBindingDirective {
|
|
|
494
1830
|
this.dataService.columns = this.dataState.columns;
|
|
495
1831
|
this.dataService.updateRowsAndCols();
|
|
496
1832
|
}
|
|
1833
|
+
updateConfiguratorFields() {
|
|
1834
|
+
this.dataService.fields.next(this.configuratorFields);
|
|
1835
|
+
this.dataService.configuredFields.next({
|
|
1836
|
+
columnAxes: this.columnAxes,
|
|
1837
|
+
rowAxes: this.rowAxes,
|
|
1838
|
+
measureAxes: this.measureAxes
|
|
1839
|
+
});
|
|
1840
|
+
}
|
|
497
1841
|
updateHeaders(axes, tree, path) {
|
|
498
1842
|
// Action to determine expand/collapse state
|
|
499
1843
|
const action = {
|
|
@@ -502,15 +1846,23 @@ class PivotBaseBindingDirective {
|
|
|
502
1846
|
};
|
|
503
1847
|
// The `headersReducer` method is responsible for udpating
|
|
504
1848
|
// the expanded state based on the toggle action (expand/collapse)
|
|
505
|
-
const newHeaders = headersReducer(this[axes].slice(), Object.assign(Object.assign({}, action), { tree }));
|
|
506
1849
|
// Update axes and reload data
|
|
1850
|
+
const newHeaders = headersReducer(this[axes].slice(), Object.assign(Object.assign({}, action), { tree }));
|
|
1851
|
+
if (hasObservers(this.expandChange)) {
|
|
1852
|
+
const newState = Object.assign(Object.assign({}, this.state), { [axes]: newHeaders });
|
|
1853
|
+
const event = new ExpandChangeEvent(newState);
|
|
1854
|
+
this.expandChange.emit(event);
|
|
1855
|
+
if (event.isDefaultPrevented()) {
|
|
1856
|
+
return;
|
|
1857
|
+
}
|
|
1858
|
+
}
|
|
507
1859
|
this[axes] = newHeaders;
|
|
508
|
-
this.loadData();
|
|
1860
|
+
this.loadData(this.state);
|
|
509
1861
|
}
|
|
510
1862
|
;
|
|
511
1863
|
}
|
|
512
1864
|
PivotBaseBindingDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PivotBaseBindingDirective, deps: [{ token: PivotGridDataService }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Directive });
|
|
513
|
-
PivotBaseBindingDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: PivotBaseBindingDirective, selector: "kendo-base-binding-directive", inputs: { columnAxes: "columnAxes", rowAxes: "rowAxes", measureAxes: "measureAxes" }, ngImport: i0 });
|
|
1865
|
+
PivotBaseBindingDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: PivotBaseBindingDirective, selector: "kendo-base-binding-directive", inputs: { columnAxes: "columnAxes", rowAxes: "rowAxes", measureAxes: "measureAxes" }, outputs: { expandChange: "expandChange", configurationChange: "configurationChange" }, ngImport: i0 });
|
|
514
1866
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PivotBaseBindingDirective, decorators: [{
|
|
515
1867
|
type: Directive,
|
|
516
1868
|
args: [{
|
|
@@ -522,6 +1874,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
|
|
|
522
1874
|
type: Input
|
|
523
1875
|
}], measureAxes: [{
|
|
524
1876
|
type: Input
|
|
1877
|
+
}], expandChange: [{
|
|
1878
|
+
type: Output
|
|
1879
|
+
}], configurationChange: [{
|
|
1880
|
+
type: Output
|
|
525
1881
|
}] } });
|
|
526
1882
|
|
|
527
1883
|
const dataField = 'aggregate';
|
|
@@ -534,26 +1890,38 @@ const stringSeparator = '&';
|
|
|
534
1890
|
class PivotLocalBindingDirective extends PivotBaseBindingDirective {
|
|
535
1891
|
constructor(dataService, zone) {
|
|
536
1892
|
super(dataService, zone);
|
|
1893
|
+
this.type = 'local';
|
|
537
1894
|
this.createAxisSettings = (key) => (Object.assign({ key }, this.dimensions[key]));
|
|
538
1895
|
}
|
|
539
1896
|
ngOnChanges(changes) {
|
|
540
1897
|
if (anyChanged(['data', 'dimensions', 'columnAxes', 'rowAxes', 'measureAxes', 'measures'], changes)) {
|
|
541
|
-
this.loadData();
|
|
1898
|
+
this.loadData(this.state);
|
|
542
1899
|
}
|
|
543
1900
|
}
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
1901
|
+
/**
|
|
1902
|
+
* @hidden
|
|
1903
|
+
*/
|
|
1904
|
+
fetchChildren(node) {
|
|
1905
|
+
return node.children;
|
|
1906
|
+
}
|
|
1907
|
+
loadFields() {
|
|
1908
|
+
this.configuratorFields = createFlatSchemaDimensions(this.dimensions, this.measures);
|
|
1909
|
+
this.updateConfiguratorFields();
|
|
1910
|
+
}
|
|
1911
|
+
loadData(state) {
|
|
1912
|
+
const { columnAxes, rowAxes, measureAxes } = state;
|
|
1913
|
+
const rootColumnAxes = this.getRootAxes(columnAxes);
|
|
1914
|
+
const rootRowAxes = this.getRootAxes(rowAxes);
|
|
547
1915
|
const columnSettings = rootColumnAxes.split(stringSeparator).map(this.createAxisSettings);
|
|
548
1916
|
const rowSettings = rootRowAxes.split(stringSeparator).map(this.createAxisSettings);
|
|
549
|
-
const measuresSettings =
|
|
1917
|
+
const measuresSettings = measureAxes.map(m => this.measures.find(meas => String(meas.name) === String(m.name))).filter(Boolean);
|
|
550
1918
|
const dataTree = createDataTree(this.data, rowSettings, columnSettings, measuresSettings, bindingFields);
|
|
551
1919
|
this.dataState = createLocalDataState({
|
|
552
1920
|
dataTree,
|
|
553
1921
|
rowSettings,
|
|
554
1922
|
columnSettings,
|
|
555
|
-
rowAxes:
|
|
556
|
-
columnAxes:
|
|
1923
|
+
rowAxes: rowAxes,
|
|
1924
|
+
columnAxes: columnAxes,
|
|
557
1925
|
measures: measuresSettings,
|
|
558
1926
|
sort: [],
|
|
559
1927
|
fields: bindingFields
|
|
@@ -587,22 +1955,25 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
|
|
|
587
1955
|
class PivotOLAPBindingDirective extends PivotBaseBindingDirective {
|
|
588
1956
|
constructor(dataService, zone) {
|
|
589
1957
|
super(dataService, zone);
|
|
1958
|
+
this.type = 'olap';
|
|
590
1959
|
}
|
|
591
1960
|
ngOnChanges(changes) {
|
|
592
1961
|
if (anyChanged(['url', 'cube', 'catalog', 'columnAxes', 'rowAxes', 'measureAxes'], changes)) {
|
|
593
|
-
this.loadData();
|
|
1962
|
+
this.loadData(this.state);
|
|
1963
|
+
this.loadFields();
|
|
594
1964
|
}
|
|
595
1965
|
}
|
|
596
|
-
loadData() {
|
|
1966
|
+
loadData(state) {
|
|
1967
|
+
const { columnAxes, rowAxes, measureAxes } = state;
|
|
597
1968
|
this.dataService.loading.next(true);
|
|
598
1969
|
const options = {
|
|
599
1970
|
connection: {
|
|
600
1971
|
catalog: this.catalog,
|
|
601
1972
|
cube: this.cube
|
|
602
1973
|
},
|
|
603
|
-
columnAxes:
|
|
604
|
-
rowAxes:
|
|
605
|
-
measureAxes:
|
|
1974
|
+
columnAxes: columnAxes,
|
|
1975
|
+
rowAxes: rowAxes,
|
|
1976
|
+
measureAxes: measureAxes
|
|
606
1977
|
};
|
|
607
1978
|
fetchData({ url: this.url }, JSON.parse(JSON.stringify(options)))
|
|
608
1979
|
.then(createDataState)
|
|
@@ -612,6 +1983,127 @@ class PivotOLAPBindingDirective extends PivotBaseBindingDirective {
|
|
|
612
1983
|
this.dataService.loading.next(false);
|
|
613
1984
|
});
|
|
614
1985
|
}
|
|
1986
|
+
loadFields() {
|
|
1987
|
+
const options = {
|
|
1988
|
+
connection: {
|
|
1989
|
+
catalog: this.catalog,
|
|
1990
|
+
cube: this.cube
|
|
1991
|
+
},
|
|
1992
|
+
restrictions: {
|
|
1993
|
+
catalogName: this.catalog,
|
|
1994
|
+
cubeName: this.cube
|
|
1995
|
+
},
|
|
1996
|
+
command: 'schemaDimensions'
|
|
1997
|
+
};
|
|
1998
|
+
fetchDiscover({ url: this.url }, options)
|
|
1999
|
+
.then((newFields) => {
|
|
2000
|
+
addKPI(newFields);
|
|
2001
|
+
this.configuratorFields = newFields;
|
|
2002
|
+
this.updateConfiguratorFields();
|
|
2003
|
+
});
|
|
2004
|
+
}
|
|
2005
|
+
updateFields(event, fields) {
|
|
2006
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
2007
|
+
const newFields = fields.slice();
|
|
2008
|
+
const field = this.getField(newFields, event);
|
|
2009
|
+
if (field && field.uniqueName === '[KPIs]') {
|
|
2010
|
+
const KPIs = this.normalizeKPIs(yield this.loadKPIs());
|
|
2011
|
+
field.children = KPIs;
|
|
2012
|
+
}
|
|
2013
|
+
else if (field && field.type === 'kpi') {
|
|
2014
|
+
field.children = buildKPIMeasures(field);
|
|
2015
|
+
}
|
|
2016
|
+
else if (field && !field.children) {
|
|
2017
|
+
const additionalFields = yield this.loadAvailableFields(field);
|
|
2018
|
+
field.children = additionalFields;
|
|
2019
|
+
}
|
|
2020
|
+
return field === null || field === void 0 ? void 0 : field.children;
|
|
2021
|
+
});
|
|
2022
|
+
}
|
|
2023
|
+
/**
|
|
2024
|
+
* @hidden
|
|
2025
|
+
*/
|
|
2026
|
+
fetchChildren(event, fields) {
|
|
2027
|
+
return this.updateFields(event, fields);
|
|
2028
|
+
}
|
|
2029
|
+
normalizeKPIs(data) {
|
|
2030
|
+
for (let idx = 0, length = data.length; idx < length; idx++) {
|
|
2031
|
+
data[idx].uniqueName = data[idx].name;
|
|
2032
|
+
data[idx].type = 'kpi';
|
|
2033
|
+
}
|
|
2034
|
+
return data;
|
|
2035
|
+
}
|
|
2036
|
+
;
|
|
2037
|
+
getField(nodes = [], target) {
|
|
2038
|
+
for (let i = 0; i < nodes.length; i++) {
|
|
2039
|
+
const node = nodes[i];
|
|
2040
|
+
if (node.uniqueName === target.uniqueName) {
|
|
2041
|
+
return node;
|
|
2042
|
+
}
|
|
2043
|
+
let result = this.getField(node.children, target);
|
|
2044
|
+
if (result !== null) {
|
|
2045
|
+
return result;
|
|
2046
|
+
}
|
|
2047
|
+
}
|
|
2048
|
+
return null;
|
|
2049
|
+
}
|
|
2050
|
+
;
|
|
2051
|
+
loadKPIs() {
|
|
2052
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
2053
|
+
const options = {
|
|
2054
|
+
connection: {
|
|
2055
|
+
catalog: this.catalog,
|
|
2056
|
+
cube: this.cube
|
|
2057
|
+
},
|
|
2058
|
+
restrictions: {
|
|
2059
|
+
catalogName: this.catalog,
|
|
2060
|
+
cubeName: this.cube
|
|
2061
|
+
},
|
|
2062
|
+
command: 'schemaKPIs'
|
|
2063
|
+
};
|
|
2064
|
+
return fetchDiscover({ url: this.url }, options);
|
|
2065
|
+
});
|
|
2066
|
+
}
|
|
2067
|
+
;
|
|
2068
|
+
loadAvailableFields(field) {
|
|
2069
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
2070
|
+
let command;
|
|
2071
|
+
let dimensionUniqueName;
|
|
2072
|
+
let hierarchyUniqueName;
|
|
2073
|
+
let levelUniqueName;
|
|
2074
|
+
let memberUniqueName;
|
|
2075
|
+
let treeOp;
|
|
2076
|
+
if (field.type === 2) {
|
|
2077
|
+
command = 'schemaMeasures';
|
|
2078
|
+
}
|
|
2079
|
+
else if (field.dimensionUniqueName) {
|
|
2080
|
+
command = 'schemaLevels';
|
|
2081
|
+
hierarchyUniqueName = field.uniqueName;
|
|
2082
|
+
}
|
|
2083
|
+
else {
|
|
2084
|
+
command = 'schemaHierarchies';
|
|
2085
|
+
dimensionUniqueName = field.uniqueName;
|
|
2086
|
+
}
|
|
2087
|
+
const options = {
|
|
2088
|
+
connection: {
|
|
2089
|
+
catalog: this.catalog,
|
|
2090
|
+
cube: this.cube
|
|
2091
|
+
},
|
|
2092
|
+
restrictions: {
|
|
2093
|
+
catalogName: this.catalog,
|
|
2094
|
+
cubeName: this.cube,
|
|
2095
|
+
hierarchyUniqueName,
|
|
2096
|
+
dimensionUniqueName,
|
|
2097
|
+
levelUniqueName,
|
|
2098
|
+
memberUniqueName,
|
|
2099
|
+
treeOp
|
|
2100
|
+
},
|
|
2101
|
+
command
|
|
2102
|
+
};
|
|
2103
|
+
return fetchDiscover({ url: this.url }, options);
|
|
2104
|
+
});
|
|
2105
|
+
}
|
|
2106
|
+
;
|
|
615
2107
|
}
|
|
616
2108
|
PivotOLAPBindingDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PivotOLAPBindingDirective, deps: [{ token: PivotGridDataService }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Directive });
|
|
617
2109
|
PivotOLAPBindingDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.16", type: PivotOLAPBindingDirective, selector: "[kendoPivotOLAPBinding]", inputs: { url: "url", cube: "cube", catalog: "catalog" }, exportAs: ["kendoPivotOLAPBinding"], usesInheritance: true, usesOnChanges: true, ngImport: i0 });
|
|
@@ -629,17 +2121,68 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
|
|
|
629
2121
|
type: Input
|
|
630
2122
|
}] } });
|
|
631
2123
|
|
|
2124
|
+
/**
|
|
2125
|
+
* Custom component messages override default component messages
|
|
2126
|
+
* ([see example]({% slug globalization_pivotgrid %}#toc-localization)).
|
|
2127
|
+
*/
|
|
2128
|
+
class CustomMessagesComponent extends PivotGridMessages {
|
|
2129
|
+
constructor(service) {
|
|
2130
|
+
super();
|
|
2131
|
+
this.service = service;
|
|
2132
|
+
}
|
|
2133
|
+
get override() {
|
|
2134
|
+
return true;
|
|
2135
|
+
}
|
|
2136
|
+
}
|
|
2137
|
+
CustomMessagesComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: CustomMessagesComponent, deps: [{ token: i2.LocalizationService }], target: i0.ɵɵFactoryTarget.Component });
|
|
2138
|
+
CustomMessagesComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: CustomMessagesComponent, selector: "kendo-pivotgrid-messages", providers: [
|
|
2139
|
+
{
|
|
2140
|
+
provide: PivotGridMessages,
|
|
2141
|
+
useExisting: forwardRef(() => CustomMessagesComponent)
|
|
2142
|
+
}
|
|
2143
|
+
], usesInheritance: true, ngImport: i0, template: ``, isInline: true });
|
|
2144
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: CustomMessagesComponent, decorators: [{
|
|
2145
|
+
type: Component,
|
|
2146
|
+
args: [{
|
|
2147
|
+
providers: [
|
|
2148
|
+
{
|
|
2149
|
+
provide: PivotGridMessages,
|
|
2150
|
+
useExisting: forwardRef(() => CustomMessagesComponent)
|
|
2151
|
+
}
|
|
2152
|
+
],
|
|
2153
|
+
selector: 'kendo-pivotgrid-messages',
|
|
2154
|
+
template: ``
|
|
2155
|
+
}]
|
|
2156
|
+
}], ctorParameters: function () { return [{ type: i2.LocalizationService }]; } });
|
|
2157
|
+
|
|
632
2158
|
const IMPORTED_MODULES = [
|
|
633
2159
|
CommonModule,
|
|
634
2160
|
EventsModule,
|
|
635
|
-
IndicatorsModule
|
|
2161
|
+
IndicatorsModule,
|
|
2162
|
+
ButtonsModule,
|
|
2163
|
+
TreeViewModule,
|
|
2164
|
+
InputsModule,
|
|
2165
|
+
DraggableModule
|
|
636
2166
|
];
|
|
637
2167
|
const DECLARATIONS = [
|
|
2168
|
+
PivotGridComponent,
|
|
2169
|
+
PivotGridTableComponent,
|
|
2170
|
+
PivotGridConfiguratorComponent,
|
|
2171
|
+
PivotGridCellDirective,
|
|
2172
|
+
PivotLocalBindingDirective,
|
|
2173
|
+
PivotOLAPBindingDirective,
|
|
2174
|
+
DraggableChipDirective,
|
|
2175
|
+
DropTargetDirective,
|
|
2176
|
+
LocalizedMessagesDirective,
|
|
2177
|
+
CustomMessagesComponent
|
|
2178
|
+
];
|
|
2179
|
+
const EXPORTS = [
|
|
638
2180
|
PivotGridComponent,
|
|
639
2181
|
PivotGridTableComponent,
|
|
640
2182
|
PivotGridCellDirective,
|
|
641
2183
|
PivotLocalBindingDirective,
|
|
642
|
-
PivotOLAPBindingDirective
|
|
2184
|
+
PivotOLAPBindingDirective,
|
|
2185
|
+
CustomMessagesComponent
|
|
643
2186
|
];
|
|
644
2187
|
/**
|
|
645
2188
|
* Sample module
|
|
@@ -649,29 +2192,32 @@ class PivotGridModule {
|
|
|
649
2192
|
PivotGridModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PivotGridModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
650
2193
|
PivotGridModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PivotGridModule, declarations: [PivotGridComponent,
|
|
651
2194
|
PivotGridTableComponent,
|
|
2195
|
+
PivotGridConfiguratorComponent,
|
|
652
2196
|
PivotGridCellDirective,
|
|
653
2197
|
PivotLocalBindingDirective,
|
|
654
|
-
PivotOLAPBindingDirective
|
|
2198
|
+
PivotOLAPBindingDirective,
|
|
2199
|
+
DraggableChipDirective,
|
|
2200
|
+
DropTargetDirective,
|
|
2201
|
+
LocalizedMessagesDirective,
|
|
2202
|
+
CustomMessagesComponent], imports: [CommonModule,
|
|
655
2203
|
EventsModule,
|
|
656
|
-
IndicatorsModule
|
|
2204
|
+
IndicatorsModule,
|
|
2205
|
+
ButtonsModule,
|
|
2206
|
+
TreeViewModule,
|
|
2207
|
+
InputsModule,
|
|
2208
|
+
DraggableModule], exports: [PivotGridComponent,
|
|
657
2209
|
PivotGridTableComponent,
|
|
658
2210
|
PivotGridCellDirective,
|
|
659
2211
|
PivotLocalBindingDirective,
|
|
660
|
-
PivotOLAPBindingDirective
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
useValue: 'kendo.pivotgrid'
|
|
664
|
-
}], imports: [[...IMPORTED_MODULES]] });
|
|
2212
|
+
PivotOLAPBindingDirective,
|
|
2213
|
+
CustomMessagesComponent] });
|
|
2214
|
+
PivotGridModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PivotGridModule, imports: [[...IMPORTED_MODULES]] });
|
|
665
2215
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: PivotGridModule, decorators: [{
|
|
666
2216
|
type: NgModule,
|
|
667
2217
|
args: [{
|
|
668
2218
|
imports: [...IMPORTED_MODULES],
|
|
669
2219
|
declarations: [...DECLARATIONS],
|
|
670
|
-
exports: [...
|
|
671
|
-
providers: [{
|
|
672
|
-
provide: L10N_PREFIX,
|
|
673
|
-
useValue: 'kendo.pivotgrid'
|
|
674
|
-
}]
|
|
2220
|
+
exports: [...EXPORTS]
|
|
675
2221
|
}]
|
|
676
2222
|
}] });
|
|
677
2223
|
|
|
@@ -679,5 +2225,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
|
|
|
679
2225
|
* Generated bundle index. Do not edit.
|
|
680
2226
|
*/
|
|
681
2227
|
|
|
682
|
-
export { PivotGridCellDirective, PivotGridComponent, PivotGridModule, PivotGridTableComponent, PivotLocalBindingDirective, PivotOLAPBindingDirective };
|
|
2228
|
+
export { ConfigurationChangeEvent, CustomMessagesComponent, DraggableChipDirective, DropTargetDirective, ExpandChangeEvent, PivotGridCellDirective, PivotGridComponent, PivotGridConfiguratorComponent, PivotGridModule, PivotGridTableComponent, PivotLocalBindingDirective, PivotOLAPBindingDirective };
|
|
683
2229
|
|