@weni/unnnic-system 3.31.1-alpha.2 → 3.32.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 (527) hide show
  1. package/dist/style.css +1 -1
  2. package/dist/unnnic.mjs +1 -1
  3. package/dist/unnnic.umd.js +1 -1
  4. package/package.json +8 -9
  5. package/public/doris.png +0 -0
  6. package/public/favicon.ico +0 -0
  7. package/src/App.vue +0 -0
  8. package/src/assets/emoji/u1F600.png +0 -0
  9. package/src/assets/emoji/u1F601.png +0 -0
  10. package/src/assets/emoji/u1F602.png +0 -0
  11. package/src/assets/emoji/u1F603.png +0 -0
  12. package/src/assets/emoji/u1F604.png +0 -0
  13. package/src/assets/emoji/u1F605.png +0 -0
  14. package/src/assets/emoji/u1F606.png +0 -0
  15. package/src/assets/emoji/u1F607.png +0 -0
  16. package/src/assets/emoji/u1F608.png +0 -0
  17. package/src/assets/emoji/u1F609.png +0 -0
  18. package/src/assets/emoji/u1F610.png +0 -0
  19. package/src/assets/emoji/u1F611.png +0 -0
  20. package/src/assets/emoji/u1F612.png +0 -0
  21. package/src/assets/emoji/u1F613.png +0 -0
  22. package/src/assets/emoji/u1F614.png +0 -0
  23. package/src/assets/emoji/u1F615.png +0 -0
  24. package/src/assets/emoji/u1F616.png +0 -0
  25. package/src/assets/emoji/u1F617.png +0 -0
  26. package/src/assets/emoji/u1F618.png +0 -0
  27. package/src/assets/emoji/u1F619.png +0 -0
  28. package/src/assets/emoji/u1F620.png +0 -0
  29. package/src/assets/emoji/u1F621.png +0 -0
  30. package/src/assets/emoji/u1F622.png +0 -0
  31. package/src/assets/emoji/u1F623.png +0 -0
  32. package/src/assets/emoji/u1F624.png +0 -0
  33. package/src/assets/emoji/u1F625.png +0 -0
  34. package/src/assets/emoji/u1F626.png +0 -0
  35. package/src/assets/emoji/u1F627.png +0 -0
  36. package/src/assets/emoji/u1F628.png +0 -0
  37. package/src/assets/emoji/u1F629.png +0 -0
  38. package/src/assets/emoji/u1F630.png +0 -0
  39. package/src/assets/emoji/u1F631.png +0 -0
  40. package/src/assets/emoji/u1F632.png +0 -0
  41. package/src/assets/emoji/u1F633.png +0 -0
  42. package/src/assets/emoji/u1F634.png +0 -0
  43. package/src/assets/emoji/u1F635.png +0 -0
  44. package/src/assets/emoji/u1F636.png +0 -0
  45. package/src/assets/emoji/u1F637.png +0 -0
  46. package/src/assets/emoji/u1F638.png +0 -0
  47. package/src/assets/emoji/u1F639.png +0 -0
  48. package/src/assets/emoji/u1F640.png +0 -0
  49. package/src/assets/emoji/u1F641.png +0 -0
  50. package/src/assets/emoji/u1F642.png +0 -0
  51. package/src/assets/emoji/u1F643.png +0 -0
  52. package/src/assets/emoji/u1F644.png +0 -0
  53. package/src/assets/emoji/u1F645.png +0 -0
  54. package/src/assets/fonts/material-symbols-rounded.woff2 +0 -0
  55. package/src/assets/icons/Brazil.vue +74 -0
  56. package/src/assets/icons/CheckboxDefault.vue +19 -0
  57. package/src/assets/icons/CheckboxDisable.vue +19 -0
  58. package/src/assets/icons/CheckboxLess.vue +23 -0
  59. package/src/assets/icons/CheckboxSelect.vue +25 -0
  60. package/src/assets/icons/FitnessBiceps1.vue +15 -0
  61. package/src/assets/icons/Indicator.vue +18 -0
  62. package/src/assets/icons/Messages.vue +18 -0
  63. package/src/assets/icons/NavigationMenuVertical1.vue +25 -0
  64. package/src/assets/icons/Pin.vue +33 -0
  65. package/src/assets/icons/RadioDefault.vue +17 -0
  66. package/src/assets/icons/RadioDisable.vue +17 -0
  67. package/src/assets/icons/RadioSelected.vue +23 -0
  68. package/src/assets/icons/SingleNeutral2.vue +20 -0
  69. package/src/assets/icons/SingleNeutralActions1.vue +20 -0
  70. package/src/assets/icons/SocialInstagram1.vue +15 -0
  71. package/src/assets/icons/SocialMediaFacebook1.vue +15 -0
  72. package/src/assets/icons/SortAsc.vue +19 -0
  73. package/src/assets/icons/SortDefault.vue +20 -0
  74. package/src/assets/icons/SortDesc.vue +19 -0
  75. package/src/assets/icons/Spain.vue +1846 -0
  76. package/src/assets/icons/SwitchDefault.vue +31 -0
  77. package/src/assets/icons/SwitchDefaultDisabled.vue +25 -0
  78. package/src/assets/icons/SwitchSelected.vue +31 -0
  79. package/src/assets/icons/SwitchSelectedDisabled.vue +23 -0
  80. package/src/assets/icons/TransferMessage.vue +24 -0
  81. package/src/assets/icons/USA.vue +192 -0
  82. package/src/assets/icons/Unpin.vue +33 -0
  83. package/src/assets/icons/checkbox-checked-disabled.svg +3 -0
  84. package/src/assets/icons/checkbox-checked.svg +3 -0
  85. package/src/assets/icons/checkbox-less-disabled.svg +3 -0
  86. package/src/assets/icons/checkbox-less.svg +3 -0
  87. package/src/assets/icons/radio-checked.svg +3 -0
  88. package/src/assets/icons/switch-checked-disabled.svg +3 -0
  89. package/src/assets/icons/switch-checked.svg +3 -0
  90. package/src/assets/icons/weni-loading.svg +2 -0
  91. package/src/assets/img/flag/en.svg +28 -0
  92. package/src/assets/img/flag/pt-br.svg +21 -0
  93. package/src/assets/img/previews/doc-preview.png +0 -0
  94. package/src/assets/img/previews/image-preview.png +0 -0
  95. package/src/assets/img/previews/video-preview.png +0 -0
  96. package/src/assets/tokens/colors-primitives.json +155 -0
  97. package/src/assets/tokens/colors-semantic-dark.json +55 -0
  98. package/src/assets/tokens/colors-semantic.json +55 -0
  99. package/src/assets/tokens/fonts.json +70 -0
  100. package/src/assets/tokens/icon-sizes.json +22 -0
  101. package/src/assets/tokens/radii.json +28 -0
  102. package/src/assets/tokens/shadows.json +10 -0
  103. package/src/assets/tokens/spaces.json +46 -0
  104. package/src/components/Accordion/Accordion.vue +149 -0
  105. package/src/components/Alert/Alert.vue +62 -0
  106. package/src/components/Alert/Version1dot1.vue +231 -0
  107. package/src/components/Alert/__tests__/Alert.spec.js +41 -0
  108. package/src/components/Alert/__tests__/Version1dot1.spec.js +101 -0
  109. package/src/components/Alert/__tests__/__snapshots__/Alert.spec.js.snap +15 -0
  110. package/src/components/Alert/__tests__/__snapshots__/AlertBanner.spec.js.snap +10 -0
  111. package/src/components/Alert/__tests__/__snapshots__/AlertCaller.spec.js.snap +3 -0
  112. package/src/components/Alert/__tests__/__snapshots__/Version1dot1.spec.js.snap +13 -0
  113. package/src/components/AudioRecorder/AudioHandler.vue +121 -0
  114. package/src/components/AudioRecorder/AudioPlayer.vue +403 -0
  115. package/src/components/AudioRecorder/AudioRecorder.vue +475 -0
  116. package/src/components/AudioRecorder/AudioTranscriptionButton.vue +73 -0
  117. package/src/components/AvatarIcon/AvatarIcon.vue +107 -0
  118. package/src/components/AvatarIcon/__tests__/AvatarIcon.spec.js +84 -0
  119. package/src/components/AvatarIcon/__tests__/__snapshots__/AvatarIcon.spec.js.snap +7 -0
  120. package/src/components/Banner/Banner.vue +79 -0
  121. package/src/components/Banner/InfoBanner.vue +158 -0
  122. package/src/components/Breadcrumb/Breadcrumb.vue +82 -0
  123. package/src/components/Breadcrumb/__tests__/Breadcrumb.spec.js +68 -0
  124. package/src/components/Button/Button.vue +371 -0
  125. package/src/components/Button/__tests__/Button.spec.js +188 -0
  126. package/src/components/Button/types.ts +22 -0
  127. package/src/components/Card/AccountCard.vue +94 -0
  128. package/src/components/Card/BlankCard.vue +85 -0
  129. package/src/components/Card/Card.vue +218 -0
  130. package/src/components/Card/CardCompany.vue +189 -0
  131. package/src/components/Card/CardData.vue +123 -0
  132. package/src/components/Card/CardStatusesContainer.vue +255 -0
  133. package/src/components/Card/ContentCard.vue +145 -0
  134. package/src/components/Card/DashCard.vue +144 -0
  135. package/src/components/Card/DefaultCard.vue +87 -0
  136. package/src/components/Card/MarketplaceCard.vue +187 -0
  137. package/src/components/Card/SimpleCard.vue +166 -0
  138. package/src/components/Card/StatusCard.vue +113 -0
  139. package/src/components/Card/TitleCard.vue +100 -0
  140. package/src/components/CardImage/CardImage.vue +172 -0
  141. package/src/components/CardInformation/CardInformation.vue +65 -0
  142. package/src/components/CardNumber/CardNumber.vue +61 -0
  143. package/src/components/CardProject/CardProject.vue +320 -0
  144. package/src/components/CardProject/__tests__/CardProject.spec.js +161 -0
  145. package/src/components/ChartBar/ChartBar.vue +428 -0
  146. package/src/components/ChartFunnel/ChartFunnel.vue +70 -0
  147. package/src/components/ChartFunnel/DefaultFunnel/ChartDefaultFunnelBase.vue +200 -0
  148. package/src/components/ChartFunnel/DefaultFunnel/__tests__/ChartDefaultFunnelBase.unit.spec.js +123 -0
  149. package/src/components/ChartFunnel/DefaultFunnel/__tests__/__snapshots__/ChartDefaultFunnelBase.unit.spec.js.snap +66 -0
  150. package/src/components/ChartFunnel/SvgFunnel/ChartFunnelBaseRow.vue +79 -0
  151. package/src/components/ChartFunnel/SvgFunnel/ChartFunnelFiveRows.vue +101 -0
  152. package/src/components/ChartFunnel/SvgFunnel/ChartFunnelFourRows.vue +89 -0
  153. package/src/components/ChartFunnel/SvgFunnel/ChartFunnelThreeRows.vue +77 -0
  154. package/src/components/ChartFunnel/SvgFunnel/ChartFunnelTwoRows.vue +64 -0
  155. package/src/components/ChartFunnel/SvgFunnel/__tests__/ChartFunnelBaseRow.unit.spec.js +192 -0
  156. package/src/components/ChartFunnel/SvgFunnel/__tests__/ChartFunnelFiveRows.unit.spec.js +126 -0
  157. package/src/components/ChartFunnel/SvgFunnel/__tests__/ChartFunnelFourRows.unit.spec.js +122 -0
  158. package/src/components/ChartFunnel/SvgFunnel/__tests__/ChartFunnelThreeRow.unit.spec.js +120 -0
  159. package/src/components/ChartFunnel/SvgFunnel/__tests__/__snapshots__/ChartFunnelBaseRow.unit.spec.js.snap +15 -0
  160. package/src/components/ChartFunnel/SvgFunnel/__tests__/__snapshots__/ChartFunnelFiveRows.unit.spec.js.snap +3 -0
  161. package/src/components/ChartFunnel/SvgFunnel/__tests__/__snapshots__/ChartFunnelFourRows.unit.spec.js.snap +3 -0
  162. package/src/components/ChartFunnel/SvgFunnel/__tests__/__snapshots__/ChartFunnelThreeRow.unit.spec.js.snap +3 -0
  163. package/src/components/ChartFunnel/__tests__/ChartFunnel.unit.spec.js +161 -0
  164. package/src/components/ChartFunnel/__tests__/__snapshots__/ChartFunnel.unit.spec.js.snap +3 -0
  165. package/src/components/ChartLine/ChartLine.vue +322 -0
  166. package/src/components/ChartLine/__tests__/ChartLine.spec.js +170 -0
  167. package/src/components/ChartMultiLine/ChartMultiLine.vue +326 -0
  168. package/src/components/ChartMultiLine/Line/Line.vue +170 -0
  169. package/src/components/ChartRainbow/ChartRainbow.vue +201 -0
  170. package/src/components/ChatsUserAvatar/ChatsUserAvatar.vue +158 -0
  171. package/src/components/Checkbox/Checkbox.vue +192 -0
  172. package/src/components/Checkbox/__tests__/Checkbox.spec.js +65 -0
  173. package/src/components/CheckboxGroup/CheckboxGroup.vue +88 -0
  174. package/src/components/CheckboxGroup/__tests__/CheckboxGroup.spec.js +62 -0
  175. package/src/components/Chip/Chip.vue +125 -0
  176. package/src/components/Chip/__tests__/Chip.spec.js +164 -0
  177. package/src/components/Chip/types.ts +8 -0
  178. package/src/components/Collapse/Collapse.vue +142 -0
  179. package/src/components/Collapse/__tests__/Collapse.spec.js +117 -0
  180. package/src/components/Collapse/__tests__/__snapshots__/Collapse.spec.js.snap +8 -0
  181. package/src/components/Comment/Comment.vue +99 -0
  182. package/src/components/DataArea/DataArea.vue +99 -0
  183. package/src/components/DataTable/index.vue +555 -0
  184. package/src/components/DateFilter/DateFilter.vue +82 -0
  185. package/src/components/DatePicker/DatePicker.vue +1148 -0
  186. package/src/components/DatePicker/__tests__/DatePicker.spec.js +591 -0
  187. package/src/components/DatePicker/translations.js +148 -0
  188. package/src/components/Disclaimer/Disclaimer.vue +179 -0
  189. package/src/components/Disclaimer/__tests__/Disclaimer.spec.js +165 -0
  190. package/src/components/Disclaimer/types.ts +16 -0
  191. package/src/components/Drawer/Drawer.vue +248 -0
  192. package/src/components/Drawer/__tests__/Drawer.spec.js +280 -0
  193. package/src/components/Drawer/__tests__/__snapshots__/Drawer.spec.js.snap +22 -0
  194. package/src/components/DropArea/DropArea.vue +373 -0
  195. package/src/components/DropArea/__tests__/DropArea.spec.js +333 -0
  196. package/src/components/Dropdown/Dropdown.vue +142 -0
  197. package/src/components/Dropdown/DropdownItem.vue +32 -0
  198. package/src/components/Dropdown/DropdownSkeleton.vue +180 -0
  199. package/src/components/Dropdown/LanguageSelect.vue +296 -0
  200. package/src/components/Dropdown/__tests__/Dropdown.spec.js +155 -0
  201. package/src/components/Dropdown/__tests__/DropdownItem.spec.js +25 -0
  202. package/src/components/Dropdown/__tests__/DropdownSkeleton.spec.js +147 -0
  203. package/src/components/EmojiPicker/EmojiPicker.vue +244 -0
  204. package/src/components/EmojiPicker/__tests__/EmojiPicker.spec.js +236 -0
  205. package/src/components/Flag.vue +40 -0
  206. package/src/components/FormElement/FormElement.vue +139 -0
  207. package/src/components/Icon/OldIconsMap.json +111 -0
  208. package/src/components/Icon/types.ts +26 -0
  209. package/src/components/Icon.vue +198 -0
  210. package/src/components/IconLoading/IconLoading.vue +107 -0
  211. package/src/components/ImportCard/ImportCard.vue +245 -0
  212. package/src/components/Input/BaseInput.vue +156 -0
  213. package/src/components/Input/Input.scss +43 -0
  214. package/src/components/Input/Input.vue +191 -0
  215. package/src/components/Input/TextInput.vue +233 -0
  216. package/src/components/Input/__test__/BaseInput.spec.js +107 -0
  217. package/src/components/Input/__test__/Input.spec.js +103 -0
  218. package/src/components/Input/__test__/TextInput.spec.js +209 -0
  219. package/src/components/Input/__test__/__snapshots__/BaseInput.spec.js.snap +3 -0
  220. package/src/components/Input/__test__/__snapshots__/Input.spec.js.snap +22 -0
  221. package/src/components/Input/__test__/__snapshots__/TextInput.spec.js.snap +9 -0
  222. package/src/components/InputDatePicker/InputDatePicker.vue +253 -0
  223. package/src/components/InputDatePicker/__test__/InputDatePicker.spec.js +208 -0
  224. package/src/components/Label/Label.vue +62 -0
  225. package/src/components/Label/__tests__/Label.spec.js +30 -0
  226. package/src/components/Label/__tests__/__snapshots__/Label.spec.js.snap +3 -0
  227. package/src/components/Modal/CallModal.vue +23 -0
  228. package/src/components/Modal/Modal.vue +377 -0
  229. package/src/components/ModalDialog/ModalDialog.vue +245 -0
  230. package/src/components/ModalDialog/__tests__/ModalDialog.spec.js +159 -0
  231. package/src/components/ModalDialog/__tests__/__snapshots__/ModalDialog.spec.js.snap +3 -0
  232. package/src/components/ModalNext/ModalNext.vue +437 -0
  233. package/src/components/MultiSelect/MultiSelectOption.vue +49 -0
  234. package/src/components/MultiSelect/__tests__/MultiSelect.spec.js +655 -0
  235. package/src/components/MultiSelect/__tests__/MultiSelectOption.spec.js +229 -0
  236. package/src/components/MultiSelect/__tests__/__snapshots__/MultiSelect.spec.js.snap +91 -0
  237. package/src/components/MultiSelect/__tests__/__snapshots__/MultiSelectOption.spec.js.snap +51 -0
  238. package/src/components/MultiSelect/index.vue +240 -0
  239. package/src/components/Navigator/__tests__/Navigator.spec.js +55 -0
  240. package/src/components/Navigator/index.vue +100 -0
  241. package/src/components/PageHeader/PageHeader.vue +151 -0
  242. package/src/components/PageHeader/__tests__/PageHeader.spec.js +97 -0
  243. package/src/components/PageHeader/index.ts +2 -0
  244. package/src/components/PageHeader/types.ts +11 -0
  245. package/src/components/Pagination/Pagination.vue +190 -0
  246. package/src/components/Pagination/__tests__/Pagination.spec.js +307 -0
  247. package/src/components/ProgressBar/ProgressBar.vue +245 -0
  248. package/src/components/Radio/Radio.vue +168 -0
  249. package/src/components/Radio/__test__/Radio.spec.js +145 -0
  250. package/src/components/Radio/__test__/__snapshots__/Radio.spec.js.snap +8 -0
  251. package/src/components/RadioGroup/RadioGroup.vue +128 -0
  252. package/src/components/RadioGroup/__tests__/RadioGroup.spec.js +100 -0
  253. package/src/components/Select/SelectItem.vue +85 -0
  254. package/src/components/Select/__tests__/Select.spec.js +626 -0
  255. package/src/components/Select/__tests__/SelectItem.spec.js +330 -0
  256. package/src/components/Select/__tests__/__snapshots__/Popover.spec.js.snap +8 -0
  257. package/src/components/Select/__tests__/__snapshots__/Select.spec.js.snap +91 -0
  258. package/src/components/Select/__tests__/__snapshots__/SelectItem.spec.js.snap +15 -0
  259. package/src/components/Select/__tests__/__snapshots__/SelectOption.spec.js.snap +25 -0
  260. package/src/components/Select/__tests__/__snapshots__/SelectPopover.spec.js.snap +8 -0
  261. package/src/components/Select/_select-shared.scss +25 -0
  262. package/src/components/Select/index.vue +459 -0
  263. package/src/components/Select/types.ts +37 -0
  264. package/src/components/SelectSmart/SelectSmart.vue +873 -0
  265. package/src/components/SelectSmart/SelectSmartMultipleHeader.vue +144 -0
  266. package/src/components/SelectSmart/SelectSmartOption.vue +178 -0
  267. package/src/components/SelectSmart/__tests__/SelectSmart.spec.js +527 -0
  268. package/src/components/SelectSmart/__tests__/SelectSmartMultipleHeader.spec.js +86 -0
  269. package/src/components/SelectSmart/__tests__/SelectSmartOption.spec.js +139 -0
  270. package/src/components/SelectSmart/__tests__/__snapshots__/SelectSmartMultipleHeader.spec.js.snap +8 -0
  271. package/src/components/SelectSmart/__tests__/__snapshots__/SelectSmartOption.spec.js.snap +10 -0
  272. package/src/components/SelectTime/index.vue +220 -0
  273. package/src/components/Sidebar/SidebarItem.vue +224 -0
  274. package/src/components/Sidebar/__tests__/SidebarItem.spec.js +105 -0
  275. package/src/components/Sidebar/__tests__/Siderbar.spec.js +92 -0
  276. package/src/components/Sidebar/index.vue +126 -0
  277. package/src/components/Sidebar/propsValidator.js +24 -0
  278. package/src/components/SkeletonLoading/SkeletonLoading.vue +156 -0
  279. package/src/components/SkeletonLoading/__tests__/SkeletonLoading.spec.js +128 -0
  280. package/src/components/SkeletonLoading/skeletonTheme.vue +66 -0
  281. package/src/components/Switch/Switch.vue +185 -0
  282. package/src/components/Switch/__tests__/Switch.spec.js +55 -0
  283. package/src/components/Switch/__tests__/__snapshots__/Switch.spec.js.snap +10 -0
  284. package/src/components/Tab/Tab.vue +203 -0
  285. package/src/components/Tab/__test__/Tab.spec.js +152 -0
  286. package/src/components/Tab/__test__/__snapshots__/Tab.spec.js.snap +23 -0
  287. package/src/components/Table/Table.vue +143 -0
  288. package/src/components/Table/TableRow.vue +101 -0
  289. package/src/components/TableNext/TableBodyCell.vue +47 -0
  290. package/src/components/TableNext/TableNext.vue +428 -0
  291. package/src/components/TableNext/TablePagination.vue +98 -0
  292. package/src/components/TableNext/__test__/TableBodyCell.spec.js +65 -0
  293. package/src/components/TableNext/__test__/TableNext.spec.js +197 -0
  294. package/src/components/TableNext/__test__/TablePagination.spec.js +65 -0
  295. package/src/components/TableNext/__test__/__snapshots__/TableNext.spec.js.snap +59 -0
  296. package/src/components/TableNext/__test__/__snapshots__/TablePagination.spec.js.snap +41 -0
  297. package/src/components/TableNext/__test__/validation.unit.test.js +90 -0
  298. package/src/components/TableNext/validation.js +66 -0
  299. package/src/components/TabsExpanded/TabsExpanded.vue +156 -0
  300. package/src/components/TabsExpanded/__tests__/TabsExpanded.spec.js +78 -0
  301. package/src/components/Tag/DefaultTag.vue +87 -0
  302. package/src/components/Tag/Tag.vue +43 -0
  303. package/src/components/Tag/__tests__/DefaultTag.spec.js +51 -0
  304. package/src/components/Tag/__tests__/Tag.spec.js +82 -0
  305. package/src/components/Tag/types.ts +19 -0
  306. package/src/components/TemplatePreview/TemplatePreview.vue +252 -0
  307. package/src/components/TemplatePreview/TemplatePreviewModal.vue +51 -0
  308. package/src/components/TemplatePreview/types.d.ts +16 -0
  309. package/src/components/TextArea/TextArea.vue +138 -0
  310. package/src/components/TextArea/__test__/TextArea.spec.js +218 -0
  311. package/src/components/TextArea/__test__/__snapshots__/TextArea.spec.js.snap +17 -0
  312. package/src/components/Toast/Toast.vue +252 -0
  313. package/src/components/Toast/ToastManager.ts +113 -0
  314. package/src/components/Toast/__tests__/Toast.spec.js +291 -0
  315. package/src/components/Toast/__tests__/ToastManager.spec.js +298 -0
  316. package/src/components/Toast/types.ts +57 -0
  317. package/src/components/ToolTip/ToolTip.vue +99 -0
  318. package/src/components/ToolTip/__tests__/ToolTip.spec.js +451 -0
  319. package/src/components/Tour/Tour.vue +138 -0
  320. package/src/components/Tour/TourMask.vue +135 -0
  321. package/src/components/Tour/TourPopover.vue +236 -0
  322. package/src/components/Tour/propsValidation.js +82 -0
  323. package/src/components/UploadArea/UploadArea.vue +141 -0
  324. package/src/components/__tests__/Icon.spec.js +94 -0
  325. package/src/components/config.js +1 -0
  326. package/src/components/grid/Grid.vue +50 -0
  327. package/src/components/icons/IconCommunity.vue +12 -0
  328. package/src/components/icons/IconDocumentation.vue +12 -0
  329. package/src/components/icons/IconEcosystem.vue +12 -0
  330. package/src/components/icons/IconSupport.vue +12 -0
  331. package/src/components/icons/IconTooling.vue +19 -0
  332. package/src/components/icons/iconArrowsDefault.vue +16 -0
  333. package/src/components/index.ts +468 -0
  334. package/src/components/ui/dialog/Dialog.vue +51 -0
  335. package/src/components/ui/dialog/DialogClose.vue +29 -0
  336. package/src/components/ui/dialog/DialogContent.vue +141 -0
  337. package/src/components/ui/dialog/DialogFooter.vue +46 -0
  338. package/src/components/ui/dialog/DialogHeader.vue +83 -0
  339. package/src/components/ui/dialog/DialogTitle.vue +38 -0
  340. package/src/components/ui/dialog/DialogTrigger.vue +16 -0
  341. package/src/components/ui/dialog/index.ts +7 -0
  342. package/src/components/ui/drawer/Drawer.vue +80 -0
  343. package/src/components/ui/drawer/DrawerClose.vue +31 -0
  344. package/src/components/ui/drawer/DrawerContent.vue +114 -0
  345. package/src/components/ui/drawer/DrawerDescription.vue +40 -0
  346. package/src/components/ui/drawer/DrawerFooter.vue +34 -0
  347. package/src/components/ui/drawer/DrawerHeader.vue +57 -0
  348. package/src/components/ui/drawer/DrawerOverlay.vue +33 -0
  349. package/src/components/ui/drawer/DrawerTitle.vue +37 -0
  350. package/src/components/ui/drawer/DrawerTrigger.vue +31 -0
  351. package/src/components/ui/drawer/index.ts +10 -0
  352. package/src/components/ui/popover/Popover.vue +19 -0
  353. package/src/components/ui/popover/PopoverContent.vue +113 -0
  354. package/src/components/ui/popover/PopoverFooter.vue +47 -0
  355. package/src/components/ui/popover/PopoverOption.vue +130 -0
  356. package/src/components/ui/popover/PopoverTrigger.vue +27 -0
  357. package/src/components/ui/popover/__tests__/PopoverFooter.spec.js +116 -0
  358. package/src/components/ui/popover/context.ts +4 -0
  359. package/src/components/ui/popover/index.ts +6 -0
  360. package/src/components/ui/segmented-control/SegmentedControlList.vue +51 -0
  361. package/src/components/ui/segmented-control/SegmentedControlTrigger.vue +81 -0
  362. package/src/components/ui/segmented-control/index.ts +4 -0
  363. package/src/components/ui/table/Table.vue +29 -0
  364. package/src/components/ui/table/TableBody.vue +14 -0
  365. package/src/components/ui/table/TableCell.vue +28 -0
  366. package/src/components/ui/table/TableHead.vue +27 -0
  367. package/src/components/ui/table/TableHeader.vue +24 -0
  368. package/src/components/ui/table/TableRow.vue +51 -0
  369. package/src/components/ui/table/index.ts +6 -0
  370. package/src/components/ui/tabs/Tabs.vue +19 -0
  371. package/src/components/ui/tabs/TabsContent.vue +22 -0
  372. package/src/components/ui/tabs/TabsList.vue +40 -0
  373. package/src/components/ui/tabs/TabsTrigger.vue +63 -0
  374. package/src/components/ui/tabs/index.ts +4 -0
  375. package/src/components/ui/tooltip/Tooltip.vue +21 -0
  376. package/src/components/ui/tooltip/TooltipContent.vue +84 -0
  377. package/src/components/ui/tooltip/TooltipTrigger.vue +24 -0
  378. package/src/components/ui/tooltip/index.ts +3 -0
  379. package/src/composables/useDelayedUnmount.ts +48 -0
  380. package/src/composables/useSelectBase.ts +119 -0
  381. package/src/composables/useSelectKeyboard.ts +91 -0
  382. package/src/composables/useTheme.ts +67 -0
  383. package/src/index.ts +29 -0
  384. package/src/lib/__tests__/teleport-target.spec.ts +73 -0
  385. package/src/lib/layer-manager.ts +64 -0
  386. package/src/lib/teleport-target.ts +46 -0
  387. package/src/lib/utils.ts +7 -0
  388. package/src/locales/en.json +50 -0
  389. package/src/locales/es.json +50 -0
  390. package/src/locales/pt_br.json +50 -0
  391. package/src/main.ts +9 -0
  392. package/src/mixins/i18n.js +74 -0
  393. package/src/stories/Accordion.stories.js +54 -0
  394. package/src/stories/Alert.stories.js +157 -0
  395. package/src/stories/AudioRecorder.stories.js +52 -0
  396. package/src/stories/AvatarIcon.stories.js +57 -0
  397. package/src/stories/Banner.stories.js +54 -0
  398. package/src/stories/Breadcrumb.stories.js +30 -0
  399. package/src/stories/Button.stories.js +183 -0
  400. package/src/stories/Card.stories.js +154 -0
  401. package/src/stories/CardCompany.stories.js +64 -0
  402. package/src/stories/CardData.stories.js +25 -0
  403. package/src/stories/CardImage.stories.js +58 -0
  404. package/src/stories/CardInformation.stories.js +44 -0
  405. package/src/stories/CardNumber.stories.js +15 -0
  406. package/src/stories/CardProject.stories.js +70 -0
  407. package/src/stories/CardSimple.stories.js +73 -0
  408. package/src/stories/ChartBar.stories.js +123 -0
  409. package/src/stories/ChartFunnel.stories.js +127 -0
  410. package/src/stories/ChartLine.stories.js +55 -0
  411. package/src/stories/ChartMultiLine.stories.js +50 -0
  412. package/src/stories/ChartRainbow.stories.js +18 -0
  413. package/src/stories/ChatsUserAvatar.stories.js +36 -0
  414. package/src/stories/Checkbox.stories.js +79 -0
  415. package/src/stories/CheckboxGroup.stories.js +105 -0
  416. package/src/stories/Chip.stories.js +194 -0
  417. package/src/stories/Collapse.stories.js +81 -0
  418. package/src/stories/Colors.mdx +13 -0
  419. package/src/stories/Colors.stories.js +132 -0
  420. package/src/stories/Comment.stories.js +66 -0
  421. package/src/stories/DataArea.stories.js +78 -0
  422. package/src/stories/DataTable.stories.js +588 -0
  423. package/src/stories/DateFilter.stories.js +18 -0
  424. package/src/stories/DatePicker.stories.js +114 -0
  425. package/src/stories/Dialog.stories.js +851 -0
  426. package/src/stories/Disclaimer.stories.js +93 -0
  427. package/src/stories/Drawer.stories.js +242 -0
  428. package/src/stories/DrawerNext.stories.js +631 -0
  429. package/src/stories/DropArea.mdx +66 -0
  430. package/src/stories/DropArea.stories.js +74 -0
  431. package/src/stories/Dropdown.stories.js +35 -0
  432. package/src/stories/EmojiPicker.stories.js +93 -0
  433. package/src/stories/FormElement.stories.js +35 -0
  434. package/src/stories/Grid.stories.js +19 -0
  435. package/src/stories/Icon.stories.js +144 -0
  436. package/src/stories/IconLoading.stories.js +63 -0
  437. package/src/stories/Iconography.mdx +7 -0
  438. package/src/stories/ImportCard.stories.js +33 -0
  439. package/src/stories/Input.mdx +79 -0
  440. package/src/stories/Input.stories.js +157 -0
  441. package/src/stories/InputDatePicker.stories.js +155 -0
  442. package/src/stories/Label.stories.js +30 -0
  443. package/src/stories/LanguageSelect.stories.js +26 -0
  444. package/src/stories/LayerManager.docs.mdx +40 -0
  445. package/src/stories/LayerManager.stories.js +407 -0
  446. package/src/stories/Modal.stories.js +101 -0
  447. package/src/stories/ModalDialog.mdx +89 -0
  448. package/src/stories/ModalDialog.stories.js +448 -0
  449. package/src/stories/ModalNext.stories.js +191 -0
  450. package/src/stories/MultiSelect.stories.js +169 -0
  451. package/src/stories/Navigator.stories.js +26 -0
  452. package/src/stories/PageHeader.stories.js +364 -0
  453. package/src/stories/Pagination.stories.js +37 -0
  454. package/src/stories/Popover.stories.js +457 -0
  455. package/src/stories/PopoverOption.stories.js +128 -0
  456. package/src/stories/ProgressBar.stories.js +38 -0
  457. package/src/stories/Radio.stories.js +104 -0
  458. package/src/stories/RadioGroup.stories.js +145 -0
  459. package/src/stories/SegmentedControl.stories.js +253 -0
  460. package/src/stories/Select.stories.js +375 -0
  461. package/src/stories/SelectSmart.mdx +152 -0
  462. package/src/stories/SelectSmart.stories.js +594 -0
  463. package/src/stories/SelectTime.stories.js +25 -0
  464. package/src/stories/Sidebar.stories.js +157 -0
  465. package/src/stories/SkeletonLoading.stories.js +28 -0
  466. package/src/stories/Switch.stories.js +46 -0
  467. package/src/stories/Tab.stories.js +56 -0
  468. package/src/stories/Table.stories.js +218 -0
  469. package/src/stories/TableNext.stories.js +176 -0
  470. package/src/stories/Tabs.stories.js +169 -0
  471. package/src/stories/TabsExpanded.stories.js +69 -0
  472. package/src/stories/Tag.stories.js +59 -0
  473. package/src/stories/TemplatePreview.stories.js +94 -0
  474. package/src/stories/TemplatePreviewModal.stories.js +110 -0
  475. package/src/stories/TextArea.mdx +68 -0
  476. package/src/stories/TextArea.stories.js +117 -0
  477. package/src/stories/Toast.mdx +123 -0
  478. package/src/stories/Toast.stories.js +126 -0
  479. package/src/stories/ToolTip.stories.js +71 -0
  480. package/src/stories/Tour.stories.js +216 -0
  481. package/src/stories/Typography.mdx +83 -0
  482. package/src/stories/Typography.stories.js +66 -0
  483. package/src/stories/UploadArea.stories.js +42 -0
  484. package/src/stories/assets/audios/audio-recorder-sample.mp3 +0 -0
  485. package/src/stories/assets/code-brackets.svg +1 -0
  486. package/src/stories/assets/colors.svg +1 -0
  487. package/src/stories/assets/comments.svg +1 -0
  488. package/src/stories/assets/direction.svg +1 -0
  489. package/src/stories/assets/flow.svg +1 -0
  490. package/src/stories/assets/images/un.png +0 -0
  491. package/src/stories/assets/images/unnnic.png +0 -0
  492. package/src/stories/assets/images/unnnicPortrait.png +0 -0
  493. package/src/stories/assets/plugin.svg +1 -0
  494. package/src/stories/assets/repo.svg +1 -0
  495. package/src/stories/assets/stackalt.svg +1 -0
  496. package/src/stories/assets/videos/weni.mp4 +0 -0
  497. package/src/types/index.d.ts +53 -0
  498. package/src/types/scheme-colors.d.ts +209 -0
  499. package/src/types/unnnic-utils.d.ts +88 -0
  500. package/src/types/vue-shims.d.ts +5 -0
  501. package/src/types/vueuse-overrides.d.ts +7 -0
  502. package/src/utils/call.js +81 -0
  503. package/src/utils/colorTokens.js +2 -0
  504. package/src/utils/colorsList.js +89 -0
  505. package/src/utils/emojiList.js +47 -0
  506. package/src/utils/hours.js +100 -0
  507. package/src/utils/iconList.js +108 -0
  508. package/src/utils/icons.js +59 -0
  509. package/src/utils/plugins/i18n.js +20 -0
  510. package/src/utils/sanitize.js +75 -0
  511. /package/{dist → src/assets}/scss/colors-hsl.scss +0 -0
  512. /package/{dist → src/assets}/scss/colors.scss +0 -0
  513. /package/{dist → src/assets}/scss/deprecated/colors.scss +0 -0
  514. /package/{dist → src/assets}/scss/deprecated/fonts.scss +0 -0
  515. /package/{dist → src/assets}/scss/deprecated/grid.scss +0 -0
  516. /package/{dist → src/assets}/scss/deprecated/spacing.scss +0 -0
  517. /package/{dist → src/assets}/scss/fonts.scss +0 -0
  518. /package/{dist → src/assets}/scss/icon-sizes.scss +0 -0
  519. /package/{dist → src/assets}/scss/radii.scss +0 -0
  520. /package/{dist → src/assets}/scss/scheme-colors.scss +0 -0
  521. /package/{dist → src/assets}/scss/semantic-colors.scss +0 -0
  522. /package/{dist → src/assets}/scss/semantic-text-utilities.scss +0 -0
  523. /package/{dist → src/assets}/scss/shadows.scss +0 -0
  524. /package/{dist → src/assets}/scss/spaces.scss +0 -0
  525. /package/{dist → src/assets}/scss/tailwind.scss +0 -0
  526. /package/{dist → src/assets}/scss/theme.scss +0 -0
  527. /package/{dist → src/assets}/scss/unnnic.scss +0 -0
@@ -0,0 +1,77 @@
1
+ <template>
2
+ <ChartFunnelBaseRow
3
+ class="unnnic-chart-funnel-three-rows"
4
+ :rows="rows"
5
+ viewBox="0 0 375 222"
6
+ />
7
+ </template>
8
+
9
+ <script>
10
+ import ChartFunnelBaseRow from './ChartFunnelBaseRow.vue';
11
+ export default {
12
+ name: 'UnnnicChartFunnelThreeRows',
13
+
14
+ components: {
15
+ ChartFunnelBaseRow,
16
+ },
17
+
18
+ props: {
19
+ data: {
20
+ type: Array,
21
+ required: true,
22
+ },
23
+ },
24
+
25
+ computed: {
26
+ rows() {
27
+ const { data } = this;
28
+ return [
29
+ {
30
+ pathD:
31
+ 'M362.938 0H12.025C6.30976 0 2.43799 5.81972 4.64626 11.0911L31 74H343.75L370.307 11.1122C372.535 5.83818 368.663 0 362.938 0Z',
32
+ titleX: '50%',
33
+ titleY: '32',
34
+ descriptionX: '50%',
35
+ descriptionY: '52',
36
+ title: data[0].title,
37
+ description: data[0].description,
38
+ },
39
+ {
40
+ pathD: 'M344 74H31L63.4654 148H311.535L344 74Z',
41
+ titleX: '50%',
42
+ titleY: '106',
43
+ descriptionX: '50%',
44
+ descriptionY: '126',
45
+ title: data[1].title,
46
+ description: data[1].description,
47
+ },
48
+ {
49
+ pathD:
50
+ 'M311.5 148H63.5L93.8569 217.213C95.1325 220.122 98.0075 222 101.183 222H275.372C278.603 222 281.517 220.056 282.758 217.073L311.5 148Z',
51
+ titleX: '50%',
52
+ titleY: '180',
53
+ descriptionX: '50%',
54
+ descriptionY: '200',
55
+ title: data[2].title,
56
+ description: data[2].description,
57
+ },
58
+ ];
59
+ },
60
+ },
61
+ };
62
+ </script>
63
+
64
+ <style lang="scss">
65
+ @use '@/assets/scss/unnnic' as *;
66
+ .unnnic-chart-funnel-three-rows {
67
+ [class$='row']:nth-child(1) {
68
+ fill: $unnnic-color-weni-950;
69
+ }
70
+ [class$='row']:nth-child(2) {
71
+ fill: $unnnic-color-weni-800;
72
+ }
73
+ [class$='row']:nth-child(3) {
74
+ fill: $unnnic-color-weni-600;
75
+ }
76
+ }
77
+ </style>
@@ -0,0 +1,64 @@
1
+ <template>
2
+ <ChartFunnelBaseRow
3
+ class="unnnic-chart-funnel-two-rows"
4
+ :rows="rows"
5
+ viewBox="0 0 250 148"
6
+ />
7
+ </template>
8
+
9
+ <script>
10
+ import ChartFunnelBaseRow from './ChartFunnelBaseRow.vue';
11
+ export default {
12
+ name: 'UnnnicChartFunnelTwoRows',
13
+
14
+ components: {
15
+ ChartFunnelBaseRow,
16
+ },
17
+
18
+ props: {
19
+ data: {
20
+ type: Array,
21
+ required: true,
22
+ },
23
+ },
24
+
25
+ computed: {
26
+ rows() {
27
+ const { data } = this;
28
+ return [
29
+ {
30
+ pathD:
31
+ 'M362.938 0H12.025C6.30976 0 2.43799 5.81972 4.64626 11.0911L31 74H343.75L370.307 11.1122C372.535 5.83818 368.663 0 362.938 0Z',
32
+ titleX: '50%',
33
+ titleY: '32',
34
+ descriptionX: '50%',
35
+ descriptionY: '52',
36
+ title: data[0].title,
37
+ description: data[0].description,
38
+ },
39
+ {
40
+ pathD: 'M344 74H31L63.4654 148H311.535L344 74Z',
41
+ titleX: '50%',
42
+ titleY: '106',
43
+ descriptionX: '50%',
44
+ descriptionY: '126',
45
+ title: data[1].title,
46
+ description: data[1].description,
47
+ },
48
+ ];
49
+ },
50
+ },
51
+ };
52
+ </script>
53
+
54
+ <style lang="scss">
55
+ @use '@/assets/scss/unnnic' as *;
56
+ .unnnic-chart-funnel-two-rows {
57
+ [class$='row']:nth-child(1) {
58
+ fill: $unnnic-color-weni-950;
59
+ }
60
+ [class$='row']:nth-child(2) {
61
+ fill: $unnnic-color-weni-800;
62
+ }
63
+ }
64
+ </style>
@@ -0,0 +1,192 @@
1
+ import { mount } from '@vue/test-utils';
2
+ import { describe, expect, test, beforeEach } from 'vitest';
3
+ import ChartFunnelBaseRow from '@/components/ChartFunnel/SvgFunnel/ChartFunnelBaseRow.vue';
4
+
5
+ describe('ChartFunnelBaseRow.vue', () => {
6
+ let wrapper;
7
+ const mockRows = [
8
+ {
9
+ title: '100%',
10
+ description: 'First Level',
11
+ pathD: 'M0 0 L100 0 L80 50 L20 50 Z',
12
+ titleY: '20',
13
+ descriptionY: '35',
14
+ },
15
+ {
16
+ title: '75%',
17
+ description: 'Second Level',
18
+ pathD: 'M20 50 L80 50 L60 100 L40 100 Z',
19
+ titleY: '70',
20
+ descriptionY: '85',
21
+ },
22
+ {
23
+ title: '50%',
24
+ description: 'Third Level',
25
+ pathD: 'M40 100 L60 100 L50 150 L50 150 Z',
26
+ titleY: '120',
27
+ descriptionY: '135',
28
+ },
29
+ ];
30
+
31
+ beforeEach(() => {
32
+ wrapper = mount(ChartFunnelBaseRow, {
33
+ props: {
34
+ rows: mockRows,
35
+ viewBox: '0 0 100 150',
36
+ },
37
+ });
38
+ });
39
+
40
+ test('renders correctly', () => {
41
+ expect(wrapper.exists()).toBe(true);
42
+ });
43
+
44
+ test('validates required props', () => {
45
+ const { rows } = wrapper.vm.$options.props;
46
+ expect(rows.required).toBe(true);
47
+ expect(rows.type).toBe(Array);
48
+ });
49
+
50
+ test('validates optional viewBox prop', () => {
51
+ const { viewBox } = wrapper.vm.$options.props;
52
+ expect(viewBox.type).toBe(String);
53
+ expect(viewBox.required).toBeTruthy();
54
+ });
55
+
56
+ test('applies correct viewBox to svg element', () => {
57
+ const svg = wrapper.find('svg');
58
+ expect(svg.attributes('viewBox')).toBe('0 0 100 150');
59
+ });
60
+
61
+ test('renders correct number of rows', () => {
62
+ const rows = wrapper.findAll('.unnnic-chart-funnel-base-rows__row');
63
+ expect(rows).toHaveLength(mockRows.length);
64
+ });
65
+
66
+ describe('row elements rendering', () => {
67
+ test('renders paths with correct d attribute', () => {
68
+ const paths = wrapper.findAll('.row__path');
69
+ paths.forEach((path, index) => {
70
+ expect(path.attributes('d')).toBe(mockRows[index].pathD);
71
+ });
72
+ });
73
+
74
+ test('renders titles with correct text and position', () => {
75
+ const titles = wrapper.findAll('.row__title');
76
+ titles.forEach((title, index) => {
77
+ expect(title.text()).toBe(mockRows[index].title);
78
+ expect(title.attributes('x')).toBe('50%');
79
+ expect(title.attributes('y')).toBe(mockRows[index].titleY);
80
+ });
81
+ });
82
+
83
+ test('renders descriptions with correct text and position', () => {
84
+ const descriptions = wrapper.findAll('.row__description');
85
+ descriptions.forEach((description, index) => {
86
+ expect(description.text()).toBe(mockRows[index].description);
87
+ expect(description.attributes('x')).toBe('50%');
88
+ expect(description.attributes('y')).toBe(mockRows[index].descriptionY);
89
+ });
90
+ });
91
+ });
92
+
93
+ test('handles empty rows array', async () => {
94
+ await wrapper.setProps({ rows: [] });
95
+ const rows = wrapper.findAll('.unnnic-chart-funnel-base-rows__row');
96
+ expect(rows).toHaveLength(0);
97
+ });
98
+
99
+ test('handles missing viewBox prop', async () => {
100
+ const wrapperWithoutViewBox = mount(ChartFunnelBaseRow, {
101
+ props: {
102
+ rows: mockRows,
103
+ },
104
+ });
105
+ const svg = wrapperWithoutViewBox.find('svg');
106
+ expect(svg.exists()).toBe(true);
107
+ expect(svg.attributes('viewbox')).toBeFalsy();
108
+ });
109
+
110
+ test('handles rows with missing properties', async () => {
111
+ const incompleteRows = [
112
+ {
113
+ title: '100%',
114
+ pathD: 'M0 0 L100 0 L80 50 L20 50 Z',
115
+ titleY: '20',
116
+ },
117
+ ];
118
+
119
+ await wrapper.setProps({ rows: incompleteRows });
120
+ const row = wrapper.find('.unnnic-chart-funnel-base-rows__row');
121
+ const title = row.find('.row__title');
122
+ const description = row.find('.row__description');
123
+ const path = row.find('.row__path');
124
+
125
+ expect(title.text()).toBe('100%');
126
+ expect(description.text()).toBe('');
127
+ expect(path.attributes('d')).toBe(incompleteRows[0].pathD);
128
+ });
129
+
130
+ test('matches snapshot', () => {
131
+ expect(wrapper.html()).toMatchSnapshot();
132
+ });
133
+
134
+ test('verifies SVG namespace', () => {
135
+ const svg = wrapper.find('svg');
136
+ expect(svg.attributes('xmlns')).toBe('http://www.w3.org/2000/svg');
137
+ expect(svg.attributes('fill')).toBe('none');
138
+ });
139
+
140
+ test('maintains component class name', () => {
141
+ const svg = wrapper.find('svg');
142
+ expect(svg.classes()).toContain('unnnic-chart-funnel-base-rows');
143
+ });
144
+
145
+ test('preserves row order', () => {
146
+ const rows = wrapper.findAll('.unnnic-chart-funnel-base-rows__row');
147
+ rows.forEach((row, index) => {
148
+ const title = row.find('.row__title');
149
+ expect(title.text()).toBe(mockRows[index].title);
150
+ });
151
+ });
152
+
153
+ describe('edge cases', () => {
154
+ test('handles rows with special characters in text', async () => {
155
+ const rowsWithSpecialChars = [
156
+ {
157
+ title: '100% & <special>',
158
+ description: 'Test & <special>',
159
+ pathD: 'M0 0 L100 0 L80 50 L20 50 Z',
160
+ titleY: '20',
161
+ descriptionY: '35',
162
+ },
163
+ ];
164
+
165
+ await wrapper.setProps({ rows: rowsWithSpecialChars });
166
+ const title = wrapper.find('.row__title');
167
+ const description = wrapper.find('.row__description');
168
+
169
+ expect(title.text()).toBe('100% & <special>');
170
+ expect(description.text()).toBe('Test & <special>');
171
+ });
172
+
173
+ test('handles very long text content', async () => {
174
+ const rowsWithLongText = [
175
+ {
176
+ title: 'A'.repeat(50),
177
+ description: 'B'.repeat(100),
178
+ pathD: 'M0 0 L100 0 L80 50 L20 50 Z',
179
+ titleY: '20',
180
+ descriptionY: '35',
181
+ },
182
+ ];
183
+
184
+ await wrapper.setProps({ rows: rowsWithLongText });
185
+ const title = wrapper.find('.row__title');
186
+ const description = wrapper.find('.row__description');
187
+
188
+ expect(title.text()).toBe('A'.repeat(50));
189
+ expect(description.text()).toBe('B'.repeat(100));
190
+ });
191
+ });
192
+ });
@@ -0,0 +1,126 @@
1
+ import { mount } from '@vue/test-utils';
2
+ import { beforeEach, describe, expect, afterEach, test, vi } from 'vitest';
3
+ import ChartFunnelFiveRows from '@/components/ChartFunnel/SvgFunnel/ChartFunnelFiveRows.vue';
4
+
5
+ describe('ChartFunnelFiveRows.vue', () => {
6
+ let wrapper;
7
+ const mockData = [
8
+ { title: 'Row 1', description: 'Description 1' },
9
+ { title: 'Row 2', description: 'Description 2' },
10
+ { title: 'Row 3', description: 'Description 3' },
11
+ { title: 'Row 4', description: 'Description 4' },
12
+ { title: 'Row 5', description: 'Description 5' },
13
+ ];
14
+
15
+ beforeEach(() => {
16
+ wrapper = mount(ChartFunnelFiveRows, {
17
+ props: {
18
+ data: mockData,
19
+ },
20
+ global: {
21
+ stubs: {
22
+ ChartFunnelBaseRow: {
23
+ template: '<div class="chart-funnel-base-row" />',
24
+ props: ['rows', 'viewBox'],
25
+ },
26
+ },
27
+ },
28
+ });
29
+ });
30
+
31
+ afterEach(() => {
32
+ wrapper.unmount();
33
+ });
34
+
35
+ test('renders correctly', () => {
36
+ expect(wrapper.exists()).toBe(true);
37
+ expect(wrapper.classes()).toContain('unnnic-chart-funnel-five-rows');
38
+ });
39
+
40
+ test('renders ChartFunnelBaseRow component with correct props', () => {
41
+ const baseRow = wrapper.findComponent('.unnnic-chart-funnel-five-rows');
42
+
43
+ expect(baseRow.exists()).toBe(true);
44
+ expect(baseRow.props('viewBox')).toBe('0 0 361 220');
45
+ });
46
+
47
+ test('computes rows correctly with provided data', () => {
48
+ const computedRows = wrapper.vm.rows;
49
+
50
+ expect(computedRows).toHaveLength(5);
51
+
52
+ expect(computedRows[0]).toEqual({
53
+ pathD:
54
+ 'M352.506 0H8.42251C1.93921 0 -1.85142 7.30766 1.88266 12.6076L24 44H336.75L359.028 12.6324C362.79 7.33528 359.003 0 352.506 0Z',
55
+ titleX: '50%',
56
+ titleY: '20',
57
+ descriptionX: '50%',
58
+ descriptionY: '38',
59
+ title: mockData[0].title,
60
+ description: mockData[0].description,
61
+ });
62
+
63
+ expect(computedRows[2]).toEqual({
64
+ pathD: 'M304.5 88H56.5L88.9564 132H273.708L304.5 88Z',
65
+ titleX: '50%',
66
+ titleY: '106',
67
+ descriptionX: '50%',
68
+ descriptionY: '124',
69
+ title: mockData[2].title,
70
+ description: mockData[2].description,
71
+ });
72
+
73
+ expect(computedRows[4]).toEqual({
74
+ pathD:
75
+ 'M242 176H120.957L130.481 213.947C131.374 217.505 134.573 220 138.241 220H223.89C227.498 220 230.659 217.585 231.608 214.105L242 176Z',
76
+ titleX: '50%',
77
+ titleY: '194',
78
+ descriptionX: '50%',
79
+ descriptionY: '212',
80
+ title: mockData[4].title,
81
+ description: mockData[4].description,
82
+ });
83
+ });
84
+
85
+ test('updates rows when data prop changes', async () => {
86
+ const newData = [
87
+ { title: 'New 1', description: 'New Desc 1' },
88
+ { title: 'New 2', description: 'New Desc 2' },
89
+ { title: 'New 3', description: 'New Desc 3' },
90
+ { title: 'New 4', description: 'New Desc 4' },
91
+ { title: 'New 5', description: 'New Desc 5' },
92
+ ];
93
+
94
+ await wrapper.setProps({ data: newData });
95
+ const computedRows = wrapper.vm.rows;
96
+
97
+ expect(computedRows[0].title).toBe('New 1');
98
+ expect(computedRows[0].description).toBe('New Desc 1');
99
+ expect(computedRows[4].title).toBe('New 5');
100
+ expect(computedRows[4].description).toBe('New Desc 5');
101
+ });
102
+
103
+ test('matches snapshot', () => {
104
+ expect(wrapper.html()).toMatchSnapshot();
105
+ });
106
+
107
+ test('passes correct viewBox to ChartFunnelBaseRow', () => {
108
+ const baseRow = wrapper.findComponent('.unnnic-chart-funnel-five-rows');
109
+ expect(baseRow.props('viewBox')).toBe('0 0 361 220');
110
+ });
111
+
112
+ test('correctly formats all row paths', () => {
113
+ const computedRows = wrapper.vm.rows;
114
+ const expectedPaths = [
115
+ 'M352.506 0H8.42251C1.93921 0 -1.85142 7.30766 1.88266 12.6076L24 44H336.75L359.028 12.6324C362.79 7.33528 359.003 0 352.506 0Z',
116
+ 'M337 44H24L56.4654 88H304.535L337 44Z',
117
+ 'M304.5 88H56.5L88.9564 132H273.708L304.5 88Z',
118
+ 'M274 132H89L121 176H242L274 132Z',
119
+ 'M242 176H120.957L130.481 213.947C131.374 217.505 134.573 220 138.241 220H223.89C227.498 220 230.659 217.585 231.608 214.105L242 176Z',
120
+ ];
121
+
122
+ computedRows.forEach((row, index) => {
123
+ expect(row.pathD).toBe(expectedPaths[index]);
124
+ });
125
+ });
126
+ });
@@ -0,0 +1,122 @@
1
+ import { mount } from '@vue/test-utils';
2
+ import { beforeEach, describe, expect, afterEach, test } from 'vitest';
3
+ import ChartFunnelFiveRows from '@/components/ChartFunnel/SvgFunnel/ChartFunnelFourRows.vue';
4
+
5
+ describe('ChartFunnelFourRows.vue', () => {
6
+ let wrapper;
7
+ const mockData = [
8
+ { title: 'Row 1', description: 'Description 1' },
9
+ { title: 'Row 2', description: 'Description 2' },
10
+ { title: 'Row 3', description: 'Description 3' },
11
+ { title: 'Row 4', description: 'Description 4' },
12
+ ];
13
+
14
+ beforeEach(() => {
15
+ wrapper = mount(ChartFunnelFiveRows, {
16
+ props: {
17
+ data: mockData,
18
+ },
19
+ global: {
20
+ stubs: {
21
+ ChartFunnelBaseRow: {
22
+ template: '<div class="chart-funnel-base-row" />',
23
+ props: ['rows', 'viewBox'],
24
+ },
25
+ },
26
+ },
27
+ });
28
+ });
29
+
30
+ afterEach(() => {
31
+ wrapper.unmount();
32
+ });
33
+
34
+ test('renders correctly', () => {
35
+ expect(wrapper.exists()).toBe(true);
36
+ expect(wrapper.classes()).toContain('unnnic-chart-funnel-four-rows');
37
+ });
38
+
39
+ test('renders ChartFunnelBaseRow component with correct props', () => {
40
+ const baseRow = wrapper.findComponent('.unnnic-chart-funnel-four-rows');
41
+
42
+ expect(baseRow.exists()).toBe(true);
43
+ expect(baseRow.props('viewBox')).toBe('0 0 365 224');
44
+ });
45
+
46
+ test('computes rows correctly with provided data', () => {
47
+ const computedRows = wrapper.vm.rows;
48
+
49
+ expect(computedRows).toHaveLength(4);
50
+
51
+ expect(computedRows[0]).toEqual({
52
+ pathD:
53
+ 'M356.374 0H8.57255C2.47804 0 -1.37827 6.54249 1.5734 11.8745L26 56H338.75L363.36 11.8984C366.336 6.56589 362.481 0 356.374 0Z',
54
+ titleX: '50%',
55
+ titleY: '23',
56
+ descriptionX: '50%',
57
+ descriptionY: '43',
58
+ title: mockData[0].title,
59
+ description: mockData[0].description,
60
+ });
61
+
62
+ expect(computedRows[1]).toEqual({
63
+ pathD: 'M339 56H26L58.4654 112H306.535L339 56Z',
64
+ titleX: '50%',
65
+ titleY: '78',
66
+ descriptionX: '50%',
67
+ descriptionY: '98',
68
+ title: mockData[1].title,
69
+ description: mockData[1].description,
70
+ });
71
+
72
+ expect(computedRows[2]).toEqual({
73
+ pathD: 'M306.5 112H58.5L90.9564 168H275.708L306.5 112Z',
74
+ titleX: '50%',
75
+ titleY: '136',
76
+ descriptionX: '50%',
77
+ descriptionY: '156',
78
+ title: mockData[2].title,
79
+ description: mockData[2].description,
80
+ });
81
+ });
82
+
83
+ test('updates rows when data prop changes', async () => {
84
+ const newData = [
85
+ { title: 'New 1', description: 'New Desc 1' },
86
+ { title: 'New 2', description: 'New Desc 2' },
87
+ { title: 'New 3', description: 'New Desc 3' },
88
+ { title: 'New 4', description: 'New Desc 4' },
89
+ ];
90
+
91
+ await wrapper.setProps({ data: newData });
92
+ const computedRows = wrapper.vm.rows;
93
+
94
+ expect(computedRows[0].title).toBe('New 1');
95
+ expect(computedRows[0].description).toBe('New Desc 1');
96
+ expect(computedRows[3].title).toBe('New 4');
97
+ expect(computedRows[3].description).toBe('New Desc 4');
98
+ });
99
+
100
+ test('matches snapshot', () => {
101
+ expect(wrapper.html()).toMatchSnapshot();
102
+ });
103
+
104
+ test('passes correct viewBox to ChartFunnelBaseRow', () => {
105
+ const baseRow = wrapper.findComponent('.unnnic-chart-funnel-four-rows');
106
+ expect(baseRow.props('viewBox')).toBe('0 0 365 224');
107
+ });
108
+
109
+ test('correctly formats all row paths', () => {
110
+ const computedRows = wrapper.vm.rows;
111
+ const expectedPaths = [
112
+ 'M356.374 0H8.57255C2.47804 0 -1.37827 6.54249 1.5734 11.8745L26 56H338.75L363.36 11.8984C366.336 6.56589 362.481 0 356.374 0Z',
113
+ 'M339 56H26L58.4654 112H306.535L339 56Z',
114
+ 'M306.5 112H58.5L90.9564 168H275.708L306.5 112Z',
115
+ 'M276 168H91L120.697 219.969C122.121 222.462 124.772 224 127.643 224H239.357C242.228 224 244.879 222.462 246.303 219.969L276 168Z',
116
+ ];
117
+
118
+ computedRows.forEach((row, index) => {
119
+ expect(row.pathD).toBe(expectedPaths[index]);
120
+ });
121
+ });
122
+ });
@@ -0,0 +1,120 @@
1
+ import { mount } from '@vue/test-utils';
2
+ import { beforeEach, describe, expect, afterEach, test } from 'vitest';
3
+ import ChartFunnelFiveRows from '@/components/ChartFunnel/SvgFunnel/ChartFunnelThreeRows.vue';
4
+
5
+ describe('ChartFunnelThreeRows.vue', () => {
6
+ let wrapper;
7
+ const mockData = [
8
+ { title: 'Row 1', description: 'Description 1' },
9
+ { title: 'Row 2', description: 'Description 2' },
10
+ { title: 'Row 3', description: 'Description 3' },
11
+ ];
12
+
13
+ beforeEach(() => {
14
+ wrapper = mount(ChartFunnelFiveRows, {
15
+ props: {
16
+ data: mockData,
17
+ },
18
+ global: {
19
+ stubs: {
20
+ ChartFunnelBaseRow: {
21
+ template: '<div class="chart-funnel-base-row" />',
22
+ props: ['rows', 'viewBox'],
23
+ },
24
+ },
25
+ },
26
+ });
27
+ });
28
+
29
+ afterEach(() => {
30
+ wrapper.unmount();
31
+ });
32
+
33
+ test('renders correctly', () => {
34
+ expect(wrapper.exists()).toBe(true);
35
+ expect(wrapper.classes()).toContain('unnnic-chart-funnel-three-rows');
36
+ });
37
+
38
+ test('renders ChartFunnelBaseRow component with correct props', () => {
39
+ const baseRow = wrapper.findComponent('.unnnic-chart-funnel-three-rows');
40
+
41
+ expect(baseRow.exists()).toBe(true);
42
+ expect(baseRow.props('viewBox')).toBe('0 0 375 222');
43
+ });
44
+
45
+ test('computes rows correctly with provided data', () => {
46
+ const computedRows = wrapper.vm.rows;
47
+
48
+ expect(computedRows).toHaveLength(3);
49
+
50
+ expect(computedRows[0]).toEqual({
51
+ pathD:
52
+ 'M362.938 0H12.025C6.30976 0 2.43799 5.81972 4.64626 11.0911L31 74H343.75L370.307 11.1122C372.535 5.83818 368.663 0 362.938 0Z',
53
+ titleX: '50%',
54
+ titleY: '32',
55
+ descriptionX: '50%',
56
+ descriptionY: '52',
57
+ title: mockData[0].title,
58
+ description: mockData[0].description,
59
+ });
60
+
61
+ expect(computedRows[1]).toEqual({
62
+ pathD: 'M344 74H31L63.4654 148H311.535L344 74Z',
63
+ titleX: '50%',
64
+ titleY: '106',
65
+ descriptionX: '50%',
66
+ descriptionY: '126',
67
+ title: mockData[1].title,
68
+ description: mockData[1].description,
69
+ });
70
+
71
+ expect(computedRows[2]).toEqual({
72
+ pathD:
73
+ 'M311.5 148H63.5L93.8569 217.213C95.1325 220.122 98.0075 222 101.183 222H275.372C278.603 222 281.517 220.056 282.758 217.073L311.5 148Z',
74
+ titleX: '50%',
75
+ titleY: '180',
76
+ descriptionX: '50%',
77
+ descriptionY: '200',
78
+ title: mockData[2].title,
79
+ description: mockData[2].description,
80
+ });
81
+ });
82
+
83
+ test('updates rows when data prop changes', async () => {
84
+ const newData = [
85
+ { title: 'New 1', description: 'New Desc 1' },
86
+ { title: 'New 2', description: 'New Desc 2' },
87
+ { title: 'New 3', description: 'New Desc 3' },
88
+ ];
89
+
90
+ await wrapper.setProps({ data: newData });
91
+ const computedRows = wrapper.vm.rows;
92
+
93
+ expect(computedRows[0].title).toBe('New 1');
94
+ expect(computedRows[0].description).toBe('New Desc 1');
95
+ expect(computedRows[2].title).toBe('New 3');
96
+ expect(computedRows[2].description).toBe('New Desc 3');
97
+ });
98
+
99
+ test('matches snapshot', () => {
100
+ expect(wrapper.html()).toMatchSnapshot();
101
+ });
102
+
103
+ test('passes correct viewBox to ChartFunnelBaseRow', () => {
104
+ const baseRow = wrapper.findComponent('.unnnic-chart-funnel-three-rows');
105
+ expect(baseRow.props('viewBox')).toBe('0 0 375 222');
106
+ });
107
+
108
+ test('correctly formats all row paths', () => {
109
+ const computedRows = wrapper.vm.rows;
110
+ const expectedPaths = [
111
+ 'M362.938 0H12.025C6.30976 0 2.43799 5.81972 4.64626 11.0911L31 74H343.75L370.307 11.1122C372.535 5.83818 368.663 0 362.938 0Z',
112
+ 'M344 74H31L63.4654 148H311.535L344 74Z',
113
+ 'M311.5 148H63.5L93.8569 217.213C95.1325 220.122 98.0075 222 101.183 222H275.372C278.603 222 281.517 220.056 282.758 217.073L311.5 148Z',
114
+ ];
115
+
116
+ computedRows.forEach((row, index) => {
117
+ expect(row.pathD).toBe(expectedPaths[index]);
118
+ });
119
+ });
120
+ });