@vuetify/nightly 3.0.0-beta.13 → 3.0.0-beta.15

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 (840) hide show
  1. package/CHANGELOG.md +23 -5
  2. package/dist/json/importMap.json +26 -30
  3. package/dist/vuetify.css +262 -173
  4. package/dist/vuetify.d.ts +16645 -7306
  5. package/dist/vuetify.esm.js +1040 -2004
  6. package/dist/vuetify.esm.js.map +1 -1
  7. package/dist/vuetify.js +1038 -2003
  8. package/dist/vuetify.js.map +1 -1
  9. package/dist/vuetify.min.css +2 -2
  10. package/dist/vuetify.min.js +531 -537
  11. package/dist/vuetify.min.js.map +1 -1
  12. package/lib/blueprints/index.d.ts +24 -32
  13. package/lib/blueprints/index.mjs.map +1 -1
  14. package/lib/blueprints/md1.d.ts +24 -32
  15. package/lib/blueprints/md1.mjs +3 -1
  16. package/lib/blueprints/md1.mjs.map +1 -1
  17. package/lib/blueprints/md2.d.ts +24 -32
  18. package/lib/blueprints/md2.mjs +3 -1
  19. package/lib/blueprints/md2.mjs.map +1 -1
  20. package/lib/blueprints/md3.d.ts +24 -32
  21. package/lib/blueprints/md3.mjs +2 -2
  22. package/lib/blueprints/md3.mjs.map +1 -1
  23. package/lib/components/VAlert/VAlert.mjs +2 -9
  24. package/lib/components/VAlert/VAlert.mjs.map +1 -1
  25. package/lib/components/VAlert/VAlertTitle.mjs.map +1 -1
  26. package/lib/components/VAlert/index.d.ts +7 -5
  27. package/lib/components/VAlert/index.mjs.map +1 -1
  28. package/lib/components/VApp/VApp.mjs +5 -7
  29. package/lib/components/VApp/VApp.mjs.map +1 -1
  30. package/lib/components/VApp/index.d.ts +4 -2
  31. package/lib/components/VApp/index.mjs.map +1 -1
  32. package/lib/components/VAppBar/VAppBar.mjs +4 -8
  33. package/lib/components/VAppBar/VAppBar.mjs.map +1 -1
  34. package/lib/components/VAppBar/VAppBarNavIcon.mjs +0 -4
  35. package/lib/components/VAppBar/VAppBarNavIcon.mjs.map +1 -1
  36. package/lib/components/VAppBar/VAppBarTitle.mjs +2 -4
  37. package/lib/components/VAppBar/VAppBarTitle.mjs.map +1 -1
  38. package/lib/components/VAppBar/index.d.ts +7 -3
  39. package/lib/components/VAppBar/index.mjs.map +1 -1
  40. package/lib/components/VAutocomplete/VAutocomplete.css +18 -1
  41. package/lib/components/VAutocomplete/VAutocomplete.mjs +16 -35
  42. package/lib/components/VAutocomplete/VAutocomplete.mjs.map +1 -1
  43. package/lib/components/VAutocomplete/VAutocomplete.sass +11 -1
  44. package/lib/components/VAutocomplete/_variables.scss +1 -0
  45. package/lib/components/VAutocomplete/index.d.ts +267 -376
  46. package/lib/components/VAutocomplete/index.mjs.map +1 -1
  47. package/lib/components/VAvatar/VAvatar.mjs +3 -7
  48. package/lib/components/VAvatar/VAvatar.mjs.map +1 -1
  49. package/lib/components/VAvatar/index.d.ts +5 -3
  50. package/lib/components/VAvatar/index.mjs.map +1 -1
  51. package/lib/components/VBadge/VBadge.mjs +2 -6
  52. package/lib/components/VBadge/VBadge.mjs.map +1 -1
  53. package/lib/components/VBadge/index.mjs.map +1 -1
  54. package/lib/components/VBanner/VBanner.mjs +5 -7
  55. package/lib/components/VBanner/VBanner.mjs.map +1 -1
  56. package/lib/components/VBanner/VBannerActions.mjs +0 -4
  57. package/lib/components/VBanner/VBannerActions.mjs.map +1 -1
  58. package/lib/components/VBanner/VBannerText.mjs.map +1 -1
  59. package/lib/components/VBanner/index.d.ts +7 -3
  60. package/lib/components/VBanner/index.mjs.map +1 -1
  61. package/lib/components/VBottomNavigation/VBottomNavigation.mjs +2 -5
  62. package/lib/components/VBottomNavigation/VBottomNavigation.mjs.map +1 -1
  63. package/lib/components/VBottomNavigation/index.d.ts +5 -3
  64. package/lib/components/VBottomNavigation/index.mjs.map +1 -1
  65. package/lib/components/VBottomSheet/VBottomSheet.mjs +5 -5
  66. package/lib/components/VBottomSheet/VBottomSheet.mjs.map +1 -1
  67. package/lib/components/VBottomSheet/index.mjs.map +1 -1
  68. package/lib/components/VBreadcrumbs/VBreadcrumbs.mjs +5 -9
  69. package/lib/components/VBreadcrumbs/VBreadcrumbs.mjs.map +1 -1
  70. package/lib/components/VBreadcrumbs/VBreadcrumbsDivider.mjs.map +1 -1
  71. package/lib/components/VBreadcrumbs/VBreadcrumbsItem.mjs +0 -5
  72. package/lib/components/VBreadcrumbs/VBreadcrumbsItem.mjs.map +1 -1
  73. package/lib/components/VBreadcrumbs/index.d.ts +50 -40
  74. package/lib/components/VBreadcrumbs/index.mjs.map +1 -1
  75. package/lib/components/VBtn/VBtn.mjs +2 -10
  76. package/lib/components/VBtn/VBtn.mjs.map +1 -1
  77. package/lib/components/VBtn/index.d.ts +5 -3
  78. package/lib/components/VBtn/index.mjs.map +1 -1
  79. package/lib/components/VBtnGroup/VBtnGroup.mjs +2 -4
  80. package/lib/components/VBtnGroup/VBtnGroup.mjs.map +1 -1
  81. package/lib/components/VBtnGroup/index.d.ts +6 -3
  82. package/lib/components/VBtnGroup/index.mjs.map +1 -1
  83. package/lib/components/VBtnToggle/VBtnToggle.mjs +2 -7
  84. package/lib/components/VBtnToggle/VBtnToggle.mjs.map +1 -1
  85. package/lib/components/VBtnToggle/index.d.ts +20 -25
  86. package/lib/components/VBtnToggle/index.mjs.map +1 -1
  87. package/lib/components/VCalendar/VCalendar.mjs +6 -67
  88. package/lib/components/VCalendar/VCalendar.mjs.map +1 -1
  89. package/lib/components/VCalendar/VCalendarCategory.mjs +7 -18
  90. package/lib/components/VCalendar/VCalendarCategory.mjs.map +1 -1
  91. package/lib/components/VCalendar/VCalendarDaily.mjs +3 -34
  92. package/lib/components/VCalendar/VCalendarDaily.mjs.map +1 -1
  93. package/lib/components/VCalendar/VCalendarMonthly.mjs +3 -7
  94. package/lib/components/VCalendar/VCalendarMonthly.mjs.map +1 -1
  95. package/lib/components/VCalendar/VCalendarWeekly.mjs +3 -32
  96. package/lib/components/VCalendar/VCalendarWeekly.mjs.map +1 -1
  97. package/lib/components/VCalendar/index.mjs.map +1 -1
  98. package/lib/components/VCalendar/mixins/calendar-base.mjs +1 -19
  99. package/lib/components/VCalendar/mixins/calendar-base.mjs.map +1 -1
  100. package/lib/components/VCalendar/mixins/calendar-with-events.mjs +14 -78
  101. package/lib/components/VCalendar/mixins/calendar-with-events.mjs.map +1 -1
  102. package/lib/components/VCalendar/mixins/calendar-with-intervals.mjs +0 -30
  103. package/lib/components/VCalendar/mixins/calendar-with-intervals.mjs.map +1 -1
  104. package/lib/components/VCalendar/mixins/mouse.mjs +7 -17
  105. package/lib/components/VCalendar/mixins/mouse.mjs.map +1 -1
  106. package/lib/components/VCalendar/mixins/times.mjs +1 -9
  107. package/lib/components/VCalendar/mixins/times.mjs.map +1 -1
  108. package/lib/components/VCalendar/modes/column.mjs +0 -3
  109. package/lib/components/VCalendar/modes/column.mjs.map +1 -1
  110. package/lib/components/VCalendar/modes/common.mjs +0 -14
  111. package/lib/components/VCalendar/modes/common.mjs.map +1 -1
  112. package/lib/components/VCalendar/modes/index.mjs +0 -1
  113. package/lib/components/VCalendar/modes/index.mjs.map +1 -1
  114. package/lib/components/VCalendar/modes/stack.mjs +3 -45
  115. package/lib/components/VCalendar/modes/stack.mjs.map +1 -1
  116. package/lib/components/VCalendar/util/events.mjs +0 -1
  117. package/lib/components/VCalendar/util/events.mjs.map +1 -1
  118. package/lib/components/VCalendar/util/parser.mjs +3 -4
  119. package/lib/components/VCalendar/util/parser.mjs.map +1 -1
  120. package/lib/components/VCalendar/util/props.mjs +0 -13
  121. package/lib/components/VCalendar/util/props.mjs.map +1 -1
  122. package/lib/components/VCalendar/util/timestamp.mjs +2 -64
  123. package/lib/components/VCalendar/util/timestamp.mjs.map +1 -1
  124. package/lib/components/VCard/VCard.mjs +3 -8
  125. package/lib/components/VCard/VCard.mjs.map +1 -1
  126. package/lib/components/VCard/VCardActions.mjs +0 -4
  127. package/lib/components/VCard/VCardActions.mjs.map +1 -1
  128. package/lib/components/VCard/VCardItem.mjs +0 -5
  129. package/lib/components/VCard/VCardItem.mjs.map +1 -1
  130. package/lib/components/VCard/VCardSubtitle.mjs.map +1 -1
  131. package/lib/components/VCard/VCardText.mjs.map +1 -1
  132. package/lib/components/VCard/VCardTitle.mjs.map +1 -1
  133. package/lib/components/VCard/index.d.ts +13 -6
  134. package/lib/components/VCard/index.mjs.map +1 -1
  135. package/lib/components/VCarousel/VCarousel.mjs +5 -9
  136. package/lib/components/VCarousel/VCarousel.mjs.map +1 -1
  137. package/lib/components/VCarousel/VCarouselItem.mjs +0 -3
  138. package/lib/components/VCarousel/VCarouselItem.mjs.map +1 -1
  139. package/lib/components/VCarousel/index.d.ts +1 -0
  140. package/lib/components/VCarousel/index.mjs.map +1 -1
  141. package/lib/components/VCheckbox/VCheckbox.mjs +6 -6
  142. package/lib/components/VCheckbox/VCheckbox.mjs.map +1 -1
  143. package/lib/components/VCheckbox/VCheckboxBtn.mjs +7 -15
  144. package/lib/components/VCheckbox/VCheckboxBtn.mjs.map +1 -1
  145. package/lib/components/VCheckbox/index.d.ts +24 -22
  146. package/lib/components/VCheckbox/index.mjs.map +1 -1
  147. package/lib/components/VChip/VChip.css +25 -0
  148. package/lib/components/VChip/VChip.mjs +2 -10
  149. package/lib/components/VChip/VChip.mjs.map +1 -1
  150. package/lib/components/VChip/VChip.sass +1 -0
  151. package/lib/components/VChip/index.d.ts +5 -3
  152. package/lib/components/VChip/index.mjs.map +1 -1
  153. package/lib/components/VChipGroup/VChipGroup.mjs +5 -6
  154. package/lib/components/VChipGroup/VChipGroup.mjs.map +1 -1
  155. package/lib/components/VChipGroup/index.mjs.map +1 -1
  156. package/lib/components/VCode/index.d.ts +1 -0
  157. package/lib/components/VCode/index.mjs.map +1 -1
  158. package/lib/components/VColorPicker/VColorPicker.mjs +9 -12
  159. package/lib/components/VColorPicker/VColorPicker.mjs.map +1 -1
  160. package/lib/components/VColorPicker/VColorPickerCanvas.mjs +5 -20
  161. package/lib/components/VColorPicker/VColorPickerCanvas.mjs.map +1 -1
  162. package/lib/components/VColorPicker/VColorPickerEdit.mjs +6 -10
  163. package/lib/components/VColorPicker/VColorPickerEdit.mjs.map +1 -1
  164. package/lib/components/VColorPicker/VColorPickerPreview.mjs +6 -8
  165. package/lib/components/VColorPicker/VColorPickerPreview.mjs.map +1 -1
  166. package/lib/components/VColorPicker/VColorPickerSwatches.mjs +2 -6
  167. package/lib/components/VColorPicker/VColorPickerSwatches.mjs.map +1 -1
  168. package/lib/components/VColorPicker/index.mjs.map +1 -1
  169. package/lib/components/VColorPicker/util/index.mjs +24 -26
  170. package/lib/components/VColorPicker/util/index.mjs.map +1 -1
  171. package/lib/components/VCombobox/VCombobox.css +13 -0
  172. package/lib/components/VCombobox/VCombobox.mjs +23 -50
  173. package/lib/components/VCombobox/VCombobox.mjs.map +1 -1
  174. package/lib/components/VCombobox/VCombobox.sass +5 -0
  175. package/lib/components/VCombobox/_variables.scss +1 -0
  176. package/lib/components/VCombobox/index.d.ts +275 -384
  177. package/lib/components/VCombobox/index.mjs.map +1 -1
  178. package/lib/components/VCounter/VCounter.mjs +2 -5
  179. package/lib/components/VCounter/VCounter.mjs.map +1 -1
  180. package/lib/components/VCounter/index.d.ts +1 -0
  181. package/lib/components/VCounter/index.mjs.map +1 -1
  182. package/lib/components/VData/VData.mjs +9 -67
  183. package/lib/components/VData/VData.mjs.map +1 -1
  184. package/lib/components/VData/index.mjs.map +1 -1
  185. package/lib/components/VDataIterator/VDataFooter.mjs +6 -25
  186. package/lib/components/VDataIterator/VDataFooter.mjs.map +1 -1
  187. package/lib/components/VDataIterator/VDataIterator.mjs +12 -51
  188. package/lib/components/VDataIterator/VDataIterator.mjs.map +1 -1
  189. package/lib/components/VDataIterator/index.mjs.map +1 -1
  190. package/lib/components/VDataTable/MobileRow.mjs +3 -8
  191. package/lib/components/VDataTable/MobileRow.mjs.map +1 -1
  192. package/lib/components/VDataTable/Row.mjs +1 -8
  193. package/lib/components/VDataTable/Row.mjs.map +1 -1
  194. package/lib/components/VDataTable/RowGroup.mjs +1 -7
  195. package/lib/components/VDataTable/RowGroup.mjs.map +1 -1
  196. package/lib/components/VDataTable/VDataTable.mjs +42 -90
  197. package/lib/components/VDataTable/VDataTable.mjs.map +1 -1
  198. package/lib/components/VDataTable/VDataTableHeader.mjs +6 -10
  199. package/lib/components/VDataTable/VDataTableHeader.mjs.map +1 -1
  200. package/lib/components/VDataTable/VDataTableHeaderDesktop.mjs +0 -18
  201. package/lib/components/VDataTable/VDataTableHeaderDesktop.mjs.map +1 -1
  202. package/lib/components/VDataTable/VDataTableHeaderMobile.mjs +0 -9
  203. package/lib/components/VDataTable/VDataTableHeaderMobile.mjs.map +1 -1
  204. package/lib/components/VDataTable/VEditDialog.mjs +3 -17
  205. package/lib/components/VDataTable/VEditDialog.mjs.map +1 -1
  206. package/lib/components/VDataTable/VVirtualTable.mjs +3 -28
  207. package/lib/components/VDataTable/VVirtualTable.mjs.map +1 -1
  208. package/lib/components/VDataTable/index.mjs +0 -1
  209. package/lib/components/VDataTable/index.mjs.map +1 -1
  210. package/lib/components/VDataTable/mixins/header.mjs +0 -5
  211. package/lib/components/VDataTable/mixins/header.mjs.map +1 -1
  212. package/lib/components/VDatePicker/VDatePicker.mjs +2 -69
  213. package/lib/components/VDatePicker/VDatePicker.mjs.map +1 -1
  214. package/lib/components/VDatePicker/VDatePickerDateTable.mjs +1 -29
  215. package/lib/components/VDatePicker/VDatePickerDateTable.mjs.map +1 -1
  216. package/lib/components/VDatePicker/VDatePickerHeader.mjs +4 -17
  217. package/lib/components/VDatePicker/VDatePickerHeader.mjs.map +1 -1
  218. package/lib/components/VDatePicker/VDatePickerMonthTable.mjs +1 -12
  219. package/lib/components/VDatePicker/VDatePickerMonthTable.mjs.map +1 -1
  220. package/lib/components/VDatePicker/VDatePickerTitle.mjs +4 -15
  221. package/lib/components/VDatePicker/VDatePickerTitle.mjs.map +1 -1
  222. package/lib/components/VDatePicker/VDatePickerYears.mjs +4 -18
  223. package/lib/components/VDatePicker/VDatePickerYears.mjs.map +1 -1
  224. package/lib/components/VDatePicker/index.mjs.map +1 -1
  225. package/lib/components/VDatePicker/mixins/date-picker-table.mjs +6 -33
  226. package/lib/components/VDatePicker/mixins/date-picker-table.mjs.map +1 -1
  227. package/lib/components/VDatePicker/util/createNativeLocaleFormatter.mjs +0 -5
  228. package/lib/components/VDatePicker/util/createNativeLocaleFormatter.mjs.map +1 -1
  229. package/lib/components/VDatePicker/util/eventHelpers.mjs +2 -3
  230. package/lib/components/VDatePicker/util/eventHelpers.mjs.map +1 -1
  231. package/lib/components/VDatePicker/util/index.mjs +0 -1
  232. package/lib/components/VDatePicker/util/index.mjs.map +1 -1
  233. package/lib/components/VDatePicker/util/isDateAllowed.mjs +1 -1
  234. package/lib/components/VDatePicker/util/isDateAllowed.mjs.map +1 -1
  235. package/lib/components/VDatePicker/util/monthChange.mjs +0 -3
  236. package/lib/components/VDatePicker/util/monthChange.mjs.map +1 -1
  237. package/lib/components/VDatePicker/util/pad.mjs +1 -6
  238. package/lib/components/VDatePicker/util/pad.mjs.map +1 -1
  239. package/lib/components/VDatePicker/util/sanitizeDateString.mjs.map +1 -1
  240. package/lib/components/VDefaultsProvider/VDefaultsProvider.mjs +2 -4
  241. package/lib/components/VDefaultsProvider/VDefaultsProvider.mjs.map +1 -1
  242. package/lib/components/VDefaultsProvider/index.d.ts +1 -0
  243. package/lib/components/VDefaultsProvider/index.mjs.map +1 -1
  244. package/lib/components/VDialog/VDialog.mjs +7 -20
  245. package/lib/components/VDialog/VDialog.mjs.map +1 -1
  246. package/lib/components/VDialog/index.d.ts +1208 -188
  247. package/lib/components/VDialog/index.mjs.map +1 -1
  248. package/lib/components/VDivider/VDivider.mjs +2 -8
  249. package/lib/components/VDivider/VDivider.mjs.map +1 -1
  250. package/lib/components/VDivider/index.d.ts +1 -0
  251. package/lib/components/VDivider/index.mjs.map +1 -1
  252. package/lib/components/VExpansionPanel/VExpansionPanel.mjs +0 -5
  253. package/lib/components/VExpansionPanel/VExpansionPanel.mjs.map +1 -1
  254. package/lib/components/VExpansionPanel/VExpansionPanelText.mjs +2 -6
  255. package/lib/components/VExpansionPanel/VExpansionPanelText.mjs.map +1 -1
  256. package/lib/components/VExpansionPanel/VExpansionPanelTitle.mjs +3 -8
  257. package/lib/components/VExpansionPanel/VExpansionPanelTitle.mjs.map +1 -1
  258. package/lib/components/VExpansionPanel/VExpansionPanels.mjs +2 -5
  259. package/lib/components/VExpansionPanel/VExpansionPanels.mjs.map +1 -1
  260. package/lib/components/VExpansionPanel/index.mjs.map +1 -1
  261. package/lib/components/VField/VField.css +1 -1
  262. package/lib/components/VField/VField.mjs +4 -11
  263. package/lib/components/VField/VField.mjs.map +1 -1
  264. package/lib/components/VField/VField.sass +0 -1
  265. package/lib/components/VField/VFieldLabel.mjs +0 -3
  266. package/lib/components/VField/VFieldLabel.mjs.map +1 -1
  267. package/lib/components/VField/index.d.ts +33 -59
  268. package/lib/components/VField/index.mjs.map +1 -1
  269. package/lib/components/VFileInput/VFileInput.css +16 -0
  270. package/lib/components/VFileInput/VFileInput.mjs +6 -20
  271. package/lib/components/VFileInput/VFileInput.mjs.map +1 -1
  272. package/lib/components/VFileInput/VFileInput.sass +10 -0
  273. package/lib/components/VFileInput/_variables.scss +2 -0
  274. package/lib/components/VFileInput/index.d.ts +233 -5
  275. package/lib/components/VFileInput/index.mjs.map +1 -1
  276. package/lib/components/VFooter/VFooter.mjs +2 -4
  277. package/lib/components/VFooter/VFooter.mjs.map +1 -1
  278. package/lib/components/VFooter/index.d.ts +1 -0
  279. package/lib/components/VFooter/index.mjs.map +1 -1
  280. package/lib/components/VForm/VForm.mjs +2 -13
  281. package/lib/components/VForm/VForm.mjs.map +1 -1
  282. package/lib/components/VForm/index.d.ts +1 -1
  283. package/lib/components/VForm/index.mjs.map +1 -1
  284. package/lib/components/VGrid/VCol.mjs +8 -23
  285. package/lib/components/VGrid/VCol.mjs.map +1 -1
  286. package/lib/components/VGrid/VContainer.mjs +2 -4
  287. package/lib/components/VGrid/VContainer.mjs.map +1 -1
  288. package/lib/components/VGrid/VRow.mjs +6 -24
  289. package/lib/components/VGrid/VRow.mjs.map +1 -1
  290. package/lib/components/VGrid/VSpacer.mjs.map +1 -1
  291. package/lib/components/VGrid/index.d.ts +2 -0
  292. package/lib/components/VGrid/index.mjs.map +1 -1
  293. package/lib/components/VHover/VHover.mjs +0 -4
  294. package/lib/components/VHover/VHover.mjs.map +1 -1
  295. package/lib/components/VHover/index.d.ts +1 -0
  296. package/lib/components/VHover/index.mjs.map +1 -1
  297. package/lib/components/VIcon/VIcon.mjs +2 -8
  298. package/lib/components/VIcon/VIcon.mjs.map +1 -1
  299. package/lib/components/VIcon/index.d.ts +1 -0
  300. package/lib/components/VIcon/index.mjs.map +1 -1
  301. package/lib/components/VImg/VImg.mjs +9 -35
  302. package/lib/components/VImg/VImg.mjs.map +1 -1
  303. package/lib/components/VImg/index.d.ts +8 -4
  304. package/lib/components/VImg/index.mjs.map +1 -1
  305. package/lib/components/VInput/InputIcon.mjs +0 -2
  306. package/lib/components/VInput/InputIcon.mjs.map +1 -1
  307. package/lib/components/VInput/VInput.mjs +5 -9
  308. package/lib/components/VInput/VInput.mjs.map +1 -1
  309. package/lib/components/VInput/index.d.ts +29 -45
  310. package/lib/components/VInput/index.mjs.map +1 -1
  311. package/lib/components/VItemGroup/VItem.mjs +0 -5
  312. package/lib/components/VItemGroup/VItem.mjs.map +1 -1
  313. package/lib/components/VItemGroup/VItemGroup.mjs +4 -6
  314. package/lib/components/VItemGroup/VItemGroup.mjs.map +1 -1
  315. package/lib/components/VItemGroup/index.d.ts +19 -25
  316. package/lib/components/VItemGroup/index.mjs.map +1 -1
  317. package/lib/components/VKbd/index.d.ts +1 -0
  318. package/lib/components/VKbd/index.mjs.map +1 -1
  319. package/lib/components/VLabel/VLabel.mjs +2 -5
  320. package/lib/components/VLabel/VLabel.mjs.map +1 -1
  321. package/lib/components/VLabel/index.mjs.map +1 -1
  322. package/lib/components/VLayout/VLayout.mjs +2 -5
  323. package/lib/components/VLayout/VLayout.mjs.map +1 -1
  324. package/lib/components/VLayout/VLayoutItem.mjs +2 -6
  325. package/lib/components/VLayout/VLayoutItem.mjs.map +1 -1
  326. package/lib/components/VLayout/index.d.ts +5 -2
  327. package/lib/components/VLayout/index.mjs.map +1 -1
  328. package/lib/components/VLazy/VLazy.mjs +0 -8
  329. package/lib/components/VLazy/VLazy.mjs.map +1 -1
  330. package/lib/components/VLazy/index.d.ts +1 -0
  331. package/lib/components/VLazy/index.mjs.map +1 -1
  332. package/lib/components/VList/VList.mjs +2 -11
  333. package/lib/components/VList/VList.mjs.map +1 -1
  334. package/lib/components/VList/VListChildren.mjs +12 -21
  335. package/lib/components/VList/VListChildren.mjs.map +1 -1
  336. package/lib/components/VList/VListGroup.mjs +1 -12
  337. package/lib/components/VList/VListGroup.mjs.map +1 -1
  338. package/lib/components/VList/VListImg.mjs.map +1 -1
  339. package/lib/components/VList/VListItem.mjs +2 -12
  340. package/lib/components/VList/VListItem.mjs.map +1 -1
  341. package/lib/components/VList/VListItemAction.mjs +0 -3
  342. package/lib/components/VList/VListItemAction.mjs.map +1 -1
  343. package/lib/components/VList/VListItemMedia.mjs +0 -3
  344. package/lib/components/VList/VListItemMedia.mjs.map +1 -1
  345. package/lib/components/VList/VListItemSubtitle.mjs.map +1 -1
  346. package/lib/components/VList/VListItemTitle.mjs.map +1 -1
  347. package/lib/components/VList/VListSubheader.mjs +0 -4
  348. package/lib/components/VList/VListSubheader.mjs.map +1 -1
  349. package/lib/components/VList/index.d.ts +147 -170
  350. package/lib/components/VList/index.mjs.map +1 -1
  351. package/lib/components/VList/list.mjs +5 -2
  352. package/lib/components/VList/list.mjs.map +1 -1
  353. package/lib/components/VLocaleProvider/VLocaleProvider.mjs +4 -9
  354. package/lib/components/VLocaleProvider/VLocaleProvider.mjs.map +1 -1
  355. package/lib/components/VLocaleProvider/index.d.ts +1 -0
  356. package/lib/components/VLocaleProvider/index.mjs.map +1 -1
  357. package/lib/components/VMain/VMain.mjs +2 -5
  358. package/lib/components/VMain/VMain.mjs.map +1 -1
  359. package/lib/components/VMain/index.d.ts +1 -0
  360. package/lib/components/VMain/index.mjs.map +1 -1
  361. package/lib/components/VMenu/VMenu.mjs +3 -14
  362. package/lib/components/VMenu/VMenu.mjs.map +1 -1
  363. package/lib/components/VMenu/index.d.ts +1203 -183
  364. package/lib/components/VMenu/index.mjs.map +1 -1
  365. package/lib/components/VMenu/shared.mjs.map +1 -1
  366. package/lib/components/VMessages/VMessages.mjs +2 -6
  367. package/lib/components/VMessages/VMessages.mjs.map +1 -1
  368. package/lib/components/VMessages/index.d.ts +1 -0
  369. package/lib/components/VMessages/index.mjs.map +1 -1
  370. package/lib/components/VNavigationDrawer/VNavigationDrawer.mjs +6 -11
  371. package/lib/components/VNavigationDrawer/VNavigationDrawer.mjs.map +1 -1
  372. package/lib/components/VNavigationDrawer/index.mjs.map +1 -1
  373. package/lib/components/VNavigationDrawer/sticky.mjs +0 -4
  374. package/lib/components/VNavigationDrawer/sticky.mjs.map +1 -1
  375. package/lib/components/VNavigationDrawer/touch.mjs +2 -15
  376. package/lib/components/VNavigationDrawer/touch.mjs.map +1 -1
  377. package/lib/components/VNoSsr/VNoSsr.mjs +0 -4
  378. package/lib/components/VNoSsr/VNoSsr.mjs.map +1 -1
  379. package/lib/components/VNoSsr/index.d.ts +1 -0
  380. package/lib/components/VNoSsr/index.mjs.map +1 -1
  381. package/lib/components/VOtpInput/VOtpInput.mjs +7 -58
  382. package/lib/components/VOtpInput/VOtpInput.mjs.map +1 -1
  383. package/lib/components/VOtpInput/index.mjs.map +1 -1
  384. package/lib/components/VOverflowBtn/VOverflowBtn.mjs +7 -19
  385. package/lib/components/VOverflowBtn/VOverflowBtn.mjs.map +1 -1
  386. package/lib/components/VOverflowBtn/index.mjs.map +1 -1
  387. package/lib/components/VOverlay/VOverlay.mjs +8 -17
  388. package/lib/components/VOverlay/VOverlay.mjs.map +1 -1
  389. package/lib/components/VOverlay/index.d.ts +32 -60
  390. package/lib/components/VOverlay/index.mjs.map +1 -1
  391. package/lib/components/VOverlay/locationStrategies.mjs +23 -56
  392. package/lib/components/VOverlay/locationStrategies.mjs.map +1 -1
  393. package/lib/components/VOverlay/requestNewFrame.mjs +1 -2
  394. package/lib/components/VOverlay/requestNewFrame.mjs.map +1 -1
  395. package/lib/components/VOverlay/scrollStrategies.mjs +2 -18
  396. package/lib/components/VOverlay/scrollStrategies.mjs.map +1 -1
  397. package/lib/components/VOverlay/useActivator.mjs +6 -32
  398. package/lib/components/VOverlay/useActivator.mjs.map +1 -1
  399. package/lib/components/VOverlay/util/point.mjs +3 -4
  400. package/lib/components/VOverlay/util/point.mjs.map +1 -1
  401. package/lib/components/VPagination/VPagination.mjs +11 -23
  402. package/lib/components/VPagination/VPagination.mjs.map +1 -1
  403. package/lib/components/VPagination/index.d.ts +5 -3
  404. package/lib/components/VPagination/index.mjs.map +1 -1
  405. package/lib/components/VParallax/VParallax.mjs +6 -12
  406. package/lib/components/VParallax/VParallax.mjs.map +1 -1
  407. package/lib/components/VParallax/index.mjs.map +1 -1
  408. package/lib/components/VPicker/VPicker.mjs +3 -12
  409. package/lib/components/VPicker/VPicker.mjs.map +1 -1
  410. package/lib/components/VPicker/index.mjs.map +1 -1
  411. package/lib/components/VProgressCircular/VProgressCircular.mjs +2 -5
  412. package/lib/components/VProgressCircular/VProgressCircular.mjs.map +1 -1
  413. package/lib/components/VProgressCircular/index.d.ts +1 -0
  414. package/lib/components/VProgressCircular/index.mjs.map +1 -1
  415. package/lib/components/VProgressLinear/VProgressLinear.mjs +5 -8
  416. package/lib/components/VProgressLinear/VProgressLinear.mjs.map +1 -1
  417. package/lib/components/VProgressLinear/index.d.ts +1 -0
  418. package/lib/components/VProgressLinear/index.mjs.map +1 -1
  419. package/lib/components/VRadio/VRadio.mjs +2 -4
  420. package/lib/components/VRadio/VRadio.mjs.map +1 -1
  421. package/lib/components/VRadio/index.d.ts +13 -11
  422. package/lib/components/VRadio/index.mjs.map +1 -1
  423. package/lib/components/VRadioGroup/VRadioGroup.mjs +15 -20
  424. package/lib/components/VRadioGroup/VRadioGroup.mjs.map +1 -1
  425. package/lib/components/VRadioGroup/index.d.ts +26 -38
  426. package/lib/components/VRadioGroup/index.mjs.map +1 -1
  427. package/lib/components/VRangeSlider/VRangeSlider.mjs +13 -26
  428. package/lib/components/VRangeSlider/VRangeSlider.mjs.map +1 -1
  429. package/lib/components/VRangeSlider/index.d.ts +5 -3
  430. package/lib/components/VRangeSlider/index.mjs.map +1 -1
  431. package/lib/components/VRating/VRating.mjs +4 -22
  432. package/lib/components/VRating/VRating.mjs.map +1 -1
  433. package/lib/components/VRating/index.d.ts +32 -40
  434. package/lib/components/VRating/index.mjs.map +1 -1
  435. package/lib/components/VResponsive/VResponsive.mjs +2 -5
  436. package/lib/components/VResponsive/VResponsive.mjs.map +1 -1
  437. package/lib/components/VResponsive/index.d.ts +1 -0
  438. package/lib/components/VResponsive/index.mjs.map +1 -1
  439. package/lib/components/VSelect/VSelect.css +13 -0
  440. package/lib/components/VSelect/VSelect.mjs +9 -22
  441. package/lib/components/VSelect/VSelect.mjs.map +1 -1
  442. package/lib/components/VSelect/VSelect.sass +6 -0
  443. package/lib/components/VSelect/_variables.scss +1 -0
  444. package/lib/components/VSelect/index.d.ts +4264 -776
  445. package/lib/components/VSelect/index.mjs.map +1 -1
  446. package/lib/components/VSelectionControl/VSelectionControl.mjs +14 -58
  447. package/lib/components/VSelectionControl/VSelectionControl.mjs.map +1 -1
  448. package/lib/components/VSelectionControl/index.d.ts +62 -78
  449. package/lib/components/VSelectionControl/index.mjs.map +1 -1
  450. package/lib/components/VSelectionControlGroup/VSelectionControlGroup.css +1 -0
  451. package/lib/components/VSelectionControlGroup/VSelectionControlGroup.mjs +56 -28
  452. package/lib/components/VSelectionControlGroup/VSelectionControlGroup.mjs.map +1 -1
  453. package/lib/components/VSelectionControlGroup/VSelectionControlGroup.sass +1 -0
  454. package/lib/components/VSelectionControlGroup/index.d.ts +53 -4
  455. package/lib/components/VSelectionControlGroup/index.mjs.map +1 -1
  456. package/lib/components/VSheet/VSheet.mjs +2 -4
  457. package/lib/components/VSheet/VSheet.mjs.map +1 -1
  458. package/lib/components/VSheet/index.d.ts +1 -0
  459. package/lib/components/VSheet/index.mjs.map +1 -1
  460. package/lib/components/VSkeletonLoader/VSkeletonLoader.mjs +19 -32
  461. package/lib/components/VSkeletonLoader/VSkeletonLoader.mjs.map +1 -1
  462. package/lib/components/VSkeletonLoader/index.mjs.map +1 -1
  463. package/lib/components/VSlideGroup/VSlideGroup.mjs +16 -47
  464. package/lib/components/VSlideGroup/VSlideGroup.mjs.map +1 -1
  465. package/lib/components/VSlideGroup/VSlideGroupItem.mjs +5 -9
  466. package/lib/components/VSlideGroup/VSlideGroupItem.mjs.map +1 -1
  467. package/lib/components/VSlideGroup/helpers.mjs +0 -2
  468. package/lib/components/VSlideGroup/helpers.mjs.map +1 -1
  469. package/lib/components/VSlideGroup/index.d.ts +342 -59
  470. package/lib/components/VSlideGroup/index.mjs.map +1 -1
  471. package/lib/components/VSlider/VSlider.mjs +6 -9
  472. package/lib/components/VSlider/VSlider.mjs.map +1 -1
  473. package/lib/components/VSlider/VSliderThumb.mjs +4 -15
  474. package/lib/components/VSlider/VSliderThumb.mjs.map +1 -1
  475. package/lib/components/VSlider/VSliderTrack.mjs +6 -8
  476. package/lib/components/VSlider/VSliderTrack.mjs.map +1 -1
  477. package/lib/components/VSlider/index.d.ts +5 -3
  478. package/lib/components/VSlider/index.mjs.map +1 -1
  479. package/lib/components/VSlider/slider.mjs +6 -27
  480. package/lib/components/VSlider/slider.mjs.map +1 -1
  481. package/lib/components/VSnackbar/VSnackbar.mjs +3 -10
  482. package/lib/components/VSnackbar/VSnackbar.mjs.map +1 -1
  483. package/lib/components/VSnackbar/index.d.ts +1215 -191
  484. package/lib/components/VSnackbar/index.mjs.map +1 -1
  485. package/lib/components/VSparkline/VSparkline.mjs +5 -40
  486. package/lib/components/VSparkline/VSparkline.mjs.map +1 -1
  487. package/lib/components/VSparkline/helpers/core.mjs +1 -1
  488. package/lib/components/VSparkline/helpers/core.mjs.map +1 -1
  489. package/lib/components/VSparkline/helpers/math.mjs +2 -3
  490. package/lib/components/VSparkline/helpers/math.mjs.map +1 -1
  491. package/lib/components/VSparkline/helpers/path.mjs +0 -4
  492. package/lib/components/VSparkline/helpers/path.mjs.map +1 -1
  493. package/lib/components/VSparkline/index.mjs.map +1 -1
  494. package/lib/components/VSpeedDial/VSpeedDial.mjs +3 -12
  495. package/lib/components/VSpeedDial/VSpeedDial.mjs.map +1 -1
  496. package/lib/components/VSpeedDial/index.mjs.map +1 -1
  497. package/lib/components/VStepper/VStepper.mjs +5 -24
  498. package/lib/components/VStepper/VStepper.mjs.map +1 -1
  499. package/lib/components/VStepper/VStepperContent.mjs +4 -25
  500. package/lib/components/VStepper/VStepperContent.mjs.map +1 -1
  501. package/lib/components/VStepper/VStepperStep.mjs +0 -24
  502. package/lib/components/VStepper/VStepperStep.mjs.map +1 -1
  503. package/lib/components/VStepper/index.mjs.map +1 -1
  504. package/lib/components/VSwitch/VSwitch.mjs +14 -15
  505. package/lib/components/VSwitch/VSwitch.mjs.map +1 -1
  506. package/lib/components/VSwitch/index.d.ts +15 -11
  507. package/lib/components/VSwitch/index.mjs.map +1 -1
  508. package/lib/components/VSystemBar/VSystemBar.mjs +2 -4
  509. package/lib/components/VSystemBar/VSystemBar.mjs.map +1 -1
  510. package/lib/components/VSystemBar/index.d.ts +1 -0
  511. package/lib/components/VSystemBar/index.mjs.map +1 -1
  512. package/lib/components/VTable/VTable.css +3 -3
  513. package/lib/components/VTable/VTable.mjs +5 -6
  514. package/lib/components/VTable/VTable.mjs.map +1 -1
  515. package/lib/components/VTable/VTable.sass +9 -3
  516. package/lib/components/VTable/index.d.ts +8 -3
  517. package/lib/components/VTable/index.mjs.map +1 -1
  518. package/lib/components/VTabs/VTab.mjs +2 -10
  519. package/lib/components/VTabs/VTab.mjs.map +1 -1
  520. package/lib/components/VTabs/VTabs.css +5 -5
  521. package/lib/components/VTabs/VTabs.mjs +12 -17
  522. package/lib/components/VTabs/VTabs.mjs.map +1 -1
  523. package/lib/components/VTabs/VTabs.sass +4 -4
  524. package/lib/components/VTabs/_variables.scss +1 -1
  525. package/lib/components/VTabs/index.d.ts +23 -15
  526. package/lib/components/VTabs/index.mjs.map +1 -1
  527. package/lib/components/VTabs/shared.mjs.map +1 -1
  528. package/lib/components/VTextField/VTextField.mjs +13 -24
  529. package/lib/components/VTextField/VTextField.mjs.map +1 -1
  530. package/lib/components/VTextField/index.d.ts +1375 -191
  531. package/lib/components/VTextField/index.mjs.map +1 -1
  532. package/lib/components/VTextarea/VTextarea.mjs +6 -24
  533. package/lib/components/VTextarea/VTextarea.mjs.map +1 -1
  534. package/lib/components/VTextarea/index.d.ts +233 -5
  535. package/lib/components/VTextarea/index.mjs.map +1 -1
  536. package/lib/components/VThemeProvider/VThemeProvider.mjs +2 -5
  537. package/lib/components/VThemeProvider/VThemeProvider.mjs.map +1 -1
  538. package/lib/components/VThemeProvider/index.d.ts +1 -0
  539. package/lib/components/VThemeProvider/index.mjs.map +1 -1
  540. package/lib/components/VTimePicker/SelectingTimes.mjs +0 -3
  541. package/lib/components/VTimePicker/SelectingTimes.mjs.map +1 -1
  542. package/lib/components/VTimePicker/VTimePicker.mjs +3 -53
  543. package/lib/components/VTimePicker/VTimePicker.mjs.map +1 -1
  544. package/lib/components/VTimePicker/VTimePickerClock.mjs +6 -42
  545. package/lib/components/VTimePicker/VTimePickerClock.mjs.map +1 -1
  546. package/lib/components/VTimePicker/VTimePickerTitle.mjs +4 -13
  547. package/lib/components/VTimePicker/VTimePickerTitle.mjs.map +1 -1
  548. package/lib/components/VTimePicker/index.mjs.map +1 -1
  549. package/lib/components/VTimeline/VTimeline.mjs +2 -9
  550. package/lib/components/VTimeline/VTimeline.mjs.map +1 -1
  551. package/lib/components/VTimeline/VTimelineDivider.mjs +0 -5
  552. package/lib/components/VTimeline/VTimelineDivider.mjs.map +1 -1
  553. package/lib/components/VTimeline/VTimelineItem.mjs +0 -6
  554. package/lib/components/VTimeline/VTimelineItem.mjs.map +1 -1
  555. package/lib/components/VTimeline/index.d.ts +7 -3
  556. package/lib/components/VTimeline/index.mjs.map +1 -1
  557. package/lib/components/VToolbar/VToolbar.mjs +2 -8
  558. package/lib/components/VToolbar/VToolbar.mjs.map +1 -1
  559. package/lib/components/VToolbar/VToolbarItems.mjs +0 -4
  560. package/lib/components/VToolbar/VToolbarItems.mjs.map +1 -1
  561. package/lib/components/VToolbar/VToolbarTitle.mjs +0 -5
  562. package/lib/components/VToolbar/VToolbarTitle.mjs.map +1 -1
  563. package/lib/components/VToolbar/index.d.ts +34 -71
  564. package/lib/components/VToolbar/index.mjs.map +1 -1
  565. package/lib/components/VTooltip/VTooltip.mjs +2 -8
  566. package/lib/components/VTooltip/VTooltip.mjs.map +1 -1
  567. package/lib/components/VTooltip/index.d.ts +1196 -176
  568. package/lib/components/VTooltip/index.mjs.map +1 -1
  569. package/lib/components/VTreeview/VTreeview.mjs +17 -72
  570. package/lib/components/VTreeview/VTreeview.mjs.map +1 -1
  571. package/lib/components/VTreeview/VTreeviewNode.mjs +2 -32
  572. package/lib/components/VTreeview/VTreeviewNode.mjs.map +1 -1
  573. package/lib/components/VTreeview/index.mjs.map +1 -1
  574. package/lib/components/VTreeview/util/filterTreeItems.mjs +0 -6
  575. package/lib/components/VTreeview/util/filterTreeItems.mjs.map +1 -1
  576. package/lib/components/VValidation/VValidation.mjs +2 -5
  577. package/lib/components/VValidation/VValidation.mjs.map +1 -1
  578. package/lib/components/VValidation/index.d.ts +1 -0
  579. package/lib/components/VValidation/index.mjs.map +1 -1
  580. package/lib/components/VVirtualScroll/VVirtualScroll.mjs +3 -18
  581. package/lib/components/VVirtualScroll/VVirtualScroll.mjs.map +1 -1
  582. package/lib/components/VVirtualScroll/index.mjs.map +1 -1
  583. package/lib/components/VWindow/VWindow.mjs +5 -15
  584. package/lib/components/VWindow/VWindow.mjs.map +1 -1
  585. package/lib/components/VWindow/VWindowItem.mjs +8 -21
  586. package/lib/components/VWindow/VWindowItem.mjs.map +1 -1
  587. package/lib/components/VWindow/index.d.ts +37 -87
  588. package/lib/components/VWindow/index.mjs.map +1 -1
  589. package/lib/components/index.d.ts +16084 -6799
  590. package/lib/components/index.mjs +0 -11
  591. package/lib/components/index.mjs.map +1 -1
  592. package/lib/components/transitions/createTransition.mjs +0 -10
  593. package/lib/components/transitions/createTransition.mjs.map +1 -1
  594. package/lib/components/transitions/dialog-transition.mjs +3 -18
  595. package/lib/components/transitions/dialog-transition.mjs.map +1 -1
  596. package/lib/components/transitions/expand-transition.mjs +2 -11
  597. package/lib/components/transitions/expand-transition.mjs.map +1 -1
  598. package/lib/components/transitions/index.d.ts +16 -0
  599. package/lib/components/transitions/index.mjs +5 -4
  600. package/lib/components/transitions/index.mjs.map +1 -1
  601. package/lib/composables/border.mjs +0 -3
  602. package/lib/composables/border.mjs.map +1 -1
  603. package/lib/composables/color.mjs +0 -4
  604. package/lib/composables/color.mjs.map +1 -1
  605. package/lib/composables/defaults.mjs +0 -5
  606. package/lib/composables/defaults.mjs.map +1 -1
  607. package/lib/composables/delay.mjs +0 -3
  608. package/lib/composables/delay.mjs.map +1 -1
  609. package/lib/composables/density.mjs +4 -1
  610. package/lib/composables/density.mjs.map +1 -1
  611. package/lib/composables/dimensions.mjs +0 -1
  612. package/lib/composables/dimensions.mjs.map +1 -1
  613. package/lib/composables/display.mjs +7 -20
  614. package/lib/composables/display.mjs.map +1 -1
  615. package/lib/composables/elevation.mjs +2 -4
  616. package/lib/composables/elevation.mjs.map +1 -1
  617. package/lib/composables/filter.mjs +7 -14
  618. package/lib/composables/filter.mjs.map +1 -1
  619. package/lib/composables/focus.mjs +0 -5
  620. package/lib/composables/focus.mjs.map +1 -1
  621. package/lib/composables/form.mjs +1 -14
  622. package/lib/composables/form.mjs.map +1 -1
  623. package/lib/composables/forwardRefs.mjs +9 -16
  624. package/lib/composables/forwardRefs.mjs.map +1 -1
  625. package/lib/composables/group.mjs +10 -33
  626. package/lib/composables/group.mjs.map +1 -1
  627. package/lib/composables/hydration.mjs +0 -1
  628. package/lib/composables/hydration.mjs.map +1 -1
  629. package/lib/composables/icons.mjs +4 -17
  630. package/lib/composables/icons.mjs.map +1 -1
  631. package/lib/composables/index.mjs +1 -2
  632. package/lib/composables/index.mjs.map +1 -1
  633. package/lib/composables/intersectionObserver.mjs +0 -3
  634. package/lib/composables/intersectionObserver.mjs.map +1 -1
  635. package/lib/composables/items.mjs +3 -15
  636. package/lib/composables/items.mjs.map +1 -1
  637. package/lib/composables/layout.mjs +29 -31
  638. package/lib/composables/layout.mjs.map +1 -1
  639. package/lib/composables/lazy.mjs +2 -3
  640. package/lib/composables/lazy.mjs.map +1 -1
  641. package/lib/composables/loader.mjs +0 -3
  642. package/lib/composables/loader.mjs.map +1 -1
  643. package/lib/composables/locale.mjs +46 -118
  644. package/lib/composables/locale.mjs.map +1 -1
  645. package/lib/composables/location.mjs +1 -8
  646. package/lib/composables/location.mjs.map +1 -1
  647. package/lib/composables/mutationObserver.mjs +3 -1
  648. package/lib/composables/mutationObserver.mjs.map +1 -1
  649. package/lib/composables/nested/nested.mjs +4 -20
  650. package/lib/composables/nested/nested.mjs.map +1 -1
  651. package/lib/composables/nested/openStrategies.mjs +0 -9
  652. package/lib/composables/nested/openStrategies.mjs.map +1 -1
  653. package/lib/composables/nested/selectStrategies.mjs +6 -21
  654. package/lib/composables/nested/selectStrategies.mjs.map +1 -1
  655. package/lib/composables/position.mjs +1 -4
  656. package/lib/composables/position.mjs.map +1 -1
  657. package/lib/composables/proxiedModel.mjs +3 -9
  658. package/lib/composables/proxiedModel.mjs.map +1 -1
  659. package/lib/composables/refs.mjs +0 -2
  660. package/lib/composables/refs.mjs.map +1 -1
  661. package/lib/composables/resizeObserver.mjs +0 -3
  662. package/lib/composables/resizeObserver.mjs.map +1 -1
  663. package/lib/composables/rounded.mjs +0 -3
  664. package/lib/composables/rounded.mjs.map +1 -1
  665. package/lib/composables/router.mjs +3 -11
  666. package/lib/composables/router.mjs.map +1 -1
  667. package/lib/composables/scopeId.mjs.map +1 -1
  668. package/lib/composables/scroll.mjs +3 -9
  669. package/lib/composables/scroll.mjs.map +1 -1
  670. package/lib/composables/selectLink.mjs +3 -2
  671. package/lib/composables/selectLink.mjs.map +1 -1
  672. package/lib/composables/size.mjs +0 -3
  673. package/lib/composables/size.mjs.map +1 -1
  674. package/lib/composables/ssrBoot.mjs +2 -1
  675. package/lib/composables/ssrBoot.mjs.map +1 -1
  676. package/lib/composables/stack.mjs +0 -6
  677. package/lib/composables/stack.mjs.map +1 -1
  678. package/lib/composables/tag.mjs +0 -1
  679. package/lib/composables/tag.mjs.map +1 -1
  680. package/lib/composables/teleport.mjs +0 -4
  681. package/lib/composables/teleport.mjs.map +1 -1
  682. package/lib/composables/theme.mjs +18 -38
  683. package/lib/composables/theme.mjs.map +1 -1
  684. package/lib/composables/toggleScope.mjs +0 -1
  685. package/lib/composables/toggleScope.mjs.map +1 -1
  686. package/lib/composables/touch.mjs +5 -28
  687. package/lib/composables/touch.mjs.map +1 -1
  688. package/lib/composables/transition.mjs +0 -2
  689. package/lib/composables/transition.mjs.map +1 -1
  690. package/lib/composables/validation.mjs +3 -13
  691. package/lib/composables/validation.mjs.map +1 -1
  692. package/lib/composables/variant.mjs +0 -2
  693. package/lib/composables/variant.mjs.map +1 -1
  694. package/lib/directives/click-outside/index.mjs +10 -22
  695. package/lib/directives/click-outside/index.mjs.map +1 -1
  696. package/lib/directives/color/index.mjs +0 -11
  697. package/lib/directives/color/index.mjs.map +1 -1
  698. package/lib/directives/index.d.ts +104 -13
  699. package/lib/directives/index.mjs +0 -1
  700. package/lib/directives/index.mjs.map +1 -1
  701. package/lib/directives/intersect/index.mjs +3 -10
  702. package/lib/directives/intersect/index.mjs.map +1 -1
  703. package/lib/directives/mutate/index.mjs +1 -5
  704. package/lib/directives/mutate/index.mjs.map +1 -1
  705. package/lib/directives/resize/index.mjs +0 -5
  706. package/lib/directives/resize/index.mjs.map +1 -1
  707. package/lib/directives/ripple/index.mjs +11 -63
  708. package/lib/directives/ripple/index.mjs.map +1 -1
  709. package/lib/directives/scroll/index.mjs +0 -4
  710. package/lib/directives/scroll/index.mjs.map +1 -1
  711. package/lib/directives/touch/index.mjs +0 -15
  712. package/lib/directives/touch/index.mjs.map +1 -1
  713. package/lib/entry-bundler.mjs +1 -1
  714. package/lib/entry-bundler.mjs.map +1 -1
  715. package/lib/framework.mjs +24 -22
  716. package/lib/framework.mjs.map +1 -1
  717. package/lib/iconsets/fa-svg.mjs +0 -1
  718. package/lib/iconsets/fa-svg.mjs.map +1 -1
  719. package/lib/iconsets/fa.mjs +0 -1
  720. package/lib/iconsets/fa.mjs.map +1 -1
  721. package/lib/iconsets/fa4.mjs +4 -3
  722. package/lib/iconsets/fa4.mjs.map +1 -1
  723. package/lib/iconsets/md.mjs +4 -3
  724. package/lib/iconsets/md.mjs.map +1 -1
  725. package/lib/iconsets/mdi-svg.mjs +0 -1
  726. package/lib/iconsets/mdi-svg.mjs.map +1 -1
  727. package/lib/iconsets/mdi.mjs +4 -3
  728. package/lib/iconsets/mdi.mjs.map +1 -1
  729. package/lib/index.d.ts +92 -106
  730. package/lib/locale/adapters/vue-i18n.d.ts +10 -16
  731. package/lib/locale/adapters/vue-i18n.mjs +59 -52
  732. package/lib/locale/adapters/vue-i18n.mjs.map +1 -1
  733. package/lib/locale/adapters/vuetify.d.ts +24 -0
  734. package/lib/locale/adapters/vuetify.mjs +97 -0
  735. package/lib/locale/adapters/vuetify.mjs.map +1 -0
  736. package/lib/locale/af.mjs.map +1 -1
  737. package/lib/locale/ar.mjs.map +1 -1
  738. package/lib/locale/az.mjs.map +1 -1
  739. package/lib/locale/bg.mjs.map +1 -1
  740. package/lib/locale/ca.mjs.map +1 -1
  741. package/lib/locale/ckb.mjs.map +1 -1
  742. package/lib/locale/cs.mjs.map +1 -1
  743. package/lib/locale/da.mjs.map +1 -1
  744. package/lib/locale/de.mjs.map +1 -1
  745. package/lib/locale/el.mjs.map +1 -1
  746. package/lib/locale/en.mjs.map +1 -1
  747. package/lib/locale/es.mjs.map +1 -1
  748. package/lib/locale/et.mjs.map +1 -1
  749. package/lib/locale/fa.mjs.map +1 -1
  750. package/lib/locale/fi.mjs.map +1 -1
  751. package/lib/locale/fr.mjs.map +1 -1
  752. package/lib/locale/he.mjs.map +1 -1
  753. package/lib/locale/hr.mjs.map +1 -1
  754. package/lib/locale/hu.mjs.map +1 -1
  755. package/lib/locale/id.mjs.map +1 -1
  756. package/lib/locale/index.d.ts +2 -2
  757. package/lib/locale/index.mjs +1 -1
  758. package/lib/locale/index.mjs.map +1 -1
  759. package/lib/locale/it.mjs.map +1 -1
  760. package/lib/locale/ja.mjs.map +1 -1
  761. package/lib/locale/ko.mjs.map +1 -1
  762. package/lib/locale/lt.mjs.map +1 -1
  763. package/lib/locale/lv.mjs.map +1 -1
  764. package/lib/locale/nl.mjs.map +1 -1
  765. package/lib/locale/no.mjs.map +1 -1
  766. package/lib/locale/pl.mjs +7 -7
  767. package/lib/locale/pl.mjs.map +1 -1
  768. package/lib/locale/pt.mjs.map +1 -1
  769. package/lib/locale/ro.mjs.map +1 -1
  770. package/lib/locale/ru.mjs.map +1 -1
  771. package/lib/locale/sk.mjs.map +1 -1
  772. package/lib/locale/sl.mjs.map +1 -1
  773. package/lib/locale/sr-Cyrl.mjs.map +1 -1
  774. package/lib/locale/sr-Latn.mjs.map +1 -1
  775. package/lib/locale/sv.mjs.map +1 -1
  776. package/lib/locale/th.mjs.map +1 -1
  777. package/lib/locale/tr.mjs.map +1 -1
  778. package/lib/locale/uk.mjs.map +1 -1
  779. package/lib/locale/vi.mjs.map +1 -1
  780. package/lib/locale/zh-Hans.mjs.map +1 -1
  781. package/lib/locale/zh-Hant.mjs.map +1 -1
  782. package/lib/services/goto/easing-patterns.mjs +24 -24
  783. package/lib/services/goto/easing-patterns.mjs.map +1 -1
  784. package/lib/services/goto/index.mjs +11 -15
  785. package/lib/services/goto/index.mjs.map +1 -1
  786. package/lib/services/goto/util.mjs +1 -8
  787. package/lib/services/goto/util.mjs.map +1 -1
  788. package/lib/styles/main.css +4 -0
  789. package/lib/styles/settings/_utilities.scss +7 -0
  790. package/lib/util/anchor.mjs +0 -3
  791. package/lib/util/anchor.mjs.map +1 -1
  792. package/lib/util/animation.mjs +0 -6
  793. package/lib/util/animation.mjs.map +1 -1
  794. package/lib/util/box.mjs +0 -5
  795. package/lib/util/box.mjs.map +1 -1
  796. package/lib/util/color/APCA.mjs +23 -21
  797. package/lib/util/color/APCA.mjs.map +1 -1
  798. package/lib/util/color/transformCIELAB.mjs +0 -2
  799. package/lib/util/color/transformCIELAB.mjs.map +1 -1
  800. package/lib/util/color/transformSRGB.mjs +14 -12
  801. package/lib/util/color/transformSRGB.mjs.map +1 -1
  802. package/lib/util/colorUtils.mjs +8 -25
  803. package/lib/util/colorUtils.mjs.map +1 -1
  804. package/lib/util/colors.mjs.map +1 -1
  805. package/lib/util/console.mjs +5 -14
  806. package/lib/util/console.mjs.map +1 -1
  807. package/lib/util/createSimpleFunctional.mjs +0 -3
  808. package/lib/util/createSimpleFunctional.mjs.map +1 -1
  809. package/lib/util/dateTimeUtils.mjs +0 -10
  810. package/lib/util/dateTimeUtils.mjs.map +1 -1
  811. package/lib/util/defineComponent.mjs +6 -22
  812. package/lib/util/defineComponent.mjs.map +1 -1
  813. package/lib/util/dom.mjs +4 -4
  814. package/lib/util/dom.mjs.map +1 -1
  815. package/lib/util/easing.mjs +0 -1
  816. package/lib/util/easing.mjs.map +1 -1
  817. package/lib/util/getCurrentInstance.mjs +1 -7
  818. package/lib/util/getCurrentInstance.mjs.map +1 -1
  819. package/lib/util/getScrollParent.mjs +0 -3
  820. package/lib/util/getScrollParent.mjs.map +1 -1
  821. package/lib/util/globals.mjs.map +1 -1
  822. package/lib/util/helpers.mjs +18 -75
  823. package/lib/util/helpers.mjs.map +1 -1
  824. package/lib/util/injectSelf.mjs +0 -1
  825. package/lib/util/injectSelf.mjs.map +1 -1
  826. package/lib/util/isFixedPosition.mjs +0 -2
  827. package/lib/util/isFixedPosition.mjs.map +1 -1
  828. package/lib/util/propsFactory.mjs +11 -5
  829. package/lib/util/propsFactory.mjs.map +1 -1
  830. package/lib/util/useRender.mjs +0 -1
  831. package/lib/util/useRender.mjs.map +1 -1
  832. package/package.json +6 -10
  833. package/dist/json/attributes.json +0 -5602
  834. package/dist/json/tags.json +0 -1945
  835. package/dist/json/web-types.json +0 -19006
  836. package/lib/composables/rtl.mjs +0 -42
  837. package/lib/composables/rtl.mjs.map +0 -1
  838. package/lib/locale/adapters/vue-intl.d.ts +0 -42
  839. package/lib/locale/adapters/vue-intl.mjs +0 -65
  840. package/lib/locale/adapters/vue-intl.mjs.map +0 -1
@@ -1,4 +1,5 @@
1
1
  /* eslint-disable sonarjs/no-identical-functions */
2
+
2
3
  export const independentSelectStrategy = mandatory => {
3
4
  const strategy = {
4
5
  select: _ref => {
@@ -7,7 +8,6 @@ export const independentSelectStrategy = mandatory => {
7
8
  value,
8
9
  selected
9
10
  } = _ref;
10
-
11
11
  // When mandatory and we're trying to deselect when id
12
12
  // is the only currently selected item then do nothing
13
13
  if (mandatory && !value) {
@@ -17,13 +17,11 @@ export const independentSelectStrategy = mandatory => {
17
17
  }, []);
18
18
  if (on.length === 1 && on[0] === id) return selected;
19
19
  }
20
-
21
20
  selected.set(id, value ? 'on' : 'off');
22
21
  return selected;
23
22
  },
24
23
  in: (v, children, parents) => {
25
24
  let map = new Map();
26
-
27
25
  for (const id of v || []) {
28
26
  map = strategy.select({
29
27
  id,
@@ -33,16 +31,13 @@ export const independentSelectStrategy = mandatory => {
33
31
  parents
34
32
  });
35
33
  }
36
-
37
34
  return map;
38
35
  },
39
36
  out: v => {
40
37
  const arr = [];
41
-
42
38
  for (const [key, value] of v.entries()) {
43
39
  if (value === 'on') arr.push(key);
44
40
  }
45
-
46
41
  return arr;
47
42
  }
48
43
  };
@@ -58,18 +53,17 @@ export const independentSingleSelectStrategy = mandatory => {
58
53
  ...rest
59
54
  } = _ref3;
60
55
  const singleSelected = selected.has(id) ? new Map([[id, selected.get(id)]]) : new Map();
61
- return parentStrategy.select({ ...rest,
56
+ return parentStrategy.select({
57
+ ...rest,
62
58
  id,
63
59
  selected: singleSelected
64
60
  });
65
61
  },
66
62
  in: (v, children, parents) => {
67
63
  let map = new Map();
68
-
69
64
  if (v != null && v.length) {
70
65
  map = parentStrategy.in(v.slice(0, 1), children, parents);
71
66
  }
72
-
73
67
  return map;
74
68
  },
75
69
  out: (v, children, parents) => {
@@ -136,28 +130,24 @@ export const classicSelectStrategy = mandatory => {
136
130
  } = _ref6;
137
131
  const original = new Map(selected);
138
132
  const items = [id];
139
-
140
133
  while (items.length) {
141
134
  const item = items.shift();
142
135
  selected.set(item, value ? 'on' : 'off');
143
-
144
136
  if (children.has(item)) {
145
137
  items.push(...children.get(item));
146
138
  }
147
139
  }
148
-
149
140
  let parent = parents.get(id);
150
-
151
141
  while (parent) {
152
142
  const childrenIds = children.get(parent);
153
143
  const everySelected = childrenIds.every(cid => selected.get(cid) === 'on');
154
144
  const noneSelected = childrenIds.every(cid => !selected.has(cid) || selected.get(cid) === 'off');
155
145
  selected.set(parent, everySelected ? 'on' : noneSelected ? 'off' : 'indeterminate');
156
146
  parent = parents.get(parent);
157
- } // If mandatory and planned deselect results in no selected
158
- // items then we can't do it, so return original state
159
-
147
+ }
160
148
 
149
+ // If mandatory and planned deselect results in no selected
150
+ // items then we can't do it, so return original state
161
151
  if (mandatory && !value) {
162
152
  const on = Array.from(selected.entries()).reduce((arr, _ref7) => {
163
153
  let [key, value] = _ref7;
@@ -165,12 +155,10 @@ export const classicSelectStrategy = mandatory => {
165
155
  }, []);
166
156
  if (on.length === 0) return original;
167
157
  }
168
-
169
158
  return selected;
170
159
  },
171
160
  in: (v, children, parents) => {
172
161
  let map = new Map();
173
-
174
162
  for (const id of v || []) {
175
163
  map = strategy.select({
176
164
  id,
@@ -180,16 +168,13 @@ export const classicSelectStrategy = mandatory => {
180
168
  parents
181
169
  });
182
170
  }
183
-
184
171
  return map;
185
172
  },
186
173
  out: (v, children) => {
187
174
  const arr = [];
188
-
189
175
  for (const [key, value] of v.entries()) {
190
176
  if (value === 'on' && !children.has(key)) arr.push(key);
191
177
  }
192
-
193
178
  return arr;
194
179
  }
195
180
  };
@@ -1 +1 @@
1
- {"version":3,"file":"selectStrategies.mjs","names":["independentSelectStrategy","mandatory","strategy","select","id","value","selected","on","Array","from","entries","reduce","arr","key","length","set","in","v","children","parents","map","Map","out","push","independentSingleSelectStrategy","parentStrategy","rest","singleSelected","has","get","slice","leafSelectStrategy","leafSingleSelectStrategy","classicSelectStrategy","original","items","item","shift","parent","childrenIds","everySelected","every","cid","noneSelected"],"sources":["../../../src/composables/nested/selectStrategies.ts"],"sourcesContent":["/* eslint-disable sonarjs/no-identical-functions */\nexport type SelectStrategyFn = (data: {\n id: string\n value: boolean\n selected: Map<string, 'on' | 'off' | 'indeterminate'>\n children: Map<string, string[]>\n parents: Map<string, string>\n event?: Event\n}) => Map<string, 'on' | 'off' | 'indeterminate'>\n\nexport type SelectStrategyTransformInFn = (\n v: string[] | undefined,\n children: Map<string, string[]>,\n parents: Map<string, string>,\n) => Map<string, 'on' | 'off' | 'indeterminate'>\n\nexport type SelectStrategyTransformOutFn = (\n v: Map<string, 'on' | 'off' | 'indeterminate'>,\n children: Map<string, string[]>,\n parents: Map<string, string>,\n) => any[]\n\nexport type SelectStrategy = {\n select: SelectStrategyFn\n in: SelectStrategyTransformInFn\n out: SelectStrategyTransformOutFn\n}\n\nexport const independentSelectStrategy = (mandatory?: boolean): SelectStrategy => {\n const strategy: SelectStrategy = {\n select: ({ id, value, selected }) => {\n // When mandatory and we're trying to deselect when id\n // is the only currently selected item then do nothing\n if (mandatory && !value) {\n const on = Array.from(selected.entries()).reduce((arr, [key, value]) => value === 'on' ? [...arr, key] : arr, [] as string[])\n if (on.length === 1 && on[0] === id) return selected\n }\n\n selected.set(id, value ? 'on' : 'off')\n\n return selected\n },\n in: (v, children, parents) => {\n let map = new Map()\n\n for (const id of (v || [])) {\n map = strategy.select({\n id,\n value: true,\n selected: new Map(map),\n children,\n parents,\n })\n }\n\n return map\n },\n out: v => {\n const arr = []\n\n for (const [key, value] of v.entries()) {\n if (value === 'on') arr.push(key)\n }\n\n return arr\n },\n }\n\n return strategy\n}\n\nexport const independentSingleSelectStrategy = (mandatory?: boolean): SelectStrategy => {\n const parentStrategy = independentSelectStrategy(mandatory)\n\n const strategy: SelectStrategy = {\n select: ({ selected, id, ...rest }) => {\n const singleSelected = selected.has(id) ? new Map([[id, selected.get(id)!]]) : new Map()\n return parentStrategy.select({ ...rest, id, selected: singleSelected })\n },\n in: (v, children, parents) => {\n let map = new Map()\n\n if (v?.length) {\n map = parentStrategy.in(v.slice(0, 1), children, parents)\n }\n\n return map\n },\n out: (v, children, parents) => {\n return parentStrategy.out(v, children, parents)\n },\n }\n\n return strategy\n}\n\nexport const leafSelectStrategy = (mandatory?: boolean): SelectStrategy => {\n const parentStrategy = independentSelectStrategy(mandatory)\n\n const strategy: SelectStrategy = {\n select: ({ id, selected, children, ...rest }) => {\n if (children.has(id)) return selected\n\n return parentStrategy.select({ id, selected, children, ...rest })\n },\n in: parentStrategy.in,\n out: parentStrategy.out,\n }\n\n return strategy\n}\n\nexport const leafSingleSelectStrategy = (mandatory?: boolean): SelectStrategy => {\n const parentStrategy = independentSingleSelectStrategy(mandatory)\n\n const strategy: SelectStrategy = {\n select: ({ id, selected, children, ...rest }) => {\n if (children.has(id)) return selected\n\n return parentStrategy.select({ id, selected, children, ...rest })\n },\n in: parentStrategy.in,\n out: parentStrategy.out,\n }\n\n return strategy\n}\n\nexport const classicSelectStrategy = (mandatory?: boolean): SelectStrategy => {\n const strategy: SelectStrategy = {\n select: ({ id, value, selected, children, parents }) => {\n const original = new Map(selected)\n\n const items = [id]\n\n while (items.length) {\n const item = items.shift()!\n\n selected.set(item, value ? 'on' : 'off')\n\n if (children.has(item)) {\n items.push(...children.get(item)!)\n }\n }\n\n let parent = parents.get(id)\n\n while (parent) {\n const childrenIds = children.get(parent)!\n const everySelected = childrenIds.every(cid => selected.get(cid) === 'on')\n const noneSelected = childrenIds.every(cid => !selected.has(cid) || selected.get(cid) === 'off')\n\n selected.set(parent, everySelected ? 'on' : noneSelected ? 'off' : 'indeterminate')\n\n parent = parents.get(parent)\n }\n\n // If mandatory and planned deselect results in no selected\n // items then we can't do it, so return original state\n if (mandatory && !value) {\n const on = Array.from(selected.entries()).reduce((arr, [key, value]) => value === 'on' ? [...arr, key] : arr, [] as string[])\n if (on.length === 0) return original\n }\n\n return selected\n },\n in: (v, children, parents) => {\n let map = new Map()\n\n for (const id of (v || [])) {\n map = strategy.select({\n id,\n value: true,\n selected: new Map(map),\n children,\n parents,\n })\n }\n\n return map\n },\n out: (v, children) => {\n const arr = []\n\n for (const [key, value] of v.entries()) {\n if (value === 'on' && !children.has(key)) arr.push(key)\n }\n\n return arr\n },\n }\n\n return strategy\n}\n"],"mappings":"AAAA;AA4BA,OAAO,MAAMA,yBAAyB,GAAIC,SAAD,IAAyC;EAChF,MAAMC,QAAwB,GAAG;IAC/BC,MAAM,EAAE,QAA6B;MAAA,IAA5B;QAAEC,EAAF;QAAMC,KAAN;QAAaC;MAAb,CAA4B;;MACnC;MACA;MACA,IAAIL,SAAS,IAAI,CAACI,KAAlB,EAAyB;QACvB,MAAME,EAAE,GAAGC,KAAK,CAACC,IAAN,CAAWH,QAAQ,CAACI,OAAT,EAAX,EAA+BC,MAA/B,CAAsC,CAACC,GAAD;UAAA,IAAM,CAACC,GAAD,EAAMR,KAAN,CAAN;UAAA,OAAuBA,KAAK,KAAK,IAAV,GAAiB,CAAC,GAAGO,GAAJ,EAASC,GAAT,CAAjB,GAAiCD,GAAxD;QAAA,CAAtC,EAAmG,EAAnG,CAAX;QACA,IAAIL,EAAE,CAACO,MAAH,KAAc,CAAd,IAAmBP,EAAE,CAAC,CAAD,CAAF,KA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IAAIC,GAAJ,EAAV;;MAEA,KAAK,MAAMjB,EAAX,IAAkBa,CAAC,IAAI,EAAvB,EAA4B;QAC1BG,GAAG,GAAGlB,QAAQ,CAACC,MAAT,CAAgB;UACpBC,EADoB;UAEpBC,KAAK,EAAE,IAFa;UAGpBC,QAAQ,EAAE,IAAIe,GAAJ,CAAQD,GAAR,CAHU;UAIpBF,QAJoB;UAKpBC;QALoB,CAAhB,CAAN;MAOD;;MAED,OAAOC,GAAP;IACD,CAnD8B;IAoD/BE,GAAG,EAAE,CAACL,CAAD,EAAIC,QAAJ,KAAiB;MACpB,MAAMN,GAAG,GAAG,EAAZ;;MAEA,KAAK,MAAM,CAACC,GAAD,EAAMR,KAAN,CAAX,IAA2BY,CAAC,CAACP,OAAF,EAA3B,EAAwC;QACtC,IAAIL,KAAK,KAAK,IAAV,IAAkB,CAACa,QAAQ,CAACU,GAAT,CAAaf,GAAb,CAAvB,EAA0CD,GAAG,CAACW,IAAJ,CAASV,GAAT;MAC3C;;MAED,OAAOD,GAAP;IACD;EA5D8B,CAAjC;EA+DA,OAAOV,QAAP;AACD,CAjEM"}
1
+ {"version":3,"file":"selectStrategies.mjs","names":["independentSelectStrategy","mandatory","strategy","select","id","value","selected","on","Array","from","entries","reduce","arr","key","length","set","in","v","children","parents","map","Map","out","push","independentSingleSelectStrategy","parentStrategy","rest","singleSelected","has","get","slice","leafSelectStrategy","leafSingleSelectStrategy","classicSelectStrategy","original","items","item","shift","parent","childrenIds","everySelected","every","cid","noneSelected"],"sources":["../../../src/composables/nested/selectStrategies.ts"],"sourcesContent":["/* eslint-disable sonarjs/no-identical-functions */\nexport type SelectStrategyFn = (data: {\n id: unknown\n value: boolean\n selected: Map<unknown, 'on' | 'off' | 'indeterminate'>\n children: Map<unknown, unknown[]>\n parents: Map<unknown, unknown>\n event?: Event\n}) => Map<unknown, 'on' | 'off' | 'indeterminate'>\n\nexport type SelectStrategyTransformInFn = (\n v: unknown[] | undefined,\n children: Map<unknown, unknown[]>,\n parents: Map<unknown, unknown>,\n) => Map<unknown, 'on' | 'off' | 'indeterminate'>\n\nexport type SelectStrategyTransformOutFn = (\n v: Map<unknown, 'on' | 'off' | 'indeterminate'>,\n children: Map<unknown, unknown[]>,\n parents: Map<unknown, unknown>,\n) => unknown[]\n\nexport type SelectStrategy = {\n select: SelectStrategyFn\n in: SelectStrategyTransformInFn\n out: SelectStrategyTransformOutFn\n}\n\nexport const independentSelectStrategy = (mandatory?: boolean): SelectStrategy => {\n const strategy: SelectStrategy = {\n select: ({ id, value, selected }) => {\n // When mandatory and we're trying to deselect when id\n // is the only currently selected item then do nothing\n if (mandatory && !value) {\n const on = Array.from(selected.entries()).reduce((arr, [key, value]) => value === 'on' ? [...arr, key] : arr, [] as unknown[])\n if (on.length === 1 && on[0] === id) return selected\n }\n\n selected.set(id, value ? 'on' : 'off')\n\n return selected\n },\n in: (v, children, parents) => {\n let map = new Map()\n\n for (const id of (v || [])) {\n map = strategy.select({\n id,\n value: true,\n selected: new Map(map),\n children,\n parents,\n })\n }\n\n return map\n },\n out: v => {\n const arr = []\n\n for (const [key, value] of v.entries()) {\n if (value === 'on') arr.push(key)\n }\n\n return arr\n },\n }\n\n return strategy\n}\n\nexport const independentSingleSelectStrategy = (mandatory?: boolean): SelectStrategy => {\n const parentStrategy = independentSelectStrategy(mandatory)\n\n const strategy: SelectStrategy = {\n select: ({ selected, id, ...rest }) => {\n const singleSelected = selected.has(id) ? new Map([[id, selected.get(id)!]]) : new Map()\n return parentStrategy.select({ ...rest, id, selected: singleSelected })\n },\n in: (v, children, parents) => {\n let map = new Map()\n\n if (v?.length) {\n map = parentStrategy.in(v.slice(0, 1), children, parents)\n }\n\n return map\n },\n out: (v, children, parents) => {\n return parentStrategy.out(v, children, parents)\n },\n }\n\n return strategy\n}\n\nexport const leafSelectStrategy = (mandatory?: boolean): SelectStrategy => {\n const parentStrategy = independentSelectStrategy(mandatory)\n\n const strategy: SelectStrategy = {\n select: ({ id, selected, children, ...rest }) => {\n if (children.has(id)) return selected\n\n return parentStrategy.select({ id, selected, children, ...rest })\n },\n in: parentStrategy.in,\n out: parentStrategy.out,\n }\n\n return strategy\n}\n\nexport const leafSingleSelectStrategy = (mandatory?: boolean): SelectStrategy => {\n const parentStrategy = independentSingleSelectStrategy(mandatory)\n\n const strategy: SelectStrategy = {\n select: ({ id, selected, children, ...rest }) => {\n if (children.has(id)) return selected\n\n return parentStrategy.select({ id, selected, children, ...rest })\n },\n in: parentStrategy.in,\n out: parentStrategy.out,\n }\n\n return strategy\n}\n\nexport const classicSelectStrategy = (mandatory?: boolean): SelectStrategy => {\n const strategy: SelectStrategy = {\n select: ({ id, value, selected, children, parents }) => {\n const original = new Map(selected)\n\n const items = [id]\n\n while (items.length) {\n const item = items.shift()!\n\n selected.set(item, value ? 'on' : 'off')\n\n if (children.has(item)) {\n items.push(...children.get(item)!)\n }\n }\n\n let parent = parents.get(id)\n\n while (parent) {\n const childrenIds = children.get(parent)!\n const everySelected = childrenIds.every(cid => selected.get(cid) === 'on')\n const noneSelected = childrenIds.every(cid => !selected.has(cid) || selected.get(cid) === 'off')\n\n selected.set(parent, everySelected ? 'on' : noneSelected ? 'off' : 'indeterminate')\n\n parent = parents.get(parent)\n }\n\n // If mandatory and planned deselect results in no selected\n // items then we can't do it, so return original state\n if (mandatory && !value) {\n const on = Array.from(selected.entries()).reduce((arr, [key, value]) => value === 'on' ? [...arr, key] : arr, [] as unknown[])\n if (on.length === 0) return original\n }\n\n return selected\n },\n in: (v, children, parents) => {\n let map = new Map()\n\n for (const id of (v || [])) {\n map = strategy.select({\n id,\n value: true,\n selected: new Map(map),\n children,\n parents,\n })\n }\n\n return map\n },\n out: (v, children) => {\n const arr = []\n\n for (const [key, value] of v.entries()) {\n if (value === 'on' && !children.has(key)) arr.push(key)\n }\n\n return arr\n },\n }\n\n return strategy\n}\n"],"mappings":"AAAA;;AA4BA,OAAO,MAAMA,yBAAyB,GAAIC,SAAmB,IAAqB;EAChF,MAAMC,QAAwB,GA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G;UAAA,IAAE,CAACC,GAAG,EAAER,KAAK,CAAC;UAAA,OAAKA,KAAK,KAAK,IAAI,GAAG,CAAC,GAAGO,GAAG,EAAEC,GAAG,CAAC,GAAGD,GAAG;QAAA,GAAE,EAAE,CAAc;QAC9H,IAAIL,EAAE,CAACO,MAAM,KAAK,CAAC,EAAE,OAAOoB,QAAQ;MACtC;MAEA,OAAO5B,QAAQ;IACjB,CAAC;IACDU,EAAE,EAAE,CAACC,CAAC,EAAEC,QAAQ,EAAEC,OAAO,KAAK;MAC5B,IAAIC,GAAG,GAAG,IAAIC,GAAG,EAAE;MAEnB,KAAK,MAAMjB,EAAE,IAAKa,CAAC,IAAI,EAAE,EAAG;QAC1BG,GAAG,GAAGlB,QAAQ,CAACC,MAAM,CAAC;UACpBC,EAAE;UACFC,KAAK,EAAE,IAAI;UACXC,QAAQ,EAAE,IAAIe,GAAG,CAACD,GAAG,CAAC;UACtBF,QAAQ;UACRC;QACF,CAAC,CAAC;MACJ;MAEA,OAAOC,GAAG;IACZ,CAAC;IACDE,GAAG,EAAE,CAACL,CAAC,EAAEC,QAAQ,KAAK;MACpB,MAAMN,GAAG,GAAG,EAAE;MAEd,KAAK,MAAM,CAACC,GAAG,EAAER,KAAK,CAAC,IAAIY,CAAC,CAACP,OAAO,EAAE,EAAE;QACtC,IAAIL,KAAK,KAAK,IAAI,IAAI,CAACa,QAAQ,CAACU,GAAG,CAACf,GAAG,CAAC,EAAED,GAAG,CAACW,IAAI,CAACV,GAAG,CAAC;MACzD;MAEA,OAAOD,GAAG;IACZ;EACF,CAAC;EAED,OAAOV,QAAQ;AACjB,CAAC"}
@@ -1,15 +1,12 @@
1
1
  // Utilities
2
2
  import { computed } from 'vue';
3
3
  import { getCurrentInstanceName, propsFactory } from "../util/index.mjs"; // Types
4
-
5
4
  const positionValues = ['static', 'relative', 'fixed', 'absolute', 'sticky'];
6
5
  // Composables
7
6
  export const makePositionProps = propsFactory({
8
7
  position: {
9
8
  type: String,
10
- validator:
11
- /* istanbul ignore next */
12
- v => positionValues.includes(v)
9
+ validator: /* istanbul ignore next */v => positionValues.includes(v)
13
10
  }
14
11
  }, 'position');
15
12
  export function usePosition(props) {
@@ -1 +1 @@
1
- {"version":3,"file":"position.mjs","names":["computed","getCurrentInstanceName","propsFactory","positionValues","makePositionProps","position","type","String","validator","v","includes","usePosition","props","name","positionClasses","undefined"],"sources":["../../src/composables/position.ts"],"sourcesContent":["// Utilities\nimport { computed } from 'vue'\nimport { getCurrentInstanceName, propsFactory } from '@/util'\n\n// Types\nimport type { PropType } from 'vue'\n\nconst positionValues = ['static', 'relative', 'fixed', 'absolute', 'sticky'] as const\n\ntype Position = typeof positionValues[number]\n\nexport interface PositionProps {\n position: Position | undefined\n}\n\n// Composables\nexport const makePositionProps = propsFactory({\n position: {\n type: String as PropType<Position>,\n validator: /* istanbul ignore next */ (v: any) => positionValues.includes(v),\n },\n}, 'position')\n\nexport function usePosition (\n props: PositionProps,\n name = getCurrentInstanceName(),\n) {\n const positionClasses = computed(() => {\n return props.position ? `${name}--${props.position}` : undefined\n })\n\n return { positionClasses }\n}\n"],"mappings":"AAAA;AACA,SAASA,QAAT,QAAyB,KAAzB;SACSC,sB,EAAwBC,Y,6BAEjC;;AAGA,MAAMC,cAAc,GAAG,CAAC,QAAD,EAAW,UAAX,EAAuB,OAAvB,EAAgC,UAAhC,EAA4C,QAA5C,CAAvB;AAQA;AACA,OAAO,MAAMC,iBAAiB,GAAGF,YAAY,CAAC;EAC5CG,QAAQ,EAAE;IACRC,IAAI,EAAEC,MADE;IAERC,SAAS;IAAE;IAA4BC,CAAD,IAAYN,cAAc,CAACO,QAAf,CAAwBD,CAAxB;EAF1C;AADkC,CAAD,EAK1C,UAL0C,CAAtC;AAOP,OAAO,SAASE,WAAT,CACLC,KADK,EAGL;EAAA,IADAC,IACA,uEADOZ,sBAAsB,EAC7B;EACA,MAAMa,eAAe,GAAGd,QAAQ,CAAC,MAAM;IACrC,OAAOY,KAAK,CAACP,QAAN,GAAkB,GAAEQ,IAAK,KAAID,KAAK,CAACP,QAAS,EAA5C,GAAgDU,SAAvD;EACD,CAF+B,CAAhC;EAIA,OAAO;IAAED;EAAF,CAAP;AACD"}
1
+ {"version":3,"file":"position.mjs","names":["computed","getCurrentInstanceName","propsFactory","positionValues","makePositionProps","position","type","String","validator","v","includes","usePosition","props","name","positionClasses","undefined"],"sources":["../../src/composables/position.ts"],"sourcesContent":["// Utilities\nimport { computed } from 'vue'\nimport { getCurrentInstanceName, propsFactory } from '@/util'\n\n// Types\nimport type { PropType } from 'vue'\n\nconst positionValues = ['static', 'relative', 'fixed', 'absolute', 'sticky'] as const\n\ntype Position = typeof positionValues[number]\n\nexport interface PositionProps {\n position: Position | undefined\n}\n\n// Composables\nexport const makePositionProps = propsFactory({\n position: {\n type: String as PropType<Position>,\n validator: /* istanbul ignore next */ (v: any) => positionValues.includes(v),\n },\n}, 'position')\n\nexport function usePosition (\n props: PositionProps,\n name = getCurrentInstanceName(),\n) {\n const positionClasses = computed(() => {\n return props.position ? `${name}--${props.position}` : undefined\n })\n\n return { positionClasses }\n}\n"],"mappings":"AAAA;AACA,SAASA,QAAQ,QAAQ,KAAK;AAAA,SACrBC,sBAAsB,EAAEC,YAAY,6BAE7C;AAGA,MAAMC,cAAc,GAAG,CAAC,QAAQ,EAAE,UAAU,EAAE,OAAO,EAAE,UAAU,EAAE,QAAQ,CAAU;AAQrF;AACA,OAAO,MAAMC,iBAAiB,GAAGF,YAAY,CAAC;EAC5CG,QAAQ,EAAE;IACRC,IAAI,EAAEC,MAA4B;IAClCC,SAAS,EAAE,0BAA4BC,CAAM,IAAKN,cAAc,CAACO,QAAQ,CAACD,CAAC;EAC7E;AACF,CAAC,EAAE,UAAU,CAAC;AAEd,OAAO,SAASE,WAAW,CACzBC,KAAoB,EAEpB;EAAA,IADAC,IAAI,uEAAGZ,sBAAsB,EAAE;EAE/B,MAAMa,eAAe,GAAGd,QAAQ,CAAC,MAAM;IACrC,OAAOY,KAAK,CAACP,QAAQ,GAAI,GAAEQ,IAAK,KAAID,KAAK,CAACP,QAAS,EAAC,GAAGU,SAAS;EAClE,CAAC,CAAC;EAEF,OAAO;IAAED;EAAgB,CAAC;AAC5B"}
@@ -2,7 +2,6 @@
2
2
  import { computed, ref, watch } from 'vue';
3
3
  import { getCurrentInstance, toKebabCase } from "../util/index.mjs";
4
4
  import { useToggleScope } from "./toggleScope.mjs"; // Types
5
-
6
5
  // Composables
7
6
  export function useProxiedModel(props, prop, defaultValue) {
8
7
  let transformIn = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : v => v;
@@ -13,12 +12,10 @@ export function useProxiedModel(props, prop, defaultValue) {
13
12
  const checkKebab = kebabProp !== prop;
14
13
  const isControlled = checkKebab ? computed(() => {
15
14
  var _vm$vnode$props, _vm$vnode$props2, _vm$vnode$props3, _vm$vnode$props4;
16
-
17
15
  void props[prop];
18
16
  return !!(((_vm$vnode$props = vm.vnode.props) != null && _vm$vnode$props.hasOwnProperty(prop) || (_vm$vnode$props2 = vm.vnode.props) != null && _vm$vnode$props2.hasOwnProperty(kebabProp)) && ((_vm$vnode$props3 = vm.vnode.props) != null && _vm$vnode$props3.hasOwnProperty(`onUpdate:${prop}`) || (_vm$vnode$props4 = vm.vnode.props) != null && _vm$vnode$props4.hasOwnProperty(`onUpdate:${kebabProp}`)));
19
17
  }) : computed(() => {
20
18
  var _vm$vnode$props5, _vm$vnode$props6;
21
-
22
19
  void props[prop];
23
20
  return !!((_vm$vnode$props5 = vm.vnode.props) != null && _vm$vnode$props5.hasOwnProperty(prop) && (_vm$vnode$props6 = vm.vnode.props) != null && _vm$vnode$props6.hasOwnProperty(`onUpdate:${prop}`));
24
21
  });
@@ -31,17 +28,14 @@ export function useProxiedModel(props, prop, defaultValue) {
31
28
  get() {
32
29
  return transformIn(isControlled.value ? props[prop] : internal.value);
33
30
  },
34
-
35
- set(newValue) {
36
- if (transformIn(isControlled.value ? props[prop] : internal.value) === newValue) {
31
+ set(value) {
32
+ const newValue = transformOut(value);
33
+ if ((isControlled.value ? props[prop] : internal.value) === newValue || transformIn(isControlled.value ? props[prop] : internal.value) === value) {
37
34
  return;
38
35
  }
39
-
40
- newValue = transformOut(newValue);
41
36
  internal.value = newValue;
42
37
  vm == null ? void 0 : vm.emit(`update:${prop}`, newValue);
43
38
  }
44
-
45
39
  });
46
40
  Object.defineProperty(model, 'externalValue', {
47
41
  get: () => isControlled.value ? props[prop] : internal.value
@@ -1 +1 @@
1
- {"version":3,"file":"proxiedModel.mjs","names":["computed","ref","watch","getCurrentInstance","toKebabCase","useToggleScope","useProxiedModel","props","prop","defaultValue","transformIn","v","transformOut","vm","internal","kebabProp","checkKebab","isControlled","vnode","hasOwnProperty","value","val","model","get","set","newValue","emit","Object","defineProperty"],"sources":["../../src/composables/proxiedModel.ts"],"sourcesContent":["// Utilities\nimport { computed, ref, watch } from 'vue'\nimport { getCurrentInstance, toKebabCase } from '@/util'\nimport { useToggleScope } from '@/composables/toggleScope'\n\n// Types\nimport type { Ref } from 'vue'\n\ntype InnerVal<T> = T extends any[] ? Readonly<T> : T\n\n// Composables\nexport function useProxiedModel<\n Props extends object & { [key in Prop as `onUpdate:${Prop}`]: ((val: any) => void) | undefined },\n Prop extends Extract<keyof Props, string>,\n Inner = Props[Prop],\n> (\n props: Props,\n prop: Prop,\n defaultValue?: Props[Prop],\n transformIn: (value?: Props[Prop]) => Inner = (v: any) => v,\n transformOut: (value: Inner) => Props[Prop] = (v: any) => v,\n) {\n const vm = getCurrentInstance('useProxiedModel')\n const internal = ref(props[prop]) as Ref<Props[Prop]>\n const kebabProp = toKebabCase(prop)\n const checkKebab = kebabProp !== prop\n\n const isControlled = checkKebab\n ? computed(() => {\n void props[prop]\n return !!(\n (vm.vnode.props?.hasOwnProperty(prop) || vm.vnode.props?.hasOwnProperty(kebabProp)) &&\n (vm.vnode.props?.hasOwnProperty(`onUpdate:${prop}`) || vm.vnode.props?.hasOwnProperty(`onUpdate:${kebabProp}`))\n )\n })\n : computed(() => {\n void props[prop]\n return !!(vm.vnode.props?.hasOwnProperty(prop) && vm.vnode.props?.hasOwnProperty(`onUpdate:${prop}`))\n })\n\n useToggleScope(() => !isControlled.value, () => {\n watch(() => props[prop], val => {\n internal.value = val\n })\n })\n\n const model = computed({\n get (): any {\n return transformIn(isControlled.value ? props[prop] : internal.value)\n },\n set (newValue) {\n if (transformIn(isControlled.value ? props[prop] : internal.value) === newValue) {\n return\n }\n newValue = transformOut(newValue)\n internal.value = newValue\n vm?.emit(`update:${prop}`, newValue)\n },\n }) as any as Ref<InnerVal<Inner>> & { readonly externalValue: Props[Prop] }\n\n Object.defineProperty(model, 'externalValue', {\n get: () => isControlled.value ? props[prop] : internal.value,\n })\n\n return model\n}\n"],"mappings":"AAAA;AACA,SAASA,QAAT,EAAmBC,GAAnB,EAAwBC,KAAxB,QAAqC,KAArC;SACSC,kB,EAAoBC,W;SACpBC,c,6BAET;;AAKA;AACA,OAAO,SAASC,eAAT,CAKLC,KALK,EAMLC,IANK,EAOLC,YAPK,EAUL;EAAA,IAFAC,WAEA,uEAF+CC,CAAD,IAAYA,CAE1D;EAAA,IADAC,YACA,uEAD+CD,CAAD,IAAYA,CAC1D;EACA,MAAME,EAAE,GAAGV,kBAAkB,CAAC,iBAAD,CAA7B;EACA,MAAMW,QAAQ,GAAGb,GAAG,CAACM,KAAK,CAACC,IAAD,CAAN,CAApB;EACA,MAAMO,SAAS,GAAGX,WAAW,CAACI,IAAD,CAA7B;EACA,MAAMQ,UAAU,GAAGD,SAAS,KAAKP,IAAjC;EAEA,MAAMS,YAAY,GAAGD,UAAU,GAC3BhB,QAAQ,CAAC,MAAM;IAAA;;IACf,KAAKO,KAAK,CAACC,IAAD,CAAV;IACA,OAAO,CAAC,EACN,CAAC,mBAAAK,EAAE,CAACK,KAAH,CAASX,KAAT,6BAAgBY,cAAhB,CAA+BX,IAA/B,yBAAwCK,EAAE,CAACK,KAAH,CAASX,KAAjD,aAAwC,iBAAgBY,cAAhB,CAA+BJ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,CAAU,UAASlB,IAAK,EAAxB,EAA2BiB,QAA3B;IACD;;EAXoB,CAAD,CAAtB;EAcAE,MAAM,CAACC,cAAP,CAAsBN,KAAtB,EAA6B,eAA7B,EAA8C;IAC5CC,GAAG,EAAE,MAAMN,YAAY,CAACG,KAAb,GAAqBb,KAAK,CAACC,IAAD,CAA1B,GAAmCM,QAAQ,CAACM;EADX,CAA9C;EAIA,OAAOE,KAAP;AACD"}
1
+ {"version":3,"file":"proxiedModel.mjs","names":["computed","ref","watch","getCurrentInstance","toKebabCase","useToggleScope","useProxiedModel","props","prop","defaultValue","transformIn","v","transformOut","vm","internal","kebabProp","checkKebab","isControlled","vnode","hasOwnProperty","value","val","model","get","set","newValue","emit","Object","defineProperty"],"sources":["../../src/composables/proxiedModel.ts"],"sourcesContent":["// Utilities\nimport { computed, ref, watch } from 'vue'\nimport { getCurrentInstance, toKebabCase } from '@/util'\nimport { useToggleScope } from '@/composables/toggleScope'\n\n// Types\nimport type { Ref } from 'vue'\n\ntype InnerVal<T> = T extends any[] ? Readonly<T> : T\n\n// Composables\nexport function useProxiedModel<\n Props extends object & { [key in Prop as `onUpdate:${Prop}`]: ((val: any) => void) | undefined },\n Prop extends Extract<keyof Props, string>,\n Inner = Props[Prop],\n> (\n props: Props,\n prop: Prop,\n defaultValue?: Props[Prop],\n transformIn: (value?: Props[Prop]) => Inner = (v: any) => v,\n transformOut: (value: Inner) => Props[Prop] = (v: any) => v,\n) {\n const vm = getCurrentInstance('useProxiedModel')\n const internal = ref(props[prop]) as Ref<Props[Prop]>\n const kebabProp = toKebabCase(prop)\n const checkKebab = kebabProp !== prop\n\n const isControlled = checkKebab\n ? computed(() => {\n void props[prop]\n return !!(\n (vm.vnode.props?.hasOwnProperty(prop) || vm.vnode.props?.hasOwnProperty(kebabProp)) &&\n (vm.vnode.props?.hasOwnProperty(`onUpdate:${prop}`) || vm.vnode.props?.hasOwnProperty(`onUpdate:${kebabProp}`))\n )\n })\n : computed(() => {\n void props[prop]\n return !!(vm.vnode.props?.hasOwnProperty(prop) && vm.vnode.props?.hasOwnProperty(`onUpdate:${prop}`))\n })\n\n useToggleScope(() => !isControlled.value, () => {\n watch(() => props[prop], val => {\n internal.value = val\n })\n })\n\n const model = computed({\n get (): any {\n return transformIn(isControlled.value ? props[prop] : internal.value)\n },\n set (value) {\n const newValue = transformOut(value)\n if (\n (isControlled.value ? props[prop] : internal.value) === newValue ||\n transformIn(isControlled.value ? props[prop] : internal.value) === value\n ) {\n return\n }\n internal.value = newValue\n vm?.emit(`update:${prop}`, newValue)\n },\n }) as any as Ref<InnerVal<Inner>> & { readonly externalValue: Props[Prop] }\n\n Object.defineProperty(model, 'externalValue', {\n get: () => isControlled.value ? props[prop] : internal.value,\n })\n\n return model\n}\n"],"mappings":"AAAA;AACA,SAASA,QAAQ,EAAEC,GAAG,EAAEC,KAAK,QAAQ,KAAK;AAAA,SACjCC,kBAAkB,EAAEC,WAAW;AAAA,SAC/BC,cAAc,6BAEvB;AAKA;AACA,OAAO,SAASC,eAAe,CAK7BC,KAAY,EACZC,IAAU,EACVC,YAA0B,EAG1B;EAAA,IAFAC,WAA2C,uEAAIC,CAAM,IAAKA,CAAC;EAAA,IAC3DC,YAA2C,uEAAID,CAAM,IAAKA,CAAC;EAE3D,MAAME,EAAE,GAAGV,kBAAkB,CAAC,iBAAiB,CAAC;EAChD,MAAMW,QAAQ,GAAGb,GAAG,CAACM,KAAK,CAACC,IAAI,CAAC,CAAqB;EACrD,MAAMO,SAAS,GAAGX,WAAW,CAACI,IAAI,CAAC;EACnC,MAAMQ,UAAU,GAAGD,SAAS,KAAKP,IAAI;EAErC,MAAMS,YAAY,GAAGD,UAAU,GAC3BhB,QAAQ,CAAC,MAAM;IAAA;IACf,KAAKO,KAAK,CAACC,IAAI,CAAC;IAChB,OAAO,CAAC,EACN,CAAC,mBAAAK,EAAE,CAACK,KAAK,CAACX,KAAK,aAAd,gBAAgBY,cAAc,CAACX,IAAI,CAAC,wBAAIK,EAAE,CA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AACM,KAAK,CAAC,KAAKA,KAAK,EACxE;QACA;MACF;MACAN,QAAQ,CAACM,KAAK,GAAGK,QAAQ;MACzBZ,EAAE,oBAAFA,EAAE,CAAEa,IAAI,CAAE,UAASlB,IAAK,EAAC,EAAEiB,QAAQ,CAAC;IACtC;EACF,CAAC,CAA0E;EAE3EE,MAAM,CAACC,cAAc,CAACN,KAAK,EAAE,eAAe,EAAE;IAC5CC,GAAG,EAAE,MAAMN,YAAY,CAACG,KAAK,GAAGb,KAAK,CAACC,IAAI,CAAC,GAAGM,QAAQ,CAACM;EACzD,CAAC,CAAC;EAEF,OAAOE,KAAK;AACd"}
@@ -3,11 +3,9 @@ import { onBeforeUpdate, ref } from 'vue';
3
3
  export function useRefs() {
4
4
  const refs = ref([]);
5
5
  onBeforeUpdate(() => refs.value = []);
6
-
7
6
  function updateRef(e, i) {
8
7
  refs.value[i] = e;
9
8
  }
10
-
11
9
  return {
12
10
  refs,
13
11
  updateRef
@@ -1 +1 @@
1
- {"version":3,"file":"refs.mjs","names":["onBeforeUpdate","ref","useRefs","refs","value","updateRef","e","i"],"sources":["../../src/composables/refs.ts"],"sourcesContent":["// Imports\nimport { onBeforeUpdate, ref } from 'vue'\nimport type { Ref } from 'vue'\n\nexport function useRefs <T extends {}> () {\n const refs = ref<(T | undefined)[]>([]) as Ref<(T | undefined)[]>\n\n onBeforeUpdate(() => (refs.value = []))\n\n function updateRef (e: any, i: number) {\n refs.value[i] = e\n }\n\n return { refs, updateRef }\n}\n"],"mappings":"AAAA;AACA,SAASA,cAAT,EAAyBC,GAAzB,QAAoC,KAApC;AAGA,OAAO,SAASC,OAAT,GAAmC;EACxC,MAAMC,IAAI,GAAGF,GAAG,CAAoB,EAApB,CAAhB;EAEAD,cAAc,CAAC,MAAOG,IAAI,CAACC,KAAL,GAAa,EAArB,CAAd;;EAEA,SAASC,SAAT,CAAoBC,CAApB,EAA4BC,CAA5B,EAAuC;IACrCJ,IAAI,CAACC,KAAL,CAAWG,CAAX,IAAgBD,CAAhB;EACD;;EAED,OAAO;IAAEH,IAAF;IAAQE;EAAR,CAAP;AACD"}
1
+ {"version":3,"file":"refs.mjs","names":["onBeforeUpdate","ref","useRefs","refs","value","updateRef","e","i"],"sources":["../../src/composables/refs.ts"],"sourcesContent":["// Imports\nimport { onBeforeUpdate, ref } from 'vue'\nimport type { Ref } from 'vue'\n\nexport function useRefs <T extends {}> () {\n const refs = ref<(T | undefined)[]>([]) as Ref<(T | undefined)[]>\n\n onBeforeUpdate(() => (refs.value = []))\n\n function updateRef (e: any, i: number) {\n refs.value[i] = e\n }\n\n return { refs, updateRef }\n}\n"],"mappings":"AAAA;AACA,SAASA,cAAc,EAAEC,GAAG,QAAQ,KAAK;AAGzC,OAAO,SAASC,OAAO,GAAmB;EACxC,MAAMC,IAAI,GAAGF,GAAG,CAAoB,EAAE,CAA2B;EAEjED,cAAc,CAAC,MAAOG,IAAI,CAACC,KAAK,GAAG,EAAG,CAAC;EAEvC,SAASC,SAAS,CAAEC,CAAM,EAAEC,CAAS,EAAE;IACrCJ,IAAI,CAACC,KAAK,CAACG,CAAC,CAAC,GAAGD,CAAC;EACnB;EAEA,OAAO;IAAEH,IAAI;IAAEE;EAAU,CAAC;AAC5B"}
@@ -5,7 +5,6 @@ import { IN_BROWSER } from "../util/globals.mjs";
5
5
  export function useResizeObserver(callback) {
6
6
  const resizeRef = ref();
7
7
  const contentRect = ref();
8
-
9
8
  if (IN_BROWSER) {
10
9
  const observer = new ResizeObserver(entries => {
11
10
  callback == null ? void 0 : callback(entries, observer);
@@ -20,13 +19,11 @@ export function useResizeObserver(callback) {
20
19
  observer.unobserve(oldValue);
21
20
  contentRect.value = undefined;
22
21
  }
23
-
24
22
  if (newValue) observer.observe(newValue);
25
23
  }, {
26
24
  flush: 'post'
27
25
  });
28
26
  }
29
-
30
27
  return {
31
28
  resizeRef,
32
29
  contentRect: readonly(contentRect)
@@ -1 +1 @@
1
- {"version":3,"file":"resizeObserver.mjs","names":["onBeforeUnmount","readonly","ref","watch","IN_BROWSER","useResizeObserver","callback","resizeRef","contentRect","observer","ResizeObserver","entries","length","value","disconnect","newValue","oldValue","unobserve","undefined","observe","flush"],"sources":["../../src/composables/resizeObserver.ts"],"sourcesContent":["// Utilities\nimport { onBeforeUnmount, readonly, ref, watch } from 'vue'\nimport type { DeepReadonly, Ref } from 'vue'\n\n// Globals\nimport { IN_BROWSER } from '@/util/globals'\n\ninterface ResizeState {\n resizeRef: Ref<Element | undefined>\n contentRect: DeepReadonly<Ref<DOMRectReadOnly | undefined>>\n}\n\nexport function useResizeObserver (callback?: ResizeObserverCallback): ResizeState {\n const resizeRef = ref<Element>()\n const contentRect = ref<DOMRectReadOnly>()\n\n if (IN_BROWSER) {\n const observer = new ResizeObserver((entries: ResizeObserverEntry[]) => {\n callback?.(entries, observer)\n\n if (!entries.length) return\n\n contentRect.value = entries[0].contentRect\n })\n\n onBeforeUnmount(() => {\n observer.disconnect()\n })\n\n watch(resizeRef, (newValue, oldValue) => {\n if (oldValue) {\n observer.unobserve(oldValue)\n contentRect.value = undefined\n }\n\n if (newValue) observer.observe(newValue)\n }, {\n flush: 'post',\n })\n }\n\n return {\n resizeRef,\n contentRect: readonly(contentRect),\n }\n}\n"],"mappings":"AAAA;AACA,SAASA,eAAT,EAA0BC,QAA1B,EAAoCC,GAApC,EAAyCC,KAAzC,QAAsD,KAAtD;AAGA;SACSC,U;AAOT,OAAO,SAASC,iBAAT,CAA4BC,QAA5B,EAA4E;EACjF,MAAMC,SAAS,GAAGL,GAAG,EAArB;EACA,MAAMM,WAAW,GAAGN,GAAG,EAAvB;;EAEA,IAAIE,UAAJ,EAAgB;IACd,MAAMK,QAAQ,GAAG,IAAIC,cAAJ,CAAoBC,OAAD,IAAoC;MACtEL,QAAQ,QAAR,YAAAA,QAAQ,CAAGK,OAAH,EAAYF,QAAZ,CAAR;MAEA,IAAI,CAACE,OAAO,CAACC,MAAb,EAAqB;MAErBJ,WAAW,CAACK,KAAZ,GAAoBF,OAAO,CAAC,CAAD,CAAP,CAAWH,WAA/B;IACD,CANgB,CAAjB;IAQAR,eAAe,CAAC,MAAM;MACpBS,QAAQ,CAACK,UAAT;IACD,CAFc,CAAf;IAIAX,KAAK,CAACI,SAAD,EAAY,CAACQ,QAAD,EAAWC,QAAX,KAAwB;MACvC,IAAIA,QAAJ,EAAc;QACZP,QAAQ,CAACQ,SAAT,CAAmBD,QAAnB;QACAR,WAAW,CAACK,KAAZ,GAAoBK,SAApB;MACD;;MAED,IAAIH,QAAJ,EAAcN,QAAQ,CAACU,OAAT,CAAiBJ,QAAjB;IACf,CAPI,EAOF;MACDK,KAAK,EAAE;IADN,CAPE,CAAL;EAUD;;EAED,OAAO;IACLb,SADK;IAELC,WAAW,EAAEP,QAAQ,CAACO,WAAD;EAFhB,CAAP;AAID"}
1
+ {"version":3,"file":"resizeObserver.mjs","names":["onBeforeUnmount","readonly","ref","watch","IN_BROWSER","useResizeObserver","callback","resizeRef","contentRect","observer","ResizeObserver","entries","length","value","disconnect","newValue","oldValue","unobserve","undefined","observe","flush"],"sources":["../../src/composables/resizeObserver.ts"],"sourcesContent":["// Utilities\nimport { onBeforeUnmount, readonly, ref, watch } from 'vue'\nimport type { DeepReadonly, Ref } from 'vue'\n\n// Globals\nimport { IN_BROWSER } from '@/util/globals'\n\ninterface ResizeState {\n resizeRef: Ref<Element | undefined>\n contentRect: DeepReadonly<Ref<DOMRectReadOnly | undefined>>\n}\n\nexport function useResizeObserver (callback?: ResizeObserverCallback): ResizeState {\n const resizeRef = ref<Element>()\n const contentRect = ref<DOMRectReadOnly>()\n\n if (IN_BROWSER) {\n const observer = new ResizeObserver((entries: ResizeObserverEntry[]) => {\n callback?.(entries, observer)\n\n if (!entries.length) return\n\n contentRect.value = entries[0].contentRect\n })\n\n onBeforeUnmount(() => {\n observer.disconnect()\n })\n\n watch(resizeRef, (newValue, oldValue) => {\n if (oldValue) {\n observer.unobserve(oldValue)\n contentRect.value = undefined\n }\n\n if (newValue) observer.observe(newValue)\n }, {\n flush: 'post',\n })\n }\n\n return {\n resizeRef,\n contentRect: readonly(contentRect),\n }\n}\n"],"mappings":"AAAA;AACA,SAASA,eAAe,EAAEC,QAAQ,EAAEC,GAAG,EAAEC,KAAK,QAAQ,KAAK;AAG3D;AAAA,SACSC,UAAU;AAOnB,OAAO,SAASC,iBAAiB,CAAEC,QAAiC,EAAe;EACjF,MAAMC,SAAS,GAAGL,GAAG,EAAW;EAChC,MAAMM,WAAW,GAAGN,GAAG,EAAmB;EAE1C,IAAIE,UAAU,EAAE;IACd,MAAMK,QAAQ,GAAG,IAAIC,cAAc,CAAEC,OAA8B,IAAK;MACtEL,QAAQ,oBAARA,QAAQ,CAAGK,OAAO,EAAEF,QAAQ,CAAC;MAE7B,IAAI,CAACE,OAAO,CAACC,MAAM,EAAE;MAErBJ,WAAW,CAACK,KAAK,GAAGF,OAAO,CAAC,CAAC,CAAC,CAACH,WAAW;IAC5C,CAAC,CAAC;IAEFR,eAAe,CAAC,MAAM;MACpBS,QAAQ,CAACK,UAAU,EAAE;IACvB,CAAC,CAAC;IAEFX,KAAK,CAACI,SAAS,EAAE,CAACQ,QAAQ,EAAEC,QAAQ,KAAK;MACvC,IAAIA,QAAQ,EAAE;QACZP,QAAQ,CAACQ,SAAS,CAACD,QAAQ,CAAC;QAC5BR,WAAW,CAACK,KAAK,GAAGK,SAAS;MAC/B;MAEA,IAAIH,QAAQ,EAAEN,QAAQ,CAACU,OAAO,CAACJ,QAAQ,CAAC;IAC1C,CAAC,EAAE;MACDK,KAAK,EAAE;IACT,CAAC,CAAC;EACJ;EAEA,OAAO;IACLb,SAAS;IACTC,WAAW,EAAEP,QAAQ,CAACO,WAAW;EACnC,CAAC;AACH"}
@@ -1,7 +1,6 @@
1
1
  // Utilities
2
2
  import { computed, isRef } from 'vue';
3
3
  import { getCurrentInstanceName, propsFactory } from "../util/index.mjs"; // Types
4
-
5
4
  // Composables
6
5
  export const makeRoundedProps = propsFactory({
7
6
  rounded: {
@@ -14,7 +13,6 @@ export function useRounded(props) {
14
13
  const roundedClasses = computed(() => {
15
14
  const rounded = isRef(props) ? props.value : props.rounded;
16
15
  const classes = [];
17
-
18
16
  if (rounded === true || rounded === '') {
19
17
  classes.push(`${name}--rounded`);
20
18
  } else if (typeof rounded === 'string' || rounded === 0) {
@@ -22,7 +20,6 @@ export function useRounded(props) {
22
20
  classes.push(`rounded-${value}`);
23
21
  }
24
22
  }
25
-
26
23
  return classes;
27
24
  });
28
25
  return {
@@ -1 +1 @@
1
- {"version":3,"file":"rounded.mjs","names":["computed","isRef","getCurrentInstanceName","propsFactory","makeRoundedProps","rounded","type","Boolean","Number","String","default","undefined","useRounded","props","name","roundedClasses","value","classes","push","split"],"sources":["../../src/composables/rounded.ts"],"sourcesContent":["// Utilities\nimport { computed, isRef } from 'vue'\nimport { getCurrentInstanceName, propsFactory } from '@/util'\n\n// Types\nimport type { Ref } from 'vue'\n\ntype RoundedValue = boolean | string | number | null | undefined\n\nexport interface RoundedProps {\n rounded?: RoundedValue\n tile?: boolean\n}\n\ntype RoundedData = {\n roundedClasses: Ref<string[]>\n}\n\n// Composables\nexport const makeRoundedProps = propsFactory({\n rounded: {\n type: [Boolean, Number, String],\n default: undefined,\n },\n}, 'rounded')\n\nexport function useRounded (\n props: RoundedProps | Ref<RoundedValue>,\n name = getCurrentInstanceName(),\n): RoundedData {\n const roundedClasses = computed(() => {\n const rounded = isRef(props) ? props.value : props.rounded\n const classes: string[] = []\n\n if (rounded === true || rounded === '') {\n classes.push(`${name}--rounded`)\n } else if (\n typeof rounded === 'string' ||\n rounded === 0\n ) {\n for (const value of String(rounded).split(' ')) {\n classes.push(`rounded-${value}`)\n }\n }\n\n return classes\n })\n\n return { roundedClasses }\n}\n"],"mappings":"AAAA;AACA,SAASA,QAAT,EAAmBC,KAAnB,QAAgC,KAAhC;SACSC,sB,EAAwBC,Y,6BAEjC;;AAcA;AACA,OAAO,MAAMC,gBAAgB,GAAGD,YAAY,CAAC;EAC3CE,OAAO,EAAE;IACPC,IAAI,EAAE,CAACC,OAAD,EAAUC,MAAV,EAAkBC,MAAlB,CADC;IAEPC,OAAO,EAAEC;EAFF;AADkC,CAAD,EAKzC,SALyC,CAArC;AAOP,OAAO,SAASC,UAAT,CACLC,KADK,EAGQ;EAAA,IADbC,IACa,uEADNZ,sBAAsB,EAChB;EACb,MAAMa,cAAc,GAAGf,QAAQ,CAAC,MAAM;IACpC,MAAMK,OAAO,GAAGJ,KAAK,CAACY,KAAD,CAAL,GAAeA,KAAK,CAACG,KAArB,GAA6BH,KAAK,CAACR,OAAnD;IACA,MAAMY,OAAiB,GAAG,EAA1B;;IAEA,IAAIZ,OAAO,KAAK,IAAZ,IAAoBA,OAAO,KAAK,EAApC,EAAwC;MACtCY,OAAO,CAACC,IAAR,CAAc,GAAEJ,IAAK,WAArB;IACD,CAFD,MAEO,IACL,OAAOT,OAAP,KAAmB,QAAnB,IACAA,OAAO,KAAK,CAFP,EAGL;MACA,KAAK,MAAMW,KAAX,IAAoBP,MAAM,CAACJ,OAAD,CAAN,CAAgBc,KAAhB,CAAsB,GAAtB,CAApB,EAAgD;QAC9CF,OAAO,CAACC,IAAR,CAAc,WAAUF,KAAM,EAA9B;MACD;IACF;;IAED,OAAOC,OAAP;EACD,CAhB8B,CAA/B;EAkBA,OAAO;IAAEF;EAAF,CAAP;AACD"}
1
+ {"version":3,"file":"rounded.mjs","names":["computed","isRef","getCurrentInstanceName","propsFactory","makeRoundedProps","rounded","type","Boolean","Number","String","default","undefined","useRounded","props","name","roundedClasses","value","classes","push","split"],"sources":["../../src/composables/rounded.ts"],"sourcesContent":["// Utilities\nimport { computed, isRef } from 'vue'\nimport { getCurrentInstanceName, propsFactory } from '@/util'\n\n// Types\nimport type { Ref } from 'vue'\n\ntype RoundedValue = boolean | string | number | null | undefined\n\nexport interface RoundedProps {\n rounded?: RoundedValue\n tile?: boolean\n}\n\ntype RoundedData = {\n roundedClasses: Ref<string[]>\n}\n\n// Composables\nexport const makeRoundedProps = propsFactory({\n rounded: {\n type: [Boolean, Number, String],\n default: undefined,\n },\n}, 'rounded')\n\nexport function useRounded (\n props: RoundedProps | Ref<RoundedValue>,\n name = getCurrentInstanceName(),\n): RoundedData {\n const roundedClasses = computed(() => {\n const rounded = isRef(props) ? props.value : props.rounded\n const classes: string[] = []\n\n if (rounded === true || rounded === '') {\n classes.push(`${name}--rounded`)\n } else if (\n typeof rounded === 'string' ||\n rounded === 0\n ) {\n for (const value of String(rounded).split(' ')) {\n classes.push(`rounded-${value}`)\n }\n }\n\n return classes\n })\n\n return { roundedClasses }\n}\n"],"mappings":"AAAA;AACA,SAASA,QAAQ,EAAEC,KAAK,QAAQ,KAAK;AAAA,SAC5BC,sBAAsB,EAAEC,YAAY,6BAE7C;AAcA;AACA,OAAO,MAAMC,gBAAgB,GAAGD,YAAY,CAAC;EAC3CE,OAAO,EAAE;IACPC,IAAI,EAAE,CAACC,OAAO,EAAEC,MAAM,EAAEC,MAAM,CAAC;IAC/BC,OAAO,EAAEC;EACX;AACF,CAAC,EAAE,SAAS,CAAC;AAEb,OAAO,SAASC,UAAU,CACxBC,KAAuC,EAE1B;EAAA,IADbC,IAAI,uEAAGZ,sBAAsB,EAAE;EAE/B,MAAMa,cAAc,GAAGf,QAAQ,CAAC,MAAM;IACpC,MAAMK,OAAO,GAAGJ,KAAK,CAACY,KAAK,CAAC,GAAGA,KAAK,CAACG,KAAK,GAAGH,KAAK,CAACR,OAAO;IAC1D,MAAMY,OAAiB,GAAG,EAAE;IAE5B,IAAIZ,OAAO,KAAK,IAAI,IAAIA,OAAO,KAAK,EAAE,EAAE;MACtCY,OAAO,CAACC,IAAI,CAAE,GAAEJ,IAAK,WAAU,CAAC;IAClC,CAAC,MAAM,IACL,OAAOT,OAAO,KAAK,QAAQ,IAC3BA,OAAO,KAAK,CAAC,EACb;MACA,KAAK,MAAMW,KAAK,IAAIP,MAAM,CAACJ,OAAO,CAAC,CAACc,KAAK,CAAC,GAAG,CAAC,EAAE;QAC9CF,OAAO,CAACC,IAAI,CAAE,WAAUF,KAAM,EAAC,CAAC;MAClC;IACF;IAEA,OAAOC,OAAO;EAChB,CAAC,CAAC;EAEF,OAAO;IAAEF;EAAe,CAAC;AAC3B"}
@@ -1,18 +1,18 @@
1
1
  // Utilities
2
2
  import { getCurrentInstance, IN_BROWSER, propsFactory } from "../util/index.mjs";
3
- import { computed, nextTick, onScopeDispose, resolveDynamicComponent, toRef } from 'vue'; // Types
3
+ import { computed, nextTick, onScopeDispose, resolveDynamicComponent, toRef } from 'vue';
4
+
5
+ // Types
4
6
 
5
7
  export function useRoute() {
6
8
  const vm = getCurrentInstance('useRoute');
7
9
  return computed(() => {
8
10
  var _vm$proxy;
9
-
10
11
  return vm == null ? void 0 : (_vm$proxy = vm.proxy) == null ? void 0 : _vm$proxy.$route;
11
12
  });
12
13
  }
13
14
  export function useRouter() {
14
15
  var _getCurrentInstance, _getCurrentInstance$p;
15
-
16
16
  return (_getCurrentInstance = getCurrentInstance('useRouter')) == null ? void 0 : (_getCurrentInstance$p = _getCurrentInstance.proxy) == null ? void 0 : _getCurrentInstance$p.$router;
17
17
  }
18
18
  export function useLink(props, attrs) {
@@ -21,7 +21,6 @@ export function useLink(props, attrs) {
21
21
  const isClickable = computed(() => {
22
22
  return (isLink == null ? void 0 : isLink.value) || !!(attrs.onClick || attrs.onClickOnce);
23
23
  });
24
-
25
24
  if (typeof RouterLink === 'string') {
26
25
  return {
27
26
  isLink,
@@ -29,7 +28,6 @@ export function useLink(props, attrs) {
29
28
  href: toRef(props, 'href')
30
29
  };
31
30
  }
32
-
33
31
  const link = props.to ? RouterLink.useLink(props) : undefined;
34
32
  return {
35
33
  isLink,
@@ -38,7 +36,6 @@ export function useLink(props, attrs) {
38
36
  navigate: link == null ? void 0 : link.navigate,
39
37
  isActive: link && computed(() => {
40
38
  var _link$isExactActive, _link$isActive;
41
-
42
39
  return props.exact ? (_link$isExactActive = link.isExactActive) == null ? void 0 : _link$isExactActive.value : (_link$isActive = link.isActive) == null ? void 0 : _link$isActive.value;
43
40
  }),
44
41
  href: computed(() => props.to ? link == null ? void 0 : link.route.value.href : props.href)
@@ -55,7 +52,6 @@ export function useBackButton(router, cb) {
55
52
  let popped = false;
56
53
  let removeBefore;
57
54
  let removeAfter;
58
-
59
55
  if (IN_BROWSER) {
60
56
  nextTick(() => {
61
57
  window.addEventListener('popstate', onPopstate);
@@ -65,7 +61,6 @@ export function useBackButton(router, cb) {
65
61
  } else {
66
62
  popped ? cb(next) : next();
67
63
  }
68
-
69
64
  inTransition = true;
70
65
  });
71
66
  removeAfter = router == null ? void 0 : router.afterEach(() => {
@@ -74,16 +69,13 @@ export function useBackButton(router, cb) {
74
69
  });
75
70
  onScopeDispose(() => {
76
71
  var _removeBefore, _removeAfter;
77
-
78
72
  window.removeEventListener('popstate', onPopstate);
79
73
  (_removeBefore = removeBefore) == null ? void 0 : _removeBefore();
80
74
  (_removeAfter = removeAfter) == null ? void 0 : _removeAfter();
81
75
  });
82
76
  }
83
-
84
77
  function onPopstate(e) {
85
78
  var _e$state;
86
-
87
79
  if ((_e$state = e.state) != null && _e$state.replaced) return;
88
80
  popped = true;
89
81
  setTimeout(() => popped = false);
@@ -1 +1 @@
1
- {"version":3,"file":"router.mjs","names":["getCurrentInstance","IN_BROWSER","propsFactory","computed","nextTick","onScopeDispose","resolveDynamicComponent","toRef","useRoute","vm","proxy","$route","useRouter","$router","useLink","props","attrs","RouterLink","isLink","href","to","isClickable","value","onClick","onClickOnce","link","undefined","route","navigate","isActive","exact","isExactActive","makeRouterProps","String","replace","Boolean","Object","inTransition","useBackButton","router","cb","popped","removeBefore","removeAfter","window","addEventListener","onPopstate","beforeEach","from","next","setTimeout","afterEach","removeEventListener","e","state","replaced"],"sources":["../../src/composables/router.tsx"],"sourcesContent":["// Utilities\nimport { getCurrentInstance, IN_BROWSER, propsFactory } from '@/util'\nimport {\n computed,\n nextTick,\n onScopeDispose,\n resolveDynamicComponent,\n toRef,\n} from 'vue'\n\n// Types\nimport type { ComputedRef, PropType, Ref, SetupContext } from 'vue'\nimport type {\n RouterLink as _RouterLink,\n useLink as _useLink,\n NavigationGuardNext,\n RouteLocationNormalizedLoaded,\n RouteLocationRaw,\n Router,\n UseLinkOptions,\n} from 'vue-router'\n\nexport function useRoute (): Ref<RouteLocationNormalizedLoaded | undefined> {\n const vm = getCurrentInstance('useRoute')\n\n return computed(() => vm?.proxy?.$route)\n}\n\nexport function useRouter (): Router | undefined {\n return getCurrentInstance('useRouter')?.proxy?.$router\n}\n\nexport interface LinkProps {\n href: string | undefined\n replace: boolean | undefined\n to: RouteLocationRaw | undefined\n exact: boolean | undefined\n}\n\nexport interface UseLink extends Omit<Partial<ReturnType<typeof _useLink>>, 'href'> {\n isLink: ComputedRef<boolean>\n isClickable: ComputedRef<boolean>\n href: Ref<string | undefined>\n}\n\nexport function useLink (props: LinkProps, attrs: SetupContext['attrs']): UseLink {\n const RouterLink = resolveDynamicComponent('RouterLink') as typeof _RouterLink | string\n\n const isLink = computed(() => !!(props.href || props.to))\n const isClickable = computed(() => {\n return isLink?.value || !!(attrs.onClick || attrs.onClickOnce)\n })\n\n if (typeof RouterLink === 'string') {\n return {\n isLink,\n isClickable,\n href: toRef(props, 'href'),\n }\n }\n\n const link = props.to ? RouterLink.useLink(props as UseLinkOptions) : undefined\n\n return {\n isLink,\n isClickable,\n route: link?.route,\n navigate: link?.navigate,\n isActive: link && computed(() => props.exact ? link.isExactActive?.value : link.isActive?.value),\n href: computed(() => props.to ? link?.route.value.href : props.href),\n }\n}\n\nexport const makeRouterProps = propsFactory({\n href: String,\n replace: Boolean,\n to: [String, Object] as PropType<RouteLocationRaw>,\n exact: Boolean,\n}, 'router')\n\nlet inTransition = false\nexport function useBackButton (router: Router | undefined, cb: (next: NavigationGuardNext) => void) {\n let popped = false\n let removeBefore: (() => void) | undefined\n let removeAfter: (() => void) | undefined\n\n if (IN_BROWSER) {\n nextTick(() => {\n window.addEventListener('popstate', onPopstate)\n removeBefore = router?.beforeEach((to, from, next) => {\n if (!inTransition) {\n setTimeout(() => popped ? cb(next) : next())\n } else {\n popped ? cb(next) : next()\n }\n inTransition = true\n })\n removeAfter = router?.afterEach(() => {\n inTransition = false\n })\n })\n onScopeDispose(() => {\n window.removeEventListener('popstate', onPopstate)\n removeBefore?.()\n removeAfter?.()\n })\n }\n\n function onPopstate (e: PopStateEvent) {\n if (e.state?.replaced) return\n\n popped = true\n setTimeout(() => (popped = false))\n }\n}\n"],"mappings":"AAAA;SACSA,kB,EAAoBC,U,EAAYC,Y;AACzC,SACEC,QADF,EAEEC,QAFF,EAGEC,cAHF,EAIEC,uBAJF,EAKEC,KALF,QAMO,KANP,C,CAQA;;AAYA,OAAO,SAASC,QAAT,GAAqE;EAC1E,MAAMC,EAAE,GAAGT,kBAAkB,CAAC,UAAD,CAA7B;EAEA,OAAOG,QAAQ,CAAC;IAAA;;IAAA,OAAMM,EAAN,iCAAMA,EAAE,CAAEC,KAAV,qBAAM,UAAWC,MAAjB;EAAA,CAAD,CAAf;AACD;AAED,OAAO,SAASC,SAAT,GAA0C;EAAA;;EAC/C,8BAAOZ,kBAAkB,CAAC,WAAD,CAAzB,8CAAO,oBAAiCU,KAAxC,qBAAO,sBAAwCG,OAA/C;AACD;AAeD,OAAO,SAASC,OAAT,CAAkBC,KAAlB,EAAoCC,KAApC,EAA2E;EAChF,MAAMC,UAAU,GAAGX,uBAAuB,CAAC,YAAD,CAA1C;EAEA,MAAMY,MAAM,GAAGf,QAAQ,CAAC,MAAM,CAAC,EAAEY,KAAK,CAACI,IAAN,IAAcJ,KAAK,CAACK,EAAtB,CAAR,CAAvB;EACA,MAAMC,WAAW,GAAGlB,QAAQ,CAAC,MAAM;IACjC,OAAO,CAAAe,MAAM,QAAN,YAAAA,MAAM,CAAEI,KAAR,KAAiB,CAAC,EAAEN,KAAK,CAACO,OAAN,IAAiBP,KAAK,CAACQ,WAAzB,CAAzB;EACD,CAF2B,CAA5B;;EAIA,IAAI,OAAOP,UAAP,KAAsB,QAA1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ApC;MACAJ,YAAY,GAAGH,MAAH,oBAAGA,MAAM,CAAEQ,UAAR,CAAmB,CAAC3B,EAAD,EAAK4B,IAAL,EAAWC,IAAX,KAAoB;QACpD,IAAI,CAACZ,YAAL,EAAmB;UACjBa,UAAU,CAAC,MAAMT,MAAM,GAAGD,EAAE,CAACS,IAAD,CAAL,GAAcA,IAAI,EAA/B,CAAV;QACD,CAFD,MAEO;UACLR,MAAM,GAAGD,EAAE,CAACS,IAAD,CAAL,GAAcA,IAAI,EAAxB;QACD;;QACDZ,YAAY,GAAG,IAAf;MACD,CAPc,CAAf;MAQAM,WAAW,GAAGJ,MAAH,oBAAGA,MAAM,CAAEY,SAAR,CAAkB,MAAM;QACpCd,YAAY,GAAG,KAAf;MACD,CAFa,CAAd;IAGD,CAbO,CAAR;IAcAhC,cAAc,CAAC,MAAM;MAAA;;MACnBuC,MAAM,CAACQ,mBAAP,CAA2B,UAA3B,EAAuCN,UAAvC;MACA,iBAAAJ,YAAY,SAAZ;MACA,gBAAAC,WAAW,SAAX;IACD,CAJa,CAAd;EAKD;;EAED,SAASG,UAAT,CAAqBO,CAArB,EAAuC;IAAA;;IACrC,gBAAIA,CAAC,CAACC,KAAN,aAAI,SAASC,QAAb,EAAuB;IAEvBd,MAAM,GAAG,IAAT;IACAS,UAAU,CAAC,MAAOT,MAAM,GAAG,KAAjB,CAAV;EACD;AACF"}
1
+ {"version":3,"file":"router.mjs","names":["getCurrentInstance","IN_BROWSER","propsFactory","computed","nextTick","onScopeDispose","resolveDynamicComponent","toRef","useRoute","vm","proxy","$route","useRouter","$router","useLink","props","attrs","RouterLink","isLink","href","to","isClickable","value","onClick","onClickOnce","link","undefined","route","navigate","isActive","exact","isExactActive","makeRouterProps","String","replace","Boolean","Object","inTransition","useBackButton","router","cb","popped","removeBefore","removeAfter","window","addEventListener","onPopstate","beforeEach","from","next","setTimeout","afterEach","removeEventListener","e","state","replaced"],"sources":["../../src/composables/router.tsx"],"sourcesContent":["// Utilities\nimport { getCurrentInstance, IN_BROWSER, propsFactory } from '@/util'\nimport {\n computed,\n nextTick,\n onScopeDispose,\n resolveDynamicComponent,\n toRef,\n} from 'vue'\n\n// Types\nimport type { ComputedRef, PropType, Ref, SetupContext } from 'vue'\nimport type {\n RouterLink as _RouterLink,\n useLink as _useLink,\n NavigationGuardNext,\n RouteLocationNormalizedLoaded,\n RouteLocationRaw,\n Router,\n UseLinkOptions,\n} from 'vue-router'\n\nexport function useRoute (): Ref<RouteLocationNormalizedLoaded | undefined> {\n const vm = getCurrentInstance('useRoute')\n\n return computed(() => vm?.proxy?.$route)\n}\n\nexport function useRouter (): Router | undefined {\n return getCurrentInstance('useRouter')?.proxy?.$router\n}\n\nexport interface LinkProps {\n href: string | undefined\n replace: boolean | undefined\n to: RouteLocationRaw | undefined\n exact: boolean | undefined\n}\n\nexport interface UseLink extends Omit<Partial<ReturnType<typeof _useLink>>, 'href'> {\n isLink: ComputedRef<boolean>\n isClickable: ComputedRef<boolean>\n href: Ref<string | undefined>\n}\n\nexport function useLink (props: LinkProps, attrs: SetupContext['attrs']): UseLink {\n const RouterLink = resolveDynamicComponent('RouterLink') as typeof _RouterLink | string\n\n const isLink = computed(() => !!(props.href || props.to))\n const isClickable = computed(() => {\n return isLink?.value || !!(attrs.onClick || attrs.onClickOnce)\n })\n\n if (typeof RouterLink === 'string') {\n return {\n isLink,\n isClickable,\n href: toRef(props, 'href'),\n }\n }\n\n const link = props.to ? RouterLink.useLink(props as UseLinkOptions) : undefined\n\n return {\n isLink,\n isClickable,\n route: link?.route,\n navigate: link?.navigate,\n isActive: link && computed(() => props.exact ? link.isExactActive?.value : link.isActive?.value),\n href: computed(() => props.to ? link?.route.value.href : props.href),\n }\n}\n\nexport const makeRouterProps = propsFactory({\n href: String,\n replace: Boolean,\n to: [String, Object] as PropType<RouteLocationRaw>,\n exact: Boolean,\n}, 'router')\n\nlet inTransition = false\nexport function useBackButton (router: Router | undefined, cb: (next: NavigationGuardNext) => void) {\n let popped = false\n let removeBefore: (() => void) | undefined\n let removeAfter: (() => void) | undefined\n\n if (IN_BROWSER) {\n nextTick(() => {\n window.addEventListener('popstate', onPopstate)\n removeBefore = router?.beforeEach((to, from, next) => {\n if (!inTransition) {\n setTimeout(() => popped ? cb(next) : next())\n } else {\n popped ? cb(next) : next()\n }\n inTransition = true\n })\n removeAfter = router?.afterEach(() => {\n inTransition = false\n })\n })\n onScopeDispose(() => {\n window.removeEventListener('popstate', onPopstate)\n removeBefore?.()\n removeAfter?.()\n })\n }\n\n function onPopstate (e: PopStateEvent) {\n if (e.state?.replaced) return\n\n popped = true\n setTimeout(() => (popped = false))\n }\n}\n"],"mappings":"AAAA;AAAA,SACSA,kBAAkB,EAAEC,UAAU,EAAEC,YAAY;AACrD,SACEC,QAAQ,EACRC,QAAQ,EACRC,cAAc,EACdC,uBAAuB,EACvBC,KAAK,QACA,KAAK;;AAEZ;;AAYA,OAAO,SAASC,QAAQ,GAAoD;EAC1E,MAAMC,EAAE,GAAGT,kBAAkB,CAAC,UAAU,CAAC;EAEzC,OAAOG,QAAQ,CAAC;IAAA;IAAA,OAAMM,EAAE,iCAAFA,EAAE,CAAEC,KAAK,qBAAT,UAAWC,MAAM;EAAA,EAAC;AAC1C;AAEA,OAAO,SAASC,SAAS,GAAwB;EAAA;EAC/C,8BAAOZ,kBAAkB,CAAC,WAAW,CAAC,8CAA/B,oBAAiCU,KAAK,qBAAtC,sBAAwCG,OAAO;AACxD;AAeA,OAAO,SAASC,OAAO,CAAEC,KAAgB,EAAEC,KAA4B,EAAW;EAChF,MAAMC,UAAU,GAAGX,uBAAuB,CAAC,YAAY,CAAgC;EAEvF,MAAMY,MAAM,GAAGf,QAAQ,CAAC,MAAM,CAAC,EAAEY,KAAK,CAACI,IAAI,IAAIJ,KAAK,CAACK,EAAE,CAAC,CAAC;EACzD,MAAMC,WAAW,GAAGlB,QAAQ,CAAC,MAAM;IACjC,OAAO,CAAAe,MAAM,oBAANA,MAAM,CAAEI,KAAK,KAAI,CAAC,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AE;IACdG,QAAQ,CAAC,MAAM;MACbwC,MAAM,CAACC,gBAAgB,CAAC,UAAU,EAAEC,UAAU,CAAC;MAC/CJ,YAAY,GAAGH,MAAM,oBAANA,MAAM,CAAEQ,UAAU,CAAC,CAAC3B,EAAE,EAAE4B,IAAI,EAAEC,IAAI,KAAK;QACpD,IAAI,CAACZ,YAAY,EAAE;UACjBa,UAAU,CAAC,MAAMT,MAAM,GAAGD,EAAE,CAACS,IAAI,CAAC,GAAGA,IAAI,EAAE,CAAC;QAC9C,CAAC,MAAM;UACLR,MAAM,GAAGD,EAAE,CAACS,IAAI,CAAC,GAAGA,IAAI,EAAE;QAC5B;QACAZ,YAAY,GAAG,IAAI;MACrB,CAAC,CAAC;MACFM,WAAW,GAAGJ,MAAM,oBAANA,MAAM,CAAEY,SAAS,CAAC,MAAM;QACpCd,YAAY,GAAG,KAAK;MACtB,CAAC,CAAC;IACJ,CAAC,CAAC;IACFhC,cAAc,CAAC,MAAM;MAAA;MACnBuC,MAAM,CAACQ,mBAAmB,CAAC,UAAU,EAAEN,UAAU,CAAC;MAClD,iBAAAJ,YAAY,qBAAZ,eAAgB;MAChB,gBAAAC,WAAW,qBAAX,cAAe;IACjB,CAAC,CAAC;EACJ;EAEA,SAASG,UAAU,CAAEO,CAAgB,EAAE;IAAA;IACrC,gBAAIA,CAAC,CAACC,KAAK,aAAP,SAASC,QAAQ,EAAE;IAEvBd,MAAM,GAAG,IAAI;IACbS,UAAU,CAAC,MAAOT,MAAM,GAAG,KAAM,CAAC;EACpC;AACF"}
@@ -1 +1 @@
1
- {"version":3,"file":"scopeId.mjs","names":["getCurrentInstance","useScopeId","vm","scopeId","vnode","undefined"],"sources":["../../src/composables/scopeId.ts"],"sourcesContent":["import { getCurrentInstance } from '@/util'\n\nexport function useScopeId () {\n const vm = getCurrentInstance('useScopeId')\n\n const scopeId = vm!.vnode.scopeId\n\n return { scopeId: scopeId ? { [scopeId]: '' } : undefined }\n}\n"],"mappings":"SAASA,kB;AAET,OAAO,SAASC,UAAT,GAAuB;EAC5B,MAAMC,EAAE,GAAGF,kBAAkB,CAAC,YAAD,CAA7B;EAEA,MAAMG,OAAO,GAAGD,EAAE,CAAEE,KAAJ,CAAUD,OAA1B;EAEA,OAAO;IAAEA,OAAO,EAAEA,OAAO,GAAG;MAAE,CAACA,OAAD,GAAW;IAAb,CAAH,GAAuBE;EAAzC,CAAP;AACD"}
1
+ {"version":3,"file":"scopeId.mjs","names":["getCurrentInstance","useScopeId","vm","scopeId","vnode","undefined"],"sources":["../../src/composables/scopeId.ts"],"sourcesContent":["import { getCurrentInstance } from '@/util'\n\nexport function useScopeId () {\n const vm = getCurrentInstance('useScopeId')\n\n const scopeId = vm!.vnode.scopeId\n\n return { scopeId: scopeId ? { [scopeId]: '' } : undefined }\n}\n"],"mappings":"SAASA,kBAAkB;AAE3B,OAAO,SAASC,UAAU,GAAI;EAC5B,MAAMC,EAAE,GAAGF,kBAAkB,CAAC,YAAY,CAAC;EAE3C,MAAMG,OAAO,GAAGD,EAAE,CAAEE,KAAK,CAACD,OAAO;EAEjC,OAAO;IAAEA,OAAO,EAAEA,OAAO,GAAG;MAAE,CAACA,OAAO,GAAG;IAAG,CAAC,GAAGE;EAAU,CAAC;AAC7D"}
@@ -1,7 +1,6 @@
1
1
  // Utilities
2
2
  import { computed, getCurrentInstance, onBeforeUnmount, onMounted, ref, watch } from 'vue';
3
3
  import { consoleWarn, propsFactory } from "../util/index.mjs"; // Types
4
-
5
4
  // Composables
6
5
  export const makeScrollProps = propsFactory({
7
6
  scrollTarget: {
@@ -28,7 +27,6 @@ export function useScroll(props) {
28
27
  const computedScrollThreshold = computed(() => {
29
28
  return Number(props.scrollThreshold ?? scrollThreshold ?? 300);
30
29
  });
31
-
32
30
  const onScroll = () => {
33
31
  const targetEl = target.value;
34
32
  if (!targetEl || canScroll && !canScroll.value) return;
@@ -37,7 +35,6 @@ export function useScroll(props) {
37
35
  isScrollingUp.value = currentScroll.value < previousScroll;
38
36
  currentThreshold.value = Math.abs(currentScroll.value - computedScrollThreshold.value);
39
37
  };
40
-
41
38
  watch(isScrollingUp, () => {
42
39
  savedScroll.value = savedScroll.value || currentScroll.value;
43
40
  });
@@ -47,14 +44,11 @@ export function useScroll(props) {
47
44
  onMounted(() => {
48
45
  watch(() => props.scrollTarget, scrollTarget => {
49
46
  var _target$value;
50
-
51
47
  const newTarget = scrollTarget ? document.querySelector(scrollTarget) : window;
52
-
53
48
  if (!newTarget) {
54
49
  consoleWarn(`Unable to locate element with identifier ${scrollTarget}`, getCurrentInstance());
55
50
  return;
56
51
  }
57
-
58
52
  if (newTarget === target.value) return;
59
53
  (_target$value = target.value) == null ? void 0 : _target$value.removeEventListener('scroll', onScroll);
60
54
  target.value = newTarget;
@@ -67,7 +61,6 @@ export function useScroll(props) {
67
61
  });
68
62
  onBeforeUnmount(() => {
69
63
  var _target$value2;
70
-
71
64
  (_target$value2 = target.value) == null ? void 0 : _target$value2.removeEventListener('scroll', onScroll);
72
65
  });
73
66
  thresholdMetCallback && watch(() => Math.abs(currentScroll.value - savedScroll.value) > computedScrollThreshold.value, thresholdMet => {
@@ -78,9 +71,10 @@ export function useScroll(props) {
78
71
  });
79
72
  }, {
80
73
  immediate: true
81
- }); // Do we need this? If yes - seems that
82
- // there's no need to expose onScroll
74
+ });
83
75
 
76
+ // Do we need this? If yes - seems that
77
+ // there's no need to expose onScroll
84
78
  canScroll && watch(canScroll, onScroll, {
85
79
  immediate: true
86
80
  });