diff --git a/src/runtime/types/utils.ts b/src/runtime/types/utils.ts index 9c31526d..4590b4de 100644 --- a/src/runtime/types/utils.ts +++ b/src/runtime/types/utils.ts @@ -1,6 +1,14 @@ -export type DeepPartial = Partial<{ - [P in keyof T]: DeepPartial | { [key: string]: string | object } -}> +export interface TightMap { + [key: string]: TightMap | O +} + +export type DeepPartial = { + [P in keyof T]?: T[P] extends object + ? DeepPartial + : T[P]; +} & { + [key: string]: O | TightMap +} export type DynamicSlots = Record & (Slot extends string ? Record : Record) diff --git a/src/templates.ts b/src/templates.ts index a7d5a7e3..92a73d06 100644 --- a/src/templates.ts +++ b/src/templates.ts @@ -101,7 +101,7 @@ type AppConfigUI = { gray?: 'slate' | 'cool' | 'zinc' | 'neutral' | 'stone' } icons?: Partial -} & DeepPartial +} & DeepPartial declare module 'nuxt/schema' { interface AppConfigInput {