@nuxt/ui 3.0.0-alpha.4 → 3.0.0-alpha.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +6 -4
- package/dist/module.d.mts +19 -5
- package/dist/module.d.ts +19 -5
- package/dist/module.json +2 -1
- package/dist/module.mjs +359 -312
- package/dist/runtime/components/Alert.vue +2 -2
- package/dist/runtime/components/Breadcrumb.vue +2 -2
- package/dist/runtime/components/Button.vue +2 -1
- package/dist/runtime/components/Carousel.vue +306 -0
- package/dist/runtime/components/CommandPalette.vue +2 -2
- package/dist/runtime/components/ContextMenu.vue +2 -2
- package/dist/runtime/components/DropdownMenu.vue +2 -2
- package/dist/runtime/components/Form.vue +4 -2
- package/dist/runtime/components/Modal.vue +2 -2
- package/dist/runtime/components/NavigationMenu.vue +3 -3
- package/dist/runtime/components/Pagination.vue +2 -2
- package/dist/runtime/components/Slideover.vue +2 -2
- package/dist/runtime/components/Toast.vue +2 -2
- package/dist/runtime/index.css +1 -1
- package/dist/runtime/plugins/colors.js +12 -8
- package/dist/runtime/types/form.d.ts +2 -1
- package/dist/runtime/types/index.d.ts +1 -0
- package/dist/runtime/types/index.js +1 -0
- package/dist/runtime/utils/form.d.ts +4 -1
- package/dist/runtime/utils/form.js +11 -1
- package/package.json +22 -9
|
@@ -56,7 +56,7 @@ export async function getJoiErrors(state, schema) {
|
|
|
56
56
|
export function isValibotSchema(schema) {
|
|
57
57
|
return "_run" in schema || typeof schema === "function" && "schema" in schema;
|
|
58
58
|
}
|
|
59
|
-
export async function
|
|
59
|
+
export async function getValibotErrors(state, schema) {
|
|
60
60
|
const result = await ("_run" in schema ? schema._run({ typed: false, value: state }, {}) : schema(state));
|
|
61
61
|
return result.issues?.map((issue) => ({
|
|
62
62
|
// We know that the key for a form schema is always a string or a number
|
|
@@ -64,3 +64,13 @@ export async function getValibotError(state, schema) {
|
|
|
64
64
|
message: issue.message
|
|
65
65
|
})) || [];
|
|
66
66
|
}
|
|
67
|
+
export function isStandardSchema(schema) {
|
|
68
|
+
return "~standard" in schema;
|
|
69
|
+
}
|
|
70
|
+
export async function getStandardErrors(state, schema) {
|
|
71
|
+
const result = await schema["~validate"]({ value: state });
|
|
72
|
+
return result.issues?.map((issue) => ({
|
|
73
|
+
name: issue.path?.map((item) => typeof item === "object" ? item.key : item).join(".") || "",
|
|
74
|
+
message: issue.message
|
|
75
|
+
})) || [];
|
|
76
|
+
}
|
package/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nuxt/ui",
|
|
3
3
|
"description": "A UI Library for Modern Web Apps, powered by Vue & Tailwind CSS.",
|
|
4
|
-
"version": "3.0.0-alpha.
|
|
5
|
-
"packageManager": "pnpm@9.
|
|
4
|
+
"version": "3.0.0-alpha.6",
|
|
5
|
+
"packageManager": "pnpm@9.12.1",
|
|
6
6
|
"repository": {
|
|
7
7
|
"type": "git",
|
|
8
8
|
"url": "git+https://github.com/nuxt/ui.git"
|
|
@@ -45,8 +45,8 @@
|
|
|
45
45
|
"release": "release-it --preRelease=alpha --npm.tag=next"
|
|
46
46
|
},
|
|
47
47
|
"dependencies": {
|
|
48
|
-
"@nuxt/fonts": "^0.
|
|
49
|
-
"@nuxt/icon": "^1.5.
|
|
48
|
+
"@nuxt/fonts": "^0.10.0",
|
|
49
|
+
"@nuxt/icon": "^1.5.5",
|
|
50
50
|
"@nuxt/kit": "^3.13.2",
|
|
51
51
|
"@nuxt/schema": "^3.13.2",
|
|
52
52
|
"@nuxtjs/color-mode": "^3.5.1",
|
|
@@ -55,9 +55,16 @@
|
|
|
55
55
|
"@vueuse/core": "^11.1.0",
|
|
56
56
|
"@vueuse/integrations": "^11.1.0",
|
|
57
57
|
"defu": "^6.1.4",
|
|
58
|
+
"embla-carousel-auto-height": "^8.3.0",
|
|
59
|
+
"embla-carousel-auto-scroll": "^8.3.0",
|
|
60
|
+
"embla-carousel-autoplay": "^8.3.0",
|
|
61
|
+
"embla-carousel-class-names": "^8.3.0",
|
|
62
|
+
"embla-carousel-fade": "^8.3.0",
|
|
63
|
+
"embla-carousel-vue": "^8.3.0",
|
|
64
|
+
"embla-carousel-wheel-gestures": "^8.0.1",
|
|
58
65
|
"fuse.js": "^7.0.0",
|
|
59
66
|
"ohash": "^1.1.4",
|
|
60
|
-
"radix-vue": "^1.9.
|
|
67
|
+
"radix-vue": "^1.9.7",
|
|
61
68
|
"scule": "^1.3.0",
|
|
62
69
|
"tailwind-variants": "^0.2.1",
|
|
63
70
|
"tailwindcss": "4.0.0-alpha.24",
|
|
@@ -66,23 +73,29 @@
|
|
|
66
73
|
"devDependencies": {
|
|
67
74
|
"@nuxt/eslint-config": "^0.5.7",
|
|
68
75
|
"@nuxt/module-builder": "^0.8.4",
|
|
69
|
-
"@nuxt/test-utils": "^3.14.
|
|
76
|
+
"@nuxt/test-utils": "^3.14.3",
|
|
70
77
|
"@release-it/conventional-changelog": "^8.0.2",
|
|
78
|
+
"@standard-schema/spec": "1.0.0-beta.1",
|
|
71
79
|
"@vue/test-utils": "^2.4.6",
|
|
80
|
+
"embla-carousel": "^8.3.0",
|
|
72
81
|
"eslint": "^9.11.1",
|
|
73
82
|
"happy-dom": "^15.7.4",
|
|
74
83
|
"joi": "^17.13.3",
|
|
75
84
|
"nuxt": "^3.13.2",
|
|
76
|
-
"release-it": "^17.
|
|
85
|
+
"release-it": "^17.7.0",
|
|
77
86
|
"valibot": "^0.42.1",
|
|
78
|
-
"vitest": "^2.1.
|
|
87
|
+
"vitest": "^2.1.2",
|
|
79
88
|
"vitest-environment-nuxt": "^1.0.1",
|
|
80
89
|
"vue-tsc": "^2.1.6",
|
|
81
90
|
"yup": "^1.4.0",
|
|
82
91
|
"zod": "^3.23.8"
|
|
83
92
|
},
|
|
93
|
+
"peerDependencies": {
|
|
94
|
+
"typescript": "^5.6.3"
|
|
95
|
+
},
|
|
84
96
|
"resolutions": {
|
|
85
97
|
"@nuxt/ui": "workspace:*",
|
|
86
|
-
"happy-dom": "14.12.3"
|
|
98
|
+
"happy-dom": "14.12.3",
|
|
99
|
+
"rollup": "^4.24.0"
|
|
87
100
|
}
|
|
88
101
|
}
|