@progress/kendo-angular-grid 21.2.0 → 21.3.0-develop.1
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/common/id.service.d.ts +2 -0
- package/esm2022/columns/column-base.mjs +1 -2
- package/esm2022/common/id.service.mjs +4 -0
- package/esm2022/grid.component.mjs +325 -274
- package/esm2022/package-metadata.mjs +2 -2
- package/esm2022/rendering/header/header.component.mjs +4 -4
- package/esm2022/rendering/toolbar/tools/ai-assistant/ai-assistant.component.mjs +11 -588
- package/esm2022/rendering/toolbar/tools/ai-assistant/ai-request-response.service.mjs +624 -0
- package/fesm2022/progress-kendo-angular-grid.mjs +1457 -1370
- package/grid.component.d.ts +41 -1
- package/package.json +24 -24
- package/rendering/toolbar/tools/ai-assistant/ai-assistant.component.d.ts +3 -23
- package/rendering/toolbar/tools/ai-assistant/ai-request-response.service.d.ts +61 -0
- package/schematics/ngAdd/index.js +7 -7
|
@@ -2109,6 +2109,7 @@ let sequence = 0;
|
|
|
2109
2109
|
*/
|
|
2110
2110
|
class IdService {
|
|
2111
2111
|
prefix;
|
|
2112
|
+
columnCounter = 0;
|
|
2112
2113
|
constructor() {
|
|
2113
2114
|
this.prefix = `k-grid${sequence++}`;
|
|
2114
2115
|
}
|
|
@@ -2127,6 +2128,9 @@ class IdService {
|
|
|
2127
2128
|
columnId(colIndex) {
|
|
2128
2129
|
return `${this.prefix}-col${colIndex}`;
|
|
2129
2130
|
}
|
|
2131
|
+
nextColumnId() {
|
|
2132
|
+
return `${this.prefix}-col${this.columnCounter++}`;
|
|
2133
|
+
}
|
|
2130
2134
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: IdService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
2131
2135
|
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: IdService });
|
|
2132
2136
|
}
|
|
@@ -2208,7 +2212,6 @@ const isCheckboxColumn = column => column?.isCheckboxColumn;
|
|
|
2208
2212
|
*/
|
|
2209
2213
|
const isRowReorderColumn = column => column?.isRowReorderColumn;
|
|
2210
2214
|
const isColumnContainer = column => column?.isColumnGroup || isSpanColumn(column);
|
|
2211
|
-
let columnId = 0;
|
|
2212
2215
|
/**
|
|
2213
2216
|
* The base class for the column components of the Grid.
|
|
2214
2217
|
*
|
|
@@ -2539,7 +2542,7 @@ class ColumnBase {
|
|
|
2539
2542
|
if (parent && idService && parent.idService.gridId() === idService.gridId() && !isColumnContainer(parent)) {
|
|
2540
2543
|
throw new Error(ColumnConfigurationErrorMessages.columnNested);
|
|
2541
2544
|
}
|
|
2542
|
-
this._id = this.idService?.
|
|
2545
|
+
this._id = this.idService?.nextColumnId();
|
|
2543
2546
|
}
|
|
2544
2547
|
ngAfterViewInit() {
|
|
2545
2548
|
this.initialMinResizableWidth = this.minResizableWidth || 10;
|
|
@@ -19727,7 +19730,7 @@ class HeaderComponent {
|
|
|
19727
19730
|
}
|
|
19728
19731
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: HeaderComponent, deps: [{ token: SinglePopupService }, { token: DragHintService }, { token: DropCueService }, { token: ColumnReorderService }, { token: IdService }, { token: SortService }, { token: ColumnInfoService }, { token: i0.ChangeDetectorRef }, { token: ContextService }, { token: NavigationService }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component });
|
|
19729
19732
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.14", type: HeaderComponent, isStandalone: true, selector: "[kendoGridHeader]", inputs: { totalColumnLevels: "totalColumnLevels", columns: "columns", groups: "groups", detailTemplate: "detailTemplate", scrollable: "scrollable", filterable: "filterable", sort: "sort", filter: "filter", sortable: "sortable", groupable: "groupable", lockedColumnsCount: "lockedColumnsCount", resizable: "resizable", reorderable: "reorderable", columnMenu: "columnMenu", columnMenuTemplate: "columnMenuTemplate", totalColumnsCount: "totalColumnsCount", totalColumns: "totalColumns", tabIndex: "tabIndex", size: "size" }, host: { properties: { "class.k-table-thead": "this.hostClass" } }, viewQueries: [{ propertyName: "dropTargets", predicate: DropTargetDirective, descendants: true }, { propertyName: "filterMenus", predicate: FilterMenuComponent, descendants: true }, { propertyName: "columnMenus", predicate: ColumnMenuComponent, descendants: true }], usesOnChanges: true, ngImport: i0, template: `
|
|
19730
|
-
@for (i of columnLevels; track
|
|
19733
|
+
@for (i of columnLevels; track $index; let levelIndex = $index) {
|
|
19731
19734
|
<tr
|
|
19732
19735
|
kendoGridLogicalRow
|
|
19733
19736
|
[logicalRowIndex]="levelIndex"
|
|
@@ -19748,7 +19751,7 @@ class HeaderComponent {
|
|
|
19748
19751
|
>
|
|
19749
19752
|
</th>
|
|
19750
19753
|
}
|
|
19751
|
-
@for (column of columnsForLevel(levelIndex); track column; let columnIndex = $index; let last = $last) {
|
|
19754
|
+
@for (column of columnsForLevel(levelIndex); track column.id; let columnIndex = $index; let last = $last) {
|
|
19752
19755
|
@if (!isColumnGroupComponent(column)) {
|
|
19753
19756
|
<th
|
|
19754
19757
|
kendoGridLogicalCell
|
|
@@ -19975,7 +19978,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImpo
|
|
|
19975
19978
|
args: [{
|
|
19976
19979
|
selector: '[kendoGridHeader]',
|
|
19977
19980
|
template: `
|
|
19978
|
-
@for (i of columnLevels; track
|
|
19981
|
+
@for (i of columnLevels; track $index; let levelIndex = $index) {
|
|
19979
19982
|
<tr
|
|
19980
19983
|
kendoGridLogicalRow
|
|
19981
19984
|
[logicalRowIndex]="levelIndex"
|
|
@@ -19996,7 +19999,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImpo
|
|
|
19996
19999
|
>
|
|
19997
20000
|
</th>
|
|
19998
20001
|
}
|
|
19999
|
-
@for (column of columnsForLevel(levelIndex); track column; let columnIndex = $index; let last = $last) {
|
|
20002
|
+
@for (column of columnsForLevel(levelIndex); track column.id; let columnIndex = $index; let last = $last) {
|
|
20000
20003
|
@if (!isColumnGroupComponent(column)) {
|
|
20001
20004
|
<th
|
|
20002
20005
|
kendoGridLogicalCell
|
|
@@ -23575,473 +23578,1171 @@ const packageMetadata = {
|
|
|
23575
23578
|
productName: 'Kendo UI for Angular',
|
|
23576
23579
|
productCode: 'KENDOUIANGULAR',
|
|
23577
23580
|
productCodes: ['KENDOUIANGULAR'],
|
|
23578
|
-
publishDate:
|
|
23579
|
-
version: '21.
|
|
23581
|
+
publishDate: 1764778815,
|
|
23582
|
+
version: '21.3.0-develop.1',
|
|
23580
23583
|
licensingDocsUrl: 'https://www.telerik.com/kendo-angular-ui/my-license/'
|
|
23581
23584
|
};
|
|
23582
23585
|
|
|
23583
23586
|
/**
|
|
23584
23587
|
* @hidden
|
|
23588
|
+
* Converts date strings in a filter to Date objects.
|
|
23585
23589
|
*/
|
|
23586
|
-
const
|
|
23587
|
-
|
|
23588
|
-
|
|
23589
|
-
pageSizes,
|
|
23590
|
-
previousNext,
|
|
23591
|
-
type,
|
|
23592
|
-
responsive,
|
|
23593
|
-
position
|
|
23594
|
-
});
|
|
23595
|
-
/**
|
|
23596
|
-
* @hidden
|
|
23597
|
-
*/
|
|
23598
|
-
const normalize = (settings) => normalizeSettings(settings === true ? {} : settings);
|
|
23599
|
-
|
|
23600
|
-
const canCreateElement = () => isDocumentAvailable() && document.createElement;
|
|
23601
|
-
let cachedScrollbarWidth = null;
|
|
23602
|
-
let cachedPixelRatio;
|
|
23603
|
-
let cachedRtlScrollLeft = null;
|
|
23604
|
-
function scrollbarWidth() {
|
|
23605
|
-
if (cachedScrollbarWidth === null && canCreateElement()) {
|
|
23606
|
-
cachedPixelRatio = window.devicePixelRatio || 1;
|
|
23607
|
-
const div = document.createElement("div");
|
|
23608
|
-
div.style.cssText = "overflow:scroll;overflow-x:hidden;zoom:1;clear:both;display:block";
|
|
23609
|
-
div.innerHTML = " ";
|
|
23610
|
-
document.body.appendChild(div);
|
|
23611
|
-
cachedScrollbarWidth = div.offsetWidth - div.scrollWidth;
|
|
23612
|
-
document.body.removeChild(div);
|
|
23613
|
-
}
|
|
23614
|
-
return cachedScrollbarWidth;
|
|
23615
|
-
}
|
|
23616
|
-
function rtlScrollLeft() {
|
|
23617
|
-
if (cachedRtlScrollLeft === null && canCreateElement()) {
|
|
23618
|
-
const outer = document.createElement('div');
|
|
23619
|
-
outer.style.direction = 'rtl';
|
|
23620
|
-
outer.style.display = 'block';
|
|
23621
|
-
outer.style.clear = 'both';
|
|
23622
|
-
outer.style.width = '100px';
|
|
23623
|
-
outer.style.visibility = 'hidden';
|
|
23624
|
-
outer.style.position = 'absolute';
|
|
23625
|
-
outer.style.left = '-10000px';
|
|
23626
|
-
outer.style.overflow = 'scroll';
|
|
23627
|
-
outer.style.zoom = '1';
|
|
23628
|
-
const inner = document.createElement('div');
|
|
23629
|
-
inner.style.width = '200px';
|
|
23630
|
-
inner.style.height = '1px';
|
|
23631
|
-
outer.append(inner);
|
|
23632
|
-
document.body.appendChild(outer);
|
|
23633
|
-
const initial = outer.scrollLeft;
|
|
23634
|
-
outer.scrollLeft = -1;
|
|
23635
|
-
cachedRtlScrollLeft = outer.scrollLeft < 0 ? outer.scrollLeft : initial;
|
|
23636
|
-
document.body.removeChild(outer);
|
|
23590
|
+
const convertDateStringsInFilter = (filter) => {
|
|
23591
|
+
if (!filter) {
|
|
23592
|
+
return filter;
|
|
23637
23593
|
}
|
|
23638
|
-
|
|
23639
|
-
|
|
23640
|
-
|
|
23641
|
-
|
|
23642
|
-
|
|
23643
|
-
*/
|
|
23644
|
-
class BrowserSupportService {
|
|
23645
|
-
zone;
|
|
23646
|
-
changeDetector;
|
|
23647
|
-
changes = new EventEmitter();
|
|
23648
|
-
subscriptions;
|
|
23649
|
-
constructor(zone, changeDetector) {
|
|
23650
|
-
this.zone = zone;
|
|
23651
|
-
this.changeDetector = changeDetector;
|
|
23652
|
-
if (typeof window === 'undefined') {
|
|
23653
|
-
return;
|
|
23654
|
-
}
|
|
23655
|
-
this.zone.runOutsideAngular(() => {
|
|
23656
|
-
this.subscriptions = fromEvent(window, 'resize').pipe(auditTime(100)).subscribe(() => {
|
|
23657
|
-
if (cachedPixelRatio !== window.devicePixelRatio) {
|
|
23658
|
-
zone.run(() => {
|
|
23659
|
-
cachedScrollbarWidth = null;
|
|
23660
|
-
this.changes.emit();
|
|
23661
|
-
this.changeDetector.markForCheck();
|
|
23662
|
-
});
|
|
23663
|
-
}
|
|
23664
|
-
});
|
|
23665
|
-
});
|
|
23594
|
+
if (filter.filters && Array.isArray(filter.filters)) {
|
|
23595
|
+
return {
|
|
23596
|
+
...filter,
|
|
23597
|
+
filters: filter.filters.map(f => convertDateStringsInFilter(f))
|
|
23598
|
+
};
|
|
23666
23599
|
}
|
|
23667
|
-
|
|
23668
|
-
if (
|
|
23669
|
-
|
|
23670
|
-
|
|
23600
|
+
if (filter.field && filter.value !== undefined) {
|
|
23601
|
+
if (typeof filter.value === 'string' && isDateOperator(filter.operator)) {
|
|
23602
|
+
const date = parseDate(filter.value);
|
|
23603
|
+
return {
|
|
23604
|
+
...filter,
|
|
23605
|
+
value: date || filter.value
|
|
23606
|
+
};
|
|
23671
23607
|
}
|
|
23672
23608
|
}
|
|
23673
|
-
|
|
23674
|
-
return scrollbarWidth();
|
|
23675
|
-
}
|
|
23676
|
-
get rtlScrollLeft() {
|
|
23677
|
-
return rtlScrollLeft();
|
|
23678
|
-
}
|
|
23679
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: BrowserSupportService, deps: [{ token: i0.NgZone }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
23680
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: BrowserSupportService });
|
|
23681
|
-
}
|
|
23682
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: BrowserSupportService, decorators: [{
|
|
23683
|
-
type: Injectable
|
|
23684
|
-
}], ctorParameters: () => [{ type: i0.NgZone }, { type: i0.ChangeDetectorRef }] });
|
|
23685
|
-
|
|
23686
|
-
const isGroupItem = (source) => {
|
|
23687
|
-
return source.items !== undefined &&
|
|
23688
|
-
source.field !== undefined;
|
|
23689
|
-
};
|
|
23690
|
-
const flattenGroups = (groups) => (groups.reduce((acc, curr) => {
|
|
23691
|
-
if (isGroupItem(curr)) {
|
|
23692
|
-
return acc.concat(flattenGroups(curr.items));
|
|
23693
|
-
}
|
|
23694
|
-
return acc.concat([curr]);
|
|
23695
|
-
}, []));
|
|
23696
|
-
/**
|
|
23697
|
-
* @hidden
|
|
23698
|
-
*/
|
|
23699
|
-
const itemAt = (data, index) => {
|
|
23700
|
-
const first = data[0];
|
|
23701
|
-
if (isPresent(first) && isGroupItem(first)) {
|
|
23702
|
-
return flattenGroups(data)[index];
|
|
23703
|
-
}
|
|
23704
|
-
return data[index];
|
|
23609
|
+
return filter;
|
|
23705
23610
|
};
|
|
23706
23611
|
/**
|
|
23707
23612
|
* @hidden
|
|
23708
23613
|
*/
|
|
23709
|
-
const
|
|
23710
|
-
const
|
|
23711
|
-
|
|
23712
|
-
|
|
23713
|
-
|
|
23714
|
-
return new ItemIterator(data, dataIndex, parentGroupIndex, parentGroup);
|
|
23614
|
+
const isDateOperator = (operator) => {
|
|
23615
|
+
const dateOperators = [
|
|
23616
|
+
'eq', 'neq', 'lt', 'lte', 'gt', 'gte'
|
|
23617
|
+
];
|
|
23618
|
+
return dateOperators.includes(operator);
|
|
23715
23619
|
};
|
|
23716
|
-
class ArrayIterator {
|
|
23717
|
-
arr;
|
|
23718
|
-
idx;
|
|
23719
|
-
constructor(arr, idx = 0) {
|
|
23720
|
-
this.arr = arr;
|
|
23721
|
-
this.idx = idx;
|
|
23722
|
-
this.arr = arr || [];
|
|
23723
|
-
}
|
|
23724
|
-
[iterator]() {
|
|
23725
|
-
return this;
|
|
23726
|
-
}
|
|
23727
|
-
next() {
|
|
23728
|
-
return this.idx < this.arr.length ? {
|
|
23729
|
-
done: false,
|
|
23730
|
-
value: this.arr[this.idx++]
|
|
23731
|
-
} : { done: true, value: undefined };
|
|
23732
|
-
}
|
|
23733
|
-
}
|
|
23734
|
-
/**
|
|
23735
|
-
* @hidden
|
|
23736
|
-
*/
|
|
23737
|
-
class Iterator {
|
|
23738
|
-
dataIndex;
|
|
23739
|
-
resultMap;
|
|
23740
|
-
_innerIterator;
|
|
23741
|
-
constructor(arr, dataIndex = 0, resultMap = (x) => x) {
|
|
23742
|
-
this.dataIndex = dataIndex;
|
|
23743
|
-
this.resultMap = resultMap;
|
|
23744
|
-
const iter = arr[iterator];
|
|
23745
|
-
this._innerIterator = iter ? arr[iterator]() : new ArrayIterator(arr);
|
|
23746
|
-
}
|
|
23747
|
-
[iterator]() {
|
|
23748
|
-
return this;
|
|
23749
|
-
}
|
|
23750
|
-
next() {
|
|
23751
|
-
return this.resultMap(this._innerIterator.next(), this.dataIndex++);
|
|
23752
|
-
}
|
|
23753
|
-
}
|
|
23754
23620
|
/**
|
|
23755
23621
|
* @hidden
|
|
23622
|
+
* Processes cell highlights for a specific filter and item.
|
|
23756
23623
|
*/
|
|
23757
|
-
|
|
23758
|
-
|
|
23759
|
-
|
|
23760
|
-
|
|
23761
|
-
|
|
23762
|
-
|
|
23763
|
-
|
|
23764
|
-
|
|
23765
|
-
|
|
23766
|
-
|
|
23767
|
-
}
|
|
23768
|
-
}));
|
|
23769
|
-
}
|
|
23770
|
-
/**
|
|
23771
|
-
* The index of the next record.
|
|
23772
|
-
* @readonly
|
|
23773
|
-
* @type {number}
|
|
23774
|
-
*/
|
|
23775
|
-
get index() {
|
|
23776
|
-
return this.dataIndex;
|
|
23777
|
-
}
|
|
23778
|
-
}
|
|
23779
|
-
const prefix = (s, n) => {
|
|
23780
|
-
const p = s ? s + "_" : s;
|
|
23781
|
-
return `${p}${n}`;
|
|
23624
|
+
const processCellHighlights = (filter, rowIndex, columns, highlightItems) => {
|
|
23625
|
+
Object.keys(filter.cells).forEach((columnField) => {
|
|
23626
|
+
const actualColumnIndex = Array.from(columns).findIndex((col) => col.field === columnField);
|
|
23627
|
+
if (actualColumnIndex !== -1) {
|
|
23628
|
+
highlightItems.push({
|
|
23629
|
+
itemKey: rowIndex,
|
|
23630
|
+
columnKey: actualColumnIndex,
|
|
23631
|
+
});
|
|
23632
|
+
}
|
|
23633
|
+
});
|
|
23782
23634
|
};
|
|
23783
23635
|
/**
|
|
23784
23636
|
* @hidden
|
|
23637
|
+
* Processes filtered results and adds highlight items.
|
|
23785
23638
|
*/
|
|
23786
|
-
|
|
23787
|
-
|
|
23788
|
-
|
|
23789
|
-
|
|
23790
|
-
|
|
23791
|
-
parentIndex;
|
|
23792
|
-
groupIndex;
|
|
23793
|
-
parentGroup;
|
|
23794
|
-
current;
|
|
23795
|
-
_innerIterator;
|
|
23796
|
-
_iterator;
|
|
23797
|
-
currentGroupIndex = "";
|
|
23798
|
-
constructor(arr, outputFooters = false, level = 0, dataIndex = 0, parentIndex = '', groupIndex = 0, parentGroup = undefined) {
|
|
23799
|
-
this.arr = arr;
|
|
23800
|
-
this.outputFooters = outputFooters;
|
|
23801
|
-
this.level = level;
|
|
23802
|
-
this.dataIndex = dataIndex;
|
|
23803
|
-
this.parentIndex = parentIndex;
|
|
23804
|
-
this.groupIndex = groupIndex;
|
|
23805
|
-
this.parentGroup = parentGroup;
|
|
23806
|
-
this.arr = arr || [];
|
|
23807
|
-
this._iterator = new Iterator(this.arr, this.dataIndex);
|
|
23808
|
-
}
|
|
23809
|
-
[iterator]() {
|
|
23810
|
-
return this;
|
|
23811
|
-
}
|
|
23812
|
-
nextGroupItem() {
|
|
23813
|
-
this.current = this._iterator.next().value;
|
|
23814
|
-
this._innerIterator = null;
|
|
23815
|
-
if (this.current) {
|
|
23816
|
-
this.currentGroupIndex = prefix(this.parentIndex, this.groupIndex++);
|
|
23817
|
-
return {
|
|
23818
|
-
done: false,
|
|
23819
|
-
value: {
|
|
23820
|
-
data: this.current,
|
|
23821
|
-
index: this.currentGroupIndex,
|
|
23822
|
-
level: this.level,
|
|
23823
|
-
type: 'group',
|
|
23824
|
-
parentGroup: this.parentGroup
|
|
23825
|
-
}
|
|
23826
|
-
};
|
|
23827
|
-
}
|
|
23828
|
-
else {
|
|
23829
|
-
this.current = null;
|
|
23830
|
-
return { done: true, value: undefined };
|
|
23831
|
-
}
|
|
23832
|
-
}
|
|
23833
|
-
footerItem() {
|
|
23834
|
-
if (this.current) {
|
|
23835
|
-
const group = this.current;
|
|
23836
|
-
this.current = null;
|
|
23837
|
-
return {
|
|
23838
|
-
done: false,
|
|
23839
|
-
value: {
|
|
23840
|
-
data: group,
|
|
23841
|
-
groupIndex: this.currentGroupIndex,
|
|
23842
|
-
level: this.level,
|
|
23843
|
-
type: 'footer',
|
|
23844
|
-
group: {
|
|
23845
|
-
data: group,
|
|
23846
|
-
index: this.currentGroupIndex,
|
|
23847
|
-
level: this.level,
|
|
23848
|
-
type: 'group',
|
|
23849
|
-
parentGroup: this.parentGroup
|
|
23850
|
-
}
|
|
23851
|
-
}
|
|
23852
|
-
};
|
|
23639
|
+
const processFilteredResults = (filteredResults, data, filter, columns, highlightItems) => {
|
|
23640
|
+
filteredResults?.forEach((item) => {
|
|
23641
|
+
const rowIndex = data.findIndex((dataItem) => dataItem === item);
|
|
23642
|
+
if (filter.cells && Object.keys(filter.cells).length > 0) {
|
|
23643
|
+
processCellHighlights(filter, rowIndex, columns, highlightItems);
|
|
23853
23644
|
}
|
|
23854
23645
|
else {
|
|
23855
|
-
|
|
23856
|
-
|
|
23857
|
-
}
|
|
23858
|
-
}
|
|
23859
|
-
innerIterator(group) {
|
|
23860
|
-
if (!this._innerIterator) {
|
|
23861
|
-
this._innerIterator = getIterator(group.items, {
|
|
23862
|
-
dataIndex: this.dataIndex,
|
|
23863
|
-
footers: this.outputFooters,
|
|
23864
|
-
level: this.level + 1,
|
|
23865
|
-
parentGroupIndex: this.currentGroupIndex,
|
|
23866
|
-
parentGroup: {
|
|
23867
|
-
data: this.current,
|
|
23868
|
-
index: this.currentGroupIndex,
|
|
23869
|
-
level: this.level,
|
|
23870
|
-
type: 'group',
|
|
23871
|
-
parentGroup: this.parentGroup
|
|
23872
|
-
}
|
|
23646
|
+
highlightItems.push({
|
|
23647
|
+
itemKey: rowIndex,
|
|
23873
23648
|
});
|
|
23874
23649
|
}
|
|
23875
|
-
|
|
23876
|
-
|
|
23877
|
-
nextDataItem(group) {
|
|
23878
|
-
const iterator = this.innerIterator(group);
|
|
23879
|
-
const result = iterator.next();
|
|
23880
|
-
if (isPresent(result.value) && !result.done && result.value.type === "data") {
|
|
23881
|
-
this.dataIndex = result.value.index + 1;
|
|
23882
|
-
}
|
|
23883
|
-
return !result.done ? result : undefined;
|
|
23884
|
-
}
|
|
23885
|
-
next() {
|
|
23886
|
-
if (!isPresent(this.current)) {
|
|
23887
|
-
return this.nextGroupItem();
|
|
23888
|
-
}
|
|
23889
|
-
const item = this.nextDataItem(this.current);
|
|
23890
|
-
return item ? item : (this.outputFooters ? this.footerItem() : this.nextGroupItem());
|
|
23891
|
-
}
|
|
23892
|
-
/**
|
|
23893
|
-
* The index of the last iterated data record.
|
|
23894
|
-
* @readonly
|
|
23895
|
-
* @type {number}
|
|
23896
|
-
*/
|
|
23897
|
-
get index() {
|
|
23898
|
-
return this.dataIndex + 1;
|
|
23899
|
-
}
|
|
23900
|
-
}
|
|
23901
|
-
|
|
23650
|
+
});
|
|
23651
|
+
};
|
|
23902
23652
|
/**
|
|
23903
23653
|
* @hidden
|
|
23654
|
+
* Highlights items in a grid based on the provided filters and columns.
|
|
23655
|
+
* @param data - The data to be highlighted.
|
|
23656
|
+
* @param filters - The composite highlight descriptors containing the filters and logic.
|
|
23657
|
+
* @param columns - The columns of the grid.
|
|
23658
|
+
* @returns An array of HighlightItem objects representing the highlighted items.
|
|
23904
23659
|
*/
|
|
23905
|
-
|
|
23906
|
-
|
|
23907
|
-
|
|
23908
|
-
|
|
23909
|
-
|
|
23910
|
-
|
|
23911
|
-
|
|
23912
|
-
this.skip = skip;
|
|
23913
|
-
this.groupFooters = groupFooters;
|
|
23914
|
-
this.source = this.source ? this.source : [];
|
|
23915
|
-
this.isObject = this.isGridDataResult(this.source);
|
|
23916
|
-
}
|
|
23917
|
-
isGridDataResult(source) {
|
|
23918
|
-
return source.total !== undefined && source.data !== undefined;
|
|
23919
|
-
}
|
|
23920
|
-
get total() {
|
|
23921
|
-
return this.isObject ? this.source.total : this.source.length;
|
|
23922
|
-
}
|
|
23923
|
-
get data() {
|
|
23924
|
-
return this.isObject ? this.source.data : this.source;
|
|
23925
|
-
}
|
|
23926
|
-
map(fn) {
|
|
23927
|
-
return this.data.map(fn);
|
|
23928
|
-
}
|
|
23929
|
-
filter(fn) {
|
|
23930
|
-
return this.data.filter(fn);
|
|
23931
|
-
}
|
|
23932
|
-
reduce(fn, init) {
|
|
23933
|
-
return this.data.reduce(fn, init);
|
|
23934
|
-
}
|
|
23935
|
-
forEach(fn) {
|
|
23936
|
-
this.data.forEach(fn);
|
|
23937
|
-
}
|
|
23938
|
-
some(fn) {
|
|
23939
|
-
return this.data.some(fn);
|
|
23940
|
-
}
|
|
23941
|
-
[iterator]() {
|
|
23942
|
-
return getIterator(this.data, {
|
|
23943
|
-
dataIndex: this.skip,
|
|
23944
|
-
footers: this.groupFooters,
|
|
23945
|
-
groupIndex: this.skip
|
|
23660
|
+
const highlightBy = (data, filters, columns) => {
|
|
23661
|
+
const highlightItems = [];
|
|
23662
|
+
filters.forEach((filter) => {
|
|
23663
|
+
const processedFilters = filter.filters.map((filter) => convertDateStringsInFilter(filter));
|
|
23664
|
+
const filteredResults = filterBy(data, {
|
|
23665
|
+
logic: filter.logic || "and",
|
|
23666
|
+
filters: processedFilters,
|
|
23946
23667
|
});
|
|
23947
|
-
|
|
23948
|
-
|
|
23949
|
-
|
|
23950
|
-
|
|
23951
|
-
* @hidden
|
|
23952
|
-
*/
|
|
23953
|
-
class DataCollection {
|
|
23954
|
-
accessor;
|
|
23955
|
-
constructor(accessor) {
|
|
23956
|
-
this.accessor = accessor;
|
|
23957
|
-
}
|
|
23958
|
-
get total() { return this.accessor().total; }
|
|
23959
|
-
get length() { return this.accessor().data.length; }
|
|
23960
|
-
get first() { return this.accessor().data[0]; }
|
|
23961
|
-
get last() { return this.accessor().data[this.length - 1]; }
|
|
23962
|
-
at(index) {
|
|
23963
|
-
return itemAt(this.accessor().data, index);
|
|
23964
|
-
}
|
|
23965
|
-
map(fn) { return this.accessor().map(fn); }
|
|
23966
|
-
filter(fn) {
|
|
23967
|
-
return this.accessor().filter(fn);
|
|
23968
|
-
}
|
|
23969
|
-
reduce(fn, init) {
|
|
23970
|
-
return this.accessor().reduce(fn, init);
|
|
23971
|
-
}
|
|
23972
|
-
forEach(fn) {
|
|
23973
|
-
this.accessor().forEach(fn);
|
|
23974
|
-
}
|
|
23975
|
-
some(fn) {
|
|
23976
|
-
return this.accessor().some(fn);
|
|
23977
|
-
}
|
|
23978
|
-
[iterator]() {
|
|
23979
|
-
return this.accessor()[iterator]();
|
|
23980
|
-
}
|
|
23981
|
-
toString() { return this.accessor().toString(); }
|
|
23982
|
-
}
|
|
23668
|
+
processFilteredResults(filteredResults, data, filter, columns, highlightItems);
|
|
23669
|
+
});
|
|
23670
|
+
return highlightItems;
|
|
23671
|
+
};
|
|
23983
23672
|
|
|
23984
23673
|
/**
|
|
23985
23674
|
* @hidden
|
|
23986
23675
|
*
|
|
23987
|
-
*
|
|
23988
|
-
*
|
|
23989
|
-
* Supports both primitive keys and object keys (compared by reference).
|
|
23676
|
+
* Service that builds AI requests and processes AI responses for the Grid.
|
|
23677
|
+
* Used internally by both the Grid component and the AI Assistant tool.
|
|
23990
23678
|
*/
|
|
23991
|
-
class
|
|
23992
|
-
|
|
23993
|
-
|
|
23994
|
-
|
|
23995
|
-
|
|
23996
|
-
|
|
23997
|
-
|
|
23998
|
-
|
|
23999
|
-
get size() {
|
|
24000
|
-
return this.totalKeysCount;
|
|
23679
|
+
class GridAIRequestResponseService {
|
|
23680
|
+
ctx;
|
|
23681
|
+
columnInfoService;
|
|
23682
|
+
zone;
|
|
23683
|
+
constructor(ctx, columnInfoService, zone) {
|
|
23684
|
+
this.ctx = ctx;
|
|
23685
|
+
this.columnInfoService = columnInfoService;
|
|
23686
|
+
this.zone = zone;
|
|
24001
23687
|
}
|
|
24002
23688
|
/**
|
|
24003
|
-
*
|
|
24004
|
-
*
|
|
24005
|
-
* For single keys, the Y value is the SINGLE_KEY_SYMBOL.
|
|
24006
|
-
*
|
|
24007
|
-
* Map { 'foo' => Set { Symbol(SINGLE_KEY) } } // single key: {x: 'foo'}
|
|
24008
|
-
* Map { 'foo2' => Set { 'bar', 'baz' } } // pairs: {x: 'foo2', y: 'bar'}, {x: 'foo2', y: 'baz'}
|
|
23689
|
+
* Builds the request body for the AI service based on the Grid's column structure.
|
|
23690
|
+
* Returns a column descriptor tree that includes column metadata for the AI service.
|
|
24009
23691
|
*/
|
|
24010
|
-
|
|
23692
|
+
buildRequestBody(promptMessage, role) {
|
|
23693
|
+
const columnsTree = this.buildColumnDescriptors();
|
|
23694
|
+
return {
|
|
23695
|
+
role: role || 'user',
|
|
23696
|
+
contents: [
|
|
23697
|
+
{
|
|
23698
|
+
text: promptMessage
|
|
23699
|
+
}
|
|
23700
|
+
],
|
|
23701
|
+
columns: columnsTree
|
|
23702
|
+
};
|
|
23703
|
+
}
|
|
24011
23704
|
/**
|
|
24012
|
-
*
|
|
23705
|
+
* Builds a nested column descriptor tree based on the Grid's column structure.
|
|
23706
|
+
* Includes root columns and their nested children (for ColumnGroup and SpanColumn).
|
|
24013
23707
|
*/
|
|
24014
|
-
|
|
24015
|
-
|
|
24016
|
-
|
|
24017
|
-
|
|
24018
|
-
|
|
24019
|
-
|
|
23708
|
+
buildColumnDescriptors() {
|
|
23709
|
+
const rootColumns = this.ctx?.grid?.columnList?.rootColumns() || [];
|
|
23710
|
+
const buildDescriptor = (col) => {
|
|
23711
|
+
const hasChildren = Boolean(col.hasChildren && col.childrenArray?.length);
|
|
23712
|
+
const descriptor = {
|
|
23713
|
+
id: col.id,
|
|
23714
|
+
field: col.field,
|
|
23715
|
+
header: col.title
|
|
23716
|
+
};
|
|
23717
|
+
if (hasChildren) {
|
|
23718
|
+
descriptor.columns = col.childrenArray.map((c) => buildDescriptor(c));
|
|
23719
|
+
}
|
|
23720
|
+
// For special columns that don't have a field, emit an optional type token
|
|
23721
|
+
// so the AI service knows how to treat them (checkbox/command/reorder)
|
|
23722
|
+
if (!col.field) {
|
|
23723
|
+
if (isCheckboxColumn(col)) {
|
|
23724
|
+
descriptor.type = 'checkbox';
|
|
24020
23725
|
}
|
|
24021
|
-
else {
|
|
24022
|
-
|
|
23726
|
+
else if (col instanceof CommandColumnComponent) {
|
|
23727
|
+
descriptor.type = 'command';
|
|
24023
23728
|
}
|
|
24024
|
-
}
|
|
24025
|
-
|
|
23729
|
+
}
|
|
23730
|
+
return descriptor;
|
|
23731
|
+
};
|
|
23732
|
+
return rootColumns.map((col) => buildDescriptor(col));
|
|
24026
23733
|
}
|
|
24027
23734
|
/**
|
|
24028
|
-
*
|
|
23735
|
+
* Processes AI response commands and applies them to the Grid.
|
|
23736
|
+
* Returns an array of display messages for each command.
|
|
24029
23737
|
*/
|
|
24030
|
-
|
|
24031
|
-
|
|
24032
|
-
|
|
24033
|
-
|
|
24034
|
-
if (!this.hasSingle(keyX)) {
|
|
24035
|
-
this.keysX.get(keyX).add(PairSet.SINGLE_KEY_SYMBOL);
|
|
24036
|
-
this.totalKeysCount += 1;
|
|
24037
|
-
}
|
|
23738
|
+
processCommands(commands, columns, leafColumns) {
|
|
23739
|
+
const messages = [];
|
|
23740
|
+
this.executeCommands(commands || [], columns, leafColumns, messages);
|
|
23741
|
+
return messages;
|
|
24038
23742
|
}
|
|
24039
|
-
|
|
24040
|
-
|
|
24041
|
-
|
|
24042
|
-
|
|
24043
|
-
|
|
24044
|
-
|
|
23743
|
+
executeCommands(commands, columns, leafColumns, messages) {
|
|
23744
|
+
if (!commands?.length) {
|
|
23745
|
+
return;
|
|
23746
|
+
}
|
|
23747
|
+
const grid = this.ctx.grid;
|
|
23748
|
+
const isFilterable = Boolean(grid.filterable);
|
|
23749
|
+
const isSortable = Boolean(grid.sortable);
|
|
23750
|
+
const isGroupable = Boolean(grid.groupable);
|
|
23751
|
+
const findColumnById = (id) => grid.columnList.toArray().find((c) => c.id === id);
|
|
23752
|
+
const updateColumnHierarchy = (column, updater) => {
|
|
23753
|
+
const changed = [];
|
|
23754
|
+
const queue = [column];
|
|
23755
|
+
while (queue.length) {
|
|
23756
|
+
const current = queue.shift();
|
|
23757
|
+
if (!current) {
|
|
23758
|
+
continue;
|
|
23759
|
+
}
|
|
23760
|
+
const didChange = updater(current);
|
|
23761
|
+
if (didChange) {
|
|
23762
|
+
changed.push(current);
|
|
23763
|
+
}
|
|
23764
|
+
if (current.hasChildren && current.childrenArray?.length) {
|
|
23765
|
+
queue.push(...current.childrenArray);
|
|
23766
|
+
}
|
|
23767
|
+
}
|
|
23768
|
+
return changed;
|
|
23769
|
+
};
|
|
23770
|
+
commands.forEach((cmd) => {
|
|
23771
|
+
let displayMessage = cmd.message || '';
|
|
23772
|
+
if (this.isColumnCommand(cmd.type)) {
|
|
23773
|
+
if (cmd.id) {
|
|
23774
|
+
const column = findColumnById(cmd.id);
|
|
23775
|
+
const replacement = this.getColumnReplacement(column);
|
|
23776
|
+
displayMessage = this.replaceQuotedColumnId(displayMessage, replacement);
|
|
23777
|
+
}
|
|
23778
|
+
}
|
|
23779
|
+
messages.push(displayMessage);
|
|
23780
|
+
switch (cmd.type) {
|
|
23781
|
+
case 'GridSort':
|
|
23782
|
+
if (!isSortable) {
|
|
23783
|
+
break;
|
|
23784
|
+
}
|
|
23785
|
+
this.processArrayResponse([cmd.sort], grid.currentState.sort || [], (item) => item.field, (mergedArray) => grid.sortChange.next(mergedArray));
|
|
23786
|
+
break;
|
|
23787
|
+
case 'GridClearSort':
|
|
23788
|
+
if (!isSortable) {
|
|
23789
|
+
break;
|
|
23790
|
+
}
|
|
23791
|
+
grid.sortChange.next([]);
|
|
23792
|
+
break;
|
|
23793
|
+
case 'GridFilter':
|
|
23794
|
+
if (!isFilterable) {
|
|
23795
|
+
break;
|
|
23796
|
+
}
|
|
23797
|
+
this.processFilterResponse(cmd.filter);
|
|
23798
|
+
break;
|
|
23799
|
+
case 'GridClearFilter':
|
|
23800
|
+
if (!isFilterable) {
|
|
23801
|
+
break;
|
|
23802
|
+
}
|
|
23803
|
+
grid.filterChange.next(undefined);
|
|
23804
|
+
break;
|
|
23805
|
+
case 'GridGroup':
|
|
23806
|
+
if (!isGroupable) {
|
|
23807
|
+
break;
|
|
23808
|
+
}
|
|
23809
|
+
this.processArrayResponse([cmd.group], grid.currentState.group || [], (item) => item.field, (mergedArray) => grid.groupChange.next(mergedArray));
|
|
23810
|
+
break;
|
|
23811
|
+
case 'GridClearGroup':
|
|
23812
|
+
if (!isGroupable) {
|
|
23813
|
+
break;
|
|
23814
|
+
}
|
|
23815
|
+
grid.groupChange.next([]);
|
|
23816
|
+
break;
|
|
23817
|
+
case 'GridHighlight':
|
|
23818
|
+
if (!this.ctx.highlightDirective) {
|
|
23819
|
+
break;
|
|
23820
|
+
}
|
|
23821
|
+
this.processHighlightResponse([cmd.highlight], columns);
|
|
23822
|
+
break;
|
|
23823
|
+
case 'GridClearHighlight':
|
|
23824
|
+
if (!this.ctx.highlightDirective) {
|
|
23825
|
+
break;
|
|
23826
|
+
}
|
|
23827
|
+
this.ctx.highlightDirective['setState']([]);
|
|
23828
|
+
break;
|
|
23829
|
+
case 'GridSelect': {
|
|
23830
|
+
this.processSelectionResponse([cmd.select], columns, leafColumns, messages);
|
|
23831
|
+
break;
|
|
23832
|
+
}
|
|
23833
|
+
case 'GridClearSelect': {
|
|
23834
|
+
const selectionInstance = this.getSelectionInstance();
|
|
23835
|
+
if (!selectionInstance) {
|
|
23836
|
+
this.updateLastMessage(messages, this.ctx.localization?.get('aiAssistantSelectionNotEnabled'));
|
|
23837
|
+
break;
|
|
23838
|
+
}
|
|
23839
|
+
this.applySelectionState(selectionInstance, []);
|
|
23840
|
+
break;
|
|
23841
|
+
}
|
|
23842
|
+
case 'GridColumnResize': {
|
|
23843
|
+
const col = findColumnById(cmd.id);
|
|
23844
|
+
if (!col) {
|
|
23845
|
+
break;
|
|
23846
|
+
}
|
|
23847
|
+
let newWidth;
|
|
23848
|
+
if (typeof cmd.size === 'number') {
|
|
23849
|
+
newWidth = cmd.size;
|
|
23850
|
+
}
|
|
23851
|
+
else if (typeof cmd.size === 'string') {
|
|
23852
|
+
const numericPart = parseFloat(cmd.size);
|
|
23853
|
+
if (!isNaN(numericPart)) {
|
|
23854
|
+
newWidth = numericPart;
|
|
23855
|
+
}
|
|
23856
|
+
}
|
|
23857
|
+
if (typeof newWidth === 'number') {
|
|
23858
|
+
const oldWidth = col.width;
|
|
23859
|
+
col.width = newWidth;
|
|
23860
|
+
const args = [{ column: col, oldWidth: oldWidth, newWidth: newWidth }];
|
|
23861
|
+
grid.columnResize.emit(args);
|
|
23862
|
+
}
|
|
23863
|
+
break;
|
|
23864
|
+
}
|
|
23865
|
+
case 'GridColumnReorder': {
|
|
23866
|
+
const col = findColumnById(cmd.id);
|
|
23867
|
+
if (!col) {
|
|
23868
|
+
break;
|
|
23869
|
+
}
|
|
23870
|
+
const newPosition = Number(cmd.position);
|
|
23871
|
+
if (!isNaN(newPosition) && newPosition >= 0) {
|
|
23872
|
+
this.changeColumnPosition(col, newPosition);
|
|
23873
|
+
}
|
|
23874
|
+
break;
|
|
23875
|
+
}
|
|
23876
|
+
case 'GridColumnShow':
|
|
23877
|
+
case 'GridColumnHide': {
|
|
23878
|
+
const col = findColumnById(cmd.id);
|
|
23879
|
+
if (!col) {
|
|
23880
|
+
break;
|
|
23881
|
+
}
|
|
23882
|
+
const targetHidden = cmd.type === 'GridColumnHide';
|
|
23883
|
+
const changed = updateColumnHierarchy(col, (current) => {
|
|
23884
|
+
if (current.hidden === targetHidden) {
|
|
23885
|
+
return false;
|
|
23886
|
+
}
|
|
23887
|
+
current.hidden = targetHidden;
|
|
23888
|
+
return true;
|
|
23889
|
+
});
|
|
23890
|
+
if (changed.length) {
|
|
23891
|
+
this.columnInfoService.changeVisibility(changed);
|
|
23892
|
+
}
|
|
23893
|
+
break;
|
|
23894
|
+
}
|
|
23895
|
+
case 'GridColumnLock':
|
|
23896
|
+
case 'GridColumnUnlock': {
|
|
23897
|
+
const col = findColumnById(cmd.id);
|
|
23898
|
+
if (!col) {
|
|
23899
|
+
break;
|
|
23900
|
+
}
|
|
23901
|
+
const targetLocked = cmd.type === 'GridColumnLock';
|
|
23902
|
+
const changed = updateColumnHierarchy(col, (current) => {
|
|
23903
|
+
if (current.locked === targetLocked) {
|
|
23904
|
+
return false;
|
|
23905
|
+
}
|
|
23906
|
+
current.locked = targetLocked;
|
|
23907
|
+
return true;
|
|
23908
|
+
});
|
|
23909
|
+
if (changed.length) {
|
|
23910
|
+
this.columnInfoService.changeLocked(changed);
|
|
23911
|
+
}
|
|
23912
|
+
break;
|
|
23913
|
+
}
|
|
23914
|
+
case 'GridPage': {
|
|
23915
|
+
this.processPageCommand(cmd);
|
|
23916
|
+
break;
|
|
23917
|
+
}
|
|
23918
|
+
case 'GridPageSize': {
|
|
23919
|
+
this.processPageSizeCommand(cmd);
|
|
23920
|
+
break;
|
|
23921
|
+
}
|
|
23922
|
+
case 'GridExportExcel': {
|
|
23923
|
+
this.runExportWithFileName(this.ctx.excelComponent, cmd.fileName, () => grid.saveAsExcel());
|
|
23924
|
+
break;
|
|
23925
|
+
}
|
|
23926
|
+
case 'GridExportPDF': {
|
|
23927
|
+
this.runExportWithFileName(this.ctx.pdfComponent, cmd.fileName, () => grid.emitPDFExportEvent());
|
|
23928
|
+
break;
|
|
23929
|
+
}
|
|
23930
|
+
default:
|
|
23931
|
+
break;
|
|
23932
|
+
}
|
|
23933
|
+
});
|
|
23934
|
+
}
|
|
23935
|
+
processArrayResponse(newItems, currentItems, getField, updateGrid) {
|
|
23936
|
+
if (newItems?.length === 0) {
|
|
23937
|
+
updateGrid([]);
|
|
23938
|
+
}
|
|
23939
|
+
else if (newItems?.length) {
|
|
23940
|
+
let mergedArray = [...newItems];
|
|
23941
|
+
const newFields = newItems.map(getField);
|
|
23942
|
+
const existingItemsToKeep = currentItems.filter(item => !newFields.includes(getField(item)));
|
|
23943
|
+
mergedArray = [...mergedArray, ...existingItemsToKeep];
|
|
23944
|
+
updateGrid(mergedArray);
|
|
23945
|
+
}
|
|
23946
|
+
}
|
|
23947
|
+
runExportWithFileName(component, fileName, action) {
|
|
23948
|
+
if (!component || !fileName) {
|
|
23949
|
+
action();
|
|
23950
|
+
return;
|
|
23951
|
+
}
|
|
23952
|
+
const previousFileName = component.fileName;
|
|
23953
|
+
component.fileName = fileName;
|
|
23954
|
+
action();
|
|
23955
|
+
const isExcel = component === this.ctx.excelComponent;
|
|
23956
|
+
if (isExcel) {
|
|
23957
|
+
this.zone.runOutsideAngular(() => {
|
|
23958
|
+
this.ctx.excelComponent.fileCreated.subscribe(() => {
|
|
23959
|
+
component.fileName = previousFileName;
|
|
23960
|
+
});
|
|
23961
|
+
});
|
|
23962
|
+
}
|
|
23963
|
+
else {
|
|
23964
|
+
component.fileName = previousFileName;
|
|
23965
|
+
}
|
|
23966
|
+
}
|
|
23967
|
+
processPageCommand(command) {
|
|
23968
|
+
const pageSize = this.getCurrentPageSizeValue();
|
|
23969
|
+
if (!isPresent$1(pageSize) || pageSize <= 0) {
|
|
23970
|
+
return;
|
|
23971
|
+
}
|
|
23972
|
+
const total = this.getTotalItemsCount();
|
|
23973
|
+
const requestedPage = Number(command.page);
|
|
23974
|
+
let targetPage = Number.isFinite(requestedPage) ? Math.floor(requestedPage) : 1;
|
|
23975
|
+
if (targetPage < 1) {
|
|
23976
|
+
targetPage = 1;
|
|
23977
|
+
}
|
|
23978
|
+
if (isPresent$1(total) && pageSize > 0) {
|
|
23979
|
+
const maxPage = Math.max(1, Math.ceil(total / pageSize));
|
|
23980
|
+
targetPage = Math.min(targetPage, maxPage);
|
|
23981
|
+
}
|
|
23982
|
+
const skip = (targetPage - 1) * pageSize;
|
|
23983
|
+
this.emitGridPageChange(skip, pageSize);
|
|
23984
|
+
}
|
|
23985
|
+
processPageSizeCommand(command) {
|
|
23986
|
+
const rawPageSize = Number(command.pageSize);
|
|
23987
|
+
if (!Number.isFinite(rawPageSize)) {
|
|
23988
|
+
return;
|
|
23989
|
+
}
|
|
23990
|
+
const newPageSize = Math.max(1, Math.floor(rawPageSize));
|
|
23991
|
+
const skip = Math.max(0, this.ctx.grid?.skip ?? 0);
|
|
23992
|
+
this.ensurePageSizeOption(newPageSize);
|
|
23993
|
+
this.emitGridPageChange(skip, newPageSize);
|
|
23994
|
+
}
|
|
23995
|
+
emitGridPageChange(skip, take) {
|
|
23996
|
+
const grid = this.ctx.grid;
|
|
23997
|
+
const normalizedSkip = Math.max(0, Math.floor(skip));
|
|
23998
|
+
const normalizedTake = Math.max(1, Math.floor(take));
|
|
23999
|
+
grid.skip = normalizedSkip;
|
|
24000
|
+
grid.pageSize = normalizedTake;
|
|
24001
|
+
grid.pageChange.emit({ skip: normalizedSkip, take: normalizedTake });
|
|
24002
|
+
}
|
|
24003
|
+
ensurePageSizeOption(pageSize) {
|
|
24004
|
+
const grid = this.ctx.grid;
|
|
24005
|
+
if (!grid) {
|
|
24006
|
+
return;
|
|
24007
|
+
}
|
|
24008
|
+
const pageable = grid.pageable;
|
|
24009
|
+
if (!pageable || typeof pageable === 'boolean') {
|
|
24010
|
+
return;
|
|
24011
|
+
}
|
|
24012
|
+
const pageSizes = pageable.pageSizes;
|
|
24013
|
+
if (!Array.isArray(pageSizes) || pageSizes.length === 0) {
|
|
24014
|
+
return;
|
|
24015
|
+
}
|
|
24016
|
+
if (pageSizes.includes(pageSize)) {
|
|
24017
|
+
return;
|
|
24018
|
+
}
|
|
24019
|
+
const uniqueSizes = [pageSize, ...pageSizes.filter(size => size !== pageSize)];
|
|
24020
|
+
grid.pageable = {
|
|
24021
|
+
...pageable,
|
|
24022
|
+
pageSizes: uniqueSizes
|
|
24023
|
+
};
|
|
24024
|
+
const changeDetector = grid?.changeDetectorRef;
|
|
24025
|
+
if (changeDetector && typeof changeDetector.markForCheck === 'function') {
|
|
24026
|
+
changeDetector.markForCheck();
|
|
24027
|
+
}
|
|
24028
|
+
}
|
|
24029
|
+
getCurrentPageSizeValue() {
|
|
24030
|
+
const grid = this.ctx.grid;
|
|
24031
|
+
if (!grid) {
|
|
24032
|
+
return null;
|
|
24033
|
+
}
|
|
24034
|
+
const candidates = [grid.pageSize, grid.currentState?.take, this.ctx.dataBindingDirective?.['state']?.take];
|
|
24035
|
+
for (const candidate of candidates) {
|
|
24036
|
+
if (typeof candidate === 'number' && candidate > 0) {
|
|
24037
|
+
return candidate;
|
|
24038
|
+
}
|
|
24039
|
+
}
|
|
24040
|
+
const pageable = grid.pageable;
|
|
24041
|
+
if (pageable && typeof pageable === 'object' && Array.isArray(pageable.pageSizes)) {
|
|
24042
|
+
const numericSize = pageable.pageSizes.find(size => typeof size === 'number' && size > 0);
|
|
24043
|
+
if (numericSize) {
|
|
24044
|
+
return numericSize;
|
|
24045
|
+
}
|
|
24046
|
+
}
|
|
24047
|
+
const originalData = this.ctx.dataBindingDirective?.['originalData'];
|
|
24048
|
+
if (Array.isArray(originalData) && originalData.length > 0) {
|
|
24049
|
+
return originalData.length;
|
|
24050
|
+
}
|
|
24051
|
+
return null;
|
|
24052
|
+
}
|
|
24053
|
+
getTotalItemsCount() {
|
|
24054
|
+
const grid = this.ctx.grid;
|
|
24055
|
+
if (!grid) {
|
|
24056
|
+
return null;
|
|
24057
|
+
}
|
|
24058
|
+
const gridData = grid.data;
|
|
24059
|
+
if (gridData && typeof gridData.total === 'number') {
|
|
24060
|
+
return gridData.total;
|
|
24061
|
+
}
|
|
24062
|
+
const view = grid.view;
|
|
24063
|
+
if (view && typeof view.total === 'number') {
|
|
24064
|
+
return view.total;
|
|
24065
|
+
}
|
|
24066
|
+
const originalData = this.ctx.dataBindingDirective?.['originalData'];
|
|
24067
|
+
if (Array.isArray(originalData)) {
|
|
24068
|
+
return originalData.length;
|
|
24069
|
+
}
|
|
24070
|
+
return null;
|
|
24071
|
+
}
|
|
24072
|
+
getSelectionInstance() {
|
|
24073
|
+
const selectionDirective = this.ctx.grid?.selectionDirective;
|
|
24074
|
+
if (selectionDirective && typeof selectionDirective === 'object') {
|
|
24075
|
+
return selectionDirective;
|
|
24076
|
+
}
|
|
24077
|
+
const defaultSelection = this.ctx.grid?.defaultSelection;
|
|
24078
|
+
if (defaultSelection && typeof defaultSelection === 'object') {
|
|
24079
|
+
return defaultSelection;
|
|
24080
|
+
}
|
|
24081
|
+
return null;
|
|
24082
|
+
}
|
|
24083
|
+
updateLastMessage(messages, newMessage) {
|
|
24084
|
+
if (!messages.length) {
|
|
24085
|
+
return;
|
|
24086
|
+
}
|
|
24087
|
+
messages[messages.length - 1] = newMessage;
|
|
24088
|
+
}
|
|
24089
|
+
isColumnCommand(type) {
|
|
24090
|
+
return type === 'GridColumnResize' ||
|
|
24091
|
+
type === 'GridColumnReorder' ||
|
|
24092
|
+
type === 'GridColumnShow' ||
|
|
24093
|
+
type === 'GridColumnHide' ||
|
|
24094
|
+
type === 'GridColumnLock' ||
|
|
24095
|
+
type === 'GridColumnUnlock';
|
|
24096
|
+
}
|
|
24097
|
+
getColumnReplacement(column) {
|
|
24098
|
+
if (!column) {
|
|
24099
|
+
return '';
|
|
24100
|
+
}
|
|
24101
|
+
if (column.title && String(column.title).trim()) {
|
|
24102
|
+
return String(column.title).trim();
|
|
24103
|
+
}
|
|
24104
|
+
if (column.field && String(column.field).trim()) {
|
|
24105
|
+
return String(column.field).trim();
|
|
24106
|
+
}
|
|
24107
|
+
return '';
|
|
24108
|
+
}
|
|
24109
|
+
replaceQuotedColumnId(message, replacement) {
|
|
24110
|
+
if (!replacement) {
|
|
24111
|
+
const columnIdPattern = /(?:"|")(k-grid\d+-col\d+)(?:"|")\s*/g;
|
|
24112
|
+
return message.replace(columnIdPattern, '').replace(/\s{2,}/g, ' ').trim();
|
|
24113
|
+
}
|
|
24114
|
+
const columnIdPattern = /(?:"|")(k-grid\d+-col\d+)(?:"|")/g;
|
|
24115
|
+
return message.replace(columnIdPattern, (match) => {
|
|
24116
|
+
const isEncoded = match.startsWith('"');
|
|
24117
|
+
return isEncoded ? `"${replacement}"` : `"${replacement}"`;
|
|
24118
|
+
});
|
|
24119
|
+
}
|
|
24120
|
+
getHighlightItems(descriptors, columns) {
|
|
24121
|
+
if (!descriptors?.length) {
|
|
24122
|
+
return [];
|
|
24123
|
+
}
|
|
24124
|
+
const data = this.ctx.dataBindingDirective?.['originalData'] || [];
|
|
24125
|
+
return highlightBy(data, descriptors, columns);
|
|
24126
|
+
}
|
|
24127
|
+
processSelectionResponse(selection, columns, leafColumns, messages) {
|
|
24128
|
+
const selectionInstance = this.getSelectionInstance();
|
|
24129
|
+
if (!selectionInstance) {
|
|
24130
|
+
this.updateLastMessage(messages, this.ctx.localization?.get('aiAssistantSelectionNotEnabled'));
|
|
24131
|
+
return;
|
|
24132
|
+
}
|
|
24133
|
+
const descriptors = (selection || []).filter((descriptor) => Boolean(descriptor));
|
|
24134
|
+
if (descriptors.length === 0) {
|
|
24135
|
+
this.applySelectionState(selectionInstance, []);
|
|
24136
|
+
return;
|
|
24137
|
+
}
|
|
24138
|
+
const highlightItems = this.getHighlightItems(descriptors, columns);
|
|
24139
|
+
if (!highlightItems.length) {
|
|
24140
|
+
this.applySelectionState(selectionInstance, []);
|
|
24141
|
+
return;
|
|
24142
|
+
}
|
|
24143
|
+
const hasCellSelections = highlightItems.some(item => isPresent$1(item.columnKey));
|
|
24144
|
+
const hasRowSelections = highlightItems.some(item => !isPresent$1(item.columnKey));
|
|
24145
|
+
const isCellMode = selectionInstance.isCellSelectionMode;
|
|
24146
|
+
if ((!isCellMode && hasCellSelections) || (isCellMode && hasRowSelections)) {
|
|
24147
|
+
const key = isCellMode ? 'aiAssistantSelectionRowModeRequired' : 'aiAssistantSelectionCellModeRequired';
|
|
24148
|
+
this.updateLastMessage(messages, this.ctx.localization?.get(key));
|
|
24149
|
+
return;
|
|
24150
|
+
}
|
|
24151
|
+
const selectionState = this.mapHighlightItemsToSelection(selectionInstance, highlightItems, isCellMode, leafColumns);
|
|
24152
|
+
this.applySelectionState(selectionInstance, selectionState);
|
|
24153
|
+
}
|
|
24154
|
+
mapHighlightItemsToSelection(selectionInstance, highlightItems, isCellMode, leafColumns) {
|
|
24155
|
+
const data = this.ctx.dataBindingDirective?.['originalData'] || [];
|
|
24156
|
+
if (isCellMode) {
|
|
24157
|
+
const mapped = highlightItems
|
|
24158
|
+
.filter(item => isPresent$1(item.itemKey) && isPresent$1(item.columnKey))
|
|
24159
|
+
.map(item => {
|
|
24160
|
+
const rowIndex = item.itemKey;
|
|
24161
|
+
const columnIndex = item.columnKey;
|
|
24162
|
+
const dataItem = data[rowIndex];
|
|
24163
|
+
if (!isPresent$1(dataItem)) {
|
|
24164
|
+
return null;
|
|
24165
|
+
}
|
|
24166
|
+
if (typeof selectionInstance['getSelectionItem'] === 'function') {
|
|
24167
|
+
const columnComponent = leafColumns[columnIndex];
|
|
24168
|
+
const selectionItem = selectionInstance['getSelectionItem']({ dataItem, index: rowIndex }, columnComponent, columnIndex);
|
|
24169
|
+
if (selectionItem && isPresent$1(selectionItem.itemKey) && isPresent$1(selectionItem.columnKey)) {
|
|
24170
|
+
return selectionItem;
|
|
24171
|
+
}
|
|
24172
|
+
return null;
|
|
24173
|
+
}
|
|
24174
|
+
const itemKey = typeof selectionInstance.getItemKey === 'function'
|
|
24175
|
+
? selectionInstance.getItemKey({ dataItem, index: rowIndex })
|
|
24176
|
+
: rowIndex;
|
|
24177
|
+
return isPresent$1(itemKey) ? { itemKey, columnKey: columnIndex } : null;
|
|
24178
|
+
})
|
|
24179
|
+
.filter((item) => isPresent$1(item));
|
|
24180
|
+
return mapped.filter((item, index, self) => self.findIndex(other => other.itemKey === item.itemKey && other.columnKey === item.columnKey) === index);
|
|
24181
|
+
}
|
|
24182
|
+
const rowKeys = highlightItems
|
|
24183
|
+
.filter(item => isPresent$1(item.itemKey))
|
|
24184
|
+
.map(item => {
|
|
24185
|
+
const rowIndex = item.itemKey;
|
|
24186
|
+
const dataItem = data[rowIndex];
|
|
24187
|
+
if (!isPresent$1(dataItem)) {
|
|
24188
|
+
return null;
|
|
24189
|
+
}
|
|
24190
|
+
if (typeof selectionInstance.getItemKey === 'function') {
|
|
24191
|
+
return selectionInstance.getItemKey({ dataItem, index: rowIndex });
|
|
24192
|
+
}
|
|
24193
|
+
return rowIndex;
|
|
24194
|
+
})
|
|
24195
|
+
.filter(isPresent$1);
|
|
24196
|
+
return Array.from(new Set(rowKeys));
|
|
24197
|
+
}
|
|
24198
|
+
applySelectionState(selectionInstance, selectionState) {
|
|
24199
|
+
selectionInstance.selectedKeys = selectionState;
|
|
24200
|
+
if (typeof selectionInstance['setState'] === 'function') {
|
|
24201
|
+
selectionInstance['setState'](selectionState);
|
|
24202
|
+
}
|
|
24203
|
+
const changeDetector = selectionInstance['cd'];
|
|
24204
|
+
if (changeDetector && typeof changeDetector.markForCheck === 'function') {
|
|
24205
|
+
changeDetector.markForCheck();
|
|
24206
|
+
}
|
|
24207
|
+
if (typeof selectionInstance['notifyChange'] === 'function') {
|
|
24208
|
+
selectionInstance['notifyChange']();
|
|
24209
|
+
}
|
|
24210
|
+
}
|
|
24211
|
+
processHighlightResponse(highlight, columns) {
|
|
24212
|
+
const highlightedItems = this.getHighlightItems(highlight, columns);
|
|
24213
|
+
this.ctx.highlightDirective['setState'](highlightedItems);
|
|
24214
|
+
}
|
|
24215
|
+
processFilterResponse(filter) {
|
|
24216
|
+
const processedFilter = convertDateStringsInFilter(filter);
|
|
24217
|
+
const clearFilter = Object.keys(processedFilter).length === 0;
|
|
24218
|
+
if (clearFilter) {
|
|
24219
|
+
this.ctx.grid.filterChange.next(undefined);
|
|
24220
|
+
}
|
|
24221
|
+
else if (processedFilter?.filters.length) {
|
|
24222
|
+
const currentFilter = this.ctx.grid.currentState.filter;
|
|
24223
|
+
let mergedFilter = processedFilter;
|
|
24224
|
+
if (currentFilter && currentFilter.filters?.length > 0) {
|
|
24225
|
+
mergedFilter = {
|
|
24226
|
+
logic: 'and',
|
|
24227
|
+
filters: [
|
|
24228
|
+
currentFilter,
|
|
24229
|
+
processedFilter
|
|
24230
|
+
]
|
|
24231
|
+
};
|
|
24232
|
+
}
|
|
24233
|
+
this.ctx.grid.filterChange.next(mergedFilter);
|
|
24234
|
+
}
|
|
24235
|
+
}
|
|
24236
|
+
changeColumnPosition(column, newPosition) {
|
|
24237
|
+
const grid = this.ctx.grid;
|
|
24238
|
+
if (!grid?.columns) {
|
|
24239
|
+
return;
|
|
24240
|
+
}
|
|
24241
|
+
const currentColumns = grid.columns.toArray();
|
|
24242
|
+
const currentIndex = currentColumns.findIndex(col => col === column);
|
|
24243
|
+
if (currentIndex === -1) {
|
|
24244
|
+
return;
|
|
24245
|
+
}
|
|
24246
|
+
if (newPosition < 0 || newPosition >= currentColumns.length) {
|
|
24247
|
+
return;
|
|
24248
|
+
}
|
|
24249
|
+
const sortedColumns = currentColumns
|
|
24250
|
+
.map((col, idx) => ({ col, physicalIndex: idx, visualOrder: col.orderIndex ?? idx }))
|
|
24251
|
+
.sort((a, b) => a.visualOrder - b.visualOrder);
|
|
24252
|
+
const currentVisualPos = sortedColumns.findIndex(item => item.physicalIndex === currentIndex);
|
|
24253
|
+
if (currentVisualPos === newPosition) {
|
|
24254
|
+
return;
|
|
24255
|
+
}
|
|
24256
|
+
currentColumns.forEach((col, idx) => {
|
|
24257
|
+
const sortedIndex = sortedColumns.findIndex(item => item.physicalIndex === idx);
|
|
24258
|
+
if (idx === currentIndex) {
|
|
24259
|
+
col.orderIndex = newPosition;
|
|
24260
|
+
}
|
|
24261
|
+
else if (currentVisualPos < newPosition) {
|
|
24262
|
+
col.orderIndex = (sortedIndex > currentVisualPos && sortedIndex <= newPosition)
|
|
24263
|
+
? sortedIndex - 1 : sortedIndex;
|
|
24264
|
+
}
|
|
24265
|
+
else {
|
|
24266
|
+
col.orderIndex = (sortedIndex >= newPosition && sortedIndex < currentVisualPos)
|
|
24267
|
+
? sortedIndex + 1 : sortedIndex;
|
|
24268
|
+
}
|
|
24269
|
+
col.isReordered = true;
|
|
24270
|
+
});
|
|
24271
|
+
grid.columnReorder.emit({
|
|
24272
|
+
column: column,
|
|
24273
|
+
oldIndex: currentVisualPos,
|
|
24274
|
+
newIndex: newPosition
|
|
24275
|
+
});
|
|
24276
|
+
}
|
|
24277
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: GridAIRequestResponseService, deps: [{ token: ContextService }, { token: ColumnInfoService }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
24278
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: GridAIRequestResponseService });
|
|
24279
|
+
}
|
|
24280
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: GridAIRequestResponseService, decorators: [{
|
|
24281
|
+
type: Injectable
|
|
24282
|
+
}], ctorParameters: () => [{ type: ContextService }, { type: ColumnInfoService }, { type: i0.NgZone }] });
|
|
24283
|
+
|
|
24284
|
+
/**
|
|
24285
|
+
* @hidden
|
|
24286
|
+
*/
|
|
24287
|
+
const normalizeSettings = ({ buttonCount = 10, info = true, type = 'numeric', pageSizes = false, previousNext = true, responsive = true, position = 'bottom' }) => ({
|
|
24288
|
+
buttonCount,
|
|
24289
|
+
info,
|
|
24290
|
+
pageSizes,
|
|
24291
|
+
previousNext,
|
|
24292
|
+
type,
|
|
24293
|
+
responsive,
|
|
24294
|
+
position
|
|
24295
|
+
});
|
|
24296
|
+
/**
|
|
24297
|
+
* @hidden
|
|
24298
|
+
*/
|
|
24299
|
+
const normalize = (settings) => normalizeSettings(settings === true ? {} : settings);
|
|
24300
|
+
|
|
24301
|
+
const canCreateElement = () => isDocumentAvailable() && document.createElement;
|
|
24302
|
+
let cachedScrollbarWidth = null;
|
|
24303
|
+
let cachedPixelRatio;
|
|
24304
|
+
let cachedRtlScrollLeft = null;
|
|
24305
|
+
function scrollbarWidth() {
|
|
24306
|
+
if (cachedScrollbarWidth === null && canCreateElement()) {
|
|
24307
|
+
cachedPixelRatio = window.devicePixelRatio || 1;
|
|
24308
|
+
const div = document.createElement("div");
|
|
24309
|
+
div.style.cssText = "overflow:scroll;overflow-x:hidden;zoom:1;clear:both;display:block";
|
|
24310
|
+
div.innerHTML = " ";
|
|
24311
|
+
document.body.appendChild(div);
|
|
24312
|
+
cachedScrollbarWidth = div.offsetWidth - div.scrollWidth;
|
|
24313
|
+
document.body.removeChild(div);
|
|
24314
|
+
}
|
|
24315
|
+
return cachedScrollbarWidth;
|
|
24316
|
+
}
|
|
24317
|
+
function rtlScrollLeft() {
|
|
24318
|
+
if (cachedRtlScrollLeft === null && canCreateElement()) {
|
|
24319
|
+
const outer = document.createElement('div');
|
|
24320
|
+
outer.style.direction = 'rtl';
|
|
24321
|
+
outer.style.display = 'block';
|
|
24322
|
+
outer.style.clear = 'both';
|
|
24323
|
+
outer.style.width = '100px';
|
|
24324
|
+
outer.style.visibility = 'hidden';
|
|
24325
|
+
outer.style.position = 'absolute';
|
|
24326
|
+
outer.style.left = '-10000px';
|
|
24327
|
+
outer.style.overflow = 'scroll';
|
|
24328
|
+
outer.style.zoom = '1';
|
|
24329
|
+
const inner = document.createElement('div');
|
|
24330
|
+
inner.style.width = '200px';
|
|
24331
|
+
inner.style.height = '1px';
|
|
24332
|
+
outer.append(inner);
|
|
24333
|
+
document.body.appendChild(outer);
|
|
24334
|
+
const initial = outer.scrollLeft;
|
|
24335
|
+
outer.scrollLeft = -1;
|
|
24336
|
+
cachedRtlScrollLeft = outer.scrollLeft < 0 ? outer.scrollLeft : initial;
|
|
24337
|
+
document.body.removeChild(outer);
|
|
24338
|
+
}
|
|
24339
|
+
return cachedRtlScrollLeft;
|
|
24340
|
+
}
|
|
24341
|
+
/**
|
|
24342
|
+
* @hidden
|
|
24343
|
+
* move to kendo-common
|
|
24344
|
+
*/
|
|
24345
|
+
class BrowserSupportService {
|
|
24346
|
+
zone;
|
|
24347
|
+
changeDetector;
|
|
24348
|
+
changes = new EventEmitter();
|
|
24349
|
+
subscriptions;
|
|
24350
|
+
constructor(zone, changeDetector) {
|
|
24351
|
+
this.zone = zone;
|
|
24352
|
+
this.changeDetector = changeDetector;
|
|
24353
|
+
if (typeof window === 'undefined') {
|
|
24354
|
+
return;
|
|
24355
|
+
}
|
|
24356
|
+
this.zone.runOutsideAngular(() => {
|
|
24357
|
+
this.subscriptions = fromEvent(window, 'resize').pipe(auditTime(100)).subscribe(() => {
|
|
24358
|
+
if (cachedPixelRatio !== window.devicePixelRatio) {
|
|
24359
|
+
zone.run(() => {
|
|
24360
|
+
cachedScrollbarWidth = null;
|
|
24361
|
+
this.changes.emit();
|
|
24362
|
+
this.changeDetector.markForCheck();
|
|
24363
|
+
});
|
|
24364
|
+
}
|
|
24365
|
+
});
|
|
24366
|
+
});
|
|
24367
|
+
}
|
|
24368
|
+
ngOnDestroy() {
|
|
24369
|
+
if (this.subscriptions) {
|
|
24370
|
+
this.subscriptions.unsubscribe();
|
|
24371
|
+
this.subscriptions = null;
|
|
24372
|
+
}
|
|
24373
|
+
}
|
|
24374
|
+
get scrollbarWidth() {
|
|
24375
|
+
return scrollbarWidth();
|
|
24376
|
+
}
|
|
24377
|
+
get rtlScrollLeft() {
|
|
24378
|
+
return rtlScrollLeft();
|
|
24379
|
+
}
|
|
24380
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: BrowserSupportService, deps: [{ token: i0.NgZone }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
24381
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: BrowserSupportService });
|
|
24382
|
+
}
|
|
24383
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: BrowserSupportService, decorators: [{
|
|
24384
|
+
type: Injectable
|
|
24385
|
+
}], ctorParameters: () => [{ type: i0.NgZone }, { type: i0.ChangeDetectorRef }] });
|
|
24386
|
+
|
|
24387
|
+
const isGroupItem = (source) => {
|
|
24388
|
+
return source.items !== undefined &&
|
|
24389
|
+
source.field !== undefined;
|
|
24390
|
+
};
|
|
24391
|
+
const flattenGroups = (groups) => (groups.reduce((acc, curr) => {
|
|
24392
|
+
if (isGroupItem(curr)) {
|
|
24393
|
+
return acc.concat(flattenGroups(curr.items));
|
|
24394
|
+
}
|
|
24395
|
+
return acc.concat([curr]);
|
|
24396
|
+
}, []));
|
|
24397
|
+
/**
|
|
24398
|
+
* @hidden
|
|
24399
|
+
*/
|
|
24400
|
+
const itemAt = (data, index) => {
|
|
24401
|
+
const first = data[0];
|
|
24402
|
+
if (isPresent(first) && isGroupItem(first)) {
|
|
24403
|
+
return flattenGroups(data)[index];
|
|
24404
|
+
}
|
|
24405
|
+
return data[index];
|
|
24406
|
+
};
|
|
24407
|
+
/**
|
|
24408
|
+
* @hidden
|
|
24409
|
+
*/
|
|
24410
|
+
const getIterator = (data, { footers, level, dataIndex, parentGroupIndex, groupIndex, parentGroup }) => {
|
|
24411
|
+
const first = data[0];
|
|
24412
|
+
if (isPresent(first) && isGroupItem(first)) {
|
|
24413
|
+
return new GroupIterator(data, footers, level, dataIndex, parentGroupIndex, groupIndex, parentGroup);
|
|
24414
|
+
}
|
|
24415
|
+
return new ItemIterator(data, dataIndex, parentGroupIndex, parentGroup);
|
|
24416
|
+
};
|
|
24417
|
+
class ArrayIterator {
|
|
24418
|
+
arr;
|
|
24419
|
+
idx;
|
|
24420
|
+
constructor(arr, idx = 0) {
|
|
24421
|
+
this.arr = arr;
|
|
24422
|
+
this.idx = idx;
|
|
24423
|
+
this.arr = arr || [];
|
|
24424
|
+
}
|
|
24425
|
+
[iterator]() {
|
|
24426
|
+
return this;
|
|
24427
|
+
}
|
|
24428
|
+
next() {
|
|
24429
|
+
return this.idx < this.arr.length ? {
|
|
24430
|
+
done: false,
|
|
24431
|
+
value: this.arr[this.idx++]
|
|
24432
|
+
} : { done: true, value: undefined };
|
|
24433
|
+
}
|
|
24434
|
+
}
|
|
24435
|
+
/**
|
|
24436
|
+
* @hidden
|
|
24437
|
+
*/
|
|
24438
|
+
class Iterator {
|
|
24439
|
+
dataIndex;
|
|
24440
|
+
resultMap;
|
|
24441
|
+
_innerIterator;
|
|
24442
|
+
constructor(arr, dataIndex = 0, resultMap = (x) => x) {
|
|
24443
|
+
this.dataIndex = dataIndex;
|
|
24444
|
+
this.resultMap = resultMap;
|
|
24445
|
+
const iter = arr[iterator];
|
|
24446
|
+
this._innerIterator = iter ? arr[iterator]() : new ArrayIterator(arr);
|
|
24447
|
+
}
|
|
24448
|
+
[iterator]() {
|
|
24449
|
+
return this;
|
|
24450
|
+
}
|
|
24451
|
+
next() {
|
|
24452
|
+
return this.resultMap(this._innerIterator.next(), this.dataIndex++);
|
|
24453
|
+
}
|
|
24454
|
+
}
|
|
24455
|
+
/**
|
|
24456
|
+
* @hidden
|
|
24457
|
+
*/
|
|
24458
|
+
class ItemIterator extends Iterator {
|
|
24459
|
+
constructor(arr, dataIndex, groupIndex, group) {
|
|
24460
|
+
super(arr, dataIndex, (x, idx) => ({
|
|
24461
|
+
done: x.done,
|
|
24462
|
+
value: {
|
|
24463
|
+
data: x.value,
|
|
24464
|
+
groupIndex: groupIndex,
|
|
24465
|
+
index: idx,
|
|
24466
|
+
type: 'data',
|
|
24467
|
+
group
|
|
24468
|
+
}
|
|
24469
|
+
}));
|
|
24470
|
+
}
|
|
24471
|
+
/**
|
|
24472
|
+
* The index of the next record.
|
|
24473
|
+
* @readonly
|
|
24474
|
+
* @type {number}
|
|
24475
|
+
*/
|
|
24476
|
+
get index() {
|
|
24477
|
+
return this.dataIndex;
|
|
24478
|
+
}
|
|
24479
|
+
}
|
|
24480
|
+
const prefix = (s, n) => {
|
|
24481
|
+
const p = s ? s + "_" : s;
|
|
24482
|
+
return `${p}${n}`;
|
|
24483
|
+
};
|
|
24484
|
+
/**
|
|
24485
|
+
* @hidden
|
|
24486
|
+
*/
|
|
24487
|
+
class GroupIterator {
|
|
24488
|
+
arr;
|
|
24489
|
+
outputFooters;
|
|
24490
|
+
level;
|
|
24491
|
+
dataIndex;
|
|
24492
|
+
parentIndex;
|
|
24493
|
+
groupIndex;
|
|
24494
|
+
parentGroup;
|
|
24495
|
+
current;
|
|
24496
|
+
_innerIterator;
|
|
24497
|
+
_iterator;
|
|
24498
|
+
currentGroupIndex = "";
|
|
24499
|
+
constructor(arr, outputFooters = false, level = 0, dataIndex = 0, parentIndex = '', groupIndex = 0, parentGroup = undefined) {
|
|
24500
|
+
this.arr = arr;
|
|
24501
|
+
this.outputFooters = outputFooters;
|
|
24502
|
+
this.level = level;
|
|
24503
|
+
this.dataIndex = dataIndex;
|
|
24504
|
+
this.parentIndex = parentIndex;
|
|
24505
|
+
this.groupIndex = groupIndex;
|
|
24506
|
+
this.parentGroup = parentGroup;
|
|
24507
|
+
this.arr = arr || [];
|
|
24508
|
+
this._iterator = new Iterator(this.arr, this.dataIndex);
|
|
24509
|
+
}
|
|
24510
|
+
[iterator]() {
|
|
24511
|
+
return this;
|
|
24512
|
+
}
|
|
24513
|
+
nextGroupItem() {
|
|
24514
|
+
this.current = this._iterator.next().value;
|
|
24515
|
+
this._innerIterator = null;
|
|
24516
|
+
if (this.current) {
|
|
24517
|
+
this.currentGroupIndex = prefix(this.parentIndex, this.groupIndex++);
|
|
24518
|
+
return {
|
|
24519
|
+
done: false,
|
|
24520
|
+
value: {
|
|
24521
|
+
data: this.current,
|
|
24522
|
+
index: this.currentGroupIndex,
|
|
24523
|
+
level: this.level,
|
|
24524
|
+
type: 'group',
|
|
24525
|
+
parentGroup: this.parentGroup
|
|
24526
|
+
}
|
|
24527
|
+
};
|
|
24528
|
+
}
|
|
24529
|
+
else {
|
|
24530
|
+
this.current = null;
|
|
24531
|
+
return { done: true, value: undefined };
|
|
24532
|
+
}
|
|
24533
|
+
}
|
|
24534
|
+
footerItem() {
|
|
24535
|
+
if (this.current) {
|
|
24536
|
+
const group = this.current;
|
|
24537
|
+
this.current = null;
|
|
24538
|
+
return {
|
|
24539
|
+
done: false,
|
|
24540
|
+
value: {
|
|
24541
|
+
data: group,
|
|
24542
|
+
groupIndex: this.currentGroupIndex,
|
|
24543
|
+
level: this.level,
|
|
24544
|
+
type: 'footer',
|
|
24545
|
+
group: {
|
|
24546
|
+
data: group,
|
|
24547
|
+
index: this.currentGroupIndex,
|
|
24548
|
+
level: this.level,
|
|
24549
|
+
type: 'group',
|
|
24550
|
+
parentGroup: this.parentGroup
|
|
24551
|
+
}
|
|
24552
|
+
}
|
|
24553
|
+
};
|
|
24554
|
+
}
|
|
24555
|
+
else {
|
|
24556
|
+
this.current = null;
|
|
24557
|
+
return { done: true, value: undefined };
|
|
24558
|
+
}
|
|
24559
|
+
}
|
|
24560
|
+
innerIterator(group) {
|
|
24561
|
+
if (!this._innerIterator) {
|
|
24562
|
+
this._innerIterator = getIterator(group.items, {
|
|
24563
|
+
dataIndex: this.dataIndex,
|
|
24564
|
+
footers: this.outputFooters,
|
|
24565
|
+
level: this.level + 1,
|
|
24566
|
+
parentGroupIndex: this.currentGroupIndex,
|
|
24567
|
+
parentGroup: {
|
|
24568
|
+
data: this.current,
|
|
24569
|
+
index: this.currentGroupIndex,
|
|
24570
|
+
level: this.level,
|
|
24571
|
+
type: 'group',
|
|
24572
|
+
parentGroup: this.parentGroup
|
|
24573
|
+
}
|
|
24574
|
+
});
|
|
24575
|
+
}
|
|
24576
|
+
return this._innerIterator;
|
|
24577
|
+
}
|
|
24578
|
+
nextDataItem(group) {
|
|
24579
|
+
const iterator = this.innerIterator(group);
|
|
24580
|
+
const result = iterator.next();
|
|
24581
|
+
if (isPresent(result.value) && !result.done && result.value.type === "data") {
|
|
24582
|
+
this.dataIndex = result.value.index + 1;
|
|
24583
|
+
}
|
|
24584
|
+
return !result.done ? result : undefined;
|
|
24585
|
+
}
|
|
24586
|
+
next() {
|
|
24587
|
+
if (!isPresent(this.current)) {
|
|
24588
|
+
return this.nextGroupItem();
|
|
24589
|
+
}
|
|
24590
|
+
const item = this.nextDataItem(this.current);
|
|
24591
|
+
return item ? item : (this.outputFooters ? this.footerItem() : this.nextGroupItem());
|
|
24592
|
+
}
|
|
24593
|
+
/**
|
|
24594
|
+
* The index of the last iterated data record.
|
|
24595
|
+
* @readonly
|
|
24596
|
+
* @type {number}
|
|
24597
|
+
*/
|
|
24598
|
+
get index() {
|
|
24599
|
+
return this.dataIndex + 1;
|
|
24600
|
+
}
|
|
24601
|
+
}
|
|
24602
|
+
|
|
24603
|
+
/**
|
|
24604
|
+
* @hidden
|
|
24605
|
+
*/
|
|
24606
|
+
class DataResultIterator {
|
|
24607
|
+
source;
|
|
24608
|
+
skip;
|
|
24609
|
+
groupFooters;
|
|
24610
|
+
isObject;
|
|
24611
|
+
constructor(source, skip = 0, groupFooters = false) {
|
|
24612
|
+
this.source = source;
|
|
24613
|
+
this.skip = skip;
|
|
24614
|
+
this.groupFooters = groupFooters;
|
|
24615
|
+
this.source = this.source ? this.source : [];
|
|
24616
|
+
this.isObject = this.isGridDataResult(this.source);
|
|
24617
|
+
}
|
|
24618
|
+
isGridDataResult(source) {
|
|
24619
|
+
return source.total !== undefined && source.data !== undefined;
|
|
24620
|
+
}
|
|
24621
|
+
get total() {
|
|
24622
|
+
return this.isObject ? this.source.total : this.source.length;
|
|
24623
|
+
}
|
|
24624
|
+
get data() {
|
|
24625
|
+
return this.isObject ? this.source.data : this.source;
|
|
24626
|
+
}
|
|
24627
|
+
map(fn) {
|
|
24628
|
+
return this.data.map(fn);
|
|
24629
|
+
}
|
|
24630
|
+
filter(fn) {
|
|
24631
|
+
return this.data.filter(fn);
|
|
24632
|
+
}
|
|
24633
|
+
reduce(fn, init) {
|
|
24634
|
+
return this.data.reduce(fn, init);
|
|
24635
|
+
}
|
|
24636
|
+
forEach(fn) {
|
|
24637
|
+
this.data.forEach(fn);
|
|
24638
|
+
}
|
|
24639
|
+
some(fn) {
|
|
24640
|
+
return this.data.some(fn);
|
|
24641
|
+
}
|
|
24642
|
+
[iterator]() {
|
|
24643
|
+
return getIterator(this.data, {
|
|
24644
|
+
dataIndex: this.skip,
|
|
24645
|
+
footers: this.groupFooters,
|
|
24646
|
+
groupIndex: this.skip
|
|
24647
|
+
});
|
|
24648
|
+
}
|
|
24649
|
+
toString() { return this.data.toString(); }
|
|
24650
|
+
}
|
|
24651
|
+
/**
|
|
24652
|
+
* @hidden
|
|
24653
|
+
*/
|
|
24654
|
+
class DataCollection {
|
|
24655
|
+
accessor;
|
|
24656
|
+
constructor(accessor) {
|
|
24657
|
+
this.accessor = accessor;
|
|
24658
|
+
}
|
|
24659
|
+
get total() { return this.accessor().total; }
|
|
24660
|
+
get length() { return this.accessor().data.length; }
|
|
24661
|
+
get first() { return this.accessor().data[0]; }
|
|
24662
|
+
get last() { return this.accessor().data[this.length - 1]; }
|
|
24663
|
+
at(index) {
|
|
24664
|
+
return itemAt(this.accessor().data, index);
|
|
24665
|
+
}
|
|
24666
|
+
map(fn) { return this.accessor().map(fn); }
|
|
24667
|
+
filter(fn) {
|
|
24668
|
+
return this.accessor().filter(fn);
|
|
24669
|
+
}
|
|
24670
|
+
reduce(fn, init) {
|
|
24671
|
+
return this.accessor().reduce(fn, init);
|
|
24672
|
+
}
|
|
24673
|
+
forEach(fn) {
|
|
24674
|
+
this.accessor().forEach(fn);
|
|
24675
|
+
}
|
|
24676
|
+
some(fn) {
|
|
24677
|
+
return this.accessor().some(fn);
|
|
24678
|
+
}
|
|
24679
|
+
[iterator]() {
|
|
24680
|
+
return this.accessor()[iterator]();
|
|
24681
|
+
}
|
|
24682
|
+
toString() { return this.accessor().toString(); }
|
|
24683
|
+
}
|
|
24684
|
+
|
|
24685
|
+
/**
|
|
24686
|
+
* @hidden
|
|
24687
|
+
*
|
|
24688
|
+
* Quick look-up structure for combinations of keys or single keys.
|
|
24689
|
+
* Similar to the native JS Set, however, working with single keys or a couple of keys.
|
|
24690
|
+
* Supports both primitive keys and object keys (compared by reference).
|
|
24691
|
+
*/
|
|
24692
|
+
class PairSet {
|
|
24693
|
+
/**
|
|
24694
|
+
* Symbol used internally to represent "no Y key" when storing single X keys.
|
|
24695
|
+
*/
|
|
24696
|
+
static SINGLE_KEY_SYMBOL = Symbol('SINGLE_KEY');
|
|
24697
|
+
/**
|
|
24698
|
+
* Gets the total number of key entries (both single keys and key pairs).
|
|
24699
|
+
*/
|
|
24700
|
+
get size() {
|
|
24701
|
+
return this.totalKeysCount;
|
|
24702
|
+
}
|
|
24703
|
+
/**
|
|
24704
|
+
* Holds a set of Y keys for each defined X key.
|
|
24705
|
+
* Each X key creates a map which holds a set of Y keys.
|
|
24706
|
+
* For single keys, the Y value is the SINGLE_KEY_SYMBOL.
|
|
24707
|
+
*
|
|
24708
|
+
* Map { 'foo' => Set { Symbol(SINGLE_KEY) } } // single key: {x: 'foo'}
|
|
24709
|
+
* Map { 'foo2' => Set { 'bar', 'baz' } } // pairs: {x: 'foo2', y: 'bar'}, {x: 'foo2', y: 'baz'}
|
|
24710
|
+
*/
|
|
24711
|
+
keysX = new Map();
|
|
24712
|
+
/**
|
|
24713
|
+
* Count each added or deleted key manually to avoid iterating over all items when calling `this.size`.
|
|
24714
|
+
*/
|
|
24715
|
+
totalKeysCount = 0;
|
|
24716
|
+
constructor(items, keyXField, keyYField) {
|
|
24717
|
+
if (items && keyXField) {
|
|
24718
|
+
items.forEach(item => {
|
|
24719
|
+
if (keyYField && item[keyYField] !== undefined) {
|
|
24720
|
+
this.add(item[keyXField], item[keyYField]);
|
|
24721
|
+
}
|
|
24722
|
+
else {
|
|
24723
|
+
this.addSingle(item[keyXField]);
|
|
24724
|
+
}
|
|
24725
|
+
});
|
|
24726
|
+
}
|
|
24727
|
+
}
|
|
24728
|
+
/**
|
|
24729
|
+
* Adds a single key entry.
|
|
24730
|
+
*/
|
|
24731
|
+
addSingle(keyX) {
|
|
24732
|
+
if (!this.keysX.has(keyX)) {
|
|
24733
|
+
this.keysX.set(keyX, new Set());
|
|
24734
|
+
}
|
|
24735
|
+
if (!this.hasSingle(keyX)) {
|
|
24736
|
+
this.keysX.get(keyX).add(PairSet.SINGLE_KEY_SYMBOL);
|
|
24737
|
+
this.totalKeysCount += 1;
|
|
24738
|
+
}
|
|
24739
|
+
}
|
|
24740
|
+
/**
|
|
24741
|
+
* Adds a couple of items identified as a combination.
|
|
24742
|
+
*/
|
|
24743
|
+
add(keyX, keyY) {
|
|
24744
|
+
if (!this.keysX.has(keyX)) {
|
|
24745
|
+
this.keysX.set(keyX, new Set());
|
|
24045
24746
|
}
|
|
24046
24747
|
if (!this.has(keyX, keyY)) {
|
|
24047
24748
|
this.keysX.get(keyX).add(keyY);
|
|
@@ -30728,6 +31429,8 @@ class GridComponent {
|
|
|
30728
31429
|
adaptiveGridService;
|
|
30729
31430
|
rowReorderService;
|
|
30730
31431
|
dataMappingService;
|
|
31432
|
+
aiRequestResponseService;
|
|
31433
|
+
idService;
|
|
30731
31434
|
/**
|
|
30732
31435
|
* Sets the data of the Grid. If you provide an array, the Grid gets the total count automatically.
|
|
30733
31436
|
* ([more information and example]({% slug binding_grid %})).
|
|
@@ -31685,7 +32388,7 @@ class GridComponent {
|
|
|
31685
32388
|
rowReorderSubscription;
|
|
31686
32389
|
rtl = false;
|
|
31687
32390
|
_rowSticky;
|
|
31688
|
-
constructor(supportService, selectionService, cellSelectionService, wrapper, groupInfoService, groupsService, changeNotification, detailsService, editService, filterService, pdfService, responsiveService, renderer, excelService, ngZone, scrollSyncService, domEvents, columnResizingService, changeDetectorRef, columnReorderService, columnInfoService, navigationService, sortService, scrollRequestService, localization, ctx, sizingService, adaptiveGridService, rowReorderService, dataMappingService) {
|
|
32391
|
+
constructor(supportService, selectionService, cellSelectionService, wrapper, groupInfoService, groupsService, changeNotification, detailsService, editService, filterService, pdfService, responsiveService, renderer, excelService, ngZone, scrollSyncService, domEvents, columnResizingService, changeDetectorRef, columnReorderService, columnInfoService, navigationService, sortService, scrollRequestService, localization, ctx, sizingService, adaptiveGridService, rowReorderService, dataMappingService, aiRequestResponseService, idService) {
|
|
31689
32392
|
this.supportService = supportService;
|
|
31690
32393
|
this.selectionService = selectionService;
|
|
31691
32394
|
this.cellSelectionService = cellSelectionService;
|
|
@@ -31716,6 +32419,8 @@ class GridComponent {
|
|
|
31716
32419
|
this.adaptiveGridService = adaptiveGridService;
|
|
31717
32420
|
this.rowReorderService = rowReorderService;
|
|
31718
32421
|
this.dataMappingService = dataMappingService;
|
|
32422
|
+
this.aiRequestResponseService = aiRequestResponseService;
|
|
32423
|
+
this.idService = idService;
|
|
31719
32424
|
const isValid = validatePackage(packageMetadata);
|
|
31720
32425
|
this.licenseMessage = getLicenseMessage(packageMetadata);
|
|
31721
32426
|
this.showLicenseWatermark = shouldShowValidationUI(isValid);
|
|
@@ -31812,6 +32517,48 @@ class GridComponent {
|
|
|
31812
32517
|
resetGroupsState() {
|
|
31813
32518
|
this.groupsService.reset();
|
|
31814
32519
|
}
|
|
32520
|
+
/**
|
|
32521
|
+
* Builds the request body for the AI service based on the provided prompt message.
|
|
32522
|
+
* Allows developers to construct their own AI service requests.
|
|
32523
|
+
*
|
|
32524
|
+
* @param promptMessage - The prompt message to send to the AI service.
|
|
32525
|
+
* @returns The request body object ready to be sent to the AI service.
|
|
32526
|
+
*
|
|
32527
|
+
* @example
|
|
32528
|
+
* ```ts
|
|
32529
|
+
* const requestBody = this.grid.getAIRequest('Sort by Product Name ascending');
|
|
32530
|
+
*
|
|
32531
|
+
* // Send to your AI service
|
|
32532
|
+
* this.http.post('https://your-ai-service.com/api', requestBody).subscribe(response => {
|
|
32533
|
+
* this.grid.handleAIResponse(response);
|
|
32534
|
+
* });
|
|
32535
|
+
* ```
|
|
32536
|
+
*/
|
|
32537
|
+
getAIRequest(promptMessage) {
|
|
32538
|
+
return this.aiRequestResponseService.buildRequestBody(promptMessage);
|
|
32539
|
+
}
|
|
32540
|
+
/**
|
|
32541
|
+
* Processes an AI service response and applies the commands to the Grid.
|
|
32542
|
+
* Allows developers to handle their own AI service responses manually.
|
|
32543
|
+
*
|
|
32544
|
+
* @param response - The AI service response containing optional message and commands array.
|
|
32545
|
+
*
|
|
32546
|
+
* @example
|
|
32547
|
+
* ```ts
|
|
32548
|
+
* const response = {
|
|
32549
|
+
* message: 'Applying sorting',
|
|
32550
|
+
* commands: [
|
|
32551
|
+
* { type: 'GridSort', sort: { field: 'ProductName', dir: 'asc' }, message: 'Sorted by Product Name' }
|
|
32552
|
+
* ]
|
|
32553
|
+
* };
|
|
32554
|
+
* this.grid.handleAIResponse(response);
|
|
32555
|
+
* ```
|
|
32556
|
+
*/
|
|
32557
|
+
handleAIResponse(response) {
|
|
32558
|
+
const columns = this.columnInfoService.leafNamedColumns?.map((col) => ({ field: col.field })) || [];
|
|
32559
|
+
const leafColumns = this.columnInfoService.leafNamedColumns || [];
|
|
32560
|
+
this.aiRequestResponseService.processCommands(response.commands || [], columns, leafColumns);
|
|
32561
|
+
}
|
|
31815
32562
|
/**
|
|
31816
32563
|
* @hidden
|
|
31817
32564
|
*/
|
|
@@ -32585,7 +33332,7 @@ class GridComponent {
|
|
|
32585
33332
|
autoGenerateColumns() {
|
|
32586
33333
|
if (this.shouldGenerateColumns && !this.columns.length && this.view.length) {
|
|
32587
33334
|
this.columns.reset(Object.keys(this.view.at(0)).map(field => {
|
|
32588
|
-
const column = new ColumnComponent();
|
|
33335
|
+
const column = new ColumnComponent(undefined, this.idService);
|
|
32589
33336
|
column.field = field;
|
|
32590
33337
|
return column;
|
|
32591
33338
|
}));
|
|
@@ -32976,7 +33723,7 @@ class GridComponent {
|
|
|
32976
33723
|
this.dragTargetContainer?.notify();
|
|
32977
33724
|
this.dropTargetContainer?.notify();
|
|
32978
33725
|
}
|
|
32979
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: GridComponent, deps: [{ token: BrowserSupportService }, { token: SelectionService }, { token: CellSelectionService }, { token: i0.ElementRef }, { token: GroupInfoService }, { token: GroupsService }, { token: ChangeNotificationService }, { token: DetailsService }, { token: EditService }, { token: FilterService }, { token: PDFService }, { token: ResponsiveService }, { token: i0.Renderer2 }, { token: ExcelService }, { token: i0.NgZone }, { token: ScrollSyncService }, { token: DomEventsService }, { token: ColumnResizingService }, { token: i0.ChangeDetectorRef }, { token: ColumnReorderService }, { token: ColumnInfoService }, { token: NavigationService }, { token: SortService }, { token: ScrollRequestService }, { token: i1$2.LocalizationService }, { token: ContextService }, { token: SizingOptionsService }, { token: AdaptiveGridService }, { token: RowReorderService }, { token: DataMappingService }], target: i0.ɵɵFactoryTarget.Component });
|
|
33726
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: GridComponent, deps: [{ token: BrowserSupportService }, { token: SelectionService }, { token: CellSelectionService }, { token: i0.ElementRef }, { token: GroupInfoService }, { token: GroupsService }, { token: ChangeNotificationService }, { token: DetailsService }, { token: EditService }, { token: FilterService }, { token: PDFService }, { token: ResponsiveService }, { token: i0.Renderer2 }, { token: ExcelService }, { token: i0.NgZone }, { token: ScrollSyncService }, { token: DomEventsService }, { token: ColumnResizingService }, { token: i0.ChangeDetectorRef }, { token: ColumnReorderService }, { token: ColumnInfoService }, { token: NavigationService }, { token: SortService }, { token: ScrollRequestService }, { token: i1$2.LocalizationService }, { token: ContextService }, { token: SizingOptionsService }, { token: AdaptiveGridService }, { token: RowReorderService }, { token: DataMappingService }, { token: GridAIRequestResponseService }, { token: IdService }], target: i0.ɵɵFactoryTarget.Component });
|
|
32980
33727
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.14", type: GridComponent, isStandalone: true, selector: "kendo-grid", inputs: { data: "data", pageSize: "pageSize", height: "height", rowHeight: "rowHeight", adaptiveMode: "adaptiveMode", detailRowHeight: "detailRowHeight", skip: "skip", scrollable: "scrollable", selectable: "selectable", sort: "sort", size: "size", trackBy: "trackBy", filter: "filter", group: "group", virtualColumns: "virtualColumns", filterable: "filterable", sortable: "sortable", pageable: "pageable", groupable: "groupable", gridResizable: "gridResizable", rowReorderable: "rowReorderable", navigable: "navigable", autoSize: "autoSize", rowClass: "rowClass", rowSticky: "rowSticky", rowSelected: "rowSelected", isRowSelectable: "isRowSelectable", cellSelected: "cellSelected", resizable: "resizable", reorderable: "reorderable", loading: "loading", columnMenu: "columnMenu", hideHeader: "hideHeader", showInactiveTools: "showInactiveTools", isDetailExpanded: "isDetailExpanded", isGroupExpanded: "isGroupExpanded", dataLayoutMode: "dataLayoutMode" }, outputs: { filterChange: "filterChange", pageChange: "pageChange", groupChange: "groupChange", sortChange: "sortChange", selectionChange: "selectionChange", rowReorder: "rowReorder", dataStateChange: "dataStateChange", gridStateChange: "gridStateChange", groupExpand: "groupExpand", groupCollapse: "groupCollapse", detailExpand: "detailExpand", detailCollapse: "detailCollapse", edit: "edit", cancel: "cancel", save: "save", remove: "remove", add: "add", cellClose: "cellClose", cellClick: "cellClick", pdfExport: "pdfExport", excelExport: "excelExport", columnResize: "columnResize", columnReorder: "columnReorder", columnVisibilityChange: "columnVisibilityChange", columnLockedChange: "columnLockedChange", columnStickyChange: "columnStickyChange", scrollBottom: "scrollBottom", contentScroll: "contentScroll" }, host: { properties: { "attr.dir": "this.dir", "class.k-grid": "this.hostClass", "class.k-grid-sm": "this.sizeSmallClass", "class.k-grid-md": "this.sizeMediumClass", "class.k-grid-stack": "this.stackedClass", "class.k-grid-lockedcolumns": "this.lockedClasses", "class.k-grid-virtual": "this.virtualClasses", "class.k-grid-no-scrollbar": "this.noScrollbarClass", "class.k-grid-resizable": "this.isResizable", "style.minWidth": "this.minWidth", "style.maxWidth": "this.maxWidth", "style.minHeight": "this.minHeight", "style.maxHeight": "this.maxHeight" } }, providers: [
|
|
32981
33728
|
BrowserSupportService,
|
|
32982
33729
|
LocalizationService,
|
|
@@ -33023,6 +33770,7 @@ class GridComponent {
|
|
|
33023
33770
|
SizingOptionsService,
|
|
33024
33771
|
RowReorderService,
|
|
33025
33772
|
ClipboardService,
|
|
33773
|
+
GridAIRequestResponseService,
|
|
33026
33774
|
RowspanService,
|
|
33027
33775
|
AdaptiveGridService,
|
|
33028
33776
|
ColumnMenuService,
|
|
@@ -33032,394 +33780,394 @@ class GridComponent {
|
|
|
33032
33780
|
<ng-container kendoGridLocalizedMessages
|
|
33033
33781
|
i18n-groupPanelEmpty="kendo.grid.groupPanelEmpty|The label visible in the Grid group panel when it is empty"
|
|
33034
33782
|
groupPanelEmpty="Drag a column header and drop it here to group by that column"
|
|
33035
|
-
|
|
33783
|
+
|
|
33036
33784
|
i18n-noRecords="kendo.grid.noRecords|The label visible in the Grid when there are no records"
|
|
33037
33785
|
noRecords="No records available."
|
|
33038
|
-
|
|
33786
|
+
|
|
33039
33787
|
i18n-pagerLabel="kendo.grid.pagerLabel|The label for the Grid pager"
|
|
33040
33788
|
pagerLabel="{{ 'Page navigation, page {currentPage} of {totalPages}' }}"
|
|
33041
|
-
|
|
33789
|
+
|
|
33042
33790
|
i18n-pagerFirstPage="kendo.grid.pagerFirstPage|The label for the first page button in Grid pager"
|
|
33043
33791
|
pagerFirstPage="Go to the first page"
|
|
33044
|
-
|
|
33792
|
+
|
|
33045
33793
|
i18n-pagerPreviousPage="kendo.grid.pagerPreviousPage|The label for the previous page button in Grid pager"
|
|
33046
33794
|
pagerPreviousPage="Go to the previous page"
|
|
33047
|
-
|
|
33795
|
+
|
|
33048
33796
|
i18n-pagerNextPage="kendo.grid.pagerNextPage|The label for the next page button in Grid pager"
|
|
33049
33797
|
pagerNextPage="Go to the next page"
|
|
33050
|
-
|
|
33798
|
+
|
|
33051
33799
|
i18n-pagerLastPage="kendo.grid.pagerLastPage|The label for the last page button in Grid pager"
|
|
33052
33800
|
pagerLastPage="Go to the last page"
|
|
33053
|
-
|
|
33801
|
+
|
|
33054
33802
|
i18n-pagerPage="kendo.grid.pagerPage|The label before the current page number in the Grid pager"
|
|
33055
33803
|
pagerPage="Page"
|
|
33056
|
-
|
|
33804
|
+
|
|
33057
33805
|
i18n-pagerOf="kendo.grid.pagerOf|The label before the total pages number in the Grid pager"
|
|
33058
33806
|
pagerOf="of"
|
|
33059
|
-
|
|
33807
|
+
|
|
33060
33808
|
i18n-pagerItems="kendo.grid.pagerItems|The label after the total pages number in the Grid pager"
|
|
33061
33809
|
pagerItems="items"
|
|
33062
|
-
|
|
33810
|
+
|
|
33063
33811
|
i18n-pagerPageNumberInputTitle="kendo.grid.pagerPageNumberInputTitle|The label for the pager input in the Grid pager"
|
|
33064
33812
|
pagerPageNumberInputTitle="Page Number"
|
|
33065
|
-
|
|
33813
|
+
|
|
33066
33814
|
i18n-pagerItemsPerPage="kendo.grid.pagerItemsPerPage|The label for the page size chooser in the Grid pager"
|
|
33067
33815
|
pagerItemsPerPage="items per page"
|
|
33068
|
-
|
|
33816
|
+
|
|
33069
33817
|
i18n-pagerInputLabel="kendo.grid.pagerInputLabel|The text of the aria-label attribute applied to the input element for entering the page number"
|
|
33070
33818
|
pagerInputLabel="Type a page number"
|
|
33071
|
-
|
|
33819
|
+
|
|
33072
33820
|
i18n-filter="kendo.grid.filter|The label of the filter cell or icon"
|
|
33073
33821
|
filter="Filter"
|
|
33074
|
-
|
|
33822
|
+
|
|
33075
33823
|
i18n-filterInputLabel="kendo.grid.filterInputLabel|The label of the filter row and menu inputs"
|
|
33076
33824
|
filterInputLabel="{{ '{columnName} Filter' }}"
|
|
33077
|
-
|
|
33825
|
+
|
|
33078
33826
|
i18n-filterMenuTitle="kendo.grid.filterMenuTitle|The title of the filter menu icon"
|
|
33079
33827
|
filterMenuTitle="{{ '{columnName} Filter Menu' }}"
|
|
33080
|
-
|
|
33828
|
+
|
|
33081
33829
|
i18n-filterMenuOperatorsDropDownLabel="kendo.grid.filterMenuOperatorsDropDownLabel|The label of the filter menu operators dropdown"
|
|
33082
33830
|
filterMenuOperatorsDropDownLabel="{{ '{columnName} Filter Operators' }}"
|
|
33083
|
-
|
|
33831
|
+
|
|
33084
33832
|
i18n-filterCellOperatorLabel="kendo.grid.filterCellOperatorLabel|The label of the filter cell operators dropdown"
|
|
33085
33833
|
filterCellOperatorLabel="{{ 'Filter cell operators for {columnName}' }}"
|
|
33086
|
-
|
|
33834
|
+
|
|
33087
33835
|
i18n-booleanFilterCellLabel="kendo.grid.booleanFilterCellLabel|The label of the boolean filter cell dropdown"
|
|
33088
33836
|
booleanFilterCellLabel="{{ 'Boolean filter cell for {columnName}' }}"
|
|
33089
|
-
|
|
33837
|
+
|
|
33090
33838
|
i18n-filterMenuLogicDropDownLabel="kendo.grid.filterMenuLogicDropDownLabel|The label of the filter menu logic dropdown"
|
|
33091
33839
|
filterMenuLogicDropDownLabel="{{ '{columnName} Filter Logic' }}"
|
|
33092
|
-
|
|
33840
|
+
|
|
33093
33841
|
i18n-filterEqOperator="kendo.grid.filterEqOperator|The text of the equal filter operator"
|
|
33094
33842
|
filterEqOperator="Is equal to"
|
|
33095
|
-
|
|
33843
|
+
|
|
33096
33844
|
i18n-filterNotEqOperator="kendo.grid.filterNotEqOperator|The text of the not equal filter operator"
|
|
33097
33845
|
filterNotEqOperator="Is not equal to"
|
|
33098
|
-
|
|
33846
|
+
|
|
33099
33847
|
i18n-filterIsNullOperator="kendo.grid.filterIsNullOperator|The text of the is null filter operator"
|
|
33100
33848
|
filterIsNullOperator="Is null"
|
|
33101
|
-
|
|
33849
|
+
|
|
33102
33850
|
i18n-filterIsNotNullOperator="kendo.grid.filterIsNotNullOperator|The text of the is not null filter operator"
|
|
33103
33851
|
filterIsNotNullOperator="Is not null"
|
|
33104
|
-
|
|
33852
|
+
|
|
33105
33853
|
i18n-filterIsEmptyOperator="kendo.grid.filterIsEmptyOperator|The text of the is empty filter operator"
|
|
33106
33854
|
filterIsEmptyOperator="Is empty"
|
|
33107
|
-
|
|
33855
|
+
|
|
33108
33856
|
i18n-filterIsNotEmptyOperator="kendo.grid.filterIsNotEmptyOperator|The text of the is not empty filter operator"
|
|
33109
33857
|
filterIsNotEmptyOperator="Is not empty"
|
|
33110
|
-
|
|
33858
|
+
|
|
33111
33859
|
i18n-filterStartsWithOperator="kendo.grid.filterStartsWithOperator|The text of the starts with filter operator"
|
|
33112
33860
|
filterStartsWithOperator="Starts with"
|
|
33113
|
-
|
|
33861
|
+
|
|
33114
33862
|
i18n-filterContainsOperator="kendo.grid.filterContainsOperator|The text of the contains filter operator"
|
|
33115
33863
|
filterContainsOperator="Contains"
|
|
33116
|
-
|
|
33864
|
+
|
|
33117
33865
|
i18n-filterNotContainsOperator="kendo.grid.filterNotContainsOperator|The text of the does not contain filter operator"
|
|
33118
33866
|
filterNotContainsOperator="Does not contain"
|
|
33119
|
-
|
|
33867
|
+
|
|
33120
33868
|
i18n-filterEndsWithOperator="kendo.grid.filterEndsWithOperator|The text of the ends with filter operator"
|
|
33121
33869
|
filterEndsWithOperator="Ends with"
|
|
33122
|
-
|
|
33870
|
+
|
|
33123
33871
|
i18n-filterGteOperator="kendo.grid.filterGteOperator|The text of the greater than or equal filter operator"
|
|
33124
33872
|
filterGteOperator="Is greater than or equal to"
|
|
33125
|
-
|
|
33873
|
+
|
|
33126
33874
|
i18n-filterGtOperator="kendo.grid.filterGtOperator|The text of the greater than filter operator"
|
|
33127
33875
|
filterGtOperator="Is greater than"
|
|
33128
|
-
|
|
33876
|
+
|
|
33129
33877
|
i18n-filterLteOperator="kendo.grid.filterLteOperator|The text of the less than or equal filter operator"
|
|
33130
33878
|
filterLteOperator="Is less than or equal to"
|
|
33131
|
-
|
|
33879
|
+
|
|
33132
33880
|
i18n-filterLtOperator="kendo.grid.filterLtOperator|The text of the less than filter operator"
|
|
33133
33881
|
filterLtOperator="Is less than"
|
|
33134
|
-
|
|
33882
|
+
|
|
33135
33883
|
i18n-filterIsTrue="kendo.grid.filterIsTrue|The text of the IsTrue boolean filter option"
|
|
33136
33884
|
filterIsTrue="Is True"
|
|
33137
|
-
|
|
33885
|
+
|
|
33138
33886
|
i18n-filterIsFalse="kendo.grid.filterIsFalse|The text of the IsFalse boolean filter option"
|
|
33139
33887
|
filterIsFalse="Is False"
|
|
33140
|
-
|
|
33888
|
+
|
|
33141
33889
|
i18n-filterBooleanAll="kendo.grid.filterBooleanAll|The text of the (All) boolean filter option"
|
|
33142
33890
|
filterBooleanAll="(All)"
|
|
33143
|
-
|
|
33891
|
+
|
|
33144
33892
|
i18n-filterAfterOrEqualOperator="kendo.grid.filterAfterOrEqualOperator|The text of the after or equal date filter operator"
|
|
33145
33893
|
filterAfterOrEqualOperator="Is after or equal to"
|
|
33146
|
-
|
|
33894
|
+
|
|
33147
33895
|
i18n-filterAfterOperator="kendo.grid.filterAfterOperator|The text of the after date filter operator"
|
|
33148
33896
|
filterAfterOperator="Is after"
|
|
33149
|
-
|
|
33897
|
+
|
|
33150
33898
|
i18n-filterBeforeOperator="kendo.grid.filterBeforeOperator|The text of the before date filter operator"
|
|
33151
33899
|
filterBeforeOperator="Is before"
|
|
33152
|
-
|
|
33900
|
+
|
|
33153
33901
|
i18n-filterBeforeOrEqualOperator="kendo.grid.filterBeforeOrEqualOperator|The text of the before or equal date filter operator"
|
|
33154
33902
|
filterBeforeOrEqualOperator="Is before or equal to"
|
|
33155
|
-
|
|
33903
|
+
|
|
33156
33904
|
i18n-filterFilterButton="kendo.grid.filterFilterButton|The text of the filter button"
|
|
33157
33905
|
filterFilterButton="Filter"
|
|
33158
|
-
|
|
33906
|
+
|
|
33159
33907
|
i18n-filterClearButton="kendo.grid.filterClearButton|The text of the clear filter button"
|
|
33160
33908
|
filterClearButton="Clear"
|
|
33161
|
-
|
|
33909
|
+
|
|
33162
33910
|
i18n-sortClearButton="kendo.grid.sortClearButton|The text of the clear sort button located in the Sort Toolbar Tool and adaptive Sort Toolbar Tool"
|
|
33163
33911
|
sortClearButton="Clear sorting"
|
|
33164
|
-
|
|
33912
|
+
|
|
33165
33913
|
i18n-adaptiveCloseButtonTitle="kendo.grid.adaptiveCloseButtonTitle|The title of the Close button of the ActionSheet that is rendered instead of the Popup when using small screen devices in adaptive mode"
|
|
33166
33914
|
adaptiveCloseButtonTitle="Close"
|
|
33167
|
-
|
|
33915
|
+
|
|
33168
33916
|
i18n-adaptiveBackButtonTitle="kendo.grid.adaptiveBackButtonTitle|The title of the Back button of the ActionSheet that is rendered instead of the Popup when using small screen devices in adaptive mode"
|
|
33169
33917
|
adaptiveBackButtonTitle="Back"
|
|
33170
|
-
|
|
33918
|
+
|
|
33171
33919
|
i18n-filterClearAllButton="kendo.grid.filterClearAllButton|The text of the clear all filters button located in the Filter Toolbar Tool and adaptive Filter Toolbar Tool"
|
|
33172
33920
|
filterClearAllButton="Clear all filters"
|
|
33173
|
-
|
|
33921
|
+
|
|
33174
33922
|
i18n-groupClearButton="kendo.grid.groupClearButton|The text of the clear grouping button in the Group Toolbar Tool and adaptive Group Toolbar Tool"
|
|
33175
33923
|
groupClearButton="Clear grouping"
|
|
33176
|
-
|
|
33924
|
+
|
|
33177
33925
|
i18n-sortDoneButton="kendo.grid.sortDoneButton|The text of the done sort button"
|
|
33178
33926
|
sortDoneButton="Done"
|
|
33179
|
-
|
|
33927
|
+
|
|
33180
33928
|
i18n-groupDoneButton="kendo.grid.groupDoneButton|The text of the done group button in the adaptive Group Toolbar Tool"
|
|
33181
33929
|
groupDoneButton="Done"
|
|
33182
|
-
|
|
33930
|
+
|
|
33183
33931
|
i18n-filterAndLogic="kendo.grid.filterAndLogic|The text of the And filter logic"
|
|
33184
33932
|
filterAndLogic="And"
|
|
33185
|
-
|
|
33933
|
+
|
|
33186
33934
|
i18n-filterOrLogic="kendo.grid.filterOrLogic|The text of the Or filter logic"
|
|
33187
33935
|
filterOrLogic="Or"
|
|
33188
|
-
|
|
33936
|
+
|
|
33189
33937
|
i18n-filterToolbarToolText="kendo.grid.filterToolbarToolText|The button text of the Filter toolbar tool"
|
|
33190
33938
|
filterToolbarToolText="Filter"
|
|
33191
|
-
|
|
33939
|
+
|
|
33192
33940
|
i18n-loading="kendo.grid.loading|The loading text"
|
|
33193
33941
|
loading="Loading"
|
|
33194
|
-
|
|
33942
|
+
|
|
33195
33943
|
i18n-gridLabel="kendo.grid.gridLabel|The Grid aria-label"
|
|
33196
33944
|
gridLabel="Data table"
|
|
33197
|
-
|
|
33945
|
+
|
|
33198
33946
|
i18n-columnMenu="kendo.grid.columnMenu|The title of the column menu icon"
|
|
33199
33947
|
columnMenu="{{ '{columnName} Column Menu' }}"
|
|
33200
|
-
|
|
33948
|
+
|
|
33201
33949
|
i18n-columns="kendo.grid.columns|The text for the Grid Column Chooser and Column Chooser toolbar tool"
|
|
33202
33950
|
columns="Columns"
|
|
33203
|
-
|
|
33951
|
+
|
|
33204
33952
|
i18n-columnsSubtitle="kendo.grid.columnsSubtitle|The subtitle for the adaptive Grid Column Chooser and Column Chooser toolbar tool"
|
|
33205
33953
|
columnsSubtitle="Selected fields are visible"
|
|
33206
|
-
|
|
33954
|
+
|
|
33207
33955
|
i18n-adaptiveFilterTitle="kendo.grid.adaptiveFilterTitle|The title that is displayed in the adaptive Filter Toolbar Tool and Filter Menu"
|
|
33208
33956
|
adaptiveFilterTitle="Filter by"
|
|
33209
|
-
|
|
33957
|
+
|
|
33210
33958
|
i18n-adaptiveFilterOperatorsTitle="kendo.grid.adaptiveFilterOperatorsTitle|The title that is displayed in the Operators Action Sheet"
|
|
33211
33959
|
adaptiveFilterOperatorsTitle="Operators"
|
|
33212
|
-
|
|
33960
|
+
|
|
33213
33961
|
i18n-adaptiveSortTitle="kendo.grid.adaptiveSortTitle|The title that is displayed in the adaptive Sort Toolbar Tool"
|
|
33214
33962
|
adaptiveSortTitle="Sort by"
|
|
33215
|
-
|
|
33963
|
+
|
|
33216
33964
|
i18n-adaptiveGroupTitle="kendo.grid.adaptiveGroupTitle|The title that is displayed in the adaptive Group Toolbar Tool."
|
|
33217
33965
|
adaptiveGroupTitle="Group by"
|
|
33218
|
-
|
|
33966
|
+
|
|
33219
33967
|
i18n-lock="kendo.grid.lock|The text shown in the column menu for the lock item"
|
|
33220
33968
|
lock="Lock"
|
|
33221
|
-
|
|
33969
|
+
|
|
33222
33970
|
i18n-unlock="kendo.grid.unlock|The text shown in the column menu for the unlock item"
|
|
33223
33971
|
unlock="Unlock"
|
|
33224
|
-
|
|
33972
|
+
|
|
33225
33973
|
i18n-setColumnPosition="kendo.grid.setColumnPosition|The text shown in the column menu for the set column position item"
|
|
33226
33974
|
setColumnPosition="Set Column Position"
|
|
33227
|
-
|
|
33975
|
+
|
|
33228
33976
|
i18n-stick="kendo.grid.stick|The text shown in the column menu for the stick item"
|
|
33229
33977
|
stick="Stick"
|
|
33230
|
-
|
|
33978
|
+
|
|
33231
33979
|
i18n-unstick="kendo.grid.unstick|The text shown in the column menu for the unstick item"
|
|
33232
33980
|
unstick="Unstick"
|
|
33233
|
-
|
|
33981
|
+
|
|
33234
33982
|
i18n-sortable="kendo.grid.sortable|The label of the sort icon"
|
|
33235
33983
|
sortable="Sortable"
|
|
33236
|
-
|
|
33984
|
+
|
|
33237
33985
|
i18n-sortAscending="kendo.grid.sortAscending|The text shown in the column menu for the sort ascending item"
|
|
33238
33986
|
sortAscending="Sort Ascending"
|
|
33239
|
-
|
|
33987
|
+
|
|
33240
33988
|
i18n-sortDescending="kendo.grid.sortDescending|The text shown in the column menu for the sort descending item"
|
|
33241
33989
|
sortDescending="Sort Descending"
|
|
33242
|
-
|
|
33990
|
+
|
|
33243
33991
|
i18n-autosizeAllColumns="kendo.grid.autosizeAllColumns|The text shown in the column menu for the autosize all columns item"
|
|
33244
33992
|
autosizeAllColumns="Autosize All Columns"
|
|
33245
|
-
|
|
33993
|
+
|
|
33246
33994
|
i18n-autosizeThisColumn="kendo.grid.autosizeThisColumn|The text shown in the column menu for the autosize this column item"
|
|
33247
33995
|
autosizeThisColumn="Autosize This Column"
|
|
33248
|
-
|
|
33996
|
+
|
|
33249
33997
|
i18n-sortedDefault="kendo.grid.sortedDefault|The status announcement when a column is no longer sorted"
|
|
33250
33998
|
sortedDefault="Not Sorted"
|
|
33251
|
-
|
|
33999
|
+
|
|
33252
34000
|
i18n-sortedAscending="kendo.grid.sortedAscending|The title of the Group Chip indicating the ascending sorting order of the groups"
|
|
33253
34001
|
sortedAscending="Sorted Ascending"
|
|
33254
|
-
|
|
34002
|
+
|
|
33255
34003
|
i18n-sortedDescending="kendo.grid.sortedDescending|The title of the Group Chip indicating the descending sorting order of the groups"
|
|
33256
34004
|
sortedDescending="Sorted Descending"
|
|
33257
|
-
|
|
34005
|
+
|
|
33258
34006
|
i18n-columnsApply="kendo.grid.columnsApply|The text shown in the column menu or column chooser for the columns apply button"
|
|
33259
34007
|
columnsApply="Apply"
|
|
33260
|
-
|
|
34008
|
+
|
|
33261
34009
|
i18n-columnsReset="kendo.grid.columnsReset|The text shown in the column menu or column chooser for the columns reset button"
|
|
33262
34010
|
columnsReset="Reset"
|
|
33263
|
-
|
|
34011
|
+
|
|
33264
34012
|
i18n-detailExpand="kendo.grid.detailExpand|The title of the expand icon of detail rows. Applies also to the expand button text in stacked mode."
|
|
33265
34013
|
detailExpand="Expand Details"
|
|
33266
|
-
|
|
34014
|
+
|
|
33267
34015
|
i18n-detailCollapse="kendo.grid.detailCollapse|The title of the collapse icon of detail rows. Applies also to the collapse button text in stacked mode."
|
|
33268
34016
|
detailCollapse="Collapse Details"
|
|
33269
|
-
|
|
34017
|
+
|
|
33270
34018
|
i18n-filterDateToday="kendo.grid.filterDateToday|The text of the Today button of the Date filter."
|
|
33271
34019
|
filterDateToday="TODAY"
|
|
33272
|
-
|
|
34020
|
+
|
|
33273
34021
|
i18n-filterDateToggle="kendo.grid.filterDateToggle|The title of the Toggle button of the Date filter."
|
|
33274
34022
|
filterDateToggle="Toggle Calendar"
|
|
33275
|
-
|
|
34023
|
+
|
|
33276
34024
|
i18n-filterNumericDecrement="kendo.grid.filterNumericDecrement|The title of the Decrement button of the Numeric filter."
|
|
33277
34025
|
filterNumericDecrement="Decrement"
|
|
33278
|
-
|
|
34026
|
+
|
|
33279
34027
|
i18n-filterNumericIncrement="kendo.grid.filterNumericIncrement|The title of the Increment button of the Numeric filter."
|
|
33280
34028
|
filterNumericIncrement="Increment"
|
|
33281
|
-
|
|
34029
|
+
|
|
33282
34030
|
i18n-selectionCheckboxLabel="kendo.grid.selectionCheckboxLabel|The labels of the checkbox column checkboxes."
|
|
33283
34031
|
selectionCheckboxLabel="Select Row"
|
|
33284
|
-
|
|
34032
|
+
|
|
33285
34033
|
i18n-selectAllCheckboxLabel="kendo.grid.selectAllCheckboxLabel|The label of the checkbox column select all checkbox."
|
|
33286
34034
|
selectAllCheckboxLabel="Select All Rows"
|
|
33287
|
-
|
|
34035
|
+
|
|
33288
34036
|
i18n-sortToolbarToolText="kendo.grid.sortToolbarToolText|The button text of the Sort toolbar tool."
|
|
33289
34037
|
sortToolbarToolText="Sort"
|
|
33290
|
-
|
|
34038
|
+
|
|
33291
34039
|
i18n-groupCollapse="kendo.grid.groupCollapse|The text of the title and aria-label attributes applied to the collapse icon of group rows."
|
|
33292
34040
|
groupCollapse="Collapse Group"
|
|
33293
|
-
|
|
34041
|
+
|
|
33294
34042
|
i18n-groupExpand="kendo.grid.groupExpand|The text of the title and aria-label attributes applied to the expand icon of group rows."
|
|
33295
34043
|
groupExpand="Expand Group"
|
|
33296
|
-
|
|
34044
|
+
|
|
33297
34045
|
i18n-pagerSelectPage="kendo.grid.pagerSelectPage|The text of the title and aria-label attributes applied to the page chooser in the Grid Pager"
|
|
33298
34046
|
pagerSelectPage="Select page"
|
|
33299
|
-
|
|
34047
|
+
|
|
33300
34048
|
i18n-topToolbarLabel="kendo.grid.topToolbarLabel|The label for the Grid top toolbar"
|
|
33301
34049
|
topToolbarLabel="Top toolbar"
|
|
33302
|
-
|
|
34050
|
+
|
|
33303
34051
|
i18n-bottomToolbarLabel="kendo.grid.bottomToolbarLabel|The label for the Grid bottom toolbar"
|
|
33304
34052
|
bottomToolbarLabel="Bottom toolbar"
|
|
33305
|
-
|
|
34053
|
+
|
|
33306
34054
|
i18n-editToolbarToolText="kendo.grid.editToolbarToolText|The text for the Grid Edit toolbar tool"
|
|
33307
34055
|
editToolbarToolText="Edit"
|
|
33308
|
-
|
|
34056
|
+
|
|
33309
34057
|
i18n-saveToolbarToolText="kendo.grid.saveToolbarToolText|The text for the Grid Save toolbar tool"
|
|
33310
34058
|
saveToolbarToolText="Save"
|
|
33311
|
-
|
|
34059
|
+
|
|
33312
34060
|
i18n-addToolbarToolText="kendo.grid.addToolbarToolText|The text for the Grid Add toolbar tool"
|
|
33313
34061
|
addToolbarToolText="Add"
|
|
33314
|
-
|
|
34062
|
+
|
|
33315
34063
|
i18n-cancelToolbarToolText="kendo.grid.cancelToolbarToolText|The text for the Grid Cancel toolbar tool"
|
|
33316
34064
|
cancelToolbarToolText="Cancel"
|
|
33317
|
-
|
|
34065
|
+
|
|
33318
34066
|
i18n-removeToolbarToolText="kendo.grid.removeToolbarToolText|The text for the Grid Remove toolbar tool"
|
|
33319
34067
|
removeToolbarToolText="Delete"
|
|
33320
|
-
|
|
34068
|
+
|
|
33321
34069
|
i18n-excelExportToolbarToolText="kendo.grid.excelExportToolbarToolText|The text for the Grid Excel export toolbar tool"
|
|
33322
34070
|
excelExportToolbarToolText="Excel Export"
|
|
33323
|
-
|
|
34071
|
+
|
|
33324
34072
|
i18n-pdfExportToolbarToolText="kendo.grid.pdfExportToolbarToolText|The text for the Grid PDF export toolbar tool"
|
|
33325
34073
|
pdfExportToolbarToolText="PDF Export"
|
|
33326
|
-
|
|
34074
|
+
|
|
33327
34075
|
i18n-groupPanelLabel="kendo.grid.groupPanelLabel|The label for the Grid group panel toolbar"
|
|
33328
34076
|
groupPanelLabel="Group panel"
|
|
33329
|
-
|
|
34077
|
+
|
|
33330
34078
|
i18n-dragRowHandleLabel="kendo.grid.dragRowHandleLabel|The label for the Grid drag row handle"
|
|
33331
34079
|
dragRowHandleLabel="Drag row"
|
|
33332
|
-
|
|
34080
|
+
|
|
33333
34081
|
i18n-columnMenuFilterTabTitle="kendo.grid.columnMenuFilterTabTitle|The title for the column menu Filter tab"
|
|
33334
34082
|
columnMenuFilterTabTitle="Filter"
|
|
33335
|
-
|
|
34083
|
+
|
|
33336
34084
|
i18n-columnMenuGeneralTabTitle="kendo.grid.columnMenuGeneralTabTitle|The title for the column menu General tab"
|
|
33337
34085
|
columnMenuGeneralTabTitle="General"
|
|
33338
|
-
|
|
34086
|
+
|
|
33339
34087
|
i18n-columnMenuColumnsTabTitle="kendo.grid.columnMenuColumnsTabTitle|The title for the column menu Columns tab"
|
|
33340
34088
|
columnMenuColumnsTabTitle="Columns"
|
|
33341
|
-
|
|
34089
|
+
|
|
33342
34090
|
i18n-groupChipMenuPrevious="kendo.grid.groupChipMenuPrevious|The text for the Group pane Chip Menu Move as previous item"
|
|
33343
34091
|
groupChipMenuPrevious="Move as previous"
|
|
33344
|
-
|
|
34092
|
+
|
|
33345
34093
|
i18n-groupChipMenuNext="kendo.grid.groupChipMenuNext|The text for the Group pane Chip Menu Move as next item"
|
|
33346
34094
|
groupChipMenuNext="Move as next"
|
|
33347
|
-
|
|
34095
|
+
|
|
33348
34096
|
i18n-groupToolbarToolText="kendo.grid.groupToolbarToolText|The button text of the Group toolbar tool"
|
|
33349
34097
|
groupToolbarToolText="Group"
|
|
33350
|
-
|
|
34098
|
+
|
|
33351
34099
|
i18n-formValidationErrorText="kendo.grid.formValidationErrorText|The default text of a form validation error when using external editing."
|
|
33352
34100
|
formValidationErrorText="{{ 'The {fieldName} field has {errorName} validation error' }}"
|
|
33353
|
-
|
|
34101
|
+
|
|
33354
34102
|
i18n-removeConfirmationDialogTitle="kendo.grid.removeConfirmationDialogTitle|The title of the built-in remove item confirmation Dialog"
|
|
33355
34103
|
removeConfirmationDialogTitle="Please confirm"
|
|
33356
|
-
|
|
34104
|
+
|
|
33357
34105
|
i18n-removeConfirmationDialogContent="kendo.grid.removeConfirmationDialogContent|The content of the built-in remove item confirmation Dialog"
|
|
33358
34106
|
removeConfirmationDialogContent="Are you sure you want to delete this item?"
|
|
33359
|
-
|
|
34107
|
+
|
|
33360
34108
|
i18n-removeConfirmationDialogConfirmText="kendo.grid.removeConfirmationDialogConfirmText|The text of the built-in remove item confirmation Dialog confirm action button"
|
|
33361
34109
|
removeConfirmationDialogConfirmText="Yes"
|
|
33362
|
-
|
|
34110
|
+
|
|
33363
34111
|
i18n-removeConfirmationDialogRejectText="kendo.grid.removeConfirmationDialogRejectText|The text of the built-in remove item confirmation Dialog reject action button"
|
|
33364
34112
|
removeConfirmationDialogRejectText="No"
|
|
33365
|
-
|
|
34113
|
+
|
|
33366
34114
|
i18n-externalEditingTitle="kendo.grid.externalEditingTitle|The title of the built-in external editing form container when editing an item"
|
|
33367
34115
|
externalEditingTitle="Edit"
|
|
33368
|
-
|
|
34116
|
+
|
|
33369
34117
|
i18n-externalEditingAddTitle="kendo.grid.externalEditingAddTitle|The title of the built-in external editing form container when adding a new item"
|
|
33370
34118
|
externalEditingAddTitle="Add"
|
|
33371
|
-
|
|
34119
|
+
|
|
33372
34120
|
i18n-externalEditingSaveText="kendo.grid.externalEditingSaveText|The text of the external editing form Save button"
|
|
33373
34121
|
externalEditingSaveText="Save"
|
|
33374
|
-
|
|
34122
|
+
|
|
33375
34123
|
i18n-externalEditingCancelText="kendo.grid.externalEditingCancelText|The text of the external editing form Cancel button"
|
|
33376
34124
|
externalEditingCancelText="Cancel"
|
|
33377
|
-
|
|
34125
|
+
|
|
33378
34126
|
i18n-aiAssistantToolbarToolText="kendo.grid.aiAssistantToolbarToolText|The text of the AI Assistant toolbar tool"
|
|
33379
34127
|
aiAssistantToolbarToolText="AI Assistant"
|
|
33380
|
-
|
|
34128
|
+
|
|
33381
34129
|
i18n-aiAssistantWindowTitle="kendo.grid.aiAssistantWindowTitle|The text of the AI Assistant Window title"
|
|
33382
34130
|
aiAssistantWindowTitle="AI Assistant"
|
|
33383
|
-
|
|
34131
|
+
|
|
33384
34132
|
i18n-aiAssistantApplyButtonText="kendo.grid.aiAssistantApplyButtonText|The text of the AI Assistant Apply button"
|
|
33385
34133
|
aiAssistantApplyButtonText="Apply"
|
|
33386
|
-
|
|
34134
|
+
|
|
33387
34135
|
i18n-aiAssistantWindowCloseTitle="kendo.grid.aiAssistantWindowCloseTitle|The title of the AI Assistant Window close button"
|
|
33388
34136
|
aiAssistantWindowCloseTitle="Close"
|
|
33389
|
-
|
|
34137
|
+
|
|
33390
34138
|
i18n-aiAssistantWindowMaximizeTitle="kendo.grid.aiAssistantWindowMaximizeTitle|The title of the AI Assistant Window maximize button"
|
|
33391
34139
|
aiAssistantWindowMaximizeTitle="Maximize"
|
|
33392
|
-
|
|
34140
|
+
|
|
33393
34141
|
i18n-aiAssistantWindowMinimizeTitle="kendo.grid.aiAssistantWindowMinimizeTitle|The title of the AI Assistant Window minimize button"
|
|
33394
34142
|
aiAssistantWindowMinimizeTitle="Minimize"
|
|
33395
|
-
|
|
34143
|
+
|
|
33396
34144
|
i18n-aiAssistantWindowRestoreTitle="kendo.grid.aiAssistantWindowRestoreTitle|The title of the AI Assistant Window restore button"
|
|
33397
34145
|
aiAssistantWindowRestoreTitle="Restore"
|
|
33398
|
-
|
|
34146
|
+
|
|
33399
34147
|
i18n-aiAssistantOutputCardTitle="kendo.grid.aiAssistantOutputCardTitle|The title of the AI Assistant Prompt Output Card"
|
|
33400
34148
|
aiAssistantOutputCardTitle="Generated with AI"
|
|
33401
|
-
|
|
34149
|
+
|
|
33402
34150
|
i18n-aiAssistantOutputCardBodyContent="kendo.grid.aiAssistantOutputCardBodyContent|The success message dispayed in the AI Assistant Prompt Output Card's body"
|
|
33403
34151
|
aiAssistantOutputCardBodyContent="Operation is successful. Data is:"
|
|
33404
|
-
|
|
34152
|
+
|
|
33405
34153
|
i18n-aiAssistantSelectionNotEnabled="kendo.grid.aiAssistantSelectionNotEnabled|The message shown when AI selection requires the Grid selectable option"
|
|
33406
34154
|
aiAssistantSelectionNotEnabled="Selection can be applied only when the Grid selectable option is enabled."
|
|
33407
|
-
|
|
34155
|
+
|
|
33408
34156
|
i18n-aiAssistantSelectionRowModeRequired="kendo.grid.aiAssistantSelectionRowModeRequired|The message shown when AI selection requires row selection mode"
|
|
33409
34157
|
aiAssistantSelectionRowModeRequired="Selection can be applied only when row selection mode is enabled."
|
|
33410
|
-
|
|
34158
|
+
|
|
33411
34159
|
i18n-aiAssistantSelectionCellModeRequired="kendo.grid.aiAssistantSelectionCellModeRequired|The message shown when AI selection requires cell selection mode"
|
|
33412
34160
|
aiAssistantSelectionCellModeRequired="Selection can be applied only when cell selection mode is enabled."
|
|
33413
|
-
|
|
34161
|
+
|
|
33414
34162
|
i18n-columnChooserSelectedColumnsCount="kendo.grid.columnChooserSelectedColumnsCount|The text displayed in the Column Chooser for the number of selected columns"
|
|
33415
34163
|
columnChooserSelectedColumnsCount="{{ '{selectedColumnsCount} Selected items' }}"
|
|
33416
|
-
|
|
34164
|
+
|
|
33417
34165
|
i18n-multiCheckboxFilterSearchPlaceholder="kendo.grid.multiCheckboxFilterSearchPlaceholder|The placeholder text for the multi-checkbox filter search input"
|
|
33418
34166
|
multiCheckboxFilterSearchPlaceholder="Search..."
|
|
33419
|
-
|
|
34167
|
+
|
|
33420
34168
|
i18n-multiCheckboxFilterSelectAllLabel="kendo.grid.multiCheckboxFilterSelectAllLabel|The label for the multi-checkbox filter select all option"
|
|
33421
34169
|
multiCheckboxFilterSelectAllLabel="Select all"
|
|
33422
|
-
|
|
34170
|
+
|
|
33423
34171
|
i18n-multiCheckboxFilterSelectedItemsCount="kendo.grid.multiCheckboxFilterSelectedItemsCount|The text for the multi-checkbox filter selected items count"
|
|
33424
34172
|
multiCheckboxFilterSelectedItemsCount="{{ '{selectedItemsCount} selected items' }}"
|
|
33425
34173
|
>
|
|
@@ -33832,7 +34580,7 @@ class GridComponent {
|
|
|
33832
34580
|
position="bottom">
|
|
33833
34581
|
</kendo-grid-toolbar>
|
|
33834
34582
|
}
|
|
33835
|
-
|
|
34583
|
+
|
|
33836
34584
|
<ng-template #defaultHint>
|
|
33837
34585
|
<kendo-icon-wrapper
|
|
33838
34586
|
[name]="getHintSettings('hintIcon')"
|
|
@@ -33841,7 +34589,7 @@ class GridComponent {
|
|
|
33841
34589
|
</kendo-icon-wrapper>
|
|
33842
34590
|
{{hintText}}
|
|
33843
34591
|
</ng-template>
|
|
33844
|
-
|
|
34592
|
+
|
|
33845
34593
|
<ng-template #defaultPager>
|
|
33846
34594
|
<div class="k-pager-numbers-wrap">
|
|
33847
34595
|
@if (normalizedPageableSettings.previousNext) {
|
|
@@ -33874,14 +34622,14 @@ class GridComponent {
|
|
|
33874
34622
|
</ng-template>
|
|
33875
34623
|
<div #dialogContainer></div>
|
|
33876
34624
|
<div #windowContainer></div>
|
|
33877
|
-
|
|
34625
|
+
|
|
33878
34626
|
@if (isAdaptiveModeEnabled) {
|
|
33879
34627
|
<kendo-grid-adaptive-renderer></kendo-grid-adaptive-renderer>
|
|
33880
34628
|
}
|
|
33881
34629
|
@if (isVirtual) {
|
|
33882
34630
|
<kendo-resize-sensor (resize)="onResize()"></kendo-resize-sensor>
|
|
33883
34631
|
}
|
|
33884
|
-
|
|
34632
|
+
|
|
33885
34633
|
@if (showLicenseWatermark) {
|
|
33886
34634
|
<div kendoWatermarkOverlay [licenseMessage]="licenseMessage"></div>
|
|
33887
34635
|
}
|
|
@@ -33938,6 +34686,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImpo
|
|
|
33938
34686
|
SizingOptionsService,
|
|
33939
34687
|
RowReorderService,
|
|
33940
34688
|
ClipboardService,
|
|
34689
|
+
GridAIRequestResponseService,
|
|
33941
34690
|
RowspanService,
|
|
33942
34691
|
AdaptiveGridService,
|
|
33943
34692
|
ColumnMenuService,
|
|
@@ -33949,394 +34698,394 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImpo
|
|
|
33949
34698
|
<ng-container kendoGridLocalizedMessages
|
|
33950
34699
|
i18n-groupPanelEmpty="kendo.grid.groupPanelEmpty|The label visible in the Grid group panel when it is empty"
|
|
33951
34700
|
groupPanelEmpty="Drag a column header and drop it here to group by that column"
|
|
33952
|
-
|
|
34701
|
+
|
|
33953
34702
|
i18n-noRecords="kendo.grid.noRecords|The label visible in the Grid when there are no records"
|
|
33954
34703
|
noRecords="No records available."
|
|
33955
|
-
|
|
34704
|
+
|
|
33956
34705
|
i18n-pagerLabel="kendo.grid.pagerLabel|The label for the Grid pager"
|
|
33957
34706
|
pagerLabel="{{ 'Page navigation, page {currentPage} of {totalPages}' }}"
|
|
33958
|
-
|
|
34707
|
+
|
|
33959
34708
|
i18n-pagerFirstPage="kendo.grid.pagerFirstPage|The label for the first page button in Grid pager"
|
|
33960
34709
|
pagerFirstPage="Go to the first page"
|
|
33961
|
-
|
|
34710
|
+
|
|
33962
34711
|
i18n-pagerPreviousPage="kendo.grid.pagerPreviousPage|The label for the previous page button in Grid pager"
|
|
33963
34712
|
pagerPreviousPage="Go to the previous page"
|
|
33964
|
-
|
|
34713
|
+
|
|
33965
34714
|
i18n-pagerNextPage="kendo.grid.pagerNextPage|The label for the next page button in Grid pager"
|
|
33966
34715
|
pagerNextPage="Go to the next page"
|
|
33967
|
-
|
|
34716
|
+
|
|
33968
34717
|
i18n-pagerLastPage="kendo.grid.pagerLastPage|The label for the last page button in Grid pager"
|
|
33969
34718
|
pagerLastPage="Go to the last page"
|
|
33970
|
-
|
|
34719
|
+
|
|
33971
34720
|
i18n-pagerPage="kendo.grid.pagerPage|The label before the current page number in the Grid pager"
|
|
33972
34721
|
pagerPage="Page"
|
|
33973
|
-
|
|
34722
|
+
|
|
33974
34723
|
i18n-pagerOf="kendo.grid.pagerOf|The label before the total pages number in the Grid pager"
|
|
33975
34724
|
pagerOf="of"
|
|
33976
|
-
|
|
34725
|
+
|
|
33977
34726
|
i18n-pagerItems="kendo.grid.pagerItems|The label after the total pages number in the Grid pager"
|
|
33978
34727
|
pagerItems="items"
|
|
33979
|
-
|
|
34728
|
+
|
|
33980
34729
|
i18n-pagerPageNumberInputTitle="kendo.grid.pagerPageNumberInputTitle|The label for the pager input in the Grid pager"
|
|
33981
34730
|
pagerPageNumberInputTitle="Page Number"
|
|
33982
|
-
|
|
34731
|
+
|
|
33983
34732
|
i18n-pagerItemsPerPage="kendo.grid.pagerItemsPerPage|The label for the page size chooser in the Grid pager"
|
|
33984
34733
|
pagerItemsPerPage="items per page"
|
|
33985
|
-
|
|
34734
|
+
|
|
33986
34735
|
i18n-pagerInputLabel="kendo.grid.pagerInputLabel|The text of the aria-label attribute applied to the input element for entering the page number"
|
|
33987
34736
|
pagerInputLabel="Type a page number"
|
|
33988
|
-
|
|
34737
|
+
|
|
33989
34738
|
i18n-filter="kendo.grid.filter|The label of the filter cell or icon"
|
|
33990
34739
|
filter="Filter"
|
|
33991
|
-
|
|
34740
|
+
|
|
33992
34741
|
i18n-filterInputLabel="kendo.grid.filterInputLabel|The label of the filter row and menu inputs"
|
|
33993
34742
|
filterInputLabel="{{ '{columnName} Filter' }}"
|
|
33994
|
-
|
|
34743
|
+
|
|
33995
34744
|
i18n-filterMenuTitle="kendo.grid.filterMenuTitle|The title of the filter menu icon"
|
|
33996
34745
|
filterMenuTitle="{{ '{columnName} Filter Menu' }}"
|
|
33997
|
-
|
|
34746
|
+
|
|
33998
34747
|
i18n-filterMenuOperatorsDropDownLabel="kendo.grid.filterMenuOperatorsDropDownLabel|The label of the filter menu operators dropdown"
|
|
33999
34748
|
filterMenuOperatorsDropDownLabel="{{ '{columnName} Filter Operators' }}"
|
|
34000
|
-
|
|
34749
|
+
|
|
34001
34750
|
i18n-filterCellOperatorLabel="kendo.grid.filterCellOperatorLabel|The label of the filter cell operators dropdown"
|
|
34002
34751
|
filterCellOperatorLabel="{{ 'Filter cell operators for {columnName}' }}"
|
|
34003
|
-
|
|
34752
|
+
|
|
34004
34753
|
i18n-booleanFilterCellLabel="kendo.grid.booleanFilterCellLabel|The label of the boolean filter cell dropdown"
|
|
34005
34754
|
booleanFilterCellLabel="{{ 'Boolean filter cell for {columnName}' }}"
|
|
34006
|
-
|
|
34755
|
+
|
|
34007
34756
|
i18n-filterMenuLogicDropDownLabel="kendo.grid.filterMenuLogicDropDownLabel|The label of the filter menu logic dropdown"
|
|
34008
34757
|
filterMenuLogicDropDownLabel="{{ '{columnName} Filter Logic' }}"
|
|
34009
|
-
|
|
34758
|
+
|
|
34010
34759
|
i18n-filterEqOperator="kendo.grid.filterEqOperator|The text of the equal filter operator"
|
|
34011
34760
|
filterEqOperator="Is equal to"
|
|
34012
|
-
|
|
34761
|
+
|
|
34013
34762
|
i18n-filterNotEqOperator="kendo.grid.filterNotEqOperator|The text of the not equal filter operator"
|
|
34014
34763
|
filterNotEqOperator="Is not equal to"
|
|
34015
|
-
|
|
34764
|
+
|
|
34016
34765
|
i18n-filterIsNullOperator="kendo.grid.filterIsNullOperator|The text of the is null filter operator"
|
|
34017
34766
|
filterIsNullOperator="Is null"
|
|
34018
|
-
|
|
34767
|
+
|
|
34019
34768
|
i18n-filterIsNotNullOperator="kendo.grid.filterIsNotNullOperator|The text of the is not null filter operator"
|
|
34020
34769
|
filterIsNotNullOperator="Is not null"
|
|
34021
|
-
|
|
34770
|
+
|
|
34022
34771
|
i18n-filterIsEmptyOperator="kendo.grid.filterIsEmptyOperator|The text of the is empty filter operator"
|
|
34023
34772
|
filterIsEmptyOperator="Is empty"
|
|
34024
|
-
|
|
34773
|
+
|
|
34025
34774
|
i18n-filterIsNotEmptyOperator="kendo.grid.filterIsNotEmptyOperator|The text of the is not empty filter operator"
|
|
34026
34775
|
filterIsNotEmptyOperator="Is not empty"
|
|
34027
|
-
|
|
34776
|
+
|
|
34028
34777
|
i18n-filterStartsWithOperator="kendo.grid.filterStartsWithOperator|The text of the starts with filter operator"
|
|
34029
34778
|
filterStartsWithOperator="Starts with"
|
|
34030
|
-
|
|
34779
|
+
|
|
34031
34780
|
i18n-filterContainsOperator="kendo.grid.filterContainsOperator|The text of the contains filter operator"
|
|
34032
34781
|
filterContainsOperator="Contains"
|
|
34033
|
-
|
|
34782
|
+
|
|
34034
34783
|
i18n-filterNotContainsOperator="kendo.grid.filterNotContainsOperator|The text of the does not contain filter operator"
|
|
34035
34784
|
filterNotContainsOperator="Does not contain"
|
|
34036
|
-
|
|
34785
|
+
|
|
34037
34786
|
i18n-filterEndsWithOperator="kendo.grid.filterEndsWithOperator|The text of the ends with filter operator"
|
|
34038
34787
|
filterEndsWithOperator="Ends with"
|
|
34039
|
-
|
|
34788
|
+
|
|
34040
34789
|
i18n-filterGteOperator="kendo.grid.filterGteOperator|The text of the greater than or equal filter operator"
|
|
34041
34790
|
filterGteOperator="Is greater than or equal to"
|
|
34042
|
-
|
|
34791
|
+
|
|
34043
34792
|
i18n-filterGtOperator="kendo.grid.filterGtOperator|The text of the greater than filter operator"
|
|
34044
34793
|
filterGtOperator="Is greater than"
|
|
34045
|
-
|
|
34794
|
+
|
|
34046
34795
|
i18n-filterLteOperator="kendo.grid.filterLteOperator|The text of the less than or equal filter operator"
|
|
34047
34796
|
filterLteOperator="Is less than or equal to"
|
|
34048
|
-
|
|
34797
|
+
|
|
34049
34798
|
i18n-filterLtOperator="kendo.grid.filterLtOperator|The text of the less than filter operator"
|
|
34050
34799
|
filterLtOperator="Is less than"
|
|
34051
|
-
|
|
34800
|
+
|
|
34052
34801
|
i18n-filterIsTrue="kendo.grid.filterIsTrue|The text of the IsTrue boolean filter option"
|
|
34053
34802
|
filterIsTrue="Is True"
|
|
34054
|
-
|
|
34803
|
+
|
|
34055
34804
|
i18n-filterIsFalse="kendo.grid.filterIsFalse|The text of the IsFalse boolean filter option"
|
|
34056
34805
|
filterIsFalse="Is False"
|
|
34057
|
-
|
|
34806
|
+
|
|
34058
34807
|
i18n-filterBooleanAll="kendo.grid.filterBooleanAll|The text of the (All) boolean filter option"
|
|
34059
34808
|
filterBooleanAll="(All)"
|
|
34060
|
-
|
|
34809
|
+
|
|
34061
34810
|
i18n-filterAfterOrEqualOperator="kendo.grid.filterAfterOrEqualOperator|The text of the after or equal date filter operator"
|
|
34062
34811
|
filterAfterOrEqualOperator="Is after or equal to"
|
|
34063
|
-
|
|
34812
|
+
|
|
34064
34813
|
i18n-filterAfterOperator="kendo.grid.filterAfterOperator|The text of the after date filter operator"
|
|
34065
34814
|
filterAfterOperator="Is after"
|
|
34066
|
-
|
|
34815
|
+
|
|
34067
34816
|
i18n-filterBeforeOperator="kendo.grid.filterBeforeOperator|The text of the before date filter operator"
|
|
34068
34817
|
filterBeforeOperator="Is before"
|
|
34069
|
-
|
|
34818
|
+
|
|
34070
34819
|
i18n-filterBeforeOrEqualOperator="kendo.grid.filterBeforeOrEqualOperator|The text of the before or equal date filter operator"
|
|
34071
34820
|
filterBeforeOrEqualOperator="Is before or equal to"
|
|
34072
|
-
|
|
34821
|
+
|
|
34073
34822
|
i18n-filterFilterButton="kendo.grid.filterFilterButton|The text of the filter button"
|
|
34074
34823
|
filterFilterButton="Filter"
|
|
34075
|
-
|
|
34824
|
+
|
|
34076
34825
|
i18n-filterClearButton="kendo.grid.filterClearButton|The text of the clear filter button"
|
|
34077
34826
|
filterClearButton="Clear"
|
|
34078
|
-
|
|
34827
|
+
|
|
34079
34828
|
i18n-sortClearButton="kendo.grid.sortClearButton|The text of the clear sort button located in the Sort Toolbar Tool and adaptive Sort Toolbar Tool"
|
|
34080
34829
|
sortClearButton="Clear sorting"
|
|
34081
|
-
|
|
34830
|
+
|
|
34082
34831
|
i18n-adaptiveCloseButtonTitle="kendo.grid.adaptiveCloseButtonTitle|The title of the Close button of the ActionSheet that is rendered instead of the Popup when using small screen devices in adaptive mode"
|
|
34083
34832
|
adaptiveCloseButtonTitle="Close"
|
|
34084
|
-
|
|
34833
|
+
|
|
34085
34834
|
i18n-adaptiveBackButtonTitle="kendo.grid.adaptiveBackButtonTitle|The title of the Back button of the ActionSheet that is rendered instead of the Popup when using small screen devices in adaptive mode"
|
|
34086
34835
|
adaptiveBackButtonTitle="Back"
|
|
34087
|
-
|
|
34836
|
+
|
|
34088
34837
|
i18n-filterClearAllButton="kendo.grid.filterClearAllButton|The text of the clear all filters button located in the Filter Toolbar Tool and adaptive Filter Toolbar Tool"
|
|
34089
34838
|
filterClearAllButton="Clear all filters"
|
|
34090
|
-
|
|
34839
|
+
|
|
34091
34840
|
i18n-groupClearButton="kendo.grid.groupClearButton|The text of the clear grouping button in the Group Toolbar Tool and adaptive Group Toolbar Tool"
|
|
34092
34841
|
groupClearButton="Clear grouping"
|
|
34093
|
-
|
|
34842
|
+
|
|
34094
34843
|
i18n-sortDoneButton="kendo.grid.sortDoneButton|The text of the done sort button"
|
|
34095
34844
|
sortDoneButton="Done"
|
|
34096
|
-
|
|
34845
|
+
|
|
34097
34846
|
i18n-groupDoneButton="kendo.grid.groupDoneButton|The text of the done group button in the adaptive Group Toolbar Tool"
|
|
34098
34847
|
groupDoneButton="Done"
|
|
34099
|
-
|
|
34848
|
+
|
|
34100
34849
|
i18n-filterAndLogic="kendo.grid.filterAndLogic|The text of the And filter logic"
|
|
34101
34850
|
filterAndLogic="And"
|
|
34102
|
-
|
|
34851
|
+
|
|
34103
34852
|
i18n-filterOrLogic="kendo.grid.filterOrLogic|The text of the Or filter logic"
|
|
34104
34853
|
filterOrLogic="Or"
|
|
34105
|
-
|
|
34854
|
+
|
|
34106
34855
|
i18n-filterToolbarToolText="kendo.grid.filterToolbarToolText|The button text of the Filter toolbar tool"
|
|
34107
34856
|
filterToolbarToolText="Filter"
|
|
34108
|
-
|
|
34857
|
+
|
|
34109
34858
|
i18n-loading="kendo.grid.loading|The loading text"
|
|
34110
34859
|
loading="Loading"
|
|
34111
|
-
|
|
34860
|
+
|
|
34112
34861
|
i18n-gridLabel="kendo.grid.gridLabel|The Grid aria-label"
|
|
34113
34862
|
gridLabel="Data table"
|
|
34114
|
-
|
|
34863
|
+
|
|
34115
34864
|
i18n-columnMenu="kendo.grid.columnMenu|The title of the column menu icon"
|
|
34116
34865
|
columnMenu="{{ '{columnName} Column Menu' }}"
|
|
34117
|
-
|
|
34866
|
+
|
|
34118
34867
|
i18n-columns="kendo.grid.columns|The text for the Grid Column Chooser and Column Chooser toolbar tool"
|
|
34119
34868
|
columns="Columns"
|
|
34120
|
-
|
|
34869
|
+
|
|
34121
34870
|
i18n-columnsSubtitle="kendo.grid.columnsSubtitle|The subtitle for the adaptive Grid Column Chooser and Column Chooser toolbar tool"
|
|
34122
34871
|
columnsSubtitle="Selected fields are visible"
|
|
34123
|
-
|
|
34872
|
+
|
|
34124
34873
|
i18n-adaptiveFilterTitle="kendo.grid.adaptiveFilterTitle|The title that is displayed in the adaptive Filter Toolbar Tool and Filter Menu"
|
|
34125
34874
|
adaptiveFilterTitle="Filter by"
|
|
34126
|
-
|
|
34875
|
+
|
|
34127
34876
|
i18n-adaptiveFilterOperatorsTitle="kendo.grid.adaptiveFilterOperatorsTitle|The title that is displayed in the Operators Action Sheet"
|
|
34128
34877
|
adaptiveFilterOperatorsTitle="Operators"
|
|
34129
|
-
|
|
34878
|
+
|
|
34130
34879
|
i18n-adaptiveSortTitle="kendo.grid.adaptiveSortTitle|The title that is displayed in the adaptive Sort Toolbar Tool"
|
|
34131
34880
|
adaptiveSortTitle="Sort by"
|
|
34132
|
-
|
|
34881
|
+
|
|
34133
34882
|
i18n-adaptiveGroupTitle="kendo.grid.adaptiveGroupTitle|The title that is displayed in the adaptive Group Toolbar Tool."
|
|
34134
34883
|
adaptiveGroupTitle="Group by"
|
|
34135
|
-
|
|
34884
|
+
|
|
34136
34885
|
i18n-lock="kendo.grid.lock|The text shown in the column menu for the lock item"
|
|
34137
34886
|
lock="Lock"
|
|
34138
|
-
|
|
34887
|
+
|
|
34139
34888
|
i18n-unlock="kendo.grid.unlock|The text shown in the column menu for the unlock item"
|
|
34140
34889
|
unlock="Unlock"
|
|
34141
|
-
|
|
34890
|
+
|
|
34142
34891
|
i18n-setColumnPosition="kendo.grid.setColumnPosition|The text shown in the column menu for the set column position item"
|
|
34143
34892
|
setColumnPosition="Set Column Position"
|
|
34144
|
-
|
|
34893
|
+
|
|
34145
34894
|
i18n-stick="kendo.grid.stick|The text shown in the column menu for the stick item"
|
|
34146
34895
|
stick="Stick"
|
|
34147
|
-
|
|
34896
|
+
|
|
34148
34897
|
i18n-unstick="kendo.grid.unstick|The text shown in the column menu for the unstick item"
|
|
34149
34898
|
unstick="Unstick"
|
|
34150
|
-
|
|
34899
|
+
|
|
34151
34900
|
i18n-sortable="kendo.grid.sortable|The label of the sort icon"
|
|
34152
34901
|
sortable="Sortable"
|
|
34153
|
-
|
|
34902
|
+
|
|
34154
34903
|
i18n-sortAscending="kendo.grid.sortAscending|The text shown in the column menu for the sort ascending item"
|
|
34155
34904
|
sortAscending="Sort Ascending"
|
|
34156
|
-
|
|
34905
|
+
|
|
34157
34906
|
i18n-sortDescending="kendo.grid.sortDescending|The text shown in the column menu for the sort descending item"
|
|
34158
34907
|
sortDescending="Sort Descending"
|
|
34159
|
-
|
|
34908
|
+
|
|
34160
34909
|
i18n-autosizeAllColumns="kendo.grid.autosizeAllColumns|The text shown in the column menu for the autosize all columns item"
|
|
34161
34910
|
autosizeAllColumns="Autosize All Columns"
|
|
34162
|
-
|
|
34911
|
+
|
|
34163
34912
|
i18n-autosizeThisColumn="kendo.grid.autosizeThisColumn|The text shown in the column menu for the autosize this column item"
|
|
34164
34913
|
autosizeThisColumn="Autosize This Column"
|
|
34165
|
-
|
|
34914
|
+
|
|
34166
34915
|
i18n-sortedDefault="kendo.grid.sortedDefault|The status announcement when a column is no longer sorted"
|
|
34167
34916
|
sortedDefault="Not Sorted"
|
|
34168
|
-
|
|
34917
|
+
|
|
34169
34918
|
i18n-sortedAscending="kendo.grid.sortedAscending|The title of the Group Chip indicating the ascending sorting order of the groups"
|
|
34170
34919
|
sortedAscending="Sorted Ascending"
|
|
34171
|
-
|
|
34920
|
+
|
|
34172
34921
|
i18n-sortedDescending="kendo.grid.sortedDescending|The title of the Group Chip indicating the descending sorting order of the groups"
|
|
34173
34922
|
sortedDescending="Sorted Descending"
|
|
34174
|
-
|
|
34923
|
+
|
|
34175
34924
|
i18n-columnsApply="kendo.grid.columnsApply|The text shown in the column menu or column chooser for the columns apply button"
|
|
34176
34925
|
columnsApply="Apply"
|
|
34177
|
-
|
|
34926
|
+
|
|
34178
34927
|
i18n-columnsReset="kendo.grid.columnsReset|The text shown in the column menu or column chooser for the columns reset button"
|
|
34179
34928
|
columnsReset="Reset"
|
|
34180
|
-
|
|
34929
|
+
|
|
34181
34930
|
i18n-detailExpand="kendo.grid.detailExpand|The title of the expand icon of detail rows. Applies also to the expand button text in stacked mode."
|
|
34182
34931
|
detailExpand="Expand Details"
|
|
34183
|
-
|
|
34932
|
+
|
|
34184
34933
|
i18n-detailCollapse="kendo.grid.detailCollapse|The title of the collapse icon of detail rows. Applies also to the collapse button text in stacked mode."
|
|
34185
34934
|
detailCollapse="Collapse Details"
|
|
34186
|
-
|
|
34935
|
+
|
|
34187
34936
|
i18n-filterDateToday="kendo.grid.filterDateToday|The text of the Today button of the Date filter."
|
|
34188
34937
|
filterDateToday="TODAY"
|
|
34189
|
-
|
|
34938
|
+
|
|
34190
34939
|
i18n-filterDateToggle="kendo.grid.filterDateToggle|The title of the Toggle button of the Date filter."
|
|
34191
34940
|
filterDateToggle="Toggle Calendar"
|
|
34192
|
-
|
|
34941
|
+
|
|
34193
34942
|
i18n-filterNumericDecrement="kendo.grid.filterNumericDecrement|The title of the Decrement button of the Numeric filter."
|
|
34194
34943
|
filterNumericDecrement="Decrement"
|
|
34195
|
-
|
|
34944
|
+
|
|
34196
34945
|
i18n-filterNumericIncrement="kendo.grid.filterNumericIncrement|The title of the Increment button of the Numeric filter."
|
|
34197
34946
|
filterNumericIncrement="Increment"
|
|
34198
|
-
|
|
34947
|
+
|
|
34199
34948
|
i18n-selectionCheckboxLabel="kendo.grid.selectionCheckboxLabel|The labels of the checkbox column checkboxes."
|
|
34200
34949
|
selectionCheckboxLabel="Select Row"
|
|
34201
|
-
|
|
34950
|
+
|
|
34202
34951
|
i18n-selectAllCheckboxLabel="kendo.grid.selectAllCheckboxLabel|The label of the checkbox column select all checkbox."
|
|
34203
34952
|
selectAllCheckboxLabel="Select All Rows"
|
|
34204
|
-
|
|
34953
|
+
|
|
34205
34954
|
i18n-sortToolbarToolText="kendo.grid.sortToolbarToolText|The button text of the Sort toolbar tool."
|
|
34206
34955
|
sortToolbarToolText="Sort"
|
|
34207
|
-
|
|
34956
|
+
|
|
34208
34957
|
i18n-groupCollapse="kendo.grid.groupCollapse|The text of the title and aria-label attributes applied to the collapse icon of group rows."
|
|
34209
34958
|
groupCollapse="Collapse Group"
|
|
34210
|
-
|
|
34959
|
+
|
|
34211
34960
|
i18n-groupExpand="kendo.grid.groupExpand|The text of the title and aria-label attributes applied to the expand icon of group rows."
|
|
34212
34961
|
groupExpand="Expand Group"
|
|
34213
|
-
|
|
34962
|
+
|
|
34214
34963
|
i18n-pagerSelectPage="kendo.grid.pagerSelectPage|The text of the title and aria-label attributes applied to the page chooser in the Grid Pager"
|
|
34215
34964
|
pagerSelectPage="Select page"
|
|
34216
|
-
|
|
34965
|
+
|
|
34217
34966
|
i18n-topToolbarLabel="kendo.grid.topToolbarLabel|The label for the Grid top toolbar"
|
|
34218
34967
|
topToolbarLabel="Top toolbar"
|
|
34219
|
-
|
|
34968
|
+
|
|
34220
34969
|
i18n-bottomToolbarLabel="kendo.grid.bottomToolbarLabel|The label for the Grid bottom toolbar"
|
|
34221
34970
|
bottomToolbarLabel="Bottom toolbar"
|
|
34222
|
-
|
|
34971
|
+
|
|
34223
34972
|
i18n-editToolbarToolText="kendo.grid.editToolbarToolText|The text for the Grid Edit toolbar tool"
|
|
34224
34973
|
editToolbarToolText="Edit"
|
|
34225
|
-
|
|
34974
|
+
|
|
34226
34975
|
i18n-saveToolbarToolText="kendo.grid.saveToolbarToolText|The text for the Grid Save toolbar tool"
|
|
34227
34976
|
saveToolbarToolText="Save"
|
|
34228
|
-
|
|
34977
|
+
|
|
34229
34978
|
i18n-addToolbarToolText="kendo.grid.addToolbarToolText|The text for the Grid Add toolbar tool"
|
|
34230
34979
|
addToolbarToolText="Add"
|
|
34231
|
-
|
|
34980
|
+
|
|
34232
34981
|
i18n-cancelToolbarToolText="kendo.grid.cancelToolbarToolText|The text for the Grid Cancel toolbar tool"
|
|
34233
34982
|
cancelToolbarToolText="Cancel"
|
|
34234
|
-
|
|
34983
|
+
|
|
34235
34984
|
i18n-removeToolbarToolText="kendo.grid.removeToolbarToolText|The text for the Grid Remove toolbar tool"
|
|
34236
34985
|
removeToolbarToolText="Delete"
|
|
34237
|
-
|
|
34986
|
+
|
|
34238
34987
|
i18n-excelExportToolbarToolText="kendo.grid.excelExportToolbarToolText|The text for the Grid Excel export toolbar tool"
|
|
34239
34988
|
excelExportToolbarToolText="Excel Export"
|
|
34240
|
-
|
|
34989
|
+
|
|
34241
34990
|
i18n-pdfExportToolbarToolText="kendo.grid.pdfExportToolbarToolText|The text for the Grid PDF export toolbar tool"
|
|
34242
34991
|
pdfExportToolbarToolText="PDF Export"
|
|
34243
|
-
|
|
34992
|
+
|
|
34244
34993
|
i18n-groupPanelLabel="kendo.grid.groupPanelLabel|The label for the Grid group panel toolbar"
|
|
34245
34994
|
groupPanelLabel="Group panel"
|
|
34246
|
-
|
|
34995
|
+
|
|
34247
34996
|
i18n-dragRowHandleLabel="kendo.grid.dragRowHandleLabel|The label for the Grid drag row handle"
|
|
34248
34997
|
dragRowHandleLabel="Drag row"
|
|
34249
|
-
|
|
34998
|
+
|
|
34250
34999
|
i18n-columnMenuFilterTabTitle="kendo.grid.columnMenuFilterTabTitle|The title for the column menu Filter tab"
|
|
34251
35000
|
columnMenuFilterTabTitle="Filter"
|
|
34252
|
-
|
|
35001
|
+
|
|
34253
35002
|
i18n-columnMenuGeneralTabTitle="kendo.grid.columnMenuGeneralTabTitle|The title for the column menu General tab"
|
|
34254
35003
|
columnMenuGeneralTabTitle="General"
|
|
34255
|
-
|
|
35004
|
+
|
|
34256
35005
|
i18n-columnMenuColumnsTabTitle="kendo.grid.columnMenuColumnsTabTitle|The title for the column menu Columns tab"
|
|
34257
35006
|
columnMenuColumnsTabTitle="Columns"
|
|
34258
|
-
|
|
35007
|
+
|
|
34259
35008
|
i18n-groupChipMenuPrevious="kendo.grid.groupChipMenuPrevious|The text for the Group pane Chip Menu Move as previous item"
|
|
34260
35009
|
groupChipMenuPrevious="Move as previous"
|
|
34261
|
-
|
|
35010
|
+
|
|
34262
35011
|
i18n-groupChipMenuNext="kendo.grid.groupChipMenuNext|The text for the Group pane Chip Menu Move as next item"
|
|
34263
35012
|
groupChipMenuNext="Move as next"
|
|
34264
|
-
|
|
35013
|
+
|
|
34265
35014
|
i18n-groupToolbarToolText="kendo.grid.groupToolbarToolText|The button text of the Group toolbar tool"
|
|
34266
35015
|
groupToolbarToolText="Group"
|
|
34267
|
-
|
|
35016
|
+
|
|
34268
35017
|
i18n-formValidationErrorText="kendo.grid.formValidationErrorText|The default text of a form validation error when using external editing."
|
|
34269
35018
|
formValidationErrorText="{{ 'The {fieldName} field has {errorName} validation error' }}"
|
|
34270
|
-
|
|
35019
|
+
|
|
34271
35020
|
i18n-removeConfirmationDialogTitle="kendo.grid.removeConfirmationDialogTitle|The title of the built-in remove item confirmation Dialog"
|
|
34272
35021
|
removeConfirmationDialogTitle="Please confirm"
|
|
34273
|
-
|
|
35022
|
+
|
|
34274
35023
|
i18n-removeConfirmationDialogContent="kendo.grid.removeConfirmationDialogContent|The content of the built-in remove item confirmation Dialog"
|
|
34275
35024
|
removeConfirmationDialogContent="Are you sure you want to delete this item?"
|
|
34276
|
-
|
|
35025
|
+
|
|
34277
35026
|
i18n-removeConfirmationDialogConfirmText="kendo.grid.removeConfirmationDialogConfirmText|The text of the built-in remove item confirmation Dialog confirm action button"
|
|
34278
35027
|
removeConfirmationDialogConfirmText="Yes"
|
|
34279
|
-
|
|
35028
|
+
|
|
34280
35029
|
i18n-removeConfirmationDialogRejectText="kendo.grid.removeConfirmationDialogRejectText|The text of the built-in remove item confirmation Dialog reject action button"
|
|
34281
35030
|
removeConfirmationDialogRejectText="No"
|
|
34282
|
-
|
|
35031
|
+
|
|
34283
35032
|
i18n-externalEditingTitle="kendo.grid.externalEditingTitle|The title of the built-in external editing form container when editing an item"
|
|
34284
35033
|
externalEditingTitle="Edit"
|
|
34285
|
-
|
|
35034
|
+
|
|
34286
35035
|
i18n-externalEditingAddTitle="kendo.grid.externalEditingAddTitle|The title of the built-in external editing form container when adding a new item"
|
|
34287
35036
|
externalEditingAddTitle="Add"
|
|
34288
|
-
|
|
35037
|
+
|
|
34289
35038
|
i18n-externalEditingSaveText="kendo.grid.externalEditingSaveText|The text of the external editing form Save button"
|
|
34290
35039
|
externalEditingSaveText="Save"
|
|
34291
|
-
|
|
35040
|
+
|
|
34292
35041
|
i18n-externalEditingCancelText="kendo.grid.externalEditingCancelText|The text of the external editing form Cancel button"
|
|
34293
35042
|
externalEditingCancelText="Cancel"
|
|
34294
|
-
|
|
35043
|
+
|
|
34295
35044
|
i18n-aiAssistantToolbarToolText="kendo.grid.aiAssistantToolbarToolText|The text of the AI Assistant toolbar tool"
|
|
34296
35045
|
aiAssistantToolbarToolText="AI Assistant"
|
|
34297
|
-
|
|
35046
|
+
|
|
34298
35047
|
i18n-aiAssistantWindowTitle="kendo.grid.aiAssistantWindowTitle|The text of the AI Assistant Window title"
|
|
34299
35048
|
aiAssistantWindowTitle="AI Assistant"
|
|
34300
|
-
|
|
35049
|
+
|
|
34301
35050
|
i18n-aiAssistantApplyButtonText="kendo.grid.aiAssistantApplyButtonText|The text of the AI Assistant Apply button"
|
|
34302
35051
|
aiAssistantApplyButtonText="Apply"
|
|
34303
|
-
|
|
35052
|
+
|
|
34304
35053
|
i18n-aiAssistantWindowCloseTitle="kendo.grid.aiAssistantWindowCloseTitle|The title of the AI Assistant Window close button"
|
|
34305
35054
|
aiAssistantWindowCloseTitle="Close"
|
|
34306
|
-
|
|
35055
|
+
|
|
34307
35056
|
i18n-aiAssistantWindowMaximizeTitle="kendo.grid.aiAssistantWindowMaximizeTitle|The title of the AI Assistant Window maximize button"
|
|
34308
35057
|
aiAssistantWindowMaximizeTitle="Maximize"
|
|
34309
|
-
|
|
35058
|
+
|
|
34310
35059
|
i18n-aiAssistantWindowMinimizeTitle="kendo.grid.aiAssistantWindowMinimizeTitle|The title of the AI Assistant Window minimize button"
|
|
34311
35060
|
aiAssistantWindowMinimizeTitle="Minimize"
|
|
34312
|
-
|
|
35061
|
+
|
|
34313
35062
|
i18n-aiAssistantWindowRestoreTitle="kendo.grid.aiAssistantWindowRestoreTitle|The title of the AI Assistant Window restore button"
|
|
34314
35063
|
aiAssistantWindowRestoreTitle="Restore"
|
|
34315
|
-
|
|
35064
|
+
|
|
34316
35065
|
i18n-aiAssistantOutputCardTitle="kendo.grid.aiAssistantOutputCardTitle|The title of the AI Assistant Prompt Output Card"
|
|
34317
35066
|
aiAssistantOutputCardTitle="Generated with AI"
|
|
34318
|
-
|
|
35067
|
+
|
|
34319
35068
|
i18n-aiAssistantOutputCardBodyContent="kendo.grid.aiAssistantOutputCardBodyContent|The success message dispayed in the AI Assistant Prompt Output Card's body"
|
|
34320
35069
|
aiAssistantOutputCardBodyContent="Operation is successful. Data is:"
|
|
34321
|
-
|
|
35070
|
+
|
|
34322
35071
|
i18n-aiAssistantSelectionNotEnabled="kendo.grid.aiAssistantSelectionNotEnabled|The message shown when AI selection requires the Grid selectable option"
|
|
34323
35072
|
aiAssistantSelectionNotEnabled="Selection can be applied only when the Grid selectable option is enabled."
|
|
34324
|
-
|
|
35073
|
+
|
|
34325
35074
|
i18n-aiAssistantSelectionRowModeRequired="kendo.grid.aiAssistantSelectionRowModeRequired|The message shown when AI selection requires row selection mode"
|
|
34326
35075
|
aiAssistantSelectionRowModeRequired="Selection can be applied only when row selection mode is enabled."
|
|
34327
|
-
|
|
35076
|
+
|
|
34328
35077
|
i18n-aiAssistantSelectionCellModeRequired="kendo.grid.aiAssistantSelectionCellModeRequired|The message shown when AI selection requires cell selection mode"
|
|
34329
35078
|
aiAssistantSelectionCellModeRequired="Selection can be applied only when cell selection mode is enabled."
|
|
34330
|
-
|
|
35079
|
+
|
|
34331
35080
|
i18n-columnChooserSelectedColumnsCount="kendo.grid.columnChooserSelectedColumnsCount|The text displayed in the Column Chooser for the number of selected columns"
|
|
34332
35081
|
columnChooserSelectedColumnsCount="{{ '{selectedColumnsCount} Selected items' }}"
|
|
34333
|
-
|
|
35082
|
+
|
|
34334
35083
|
i18n-multiCheckboxFilterSearchPlaceholder="kendo.grid.multiCheckboxFilterSearchPlaceholder|The placeholder text for the multi-checkbox filter search input"
|
|
34335
35084
|
multiCheckboxFilterSearchPlaceholder="Search..."
|
|
34336
|
-
|
|
35085
|
+
|
|
34337
35086
|
i18n-multiCheckboxFilterSelectAllLabel="kendo.grid.multiCheckboxFilterSelectAllLabel|The label for the multi-checkbox filter select all option"
|
|
34338
35087
|
multiCheckboxFilterSelectAllLabel="Select all"
|
|
34339
|
-
|
|
35088
|
+
|
|
34340
35089
|
i18n-multiCheckboxFilterSelectedItemsCount="kendo.grid.multiCheckboxFilterSelectedItemsCount|The text for the multi-checkbox filter selected items count"
|
|
34341
35090
|
multiCheckboxFilterSelectedItemsCount="{{ '{selectedItemsCount} selected items' }}"
|
|
34342
35091
|
>
|
|
@@ -34749,7 +35498,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImpo
|
|
|
34749
35498
|
position="bottom">
|
|
34750
35499
|
</kendo-grid-toolbar>
|
|
34751
35500
|
}
|
|
34752
|
-
|
|
35501
|
+
|
|
34753
35502
|
<ng-template #defaultHint>
|
|
34754
35503
|
<kendo-icon-wrapper
|
|
34755
35504
|
[name]="getHintSettings('hintIcon')"
|
|
@@ -34758,7 +35507,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImpo
|
|
|
34758
35507
|
</kendo-icon-wrapper>
|
|
34759
35508
|
{{hintText}}
|
|
34760
35509
|
</ng-template>
|
|
34761
|
-
|
|
35510
|
+
|
|
34762
35511
|
<ng-template #defaultPager>
|
|
34763
35512
|
<div class="k-pager-numbers-wrap">
|
|
34764
35513
|
@if (normalizedPageableSettings.previousNext) {
|
|
@@ -34791,14 +35540,14 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImpo
|
|
|
34791
35540
|
</ng-template>
|
|
34792
35541
|
<div #dialogContainer></div>
|
|
34793
35542
|
<div #windowContainer></div>
|
|
34794
|
-
|
|
35543
|
+
|
|
34795
35544
|
@if (isAdaptiveModeEnabled) {
|
|
34796
35545
|
<kendo-grid-adaptive-renderer></kendo-grid-adaptive-renderer>
|
|
34797
35546
|
}
|
|
34798
35547
|
@if (isVirtual) {
|
|
34799
35548
|
<kendo-resize-sensor (resize)="onResize()"></kendo-resize-sensor>
|
|
34800
35549
|
}
|
|
34801
|
-
|
|
35550
|
+
|
|
34802
35551
|
@if (showLicenseWatermark) {
|
|
34803
35552
|
<div kendoWatermarkOverlay [licenseMessage]="licenseMessage"></div>
|
|
34804
35553
|
}
|
|
@@ -34830,7 +35579,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImpo
|
|
|
34830
35579
|
ResizeSensorComponent
|
|
34831
35580
|
]
|
|
34832
35581
|
}]
|
|
34833
|
-
}], ctorParameters: () => [{ type: BrowserSupportService }, { type: SelectionService }, { type: CellSelectionService }, { type: i0.ElementRef }, { type: GroupInfoService }, { type: GroupsService }, { type: ChangeNotificationService }, { type: DetailsService }, { type: EditService }, { type: FilterService }, { type: PDFService }, { type: ResponsiveService }, { type: i0.Renderer2 }, { type: ExcelService }, { type: i0.NgZone }, { type: ScrollSyncService }, { type: DomEventsService }, { type: ColumnResizingService }, { type: i0.ChangeDetectorRef }, { type: ColumnReorderService }, { type: ColumnInfoService }, { type: NavigationService }, { type: SortService }, { type: ScrollRequestService }, { type: i1$2.LocalizationService }, { type: ContextService }, { type: SizingOptionsService }, { type: AdaptiveGridService }, { type: RowReorderService }, { type: DataMappingService }], propDecorators: { data: [{
|
|
35582
|
+
}], ctorParameters: () => [{ type: BrowserSupportService }, { type: SelectionService }, { type: CellSelectionService }, { type: i0.ElementRef }, { type: GroupInfoService }, { type: GroupsService }, { type: ChangeNotificationService }, { type: DetailsService }, { type: EditService }, { type: FilterService }, { type: PDFService }, { type: ResponsiveService }, { type: i0.Renderer2 }, { type: ExcelService }, { type: i0.NgZone }, { type: ScrollSyncService }, { type: DomEventsService }, { type: ColumnResizingService }, { type: i0.ChangeDetectorRef }, { type: ColumnReorderService }, { type: ColumnInfoService }, { type: NavigationService }, { type: SortService }, { type: ScrollRequestService }, { type: i1$2.LocalizationService }, { type: ContextService }, { type: SizingOptionsService }, { type: AdaptiveGridService }, { type: RowReorderService }, { type: DataMappingService }, { type: GridAIRequestResponseService }, { type: IdService }], propDecorators: { data: [{
|
|
34834
35583
|
type: Input
|
|
34835
35584
|
}], pageSize: [{
|
|
34836
35585
|
type: Input
|
|
@@ -38463,93 +39212,6 @@ class GridAIAssistantResponseErrorEvent extends PreventableEvent$1 {
|
|
|
38463
39212
|
}
|
|
38464
39213
|
}
|
|
38465
39214
|
|
|
38466
|
-
/**
|
|
38467
|
-
* @hidden
|
|
38468
|
-
* Converts date strings in a filter to Date objects.
|
|
38469
|
-
*/
|
|
38470
|
-
const convertDateStringsInFilter = (filter) => {
|
|
38471
|
-
if (!filter) {
|
|
38472
|
-
return filter;
|
|
38473
|
-
}
|
|
38474
|
-
if (filter.filters && Array.isArray(filter.filters)) {
|
|
38475
|
-
return {
|
|
38476
|
-
...filter,
|
|
38477
|
-
filters: filter.filters.map(f => convertDateStringsInFilter(f))
|
|
38478
|
-
};
|
|
38479
|
-
}
|
|
38480
|
-
if (filter.field && filter.value !== undefined) {
|
|
38481
|
-
if (typeof filter.value === 'string' && isDateOperator(filter.operator)) {
|
|
38482
|
-
const date = parseDate(filter.value);
|
|
38483
|
-
return {
|
|
38484
|
-
...filter,
|
|
38485
|
-
value: date || filter.value
|
|
38486
|
-
};
|
|
38487
|
-
}
|
|
38488
|
-
}
|
|
38489
|
-
return filter;
|
|
38490
|
-
};
|
|
38491
|
-
/**
|
|
38492
|
-
* @hidden
|
|
38493
|
-
*/
|
|
38494
|
-
const isDateOperator = (operator) => {
|
|
38495
|
-
const dateOperators = [
|
|
38496
|
-
'eq', 'neq', 'lt', 'lte', 'gt', 'gte'
|
|
38497
|
-
];
|
|
38498
|
-
return dateOperators.includes(operator);
|
|
38499
|
-
};
|
|
38500
|
-
/**
|
|
38501
|
-
* @hidden
|
|
38502
|
-
* Processes cell highlights for a specific filter and item.
|
|
38503
|
-
*/
|
|
38504
|
-
const processCellHighlights = (filter, rowIndex, columns, highlightItems) => {
|
|
38505
|
-
Object.keys(filter.cells).forEach((columnField) => {
|
|
38506
|
-
const actualColumnIndex = Array.from(columns).findIndex((col) => col.field === columnField);
|
|
38507
|
-
if (actualColumnIndex !== -1) {
|
|
38508
|
-
highlightItems.push({
|
|
38509
|
-
itemKey: rowIndex,
|
|
38510
|
-
columnKey: actualColumnIndex,
|
|
38511
|
-
});
|
|
38512
|
-
}
|
|
38513
|
-
});
|
|
38514
|
-
};
|
|
38515
|
-
/**
|
|
38516
|
-
* @hidden
|
|
38517
|
-
* Processes filtered results and adds highlight items.
|
|
38518
|
-
*/
|
|
38519
|
-
const processFilteredResults = (filteredResults, data, filter, columns, highlightItems) => {
|
|
38520
|
-
filteredResults?.forEach((item) => {
|
|
38521
|
-
const rowIndex = data.findIndex((dataItem) => dataItem === item);
|
|
38522
|
-
if (filter.cells && Object.keys(filter.cells).length > 0) {
|
|
38523
|
-
processCellHighlights(filter, rowIndex, columns, highlightItems);
|
|
38524
|
-
}
|
|
38525
|
-
else {
|
|
38526
|
-
highlightItems.push({
|
|
38527
|
-
itemKey: rowIndex,
|
|
38528
|
-
});
|
|
38529
|
-
}
|
|
38530
|
-
});
|
|
38531
|
-
};
|
|
38532
|
-
/**
|
|
38533
|
-
* @hidden
|
|
38534
|
-
* Highlights items in a grid based on the provided filters and columns.
|
|
38535
|
-
* @param data - The data to be highlighted.
|
|
38536
|
-
* @param filters - The composite highlight descriptors containing the filters and logic.
|
|
38537
|
-
* @param columns - The columns of the grid.
|
|
38538
|
-
* @returns An array of HighlightItem objects representing the highlighted items.
|
|
38539
|
-
*/
|
|
38540
|
-
const highlightBy = (data, filters, columns) => {
|
|
38541
|
-
const highlightItems = [];
|
|
38542
|
-
filters.forEach((filter) => {
|
|
38543
|
-
const processedFilters = filter.filters.map((filter) => convertDateStringsInFilter(filter));
|
|
38544
|
-
const filteredResults = filterBy(data, {
|
|
38545
|
-
logic: filter.logic || "and",
|
|
38546
|
-
filters: processedFilters,
|
|
38547
|
-
});
|
|
38548
|
-
processFilteredResults(filteredResults, data, filter, columns, highlightItems);
|
|
38549
|
-
});
|
|
38550
|
-
return highlightItems;
|
|
38551
|
-
};
|
|
38552
|
-
|
|
38553
39215
|
/**
|
|
38554
39216
|
* @hidden
|
|
38555
39217
|
*/
|
|
@@ -38558,6 +39220,7 @@ class AiAssistantComponent {
|
|
|
38558
39220
|
ctx;
|
|
38559
39221
|
columnInfoService;
|
|
38560
39222
|
zone;
|
|
39223
|
+
aiRequestResponseService;
|
|
38561
39224
|
aiPrompt;
|
|
38562
39225
|
activeView = 0;
|
|
38563
39226
|
requestUrl;
|
|
@@ -38574,42 +39237,15 @@ class AiAssistantComponent {
|
|
|
38574
39237
|
// flat columns used for highlight utilities (expects { field })
|
|
38575
39238
|
columns = [];
|
|
38576
39239
|
leafColumns = [];
|
|
38577
|
-
// nested tree representing the actual Grid column components sent to the AI service
|
|
38578
|
-
columnsTree = [];
|
|
38579
39240
|
idCounter = 0;
|
|
38580
|
-
constructor(http, ctx, columnInfoService, zone) {
|
|
39241
|
+
constructor(http, ctx, columnInfoService, zone, aiRequestResponseService) {
|
|
38581
39242
|
this.http = http;
|
|
38582
39243
|
this.ctx = ctx;
|
|
38583
39244
|
this.columnInfoService = columnInfoService;
|
|
38584
39245
|
this.zone = zone;
|
|
39246
|
+
this.aiRequestResponseService = aiRequestResponseService;
|
|
38585
39247
|
}
|
|
38586
39248
|
ngAfterViewInit() {
|
|
38587
|
-
// Build a nested GridColumnDescriptor tree based on the actual Grid columns structure.
|
|
38588
|
-
// This includes root columns and their nested children (for ColumnGroup and SpanColumn).
|
|
38589
|
-
const rootColumns = this.ctx?.grid?.columnList?.rootColumns() || [];
|
|
38590
|
-
const buildDescriptor = (col) => {
|
|
38591
|
-
const hasChildren = Boolean(col.hasChildren && col.childrenArray?.length);
|
|
38592
|
-
const descriptor = {
|
|
38593
|
-
id: col.id,
|
|
38594
|
-
field: col.field
|
|
38595
|
-
};
|
|
38596
|
-
if (hasChildren) {
|
|
38597
|
-
descriptor.header = col.displayTitle;
|
|
38598
|
-
descriptor.columns = col.childrenArray.map((c) => buildDescriptor(c));
|
|
38599
|
-
}
|
|
38600
|
-
// For special columns that don't have a field, emit an optional type token
|
|
38601
|
-
// so the AI service knows how to treat them (checkbox/command/reorder)
|
|
38602
|
-
if (!col.field) {
|
|
38603
|
-
if (isCheckboxColumn(col)) {
|
|
38604
|
-
descriptor.type = 'checkbox';
|
|
38605
|
-
}
|
|
38606
|
-
else if (col instanceof CommandColumnComponent) {
|
|
38607
|
-
descriptor.type = 'command';
|
|
38608
|
-
}
|
|
38609
|
-
}
|
|
38610
|
-
return descriptor;
|
|
38611
|
-
};
|
|
38612
|
-
this.columnsTree = rootColumns.map((col) => buildDescriptor(col));
|
|
38613
39249
|
// Preserve a flat columns array (fields) for highlight utilities.
|
|
38614
39250
|
// Use leafNamedColumns as the canonical list of leaf columns with display titles.
|
|
38615
39251
|
this.leafColumns = this.columnInfoService.leafNamedColumns || [];
|
|
@@ -38637,8 +39273,7 @@ class AiAssistantComponent {
|
|
|
38637
39273
|
this.lastMessage = ev.prompt;
|
|
38638
39274
|
}
|
|
38639
39275
|
this.requestData = {
|
|
38640
|
-
//
|
|
38641
|
-
columns: this.columnsTree,
|
|
39276
|
+
columns: [], // Will be populated by service
|
|
38642
39277
|
promptMessage: ev.prompt,
|
|
38643
39278
|
url: this.requestUrl,
|
|
38644
39279
|
requestOptions: {
|
|
@@ -38646,16 +39281,7 @@ class AiAssistantComponent {
|
|
|
38646
39281
|
}
|
|
38647
39282
|
};
|
|
38648
39283
|
if (!this.requestOptions.body) {
|
|
38649
|
-
|
|
38650
|
-
role: this.requestData.requestOptions.role,
|
|
38651
|
-
contents: [
|
|
38652
|
-
{
|
|
38653
|
-
text: this.requestData.promptMessage
|
|
38654
|
-
}
|
|
38655
|
-
],
|
|
38656
|
-
columns: this.requestData.columns
|
|
38657
|
-
};
|
|
38658
|
-
this.requestData.requestOptions.body = requestBody;
|
|
39284
|
+
this.requestData.requestOptions.body = this.aiRequestResponseService.buildRequestBody(this.requestData.promptMessage, this.requestData.requestOptions.role);
|
|
38659
39285
|
}
|
|
38660
39286
|
this.aiToolDirective.promptRequest.emit({ requestData: this.requestData, isRetry: ev.isRetry });
|
|
38661
39287
|
if (!this.requestUrl) {
|
|
@@ -38690,12 +39316,11 @@ class AiAssistantComponent {
|
|
|
38690
39316
|
return;
|
|
38691
39317
|
}
|
|
38692
39318
|
const messages = [];
|
|
38693
|
-
// Include optional top-level message from the response
|
|
38694
39319
|
if (responseBody.message) {
|
|
38695
39320
|
messages.push(responseBody.message);
|
|
38696
39321
|
}
|
|
38697
|
-
|
|
38698
|
-
|
|
39322
|
+
const commandMessages = this.aiRequestResponseService.processCommands(responseBody.commands || [], this.columns, this.leafColumns);
|
|
39323
|
+
messages.push(...commandMessages);
|
|
38699
39324
|
const responseContentStart = [`${this.ctx.localization.get('aiAssistantOutputCardBodyContent')} \n`];
|
|
38700
39325
|
const responseContentBody = messages
|
|
38701
39326
|
.map((output, idx) => `${idx + 1} ${output}`)
|
|
@@ -38735,545 +39360,7 @@ class AiAssistantComponent {
|
|
|
38735
39360
|
this.currentRequestSubscription = null;
|
|
38736
39361
|
}
|
|
38737
39362
|
}
|
|
38738
|
-
|
|
38739
|
-
if (newItems?.length === 0) {
|
|
38740
|
-
updateGrid([]);
|
|
38741
|
-
}
|
|
38742
|
-
else if (newItems?.length) {
|
|
38743
|
-
let mergedArray = [...newItems];
|
|
38744
|
-
const newFields = newItems.map(getField);
|
|
38745
|
-
const existingItemsToKeep = currentItems.filter(item => !newFields.includes(getField(item)));
|
|
38746
|
-
mergedArray = [...mergedArray, ...existingItemsToKeep];
|
|
38747
|
-
updateGrid(mergedArray);
|
|
38748
|
-
}
|
|
38749
|
-
}
|
|
38750
|
-
processCommands(commands, messages) {
|
|
38751
|
-
if (!commands?.length) {
|
|
38752
|
-
return;
|
|
38753
|
-
}
|
|
38754
|
-
const isFilterable = Boolean(this.ctx.grid.filterable);
|
|
38755
|
-
const isSortable = Boolean(this.ctx.grid.sortable);
|
|
38756
|
-
const isGroupable = Boolean(this.ctx.grid.groupable);
|
|
38757
|
-
const findColumnById = (id) => this.ctx.grid.columnList.toArray().find((c) => c.id === id);
|
|
38758
|
-
const updateColumnHierarchy = (column, updater) => {
|
|
38759
|
-
const changed = [];
|
|
38760
|
-
const queue = [column];
|
|
38761
|
-
while (queue.length) {
|
|
38762
|
-
const current = queue.shift();
|
|
38763
|
-
if (!current) {
|
|
38764
|
-
continue;
|
|
38765
|
-
}
|
|
38766
|
-
const didChange = updater(current);
|
|
38767
|
-
if (didChange) {
|
|
38768
|
-
changed.push(current);
|
|
38769
|
-
}
|
|
38770
|
-
if (current.hasChildren && current.childrenArray?.length) {
|
|
38771
|
-
queue.push(...current.childrenArray);
|
|
38772
|
-
}
|
|
38773
|
-
}
|
|
38774
|
-
return changed;
|
|
38775
|
-
};
|
|
38776
|
-
commands.forEach((cmd) => {
|
|
38777
|
-
let displayMessage = cmd.message || '';
|
|
38778
|
-
if (this.isColumnCommand(cmd.type)) {
|
|
38779
|
-
if (cmd.id) {
|
|
38780
|
-
const column = findColumnById(cmd.id);
|
|
38781
|
-
const replacement = this.getColumnReplacement(column);
|
|
38782
|
-
displayMessage = this.replaceQuotedColumnId(displayMessage, replacement);
|
|
38783
|
-
}
|
|
38784
|
-
}
|
|
38785
|
-
messages.push(displayMessage);
|
|
38786
|
-
switch (cmd.type) {
|
|
38787
|
-
case 'GridSort':
|
|
38788
|
-
if (!isSortable) {
|
|
38789
|
-
break;
|
|
38790
|
-
}
|
|
38791
|
-
// cmd.sort is a SortDescriptor - replace or merge with existing sort
|
|
38792
|
-
this.processArrayResponse([cmd.sort], this.ctx.grid.currentState.sort || [], (item) => item.field, (mergedArray) => this.ctx.grid.sortChange.next(mergedArray));
|
|
38793
|
-
break;
|
|
38794
|
-
case 'GridClearSort':
|
|
38795
|
-
if (!isSortable) {
|
|
38796
|
-
break;
|
|
38797
|
-
}
|
|
38798
|
-
this.ctx.grid.sortChange.next([]);
|
|
38799
|
-
break;
|
|
38800
|
-
case 'GridFilter':
|
|
38801
|
-
if (!isFilterable) {
|
|
38802
|
-
break;
|
|
38803
|
-
}
|
|
38804
|
-
this.processFilterResponse(cmd.filter);
|
|
38805
|
-
break;
|
|
38806
|
-
case 'GridClearFilter':
|
|
38807
|
-
if (!isFilterable) {
|
|
38808
|
-
break;
|
|
38809
|
-
}
|
|
38810
|
-
this.ctx.grid.filterChange.next(undefined);
|
|
38811
|
-
break;
|
|
38812
|
-
case 'GridGroup':
|
|
38813
|
-
if (!isGroupable) {
|
|
38814
|
-
break;
|
|
38815
|
-
}
|
|
38816
|
-
this.processArrayResponse([cmd.group], this.ctx.grid.currentState.group || [], (item) => item.field, (mergedArray) => this.ctx.grid.groupChange.next(mergedArray));
|
|
38817
|
-
break;
|
|
38818
|
-
case 'GridClearGroup':
|
|
38819
|
-
if (!isGroupable) {
|
|
38820
|
-
break;
|
|
38821
|
-
}
|
|
38822
|
-
this.ctx.grid.groupChange.next([]);
|
|
38823
|
-
break;
|
|
38824
|
-
case 'GridHighlight':
|
|
38825
|
-
if (!this.ctx.highlightDirective) {
|
|
38826
|
-
break;
|
|
38827
|
-
}
|
|
38828
|
-
this.processHighlightResponse([cmd.highlight]);
|
|
38829
|
-
break;
|
|
38830
|
-
case 'GridClearHighlight':
|
|
38831
|
-
if (!this.ctx.highlightDirective) {
|
|
38832
|
-
break;
|
|
38833
|
-
}
|
|
38834
|
-
this.ctx.highlightDirective['setState']([]);
|
|
38835
|
-
break;
|
|
38836
|
-
case 'GridSelect': {
|
|
38837
|
-
this.processSelectionResponse([cmd.select], messages);
|
|
38838
|
-
break;
|
|
38839
|
-
}
|
|
38840
|
-
case 'GridClearSelect': {
|
|
38841
|
-
const selectionInstance = this.getSelectionInstance();
|
|
38842
|
-
if (!selectionInstance) {
|
|
38843
|
-
this.updateLastMessage(messages, this.ctx.localization?.get('aiAssistantSelectionNotEnabled'));
|
|
38844
|
-
break;
|
|
38845
|
-
}
|
|
38846
|
-
this.applySelectionState(selectionInstance, []);
|
|
38847
|
-
break;
|
|
38848
|
-
}
|
|
38849
|
-
case 'GridColumnResize': {
|
|
38850
|
-
const col = findColumnById(cmd.id);
|
|
38851
|
-
if (!col) {
|
|
38852
|
-
break;
|
|
38853
|
-
}
|
|
38854
|
-
// parse size (accept numeric or strings like '200px')
|
|
38855
|
-
let newWidth;
|
|
38856
|
-
if (typeof cmd.size === 'number') {
|
|
38857
|
-
newWidth = cmd.size;
|
|
38858
|
-
}
|
|
38859
|
-
else if (typeof cmd.size === 'string') {
|
|
38860
|
-
const numericPart = parseFloat(cmd.size);
|
|
38861
|
-
if (!isNaN(numericPart)) {
|
|
38862
|
-
newWidth = numericPart;
|
|
38863
|
-
}
|
|
38864
|
-
}
|
|
38865
|
-
if (typeof newWidth === 'number') {
|
|
38866
|
-
const oldWidth = col.width;
|
|
38867
|
-
// set the column width (ColumnBase.width setter handles string -> number)
|
|
38868
|
-
col.width = newWidth;
|
|
38869
|
-
// emit columnResize event with ColumnResizeArgs[]
|
|
38870
|
-
const args = [{ column: col, oldWidth: oldWidth, newWidth: newWidth }];
|
|
38871
|
-
this.ctx.grid.columnResize.emit(args);
|
|
38872
|
-
}
|
|
38873
|
-
break;
|
|
38874
|
-
}
|
|
38875
|
-
case 'GridColumnReorder': {
|
|
38876
|
-
const col = findColumnById(cmd.id);
|
|
38877
|
-
if (!col) {
|
|
38878
|
-
break;
|
|
38879
|
-
}
|
|
38880
|
-
const newPosition = Number(cmd.position);
|
|
38881
|
-
if (!isNaN(newPosition) && newPosition >= 0) {
|
|
38882
|
-
this.changeColumnPosition(col, newPosition);
|
|
38883
|
-
}
|
|
38884
|
-
break;
|
|
38885
|
-
}
|
|
38886
|
-
case 'GridColumnShow':
|
|
38887
|
-
case 'GridColumnHide': {
|
|
38888
|
-
const col = findColumnById(cmd.id);
|
|
38889
|
-
if (!col) {
|
|
38890
|
-
break;
|
|
38891
|
-
}
|
|
38892
|
-
const targetHidden = cmd.type === 'GridColumnHide';
|
|
38893
|
-
const changed = updateColumnHierarchy(col, (current) => {
|
|
38894
|
-
if (current.hidden === targetHidden) {
|
|
38895
|
-
return false;
|
|
38896
|
-
}
|
|
38897
|
-
current.hidden = targetHidden;
|
|
38898
|
-
return true;
|
|
38899
|
-
});
|
|
38900
|
-
if (changed.length) {
|
|
38901
|
-
this.columnInfoService.changeVisibility(changed);
|
|
38902
|
-
}
|
|
38903
|
-
break;
|
|
38904
|
-
}
|
|
38905
|
-
case 'GridColumnLock':
|
|
38906
|
-
case 'GridColumnUnlock': {
|
|
38907
|
-
const col = findColumnById(cmd.id);
|
|
38908
|
-
if (!col) {
|
|
38909
|
-
break;
|
|
38910
|
-
}
|
|
38911
|
-
const targetLocked = cmd.type === 'GridColumnLock';
|
|
38912
|
-
const changed = updateColumnHierarchy(col, (current) => {
|
|
38913
|
-
if (current.locked === targetLocked) {
|
|
38914
|
-
return false;
|
|
38915
|
-
}
|
|
38916
|
-
current.locked = targetLocked;
|
|
38917
|
-
return true;
|
|
38918
|
-
});
|
|
38919
|
-
if (changed.length) {
|
|
38920
|
-
this.columnInfoService.changeLocked(changed);
|
|
38921
|
-
}
|
|
38922
|
-
break;
|
|
38923
|
-
}
|
|
38924
|
-
case 'GridPage': {
|
|
38925
|
-
this.processPageCommand(cmd);
|
|
38926
|
-
break;
|
|
38927
|
-
}
|
|
38928
|
-
case 'GridPageSize': {
|
|
38929
|
-
this.processPageSizeCommand(cmd);
|
|
38930
|
-
break;
|
|
38931
|
-
}
|
|
38932
|
-
case 'GridExportExcel': {
|
|
38933
|
-
this.runExportWithFileName(this.ctx.excelComponent, cmd.fileName, () => this.ctx.grid.saveAsExcel());
|
|
38934
|
-
break;
|
|
38935
|
-
}
|
|
38936
|
-
case 'GridExportPDF': {
|
|
38937
|
-
this.runExportWithFileName(this.ctx.pdfComponent, cmd.fileName, () => this.ctx.grid.emitPDFExportEvent());
|
|
38938
|
-
break;
|
|
38939
|
-
}
|
|
38940
|
-
default:
|
|
38941
|
-
// Unknown command - ignore
|
|
38942
|
-
break;
|
|
38943
|
-
}
|
|
38944
|
-
});
|
|
38945
|
-
}
|
|
38946
|
-
runExportWithFileName(component, fileName, action) {
|
|
38947
|
-
if (!component || !fileName) {
|
|
38948
|
-
action();
|
|
38949
|
-
return;
|
|
38950
|
-
}
|
|
38951
|
-
const previousFileName = component.fileName;
|
|
38952
|
-
component.fileName = fileName;
|
|
38953
|
-
action();
|
|
38954
|
-
const isExcel = component === this.ctx.excelComponent;
|
|
38955
|
-
if (isExcel) {
|
|
38956
|
-
this.zone.runOutsideAngular(() => {
|
|
38957
|
-
this.ctx.excelComponent.fileCreated.subscribe(() => {
|
|
38958
|
-
component.fileName = previousFileName;
|
|
38959
|
-
});
|
|
38960
|
-
});
|
|
38961
|
-
}
|
|
38962
|
-
else {
|
|
38963
|
-
component.fileName = previousFileName;
|
|
38964
|
-
}
|
|
38965
|
-
}
|
|
38966
|
-
processPageCommand(command) {
|
|
38967
|
-
const pageSize = this.getCurrentPageSizeValue();
|
|
38968
|
-
if (!isPresent$1(pageSize) || pageSize <= 0) {
|
|
38969
|
-
return;
|
|
38970
|
-
}
|
|
38971
|
-
const total = this.getTotalItemsCount();
|
|
38972
|
-
const requestedPage = Number(command.page);
|
|
38973
|
-
let targetPage = Number.isFinite(requestedPage) ? Math.floor(requestedPage) : 1;
|
|
38974
|
-
if (targetPage < 1) {
|
|
38975
|
-
targetPage = 1;
|
|
38976
|
-
}
|
|
38977
|
-
if (isPresent$1(total) && pageSize > 0) {
|
|
38978
|
-
const maxPage = Math.max(1, Math.ceil(total / pageSize));
|
|
38979
|
-
targetPage = Math.min(targetPage, maxPage);
|
|
38980
|
-
}
|
|
38981
|
-
const skip = (targetPage - 1) * pageSize;
|
|
38982
|
-
this.emitGridPageChange(skip, pageSize);
|
|
38983
|
-
}
|
|
38984
|
-
processPageSizeCommand(command) {
|
|
38985
|
-
const rawPageSize = Number(command.pageSize);
|
|
38986
|
-
if (!Number.isFinite(rawPageSize)) {
|
|
38987
|
-
return;
|
|
38988
|
-
}
|
|
38989
|
-
const newPageSize = Math.max(1, Math.floor(rawPageSize));
|
|
38990
|
-
const skip = Math.max(0, this.ctx.grid?.skip ?? 0);
|
|
38991
|
-
this.ensurePageSizeOption(newPageSize);
|
|
38992
|
-
this.emitGridPageChange(skip, newPageSize);
|
|
38993
|
-
}
|
|
38994
|
-
emitGridPageChange(skip, take) {
|
|
38995
|
-
const grid = this.ctx.grid;
|
|
38996
|
-
const normalizedSkip = Math.max(0, Math.floor(skip));
|
|
38997
|
-
const normalizedTake = Math.max(1, Math.floor(take));
|
|
38998
|
-
grid.skip = normalizedSkip;
|
|
38999
|
-
grid.pageSize = normalizedTake;
|
|
39000
|
-
grid.pageChange.emit({ skip: normalizedSkip, take: normalizedTake });
|
|
39001
|
-
}
|
|
39002
|
-
ensurePageSizeOption(pageSize) {
|
|
39003
|
-
const grid = this.ctx.grid;
|
|
39004
|
-
if (!grid) {
|
|
39005
|
-
return;
|
|
39006
|
-
}
|
|
39007
|
-
const pageable = grid.pageable;
|
|
39008
|
-
if (!pageable || typeof pageable === 'boolean') {
|
|
39009
|
-
return;
|
|
39010
|
-
}
|
|
39011
|
-
const pageSizes = pageable.pageSizes;
|
|
39012
|
-
if (!Array.isArray(pageSizes) || pageSizes.length === 0) {
|
|
39013
|
-
return;
|
|
39014
|
-
}
|
|
39015
|
-
if (pageSizes.includes(pageSize)) {
|
|
39016
|
-
return;
|
|
39017
|
-
}
|
|
39018
|
-
const uniqueSizes = [pageSize, ...pageSizes.filter(size => size !== pageSize)];
|
|
39019
|
-
grid.pageable = {
|
|
39020
|
-
...pageable,
|
|
39021
|
-
pageSizes: uniqueSizes
|
|
39022
|
-
};
|
|
39023
|
-
const changeDetector = grid?.changeDetectorRef;
|
|
39024
|
-
if (changeDetector && typeof changeDetector.markForCheck === 'function') {
|
|
39025
|
-
changeDetector.markForCheck();
|
|
39026
|
-
}
|
|
39027
|
-
}
|
|
39028
|
-
getCurrentPageSizeValue() {
|
|
39029
|
-
const grid = this.ctx.grid;
|
|
39030
|
-
if (!grid) {
|
|
39031
|
-
return null;
|
|
39032
|
-
}
|
|
39033
|
-
const candidates = [grid.pageSize, grid.currentState?.take, this.ctx.dataBindingDirective?.['state']?.take];
|
|
39034
|
-
for (const candidate of candidates) {
|
|
39035
|
-
if (typeof candidate === 'number' && candidate > 0) {
|
|
39036
|
-
return candidate;
|
|
39037
|
-
}
|
|
39038
|
-
}
|
|
39039
|
-
const pageable = grid.pageable;
|
|
39040
|
-
if (pageable && typeof pageable === 'object' && Array.isArray(pageable.pageSizes)) {
|
|
39041
|
-
const numericSize = pageable.pageSizes.find(size => typeof size === 'number' && size > 0);
|
|
39042
|
-
if (numericSize) {
|
|
39043
|
-
return numericSize;
|
|
39044
|
-
}
|
|
39045
|
-
}
|
|
39046
|
-
const originalData = this.ctx.dataBindingDirective?.['originalData'];
|
|
39047
|
-
if (Array.isArray(originalData) && originalData.length > 0) {
|
|
39048
|
-
return originalData.length;
|
|
39049
|
-
}
|
|
39050
|
-
return null;
|
|
39051
|
-
}
|
|
39052
|
-
getTotalItemsCount() {
|
|
39053
|
-
const grid = this.ctx.grid;
|
|
39054
|
-
if (!grid) {
|
|
39055
|
-
return null;
|
|
39056
|
-
}
|
|
39057
|
-
const gridData = grid.data;
|
|
39058
|
-
if (gridData && typeof gridData.total === 'number') {
|
|
39059
|
-
return gridData.total;
|
|
39060
|
-
}
|
|
39061
|
-
const view = grid.view;
|
|
39062
|
-
if (view && typeof view.total === 'number') {
|
|
39063
|
-
return view.total;
|
|
39064
|
-
}
|
|
39065
|
-
const originalData = this.ctx.dataBindingDirective?.['originalData'];
|
|
39066
|
-
if (Array.isArray(originalData)) {
|
|
39067
|
-
return originalData.length;
|
|
39068
|
-
}
|
|
39069
|
-
return null;
|
|
39070
|
-
}
|
|
39071
|
-
getSelectionInstance() {
|
|
39072
|
-
const selectionDirective = this.ctx.grid?.selectionDirective;
|
|
39073
|
-
if (selectionDirective && typeof selectionDirective === 'object') {
|
|
39074
|
-
return selectionDirective;
|
|
39075
|
-
}
|
|
39076
|
-
const defaultSelection = this.ctx.grid?.defaultSelection;
|
|
39077
|
-
if (defaultSelection && typeof defaultSelection === 'object') {
|
|
39078
|
-
return defaultSelection;
|
|
39079
|
-
}
|
|
39080
|
-
return null;
|
|
39081
|
-
}
|
|
39082
|
-
updateLastMessage(messages, newMessage) {
|
|
39083
|
-
if (!messages.length) {
|
|
39084
|
-
return;
|
|
39085
|
-
}
|
|
39086
|
-
messages[messages.length - 1] = newMessage;
|
|
39087
|
-
}
|
|
39088
|
-
getHighlightItems(descriptors) {
|
|
39089
|
-
if (!descriptors?.length) {
|
|
39090
|
-
return [];
|
|
39091
|
-
}
|
|
39092
|
-
const data = this.ctx.dataBindingDirective?.['originalData'] || [];
|
|
39093
|
-
return highlightBy(data, descriptors, this.columns);
|
|
39094
|
-
}
|
|
39095
|
-
processSelectionResponse(selection, messages) {
|
|
39096
|
-
const selectionInstance = this.getSelectionInstance();
|
|
39097
|
-
if (!selectionInstance) {
|
|
39098
|
-
this.updateLastMessage(messages, this.ctx.localization?.get('aiAssistantSelectionNotEnabled'));
|
|
39099
|
-
return;
|
|
39100
|
-
}
|
|
39101
|
-
const descriptors = (selection || []).filter((descriptor) => Boolean(descriptor));
|
|
39102
|
-
if (descriptors.length === 0) {
|
|
39103
|
-
this.applySelectionState(selectionInstance, []);
|
|
39104
|
-
return;
|
|
39105
|
-
}
|
|
39106
|
-
const highlightItems = this.getHighlightItems(descriptors);
|
|
39107
|
-
if (!highlightItems.length) {
|
|
39108
|
-
this.applySelectionState(selectionInstance, []);
|
|
39109
|
-
return;
|
|
39110
|
-
}
|
|
39111
|
-
const hasCellSelections = highlightItems.some(item => isPresent$1(item.columnKey));
|
|
39112
|
-
const hasRowSelections = highlightItems.some(item => !isPresent$1(item.columnKey));
|
|
39113
|
-
const isCellMode = selectionInstance.isCellSelectionMode;
|
|
39114
|
-
if ((!isCellMode && hasCellSelections) || (isCellMode && hasRowSelections)) {
|
|
39115
|
-
const key = isCellMode ? 'aiAssistantSelectionRowModeRequired' : 'aiAssistantSelectionCellModeRequired';
|
|
39116
|
-
this.updateLastMessage(messages, this.ctx.localization?.get(key));
|
|
39117
|
-
return;
|
|
39118
|
-
}
|
|
39119
|
-
const selectionState = this.mapHighlightItemsToSelection(selectionInstance, highlightItems, isCellMode);
|
|
39120
|
-
this.applySelectionState(selectionInstance, selectionState);
|
|
39121
|
-
}
|
|
39122
|
-
mapHighlightItemsToSelection(selectionInstance, highlightItems, isCellMode) {
|
|
39123
|
-
const data = this.ctx.dataBindingDirective?.['originalData'] || [];
|
|
39124
|
-
if (isCellMode) {
|
|
39125
|
-
const mapped = highlightItems
|
|
39126
|
-
.filter(item => isPresent$1(item.itemKey) && isPresent$1(item.columnKey))
|
|
39127
|
-
.map(item => {
|
|
39128
|
-
const rowIndex = item.itemKey;
|
|
39129
|
-
const columnIndex = item.columnKey;
|
|
39130
|
-
const dataItem = data[rowIndex];
|
|
39131
|
-
if (!isPresent$1(dataItem)) {
|
|
39132
|
-
return null;
|
|
39133
|
-
}
|
|
39134
|
-
if (typeof selectionInstance['getSelectionItem'] === 'function') {
|
|
39135
|
-
const columnComponent = this.leafColumns[columnIndex];
|
|
39136
|
-
const selectionItem = selectionInstance['getSelectionItem']({ dataItem, index: rowIndex }, columnComponent, columnIndex);
|
|
39137
|
-
if (selectionItem && isPresent$1(selectionItem.itemKey) && isPresent$1(selectionItem.columnKey)) {
|
|
39138
|
-
return selectionItem;
|
|
39139
|
-
}
|
|
39140
|
-
return null;
|
|
39141
|
-
}
|
|
39142
|
-
const itemKey = typeof selectionInstance.getItemKey === 'function'
|
|
39143
|
-
? selectionInstance.getItemKey({ dataItem, index: rowIndex })
|
|
39144
|
-
: rowIndex;
|
|
39145
|
-
return isPresent$1(itemKey) ? { itemKey, columnKey: columnIndex } : null;
|
|
39146
|
-
})
|
|
39147
|
-
.filter((item) => isPresent$1(item));
|
|
39148
|
-
return mapped.filter((item, index, self) => self.findIndex(other => other.itemKey === item.itemKey && other.columnKey === item.columnKey) === index);
|
|
39149
|
-
}
|
|
39150
|
-
const rowKeys = highlightItems
|
|
39151
|
-
.filter(item => isPresent$1(item.itemKey))
|
|
39152
|
-
.map(item => {
|
|
39153
|
-
const rowIndex = item.itemKey;
|
|
39154
|
-
const dataItem = data[rowIndex];
|
|
39155
|
-
if (!isPresent$1(dataItem)) {
|
|
39156
|
-
return null;
|
|
39157
|
-
}
|
|
39158
|
-
if (typeof selectionInstance.getItemKey === 'function') {
|
|
39159
|
-
return selectionInstance.getItemKey({ dataItem, index: rowIndex });
|
|
39160
|
-
}
|
|
39161
|
-
return rowIndex;
|
|
39162
|
-
})
|
|
39163
|
-
.filter(isPresent$1);
|
|
39164
|
-
return Array.from(new Set(rowKeys));
|
|
39165
|
-
}
|
|
39166
|
-
applySelectionState(selectionInstance, selectionState) {
|
|
39167
|
-
selectionInstance.selectedKeys = selectionState;
|
|
39168
|
-
if (typeof selectionInstance['setState'] === 'function') {
|
|
39169
|
-
selectionInstance['setState'](selectionState);
|
|
39170
|
-
}
|
|
39171
|
-
const changeDetector = selectionInstance['cd'];
|
|
39172
|
-
if (changeDetector && typeof changeDetector.markForCheck === 'function') {
|
|
39173
|
-
changeDetector.markForCheck();
|
|
39174
|
-
}
|
|
39175
|
-
if (typeof selectionInstance['notifyChange'] === 'function') {
|
|
39176
|
-
selectionInstance['notifyChange']();
|
|
39177
|
-
}
|
|
39178
|
-
}
|
|
39179
|
-
replaceQuotedColumnId(message, replacement) {
|
|
39180
|
-
if (!replacement) {
|
|
39181
|
-
const columnIdPattern = /(?:"|")(k-grid\d+-col\d+)(?:"|")\s*/g;
|
|
39182
|
-
return message.replace(columnIdPattern, '').replace(/\s{2,}/g, ' ').trim();
|
|
39183
|
-
}
|
|
39184
|
-
const columnIdPattern = /(?:"|")(k-grid\d+-col\d+)(?:"|")/g;
|
|
39185
|
-
return message.replace(columnIdPattern, (match) => {
|
|
39186
|
-
const isEncoded = match.startsWith('"');
|
|
39187
|
-
return isEncoded ? `"${replacement}"` : `"${replacement}"`;
|
|
39188
|
-
});
|
|
39189
|
-
}
|
|
39190
|
-
isColumnCommand(type) {
|
|
39191
|
-
return type === 'GridColumnResize' ||
|
|
39192
|
-
type === 'GridColumnReorder' ||
|
|
39193
|
-
type === 'GridColumnShow' ||
|
|
39194
|
-
type === 'GridColumnHide' ||
|
|
39195
|
-
type === 'GridColumnLock' ||
|
|
39196
|
-
type === 'GridColumnUnlock';
|
|
39197
|
-
}
|
|
39198
|
-
getColumnReplacement(column) {
|
|
39199
|
-
if (!column) {
|
|
39200
|
-
return '';
|
|
39201
|
-
}
|
|
39202
|
-
if (column.title && String(column.title).trim()) {
|
|
39203
|
-
return String(column.title).trim();
|
|
39204
|
-
}
|
|
39205
|
-
if (column.field && String(column.field).trim()) {
|
|
39206
|
-
return String(column.field).trim();
|
|
39207
|
-
}
|
|
39208
|
-
return '';
|
|
39209
|
-
}
|
|
39210
|
-
processHighlightResponse(highlight) {
|
|
39211
|
-
const highlightedItems = this.getHighlightItems(highlight);
|
|
39212
|
-
this.ctx.highlightDirective['setState'](highlightedItems);
|
|
39213
|
-
}
|
|
39214
|
-
processFilterResponse(filter) {
|
|
39215
|
-
const processedFilter = convertDateStringsInFilter(filter);
|
|
39216
|
-
const clearFilter = Object.keys(processedFilter).length === 0;
|
|
39217
|
-
if (clearFilter) {
|
|
39218
|
-
this.ctx.grid.filterChange.next(undefined);
|
|
39219
|
-
}
|
|
39220
|
-
else if (processedFilter?.filters.length) {
|
|
39221
|
-
const currentFilter = this.ctx.grid.currentState.filter;
|
|
39222
|
-
let mergedFilter = processedFilter;
|
|
39223
|
-
if (currentFilter && currentFilter.filters?.length > 0) {
|
|
39224
|
-
mergedFilter = {
|
|
39225
|
-
logic: 'and',
|
|
39226
|
-
filters: [
|
|
39227
|
-
currentFilter,
|
|
39228
|
-
processedFilter
|
|
39229
|
-
]
|
|
39230
|
-
};
|
|
39231
|
-
}
|
|
39232
|
-
this.ctx.grid.filterChange.next(mergedFilter);
|
|
39233
|
-
}
|
|
39234
|
-
}
|
|
39235
|
-
changeColumnPosition(column, newPosition) {
|
|
39236
|
-
const grid = this.ctx.grid;
|
|
39237
|
-
if (!grid?.columns) {
|
|
39238
|
-
return;
|
|
39239
|
-
}
|
|
39240
|
-
const currentColumns = grid.columns.toArray();
|
|
39241
|
-
const currentIndex = currentColumns.findIndex(col => col === column);
|
|
39242
|
-
if (currentIndex === -1) {
|
|
39243
|
-
return;
|
|
39244
|
-
}
|
|
39245
|
-
if (newPosition < 0 || newPosition >= currentColumns.length) {
|
|
39246
|
-
return;
|
|
39247
|
-
}
|
|
39248
|
-
const sortedColumns = currentColumns
|
|
39249
|
-
.map((col, idx) => ({ col, physicalIndex: idx, visualOrder: col.orderIndex ?? idx }))
|
|
39250
|
-
.sort((a, b) => a.visualOrder - b.visualOrder);
|
|
39251
|
-
const currentVisualPos = sortedColumns.findIndex(item => item.physicalIndex === currentIndex);
|
|
39252
|
-
if (currentVisualPos === newPosition) {
|
|
39253
|
-
return;
|
|
39254
|
-
}
|
|
39255
|
-
currentColumns.forEach((col, idx) => {
|
|
39256
|
-
const sortedIndex = sortedColumns.findIndex(item => item.physicalIndex === idx);
|
|
39257
|
-
if (idx === currentIndex) {
|
|
39258
|
-
col.orderIndex = newPosition;
|
|
39259
|
-
}
|
|
39260
|
-
else if (currentVisualPos < newPosition) {
|
|
39261
|
-
col.orderIndex = (sortedIndex > currentVisualPos && sortedIndex <= newPosition)
|
|
39262
|
-
? sortedIndex - 1 : sortedIndex;
|
|
39263
|
-
}
|
|
39264
|
-
else {
|
|
39265
|
-
col.orderIndex = (sortedIndex >= newPosition && sortedIndex < currentVisualPos)
|
|
39266
|
-
? sortedIndex + 1 : sortedIndex;
|
|
39267
|
-
}
|
|
39268
|
-
col.isReordered = true;
|
|
39269
|
-
});
|
|
39270
|
-
grid.columnReorder.emit({
|
|
39271
|
-
column: column,
|
|
39272
|
-
oldIndex: currentVisualPos,
|
|
39273
|
-
newIndex: newPosition
|
|
39274
|
-
});
|
|
39275
|
-
}
|
|
39276
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: AiAssistantComponent, deps: [{ token: i1$8.HttpClient }, { token: ContextService }, { token: ColumnInfoService }, { token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component });
|
|
39363
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: AiAssistantComponent, deps: [{ token: i1$8.HttpClient }, { token: ContextService }, { token: ColumnInfoService }, { token: i0.NgZone }, { token: GridAIRequestResponseService }], target: i0.ɵɵFactoryTarget.Component });
|
|
39277
39364
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.14", type: AiAssistantComponent, isStandalone: true, selector: "ng-component", viewQueries: [{ propertyName: "aiPrompt", first: true, predicate: AIPromptComponent, descendants: true }], ngImport: i0, template: `
|
|
39278
39365
|
<kendo-aiprompt
|
|
39279
39366
|
#aiPrompt
|
|
@@ -39377,7 +39464,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImpo
|
|
|
39377
39464
|
</kendo-aiprompt>
|
|
39378
39465
|
`
|
|
39379
39466
|
}]
|
|
39380
|
-
}], ctorParameters: () => [{ type: i1$8.HttpClient }, { type: ContextService }, { type: ColumnInfoService }, { type: i0.NgZone }], propDecorators: { aiPrompt: [{
|
|
39467
|
+
}], ctorParameters: () => [{ type: i1$8.HttpClient }, { type: ContextService }, { type: ColumnInfoService }, { type: i0.NgZone }, { type: GridAIRequestResponseService }], propDecorators: { aiPrompt: [{
|
|
39381
39468
|
type: ViewChild,
|
|
39382
39469
|
args: [AIPromptComponent]
|
|
39383
39470
|
}] } });
|