@progress/kendo-angular-grid 12.2.0-develop.6 → 13.0.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/column-menu/column-chooser.component.d.ts +4 -4
- package/column-menu/column-menu-autosize-all.component.d.ts +6 -7
- package/column-menu/column-menu-autosize.component.d.ts +1 -3
- package/column-menu/column-menu-chooser.component.d.ts +7 -6
- package/column-menu/column-menu-filter.component.d.ts +7 -6
- package/column-menu/column-menu-lock.component.d.ts +7 -6
- package/column-menu/column-menu-position.component.d.ts +7 -6
- package/column-menu/column-menu-settings.interface.d.ts +5 -0
- package/column-menu/column-menu-sort.component.d.ts +7 -6
- package/column-menu/column-menu-stick.component.d.ts +3 -3
- package/column-menu/column-menu.component.d.ts +39 -5
- package/column-menu/column-menu.module.d.ts +2 -1
- package/column-resizing/column-handle.directive.d.ts +3 -3
- package/common/provider.service.d.ts +3 -1
- package/common/single-popup.service.d.ts +3 -3
- package/editing/add-command.directive.d.ts +2 -2
- package/editing/cancel-command.directive.d.ts +2 -2
- package/editing/edit-command.directive.d.ts +2 -2
- package/editing/remove-command.directive.d.ts +2 -2
- package/editing/save-command.directive.d.ts +2 -2
- package/esm2020/column-menu/column-chooser.component.mjs +17 -17
- package/esm2020/column-menu/column-menu-autosize-all.component.mjs +19 -21
- package/esm2020/column-menu/column-menu-autosize.component.mjs +9 -12
- package/esm2020/column-menu/column-menu-chooser.component.mjs +16 -15
- package/esm2020/column-menu/column-menu-filter.component.mjs +12 -11
- package/esm2020/column-menu/column-menu-lock.component.mjs +11 -10
- package/esm2020/column-menu/column-menu-position.component.mjs +12 -11
- package/esm2020/column-menu/column-menu-sort.component.mjs +14 -13
- package/esm2020/column-menu/column-menu-stick.component.mjs +7 -7
- package/esm2020/column-menu/column-menu.component.mjs +257 -17
- package/esm2020/column-menu/column-menu.module.mjs +4 -3
- package/esm2020/column-resizing/column-handle.directive.mjs +7 -7
- package/esm2020/common/provider.service.mjs +6 -3
- package/esm2020/common/single-popup.service.mjs +8 -8
- package/esm2020/editing/add-command.directive.mjs +6 -6
- package/esm2020/editing/cancel-command.directive.mjs +6 -6
- package/esm2020/editing/edit-command.directive.mjs +6 -6
- package/esm2020/editing/remove-command.directive.mjs +6 -6
- package/esm2020/editing/save-command.directive.mjs +6 -6
- package/esm2020/excel/excel-command.directive.mjs +6 -6
- package/esm2020/excel/excel.component.mjs +7 -7
- package/esm2020/filtering/boolean-filter.component.mjs +13 -13
- package/esm2020/filtering/cell/autocomplete-filter-cell.component.mjs +7 -7
- package/esm2020/filtering/cell/boolean-filter-cell.component.mjs +7 -7
- package/esm2020/filtering/cell/date-filter-cell.component.mjs +9 -9
- package/esm2020/filtering/cell/filter-cell-operators.component.mjs +7 -7
- package/esm2020/filtering/cell/numeric-filter-cell.component.mjs +10 -10
- package/esm2020/filtering/cell/string-filter-cell.component.mjs +7 -7
- package/esm2020/filtering/date-filter.component.mjs +9 -9
- package/esm2020/filtering/filter-row.component.mjs +7 -7
- package/esm2020/filtering/menu/boolean-filter-menu.component.mjs +10 -8
- package/esm2020/filtering/menu/date-filter-menu-input.component.mjs +8 -8
- package/esm2020/filtering/menu/date-filter-menu.component.mjs +9 -9
- package/esm2020/filtering/menu/filter-menu-container.component.mjs +9 -9
- package/esm2020/filtering/menu/filter-menu-input-wrapper.component.mjs +10 -8
- package/esm2020/filtering/menu/filter-menu.component.mjs +7 -7
- package/esm2020/filtering/menu/menu-tabbing.service.mjs +1 -0
- package/esm2020/filtering/menu/numeric-filter-menu-input.component.mjs +8 -8
- package/esm2020/filtering/menu/numeric-filter-menu.component.mjs +9 -9
- package/esm2020/filtering/menu/string-filter-menu-input.component.mjs +7 -7
- package/esm2020/filtering/menu/string-filter-menu.component.mjs +9 -9
- package/esm2020/filtering/numeric-filter.component.mjs +9 -9
- package/esm2020/filtering/operators/after-eq-filter-operator.component.mjs +5 -5
- package/esm2020/filtering/operators/after-filter-operator.component.mjs +5 -5
- package/esm2020/filtering/operators/before-eq-filter-operator.component.mjs +5 -5
- package/esm2020/filtering/operators/before-filter-operator.component.mjs +5 -5
- package/esm2020/filtering/operators/contains-filter-operator.component.mjs +5 -5
- package/esm2020/filtering/operators/ends-with-filter-operator.component.mjs +5 -5
- package/esm2020/filtering/operators/eq-filter-operator.component.mjs +5 -5
- package/esm2020/filtering/operators/filter-operator.base.mjs +9 -9
- package/esm2020/filtering/operators/gt-filter-operator.component.mjs +5 -5
- package/esm2020/filtering/operators/gte-filter-operator.component.mjs +5 -5
- package/esm2020/filtering/operators/is-empty-filter-operator.component.mjs +5 -5
- package/esm2020/filtering/operators/is-not-empty-filter-operator.component.mjs +5 -5
- package/esm2020/filtering/operators/is-not-null-filter-operator.component.mjs +5 -5
- package/esm2020/filtering/operators/isnull-filter-operator.component.mjs +5 -5
- package/esm2020/filtering/operators/lt-filter-operator.component.mjs +5 -5
- package/esm2020/filtering/operators/lte-filter-operator.component.mjs +5 -5
- package/esm2020/filtering/operators/neq-filter-operator.component.mjs +5 -5
- package/esm2020/filtering/operators/not-contains-filter-operator.component.mjs +5 -5
- package/esm2020/filtering/operators/starts-with-filter-operator.component.mjs +5 -5
- package/esm2020/filtering/string-filter.component.mjs +8 -8
- package/esm2020/grid.component.mjs +18 -0
- package/esm2020/grouping/group-header.component.mjs +7 -7
- package/esm2020/grouping/group-panel.component.mjs +10 -10
- package/esm2020/localization/messages.mjs +7 -1
- package/esm2020/navigation/navigation.service.mjs +8 -8
- package/esm2020/package-metadata.mjs +2 -2
- package/esm2020/pager/pager-element.component.mjs +8 -8
- package/esm2020/pager/pager-info.component.mjs +6 -6
- package/esm2020/pager/pager-input.component.mjs +6 -6
- package/esm2020/pager/pager-next-buttons.component.mjs +6 -6
- package/esm2020/pager/pager-numeric-buttons.component.mjs +6 -6
- package/esm2020/pager/pager-page-sizes.component.mjs +6 -6
- package/esm2020/pager/pager-prev-buttons.component.mjs +6 -6
- package/esm2020/pager/pager.component.mjs +7 -7
- package/esm2020/pdf/pdf-command.directive.mjs +6 -6
- package/esm2020/rendering/cell.component.mjs +8 -8
- package/esm2020/rendering/common/loading.component.mjs +7 -7
- package/esm2020/rendering/header/header.component.mjs +27 -30
- package/esm2020/rendering/list.component.mjs +7 -7
- package/esm2020/rendering/table-body.component.mjs +11 -11
- package/excel/excel-command.directive.d.ts +2 -2
- package/excel/excel.component.d.ts +3 -3
- package/fesm2015/progress-kendo-angular-grid.mjs +778 -504
- package/fesm2020/progress-kendo-angular-grid.mjs +775 -504
- package/filtering/base-filter-cell.component.d.ts +1 -1
- package/filtering/boolean-filter.component.d.ts +3 -3
- package/filtering/cell/autocomplete-filter-cell.component.d.ts +3 -3
- package/filtering/cell/boolean-filter-cell.component.d.ts +2 -2
- package/filtering/cell/date-filter-cell.component.d.ts +3 -3
- package/filtering/cell/filter-cell-operators.component.d.ts +3 -3
- package/filtering/cell/numeric-filter-cell.component.d.ts +4 -4
- package/filtering/cell/string-filter-cell.component.d.ts +2 -2
- package/filtering/date-filter.component.d.ts +3 -3
- package/filtering/filter-row.component.d.ts +3 -3
- package/filtering/menu/boolean-filter-menu.component.d.ts +2 -2
- package/filtering/menu/date-filter-menu-input.component.d.ts +3 -3
- package/filtering/menu/date-filter-menu.component.d.ts +2 -2
- package/filtering/menu/filter-menu-container.component.d.ts +3 -3
- package/filtering/menu/filter-menu-input-wrapper.component.d.ts +3 -3
- package/filtering/menu/filter-menu.component.d.ts +3 -3
- package/filtering/menu/menu-tabbing.service.d.ts +1 -0
- package/filtering/menu/numeric-filter-menu-input.component.d.ts +3 -3
- package/filtering/menu/numeric-filter-menu.component.d.ts +2 -2
- package/filtering/menu/string-filter-menu-input.component.d.ts +3 -3
- package/filtering/menu/string-filter-menu.component.d.ts +2 -2
- package/filtering/numeric-filter.component.d.ts +3 -3
- package/filtering/operators/after-eq-filter-operator.component.d.ts +2 -2
- package/filtering/operators/after-filter-operator.component.d.ts +2 -2
- package/filtering/operators/before-eq-filter-operator.component.d.ts +2 -2
- package/filtering/operators/before-filter-operator.component.d.ts +2 -2
- package/filtering/operators/contains-filter-operator.component.d.ts +2 -2
- package/filtering/operators/ends-with-filter-operator.component.d.ts +2 -2
- package/filtering/operators/eq-filter-operator.component.d.ts +2 -2
- package/filtering/operators/filter-operator.base.d.ts +3 -3
- package/filtering/operators/gt-filter-operator.component.d.ts +2 -2
- package/filtering/operators/gte-filter-operator.component.d.ts +2 -2
- package/filtering/operators/is-empty-filter-operator.component.d.ts +2 -2
- package/filtering/operators/is-not-empty-filter-operator.component.d.ts +2 -2
- package/filtering/operators/is-not-null-filter-operator.component.d.ts +2 -2
- package/filtering/operators/isnull-filter-operator.component.d.ts +2 -2
- package/filtering/operators/lt-filter-operator.component.d.ts +2 -2
- package/filtering/operators/lte-filter-operator.component.d.ts +2 -2
- package/filtering/operators/neq-filter-operator.component.d.ts +2 -2
- package/filtering/operators/not-contains-filter-operator.component.d.ts +2 -2
- package/filtering/operators/starts-with-filter-operator.component.d.ts +2 -2
- package/filtering/string-filter.component.d.ts +3 -3
- package/grouping/group-header.component.d.ts +3 -3
- package/grouping/group-panel.component.d.ts +3 -3
- package/localization/messages.d.ts +13 -1
- package/navigation/navigation.service.d.ts +3 -3
- package/package.json +16 -15
- package/pager/pager-element.component.d.ts +3 -3
- package/pager/pager-info.component.d.ts +2 -2
- package/pager/pager-input.component.d.ts +2 -2
- package/pager/pager-next-buttons.component.d.ts +2 -2
- package/pager/pager-numeric-buttons.component.d.ts +2 -2
- package/pager/pager-page-sizes.component.d.ts +2 -2
- package/pager/pager-prev-buttons.component.d.ts +2 -2
- package/pager/pager.component.d.ts +3 -3
- package/pdf/pdf-command.directive.d.ts +2 -2
- package/rendering/cell.component.d.ts +3 -3
- package/rendering/common/loading.component.d.ts +3 -3
- package/rendering/header/header.component.d.ts +1 -3
- package/rendering/list.component.d.ts +3 -3
- package/rendering/table-body.component.d.ts +3 -3
- package/schematics/ngAdd/index.js +5 -3
|
@@ -3,22 +3,23 @@
|
|
|
3
3
|
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
4
|
*-------------------------------------------------------------------------------------------*/
|
|
5
5
|
import { Component, Renderer2 } from '@angular/core';
|
|
6
|
-
import { LocalizationService } from "@progress/kendo-angular-l10n";
|
|
7
6
|
import { SortService } from '../common/sort.service';
|
|
8
7
|
import { normalize } from '../columns/sort-settings';
|
|
9
8
|
import { ColumnMenuItemBase } from './column-menu-item-base';
|
|
10
9
|
import { sortAscSmallIcon, sortDescSmallIcon } from '@progress/kendo-svg-icons';
|
|
10
|
+
import { ContextService } from '../common/provider.service';
|
|
11
11
|
import * as i0 from "@angular/core";
|
|
12
|
-
import * as i1 from "
|
|
12
|
+
import * as i1 from "../common/provider.service";
|
|
13
13
|
import * as i2 from "../common/sort.service";
|
|
14
14
|
import * as i3 from "./column-menu-item.component";
|
|
15
15
|
/**
|
|
16
16
|
* Represents the column-menu item for sorting Grid columns.
|
|
17
17
|
* [See example](slug:columnmenu_grid#toc-sort-item).
|
|
18
|
+
* The compoenent can be placed inside a [ColumnMenuTemplate]({% slug api_grid_columnmenutemplatedirective %}) directive.
|
|
19
|
+
* [See example](slug:columnmenu_grid#toc-customizing-the-content).
|
|
18
20
|
*
|
|
19
|
-
*
|
|
20
|
-
*
|
|
21
|
-
* the template to the service input of the `kendo-grid-columnmenu-sort` component. [See example](slug:columnmenu_grid#toc-customizing-the-content).
|
|
21
|
+
* You have to set the [ColumnMenuService]({% slug api_grid_columnmenuservice %}) that is passed by
|
|
22
|
+
* the template to the service input of the `kendo-grid-columnmenu-sort` component.
|
|
22
23
|
*
|
|
23
24
|
* @example
|
|
24
25
|
* ```html
|
|
@@ -31,9 +32,9 @@ import * as i3 from "./column-menu-item.component";
|
|
|
31
32
|
* ```
|
|
32
33
|
*/
|
|
33
34
|
export class ColumnMenuSortComponent extends ColumnMenuItemBase {
|
|
34
|
-
constructor(
|
|
35
|
+
constructor(ctx, sortService, renderer) {
|
|
35
36
|
super();
|
|
36
|
-
this.
|
|
37
|
+
this.ctx = ctx;
|
|
37
38
|
this.sortService = sortService;
|
|
38
39
|
this.renderer = renderer;
|
|
39
40
|
this.sortAscSmallIcon = sortAscSmallIcon;
|
|
@@ -70,17 +71,17 @@ export class ColumnMenuSortComponent extends ColumnMenuItemBase {
|
|
|
70
71
|
return [].concat(this.service.sort || []).find(s => s.field === this.service.column.field);
|
|
71
72
|
}
|
|
72
73
|
}
|
|
73
|
-
ColumnMenuSortComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: ColumnMenuSortComponent, deps: [{ token: i1.
|
|
74
|
+
ColumnMenuSortComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: ColumnMenuSortComponent, deps: [{ token: i1.ContextService }, { token: i2.SortService }, { token: i0.Renderer2 }], target: i0.ɵɵFactoryTarget.Component });
|
|
74
75
|
ColumnMenuSortComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.12", type: ColumnMenuSortComponent, selector: "kendo-grid-columnmenu-sort", usesInheritance: true, ngImport: i0, template: `
|
|
75
76
|
<kendo-grid-columnmenu-item
|
|
76
|
-
[text]="localization.get('sortAscending')"
|
|
77
|
+
[text]="ctx.localization.get('sortAscending')"
|
|
77
78
|
icon="sort-asc-small"
|
|
78
79
|
[svgIcon]="sortAscSmallIcon"
|
|
79
80
|
(itemClick)="toggleSort('asc')"
|
|
80
81
|
[selected]="sortedAsc">
|
|
81
82
|
</kendo-grid-columnmenu-item>
|
|
82
83
|
<kendo-grid-columnmenu-item
|
|
83
|
-
[text]="localization.get('sortDescending')"
|
|
84
|
+
[text]="ctx.localization.get('sortDescending')"
|
|
84
85
|
icon="sort-desc-small"
|
|
85
86
|
[svgIcon]="sortDescSmallIcon"
|
|
86
87
|
(itemClick)="toggleSort('desc')"
|
|
@@ -93,14 +94,14 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
93
94
|
selector: 'kendo-grid-columnmenu-sort',
|
|
94
95
|
template: `
|
|
95
96
|
<kendo-grid-columnmenu-item
|
|
96
|
-
[text]="localization.get('sortAscending')"
|
|
97
|
+
[text]="ctx.localization.get('sortAscending')"
|
|
97
98
|
icon="sort-asc-small"
|
|
98
99
|
[svgIcon]="sortAscSmallIcon"
|
|
99
100
|
(itemClick)="toggleSort('asc')"
|
|
100
101
|
[selected]="sortedAsc">
|
|
101
102
|
</kendo-grid-columnmenu-item>
|
|
102
103
|
<kendo-grid-columnmenu-item
|
|
103
|
-
[text]="localization.get('sortDescending')"
|
|
104
|
+
[text]="ctx.localization.get('sortDescending')"
|
|
104
105
|
icon="sort-desc-small"
|
|
105
106
|
[svgIcon]="sortDescSmallIcon"
|
|
106
107
|
(itemClick)="toggleSort('desc')"
|
|
@@ -108,4 +109,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
108
109
|
</kendo-grid-columnmenu-item>
|
|
109
110
|
`
|
|
110
111
|
}]
|
|
111
|
-
}], ctorParameters: function () { return [{ type: i1.
|
|
112
|
+
}], ctorParameters: function () { return [{ type: i1.ContextService }, { type: i2.SortService }, { type: i0.Renderer2 }]; } });
|
|
@@ -3,12 +3,12 @@
|
|
|
3
3
|
* Licensed under commercial license. See LICENSE.md in the project root for more information
|
|
4
4
|
*-------------------------------------------------------------------------------------------*/
|
|
5
5
|
import { Component, ChangeDetectorRef } from '@angular/core';
|
|
6
|
-
import { LocalizationService } from "@progress/kendo-angular-l10n";
|
|
7
6
|
import { stickIcon, unstickIcon } from '@progress/kendo-svg-icons';
|
|
8
7
|
import { ColumnInfoService } from '../common/column-info.service';
|
|
8
|
+
import { ContextService } from '../common/provider.service';
|
|
9
9
|
import { ColumnMenuItemBase } from './column-menu-item-base';
|
|
10
10
|
import * as i0 from "@angular/core";
|
|
11
|
-
import * as i1 from "
|
|
11
|
+
import * as i1 from "../common/provider.service";
|
|
12
12
|
import * as i2 from "../common/column-info.service";
|
|
13
13
|
import * as i3 from "./column-menu-item.component";
|
|
14
14
|
/**
|
|
@@ -31,16 +31,16 @@ import * as i3 from "./column-menu-item.component";
|
|
|
31
31
|
* ```
|
|
32
32
|
*/
|
|
33
33
|
export class ColumnMenuStickComponent extends ColumnMenuItemBase {
|
|
34
|
-
constructor(
|
|
34
|
+
constructor(ctx, columnInfoService, changeDetector) {
|
|
35
35
|
super();
|
|
36
|
-
this.
|
|
36
|
+
this.ctx = ctx;
|
|
37
37
|
this.columnInfoService = columnInfoService;
|
|
38
38
|
this.changeDetector = changeDetector;
|
|
39
39
|
this.stickIcon = stickIcon;
|
|
40
40
|
this.unstickIcon = unstickIcon;
|
|
41
41
|
}
|
|
42
42
|
get text() {
|
|
43
|
-
return this.localization.get(this.sticky ? 'unstick' : 'stick');
|
|
43
|
+
return this.ctx.localization.get(this.sticky ? 'unstick' : 'stick');
|
|
44
44
|
}
|
|
45
45
|
get icon() {
|
|
46
46
|
return this.sticky ? 'unstick' : 'stick';
|
|
@@ -80,7 +80,7 @@ export class ColumnMenuStickComponent extends ColumnMenuItemBase {
|
|
|
80
80
|
return this.service.column.sticky;
|
|
81
81
|
}
|
|
82
82
|
}
|
|
83
|
-
ColumnMenuStickComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: ColumnMenuStickComponent, deps: [{ token: i1.
|
|
83
|
+
ColumnMenuStickComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: ColumnMenuStickComponent, deps: [{ token: i1.ContextService }, { token: i2.ColumnInfoService }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
84
84
|
ColumnMenuStickComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.12", type: ColumnMenuStickComponent, selector: "kendo-grid-columnmenu-stick", usesInheritance: true, ngImport: i0, template: `
|
|
85
85
|
<kendo-grid-columnmenu-item
|
|
86
86
|
[text]="text"
|
|
@@ -104,4 +104,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
104
104
|
</kendo-grid-columnmenu-item>
|
|
105
105
|
`
|
|
106
106
|
}]
|
|
107
|
-
}], ctorParameters: function () { return [{ type: i1.
|
|
107
|
+
}], ctorParameters: function () { return [{ type: i1.ContextService }, { type: i2.ColumnInfoService }, { type: i0.ChangeDetectorRef }]; } });
|
|
@@ -4,8 +4,7 @@
|
|
|
4
4
|
*-------------------------------------------------------------------------------------------*/
|
|
5
5
|
import { MenuTabbingService } from './../filtering/menu/menu-tabbing.service';
|
|
6
6
|
import { NavigationService } from './../navigation/navigation.service';
|
|
7
|
-
import { Component, Input, TemplateRef, HostBinding, ElementRef, ViewChild, isDevMode } from '@angular/core';
|
|
8
|
-
import { LocalizationService } from "@progress/kendo-angular-l10n";
|
|
7
|
+
import { Component, Renderer2, Input, TemplateRef, HostBinding, ElementRef, ViewChild, isDevMode, ChangeDetectorRef } from '@angular/core';
|
|
9
8
|
import { SinglePopupService } from '../common/single-popup.service';
|
|
10
9
|
import { ColumnMenuService } from './column-menu.service';
|
|
11
10
|
import { filtersByField } from '../filtering/base-filter-cell.component';
|
|
@@ -13,13 +12,15 @@ import { hasFilter, hasSort, hasLock, hasStick, hasColumnChooser, hasAutoSizeCol
|
|
|
13
12
|
import { replaceMessagePlaceholder } from '../utils';
|
|
14
13
|
import { ContextService } from '../common/provider.service';
|
|
15
14
|
import { ColunnMenuErrorMessages } from '../common/error-messages';
|
|
16
|
-
import { moreVerticalIcon } from '@progress/kendo-svg-icons';
|
|
15
|
+
import { moreVerticalIcon, columnsIcon, moreHorizontalIcon, filterIcon } from '@progress/kendo-svg-icons';
|
|
16
|
+
import { TabStripComponent } from '@progress/kendo-angular-layout';
|
|
17
|
+
import { ColumnInfoService } from '../common/column-info.service';
|
|
17
18
|
import * as i0 from "@angular/core";
|
|
18
19
|
import * as i1 from "./../navigation/navigation.service";
|
|
19
20
|
import * as i2 from "../common/single-popup.service";
|
|
20
|
-
import * as i3 from "
|
|
21
|
-
import * as i4 from "
|
|
22
|
-
import * as i5 from "../common/
|
|
21
|
+
import * as i3 from "./column-menu.service";
|
|
22
|
+
import * as i4 from "../common/provider.service";
|
|
23
|
+
import * as i5 from "../common/column-info.service";
|
|
23
24
|
import * as i6 from "@progress/kendo-angular-icons";
|
|
24
25
|
import * as i7 from "./column-menu-container.component";
|
|
25
26
|
import * as i8 from "./column-menu-sort.component";
|
|
@@ -30,8 +31,11 @@ import * as i12 from "./column-menu-chooser.component";
|
|
|
30
31
|
import * as i13 from "./column-menu-autosize.component";
|
|
31
32
|
import * as i14 from "./column-menu-autosize-all.component";
|
|
32
33
|
import * as i15 from "./column-menu-filter.component";
|
|
33
|
-
import * as i16 from "@angular
|
|
34
|
-
import * as i17 from "
|
|
34
|
+
import * as i16 from "@progress/kendo-angular-layout";
|
|
35
|
+
import * as i17 from "../filtering/menu/filter-menu-container.component";
|
|
36
|
+
import * as i18 from "./column-list.component";
|
|
37
|
+
import * as i19 from "@angular/common";
|
|
38
|
+
import * as i20 from "./column-menu-item.directive";
|
|
35
39
|
const POPUP_CLASS = 'k-grid-columnmenu-popup';
|
|
36
40
|
/**
|
|
37
41
|
* Represents the [column menu](slug:columnmenu_grid#toc-customizing-the-position) component.
|
|
@@ -45,12 +49,14 @@ const POPUP_CLASS = 'k-grid-columnmenu-popup';
|
|
|
45
49
|
* </kendo-grid>
|
|
46
50
|
*/
|
|
47
51
|
export class ColumnMenuComponent {
|
|
48
|
-
constructor(navigationService, popupService,
|
|
52
|
+
constructor(navigationService, popupService, service, ctx, renderer, cdr, columnInfoService) {
|
|
49
53
|
this.navigationService = navigationService;
|
|
50
54
|
this.popupService = popupService;
|
|
51
|
-
this.localization = localization;
|
|
52
55
|
this.service = service;
|
|
53
56
|
this.ctx = ctx;
|
|
57
|
+
this.renderer = renderer;
|
|
58
|
+
this.cdr = cdr;
|
|
59
|
+
this.columnInfoService = columnInfoService;
|
|
54
60
|
/**
|
|
55
61
|
* @hidden
|
|
56
62
|
*/
|
|
@@ -67,6 +73,22 @@ export class ColumnMenuComponent {
|
|
|
67
73
|
* @hidden
|
|
68
74
|
*/
|
|
69
75
|
this.tabIndex = '-1';
|
|
76
|
+
/**
|
|
77
|
+
* @hidden
|
|
78
|
+
*/
|
|
79
|
+
this.columnsIcon = columnsIcon;
|
|
80
|
+
/**
|
|
81
|
+
* @hidden
|
|
82
|
+
*/
|
|
83
|
+
this.actionsClass = 'k-actions';
|
|
84
|
+
/**
|
|
85
|
+
* @hidden
|
|
86
|
+
*/
|
|
87
|
+
this.moreHorizontalIcon = moreHorizontalIcon;
|
|
88
|
+
/**
|
|
89
|
+
* @hidden
|
|
90
|
+
*/
|
|
91
|
+
this.filterIcon = filterIcon;
|
|
70
92
|
/**
|
|
71
93
|
* @hidden
|
|
72
94
|
*/
|
|
@@ -82,6 +104,17 @@ export class ColumnMenuComponent {
|
|
|
82
104
|
this.moreVerticalIcon = moreVerticalIcon;
|
|
83
105
|
this.closeSubscription = service.closeMenu.subscribe(this.close.bind(this));
|
|
84
106
|
}
|
|
107
|
+
/**
|
|
108
|
+
* @hidden
|
|
109
|
+
*/
|
|
110
|
+
get showGeneralTab() {
|
|
111
|
+
return this.hasSort
|
|
112
|
+
|| this.hasLock
|
|
113
|
+
|| this.hasStick
|
|
114
|
+
|| this.hasPosition
|
|
115
|
+
|| this.hasAutoSizeColumn
|
|
116
|
+
|| this.hasAutoSizeAllColumns;
|
|
117
|
+
}
|
|
85
118
|
/**
|
|
86
119
|
* @hidden
|
|
87
120
|
*/
|
|
@@ -107,6 +140,16 @@ export class ColumnMenuComponent {
|
|
|
107
140
|
get hasColumnChooser() {
|
|
108
141
|
return hasColumnChooser(this.settings);
|
|
109
142
|
}
|
|
143
|
+
/**
|
|
144
|
+
* @hidden
|
|
145
|
+
*/
|
|
146
|
+
onApply(changed) {
|
|
147
|
+
this.close();
|
|
148
|
+
if (changed.length) {
|
|
149
|
+
this.cdr.markForCheck();
|
|
150
|
+
this.columnInfoService.changeVisibility(changed);
|
|
151
|
+
}
|
|
152
|
+
}
|
|
110
153
|
/**
|
|
111
154
|
* @hidden
|
|
112
155
|
*/
|
|
@@ -137,6 +180,12 @@ export class ColumnMenuComponent {
|
|
|
137
180
|
get hasPosition() {
|
|
138
181
|
return hasPosition(this.settings, this.column);
|
|
139
182
|
}
|
|
183
|
+
/**
|
|
184
|
+
* @hidden
|
|
185
|
+
*/
|
|
186
|
+
get columns() {
|
|
187
|
+
return this.columnInfoService.leafNamedColumns;
|
|
188
|
+
}
|
|
140
189
|
ngAfterViewInit() {
|
|
141
190
|
if (this.ctx.grid.virtualColumns && isDevMode()) {
|
|
142
191
|
if (this.settings.autoSizeAllColumns) {
|
|
@@ -148,6 +197,7 @@ export class ColumnMenuComponent {
|
|
|
148
197
|
console.warn(ColunnMenuErrorMessages.autoSizeColumn);
|
|
149
198
|
}
|
|
150
199
|
}
|
|
200
|
+
this.service.menuTabbingService.isTabbedInterface = this.settings.view === 'tabbed' ? true : false;
|
|
151
201
|
}
|
|
152
202
|
ngOnChanges() {
|
|
153
203
|
this.service.column = this.column;
|
|
@@ -171,6 +221,11 @@ export class ColumnMenuComponent {
|
|
|
171
221
|
this.expandedColumns = this.getExpandedState(this.settings.columnChooser);
|
|
172
222
|
this.expandedPosition = this.getExpandedState(this.settings.setColumnPosition);
|
|
173
223
|
this.popupRef = this.popupService.open(anchor, template, this.popupRef, POPUP_CLASS);
|
|
224
|
+
if (this.popupRef && this.settings.view === 'tabbed') {
|
|
225
|
+
this.renderer.addClass(this.popupRef.popupElement.firstChild, 'k-column-menu-tabbed');
|
|
226
|
+
this.cdr.detectChanges();
|
|
227
|
+
this.tabStrip?.selectTab(0);
|
|
228
|
+
}
|
|
174
229
|
if (!this.popupRef) {
|
|
175
230
|
if (this.navigationService.tableEnabled) {
|
|
176
231
|
this.navigationService.focusCell(0, this.column.leafIndex);
|
|
@@ -197,7 +252,7 @@ export class ColumnMenuComponent {
|
|
|
197
252
|
* @hidden
|
|
198
253
|
*/
|
|
199
254
|
get columnMenuTitle() {
|
|
200
|
-
const localizationMsg = this.localization.get('columnMenu') || '';
|
|
255
|
+
const localizationMsg = this.ctx.localization.get('columnMenu') || '';
|
|
201
256
|
const columnName = this.column.title || this.column.field;
|
|
202
257
|
return replaceMessagePlaceholder(localizationMsg, 'columnName', columnName);
|
|
203
258
|
}
|
|
@@ -205,11 +260,11 @@ export class ColumnMenuComponent {
|
|
|
205
260
|
return typeof (menuItemSettings) === 'object' ? menuItemSettings.expanded : false;
|
|
206
261
|
}
|
|
207
262
|
}
|
|
208
|
-
ColumnMenuComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: ColumnMenuComponent, deps: [{ token: i1.NavigationService }, { token: i2.SinglePopupService }, { token: i3.
|
|
263
|
+
ColumnMenuComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: ColumnMenuComponent, deps: [{ token: i1.NavigationService }, { token: i2.SinglePopupService }, { token: i3.ColumnMenuService }, { token: i4.ContextService }, { token: i0.Renderer2 }, { token: i0.ChangeDetectorRef }, { token: i5.ColumnInfoService }], target: i0.ɵɵFactoryTarget.Component });
|
|
209
264
|
ColumnMenuComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.12", type: ColumnMenuComponent, selector: "kendo-grid-column-menu", inputs: { standalone: "standalone", column: "column", settings: "settings", sort: "sort", filter: "filter", sortable: "sortable", columnMenuTemplate: "columnMenuTemplate", tabIndex: "tabIndex" }, host: { properties: { "class.k-grid-column-menu-standalone": "this.standalone" } }, providers: [
|
|
210
265
|
ColumnMenuService,
|
|
211
266
|
MenuTabbingService
|
|
212
|
-
], viewQueries: [{ propertyName: "anchor", first: true, predicate: ["anchor"], descendants: true, static: true }, { propertyName: "template", first: true, predicate: ["template"], descendants: true, read: TemplateRef, static: true }], usesOnChanges: true, ngImport: i0, template: `
|
|
267
|
+
], viewQueries: [{ propertyName: "anchor", first: true, predicate: ["anchor"], descendants: true, static: true }, { propertyName: "template", first: true, predicate: ["template"], descendants: true, read: TemplateRef, static: true }, { propertyName: "defaultTemplate", first: true, predicate: ["defaultTemplate"], descendants: true, read: TemplateRef, static: true }, { propertyName: "tabbedInterfaceTemplate", first: true, predicate: ["tabbedInterfaceTemplate"], descendants: true, read: TemplateRef, static: true }, { propertyName: "tabStrip", first: true, predicate: TabStripComponent, descendants: true }], usesOnChanges: true, ngImport: i0, template: `
|
|
213
268
|
<a #anchor
|
|
214
269
|
class="k-grid-header-menu k-grid-column-menu"
|
|
215
270
|
[ngClass]="{ 'k-active': isActive }"
|
|
@@ -224,7 +279,7 @@ ColumnMenuComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", ve
|
|
|
224
279
|
</a>
|
|
225
280
|
<ng-template #template>
|
|
226
281
|
<ng-container
|
|
227
|
-
[ngTemplateOutlet]="column.columnMenuTemplateRef || columnMenuTemplate || defaultTemplate"
|
|
282
|
+
[ngTemplateOutlet]="this.column.columnMenuTemplateRef || this.columnMenuTemplate || (this.settings.view === 'tabbed' ? this.tabbedInterfaceTemplate : this.defaultTemplate)"
|
|
228
283
|
[ngTemplateOutletContext]="{ service: service, column: column }">
|
|
229
284
|
</ng-container>
|
|
230
285
|
</ng-template>
|
|
@@ -281,7 +336,95 @@ ColumnMenuComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", ve
|
|
|
281
336
|
</kendo-grid-columnmenu-filter>
|
|
282
337
|
</kendo-grid-columnmenu-container>
|
|
283
338
|
</ng-template>
|
|
284
|
-
|
|
339
|
+
<ng-template #tabbedInterfaceTemplate>
|
|
340
|
+
<kendo-tabstrip #tabstrip (keydown.escape)="close()">
|
|
341
|
+
<kendo-tabstrip-tab *ngIf="hasFilter">
|
|
342
|
+
<ng-template kendoTabTitle>
|
|
343
|
+
<kendo-icon-wrapper
|
|
344
|
+
[attr.title]="ctx.localization.get('columnMenuFilterTabTitle')"
|
|
345
|
+
name="filter"
|
|
346
|
+
[svgIcon]="filterIcon">
|
|
347
|
+
</kendo-icon-wrapper>
|
|
348
|
+
</ng-template>
|
|
349
|
+
<ng-template kendoTabContent>
|
|
350
|
+
<kendo-grid-filter-menu-container
|
|
351
|
+
[column]="service.column"
|
|
352
|
+
[menuTabbingService]="service.menuTabbingService"
|
|
353
|
+
[filter]="service.filter"
|
|
354
|
+
[actionsClass]="actionsClass"
|
|
355
|
+
(keydown.shift.tab)="$event.stopImmediatePropagation()"
|
|
356
|
+
(close)="close()">
|
|
357
|
+
</kendo-grid-filter-menu-container>
|
|
358
|
+
</ng-template>
|
|
359
|
+
</kendo-tabstrip-tab>
|
|
360
|
+
<kendo-tabstrip-tab *ngIf="showGeneralTab">
|
|
361
|
+
<ng-template kendoTabTitle>
|
|
362
|
+
<kendo-icon-wrapper
|
|
363
|
+
[attr.title]="ctx.localization.get('columnMenuGeneralTabTitle')"
|
|
364
|
+
name="more-horizontal"
|
|
365
|
+
[svgIcon]="moreHorizontalIcon">
|
|
366
|
+
</kendo-icon-wrapper>
|
|
367
|
+
</ng-template>
|
|
368
|
+
<ng-template kendoTabContent>
|
|
369
|
+
<kendo-grid-columnmenu-sort #sortItem [kendoGridColumnMenuItem]="sortItem" *ngIf="hasSort" [service]="service">
|
|
370
|
+
</kendo-grid-columnmenu-sort>
|
|
371
|
+
<span [style.borderColor]="'rgba(0, 0, 0, 0.08)'" *ngIf="hasSort && (hasLock || hasStick || hasPosition || hasAutoSizeColumn || hasAutoSizeAllColumns)" class="k-separator"></span>
|
|
372
|
+
<kendo-grid-columnmenu-lock #lockItem *ngIf="hasLock && !hasPosition" [kendoGridColumnMenuItem]="lockItem" [service]="service">
|
|
373
|
+
</kendo-grid-columnmenu-lock>
|
|
374
|
+
<kendo-grid-columnmenu-stick #stickItem *ngIf="hasStick && !hasPosition" [kendoGridColumnMenuItem]="stickItem" [service]="service">
|
|
375
|
+
</kendo-grid-columnmenu-stick>
|
|
376
|
+
<span [style.borderColor]="'rgba(0, 0, 0, 0.08)'" *ngIf="(hasLock || hasStick) && !hasPosition && (hasAutoSizeColumn || hasAutoSizeAllColumns)" class="k-separator"></span>
|
|
377
|
+
<kendo-grid-columnmenu-position
|
|
378
|
+
#positionItem
|
|
379
|
+
*ngIf="hasPosition"
|
|
380
|
+
[showLock]="hasLock"
|
|
381
|
+
[showStick]="hasStick"
|
|
382
|
+
[kendoGridColumnMenuItem]="positionItem"
|
|
383
|
+
[service]="service"
|
|
384
|
+
[expanded]="expandedPosition">
|
|
385
|
+
</kendo-grid-columnmenu-position>
|
|
386
|
+
<span [style.borderColor]="'rgba(0, 0, 0, 0.08)'" *ngIf="hasPosition && (hasAutoSizeColumn || hasAutoSizeAllColumns)" class="k-separator"></span>
|
|
387
|
+
<kendo-grid-columnmenu-autosize-column
|
|
388
|
+
#autoSizeColumnItem
|
|
389
|
+
*ngIf="hasAutoSizeColumn"
|
|
390
|
+
[service]="service"
|
|
391
|
+
[kendoGridColumnMenuItem]="autoSizeColumnItem"
|
|
392
|
+
[column]="column"
|
|
393
|
+
>
|
|
394
|
+
</kendo-grid-columnmenu-autosize-column>
|
|
395
|
+
<kendo-grid-columnmenu-autosize-all-columns
|
|
396
|
+
#autoSizeAllColumnsItem
|
|
397
|
+
*ngIf="hasAutoSizeAllColumns"
|
|
398
|
+
[service]="service"
|
|
399
|
+
[kendoGridColumnMenuItem]="autoSizeAllColumnsItem"
|
|
400
|
+
>
|
|
401
|
+
</kendo-grid-columnmenu-autosize-all-columns>
|
|
402
|
+
</ng-template>
|
|
403
|
+
</kendo-tabstrip-tab>
|
|
404
|
+
<kendo-tabstrip-tab *ngIf="hasColumnChooser">
|
|
405
|
+
<ng-template kendoTabTitle>
|
|
406
|
+
<kendo-icon-wrapper
|
|
407
|
+
[attr.title]="ctx.localization.get('columnMenuColumnsTabTitle')"
|
|
408
|
+
name="columns"
|
|
409
|
+
[svgIcon]="columnsIcon">
|
|
410
|
+
</kendo-icon-wrapper>
|
|
411
|
+
</ng-template>
|
|
412
|
+
<ng-template kendoTabContent>
|
|
413
|
+
<kendo-grid-columnlist
|
|
414
|
+
[applyText]="ctx.localization.get('columnsApply')"
|
|
415
|
+
[resetText]="ctx.localization.get('columnsReset')"
|
|
416
|
+
[columns]="columns"
|
|
417
|
+
[autoSync]="false"
|
|
418
|
+
[allowHideAll]="false"
|
|
419
|
+
[actionsClass]="actionsClass"
|
|
420
|
+
[service]="service"
|
|
421
|
+
(apply)="onApply($event)">
|
|
422
|
+
</kendo-grid-columnlist>
|
|
423
|
+
</ng-template>
|
|
424
|
+
</kendo-tabstrip-tab>
|
|
425
|
+
</kendo-tabstrip>
|
|
426
|
+
</ng-template>
|
|
427
|
+
`, isInline: true, components: [{ type: i6.IconWrapperComponent, selector: "kendo-icon-wrapper", inputs: ["name", "svgIcon", "innerCssClass", "customFontClass"], exportAs: ["kendoIconWrapper"] }, { type: i7.ColumnMenuContainerComponent, selector: "kendo-grid-columnmenu-container" }, { type: i8.ColumnMenuSortComponent, selector: "kendo-grid-columnmenu-sort" }, { type: i9.ColumnMenuLockComponent, selector: "kendo-grid-columnmenu-lock" }, { type: i10.ColumnMenuStickComponent, selector: "kendo-grid-columnmenu-stick" }, { type: i11.ColumnMenuPositionComponent, selector: "kendo-grid-columnmenu-position", inputs: ["expanded", "showLock", "showStick", "isLast"], outputs: ["expand", "collapse"] }, { type: i12.ColumnMenuChooserComponent, selector: "kendo-grid-columnmenu-chooser", inputs: ["expanded", "isLast"], outputs: ["expand", "collapse"] }, { type: i13.ColumnMenuAutoSizeColumnComponent, selector: "kendo-grid-columnmenu-autosize-column", inputs: ["column"] }, { type: i14.ColumnMenuAutoSizeAllColumnsComponent, selector: "kendo-grid-columnmenu-autosize-all-columns" }, { type: i15.ColumnMenuFilterComponent, selector: "kendo-grid-columnmenu-filter", inputs: ["expanded", "isLast"], outputs: ["expand", "collapse"] }, { type: i16.TabStripComponent, selector: "kendo-tabstrip", inputs: ["height", "animate", "tabAlignment", "tabPosition", "keepTabContent", "closable", "scrollable", "closeIcon", "closeIconClass", "closeSVGIcon"], outputs: ["tabSelect", "tabClose", "tabScroll"], exportAs: ["kendoTabStrip"] }, { type: i16.TabStripTabComponent, selector: "kendo-tabstrip-tab", inputs: ["title", "disabled", "cssClass", "cssStyle", "selected", "closable", "closeIcon", "closeIconClass", "closeSVGIcon"], exportAs: ["kendoTabStripTab"] }, { type: i17.FilterMenuContainerComponent, selector: "kendo-grid-filter-menu-container", inputs: ["column", "isLast", "isExpanded", "menuTabbingService", "filter", "actionsClass"], outputs: ["close"] }, { type: i18.ColumnListComponent, selector: "kendo-grid-columnlist", inputs: ["columns", "autoSync", "allowHideAll", "applyText", "resetText", "actionsClass", "isLast", "isExpanded", "service"], outputs: ["reset", "apply", "columnChange"] }], directives: [{ type: i19.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i19.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }, { type: i19.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i20.ColumnMenuItemDirective, selector: "[kendoGridColumnMenuItem]", inputs: ["kendoGridColumnMenuItem"] }, { type: i16.TabTitleDirective, selector: "[kendoTabTitle]" }, { type: i16.TabContentDirective, selector: "[kendoTabContent]" }] });
|
|
285
428
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: ColumnMenuComponent, decorators: [{
|
|
286
429
|
type: Component,
|
|
287
430
|
args: [{
|
|
@@ -305,7 +448,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
305
448
|
</a>
|
|
306
449
|
<ng-template #template>
|
|
307
450
|
<ng-container
|
|
308
|
-
[ngTemplateOutlet]="column.columnMenuTemplateRef || columnMenuTemplate || defaultTemplate"
|
|
451
|
+
[ngTemplateOutlet]="this.column.columnMenuTemplateRef || this.columnMenuTemplate || (this.settings.view === 'tabbed' ? this.tabbedInterfaceTemplate : this.defaultTemplate)"
|
|
309
452
|
[ngTemplateOutletContext]="{ service: service, column: column }">
|
|
310
453
|
</ng-container>
|
|
311
454
|
</ng-template>
|
|
@@ -362,9 +505,97 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
362
505
|
</kendo-grid-columnmenu-filter>
|
|
363
506
|
</kendo-grid-columnmenu-container>
|
|
364
507
|
</ng-template>
|
|
508
|
+
<ng-template #tabbedInterfaceTemplate>
|
|
509
|
+
<kendo-tabstrip #tabstrip (keydown.escape)="close()">
|
|
510
|
+
<kendo-tabstrip-tab *ngIf="hasFilter">
|
|
511
|
+
<ng-template kendoTabTitle>
|
|
512
|
+
<kendo-icon-wrapper
|
|
513
|
+
[attr.title]="ctx.localization.get('columnMenuFilterTabTitle')"
|
|
514
|
+
name="filter"
|
|
515
|
+
[svgIcon]="filterIcon">
|
|
516
|
+
</kendo-icon-wrapper>
|
|
517
|
+
</ng-template>
|
|
518
|
+
<ng-template kendoTabContent>
|
|
519
|
+
<kendo-grid-filter-menu-container
|
|
520
|
+
[column]="service.column"
|
|
521
|
+
[menuTabbingService]="service.menuTabbingService"
|
|
522
|
+
[filter]="service.filter"
|
|
523
|
+
[actionsClass]="actionsClass"
|
|
524
|
+
(keydown.shift.tab)="$event.stopImmediatePropagation()"
|
|
525
|
+
(close)="close()">
|
|
526
|
+
</kendo-grid-filter-menu-container>
|
|
527
|
+
</ng-template>
|
|
528
|
+
</kendo-tabstrip-tab>
|
|
529
|
+
<kendo-tabstrip-tab *ngIf="showGeneralTab">
|
|
530
|
+
<ng-template kendoTabTitle>
|
|
531
|
+
<kendo-icon-wrapper
|
|
532
|
+
[attr.title]="ctx.localization.get('columnMenuGeneralTabTitle')"
|
|
533
|
+
name="more-horizontal"
|
|
534
|
+
[svgIcon]="moreHorizontalIcon">
|
|
535
|
+
</kendo-icon-wrapper>
|
|
536
|
+
</ng-template>
|
|
537
|
+
<ng-template kendoTabContent>
|
|
538
|
+
<kendo-grid-columnmenu-sort #sortItem [kendoGridColumnMenuItem]="sortItem" *ngIf="hasSort" [service]="service">
|
|
539
|
+
</kendo-grid-columnmenu-sort>
|
|
540
|
+
<span [style.borderColor]="'rgba(0, 0, 0, 0.08)'" *ngIf="hasSort && (hasLock || hasStick || hasPosition || hasAutoSizeColumn || hasAutoSizeAllColumns)" class="k-separator"></span>
|
|
541
|
+
<kendo-grid-columnmenu-lock #lockItem *ngIf="hasLock && !hasPosition" [kendoGridColumnMenuItem]="lockItem" [service]="service">
|
|
542
|
+
</kendo-grid-columnmenu-lock>
|
|
543
|
+
<kendo-grid-columnmenu-stick #stickItem *ngIf="hasStick && !hasPosition" [kendoGridColumnMenuItem]="stickItem" [service]="service">
|
|
544
|
+
</kendo-grid-columnmenu-stick>
|
|
545
|
+
<span [style.borderColor]="'rgba(0, 0, 0, 0.08)'" *ngIf="(hasLock || hasStick) && !hasPosition && (hasAutoSizeColumn || hasAutoSizeAllColumns)" class="k-separator"></span>
|
|
546
|
+
<kendo-grid-columnmenu-position
|
|
547
|
+
#positionItem
|
|
548
|
+
*ngIf="hasPosition"
|
|
549
|
+
[showLock]="hasLock"
|
|
550
|
+
[showStick]="hasStick"
|
|
551
|
+
[kendoGridColumnMenuItem]="positionItem"
|
|
552
|
+
[service]="service"
|
|
553
|
+
[expanded]="expandedPosition">
|
|
554
|
+
</kendo-grid-columnmenu-position>
|
|
555
|
+
<span [style.borderColor]="'rgba(0, 0, 0, 0.08)'" *ngIf="hasPosition && (hasAutoSizeColumn || hasAutoSizeAllColumns)" class="k-separator"></span>
|
|
556
|
+
<kendo-grid-columnmenu-autosize-column
|
|
557
|
+
#autoSizeColumnItem
|
|
558
|
+
*ngIf="hasAutoSizeColumn"
|
|
559
|
+
[service]="service"
|
|
560
|
+
[kendoGridColumnMenuItem]="autoSizeColumnItem"
|
|
561
|
+
[column]="column"
|
|
562
|
+
>
|
|
563
|
+
</kendo-grid-columnmenu-autosize-column>
|
|
564
|
+
<kendo-grid-columnmenu-autosize-all-columns
|
|
565
|
+
#autoSizeAllColumnsItem
|
|
566
|
+
*ngIf="hasAutoSizeAllColumns"
|
|
567
|
+
[service]="service"
|
|
568
|
+
[kendoGridColumnMenuItem]="autoSizeAllColumnsItem"
|
|
569
|
+
>
|
|
570
|
+
</kendo-grid-columnmenu-autosize-all-columns>
|
|
571
|
+
</ng-template>
|
|
572
|
+
</kendo-tabstrip-tab>
|
|
573
|
+
<kendo-tabstrip-tab *ngIf="hasColumnChooser">
|
|
574
|
+
<ng-template kendoTabTitle>
|
|
575
|
+
<kendo-icon-wrapper
|
|
576
|
+
[attr.title]="ctx.localization.get('columnMenuColumnsTabTitle')"
|
|
577
|
+
name="columns"
|
|
578
|
+
[svgIcon]="columnsIcon">
|
|
579
|
+
</kendo-icon-wrapper>
|
|
580
|
+
</ng-template>
|
|
581
|
+
<ng-template kendoTabContent>
|
|
582
|
+
<kendo-grid-columnlist
|
|
583
|
+
[applyText]="ctx.localization.get('columnsApply')"
|
|
584
|
+
[resetText]="ctx.localization.get('columnsReset')"
|
|
585
|
+
[columns]="columns"
|
|
586
|
+
[autoSync]="false"
|
|
587
|
+
[allowHideAll]="false"
|
|
588
|
+
[actionsClass]="actionsClass"
|
|
589
|
+
[service]="service"
|
|
590
|
+
(apply)="onApply($event)">
|
|
591
|
+
</kendo-grid-columnlist>
|
|
592
|
+
</ng-template>
|
|
593
|
+
</kendo-tabstrip-tab>
|
|
594
|
+
</kendo-tabstrip>
|
|
595
|
+
</ng-template>
|
|
365
596
|
`
|
|
366
597
|
}]
|
|
367
|
-
}], ctorParameters: function () { return [{ type: i1.NavigationService }, { type: i2.SinglePopupService }, { type: i3.
|
|
598
|
+
}], ctorParameters: function () { return [{ type: i1.NavigationService }, { type: i2.SinglePopupService }, { type: i3.ColumnMenuService }, { type: i4.ContextService }, { type: i0.Renderer2 }, { type: i0.ChangeDetectorRef }, { type: i5.ColumnInfoService }]; }, propDecorators: { standalone: [{
|
|
368
599
|
type: HostBinding,
|
|
369
600
|
args: ['class.k-grid-column-menu-standalone']
|
|
370
601
|
}, {
|
|
@@ -389,4 +620,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
389
620
|
}], template: [{
|
|
390
621
|
type: ViewChild,
|
|
391
622
|
args: ['template', { static: true, read: TemplateRef }]
|
|
623
|
+
}], defaultTemplate: [{
|
|
624
|
+
type: ViewChild,
|
|
625
|
+
args: ['defaultTemplate', { static: true, read: TemplateRef }]
|
|
626
|
+
}], tabbedInterfaceTemplate: [{
|
|
627
|
+
type: ViewChild,
|
|
628
|
+
args: ['tabbedInterfaceTemplate', { static: true, read: TemplateRef }]
|
|
629
|
+
}], tabStrip: [{
|
|
630
|
+
type: ViewChild,
|
|
631
|
+
args: [TabStripComponent]
|
|
392
632
|
}] } });
|
|
@@ -22,6 +22,7 @@ import { ColumnMenuPositionComponent } from './column-menu-position.component';
|
|
|
22
22
|
import { ColumnMenuAutoSizeColumnComponent } from './column-menu-autosize.component';
|
|
23
23
|
import { ColumnMenuAutoSizeAllColumnsComponent } from './column-menu-autosize-all.component';
|
|
24
24
|
import { ButtonModule } from '@progress/kendo-angular-buttons';
|
|
25
|
+
import { TabStripModule } from '@progress/kendo-angular-layout';
|
|
25
26
|
import * as i0 from "@angular/core";
|
|
26
27
|
const COMPONENTS = [
|
|
27
28
|
ColumnListComponent,
|
|
@@ -81,7 +82,7 @@ ColumnMenuModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", versio
|
|
|
81
82
|
ColumnMenuStickComponent,
|
|
82
83
|
ColumnMenuPositionComponent,
|
|
83
84
|
ColumnMenuAutoSizeColumnComponent,
|
|
84
|
-
ColumnMenuAutoSizeAllColumnsComponent], imports: [CommonModule, FilterMenuModule, ButtonModule], exports: [ColumnListComponent,
|
|
85
|
+
ColumnMenuAutoSizeAllColumnsComponent], imports: [CommonModule, FilterMenuModule, ButtonModule, TabStripModule], exports: [ColumnListComponent,
|
|
85
86
|
ColumnChooserComponent,
|
|
86
87
|
ColumnMenuChooserComponent,
|
|
87
88
|
ColumnMenuFilterComponent,
|
|
@@ -97,12 +98,12 @@ ColumnMenuModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", versio
|
|
|
97
98
|
ColumnMenuPositionComponent,
|
|
98
99
|
ColumnMenuAutoSizeColumnComponent,
|
|
99
100
|
ColumnMenuAutoSizeAllColumnsComponent] });
|
|
100
|
-
ColumnMenuModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: ColumnMenuModule, imports: [[CommonModule, FilterMenuModule, ButtonModule]] });
|
|
101
|
+
ColumnMenuModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: ColumnMenuModule, imports: [[CommonModule, FilterMenuModule, ButtonModule, TabStripModule]] });
|
|
101
102
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: ColumnMenuModule, decorators: [{
|
|
102
103
|
type: NgModule,
|
|
103
104
|
args: [{
|
|
104
105
|
declarations: [COMPONENTS],
|
|
105
|
-
imports: [CommonModule, FilterMenuModule, ButtonModule],
|
|
106
|
+
imports: [CommonModule, FilterMenuModule, ButtonModule, TabStripModule],
|
|
106
107
|
exports: [COMPONENTS]
|
|
107
108
|
}]
|
|
108
109
|
}] });
|
|
@@ -4,7 +4,6 @@
|
|
|
4
4
|
*-------------------------------------------------------------------------------------------*/
|
|
5
5
|
import { ChangeDetectorRef, Directive, ElementRef, Host, HostBinding, HostListener, Input, NgZone } from '@angular/core';
|
|
6
6
|
import { Subscription, of } from 'rxjs';
|
|
7
|
-
import { LocalizationService } from '@progress/kendo-angular-l10n';
|
|
8
7
|
import { isBlank, isPresent, isTruthy } from '../utils';
|
|
9
8
|
import { ColumnBase } from '../columns/column-base';
|
|
10
9
|
import { expandColumns, leafColumns, columnsToRender } from '../columns/column-common';
|
|
@@ -12,10 +11,11 @@ import { DraggableDirective } from '@progress/kendo-angular-common';
|
|
|
12
11
|
import { ColumnResizingService } from './column-resizing.service';
|
|
13
12
|
import { delay, takeUntil, filter, take, tap, switchMap, map } from 'rxjs/operators';
|
|
14
13
|
import { ColumnInfoService } from '../common/column-info.service';
|
|
14
|
+
import { ContextService } from '../common/provider.service';
|
|
15
15
|
import * as i0 from "@angular/core";
|
|
16
16
|
import * as i1 from "@progress/kendo-angular-common";
|
|
17
17
|
import * as i2 from "./column-resizing.service";
|
|
18
|
-
import * as i3 from "
|
|
18
|
+
import * as i3 from "../common/provider.service";
|
|
19
19
|
import * as i4 from "../common/column-info.service";
|
|
20
20
|
/**
|
|
21
21
|
* @hidden
|
|
@@ -87,13 +87,13 @@ const indexOf = (target, list) => {
|
|
|
87
87
|
* @hidden
|
|
88
88
|
*/
|
|
89
89
|
export class ColumnHandleDirective {
|
|
90
|
-
constructor(draggable, element, service, zone, cdr,
|
|
90
|
+
constructor(draggable, element, service, zone, cdr, ctx, columnInfoService) {
|
|
91
91
|
this.draggable = draggable;
|
|
92
92
|
this.element = element;
|
|
93
93
|
this.service = service;
|
|
94
94
|
this.zone = zone;
|
|
95
95
|
this.cdr = cdr;
|
|
96
|
-
this.
|
|
96
|
+
this.ctx = ctx;
|
|
97
97
|
this.columnInfoService = columnInfoService;
|
|
98
98
|
this.columns = [];
|
|
99
99
|
this.subscriptions = new Subscription();
|
|
@@ -148,7 +148,7 @@ export class ColumnHandleDirective {
|
|
|
148
148
|
.subscribe(this.sizeToFit.bind(this)));
|
|
149
149
|
this.subscriptions.add(service.pipe(filter(e => e.type === 'triggerAutoFit'))
|
|
150
150
|
.subscribe(this.autoFit.bind(this)));
|
|
151
|
-
this.subscriptions.add(this.localization.changes.subscribe(({ rtl }) => this.rtl = rtl));
|
|
151
|
+
this.subscriptions.add(this.ctx.localization.changes.subscribe(({ rtl }) => this.rtl = rtl));
|
|
152
152
|
}
|
|
153
153
|
ngOnDestroy() {
|
|
154
154
|
if (this.subscriptions) {
|
|
@@ -224,7 +224,7 @@ export class ColumnHandleDirective {
|
|
|
224
224
|
}
|
|
225
225
|
}
|
|
226
226
|
}
|
|
227
|
-
ColumnHandleDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: ColumnHandleDirective, deps: [{ token: i1.DraggableDirective, host: true }, { token: i0.ElementRef }, { token: i2.ColumnResizingService }, { token: i0.NgZone }, { token: i0.ChangeDetectorRef }, { token: i3.
|
|
227
|
+
ColumnHandleDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: ColumnHandleDirective, deps: [{ token: i1.DraggableDirective, host: true }, { token: i0.ElementRef }, { token: i2.ColumnResizingService }, { token: i0.NgZone }, { token: i0.ChangeDetectorRef }, { token: i3.ContextService }, { token: i4.ColumnInfoService }], target: i0.ɵɵFactoryTarget.Directive });
|
|
228
228
|
ColumnHandleDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.3.12", type: ColumnHandleDirective, selector: "[kendoGridColumnHandle]", inputs: { columns: "columns", column: "column" }, host: { listeners: { "dblclick": "autoFit()" }, properties: { "style.display": "this.visible", "style.left": "this.leftStyle", "style.right": "this.rightStyle" } }, ngImport: i0 });
|
|
229
229
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: ColumnHandleDirective, decorators: [{
|
|
230
230
|
type: Directive,
|
|
@@ -233,7 +233,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
233
233
|
}]
|
|
234
234
|
}], ctorParameters: function () { return [{ type: i1.DraggableDirective, decorators: [{
|
|
235
235
|
type: Host
|
|
236
|
-
}] }, { type: i0.ElementRef }, { type: i2.ColumnResizingService }, { type: i0.NgZone }, { type: i0.ChangeDetectorRef }, { type: i3.
|
|
236
|
+
}] }, { type: i0.ElementRef }, { type: i2.ColumnResizingService }, { type: i0.NgZone }, { type: i0.ChangeDetectorRef }, { type: i3.ContextService }, { type: i4.ColumnInfoService }]; }, propDecorators: { columns: [{
|
|
237
237
|
type: Input
|
|
238
238
|
}], column: [{
|
|
239
239
|
type: Input
|