Y2K UI

Accordion

A vertically stacked set of collapsible sections. Animations are powered by tw-animate-cssanimate-accordion-down on open and animate-accordion-up on close — so the height transition is buttery smooth.

accordion-demo.app

A modern Y2K / kawaii-retro component library for React. Flat windows, thick navy outlines, pastel fills. No glassmorphism, no Win98 bevel.

Installation

terminal.sh
npx y2kui@latest add accordion

Usage

import {
  Accordion,
  AccordionContent,
  AccordionItem,
  AccordionTrigger,
} from "@/components/ui/accordion";

Props

PropTypeDefaultDescription
type'single' | 'multiple'Whether one or multiple items can be open at a time.
collapsiblebooleanAllow items to be collapsed when type='single'.
defaultValuestring | string[]Initial open item(s) (uncontrolled).
valuestring | string[]Controlled open item(s).
onValueChange(value: string | string[]) => voidFired when the open items change.

On this page