Skip to content

CheckboxGroup label slot type missing in app.config.ts #6337

@leosin

Description

@leosin

Environment

│ │ │
│ │ Operating system macOS 24.6.0 │
│ │ CPU Apple M4 Max (16 cores) │
│ │ Node.js version v22.18.0 │
│ │ nuxt/cli version 3.34.0 │
│ │ Package manager pnpm 10.31.0 │
│ │ Nuxt version 4.4.2 │
│ │ Nitro version 2.13.3 │
│ │ Builder vite 7.3.2 │
│ │ Config app, compatibilityDate, content, css, devtools, eslint, hooks, │
│ │ imports, modules, ui, vite │
│ │ Modules @nuxt/eslint 1.15.2, @nuxt/ui 4.6.1, @nuxt/eslint 1.15.2, │
│ │ @nuxt/content 3.12.0, @vueuse/nuxt 14.2.1 │
│ │ │

Is this bug related to Nuxt or Vue?

Nuxt

Package

v4.x

Version

v4.6.1

Reproduction

https://ui.nuxt.com/docs/components/checkbox-group#theme

In app.config.ts:

export default defineAppConfig({
  ui: {
    checkboxGroup: {
      slots: {
        label: 'font-normal' // ❌ Type error: label not found
      }
    }
  }
})

In component template:

<EzCheckboxGroup
  :ui="{ label: 'font-normal' }"
/>

The above works as expected at runtime, and the label style is applied correctly.

Expected Behavior
The label field should be properly typed and available in slots when configuring via app.config.ts.

Actual Behavior
TypeScript does not recognize label in slots, causing a type error, even though it works at runtime.

Description

I encountered a type inconsistency issue with the CheckboxGroup component in Nuxt UI v4.6.1.

When defining UI configuration in app.config.ts, the label field is not recognized in the slots type. However, the same label field works correctly when used directly in the component template.

Additional context

This suggests a mismatch between runtime behavior and type definitions. Possibly the slots typing is incomplete or missing the label field.

Logs

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingtriageAwaiting initial review and prioritizationv4#4488

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions