-
Notifications
You must be signed in to change notification settings - Fork 331
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
Right sidenav (alone or together with left one) and locked-open sidenav #47
Comments
The current implementation locks the sidenav at a fixed viewport width (greater than 850px, overridable through css/sass). When we have sass in the consuming app, you can just override The structure for a right sidebar would be identical to a left one: {{#paper-nav-container}}
{{#paper-content}}
{{!-- your content here --}}
{{/paper-content}}
{{#paper-sidenav classNames="md-sidenav-right md-whiteframe-z2" flex-layout="column" flex=true}}
{{!-- your sidenav content here --}}
{{/paper-sidenav}}
{{/paper-nav-container}} You can have two sidebars, yes. Just add it before The sidenav is the only component not ported from angular material. The reason is that they use a really complicated media query evaluation system and angular Hope it helped. |
Thanks, your clarification helped, and yes, your sidenav implementation is really clever, so little lines of code compared to the angular one ! |
@pixelhandler nailed it at https://github.com/pixelhandler/ember-off-canvas-components Sorry for always mentioning you, @pixelhandler. 😆 |
@miguelcobain cool, I'll checkout your adaptation (no need to be sorry). at the day job we use the off canvas component and have a really nice theme. so I'm interested in adding themes at some point. |
So I tried to keep the sidenavbar always open by overriding $locked-breakpoint. However It is not straightforward. If just importing ember-paper scss in the app style scss file, it is not possible to overwrite it. I assumed $locked-breakpoint is defined in the variables file, so if importing all components separately, I could just overwrite it after importing the variables files, but unfortunately $locked-breakpoint is defined in the paper-sidenav.scss, so I had to insert the whole paper-sidenav source, to make the overwrite effective. |
Doing @import 'ember-paper'; and after $locked-breakpoint: your value; doesn't work? |
No, unfortunately not. Does it work for you ? "broccoli-autoprefixer": "^2.1.0", |
Please update ember-paper to 0.0.20 and use this in your sass file: $locked-breakpoint: 450px;
@import 'ember-paper'; We need to assign values before importing ember-paper. Looks like this is the way to do it in sass. |
Is this possible ? The angular implementation does it, so I guess if the SCSS is partially borrowed from there, it should be doable.
The text was updated successfully, but these errors were encountered: