@antify/ui-module 1.7.3 → 1.8.2

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 (364) hide show
  1. package/README.md +43 -52
  2. package/dist/module.d.mts +1 -251
  3. package/dist/module.d.ts +1 -251
  4. package/dist/module.json +1 -1
  5. package/dist/module.mjs +97 -418
  6. package/dist/runtime/composables/useUiClient.d.ts +2 -2
  7. package/dist/runtime/composables/useUiClient.mjs +1 -2
  8. package/dist/runtime/plugins/ui-module.mjs +3 -2
  9. package/dist/runtime/tailwind.config.d.ts +2 -3
  10. package/dist/runtime/tailwind.config.mjs +20 -204
  11. package/dist/types.d.mts +1 -1
  12. package/dist/types.d.ts +1 -1
  13. package/package.json +10 -41
  14. package/dist/runtime/components/AntAccordion.vue +0 -64
  15. package/dist/runtime/components/AntAccordionItem.vue +0 -81
  16. package/dist/runtime/components/AntAlert.vue +0 -146
  17. package/dist/runtime/components/AntCard.vue +0 -34
  18. package/dist/runtime/components/AntContent.vue +0 -16
  19. package/dist/runtime/components/AntDropdown.vue +0 -79
  20. package/dist/runtime/components/AntIcon.vue +0 -56
  21. package/dist/runtime/components/AntKeycap.vue +0 -45
  22. package/dist/runtime/components/AntListGroup.vue +0 -24
  23. package/dist/runtime/components/AntListGroupItem.vue +0 -83
  24. package/dist/runtime/components/AntModal.vue +0 -88
  25. package/dist/runtime/components/AntPagination.vue +0 -206
  26. package/dist/runtime/components/AntPopover.vue +0 -114
  27. package/dist/runtime/components/AntSkeleton.vue +0 -38
  28. package/dist/runtime/components/AntSpinner.vue +0 -101
  29. package/dist/runtime/components/AntTag.vue +0 -114
  30. package/dist/runtime/components/AntToast.vue +0 -119
  31. package/dist/runtime/components/AntToaster.vue +0 -51
  32. package/dist/runtime/components/AntTooltip.vue +0 -189
  33. package/dist/runtime/components/Main.mdx +0 -11
  34. package/dist/runtime/components/Main.stories.d.ts +0 -7
  35. package/dist/runtime/components/Main.stories.mjs +0 -8
  36. package/dist/runtime/components/__stories/AntAccordion.stories.d.ts +0 -9
  37. package/dist/runtime/components/__stories/AntAccordion.stories.mjs +0 -101
  38. package/dist/runtime/components/__stories/AntAlert.stories.d.ts +0 -11
  39. package/dist/runtime/components/__stories/AntAlert.stories.mjs +0 -81
  40. package/dist/runtime/components/__stories/AntCard.stories.d.ts +0 -7
  41. package/dist/runtime/components/__stories/AntCard.stories.mjs +0 -87
  42. package/dist/runtime/components/__stories/AntContent.stories.d.ts +0 -6
  43. package/dist/runtime/components/__stories/AntContent.stories.mjs +0 -26
  44. package/dist/runtime/components/__stories/AntDropdown.stories.d.ts +0 -6
  45. package/dist/runtime/components/__stories/AntDropdown.stories.mjs +0 -52
  46. package/dist/runtime/components/__stories/AntIcon.stories.d.ts +0 -8
  47. package/dist/runtime/components/__stories/AntIcon.stories.mjs +0 -93
  48. package/dist/runtime/components/__stories/AntKeycap.stories.d.ts +0 -9
  49. package/dist/runtime/components/__stories/AntKeycap.stories.mjs +0 -69
  50. package/dist/runtime/components/__stories/AntListGroup.stories.d.ts +0 -7
  51. package/dist/runtime/components/__stories/AntListGroup.stories.mjs +0 -36
  52. package/dist/runtime/components/__stories/AntListGroupItem.stories.d.ts +0 -10
  53. package/dist/runtime/components/__stories/AntListGroupItem.stories.mjs +0 -62
  54. package/dist/runtime/components/__stories/AntModal.stories.d.ts +0 -7
  55. package/dist/runtime/components/__stories/AntModal.stories.mjs +0 -78
  56. package/dist/runtime/components/__stories/AntPagination.stories.d.ts +0 -8
  57. package/dist/runtime/components/__stories/AntPagination.stories.mjs +0 -39
  58. package/dist/runtime/components/__stories/AntPopover.stories.d.ts +0 -6
  59. package/dist/runtime/components/__stories/AntPopover.stories.mjs +0 -47
  60. package/dist/runtime/components/__stories/AntSkeleton.stories.d.ts +0 -8
  61. package/dist/runtime/components/__stories/AntSkeleton.stories.mjs +0 -43
  62. package/dist/runtime/components/__stories/AntSpinner.stories.d.ts +0 -6
  63. package/dist/runtime/components/__stories/AntSpinner.stories.mjs +0 -34
  64. package/dist/runtime/components/__stories/AntTag.stories.d.ts +0 -7
  65. package/dist/runtime/components/__stories/AntTag.stories.mjs +0 -43
  66. package/dist/runtime/components/__stories/AntToast.stories.d.ts +0 -8
  67. package/dist/runtime/components/__stories/AntToast.stories.mjs +0 -66
  68. package/dist/runtime/components/__stories/AntToaster.stories.d.ts +0 -34
  69. package/dist/runtime/components/__stories/AntToaster.stories.mjs +0 -42
  70. package/dist/runtime/components/__stories/AntTooltip.stories.d.ts +0 -16
  71. package/dist/runtime/components/__stories/AntTooltip.stories.mjs +0 -241
  72. package/dist/runtime/components/__types/AntAccordion.types.d.ts +0 -4
  73. package/dist/runtime/components/__types/AntAccordion.types.mjs +0 -5
  74. package/dist/runtime/components/__types/AntIcon.types.d.ts +0 -8
  75. package/dist/runtime/components/__types/AntIcon.types.mjs +0 -9
  76. package/dist/runtime/components/__types/AntKeycap.types.d.ts +0 -4
  77. package/dist/runtime/components/__types/AntKeycap.types.mjs +0 -5
  78. package/dist/runtime/components/__types/AntListGroupItem.types.d.ts +0 -9
  79. package/dist/runtime/components/__types/AntListGroupItem.types.mjs +0 -10
  80. package/dist/runtime/components/__types/AntSpinner.types.d.ts +0 -10
  81. package/dist/runtime/components/__types/AntSpinner.types.mjs +0 -11
  82. package/dist/runtime/components/__types/AntTag.types.d.ts +0 -17
  83. package/dist/runtime/components/__types/AntTag.types.mjs +0 -19
  84. package/dist/runtime/components/__types/AntToaster.types.d.ts +0 -8
  85. package/dist/runtime/components/__types/AntToaster.types.mjs +0 -0
  86. package/dist/runtime/components/__types/index.d.ts +0 -7
  87. package/dist/runtime/components/__types/index.mjs +0 -7
  88. package/dist/runtime/components/buttons/AntActionButton.vue +0 -74
  89. package/dist/runtime/components/buttons/AntButton.vue +0 -257
  90. package/dist/runtime/components/buttons/AntCreateButton.vue +0 -54
  91. package/dist/runtime/components/buttons/AntDeleteButton.vue +0 -54
  92. package/dist/runtime/components/buttons/AntDuplicateButton.vue +0 -54
  93. package/dist/runtime/components/buttons/AntEditButton.vue +0 -54
  94. package/dist/runtime/components/buttons/AntSaveAndNewButton.vue +0 -56
  95. package/dist/runtime/components/buttons/AntSaveButton.vue +0 -55
  96. package/dist/runtime/components/buttons/__stories/AntActionButton.stories.d.ts +0 -11
  97. package/dist/runtime/components/buttons/__stories/AntActionButton.stories.mjs +0 -86
  98. package/dist/runtime/components/buttons/__stories/AntButton.stories.d.ts +0 -16
  99. package/dist/runtime/components/buttons/__stories/AntButton.stories.mjs +0 -313
  100. package/dist/runtime/components/buttons/__stories/AntCreateButton.stories.d.ts +0 -12
  101. package/dist/runtime/components/buttons/__stories/AntCreateButton.stories.mjs +0 -76
  102. package/dist/runtime/components/buttons/__stories/AntDeleteButton.stories.d.ts +0 -12
  103. package/dist/runtime/components/buttons/__stories/AntDeleteButton.stories.mjs +0 -76
  104. package/dist/runtime/components/buttons/__stories/AntDuplicateButton.stories.d.ts +0 -12
  105. package/dist/runtime/components/buttons/__stories/AntDuplicateButton.stories.mjs +0 -76
  106. package/dist/runtime/components/buttons/__stories/AntEditButton.stories.d.ts +0 -12
  107. package/dist/runtime/components/buttons/__stories/AntEditButton.stories.mjs +0 -76
  108. package/dist/runtime/components/buttons/__stories/AntSaveAndNewButton.stories.d.ts +0 -12
  109. package/dist/runtime/components/buttons/__stories/AntSaveAndNewButton.stories.mjs +0 -76
  110. package/dist/runtime/components/buttons/__stories/AntSaveButton.stories.d.ts +0 -12
  111. package/dist/runtime/components/buttons/__stories/AntSaveButton.stories.mjs +0 -76
  112. package/dist/runtime/components/buttons/__types/AntButton.types.d.ts +0 -4
  113. package/dist/runtime/components/buttons/__types/AntButton.types.mjs +0 -5
  114. package/dist/runtime/components/buttons/__types/index.d.ts +0 -1
  115. package/dist/runtime/components/buttons/__types/index.mjs +0 -1
  116. package/dist/runtime/components/crud/AntCrud.vue +0 -45
  117. package/dist/runtime/components/crud/AntCrudDetail.vue +0 -11
  118. package/dist/runtime/components/crud/AntCrudDetailActions.vue +0 -58
  119. package/dist/runtime/components/crud/AntCrudDetailNav.vue +0 -64
  120. package/dist/runtime/components/crud/AntCrudTableFilter.vue +0 -122
  121. package/dist/runtime/components/crud/AntCrudTableNav.vue +0 -149
  122. package/dist/runtime/components/crud/__stories/AntCrud.stories.d.ts +0 -6
  123. package/dist/runtime/components/crud/__stories/AntCrud.stories.mjs +0 -126
  124. package/dist/runtime/components/crud/__stories/AntCrudDetail.stories.d.ts +0 -7
  125. package/dist/runtime/components/crud/__stories/AntCrudDetail.stories.mjs +0 -80
  126. package/dist/runtime/components/crud/__stories/AntCrudDetailActions.stories.d.ts +0 -6
  127. package/dist/runtime/components/crud/__stories/AntCrudDetailActions.stories.mjs +0 -25
  128. package/dist/runtime/components/crud/__stories/AntCrudDetailNav.stories.d.ts +0 -6
  129. package/dist/runtime/components/crud/__stories/AntCrudDetailNav.stories.mjs +0 -41
  130. package/dist/runtime/components/crud/__stories/AntCrudTableFilter.stories.d.ts +0 -6
  131. package/dist/runtime/components/crud/__stories/AntCrudTableFilter.stories.mjs +0 -25
  132. package/dist/runtime/components/crud/__stories/AntCrudTableNav.stories.d.ts +0 -8
  133. package/dist/runtime/components/crud/__stories/AntCrudTableNav.stories.mjs +0 -56
  134. package/dist/runtime/components/dialogs/AntDeleteDialog.vue +0 -29
  135. package/dist/runtime/components/dialogs/AntDialog.vue +0 -147
  136. package/dist/runtime/components/dialogs/__stories/AndDeleteDialog.stories.d.ts +0 -6
  137. package/dist/runtime/components/dialogs/__stories/AndDeleteDialog.stories.mjs +0 -32
  138. package/dist/runtime/components/dialogs/__stories/AntDialog.stories.d.ts +0 -6
  139. package/dist/runtime/components/dialogs/__stories/AntDialog.stories.mjs +0 -60
  140. package/dist/runtime/components/forms/AntField.vue +0 -123
  141. package/dist/runtime/components/forms/AntFormGroup.vue +0 -36
  142. package/dist/runtime/components/forms/AntFormGroupLabel.vue +0 -5
  143. package/dist/runtime/components/forms/__stories/AntField.stories.d.ts +0 -6
  144. package/dist/runtime/components/forms/__stories/AntField.stories.mjs +0 -80
  145. package/dist/runtime/components/forms/__stories/AntFormGroup.stories.d.ts +0 -6
  146. package/dist/runtime/components/forms/__stories/AntFormGroup.stories.mjs +0 -33
  147. package/dist/runtime/components/forms/__stories/AntFormGroupLabel.stories.d.ts +0 -6
  148. package/dist/runtime/components/forms/__stories/AntFormGroupLabel.stories.mjs +0 -20
  149. package/dist/runtime/components/index.d.ts +0 -62
  150. package/dist/runtime/components/index.mjs +0 -124
  151. package/dist/runtime/components/inputs/AntCheckbox.vue +0 -182
  152. package/dist/runtime/components/inputs/AntCheckboxGroup.vue +0 -117
  153. package/dist/runtime/components/inputs/AntDateInput.vue +0 -104
  154. package/dist/runtime/components/inputs/AntNumberInput.vue +0 -157
  155. package/dist/runtime/components/inputs/AntPasswordInput.vue +0 -107
  156. package/dist/runtime/components/inputs/AntRadio.vue +0 -206
  157. package/dist/runtime/components/inputs/AntRadioGroup.vue +0 -127
  158. package/dist/runtime/components/inputs/AntRangeSlider.vue +0 -101
  159. package/dist/runtime/components/inputs/AntRichTextEditor.vue +0 -237
  160. package/dist/runtime/components/inputs/AntSearch.vue +0 -75
  161. package/dist/runtime/components/inputs/AntSelect.vue +0 -319
  162. package/dist/runtime/components/inputs/AntSwitch.vue +0 -192
  163. package/dist/runtime/components/inputs/AntSwitcher.vue +0 -196
  164. package/dist/runtime/components/inputs/AntTagInput.vue +0 -339
  165. package/dist/runtime/components/inputs/AntTextInput.vue +0 -75
  166. package/dist/runtime/components/inputs/AntTextarea.vue +0 -191
  167. package/dist/runtime/components/inputs/AntUnitInput.vue +0 -96
  168. package/dist/runtime/components/inputs/Elements/AntBaseInput.vue +0 -271
  169. package/dist/runtime/components/inputs/Elements/AntDropDown.vue +0 -189
  170. package/dist/runtime/components/inputs/Elements/AntInputDescription.vue +0 -58
  171. package/dist/runtime/components/inputs/Elements/AntInputLabel.vue +0 -62
  172. package/dist/runtime/components/inputs/Elements/AntInputLimiter.vue +0 -58
  173. package/dist/runtime/components/inputs/Elements/__stories/AntBaseInput.stories.d.ts +0 -11
  174. package/dist/runtime/components/inputs/Elements/__stories/AntBaseInput.stories.mjs +0 -234
  175. package/dist/runtime/components/inputs/Elements/__stories/AntInputDescription.stories.d.ts +0 -6
  176. package/dist/runtime/components/inputs/Elements/__stories/AntInputDescription.stories.mjs +0 -34
  177. package/dist/runtime/components/inputs/Elements/__stories/AntInputLabel.stories.d.ts +0 -7
  178. package/dist/runtime/components/inputs/Elements/__stories/AntInputLabel.stories.mjs +0 -46
  179. package/dist/runtime/components/inputs/Elements/__stories/AntInputLimiter.stories.d.ts +0 -6
  180. package/dist/runtime/components/inputs/Elements/__stories/AntInputLimiter.stories.mjs +0 -37
  181. package/dist/runtime/components/inputs/Elements/__types/AntBaseInput.types.d.ts +0 -17
  182. package/dist/runtime/components/inputs/Elements/__types/AntBaseInput.types.mjs +0 -18
  183. package/dist/runtime/components/inputs/Elements/__types/index.d.ts +0 -1
  184. package/dist/runtime/components/inputs/Elements/__types/index.mjs +0 -1
  185. package/dist/runtime/components/inputs/Elements/index.d.ts +0 -6
  186. package/dist/runtime/components/inputs/Elements/index.mjs +0 -12
  187. package/dist/runtime/components/inputs/__stories/AntCheckbox.stories.d.ts +0 -8
  188. package/dist/runtime/components/inputs/__stories/AntCheckbox.stories.mjs +0 -382
  189. package/dist/runtime/components/inputs/__stories/AntCheckboxGroup.stories.d.ts +0 -7
  190. package/dist/runtime/components/inputs/__stories/AntCheckboxGroup.stories.mjs +0 -84
  191. package/dist/runtime/components/inputs/__stories/AntDateInput.stories.d.ts +0 -8
  192. package/dist/runtime/components/inputs/__stories/AntDateInput.stories.mjs +0 -193
  193. package/dist/runtime/components/inputs/__stories/AntNumberInput.stories.d.ts +0 -10
  194. package/dist/runtime/components/inputs/__stories/AntNumberInput.stories.mjs +0 -246
  195. package/dist/runtime/components/inputs/__stories/AntPasswordInput.stories.d.ts +0 -8
  196. package/dist/runtime/components/inputs/__stories/AntPasswordInput.stories.mjs +0 -156
  197. package/dist/runtime/components/inputs/__stories/AntRadioGroup.stories.d.ts +0 -8
  198. package/dist/runtime/components/inputs/__stories/AntRadioGroup.stories.mjs +0 -251
  199. package/dist/runtime/components/inputs/__stories/AntRangeSlider.stories.d.ts +0 -7
  200. package/dist/runtime/components/inputs/__stories/AntRangeSlider.stories.mjs +0 -67
  201. package/dist/runtime/components/inputs/__stories/AntRichTextEditor.stories-old.d.ts +0 -0
  202. package/dist/runtime/components/inputs/__stories/AntRichTextEditor.stories-old.mjs +0 -0
  203. package/dist/runtime/components/inputs/__stories/AntSearch.stories.d.ts +0 -7
  204. package/dist/runtime/components/inputs/__stories/AntSearch.stories.mjs +0 -103
  205. package/dist/runtime/components/inputs/__stories/AntSelect.stories.d.ts +0 -13
  206. package/dist/runtime/components/inputs/__stories/AntSelect.stories.mjs +0 -255
  207. package/dist/runtime/components/inputs/__stories/AntSwitch.stories.d.ts +0 -8
  208. package/dist/runtime/components/inputs/__stories/AntSwitch.stories.mjs +0 -344
  209. package/dist/runtime/components/inputs/__stories/AntSwitcher.stories.d.ts +0 -8
  210. package/dist/runtime/components/inputs/__stories/AntSwitcher.stories.mjs +0 -235
  211. package/dist/runtime/components/inputs/__stories/AntTagInput.stories.d.ts +0 -9
  212. package/dist/runtime/components/inputs/__stories/AntTagInput.stories.mjs +0 -228
  213. package/dist/runtime/components/inputs/__stories/AntTextInput.stories.d.ts +0 -9
  214. package/dist/runtime/components/inputs/__stories/AntTextInput.stories.mjs +0 -225
  215. package/dist/runtime/components/inputs/__stories/AntTextarea.stories.d.ts +0 -9
  216. package/dist/runtime/components/inputs/__stories/AntTextarea.stories.mjs +0 -144
  217. package/dist/runtime/components/inputs/__stories/AntUnitInput.stories.d.ts +0 -9
  218. package/dist/runtime/components/inputs/__stories/AntUnitInput.stories.mjs +0 -116
  219. package/dist/runtime/components/inputs/__types/AntCheckbox.types.d.ts +0 -6
  220. package/dist/runtime/components/inputs/__types/AntCheckbox.types.mjs +0 -0
  221. package/dist/runtime/components/inputs/__types/AntDateInput.types.d.ts +0 -7
  222. package/dist/runtime/components/inputs/__types/AntDateInput.types.mjs +0 -8
  223. package/dist/runtime/components/inputs/__types/AntRadio.types.d.ts +0 -9
  224. package/dist/runtime/components/inputs/__types/AntRadio.types.mjs +0 -0
  225. package/dist/runtime/components/inputs/__types/AntSelect.types.d.ts +0 -4
  226. package/dist/runtime/components/inputs/__types/AntSelect.types.mjs +0 -0
  227. package/dist/runtime/components/inputs/__types/AntSwitcher.types.d.ts +0 -4
  228. package/dist/runtime/components/inputs/__types/AntSwitcher.types.mjs +0 -0
  229. package/dist/runtime/components/inputs/__types/AntTagInput.types.d.ts +0 -5
  230. package/dist/runtime/components/inputs/__types/AntTagInput.types.mjs +0 -6
  231. package/dist/runtime/components/inputs/__types/AntTextInput.types.d.ts +0 -6
  232. package/dist/runtime/components/inputs/__types/AntTextInput.types.mjs +0 -7
  233. package/dist/runtime/components/inputs/__types/index.d.ts +0 -7
  234. package/dist/runtime/components/inputs/__types/index.mjs +0 -7
  235. package/dist/runtime/components/layouts/AntNavLeftLayout.vue +0 -36
  236. package/dist/runtime/components/layouts/__stories/AntNavLeftLayout.stories.d.ts +0 -7
  237. package/dist/runtime/components/layouts/__stories/AntNavLeftLayout.stories.mjs +0 -68
  238. package/dist/runtime/components/navbar/AntNavbar.vue +0 -25
  239. package/dist/runtime/components/navbar/AntNavbarItem.vue +0 -78
  240. package/dist/runtime/components/navbar/__stories/AntNavbar.stories.d.ts +0 -6
  241. package/dist/runtime/components/navbar/__stories/AntNavbar.stories.mjs +0 -66
  242. package/dist/runtime/components/navbar/__types/NavbarItem.types.d.ts +0 -10
  243. package/dist/runtime/components/navbar/__types/NavbarItem.types.mjs +0 -0
  244. package/dist/runtime/components/navbar/__types/index.d.ts +0 -1
  245. package/dist/runtime/components/navbar/__types/index.mjs +0 -1
  246. package/dist/runtime/components/table/AntTable.vue +0 -218
  247. package/dist/runtime/components/table/AntTableSortButton.vue +0 -48
  248. package/dist/runtime/components/table/AntTd.vue +0 -81
  249. package/dist/runtime/components/table/AntTh.vue +0 -78
  250. package/dist/runtime/components/table/__stories/AntTable.stories.d.ts +0 -9
  251. package/dist/runtime/components/table/__stories/AntTable.stories.mjs +0 -273
  252. package/dist/runtime/components/table/__types/TableHeader.types.d.ts +0 -36
  253. package/dist/runtime/components/table/__types/TableHeader.types.mjs +0 -25
  254. package/dist/runtime/components/table/__types/index.d.ts +0 -1
  255. package/dist/runtime/components/table/__types/index.mjs +0 -1
  256. package/dist/runtime/components/tabs/AntTabItem.vue +0 -118
  257. package/dist/runtime/components/tabs/AntTabs.vue +0 -47
  258. package/dist/runtime/components/tabs/__stories/AntTabItem.stories.d.ts +0 -6
  259. package/dist/runtime/components/tabs/__stories/AntTabItem.stories.mjs +0 -32
  260. package/dist/runtime/components/tabs/__stories/AntTabs.stories.d.ts +0 -9
  261. package/dist/runtime/components/tabs/__stories/AntTabs.stories.mjs +0 -173
  262. package/dist/runtime/components/tabs/__types/AntTabItem.types.d.ts +0 -17
  263. package/dist/runtime/components/tabs/__types/AntTabItem.types.mjs +0 -6
  264. package/dist/runtime/components/tabs/__types/index.d.ts +0 -1
  265. package/dist/runtime/components/tabs/__types/index.mjs +0 -1
  266. package/dist/runtime/components/transitions/AntTransitionCollapseHeight.vue +0 -92
  267. package/dist/runtime/composables/useUi.d.ts +0 -20
  268. package/dist/runtime/composables/useUi.mjs +0 -31
  269. package/dist/runtime/composables/useValidator.d.ts +0 -1
  270. package/dist/runtime/composables/useValidator.mjs +0 -1
  271. package/dist/runtime/enums/Direction.enum.d.ts +0 -4
  272. package/dist/runtime/enums/Direction.enum.mjs +0 -5
  273. package/dist/runtime/enums/Grouped.enum.d.ts +0 -6
  274. package/dist/runtime/enums/Grouped.enum.mjs +0 -7
  275. package/dist/runtime/enums/Position.enum.d.ts +0 -12
  276. package/dist/runtime/enums/Position.enum.mjs +0 -14
  277. package/dist/runtime/enums/Size.enum.d.ts +0 -7
  278. package/dist/runtime/enums/Size.enum.mjs +0 -8
  279. package/dist/runtime/enums/State.enum.d.ts +0 -16
  280. package/dist/runtime/enums/State.enum.mjs +0 -18
  281. package/dist/runtime/enums/index.d.ts +0 -5
  282. package/dist/runtime/enums/index.mjs +0 -5
  283. package/dist/runtime/env.d.ts +0 -8
  284. package/dist/runtime/handler.d.ts +0 -1
  285. package/dist/runtime/handler.mjs +0 -5
  286. package/dist/runtime/plugins/toaster.d.ts +0 -22
  287. package/dist/runtime/plugins/toaster.mjs +0 -53
  288. package/dist/runtime/shims/vue.d.ts +0 -5
  289. package/dist/runtime/types.d.ts +0 -8
  290. package/dist/runtime/types.mjs +0 -8
  291. package/dist/runtime/utils/helper.d.ts +0 -4
  292. package/dist/runtime/utils/helper.mjs +0 -12
  293. package/dist/runtime/utils.d.ts +0 -20
  294. package/dist/runtime/utils.mjs +0 -41
  295. package/src/runtime/components/AntAccordion.vue +0 -64
  296. package/src/runtime/components/AntAccordionItem.vue +0 -119
  297. package/src/runtime/components/AntAlert.vue +0 -146
  298. package/src/runtime/components/AntCard.vue +0 -34
  299. package/src/runtime/components/AntContent.vue +0 -16
  300. package/src/runtime/components/AntDropdown.vue +0 -100
  301. package/src/runtime/components/AntIcon.vue +0 -56
  302. package/src/runtime/components/AntKeycap.vue +0 -45
  303. package/src/runtime/components/AntListGroup.vue +0 -24
  304. package/src/runtime/components/AntListGroupItem.vue +0 -83
  305. package/src/runtime/components/AntModal.vue +0 -130
  306. package/src/runtime/components/AntPagination.vue +0 -206
  307. package/src/runtime/components/AntPopover.vue +0 -135
  308. package/src/runtime/components/AntSkeleton.vue +0 -38
  309. package/src/runtime/components/AntSpinner.vue +0 -101
  310. package/src/runtime/components/AntTag.vue +0 -114
  311. package/src/runtime/components/AntToast.vue +0 -119
  312. package/src/runtime/components/AntToaster.vue +0 -70
  313. package/src/runtime/components/AntTooltip.vue +0 -189
  314. package/src/runtime/components/buttons/AntActionButton.vue +0 -74
  315. package/src/runtime/components/buttons/AntButton.vue +0 -257
  316. package/src/runtime/components/buttons/AntCreateButton.vue +0 -54
  317. package/src/runtime/components/buttons/AntDeleteButton.vue +0 -54
  318. package/src/runtime/components/buttons/AntDuplicateButton.vue +0 -54
  319. package/src/runtime/components/buttons/AntEditButton.vue +0 -54
  320. package/src/runtime/components/buttons/AntSaveAndNewButton.vue +0 -56
  321. package/src/runtime/components/buttons/AntSaveButton.vue +0 -55
  322. package/src/runtime/components/crud/AntCrud.vue +0 -69
  323. package/src/runtime/components/crud/AntCrudDetail.vue +0 -11
  324. package/src/runtime/components/crud/AntCrudDetailActions.vue +0 -58
  325. package/src/runtime/components/crud/AntCrudDetailNav.vue +0 -64
  326. package/src/runtime/components/crud/AntCrudTableFilter.vue +0 -122
  327. package/src/runtime/components/crud/AntCrudTableNav.vue +0 -149
  328. package/src/runtime/components/dialogs/AntDeleteDialog.vue +0 -29
  329. package/src/runtime/components/dialogs/AntDialog.vue +0 -181
  330. package/src/runtime/components/forms/AntField.vue +0 -123
  331. package/src/runtime/components/forms/AntFormGroup.vue +0 -36
  332. package/src/runtime/components/forms/AntFormGroupLabel.vue +0 -5
  333. package/src/runtime/components/inputs/AntCheckbox.vue +0 -201
  334. package/src/runtime/components/inputs/AntCheckboxGroup.vue +0 -117
  335. package/src/runtime/components/inputs/AntDateInput.vue +0 -104
  336. package/src/runtime/components/inputs/AntNumberInput.vue +0 -157
  337. package/src/runtime/components/inputs/AntPasswordInput.vue +0 -107
  338. package/src/runtime/components/inputs/AntRadio.vue +0 -214
  339. package/src/runtime/components/inputs/AntRadioGroup.vue +0 -127
  340. package/src/runtime/components/inputs/AntRangeSlider.vue +0 -121
  341. package/src/runtime/components/inputs/AntRichTextEditor.vue +0 -237
  342. package/src/runtime/components/inputs/AntSearch.vue +0 -75
  343. package/src/runtime/components/inputs/AntSelect.vue +0 -319
  344. package/src/runtime/components/inputs/AntSwitch.vue +0 -192
  345. package/src/runtime/components/inputs/AntSwitcher.vue +0 -196
  346. package/src/runtime/components/inputs/AntTagInput.vue +0 -339
  347. package/src/runtime/components/inputs/AntTextInput.vue +0 -75
  348. package/src/runtime/components/inputs/AntTextarea.vue +0 -191
  349. package/src/runtime/components/inputs/AntUnitInput.vue +0 -96
  350. package/src/runtime/components/inputs/Elements/AntBaseInput.vue +0 -319
  351. package/src/runtime/components/inputs/Elements/AntDropDown.vue +0 -189
  352. package/src/runtime/components/inputs/Elements/AntInputDescription.vue +0 -58
  353. package/src/runtime/components/inputs/Elements/AntInputLabel.vue +0 -62
  354. package/src/runtime/components/inputs/Elements/AntInputLimiter.vue +0 -58
  355. package/src/runtime/components/layouts/AntNavLeftLayout.vue +0 -36
  356. package/src/runtime/components/navbar/AntNavbar.vue +0 -25
  357. package/src/runtime/components/navbar/AntNavbarItem.vue +0 -78
  358. package/src/runtime/components/table/AntTable.vue +0 -218
  359. package/src/runtime/components/table/AntTableSortButton.vue +0 -48
  360. package/src/runtime/components/table/AntTd.vue +0 -81
  361. package/src/runtime/components/table/AntTh.vue +0 -78
  362. package/src/runtime/components/tabs/AntTabItem.vue +0 -118
  363. package/src/runtime/components/tabs/AntTabs.vue +0 -47
  364. package/src/runtime/components/transitions/AntTransitionCollapseHeight.vue +0 -96
@@ -1,38 +0,0 @@
1
- <script lang="ts" setup>
2
- import {Grouped} from '../enums/Grouped.enum';
3
- import {computed} from 'vue';
4
-
5
- const props = withDefaults(defineProps<{
6
- grouped?: Grouped;
7
- rounded?: boolean;
8
- roundedFull?: boolean;
9
- absolute?: boolean;
10
- minShowTime?: number;
11
- }>(), {
12
- grouped: Grouped.none,
13
- rounded: false,
14
- roundedFull: false,
15
- absolute: false,
16
- minShowTime: 5000
17
- });
18
-
19
- const groupedClassList = computed(() => ({
20
- 'rounded-tl-md rounded-bl-md rounded-tr-none rounded-br-none': props.grouped === Grouped.left,
21
- 'rounded-none': props.grouped === Grouped.center,
22
- 'rounded-tl-none rounded-bl-none rounded-tr-md rounded-br-md': props.grouped === Grouped.right,
23
- }));
24
- const classList = computed(() => ({
25
- 'animate-skeleton min-h-[1px] min-w-[1px] inline-block': true,
26
- 'absolute inset-0 w-full h-full z-40': props.absolute,
27
- 'rounded-md': props.rounded && props.grouped === Grouped.none,
28
- 'rounded-xl': props.roundedFull && props.grouped === Grouped.none,
29
- ...groupedClassList.value
30
- }));
31
- </script>
32
-
33
- <template>
34
- <div
35
- :class="classList"
36
- data-e2e="skeleton"
37
- />
38
- </template>
@@ -1,101 +0,0 @@
1
- <script lang="ts" setup>
2
- import {computed, onMounted} from 'vue';
3
- import {AntSpinnerSize} from './__types/AntSpinner.types';
4
- import {handleEnumValidation} from '../handler';
5
- import {State} from '../enums/State.enum';
6
-
7
- const props = withDefaults(defineProps<{
8
- state?: State,
9
- size?: AntSpinnerSize;
10
- inverted?: boolean;
11
- }>(), {
12
- size: AntSpinnerSize.md,
13
- state: State.base,
14
- inverted: false
15
- });
16
-
17
- const classes = computed(() => ({
18
- 'animate-spin': true,
19
- 'w-3 h-3': props.size === AntSpinnerSize.xs2,
20
- 'w-4 h-4': props.size === AntSpinnerSize.xs,
21
- 'w-5 h-5': props.size === AntSpinnerSize.sm,
22
- 'w-6 h-6': props.size === AntSpinnerSize.md,
23
- 'w-7 h-7': props.size === AntSpinnerSize.lg,
24
- 'w-8 h-8': props.size === AntSpinnerSize.xl2,
25
- 'w-9 h-9': props.size === AntSpinnerSize.xl3,
26
- 'w-10 h-10': props.size === AntSpinnerSize.xl4,
27
- }));
28
- onMounted(() => {
29
- handleEnumValidation(props.size, AntSpinnerSize, 'size');
30
- handleEnumValidation(props.state, State, 'state');
31
- });
32
- const circleClass = computed(() => {
33
- const invertedVariants: Record<State, string> = {
34
- [State.base]: 'fill-neutral-500',
35
- [State.primary]: 'fill-primary-700',
36
- [State.secondary]: 'fill-secondary-700',
37
- [State.danger]: 'fill-danger-700',
38
- [State.info]: 'fill-info-700',
39
- [State.success]: 'fill-success-700',
40
- [State.warning]: 'fill-warning-700',
41
- };
42
- const notInvertedVariants: Record<State, string> = {
43
- [State.base]: 'fill-neutral-100',
44
- [State.primary]: 'fill-primary-100',
45
- [State.secondary]: 'fill-secondary-100',
46
- [State.danger]: 'fill-danger-100',
47
- [State.info]: 'fill-info-100',
48
- [State.success]: 'fill-success-100',
49
- [State.warning]: 'fill-warning-100',
50
- };
51
-
52
- return {
53
- [invertedVariants[props.state]]: props.inverted,
54
- [notInvertedVariants[props.state]]: !props.inverted,
55
- };
56
- });
57
- const spinningElementClass = computed(() => {
58
- const invertedVariants: Record<State, string> = {
59
- [State.base]: 'fill-neutral-100',
60
- [State.primary]: 'fill-primary-100',
61
- [State.secondary]: 'fill-secondary-100',
62
- [State.danger]: 'fill-danger-100',
63
- [State.info]: 'fill-info-100',
64
- [State.success]: 'fill-success-100',
65
- [State.warning]: 'fill-warning-100',
66
- };
67
- const notInvertedVariants: Record<State, string> = {
68
- [State.base]: 'fill-neutral-500',
69
- [State.primary]: 'fill-primary-500',
70
- [State.secondary]: 'fill-secondary-500',
71
- [State.danger]: 'fill-danger-500',
72
- [State.info]: 'fill-info-500',
73
- [State.success]: 'fill-success-500',
74
- [State.warning]: 'fill-warning-500',
75
- };
76
-
77
- return {
78
- [invertedVariants[props.state]]: props.inverted,
79
- [notInvertedVariants[props.state]]: !props.inverted,
80
- };
81
- });
82
- </script>
83
-
84
- <template>
85
- <svg
86
- :class="classes"
87
- viewBox="0 0 16 16"
88
- fill="none"
89
- xmlns="http://www.w3.org/2000/svg"
90
- data-e2e="spinner"
91
- >
92
- <path
93
- :class="circleClass"
94
- d="M8 16C12.4183 16 16 12.4183 16 8H14C14 11.5346 11.5346 14 8 14C4.46538 14 2 11.5346 2 8C2 4.46538 4.46538 2 8 2V0C3.58172 0 0 3.58172 0 8C0 12.4183 3.58172 16 8 16Z"
95
- />
96
- <path
97
- :class="spinningElementClass"
98
- d="M16 8C16 6.94942 15.7931 5.90914 15.391 4.93853C14.989 3.96793 14.3997 3.08601 13.6569 2.34315C12.914 1.60028 12.0321 1.011 11.0615 0.608963C10.0909 0.206926 9.05057 -1.7116e-07 8 0L8 2C8.78793 2 9.56815 2.15519 10.2961 2.45672C11.0241 2.75825 11.6855 3.20021 12.2426 3.75736C12.7998 4.31451 13.2417 4.97595 13.5433 5.7039C13.8448 6.43185 14 7.21207 14 8H16Z"
99
- />
100
- </svg>
101
- </template>
@@ -1,114 +0,0 @@
1
- <script lang="ts" setup>
2
- import {computed, onMounted} from 'vue';
3
- import {handleEnumValidation} from '../handler';
4
- import {faCircleXmark, type IconDefinition} from '@fortawesome/free-solid-svg-icons';
5
- import {AntTagSize, TagState} from './__types/AntTag.types';
6
- import AntIcon from './AntIcon.vue';
7
- import {IconSize} from './__types/AntIcon.types';
8
-
9
- defineEmits(['close']);
10
- const props = withDefaults(defineProps<{
11
- state?: TagState,
12
- size?: AntTagSize;
13
- iconLeft?: IconDefinition;
14
- dismiss?: boolean
15
- }>(), {
16
- size: AntTagSize.md,
17
- state: TagState.base,
18
- dismiss: false
19
- });
20
-
21
- const classes = computed(() => {
22
- const variants: Record<TagState, string> = {
23
- [TagState.danger]: 'bg-danger-500 text-danger-500-font',
24
- [TagState.info]: 'bg-info-500 text-info-500-font',
25
- [TagState.primary]: 'bg-primary-500 text-primary-500-font',
26
- [TagState.secondary]: 'bg-secondary-500 text-secondary-500-font',
27
- [TagState.base]: 'bg-neutral-300 text-neutral-300-font',
28
- [TagState.success]: 'bg-success-500 text-success-500-font',
29
- [TagState.warning]: 'bg-warning-500 text-warning-500-font',
30
- };
31
- return {
32
- 'rounded-md inline-flex items-center': true,
33
- 'px-1 py-0.5 text-xs gap-0.5': props.size === AntTagSize.xs3,
34
- 'px-1.5 py-1 text-xs gap-1': props.size === AntTagSize.xs2,
35
- 'px-2 py-1.5 text-xs gap-1.5': props.size === AntTagSize.xs,
36
- 'px-2 py-1.5 text-sm gap-1.5': props.size === AntTagSize.sm,
37
- 'px-2.5 py-2 text-sm gap-2': props.size === AntTagSize.md,
38
- 'px-3 py-2.5 text-sm gap-2.5': props.size === AntTagSize.lg,
39
- [variants[props.state]]: true,
40
- };
41
- });
42
- const getIconSize = computed(() => {
43
- if (props.size === AntTagSize.xs || props.size === AntTagSize.xs2 || props.size === AntTagSize.xs3) {
44
- return IconSize.xs;
45
- } else {
46
- return IconSize.sm;
47
- }
48
- });
49
- const iconState = computed(() => {
50
- switch (props.state) {
51
- case TagState.info:
52
- return 'text-info-500-font';
53
- case TagState.success:
54
- return 'text-success-500-font';
55
- case TagState.warning:
56
- return 'text-warning-500-font';
57
- case TagState.danger:
58
- return 'text-danger-500-font';
59
- case TagState.primary:
60
- return 'text-primary-500-font';
61
- case TagState.secondary:
62
- return 'text-secondary-500-font';
63
- default:
64
- return 'text-neutral-300-font';
65
- }
66
- });
67
- const iconWrapperClass = computed(() => {
68
- return {
69
- 'w-4 h-4': props.size === AntTagSize.xs2 || props.size === AntTagSize.xs,
70
- 'w-5 h-5': props.size === AntTagSize.sm || props.size === AntTagSize.md || props.size === AntTagSize.lg
71
- };
72
- });
73
-
74
- onMounted(() => {
75
- handleEnumValidation(props.size, AntTagSize, 'size');
76
- handleEnumValidation(props.state, TagState, 'state');
77
- });
78
- </script>
79
-
80
- <template>
81
- <span
82
- :class="classes"
83
- data-e2e="tag"
84
- >
85
- <span
86
- v-if="iconLeft"
87
- class="inline-flex items-center justify-center"
88
- :class="iconWrapperClass"
89
- >
90
- <AntIcon
91
- :icon="iconLeft"
92
- :size="getIconSize"
93
- :color="iconState"
94
- >
95
- </anticon>
96
- </span>
97
-
98
- <slot />
99
-
100
- <span
101
- v-if="dismiss"
102
- class="inline-flex items-center justify-center"
103
- :class="iconWrapperClass"
104
- >
105
- <AntIcon
106
- :icon="faCircleXmark"
107
- :size="getIconSize"
108
- :color="iconState"
109
- class="cursor-pointer"
110
- @click="() => $emit('close')"
111
- />
112
- </span>
113
- </span>
114
- </template>
@@ -1,119 +0,0 @@
1
- <script lang="ts" setup>
2
- import {computed, onMounted, useSlots} from 'vue';
3
- import {handleEnumValidation} from '../handler';
4
- import {
5
- faCheckCircle,
6
- faExclamationCircle,
7
- faExclamationTriangle,
8
- faInfoCircle,
9
- faXmark
10
- } from '@fortawesome/free-solid-svg-icons';
11
- import AntIcon from './AntIcon.vue';
12
- import AntButton from './buttons/AntButton.vue';
13
- import {State, InputState, Size} from '../enums';
14
- import {IconSize} from './__types/AntIcon.types';
15
-
16
- const props = withDefaults(defineProps<{
17
- title?: string,
18
- state?: InputState,
19
- showUndo?: boolean,
20
- icon?: boolean
21
- }>(), {
22
- state: InputState.base,
23
- showUndo: false,
24
- icon: true
25
- });
26
-
27
- const icons = {
28
- [InputState.base]: faInfoCircle,
29
- [InputState.info]: faInfoCircle,
30
- [InputState.danger]: faExclamationCircle,
31
- [InputState.warning]: faExclamationTriangle,
32
- [InputState.success]: faCheckCircle,
33
- };
34
-
35
- const _icon = computed(() => icons[props.state]);
36
- const classes = computed(() => {
37
- const variants: Record<InputState, string> = {
38
- [InputState.base]: 'bg-neutral-100 border-neutral-500 text-neutral-500',
39
- [InputState.danger]: 'bg-danger-100 border-danger-500 text-danger-500',
40
- [InputState.info]: 'bg-info-100 border-info-500 text-info-500',
41
- [InputState.success]: 'bg-success-100 border-success-500 text-success-500',
42
- [InputState.warning]: 'bg-warning-100 border-warning-500 text-warning-500',
43
- };
44
-
45
- return {
46
- 'inline-flex flex-col gap-2 rounded-md p-2 border transition-colors shadow-md': true,
47
- [variants[props.state]]: true,
48
- };
49
- });
50
- const hasDefaultSlot = computed(() => useSlots()['default'] || false);
51
- const iconColor = computed(() => {
52
- const variants = {
53
- [InputState.base]: 'text-neutral-100-font',
54
- [InputState.danger]: 'text-danger-500',
55
- [InputState.info]: 'text-info-500',
56
- [InputState.success]: 'text-success-500',
57
- [InputState.warning]: 'text-warning-500',
58
- };
59
-
60
- return variants[props.state];
61
- });
62
-
63
- onMounted(() => {
64
- handleEnumValidation(props.state, InputState, 'state');
65
- });
66
- </script>
67
-
68
- <template>
69
- <div
70
- :class="classes"
71
- data-e2e="toast"
72
- :data-e2e-state="props.state"
73
- >
74
- <div class="inline-flex items-center justify-between w-content gap-2">
75
- <div class="inline-flex items-center gap-2">
76
- <AntIcon
77
- v-if="icon"
78
- :icon="_icon"
79
- :color="iconColor"
80
- :size="IconSize.sm"
81
- />
82
-
83
- <div
84
- class="whitespace-pre text-sm"
85
- :class="{'font-semibold': hasDefaultSlot}"
86
- >
87
- <slot name="title">
88
- {{ title }}
89
- </slot>
90
- </div>
91
- </div>
92
-
93
- <AntIcon
94
- :icon="faXmark"
95
- class="cursor-pointer"
96
- :color="iconColor"
97
- @click="() => $emit('close')"
98
- />
99
- </div>
100
-
101
- <div v-if="hasDefaultSlot">
102
- <slot />
103
- </div>
104
-
105
- <div
106
- v-if="showUndo"
107
- class="flex justify-end"
108
- >
109
- <AntButton
110
- :state="props.state as unknown as State"
111
- :size="Size.md"
112
- filled
113
- @click="() => $emit('undo')"
114
- >
115
- undo
116
- </AntButton>
117
- </div>
118
- </div>
119
- </template>
@@ -1,51 +0,0 @@
1
- <script lang="ts" setup>
2
- /**
3
- * To let the toaster show toasts, use the plugin "$uiModule.toaster" property.
4
- */
5
- import {computed} from 'vue';
6
- import AntToast from './AntToast.vue';
7
- import {CornerPosition} from '../enums/Position.enum';
8
-
9
- const props = withDefaults(defineProps<{
10
- position?: CornerPosition;
11
- }>(), {
12
- position: CornerPosition.bottomLeft
13
- });
14
-
15
- const classes = computed(() => ({
16
- 'left-0 top-0 items-start': props.position === CornerPosition.topLeft,
17
- 'right-0 top-0 items-end': props.position === CornerPosition.topRight,
18
- 'left-0 bottom-0 items-start': props.position === CornerPosition.bottomLeft,
19
- 'right-0 bottom-0 items-end': props.position === CornerPosition.bottomRight,
20
- }));
21
- </script>
22
-
23
- <template>
24
- <div
25
- class="absolute flex flex-col space-y-2.5 p-2.5"
26
- :class="classes"
27
- data-e2e="toaster"
28
- >
29
- <TransitionGroup name="list">
30
- <AntToast
31
- v-for="toast of $uiModule.toaster.getToasts()"
32
- :key="`ant-toast-${toast.id}`"
33
- :title="toast.title"
34
- :state="toast.type"
35
- :icon="toast.hasIcon"
36
- @close="$uiModule.toaster.removeToast(toast)"
37
- >
38
- <template
39
- v-if="toast.content"
40
- #default
41
- >
42
- {{ toast.content }}
43
- </template>
44
- </AntToast>
45
- </TransitionGroup>
46
- </div>
47
- </template>
48
-
49
- <style>
50
- .list-move{transition:all .5s ease}.list-enter-active{animation:fade-in .6s}.list-leave-active{animation:fade-in .4s reverse}@keyframes fade-in{0%{opacity:0}to{opacity:1}}
51
- </style>
@@ -1,189 +0,0 @@
1
- <script lang="ts" setup>
2
- import {computed, onMounted, ref, getCurrentInstance} from 'vue';
3
- import {handleEnumValidation} from '../handler';
4
- import {InputState, Position} from '../enums';
5
- import {classesToObjectSyntax} from '../utils';
6
- import {hasSlotContent} from '../utils';
7
-
8
- const props = withDefaults(defineProps<{
9
- position?: Position
10
- tooltipClasses?: string | Record<string, boolean>
11
- state?: InputState
12
- expanded?: boolean
13
- delay?: number
14
- }>(), {
15
- position: Position.left,
16
- tooltipClasses: '',
17
- state: InputState.base,
18
- expanded: false,
19
- delay: 800
20
- });
21
- const visible = ref(false);
22
- const _tooltipClasses = computed(() => ({
23
- 'absolute w-max inline-flex': true,
24
- // Position
25
- 'bottom-full pb-3.5': props.position === Position.top,
26
- 'top-full pt-3.5': props.position === Position.bottom,
27
- 'right-full pr-3.5': props.position === Position.left,
28
- 'left-full pl-3.5': props.position === Position.right,
29
- ...classesToObjectSyntax(props.tooltipClasses)
30
- }));
31
- const classes = computed(() => ({
32
- 'z-10 absolute flex': true,
33
- 'top-0 left-0 right-0 -m-[2px] justify-center': props.position === Position.bottom,
34
- 'bottom-0 left-0 right-0 -m-[2px] justify-center': props.position === Position.top,
35
- 'top-0 left-0 bottom-0 -ml-[2.2px] items-center': props.position === Position.right,
36
- 'top-0 right-0 bottom-0 -mr-[2.2px] items-center': props.position === Position.left,
37
- }));
38
- const itemContainerClasses = computed(() => ({
39
- 'relative flex items-center': true,
40
- 'justify-center': props.position === Position.bottom,
41
- 'justify-center rotate-180': props.position === Position.top,
42
- 'justify-center -rotate-90': props.position === Position.right,
43
- 'justify-center rotate-90': props.position === Position.left,
44
- }));
45
- const contentClasses = computed(() => {
46
- const variants: Record<InputState, string> = {
47
- [InputState.base]: 'text-for-white-bg-font bg-white border-neutral-300',
48
- [InputState.danger]: 'text-danger-500-font bg-danger-500 border-danger-500',
49
- [InputState.info]: 'text-info-500-font bg-info-500 border-info-500',
50
- [InputState.success]: 'text-success-500-font bg-success-500 border-success-500',
51
- [InputState.warning]: 'text-warning-500-font bg-warning-500 border-warning-500',
52
- };
53
-
54
- return {[variants[props.state]]: true};
55
- });
56
- const svgPathClasses = computed(() => {
57
- const variants: Record<InputState, string> = {
58
- [InputState.base]: 'fill-white stroke-white',
59
- [InputState.danger]: 'fill-danger-500 stroke-danger-500',
60
- [InputState.info]: 'fill-info-500 stroke-info-500',
61
- [InputState.success]: 'fill-success-500 stroke-success-500',
62
- [InputState.warning]: 'fill-warning-500 stroke-warning-500',
63
- };
64
-
65
- return {[variants[props.state]]: true};
66
- });
67
- const arrowSvgPathClasses = computed(() => {
68
- const variants: Record<InputState, string> = {
69
- [InputState.base]: 'stroke-neutral-300',
70
- [InputState.danger]: 'stroke-danger-500',
71
- [InputState.info]: 'stroke-info-500',
72
- [InputState.success]: 'stroke-success-500',
73
- [InputState.warning]: 'stroke-warning-500',
74
- };
75
-
76
- return {[variants[props.state]]: true};
77
- });
78
- const timeout = ref<number | undefined>();
79
- const clickLock = ref(false);
80
- const uuid = ref(getCurrentInstance()?.uid);
81
-
82
- onMounted(() => {
83
- handleEnumValidation(props.position, Position, 'position');
84
- handleEnumValidation(props.state, InputState, 'state');
85
- });
86
-
87
- function onMouseOver() {
88
- if (visible.value || clickLock.value) {
89
- return;
90
- }
91
-
92
- /**
93
- * To prevent buggy behavior when hovering over multiple tooltips in quick succession,
94
- * we clear the timeout before setting a new one.
95
- */
96
- clearTimeout(timeout.value);
97
-
98
- timeout.value = setTimeout(() => visible.value = true, props.delay) as unknown as number;
99
- }
100
-
101
- function onMouseLeave() {
102
- clearTimeout(timeout.value);
103
-
104
- visible.value = false;
105
- clickLock.value = false;
106
- }
107
-
108
- function onClick() {
109
- clearTimeout(timeout.value);
110
-
111
- visible.value = false;
112
- clickLock.value = true;
113
- }
114
- </script>
115
-
116
- <template>
117
- <div
118
- :key="uuid"
119
- class="relative justify-center items-center"
120
- :class="{'flex w-full': props.expanded, 'inline-flex': !props.expanded}"
121
- data-e2e="tooltip"
122
- @mouseover="() => onMouseOver()"
123
- @mouseleave="() => onMouseLeave()"
124
- >
125
- <div
126
- class="w-full"
127
- @click="() => onClick()"
128
- >
129
- <slot />
130
- </div>
131
-
132
- <div
133
- v-if="visible && hasSlotContent($slots.content)"
134
- :class="_tooltipClasses"
135
- >
136
- <div
137
- class="shadow-lg text-sm relative"
138
- >
139
- <div
140
- :class="classes"
141
- >
142
- <div
143
- :class="itemContainerClasses"
144
- >
145
- <svg
146
- class="absolute mt-[.5px]"
147
- width="30"
148
- height="8"
149
- viewBox="0 0 35 8"
150
- fill="none"
151
- xmlns="http://www.w3.org/2000/svg"
152
- >
153
- <path
154
- d="M20.3284 1.82843L23.1569 4.65685C24.6571 6.15715 26.692 7 28.8137 7L6.18629 7C8.30802 7 10.3429 6.15715 11.8431 4.65686L14.6716 1.82843C16.2337 0.266331 18.7663 0.266328 20.3284 1.82843Z"
155
- :class="svgPathClasses"
156
- />
157
-
158
- <path
159
- d="M34.5 7L28.8137 7C26.692 7 24.6571 6.15715 23.1569 4.65685L20.3284 1.82843C18.7663 0.266328 16.2337 0.266331 14.6716 1.82843L11.8431 4.65686C10.3429 6.15715 8.30802 7 6.18629 7L0.5 7L34.5 7Z"
160
- :class="svgPathClasses"
161
- />
162
- </svg>
163
-
164
- <svg
165
- class="absolute"
166
- width="30"
167
- height="8"
168
- viewBox="0 0 35 8"
169
- fill="none"
170
- xmlns="http://www.w3.org/2000/svg"
171
- >
172
- <path
173
- d="M34.5 7L28.8137 7C26.692 7 24.6571 6.15715 23.1569 4.65685L20.3284 1.82843C18.7663 0.266328 16.2337 0.266331 14.6716 1.82843L11.8431 4.65686C10.3429 6.15715 8.30802 7 6.18629 7L0.5 7"
174
- :class="arrowSvgPathClasses"
175
- />
176
- </svg>
177
- </div>
178
- </div>
179
-
180
- <div
181
- class="p-2 rounded-md border"
182
- :class="contentClasses"
183
- >
184
- <slot name="content" />
185
- </div>
186
- </div>
187
- </div>
188
- </div>
189
- </template>
@@ -1,11 +0,0 @@
1
- import { Canvas, Meta, Story } from '@storybook/blocks';
2
- import * as MainStories from './Main.stories';
3
-
4
- <Meta of={MainStories} />
5
-
6
- <h1>This is the storybook for Antify UI.</h1>
7
-
8
- <p>
9
- Antify UI is a Tailwind based components library for use in Vue 3 / Nuxt
10
- projects.{' '}
11
- </p>
@@ -1,7 +0,0 @@
1
- declare const _default: {
2
- title: string;
3
- };
4
- export default _default;
5
- export declare const Main: () => {
6
- template: string;
7
- };
@@ -1,8 +0,0 @@
1
- export default {
2
- title: "Main"
3
- };
4
- export const Main = () => {
5
- return {
6
- template: "<div>main</div>"
7
- };
8
- };
@@ -1,9 +0,0 @@
1
- import AntAccordion from '../AntAccordion.vue';
2
- import { type Meta, type StoryObj } from '@storybook/vue3';
3
- declare const meta: Meta<typeof AntAccordion>;
4
- export default meta;
5
- type Story = StoryObj<typeof AntAccordion>;
6
- export declare const Docs: Story;
7
- export declare const CustomContent: Story;
8
- export declare const MultipleCollapseStrategy: Story;
9
- export declare const htmlInContent: Story;