Accordion Basic
uiable/accordion-basicFreeComponent
Accordion Basic variant for component.
Live preview
live · rendered by the registry
Rendered by uiable on their own page — this is the component running, not a screenshot of it.Install it
npx shadcn@latest add https://uiable.com/r/accordion-basic.jsonSource
1// shadcn2import {3 Accordion,4 AccordionContent,5 AccordionItem,6 AccordionTrigger7} from "@/components/ui/accordion";89// ------------------------------ | ACCORDION BASIC | ------------------------------ //1011export default function AccordionBasic() {12 return (13 <Accordion defaultValue={["item-1"]} className="w-full">14 <AccordionItem value="item-1" className="bg-card border-border">15 <AccordionTrigger className="p-4 text-base font-semibold hover:no-underline">16 Accordion Item #117 </AccordionTrigger>18 <AccordionContent className="p-4 pt-0">19 <strong>This is the first item's accordion body.</strong> It is hidden20 by default, until the collapse plugin adds the appropriate classes21 that we use to style each element.22 </AccordionContent>23 </AccordionItem>24 <AccordionItem value="item-2" className="bg-card border-border">25 <AccordionTrigger className="p-4 text-base font-semibold hover:no-underline">26 Accordion Item #227 </AccordionTrigger>28 <AccordionContent className="p-4 pt-0">29 <strong>This is the second item's accordion body.</strong> It is30 hidden by default, until the collapse plugin adds the appropriate31 classes that we use to style each element.32 </AccordionContent>33 </AccordionItem>34 <AccordionItem value="item-3" className="bg-card border-border">35 <AccordionTrigger className="p-4 text-base font-semibold hover:no-underline">36 Accordion Item #337 </AccordionTrigger>38 <AccordionContent className="p-4 pt-0">39 <strong>This is the third item's accordion body.</strong> It is hidden40 by default, until the collapse plugin adds the appropriate classes41 that we use to style each element.42 </AccordionContent>43 </AccordionItem>44 </Accordion>45 );46}
What it pulls in
Other registry items
Files it writes
More from uiable
All 730 items| Component | Registry | Kind | Access | Installs | Command |
|---|---|---|---|---|---|
| Accordionaccordion | uiable | Components | Free | 2 deps | |
| Accordion Bordersaccordion-borders | uiable | Components | Free | no deps | |
| Accordion Cardaccordion-card | uiable | Components | Free | no deps | |
| Accordion Disabledaccordion-disabled | uiable | Components | Free | no deps | |
| Accordion Flushaccordion-flush | uiable | Components | Free | no deps | |
| Accordion Multipleaccordion-multiple | uiable | Components | Free | no deps | |
| Alertalert | uiable | Components | Free | 1 dep | |
| Alert Actionalert-action | uiable | Components | Free | no deps |
