Skip to Content
✨ Just dropped my UI Library — still cooking up some magic! Stay tuned & maybe… hire me  or sponsor me 😉 
DocumentationAccordion

Accordion

A flexible and accessible accordion component that allows users to expand and collapse content sections. Built with smooth animations and multiple styling variants.

Install Dependencies

npx
quickcode-ui add Accordion

Default Usage

Default Accordion

Allow Multiple Open Items

Allow Multiple Open

Bordered Variant

Bordered Variant

Filled Variant with Large Size

Filled Variant Large

Props

PropTypeDefaultDescription
itemsArray<{title: string, content: string}>Sample itemsArray of objects containing title and content for each accordion item
allowMultiplebooleanfalseWhether multiple accordion items can be open simultaneously
variant"default" | "bordered" | "filled""default"Visual style variant of the accordion
size"sm" | "md" | "lg""md"Size variant that affects text size and padding

Features

  • Smooth Animations: Powered by Framer Motion for fluid expand/collapse transitions
  • Keyboard Accessible: Full keyboard navigation support with focus management
  • Multiple Variants: Choose from default, bordered, or filled styling options
  • Flexible Content: Supports any content structure within accordion items
  • Responsive Design: Adapts beautifully to different screen sizes
  • Dark Mode Ready: Built-in support for light and dark themes
Last updated on