-
Notifications
You must be signed in to change notification settings - Fork 378
feat(accordion): Add accordion to pf #1511
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
Conversation
3f7d31c to
b108c4a
Compare
bc0e1e6 to
3eaad26
Compare
|
Rebase on latest master to fix CircleCI errors and get a deploy preview. |
3eaad26 to
065c04c
Compare
Codecov Report
@@ Coverage Diff @@
## master #1511 +/- ##
==========================================
+ Coverage 82.74% 82.78% +0.03%
==========================================
Files 601 608 +7
Lines 6647 6696 +49
Branches 72 76 +4
==========================================
+ Hits 5500 5543 +43
- Misses 1120 1123 +3
- Partials 27 30 +3
Continue to review full report at Codecov.
|
packages/patternfly-4/react-core/src/components/Accordion/AccordionToggle.js
Show resolved
Hide resolved
packages/patternfly-4/react-core/src/components/Accordion/AccordionItem.js
Outdated
Show resolved
Hide resolved
065c04c to
245bfd6
Compare
packages/patternfly-4/react-core/src/components/Accordion/AccordionContent.js
Outdated
Show resolved
Hide resolved
245bfd6 to
23baadf
Compare
|
CircleCI times out before it shows this, but there is this error that needs to be fixed that happens when building the docs locally @ibolton336 : Run |
packages/patternfly-4/react-core/src/components/Accordion/examples/SimpleAccordion.js
Outdated
Show resolved
Hide resolved
b27a356 to
111baa6
Compare
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.
@ibolton336 can you add the accordian wrapper to your PR? you will need to wait until master has updated to a later version of core.
.pf-c-accordion__expanded-content-body (child of .pf-c-accordion__expanded-content)
This is a change from core referenced in issue #1682
tlabaj
left a comment
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.
@ibolton336 The way the docs are being generated was recently changed, can you please rebase and move the examples into the MD file.
b3028ff to
9751033
Compare
9751033 to
bdce0b3
Compare
|
PatternFly-React preview: https://1511-pr-patternfly-react-patternfly.surge.sh |
|
I don't think that the behavior is quite right here. In a classic accordion control, only one panel is ever opened at a time. See the behavior of the PF3 Accordion component, for example: https://www.patternfly.org/pattern-library/widgets/#accordion Note here that opening a new panel closes the current one. That said, it could be useful to have both variations - one with simple collapsible panels as you have now and another withe the accordion behavior as described above. The other thing I questioned was the difference between the Simple and the Fixed accordion. My understanding is that the intent of the fixed accordion is that the height is constrained. So if the contents will not fit within the max height, a scrollbar will be exposed within the open panel to scroll the content. Is that also what you intended @mcoker ? |
|
@mcarrano Agreed re: having the option for both types of behavior. Re: the fixed examples, yep - looking at the pf3 fixed height accordion, this accordion is the same where the max height is defined on the expandable panel for an accordion item. In the PF3 examples, that max-height is 69px. In the PF4 component, looks like we went with 150px. Also the And when an item is expanded, we also need to add |
|
Some initial comments after a quick review...
The section headings that are expand/collapse buttons have Core does not include |
tlabaj
left a comment
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.
LGTM
What: closes #1387
Additional issues: