Skip to content

Commit 025d13e

Browse files
authored
Merge branch 'master' into AMarinov/issue5587_master
2 parents 02afce5 + 57bce78 commit 025d13e

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+561
-91
lines changed

CHANGELOG.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,19 @@
22

33
All notable changes for each version of this project will be documented in this file.
44

5+
## 8.2.0
6+
7+
### New Features
8+
- `IgxGrid`, `IgxTreeGrid`, `IgxHierarchicalGrid`
9+
- `uniqueColumnValuesStrategy` input is added. This property provides a callback for loading unique column values on demand. If this property is provided, the unique values it generates will be used by the Excel Style Filtering (instead of using the unique values from the data that is bound to the grid).
10+
- `igxExcelStyleLoading` directive is added, which can be used to provide a custom loading template for the Excel Style Filtering. If this property is not provided, a default loading template will be used instead.
11+
### General
12+
- `IgxGrid`, `IgxTreeGrid`, `IgxHierarchicalGrid`
13+
- **Breaking Change** `igxExcelStyleSortingTemplate` directive is renamed to `igxExcelStyleSorting`.
14+
- **Breaking Change** `igxExcelStyleMovingTemplate` directive is renamed to `igxExcelStyleMoving`.
15+
- **Breaking Change** `igxExcelStyleHidingTemplate` directive is renamed to `igxExcelStyleHiding`.
16+
- **Breaking Change** `igxExcelStylePinningTemplate` directive is renamed to `igxExcelStylePinning`.
17+
518
## 8.1.3
619
- `IgxCombo`
720
- Combo `onSelectionChange` events now emits the item(s) that were added to or removed from the collection:

projects/igniteui-angular/migrations/migration-collection.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,11 @@
4545
"version": "7.3.4",
4646
"description": "Updates Ignite UI for Angular from v7.2.0 to v7.3.4",
4747
"factory": "./update-7_3_4"
48+
},
49+
"migration-10": {
50+
"version": "8.2.0",
51+
"description": "Updates Ignite UI for Angular from v8.1.x to v8.2.0",
52+
"factory": "./update-8_2_0"
4853
}
4954
}
5055
}
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
{
2+
"$schema": "../../common/schema/selector.schema.json",
3+
"changes": [
4+
{
5+
"type": "directive",
6+
"selector": "igxExcelStyleSortingTemplate",
7+
"replaceWith": "igxExcelStyleSorting"
8+
},
9+
{
10+
"type": "directive",
11+
"selector": "igxExcelStyleMovingTemplate",
12+
"replaceWith": "igxExcelStyleMoving"
13+
},
14+
{
15+
"type": "directive",
16+
"selector": "igxExcelStyleHidingTemplate",
17+
"replaceWith": "igxExcelStyleHiding"
18+
},
19+
{
20+
"type": "directive",
21+
"selector": "igxExcelStylePinningTemplate",
22+
"replaceWith": "igxExcelStylePinning"
23+
}
24+
]
25+
}
Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
import * as path from 'path';
2+
3+
// tslint:disable:no-implicit-dependencies
4+
import { virtualFs } from '@angular-devkit/core';
5+
import { EmptyTree } from '@angular-devkit/schematics';
6+
// tslint:disable-next-line:no-submodule-imports
7+
import { SchematicTestRunner, UnitTestTree } from '@angular-devkit/schematics/testing';
8+
9+
describe('Update 8.2.0', () => {
10+
let appTree: UnitTestTree;
11+
const schematicRunner = new SchematicTestRunner('ig-migrate', path.join(__dirname, '../migration-collection.json'));
12+
const configJson = {
13+
defaultProject: 'testProj',
14+
projects: {
15+
testProj: {
16+
sourceRoot: '/testSrc'
17+
}
18+
},
19+
schematics: {
20+
'@schematics/angular:component': {
21+
prefix: 'appPrefix'
22+
}
23+
}
24+
};
25+
26+
beforeEach(() => {
27+
appTree = new UnitTestTree(new EmptyTree());
28+
appTree.create('/angular.json', JSON.stringify(configJson));
29+
});
30+
31+
it('should update Excel Style Filtering template selectors', done => {
32+
appTree.create(
33+
'/testSrc/appPrefix/component/custom.component.html',
34+
`<igx-grid [data]="data" height="500px" [autoGenerate]="true" [allowFiltering]='true' [filterMode]="'excelStyleFilter'">
35+
<ng-template igxExcelStyleSortingTemplate><div class="esf-custom-sorting">Sorting Template</div></ng-template>
36+
<ng-template igxExcelStyleHidingTemplate><div class="esf-custom-hiding">Hiding Template</div></ng-template>
37+
<ng-template igxExcelStyleMovingTemplate><div class="esf-custom-moving">Moving Template</div></ng-template>
38+
<ng-template igxExcelStylePinningTemplate><div class="esf-custom-pinning">Pinning Template</div></ng-template>
39+
</igx-grid>`);
40+
41+
const tree = schematicRunner.runSchematic('migration-10', {}, appTree);
42+
expect(tree.readContent('/testSrc/appPrefix/component/custom.component.html'))
43+
.toEqual(
44+
`<igx-grid [data]="data" height="500px" [autoGenerate]="true" [allowFiltering]='true' [filterMode]="'excelStyleFilter'">
45+
<ng-template igxExcelStyleSorting><div class="esf-custom-sorting">Sorting Template</div></ng-template>
46+
<ng-template igxExcelStyleHiding><div class="esf-custom-hiding">Hiding Template</div></ng-template>
47+
<ng-template igxExcelStyleMoving><div class="esf-custom-moving">Moving Template</div></ng-template>
48+
<ng-template igxExcelStylePinning><div class="esf-custom-pinning">Pinning Template</div></ng-template>
49+
</igx-grid>`);
50+
51+
done();
52+
});
53+
});
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
import {
2+
Rule,
3+
SchematicContext,
4+
Tree
5+
} from '@angular-devkit/schematics';
6+
import { UpdateChanges } from '../common/UpdateChanges';
7+
8+
const version = '8.2.0';
9+
10+
export default function(): Rule {
11+
return (host: Tree, context: SchematicContext) => {
12+
context.logger.info(`Applying migration for Ignite UI for Angular to version ${version}`);
13+
14+
const update = new UpdateChanges(__dirname, host, context);
15+
update.applyChanges();
16+
};
17+
}

projects/igniteui-angular/src/lib/banner/banner.component.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,13 +47,13 @@ export class IgxBannerComponent implements IToggleView {
4747
@ViewChild('expansionPanel', { static: true })
4848
private _expansionPanel: IgxExpansionPanelComponent;
4949

50-
@ContentChild(IgxBannerActionsDirective, { static: true })
50+
@ContentChild(IgxBannerActionsDirective, { static: false })
5151
private _bannerActionTemplate: IgxBannerActionsDirective;
5252

5353
/**
5454
* @hidden
5555
*/
56-
@ContentChild(IgxIconComponent, { static: true })
56+
@ContentChild(IgxIconComponent, { static: false })
5757
public bannerIcon: IgxIconComponent;
5858

5959
/**

projects/igniteui-angular/src/lib/combo/combo.component.ts

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -243,7 +243,7 @@ export class IgxComboComponent extends DisplayDensityBase implements IgxComboBas
243243
* </igx-combo>
244244
* ```
245245
*/
246-
@ContentChild(IgxComboItemDirective, { read: TemplateRef, static: true })
246+
@ContentChild(IgxComboItemDirective, { read: TemplateRef, static: false })
247247
public itemTemplate: TemplateRef<any> = null;
248248

249249
/**
@@ -266,7 +266,7 @@ export class IgxComboComponent extends DisplayDensityBase implements IgxComboBas
266266
* </igx-combo>
267267
* ```
268268
*/
269-
@ContentChild(IgxComboHeaderDirective, { read: TemplateRef, static: true })
269+
@ContentChild(IgxComboHeaderDirective, { read: TemplateRef, static: false })
270270
public headerTemplate: TemplateRef<any> = null;
271271

272272
/**
@@ -289,7 +289,7 @@ export class IgxComboComponent extends DisplayDensityBase implements IgxComboBas
289289
* </igx-combo>
290290
* ```
291291
*/
292-
@ContentChild(IgxComboFooterDirective, { read: TemplateRef, static: true })
292+
@ContentChild(IgxComboFooterDirective, { read: TemplateRef, static: false })
293293
public footerTemplate: TemplateRef<any> = null;
294294

295295
/**
@@ -310,7 +310,7 @@ export class IgxComboComponent extends DisplayDensityBase implements IgxComboBas
310310
* </igx-combo>
311311
* ```
312312
*/
313-
@ContentChild(IgxComboHeaderItemDirective, { read: TemplateRef, static: true })
313+
@ContentChild(IgxComboHeaderItemDirective, { read: TemplateRef, static: false })
314314
public headerItemTemplate: TemplateRef<any> = null;
315315

316316
/**
@@ -333,7 +333,7 @@ export class IgxComboComponent extends DisplayDensityBase implements IgxComboBas
333333
* </igx-combo>
334334
* ```
335335
*/
336-
@ContentChild(IgxComboAddItemDirective, { read: TemplateRef, static: true })
336+
@ContentChild(IgxComboAddItemDirective, { read: TemplateRef, static: false })
337337
public addItemTemplate: TemplateRef<any> = null;
338338

339339
/**
@@ -356,7 +356,7 @@ export class IgxComboComponent extends DisplayDensityBase implements IgxComboBas
356356
* </igx-combo>
357357
* ```
358358
*/
359-
@ContentChild(IgxComboEmptyDirective, { read: TemplateRef, static: true })
359+
@ContentChild(IgxComboEmptyDirective, { read: TemplateRef, static: false })
360360
public emptyTemplate: TemplateRef<any> = null;
361361

362362
/**
@@ -377,7 +377,7 @@ export class IgxComboComponent extends DisplayDensityBase implements IgxComboBas
377377
* </igx-combo>
378378
* ```
379379
*/
380-
@ContentChild(IgxComboToggleIconDirective, { read: TemplateRef, static: true })
380+
@ContentChild(IgxComboToggleIconDirective, { read: TemplateRef, static: false })
381381
public toggleIconTemplate: TemplateRef<any> = null;
382382

383383
/**
@@ -398,7 +398,7 @@ export class IgxComboComponent extends DisplayDensityBase implements IgxComboBas
398398
* </igx-combo>
399399
* ```
400400
*/
401-
@ContentChild(IgxComboClearIconDirective, { read: TemplateRef, static: true })
401+
@ContentChild(IgxComboClearIconDirective, { read: TemplateRef, static: false })
402402
public clearIconTemplate: TemplateRef<any> = null;
403403

404404
@ViewChild('primitive', { read: TemplateRef, static: true })

projects/igniteui-angular/src/lib/core/styles/components/grid/_excel-filtering-component.scss

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,10 @@
1111
@include b(igx-excel-filter) {
1212
@extend %grid-excel-filter !optional;
1313

14+
@include e(loading) {
15+
@extend %igx-excel-filter__loading !optional;
16+
}
17+
1418
@include e(menu) {
1519
@extend %grid-excel-menu !optional;
1620
}

projects/igniteui-angular/src/lib/core/styles/components/grid/_excel-filtering-theme.scss

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,12 @@
1616
display: block;
1717
}
1818

19+
%igx-excel-filter__loading {
20+
display: flex;
21+
justify-content: center;
22+
align-items: center;
23+
}
24+
1925
%grid-excel-icon {
2026
cursor: pointer;
2127

projects/igniteui-angular/src/lib/date-picker/date-picker.component.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -704,19 +704,19 @@ export class IgxDatePickerComponent implements IDatePicker, ControlValueAccessor
704704
/**
705705
*@hidden
706706
*/
707-
@ContentChild(IgxDatePickerTemplateDirective, { read: IgxDatePickerTemplateDirective, static: true })
707+
@ContentChild(IgxDatePickerTemplateDirective, { read: IgxDatePickerTemplateDirective, static: false })
708708
protected datePickerTemplateDirective: IgxDatePickerTemplateDirective;
709709

710710
/**
711711
*@hidden
712712
*/
713-
@ContentChild(IgxCalendarHeaderTemplateDirective, { read: IgxCalendarHeaderTemplateDirective, static: true })
713+
@ContentChild(IgxCalendarHeaderTemplateDirective, { read: IgxCalendarHeaderTemplateDirective, static: false })
714714
public headerTemplate: IgxCalendarHeaderTemplateDirective;
715715

716716
/**
717717
*@hidden
718718
*/
719-
@ContentChild(IgxCalendarSubheaderTemplateDirective, { read: IgxCalendarSubheaderTemplateDirective, static: true })
719+
@ContentChild(IgxCalendarSubheaderTemplateDirective, { read: IgxCalendarSubheaderTemplateDirective, static: false })
720720
public subheaderTemplate: IgxCalendarSubheaderTemplateDirective;
721721

722722
/**

0 commit comments

Comments
 (0)