vectis-ui 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (676) hide show
  1. package/LICENSE +21 -0
  2. package/NOTICE +27 -0
  3. package/README.md +354 -0
  4. package/dist/_virtual/_plugin-vue_export-helper.js +8 -0
  5. package/dist/components/VAccordion/VAccordion.css +2 -0
  6. package/dist/components/VAccordion/VAccordion.d.ts +59 -0
  7. package/dist/components/VAccordion/VAccordion.js +9 -0
  8. package/dist/components/VAccordion/VAccordion.js.map +1 -0
  9. package/dist/components/VAccordion/VAccordion.vue_vue_type_script_setup_true_lang.js +42 -0
  10. package/dist/components/VAccordion/VAccordion.vue_vue_type_script_setup_true_lang.js.map +1 -0
  11. package/dist/components/VAccordion/VAccordionItem.css +2 -0
  12. package/dist/components/VAccordion/VAccordionItem.d.ts +64 -0
  13. package/dist/components/VAccordion/VAccordionItem.js +9 -0
  14. package/dist/components/VAccordion/VAccordionItem.js.map +1 -0
  15. package/dist/components/VAccordion/VAccordionItem.vue_vue_type_script_setup_true_lang.js +70 -0
  16. package/dist/components/VAccordion/VAccordionItem.vue_vue_type_script_setup_true_lang.js.map +1 -0
  17. package/dist/components/VAccordion/context.d.ts +18 -0
  18. package/dist/components/VAccordion/context.js +6 -0
  19. package/dist/components/VAccordion/context.js.map +1 -0
  20. package/dist/components/VAvatar/VAvatar.css +2 -0
  21. package/dist/components/VAvatar/VAvatar.d.ts +68 -0
  22. package/dist/components/VAvatar/VAvatar.js +9 -0
  23. package/dist/components/VAvatar/VAvatar.js.map +1 -0
  24. package/dist/components/VAvatar/VAvatar.vue_vue_type_script_setup_true_lang.js +87 -0
  25. package/dist/components/VAvatar/VAvatar.vue_vue_type_script_setup_true_lang.js.map +1 -0
  26. package/dist/components/VAvatar/VAvatarGroup.css +2 -0
  27. package/dist/components/VAvatar/VAvatarGroup.d.ts +59 -0
  28. package/dist/components/VAvatar/VAvatarGroup.js +9 -0
  29. package/dist/components/VAvatar/VAvatarGroup.js.map +1 -0
  30. package/dist/components/VAvatar/VAvatarGroup.vue_vue_type_script_setup_true_lang.js +43 -0
  31. package/dist/components/VAvatar/VAvatarGroup.vue_vue_type_script_setup_true_lang.js.map +1 -0
  32. package/dist/components/VAvatar/context.d.ts +17 -0
  33. package/dist/components/VAvatar/context.js +6 -0
  34. package/dist/components/VAvatar/context.js.map +1 -0
  35. package/dist/components/VBadge/VBadge.css +2 -0
  36. package/dist/components/VBadge/VBadge.d.ts +74 -0
  37. package/dist/components/VBadge/VBadge.js +9 -0
  38. package/dist/components/VBadge/VBadge.js.map +1 -0
  39. package/dist/components/VBadge/VBadge.vue_vue_type_script_setup_true_lang.js +40 -0
  40. package/dist/components/VBadge/VBadge.vue_vue_type_script_setup_true_lang.js.map +1 -0
  41. package/dist/components/VBreadcrumb/VBreadcrumb.css +2 -0
  42. package/dist/components/VBreadcrumb/VBreadcrumb.d.ts +68 -0
  43. package/dist/components/VBreadcrumb/VBreadcrumb.js +9 -0
  44. package/dist/components/VBreadcrumb/VBreadcrumb.js.map +1 -0
  45. package/dist/components/VBreadcrumb/VBreadcrumb.vue_vue_type_script_setup_true_lang.js +70 -0
  46. package/dist/components/VBreadcrumb/VBreadcrumb.vue_vue_type_script_setup_true_lang.js.map +1 -0
  47. package/dist/components/VButton/VButton.css +2 -0
  48. package/dist/components/VButton/VButton.d.ts +88 -0
  49. package/dist/components/VButton/VButton.js +9 -0
  50. package/dist/components/VButton/VButton.js.map +1 -0
  51. package/dist/components/VButton/VButton.vue_vue_type_script_setup_true_lang.js +86 -0
  52. package/dist/components/VButton/VButton.vue_vue_type_script_setup_true_lang.js.map +1 -0
  53. package/dist/components/VButton/VButtonGroup.css +2 -0
  54. package/dist/components/VButton/VButtonGroup.d.ts +32 -0
  55. package/dist/components/VButton/VButtonGroup.js +9 -0
  56. package/dist/components/VButton/VButtonGroup.js.map +1 -0
  57. package/dist/components/VButton/VButtonGroup.vue_vue_type_script_setup_true_lang.js +17 -0
  58. package/dist/components/VButton/VButtonGroup.vue_vue_type_script_setup_true_lang.js.map +1 -0
  59. package/dist/components/VCalendar/VCalendar.css +2 -0
  60. package/dist/components/VCalendar/VCalendar.d.ts +129 -0
  61. package/dist/components/VCalendar/VCalendar.js +9 -0
  62. package/dist/components/VCalendar/VCalendar.js.map +1 -0
  63. package/dist/components/VCalendar/VCalendar.vue_vue_type_script_setup_true_lang.js +374 -0
  64. package/dist/components/VCalendar/VCalendar.vue_vue_type_script_setup_true_lang.js.map +1 -0
  65. package/dist/components/VCalendar/VCalendarEvent.css +2 -0
  66. package/dist/components/VCalendar/VCalendarEvent.d.ts +71 -0
  67. package/dist/components/VCalendar/VCalendarEvent.js +9 -0
  68. package/dist/components/VCalendar/VCalendarEvent.js.map +1 -0
  69. package/dist/components/VCalendar/VCalendarEvent.vue_vue_type_script_setup_true_lang.js +106 -0
  70. package/dist/components/VCalendar/VCalendarEvent.vue_vue_type_script_setup_true_lang.js.map +1 -0
  71. package/dist/components/VCalendar/VCalendarMonth.css +2 -0
  72. package/dist/components/VCalendar/VCalendarMonth.d.ts +60 -0
  73. package/dist/components/VCalendar/VCalendarMonth.js +9 -0
  74. package/dist/components/VCalendar/VCalendarMonth.js.map +1 -0
  75. package/dist/components/VCalendar/VCalendarMonth.vue_vue_type_script_setup_true_lang.js +342 -0
  76. package/dist/components/VCalendar/VCalendarMonth.vue_vue_type_script_setup_true_lang.js.map +1 -0
  77. package/dist/components/VCalendar/VCalendarTimeGrid.css +2 -0
  78. package/dist/components/VCalendar/VCalendarTimeGrid.d.ts +85 -0
  79. package/dist/components/VCalendar/VCalendarTimeGrid.js +9 -0
  80. package/dist/components/VCalendar/VCalendarTimeGrid.js.map +1 -0
  81. package/dist/components/VCalendar/VCalendarTimeGrid.vue_vue_type_script_setup_true_lang.js +621 -0
  82. package/dist/components/VCalendar/VCalendarTimeGrid.vue_vue_type_script_setup_true_lang.js.map +1 -0
  83. package/dist/components/VCalendar/VCalendarYear.css +2 -0
  84. package/dist/components/VCalendar/VCalendarYear.d.ts +31 -0
  85. package/dist/components/VCalendar/VCalendarYear.js +9 -0
  86. package/dist/components/VCalendar/VCalendarYear.js.map +1 -0
  87. package/dist/components/VCalendar/VCalendarYear.vue_vue_type_script_setup_true_lang.js +76 -0
  88. package/dist/components/VCalendar/VCalendarYear.vue_vue_type_script_setup_true_lang.js.map +1 -0
  89. package/dist/components/VCalendar/color.d.ts +9 -0
  90. package/dist/components/VCalendar/color.js +9 -0
  91. package/dist/components/VCalendar/color.js.map +1 -0
  92. package/dist/components/VCalendar/edgeStep.d.ts +38 -0
  93. package/dist/components/VCalendar/edgeStep.js +28 -0
  94. package/dist/components/VCalendar/edgeStep.js.map +1 -0
  95. package/dist/components/VCalendar/keyboard.d.ts +78 -0
  96. package/dist/components/VCalendar/keyboard.js +86 -0
  97. package/dist/components/VCalendar/keyboard.js.map +1 -0
  98. package/dist/components/VCalendar/layout.d.ts +355 -0
  99. package/dist/components/VCalendar/layout.js +292 -0
  100. package/dist/components/VCalendar/layout.js.map +1 -0
  101. package/dist/components/VCalendar/types.d.ts +78 -0
  102. package/dist/components/VCarousel/VCarousel.css +2 -0
  103. package/dist/components/VCarousel/VCarousel.d.ts +241 -0
  104. package/dist/components/VCarousel/VCarousel.js +9 -0
  105. package/dist/components/VCarousel/VCarousel.js.map +1 -0
  106. package/dist/components/VCarousel/VCarousel.vue_vue_type_script_setup_true_lang.js +262 -0
  107. package/dist/components/VCarousel/VCarousel.vue_vue_type_script_setup_true_lang.js.map +1 -0
  108. package/dist/components/VCarousel/VCarouselItem.d.ts +41 -0
  109. package/dist/components/VCarousel/VCarouselItem.js +7 -0
  110. package/dist/components/VCarousel/VCarouselItem.js.map +1 -0
  111. package/dist/components/VCarousel/VCarouselItem.vue_vue_type_script_setup_true_lang.js +25 -0
  112. package/dist/components/VCarousel/VCarouselItem.vue_vue_type_script_setup_true_lang.js.map +1 -0
  113. package/dist/components/VCarousel/context.d.ts +23 -0
  114. package/dist/components/VCarousel/context.js +6 -0
  115. package/dist/components/VCarousel/context.js.map +1 -0
  116. package/dist/components/VCheckbox/VCheckbox.css +2 -0
  117. package/dist/components/VCheckbox/VCheckbox.d.ts +63 -0
  118. package/dist/components/VCheckbox/VCheckbox.js +9 -0
  119. package/dist/components/VCheckbox/VCheckbox.js.map +1 -0
  120. package/dist/components/VCheckbox/VCheckbox.vue_vue_type_script_setup_true_lang.js +83 -0
  121. package/dist/components/VCheckbox/VCheckbox.vue_vue_type_script_setup_true_lang.js.map +1 -0
  122. package/dist/components/VChip/VChip.css +2 -0
  123. package/dist/components/VChip/VChip.d.ts +120 -0
  124. package/dist/components/VChip/VChip.js +9 -0
  125. package/dist/components/VChip/VChip.js.map +1 -0
  126. package/dist/components/VChip/VChip.vue_vue_type_script_setup_true_lang.js +118 -0
  127. package/dist/components/VChip/VChip.vue_vue_type_script_setup_true_lang.js.map +1 -0
  128. package/dist/components/VCombobox/VCombobox.css +2 -0
  129. package/dist/components/VCombobox/VCombobox.d.ts +183 -0
  130. package/dist/components/VCombobox/VCombobox.js +9 -0
  131. package/dist/components/VCombobox/VCombobox.js.map +1 -0
  132. package/dist/components/VCombobox/VCombobox.vue_vue_type_script_setup_true_lang.js +428 -0
  133. package/dist/components/VCombobox/VCombobox.vue_vue_type_script_setup_true_lang.js.map +1 -0
  134. package/dist/components/VCombobox/VComboboxGroup.css +2 -0
  135. package/dist/components/VCombobox/VComboboxGroup.d.ts +26 -0
  136. package/dist/components/VCombobox/VComboboxGroup.js +9 -0
  137. package/dist/components/VCombobox/VComboboxGroup.js.map +1 -0
  138. package/dist/components/VCombobox/VComboboxGroup.vue_vue_type_script_setup_true_lang.js +21 -0
  139. package/dist/components/VCombobox/VComboboxGroup.vue_vue_type_script_setup_true_lang.js.map +1 -0
  140. package/dist/components/VCombobox/VComboboxOption.css +2 -0
  141. package/dist/components/VCombobox/VComboboxOption.d.ts +48 -0
  142. package/dist/components/VCombobox/VComboboxOption.js +9 -0
  143. package/dist/components/VCombobox/VComboboxOption.js.map +1 -0
  144. package/dist/components/VCombobox/VComboboxOption.vue_vue_type_script_setup_true_lang.js +56 -0
  145. package/dist/components/VCombobox/VComboboxOption.vue_vue_type_script_setup_true_lang.js.map +1 -0
  146. package/dist/components/VCombobox/VComboboxSeparator.css +2 -0
  147. package/dist/components/VCombobox/VComboboxSeparator.d.ts +3 -0
  148. package/dist/components/VCombobox/VComboboxSeparator.js +9 -0
  149. package/dist/components/VCombobox/VComboboxSeparator.js.map +1 -0
  150. package/dist/components/VCombobox/VComboboxSeparator.vue_vue_type_script_setup_true_lang.js +16 -0
  151. package/dist/components/VCombobox/VComboboxSeparator.vue_vue_type_script_setup_true_lang.js.map +1 -0
  152. package/dist/components/VCombobox/infiniteScroll.d.ts +22 -0
  153. package/dist/components/VCombobox/infiniteScroll.js +28 -0
  154. package/dist/components/VCombobox/infiniteScroll.js.map +1 -0
  155. package/dist/components/VDataTable/VDataTable.css +2 -0
  156. package/dist/components/VDataTable/VDataTable.d.ts +214 -0
  157. package/dist/components/VDataTable/VDataTable.js +9 -0
  158. package/dist/components/VDataTable/VDataTable.js.map +1 -0
  159. package/dist/components/VDataTable/VDataTable.vue_vue_type_script_setup_true_lang.js +396 -0
  160. package/dist/components/VDataTable/VDataTable.vue_vue_type_script_setup_true_lang.js.map +1 -0
  161. package/dist/components/VDateInput/VDateInput.css +2 -0
  162. package/dist/components/VDateInput/VDateInput.d.ts +152 -0
  163. package/dist/components/VDateInput/VDateInput.js +9 -0
  164. package/dist/components/VDateInput/VDateInput.js.map +1 -0
  165. package/dist/components/VDateInput/VDateInput.vue_vue_type_script_setup_true_lang.js +324 -0
  166. package/dist/components/VDateInput/VDateInput.vue_vue_type_script_setup_true_lang.js.map +1 -0
  167. package/dist/components/VDatePicker/VDatePicker.css +2 -0
  168. package/dist/components/VDatePicker/VDatePicker.d.ts +143 -0
  169. package/dist/components/VDatePicker/VDatePicker.js +9 -0
  170. package/dist/components/VDatePicker/VDatePicker.js.map +1 -0
  171. package/dist/components/VDatePicker/VDatePicker.vue_vue_type_script_setup_true_lang.js +454 -0
  172. package/dist/components/VDatePicker/VDatePicker.vue_vue_type_script_setup_true_lang.js.map +1 -0
  173. package/dist/components/VDatePicker/keyboard.d.ts +56 -0
  174. package/dist/components/VDatePicker/keyboard.js +26 -0
  175. package/dist/components/VDatePicker/keyboard.js.map +1 -0
  176. package/dist/components/VDialog/VDialog.css +2 -0
  177. package/dist/components/VDialog/VDialog.d.ts +96 -0
  178. package/dist/components/VDialog/VDialog.js +9 -0
  179. package/dist/components/VDialog/VDialog.js.map +1 -0
  180. package/dist/components/VDialog/VDialog.vue_vue_type_script_setup_true_lang.js +134 -0
  181. package/dist/components/VDialog/VDialog.vue_vue_type_script_setup_true_lang.js.map +1 -0
  182. package/dist/components/VDialog/VDialogAlert.d.ts +67 -0
  183. package/dist/components/VDialog/VDialogAlert.js +7 -0
  184. package/dist/components/VDialog/VDialogAlert.js.map +1 -0
  185. package/dist/components/VDialog/VDialogAlert.vue_vue_type_script_setup_true_lang.js +60 -0
  186. package/dist/components/VDialog/VDialogAlert.vue_vue_type_script_setup_true_lang.js.map +1 -0
  187. package/dist/components/VFileInput/VFileInput.css +2 -0
  188. package/dist/components/VFileInput/VFileInput.d.ts +156 -0
  189. package/dist/components/VFileInput/VFileInput.js +9 -0
  190. package/dist/components/VFileInput/VFileInput.js.map +1 -0
  191. package/dist/components/VFileInput/VFileInput.vue_vue_type_script_setup_true_lang.js +244 -0
  192. package/dist/components/VFileInput/VFileInput.vue_vue_type_script_setup_true_lang.js.map +1 -0
  193. package/dist/components/VFileInput/truncate.d.ts +29 -0
  194. package/dist/components/VFileInput/truncate.js +10 -0
  195. package/dist/components/VFileInput/truncate.js.map +1 -0
  196. package/dist/components/VFilePicker/VFilePicker.css +2 -0
  197. package/dist/components/VFilePicker/VFilePicker.d.ts +203 -0
  198. package/dist/components/VFilePicker/VFilePicker.js +9 -0
  199. package/dist/components/VFilePicker/VFilePicker.js.map +1 -0
  200. package/dist/components/VFilePicker/VFilePicker.vue_vue_type_script_setup_true_lang.js +266 -0
  201. package/dist/components/VFilePicker/VFilePicker.vue_vue_type_script_setup_true_lang.js.map +1 -0
  202. package/dist/components/VFilePicker/fileKind.d.ts +29 -0
  203. package/dist/components/VFilePicker/fileKind.js +91 -0
  204. package/dist/components/VFilePicker/fileKind.js.map +1 -0
  205. package/dist/components/VHotkeys/VHotkeys.css +2 -0
  206. package/dist/components/VHotkeys/VHotkeys.d.ts +100 -0
  207. package/dist/components/VHotkeys/VHotkeys.js +9 -0
  208. package/dist/components/VHotkeys/VHotkeys.js.map +1 -0
  209. package/dist/components/VHotkeys/VHotkeys.vue_vue_type_script_setup_true_lang.js +76 -0
  210. package/dist/components/VHotkeys/VHotkeys.vue_vue_type_script_setup_true_lang.js.map +1 -0
  211. package/dist/components/VHotkeys/platform.d.ts +82 -0
  212. package/dist/components/VHotkeys/platform.js +115 -0
  213. package/dist/components/VHotkeys/platform.js.map +1 -0
  214. package/dist/components/VIcon/VIcon.css +2 -0
  215. package/dist/components/VIcon/VIcon.d.ts +57 -0
  216. package/dist/components/VIcon/VIcon.js +9 -0
  217. package/dist/components/VIcon/VIcon.js.map +1 -0
  218. package/dist/components/VIcon/VIcon.vue_vue_type_script_setup_true_lang.js +99 -0
  219. package/dist/components/VIcon/VIcon.vue_vue_type_script_setup_true_lang.js.map +1 -0
  220. package/dist/components/VIcon/iconProps.d.ts +30 -0
  221. package/dist/components/VIcon/iconProps.js +6 -0
  222. package/dist/components/VIcon/iconProps.js.map +1 -0
  223. package/dist/components/VIcon/icons/arrow_downward.d.ts +5 -0
  224. package/dist/components/VIcon/icons/arrow_downward.js +9 -0
  225. package/dist/components/VIcon/icons/arrow_downward.js.map +1 -0
  226. package/dist/components/VIcon/icons/arrow_downward_alt.d.ts +5 -0
  227. package/dist/components/VIcon/icons/arrow_downward_alt.js +9 -0
  228. package/dist/components/VIcon/icons/arrow_downward_alt.js.map +1 -0
  229. package/dist/components/VIcon/icons/arrow_drop_down.d.ts +5 -0
  230. package/dist/components/VIcon/icons/arrow_drop_down.js +9 -0
  231. package/dist/components/VIcon/icons/arrow_drop_down.js.map +1 -0
  232. package/dist/components/VIcon/icons/arrow_drop_up.d.ts +5 -0
  233. package/dist/components/VIcon/icons/arrow_drop_up.js +9 -0
  234. package/dist/components/VIcon/icons/arrow_drop_up.js.map +1 -0
  235. package/dist/components/VIcon/icons/arrow_left_alt.d.ts +5 -0
  236. package/dist/components/VIcon/icons/arrow_left_alt.js +9 -0
  237. package/dist/components/VIcon/icons/arrow_left_alt.js.map +1 -0
  238. package/dist/components/VIcon/icons/arrow_right_alt.d.ts +5 -0
  239. package/dist/components/VIcon/icons/arrow_right_alt.js +9 -0
  240. package/dist/components/VIcon/icons/arrow_right_alt.js.map +1 -0
  241. package/dist/components/VIcon/icons/arrow_upward.d.ts +5 -0
  242. package/dist/components/VIcon/icons/arrow_upward.js +9 -0
  243. package/dist/components/VIcon/icons/arrow_upward.js.map +1 -0
  244. package/dist/components/VIcon/icons/arrow_upward_alt.d.ts +5 -0
  245. package/dist/components/VIcon/icons/arrow_upward_alt.js +9 -0
  246. package/dist/components/VIcon/icons/arrow_upward_alt.js.map +1 -0
  247. package/dist/components/VIcon/icons/attach_file.d.ts +5 -0
  248. package/dist/components/VIcon/icons/attach_file.js +9 -0
  249. package/dist/components/VIcon/icons/attach_file.js.map +1 -0
  250. package/dist/components/VIcon/icons/audio_file.d.ts +5 -0
  251. package/dist/components/VIcon/icons/audio_file.js +9 -0
  252. package/dist/components/VIcon/icons/audio_file.js.map +1 -0
  253. package/dist/components/VIcon/icons/calendar_today.d.ts +5 -0
  254. package/dist/components/VIcon/icons/calendar_today.js +9 -0
  255. package/dist/components/VIcon/icons/calendar_today.js.map +1 -0
  256. package/dist/components/VIcon/icons/check.d.ts +5 -0
  257. package/dist/components/VIcon/icons/check.js +9 -0
  258. package/dist/components/VIcon/icons/check.js.map +1 -0
  259. package/dist/components/VIcon/icons/check_circle.d.ts +5 -0
  260. package/dist/components/VIcon/icons/check_circle.js +9 -0
  261. package/dist/components/VIcon/icons/check_circle.js.map +1 -0
  262. package/dist/components/VIcon/icons/chevron_left.d.ts +5 -0
  263. package/dist/components/VIcon/icons/chevron_left.js +9 -0
  264. package/dist/components/VIcon/icons/chevron_left.js.map +1 -0
  265. package/dist/components/VIcon/icons/chevron_right.d.ts +5 -0
  266. package/dist/components/VIcon/icons/chevron_right.js +9 -0
  267. package/dist/components/VIcon/icons/chevron_right.js.map +1 -0
  268. package/dist/components/VIcon/icons/close.d.ts +5 -0
  269. package/dist/components/VIcon/icons/close.js +9 -0
  270. package/dist/components/VIcon/icons/close.js.map +1 -0
  271. package/dist/components/VIcon/icons/cloud_upload.d.ts +5 -0
  272. package/dist/components/VIcon/icons/cloud_upload.js +9 -0
  273. package/dist/components/VIcon/icons/cloud_upload.js.map +1 -0
  274. package/dist/components/VIcon/icons/code.d.ts +5 -0
  275. package/dist/components/VIcon/icons/code.js +9 -0
  276. package/dist/components/VIcon/icons/code.js.map +1 -0
  277. package/dist/components/VIcon/icons/description.d.ts +5 -0
  278. package/dist/components/VIcon/icons/description.js +9 -0
  279. package/dist/components/VIcon/icons/description.js.map +1 -0
  280. package/dist/components/VIcon/icons/error.d.ts +5 -0
  281. package/dist/components/VIcon/icons/error.js +9 -0
  282. package/dist/components/VIcon/icons/error.js.map +1 -0
  283. package/dist/components/VIcon/icons/expand_less.d.ts +5 -0
  284. package/dist/components/VIcon/icons/expand_less.js +9 -0
  285. package/dist/components/VIcon/icons/expand_less.js.map +1 -0
  286. package/dist/components/VIcon/icons/expand_more.d.ts +5 -0
  287. package/dist/components/VIcon/icons/expand_more.js +9 -0
  288. package/dist/components/VIcon/icons/expand_more.js.map +1 -0
  289. package/dist/components/VIcon/icons/folder_zip.d.ts +5 -0
  290. package/dist/components/VIcon/icons/folder_zip.js +9 -0
  291. package/dist/components/VIcon/icons/folder_zip.js.map +1 -0
  292. package/dist/components/VIcon/icons/image.d.ts +5 -0
  293. package/dist/components/VIcon/icons/image.js +9 -0
  294. package/dist/components/VIcon/icons/image.js.map +1 -0
  295. package/dist/components/VIcon/icons/index.d.ts +183 -0
  296. package/dist/components/VIcon/icons/index.js +77 -0
  297. package/dist/components/VIcon/icons/index.js.map +1 -0
  298. package/dist/components/VIcon/icons/info.d.ts +5 -0
  299. package/dist/components/VIcon/icons/info.js +9 -0
  300. package/dist/components/VIcon/icons/info.js.map +1 -0
  301. package/dist/components/VIcon/icons/more_horiz.d.ts +5 -0
  302. package/dist/components/VIcon/icons/more_horiz.js +9 -0
  303. package/dist/components/VIcon/icons/more_horiz.js.map +1 -0
  304. package/dist/components/VIcon/icons/names.d.ts +11 -0
  305. package/dist/components/VIcon/icons/names.js +5 -0
  306. package/dist/components/VIcon/icons/names.js.map +1 -0
  307. package/dist/components/VIcon/icons/notifications.d.ts +5 -0
  308. package/dist/components/VIcon/icons/notifications.js +9 -0
  309. package/dist/components/VIcon/icons/notifications.js.map +1 -0
  310. package/dist/components/VIcon/icons/picture_as_pdf.d.ts +5 -0
  311. package/dist/components/VIcon/icons/picture_as_pdf.js +9 -0
  312. package/dist/components/VIcon/icons/picture_as_pdf.js.map +1 -0
  313. package/dist/components/VIcon/icons/schedule.d.ts +5 -0
  314. package/dist/components/VIcon/icons/schedule.js +9 -0
  315. package/dist/components/VIcon/icons/schedule.js.map +1 -0
  316. package/dist/components/VIcon/icons/search.d.ts +5 -0
  317. package/dist/components/VIcon/icons/search.js +9 -0
  318. package/dist/components/VIcon/icons/search.js.map +1 -0
  319. package/dist/components/VIcon/icons/swap_vert.d.ts +5 -0
  320. package/dist/components/VIcon/icons/swap_vert.js +9 -0
  321. package/dist/components/VIcon/icons/swap_vert.js.map +1 -0
  322. package/dist/components/VIcon/icons/table_chart.d.ts +5 -0
  323. package/dist/components/VIcon/icons/table_chart.js +9 -0
  324. package/dist/components/VIcon/icons/table_chart.js.map +1 -0
  325. package/dist/components/VIcon/icons/video_file.d.ts +5 -0
  326. package/dist/components/VIcon/icons/video_file.js +9 -0
  327. package/dist/components/VIcon/icons/video_file.js.map +1 -0
  328. package/dist/components/VIcon/icons/viewBox.d.ts +6 -0
  329. package/dist/components/VIcon/icons/viewBox.js +6 -0
  330. package/dist/components/VIcon/icons/viewBox.js.map +1 -0
  331. package/dist/components/VIcon/icons/warning.d.ts +5 -0
  332. package/dist/components/VIcon/icons/warning.js +9 -0
  333. package/dist/components/VIcon/icons/warning.js.map +1 -0
  334. package/dist/components/VIcon/resolver.d.ts +76 -0
  335. package/dist/components/VIcon/resolver.js +35 -0
  336. package/dist/components/VIcon/resolver.js.map +1 -0
  337. package/dist/components/VIcon/types.d.ts +77 -0
  338. package/dist/components/VIconButton/VIconButton.css +2 -0
  339. package/dist/components/VIconButton/VIconButton.d.ts +66 -0
  340. package/dist/components/VIconButton/VIconButton.js +9 -0
  341. package/dist/components/VIconButton/VIconButton.js.map +1 -0
  342. package/dist/components/VIconButton/VIconButton.vue_vue_type_script_setup_true_lang.js +70 -0
  343. package/dist/components/VIconButton/VIconButton.vue_vue_type_script_setup_true_lang.js.map +1 -0
  344. package/dist/components/VInput/VInput.css +2 -0
  345. package/dist/components/VInput/VInput.d.ts +152 -0
  346. package/dist/components/VInput/VInput.js +9 -0
  347. package/dist/components/VInput/VInput.js.map +1 -0
  348. package/dist/components/VInput/VInput.vue_vue_type_script_setup_true_lang.js +185 -0
  349. package/dist/components/VInput/VInput.vue_vue_type_script_setup_true_lang.js.map +1 -0
  350. package/dist/components/VInputOTP/VInputOTP.css +2 -0
  351. package/dist/components/VInputOTP/VInputOTP.d.ts +76 -0
  352. package/dist/components/VInputOTP/VInputOTP.js +9 -0
  353. package/dist/components/VInputOTP/VInputOTP.js.map +1 -0
  354. package/dist/components/VInputOTP/VInputOTP.vue_vue_type_script_setup_true_lang.js +149 -0
  355. package/dist/components/VInputOTP/VInputOTP.vue_vue_type_script_setup_true_lang.js.map +1 -0
  356. package/dist/components/VMenu/VMenu.d.ts +91 -0
  357. package/dist/components/VMenu/VMenu.js +7 -0
  358. package/dist/components/VMenu/VMenu.js.map +1 -0
  359. package/dist/components/VMenu/VMenu.vue_vue_type_script_setup_true_lang.js +73 -0
  360. package/dist/components/VMenu/VMenu.vue_vue_type_script_setup_true_lang.js.map +1 -0
  361. package/dist/components/VMenu/VMenuGroup.css +2 -0
  362. package/dist/components/VMenu/VMenuGroup.d.ts +22 -0
  363. package/dist/components/VMenu/VMenuGroup.js +9 -0
  364. package/dist/components/VMenu/VMenuGroup.js.map +1 -0
  365. package/dist/components/VMenu/VMenuGroup.vue_vue_type_script_setup_true_lang.js +21 -0
  366. package/dist/components/VMenu/VMenuGroup.vue_vue_type_script_setup_true_lang.js.map +1 -0
  367. package/dist/components/VMenu/VMenuItem.css +2 -0
  368. package/dist/components/VMenu/VMenuItem.d.ts +85 -0
  369. package/dist/components/VMenu/VMenuItem.js +9 -0
  370. package/dist/components/VMenu/VMenuItem.js.map +1 -0
  371. package/dist/components/VMenu/VMenuItem.vue_vue_type_script_setup_true_lang.js +121 -0
  372. package/dist/components/VMenu/VMenuItem.vue_vue_type_script_setup_true_lang.js.map +1 -0
  373. package/dist/components/VMenu/VMenuPanel.css +2 -0
  374. package/dist/components/VMenu/VMenuPanel.d.ts +91 -0
  375. package/dist/components/VMenu/VMenuPanel.js +9 -0
  376. package/dist/components/VMenu/VMenuPanel.js.map +1 -0
  377. package/dist/components/VMenu/VMenuPanel.vue_vue_type_script_setup_true_lang.js +103 -0
  378. package/dist/components/VMenu/VMenuPanel.vue_vue_type_script_setup_true_lang.js.map +1 -0
  379. package/dist/components/VMenu/VMenuSeparator.css +2 -0
  380. package/dist/components/VMenu/VMenuSeparator.d.ts +3 -0
  381. package/dist/components/VMenu/VMenuSeparator.js +9 -0
  382. package/dist/components/VMenu/VMenuSeparator.js.map +1 -0
  383. package/dist/components/VMenu/VMenuSeparator.vue_vue_type_script_setup_true_lang.js +13 -0
  384. package/dist/components/VMenu/VMenuSeparator.vue_vue_type_script_setup_true_lang.js.map +1 -0
  385. package/dist/components/VMenu/context.d.ts +33 -0
  386. package/dist/components/VMenu/context.js +9 -0
  387. package/dist/components/VMenu/context.js.map +1 -0
  388. package/dist/components/VPagination/VPagination.css +2 -0
  389. package/dist/components/VPagination/VPagination.d.ts +103 -0
  390. package/dist/components/VPagination/VPagination.js +9 -0
  391. package/dist/components/VPagination/VPagination.js.map +1 -0
  392. package/dist/components/VPagination/VPagination.vue_vue_type_script_setup_true_lang.js +270 -0
  393. package/dist/components/VPagination/VPagination.vue_vue_type_script_setup_true_lang.js.map +1 -0
  394. package/dist/components/VPopover/VPopover.css +2 -0
  395. package/dist/components/VPopover/VPopover.d.ts +82 -0
  396. package/dist/components/VPopover/VPopover.js +9 -0
  397. package/dist/components/VPopover/VPopover.js.map +1 -0
  398. package/dist/components/VPopover/VPopover.vue_vue_type_script_setup_true_lang.js +65 -0
  399. package/dist/components/VPopover/VPopover.vue_vue_type_script_setup_true_lang.js.map +1 -0
  400. package/dist/components/VProgressCircular/VProgressCircular.css +2 -0
  401. package/dist/components/VProgressCircular/VProgressCircular.d.ts +60 -0
  402. package/dist/components/VProgressCircular/VProgressCircular.js +9 -0
  403. package/dist/components/VProgressCircular/VProgressCircular.js.map +1 -0
  404. package/dist/components/VProgressCircular/VProgressCircular.vue_vue_type_script_setup_true_lang.js +74 -0
  405. package/dist/components/VProgressCircular/VProgressCircular.vue_vue_type_script_setup_true_lang.js.map +1 -0
  406. package/dist/components/VProgressLinear/VProgressLinear.css +2 -0
  407. package/dist/components/VProgressLinear/VProgressLinear.d.ts +74 -0
  408. package/dist/components/VProgressLinear/VProgressLinear.js +9 -0
  409. package/dist/components/VProgressLinear/VProgressLinear.js.map +1 -0
  410. package/dist/components/VProgressLinear/VProgressLinear.vue_vue_type_script_setup_true_lang.js +74 -0
  411. package/dist/components/VProgressLinear/VProgressLinear.vue_vue_type_script_setup_true_lang.js.map +1 -0
  412. package/dist/components/VRadio/VRadio.css +2 -0
  413. package/dist/components/VRadio/VRadio.d.ts +58 -0
  414. package/dist/components/VRadio/VRadio.js +9 -0
  415. package/dist/components/VRadio/VRadio.js.map +1 -0
  416. package/dist/components/VRadio/VRadio.vue_vue_type_script_setup_true_lang.js +60 -0
  417. package/dist/components/VRadio/VRadio.vue_vue_type_script_setup_true_lang.js.map +1 -0
  418. package/dist/components/VSeparator/VSeparator.css +2 -0
  419. package/dist/components/VSeparator/VSeparator.d.ts +23 -0
  420. package/dist/components/VSeparator/VSeparator.js +9 -0
  421. package/dist/components/VSeparator/VSeparator.js.map +1 -0
  422. package/dist/components/VSeparator/VSeparator.vue_vue_type_script_setup_true_lang.js +17 -0
  423. package/dist/components/VSeparator/VSeparator.vue_vue_type_script_setup_true_lang.js.map +1 -0
  424. package/dist/components/VSideNavigation/VSideNavigation.css +2 -0
  425. package/dist/components/VSideNavigation/VSideNavigation.d.ts +64 -0
  426. package/dist/components/VSideNavigation/VSideNavigation.js +9 -0
  427. package/dist/components/VSideNavigation/VSideNavigation.js.map +1 -0
  428. package/dist/components/VSideNavigation/VSideNavigation.vue_vue_type_script_setup_true_lang.js +67 -0
  429. package/dist/components/VSideNavigation/VSideNavigation.vue_vue_type_script_setup_true_lang.js.map +1 -0
  430. package/dist/components/VSideNavigation/VSideNavigationGroup.css +2 -0
  431. package/dist/components/VSideNavigation/VSideNavigationGroup.d.ts +33 -0
  432. package/dist/components/VSideNavigation/VSideNavigationGroup.js +9 -0
  433. package/dist/components/VSideNavigation/VSideNavigationGroup.js.map +1 -0
  434. package/dist/components/VSideNavigation/VSideNavigationGroup.vue_vue_type_script_setup_true_lang.js +20 -0
  435. package/dist/components/VSideNavigation/VSideNavigationGroup.vue_vue_type_script_setup_true_lang.js.map +1 -0
  436. package/dist/components/VSideNavigation/VSideNavigationItem.css +2 -0
  437. package/dist/components/VSideNavigation/VSideNavigationItem.d.ts +103 -0
  438. package/dist/components/VSideNavigation/VSideNavigationItem.js +9 -0
  439. package/dist/components/VSideNavigation/VSideNavigationItem.js.map +1 -0
  440. package/dist/components/VSideNavigation/VSideNavigationItem.vue_vue_type_script_setup_true_lang.js +154 -0
  441. package/dist/components/VSideNavigation/VSideNavigationItem.vue_vue_type_script_setup_true_lang.js.map +1 -0
  442. package/dist/components/VSideNavigation/VSideNavigationSeparator.css +2 -0
  443. package/dist/components/VSideNavigation/VSideNavigationSeparator.d.ts +3 -0
  444. package/dist/components/VSideNavigation/VSideNavigationSeparator.js +17 -0
  445. package/dist/components/VSideNavigation/VSideNavigationSeparator.js.map +1 -0
  446. package/dist/components/VSideNavigation/context.d.ts +37 -0
  447. package/dist/components/VSideNavigation/context.js +6 -0
  448. package/dist/components/VSideNavigation/context.js.map +1 -0
  449. package/dist/components/VSkeletonLoader/VSkeletonLoader.css +2 -0
  450. package/dist/components/VSkeletonLoader/VSkeletonLoader.d.ts +75 -0
  451. package/dist/components/VSkeletonLoader/VSkeletonLoader.js +9 -0
  452. package/dist/components/VSkeletonLoader/VSkeletonLoader.js.map +1 -0
  453. package/dist/components/VSkeletonLoader/VSkeletonLoader.vue_vue_type_script_setup_true_lang.js +61 -0
  454. package/dist/components/VSkeletonLoader/VSkeletonLoader.vue_vue_type_script_setup_true_lang.js.map +1 -0
  455. package/dist/components/VSlider/VSlider.css +2 -0
  456. package/dist/components/VSlider/VSlider.d.ts +82 -0
  457. package/dist/components/VSlider/VSlider.js +9 -0
  458. package/dist/components/VSlider/VSlider.js.map +1 -0
  459. package/dist/components/VSlider/VSlider.vue_vue_type_script_setup_true_lang.js +220 -0
  460. package/dist/components/VSlider/VSlider.vue_vue_type_script_setup_true_lang.js.map +1 -0
  461. package/dist/components/VSnackbar/VSnackbar.css +2 -0
  462. package/dist/components/VSnackbar/VSnackbar.d.ts +51 -0
  463. package/dist/components/VSnackbar/VSnackbar.js +9 -0
  464. package/dist/components/VSnackbar/VSnackbar.js.map +1 -0
  465. package/dist/components/VSnackbar/VSnackbar.vue_vue_type_script_setup_true_lang.js +83 -0
  466. package/dist/components/VSnackbar/VSnackbar.vue_vue_type_script_setup_true_lang.js.map +1 -0
  467. package/dist/components/VSnackbar/state.d.ts +92 -0
  468. package/dist/components/VSnackbar/state.js +18 -0
  469. package/dist/components/VSnackbar/state.js.map +1 -0
  470. package/dist/components/VSpinner/VSpinner.css +2 -0
  471. package/dist/components/VSpinner/VSpinner.d.ts +21 -0
  472. package/dist/components/VSpinner/VSpinner.js +9 -0
  473. package/dist/components/VSpinner/VSpinner.js.map +1 -0
  474. package/dist/components/VSpinner/VSpinner.vue_vue_type_script_setup_true_lang.js +25 -0
  475. package/dist/components/VSpinner/VSpinner.vue_vue_type_script_setup_true_lang.js.map +1 -0
  476. package/dist/components/VSwitch/VSwitch.css +2 -0
  477. package/dist/components/VSwitch/VSwitch.d.ts +46 -0
  478. package/dist/components/VSwitch/VSwitch.js +9 -0
  479. package/dist/components/VSwitch/VSwitch.js.map +1 -0
  480. package/dist/components/VSwitch/VSwitch.vue_vue_type_script_setup_true_lang.js +51 -0
  481. package/dist/components/VSwitch/VSwitch.vue_vue_type_script_setup_true_lang.js.map +1 -0
  482. package/dist/components/VTabs/VTab.css +2 -0
  483. package/dist/components/VTabs/VTab.d.ts +42 -0
  484. package/dist/components/VTabs/VTab.js +9 -0
  485. package/dist/components/VTabs/VTab.js.map +1 -0
  486. package/dist/components/VTabs/VTab.vue_vue_type_script_setup_true_lang.js +66 -0
  487. package/dist/components/VTabs/VTab.vue_vue_type_script_setup_true_lang.js.map +1 -0
  488. package/dist/components/VTabs/VTabPanel.css +2 -0
  489. package/dist/components/VTabs/VTabPanel.d.ts +34 -0
  490. package/dist/components/VTabs/VTabPanel.js +9 -0
  491. package/dist/components/VTabs/VTabPanel.js.map +1 -0
  492. package/dist/components/VTabs/VTabPanel.vue_vue_type_script_setup_true_lang.js +34 -0
  493. package/dist/components/VTabs/VTabPanel.vue_vue_type_script_setup_true_lang.js.map +1 -0
  494. package/dist/components/VTabs/VTabs.css +2 -0
  495. package/dist/components/VTabs/VTabs.d.ts +107 -0
  496. package/dist/components/VTabs/VTabs.js +9 -0
  497. package/dist/components/VTabs/VTabs.js.map +1 -0
  498. package/dist/components/VTabs/VTabs.vue_vue_type_script_setup_true_lang.js +199 -0
  499. package/dist/components/VTabs/VTabs.vue_vue_type_script_setup_true_lang.js.map +1 -0
  500. package/dist/components/VTabs/context.d.ts +43 -0
  501. package/dist/components/VTabs/context.js +6 -0
  502. package/dist/components/VTabs/context.js.map +1 -0
  503. package/dist/components/VTextarea/VTextarea.css +2 -0
  504. package/dist/components/VTextarea/VTextarea.d.ts +140 -0
  505. package/dist/components/VTextarea/VTextarea.js +9 -0
  506. package/dist/components/VTextarea/VTextarea.js.map +1 -0
  507. package/dist/components/VTextarea/VTextarea.vue_vue_type_script_setup_true_lang.js +187 -0
  508. package/dist/components/VTextarea/VTextarea.vue_vue_type_script_setup_true_lang.js.map +1 -0
  509. package/dist/components/VTimeInput/VTimeInput.css +2 -0
  510. package/dist/components/VTimeInput/VTimeInput.d.ts +112 -0
  511. package/dist/components/VTimeInput/VTimeInput.js +9 -0
  512. package/dist/components/VTimeInput/VTimeInput.js.map +1 -0
  513. package/dist/components/VTimeInput/VTimeInput.vue_vue_type_script_setup_true_lang.js +385 -0
  514. package/dist/components/VTimeInput/VTimeInput.vue_vue_type_script_setup_true_lang.js.map +1 -0
  515. package/dist/components/VTimePicker/VTimePicker.css +2 -0
  516. package/dist/components/VTimePicker/VTimePicker.d.ts +89 -0
  517. package/dist/components/VTimePicker/VTimePicker.js +9 -0
  518. package/dist/components/VTimePicker/VTimePicker.js.map +1 -0
  519. package/dist/components/VTimePicker/VTimePicker.vue_vue_type_script_setup_true_lang.js +257 -0
  520. package/dist/components/VTimePicker/VTimePicker.vue_vue_type_script_setup_true_lang.js.map +1 -0
  521. package/dist/components/VToast/VToast.css +2 -0
  522. package/dist/components/VToast/VToast.d.ts +24 -0
  523. package/dist/components/VToast/VToast.js +9 -0
  524. package/dist/components/VToast/VToast.js.map +1 -0
  525. package/dist/components/VToast/VToast.vue_vue_type_script_setup_true_lang.js +62 -0
  526. package/dist/components/VToast/VToast.vue_vue_type_script_setup_true_lang.js.map +1 -0
  527. package/dist/components/VToast/VToaster.css +2 -0
  528. package/dist/components/VToast/VToaster.d.ts +42 -0
  529. package/dist/components/VToast/VToaster.js +9 -0
  530. package/dist/components/VToast/VToaster.js.map +1 -0
  531. package/dist/components/VToast/VToaster.vue_vue_type_script_setup_true_lang.js +112 -0
  532. package/dist/components/VToast/VToaster.vue_vue_type_script_setup_true_lang.js.map +1 -0
  533. package/dist/components/VToast/state.d.ts +74 -0
  534. package/dist/components/VToast/state.js +25 -0
  535. package/dist/components/VToast/state.js.map +1 -0
  536. package/dist/components/VToggle/VToggle.css +2 -0
  537. package/dist/components/VToggle/VToggle.d.ts +84 -0
  538. package/dist/components/VToggle/VToggle.js +9 -0
  539. package/dist/components/VToggle/VToggle.js.map +1 -0
  540. package/dist/components/VToggle/VToggle.vue_vue_type_script_setup_true_lang.js +103 -0
  541. package/dist/components/VToggle/VToggle.vue_vue_type_script_setup_true_lang.js.map +1 -0
  542. package/dist/components/VToggle/VToggleItem.css +2 -0
  543. package/dist/components/VToggle/VToggleItem.d.ts +35 -0
  544. package/dist/components/VToggle/VToggleItem.js +9 -0
  545. package/dist/components/VToggle/VToggleItem.js.map +1 -0
  546. package/dist/components/VToggle/VToggleItem.vue_vue_type_script_setup_true_lang.js +51 -0
  547. package/dist/components/VToggle/VToggleItem.vue_vue_type_script_setup_true_lang.js.map +1 -0
  548. package/dist/components/VToggle/context.d.ts +37 -0
  549. package/dist/components/VToggle/context.js +6 -0
  550. package/dist/components/VToggle/context.js.map +1 -0
  551. package/dist/components/VTooltip/VTooltip.css +2 -0
  552. package/dist/components/VTooltip/VTooltip.d.ts +76 -0
  553. package/dist/components/VTooltip/VTooltip.js +9 -0
  554. package/dist/components/VTooltip/VTooltip.js.map +1 -0
  555. package/dist/components/VTooltip/VTooltip.vue_vue_type_script_setup_true_lang.js +50 -0
  556. package/dist/components/VTooltip/VTooltip.vue_vue_type_script_setup_true_lang.js.map +1 -0
  557. package/dist/components/VTypography/VTypography.css +2 -0
  558. package/dist/components/VTypography/VTypography.d.ts +46 -0
  559. package/dist/components/VTypography/VTypography.js +9 -0
  560. package/dist/components/VTypography/VTypography.js.map +1 -0
  561. package/dist/components/VTypography/VTypography.vue_vue_type_script_setup_true_lang.js +49 -0
  562. package/dist/components/VTypography/VTypography.vue_vue_type_script_setup_true_lang.js.map +1 -0
  563. package/dist/composables/useAriaLabel.d.ts +19 -0
  564. package/dist/composables/useAriaLabel.js +10 -0
  565. package/dist/composables/useAriaLabel.js.map +1 -0
  566. package/dist/composables/useFieldIds.d.ts +21 -0
  567. package/dist/composables/useFieldIds.js +14 -0
  568. package/dist/composables/useFieldIds.js.map +1 -0
  569. package/dist/composables/useFieldPanel.d.ts +61 -0
  570. package/dist/composables/useFieldPanel.js +39 -0
  571. package/dist/composables/useFieldPanel.js.map +1 -0
  572. package/dist/composables/useFileDrop.d.ts +30 -0
  573. package/dist/composables/useFileDrop.js +28 -0
  574. package/dist/composables/useFileDrop.js.map +1 -0
  575. package/dist/composables/useFileField.d.ts +36 -0
  576. package/dist/composables/useFileField.js +45 -0
  577. package/dist/composables/useFileField.js.map +1 -0
  578. package/dist/composables/useFocusoutDismiss.d.ts +17 -0
  579. package/dist/composables/useFocusoutDismiss.js +11 -0
  580. package/dist/composables/useFocusoutDismiss.js.map +1 -0
  581. package/dist/composables/useIconClickHandlers.d.ts +27 -0
  582. package/dist/composables/useIconClickHandlers.js +13 -0
  583. package/dist/composables/useIconClickHandlers.js.map +1 -0
  584. package/dist/composables/useMaskedField.d.ts +65 -0
  585. package/dist/composables/useMaskedField.js +54 -0
  586. package/dist/composables/useMaskedField.js.map +1 -0
  587. package/dist/composables/usePopover.d.ts +7 -0
  588. package/dist/composables/usePopover.js +24 -0
  589. package/dist/composables/usePopover.js.map +1 -0
  590. package/dist/composables/useProgressValue.d.ts +13 -0
  591. package/dist/composables/useProgressValue.js +14 -0
  592. package/dist/composables/useProgressValue.js.map +1 -0
  593. package/dist/composables/useRootAttrs.d.ts +34 -0
  594. package/dist/composables/useRootAttrs.js +15 -0
  595. package/dist/composables/useRootAttrs.js.map +1 -0
  596. package/dist/composables/useTextLimit.d.ts +31 -0
  597. package/dist/composables/useTextLimit.js +19 -0
  598. package/dist/composables/useTextLimit.js.map +1 -0
  599. package/dist/composables/useTimer.d.ts +18 -0
  600. package/dist/composables/useTimer.js +19 -0
  601. package/dist/composables/useTimer.js.map +1 -0
  602. package/dist/i18n/en.d.ts +10 -0
  603. package/dist/i18n/en.js +179 -0
  604. package/dist/i18n/en.js.map +1 -0
  605. package/dist/i18n/fr.d.ts +18 -0
  606. package/dist/i18n/fr.js +179 -0
  607. package/dist/i18n/fr.js.map +1 -0
  608. package/dist/i18n/state.d.ts +64 -0
  609. package/dist/i18n/state.js +40 -0
  610. package/dist/i18n/state.js.map +1 -0
  611. package/dist/i18n/types.d.ts +345 -0
  612. package/dist/icons.d.ts +16 -0
  613. package/dist/icons.js +38 -0
  614. package/dist/index.d.ts +90 -0
  615. package/dist/index.js +64 -0
  616. package/dist/styles.css +1 -0
  617. package/dist/tokens/css.d.ts +25 -0
  618. package/dist/tokens/css.js +29 -0
  619. package/dist/tokens/css.js.map +1 -0
  620. package/dist/tokens/index.d.ts +370 -0
  621. package/dist/tokens/index.js +15 -0
  622. package/dist/tokens/index.js.map +1 -0
  623. package/dist/tokens/primitives.d.ts +101 -0
  624. package/dist/tokens/primitives.js +166 -0
  625. package/dist/tokens/primitives.js.map +1 -0
  626. package/dist/tokens/semantic.d.ts +236 -0
  627. package/dist/tokens/semantic.js +219 -0
  628. package/dist/tokens/semantic.js.map +1 -0
  629. package/dist/tokens/themes/dark.d.ts +49 -0
  630. package/dist/tokens/themes/dark.js +53 -0
  631. package/dist/tokens/themes/dark.js.map +1 -0
  632. package/dist/tokens/types.d.ts +38 -0
  633. package/dist/tokens/types.js +16 -0
  634. package/dist/tokens/types.js.map +1 -0
  635. package/dist/tokens.json +1516 -0
  636. package/dist/utils/array.d.ts +10 -0
  637. package/dist/utils/array.js +8 -0
  638. package/dist/utils/array.js.map +1 -0
  639. package/dist/utils/arrowNav.d.ts +27 -0
  640. package/dist/utils/arrowNav.js +26 -0
  641. package/dist/utils/arrowNav.js.map +1 -0
  642. package/dist/utils/chip.d.ts +26 -0
  643. package/dist/utils/chip.js +13 -0
  644. package/dist/utils/chip.js.map +1 -0
  645. package/dist/utils/css.d.ts +19 -0
  646. package/dist/utils/css.js +13 -0
  647. package/dist/utils/css.js.map +1 -0
  648. package/dist/utils/date.d.ts +199 -0
  649. package/dist/utils/date.js +225 -0
  650. package/dist/utils/date.js.map +1 -0
  651. package/dist/utils/direction.d.ts +18 -0
  652. package/dist/utils/direction.js +8 -0
  653. package/dist/utils/direction.js.map +1 -0
  654. package/dist/utils/env.d.ts +10 -0
  655. package/dist/utils/file.d.ts +95 -0
  656. package/dist/utils/file.js +70 -0
  657. package/dist/utils/file.js.map +1 -0
  658. package/dist/utils/focus.d.ts +24 -0
  659. package/dist/utils/focus.js +13 -0
  660. package/dist/utils/focus.js.map +1 -0
  661. package/dist/utils/matcher.d.ts +13 -0
  662. package/dist/utils/matcher.js +11 -0
  663. package/dist/utils/matcher.js.map +1 -0
  664. package/dist/utils/number.d.ts +9 -0
  665. package/dist/utils/number.js +8 -0
  666. package/dist/utils/number.js.map +1 -0
  667. package/dist/utils/text.d.ts +19 -0
  668. package/dist/utils/text.js +12 -0
  669. package/dist/utils/text.js.map +1 -0
  670. package/dist/utils/time.d.ts +138 -0
  671. package/dist/utils/time.js +123 -0
  672. package/dist/utils/time.js.map +1 -0
  673. package/dist/utils/vnode.d.ts +21 -0
  674. package/dist/utils/vnode.js +14 -0
  675. package/dist/utils/vnode.js.map +1 -0
  676. package/package.json +114 -0
@@ -0,0 +1,51 @@
1
+ import { SnackbarPlacement } from './state.js';
2
+ /**
3
+ * Where confirmations appear. It is mounted ONCE, at the root of the application, and
4
+ * from then on any call to `snackbar()` shows up here.
5
+ *
6
+ * A confirmation is the short answer to something the reader has just done — "Message
7
+ * deleted", "Settings saved" — usually with one button to take it back. That is a
8
+ * different job from a notification, which reports a state, and the differences are
9
+ * deliberate rather than a matter of styling: there is only ever ONE bar at a time,
10
+ * always along the bottom edge, it carries no close cross, and it leaves on its own after
11
+ * a few seconds. Two of those follow from the same idea: only the LAST thing a reader did
12
+ * is worth offering to undo, so a queue would hand out buttons about actions already
13
+ * forgotten, and a cross would ask them to tidy up after a message that tidies itself.
14
+ *
15
+ * Because there is only one, this is a single file where the notifications need two: one
16
+ * container, one card, and no book-keeping to tell several countdowns apart.
17
+ *
18
+ * The JavaScript covers three things the platform does not: putting the state and the
19
+ * container in step, since drawing above the page can only be asked for by calling a
20
+ * method; the countdown that takes the bar away when its time is up; and holding that
21
+ * countdown while the reader is resting the pointer on the bar OR has moved the keyboard
22
+ * into it, so that something disappearing on a clock can be held long enough to read and
23
+ * to act on (WCAG 2.2.1).
24
+ */
25
+ interface SnackbarProps {
26
+ /** Which end of the bottom edge confirmations appear at, unless one of them asks for another. */
27
+ placement?: SnackbarPlacement;
28
+ /**
29
+ * How long a confirmation stays, in milliseconds, unless it asks for something else. A
30
+ * confirmation given 0 stays until it is replaced or taken away by hand.
31
+ */
32
+ duration?: number;
33
+ /**
34
+ * What the single action is called, when the confirmation does not name it. It falls
35
+ * back to the design system dictionary.
36
+ */
37
+ actionLabel?: string;
38
+ /**
39
+ * What screen readers announce for the confirmation area itself, which is a landmark of
40
+ * the page. It falls back to the design system dictionary.
41
+ */
42
+ label?: string;
43
+ }
44
+ declare const __VLS_export: import('vue').DefineComponent<SnackbarProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<SnackbarProps> & Readonly<{}>, {
45
+ label: string;
46
+ placement: SnackbarPlacement;
47
+ duration: number;
48
+ actionLabel: string;
49
+ }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
50
+ declare const _default: typeof __VLS_export;
51
+ export default _default;
@@ -0,0 +1,9 @@
1
+ import './VSnackbar.css';
2
+ import e from "./VSnackbar.vue_vue_type_script_setup_true_lang.js";
3
+ /* empty css */
4
+ //#region src/components/VSnackbar/VSnackbar.vue
5
+ var t = e;
6
+ //#endregion
7
+ export { t as default };
8
+
9
+ //# sourceMappingURL=VSnackbar.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"VSnackbar.js","names":[],"sources":["../../../src/components/VSnackbar/VSnackbar.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport { computed, onMounted, ref, watch } from 'vue'\n\nimport { usePopover } from '../../composables/usePopover'\nimport { useTimer } from '../../composables/useTimer'\nimport { useAriaLabel } from '../../composables/useAriaLabel'\nimport { useMessages } from '../../i18n/state'\nimport VButton from '../VButton/VButton.vue'\nimport VIcon from '../VIcon/VIcon.vue'\nimport { iconProps } from '../VIcon/iconProps'\nimport { current, dismissSnackbar, type SnackbarPlacement } from './state'\n\n// @a11y @core\n/**\n * Where confirmations appear. It is mounted ONCE, at the root of the application, and\n * from then on any call to `snackbar()` shows up here.\n *\n * A confirmation is the short answer to something the reader has just done — \"Message\n * deleted\", \"Settings saved\" — usually with one button to take it back. That is a\n * different job from a notification, which reports a state, and the differences are\n * deliberate rather than a matter of styling: there is only ever ONE bar at a time,\n * always along the bottom edge, it carries no close cross, and it leaves on its own after\n * a few seconds. Two of those follow from the same idea: only the LAST thing a reader did\n * is worth offering to undo, so a queue would hand out buttons about actions already\n * forgotten, and a cross would ask them to tidy up after a message that tidies itself.\n *\n * Because there is only one, this is a single file where the notifications need two: one\n * container, one card, and no book-keeping to tell several countdowns apart.\n *\n * The JavaScript covers three things the platform does not: putting the state and the\n * container in step, since drawing above the page can only be asked for by calling a\n * method; the countdown that takes the bar away when its time is up; and holding that\n * countdown while the reader is resting the pointer on the bar OR has moved the keyboard\n * into it, so that something disappearing on a clock can be held long enough to read and\n * to act on (WCAG 2.2.1).\n */\ninterface SnackbarProps {\n /** Which end of the bottom edge confirmations appear at, unless one of them asks for another. */\n placement?: SnackbarPlacement\n /**\n * How long a confirmation stays, in milliseconds, unless it asks for something else. A\n * confirmation given 0 stays until it is replaced or taken away by hand.\n */\n duration?: number\n /**\n * What the single action is called, when the confirmation does not name it. It falls\n * back to the design system dictionary.\n */\n actionLabel?: string\n /**\n * What screen readers announce for the confirmation area itself, which is a landmark of\n * the page. It falls back to the design system dictionary.\n */\n label?: string\n}\n\nconst props = withDefaults(defineProps<SnackbarProps>(), {\n placement: 'bottom-center',\n /* Shorter than a notification's five seconds. A confirmation is one short sentence\n about something the reader has just done, so they already know what it says. */\n duration: 4000,\n actionLabel: undefined,\n label: undefined,\n})\n\nconst m = useMessages()\nconst ariaLabel = useAriaLabel(() => props.label ?? m.value.snackbar.label)\n\nconst item = computed(() => current.value)\nconst placement = computed(() => item.value?.placement ?? props.placement)\n/* A failure interrupts whatever a screen reader is saying; a plain confirmation waits for\n a pause, the reader having asked for the action it reports. */\nconst role = computed(() => (item.value?.tone === 'danger' ? 'alert' : 'status'))\nconst actionLabel = computed(\n () => item.value?.actionLabel ?? props.actionLabel ?? m.value.snackbar.action,\n)\nconst icon = computed(() => (item.value?.icon ? iconProps(item.value.icon) : undefined))\n\nconst hostEl = ref<HTMLElement | null>(null)\nconst { syncShown, show, hide } = usePopover(hostEl)\nconst { start, cancel } = useTimer()\n\n/* The reasons to hold the countdown, each set by its own pair of events. They are two\n separate flags rather than one counter because they can be true at the same time and\n end independently: a reader tabs to the action button, then moves the mouse over the\n bar, then moves it away — and the bar must not leave while the button still has focus. */\nlet hovered = false\nlet focused = false\n\nfunction arm() {\n const bar = item.value\n if (!bar || hovered || focused) return\n const duration = bar.duration ?? props.duration\n /* GUARD, not a default: `useTimer` runs a delay of 0 SYNCHRONOUSLY, which is the design\n system's convention for \"no deferral at all\". Without this test a confirmation asking\n to be permanent would be taken away in the same tick it was raised. */\n if (duration > 0) start(() => dismissSnackbar(bar.id), duration)\n}\n\n// @core\n/**\n * Brings the page into line with the state: it shows the container when there is a\n * confirmation and hides it when there is none, and restarts the countdown from the top.\n *\n * Restarting unconditionally is what makes a replacement correct — the outgoing bar's\n * countdown must not be allowed to take the incoming one away — and it is safe precisely\n * because this runs only when the bar itself changes.\n *\n * It runs once on mount, which is what makes a confirmation raised before this component\n * existed appear all the same, and after that on every change.\n */\nfunction sync() {\n cancel()\n // Showing and hiding are safe to call on a container already in that state, the guards\n // living in the popover plumbing — so there is no need to remember which it is in.\n if (item.value) show()\n else hide()\n arm()\n}\n\n/*\n * Watching the resolved bar covers a change of confirmation AND its disappearance. The\n * `post` timing is load-bearing: the card must already be in the page before its container\n * is told to show itself.\n */\nwatch(item, sync, { flush: 'post' })\n// @ssr — a watcher does not run during the server render, so a confirmation raised before\n// this component mounted would never be picked up. Running the same synchronization on\n// mount is what brings it in.\nonMounted(sync)\n\n// @a11y — WCAG 2.2.1: something that disappears on a clock has to be holdable, or a slow\n// reader simply never finishes it — and here they would also never reach the button.\n/*\n * Resting the pointer on the bar suspends its countdown, and so does moving the keyboard\n * into it. The focus half is what the notifications do not need and this cannot do\n * without: the action is a real button, so a reader tabbing towards it would otherwise\n * watch it vanish from under the focus ring.\n *\n * Any focus counts, not just a keyboard one: a pointer landing on the button is about to\n * run the action anyway, so there is nothing to lose by holding as well.\n *\n * Leaving restarts the countdown from the FULL duration rather than from what was left:\n * simpler, and more generous to the reader who has just interrupted themselves.\n */\nfunction hold(which: 'pointer' | 'focus') {\n if (which === 'pointer') hovered = true\n else focused = true\n cancel()\n}\n\nfunction release(which: 'pointer' | 'focus') {\n if (which === 'pointer') hovered = false\n else focused = false\n arm()\n}\n\n/* The action always takes the bar away: it answers the confirmation, so leaving it on\n screen would invite the reader to answer it twice. */\nfunction runAction() {\n const bar = item.value\n if (!bar) return\n bar.action?.()\n dismissSnackbar(bar.id)\n}\n</script>\n\n<template>\n <div\n ref=\"hostEl\"\n class=\"v-overlay v-snackbar-host\"\n popover=\"manual\"\n :data-placement=\"placement\"\n role=\"region\"\n :aria-label=\"ariaLabel\"\n @pointerenter=\"hold('pointer')\"\n @pointerleave=\"release('pointer')\"\n @focusin=\"hold('focus')\"\n @focusout=\"release('focus')\"\n @beforetoggle=\"syncShown\"\n @toggle=\"syncShown\"\n >\n <div\n v-if=\"item\"\n :key=\"item.id\"\n class=\"v-banner v-snackbar v-tone\"\n :data-tone=\"item.tone\"\n :role=\"role\"\n >\n <VIcon v-if=\"icon\" class=\"v-snackbar-icon\" v-bind=\"icon\" />\n <p class=\"v-snackbar-message\">{{ item.message }}</p>\n <VButton\n v-if=\"item.action\"\n class=\"v-snackbar-action\"\n variant=\"ghost\"\n tone=\"neutral\"\n size=\"sm\"\n @click=\"runAction\"\n >\n {{ actionLabel }}\n </VButton>\n </div>\n </div>\n</template>\n\n<style>\n@layer vectis.components {\n /* The fixed positioning and the guard hiding a closed container come from the shared\n `.v-overlay` class, set on this same element. What stays here is the browser's own\n popover decoration to undo — its border, its padding, its opaque background. */\n .v-snackbar-host {\n margin: 0;\n border: none;\n padding: 0;\n background: transparent;\n overflow: visible;\n width: fit-content;\n bottom: var(--vectis-space-4);\n /* The direction the bar slides in from, read by `.v-banner` in styles/banner.css.\n Always positive: this container only ever sits along the bottom edge. */\n --banner-enter-y: var(--vectis-space-4);\n }\n\n /*\n * These coordinates are deliberately PHYSICAL rather than logical: a confirmation\n * appears at a place on the screen, and that place does not flip with the reading\n * direction — the same argument as the notification stacks, and the same as the\n * operating system's own messages.\n */\n .v-snackbar-host[data-placement='bottom-left'] {\n left: var(--vectis-space-4);\n }\n\n .v-snackbar-host[data-placement='bottom-right'] {\n right: var(--vectis-space-4);\n }\n\n .v-snackbar-host[data-placement='bottom-center'] {\n left: 0;\n right: 0;\n margin-inline: auto;\n }\n\n /* The container fades in and out. Animating an element that is being added to or removed\n from the page needs the two `allow-discrete` declarations and the starting values\n below; a browser missing either simply shows and hides it at once. */\n .v-snackbar-host {\n opacity: 1;\n transition:\n opacity var(--vectis-duration-base) var(--vectis-ease-default),\n overlay var(--vectis-duration-base) allow-discrete,\n display var(--vectis-duration-base) allow-discrete;\n }\n\n .v-snackbar-host:not(:popover-open) {\n opacity: 0;\n }\n\n @starting-style {\n .v-snackbar-host:popover-open {\n opacity: 0;\n }\n }\n\n @media (prefers-reduced-motion: reduce) {\n .v-snackbar-host {\n transition: none;\n }\n }\n\n /* The box, the decoration, the typography and the entry motion come from the shared\n `.v-banner` class set on this same element — the chassis this bar has in common with\n the notification card, in `styles/banner.css`. What stays here is what the two\n genuinely differ on: the alignment, the padding, the width, and the tone painting.\n `--banner-line`, the one-line alignment unit both use, is defined there. */\n .v-snackbar {\n /* Centred, where the notification hooks to its first line. A confirmation is ONE\n short sentence and it carries a real button: on a message that wraps, aligning to\n the start would park that button in the top corner, away from the text it answers.\n Centring also puts the icon in the middle, which is what keeps the two ends of the\n bar reading as one row. */\n align-items: center;\n padding-block: var(--vectis-space-3);\n /* Tighter at the end than at the start: the action button brings padding of its own,\n and the two together would read as a hole — hence the negative inline margin it\n pulls back with, rather than a smaller padding declared here. */\n padding-inline: var(--vectis-space-4);\n min-inline-size: var(--vectis-control-size-snackbar-min);\n /* Wide enough for a sentence, never wider than the viewport with the container's own\n margins deducted. */\n max-inline-size: min(\n var(--vectis-control-size-snackbar-max),\n calc(100vw - 2 * var(--vectis-space-4))\n );\n }\n\n /*\n * Both tones are painted SOLID, and there is deliberately no soft variant: a\n * confirmation is a short-lived object laid over arbitrary content, so it has to read at\n * a glance rather than tint into the page.\n *\n * The tone table itself lives in styles/tones.css, in a layer below the components, and\n * is shared with VButton, VChip and VToast. Neutral needs no override here — its solid\n * pair IS the design system's canonical text/surface inversion, dark on a light theme\n * and light on a dark one, which is exactly what a snackbar wants and is why it is\n * expressed there rather than restated here.\n */\n .v-snackbar {\n background: var(--tone-bg-solid);\n color: var(--tone-text-solid);\n }\n\n /* No alignment margin here, unlike the notification: `align-items: center` above already\n puts the icon on the row's centre line, and an equal margin on a centred item changes\n nothing at all — it would be a declaration that does no work. */\n .v-snackbar-icon {\n --vectis-icon-size: var(--vectis-icon-size-md);\n }\n\n .v-snackbar-message {\n flex: 1;\n min-width: 0;\n /* A message may hold something with nowhere to break — a file name, an identifier —\n and it has to wrap anyway rather than widen the bar. */\n overflow-wrap: anywhere;\n }\n\n /*\n * The action is an ordinary neutral ghost button, recoloured by rebinding the very\n * variables its own tone table reads. These rules win over that table TWICE — they are\n * more specific AND they sit in a layer above it — so no sheet order can change the\n * outcome.\n *\n * Without the rebind a neutral ghost paints its text `--vectis-color-text`, which is the\n * very colour the bar's background is: the button would be invisible, in both themes.\n * The surrounding text colour is the only thing guaranteed to be readable against that\n * background, whichever of the two tones is showing.\n *\n * Not observable in jsdom, which lays nothing out and evaluates no colour: the guard is\n * the `Tones` play function, which deliberately ends with a bar OPEN so that axe judges\n * this button. Verified red — without the rule axe reports `color-contrast` on\n * `.v-snackbar-action`, in both themes.\n */\n .v-snackbar .v-snackbar-action[data-tone] {\n --tone-text-tinted: currentcolor;\n --tone-bg-soft: color-mix(in oklab, currentcolor, transparent 85%);\n }\n\n .v-snackbar-action {\n /* TRAP — this restates the size the template gives that button, small. The height the\n button computes for itself lives inside its own subtree, out of reach from here, so\n the two are written in two places and must be changed together. */\n --snackbar-action-height: var(--vectis-control-height-sm);\n /* The button is taller than a line of text, so this margin comes out negative. Under\n `align-items: center` it ALIGNS nothing — an equal margin does not move a centred\n item — and its one job is to keep the bar exactly one line tall on a single-line\n message: without it the row would take the button's height instead, and the bar\n would grow by the difference for no reason the reader can see. The unit it is\n measured against is the one-line height `.v-banner` defines. */\n margin-block: calc((var(--banner-line) - var(--snackbar-action-height)) / 2);\n /* Kept equal to VToast's close cross, which pulls back by the same amount from the\n same gutter — see the note there. */\n margin-inline-end: calc(-1 * var(--vectis-space-2));\n }\n}\n</style>\n"],"mappings":""}
@@ -0,0 +1,83 @@
1
+ import { useMessages as e } from "../../i18n/state.js";
2
+ import t from "../VIcon/VIcon.js";
3
+ import { usePopover as n } from "../../composables/usePopover.js";
4
+ import { iconProps as r } from "../VIcon/iconProps.js";
5
+ import i from "../VButton/VButton.js";
6
+ import { useAriaLabel as a } from "../../composables/useAriaLabel.js";
7
+ import { useTimer as o } from "../../composables/useTimer.js";
8
+ import { current as s, dismissSnackbar as c } from "./state.js";
9
+ import { computed as l, createBlock as u, createCommentVNode as d, createElementBlock as f, createElementVNode as p, createTextVNode as m, defineComponent as h, mergeProps as g, onMounted as _, openBlock as v, ref as y, toDisplayString as b, unref as x, watch as S, withCtx as C } from "vue";
10
+ //#region src/components/VSnackbar/VSnackbar.vue?vue&type=script&setup=true&lang.ts
11
+ var w = ["data-placement", "aria-label"], T = ["data-tone", "role"], E = { class: "v-snackbar-message" }, D = /*@__PURE__*/ h({
12
+ __name: "VSnackbar",
13
+ props: {
14
+ placement: { default: "bottom-center" },
15
+ duration: { default: 4e3 },
16
+ actionLabel: { default: void 0 },
17
+ label: { default: void 0 }
18
+ },
19
+ setup(h) {
20
+ let D = h, O = e(), k = a(() => D.label ?? O.value.snackbar.label), A = l(() => s.value), j = l(() => A.value?.placement ?? D.placement), M = l(() => A.value?.tone === "danger" ? "alert" : "status"), N = l(() => A.value?.actionLabel ?? D.actionLabel ?? O.value.snackbar.action), P = l(() => A.value?.icon ? r(A.value.icon) : void 0), F = y(null), { syncShown: I, show: L, hide: R } = n(F), { start: z, cancel: B } = o(), V = !1, H = !1;
21
+ function U() {
22
+ let e = A.value;
23
+ if (!e || V || H) return;
24
+ let t = e.duration ?? D.duration;
25
+ t > 0 && z(() => c(e.id), t);
26
+ }
27
+ function W() {
28
+ B(), A.value ? L() : R(), U();
29
+ }
30
+ S(A, W, { flush: "post" }), _(W);
31
+ function G(e) {
32
+ e === "pointer" ? V = !0 : H = !0, B();
33
+ }
34
+ function K(e) {
35
+ e === "pointer" ? V = !1 : H = !1, U();
36
+ }
37
+ function q() {
38
+ let e = A.value;
39
+ e && (e.action?.(), c(e.id));
40
+ }
41
+ return (e, n) => (v(), f("div", {
42
+ ref_key: "hostEl",
43
+ ref: F,
44
+ class: "v-overlay v-snackbar-host",
45
+ popover: "manual",
46
+ "data-placement": j.value,
47
+ role: "region",
48
+ "aria-label": x(k),
49
+ onPointerenter: n[0] ||= (e) => G("pointer"),
50
+ onPointerleave: n[1] ||= (e) => K("pointer"),
51
+ onFocusin: n[2] ||= (e) => G("focus"),
52
+ onFocusout: n[3] ||= (e) => K("focus"),
53
+ onBeforetoggle: n[4] ||= (...e) => x(I) && x(I)(...e),
54
+ onToggle: n[5] ||= (...e) => x(I) && x(I)(...e)
55
+ }, [A.value ? (v(), f("div", {
56
+ key: A.value.id,
57
+ class: "v-banner v-snackbar v-tone",
58
+ "data-tone": A.value.tone,
59
+ role: M.value
60
+ }, [
61
+ P.value ? (v(), u(t, g({
62
+ key: 0,
63
+ class: "v-snackbar-icon"
64
+ }, P.value), null, 16)) : d("", !0),
65
+ p("p", E, b(A.value.message), 1),
66
+ A.value.action ? (v(), u(i, {
67
+ key: 1,
68
+ class: "v-snackbar-action",
69
+ variant: "ghost",
70
+ tone: "neutral",
71
+ size: "sm",
72
+ onClick: q
73
+ }, {
74
+ default: C(() => [m(b(N.value), 1)]),
75
+ _: 1
76
+ })) : d("", !0)
77
+ ], 8, T)) : d("", !0)], 40, w));
78
+ }
79
+ });
80
+ //#endregion
81
+ export { D as default };
82
+
83
+ //# sourceMappingURL=VSnackbar.vue_vue_type_script_setup_true_lang.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"VSnackbar.vue_vue_type_script_setup_true_lang.js","names":[],"sources":["../../../src/components/VSnackbar/VSnackbar.vue"],"sourcesContent":["<script setup lang=\"ts\">\nimport { computed, onMounted, ref, watch } from 'vue'\n\nimport { usePopover } from '../../composables/usePopover'\nimport { useTimer } from '../../composables/useTimer'\nimport { useAriaLabel } from '../../composables/useAriaLabel'\nimport { useMessages } from '../../i18n/state'\nimport VButton from '../VButton/VButton.vue'\nimport VIcon from '../VIcon/VIcon.vue'\nimport { iconProps } from '../VIcon/iconProps'\nimport { current, dismissSnackbar, type SnackbarPlacement } from './state'\n\n// @a11y @core\n/**\n * Where confirmations appear. It is mounted ONCE, at the root of the application, and\n * from then on any call to `snackbar()` shows up here.\n *\n * A confirmation is the short answer to something the reader has just done — \"Message\n * deleted\", \"Settings saved\" — usually with one button to take it back. That is a\n * different job from a notification, which reports a state, and the differences are\n * deliberate rather than a matter of styling: there is only ever ONE bar at a time,\n * always along the bottom edge, it carries no close cross, and it leaves on its own after\n * a few seconds. Two of those follow from the same idea: only the LAST thing a reader did\n * is worth offering to undo, so a queue would hand out buttons about actions already\n * forgotten, and a cross would ask them to tidy up after a message that tidies itself.\n *\n * Because there is only one, this is a single file where the notifications need two: one\n * container, one card, and no book-keeping to tell several countdowns apart.\n *\n * The JavaScript covers three things the platform does not: putting the state and the\n * container in step, since drawing above the page can only be asked for by calling a\n * method; the countdown that takes the bar away when its time is up; and holding that\n * countdown while the reader is resting the pointer on the bar OR has moved the keyboard\n * into it, so that something disappearing on a clock can be held long enough to read and\n * to act on (WCAG 2.2.1).\n */\ninterface SnackbarProps {\n /** Which end of the bottom edge confirmations appear at, unless one of them asks for another. */\n placement?: SnackbarPlacement\n /**\n * How long a confirmation stays, in milliseconds, unless it asks for something else. A\n * confirmation given 0 stays until it is replaced or taken away by hand.\n */\n duration?: number\n /**\n * What the single action is called, when the confirmation does not name it. It falls\n * back to the design system dictionary.\n */\n actionLabel?: string\n /**\n * What screen readers announce for the confirmation area itself, which is a landmark of\n * the page. It falls back to the design system dictionary.\n */\n label?: string\n}\n\nconst props = withDefaults(defineProps<SnackbarProps>(), {\n placement: 'bottom-center',\n /* Shorter than a notification's five seconds. A confirmation is one short sentence\n about something the reader has just done, so they already know what it says. */\n duration: 4000,\n actionLabel: undefined,\n label: undefined,\n})\n\nconst m = useMessages()\nconst ariaLabel = useAriaLabel(() => props.label ?? m.value.snackbar.label)\n\nconst item = computed(() => current.value)\nconst placement = computed(() => item.value?.placement ?? props.placement)\n/* A failure interrupts whatever a screen reader is saying; a plain confirmation waits for\n a pause, the reader having asked for the action it reports. */\nconst role = computed(() => (item.value?.tone === 'danger' ? 'alert' : 'status'))\nconst actionLabel = computed(\n () => item.value?.actionLabel ?? props.actionLabel ?? m.value.snackbar.action,\n)\nconst icon = computed(() => (item.value?.icon ? iconProps(item.value.icon) : undefined))\n\nconst hostEl = ref<HTMLElement | null>(null)\nconst { syncShown, show, hide } = usePopover(hostEl)\nconst { start, cancel } = useTimer()\n\n/* The reasons to hold the countdown, each set by its own pair of events. They are two\n separate flags rather than one counter because they can be true at the same time and\n end independently: a reader tabs to the action button, then moves the mouse over the\n bar, then moves it away — and the bar must not leave while the button still has focus. */\nlet hovered = false\nlet focused = false\n\nfunction arm() {\n const bar = item.value\n if (!bar || hovered || focused) return\n const duration = bar.duration ?? props.duration\n /* GUARD, not a default: `useTimer` runs a delay of 0 SYNCHRONOUSLY, which is the design\n system's convention for \"no deferral at all\". Without this test a confirmation asking\n to be permanent would be taken away in the same tick it was raised. */\n if (duration > 0) start(() => dismissSnackbar(bar.id), duration)\n}\n\n// @core\n/**\n * Brings the page into line with the state: it shows the container when there is a\n * confirmation and hides it when there is none, and restarts the countdown from the top.\n *\n * Restarting unconditionally is what makes a replacement correct — the outgoing bar's\n * countdown must not be allowed to take the incoming one away — and it is safe precisely\n * because this runs only when the bar itself changes.\n *\n * It runs once on mount, which is what makes a confirmation raised before this component\n * existed appear all the same, and after that on every change.\n */\nfunction sync() {\n cancel()\n // Showing and hiding are safe to call on a container already in that state, the guards\n // living in the popover plumbing — so there is no need to remember which it is in.\n if (item.value) show()\n else hide()\n arm()\n}\n\n/*\n * Watching the resolved bar covers a change of confirmation AND its disappearance. The\n * `post` timing is load-bearing: the card must already be in the page before its container\n * is told to show itself.\n */\nwatch(item, sync, { flush: 'post' })\n// @ssr — a watcher does not run during the server render, so a confirmation raised before\n// this component mounted would never be picked up. Running the same synchronization on\n// mount is what brings it in.\nonMounted(sync)\n\n// @a11y — WCAG 2.2.1: something that disappears on a clock has to be holdable, or a slow\n// reader simply never finishes it — and here they would also never reach the button.\n/*\n * Resting the pointer on the bar suspends its countdown, and so does moving the keyboard\n * into it. The focus half is what the notifications do not need and this cannot do\n * without: the action is a real button, so a reader tabbing towards it would otherwise\n * watch it vanish from under the focus ring.\n *\n * Any focus counts, not just a keyboard one: a pointer landing on the button is about to\n * run the action anyway, so there is nothing to lose by holding as well.\n *\n * Leaving restarts the countdown from the FULL duration rather than from what was left:\n * simpler, and more generous to the reader who has just interrupted themselves.\n */\nfunction hold(which: 'pointer' | 'focus') {\n if (which === 'pointer') hovered = true\n else focused = true\n cancel()\n}\n\nfunction release(which: 'pointer' | 'focus') {\n if (which === 'pointer') hovered = false\n else focused = false\n arm()\n}\n\n/* The action always takes the bar away: it answers the confirmation, so leaving it on\n screen would invite the reader to answer it twice. */\nfunction runAction() {\n const bar = item.value\n if (!bar) return\n bar.action?.()\n dismissSnackbar(bar.id)\n}\n</script>\n\n<template>\n <div\n ref=\"hostEl\"\n class=\"v-overlay v-snackbar-host\"\n popover=\"manual\"\n :data-placement=\"placement\"\n role=\"region\"\n :aria-label=\"ariaLabel\"\n @pointerenter=\"hold('pointer')\"\n @pointerleave=\"release('pointer')\"\n @focusin=\"hold('focus')\"\n @focusout=\"release('focus')\"\n @beforetoggle=\"syncShown\"\n @toggle=\"syncShown\"\n >\n <div\n v-if=\"item\"\n :key=\"item.id\"\n class=\"v-banner v-snackbar v-tone\"\n :data-tone=\"item.tone\"\n :role=\"role\"\n >\n <VIcon v-if=\"icon\" class=\"v-snackbar-icon\" v-bind=\"icon\" />\n <p class=\"v-snackbar-message\">{{ item.message }}</p>\n <VButton\n v-if=\"item.action\"\n class=\"v-snackbar-action\"\n variant=\"ghost\"\n tone=\"neutral\"\n size=\"sm\"\n @click=\"runAction\"\n >\n {{ actionLabel }}\n </VButton>\n </div>\n </div>\n</template>\n\n<style>\n@layer vectis.components {\n /* The fixed positioning and the guard hiding a closed container come from the shared\n `.v-overlay` class, set on this same element. What stays here is the browser's own\n popover decoration to undo — its border, its padding, its opaque background. */\n .v-snackbar-host {\n margin: 0;\n border: none;\n padding: 0;\n background: transparent;\n overflow: visible;\n width: fit-content;\n bottom: var(--vectis-space-4);\n /* The direction the bar slides in from, read by `.v-banner` in styles/banner.css.\n Always positive: this container only ever sits along the bottom edge. */\n --banner-enter-y: var(--vectis-space-4);\n }\n\n /*\n * These coordinates are deliberately PHYSICAL rather than logical: a confirmation\n * appears at a place on the screen, and that place does not flip with the reading\n * direction — the same argument as the notification stacks, and the same as the\n * operating system's own messages.\n */\n .v-snackbar-host[data-placement='bottom-left'] {\n left: var(--vectis-space-4);\n }\n\n .v-snackbar-host[data-placement='bottom-right'] {\n right: var(--vectis-space-4);\n }\n\n .v-snackbar-host[data-placement='bottom-center'] {\n left: 0;\n right: 0;\n margin-inline: auto;\n }\n\n /* The container fades in and out. Animating an element that is being added to or removed\n from the page needs the two `allow-discrete` declarations and the starting values\n below; a browser missing either simply shows and hides it at once. */\n .v-snackbar-host {\n opacity: 1;\n transition:\n opacity var(--vectis-duration-base) var(--vectis-ease-default),\n overlay var(--vectis-duration-base) allow-discrete,\n display var(--vectis-duration-base) allow-discrete;\n }\n\n .v-snackbar-host:not(:popover-open) {\n opacity: 0;\n }\n\n @starting-style {\n .v-snackbar-host:popover-open {\n opacity: 0;\n }\n }\n\n @media (prefers-reduced-motion: reduce) {\n .v-snackbar-host {\n transition: none;\n }\n }\n\n /* The box, the decoration, the typography and the entry motion come from the shared\n `.v-banner` class set on this same element — the chassis this bar has in common with\n the notification card, in `styles/banner.css`. What stays here is what the two\n genuinely differ on: the alignment, the padding, the width, and the tone painting.\n `--banner-line`, the one-line alignment unit both use, is defined there. */\n .v-snackbar {\n /* Centred, where the notification hooks to its first line. A confirmation is ONE\n short sentence and it carries a real button: on a message that wraps, aligning to\n the start would park that button in the top corner, away from the text it answers.\n Centring also puts the icon in the middle, which is what keeps the two ends of the\n bar reading as one row. */\n align-items: center;\n padding-block: var(--vectis-space-3);\n /* Tighter at the end than at the start: the action button brings padding of its own,\n and the two together would read as a hole — hence the negative inline margin it\n pulls back with, rather than a smaller padding declared here. */\n padding-inline: var(--vectis-space-4);\n min-inline-size: var(--vectis-control-size-snackbar-min);\n /* Wide enough for a sentence, never wider than the viewport with the container's own\n margins deducted. */\n max-inline-size: min(\n var(--vectis-control-size-snackbar-max),\n calc(100vw - 2 * var(--vectis-space-4))\n );\n }\n\n /*\n * Both tones are painted SOLID, and there is deliberately no soft variant: a\n * confirmation is a short-lived object laid over arbitrary content, so it has to read at\n * a glance rather than tint into the page.\n *\n * The tone table itself lives in styles/tones.css, in a layer below the components, and\n * is shared with VButton, VChip and VToast. Neutral needs no override here — its solid\n * pair IS the design system's canonical text/surface inversion, dark on a light theme\n * and light on a dark one, which is exactly what a snackbar wants and is why it is\n * expressed there rather than restated here.\n */\n .v-snackbar {\n background: var(--tone-bg-solid);\n color: var(--tone-text-solid);\n }\n\n /* No alignment margin here, unlike the notification: `align-items: center` above already\n puts the icon on the row's centre line, and an equal margin on a centred item changes\n nothing at all — it would be a declaration that does no work. */\n .v-snackbar-icon {\n --vectis-icon-size: var(--vectis-icon-size-md);\n }\n\n .v-snackbar-message {\n flex: 1;\n min-width: 0;\n /* A message may hold something with nowhere to break — a file name, an identifier —\n and it has to wrap anyway rather than widen the bar. */\n overflow-wrap: anywhere;\n }\n\n /*\n * The action is an ordinary neutral ghost button, recoloured by rebinding the very\n * variables its own tone table reads. These rules win over that table TWICE — they are\n * more specific AND they sit in a layer above it — so no sheet order can change the\n * outcome.\n *\n * Without the rebind a neutral ghost paints its text `--vectis-color-text`, which is the\n * very colour the bar's background is: the button would be invisible, in both themes.\n * The surrounding text colour is the only thing guaranteed to be readable against that\n * background, whichever of the two tones is showing.\n *\n * Not observable in jsdom, which lays nothing out and evaluates no colour: the guard is\n * the `Tones` play function, which deliberately ends with a bar OPEN so that axe judges\n * this button. Verified red — without the rule axe reports `color-contrast` on\n * `.v-snackbar-action`, in both themes.\n */\n .v-snackbar .v-snackbar-action[data-tone] {\n --tone-text-tinted: currentcolor;\n --tone-bg-soft: color-mix(in oklab, currentcolor, transparent 85%);\n }\n\n .v-snackbar-action {\n /* TRAP — this restates the size the template gives that button, small. The height the\n button computes for itself lives inside its own subtree, out of reach from here, so\n the two are written in two places and must be changed together. */\n --snackbar-action-height: var(--vectis-control-height-sm);\n /* The button is taller than a line of text, so this margin comes out negative. Under\n `align-items: center` it ALIGNS nothing — an equal margin does not move a centred\n item — and its one job is to keep the bar exactly one line tall on a single-line\n message: without it the row would take the button's height instead, and the bar\n would grow by the difference for no reason the reader can see. The unit it is\n measured against is the one-line height `.v-banner` defines. */\n margin-block: calc((var(--banner-line) - var(--snackbar-action-height)) / 2);\n /* Kept equal to VToast's close cross, which pulls back by the same amount from the\n same gutter — see the note there. */\n margin-inline-end: calc(-1 * var(--vectis-space-2));\n }\n}\n</style>\n"],"mappings":";;;;;;;;;;;;;;;;;;;EAwDA,IAAM,IAAQ,GASR,IAAI,EAAY,GAChB,IAAY,QAAmB,EAAM,SAAS,EAAE,MAAM,SAAS,KAAK,GAEpE,IAAO,QAAe,EAAQ,KAAK,GACnC,IAAY,QAAe,EAAK,OAAO,aAAa,EAAM,SAAS,GAGnE,IAAO,QAAgB,EAAK,OAAO,SAAS,WAAW,UAAU,QAAS,GAC1E,IAAc,QACZ,EAAK,OAAO,eAAe,EAAM,eAAe,EAAE,MAAM,SAAS,MACzE,GACM,IAAO,QAAgB,EAAK,OAAO,OAAO,EAAU,EAAK,MAAM,IAAI,IAAI,KAAA,CAAU,GAEjF,IAAS,EAAwB,IAAI,GACrC,EAAE,cAAW,SAAM,YAAS,EAAW,CAAM,GAC7C,EAAE,UAAO,cAAW,EAAS,GAM/B,IAAU,IACV,IAAU;EAEd,SAAS,IAAM;GACb,IAAM,IAAM,EAAK;GACjB,IAAI,CAAC,KAAO,KAAW,GAAS;GAChC,IAAM,IAAW,EAAI,YAAY,EAAM;GAIvC,AAAI,IAAW,KAAG,QAAY,EAAgB,EAAI,EAAE,GAAG,CAAQ;EACjE;EAcA,SAAS,IAAO;GAMd,AALA,EAAO,GAGH,EAAK,QAAO,EAAK,IAChB,EAAK,GACV,EAAI;EACN;EAWA,AAJA,EAAM,GAAM,GAAM,EAAE,OAAO,OAAO,CAAC,GAInC,EAAU,CAAI;EAgBd,SAAS,EAAK,GAA4B;GAGxC,AAFI,MAAU,YAAW,IAAU,KAC9B,IAAU,IACf,EAAO;EACT;EAEA,SAAS,EAAQ,GAA4B;GAG3C,AAFI,MAAU,YAAW,IAAU,KAC9B,IAAU,IACf,EAAI;EACN;EAIA,SAAS,IAAY;GACnB,IAAM,IAAM,EAAK;GACZ,MACL,EAAI,SAAS,GACb,EAAgB,EAAI,EAAE;EACxB;yBAIE,EAkCM,OAAA;YAjCA;GAAJ,KAAI;GACJ,OAAM;GACN,SAAQ;GACP,kBAAgB,EAAA;GACjB,MAAK;GACJ,cAAY,EAAA,CAAA;GACZ,gBAAY,AAAA,EAAA,QAAA,MAAE,EAAI,SAAA;GAClB,gBAAY,AAAA,EAAA,QAAA,MAAE,EAAO,SAAA;GACrB,WAAO,AAAA,EAAA,QAAA,MAAE,EAAI,OAAA;GACb,YAAQ,AAAA,EAAA,QAAA,MAAE,EAAO,OAAA;GACjB,gBAAY,AAAA,EAAA,QAAA,GAAA,MAAE,EAAA,CAAA,KAAA,EAAA,CAAA,CAAA,CAAA,GAAA,CAAA;GACd,UAAM,AAAA,EAAA,QAAA,GAAA,MAAE,EAAA,CAAA,KAAA,EAAA,CAAA,CAAA,CAAA,GAAA,CAAA;MAGD,EAAA,SAAA,EAAA,GADR,EAmBM,OAAA;GAjBH,KAAK,EAAA,MAAK;GACX,OAAM;GACL,aAAW,EAAA,MAAK;GAChB,MAAM,EAAA;;GAEM,EAAA,SAAA,EAAA,GAAb,EAA2D,GAA3D,EAA2D;;IAAxC,OAAM;MAA0B,EAAA,KAAI,GAAA,MAAA,EAAA,KAAA,EAAA,IAAA,EAAA;GACvD,EAAoD,KAApD,GAAoD,EAAnB,EAAA,MAAK,OAAO,GAAA,CAAA;GAErC,EAAA,MAAK,UAAA,EAAA,GADb,EASU,GAAA;;IAPR,OAAM;IACN,SAAQ;IACR,MAAK;IACL,MAAK;IACJ,SAAO;;qBAES,CAAA,EAAA,EAAd,EAAA,KAAW,GAAA,CAAA,CAAA,CAAA"}
@@ -0,0 +1,92 @@
1
+ import { IconSource } from '../VIcon/types.js';
2
+ /**
3
+ * The confirmation bar waiting to be shown. Nothing in HTML covers this, so it is code
4
+ * by necessity.
5
+ *
6
+ * A snackbar confirms an action the reader has just taken and offers, most of the time,
7
+ * to take it back — "Message deleted — Undo". That is what separates it from a
8
+ * notification, which reports a state: a notification stacks, because two things can be
9
+ * true at once, whereas only the LAST action a reader took is worth offering to undo.
10
+ * So there is at most one snackbar at a time, and raising a new one replaces the one
11
+ * before it on the spot.
12
+ *
13
+ * Which is why this is a single value rather than a queue. It is a `shallowRef` and not
14
+ * a `reactive` object: the bar is replaced whole, never edited in place. That is what
15
+ * makes the watcher in VSnackbar exact — it fires when and only when the bar really
16
+ * changes, so the countdown is re-armed exactly then, and none of the bookkeeping the
17
+ * VToaster needs to time several notifications at once has to exist here.
18
+ *
19
+ * The state is held at module level rather than inside a component, and that is the
20
+ * whole point: `snackbar()` can then be called from ANYWHERE — a component, a store, the
21
+ * handler that just deleted something — without anything having to be passed down to it.
22
+ * The price is a contract to respect: since module state is shared by every request a
23
+ * server handles, `snackbar()` must only ever be called in the browser, from a handler
24
+ * or when a request comes back, and never while a page is being rendered on the server.
25
+ *
26
+ * The only thing that touches the DOM, and the only thing that arms the countdown, is
27
+ * the mounted VSnackbar.
28
+ */
29
+ /**
30
+ * What a confirmation can mean. There are two, and deliberately no more: a snackbar
31
+ * says either "done" or "that did not work". Success, warning and the accent are
32
+ * STATES, which is a notification's subject — reporting one here would blur the line
33
+ * the two components exist to draw.
34
+ */
35
+ export type SnackbarTone = 'neutral' | 'danger';
36
+ /** Where the bar appears. Along the bottom edge only, where it is out of the content's way. */
37
+ export type SnackbarPlacement = 'bottom-left' | 'bottom-center' | 'bottom-right';
38
+ /** Everything one can say when raising a confirmation. */
39
+ export interface SnackbarOptions {
40
+ /** What the confirmation says. One short sentence — there is no title to frame it. */
41
+ message: string;
42
+ /** What it means, expressed as a colour: the plain inversion, or the failure colour. */
43
+ tone?: SnackbarTone;
44
+ /**
45
+ * An icon before the message. There is none by default, and none is deduced from the
46
+ * tone: a confirmation is read, not scanned.
47
+ */
48
+ icon?: IconSource;
49
+ /**
50
+ * How long it stays, in milliseconds. Setting it to 0 keeps it until it is replaced or
51
+ * taken away by hand, and leaving it out takes the duration set on the VSnackbar.
52
+ */
53
+ duration?: number;
54
+ /** Which end of the bottom edge it appears at. Left out, it takes the one set on the VSnackbar. */
55
+ placement?: SnackbarPlacement;
56
+ /**
57
+ * What the single action does. Left out, the bar carries no button at all. Running it
58
+ * always takes the bar away, so nothing has to be dismissed by hand afterwards.
59
+ */
60
+ action?: () => void;
61
+ /** What that action is called. It falls back to the design system dictionary ("Undo"). */
62
+ actionLabel?: string;
63
+ }
64
+ /**
65
+ * A confirmation once it is showing, with the choices the caller left out filled in and
66
+ * an id of its own. Internal: it is what VSnackbar renders.
67
+ */
68
+ export interface SnackbarItem extends SnackbarOptions {
69
+ id: number;
70
+ tone: SnackbarTone;
71
+ }
72
+ /** The bar currently showing, if any. Internal, read only by VSnackbar, and not public API. */
73
+ export declare const current: import('vue').ShallowRef<SnackbarItem | null, SnackbarItem | null>;
74
+ /**
75
+ * Raises a confirmation, replacing whatever was showing, and hands back an id that
76
+ * `dismissSnackbar` can use to take it away again before its time.
77
+ *
78
+ * The two defaults that belong to the VSnackbar — where the bar appears and how long it
79
+ * stays — are deliberately NOT resolved here: they are read when the bar is rendered, so
80
+ * the component remains the single source of truth for its own settings.
81
+ */
82
+ export declare function snackbar(options: SnackbarOptions): number;
83
+ /**
84
+ * Takes a confirmation away, by its id or — called with no argument — whichever one is
85
+ * showing.
86
+ *
87
+ * Passing an id is not a formality: it is checked against the bar actually on screen, and
88
+ * a stale one is ignored. Without that test a countdown or a handler arriving late would
89
+ * close the bar that has just REPLACED the one it was about, and the reader would watch a
90
+ * fresh confirmation vanish in a fraction of its time.
91
+ */
92
+ export declare function dismissSnackbar(id?: number): void;
@@ -0,0 +1,18 @@
1
+ import { shallowRef as e } from "vue";
2
+ //#region src/components/VSnackbar/state.ts
3
+ var t = e(null), n = 0;
4
+ function r(e) {
5
+ let r = n++;
6
+ return t.value = {
7
+ tone: "neutral",
8
+ ...e,
9
+ id: r
10
+ }, r;
11
+ }
12
+ function i(e) {
13
+ (e === void 0 || t.value?.id === e) && (t.value = null);
14
+ }
15
+ //#endregion
16
+ export { t as current, i as dismissSnackbar, r as snackbar };
17
+
18
+ //# sourceMappingURL=state.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"state.js","names":[],"sources":["../../../src/components/VSnackbar/state.ts"],"sourcesContent":["import { shallowRef } from 'vue'\n\nimport type { IconSource } from '../VIcon/types'\n\n// @ssr @core\n/**\n * The confirmation bar waiting to be shown. Nothing in HTML covers this, so it is code\n * by necessity.\n *\n * A snackbar confirms an action the reader has just taken and offers, most of the time,\n * to take it back — \"Message deleted — Undo\". That is what separates it from a\n * notification, which reports a state: a notification stacks, because two things can be\n * true at once, whereas only the LAST action a reader took is worth offering to undo.\n * So there is at most one snackbar at a time, and raising a new one replaces the one\n * before it on the spot.\n *\n * Which is why this is a single value rather than a queue. It is a `shallowRef` and not\n * a `reactive` object: the bar is replaced whole, never edited in place. That is what\n * makes the watcher in VSnackbar exact — it fires when and only when the bar really\n * changes, so the countdown is re-armed exactly then, and none of the bookkeeping the\n * VToaster needs to time several notifications at once has to exist here.\n *\n * The state is held at module level rather than inside a component, and that is the\n * whole point: `snackbar()` can then be called from ANYWHERE — a component, a store, the\n * handler that just deleted something — without anything having to be passed down to it.\n * The price is a contract to respect: since module state is shared by every request a\n * server handles, `snackbar()` must only ever be called in the browser, from a handler\n * or when a request comes back, and never while a page is being rendered on the server.\n *\n * The only thing that touches the DOM, and the only thing that arms the countdown, is\n * the mounted VSnackbar.\n */\n\n/**\n * What a confirmation can mean. There are two, and deliberately no more: a snackbar\n * says either \"done\" or \"that did not work\". Success, warning and the accent are\n * STATES, which is a notification's subject — reporting one here would blur the line\n * the two components exist to draw.\n */\nexport type SnackbarTone = 'neutral' | 'danger'\n\n/** Where the bar appears. Along the bottom edge only, where it is out of the content's way. */\nexport type SnackbarPlacement = 'bottom-left' | 'bottom-center' | 'bottom-right'\n\n/** Everything one can say when raising a confirmation. */\nexport interface SnackbarOptions {\n /** What the confirmation says. One short sentence — there is no title to frame it. */\n message: string\n /** What it means, expressed as a colour: the plain inversion, or the failure colour. */\n tone?: SnackbarTone\n /**\n * An icon before the message. There is none by default, and none is deduced from the\n * tone: a confirmation is read, not scanned.\n */\n icon?: IconSource\n /**\n * How long it stays, in milliseconds. Setting it to 0 keeps it until it is replaced or\n * taken away by hand, and leaving it out takes the duration set on the VSnackbar.\n */\n duration?: number\n /** Which end of the bottom edge it appears at. Left out, it takes the one set on the VSnackbar. */\n placement?: SnackbarPlacement\n /**\n * What the single action does. Left out, the bar carries no button at all. Running it\n * always takes the bar away, so nothing has to be dismissed by hand afterwards.\n */\n action?: () => void\n /** What that action is called. It falls back to the design system dictionary (\"Undo\"). */\n actionLabel?: string\n}\n\n/**\n * A confirmation once it is showing, with the choices the caller left out filled in and\n * an id of its own. Internal: it is what VSnackbar renders.\n */\nexport interface SnackbarItem extends SnackbarOptions {\n id: number\n tone: SnackbarTone\n}\n\n/** The bar currently showing, if any. Internal, read only by VSnackbar, and not public API. */\nexport const current = shallowRef<SnackbarItem | null>(null)\n\nlet nextId = 0\n\n/**\n * Raises a confirmation, replacing whatever was showing, and hands back an id that\n * `dismissSnackbar` can use to take it away again before its time.\n *\n * The two defaults that belong to the VSnackbar — where the bar appears and how long it\n * stays — are deliberately NOT resolved here: they are read when the bar is rendered, so\n * the component remains the single source of truth for its own settings.\n */\nexport function snackbar(options: SnackbarOptions): number {\n const id = nextId++\n current.value = { tone: 'neutral', ...options, id }\n return id\n}\n\n/**\n * Takes a confirmation away, by its id or — called with no argument — whichever one is\n * showing.\n *\n * Passing an id is not a formality: it is checked against the bar actually on screen, and\n * a stale one is ignored. Without that test a countdown or a handler arriving late would\n * close the bar that has just REPLACED the one it was about, and the reader would watch a\n * fresh confirmation vanish in a fraction of its time.\n */\nexport function dismissSnackbar(id?: number): void {\n if (id === undefined || current.value?.id === id) current.value = null\n}\n"],"mappings":";;AAiFA,IAAa,IAAU,EAAgC,IAAI,GAEvD,IAAS;AAUb,SAAgB,EAAS,GAAkC;CACzD,IAAM,IAAK;CAEX,OADA,EAAQ,QAAQ;EAAE,MAAM;EAAW,GAAG;EAAS;CAAG,GAC3C;AACT;AAWA,SAAgB,EAAgB,GAAmB;CACjD,CAAI,MAAO,KAAA,KAAa,EAAQ,OAAO,OAAO,OAAI,EAAQ,QAAQ;AACpE"}
@@ -0,0 +1,2 @@
1
+ @layer vectis.reset, vectis.tokens, vectis.components, vectis.utilities;
2
+ @layer vectis.components{.v-spinner{--spinner-size:1em;--spinner-ring:calc(var(--spinner-size) * 5 / 6);width:var(--spinner-size);height:var(--spinner-size);flex:none;justify-content:center;align-items:center;display:inline-flex}.v-spinner-circle{width:var(--spinner-ring);height:var(--spinner-ring);border:max(1px, calc(var(--spinner-ring) / 10)) solid color-mix(in oklab, currentcolor, transparent 75%);border-radius:var(--vectis-radius-full);animation:v-spin var(--vectis-duration-1000) linear infinite;border-block-start-color:currentColor}@media (prefers-reduced-motion:reduce){.v-spinner-circle{animation-duration:var(--vectis-duration-3000)}}}
@@ -0,0 +1,21 @@
1
+ interface SpinnerProps {
2
+ /**
3
+ * A size in pixels, understood exactly as VIcon's: it is the BOX the spinner
4
+ * occupies, not the diameter of the ring, which is drawn slightly smaller inside
5
+ * it. Left out, the box measures 1em and therefore follows the size of the text
6
+ * around it, which is how the spinner stays proportionate inside a button or a
7
+ * paragraph without being told anything.
8
+ */
9
+ size?: number;
10
+ /**
11
+ * What screen readers announce while it turns. It falls back to the wording of the
12
+ * design system dictionary, in the current language.
13
+ */
14
+ label?: string;
15
+ }
16
+ declare const __VLS_export: import('vue').DefineComponent<SpinnerProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<SpinnerProps> & Readonly<{}>, {
17
+ label: string;
18
+ size: number;
19
+ }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
20
+ declare const _default: typeof __VLS_export;
21
+ export default _default;
@@ -0,0 +1,9 @@
1
+ import './VSpinner.css';
2
+ import e from "./VSpinner.vue_vue_type_script_setup_true_lang.js";
3
+ /* empty css */
4
+ //#region src/components/VSpinner/VSpinner.vue
5
+ var t = e;
6
+ //#endregion
7
+ export { t as default };
8
+
9
+ //# sourceMappingURL=VSpinner.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"VSpinner.js","names":[],"sources":["../../../src/components/VSpinner/VSpinner.vue"],"sourcesContent":["<script setup lang=\"ts\">\n// @a11y\n/**\n * A turning ring saying that something is under way. The animation is pure CSS; what\n * makes the component more than a decorated circle is that it also announces itself:\n * it carries `role=\"status\"` and a label only screen readers see, so the wait is\n * heard as well as seen, without adding any text to the design.\n *\n * The single line of JavaScript reads the label from the dictionary, which is what\n * makes its default translatable. It is not behaviour: no event, no lifecycle, no\n * DOM access.\n */\nimport { computed } from 'vue'\n\nimport { useMessages } from '../../i18n/state'\n\ninterface SpinnerProps {\n /**\n * A size in pixels, understood exactly as VIcon's: it is the BOX the spinner\n * occupies, not the diameter of the ring, which is drawn slightly smaller inside\n * it. Left out, the box measures 1em and therefore follows the size of the text\n * around it, which is how the spinner stays proportionate inside a button or a\n * paragraph without being told anything.\n */\n size?: number\n /**\n * What screen readers announce while it turns. It falls back to the wording of the\n * design system dictionary, in the current language.\n */\n label?: string\n}\n\nconst props = withDefaults(defineProps<SpinnerProps>(), {\n size: undefined,\n label: undefined,\n})\n\nconst m = useMessages()\nconst resolvedLabel = computed(() => props.label ?? m.value.common.loading)\n</script>\n\n<template>\n <span\n class=\"v-spinner\"\n :style=\"size !== undefined ? { '--spinner-size': `${size}px` } : undefined\"\n role=\"status\"\n >\n <span class=\"v-spinner-circle\" aria-hidden=\"true\" />\n <span class=\"v-visually-hidden\">{{ resolvedLabel }}</span>\n </span>\n</template>\n\n<style>\n@layer vectis.components {\n .v-spinner {\n /* `--spinner-size` is the BOX the spinner occupies, exactly as `--vectis-icon-size`\n is for VIcon — and not the diameter of the ring. Sized in `em`, that box follows\n the text of whatever contains it, so a consumer can size it through font-size\n alone — VButton, VInput and VTextarea do exactly that, from their icon size. The\n `size` prop writes this same variable in pixels, inline, and therefore wins.\n\n The ring is then drawn at five sixths of the box, because that is the proportion\n Material Symbols draws `progress_activity` at: on its 960 grid the outer radius\n is 400, so the ink spans 800 of the 960 the glyph is scaled into. Anything a\n spinner stands in for is an icon, and matching that fraction is what makes the\n two read as the same size instead of the spinner looking a size up. */\n --spinner-size: 1em;\n --spinner-ring: calc(var(--spinner-size) * 5 / 6);\n display: inline-flex;\n align-items: center;\n justify-content: center;\n flex: none;\n width: var(--spinner-size);\n height: var(--spinner-size);\n }\n\n .v-spinner-circle {\n width: var(--spinner-ring);\n height: var(--spinner-ring);\n /* The stroke is a tenth of the ring's diameter, the same source again: the glyph's\n outer radius is 400 and its inner one 320, so its stroke is 80 of those 800. It\n stays in proportion at every size, with a one-pixel floor below which the ring\n would disappear — a floor that only bites under a 12px box, which no size of the\n design system reaches. A bare ratio is tolerated here, like the opacities. */\n border: max(1px, calc(var(--spinner-ring) / 10)) solid\n color-mix(in oklab, currentcolor, transparent 75%);\n border-block-start-color: currentcolor;\n border-radius: var(--vectis-radius-full);\n animation: v-spin var(--vectis-duration-1000) linear infinite;\n }\n\n /* The `v-spin` keyframes live in styles/utilities.css, shared with\n VProgressCircular. Keyframes are global names rather than declarations arbitrated\n by the cascade, so they sit outside any layer and are declared once for the whole\n design system. */\n\n @media (prefers-reduced-motion: reduce) {\n .v-spinner-circle {\n animation-duration: var(--vectis-duration-3000);\n }\n }\n}\n</style>\n"],"mappings":""}
@@ -0,0 +1,25 @@
1
+ import { useMessages as e } from "../../i18n/state.js";
2
+ import { computed as t, createElementBlock as n, createElementVNode as r, defineComponent as i, normalizeStyle as a, openBlock as o, toDisplayString as s } from "vue";
3
+ //#region src/components/VSpinner/VSpinner.vue?vue&type=script&setup=true&lang.ts
4
+ var c = { class: "v-visually-hidden" }, l = /*@__PURE__*/ i({
5
+ __name: "VSpinner",
6
+ props: {
7
+ size: { default: void 0 },
8
+ label: { default: void 0 }
9
+ },
10
+ setup(i) {
11
+ let l = i, u = e(), d = t(() => l.label ?? u.value.common.loading);
12
+ return (e, t) => (o(), n("span", {
13
+ class: "v-spinner",
14
+ style: a(i.size === void 0 ? void 0 : { "--spinner-size": `${i.size}px` }),
15
+ role: "status"
16
+ }, [t[0] ||= r("span", {
17
+ class: "v-spinner-circle",
18
+ "aria-hidden": "true"
19
+ }, null, -1), r("span", c, s(d.value), 1)], 4));
20
+ }
21
+ });
22
+ //#endregion
23
+ export { l as default };
24
+
25
+ //# sourceMappingURL=VSpinner.vue_vue_type_script_setup_true_lang.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"VSpinner.vue_vue_type_script_setup_true_lang.js","names":[],"sources":["../../../src/components/VSpinner/VSpinner.vue"],"sourcesContent":["<script setup lang=\"ts\">\n// @a11y\n/**\n * A turning ring saying that something is under way. The animation is pure CSS; what\n * makes the component more than a decorated circle is that it also announces itself:\n * it carries `role=\"status\"` and a label only screen readers see, so the wait is\n * heard as well as seen, without adding any text to the design.\n *\n * The single line of JavaScript reads the label from the dictionary, which is what\n * makes its default translatable. It is not behaviour: no event, no lifecycle, no\n * DOM access.\n */\nimport { computed } from 'vue'\n\nimport { useMessages } from '../../i18n/state'\n\ninterface SpinnerProps {\n /**\n * A size in pixels, understood exactly as VIcon's: it is the BOX the spinner\n * occupies, not the diameter of the ring, which is drawn slightly smaller inside\n * it. Left out, the box measures 1em and therefore follows the size of the text\n * around it, which is how the spinner stays proportionate inside a button or a\n * paragraph without being told anything.\n */\n size?: number\n /**\n * What screen readers announce while it turns. It falls back to the wording of the\n * design system dictionary, in the current language.\n */\n label?: string\n}\n\nconst props = withDefaults(defineProps<SpinnerProps>(), {\n size: undefined,\n label: undefined,\n})\n\nconst m = useMessages()\nconst resolvedLabel = computed(() => props.label ?? m.value.common.loading)\n</script>\n\n<template>\n <span\n class=\"v-spinner\"\n :style=\"size !== undefined ? { '--spinner-size': `${size}px` } : undefined\"\n role=\"status\"\n >\n <span class=\"v-spinner-circle\" aria-hidden=\"true\" />\n <span class=\"v-visually-hidden\">{{ resolvedLabel }}</span>\n </span>\n</template>\n\n<style>\n@layer vectis.components {\n .v-spinner {\n /* `--spinner-size` is the BOX the spinner occupies, exactly as `--vectis-icon-size`\n is for VIcon — and not the diameter of the ring. Sized in `em`, that box follows\n the text of whatever contains it, so a consumer can size it through font-size\n alone — VButton, VInput and VTextarea do exactly that, from their icon size. The\n `size` prop writes this same variable in pixels, inline, and therefore wins.\n\n The ring is then drawn at five sixths of the box, because that is the proportion\n Material Symbols draws `progress_activity` at: on its 960 grid the outer radius\n is 400, so the ink spans 800 of the 960 the glyph is scaled into. Anything a\n spinner stands in for is an icon, and matching that fraction is what makes the\n two read as the same size instead of the spinner looking a size up. */\n --spinner-size: 1em;\n --spinner-ring: calc(var(--spinner-size) * 5 / 6);\n display: inline-flex;\n align-items: center;\n justify-content: center;\n flex: none;\n width: var(--spinner-size);\n height: var(--spinner-size);\n }\n\n .v-spinner-circle {\n width: var(--spinner-ring);\n height: var(--spinner-ring);\n /* The stroke is a tenth of the ring's diameter, the same source again: the glyph's\n outer radius is 400 and its inner one 320, so its stroke is 80 of those 800. It\n stays in proportion at every size, with a one-pixel floor below which the ring\n would disappear — a floor that only bites under a 12px box, which no size of the\n design system reaches. A bare ratio is tolerated here, like the opacities. */\n border: max(1px, calc(var(--spinner-ring) / 10)) solid\n color-mix(in oklab, currentcolor, transparent 75%);\n border-block-start-color: currentcolor;\n border-radius: var(--vectis-radius-full);\n animation: v-spin var(--vectis-duration-1000) linear infinite;\n }\n\n /* The `v-spin` keyframes live in styles/utilities.css, shared with\n VProgressCircular. Keyframes are global names rather than declarations arbitrated\n by the cascade, so they sit outside any layer and are declared once for the whole\n design system. */\n\n @media (prefers-reduced-motion: reduce) {\n .v-spinner-circle {\n animation-duration: var(--vectis-duration-3000);\n }\n }\n}\n</style>\n"],"mappings":";;;;;;;;;;EAgCA,IAAM,IAAQ,GAKR,IAAI,EAAY,GAChB,IAAgB,QAAe,EAAM,SAAS,EAAE,MAAM,OAAO,OAAO;yBAIxE,EAOO,QAAA;GANL,OAAM;GACL,OAAK,EAAE,EAAA,SAAS,KAAA,IAAgD,KAAA,IAAvC,EAAA,kBAAA,GAA0B,EAAA,KAAI,IAAA,CAAkB;GAC1E,MAAK;eAEL,EAAoD,QAAA;GAA9C,OAAM;GAAmB,eAAY;gBAC3C,EAA0D,QAA1D,GAA0D,EAAvB,EAAA,KAAa,GAAA,CAAA,CAAA,GAAA,CAAA"}
@@ -0,0 +1,2 @@
1
+ @layer vectis.reset, vectis.tokens, vectis.components, vectis.utilities;
2
+ @layer vectis.components{.v-switch{--switch-track-w:var(--vectis-control-size-switch-w);--switch-track-h:var(--vectis-control-size-switch-h);--switch-pad:2px;align-items:center;gap:var(--vectis-space-2);font-family:var(--vectis-text-family);font-size:var(--vectis-text-label-size);color:var(--vectis-color-text);cursor:pointer;display:inline-flex}.v-switch[data-label-position=start]{flex-direction:row-reverse}.v-switch[data-spread]{justify-content:space-between;display:flex}.v-switch-input{opacity:0;pointer-events:none;width:1px;height:1px;margin:0;position:absolute}.v-switch-track{width:var(--switch-track-w);height:var(--switch-track-h);padding:var(--switch-pad);background:var(--vectis-color-border-strong);border-radius:var(--vectis-radius-full);transition:background-color var(--vectis-duration-fast) var(--vectis-ease-default);flex:none;align-items:center;display:inline-flex}.v-switch-thumb{width:calc(var(--switch-track-h) - var(--switch-pad) * 2);height:calc(var(--switch-track-h) - var(--switch-pad) * 2);background:var(--vectis-color-surface);border-radius:var(--vectis-radius-full);box-shadow:var(--vectis-shadow-xs);transition:margin-inline-start var(--vectis-duration-base) var(--vectis-ease-default)}.v-switch-input:checked+.v-switch-track{background:var(--vectis-color-accent)}.v-switch-input:checked+.v-switch-track .v-switch-thumb{margin-inline-start:calc(var(--switch-track-w) - var(--switch-track-h))}.v-switch:hover .v-switch-input:not(:disabled):not(:checked)+.v-switch-track{background:color-mix(in oklab, var(--vectis-color-border-strong), var(--vectis-color-text) 12%)}.v-switch-input:focus-visible+.v-switch-track{outline:var(--vectis-focus-ring-width) solid var(--vectis-focus-ring-color);outline-offset:var(--vectis-focus-ring-offset)}.v-switch:has(.v-switch-input:disabled){color:var(--vectis-color-text-subtle);cursor:not-allowed}.v-switch-input:disabled+.v-switch-track{background:var(--vectis-color-surface-muted)}.v-switch-input:disabled+.v-switch-track .v-switch-thumb{background:var(--vectis-color-text-subtle);box-shadow:none}@media (prefers-reduced-motion:reduce){.v-switch-track,.v-switch-thumb{transition:none}}}
@@ -0,0 +1,46 @@
1
+ /**
2
+ * A switch, for a setting that takes effect at once — where a checkbox states an
3
+ * intention to be confirmed later.
4
+ *
5
+ * Underneath it is a native checkbox marked `role="switch"`, so a screen reader
6
+ * announces it as on or off rather than as ticked, and the keyboard and the form
7
+ * behaviour come along for free. The track and the moving thumb are pure CSS,
8
+ * following the input's checked state; the only JavaScript is the v-model.
9
+ */
10
+ interface SwitchProps {
11
+ /** Which side of the switch the label sits on. */
12
+ labelPosition?: 'start' | 'end';
13
+ /**
14
+ * Pushes the label and the switch to opposite ends of the line, the row taking the
15
+ * full width available — the usual shape for a list of settings.
16
+ */
17
+ spread?: boolean;
18
+ /** Makes the switch unusable, greyed out through the colour tokens. */
19
+ disabled?: boolean;
20
+ }
21
+ type __VLS_Props = SwitchProps;
22
+ type __VLS_Slots = {
23
+ /** The label. It is clickable, the whole component being wrapped in a `<label>`. */
24
+ default?(): unknown;
25
+ };
26
+ type __VLS_ModelProps = {
27
+ modelValue?: boolean;
28
+ };
29
+ type __VLS_PublicProps = __VLS_Props & __VLS_ModelProps;
30
+ declare const __VLS_base: import('vue').DefineComponent<__VLS_PublicProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
31
+ "update:modelValue": (value: boolean) => any;
32
+ }, string, import('vue').PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
33
+ "onUpdate:modelValue"?: ((value: boolean) => any) | undefined;
34
+ }>, {
35
+ disabled: boolean;
36
+ labelPosition: "start" | "end";
37
+ spread: boolean;
38
+ }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
39
+ declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
40
+ declare const _default: typeof __VLS_export;
41
+ export default _default;
42
+ type __VLS_WithSlots<T, S> = T & {
43
+ new (): {
44
+ $slots: S;
45
+ };
46
+ };
@@ -0,0 +1,9 @@
1
+ import './VSwitch.css';
2
+ import e from "./VSwitch.vue_vue_type_script_setup_true_lang.js";
3
+ /* empty css */
4
+ //#region src/components/VSwitch/VSwitch.vue
5
+ var t = e;
6
+ //#endregion
7
+ export { t as default };
8
+
9
+ //# sourceMappingURL=VSwitch.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"VSwitch.js","names":[],"sources":["../../../src/components/VSwitch/VSwitch.vue"],"sourcesContent":["<script setup lang=\"ts\">\n/**\n * A switch, for a setting that takes effect at once — where a checkbox states an\n * intention to be confirmed later.\n *\n * Underneath it is a native checkbox marked `role=\"switch\"`, so a screen reader\n * announces it as on or off rather than as ticked, and the keyboard and the form\n * behaviour come along for free. The track and the moving thumb are pure CSS,\n * following the input's checked state; the only JavaScript is the v-model.\n */\ninterface SwitchProps {\n /** Which side of the switch the label sits on. */\n labelPosition?: 'start' | 'end'\n /**\n * Pushes the label and the switch to opposite ends of the line, the row taking the\n * full width available — the usual shape for a list of settings.\n */\n spread?: boolean\n /** Makes the switch unusable, greyed out through the colour tokens. */\n disabled?: boolean\n}\n\nwithDefaults(defineProps<SwitchProps>(), {\n labelPosition: 'end',\n spread: false,\n disabled: false,\n})\n\n// @a11y\n// The root element is the <label>, so the attributes the consumer passes have to be\n// redirected onto the input: `name` for the form, and the aria-* for the element\n// that actually carries the switch role.\ndefineOptions({ inheritAttrs: false })\n\nconst model = defineModel<boolean>({ default: false })\n\ndefineSlots<{\n /** The label. It is clickable, the whole component being wrapped in a `<label>`. */\n default?(): unknown\n}>()\n</script>\n\n<template>\n <label class=\"v-switch\" :data-label-position=\"labelPosition\" :data-spread=\"spread || undefined\">\n <input\n v-model=\"model\"\n type=\"checkbox\"\n role=\"switch\"\n class=\"v-switch-input\"\n v-bind=\"$attrs\"\n :disabled=\"disabled\"\n />\n <span class=\"v-switch-track\" aria-hidden=\"true\">\n <span class=\"v-switch-thumb\" />\n </span>\n <span v-if=\"$slots.default\" class=\"v-switch-label\"><slot /></span>\n </label>\n</template>\n\n<style>\n@layer vectis.components {\n .v-switch {\n --switch-track-w: var(--vectis-control-size-switch-w);\n --switch-track-h: var(--vectis-control-size-switch-h);\n --switch-pad: 2px;\n display: inline-flex;\n align-items: center;\n gap: var(--vectis-space-2);\n font-family: var(--vectis-text-family);\n font-size: var(--vectis-text-label-size);\n color: var(--vectis-color-text);\n cursor: pointer;\n }\n\n /* The input is taken out of the flow by its absolute position, so reversing the\n row only ever swaps the track and the label. */\n .v-switch[data-label-position='start'] {\n flex-direction: row-reverse;\n }\n\n .v-switch[data-spread] {\n display: flex;\n justify-content: space-between;\n }\n\n /* Hidden with `opacity` and never with `display: none`, which would take the input\n out of the tab order and out of the form. */\n .v-switch-input {\n position: absolute;\n opacity: 0;\n width: 1px;\n height: 1px;\n margin: 0;\n pointer-events: none;\n }\n\n .v-switch-track {\n display: inline-flex;\n align-items: center;\n width: var(--switch-track-w);\n height: var(--switch-track-h);\n padding: var(--switch-pad);\n flex: none;\n background: var(--vectis-color-border-strong);\n border-radius: var(--vectis-radius-full);\n transition: background-color var(--vectis-duration-fast) var(--vectis-ease-default);\n }\n\n .v-switch-thumb {\n width: calc(var(--switch-track-h) - var(--switch-pad) * 2);\n height: calc(var(--switch-track-h) - var(--switch-pad) * 2);\n background: var(--vectis-color-surface);\n border-radius: var(--vectis-radius-full);\n box-shadow: var(--vectis-shadow-xs);\n /* The thumb travels through `margin-inline-start` rather than a translation,\n because a logical property follows the reading direction: in a right-to-left\n page the thumb then moves leftwards on its own, where a translateX would have\n to be mirrored by a second rule. */\n transition: margin-inline-start var(--vectis-duration-base) var(--vectis-ease-default);\n }\n\n .v-switch-input:checked + .v-switch-track {\n background: var(--vectis-color-accent);\n }\n\n .v-switch-input:checked + .v-switch-track .v-switch-thumb {\n margin-inline-start: calc(var(--switch-track-w) - var(--switch-track-h));\n }\n\n .v-switch:hover .v-switch-input:not(:disabled):not(:checked) + .v-switch-track {\n background: color-mix(\n in oklab,\n var(--vectis-color-border-strong),\n var(--vectis-color-text) 12%\n );\n }\n\n .v-switch-input:focus-visible + .v-switch-track {\n outline: var(--vectis-focus-ring-width) solid var(--vectis-focus-ring-color);\n outline-offset: var(--vectis-focus-ring-offset);\n }\n\n /* A disabled switch greys out through the colour tokens, the same ones VCheckbox\n and VRadio use, and never through opacity. The thumb takes text-subtle — the\n colour their disabled tick and dot take — which is what keeps it visible against\n the grey track in both themes. */\n .v-switch:has(.v-switch-input:disabled) {\n color: var(--vectis-color-text-subtle);\n cursor: not-allowed;\n }\n\n .v-switch-input:disabled + .v-switch-track {\n background: var(--vectis-color-surface-muted);\n }\n\n .v-switch-input:disabled + .v-switch-track .v-switch-thumb {\n background: var(--vectis-color-text-subtle);\n box-shadow: none;\n }\n\n @media (prefers-reduced-motion: reduce) {\n .v-switch-track,\n .v-switch-thumb {\n transition: none;\n }\n }\n}\n</style>\n"],"mappings":""}
@@ -0,0 +1,51 @@
1
+ import { createCommentVNode as e, createElementBlock as t, createElementVNode as n, defineComponent as r, mergeModels as i, mergeProps as a, openBlock as o, renderSlot as s, useModel as c, vModelCheckbox as l, withDirectives as u } from "vue";
2
+ //#region src/components/VSwitch/VSwitch.vue?vue&type=script&setup=true&lang.ts
3
+ var d = ["data-label-position", "data-spread"], f = ["disabled"], p = {
4
+ key: 0,
5
+ class: "v-switch-label"
6
+ }, m = /*@__PURE__*/ r({
7
+ inheritAttrs: !1,
8
+ __name: "VSwitch",
9
+ props: /*@__PURE__*/ i({
10
+ labelPosition: { default: "end" },
11
+ spread: {
12
+ type: Boolean,
13
+ default: !1
14
+ },
15
+ disabled: {
16
+ type: Boolean,
17
+ default: !1
18
+ }
19
+ }, {
20
+ modelValue: {
21
+ type: Boolean,
22
+ default: !1
23
+ },
24
+ modelModifiers: {}
25
+ }),
26
+ emits: ["update:modelValue"],
27
+ setup(r) {
28
+ let i = c(r, "modelValue");
29
+ return (c, m) => (o(), t("label", {
30
+ class: "v-switch",
31
+ "data-label-position": r.labelPosition,
32
+ "data-spread": r.spread || void 0
33
+ }, [
34
+ u(n("input", a({
35
+ "onUpdate:modelValue": m[0] ||= (e) => i.value = e,
36
+ type: "checkbox",
37
+ role: "switch",
38
+ class: "v-switch-input"
39
+ }, c.$attrs, { disabled: r.disabled }), null, 16, f), [[l, i.value]]),
40
+ m[1] ||= n("span", {
41
+ class: "v-switch-track",
42
+ "aria-hidden": "true"
43
+ }, [n("span", { class: "v-switch-thumb" })], -1),
44
+ c.$slots.default ? (o(), t("span", p, [s(c.$slots, "default")])) : e("", !0)
45
+ ], 8, d));
46
+ }
47
+ });
48
+ //#endregion
49
+ export { m as default };
50
+
51
+ //# sourceMappingURL=VSwitch.vue_vue_type_script_setup_true_lang.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"VSwitch.vue_vue_type_script_setup_true_lang.js","names":["$attrs","$slots"],"sources":["../../../src/components/VSwitch/VSwitch.vue"],"sourcesContent":["<script setup lang=\"ts\">\n/**\n * A switch, for a setting that takes effect at once — where a checkbox states an\n * intention to be confirmed later.\n *\n * Underneath it is a native checkbox marked `role=\"switch\"`, so a screen reader\n * announces it as on or off rather than as ticked, and the keyboard and the form\n * behaviour come along for free. The track and the moving thumb are pure CSS,\n * following the input's checked state; the only JavaScript is the v-model.\n */\ninterface SwitchProps {\n /** Which side of the switch the label sits on. */\n labelPosition?: 'start' | 'end'\n /**\n * Pushes the label and the switch to opposite ends of the line, the row taking the\n * full width available — the usual shape for a list of settings.\n */\n spread?: boolean\n /** Makes the switch unusable, greyed out through the colour tokens. */\n disabled?: boolean\n}\n\nwithDefaults(defineProps<SwitchProps>(), {\n labelPosition: 'end',\n spread: false,\n disabled: false,\n})\n\n// @a11y\n// The root element is the <label>, so the attributes the consumer passes have to be\n// redirected onto the input: `name` for the form, and the aria-* for the element\n// that actually carries the switch role.\ndefineOptions({ inheritAttrs: false })\n\nconst model = defineModel<boolean>({ default: false })\n\ndefineSlots<{\n /** The label. It is clickable, the whole component being wrapped in a `<label>`. */\n default?(): unknown\n}>()\n</script>\n\n<template>\n <label class=\"v-switch\" :data-label-position=\"labelPosition\" :data-spread=\"spread || undefined\">\n <input\n v-model=\"model\"\n type=\"checkbox\"\n role=\"switch\"\n class=\"v-switch-input\"\n v-bind=\"$attrs\"\n :disabled=\"disabled\"\n />\n <span class=\"v-switch-track\" aria-hidden=\"true\">\n <span class=\"v-switch-thumb\" />\n </span>\n <span v-if=\"$slots.default\" class=\"v-switch-label\"><slot /></span>\n </label>\n</template>\n\n<style>\n@layer vectis.components {\n .v-switch {\n --switch-track-w: var(--vectis-control-size-switch-w);\n --switch-track-h: var(--vectis-control-size-switch-h);\n --switch-pad: 2px;\n display: inline-flex;\n align-items: center;\n gap: var(--vectis-space-2);\n font-family: var(--vectis-text-family);\n font-size: var(--vectis-text-label-size);\n color: var(--vectis-color-text);\n cursor: pointer;\n }\n\n /* The input is taken out of the flow by its absolute position, so reversing the\n row only ever swaps the track and the label. */\n .v-switch[data-label-position='start'] {\n flex-direction: row-reverse;\n }\n\n .v-switch[data-spread] {\n display: flex;\n justify-content: space-between;\n }\n\n /* Hidden with `opacity` and never with `display: none`, which would take the input\n out of the tab order and out of the form. */\n .v-switch-input {\n position: absolute;\n opacity: 0;\n width: 1px;\n height: 1px;\n margin: 0;\n pointer-events: none;\n }\n\n .v-switch-track {\n display: inline-flex;\n align-items: center;\n width: var(--switch-track-w);\n height: var(--switch-track-h);\n padding: var(--switch-pad);\n flex: none;\n background: var(--vectis-color-border-strong);\n border-radius: var(--vectis-radius-full);\n transition: background-color var(--vectis-duration-fast) var(--vectis-ease-default);\n }\n\n .v-switch-thumb {\n width: calc(var(--switch-track-h) - var(--switch-pad) * 2);\n height: calc(var(--switch-track-h) - var(--switch-pad) * 2);\n background: var(--vectis-color-surface);\n border-radius: var(--vectis-radius-full);\n box-shadow: var(--vectis-shadow-xs);\n /* The thumb travels through `margin-inline-start` rather than a translation,\n because a logical property follows the reading direction: in a right-to-left\n page the thumb then moves leftwards on its own, where a translateX would have\n to be mirrored by a second rule. */\n transition: margin-inline-start var(--vectis-duration-base) var(--vectis-ease-default);\n }\n\n .v-switch-input:checked + .v-switch-track {\n background: var(--vectis-color-accent);\n }\n\n .v-switch-input:checked + .v-switch-track .v-switch-thumb {\n margin-inline-start: calc(var(--switch-track-w) - var(--switch-track-h));\n }\n\n .v-switch:hover .v-switch-input:not(:disabled):not(:checked) + .v-switch-track {\n background: color-mix(\n in oklab,\n var(--vectis-color-border-strong),\n var(--vectis-color-text) 12%\n );\n }\n\n .v-switch-input:focus-visible + .v-switch-track {\n outline: var(--vectis-focus-ring-width) solid var(--vectis-focus-ring-color);\n outline-offset: var(--vectis-focus-ring-offset);\n }\n\n /* A disabled switch greys out through the colour tokens, the same ones VCheckbox\n and VRadio use, and never through opacity. The thumb takes text-subtle — the\n colour their disabled tick and dot take — which is what keeps it visible against\n the grey track in both themes. */\n .v-switch:has(.v-switch-input:disabled) {\n color: var(--vectis-color-text-subtle);\n cursor: not-allowed;\n }\n\n .v-switch-input:disabled + .v-switch-track {\n background: var(--vectis-color-surface-muted);\n }\n\n .v-switch-input:disabled + .v-switch-track .v-switch-thumb {\n background: var(--vectis-color-text-subtle);\n box-shadow: none;\n }\n\n @media (prefers-reduced-motion: reduce) {\n .v-switch-track,\n .v-switch-thumb {\n transition: none;\n }\n }\n}\n</style>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;EAkCA,IAAM,IAAQ,EAAoB,GAAA,YAAmB;yBASnD,EAaQ,SAAA;GAbD,OAAM;GAAY,uBAAqB,EAAA;GAAgB,eAAa,EAAA,UAAU,KAAA;;KACnF,EAOE,SAPF,EAOE;6CANc,QAAA;IACd,MAAK;IACL,MAAK;IACL,OAAM;MACEA,EAAAA,QAAM,EACb,UAAU,EAAA,SAAQ,CAAA,GAAA,MAAA,IAAA,CAAA,GAAA,CAAA,CAAA,GALV,EAAA,KAAK,CAAA,CAAA;YAOhB,EAEO,QAAA;IAFD,OAAM;IAAiB,eAAY;OACvC,EAA+B,QAAA,EAAzB,OAAM,iBAAgB,CAAA,CAAA,GAAA,EAAA;GAElBC,EAAAA,OAAO,WAAA,EAAA,GAAnB,EAAkE,QAAlE,GAAkE,CAAf,EAAQ,EAAA,QAAA,SAAA,CAAA,CAAA,KAAA,EAAA,IAAA,EAAA"}
@@ -0,0 +1,2 @@
1
+ @layer vectis.reset, vectis.tokens, vectis.components, vectis.utilities;
2
+ @layer vectis.components{.v-tab[data-size]{white-space:nowrap;flex:none;position:relative}.v-tab[data-size][data-icon-only]{min-inline-size:var(--control-height);padding-inline:0}.v-tab[data-size]:focus-visible{outline-offset:calc(var(--vectis-focus-ring-offset) * -1)}.v-tab-label{text-overflow:ellipsis;overflow:hidden}.v-tabs[data-grow] .v-tab[data-size]{flex:1 1 0;min-inline-size:0}.v-tabs[data-variant=inset] .v-tab[data-size]{border-radius:calc(var(--vectis-radius-surface) - var(--vectis-space-1))}.v-tabs:is([data-variant=flat],[data-variant=outlined]) .v-tab[data-size]{border-radius:0}.v-tabs[data-variant=outlined] .v-tab[data-size]:first-of-type{border-start-start-radius:var(--vectis-radius-interactive)}.v-tabs[data-variant=outlined][data-orientation=horizontal] .v-tab[data-size]:last-of-type{border-start-end-radius:var(--vectis-radius-interactive)}.v-tabs[data-variant=outlined][data-orientation=vertical] .v-tab[data-size]:last-of-type{border-end-start-radius:var(--vectis-radius-interactive)}.v-tabs:is([data-variant=flat],[data-variant=outlined]) .v-tab[data-size]:after{content:"";block-size:var(--vectis-control-size-tab-indicator);opacity:0;transition:opacity var(--vectis-duration-fast) var(--vectis-ease-default);background:currentColor;position:absolute;inset-block-end:0;inset-inline:0}.v-tabs:is([data-variant=flat],[data-variant=outlined])[data-orientation=vertical] .v-tab[data-size]:after{block-size:auto;inline-size:var(--vectis-control-size-tab-indicator);inset-block:0;inset-inline:0 auto}.v-tabs:is([data-variant=flat],[data-variant=outlined]) .v-tab[data-size][aria-selected=true]:after{opacity:1}@media (prefers-reduced-motion:reduce){.v-tabs:is([data-variant=flat],[data-variant=outlined]) .v-tab[data-size]:after{transition:none}}}