Skip to content

Commit b2758e8

Browse files
committed
chore(*): cleanup ng 9 update
1 parent bc101ab commit b2758e8

File tree

11 files changed

+24
-23
lines changed

11 files changed

+24
-23
lines changed

projects/igniteui-angular/src/lib/calendar/calendar-base.ts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,10 @@ export enum ScrollMonth {
2020
NONE = 'none'
2121
}
2222

23-
@Directive()
24-
export class IgxCalendarBase implements ControlValueAccessor {
23+
@Directive({
24+
selector: '[igxCalendarBase]'
25+
})
26+
export class IgxCalendarBaseDirective implements ControlValueAccessor {
2527
/**
2628
* Gets the start day of the week.
2729
* Can return a numeric or an enum representation of the week day.

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

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ import {
2121
} from './calendar.directives';
2222
import { KEYS } from '../core/utils';
2323
import { ICalendarDate, monthRange } from './calendar';
24-
import { CalendarView, IgxMonthPickerBase } from './month-picker-base';
24+
import { CalendarView, IgxMonthPickerBaseDirective } from './month-picker-base';
2525
import { IgxMonthsViewComponent } from './months-view/months-view.component';
2626
import { IgxYearsViewComponent } from './years-view/years-view.component';
2727
import { IgxDaysViewComponent } from './days-view/days-view.component';
@@ -78,7 +78,7 @@ let NEXT_ID = 0;
7878
selector: 'igx-calendar',
7979
templateUrl: 'calendar.component.html'
8080
})
81-
export class IgxCalendarComponent extends IgxMonthPickerBase implements AfterViewInit, OnDestroy {
81+
export class IgxCalendarComponent extends IgxMonthPickerBaseDirective implements AfterViewInit, OnDestroy {
8282
/**
8383
* Sets/gets the `id` of the calendar.
8484
* If not set, the `id` will have value `"igx-calendar-0"`.

projects/igniteui-angular/src/lib/calendar/calendar.module.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,16 @@ import { IgxYearsViewComponent } from './years-view/years-view.component';
1515
import { IgxDaysViewComponent } from './days-view/days-view.component';
1616
import { IgxDayItemComponent } from './days-view/day-item.component';
1717
import { IgxMonthPickerComponent } from './month-picker/month-picker.component';
18+
import { IgxCalendarBaseDirective } from './calendar-base';
19+
import { IgxMonthPickerBaseDirective } from './month-picker-base';
1820

1921
/**
2022
* @hidden
2123
*/
2224
@NgModule({
2325
declarations: [
26+
IgxCalendarBaseDirective,
27+
IgxMonthPickerBaseDirective,
2428
IgxDayItemComponent,
2529
IgxDaysViewComponent,
2630
IgxCalendarComponent,

projects/igniteui-angular/src/lib/calendar/days-view/days-view.component.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ import { ICalendarDate, isDateInRanges } from '../../calendar/calendar';
1414
import { NG_VALUE_ACCESSOR } from '@angular/forms';
1515
import { IgxDayItemComponent } from './day-item.component';
1616
import { DateRangeDescriptor, DateRangeType } from '../../core/dates';
17-
import { IgxCalendarBase, CalendarSelection } from '../calendar-base';
17+
import { IgxCalendarBaseDirective, CalendarSelection } from '../calendar-base';
1818
import { isEqual } from '../../core/utils';
1919
import { IViewChangingEventArgs } from './days-view.interface';
2020
import { IgxDaysViewNavigationService } from './daysview-navigation.service';
@@ -33,7 +33,7 @@ let NEXT_ID = 0;
3333
selector: 'igx-days-view',
3434
templateUrl: 'days-view.component.html'
3535
})
36-
export class IgxDaysViewComponent extends IgxCalendarBase implements DoCheck, OnInit {
36+
export class IgxDaysViewComponent extends IgxCalendarBaseDirective implements DoCheck, OnInit {
3737
/**
3838
* Sets/gets the `id` of the days view.
3939
* If not set, the `id` will have value `"igx-days-view-0"`.

projects/igniteui-angular/src/lib/calendar/month-picker-base.ts

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { IgxCalendarBase } from './calendar-base';
1+
import { IgxCalendarBaseDirective } from './calendar-base';
22
import { ViewChild, ElementRef, HostBinding, Directive } from '@angular/core';
33
import { KEYS } from '../core/utils';
44

@@ -10,8 +10,10 @@ export enum CalendarView {
1010
YEAR,
1111
DECADE
1212
}
13-
@Directive()
14-
export class IgxMonthPickerBase extends IgxCalendarBase {
13+
@Directive({
14+
selector: '[igxMonthPickerBase]'
15+
})
16+
export class IgxMonthPickerBaseDirective extends IgxCalendarBaseDirective {
1517

1618
/**
1719
* @hidden

projects/igniteui-angular/src/lib/calendar/month-picker/month-picker.component.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import { trigger, transition, useAnimation } from '@angular/animations';
1010
import { fadeIn, scaleInCenter, slideInLeft, slideInRight } from '../../animations/main';
1111
import { KEYS } from '../../core/utils';
1212
import { IgxMonthsViewComponent } from '../months-view/months-view.component';
13-
import { IgxMonthPickerBase, CalendarView } from '../month-picker-base';
13+
import { IgxMonthPickerBaseDirective, CalendarView } from '../month-picker-base';
1414
import { IgxYearsViewComponent } from '../years-view/years-view.component';
1515
import { IgxDaysViewComponent } from '../days-view/days-view.component';
1616

@@ -49,7 +49,7 @@ let NEXT_ID = 0;
4949
selector: 'igx-month-picker',
5050
templateUrl: 'month-picker.component.html'
5151
})
52-
export class IgxMonthPickerComponent extends IgxMonthPickerBase {
52+
export class IgxMonthPickerComponent extends IgxMonthPickerBaseDirective {
5353
/**
5454
* Sets/gets the `id` of the month picker.
5555
* If not set, the `id` will have value `"igx-month-picker-0"`.

projects/igniteui-angular/src/lib/core/navigation/nav.service.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { IToggleView } from './IToggleView';
2-
import { Injectable } from "@angular/core";
2+
import { Injectable } from '@angular/core';
33

44
/**
55
* Common service to be injected between components where those implementing common

projects/igniteui-angular/src/lib/grids/hierarchical-grid/row-island-api.service.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import { IgxHierarchicalGridComponent } from './hierarchical-grid.component';
22
import { IgxRowIslandComponent } from './row-island.component';
33
import { Subject } from 'rxjs';
4-
import { Injectable } from "@angular/core";
4+
import { Injectable } from '@angular/core';
55

66
@Injectable()
77
export class IgxRowIslandAPIService {

projects/igniteui-angular/src/lib/grids/tree-grid/tree-grid-api.service.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import { IRowToggleEventArgs } from './tree-grid.interfaces';
66
import { IgxColumnComponent } from '../columns/column.component';
77
import { HierarchicalTransaction, TransactionType, State } from '../../services';
88
import { mergeObjects } from '../../core/utils';
9-
import { Injectable } from "@angular/core";
9+
import { Injectable } from '@angular/core';
1010

1111
@Injectable()
1212
export class IgxTreeGridAPIService extends GridBaseAPIService<IgxTreeGridComponent> {

projects/igniteui-angular/src/lib/grids/tree-grid/tree-grid-navigation.service.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { IgxGridNavigationService } from '../grid-navigation.service';
2-
import { Injectable } from "@angular/core";
2+
import { Injectable } from '@angular/core';
33

44
@Injectable()
55
export class IgxTreeGridNavigationService extends IgxGridNavigationService {

0 commit comments

Comments
 (0)