@nuxt/ui 4.6.1 → 4.7.1

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.
Files changed (175) hide show
  1. package/README.md +7 -4
  2. package/cli/package.json +1 -1
  3. package/dist/module.json +1 -1
  4. package/dist/module.mjs +3 -2
  5. package/dist/runtime/components/Accordion.d.vue.ts +6 -1
  6. package/dist/runtime/components/Accordion.vue +1 -1
  7. package/dist/runtime/components/Accordion.vue.d.ts +6 -1
  8. package/dist/runtime/components/AuthForm.d.vue.ts +22 -29
  9. package/dist/runtime/components/AuthForm.vue +8 -6
  10. package/dist/runtime/components/AuthForm.vue.d.ts +22 -29
  11. package/dist/runtime/components/Button.vue +1 -0
  12. package/dist/runtime/components/Calendar.vue +4 -4
  13. package/dist/runtime/components/Card.d.vue.ts +4 -0
  14. package/dist/runtime/components/Card.vue +16 -2
  15. package/dist/runtime/components/Card.vue.d.ts +4 -0
  16. package/dist/runtime/components/ChatMessage.d.vue.ts +27 -17
  17. package/dist/runtime/components/ChatMessage.vue +10 -16
  18. package/dist/runtime/components/ChatMessage.vue.d.ts +27 -17
  19. package/dist/runtime/components/ChatMessages.d.vue.ts +27 -21
  20. package/dist/runtime/components/ChatMessages.vue +22 -23
  21. package/dist/runtime/components/ChatMessages.vue.d.ts +27 -21
  22. package/dist/runtime/components/ChatPromptSubmit.vue +3 -1
  23. package/dist/runtime/components/Checkbox.vue +5 -3
  24. package/dist/runtime/components/CommandPalette.d.vue.ts +18 -3
  25. package/dist/runtime/components/CommandPalette.vue +11 -7
  26. package/dist/runtime/components/CommandPalette.vue.d.ts +18 -3
  27. package/dist/runtime/components/ContextMenuContent.vue +68 -65
  28. package/dist/runtime/components/DashboardSearch.d.vue.ts +8 -37
  29. package/dist/runtime/components/DashboardSearch.vue +11 -10
  30. package/dist/runtime/components/DashboardSearch.vue.d.ts +8 -37
  31. package/dist/runtime/components/DashboardSidebar.vue +1 -5
  32. package/dist/runtime/components/Drawer.vue +44 -41
  33. package/dist/runtime/components/DropdownMenuContent.vue +90 -87
  34. package/dist/runtime/components/EditorEmojiMenu.d.vue.ts +1 -1
  35. package/dist/runtime/components/EditorEmojiMenu.vue +2 -0
  36. package/dist/runtime/components/EditorEmojiMenu.vue.d.ts +1 -1
  37. package/dist/runtime/components/EditorMentionMenu.d.vue.ts +1 -1
  38. package/dist/runtime/components/EditorMentionMenu.vue +2 -0
  39. package/dist/runtime/components/EditorMentionMenu.vue.d.ts +1 -1
  40. package/dist/runtime/components/EditorSuggestionMenu.d.vue.ts +1 -1
  41. package/dist/runtime/components/EditorSuggestionMenu.vue +2 -0
  42. package/dist/runtime/components/EditorSuggestionMenu.vue.d.ts +1 -1
  43. package/dist/runtime/components/FileUpload.vue +7 -5
  44. package/dist/runtime/components/FormField.d.vue.ts +1 -1
  45. package/dist/runtime/components/FormField.vue.d.ts +1 -1
  46. package/dist/runtime/components/Header.vue +1 -5
  47. package/dist/runtime/components/Input.vue +2 -2
  48. package/dist/runtime/components/InputDate.vue +6 -6
  49. package/dist/runtime/components/InputMenu.d.vue.ts +3 -3
  50. package/dist/runtime/components/InputMenu.vue +40 -38
  51. package/dist/runtime/components/InputMenu.vue.d.ts +3 -3
  52. package/dist/runtime/components/InputNumber.vue +2 -2
  53. package/dist/runtime/components/InputTags.vue +2 -2
  54. package/dist/runtime/components/InputTime.vue +2 -2
  55. package/dist/runtime/components/Link.d.vue.ts +10 -1
  56. package/dist/runtime/components/Link.vue +74 -9
  57. package/dist/runtime/components/Link.vue.d.ts +10 -1
  58. package/dist/runtime/components/Listbox.d.vue.ts +228 -0
  59. package/dist/runtime/components/Listbox.vue +242 -0
  60. package/dist/runtime/components/Listbox.vue.d.ts +228 -0
  61. package/dist/runtime/components/Modal.vue +13 -10
  62. package/dist/runtime/components/Popover.vue +7 -4
  63. package/dist/runtime/components/PricingTable.vue +60 -58
  64. package/dist/runtime/components/RadioGroup.vue +5 -3
  65. package/dist/runtime/components/Select.d.vue.ts +1 -1
  66. package/dist/runtime/components/Select.vue +84 -73
  67. package/dist/runtime/components/Select.vue.d.ts +1 -1
  68. package/dist/runtime/components/SelectMenu.d.vue.ts +3 -3
  69. package/dist/runtime/components/SelectMenu.vue +54 -52
  70. package/dist/runtime/components/SelectMenu.vue.d.ts +3 -3
  71. package/dist/runtime/components/Sidebar.vue +1 -4
  72. package/dist/runtime/components/Slideover.vue +67 -64
  73. package/dist/runtime/components/Table.d.vue.ts +1 -2
  74. package/dist/runtime/components/Table.vue +17 -29
  75. package/dist/runtime/components/Table.vue.d.ts +1 -2
  76. package/dist/runtime/components/Tabs.d.vue.ts +5 -1
  77. package/dist/runtime/components/Tabs.vue +2 -2
  78. package/dist/runtime/components/Tabs.vue.d.ts +5 -1
  79. package/dist/runtime/components/Textarea.d.vue.ts +1 -0
  80. package/dist/runtime/components/Textarea.vue +2 -1
  81. package/dist/runtime/components/Textarea.vue.d.ts +1 -0
  82. package/dist/runtime/components/Tooltip.vue +12 -9
  83. package/dist/runtime/components/content/ContentSearch.d.vue.ts +19 -35
  84. package/dist/runtime/components/content/ContentSearch.vue +10 -9
  85. package/dist/runtime/components/content/ContentSearch.vue.d.ts +19 -35
  86. package/dist/runtime/components/content/ContentToc.vue +19 -9
  87. package/dist/runtime/components/prose/Img.vue +7 -1
  88. package/dist/runtime/components/prose/Pre.vue +8 -3
  89. package/dist/runtime/components/prose/Prompt.d.vue.ts +32 -0
  90. package/dist/runtime/components/prose/Prompt.vue +88 -0
  91. package/dist/runtime/components/prose/Prompt.vue.d.ts +32 -0
  92. package/dist/runtime/composables/index.d.ts +1 -0
  93. package/dist/runtime/composables/index.js +1 -0
  94. package/dist/runtime/composables/useContentSearch.js +19 -5
  95. package/dist/runtime/composables/useEditorMenu.d.ts +5 -0
  96. package/dist/runtime/composables/useEditorMenu.js +3 -1
  97. package/dist/runtime/composables/useFieldGroup.d.ts +3 -0
  98. package/dist/runtime/composables/useFieldGroup.js +11 -1
  99. package/dist/runtime/composables/useResolvedVariants.d.ts +21 -0
  100. package/dist/runtime/composables/useResolvedVariants.js +14 -0
  101. package/dist/runtime/locale/ar.js +9 -0
  102. package/dist/runtime/locale/az.js +9 -0
  103. package/dist/runtime/locale/be.js +9 -0
  104. package/dist/runtime/locale/bg.js +9 -0
  105. package/dist/runtime/locale/bn.js +9 -0
  106. package/dist/runtime/locale/ca.js +9 -0
  107. package/dist/runtime/locale/ckb.js +10 -1
  108. package/dist/runtime/locale/cs.js +9 -0
  109. package/dist/runtime/locale/da.js +9 -0
  110. package/dist/runtime/locale/de.js +9 -0
  111. package/dist/runtime/locale/de_ch.js +9 -0
  112. package/dist/runtime/locale/el.js +9 -0
  113. package/dist/runtime/locale/en.js +10 -1
  114. package/dist/runtime/locale/es.js +9 -0
  115. package/dist/runtime/locale/et.js +9 -0
  116. package/dist/runtime/locale/eu.js +11 -2
  117. package/dist/runtime/locale/fa_ir.js +9 -0
  118. package/dist/runtime/locale/fi.js +9 -0
  119. package/dist/runtime/locale/fr.js +9 -0
  120. package/dist/runtime/locale/gl.js +9 -0
  121. package/dist/runtime/locale/he.js +9 -0
  122. package/dist/runtime/locale/hi.js +9 -0
  123. package/dist/runtime/locale/hr.js +9 -0
  124. package/dist/runtime/locale/hu.js +9 -0
  125. package/dist/runtime/locale/hy.js +9 -0
  126. package/dist/runtime/locale/id.js +9 -0
  127. package/dist/runtime/locale/is.js +9 -0
  128. package/dist/runtime/locale/it.js +9 -0
  129. package/dist/runtime/locale/ja.js +9 -0
  130. package/dist/runtime/locale/ka.js +9 -0
  131. package/dist/runtime/locale/kk.js +9 -0
  132. package/dist/runtime/locale/km.js +9 -0
  133. package/dist/runtime/locale/ko.js +9 -0
  134. package/dist/runtime/locale/ky.js +9 -0
  135. package/dist/runtime/locale/lb.js +11 -2
  136. package/dist/runtime/locale/lo.js +15 -6
  137. package/dist/runtime/locale/lt.js +9 -0
  138. package/dist/runtime/locale/mn.js +9 -0
  139. package/dist/runtime/locale/ms.js +9 -0
  140. package/dist/runtime/locale/nb_no.js +9 -0
  141. package/dist/runtime/locale/nl.js +9 -0
  142. package/dist/runtime/locale/pl.js +9 -0
  143. package/dist/runtime/locale/pt.js +9 -0
  144. package/dist/runtime/locale/pt_br.js +9 -0
  145. package/dist/runtime/locale/ro.js +9 -0
  146. package/dist/runtime/locale/ru.js +9 -0
  147. package/dist/runtime/locale/sk.js +9 -0
  148. package/dist/runtime/locale/sl.js +9 -0
  149. package/dist/runtime/locale/sq.js +9 -0
  150. package/dist/runtime/locale/sv.js +9 -0
  151. package/dist/runtime/locale/th.js +9 -0
  152. package/dist/runtime/locale/tj.js +9 -0
  153. package/dist/runtime/locale/tr.js +9 -0
  154. package/dist/runtime/locale/ug_cn.js +9 -0
  155. package/dist/runtime/locale/uk.js +9 -0
  156. package/dist/runtime/locale/ur.js +9 -0
  157. package/dist/runtime/locale/uz.js +9 -0
  158. package/dist/runtime/locale/vi.js +9 -0
  159. package/dist/runtime/locale/zh_cn.js +9 -0
  160. package/dist/runtime/locale/zh_tw.js +9 -0
  161. package/dist/runtime/plugins/colors.js +1 -1
  162. package/dist/runtime/types/index.d.ts +1 -0
  163. package/dist/runtime/types/index.js +1 -0
  164. package/dist/runtime/types/locale.d.ts +9 -0
  165. package/dist/runtime/types/prose.d.ts +1 -0
  166. package/dist/runtime/types/prose.js +1 -0
  167. package/dist/runtime/utils/link.d.ts +1 -1
  168. package/dist/runtime/utils/link.js +1 -0
  169. package/dist/runtime/vue/overrides/inertia/Link.vue +3 -3
  170. package/dist/runtime/vue/overrides/none/Link.vue +3 -2
  171. package/dist/runtime/vue/overrides/vue-router/Link.vue +27 -31
  172. package/dist/shared/{ui.DJUbBpE2.mjs → ui.C6mn7iap.mjs} +189 -37
  173. package/dist/unplugin.mjs +1 -1
  174. package/dist/vite.mjs +1 -1
  175. package/package.json +49 -40
@@ -98,6 +98,11 @@ export default defineLocale({
98
98
  decrement: "\u51CF\u5C11",
99
99
  increment: "\u589E\u52A0"
100
100
  },
101
+ listbox: {
102
+ noData: "\u6CA1\u6709\u6570\u636E",
103
+ noMatch: "\u6CA1\u6709\u5339\u914D\u7684\u6570\u636E",
104
+ search: "\u641C\u7D22\u2026"
105
+ },
101
106
  modal: {
102
107
  close: "\u5173\u95ED"
103
108
  },
@@ -117,6 +122,10 @@ export default defineLocale({
117
122
  },
118
123
  pre: {
119
124
  copy: "\u590D\u5236\u4EE3\u7801\u5230\u526A\u8D34\u677F"
125
+ },
126
+ prompt: {
127
+ copy: "\u590D\u5236\u63D0\u793A\u8BCD",
128
+ openIn: "\u5728 {name} \u4E2D\u6253\u5F00"
120
129
  }
121
130
  },
122
131
  sidebar: {
@@ -98,6 +98,11 @@ export default defineLocale({
98
98
  decrement: "\u6E1B\u5C11",
99
99
  increment: "\u589E\u52A0"
100
100
  },
101
+ listbox: {
102
+ noData: "\u6C92\u6709\u8CC7\u6599",
103
+ noMatch: "\u6C92\u6709\u76F8\u7B26\u7684\u8CC7\u6599",
104
+ search: "\u641C\u5C0B\u2026"
105
+ },
101
106
  modal: {
102
107
  close: "\u95DC\u9589"
103
108
  },
@@ -117,6 +122,10 @@ export default defineLocale({
117
122
  },
118
123
  pre: {
119
124
  copy: "\u8907\u88FD\u7A0B\u5F0F\u78BC\u5230\u526A\u8CBC\u7C3F"
125
+ },
126
+ prompt: {
127
+ copy: "\u8907\u88FD\u63D0\u793A\u8A5E",
128
+ openIn: "\u5728 {name} \u4E2D\u958B\u555F"
120
129
  }
121
130
  },
122
131
  sidebar: {
@@ -36,7 +36,7 @@ export default defineNuxtPlugin(() => {
36
36
  const headData = {
37
37
  style: [{
38
38
  innerHTML: () => root.value,
39
- tagPriority: -2,
39
+ tagPriority: "critical",
40
40
  id: "nuxt-ui-colors"
41
41
  }]
42
42
  };
@@ -67,6 +67,7 @@ export * from '../components/InputTags.vue';
67
67
  export * from '../components/InputTime.vue';
68
68
  export * from '../components/Kbd.vue';
69
69
  export * from '../components/Link.vue';
70
+ export * from '../components/Listbox.vue';
70
71
  export * from '../components/Main.vue';
71
72
  export * from '../components/Marquee.vue';
72
73
  export * from '../components/Modal.vue';
@@ -67,6 +67,7 @@ export * from "../components/InputTags.vue";
67
67
  export * from "../components/InputTime.vue";
68
68
  export * from "../components/Kbd.vue";
69
69
  export * from "../components/Link.vue";
70
+ export * from "../components/Listbox.vue";
70
71
  export * from "../components/Main.vue";
71
72
  export * from "../components/Marquee.vue";
72
73
  export * from "../components/Modal.vue";
@@ -99,6 +99,11 @@ export type Messages = {
99
99
  decrement: string;
100
100
  increment: string;
101
101
  };
102
+ listbox: {
103
+ noData: string;
104
+ noMatch: string;
105
+ search: string;
106
+ };
102
107
  modal: {
103
108
  close: string;
104
109
  };
@@ -119,6 +124,10 @@ export type Messages = {
119
124
  pre: {
120
125
  copy: string;
121
126
  };
127
+ prompt: {
128
+ copy: string;
129
+ openIn: string;
130
+ };
122
131
  };
123
132
  chatReasoning: {
124
133
  thinking: string;
@@ -28,6 +28,7 @@ export * from '../components/prose/Li.vue';
28
28
  export * from '../components/prose/Ol.vue';
29
29
  export * from '../components/prose/P.vue';
30
30
  export * from '../components/prose/Pre.vue';
31
+ export * from '../components/prose/Prompt.vue';
31
32
  export * from '../components/prose/Script.vue';
32
33
  export * from '../components/prose/Steps.vue';
33
34
  export * from '../components/prose/Strong.vue';
@@ -28,6 +28,7 @@ export * from "../components/prose/Li.vue";
28
28
  export * from "../components/prose/Ol.vue";
29
29
  export * from "../components/prose/P.vue";
30
30
  export * from "../components/prose/Pre.vue";
31
+ export * from "../components/prose/Prompt.vue";
31
32
  export * from "../components/prose/Script.vue";
32
33
  export * from "../components/prose/Steps.vue";
33
34
  export * from "../components/prose/Strong.vue";
@@ -1,5 +1,5 @@
1
1
  import type { LinkProps } from '../types';
2
- export declare const linkKeys: readonly ["active", "activeClass", "ariaCurrentValue", "as", "disabled", "download", "exact", "exactActiveClass", "exactHash", "exactQuery", "external", "form", "formaction", "formenctype", "formmethod", "formnovalidate", "formtarget", "href", "hreflang", "inactiveClass", "media", "noPrefetch", "noRel", "onClick", "ping", "prefetch", "prefetchOn", "prefetchedClass", "referrerpolicy", "rel", "replace", "target", "title", "to", "trailingSlash", "type", "viewTransition"];
2
+ export declare const linkKeys: readonly ["active", "activeClass", "ariaCurrentValue", "as", "disabled", "download", "exact", "exactActiveClass", "exactHash", "exactQuery", "external", "form", "formaction", "formenctype", "formmethod", "formnovalidate", "formtarget", "href", "hreflang", "inactiveClass", "locale", "media", "noPrefetch", "noRel", "onClick", "ping", "prefetch", "prefetchOn", "prefetchedClass", "referrerpolicy", "rel", "replace", "target", "title", "to", "trailingSlash", "type", "viewTransition"];
3
3
  export declare function pickLinkProps(link: LinkProps & {
4
4
  [key: string]: any;
5
5
  }): import("@vueuse/shared").ReactivePickReturn<LinkProps & {
@@ -21,6 +21,7 @@ export const linkKeys = [
21
21
  "href",
22
22
  "hreflang",
23
23
  "inactiveClass",
24
+ "locale",
24
25
  "media",
25
26
  "noPrefetch",
26
27
  "noRel",
@@ -5,7 +5,7 @@ import theme from "#build/ui/link";
5
5
  <script setup>
6
6
  import { computed } from "vue";
7
7
  import { defu } from "defu";
8
- import { useForwardProps } from "reka-ui";
8
+ import { useForwardProps, Slot } from "reka-ui";
9
9
  import { reactiveOmit } from "@vueuse/core";
10
10
  import { usePage } from "@inertiajs/vue3";
11
11
  import { hasProtocol } from "ufo";
@@ -126,7 +126,7 @@ const linkClass = computed(() => {
126
126
  </script>
127
127
 
128
128
  <template>
129
- <template v-if="custom">
129
+ <Slot v-if="custom">
130
130
  <slot
131
131
  v-bind="{
132
132
  ...$attrs,
@@ -141,7 +141,7 @@ const linkClass = computed(() => {
141
141
  isExternal
142
142
  }"
143
143
  />
144
- </template>
144
+ </Slot>
145
145
  <ULinkBase
146
146
  v-else
147
147
  v-bind="{
@@ -5,6 +5,7 @@ import theme from "#build/ui/link";
5
5
  <script setup>
6
6
  import { computed, inject } from "vue";
7
7
  import { defu } from "defu";
8
+ import { Slot } from "reka-ui";
8
9
  import { hasProtocol } from "ufo";
9
10
  import { useAppConfig } from "#imports";
10
11
  import { mergeClasses } from "../../../utils";
@@ -94,7 +95,7 @@ const navigate = handleNavigation ? (e) => {
94
95
  </script>
95
96
 
96
97
  <template>
97
- <template v-if="custom">
98
+ <Slot v-if="custom">
98
99
  <slot
99
100
  v-bind="{
100
101
  ...$attrs,
@@ -109,7 +110,7 @@ const navigate = handleNavigation ? (e) => {
109
110
  active: isLinkActive
110
111
  }"
111
112
  />
112
- </template>
113
+ </Slot>
113
114
  <ULinkBase
114
115
  v-else
115
116
  v-bind="{
@@ -6,7 +6,7 @@ import theme from "#build/ui/link";
6
6
  import { computed } from "vue";
7
7
  import { defu } from "defu";
8
8
  import { isEqual } from "ohash/utils";
9
- import { useForwardProps } from "reka-ui";
9
+ import { useForwardProps, Slot } from "reka-ui";
10
10
  import { reactiveOmit } from "@vueuse/core";
11
11
  import { hasProtocol } from "ufo";
12
12
  import { useRoute, RouterLink } from "vue-router";
@@ -111,11 +111,10 @@ function resolveLinkClass({ route: route2, isActive, isExactActive } = {}) {
111
111
  </script>
112
112
 
113
113
  <template>
114
- <template v-if="!isExternal && !!to">
115
- <RouterLink v-slot="{ href, navigate, route: linkRoute, isActive, isExactActive }" v-bind="routerLinkProps" :to="to" custom>
116
- <template v-if="custom">
117
- <slot
118
- v-bind="{
114
+ <RouterLink v-if="!isExternal && !!to" v-slot="{ href, navigate, route: linkRoute, isActive, isExactActive }" v-bind="routerLinkProps" :to="to" custom>
115
+ <Slot v-if="custom">
116
+ <slot
117
+ v-bind="{
119
118
  ...$attrs,
120
119
  ...exact && isExactActive ? { 'aria-current': props.ariaCurrentValue } : {},
121
120
  as,
@@ -128,11 +127,11 @@ function resolveLinkClass({ route: route2, isActive, isExactActive } = {}) {
128
127
  isExternal,
129
128
  active: isLinkActive({ route: linkRoute, isActive, isExactActive })
130
129
  }"
131
- />
132
- </template>
133
- <ULinkBase
134
- v-else
135
- v-bind="{
130
+ />
131
+ </Slot>
132
+ <ULinkBase
133
+ v-else
134
+ v-bind="{
136
135
  ...$attrs,
137
136
  ...exact && isExactActive ? { 'aria-current': props.ariaCurrentValue } : {},
138
137
  as,
@@ -144,17 +143,15 @@ function resolveLinkClass({ route: route2, isActive, isExactActive } = {}) {
144
143
  target,
145
144
  isExternal
146
145
  }"
147
- :class="resolveLinkClass({ route: linkRoute, isActive, isExactActive })"
148
- >
149
- <slot :active="isLinkActive({ route: linkRoute, isActive, isExactActive })" />
150
- </ULinkBase>
151
- </RouterLink>
152
- </template>
146
+ :class="resolveLinkClass({ route: linkRoute, isActive, isExactActive })"
147
+ >
148
+ <slot :active="isLinkActive({ route: linkRoute, isActive, isExactActive })" />
149
+ </ULinkBase>
150
+ </RouterLink>
153
151
 
154
- <template v-else>
155
- <template v-if="custom">
156
- <slot
157
- v-bind="{
152
+ <Slot v-else-if="custom">
153
+ <slot
154
+ v-bind="{
158
155
  ...$attrs,
159
156
  as,
160
157
  type,
@@ -165,11 +162,11 @@ function resolveLinkClass({ route: route2, isActive, isExactActive } = {}) {
165
162
  active: active ?? false,
166
163
  isExternal
167
164
  }"
168
- />
169
- </template>
170
- <ULinkBase
171
- v-else
172
- v-bind="{
165
+ />
166
+ </Slot>
167
+ <ULinkBase
168
+ v-else
169
+ v-bind="{
173
170
  ...$attrs,
174
171
  as,
175
172
  type,
@@ -179,9 +176,8 @@ function resolveLinkClass({ route: route2, isActive, isExactActive } = {}) {
179
176
  target,
180
177
  isExternal
181
178
  }"
182
- :class="resolveLinkClass()"
183
- >
184
- <slot :active="active ?? false" />
185
- </ULinkBase>
186
- </template>
179
+ :class="resolveLinkClass()"
180
+ >
181
+ <slot :active="active ?? false" />
182
+ </ULinkBase>
187
183
  </template>