Skip to content
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

[New Nav Feature] Move collapsible nav toggle button to be part of EuiCollapsibleNav #3168

Conversation

cchaos
Copy link
Contributor

@cchaos cchaos commented Mar 25, 2020

Better for accessibility

Instead of forcing the consumer to remember all the aria- bits that the toggle button needs, the EuiCollapsibleNav component now behaves similar to the EuiPopover component where it accepts a button and isOpen props.

It can then also handle the visibility of the button when docked internally.

Checklist

  • Check against all themes for compatibility in both light and dark modes
  • Checked in mobile
  • Checked in IE11 and Firefox
  • Props have proper autodocs
  • Updated documentation examples
  • Added or updated jest tests
  • [ ] Checked for breaking changes and labeled appropriately
  • Checked for accessibility including keyboard-only and screenreader modes
  • [ ] A changelog entry exists and is marked appropriately

@kibanamachine
Copy link

Preview documentation changes for this PR: https://eui.elastic.co/pr_3168/

@cchaos cchaos requested review from myasonik and thompsongl March 25, 2020 21:57
@cchaos
Copy link
Contributor Author

cchaos commented Mar 25, 2020

@myasonik Unfortunately, I can't fix the return focus to the toggle button in this PR. It's a problem with EuiFocusTrap. I created this issue to track: #3170

@myasonik
Copy link
Contributor

Do you still want to make this change then?

@cchaos
Copy link
Contributor Author

cchaos commented Mar 25, 2020

Yes because at the very least it allows us to control the aria-labels for the toggle button and anything else that might be drummed up in implementation.

Copy link
Contributor

@myasonik myasonik left a comment

Choose a reason for hiding this comment

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

LGTM! One small change that's not even directly related to this work...

src/components/collapsible_nav/collapsible_nav.tsx Outdated Show resolved Hide resolved
@kibanamachine
Copy link

Preview documentation changes for this PR: https://eui.elastic.co/pr_3168/

@cchaos cchaos mentioned this pull request Mar 26, 2020
8 tasks
@kibanamachine
Copy link

Preview documentation changes for this PR: https://eui.elastic.co/pr_3168/

@ryankeairns ryankeairns self-requested a review March 26, 2020 15:49
Copy link
Contributor

@ryankeairns ryankeairns left a comment

Choose a reason for hiding this comment

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

Text looks good, ty!

Copy link
Contributor

@thompsongl thompsongl left a comment

Choose a reason for hiding this comment

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

LGTM!

src/components/collapsible_nav/collapsible_nav.tsx Outdated Show resolved Hide resolved
Co-Authored-By: Greg Thompson <thompson.glowe@gmail.com>
@kibanamachine
Copy link

Preview documentation changes for this PR: https://eui.elastic.co/pr_3168/

@cchaos cchaos merged commit 16518ef into elastic:feature/collapsible_nav Mar 26, 2020
@cchaos cchaos deleted the into-feature/collapsible_nav_toggle branch March 26, 2020 20:53
cchaos added a commit that referenced this pull request Mar 26, 2020
…iCollapsibleNav (#3168)

* Move collapsible nav toggle button to be part of EuiCollapsibleNav
* No role group
* Alterations to top links and added `pinnable` prop to pinnable list items
cchaos added a commit that referenced this pull request Mar 27, 2020
* [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)
elizabetdev pushed a commit to elizabetdev/eui that referenced this pull request Mar 30, 2020
* [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)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants