Skip to content

Commit 4f2d1ed

Browse files
authored
Merge branch 'master' into simeonoff/dock-mgr-drop-shadow
2 parents a800c36 + e3a09dc commit 4f2d1ed

File tree

196 files changed

+5509
-1949
lines changed

Some content is hidden

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

196 files changed

+5509
-1949
lines changed

CHANGELOG.md

Lines changed: 64 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,26 +4,51 @@ All notable changes for each version of this project will be documented in this
44
## 10.2.0
55

66
### General
7-
- `IgxDatePicker`
8-
- Added `aria-labelledby` property for the input field. This will ensure the users of assistive technologies will also know what component is used for, upon input focus.
7+
- `IgxGridActions`
8+
- Added `asMenuItems` Input for grid actions - `igx-grid-editing-actions`, `igx-grid-pinning-actions`. When set to true will render the related action buttons as separate menu items with button and label.
9+
- `IgxGrid`, `IgxTreeGrid`, `IgxHierarchicalGrid`
10+
- **Behavioral Change** - The Excel Style Filtering has been reworked to provide filtering experience such as in Excel. This includes the following changes:
11+
- You can close the Excel Style Filtering menu by pressing `Ctrl + Shift + L`.
12+
- You can apply the filter by pressing `Enter`.
13+
- When searching items in the Excel Style Filtering menu, only the rows that match your search term will be filtered in.
14+
- By checking the `Add current selection to filter` option, the new search results will be added to the previously filtered items.
915
- `IgxInputGroup`
1016
- **Breaking Change** - Removed `fluent`, `fluent_search`, `bootstrap`, and `indigo` as possible values for the `type` input property.
1117
- **Behavioral Change** - The styling of the input group is now dictated by the theme being used. The remaining `types` - `line`, `border`, and `box` will only have effect on the styling when used with the `material` theme. The `search` type will affect styling when used with all themes. Changing the theme at runtime will not change the styling of the input group, a page refresh is required.
18+
- `IgxGrid`, `IgxTreeGrid`, `IgxHierarchicalGrid`
19+
- **Rename outputs**
20+
`onRowEditEnter` to `rowEditEnter`
21+
`onCellEditEnter` to `cellEditEnter`
22+
`onCellEdit` to `cellEdit`
23+
`onRowEdit` to `rowEdit`
24+
- **Breaking Change** - The `onCellEditCancel` event is replaced by the new `cellEditExit` event that emits every time the editable cell exits edit mode.
25+
- **Breaking Change** - The `onRowEditCancel` event is replaced by the new `rowEditExit` event that emits every time the editable row exits edit mode.
1226
- `IgxOverlay`
1327
- **Breaking Change** - `target` property in `PositionSettings` has been deprecated. You can set the attaching target for the component to show in `OverlaySettings` instead.
28+
- `IgxToggleDirective`
29+
- `onAppended`, `onOpened` and `onClosed` events are emitting now arguments of `ToggleViewEventArgs` type.
30+
- `onOpening` and `onClosing` events are emitting now arguments of `ToggleViewCancelableEventArgs` type.
1431
- `IgxSelect`
1532
- Added `aria-labelledby` property for the items list container(marked as `role="listbox"`). This will ensure the users of assistive technologies will also know what the list items container is used for, upon opening.
16-
- `IgxDatePicker`
33+
- `IgxDatePicker`
1734
- **Breaking Change** - Deprecated the `label` property.
18-
- `igxGridActions`
19-
- Added `asMenuItems` Input for grid actions - `igx-grid-editing-actions`, `igx-grid-pinning-actions`. When set to true will render the related action buttons as separate menu items with button and label.
20-
35+
- Added `aria-labelledby` property for the input field. This will ensure the users of assistive technologies will also know what component is used for, upon input focus.
36+
- `igxNavigationDrawer`
37+
- Added `disableAnimation` property which enables/disables the animation, when toggling the drawer. Set to `false` by default.
38+
- `igxTabs`
39+
- Added `disableAnimation` property which enables/disables the transition animation of the tabs' content. Set to `false` by default.
40+
- `IgxExpansionPanel`
41+
- `IExpansionPanelEventArgs.panel` - Deprecated. Usе `owner` property to get a reference to the panel.
42+
- `IgxCalendarComponent`, `IgxMonthsViewComponent` and `IgxYearsViewComponent`
43+
- `tabIndex` property was removed in order to improve on page navigation and to be compliant with W3 accessability recommendations; Also the date grid in the calendar is now only one tab stop, the same approach is applied and in the `IgxMonthsViewComponent` and `IgxYearsViewComponent`;
2144

2245
### New Features
2346
- `IgxGrid`, `IgxTreeGrid`, `IgxHierarchicalGrid`
2447
- When triggering an export of the grid via the toolbar and the export takes more than 500 milliseconds, the export button becomes disabled and an indeterminate progress bar is shown at the bottom of the toolbar until the export is finished.
48+
- `cellEditExit` is a new event that fires when cell exits edit mode
49+
- `rowEditExit` is a new event that fires when row exits edit mode
2550
- Added *getRowData(rowSelector)* method that returns an object that represents the data that is contained in the specified row component.
26-
- Added ability to spawn row adding UI through exoposed methods. Note that rowEditing should be enabled.
51+
- Added ability to spawn row adding UI through exposed methods. Note that rowEditing should be enabled.
2752
- `beginAddRow` method which starts the adding row UI.
2853
- `beginAddChild` method which starts the adding child UI.
2954
```typescript
@@ -38,6 +63,22 @@ All notable changes for each version of this project will be documented in this
3863
</igx-action-strip>
3964
</igx-tree-grid>
4065
```
66+
- A new `locale` and `pipeArgs` parameters are introduced in the `operate` method exposed by the `IgxNumberSummaryOperand` and `IgxDateSummaryOperand`, which exposes the grid locale. Use the `locale` parameter to get localized summary data (as per the grid locale. If not passed, `locale` defaults to `'en-US'`). Use the `pipeArgs` parameter only if you want to customize the format of the date and numeric values that will be returned.
67+
```typescript
68+
class MySummary extends IgxDateSummaryOperand {
69+
operate(columnData: any[], allData = [], fieldName, locale: string, pipeArgs: IColumnPipeArgs): IgxSummaryResult[] {
70+
const pipeArgs: IColumnPipeArgs = {
71+
format: 'longDate',
72+
timezone: 'UTC',
73+
digitsInfo: '1.1-2'
74+
}
75+
const result = super.operate(columnData, allData, fieldName, locale, pipeArgs);
76+
return result;
77+
}
78+
}
79+
```
80+
- A new `pipeArgs` input property is exposed by the `IgxColumnComponent`, which is used to pass arguments to the Angular `DatePipe` and `DecimalPipe`, to format the display for date and numeric columns.
81+
```typescript
4182
- ` IGX_INPUT_GROUP_TYPE` injection token
4283
- Allows for setting an input group `type` on a global level, so all input-group instances, including components using such an instance as a template will have their input group type set to the one specified by the token. It can be overridden on a component level by explicitly setting a `type`.
4384
- ` IgxExcelExporterService`
@@ -50,10 +91,26 @@ All notable changes for each version of this project will be documented in this
5091
- `IgxOverlay`
5192
- The `PositionSettings` `target` property has been deprecated and moved to `OverlaySettings`.
5293
- An optional Point/HTML Element parameter `target` has been added to the `position()` method
94+
- Added `createAbsoluteOverlaySettings` and `createRelativeOverlaySettings` methods which create non-modal `OverlaySettings` based on predefined `PositionSettings`. The methods are exposed off the `IgxOverlayService`.
95+
- `createAbsoluteOverlaySettings` creates non-modal `OverlaySettings` with `GlobalPositionStrategy` or `ContainerPositionStrategy` if an outlet is provided. Accepts `AbsolutePosition` enumeration, which could be `Center`, `Top` and `Bottom`. Default is `Center`.
96+
```typescript
97+
const globalOverlaySettings = IgxOverlayService.createAbsoluteOverlaySettings(AbsolutePosition.Top);
98+
```
99+
- `createRelativeOverlaySettings` creates `OverlaySettings` with `AutoPositionStrategy`, `ConnectedPositioningStrategy` or `ElasticPositionStrategy`. Accepts target, strategy and position. The `target` is the attaching point or element for the component to show. The position strategy is a `RelativePositionStrategy` enumeration, which defaults to `Auto`. The position is a `RelativePosition` enumeration. Possible values are `Above`, `Below`, `Before`, `After` and `Default`. The default option is `Default`, which positions the element below the target, left aligned.
100+
```typescript
101+
const targetElement = this.button.nativeElement;
102+
const connectedOverlaySettings = IgxOverlayService.createRelativeOverlaySettings(
103+
targetElement,
104+
RelativePositionStrategy.Connected,
105+
RelativePosition.Above);
106+
```
53107
- `IgxToast`
54108
- The component now utilizes the `IgxOverlayService` to position itself in the DOM.
55109
- An additional input property `outlet` has been added to allow users to specify custom Overlay Outlets using the `IgxOverlayOutletDirective`;
56110
- The `position` property now accepts values of type `IgxToastPosition` that work with strict templates.
111+
- `IgxExpansionPanelHeader`
112+
- `onInteraction` is now cancelable
113+
- Added `iconRef` property. This can be used to get a reference to the displayed expand/collapsed indicator. Returns `null` if `iconPosition` is set to `NONE`.
57114

58115
## 10.1.0
59116

package-lock.json

Lines changed: 46 additions & 7 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@
5252
"@angular/platform-browser": "^10.1.0",
5353
"@angular/platform-browser-dynamic": "^10.1.0",
5454
"@angular/router": "^10.1.0",
55-
"@igniteui/material-icons-extended": "^2.3.0",
55+
"@igniteui/material-icons-extended": "^2.4.0",
5656
"@types/hammerjs": "^2.0.36",
5757
"@types/source-map": "0.5.2",
5858
"classlist.js": "^1.1.20150312",
@@ -61,6 +61,7 @@
6161
"igniteui-trial-watermark": "^1.0.3",
6262
"jszip": "^3.5.0",
6363
"lodash.merge": "^4.6.2",
64+
"uuid": "^8.3.0",
6465
"resize-observer-polyfill": "^1.5.1",
6566
"rxjs": "^6.6.3",
6667
"setimmediate": "^1.0.5",

projects/igniteui-angular/migrations/common/UpdateChanges.spec.ts

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -390,7 +390,7 @@ describe('UpdateChanges', () => {
390390
});
391391
spyOn<any>(fs, 'readFileSync').and.callFake(() => JSON.stringify(classJson));
392392

393-
const fileContent =
393+
let fileContent =
394394
`import { Size, Type as someThg } from "igniteui-angular";
395395
import { IgxService, IgxDiffService as eDiffService, Calendar as Calendar } from 'igniteui-angular';
396396
import { Type } from "@angular/core";
@@ -411,7 +411,7 @@ export class Test {
411411
expect(update.getClassChanges()).toEqual(classJson);
412412

413413
update.applyChanges();
414-
expect(appTree.readContent('test.component.ts')).toEqual(
414+
let expectedFileContent =
415415
`import { IgxSize, IgxType as someThg } from "igniteui-angular";
416416
import { IgxService1, IgxNewDiffService as eDiffService, CalendarActual as Calendar } from 'igniteui-angular';
417417
import { Type } from "@angular/core";
@@ -423,8 +423,15 @@ export class Test {
423423
cal: Calendar;
424424
425425
constructor (public router: Router, private _iconService: IgxService1) {}
426-
}`
427-
);
426+
}`;
427+
expect(appTree.readContent('test.component.ts')).toEqual(expectedFileContent);
428+
429+
// with ig feed package:
430+
fileContent = fileContent.replace(/igniteui-angular/g, '@infragistics/igniteui-angular');
431+
expectedFileContent = expectedFileContent.replace(/igniteui-angular/g, '@infragistics/igniteui-angular');
432+
appTree.overwrite('test.component.ts', fileContent);
433+
update.applyChanges();
434+
expect(appTree.readContent('test.component.ts')).toEqual(expectedFileContent);
428435
});
429436

430437
it('should move property value between element tags', done => {

projects/igniteui-angular/migrations/common/UpdateChanges.ts

Lines changed: 31 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,21 @@
1-
import { SchematicContext, Tree, FileVisitor } from '@angular-devkit/schematics';
2-
import { WorkspaceSchema } from '@schematics/angular/utility/workspace-models';
3-
41
import * as fs from 'fs';
52
import * as path from 'path';
3+
import * as ts from 'typescript';
64
import * as tss from 'typescript/lib/tsserverlibrary';
5+
import { SchematicContext, Tree, FileVisitor } from '@angular-devkit/schematics';
6+
import { WorkspaceSchema } from '@schematics/angular/utility/workspace-models';
77
import {
88
ClassChanges, BindingChanges, SelectorChange,
99
SelectorChanges, ThemePropertyChanges, ImportsChanges, MemberChanges
1010
} from './schema';
1111
import {
1212
getLanguageService, getRenamePositions, findMatches,
13-
replaceMatch, createProjectService, isMemberIgniteUI
13+
replaceMatch, createProjectService, isMemberIgniteUI, NG_LANG_SERVICE_PACKAGE_NAME
1414
} from './tsUtils';
15-
import { getProjectPaths, getWorkspace, getProjects, escapeRegExp } from './util';
15+
import {
16+
getProjectPaths, getWorkspace, getProjects, escapeRegExp,
17+
getPackageManager, canResolvePackage, tryInstallPackage, tryUninstallPackage
18+
} from './util';
1619
import { ServerHost } from './ServerHost';
1720

1821
export enum InputPropertyType {
@@ -82,14 +85,23 @@ export class UpdateChanges {
8285
return this._sassFiles;
8386
}
8487

85-
private _service: tss.LanguageService;
86-
public get service(): tss.LanguageService {
88+
private _service: ts.LanguageService;
89+
public get service(): ts.LanguageService {
8790
if (!this._service) {
8891
this._service = getLanguageService(this.tsFiles, this.host);
8992
}
9093
return this._service;
9194
}
9295

96+
private _packageManager: 'npm' | 'yarn';
97+
private get packageManager(): 'npm' | 'yarn' {
98+
if (!this._packageManager) {
99+
this._packageManager = getPackageManager(this.host);
100+
}
101+
102+
return this._packageManager;
103+
}
104+
93105
/**
94106
* Create a new base schematic to apply changes
95107
* @param rootPath Root folder for the schematic to read configs, pass __dirname
@@ -111,16 +123,27 @@ export class UpdateChanges {
111123

112124
/** Apply configured changes to the Host Tree */
113125
public applyChanges() {
126+
const shouldInstallPkg = this.membersChanges && this.membersChanges.changes.length
127+
&& !canResolvePackage(NG_LANG_SERVICE_PACKAGE_NAME);
128+
if (shouldInstallPkg) {
129+
this.context.logger.info(`Installing temporary migration dependencies via ${this.packageManager}.`);
130+
tryInstallPackage(this.context, this.packageManager, NG_LANG_SERVICE_PACKAGE_NAME);
131+
}
132+
114133
this.updateTemplateFiles();
115134
this.updateTsFiles();
116135
this.updateMembers();
117-
118136
/** Sass files */
119137
if (this.themePropsChanges && this.themePropsChanges.changes.length) {
120138
for (const entryPath of this.sassFiles) {
121139
this.updateThemeProps(entryPath);
122140
}
123141
}
142+
143+
if (shouldInstallPkg) {
144+
this.context.logger.info(`Cleaning up temporary migration dependencies.`);
145+
tryUninstallPackage(this.context, this.packageManager, NG_LANG_SERVICE_PACKAGE_NAME);
146+
}
124147
}
125148

126149
/** Add condition function. */

0 commit comments

Comments
 (0)