[New Nav Feature] Created EuiCollapsibleGroup#3031
[New Nav Feature] Created EuiCollapsibleGroup#3031cchaos merged 16 commits intoelastic:feature/collapsible_navfrom
EuiCollapsibleGroup#3031Conversation
+1 |
|
Preview documentation changes for this PR: https://eui.elastic.co/pr_3031/ |
|
Preview documentation changes for this PR: https://eui.elastic.co/pr_3031/ |
src/components/collapsible_nav/collapsible_nav_group/collapsible_nav_group.tsx
Show resolved
Hide resolved
src/components/collapsible_nav/collapsible_nav_group/collapsible_nav_group.tsx
Show resolved
Hide resolved
src/components/collapsible_nav/collapsible_nav_group/collapsible_nav_group.tsx
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Only bit I noticed was collapsable spitting out some weirdness in the autodocs. Note reads well enough though.
Yeah this happens when a prop is technically a boolean, but depending on it's value requires another prop or extends another type. Hopefully that'll all get fixed via GSOC 😏
src/components/collapsible_nav/collapsible_nav_group/collapsible_nav_group.tsx
Outdated
Show resolved
Hide resolved
|
Preview documentation changes for this PR: https://eui.elastic.co/pr_3031/ |
thompsongl
left a comment
There was a problem hiding this comment.
Looking good; just a couple requests.
src/components/collapsible_nav/collapsible_nav_group/collapsible_nav_group.test.tsx
Outdated
Show resolved
Hide resolved
src/components/collapsible_nav/collapsible_nav_group/collapsible_nav_group.tsx
Outdated
Show resolved
Hide resolved
src/components/collapsible_nav/collapsible_nav_group/collapsible_nav_group.tsx
Outdated
Show resolved
Hide resolved
src/components/collapsible_nav/collapsible_nav_group/collapsible_nav_group.tsx
Outdated
Show resolved
Hide resolved
|
Preview documentation changes for this PR: https://eui.elastic.co/pr_3031/ |
* Added `EuiCollapsibleNavGroup` component * Initial render of nav group * Adding background color options * Fixing more colors * Added `collapsible` prop * cleanup * remove slugify * Added `titleSize` and `titleElement` to groups and better docs * better docs * snaps * doc cleanoup * Fixing contrast of focus state of dark bg * specific classname target * Using EuiTitle and sizing to wrap title * `collapsible` -> `isCollapsible` * Fixing `id` as state and exporting proper Prop types
* Added `EuiCollapsibleNavGroup` component * Initial render of nav group * Adding background color options * Fixing more colors * Added `collapsible` prop * cleanup * remove slugify * Added `titleSize` and `titleElement` to groups and better docs * better docs * snaps * doc cleanoup * Fixing contrast of focus state of dark bg * specific classname target * Using EuiTitle and sizing to wrap title * `collapsible` -> `isCollapsible` * Fixing `id` as state and exporting proper Prop types
* Added `EuiCollapsibleNavGroup` component * Initial render of nav group * Adding background color options * Fixing more colors * Added `collapsible` prop * cleanup * remove slugify * Added `titleSize` and `titleElement` to groups and better docs * better docs * snaps * doc cleanoup * Fixing contrast of focus state of dark bg * specific classname target * Using EuiTitle and sizing to wrap title * `collapsible` -> `isCollapsible` * Fixing `id` as state and exporting proper Prop types
* [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)

EuiCollapsibleGroup
This is the accordion style grouping that will make up these three portions:
The contents of the group doesn't matter, hence the scribbles
Instead of trying to create 3 components, I made one that is child-agnostic and can be an accordion via
collapsible=trueor not. Consumers can also add a header withtitleandiconType. They can also choose the background color.Accessibility
Since it does wrap the EuiAccordion when
collapsible=true, if there's any a11y needs for that specifically, we should do it in EuiAccordion and make an issue for that.The one thing I had to deal with is the focus states of the
darkbackground accordion toggle arrow were hard to see. So I forced a different focus ring color with overrides.Dark mode
In dark mode, they all just get different shades of dark that aren't that noticeable from each other. 🤷♀
Checklist
[ ] Checked for breaking changes and labeled appropriately[ ] A changelog entry exists and is marked appropriatelyWill be added to feature PR