@volverjs/ui-vue 0.0.9-beta.1 → 0.0.9-beta.3

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 (79) hide show
  1. package/dist/components/VvAccordion/VvAccordion.es.js +7 -0
  2. package/dist/components/VvAccordionGroup/VvAccordionGroup.es.js +7 -0
  3. package/dist/components/VvAction/VvAction.es.js +9 -1
  4. package/dist/components/VvAction/VvAction.umd.js +1 -1
  5. package/dist/components/VvAction/VvAction.vue.d.ts +9 -0
  6. package/dist/components/VvAction/index.d.ts +4 -0
  7. package/dist/components/VvAlert/VvAlert.es.js +7 -0
  8. package/dist/components/VvAlertGroup/VvAlertGroup.es.js +7 -0
  9. package/dist/components/VvAvatar/VvAvatar.es.js +7 -0
  10. package/dist/components/VvAvatarGroup/VvAvatarGroup.es.js +7 -0
  11. package/dist/components/VvBadge/VvBadge.es.js +7 -0
  12. package/dist/components/VvBreadcrumb/VvBreadcrumb.es.js +7 -0
  13. package/dist/components/VvButton/VvButton.es.js +11 -2
  14. package/dist/components/VvButton/VvButton.umd.js +1 -1
  15. package/dist/components/VvButton/VvButton.vue.d.ts +9 -0
  16. package/dist/components/VvButton/index.d.ts +4 -0
  17. package/dist/components/VvButtonGroup/VvButtonGroup.es.js +7 -0
  18. package/dist/components/VvCard/VvCard.es.js +7 -0
  19. package/dist/components/VvCheckbox/VvCheckbox.es.js +7 -0
  20. package/dist/components/VvCheckboxGroup/VvCheckboxGroup.es.js +7 -0
  21. package/dist/components/VvCombobox/VvCombobox.es.js +17 -10
  22. package/dist/components/VvCombobox/VvCombobox.umd.js +1 -1
  23. package/dist/components/VvDialog/VvDialog.es.js +7 -0
  24. package/dist/components/VvDropdown/VvDropdown.es.js +19 -8
  25. package/dist/components/VvDropdown/VvDropdown.umd.js +1 -1
  26. package/dist/components/VvDropdown/VvDropdown.vue.d.ts +2 -9
  27. package/dist/components/VvDropdown/VvDropdownAction.vue.d.ts +9 -0
  28. package/dist/components/VvDropdown/index.d.ts +1 -7
  29. package/dist/components/VvDropdownAction/VvDropdownAction.es.js +9 -1
  30. package/dist/components/VvDropdownAction/VvDropdownAction.umd.js +1 -1
  31. package/dist/components/VvDropdownOptgroup/VvDropdownOptgroup.es.js +7 -0
  32. package/dist/components/VvDropdownOption/VvDropdownOption.es.js +7 -0
  33. package/dist/components/VvInputText/VvInputText.es.js +7 -0
  34. package/dist/components/VvNav/VvNav.es.js +10 -2
  35. package/dist/components/VvNav/VvNav.umd.js +1 -1
  36. package/dist/components/VvNav/index.d.ts +1 -1
  37. package/dist/components/VvProgress/VvProgress.es.js +7 -0
  38. package/dist/components/VvRadio/VvRadio.es.js +7 -0
  39. package/dist/components/VvRadioGroup/VvRadioGroup.es.js +7 -0
  40. package/dist/components/VvSelect/VvSelect.es.js +7 -0
  41. package/dist/components/VvTab/VvTab.es.js +10 -2
  42. package/dist/components/VvTab/VvTab.umd.js +1 -1
  43. package/dist/components/VvTextarea/VvTextarea.es.js +7 -0
  44. package/dist/components/VvTooltip/VvTooltip.es.js +7 -0
  45. package/dist/components/index.d.ts +5 -0
  46. package/dist/components/index.es.js +714 -314
  47. package/dist/components/index.umd.js +1 -1
  48. package/dist/directives/index.es.js +7 -0
  49. package/dist/directives/v-tooltip.es.js +7 -0
  50. package/dist/icons.es.js +3 -3
  51. package/dist/icons.umd.js +1 -1
  52. package/dist/props/index.d.ts +7 -0
  53. package/dist/stories/AccordionGroup/AccordionGroupSlots.stories.d.ts +43 -258
  54. package/dist/stories/Alert/Alert.settings.d.ts +3 -7
  55. package/dist/stories/Button/Button.settings.d.ts +3 -13
  56. package/dist/stories/Combobox/Combobox.settings.d.ts +3 -7
  57. package/dist/stories/Nav/Nav.settings.d.ts +3 -21
  58. package/package.json +28 -28
  59. package/src/assets/icons/detailed.json +1 -1
  60. package/src/assets/icons/normal.json +1 -1
  61. package/src/assets/icons/simple.json +1 -1
  62. package/src/components/VvAction/VvAction.vue +2 -1
  63. package/src/components/VvButton/VvButton.vue +1 -0
  64. package/src/components/VvDropdown/VvDropdown.vue +5 -1
  65. package/src/components/VvDropdown/index.ts +2 -8
  66. package/src/components/VvNav/VvNav.vue +1 -1
  67. package/src/components/VvNav/index.ts +1 -1
  68. package/src/components/index.ts +5 -0
  69. package/src/props/index.ts +7 -0
  70. package/src/stories/Alert/Alert.settings.ts +3 -1
  71. package/src/stories/Button/Button.settings.ts +5 -3
  72. package/src/stories/Combobox/Combobox.settings.ts +4 -1
  73. package/src/stories/Nav/Nav.settings.ts +3 -1
  74. package/src/stories/Tab/Tab.stories.ts +3 -3
  75. package/src/stories/Textarea/TextareaLength.stories.ts +1 -1
  76. /package/dist/components/{VvNavItemTitle → VvNav}/VvNavItemTitle.vue.d.ts +0 -0
  77. /package/dist/components/{VvNavSeparator → VvNav}/VvNavSeparator.d.ts +0 -0
  78. /package/src/components/{VvNavItemTitle → VvNav}/VvNavItemTitle.vue +0 -0
  79. /package/src/components/{VvNavSeparator → VvNav}/VvNavSeparator.ts +0 -0
@@ -79,6 +79,9 @@ const INJECTION_KEY_DROPDOWN_ITEM = Symbol.for(
79
79
  const INJECTION_KEY_DROPDOWN_ACTION = Symbol.for(
80
80
  "dropdownAction"
81
81
  );
82
+ const INJECTION_KEY_ALERT_GROUP = Symbol.for(
83
+ "alertGroup"
84
+ );
82
85
  const LinkProps = {
83
86
  /**
84
87
  * The router-link/nuxt-link property, if it is defined the button is rendered as a ruouter-link or nuxt-link.
@@ -484,6 +487,13 @@ const ActionProps = {
484
487
  type: String,
485
488
  default: ButtonType.button,
486
489
  validator: (value) => Object.values(ButtonType).includes(value)
490
+ },
491
+ /**
492
+ * Button aria-label
493
+ */
494
+ ariaLabel: {
495
+ type: String,
496
+ default: void 0
487
497
  }
488
498
  };
489
499
  function equals(obj1, obj2, field) {
@@ -723,14 +733,14 @@ function useModifiers(prefix, modifiers, others) {
723
733
  return toReturn;
724
734
  });
725
735
  }
726
- const _hoisted_1$f = ["id", "open"];
727
- const _hoisted_2$c = ["aria-controls", "aria-expanded"];
728
- const _hoisted_3$6 = ["aria-hidden"];
729
- const __default__$m = {
736
+ const _hoisted_1$i = ["id", "open"];
737
+ const _hoisted_2$d = ["aria-controls", "aria-expanded"];
738
+ const _hoisted_3$7 = ["aria-hidden"];
739
+ const __default__$n = {
730
740
  name: "VvAccordion"
731
741
  };
732
- const _sfc_main$m = /* @__PURE__ */ defineComponent({
733
- ...__default__$m,
742
+ const _sfc_main$q = /* @__PURE__ */ defineComponent({
743
+ ...__default__$n,
734
744
  props: VvAccordionProps,
735
745
  emits: VvAccordionEvents,
736
746
  setup(__props, { emit }) {
@@ -812,7 +822,7 @@ const _sfc_main$m = /* @__PURE__ */ defineComponent({
812
822
  renderSlot(_ctx.$slots, "summary", normalizeProps(guardReactiveProps({ open: unref(isOpen) })), () => [
813
823
  createTextVNode(toDisplayString(unref(title)), 1)
814
824
  ])
815
- ], 8, _hoisted_2$c),
825
+ ], 8, _hoisted_2$d),
816
826
  createElementVNode("div", {
817
827
  "aria-hidden": !unref(isOpen),
818
828
  class: "vv-accordion__content"
@@ -820,8 +830,8 @@ const _sfc_main$m = /* @__PURE__ */ defineComponent({
820
830
  renderSlot(_ctx.$slots, "default", normalizeProps(guardReactiveProps({ open: unref(isOpen) })), () => [
821
831
  createTextVNode(toDisplayString(unref(content)), 1)
822
832
  ])
823
- ], 8, _hoisted_3$6)
824
- ], 10, _hoisted_1$f);
833
+ ], 8, _hoisted_3$7)
834
+ ], 10, _hoisted_1$i);
825
835
  };
826
836
  }
827
837
  });
@@ -874,11 +884,11 @@ function useProvideGroupState(groupState) {
874
884
  computed(() => groupState)
875
885
  );
876
886
  }
877
- const __default__$l = {
887
+ const __default__$m = {
878
888
  name: "VvAccordionGroup"
879
889
  };
880
- const _sfc_main$l = /* @__PURE__ */ defineComponent({
881
- ...__default__$l,
890
+ const _sfc_main$p = /* @__PURE__ */ defineComponent({
891
+ ...__default__$m,
882
892
  props: VvAccordionGroupProps,
883
893
  emits: VvAccordionGroupEvents,
884
894
  setup(__props, { emit }) {
@@ -945,7 +955,7 @@ const _sfc_main$l = /* @__PURE__ */ defineComponent({
945
955
  }, [
946
956
  renderSlot(_ctx.$slots, "default", {}, () => [
947
957
  (openBlock(true), createElementBlock(Fragment, null, renderList(unref(items), (item) => {
948
- return openBlock(), createBlock(_sfc_main$m, mergeProps({
958
+ return openBlock(), createBlock(_sfc_main$q, mergeProps({
949
959
  key: item.title
950
960
  }, {
951
961
  name: item.name,
@@ -966,88 +976,128 @@ const _sfc_main$l = /* @__PURE__ */ defineComponent({
966
976
  };
967
977
  }
968
978
  });
969
- const VvBadgeProps = {
970
- ...ModifiersProps,
971
- value: [String, Number]
972
- };
973
- const __default__$k = {
974
- name: "VvBadge"
979
+ const VvActionEvents = ["click", "mouseover", "mouseleave"];
980
+ const VvActionProps = ActionProps;
981
+ function useVolver() {
982
+ return inject(INJECTION_KEY_VOLVER);
983
+ }
984
+ function useInjectedDropdownTrigger() {
985
+ return inject(INJECTION_KEY_DROPDOWN_TRIGGER, {});
986
+ }
987
+ function useInjectedDropdownItem() {
988
+ return inject(INJECTION_KEY_DROPDOWN_ITEM, {});
989
+ }
990
+ function useInjectedDropdownAction() {
991
+ return inject(INJECTION_KEY_DROPDOWN_ACTION, {});
992
+ }
993
+ const __default__$l = {
994
+ name: "VvAction"
975
995
  };
976
- const _sfc_main$k = /* @__PURE__ */ defineComponent({
977
- ...__default__$k,
978
- props: VvBadgeProps,
979
- setup(__props) {
996
+ const _sfc_main$o = /* @__PURE__ */ defineComponent({
997
+ ...__default__$l,
998
+ props: VvActionProps,
999
+ emits: VvActionEvents,
1000
+ setup(__props, { expose: __expose, emit }) {
980
1001
  const props = __props;
981
- const { modifiers } = toRefs(props);
982
- const bemCssClasses = useModifiers("vv-badge", modifiers);
983
- return (_ctx, _cache) => {
984
- return openBlock(), createElementBlock("span", {
985
- class: normalizeClass(unref(bemCssClasses)),
986
- role: "status"
987
- }, [
988
- renderSlot(_ctx.$slots, "default", {}, () => [
989
- createTextVNode(toDisplayString(_ctx.value), 1)
990
- ])
991
- ], 2);
1002
+ const volver = useVolver();
1003
+ const element = ref(null);
1004
+ __expose({ $el: element });
1005
+ const {
1006
+ reference: dropdownTriggerReference,
1007
+ bus: dropdownEventBus,
1008
+ aria: dropdownAria,
1009
+ expanded: dropdownExpanded
1010
+ } = useInjectedDropdownTrigger();
1011
+ watch(
1012
+ () => element.value,
1013
+ (newValue) => {
1014
+ if (dropdownTriggerReference) {
1015
+ dropdownTriggerReference.value = newValue;
1016
+ }
1017
+ }
1018
+ );
1019
+ const pressed = computed(() => {
1020
+ return props.pressed || (dropdownExpanded == null ? void 0 : dropdownExpanded.value);
1021
+ });
1022
+ const { role } = useInjectedDropdownAction();
1023
+ const hasTag = computed(() => {
1024
+ switch (true) {
1025
+ case props.disabled:
1026
+ return ActionTag.button;
1027
+ case props.to !== void 0:
1028
+ return (volver == null ? void 0 : volver.nuxt) ? ActionTag.nuxtLink : ActionTag.routerLink;
1029
+ case props.href !== void 0:
1030
+ return ActionTag.a;
1031
+ default:
1032
+ return ActionTag.button;
1033
+ }
1034
+ });
1035
+ const hasProps = computed(() => {
1036
+ const toReturn = {
1037
+ ...dropdownAria == null ? void 0 : dropdownAria.value,
1038
+ ariaPressed: pressed.value ? true : void 0,
1039
+ ariaLabel: props.ariaLabel,
1040
+ role: role == null ? void 0 : role.value
1041
+ };
1042
+ switch (hasTag.value) {
1043
+ case ActionTag.a:
1044
+ return {
1045
+ ...toReturn,
1046
+ href: props.href,
1047
+ target: props.target,
1048
+ rel: props.rel
1049
+ };
1050
+ case ActionTag.routerLink:
1051
+ case ActionTag.nuxtLink:
1052
+ return {
1053
+ ...toReturn,
1054
+ to: props.to,
1055
+ target: props.target
1056
+ };
1057
+ default:
1058
+ return {
1059
+ ...toReturn,
1060
+ type: props.type,
1061
+ disabled: props.disabled
1062
+ };
1063
+ }
1064
+ });
1065
+ const onClick = (e) => {
1066
+ if (props.disabled) {
1067
+ e.preventDefault();
1068
+ return;
1069
+ }
1070
+ dropdownEventBus == null ? void 0 : dropdownEventBus.emit("click", e);
1071
+ emit("click", e);
1072
+ };
1073
+ const onMouseover = (e) => {
1074
+ dropdownEventBus == null ? void 0 : dropdownEventBus.emit("mouseover", e);
1075
+ emit("mouseover", e);
1076
+ };
1077
+ const onMouseleave = (e) => {
1078
+ dropdownEventBus == null ? void 0 : dropdownEventBus.emit("mouseleave", e);
1079
+ emit("mouseleave", e);
992
1080
  };
993
- }
994
- });
995
- const VvBreadcrumbProps = {
996
- ...ModifiersProps,
997
- routes: Array
998
- };
999
- const _hoisted_1$e = { class: "vv-breadcrumb__list" };
1000
- const _hoisted_2$b = ["content"];
1001
- const __default__$j = {
1002
- name: "VvBreadcrumb"
1003
- };
1004
- const _sfc_main$j = /* @__PURE__ */ defineComponent({
1005
- ...__default__$j,
1006
- props: VvBreadcrumbProps,
1007
- setup(__props) {
1008
- const props = __props;
1009
- const { modifiers } = toRefs(props);
1010
- const bemCssClasses = useModifiers("vv-breadcrumb", modifiers);
1011
1081
  return (_ctx, _cache) => {
1012
- return openBlock(), createElementBlock("nav", {
1013
- class: normalizeClass(unref(bemCssClasses)),
1014
- "aria-label": "breadcrumbs"
1015
- }, [
1016
- createElementVNode("ol", _hoisted_1$e, [
1017
- (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.routes, (route, index) => {
1018
- var _a, _b, _c, _d;
1019
- return openBlock(), createElementBlock("li", {
1020
- key: `${route.label}-${index}`,
1021
- class: normalizeClass({
1022
- "vv-breadcrumb__item": index < Number((_a = _ctx.routes) == null ? void 0 : _a.length) - 1,
1023
- "vv-breadcrumb__item-active": index === Number((_b = _ctx.routes) == null ? void 0 : _b.length) - 1
1024
- }),
1025
- itemprop: "itemListElement",
1026
- itemtype: "https://schema.org/ListItem",
1027
- itemscope: ""
1028
- }, [
1029
- (openBlock(), createBlock(resolveDynamicComponent(route.to ? "router-link" : route.href ? "a" : "span"), mergeProps(route, {
1030
- class: {
1031
- "vv-breadcrumb__link": index < Number((_c = _ctx.routes) == null ? void 0 : _c.length) - 1
1032
- },
1033
- "aria-current": index === Number((_d = _ctx.routes) == null ? void 0 : _d.length) - 1 ? "page" : void 0,
1034
- itemprop: "item"
1035
- }), {
1036
- default: withCtx(() => [
1037
- renderSlot(_ctx.$slots, "label", normalizeProps(guardReactiveProps({ route, index })), () => [
1038
- createTextVNode(toDisplayString(route.label), 1)
1039
- ])
1040
- ]),
1041
- _: 2
1042
- }, 1040, ["class", "aria-current"])),
1043
- createElementVNode("meta", {
1044
- itemprop: "position",
1045
- content: `${index + 1}`
1046
- }, null, 8, _hoisted_2$b)
1047
- ], 2);
1048
- }), 128))
1049
- ])
1050
- ], 2);
1082
+ return openBlock(), createBlock(resolveDynamicComponent(unref(hasTag)), mergeProps(unref(hasProps), {
1083
+ ref_key: "element",
1084
+ ref: element,
1085
+ class: {
1086
+ active: _ctx.active,
1087
+ pressed: unref(pressed),
1088
+ disabled: _ctx.disabled
1089
+ },
1090
+ onClickPassive: onClick,
1091
+ onMouseoverPassive: onMouseover,
1092
+ onMouseleavePassive: onMouseleave
1093
+ }), {
1094
+ default: withCtx(() => [
1095
+ renderSlot(_ctx.$slots, "default", {}, () => [
1096
+ createTextVNode(toDisplayString(_ctx.label), 1)
1097
+ ])
1098
+ ]),
1099
+ _: 3
1100
+ }, 16, ["class"]);
1051
1101
  };
1052
1102
  }
1053
1103
  });
@@ -1145,14 +1195,11 @@ const VvIconProps = {
1145
1195
  type: [String, Array]
1146
1196
  }
1147
1197
  };
1148
- function useVolver() {
1149
- return inject(INJECTION_KEY_VOLVER);
1150
- }
1151
- const __default__$i = {
1198
+ const __default__$k = {
1152
1199
  name: "VvIcon"
1153
1200
  };
1154
- const _sfc_main$i = /* @__PURE__ */ defineComponent({
1155
- ...__default__$i,
1201
+ const _sfc_main$n = /* @__PURE__ */ defineComponent({
1202
+ ...__default__$k,
1156
1203
  props: VvIconProps,
1157
1204
  setup(__props) {
1158
1205
  const props = __props;
@@ -1244,124 +1291,306 @@ const _sfc_main$i = /* @__PURE__ */ defineComponent({
1244
1291
  };
1245
1292
  }
1246
1293
  });
1247
- const VvActionEvents = ["click", "mouseover", "mouseleave"];
1248
- const VvActionProps = ActionProps;
1249
- function useInjectedDropdownTrigger() {
1250
- return inject(INJECTION_KEY_DROPDOWN_TRIGGER, {});
1251
- }
1252
- function useInjectedDropdownItem() {
1253
- return inject(INJECTION_KEY_DROPDOWN_ITEM, {});
1294
+ function useInjectedAlertGroup() {
1295
+ return inject(INJECTION_KEY_ALERT_GROUP, {});
1254
1296
  }
1255
- function useInjectedDropdownAction() {
1256
- return inject(INJECTION_KEY_DROPDOWN_ACTION, {});
1257
- }
1258
- const __default__$h = {
1259
- name: "VvAction"
1297
+ const useUniqueId = (id) => computed(() => String((id == null ? void 0 : id.value) || nanoid()));
1298
+ const VvAlertProps = {
1299
+ ...IdProps,
1300
+ ...ModifiersProps,
1301
+ ...IconProps,
1302
+ /**
1303
+ * The alert is dismissable
1304
+ * @default false
1305
+ * @type boolean
1306
+ */
1307
+ dismissable: {
1308
+ type: Boolean,
1309
+ default: false
1310
+ },
1311
+ /**
1312
+ * The alert auto close after the specified time in milliseconds
1313
+ * @default 0
1314
+ * @type number
1315
+ */
1316
+ autoClose: {
1317
+ type: Number,
1318
+ default: 0
1319
+ },
1320
+ /**
1321
+ * The alert close label
1322
+ * @default 'Close'
1323
+ * @type string
1324
+ */
1325
+ closeLabel: {
1326
+ type: String,
1327
+ default: "Close"
1328
+ },
1329
+ /**
1330
+ * The alert title
1331
+ * @default ''
1332
+ * @type string
1333
+ */
1334
+ title: {
1335
+ type: String,
1336
+ default: ""
1337
+ },
1338
+ /**
1339
+ * The alert content
1340
+ * @default ''
1341
+ * @type string
1342
+ */
1343
+ content: {
1344
+ type: String,
1345
+ default: ""
1346
+ },
1347
+ /**
1348
+ * The alert footer
1349
+ * @default ''
1350
+ * @type string
1351
+ */
1352
+ footer: {
1353
+ type: String,
1354
+ default: ""
1355
+ },
1356
+ /**
1357
+ * The alert role
1358
+ * @default 'alert'
1359
+ * @type string
1360
+ * @values 'alert', 'alertdialog'
1361
+ * @see https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Roles/Alert_Role
1362
+ * @see https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Roles/Alertdialog_role
1363
+ */
1364
+ role: {
1365
+ type: String,
1366
+ default: "alert"
1367
+ }
1260
1368
  };
1261
- const _sfc_main$h = /* @__PURE__ */ defineComponent({
1262
- ...__default__$h,
1263
- props: VvActionProps,
1264
- emits: VvActionEvents,
1265
- setup(__props, { expose: __expose, emit }) {
1266
- const props = __props;
1267
- const volver = useVolver();
1268
- const element = ref(null);
1269
- __expose({ $el: element });
1270
- const {
1271
- reference: dropdownTriggerReference,
1272
- bus: dropdownEventBus,
1273
- aria: dropdownAria,
1274
- expanded: dropdownExpanded
1275
- } = useInjectedDropdownTrigger();
1276
- watch(
1277
- () => element.value,
1278
- (newValue) => {
1279
- if (dropdownTriggerReference) {
1280
- dropdownTriggerReference.value = newValue;
1281
- }
1282
- }
1283
- );
1284
- const pressed = computed(() => {
1285
- return props.pressed || (dropdownExpanded == null ? void 0 : dropdownExpanded.value);
1286
- });
1287
- const { role } = useInjectedDropdownAction();
1288
- const hasTag = computed(() => {
1289
- switch (true) {
1290
- case props.disabled:
1291
- return ActionTag.button;
1292
- case props.to !== void 0:
1293
- return (volver == null ? void 0 : volver.nuxt) ? ActionTag.nuxtLink : ActionTag.routerLink;
1294
- case props.href !== void 0:
1295
- return ActionTag.a;
1296
- default:
1297
- return ActionTag.button;
1298
- }
1299
- });
1300
- const hasProps = computed(() => {
1301
- const toReturn = {
1302
- ...dropdownAria == null ? void 0 : dropdownAria.value,
1303
- "aria-pressed": pressed.value ? true : void 0,
1304
- role: role == null ? void 0 : role.value
1305
- };
1306
- switch (hasTag.value) {
1307
- case ActionTag.a:
1308
- return {
1309
- ...toReturn,
1310
- href: props.href,
1311
- target: props.target,
1312
- rel: props.rel
1313
- };
1314
- case ActionTag.routerLink:
1315
- case ActionTag.nuxtLink:
1316
- return {
1317
- ...toReturn,
1318
- to: props.to,
1319
- target: props.target
1320
- };
1321
- default:
1322
- return {
1323
- ...toReturn,
1324
- type: props.type,
1325
- disabled: props.disabled
1326
- };
1327
- }
1328
- });
1329
- const onClick = (e) => {
1330
- if (props.disabled) {
1331
- e.preventDefault();
1369
+ const VvAlertEvents = ["close"];
1370
+ const useVvAlert = (props, emit) => {
1371
+ const { bus } = useInjectedAlertGroup();
1372
+ const hasId = useUniqueId(computed(() => props.id));
1373
+ const hasTitleId = computed(() => `${hasId.value}-title`);
1374
+ const hasIcon = computed(
1375
+ () => typeof props.icon === "string" ? { name: props.icon } : props.icon
1376
+ );
1377
+ const hasClass = useModifiers(
1378
+ "vv-alert",
1379
+ computed(() => props.modifiers),
1380
+ computed(() => ({
1381
+ dismissable: props.autoClose > 0 || props.dismissable,
1382
+ "auto-close": props.autoClose > 0,
1383
+ hover: isMouseover.value
1384
+ }))
1385
+ );
1386
+ const hasStyle = computed(() => ({
1387
+ "--alert-duration": `${props.autoClose}ms`
1388
+ }));
1389
+ const close = () => {
1390
+ if (timeout) {
1391
+ clearTimeout(timeout);
1392
+ }
1393
+ emit("close", hasId.value);
1394
+ bus == null ? void 0 : bus.emit("close", hasId.value);
1395
+ };
1396
+ let timeout;
1397
+ watch(
1398
+ () => props.autoClose,
1399
+ (value) => {
1400
+ if (value > 0) {
1401
+ timeout = setTimeout(close, value);
1332
1402
  return;
1333
1403
  }
1334
- dropdownEventBus == null ? void 0 : dropdownEventBus.emit("click", e);
1335
- emit("click", e);
1336
- };
1337
- const onMouseover = (e) => {
1338
- dropdownEventBus == null ? void 0 : dropdownEventBus.emit("mouseover", e);
1339
- emit("mouseover", e);
1340
- };
1341
- const onMouseleave = (e) => {
1342
- dropdownEventBus == null ? void 0 : dropdownEventBus.emit("mouseleave", e);
1343
- emit("mouseleave", e);
1344
- };
1404
+ if (timeout) {
1405
+ clearTimeout(timeout);
1406
+ }
1407
+ },
1408
+ {
1409
+ immediate: true
1410
+ }
1411
+ );
1412
+ const isMouseover = ref(false);
1413
+ const onMouseover = withModifiers(() => {
1414
+ isMouseover.value = true;
1415
+ if (timeout) {
1416
+ clearTimeout(timeout);
1417
+ }
1418
+ }, ["passive"]);
1419
+ const onMouseleave = withModifiers(() => {
1420
+ isMouseover.value = false;
1421
+ if (props.autoClose > 0) {
1422
+ timeout = setTimeout(close, props.autoClose);
1423
+ }
1424
+ }, ["passive"]);
1425
+ return {
1426
+ close,
1427
+ hasIcon,
1428
+ hasTitleId,
1429
+ hasProps: computed(() => ({
1430
+ onMouseover,
1431
+ onMouseleave,
1432
+ class: hasClass.value,
1433
+ style: hasStyle.value,
1434
+ role: props.role,
1435
+ "aria-labelledby": hasTitleId.value
1436
+ }))
1437
+ };
1438
+ };
1439
+ const _hoisted_1$h = {
1440
+ key: 0,
1441
+ class: "vv-alert__header"
1442
+ };
1443
+ const _hoisted_2$c = ["id"];
1444
+ const _hoisted_3$6 = ["aria-label"];
1445
+ const _hoisted_4$4 = /* @__PURE__ */ createElementVNode("div", { class: "vv-alert__close-mask" }, null, -1);
1446
+ const _hoisted_5$4 = [
1447
+ _hoisted_4$4
1448
+ ];
1449
+ const _hoisted_6$4 = {
1450
+ key: 1,
1451
+ class: "vv-alert__content"
1452
+ };
1453
+ const _hoisted_7$4 = {
1454
+ key: 2,
1455
+ class: "vv-alert__footer"
1456
+ };
1457
+ const __default__$j = {
1458
+ name: "VvAlert"
1459
+ };
1460
+ const _sfc_main$m = /* @__PURE__ */ defineComponent({
1461
+ ...__default__$j,
1462
+ props: VvAlertProps,
1463
+ emits: VvAlertEvents,
1464
+ setup(__props, { expose: __expose, emit }) {
1465
+ const props = __props;
1466
+ const { hasProps, hasTitleId, hasIcon, close } = useVvAlert(props, emit);
1467
+ __expose({ close });
1345
1468
  return (_ctx, _cache) => {
1346
- return openBlock(), createBlock(resolveDynamicComponent(unref(hasTag)), mergeProps(unref(hasProps), {
1347
- ref_key: "element",
1348
- ref: element,
1349
- class: {
1350
- active: _ctx.active,
1351
- pressed: unref(pressed),
1352
- disabled: _ctx.disabled
1353
- },
1354
- onClickPassive: onClick,
1355
- onMouseoverPassive: onMouseover,
1356
- onMouseleavePassive: onMouseleave
1357
- }), {
1358
- default: withCtx(() => [
1469
+ return openBlock(), createElementBlock("div", normalizeProps(guardReactiveProps(unref(hasProps))), [
1470
+ _ctx.$slots.header || _ctx.$slots.title || _ctx.$slots.close || _ctx.$slots["title::before"] || _ctx.$slots["title::after"] || _ctx.title || _ctx.dismissable || _ctx.autoClose ? (openBlock(), createElementBlock("div", _hoisted_1$h, [
1471
+ unref(hasIcon) ? (openBlock(), createBlock(_sfc_main$n, mergeProps({ key: 0 }, unref(hasIcon), { class: "vv-alert__icon" }), null, 16)) : createCommentVNode("", true),
1472
+ renderSlot(_ctx.$slots, "header", {}, () => [
1473
+ renderSlot(_ctx.$slots, "title::before"),
1474
+ createElementVNode("strong", {
1475
+ id: unref(hasTitleId),
1476
+ class: "vv-alert__title"
1477
+ }, [
1478
+ renderSlot(_ctx.$slots, "title", {}, () => [
1479
+ createTextVNode(toDisplayString(_ctx.title), 1)
1480
+ ])
1481
+ ], 8, _hoisted_2$c),
1482
+ renderSlot(_ctx.$slots, "title::after")
1483
+ ]),
1484
+ renderSlot(_ctx.$slots, "close", normalizeProps(guardReactiveProps({ close: unref(close) })), () => [
1485
+ _ctx.dismissable || _ctx.autoClose ? (openBlock(), createElementBlock("button", {
1486
+ key: 0,
1487
+ class: "vv-alert__close",
1488
+ type: "button",
1489
+ "aria-label": _ctx.closeLabel,
1490
+ onClick: _cache[0] || (_cache[0] = withModifiers(
1491
+ //@ts-ignore
1492
+ (...args) => unref(close) && unref(close)(...args),
1493
+ ["stop"]
1494
+ ))
1495
+ }, _hoisted_5$4, 8, _hoisted_3$6)) : createCommentVNode("", true)
1496
+ ])
1497
+ ])) : createCommentVNode("", true),
1498
+ _ctx.$slots.default || _ctx.content ? (openBlock(), createElementBlock("div", _hoisted_6$4, [
1359
1499
  renderSlot(_ctx.$slots, "default", {}, () => [
1360
- createTextVNode(toDisplayString(_ctx.label), 1)
1500
+ createTextVNode(toDisplayString(_ctx.content), 1)
1361
1501
  ])
1362
- ]),
1363
- _: 3
1364
- }, 16, ["class"]);
1502
+ ])) : createCommentVNode("", true),
1503
+ _ctx.$slots.footer || _ctx.footer ? (openBlock(), createElementBlock("div", _hoisted_7$4, [
1504
+ renderSlot(_ctx.$slots, "footer", {}, () => [
1505
+ createTextVNode(toDisplayString(_ctx.footer), 1)
1506
+ ])
1507
+ ])) : createCommentVNode("", true)
1508
+ ], 16);
1509
+ };
1510
+ }
1511
+ });
1512
+ const VvBadgeProps = {
1513
+ ...ModifiersProps,
1514
+ value: [String, Number]
1515
+ };
1516
+ const __default__$i = {
1517
+ name: "VvBadge"
1518
+ };
1519
+ const _sfc_main$l = /* @__PURE__ */ defineComponent({
1520
+ ...__default__$i,
1521
+ props: VvBadgeProps,
1522
+ setup(__props) {
1523
+ const props = __props;
1524
+ const { modifiers } = toRefs(props);
1525
+ const bemCssClasses = useModifiers("vv-badge", modifiers);
1526
+ return (_ctx, _cache) => {
1527
+ return openBlock(), createElementBlock("span", {
1528
+ class: normalizeClass(unref(bemCssClasses)),
1529
+ role: "status"
1530
+ }, [
1531
+ renderSlot(_ctx.$slots, "default", {}, () => [
1532
+ createTextVNode(toDisplayString(_ctx.value), 1)
1533
+ ])
1534
+ ], 2);
1535
+ };
1536
+ }
1537
+ });
1538
+ const VvBreadcrumbProps = {
1539
+ ...ModifiersProps,
1540
+ routes: Array
1541
+ };
1542
+ const _hoisted_1$g = { class: "vv-breadcrumb__list" };
1543
+ const _hoisted_2$b = ["content"];
1544
+ const __default__$h = {
1545
+ name: "VvBreadcrumb"
1546
+ };
1547
+ const _sfc_main$k = /* @__PURE__ */ defineComponent({
1548
+ ...__default__$h,
1549
+ props: VvBreadcrumbProps,
1550
+ setup(__props) {
1551
+ const props = __props;
1552
+ const { modifiers } = toRefs(props);
1553
+ const bemCssClasses = useModifiers("vv-breadcrumb", modifiers);
1554
+ return (_ctx, _cache) => {
1555
+ return openBlock(), createElementBlock("nav", {
1556
+ class: normalizeClass(unref(bemCssClasses)),
1557
+ "aria-label": "breadcrumbs"
1558
+ }, [
1559
+ createElementVNode("ol", _hoisted_1$g, [
1560
+ (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.routes, (route, index) => {
1561
+ var _a, _b, _c, _d;
1562
+ return openBlock(), createElementBlock("li", {
1563
+ key: `${route.label}-${index}`,
1564
+ class: normalizeClass({
1565
+ "vv-breadcrumb__item": index < Number((_a = _ctx.routes) == null ? void 0 : _a.length) - 1,
1566
+ "vv-breadcrumb__item-active": index === Number((_b = _ctx.routes) == null ? void 0 : _b.length) - 1
1567
+ }),
1568
+ itemprop: "itemListElement",
1569
+ itemtype: "https://schema.org/ListItem",
1570
+ itemscope: ""
1571
+ }, [
1572
+ (openBlock(), createBlock(resolveDynamicComponent(route.to ? "router-link" : route.href ? "a" : "span"), mergeProps(route, {
1573
+ class: {
1574
+ "vv-breadcrumb__link": index < Number((_c = _ctx.routes) == null ? void 0 : _c.length) - 1
1575
+ },
1576
+ "aria-current": index === Number((_d = _ctx.routes) == null ? void 0 : _d.length) - 1 ? "page" : void 0,
1577
+ itemprop: "item"
1578
+ }), {
1579
+ default: withCtx(() => [
1580
+ renderSlot(_ctx.$slots, "label", normalizeProps(guardReactiveProps({ route, index })), () => [
1581
+ createTextVNode(toDisplayString(route.label), 1)
1582
+ ])
1583
+ ]),
1584
+ _: 2
1585
+ }, 1040, ["class", "aria-current"])),
1586
+ createElementVNode("meta", {
1587
+ itemprop: "position",
1588
+ content: `${index + 1}`
1589
+ }, null, 8, _hoisted_2$b)
1590
+ ], 2);
1591
+ }), 128))
1592
+ ])
1593
+ ], 2);
1365
1594
  };
1366
1595
  }
1367
1596
  });
@@ -1469,8 +1698,7 @@ function useGroupProps$2(props, emit) {
1469
1698
  label
1470
1699
  };
1471
1700
  }
1472
- const useUniqueId = (id) => computed(() => String((id == null ? void 0 : id.value) || nanoid()));
1473
- const _hoisted_1$d = {
1701
+ const _hoisted_1$f = {
1474
1702
  key: 1,
1475
1703
  class: "vv-button__label"
1476
1704
  };
@@ -1481,7 +1709,7 @@ const _hoisted_2$a = {
1481
1709
  const __default__$g = {
1482
1710
  name: "VvButton"
1483
1711
  };
1484
- const _sfc_main$g = /* @__PURE__ */ defineComponent({
1712
+ const _sfc_main$j = /* @__PURE__ */ defineComponent({
1485
1713
  ...__default__$g,
1486
1714
  props: VvButtonProps,
1487
1715
  emits: VvButtonEvents,
@@ -1560,7 +1788,7 @@ const _sfc_main$g = /* @__PURE__ */ defineComponent({
1560
1788
  }
1561
1789
  };
1562
1790
  return (_ctx, _cache) => {
1563
- return openBlock(), createBlock(_sfc_main$h, mergeProps({
1791
+ return openBlock(), createBlock(_sfc_main$o, mergeProps({
1564
1792
  disabled: unref(disabled),
1565
1793
  pressed: unref(pressed),
1566
1794
  active: _ctx.active,
@@ -1568,7 +1796,8 @@ const _sfc_main$g = /* @__PURE__ */ defineComponent({
1568
1796
  to: _ctx.to,
1569
1797
  href: _ctx.href,
1570
1798
  target: _ctx.target,
1571
- rel: _ctx.rel
1799
+ rel: _ctx.rel,
1800
+ ariaLabel: _ctx.ariaLabel
1572
1801
  }, {
1573
1802
  id: unref(hasId),
1574
1803
  ref_key: "element",
@@ -1579,15 +1808,15 @@ const _sfc_main$g = /* @__PURE__ */ defineComponent({
1579
1808
  default: withCtx(() => [
1580
1809
  renderSlot(_ctx.$slots, "default", {}, () => [
1581
1810
  _ctx.loading ? renderSlot(_ctx.$slots, "loading", { key: 0 }, () => [
1582
- _ctx.loadingIcon ? (openBlock(), createBlock(_sfc_main$i, {
1811
+ _ctx.loadingIcon ? (openBlock(), createBlock(_sfc_main$n, {
1583
1812
  key: 0,
1584
1813
  class: "vv-button__loading-icon",
1585
1814
  name: _ctx.loadingIcon
1586
1815
  }, null, 8, ["name"])) : createCommentVNode("", true),
1587
- _ctx.loadingLabel ? (openBlock(), createElementBlock("span", _hoisted_1$d, toDisplayString(_ctx.loadingLabel), 1)) : createCommentVNode("", true)
1816
+ _ctx.loadingLabel ? (openBlock(), createElementBlock("span", _hoisted_1$f, toDisplayString(_ctx.loadingLabel), 1)) : createCommentVNode("", true)
1588
1817
  ]) : (openBlock(), createElementBlock(Fragment, { key: 1 }, [
1589
1818
  renderSlot(_ctx.$slots, "before"),
1590
- unref(icon) ? (openBlock(), createBlock(_sfc_main$i, mergeProps({
1819
+ unref(icon) ? (openBlock(), createBlock(_sfc_main$n, mergeProps({
1591
1820
  key: 0,
1592
1821
  class: "vv-button__icon"
1593
1822
  }, unref(hasIconProps)), null, 16)) : createCommentVNode("", true),
@@ -1627,7 +1856,7 @@ const VvButtonGroupEvents = ["update:modelValue"];
1627
1856
  const __default__$f = {
1628
1857
  name: "VvButtonGroup"
1629
1858
  };
1630
- const _sfc_main$f = /* @__PURE__ */ defineComponent({
1859
+ const _sfc_main$i = /* @__PURE__ */ defineComponent({
1631
1860
  ...__default__$f,
1632
1861
  props: VvButtonGroupProps,
1633
1862
  emits: VvButtonGroupEvents,
@@ -1686,7 +1915,7 @@ const VvCardProps = {
1686
1915
  ...ModifiersProps,
1687
1916
  title: String
1688
1917
  };
1689
- const _hoisted_1$c = {
1918
+ const _hoisted_1$e = {
1690
1919
  key: 0,
1691
1920
  class: "vv-card__header"
1692
1921
  };
@@ -1701,7 +1930,7 @@ const _hoisted_3$5 = {
1701
1930
  const __default__$e = {
1702
1931
  name: "VvCard"
1703
1932
  };
1704
- const _sfc_main$e = /* @__PURE__ */ defineComponent({
1933
+ const _sfc_main$h = /* @__PURE__ */ defineComponent({
1705
1934
  ...__default__$e,
1706
1935
  props: VvCardProps,
1707
1936
  setup(__props) {
@@ -1712,7 +1941,7 @@ const _sfc_main$e = /* @__PURE__ */ defineComponent({
1712
1941
  return openBlock(), createElementBlock("article", {
1713
1942
  class: normalizeClass(unref(bemCssClasses))
1714
1943
  }, [
1715
- _ctx.$slots.header || _ctx.title ? (openBlock(), createElementBlock("header", _hoisted_1$c, [
1944
+ _ctx.$slots.header || _ctx.title ? (openBlock(), createElementBlock("header", _hoisted_1$e, [
1716
1945
  renderSlot(_ctx.$slots, "header", {}, () => [
1717
1946
  createTextVNode(toDisplayString(_ctx.title), 1)
1718
1947
  ])
@@ -1888,12 +2117,12 @@ function HintSlotFactory(props, slots) {
1888
2117
  HintSlot
1889
2118
  };
1890
2119
  }
1891
- const _hoisted_1$b = ["for"];
2120
+ const _hoisted_1$d = ["for"];
1892
2121
  const _hoisted_2$8 = ["id", "name", "disabled", "value", "tabindex", "aria-invalid", "aria-describedby", "aria-errormessage"];
1893
2122
  const __default__$d = {
1894
2123
  name: "VvCheckbox"
1895
2124
  };
1896
- const _sfc_main$d = /* @__PURE__ */ defineComponent({
2125
+ const _sfc_main$g = /* @__PURE__ */ defineComponent({
1897
2126
  ...__default__$d,
1898
2127
  props: VvCheckboxProps,
1899
2128
  emits: VvCheckboxEvents,
@@ -2071,7 +2300,7 @@ const _sfc_main$d = /* @__PURE__ */ defineComponent({
2071
2300
  key: "3"
2072
2301
  } : void 0
2073
2302
  ]), 1032, ["id"])
2074
- ], 10, _hoisted_1$b);
2303
+ ], 10, _hoisted_1$d);
2075
2304
  };
2076
2305
  }
2077
2306
  });
@@ -2109,12 +2338,12 @@ function useOptions(props) {
2109
2338
  getOptionGrouped
2110
2339
  };
2111
2340
  }
2112
- const _hoisted_1$a = ["textContent"];
2341
+ const _hoisted_1$c = ["textContent"];
2113
2342
  const _hoisted_2$7 = { class: "vv-checkbox-group__wrapper" };
2114
2343
  const __default__$c = {
2115
2344
  name: "VvCheckboxGroup"
2116
2345
  };
2117
- const _sfc_main$c = /* @__PURE__ */ defineComponent({
2346
+ const _sfc_main$f = /* @__PURE__ */ defineComponent({
2118
2347
  ...__default__$c,
2119
2348
  props: VvCheckboxGroupProps,
2120
2349
  emits: VvCheckboxGroupEvents,
@@ -2159,10 +2388,10 @@ const _sfc_main$c = /* @__PURE__ */ defineComponent({
2159
2388
  _ctx.label ? (openBlock(), createElementBlock("legend", {
2160
2389
  key: 0,
2161
2390
  textContent: toDisplayString(_ctx.label)
2162
- }, null, 8, _hoisted_1$a)) : createCommentVNode("", true),
2391
+ }, null, 8, _hoisted_1$c)) : createCommentVNode("", true),
2163
2392
  createElementVNode("div", _hoisted_2$7, [
2164
2393
  _ctx.options.length > 0 ? (openBlock(true), createElementBlock(Fragment, { key: 0 }, renderList(_ctx.options, (option, index) => {
2165
- return openBlock(), createBlock(_sfc_main$d, mergeProps({ key: index }, getOptionProps(option, index)), null, 16);
2394
+ return openBlock(), createBlock(_sfc_main$g, mergeProps({ key: index }, getOptionProps(option, index)), null, 16);
2166
2395
  }), 128)) : renderSlot(_ctx.$slots, "default", { key: 1 })
2167
2396
  ]),
2168
2397
  createVNode(unref(HintSlot), { class: "vv-checkbox-group__hint" }, createSlots({ _: 2 }, [
@@ -2333,13 +2562,7 @@ const VvComboboxProps = {
2333
2562
  const VvDropdownProps = {
2334
2563
  ...IdProps,
2335
2564
  ...DropdownProps,
2336
- /**
2337
- * Component BEM modifiers
2338
- */
2339
- modifiers: {
2340
- type: [String, Array],
2341
- default: "mobile"
2342
- },
2565
+ ...ModifiersProps,
2343
2566
  /**
2344
2567
  * Show / hide dropdown programmatically
2345
2568
  */
@@ -2412,12 +2635,12 @@ function useProvideDropdownAction({
2412
2635
  expanded
2413
2636
  });
2414
2637
  }
2415
- const _hoisted_1$9 = ["id", "tabindex", "role", "aria-labelledby"];
2638
+ const _hoisted_1$b = ["id", "tabindex", "role", "aria-labelledby"];
2416
2639
  const __default__$b = {
2417
2640
  name: "VvDropdown",
2418
2641
  inheritAttrs: false
2419
2642
  };
2420
- const _sfc_main$b = /* @__PURE__ */ defineComponent({
2643
+ const _sfc_main$e = /* @__PURE__ */ defineComponent({
2421
2644
  ...__default__$b,
2422
2645
  props: VvDropdownProps,
2423
2646
  emits: [
@@ -2534,7 +2757,11 @@ const _sfc_main$b = /* @__PURE__ */ defineComponent({
2534
2757
  referenceEl,
2535
2758
  floatingEl,
2536
2759
  {
2537
- whileElementsMounted: autoUpdate,
2760
+ whileElementsMounted: (...args) => {
2761
+ return autoUpdate(...args, {
2762
+ animationFrame: props.strategy === "fixed"
2763
+ });
2764
+ },
2538
2765
  placement: computed(() => props.placement),
2539
2766
  strategy: computed(() => props.strategy),
2540
2767
  middleware
@@ -2801,7 +3028,7 @@ const _sfc_main$b = /* @__PURE__ */ defineComponent({
2801
3028
  renderSlot(_ctx.$slots, "items", normalizeProps(guardReactiveProps({
2802
3029
  role: unref(itemRole)
2803
3030
  })))
2804
- ], 16, _hoisted_1$9),
3031
+ ], 16, _hoisted_1$b),
2805
3032
  renderSlot(_ctx.$slots, "after", normalizeProps(guardReactiveProps({ expanded: unref(expanded) })))
2806
3033
  ], 6), [
2807
3034
  [vShow, unref(expanded)]
@@ -2816,7 +3043,7 @@ const _sfc_main$b = /* @__PURE__ */ defineComponent({
2816
3043
  const __default__$a = {
2817
3044
  name: "VvDropdownItem"
2818
3045
  };
2819
- const _sfc_main$a = /* @__PURE__ */ defineComponent({
3046
+ const _sfc_main$d = /* @__PURE__ */ defineComponent({
2820
3047
  ...__default__$a,
2821
3048
  setup(__props) {
2822
3049
  const { role, expanded } = useInjectedDropdownItem();
@@ -2841,11 +3068,11 @@ const _sfc_main$a = /* @__PURE__ */ defineComponent({
2841
3068
  };
2842
3069
  }
2843
3070
  });
2844
- const _hoisted_1$8 = ["title"];
3071
+ const _hoisted_1$a = ["title"];
2845
3072
  const __default__$9 = {
2846
3073
  name: "VvDropdownOption"
2847
3074
  };
2848
- const _sfc_main$9 = /* @__PURE__ */ defineComponent({
3075
+ const _sfc_main$c = /* @__PURE__ */ defineComponent({
2849
3076
  ...__default__$9,
2850
3077
  props: {
2851
3078
  ...DisabledProps,
@@ -2883,7 +3110,7 @@ const _sfc_main$9 = /* @__PURE__ */ defineComponent({
2883
3110
  }
2884
3111
  });
2885
3112
  return (_ctx, _cache) => {
2886
- return openBlock(), createBlock(_sfc_main$a, {
3113
+ return openBlock(), createBlock(_sfc_main$d, {
2887
3114
  class: normalizeClass(unref(bemCssClasses)),
2888
3115
  tabindex: _ctx.disabled ? -1 : 0,
2889
3116
  "aria-selected": _ctx.selected,
@@ -2898,14 +3125,14 @@ const _sfc_main$9 = /* @__PURE__ */ defineComponent({
2898
3125
  renderSlot(_ctx.$slots, "hint", normalizeProps(guardReactiveProps({ disabled: _ctx.disabled, selected: _ctx.selected, unselectable: _ctx.unselectable })), () => [
2899
3126
  createTextVNode(toDisplayString(unref(hintLabel)), 1)
2900
3127
  ])
2901
- ], 8, _hoisted_1$8)
3128
+ ], 8, _hoisted_1$a)
2902
3129
  ]),
2903
3130
  _: 3
2904
3131
  }, 8, ["class", "tabindex", "aria-selected", "aria-disabled"]);
2905
3132
  };
2906
3133
  }
2907
3134
  });
2908
- const _hoisted_1$7 = {
3135
+ const _hoisted_1$9 = {
2909
3136
  class: "vv-dropdown-optgroup",
2910
3137
  role: "presentation",
2911
3138
  tabindex: "-1"
@@ -2913,7 +3140,7 @@ const _hoisted_1$7 = {
2913
3140
  const __default__$8 = {
2914
3141
  name: "VvDropdownOptgroup"
2915
3142
  };
2916
- const _sfc_main$8 = /* @__PURE__ */ defineComponent({
3143
+ const _sfc_main$b = /* @__PURE__ */ defineComponent({
2917
3144
  ...__default__$8,
2918
3145
  props: {
2919
3146
  ...LabelProps
@@ -2921,7 +3148,7 @@ const _sfc_main$8 = /* @__PURE__ */ defineComponent({
2921
3148
  setup(__props) {
2922
3149
  const props = __props;
2923
3150
  return (_ctx, _cache) => {
2924
- return openBlock(), createElementBlock("li", _hoisted_1$7, toDisplayString(props.label), 1);
3151
+ return openBlock(), createElementBlock("li", _hoisted_1$9, toDisplayString(props.label), 1);
2925
3152
  };
2926
3153
  }
2927
3154
  });
@@ -3018,7 +3245,7 @@ function useComponentIcon(icon, iconPosition) {
3018
3245
  hasIconAfter
3019
3246
  };
3020
3247
  }
3021
- const _hoisted_1$6 = ["for"];
3248
+ const _hoisted_1$8 = ["for"];
3022
3249
  const _hoisted_2$6 = { class: "vv-select__wrapper" };
3023
3250
  const _hoisted_3$4 = {
3024
3251
  key: 0,
@@ -3037,7 +3264,7 @@ const _hoisted_10 = {
3037
3264
  const __default__$7 = {
3038
3265
  name: "VvSelect"
3039
3266
  };
3040
- const _sfc_main$7 = /* @__PURE__ */ defineComponent({
3267
+ const _sfc_main$a = /* @__PURE__ */ defineComponent({
3041
3268
  ...__default__$7,
3042
3269
  props: VvSelectProps,
3043
3270
  emits: VvSelectEmits,
@@ -3156,13 +3383,13 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
3156
3383
  _ctx.label ? (openBlock(), createElementBlock("label", {
3157
3384
  key: 0,
3158
3385
  for: unref(hasId)
3159
- }, toDisplayString(_ctx.label), 9, _hoisted_1$6)) : createCommentVNode("", true),
3386
+ }, toDisplayString(_ctx.label), 9, _hoisted_1$8)) : createCommentVNode("", true),
3160
3387
  createElementVNode("div", _hoisted_2$6, [
3161
3388
  _ctx.$slots.before ? (openBlock(), createElementBlock("div", _hoisted_3$4, [
3162
3389
  renderSlot(_ctx.$slots, "before", normalizeProps(guardReactiveProps(unref(slotProps))))
3163
3390
  ])) : createCommentVNode("", true),
3164
3391
  createElementVNode("div", _hoisted_4$3, [
3165
- unref(hasIconBefore) ? (openBlock(), createBlock(_sfc_main$i, mergeProps({
3392
+ unref(hasIconBefore) ? (openBlock(), createBlock(_sfc_main$n, mergeProps({
3166
3393
  key: 0,
3167
3394
  class: "vv-select__icon"
3168
3395
  }, unref(hasIcon)), null, 16)) : createCommentVNode("", true),
@@ -3202,7 +3429,7 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
3202
3429
  ], 16, _hoisted_5$3), [
3203
3430
  [vModelSelect, unref(localModelValue)]
3204
3431
  ]),
3205
- unref(hasIconAfter) ? (openBlock(), createBlock(_sfc_main$i, mergeProps({
3432
+ unref(hasIconAfter) ? (openBlock(), createBlock(_sfc_main$n, mergeProps({
3206
3433
  key: 1,
3207
3434
  class: "vv-select__icon vv-select__icon-after"
3208
3435
  }, unref(hasIcon)), null, 16)) : createCommentVNode("", true)
@@ -3301,7 +3528,7 @@ function useDefaults(componentName, propsDefinition, props) {
3301
3528
  }, {});
3302
3529
  });
3303
3530
  }
3304
- const _hoisted_1$5 = ["id"];
3531
+ const _hoisted_1$7 = ["id"];
3305
3532
  const _hoisted_2$5 = ["id", "for"];
3306
3533
  const _hoisted_3$3 = ["id", "aria-controls", "placeholder"];
3307
3534
  const _hoisted_4$2 = {
@@ -3322,13 +3549,13 @@ const _hoisted_9 = {
3322
3549
  const __default__$6 = {
3323
3550
  name: "VvCombobox",
3324
3551
  components: {
3325
- VvDropdown: _sfc_main$b,
3326
- VvDropdownOption: _sfc_main$9,
3327
- VvDropdownOptgroup: _sfc_main$8,
3328
- VvButton: _sfc_main$g
3552
+ VvDropdown: _sfc_main$e,
3553
+ VvDropdownOption: _sfc_main$c,
3554
+ VvDropdownOptgroup: _sfc_main$b,
3555
+ VvButton: _sfc_main$j
3329
3556
  }
3330
3557
  };
3331
- const _sfc_main$6 = /* @__PURE__ */ defineComponent({
3558
+ const _sfc_main$9 = /* @__PURE__ */ defineComponent({
3332
3559
  ...__default__$6,
3333
3560
  props: VvComboboxProps,
3334
3561
  emits: VvComboboxEvents,
@@ -3608,7 +3835,7 @@ const _sfc_main$6 = /* @__PURE__ */ defineComponent({
3608
3835
  ref: wrapperEl,
3609
3836
  class: "vv-select__wrapper"
3610
3837
  }, [
3611
- createVNode(_sfc_main$b, mergeProps({
3838
+ createVNode(_sfc_main$e, mergeProps({
3612
3839
  ref_key: "dropdownEl",
3613
3840
  ref: dropdownEl,
3614
3841
  modelValue: unref(expanded),
@@ -3623,7 +3850,7 @@ const _sfc_main$6 = /* @__PURE__ */ defineComponent({
3623
3850
  renderSlot(_ctx.$slots, "before", normalizeProps(guardReactiveProps(unref(slotProps))))
3624
3851
  ])) : createCommentVNode("", true),
3625
3852
  createElementVNode("div", _hoisted_5$2, [
3626
- unref(hasIconBefore) ? (openBlock(), createBlock(_sfc_main$i, mergeProps({
3853
+ unref(hasIconBefore) ? (openBlock(), createBlock(_sfc_main$n, mergeProps({
3627
3854
  key: 0,
3628
3855
  class: "vv-select__icon"
3629
3856
  }, unref(hasIcon)), null, 16)) : createCommentVNode("", true),
@@ -3643,7 +3870,7 @@ const _sfc_main$6 = /* @__PURE__ */ defineComponent({
3643
3870
  renderSlot(_ctx.$slots, "value", normalizeProps(guardReactiveProps({ selectedOptions: unref(selectedOptions), onInput })), () => [
3644
3871
  unref(hasValue) ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
3645
3872
  !_ctx.badges ? (openBlock(), createElementBlock("div", _hoisted_7$2, toDisplayString(unref(hasValue)), 1)) : (openBlock(true), createElementBlock(Fragment, { key: 1 }, renderList(unref(selectedOptions), (option, index) => {
3646
- return openBlock(), createBlock(_sfc_main$k, {
3873
+ return openBlock(), createBlock(_sfc_main$l, {
3647
3874
  key: index,
3648
3875
  modifiers: _ctx.badgeModifiers,
3649
3876
  class: "vv-select__badge"
@@ -3655,7 +3882,7 @@ const _sfc_main$6 = /* @__PURE__ */ defineComponent({
3655
3882
  "aria-label": unref(propsDefaults).deselectActionLabel,
3656
3883
  onClick: withModifiers(($event) => onInput(option), ["stop"])
3657
3884
  }, [
3658
- createVNode(_sfc_main$i, { name: "close" })
3885
+ createVNode(_sfc_main$n, { name: "close" })
3659
3886
  ], 8, _hoisted_8$1)) : createCommentVNode("", true)
3660
3887
  ]),
3661
3888
  _: 2
@@ -3666,7 +3893,7 @@ const _sfc_main$6 = /* @__PURE__ */ defineComponent({
3666
3893
  ], 64))
3667
3894
  ])
3668
3895
  ], 16, _hoisted_6$2),
3669
- unref(hasIconAfter) ? (openBlock(), createBlock(_sfc_main$i, mergeProps({
3896
+ unref(hasIconAfter) ? (openBlock(), createBlock(_sfc_main$n, mergeProps({
3670
3897
  key: 1,
3671
3898
  class: "vv-select__icon vv-select__icon-after"
3672
3899
  }, unref(hasIcon)), null, 16)) : createCommentVNode("", true)
@@ -3679,13 +3906,13 @@ const _sfc_main$6 = /* @__PURE__ */ defineComponent({
3679
3906
  unref(filteredOptions).length ? (openBlock(true), createElementBlock(Fragment, { key: 0 }, renderList(unref(filteredOptions), (option, index) => {
3680
3907
  return openBlock(), createElementBlock(Fragment, { key: index }, [
3681
3908
  isGroup(option) ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
3682
- createVNode(_sfc_main$8, {
3909
+ createVNode(_sfc_main$b, {
3683
3910
  label: unref(getOptionLabel)(option)
3684
3911
  }, null, 8, ["label"]),
3685
3912
  (openBlock(true), createElementBlock(Fragment, null, renderList(unref(getOptionGrouped)(
3686
3913
  option
3687
3914
  ), (item, i) => {
3688
- return openBlock(), createBlock(_sfc_main$9, mergeProps({
3915
+ return openBlock(), createBlock(_sfc_main$c, mergeProps({
3689
3916
  disabled: unref(getOptionDisabled)(item),
3690
3917
  selected: getOptionSelected(item),
3691
3918
  unselectable: _ctx.unselectable,
@@ -3710,7 +3937,7 @@ const _sfc_main$6 = /* @__PURE__ */ defineComponent({
3710
3937
  _: 2
3711
3938
  }, 1040, ["onClickPassive"]);
3712
3939
  }), 128))
3713
- ], 64)) : (openBlock(), createBlock(_sfc_main$9, mergeProps({ key: 1 }, {
3940
+ ], 64)) : (openBlock(), createBlock(_sfc_main$c, mergeProps({ key: 1 }, {
3714
3941
  disabled: unref(getOptionDisabled)(option),
3715
3942
  selected: getOptionSelected(option),
3716
3943
  unselectable: _ctx.unselectable,
@@ -3734,7 +3961,7 @@ const _sfc_main$6 = /* @__PURE__ */ defineComponent({
3734
3961
  _: 2
3735
3962
  }, 1040, ["onClickPassive"]))
3736
3963
  ], 64);
3737
- }), 128)) : !_ctx.options.length ? (openBlock(), createBlock(_sfc_main$9, {
3964
+ }), 128)) : !_ctx.options.length ? (openBlock(), createBlock(_sfc_main$c, {
3738
3965
  key: 1,
3739
3966
  modifiers: "inert"
3740
3967
  }, {
@@ -3744,7 +3971,7 @@ const _sfc_main$6 = /* @__PURE__ */ defineComponent({
3744
3971
  ])
3745
3972
  ]),
3746
3973
  _: 3
3747
- })) : (openBlock(), createBlock(_sfc_main$9, {
3974
+ })) : (openBlock(), createBlock(_sfc_main$c, {
3748
3975
  key: 2,
3749
3976
  modifiers: "inert"
3750
3977
  }, {
@@ -3760,7 +3987,7 @@ const _sfc_main$6 = /* @__PURE__ */ defineComponent({
3760
3987
  renderSlot(_ctx.$slots, "dropdown::after", {}, () => {
3761
3988
  var _a;
3762
3989
  return [
3763
- ((_a = unref(dropdownEl)) == null ? void 0 : _a.customPosition) ? (openBlock(), createBlock(_sfc_main$g, {
3990
+ ((_a = unref(dropdownEl)) == null ? void 0 : _a.customPosition) ? (openBlock(), createBlock(_sfc_main$j, {
3764
3991
  key: 0,
3765
3992
  label: "Close",
3766
3993
  modifiers: "secondary",
@@ -3830,7 +4057,7 @@ const _sfc_main$6 = /* @__PURE__ */ defineComponent({
3830
4057
  key: "3"
3831
4058
  } : void 0
3832
4059
  ]), 1032, ["id"])
3833
- ], 10, _hoisted_1$5)) : (openBlock(), createBlock(_sfc_main$7, mergeProps({ key: 1 }, unref(selectProps), {
4060
+ ], 10, _hoisted_1$7)) : (openBlock(), createBlock(_sfc_main$a, mergeProps({ key: 1 }, unref(selectProps), {
3834
4061
  "onUpdate:modelValue": _cache[3] || (_cache[3] = ($event) => emit("update:modelValue", $event))
3835
4062
  }), null, 16));
3836
4063
  };
@@ -3875,7 +4102,7 @@ const VvDialogProps = {
3875
4102
  */
3876
4103
  keepOpen: { type: Boolean, default: false }
3877
4104
  };
3878
- const _hoisted_1$4 = {
4105
+ const _hoisted_1$6 = {
3879
4106
  key: 0,
3880
4107
  class: "vv-dialog__header"
3881
4108
  };
@@ -3887,7 +4114,7 @@ const _hoisted_3$2 = {
3887
4114
  const __default__$5 = {
3888
4115
  name: "VvDialog"
3889
4116
  };
3890
- const _sfc_main$5 = /* @__PURE__ */ defineComponent({
4117
+ const _sfc_main$8 = /* @__PURE__ */ defineComponent({
3891
4118
  ...__default__$5,
3892
4119
  props: VvDialogProps,
3893
4120
  emits: VvDialogEvents,
@@ -3983,7 +4210,7 @@ const _sfc_main$5 = /* @__PURE__ */ defineComponent({
3983
4210
  ref: modalWrapper,
3984
4211
  class: "vv-dialog__wrapper"
3985
4212
  }, [
3986
- _ctx.$slots.header || _ctx.title ? (openBlock(), createElementBlock("header", _hoisted_1$4, [
4213
+ _ctx.$slots.header || _ctx.title ? (openBlock(), createElementBlock("header", _hoisted_1$6, [
3987
4214
  renderSlot(_ctx.$slots, "header", {}, () => [
3988
4215
  createTextVNode(toDisplayString(_ctx.title) + " ", 1),
3989
4216
  createElementVNode("button", {
@@ -3992,7 +4219,7 @@ const _sfc_main$5 = /* @__PURE__ */ defineComponent({
3992
4219
  class: "vv-dialog__close",
3993
4220
  onClickPassive: close
3994
4221
  }, [
3995
- createVNode(_sfc_main$i, { name: "close" })
4222
+ createVNode(_sfc_main$n, { name: "close" })
3996
4223
  ], 32)
3997
4224
  ])
3998
4225
  ])) : createCommentVNode("", true),
@@ -4204,7 +4431,7 @@ const VvInputTextProps = {
4204
4431
  };
4205
4432
  const VvInputPasswordAction = defineComponent({
4206
4433
  components: {
4207
- VvIcon: _sfc_main$i
4434
+ VvIcon: _sfc_main$n
4208
4435
  },
4209
4436
  props: {
4210
4437
  disabled: {
@@ -4248,7 +4475,7 @@ const VvInputPasswordAction = defineComponent({
4248
4475
  };
4249
4476
  },
4250
4477
  render() {
4251
- const icon = h(_sfc_main$i, {
4478
+ const icon = h(_sfc_main$n, {
4252
4479
  name: this.activeIcon,
4253
4480
  class: "vv-input-text__icon"
4254
4481
  });
@@ -4267,7 +4494,7 @@ const VvInputPasswordAction = defineComponent({
4267
4494
  });
4268
4495
  const VvInputStepAction = defineComponent({
4269
4496
  components: {
4270
- VvIcon: _sfc_main$i
4497
+ VvIcon: _sfc_main$n
4271
4498
  },
4272
4499
  props: {
4273
4500
  disabled: {
@@ -4312,7 +4539,7 @@ const VvInputStepAction = defineComponent({
4312
4539
  });
4313
4540
  const VvInputClearAction = defineComponent({
4314
4541
  components: {
4315
- VvIcon: _sfc_main$i
4542
+ VvIcon: _sfc_main$n
4316
4543
  },
4317
4544
  props: {
4318
4545
  disabled: {
@@ -4341,7 +4568,7 @@ const VvInputClearAction = defineComponent({
4341
4568
  };
4342
4569
  },
4343
4570
  render() {
4344
- const icon = h(_sfc_main$i, {
4571
+ const icon = h(_sfc_main$n, {
4345
4572
  name: this.icon,
4346
4573
  class: "vv-input-text__icon"
4347
4574
  });
@@ -4362,7 +4589,7 @@ function VvInputTextActionsFactory(type, parentProps) {
4362
4589
  return {
4363
4590
  name: "VvInputTextActions",
4364
4591
  components: {
4365
- VvIcon: _sfc_main$i,
4592
+ VvIcon: _sfc_main$n,
4366
4593
  VvInputPasswordAction,
4367
4594
  VvInputStepAction,
4368
4595
  VvInputClearAction
@@ -4489,7 +4716,7 @@ function useTextCount(text, options) {
4489
4716
  formatted
4490
4717
  };
4491
4718
  }
4492
- const _hoisted_1$3 = ["for"];
4719
+ const _hoisted_1$5 = ["for"];
4493
4720
  const _hoisted_2$3 = { class: "vv-input-text__wrapper" };
4494
4721
  const _hoisted_3$1 = {
4495
4722
  key: 0,
@@ -4512,7 +4739,7 @@ const _hoisted_8 = {
4512
4739
  const __default__$4 = {
4513
4740
  name: "VvInputText"
4514
4741
  };
4515
- const _sfc_main$4 = /* @__PURE__ */ defineComponent({
4742
+ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
4516
4743
  ...__default__$4,
4517
4744
  props: VvInputTextProps,
4518
4745
  emits: VvInputTextEvents,
@@ -4764,7 +4991,7 @@ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
4764
4991
  key: 0,
4765
4992
  for: unref(hasId),
4766
4993
  class: "vv-input-text__label"
4767
- }, toDisplayString(unref(label)), 9, _hoisted_1$3)) : createCommentVNode("", true),
4994
+ }, toDisplayString(unref(label)), 9, _hoisted_1$5)) : createCommentVNode("", true),
4768
4995
  createElementVNode("div", _hoisted_2$3, [
4769
4996
  _ctx.$slots.before ? (openBlock(), createElementBlock("div", _hoisted_3$1, [
4770
4997
  renderSlot(_ctx.$slots, "before", normalizeProps(guardReactiveProps(unref(slotProps))))
@@ -4775,7 +5002,7 @@ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
4775
5002
  class: "vv-input-text__inner",
4776
5003
  onClick: withModifiers(onClickInner, ["stop"])
4777
5004
  }, [
4778
- unref(hasIconBefore) ? (openBlock(), createBlock(_sfc_main$i, mergeProps({
5005
+ unref(hasIconBefore) ? (openBlock(), createBlock(_sfc_main$n, mergeProps({
4779
5006
  key: 0,
4780
5007
  class: "vv-input-text__icon"
4781
5008
  }, unref(hasIcon)), null, 16)) : createCommentVNode("", true),
@@ -4796,7 +5023,7 @@ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
4796
5023
  ])
4797
5024
  ])) : createCommentVNode("", true)
4798
5025
  ], 8, _hoisted_4$1),
4799
- unref(hasIconAfter) || unref(defaultAfterIcon) ? (openBlock(), createBlock(_sfc_main$i, mergeProps({
5026
+ unref(hasIconAfter) || unref(defaultAfterIcon) ? (openBlock(), createBlock(_sfc_main$n, mergeProps({
4800
5027
  key: 1,
4801
5028
  class: "vv-input-text__icon vv-input-text__icon-after"
4802
5029
  }, unref(hasIconAfter) ? unref(hasIcon) : unref(defaultAfterIcon)), null, 16)) : unref(isPassword) && !_ctx.hideActions && unref(isClickable) ? (openBlock(), createBlock(unref(PasswordInputActions), {
@@ -4856,6 +5083,79 @@ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
4856
5083
  };
4857
5084
  }
4858
5085
  });
5086
+ const VvNavProps = {
5087
+ ...ModifiersProps,
5088
+ items: {
5089
+ type: Array,
5090
+ required: true,
5091
+ default: () => []
5092
+ }
5093
+ };
5094
+ const VvNavEvents = ["click"];
5095
+ const _hoisted_1$4 = {
5096
+ class: "vv-nav__menu",
5097
+ role: "menu",
5098
+ "aria-busy": "true"
5099
+ };
5100
+ const _sfc_main$6 = /* @__PURE__ */ defineComponent({
5101
+ __name: "VvNav",
5102
+ props: VvNavProps,
5103
+ emits: VvNavEvents,
5104
+ setup(__props, { emit }) {
5105
+ const props = __props;
5106
+ const { modifiers, items } = toRefs(props);
5107
+ const activeItem = ref(null);
5108
+ const bemCssClasses = useModifiers("vv-nav", modifiers);
5109
+ const localItems = computed(() => {
5110
+ return items.value.map((item, index) => {
5111
+ return {
5112
+ ...item,
5113
+ id: item.id || `nav-item_${index}`
5114
+ };
5115
+ });
5116
+ });
5117
+ function onClick(item) {
5118
+ if (!item.disabled) {
5119
+ emit("click", item);
5120
+ activeItem.value = item.id;
5121
+ }
5122
+ }
5123
+ return (_ctx, _cache) => {
5124
+ return openBlock(), createElementBlock("nav", {
5125
+ class: normalizeClass(unref(bemCssClasses))
5126
+ }, [
5127
+ createElementVNode("ul", _hoisted_1$4, [
5128
+ (openBlock(true), createElementBlock(Fragment, null, renderList(unref(localItems), (navItem) => {
5129
+ return openBlock(), createElementBlock("li", {
5130
+ key: navItem.id,
5131
+ class: "vv-nav__item",
5132
+ role: "presentation"
5133
+ }, [
5134
+ createVNode(_sfc_main$o, mergeProps({
5135
+ disabled: navItem.disabled,
5136
+ to: navItem.to,
5137
+ href: navItem.href,
5138
+ tabindex: 0
5139
+ }, {
5140
+ class: [{
5141
+ current: unref(activeItem) == navItem.id,
5142
+ disabled: navItem.disabled
5143
+ }, "vv-nav__item-label"]
5144
+ }, toHandlers(navItem.on), {
5145
+ onClick: ($event) => onClick(navItem)
5146
+ }), {
5147
+ default: withCtx(() => [
5148
+ createTextVNode(toDisplayString(navItem.title), 1)
5149
+ ]),
5150
+ _: 2
5151
+ }, 1040, ["class", "onClick"])
5152
+ ]);
5153
+ }), 128))
5154
+ ])
5155
+ ], 2);
5156
+ };
5157
+ }
5158
+ });
4859
5159
  const VvProgressProps = {
4860
5160
  ...ModifiersProps,
4861
5161
  /**
@@ -4889,7 +5189,7 @@ const VvProgressProps = {
4889
5189
  const __default__$3 = {
4890
5190
  name: "VvProgress"
4891
5191
  };
4892
- const _sfc_main$3 = /* @__PURE__ */ defineComponent({
5192
+ const _sfc_main$5 = /* @__PURE__ */ defineComponent({
4893
5193
  ...__default__$3,
4894
5194
  props: VvProgressProps,
4895
5195
  setup(__props) {
@@ -4945,12 +5245,12 @@ function useGroupProps(props, emit) {
4945
5245
  disabled
4946
5246
  };
4947
5247
  }
4948
- const _hoisted_1$2 = ["for"];
5248
+ const _hoisted_1$3 = ["for"];
4949
5249
  const _hoisted_2$2 = ["id", "name", "disabled", "value", "tabindex", "aria-invalid", "aria-describedby", "aria-errormessage"];
4950
5250
  const __default__$2 = {
4951
5251
  name: "VvRadio"
4952
5252
  };
4953
- const _sfc_main$2 = /* @__PURE__ */ defineComponent({
5253
+ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
4954
5254
  ...__default__$2,
4955
5255
  props: VvRadioProps,
4956
5256
  emits: VvRadioEvents,
@@ -5066,18 +5366,18 @@ const _sfc_main$2 = /* @__PURE__ */ defineComponent({
5066
5366
  key: "3"
5067
5367
  } : void 0
5068
5368
  ]), 1032, ["id"])
5069
- ], 10, _hoisted_1$2);
5369
+ ], 10, _hoisted_1$3);
5070
5370
  };
5071
5371
  }
5072
5372
  });
5073
5373
  const VvRadioGroupProps = CheckboxRadioGroupProps;
5074
5374
  const VvRadioGroupEvents = ["update:modelValue", "change"];
5075
- const _hoisted_1$1 = ["textContent"];
5375
+ const _hoisted_1$2 = ["textContent"];
5076
5376
  const _hoisted_2$1 = { class: "vv-radio-group__wrapper" };
5077
5377
  const __default__$1 = {
5078
5378
  name: "VvRadioGroup"
5079
5379
  };
5080
- const _sfc_main$1 = /* @__PURE__ */ defineComponent({
5380
+ const _sfc_main$3 = /* @__PURE__ */ defineComponent({
5081
5381
  ...__default__$1,
5082
5382
  props: VvRadioGroupProps,
5083
5383
  emits: VvRadioGroupEvents,
@@ -5122,10 +5422,10 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
5122
5422
  _ctx.label ? (openBlock(), createElementBlock("legend", {
5123
5423
  key: 0,
5124
5424
  textContent: toDisplayString(_ctx.label)
5125
- }, null, 8, _hoisted_1$1)) : createCommentVNode("", true),
5425
+ }, null, 8, _hoisted_1$2)) : createCommentVNode("", true),
5126
5426
  createElementVNode("div", _hoisted_2$1, [
5127
5427
  _ctx.options.length > 0 ? (openBlock(true), createElementBlock(Fragment, { key: 0 }, renderList(_ctx.options, (option, index) => {
5128
- return openBlock(), createBlock(_sfc_main$2, mergeProps({ key: index }, getOptionProps(option, index)), null, 16);
5428
+ return openBlock(), createBlock(_sfc_main$4, mergeProps({ key: index }, getOptionProps(option, index)), null, 16);
5129
5429
  }), 128)) : renderSlot(_ctx.$slots, "default", { key: 1 })
5130
5430
  ]),
5131
5431
  createVNode(unref(HintSlot), { class: "vv-radio-group__hint" }, createSlots({ _: 2 }, [
@@ -5162,6 +5462,61 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
5162
5462
  };
5163
5463
  }
5164
5464
  });
5465
+ const VvTabProps = {
5466
+ ...ModifiersProps,
5467
+ items: {
5468
+ type: Array,
5469
+ required: true,
5470
+ default: () => []
5471
+ }
5472
+ };
5473
+ const VvTabEvents = ["click"];
5474
+ const _hoisted_1$1 = ["id"];
5475
+ const _sfc_main$2 = /* @__PURE__ */ defineComponent({
5476
+ __name: "VvTab",
5477
+ props: VvTabProps,
5478
+ emits: VvTabEvents,
5479
+ setup(__props, { emit }) {
5480
+ const props = __props;
5481
+ const { modifiers, items } = toRefs(props);
5482
+ const activeTab = ref(null);
5483
+ const bemCssClasses = useModifiers("vv-tab", modifiers);
5484
+ const localItems = computed(() => {
5485
+ return items.value.map((item, index) => {
5486
+ return {
5487
+ ...item,
5488
+ id: item.id || `tab-item_${index}`
5489
+ };
5490
+ });
5491
+ });
5492
+ function onClick(item) {
5493
+ if (!item.disabled) {
5494
+ emit("click", item);
5495
+ activeTab.value = item.id;
5496
+ }
5497
+ }
5498
+ return (_ctx, _cache) => {
5499
+ return openBlock(), createElementBlock("div", {
5500
+ class: normalizeClass(unref(bemCssClasses))
5501
+ }, [
5502
+ createVNode(_sfc_main$6, {
5503
+ items: unref(localItems),
5504
+ modifiers: "tabs full",
5505
+ onClick
5506
+ }, null, 8, ["items"]),
5507
+ (openBlock(true), createElementBlock(Fragment, null, renderList(unref(localItems), (item) => {
5508
+ return openBlock(), createElementBlock("article", {
5509
+ id: item.id,
5510
+ key: item.id,
5511
+ class: normalizeClass([{ target: unref(activeTab) === item.id }, "vv-tab__panel"])
5512
+ }, [
5513
+ renderSlot(_ctx.$slots, `${item.id}`)
5514
+ ], 10, _hoisted_1$1);
5515
+ }), 128))
5516
+ ], 2);
5517
+ };
5518
+ }
5519
+ });
5165
5520
  const WRAP = {
5166
5521
  hard: "hard",
5167
5522
  soft: "soft"
@@ -5223,7 +5578,7 @@ const _hoisted_7 = {
5223
5578
  const __default__ = {
5224
5579
  name: "VvTextarea"
5225
5580
  };
5226
- const _sfc_main = /* @__PURE__ */ defineComponent({
5581
+ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
5227
5582
  ...__default__,
5228
5583
  props: VvTextareaProps,
5229
5584
  emits: VvTextareaEvents,
@@ -5348,7 +5703,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
5348
5703
  renderSlot(_ctx.$slots, "before", normalizeProps(guardReactiveProps(unref(slotProps))))
5349
5704
  ])) : createCommentVNode("", true),
5350
5705
  createElementVNode("div", _hoisted_4, [
5351
- unref(hasIconBefore) ? (openBlock(), createBlock(_sfc_main$i, mergeProps({
5706
+ unref(hasIconBefore) ? (openBlock(), createBlock(_sfc_main$n, mergeProps({
5352
5707
  key: 0,
5353
5708
  class: "vv-textarea__icon"
5354
5709
  }, unref(hasIcon)), null, 16)) : createCommentVNode("", true),
@@ -5362,7 +5717,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
5362
5717
  }), null, 16, _hoisted_5), [
5363
5718
  [vModelText, unref(localModelValue)]
5364
5719
  ]),
5365
- unref(hasIconAfter) ? (openBlock(), createBlock(_sfc_main$i, mergeProps({
5720
+ unref(hasIconAfter) ? (openBlock(), createBlock(_sfc_main$n, mergeProps({
5366
5721
  key: 1,
5367
5722
  class: "vv-textarea__icon vv-textarea__icon-after"
5368
5723
  }, unref(hasIcon)), null, 16)) : createCommentVNode("", true)
@@ -5413,24 +5768,69 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
5413
5768
  };
5414
5769
  }
5415
5770
  });
5771
+ const VvTooltipProps = {
5772
+ ...ModifiersProps,
5773
+ /**
5774
+ * Define the tooltip position
5775
+ * @default Side.bottom
5776
+ */
5777
+ position: {
5778
+ type: String,
5779
+ default: Side.bottom
5780
+ },
5781
+ value: {
5782
+ type: String
5783
+ }
5784
+ };
5785
+ const _sfc_main = /* @__PURE__ */ defineComponent({
5786
+ __name: "VvTooltip",
5787
+ props: VvTooltipProps,
5788
+ setup(__props) {
5789
+ const props = __props;
5790
+ const { modifiers } = toRefs(props);
5791
+ const bemCssClasses = useModifiers(
5792
+ "vv-tooltip",
5793
+ modifiers,
5794
+ computed(() => ({
5795
+ [props.position]: true
5796
+ }))
5797
+ );
5798
+ return (_ctx, _cache) => {
5799
+ return openBlock(), createElementBlock("span", {
5800
+ class: normalizeClass(unref(bemCssClasses)),
5801
+ role: "tooltip",
5802
+ inert: ""
5803
+ }, [
5804
+ renderSlot(_ctx.$slots, "default", {}, () => [
5805
+ createTextVNode(toDisplayString(_ctx.value), 1)
5806
+ ])
5807
+ ], 2);
5808
+ };
5809
+ }
5810
+ });
5416
5811
  export {
5417
- _sfc_main$m as VvAccordion,
5418
- _sfc_main$l as VvAccordionGroup,
5419
- _sfc_main$k as VvBadge,
5420
- _sfc_main$j as VvBreadcrumb,
5421
- _sfc_main$g as VvButton,
5422
- _sfc_main$f as VvButtonGroup,
5423
- _sfc_main$e as VvCard,
5424
- _sfc_main$d as VvCheckbox,
5425
- _sfc_main$c as VvCheckboxGroup,
5426
- _sfc_main$6 as VvCombobox,
5427
- _sfc_main$5 as VvDialog,
5428
- _sfc_main$b as VvDropdown,
5429
- _sfc_main$i as VvIcon,
5430
- _sfc_main$4 as VvInputText,
5431
- _sfc_main$3 as VvProgress,
5432
- _sfc_main$2 as VvRadio,
5433
- _sfc_main$1 as VvRadioGroup,
5434
- _sfc_main$7 as VvSelect,
5435
- _sfc_main as VvTextarea
5812
+ _sfc_main$q as VvAccordion,
5813
+ _sfc_main$p as VvAccordionGroup,
5814
+ _sfc_main$o as VvAction,
5815
+ _sfc_main$m as VvAlert,
5816
+ _sfc_main$l as VvBadge,
5817
+ _sfc_main$k as VvBreadcrumb,
5818
+ _sfc_main$j as VvButton,
5819
+ _sfc_main$i as VvButtonGroup,
5820
+ _sfc_main$h as VvCard,
5821
+ _sfc_main$g as VvCheckbox,
5822
+ _sfc_main$f as VvCheckboxGroup,
5823
+ _sfc_main$9 as VvCombobox,
5824
+ _sfc_main$8 as VvDialog,
5825
+ _sfc_main$e as VvDropdown,
5826
+ _sfc_main$n as VvIcon,
5827
+ _sfc_main$7 as VvInputText,
5828
+ _sfc_main$6 as VvNav,
5829
+ _sfc_main$5 as VvProgress,
5830
+ _sfc_main$4 as VvRadio,
5831
+ _sfc_main$3 as VvRadioGroup,
5832
+ _sfc_main$a as VvSelect,
5833
+ _sfc_main$2 as VvTab,
5834
+ _sfc_main$1 as VvTextarea,
5835
+ _sfc_main as VvTooltip
5436
5836
  };