@vuetify/nightly 3.7.4-next.2024-11-06 → 3.7.5-dev.2024-12-16

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 (262) hide show
  1. package/dist/json/attributes.json +2853 -2845
  2. package/dist/json/importMap-labs.json +20 -20
  3. package/dist/json/importMap.json +150 -150
  4. package/dist/json/tags.json +2 -0
  5. package/dist/json/web-types.json +5324 -5306
  6. package/dist/vuetify-labs.css +25135 -23418
  7. package/dist/vuetify-labs.d.ts +202 -196
  8. package/dist/vuetify-labs.esm.js +107 -106
  9. package/dist/vuetify-labs.esm.js.map +1 -1
  10. package/dist/vuetify-labs.js +106 -105
  11. package/dist/vuetify-labs.min.css +4 -3
  12. package/dist/vuetify.css +23838 -22118
  13. package/dist/vuetify.d.ts +191 -185
  14. package/dist/vuetify.esm.js +96 -96
  15. package/dist/vuetify.esm.js.map +1 -1
  16. package/dist/vuetify.js +95 -95
  17. package/dist/vuetify.js.map +1 -1
  18. package/dist/vuetify.min.css +4 -3
  19. package/dist/vuetify.min.js +884 -889
  20. package/dist/vuetify.min.js.map +1 -1
  21. package/lib/components/VAlert/VAlert.css +215 -207
  22. package/lib/components/VApp/VApp.css +15 -16
  23. package/lib/components/VAppBar/VAppBar.css +12 -14
  24. package/lib/components/VAppBar/index.d.mts +6 -6
  25. package/lib/components/VAutocomplete/VAutocomplete.css +85 -86
  26. package/lib/components/VAutocomplete/VAutocomplete.mjs +4 -4
  27. package/lib/components/VAutocomplete/VAutocomplete.mjs.map +1 -1
  28. package/lib/components/VAutocomplete/index.d.mts +22 -22
  29. package/lib/components/VAvatar/VAvatar.css +106 -108
  30. package/lib/components/VBadge/VBadge.css +77 -73
  31. package/lib/components/VBadge/VBadge.sass +4 -0
  32. package/lib/components/VBanner/VBanner.css +166 -161
  33. package/lib/components/VBottomNavigation/VBottomNavigation.css +63 -64
  34. package/lib/components/VBottomSheet/VBottomSheet.css +31 -34
  35. package/lib/components/VBreadcrumbs/VBreadcrumbs.css +57 -54
  36. package/lib/components/VBtn/VBtn.css +408 -385
  37. package/lib/components/VBtn/VBtn.sass +4 -4
  38. package/lib/components/VBtn/index.d.mts +7 -7
  39. package/lib/components/VBtnGroup/VBtnGroup.css +64 -63
  40. package/lib/components/VBtnToggle/VBtnToggle.css +14 -16
  41. package/lib/components/VBtnToggle/index.d.mts +9 -9
  42. package/lib/components/VCard/VCard.css +302 -294
  43. package/lib/components/VCarousel/VCarousel.css +65 -63
  44. package/lib/components/VCarousel/VCarousel.mjs.map +1 -1
  45. package/lib/components/VCarousel/VCarousel.sass +1 -1
  46. package/lib/components/VCarousel/index.d.mts +9 -9
  47. package/lib/components/VCheckbox/VCheckbox.css +5 -7
  48. package/lib/components/VCheckbox/VCheckbox.mjs +3 -3
  49. package/lib/components/VCheckbox/VCheckbox.mjs.map +1 -1
  50. package/lib/components/VChip/VChip.css +411 -378
  51. package/lib/components/VChip/VChip.mjs +18 -10
  52. package/lib/components/VChip/VChip.mjs.map +1 -1
  53. package/lib/components/VChip/index.d.mts +13 -8
  54. package/lib/components/VChipGroup/VChipGroup.css +18 -19
  55. package/lib/components/VChipGroup/VChipGroup.mjs +2 -0
  56. package/lib/components/VChipGroup/VChipGroup.mjs.map +1 -1
  57. package/lib/components/VChipGroup/index.d.mts +20 -15
  58. package/lib/components/VCode/VCode.css +8 -10
  59. package/lib/components/VColorPicker/VColorPicker.css +22 -22
  60. package/lib/components/VColorPicker/VColorPickerCanvas.css +22 -24
  61. package/lib/components/VColorPicker/VColorPickerEdit.css +28 -29
  62. package/lib/components/VColorPicker/VColorPickerPreview.css +67 -69
  63. package/lib/components/VColorPicker/VColorPickerPreview.sass +2 -4
  64. package/lib/components/VColorPicker/VColorPickerSwatches.css +34 -34
  65. package/lib/components/VCombobox/VCombobox.css +85 -86
  66. package/lib/components/VCombobox/VCombobox.mjs +4 -4
  67. package/lib/components/VCombobox/VCombobox.mjs.map +1 -1
  68. package/lib/components/VCombobox/index.d.mts +22 -22
  69. package/lib/components/VConfirmEdit/VConfirmEdit.mjs +9 -7
  70. package/lib/components/VConfirmEdit/VConfirmEdit.mjs.map +1 -1
  71. package/lib/components/VConfirmEdit/__test__/VConfirmEdit.spec.browser.mjs +1 -1
  72. package/lib/components/VConfirmEdit/__test__/VConfirmEdit.spec.browser.mjs.map +1 -1
  73. package/lib/components/VConfirmEdit/index.d.mts +3 -7
  74. package/lib/components/VCounter/VCounter.css +5 -7
  75. package/lib/components/VDataTable/VDataTable.css +186 -189
  76. package/lib/components/VDataTable/VDataTable.sass +10 -20
  77. package/lib/components/VDataTable/VDataTableFooter.css +31 -33
  78. package/lib/components/VDatePicker/VDatePicker.css +6 -8
  79. package/lib/components/VDatePicker/VDatePickerControls.css +56 -54
  80. package/lib/components/VDatePicker/VDatePickerHeader.css +60 -56
  81. package/lib/components/VDatePicker/VDatePickerHeader.mjs +2 -1
  82. package/lib/components/VDatePicker/VDatePickerHeader.mjs.map +1 -1
  83. package/lib/components/VDatePicker/VDatePickerMonth.css +55 -51
  84. package/lib/components/VDatePicker/VDatePickerMonths.css +19 -20
  85. package/lib/components/VDatePicker/VDatePickerYears.css +15 -16
  86. package/lib/components/VDatePicker/index.d.mts +5 -5
  87. package/lib/components/VDialog/VDialog.css +95 -95
  88. package/lib/components/VDivider/VDivider.css +52 -52
  89. package/lib/components/VEmptyState/VEmptyState.css +67 -62
  90. package/lib/components/VExpansionPanel/VExpansionPanel.css +209 -203
  91. package/lib/components/VExpansionPanel/VExpansionPanel.sass +25 -27
  92. package/lib/components/VExpansionPanel/index.d.mts +7 -7
  93. package/lib/components/VFab/VFab.css +69 -74
  94. package/lib/components/VFab/VFab.sass +4 -5
  95. package/lib/components/VFab/index.d.mts +6 -6
  96. package/lib/components/VField/VField.css +579 -539
  97. package/lib/components/VField/VField.mjs +5 -4
  98. package/lib/components/VField/VField.mjs.map +1 -1
  99. package/lib/components/VFileInput/VFileInput.css +29 -31
  100. package/lib/components/VFooter/VFooter.css +36 -38
  101. package/lib/components/VGrid/VGrid.css +592 -565
  102. package/lib/components/VIcon/VIcon.css +52 -51
  103. package/lib/components/VImg/VImg.css +51 -50
  104. package/lib/components/VInfiniteScroll/VInfiniteScroll.css +37 -36
  105. package/lib/components/VInput/VInput.css +142 -131
  106. package/lib/components/VInput/VInput.mjs +3 -3
  107. package/lib/components/VInput/VInput.mjs.map +1 -1
  108. package/lib/components/VItemGroup/VItemGroup.css +5 -7
  109. package/lib/components/VItemGroup/VItemGroup.mjs.map +1 -1
  110. package/lib/components/VItemGroup/index.d.mts +9 -9
  111. package/lib/components/VKbd/VKbd.css +11 -13
  112. package/lib/components/VLabel/VLabel.css +15 -16
  113. package/lib/components/VLayout/VLayout.css +8 -10
  114. package/lib/components/VLayout/VLayoutItem.css +7 -8
  115. package/lib/components/VList/VList.css +108 -104
  116. package/lib/components/VList/VList.mjs +3 -2
  117. package/lib/components/VList/VList.mjs.map +1 -1
  118. package/lib/components/VList/VList.sass +1 -1
  119. package/lib/components/VList/VListItem.css +452 -440
  120. package/lib/components/VList/VListItem.mjs +3 -2
  121. package/lib/components/VList/VListItem.mjs.map +1 -1
  122. package/lib/components/VList/VListItem.sass +1 -2
  123. package/lib/components/VList/index.d.mts +10 -10
  124. package/lib/components/VLocaleProvider/VLocaleProvider.css +2 -4
  125. package/lib/components/VMain/VMain.css +30 -32
  126. package/lib/components/VMenu/VMenu.css +19 -21
  127. package/lib/components/VMenu/VMenu.mjs +3 -3
  128. package/lib/components/VMenu/VMenu.mjs.map +1 -1
  129. package/lib/components/VMenu/index.d.mts +6 -6
  130. package/lib/components/VMessages/VMessages.css +15 -17
  131. package/lib/components/VNavigationDrawer/VNavigationDrawer.css +108 -106
  132. package/lib/components/VOtpInput/VOtpInput.css +58 -56
  133. package/lib/components/VOverlay/VOverlay.css +63 -60
  134. package/lib/components/VOverlay/VOverlay.sass +13 -14
  135. package/lib/components/VPagination/VPagination.css +8 -10
  136. package/lib/components/VParallax/VParallax.css +6 -8
  137. package/lib/components/VProgressCircular/VProgressCircular.css +101 -95
  138. package/lib/components/VProgressLinear/VProgressLinear.css +222 -209
  139. package/lib/components/VRadioGroup/VRadioGroup.css +12 -14
  140. package/lib/components/VRadioGroup/VRadioGroup.mjs +3 -3
  141. package/lib/components/VRadioGroup/VRadioGroup.mjs.map +1 -1
  142. package/lib/components/VRating/VRating.css +53 -52
  143. package/lib/components/VRating/VRating.mjs +4 -3
  144. package/lib/components/VRating/VRating.mjs.map +1 -1
  145. package/lib/components/VResponsive/VResponsive.css +26 -25
  146. package/lib/components/VSelect/VSelect.css +52 -54
  147. package/lib/components/VSelect/VSelect.mjs +3 -3
  148. package/lib/components/VSelect/VSelect.mjs.map +1 -1
  149. package/lib/components/VSelect/index.d.mts +22 -22
  150. package/lib/components/VSelectionControl/VSelectionControl.css +102 -100
  151. package/lib/components/VSelectionControl/VSelectionControl.mjs +3 -3
  152. package/lib/components/VSelectionControl/VSelectionControl.mjs.map +1 -1
  153. package/lib/components/VSelectionControlGroup/VSelectionControlGroup.css +8 -10
  154. package/lib/components/VSelectionControlGroup/VSelectionControlGroup.mjs +3 -3
  155. package/lib/components/VSelectionControlGroup/VSelectionControlGroup.mjs.map +1 -1
  156. package/lib/components/VSheet/VSheet.css +36 -38
  157. package/lib/components/VSkeletonLoader/VSkeletonLoader.css +224 -225
  158. package/lib/components/VSlideGroup/VSlideGroup.css +55 -53
  159. package/lib/components/VSlideGroup/index.d.mts +10 -10
  160. package/lib/components/VSlider/VSlider.css +57 -53
  161. package/lib/components/VSlider/VSliderThumb.css +153 -142
  162. package/lib/components/VSlider/VSliderTrack.css +174 -155
  163. package/lib/components/VSnackbar/VSnackbar.css +140 -140
  164. package/lib/components/VSparkline/VBarline.mjs +3 -3
  165. package/lib/components/VSparkline/VBarline.mjs.map +1 -1
  166. package/lib/components/VSparkline/VTrendline.mjs +3 -3
  167. package/lib/components/VSparkline/VTrendline.mjs.map +1 -1
  168. package/lib/components/VSpeedDial/VSpeedDial.css +41 -43
  169. package/lib/components/VStepper/VStepper.css +56 -55
  170. package/lib/components/VStepper/VStepper.mjs +5 -4
  171. package/lib/components/VStepper/VStepper.mjs.map +1 -1
  172. package/lib/components/VStepper/VStepperItem.css +115 -112
  173. package/lib/components/VStepper/VStepperItem.mjs +5 -4
  174. package/lib/components/VStepper/VStepperItem.mjs.map +1 -1
  175. package/lib/components/VStepper/index.d.mts +51 -45
  176. package/lib/components/VSwitch/VSwitch.css +139 -129
  177. package/lib/components/VSwitch/VSwitch.mjs +3 -3
  178. package/lib/components/VSwitch/VSwitch.mjs.map +1 -1
  179. package/lib/components/VSystemBar/VSystemBar.css +43 -45
  180. package/lib/components/VTable/VTable.css +141 -140
  181. package/lib/components/VTable/VTable.sass +2 -4
  182. package/lib/components/VTabs/VTab.css +29 -30
  183. package/lib/components/VTabs/VTabs.css +65 -59
  184. package/lib/components/VTabs/index.d.mts +7 -7
  185. package/lib/components/VTextField/VTextField.css +68 -65
  186. package/lib/components/VTextarea/VTextarea.css +39 -47
  187. package/lib/components/VTextarea/VTextarea.sass +2 -4
  188. package/lib/components/VThemeProvider/VThemeProvider.css +3 -5
  189. package/lib/components/VTimeline/VTimeline.css +418 -379
  190. package/lib/components/VToolbar/VToolbar.css +143 -136
  191. package/lib/components/VTooltip/VTooltip.css +21 -25
  192. package/lib/components/VTooltip/VTooltip.mjs +3 -3
  193. package/lib/components/VTooltip/VTooltip.mjs.map +1 -1
  194. package/lib/components/VTooltip/VTooltip.sass +6 -8
  195. package/lib/components/VVirtualScroll/VVirtualScroll.css +9 -11
  196. package/lib/components/VWindow/VWindow.css +70 -73
  197. package/lib/components/VWindow/index.d.mts +7 -7
  198. package/lib/components/index.d.mts +138 -132
  199. package/lib/composables/form.mjs +7 -2
  200. package/lib/composables/form.mjs.map +1 -1
  201. package/lib/composables/group.mjs +3 -3
  202. package/lib/composables/group.mjs.map +1 -1
  203. package/lib/composables/layout.mjs +3 -3
  204. package/lib/composables/layout.mjs.map +1 -1
  205. package/lib/composables/nested/nested.mjs +2 -2
  206. package/lib/composables/nested/nested.mjs.map +1 -1
  207. package/lib/composables/theme.mjs +4 -4
  208. package/lib/composables/theme.mjs.map +1 -1
  209. package/lib/composables/validation.mjs +13 -15
  210. package/lib/composables/validation.mjs.map +1 -1
  211. package/lib/directives/ripple/VRipple.css +36 -38
  212. package/lib/entry-bundler.mjs +1 -1
  213. package/lib/entry-bundler.mjs.map +1 -1
  214. package/lib/framework.mjs +2 -3
  215. package/lib/framework.mjs.map +1 -1
  216. package/lib/index.d.mts +53 -53
  217. package/lib/labs/VCalendar/VCalendar.css +225 -219
  218. package/lib/labs/VCalendar/VCalendarDay.css +32 -33
  219. package/lib/labs/VCalendar/VCalendarHeader.css +13 -13
  220. package/lib/labs/VCalendar/VCalendarInterval.css +42 -43
  221. package/lib/labs/VCalendar/VCalendarIntervalEvent.css +5 -7
  222. package/lib/labs/VCalendar/VCalendarMonthDay.css +58 -61
  223. package/lib/labs/VCalendar/VCalendarMonthDay.sass +2 -3
  224. package/lib/labs/VDateInput/VDateInput.mjs +1 -1
  225. package/lib/labs/VDateInput/VDateInput.mjs.map +1 -1
  226. package/lib/labs/VNumberInput/VNumberInput.css +38 -40
  227. package/lib/labs/VNumberInput/VNumberInput.mjs +7 -5
  228. package/lib/labs/VNumberInput/VNumberInput.mjs.map +1 -1
  229. package/lib/labs/VPicker/VPicker.css +57 -53
  230. package/lib/labs/VStepperVertical/index.d.mts +44 -44
  231. package/lib/labs/VTimePicker/VTimePicker.css +7 -9
  232. package/lib/labs/VTimePicker/VTimePickerClock.css +129 -126
  233. package/lib/labs/VTimePicker/VTimePickerControls.css +103 -102
  234. package/lib/labs/VTreeview/VTreeviewItem.css +15 -17
  235. package/lib/labs/VTreeview/VTreeviewItem.mjs +3 -4
  236. package/lib/labs/VTreeview/VTreeviewItem.mjs.map +1 -1
  237. package/lib/labs/VTreeview/VTreeviewItem.sass +1 -2
  238. package/lib/labs/VTreeview/index.d.mts +20 -20
  239. package/lib/labs/components.d.mts +64 -64
  240. package/lib/locale/fr.mjs +1 -1
  241. package/lib/locale/fr.mjs.map +1 -1
  242. package/lib/styles/elements/_global.sass +1 -1
  243. package/lib/styles/generic/_colors.scss +3 -3
  244. package/lib/styles/generic/_layers.scss +1 -13
  245. package/lib/styles/generic/_transitions.scss +32 -32
  246. package/lib/styles/main.css +16139 -14666
  247. package/lib/styles/settings/_utilities.scss +5 -0
  248. package/lib/styles/settings/_variables.scss +2 -1
  249. package/lib/styles/tools/_bootable.sass +3 -0
  250. package/lib/styles/tools/_border.sass +4 -4
  251. package/lib/styles/tools/_display.sass +10 -0
  252. package/lib/styles/tools/_elevation.sass +2 -2
  253. package/lib/styles/tools/_index.sass +2 -0
  254. package/lib/styles/tools/_layer.scss +2 -4
  255. package/lib/styles/tools/_position.sass +2 -2
  256. package/lib/styles/tools/_radius.sass +10 -0
  257. package/lib/styles/tools/_rounded.sass +2 -2
  258. package/lib/styles/tools/_utilities.sass +5 -1
  259. package/lib/styles/utilities/_elevation.scss +1 -1
  260. package/lib/util/getCurrentInstance.mjs +1 -15
  261. package/lib/util/getCurrentInstance.mjs.map +1 -1
  262. package/package.json +1 -1
@@ -9,8 +9,8 @@ import { VSelectionControl } from "../VSelectionControl/index.mjs";
9
9
  import { makeSelectionControlGroupProps, VSelectionControlGroup } from "../VSelectionControlGroup/VSelectionControlGroup.mjs"; // Composables
10
10
  import { IconValue } from "../../composables/icons.mjs";
11
11
  import { useProxiedModel } from "../../composables/proxiedModel.mjs"; // Utilities
12
- import { computed } from 'vue';
13
- import { filterInputAttrs, genericComponent, getUid, omit, propsFactory, useRender } from "../../util/index.mjs"; // Types
12
+ import { computed, useId } from 'vue';
13
+ import { filterInputAttrs, genericComponent, omit, propsFactory, useRender } from "../../util/index.mjs"; // Types
14
14
  export const makeVRadioGroupProps = propsFactory({
15
15
  height: {
16
16
  type: [Number, String],
@@ -43,7 +43,7 @@ export const VRadioGroup = genericComponent()({
43
43
  attrs,
44
44
  slots
45
45
  } = _ref;
46
- const uid = getUid();
46
+ const uid = useId();
47
47
  const id = computed(() => props.id || `radio-group-${uid}`);
48
48
  const model = useProxiedModel(props, 'modelValue');
49
49
  useRender(() => {
@@ -1 +1 @@
1
- {"version":3,"file":"VRadioGroup.mjs","names":["makeVInputProps","VInput","VLabel","VSelectionControl","makeSelectionControlGroupProps","VSelectionControlGroup","IconValue","useProxiedModel","computed","filterInputAttrs","genericComponent","getUid","omit","propsFactory","useRender","makeVRadioGroupProps","height","type","Number","String","default","trueIcon","falseIcon","VRadioGroup","name","inheritAttrs","props","emits","value","setup","_ref","attrs","slots","uid","id","model","rootAttrs","controlAttrs","inputProps","filterProps","controlProps","label","for","_createVNode","_mergeProps","class","style","$event","_ref2","messagesId","isDisabled","isReadonly","_Fragment","undefined"],"sources":["../../../src/components/VRadioGroup/VRadioGroup.tsx"],"sourcesContent":["// Styles\nimport './VRadioGroup.sass'\n\n// Components\nimport { makeVInputProps, VInput } from '@/components/VInput/VInput'\nimport { VLabel } from '@/components/VLabel'\nimport { VSelectionControl } from '@/components/VSelectionControl'\nimport { makeSelectionControlGroupProps, VSelectionControlGroup } from '@/components/VSelectionControlGroup/VSelectionControlGroup'\n\n// Composables\nimport { IconValue } from '@/composables/icons'\nimport { useProxiedModel } from '@/composables/proxiedModel'\n\n// Utilities\nimport { computed } from 'vue'\nimport { filterInputAttrs, genericComponent, getUid, omit, propsFactory, useRender } from '@/util'\n\n// Types\nimport type { VInputSlots } from '@/components/VInput/VInput'\nimport type { GenericProps } from '@/util'\n\nexport type VRadioGroupSlots = Omit<VInputSlots, 'default'> & {\n default: never\n label: {\n label: string | undefined\n props: Record<string, any>\n }\n}\n\nexport const makeVRadioGroupProps = propsFactory({\n height: {\n type: [Number, String],\n default: 'auto',\n },\n\n ...makeVInputProps(),\n ...omit(makeSelectionControlGroupProps(), ['multiple']),\n\n trueIcon: {\n type: IconValue,\n default: '$radioOn',\n },\n falseIcon: {\n type: IconValue,\n default: '$radioOff',\n },\n type: {\n type: String,\n default: 'radio',\n },\n}, 'VRadioGroup')\n\nexport const VRadioGroup = genericComponent<new <T>(\n props: {\n modelValue?: T | null\n 'onUpdate:modelValue'?: (value: T | null) => void\n },\n slots: VRadioGroupSlots,\n) => GenericProps<typeof props, typeof slots>>()({\n name: 'VRadioGroup',\n\n inheritAttrs: false,\n\n props: makeVRadioGroupProps(),\n\n emits: {\n 'update:modelValue': (value: any) => true,\n },\n\n setup (props, { attrs, slots }) {\n const uid = getUid()\n const id = computed(() => props.id || `radio-group-${uid}`)\n const model = useProxiedModel(props, 'modelValue')\n\n useRender(() => {\n const [rootAttrs, controlAttrs] = filterInputAttrs(attrs)\n const inputProps = VInput.filterProps(props)\n const controlProps = VSelectionControl.filterProps(props)\n const label = slots.label\n ? slots.label({\n label: props.label,\n props: { for: id.value },\n })\n : props.label\n\n return (\n <VInput\n class={[\n 'v-radio-group',\n props.class,\n ]}\n style={ props.style }\n { ...rootAttrs }\n { ...inputProps }\n v-model={ model.value }\n id={ id.value }\n >\n {{\n ...slots,\n default: ({\n id,\n messagesId,\n isDisabled,\n isReadonly,\n }) => (\n <>\n { label && (\n <VLabel id={ id.value }>\n { label }\n </VLabel>\n )}\n\n <VSelectionControlGroup\n { ...controlProps }\n id={ id.value }\n aria-describedby={ messagesId.value }\n defaultsTarget=\"VRadio\"\n trueIcon={ props.trueIcon }\n falseIcon={ props.falseIcon }\n type={ props.type }\n disabled={ isDisabled.value }\n readonly={ isReadonly.value }\n aria-labelledby={ label ? id.value : undefined }\n multiple={ false }\n { ...controlAttrs }\n v-model={ model.value }\n v-slots={ slots }\n />\n </>\n ),\n }}\n </VInput>\n )\n })\n\n return {}\n },\n})\n\nexport type VRadioGroup = InstanceType<typeof VRadioGroup>\n"],"mappings":";AAAA;AACA;;AAEA;AAAA,SACSA,eAAe,EAAEC,MAAM;AAAA,SACvBC,MAAM;AAAA,SACNC,iBAAiB;AAAA,SACjBC,8BAA8B,EAAEC,sBAAsB,gEAE/D;AAAA,SACSC,SAAS;AAA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YAAA,YAChBuB,UAAU,CAACvB,KAAK;YAAA,mBACTa,KAAK,GAAGP,EAAE,CAACN,KAAK,GAAGyB,SAAS;YAAA,YACnC;UAAK,GACXhB,YAAY;YAAA,cACPF,KAAK,CAACP,KAAK;YAAA,uBAAAmB,MAAA,IAAXZ,KAAK,CAACP,KAAK,GAAAmB;UAAA,IACXf,KAAK;QAAA;MAGpB;IAIT,CAAC,CAAC;IAEF,OAAO,CAAC,CAAC;EACX;AACF,CAAC,CAAC","ignoreList":[]}
1
+ {"version":3,"file":"VRadioGroup.mjs","names":["makeVInputProps","VInput","VLabel","VSelectionControl","makeSelectionControlGroupProps","VSelectionControlGroup","IconValue","useProxiedModel","computed","useId","filterInputAttrs","genericComponent","omit","propsFactory","useRender","makeVRadioGroupProps","height","type","Number","String","default","trueIcon","falseIcon","VRadioGroup","name","inheritAttrs","props","emits","value","setup","_ref","attrs","slots","uid","id","model","rootAttrs","controlAttrs","inputProps","filterProps","controlProps","label","for","_createVNode","_mergeProps","class","style","$event","_ref2","messagesId","isDisabled","isReadonly","_Fragment","undefined"],"sources":["../../../src/components/VRadioGroup/VRadioGroup.tsx"],"sourcesContent":["// Styles\nimport './VRadioGroup.sass'\n\n// Components\nimport { makeVInputProps, VInput } from '@/components/VInput/VInput'\nimport { VLabel } from '@/components/VLabel'\nimport { VSelectionControl } from '@/components/VSelectionControl'\nimport { makeSelectionControlGroupProps, VSelectionControlGroup } from '@/components/VSelectionControlGroup/VSelectionControlGroup'\n\n// Composables\nimport { IconValue } from '@/composables/icons'\nimport { useProxiedModel } from '@/composables/proxiedModel'\n\n// Utilities\nimport { computed, useId } from 'vue'\nimport { filterInputAttrs, genericComponent, omit, propsFactory, useRender } from '@/util'\n\n// Types\nimport type { VInputSlots } from '@/components/VInput/VInput'\nimport type { GenericProps } from '@/util'\n\nexport type VRadioGroupSlots = Omit<VInputSlots, 'default'> & {\n default: never\n label: {\n label: string | undefined\n props: Record<string, any>\n }\n}\n\nexport const makeVRadioGroupProps = propsFactory({\n height: {\n type: [Number, String],\n default: 'auto',\n },\n\n ...makeVInputProps(),\n ...omit(makeSelectionControlGroupProps(), ['multiple']),\n\n trueIcon: {\n type: IconValue,\n default: '$radioOn',\n },\n falseIcon: {\n type: IconValue,\n default: '$radioOff',\n },\n type: {\n type: String,\n default: 'radio',\n },\n}, 'VRadioGroup')\n\nexport const VRadioGroup = genericComponent<new <T>(\n props: {\n modelValue?: T | null\n 'onUpdate:modelValue'?: (value: T | null) => void\n },\n slots: VRadioGroupSlots,\n) => GenericProps<typeof props, typeof slots>>()({\n name: 'VRadioGroup',\n\n inheritAttrs: false,\n\n props: makeVRadioGroupProps(),\n\n emits: {\n 'update:modelValue': (value: any) => true,\n },\n\n setup (props, { attrs, slots }) {\n const uid = useId()\n const id = computed(() => props.id || `radio-group-${uid}`)\n const model = useProxiedModel(props, 'modelValue')\n\n useRender(() => {\n const [rootAttrs, controlAttrs] = filterInputAttrs(attrs)\n const inputProps = VInput.filterProps(props)\n const controlProps = VSelectionControl.filterProps(props)\n const label = slots.label\n ? slots.label({\n label: props.label,\n props: { for: id.value },\n })\n : props.label\n\n return (\n <VInput\n class={[\n 'v-radio-group',\n props.class,\n ]}\n style={ props.style }\n { ...rootAttrs }\n { ...inputProps }\n v-model={ model.value }\n id={ id.value }\n >\n {{\n ...slots,\n default: ({\n id,\n messagesId,\n isDisabled,\n isReadonly,\n }) => (\n <>\n { label && (\n <VLabel id={ id.value }>\n { label }\n </VLabel>\n )}\n\n <VSelectionControlGroup\n { ...controlProps }\n id={ id.value }\n aria-describedby={ messagesId.value }\n defaultsTarget=\"VRadio\"\n trueIcon={ props.trueIcon }\n falseIcon={ props.falseIcon }\n type={ props.type }\n disabled={ isDisabled.value }\n readonly={ isReadonly.value }\n aria-labelledby={ label ? id.value : undefined }\n multiple={ false }\n { ...controlAttrs }\n v-model={ model.value }\n v-slots={ slots }\n />\n </>\n ),\n }}\n </VInput>\n )\n })\n\n return {}\n },\n})\n\nexport type VRadioGroup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A,MACZN,EAAE,CAACN,KAAK;YAAA,oBACMqB,UAAU,CAACrB,KAAK;YAAA;YAAA,YAExBF,KAAK,CAACL,QAAQ;YAAA,aACbK,KAAK,CAACJ,SAAS;YAAA,QACpBI,KAAK,CAACT,IAAI;YAAA,YACNiC,UAAU,CAACtB,KAAK;YAAA,YAChBuB,UAAU,CAACvB,KAAK;YAAA,mBACTa,KAAK,GAAGP,EAAE,CAACN,KAAK,GAAGyB,SAAS;YAAA,YACnC;UAAK,GACXhB,YAAY;YAAA,cACPF,KAAK,CAACP,KAAK;YAAA,uBAAAmB,MAAA,IAAXZ,KAAK,CAACP,KAAK,GAAAmB;UAAA,IACXf,KAAK;QAAA;MAGpB;IAIT,CAAC,CAAC;IAEF,OAAO,CAAC,CAAC;EACX;AACF,CAAC,CAAC","ignoreList":[]}
@@ -1,53 +1,54 @@
1
- @layer vuetify.components {
2
- .v-rating {
3
- max-width: 100%;
4
- display: inline-flex;
5
- white-space: nowrap;
6
- }
7
- .v-rating--readonly {
8
- pointer-events: none;
9
- }
10
- .v-rating__wrapper {
11
- align-items: center;
12
- display: inline-flex;
13
- flex-direction: column;
14
- }
15
- .v-rating__wrapper--bottom {
16
- flex-direction: column-reverse;
17
- }
18
- .v-rating__item {
19
- display: inline-flex;
20
- position: relative;
21
- }
22
- .v-rating__item label {
23
- cursor: pointer;
24
- }
25
- .v-rating__item .v-btn--variant-plain {
26
- opacity: 1;
27
- }
28
- .v-rating__item .v-btn {
29
- transition-property: transform;
30
- }
31
- .v-rating__item .v-btn .v-icon {
32
- transition: inherit;
33
- transition-timing-function: cubic-bezier(0, 0, 0.2, 1);
34
- }
35
- .v-rating--hover .v-rating__item:hover:not(.v-rating__item--focused) .v-btn {
36
- transform: scale(1.25);
37
- }
38
- .v-rating__item--half {
39
- overflow: hidden;
40
- position: absolute;
41
- clip-path: polygon(0 0, 50% 0, 50% 100%, 0 100%);
42
- z-index: 1;
43
- }
44
- .v-rating__item--half .v-btn__overlay, .v-rating__item--half:hover .v-btn__overlay {
45
- opacity: 0;
46
- }
47
- .v-rating__hidden {
48
- height: 0;
49
- opacity: 0;
50
- position: absolute;
51
- width: 0;
52
- }
1
+ .v-rating {
2
+ max-width: 100%;
3
+ display: inline-flex;
4
+ white-space: nowrap;
5
+ }
6
+ .v-rating--readonly {
7
+ pointer-events: none;
8
+ }
9
+
10
+ .v-rating__wrapper {
11
+ align-items: center;
12
+ display: inline-flex;
13
+ flex-direction: column;
14
+ }
15
+ .v-rating__wrapper--bottom {
16
+ flex-direction: column-reverse;
17
+ }
18
+
19
+ .v-rating__item {
20
+ display: inline-flex;
21
+ position: relative;
22
+ }
23
+ .v-rating__item label {
24
+ cursor: pointer;
25
+ }
26
+ .v-rating__item .v-btn--variant-plain {
27
+ opacity: 1;
28
+ }
29
+ .v-rating__item .v-btn {
30
+ transition-property: transform;
31
+ }
32
+ .v-rating__item .v-btn .v-icon {
33
+ transition: inherit;
34
+ transition-timing-function: cubic-bezier(0, 0, 0.2, 1);
35
+ }
36
+ .v-rating--hover .v-rating__item:hover:not(.v-rating__item--focused) .v-btn {
37
+ transform: scale(1.25);
38
+ }
39
+ .v-rating__item--half {
40
+ overflow: hidden;
41
+ position: absolute;
42
+ clip-path: polygon(0 0, 50% 0, 50% 100%, 0 100%);
43
+ z-index: 1;
44
+ }
45
+ .v-rating__item--half .v-btn__overlay, .v-rating__item--half:hover .v-btn__overlay {
46
+ opacity: 0;
47
+ }
48
+
49
+ .v-rating__hidden {
50
+ height: 0;
51
+ opacity: 0;
52
+ position: absolute;
53
+ width: 0;
53
54
  }
@@ -12,8 +12,8 @@ import { useProxiedModel } from "../../composables/proxiedModel.mjs";
12
12
  import { makeSizeProps } from "../../composables/size.mjs";
13
13
  import { makeTagProps } from "../../composables/tag.mjs";
14
14
  import { makeThemeProps, provideTheme } from "../../composables/theme.mjs"; // Utilities
15
- import { computed, shallowRef } from 'vue';
16
- import { clamp, createRange, genericComponent, getUid, propsFactory, useRender } from "../../util/index.mjs"; // Types
15
+ import { computed, shallowRef, useId } from 'vue';
16
+ import { clamp, createRange, genericComponent, propsFactory, useRender } from "../../util/index.mjs"; // Types
17
17
  export const makeVRatingProps = propsFactory({
18
18
  name: String,
19
19
  itemAriaLabel: {
@@ -109,7 +109,8 @@ export const VRating = genericComponent()({
109
109
  onClick
110
110
  };
111
111
  }));
112
- const name = computed(() => props.name ?? `v-rating-${getUid()}`);
112
+ const uid = useId();
113
+ const name = computed(() => props.name ?? `v-rating-${uid}`);
113
114
  function VRatingItem(_ref2) {
114
115
  let {
115
116
  value,
@@ -1 +1 @@
1
- {"version":3,"file":"VRating.mjs","names":["VBtn","makeComponentProps","makeDensityProps","IconValue","useLocale","useProxiedModel","makeSizeProps","makeTagProps","makeThemeProps","provideTheme","computed","shallowRef","clamp","createRange","genericComponent","getUid","propsFactory","useRender","makeVRatingProps","name","String","itemAriaLabel","type","default","activeColor","color","clearable","Boolean","disabled","emptyIcon","fullIcon","halfIncrements","hover","length","Number","readonly","modelValue","itemLabels","Array","itemLabelPosition","validator","v","includes","ripple","VRating","props","emits","value","setup","_ref","slots","t","themeClasses","rating","normalizedValue","parseFloat","range","increments","flatMap","hoverIndex","itemState","map","isHovering","isFilled","isHovered","isFullIcon","icon","eventState","onMouseenter","onMouseleave","onClick","undefined","VRatingItem","_ref2","index","showStar","id","replace","btnProps","density","size","variant","_createVNode","_Fragment","item","_mergeProps","createLabel","labelProps","label","_createTextVNode","hasLabels","tag","class","style","i"],"sources":["../../../src/components/VRating/VRating.tsx"],"sourcesContent":["// Styles\nimport './VRating.sass'\n\n// Components\nimport { VBtn } from '@/components/VBtn'\n\n// Composables\nimport { makeComponentProps } from '@/composables/component'\nimport { makeDensityProps } from '@/composables/density'\nimport { IconValue } from '@/composables/icons'\nimport { useLocale } from '@/composables/locale'\nimport { useProxiedModel } from '@/composables/proxiedModel'\nimport { makeSizeProps } from '@/composables/size'\nimport { makeTagProps } from '@/composables/tag'\nimport { makeThemeProps, provideTheme } from '@/composables/theme'\n\n// Utilities\nimport { computed, shallowRef } from 'vue'\nimport { clamp, createRange, genericComponent, getUid, propsFactory, useRender } from '@/util'\n\n// Types\nimport type { Prop } from 'vue'\nimport type { Variant } from '@/composables/variant'\n\ntype VRatingItemSlot = {\n value: number\n index: number\n isFilled: boolean\n isHovered: boolean\n icon: IconValue\n color?: string\n props: Record<string, unknown>\n rating: number\n}\n\ntype VRatingItemLabelSlot = {\n value: number\n index: number\n label?: string\n}\n\ntype VRatingSlots = {\n item: VRatingItemSlot\n 'item-label': VRatingItemLabelSlot\n}\n\nexport const makeVRatingProps = propsFactory({\n name: String,\n itemAriaLabel: {\n type: String,\n default: '$vuetify.rating.ariaLabel.item',\n },\n activeColor: String,\n color: String,\n clearable: Boolean,\n disabled: Boolean,\n emptyIcon: {\n type: IconValue,\n default: '$ratingEmpty',\n },\n fullIcon: {\n type: IconValue,\n default: '$ratingFull',\n },\n halfIncrements: Boolean,\n hover: Boolean,\n length: {\n type: [Number, String],\n default: 5,\n },\n readonly: Boolean,\n modelValue: {\n type: [Number, String],\n default: 0,\n },\n itemLabels: Array as Prop<string[]>,\n itemLabelPosition: {\n type: String,\n default: 'top',\n validator: (v: any) => ['top', 'bottom'].includes(v),\n },\n ripple: Boolean,\n\n ...makeComponentProps(),\n ...makeDensityProps(),\n ...makeSizeProps(),\n ...makeTagProps(),\n ...makeThemeProps(),\n}, 'VRating')\n\nexport const VRating = genericComponent<VRatingSlots>()({\n name: 'VRating',\n\n props: makeVRatingProps(),\n\n emits: {\n 'update:modelValue': (value: number | string) => true,\n },\n\n setup (props, { slots }) {\n const { t } = useLocale()\n const { themeClasses } = provideTheme(props)\n const rating = useProxiedModel(props, 'modelValue')\n const normalizedValue = computed(() => clamp(parseFloat(rating.value), 0, +props.length))\n\n const range = computed(() => createRange(Number(props.length), 1))\n const increments = computed(() => range.value.flatMap(v => props.halfIncrements ? [v - 0.5, v] : [v]))\n const hoverIndex = shallowRef(-1)\n\n const itemState = computed(() => increments.value.map(value => {\n const isHovering = props.hover && hoverIndex.value > -1\n const isFilled = normalizedValue.value >= value\n const isHovered = hoverIndex.value >= value\n const isFullIcon = isHovering ? isHovered : isFilled\n const icon = isFullIcon ? props.fullIcon : props.emptyIcon\n const activeColor = props.activeColor ?? props.color\n const color = (isFilled || isHovered) ? activeColor : props.color\n\n return { isFilled, isHovered, icon, color }\n }))\n\n const eventState = computed(() => [0, ...increments.value].map(value => {\n function onMouseenter () {\n hoverIndex.value = value\n }\n\n function onMouseleave () {\n hoverIndex.value = -1\n }\n\n function onClick () {\n if (props.disabled || props.readonly) return\n rating.value = normalizedValue.value === value && props.clearable ? 0 : value\n }\n\n return {\n onMouseenter: props.hover ? onMouseenter : undefined,\n onMouseleave: props.hover ? onMouseleave : undefined,\n onClick,\n }\n }))\n\n const name = computed(() => props.name ?? `v-rating-${getUid()}`)\n\n function VRatingItem ({ value, index, showStar = true }: { value: number, index: number, showStar?: boolean }) {\n const { onMouseenter, onMouseleave, onClick } = eventState.value[index + 1]\n const id = `${name.value}-${String(value).replace('.', '-')}`\n const btnProps = {\n color: itemState.value[index]?.color,\n density: props.density,\n disabled: props.disabled,\n icon: itemState.value[index]?.icon,\n ripple: props.ripple,\n size: props.size,\n variant: 'plain' as Variant,\n }\n\n return (\n <>\n <label\n for={ id }\n class={{\n 'v-rating__item--half': props.halfIncrements && value % 1 > 0,\n 'v-rating__item--full': props.halfIncrements && value % 1 === 0,\n }}\n onMouseenter={ onMouseenter }\n onMouseleave={ onMouseleave }\n onClick={ onClick }\n >\n <span class=\"v-rating__hidden\">{ t(props.itemAriaLabel, value, props.length) }</span>\n {\n !showStar ? undefined\n : slots.item ? slots.item({\n ...itemState.value[index],\n props: btnProps,\n value,\n index,\n rating: normalizedValue.value,\n })\n : (\n <VBtn\n aria-label={ t(props.itemAriaLabel, value, props.length) }\n { ...btnProps }\n />\n )\n }\n </label>\n\n <input\n class=\"v-rating__hidden\"\n name={ name.value }\n id={ id }\n type=\"radio\"\n value={ value }\n checked={ normalizedValue.value === value }\n tabindex={ -1 }\n readonly={ props.readonly }\n disabled={ props.disabled }\n />\n </>\n )\n }\n\n function createLabel (labelProps: { value: number, index: number, label?: string }) {\n if (slots['item-label']) return slots['item-label'](labelProps)\n\n if (labelProps.label) return <span>{ labelProps.label }</span>\n\n return <span>&nbsp;</span>\n }\n\n useRender(() => {\n const hasLabels = !!props.itemLabels?.length || slots['item-label']\n\n return (\n <props.tag\n class={[\n 'v-rating',\n {\n 'v-rating--hover': props.hover,\n 'v-rating--readonly': props.readonly,\n },\n themeClasses.value,\n props.class,\n ]}\n style={ props.style }\n >\n <VRatingItem value={ 0 } index={ -1 } showStar={ false } />\n\n { range.value.map((value, i) => (\n <div class=\"v-rating__wrapper\">\n {\n hasLabels && props.itemLabelPosition === 'top'\n ? createLabel({ value, index: i, label: props.itemLabels?.[i] })\n : undefined\n }\n <div class=\"v-rating__item\">\n { props.halfIncrements ? (\n <>\n <VRatingItem value={ value - 0.5 } index={ i * 2 } />\n <VRatingItem value={ value } index={ (i * 2) + 1 } />\n </>\n ) : (\n <VRatingItem value={ value } index={ i } />\n )}\n </div>\n {\n hasLabels && props.itemLabelPosition === 'bottom'\n ? createLabel({ value, index: i, label: props.itemLabels?.[i] })\n : undefined\n }\n </div>\n ))}\n </props.tag>\n )\n })\n\n return {}\n },\n})\n\nexport type VRating = InstanceType<typeof VRating>\n"],"mappings":";AAAA;AACA;;AAEA;AAAA,SACSA,IAAI,6BAEb;AAAA,SACSC,kBAAkB;AAAA,SAClBC,gBAAgB;AAAA,SAChBC,SAAS;AAAA,SACTC,SAAS;AAAA,SACTC,eAAe;AAAA,SACfC,aAAa;AAAA,SACbC,YAAY;AAAA,SACZC,cAAc,EAAEC,YAAY,uCAErC;AACA,SAASC,QAAQ,EAAEC,UAAU,QAAQ,KAAK;AAAA,SACjCC,KAAK,EAAEC,WAAW,EAAEC,gBAAgB,EAAEC,MAAM,EAAEC,YAAY,EAAEC,SAAS,gCAE9E;AA0BA,OAAO,MAAMC,gB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WAAA;UAAA,SAEE,CAAC;UAAA,SAAW,CAAC,CAAC;UAAA,YAAc;QAAK,UAEpDhB,KAAK,CAACT,KAAK,CAACc,GAAG,CAAC,CAACd,KAAK,EAAE+C,CAAC,KAAAZ,YAAA;UAAA;QAAA,IAGrBQ,SAAS,IAAI7C,KAAK,CAACN,iBAAiB,KAAK,KAAK,GAC1C+C,WAAW,CAAC;UAAEvC,KAAK;UAAE2B,KAAK,EAAEoB,CAAC;UAAEN,KAAK,EAAE3C,KAAK,CAACR,UAAU,GAAGyD,CAAC;QAAE,CAAC,CAAC,GAC9DvB,SAAS,EAAAW,YAAA;UAAA;QAAA,IAGXrC,KAAK,CAACd,cAAc,GAAAmD,YAAA,CAAAC,SAAA,SAAAD,YAAA,CAAAV,WAAA;UAAA,SAEGzB,KAAK,GAAG,GAAG;UAAA,SAAW+C,CAAC,GAAG;QAAC,UAAAZ,YAAA,CAAAV,WAAA;UAAA,SAC3BzB,KAAK;UAAA,SAAY+C,CAAC,GAAG,CAAC,GAAI;QAAC,aAAAZ,YAAA,CAAAV,WAAA;UAAA,SAG7BzB,KAAK;UAAA,SAAW+C;QAAC,QACvC,IAGDJ,SAAS,IAAI7C,KAAK,CAACN,iBAAiB,KAAK,QAAQ,GAC7C+C,WAAW,CAAC;UAAEvC,KAAK;UAAE2B,KAAK,EAAEoB,CAAC;UAAEN,KAAK,EAAE3C,KAAK,CAACR,UAAU,GAAGyD,CAAC;QAAE,CAAC,CAAC,GAC9DvB,SAAS,EAGlB,CAAC;MAAA;IAGR,CAAC,CAAC;IAEF,OAAO,CAAC,CAAC;EACX;AACF,CAAC,CAAC","ignoreList":[]}
1
+ {"version":3,"file":"VRating.mjs","names":["VBtn","makeComponentProps","makeDensityProps","IconValue","useLocale","useProxiedModel","makeSizeProps","makeTagProps","makeThemeProps","provideTheme","computed","shallowRef","useId","clamp","createRange","genericComponent","propsFactory","useRender","makeVRatingProps","name","String","itemAriaLabel","type","default","activeColor","color","clearable","Boolean","disabled","emptyIcon","fullIcon","halfIncrements","hover","length","Number","readonly","modelValue","itemLabels","Array","itemLabelPosition","validator","v","includes","ripple","VRating","props","emits","value","setup","_ref","slots","t","themeClasses","rating","normalizedValue","parseFloat","range","increments","flatMap","hoverIndex","itemState","map","isHovering","isFilled","isHovered","isFullIcon","icon","eventState","onMouseenter","onMouseleave","onClick","undefined","uid","VRatingItem","_ref2","index","showStar","id","replace","btnProps","density","size","variant","_createVNode","_Fragment","item","_mergeProps","createLabel","labelProps","label","_createTextVNode","hasLabels","tag","class","style","i"],"sources":["../../../src/components/VRating/VRating.tsx"],"sourcesContent":["// Styles\nimport './VRating.sass'\n\n// Components\nimport { VBtn } from '@/components/VBtn'\n\n// Composables\nimport { makeComponentProps } from '@/composables/component'\nimport { makeDensityProps } from '@/composables/density'\nimport { IconValue } from '@/composables/icons'\nimport { useLocale } from '@/composables/locale'\nimport { useProxiedModel } from '@/composables/proxiedModel'\nimport { makeSizeProps } from '@/composables/size'\nimport { makeTagProps } from '@/composables/tag'\nimport { makeThemeProps, provideTheme } from '@/composables/theme'\n\n// Utilities\nimport { computed, shallowRef, useId } from 'vue'\nimport { clamp, createRange, genericComponent, propsFactory, useRender } from '@/util'\n\n// Types\nimport type { Prop } from 'vue'\nimport type { Variant } from '@/composables/variant'\n\ntype VRatingItemSlot = {\n value: number\n index: number\n isFilled: boolean\n isHovered: boolean\n icon: IconValue\n color?: string\n props: Record<string, unknown>\n rating: number\n}\n\ntype VRatingItemLabelSlot = {\n value: number\n index: number\n label?: string\n}\n\ntype VRatingSlots = {\n item: VRatingItemSlot\n 'item-label': VRatingItemLabelSlot\n}\n\nexport const makeVRatingProps = propsFactory({\n name: String,\n itemAriaLabel: {\n type: String,\n default: '$vuetify.rating.ariaLabel.item',\n },\n activeColor: String,\n color: String,\n clearable: Boolean,\n disabled: Boolean,\n emptyIcon: {\n type: IconValue,\n default: '$ratingEmpty',\n },\n fullIcon: {\n type: IconValue,\n default: '$ratingFull',\n },\n halfIncrements: Boolean,\n hover: Boolean,\n length: {\n type: [Number, String],\n default: 5,\n },\n readonly: Boolean,\n modelValue: {\n type: [Number, String],\n default: 0,\n },\n itemLabels: Array as Prop<string[]>,\n itemLabelPosition: {\n type: String,\n default: 'top',\n validator: (v: any) => ['top', 'bottom'].includes(v),\n },\n ripple: Boolean,\n\n ...makeComponentProps(),\n ...makeDensityProps(),\n ...makeSizeProps(),\n ...makeTagProps(),\n ...makeThemeProps(),\n}, 'VRating')\n\nexport const VRating = genericComponent<VRatingSlots>()({\n name: 'VRating',\n\n props: makeVRatingProps(),\n\n emits: {\n 'update:modelValue': (value: number | string) => true,\n },\n\n setup (props, { slots }) {\n const { t } = useLocale()\n const { themeClasses } = provideTheme(props)\n const rating = useProxiedModel(props, 'modelValue')\n const normalizedValue = computed(() => clamp(parseFloat(rating.value), 0, +props.length))\n\n const range = computed(() => createRange(Number(props.length), 1))\n const increments = computed(() => range.value.flatMap(v => props.halfIncrements ? [v - 0.5, v] : [v]))\n const hoverIndex = shallowRef(-1)\n\n const itemState = computed(() => increments.value.map(value => {\n const isHovering = props.hover && hoverIndex.value > -1\n const isFilled = normalizedValue.value >= value\n const isHovered = hoverIndex.value >= value\n const isFullIcon = isHovering ? isHovered : isFilled\n const icon = isFullIcon ? props.fullIcon : props.emptyIcon\n const activeColor = props.activeColor ?? props.color\n const color = (isFilled || isHovered) ? activeColor : props.color\n\n return { isFilled, isHovered, icon, color }\n }))\n\n const eventState = computed(() => [0, ...increments.value].map(value => {\n function onMouseenter () {\n hoverIndex.value = value\n }\n\n function onMouseleave () {\n hoverIndex.value = -1\n }\n\n function onClick () {\n if (props.disabled || props.readonly) return\n rating.value = normalizedValue.value === value && props.clearable ? 0 : value\n }\n\n return {\n onMouseenter: props.hover ? onMouseenter : undefined,\n onMouseleave: props.hover ? onMouseleave : undefined,\n onClick,\n }\n }))\n\n const uid = useId()\n const name = computed(() => props.name ?? `v-rating-${uid}`)\n\n function VRatingItem ({ value, index, showStar = true }: { value: number, index: number, showStar?: boolean }) {\n const { onMouseenter, onMouseleave, onClick } = eventState.value[index + 1]\n const id = `${name.value}-${String(value).replace('.', '-')}`\n const btnProps = {\n color: itemState.value[index]?.color,\n density: props.density,\n disabled: props.disabled,\n icon: itemState.value[index]?.icon,\n ripple: props.ripple,\n size: props.size,\n variant: 'plain' as Variant,\n }\n\n return (\n <>\n <label\n for={ id }\n class={{\n 'v-rating__item--half': props.halfIncrements && value % 1 > 0,\n 'v-rating__item--full': props.halfIncrements && value % 1 === 0,\n }}\n onMouseenter={ onMouseenter }\n onMouseleave={ onMouseleave }\n onClick={ onClick }\n >\n <span class=\"v-rating__hidden\">{ t(props.itemAriaLabel, value, props.length) }</span>\n {\n !showStar ? undefined\n : slots.item ? slots.item({\n ...itemState.value[index],\n props: btnProps,\n value,\n index,\n rating: normalizedValue.value,\n })\n : (\n <VBtn\n aria-label={ t(props.itemAriaLabel, value, props.length) }\n { ...btnProps }\n />\n )\n }\n </label>\n\n <input\n class=\"v-rating__hidden\"\n name={ name.value }\n id={ id }\n type=\"radio\"\n value={ value }\n checked={ normalizedValue.value === value }\n tabindex={ -1 }\n readonly={ props.readonly }\n disabled={ props.disabled }\n />\n </>\n )\n }\n\n function createLabel (labelProps: { value: number, index: number, label?: string }) {\n if (slots['item-label']) return slots['item-label'](labelProps)\n\n if (labelProps.label) return <span>{ labelProps.label }</span>\n\n return <span>&nbsp;</span>\n }\n\n useRender(() => {\n const hasLabels = !!props.itemLabels?.length || slots['item-label']\n\n return (\n <props.tag\n class={[\n 'v-rating',\n {\n 'v-rating--hover': props.hover,\n 'v-rating--readonly': props.readonly,\n },\n themeClasses.value,\n props.class,\n ]}\n style={ props.style }\n >\n <VRatingItem value={ 0 } index={ -1 } showStar={ false } />\n\n { range.value.map((value, i) => (\n <div class=\"v-rating__wrapper\">\n {\n hasLabels && props.itemLabelPosition === 'top'\n ? createLabel({ value, index: i, label: props.itemLabels?.[i] })\n : undefined\n }\n <div class=\"v-rating__item\">\n { props.halfIncrements ? (\n <>\n <VRatingItem value={ value - 0.5 } index={ i * 2 } />\n <VRatingItem value={ value } index={ (i * 2) + 1 } />\n </>\n ) : (\n <VRatingItem value={ value } index={ i } />\n )}\n </div>\n {\n hasLabels && props.itemLabelPosition === 'bottom'\n ? createLabel({ value, index: i, label: props.itemLabels?.[i] })\n : undefined\n }\n </div>\n ))}\n </props.tag>\n )\n })\n\n return {}\n },\n})\n\nexport type VRating = InstanceType<typeof VRating>\n"],"mappings":";AAAA;AACA;;AAEA;AAAA,SACSA,IAAI,6BAEb;AAAA,SACSC,kBAAkB;AAAA,SAClBC,gBAAgB;AAAA,SAChBC,SAAS;AAAA,SACTC,SAAS;AAAA,SACTC,eAAe;AAAA,SACfC,aAAa;AAAA,SACbC,YAAY;AAAA,SACZC,cAAc,EAAEC,YAAY,uCAErC;AACA,SAASC,QAAQ,EAAEC,UAAU,EAAEC,KAAK,QAAQ,KAAK;AAAA,SACxCC,KAAK,EAAEC,WAAW,EAAEC,gBAAgB,EAAEC,YAAY,EAAEC,SAAS,gCAEtE;AA0BA,OAAO,MAAMC,gBAAgB,GAAGF,YAAY,CAAC;EAC3CG,IAAI,EAAEC,MAAM;EACZC,aAAa,EAAE;IACbC,IAAI,EAAEF,MAAM;IACZG,OAAO,EAAE;EACX,CAAC;EACDC,WAAW,EAAEJ,MAAM;EACnBK,KAAK,EAAEL,MAAM;EACbM,SAAS,EAAEC,OAAO;EAClBC,QAAQ,EAAED,OAAO;EACjBE,SAAS,EAAE;IACTP,IAAI,EAAEnB,SAAS;IACfoB,OAAO,EAAE;EACX,CAAC;EACDO,QAAQ,EAAE;IACRR,IAAI,EAAEnB,SAAS;IACfoB,OAAO,EAAE;EACX,CAAC;EACDQ,cAAc,EAAEJ,OAAO;EACvBK,KAAK,EAAEL,OAAO;EACdM,MAAM,EAAE;IACNX,IAAI,EAAE,CAACY,MAAM,EAAEd,MAAM,CAAC;IACtBG,OAAO,EAAE;EACX,CAAC;EACDY,QAAQ,EAAER,OAAO;EACj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AG;QAAC,UAAAZ,YAAA,CAAAV,WAAA;UAAA,SAC3B1B,KAAK;UAAA,SAAYgD,CAAC,GAAG,CAAC,GAAI;QAAC,aAAAZ,YAAA,CAAAV,WAAA;UAAA,SAG7B1B,KAAK;UAAA,SAAWgD;QAAC,QACvC,IAGDJ,SAAS,IAAI9C,KAAK,CAACN,iBAAiB,KAAK,QAAQ,GAC7CgD,WAAW,CAAC;UAAExC,KAAK;UAAE4B,KAAK,EAAEoB,CAAC;UAAEN,KAAK,EAAE5C,KAAK,CAACR,UAAU,GAAG0D,CAAC;QAAE,CAAC,CAAC,GAC9DxB,SAAS,EAGlB,CAAC;MAAA;IAGR,CAAC,CAAC;IAEF,OAAO,CAAC,CAAC;EACX;AACF,CAAC,CAAC","ignoreList":[]}
@@ -1,26 +1,27 @@
1
- @layer vuetify.components {
2
- .v-responsive {
3
- display: flex;
4
- flex: 1 0 auto;
5
- max-height: 100%;
6
- max-width: 100%;
7
- overflow: hidden;
8
- position: relative;
9
- }
10
- .v-responsive--inline {
11
- display: inline-flex;
12
- flex: 0 0 auto;
13
- }
14
- .v-responsive__content {
15
- flex: 1 0 0px;
16
- max-width: 100%;
17
- }
18
- .v-responsive__sizer ~ .v-responsive__content {
19
- margin-inline-start: -100%;
20
- }
21
- .v-responsive__sizer {
22
- flex: 1 0 0px;
23
- transition: padding-bottom 0.2s cubic-bezier(0.4, 0, 0.2, 1);
24
- pointer-events: none;
25
- }
1
+ .v-responsive {
2
+ display: flex;
3
+ flex: 1 0 auto;
4
+ max-height: 100%;
5
+ max-width: 100%;
6
+ overflow: hidden;
7
+ position: relative;
8
+ }
9
+ .v-responsive--inline {
10
+ display: inline-flex;
11
+ flex: 0 0 auto;
12
+ }
13
+
14
+ .v-responsive__content {
15
+ flex: 1 0 0px;
16
+ max-width: 100%;
17
+ }
18
+
19
+ .v-responsive__sizer ~ .v-responsive__content {
20
+ margin-inline-start: -100%;
21
+ }
22
+
23
+ .v-responsive__sizer {
24
+ flex: 1 0 0px;
25
+ transition: padding-bottom 0.2s cubic-bezier(0.4, 0, 0.2, 1);
26
+ pointer-events: none;
26
27
  }
@@ -1,55 +1,53 @@
1
- @layer vuetify.components {
2
- .v-select .v-field .v-text-field__prefix,
3
- .v-select .v-field .v-text-field__suffix,
4
- .v-select .v-field .v-field__input, .v-select .v-field.v-field {
5
- cursor: pointer;
6
- }
7
- .v-select .v-field .v-field__input > input {
8
- align-self: flex-start;
9
- opacity: 1;
10
- flex: 0 0;
11
- position: absolute;
12
- width: 100%;
13
- transition: none;
14
- pointer-events: none;
15
- caret-color: transparent;
16
- }
17
- .v-select .v-field--dirty .v-select__selection {
18
- margin-inline-end: 2px;
19
- }
20
- .v-select .v-select__selection-text {
21
- overflow: hidden;
22
- text-overflow: ellipsis;
23
- white-space: nowrap;
24
- }
25
- .v-select__content {
26
- overflow: hidden;
27
- }
28
- .v-select__content {
29
- box-shadow: 0px 2px 4px -1px var(--v-shadow-key-umbra-opacity, rgba(0, 0, 0, 0.2)), 0px 4px 5px 0px var(--v-shadow-key-penumbra-opacity, rgba(0, 0, 0, 0.14)), 0px 1px 10px 0px var(--v-shadow-key-ambient-opacity, rgba(0, 0, 0, 0.12));
30
- }
31
- .v-select__content {
32
- border-radius: 4px;
33
- }
34
- .v-select__selection {
35
- display: inline-flex;
36
- align-items: center;
37
- letter-spacing: inherit;
38
- line-height: inherit;
39
- max-width: 100%;
40
- }
41
- .v-select .v-select__selection:first-child {
42
- margin-inline-start: 0;
43
- }
44
- .v-select--selected .v-field .v-field__input > input {
45
- opacity: 0;
46
- }
47
- .v-select__menu-icon {
48
- margin-inline-start: 4px;
49
- transition: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
50
- }
51
- .v-select--active-menu .v-select__menu-icon {
52
- opacity: var(--v-high-emphasis-opacity);
53
- transform: rotate(180deg);
54
- }
1
+ .v-select .v-field .v-text-field__prefix,
2
+ .v-select .v-field .v-text-field__suffix,
3
+ .v-select .v-field .v-field__input, .v-select .v-field.v-field {
4
+ cursor: pointer;
5
+ }
6
+ .v-select .v-field .v-field__input > input {
7
+ align-self: flex-start;
8
+ opacity: 1;
9
+ flex: 0 0;
10
+ position: absolute;
11
+ width: 100%;
12
+ transition: none;
13
+ pointer-events: none;
14
+ caret-color: transparent;
15
+ }
16
+ .v-select .v-field--dirty .v-select__selection {
17
+ margin-inline-end: 2px;
18
+ }
19
+ .v-select .v-select__selection-text {
20
+ overflow: hidden;
21
+ text-overflow: ellipsis;
22
+ white-space: nowrap;
23
+ }
24
+ .v-select__content {
25
+ overflow: hidden;
26
+ }
27
+ .v-select__content {
28
+ box-shadow: 0px 2px 4px -1px var(--v-shadow-key-umbra-opacity, rgba(0, 0, 0, 0.2)), 0px 4px 5px 0px var(--v-shadow-key-penumbra-opacity, rgba(0, 0, 0, 0.14)), 0px 1px 10px 0px var(--v-shadow-key-ambient-opacity, rgba(0, 0, 0, 0.12));
29
+ }
30
+ .v-select__content {
31
+ border-radius: 4px;
32
+ }
33
+ .v-select__selection {
34
+ display: inline-flex;
35
+ align-items: center;
36
+ letter-spacing: inherit;
37
+ line-height: inherit;
38
+ max-width: 100%;
39
+ }
40
+ .v-select .v-select__selection:first-child {
41
+ margin-inline-start: 0;
42
+ }
43
+ .v-select--selected .v-field .v-field__input > input {
44
+ opacity: 0;
45
+ }
46
+ .v-select__menu-icon {
47
+ margin-inline-start: 4px;
48
+ transition: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
49
+ }
50
+ .v-select--active-menu .v-select__menu-icon {
51
+ opacity: var(--v-high-emphasis-opacity);
52
+ transform: rotate(180deg);
55
53
  }
@@ -109,7 +109,7 @@ export const VSelect = genericComponent()({
109
109
  const counterValue = computed(() => {
110
110
  return typeof props.counterValue === 'function' ? props.counterValue(model.value) : typeof props.counterValue === 'number' ? props.counterValue : model.value.length;
111
111
  });
112
- const form = useForm();
112
+ const form = useForm(props);
113
113
  const selectedValues = computed(() => model.value.map(selection => selection.value));
114
114
  const isFocused = shallowRef(false);
115
115
  const label = computed(() => menu.value ? props.closeText : props.openText);
@@ -121,7 +121,7 @@ export const VSelect = genericComponent()({
121
121
  }
122
122
  return items.value;
123
123
  });
124
- const menuDisabled = computed(() => props.hideNoData && !displayItems.value.length || props.readonly || form?.isReadonly.value);
124
+ const menuDisabled = computed(() => props.hideNoData && !displayItems.value.length || form.isReadonly.value || form.isDisabled.value);
125
125
  const computedMenuProps = computed(() => {
126
126
  return {
127
127
  ...props.menuProps,
@@ -148,7 +148,7 @@ export const VSelect = genericComponent()({
148
148
  }
149
149
  }
150
150
  function onKeydown(e) {
151
- if (!e.key || props.readonly || form?.isReadonly.value) return;
151
+ if (!e.key || form.isReadonly.value) return;
152
152
  if (['Enter', ' ', 'ArrowDown', 'ArrowUp', 'Home', 'End'].includes(e.key)) {
153
153
  e.preventDefault();
154
154
  }