maz-ui 3.43.4 → 3.44.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 (358) hide show
  1. package/components/MazAccordion.d.ts +2 -2
  2. package/components/MazAccordion.mjs +84 -84
  3. package/components/MazAnimatedCounter.mjs +9 -10
  4. package/components/MazAvatar.d.ts +3 -3
  5. package/components/MazAvatar.mjs +1 -1
  6. package/components/MazBackdrop.d.ts +2 -2
  7. package/components/MazBackdrop.mjs +12 -10
  8. package/components/MazBadge.d.ts +2 -2
  9. package/components/MazBadge.mjs +3 -4
  10. package/components/MazBottomSheet.mjs +1 -1
  11. package/components/MazBtn.d.ts +7 -5
  12. package/components/MazBtn.mjs +1 -1
  13. package/components/MazCard.d.ts +3 -3
  14. package/components/MazCard.mjs +1 -1
  15. package/components/MazCardSpotlight.d.ts +2 -2
  16. package/components/MazCardSpotlight.mjs +4 -5
  17. package/components/MazCarousel.d.ts +2 -2
  18. package/components/MazCarousel.mjs +1 -1
  19. package/components/MazChart.d.ts +1 -1
  20. package/components/MazCheckbox.d.ts +2 -2
  21. package/components/MazCheckbox.mjs +10 -11
  22. package/components/MazCircularProgressBar.d.ts +1 -1
  23. package/components/MazCircularProgressBar.mjs +21 -23
  24. package/components/MazDialog.d.ts +2 -2
  25. package/components/MazDialog.mjs +1 -1
  26. package/components/MazDialogPromise/use-maz-dialog-promise.d.ts +17 -14
  27. package/components/MazDialogPromise.mjs +1 -1
  28. package/components/MazDrawer.d.ts +2 -2
  29. package/components/MazDrawer.mjs +71 -69
  30. package/components/MazDropdown.d.ts +7 -6
  31. package/components/MazDropdown.mjs +130 -128
  32. package/components/MazDropzone.d.ts +1 -1
  33. package/components/MazDropzone.mjs +1 -1
  34. package/components/MazExpandAnimation.d.ts +2 -2
  35. package/components/MazExpandAnimation.mjs +26 -26
  36. package/components/MazFullscreenLoader.d.ts +2 -2
  37. package/components/MazFullscreenLoader.mjs +11 -10
  38. package/components/MazGallery.d.ts +2 -2
  39. package/components/MazGallery.mjs +1 -1
  40. package/components/MazIcon.mjs +45 -34
  41. package/components/MazInput.d.ts +4 -4
  42. package/components/MazInput.mjs +1 -1
  43. package/components/MazInputCode.d.ts +2 -2
  44. package/components/MazInputCode.mjs +4 -5
  45. package/components/MazInputNumber.d.ts +2 -2
  46. package/components/MazInputNumber.mjs +1 -1
  47. package/components/MazInputPrice.d.ts +2 -2
  48. package/components/MazInputPrice.mjs +1 -1
  49. package/components/MazInputTags.d.ts +7 -2
  50. package/components/MazInputTags.mjs +1 -1
  51. package/components/MazLazyImg.d.ts +2 -2
  52. package/components/MazLazyImg.mjs +1 -1
  53. package/components/MazLink.d.ts +6 -6
  54. package/components/MazLink.mjs +3 -4
  55. package/components/MazLoadingBar.d.ts +2 -2
  56. package/components/MazLoadingBar.mjs +17 -18
  57. package/components/MazPagination.d.ts +3 -3
  58. package/components/MazPagination.mjs +1 -1
  59. package/components/MazPhoneNumberInput/CountrySelector.vue.d.ts +1 -1
  60. package/components/MazPhoneNumberInput/types.d.ts +5 -5
  61. package/components/MazPhoneNumberInput/use-libphonenumber.d.ts +1 -1
  62. package/components/MazPhoneNumberInput/use-maz-phone-number-input.d.ts +1 -1
  63. package/components/MazPhoneNumberInput.d.ts +8 -8
  64. package/components/MazPhoneNumberInput.mjs +1 -1
  65. package/components/MazPicker/MazPickerCalendarMonth/MazPickerCalendarGrid.vue.d.ts +1 -1
  66. package/components/MazPicker/MazPickerCalendarMonth/MazPickerCalendarMonth.vue.d.ts +2 -2
  67. package/components/MazPicker/MazPickerFooter.vue.d.ts +1 -1
  68. package/components/MazPicker/MazPickerTime.vue.d.ts +1 -1
  69. package/components/MazPicker/types.d.ts +4 -4
  70. package/components/MazPicker/utils.d.ts +4 -4
  71. package/components/MazPicker.d.ts +3 -3
  72. package/components/MazPicker.mjs +1 -1
  73. package/components/MazPullToRefresh.d.ts +2 -2
  74. package/components/MazPullToRefresh.mjs +1 -1
  75. package/components/MazRadio.mjs +8 -9
  76. package/components/MazRadioButtons.d.ts +2 -2
  77. package/components/MazRadioButtons.mjs +44 -42
  78. package/components/MazReadingProgressBar.d.ts +2 -2
  79. package/components/MazReadingProgressBar.mjs +12 -13
  80. package/components/MazSelect.d.ts +4 -4
  81. package/components/MazSelect.mjs +1 -1
  82. package/components/MazSlider/utils.d.ts +4 -4
  83. package/components/MazSlider.mjs +100 -87
  84. package/components/MazSpinner.mjs +6 -7
  85. package/components/MazStepper.d.ts +3 -3
  86. package/components/MazStepper.mjs +1 -1
  87. package/components/MazSwitch.d.ts +2 -2
  88. package/components/MazSwitch.mjs +6 -6
  89. package/components/MazTable.d.ts +13 -10
  90. package/components/MazTable.mjs +1 -1
  91. package/components/MazTableCell.mjs +4 -5
  92. package/components/MazTableRow.d.ts +2 -2
  93. package/components/MazTableRow.mjs +4 -5
  94. package/components/MazTableTitle.mjs +2 -3
  95. package/components/MazTabs.d.ts +4 -4
  96. package/components/MazTabsBar.d.ts +7 -5
  97. package/components/MazTabsBar.mjs +1 -1
  98. package/components/MazTabsContent.mjs +5 -4
  99. package/components/MazTabsContentItem.mjs +16 -17
  100. package/components/MazTextarea.d.ts +2 -2
  101. package/components/MazTextarea.mjs +19 -17
  102. package/components/MazTransitionExpand.d.ts +2 -2
  103. package/components/MazTransitionExpand.mjs +19 -18
  104. package/components/assets/MazAccordion.css +1 -1
  105. package/components/assets/MazAnimatedCounter.css +1 -1
  106. package/components/assets/MazAvatar.css +1 -1
  107. package/components/assets/MazBadge.css +1 -1
  108. package/components/assets/MazBottomSheet.css +1 -1
  109. package/components/assets/MazBtn.css +1 -1
  110. package/components/assets/MazCard.css +1 -1
  111. package/components/assets/MazCardSpotlight.css +1 -1
  112. package/components/assets/MazCarousel.css +1 -1
  113. package/components/assets/MazCheckbox.css +1 -1
  114. package/components/assets/MazCircularProgressBar.css +1 -1
  115. package/components/assets/MazDialog.css +1 -1
  116. package/components/assets/MazDialogPromise.css +1 -1
  117. package/components/assets/MazExpandAnimation.css +1 -1
  118. package/components/assets/MazGallery.css +1 -1
  119. package/components/assets/MazInput.css +1 -1
  120. package/components/assets/MazInputCode.css +1 -1
  121. package/components/assets/MazInputNumber.css +1 -1
  122. package/components/assets/MazInputPrice.css +1 -1
  123. package/components/assets/MazInputTags.css +1 -1
  124. package/components/assets/MazLazyImg.css +1 -1
  125. package/components/assets/MazLink.css +1 -1
  126. package/components/assets/MazLoadingBar.css +1 -1
  127. package/components/assets/MazPagination.css +1 -1
  128. package/components/assets/MazPhoneNumberInput.css +1 -1
  129. package/components/assets/MazPicker.css +1 -1
  130. package/components/assets/MazPickerMonthSwitcher.css +1 -1
  131. package/components/assets/MazPickerShortcuts.css +1 -1
  132. package/components/assets/MazPickerYearSwitcher.css +1 -1
  133. package/components/assets/MazPullToRefresh.css +1 -1
  134. package/components/assets/MazRadio.css +1 -1
  135. package/components/assets/MazRadioButtons.css +1 -1
  136. package/components/assets/MazReadingProgressBar.css +1 -1
  137. package/components/assets/MazSelect.css +1 -1
  138. package/components/assets/MazSlider.css +1 -1
  139. package/components/assets/MazSpinner.css +1 -1
  140. package/components/assets/MazStepper.css +1 -1
  141. package/components/assets/MazSwitch.css +1 -1
  142. package/components/assets/MazTable.css +1 -1
  143. package/components/assets/MazTableCell.css +1 -1
  144. package/components/assets/MazTableRow.css +1 -1
  145. package/components/assets/MazTableTitle.css +1 -1
  146. package/components/assets/MazTabsBar.css +1 -1
  147. package/components/assets/MazTabsContentItem.css +1 -1
  148. package/components/assets/MazTextarea.css +1 -1
  149. package/components/assets/MazTransitionExpand.css +1 -1
  150. package/components/chunks/{MazAvatar-DsJvzyS9.mjs → MazAvatar-BU1nJFcV.mjs} +8 -9
  151. package/components/chunks/{MazBadge-CYJlqITD.mjs → MazBadge-CwA0md19.mjs} +4 -5
  152. package/components/chunks/{MazBottomSheet-CIlIdn-2.mjs → MazBottomSheet-DUOIusEi.mjs} +54 -52
  153. package/components/chunks/{MazBtn-CCNGs6oo.mjs → MazBtn-5BSKOcqG.mjs} +35 -36
  154. package/components/chunks/{MazBtn-Ccvl1ZWv.mjs → MazBtn-B1-sTc7F.mjs} +31 -32
  155. package/components/chunks/{MazBtn-BC5OegPu.mjs → MazBtn-BY8WCtM7.mjs} +35 -36
  156. package/components/chunks/{MazBtn-CX4OgPzp.mjs → MazBtn-C5G78zLg.mjs} +35 -36
  157. package/components/chunks/MazBtn-CeVwyYR5.mjs +150 -0
  158. package/components/chunks/{MazBtn-BqgdERYQ.mjs → MazBtn-ColLVUca.mjs} +35 -36
  159. package/components/chunks/{MazBtn-beTASOLt.mjs → MazBtn-DJhQqzja.mjs} +35 -36
  160. package/components/chunks/MazBtn-DuY28-0U.mjs +150 -0
  161. package/components/chunks/{MazBtn-BydIwD1J.mjs → MazBtn-f1mBXJeU.mjs} +31 -32
  162. package/components/chunks/MazBtn-h3WmmaEO.mjs +150 -0
  163. package/components/chunks/MazBtn-zyRLUViT.mjs +150 -0
  164. package/components/chunks/{MazCard-bmiVPg8p.mjs → MazCard-BWxV_Z-i.mjs} +25 -26
  165. package/components/chunks/{MazCarousel-CL0bMygd.mjs → MazCarousel-D5EmW7Sa.mjs} +43 -35
  166. package/components/chunks/{MazCheckbox-DsFbvpp4.mjs → MazCheckbox-BWiMbecz.mjs} +11 -12
  167. package/components/chunks/{MazCheckbox-CCa7grGF.mjs → MazCheckbox-D3PXkt75.mjs} +11 -12
  168. package/components/chunks/{MazDialog-BckFta4N.mjs → MazDialog-CLWKCphI.mjs} +56 -54
  169. package/components/chunks/{MazDialogPromise-Bb6h4hFz.mjs → MazDialogPromise-DVOJwdVp.mjs} +139 -126
  170. package/components/chunks/{MazDropzone-C_8mRUbK.mjs → MazDropzone-Dm2IirHm.mjs} +33 -54
  171. package/components/chunks/MazExpandAnimation-ChSSdQAq.mjs +58 -0
  172. package/components/chunks/{MazGallery-CcpeM_zk.mjs → MazGallery-BlfPe8WG.mjs} +103 -101
  173. package/components/chunks/{MazGallery-6UK5sH9P.mjs → MazGallery-Bn9p1gNb.mjs} +102 -100
  174. package/{modules/chunks/MazIcon-CiNswMKM.mjs → components/chunks/MazIcon-B8A0hQAH.mjs} +45 -34
  175. package/components/chunks/{MazIcon-Cxrv3_OK.mjs → MazIcon-BDGxCy9M.mjs} +45 -34
  176. package/components/chunks/{MazIcon-BKuhvwwq.mjs → MazIcon-D3umgnku.mjs} +45 -34
  177. package/components/chunks/{MazInput-DNwBL54e.mjs → MazInput-BpsE-mdg.mjs} +69 -69
  178. package/components/chunks/{MazInputNumber-BSdVF8-q.mjs → MazInputNumber-DGBYbDSX.mjs} +186 -182
  179. package/components/chunks/{MazInputPrice-osrAz4xd.mjs → MazInputPrice-j2BNMeFp.mjs} +134 -129
  180. package/components/chunks/{MazInputTags-XUWwx6p8.mjs → MazInputTags-CJofVaj5.mjs} +234 -252
  181. package/components/chunks/{MazLazyImg-6qrfqWKr.mjs → MazLazyImg-BFG6FIJZ.mjs} +6 -7
  182. package/components/chunks/{MazLazyImg-BelScAEF.mjs → MazLazyImg-Dboc6Xfz.mjs} +5 -6
  183. package/components/chunks/{MazPagination-DUiHgLAp.mjs → MazPagination-C6ZehQSZ.mjs} +118 -119
  184. package/components/chunks/{MazPhoneNumberInput-HeEEyDu0.mjs → MazPhoneNumberInput-DpWoNQfx.mjs} +707 -695
  185. package/components/chunks/MazPicker-ia2BEmm5.mjs +2531 -0
  186. package/components/chunks/{MazPickerMonthSwitcher-CoV-84J1.mjs → MazPickerMonthSwitcher-CKtfZ_m-.mjs} +19 -19
  187. package/components/chunks/{MazPickerShortcuts-5IfUIwpz.mjs → MazPickerShortcuts-Cc9VoqBw.mjs} +10 -10
  188. package/components/chunks/{MazPickerYearSwitcher-MeptqtZk.mjs → MazPickerYearSwitcher-0b5Wrem9.mjs} +10 -8
  189. package/components/chunks/{MazPullToRefresh-DWbmwlzV.mjs → MazPullToRefresh-CUazP4y2.mjs} +21 -22
  190. package/components/chunks/MazSelect-COJoKXbV.mjs +847 -0
  191. package/components/chunks/MazSpinner-9Jue6cel.mjs +37 -0
  192. package/components/chunks/{MazSpinner-BKjRRWtc.mjs → MazSpinner-BGPOws6a.mjs} +6 -7
  193. package/components/chunks/{MazSpinner-BXxULdoD.mjs → MazSpinner-BWYdqSMP.mjs} +6 -7
  194. package/components/chunks/{MazSpinner-BRgzRI07.mjs → MazSpinner-BZOjTZBN.mjs} +6 -7
  195. package/components/chunks/{MazSpinner-B-svzg-R.mjs → MazSpinner-BaAMq7LI.mjs} +6 -7
  196. package/components/chunks/MazSpinner-Bad2n-0k.mjs +37 -0
  197. package/components/chunks/MazSpinner-BxnVFqUu.mjs +37 -0
  198. package/components/chunks/{MazSpinner-Mvsi6uCt.mjs → MazSpinner-C41VyUup.mjs} +6 -7
  199. package/components/chunks/MazSpinner-C6StE-Mb.mjs +37 -0
  200. package/components/chunks/{MazSpinner-BFXwybUv.mjs → MazSpinner-CNIlbDfg.mjs} +6 -7
  201. package/components/chunks/MazSpinner-Cz2DHV6g.mjs +37 -0
  202. package/components/chunks/MazSpinner-D4CdHpP2.mjs +37 -0
  203. package/{modules/chunks/MazSpinner--jWWogVn.mjs → components/chunks/MazSpinner-DHQH6Bhz.mjs} +6 -7
  204. package/components/chunks/MazSpinner-DRj2VpGA.mjs +37 -0
  205. package/components/chunks/{MazSpinner-C1lg-Klx.mjs → MazSpinner-DkXequnp.mjs} +6 -7
  206. package/components/chunks/MazSpinner-EA5ejB8F.mjs +37 -0
  207. package/components/chunks/{MazSpinner-BtpIL60X.mjs → MazSpinner-RvDGcBng.mjs} +6 -7
  208. package/components/chunks/{MazSpinner-B_WP-2kr.mjs → MazSpinner-V-bFi71W.mjs} +6 -7
  209. package/components/chunks/MazSpinner-aPFlrc5E.mjs +37 -0
  210. package/components/chunks/{MazSpinner-CfA_KEZT.mjs → MazSpinner-nH44Htog.mjs} +6 -7
  211. package/components/chunks/MazSpinner-nOD-7_sU.mjs +37 -0
  212. package/components/chunks/MazSpinner-yZGK-AQe.mjs +37 -0
  213. package/components/chunks/{MazStepper-DDofJsdg.mjs → MazStepper-DxrzKz06.mjs} +94 -83
  214. package/components/chunks/MazTable-DRUj_PZp.mjs +1960 -0
  215. package/components/chunks/{MazTabsBar-BXDEQkZM.mjs → MazTabsBar-xcIIXHx5.mjs} +67 -68
  216. package/components/chunks/{MazTransitionExpand-BwuAIzII.mjs → MazTransitionExpand-B08cSrmL.mjs} +20 -19
  217. package/components/chunks/{examples.mobile.json-um0ibyv5.mjs → examples.mobile.json-JpNGylGv.mjs} +1 -1
  218. package/css/main.css +1 -1
  219. package/modules/assets/MazBtn.css +1 -1
  220. package/modules/assets/MazSpinner.css +1 -1
  221. package/modules/assets/index.css +1 -1
  222. package/modules/chunks/{MazBtn-Czcbhr3Z.cjs → MazBtn-BbCGGxkK.cjs} +2 -2
  223. package/modules/chunks/{MazBtn-CXcW31TK.mjs → MazBtn-UBHTKqaN.mjs} +35 -36
  224. package/modules/chunks/MazIcon-BDSXZYZ8.cjs +1 -0
  225. package/{components/chunks/MazIcon-DtG5ii8R.mjs → modules/chunks/MazIcon-C2ch3jUS.mjs} +45 -34
  226. package/modules/chunks/{MazSpinner-Cw1KnqLM.cjs → MazSpinner-BiyFRA4w.cjs} +1 -1
  227. package/modules/chunks/MazSpinner-C9_xSbZZ.mjs +37 -0
  228. package/modules/chunks/{index-CThtJOu5.mjs → index-Cwbjspv3.mjs} +621 -588
  229. package/modules/chunks/index-tnjajVkX.cjs +124 -0
  230. package/modules/index.cjs +1 -1
  231. package/modules/index.mjs +34 -35
  232. package/nuxt/index.json +2 -2
  233. package/nuxt/index.mjs +3 -4
  234. package/nuxt/types.d.mts +24 -0
  235. package/nuxt/types.d.ts +24 -0
  236. package/package.json +77 -83
  237. package/resolvers/unplugin-directives-resolver.d.ts +1 -1
  238. package/resolvers/unplugin-vue-components-resolver.d.ts +1 -1
  239. package/tailwindcss/tailwind.config.ts +9 -2
  240. package/tailwindcss/utils/colors.ts +3 -3
  241. package/tailwindcss/variables/colors.ts +12 -12
  242. package/tailwindcss/variables/utilities.ts +2 -2
  243. package/tailwindcss/variables/z-indexes.ts +12 -11
  244. package/types/components/MazAccordion.vue.d.ts +2 -2
  245. package/types/components/MazAvatar.vue.d.ts +3 -3
  246. package/types/components/MazBackdrop.vue.d.ts +2 -2
  247. package/types/components/MazBadge.vue.d.ts +2 -2
  248. package/types/components/MazBtn.vue.d.ts +7 -5
  249. package/types/components/MazCard.vue.d.ts +3 -3
  250. package/types/components/MazCardSpotlight.vue.d.ts +2 -2
  251. package/types/components/MazCarousel.vue.d.ts +2 -2
  252. package/types/components/MazChart.vue.d.ts +1 -1
  253. package/types/components/MazCheckbox.vue.d.ts +2 -2
  254. package/types/components/MazCircularProgressBar.vue.d.ts +1 -1
  255. package/types/components/MazDialog.vue.d.ts +2 -2
  256. package/types/components/MazDialogPromise/use-maz-dialog-promise.d.ts +17 -14
  257. package/types/components/MazDrawer.vue.d.ts +2 -2
  258. package/types/components/MazDropdown.vue.d.ts +7 -6
  259. package/types/components/MazDropzone.vue.d.ts +1 -1
  260. package/types/components/MazExpandAnimation.vue.d.ts +2 -2
  261. package/types/components/MazFullscreenLoader.vue.d.ts +2 -2
  262. package/types/components/MazGallery.vue.d.ts +2 -2
  263. package/types/components/MazInput.vue.d.ts +4 -4
  264. package/types/components/MazInputCode.vue.d.ts +2 -2
  265. package/types/components/MazInputNumber.vue.d.ts +2 -2
  266. package/types/components/MazInputPrice.vue.d.ts +2 -2
  267. package/types/components/MazInputTags.vue.d.ts +7 -2
  268. package/types/components/MazLazyImg.vue.d.ts +2 -2
  269. package/types/components/MazLink.vue.d.ts +6 -6
  270. package/types/components/MazLoadingBar.vue.d.ts +2 -2
  271. package/types/components/MazPagination.vue.d.ts +3 -3
  272. package/types/components/MazPhoneNumberInput/CountrySelector.vue.d.ts +1 -1
  273. package/types/components/MazPhoneNumberInput/types.d.ts +5 -5
  274. package/types/components/MazPhoneNumberInput/use-libphonenumber.d.ts +1 -1
  275. package/types/components/MazPhoneNumberInput/use-maz-phone-number-input.d.ts +1 -1
  276. package/types/components/MazPhoneNumberInput.vue.d.ts +8 -8
  277. package/types/components/MazPicker/MazPickerCalendarMonth/MazPickerCalendarGrid.vue.d.ts +1 -1
  278. package/types/components/MazPicker/MazPickerCalendarMonth/MazPickerCalendarMonth.vue.d.ts +2 -2
  279. package/types/components/MazPicker/MazPickerFooter.vue.d.ts +1 -1
  280. package/types/components/MazPicker/MazPickerTime.vue.d.ts +1 -1
  281. package/types/components/MazPicker/types.d.ts +4 -4
  282. package/types/components/MazPicker/utils.d.ts +4 -4
  283. package/types/components/MazPicker.vue.d.ts +3 -3
  284. package/types/components/MazPullToRefresh.vue.d.ts +2 -2
  285. package/types/components/MazRadioButtons.vue.d.ts +2 -2
  286. package/types/components/MazReadingProgressBar.vue.d.ts +2 -2
  287. package/types/components/MazSelect.vue.d.ts +4 -4
  288. package/types/components/MazSlider/utils.d.ts +4 -4
  289. package/types/components/MazStepper.vue.d.ts +3 -3
  290. package/types/components/MazSwitch.vue.d.ts +2 -2
  291. package/types/components/MazTable.vue.d.ts +13 -10
  292. package/types/components/MazTableRow.vue.d.ts +2 -2
  293. package/types/components/MazTabs.vue.d.ts +4 -4
  294. package/types/components/MazTabsBar.vue.d.ts +7 -5
  295. package/types/components/MazTextarea.vue.d.ts +2 -2
  296. package/types/components/MazTransitionExpand.vue.d.ts +2 -2
  297. package/types/modules/composables/use-reading-time.d.ts +5 -5
  298. package/types/modules/composables/use-theme-handler.d.ts +2 -2
  299. package/types/modules/directives/closable.d.ts +2 -2
  300. package/types/modules/directives/tooltip/index.d.ts +4 -4
  301. package/types/modules/directives/v-fullscreen-img/MazFullscreenImg.vue.d.ts +2 -2
  302. package/types/modules/directives/v-lazy-img/index.d.ts +1 -1
  303. package/types/modules/filters/capitalize.d.ts +1 -1
  304. package/types/modules/filters/currency.d.ts +1 -1
  305. package/types/modules/filters/date.d.ts +1 -1
  306. package/types/modules/filters/index.d.ts +8 -4
  307. package/types/modules/filters/number.d.ts +1 -1
  308. package/types/modules/filters/telephone.d.ts +1 -1
  309. package/types/modules/helpers/idle-timeout/idle-timeout-handler.d.ts +1 -1
  310. package/types/modules/helpers/mount-component.d.ts +2 -2
  311. package/types/modules/helpers/normalize-string.d.ts +2 -2
  312. package/types/modules/helpers/swipe-handler.d.ts +2 -2
  313. package/types/modules/helpers/user-visibility/types.d.ts +2 -2
  314. package/types/modules/plugins/aos/index.d.ts +3 -3
  315. package/types/modules/plugins/index.d.ts +2 -2
  316. package/types/modules/plugins/toaster/MazToast.vue.d.ts +3 -3
  317. package/types/modules/plugins/toaster/index.d.ts +1 -2
  318. package/types/modules/plugins/toaster/types.d.ts +6 -6
  319. package/types/modules/plugins/wait/utils.d.ts +4 -4
  320. package/types/resolvers/unplugin-directives-resolver.d.ts +1 -1
  321. package/types/resolvers/unplugin-vue-components-resolver.d.ts +1 -1
  322. package/types/tailwindcss/tailwind.config.d.ts +71 -9
  323. package/types/tailwindcss/variables/z-indexes.d.ts +11 -11
  324. package/components/chunks/MazBtn-BOb7Fg_d.mjs +0 -151
  325. package/components/chunks/MazBtn-DpkJQ_3W.mjs +0 -151
  326. package/components/chunks/MazBtn-Dw_CR_0X.mjs +0 -151
  327. package/components/chunks/MazBtn-_NGDIlQK.mjs +0 -151
  328. package/components/chunks/MazExpandAnimation-Cin7sZ3I.mjs +0 -58
  329. package/components/chunks/MazPicker-CltoTa2Z.mjs +0 -2477
  330. package/components/chunks/MazSelect-DDKbowf3.mjs +0 -835
  331. package/components/chunks/MazSpinner-2ti3NQjo.mjs +0 -38
  332. package/components/chunks/MazSpinner-BZUmasIf.mjs +0 -38
  333. package/components/chunks/MazSpinner-C-lFmcUR.mjs +0 -38
  334. package/components/chunks/MazSpinner-C75WMoEA.mjs +0 -38
  335. package/components/chunks/MazSpinner-CA38Ikqe.mjs +0 -38
  336. package/components/chunks/MazSpinner-CAHOYqvB.mjs +0 -38
  337. package/components/chunks/MazSpinner-COOp2WX8.mjs +0 -38
  338. package/components/chunks/MazSpinner-D-ONjGGv.mjs +0 -38
  339. package/components/chunks/MazSpinner-DJkziC4O.mjs +0 -38
  340. package/components/chunks/MazSpinner-Di0F6oZz.mjs +0 -38
  341. package/components/chunks/MazSpinner-EcA0uOQv.mjs +0 -38
  342. package/components/chunks/MazSpinner-s_0BLDqW.mjs +0 -38
  343. package/components/chunks/MazTable-B9JiJ2B2.mjs +0 -1950
  344. package/modules/chunks/MazIcon-DdFYd3W8.cjs +0 -1
  345. package/modules/chunks/index-RvIMpzcQ.cjs +0 -124
  346. package/nuxt/runtime/composables/{use-aos.mjs → use-aos.js} +0 -0
  347. package/nuxt/runtime/composables/{use-theme-handler.mjs → use-theme-handler.js} +1 -1
  348. package/nuxt/runtime/composables/{use-toast.mjs → use-toast.js} +0 -0
  349. package/nuxt/runtime/composables/{use-wait.mjs → use-wait.js} +0 -0
  350. package/nuxt/runtime/plugins/{aos.mjs → aos.js} +1 -1
  351. package/nuxt/runtime/plugins/{maz-icon-path.mjs → maz-icon-path.js} +0 -0
  352. package/nuxt/runtime/plugins/{toaster.mjs → toaster.js} +1 -1
  353. package/nuxt/runtime/plugins/{v-click-outside.mjs → v-click-outside.js} +1 -1
  354. package/nuxt/runtime/plugins/{v-fullscreen-img.mjs → v-fullscreen-img.js} +1 -1
  355. package/nuxt/runtime/plugins/{v-lazy-img.mjs → v-lazy-img.js} +1 -1
  356. package/nuxt/runtime/plugins/{v-tooltip.mjs → v-tooltip.js} +1 -1
  357. package/nuxt/runtime/plugins/{v-zoom-img.mjs → v-zoom-img.js} +1 -1
  358. package/nuxt/runtime/plugins/{wait.mjs → wait.js} +1 -1
@@ -1,835 +0,0 @@
1
- import '../assets/MazSelect.css';
2
- import { getCurrentInstance as Me, computed as p, defineComponent as he, defineAsyncComponent as C, ref as I, onMounted as Le, useSlots as Te, openBlock as v, createElementBlock as w, normalizeClass as q, normalizeStyle as Y, createElementVNode as T, createCommentVNode as y, renderSlot as U, createBlock as A, unref as V, resolveDynamicComponent as me, withDirectives as be, mergeProps as ge, toHandlers as Ee, vModelDynamic as De, createTextVNode as Ne, toDisplayString as ue, withModifiers as F, withCtx as x, createVNode as H, useCssVars as Oe, onBeforeMount as Pe, nextTick as se, Transition as Fe, Fragment as ve, renderList as He } from "vue";
3
- function qe(r, u) {
4
- let s;
5
- return function(...d) {
6
- clearTimeout(s), s = setTimeout(() => {
7
- r.apply(this, d);
8
- }, u);
9
- };
10
- }
11
- function ze({
12
- componentName: r,
13
- providedId: u
14
- }) {
15
- const s = Me();
16
- return p(() => u ?? `${r}-${s == null ? void 0 : s.uid}`);
17
- }
18
- const Ue = {
19
- key: 0,
20
- class: "m-input-wrapper-left"
21
- }, je = { class: "m-input-wrapper-input" }, Re = ["id", "type", "name", "inputmode", "placeholder", "aria-label", "disabled", "readonly", "required"], We = { key: 0 }, Qe = {
22
- key: 1,
23
- class: "m-input-wrapper-right"
24
- }, Ge = /* @__PURE__ */ he({
25
- inheritAttrs: !1,
26
- __name: "MazInput",
27
- props: {
28
- style: { default: void 0 },
29
- class: { default: void 0 },
30
- modelValue: { default: void 0 },
31
- placeholder: { default: void 0 },
32
- label: { default: void 0 },
33
- name: { default: void 0 },
34
- color: { default: "primary" },
35
- type: { default: "text" },
36
- required: { type: Boolean, default: !1 },
37
- disabled: { type: Boolean, default: !1 },
38
- readonly: { type: Boolean, default: !1 },
39
- id: { default: void 0 },
40
- error: { type: Boolean, default: !1 },
41
- success: { type: Boolean, default: !1 },
42
- warning: { type: Boolean, default: !1 },
43
- hint: { default: void 0 },
44
- inputClasses: { default: void 0 },
45
- noBorder: { type: Boolean, default: !1 },
46
- noRadius: { type: Boolean, default: !1 },
47
- inputmode: { default: "text" },
48
- size: { default: "md" },
49
- debounce: { type: [Boolean, Number], default: !1 },
50
- debounceDelay: { default: 500 },
51
- validButton: { type: Boolean, default: !1 },
52
- validButtonLoading: { type: Boolean, default: !1 },
53
- autoFocus: { type: Boolean, default: !1 },
54
- borderActive: { type: Boolean, default: !1 },
55
- leftIcon: { default: void 0 },
56
- rightIcon: { default: void 0 },
57
- roundedSize: { default: void 0 },
58
- block: { type: Boolean }
59
- },
60
- emits: ["update:model-value", "focus", "blur", "click", "change"],
61
- setup(r, { emit: u }) {
62
- const s = C(() => import("./MazBtn-BqgdERYQ.mjs")), d = C(() => import("./MazIcon-Cxrv3_OK.mjs")), i = C(() => import("./eye-slash-tjfxO0LK.mjs")), c = C(() => import("./eye-DqO_Jx56.mjs")), b = C(() => import("./check-7UA4j2f2.mjs")), t = r, z = u, k = I(!1), m = I(!1), E = I(), ee = ze({
63
- componentName: "MazInput",
64
- providedId: t.id
65
- });
66
- Le(() => {
67
- var o;
68
- t.autoFocus && ((o = E.value) == null || o.focus());
69
- });
70
- const W = p(() => t.type === "password"), te = p(() => k.value ? "text" : t.type), S = p(() => {
71
- if (!t.noBorder) {
72
- if (t.error)
73
- return "maz-border-danger";
74
- if (t.success)
75
- return "maz-border-success";
76
- if (t.warning)
77
- return "maz-border-warning";
78
- if (m.value || t.borderActive) {
79
- if (t.color === "black")
80
- return "maz-border-black";
81
- if (t.color === "danger")
82
- return "maz-border-danger";
83
- if (t.color === "info")
84
- return "maz-border-info";
85
- if (t.color === "primary")
86
- return "maz-border-primary";
87
- if (t.color === "secondary")
88
- return "maz-border-secondary";
89
- if (t.color === "success")
90
- return "maz-border-success";
91
- if (t.color === "warning")
92
- return "maz-border-warning";
93
- if (t.color === "white")
94
- return "maz-border-white";
95
- }
96
- return "--default-border";
97
- }
98
- }), j = Te(), Q = p(() => {
99
- const { required: o, placeholder: h } = t;
100
- if (h)
101
- return o ? `${h} *` : h;
102
- }), G = p(() => L.value !== void 0 && L.value !== ""), M = qe(
103
- (o) => {
104
- z("update:model-value", o);
105
- },
106
- typeof t.debounce == "number" ? t.debounce : t.debounceDelay ?? 500
107
- ), D = (o) => {
108
- if (t.debounce)
109
- return M(o);
110
- z("update:model-value", o);
111
- }, L = p({
112
- get: () => t.modelValue,
113
- set: (o) => D(o)
114
- }), Z = p(() => (!!t.label || !!t.hint) && (m.value || !!G.value || !!t.placeholder || ["date", "month", "week"].includes(t.type))), J = p(() => !!t.label || !!t.hint);
115
- function X() {
116
- return !!j["right-icon"] || W.value || !!j["valid-button"] || t.validButton || !!t.rightIcon;
117
- }
118
- function $() {
119
- return !!j["left-icon"] || !!t.leftIcon;
120
- }
121
- function R(o) {
122
- z("focus", o), m.value = !0;
123
- }
124
- function oe(o) {
125
- z("blur", o), m.value = !1;
126
- }
127
- function le(o) {
128
- return z("change", o);
129
- }
130
- return (o, h) => (v(), w(
131
- "div",
132
- {
133
- class: q(["m-input", [
134
- {
135
- "--is-focused": m.value || o.borderActive,
136
- "--should-up": Z.value,
137
- "--has-label": J.value,
138
- "--is-disabled": o.disabled,
139
- "--is-readonly": o.readonly,
140
- "--has-z-2": o.error || o.warning || o.success,
141
- "--has-state": o.error || o.warning || o.success,
142
- "--block": o.block
143
- },
144
- t.class,
145
- `--${o.color}`,
146
- `--${o.size}`
147
- ]]),
148
- style: Y(o.style)
149
- },
150
- [
151
- T(
152
- "div",
153
- {
154
- class: q(["m-input-wrapper", [
155
- o.inputClasses,
156
- S.value,
157
- o.roundedSize ? `--rounded-${o.roundedSize}` : { "maz-rounded": !o.noRadius }
158
- ]])
159
- },
160
- [
161
- $() ? (v(), w("div", Ue, [
162
- y(`
163
- @slot left-icon - The icon to display on the left of the input
164
- `),
165
- o.$slots["left-icon"] || o.leftIcon ? U(o.$slots, "left-icon", { key: 0 }, () => [
166
- typeof o.leftIcon == "string" ? (v(), A(V(d), {
167
- key: 0,
168
- name: o.leftIcon,
169
- class: "maz-text-xl maz-text-muted"
170
- }, null, 8, ["name"])) : o.leftIcon ? (v(), A(me(o.leftIcon), {
171
- key: 1,
172
- class: "maz-text-xl maz-text-muted"
173
- })) : y("v-if", !0)
174
- ], !0) : y("v-if", !0)
175
- ])) : y("v-if", !0),
176
- T("div", je, [
177
- be(T("input", ge({
178
- id: V(ee),
179
- ref_key: "input",
180
- ref: E,
181
- "onUpdate:modelValue": h[0] || (h[0] = (B) => L.value = B),
182
- type: te.value,
183
- name: o.name
184
- }, o.$attrs, {
185
- inputmode: o.inputmode,
186
- placeholder: Q.value,
187
- "aria-label": o.label || o.placeholder,
188
- disabled: o.disabled,
189
- readonly: o.readonly,
190
- required: o.required,
191
- class: "m-input-input"
192
- }, Ee({
193
- blur: oe,
194
- focus: R,
195
- change: le
196
- }, !0), {
197
- onClick: h[1] || (h[1] = (B) => o.$emit("click", B))
198
- }), null, 16, Re), [
199
- [De, L.value]
200
- ]),
201
- o.label || o.hint ? (v(), w(
202
- "span",
203
- {
204
- key: 0,
205
- ref: "label",
206
- class: q(["m-input-label", [
207
- {
208
- "maz-text-danger-600": o.error,
209
- "maz-text-success-600": o.success,
210
- "maz-text-warning-600": o.warning
211
- }
212
- ]])
213
- },
214
- [
215
- Ne(
216
- ue(o.hint || o.label) + " ",
217
- 1
218
- /* TEXT */
219
- ),
220
- o.required ? (v(), w("sup", We, "*")) : y("v-if", !0)
221
- ],
222
- 2
223
- /* CLASS */
224
- )) : y("v-if", !0)
225
- ]),
226
- X() ? (v(), w("div", Qe, [
227
- y(`
228
- @slot right-icon - The icon to display on the right of the input
229
- `),
230
- o.$slots["right-icon"] || o.rightIcon ? U(o.$slots, "right-icon", { key: 0 }, () => [
231
- typeof o.rightIcon == "string" ? (v(), A(V(d), {
232
- key: 0,
233
- name: o.rightIcon,
234
- class: "maz-text-xl maz-text-muted"
235
- }, null, 8, ["name"])) : o.rightIcon ? (v(), A(me(o.rightIcon), {
236
- key: 1,
237
- class: "maz-text-xl maz-text-muted"
238
- })) : y("v-if", !0)
239
- ], !0) : y("v-if", !0),
240
- W.value ? (v(), A(V(s), {
241
- key: 1,
242
- color: "transparent",
243
- tabindex: "-1",
244
- size: "mini",
245
- onClick: h[2] || (h[2] = F((B) => k.value = !k.value, ["stop"]))
246
- }, {
247
- default: x(() => [
248
- k.value ? (v(), A(V(i), {
249
- key: 0,
250
- class: "maz-text-xl maz-text-muted"
251
- })) : (v(), A(V(c), {
252
- key: 1,
253
- class: "maz-text-xl maz-text-muted"
254
- }))
255
- ]),
256
- _: 1
257
- /* STABLE */
258
- })) : y("v-if", !0),
259
- y(`
260
- @slot valid-button - Replace the valid button by your own
261
- `),
262
- o.$slots["valid-button"] || o.validButton ? U(o.$slots, "valid-button", { key: 2 }, () => [
263
- H(V(s), {
264
- color: "transparent",
265
- disabled: o.disabled,
266
- tabindex: "-1",
267
- loading: o.validButtonLoading,
268
- class: "m-input-valid-button",
269
- size: "mini",
270
- type: "submit"
271
- }, {
272
- default: x(() => [
273
- H(V(b), { class: "maz-text-2xl maz-text-normal" })
274
- ]),
275
- _: 1
276
- /* STABLE */
277
- }, 8, ["disabled", "loading"])
278
- ], !0) : y("v-if", !0)
279
- ])) : y("v-if", !0)
280
- ],
281
- 2
282
- /* CLASS */
283
- )
284
- ],
285
- 6
286
- /* CLASS, STYLE */
287
- ));
288
- }
289
- }), Ve = (r, u) => {
290
- const s = r.__vccOpts || r;
291
- for (const [d, i] of u)
292
- s[d] = i;
293
- return s;
294
- }, ye = /* @__PURE__ */ Ve(Ge, [["__scopeId", "data-v-84073434"]]);
295
- let ie = null;
296
- function Ze(r, u) {
297
- ie && clearTimeout(ie), ie = setTimeout(r, u);
298
- }
299
- const Je = {
300
- removeAccents: !0,
301
- caseSensitive: !1,
302
- replaceSpaces: !0,
303
- removeSpecialCharacters: !1,
304
- trim: !0,
305
- normalizeSpaces: !0,
306
- removeNumbers: !1,
307
- customNormalizationForms: ["NFC", "NFKD"]
308
- };
309
- function _(r, u) {
310
- const s = { ...Je, ...u }, d = {
311
- À: "A",
312
- Á: "A",
313
- Â: "A",
314
- Ã: "A",
315
- Ä: "A",
316
- Å: "A",
317
- à: "a",
318
- á: "a",
319
- â: "a",
320
- ã: "a",
321
- ä: "a",
322
- å: "a",
323
- È: "E",
324
- É: "E",
325
- Ê: "E",
326
- Ë: "E",
327
- è: "e",
328
- é: "e",
329
- ê: "e",
330
- ë: "e",
331
- Î: "I",
332
- Ï: "I",
333
- í: "I",
334
- î: "i",
335
- ï: "i",
336
- Ô: "O",
337
- Õ: "O",
338
- Ö: "O",
339
- Ø: "O",
340
- ô: "o",
341
- õ: "o",
342
- ö: "o",
343
- ø: "o",
344
- Ù: "U",
345
- Ú: "U",
346
- Û: "U",
347
- Ü: "U",
348
- ù: "u",
349
- ú: "u",
350
- û: "u",
351
- ü: "u",
352
- Ç: "C",
353
- ç: "c",
354
- ÿ: "y",
355
- Ñ: "N",
356
- ñ: "n",
357
- ó: "o"
358
- };
359
- let i = r.toString();
360
- if (s.trim && (i = i.trim()), s.normalizeSpaces && (i = i.replaceAll(/\s+/g, " ")), s.replaceSpaces && (i = i.replaceAll(" ", "-")), s.removeNumbers && (i = i.replaceAll(/\d/g, "")), s.removeAccents && (i = i.replaceAll(/[ÀÁÂÃÄÅÇÈÉÊËÎÏÑÔÕÖØÙÚÛÜàáâãäåçèéêëíîïñóôõöøùúûüÿ]/g, (c) => d[c] || c), i = i.replaceAll(/[\u0300-\u036F]/g, "")), s.caseSensitive === !1 && (i = i.toLowerCase()), s.removeSpecialCharacters && (i = i.replaceAll(/[^\dA-Za-z-]/g, "")), s.trim && (i = i.trim()), s.customNormalizationForms)
361
- for (const c of s.customNormalizationForms)
362
- i = i.normalize(c);
363
- return i;
364
- }
365
- function Xe(r, u) {
366
- const s = r.length, d = u.length, i = [];
367
- for (let c = 0; c <= s; c++)
368
- i[c] = [c];
369
- for (let c = 0; c <= d; c++)
370
- i[0][c] = c;
371
- for (let c = 1; c <= s; c++)
372
- for (let b = 1; b <= d; b++) {
373
- const t = r[c - 1] === u[b - 1] ? 0 : 1;
374
- i[c][b] = Math.min(
375
- i[c - 1][b] + 1,
376
- i[c][b - 1] + 1,
377
- i[c - 1][b - 1] + t
378
- );
379
- }
380
- return i[s][d];
381
- }
382
- function ke(r, u) {
383
- const s = Xe(r, u), d = Math.max(r.length, u.length);
384
- return 1 - s / d;
385
- }
386
- function Ye(r, u, s = 0.75) {
387
- return ke(r, u) >= s;
388
- }
389
- function re(r, u, s = 0.75) {
390
- const d = p(
391
- () => _(typeof r == "string" ? r : r.value)
392
- ), i = p(
393
- () => _(typeof u == "string" ? u : u.value)
394
- ), c = p(() => typeof s == "number" ? s : s.value), b = p(() => ke(d.value, i.value));
395
- return {
396
- isMatching: p(
397
- () => Ye(d.value, i.value, c.value)
398
- ),
399
- score: b
400
- };
401
- }
402
- const Ie = (r, u, s) => {
403
- var b;
404
- r.stopPropagation();
405
- const d = typeof s.value == "function" ? s.value : s.value.handler, i = typeof s.value == "object" ? s.value.exclude : void 0;
406
- let c = !1;
407
- if (i && i.length > 0) {
408
- for (const t of i)
409
- if (!c && r.target instanceof HTMLElement) {
410
- const z = (b = document.querySelector(t)) == null ? void 0 : b.getAttribute("id");
411
- c = r.target.getAttribute("id") === z;
412
- }
413
- }
414
- !u.contains(r.target) && !c && (d == null || d());
415
- };
416
- function we() {
417
- return document.ontouchstart === null ? "touchstart" : "click";
418
- }
419
- function xe(r, u) {
420
- const s = we();
421
- document.removeEventListener(s, (d) => Ie(d, r, u));
422
- }
423
- function _e(r, u) {
424
- if (typeof u.value != "function" && typeof u.value == "object" && typeof u.value.handler != "function") {
425
- console.error("[maz-ui](vClosable) v-closable directive requires a handler function");
426
- return;
427
- }
428
- const s = we();
429
- document.addEventListener(s, (d) => Ie(d, r, u));
430
- }
431
- const et = {
432
- mounted: _e,
433
- unmounted: xe
434
- }, tt = ["aria-label"], ot = { class: "m-select-list__no-results" }, lt = {
435
- key: 2,
436
- class: "m-select-list__scroll-wrapper",
437
- tabindex: "-1"
438
- }, at = { class: "m-select-list-optgroup" }, nt = ["onClick"], st = /* @__PURE__ */ he({
439
- inheritAttrs: !1,
440
- __name: "MazSelect",
441
- props: {
442
- style: { default: void 0 },
443
- class: { default: void 0 },
444
- id: { default: void 0 },
445
- modelValue: { default: void 0 },
446
- options: { default: void 0 },
447
- optionValueKey: { default: "value" },
448
- optionLabelKey: { default: "label" },
449
- optionInputValueKey: { default: "label" },
450
- listPosition: { default: "bottom left" },
451
- itemHeight: { default: void 0 },
452
- maxListHeight: { default: 240 },
453
- maxListWidth: { default: void 0 },
454
- size: { default: "md" },
455
- color: { default: "primary" },
456
- search: { type: Boolean },
457
- searchPlaceholder: { default: "Search in options" },
458
- open: { type: Boolean },
459
- multiple: { type: Boolean, default: void 0 },
460
- required: { type: Boolean },
461
- disabled: { type: Boolean },
462
- block: { type: Boolean },
463
- excludeSelectors: { default: void 0 }
464
- },
465
- emits: ["close", "open", "blur", "focus", "change", "update:model-value", "selected-option"],
466
- setup(r, { expose: u, emit: s }) {
467
- Oe((e) => ({
468
- "416802e0": te.value,
469
- "21823f4f": ee.value,
470
- "6d76cd12": W.value
471
- }));
472
- const d = C(() => import("./MazCheckbox-DsFbvpp4.mjs")), i = C(() => import("./magnifying-glass-DZGg7953.mjs")), c = C(() => import("./chevron-down-CzMH-gFW.mjs")), b = C(() => import("./no-symbol-QAqP9IlR.mjs"));
473
- u({
474
- /** Method to open the option list */
475
- openList: O,
476
- /** Method to close the option list */
477
- closeList: N
478
- });
479
- const t = r, z = s, k = I(!1), m = I(), E = p(
480
- () => ["black", "transparent", "white"].includes(t.color)
481
- ), ee = p(
482
- () => E.value ? "var(--maz-color-black)" : `var(--maz-color-${t.color}-800)`
483
- ), W = p(
484
- () => E.value ? "var(--maz-color-muted)" : `var(--maz-color-${t.color}-100)`
485
- ), te = p(
486
- () => E.value ? "var(--maz-color-muted)" : `var(--maz-color-${t.color}-200)`
487
- ), S = p(() => k.value || t.open), j = ze({
488
- componentName: "MazSelect",
489
- providedId: t.id
490
- });
491
- function Q(e) {
492
- return {
493
- [t.optionValueKey]: e,
494
- [t.optionLabelKey]: e,
495
- [t.optionInputValueKey]: e
496
- };
497
- }
498
- function G(e) {
499
- return {
500
- ...e,
501
- [t.optionValueKey]: e[t.optionValueKey],
502
- [t.optionLabelKey]: e[t.optionLabelKey],
503
- [t.optionInputValueKey]: e[t.optionInputValueKey]
504
- };
505
- }
506
- const M = p(() => {
507
- var l;
508
- const e = [];
509
- if (!((l = t.options) != null && l.length))
510
- return [];
511
- for (const n of t.options)
512
- typeof n == "string" || typeof n == "number" || typeof n == "boolean" ? e.push(Q(n)) : typeof n == "object" && "options" in n && Array.isArray(n.options) ? e.push(
513
- { label: n.label, isOptGroup: !0 },
514
- ...n.options.map(
515
- (a) => typeof a == "string" || typeof a == "number" || typeof a == "boolean" ? Q(a) : G(a)
516
- )
517
- ) : e.push(G(n));
518
- return e;
519
- }), D = p(
520
- () => {
521
- var e;
522
- return ((e = M.value) == null ? void 0 : e.filter((l) => t.multiple ? Array.isArray(t.modelValue) ? t.modelValue.includes(l[t.optionValueKey]) && !$(l[t.optionValueKey]) : !1 : t.modelValue === l[t.optionValueKey] && !$(l[t.optionValueKey]))) ?? [];
523
- }
524
- );
525
- Pe(() => {
526
- var e;
527
- (e = t.options) != null && e.length || console.warn("[maz-ui](MazSelect) you must provide options"), ne();
528
- });
529
- const L = I(), Z = I(), J = I(), X = I(), $ = (e) => e == null;
530
- function R(e) {
531
- var n;
532
- return (((n = D.value) == null ? void 0 : n.some(
533
- (a) => a[t.optionValueKey] === e[t.optionValueKey]
534
- )) ?? !1) && !$(e[t.optionValueKey]);
535
- }
536
- const oe = p(() => {
537
- var l;
538
- if (t.multiple && t.modelValue && Array.isArray(t.modelValue))
539
- return t.modelValue.map(
540
- (n) => {
541
- var a, f;
542
- return (f = (a = M.value) == null ? void 0 : a.find((g) => g[t.optionValueKey] === n)) == null ? void 0 : f[t.optionInputValueKey];
543
- }
544
- ).join(", ");
545
- const e = (l = M.value) == null ? void 0 : l.find(
546
- (n) => n[t.optionValueKey] === t.modelValue
547
- );
548
- return $(t.modelValue) || e == null ? void 0 : e[t.optionInputValueKey];
549
- }), le = p(
550
- () => t.listPosition.includes("bottom") ? "maz-slide" : "maz-slideinvert"
551
- ), o = I(""), h = I(""), B = (e, l) => l && e && _(e).includes(_(l));
552
- function ce(e) {
553
- var l;
554
- return e ? (l = M.value) == null ? void 0 : l.filter((n) => {
555
- const a = n[t.optionLabelKey], f = n[t.optionValueKey], g = n[t.optionInputValueKey];
556
- return B(a, e) || B(g, e) || B(f, e) || typeof a == "string" && re(a, e, 0.5).isMatching.value || typeof g == "string" && re(g, e, 0.5).isMatching.value || typeof f == "string" && re(f, e, 0.5).isMatching.value;
557
- }) : M.value;
558
- }
559
- const K = p(() => ce(o.value));
560
- async function N(e) {
561
- var n, a;
562
- if (!S.value)
563
- return;
564
- if (e && ("relatedTarget" in e && ((n = L.value) != null && n.contains(e.relatedTarget)) || e.type === "keydown"))
565
- return e.preventDefault();
566
- const l = e && "relatedTarget" in e && e.relatedTarget instanceof HTMLElement && e.relatedTarget.getAttribute("id");
567
- if ((a = t.excludeSelectors) != null && a.includes(`#${l}`))
568
- return e == null ? void 0 : e.preventDefault();
569
- await se(), k.value = !1, m.value = 0, z("close", e);
570
- }
571
- async function O(e) {
572
- t.disabled || S.value || (e == null || e.preventDefault(), k.value = !0, await ae(), z("focus", e), z("open", k.value));
573
- }
574
- function de() {
575
- var e, l;
576
- (l = ((e = Z.value) == null ? void 0 : e.$el).querySelector("input")) == null || l.focus();
577
- }
578
- function Se(e) {
579
- k.value ? N(e) : de();
580
- }
581
- function Ke(e) {
582
- var l, n;
583
- o.value = e, (n = ((l = J.value) == null ? void 0 : l.$el).querySelector("input")) == null || n.focus();
584
- }
585
- function Ae(e) {
586
- var n;
587
- e === "Backspace" && h.value.length > 0 ? h.value = h.value.slice(0, -1) : h.value += e;
588
- const l = ce(h.value);
589
- l != null && l.length && (m.value = (n = K.value) == null ? void 0 : n.findIndex(
590
- (a) => a[t.optionValueKey] === l[0][t.optionValueKey]
591
- ), typeof m.value == "number" && m.value >= 0 && ae(m.value)), Ze(() => {
592
- h.value = "";
593
- }, 1e3);
594
- }
595
- const Ce = (e) => {
596
- const l = e.key;
597
- /^[\dA-Za-z\u0400-\u04FF]$/.test(l) ? (e.preventDefault(), O(e), t.search ? Ke(l) : Ae(l)) : pe(e);
598
- }, pe = (e) => {
599
- const l = e.code, n = ["ArrowUp", "ArrowDown"].includes(l), a = ["Enter", "Space"].includes(l), f = l === "Escape" && S.value;
600
- n ? $e(e, m.value) : a ? Be(e, m.value) : f && N(e);
601
- }, $e = (e, l) => {
602
- var f;
603
- e.preventDefault();
604
- const n = e.code;
605
- S.value || O(e);
606
- const a = (f = K.value) == null ? void 0 : f.length;
607
- a && (typeof l == "number" ? l === a - 1 && n === "ArrowDown" ? m.value = 0 : l === 0 && n === "ArrowUp" ? m.value = a - 1 : m.value = n === "ArrowDown" ? l + 1 : l - 1 : m.value = n === "ArrowDown" ? 0 : a - 1, ae(m.value));
608
- }, Be = (e, l) => {
609
- var a, f, g;
610
- if (e.preventDefault(), !S.value)
611
- return O(e);
612
- const n = l ? ((a = K.value) == null ? void 0 : a[l]) ?? ((f = K.value) == null ? void 0 : f[0]) : (g = K.value) == null ? void 0 : g[0];
613
- $(n) || fe(n);
614
- };
615
- async function ae(e) {
616
- var n, a;
617
- await se(), typeof e != "number" && ne();
618
- const l = e ?? m.value;
619
- typeof l == "number" && l >= 0 && ((a = (n = X.value) == null ? void 0 : n.querySelectorAll(".m-select-list-item")[l]) == null || a.scrollIntoView({
620
- behavior: "auto",
621
- block: "nearest",
622
- inline: "start"
623
- }));
624
- }
625
- function ne(e) {
626
- var n;
627
- const l = (n = K.value) == null ? void 0 : n.findIndex((a) => {
628
- var f, g;
629
- return t.multiple && Array.isArray(t.modelValue) ? e ? e[t.optionValueKey] === a[t.optionValueKey] : [...t.modelValue].reverse()[0] === a[t.optionValueKey] : ((g = (f = D.value) == null ? void 0 : f[0]) == null ? void 0 : g[t.optionValueKey]) === a[t.optionValueKey];
630
- });
631
- m.value = l && l >= 0 ? l : 0;
632
- }
633
- function fe(e, l = !0) {
634
- var g;
635
- l && !t.multiple && se(() => N()), o.value = "";
636
- const n = (g = D.value) == null ? void 0 : g.some(
637
- (P) => P[t.optionValueKey] === e[t.optionValueKey]
638
- );
639
- let a = D.value;
640
- n && t.multiple ? a = a == null ? void 0 : a.filter(
641
- (P) => P[t.optionValueKey] !== e[t.optionValueKey]
642
- ) : t.multiple ? a.push(e) : a = [e];
643
- const f = a.map((P) => P[t.optionValueKey]);
644
- z("update:model-value", t.multiple ? f : f[0]), z("selected-option", e), ne(e), de();
645
- }
646
- return (e, l) => {
647
- var n;
648
- return be((v(), w(
649
- "div",
650
- {
651
- ref_key: "mazSelectElement",
652
- ref: L,
653
- class: q(["m-select", [
654
- { "--is-open": S.value, "--disabled": e.disabled, "--block": e.block },
655
- t.class,
656
- `--${e.size}`
657
- ]]),
658
- style: Y(e.style)
659
- },
660
- [
661
- H(ye, ge({
662
- id: V(j),
663
- ref_key: "mazInputComponent",
664
- ref: Z,
665
- class: "m-select-input"
666
- }, e.$attrs, {
667
- required: e.required,
668
- "border-active": k.value,
669
- color: e.color,
670
- "model-value": oe.value,
671
- autocomplete: "off",
672
- size: e.size,
673
- block: "",
674
- disabled: e.disabled,
675
- onFocus: F(O, ["prevent", "stop"]),
676
- onBlur: F(N, ["prevent", "stop"]),
677
- onClick: F(O, ["prevent", "stop"]),
678
- onChange: l[0] || (l[0] = (a) => z("change", a)),
679
- onKeydown: Ce
680
- }), {
681
- "right-icon": x(() => [
682
- T("button", {
683
- tabindex: "-1",
684
- type: "button",
685
- class: "m-select-input__toggle-button maz-custom",
686
- "aria-label": `${S.value ? "collapse" : "expand"} list of options`,
687
- onClick: F(Se, ["stop"])
688
- }, [
689
- H(V(c), { class: "m-select-chevron maz-text-xl" })
690
- ], 8, tt)
691
- ]),
692
- _: 1
693
- /* STABLE */
694
- }, 16, ["id", "required", "border-active", "color", "model-value", "size", "disabled"]),
695
- H(Fe, { name: le.value }, {
696
- default: x(() => [
697
- S.value ? (v(), w(
698
- "div",
699
- {
700
- key: 0,
701
- ref_key: "optionsListElement",
702
- ref: X,
703
- class: q(["m-select-list", {
704
- "--top": e.listPosition.includes("top"),
705
- "--left": e.listPosition.includes("left"),
706
- "--right": e.listPosition.includes("right"),
707
- "--bottom": e.listPosition.includes("bottom")
708
- }]),
709
- style: Y({
710
- maxHeight: `${e.maxListHeight}px`,
711
- maxWidth: `${e.maxListWidth}px`
712
- })
713
- },
714
- [
715
- e.search ? (v(), A(ye, {
716
- key: 0,
717
- ref_key: "searchInputComponent",
718
- ref: J,
719
- modelValue: o.value,
720
- "onUpdate:modelValue": [
721
- l[1] || (l[1] = (a) => o.value = a),
722
- l[2] || (l[2] = (a) => m.value = 0)
723
- ],
724
- size: "sm",
725
- color: e.color,
726
- placeholder: e.searchPlaceholder,
727
- name: "search",
728
- autocomplete: "off",
729
- tabindex: "-1",
730
- class: "m-select-list__search-input maz-flex-none",
731
- "left-icon": V(i),
732
- onKeydown: pe
733
- }, null, 8, ["modelValue", "color", "placeholder", "left-icon"])) : y("v-if", !0),
734
- y(`
735
- @slot No results slot - Displayed when no results corresponding with search query
736
- `),
737
- !K.value || K.value.length <= 0 ? U(e.$slots, "no-results", { key: 1 }, () => [
738
- T("span", ot, [
739
- H(V(b), { class: "maz-h-6 maz-w-6 maz-text-normal" })
740
- ])
741
- ], !0) : (v(), w("div", lt, [
742
- (v(!0), w(
743
- ve,
744
- null,
745
- He(K.value, (a, f) => (v(), w(
746
- ve,
747
- { key: f },
748
- [
749
- y(`
750
- @slot Custom optgroup label
751
- @binding {String} label - the label of the optgroup
752
- `),
753
- a.label && a.isOptGroup ? U(e.$slots, "optgroup", {
754
- key: 0,
755
- label: a.label
756
- }, () => [
757
- T(
758
- "span",
759
- at,
760
- ue(a.label),
761
- 1
762
- /* TEXT */
763
- )
764
- ], !0) : (v(), w("button", {
765
- key: 1,
766
- tabindex: "-1",
767
- type: "button",
768
- class: q(["m-select-list-item maz-custom maz-flex-none", [
769
- {
770
- "--is-keyboard-selected": m.value === f,
771
- "--is-selected": R(a),
772
- "--is-none-value": $(a[e.optionValueKey])
773
- }
774
- ]]),
775
- style: Y(e.itemHeight ? { height: `${e.itemHeight}px` } : void 0),
776
- onClick: F((g) => fe(a), ["prevent", "stop"])
777
- }, [
778
- e.multiple ? (v(), A(V(d), {
779
- key: 0,
780
- tabindex: "-1",
781
- "model-value": R(a),
782
- size: "sm",
783
- color: e.color
784
- }, null, 8, ["model-value", "color"])) : y("v-if", !0),
785
- y(`
786
- @slot Custom option
787
- @binding {Object} option - the option object
788
- @binding {Boolean} is-selected - if the option is selected
789
- `),
790
- U(e.$slots, "default", {
791
- option: a,
792
- isSelected: R(a)
793
- }, () => [
794
- T(
795
- "span",
796
- null,
797
- ue(a[e.optionLabelKey]),
798
- 1
799
- /* TEXT */
800
- )
801
- ], !0)
802
- ], 14, nt))
803
- ],
804
- 64
805
- /* STABLE_FRAGMENT */
806
- ))),
807
- 128
808
- /* KEYED_FRAGMENT */
809
- ))
810
- ]))
811
- ],
812
- 6
813
- /* CLASS, STYLE */
814
- )) : y("v-if", !0)
815
- ]),
816
- _: 3
817
- /* FORWARDED */
818
- }, 8, ["name"])
819
- ],
820
- 6
821
- /* CLASS, STYLE */
822
- )), [
823
- [V(et), {
824
- exclude: (n = e.excludeSelectors) != null && n.length ? e.excludeSelectors : [],
825
- handler: N
826
- }]
827
- ]);
828
- };
829
- }
830
- }), rt = /* @__PURE__ */ Ve(st, [["__scopeId", "data-v-05b98a1b"]]);
831
- export {
832
- rt as M,
833
- Ve as _,
834
- ze as u
835
- };