-
Notifications
You must be signed in to change notification settings - Fork 6.8k
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
feat(dialog): add afterOpen to MdDialogRef #6887
Conversation
Provides a hook for initializing component after animation is complete.
src/lib/dialog/dialog-ref.ts
Outdated
RxChain.from(_containerInstance._animationStateChanged) | ||
.call(filter, event => event.phaseName === 'done' && event.toState === 'enter') | ||
.call(first) | ||
.subscribe(() => this._afterOpen.next()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also complete
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah yep, fixed
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
/** Subject for notifying the user that the dialog has finished closing. */ | ||
private _afterClosed: Subject<any> = new Subject(); | ||
private _afterClosed = new Subject<any>(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These subjects should be Subject<void>
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don't they carry the close value of the dialog?
* feat(dialog): add afterOpen to MdDialogRef Provides a hook for initializing component after animation is complete. * Complete afterOpen observable
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
Provides a hook for initializing component after animation is
complete.
Relates to #3616 (comment).