Types
Shared TypeScript types used across the library and available for your own code.
import type { ID, Activation, DeepPartial, Extensible, MaybeArray } from '@vuetify/v0'ID
Identifier type used throughout the registry system. All tickets, items, and registrable entities use this for their id property.
type ID = string | numberconst id: ID = 'item-1' // string
const id: ID = 42 // numberActivation
Keyboard activation mode for navigable components.
type Activation = 'automatic' | 'manual'automatic — selection follows focus. Arrow keys select immediately. This is the WAI-ARIA standard for radio groups.
manual — arrow keys move focus only. Enter or Space is required to select. Use for toolbars or when deliberate selection is preferred.
<template>
<Radio.Group v-model="selected" activation="manual">
<Radio.Root value="a">Option A</Radio.Root>
</Radio.Group>
</template>DeepPartial
Recursively makes all properties of T optional. Used by mergeDeep to type partial source objects.
type DeepPartial<T> = T extends object ? {
[P in keyof T]?: DeepPartial<T[P]>;
} : Ttype User = { name: string; address: { city: string } }
type PartialUser = DeepPartial<User>
// { name?: string; address?: { city?: string } }Extensible
Preserves string literal autocomplete while allowing arbitrary strings. TypeScript normally collapses 'a' | 'b' | string into just string, losing IDE autocomplete. This type uses the string & {} trick to prevent that collapse.
type Extensible<T extends string> = T | (string & {})Use for extensible APIs where you want autocomplete for known values but still accept custom strings — event names, theme tokens, CSS classes, etc.
type Color = 'red' | 'blue' | 'green'
// WITHOUT Extensible — autocomplete lost
type BadColor = Color | string // collapses to just `string`
// WITH Extensible — autocomplete preserved
type GoodColor = Extensible<Color>
function setColor(c: GoodColor) {}
setColor('red') // autocomplete suggests 'red' | 'blue' | 'green'
setColor('purple') // also OK — custom value acceptedMaybeArray
Union type that accepts either a single value or an array. Use for APIs that accept both forms.
type MaybeArray<T> = T | T[]function process(input: MaybeArray<string>) { ... }
process('single') // OK
process(['a', 'b', 'c']) // OKDOMElement
Valid element types for Vue’s h() render function. Includes HTML tag names, component definitions, and functional components. Used by the Atom component for polymorphic rendering.
type DOMElement = Parameters<typeof h>[0]GenericObject / UnknownObject
Two record types for different safety levels:
type GenericObject = Record<string, any>
type UnknownObject = Record<string, unknown>Prefer UnknownObject — it requires type narrowing and catches more bugs at compile time.