Skip to main content
Parsley Design Systems logoParsley Design System - sample

Accordion

Examples

Default

Code

1<Accordion>
2 <AccordionItem label="Accordion Item 1">
3 <ContentStack>
4 <p>Integer tincidunt. Etiam sit amet orci eget eros faucibus tincidunt.</p>
5 <p>Integer tincidunt. Etiam sit amet orci eget eros faucibus tincidunt.</p>
6 </ContentStack>
7 </AccordionItem>
8 <AccordionItem label="Accordion Item 2">
9 <ContentStack>
10 <p>Integer tincidunt. Etiam sit amet orci eget eros faucibus tincidunt.</p>
11 <p>Integer tincidunt. Etiam sit amet orci eget eros faucibus tincidunt.</p>
12 </ContentStack>
13 </AccordionItem>
14 <AccordionItem label="Accordion Item 3">
15 <ContentStack>
16 <p>Integer tincidunt. Etiam sit amet orci eget eros faucibus tincidunt.</p>
17 <p>Integer tincidunt. Etiam sit amet orci eget eros faucibus tincidunt.</p>
18 </ContentStack>
19 </AccordionItem>
20</Accordion>

Maximum width set

Code

1<Accordion maxWidth="60%">
2 ...
3</Accordion>

Accordion item open by default

Code

1<Accordion maxWidth="60%">
2 ...
3 <AccordionItem label="Accordion Item 2" open>
4 ...
5 </AccordionItem>
6 ...
7</Accordion>

Background of button

Secondary

Tertiary

Code

1<Accordion background="secondary">
2 ...
3</Accordion>
4
5<Accordion background="tertiary">
6 ...
7</Accordion>

Size

Code

1<Accordion size="small">
2 ...
3</Accordion>
4
5<Accordion>
6 ...
7</Accordion>
8
9<Accordion size="large">
10 ...
11</Accordion>
12
13<Accordion size="xlarge">
14 ...
15</Accordion>

Borderless

Code

1<Accordion border={false}>
2 ...
3</Accordion>