Skip to content

refactor: mark injectable refs with @Injectable #15584

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 21, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions src/material/bottom-sheet/bottom-sheet-ref.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,17 @@
* found in the LICENSE file at https://angular.io/license
*/

import {Location} from '@angular/common';
import {ESCAPE} from '@angular/cdk/keycodes';
import {OverlayRef} from '@angular/cdk/overlay';
import {Location} from '@angular/common';
import {Injectable} from '@angular/core';
import {merge, Observable, Subject} from 'rxjs';
import {filter, take} from 'rxjs/operators';
import {MatBottomSheetContainer} from './bottom-sheet-container';


/**
* Reference to a bottom sheet dispatched from the bottom sheet service.
*/
/** Reference to a bottom sheet dispatched from the bottom sheet service. */
@Injectable()
export class MatBottomSheetRef<T = any, R = any> {
/** Instance of the component making up the content of the bottom sheet. */
instance: T;
Expand Down
6 changes: 3 additions & 3 deletions src/material/dialog/dialog-ref.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
import {ESCAPE} from '@angular/cdk/keycodes';
import {GlobalPositionStrategy, OverlayRef} from '@angular/cdk/overlay';
import {Location} from '@angular/common';
import {Injectable} from '@angular/core';
import {Observable, Subject} from 'rxjs';
import {filter, take} from 'rxjs/operators';
import {DialogPosition} from './dialog-config';
Expand All @@ -20,9 +21,8 @@ import {MatDialogContainer} from './dialog-container';
// Counter for unique dialog ids.
let uniqueId = 0;

/**
* Reference to a dialog opened via the MatDialog service.
*/
/** Reference to a dialog opened via the MatDialog service. */
@Injectable()
export class MatDialogRef<T, R = any> {
/** The instance of component opened into the dialog. */
componentInstance: T;
Expand Down
6 changes: 3 additions & 3 deletions src/material/snack-bar/snack-bar-ref.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
*/

import {OverlayRef} from '@angular/cdk/overlay';
import {Injectable} from '@angular/core';
import {Observable, Subject} from 'rxjs';
import {MatSnackBarContainer} from './snack-bar-container';

Expand All @@ -17,9 +18,8 @@ export interface MatSnackBarDismiss {
dismissedByAction: boolean;
}

/**
* Reference to a snack bar dispatched from the snack bar service.
*/
/** Reference to a snack bar dispatched from the snack bar service. */
@Injectable()
export class MatSnackBarRef<T> {
/** The instance of the component making up the content of the snack bar. */
instance: T;
Expand Down