import type { AccordionRootProps, AccordionRootEmits } from 'reka-ui'; import type { VNode } from 'vue'; import type { AppConfig } from '@nuxt/schema'; import theme from '#build/b24ui/accordion'; import type { IconComponent } from '../types'; import type { DynamicSlots, GetItemKeys } from '../types/utils'; import type { ComponentConfig } from '../types/tv'; type Accordion = ComponentConfig; export interface AccordionItem { label?: string; /** * @IconComponent */ icon?: IconComponent; /** * @IconComponent */ trailingIcon?: IconComponent; slot?: string; content?: string; /** * A unique value for the accordion item. Defaults to the index. * Also used as the Vue `key` for this item, so providing a stable value prevents * accordion content (and its local state) from remounting when items are added, removed, * or reordered. */ value?: string; disabled?: boolean; class?: any; b24ui?: Pick; [key: string]: any; } export interface AccordionProps extends Pick { /** * The element or component this component should render as. * @defaultValue 'div' */ as?: any; items?: T[]; /** * The icon displayed on the right side of the trigger. * @defaultValue icons.chevronDown * @IconComponent */ trailingIcon?: IconComponent; /** * The key used to get the value from the item. * @defaultValue 'value' */ valueKey?: GetItemKeys; /** * The key used to get the label from the item. * @defaultValue 'label' */ labelKey?: GetItemKeys; class?: any; b24ui?: Accordion['slots']; } export interface AccordionEmits extends AccordionRootEmits { } type SlotProps = (props: { item: T; index: number; open: boolean; b24ui: Accordion['b24ui']; }) => VNode[]; export type AccordionSlots = { leading?: SlotProps; default?(props: { item: T; index: number; open: boolean; }): VNode[]; trailing?: SlotProps; content?: SlotProps; body?: SlotProps; } & DynamicSlots; declare const _default: typeof __VLS_export; export default _default; declare const __VLS_export: (__VLS_props: NonNullable>["props"], __VLS_ctx?: __VLS_PrettifyLocal>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable>["expose"], __VLS_setup?: Promise<{ props: import("vue").PublicProps & __VLS_PrettifyLocal & { "onUpdate:modelValue"?: ((value: string | string[] | undefined) => any) | undefined; }> & (typeof globalThis extends { __VLS_PROPS_FALLBACK: infer P; } ? P : {}); expose: (exposed: {}) => void; attrs: any; slots: AccordionSlots; emit: (evt: "update:modelValue", value: string | string[] | undefined) => void; }>) => import("vue").VNode & { __ctx?: Awaited; }; type __VLS_PrettifyLocal = (T extends any ? { [K in keyof T]: T[K]; } : { [K in keyof T as K]: T[K]; }) & {};