Class Accordion
java.lang.Object
org.patternfly.component.BaseComponent<HTMLElement,Accordion>
org.patternfly.component.accordion.Accordion
- All Implemented Interfaces:
Iterable<AccordionItem>
,Attachable
,Container<HTMLElement,
,Accordion> Finder<HTMLElement>
,HasElement<HTMLElement,
,Accordion> HasHTMLElement<HTMLElement,
,Accordion> IsElement<HTMLElement>
,TypedBuilder<HTMLElement,
,Accordion> Component
,HasItems<HTMLElement,
,Accordion, AccordionItem> Modifiers.Bordered<HTMLElement,
Accordion>
public class Accordion
extends BaseComponent<HTMLElement,Accordion>
implements Modifiers.Bordered<HTMLElement,Accordion>, HasItems<HTMLElement,Accordion,AccordionItem>, Attachable
An accordion is an interactive container that expands and collapses to hide or reveal nested content. It takes advantage of
progressive disclosure to help reduce page scrolling, by allowing users to choose whether they want to show or hide more
detailed information as needed.
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionstatic Accordion
Creates a new Accordion instance backed by a<p> <dl/>
.static Accordion
accordion
(boolean definitionList) add
(AccordionItem item) void
attach
(MutationRecord mutationRecord) void
clear()
void
void
void
void
fixed()
Same as fixed(true)fixed
(boolean fixed) Flag to indicate Accordion content is fixedheadingLevel
(int headingLevel) boolean
isEmpty()
iterator()
large()
Same as large(true)large
(boolean large) Adds/removes modifier(large, lg)onToggle
(ToggleHandler<AccordionItem> toggleHandler) Same as singleExpand(true)singleExpand
(boolean singleExpand) Whether only oneAccordionItem
can be expandedint
size()
that()
Methods inherited from class org.patternfly.component.BaseComponent
componentType, element
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.jboss.elemento.Attachable
detach
Methods inherited from interface org.jboss.elemento.Container
add, add, add, addAll, addAll, addAll, addAll, addAll, addAll
Methods inherited from interface org.jboss.elemento.HasElement
add, apply, aria, aria, aria, attr, attr, attr, classList, classList, css, id, innerHtml, on, on, on, run, textContent, textNode, toggle, toggle, toggle, uniqueId
Methods inherited from interface org.jboss.elemento.HasHTMLElement
data, hidden, style, style, style, style, style, style, title
Methods inherited from interface java.lang.Iterable
forEach, spliterator
Methods inherited from interface org.patternfly.style.Modifiers.Bordered
bordered, bordered
-
Method Details
-
accordion
Creates a new Accordion instance backed by a<p> <dl/>
. -
accordion
-
attach
- Specified by:
attach
in interfaceAttachable
-
add
- Specified by:
add
in interfaceHasItems<HTMLElement,
Accordion, AccordionItem>
-
fixed
Same as fixed(true) -
fixed
Flag to indicate Accordion content is fixed -
large
Same as large(true) -
large
Adds/removes modifier(large, lg) -
singleExpand
Same as singleExpand(true) -
singleExpand
Whether only oneAccordionItem
can be expanded -
headingLevel
-
that
- Specified by:
that
in interfaceTypedBuilder<HTMLElement,
Accordion>
-
onToggle
-
collapse
-
collapse
-
expand
-
expand
-
iterator
- Specified by:
iterator
in interfaceIterable<AccordionItem>
-
size
public int size()- Specified by:
size
in interfaceHasItems<HTMLElement,
Accordion, AccordionItem>
-
isEmpty
public boolean isEmpty()- Specified by:
isEmpty
in interfaceHasItems<HTMLElement,
Accordion, AccordionItem>
-
clear
public void clear()- Specified by:
clear
in interfaceHasItems<HTMLElement,
Accordion, AccordionItem>
-