import type { FC, ReactNode } from "react"; import { type AccordionProps } from "../Accordion/Accordion"; import { type DraggableListProps, type ListItemProps, type SortableListProps } from "../List"; import { type AccordionItemProps } from "../Accordion/AccordionItem"; import { type BaseButtonProps } from "../ButtonV2/ButtonProps.type"; import { AccordionListActions } from "./subcomponents/AccordionListActions"; export interface AccordionListProps extends Omit { localisations: { title: string; searchPlaceholder?: string; emptyListText?: string; }; accordionItems: AccordionItem[]; /** * @deprecated * Use the `actions` prop to render any button(s) * or other component(s) automatically in the correct area. */ buttonProps?: BaseButtonProps; isSearchEnabled?: boolean; isLoading?: boolean; isError?: boolean; errorState?: { title: string; description: string; }; actions?: ReactNode; headerActions?: ReactNode; } export type AccordionListItemProps = Omit & { listItems: T[]; draggableListType?: "default"; title: ReactNode; }; export type DraggableAccordionListItemProps = Omit & { draggableListType: "draggable"; listItems: DraggableListProps["items"]; title: ReactNode; }; export type SortableAccordionListItemProps = Omit & { draggableListType: "sortable"; draggableIdentifier: string; listItems: SortableListProps["items"]; title: ReactNode; }; export type AccordionItem = AccordionListItemProps | DraggableAccordionListItemProps | SortableAccordionListItemProps; type StaticComponents = { Actions: typeof AccordionListActions; }; /** * @deprecated Please check out the recipes on how to create an `AccordionList` component using composition: https://design.luscii.com/?path=/docs/recipes-accordion-list-composition--docs */ export declare const AccordionList: FC & StaticComponents; export default AccordionList;