mirror of
https://github.com/angular/angular.git
synced 2026-09-14 13:54:52 +08:00
chore(dialog): rename config to avoid name collisions (#5088)
This commit is contained in:
@@ -57,7 +57,7 @@ export function throwMdDialogContentAlreadyAttachedError() {
|
||||
],
|
||||
host: {
|
||||
'[class.mat-dialog-container]': 'true',
|
||||
'[attr.role]': 'config?.role',
|
||||
'[attr.role]': '_config?.role',
|
||||
'[@slideDialog]': '_state',
|
||||
'(@slideDialog.done)': '_onAnimationDone($event)',
|
||||
},
|
||||
@@ -76,7 +76,7 @@ export class MdDialogContainer extends BasePortalHost {
|
||||
private _document: Document;
|
||||
|
||||
/** The dialog configuration. */
|
||||
config: MdDialogConfig;
|
||||
_config: MdDialogConfig;
|
||||
|
||||
/** State of the dialog animation. */
|
||||
_state: 'void' | 'enter' | 'exit' = 'enter';
|
||||
|
||||
@@ -19,7 +19,7 @@ export class MdDialogRef<T> {
|
||||
componentInstance: T;
|
||||
|
||||
/** Whether the user is allowed to close the dialog. */
|
||||
disableClose: boolean = this._containerInstance.config.disableClose;
|
||||
disableClose: boolean = this._containerInstance._config.disableClose;
|
||||
|
||||
/** Subject for notifying the user that the dialog has finished closing. */
|
||||
private _afterClosed: Subject<any> = new Subject();
|
||||
|
||||
@@ -146,7 +146,7 @@ export class MdDialog {
|
||||
let containerPortal = new ComponentPortal(MdDialogContainer, viewContainer);
|
||||
|
||||
let containerRef: ComponentRef<MdDialogContainer> = overlay.attach(containerPortal);
|
||||
containerRef.instance.config = config;
|
||||
containerRef.instance._config = config;
|
||||
|
||||
return containerRef.instance;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user