Components / PaperAccordion

Navigation

PaperAccordion

Disclosure pattern with editorial rhythm and yellow active marker.

↗ open what matters, collapse the rest.

Preview

Copy the file, export it, and ship.
No package required for core components.
Yes. CVA is inside every file.
'use client'

import * as React from 'react'
import { cn } from '@/lib/utils'

export interface PaperAccordionItem {

Installation

Copy this file into your project, export its barrel, and then add it to the master UI index.

  1. Step 1.Create this file:
    components/ui/paperAccordion/paperAccordion.tsx
  2. Step 2.Create the barrel:
    components/ui/paperAccordion/index.ts
  3. Step 3.Add this export in components/ui/index.ts:
    export * from './paperAccordion'

Variants

Default

Answer text.

Props

PropTypeDefaultDescription
itemsPaperAccordionItem[][]Disclosure entries rendered top to bottom.
defaultValuestringfirst itemInitially opened item value.

Examples

FAQ block

Ideal for docs sections with concise Q&A.

Keyboard and screen-reader friendly semantics.
Yes, everything uses token classes.
<PaperAccordion items={[...]} />

Release notes

Collapse changelog sections by version.

New table and tabs components.
Introduced dialog and accordion.
<PaperAccordion items={[...]} />