Skip to content
PixiKit

Plus Accordion

A list of questions that open in place. The plus at the end of each row turns into a minus while the answer grows open, and several rows can stay open.

pixikit.com/docs/components/plus-accordion

Customize

Multiple
Default open0
Width600px
Padding y20px
Padding x20px
Font size16.0px
Font weight400
Answer size15.0px
Answer gap18px
Duration0.40s
Icon duration0.30s
Icon
Icon size14px
Icon stroke2.00px
Icon side
Hover opacity0.60
Dividers
Divider color
Text color
Answer color

Props

24
NameTypeDefaultDescription
itemsPlusAccordionItem[]SAMPLEThe rows. A short sample set shows when left out.
multiplebooleantrueLets several rows stay open together.
defaultOpennumber-1Index of the row open at first; -1 opens none.
onOpenChange(open: number[]) => voidNoneCalled with the indexes of the open rows.
widthnumber600Widest the list grows, in px.
paddingYnumber20Space above and below each title, in px.
paddingXnumber20Space left and right of each row, in px.
fontSizenumber16Title size, in px.
fontWeightnumber400Title weight.
answerSizenumber15Answer size, in px.
answerGapnumber18Space under an open answer, in px.
durationnumber0.4Seconds the answer takes to open and close.
iconDurationnumber0.3Seconds the icon takes to turn.
icon"plus" | "chevron" | "none""plus"`plus` turns into a minus, `chevron` flips, `none` shows no icon.
iconSizenumber14Icon size, in px.
iconStrokenumber2Icon line thickness, in px.
iconSide"right" | "left""right"Which side the icon sits on.
hoverOpacitynumber0.6Opacity of a title while the pointer is over it.
dividersbooleantrueDraws a line between rows.
dividerColorstring"var(--border)"Line colour.
textColorstring"var(--foreground)"Title and icon colour.
answerColorstring"var(--muted-foreground)"Answer colour.
classNamestring""
styleCSSPropertiesNone

More interaction components in Pro

View all

Related