[Feature] Added EuiCollapsibleNav component#2977
[Feature] Added EuiCollapsibleNav component#2977cchaos merged 7 commits intoelastic:feature/collapsible_navfrom
EuiCollapsibleNav component#2977Conversation
|
@myasonik What kind of @thompsongl Is there any way to add tests for the responsive behavior? Can it mock setting the window to a certain size? |
|
Preview documentation changes for this PR: https://eui.elastic.co/pr_2977/ |
snide
left a comment
There was a problem hiding this comment.
Some smaller stuff I noticed. Couple questions.
myasonik
left a comment
There was a problem hiding this comment.
When undocking the nav, I was surprised when the nav was still open. What do you think about closing the nav when undocked?
The current behavior is how it was working during the Usability tests. We didn't hear any feedback specifically on this interaction so I'm not inclined to change it. |
|
I should also mention that the example for CollapsibleNav is not complete. It will get fleshed out with all the other inner content, but for now I'm just trying to nail the actual "drawer" part. |
I'm not sure that any https://gist.github.com/thompsongl/cec1e5be12078ff9e56dc78296b88e27 |
Also added a `close` button
|
Ok the component has been updated to not render a EuiFlyout, but just reuses some styles and copies some functionality over. I addressed (most) of the other comments as well. I also added a visable "close" button (though I supposed we could make it a accessibleOnFocus element instead). |
|
Preview documentation changes for this PR: https://eui.elastic.co/pr_2977/ |
|
Is there any way to have the portal render at the start of the document for when rendering the docked version of the nav? Having it at the end of the document, I think, is pretty confusing from a tab order perspective. |
snide
left a comment
There was a problem hiding this comment.
My issues were addressed and I did a quick code review of the new restructuring. I'd suggest like DataGrid, setting up a PR for the feature branch merge (in draft mode) and then keeping links to these sub PRs in that PR. That way you'll have a nice reference when you need to write your CL.
We don't often use extends, but looks OK here. Mixing might be better so you can pass stuff to it eventually. Very small comment though.
The component does not live in a portal. It's DOM will get inserted wherever you place the component. The example in the EUI docs is at the tail end of the DOM structure so that's where it gets rendered. |
Yep, I have to have new commits in the branch before Github allows me to create a PR, so I need this one in first. |
thompsongl
left a comment
There was a problem hiding this comment.
LGTM; works as expected
EuiCollapsibleNav componentEuiCollapsibleNav component
* Setting up file structure * Added EuiFlyout to render, moved to left, and added docking * mock euioverlaymask * Better docs for EuiCollapsibleNav * Cleanup css * Adding responsive behavior * No longer using EuiFlyout directly * added a `close` button
* Setting up file structure * Added EuiFlyout to render, moved to left, and added docking * mock euioverlaymask * Better docs for EuiCollapsibleNav * Cleanup css * Adding responsive behavior * No longer using EuiFlyout directly * added a `close` button
* Setting up file structure * Added EuiFlyout to render, moved to left, and added docking * mock euioverlaymask * Better docs for EuiCollapsibleNav * Cleanup css * Adding responsive behavior * No longer using EuiFlyout directly * added a `close` button
* [Feature] Added `EuiCollapsibleNav` component (#2977) * [New Nav Feature] Added `ghost` colored EuiListGroupItem (#3018) * [New Nav Feature] Created `EuiCollapsibleGroup` (#3031) * [New Nav Feature] EuiPinnableListGroup (#3061) * [K8 Nav Feature] Added `home` and `menu` glyphs to EuiIcon (#3109) * [New Nav Feature] Final docs examples and patterns (#3117) * [New Nav Feature] Move collapsible nav toggle button to be part of EuiCollapsibleNav (#3168)
* [Feature] Added `EuiCollapsibleNav` component (elastic#2977) * [New Nav Feature] Added `ghost` colored EuiListGroupItem (elastic#3018) * [New Nav Feature] Created `EuiCollapsibleGroup` (elastic#3031) * [New Nav Feature] EuiPinnableListGroup (elastic#3061) * [K8 Nav Feature] Added `home` and `menu` glyphs to EuiIcon (elastic#3109) * [New Nav Feature] Final docs examples and patterns (elastic#3117) * [New Nav Feature] Move collapsible nav toggle button to be part of EuiCollapsibleNav (elastic#3168)
Feature branch
This is the primary container for the new EuiCollapsibleNav component. It doesn't do much but
dockedability, andBasic flyout behavior
Responsive behavior with docking
Checklist
[ ] Checked for breaking changes and labeled appropriately[ ] A changelog entry exists and is marked appropriatelyWill be added via the Feature Branch