diff --git a/package.json b/package.json
index b784b52f..28fc0913 100644
--- a/package.json
+++ b/package.json
@@ -64,7 +64,7 @@
"prepack": "pnpm build",
"dev": "DEV=true nuxi dev playground",
"dev:build": "nuxi build playground",
- "dev:vue": "DEV=true vite playground-vue",
+ "dev:vue": "DEV=true pnpm --filter playground-vue dev",
"dev:vue:build": "vite build playground-vue",
"dev:prepare": "nuxt-module-build build --stub && nuxt-module-build prepare && nuxi prepare playground && nuxi prepare docs && vite build playground-vue",
"docs": "DEV=true nuxi dev docs",
diff --git a/playground-vue/package.json b/playground-vue/package.json
index 8a6ea5d5..738bcbb6 100644
--- a/playground-vue/package.json
+++ b/playground-vue/package.json
@@ -16,6 +16,7 @@
"zod": "^3.24.2"
},
"devDependencies": {
+ "@compodium/vue": "https://pkg.pr.new/romhml/compodium/@compodium/vue@18f083d",
"@vitejs/plugin-vue": "^5.2.3",
"typescript": "^5.6.3",
"vite": "^6.2.3",
diff --git a/playground-vue/src/main.ts b/playground-vue/src/main.ts
index d236724e..a9edcde1 100644
--- a/playground-vue/src/main.ts
+++ b/playground-vue/src/main.ts
@@ -10,7 +10,7 @@ const pages = import.meta.glob('../../playground/app/pages/**/*.vue')
const components = import.meta.glob('../../playground/app/components/**/*.vue')
const routes = Object.keys(pages).map((path) => {
- const name = path.match(/\.\.\/\.\.\/playground\/app\/pages(.*)\.vue$/)![1].toLowerCase()
+ const name = path.match(/\.\.\/\.\.\/playground\/app\/pages(.*)\.vue$/)!.[1].toLowerCase()
return {
path: name === '/index' ? '/' : name,
component: pages[path]
diff --git a/playground-vue/vite.config.ts b/playground-vue/vite.config.ts
index fcd3f0be..cb3c9511 100644
--- a/playground-vue/vite.config.ts
+++ b/playground-vue/vite.config.ts
@@ -1,6 +1,7 @@
import { defineConfig } from 'vite'
import vue from '@vitejs/plugin-vue'
+import { compodium } from '@compodium/vue'
import ui from '../src/vite'
// https://vitejs.dev/config/
@@ -25,7 +26,21 @@ export default defineConfig({
components: {
dirs: ['../playground/app/components']
}
+ }),
+ compodium({
+ dir: '../playground/compodium',
+ includeLibraryCollections: false,
+
+ componentDirs: [
+ { path: '../src/runtime/components', prefix: 'U', pathPrefix: false }
+ ],
+ extras: {
+ colors: {
+ neutral: 'slate'
+ }
+ }
})
+
],
optimizeDeps: {
// prevents reloading page when navigating between components
diff --git a/playground/compodium/examples/UContainerExample.vue b/playground/compodium/examples/UContainerExample.vue
new file mode 100644
index 00000000..e08c8434
--- /dev/null
+++ b/playground/compodium/examples/UContainerExample.vue
@@ -0,0 +1,12 @@
+
+
+
+
+
+
+
diff --git a/playground/compodium/examples/UContextMenuExample.vue b/playground/compodium/examples/UContextMenuExample.vue
new file mode 100644
index 00000000..de894dc1
--- /dev/null
+++ b/playground/compodium/examples/UContextMenuExample.vue
@@ -0,0 +1,28 @@
+
+
+
+
+
+ Right click here
+
+
+
diff --git a/playground/compodium/examples/UDrawerExample.vue b/playground/compodium/examples/UDrawerExample.vue
new file mode 100644
index 00000000..0b34e6be
--- /dev/null
+++ b/playground/compodium/examples/UDrawerExample.vue
@@ -0,0 +1,12 @@
+
+
+
+
+
+
+
+
diff --git a/playground/compodium/examples/UDropdownMenuExample.vue b/playground/compodium/examples/UDropdownMenuExample.vue
new file mode 100644
index 00000000..d785f8ac
--- /dev/null
+++ b/playground/compodium/examples/UDropdownMenuExample.vue
@@ -0,0 +1,9 @@
+
+
+
+
+
diff --git a/playground/compodium/examples/UFormExample.vue b/playground/compodium/examples/UFormExample.vue
new file mode 100644
index 00000000..e68f77ba
--- /dev/null
+++ b/playground/compodium/examples/UFormExample.vue
@@ -0,0 +1,36 @@
+
+
+
+
+
+
+
+
+
+
+
+ Submit
+
+
+
diff --git a/playground/compodium/examples/UFormFieldExample.vue b/playground/compodium/examples/UFormFieldExample.vue
new file mode 100644
index 00000000..34941f9b
--- /dev/null
+++ b/playground/compodium/examples/UFormFieldExample.vue
@@ -0,0 +1,13 @@
+
+
+
+
+
+
+
diff --git a/playground/compodium/examples/UIconExample.vue b/playground/compodium/examples/UIconExample.vue
new file mode 100644
index 00000000..a6733733
--- /dev/null
+++ b/playground/compodium/examples/UIconExample.vue
@@ -0,0 +1,11 @@
+
+
+
+
+
diff --git a/playground/compodium/examples/UInputMenuExample.vue b/playground/compodium/examples/UInputMenuExample.vue
new file mode 100644
index 00000000..2c648b4f
--- /dev/null
+++ b/playground/compodium/examples/UInputMenuExample.vue
@@ -0,0 +1,11 @@
+
+
+
+
+
diff --git a/playground/compodium/examples/UKbdExample.vue b/playground/compodium/examples/UKbdExample.vue
new file mode 100644
index 00000000..25bb0ae2
--- /dev/null
+++ b/playground/compodium/examples/UKbdExample.vue
@@ -0,0 +1,11 @@
+
+
+
+
+
diff --git a/playground/compodium/examples/ULinkExample.vue b/playground/compodium/examples/ULinkExample.vue
new file mode 100644
index 00000000..e5cbd6bc
--- /dev/null
+++ b/playground/compodium/examples/ULinkExample.vue
@@ -0,0 +1,5 @@
+
+
+ Link
+
+
diff --git a/playground/compodium/examples/UModalExample.vue b/playground/compodium/examples/UModalExample.vue
new file mode 100644
index 00000000..30e822d6
--- /dev/null
+++ b/playground/compodium/examples/UModalExample.vue
@@ -0,0 +1,12 @@
+
+
+
+
+
+
+
+
diff --git a/playground/compodium/examples/UNavigationMenuExample.vue b/playground/compodium/examples/UNavigationMenuExample.vue
new file mode 100644
index 00000000..bc07f866
--- /dev/null
+++ b/playground/compodium/examples/UNavigationMenuExample.vue
@@ -0,0 +1,43 @@
+
+
+
+
+
diff --git a/playground/compodium/examples/UPaginationExample.vue b/playground/compodium/examples/UPaginationExample.vue
new file mode 100644
index 00000000..e4127b92
--- /dev/null
+++ b/playground/compodium/examples/UPaginationExample.vue
@@ -0,0 +1,11 @@
+
+
+
+
+
diff --git a/playground/compodium/examples/UPopoverExample.vue b/playground/compodium/examples/UPopoverExample.vue
new file mode 100644
index 00000000..e5e557b6
--- /dev/null
+++ b/playground/compodium/examples/UPopoverExample.vue
@@ -0,0 +1,12 @@
+
+
+
+
+
+
+
+
diff --git a/playground/compodium/examples/URadioGroupExample.vue b/playground/compodium/examples/URadioGroupExample.vue
new file mode 100644
index 00000000..617c07f5
--- /dev/null
+++ b/playground/compodium/examples/URadioGroupExample.vue
@@ -0,0 +1,11 @@
+
+
+
+
+
diff --git a/playground/compodium/examples/USelectExample.vue b/playground/compodium/examples/USelectExample.vue
new file mode 100644
index 00000000..cb4302fc
--- /dev/null
+++ b/playground/compodium/examples/USelectExample.vue
@@ -0,0 +1,12 @@
+
+
+
+
+
diff --git a/playground/compodium/examples/USelectMenuExample.vue b/playground/compodium/examples/USelectMenuExample.vue
new file mode 100644
index 00000000..50540221
--- /dev/null
+++ b/playground/compodium/examples/USelectMenuExample.vue
@@ -0,0 +1,11 @@
+
+
+
+
+
diff --git a/playground/compodium/examples/USkeletonExample.vue b/playground/compodium/examples/USkeletonExample.vue
new file mode 100644
index 00000000..5b2fab1e
--- /dev/null
+++ b/playground/compodium/examples/USkeletonExample.vue
@@ -0,0 +1,3 @@
+
+
+
diff --git a/playground/compodium/examples/USlideoverExample.vue b/playground/compodium/examples/USlideoverExample.vue
new file mode 100644
index 00000000..6dfb2392
--- /dev/null
+++ b/playground/compodium/examples/USlideoverExample.vue
@@ -0,0 +1,12 @@
+
+
+
+
+
+
+
+
diff --git a/playground/compodium/examples/UStepperExample.vue b/playground/compodium/examples/UStepperExample.vue
new file mode 100644
index 00000000..2bb30620
--- /dev/null
+++ b/playground/compodium/examples/UStepperExample.vue
@@ -0,0 +1,51 @@
+
+
+
+
+
+
+ {{ item.title }}
+
+
+
+ Back
+
+
+ Next
+
+
+
+
+
diff --git a/playground/compodium/examples/USwitchExample.vue b/playground/compodium/examples/USwitchExample.vue
new file mode 100644
index 00000000..e77cb3bc
--- /dev/null
+++ b/playground/compodium/examples/USwitchExample.vue
@@ -0,0 +1,11 @@
+
+
+
+
+
diff --git a/playground/compodium/examples/UTableExample.vue b/playground/compodium/examples/UTableExample.vue
new file mode 100644
index 00000000..1ea189aa
--- /dev/null
+++ b/playground/compodium/examples/UTableExample.vue
@@ -0,0 +1,48 @@
+
+
+
+
+
diff --git a/playground/compodium/examples/UTabsExample.vue b/playground/compodium/examples/UTabsExample.vue
new file mode 100644
index 00000000..04f077bf
--- /dev/null
+++ b/playground/compodium/examples/UTabsExample.vue
@@ -0,0 +1,23 @@
+
+
+
+
+
diff --git a/playground/compodium/examples/UToasterExample.vue b/playground/compodium/examples/UToasterExample.vue
new file mode 100644
index 00000000..1333d316
--- /dev/null
+++ b/playground/compodium/examples/UToasterExample.vue
@@ -0,0 +1,12 @@
+
+
+
+
+
diff --git a/playground/compodium/examples/UTooltipExample.vue b/playground/compodium/examples/UTooltipExample.vue
new file mode 100644
index 00000000..70ea501e
--- /dev/null
+++ b/playground/compodium/examples/UTooltipExample.vue
@@ -0,0 +1,17 @@
+
+
+
+
+
+
+
diff --git a/playground/compodium/examples/UTreeExample.vue b/playground/compodium/examples/UTreeExample.vue
new file mode 100644
index 00000000..bc2b6d42
--- /dev/null
+++ b/playground/compodium/examples/UTreeExample.vue
@@ -0,0 +1,42 @@
+
+
+
+
+
diff --git a/playground/nuxt.config.ts b/playground/nuxt.config.ts
index 6853b8eb..3b4dbc22 100644
--- a/playground/nuxt.config.ts
+++ b/playground/nuxt.config.ts
@@ -21,7 +21,7 @@ export default defineNuxtConfig({
compodium: {
includeLibraryCollections: false,
- ignore: ['**/App.vue', '**/*Example.vue', '**/Placeholder.vue', '**/*Content.vue'],
+ ignore: ['**/App.vue', '**/*Example.vue', '**/Placeholder.vue', '**/*Content.vue', '**/*Provider.vue', 'UToast'],
extras: {
colors: {
neutral: 'slate'
diff --git a/playground/package.json b/playground/package.json
index 36901d67..5bd8583c 100644
--- a/playground/package.json
+++ b/playground/package.json
@@ -16,6 +16,6 @@
"zod": "^3.24.2"
},
"devDependencies": {
- "@compodium/nuxt": "https://pkg.pr.new/romhml/compodium/@compodium/nuxt@18f083d"
+ "@compodium/nuxt": "https://pkg.pr.new/romhml/compodium/@compodium/nuxt@eefc5d8"
}
}
diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml
index d5e1628e..10a7c975 100644
--- a/pnpm-lock.yaml
+++ b/pnpm-lock.yaml
@@ -324,8 +324,8 @@ importers:
version: 3.24.2
devDependencies:
'@compodium/nuxt':
- specifier: https://pkg.pr.new/romhml/compodium/@compodium/nuxt@18f083d
- version: https://pkg.pr.new/romhml/compodium/@compodium/nuxt@18f083d(magicast@0.3.5)(typescript@5.6.3)(vite@6.2.3(@types/node@22.13.12)(jiti@2.4.2)(lightningcss@1.29.2)(terser@5.39.0)(yaml@2.7.0))(vue@3.5.13(typescript@5.6.3))
+ specifier: https://pkg.pr.new/romhml/compodium/@compodium/nuxt@eefc5d8
+ version: https://pkg.pr.new/romhml/compodium/@compodium/nuxt@eefc5d8(magicast@0.3.5)(typescript@5.6.3)(vite@6.2.3(@types/node@22.13.12)(jiti@2.4.2)(lightningcss@1.29.2)(terser@5.39.0)(yaml@2.7.0))(vue@3.5.13(typescript@5.6.3))
playground-vue:
dependencies:
@@ -342,6 +342,9 @@ importers:
specifier: ^3.24.2
version: 3.24.2
devDependencies:
+ '@compodium/vue':
+ specifier: https://pkg.pr.new/romhml/compodium/@compodium/vue@18f083d
+ version: https://pkg.pr.new/romhml/compodium/@compodium/vue@18f083d(typescript@5.6.3)(vite@6.2.3(@types/node@22.13.12)(jiti@2.4.2)(lightningcss@1.29.2)(terser@5.39.0)(yaml@2.7.0))(vue@3.5.13(typescript@5.6.3))
'@vitejs/plugin-vue':
specifier: ^5.2.3
version: 5.2.3(vite@6.2.3(@types/node@22.13.12)(jiti@2.4.2)(lightningcss@1.29.2)(terser@5.39.0)(yaml@2.7.0))(vue@3.5.13(typescript@5.6.3))
@@ -563,10 +566,24 @@ packages:
vite:
optional: true
+ '@compodium/core@https://pkg.pr.new/romhml/compodium/@compodium/core@eefc5d8fcee1b89fd0c89ab3f06bf351d04852cc':
+ resolution: {tarball: https://pkg.pr.new/romhml/compodium/@compodium/core@eefc5d8fcee1b89fd0c89ab3f06bf351d04852cc}
+ version: 0.0.0-eefc5d8fcee1b89fd0c89ab3f06bf351d04852cc
+ peerDependencies:
+ vite: '>=6'
+ vue: '>=3'
+ peerDependenciesMeta:
+ vite:
+ optional: true
+
'@compodium/examples@https://pkg.pr.new/romhml/compodium/@compodium/examples@18f083d1431d5d84f9d251ce996e186877e4ea5b':
resolution: {tarball: https://pkg.pr.new/romhml/compodium/@compodium/examples@18f083d1431d5d84f9d251ce996e186877e4ea5b}
version: 0.0.0-18f083d1431d5d84f9d251ce996e186877e4ea5b
+ '@compodium/examples@https://pkg.pr.new/romhml/compodium/@compodium/examples@eefc5d8fcee1b89fd0c89ab3f06bf351d04852cc':
+ resolution: {tarball: https://pkg.pr.new/romhml/compodium/@compodium/examples@eefc5d8fcee1b89fd0c89ab3f06bf351d04852cc}
+ version: 0.0.0-eefc5d8fcee1b89fd0c89ab3f06bf351d04852cc
+
'@compodium/meta@https://pkg.pr.new/romhml/compodium/@compodium/meta@18f083d1431d5d84f9d251ce996e186877e4ea5b':
resolution: {tarball: https://pkg.pr.new/romhml/compodium/@compodium/meta@18f083d1431d5d84f9d251ce996e186877e4ea5b}
version: 0.0.0-18f083d1431d5d84f9d251ce996e186877e4ea5b
@@ -576,9 +593,24 @@ packages:
typescript:
optional: true
- '@compodium/nuxt@https://pkg.pr.new/romhml/compodium/@compodium/nuxt@18f083d':
- resolution: {tarball: https://pkg.pr.new/romhml/compodium/@compodium/nuxt@18f083d}
+ '@compodium/meta@https://pkg.pr.new/romhml/compodium/@compodium/meta@eefc5d8fcee1b89fd0c89ab3f06bf351d04852cc':
+ resolution: {tarball: https://pkg.pr.new/romhml/compodium/@compodium/meta@eefc5d8fcee1b89fd0c89ab3f06bf351d04852cc}
+ version: 0.0.0-eefc5d8fcee1b89fd0c89ab3f06bf351d04852cc
+ peerDependencies:
+ typescript: 5.6.3
+ peerDependenciesMeta:
+ typescript:
+ optional: true
+
+ '@compodium/nuxt@https://pkg.pr.new/romhml/compodium/@compodium/nuxt@eefc5d8':
+ resolution: {tarball: https://pkg.pr.new/romhml/compodium/@compodium/nuxt@eefc5d8}
+ version: 0.0.0-eefc5d8fcee1b89fd0c89ab3f06bf351d04852cc
+
+ '@compodium/vue@https://pkg.pr.new/romhml/compodium/@compodium/vue@18f083d':
+ resolution: {tarball: https://pkg.pr.new/romhml/compodium/@compodium/vue@18f083d}
version: 0.0.0-18f083d1431d5d84f9d251ce996e186877e4ea5b
+ peerDependencies:
+ vite: '>=6'
'@conventional-changelog/git-client@1.0.1':
resolution: {integrity: sha512-PJEqBwAleffCMETaVm/fUgHldzBE35JFk3/9LL6NUA5EXa3qednu+UT6M7E5iBu3zIQZCULYIiZ90fBYHt6xUw==}
@@ -7574,11 +7606,37 @@ snapshots:
transitivePeerDependencies:
- typescript
+ '@compodium/core@https://pkg.pr.new/romhml/compodium/@compodium/core@eefc5d8fcee1b89fd0c89ab3f06bf351d04852cc(typescript@5.6.3)(vite@6.2.3(@types/node@22.13.12)(jiti@2.4.2)(lightningcss@1.29.2)(terser@5.39.0)(yaml@2.7.0))(vue@3.5.13(typescript@5.6.3))':
+ dependencies:
+ '@compodium/examples': https://pkg.pr.new/romhml/compodium/@compodium/examples@eefc5d8fcee1b89fd0c89ab3f06bf351d04852cc
+ '@compodium/meta': https://pkg.pr.new/romhml/compodium/@compodium/meta@eefc5d8fcee1b89fd0c89ab3f06bf351d04852cc(typescript@5.6.3)
+ '@vueuse/core': 13.0.0(vue@3.5.13(typescript@5.6.3))
+ chokidar: 3.6.0
+ hookable: 5.5.3
+ pathe: 2.0.3
+ scule: 1.3.0
+ sirv: 3.0.1
+ tinyglobby: 0.2.12
+ ufo: 1.5.4
+ unplugin: 2.2.2
+ unplugin-ast: 0.14.4
+ vue: 3.5.13(typescript@5.6.3)
+ zod: 3.24.2
+ optionalDependencies:
+ vite: 6.2.3(@types/node@22.13.12)(jiti@2.4.2)(lightningcss@1.29.2)(terser@5.39.0)(yaml@2.7.0)
+ transitivePeerDependencies:
+ - typescript
+
'@compodium/examples@https://pkg.pr.new/romhml/compodium/@compodium/examples@18f083d1431d5d84f9d251ce996e186877e4ea5b':
dependencies:
pathe: 2.0.3
scule: 1.3.0
+ '@compodium/examples@https://pkg.pr.new/romhml/compodium/@compodium/examples@eefc5d8fcee1b89fd0c89ab3f06bf351d04852cc':
+ dependencies:
+ pathe: 2.0.3
+ scule: 1.3.0
+
'@compodium/meta@https://pkg.pr.new/romhml/compodium/@compodium/meta@18f083d1431d5d84f9d251ce996e186877e4ea5b(typescript@5.6.3)':
dependencies:
'@volar/typescript': 2.4.12
@@ -7589,9 +7647,19 @@ snapshots:
optionalDependencies:
typescript: 5.6.3
- '@compodium/nuxt@https://pkg.pr.new/romhml/compodium/@compodium/nuxt@18f083d(magicast@0.3.5)(typescript@5.6.3)(vite@6.2.3(@types/node@22.13.12)(jiti@2.4.2)(lightningcss@1.29.2)(terser@5.39.0)(yaml@2.7.0))(vue@3.5.13(typescript@5.6.3))':
+ '@compodium/meta@https://pkg.pr.new/romhml/compodium/@compodium/meta@eefc5d8fcee1b89fd0c89ab3f06bf351d04852cc(typescript@5.6.3)':
dependencies:
- '@compodium/core': https://pkg.pr.new/romhml/compodium/@compodium/core@18f083d1431d5d84f9d251ce996e186877e4ea5b(typescript@5.6.3)(vite@6.2.3(@types/node@22.13.12)(jiti@2.4.2)(lightningcss@1.29.2)(terser@5.39.0)(yaml@2.7.0))(vue@3.5.13(typescript@5.6.3))
+ '@volar/typescript': 2.4.12
+ '@vue/language-core': 2.2.8(typescript@5.6.3)
+ pathe: 2.0.3
+ vue-component-meta: 2.2.8(typescript@5.6.3)
+ vue-component-type-helpers: 2.2.8
+ optionalDependencies:
+ typescript: 5.6.3
+
+ '@compodium/nuxt@https://pkg.pr.new/romhml/compodium/@compodium/nuxt@eefc5d8(magicast@0.3.5)(typescript@5.6.3)(vite@6.2.3(@types/node@22.13.12)(jiti@2.4.2)(lightningcss@1.29.2)(terser@5.39.0)(yaml@2.7.0))(vue@3.5.13(typescript@5.6.3))':
+ dependencies:
+ '@compodium/core': https://pkg.pr.new/romhml/compodium/@compodium/core@eefc5d8fcee1b89fd0c89ab3f06bf351d04852cc(typescript@5.6.3)(vite@6.2.3(@types/node@22.13.12)(jiti@2.4.2)(lightningcss@1.29.2)(terser@5.39.0)(yaml@2.7.0))(vue@3.5.13(typescript@5.6.3))
'@nuxt/devtools-kit': 2.3.1(magicast@0.3.5)(vite@6.2.3(@types/node@22.13.12)(jiti@2.4.2)(lightningcss@1.29.2)(terser@5.39.0)(yaml@2.7.0))
'@nuxt/kit': 3.16.1(magicast@0.3.5)
consola: 3.4.2
@@ -7603,6 +7671,20 @@ snapshots:
- vite
- vue
+ '@compodium/vue@https://pkg.pr.new/romhml/compodium/@compodium/vue@18f083d(typescript@5.6.3)(vite@6.2.3(@types/node@22.13.12)(jiti@2.4.2)(lightningcss@1.29.2)(terser@5.39.0)(yaml@2.7.0))(vue@3.5.13(typescript@5.6.3))':
+ dependencies:
+ '@compodium/core': https://pkg.pr.new/romhml/compodium/@compodium/core@18f083d1431d5d84f9d251ce996e186877e4ea5b(typescript@5.6.3)(vite@6.2.3(@types/node@22.13.12)(jiti@2.4.2)(lightningcss@1.29.2)(terser@5.39.0)(yaml@2.7.0))(vue@3.5.13(typescript@5.6.3))
+ '@compodium/examples': https://pkg.pr.new/romhml/compodium/@compodium/examples@18f083d1431d5d84f9d251ce996e186877e4ea5b
+ '@vue/devtools-kit': 7.7.2
+ consola: 3.4.2
+ defu: 6.1.4
+ pathe: 2.0.3
+ unplugin: 2.2.2
+ vite: 6.2.3(@types/node@22.13.12)(jiti@2.4.2)(lightningcss@1.29.2)(terser@5.39.0)(yaml@2.7.0)
+ transitivePeerDependencies:
+ - typescript
+ - vue
+
'@conventional-changelog/git-client@1.0.1(conventional-commits-filter@5.0.0)(conventional-commits-parser@6.1.0)':
dependencies:
'@types/semver': 7.5.8