-
Notifications
You must be signed in to change notification settings - Fork 6.7k
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
Sidenav - .mat-sidenav-opened is not being applied after switching mode from side to over #6062
Comments
You should be querying |
@willshowell for Sometimes it is necessary to have classes in parent elements, not in children. |
Oh I see, thanks for clarifying! Looks like it only subscribes at the beginning and only if https://github.com/angular/material2/blob/master/src/lib/sidenav/sidenav.ts#L415-L418 |
fixed by #6712 |
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. |
Bug, feature request, or proposal:
Bug
What is the expected behavior?
Class
mat-sidenav-opened
should be added to<md-sidenav-container>
in modeover
(or perhaps for all modes?).What is the current behavior?
The class is not being added if the component was initialized with
side
mode and then switched toover
.What are the steps to reproduce?
Providing a Plunker (or similar) is the best way to get the team to see your issue.
Plunker template: https://plnkr.co/edit/GmUshVTgSxCXe1gcruXx?p=preview
What is the use-case or motivation for changing an existing behavior?
When changing size of the screen (e.g. rotating device) it is useful to change mode between
side
andover
. Classmat-sidenav-opened
is also useful as it tells when side-nav is closed and animation completed.Which versions of Angular, Material, OS, TypeScript, browsers are affected?
Browser: Chrome
@angular/cli: 1.2.0
node: 8.0.0
os: win32 x64
@angular/animations: 4.3.1
@angular/cdk: 2.0.0-beta.8
@angular/common: 4.3.1
@angular/compiler: 4.3.1
@angular/core: 4.3.1
@angular/forms: 4.3.1
@angular/http: 4.3.1
@angular/material: 2.0.0-beta.8
@angular/platform-browser: 4.3.1
@angular/platform-browser-dynamic: 4.3.1
@angular/platform-server: 4.3.1
@angular/router: 4.3.1
@angular/cli: 1.2.0
@angular/compiler-cli: 4.3.1
@angular/language-service: 4.3.1
The text was updated successfully, but these errors were encountered: