Skip to content

Conversation

@crisbeto
Copy link
Member

@crisbeto crisbeto commented Sep 13, 2017

Fixes the drawer container not reacting if one of the drawers is destroyed.

Fixes #6271.

@crisbeto crisbeto requested a review from mmalerba as a code owner September 13, 2017 19:53
@googlebot googlebot added the cla: yes PR author has agreed to Google's Contributor License Agreement label Sep 13, 2017
@crisbeto crisbeto force-pushed the 6271/drawer-state-changes branch from e5c6ce2 to faabcd1 Compare September 13, 2017 20:03
@Output('positionChanged') onPositionChanged = new EventEmitter<void>();

/** Event emitted when the drawer's mode changes. */
@Output('modeChanged') onModeChanged = new EventEmitter<void>();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

since this is really just for internal coordination, can we make it a Subject with no @Output() and _ name?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sure, I did this to keep it consistent with the positionChanged.

@crisbeto crisbeto force-pushed the 6271/drawer-state-changes branch from faabcd1 to d816484 Compare September 13, 2017 20:53
@crisbeto
Copy link
Member Author

Addressed the feedback @mmalerba.

@mmalerba
Copy link
Contributor

@crisbeto I think this was mostly addressed by #6712 although I think there are some small differences in how we implemented it, you're welcome to take a look and see if there's anything you'd change about how I did it.

@crisbeto
Copy link
Member Author

crisbeto commented Sep 26, 2017

@mmalerba I just tried throwing in the unit tests from this PR into master. It looks like your changes fixed one of the issues, but they still don't handle the case where a drawer is destroyed so I'd say it's worth keeping this PR around.

@crisbeto crisbeto force-pushed the 6271/drawer-state-changes branch from d816484 to db61f29 Compare September 26, 2017 19:57
@crisbeto
Copy link
Member Author

crisbeto commented Sep 26, 2017

Rebased and scoped my changes only to the onDestroy behavior, @mmalerba can you take another look?

if (!this._drawers.length ||
this._isDrawerOpen(this._start) ||
this._isDrawerOpen(this._end)
) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

style nit: move to end of previous line

@mmalerba mmalerba changed the title fix(drawer): drawer container not reacting to drawer removal and mode change fix(drawer): drawer container not reacting to drawer removal Sep 26, 2017
@crisbeto crisbeto force-pushed the 6271/drawer-state-changes branch from db61f29 to 63b3191 Compare September 26, 2017 20:11
@crisbeto crisbeto added the action: merge The PR is ready for merge by the caretaker label Sep 26, 2017
@mmalerba mmalerba added the P2 The issue is important to a large percentage of users, with a workaround label Sep 27, 2017
Fixes the drawer container not reacting if one of the drawers is destroyed.

Fixes angular#6271.
@crisbeto crisbeto force-pushed the 6271/drawer-state-changes branch from 63b3191 to 8bd26dc Compare September 29, 2017 16:12
@andrewseguin andrewseguin merged commit b0b91f4 into angular:master Sep 29, 2017
@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Sep 7, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

action: merge The PR is ready for merge by the caretaker cla: yes PR author has agreed to Google's Contributor License Agreement P2 The issue is important to a large percentage of users, with a workaround

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[sidenav] container styles not updated after sidenav destroy or mode change

4 participants