diff --git a/.github/ISSUE_TEMPLATE/bug-report-v3.yml b/.github/ISSUE_TEMPLATE/bug-report-v3.yml deleted file mode 100644 index d50818255c..0000000000 --- a/.github/ISSUE_TEMPLATE/bug-report-v3.yml +++ /dev/null @@ -1,69 +0,0 @@ -name: "🐛 Bug report (v3)" -description: Report a bug to help us improve the module (v3 only). -labels: ["triage", "bug", "v3"] -body: - - type: markdown - attributes: - value: | - Before reporting a bug, please make sure that you have read through our [documentation](https://ui.nuxt.com/) and existing [issues](https://github.com/nuxt/ui/issues?q=is%3Aissue%20is%3Aopen%20sort%3Aupdated-desc%20label%3Av3). - - type: textarea - id: env - attributes: - label: Environment - description: You can use `npx nuxt info` to fill this section - placeholder: | - - Operating System: `Darwin` - - Node Version: `v18.16.0` - - Nuxt Version: `3.7.3` - - CLI Version: `3.8.4` - - Nitro Version: `2.6.3` - - Package Manager: `pnpm@8.7.4` - - Builder: `-` - - User Config: `-` - - Runtime Modules: `-` - - Build Modules: `-` - validations: - required: true - - type: dropdown - id: package - attributes: - label: Is this bug related to Nuxt or Vue? - options: - - Nuxt - - Vue - validations: - required: true - - type: input - id: version - attributes: - label: Version - placeholder: v3.0.0 - validations: - required: true - - type: textarea - id: reproduction - attributes: - label: Reproduction - description: Please provide a reproduction link using the Nuxt template https://codesandbox.io/p/devbox/nuxt-ui3-n3sxks or the Vue template https://codesandbox.io/p/devbox/nuxt-ui3-vue-4h5gqn. A minimal [reproduction is required](https://antfu.me/posts/why-reproductions-are-required) unless you are absolutely sure that the issue is obvious and the provided information is enough to understand the problem. If a report is vague (e.g. just a generic error message) and has no reproduction, it will receive a "needs reproduction" label. If no reproduction is provided, it will be closed automatically after a while. - placeholder: https://github.com/my/reproduction - validations: - required: true - - type: textarea - id: description - attributes: - label: Description - description: A clear and concise description of what the bug is. If you intend to submit a PR for this issue, tell us in the description. - validations: - required: true - - type: textarea - id: additonal - attributes: - label: Additional context - description: If applicable, add any other context or screenshots here. - - type: textarea - id: logs - attributes: - label: Logs - description: | - Optional if provided reproduction. Please try not to insert an image but copy paste the log text. - render: shell-script diff --git a/.github/ISSUE_TEMPLATE/bug-report.yml b/.github/ISSUE_TEMPLATE/bug-report.yml index 349fbe4bed..4cc157e7f7 100644 --- a/.github/ISSUE_TEMPLATE/bug-report.yml +++ b/.github/ISSUE_TEMPLATE/bug-report.yml @@ -5,7 +5,7 @@ body: - type: markdown attributes: value: | - Before reporting a bug, please make sure that you have read through our [documentation](https://ui2.nuxt.com) and existing [issues](https://github.com/nuxt/ui/issues?q=is%3Aissue+is%3Aopen+sort%3Aupdated-desc). + Before reporting a bug, please make sure that you have read through our [documentation](https://ui.nuxt.com/) and existing [issues](https://github.com/nuxt/ui/issues?q=is%3Aissue%20is%3Aopen%20sort%3Aupdated-desc). - type: textarea id: env attributes: @@ -13,30 +13,39 @@ body: description: You can use `npx nuxt info` to fill this section placeholder: | - Operating System: `Darwin` - - Node Version: `v18.16.0` - - Nuxt Version: `3.7.3` - - CLI Version: `3.8.4` - - Nitro Version: `2.6.3` - - Package Manager: `pnpm@8.7.4` + - Node Version: `v24.3.0` + - Nuxt Version: `4.0.3` + - CLI Version: `3.27.0` + - Nitro Version: `2.12.4` + - Package Manager: `pnpm@10.13.1` - Builder: `-` - User Config: `-` - Runtime Modules: `-` - Build Modules: `-` validations: required: true + - type: dropdown + id: package + attributes: + label: Is this bug related to Nuxt or Vue? + options: + - Nuxt + - Vue + validations: + required: true - type: input id: version attributes: - label: Version - placeholder: v2.20.0 + label: Version (@nuxt/ui) + placeholder: v4.0.0 validations: required: true - type: textarea id: reproduction attributes: label: Reproduction - description: Please provide a reproduction link using this template https://stackblitz.com/edit/nuxt-ui. A minimal [reproduction is required](https://antfu.me/posts/why-reproductions-are-required) unless you are absolutely sure that the issue is obvious and the provided information is enough to understand the problem. If a report is vague (e.g. just a generic error message) and has no reproduction, it will receive a "needs reproduction" label. If no reproduction is provided we might close it. - placeholder: https://stackblitz.com/edit/nuxt-ui + description: Please provide a reproduction link using the Nuxt template https://codesandbox.io/p/devbox/nuxt-ui3-n3sxks or the Vue template https://codesandbox.io/p/devbox/nuxt-ui3-vue-4h5gqn. A minimal [reproduction is required](https://antfu.me/posts/why-reproductions-are-required) unless you are absolutely sure that the issue is obvious and the provided information is enough to understand the problem. If a report is vague (e.g. just a generic error message) and has no reproduction, it will receive a "needs reproduction" label. If no reproduction is provided, it will be closed automatically after a while. + placeholder: https://github.com/my/reproduction validations: required: true - type: textarea diff --git a/.github/ISSUE_TEMPLATE/feature-request-v3.yml b/.github/ISSUE_TEMPLATE/feature-request-v3.yml deleted file mode 100644 index 89596ac75f..0000000000 --- a/.github/ISSUE_TEMPLATE/feature-request-v3.yml +++ /dev/null @@ -1,20 +0,0 @@ -name: "🚀 Feature request (v3)" -description: Suggest an idea or enhancement for the module (v3 only). -labels: ["triage", "enhancement", "v3"] -body: - - type: markdown - attributes: - value: | - Before requesting a feature, please make sure that you have read through our [documentation](https://ui.nuxt.com/) and existing [issues](https://github.com/nuxt/ui/issues?q=is%3Aissue%20is%3Aopen%20sort%3Aupdated-desc%20label%3Av3). - - type: textarea - id: description - attributes: - label: Description - description: A clear and concise description of what you think would be an helpful addition to the module, including the possible use cases and alternatives you have considered. If you have a working prototype or module that implements it, please include a link. - validations: - required: true - - type: textarea - id: additonal - attributes: - label: Additional context - description: If applicable, add any other context or screenshots here. diff --git a/.github/ISSUE_TEMPLATE/feature-request.yml b/.github/ISSUE_TEMPLATE/feature-request.yml index 92ad15b4fd..b82b7c7666 100644 --- a/.github/ISSUE_TEMPLATE/feature-request.yml +++ b/.github/ISSUE_TEMPLATE/feature-request.yml @@ -5,7 +5,7 @@ body: - type: markdown attributes: value: | - Before requesting a feature, please make sure that you have read through our [documentation](https://ui2.nuxt.com) and existing [issues](https://github.com/nuxt/ui/issues?q=is%3Aissue+is%3Aopen+sort%3Aupdated-desc). + Before requesting a feature, please make sure that you have read through our [documentation](https://ui.nuxt.com/) and existing [issues](https://github.com/nuxt/ui/issues?q=is%3Aissue%20is%3Aopen%20sort%3Aupdated-desc). - type: textarea id: description attributes: diff --git a/.github/ISSUE_TEMPLATE/question-v3.yml b/.github/ISSUE_TEMPLATE/question-v3.yml deleted file mode 100644 index 149c749be9..0000000000 --- a/.github/ISSUE_TEMPLATE/question-v3.yml +++ /dev/null @@ -1,14 +0,0 @@ -name: "💬 Question (v3)" -description: Ask a question about the module (v3 only). -labels: ["question", "v3"] -body: - - type: markdown - attributes: - value: | - Before asking a question, please make sure that you have read through our [documentation](https://ui.nuxt.com/) and existing [issues](https://github.com/nuxt/ui/issues?q=is%3Aissue%20is%3Aopen%20sort%3Aupdated-desc%20label%3Av3). - - type: textarea - id: description - attributes: - label: Description - validations: - required: true diff --git a/.github/ISSUE_TEMPLATE/question.yml b/.github/ISSUE_TEMPLATE/question.yml index 8472116d61..b576de1cd1 100644 --- a/.github/ISSUE_TEMPLATE/question.yml +++ b/.github/ISSUE_TEMPLATE/question.yml @@ -5,7 +5,7 @@ body: - type: markdown attributes: value: | - Before asking a question, please make sure that you have read through our [documentation](https://ui2.nuxt.com) and existing [issues](https://github.com/nuxt/ui/issues?q=is%3Aissue+is%3Aopen+sort%3Aupdated-desc). + Before asking a question, please make sure that you have read through our [documentation](https://ui.nuxt.com/) and existing [issues](https://github.com/nuxt/ui/issues?q=is%3Aissue%20is%3Aopen%20sort%3Aupdated-desc). - type: textarea id: description attributes: diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml deleted file mode 100644 index 6bab34f4b0..0000000000 --- a/.github/workflows/docs.yml +++ /dev/null @@ -1,47 +0,0 @@ -name: docs - -on: push - -jobs: - deploy: - runs-on: ${{ matrix.os }} - - permissions: - contents: read - id-token: write - - strategy: - matrix: - os: [ubuntu-latest] # macos-latest, windows-latest - node: [22] - - env: - NUXT_GITHUB_TOKEN: ${{ secrets.NUXT_GITHUB_TOKEN }} - - steps: - - uses: actions/checkout@v5 - with: - fetch-depth: 0 - - - name: Install pnpm - uses: pnpm/action-setup@v4 - - - name: Install node - uses: actions/setup-node@v4 - with: - node-version: ${{ matrix.node }} - cache: pnpm - - - name: Install dependencies - run: pnpm install - - - name: Prepare build - run: pnpm run dev:prepare - - - name: Deploy to NuxtHub - uses: nuxt-hub/action@v2 - env: - NODE_OPTIONS: '--max-old-space-size=8192' - with: - project-key: ui-7eg3 - directory: docs diff --git a/.github/workflows/module.yml b/.github/workflows/module.yml index 395cbc9b23..1685d4408e 100644 --- a/.github/workflows/module.yml +++ b/.github/workflows/module.yml @@ -3,10 +3,10 @@ name: module on: push: branches: - - v3 + - v4 pull_request: branches: - - v3 + - v4 jobs: build: @@ -58,10 +58,10 @@ jobs: - name: Build run: pnpm run build - - name: Build playground + - name: Build Nuxt playground run: pnpm run dev:build - - name: Build playground (vue) + - name: Build Vue playground run: pnpm run dev:vue:build - name: Publish @@ -69,14 +69,14 @@ jobs: if: matrix.os == 'ubuntu-latest' run: pnpx pkg-pr-new publish --compact --no-template --pnpm - playground: + playground-nuxt: needs: build runs-on: ${{ matrix.os }} defaults: run: - working-directory: ./playground + working-directory: ./playgrounds/nuxt permissions: contents: read @@ -205,58 +205,3 @@ jobs: - name: Build run: pnpm run build - - nuxt-ui-pro: - needs: build - - # Only run this job if not a fork PR (when push event or PR from same repo) - if: github.event_name == 'push' || github.event.pull_request.head.repo.full_name == github.repository - - runs-on: ${{ matrix.os }} - - permissions: - contents: read - pull-requests: read - - strategy: - matrix: - os: [ubuntu-latest] # macos-latest, windows-latest - node: [22] - - env: - NUXT_UI_PRO_LICENSE: ${{ secrets.NUXT_UI_PRO_LICENSE }} - - steps: - - name: Checkout - uses: actions/checkout@v5 - with: - repository: nuxt/ui-pro - token: ${{ secrets.NUXT_GITHUB_TOKEN }} - - - name: Store commit SHA - run: | - echo "COMMIT_SHA=$(echo ${{ github.event.pull_request.head.sha || github.sha }} | cut -c1-7)" >> $GITHUB_ENV - - - name: Install pnpm - uses: pnpm/action-setup@v4 - - - name: Install node - uses: actions/setup-node@v4 - with: - node-version: 22 - cache: pnpm - - - name: Install latest nuxt/ui - run: pnpm install https://pkg.pr.new/@nuxt/ui@${{ env.COMMIT_SHA }} --lockfile-only - - - name: Install dependencies - run: pnpm install - - - name: Prepare - run: pnpm run dev:prepare - - - name: Typecheck - run: pnpm run typecheck - - - name: Build - run: pnpm run build diff --git a/.github/workflows/playground.yml b/.github/workflows/playground.yml deleted file mode 100644 index ca933b8e16..0000000000 --- a/.github/workflows/playground.yml +++ /dev/null @@ -1,45 +0,0 @@ -name: playground - -on: - push: - branches: - - v3 - -jobs: - deploy: - runs-on: ${{ matrix.os }} - - permissions: - contents: read - id-token: write - - strategy: - matrix: - os: [ubuntu-latest] # macos-latest, windows-latest - node: [22] - - steps: - - uses: actions/checkout@v5 - - - name: Install pnpm - uses: pnpm/action-setup@v4 - - - name: Install node - uses: actions/setup-node@v4 - with: - node-version: ${{ matrix.node }} - cache: pnpm - - - name: Install dependencies - run: pnpm install - - - name: Prepare build - run: pnpm run dev:prepare - - - name: Deploy to NuxtHub - uses: nuxt-hub/action@v2 - env: - NODE_OPTIONS: '--max-old-space-size=8192' - with: - project-key: ui3-playground-pb9b - directory: playground diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index ba369e8269..4bc873154d 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -3,7 +3,7 @@ name: release on: push: tags: - - 'v3*' + - 'v4*' jobs: publish: diff --git a/.gitignore b/.gitignore index a64c2c531f..791af041b7 100644 --- a/.gitignore +++ b/.gitignore @@ -26,7 +26,7 @@ logs .env.* !.env.example -playground-vue/auto-imports.d.ts -playground-vue/components.d.ts -playground-vue/tsconfig.app.tsbuildinfo -playground-vue/tsconfig.node.tsbuildinfo +playgrounds/vue/auto-imports.d.ts +playgrounds/vue/components.d.ts +playgrounds/vue/tsconfig.app.tsbuildinfo +playgrounds/vue/tsconfig.node.tsbuildinfo diff --git a/.nuxtrc b/.nuxtrc index a337991d12..eb1e48d30c 100644 --- a/.nuxtrc +++ b/.nuxtrc @@ -1 +1,2 @@ experimental.normalizeComponentNames=false +modules[]=@nuxt/content diff --git a/CHANGELOG.md b/CHANGELOG.md index ae01f74445..303ac94896 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,30 @@ # Changelog +## [4.0.0-alpha.0](https://github.com/nuxt/ui/compare/v3.3.2...v4.0.0-alpha.0) (2025-08-15) + +### ⚠ BREAKING CHANGES + +* **PageAccordion:** remove in favor of `Accordion` (#4734) +* **Marquee:** rename from `PageMarquee` (#4741) +* **FieldGroup:** rename from `ButtonGroup` (#4596) +* **components:** upgrade `ai-sdk` to v5 (#4698) + +### Features + +* **components:** upgrade `ai-sdk` to v5 ([#4698](https://github.com/nuxt/ui/issues/4698)) ([9545fdd](https://github.com/nuxt/ui/commit/9545fddec8ba88bbf523cdb26672129adc5ed4f3)) +* **FieldGroup:** rename from `ButtonGroup` ([#4596](https://github.com/nuxt/ui/issues/4596)) ([8aa96d1](https://github.com/nuxt/ui/commit/8aa96d1a04c66bd5796bebed75709015e1e2b684)) +* import `@nuxt/ui-pro` components ([#4675](https://github.com/nuxt/ui/issues/4675)) ([f6ae153](https://github.com/nuxt/ui/commit/f6ae1534280818ff6a8a4c967ae589e0f715ddbe)) +* **Marquee:** rename from `PageMarquee` ([#4741](https://github.com/nuxt/ui/issues/4741)) ([0a4d9b4](https://github.com/nuxt/ui/commit/0a4d9b4dd35703f884b740eab2bfcc6e0d11f870)) +* **PageAccordion:** remove in favor of `Accordion` ([#4734](https://github.com/nuxt/ui/issues/4734)) ([1c63aab](https://github.com/nuxt/ui/commit/1c63aab7eb21a5d2fb0a7c69725f0e7490c88ebd)) + +### Bug Fixes + +* **AuthForm:** use `error` from form field ([#4738](https://github.com/nuxt/ui/issues/4738)) ([314e661](https://github.com/nuxt/ui/commit/314e661774ae300a2b7d6f704e815cf571d67e34)) +* **BlogPost:** ensure date slot renders ([#4743](https://github.com/nuxt/ui/issues/4743)) ([44e0178](https://github.com/nuxt/ui/commit/44e0178d27e175661a504b7f0137a99457492b8c)) +* **ContentSearch/DashboardSearch:** make `ui.modal` work ([99d3227](https://github.com/nuxt/ui/commit/99d32279f330a9e655e66d015bd1238737dedcb8)) +* **PageCard:** improve keyboard accessibility ([#4733](https://github.com/nuxt/ui/issues/4733)) ([6606fa3](https://github.com/nuxt/ui/commit/6606fa35b3dba6be3096e0e3090aab406dc6d0cc)) +* **ProseImg:** ensure unique motion layout id for images ([#4720](https://github.com/nuxt/ui/issues/4720)) ([841c369](https://github.com/nuxt/ui/commit/841c369d30641fe534d1f715cc144b04eaa2fa1c)) + ## [3.3.2](https://github.com/nuxt/ui/compare/v3.3.1...v3.3.2) (2025-08-14) ## [3.3.1](https://github.com/nuxt/ui/compare/v3.3.0...v3.3.1) (2025-08-14) diff --git a/README.md b/README.md index 90be7d2c6a..73ee65fc93 100644 --- a/README.md +++ b/README.md @@ -14,32 +14,28 @@ Nuxt UI harnesses the combined strengths of [Reka UI](https://reka-ui.com/), [Tailwind CSS](https://tailwindcss.com/), and [Tailwind Variants](https://www.tailwind-variants.org/) to offer developers an unparalleled set of tools for creating sophisticated, accessible, and highly performant user interfaces. > [!NOTE] -> You are on the `v3` development branch, check out the [v2 branch](https://github.com/nuxt/ui/tree/v2) for Nuxt UI v2. - -> [!TIP] -> **Looking for more components ?** -> Check out [Nuxt UI Pro](https://ui.nuxt.com/pro), a collection of premium Vue components, composables, and utilities built on top of Nuxt UI for faster and more powerful app development. +> You are on the `v4` development branch, check out the [v2 branch](https://github.com/nuxt/ui/tree/v2) for Nuxt UI v2. ## Documentation -Visit https://ui.nuxt.com to explore the documentation. +Visit https://ui4.nuxt.com to explore the documentation. ## Installation ```bash [pnpm] -pnpm add @nuxt/ui +pnpm add @nuxt/ui@alpha ``` ```bash [yarn] -yarn add @nuxt/ui +yarn add @nuxt/ui@alpha ``` ```bash [npm] -npm install @nuxt/ui +npm install @nuxt/ui@alpha ``` ```bash [bun] -bun add @nuxt/ui +bun add @nuxt/ui@alpha ``` ### Nuxt @@ -59,7 +55,7 @@ export default defineNuxtConfig({ @import "@nuxt/ui"; ``` -Learn more in the [installation guide](https://ui.nuxt.com/getting-started/installation/nuxt). +Learn more in the [installation guide](https://ui4.nuxt.com/docs/getting-started/installation/nuxt). ### Vue @@ -106,18 +102,18 @@ app.mount('#app') @import "@nuxt/ui"; ``` -Learn more in the [installation guide](https://ui.nuxt.com/getting-started/installation/vue). +Learn more in the [installation guide](https://ui4.nuxt.com/docs/getting-started/installation/vue). ## Contribution Thank you for considering contributing to Nuxt UI. Here are a few ways you can get involved: - Reporting Bugs: If you come across any bugs or issues, please check out the reporting bugs guide to learn how to submit a bug report. -- Suggestions: Have any thoughts to enhance Nuxt UI? We'd love to hear them! Check out the [contribution guide](https://ui.nuxt.com/getting-started/contribution) to share your suggestions. +- Suggestions: Have any thoughts to enhance Nuxt UI? We'd love to hear them! Check out the [contribution guide](https://ui4.nuxt.com/docs/getting-started/contribution) to share your suggestions. ## Local Development -Follow the docs to [set up your local development environment](https://ui.nuxt.com/getting-started/contribution#local-development) and contribute. +Follow the docs to [set up your local development environment](https://ui4.nuxt.com/docs/getting-started/contribution#local-development) and contribute. ## Credits @@ -131,7 +127,7 @@ Follow the docs to [set up your local development environment](https://ui.nuxt.c ## License -Licensed under the [MIT license](https://github.com/nuxt/ui/blob/v3/LICENSE.md). +Licensed under the [MIT license](https://github.com/nuxt/ui/blob/v4/LICENSE.md). [npm-version-src]: https://img.shields.io/npm/v/@nuxt/ui/latest.svg?style=flat&colorA=18181B&colorB=28CF8D @@ -141,7 +137,7 @@ Licensed under the [MIT license](https://github.com/nuxt/ui/blob/v3/LICENSE.md). [npm-downloads-href]: https://npm.chart.dev/@nuxt/ui [license-src]: https://img.shields.io/github/license/nuxt/ui.svg?style=flat&colorA=18181B&colorB=28CF8D -[license-href]: https://github.com/nuxt/ui/blob/v3/LICENSE.md +[license-href]: https://github.com/nuxt/ui/blob/v4/LICENSE.md [nuxt-src]: https://img.shields.io/badge/Nuxt-18181B?logo=nuxt.js [nuxt-href]: https://nuxt.com diff --git a/cli/commands/make/component.mjs b/cli/commands/make/component.mjs index f668fe8ac8..cebe3e455e 100644 --- a/cli/commands/make/component.mjs +++ b/cli/commands/make/component.mjs @@ -21,17 +21,13 @@ export default defineCommand({ type: 'boolean', description: 'Create a primitive component.' }, - pro: { - type: 'boolean', - description: 'Create a pro component.' - }, prose: { type: 'boolean', - description: 'Create a prose component (with --pro).' + description: 'Create a prose component.' }, content: { type: 'boolean', - description: 'Create a content component (with --pro).' + description: 'Create a content component.' }, template: { type: 'string', @@ -45,15 +41,6 @@ export default defineCommand({ process.exit(1) } - if (args.prose && !args.pro) { - consola.error('`--prose` flag can only be used with `--pro` flag!') - process.exit(1) - } - if (args.content && !args.pro) { - consola.error('`--content` flag can only be used with `--pro` flag!') - process.exit(1) - } - const path = resolve('.') for (const template of Object.keys(templates)) { diff --git a/cli/templates.mjs b/cli/templates.mjs index f50ac8f053..ab9094a4de 100644 --- a/cli/templates.mjs +++ b/cli/templates.mjs @@ -1,14 +1,12 @@ import { splitByCase, upperFirst, camelCase, kebabCase } from 'scule' -const playground = ({ name, pro }) => { +const playground = ({ name }) => { const upperName = splitByCase(name).map(p => upperFirst(p)).join('') const kebabName = kebabCase(name) return { - filename: `playground/app/pages/components/${kebabName}.vue`, - contents: pro - ? undefined - : ` + filename: `playgrounds/nuxt/app/pages/components/${kebabName}.vue`, + contents: `