Accordion
FREEÇizgi, kart ve sade stillerde; ikonlu, açıklamalı ve yumuşak yükseklik animasyonlu açılır bölümler.
Kurulum
Terminal
npx @bloxa/cli add accordion
# or: npx shadcn@latest add @bloxa/accordionOtomatik kurulan paketler: radix-ui
Örnekler
SSS
Yes. Arrow keys move between headers, Enter and Space toggle, and screen readers hear the expanded state.
Use type="multiple". With type="single" and collapsible, one item opens at a time and can be closed.
Height and opacity animate without measuring the content, and motion is skipped for reduced-motion users.
Kartlar, ikonlar, çoklu açılım
Update how you appear to your team.
Turn on two-factor authentication to protect your account.
You are on the Pro plan, paid once for life.
API
Her bileşen, oluşturduğu HTML elemanının özelliklerini de kabul eder.
Accordion
| Özellik | Tip | Varsayılan | Açıklama |
|---|---|---|---|
| type | "single" | "multiple" | — | Tek ya da birden çok açık öğe. |
| collapsible | boolean | false | single modda açık öğe kapatılabilir. |
| variant | "line" | "card" | "ghost" | "line" | Görünüm. |
AccordionTrigger
| Özellik | Tip | Varsayılan | Açıklama |
|---|---|---|---|
| icon | ReactNode | — | Başlıktan önce ikon. |
| description | ReactNode | — | Başlık altında ikinci satır. |
| indicator | "chevron" | "plus" | "chevron" | Sağdaki işaret. |