@slashid/react
Version:
React SDK for the /id platform
26 lines • 928 B
TypeScript
import { ReactNode } from "react";
type Item = {
/** Unique value of the item */
value: string;
/** Icon to display next to the trigger */
icon?: ReactNode;
/** Trigger to toggle the collapsed state of its associated item */
trigger: ReactNode;
/** Content to display when the item is expanded */
content: ReactNode;
};
type Props = {
/** List of items to display */
items: Item[];
/** Custom class name for the accordion */
className?: string;
/** Custom class name for each item */
itemClassName?: string;
};
/**
* Accordion component built on top of Radix Accordion primitives to display a list of items
* that can be expanded and collapsed. It supports multiple items expanded at the same time.
*/
export declare const Accordion: ({ items, className, itemClassName }: Props) => import("react/jsx-runtime").JSX.Element;
export {};
//# sourceMappingURL=index.d.ts.map