import { App, CSSProperties, ComponentPublicInstance, ComputedRef, InjectionKey, MaybeRef, MaybeRefOrGetter, ObjectPlugin, Reactive, Ref, ShallowReactive, ShallowRef, TemplateRef, UnwrapNestedRefs, WatchSource, WritableComputedRef, h } from "vue"; import { Temporal } from "@js-temporal/polyfill"; import "@flagsmith/flagsmith"; import "launchdarkly-js-client-sdk"; import "posthog-js"; //#region src/types/index.d.ts /** * Valid element types for Vue's `h()` render function * * @remarks * Includes HTML tag names, component definitions, and functional components. * Used by the `Atom` component for polymorphic rendering. */ type DOMElement = Parameters[0]; /** * Identifier type used throughout the registry system * * @remarks * All tickets, items, and registrable entities use this type for their `id` property. * * @example * ```ts * const id: ID = 'item-1' // string * const id: ID = 42 // number * ``` */ type ID = string | number; /** * Recursively makes all properties of T optional * * @template T The object type to make deeply partial * * @remarks * Used by `mergeDeep` to type partial source objects. * * @example * ```ts * type User = { name: string; address: { city: string } } * type PartialUser = DeepPartial * // { name?: string; address?: { city?: string } } * ``` */ type DeepPartial = T extends object ? { [P in keyof T]?: DeepPartial; } : T; /** * Union type that accepts either a single value or an array * * @template T The base type * * @remarks * Used for APIs that accept both single items and arrays. * * @example * ```ts * function process(input: MaybeArray) { ... } * process('single') // OK * process(['a', 'b', 'c']) // OK * ``` */ type MaybeArray = T | T[]; /** * Preserves string literal autocomplete while allowing arbitrary strings * * @template T The string literal union to preserve * * @remarks * TypeScript normally collapses `'a' | 'b' | string` into just `string`, * losing IDE autocomplete for the known values. This type uses the * `string & {}` trick to prevent that collapse. * * Use for extensible APIs where you want autocomplete for known values * but still accept custom strings: event names, theme tokens, CSS classes, etc. * * @example * ```ts * type Color = 'red' | 'blue' | 'green' * * // WITHOUT Extensible - autocomplete lost * type BadColor = Color | string // collapses to just `string` * * // WITH Extensible - autocomplete preserved * type GoodColor = Extensible * * function setColor(c: GoodColor) {} * setColor('red') // autocomplete suggests 'red' | 'blue' | 'green' * setColor('purple') // also OK - custom value accepted * ``` * * @example * ```ts * // Event system with typed + custom events * type KnownEvent = 'click' | 'hover' | 'focus' * * function on>(event: K, cb: Callback) {} * * on('click', ...) // autocomplete works * on('custom', ...) // custom events allowed * ``` */ type Extensible = T | (string & {}); /** * Keyboard activation mode for navigable components * * @remarks * Controls when selection occurs during keyboard navigation: * - `automatic` (default): Selection follows focus (arrow keys select). * This is the WAI-ARIA standard for radio groups. * - `manual`: Arrow keys move focus only; Enter/Space required to select. * Use for toolbar contexts or when deliberate selection is preferred. * * @example * ```vue * * ``` */ type Activation = 'automatic' | 'manual'; /** * Discriminated union of structured details attached to every v0-thrown error * * @remarks * Each arm pairs a stable `code` discriminant with the domain context for that * code. Consumed by the `V0Error` constructor in `#v0/utilities` — the union * is the source of truth for both what codes exist and what payload each code * carries. * * Prefer `isV0Error(err, code)` over manual narrowing — see * `V0Error` and `isV0Error` in `#v0/utilities` for the consumer-facing API * and worked examples. * * Inspiration: tRPC's `TRPCError.code`, Node's `error.code` registry. * * @see https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error/cause * @see https://nodejs.org/api/errors.html#nodejs-error-codes * @see https://trpc.io/docs/server/error-handling * * @example * ```ts * const details: V0ErrorDetails = { code: 'V0_CONTEXT_MISSING', key: 'theme' } * ``` */ type V0ErrorDetails = { code: 'V0_CONTEXT_MISSING'; key: string | symbol; } | { code: 'V0_PLUGIN_MISSING'; plugin: string; } | { code: 'V0_PALETTE_INVALID_SEED'; palette: 'material' | 'leonardo' | 'ant'; seed: string; } | { code: 'V0_PALETTE_UNKNOWN_VARIANT'; palette: 'material'; variant: string; } | { code: 'V0_ADAPTER_INSTANCE_MISSING'; adapter: string; } | { code: 'V0_DATE_INVALID'; value: string; } | { code: 'V0_THEME_INVALID_PREFIX'; prefix: string; }; /** * Union of every error code thrown by v0 * * @remarks * Convenience alias for the discriminant field of {@link V0ErrorDetails}. * * @example * ```ts * function describe (code: V0ErrorCode): string { * switch (code) { * case 'V0_CONTEXT_MISSING': return 'missing provider' * case 'V0_PLUGIN_MISSING': return 'plugin not installed' * } * } * ``` */ type V0ErrorCode = V0ErrorDetails['code']; //#endregion //#region src/components/Atom/Atom.vue.d.ts /** * Props for the Atom component */ interface AtomProps { /** * The HTML element to render as, or null for renderless mode * @default 'div' */ as?: DOMElement | null; /** * When true, renders slot content directly without a wrapper element * @default false */ renderless?: boolean; } /** * Slot types for the Atom component * @template T - The type of props passed to the slot */ interface AtomSlots { /** * Default slot that receives all forwarded attributes as props */ default: (props: T) => any; } /** * Values exposed by the Atom component via defineExpose */ interface AtomExpose { /** * Template ref to the rendered HTML element (null in renderless mode) */ element: TemplateRef; } interface AtomPrivateProps extends AtomProps {} declare const _default$12: typeof __VLS_export$234; declare const __VLS_export$234: = {}>(__VLS_props: NonNullable>["props"], __VLS_ctx?: __VLS_PrettifyLocal$39>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable>["expose"], __VLS_setup?: Promise<{ props: import("vue").PublicProps & __VLS_PrettifyLocal$39 & (typeof globalThis extends { __VLS_PROPS_FALLBACK: infer P; } ? P : {}); expose: (exposed: import("vue").ShallowUnwrapRef) => void; attrs: any; slots: AtomSlots; emit: {}; }>) => import("vue").VNode & { __ctx?: NonNullable>; }; type __VLS_PrettifyLocal$39 = (T extends any ? { [K in keyof T]: T[K]; } : { [K in keyof T as K]: T[K]; }) & {}; //#endregion //#region src/components/Alert/AlertRoot.vue.d.ts interface AlertRootProps extends AtomProps { /** * ARIA live-region role. * - `'alert'` — assertive: AT interrupts to announce the message immediately. * - `'status'` — polite: AT waits for the current speech to finish. * @default 'alert' */ role?: 'alert' | 'status'; } interface AlertRootSlotAttrs { 'aria-atomic': true; 'aria-live': 'assertive' | 'polite'; 'role': 'alert' | 'status'; } interface AlertRootSlotProps { /** Attributes to bind to the alert element */ attrs: AlertRootSlotAttrs; } declare const _default$9: typeof __VLS_export$233; declare const __VLS_export$233: __VLS_WithSlots$184 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: AlertRootSlotProps) => any; }>; type __VLS_WithSlots$184 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/Alert/AlertTitle.vue.d.ts interface AlertTitleProps extends AtomProps {} interface AlertTitleSlotProps { /** Attributes to bind to the title element */ attrs: Record; } declare const _default$10: typeof __VLS_export$232; declare const __VLS_export$232: __VLS_WithSlots$183 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: AlertTitleSlotProps) => any; }>; type __VLS_WithSlots$183 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/Alert/AlertDescription.vue.d.ts interface AlertDescriptionProps extends AtomProps {} interface AlertDescriptionSlotProps { /** Attributes to bind to the description element */ attrs: Record; } declare const _default: typeof __VLS_export$231; declare const __VLS_export$231: __VLS_WithSlots$182 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: AlertDescriptionSlotProps) => any; }>; type __VLS_WithSlots$182 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/Alert/index.d.ts /** * Alert compound component for inline status messages. * * Renders a live region (`role="alert"` by default) that screen readers * announce when content is inserted or updated. Use `Alert.Root`, * `Alert.Title`, and `Alert.Description` to compose structured alerts. * * @see https://0.vuetifyjs.com/components/semantic/alert * * @example * ```vue * * * * ``` */ declare const Alert: { /** * Root live-region container. Defaults to `role="alert"` (assertive). * Set `role="status"` for polite, non-urgent messages. * * @see https://0.vuetifyjs.com/components/semantic/alert * * @example * ```vue * * * * ``` */ Root: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: AlertRootSlotProps) => any; }; }); /** * Title for the alert. Renders as `

` by default. * * @see https://0.vuetifyjs.com/components/semantic/alert * * @example * ```vue * * * * ``` */ Title: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: AlertTitleSlotProps) => any; }; }); /** * Description body for the alert. Renders as `

` by default. * * @see https://0.vuetifyjs.com/components/semantic/alert * * @example * ```vue * * * * ``` */ Description: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: AlertDescriptionSlotProps) => any; }; }); }; //#endregion //#region src/components/AlertDialog/AlertDialogRoot.vue.d.ts interface AlertDialogContext { isOpen: ShallowRef; id: string; titleId: string; descriptionId: string; /** Whether an AlertDialog.Title child is currently mounted */ hasTitle: ShallowRef; /** Whether an AlertDialog.Description child is currently mounted */ hasDescription: ShallowRef; isPending: ShallowRef; cancelEl: ShallowRef; open: () => void; close: () => void; } interface AlertDialogRootProps extends AtomProps { /** Namespace for dependency injection */ namespace?: string; /** Unique identifier for the alert dialog (auto-generated if not provided) */ id?: string; } interface AlertDialogRootSlotProps { /** Unique identifier */ id: string; /** Whether the alert dialog is currently open */ isOpen: boolean; /** Whether an action is pending (between wait and close) */ isPending: boolean; /** Open the alert dialog */ open: () => void; /** Close the alert dialog */ close: () => void; } declare const useAlertDialogContext: (key: string, defaultValue?: AlertDialogContext | undefined) => AlertDialogContext, provideAlertDialogContext: (key: string, context: AlertDialogContext, app?: import("vue").App) => AlertDialogContext; declare const _default$7: typeof __VLS_export$230; declare const __VLS_export$230: __VLS_WithSlots$181 any; "update:model-value": (value: boolean) => any; }, string, import("vue").PublicProps, Readonly & Readonly<{ "onUpdate:modelValue"?: ((value: boolean) => any) | undefined; "onUpdate:model-value"?: ((value: boolean) => any) | undefined; }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: AlertDialogRootSlotProps) => any; }>; type __VLS_WithSlots$181 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/AlertDialog/AlertDialogActivator.vue.d.ts interface AlertDialogActivatorProps extends AtomProps { /** Namespace for dependency injection */ namespace?: string; } interface AlertDialogActivatorSlotProps { /** Whether the alert dialog is currently open */ isOpen: boolean; /** Attributes to bind to the trigger element */ attrs: { 'type': 'button' | undefined; 'role': 'button' | undefined; 'tabindex': number; 'aria-haspopup': 'dialog'; 'aria-expanded': boolean; 'data-open': true | undefined; 'onClick': () => void; 'onKeydown': ((e: KeyboardEvent) => void) | undefined; }; } declare const _default$2: typeof __VLS_export$229; declare const __VLS_export$229: __VLS_WithSlots$180 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: AlertDialogActivatorSlotProps) => any; }>; type __VLS_WithSlots$180 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/AlertDialog/AlertDialogContent.vue.d.ts interface AlertDialogContentProps extends AtomProps { /** Namespace for dependency injection */ namespace?: string; /** Close dialog when clicking outside content @default false */ closeOnClickOutside?: boolean; /** Close dialog when pressing Escape @default false */ closeOnEscape?: boolean; /** * Whether this dialog blocks scrim dismissal * * @default false */ blocking?: boolean; /** * Whether the global Scrim should paint a backdrop for this dialog * * @default true * @remarks When false, this dialog still stacks for z-index but `Scrim` skips it. * Use when the consumer owns its own backdrop (e.g. a design-system modal background). */ scrim?: boolean; } interface AlertDialogContentEmits { cancel: [e: Event]; close: [e: Event]; } interface AlertDialogContentSlotProps { /** Whether the alert dialog is currently open */ isOpen: boolean; /** Whether this dialog is the topmost in the global stack */ globalTop: boolean; /** Calculated z-index for the dialog */ zIndex: number; /** Attributes to bind to the dialog element */ attrs: { 'id': string; 'role': 'alertdialog'; 'aria-modal': 'true'; 'aria-labelledby': string | undefined; 'aria-describedby': string | undefined; 'style': { zIndex: number; }; 'onCancel': (e: Event) => void; 'onClose': (e: Event) => void; }; } declare const _default$5: typeof __VLS_export$228; declare const __VLS_export$228: __VLS_WithSlots$179 any; close: (e: Event) => any; }, string, import("vue").PublicProps, Readonly & Readonly<{ onCancel?: ((e: Event) => any) | undefined; onClose?: ((e: Event) => any) | undefined; }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: AlertDialogContentSlotProps) => any; }>; type __VLS_WithSlots$179 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/AlertDialog/AlertDialogTitle.vue.d.ts interface AlertDialogTitleProps extends AtomProps { /** Namespace for dependency injection */ namespace?: string; } interface AlertDialogTitleSlotProps { /** Attributes to bind to the title element */ attrs: { id: string; }; } declare const _default$8: typeof __VLS_export$227; declare const __VLS_export$227: __VLS_WithSlots$178 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: AlertDialogTitleSlotProps) => any; }>; type __VLS_WithSlots$178 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/AlertDialog/AlertDialogDescription.vue.d.ts interface AlertDialogDescriptionProps extends AtomProps { /** Namespace for dependency injection */ namespace?: string; } interface AlertDialogDescriptionSlotProps { /** Attributes to bind to the description element */ attrs: { id: string; }; } declare const _default$6: typeof __VLS_export$226; declare const __VLS_export$226: __VLS_WithSlots$177 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: AlertDialogDescriptionSlotProps) => any; }>; type __VLS_WithSlots$177 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/AlertDialog/AlertDialogCancel.vue.d.ts interface AlertDialogCancelProps extends AtomProps { /** Namespace for dependency injection */ namespace?: string; /** Whether the cancel button is disabled */ disabled?: boolean; } interface AlertDialogCancelSlotProps { /** Whether the alert dialog is currently open */ isOpen: boolean; /** Attributes to bind to the cancel button element */ attrs: { 'type': 'button' | undefined; 'role': 'button' | undefined; 'tabindex': number; 'disabled': boolean | undefined; 'data-disabled': '' | undefined; 'onClick': () => void; 'onKeydown': ((e: KeyboardEvent) => void) | undefined; }; } declare const _default$3: typeof __VLS_export$225; declare const __VLS_export$225: __VLS_WithSlots$176 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: AlertDialogCancelSlotProps) => any; }>; type __VLS_WithSlots$176 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/AlertDialog/AlertDialogClose.vue.d.ts interface AlertDialogCloseProps extends AtomProps { /** Namespace for dependency injection */ namespace?: string; } interface AlertDialogCloseSlotProps { /** Whether the alert dialog is currently open */ isOpen: boolean; /** Attributes to bind to the close button element */ attrs: { 'type': 'button' | undefined; 'role': 'button' | undefined; 'tabindex': number; 'aria-label': string; 'onClick': () => void; 'onKeydown': ((e: KeyboardEvent) => void) | undefined; }; } declare const _default$4: typeof __VLS_export$224; declare const __VLS_export$224: __VLS_WithSlots$175 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: AlertDialogCloseSlotProps) => any; }>; type __VLS_WithSlots$175 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/AlertDialog/AlertDialogAction.vue.d.ts interface AlertDialogActionEvent { /** Signal the dialog to stay open until close() is called */ wait: () => void; /** Resolve the pending state and close the dialog */ close: () => void; } interface AlertDialogActionProps extends AtomProps { /** Namespace for dependency injection */ namespace?: string; /** Whether the action button is disabled */ disabled?: boolean; } interface AlertDialogActionEmits { action: [event: AlertDialogActionEvent]; } interface AlertDialogActionSlotProps { /** Whether the action is pending (between wait and close) */ isPending: boolean; /** Attributes to bind to the action button element */ attrs: { 'type': 'button' | undefined; 'role': 'button' | undefined; 'tabindex': number; 'disabled': boolean | undefined; 'data-disabled': '' | undefined; 'data-pending': '' | undefined; 'onClick': () => void; 'onKeydown': ((e: KeyboardEvent) => void) | undefined; }; } declare const _default$1: typeof __VLS_export$223; declare const __VLS_export$223: __VLS_WithSlots$174 any; }, string, import("vue").PublicProps, Readonly & Readonly<{ onAction?: ((event: AlertDialogActionEvent) => any) | undefined; }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: AlertDialogActionSlotProps) => any; }>; type __VLS_WithSlots$174 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/AlertDialog/index.d.ts /** * AlertDialog component with sub-components for building confirmation dialogs. * * @see https://0.vuetifyjs.com/components/disclosure/alert-dialog * * @example * ```vue * * * * ``` */ declare const AlertDialog: { /** * Root component for alert dialogs. * * @see https://0.vuetifyjs.com/components/disclosure/alert-dialog * * @example * ```vue * * * * ``` */ Root: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{ "onUpdate:modelValue"?: ((value: boolean) => any) | undefined; "onUpdate:model-value"?: ((value: boolean) => any) | undefined; }>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, { "update:modelValue": (value: boolean) => any; "update:model-value": (value: boolean) => any; }, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{ "onUpdate:modelValue"?: ((value: boolean) => any) | undefined; "onUpdate:model-value"?: ((value: boolean) => any) | undefined; }>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{ "onUpdate:modelValue"?: ((value: boolean) => any) | undefined; "onUpdate:model-value"?: ((value: boolean) => any) | undefined; }>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, { "update:modelValue": (value: boolean) => any; "update:model-value": (value: boolean) => any; }, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: AlertDialogRootSlotProps) => any; }; }); /** * Activator component that opens the alert dialog. * * @see https://0.vuetifyjs.com/components/disclosure/alert-dialog * * @example * ```vue * * * * ``` */ Activator: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: AlertDialogActivatorSlotProps) => any; }; }); /** * Content container for the alert dialog using native `

` element. * * @see https://0.vuetifyjs.com/components/disclosure/alert-dialog * * @example * ```vue * * * * ``` */ Content: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{ onCancel?: ((e: Event) => any) | undefined; onClose?: ((e: Event) => any) | undefined; }>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, { cancel: (e: Event) => any; close: (e: Event) => any; }, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{ onCancel?: ((e: Event) => any) | undefined; onClose?: ((e: Event) => any) | undefined; }>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{ onCancel?: ((e: Event) => any) | undefined; onClose?: ((e: Event) => any) | undefined; }>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, { cancel: (e: Event) => any; close: (e: Event) => any; }, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: AlertDialogContentSlotProps) => any; }; }); /** * Title component for accessible alert dialog labeling. * * @see https://0.vuetifyjs.com/components/disclosure/alert-dialog * * @example * ```vue * * * * ``` */ Title: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: AlertDialogTitleSlotProps) => any; }; }); /** * Description component for accessible alert dialog description. * * @see https://0.vuetifyjs.com/components/disclosure/alert-dialog * * @example * ```vue * * * * ``` */ Description: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: AlertDialogDescriptionSlotProps) => any; }; }); /** * Cancel button component for dismissing the alert dialog. * * @see https://0.vuetifyjs.com/components/disclosure/alert-dialog * * @example * ```vue * * * * ``` */ Cancel: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: AlertDialogCancelSlotProps) => any; }; }); /** * Close button component for closing the alert dialog. * * @see https://0.vuetifyjs.com/components/disclosure/alert-dialog * * @example * ```vue * * * * ``` */ Close: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: AlertDialogCloseSlotProps) => any; }; }); /** * Action button component for confirming the alert dialog. * * @see https://0.vuetifyjs.com/components/disclosure/alert-dialog * * @example * ```vue * * * * ``` */ Action: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{ onAction?: ((event: AlertDialogActionEvent) => any) | undefined; }>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, { action: (event: AlertDialogActionEvent) => any; }, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{ onAction?: ((event: AlertDialogActionEvent) => any) | undefined; }>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{ onAction?: ((event: AlertDialogActionEvent) => any) | undefined; }>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, { action: (event: AlertDialogActionEvent) => any; }, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: AlertDialogActionSlotProps) => any; }; }); }; //#endregion //#region src/components/AspectRatio/AspectRatio.vue.d.ts interface AspectRatioProps extends AtomProps { /** * The aspect ratio as `width / height`. Accepts a number (`16 / 9`) or a * CSS `aspect-ratio` string (`'16 / 9'`, `'1.777'`). * @default 1 */ ratio?: number | string; } interface AspectRatioSlotProps { /** Resolved CSS `aspect-ratio` value. */ ratio: string; /** Attributes to bind to the root element. */ attrs: { style: { aspectRatio: string; }; }; } declare const _default$11: typeof __VLS_export$222; declare const __VLS_export$222: __VLS_WithSlots$173 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: AspectRatioSlotProps) => any; }>; type __VLS_WithSlots$173 = T & { new (): { $slots: S; }; }; //#endregion //#region src/composables/createTrinity/index.d.ts type ContextTrinity = readonly [() => Z, (context?: Z, app?: App) => Z, Z]; /** * Creates a new trinity for a context composable and its provider. * * @param useContext The function that retrieves/uses the context (typically named `useContext`). * @param provideContext The function that provides the context to descendants. * @param context The default context instance to use when no custom context is provided. * @template Z The type of the context. * @returns A readonly tuple containing: [useContext function, provideContext wrapper function, default context instance]. * * @remarks The trinity pattern is a foundational pattern used throughout the codebase for creating reusable context systems. It provides three related elements: * * 1. A function to retrieve/use the context * 2. A function to provide the context (with default value support) * 3. The default context instance * * The returned tuple is readonly (using `as const`) to ensure proper type inference. * * @see https://0.vuetifyjs.com/composables/foundation/create-trinity * * @example * ```ts * // Simplified — key + context * export function createMyFeature() { * const context = { foo: 'hello', bar: 42 } * return createTrinity('my-context', context) * } * * // Explicit — useContext + provideContext + context * export function createMyFeature() { * const [useContext, provideContext] = createContext('my-context') * const context = { foo: 'hello', bar: 42 } * return createTrinity(useContext, provideContext, context) * } * ``` */ declare function createTrinity(key: string, context: Z): ContextTrinity; declare function createTrinity(useContext: () => Z, provideContext: (context: Z, app?: App) => Z, context: Z): ContextTrinity; //#endregion //#region src/composables/createRegistry/index.d.ts /** * User-facing input shape for registry tickets. * * Extend this when defining custom ticket types passed to `register()` and `onboard()`, * and pair it with the resolved ticket type: `createRegistry()`, input * first, output second. The registry adds the computed fields (`index`, `valueIsIndex`) * automatically — those live on {@link RegistryTicket}, which is the output type returned * by `get()` and `values()`. Passing only the input type leaves `value` typed `V | undefined` * on the resolved ticket; passing only the output type is reserved for wrappers that fix * their own ticket shape (`createForm`, `createQueue`). * * @template V The type of the ticket value. * * @example * ```ts * import { createRegistry } from '@vuetify/v0' * import type { RegistryTicket, RegistryTicketInput } from '@vuetify/v0' * * interface ItemInput extends RegistryTicketInput { * label: string * } * * type Item = RegistryTicket & ItemInput * * const registry = createRegistry() * const ticket = registry.register({ value: 'first', label: 'First' }) * * ticket.value // string * ``` */ interface RegistryTicketInput { /** The unique identifier. Optional — auto-generated if not provided. */ id?: ID; /** The value associated with the ticket. If not provided, it defaults to the index. */ value?: V; } interface RegistryTicket { /** The unique identifier. Is randomly generated if not provided. */ id: ID; /** * The index of the ticket in the registry. * * @remarks Automatically managed by the registry. Assigned at registration and updated during reindexing; a supplied index is ignored — use `move()` to position a ticket. It's not recommended to manually set this. A mid-list `unregister`/`offboard` reindexes the shifted survivors eagerly when any ticket is index-derived; otherwise the reindex is deferred and drains at the end of the enclosing `batch()`, on the next position-reading call (`register`/`upsert`/`browse`/`lookup`/`move`/`reorder`/`seek`), and in all cases before the next tick. Until then a survivor read synchronously — via `get()`, `values()`/`entries()`, a held ticket, or a `useProxyRegistry` snapshot — may still carry its previous index; call `lookup(0)` first to drain. A tail removal shifts nobody. */ index: number; /** The value associated with the ticket. If not provided, it defaults to the index. */ value: V; /** * Whether the value is derived from index. * * @remarks Set to true when no explicit value is provided during registration. It's not recommended to manually set this. */ valueIsIndex: boolean; /** * Remove this ticket from the collection that registered it. * * @remarks Equivalent to calling `unregister(ticket.id)` on that collection. * Wrapping registries (model, group, nested) rebind this so sugar hits their * cleanup, not only the base Map delete. */ unregister: () => void; } /** Valid event names for registry operations */ type RegistryEventName = 'register:ticket' | 'unregister:ticket' | 'update:ticket' | 'clear:registry' | 'reindex:registry'; /** Maps event names to their payload types */ type RegistryEventMap = { 'register:ticket': Z; 'unregister:ticket': Z; 'update:ticket': Z; 'clear:registry': undefined; 'reindex:registry': undefined; }; /** * Callback signature for registry event listeners. * * Resolves to a typed payload for known {@link RegistryEventName} keys, and * `(data: unknown) => void` for custom events. */ type RegistryEventCallback = Extensible> = K extends RegistryEventName ? (data: RegistryEventMap[K]) => void : (data: unknown) => void; /** Resolves payload type: typed for known events, unknown for custom events */ type EventPayload = K extends RegistryEventName ? RegistryEventMap[K] : unknown; interface RegistryContext { /** * The collection of tickets in the registry * * @remarks Read-only view of the internal `Map`. Use `register`, `unregister`, `upsert`, and `clear` to modify. The Map iterates in insertion order, which diverges from index order after `move()` or `reorder()` — read `keys()`, `values()`, or `entries()` for the canonical order. */ collection: ReadonlyMap; /** * Clear the entire registry * * @remarks Removes all tickets from the registry. This operation invalidates cached results from `keys()`, `values()`, and `entries()`. * * @see https://0.vuetifyjs.com/composables/registration/create-registry * * @example * ```ts * import { createRegistry } from '@vuetify/v0' * * const registry = createRegistry() * * registry.register({ id: 'ticket-1' }) * registry.register({ id: 'ticket-2' }) * * console.log(registry.size) // 2 * * registry.clear() * * console.log(registry.size) // 0 * ``` */ clear: () => void; /** * Check if a ticket exists by ID * * @param id The ID of the ticket to check. * @remarks Calls `collection.has` internally. * * @see https://0.vuetifyjs.com/composables/registration/create-registry * * @example * ```ts * import { createRegistry } from '@vuetify/v0' * * const registry = createRegistry() * * registry.register({ id: 'ticket-id' }) * * const exists = registry.has('ticket-id') // true * ``` */ has: (id: ID) => boolean; /** * Get all registered IDs * * @remarks Reads the canonical order array, not `collection.keys()`, with caching. First call is O(n), subsequent calls are O(1) until the next mutation clears the cache. * * @see https://0.vuetifyjs.com/composables/registration/create-registry * * @example * ```ts * import { createRegistry } from '@vuetify/v0' * * const registry = createRegistry() * * registry.register({ id: 'ticket-1' }) * registry.register({ id: 'ticket-2' }) * * const ids = registry.keys() // ['ticket-1', 'ticket-2'] * ``` */ keys: () => readonly ID[]; /** * Browse for an ID(s) by value * * @param value The value to browse for. * @remarks Returns an array of IDs that share the given value, or undefined if no match is found. * * @see https://0.vuetifyjs.com/composables/registration/create-registry * * @example * ```ts * import { createRegistry } from '@vuetify/v0' * * const registry = createRegistry() * * registry.register({ id: 'ticket-1', value: 'common-value' }) * registry.register({ id: 'ticket-2', value: 'common-value' }) * registry.register({ id: 'ticket-3', value: 'unique-value' }) * * const common = registry.browse('common-value') // ['ticket-1', 'ticket-2'] * const unique = registry.browse('unique-value') // ['ticket-3'] * ``` */ browse: (value: E['value']) => readonly ID[] | undefined; /** * Lookup a ticket by index number * * @param index The index number to lookup. * @remarks Maps do not support indexing by default, this method provides a way to retrieve an ID based on its index in the registry. * * @see https://0.vuetifyjs.com/composables/registration/create-registry * * @example * ```ts * const registry = createRegistry() * * registry.register({ id: 'ticket-1' }) * registry.register({ id: 'ticket-2' }) * * const ticket1 = registry.lookup(0) // 'ticket-1' * const ticket2 = registry.lookup(1) // 'ticket-2' * ``` */ lookup: (index: number) => ID | undefined; /** * Get a ticket by ID * * @param id The ID of the ticket to retrieve. * @remarks Calls `collection.get` internally. * * @see https://0.vuetifyjs.com/composables/registration/create-registry * * @example * ```ts * import { createRegistry } from '@vuetify/v0' * * const registry = createRegistry() * * registry.register({ id: 'ticket-id', value: 'some-value' }) * * const ticket = registry.get('ticket-id') // { id: 'ticket-id', index: 0, value: 'some-value', ... } * ``` */ get: (id: ID) => E | undefined; /** * Update or insert a ticket by ID * * @param id The ID of the ticket to upsert. * @param ticket The partial ticket data to update or insert. * @param event Optional custom event name to emit alongside `update:ticket`. The patched ticket is dispatched as the event payload. * @remarks If the ticket exists, it will be updated in place — the ticket reference returned by `register()` remains valid and reactive (when `reactive: true`). The iteration cache is cleared, so the next `keys()` / `values()` / `entries()` call returns a fresh array with the same refs, membership and order; `reactive: true` iteration subscribers are not re-notified, while `update:ticket` listeners (including `useProxyRegistry`) are. If it doesn't exist, a new ticket will be created with the given ID and data, which notifies iteration subscribers as `register()` does. * * @see https://0.vuetifyjs.com/composables/registration/create-registry * * @example * ```ts * import { createRegistry } from '@vuetify/v0' * * const registry = createRegistry({ events: true }) * * // Insert a new ticket * const ticket = registry.upsert('ticket-id', { value: 'initial-value' }) * * // Update the existing ticket * const patched = registry.upsert('ticket-id', { value: 'updated-value' }) * * // Emit a custom event with the patched ticket as payload * registry.upsert('ticket-id', { value: 'final' }, 'ticket:final') * ``` */ upsert: (id: ID, ticket?: Partial, event?: string) => E; /** * Get all values of registered tickets * * @remarks Reads the canonical order array, not `collection.values()`, with caching. First call is O(n), subsequent calls are O(1) until the next mutation clears the cache. * * @see https://0.vuetifyjs.com/composables/registration/create-registry * * @example * ```ts * import { createRegistry } from '@vuetify/v0' * * const registry = createRegistry() * * registry.register({ id: 'ticket-1', value: 'value-1' }) * registry.register({ id: 'ticket-2', value: 'value-2' }) * * const values = registry.values() // [{ id: 'ticket-1', ... }, { id: 'ticket-2', ... }] * ``` */ values: () => readonly E[]; /** * Get all entries of registered tickets * * @remarks Reads the canonical order array, not `collection.entries()`, with caching. First call is O(n), subsequent calls are O(1) until the next mutation clears the cache. * * @see https://0.vuetifyjs.com/composables/registration/create-registry * * @example * ```ts * import { createRegistry } from '@vuetify/v0' * * const registry = createRegistry() * * registry.register({ id: 'ticket-1', value: 'value-1' }) * registry.register({ id: 'ticket-2', value: 'value-2' }) * * const entries = registry.entries() // [['ticket-1', { id: 'ticket-1', ... }], ['ticket-2', { id: 'ticket-2', ... }]] * ``` */ entries: () => readonly [ID, E][]; /** * Register a new ticket * * @param ticket The partial ticket data to register. * @remarks If no ID is provided, a unique ID will be generated automatically. If no value is provided, it defaults to the ticket's index. The index is always assigned by the registry — a supplied index is ignored; use `move()` to position a ticket. This operation invalidates cached results from `keys()`, `values()`, and `entries()`. * * @see https://0.vuetifyjs.com/composables/registration/create-registry * * @example * ```ts * import { createRegistry } from '@vuetify/v0' * * const registry = createRegistry() * * const ticket = registry.register() * * console.log(ticket) // { id: 'generated-id', index: 0, value: 0, valueIsIndex: true } * ``` */ register: (ticket?: Partial) => E; /** * Unregister a ticket by ID * * @param id The ID of the ticket to unregister. * @remarks Removes the ticket from the registry. Survivors that shift are reindexed eagerly when any ticket is index-derived; otherwise the reindex is deferred and drains at the end of the enclosing `batch()`, on the next position-reading call, or before the next tick (see `RegistryTicket.index`). This operation invalidates cached results from `keys()`, `values()`, and `entries()`. * * @see https://0.vuetifyjs.com/composables/registration/create-registry * * @example * ```ts * import { createRegistry } from '@vuetify/v0' * * const registry = createRegistry() * * registry.register({ id: 'ticket-id' }) * * registry.unregister('ticket-id') * ``` */ unregister: (id: ID) => void; /** * Reset the index directory and update all tickets * * @remarks Rebuilds the internal index mapping and ensures all tickets have correct index values. This operation invalidates cached results from `keys()`, `values()`, and `entries()`. * * @see https://0.vuetifyjs.com/composables/registration/create-registry * * @example * ```ts * import { createRegistry } from '@vuetify/v0' * * const registry = createRegistry() * * registry.register({ id: 'ticket-1' }) * registry.register({ id: 'ticket-2' }) * * // After some operations that may affect indexing * registry.reindex() * ``` */ reindex: () => void; /** * Move a ticket to a new index position * * @param id The ID of the ticket to move. * @param toIndex The target index position. Truncated to an integer and clamped to the valid range; `Infinity` moves the ticket to the end. * @returns The moved ticket, or undefined if the ticket was not found. * * @remarks Removes the entry from its current position and reinserts it at the target, then reindexes only the `[from..to]` window rather than the whole registry. A reindex deferred by an earlier removal drains first. This operation invalidates cached results from `keys()`, `values()`, and `entries()`. * * @see https://0.vuetifyjs.com/composables/registration/create-registry * * @example * ```ts * import { createRegistry } from '@vuetify/v0' * * const registry = createRegistry() * * registry.onboard([ * { id: 'a', value: 'alpha' }, * { id: 'b', value: 'beta' }, * { id: 'c', value: 'gamma' }, * ]) * * // Move 'a' from index 0 to index 2 * registry.move('a', 2) * * console.log(registry.keys()) // ['b', 'c', 'a'] * ``` */ move: (id: ID, toIndex: number) => E | undefined; /** * Reorder the registry to match a canonical permutation of ids in one pass. * * @param ids A full permutation of the currently-registered ticket ids. * * @remarks * Bulk equivalent of calling `move` n times, but does the rebuild once * (O(n) total rather than O(n²)). Silently no-ops when `ids.length !== size`, * when any id is unknown, or when `ids` contains duplicates — caller is * responsible for validation and warnings. Emits `reindex:registry` once on * completion; does not emit per-ticket `update:ticket` events. * * @example * ```ts * const registry = createRegistry() * registry.onboard([{ id: 'a' }, { id: 'b' }, { id: 'c' }]) * * registry.reorder(['c', 'a', 'b']) * * console.log(registry.keys()) // ['c', 'a', 'b'] * ``` */ reorder: (ids: ID[]) => void; /** * Seek for a ticket based on direction and optional predicate * * @param direction The scan direction (`'first'` = forward, `'last'` = backward). Defaults to `'first'`. * @param from The index to start scanning from. With `'first'` the scan moves forward from `from`; with `'last'` the scan moves backward from `from`. Defaults to `0` for `'first'` and `size - 1` for `'last'`. Truncated to an integer and clamped to the valid range; `Infinity` starts at the last position. * @param predicate An optional function to test each ticket. The first ticket reached in scan order that satisfies the predicate is returned. * @remarks This method allows for flexible searching within the registry, either from the start or end, and can filter tickets based on custom criteria. * * @see https://0.vuetifyjs.com/composables/registration/create-registry * * @example * ```ts * import { createRegistry } from '@vuetify/v0' * * const registry = createRegistry() * * registry.register({ id: 'ticket-1', value: 'apple' }) * registry.register({ id: 'ticket-2', value: 'banana' }) * registry.register({ id: 'ticket-3', value: 'cherry' }) * * // Seek the first ticket * const first = registry.seek('first') * * // Seek the last ticket * const last = registry.seek('last') * * // Seek the first ticket with value 'banana' * const banana = registry.seek('first', undefined, ticket => ticket.value === 'banana') * * // Seek from index 1 to find the next ticket with value starting with 'c' * const cherry = registry.seek('first', 1, ticket => (ticket.value as string).startsWith('c')) * ``` */ seek: (direction?: 'first' | 'last', from?: number, predicate?: (ticket: E) => boolean) => E | undefined; /** * Listen for registry events * * @param event The name of the event to listen for. * @param cb The callback function to invoke when the event is emitted. * @remarks Must be enabled via the `events` option when creating the registry. * Supported events: * - `register:ticket` - Emitted when a ticket is registered, receives the ticket as argument * - `unregister:ticket` - Emitted when a ticket is unregistered, receives the ticket as argument * - `update:ticket` - Emitted when a ticket is updated, receives the updated ticket as argument * - `clear:registry` - Emitted when the registry is cleared * - `reindex:registry` - Emitted when the registry is reindexed * * @see https://0.vuetifyjs.com/composables/registration/create-registry * * @example * ```ts * import { createRegistry } from '@vuetify/v0' * * const registry = createRegistry({ events: true }) * * registry.on('register:ticket', (ticket) => { * console.log('Ticket registered:', ticket) * }) * * registry.register({ id: 'ticket-id' }) // Console: Ticket registered: { id: 'ticket-id', ... } * ``` */ on: >(event: K, cb: RegistryEventCallback) => void; /** * Stop listening for registry events * * @param event The name of the event to stop listening for. * @param cb The callback function to remove. * @remarks Must be enabled via the `events` option when creating the registry. * * @see https://0.vuetifyjs.com/composables/registration/create-registry * * @example * ```ts * import { onScopeDispose } from 'vue' * import { createRegistry } from '@vuetify/v0' * * const registry = createRegistry({ events: true }) * * function onRegister(ticket) { * console.log('Ticket registered:', ticket) * } * * registry.on('register:ticket', onRegister) * * registry.register({ id: 'ticket-id' }) // Console: Ticket registered: { id: 'ticket-id', ... } * * onScopeDispose(() => { * registry.off('register:ticket', onRegister) * }) * ``` */ off: >(event: K, cb: RegistryEventCallback) => void; /** * Emit an event with data * * @param event The name of the event to emit. * @param data The data to pass to event listeners. * @remarks Must be enabled via the `events` option when creating the registry. * * @see https://0.vuetifyjs.com/composables/registration/create-registry * * @example * ```ts * import { createRegistry } from '@vuetify/v0' * * const registry = createRegistry({ events: true }) * * registry.on('custom-event', (data) => { * console.log('Custom event received:', data) * }) * * registry.emit('custom-event', { message: 'Hello, World!' }) // Console: Custom event received: { message: 'Hello, World!' } * ``` */ emit: >(event: K, data: EventPayload) => void; /** * Clears the registry and removes all listeners * * @remarks Disposes of the registry by clearing all tickets and removing all event listeners. * * @see https://0.vuetifyjs.com/composables/registration/create-registry * * @example * ```ts * import { onScopeDispose } from 'vue' * import { createRegistry } from '@vuetify/v0' * * const registry = createRegistry({ events: true }) * * registry.register({ id: 'ticket-id' }) * * onScopeDispose(() => { * registry.dispose() * }) * ``` */ dispose: () => void; /** * Onboard multiple tickets at once * * @param registrations An array of partial ticket data to register. * @remarks Registers multiple tickets in a single operation and returns the array of registered tickets. * * @see https://0.vuetifyjs.com/composables/registration/create-registry * * @example * ```ts * import { createRegistry } from '@vuetify/v0' * * const registry = createRegistry() * * const tickets = registry.onboard([ * { id: 'ticket-1', value: 'value-1' }, * { id: 'ticket-2', value: 'value-2' }, * ]) * * console.log(tickets) // [{ id: 'ticket-1', ... }, { id: 'ticket-2', ... }] * ``` */ onboard: (registrations: Partial[]) => E[]; /** * Offboard multiple tickets at once, returning the input shapes that were removed. * * @param ids An array of ticket IDs to unregister. * @returns An array of `Partial` — the inputs that were registered, with * registry-managed fields (`index`, `valueIsIndex`, `unregister`) stripped. * A user-supplied `id` is preserved so identity survives the transfer; an * auto-generated `id` is stripped so the receiving registry can assign a fresh * one. The `value` is stripped only when it was index-derived (`valueIsIndex`). * Order matches the input `ids` array. Missing ids are silently skipped — the * returned array may be shorter than `ids`. * @remarks Unregisters multiple tickets in a single compaction pass and leaves * the survivors' indexes canonical before returning, or at the end of the enclosing `batch()`. The inverse of `onboard`: onboard takes inputs and returns outputs; * offboard takes ids and returns the inputs back. Pair with `onboard` on a * different registry to move tickets across registries. * * @see https://0.vuetifyjs.com/composables/registration/create-registry * * @example * ```ts * import { createRegistry } from '@vuetify/v0' * * const registry = createRegistry() * * registry.onboard([ * { id: 'ticket-1', value: 'value-1' }, * { id: 'ticket-2', value: 'value-2' }, * { id: 'ticket-3', value: 'value-3' }, * ]) * * const removed = registry.offboard(['ticket-1', 'ticket-3']) * * console.log(registry.size) // 1 * console.log(removed) // [{ id: 'ticket-1', value: 'value-1' }, { id: 'ticket-3', value: 'value-3' }] * * // Move to another registry * const other = createRegistry() * other.onboard(removed) * ``` */ offboard: (ids: ID[]) => Partial[]; /** * The number of tickets in the registry * * @remarks Reflects the current size of the internal ticket collection. * * @see https://0.vuetifyjs.com/composables/registration/create-registry * * @example * ```ts * import { createRegistry } from '@vuetify/v0' * * const registry = createRegistry() * * registry.register({ id: 'ticket-1' }) * registry.register({ id: 'ticket-2' }) * * console.log(registry.size) // 2 * ``` */ size: number; /** * Execute operations in a batch, deferring event dispatch and the reactive notification until complete * * @param fn The function containing batch operations. * @returns The return value of the batch function. * @remarks Useful for bulk operations like onboard(). Events queue until the callback returns and iteration subscribers are notified once, at the end of the batch, instead of after each operation. The iteration cache is still cleared per operation, and a reindex deferred by a removal drains when the batch returns, so survivors' `index` is canonical once the outermost `batch()` returns. * * @see https://0.vuetifyjs.com/composables/registration/create-registry * * @example * ```ts * import { createRegistry } from '@vuetify/v0' * * const registry = createRegistry({ events: true }) * * // Without batch: N events, each with its own reactive notification * // With batch: N events and one reactive notification, after all registrations * const tickets = registry.batch(() => { * return [ * registry.register({ id: 'a' }), * registry.register({ id: 'b' }), * registry.register({ id: 'c' }), * ] * }) * ``` */ batch: (fn: () => R) => R; } interface RegistryOptions { /** * Enable event emission for registry operations * * @default false * @remarks When enabled, the registry will emit events for operations like registration and unregistration. Listeners can be added using the `on` method. * * @example * ```ts * import { createRegistry } from '@vuetify/v0' * * const registry = createRegistry({ events: true }) * * registry.on('register:ticket', (ticket) => { * console.log('Ticket registered:', ticket) * }) * * registry.register({ id: 'ticket-id' }) // Console: Ticket registered: { id: 'ticket-id', ... } * ``` */ events?: boolean; /** * Enable reactive behavior for registry operations * * @default false * @remarks When enabled, tickets and the backing collection are shallowReactive, and `keys()`, `values()`, and `entries()` register a single version dependency so effects and templates re-evaluate on structural mutation. Iteration results stay cached between mutations — reactive reads cost the same as non-reactive ones. * * @example * ```ts * import { createRegistry } from '@vuetify/v0' * * const registry = createRegistry({ reactive: true }) * * registry.register({ id: 'ticket-id' }) * * console.log(registry.size) // 1 * ``` */ reactive?: boolean; } interface RegistryContextOptions extends RegistryOptions { namespace?: string; } /** * Creates a new registry instance. * * @param options The options for the registry instance. * @template Z The input ticket shape (extends RegistryTicketInput). * @template E The resolved ticket type returned by get()/values() (extends RegistryTicket & Z). * @returns A new registry instance. * * @see https://0.vuetifyjs.com/composables/registration/create-registry * * @example * ```ts * import { createRegistry } from '@vuetify/v0' * * const registry = createRegistry() * * const ticket1 = registry.register({ id: 'user-1', value: { name: 'John' } }) * const ticket2 = registry.register({ id: 'user-2', value: { name: 'Jane' } }) * * console.log(registry.size) // 2 * console.log(registry.get('user-1')) // { id: 'user-1', index: 0, value: { name: 'John' }, ... } * ``` */ declare function createRegistry(options?: RegistryOptions): RegistryContext; /** * Creates a new registry context. * * @param options The options for the registry context, including `namespace` (defaults to `'v0:registry'`) and `events`. * @template Z The input ticket shape (extends RegistryTicketInput). * @template E The resolved ticket type returned by get()/values() (extends RegistryTicket & Z). * @returns A new registry context. * * @see https://0.vuetifyjs.com/composables/registration/create-registry * * @example * ```ts * import { createRegistry, createRegistryContext } from '@vuetify/v0' * * // With default namespace 'v0:registry' * export const [useItems, provideItems, items] = createRegistryContext() * * // Or with custom namespace and registry options * export const [useItems, provideItems, items] = createRegistryContext({ namespace: 'my-items', events: true }) * * // In the root component — one registry per app instance (and per SSR request), created * // with the same options: those passed above only configure the default `items` instance * provideItems(createRegistry({ events: true })) * * // In a child component: * const registry = useItems() * registry.register({ id: 'item-1', value: 'Value 1' }) * ``` */ declare function createRegistryContext(_options?: RegistryContextOptions): ContextTrinity>; /** * Uses an existing registry from context. * * @param namespace The namespace for the registry context. Defaults to `'v0:registry'`. * @template Z The input ticket shape (extends RegistryTicketInput). * @template E The resolved ticket type returned by get()/values() (extends RegistryTicket & Z). * @returns The registry instance. * * @see https://0.vuetifyjs.com/composables/registration/create-registry * * @example * ```ts * import { useRegistry } from '@vuetify/v0' * * // In a child component (after provideRegistry was called by an ancestor): * const registry = useRegistry() * * registry.register({ id: 'item-1', value: 'Value 1' }) * ``` */ declare function useRegistry(namespace?: string): RegistryContext; //#endregion //#region src/composables/createModel/index.d.ts /** * Input type for model tickets - what users provide to register(). * * @template V The type of the ticket value. */ interface ModelTicketInput extends RegistryTicketInput { /** Disabled state of the ticket (optional on input, defaults to false) */ disabled?: MaybeRefOrGetter; } /** * Output type for model tickets - what users receive from get(). * * @template Z The input ticket type that extends ModelTicketInput. */ type ModelTicket = RegistryTicket & Z & { /** Disabled state of the ticket (guaranteed to exist on output) */ disabled: MaybeRefOrGetter; /** Whether the ticket is currently selected */ isSelected: Readonly>; }; /** * Context returned by createModel. * * @template Z The input ticket type (what users provide to register). * @template E The output ticket type (what users receive from get). Defaults to ModelTicket. */ interface ModelContext = ModelTicket> extends Omit, 'register'> { /** * Set of currently selected ticket IDs * * @remarks Reactive via `shallowReactive(new Set())`. Mutating this Set directly is supported — * `selectedItems` and `selectedValues` will update accordingly. Ghost IDs (IDs not in the registry) * are silently filtered out by the computed properties. * * @example * ```ts * const model = createModel() * model.register({ id: 'a', value: 'Apple' }) * console.log(model.selectedIds.has('a')) // true (enrolled on register) * ``` */ selectedIds: Reactive>; /** * Computed Set of selected ticket instances * * @remarks Derived from `selectedIds`. Maps each ID to its ticket via `registry.get()` and * filters out any IDs that no longer exist in the registry. * * @example * ```ts * const model = createModel() * model.register({ id: 'a', value: 'Apple' }) * model.select('a') * const items = Array.from(model.selectedItems.value) * console.log(items[0].id) // 'a' * ``` */ selectedItems: ComputedRef>; /** * Computed Set of selected ticket values * * @remarks Derived from `selectedItems`. Unwraps ref values via `toValue()` — if a ticket's * value is `ref('Apple')`, the Set contains `'Apple'`, not the Ref wrapper. * * @example * ```ts * import { shallowRef } from 'vue' * import { createModel } from '@vuetify/v0' * * const model = createModel() * model.register({ id: 'a', value: shallowRef('Apple') }) * model.select('a') * console.log([...model.selectedValues.value]) // ['Apple'] * ``` */ selectedValues: ComputedRef ? U : E['value']>>; /** * Disabled state for the entire model instance * * @remarks When truthy, all selection operations (`select`, `unselect`, `toggle`) are silently * skipped. Accepts a static boolean, a ref, or a getter for reactive disabled state. * * @see https://0.vuetifyjs.com/composables/selection/create-model */ disabled: MaybeRefOrGetter; /** * Reset selection state without destroying the registry * * @remarks Clears `selectedIds` only — registered tickets are preserved. * Use `clear()` to destroy both selection state and the registry. * * @example * ```ts * const model = createModel() * model.register({ id: 'a', value: 'Apple' }) * model.select('a') * model.reset() * console.log(model.size) // 1 (tickets preserved) * console.log(model.selectedIds.size) // 0 * ``` */ reset: () => void; /** * Select a ticket by ID * * @param id The ID of the ticket to select. * @remarks When `multiple` is `false` (default), clears `selectedIds` before adding the new ID. * When `multiple` is `true`, accumulates without clearing. * No-op if the model instance is disabled, the ticket doesn't exist, or the ticket is disabled. * * @see https://0.vuetifyjs.com/composables/selection/create-model * * @example * ```ts * const model = createModel() * model.register({ id: 'a', value: 'Apple' }) * model.register({ id: 'b', value: 'Banana' }) * model.select('a') * model.select('b') // clears 'a', selects 'b' * console.log(model.selectedIds.size) // 1 * ``` */ select: (id: ID) => void; /** * Unselect a ticket by ID * * @param id The ID of the ticket to unselect. * @remarks Removes the ID from `selectedIds`. * No-op if the model instance is disabled, the ticket doesn't exist, or the ticket is disabled. * Wholesale operations (`apply`, `reset`, `clear`) bypass this guard so disabled ids can always drain. * * @example * ```ts * model.select('a') * model.unselect('a') * console.log(model.selectedIds.size) // 0 * ``` */ unselect: (id: ID) => void; /** * Toggle a ticket's selection state * * @param id The ID of the ticket to toggle. * @remarks Calls `select(id)` if not selected, `unselect(id)` if already selected. * No-op if the model instance is disabled or the ticket is disabled. * * @example * ```ts * model.toggle('a') // selects * model.toggle('a') // unselects * ``` */ toggle: (id: ID) => void; /** * Check if a ticket is currently selected * * @param id The ID of the ticket to check. * @returns `true` if the ID is in `selectedIds`. * * @example * ```ts * model.select('a') * console.log(model.selected('a')) // true * console.log(model.selected('b')) // false * ``` */ selected: (id: ID) => boolean; /** * Apply external values to the model * * @param values Array of values to apply. Only `values[0]` is used (single-value store). * @param options Optional. Accepted for interface compatibility with `createSelection`; ignored at this layer. * @remarks Used internally by `useProxyModel` to sync a ref with the model. Two paths: * 1. **Ref write**: Writes `values[0]` to any selected ticket whose value is a ref. * The write is the application — the selection is kept and browse is skipped * (the catalog indexes the ref object, not the unwrapped value). An `undefined` * value leaves the ref untouched. * 2. **Browse resolution**: Otherwise clears `selectedIds`, resolves `values[0]` * via `registry.browse()`, and selects the match. * * @see https://0.vuetifyjs.com/composables/selection/create-model * * @example * ```ts * import { shallowRef } from 'vue' * import { createModel } from '@vuetify/v0' * * const value = shallowRef('Apple') * const model = createModel() * model.register({ id: 'fruit', value }) // enrolled automatically * * model.apply(['Banana']) // value.value is now 'Banana' * ``` */ apply: (values: unknown[], options?: { multiple?: boolean; }) => void; /** * Register a new ticket * * @param registration Partial ticket data. ID is auto-generated if not provided. Disabled defaults to `false`. * @returns The registered ticket with `isSelected` computed ref attached. * @remarks Delegates to `registry.register()` after adding model-specific fields (`disabled`, `isSelected`). * * @see https://0.vuetifyjs.com/composables/selection/create-model * * @example * ```ts * import { shallowRef } from 'vue' * import { createModel } from '@vuetify/v0' * * const model = createModel() * const ticket = model.register({ id: 'fruit', value: shallowRef('Apple') }) * * console.log(ticket.id) // 'fruit' * console.log(ticket.isSelected.value) // true (enrolled by default) * console.log(ticket.disabled) // false * ``` */ register: (registration?: Partial) => E; /** * Onboard multiple tickets at once * * @param registrations An array of partial ticket data to register. * @returns The registered tickets with model-specific fields attached. * @remarks Delegates to the model's `register` (not the registry's) so each ticket * receives `disabled` and `isSelected`. Runs inside `registry.batch()` for performance. */ onboard: (registrations: Partial[]) => E[]; } interface ModelOptions extends RegistryOptions { /** * Disabled state for the entire model instance * * @default false * @remarks When truthy, all selection operations are silently skipped. Accepts a static * boolean, a ref, or a getter for reactive disabled state. * * @example * ```ts * import { createModel } from '@vuetify/v0' * * // Static * const model = createModel({ disabled: true }) * * // Reactive * const disabled = ref(false) * const model = createModel({ disabled }) * ``` */ disabled?: MaybeRefOrGetter; /** * Auto-select tickets on registration * * @default true * @remarks When truthy, newly registered tickets are automatically selected via `select()`, * subject to disabled guards (both instance-level and ticket-level). With single-value * semantics, only the most recently registered ticket remains active. * * `createSelection` overrides this to `false` and handles enrollment with its own * `multiple`-aware logic. */ enroll?: MaybeRefOrGetter; /** * Allow multiple tickets to be selected simultaneously * * @default false * @remarks When `true`, `select()` accumulates IDs instead of clearing before adding. * Used by createSlider where all thumbs must stay selected. */ multiple?: MaybeRefOrGetter; } /** * Creates a new model instance for storing a single value. * * @param options The options for the model instance. * @template Z The input ticket type. Extend {@link ModelTicketInput} to add custom properties. * @template E The output ticket type. Automatically includes `disabled` and `isSelected`. * @template R The context type. Defaults to {@link ModelContext}. * @returns A new model instance with selection tracking and disabled guards. * * @remarks * Extends createRegistry with value tracking via a reactive Set of selected IDs. * Provides the shared model-value concept used by both Selection and Slider. * * **Enrollment**: Tickets are auto-selected on registration by default (`enroll: true`). * With single-value semantics, only the most recently registered ticket is active. * Pass `enroll: false` to opt out. `createSelection` overrides this to `false`. * * **Apply bridge**: `useProxyModel` calls `apply()` to sync a ref with the model. * When the active ticket's value is a ref, `apply` writes to it directly. Otherwise, * it resolves via `registry.browse()`. * * @see https://0.vuetifyjs.com/composables/selection/create-model * * @example * ```ts * import { shallowRef } from 'vue' * import { createModel, useProxyModel } from '@vuetify/v0' * * const value = shallowRef('Apple') * const model = createModel({ events: true }) * * model.register({ id: 'fruit', value }) * useProxyModel(model, value) * * // value and model stay in sync bidirectionally * ``` * * @example * ```ts * // Disabled model — all selection operations are no-ops * const model = createModel({ disabled: true }) * model.register({ id: 'a', value: shallowRef('Apple') }) * model.select('a') // no-op * ``` */ declare function createModel = ModelTicket, R extends ModelContext = ModelContext>(_options?: ModelOptions): R; //#endregion //#region src/composables/createSelection/index.d.ts /** * Input type for selection tickets - what users provide to register(). * Custom ticket types should extend this interface. * * @template V The type of the ticket value. * * @example * ```ts * interface MyTicket extends SelectionTicketInput { * label: string * disabled?: boolean * metadata?: Record * } * * const selection = createSelection() * selection.register({ label: 'Item 1' }) * ``` */ interface SelectionTicketInput extends ModelTicketInput {} /** * Output type for selection tickets - what users receive from get(). * Includes registry-added methods for self-selection. * * @template Z The input ticket type that extends SelectionTicketInput. * * @remarks * The following properties are automatically added by the registry: * - `disabled` - Defaults to `false` if not provided * - `isSelected` - Reactive boolean indicating selection state * - `select()` - Method to select this ticket * - `unselect()` - Method to unselect this ticket * - `toggle()` - Method to toggle selection state */ type SelectionTicket = ModelTicket & { /** Select self */ select: () => void; /** Unselect self */ unselect: () => void; /** Toggle self on and off */ toggle: () => void; }; /** * Context returned by createSelection. * * @template Z The input ticket type (what users provide to register). * @template E The output ticket type (what users receive from get). Defaults to SelectionTicket. */ interface SelectionContext = SelectionTicket> extends Omit, 'register'> { /** Whether the selection allows multiple selections */ multiple: MaybeRefOrGetter; /** Register a new ticket (accepts input type, returns output type) */ register: (ticket?: Partial) => E; /** Onboard multiple tickets at once */ onboard: (registrations: Partial[]) => E[]; /** Mandate selected ID based on "mandatory" option */ mandate: () => void; /** Seek for the first/last non-disabled ticket */ seek: (direction?: 'first' | 'last', from?: number) => E | undefined; } interface SelectionOptions extends ModelOptions { /** * Controls mandatory selection behavior: * - `false` (default): No mandatory selection enforcement * - `true`: Prevents deselecting the last selected item * - `'force'`: Automatically selects the first non-disabled item on registration */ mandatory?: MaybeRefOrGetter; /** When true, treats the selection as an array */ multiple?: MaybeRefOrGetter; /** * Auto-select tickets on registration * * @default false * @remarks Overrides createModel's default of `true`. When truthy, newly registered * items are automatically selected if not disabled. Respects `multiple` mode. */ enroll?: MaybeRefOrGetter; } interface SelectionContextOptions extends SelectionOptions { namespace?: string; } /** * Creates a new selection instance for managing multiple selected items. * * Extends `createModel` with multi-select, mandatory enforcement, * auto-enrollment, and ticket self-methods. * Supports disabled items, mandatory selection enforcement, and auto-enrollment. * * @param options The options for the selection instance. * @template Z The input ticket type - what users provide to register(). Extend SelectionTicketInput to add custom properties. * @template E The output ticket type - what users receive from get(). Automatically includes selection methods. * @template R The context type. Defaults to SelectionContext. * @returns A new selection instance with selection management methods. * * @remarks * **Key Features:** * - Multi-selection support (unlike `createSingle` which enforces single selection) * - Set-based `selectedIds` tracking for efficient lookups * - Computed `selectedItems` and `selectedValues` for reactive access * - Each ticket gets `isSelected`, `select()`, `unselect()`, and `toggle()` methods * - Disabled items cannot be selected * - Mandatory mode prevents deselecting the last item * - Force mode auto-selects first non-disabled item on registration * - Enroll option auto-selects all non-disabled items on registration * * **Inheritance Chain:** * `createRegistry` → `createModel` → `createSelection` → `createSingle`/`createGroup` → `createStep` * * @see https://0.vuetifyjs.com/composables/selection/create-selection * * @example * ```ts * import { createSelection } from '@vuetify/v0' * * // Basic usage * const selection = createSelection({ mandatory: true }) * * selection.onboard([ * { id: 'item-1', value: 'Item 1' }, * { id: 'item-2', value: 'Item 2', disabled: true }, * { id: 'item-3', value: 'Item 3' }, * ]) * * selection.select('item-1') * selection.select('item-3') * * console.log(selection.selectedIds) // Set { 'item-1', 'item-3' } * console.log(Array.from(selection.selectedValues.value)) // ['Item 1', 'Item 3'] * ``` * * @example * ```ts * // With custom ticket type * interface MyTicket extends SelectionTicketInput { * label: string * icon?: string * } * * const tabs = createSelection() * * tabs.register({ label: 'Home', icon: 'mdi-home' }) * tabs.register({ label: 'Settings' }) * * const ticket = tabs.get('...') * // ticket has: label, icon, isSelected, select(), unselect(), toggle() * ``` */ declare function createSelection = SelectionTicket, R extends SelectionContext = SelectionContext>(_options?: SelectionOptions): R; /** * Creates a new selection context. * * @param options The options for the selection context. * @template Z The input ticket type - what users provide to register(). * @template E The output ticket type - what users receive from get(). * @template R The context type. Defaults to SelectionContext. * @returns A new selection context. * * @see https://0.vuetifyjs.com/composables/selection/create-selection * * @example * ```ts * import { createSelectionContext } from '@vuetify/v0' * * // With default namespace 'v0:selection' * export const [useCheckboxes, provideCheckboxes, checkboxes] = createSelectionContext() * * // Or with custom namespace * export const [useCheckboxes, provideCheckboxes, checkboxes] = createSelectionContext({ namespace: 'checkboxes' }) * * // In a parent component: * provideCheckboxes() * * // In a child component: * const checkboxes = useCheckboxes() * checkboxes.select('checkbox-1') * ``` * * @example * ```ts * // With custom ticket type * interface TabTicket extends SelectionTicketInput { * label: string * icon?: string * } * * export const [useTabs, provideTabs, tabs] = createSelectionContext() * ``` */ declare function createSelectionContext = SelectionTicket, R extends SelectionContext = SelectionContext>(_options?: SelectionContextOptions): ContextTrinity; /** * Returns the current selection instance. * * @param namespace The namespace for the selection context. Defaults to `'v0:selection'`. * @template Z The input ticket type. * @template E The output ticket type. * @template R The context type. * @returns The current selection instance. * * @see https://0.vuetifyjs.com/composables/selection/create-selection * * @example * ```vue * * * * ``` */ declare function useSelection = SelectionTicket, R extends SelectionContext = SelectionContext>(namespace?: string): R; //#endregion //#region src/components/Avatar/AvatarRoot.vue.d.ts interface AvatarRootProps extends AtomProps { /** Namespace for dependency injection */ namespace?: string; /** Identifier when used inside Avatar.Group; harmless when standalone */ value?: unknown; /** Disables this avatar's contribution to group capacity math */ disabled?: boolean; /** Namespace of the parent Avatar.Group context */ groupNamespace?: string; } interface AvatarTicket extends SelectionTicket { type?: 'image' | 'fallback'; priority?: number; } interface AvatarContext extends SelectionContext {} interface AvatarRootSlotProps { /** True only when hidden by an enclosing Avatar.Group; false otherwise */ isHidden: boolean; /** Registry index inside an Avatar.Group; 0 when standalone */ index: number; } declare const useAvatarRoot: (key: string, defaultValue?: AvatarContext | undefined) => AvatarContext, provideAvatarRoot: (key: string, context: AvatarContext, app?: import("vue").App) => AvatarContext; declare const _default$17: typeof __VLS_export$221; declare const __VLS_export$221: __VLS_WithSlots$172 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: AvatarRootSlotProps) => unknown; }>; type __VLS_WithSlots$172 = T & { new (): { $slots: S; }; }; //#endregion //#region src/composables/useImage/index.d.ts type ImageStatus = 'idle' | 'loading' | 'loaded' | 'error'; interface UseImageOptions { /** * Image source URL. Changes trigger a reload. */ src: MaybeRefOrGetter; /** * Whether the image should load. When `false`, status stays `idle` and * `source` resolves to `undefined` so the browser does not start loading. * @default true */ eager?: MaybeRefOrGetter; } interface UseImageReturn { /** * Current loading state. */ readonly status: Readonly>; /** * Whether the image has not yet started loading (eager is false). */ readonly isIdle: Readonly>; /** * Whether the image is currently loading. */ readonly isLoading: Readonly>; /** * Whether the image has loaded successfully. */ readonly isLoaded: Readonly>; /** * Whether the image failed to load. */ readonly isError: Readonly>; /** * Gated source URL. Resolves to `undefined` while idle, otherwise the * current `src` value. Bind directly to the `` `src` attribute. */ readonly source: Readonly>; /** * Bind to the `` `load` event. */ onLoad: (e?: Event) => void; /** * Bind to the `` `error` event. */ onError: (e?: Event) => void; /** * Reset status back to `loading` so the browser re-attempts the source. */ retry: () => void; } /** * Tracks image loading state as a reactive state machine. * * @param options Configuration options * @returns Image context with state refs and event handlers * * @see https://0.vuetifyjs.com/composables/system/use-image * * @example * ```ts * import { toRef } from 'vue' * import { useImage } from '@vuetify/v0' * * const props = defineProps<{ src: string }>() * * const { source, isLoaded, onLoad, onError, retry } = useImage({ * src: toRef(() => props.src), * }) * ``` * * @example * Composed with `useIntersectionObserver` for lazy loading: * ```ts * const target = shallowRef() * const { isIntersecting } = useIntersectionObserver(target, () => {}, { * once: true, * rootMargin: '200px', * }) * * const { source, onLoad, onError } = useImage({ * src: toRef(() => props.src), * eager: isIntersecting, * }) * ``` */ declare function useImage(options: UseImageOptions): UseImageReturn; //#endregion //#region src/components/Avatar/AvatarImage.vue.d.ts interface AvatarImageProps extends AtomProps { /** Image source URL */ src?: string; /** Accessible alt text. */ alt?: string; /** Priority for display order (higher = more preferred) */ priority?: number; /** Namespace for retrieving avatar context */ namespace?: string; } interface AvatarImageEmits { load: [e: Event]; error: [e: Event]; } interface AvatarImageSlotProps { /** Whether this image is currently visible */ isSelected: boolean; /** Current loading status */ status: ImageStatus; /** Whether the image has loaded successfully */ isLoaded: boolean; /** Whether the image failed to load */ isError: boolean; /** Reset the image and re-attempt loading */ retry: () => void; /** Attributes to bind to the image element */ attrs: { role: 'img'; src?: string; alt?: string; onLoad: (e: Event) => void; onError: (e: Event) => void; }; } declare const _default$15: typeof __VLS_export$220; declare const __VLS_export$220: __VLS_WithSlots$171 any; load: (e: Event) => any; }, string, import("vue").PublicProps, Readonly & Readonly<{ onError?: ((e: Event) => any) | undefined; onLoad?: ((e: Event) => any) | undefined; }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: AvatarImageSlotProps) => any; }>; type __VLS_WithSlots$171 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/Avatar/AvatarFallback.vue.d.ts interface AvatarFallbackProps extends AtomProps { /** Namespace for retrieving avatar context */ namespace?: string; } interface AvatarFallbackSlotProps { /** Whether this fallback is currently visible */ isSelected: boolean; } declare const _default$13: typeof __VLS_export$219; declare const __VLS_export$219: __VLS_WithSlots$170 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: AvatarFallbackSlotProps) => any; }>; type __VLS_WithSlots$170 = T & { new (): { $slots: S; }; }; //#endregion //#region src/composables/createOverflow/index.d.ts interface OverflowOptions { /** * Container element to track. Can be a ref, getter, or MaybeRefOrGetter. * When provided, useOverflow tracks this element's width automatically. * Also accepts Vue `useTemplateRef` — Vue 3.5.42 wraps that in a deep * `Readonly` that is not assignable to `MaybeRefOrGetter`. */ container?: MaybeRefOrGetter | { readonly value: unknown; }; /** Gap between items in pixels */ gap?: MaybeRefOrGetter; /** Reserved space in pixels (for nav buttons, ellipsis, etc) */ reserved?: MaybeRefOrGetter; /** Uniform item width. Every item must actually be this width. */ itemWidth?: MaybeRefOrGetter; /** * Fit a count that is not mounted yet. Render `capacity`, measure, then call `settle()`. Off by default. * @example * ```ts * const overflow = createOverflow({ container, probe: true, max: () => totalVisible }) * ``` */ probe?: boolean; /** Largest count probe mode may ask for. */ max?: MaybeRefOrGetter; /** * Content-box budget in pixels. When omitted, probe claims free space in the parent instead of the element's own width. */ budget?: MaybeRefOrGetter; /** * Calculate capacity from end instead of start. * Useful for breadcrumbs where trailing items take priority. * Only affects variable mode (uniform mode capacity is direction-independent). */ reverse?: MaybeRefOrGetter; } interface OverflowContext { /** Container element ref */ container: ShallowRef; /** Current container width */ width: Readonly>; /** How many items fit in available space */ capacity: ComputedRef; /** Total width of all measured items */ total: ComputedRef; /** Whether items overflow the container */ isOverflowing: Readonly>; /** * Record an item's width under its index. Pass the element to measure it, * or a number to record a width without reading the DOM, such as one * measured earlier while the item was still visible. Required for every * child in both modes — variable mode reads the recorded widths for * capacity; uniform mode reads only the entry count for isOverflowing. * Pass `undefined` to unregister. Returns the width now recorded, or * `undefined` when the entry was cleared or nothing could be measured. * * @example * ```ts * import { useTemplateRef } from 'vue' * import { createOverflow, createRegistry } from '@vuetify/v0' * * const overflow = createOverflow({ container: useTemplateRef('container') }) * const registry = createRegistry({ reactive: true }) * * // Per item: register, then record its element once it is mounted * const ticket = registry.register() * const el = useTemplateRef('item') * const width = overflow.measure(ticket.index, el.value ?? undefined) // reads the DOM * * overflow.measure(ticket.index, width) // after a reindex: record the number, no DOM read * overflow.measure(ticket.index, undefined) // on unmount: clear * ``` */ measure: (index: number, source?: Element | number) => number | undefined; /** Clear all measurements */ reset: () => void; /** Probe step. No-op unless `probe` is set. Call after `measure`. */ settle: (committed?: boolean) => void; } interface OverflowContextOptions extends OverflowOptions { /** Namespace for dependency injection */ namespace?: string; } /** * Creates a new overflow context for computing how many items fit in a container. * * @param options Configuration options * @returns Overflow context with container ref, capacity, and measurement functions * * @example Variable-width mode (Breadcrumbs) * ```vue * * * * ``` * * @example Uniform-width mode * ```ts * const overflow = createOverflow({ * container: () => atom.value?.element, * itemWidth: buttonWidth, * reserved: () => buttonWidth.value * 4, * }) * ``` */ declare function createOverflow(options?: OverflowOptions): E; /** * Creates an overflow context with dependency injection support. * * @param options Configuration options including namespace * @template E The type of the overflow context * @returns Trinity tuple: [useOverflow, provideOverflow, defaultOverflow] * * @example * ```ts * // Create injectable context * const [useOverflow, provideOverflow, overflow] = createOverflowContext({ * namespace: 'my-overflow', * gap: 8, * reserved: 160, * }) * * // In parent component * provideOverflow() * * // In child component * const overflow = useOverflow() * ``` */ declare function createOverflowContext(_options?: OverflowContextOptions): ContextTrinity; /** * Returns the current overflow context from dependency injection. * * @param namespace The namespace for the overflow context. Defaults to `v0:overflow`. * @template E The type of the overflow context * @returns The current overflow context. * * @throws An error if the overflow context is not found and no default is provided. * * @example * ```vue * * * * ``` */ declare function useOverflow(namespace?: string): E; //#endregion //#region src/components/Avatar/AvatarGroup.vue.d.ts type AvatarGroupPriority = 'start' | 'end'; interface AvatarGroupTicketInput extends RegistryTicketInput { value?: V; disabled?: MaybeRefOrGetter; el?: MaybeRefOrGetter; } interface AvatarGroupTicket extends RegistryTicket { value: V | undefined; disabled: Readonly>; el: Readonly>; } interface AvatarGroupContext { registry: RegistryContext; max: Readonly>; responsive: Readonly>; priority: Readonly>; indicatorWidth: ShallowRef; itemWidth: ShallowRef; overflow: Readonly>; isOverflowing: Readonly>; isVisible: (index: number) => boolean; } interface AvatarGroupProps extends AtomProps { /** Namespace for dependency injection (must match Avatar.Root groupNamespace) */ namespace?: string; /** Upper bound on visible count; default Infinity */ max?: number; /** Opt-in width-responsive truncation via createOverflow */ responsive?: boolean; /** Which side keeps items when truncated */ priority?: AvatarGroupPriority; /** Pixel gap between items; only meaningful when responsive */ gap?: number; /** Accessible name for the group */ label?: string; /** ID of element that labels this group */ ariaLabelledby?: string; /** ID of element that describes this group */ ariaDescribedby?: string; } interface AvatarGroupSlotProps { /** Total number of registered, non-disabled avatars in the group */ total: number; visible: number; hidden: AvatarGroupTicket[]; isOverflowing: boolean; attrs: { 'role': 'group'; 'aria-label': string | undefined; 'aria-labelledby': string | undefined; 'aria-describedby': string | undefined; 'data-overflow': true | undefined; 'data-priority': AvatarGroupPriority; }; } declare const useAvatarGroup: (key: string, defaultValue?: AvatarGroupContext | null | undefined) => AvatarGroupContext | null, provideAvatarGroup: (key: string, context: AvatarGroupContext | null, app?: import("vue").App) => AvatarGroupContext | null; declare const _default$14: typeof __VLS_export$218; declare const __VLS_export$218: __VLS_WithSlots$169 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: AvatarGroupSlotProps) => unknown; }>; type __VLS_WithSlots$169 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/Avatar/AvatarIndicator.vue.d.ts interface AvatarIndicatorProps extends AtomProps { /** Namespace of the parent Avatar.Group context */ namespace?: string; } interface AvatarIndicatorSlotProps { count: number; hidden: AvatarGroupTicket[]; attrs: { 'aria-label': string | undefined; 'aria-live': 'polite'; 'data-overflow-indicator': 'true'; }; } declare const _default$16: typeof __VLS_export$217; declare const __VLS_export$217: __VLS_WithSlots$168 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: AvatarIndicatorSlotProps) => unknown; }>; type __VLS_WithSlots$168 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/Avatar/index.d.ts /** * Avatar component with sub-components for building avatars. * * @see https://0.vuetifyjs.com/components/semantic/avatar */ declare const Avatar: { /** * Root component for avatars. * * @see https://0.vuetifyjs.com/components/semantic/avatar * * @example * ```vue * * * * ``` */ Root: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: AvatarRootSlotProps) => unknown; }; }); /** * Image inside an Avatar.Root. Registers with the avatar's image * selection and shows when loaded. * * @see https://0.vuetifyjs.com/components/semantic/avatar */ Image: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{ onError?: ((e: Event) => any) | undefined; onLoad?: ((e: Event) => any) | undefined; }>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, { error: (e: Event) => any; load: (e: Event) => any; }, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{ onError?: ((e: Event) => any) | undefined; onLoad?: ((e: Event) => any) | undefined; }>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{ onError?: ((e: Event) => any) | undefined; onLoad?: ((e: Event) => any) | undefined; }>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, { error: (e: Event) => any; load: (e: Event) => any; }, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: AvatarImageSlotProps) => any; }; }); /** * Fallback content when no image is loaded. * * @see https://0.vuetifyjs.com/components/semantic/avatar */ Fallback: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: AvatarFallbackSlotProps) => any; }; }); /** * Group container for stacked / collapsing avatars. Owns the visibility * math driven by `max` and (optionally) width-based truncation. * * @see https://0.vuetifyjs.com/components/semantic/avatar * * @example * ```vue * * * * ``` */ Group: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: AvatarGroupSlotProps) => unknown; }; }); /** * Overflow indicator for Avatar.Group. Renders only when items are * hidden. Slot receives the hidden count and hidden tickets. * * @see https://0.vuetifyjs.com/components/semantic/avatar */ Indicator: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: AvatarIndicatorSlotProps) => unknown; }; }); }; //#endregion //#region src/composables/createSingle/index.d.ts /** * Input type for single selection tickets. * Extend this interface to add custom properties. */ interface SingleTicketInput extends SelectionTicketInput {} /** * Output type for single selection tickets. * Includes all input properties plus selection methods. */ type SingleTicket = SelectionTicket; /** * Context returned by createSingle. * * @template Z The input ticket type. * @template E The output ticket type. */ interface SingleContext = SingleTicket> extends Omit, 'register' | 'onboard'> { selectedId: Readonly>; selectedIndex: Readonly>; selectedItem: Readonly>; selectedValue: Readonly>; /** Register a new ticket (accepts input type, returns output type) */ register: (ticket?: Partial) => E; /** Onboard multiple tickets at once */ onboard: (registrations: Partial[]) => E[]; } interface SingleOptions extends SelectionOptions {} interface SingleContextOptions extends SelectionContextOptions {} /** * Creates a new single selection instance that enforces only one selected item at a time. * * Extends `createSelection` by automatically clearing previous selections when a new item is selected. * Adds computed singular properties: `selectedId`, `selectedItem`, `selectedIndex`, `selectedValue`. * * @param options The options for the single selection instance. * @template Z The input ticket type - what users provide to register(). * @template E The output ticket type - what users receive from get(). * @template R The context type. * @returns A new single selection instance with single-selection enforcement. * * @remarks * **Key Differences from `createSelection`:** * - Automatically clears `selectedIds` before selecting a new item (enforces single selection) * - Provides singular computed properties instead of plural sets * - Perfect for tabs, radio buttons, theme selectors, and other single-choice UI components * * **Computed Properties:** * - `selectedId`: The ID of the selected item (undefined if none selected) * - `selectedItem`: The selected ticket object (undefined if none selected) * - `selectedIndex`: The index of the selected item (-1 if none selected) * - `selectedValue`: The value of the selected item (undefined if none selected) * * **Inheritance Chain:** * `createRegistry` → `createSelection` → `createSingle` → `createStep` * * @see https://0.vuetifyjs.com/composables/selection/create-single * * @example * ```ts * import { createSingle } from '@vuetify/v0' * * const tabs = createSingle({ mandatory: true }) * * tabs.onboard([ * { id: 'home', value: 'Home' }, * { id: 'about', value: 'About' }, * { id: 'contact', value: 'Contact' }, * ]) * * tabs.first() // Select first tab * * console.log(tabs.selectedId.value) // 'home' * console.log(tabs.selectedIndex.value) // 0 * * tabs.select('about') // Switch to about tab * console.log(tabs.selectedId.value) // 'about' * console.log(tabs.selectedIds.size) // 1 (always enforces single selection) * ``` * * @example * ```ts * // With custom ticket type * interface TabTicket extends SingleTicketInput { * label: string * icon?: string * } * * const tabs = createSingle() * tabs.register({ label: 'Home', icon: 'mdi-home' }) * ``` */ declare function createSingle = SingleTicket, R extends SingleContext = SingleContext>(_options?: SingleOptions): R; /** * Creates a new single selection context. * * @param options The options for the single selection context. * @template Z The input ticket type. * @template E The output ticket type. * @template R The context type. * @returns A new single selection context. * * @see https://0.vuetifyjs.com/composables/selection/create-single * * @example * ```ts * import { createSingleContext } from '@vuetify/v0' * * // With default namespace 'v0:single' * export const [useSingle, provideSingle, context] = createSingleContext() * * // In a parent component: * provideSingle() * * // In a child component: * const single = useSingle() * single.select('tab-1') * ``` */ declare function createSingleContext = SingleTicket, R extends SingleContext = SingleContext>(_options?: SingleContextOptions): ContextTrinity; /** * Returns the current single selection instance. * * @param namespace The namespace for the single selection context. Defaults to `'v0:single'`. * @template Z The input ticket type. * @template E The output ticket type. * @template R The context type. * @returns The current single selection instance. * * @see https://0.vuetifyjs.com/composables/selection/create-single * * @example * ```vue * * * * ``` */ declare function useSingle = SingleTicket, R extends SingleContext = SingleContext>(namespace?: string): R; //#endregion //#region src/composables/createBreadcrumbs/index.d.ts /** * Input type for breadcrumb tickets. */ interface BreadcrumbTicketInput extends SingleTicketInput { /** Display text for the breadcrumb */ text: string; } /** * Output type for breadcrumb tickets. */ type BreadcrumbTicket = SingleTicket; /** * Context returned by createBreadcrumbs. */ interface BreadcrumbsContext = BreadcrumbTicket> extends Omit, 'select'> { /** Number of items in the path */ depth: Readonly>; /** Whether at root level (depth <= 1) */ isRoot: Readonly>; /** Whether path is empty (depth === 0) */ isEmpty: Readonly>; /** Navigate to root (first item) */ first: () => void; /** Navigate up one level (remove last item) */ prev: () => void; /** Navigate to specific item by id (truncates path) */ select: (id: ID) => void; } interface BreadcrumbsOptions extends SingleOptions {} interface BreadcrumbsContextOptions extends SingleContextOptions {} /** * Creates a breadcrumbs navigation model. * * @param options The options for the breadcrumbs instance. * @returns A breadcrumbs context with navigation methods. * * @example * ```ts * import { createBreadcrumbs } from '@vuetify/v0' * * const breadcrumbs = createBreadcrumbs() * * breadcrumbs.register({ text: 'Home' }) * breadcrumbs.register({ text: 'Products' }) * breadcrumbs.register({ text: 'Electronics' }) * * // Navigate back * breadcrumbs.prev() // removes Electronics * breadcrumbs.first() // truncates to Home * * // Derived state * breadcrumbs.depth.value // 1 * breadcrumbs.isRoot.value // true * ``` */ declare function createBreadcrumbs = BreadcrumbTicket, R extends BreadcrumbsContext = BreadcrumbsContext>(options?: BreadcrumbsOptions): R; /** * Creates a breadcrumbs context for dependency injection. * * @param options The options including namespace. * @returns A trinity: [useBreadcrumbs, provideBreadcrumbs, defaultContext] * * @example * ```ts * const [useBreadcrumbs, provideBreadcrumbs] = createBreadcrumbsContext() * * // Parent component * provideBreadcrumbs() * * // Child component * const breadcrumbs = useBreadcrumbs() * breadcrumbs.register({ text: 'Details' }) * ``` */ declare function createBreadcrumbsContext = BreadcrumbTicket, R extends BreadcrumbsContext = BreadcrumbsContext>(_options?: BreadcrumbsContextOptions): ContextTrinity; /** * Returns the current breadcrumbs instance from context. * * @param namespace The namespace. @default 'v0:breadcrumbs' * @returns The breadcrumbs context. * * @example * ```vue * * * * ``` */ declare function useBreadcrumbs = BreadcrumbTicket, R extends BreadcrumbsContext = BreadcrumbsContext>(namespace?: string): R; //#endregion //#region src/composables/createGroup/index.d.ts /** * Input type for group tickets. * Extend this interface to add custom properties. */ interface GroupTicketInput extends SelectionTicketInput { /** Whether the ticket should start in mixed/indeterminate state */ indeterminate?: MaybeRefOrGetter; } /** * Output type for group tickets. * Includes all input properties plus selection and tri-state methods. */ type GroupTicket = SelectionTicket & { /** Whether the ticket is in a mixed/indeterminate state */ isMixed: Readonly>; /** Set self to mixed/indeterminate state */ mix: () => void; /** Clear mixed/indeterminate state from self */ unmix: () => void; }; /** * Context returned by createGroup. * * @template Z The input ticket type. * @template E The output ticket type. */ interface GroupContext = GroupTicket> extends Omit, 'register' | 'onboard' | 'select' | 'unselect' | 'toggle'> { selectedIndexes: ComputedRef>; /** Select one or more Tickets by ID */ select: (ids: ID | ID[]) => void; /** Unselect one or more Tickets by ID */ unselect: (ids: ID | ID[]) => void; /** Toggle one or more Tickets ON and OFF by ID */ toggle: (ids: ID | ID[]) => void; /** Set of mixed/indeterminate ticket IDs */ mixedIds: Reactive>; /** Set of mixed/indeterminate ticket instances */ mixedItems: ComputedRef>; /** Set one or more Tickets to mixed/indeterminate state by ID */ mix: (ids: ID | ID[]) => void; /** Clear mixed/indeterminate state from one or more Tickets by ID */ unmix: (ids: ID | ID[]) => void; /** Check if a ticket is in mixed/indeterminate state by ID */ mixed: (id: ID) => boolean; /** Whether no items are currently selected */ isNoneSelected: Readonly>; /** Whether all selectable (non-disabled) items are selected */ isAllSelected: ComputedRef; /** Whether some but not all selectable items are selected */ isMixed: ComputedRef; /** Select all selectable (non-disabled) items */ selectAll: () => void; /** Unselect all items (respects mandatory option) */ unselectAll: () => void; /** Toggle between all selected and none selected */ toggleAll: () => void; /** Register a new ticket (accepts input type, returns output type) */ register: (ticket?: Partial) => E; /** Onboard multiple tickets at once */ onboard: (registrations: Partial[]) => E[]; } interface GroupOptions extends SelectionOptions {} interface GroupContextOptions extends SelectionContextOptions {} /** * Creates a new group instance with batch selection and tri-state support. * * Extends `createSelection` to support selecting, unselecting, and toggling multiple items * at once by passing an array of IDs. Adds tri-state (mixed/indeterminate) support for * checkbox trees and similar use cases. * * @param options The options for the group instance. * @template Z The type of the group ticket. * @template E The type of the group context. * @returns A new group instance with batch selection and tri-state support. * * @remarks * **Key Differences from `createSelection`:** * - `select()` accepts `ID | ID[]` for batch operations * - `unselect()` accepts `ID | ID[]` for batch operations * - `toggle()` accepts `ID | ID[]` for batch operations * - Adds `selectedIndexes` computed Set for getting selected item indexes * - Adds tri-state support via `mix()`, `unmix()`, `mixed()`, `mixedIds`, `mixedItems` * - Perfect for checkbox trees, multi-select dropdowns, and bulk operations * * **Tri-State Support:** * - Items can be in one of three states: selected, mixed (indeterminate), or unselected * - `mix(id)` sets item to mixed state (clears selected if set) * - `unmix(id)` clears mixed state * - `select(id)` clears mixed state before selecting * - `toggle(id)` on a mixed item selects it (resolves the indeterminate state positively) * - Mixed state works on disabled items (it's a computed state, not user action) * * **Batch Operations:** * - Single ID: `group.select('item-1')` * - Array of IDs: `group.select(['item-1', 'item-2', 'item-3'])` * - Uses `toArray()` utility internally to normalize input * - Disabled items are automatically skipped in select operations * - Non-existent IDs are silently ignored * * **Inheritance Chain:** * `createRegistry` → `createSelection` → `createGroup` * * **Used By:** * - `createFeatures` for feature flag management with multiple selections * * @see https://0.vuetifyjs.com/composables/selection/create-group * * @example * ```ts * import { createGroup } from '@vuetify/v0' * * const checkboxes = createGroup() * * checkboxes.onboard([ * { id: 'option-a', value: 'Option A' }, * { id: 'option-b', value: 'Option B' }, * { id: 'option-c', value: 'Option C' }, * ]) * * // Select multiple items at once * checkboxes.select(['option-a', 'option-c']) * * console.log(checkboxes.selectedIds) // Set { 'option-a', 'option-c' } * console.log(Array.from(checkboxes.selectedIndexes.value)) // [0, 2] * * // Set item to mixed/indeterminate state * checkboxes.mix('option-a') * console.log(checkboxes.mixedIds) // Set { 'option-a' } * console.log(checkboxes.selectedIds) // Set { 'option-c' } (option-a removed) * * // Toggle a mixed item selects it * checkboxes.toggle('option-a') * console.log(checkboxes.selectedIds) // Set { 'option-a', 'option-c' } * console.log(checkboxes.mixedIds) // Set {} (cleared) * ``` */ declare function createGroup = GroupTicket, R extends GroupContext = GroupContext>(_options?: GroupOptions): R; /** * Creates a new group context. * * @param options The options for the group context. * @template Z The input ticket type. * @template E The output ticket type. * @template R The context type. * @returns A new group context. * * @see https://0.vuetifyjs.com/composables/selection/create-group * * @example * ```ts * import { createGroupContext } from '@vuetify/v0' * * // With default namespace 'v0:group' * export const [useMyGroup, provideMyGroup, myGroup] = createGroupContext() * * // Or with custom namespace * export const [useMyGroup, provideMyGroup, myGroup] = createGroupContext({ namespace: 'my-group' }) * * // In a parent component: * provideMyGroup() * * // In a child component: * const group = useMyGroup() * ``` */ declare function createGroupContext = GroupTicket, R extends GroupContext = GroupContext>(_options?: GroupContextOptions): ContextTrinity; /** * Returns the current group instance. * * @param namespace The namespace for the group context. Defaults to `'v0:group'`. * @template Z The input ticket type. * @template E The output ticket type. * @template R The context type. * @returns The current group instance. * * @see https://0.vuetifyjs.com/composables/selection/create-group * * @example * ```vue * * * * ``` */ declare function useGroup = GroupTicket, R extends GroupContext = GroupContext>(namespace?: string): R; //#endregion //#region src/components/Breadcrumbs/types.d.ts type BreadcrumbsTicketType = 'item' | 'divider' | 'ellipsis' | 'activator'; interface BreadcrumbsTicket extends GroupTicket { /** Type of breadcrumb element */ type: BreadcrumbsTicketType; } interface BreadcrumbsRootContext { /** Breadcrumbs composable context for navigation and state */ breadcrumbs: BreadcrumbsContext; /** Group context for managing item registration and selection (overflow) */ group: GroupContext; /** Overflow context for width measurement and capacity calculation */ overflow: OverflowContext; /** Default divider character/text */ divider: Ref; /** Default ellipsis character/text */ ellipsis: Ref; /** Whether items are being truncated */ isOverflowing: Readonly>; /** Whether collapsed items are revealed via the ellipsis disclosure */ expanded: ShallowRef; /** Whether a BreadcrumbsActivator is registered in the trail */ hasActivator: Readonly>; /** Number of breadcrumb items currently hidden by truncation */ hiddenCount: Readonly>; /** Measured ellipsis width in pixels (set by BreadcrumbsEllipsis) */ ellipsisWidth: ShallowRef; /** * Record a part's width under its index — the first item and first divider go to * reserved space, the rest to the overflow pool. Pass the element to measure it, a * number to record a width without reading the DOM, or `undefined` to clear. Returns * the width now recorded. */ measureElement: (index: number, type: 'item' | 'divider', source?: Element | number) => number | undefined; } //#endregion //#region src/components/Breadcrumbs/BreadcrumbsRoot.vue.d.ts interface BreadcrumbsRootProps extends AtomProps { /** Namespace for dependency injection */ namespace?: string; /** Default divider character/text */ divider?: string; /** Default ellipsis character/text */ ellipsis?: string; /** Gap between items in pixels. @default 8 */ gap?: number; /** Accessible label for the navigation landmark */ label?: string; } interface BreadcrumbsRootSlotProps { /** Whether items are being truncated */ isOverflowing: boolean; /** Number of items that fit in available space */ capacity: number; /** Total number of registered items */ total: number; /** Current depth of the breadcrumb path */ depth: number; /** Whether at root level */ isRoot: boolean; /** Navigate to root */ first: () => void; /** Navigate up one level */ prev: () => void; /** Navigate to a specific item */ select: (id: ID) => void; /** Attributes to bind to the root element */ attrs: { 'aria-label': string; 'role': 'navigation' | undefined; }; } declare const useBreadcrumbsRoot: (key: string, defaultValue?: BreadcrumbsRootContext | undefined) => BreadcrumbsRootContext, provideBreadcrumbsRoot: (key: string, context: BreadcrumbsRootContext, app?: import("vue").App) => BreadcrumbsRootContext; declare const _default$25: typeof __VLS_export$216; declare const __VLS_export$216: __VLS_WithSlots$167 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: BreadcrumbsRootSlotProps) => unknown; }>; type __VLS_WithSlots$167 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/Breadcrumbs/BreadcrumbsList.vue.d.ts interface BreadcrumbsListProps extends AtomProps {} interface BreadcrumbsListSlotProps { attrs: { role: 'list'; }; } declare const _default$23: typeof __VLS_export$215; declare const __VLS_export$215: __VLS_WithSlots$166 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: BreadcrumbsListSlotProps) => unknown; }>; type __VLS_WithSlots$166 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/Breadcrumbs/BreadcrumbsItem.vue.d.ts interface BreadcrumbsItemProps extends AtomProps { /** Namespace for dependency injection */ namespace?: string; /** Unique identifier (auto-generated if not provided) */ id?: ID; /** Value associated with this item */ value?: unknown; /** Display text for the breadcrumb (used by composable model) */ text?: string; } interface BreadcrumbsItemSlotProps { /** Unique identifier */ id: ID; /** Whether this item is currently selected (visible) */ isSelected: boolean; /** Attributes to bind to the item element */ attrs: { 'inert': true | undefined; 'data-selected': true | undefined; }; } declare const _default$21: typeof __VLS_export$214; declare const __VLS_export$214: __VLS_WithSlots$165 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: BreadcrumbsItemSlotProps) => unknown; }>; type __VLS_WithSlots$165 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/Breadcrumbs/BreadcrumbsPage.vue.d.ts interface BreadcrumbsPageProps extends AtomProps {} interface BreadcrumbsPageSlotProps { /** Attributes to bind to the page element */ attrs: { 'aria-current': 'page'; }; } declare const _default$24: typeof __VLS_export$213; declare const __VLS_export$213: __VLS_WithSlots$164 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: BreadcrumbsPageSlotProps) => unknown; }>; type __VLS_WithSlots$164 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/Breadcrumbs/BreadcrumbsDivider.vue.d.ts interface BreadcrumbsDividerProps extends AtomProps { /** Namespace for dependency injection */ namespace?: string; /** Unique identifier (auto-generated if not provided) */ id?: ID; /** Override divider character (uses global from Root if not provided) */ divider?: string; } interface BreadcrumbsDividerSlotProps { /** Unique identifier */ id: ID; /** Resolved divider character */ divider: string; /** Whether this divider is currently selected (visible) */ isSelected: boolean; /** Attributes to bind to the divider element */ attrs: { 'aria-hidden': 'true'; 'data-selected': true | undefined; }; } declare const _default$19: typeof __VLS_export$212; declare const __VLS_export$212: __VLS_WithSlots$163 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: BreadcrumbsDividerSlotProps) => unknown; }>; type __VLS_WithSlots$163 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/Breadcrumbs/BreadcrumbsEllipsis.vue.d.ts interface BreadcrumbsEllipsisProps extends AtomProps { /** Namespace for dependency injection */ namespace?: string; /** Unique identifier (auto-generated if not provided) */ id?: ID; /** Override ellipsis character (uses global from Root if not provided) */ ellipsis?: string; } interface BreadcrumbsEllipsisSlotProps { /** Unique identifier */ id: ID; /** Resolved ellipsis character */ ellipsis: string; /** Whether the ellipsis is currently selected (visible) */ isSelected: boolean; /** Number of breadcrumb items hidden by truncation */ count: number; /** Attributes to bind to the ellipsis element */ attrs: { 'aria-hidden': 'true' | undefined; 'data-selected': true | undefined; }; } declare const _default$20: typeof __VLS_export$211; declare const __VLS_export$211: __VLS_WithSlots$162 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: BreadcrumbsEllipsisSlotProps) => unknown; }>; type __VLS_WithSlots$162 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/Breadcrumbs/BreadcrumbsActivator.vue.d.ts interface BreadcrumbsActivatorProps extends AtomProps { /** Namespace for dependency injection */ namespace?: string; } interface BreadcrumbsActivatorSlotProps { /** Whether the collapsed crumbs are currently revealed */ isExpanded: boolean; /** Number of breadcrumb items hidden by truncation */ count: number; /** Toggle visibility of the collapsed crumbs */ toggle: () => void; /** Attributes to bind to the activator element */ attrs: { 'type': 'button' | undefined; 'role': 'button' | undefined; 'tabindex': 0 | undefined; 'aria-expanded': boolean; 'aria-label': string; 'data-state': 'open' | 'closed'; 'onClick': () => void; 'onKeydown': ((e: KeyboardEvent) => void) | undefined; }; } declare const _default$18: typeof __VLS_export$210; declare const __VLS_export$210: __VLS_WithSlots$161 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: BreadcrumbsActivatorSlotProps) => unknown; }>; type __VLS_WithSlots$161 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/Breadcrumbs/BreadcrumbsLink.vue.d.ts type BreadcrumbsLinkProps = AtomProps; declare const _default$22: typeof __VLS_export$209; declare const __VLS_export$209: __VLS_WithSlots$160 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default?: (props: {}) => any; }>; type __VLS_WithSlots$160 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/Breadcrumbs/index.d.ts /** * Breadcrumbs component for responsive navigation trails. * * @see https://0.vuetifyjs.com/components/semantic/breadcrumbs */ declare const Breadcrumbs: { /** * Root component for breadcrumb navigation. * Creates breadcrumbs composable + Group + Overflow context. * * @see https://0.vuetifyjs.com/components/semantic/breadcrumbs * * @example * ```vue * * * * ``` */ Root: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: BreadcrumbsRootSlotProps) => unknown; }; }); /** * Semantic list wrapper for breadcrumb items. * Renders as an ordered list with role="list". * * @see https://0.vuetifyjs.com/components/semantic/breadcrumbs * * @example * ```vue * * ``` */ List: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: BreadcrumbsListSlotProps) => unknown; }; }); /** * Individual breadcrumb item. Registers with root and * self-measures for overflow visibility. * * @see https://0.vuetifyjs.com/components/semantic/breadcrumbs * * @example * ```vue * * ``` */ Item: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: BreadcrumbsItemSlotProps) => unknown; }; }); /** * Navigable breadcrumb link. Renders as an anchor by default. * All attributes (href, to, etc.) fall through to the underlying element. * * @see https://0.vuetifyjs.com/components/semantic/breadcrumbs * * @example * ```vue * * ``` */ Link: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default?: (props: {}) => any; }; }); /** * Current page indicator. Renders as a span with * aria-current="page". * * @see https://0.vuetifyjs.com/components/semantic/breadcrumbs * * @example * ```vue * * ``` */ Page: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: BreadcrumbsPageSlotProps) => unknown; }; }); /** * Visual separator between breadcrumb items. Renders as a list * item with aria-hidden="true". Uses divider character from Root * by default, or override via prop or slot content. * * @see https://0.vuetifyjs.com/components/semantic/breadcrumbs * * @example * ```vue * * ``` */ Divider: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: BreadcrumbsDividerSlotProps) => unknown; }; }); /** * Ellipsis indicator shown when items are truncated by overflow. * Auto-hidden until overflow is detected. Renders with * aria-hidden="true". * * @see https://0.vuetifyjs.com/components/semantic/breadcrumbs * * @example * ```vue * * ``` */ Ellipsis: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: BreadcrumbsEllipsisSlotProps) => unknown; }; }); /** * Disclosure control that reveals the crumbs hidden by truncation. * Place inside an Ellipsis, which stays the list item. * * @see https://0.vuetifyjs.com/components/semantic/breadcrumbs * * @example * ```vue * * ``` */ Activator: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: BreadcrumbsActivatorSlotProps) => unknown; }; }); }; //#endregion //#region src/components/Button/ButtonContent.vue.d.ts interface ButtonContentProps { /** Unique identifier for ticket registration */ id?: ID; /** Namespace for context injection from parent Button.Root */ namespace?: string; } interface ButtonContentSlotProps { isSelected: boolean; } declare const _default$26: typeof __VLS_export$208; declare const __VLS_export$208: __VLS_WithSlots$159 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: ButtonContentSlotProps) => any; }>; type __VLS_WithSlots$159 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/Button/ButtonGroup.vue.d.ts /** Ticket for button items with element reference for focus management */ interface ButtonTicket extends SelectionTicket { /** Element reference for group focus management */ el?: MaybeRefOrGetter; } /** Imperative handle exposed by Button.Group. */ interface ButtonGroupExpose { /** Focus the selected button, or the first if none is selected. */ focus: (options?: FocusOptions) => void; } interface ButtonGroupProps extends AtomProps { /** Namespace for dependency injection */ namespace?: string; /** Disables the entire button group */ disabled?: boolean; /** Single (default) or multi-select */ multiple?: boolean; /** * Controls mandatory selection behavior: * - false (default): No mandatory enforcement * - true: Prevents deselecting the last selected item * - `force`: Automatically selects the first non-disabled item on registration */ mandatory?: boolean | 'force'; /** Accessible name for the group */ label?: string; /** ID of element that labels this group */ ariaLabelledby?: string; /** ID of element that describes this group */ ariaDescribedby?: string; } interface ButtonGroupSlotProps { /** Whether the button group is disabled */ isDisabled: boolean; /** Attributes to bind to the root element */ attrs: { 'role': 'group'; 'aria-label': string | undefined; 'aria-labelledby': string | undefined; 'aria-describedby': string | undefined; }; } declare const useButtonGroup: (key: string, defaultValue?: SelectionContext> | undefined) => SelectionContext>, provideButtonGroup: (key: string, context: SelectionContext>, app?: import("vue").App) => SelectionContext>; declare const _default$27: typeof __VLS_export$207; declare const __VLS_export$207: (__VLS_props: NonNullable>["props"], __VLS_ctx?: __VLS_PrettifyLocal$38>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable>["expose"], __VLS_setup?: Promise<{ props: import("vue").PublicProps & __VLS_PrettifyLocal$38<(ButtonGroupProps & { modelValue?: T | T[]; }) & { "onUpdate:modelValue"?: ((value: T | T[] | undefined) => any) | undefined; "onUpdate:model-value"?: ((value: T | T[]) => any) | undefined; }> & (typeof globalThis extends { __VLS_PROPS_FALLBACK: infer P; } ? P : {}); expose: (exposed: import("vue").ShallowUnwrapRef) => void; attrs: any; slots: { default: (props: ButtonGroupSlotProps) => any; }; emit: ((evt: "update:model-value", value: T | T[]) => void) & ((event: "update:modelValue", value: T | T[] | undefined) => void); }>) => import("vue").VNode & { __ctx?: NonNullable>; }; type __VLS_PrettifyLocal$38 = (T extends any ? { [K in keyof T]: T[K]; } : { [K in keyof T as K]: T[K]; }) & {}; //#endregion //#region src/components/Button/ButtonHiddenInput.vue.d.ts interface ButtonHiddenInputProps { /** Namespace for context injection from parent Button.Root */ namespace?: string; /** Form field name */ name?: string; /** Submitted value (defaults to 'on') */ value?: string; /** Associate with form by ID */ form?: string; } declare const _default$28: typeof __VLS_export$206; declare const __VLS_export$206: import("vue").DefineComponent & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>; //#endregion //#region src/components/Button/ButtonIcon.vue.d.ts interface ButtonIconProps extends AtomProps { /** Namespace for context injection from parent Button.Root */ namespace?: string; } interface ButtonIconSlotProps { /** Whether this is an icon-only button */ isSolo: boolean; /** Attributes to bind to the icon element */ attrs: { 'aria-hidden': true; }; } declare const _default$29: typeof __VLS_export$205; declare const __VLS_export$205: __VLS_WithSlots$158 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: ButtonIconSlotProps) => any; }>; type __VLS_WithSlots$158 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/Button/ButtonLoading.vue.d.ts interface ButtonLoadingProps { /** Unique identifier for ticket registration */ id?: ID; /** Namespace for context injection from parent Button.Root */ namespace?: string; } interface ButtonLoadingSlotProps { /** Whether this loading indicator is currently selected/visible */ isSelected: boolean; } declare const _default$30: typeof __VLS_export$204; declare const __VLS_export$204: __VLS_WithSlots$157 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: ButtonLoadingSlotProps) => any; }>; type __VLS_WithSlots$157 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/Button/ButtonRoot.vue.d.ts interface ButtonRootContext { /** The button's value (for group registration / form submission) */ value: unknown; /** Form field name */ name?: string; /** Form association ID */ form?: string; /** Whether the button is in the loading state (after grace period) */ isLoading: Readonly>; /** Whether the button is disabled */ isDisabled: Readonly>; /** Whether the button is readonly */ isReadonly: Readonly>; /** Whether the button is passive */ isPassive: Readonly>; /** Whether the button is selected (in group mode) */ isSelected: Readonly>; /** Whether the button is an icon-only button */ isSolo: Ref; /** Internal single selection for Loading/Content visibility */ single: SingleContext; } interface ButtonRootProps extends AtomProps { /** Disables the button — fully non-interactive, removed from tab order */ disabled?: boolean; /** Non-clickable but looks normal, remains focusable/hoverable */ readonly?: boolean; /** Non-clickable, looks disabled via [data-passive], remains focusable/hoverable */ passive?: boolean; /** Triggers loading state with grace period before visual indicator */ loading?: boolean; /** Duration in ms before loading UI appears (0 to show immediately) */ grace?: number; /** Value for use inside Button.Group */ value?: V; /** Namespace for context provision to children */ namespace?: string; /** Namespace for connecting to parent Button.Group */ groupNamespace?: string; /** Form field name — auto-renders HiddenInput when set */ name?: string; /** Associate with form by ID */ form?: string; /** Accessible label for the button */ ariaLabel?: string; } interface ButtonRootSlotProps { /** Whether the button is in the loading state (after grace period) */ isLoading: boolean; /** Whether the button is disabled */ isDisabled: boolean; /** Whether the button is readonly */ isReadonly: boolean; /** Whether the button is passive */ isPassive: boolean; /** Whether the button is selected (in group mode) */ isSelected: boolean; /** Attributes to bind to the button element */ attrs: { 'type': 'button' | undefined; 'role': 'button'; 'disabled': true | undefined; 'aria-disabled': boolean; 'aria-busy': true | undefined; 'aria-pressed': boolean | undefined; 'aria-label': string | undefined; 'tabindex': 0 | -1 | undefined; 'data-loading': true | undefined; 'data-passive': true | undefined; 'data-readonly': true | undefined; 'data-disabled': true | undefined; 'data-selected': true | undefined; 'data-solo': true | undefined; 'onClick': (() => void) | undefined; 'onKeydown': ((e: KeyboardEvent) => void) | undefined; }; } declare const useButtonRoot: (key: string, defaultValue?: ButtonRootContext | undefined) => ButtonRootContext, provideButtonRoot: (key: string, context: ButtonRootContext, app?: import("vue").App) => ButtonRootContext; declare const _default$31: typeof __VLS_export$203; declare const __VLS_export$203: (__VLS_props: NonNullable>["props"], __VLS_ctx?: __VLS_PrettifyLocal$37>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable>["expose"], __VLS_setup?: Promise<{ props: import("vue").PublicProps & __VLS_PrettifyLocal$37> & (typeof globalThis extends { __VLS_PROPS_FALLBACK: infer P; } ? P : {}); expose: (exposed: import("vue").ShallowUnwrapRef) => void; attrs: any; slots: { default: (props: ButtonRootSlotProps) => any; }; emit: {}; }>) => import("vue").VNode & { __ctx?: NonNullable>; }; type __VLS_PrettifyLocal$37 = (T extends any ? { [K in keyof T]: T[K]; } : { [K in keyof T as K]: T[K]; }) & {}; //#endregion //#region src/components/Button/index.d.ts /** * Button component with sub-components for interactive button controls. * * @see https://0.vuetifyjs.com/components/actions/button * * @example * ```vue * * * * ``` */ declare const Button: { /** * Default content area for buttons. * * Registers with Root's internal selection as the fallback. * Always rendered, selected when Loading is not active. * * @see https://0.vuetifyjs.com/components/actions/button * * @example * ```vue * * * * ``` */ Content: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: ButtonContentSlotProps) => any; }; }); /** * Selection container for toggle button groups. * * @see https://0.vuetifyjs.com/components/actions/button * * @example * ```vue * * * * ``` */ Group: (__VLS_props: NonNullable>["props"], __VLS_ctx?: { attrs: any; emit: ((evt: "update:model-value", value: T | T[]) => void) & ((event: "update:modelValue", value: T | T[] | undefined) => void); slots: { default: (props: ButtonGroupSlotProps) => any; }; }, __VLS_exposed?: NonNullable>["expose"], __VLS_setup?: Promise<{ props: import("vue").PublicProps & { namespace?: string | undefined; disabled?: boolean | undefined; multiple?: boolean | undefined; mandatory?: boolean | "force" | undefined; label?: string | undefined; ariaLabelledby?: string | undefined; ariaDescribedby?: string | undefined; as?: (DOMElement | null) | undefined; renderless?: boolean | undefined; modelValue?: (T | T[]) | undefined; "onUpdate:modelValue"?: ((value: T | T[] | undefined) => any) | undefined; "onUpdate:model-value"?: ((value: T | T[]) => any) | undefined; } & (typeof globalThis extends { __VLS_PROPS_FALLBACK: infer P; } ? P : {}); expose: (exposed: import("vue").ShallowUnwrapRef) => void; attrs: any; slots: { default: (props: ButtonGroupSlotProps) => any; }; emit: ((evt: "update:model-value", value: T | T[]) => void) & ((event: "update:modelValue", value: T | T[] | undefined) => void); }>) => import("vue").VNode & { __ctx?: NonNullable>; }; /** * Hidden input component for form submission. * * @see https://0.vuetifyjs.com/components/actions/button * * @example * ```vue * * * * ``` */ HiddenInput: import("vue").DefineComponent & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>; /** * Icon wrapper with accessibility enforcement. * * Sets `aria-hidden="true"` on itself. Detects solo buttons * and warns when `aria-label` is missing on Root. * * @see https://0.vuetifyjs.com/components/actions/button * * @example * ```vue * * * * ``` */ Icon: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: ButtonIconSlotProps) => any; }; }); /** * Loading indicator that becomes visible after the grace period. * * Registers with Root's internal selection. Enabled and selected * when Root's isLoading becomes true (after grace period). * * @see https://0.vuetifyjs.com/components/actions/button * * @example * ```vue * * * * ``` */ Loading: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: ButtonLoadingSlotProps) => any; }; }); /** * Root component for buttons. * * Renders as a button with proper ARIA attributes. Supports * disabled, readonly, passive, and loading states. When inside * a Button.Group, registers as a toggle button. * * @see https://0.vuetifyjs.com/components/actions/button * * @example * ```vue * * * * ``` */ Root: (__VLS_props: NonNullable>["props"], __VLS_ctx?: { attrs: any; emit: {}; slots: { default: (props: ButtonRootSlotProps) => any; }; }, __VLS_exposed?: NonNullable>["expose"], __VLS_setup?: Promise<{ props: import("vue").PublicProps & { disabled?: boolean | undefined; readonly?: boolean | undefined; passive?: boolean | undefined; loading?: boolean | undefined; grace?: number | undefined; value?: V | undefined; namespace?: string | undefined; groupNamespace?: string | undefined; name?: string | undefined; form?: string | undefined; ariaLabel?: string | undefined; as?: (DOMElement | null) | undefined; renderless?: boolean | undefined; } & (typeof globalThis extends { __VLS_PROPS_FALLBACK: infer P; } ? P : {}); expose: (exposed: import("vue").ShallowUnwrapRef) => void; attrs: any; slots: { default: (props: ButtonRootSlotProps) => any; }; emit: {}; }>) => import("vue").VNode & { __ctx?: NonNullable>; }; }; //#endregion //#region src/composables/createStep/index.d.ts /** * Input type for step tickets. * Extend this interface to add custom properties. */ interface StepTicketInput extends SingleTicketInput {} /** * Output type for step tickets. * Includes all input properties plus selection methods. */ type StepTicket = SingleTicket; /** * Context returned by createStep. * * @template Z The input ticket type. * @template E The output ticket type. */ interface StepContext = StepTicket> extends Omit, 'register' | 'onboard'> { /** Select the first Ticket in the collection */ first: () => void; /** Select the last Ticket in the collection */ last: () => void; /** Select the next Ticket based on current index */ next: () => void; /** Select the previous Ticket based on current index */ prev: () => void; /** Step through the collection by a given count */ step: (count: number) => void; /** Register a new ticket (accepts input type, returns output type) */ register: (ticket?: Partial) => E; /** Onboard multiple tickets at once */ onboard: (registrations: Partial[]) => E[]; } interface StepOptions extends SingleOptions { /** * Enable circular navigation (wrapping at boundaries). * - true: Navigation wraps around (carousel behavior) * - false: Navigation stops at boundaries (pagination behavior) * @default false */ circular?: boolean; } interface StepContextOptions extends SingleContextOptions { /** * Enable circular navigation (wrapping at boundaries). * - true: Navigation wraps around (carousel behavior) * - false: Navigation stops at boundaries (pagination behavior) * @default false */ circular?: boolean; } /** * Creates a new step instance with navigation through items. * * Extends `createSingle` with `first()`, `last()`, `next()`, `prev()`, and `step(count)` methods * for sequential navigation. Supports both circular (wrapping) and bounded (stopping at edges) modes. * * @param options The options for the step instance. * @template Z The type of the step ticket. * @template E The type of the step context. * @returns A new step instance with navigation methods. * * @remarks * **Key Features:** * - **Configurable Navigation**: `circular: true` for wrapping, `false` for bounded (default: false) * - **Disabled Item Skipping**: Automatically skips disabled items during navigation * - **Bidirectional**: Forward (`next`, positive `step`) and backward (`prev`, negative `step`) * - **Safe Edge Cases**: Handles empty registries and all-disabled scenarios gracefully * * **Navigation Methods:** * - `first()`: Select first non-disabled item * - `last()`: Select last non-disabled item * - `next()`: Move to next item (wraps if circular, stops at end if bounded) * - `prev()`: Move to previous item (wraps if circular, stops at start if bounded) * - `step(count)`: Move by `count` positions (negative for backward) * * **Circular Mode (`circular: true`):** * - Uses modulo arithmetic for wrapping: `((index % length) + length) % length` * - Works correctly with negative indexes and large step counts * - Perfect for carousels, theme switchers, infinite scrolling * * **Bounded Mode (`circular: false`, default):** * - Navigation stops at boundaries (no wrapping) * - `next()` on last item does nothing * - `prev()` on first item does nothing * - Perfect for pagination, wizards with explicit completion, forms * * **Inheritance Chain:** * `createRegistry` → `createSelection` → `createSingle` → `createStep` * * @see https://0.vuetifyjs.com/composables/selection/create-step * * @example * ```ts * import { createStep } from '@vuetify/v0' * * // Bounded navigation (default) - for pagination * const pagination = createStep({ circular: false }) * pagination.onboard([ * { id: 'page-1', value: 1 }, * { id: 'page-2', value: 2 }, * { id: 'page-3', value: 3 }, * ]) * pagination.first() // Select page 1 * pagination.prev() // Does nothing (already at first) * pagination.next() // Select page 2 * * // Circular navigation - for carousels * const carousel = createStep({ circular: true }) * carousel.onboard([ * { id: 'slide-1', value: 'First' }, * { id: 'slide-2', value: 'Second' }, * { id: 'slide-3', value: 'Third' }, * ]) * carousel.first() * carousel.prev() // Wraps to 'slide-3' * carousel.next() // Wraps to 'slide-1' * ``` */ declare function createStep = StepTicket, R extends StepContext = StepContext>(_options?: StepOptions): R; /** * Creates a new step context. * * @param options The options for the step context. * @template Z The input ticket type. * @template E The output ticket type. * @template R The context type. * @returns A new step context. * * @see https://0.vuetifyjs.com/composables/selection/create-step * * @example * ```ts * import { createStepContext } from '@vuetify/v0' * * // With default namespace 'v0:step' * export const [useStep, provideStep, context] = createStepContext() * * // In a parent component: * provideStep() * * // In a child component: * const context = useStep() * context.next() // Progress to next step * ``` */ declare function createStepContext = StepTicket, R extends StepContext = StepContext>(_options?: StepContextOptions): ContextTrinity; /** * Returns the current step instance. * * @param namespace The namespace for the step context. Defaults to `'v0:step'`. * @template Z The input ticket type. * @template E The output ticket type. * @template R The context type. * @returns The current step instance. * * @see https://0.vuetifyjs.com/composables/selection/create-step * * @example * ```vue * * * * ``` */ declare function useStep = StepTicket, R extends StepContext = StepContext>(namespace?: string): R; //#endregion //#region src/components/Carousel/CarouselRoot.vue.d.ts type CarouselOrientation = 'horizontal' | 'vertical'; interface CarouselTicket extends StepTicket { /** Element reference for DOM measurement */ el?: MaybeRefOrGetter; } interface CarouselRootProps extends AtomProps { /** Unique identifier for the carousel */ id?: string; /** Accessible label for the carousel region */ label?: string; /** Namespace for dependency injection (must match child namespace) */ namespace?: string; /** Disables the entire carousel */ disabled?: boolean; /** Whether navigation wraps around from last to first */ circular?: boolean; /** Carousel orientation */ orientation?: CarouselOrientation; /** Number of slides visible at once */ perView?: number; /** Autoplay interval in milliseconds. 0 disables autoplay. */ autoplay?: number; /** Scroll behavior for programmatic navigation */ behavior?: ScrollBehavior; } interface CarouselRootSlotProps { /** Whether the carousel is disabled */ isDisabled: boolean; /** Current orientation */ orientation: CarouselOrientation; /** Number of slides visible at once */ perView: number; /** Select the first slide */ first: () => void; /** Select the last slide */ last: () => void; /** Select the next slide */ next: () => void; /** Select the previous slide */ prev: () => void; /** Step forward or backward by a specific count */ step: (count: number) => void; /** Select a slide by ID */ select: (id: ID) => void; /** Whether autoplay is active */ isAutoplay: boolean; /** Whether autoplay is paused */ isPaused: boolean; /** Milliseconds remaining until next slide */ remaining: number; /** Start or restart autoplay from full interval */ play: () => void; /** Stop autoplay and reset timer */ stop: () => void; /** Pause autoplay, preserving remaining time */ pause: () => void; /** Resume autoplay from where it was paused */ resume: () => void; /** Attributes to bind to the root element */ attrs: { 'role': 'region'; 'aria-roledescription': 'carousel'; 'aria-label': string; 'aria-disabled': boolean; 'data-disabled': true | undefined; }; } interface CarouselPartTicket extends RegistryTicketInput { type: 'viewport' | 'previous' | 'next' | 'indicator' | 'progress' | 'live-region'; el: MaybeRefOrGetter; } interface CarouselContext extends StepContext { /** Carousel orientation */ orientation: Ref; /** Number of slides visible at once */ perView: Ref; /** Whether navigation wraps around */ circular: Ref; /** Root ID for generating sub-component IDs */ rootId: string; /** Scroll behavior for programmatic navigation */ behavior: Ref; /** Registry for structural sub-components */ parts: RegistryContext; /** Autoplay interval duration in ms (0 = disabled) */ autoplay: Readonly>; /** Milliseconds remaining until next auto-advance */ remaining: Readonly>; /** Whether autoplay is currently active */ isAutoplay: Readonly>; /** Whether autoplay is currently paused */ isPaused: Readonly>; /** Restart autoplay from full interval */ play: () => void; /** Stop autoplay and reset the timer */ stop: () => void; /** Pause autoplay timer */ pause: () => void; /** Resume autoplay timer from remaining time */ resume: () => void; } declare const useCarouselRoot: (key: string, defaultValue?: CarouselContext | undefined) => CarouselContext, provideCarouselRoot: (key: string, context: CarouselContext, app?: import("vue").App) => CarouselContext; declare const _default$38: typeof __VLS_export$202; declare const __VLS_export$202: (__VLS_props: NonNullable>["props"], __VLS_ctx?: __VLS_PrettifyLocal$36>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable>["expose"], __VLS_setup?: Promise<{ props: import("vue").PublicProps & __VLS_PrettifyLocal$36<(CarouselRootProps & { modelValue?: T | T[]; }) & { "onUpdate:modelValue"?: ((value: T | T[] | undefined) => any) | undefined; "onUpdate:model-value"?: ((value: T | T[]) => any) | undefined; }> & (typeof globalThis extends { __VLS_PROPS_FALLBACK: infer P; } ? P : {}); expose: (exposed: {}) => void; attrs: any; slots: { default: (props: CarouselRootSlotProps) => any; }; emit: ((evt: "update:model-value", value: T | T[]) => void) & ((event: "update:modelValue", value: T | T[] | undefined) => void); }>) => import("vue").VNode & { __ctx?: NonNullable>; }; type __VLS_PrettifyLocal$36 = (T extends any ? { [K in keyof T]: T[K]; } : { [K in keyof T as K]: T[K]; }) & {}; //#endregion //#region src/components/Carousel/CarouselViewport.vue.d.ts interface CarouselViewportProps extends AtomProps { /** Namespace for connecting to parent Carousel.Root */ namespace?: string; } interface CarouselViewportSlotProps { /** Whether the user is currently dragging/scrolling */ isDragging: boolean; /** Attributes to bind to the viewport element */ attrs: { 'id': string; 'data-orientation': 'horizontal' | 'vertical'; 'data-dragging': true | undefined; 'style': Record; }; } declare const _default$39: typeof __VLS_export$201; declare const __VLS_export$201: __VLS_WithSlots$156 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: CarouselViewportSlotProps) => any; }>; type __VLS_WithSlots$156 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/Carousel/CarouselItem.vue.d.ts interface CarouselItemProps extends AtomProps { /** Unique identifier (auto-generated if not provided) */ id?: ID; /** Value associated with this slide */ value?: V; /** Disables this specific slide */ disabled?: boolean | MaybeRefOrGetter; /** Namespace for dependency injection */ namespace?: string; } interface CarouselItemSlotProps { /** Unique identifier */ id: string; /** Whether this slide is the selected (anchor) slide */ isSelected: boolean; /** Whether this slide is in the visible window */ isActive: boolean; /** Whether this slide is disabled */ isDisabled: boolean; /** Slide index in the carousel */ index: number; /** Select this slide */ select: () => void; /** Unselect this slide */ unselect: () => void; /** Toggle this slide's selection state */ toggle: () => void; /** Attributes to bind to the slide element */ attrs: { 'id': string; 'role': 'group'; 'aria-roledescription': 'slide'; 'aria-label': string; 'aria-hidden': true | undefined; 'data-selected': true | undefined; 'data-active': true | undefined; 'data-disabled': true | undefined; 'data-index': number; 'style': Record; }; } declare const _default$33: typeof __VLS_export$200; declare const __VLS_export$200: (__VLS_props: NonNullable>["props"], __VLS_ctx?: __VLS_PrettifyLocal$35>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable>["expose"], __VLS_setup?: Promise<{ props: import("vue").PublicProps & __VLS_PrettifyLocal$35> & (typeof globalThis extends { __VLS_PROPS_FALLBACK: infer P; } ? P : {}); expose: (exposed: {}) => void; attrs: any; slots: { default: (props: CarouselItemSlotProps) => any; }; emit: {}; }>) => import("vue").VNode & { __ctx?: NonNullable>; }; type __VLS_PrettifyLocal$35 = (T extends any ? { [K in keyof T]: T[K]; } : { [K in keyof T as K]: T[K]; }) & {}; //#endregion //#region src/components/Carousel/CarouselPrevious.vue.d.ts interface CarouselPreviousProps extends AtomProps { /** Namespace for connecting to parent Carousel.Root */ namespace?: string; } interface CarouselPreviousSlotProps { /** Whether the button is disabled */ isDisabled: boolean; /** Whether the carousel is at the first slide (non-circular) */ isAtEdge: boolean; /** Attributes to bind to the button element */ attrs: { 'type': 'button' | undefined; 'role': 'button' | undefined; 'tabindex': number; 'aria-label': string; 'aria-controls': string; 'aria-disabled': boolean; 'disabled': boolean | undefined; 'data-disabled': true | undefined; 'data-edge': true | undefined; 'onClick': () => void; 'onKeydown': ((e: KeyboardEvent) => void) | undefined; }; } declare const _default$36: typeof __VLS_export$199; declare const __VLS_export$199: __VLS_WithSlots$155 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: CarouselPreviousSlotProps) => any; }>; type __VLS_WithSlots$155 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/Carousel/CarouselNext.vue.d.ts interface CarouselNextProps extends AtomProps { /** Namespace for connecting to parent Carousel.Root */ namespace?: string; } interface CarouselNextSlotProps { /** Whether the button is disabled */ isDisabled: boolean; /** Whether the carousel is at the last slide (non-circular) */ isAtEdge: boolean; /** Attributes to bind to the button element */ attrs: { 'type': 'button' | undefined; 'role': 'button' | undefined; 'tabindex': number; 'aria-label': string; 'aria-controls': string; 'aria-disabled': boolean; 'disabled': boolean | undefined; 'data-disabled': true | undefined; 'data-edge': true | undefined; 'onClick': () => void; 'onKeydown': ((e: KeyboardEvent) => void) | undefined; }; } declare const _default$35: typeof __VLS_export$198; declare const __VLS_export$198: __VLS_WithSlots$154 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: CarouselNextSlotProps) => any; }>; type __VLS_WithSlots$154 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/Carousel/CarouselIndicator.vue.d.ts interface CarouselIndicatorProps extends AtomProps { /** Accessible label for the indicator group */ label?: string; /** Namespace for connecting to parent Carousel.Root */ namespace?: string; } interface CarouselIndicatorItem { /** Slide index (0-based) */ index: number; /** Whether this indicator's slide is selected */ isSelected: boolean; /** Whether this indicator's slide is in the visible window */ isActive: boolean; /** Attributes to bind to each indicator element */ attrs: { 'role': 'tab'; 'tabindex': 0 | -1; 'aria-selected': boolean; 'aria-controls': string; 'aria-label': string; 'data-selected': true | undefined; 'data-active': true | undefined; 'onClick': () => void; 'onKeydown': (e: KeyboardEvent) => void; }; } interface CarouselIndicatorSlotProps { /** Total number of slides */ size: number; /** Currently selected slide index */ selectedIndex: number; /** Array of indicator items with per-dot state and attrs */ items: CarouselIndicatorItem[]; /** Attributes to bind to the indicator container */ attrs: { 'role': 'tablist'; 'aria-label': string; 'aria-orientation': 'horizontal' | 'vertical'; }; } declare const _default$32: typeof __VLS_export$197; declare const __VLS_export$197: __VLS_WithSlots$153 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: CarouselIndicatorSlotProps) => any; }>; type __VLS_WithSlots$153 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/Carousel/CarouselProgress.vue.d.ts interface CarouselProgressProps extends AtomProps { /** Namespace for connecting to parent Carousel.Root */ namespace?: string; } interface CarouselProgressSlotProps { /** Progress value from 0 to 1 */ progress: number; /** Whether autoplay is currently active */ isAutoplay: boolean; /** Whether autoplay is paused */ isPaused: boolean; /** Attributes to bind to the progress element */ attrs: { 'role': 'progressbar'; 'aria-valuenow': number; 'aria-valuemin': 0; 'aria-valuemax': 100; 'aria-valuetext': string; 'aria-label': string; 'data-state': 'active' | 'paused' | 'idle'; 'style': { width: string; }; }; } declare const _default$37: typeof __VLS_export$196; declare const __VLS_export$196: __VLS_WithSlots$152 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: CarouselProgressSlotProps) => any; }>; type __VLS_WithSlots$152 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/Carousel/CarouselLiveRegion.vue.d.ts interface CarouselLiveRegionProps extends AtomProps { /** Namespace for connecting to parent Carousel.Root */ namespace?: string; } interface CarouselLiveRegionSlotProps { /** Current slide number (1-indexed) */ current: number; /** Total number of slides */ size: number; /** Announcement text */ text: string; /** Attributes to bind to the live region element */ attrs: { 'aria-atomic': true; 'aria-live': 'off' | 'polite'; 'role': 'status'; }; } declare const _default$34: typeof __VLS_export$195; declare const __VLS_export$195: __VLS_WithSlots$151 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: CarouselLiveRegionSlotProps) => any; }>; type __VLS_WithSlots$151 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/Carousel/index.d.ts /** * Carousel component with sub-components for building accessible slide navigation. * * @see https://0.vuetifyjs.com/components/semantic/carousel * * @example * ```vue * * * * ``` */ declare const Carousel: { /** * Root component that provides carousel context. * * @see https://0.vuetifyjs.com/components/semantic/carousel * * @example * ```vue * * * * ``` */ Root: (__VLS_props: NonNullable>["props"], __VLS_ctx?: { attrs: any; emit: ((evt: "update:model-value", value: T | T[]) => void) & ((event: "update:modelValue", value: T | T[] | undefined) => void); slots: { default: (props: CarouselRootSlotProps) => any; }; }, __VLS_exposed?: NonNullable>["expose"], __VLS_setup?: Promise<{ props: import("vue").PublicProps & { id?: string | undefined; label?: string | undefined; namespace?: string | undefined; disabled?: boolean | undefined; circular?: boolean | undefined; orientation?: CarouselOrientation | undefined; perView?: number | undefined; autoplay?: number | undefined; behavior?: ScrollBehavior | undefined; as?: (DOMElement | null) | undefined; renderless?: boolean | undefined; modelValue?: (T | T[]) | undefined; "onUpdate:modelValue"?: ((value: T | T[] | undefined) => any) | undefined; "onUpdate:model-value"?: ((value: T | T[]) => any) | undefined; } & (typeof globalThis extends { __VLS_PROPS_FALLBACK: infer P; } ? P : {}); expose: (exposed: {}) => void; attrs: any; slots: { default: (props: CarouselRootSlotProps) => any; }; emit: ((evt: "update:model-value", value: T | T[]) => void) & ((event: "update:modelValue", value: T | T[] | undefined) => void); }>) => import("vue").VNode & { __ctx?: NonNullable>; }; /** * Scroll-snap container for carousel items. Handles native drag/swipe * via CSS scroll-snap and synchronizes scroll position with selection. * * @see https://0.vuetifyjs.com/components/semantic/carousel * * @example * ```vue * * ``` */ Viewport: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, AtomExpose, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, AtomExpose, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, AtomExpose, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: CarouselViewportSlotProps) => any; }; }); /** * Individual carousel slide that registers with the step context. * Exposes selection state, visibility, and ARIA attributes. * * @see https://0.vuetifyjs.com/components/semantic/carousel * * @example * ```vue * * ``` */ Item: (__VLS_props: NonNullable>["props"], __VLS_ctx?: { attrs: any; emit: {}; slots: { default: (props: CarouselItemSlotProps) => any; }; }, __VLS_exposed?: NonNullable>["expose"], __VLS_setup?: Promise<{ props: import("vue").PublicProps & { id?: ID | undefined; value?: V | undefined; disabled?: (boolean | import("vue").MaybeRefOrGetter) | undefined; namespace?: string | undefined; as?: (DOMElement | null) | undefined; renderless?: boolean | undefined; } & (typeof globalThis extends { __VLS_PROPS_FALLBACK: infer P; } ? P : {}); expose: (exposed: {}) => void; attrs: any; slots: { default: (props: CarouselItemSlotProps) => any; }; emit: {}; }>) => import("vue").VNode & { __ctx?: NonNullable>; }; /** * Navigation button that moves to the previous slide. Automatically * disables at the first slide in non-circular mode. * * @see https://0.vuetifyjs.com/components/semantic/carousel * * @example * ```vue * * ``` */ Previous: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: CarouselPreviousSlotProps) => any; }; }); /** * Navigation button that moves to the next slide. Automatically * disables at the last visible boundary in non-circular mode. * * @see https://0.vuetifyjs.com/components/semantic/carousel * * @example * ```vue * * ``` */ Next: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: CarouselNextSlotProps) => any; }; }); /** * Dot indicator navigation showing the active slide. Exposes an * `items` array via slot props — one entry per slide with selection * state and ARIA attributes. Uses roving tabindex for keyboard nav. * * @see https://0.vuetifyjs.com/components/semantic/carousel * * @example * ```vue * * ``` */ Indicator: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: CarouselIndicatorSlotProps) => any; }; }); /** * Autoplay progress bar that fills based on remaining timer duration. * Exposes progress (0–1), autoplay state, and width styling via * slot props. Use `data-state` to style active/paused/idle states. * * @see https://0.vuetifyjs.com/components/semantic/carousel * * @example * ```vue * * ``` */ Progress: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: CarouselProgressSlotProps) => any; }; }); /** * Visually-hidden live region that announces slide changes to screen * readers. Should be styled with sr-only/visually-hidden CSS. * * @see https://0.vuetifyjs.com/components/semantic/carousel * * @example * ```vue * * ``` */ LiveRegion: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: CarouselLiveRegionSlotProps) => any; }; }); }; //#endregion //#region src/components/Checkbox/CheckboxGroup.vue.d.ts /** Ticket for checkbox items with element reference for focus management */ interface CheckboxTicket extends GroupTicket { /** Element reference for group focus management */ el?: MaybeRefOrGetter; } /** Imperative handle exposed by Checkbox.Group. */ interface CheckboxGroupExpose { /** Focus the selected checkbox, or the first if none is selected. */ focus: (options?: FocusOptions) => void; } interface CheckboxGroupProps extends AtomProps { /** Namespace for dependency injection */ namespace?: string; /** Disables the entire checkbox group */ disabled?: boolean; /** Auto-select non-disabled items on registration */ enroll?: boolean; /** * Controls mandatory checkbox behavior: * - false (default): No mandatory enforcement * - true: Prevents deselecting the last selected item * - `force`: Automatically selects the first non-disabled item on registration */ mandatory?: boolean | 'force'; /** Accessible name for the group */ label?: string; /** ID of element that labels this group */ ariaLabelledby?: string; /** ID of element that describes this group */ ariaDescribedby?: string; } interface CheckboxGroupSlotProps { /** Whether the checkbox group is disabled */ isDisabled: boolean; /** Whether no items are currently selected */ isNoneSelected: boolean; /** Whether all selectable (non-disabled) items are selected */ isAllSelected: boolean; /** Whether some but not all selectable items are selected */ isMixed: boolean; /** Select an item by ID */ select: (id: ID | ID[]) => void; /** Unselect an item by ID */ unselect: (id: ID | ID[]) => void; /** Toggle an item's selection state by ID */ toggle: (id: ID | ID[]) => void; /** Select all selectable (non-disabled) items */ selectAll: () => void; /** Unselect all items (respects mandatory option) */ unselectAll: () => void; /** Toggle between all selected and none selected */ toggleAll: () => void; /** Attributes to bind to the root element */ attrs: { 'role': 'group'; 'aria-label': string | undefined; 'aria-labelledby': string | undefined; 'aria-describedby': string | undefined; }; } declare const useCheckboxGroup: (key: string, defaultValue?: GroupContext> | undefined) => GroupContext>, provideCheckboxGroup: (key: string, context: GroupContext>, app?: import("vue").App) => GroupContext>; declare const _default$40: typeof __VLS_export$194; declare const __VLS_export$194: (__VLS_props: NonNullable>["props"], __VLS_ctx?: __VLS_PrettifyLocal$34>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable>["expose"], __VLS_setup?: Promise<{ props: import("vue").PublicProps & __VLS_PrettifyLocal$34<(CheckboxGroupProps & { modelValue?: T | T[]; }) & { "onUpdate:modelValue"?: ((value: T | T[] | undefined) => any) | undefined; "onUpdate:model-value"?: ((value: T | T[]) => any) | undefined; }> & (typeof globalThis extends { __VLS_PROPS_FALLBACK: infer P; } ? P : {}); expose: (exposed: import("vue").ShallowUnwrapRef) => void; attrs: any; slots: { default: (props: CheckboxGroupSlotProps) => any; }; emit: ((evt: "update:model-value", value: T | T[]) => void) & ((event: "update:modelValue", value: T | T[] | undefined) => void); }>) => import("vue").VNode & { __ctx?: NonNullable>; }; type __VLS_PrettifyLocal$34 = (T extends any ? { [K in keyof T]: T[K]; } : { [K in keyof T as K]: T[K]; }) & {}; //#endregion //#region src/components/Checkbox/CheckboxHiddenInput.vue.d.ts interface CheckboxHiddenInputProps { /** Namespace for context injection from parent Checkbox.Root */ namespace?: string; /** Form field name (defaults to context value) */ name?: string; /** Submitted value when checked (defaults to context value or 'on') */ value?: string; /** Associate with form by ID (defaults to context value) */ form?: string; } declare const _default$41: typeof __VLS_export$193; declare const __VLS_export$193: import("vue").DefineComponent & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>; //#endregion //#region src/components/Checkbox/CheckboxRoot.vue.d.ts /** Visual state of the checkbox for styling purposes */ type CheckboxState = 'checked' | 'unchecked' | 'indeterminate'; interface CheckboxRootContext { /** Unique identifier */ readonly id: ID; /** Optional display label */ readonly label?: string; /** Value associated with this checkbox */ readonly value: V | undefined; /** Form field name (triggers auto hidden input when provided) */ readonly name?: string; /** Associate with form by ID */ readonly form?: string; /** Whether this checkbox is currently checked */ isChecked: Readonly>; /** Whether this checkbox is in a mixed/indeterminate state */ isMixed: Readonly>; /** Whether this checkbox is disabled */ isDisabled: Readonly>; /** Check this checkbox */ select: () => void; /** Uncheck this checkbox */ unselect: () => void; /** Toggle this checkbox's state */ toggle: () => void; /** Set this checkbox to mixed/indeterminate state (group mode only) */ mix: () => void; /** Clear mixed/indeterminate state (group mode only) */ unmix: () => void; } interface CheckboxRootProps extends AtomProps { /** Unique identifier (auto-generated if not provided) */ id?: ID; /** Optional display label (passed through to slot) */ label?: string; /** Value associated with this checkbox (used in group mode and form submission) */ value?: V; /** Form field name - triggers auto hidden input when provided */ name?: string; /** Associate with form by ID */ form?: string; /** Disables this checkbox */ disabled?: boolean | MaybeRefOrGetter; /** Sets the indeterminate state */ indeterminate?: boolean | MaybeRefOrGetter; /** Namespace for context provision to children (Indicator, HiddenInput) */ namespace?: string; /** Namespace for connecting to parent Checkbox.Group */ groupNamespace?: string; /** ID of element that labels this checkbox */ ariaLabelledby?: string; /** ID of element that describes this checkbox */ ariaDescribedby?: string; /** Whether the checkbox has an invalid value */ ariaInvalid?: boolean; } interface CheckboxRootSlotProps { /** Unique identifier */ id: ID; /** Optional display label */ label?: string; /** Value associated with this checkbox */ value: V | undefined; /** Whether this checkbox is currently checked */ isChecked: boolean; /** Whether this checkbox is in a mixed/indeterminate state */ isMixed: boolean; /** Whether this checkbox is disabled */ isDisabled: boolean; /** Check this checkbox */ select: () => void; /** Uncheck this checkbox */ unselect: () => void; /** Toggle this checkbox's state */ toggle: () => void; /** Set this checkbox to mixed/indeterminate state (group mode only) */ mix: () => void; /** Clear mixed/indeterminate state (group mode only) */ unmix: () => void; /** Attributes to bind to the checkbox element */ attrs: { 'type': 'button' | undefined; 'role': 'checkbox'; 'aria-checked': boolean | 'mixed'; 'aria-disabled': boolean; 'aria-label': string | undefined; 'aria-labelledby': string | undefined; 'aria-describedby': string | undefined; 'aria-invalid': boolean | undefined; 'tabindex': 0 | undefined; 'data-state': CheckboxState; 'data-disabled': true | undefined; 'onClick': () => void; 'onKeydown': (e: KeyboardEvent) => void; }; } declare const useCheckboxRoot: (key: string, defaultValue?: CheckboxRootContext | undefined) => CheckboxRootContext, provideCheckboxRoot: (key: string, context: CheckboxRootContext, app?: import("vue").App) => CheckboxRootContext; declare const _default$43: typeof __VLS_export$192; declare const __VLS_export$192: (__VLS_props: NonNullable>["props"], __VLS_ctx?: __VLS_PrettifyLocal$33>, "attrs" | "emit" | "slots">>, __VLS_exposed?: NonNullable>["expose"], __VLS_setup?: Promise<{ props: import("vue").PublicProps & __VLS_PrettifyLocal$33<(CheckboxRootProps & { modelValue?: boolean; }) & { "onUpdate:modelValue"?: ((value: boolean | undefined) => any) | undefined; "onUpdate:model-value"?: ((value: boolean) => any) | undefined; }> & (typeof globalThis extends { __VLS_PROPS_FALLBACK: infer P; } ? P : {}); expose: (exposed: import("vue").ShallowUnwrapRef) => void; attrs: any; slots: { default: (props: CheckboxRootSlotProps) => any; }; emit: ((evt: "update:model-value", value: boolean) => void) & ((event: "update:modelValue", value: boolean | undefined) => void); }>) => import("vue").VNode & { __ctx?: NonNullable>; }; type __VLS_PrettifyLocal$33 = (T extends any ? { [K in keyof T]: T[K]; } : { [K in keyof T as K]: T[K]; }) & {}; //#endregion //#region src/components/Checkbox/CheckboxIndicator.vue.d.ts interface CheckboxIndicatorProps extends AtomProps { /** Namespace for context injection from parent Checkbox.Root */ namespace?: string; } interface CheckboxIndicatorSlotProps { /** Whether this checkbox is currently checked */ isChecked: boolean; /** Whether this checkbox is in a mixed/indeterminate state */ isMixed: boolean; /** Attributes to bind to the indicator element */ attrs: { 'data-state': CheckboxState; 'style': { visibility: 'visible' | 'hidden'; }; }; } declare const _default$42: typeof __VLS_export$191; declare const __VLS_export$191: __VLS_WithSlots$150 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: CheckboxIndicatorSlotProps) => any; }>; type __VLS_WithSlots$150 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/Checkbox/CheckboxSelectAll.vue.d.ts interface CheckboxSelectAllProps extends AtomProps { /** Optional display label (passed through to slot and aria-label) */ label?: string; /** Disables this checkbox */ disabled?: boolean; /** Namespace for context provision to children (Indicator) */ namespace?: string; /** Namespace for connecting to parent Checkbox.Group */ groupNamespace?: string; /** ID of element that labels this checkbox */ ariaLabelledby?: string; /** ID of element that describes this checkbox */ ariaDescribedby?: string; } interface CheckboxSelectAllSlotProps { /** Optional display label */ label?: string; /** Whether all selectable items are selected */ isAllSelected: boolean; /** Whether some but not all selectable items are selected */ isMixed: boolean; /** Whether this checkbox is disabled */ isDisabled: boolean; /** Select all selectable items */ selectAll: () => void; /** Unselect all items */ unselectAll: () => void; /** Toggle between all selected and none selected */ toggleAll: () => void; /** Attributes to bind to the checkbox element */ attrs: { 'type': 'button' | undefined; 'role': 'checkbox'; 'aria-checked': boolean | 'mixed'; 'aria-disabled': boolean; 'aria-label': string | undefined; 'aria-labelledby': string | undefined; 'aria-describedby': string | undefined; 'tabindex': 0 | undefined; 'data-state': CheckboxState; 'data-disabled': true | undefined; 'onClick': () => void; 'onKeydown': (e: KeyboardEvent) => void; }; } declare const _default$44: typeof __VLS_export$190; declare const __VLS_export$190: __VLS_WithSlots$149 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: CheckboxSelectAllSlotProps) => any; }>; type __VLS_WithSlots$149 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/Checkbox/index.d.ts /** * Checkbox component with sub-components for checkbox controls. * * @see https://0.vuetifyjs.com/components/forms/checkbox * * @example * ```vue * * * * ``` */ declare const Checkbox: { /** * Group component for managing multiple checkboxes. * * @see https://0.vuetifyjs.com/components/forms/checkbox * * @example * ```vue * * * * ``` */ Group: (__VLS_props: NonNullable>["props"], __VLS_ctx?: { attrs: any; emit: ((evt: "update:model-value", value: T | T[]) => void) & ((event: "update:modelValue", value: T | T[] | undefined) => void); slots: { default: (props: CheckboxGroupSlotProps) => any; }; }, __VLS_exposed?: NonNullable>["expose"], __VLS_setup?: Promise<{ props: import("vue").PublicProps & { namespace?: string | undefined; disabled?: boolean | undefined; enroll?: boolean | undefined; mandatory?: boolean | "force" | undefined; label?: string | undefined; ariaLabelledby?: string | undefined; ariaDescribedby?: string | undefined; as?: (DOMElement | null) | undefined; renderless?: boolean | undefined; modelValue?: (T | T[]) | undefined; "onUpdate:modelValue"?: ((value: T | T[] | undefined) => any) | undefined; "onUpdate:model-value"?: ((value: T | T[]) => any) | undefined; } & (typeof globalThis extends { __VLS_PROPS_FALLBACK: infer P; } ? P : {}); expose: (exposed: import("vue").ShallowUnwrapRef) => void; attrs: any; slots: { default: (props: CheckboxGroupSlotProps) => any; }; emit: ((evt: "update:model-value", value: T | T[]) => void) & ((event: "update:modelValue", value: T | T[] | undefined) => void); }>) => import("vue").VNode & { __ctx?: NonNullable>; }; /** * Hidden input component for form submission. * * Auto-rendered by Root when `name` prop is provided. * Can also be used explicitly for custom form integration. * * @see https://0.vuetifyjs.com/components/forms/checkbox * * @example * ```vue * * * * ``` */ HiddenInput: import("vue").DefineComponent & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>; /** * Visual indicator component for checkboxes. * * Renders as a span and only displays when checked or indeterminate. * Must be used within a Checkbox.Root component. * * @see https://0.vuetifyjs.com/components/forms/checkbox * * @example * ```vue * * * * ``` */ Indicator: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: CheckboxIndicatorSlotProps) => any; }; }); /** * Root component for individual checkboxes. * * Renders as a button with proper ARIA attributes and handles * click/keyboard interactions. Supports standalone mode with * v-model or group mode within Checkbox.Group. When `name` prop * is provided, automatically renders a hidden input for form submission. * * @see https://0.vuetifyjs.com/components/forms/checkbox * * @example * ```vue * * * * ``` */ Root: (__VLS_props: NonNullable>["props"], __VLS_ctx?: { attrs: any; emit: ((evt: "update:model-value", value: boolean) => void) & ((event: "update:modelValue", value: boolean | undefined) => void); slots: { default: (props: CheckboxRootSlotProps) => any; }; }, __VLS_exposed?: NonNullable>["expose"], __VLS_setup?: Promise<{ props: import("vue").PublicProps & { id?: ID | undefined; label?: string | undefined; value?: V | undefined; name?: string | undefined; form?: string | undefined; disabled?: (boolean | import("vue").MaybeRefOrGetter) | undefined; indeterminate?: (boolean | import("vue").MaybeRefOrGetter) | undefined; namespace?: string | undefined; groupNamespace?: string | undefined; ariaLabelledby?: string | undefined; ariaDescribedby?: string | undefined; ariaInvalid?: boolean | undefined; as?: (DOMElement | null) | undefined; renderless?: boolean | undefined; modelValue?: boolean | undefined; "onUpdate:modelValue"?: ((value: boolean | undefined) => any) | undefined; "onUpdate:model-value"?: ((value: boolean) => any) | undefined; } & (typeof globalThis extends { __VLS_PROPS_FALLBACK: infer P; } ? P : {}); expose: (exposed: import("vue").ShallowUnwrapRef) => void; attrs: any; slots: { default: (props: CheckboxRootSlotProps) => any; }; emit: ((evt: "update:model-value", value: boolean) => void) & ((event: "update:modelValue", value: boolean | undefined) => void); }>) => import("vue").VNode & { __ctx?: NonNullable>; }; /** * Select all checkbox for group multi-selection. * * Binds to parent Checkbox.Group's aggregate state. Reflects * isAllSelected/isMixed and calls toggleAll on click. Does NOT * register as a group item. Must be used within a Checkbox.Group. * * @see https://0.vuetifyjs.com/components/forms/checkbox * * @example * ```vue * * * * ``` */ SelectAll: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: CheckboxSelectAllSlotProps) => any; }; }); }; //#endregion //#region src/components/Collapsible/CollapsibleRoot.vue.d.ts interface CollapsibleContext { open: Readonly>; disabled: Readonly>; activatorId: Readonly>; contentId: Readonly>; toggle: () => void; show: () => void; hide: () => void; } interface CollapsibleRootProps extends AtomProps { /** Namespace for dependency injection */ namespace?: string; /** Whether the collapsible is disabled */ disabled?: boolean; } interface CollapsibleRootSlotProps { /** Whether the collapsible is open */ isOpen: boolean; /** Whether the collapsible is disabled */ isDisabled: boolean; /** Open the collapsible */ open: () => void; /** Close the collapsible */ close: () => void; /** Toggle the collapsible */ toggle: () => void; /** Attributes to bind to the root element */ attrs: { 'data-state': 'open' | 'closed'; 'data-disabled': true | undefined; }; } declare const useCollapsible: (key: string, defaultValue?: CollapsibleContext | undefined) => CollapsibleContext, provideCollapsible: (key: string, context: CollapsibleContext, app?: import("vue").App) => CollapsibleContext; declare const _default$48: typeof __VLS_export$189; declare const __VLS_export$189: __VLS_WithSlots$148 any; "update:model-value": (value: boolean) => any; }, string, import("vue").PublicProps, Readonly & Readonly<{ "onUpdate:modelValue"?: ((value: boolean) => any) | undefined; "onUpdate:model-value"?: ((value: boolean) => any) | undefined; }>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: CollapsibleRootSlotProps) => any; }>; type __VLS_WithSlots$148 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/Collapsible/CollapsibleActivator.vue.d.ts interface CollapsibleActivatorProps extends AtomProps { namespace?: string; } interface CollapsibleActivatorSlotProps { /** Whether the collapsible is open */ isOpen: boolean; /** Whether the collapsible is disabled */ isDisabled: boolean; /** Toggle the collapsible */ toggle: () => void; /** Attributes to bind to the activator element for accessibility */ attrs: { /** Unique ID for the activator element */ 'id': string; /** ARIA role for accessibility (only set when not using native button) */ 'role': 'button' | undefined; /** Tab index for keyboard navigation */ 'tabindex': number; /** ARIA expanded state */ 'aria-expanded': boolean; /** ARIA controls attribute pointing to content region */ 'aria-controls': string; /** ARIA disabled state (for non-button elements) */ 'aria-disabled': boolean | undefined; /** Data attribute for open/closed state */ 'data-state': 'open' | 'closed'; /** Data attribute for disabled state */ 'data-disabled': true | undefined; /** Disabled attribute for native button elements */ 'disabled': boolean | undefined; /** Type attribute for native button elements */ 'type': 'button' | undefined; /** Click handler to toggle */ 'onClick': () => void; /** Keyboard handler for Enter and Space keys */ 'onKeydown': ((e: KeyboardEvent) => void) | undefined; }; } declare const _default$45: typeof __VLS_export$188; declare const __VLS_export$188: __VLS_WithSlots$147 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: CollapsibleActivatorSlotProps) => any; }>; type __VLS_WithSlots$147 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/Collapsible/CollapsibleCue.vue.d.ts interface CollapsibleCueProps extends AtomProps { namespace?: string; } interface CollapsibleCueSlotProps { isOpen: boolean; attrs: { 'aria-hidden': true; 'data-state': 'open' | 'closed'; }; } declare const _default$47: typeof __VLS_export$187; declare const __VLS_export$187: __VLS_WithSlots$146 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: CollapsibleCueSlotProps) => any; }>; type __VLS_WithSlots$146 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/Collapsible/CollapsibleContent.vue.d.ts interface CollapsibleContentProps extends AtomProps { namespace?: string; } interface CollapsibleContentSlotProps { /** Whether the collapsible is open */ isOpen: boolean; /** Attributes to bind to the content element for accessibility */ attrs: { /** Unique ID for the content region */ 'id': string; /** ARIA role for accessibility */ 'role': 'region'; /** ARIA labelledby attribute pointing to trigger element */ 'aria-labelledby': string; /** Whether the content is hidden */ 'hidden': boolean; /** Data attribute for open/closed state */ 'data-state': 'open' | 'closed'; /** Data attribute for disabled state */ 'data-disabled': true | undefined; }; } declare const _default$46: typeof __VLS_export$186; declare const __VLS_export$186: __VLS_WithSlots$145 & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, false, {}, any>, { default: (props: CollapsibleContentSlotProps) => any; }>; type __VLS_WithSlots$145 = T & { new (): { $slots: S; }; }; //#endregion //#region src/components/Collapsible/index.d.ts /** * A single-item disclosure toggle for showing and hiding content. * * @see https://0.vuetifyjs.com/components/disclosure/collapsible * * @example * ```vue * * * * ``` */ declare const Collapsible: { Root: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{ "onUpdate:modelValue"?: ((value: boolean) => any) | undefined; "onUpdate:model-value"?: ((value: boolean) => any) | undefined; }>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, { "update:modelValue": (value: boolean) => any; "update:model-value": (value: boolean) => any; }, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{ "onUpdate:modelValue"?: ((value: boolean) => any) | undefined; "onUpdate:model-value"?: ((value: boolean) => any) | undefined; }>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{ "onUpdate:modelValue"?: ((value: boolean) => any) | undefined; "onUpdate:model-value"?: ((value: boolean) => any) | undefined; }>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, { "update:modelValue": (value: boolean) => any; "update:model-value": (value: boolean) => any; }, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: CollapsibleRootSlotProps) => any; }; }); Activator: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: CollapsibleActivatorSlotProps) => any; }; }); Cue: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: CollapsibleCueSlotProps) => any; }; }); Content: { new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, import("vue").PublicProps, {}, false, {}, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, {}, any, import("vue").ComponentProvideOptions, { P: {}; B: {}; D: {}; C: {}; M: {}; Defaults: {}; }, Readonly & Readonly<{}>, {}, {}, {}, {}, {}>; __isFragment?: never; __isTeleport?: never; __isSuspense?: never; } & import("vue").ComponentOptionsBase & Readonly<{}>, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, {}, {}, string, {}, import("vue").GlobalComponents, import("vue").GlobalDirectives, string, import("vue").ComponentProvideOptions> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => { $slots: { default: (props: CollapsibleContentSlotProps) => any; }; }); }; //#endregion //#region src/composables/toElement/index.d.ts type MaybeElementValue = HTMLElement | SVGElement | ComponentPublicInstance | Element | null | undefined; /** * A flexible element ref type that accepts refs, getters, or raw values * containing DOM elements or Vue component instances. * * @remarks * Defined structurally (using `{ readonly value: T }`) instead of Vue's * nominal `Ref` to avoid type mismatches when consumers use a * different Vue version than the library. * Use {@link toElement} to resolve the actual DOM element. */ type MaybeElementRef = { readonly value: MaybeElementValue; } | (() => MaybeElementValue) | MaybeElementValue; /** * Resolves a {@link MaybeElementRef} to a DOM Element or undefined. * * Handles: * - `Ref`, `ShallowRef`, getter functions * - Vue component instances (`$el`, or the first root Element of a fragment root) * - Raw DOM elements (pass-through) * - null/undefined (returns undefined) * * @param target The element ref, getter, or raw value to resolve * @returns The resolved DOM Element, or undefined if not available * * @see https://0.vuetifyjs.com/composables/transformers/to-element * * @example * ```ts * import { toElement } from '@vuetify/v0' * * const el = shallowRef(null) * toElement(el) // HTMLElement | undefined * * const component = ref() * toElement(component) // Element | undefined (first root Element) * ``` */ declare function toElement(target: MaybeElementRef): Element | undefined; //#endregion //#region src/composables/useDate/adapters/adapter.d.ts declare abstract class DateAdapter { /** Current locale for formatting */ abstract get locale(): string; /** First day of week. 0=Sunday, 1=Monday, ... 6=Saturday. Managed by the plugin. */ abstract get firstDayOfWeek(): number; abstract set locale(value: string); abstract set firstDayOfWeek(value: number); /** Create a date from various input types */ abstract date(value?: unknown): T | null; /** Convert to JavaScript Date object */ abstract toJsDate(value: T): Date; /** Parse ISO 8601 string */ abstract parseISO(date: string): T; /** Convert to ISO 8601 string */ abstract toISO(date: T): string; /** Parse date string with custom format */ abstract parse(value: string, format: string): T | null; /** Check if value is a valid date (type predicate for narrowing) */ abstract isValid(date: unknown): date is T; /** Check if value is null (type predicate for narrowing) */ abstract isNullish(value: T | null): value is null; /** Get current locale code */ abstract getCurrentLocaleCode(): string; /** Check if current locale uses 12-hour cycle */ abstract is12HourCycleInCurrentLocale(): boolean; /** Format date using preset format key */ abstract format(date: T, formatString: string): string; /** Format date using custom format string */ abstract formatByString(date: T, formatString: string): string; /** Get helper text for format string (e.g., "mm/dd/yyyy") */ abstract getFormatHelperText(format: string): string; /** Format number according to locale */ abstract formatNumber(numberToFormat: string): string; /** Get meridiem text (AM/PM) for locale */ abstract getMeridiemText(ampm: 'am' | 'pm'): string; abstract startOfDay(date: T): T; abstract endOfDay(date: T): T; abstract startOfWeek(date: T): T; abstract endOfWeek(date: T): T; abstract startOfMonth(date: T): T; abstract endOfMonth(date: T): T; abstract startOfYear(date: T): T; abstract endOfYear(date: T): T; abstract addSeconds(date: T, amount: number): T; abstract addMinutes(date: T, amount: number): T; abstract addHours(date: T, amount: number): T; abstract addDays(date: T, amount: number): T; abstract addWeeks(date: T, amount: number): T; abstract addMonths(date: T, amount: number): T; abstract addYears(date: T, amount: number): T; abstract isAfter(date: T, comparing: T): boolean; abstract isAfterDay(date: T, comparing: T): boolean; abstract isAfterMonth(date: T, comparing: T): boolean; abstract isAfterYear(date: T, comparing: T): boolean; abstract isBefore(date: T, comparing: T): boolean; abstract isBeforeDay(date: T, comparing: T): boolean; abstract isBeforeMonth(date: T, comparing: T): boolean; abstract isBeforeYear(date: T, comparing: T): boolean; abstract isEqual(date: T, comparing: T): boolean; abstract isSameDay(date: T, comparing: T): boolean; abstract isSameMonth(date: T, comparing: T): boolean; abstract isSameYear(date: T, comparing: T): boolean; abstract isSameHour(date: T, comparing: T): boolean; abstract isWithinRange(date: T, range: [T, T]): boolean; abstract getYear(date: T): number; abstract getMonth(date: T): number; abstract getDate(date: T): number; abstract getHours(date: T): number; abstract getMinutes(date: T): number; abstract getSeconds(date: T): number; /** @param comparing - Can be T or ISO string */ abstract getDiff(date: T, comparing: T | string, unit?: string): number; /** @param minimalDays - Minimum days in first week for it to count as week 1 */ abstract getWeek(date: T, minimalDays?: number): number; /** Get number of days in the month */ abstract getDaysInMonth(date: T): number; abstract setYear(date: T, year: number): T; abstract setMonth(date: T, month: number): T; abstract setDate(date: T, day: number): T; abstract setHours(date: T, hours: number): T; abstract setMinutes(date: T, minutes: number): T; abstract setSeconds(date: T, seconds: number): T; abstract getWeekdays(weekdayFormat?: 'long' | 'short' | 'narrow'): string[]; /** * Weeks-of-7 matrix for the month containing `date`, spilling into adjacent * months at the edges. With `fixedWeeks`, trailing weeks pad the matrix to a * constant 6 rows (42 cells) so calendar grids keep a stable height. */ abstract getWeekArray(date: T, fixedWeeks?: boolean): T[][]; /** Get array of months in a year (12 dates, one for each month) */ abstract getMonthArray(date: T): T[]; /** Get array of years between start and end dates */ abstract getYearRange(start: T, end: T): T[]; abstract getNextMonth(date: T): T; abstract getPreviousMonth(date: T): T; /** Merge date from one value with time from another */ abstract mergeDateAndTime(date: T, time: T): T; } //#endregion //#region src/composables/useDate/adapters/plain.d.ts declare class V0PlainDateAdapter extends DateAdapter { private _locale; private _firstDayOfWeek; private _minimalDays; private formatCache; private numberFormatCache; constructor(locale?: string); get locale(): string; get firstDayOfWeek(): number; set locale(value: string); set firstDayOfWeek(value: number); /** * @remarks * No argument: the current time in the browser, or local `1970-01-01` * on the server. A `Date` is copied. A `YYYY-MM-DD` string is that * local calendar day. */ date(value?: unknown): Date | null; toJsDate(value: Date): Date; parseISO(dateString: string): Date; /** `YYYY-MM-DD` from local calendar fields. Time is dropped. Years below 1000 pad to 4 digits. */ toISO(date: Date): string; /** `format` is ignored. Parsing goes through `date()`. */ parse(value: string, _format: string): Date | null; isValid(date: unknown): date is Date; isNullish(value: Date | null): value is null; getCurrentLocaleCode(): string; is12HourCycleInCurrentLocale(): boolean; format(date: Date, formatString: string): string; formatByString(date: Date, formatString: string): string; getFormatHelperText(format: string): string; formatNumber(numberToFormat: string): string; getMeridiemText(ampm: 'am' | 'pm'): string; startOfDay(date: Date): Date; endOfDay(date: Date): Date; startOfWeek(date: Date): Date; endOfWeek(date: Date): Date; startOfMonth(date: Date): Date; endOfMonth(date: Date): Date; startOfYear(date: Date): Date; endOfYear(date: Date): Date; addSeconds(date: Date, amount: number): Date; addMinutes(date: Date, amount: number): Date; addHours(date: Date, amount: number): Date; /** * Calendar days, not elapsed milliseconds. A DST transition does not * drop or repeat a date. */ addDays(date: Date, amount: number): Date; addWeeks(date: Date, amount: number): Date; /** Clamps the day to the target month. January 31 plus one month is February 28 or 29. */ addMonths(date: Date, amount: number): Date; addYears(date: Date, amount: number): Date; isAfter(date: Date, comparing: Date): boolean; isAfterDay(date: Date, comparing: Date): boolean; isAfterMonth(date: Date, comparing: Date): boolean; isAfterYear(date: Date, comparing: Date): boolean; isBefore(date: Date, comparing: Date): boolean; isBeforeDay(date: Date, comparing: Date): boolean; isBeforeMonth(date: Date, comparing: Date): boolean; isBeforeYear(date: Date, comparing: Date): boolean; isEqual(date: Date, comparing: Date): boolean; isSameDay(date: Date, comparing: Date): boolean; isSameMonth(date: Date, comparing: Date): boolean; isSameYear(date: Date, comparing: Date): boolean; isSameHour(date: Date, comparing: Date): boolean; isWithinRange(date: Date, [start, end]: [Date, Date]): boolean; getYear(date: Date): number; /** 0-indexed, matching `Date#getMonth`. */ getMonth(date: Date): number; getDate(date: Date): number; getHours(date: Date): number; getMinutes(date: Date): number; getSeconds(date: Date): number; getDiff(date: Date, comparing: Date | string, unit?: string): number; getWeek(date: Date, minimalDays?: number): number; getDaysInMonth(date: Date): number; setYear(date: Date, year: number): Date; /** `month` is 0-indexed. The day clamps to that month. */ setMonth(date: Date, month: number): Date; setDate(date: Date, day: number): Date; setHours(date: Date, hours: number): Date; setMinutes(date: Date, minutes: number): Date; setSeconds(date: Date, seconds: number): Date; getWeekdays(format?: 'long' | 'short' | 'narrow'): string[]; getWeekArray(date: Date, fixedWeeks?: boolean): Date[][]; getMonthArray(date: Date): Date[]; getYearRange(start: Date, end: Date): Date[]; getNextMonth(date: Date): Date; getPreviousMonth(date: Date): Date; mergeDateAndTime(date: Date, time: Date): Date; private invalid; /** * Signed calendar-day order. String order on `toISO` inverts years * whose digit counts differ. */ private dayOrder; /** `Math.trunc` of a negative fraction is `-0`, and `Object.is` keeps it. */ private whole; private orderSign; /** Signed clock order. A DST gap must not change this through `getTime`. */ private timeOrder; /** * Complete months, matching `Temporal.PlainDateTime.since`. * * The start day is compared as a number, so February never reaches day * 29–31. When the date and the clock move the same way, the start loses * one calendar day first. `addMonths` would clamp that day, and `getTime` * would treat a spring-forward gap as a later clock. */ private monthDiff; /** * UTC instant for an offset string. `new Date(string)` overflows an * impossible day instead of rejecting it. */ private instant; /** Local calendar day. Rejects a day the month does not contain. */ private civil; /** * Local calendar fields. The `Date` constructor and `Date.UTC` add 1900 * when the year is 0–99. `setFullYear` does not. */ private stamp; /** Four digits for years 0–9999. `padStart` would rewrite a negative year. */ private yearText; /** * UTC day index, so a DST shift cannot change a day diff. * `Date.UTC` maps years 0–99 onto 1900–1999. */ private dayNumber; private getFormatter; private getNumberFormatter; } //#endregion //#region src/composables/createCalendar/index.d.ts /** * One day in the visible grid. * * A spill day from the adjacent month stays in the row. It is `outside` and * not selectable. */ interface CalendarCell { /** * `YYYY-MM-DD` when the grid can page to the day. A spill day before year * 0000 or after year 9999 keeps the adapter's string. That cell is outside * and disabled. */ iso: string; /** Day of the month, 1–31. */ day: number; /** Leading or trailing spill. Not selectable. */ outside: boolean; /** `min`, `max`, `disabled`, or a day that is not `YYYY-MM-DD`. */ disabled: boolean; /** This cell is the current day. */ today: boolean; /** This cell is the selected day, or it lies inside the range. */ selected: boolean; /** This cell is the focused day. It may also be disabled. */ focused: boolean; } /** One visible month. Not a list of months. */ interface CalendarMonth { /** `YYYY-MM`. */ anchor: string; /** Rows of 7 cells. Four to six rows, or six when `fixedWeeks` is set. */ weeks: CalendarCell[][]; } /** * Inclusive range. `start` without `end` is an open range. * * @example * ```ts * const calendar = createCalendar({ mode: 'range', month: '2026-08' }) * * calendar.select('2026-08-10') * calendar.select('2026-08-12') * calendar.value.value // { start: '2026-08-10', end: '2026-08-12' } * ``` */ interface CalendarRange { /** `YYYY-MM-DD`. Replaced when the next day is earlier, or when the range is already closed. */ start?: string; /** `YYYY-MM-DD`. Set for a day on or after `start` while the range is still open. */ end?: string; } /** Selected day, an open or closed range, or nothing. */ type CalendarValue = string | CalendarRange | undefined; /** One day, or a start and an end. */ type CalendarMode = 'single' | 'range'; /** Whole grid, a list of `YYYY-MM-DD` days, or a per-day predicate. */ type CalendarDisabled = boolean | readonly string[] | ((iso: string) => boolean); /** Step size for `move`. */ type CalendarUnit = 'day' | 'week' | 'month' | 'year'; /** Intl weekday length. `narrow` is one letter in most locales. */ type CalendarWeekdayFormat = 'long' | 'short' | 'narrow'; /** * Options for `createCalendar`. * * @example * ```ts * const calendar = createCalendar({ * mode: 'single', * month: '2026-08', * min: '2026-08-01', * max: '2026-08-31', * disabled: iso => iso === '2026-08-15', * firstDayOfWeek: 1, * }) * ``` */ interface CalendarOptions { /** * Date engine. Omit it to borrow an installed date plugin, or to use * `V0PlainDateAdapter` when none is installed. An adapter you pass is not * replaced, and its `firstDayOfWeek` is not written. */ adapter?: DateAdapter; /** Namespace of an installed date plugin. @default 'v0:date' */ namespace?: string; /** * Visible month. `YYYY-MM`, or a day whose month is used. Omitted means the * current month, clamped to `min` and `max`. A writable ref is written as * `YYYY-MM` when the grid pages. Inside a component it is also written when * `min` or `max` clamps the month it opened on. A day token stays while the * page stays in that month. A getter or a readonly ref is not written. */ month?: MaybeRefOrGetter; /** * Selected day, or `{ start, end }` in range mode. A ref is written back. * A getter or a readonly ref is not. Inside a component, changing `mode` * clears it. */ value?: MaybeRefOrGetter; /** * `'single'` selects one day. `'range'` selects a start and an end. * A ref or getter is read on each interaction. Inside a component, changing * it clears the selection. * * @default 'single' */ mode?: MaybeRefOrGetter; /** `YYYY-MM-DD`. Days before it are disabled. */ min?: MaybeRefOrGetter; /** `YYYY-MM-DD`. Days after it are disabled. */ max?: MaybeRefOrGetter; /** * `true` disables every day. An array of `YYYY-MM-DD` days disables those * days. A function disables the days it returns true for. A bare function is * the predicate and is called with the ISO day, not passed through `toValue`. * Navigation still runs. * * @default false */ disabled?: MaybeRefOrGetter; /** * `select` and `unselect` no-op. Cells stay enabled, and paging still runs. * * @default false */ readonly?: MaybeRefOrGetter; /** * Week start. `0` is Sunday. A finite number wins and is not written onto * the adapter. Omit it to follow the adapter, or an owned `locale`. */ firstDayOfWeek?: MaybeRefOrGetter; /** Pad the grid to six rows. @default false */ fixedWeeks?: MaybeRefOrGetter; /** * In single mode, clicking the selected day again does not clear it. * Another day still replaces it. `unselect()` no-ops. Range clicks ignore * this. Nothing is selected until the caller selects a day. * * @default false */ mandatory?: MaybeRefOrGetter; /** * BCP 47 tag. Written onto the adapter only when this call constructs it, * which moves the weekday columns and the month label. A borrowed adapter * keeps its own locale. */ locale?: MaybeRefOrGetter; /** Weekday column labels. @default 'narrow' */ weekdayFormat?: CalendarWeekdayFormat; } /** * Month grid and selection. * * @example * ```ts * const calendar = createCalendar({ month: '2026-08' }) * * calendar.today() // pages to today, selects nothing * calendar.selectToday() // selects today when that day is allowed * calendar.value.value * ``` */ interface CalendarContext { /** The visible month. One object, not an array. */ month: ComputedRef; /** Seven labels, rotated to the week start. */ weekdays: ComputedRef; /** Localized month and year. Year 0 follows Intl, which numbers that year 1. */ label: ComputedRef; /** `YYYY-MM`. */ anchor: Readonly>; /** `YYYY-MM-DD` navigation follows. May sit on a disabled in-month day. */ focused: Readonly>; /** ISO day, or `{ start, end }` in range mode. */ value: Readonly>; /** At the `min` month, or the first representable month. */ isFirst: Readonly>; /** At the `max` month, or the last representable month. */ isLast: Readonly>; /** * Selects an in-month day that is not disabled. * In single mode, a second click on that day clears it, unless `mandatory` is set. * In range mode, a later click sets the end or starts a new range. * * @example * ```ts * calendar.select('2026-08-12') * calendar.select('2026-08-12') // clears * ``` */ select: (iso: string) => void; /** Clears the selection. No-ops when `mandatory` or `readonly` is set. */ unselect: () => void; /** * Pages to the current month and focuses today. Selects nothing. * * @example * ```ts * calendar.today() * calendar.value.value // unchanged * ``` */ today: () => void; /** * Focuses today and selects it when that day is allowed. * * @example * ```ts * calendar.selectToday() * ``` */ selectToday: () => void; /** Page to the next month, clamped to `max`. */ next: () => void; /** Page to the previous month, clamped to `min`. */ prev: () => void; /** Page by whole months, clamped to `min` and `max`. */ step: (count: number) => void; /** `YYYY-MM` or `YYYY-MM-DD`. Pages and focuses. */ goto: (value: string) => void; /** * Walks the focused day and pages when it leaves the month. * A step past `min` or `max` lands on that wall. */ move: (unit: CalendarUnit, amount: number) => void; /** Page to the `min` month. No-op when `min` is unset. */ first: () => void; /** Page to the `max` month. No-op when `max` is unset. */ last: () => void; } /** * Gregorian month grid. * * Selection lives here. Pass `mode: 'range'` for a start and end on the same * grid. `today()` pages and focuses without selecting. `selectToday()` selects * when the day is allowed. * * @param options Month, selection, and bounds. * @returns The calendar context. * * @see https://0.vuetifyjs.com/composables/forms/create-calendar * * @example * ```ts * const calendar = createCalendar({ * month: '2026-02', * firstDayOfWeek: 0, * }) * * calendar.month.value.weeks.length // 4 * ``` */ declare function createCalendar(options: CalendarOptions & { adapter: DateAdapter; }): CalendarContext; declare function createCalendar(options?: CalendarOptions): CalendarContext; //#endregion //#region src/composables/createContext/index.d.ts type ContextKey = InjectionKey | string; interface CreateContextOptions { /** Optional suffix to append to the runtime key */ suffix?: string; } /** * Injects a context provided by an ancestor component. * * @param key The key of the context to inject. * @param defaultValue Optional default value if context is not found. * @template Z The type of the context. * @returns The injected context. * @throws An error if the context is not found and no default is provided. * * @see https://vuejs.org/api/composition-api-dependency-injection.html#inject * @see https://0.vuetifyjs.com/composables/foundation/create-context * * @example * ```ts * // Without default value * const context = useContext('my-context') * * // With default value * const context = useContext('my-context', defaultContext) * ``` */ declare function useContext(key: ContextKey, defaultValue?: Z): Z; /** * Provides a context to all descendant components. * * @param key The key of the context to provide. * @param context The context to provide. * @param app Optional Vue app instance to provide the context at app level instead of component level. * @template Z The type of the context. * @returns The provided context. * * @remarks * When `app` parameter is provided, the context is made available to all components in the app. * When omitted, the context is provided at the current component level and available to descendants only. * * @see https://vuejs.org/api/composition-api-dependency-injection.html#provide * @see https://0.vuetifyjs.com/composables/foundation/create-context * * @example * ```ts * // Component-level provision * provideContext('my-context', context) * * // App-level provision (typically used in plugins) * const app = createApp() * provideContext('my-context', context, app) * ``` */ declare function provideContext(key: ContextKey, context: Z, app?: App): Z; /** * Creates a new context for providing and injecting data. * * Supports two modes: * - **Static key mode**: Pass a string/symbol key. The key is fixed at creation time. * - **Dynamic key mode**: Pass nothing or an options object. The key is provided at runtime. * * @template Z The type of the context. * @returns A tuple containing the `useContext` and `provideContext` functions. * * @see https://vuejs.org/api/composition-api-dependency-injection.html * @see https://0.vuetifyjs.com/composables/foundation/create-context * * @example * ```ts * // Static key mode - key fixed at creation * const [useContext, provideContext] = createContext('v0:theme') * provideContext(context) // provides to 'v0:theme' * useContext() // injects from 'v0:theme' * * // Dynamic key mode - key provided at runtime * const [useContext, provideContext] = createContext() * provideContext('v0:panel', context) // provides to 'v0:panel' * useContext('v0:panel') // injects from 'v0:panel' * * // Dynamic key with suffix - suffix appended to runtime key * const [useContext, provideContext] = createContext({ suffix: 'item' }) * provideContext('v0:panel', context) // provides to 'v0:panel:item' * useContext('v0:panel') // injects from 'v0:panel:item' * ``` */ declare function createContext(key: ContextKey, defaultValue?: Z): readonly [() => Z, (context: Z, app?: App) => Z]; declare function createContext(options?: CreateContextOptions): readonly [(key: string, defaultValue?: Z) => Z, (key: string, context: Z, app?: App) => Z]; //#endregion //#region src/composables/createFilter/index.d.ts type Primitive = string | number | boolean; type FilterQuery = MaybeRefOrGetter; type FilterItem = Primitive | Record; type FilterMode = 'some' | 'every' | 'union' | 'intersection'; type FilterFunction = (query: Primitive | Primitive[], item: FilterItem) => boolean; interface FilterOptions { customFilter?: FilterFunction; keys?: MaybeRefOrGetter; mode?: FilterMode; } interface FilterResult { items: ComputedRef; } interface FilterContext { /** The filter mode */ mode: FilterMode; /** Keys to filter on for object items */ keys: MaybeRefOrGetter | undefined; /** Custom filter function */ customFilter: FilterFunction | undefined; /** Current query ref */ query: ShallowRef; /** * Apply filter to an array of items * * @param query The query to filter by * @param items The items to filter * @returns The filtered items as a computed ref */ apply: (query: FilterQuery, items: MaybeRefOrGetter) => FilterResult; } interface FilterContextOptions extends FilterOptions { namespace?: string; } /** * Creates a filter context with pre-configured options. * * @param options The filter options * @template Z The type of the items * @template E The type of the filter context * @returns A filter context * * @see https://0.vuetifyjs.com/composables/data/create-filter * * @example * ```ts * import { createFilter } from '@vuetify/v0' * * const filter = createFilter({ * mode: 'intersection', * keys: ['name', 'email'], * }) * * const { items } = filter.apply(query, users) * ``` */ declare function createFilter = FilterContext>(options?: FilterOptions): E; /** * Creates a filter context with dependency injection support. * * @param options The filter context options * @template Z The type of the items * @template E The type of the filter context * @returns A trinity tuple: [useContext, provideContext, defaultContext] * * @see https://0.vuetifyjs.com/composables/data/create-filter * * @example * ```ts * import { createFilterContext } from '@vuetify/v0' * * export const [useSearchFilter, provideSearchFilter, searchFilter] = createFilterContext({ * namespace: 'app:search', * mode: 'union', * keys: ['title', 'description'], * }) * * // In parent component * provideSearchFilter() * * // In child component * const filter = useSearchFilter() * const { items } = filter.apply(query, products) * ``` */ declare function createFilterContext = FilterContext>(_options?: FilterContextOptions): ContextTrinity; /** * Returns the current filter context from dependency injection. * * @param namespace The namespace for the filter context. Defaults to `'v0:filter'`. * @template Z The type of the items. * @template E The type of the filter context. * @returns The current filter context. * * @see https://0.vuetifyjs.com/composables/data/create-filter * * @example * ```vue * * ``` */ declare function useFilter = FilterContext>(namespace?: string): E; //#endregion //#region src/composables/createPagination/index.d.ts type PaginationTicket = { type: 'page'; value: number; } | { type: 'ellipsis'; value: string; }; interface PaginationContext { /** Current page (1-indexed, auto-clamped to total pages) */ page: WritableComputedRef; /** Items per page */ itemsPerPage: number; /** Total number of items */ size: number; /** Total number of pages (computed from size / itemsPerPage) */ pages: number; /** Ellipsis character, or false if disabled */ ellipsis: string | false; /** Visible page numbers and ellipsis for rendering */ items: ComputedRef; /** Start index of items on current page (0-indexed) */ pageStart: Readonly>; /** End index of items on current page (exclusive, 0-indexed) */ pageStop: Readonly>; /** Whether current page is the first page */ isFirst: Readonly>; /** Whether current page is the last page */ isLast: Readonly>; /** Go to first page */ first: () => void; /** Go to last page */ last: () => void; /** Go to next page */ next: () => void; /** Go to previous page */ prev: () => void; /** Go to specific page */ select: (value: number) => void; } interface PaginationOptions { /** Initial page or ref for v-model (1-indexed). @default 1 */ page?: number | ShallowRef; /** Items per page. @default 10 */ itemsPerPage?: MaybeRefOrGetter; /** Total number of items. @default 0 */ size?: MaybeRefOrGetter; /** Maximum visible page buttons. @default 7 */ visible?: MaybeRefOrGetter; /** Ellipsis character. @default '...' */ ellipsis?: string | false; } interface PaginationContextOptions extends PaginationOptions { /** Namespace for dependency injection */ namespace?: string; } /** * Creates a pagination instance. * * @param options The options for the pagination instance. * @returns A pagination context with navigation methods. * * @example * ```ts * import { createPagination } from '@vuetify/v0' * * // Basic usage * const pagination = createPagination({ size: 100 }) * pagination.next() * pagination.items.value // [{ type: 'page', value: 1 }, { type: 'page', value: 2 }, ...] * * // With v-model (pass a ref) * const page = ref(1) * const pagination = createPagination({ page, size: 100 }) * // Mutating pagination.page or the passed ref syncs both * ``` */ declare function createPagination(_options?: PaginationOptions): PaginationContext; /** * Creates a pagination context for dependency injection. * * @param options The options including namespace. * @returns A trinity: [usePagination, providePagination, defaultContext] * * @example * ```ts * // With default namespace 'v0:pagination' * const [usePagination, providePaginationContext] = createPaginationContext({ size: 50 }) * * // Or with custom namespace * const [usePagination, providePaginationContext] = createPaginationContext({ * namespace: 'my-pagination', * size: 50, * }) * * // Parent component * providePaginationContext() * * // Child component * const pagination = usePagination() * pagination.next() * ``` */ declare function createPaginationContext(_options?: PaginationContextOptions): ContextTrinity; /** * Returns the current pagination instance from context. * * @param namespace The namespace. @default 'v0:pagination' * @returns The pagination context. * * @example * ```vue * * * * ``` */ declare function usePagination(namespace?: string): PaginationContext; //#endregion //#region src/composables/createDataTable/adapters/adapter.d.ts type SortDirection = 'asc' | 'desc' | 'none'; interface SortEntry { key: string; direction: SortDirection; } /** Inputs provided by createDataTable to the adapter */ interface DataTableAdapterContext { /** Source items */ items: MaybeRefOrGetter; /** Search query ref */ search: ShallowRef; /** Column ids eligible for filtering (reactive — tracks the columns registry) */ filterableKeys: MaybeRefOrGetter; /** Current sort state derived from sort controls */ sortBy: Readonly>; /** Locale for sorting (reactive, from useLocale or options) */ locale: Readonly>; /** Filter options (keys excluded, derived from columns) */ filterOptions: Omit; /** Pagination options (size excluded, derived from pipeline) */ paginationOptions: Omit; /** Per-column custom sort comparators (reactive — tracks the columns registry). Keys are column ids, which may be `keyof T` or derived strings. */ customSorts: MaybeRefOrGetter number>>>; /** Per-column custom filter functions (reactive — tracks the columns registry). Keys are column ids, which may be `keyof T` or derived strings. */ customColumnFilters: MaybeRefOrGetter boolean>>>; } /** Outputs returned by the adapter to createDataTable */ interface DataTableAdapterResult { /** Raw unprocessed items */ allItems: Readonly>; /** Items after filtering */ filteredItems: Readonly>; /** Items after filtering and sorting */ sortedItems: Readonly>; /** Final visible items (paginated or virtualized) */ items: Readonly>; /** Pagination controls */ pagination: PaginationContext; /** Total row count for aria-rowcount */ total: Readonly>; /** Loading state (optional, for async adapters) */ loading?: Readonly>; /** Error state (optional, for async adapters) */ error?: Readonly>; } declare abstract class DataTableAdapter { /** Create the filter pipeline stage */ protected filter(context: DataTableAdapterContext): { allItems: Readonly>; filteredItems: Readonly>; }; /** Create the sort pipeline stage */ protected sort(filteredItems: Readonly>, sortBy: Readonly>, locale?: Readonly>, customSorts?: MaybeRefOrGetter number>>>): Readonly>; abstract setup(context: DataTableAdapterContext): DataTableAdapterResult; } //#endregion //#region src/composables/createDataTable/columns.d.ts /** * @module createDataTable/columns * * @remarks * Utilities for resolving recursive column definitions into flat leaf * columns and 2D header grids. Used by createDataTable for header * rendering. */ interface ColumnNode { readonly id: string; readonly title?: string; readonly children?: readonly ColumnNode[]; } interface InternalHeader { id: string; title: string; colspan: number; rowspan: number; depth: number; } /** * Recursively extract leaf columns (those without children). * * @param columns Column tree to extract leaves from * @returns Flat array of leaf columns */ declare function extractLeaves(columns: readonly T[]): T[]; /** * Compute the maximum nesting depth of a column tree (0 = flat). * * @param columns Column tree to measure * @returns Maximum nesting depth */ declare function computeDepth(columns: readonly ColumnNode[]): number; /** * Resolve a recursive column tree into a 2D header grid. * * Each cell has colspan (number of leaf descendants) and rowspan * (how many rows a leaf spans when it doesn't fill all depth levels). * * @param columns Column tree to resolve * @returns 2D array of header cells with colspan/rowspan */ declare function resolveHeaders(columns: readonly ColumnNode[]): InternalHeader[][]; //#endregion //#region src/composables/createDataTable/adapters/server.d.ts interface ServerDataTableAdapterOptions { /** Total number of items on the server (for pagination calculation) */ total: MaybeRefOrGetter; /** Loading state (e.g., from useFetch) */ loading?: MaybeRefOrGetter; /** Error state from API */ error?: MaybeRefOrGetter; } declare class ServerDataTableAdapter extends DataTableAdapter { private options; constructor(options: ServerDataTableAdapterOptions); setup(context: DataTableAdapterContext): DataTableAdapterResult; } //#endregion //#region src/composables/createDataTable/adapters/v0.d.ts declare class ClientDataTableAdapter extends DataTableAdapter { setup(context: DataTableAdapterContext): DataTableAdapterResult; } //#endregion //#region src/composables/createDataTable/adapters/virtual.d.ts declare class VirtualDataTableAdapter extends DataTableAdapter { setup(context: DataTableAdapterContext): DataTableAdapterResult; } //#endregion //#region src/composables/createDataTable/index.d.ts type SelectStrategy = 'single' | 'page' | 'all'; /** * Input shape passed to `register` / `onboard` on a data table's row registry. * * @template T Row value type. * * @example * ```ts * const table = createDataTable() * table.register({ id: user.id, value: user }) * ``` */ interface DataTableTicketInput extends RegistryTicketInput { /** Row record. Required — the pipeline reads ticket.value. */ value: T; } /** * Output ticket returned by row `register` / `onboard` / `get`. * * @template T Row value type. */ type DataTableTicket = RegistryTicket & DataTableTicketInput; /** * Input shape passed to `table.columns.register` / `table.columns.onboard`. * * `id` is required and acts as the column identifier — selection, sort, and * filter all key off it. The `Extensible` shape preserves * autocomplete for the row's own keys while still accepting arbitrary strings * for derived columns (computed totals, action columns, etc.). * * @template T Row value type. * * @example * ```ts * import { createDataTable } from '@vuetify/v0' * * interface User { id: number, name: string, email: string } * * const table = createDataTable() * table.columns.register({ id: 'name', title: 'Name', sortable: true }) * table.columns.register({ * id: 'actions', * title: '', * sortable: false, * }) * ``` */ interface DataTableColumnTicketInput extends RegistryTicketInput { /** Column identifier. Required — selection / sort / filter all key off it. */ id: Extensible; /** Display title rendered in the header cell. */ title?: string; /** Allow this column to participate in the sort pipeline. */ sortable?: MaybeRefOrGetter; /** Allow this column to participate in the filter pipeline. */ filterable?: MaybeRefOrGetter; /** Custom per-column sort comparator. */ sort?: (a: unknown, b: unknown) => number; /** Custom per-column filter predicate. */ filter?: (value: unknown, query: string) => boolean; /** Header-group children (recursive). Children are NOT separately registered. */ children?: readonly DataTableColumnTicketInput[]; } /** * Output ticket returned by `table.columns.register` / `table.columns.onboard`. * * Combines the standard registry ticket fields (`index`, `valueIsIndex`, * `unregister`) with the column-shape fields from {@link DataTableColumnTicketInput}. * * @template T Row value type. */ type DataTableColumnTicket = RegistryTicket['value']> & DataTableColumnTicketInput; interface DataTableSort { /** Toggle sort for a column: none → asc → desc → none */ toggle: (id: string) => void; /** Current sort columns derived from group state */ columns: Readonly>; /** Order of sort columns (for multi-sort priority) */ order: readonly string[]; /** Get sort direction for a specific column id */ direction: (id: string) => SortDirection; /** Get sort priority index (0-based), or -1 if not sorted */ priority: (id: string) => number; /** Reset all sort state */ reset: () => void; } interface DataTableSelection { /** Currently selected row IDs */ selectedIds: ReadonlySet; /** Select a row by ID */ select: (id: ID) => void; /** Unselect a row by ID */ unselect: (id: ID) => void; /** Toggle a row's selection */ toggle: (id: ID) => void; /** Whether a row is selected */ isSelected: (id: ID) => boolean; /** Whether a row can be selected (based on itemSelectable) */ isSelectable: (id: ID) => boolean; /** Select all items within strategy scope */ selectAll: () => void; /** Unselect all items across all pages */ unselectAll: () => void; /** Toggle all items within strategy scope */ toggleAll: () => void; /** Whether all items within strategy scope are selected */ isAllSelected: Readonly>; /** Whether some but not all items within strategy scope are selected */ isMixed: Readonly>; } interface DataTableGroup { /** Stringified group identifier */ key: string; /** Raw value of the groupBy column for this group */ value: T[keyof T & string]; /** Items belonging to this group */ items: readonly T[]; } interface DataTableGrouping { /** Grouped items derived from sortedItems */ groups: Readonly[]>>; /** Toggle a group's open/closed state */ toggle: (groupKey: string) => void; /** Whether a group is open */ isOpen: (groupKey: string) => boolean; /** Open a group */ open: (groupKey: string) => void; /** Close a group */ close: (groupKey: string) => void; /** Open all groups */ openAll: () => void; /** Close all groups */ closeAll: () => void; } interface DataTableExpansion { /** Currently expanded row IDs */ expandedIds: ReadonlySet; /** Expand a row by ID */ expand: (id: ID) => void; /** Collapse a row by ID */ collapse: (id: ID) => void; /** Toggle a row's expanded state */ toggle: (id: ID) => void; /** Whether a row is expanded */ isExpanded: (id: ID) => boolean; /** Expand all visible (paginated) items. Requires expandMultiple=true. */ expandAll: () => void; /** Collapse all expanded items across all pages (not page-scoped like expandAll) */ collapseAll: () => void; } interface DataTableOptions { /** Filter options (keys derived from columns) */ filter?: Omit; /** Pagination options (size derived from pipeline) */ pagination?: Omit; /** Enable multi-column sort. @default false */ sortMultiple?: boolean; /** Prevent clearing sort (asc → desc → asc cycle). @default false */ mandate?: boolean; /** Direction for first sort click. @default 'asc' */ firstSortOrder?: 'asc' | 'desc'; /** Selection strategy: 'single' selects one row, 'page' operates on visible items, 'all' operates on all filtered items. @default 'page' */ selectStrategy?: SelectStrategy; /** Property that controls per-row selectability */ itemSelectable?: keyof T & string; /** Column id to group rows by */ groupBy?: keyof T & string; /** Auto-open all groups on creation. @default false */ openAll?: boolean; /** Allow multiple rows expanded simultaneously. @default true */ expandMultiple?: boolean; /** Locale for sorting. When set, wins over useLocale; otherwise useLocale or the browser default. */ locale?: string; /** Pipeline adapter. @default ClientDataTableAdapter */ adapter?: DataTableAdapter; } interface DataTableContext extends RegistryContext, DataTableTicket> { /** Final paginated items for rendering */ items: Readonly>; /** Raw unprocessed items */ allItems: Readonly>; /** Items after filtering */ filteredItems: Readonly>; /** Items after filtering and sorting */ sortedItems: Readonly>; /** Rank a source array by `sortedItems`. v-for this so rows register; missing ranks stay in source order. */ rank: (source: readonly U[]) => U[]; /** * Column registry. Use `columns.register({...})`, `columns.onboard([...])`, * `columns.unregister(id)`, and `columns.clear()` to manage columns. The * registry is reactive — `leaves` and `headers` recompute when it mutates. */ columns: RegistryContext, DataTableColumnTicket>; /** Leaf columns (no children) used by the data pipeline. Reactive. */ leaves: Readonly[]>>; /** 2D header grid with colspan/rowspan for rendering thead. Reactive. */ headers: Readonly>; /** Set the search query */ search: (value: string) => void; /** Current search query (readonly) */ query: Readonly>; /** Sort controls */ sort: DataTableSort; /** Pagination controls */ pagination: PaginationContext; /** Row selection controls */ selection: DataTableSelection; /** Row expansion controls */ expansion: DataTableExpansion; /** Row grouping controls. When groupBy is not set, `groups` returns an empty array. */ grouping: DataTableGrouping; /** Total row count for aria-rowcount */ total: Readonly>; /** Loading state (managed by adapter) */ loading: Readonly>; /** Error state (managed by adapter) */ error: Readonly>; } interface DataTableContextOptions extends DataTableOptions { namespace?: string; } /** * Creates a data table instance with sort controls, selection, and an * adapter-driven data pipeline. * * Rows and columns are both managed via internal registries. Use * `table.columns.register({ id, ... })` / `table.columns.onboard([...])` to * add columns and `table.register({ id, value })` / `table.onboard([...])` * for rows. Removing entries from the column registry reactively updates * `leaves`, `headers`, the sort group, and the filter pipeline. * * Must be called inside a component `setup()` or a Vue effect scope. * Calling at module scope in SSR environments causes request state leakage. * * @param options Data table options (all optional) * @returns Data table context with pipeline stages, controls, and registry surface * * @example * ```ts * import { createDataTable } from '@vuetify/v0' * * const table = createDataTable() * * table.columns.onboard([ * { id: 'name', title: 'Name', sortable: true, filterable: true }, * { id: 'email', title: 'Email', sortable: true, filterable: true }, * { id: 'age', title: 'Age', sortable: true }, * ]) * * table.onboard(users.map(value => ({ id: value.id, value }))) * * table.search('john') * * table.sort.toggle('name') * table.sort.toggle('name') * table.sort.toggle('name') * * table.pagination.next() * * table.selection.toggle(1) * ``` */ declare function createDataTable(options?: DataTableOptions): DataTableContext; /** * Creates a data table context with dependency injection support. * * The returned context exposes both row and column registries. Columns must * be onboarded after construction — pass them via `context.columns.onboard`, * not in the factory options. * * @param options Data table context options including namespace * @returns A trinity tuple: [useDataTable, provideDataTable, defaultContext] * * @example * ```ts * import { createDataTableContext } from '@vuetify/v0' * * const [useDataTable, provideDataTable, context] = createDataTableContext({ * namespace: 'app:users', * }) * * context.columns.onboard([ * { id: 'name', title: 'Name', sortable: true }, * ]) * * // Parent component * provideDataTable() * context.onboard(users.map(value => ({ id: value.id, value }))) * * // Child component * const table = useDataTable() * ``` */ declare function createDataTableContext(_options?: DataTableContextOptions): ContextTrinity>; /** * Returns the current data table context from dependency injection. * * @typeParam T - Must be provided explicitly; cannot be inferred from namespace. * Prefer the `useX` function from {@link createDataTableContext} for type-safe injection. * * @param namespace The namespace for the data table context. @default 'v0:data-table' * @returns The current data table context * * @example * ```vue * * ``` */ declare function useDataTable(namespace?: string): DataTableContext; //#endregion //#region src/composables/createDataGrid/editing.d.ts interface EditableColumn { readonly id: string; readonly editable?: boolean | ((item: T) => boolean); readonly validate?: (value: unknown, item?: T) => string | true; } /** * Minimal structural type of the row registry surface that * `createCellEditing` subscribes to for pruning stale state. * * Compatible with the registry returned by `createDataTable` / spread onto * `createDataGrid`. The `on` / `off` channel is needed — handlers subscribe at * setup and unsubscribe on scope dispose, so a registry that outlives the * editing instance does not accumulate listeners. The payload arrives as * `unknown` and is narrowed inside the handler. */ interface CellEditingRegistry { on: (event: string, listener: (data: unknown) => void) => void; off: (event: string, listener: (data: unknown) => void) => void; } interface CellEditingOptions { /** * Editable columns, read reactively. Accepts a ref or getter so the column * set can change after construction — e.g. a grid that derives editables * from a live column registry. Resolved via `toValue` on every `edit` / * `commit`, so newly-onboarded editable columns are picked up without * re-creating the editing instance. */ columns: MaybeRefOrGetter[]>; onEdit?: (row: ID, column: string, value: unknown) => void; lookup?: (row: ID) => T | undefined; registry?: CellEditingRegistry; } interface ActiveCell { row: ID; column: string; } /** * Cell editing state and controls returned by {@link createCellEditing}. * * @example * ```ts * grid.editing.edit(1, 'email') * grid.editing.commit('x@y.z') * * grid.editing.active.value // { row: 1, column: 'email' } | null * grid.editing.error.value // 'Invalid email' | null * grid.editing.dirty // Map> (ShallowReactive) * ``` */ interface CellEditing { active: Readonly>; edit: (row: ID, column: string) => void; commit: (value: unknown) => void; cancel: () => void; error: Readonly>; /** * Map of rows that have staged (uncommitted) cell values. The outer key * is the row id; the inner Map is column id → staged value. Empty * entries are not pre-created — consumers that want to stage a value * insert their own per-row Map (or use the dirty Map's `set`). * * `dirty` is a consumer-managed staging area for uncommitted values; * `commit(value)` commits its explicit `value` argument and merely deletes * the matching staged entry — it does not read or auto-flush staged values. */ dirty: Readonly>>>; } //#endregion //#region src/composables/createDataGrid/layout.d.ts type PinPosition = 'left' | 'right' | false; interface GridColumnDef extends ColumnNode { /** Width as a percentage (0–100). Unset columns share remaining space equally. */ readonly size?: number; /** Minimum width as a percentage. @default 2 */ readonly minSize?: number; /** Maximum width as a percentage. @default 100 */ readonly maxSize?: number; /** Pin position. @default false */ readonly pinned?: PinPosition; /** Allow resizing. @default true */ readonly resizable?: boolean; /** Allow reordering. @default true */ readonly reorderable?: boolean; readonly children?: readonly GridColumnDef[]; } interface ResolvedColumn { id: string; index: number; /** Current size as a percentage */ size: number; /** Distance from the column's pinning edge — left edge for left/scrollable, right edge for right. Apply directly as the CSS `left` / `right` value for sticky positioning. */ offset: number; pinned: PinPosition; resizable: boolean; reorderable: boolean; minSize: number; maxSize: number; /** Whether the column is part of the render set. Always `true` for render-set entries; meaningful on `all`, where hidden columns surface as `false`. */ visible: boolean; } interface PinnedRegion { left: ResolvedColumn[]; scrollable: ResolvedColumn[]; right: ResolvedColumn[]; } interface ColumnLayout { /** Resolved columns for each pin region (hidden columns excluded) */ pinned: Readonly>; /** All visible resolved columns in display order (hidden columns excluded) */ columns: Readonly>; /** Every column in display order, including hidden ones, each carrying a `visible` flag — for a column chooser. */ all: Readonly>; /** Pin a column to a region (or unpin with false) */ pin: (id: string, position: PinPosition) => void; /** * Resize a column by delta percentage within its pin region. * The neighbor to the right absorbs the inverse delta. * No-op for the last column in its region or non-resizable columns. */ resize: (id: string, delta: number) => void; /** * Move a column from one display-order index to another. Indices address * the visible display set (matching `columns`), so hidden columns are not * counted. No-op if the resolved top-level group has `reorderable: false`. */ reorder: (from: number, to: number) => void; /** * Replace visible-column sizes in registry (mount) order, not pin display order. * Hidden columns keep their sizes. Length must match the visible leaf count. */ distribute: (sizes: number[]) => void; /** Show a previously hidden column */ show: (id: string) => void; /** Hide a column — excludes it from the render set without redistributing */ hide: (id: string) => void; /** Toggle a column's visibility */ toggle: (id: string) => void; /** Restore initial sizes, order, and pins */ reset: () => void; } //#endregion //#region src/composables/createDataGrid/spanning.d.ts interface SpanEntry { rowSpan: number; hidden: boolean; } /** * Options for {@link createRowSpanning}. * * @template T Row value type. * * @example * ```ts * const options: RowSpanningOptions = { * items: computed(() => grid.items.value), * columns: ['group', 'ticker', 'value'], * span: (item, column) => column === 'group' ? 3 : 1, * } * ``` */ interface RowSpanningOptions> { items: Ref | ComputedRef; columns: MaybeRefOrGetter; /** * Projects the row key from its item and index. Takes precedence over * `itemKey` — the grid passes the registry ticket id so the span map shares * identity with the rest of the grid. Rows whose projected key is * `undefined` are skipped, since their spans can't be addressed. */ key?: (item: T, index: number) => ID | undefined; /** * Property used to identify each row in the span map when `key` is absent. * Rows whose value for this key is `undefined` are skipped, since their * spans can't be addressed. */ itemKey?: string; /** * Resolves the row span for a cell. Return a value < 1 (or `NaN`) to span a * single row. When absent, no spans are produced. */ span?: (item: T, column: string) => number; } //#endregion //#region src/composables/createDataGrid/index.d.ts /** * Column registration shape for `createDataGrid`. Extends the data-table * column ticket input with grid-specific layout, editing, and spanning config. * * The extra fields ride on the column ticket — `createRegistry` preserves them * via `{ ...registration }` — so layout/editing/spanning read config straight * off the registered ticket. Nested `children` config rides inline on the * parent ticket, mirroring `DataTableColumnTicketInput`. * * @template T Row value type. * * @example * ```ts * const grid = createDataGrid() * * grid.columns.onboard([ * { id: 'name', sortable: true, size: 40, pinned: 'left' }, * { id: 'price', editable: true, validate: v => Number(v) >= 0 || 'must be positive' }, * ]) * ``` */ interface DataGridColumnTicketInput extends DataTableColumnTicketInput { /** Width as a percentage (0–100). Unset columns share remaining space equally. */ size?: number; /** Minimum width as a percentage. @default 2 */ minSize?: number; /** Maximum width as a percentage. @default 100 */ maxSize?: number; /** Pin position. @default false */ pinned?: PinPosition; /** Allow resizing. @default true */ resizable?: boolean; /** Allow reordering. @default true */ reorderable?: boolean; /** Whether cells in this column can be edited. A function gates per-row. */ editable?: boolean | ((item: T) => boolean); /** Validate an edited value; return `true` to accept or a string error to reject. */ validate?: (value: unknown, item?: T) => string | true; /** Row span for a cell in this column. */ span?: (item: T) => number; /** Header-group children (recursive). Children are NOT separately registered. */ children?: readonly DataGridColumnTicketInput[]; } /** * Output ticket returned by `grid.columns.register` / `grid.columns.onboard`. * * Combines the standard registry ticket fields (`index`, `valueIsIndex`, * `unregister`) with the column-shape fields from {@link DataGridColumnTicketInput}. * * @template T Row value type. */ type DataGridColumnTicket = DataTableColumnTicket & DataGridColumnTicketInput; /** * Factory options for {@link createDataGrid}. Extends {@link DataTableOptions} * with cell-editing, row-spanning, and row-order-preservation config. * * @template T Row value type. * * @example * ```ts * const grid = createDataGrid({ * editing: { onEdit (row, column, value, item) { persist(item.id, column, value) } }, * rowSpanning: (item, column) => column === 'group' ? 3 : 1, * preserveRowOrder: true, * }) * ``` */ interface DataGridOptions extends DataTableOptions { editing?: { onEdit?: (row: ID, column: string, value: unknown, item: T) => void; }; preserveRowOrder?: MaybeRefOrGetter; rowSpanning?: (item: T, column: string) => number; } /** * The reactive grid instance returned by {@link createDataGrid}. Spreads the * inherited {@link DataTableContext} surface and adds `layout`, `rows`, * `editing`, `spans`, `orderedItems`, and `rank`. Does not override parent * `sortedItems` (PHILOSOPHY §2.6). * * @template T Row value type. * * @example * ```ts * const grid = createDataGrid() * * grid.layout.pin('name', 'left') * grid.rows.move(id, 0) * grid.editing.edit(1, 'email') * grid.spans.value.get(id)?.get('group') * grid.orderedItems.value * grid.rank(source) * ``` */ interface DataGridContext extends DataTableContext { /** * Column registry, widened to the grid column ticket shape. Covariant * override of the inherited {@link DataTableContext.columns} (PHILOSOPHY * §2.6): every grid-added column field (`size`, `pinned`, `editable`, * `validate`, `span`, `minSize`, `maxSize`, `resizable`, `reorderable`) is * optional, so the widened input still satisfies the base `register` / * `onboard` signatures and runtime behavior is unchanged. */ columns: RegistryContext, DataGridColumnTicket>; /** * Full filter+sort+row-order list before pagination. When row order is * not dirty this is `sortedItems`. Rank a source array with `rank()` * so `rows.move()` reorders the DOM. * * @example * ```ts * grid.rows.move(id, 0) * grid.orderedItems.value[0] * ``` */ orderedItems: Readonly>; /** * Rank a source array by `orderedItems`. v-for this so rows register; * missing ranks stay in source order. Ranks by `orderedItems` (not * `sortedItems`) so `rows.move()` is visible. * * @example * ```ts * grid.rows.move(id, 0) * grid.rank(source)[0] * ``` */ rank: (source: readonly U[]) => U[]; layout: ColumnLayout; rows: { order: Readonly>; move: (id: ID, toIndex: number) => void; reset: () => void; }; editing: CellEditing; spans: ComputedRef>>; } interface DataGridContextOptions extends DataGridOptions { namespace?: string; } /** * Creates a data grid instance with layout, editing, row ordering, and spanning * layered on top of the createDataTable pipeline. * * Rows live on the inherited registry surface — register them with * `grid.onboard(rows.map(value => ({ id: value.id, value })))` or * `grid.register({ id, value })`. * * @param options Data grid options * @returns Data grid context * * @example * ```ts * const grid = createDataGrid({ pagination: { page: 1 } }) * * grid.columns.onboard([ * { id: 'name', sortable: true }, * { id: 'progress', editable: true, validate: v => Number(v) >= 0 || 'must be positive' }, * ]) * * grid.onboard(rows.map(value => ({ id: value.id, value }))) * grid.layout.pin('name', 'left') * grid.rows.move(rowId, 0) * grid.editing.edit(row.id, 'progress') * ``` */ declare function createDataGrid(_options?: DataGridOptions): DataGridContext; /** * Creates a data grid context with dependency injection support. * * @param options Data grid context options including namespace * @returns A trinity tuple: [useDataGridContext, provideDataGridContext, defaultContext] * * @example * ```ts * const [useDataGrid, provideDataGrid, grid] = createDataGridContext({ * namespace: 'v0:projects', * }) * * grid.columns.onboard(columns) * grid.onboard(rows.map(value => ({ id: value.id, value }))) * provideDataGrid() * const ctx = useDataGrid() * ``` */ declare function createDataGridContext(_options?: DataGridContextOptions): ContextTrinity>; /** * Returns the current data grid context from dependency injection. * * @param namespace The namespace for the data grid context. @default 'v0:data-grid' * @returns The current data grid context * * @example * ```ts * const grid = useDataGrid() * * grid.layout.pin('id', 'left') * grid.rows.reset() * ``` */ declare function useDataGrid(namespace?: string): DataGridContext; //#endregion //#region src/composables/createPlugin/index.d.ts interface PluginOptions { namespace: string; provide: (app: App) => void; setup?: (app: App) => void; /** When true, this plugin appears in the Vue DevTools v0 inspector. @default false */ devtools?: boolean; /** Overlay keys onto the inspector snapshot (adapter names, method-backed state). */ inspect?: (context: unknown) => unknown; } interface Plugin { install: (app: App, ...options: unknown[]) => void; } /** * Attach a plugin context to the DevTools inspector record for `namespace`. * * `createPluginContext` calls this after provide. Plugins that wrap * `createPlugin` directly (stack, date) must call it from `provide`. * * @param app The Vue app the plugin was installed on. * @param namespace The plugin namespace, e.g. `'v0:stack'`. * @param context The live plugin context to show in the inspector. * * @example * ```ts * return createPlugin({ * namespace, * provide: app => { * provideStackContext(context, app) * bindPluginContext(app, namespace, context) * }, * }) * ``` */ declare function bindPluginContext(app: App, namespace: string, context: unknown): void; /** * Creates a new Vue plugin. * * @param options The plugin options. * @returns A new Vue plugin. * * @see https://0.vuetifyjs.com/composables/foundation/create-plugin * * @example * ```ts * export const [useContext, provideContext] = createContext('my-plugin') * * const context = {} * * export const MyPlugin = createPlugin({ * namespace: 'my-plugin', * provide: (app) => { * provideContext(context, app) * }, * setup: (app) => { * // Optional setup logic * }, * }) */ declare function createPlugin(options: PluginOptions): Z; interface PluginContextConfig { /** * Optional plugin setup callback, called once per Vue app after context provision. * Use for adapter initialization, Vue app mixins, global side effects, etc. * Receives the plugin options (minus namespace) so adapters and targets are accessible. */ setup?: (context: E, app: App, options: O) => void; /** * Optional fallback factory. When provided, the generated `useX` consumer uses the * defensive pattern: returns the fallback when called outside a component instance or * when the context is not found. Required for composables that may be consumed outside * component setup (e.g. useLogger, useLocale, useHydration). * * Receives the requested namespace so error messages can include it. */ fallback?: (namespace: string) => E; /** Returns the value to persist. Called reactively inside a watch source. */ persist?: (context: E) => unknown; /** Restores previously persisted state into the context. Called before setup. */ restore?: (context: E, saved: unknown) => void; /** Default `devtools` for this plugin. Install-time `devtools` overrides. @default false */ devtools?: boolean; /** Overlay keys onto the inspector snapshot (adapter names, method-backed state). */ inspect?: (context: E) => unknown; } /** * Creates the three standard functions for a plugin composable. * * @param defaultNamespace The default DI namespace string (e.g. `'v0:logger'`). * @param factory Function that creates the composable context instance from options. * @param config Optional setup callback and fallback factory. * @returns A readonly tuple: `[createXContext, createXPlugin, useX]`. * * @example * ```ts * // Simple — no setup or fallback * export const [createStorageContext, createStoragePlugin, useStorage] = * createPluginContext('v0:storage', options => createStorage(options)) * * // With fallback — safe outside component instances * export const [createLoggerContext, createLoggerPlugin, useLogger] = * createPluginContext('v0:logger', options => createLogger(options), { * fallback: ns => createFallbackLogger(ns), * setup: (context) => { * if (__DEV__ && IN_BROWSER) (window as Window & { __v0Logger__?: typeof context }).__v0Logger__ = context * }, * }) * ``` */ type PluginKeys = { namespace?: string; persist?: boolean; devtools?: boolean; }; type PluginMeta = keyof PluginKeys; declare function createPluginContext, E = unknown>(defaultNamespace: string, factory: (options: Omit) => E, config?: PluginContextConfig, E>): readonly [<_E extends E = E>(_options?: O) => ContextTrinity<_E>, (_options?: O & Pick) => Plugin, <_E extends E = E>(namespace?: string) => _E]; //#endregion //#region src/composables/useRules/adapters/standard.d.ts /** * Minimal duck-typed interface matching the Standard Schema spec (v1). * No npm dependency — structurally compatible with Zod (v3.24+), Valibot, ArkType, and others. * * @see https://standardschema.dev/ */ interface StandardSchemaIssue { readonly message: string; readonly path?: ReadonlyArray | undefined; } interface StandardSchemaResult { readonly value?: unknown; readonly issues?: ReadonlyArray | undefined; } interface StandardSchemaV1 { readonly '~standard': { readonly version: 1; readonly vendor: string; readonly validate: (value: unknown) => StandardSchemaResult | Promise; }; } /** * Type guard for Standard Schema objects. * Checks for the `~standard` property that all conforming libraries expose. * * @param value The value to check. * @returns `true` if the value conforms to the Standard Schema interface. */ declare function isStandardSchema(value: unknown): value is StandardSchemaV1; //#endregion //#region src/composables/useRules/index.d.ts /** A rule alias: a string name referencing a registered predicate. */ type RuleAlias = string; /** * Input accepted by resolve(): alias strings, raw validation functions, * or Standard Schema objects (Zod v3.24+, Valibot, ArkType, etc.). */ type RuleInput = RuleAlias | FormValidationRule | StandardSchemaV1; /** A map of alias names to predicate functions. */ interface RuleAliases { [name: string]: FormValidationRule; } interface RulesContext { /** Resolve aliases, functions, and Standard Schema objects to FormValidationRule[]. */ resolve: (rules: RuleInput[]) => FormValidationRule[]; /** The alias map (custom aliases registered via options). */ aliases: RuleAliases; } interface RulesOptions { /** Custom aliases to register. Each alias is a predicate (FormValidationRule). */ aliases?: Partial; } interface RulesContextOptions extends RulesOptions { namespace?: string; } /** * Creates a new rules instance. * * @param options The options for the rules instance. * @returns A new rules instance with resolve() and aliases. * * @see https://0.vuetifyjs.com/composables/plugins/use-rules * * @example * ```ts * import { createRules } from '@vuetify/v0' * * const rules = createRules({ * aliases: { * required: (v) => !!v || false, * }, * }) * * // Resolve alias strings to validation functions * const resolved = rules.resolve(['required']) * ``` */ declare function createRules(_options?: RulesOptions): RulesContext; /** * Creates a fallback rules instance for use outside component scope. * No locale lookup — `false` returns fall back to the alias name. * * @returns A standalone rules context with empty aliases. */ declare function createRulesFallback(): RulesContext; declare const createRulesContext: <_E extends RulesContext = RulesContext>(_options?: RulesContextOptions | undefined) => ContextTrinity<_E>, createRulesPlugin: (_options?: (RulesContextOptions & Pick<{ namespace?: string; persist?: boolean; devtools?: boolean; }, "devtools">) | undefined) => Plugin, useRules: <_E extends RulesContext = RulesContext>(namespace?: string) => _E; //#endregion //#region src/composables/createValidation/index.d.ts /** * Input type for validation tickets. * Each ticket represents a single validation rule. */ interface ValidationTicketInput extends GroupTicketInput {} /** * Output type for validation tickets. * Includes selection methods from GroupTicket for enabling/disabling rules. */ type ValidationTicket = GroupTicket; /** * Context for managing validation rules for a single input. * * @template Z The input ticket type. * @template E The output ticket type. */ interface ValidationContext = ValidationTicket> extends Omit, 'register' | 'onboard' | 'reset'> { register: (rule: RuleInput | Partial) => E; onboard: (rules: (RuleInput | Partial)[]) => E[]; /** Run validation against all active (selected) rules. */ validate: (value?: unknown, silent?: boolean) => Promise; /** Reset errors and validation state. Does not affect rule selection. */ reset: () => void; /** Current validation error messages. */ errors: ShallowRef; /** Tri-state: null (not validated), true (valid), false (invalid). */ isValid: ShallowRef; /** Whether async validation is in progress. */ isValidating: ShallowRef; } interface ValidationOptions extends GroupOptions { /** Initial rules to register. */ rules?: RuleInput[]; /** Value source for validate() when called without arguments. */ value?: MaybeRefOrGetter; /** * Form injection key. Must match the parent Form's `namespace`. * * @default 'v0:form' * * @example * ```ts * createValidation({ formNamespace: 'v0:billing' }) * ``` */ formNamespace?: string; } /** * Creates a per-input validation instance. * * Built on `createGroup` — each registered rule becomes a ticket that can be * enabled/disabled via selection methods (`select`, `unselect`, `toggle`). * Only selected (active) rules run during validation. * * @param options The options for the validation instance. * @returns A new validation context. * * @see https://0.vuetifyjs.com/composables/forms/create-validation * * @example * ```ts * import { createValidation } from '@vuetify/v0' * * const validation = createValidation({ * rules: [ * v => !!v || 'Required', * v => /^.+@\S+\.\S+$/.test(String(v)) || 'Invalid email', * ], * }) * * await validation.validate('') * * console.log(validation.errors.value) // ['Required', 'Invalid email'] * * validation.reset() * ``` */ declare function createValidation(_options?: ValidationOptions): ValidationContext; //#endregion //#region src/composables/createForm/index.d.ts type FormValidationResult = string | boolean | Promise; type FormValidationRule = (value: unknown) => FormValidationResult; type FormValue = ValidationContext; /** * User-facing input shape for form tickets. */ interface FormTicketInput extends RegistryTicketInput {} /** * A registered validation in the form registry. * * @template Z The input ticket type that extends FormTicketInput. */ type FormTicket = RegistryTicket & Z; /** * Context for coordinating validation across multiple fields. * * @template Z The input ticket type. * @template E The output ticket type. */ interface FormContext = FormTicket> extends Omit, 'register' | 'onboard'> { /** Register a validation context with the form. */ register: (registration: Partial & { value: FormValue; }) => E; /** Submit: validate specific fields or all. */ submit: (id?: ID | ID[]) => Promise; /** Reset all registered validations. */ reset: () => void; /** Whether the form is disabled. Components can read this to conditionally disable inputs. */ disabled: MaybeRefOrGetter; /** Whether the form is readonly. Components can read this to conditionally disable inputs. */ readonly: MaybeRefOrGetter; /** Aggregate: true if all validations valid, false if any invalid, null if any unvalidated. */ isValid: ComputedRef; /** Aggregate: true if any validation is in progress. */ isValidating: ComputedRef; } interface FormOptions extends RegistryOptions { /** Whether the form starts disabled. */ disabled?: MaybeRefOrGetter; /** Whether the form starts readonly. */ readonly?: MaybeRefOrGetter; } interface FormContextOptions extends FormOptions { namespace?: string; } /** * Creates a new form instance. * * A form is a pure registry of validation contexts. Validations register * themselves via `useForm()` injection. The form coordinates submit, reset, * and aggregate state across all registered validations. * * @param options The options for the form instance. * @returns A new form context. * * @see https://0.vuetifyjs.com/composables/forms/create-form * * @example * ```ts * import { createForm, createValidation } from '@vuetify/v0' * import { shallowRef } from 'vue' * * const form = createForm() * * // Each validation is one input — form is just the coordinator * const email = shallowRef('') * const validation = createValidation({ * value: email, * rules: ['required', 'email'], * }) * * form.register({ value: validation }) * * await form.submit() * form.reset() * ``` */ declare function createForm(_options?: FormOptions): FormContext; /** * Creates a new form context using the Trinity pattern. * * @param options The options for the form context. * @returns A Trinity tuple: [useFormContext, provideFormContext, formContext] * * @see https://0.vuetifyjs.com/composables/forms/create-form * * @example * ```ts * import { createFormContext } from '@vuetify/v0' * * export const [useMyForm, provideMyForm, myForm] = createFormContext() * ``` */ declare function createFormContext(_options?: FormContextOptions): ContextTrinity; /** * Returns the current form instance. * * @param namespace The namespace for the form context. Defaults to `'v0:form'`. * @returns The current form instance, or undefined if not provided. * * @see https://0.vuetifyjs.com/composables/forms/create-form * * @example * ```vue * * ``` */ declare function useForm = FormTicket, R extends FormContext = FormContext>(namespace?: string): R | undefined; //#endregion //#region src/composables/createInput/index.d.ts /** Visual state of the input for styling purposes. */ type InputState = 'pristine' | 'valid' | 'invalid'; interface InputOptions { /** Value source — caller owns this ref. */ value: Ref; /** Unique identifier (auto-generated if omitted). */ id?: ID; /** Display label. */ label?: string; /** Form field name. */ name?: string; /** Associate with form by ID. */ form?: string; /** * Form injection key. Must match the parent Form's `namespace`. * * @default 'v0:form' */ formNamespace?: string; /** * Whether required. When true, a presence rule is registered so Form * submit fails on empty values even with `novalidate`. */ required?: boolean; /** Disabled state. */ disabled?: MaybeRefOrGetter; /** Readonly state. */ readonly?: MaybeRefOrGetter; /** Validation rules. */ rules?: (FormValidationRule | RuleAlias | StandardSchemaV1)[]; /** Manual error state override — forces invalid. */ error?: MaybeRefOrGetter; /** Manual error messages — merged with rule-based errors. */ errorMessages?: MaybeRefOrGetter | undefined>; /** Predicate for "has content". */ dirty?: (value: T) => boolean; /** Equality check for pristine tracking. @default === */ equals?: (a: T, b: T) => boolean; } interface InputContext { readonly id: ID; readonly label?: string; readonly name?: string; readonly form?: string; readonly required?: boolean; readonly descriptionId: string; readonly errorId: string; descriptions: RegistryContext; fieldErrors: RegistryContext; hasDescription: Readonly>; hasError: Readonly>; value: Ref; isDirty: Readonly>; isFocused: ShallowRef; isDisabled: Readonly>; isReadonly: Readonly>; isPristine: Readonly>; isTouched: ShallowRef; errors: Readonly>; isValid: Readonly>; isValidating: Readonly>; validate: () => Promise; reset: () => void; state: Readonly>; } declare function createInput(options: InputOptions): InputContext; //#endregion //#region src/composables/createSortable/index.d.ts /** * Input shape passed to `register` / `onboard`. Inherits all model fields. * * @template V Type of the per-ticket value. * * @example * ```ts * interface TaskTicket extends SortableTicketInput { * value: { id: number; label: string } * } * * const sortable = createSortable() * sortable.register({ value: { id: 1, label: 'A' } }) * ``` */ type SortableTicketInput = ModelTicketInput; /** * Output ticket returned by `register` / `onboard` / `get`. * Aliased to `ModelTicket` — sortable adds no per-ticket fields. * * @template Z The input ticket type (carries the value type V). */ type SortableTicket = ModelTicket; /** * Options accepted by `createSortable`. * * @example * ```ts * const sortable = createSortable({ * disabled: toRef(() => isReadOnlyMode.value), * }) * ``` */ interface SortableOptions extends Omit { /** * Mutation gate. When truthy, `move` / `swap` / `reorder` silently no-op. * * @default false * @remarks Per-ticket `disabled` is honored at the `move` and `swap` call sites * for that ticket. `reorder` **bypasses** per-ticket `disabled` — it's a bulk * operation declaring the canonical order, and applying that order may relocate * disabled tickets. `register` / `onboard` / `unregister` are NEVER gated — * those are composition, not user-driven reorder. * * @example * ```ts * const sortable = createSortable({ disabled: toRef(() => isSaving.value) }) * ``` */ disabled?: MaybeRefOrGetter; } /** * Payload of the `move:ticket` event. * * @example * ```ts * sortable.on('move:ticket', ({ ticket, from, to }) => { * console.log(ticket.id, from, to) * }) * ``` */ interface SortableMovePayload { ticket: E; from: number; to: number; } /** * Listener-binding signature for a sortable instance — a typed overload for * `move:ticket` plus the registry's generic event channel. * * @template E Output ticket type. */ type SortableEventListener = { (event: 'move:ticket', cb: (data: SortableMovePayload) => void): void; >(event: K, cb: RegistryEventCallback): void; }; /** * Public API of a sortable instance. * * @template Z Input ticket type. * @template E Output ticket type. */ interface SortableContext = SortableTicket> extends Omit, 'on' | 'off' | 'move'> { /** * Subscribe to the typed `move:ticket` event with a strongly-typed payload. * * @example * ```ts * sortable.on('move:ticket', ({ ticket, from, to }) => { * console.log(ticket.id, from, to) * }) * ``` */ on: SortableEventListener; /** * Unsubscribe from a `move:ticket` listener. Must be called with the same callback reference used to subscribe. * * @example * ```ts * function onMove ({ ticket, from, to }: SortableMovePayload) { * console.log(ticket.id, from, to) * } * * sortable.on('move:ticket', onMove) * // later... * sortable.off('move:ticket', onMove) * ``` */ off: SortableEventListener; /** * Move a ticket to a target index. Other tickets shift to fill. * Emits `move:ticket` once when the index actually changes — a move whose * `toIndex` already equals the ticket's current index is a no-op. * No-ops when the root sortable is disabled or when the ticket is disabled. * * @param id Ticket id to move. * @param toIndex Target index (zero-based). * @returns The moved ticket, or `undefined` when the move was gated or the id is unknown. * * @example * ```ts * sortable.move(ticket.id, 2) * ``` */ move: (id: ID, toIndex: number) => E | undefined; /** * Swap two tickets' positions. Emits `move:ticket` twice — once per ticket. * No-ops when the root sortable is disabled or when either ticket is disabled. * * @param a Ticket id at one position. * @param b Ticket id at the other position. * * @example * ```ts * sortable.swap(a.id, b.id) * ``` */ swap: (a: ID, b: ID) => void; /** * Set the canonical order in one shot. * * @param ids Permutation of currently-registered ticket ids. * * @remarks * Validates `ids.length === registry.size` and that every id is unique and known. * Logs a warning via `useLogger()` and silently no-ops if any check fails — drag * handlers that race against concurrent unregisters won't crash. * * Honors root `disabled` (whole call no-ops). Per-ticket `disabled` is **ignored** — * `reorder` is a bulk operation declaring the canonical order, and applying that * order may move disabled tickets. If you want disabled tickets pinned, exclude * them from the ids you pass. * * @example * ```ts * sortable.reorder([c.id, a.id, b.id]) * ``` */ reorder: (ids: ID[]) => void; } /** * Create an ordered-list state primitive. * * @param options Sortable options. * @returns A {@link SortableContext} that extends {@link ModelContext}. * * @example * ```ts * const sortable = createSortable() * sortable.onboard(todos.value.map(value => ({ value }))) * ``` */ declare function createSortable = SortableTicket>(_options?: SortableOptions): SortableContext; //#endregion //#region src/composables/createKanban/index.d.ts /** * Options accepted by `createKanban`. * * @example * ```ts * import { createKanban } from '@vuetify/v0' * import { shallowRef, toRef } from 'vue' * * const isReadOnly = shallowRef(false) * const kanban = createKanban({ disabled: toRef(() => isReadOnly.value) }) * ``` */ interface KanbanOptions extends Omit { /** * Mutation gate. When truthy, `transfer` and column-level mutations no-op. * * @default false */ disabled?: MaybeRefOrGetter; } /** * Input shape for a column ticket. Parameterized over the per-column inner * ticket type so `accept` is typed against the caller's domain. * * @template ItemZ The inner ticket input type (extends `SortableTicketInput`). * @template V The column's own value type. * * @example * ```ts * import type { KanbanColumnTicketInput, SortableTicketInput } from '@vuetify/v0' * * interface CardTicket extends SortableTicketInput { * value: { title: string } * } * * interface BoardColumn extends KanbanColumnTicketInput { * value: { title: string; color: string } * } * ``` */ interface KanbanColumnTicketInput extends SortableTicketInput { /** * Per-column mutation gate. When truthy, transfers into and out of this * column are blocked, and the column's inner `items` sortable is disabled * (move / swap / reorder no-op). Column-level operations on * `kanban.columns` are unaffected — those are gated by the kanban-level * `disabled`. * * @default false */ disabled?: MaybeRefOrGetter; /** * Predicate veto for incoming transfers. Synchronous boolean return: * `true` accepts; `false` rejects (silent no-op). Async predicates are * rejected at runtime with a warning. * * @param ticket The item being transferred (from the source column). * @param from The source column id. * @param toIndex The target index inside this destination column. * * @example * ```ts * const review = kanban.columns.register({ * value: { title: 'Review' }, * accept: (ticket, from) => from !== archiveColumn.id, * }) * ``` */ accept?: (ticket: SortableTicket, from: ID, toIndex: number) => boolean; } /** * Output ticket returned from `kanban.columns.register`. Extends `SortableTicket` * with the column's own inner sortable on `items`. * * @template ItemZ Inner ticket input type. * @template Z Column input type. * * @example * ```ts * import { createKanban } from '@vuetify/v0' * * const kanban = createKanban() * const todo = kanban.columns.register({ value: { title: 'Todo' } }) * todo.items.register({ value: { title: 'Write spec' } }) * console.log(todo.id, todo.value.title, todo.items.size) * ``` */ type KanbanColumnTicket = KanbanColumnTicketInput> = SortableTicket & { items: SortableContext; }; /** * Payload of the `transfer:ticket` event on the kanban bus. * * @example * ```ts * import { createKanban } from '@vuetify/v0' * * const kanban = createKanban() * * kanban.on('transfer:ticket', ({ ticket, from, to, toIndex }) => { * console.log(ticket.id, from, '→', to, '@', toIndex) * }) * ``` */ interface KanbanTransferPayload { ticket: SortableTicket; from: ID; to: ID; fromIndex: number; toIndex: number; } /** * Listener signature for the kanban-level `transfer:ticket` event. Registry * events (`register:ticket`, `unregister:ticket`, etc.) live on the columns * registry — subscribe via `kanban.columns.on(...)` rather than `kanban.on(...)`. * * @example * ```ts * import { createKanban } from '@vuetify/v0' * * const kanban = createKanban() * * kanban.on('transfer:ticket', ({ ticket, from, to, toIndex }) => { * console.log(ticket.id, from, '→', to, '@', toIndex) * }) * ``` */ type KanbanEventListener = (event: 'transfer:ticket', cb: (data: KanbanTransferPayload) => void) => void; /** * Public context returned by `createKanban`. * * @example * ```ts * import { createKanban } from '@vuetify/v0' * import type { KanbanColumnTicketInput, SortableTicketInput } from '@vuetify/v0' * * interface CardTicket extends SortableTicketInput { * value: { title: string } * } * * interface BoardColumn extends KanbanColumnTicketInput { * value: { title: string } * } * * const kanban = createKanban() * * const [todo, done] = kanban.columns.onboard([ * { value: { title: 'Todo' } }, * { value: { title: 'Done' } }, * ]) * * const card = todo.items.register({ value: { title: 'Write spec' } }) * * kanban.on('transfer:ticket', ({ ticket, from, to, toIndex }) => { * console.log(`${ticket.id}: ${from} → ${to} @ ${toIndex}`) * }) * * kanban.transfer(card.id, done.id, 0) * ``` */ interface KanbanContext = KanbanColumnTicketInput> { /** * Column registry. Use this for column register / unregister / move / swap / reorder. * * @remarks * Unregistering a column disposes its `items` sortable — all of the column's * tickets are dropped and any subscribers attached to `column.items` are * cleared. The internal cleanup runs before consumer-registered * `unregister:ticket` handlers, so you cannot rescue items from inside that * callback. To preserve items, move them before calling `unregister`. * * `columns.dispose` is the board cascade — the same function as * `kanban.dispose()` — not a columns-only wipe. * * @example * ```ts * import { createKanban } from '@vuetify/v0' * * const kanban = createKanban() * const todo = kanban.columns.register({ value: { title: 'Todo' } }) * todo.items.register({ value: { title: 'Write spec' } }) * kanban.columns.move(todo.id, 1) * ``` * * @example * ```ts * // Reflow items into a fallback column before disposing the source column. * for (const item of todo.items.values()) { * trash.items.register({ id: item.id, value: item.value }) * } * todo.unregister() * ``` */ columns: SortableContext>; /** * Move an item across columns. Same-column transfer (where `toColumnId` * matches the item's current column) collapses to `column.items.move` and * does not emit `transfer:ticket`. * * Returns the moved ticket, or `undefined` when gated (kanban / source / destination / * item disabled, destination.accept rejected, unknown id, duplicate destination id). * * @example * ```ts * import { createKanban } from '@vuetify/v0' * * const kanban = createKanban() * const [todo, done] = kanban.columns.onboard([{ value: 'Todo' }, { value: 'Done' }]) * const card = todo.items.register({ value: 'Write spec' }) * * const moved = kanban.transfer(card.id, done.id, 0) * if (moved) console.log('landed at', moved.index) * * // Returns undefined when gated by disabled, accept, or unknown ids: * kanban.transfer(card.id, 'no-such-column', 0) // → undefined * ``` */ transfer: (id: ID, toColumnId: ID, toIndex: number) => SortableTicket | undefined; /** * Subscribe to the kanban-level `transfer:ticket` event, fired after each * successful cross-column move. Registry events (`register:ticket`, * `unregister:ticket`, `move:ticket`) live on the columns registry — use * `kanban.columns.on(...)` for those, or `column.items.on(...)` for * per-column intra-column reorder events. * * @example * ```ts * import { createKanban } from '@vuetify/v0' * * const kanban = createKanban() * * kanban.on('transfer:ticket', ({ ticket, from, to, fromIndex, toIndex }) => { * console.log(ticket.id, from, '→', to, '@', toIndex) * }) * ``` */ on: KanbanEventListener; /** * Unsubscribe from the `transfer:ticket` event. Must be called with the same * callback reference used to subscribe. * * @example * ```ts * import { createKanban } from '@vuetify/v0' * import type { KanbanTransferPayload } from '@vuetify/v0' * * const kanban = createKanban() * * function onTransfer (data: KanbanTransferPayload) { * console.log(data.ticket.id) * } * * kanban.on('transfer:ticket', onTransfer) * // later * kanban.off('transfer:ticket', onTransfer) * ``` */ off: KanbanEventListener; /** * Tear down the entire board: every column's inner `items` sortable, the * internal id → column lookup, the `transfer:ticket` event bus, and the * columns registry itself. `kanban.columns.dispose` is the same function. * Repeatable — a later call after `columns.register` tears down the rebuilt * board the same way. * * @remarks * Registry `dispose()` runs `clear()`, which never emits `unregister:ticket`, * so the per-column cleanup subscribed on that event would not run. This * method walks current columns and disposes each inner sortable first, then * re-binds that cleanup so a rebuilt board still cascades on column * unregister. * * @example * ```ts * import { createKanban } from '@vuetify/v0' * * const kanban = createKanban() * kanban.columns.register({ value: { title: 'Todo' } }) * // later * kanban.dispose() * ``` */ dispose: () => void; } /** * Create a headless two-level sortable orchestrator. * * @param options Kanban options (currently only `disabled`). * @returns A {@link KanbanContext}. * * @example * ```ts * import { createKanban } from '@vuetify/v0' * import type { KanbanColumnTicketInput, SortableTicketInput } from '@vuetify/v0' * * interface CardTicket extends SortableTicketInput { * value: { title: string } * } * * interface BoardColumn extends KanbanColumnTicketInput { * value: { title: string } * } * * const kanban = createKanban() * * const todo = kanban.columns.register({ value: { title: 'Todo' } }) * const review = kanban.columns.register({ * value: { title: 'Review' }, * accept: card => card.value.title.length > 0, * }) * * const spec = todo.items.register({ value: { title: 'Write spec' } }) * kanban.transfer(spec.id, review.id, 0) * ``` */ declare function createKanban = KanbanColumnTicketInput>(_options?: KanbanOptions): KanbanContext; //#endregion //#region src/composables/createNested/types.d.ts /** * Input type for nested tickets - what users provide to register(). * Extend this interface to add custom properties. * * @template V The type of the ticket value. */ interface NestedTicketInput extends GroupTicketInput { /** ID of the parent ticket, or undefined if this is a root item */ parentId?: ID; /** Whether this ticket is initially active */ active?: boolean; /** Reference to the DOM element for focus management */ el?: MaybeRefOrGetter; } /** * Output type for nested tickets - what users receive from get(). * Includes all input properties plus tree traversal and state methods. * * @template Z The input ticket type that extends NestedTicketInput. */ type NestedTicket = GroupTicket & { /** ID of the parent ticket, or undefined if this is a root item. Static — set at registration time. */ parentId: ID | undefined; /** Reference to the DOM element for focus management */ el: MaybeRefOrGetter | undefined; /** Whether this ticket is currently open/expanded */ isOpen: Readonly>; /** Whether this ticket is currently active/highlighted */ isActive: Readonly>; /** Whether this ticket is a leaf node (has no children) */ isLeaf: Readonly>; /** Depth in tree (0 = root) */ depth: Readonly>; /** Open/expand this ticket */ open: () => void; /** Close/collapse this ticket */ close: () => void; /** Flip this ticket's open/closed state */ flip: () => void; /** Reveal this ticket by opening all ancestors */ reveal: () => void; /** Activate/highlight this ticket */ activate: () => void; /** Deactivate/unhighlight this ticket */ deactivate: () => void; /** Get path from root to self (includes self) */ getPath: () => ID[]; /** Get ancestors excluding self */ getAncestors: () => ID[]; /** Get all descendants */ getDescendants: () => ID[]; /** Check if this ticket is an ancestor of the given ID */ isAncestorOf: (descendantId: ID) => boolean; /** Check if this ticket has the given ID as an ancestor */ hasAncestor: (ancestorId: ID) => boolean; /** Get sibling IDs (including self) */ siblings: () => ID[]; /** Get 1-indexed position among siblings (for aria-posinset) */ position: () => number; /** Drop the element and keep this ticket registered */ release: () => void; }; /** * Registration input for nested items. * Allows inline children definition for easier tree construction. * * @template Z The input ticket type that extends NestedTicketInput. */ type NestedRegistration = Partial & { /** Inline children to register with this item as parent */ children?: NestedRegistration[]; }; /** * Context for managing nested/hierarchical item collections. * * @template Z The input ticket type. * @template E The output ticket type. * * @remarks * Extends GroupContext with parent-child relationship tracking, open/close state, * and hierarchical traversal methods. Perfect for tree structures, nested menus, * file explorers, and organizational charts. */ interface NestedContext = NestedTicket> extends Omit, 'register' | 'onboard' | 'offboard' | 'select' | 'unselect' | 'toggle'> { /** Map of parent IDs to arrays of child IDs. Use register/unregister to modify. */ readonly children: ReadonlyMap; /** Map of child IDs to their parent ID (or undefined for roots). Use register/unregister to modify. */ readonly parents: ReadonlyMap; /** Reactive Set of opened/expanded item IDs. Use open/close/flip to modify. */ readonly openedIds: Reactive>; /** Computed Set of opened/expanded item instances */ openedItems: ComputedRef>; /** Reactive Set of active/highlighted item IDs. Use activate/deactivate to modify. */ readonly activeIds: Reactive>; /** Computed Set of active/highlighted item instances */ activeItems: ComputedRef>; /** Computed Set of active item indexes (position-based) */ activeIndexes: ComputedRef>; /** Activate/highlight one or more items by ID */ activate: (ids: ID | ID[]) => void; /** Deactivate/unhighlight one or more items by ID */ deactivate: (ids: ID | ID[]) => void; /** Check if an item is active by ID */ activated: (id: ID) => boolean; /** Deactivate all items */ deactivateAll: () => void; /** Open/expand one or more items by ID */ open: (ids: ID | ID[]) => void; /** Close/collapse one or more items by ID */ close: (ids: ID | ID[]) => void; /** Flip one or more items' open/closed state by ID */ flip: (ids: ID | ID[]) => void; /** Check if an item is open by ID */ opened: (id: ID) => boolean; /** Open node(s) and their immediate non-leaf children */ unfold: (ids: ID | ID[]) => void; /** Reveal node(s) by opening all ancestors (makes node visible without opening it) */ reveal: (ids: ID | ID[]) => void; /** Fully expand node(s) and all their non-leaf descendants */ expand: (ids: ID | ID[]) => void; /** Expand all non-leaf nodes */ expandAll: () => void; /** Collapse all nodes */ collapseAll: () => void; /** Convert tree to flat array with parentId references */ toFlat: () => Array<{ id: ID; parentId: ID | undefined; value: Z extends NestedTicketInput ? V : unknown; }>; /** Get the path from root to the specified item (inclusive) */ getPath: (id: ID) => ID[]; /** Get all descendants of an item */ getDescendants: (id: ID) => ID[]; /** Get all ancestors of an item (excluding self) */ getAncestors: (id: ID) => ID[]; /** Check if an item is a leaf node */ isLeaf: (id: ID) => boolean; /** Get the depth level of an item in the tree */ getDepth: (id: ID) => number; /** Check if ancestorId is an ancestor of descendantId */ isAncestorOf: (ancestorId: ID, descendantId: ID) => boolean; /** Check if id has ancestorId as an ancestor (semantic alias for isAncestorOf) */ hasAncestor: (id: ID, ancestorId: ID) => boolean; /** Get sibling IDs (including self). For roots, returns all root IDs. */ siblings: (id: ID) => ID[]; /** Get 1-indexed position among siblings (for aria-posinset). Returns 0 if not found. */ position: (id: ID) => number; /** Computed array of root items (items with no parent) */ roots: ComputedRef; /** Computed array of leaf items (items with no children) */ leaves: ComputedRef; /** Returns depth-first traversal of visible (open) nodes for keyboard navigation */ visibleItems: () => E[]; /** Whether multiple items can be selected */ readonly multiple: boolean; /** Select item(s) and all descendants, updating ancestor mixed states */ select: (ids: ID | ID[]) => void; /** Unselect item(s) and all descendants, updating ancestor mixed states */ unselect: (ids: ID | ID[]) => void; /** Toggle selection with cascading behavior */ toggle: (ids: ID | ID[]) => void; /** Register a node with optional inline children (accepts input type, returns output type) */ register: (registration?: NestedRegistration) => E; /** Batch register nodes with optional inline children */ onboard: (registrations: NestedRegistration[]) => E[]; /** Unregister a node, optionally cascading to descendants */ unregister: (id: ID, cascade?: boolean) => void; /** Drop a node's element and keep its ticket, parent link, and selection */ release: (id: ID) => void; /** Offboard multiple nodes, optionally cascading */ offboard: (ids: ID[], cascade?: boolean) => void; /** Clear all nodes and nested state (children, parents, openedIds) */ clear: () => void; } /** * Open mode for nested items. * - `'multiple'` (default): Multiple nodes can be open simultaneously * - `'single'`: Only one node can be open at a time (accordion behavior) */ type NestedOpenMode = 'single' | 'multiple'; /** * Selection mode for nested items. * - `'cascade'` (default): Selecting a parent selects all descendants; ancestors show mixed state * - `'independent'`: Each node is selected independently, no cascading * - `'leaf'`: Only leaf nodes can be selected; selecting parent selects all leaf descendants */ type NestedSelectionMode = 'cascade' | 'independent' | 'leaf'; /** * Active mode for nested items. * - `'single'` (default): Only one item can be active at a time * - `'multiple'`: Multiple items can be active simultaneously */ type NestedActiveMode = 'single' | 'multiple'; /** * Options for creating a nested instance. */ interface NestedOptions extends GroupOptions { /** * Controls how nodes expand/collapse. * - `'multiple'` (default): Multiple nodes can be open simultaneously * - `'single'`: Only one node open at a time (accordion behavior) */ open?: NestedOpenMode; /** * When true, parent nodes automatically open when children are registered. * Similar to `enroll` in selection composables but for open state. */ openAll?: boolean; /** * When true, opening a node also opens all its ancestors. * Ensures the opened node is always visible in the tree. */ reveal?: boolean; /** * Controls how selection cascades through the hierarchy. * - `'cascade'` (default): Selecting parent selects descendants; ancestors show mixed state * - `'independent'`: Each node selected independently * - `'leaf'`: Only leaf nodes selectable; parent selection selects leaf descendants */ selection?: NestedSelectionMode; /** * Controls how many items can be active/highlighted simultaneously. * - `'single'` (default): Only one item active at a time * - `'multiple'`: Multiple items can be active simultaneously */ active?: NestedActiveMode; } /** * Options for creating a nested context. */ interface NestedContextOptions extends GroupContextOptions { /** * Controls how nodes expand/collapse. * - `'multiple'` (default): Multiple nodes can be open simultaneously * - `'single'`: Only one node open at a time (accordion behavior) */ open?: NestedOpenMode; /** * When true, parent nodes automatically open when children are registered. * Similar to `enroll` in selection composables but for open state. */ openAll?: boolean; /** * When true, opening a node also opens all its ancestors. * Ensures the opened node is always visible in the tree. */ reveal?: boolean; /** * Controls how selection cascades through the hierarchy. * - `'cascade'` (default): Selecting parent selects descendants; ancestors show mixed state * - `'independent'`: Each node selected independently * - `'leaf'`: Only leaf nodes selectable; parent selection selects leaf descendants */ selection?: NestedSelectionMode; /** * Controls how many items can be active/highlighted simultaneously. * - `'single'` (default): Only one item active at a time * - `'multiple'`: Multiple items can be active simultaneously */ active?: NestedActiveMode; } //#endregion //#region src/composables/createNested/index.d.ts /** * Creates a new nested tree instance with hierarchical management. * * Extends `createGroup` to support parent-child relationships, tree traversal, * and open/close state management. Perfect for tree views, nested navigation, * and hierarchical data structures. * * @param options The options for the nested instance. * @returns A new nested instance with tree management capabilities. * * @remarks * **Key Differences from `createGroup`:** * - `register()` accepts `parentId` for establishing parent-child relationships * - `unregister()` accepts optional `cascade` parameter for cascading deletions * - Adds tree traversal methods: `getPath()`, `getAncestors()`, `getDescendants()` * - Adds computed properties: `roots`, `leaves`, `isLeaf()`, `getDepth()` * - Adds open state management: `open()`, `close()`, `flip()`, `opened()` * * @see https://0.vuetifyjs.com/composables/selection/create-nested * * @example * ```ts * import { createNested } from '@vuetify/v0' * * const tree = createNested() * * const root = tree.register({ id: 'root', value: 'Root' }) * const child1 = tree.register({ id: 'child-1', value: 'Child 1', parentId: 'root' }) * const child2 = tree.register({ id: 'child-2', value: 'Child 2', parentId: 'root' }) * * console.log(tree.getPath('child-1')) // ['root', 'child-1'] * console.log(tree.getDescendants('root')) // ['child-1', 'child-2'] * console.log(tree.isLeaf('child-2')) // true * * tree.open('root') * console.log(tree.opened('root')) // true * ``` */ declare function createNested(_options?: NestedOptions): NestedContext; /** * Creates a new nested context with provide/inject pattern. * * @param options The options for the nested context. * @returns A trinity tuple [useNested, provideNested, defaultNested] * * @see https://0.vuetifyjs.com/composables/selection/create-nested * * @example * ```ts * import { createNestedContext } from '@vuetify/v0' * * export const [useTree, provideTree, tree] = createNestedContext() * * // In parent: provideTree() * // In child: const tree = useTree() * ``` */ declare function createNestedContext(_options?: NestedContextOptions): ContextTrinity; /** * Returns the current nested instance from context. * * @param namespace The namespace for the nested context. Defaults to `'v0:nested'`. * @returns The current nested instance. * * @see https://0.vuetifyjs.com/composables/selection/create-nested */ declare function useNested(namespace?: string): NestedContext; //#endregion //#region src/composables/createNumeric/index.d.ts /** * @module createNumeric * * @see https://0.vuetifyjs.com/composables/forms/create-numeric * * @remarks * Pure numeric math primitive. No reactivity, no registry, no DOM events. * Provides clamp, snap, step, and percentage conversion for bounded numeric values. * * Used by createSlider, createNumberField, and other numeric composables. * Handles floating-point precision correction internally. * * @example * ```ts * import { createNumeric } from '@vuetify/v0' * * const numeric = createNumeric({ min: 0, max: 10, step: 1 }) * console.log(numeric.snap(3.7)) // 4 * console.log(numeric.fromValue(5)) // 50 * ``` */ interface NumericOptions { /** Minimum value. @default -Infinity */ min?: number; /** Maximum value. @default Infinity */ max?: number; /** Step increment for Arrow keys. @default 1 */ step?: number; /** Large step for PageUp/PageDown. @default step * 10 */ leap?: number; /** Circular wrapping (max+step → min). @default false */ wrap?: boolean; } interface NumericContext { min: number; max: number; step: number; leap: number; wrap: boolean; snap: (value: number) => number; fromValue: (value: number) => number; fromPercent: (percent: number) => number; up: (value: number, multiplier?: number) => number; down: (value: number, multiplier?: number) => number; floor: () => number; ceil: () => number; canUp: (value: number) => boolean; canDown: (value: number) => boolean; } declare function createNumeric(options?: NumericOptions): NumericContext; //#endregion //#region src/composables/createNumberField/index.d.ts interface NumberFieldOptions extends NumericOptions { /** Value source — defaults to ref(null). */ value?: Ref; /** BCP 47 locale tag. @default 'en-US' */ locale?: string; /** Intl.NumberFormat options. */ format?: Intl.NumberFormatOptions; /** Whether commit() clamps to min/max. @default true */ clamp?: boolean; /** * When to write typed input into `value`. `'change'` (default) only * writes on `commit()` (blur/Enter). `'input'` also writes on every * keystroke via `write()`, without clamping or snapping — clamping * mid-type would jump a value like `1` to `min` before the user finishes * typing `15`. Clamping/snapping still happens on the next `commit()`. * * @default 'change' * * @example * ```ts * const field = createNumberField({ min: 10, max: 100, commitOn: 'input' }) * field.write('1') * field.value.value // 1 — no jump to min while typing * ``` */ commitOn?: 'input' | 'change'; /** Disabled state. */ disabled?: MaybeRefOrGetter; /** Readonly state. */ readonly?: MaybeRefOrGetter; /** Unique identifier. */ id?: InputOptions['id']; /** Display label. */ label?: string; /** Form field name. */ name?: string; /** * Form injection key. Must match the parent Form's `namespace`. * * @default 'v0:form' */ formNamespace?: string; /** * Whether required. When true, a presence rule is registered so Form * submit fails on empty values even with `novalidate`. */ required?: boolean; /** Validation rules. */ rules?: InputOptions['rules']; /** Manual error state override — forces invalid. */ error?: InputOptions['error']; /** Manual error messages — merged with rule-based errors. */ errorMessages?: InputOptions['errorMessages']; } interface NumberFieldContext { /** The numeric value (null when empty). */ value: Ref; /** Formatted display string (empty for null). */ display: Readonly>; /** Whether the value can be incremented. */ canIncrement: Readonly>; /** Whether the value can be decremented. */ canDecrement: Readonly>; /** The underlying numeric context. */ numeric: NumericContext; /** The underlying input context. */ input: InputContext; /** Increment value by step * multiplier. */ increment: (multiplier?: number) => void; /** Decrement value by step * multiplier. */ decrement: (multiplier?: number) => void; /** Set value to min. */ floor: () => void; /** Set value to max. */ ceil: () => void; /** Format a number using Intl.NumberFormat. */ formatValue: (value: number) => string; /** Parse locale-formatted text to a number or null. */ parse: (text: string) => number | null; /** Snap and optionally clamp the current value. Pass `next` to avoid reading the stale model on the same tick as a write. */ commit: (next?: number | null) => void; /** When typed input is written into `value` — see {@link NumberFieldOptions.commitOn}. */ readonly commitOn: 'input' | 'change'; /** * Parse `text` and write it straight into `value`, without clamping or * snapping. Used by `commitOn: 'input'` consumers to get per-keystroke * updates without the min/max jump `commit()` would cause mid-type. * * @example * ```ts * const field = createNumberField({ min: 10, max: 100 }) * field.write('1') * field.value.value // 1 — clamped only on the next commit() * ``` */ write: (text: string) => void; } declare function createNumberField(options?: NumberFieldOptions): NumberFieldContext; //#endregion //#region src/composables/createOtp/index.d.ts /** * Pattern presets — string literals compile to internal RegExps; arbitrary * RegExp values are applied per character. * * @example * ```ts * const otp = createOtp({ pattern: 'numeric' }) * const hex = createOtp({ pattern: /^[0-9a-fA-F]$/ }) * ``` */ type OtpPattern = 'numeric' | 'alphanumeric' | 'alphabetic' | RegExp; type OtpItemState = 'filled' | 'empty'; /** * Per-character descriptor for iterating boxes from `length`. * * @example * ```ts * const otp = createOtp({ length: 4 }) * otp.items.value[0] // { index: 0, value: '', state: 'empty' } * otp.write(0, '4') * otp.items.value[0] // { index: 0, value: '4', state: 'filled' } * ``` */ interface OtpItemDescriptor { /** 0-based position */ index: number; /** Character at this index, or '' when empty */ value: string; /** Fill state */ state: OtpItemState; } /** * Options accepted by `createOtp`. * * @example * ```ts * const otp = createOtp({ * length: 6, * pattern: 'numeric', * disabled: false, * onComplete: async value => { * const ok = await verify(value) * return ok * }, * }) * ``` */ interface OtpOptions extends Omit, 'value' | 'error' | 'errorMessages'> { /** Number of characters. @default 6 */ length?: MaybeRefOrGetter; /** Joined value source. @default shallowRef('') */ value?: Ref; /** * Per-character pattern. String presets compile to internal RegExps; * custom RegExp must match a single character. * @default 'numeric' */ pattern?: MaybeRefOrGetter; /** * Fire when the joined value becomes a new complete string. Decisional — * return / resolve `false` to reject (clears value, sets error). * A rejected Promise is treated as `false` and logs a warning. * The same complete string is deduped until the value goes incomplete. */ onComplete?: (value: string) => boolean | void | PromiseLike; } /** * Reactive context returned by `createOtp`. Consumers index into `value` * for per-character rendering and call the mutation helpers to drive state. * * @example * ```ts * const otp = createOtp({ length: 6 }) * * otp.write(0, '4') * otp.distribute('12345', 1) // returns 5 * otp.isComplete.value // true * otp.clear() * ``` */ interface OtpContext { /** * The joined OTP string. Use the mutation helpers (`write`, `distribute`, * `fill`, `clear`) to update. Writing through this ref directly is * intentionally prevented to preserve pattern, length, and lock invariants. */ value: Readonly>; /** Resolved character count from the `length` option. */ length: Readonly>; /** * One descriptor per box, derived from `length` and `value`. * Iterate this instead of `v-for="i in length"`. */ items: ComputedRef; /** * The underlying `createInput` context — exposes ARIA IDs, validation * state, focus/touched, and the `validate` / `reset` methods. * * Note: `input.value` aliases `OtpContext.value` and is also readonly on * the public surface. Use the mutation helpers (`write`, `distribute`, * `fill`, `clear`) to update. */ input: Omit, 'value'> & { value: Readonly>; }; /** True when `value` reaches `length` and every character matches `pattern`. */ isComplete: Readonly>; /** * True while an async `onComplete` is in flight. Mutation helpers no-op * during this window; consumers can render a spinner against this ref. */ isValidating: Readonly>; /** * Write a single character at `index`. Empty string clears trailing * characters from `index` onward. Out-of-range indices and characters * rejected by `pattern` are ignored. No-ops while locked. */ write: (index: number, char: string) => void; /** * Splice pattern-accepted characters from `text` into `value` starting * at `index`. Returns the number of characters written. No-ops while * locked or when no characters pass the pattern. */ distribute: (text: string, index?: number) => number; /** Clear `value` and rejection state. No-ops while locked. */ clear: () => void; /** * Replace `value` with pattern-accepted characters from `text`, truncated * to `length`. Clears rejection state on deliberate empty input or any * accepted characters. No-ops while locked. */ fill: (text: string) => void; /** Whether `char` is a single character matching the current `pattern`. */ accepts: (char: string) => boolean; } declare function createOtp(_options?: OtpOptions): OtpContext; //#endregion //#region src/composables/createProgress/index.d.ts type ProgressTicketInput = ModelTicketInput>; type ProgressTicket = ModelTicket; interface ProgressOptions { value?: number; min?: number; max?: number; } interface ProgressContext extends ModelContext { readonly min: number; readonly max: number; segments: ComputedRef; total: Readonly>; percent: Readonly>; isIndeterminate: Readonly>; fromValue: (value: number) => number; } interface ProgressContextOptions extends ProgressOptions { namespace?: string; } /** * Creates a progress instance with model-based segment tracking. * * @param options The options for the progress instance. * @returns A progress context with segment registration. * * @example * ```ts * import { createProgress } from '@vuetify/v0' * * const progress = createProgress({ max: 100 }) * const segment = progress.register({ value: 50 }) * progress.percent.value // 50 * ``` */ declare function createProgress(options?: ProgressOptions): ProgressContext; /** * Creates a progress context for dependency injection. * * @param options The options including namespace. * @returns A trinity: [useProgress, provideProgress, defaultContext] */ declare function createProgressContext(_options?: ProgressContextOptions): ContextTrinity; /** * Returns the current progress instance from context. * * @param namespace The namespace. @default 'v0:progress' * @returns The progress context. */ declare function useProgress(namespace?: string): ProgressContext; //#endregion //#region src/composables/createQueue/index.d.ts /** * Input type for queue tickets - what users provide to register(). * Extend this interface to add custom properties. * * @template V The type of the ticket value. */ interface QueueTicketInput extends RegistryTicketInput { /** * Timeout in milliseconds * * @remarks * - If `undefined`: Uses the default timeout from queue options (default: 3000ms) * - If `-1`: Ticket persists indefinitely until manually dismissed * - If a number: Ticket will be automatically removed after the specified milliseconds */ timeout?: number; } /** * Output type for queue tickets - what users receive from get(). * Includes all input properties plus queue state and methods. * * @template Z The input ticket type that extends QueueTicketInput. */ type QueueTicket = RegistryTicket & Z & { /** * Timeout in milliseconds (resolved from input or default) */ timeout?: number; /** * Whether the timeout is currently paused * * @remarks * - Set to `true` when the ticket is not the first in the queue or when manually paused * - When `true`, the timeout does not progress * - Automatically managed by the queue system */ isPaused: boolean; /** * Convenience method to dismiss this ticket from the queue * * @remarks * Equivalent to calling `queue.unregister(ticket.id)` */ dismiss: () => void; }; /** * Context for managing queue collections with timeout support. * * @template Z The input ticket type. * @template E The output ticket type. */ interface QueueContext = QueueTicket> extends Omit, 'register' | 'unregister' | 'offboard'> { /** * Register a new ticket in the queue (accepts input type, returns output type) * * @param ticket The partial ticket data to register * @remarks * - If no ID is provided, a unique ID will be generated automatically * - If no timeout is provided, uses the default timeout from queue options (3000ms) * - First ticket in queue starts its timeout immediately * - Subsequent tickets are paused until they become first in queue * - Each ticket receives a `dismiss()` method for convenience * * @see https://0.vuetifyjs.com/composables/registration/create-queue * * @example * ```ts * import { useQueue } from '@vuetify/v0' * * const queue = useQueue() * * // Register with default timeout (3000ms) * const ticket1 = queue.register({ value: 'First' }) * * // Register with custom timeout * const ticket2 = queue.register({ value: 'Second', timeout: 5000 }) * * // Register persistent ticket (must be manually dismissed) * const ticket3 = queue.register({ value: 'Persistent', timeout: -1 }) * ``` */ register: (ticket?: Partial) => E; /** * Unregister a ticket from the queue * * @param id The ID of the ticket to unregister. If not provided, the first ticket in the queue will be unregistered. * @remarks * - Removes the ticket from the queue and clears its timeout * - If the removed ticket was first in queue, automatically resumes the next ticket * - Returns the unregistered ticket or `undefined` if not found * * @see https://0.vuetifyjs.com/composables/registration/create-queue * * @example * ```ts * import { useQueue } from '@vuetify/v0' * * const queue = useQueue() * * const ticket1 = queue.register({ value: 'First' }) * const ticket2 = queue.register({ value: 'Second' }) * * // Unregister specific ticket * queue.unregister(ticket2.id) * * // Unregister first ticket in queue * const removed = queue.unregister() * console.log(removed?.value) // 'First' * ``` */ unregister: (id?: ID) => E | undefined; /** * Pause the timeout of the first ticket in the queue * * @remarks * - Pauses the timeout for the first ticket if it exists and is not already paused * - Returns the paused ticket or `undefined` if no pausable ticket exists * - The timeout will not progress while paused * * @see https://0.vuetifyjs.com/composables/registration/create-queue * * @example * ```ts * import { useQueue } from '@vuetify/v0' * * const queue = useQueue({ timeout: 5000 }) * * const ticket = queue.register({ value: 'Pausable ticket' }) * * // Pause the first ticket's timeout * const paused = queue.pause() * * console.log(paused?.isPaused) // true * ``` */ pause: () => E | undefined; /** * Resume the timeout of the first paused ticket in the queue * * @remarks * - Resumes the timeout for the first ticket if it exists, is at index 0, and is currently paused * - Returns the resumed ticket or `undefined` if no resumable ticket exists * - The timeout will continue from its full duration (not from where it was paused) * * @see https://0.vuetifyjs.com/composables/registration/create-queue * * @example * ```ts * import { useQueue } from '@vuetify/v0' * * const queue = useQueue({ timeout: 5000 }) * * const ticket = queue.register({ value: 'Ticket' }) * queue.pause() * * // Later, resume the paused ticket * const resumed = queue.resume() * * console.log(resumed?.isPaused) // false * ``` */ resume: () => E | undefined; /** * Clear the entire queue * * @remarks * - Removes all tickets from the queue * - Clears all active timeouts * - Resets the queue to an empty state * * @see https://0.vuetifyjs.com/composables/registration/create-queue * * @example * ```ts * import { useQueue } from '@vuetify/v0' * * const queue = useQueue() * * queue.register({ value: 'First' }) * queue.register({ value: 'Second' }) * * console.log(queue.size) // 2 * * queue.clear() * * console.log(queue.size) // 0 * ``` */ clear: () => void; /** * Dispose of the queue and clean up resources * * @remarks * - Clears all tickets and timeouts * - Removes all event listeners * - Should be called when the queue is no longer needed * - Automatically called on scope disposal * * @see https://0.vuetifyjs.com/composables/registration/create-queue * * @example * ```ts * import { onScopeDispose } from 'vue' * import { useQueue } from '@vuetify/v0' * * const queue = useQueue() * * queue.register({ value: 'Ticket' }) * * onScopeDispose(() => { * queue.dispose() * }) * ``` */ dispose: () => void; /** * Batch unregister tickets from the queue */ offboard: (ids: ID[]) => void; } interface QueueOptions extends RegistryOptions { /** * Default timeout in milliseconds for tickets without explicit timeout * * @default 3000 * @remarks * - Applied to tickets that don't specify their own timeout * - Can be overridden per ticket during registration */ timeout?: number; } interface QueueContextOptions extends QueueOptions { namespace?: string; } /** * Creates a new queue instance * * @param options The options for the queue instance * @returns A new queue instance * * @see https://0.vuetifyjs.com/composables/registration/create-queue * * @example * ```ts * import { createQueue } from '@vuetify/v0' * * const queue = createQueue() * * // Register an ticket with default timeout (3000ms) * const ticket1 = queue.register({ value: 'Ticket 1' }) * * // Register an ticket with custom timeout * const ticket2 = queue.register({ value: 'Ticket 2', timeout: 5000 }) * * // Register a persistent ticket that must be manually dismissed * const ticket3 = queue.register({ value: 'Ticket 3', timeout: -1 }) * * // Dismiss an ticket using the convenience method * ticket3.dismiss() * * console.log(queue.size) // 2 * ``` */ declare function createQueue(_options?: QueueOptions): QueueContext; /** * Creates a new queue context. * * @param options The options for the queue context. * @returns A new queue context. * * @see https://0.vuetifyjs.com/composables/registration/create-queue * * @example * ```ts * import { createQueueContext } from '@vuetify/v0' * * export const [useQueue, provideQueue, context] = createQueueContext({ * timeout: 5000, * }) * ``` */ declare function createQueueContext(_options?: QueueContextOptions): ContextTrinity; /** * Returns the current queue instance. * * @param namespace The namespace for the queue context. Defaults to `'v0:queue'`. * @returns The current queue instance. * * @see https://0.vuetifyjs.com/composables/registration/create-queue * * @example * ```vue * * ``` */ declare function useQueue(namespace?: string): QueueContext; //#endregion //#region src/composables/createRating/index.d.ts type RatingItemState = 'full' | 'half' | 'empty'; interface RatingItemDescriptor { /** 1-based position */ value: number; /** Derived visual state */ state: RatingItemState; } interface RatingContext { /** Current rating, clamped to 0–size */ value: WritableComputedRef; /** Total items */ size: number; /** Whether half-steps are enabled */ half: boolean; /** Array of items with computed state */ items: ComputedRef; /** Whether value is at minimum (0) */ isFirst: Readonly>; /** Whether value is at maximum (size) */ isLast: Readonly>; /** Set rating to specific value */ select: (value: number) => void; /** Increment by step (1 or 0.5) */ next: () => void; /** Decrement by step (1 or 0.5) */ prev: () => void; /** Set to 0 */ first: () => void; /** Set to size */ last: () => void; } interface RatingOptions { /** Initial value or ref for v-model. @default 0 */ value?: number | ShallowRef; /** Total items. @default 5 */ size?: MaybeRefOrGetter; /** Enable 0.5 step increments. @default false */ half?: MaybeRefOrGetter; } interface RatingContextOptions extends RatingOptions { /** Namespace for dependency injection */ namespace?: string; } /** * Creates a rating instance. * * @param options The options for the rating instance. * @returns A rating context with navigation methods. * * @example * ```ts * import { createRating } from '@vuetify/v0' * * // Basic usage * const rating = createRating() * rating.select(3) * rating.items.value // [{ value: 1, state: 'full' }, ...] * * // With v-model (pass a ref) * const value = shallowRef(0) * const rating = createRating({ value }) * ``` */ declare function createRating(_options?: RatingOptions): R; /** * Creates a rating context for dependency injection. * * @param options The options including namespace. * @returns A trinity: [useRating, provideRating, defaultContext] * * @example * ```ts * const [useRating, provideRatingContext] = createRatingContext({ size: 5 }) * * // Parent component * provideRatingContext() * * // Child component * const rating = useRating() * rating.select(4) * ``` */ declare function createRatingContext(_options?: RatingContextOptions): ContextTrinity; /** * Returns the current rating instance from context. * * @param namespace The namespace. @default 'v0:rating' * @returns The rating context. * * @example * ```vue * * * * ``` */ declare function useRating(namespace?: string): R; //#endregion //#region src/composables/createSlider/index.d.ts interface SliderTicketInput extends ModelTicketInput> { value: ShallowRef; } type SliderTicket = ModelTicket; /** * Configuration options for createSlider. * * @see https://0.vuetifyjs.com/composables/forms/create-slider */ interface SliderOptions { /** * Minimum value. * @default 0 */ min?: number; /** * Maximum value. * @default 100 */ max?: number; /** * Step increment. Values are snapped to the nearest multiple of `step` above `min`. * * @remarks Use decimal steps for fine-grained control (e.g., `0.1` for a media scrubber). * A step of `0` disables snapping — values are only clamped to min/max. * * @default 1 */ step?: number; /** * Whether the slider is disabled. * * @remarks Accepts a reactive getter or ref. When disabled, all thumb operations (`set`, `up`, `down`) are no-ops. */ disabled?: MaybeRefOrGetter; /** * Whether the slider is readonly (focusable but not editable). * * @remarks Thumbs can receive focus for accessibility, but `set`, `up`, `down`, `floor`, and `ceil` are no-ops. */ readonly?: MaybeRefOrGetter; /** * Slider orientation. * * @remarks Affects `fromValue` and `fromPercent` axis mapping in Slider components. * When using createSlider standalone, orientation is informational only. */ orientation?: MaybeRefOrGetter<'horizontal' | 'vertical'>; /** * Flip the percent axis. * * @remarks When `true`, `fromValue(min)` returns `100` and `fromValue(max)` returns `0`. * Useful for vertical sliders where the visual bottom is the minimum. */ inverted?: MaybeRefOrGetter; /** * Minimum steps required between adjacent thumbs. * * @remarks Enforced by `set` and `apply`. The gap in value units is `minStepsBetweenThumbs * step`. * * @default 0 * * @example * ```ts * const slider = createSlider({ step: 5, minStepsBetweenThumbs: 2 }) * // Thumbs must be at least 10 units apart (2 × 5) * ``` */ minStepsBetweenThumbs?: number; /** * Allow thumbs to pass through each other. * * @remarks When `false` (default), `set` constrains values so thumbs maintain their order. * When `true`, thumbs can freely overlap and swap positions. * * @default false */ crossover?: boolean; /** * Range mode — expects two thumbs. * * @remarks Informational flag used by Slider components to adjust track/range rendering. * Does not enforce the number of registered thumbs. * * @default false */ range?: boolean; } /** * Context returned by {@link createSlider}. * * @remarks * Extends `createModel` with slider-specific math and thumb operations. * * **Inheritance chain:** * `createRegistry` → `createModel` → `createSlider` * * **Ticket-per-thumb model:** * Each thumb is a model ticket whose value is a `shallowRef`. * `values` is derived from the ordered tickets, not a standalone ref. * Register/unregister thumbs to add/remove values dynamically. * * @see https://0.vuetifyjs.com/composables/forms/create-slider * @see {@link createModel} for the base model API (collection, selectedIds, etc.) */ interface SliderContext extends Omit, 'values' | 'selectedValues' | 'apply' | 'disabled' | 'register'> { /** * Ordered thumb values derived from model tickets. * * @remarks Reactive — updates when any thumb's `shallowRef` changes. * Order matches ticket registration order (sorted by index). * * @example * ```ts * const slider = createSlider() * slider.register({ value: 25 }) * slider.register({ value: 75 }) * console.log(slider.values.value) // [25, 75] * ``` */ values: ComputedRef; /** * Alias for `values` — provides useProxyModel compatibility. * * @remarks Returns an array (not a Set) to preserve duplicate values across thumbs. * * @see {@link values} */ selectedValues: ComputedRef; /** * Apply external values — snaps, constrains, and writes to ticket refs. * * @param values Array of raw values (coerced to numbers). * @param options Options object (reserved for useProxyModel compatibility). * * @remarks * If no thumbs are registered yet, values are stored as pending and * consumed as thumbs register. Each value is snapped to step and * constrained by `minStepsBetweenThumbs`. * * @example * ```ts * const slider = createSlider({ step: 10 }) * slider.register({ value: 0 }) * slider.register({ value: 0 }) * slider.apply([33, 67]) // values: [30, 70] * ``` */ apply: (values: unknown[], options?: { multiple?: boolean; }) => void; /** Whether disabled. Reactive ref derived from the `disabled` option. */ disabled: Readonly>; /** Whether readonly. Reactive ref derived from the `readonly` option. */ readonly: Readonly>; /** Slider orientation. Reactive ref derived from the `orientation` option. */ orientation: Readonly>; /** Whether inverted. Reactive ref derived from the `inverted` option. */ inverted: Readonly>; /** Minimum value. */ min: number; /** Maximum value. */ max: number; /** Step increment. */ step: number; /** Minimum steps required between adjacent thumbs. */ minStepsBetweenThumbs: number; /** Whether thumbs can cross each other. */ crossover: boolean; /** Whether this is a range slider. */ range: boolean; /** * Register a new thumb and return its ticket. * * @param input Starting value as a number or `{ value }` object. Defaults to `min`. * * @remarks * The thumb is automatically selected in the model (all thumbs stay selected). * If `apply` was called before any thumbs registered, the pending value at this * thumb's index is used instead of the provided value. * * @see {@link unregister} * * @example * ```ts * const slider = createSlider({ min: 0, max: 100 }) * const thumb = slider.register({ value: 50 }) * console.log(thumb.index) // 0 * console.log(slider.values.value) // [50] * ``` */ register: (input?: number | { value: number; }) => SliderTicket; /** * Unregister a thumb by ticket ID. * * @param id The ticket ID returned from `register()`. * * @see {@link register} * * @example * ```ts * const slider = createSlider() * const thumb = slider.register({ value: 50 }) * slider.unregister(thumb.id) // values: [] * ``` */ unregister: (id: ID) => void; /** * Round a value to the nearest step, clamped to min/max. * * @param value Raw value to snap. * @returns Snapped value. * * @remarks Pure function — does not modify slider state. * When `step` is `0`, only clamps without snapping. * * @example * ```ts * const slider = createSlider({ min: 0, max: 100, step: 5 }) * slider.snap(47) // 45 * slider.snap(48) // 50 * slider.snap(-5) // 0 (clamped) * ``` */ snap: (value: number) => number; /** * Convert a value to a 0–100 percentage. * * @param value The slider value to convert. * @returns Percentage between 0 and 100. * * @remarks Pure function. Respects `inverted` — when inverted, * `fromValue(min)` returns `100` and `fromValue(max)` returns `0`. * * @see {@link fromPercent} for the inverse operation. * * @example * ```ts * const slider = createSlider({ min: 0, max: 200 }) * slider.fromValue(100) // 50 * slider.fromValue(0) // 0 * slider.fromValue(200) // 100 * ``` */ fromValue: (value: number) => number; /** * Convert a 0–100 percentage to a snapped value. * * @param percent Percentage between 0 and 100. * @returns Snapped slider value. * * @remarks Pure function. Respects `inverted`. The returned value * is snapped to the nearest step and clamped to min/max. * * @see {@link fromValue} for the inverse operation. * * @example * ```ts * const slider = createSlider({ min: 0, max: 100, step: 10 }) * slider.fromPercent(33) // 30 * slider.fromPercent(50) // 50 * ``` */ fromPercent: (percent: number) => number; /** * Set the value at a thumb index with step snapping and neighbor constraints. * * @param index Zero-based thumb index. * @param value Raw value to set. * * @remarks * No-op when `disabled` or `readonly` is `true`. The value is snapped to step, clamped to min/max, * and constrained by adjacent thumbs when `crossover` is `false`. * * @see {@link up} and {@link down} for relative adjustments. * * @example * ```ts * const slider = createSlider({ min: 0, max: 100, step: 5 }) * slider.register({ value: 50 }) * slider.set(0, 73) // values: [75] (snapped) * ``` */ set: (index: number, value: number) => void; /** * Increment a thumb's value by `step × multiplier`. * * @param index Zero-based thumb index. * @param multiplier Number of steps to increment. Defaults to `1`. * * @see {@link down} for the inverse. {@link set} for absolute positioning. * * @example * ```ts * const slider = createSlider({ min: 0, max: 100, step: 5 }) * slider.register({ value: 50 }) * slider.up(0) // values: [55] * slider.up(0, 3) // values: [70] * ``` */ up: (index: number, multiplier?: number) => void; /** * Decrement a thumb's value by `step × multiplier`. * * @param index Zero-based thumb index. * @param multiplier Number of steps to decrement. Defaults to `1`. * * @see {@link up} for the inverse. {@link set} for absolute positioning. * * @example * ```ts * const slider = createSlider({ min: 0, max: 100, step: 5 }) * slider.register({ value: 50 }) * slider.down(0) // values: [45] * slider.down(0, 3) // values: [30] * ``` */ down: (index: number, multiplier?: number) => void; /** * Set a thumb to the minimum value. * * @param index Zero-based thumb index. * * @see {@link ceil} for the inverse. * * @example * ```ts * const slider = createSlider({ min: 10, max: 90 }) * slider.register({ value: 50 }) * slider.floor(0) // values: [10] * ``` */ floor: (index: number) => void; /** * Set a thumb to the maximum value. * * @param index Zero-based thumb index. * * @see {@link floor} for the inverse. * * @example * ```ts * const slider = createSlider({ min: 10, max: 90 }) * slider.register({ value: 50 }) * slider.ceil(0) // values: [90] * ``` */ ceil: (index: number) => void; } /** * Creates slider state with value math, step snapping, and multi-thumb support. * * Extends createModel for useProxyModel compatibility. Each thumb is a model * ticket with a shallowRef value. Values are derived from the ordered * tickets, enabling proper registration/unregistration lifecycle. * * @param options Slider configuration. * @returns Slider context with values, math functions, and thumb operations. * * @see https://0.vuetifyjs.com/composables/forms/create-slider * @see {@link createModel} for the base model composable. * * @example Single thumb * ```ts * import { createSlider } from '@vuetify/v0' * * const slider = createSlider({ min: 0, max: 100, step: 5 }) * const ticket = slider.register({ value: 50 }) * slider.up(0) // values: [55] * slider.fromValue(50) // 50 * ``` * * @example Range slider * ```ts * import { createSlider } from '@vuetify/v0' * * const slider = createSlider({ min: 0, max: 100, step: 1, range: true }) * slider.register({ value: 25 }) * slider.register({ value: 75 }) * slider.set(0, 30) // values: [30, 75] * slider.set(1, 60) // values: [30, 60] * ``` * * @example Custom pointer interaction (media scrubber) * ```ts * import { createSlider } from '@vuetify/v0' * * const slider = createSlider({ min: 0, max: 217, step: 0.1 }) * slider.register({ value: 0 }) * * // pointer → fromPercent → set → fromValue → UI * const percent = (clientX - rect.left) / rect.width * 100 * slider.set(0, slider.fromPercent(percent)) * const position = slider.fromValue(slider.values.value[0]) * ``` */ declare function createSlider(options?: SliderOptions): SliderContext; //#endregion //#region src/composables/createTimeline/index.d.ts interface TimelineContext extends RegistryContext { /** * Removes the last registered ticket and stores it for redo * * @returns The removed ticket, or undefined if there are no tickets to undo. * * @see https://0.vuetifyjs.com/composables/registration/create-timeline * * @example * ```ts * import { useTimeline } from '@vuetify/v0' * * const timeline = useTimeline() * * timeline.register({ id: 'one' }) * timeline.register({ id: 'two' }) * * console.log(timeline.values()) // [{ id: 'one' }, { id: 'two' }] * * timeline.undo() * console.log(timeline.values()) // [{ id: 'one' }] * ``` */ undo: () => Z | undefined; /** * Restores the last undone ticket * * @returns The restored ticket, or undefined if there are no tickets to redo. * * @see https://0.vuetifyjs.com/composables/registration/create-timeline * * @example * ```ts * import { useTimeline } from '@vuetify/v0' * * const timeline = useTimeline() * * timeline.register({ id: 'one' }) * timeline.register({ id: 'two' }) * * console.log(timeline.values()) // [{ id: 'one' }, { id: 'two' }] * * timeline.undo() * console.log(timeline.values()) // [{ id: 'one' }] * * timeline.redo() * console.log(timeline.values()) // [{ id: 'one' }, { id: 'two' }] * ``` */ redo: () => Z | undefined; } interface TimelineTicket extends RegistryTicket {} interface TimelineOptions extends RegistryOptions { /** * The maximum size of the timeline. * * @default 10 */ size?: number; } interface TimelineContextOptions extends TimelineOptions { namespace?: string; } /** * Creates a new timeline instance. * * @param options The options for the timeline instance. * @template Z The type of the timeline ticket. * @template E The type of the timeline context. * @returns A new timeline instance. * * @see https://0.vuetifyjs.com/composables/registration/create-timeline * * @example * ```ts * import { useTimeline } from '@vuetify/v0' * * const timeline = useTimeline({ size: 3 }) * * timeline.onboard([{ id: 'one' }, { id: 'two' }, { id: 'three' }]) * * console.log(timeline.values()) // [{ id: 'one' }, { id: 'two' }, { id: 'three' }] * * timeline.undo() * console.log(timeline.values()) // [{ id: 'one' }, { id: 'two' }] * * timeline.redo() * console.log(timeline.values()) // [{ id: 'one' }, { id: 'two' }, { id: 'three' }] * ``` */ declare function createTimeline = TimelineContext>(_options?: TimelineOptions): E; /** * Creates a new timeline context. * * @param options The options for the timeline context. * @template Z The type of the timeline ticket. * @template E The type of the timeline context. * @returns A new timeline context. * * @see https://0.vuetifyjs.com/composables/registration/create-timeline * * @example * ```ts * import { createTimelineContext } from '@vuetify/v0' * * // With default namespace 'v0:timeline' * export const [useTimeline, provideTimeline, context] = createTimelineContext({ size: 5 }) * * context.register({ id: 'example' }) * * // In a parent component * provideTimeline() * * // In a child component * const timeline = useTimeline() * * console.log(timeline.values()) // [{ id: 'example' }] * ``` */ declare function createTimelineContext = TimelineContext>(_options?: TimelineContextOptions): ContextTrinity; /** * Returns the current timeline instance. * * @param namespace The namespace for the timeline context. Defaults to `'v0:timeline'`. * @returns The current timeline instance. * * @see https://0.vuetifyjs.com/composables/registration/create-timeline * * @example * ```vue * * ``` */ declare function useTimeline = TimelineContext>(namespace?: string): E; //#endregion //#region src/composables/createTimePicker/index.d.ts type TimeHourCycle = 'h12' | 'h23'; type TimePeriod = 'am' | 'pm'; /** One segment of the time value. */ type TimePart = 'hour' | 'minute' | 'second' | 'period'; /** A segment that holds a number: every part but the period. */ type TimeUnit = Exclude; /** * The lowest and highest grid values of a numeric field, in display terms, * and its step. * * @example * ```ts * import { createTimePicker } from '@vuetify/v0' * * const time = createTimePicker({ minuteStep: 15 }) * * time.grid('minute') // { min: 0, max: 45, step: 15 } * ``` */ interface TimeGrid { /** Lowest grid value. */ min: number; /** Highest grid value. */ max: number; /** Resolved step: a whole number, at least `1`. */ step: number; } /** * @example * ```ts * import { createTimePicker } from '@vuetify/v0' * * const time = createTimePicker({ * hourCycle: 'h23', * seconds: false, * minuteStep: 15, * min: '09:00', * max: '17:00', * required: true, * rules: [value => value !== '12:00' || 'Closed at noon'], * }) * ``` */ interface TimePickerOptions extends Omit, 'value' | 'dirty' | 'equals'> { /** * Canonical `HH:mm` or `HH:mm:ss` source. The picker snaps an incoming * value to the step grid, moves it to the nearest on-grid time inside * `min` / `max` when it falls outside them, and writes it back in * canonical form. With `seconds` on, `HH:mm` reads as second `0`; with * it off, `HH:mm:ss` drops the seconds. An unparseable value empties the * fields and becomes `null`. That pass runs before the next flush, * together with any option that changed in the same tick; until then the * fields show the value as written. * * The model has the last word. When, after its owner has had a tick to * answer, it does not hold the value the picker wrote, the fields take * the model's value as given and the picker writes nothing further. The * picker treats an owner that answers later than that the same way until * its value arrives. * * @default shallowRef(null) */ value?: Ref; /** * `h12` shows 1–12 and a meridiem. `h23` shows 0–23. * The picker reads any other value as `h23`. * * @default 'h23' */ hourCycle?: MaybeRefOrGetter; /** * Include seconds in the canonical value. Turning it on for a picker whose * hour and minute have values keeps the time and sets the second to `0`. * Turning it off drops the second. * * @default false */ seconds?: MaybeRefOrGetter; /** * Hour interval. The hour moves on the multiples of the step inside * `0`–`23`; in `h12`, on those inside the current meridiem's half of the * day. Fractions truncate, and the picker reads a non-finite or * non-positive step as `1`. A half with no multiple of the step holds its * first hour only. * * @default 1 */ hourStep?: MaybeRefOrGetter; /** * Minute interval. The minute moves on the multiples of the step inside * `0`–`59`. Fractions truncate, and the picker reads a non-finite or * non-positive step as `1`. A step above `59` leaves `0` as the only * minute. * * @default 1 */ minuteStep?: MaybeRefOrGetter; /** * Second interval. Same rules as `minuteStep`. * * @default 1 */ secondStep?: MaybeRefOrGetter; /** * Inclusive lower bound, `HH:mm` or `HH:mm:ss`. Applies to a complete * value only. A value below it moves to the earliest time at or after * `min` that is on every field's step grid; with `minuteStep: 15`, * `min: '10:07'` starts the range at `10:15`. Only when no on-grid time * lies between `min` and `max` does the picker set the grid aside and * clamp the value to the bound itself. The picker ignores the bound's * seconds while `seconds` is off, so `min: '09:00:30'` then admits * `09:00`. The picker ignores an unparseable `min` and keeps `max`; a * `min` above `max`, by the same comparison, turns both bounds off. */ min?: MaybeRefOrGetter; /** * Inclusive upper bound, `HH:mm` or `HH:mm:ss`. Applies to a complete * value only. A value above it moves to the latest time at or before * `max` that is on every field's step grid; with `minuteStep: 15`, * `max: '17:10'` ends the range at `17:00`. Only when no on-grid time * lies between `min` and `max` does the picker set the grid aside and * clamp the value to the bound itself. The picker ignores the bound's * seconds while `seconds` is off, so `max: '17:00:30'` then stops at * `17:00`. The picker ignores an unparseable `max` and keeps `min`; a * `max` below `min`, by the same comparison, turns both bounds off. */ max?: MaybeRefOrGetter; /** * While true, `commit`, `step`, `clear`, and `input.reset` do not write * `value`, and neither does the picker, so the model stays untouched. * `commit`, `step`, and `clear` do nothing at all. The fields show * the incoming hour and minute as given, unsnapped and unclamped, and * its seconds only while `seconds` is on. Turning it off normalizes the * value. * * @default false */ disabled?: MaybeRefOrGetter; /** * While true, `commit`, `step`, `clear`, and `input.reset` do not write * `value`, and neither does the picker, so the model stays untouched. * `commit`, `step`, and `clear` do nothing at all. The fields show * the incoming hour and minute as given, unsnapped and unclamped, and * its seconds only while `seconds` is on. Turning it off normalizes the * value. * * @default false */ readonly?: MaybeRefOrGetter; } interface TimePickerContext { /** * Canonical 24-hour value, or `null` while a field is still empty. * Writing it from outside replaces every field at once; the picker * normalizes it before the next flush. The picker writes it only when * an edit changes the time, and never while disabled or readonly. * * @example * ```ts * import { nextTick } from 'vue' * import { createTimePicker } from '@vuetify/v0' * * const time = createTimePicker({ seconds: true }) * * time.value.value = '09:30' * time.hour.value // 9 * await nextTick() * time.value.value // '09:30:00' * ``` */ readonly value: Ref; /** * Field hour. `0`–`23` in `h23`, `1`–`12` in `h12`. `null` when unset. * * @example * ```ts * import { createTimePicker } from '@vuetify/v0' * * const time = createTimePicker({ hourCycle: 'h12' }) * * time.commit('hour', 3) * time.hour.value // 3 * ``` */ readonly hour: Readonly>; /** Minute field, `0`–`59`, or `null` when unset. */ readonly minute: Readonly>; /** Second field, or `null` when seconds are off or unset. */ readonly second: Readonly>; /** * Meridiem. `null` in `h23`. In `h12` with an empty hour, the meridiem * the picker remembers: the last one you set with `commit` or `step`, * the one the hour had when you cleared it, or the one of the last * incoming value. `clear()` and an incoming `null`, `''`, or * unparseable value reset it to `'am'`. * * @example * ```ts * import { createTimePicker } from '@vuetify/v0' * * const time = createTimePicker({ hourCycle: 'h12' }) * * time.commit('hour', 3) * time.commit('minute', 0) * time.commit('period', 'pm') * time.period.value // 'pm' * time.value.value // '15:00' * ``` */ readonly period: Readonly>; /** Resolved hour cycle. */ readonly hourCycle: Readonly>; /** Whether the canonical value includes seconds. */ readonly seconds: Readonly>; /** Resolved disabled flag. */ readonly isDisabled: Readonly>; /** Resolved readonly flag. */ readonly isReadonly: Readonly>; /** * Set one field. `null` clears a numeric field and the value becomes * `null`. The picker holds a number inside the field's range and snaps * it to the nearest grid point without wrapping. In `h12` it reads the * hour as a display hour in the current meridiem. A period commit moves * a set hour to the other half of the day, and the picker remembers it * while the hour is empty. * * The edit works on what the fields show. The picker first applies a * value or option that changed earlier in the same tick, but not a value * the fields took as given after a refused write. The edited field * follows the rules above, then the picker normalizes the whole time and * writes it once. * * It writes nothing for `period` in `h23`, for the period already shown, * for `second` while seconds are off, for `null` on an empty field, and * for a non-finite number, unless a change from the same tick was still * waiting, which it then publishes. * * @example * ```ts * import { createTimePicker } from '@vuetify/v0' * * const time = createTimePicker({ minuteStep: 15 }) * * time.commit('hour', 9) * time.value.value // null * time.commit('minute', 58) // snaps to 45, never wraps to 0 * time.value.value // '09:45' * ``` */ commit: ((part: TimeUnit, value: number | null) => void) & ((part: 'period', value: TimePeriod) => void); /** * Move one field along its grid. The sign of `count` is the direction and * its magnitude the number of intervals; it defaults to `1`, fractions * truncate, and `0` or a non-finite count does nothing. The field wraps * past either end, and a value off the grid first moves onto the adjacent * grid point. An `h12` hour stays inside its meridiem. An empty field * lands on its first grid point, whatever the count: `0` for a minute, a * second, or an `h23` hour, and the first hour of the remembered meridiem * for an `h12` hour, which is `12` with the default step. Any non-zero * count flips the period. * * The step starts from what the field shows, so a value the fields took * as given after a refused write moves onto the adjacent grid point in * the direction of travel. The picker first applies a value or option * that changed earlier in the same tick. It then normalizes the whole * time and writes it once. A count of `0`, a non-finite count, `period` * in `h23`, and `second` while seconds are off write nothing, unless a * change from the same tick was still waiting, which the picker then * publishes. * * @example * ```ts * import { createTimePicker } from '@vuetify/v0' * * const time = createTimePicker({ minuteStep: 15 }) * * time.commit('hour', 23) * time.commit('minute', 45) * time.step('minute') // 45 wraps to 0 * time.step('minute', -2) // 0 → 45 → 30 * time.step('hour', 1) * time.value.value // '00:30' * ``` */ step: (part: TimePart, count?: number) => void; /** * Clear every field and forget the meridiem. The value becomes `null`. * * @example * ```ts * import { shallowRef } from 'vue' * import { createTimePicker } from '@vuetify/v0' * * const value = shallowRef('09:30') * const time = createTimePicker({ value }) * * time.clear() * time.value.value // null * time.hour.value // null * ``` */ clear: () => void; /** * Lowest and highest grid values of a numeric field, plus its resolved * step. An `h12` hour reports display hours for the current meridiem. * * @example * ```ts * import { createTimePicker } from '@vuetify/v0' * * const time = createTimePicker({ hourCycle: 'h12', hourStep: 5 }) * * time.grid('hour') // { min: 5, max: 12, step: 5 } — 12, 5, and 10 AM * time.commit('period', 'pm') * time.grid('hour') // { min: 3, max: 8, step: 5 } — 3 and 8 PM * ``` */ grid: (part: TimeUnit) => TimeGrid; /** * The time the fields show, as the canonical string, or `null` while a * field is empty. It matches `value` except in two cases. * * The model holds a string the fields cannot show as written, and the * picker has not rewritten it: because it is disabled or readonly, * because it took the owner's value as given after a refused write, or * because the value came in during this tick and the pass has not run * yet. That is a string that is not a time, where `display` is `null`, * or a time whose seconds do not match the `seconds` option, where * `display` adds `:00` or leaves the seconds out. * * The picker wrote a value the model does not hold yet. `display` runs * ahead of `value` until the picker checks the answer one tick later, * whether the owner answers late or refuses. * * @example * ```ts * import { shallowRef } from 'vue' * import { createTimePicker } from '@vuetify/v0' * * const value = shallowRef('nope') * const time = createTimePicker({ value, readonly: true }) * * time.value.value // 'nope' * time.display.value // null * ``` */ readonly display: Readonly>; /** * The underlying `createInput` context: validation state, the ARIA ids, * focused and touched, and `validate` / `reset`. The picker validates * the model value, so `required` fails while a field is still empty. * * Normalizing is not an edit: a value the picker snapped or bounded is * still pristine, unless the picker built it from edited fields. * `reset` puts the initial value back, drops a partly entered time, and * clears the validation state and `isTouched`. While disabled or readonly * it does all of that except write the model. `isPristine` reads true * after a reset even when the model does not take the initial value * back, because the picker is disabled or readonly and writes nothing, * or because the owner refuses the write. `reset` does not count toward * `revision`, except while `error` or `errorMessages` is set. * * The picker reads `required` and `rules` once, at creation. * * @example * ```ts * import { createTimePicker } from '@vuetify/v0' * * const time = createTimePicker({ required: true }) * * time.commit('hour', 9) * await time.input.validate() // false — the minute is still empty * time.input.errors.value // ['Required'] * * time.commit('minute', 30) * await time.input.validate() // true * * time.input.reset() * time.value.value // null * time.input.isValid.value // null * ``` */ input: InputContext; /** * Goes up when the model holds a new settled value worth validating. * Watch it to validate on input. * * An edit the owner took counts, and so does a value from outside. The * picker normalizing on its own counts only once the value already has * a validity: `input.isValid` is not null. `input.reset()` does not * count, except while `error` or `errorMessages` is set, which keep a * validity through the reset. * * An owner that answers late (see the `value` option) hands the * picker's own normalizing write back as a value from outside, and * that counts. An initial value that needs normalizing then counts at * creation, and again after a reset. * * @example * ```ts * import { shallowRef, watch } from 'vue' * import { createTimePicker } from '@vuetify/v0' * * const value = shallowRef('09:07') * const time = createTimePicker({ * value, * minuteStep: 15, * rules: [next => next !== '10:00' || 'Closed at ten'], * }) * * watch(time.revision, () => time.input.validate()) * * value.value // '09:00' — normalized at creation * time.revision.value // 0 * * time.step('hour') * time.revision.value // 1 — the watcher validates '10:00' and it fails * ``` */ readonly revision: Readonly>; } /** * Creates a segmented time value. * * @param options Value source, hour cycle, seconds, steps, bounds, and the * disabled and readonly flags. * @returns The fields, the canonical value, and the methods that edit them. * * @example * ```ts * import { shallowRef } from 'vue' * import { createTimePicker } from '@vuetify/v0' * * const value = shallowRef(null) * const time = createTimePicker({ value, minuteStep: 15, min: '09:00', max: '17:00' }) * * time.commit('hour', 8) * time.commit('minute', 50) * value.value // '09:00' — 08:45 on the grid, then the first time inside the range * time.step('minute', 2) * value.value // '09:30' * ``` */ declare function createTimePicker(_options?: TimePickerOptions): TimePickerContext; //#endregion //#region src/composables/createTokens/index.d.ts interface TokenAlias { [key: string]: unknown; $value: T; $type?: string; $description?: string; $extensions?: Record; $deprecated?: boolean | string; } type TokenPrimitive = string | number | boolean | null | Function; type TokenValue = TokenPrimitive | TokenAlias | TokenCollection; interface TokenCollection { [key: string]: TokenValue | TokenCollection; } type FlatTokenCollection = { id: string; value: TokenValue; }; interface TokenTicket extends RegistryTicket {} interface TokenContext extends RegistryContext { /** * Checks if a token is an alias * * @param token The token to check. * @returns True if the token is an alias, false otherwise. * @remarks An alias is a string that starts with "{" and ends with "}". * * @see https://0.vuetifyjs.com/composables/registration/create-tokens * * @example * ```ts * const tokens = createTokens({ * colors: { * primary: '#3b82f6', * secondary: '{colors.primary}', // Alias reference * }, * }) * * console.log(tokens.isAlias('{colors.primary}')) // true * console.log(tokens.isAlias('#3b82f6')) // false * ``` */ isAlias: (token: unknown) => token is string; /** * Resolves a token or alias to its value. * * @param token The token or alias to resolve. * @returns The resolved value of the token or alias, or undefined if not found. * @remarks This function can resolve nested aliases and supports token paths using dot notation. * * @see https://0.vuetifyjs.com/composables/registration/create-tokens * * @example * ```ts * const tokens = createTokens({ * colors: { * primary: '#3b82f6', * secondary: '{colors.primary}', // Alias reference * }, * }) * * console.log(tokens.resolve('{colors.primary}')) // '#3b82f6' * console.log(tokens.resolve('{colors.secondary}')) // '#3b82f6' * ``` */ resolve: (token: string | TokenAlias) => T | undefined; } interface TokenOptions extends RegistryOptions { /** * Whether to flatten nested token structures. * * @default false */ flat?: boolean; /** * An optional prefix to prepend to each token ID during registration. * * @remarks This is useful for namespacing tokens. */ prefix?: string; } interface TokenContextOptions extends TokenOptions, RegistryContextOptions { tokens?: TokenCollection; } /** * Creates a new token instance. * * @param tokens The tokens to use. * @param options The options for the token instance. * @template Z The type of the token ticket. * @template E The type of the token context. * @returns A new token instance. * * @see https://www.designtokens.org/tr/drafts/format/ * @see https://0.vuetifyjs.com/composables/registration/create-tokens * * @example * ```ts * import { createTokens } from '@vuetify/v0' * * const tokens = createTokens({ * colors: { * primary: '#3b82f6', * secondary: '{colors.primary}', // Alias reference * }, * }) * * console.log(tokens.resolve('{colors.primary}')) // '#3b82f6' * console.log(tokens.resolve('{colors.secondary}')) // '#3b82f6' * ``` */ declare function createTokens = TokenContext>(tokens?: TokenCollection, options?: TokenOptions): E; /** * Creates a new token context. * * @param options The options for the token context. * @template Z The type of the token ticket. * @template E The type of the token context. * @returns A new token context. * * @see https://0.vuetifyjs.com/composables/registration/create-tokens * * @example * ```ts * import { createTokensContext } from '@vuetify/v0' * * export const [useTokens, provideTokens, context] = createTokensContext({ * namespace: 'v0:tokens', * tokens: { * colors: { * primary: '#3b82f6', * secondary: '{colors.primary}', // Alias reference * }, * }, * }) * ``` */ declare function createTokensContext = TokenContext>(_options: TokenContextOptions): ContextTrinity; /** * Returns the current tokens instance. * * @param namespace The namespace for the tokens context. Defaults to `'v0:tokens'`. * @returns The current tokens instance. * * @see https://0.vuetifyjs.com/composables/registration/create-tokens * * @example * ```vue * * ``` */ declare function useTokens = TokenContext>(namespace?: string): E; /** * Flattens a nested collection of tokens into a flat array of tokens. * Each token is represented by an object containing its ID & value. * @param tokens The collection of tokens to flatten. * @param prefix An optional prefix to prepend to each token ID. * @returns An array of flattened tokens, each with an ID and value. */ declare function flatten(tokens: TokenCollection, prefix?: string, flat?: boolean): FlatTokenCollection[]; //#endregion //#region src/composables/createVirtual/index.d.ts type VirtualDirection = 'forward' | 'reverse'; type VirtualState = 'loading' | 'empty' | 'error' | 'ok'; type VirtualAnchor = 'auto' | 'start' | 'end' | ((items: readonly unknown[]) => number | string); interface ScrollToOptions { /** * The behavior of the scroll animation. */ behavior?: 'auto' | 'smooth' | 'instant'; /** * The alignment of the scroll position. */ block?: 'start' | 'center' | 'end' | 'nearest'; /** * The offset of the scroll position. */ offset?: number; } interface VirtualOptions { /** * The height of the item. */ itemHeight?: number | string | null; /** * The height of the container. */ height?: number | string; /** * The number of extra items to render. */ overscan?: number; /** * The direction of the scrolling. */ direction?: VirtualDirection; /** * The anchor of the scrolling. */ anchor?: VirtualAnchor; /** * Whether to smooth the anchor position. */ anchorSmooth?: boolean; /** * The callback to call when the start is reached. */ onStartReached?: (distance: number) => void | Promise; /** * The callback to call when the end is reached. */ onEndReached?: (distance: number) => void | Promise; /** * The threshold for the start. */ startThreshold?: number; /** * The threshold for the end. */ endThreshold?: number; /** * Whether to enable momentum scrolling. */ momentum?: boolean; /** * Whether to enable elastic scrolling. */ elastic?: boolean; /** * Element at the top of the list inside the scroll parent. * * Its `offsetTop` is removed from the scroll position, so a header or * padding above the list does not shift the window. Omit it when the * list starts at the top of the scroller. * * @example * ```ts * const marker = ref() * const virtual = createVirtual(items, { marker }) * ``` */ marker?: MaybeRefOrGetter; /** * Identity of an item. * * Measured heights follow this key when items are prepended, filtered, * or reordered. Omit it to keep each height on its index. Duplicate keys * keep the latest measurement. * * @example * ```ts * const virtual = createVirtual(items, { * itemKey: item => item.id, * }) * ``` */ itemKey?: (item: T, index: number) => string | number; /** * Write momentum and overscroll styles onto the scroll element. * * Set this to `false` when a parent owns that element. * * @default true * * @example * ```ts * const virtual = createVirtual(items, { ownElement: false }) * ``` */ ownElement?: boolean; } interface VirtualItem { raw: T; index: number; /** `itemKey` result, or the index when no key function was passed. */ key: string | number; } interface VirtualContext { /** * The element that is being virtualized. * * @example * ```vue * * * */ element: Ref; /** * The items that are being virtualized. * * @example * ```vue * * * * ``` */ items: ComputedRef[]>; /** * The offset of the virtualized items. * * @example * ```vue * * * * ``` */ offset: Readonly>; /** * The size of the virtualized items. * * @example * ```vue * * * * ``` */ size: Readonly>; /** * The state of the virtualized items. * * @example * ```vue * * * * ``` */ state: ShallowRef; /** * Scroll to an item by index. * * @example * ```vue * * * * ``` */ scrollTo: (index: number, options?: ScrollToOptions) => void; /** * The scroll event handler. * * @example * ```vue * * * * ``` */ scroll: () => void; /** * The scrollend event handler. * * @example * ```vue * * * * ``` */ scrollend: () => void; /** * Resize an item by index. * * @example * ```vue * * * * ``` */ resize: (index: number, height: number) => void; /** * Reset the virtualized items. * * @example * ```vue * * * * ``` */ reset: () => void; } interface VirtualContextOptions extends VirtualOptions { /** Namespace for dependency injection */ namespace?: string; } declare function createVirtual(items: Ref, _options?: VirtualOptions): VirtualContext; /** * Creates a virtual scrolling context with dependency injection support. * * @param items Reactive array of items to virtualize * @param options Configuration options including namespace * @template T The type of the items * @returns Trinity tuple: [useVirtual, provideVirtual, defaultVirtual] * * @see https://0.vuetifyjs.com/composables/data/create-virtual * * @example * ```ts * // Create injectable context * const [useVirtual, provideVirtual, virtual] = createVirtualContext(items, { * namespace: 'my-virtual', * overscan: 10, * }) * * // In parent component * provideVirtual() * * // In child component * const virtual = useVirtual() * ``` */ declare function createVirtualContext(items: Ref, _options?: VirtualContextOptions): ContextTrinity>; /** * Returns the current virtual context from dependency injection. * * @param namespace The namespace for the virtual context. Defaults to `v0:virtual`. * @template T The type of the items * @returns The current virtual context. * * @throws An error if the virtual context is not found and no default is provided. * * @see https://0.vuetifyjs.com/composables/data/create-virtual * * @example * ```vue * * * * ``` */ declare function useVirtual(namespace?: string): VirtualContext; //#endregion //#region src/composables/toArray/index.d.ts /** * @module toArray * * @see https://0.vuetifyjs.com/composables/transformers/to-array * * @remarks * Utility function to normalize single values and arrays into arrays. * * Converts single values into single-element arrays, passes arrays through unchanged, * and handles null/undefined by returning empty arrays. Perfect for functions that * accept both single values and arrays as input (e.g., ID | ID[]). * * @example * ```ts * import { toArray } from '@vuetify/v0' * * toArray('hello') // ['hello'] * toArray(['a', 'b']) // ['a', 'b'] * toArray(null) // [] * ``` */ /** * Converts a value to an array. * * @param value The value to convert. * @template Z The type of the value. * @returns The converted array. * * @see https://0.vuetifyjs.com/composables/transformers/to-array * * @example * ```ts * import { toArray } from '@vuetify/v0' * * const value = 'Example Value' * const valueAsArray = toArray(value) * * console.log(valueAsArray) // ['Example Value'] * ``` */ declare function toArray(value: Z | Z[]): Z[]; //#endregion //#region src/utilities/color.d.ts interface RGB { r: number; g: number; b: number; a?: number; } declare function hexToRgb(hex: string): RGB; declare function rgbToHex({ r, g, b, a }: RGB): string; //#endregion //#region src/utilities/apca.d.ts declare function apca(text: RGB, background: RGB): number; declare function foreground(hex: string): string; //#endregion //#region src/utilities/diacritics.d.ts /** * @module utilities/diacritics * * @remarks * Accent-folding search primitives. Pure string transforms — no DOM, no state, * no reactivity. Powers the `ignoreAccents` option of `toHighlight` and any * filter that wants a plain query to reach accented text. */ /** * A `[start, end]` index pair where `end` is exclusive (matches * `String.prototype.slice` convention). * * @example * ```ts * import type { MatchRange } from '@vuetify/v0' * * const ranges: MatchRange[] = [[0, 5], [12, 17]] * ``` */ type MatchRange = readonly [number, number]; /** * Which side of a comparison has its accents folded before matching. * * - `'query'` — folds the query, so typing `café` finds plain `cafe` * - `'target'` — folds the text, so typing `cafe` finds accented `café` * - `true` — both sides fold, so any accent variant matches any other * - `false` — neither folds, exact match only * * `'query'` and `'target'` fold only one side, but a spelling that already * agrees on both sides still matches verbatim — folding one side never * hides a match the other side already has. They still don't fold each * other's accents together, so `café` won't match `cafè` under either. */ type IgnoreAccents = boolean | 'query' | 'target'; interface FindMatchRangesOptions { ignoreCase?: boolean; ignoreAccents?: IgnoreAccents; matchAll?: boolean; } /** * Finds `[start, end]` index pairs where `query` occurs in `text`, optionally * folding accents on either side. Returned indices always address the original * `text`, even when folding or case-conversion changed its length. * * Directional folding (`'query'` or `'target'`) only transforms one side, but * a spelling that's already identical on both sides — accents and all — is * merged in verbatim, so folding one side never hides a match the other side * already has. * * @param text The string to search. * @param query The term to look for. An empty query yields no ranges. * @param options Optional `ignoreCase`, `ignoreAccents`, `matchAll`. * @returns Ranges into `text`, where `end` is exclusive. * * @example * ```ts * import { findMatchRanges } from '@vuetify/v0' * * findMatchRanges('Zürich', 'zurich', { ignoreCase: true, ignoreAccents: true }) * // [[0, 6]] * * findMatchRanges('Łódź', 'Lo', { ignoreAccents: 'target' }) * // [[0, 2]] * * findMatchRanges('… Kraków …', 'Kraków', { ignoreAccents: 'query' }) * // [[2, 8]] — typing the exact accented name always finds itself * ``` */ declare function findMatchRanges(text: string, query: string, options?: FindMatchRangesOptions): MatchRange[]; //#endregion //#region src/utilities/errors.d.ts /** * Structured error thrown by v0 internals. * * @remarks * Carries a stable {@link V0ErrorCode} discriminant on `code` so * consumers, devtools panels, and error trackers can identify the * error without parsing the message string. Domain context lives in * top-level fields per code (`key` for `V0_CONTEXT_MISSING`, `plugin` * for `V0_PLUGIN_MISSING`), populated from a {@link V0ErrorDetails} * argument and merged onto the instance at construction time. * * `cause` is forwarded to `Error`'s standard `ErrorOptions.cause` slot * and is intended to carry a wrapped upstream error, not metadata. * * Prefer {@link isV0Error} over manual `instanceof` checks at the * narrowing site — the guard intersects the instance type with the * matching {@link V0ErrorDetails} arm, so per-code fields are typed. * * @example Author site * ```ts * throw new V0Error('Context not found.', { code: 'V0_CONTEXT_MISSING', key }) * ``` * * @example Author site with upstream wrap * ```ts * try { * JSON.parse(raw) * } catch (err) { * throw new V0Error('Failed to hydrate registry.', { * code: 'V0_CONTEXT_MISSING', * key: 'v0:registry', * cause: err, * }) * } * ``` * * @example Consumer site * ```ts * try { * useContext(myKey) * } catch (err) { * if (isV0Error(err, 'V0_CONTEXT_MISSING')) { * console.log(err.key) * } * } * ``` */ declare class V0Error extends Error { name: string; readonly code: V0ErrorCode; readonly key?: string | symbol; readonly plugin?: string; readonly palette?: string; readonly seed?: string; readonly variant?: string; readonly adapter?: string; readonly prefix?: string; readonly value?: string; constructor(message: string, details: V0ErrorDetails & { cause?: unknown; }); } /** * Type guard for v0-thrown errors. * * @param value The value to test. * @param code Optional discriminant — narrow the result to a specific * {@link V0ErrorCode} so per-code fields become required. * * @remarks * Without the optional `code` argument, the guard verifies the value * is a {@link V0Error} instance. With the `code` argument, the guard * also narrows the instance type to the intersection with the matching * {@link V0ErrorDetails} arm — fields like `key` or `plugin` change * from optional to required on the narrowed type. * * @example Narrow to any v0 error * ```ts * if (isV0Error(err)) { * console.log(err.code) * } * ``` * * @example Narrow to a specific code * ```ts * if (isV0Error(err, 'V0_CONTEXT_MISSING')) { * console.log(err.key) // typed as string | symbol, not string | symbol | undefined * } * ``` */ declare function isV0Error(value: unknown, code?: C): value is V0Error & Extract; //#endregion //#region src/utilities/helpers.d.ts /** * Checks if a value is a function * * @param item The value to check * @returns True if the value is a function * * @example * ```ts * isFunction(() => {}) // true * isFunction('string') // false * ``` */ declare function isFunction(item: unknown): item is Function; /** * Checks if a value is a string * * @param item The value to check * @returns True if the value is a string * * @example * ```ts * isString('hello') // true * isString(123) // false * ``` */ declare function isString(item: unknown): item is string; /** * Checks if a value is a number * * @param item The value to check * @returns True if the value is a number (including NaN) * * @example * ```ts * isNumber(123) // true * isNumber(NaN) // true * isNumber('123') // false * ``` * * @see {@link isNaN} to check for NaN specifically */ declare function isNumber(item: unknown): item is number; /** * Checks if a value is a boolean * * @param item The value to check * @returns True if the value is a boolean * * @example * ```ts * isBoolean(true) // true * isBoolean(false) // true * isBoolean(0) // false * ``` */ declare function isBoolean(item: unknown): item is boolean; /** * Checks if a value is a plain object (excludes null and arrays) * * @param item The value to check * @returns True if the value is a plain object * * @remarks * Returns false for null and arrays, even though `typeof null === 'object'` * and `typeof [] === 'object'` in JavaScript. * * `Record` is load-bearing: TypeScript does not grant interfaces * an implicit index signature, so `Record` destroys known * property types on interface-typed values and fails to subtract * `Record` members in the negative branch. * * @example * ```ts * isObject({}) // true * isObject({ a: 1 }) // true * isObject(null) // false * isObject([]) // false * ``` * * @see {@link isArray} to check for arrays * @see {@link isNull} to check for null */ declare function isObject(item: unknown): item is Record; /** * Checks if a value is a thenable (any object with a `.then` method). * Duck-typed — matches both native Promises and any Promise-like. * * @param item The value to check * @returns True if the value has a callable `then` property * * @example * ```ts * isThenable(Promise.resolve()) // true * isThenable({ then: () => {} }) // true * isThenable({}) // false * isThenable('string') // false * ``` * * @remarks Use this when duck-typing async behavior — for example, rejecting * a callback that returned a Promise-like when only synchronous returns are * supported. If you specifically want native Promise instances, use * `instanceof Promise` directly. */ declare function isThenable(item: unknown): item is { then: Function; }; /** * Checks if a value is an array * * @param item The value to check * @returns True if the value is an array * * @example * ```ts * isArray([]) // true * isArray([1, 2, 3]) // true * isArray('string') // false * ``` * * @remarks The guard keeps whichever array constituents the input already had — * element types, tuple arity and `readonly` all survive, and the `else` branch * drops exactly those constituents. Three branches, in order: * * 1. `0 extends (1 & T)` detects an `any` input and yields `T[]` (`any[]`), * matching `Array.isArray` so callback parameters stay contextually typed. * 2. Nothing array-shaped to extract (an `unknown` value, say) falls back to * `unknown[]`, reproducing the previous narrowing so mutation and assignment * to `unknown[]` keep compiling. * 3. Otherwise the array constituents of `T` pass through untouched. * * `NoInfer` widens the parameter just enough for TypeScript to accept the * first branch (a predicate must be assignable to its parameter's type) without * letting an array argument capture the inference site. */ declare function isArray(item: T | NoInfer): item is 0 extends (1 & T) ? T[] : [Extract] extends [never] ? T & unknown[] : Extract; /** * Checks if a value is a DOM Element * * @param item The value to check * @returns True if the value is a DOM Element * * @example * ```ts * isElement(document.body) // true * isElement('string') // false * isElement(null) // false * ``` */ declare function isElement(item: unknown): item is Element; /** * Resolve the deepest focused element, piercing open shadow roots. * * `document.activeElement` returns the shadow *host* when focus is inside an * open shadow root — walk down through open roots so focus/keyboard logic * resolves the real focused element (e.g. a control inside a custom element). * Returns the same value as `document.activeElement` in light DOM, and `null` * under SSR. Closed shadow roots can't be traversed. * * @example * ```ts * const active = getActiveElement() * ``` */ declare function getActiveElement(): Element | null; /** * Checks if a value is null * * @param item The value to check * @returns True if the value is null * * @example * ```ts * isNull(null) // true * isNull(undefined) // false * ``` * * @see {@link isUndefined} to check for undefined * @see {@link isNullOrUndefined} to check for either */ declare function isNull(item: unknown): item is null; /** * Checks if a value is null or undefined * * @param item The value to check * @returns True if the value is null or undefined * * @remarks * Uses loose equality (`== null`) which matches both null and undefined. * * @example * ```ts * isNullOrUndefined(null) // true * isNullOrUndefined(undefined) // true * isNullOrUndefined(0) // false * isNullOrUndefined('') // false * ``` * * @see {@link isNull} to check for null only * @see {@link isUndefined} to check for undefined only */ declare function isNullOrUndefined(item: unknown): item is null | undefined; /** * Checks if a value is undefined * * @param item The value to check * @returns True if the value is undefined * * @example * ```ts * isUndefined(undefined) // true * isUndefined(null) // false * ``` * * @see {@link isNull} to check for null * @see {@link isNullOrUndefined} to check for either */ declare function isUndefined(item: unknown): item is undefined; /** * Checks if a value is a primitive (string, number, or boolean) * * @param item The value to check * @returns True if the value is a string, number, or boolean * * @example * ```ts * isPrimitive('hello') // true * isPrimitive(123) // true * isPrimitive(true) // true * isPrimitive({}) // false * isPrimitive(null) // false * ``` */ declare function isPrimitive(item: unknown): item is string | number | boolean; /** * Checks if a value is a symbol * * @param item The value to check * @returns True if the value is a symbol * * @example * ```ts * isSymbol(Symbol('test')) // true * isSymbol('symbol') // false * ``` */ declare function isSymbol(item: unknown): item is symbol; /** * Checks if a value is NaN (Not a Number) * * @param item The value to check * @returns True if the value is NaN * * @remarks * Uses `Number.isNaN()` which only returns true for the actual NaN value, * unlike the global `isNaN()` which coerces the argument to a number first. * * @example * ```ts * isNaN(NaN) // true * isNaN(123) // false * isNaN('hello') // false (unlike global isNaN) * isNaN(undefined) // false (unlike global isNaN) * ``` * * @see {@link isNumber} to check if a value is a number type */ declare function isNaN(item: unknown): item is number; declare const UNSAFE_KEYS: Set; /** * Deeply merges source objects into a target object, returning a new object * * @param target The base object to merge into * @param sources One or more source objects to merge from * @returns A new merged object (inputs are not mutated) * * @remarks * - Creates and returns a new object — inputs are never mutated * - Nested objects are recursively merged * - Arrays are replaced, not merged * - Primitives from sources overwrite target values * * @example * ```ts * const target = { a: 1, b: { c: 2 } } * const result = mergeDeep(target, { b: { d: 3 } }) * // result is { a: 1, b: { c: 2, d: 3 } } * // target is unchanged * * // Multiple sources * mergeDeep({}, { a: 1 }, { b: 2 }) // { a: 1, b: 2 } * * // Arrays are replaced * mergeDeep({ arr: [1, 2] }, { arr: [3] }) // { arr: [3] } * ``` */ declare function mergeDeep(target: T, ...sources: DeepPartial[]): T; /** * Generates a unique ID, using Vue's useId when in component context * * @returns A unique string ID * * @remarks * - In component setup/lifecycle: Uses Vue's `useId()` for SSR-safe hydration * - Outside components: Falls back to sequential counter (`v0-0`, `v0-1`, ...) * - Vapor mode compatible * - IDs are sequential and predictable — intended for DOM `id`/ARIA wiring only. * Never use them as security tokens (CSRF tokens, session ids, capabilities). * * @example * ```ts * // In component setup - SSR safe * const id = useId() // 'v:0', 'v:1', etc. (Vue's format) * * // Outside component - counter fallback * const id = useId() // 'v0-0', 'v0-1', etc. * ``` */ declare function useId(): string; /** * Clamps a value between a minimum and maximum * * @param value The value to clamp * @param min The minimum value (default: 0) * @param max The maximum value (default: 1) * @returns The clamped value * * @example * ```ts * clamp(5, 0, 10) // 5 * clamp(-5, 0, 10) // 0 * clamp(15, 0, 10) // 10 * ``` */ declare function clamp(value: number, min?: number, max?: number): number; /** * Creates an array of sequential numbers * * @param length The length of the array to create * @param start The starting index (default: 0) * @returns An array of sequential numbers * * @example * ```ts * range(3) // [0, 1, 2] * range(3, 1) // [1, 2, 3] * range(5, 10) // [10, 11, 12, 13, 14] * range(0) // [] * ``` */ declare function range(length: number, start?: number): number[]; /** * Parses a CSS pixel length into a number * * @param value The resolved CSS length, e.g. `getComputedStyle(el).marginLeft` * @param fallback The value to return when `value` does not parse (default: 0) * @returns The parsed number, or `fallback` * * @remarks * Built for reading `getComputedStyle` output, where a length that does not * apply resolves to `''` or `'auto'` rather than to a number. An unparseable * length returns `fallback`; a length that legitimately parses to `0` returns * `0`. That distinction is why this exists — `Number.parseFloat(v) || 0` * collapses both cases onto `0`, which is only correct when the fallback is * itself `0`. * * Only the leading number is read, matching `Number.parseFloat`, so any unit * suffix is ignored. Values `getComputedStyle` never returns — percentages, * `calc()` expressions, multi-value shorthands — are out of scope. * * @example * ```ts * pxToNumber('16px') // 16 * pxToNumber('0px') // 0 * pxToNumber('-4.5px') // -4.5 * pxToNumber('auto') // 0 * pxToNumber(undefined) // 0 * * // A non-zero fallback is the case `|| 0` cannot express * pxToNumber('auto', 100) // 100 * pxToNumber('0px', 100) // 0 * ``` */ declare function pxToNumber(value: string | undefined, fallback?: number): number; /** * Resolves an iterable of IDs to their items via a getter, * filtering out any that return undefined. * * @internal */ declare function resolveIds(ids: Iterable, getter: (id: ID) => E | undefined): E[]; /** * Extracts defined index values from an iterable of items. * * @internal */ declare function resolveIndexes(items: Iterable<{ index?: number; }>): number[]; //#endregion //#region src/utilities/instance.d.ts declare function instanceExists(): boolean; declare function instanceName(): string | undefined; //#endregion //#region src/composables/toHighlight/index.d.ts /** * A contiguous chunk of source text, flagged as matched or unmatched. * * @example * ```ts * import type { HighlightChunk } from '@vuetify/v0' * * const chunk: HighlightChunk = { text: 'Hello', match: true } * ``` */ interface HighlightChunk { text: string; match: boolean; } /** * Optional configuration for {@link toHighlight}. * * @example * ```ts * import { toHighlight } from '@vuetify/v0' * * const chunks = toHighlight('Hello World', 'WORLD', { * ignoreCase: true, * matchAll: true, * }) * ``` */ interface ToHighlightOptions { /** * Pre-computed `[start, end]` index pairs. * When non-empty, takes priority over `query`. `matchAll` is ignored. * Caller-supplied ranges are sorted and merged before chunking, so * unsorted or overlapping input is handled gracefully. */ matches?: MaybeRefOrGetter; /** * Highlight every occurrence (`true`) or only the first per term (`false`, default). * Ignored when `matches` is provided. */ matchAll?: MaybeRefOrGetter; /** Case-insensitive matching. Default `false`. */ ignoreCase?: MaybeRefOrGetter; /** * Folds accents before matching. `'query'` folds only the search term, * `'target'` only the text, `true` both sides. Default `false`. */ ignoreAccents?: MaybeRefOrGetter; } /** * Splits text into matched and unmatched chunks. * * Pure transformer — returns a plain array. Wrap the call in `computed()` for * reactive recomputation. * * Priority: `options.matches` (when non-empty) → `query` → no-match fallback. * * @param text The source string to split. * @param query One or more search terms. Empty strings are ignored. Case sensitivity controlled by `options.ignoreCase`. * @param options Optional `matches`, `matchAll`, `ignoreCase`, `ignoreAccents`. * @returns A `HighlightChunk[]` array. * * @see https://0.vuetifyjs.com/composables/transformers/to-highlight * * @example * ```ts * import { computed, shallowRef } from 'vue' * import { toHighlight } from '@vuetify/v0' * * const query = shallowRef('World') * const chunks = computed(() => toHighlight('Hello World', query)) * * console.log(chunks.value) * // [{ text: 'Hello ', match: false }, { text: 'World', match: true }] * ``` */ declare function toHighlight(text: MaybeRefOrGetter, query?: MaybeRefOrGetter, options?: ToHighlightOptions): HighlightChunk[]; //#endregion //#region src/composables/toReactive/index.d.ts /** * Converts a `MaybeRef` to a `UnwrapNestedRefs`. * * @param objectRef The object to convert. * @template Z The type of the object. * @returns The converted object. * * @see https://0.vuetifyjs.com/composables/transformers/to-reactive * * @example * ```ts * import { ref } from 'vue' * import { toReactive } from '@vuetify/v0' * * const state = ref({ name: 'John', age: 30 }) * const rstate = toReactive(state) * * console.log(rstate.name) // John * ``` */ declare function toReactive(objectRef: MaybeRef): UnwrapNestedRefs; //#endregion //#region src/composables/useBreakpoints/index.d.ts type BreakpointName = 'xs' | 'sm' | 'md' | 'lg' | 'xl' | 'xxl'; interface BreakpointsContext { breakpoints: Readonly>; mobileBreakpoint: BreakpointName | number; name: Readonly>; width: Readonly>; height: Readonly>; isMobile: Readonly>; xs: Readonly>; sm: Readonly>; md: Readonly>; lg: Readonly>; xl: Readonly>; xxl: Readonly>; smAndUp: Readonly>; mdAndUp: Readonly>; lgAndUp: Readonly>; xlAndUp: Readonly>; smAndDown: Readonly>; mdAndDown: Readonly>; lgAndDown: Readonly>; xlAndDown: Readonly>; ssr: boolean; update: () => void; } interface BreakpointsOptions { namespace?: string; mobileBreakpoint?: BreakpointName | number; breakpoints?: Partial>; ssr?: { clientWidth: number; clientHeight?: number; }; } interface BreakpointsPluginOptions extends BreakpointsOptions {} interface BreakpointsContextOptions extends BreakpointsOptions {} /** * Creates a new breakpoints instance. * * @param options The options for the breakpoints instance. * @returns A new breakpoints instance. * * @see https://0.vuetifyjs.com/composables/plugins/use-breakpoints * * @example * ```ts * import { createBreakpoints } from '@vuetify/v0' * * const breakpoints = createBreakpoints({ * namespace: 'v0:breakpoints', * mobileBreakpoint: 'md', * breakpoints: { * xs: 0, * sm: 600, * md: 840, * lg: 1145, * xl: 1545, * xxl: 2138, * }, * }) * ``` */ declare function createBreakpoints(_options?: BreakpointsOptions): BreakpointsContext; declare const createBreakpointsContext: <_E extends BreakpointsContext = BreakpointsContext>(_options?: BreakpointsContextOptions | undefined) => ContextTrinity<_E>, createBreakpointsPlugin: (_options?: (BreakpointsContextOptions & Pick<{ namespace?: string; persist?: boolean; devtools?: boolean; }, "devtools">) | undefined) => Plugin, useBreakpoints: <_E extends BreakpointsContext = BreakpointsContext>(namespace?: string) => _E; //#endregion //#region src/composables/useClickOutside/index.d.ts type ClickOutsideElement = HTMLElement | null | undefined; type ClickOutsideTarget = MaybeRefOrGetter; type ClickOutsideIgnoreTarget = ClickOutsideTarget | string; interface UseClickOutsideOptions { /** * Use capture phase for event listeners. * Ensures detection works even when inner elements call stopPropagation. * @default true */ capture?: boolean; /** * Touch movement threshold in pixels. * If finger moves more than this distance, it's treated as a scroll, not a tap. * Only applies to touch interactions. * @default 30 */ touchScrollThreshold?: number; /** * Detect focus moving to iframes as an outside click. * Useful when iframes are outside the target elements. * @default false */ detectIframe?: boolean; /** * Elements to ignore when detecting outside clicks. * Accepts element refs, getters, or CSS selector strings. * Clicks on these elements (or their descendants) won't trigger the handler. * * Note: CSS selectors cannot match across Shadow DOM boundaries due to * browser limitations. Use element refs instead when ignoring shadow hosts. */ ignore?: MaybeRefOrGetter; /** * Use bounding rect instead of DOM containment to detect outside clicks. * When true, checks if click coordinates are outside the element's bounding box. * Useful for native elements where backdrop clicks have the dialog as target. * @default false */ bounds?: boolean; } interface UseClickOutsideReturn { /** * Whether the listener is currently active */ readonly isActive: Readonly>; /** * Whether the listener is currently paused */ readonly isPaused: Readonly>; /** * Pause listening (stops detection but keeps state) */ pause: () => void; /** * Resume listening */ resume: () => void; /** * Stop listening and clean up */ stop: () => void; } /** * Detects clicks outside of the specified element(s). * * Uses two-phase detection (pointerdown → pointerup) to prevent false positives * when users drag from inside to outside an element. * * @param target Element ref(s) to detect clicks outside of. Accepts a single ref/getter or array of refs/getters. * @param handler Callback invoked when a click outside is detected. * @param options Configuration options. * @returns An object with methods to control the listener. * * @see https://0.vuetifyjs.com/composables/system/use-click-outside * * @example Native element ref * ```ts * const menuRef = useTemplateRef('menu') * * useClickOutside(menuRef, () => { isOpen.value = false }) * ``` * * @example Component ref (e.g., Atom) * ```ts * const atomRef = useTemplateRef('atom') * * // Pass the exposed element TemplateRef via getter * useClickOutside( * () => atomRef.value?.element, * () => { isOpen.value = false } * ) * ``` * * @example Multiple targets * ```ts * const popoverRef = useTemplateRef('popover') * const anchorRef = useTemplateRef('anchor') * * useClickOutside( * [() => popoverRef.value?.element, anchorRef], * () => { isOpen.value = false } * ) * ``` * * @example Ignoring elements (CSS selectors or refs) * ```ts * useClickOutside( * () => navRef.value?.element, * () => { isOpen.value = false }, * { ignore: ['[data-app-bar]'] } * ) * ``` * * @example Native dialog with bounds detection * ```ts * // For native elements, use bounds mode to detect backdrop clicks * const dialogRef = useTemplateRef('dialog') * * useClickOutside( * dialogRef, * () => { dialogRef.value?.close() }, * { bounds: true } * ) * ``` */ declare function useClickOutside(target: MaybeArray, handler: (event: PointerEvent | FocusEvent) => void, options?: UseClickOutsideOptions): UseClickOutsideReturn; //#endregion //#region src/composables/useDate/index.d.ts interface DateContext { /** The date adapter instance */ adapter: DateAdapter; /** Current locale (reactive, synced with useLocale if available) */ locale: ComputedRef; /** First day of week, derived from locale or explicit override */ firstDayOfWeek: ComputedRef; } /** Options for date composables */ interface DateOptions { /** * Date adapter instance. Omit it to use `V0PlainDateAdapter`. * Pass `V0DateAdapter` for Temporal. An adapter you pass is not replaced. * * @example * ```ts * import { createDate } from '@vuetify/v0' * import { V0DateAdapter } from '@vuetify/v0/date' * * createDate() * createDate({ adapter: new V0DateAdapter() }) * ``` */ adapter?: DateAdapter; /** Locale for formatting (defaults to useLocale's selected locale or 'en-US') */ locale?: string; /** Short locale codes mapped to full Intl locale strings (e.g., { en: 'en-US' }) */ locales?: Record; /** First day of week override. 0=Sun, 1=Mon, ... 6=Sat. Derived from locale if not set. */ firstDayOfWeek?: number; } /** Context options with namespace */ interface DateContextOptions extends DateOptions { namespace?: string; } /** Plugin options */ interface DatePluginOptions extends DateContextOptions { /** When true, this plugin appears in the Vue DevTools v0 inspector. @default false */ devtools?: boolean; } /** * Creates a new date context. * * @param options Adapter and locale configuration. * @template Z The date type used by the adapter. * @template E The date context type. * @returns A date context. * * @see https://0.vuetifyjs.com/composables/plugins/use-date * * @example * ```ts * import { createDate } from '@vuetify/v0' * import { V0DateAdapter } from '@vuetify/v0/date' * * const { adapter } = createDate() * adapter.toISO(adapter.date()!) * * // Temporal, unchanged * const temporal = createDate({ adapter: new V0DateAdapter() }) * ``` */ declare function createDate(options: DateOptions & { adapter: DateAdapter; }): DateContext; declare function createDate(options?: DateOptions): DateContext; /** * Creates a new date context trinity. * * @param options Adapter, locale, and namespace configuration. * @template Z The date type used by the adapter. * @template E The date context type. * @returns A trinity [useContext, provideContext, defaultContext]. * * @see https://0.vuetifyjs.com/composables/plugins/use-date * * @example * ```ts * import { createDateContext } from '@vuetify/v0' * import { V0DateAdapter } from '@vuetify/v0/date' * * const [useAppDate, provideAppDate] = createDateContext({ * adapter: new V0DateAdapter(), * namespace: 'app:date', * }) * ``` */ declare function createDateContext = DateContext>(_options?: DateContextOptions): ContextTrinity; /** * Creates a new date plugin. * * @param options Adapter, locale, and namespace configuration. * @template Z The date type used by the adapter. * @template E The date context type. * @returns A Vue plugin. * * @see https://0.vuetifyjs.com/composables/plugins/use-date * * @example * ```ts * import { createApp } from 'vue' * import { createDatePlugin } from '@vuetify/v0' * import { V0DateAdapter } from '@vuetify/v0/date' * import App from './App.vue' * * const app = createApp(App) * * app.use(createDatePlugin()) * app.use(createDatePlugin({ adapter: new V0DateAdapter(), locale: 'de-DE' })) * ``` */ declare function createDatePlugin(options: DatePluginOptions & { adapter: DateAdapter; }): ObjectPlugin; declare function createDatePlugin(options?: DatePluginOptions): ObjectPlugin; /** * Returns the current date context. * * Inside a component with no plugin, returns a `V0PlainDateAdapter` context. * Outside a component, throws. A plugin you installed is used as-is. * * @param namespace The namespace to look up (defaults to 'v0:date'). * @template Z The date type used by the adapter. * @template E The date context type. * @returns The current date context. * @throws If called outside a Vue component. * * @see https://0.vuetifyjs.com/composables/plugins/use-date * * @example * ```ts * import { createApp } from 'vue' * import { createDatePlugin } from '@vuetify/v0' * import { V0DateAdapter } from '@vuetify/v0/date' * import App from './App.vue' * * const app = createApp(App) * app.use(createDatePlugin({ adapter: new V0DateAdapter() })) * ``` * * @example * ```vue * * ``` */ declare function useDate = DateContext>(namespace?: string): E; //#endregion //#region src/composables/useDelay/index.d.ts interface UseDelayOptions { /** * Delay in milliseconds before the opening transition fires. * * @example * ```ts * useDelay(undefined, { openDelay: 300 }) * useDelay(undefined, { openDelay: () => isFocus.value ? 0 : 500 }) * ``` */ openDelay?: MaybeRefOrGetter; /** * Delay in milliseconds before the closing transition fires. * * @example * ```ts * useDelay(undefined, { closeDelay: 200 }) * ``` */ closeDelay?: MaybeRefOrGetter; } /** * Per-call options for `start()`. * * @example * ```ts * delay.start(false, { minDelay: 500 }) * ``` */ interface UseDelayStartOptions { /** Minimum delay floor in ms; max(configuredDelay, minDelay) wins. */ minDelay?: number; } /** * The reactive controls and state surface returned by `useDelay`. * * @example * ```ts * const { start, stop, pause, resume, isActive, isOpening } = useDelay( * undefined, * { openDelay: 300, closeDelay: 200 }, * ) * * start(true) * ``` */ interface UseDelayReturn { /** * Start a delay in the given direction. Restarts if already running. Resolves * with `isOpening` once the delay elapses. If `start()` is called again before * the previous resolves, the previous promise resolves with the new direction. * * @example * ```ts * const delay = useDelay(undefined, { openDelay: 300, closeDelay: 200 }) * await delay.start(true) // resolves true after 300ms * await delay.start(false, { minDelay: 500 }) // resolves false after max(200, 500) * ``` */ start: (isOpening: boolean, options?: UseDelayStartOptions) => Promise; /** * Cancel any pending delay and reset state. Resolves the pending promise with the current direction. * * @example * ```ts * delay.stop() * ``` */ stop: () => void; /** * Pause the in-flight delay, preserving remaining time. No-op if not running. * * @example * ```ts * delay.pause() * ``` */ pause: () => void; /** * Resume from where pause left off. No-op if not paused. * * @example * ```ts * delay.resume() * ``` */ resume: () => void; /** * Whether a delay is currently pending (started, not stopped). */ isActive: Readonly>; /** * Whether the pending delay is currently paused. */ isPaused: Readonly>; /** * Milliseconds remaining until the pending transition fires. */ remaining: Readonly>; /** * Direction of the pending transition (`true` = opening, `false` = closing). */ isOpening: Readonly>; } /** * Schedule open and close transitions with configurable delays. * * Composes `useTimer` for the lifecycle (`start` / `stop` / `pause` / `resume` plus * reactive `isActive`, `isPaused`, `remaining`) and adds direction tracking * (`isOpening`) and promise-based resolution. * * @param callback Optional callback invoked once a started delay elapses; receives the resolved direction. * @param options Reactive delay settings. * @returns Lifecycle controls and reactive state. * * @see https://0.vuetifyjs.com/composables/system/use-delay * * @example * ```ts * const delay = useDelay(isOpening => isVisible.value = isOpening, { * openDelay: 300, * closeDelay: 200, * }) * * delay.start(true) * delay.start(false, { minDelay: 500 }) * delay.pause() * delay.resume() * delay.stop() * ``` */ declare function useDelay(callback?: (isOpening: boolean) => void, options?: UseDelayOptions): UseDelayReturn; //#endregion //#region src/composables/useDragDrop/adapters/adapter.d.ts interface DragDropAdapterEmit { start: (source: DraggableTicket, origin: { x: number; y: number; }, via: DragVia) => void; move: (point: { x: number; y: number; }) => void; drop: () => void; cancel: () => void; } interface DragDropAdapterContext extends DragDropContext { emit: DragDropAdapterEmit; } /** * Abstract base class for useDragDrop adapters. Provides a `cleanup` slot, a * `dispose()` lifecycle, and a `locate()` helper that walks the DOM to find the * draggable ticket whose `el` ancestors a given event target. * * @example * ```ts * import { DragDropAdapter, type DragDropAdapterContext } from '@vuetify/v0' * * class MyAdapter extends DragDropAdapter { * setup (context: DragDropAdapterContext) { * const stop = useEventListener(document, 'mousedown', event => { * const ticket = this.locate(event.target, context) * if (ticket) context.emit.start(ticket, { x: event.clientX, y: event.clientY }, 'pointer') * }) * this.cleanup = () => stop() * } * } * ``` */ declare abstract class DragDropAdapter { protected cleanup: (() => void) | null; dispose(): void; protected locate(target: EventTarget | Element | null, context: DragDropAdapterContext): DraggableTicket | null; abstract setup(context: DragDropAdapterContext): void; } //#endregion //#region src/composables/useDragDrop/adapters/pointer.d.ts interface PointerAdapterOptions { /** Drag-activation distance in px (default 0 — start on pointerdown). */ threshold?: number; } /** * Default pointer adapter. Wires `pointerdown` / `pointermove` / `pointerup` / * `pointercancel` on the document and converts them into drag lifecycle calls. * * @example * ```ts * import { PointerAdapter, useDragDrop } from '@vuetify/v0' * * useDragDrop({ adapters: [new PointerAdapter({ threshold: 10 })] }) * ``` */ declare class PointerAdapter extends DragDropAdapter { private threshold; constructor(options?: PointerAdapterOptions); setup(context: DragDropAdapterContext): void; } //#endregion //#region src/composables/useDragDrop/adapters/keyboard.d.ts interface KeyboardAdapterOptions { /** Activation keys (default [' ', 'Enter']). */ activate?: string[]; /** Step size in px for arrow-key moves (default 16). */ step?: number; } /** * Default keyboard adapter. Listens for `keydown` on the document; activation * keys start/drop drags, arrow keys nudge the drag point, Escape cancels. * * @example * ```ts * import { KeyboardAdapter, useDragDrop } from '@vuetify/v0' * * useDragDrop({ adapters: [new KeyboardAdapter({ activate: ['x'], step: 32 })] }) * ``` */ declare class KeyboardAdapter extends DragDropAdapter { private activate; private step; constructor(options?: KeyboardAdapterOptions); setup(context: DragDropAdapterContext): void; } //#endregion //#region src/composables/useDragDrop/index.d.ts /** * Layout axis a drop zone resolves indices along. */ type Orientation = 'vertical' | 'horizontal'; /** * `MaybeRefOrGetter` plus Vue 3.5.42 `useTemplateRef` / `shallowReadonly` * results. Those wrap in a deep `Readonly>` that is not assignable * to `Ref`. */ type MaybeReadonlyRefOrGetter = MaybeRefOrGetter | { readonly value: unknown; }; /** * Discriminated payload describing what is being dragged. Consumers extend * this with concrete `type` literals plus a matching `value`. * * @example * ```ts * import type { DragType } from '@vuetify/v0' * * type Cards = * | { type: 'card', value: Card } * | { type: 'column', value: Column } * // Cards extends DragType — distributive over the union. * ``` */ interface DragType { type: string; value: unknown; } /** * Resolved drop slot inside an oriented zone. Surfaced via {@link DropPosition} * so consumers can render a between-children indicator against the resolved * child rect. * * @example * ```ts * import { useDragDrop } from '@vuetify/v0' * * const dnd = useDragDrop<{ type: 'card', value: Card }>() * const zone = dnd.zones.register({ el, accept: ['card'], orientation: 'vertical' }) * * const indicator = zone.indicator.value * if (indicator) { * const y = indicator.edge === 'before' * ? indicator.rect.top * : indicator.rect.bottom * const x = indicator.rect.left * const width = indicator.rect.width * // Render a 2px bar at (x, y) with `width` to mark drop slot `indicator.index`. * } * ``` */ interface DropIndicator { index: number; edge: 'before' | 'after'; rect: DOMRect; } /** * Position passed to drop hooks. `index` is populated for oriented zones; * unoriented zones receive only the pointer location. `indicator` is absent * when no slot was proposed: an empty zone resolves `index` to `0`, a drop on * a slot flanking the drag's own position resolves to that position (a stay). * * @example * ```ts * import { useDragDrop } from '@vuetify/v0' * * const dnd = useDragDrop<{ type: 'card', value: Card }>() * * dnd.zones.register({ * el, * accept: ['card'], * orientation: 'vertical', * onDrop: (drag, position) => { * const target = position.index ?? items.length * items.splice(target, 0, drag.value) * }, * }) * ``` */ interface DropPosition { pointer: { x: number; y: number; }; index?: number; indicator?: DropIndicator; } /** * Source modality for an active drag. Adapters declare their own value via * the `Extensible<...>` escape hatch (e.g., 'touch', 'gamepad'). */ type DragVia = Extensible<'pointer' | 'keyboard'>; /** * Active drag state. Distributive over `Z` so that narrowing `drag.type` also * narrows `drag.value` when `Z` is a discriminated union. * * @example * ```ts * import { useDragDrop } from '@vuetify/v0' * * type Cards = { type: 'card', value: Card } | { type: 'column', value: Column } * * const dnd = useDragDrop() * * dnd.zones.register({ * el, * onEnter: drag => { * if (drag.type === 'card') drag.value.title // narrowed to Card * }, * }) * ``` */ type ActiveDrag = Z extends DragType ? { id: ID; type: Z['type']; value: Z['value']; origin: { x: number; y: number; }; current: { x: number; y: number; }; delta: { x: number; y: number; }; over: ID | null; willAccept: boolean; via: DragVia; } : never; /** * Input shape for a draggable. Distributive over `Z` so unions narrow. * * @example * ```ts * import { useDragDrop } from '@vuetify/v0' * * const dnd = useDragDrop<{ type: 'card', value: Card }>() * * dnd.draggables.register({ * el: cardRef, * type: 'card', * value: card, * onBeforeStart: drag => !drag.value.locked, * }) * ``` */ type DraggableTicketInput = Z extends DragType ? RegistryTicketInput & { type: Z['type']; value: Z['value']; el: MaybeReadonlyRefOrGetter; disabled?: MaybeReadonlyRefOrGetter; onBeforeStart?: (drag: ActiveDrag) => boolean | void; onMove?: (drag: ActiveDrag) => void; onCancel?: (drag: ActiveDrag, reason: 'cancel' | 'reject') => void; } : never; /** * Output shape for a draggable. Distributive over `Z` so `ticket.type` * narrowing carries `ticket.value` to the matching union member. * * @example * ```ts * import { useDragDrop } from '@vuetify/v0' * * const dnd = useDragDrop<{ type: 'card', value: Card }>() * * const ticket = dnd.draggables.register({ el, type: 'card', value: card }) * * ticket.isDragging.value // boolean * ticket.value // Card * ``` */ type DraggableTicket = Z extends DragType ? RegistryTicket & { type: Z['type']; value: Z['value']; el: Readonly>; isDragging: Readonly>; } : never; /** * Input shape for a drop zone. * * @example * ```ts * import { useDragDrop } from '@vuetify/v0' * * const dnd = useDragDrop<{ type: 'card', value: Card }>() * * dnd.zones.register({ * el: listRef, * accept: ['card'], * orientation: 'vertical', * onDrop: (drag, position) => items.splice(position.index ?? 0, 0, drag.value), * }) * ``` */ interface DropZoneTicketInput extends RegistryTicketInput { el: MaybeReadonlyRefOrGetter; /** Allowed drag types or a synchronous predicate. Async predicates (Promise / thenable returns) are rejected with a warning — `accept` must return synchronously. */ accept?: Z['type'][] | ((drag: ActiveDrag) => boolean); orientation?: Orientation; disabled?: MaybeReadonlyRefOrGetter; onEnter?: (drag: ActiveDrag) => void; onLeave?: (drag: ActiveDrag) => void; onBeforeDrop?: (drag: ActiveDrag, position: DropPosition) => boolean | void; onDrop?: (drag: ActiveDrag, position: DropPosition) => void; } /** * Output shape for a drop zone. * * @example * ```ts * import { useDragDrop } from '@vuetify/v0' * * const dnd = useDragDrop<{ type: 'card', value: Card }>() * * const zone = dnd.zones.register({ el, accept: ['card'] }) * * zone.isOver.value // boolean * zone.willAccept.value // boolean * zone.indicator.value // DropIndicator | null * ``` */ interface DropZoneTicket extends RegistryTicket { el: Readonly>; isOver: Readonly>; willAccept: Readonly>; indicator: Readonly>; } /** * Plugin signature. Receives the public context, optionally returns a * disposer that runs on scope teardown. * * @example * ```ts * import { useDragDrop } from '@vuetify/v0' * import type { DragDropPlugin } from '@vuetify/v0' * * const logDrops: DragDropPlugin = context => { * const off = context.zones.on('register:ticket', ticket => console.log('zone', ticket.id)) * return () => off() * } * * const dnd = useDragDrop({ plugins: [logDrops] }) * ``` */ type DragDropPlugin = (context: DragDropContext) => (() => void) | void; /** * Options accepted by {@link useDragDrop}. * * @example * ```ts * import { useDragDrop, PointerAdapter } from '@vuetify/v0' * * const dnd = useDragDrop({ * adapters: [new PointerAdapter()], * onDrop: (drag, position) => console.log('drop', drag, position), * }) * ``` */ interface DragDropOptions { adapters?: DragDropAdapter[]; plugins?: DragDropPlugin[]; onBeforeStart?: (drag: ActiveDrag) => boolean | void; onMove?: (drag: ActiveDrag) => void; onBeforeDrop?: (drag: ActiveDrag, position: DropPosition) => boolean | void; onDrop?: (drag: ActiveDrag, position: DropPosition) => void; onCancel?: (drag: ActiveDrag, reason: 'cancel' | 'reject') => void; } /** * Registry context for draggable tickets, returned as `dnd.draggables` * from {@link useDragDrop}. * * @example * ```ts * import { useDragDrop } from '@vuetify/v0' * * const dnd = useDragDrop<{ type: 'card', value: Card }>() * * const ticket = dnd.draggables.register({ el, type: 'card', value: card }) * ``` */ interface DraggablesContext extends Omit, DraggableTicketInput & DraggableTicket>, 'register'> { register: (registration: DraggableTicketInput) => DraggableTicket; } /** * Registry context for drop zones, returned as `dnd.zones` * from {@link useDragDrop}. * * @example * ```ts * import { useDragDrop } from '@vuetify/v0' * * const dnd = useDragDrop<{ type: 'card', value: Card }>() * * const zone = dnd.zones.register({ el, accept: ['card'] }) * ``` */ interface ZonesContext extends Omit, DropZoneTicketInput & DropZoneTicket>, 'register'> { register: (registration: DropZoneTicketInput) => DropZoneTicket; } /** * Public context returned by {@link useDragDrop}. * * @example * ```ts * import { useDragDrop } from '@vuetify/v0' * * const dnd = useDragDrop<{ type: 'card', value: Card }>() * * dnd.active.value // ActiveDrag<{ type: 'card', value: Card }> | null * dnd.isDragging.value // boolean * dnd.cancel() // programmatic cancel * ``` */ interface DragDropContext { draggables: DraggablesContext; zones: ZonesContext; active: Readonly | null>>; isDragging: Readonly>; cancel: () => void; } /** * Create a headless drag-and-drop context. * * @param options - Adapters, plugins, and lifecycle hooks. All optional. * @returns A `DragDropContext` exposing `draggables` / `zones` registries, * the `active` drag, the `isDragging` boolean, and a programmatic `cancel()`. * * @see https://0.vuetifyjs.com/composables/system/use-drag-drop * * @example * ```ts * import { useDragDrop } from '@vuetify/v0' * import { useTemplateRef } from 'vue' * * const dnd = useDragDrop<{ type: 'card', value: string }>() * * const draggable = useTemplateRef('draggable') * const dropzone = useTemplateRef('dropzone') * * dnd.draggables.register({ el: draggable, type: 'card', value: 'card-1' }) * dnd.zones.register({ * el: dropzone, * accept: ['card'], * onDrop: (drag, position) => console.log(drag.value, position.index), * }) * ``` */ declare function useDragDrop(options?: DragDropOptions): DragDropContext; //#endregion //#region src/composables/useEventListener/index.d.ts type CleanupFunction = () => void; type EventHandler = (event: E) => void; /** * Attaches an event listener to the window. * * @param target The window object. * @param event The event to listen for. * @param listener The event listener. * @param options The event listener options. * @template E The event type. * @returns A function to remove the event listener. * * @see https://0.vuetifyjs.com/composables/system/use-event-listener */ declare function useEventListener(target: Window, event: MaybeRefOrGetter>, listener: MaybeRef void>>, options?: MaybeRefOrGetter): CleanupFunction; /** * Attaches an event listener to the document. * * @param target The document object. * @param event The event to listen for. * @param listener The event listener. * @param options The event listener options. * @template E The event type. * @returns A function to remove the event listener. * * @see https://0.vuetifyjs.com/composables/system/use-event-listener */ declare function useEventListener(target: Document, event: MaybeRefOrGetter>, listener: MaybeRef void>>, options?: MaybeRefOrGetter): CleanupFunction; /** * Attaches an event listener to an HTML element. * * @param target The HTML element. * @param event The event to listen for. * @param listener The event listener. * @param options The event listener options. * @template E The event type. * @returns A function to remove the event listener. * * @see https://0.vuetifyjs.com/composables/system/use-event-listener */ declare function useEventListener(target: MaybeRefOrGetter, event: MaybeRefOrGetter>, listener: MaybeRef void>>, options?: MaybeRefOrGetter): CleanupFunction; /** * Attaches an event listener to an event target. * * @param target The event target. * @param event The event to listen for. * @param listener The event listener. * @param options The event listener options. * @template EventType The event type. * @returns A function to remove the event listener. * * @see https://0.vuetifyjs.com/composables/system/use-event-listener */ declare function useEventListener(target: MaybeRefOrGetter, event: MaybeRefOrGetter>, listener: MaybeRef>>, options?: MaybeRefOrGetter): CleanupFunction; /** * Attaches an event listener to the window. * * @param event The event to listen for. * @param listener The event listener. * @param options The event listener options. * @template E The event type. * @returns A function to remove the event listener. * * @see https://0.vuetifyjs.com/composables/system/use-event-listener */ declare function useWindowEventListener(event: MaybeRefOrGetter>, listener: MaybeRef void>>, options?: MaybeRefOrGetter): CleanupFunction; /** * Attaches an event listener to the document. * * @param event The event to listen for. * @param listener The event listener. * @param options The event listener options. * @template E The event type. * @returns A function to remove the event listener. * * @see https://0.vuetifyjs.com/composables/system/use-event-listener */ declare function useDocumentEventListener(event: MaybeRefOrGetter>, listener: MaybeRef void>>, options?: MaybeRefOrGetter): CleanupFunction; //#endregion //#region src/composables/useFeatures/adapters/adapter.d.ts type FeaturesAdapterValue = boolean | { $value?: boolean; $variation?: unknown; }; type FeaturesAdapterFlags = Record; declare abstract class FeaturesAdapter { /** * Initialize the adapter and return initial flags. * * @param onUpdate Callback invoked when flags change. * @returns Initial feature flags. * * @remarks Called during plugin setup. Sets up change listeners * and returns the initial flag values. */ abstract setup(onUpdate: (flags: FeaturesAdapterFlags) => void): FeaturesAdapterFlags; /** * Cleanup adapter resources. * * @remarks Called when the plugin is disposed. */ dispose?(): void; } //#endregion //#region src/composables/useFeatures/index.d.ts /** * Input type for feature tickets - what users provide to register(). */ interface FeatureTicketInput extends GroupTicketInput {} /** * Output type for feature tickets - what users receive from get(). */ type FeatureTicket = GroupTicket; interface FeatureContext = FeatureTicket> extends Omit, 'register'> { /** * Get the variation value of a feature, or a fallback if not set. * * @param id The feature ID. * @param fallback The fallback value if the feature has no variation. * * @example * ```ts * const features = useFeatures() * features.variation('search', 'v1') // 'v2' or the fallback * ``` */ variation: (id: ID, fallback?: unknown) => unknown; /** * Sync feature flags from an external source. * * @param flags The flags to sync, typically from an adapter. * * @remarks This updates existing flags and registers new ones. * Use this when adapter flags change to update the registry. * * @example * ```ts * features.sync({ * checkout: true, * search: { $value: true, $variation: 'v2' }, * }) * ``` */ sync: (flags: FeaturesAdapterFlags) => void; /** * Register a feature (accepts input type, returns output type). * * @example * ```ts * features.register({ id: 'beta', value: false }) * ``` */ register: (registration?: Partial) => E; /** * Bulk-register multiple features in a single batch. * * @example * ```ts * features.onboard([ * { id: 'beta', value: false }, * { id: 'search', value: { $value: true, $variation: 'v2' } }, * ]) * ``` */ onboard: (registrations: Partial[]) => E[]; /** * Restore every registered flag to its registration default and clear all * recorded user intent (with `persist`, the stored overrides are cleared). * * @remarks Flags disabled after boot stay unselected until re-enabled — * selection ops are guarded on disabled tickets. * * @example * ```ts * const features = useFeatures() * features.toggle('beta') * features.reset() // 'beta' back to its registered default * ``` */ reset: () => void; /** External feature-flag adapter(s), when the plugin was installed with one. */ adapter?: MaybeArray; } interface FeatureOptions extends RegistryOptions { /** * Static feature flags to register. */ features?: Record; } interface FeatureContextOptions extends FeatureOptions { namespace?: string; } interface FeaturePluginOptions extends FeatureContextOptions { /** * Feature flag adapter for external services. * * @remarks Adapters provide dynamic flag values from external services. */ adapter?: MaybeArray; /** * Persist the user's feature-flag overrides to storage and restore them on load. * * @remarks Persists a delta of user-toggled flags relative to each flag's * registration default, shaped `{ enabled: ID[], disabled: ID[] }` — flags * the user never touched are not stored and keep following code defaults. * Toggling a flag back to its registration default drops it from the delta. * The storage key is the plugin namespace with the `v0:` prefix stripped * (`features`). * * On load the delta is applied only to its listed ids; flags that register * later (adapter or runtime registrations) receive their saved override at * registration time. Entries whose flag is not registered are skipped and * pruned from the next persist write. Restored overrides win over an * adapter's first snapshot; later adapter updates still overlay live remote * state. * * User intent is recorded through the context's `select` / `unselect` / * `toggle` methods; ticket self-methods (`ticket.toggle()`) and the bulk * `selectAll` / `unselectAll` / `toggleAll` operations bypass intent * tracking — their changes are not persisted and revert to defaults on * reload. Toggles on disabled flags no-op and record nothing. `reset()` * restores registration defaults in-session and clears the stored delta. * * @default false */ persist?: boolean; } /** * Creates a new features instance. * * @param options The options for the features instance. * @returns A new features instance. * * @see https://0.vuetifyjs.com/composables/plugins/use-features * * @example * ```ts * import { createFeatures } from '@vuetify/v0' * * const features = createFeatures({ * features: { * 'dark-mode': true, * 'theme-color': { $variation: 'blue' }, * }, * }) * ``` */ declare function createFeatures(_options?: FeatureOptions & { adapter?: MaybeArray; }): FeatureContext; declare const createFeaturesContext: <_E extends FeatureContext> = FeatureContext>>(_options?: FeaturePluginOptions | undefined) => ContextTrinity<_E>, createFeaturesPlugin: (_options?: (FeaturePluginOptions & Pick<{ namespace?: string; persist?: boolean; devtools?: boolean; }, "devtools">) | undefined) => Plugin, useFeatures: <_E extends FeatureContext> = FeatureContext>>(namespace?: string) => _E; //#endregion //#region src/composables/useFocusTrap/tabbable.d.ts /** * @module tabbable * @internal Second consumer is Treeview; promote to `#v0/utilities` if a third appears. * * @see https://0.vuetifyjs.com/composables/system/use-focus-trap * * @remarks * The "which descendants can Tab reach" rules, shared rather than duplicated. * * Shared by `useFocusTrap` (containment) and `Treeview/TreeviewList.vue` * (roving). Treeview imports this file directly so it does not evaluate * `useFocusTrap/index.ts` (nest stack). It layers its own `aria-disabled` and * treeitem-scope filters on top of {@link tabbable}. The barrel re-exports * `FOCUSABLE` and `tabbable` for public consumers; `isFocusTrapElement` and * {@link follows} stay local. */ /** * An element that can hold focus. `focus()` / `blur()` come from the * `HTMLOrSVGElement` mixin, so SVG content participates alongside HTML. */ type FocusTrapElement = HTMLElement | SVGElement; /** * Candidate tab stops, in document order. * * Every entry is a *potential* stop — negative `tabindex`, `disabled`, `inert`, * `hidden`, collapsed `
`, unchecked radios, and CSS-hidden are * disqualified in {@link tabbable} so one JS pass owns the rules and the * selector stays cheap. * * `input:not([type="hidden"])` is filtered here rather than in JS because it is * strictly cheaper. `button` / `select` / `textarea` carry no `:not([disabled])` * on purpose: property-only disabling and `fieldset[disabled]` inheritance are * invisible to an attribute selector, so disabled state is resolved in JS. * * Deliberately absent: `label` and `fieldset` (not focusable), `[draggable]` * (not focusable), `svg[focusable]` (a dead SVG 1.1 attribute). */ declare const FOCUSABLE: string; /** * Whether a {@link FOCUSABLE} candidate is actually reachable by Tab. * * `aria-disabled="true"` is deliberately **not** filtered: per APG an * aria-disabled control stays in the tab order, so dropping it would let the * browser walk past the computed boundary and out of a trap. * `Treeview/TreeviewList.vue` excludes it for the opposite reason — roving focus * must skip disabled items — so the two filters diverge on purpose, and * Treeview layers that rule on top of this one. */ declare function tabbable(el: Element): el is FocusTrapElement; //#endregion //#region src/composables/useFocusTrap/index.d.ts interface UseFocusTrapOptions { /** * Reactive activation source. When it flips true the trap engages and focuses * into the root; when it flips false the trap releases and restores focus. * * Omit it entirely to drive the trap imperatively. * * @remarks * This is a *source*, not the state — `isActive` is the state. An imperative * `activate()` / `deactivate()` overrides the source until its next * transition. See {@link useFocusTrap} for the full precedence rule. * * @example * ```ts * useFocusTrap(panel, { active: () => dialog.isOpen.value }) * ``` */ active?: MaybeRefOrGetter; /** * Where focus lands when the trap engages. * * - omitted — the first tabbable descendant, falling back to the root * - `false` — nothing is focused; the first Tab pulls focus in instead * - an element / ref / getter — that node is focused directly. If it cannot * take focus, the first tabbable descendant (or the root) is used instead * * @example * ```ts * const search = useTemplateRef('search') * * useFocusTrap(panel, { initial: search }) // autofocus a specific control * useFocusTrap(panel, { initial: false }) // no autofocus at all * ``` */ initial?: false | Exclude; /** * Return focus to the element that was focused before activation. * * Skipped when focus already sits on an outside control by the time the trap * releases — closing a dialog must not steal focus back from whatever the * user just clicked. A blur to `` still restores. * * @default true * * @example * ```ts * useFocusTrap(panel, { restore: false }) * ``` */ restore?: boolean; /** * Bind the capture-phase `keydown` listener on `document`. * * Set `false` when a consumer-owned listener will call {@link UseFocusTrapReturn.onKeydown} * itself — otherwise the document listener has already wrapped by the time a * root handler runs. A `listen: false` trap is not pushed onto the nest stack. * * @default true * * @example * ```ts * const trap = useFocusTrap(panel, { active: isOpen, listen: false }) * * function onPanelKeydown (event: KeyboardEvent) { * if (editorHasFocus.value && event.key === 'Tab') return * * trap.onKeydown(event) * } * ``` */ listen?: boolean; /** * Invoked on Escape while this trap is the last *connected* trap that has * `onEscape` and owns focus. * * Opt-in and side-effect free: the trap never calls `preventDefault()` and * never deactivates itself. An inner Tab-only trap (no `onEscape`) does not * eat Escape — it falls through to the next connected trap that has a * handler. Gate on a `useStack` ticket when dismissal policy is overlay-stack, * not trap-stack. * * @example * ```ts * const ticket = stack.register({ onDismiss: () => (isOpen.value = false) }) * * useFocusTrap(panel, { * active: isOpen, * onEscape: event => { * if (!ticket.globalTop.value) return * event.preventDefault() * isOpen.value = false * }, * }) * ``` */ onEscape?: (event: KeyboardEvent) => void; } interface UseFocusTrapReturn { /** * Whether the trap is currently engaged */ readonly isActive: Readonly>; /** * Engage the trap: capture the focused element for a later restore, bind * containment, and focus into the root once it exists. No-op when already * engaged, so it never overwrites the captured restore target. * * @remarks * The document listener binds on the next flush, so a Tab dispatched * synchronously in the same tick as this call is not yet intercepted. Awaiting * a tick — or letting Vue drive the trap through `options.active` — avoids it. */ activate: () => void; /** * Release the trap and restore focus. No-op when not engaged. */ deactivate: () => void; /** * The keydown handler. Bound on `document` in the capture phase while the * trap is engaged unless {@link UseFocusTrapOptions.listen} is `false`. * * @example * ```ts * const trap = useFocusTrap(panel, { active: isOpen, listen: false }) * * function onPanelKeydown (event: KeyboardEvent) { * trap.onKeydown(event) * } * ``` */ onKeydown: (event: KeyboardEvent) => void; } /** * Confines Tab / Shift+Tab to the subtree of `target`. * * @param target The trap root. Accepts a template ref, getter, component instance, or raw element. Give it `tabindex="-1"` if it can ever contain zero tabbable descendants. * @param options Configuration options. * @returns The trap's reactive state and controls. * * @remarks * **Why the listener is on `document`.** A root-bound listener stops firing the * moment focus leaves the subtree — a backdrop click that blurs to ``, or * a stray programmatic `focus()` — and the trap is then dead with no way back. * Binding at the document in the capture phase means an escaped focus is * recovered on the next Tab, and containment survives an inner * `stopPropagation()`. * * **Only the boundaries are intercepted.** Mid-list Tab presses pass straight * through untouched, so an inner widget keeps full control of its own Tab * handling everywhere except the first and last stop. * * **Precedence.** `options.active` is a source; `isActive` is the state. The * source's transitions call `activate()` / `deactivate()`, while imperative * calls write the state directly and never write back to the source. Calling * `deactivate()` while the `active` getter still returns `true` therefore stays * deactivated until `active` next transitions false → true. * * **Ordering.** Candidates are collected in document order. Positive `tabindex` * values are not re-sorted into their real tab position — they are an * anti-pattern the trap declines to optimize for. * * **Shadow DOM and iframes.** Containment pierces open shadow roots, but * discovery cannot (`querySelectorAll` does not cross the boundary). If the last * tab stop lives inside a descendant's shadow root, focus can still leave on * Tab. The same applies to `