@nuxt/ui 2.21.0 → 2.22.0

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 (85) hide show
  1. package/README.md +19 -14
  2. package/dist/module.d.mts +6 -1
  3. package/dist/module.json +3 -3
  4. package/dist/module.mjs +6 -12
  5. package/dist/runtime/components/data/Table.vue +19 -24
  6. package/dist/runtime/components/data/Table.vue.d.ts +44 -348
  7. package/dist/runtime/components/elements/Accordion.vue +4 -4
  8. package/dist/runtime/components/elements/Accordion.vue.d.ts +16 -16
  9. package/dist/runtime/components/elements/Alert.vue +7 -7
  10. package/dist/runtime/components/elements/Alert.vue.d.ts +41 -38
  11. package/dist/runtime/components/elements/Avatar.vue.d.ts +2 -2
  12. package/dist/runtime/components/elements/Badge.vue.d.ts +2 -2
  13. package/dist/runtime/components/elements/Button.vue.d.ts +6 -6
  14. package/dist/runtime/components/elements/Carousel.vue +3 -3
  15. package/dist/runtime/components/elements/Carousel.vue.d.ts +22 -22
  16. package/dist/runtime/components/elements/Chip.vue.d.ts +1 -1
  17. package/dist/runtime/components/elements/Dropdown.vue +1 -1
  18. package/dist/runtime/components/elements/Dropdown.vue.d.ts +19 -19
  19. package/dist/runtime/components/elements/Kbd.vue.d.ts +1 -1
  20. package/dist/runtime/components/elements/Link.vue +13 -11
  21. package/dist/runtime/components/elements/Link.vue.d.ts +2 -2
  22. package/dist/runtime/components/elements/Meter.vue +1 -1
  23. package/dist/runtime/components/elements/Meter.vue.d.ts +3 -3
  24. package/dist/runtime/components/elements/Progress.vue +1 -1
  25. package/dist/runtime/components/elements/Progress.vue.d.ts +5 -5
  26. package/dist/runtime/components/forms/Checkbox.vue.d.ts +3 -3
  27. package/dist/runtime/components/forms/Form.vue +8 -30
  28. package/dist/runtime/components/forms/Form.vue.d.ts +7 -8
  29. package/dist/runtime/components/forms/FormGroup.vue.d.ts +2 -2
  30. package/dist/runtime/components/forms/Input.vue +3 -3
  31. package/dist/runtime/components/forms/Input.vue.d.ts +3 -3
  32. package/dist/runtime/components/forms/InputMenu.vue +3 -3
  33. package/dist/runtime/components/forms/InputMenu.vue.d.ts +16 -16
  34. package/dist/runtime/components/forms/Radio.vue.d.ts +3 -3
  35. package/dist/runtime/components/forms/RadioGroup.vue.d.ts +6 -6
  36. package/dist/runtime/components/forms/Range.vue.d.ts +3 -3
  37. package/dist/runtime/components/forms/Select.vue +2 -2
  38. package/dist/runtime/components/forms/Select.vue.d.ts +2 -2
  39. package/dist/runtime/components/forms/SelectMenu.vue +10 -5
  40. package/dist/runtime/components/forms/SelectMenu.vue.d.ts +25 -16
  41. package/dist/runtime/components/forms/Textarea.vue.d.ts +3 -3
  42. package/dist/runtime/components/forms/Toggle.vue.d.ts +2 -2
  43. package/dist/runtime/components/layout/Card.vue.d.ts +1 -1
  44. package/dist/runtime/components/layout/Container.vue.d.ts +1 -1
  45. package/dist/runtime/components/layout/Divider.vue.d.ts +15 -15
  46. package/dist/runtime/components/layout/Skeleton.vue.d.ts +1 -1
  47. package/dist/runtime/components/navigation/Breadcrumb.vue +1 -1
  48. package/dist/runtime/components/navigation/Breadcrumb.vue.d.ts +3 -3
  49. package/dist/runtime/components/navigation/CommandPalette.vue +1 -1
  50. package/dist/runtime/components/navigation/CommandPalette.vue.d.ts +33 -33
  51. package/dist/runtime/components/navigation/CommandPaletteGroup.vue.d.ts +30 -30
  52. package/dist/runtime/components/navigation/HorizontalNavigation.vue +5 -5
  53. package/dist/runtime/components/navigation/HorizontalNavigation.vue.d.ts +36 -36
  54. package/dist/runtime/components/navigation/Pagination.vue +5 -5
  55. package/dist/runtime/components/navigation/Pagination.vue.d.ts +34 -34
  56. package/dist/runtime/components/navigation/Tabs.vue.d.ts +1 -1
  57. package/dist/runtime/components/navigation/VerticalNavigation.vue +5 -5
  58. package/dist/runtime/components/navigation/VerticalNavigation.vue.d.ts +58 -58
  59. package/dist/runtime/components/overlays/ContextMenu.vue.d.ts +1 -1
  60. package/dist/runtime/components/overlays/Modal.vue +6 -6
  61. package/dist/runtime/components/overlays/Modal.vue.d.ts +3 -3
  62. package/dist/runtime/components/overlays/Modals.client.vue +5 -7
  63. package/dist/runtime/components/overlays/Modals.client.vue.d.ts +2 -0
  64. package/dist/runtime/components/overlays/Notification.vue +6 -6
  65. package/dist/runtime/components/overlays/Notification.vue.d.ts +45 -42
  66. package/dist/runtime/components/overlays/Notifications.vue.d.ts +71 -67
  67. package/dist/runtime/components/overlays/Popover.vue.d.ts +2 -2
  68. package/dist/runtime/components/overlays/Slideover.vue.d.ts +3 -3
  69. package/dist/runtime/components/overlays/Slideovers.client.vue +5 -7
  70. package/dist/runtime/components/overlays/Slideovers.client.vue.d.ts +2 -0
  71. package/dist/runtime/components/overlays/Tooltip.vue.d.ts +5 -5
  72. package/dist/runtime/composables/useFormGroup.d.ts +1 -1
  73. package/dist/runtime/composables/useShortcuts.d.ts +2 -2
  74. package/dist/runtime/composables/useToast.d.ts +4 -4
  75. package/dist/runtime/ui.config/elements/alert.d.ts +1 -0
  76. package/dist/runtime/ui.config/elements/alert.js +1 -0
  77. package/dist/runtime/ui.config/forms/selectMenu.d.ts +1 -1
  78. package/dist/runtime/ui.config/overlays/notification.d.ts +1 -0
  79. package/dist/runtime/ui.config/overlays/notification.js +1 -0
  80. package/dist/runtime/utils/link.js +4 -2
  81. package/dist/types.d.mts +3 -1
  82. package/package.json +64 -38
  83. package/dist/module.cjs +0 -5
  84. package/dist/module.d.ts +0 -36
  85. package/dist/types.d.ts +0 -1
@@ -15,12 +15,12 @@ declare const config: {
15
15
  };
16
16
  default: {
17
17
  prevButton: {
18
- color: import("../../types/button").ButtonColor;
18
+ color: import("../../types/button.js").ButtonColor;
19
19
  class: string;
20
20
  icon: string;
21
21
  };
22
22
  nextButton: {
23
- color: import("../../types/button").ButtonColor;
23
+ color: import("../../types/button.js").ButtonColor;
24
24
  class: string;
25
25
  icon: string;
26
26
  };
@@ -85,12 +85,12 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
85
85
  };
86
86
  default: {
87
87
  prevButton: {
88
- color: import("../../types/button").ButtonColor;
88
+ color: import("../../types/button.js").ButtonColor;
89
89
  class: string;
90
90
  icon: string;
91
91
  };
92
92
  nextButton: {
93
- color: import("../../types/button").ButtonColor;
93
+ color: import("../../types/button.js").ButtonColor;
94
94
  class: string;
95
95
  icon: string;
96
96
  };
@@ -152,7 +152,6 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
152
152
  default: any;
153
153
  };
154
154
  }>> & Readonly<{}>, {
155
- class: any;
156
155
  ui: {
157
156
  wrapper?: string;
158
157
  container?: string;
@@ -168,12 +167,12 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
168
167
  }, any>;
169
168
  default?: DeepPartial<{
170
169
  prevButton: {
171
- color: import("../../types/button").ButtonColor;
170
+ color: import("../../types/button.js").ButtonColor;
172
171
  class: string;
173
172
  icon: string;
174
173
  };
175
174
  nextButton: {
176
- color: import("../../types/button").ButtonColor;
175
+ color: import("../../types/button.js").ButtonColor;
177
176
  class: string;
178
177
  icon: string;
179
178
  };
@@ -183,6 +182,7 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
183
182
  } & {
184
183
  strategy?: Strategy;
185
184
  };
185
+ class: any;
186
186
  items: any[];
187
187
  arrows: boolean;
188
188
  indicators: boolean;
@@ -220,17 +220,17 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
220
220
  default: boolean;
221
221
  };
222
222
  size: {
223
- type: PropType<import("../../types/button").ButtonSize>;
223
+ type: PropType<import("../../types/button.js").ButtonSize>;
224
224
  default: () => string;
225
225
  validator(value: string): boolean;
226
226
  };
227
227
  color: {
228
- type: PropType<import("../../types/button").ButtonColor>;
228
+ type: PropType<import("../../types/button.js").ButtonColor>;
229
229
  default: () => string;
230
230
  validator(value: string): boolean;
231
231
  };
232
232
  variant: {
233
- type: PropType<import("../../types/button").ButtonVariant>;
233
+ type: PropType<import("../../types/button.js").ButtonVariant>;
234
234
  default: () => string;
235
235
  validator(value: string): boolean;
236
236
  };
@@ -539,17 +539,17 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
539
539
  default: boolean;
540
540
  };
541
541
  size: {
542
- type: PropType<import("../../types/button").ButtonSize>;
542
+ type: PropType<import("../../types/button.js").ButtonSize>;
543
543
  default: () => string;
544
544
  validator(value: string): boolean;
545
545
  };
546
546
  color: {
547
- type: PropType<import("../../types/button").ButtonColor>;
547
+ type: PropType<import("../../types/button.js").ButtonColor>;
548
548
  default: () => string;
549
549
  validator(value: string): boolean;
550
550
  };
551
551
  variant: {
552
- type: PropType<import("../../types/button").ButtonVariant>;
552
+ type: PropType<import("../../types/button.js").ButtonVariant>;
553
553
  default: () => string;
554
554
  validator(value: string): boolean;
555
555
  };
@@ -741,10 +741,7 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
741
741
  };
742
742
  }>> & Readonly<{}>, {
743
743
  type: string;
744
- size: import("../../types/button").ButtonSize;
745
- class: any;
746
- to: string | import("vue-router").RouteLocationAsRelativeGeneric | import("vue-router").RouteLocationAsPathGeneric;
747
- disabled: boolean;
744
+ size: import("../../types/button.js").ButtonSize;
748
745
  ui: {
749
746
  base?: string;
750
747
  font?: string;
@@ -829,10 +826,11 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
829
826
  } & {
830
827
  strategy?: Strategy;
831
828
  };
832
- color: import("../../types/button").ButtonColor;
833
- variant: import("../../types/button").ButtonVariant;
829
+ color: import("../../types/button.js").ButtonColor;
830
+ variant: import("../../types/button.js").ButtonVariant;
834
831
  truncate: boolean;
835
832
  target: "_blank" | "_parent" | "_self" | "_top" | (string & {});
833
+ to: string | import("vue-router").RouteLocationAsRelativeGeneric | import("vue-router").RouteLocationAsPathGeneric;
836
834
  activeClass: string;
837
835
  exactActiveClass: string;
838
836
  ariaCurrentValue: "page" | "step" | "location" | "date" | "time" | "true" | "false";
@@ -843,12 +841,14 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
843
841
  prefetchedClass: string;
844
842
  external: boolean;
845
843
  leading: boolean;
844
+ disabled: boolean;
846
845
  href: string | import("vue-router").RouteLocationAsRelativeGeneric | import("vue-router").RouteLocationAsPathGeneric;
847
846
  rel: any;
848
- label: string;
849
847
  icon: string;
848
+ class: any;
850
849
  block: boolean;
851
850
  square: boolean;
851
+ label: string;
852
852
  loading: boolean;
853
853
  padded: boolean;
854
854
  loadingIcon: string;
@@ -1104,9 +1104,8 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
1104
1104
  };
1105
1105
  }>> & Readonly<{}>, {
1106
1106
  type: string;
1107
- to: string | import("vue-router").RouteLocationAsRelativeGeneric | import("vue-router").RouteLocationAsPathGeneric;
1108
- disabled: boolean;
1109
1107
  target: "_blank" | "_parent" | "_self" | "_top" | (string & {});
1108
+ to: string | import("vue-router").RouteLocationAsRelativeGeneric | import("vue-router").RouteLocationAsPathGeneric;
1110
1109
  activeClass: string;
1111
1110
  exactActiveClass: string;
1112
1111
  ariaCurrentValue: "page" | "step" | "location" | "date" | "time" | "true" | "false";
@@ -1117,6 +1116,7 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
1117
1116
  prefetchedClass: string;
1118
1117
  external: boolean;
1119
1118
  as: string;
1119
+ disabled: boolean;
1120
1120
  active: boolean;
1121
1121
  exact: boolean;
1122
1122
  exactQuery: boolean | "partial";
@@ -151,7 +151,6 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
151
151
  };
152
152
  }>> & Readonly<{}>, {
153
153
  size: "sm" | "xs" | "2xs" | "md" | "lg" | "xl" | "3xs" | "2xl" | "3xl";
154
- class: any;
155
154
  ui: {
156
155
  wrapper?: string;
157
156
  base?: string;
@@ -193,6 +192,7 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
193
192
  color: ChipColor;
194
193
  inset: boolean;
195
194
  position: "top-right" | "bottom-right" | "top-left" | "bottom-left";
195
+ class: any;
196
196
  text: string | number;
197
197
  show: boolean;
198
198
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
@@ -28,7 +28,7 @@
28
28
  <HMenuItem v-slot="{ active, disabled: itemDisabled, close }" :disabled="item.disabled">
29
29
  <component
30
30
  :is="!!href ? 'a' : 'button'"
31
- :href="!itemDisabled ? href : undefined"
31
+ :href="!itemDisabled ? href : void 0"
32
32
  :rel="rel"
33
33
  :target="target"
34
34
  :class="twMerge(twJoin(ui.item.base, ui.item.padding, ui.item.size, ui.item.rounded, active || isActive ? ui.item.active : ui.item.inactive, itemDisabled && ui.item.disabled), item.class)"
@@ -29,7 +29,7 @@ declare const config: {
29
29
  };
30
30
  avatar: {
31
31
  base: string;
32
- size: import("../../types/avatar").AvatarSize;
32
+ size: import("../../types/avatar.js").AvatarSize;
33
33
  };
34
34
  label: string;
35
35
  shortcuts: string;
@@ -128,7 +128,7 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
128
128
  };
129
129
  avatar: {
130
130
  base: string;
131
- size: import("../../types/avatar").AvatarSize;
131
+ size: import("../../types/avatar.js").AvatarSize;
132
132
  };
133
133
  label: string;
134
134
  shortcuts: string;
@@ -242,8 +242,6 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
242
242
  "onUpdate:open"?: (...args: any[]) => any;
243
243
  }>, {
244
244
  mode: "click" | "hover";
245
- class: any;
246
- disabled: boolean;
247
245
  ui: {
248
246
  wrapper?: string;
249
247
  container?: string;
@@ -272,7 +270,7 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
272
270
  };
273
271
  avatar: {
274
272
  base: string;
275
- size: import("../../types/avatar").AvatarSize;
273
+ size: import("../../types/avatar.js").AvatarSize;
276
274
  };
277
275
  label: string;
278
276
  shortcuts: string;
@@ -307,6 +305,8 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
307
305
  strategy?: Strategy;
308
306
  };
309
307
  popper: PopperOptions;
308
+ disabled: boolean;
309
+ class: any;
310
310
  open: boolean;
311
311
  items: DropdownItem[][];
312
312
  openDelay: number;
@@ -510,17 +510,17 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
510
510
  default: () => any;
511
511
  };
512
512
  size: {
513
- type: PropType<import("../../types/avatar").AvatarSize>;
513
+ type: PropType<import("../../types/avatar.js").AvatarSize>;
514
514
  default: () => string;
515
515
  validator(value: string): boolean;
516
516
  };
517
517
  chipColor: {
518
- type: PropType<import("../../types/avatar").AvatarChipColor>;
518
+ type: PropType<import("../../types/avatar.js").AvatarChipColor>;
519
519
  default: () => any;
520
520
  validator(value: string): boolean;
521
521
  };
522
522
  chipPosition: {
523
- type: PropType<import("../../types/avatar").AvatarChipPosition>;
523
+ type: PropType<import("../../types/avatar.js").AvatarChipPosition>;
524
524
  default: () => string;
525
525
  validator(value: string): boolean;
526
526
  };
@@ -693,17 +693,17 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
693
693
  default: () => any;
694
694
  };
695
695
  size: {
696
- type: PropType<import("../../types/avatar").AvatarSize>;
696
+ type: PropType<import("../../types/avatar.js").AvatarSize>;
697
697
  default: () => string;
698
698
  validator(value: string): boolean;
699
699
  };
700
700
  chipColor: {
701
- type: PropType<import("../../types/avatar").AvatarChipColor>;
701
+ type: PropType<import("../../types/avatar.js").AvatarChipColor>;
702
702
  default: () => any;
703
703
  validator(value: string): boolean;
704
704
  };
705
705
  chipPosition: {
706
- type: PropType<import("../../types/avatar").AvatarChipPosition>;
706
+ type: PropType<import("../../types/avatar.js").AvatarChipPosition>;
707
707
  default: () => string;
708
708
  validator(value: string): boolean;
709
709
  };
@@ -784,8 +784,7 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
784
784
  default: () => {};
785
785
  };
786
786
  }>> & Readonly<{}>, {
787
- size: import("../../types/avatar").AvatarSize;
788
- class: any;
787
+ size: import("../../types/avatar.js").AvatarSize;
789
788
  ui: {
790
789
  wrapper?: string;
791
790
  background?: string;
@@ -850,11 +849,12 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
850
849
  strategy?: Strategy;
851
850
  };
852
851
  as: string | Record<string, any>;
853
- text: string;
854
852
  alt: string;
855
853
  icon: string;
854
+ class: any;
855
+ text: string;
856
856
  src: string | boolean;
857
- chipColor: import("../../types/avatar").AvatarChipColor;
857
+ chipColor: import("../../types/avatar.js").AvatarChipColor;
858
858
  chipPosition: "top-right" | "bottom-right" | "top-left" | "bottom-left";
859
859
  chipText: string | number;
860
860
  imgClass: string;
@@ -911,7 +911,7 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
911
911
  default: any;
912
912
  };
913
913
  size: {
914
- type: PropType<import("../../types/kbd").KbdSize>;
914
+ type: PropType<import("../../types/kbd.js").KbdSize>;
915
915
  default: () => string;
916
916
  validator(value: string): boolean;
917
917
  };
@@ -967,7 +967,7 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
967
967
  default: any;
968
968
  };
969
969
  size: {
970
- type: PropType<import("../../types/kbd").KbdSize>;
970
+ type: PropType<import("../../types/kbd.js").KbdSize>;
971
971
  default: () => string;
972
972
  validator(value: string): boolean;
973
973
  };
@@ -997,8 +997,7 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
997
997
  default: () => {};
998
998
  };
999
999
  }>> & Readonly<{}>, {
1000
- size: import("../../types/kbd").KbdSize;
1001
- class: any;
1000
+ size: import("../../types/kbd.js").KbdSize;
1002
1001
  ui: {
1003
1002
  base?: string;
1004
1003
  padding?: string;
@@ -1019,6 +1018,7 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
1019
1018
  } & {
1020
1019
  strategy?: Strategy;
1021
1020
  };
1021
+ class: any;
1022
1022
  value: string;
1023
1023
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
1024
1024
  }, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
@@ -79,7 +79,6 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
79
79
  };
80
80
  }>> & Readonly<{}>, {
81
81
  size: KbdSize;
82
- class: any;
83
82
  ui: {
84
83
  base?: string;
85
84
  padding?: string;
@@ -100,6 +99,7 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
100
99
  } & {
101
100
  strategy?: Strategy;
102
101
  };
102
+ class: any;
103
103
  value: string;
104
104
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
105
105
  export default _default;
@@ -17,22 +17,22 @@
17
17
  >
18
18
  <a
19
19
  v-bind="$attrs"
20
- :href="!disabled ? href : undefined"
21
- :aria-disabled="disabled ? 'true' : undefined"
22
- :role="disabled ? 'link' : undefined"
20
+ :href="!disabled ? href : void 0"
21
+ :aria-disabled="disabled ? 'true' : void 0"
22
+ :role="disabled ? 'link' : void 0"
23
23
  :rel="rel"
24
24
  :target="target"
25
- :class="active !== undefined ? (active ? activeClass : inactiveClass) : resolveLinkClass(route, $route, { isActive, isExactActive })"
26
- :tabindex="disabled ? -1 : undefined"
27
- @click="(e) => (!isExternal && !disabled) && navigate(e)"
25
+ :class="active !== void 0 ? active ? activeClass : inactiveClass : resolveLinkClass(route, $route, { isActive, isExactActive })"
26
+ :tabindex="disabled ? -1 : void 0"
27
+ @click="(e) => !isExternal && !disabled && navigate(e)"
28
28
  >
29
- <slot v-bind="{ isActive: active !== undefined ? active : (exact ? isExactActive : isActive) }" />
29
+ <slot v-bind="{ isActive: active !== void 0 ? active : exact ? isExactActive : isActive }" />
30
30
  </a>
31
31
  </NuxtLink>
32
32
  </template>
33
33
 
34
34
  <script>
35
- import { isEqual, diff } from "ohash";
35
+ import { isEqual, diff } from "ohash/utils";
36
36
  import { defineComponent } from "vue";
37
37
  import { nuxtLinkProps } from "../../utils";
38
38
  export default defineComponent({
@@ -76,11 +76,13 @@ export default defineComponent({
76
76
  function isPartiallyEqual(item1, item2) {
77
77
  const diffedKeys = diff(item1, item2).reduce((filtered, q) => {
78
78
  if (q.type === "added") {
79
- filtered.push(q.key);
79
+ filtered.add(q.key);
80
80
  }
81
81
  return filtered;
82
- }, []);
83
- return isEqual(item1, item2, { excludeKeys: (key) => diffedKeys.includes(key) });
82
+ }, /* @__PURE__ */ new Set());
83
+ const item1Filtered = Object.fromEntries(Object.entries(item1).filter(([key]) => !diffedKeys.has(key)));
84
+ const item2Filtered = Object.fromEntries(Object.entries(item2).filter(([key]) => !diffedKeys.has(key)));
85
+ return isEqual(item1Filtered, item2Filtered);
84
86
  }
85
87
  function resolveLinkClass(route, $route, { isActive, isExactActive }) {
86
88
  if (props.exactQuery === "partial") {
@@ -202,9 +202,8 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
202
202
  };
203
203
  }>> & Readonly<{}>, {
204
204
  type: string;
205
- to: string | import("vue-router").RouteLocationAsRelativeGeneric | import("vue-router").RouteLocationAsPathGeneric;
206
- disabled: boolean;
207
205
  target: "_blank" | "_parent" | "_self" | "_top" | (string & {});
206
+ to: string | import("vue-router").RouteLocationAsRelativeGeneric | import("vue-router").RouteLocationAsPathGeneric;
208
207
  activeClass: string;
209
208
  exactActiveClass: string;
210
209
  ariaCurrentValue: "page" | "step" | "location" | "date" | "time" | "true" | "false";
@@ -215,6 +214,7 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
215
214
  prefetchedClass: string;
216
215
  external: boolean;
217
216
  as: string;
217
+ disabled: boolean;
218
218
  active: boolean;
219
219
  exact: boolean;
220
220
  exactQuery: boolean | "partial";
@@ -41,7 +41,6 @@ export default defineComponent({
41
41
  UIcon
42
42
  },
43
43
  inheritAttrs: false,
44
- slots: Object,
45
44
  props: {
46
45
  value: {
47
46
  type: Number,
@@ -90,6 +89,7 @@ export default defineComponent({
90
89
  default: () => ({})
91
90
  }
92
91
  },
92
+ slots: Object,
93
93
  setup(props) {
94
94
  const { ui, attrs } = useUI("meter", toRef(props, "ui"), config, toRef(props, "class"));
95
95
  function clampPercent(value, min, max) {
@@ -257,8 +257,6 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
257
257
  };
258
258
  }>> & Readonly<{}>, {
259
259
  size: "sm" | "xs" | "2xs" | "md" | "lg" | "xl" | "2xl";
260
- class: any;
261
- max: number;
262
260
  ui: {
263
261
  wrapper?: string;
264
262
  indicator?: DeepPartial<{
@@ -340,10 +338,12 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
340
338
  strategy?: Strategy;
341
339
  };
342
340
  color: MeterColor;
343
- label: string;
344
341
  icon: string;
342
+ class: any;
345
343
  value: number;
344
+ label: string;
346
345
  indicator: boolean;
346
+ max: number;
347
347
  min: number;
348
348
  }, SlotsType<{
349
349
  indicator?: {
@@ -14,7 +14,7 @@
14
14
  :class="progressClass"
15
15
  v-bind="{ value, max: realMax, ...attrs }"
16
16
  >
17
- {{ percent !== undefined ? `${Math.round(percent)}%` : undefined }}
17
+ {{ percent !== void 0 ? `${Math.round(percent)}%` : void 0 }}
18
18
  </progress>
19
19
 
20
20
  <div v-if="isSteps" :class="stepsClass">
@@ -93,7 +93,7 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
93
93
  from<T, U>(iterable: Iterable<T> | ArrayLike<T>, mapfn: (v: T, k: number) => U, thisArg?: any): U[];
94
94
  of<T>(...items: T[]): T[];
95
95
  fromAsync<T>(iterableOrArrayLike: AsyncIterable<T> | Iterable<T | PromiseLike<T>> | ArrayLike<T | PromiseLike<T>>): Promise<T[]>;
96
- fromAsync<T, U>(iterableOrArrayLike: AsyncIterable<T> | Iterable<T> | ArrayLike<T>, mapFn: (value: Awaited<T>) => U, thisArg?: any): Promise<Awaited<U>[]>;
96
+ fromAsync<T, U>(iterableOrArrayLike: AsyncIterable<T> | Iterable<T> | ArrayLike<T>, mapFn: (value: Awaited<T>, index: number) => U, thisArg?: any): Promise<Awaited<U>[]>;
97
97
  readonly [Symbol.species]: ArrayConstructor;
98
98
  })[];
99
99
  default: number;
@@ -233,7 +233,7 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
233
233
  from<T, U>(iterable: Iterable<T> | ArrayLike<T>, mapfn: (v: T, k: number) => U, thisArg?: any): U[];
234
234
  of<T>(...items: T[]): T[];
235
235
  fromAsync<T>(iterableOrArrayLike: AsyncIterable<T> | Iterable<T | PromiseLike<T>> | ArrayLike<T | PromiseLike<T>>): Promise<T[]>;
236
- fromAsync<T, U>(iterableOrArrayLike: AsyncIterable<T> | Iterable<T> | ArrayLike<T>, mapFn: (value: Awaited<T>) => U, thisArg?: any): Promise<Awaited<U>[]>;
236
+ fromAsync<T, U>(iterableOrArrayLike: AsyncIterable<T> | Iterable<T> | ArrayLike<T>, mapFn: (value: Awaited<T>, index: number) => U, thisArg?: any): Promise<Awaited<U>[]>;
237
237
  readonly [Symbol.species]: ArrayConstructor;
238
238
  })[];
239
239
  default: number;
@@ -269,9 +269,6 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
269
269
  };
270
270
  }>> & Readonly<{}>, {
271
271
  size: "sm" | "xs" | "2xs" | "md" | "lg" | "xl" | "2xl";
272
- class: any;
273
- max: number | any[];
274
- animation: "carousel" | "carousel-inverse" | "swing" | "elastic";
275
272
  ui: {
276
273
  wrapper?: string;
277
274
  indicator?: DeepPartial<{
@@ -351,7 +348,10 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
351
348
  strategy?: Strategy;
352
349
  };
353
350
  color: "primary" | "red" | "orange" | "amber" | "yellow" | "lime" | "green" | "emerald" | "teal" | "cyan" | "sky" | "blue" | "indigo" | "violet" | "purple" | "fuchsia" | "pink" | "rose";
351
+ class: any;
354
352
  value: number;
355
353
  indicator: boolean;
354
+ animation: "carousel" | "carousel-inverse" | "swing" | "elastic";
355
+ max: number | any[];
356
356
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
357
357
  export default _default;
@@ -164,8 +164,6 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
164
164
  }>, {
165
165
  name: string;
166
166
  required: boolean;
167
- class: any;
168
- disabled: boolean;
169
167
  ui: {
170
168
  wrapper?: string;
171
169
  container?: string;
@@ -189,10 +187,12 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
189
187
  strategy?: Strategy;
190
188
  };
191
189
  color: "primary" | "red" | "orange" | "amber" | "yellow" | "lime" | "green" | "emerald" | "teal" | "cyan" | "sky" | "blue" | "indigo" | "violet" | "purple" | "fuchsia" | "pink" | "rose";
192
- label: string;
190
+ disabled: boolean;
193
191
  id: string;
192
+ class: any;
194
193
  modelValue: boolean | any[];
195
194
  value: string | number | boolean | Record<string, any>;
195
+ label: string;
196
196
  help: string;
197
197
  indeterminate: boolean;
198
198
  inputClass: string;
@@ -162,23 +162,20 @@ function isJoiSchema(schema) {
162
162
  function isJoiError(error) {
163
163
  return error.isJoi === true;
164
164
  }
165
- function isValibotSchema(schema) {
166
- return "_parse" in schema || "_run" in schema || typeof schema === "function" && "schema" in schema;
165
+ export function isStandardSchema(schema) {
166
+ return "~standard" in schema;
167
167
  }
168
- function isZodSchema(schema) {
169
- return schema.parse !== void 0;
170
- }
171
- async function validateValibotSchema(state, schema) {
172
- const result = await ("_parse" in schema ? schema._parse(state) : "_run" in schema ? schema._run({ typed: false, value: state }, {}) : schema(state));
168
+ export async function validateStandardSchema(state, schema) {
169
+ const result = await schema["~standard"].validate(state);
173
170
  if (!result.issues || result.issues.length === 0) {
174
- const output = "output" in result ? result.output : "value" in result ? result.value : null;
171
+ const output = "value" in result ? result.value : null;
175
172
  return {
176
173
  errors: null,
177
174
  result: output
178
175
  };
179
176
  }
180
177
  const errors = result.issues.map((issue) => ({
181
- path: issue.path?.map((item) => item.key).join(".") || "",
178
+ path: issue.path?.map((item) => typeof item === "object" ? item.key : item).join(".") || "",
182
179
  message: issue.message
183
180
  }));
184
181
  return {
@@ -208,23 +205,6 @@ async function validateJoiSchema(state, schema) {
208
205
  }
209
206
  }
210
207
  }
211
- async function validateZodSchema(state, schema) {
212
- const result = await schema.safeParseAsync(state);
213
- if (result.success === false) {
214
- const errors = result.error.issues.map((issue) => ({
215
- path: issue.path.join("."),
216
- message: issue.message
217
- }));
218
- return {
219
- errors,
220
- result: null
221
- };
222
- }
223
- return {
224
- result: result.data,
225
- errors: null
226
- };
227
- }
228
208
  async function validateSuperstructSchema(state, schema) {
229
209
  const [err, result] = schema.validate(state);
230
210
  if (err) {
@@ -265,12 +245,10 @@ async function validateYupSchema(state, schema) {
265
245
  }
266
246
  }
267
247
  function parseSchema(state, schema) {
268
- if (isZodSchema(schema)) {
269
- return validateZodSchema(state, schema);
248
+ if (isStandardSchema(schema)) {
249
+ return validateStandardSchema(state, schema);
270
250
  } else if (isJoiSchema(schema)) {
271
251
  return validateJoiSchema(state, schema);
272
- } else if (isValibotSchema(schema)) {
273
- return validateValibotSchema(state, schema);
274
252
  } else if (isYupSchema(schema)) {
275
253
  return validateYupSchema(state, schema);
276
254
  } else if (isSuperStructSchema(schema)) {
@@ -1,13 +1,10 @@
1
1
  import { type PropType } from 'vue';
2
- import type { ZodSchema } from 'zod';
3
2
  import type { Schema as JoiSchema } from 'joi';
4
3
  import type { ObjectSchema as YupObjectSchema } from 'yup';
5
- import type { BaseSchema as ValibotSchema30, BaseSchemaAsync as ValibotSchemaAsync30 } from 'valibot30';
6
- import type { GenericSchema as ValibotSchema31, GenericSchemaAsync as ValibotSchemaAsync31, SafeParser as ValibotSafeParser31, SafeParserAsync as ValibotSafeParserAsync31 } from 'valibot31';
7
- import type { GenericSchema as ValibotSchema, GenericSchemaAsync as ValibotSchemaAsync, SafeParser as ValibotSafeParser, SafeParserAsync as ValibotSafeParserAsync } from 'valibot';
4
+ import type { StandardSchemaV1 } from '@standard-schema/spec';
8
5
  import type { Struct } from 'superstruct';
9
- import type { FormError, FormEventType } from '../../types/form.js';
10
- type Schema = PropType<ZodSchema> | PropType<YupObjectSchema<any>> | PropType<JoiSchema> | PropType<ValibotSchema30 | ValibotSchemaAsync30> | PropType<ValibotSchema31 | ValibotSchemaAsync31> | PropType<ValibotSafeParser31<any, any> | ValibotSafeParserAsync31<any, any>> | PropType<ValibotSchema | ValibotSchemaAsync> | PropType<ValibotSafeParser<any, any> | ValibotSafeParserAsync<any, any>> | PropType<Struct<any, any>>;
6
+ import type { FormError, FormEventType, ValidateReturnSchema } from '../../types/form.js';
7
+ type Schema = PropType<StandardSchemaV1> | PropType<YupObjectSchema<any>> | PropType<Struct<any, any>> | PropType<JoiSchema>;
11
8
  declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
12
9
  schema: {
13
10
  type: Schema;
@@ -52,11 +49,13 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
52
49
  default: () => string[];
53
50
  };
54
51
  }>> & Readonly<{
55
- onSubmit?: (...args: any[]) => any;
56
52
  onError?: (...args: any[]) => any;
53
+ onSubmit?: (...args: any[]) => any;
57
54
  }>, {
58
- schema: ZodSchema<any, import("zod").ZodTypeDef, any> | YupObjectSchema<any, import("yup").AnyObject, any, ""> | import("joi").AnySchema<any> | ValibotSchema30<any, any> | ValibotSchemaAsync30<any, any> | ValibotSchema31<unknown, unknown, import("valibot31").BaseIssue<unknown>> | ValibotSchemaAsync31<unknown, unknown, import("valibot31").BaseIssue<unknown>> | ValibotSafeParser31<any, any> | ValibotSafeParserAsync31<any, any> | ValibotSchema<unknown, unknown, import("valibot").BaseIssue<unknown>> | ValibotSchemaAsync<unknown, unknown, import("valibot").BaseIssue<unknown>> | Struct<any, any>;
55
+ schema: StandardSchemaV1<unknown, unknown> | YupObjectSchema<any, import("yup").AnyObject, any, ""> | Struct<any, any> | import("joi").AnySchema<any>;
59
56
  validate: ((state: any) => Promise<FormError[]>) | ((state: any) => FormError[]);
60
57
  validateOn: FormEventType[];
61
58
  }, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
62
59
  export default _default;
60
+ export declare function isStandardSchema(schema: any): schema is StandardSchemaV1;
61
+ export declare function validateStandardSchema(state: any, schema: StandardSchemaV1): Promise<ValidateReturnSchema<typeof state>>;
@@ -157,7 +157,6 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
157
157
  name: string;
158
158
  required: boolean;
159
159
  size: FormGroupSize;
160
- class: any;
161
160
  ui: {
162
161
  wrapper?: string;
163
162
  inner?: string;
@@ -187,9 +186,10 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
187
186
  } & {
188
187
  strategy?: Strategy;
189
188
  };
190
- label: string;
191
189
  error: string | boolean;
192
190
  description: string;
191
+ class: any;
192
+ label: string;
193
193
  help: string;
194
194
  hint: string;
195
195
  eagerValidation: boolean;