-
-
Notifications
You must be signed in to change notification settings - Fork 32.4k
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
[Doc] Convert LeftNav to use the new standard. #2507
Conversation
@@ -260,6 +369,30 @@ const LeftNav = React.createClass({ | |||
|
|||
warning(!(typeof this.props.onNavOpen === 'function'), | |||
'onNavOpen will be removed in favor of onRequestChange'); | |||
|
|||
warning(!this.props.header, |
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.
Would hasOwnProperty
be better that a negation?
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.
yup, it would!
done |
<RaisedButton | ||
label="Controlled LeftNav That Opens From Right" | ||
onTouchTap={this.handleToggle} /> | ||
<LeftNav width={450} openRight={true} open={this.state.open} > |
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.
450
or 400
is too much for a mobile phone.
I'm wondering, would 50%
works?
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.
hmmmm let me see if i can get that to work. good feature to have.
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.
@oliviertassinari
how would we handle the number returned by this
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.
We would need to make this number unitless. It could be px
or %
.
That's require some work. Same, we would have to use px
or %
for the transform3d property.
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.
What about reducing the width to something like 300 instead of 400 or 450 and address this %
later?
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.
alright. sure 😁
@oliviertassinari Is that ok? I wanted it to be noticeable, so I made it very small instead. |
onTouchTap={this.handleToggle} /> | ||
<LeftNav | ||
docked={false} | ||
width={400} |
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.
300?
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.
O.O I forgot about this. nice catch 👍 👍
@subjectix Feel free to squash down, I will merge 🎉. |
@oliviertassinari Didn't have the time, on it 😁 |
a439c89
to
23ee58b
Compare
@oliviertassinari I'll leave the merging to you, thanks 👍 👍 |
[Doc] Convert LeftNav to use the new standard.
are there some examples of using menuItems? but the code I'm using came from the docs site. I'm looking for a code example for an app bar with left navigation. I can see implementation of the components on your docs site, but can't see a master layout where it's used. |
Also addresses some other issues.
menuItems
( Closes LeftNav is still using old menu -- which will be deprecated soon #2491)LeftNav
(Closes Styling on LeftPanel #2499 and leftNav not correctly hidden when width modified #2270)@oliviertassinari Take a look 😁