Disclosure
Accordion

Accordion

Accordion is a user interface component that allows you to create a list of expandable and collapsible items. Through Accordion, you can create individual items called AccordionItem.

Example

Basic Usage

<Widget
	src='flashui.near/widget/Accordion'
	props={{
		data: [
			{
				title: 'Section 1',
				content: 'Content of Section 1',
				show: false,
			},
		],
		children: (
			<Widget
				src='flashui.near/widget/AccordionItem'
				props={{
					title: 'Section 2',
					content: 'Content of Section 2',
				}}
			/>
		),
	}}
/>

Props

  • data (Array, optional): An array containing AccordionItem entries. Each item may have properties such as title, content, and show.

  • children (ReactNode, optional): React children elements inside the Accordion. These children will be displayed after the items from data.