@progress/kendo-angular-grid 12.0.0-develop.8 → 12.0.0
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/column-menu/column-menu-item-content-template.directive.d.ts +13 -24
- package/column-menu/column-menu-template.directive.d.ts +14 -28
- package/column-menu/column-menu.service.d.ts +9 -21
- package/columns/column-base.d.ts +18 -369
- package/columns/reorder-column.component.d.ts +31 -0
- package/columns/sort-settings.d.ts +20 -4
- package/common/fetch-data-callback.d.ts +1 -1
- package/common/preventable-event.d.ts +1 -1
- package/common/single-popup.service.d.ts +1 -1
- package/common/size-options.d.ts +1 -2
- package/data/grid-item.interface.d.ts +6 -3
- package/databinding.directive.d.ts +15 -1
- package/editing/add-command.directive.d.ts +1 -1
- package/editing/cancel-command.directive.d.ts +4 -16
- package/editing/edit-template.directive.d.ts +2 -3
- package/editing/remove-command.directive.d.ts +6 -6
- package/editing/save-command.directive.d.ts +3 -15
- package/editing-directives/in-cell-editing.directive.d.ts +1 -1
- package/editing-directives/template-editing.directive.d.ts +1 -1
- package/esm2020/column-menu/column-menu-item-content-template.directive.mjs +13 -24
- package/esm2020/column-menu/column-menu-template.directive.mjs +14 -28
- package/esm2020/column-menu/column-menu.service.mjs +9 -21
- package/esm2020/columns/column-base.mjs +10 -40
- package/esm2020/columns/reorder-column.component.mjs +55 -0
- package/esm2020/common/preventable-event.mjs +1 -1
- package/esm2020/common/single-popup.service.mjs +1 -1
- package/esm2020/databinding.directive.mjs +30 -3
- package/esm2020/editing/add-command.directive.mjs +1 -1
- package/esm2020/editing/cancel-command.directive.mjs +4 -16
- package/esm2020/editing/edit-template.directive.mjs +2 -3
- package/esm2020/editing/remove-command.directive.mjs +6 -6
- package/esm2020/editing/save-command.directive.mjs +3 -15
- package/esm2020/editing-directives/in-cell-editing.directive.mjs +1 -1
- package/esm2020/editing-directives/template-editing.directive.mjs +1 -1
- package/esm2020/excel/excel-command.directive.mjs +2 -2
- package/esm2020/excel/excel.module.mjs +5 -15
- package/esm2020/grid.component.mjs +195 -38
- package/esm2020/grid.module.mjs +76 -81
- package/esm2020/grouping/group-footer-template.directive.mjs +9 -35
- package/esm2020/grouping/group-header-column-template.directive.mjs +2 -2
- package/esm2020/grouping/group-header-template.directive.mjs +9 -37
- package/esm2020/index.mjs +1 -0
- package/esm2020/layout/sizing-options.service.mjs +3 -0
- package/esm2020/localization/messages.mjs +3 -1
- package/esm2020/navigation/focusable.directive.mjs +10 -41
- package/esm2020/package-metadata.mjs +2 -2
- package/esm2020/pager/pager-template.directive.mjs +13 -46
- package/esm2020/pdf/pdf-template.directive.mjs +10 -38
- package/esm2020/pdf/pdf.module.mjs +7 -16
- package/esm2020/rendering/body.module.mjs +9 -4
- package/esm2020/rendering/cell-loading.template.directive.mjs +11 -8
- package/esm2020/rendering/cell-template.directive.mjs +11 -35
- package/esm2020/rendering/cell.component.mjs +43 -10
- package/esm2020/rendering/details/detail-template.directive.mjs +10 -58
- package/esm2020/rendering/details-expand.directive.mjs +1 -1
- package/esm2020/rendering/footer/footer-template.directive.mjs +8 -35
- package/esm2020/rendering/header/header-template.directive.mjs +9 -36
- package/esm2020/rendering/loading-template.directive.mjs +1 -1
- package/esm2020/rendering/no-records-template.directive.mjs +11 -58
- package/esm2020/rendering/toolbar/toolbar-position.mjs +17 -0
- package/esm2020/rendering/toolbar/toolbar-template.directive.mjs +10 -56
- package/esm2020/row-reordering/row-reorder.service.mjs +233 -0
- package/esm2020/row-reordering/types.mjs +5 -0
- package/esm2020/row-reordering/utils.mjs +87 -0
- package/esm2020/selection/selectall-checkbox.directive.mjs +12 -1
- package/esm2020/selection/selection-checkbox.directive.mjs +11 -44
- package/esm2020/selection/selection-default.mjs +1 -0
- package/esm2020/selection/selection.directive.mjs +1 -1
- package/excel/excel-command.directive.d.ts +2 -2
- package/excel/excel.module.d.ts +5 -15
- package/fesm2015/progress-kendo-angular-grid.mjs +869 -792
- package/fesm2020/progress-kendo-angular-grid.mjs +869 -796
- package/filtering/filterable.d.ts +10 -0
- package/grid.component.d.ts +46 -4
- package/grid.module.d.ts +93 -101
- package/grouping/group-footer-template.directive.d.ts +9 -35
- package/grouping/group-header-column-template.directive.d.ts +2 -2
- package/grouping/group-header-template.directive.d.ts +9 -37
- package/index.d.ts +2 -0
- package/layout/sizing-options.service.d.ts +3 -0
- package/localization/messages.d.ts +5 -1
- package/navigation/focusable.directive.d.ts +10 -41
- package/navigation/navigable-settings.d.ts +15 -1
- package/package.json +15 -14
- package/pager/pager-settings.d.ts +8 -12
- package/pager/pager-template.directive.d.ts +13 -46
- package/pdf/pdf-template.directive.d.ts +10 -38
- package/pdf/pdf.module.d.ts +7 -16
- package/rendering/body.module.d.ts +9 -8
- package/rendering/cell-loading.template.directive.d.ts +11 -8
- package/rendering/cell-template.directive.d.ts +11 -35
- package/rendering/cell.component.d.ts +5 -0
- package/rendering/common/row-class.d.ts +4 -4
- package/rendering/details/detail-template.directive.d.ts +10 -58
- package/rendering/details-expand.directive.d.ts +1 -1
- package/rendering/footer/footer-template.directive.d.ts +8 -35
- package/rendering/header/header-template.directive.d.ts +9 -36
- package/rendering/loading-template.directive.d.ts +1 -1
- package/rendering/no-records-template.directive.d.ts +11 -58
- package/rendering/toolbar/toolbar-position.d.ts +18 -1
- package/rendering/toolbar/toolbar-template.directive.d.ts +10 -56
- package/row-reordering/row-reorder.service.d.ts +57 -0
- package/row-reordering/types.d.ts +40 -0
- package/row-reordering/utils.d.ts +78 -0
- package/schematics/ngAdd/index.js +2 -2
- package/scrolling/scrollmode.d.ts +4 -4
- package/selection/selectall-checkbox.directive.d.ts +12 -1
- package/selection/selection-checkbox.directive.d.ts +11 -44
- package/selection/selection-default.d.ts +1 -0
- package/selection/selection.directive.d.ts +1 -1
- package/selection/types.d.ts +24 -2
|
@@ -27,28 +27,19 @@ const declarations = [
|
|
|
27
27
|
*
|
|
28
28
|
* @example
|
|
29
29
|
*
|
|
30
|
-
* ```ts
|
|
31
|
-
* // Import the Grid and PDF modules
|
|
32
|
-
* import { GridModule, PDFModule } from '@progress/kendo-angular-grid';
|
|
33
|
-
*
|
|
34
|
-
* // The browser platform with a compiler
|
|
35
|
-
* import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';
|
|
36
|
-
*
|
|
30
|
+
* ```ts
|
|
37
31
|
* import { NgModule } from '@angular/core';
|
|
38
|
-
*
|
|
39
|
-
*
|
|
32
|
+
* import { BrowserModule } from "@angular/platform-browser";
|
|
33
|
+
* import { GridModule, PDFModule } from '@progress/kendo-angular-grid';
|
|
40
34
|
* import { AppComponent } from './app.component';
|
|
41
35
|
*
|
|
42
|
-
*
|
|
43
|
-
*
|
|
44
|
-
*
|
|
45
|
-
* imports: [BrowserModule, GridModule, PDFModule], // import Grid and PDF modules
|
|
36
|
+
* @NgModule({
|
|
37
|
+
* declarations: [AppComponent],
|
|
38
|
+
* imports: [BrowserModule, GridModule, PDFModule],
|
|
46
39
|
* bootstrap: [AppComponent]
|
|
47
40
|
* })
|
|
48
|
-
* export class AppModule {}
|
|
49
41
|
*
|
|
50
|
-
*
|
|
51
|
-
* platformBrowserDynamic().bootstrapModule(AppModule);
|
|
42
|
+
* export class AppModule {}
|
|
52
43
|
*
|
|
53
44
|
* ```
|
|
54
45
|
*/
|
|
@@ -25,6 +25,7 @@ import { NumericTextBoxModule } from "@progress/kendo-angular-inputs";
|
|
|
25
25
|
import { DatePickerModule } from '@progress/kendo-angular-dateinputs';
|
|
26
26
|
import { CellLoadingTemplateDirective } from './cell-loading.template.directive';
|
|
27
27
|
import { LoadingTemplateDirective } from './loading-template.directive';
|
|
28
|
+
import { RowReorderColumnComponent } from '../columns/reorder-column.component';
|
|
28
29
|
import * as i0 from "@angular/core";
|
|
29
30
|
const exported = [
|
|
30
31
|
CommandColumnComponent,
|
|
@@ -41,7 +42,8 @@ const exported = [
|
|
|
41
42
|
RemoveCommandDirective,
|
|
42
43
|
AddCommandDirective,
|
|
43
44
|
CellLoadingTemplateDirective,
|
|
44
|
-
LoadingTemplateDirective
|
|
45
|
+
LoadingTemplateDirective,
|
|
46
|
+
RowReorderColumnComponent
|
|
45
47
|
];
|
|
46
48
|
const importedModules = [
|
|
47
49
|
CommonModule,
|
|
@@ -71,7 +73,8 @@ export class BodyModule {
|
|
|
71
73
|
RemoveCommandDirective,
|
|
72
74
|
AddCommandDirective,
|
|
73
75
|
CellLoadingTemplateDirective,
|
|
74
|
-
LoadingTemplateDirective
|
|
76
|
+
LoadingTemplateDirective,
|
|
77
|
+
RowReorderColumnComponent
|
|
75
78
|
];
|
|
76
79
|
}
|
|
77
80
|
}
|
|
@@ -90,7 +93,8 @@ BodyModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13
|
|
|
90
93
|
RemoveCommandDirective,
|
|
91
94
|
AddCommandDirective,
|
|
92
95
|
CellLoadingTemplateDirective,
|
|
93
|
-
LoadingTemplateDirective
|
|
96
|
+
LoadingTemplateDirective,
|
|
97
|
+
RowReorderColumnComponent], imports: [CommonModule,
|
|
94
98
|
ReactiveFormsModule,
|
|
95
99
|
FormsModule,
|
|
96
100
|
SharedModule,
|
|
@@ -111,7 +115,8 @@ BodyModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13
|
|
|
111
115
|
RemoveCommandDirective,
|
|
112
116
|
AddCommandDirective,
|
|
113
117
|
CellLoadingTemplateDirective,
|
|
114
|
-
LoadingTemplateDirective
|
|
118
|
+
LoadingTemplateDirective,
|
|
119
|
+
RowReorderColumnComponent] });
|
|
115
120
|
BodyModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: BodyModule, imports: [[...importedModules]] });
|
|
116
121
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: BodyModule, decorators: [{
|
|
117
122
|
type: NgModule,
|
|
@@ -7,17 +7,20 @@ import * as i0 from "@angular/core";
|
|
|
7
7
|
/**
|
|
8
8
|
* Represents the virtual scrolling cell template of the Grid while loading new data. Provides an option to customize the
|
|
9
9
|
* appearance of the indicator that is displayed while new data is loading. To define the loading cell template,
|
|
10
|
-
* nest an `<ng-template>` tag with the `kendoGridCellLoadingTemplate` directive inside `<kendo-grid>`
|
|
10
|
+
* nest an `<ng-template>` tag with the `kendoGridCellLoadingTemplate` directive inside `<kendo-grid>` tag [see example]({% slug virtualscrolling_grid %}#toc-custom-loading-skeleton).
|
|
11
11
|
*
|
|
12
|
-
*
|
|
12
|
+
*
|
|
13
|
+
* The template context is set to the current column and the following additional field is passed:
|
|
14
|
+
*
|
|
15
|
+
* - `column`—The current column instance. Represents the default context that will be assigned to any template variable which utilizes the `let-x` syntax (for example `let-column`).
|
|
13
16
|
*
|
|
14
17
|
* @example
|
|
15
|
-
* ```
|
|
16
|
-
*
|
|
17
|
-
*
|
|
18
|
-
*
|
|
19
|
-
*
|
|
20
|
-
*
|
|
18
|
+
* ```html
|
|
19
|
+
* <kendo-grid ... scrollable="virtual" [rowHeight]="36" [height]="450">
|
|
20
|
+
* <ng-template kendoGridCellLoadingTemplate let-column>
|
|
21
|
+
* ...
|
|
22
|
+
* </ng-template>
|
|
23
|
+
* </kendo-grid>
|
|
21
24
|
* ```
|
|
22
25
|
*/
|
|
23
26
|
export class CellLoadingTemplateDirective {
|
|
@@ -5,9 +5,9 @@
|
|
|
5
5
|
import { Directive, TemplateRef, Optional } from '@angular/core';
|
|
6
6
|
import * as i0 from "@angular/core";
|
|
7
7
|
/**
|
|
8
|
-
* Represents the column cell template of the Grid
|
|
9
|
-
* Helps to customize the content of the cells. To define the cell template, nest an `<ng-template>` tag
|
|
10
|
-
*
|
|
8
|
+
* Represents the column cell template of the Grid.
|
|
9
|
+
* Helps to customize the content of the cells. To define the cell template, nest an `<ng-template>` tag with the
|
|
10
|
+
* `kendoGridCellTemplate` directive inside a `<kendo-grid-column>` tag [see example](slug:templates_columns_grid#toc-cell-template).
|
|
11
11
|
*
|
|
12
12
|
* The template context is set to the current data item and the following additional fields are passed:
|
|
13
13
|
* - `columnIndex`—The current column index. Use it as an alias for a template variable by utilizing the `let-columnIndex="columnIndex"` syntax.
|
|
@@ -16,38 +16,14 @@ import * as i0 from "@angular/core";
|
|
|
16
16
|
* - `column`—The current column instance. Use it as an alias for a template variable by utilizing the `let-column="column"` syntax.
|
|
17
17
|
*
|
|
18
18
|
* @example
|
|
19
|
-
* ```
|
|
20
|
-
*
|
|
21
|
-
*
|
|
22
|
-
*
|
|
23
|
-
*
|
|
24
|
-
*
|
|
25
|
-
*
|
|
26
|
-
*
|
|
27
|
-
* Data Row #: {{rowIndex}} /
|
|
28
|
-
* <strong>{{dataItem.ProductName}}</strong>
|
|
29
|
-
* ({{dataItem.Discontinued ? "discontinued" : "active"}})
|
|
30
|
-
* </ng-template>
|
|
31
|
-
* </kendo-grid-column>
|
|
32
|
-
* </kendo-grid>
|
|
33
|
-
* `
|
|
34
|
-
* })
|
|
35
|
-
*
|
|
36
|
-
* class AppComponent {
|
|
37
|
-
* public gridData = [{
|
|
38
|
-
* "ProductID": 1,
|
|
39
|
-
* "ProductName": "Chai",
|
|
40
|
-
* "UnitPrice": 18.0000,
|
|
41
|
-
* "Discontinued": false
|
|
42
|
-
* }, {
|
|
43
|
-
* "ProductID": 2,
|
|
44
|
-
* "ProductName": "Chang",
|
|
45
|
-
* "UnitPrice": 19.0000,
|
|
46
|
-
* "Discontinued": true
|
|
47
|
-
* }
|
|
48
|
-
* ];
|
|
49
|
-
* }
|
|
50
|
-
*
|
|
19
|
+
* ```html
|
|
20
|
+
* <kendo-grid [data]="gridData" ...>
|
|
21
|
+
* <kendo-grid-column field="ProductName">
|
|
22
|
+
* <ng-template kendoGridCellTemplate let-dataItem let-rowIndex="rowIndex" let-column="column">
|
|
23
|
+
* Data Row: {{rowIndex}}
|
|
24
|
+
* </ng-template>
|
|
25
|
+
* </kendo-grid-column>
|
|
26
|
+
* </kendo-grid>
|
|
51
27
|
* ```
|
|
52
28
|
*/
|
|
53
29
|
export class CellTemplateDirective {
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
*-------------------------------------------------------------------------------------------*/
|
|
5
5
|
import { Component, HostBinding, Input, Inject, Optional, TemplateRef } from '@angular/core';
|
|
6
6
|
import { EditService } from '../editing/edit.service';
|
|
7
|
-
import { isSpanColumn, isCheckboxColumn } from '../columns/column-base';
|
|
7
|
+
import { isSpanColumn, isCheckboxColumn, isRowReorderColumn } from '../columns/column-base';
|
|
8
8
|
import { CommandColumnComponent } from '../columns/command-column.component';
|
|
9
9
|
import { isColumnComponent } from '../columns/column.component';
|
|
10
10
|
import { columnsToRender } from "../columns/column-common";
|
|
@@ -12,17 +12,19 @@ import { isPresent, isNullOrEmptyString, extractFormat } from '../utils';
|
|
|
12
12
|
import { CELL_CONTEXT } from './common/cell-context';
|
|
13
13
|
import { IdService } from '../common/id.service';
|
|
14
14
|
import { LocalizationService } from '@progress/kendo-angular-l10n';
|
|
15
|
+
import { reorderIcon } from '@progress/kendo-svg-icons';
|
|
15
16
|
import * as i0 from "@angular/core";
|
|
16
17
|
import * as i1 from "../editing/edit.service";
|
|
17
18
|
import * as i2 from "../common/id.service";
|
|
18
19
|
import * as i3 from "@progress/kendo-angular-l10n";
|
|
19
|
-
import * as i4 from "@progress/kendo-angular-
|
|
20
|
-
import * as i5 from "@progress/kendo-angular-
|
|
21
|
-
import * as i6 from "@angular
|
|
22
|
-
import * as i7 from "
|
|
23
|
-
import * as i8 from "../
|
|
24
|
-
import * as i9 from "
|
|
25
|
-
import * as i10 from "
|
|
20
|
+
import * as i4 from "@progress/kendo-angular-icons";
|
|
21
|
+
import * as i5 from "@progress/kendo-angular-inputs";
|
|
22
|
+
import * as i6 from "@progress/kendo-angular-dateinputs";
|
|
23
|
+
import * as i7 from "@angular/common";
|
|
24
|
+
import * as i8 from "../navigation/focusable.directive";
|
|
25
|
+
import * as i9 from "../selection/selection-checkbox.directive";
|
|
26
|
+
import * as i10 from "@angular/forms";
|
|
27
|
+
import * as i11 from "./common/field-accessor.pipe";
|
|
26
28
|
/**
|
|
27
29
|
* @hidden
|
|
28
30
|
*/
|
|
@@ -35,12 +37,19 @@ export class CellComponent {
|
|
|
35
37
|
this.isNew = false;
|
|
36
38
|
this.isLoading = false;
|
|
37
39
|
this.isVirtual = false;
|
|
40
|
+
this.reorderIcon = reorderIcon;
|
|
38
41
|
this._templateContext = {};
|
|
39
42
|
this._editTemplateContext = {};
|
|
40
43
|
}
|
|
41
44
|
get commandCellClass() {
|
|
42
45
|
return this.isCommand(this.column);
|
|
43
46
|
}
|
|
47
|
+
get dragHandleCellClass() {
|
|
48
|
+
return isRowReorderColumn(this.column);
|
|
49
|
+
}
|
|
50
|
+
get dragRowHandleLabel() {
|
|
51
|
+
return isRowReorderColumn(this.column) ? this.localizationService.get('dragRowHandleLabel') : undefined;
|
|
52
|
+
}
|
|
44
53
|
set rowIndex(index) {
|
|
45
54
|
this._rowIndex = index;
|
|
46
55
|
this.updateCellContext();
|
|
@@ -97,6 +106,9 @@ export class CellComponent {
|
|
|
97
106
|
get childColumns() {
|
|
98
107
|
return columnsToRender([this.column]);
|
|
99
108
|
}
|
|
109
|
+
get isRowReorderColumn() {
|
|
110
|
+
return isRowReorderColumn(this.column) && !this.column.templateRef;
|
|
111
|
+
}
|
|
100
112
|
get isColumnEditable() {
|
|
101
113
|
if (!this.column || this.isCommand(this.column)) {
|
|
102
114
|
return false;
|
|
@@ -143,7 +155,7 @@ export class CellComponent {
|
|
|
143
155
|
}
|
|
144
156
|
}
|
|
145
157
|
CellComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: CellComponent, deps: [{ token: i1.EditService }, { token: i2.IdService }, { token: i3.LocalizationService }, { token: CELL_CONTEXT, optional: true }], target: i0.ɵɵFactoryTarget.Component });
|
|
146
|
-
CellComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.12", type: CellComponent, selector: "[kendoGridCell]", inputs: { column: "column", columnIndex: "columnIndex", isNew: "isNew", isLoading: "isLoading", isVirtual: "isVirtual", loadingTemplate: "loadingTemplate", rowIndex: "rowIndex", dataItem: "dataItem" }, host: { properties: { "class.k-command-cell": "this.commandCellClass" } }, usesOnChanges: true, ngImport: i0, template: `
|
|
158
|
+
CellComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.12", type: CellComponent, selector: "[kendoGridCell]", inputs: { column: "column", columnIndex: "columnIndex", isNew: "isNew", isLoading: "isLoading", isVirtual: "isVirtual", loadingTemplate: "loadingTemplate", rowIndex: "rowIndex", dataItem: "dataItem" }, host: { properties: { "class.k-command-cell": "this.commandCellClass", "class.k-drag-cell": "this.dragHandleCellClass", "class.k-touch-action-none": "this.dragHandleCellClass", "attr.aria-label": "this.dragRowHandleLabel" } }, usesOnChanges: true, ngImport: i0, template: `
|
|
147
159
|
<ng-container [ngSwitch]="isEdited">
|
|
148
160
|
<ng-container *ngSwitchCase="false">
|
|
149
161
|
<ng-container *ngIf="!showLoading; else loading">
|
|
@@ -164,6 +176,12 @@ CellComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version:
|
|
|
164
176
|
[attr.id]="selectionCheckboxId"
|
|
165
177
|
[attr.aria-label]="selectionCheckboxLabel" />
|
|
166
178
|
</ng-container>
|
|
179
|
+
<ng-container *ngIf="isRowReorderColumn && !isNew">
|
|
180
|
+
<kendo-icon-wrapper
|
|
181
|
+
name="reorder"
|
|
182
|
+
[svgIcon]="reorderIcon">
|
|
183
|
+
</kendo-icon-wrapper>
|
|
184
|
+
</ng-container>
|
|
167
185
|
</ng-container>
|
|
168
186
|
<ng-template #loading>
|
|
169
187
|
<ng-template
|
|
@@ -213,7 +231,7 @@ CellComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version:
|
|
|
213
231
|
</ng-container>
|
|
214
232
|
</ng-container>
|
|
215
233
|
</ng-container>
|
|
216
|
-
`, isInline: true, components: [{ type: i4.NumericTextBoxComponent, selector: "kendo-numerictextbox", inputs: ["focusableId", "disabled", "readonly", "title", "autoCorrect", "format", "max", "min", "decimals", "placeholder", "step", "spinners", "rangeValidation", "tabindex", "tabIndex", "changeValueOnScroll", "selectOnFocus", "value", "maxlength", "size", "rounded", "fillMode"], outputs: ["valueChange", "focus", "blur"], exportAs: ["kendoNumericTextBox"] }, { type:
|
|
234
|
+
`, isInline: true, components: [{ type: i4.IconWrapperComponent, selector: "kendo-icon-wrapper", inputs: ["name", "svgIcon", "innerCssClass", "customFontClass"], exportAs: ["kendoIconWrapper"] }, { type: i5.NumericTextBoxComponent, selector: "kendo-numerictextbox", inputs: ["focusableId", "disabled", "readonly", "title", "autoCorrect", "format", "max", "min", "decimals", "placeholder", "step", "spinners", "rangeValidation", "tabindex", "tabIndex", "changeValueOnScroll", "selectOnFocus", "value", "maxlength", "size", "rounded", "fillMode"], outputs: ["valueChange", "focus", "blur"], exportAs: ["kendoNumericTextBox"] }, { type: i6.DatePickerComponent, selector: "kendo-datepicker", inputs: ["focusableId", "cellTemplate", "monthCellTemplate", "yearCellTemplate", "decadeCellTemplate", "centuryCellTemplate", "weekNumberTemplate", "headerTitleTemplate", "navigationItemTemplate", "activeView", "bottomView", "topView", "calendarType", "animateCalendarNavigation", "disabled", "readonly", "readOnlyInput", "popupSettings", "navigation", "min", "max", "incompleteDateValidation", "focusedDate", "value", "format", "twoDigitYearMax", "formatPlaceholder", "placeholder", "tabindex", "tabIndex", "disabledDates", "title", "subtitle", "rangeValidation", "disabledDatesValidation", "weekNumber", "size", "rounded", "fillMode", "adaptiveMode"], outputs: ["valueChange", "focus", "blur", "open", "close"], exportAs: ["kendo-datepicker"] }], directives: [{ type: i7.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { type: i7.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { type: i7.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i7.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }, { type: i7.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i8.FocusableDirective, selector: "[kendoGridFocusable],\n [kendoGridEditCommand],\n [kendoGridRemoveCommand],\n [kendoGridSaveCommand],\n [kendoGridCancelCommand],\n [kendoGridSelectionCheckbox]\n ", inputs: ["kendoGridFocusable"] }, { type: i9.SelectionCheckboxDirective, selector: "[kendoGridSelectionCheckbox]", inputs: ["kendoGridSelectionCheckbox"] }, { type: i10.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i10.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { type: i10.CheckboxControlValueAccessor, selector: "input[type=checkbox][formControlName],input[type=checkbox][formControl],input[type=checkbox][ngModel]" }, { type: i7.NgSwitchDefault, selector: "[ngSwitchDefault]" }, { type: i10.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }], pipes: { "valueOf": i11.FieldAccessorPipe } });
|
|
217
235
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: CellComponent, decorators: [{
|
|
218
236
|
type: Component,
|
|
219
237
|
args: [{
|
|
@@ -239,6 +257,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
239
257
|
[attr.id]="selectionCheckboxId"
|
|
240
258
|
[attr.aria-label]="selectionCheckboxLabel" />
|
|
241
259
|
</ng-container>
|
|
260
|
+
<ng-container *ngIf="isRowReorderColumn && !isNew">
|
|
261
|
+
<kendo-icon-wrapper
|
|
262
|
+
name="reorder"
|
|
263
|
+
[svgIcon]="reorderIcon">
|
|
264
|
+
</kendo-icon-wrapper>
|
|
265
|
+
</ng-container>
|
|
242
266
|
</ng-container>
|
|
243
267
|
<ng-template #loading>
|
|
244
268
|
<ng-template
|
|
@@ -298,6 +322,15 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
298
322
|
}] }]; }, propDecorators: { commandCellClass: [{
|
|
299
323
|
type: HostBinding,
|
|
300
324
|
args: ['class.k-command-cell']
|
|
325
|
+
}], dragHandleCellClass: [{
|
|
326
|
+
type: HostBinding,
|
|
327
|
+
args: ['class.k-drag-cell']
|
|
328
|
+
}, {
|
|
329
|
+
type: HostBinding,
|
|
330
|
+
args: ['class.k-touch-action-none']
|
|
331
|
+
}], dragRowHandleLabel: [{
|
|
332
|
+
type: HostBinding,
|
|
333
|
+
args: ['attr.aria-label']
|
|
301
334
|
}], column: [{
|
|
302
335
|
type: Input
|
|
303
336
|
}], columnIndex: [{
|
|
@@ -9,64 +9,16 @@ import * as i0 from "@angular/core";
|
|
|
9
9
|
* To define the detail template, nest an `<ng-template>` tag with the `kendoGridDetailTemplate` directive inside a `<kendo-grid>` tag.
|
|
10
10
|
*
|
|
11
11
|
* @example
|
|
12
|
-
* ```
|
|
13
|
-
*
|
|
14
|
-
*
|
|
15
|
-
*
|
|
16
|
-
*
|
|
17
|
-
*
|
|
18
|
-
*
|
|
19
|
-
*
|
|
20
|
-
*
|
|
21
|
-
*
|
|
22
|
-
* <kendo-grid-column field="ProductID"></kendo-grid-column>
|
|
23
|
-
* <kendo-grid-column field="ProductName"></kendo-grid-column>
|
|
24
|
-
* <kendo-grid-column field="UnitPrice"></kendo-grid-column>
|
|
25
|
-
* <ng-template kendoGridDetailTemplate let-dataItem>
|
|
26
|
-
* <div *ngIf="dataItem.Category">
|
|
27
|
-
* <header>{{dataItem.Category?.CategoryName}}</header>
|
|
28
|
-
* <span>{{dataItem.Category?.Description}}</span>
|
|
29
|
-
* </div>
|
|
30
|
-
* </ng-template>
|
|
31
|
-
* </kendo-grid>
|
|
32
|
-
* `
|
|
33
|
-
* })
|
|
34
|
-
*
|
|
35
|
-
* class AppComponent {
|
|
36
|
-
* public data = [{
|
|
37
|
-
* "ProductID": 1,
|
|
38
|
-
* "ProductName": "Chai",
|
|
39
|
-
* "UnitPrice": 18.0000,
|
|
40
|
-
* "Discontinued": false,
|
|
41
|
-
* "Category": {
|
|
42
|
-
* "CategoryID": 1,
|
|
43
|
-
* "CategoryName": "Beverages",
|
|
44
|
-
* "Description": "Soft drinks, coffees, teas, beers, and ales"
|
|
45
|
-
* }
|
|
46
|
-
* }, {
|
|
47
|
-
* "ProductID": 2,
|
|
48
|
-
* "ProductName": "Chang",
|
|
49
|
-
* "UnitPrice": 19.0000,
|
|
50
|
-
* "Discontinued": false,
|
|
51
|
-
* "Category": {
|
|
52
|
-
* "CategoryID": 1,
|
|
53
|
-
* "CategoryName": "Beverages",
|
|
54
|
-
* "Description": "Soft drinks, coffees, teas, beers, and ales"
|
|
55
|
-
* }
|
|
56
|
-
* }, {
|
|
57
|
-
* "ProductID": 3,
|
|
58
|
-
* "ProductName": "Aniseed Syrup",
|
|
59
|
-
* "UnitPrice": 10.0000,
|
|
60
|
-
* "Discontinued": false,
|
|
61
|
-
* "Category": {
|
|
62
|
-
* "CategoryID": 2,
|
|
63
|
-
* "CategoryName": "Condiments",
|
|
64
|
-
* "Description": "Sweet and savory sauces, relishes, spreads, and seasonings"
|
|
65
|
-
* }
|
|
66
|
-
* }];
|
|
67
|
-
*
|
|
68
|
-
* }
|
|
69
|
-
*
|
|
12
|
+
* ```html
|
|
13
|
+
* <kendo-grid [data]="data" selectable="true" style="height: 160px">
|
|
14
|
+
* <kendo-grid-column field="ProductName"></kendo-grid-column>
|
|
15
|
+
* <ng-template kendoGridDetailTemplate let-dataItem>
|
|
16
|
+
* <div *ngIf="dataItem.Category">
|
|
17
|
+
* <header>{{dataItem.Category?.CategoryName}}</header>
|
|
18
|
+
* span>{{dataItem.Category?.Description}}</span>
|
|
19
|
+
* </div>
|
|
20
|
+
* </ng-template>
|
|
21
|
+
* </kendo-grid>
|
|
70
22
|
* ```
|
|
71
23
|
*
|
|
72
24
|
*/
|
|
@@ -11,7 +11,7 @@ import { isPresent, isString } from '../utils';
|
|
|
11
11
|
import * as i0 from "@angular/core";
|
|
12
12
|
import * as i1 from "../grid.component";
|
|
13
13
|
/**
|
|
14
|
-
* A directive which controls the expanded state of the master detail rows.
|
|
14
|
+
* A directive which controls the expanded state of the master detail rows. ([see example](slug:master_detail_expanded_state_grid#toc-built-in-directive))
|
|
15
15
|
*/
|
|
16
16
|
export class ExpandDetailsDirective {
|
|
17
17
|
constructor(grid) {
|
|
@@ -19,41 +19,14 @@ import * as i0 from "@angular/core";
|
|
|
19
19
|
* refer to the article on [aggregates]({% slug groupable_grid_with_aggregates %}).
|
|
20
20
|
*
|
|
21
21
|
* @example
|
|
22
|
-
* ```
|
|
23
|
-
*
|
|
24
|
-
*
|
|
25
|
-
*
|
|
26
|
-
*
|
|
27
|
-
*
|
|
28
|
-
*
|
|
29
|
-
*
|
|
30
|
-
* {{column.field}}({{columnIndex}})
|
|
31
|
-
* </ng-template>
|
|
32
|
-
* </kendo-grid-column>
|
|
33
|
-
* <kendo-grid-column field="UnitPrice">
|
|
34
|
-
* <ng-template kendoGridFooterTemplate let-column let-columnIndex="columnIndex">
|
|
35
|
-
* {{column.field}}({{columnIndex}})
|
|
36
|
-
* </ng-template>
|
|
37
|
-
* </kendo-grid-column>
|
|
38
|
-
* </kendo-grid>
|
|
39
|
-
* `
|
|
40
|
-
* })
|
|
41
|
-
*
|
|
42
|
-
* class AppComponent {
|
|
43
|
-
* public gridData = [{
|
|
44
|
-
* "ProductID": 1,
|
|
45
|
-
* "ProductName": "Chai",
|
|
46
|
-
* "UnitPrice": 18.0000,
|
|
47
|
-
* "Discontinued": false
|
|
48
|
-
* }, {
|
|
49
|
-
* "ProductID": 2,
|
|
50
|
-
* "ProductName": "Chang",
|
|
51
|
-
* "UnitPrice": 19.0000,
|
|
52
|
-
* "Discontinued": true
|
|
53
|
-
* }
|
|
54
|
-
* ];
|
|
55
|
-
* }
|
|
56
|
-
*
|
|
22
|
+
* ```html
|
|
23
|
+
* <kendo-grid [data]="gridData" scrollable="none">
|
|
24
|
+
* <kendo-grid-column field="ProductName">
|
|
25
|
+
* <ng-template kendoGridFooterTemplate let-column let-columnIndex="columnIndex">
|
|
26
|
+
* {{column.field}}({{columnIndex}})
|
|
27
|
+
* </ng-template>
|
|
28
|
+
* </kendo-grid-column>
|
|
29
|
+
* </kendo-grid>
|
|
57
30
|
* ```
|
|
58
31
|
*/
|
|
59
32
|
export class FooterTemplateDirective {
|
|
@@ -9,48 +9,21 @@ import * as i0 from "@angular/core";
|
|
|
9
9
|
* ([more information and example]({% slug templates_columns_grid %}#toc-header-template)).
|
|
10
10
|
* Helps to customize the table header cell for the column.
|
|
11
11
|
* To define a header template, nest an `<ng-template>` tag with the
|
|
12
|
-
*
|
|
12
|
+
* `kendoGridHeaderTemplate` directive inside the `<kendo-grid-column>` tag.
|
|
13
13
|
*
|
|
14
14
|
* The template context is set to the current column and then the following additional fields are passed:
|
|
15
15
|
* * `column`—Defines an instance of the [ColumnComponent]({% slug api_grid_columncomponent %}) option.
|
|
16
16
|
* * `columnIndex`—Defines the current column index.
|
|
17
17
|
*
|
|
18
18
|
* @example
|
|
19
|
-
* ```
|
|
20
|
-
*
|
|
21
|
-
*
|
|
22
|
-
*
|
|
23
|
-
*
|
|
24
|
-
*
|
|
25
|
-
*
|
|
26
|
-
*
|
|
27
|
-
* {{column.field}}({{columnIndex}})
|
|
28
|
-
* </ng-template>
|
|
29
|
-
* </kendo-grid-column>
|
|
30
|
-
* <kendo-grid-column field="UnitPrice">
|
|
31
|
-
* <ng-template kendoGridHeaderTemplate let-column let-columnIndex="columnIndex">
|
|
32
|
-
* {{column.field}}({{columnIndex}})
|
|
33
|
-
* </ng-template>
|
|
34
|
-
* </kendo-grid-column>
|
|
35
|
-
* </kendo-grid>
|
|
36
|
-
* `
|
|
37
|
-
* })
|
|
38
|
-
*
|
|
39
|
-
* class AppComponent {
|
|
40
|
-
* public gridData = [{
|
|
41
|
-
* "ProductID": 1,
|
|
42
|
-
* "ProductName": "Chai",
|
|
43
|
-
* "UnitPrice": 18.0000,
|
|
44
|
-
* "Discontinued": false
|
|
45
|
-
* }, {
|
|
46
|
-
* "ProductID": 2,
|
|
47
|
-
* "ProductName": "Chang",
|
|
48
|
-
* "UnitPrice": 19.0000,
|
|
49
|
-
* "Discontinued": true
|
|
50
|
-
* }
|
|
51
|
-
* ];
|
|
52
|
-
* }
|
|
53
|
-
*
|
|
19
|
+
* ```html
|
|
20
|
+
* <kendo-grid [data]="gridData">
|
|
21
|
+
* <kendo-grid-column field="ProductName">
|
|
22
|
+
* <ng-template kendoGridHeaderTemplate let-column let-columnIndex="columnIndex">
|
|
23
|
+
* {{column.field}}({{columnIndex}})
|
|
24
|
+
* </ng-template>
|
|
25
|
+
* </kendo-grid-column>
|
|
26
|
+
* </kendo-grid>
|
|
54
27
|
* ```
|
|
55
28
|
*/
|
|
56
29
|
export class HeaderTemplateDirective {
|
|
@@ -7,7 +7,7 @@ import * as i0 from "@angular/core";
|
|
|
7
7
|
/**
|
|
8
8
|
* Creates a loading template that overrides the default loading indicator of the Grid Component.
|
|
9
9
|
* To define a loading template, nest an `<ng-template>` tag with the `kendoGridLoadingTemplate` directive inside the `<kendo-grid>` tag
|
|
10
|
-
* [see example](
|
|
10
|
+
* ([see example](slug:loadingtemplate_grid)).
|
|
11
11
|
*/
|
|
12
12
|
export class LoadingTemplateDirective {
|
|
13
13
|
constructor(templateRef) {
|
|
@@ -6,66 +6,19 @@ import { Directive, TemplateRef, Optional } from '@angular/core';
|
|
|
6
6
|
import * as i0 from "@angular/core";
|
|
7
7
|
/**
|
|
8
8
|
* Represents the no-records template of the Grid. Provides an option to customize the
|
|
9
|
-
* appearance of the item that is displayed when no data is present.
|
|
10
|
-
* nest an `<ng-template>` tag with the `kendoGridNoRecordsTemplate`
|
|
11
|
-
*
|
|
12
|
-
* > When the locked columns of the Grid are in use, the template is displayed in the non-locked part of the content.
|
|
9
|
+
* appearance of the item that is displayed when no data is present.
|
|
10
|
+
* To define the no-records template, nest an `<ng-template>` tag with the `kendoGridNoRecordsTemplate`
|
|
11
|
+
* directive inside `<kendo-grid>` [see example](slug:norecordtemplate_grid).
|
|
13
12
|
*
|
|
14
13
|
* @example
|
|
15
|
-
* ```
|
|
16
|
-
*
|
|
17
|
-
*
|
|
18
|
-
*
|
|
19
|
-
* template
|
|
20
|
-
*
|
|
21
|
-
*
|
|
22
|
-
*
|
|
23
|
-
* <kendo-grid-column field="UnitPrice"></kendo-grid-column>
|
|
24
|
-
* <ng-template kendoGridNoRecordsTemplate>
|
|
25
|
-
* There are not products. <a href="#" (click)="refresh()">Click here to refresh</a>.
|
|
26
|
-
* </ng-template>
|
|
27
|
-
* </kendo-grid>
|
|
28
|
-
* `
|
|
29
|
-
* })
|
|
30
|
-
*
|
|
31
|
-
* class AppComponent {
|
|
32
|
-
* public data = [];
|
|
33
|
-
* public refresh() {
|
|
34
|
-
* this.data = [{
|
|
35
|
-
* "ProductID": 1,
|
|
36
|
-
* "ProductName": "Chai",
|
|
37
|
-
* "UnitPrice": 18.0000,
|
|
38
|
-
* "Discontinued": false,
|
|
39
|
-
* "Category": {
|
|
40
|
-
* "CategoryID": 1,
|
|
41
|
-
* "CategoryName": "Beverages",
|
|
42
|
-
* "Description": "Soft drinks, coffees, teas, beers, and ales"
|
|
43
|
-
* }
|
|
44
|
-
* }, {
|
|
45
|
-
* "ProductID": 2,
|
|
46
|
-
* "ProductName": "Chang",
|
|
47
|
-
* "UnitPrice": 19.0000,
|
|
48
|
-
* "Discontinued": false,
|
|
49
|
-
* "Category": {
|
|
50
|
-
* "CategoryID": 1,
|
|
51
|
-
* "CategoryName": "Beverages",
|
|
52
|
-
* "Description": "Soft drinks, coffees, teas, beers, and ales"
|
|
53
|
-
* }
|
|
54
|
-
* }, {
|
|
55
|
-
* "ProductID": 3,
|
|
56
|
-
* "ProductName": "Aniseed Syrup",
|
|
57
|
-
* "UnitPrice": 10.0000,
|
|
58
|
-
* "Discontinued": false,
|
|
59
|
-
* "Category": {
|
|
60
|
-
* "CategoryID": 2,
|
|
61
|
-
* "CategoryName": "Condiments",
|
|
62
|
-
* "Description": "Sweet and savory sauces, relishes, spreads, and seasonings"
|
|
63
|
-
* }
|
|
64
|
-
* }];
|
|
65
|
-
*
|
|
66
|
-
* }
|
|
67
|
-
* }
|
|
68
|
-
*
|
|
14
|
+
* ```html
|
|
15
|
+
* <kendo-grid [data]="data">
|
|
16
|
+
* <ng-template kendoGridNoRecordsTemplate>
|
|
17
|
+
* There are not products. <a href="#" (click)="refresh()">Click here to refresh</a>.
|
|
18
|
+
* </ng-template>
|
|
19
|
+
* <kendo-grid-column field="ProductID"></kendo-grid-column>
|
|
20
|
+
* <kendo-grid-column field="ProductName"></kendo-grid-column>
|
|
21
|
+
* </kendo-grid>
|
|
69
22
|
* ```
|
|
70
23
|
*/
|
|
71
24
|
export class NoRecordsTemplateDirective {
|
|
@@ -2,4 +2,21 @@
|
|
|
2
2
|
* Copyright © 2023 Progress Software Corporation. All rights reserved.
|
|
3
3
|
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
4
|
*-------------------------------------------------------------------------------------------*/
|
|
5
|
+
/**
|
|
6
|
+
* Defines the settings for `position` property of the the Grid Toolbar Template. [See example](slug:toolbartemplate_grid#toc-setting-the-toolbar-position)
|
|
7
|
+
*
|
|
8
|
+
* The possible values are:
|
|
9
|
+
* * `top`—Displays the Toolbar a the top of the Grid.
|
|
10
|
+
* * `bottom`—Displays the Toolbar at the bottom of the Grid.
|
|
11
|
+
* * `both`—Displays the Toolbar at the top and bottom of the Grid.
|
|
12
|
+
*
|
|
13
|
+
* @example
|
|
14
|
+
* ```html
|
|
15
|
+
* <kendo-grid >
|
|
16
|
+
* <ng-template kendoGridToolbarTemplate position="bottom" let-position="position">
|
|
17
|
+
* <button (click)="onClick()">Custom action</button>
|
|
18
|
+
* </ng-template>
|
|
19
|
+
* </kendo-grid>
|
|
20
|
+
* ```
|
|
21
|
+
*/
|
|
5
22
|
export {};
|