@namuna-nur/ui-kit 1.0.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 (465) hide show
  1. package/README.md +338 -0
  2. package/lib/.gitkeep +0 -0
  3. package/lib/atoms/index.js +39 -0
  4. package/lib/hooks/index.js +8 -0
  5. package/lib/index.d.ts +2 -0
  6. package/lib/index.js +152 -0
  7. package/lib/molecules/index.js +101 -0
  8. package/lib/setupTests.d.ts +0 -0
  9. package/lib/shared/Avatar.tokens.js +7510 -0
  10. package/lib/shared/MessageSettings.tokens.js +8693 -0
  11. package/lib/shared/TabDots.tokens.js +1075 -0
  12. package/lib/shared/twMerge.js +3535 -0
  13. package/lib/shared/useClickOutside.js +16 -0
  14. package/lib/shared/useDebounce.js +15 -0
  15. package/lib/shared/useOption.js +8 -0
  16. package/lib/src/_shared/Accordion.utils.d.ts +15 -0
  17. package/lib/src/_shared/Dropdown.utils.d.ts +27 -0
  18. package/lib/src/_shared/Modal.utils.d.ts +16 -0
  19. package/lib/src/_shared/Popover.utils.d.ts +5 -0
  20. package/lib/src/_shared/Tab.utils.d.ts +6 -0
  21. package/lib/src/_shared/index.d.ts +5 -0
  22. package/lib/src/_shared/types.d.ts +7 -0
  23. package/lib/src/assets/icons/index.d.ts +151 -0
  24. package/lib/src/assets/images/index.d.ts +11 -0
  25. package/lib/src/atoms/Avatar/Avatar.d.ts +2 -0
  26. package/lib/src/atoms/Avatar/Avatar.stories.d.ts +9 -0
  27. package/lib/src/atoms/Avatar/Avatar.test.d.ts +1 -0
  28. package/lib/src/atoms/Avatar/Avatar.tokens.d.ts +8 -0
  29. package/lib/src/atoms/Avatar/Avatar.types.d.ts +24 -0
  30. package/lib/src/atoms/Avatar/index.d.ts +3 -0
  31. package/lib/src/atoms/Button/Button.d.ts +16 -0
  32. package/lib/src/atoms/Button/Button.stories.d.ts +8 -0
  33. package/lib/src/atoms/Button/Button.test.d.ts +1 -0
  34. package/lib/src/atoms/Button/Button.tokens.d.ts +52 -0
  35. package/lib/src/atoms/Button/Button.types.d.ts +23 -0
  36. package/lib/src/atoms/Button/index.d.ts +3 -0
  37. package/lib/src/atoms/Checkbox/Checkbox.d.ts +5 -0
  38. package/lib/src/atoms/Checkbox/Checkbox.stories.d.ts +8 -0
  39. package/lib/src/atoms/Checkbox/Checkbox.test.d.ts +1 -0
  40. package/lib/src/atoms/Checkbox/Checkbox.tokens.d.ts +18 -0
  41. package/lib/src/atoms/Checkbox/Checkbox.types.d.ts +7 -0
  42. package/lib/src/atoms/Checkbox/index.d.ts +3 -0
  43. package/lib/src/atoms/Headline/Headline.d.ts +3 -0
  44. package/lib/src/atoms/Headline/Headline.stories.d.ts +8 -0
  45. package/lib/src/atoms/Headline/Headline.test.d.ts +1 -0
  46. package/lib/src/atoms/Headline/Headline.types.d.ts +13 -0
  47. package/lib/src/atoms/Headline/index.d.ts +2 -0
  48. package/lib/src/atoms/IconButton/IconButton.d.ts +13 -0
  49. package/lib/src/atoms/IconButton/IconButton.stories.d.ts +9 -0
  50. package/lib/src/atoms/IconButton/IconButton.test.d.ts +1 -0
  51. package/lib/src/atoms/IconButton/IconButton.tokens.d.ts +47 -0
  52. package/lib/src/atoms/IconButton/IconButton.types.d.ts +24 -0
  53. package/lib/src/atoms/IconButton/index.d.ts +3 -0
  54. package/lib/src/atoms/Input/Input.d.ts +11 -0
  55. package/lib/src/atoms/Input/Input.stories.d.ts +12 -0
  56. package/lib/src/atoms/Input/Input.test.d.ts +1 -0
  57. package/lib/src/atoms/Input/Input.tokens.d.ts +21 -0
  58. package/lib/src/atoms/Input/Input.types.d.ts +27 -0
  59. package/lib/src/atoms/Input/index.d.ts +3 -0
  60. package/lib/src/atoms/Label/Label.d.ts +4 -0
  61. package/lib/src/atoms/Label/Label.stories.d.ts +6 -0
  62. package/lib/src/atoms/Label/Label.test.d.ts +1 -0
  63. package/lib/src/atoms/Label/Label.tokens.d.ts +2 -0
  64. package/lib/src/atoms/Label/Label.types.d.ts +11 -0
  65. package/lib/src/atoms/Label/index.d.ts +3 -0
  66. package/lib/src/atoms/Message/Message.d.ts +8 -0
  67. package/lib/src/atoms/Message/Message.stories.d.ts +10 -0
  68. package/lib/src/atoms/Message/Message.test.d.ts +1 -0
  69. package/lib/src/atoms/Message/Message.tokens.d.ts +2 -0
  70. package/lib/src/atoms/Message/Message.types.d.ts +38 -0
  71. package/lib/src/atoms/Message/index.d.ts +3 -0
  72. package/lib/src/atoms/Notification/Notification.d.ts +2 -0
  73. package/lib/src/atoms/Notification/Notification.data.d.ts +7 -0
  74. package/lib/src/atoms/Notification/Notification.stories.d.ts +9 -0
  75. package/lib/src/atoms/Notification/Notification.test.d.ts +1 -0
  76. package/lib/src/atoms/Notification/Notification.types.d.ts +8 -0
  77. package/lib/src/atoms/Notification/Notification.utils.d.ts +20 -0
  78. package/lib/src/atoms/Notification/index.d.ts +2 -0
  79. package/lib/src/atoms/Radio/Radio.d.ts +5 -0
  80. package/lib/src/atoms/Radio/Radio.stories.d.ts +7 -0
  81. package/lib/src/atoms/Radio/Radio.test.d.ts +1 -0
  82. package/lib/src/atoms/Radio/Radio.tokens.d.ts +20 -0
  83. package/lib/src/atoms/Radio/Radio.types.d.ts +10 -0
  84. package/lib/src/atoms/Radio/index.d.ts +3 -0
  85. package/lib/src/atoms/Select/Select.d.ts +2 -0
  86. package/lib/src/atoms/Select/Select.stories.d.ts +13 -0
  87. package/lib/src/atoms/Select/Select.test.d.ts +1 -0
  88. package/lib/src/atoms/Select/Select.tokens.d.ts +43 -0
  89. package/lib/src/atoms/Select/Select.types.d.ts +30 -0
  90. package/lib/src/atoms/Select/index.d.ts +3 -0
  91. package/lib/src/atoms/Status/Status.d.ts +2 -0
  92. package/lib/src/atoms/Status/Status.stories.d.ts +9 -0
  93. package/lib/src/atoms/Status/Status.test.d.ts +1 -0
  94. package/lib/src/atoms/Status/Status.tokens.d.ts +10 -0
  95. package/lib/src/atoms/Status/Status.types.d.ts +8 -0
  96. package/lib/src/atoms/Status/index.d.ts +3 -0
  97. package/lib/src/atoms/Switch/Switch.d.ts +8 -0
  98. package/lib/src/atoms/Switch/Switch.stories.d.ts +6 -0
  99. package/lib/src/atoms/Switch/Switch.test.d.ts +1 -0
  100. package/lib/src/atoms/Switch/Switch.tokens.d.ts +2 -0
  101. package/lib/src/atoms/Switch/Switch.types.d.ts +19 -0
  102. package/lib/src/atoms/Switch/index.d.ts +3 -0
  103. package/lib/src/atoms/Tab/Tab.d.ts +10 -0
  104. package/lib/src/atoms/Tab/Tab.stories.d.ts +14 -0
  105. package/lib/src/atoms/Tab/Tab.test.d.ts +1 -0
  106. package/lib/src/atoms/Tab/Tab.tokens.d.ts +31 -0
  107. package/lib/src/atoms/Tab/Tab.types.d.ts +14 -0
  108. package/lib/src/atoms/Tab/index.d.ts +3 -0
  109. package/lib/src/atoms/TabDots/TabDots.d.ts +2 -0
  110. package/lib/src/atoms/TabDots/TabDots.stories.d.ts +5 -0
  111. package/lib/src/atoms/TabDots/TabDots.test.d.ts +1 -0
  112. package/lib/src/atoms/TabDots/TabDots.tokens.d.ts +5 -0
  113. package/lib/src/atoms/TabDots/TabDots.types.d.ts +12 -0
  114. package/lib/src/atoms/TabDots/index.d.ts +3 -0
  115. package/lib/src/atoms/Text/Text.d.ts +2 -0
  116. package/lib/src/atoms/Text/Text.stories.d.ts +10 -0
  117. package/lib/src/atoms/Text/Text.test.d.ts +1 -0
  118. package/lib/src/atoms/Text/Text.types.d.ts +14 -0
  119. package/lib/src/atoms/Text/index.d.ts +2 -0
  120. package/lib/src/atoms/Textarea/Teaxtarea.test.d.ts +1 -0
  121. package/lib/src/atoms/Textarea/Textarea.d.ts +5 -0
  122. package/lib/src/atoms/Textarea/Textarea.stories.d.ts +12 -0
  123. package/lib/src/atoms/Textarea/Textarea.tokens.d.ts +2 -0
  124. package/lib/src/atoms/Textarea/Textarea.types.d.ts +24 -0
  125. package/lib/src/atoms/Textarea/index.d.ts +3 -0
  126. package/lib/src/atoms/Toggle/Toggle.d.ts +11 -0
  127. package/lib/src/atoms/Toggle/Toggle.stories.d.ts +10 -0
  128. package/lib/src/atoms/Toggle/Toggle.test.d.ts +1 -0
  129. package/lib/src/atoms/Toggle/Toggle.tokens.d.ts +2 -0
  130. package/lib/src/atoms/Toggle/Toggle.types.d.ts +15 -0
  131. package/lib/src/atoms/Toggle/index.d.ts +3 -0
  132. package/lib/src/atoms/Tooltip/Tooltip.d.ts +2 -0
  133. package/lib/src/atoms/Tooltip/Tooltip.stories.d.ts +9 -0
  134. package/lib/src/atoms/Tooltip/Tooltip.test.d.ts +1 -0
  135. package/lib/src/atoms/Tooltip/Tooltip.tokens.d.ts +4 -0
  136. package/lib/src/atoms/Tooltip/Tooltip.types.d.ts +8 -0
  137. package/lib/src/atoms/Tooltip/index.d.ts +3 -0
  138. package/lib/src/atoms/index.d.ts +19 -0
  139. package/lib/src/context/use-toast.context.d.ts +10 -0
  140. package/lib/src/hooks/index.d.ts +3 -0
  141. package/lib/src/hooks/use-toast.d.ts +11 -0
  142. package/lib/src/hooks/use-toast.types.d.ts +32 -0
  143. package/lib/src/hooks/useClickOutside.d.ts +2 -0
  144. package/lib/src/hooks/useDebounce.d.ts +1 -0
  145. package/lib/src/hooks/useOption.d.ts +6 -0
  146. package/lib/src/index.d.ts +5 -0
  147. package/lib/src/molecules/Accordion/Accordion.d.ts +2 -0
  148. package/lib/src/molecules/Accordion/Accordion.stories.d.ts +7 -0
  149. package/lib/src/molecules/Accordion/Accordion.test.d.ts +1 -0
  150. package/lib/src/molecules/Accordion/Accordion.tokens.d.ts +19 -0
  151. package/lib/src/molecules/Accordion/Accordion.types.d.ts +27 -0
  152. package/lib/src/molecules/Accordion/index.d.ts +3 -0
  153. package/lib/src/molecules/ApartmentCard/ApartmentCard.d.ts +2 -0
  154. package/lib/src/molecules/ApartmentCard/ApartmentCard.data.d.ts +2 -0
  155. package/lib/src/molecules/ApartmentCard/ApartmentCard.stories.d.ts +5 -0
  156. package/lib/src/molecules/ApartmentCard/ApartmentCard.test.d.ts +1 -0
  157. package/lib/src/molecules/ApartmentCard/ApartmentCard.tokens.d.ts +12 -0
  158. package/lib/src/molecules/ApartmentCard/ApartmentCard.types.d.ts +26 -0
  159. package/lib/src/molecules/ApartmentCard/index.d.ts +3 -0
  160. package/lib/src/molecules/AvatarGroup/AvatarGroup.d.ts +2 -0
  161. package/lib/src/molecules/AvatarGroup/AvatarGroup.stories.d.ts +9 -0
  162. package/lib/src/molecules/AvatarGroup/AvatarGroup.test.d.ts +1 -0
  163. package/lib/src/molecules/AvatarGroup/AvatarGroup.tokens.d.ts +6 -0
  164. package/lib/src/molecules/AvatarGroup/AvatarGroup.types.d.ts +22 -0
  165. package/lib/src/molecules/AvatarGroup/index.d.ts +3 -0
  166. package/lib/src/molecules/Breadcrumb/Breadcrumb.d.ts +4 -0
  167. package/lib/src/molecules/Breadcrumb/Breadcrumb.stories.d.ts +8 -0
  168. package/lib/src/molecules/Breadcrumb/Breadcrumb.test.d.ts +1 -0
  169. package/lib/src/molecules/Breadcrumb/Breadcrumb.tokens.d.ts +7 -0
  170. package/lib/src/molecules/Breadcrumb/Breadcrumb.types.d.ts +16 -0
  171. package/lib/src/molecules/Breadcrumb/Breadcrumb.utils.d.ts +11 -0
  172. package/lib/src/molecules/Breadcrumb/index.d.ts +3 -0
  173. package/lib/src/molecules/CardFiles/CardFiles.d.ts +2 -0
  174. package/lib/src/molecules/CardFiles/CardFiles.stories.d.ts +7 -0
  175. package/lib/src/molecules/CardFiles/CardFiles.test.d.ts +1 -0
  176. package/lib/src/molecules/CardFiles/CardFiles.tokens.d.ts +28 -0
  177. package/lib/src/molecules/CardFiles/CardFiles.types.d.ts +40 -0
  178. package/lib/src/molecules/CardFiles/index.d.ts +3 -0
  179. package/lib/src/molecules/CardServices/CardServices.d.ts +5 -0
  180. package/lib/src/molecules/CardServices/CardServices.stories.d.ts +6 -0
  181. package/lib/src/molecules/CardServices/CardServices.test.d.ts +1 -0
  182. package/lib/src/molecules/CardServices/CardServices.tokens.d.ts +17 -0
  183. package/lib/src/molecules/CardServices/CardServices.types.d.ts +18 -0
  184. package/lib/src/molecules/CardServices/index.d.ts +3 -0
  185. package/lib/src/molecules/ChatButton/ChatButton.d.ts +2 -0
  186. package/lib/src/molecules/ChatButton/ChatButton.stories.d.ts +6 -0
  187. package/lib/src/molecules/ChatButton/ChatButton.test.d.ts +1 -0
  188. package/lib/src/molecules/ChatButton/ChatButton.tokens.d.ts +12 -0
  189. package/lib/src/molecules/ChatButton/ChatButton.types.d.ts +18 -0
  190. package/lib/src/molecules/ChatButton/index.d.ts +3 -0
  191. package/lib/src/molecules/ChatCard/ChatCard.d.ts +3 -0
  192. package/lib/src/molecules/ChatCard/ChatCard.stories.d.ts +8 -0
  193. package/lib/src/molecules/ChatCard/ChatCard.test.d.ts +1 -0
  194. package/lib/src/molecules/ChatCard/ChatCard.tokens.d.ts +9 -0
  195. package/lib/src/molecules/ChatCard/ChatCard.types.d.ts +18 -0
  196. package/lib/src/molecules/ChatCard/index.d.ts +3 -0
  197. package/lib/src/molecules/ChatList/ChatList.d.ts +3 -0
  198. package/lib/src/molecules/ChatList/ChatList.stories.d.ts +5 -0
  199. package/lib/src/molecules/ChatList/ChatList.test.d.ts +1 -0
  200. package/lib/src/molecules/ChatList/ChatList.tokens.d.ts +4 -0
  201. package/lib/src/molecules/ChatList/ChatList.types.d.ts +14 -0
  202. package/lib/src/molecules/ChatList/index.d.ts +3 -0
  203. package/lib/src/molecules/ChatMessage/ChatMessage.d.ts +2 -0
  204. package/lib/src/molecules/ChatMessage/ChatMessage.data.d.ts +3 -0
  205. package/lib/src/molecules/ChatMessage/ChatMessage.stories.d.ts +9 -0
  206. package/lib/src/molecules/ChatMessage/ChatMessage.test.d.ts +1 -0
  207. package/lib/src/molecules/ChatMessage/ChatMessage.tokens.d.ts +6 -0
  208. package/lib/src/molecules/ChatMessage/ChatMessage.types.d.ts +19 -0
  209. package/lib/src/molecules/ChatMessage/index.d.ts +3 -0
  210. package/lib/src/molecules/ChatSidebar/ChatSidebar.d.ts +2 -0
  211. package/lib/src/molecules/ChatSidebar/ChatSidebar.data.d.ts +4 -0
  212. package/lib/src/molecules/ChatSidebar/ChatSidebar.stories.d.ts +36 -0
  213. package/lib/src/molecules/ChatSidebar/ChatSidebar.test.d.ts +1 -0
  214. package/lib/src/molecules/ChatSidebar/ChatSidebar.tokens.d.ts +7 -0
  215. package/lib/src/molecules/ChatSidebar/ChatSidebar.types.d.ts +35 -0
  216. package/lib/src/molecules/ChatSidebar/index.d.ts +3 -0
  217. package/lib/src/molecules/CheckboxGroup/CheckboxGroup.d.ts +2 -0
  218. package/lib/src/molecules/CheckboxGroup/CheckboxGroup.stories.d.ts +8 -0
  219. package/lib/src/molecules/CheckboxGroup/CheckboxGroup.test.d.ts +1 -0
  220. package/lib/src/molecules/CheckboxGroup/CheckboxGroup.tokens.d.ts +16 -0
  221. package/lib/src/molecules/CheckboxGroup/CheckboxGroup.types.d.ts +8 -0
  222. package/lib/src/molecules/CheckboxGroup/index.d.ts +3 -0
  223. package/lib/src/molecules/CommentInput/CommentInput.d.ts +3 -0
  224. package/lib/src/molecules/CommentInput/CommentInput.stories.d.ts +8 -0
  225. package/lib/src/molecules/CommentInput/CommentInput.test.d.ts +1 -0
  226. package/lib/src/molecules/CommentInput/CommentInput.tokens.d.ts +9 -0
  227. package/lib/src/molecules/CommentInput/CommentInput.types.d.ts +29 -0
  228. package/lib/src/molecules/CommentInput/index.d.ts +3 -0
  229. package/lib/src/molecules/CommentList/CommentList.d.ts +3 -0
  230. package/lib/src/molecules/CommentList/CommentList.stories.d.ts +7 -0
  231. package/lib/src/molecules/CommentList/CommentList.test.d.ts +1 -0
  232. package/lib/src/molecules/CommentList/CommentList.tokens.d.ts +35 -0
  233. package/lib/src/molecules/CommentList/CommentList.types.d.ts +21 -0
  234. package/lib/src/molecules/CommentList/index.d.ts +3 -0
  235. package/lib/src/molecules/DateOfBirth/DateOfBirth.d.ts +2 -0
  236. package/lib/src/molecules/DateOfBirth/DateOfBirth.stories.d.ts +10 -0
  237. package/lib/src/molecules/DateOfBirth/DateOfBirth.test.d.ts +1 -0
  238. package/lib/src/molecules/DateOfBirth/DateOfBirth.tokens.d.ts +6 -0
  239. package/lib/src/molecules/DateOfBirth/DateOfBirth.types.d.ts +13 -0
  240. package/lib/src/molecules/DateOfBirth/index.d.ts +3 -0
  241. package/lib/src/molecules/DatePicker/DatePicker.d.ts +2 -0
  242. package/lib/src/molecules/DatePicker/DatePicker.stories.d.ts +8 -0
  243. package/lib/src/molecules/DatePicker/DatePicker.test.d.ts +1 -0
  244. package/lib/src/molecules/DatePicker/DatePicker.tokens.d.ts +57 -0
  245. package/lib/src/molecules/DatePicker/DatePicker.types.d.ts +18 -0
  246. package/lib/src/molecules/DatePicker/index.d.ts +3 -0
  247. package/lib/src/molecules/DeleteMessage/DeleteMessage.d.ts +2 -0
  248. package/lib/src/molecules/DeleteMessage/DeleteMessage.stories.d.ts +6 -0
  249. package/lib/src/molecules/DeleteMessage/DeleteMessage.test.d.ts +1 -0
  250. package/lib/src/molecules/DeleteMessage/DeleteMessage.tokens.d.ts +9 -0
  251. package/lib/src/molecules/DeleteMessage/DeleteMessage.types.d.ts +13 -0
  252. package/lib/src/molecules/DeleteMessage/index.d.ts +3 -0
  253. package/lib/src/molecules/DragAndDrop/DragAndDrop.d.ts +2 -0
  254. package/lib/src/molecules/DragAndDrop/DragAndDrop.stories.d.ts +14 -0
  255. package/lib/src/molecules/DragAndDrop/DragAndDrop.test.d.ts +1 -0
  256. package/lib/src/molecules/DragAndDrop/DragAndDrop.tokens.d.ts +2 -0
  257. package/lib/src/molecules/DragAndDrop/DragAndDrop.types.d.ts +19 -0
  258. package/lib/src/molecules/DragAndDrop/index.d.ts +3 -0
  259. package/lib/src/molecules/Dropdown/Dropdown.d.ts +3 -0
  260. package/lib/src/molecules/Dropdown/Dropdown.stories.d.ts +6 -0
  261. package/lib/src/molecules/Dropdown/Dropdown.test.d.ts +1 -0
  262. package/lib/src/molecules/Dropdown/Dropdown.tokens.d.ts +13 -0
  263. package/lib/src/molecules/Dropdown/Dropdown.types.d.ts +20 -0
  264. package/lib/src/molecules/Dropdown/index.d.ts +3 -0
  265. package/lib/src/molecules/FileUploader/FileUploader.d.ts +2 -0
  266. package/lib/src/molecules/FileUploader/FileUploader.stories.d.ts +7 -0
  267. package/lib/src/molecules/FileUploader/FileUploader.test.d.ts +1 -0
  268. package/lib/src/molecules/FileUploader/FileUploader.tokens.d.ts +19 -0
  269. package/lib/src/molecules/FileUploader/FileUploader.types.d.ts +18 -0
  270. package/lib/src/molecules/FileUploader/index.d.ts +3 -0
  271. package/lib/src/molecules/FilterTable/FilterTable.d.ts +2 -0
  272. package/lib/src/molecules/FilterTable/FilterTable.stories.d.ts +8 -0
  273. package/lib/src/molecules/FilterTable/FilterTable.test.d.ts +1 -0
  274. package/lib/src/molecules/FilterTable/FilterTable.tokens.d.ts +19 -0
  275. package/lib/src/molecules/FilterTable/FilterTable.types.d.ts +35 -0
  276. package/lib/src/molecules/FilterTable/index.d.ts +3 -0
  277. package/lib/src/molecules/IconTitle/IconTitle.d.ts +2 -0
  278. package/lib/src/molecules/IconTitle/IconTitle.stories.d.ts +6 -0
  279. package/lib/src/molecules/IconTitle/IconTitle.test.d.ts +1 -0
  280. package/lib/src/molecules/IconTitle/IconTitle.tokens.d.ts +5 -0
  281. package/lib/src/molecules/IconTitle/IconTitle.types.d.ts +20 -0
  282. package/lib/src/molecules/IconTitle/index.d.ts +3 -0
  283. package/lib/src/molecules/InputGroup/InputGroup.d.ts +2 -0
  284. package/lib/src/molecules/InputGroup/InputGroup.stories.d.ts +11 -0
  285. package/lib/src/molecules/InputGroup/InputGroup.test.d.ts +1 -0
  286. package/lib/src/molecules/InputGroup/InputGroup.tokens.d.ts +34 -0
  287. package/lib/src/molecules/InputGroup/InputGroup.types.d.ts +34 -0
  288. package/lib/src/molecules/InputGroup/index.d.ts +3 -0
  289. package/lib/src/molecules/LabelWithValue/LabelWithValue.d.ts +2 -0
  290. package/lib/src/molecules/LabelWithValue/LabelWithValue.stories.d.ts +5 -0
  291. package/lib/src/molecules/LabelWithValue/LabelWithValue.test.d.ts +1 -0
  292. package/lib/src/molecules/LabelWithValue/LabelWithValue.tokens.d.ts +4 -0
  293. package/lib/src/molecules/LabelWithValue/LabelWithValue.types.d.ts +12 -0
  294. package/lib/src/molecules/LabelWithValue/index.d.ts +3 -0
  295. package/lib/src/molecules/Languages/Languages.d.ts +2 -0
  296. package/lib/src/molecules/Languages/Languages.stories.d.ts +5 -0
  297. package/lib/src/molecules/Languages/Languages.test.d.ts +1 -0
  298. package/lib/src/molecules/Languages/Languages.tokens.d.ts +4 -0
  299. package/lib/src/molecules/Languages/Languages.types.d.ts +23 -0
  300. package/lib/src/molecules/Languages/index.d.ts +3 -0
  301. package/lib/src/molecules/Link/Link.d.ts +2 -0
  302. package/lib/src/molecules/Link/Link.stories.d.ts +7 -0
  303. package/lib/src/molecules/Link/Link.test.d.ts +1 -0
  304. package/lib/src/molecules/Link/Link.tokens.d.ts +9 -0
  305. package/lib/src/molecules/Link/Link.types.d.ts +15 -0
  306. package/lib/src/molecules/Link/index.d.ts +3 -0
  307. package/lib/src/molecules/MessageSettings/MessageSettings.d.ts +2 -0
  308. package/lib/src/molecules/MessageSettings/MessageSettings.stories.d.ts +5 -0
  309. package/lib/src/molecules/MessageSettings/MessageSettings.test.d.ts +1 -0
  310. package/lib/src/molecules/MessageSettings/MessageSettings.tokens.d.ts +13 -0
  311. package/lib/src/molecules/MessageSettings/MessageSettings.types.d.ts +21 -0
  312. package/lib/src/molecules/MessageSettings/MessageSettings.utils.d.ts +2 -0
  313. package/lib/src/molecules/MessageSettings/index.d.ts +3 -0
  314. package/lib/src/molecules/MultiSelect/MultiSelect.d.ts +2 -0
  315. package/lib/src/molecules/MultiSelect/MultiSelect.stories.d.ts +7 -0
  316. package/lib/src/molecules/MultiSelect/MultiSelect.test.d.ts +1 -0
  317. package/lib/src/molecules/MultiSelect/MultiSelect.tokens.d.ts +2 -0
  318. package/lib/src/molecules/MultiSelect/MultiSelect.types.d.ts +60 -0
  319. package/lib/src/molecules/MultiSelect/index.d.ts +3 -0
  320. package/lib/src/molecules/NavButton/NavButton.d.ts +2 -0
  321. package/lib/src/molecules/NavButton/NavButton.stories.d.ts +9 -0
  322. package/lib/src/molecules/NavButton/NavButton.test.d.ts +1 -0
  323. package/lib/src/molecules/NavButton/NavButton.tokens.d.ts +15 -0
  324. package/lib/src/molecules/NavButton/NavButton.types.d.ts +26 -0
  325. package/lib/src/molecules/NavButton/index.d.ts +3 -0
  326. package/lib/src/molecules/Pagination/Pagination.d.ts +2 -0
  327. package/lib/src/molecules/Pagination/Pagination.stories.d.ts +7 -0
  328. package/lib/src/molecules/Pagination/Pagination.test.d.ts +1 -0
  329. package/lib/src/molecules/Pagination/Pagination.tokens.d.ts +28 -0
  330. package/lib/src/molecules/Pagination/Pagination.types.d.ts +16 -0
  331. package/lib/src/molecules/Pagination/Pagination.utils.d.ts +1 -0
  332. package/lib/src/molecules/Pagination/index.d.ts +3 -0
  333. package/lib/src/molecules/PasswordInput/PasswordInput.d.ts +2 -0
  334. package/lib/src/molecules/PasswordInput/PasswordInput.stories.d.ts +12 -0
  335. package/lib/src/molecules/PasswordInput/PasswordInput.test.d.ts +1 -0
  336. package/lib/src/molecules/PasswordInput/PasswordInput.tokens.d.ts +2 -0
  337. package/lib/src/molecules/PasswordInput/PasswordInput.types.d.ts +19 -0
  338. package/lib/src/molecules/PasswordInput/index.d.ts +3 -0
  339. package/lib/src/molecules/PaymentCard/PaymentCard.d.ts +2 -0
  340. package/lib/src/molecules/PaymentCard/PaymentCard.stories.d.ts +5 -0
  341. package/lib/src/molecules/PaymentCard/PaymentCard.test.d.ts +1 -0
  342. package/lib/src/molecules/PaymentCard/PaymentCard.tokens.d.ts +20 -0
  343. package/lib/src/molecules/PaymentCard/PaymentCard.types.d.ts +19 -0
  344. package/lib/src/molecules/PaymentCard/index.d.ts +3 -0
  345. package/lib/src/molecules/PhoneInput/PhoneInput.d.ts +2 -0
  346. package/lib/src/molecules/PhoneInput/PhoneInput.stories.d.ts +10 -0
  347. package/lib/src/molecules/PhoneInput/PhoneInput.test.d.ts +1 -0
  348. package/lib/src/molecules/PhoneInput/PhoneInput.tokens.d.ts +2 -0
  349. package/lib/src/molecules/PhoneInput/PhoneInput.types.d.ts +27 -0
  350. package/lib/src/molecules/PhoneInput/index.d.ts +3 -0
  351. package/lib/src/molecules/Plate/Plate.d.ts +4 -0
  352. package/lib/src/molecules/Plate/Plate.stories.d.ts +7 -0
  353. package/lib/src/molecules/Plate/Plate.test.d.ts +1 -0
  354. package/lib/src/molecules/Plate/Plate.tokens.d.ts +2 -0
  355. package/lib/src/molecules/Plate/Plate.types.d.ts +36 -0
  356. package/lib/src/molecules/Plate/index.d.ts +3 -0
  357. package/lib/src/molecules/RadioGroup/RadioGroup.d.ts +11 -0
  358. package/lib/src/molecules/RadioGroup/RadioGroup.stories.d.ts +7 -0
  359. package/lib/src/molecules/RadioGroup/RadioGroup.test.d.ts +1 -0
  360. package/lib/src/molecules/RadioGroup/RadioGroup.tokens.d.ts +13 -0
  361. package/lib/src/molecules/RadioGroup/RadioGroup.types.d.ts +14 -0
  362. package/lib/src/molecules/RadioGroup/index.d.ts +3 -0
  363. package/lib/src/molecules/SearchInput/SearchInput.d.ts +22 -0
  364. package/lib/src/molecules/SearchInput/SearchInput.stories.d.ts +7 -0
  365. package/lib/src/molecules/SearchInput/SearchInput.test.d.ts +1 -0
  366. package/lib/src/molecules/SearchInput/SearchInput.tokens.d.ts +42 -0
  367. package/lib/src/molecules/SearchInput/SearchInput.types.d.ts +38 -0
  368. package/lib/src/molecules/SearchInput/index.d.ts +3 -0
  369. package/lib/src/molecules/SelectGroup/SelectGroup.d.ts +2 -0
  370. package/lib/src/molecules/SelectGroup/SelectGroup.stories.d.ts +6 -0
  371. package/lib/src/molecules/SelectGroup/SelectGroup.test.d.ts +1 -0
  372. package/lib/src/molecules/SelectGroup/SelectGroup.tokens.d.ts +3 -0
  373. package/lib/src/molecules/SelectGroup/SelectGroup.types.d.ts +12 -0
  374. package/lib/src/molecules/SelectGroup/index.d.ts +3 -0
  375. package/lib/src/molecules/SelectList/SelectList.d.ts +2 -0
  376. package/lib/src/molecules/SelectList/SelectList.stories.d.ts +7 -0
  377. package/lib/src/molecules/SelectList/SelectList.test.d.ts +1 -0
  378. package/lib/src/molecules/SelectList/SelectList.tokens.d.ts +29 -0
  379. package/lib/src/molecules/SelectList/SelectList.types.d.ts +20 -0
  380. package/lib/src/molecules/SelectList/index.d.ts +3 -0
  381. package/lib/src/molecules/ServiceOrders/ServiceOrders.d.ts +2 -0
  382. package/lib/src/molecules/ServiceOrders/ServiceOrders.data.d.ts +2 -0
  383. package/lib/src/molecules/ServiceOrders/ServiceOrders.stories.d.ts +5 -0
  384. package/lib/src/molecules/ServiceOrders/ServiceOrders.test.d.ts +1 -0
  385. package/lib/src/molecules/ServiceOrders/ServiceOrders.tokens.d.ts +11 -0
  386. package/lib/src/molecules/ServiceOrders/ServiceOrders.types.d.ts +19 -0
  387. package/lib/src/molecules/ServiceOrders/index.d.ts +3 -0
  388. package/lib/src/molecules/Sidebar/Sidebar.d.ts +2 -0
  389. package/lib/src/molecules/Sidebar/Sidebar.data.d.ts +2 -0
  390. package/lib/src/molecules/Sidebar/Sidebar.stories.d.ts +7 -0
  391. package/lib/src/molecules/Sidebar/Sidebar.test.d.ts +1 -0
  392. package/lib/src/molecules/Sidebar/Sidebar.tokens.d.ts +12 -0
  393. package/lib/src/molecules/Sidebar/Sidebar.types.d.ts +20 -0
  394. package/lib/src/molecules/Sidebar/Sidebar.utils.d.ts +2 -0
  395. package/lib/src/molecules/Sidebar/index.d.ts +3 -0
  396. package/lib/src/molecules/StatusSelect/StatusSelect.d.ts +2 -0
  397. package/lib/src/molecules/StatusSelect/StatusSelect.stories.d.ts +5 -0
  398. package/lib/src/molecules/StatusSelect/StatusSelect.test.d.ts +1 -0
  399. package/lib/src/molecules/StatusSelect/StatusSelect.tokens.d.ts +28 -0
  400. package/lib/src/molecules/StatusSelect/StatusSelect.types.d.ts +25 -0
  401. package/lib/src/molecules/StatusSelect/index.d.ts +3 -0
  402. package/lib/src/molecules/Stepper/Stepper.d.ts +2 -0
  403. package/lib/src/molecules/Stepper/Stepper.stories.d.ts +8 -0
  404. package/lib/src/molecules/Stepper/Stepper.test.d.ts +1 -0
  405. package/lib/src/molecules/Stepper/Stepper.tokens.d.ts +21 -0
  406. package/lib/src/molecules/Stepper/Stepper.types.d.ts +33 -0
  407. package/lib/src/molecules/Stepper/index.d.ts +3 -0
  408. package/lib/src/molecules/TabGroup/TabGroup.d.ts +3 -0
  409. package/lib/src/molecules/TabGroup/TabGroup.stories.d.ts +6 -0
  410. package/lib/src/molecules/TabGroup/TabGroup.test.d.ts +1 -0
  411. package/lib/src/molecules/TabGroup/TabGroup.tokens.d.ts +26 -0
  412. package/lib/src/molecules/TabGroup/TabGroup.types.d.ts +33 -0
  413. package/lib/src/molecules/TabGroup/TabGroup.utils.d.ts +2 -0
  414. package/lib/src/molecules/TabGroup/index.d.ts +3 -0
  415. package/lib/src/molecules/TabSwitch/TabSwitch.d.ts +3 -0
  416. package/lib/src/molecules/TabSwitch/TabSwitch.stories.d.ts +5 -0
  417. package/lib/src/molecules/TabSwitch/TabSwitch.test.d.ts +1 -0
  418. package/lib/src/molecules/TabSwitch/TabSwitch.tokens.d.ts +10 -0
  419. package/lib/src/molecules/TabSwitch/TabSwitch.types.d.ts +28 -0
  420. package/lib/src/molecules/TabSwitch/TabSwitch.utils.d.ts +2 -0
  421. package/lib/src/molecules/TabSwitch/index.d.ts +3 -0
  422. package/lib/src/molecules/Table/Table.d.ts +2 -0
  423. package/lib/src/molecules/Table/Table.stories.d.ts +5 -0
  424. package/lib/src/molecules/Table/Table.test.d.ts +1 -0
  425. package/lib/src/molecules/Table/Table.tokens.d.ts +14 -0
  426. package/lib/src/molecules/Table/Table.types.d.ts +18 -0
  427. package/lib/src/molecules/Table/index.d.ts +3 -0
  428. package/lib/src/molecules/Table/mocks/data.d.ts +15 -0
  429. package/lib/src/molecules/TextareaGroup/TextareaGroup.d.ts +2 -0
  430. package/lib/src/molecules/TextareaGroup/TextareaGroup.stories.d.ts +8 -0
  431. package/lib/src/molecules/TextareaGroup/TextareaGroup.test.d.ts +1 -0
  432. package/lib/src/molecules/TextareaGroup/TextareaGroup.tokens.d.ts +2 -0
  433. package/lib/src/molecules/TextareaGroup/TextareaGroup.types.d.ts +13 -0
  434. package/lib/src/molecules/TextareaGroup/index.d.ts +3 -0
  435. package/lib/src/molecules/ToggleGroup/ToggleGroup.d.ts +2 -0
  436. package/lib/src/molecules/ToggleGroup/ToggleGroup.stories.d.ts +9 -0
  437. package/lib/src/molecules/ToggleGroup/ToggleGroup.test.d.ts +1 -0
  438. package/lib/src/molecules/ToggleGroup/ToggleGroup.types.d.ts +12 -0
  439. package/lib/src/molecules/ToggleGroup/ToogleGroup.tokens.d.ts +3 -0
  440. package/lib/src/molecules/ToggleGroup/index.d.ts +3 -0
  441. package/lib/src/molecules/UploadInput/UploadInput.d.ts +18 -0
  442. package/lib/src/molecules/UploadInput/UploadInput.stories.d.ts +8 -0
  443. package/lib/src/molecules/UploadInput/UploadInput.test.d.ts +1 -0
  444. package/lib/src/molecules/UploadInput/UploadInput.tokens.d.ts +17 -0
  445. package/lib/src/molecules/UploadInput/UploadInput.types.d.ts +30 -0
  446. package/lib/src/molecules/UploadInput/UploadInput.utils.d.ts +3 -0
  447. package/lib/src/molecules/UploadInput/index.d.ts +3 -0
  448. package/lib/src/molecules/UserContact/UserContact.d.ts +2 -0
  449. package/lib/src/molecules/UserContact/UserContact.stories.d.ts +8 -0
  450. package/lib/src/molecules/UserContact/UserContact.test.d.ts +1 -0
  451. package/lib/src/molecules/UserContact/UserContact.tokens.d.ts +10 -0
  452. package/lib/src/molecules/UserContact/UserContact.types.d.ts +15 -0
  453. package/lib/src/molecules/UserContact/index.d.ts +3 -0
  454. package/lib/src/molecules/index.d.ts +49 -0
  455. package/lib/src/tokens/colors.d.ts +2 -0
  456. package/lib/src/tokens/index.d.ts +3 -0
  457. package/lib/src/tokens/types.d.ts +36 -0
  458. package/lib/src/tokens/typography.d.ts +2 -0
  459. package/lib/src/utils/date.d.ts +1 -0
  460. package/lib/src/utils/index.d.ts +2 -0
  461. package/lib/src/utils/twMerge.d.ts +7 -0
  462. package/lib/tokens/index.js +248 -0
  463. package/lib/utils/index.js +11 -0
  464. package/lib/vite.config.d.ts +2 -0
  465. package/package.json +163 -0
@@ -0,0 +1,1075 @@
1
+ import { n as s, P as S, o as tt, p as Pe, u as G, q as rt, v as Re, w as le, x as R, y as U, z as ot, D as ke, E as nt, F as st, G as at, J as it, K as Ne, N as ct, O as lt, Q as dt, U as ut, V as ft, W as pt, X as vt, Y as mt, Z as xt, _ as ht } from "./Avatar.tokens.js";
2
+ import * as n from "react";
3
+ import { forwardRef as wt } from "react";
4
+ import * as gt from "react-dom";
5
+ import { b as bt, a as C } from "./twMerge.js";
6
+ const Tt = (e) => /* @__PURE__ */ n.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: 19, height: 19, fill: "currentFill", ...e }, /* @__PURE__ */ n.createElement("path", { fillOpacity: 0.8, d: "M1.6 8a.75.75 0 0 1-.75-.75v-6A.75.75 0 0 1 1.6.5h6a.75.75 0 0 1 .75.75v6A.75.75 0 0 1 7.6 8zm10.5 0a.75.75 0 0 1-.75-.75v-6A.75.75 0 0 1 12.1.5h6a.75.75 0 0 1 .75.75v6a.75.75 0 0 1-.75.75zM1.6 18.5a.75.75 0 0 1-.75-.75v-6A.75.75 0 0 1 1.6 11h6a.75.75 0 0 1 .75.75v6a.75.75 0 0 1-.75.75zm10.5 0a.75.75 0 0 1-.75-.75v-6a.75.75 0 0 1 .75-.75h6a.75.75 0 0 1 .75.75v6a.75.75 0 0 1-.75.75z" })), yt = (e) => /* @__PURE__ */ n.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: 19, height: 13, fill: "currentFill", ...e }, /* @__PURE__ */ n.createElement("path", { fillOpacity: 0.8, d: "M1.45 12.45a1 1 0 0 1-.72-.28 1 1 0 0 1-.28-.72q0-.43.28-.7.3-.3.72-.3h16q.43 0 .7.3.3.27.3.7a1 1 0 0 1-1 1zm0-5a1 1 0 0 1-.72-.28 1 1 0 0 1-.28-.72q0-.42.28-.7.3-.3.72-.3h16q.43 0 .7.3.3.27.3.7a1 1 0 0 1-1 1zm0-5a1 1 0 0 1-.72-.28 1 1 0 0 1-.28-.72q0-.43.28-.7.3-.3.72-.3h16q.43 0 .7.3.3.28.3.7a1 1 0 0 1-1 1z" })), be = (e) => /* @__PURE__ */ n.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: 24, height: 25, fill: "none", ...e }, /* @__PURE__ */ n.createElement("path", { fill: "currentFill", d: "M9.73 18.24a1.2 1.2 0 0 1-.85-.35l-4.53-4.53a1.2 1.2 0 0 1 0-1.7 1.2 1.2 0 0 1 1.7 0l3.68 3.69 8.23-8.23a1.2 1.2 0 0 1 1.7 0 1.2 1.2 0 0 1 0 1.7l-9.08 9.07a1.2 1.2 0 0 1-.85.35" })), Et = (e) => /* @__PURE__ */ n.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: 24, height: 25, fill: "none", ...e }, /* @__PURE__ */ n.createElement("path", { stroke: "currentColor", strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: 2.36, d: "m7 17.5 10-10M17 17.5 7 7.5" })), Ct = (e) => /* @__PURE__ */ n.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: 24, height: 25, fill: "none", ...e }, /* @__PURE__ */ n.createElement("path", { fill: "currentFill", d: "M12.37 9.49a1.4 1.4 0 0 0-1.4 1.39v9.73c0 .76.64 1.39 1.4 1.39a1.4 1.4 0 0 0 1.39-1.39v-9.73a1.4 1.4 0 0 0-1.4-1.4M12.37 3c-.5 0-.97.19-1.32.54q-.25.28-.4.6-.14.35-.14.71c0 .49.2.97.54 1.32.69.69 1.95.69 2.63 0a1.84 1.84 0 0 0 .39-2.02q-.14-.34-.39-.61A1.8 1.8 0 0 0 12.37 3" })), Pt = (e) => /* @__PURE__ */ n.createElement("svg", { xmlns: "http://www.w3.org/2000/svg", width: 24, height: 25, fill: "none", ...e }, /* @__PURE__ */ n.createElement("path", { fill: "currentFill", d: "M12.37 15.51a1.4 1.4 0 0 1-1.4-1.39V4.4c0-.76.64-1.39 1.4-1.39s1.39.63 1.39 1.39v9.73a1.4 1.4 0 0 1-1.4 1.4M12.37 22c-.5 0-.97-.19-1.32-.54a3 3 0 0 1-.4-.6q-.14-.35-.14-.71c0-.49.2-.97.54-1.32a1.94 1.94 0 0 1 2.63 0 1.84 1.84 0 0 1 .39 2.02q-.14.33-.39.61-.54.53-1.31.54" })), Rt = {
7
+ success: /* @__PURE__ */ s.jsx(be, { className: "text-success-10 fill-success-10" }),
8
+ danger: /* @__PURE__ */ s.jsx(Et, { className: "text-danger-10 fill-danger-10" }),
9
+ info: /* @__PURE__ */ s.jsx(Ct, { className: "text-info-10 fill-info-10" }),
10
+ warning: /* @__PURE__ */ s.jsx(Pt, { className: "text-sidebar-20 fill-sidebar-20" }),
11
+ default: /* @__PURE__ */ s.jsx(be, { className: "text-success-10 fill-success-10" })
12
+ };
13
+ var kt = "VisuallyHidden", X = n.forwardRef(
14
+ (e, r) => /* @__PURE__ */ s.jsx(
15
+ S.span,
16
+ {
17
+ ...e,
18
+ ref: r,
19
+ style: {
20
+ // See: https://github.com/twbs/bootstrap/blob/main/scss/mixins/_visually-hidden.scss
21
+ position: "absolute",
22
+ border: 0,
23
+ width: 1,
24
+ height: 1,
25
+ padding: 0,
26
+ margin: -1,
27
+ overflow: "hidden",
28
+ clip: "rect(0, 0, 0, 0)",
29
+ whiteSpace: "nowrap",
30
+ wordWrap: "normal",
31
+ ...e.style
32
+ }
33
+ }
34
+ )
35
+ );
36
+ X.displayName = kt;
37
+ var Nt = X, jt = "ToastProvider", [je, At, St] = tt("Toast"), [Ae, Sr] = Pe("Toast", [St]), [_r, Y] = Ae(jt), Se = "ToastViewport", _t = ["F8"], ne = "toast.viewportPause", se = "toast.viewportResume", _e = n.forwardRef(
38
+ (e, r) => {
39
+ const {
40
+ __scopeToast: t,
41
+ hotkey: o = _t,
42
+ label: a = "Notifications ({hotkey})",
43
+ ...c
44
+ } = e, l = Y(Se, t), v = At(t), d = n.useRef(null), i = n.useRef(null), f = n.useRef(null), x = n.useRef(null), b = G(r, x, l.onViewportChange), w = o.join("+").replace(/Key/g, "").replace(/Digit/g, ""), T = l.toastCount > 0;
45
+ n.useEffect(() => {
46
+ const u = (y) => {
47
+ var g;
48
+ o.length !== 0 && o.every((E) => y[E] || y.code === E) && ((g = x.current) == null || g.focus());
49
+ };
50
+ return document.addEventListener("keydown", u), () => document.removeEventListener("keydown", u);
51
+ }, [o]), n.useEffect(() => {
52
+ const u = d.current, y = x.current;
53
+ if (T && u && y) {
54
+ const h = () => {
55
+ if (!l.isClosePausedRef.current) {
56
+ const k = new CustomEvent(ne);
57
+ y.dispatchEvent(k), l.isClosePausedRef.current = !0;
58
+ }
59
+ }, g = () => {
60
+ if (l.isClosePausedRef.current) {
61
+ const k = new CustomEvent(se);
62
+ y.dispatchEvent(k), l.isClosePausedRef.current = !1;
63
+ }
64
+ }, E = (k) => {
65
+ !u.contains(k.relatedTarget) && g();
66
+ }, P = () => {
67
+ u.contains(document.activeElement) || g();
68
+ };
69
+ return u.addEventListener("focusin", h), u.addEventListener("focusout", E), u.addEventListener("pointermove", h), u.addEventListener("pointerleave", P), window.addEventListener("blur", h), window.addEventListener("focus", g), () => {
70
+ u.removeEventListener("focusin", h), u.removeEventListener("focusout", E), u.removeEventListener("pointermove", h), u.removeEventListener("pointerleave", P), window.removeEventListener("blur", h), window.removeEventListener("focus", g);
71
+ };
72
+ }
73
+ }, [T, l.isClosePausedRef]);
74
+ const p = n.useCallback(
75
+ ({ tabbingDirection: u }) => {
76
+ const h = v().map((g) => {
77
+ const E = g.ref.current, P = [E, ...qt(E)];
78
+ return u === "forwards" ? P : P.reverse();
79
+ });
80
+ return (u === "forwards" ? h.reverse() : h).flat();
81
+ },
82
+ [v]
83
+ );
84
+ return n.useEffect(() => {
85
+ const u = x.current;
86
+ if (u) {
87
+ const y = (h) => {
88
+ var P, k, j;
89
+ const g = h.altKey || h.ctrlKey || h.metaKey;
90
+ if (h.key === "Tab" && !g) {
91
+ const F = document.activeElement, O = h.shiftKey;
92
+ if (h.target === u && O) {
93
+ (P = i.current) == null || P.focus();
94
+ return;
95
+ }
96
+ const _ = p({ tabbingDirection: O ? "backwards" : "forwards" }), K = _.findIndex((m) => m === F);
97
+ re(_.slice(K + 1)) ? h.preventDefault() : O ? (k = i.current) == null || k.focus() : (j = f.current) == null || j.focus();
98
+ }
99
+ };
100
+ return u.addEventListener("keydown", y), () => u.removeEventListener("keydown", y);
101
+ }
102
+ }, [v, p]), /* @__PURE__ */ s.jsxs(
103
+ rt,
104
+ {
105
+ ref: d,
106
+ role: "region",
107
+ "aria-label": a.replace("{hotkey}", w),
108
+ tabIndex: -1,
109
+ style: { pointerEvents: T ? void 0 : "none" },
110
+ children: [
111
+ T && /* @__PURE__ */ s.jsx(
112
+ ae,
113
+ {
114
+ ref: i,
115
+ onFocusFromOutsideViewport: () => {
116
+ const u = p({
117
+ tabbingDirection: "forwards"
118
+ });
119
+ re(u);
120
+ }
121
+ }
122
+ ),
123
+ /* @__PURE__ */ s.jsx(je.Slot, { scope: t, children: /* @__PURE__ */ s.jsx(S.ol, { tabIndex: -1, ...c, ref: b }) }),
124
+ T && /* @__PURE__ */ s.jsx(
125
+ ae,
126
+ {
127
+ ref: f,
128
+ onFocusFromOutsideViewport: () => {
129
+ const u = p({
130
+ tabbingDirection: "backwards"
131
+ });
132
+ re(u);
133
+ }
134
+ }
135
+ )
136
+ ]
137
+ }
138
+ );
139
+ }
140
+ );
141
+ _e.displayName = Se;
142
+ var De = "ToastFocusProxy", ae = n.forwardRef(
143
+ (e, r) => {
144
+ const { __scopeToast: t, onFocusFromOutsideViewport: o, ...a } = e, c = Y(De, t);
145
+ return /* @__PURE__ */ s.jsx(
146
+ X,
147
+ {
148
+ "aria-hidden": !0,
149
+ tabIndex: 0,
150
+ ...a,
151
+ ref: r,
152
+ style: { position: "fixed" },
153
+ onFocus: (l) => {
154
+ var i;
155
+ const v = l.relatedTarget;
156
+ !((i = c.viewport) != null && i.contains(v)) && o();
157
+ }
158
+ }
159
+ );
160
+ }
161
+ );
162
+ ae.displayName = De;
163
+ var B = "Toast", Dt = "toast.swipeStart", Ot = "toast.swipeMove", Lt = "toast.swipeCancel", It = "toast.swipeEnd", Oe = n.forwardRef(
164
+ (e, r) => {
165
+ const { forceMount: t, open: o, defaultOpen: a, onOpenChange: c, ...l } = e, [v = !0, d] = Re({
166
+ prop: o,
167
+ defaultProp: a,
168
+ onChange: c
169
+ });
170
+ return /* @__PURE__ */ s.jsx(le, { present: t || v, children: /* @__PURE__ */ s.jsx(
171
+ Vt,
172
+ {
173
+ open: v,
174
+ ...l,
175
+ ref: r,
176
+ onClose: () => d(!1),
177
+ onPause: U(e.onPause),
178
+ onResume: U(e.onResume),
179
+ onSwipeStart: R(e.onSwipeStart, (i) => {
180
+ i.currentTarget.setAttribute("data-swipe", "start");
181
+ }),
182
+ onSwipeMove: R(e.onSwipeMove, (i) => {
183
+ const { x: f, y: x } = i.detail.delta;
184
+ i.currentTarget.setAttribute("data-swipe", "move"), i.currentTarget.style.setProperty("--radix-toast-swipe-move-x", `${f}px`), i.currentTarget.style.setProperty("--radix-toast-swipe-move-y", `${x}px`);
185
+ }),
186
+ onSwipeCancel: R(e.onSwipeCancel, (i) => {
187
+ i.currentTarget.setAttribute("data-swipe", "cancel"), i.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"), i.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"), i.currentTarget.style.removeProperty("--radix-toast-swipe-end-x"), i.currentTarget.style.removeProperty("--radix-toast-swipe-end-y");
188
+ }),
189
+ onSwipeEnd: R(e.onSwipeEnd, (i) => {
190
+ const { x: f, y: x } = i.detail.delta;
191
+ i.currentTarget.setAttribute("data-swipe", "end"), i.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"), i.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"), i.currentTarget.style.setProperty("--radix-toast-swipe-end-x", `${f}px`), i.currentTarget.style.setProperty("--radix-toast-swipe-end-y", `${x}px`), d(!1);
192
+ })
193
+ }
194
+ ) });
195
+ }
196
+ );
197
+ Oe.displayName = B;
198
+ var [Ft, Mt] = Ae(B, {
199
+ onClose() {
200
+ }
201
+ }), Vt = n.forwardRef(
202
+ (e, r) => {
203
+ const {
204
+ __scopeToast: t,
205
+ type: o = "foreground",
206
+ duration: a,
207
+ open: c,
208
+ onClose: l,
209
+ onEscapeKeyDown: v,
210
+ onPause: d,
211
+ onResume: i,
212
+ onSwipeStart: f,
213
+ onSwipeMove: x,
214
+ onSwipeCancel: b,
215
+ onSwipeEnd: w,
216
+ ...T
217
+ } = e, p = Y(B, t), [u, y] = n.useState(null), h = G(r, (m) => y(m)), g = n.useRef(null), E = n.useRef(null), P = a || p.duration, k = n.useRef(0), j = n.useRef(P), F = n.useRef(0), { onToastAdd: O, onToastRemove: ee } = p, L = U(() => {
218
+ var N;
219
+ (u == null ? void 0 : u.contains(document.activeElement)) && ((N = p.viewport) == null || N.focus()), l();
220
+ }), _ = n.useCallback(
221
+ (m) => {
222
+ !m || m === 1 / 0 || (window.clearTimeout(F.current), k.current = (/* @__PURE__ */ new Date()).getTime(), F.current = window.setTimeout(L, m));
223
+ },
224
+ [L]
225
+ );
226
+ n.useEffect(() => {
227
+ const m = p.viewport;
228
+ if (m) {
229
+ const N = () => {
230
+ _(j.current), i == null || i();
231
+ }, A = () => {
232
+ const M = (/* @__PURE__ */ new Date()).getTime() - k.current;
233
+ j.current = j.current - M, window.clearTimeout(F.current), d == null || d();
234
+ };
235
+ return m.addEventListener(ne, A), m.addEventListener(se, N), () => {
236
+ m.removeEventListener(ne, A), m.removeEventListener(se, N);
237
+ };
238
+ }
239
+ }, [p.viewport, P, d, i, _]), n.useEffect(() => {
240
+ c && !p.isClosePausedRef.current && _(P);
241
+ }, [c, P, p.isClosePausedRef, _]), n.useEffect(() => (O(), () => ee()), [O, ee]);
242
+ const K = n.useMemo(() => u ? $e(u) : null, [u]);
243
+ return p.viewport ? /* @__PURE__ */ s.jsxs(s.Fragment, { children: [
244
+ K && /* @__PURE__ */ s.jsx(
245
+ Ht,
246
+ {
247
+ __scopeToast: t,
248
+ role: "status",
249
+ "aria-live": o === "foreground" ? "assertive" : "polite",
250
+ "aria-atomic": !0,
251
+ children: K
252
+ }
253
+ ),
254
+ /* @__PURE__ */ s.jsx(Ft, { scope: t, onClose: L, children: gt.createPortal(
255
+ /* @__PURE__ */ s.jsx(je.ItemSlot, { scope: t, children: /* @__PURE__ */ s.jsx(
256
+ ot,
257
+ {
258
+ asChild: !0,
259
+ onEscapeKeyDown: R(v, () => {
260
+ p.isFocusedToastEscapeKeyDownRef.current || L(), p.isFocusedToastEscapeKeyDownRef.current = !1;
261
+ }),
262
+ children: /* @__PURE__ */ s.jsx(
263
+ S.li,
264
+ {
265
+ role: "status",
266
+ "aria-live": "off",
267
+ "aria-atomic": !0,
268
+ tabIndex: 0,
269
+ "data-state": c ? "open" : "closed",
270
+ "data-swipe-direction": p.swipeDirection,
271
+ ...T,
272
+ ref: h,
273
+ style: { userSelect: "none", touchAction: "none", ...e.style },
274
+ onKeyDown: R(e.onKeyDown, (m) => {
275
+ m.key === "Escape" && (v == null || v(m.nativeEvent), m.nativeEvent.defaultPrevented || (p.isFocusedToastEscapeKeyDownRef.current = !0, L()));
276
+ }),
277
+ onPointerDown: R(e.onPointerDown, (m) => {
278
+ m.button === 0 && (g.current = { x: m.clientX, y: m.clientY });
279
+ }),
280
+ onPointerMove: R(e.onPointerMove, (m) => {
281
+ if (!g.current) return;
282
+ const N = m.clientX - g.current.x, A = m.clientY - g.current.y, M = !!E.current, V = ["left", "right"].includes(p.swipeDirection), W = ["left", "up"].includes(p.swipeDirection) ? Math.min : Math.max, Ze = V ? W(0, N) : 0, et = V ? 0 : W(0, A), te = m.pointerType === "touch" ? 10 : 2, z = { x: Ze, y: et }, ge = { originalEvent: m, delta: z };
283
+ M ? (E.current = z, q(Ot, x, ge, {
284
+ discrete: !1
285
+ })) : Te(z, p.swipeDirection, te) ? (E.current = z, q(Dt, f, ge, {
286
+ discrete: !1
287
+ }), m.target.setPointerCapture(m.pointerId)) : (Math.abs(N) > te || Math.abs(A) > te) && (g.current = null);
288
+ }),
289
+ onPointerUp: R(e.onPointerUp, (m) => {
290
+ const N = E.current, A = m.target;
291
+ if (A.hasPointerCapture(m.pointerId) && A.releasePointerCapture(m.pointerId), E.current = null, g.current = null, N) {
292
+ const M = m.currentTarget, V = { originalEvent: m, delta: N };
293
+ Te(N, p.swipeDirection, p.swipeThreshold) ? q(It, w, V, {
294
+ discrete: !0
295
+ }) : q(
296
+ Lt,
297
+ b,
298
+ V,
299
+ {
300
+ discrete: !0
301
+ }
302
+ ), M.addEventListener("click", (W) => W.preventDefault(), {
303
+ once: !0
304
+ });
305
+ }
306
+ })
307
+ }
308
+ )
309
+ }
310
+ ) }),
311
+ p.viewport
312
+ ) })
313
+ ] }) : null;
314
+ }
315
+ ), Ht = (e) => {
316
+ const { __scopeToast: r, children: t, ...o } = e, a = Y(B, r), [c, l] = n.useState(!1), [v, d] = n.useState(!1);
317
+ return Wt(() => l(!0)), n.useEffect(() => {
318
+ const i = window.setTimeout(() => d(!0), 1e3);
319
+ return () => window.clearTimeout(i);
320
+ }, []), v ? null : /* @__PURE__ */ s.jsx(ke, { asChild: !0, children: /* @__PURE__ */ s.jsx(X, { ...o, children: c && /* @__PURE__ */ s.jsxs(s.Fragment, { children: [
321
+ a.label,
322
+ " ",
323
+ t
324
+ ] }) }) });
325
+ }, $t = "ToastTitle", Le = n.forwardRef(
326
+ (e, r) => {
327
+ const { __scopeToast: t, ...o } = e;
328
+ return /* @__PURE__ */ s.jsx(S.div, { ...o, ref: r });
329
+ }
330
+ );
331
+ Le.displayName = $t;
332
+ var Kt = "ToastDescription", Ie = n.forwardRef(
333
+ (e, r) => {
334
+ const { __scopeToast: t, ...o } = e;
335
+ return /* @__PURE__ */ s.jsx(S.div, { ...o, ref: r });
336
+ }
337
+ );
338
+ Ie.displayName = Kt;
339
+ var Fe = "ToastAction", Me = n.forwardRef(
340
+ (e, r) => {
341
+ const { altText: t, ...o } = e;
342
+ return t.trim() ? /* @__PURE__ */ s.jsx(He, { altText: t, asChild: !0, children: /* @__PURE__ */ s.jsx(de, { ...o, ref: r }) }) : (console.error(
343
+ `Invalid prop \`altText\` supplied to \`${Fe}\`. Expected non-empty \`string\`.`
344
+ ), null);
345
+ }
346
+ );
347
+ Me.displayName = Fe;
348
+ var Ve = "ToastClose", de = n.forwardRef(
349
+ (e, r) => {
350
+ const { __scopeToast: t, ...o } = e, a = Mt(Ve, t);
351
+ return /* @__PURE__ */ s.jsx(He, { asChild: !0, children: /* @__PURE__ */ s.jsx(
352
+ S.button,
353
+ {
354
+ type: "button",
355
+ ...o,
356
+ ref: r,
357
+ onClick: R(e.onClick, a.onClose)
358
+ }
359
+ ) });
360
+ }
361
+ );
362
+ de.displayName = Ve;
363
+ var He = n.forwardRef((e, r) => {
364
+ const { __scopeToast: t, altText: o, ...a } = e;
365
+ return /* @__PURE__ */ s.jsx(
366
+ S.div,
367
+ {
368
+ "data-radix-toast-announce-exclude": "",
369
+ "data-radix-toast-announce-alt": o || void 0,
370
+ ...a,
371
+ ref: r
372
+ }
373
+ );
374
+ });
375
+ function $e(e) {
376
+ const r = [];
377
+ return Array.from(e.childNodes).forEach((o) => {
378
+ if (o.nodeType === o.TEXT_NODE && o.textContent && r.push(o.textContent), zt(o)) {
379
+ const a = o.ariaHidden || o.hidden || o.style.display === "none", c = o.dataset.radixToastAnnounceExclude === "";
380
+ if (!a)
381
+ if (c) {
382
+ const l = o.dataset.radixToastAnnounceAlt;
383
+ l && r.push(l);
384
+ } else
385
+ r.push(...$e(o));
386
+ }
387
+ }), r;
388
+ }
389
+ function q(e, r, t, { discrete: o }) {
390
+ const a = t.originalEvent.currentTarget, c = new CustomEvent(e, { bubbles: !0, cancelable: !0, detail: t });
391
+ r && a.addEventListener(e, r, { once: !0 }), o ? nt(a, c) : a.dispatchEvent(c);
392
+ }
393
+ var Te = (e, r, t = 0) => {
394
+ const o = Math.abs(e.x), a = Math.abs(e.y), c = o > a;
395
+ return r === "left" || r === "right" ? c && o > t : !c && a > t;
396
+ };
397
+ function Wt(e = () => {
398
+ }) {
399
+ const r = U(e);
400
+ st(() => {
401
+ let t = 0, o = 0;
402
+ return t = window.requestAnimationFrame(() => o = window.requestAnimationFrame(r)), () => {
403
+ window.cancelAnimationFrame(t), window.cancelAnimationFrame(o);
404
+ };
405
+ }, [r]);
406
+ }
407
+ function zt(e) {
408
+ return e.nodeType === e.ELEMENT_NODE;
409
+ }
410
+ function qt(e) {
411
+ const r = [], t = document.createTreeWalker(e, NodeFilter.SHOW_ELEMENT, {
412
+ acceptNode: (o) => {
413
+ const a = o.tagName === "INPUT" && o.type === "hidden";
414
+ return o.disabled || o.hidden || a ? NodeFilter.FILTER_SKIP : o.tabIndex >= 0 ? NodeFilter.FILTER_ACCEPT : NodeFilter.FILTER_SKIP;
415
+ }
416
+ });
417
+ for (; t.nextNode(); ) r.push(t.currentNode);
418
+ return r;
419
+ }
420
+ function re(e) {
421
+ const r = document.activeElement;
422
+ return e.some((t) => t === r ? !0 : (t.focus(), document.activeElement !== r));
423
+ }
424
+ var Ke = _e, We = Oe, ze = Le, qe = Ie, Ue = Me, Ge = de;
425
+ const ye = (e) => typeof e == "boolean" ? `${e}` : e === 0 ? "0" : e, Ee = bt, Ut = (e, r) => (t) => {
426
+ var o;
427
+ if ((r == null ? void 0 : r.variants) == null) return Ee(e, t == null ? void 0 : t.class, t == null ? void 0 : t.className);
428
+ const { variants: a, defaultVariants: c } = r, l = Object.keys(a).map((i) => {
429
+ const f = t == null ? void 0 : t[i], x = c == null ? void 0 : c[i];
430
+ if (f === null) return null;
431
+ const b = ye(f) || ye(x);
432
+ return a[i][b];
433
+ }), v = t && Object.entries(t).reduce((i, f) => {
434
+ let [x, b] = f;
435
+ return b === void 0 || (i[x] = b), i;
436
+ }, {}), d = r == null || (o = r.compoundVariants) === null || o === void 0 ? void 0 : o.reduce((i, f) => {
437
+ let { class: x, className: b, ...w } = f;
438
+ return Object.entries(w).every((T) => {
439
+ let [p, u] = T;
440
+ return Array.isArray(u) ? u.includes({
441
+ ...c,
442
+ ...v
443
+ }[p]) : {
444
+ ...c,
445
+ ...v
446
+ }[p] === u;
447
+ }) ? [
448
+ ...i,
449
+ x,
450
+ b
451
+ ] : i;
452
+ }, []);
453
+ return Ee(e, l, d, t == null ? void 0 : t.class, t == null ? void 0 : t.className);
454
+ }, Gt = n.forwardRef(({ className: e, ...r }, t) => /* @__PURE__ */ s.jsx(
455
+ Ke,
456
+ {
457
+ ref: t,
458
+ className: C(
459
+ "fixed top-0 z-[100] flex max-h-screen flex-col-reverse sm:bottom-0 sm:right-0 sm:top-auto sm:flex-col min-w-64 max-w-[420px]",
460
+ e
461
+ ),
462
+ ...r
463
+ }
464
+ ));
465
+ Gt.displayName = Ke.displayName;
466
+ const Xt = Ut(
467
+ "group pointer-events-auto rounded-[10px] relative border-l-2 flex w-full items-center justify-between space-x-2 overflow-hidden py-3 px-5 transition-all data-[swipe=cancel]:translate-x-0 data-[swipe=end]:translate-x-[var(--radix-toast-swipe-end-x)] data-[swipe=move]:translate-x-[var(--radix-toast-swipe-move-x)] data-[swipe=move]:transition-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[swipe=end]:animate-out data-[state=closed]:fade-out-80 data-[state=closed]:slide-out-to-right-full data-[state=open]:slide-in-from-top-full data-[state=open]:sm:slide-in-from-bottom-full dark:border-neutral-800",
468
+ {
469
+ variants: {
470
+ variant: {
471
+ success: "text-success-10 bg-success-10/[.20] border-success-10",
472
+ danger: "text-danger-10 bg-danger-10/[.20] border-danger-10",
473
+ info: "text-info-10 bg-info-10/[.20] border-info-10",
474
+ warning: "text-sidebar-20 bg-sidebar-20/[.20] border-sidebar-20",
475
+ default: "text-success-10 bg-success-10/[.20] border-success-10"
476
+ }
477
+ },
478
+ defaultVariants: {
479
+ variant: "default"
480
+ }
481
+ }
482
+ ), Yt = n.forwardRef(({ className: e, variant: r, ...t }, o) => /* @__PURE__ */ s.jsx(
483
+ We,
484
+ {
485
+ ref: o,
486
+ className: C(Xt({ variant: r }), e),
487
+ ...t
488
+ }
489
+ ));
490
+ Yt.displayName = We.displayName;
491
+ const Bt = n.forwardRef(({ className: e, ...r }, t) => /* @__PURE__ */ s.jsx(
492
+ Ue,
493
+ {
494
+ ref: t,
495
+ className: C(
496
+ "inline-flex h-8 shrink-0 items-center justify-center rounded-md border border-neutral-200 bg-transparent px-3 text-sm font-medium transition-colors hover:bg-neutral-100 focus:outline-none focus:ring-1 focus:ring-neutral-950 disabled:pointer-events-none disabled:opacity-50 group-[.destructive]:border-neutral-100/40 group-[.destructive]:hover:border-red-500/30 group-[.destructive]:hover:bg-red-500 group-[.destructive]:hover:text-neutral-50 group-[.destructive]:focus:ring-red-500 dark:border-neutral-800 dark:hover:bg-neutral-800 dark:focus:ring-neutral-300 dark:group-[.destructive]:border-neutral-800/40 dark:group-[.destructive]:hover:border-red-900/30 dark:group-[.destructive]:hover:bg-red-900 dark:group-[.destructive]:hover:text-neutral-50 dark:group-[.destructive]:focus:ring-red-900",
497
+ e
498
+ ),
499
+ ...r
500
+ }
501
+ ));
502
+ Bt.displayName = Ue.displayName;
503
+ const Jt = n.forwardRef(({ className: e, ...r }, t) => /* @__PURE__ */ s.jsx(
504
+ Ge,
505
+ {
506
+ ref: t,
507
+ className: C(
508
+ "absolute right-3 top-2 rounded-md p-1 text-neutral-950/50 opacity-0 transition-opacity hover:text-neutral-950 focus:opacity-100 focus:outline-none focus:ring-1 group-hover:opacity-100 group-[.destructive]:text-red-300 group-[.destructive]:hover:text-red-50 group-[.destructive]:focus:ring-red-400 group-[.destructive]:focus:ring-offset-red-600 dark:text-neutral-50/50 dark:hover:text-neutral-50",
509
+ e
510
+ ),
511
+ "toast-close": "",
512
+ ...r,
513
+ children: /* @__PURE__ */ s.jsx(at, { className: "h-4 w-4" })
514
+ }
515
+ ));
516
+ Jt.displayName = Ge.displayName;
517
+ const Xe = n.forwardRef(({ className: e, ...r }, t) => /* @__PURE__ */ s.jsx(
518
+ ze,
519
+ {
520
+ ref: t,
521
+ className: C("text-base font-semibold [&+div]:text-xs", e),
522
+ ...r
523
+ }
524
+ ));
525
+ Xe.displayName = ze.displayName;
526
+ const Ye = n.forwardRef(({ className: e, ...r }, t) => /* @__PURE__ */ s.jsx(
527
+ qe,
528
+ {
529
+ ref: t,
530
+ className: C("text-xs font-normal opacity-90", e),
531
+ ...r
532
+ }
533
+ ));
534
+ Ye.displayName = qe.displayName;
535
+ const Dr = ({
536
+ type: e = "info",
537
+ title: r,
538
+ description: t,
539
+ withIcon: o = !0
540
+ }) => /* @__PURE__ */ s.jsxs(
541
+ "div",
542
+ {
543
+ className: C(
544
+ o ? "items-start" : "justify-center",
545
+ "flex items-center gap-1.5"
546
+ ),
547
+ children: [
548
+ o && /* @__PURE__ */ s.jsx("div", { "data-testid": "notification-icon", children: e && Rt[e] }),
549
+ /* @__PURE__ */ s.jsxs("div", { className: "flex flex-col", children: [
550
+ /* @__PURE__ */ s.jsx(Xe, { className: o ? "text-left" : "text-center", children: r }),
551
+ /* @__PURE__ */ s.jsx(Ye, { className: o ? "text-left" : "text-center", children: t })
552
+ ] })
553
+ ]
554
+ }
555
+ ), { Root: Qt, Thumb: Zt } = it, Or = n.forwardRef(({ classNames: e, ...r }, t) => {
556
+ const o = r.checked ?? !1;
557
+ return /* @__PURE__ */ s.jsxs(Qt, { ref: t, className: C(D.base, e == null ? void 0 : e.root), ...r, children: [
558
+ /* @__PURE__ */ s.jsx(
559
+ "div",
560
+ {
561
+ className: C(
562
+ D.iconWrapper.base,
563
+ "left-0",
564
+ !o && D.iconWrapper.checked
565
+ ),
566
+ children: /* @__PURE__ */ s.jsx(
567
+ yt,
568
+ {
569
+ "data-testid": "list-icon",
570
+ className: C(o ? "fill-dark-30/25" : "fill-dark-30/[.80]")
571
+ }
572
+ )
573
+ }
574
+ ),
575
+ /* @__PURE__ */ s.jsx(
576
+ "div",
577
+ {
578
+ className: C(
579
+ D.iconWrapper.base,
580
+ "right-0",
581
+ o && D.iconWrapper.checked
582
+ ),
583
+ children: /* @__PURE__ */ s.jsx(
584
+ Tt,
585
+ {
586
+ "data-testid": "grid-icon",
587
+ className: C(o ? "fill-dark-30/[.80]" : "fill-dark-30/25")
588
+ }
589
+ )
590
+ }
591
+ ),
592
+ /* @__PURE__ */ s.jsx("div", { className: C(D.borderLine) }),
593
+ /* @__PURE__ */ s.jsx(Zt, { tabIndex: 1, className: C(D.thumb, e == null ? void 0 : e.thumb) })
594
+ ] });
595
+ }), D = {
596
+ base: "group relative inline-flex w-20 h-[38px] shrink-0 cursor-pointer items-center bg-gray-50 rounded-[10px] transition-colors duration-200 transition-colors",
597
+ thumb: "pointer-events-none block z-50 size-10 bg-transparent border border-secondary-10/[.15] transition-transform rounded-[10px] ring-0 data-[state=checked]:translate-x-full data-[state=unchecked]:translate-x-0",
598
+ iconWrapper: {
599
+ base: "absolute z-20 w-1/2 h-full flex items-center justify-center",
600
+ checked: "bg-sidebar-10 rounded-[10px] overflow-hidden"
601
+ },
602
+ borderLine: "pointer-events-none absolute z-0 left-0 top-0 w-full h-full group-hover:border group-hover:border-primary-20/[.30] rounded-[10px] transition-colors duration-200"
603
+ }, H = {
604
+ sizes: {
605
+ small: {
606
+ base: "flex items-center justify-center min-w-32 bg-sidebar-10 text-xs font-medium leading-none border-[1px] rounded-md py-[7px] px-5",
607
+ default: "text-dark-30/25 border-dark-30/25",
608
+ active: "bg-gray-50 text-dark-30 border-dark-30/[.40]",
609
+ hover: "hover:text-dark-30/[.40] hover:border-dark-30/[.40]",
610
+ disabled: "bg-dark-30/[.08] text-dark-30/25 border-dark-30/25 cursor-not-allowed"
611
+ },
612
+ medium: {
613
+ base: "flex items-center gap-1 pl-4 pr-5 py-2.5 bg-gray-50 text-sm font-semibold leading-none rounded-[10px] border",
614
+ default: "border-gray-50 text-dark-30",
615
+ active: "bg-primary-10 border-primary-10 text-white",
616
+ hover: "hover:border-primary-10/[.30]",
617
+ disabled: "bg-dark-30/[.08] text-dark-30/25 cursor-not-allowed"
618
+ },
619
+ large: {
620
+ base: "flex items-center bg-gray-50 px-8 py-3.5 text-sm font-regular leading-none border rounded-[10px] focus:outline-none focus:ring focus:ring-transparent",
621
+ default: "text-dark-40/50 border-dark-30/[.15]",
622
+ active: "bg-primary-10/[.10] text-dark-30 font-semibold border border-primary-10/[.20]",
623
+ hover: "hover:border-primary-20/[.20]",
624
+ disabled: "bg-dark-30/[.08] text-dark-30/25 border-dark-30/25 cursor-not-allowed"
625
+ }
626
+ },
627
+ focus: "focus:outline-none focus:ring focus:ring-primary-10/[.20]",
628
+ icon: {
629
+ default: "fill-dark-30",
630
+ active: "fill-white",
631
+ disabled: "fill-dark-30/25"
632
+ }
633
+ }, Lr = wt(
634
+ ({
635
+ variant: e = "small",
636
+ active: r,
637
+ icon: t,
638
+ disabled: o,
639
+ children: a,
640
+ className: c,
641
+ iconDimensions: l,
642
+ ...v
643
+ }, d) => {
644
+ const i = H.sizes[e];
645
+ return /* @__PURE__ */ s.jsxs(
646
+ "button",
647
+ {
648
+ role: "tab",
649
+ "aria-selected": r,
650
+ ref: d,
651
+ className: C(
652
+ i.base,
653
+ i.default,
654
+ !o && !r && i.hover,
655
+ r && !o && i.active,
656
+ r && !o && H.focus,
657
+ o && i.disabled,
658
+ c
659
+ ),
660
+ ...v,
661
+ children: [
662
+ !!t && /* @__PURE__ */ s.jsx(
663
+ t,
664
+ {
665
+ "aria-label": "icon",
666
+ "aria-hidden": !0,
667
+ className: C(
668
+ H.icon.default,
669
+ r && H.icon.active,
670
+ o && H.icon.disabled
671
+ ),
672
+ ...l
673
+ }
674
+ ),
675
+ a
676
+ ]
677
+ }
678
+ );
679
+ }
680
+ );
681
+ var [J, er] = Pe("Tooltip", [
682
+ Ne
683
+ ]), Q = Ne(), Be = "TooltipProvider", tr = 700, ie = "tooltip.open", [rr, ue] = J(Be), fe = (e) => {
684
+ const {
685
+ __scopeTooltip: r,
686
+ delayDuration: t = tr,
687
+ skipDelayDuration: o = 300,
688
+ disableHoverableContent: a = !1,
689
+ children: c
690
+ } = e, [l, v] = n.useState(!0), d = n.useRef(!1), i = n.useRef(0);
691
+ return n.useEffect(() => {
692
+ const f = i.current;
693
+ return () => window.clearTimeout(f);
694
+ }, []), /* @__PURE__ */ s.jsx(
695
+ rr,
696
+ {
697
+ scope: r,
698
+ isOpenDelayed: l,
699
+ delayDuration: t,
700
+ onOpen: n.useCallback(() => {
701
+ window.clearTimeout(i.current), v(!1);
702
+ }, []),
703
+ onClose: n.useCallback(() => {
704
+ window.clearTimeout(i.current), i.current = window.setTimeout(
705
+ () => v(!0),
706
+ o
707
+ );
708
+ }, [o]),
709
+ isPointerInTransitRef: d,
710
+ onPointerInTransitChange: n.useCallback((f) => {
711
+ d.current = f;
712
+ }, []),
713
+ disableHoverableContent: a,
714
+ children: c
715
+ }
716
+ );
717
+ };
718
+ fe.displayName = Be;
719
+ var Z = "Tooltip", [or, $] = J(Z), pe = (e) => {
720
+ const {
721
+ __scopeTooltip: r,
722
+ children: t,
723
+ open: o,
724
+ defaultOpen: a = !1,
725
+ onOpenChange: c,
726
+ disableHoverableContent: l,
727
+ delayDuration: v
728
+ } = e, d = ue(Z, e.__scopeTooltip), i = Q(r), [f, x] = n.useState(null), b = lt(), w = n.useRef(0), T = l ?? d.disableHoverableContent, p = v ?? d.delayDuration, u = n.useRef(!1), [y = !1, h] = Re({
729
+ prop: o,
730
+ defaultProp: a,
731
+ onChange: (j) => {
732
+ j ? (d.onOpen(), document.dispatchEvent(new CustomEvent(ie))) : d.onClose(), c == null || c(j);
733
+ }
734
+ }), g = n.useMemo(() => y ? u.current ? "delayed-open" : "instant-open" : "closed", [y]), E = n.useCallback(() => {
735
+ window.clearTimeout(w.current), w.current = 0, u.current = !1, h(!0);
736
+ }, [h]), P = n.useCallback(() => {
737
+ window.clearTimeout(w.current), w.current = 0, h(!1);
738
+ }, [h]), k = n.useCallback(() => {
739
+ window.clearTimeout(w.current), w.current = window.setTimeout(() => {
740
+ u.current = !0, h(!0), w.current = 0;
741
+ }, p);
742
+ }, [p, h]);
743
+ return n.useEffect(() => () => {
744
+ w.current && (window.clearTimeout(w.current), w.current = 0);
745
+ }, []), /* @__PURE__ */ s.jsx(dt, { ...i, children: /* @__PURE__ */ s.jsx(
746
+ or,
747
+ {
748
+ scope: r,
749
+ contentId: b,
750
+ open: y,
751
+ stateAttribute: g,
752
+ trigger: f,
753
+ onTriggerChange: x,
754
+ onTriggerEnter: n.useCallback(() => {
755
+ d.isOpenDelayed ? k() : E();
756
+ }, [d.isOpenDelayed, k, E]),
757
+ onTriggerLeave: n.useCallback(() => {
758
+ T ? P() : (window.clearTimeout(w.current), w.current = 0);
759
+ }, [P, T]),
760
+ onOpen: E,
761
+ onClose: P,
762
+ disableHoverableContent: T,
763
+ children: t
764
+ }
765
+ ) });
766
+ };
767
+ pe.displayName = Z;
768
+ var ce = "TooltipTrigger", ve = n.forwardRef(
769
+ (e, r) => {
770
+ const { __scopeTooltip: t, ...o } = e, a = $(ce, t), c = ue(ce, t), l = Q(t), v = n.useRef(null), d = G(r, v, a.onTriggerChange), i = n.useRef(!1), f = n.useRef(!1), x = n.useCallback(() => i.current = !1, []);
771
+ return n.useEffect(() => () => document.removeEventListener("pointerup", x), [x]), /* @__PURE__ */ s.jsx(ut, { asChild: !0, ...l, children: /* @__PURE__ */ s.jsx(
772
+ S.button,
773
+ {
774
+ "aria-describedby": a.open ? a.contentId : void 0,
775
+ "data-state": a.stateAttribute,
776
+ ...o,
777
+ ref: d,
778
+ onPointerMove: R(e.onPointerMove, (b) => {
779
+ b.pointerType !== "touch" && !f.current && !c.isPointerInTransitRef.current && (a.onTriggerEnter(), f.current = !0);
780
+ }),
781
+ onPointerLeave: R(e.onPointerLeave, () => {
782
+ a.onTriggerLeave(), f.current = !1;
783
+ }),
784
+ onPointerDown: R(e.onPointerDown, () => {
785
+ i.current = !0, document.addEventListener("pointerup", x, { once: !0 });
786
+ }),
787
+ onFocus: R(e.onFocus, () => {
788
+ i.current || a.onOpen();
789
+ }),
790
+ onBlur: R(e.onBlur, a.onClose),
791
+ onClick: R(e.onClick, a.onClose)
792
+ }
793
+ ) });
794
+ }
795
+ );
796
+ ve.displayName = ce;
797
+ var me = "TooltipPortal", [nr, sr] = J(me, {
798
+ forceMount: void 0
799
+ }), xe = (e) => {
800
+ const { __scopeTooltip: r, forceMount: t, children: o, container: a } = e, c = $(me, r);
801
+ return /* @__PURE__ */ s.jsx(nr, { scope: r, forceMount: t, children: /* @__PURE__ */ s.jsx(le, { present: t || c.open, children: /* @__PURE__ */ s.jsx(ke, { asChild: !0, container: a, children: o }) }) });
802
+ };
803
+ xe.displayName = me;
804
+ var I = "TooltipContent", he = n.forwardRef(
805
+ (e, r) => {
806
+ const t = sr(I, e.__scopeTooltip), { forceMount: o = t.forceMount, side: a = "top", ...c } = e, l = $(I, e.__scopeTooltip);
807
+ return /* @__PURE__ */ s.jsx(le, { present: o || l.open, children: l.disableHoverableContent ? /* @__PURE__ */ s.jsx(Je, { side: a, ...c, ref: r }) : /* @__PURE__ */ s.jsx(ar, { side: a, ...c, ref: r }) });
808
+ }
809
+ ), ar = n.forwardRef((e, r) => {
810
+ const t = $(I, e.__scopeTooltip), o = ue(I, e.__scopeTooltip), a = n.useRef(null), c = G(r, a), [l, v] = n.useState(null), { trigger: d, onClose: i } = t, f = a.current, { onPointerInTransitChange: x } = o, b = n.useCallback(() => {
811
+ v(null), x(!1);
812
+ }, [x]), w = n.useCallback(
813
+ (T, p) => {
814
+ const u = T.currentTarget, y = { x: T.clientX, y: T.clientY }, h = lr(y, u.getBoundingClientRect()), g = dr(y, h), E = ur(p.getBoundingClientRect()), P = pr([...g, ...E]);
815
+ v(P), x(!0);
816
+ },
817
+ [x]
818
+ );
819
+ return n.useEffect(() => () => b(), [b]), n.useEffect(() => {
820
+ if (d && f) {
821
+ const T = (u) => w(u, f), p = (u) => w(u, d);
822
+ return d.addEventListener("pointerleave", T), f.addEventListener("pointerleave", p), () => {
823
+ d.removeEventListener("pointerleave", T), f.removeEventListener("pointerleave", p);
824
+ };
825
+ }
826
+ }, [d, f, w, b]), n.useEffect(() => {
827
+ if (l) {
828
+ const T = (p) => {
829
+ const u = p.target, y = { x: p.clientX, y: p.clientY }, h = (d == null ? void 0 : d.contains(u)) || (f == null ? void 0 : f.contains(u)), g = !fr(y, l);
830
+ h ? b() : g && (b(), i());
831
+ };
832
+ return document.addEventListener("pointermove", T), () => document.removeEventListener("pointermove", T);
833
+ }
834
+ }, [d, f, l, i, b]), /* @__PURE__ */ s.jsx(Je, { ...e, ref: c });
835
+ }), [ir, cr] = J(Z, { isInside: !1 }), Je = n.forwardRef(
836
+ (e, r) => {
837
+ const {
838
+ __scopeTooltip: t,
839
+ children: o,
840
+ "aria-label": a,
841
+ onEscapeKeyDown: c,
842
+ onPointerDownOutside: l,
843
+ ...v
844
+ } = e, d = $(I, t), i = Q(t), { onClose: f } = d;
845
+ return n.useEffect(() => (document.addEventListener(ie, f), () => document.removeEventListener(ie, f)), [f]), n.useEffect(() => {
846
+ if (d.trigger) {
847
+ const x = (b) => {
848
+ const w = b.target;
849
+ w != null && w.contains(d.trigger) && f();
850
+ };
851
+ return window.addEventListener("scroll", x, { capture: !0 }), () => window.removeEventListener("scroll", x, { capture: !0 });
852
+ }
853
+ }, [d.trigger, f]), /* @__PURE__ */ s.jsx(
854
+ ft,
855
+ {
856
+ asChild: !0,
857
+ disableOutsidePointerEvents: !1,
858
+ onEscapeKeyDown: c,
859
+ onPointerDownOutside: l,
860
+ onFocusOutside: (x) => x.preventDefault(),
861
+ onDismiss: f,
862
+ children: /* @__PURE__ */ s.jsxs(
863
+ pt,
864
+ {
865
+ "data-state": d.stateAttribute,
866
+ ...i,
867
+ ...v,
868
+ ref: r,
869
+ style: {
870
+ ...v.style,
871
+ "--radix-tooltip-content-transform-origin": "var(--radix-popper-transform-origin)",
872
+ "--radix-tooltip-content-available-width": "var(--radix-popper-available-width)",
873
+ "--radix-tooltip-content-available-height": "var(--radix-popper-available-height)",
874
+ "--radix-tooltip-trigger-width": "var(--radix-popper-anchor-width)",
875
+ "--radix-tooltip-trigger-height": "var(--radix-popper-anchor-height)"
876
+ },
877
+ children: [
878
+ /* @__PURE__ */ s.jsx(vt, { children: o }),
879
+ /* @__PURE__ */ s.jsx(ir, { scope: t, isInside: !0, children: /* @__PURE__ */ s.jsx(Nt, { id: d.contentId, role: "tooltip", children: a || o }) })
880
+ ]
881
+ }
882
+ )
883
+ }
884
+ );
885
+ }
886
+ );
887
+ he.displayName = I;
888
+ var Qe = "TooltipArrow", we = n.forwardRef(
889
+ (e, r) => {
890
+ const { __scopeTooltip: t, ...o } = e, a = Q(t);
891
+ return cr(
892
+ Qe,
893
+ t
894
+ ).isInside ? null : /* @__PURE__ */ s.jsx(ct, { ...a, ...o, ref: r });
895
+ }
896
+ );
897
+ we.displayName = Qe;
898
+ function lr(e, r) {
899
+ const t = Math.abs(r.top - e.y), o = Math.abs(r.bottom - e.y), a = Math.abs(r.right - e.x), c = Math.abs(r.left - e.x);
900
+ switch (Math.min(t, o, a, c)) {
901
+ case c:
902
+ return "left";
903
+ case a:
904
+ return "right";
905
+ case t:
906
+ return "top";
907
+ case o:
908
+ return "bottom";
909
+ default:
910
+ throw new Error("unreachable");
911
+ }
912
+ }
913
+ function dr(e, r, t = 5) {
914
+ const o = [];
915
+ switch (r) {
916
+ case "top":
917
+ o.push(
918
+ { x: e.x - t, y: e.y + t },
919
+ { x: e.x + t, y: e.y + t }
920
+ );
921
+ break;
922
+ case "bottom":
923
+ o.push(
924
+ { x: e.x - t, y: e.y - t },
925
+ { x: e.x + t, y: e.y - t }
926
+ );
927
+ break;
928
+ case "left":
929
+ o.push(
930
+ { x: e.x + t, y: e.y - t },
931
+ { x: e.x + t, y: e.y + t }
932
+ );
933
+ break;
934
+ case "right":
935
+ o.push(
936
+ { x: e.x - t, y: e.y - t },
937
+ { x: e.x - t, y: e.y + t }
938
+ );
939
+ break;
940
+ }
941
+ return o;
942
+ }
943
+ function ur(e) {
944
+ const { top: r, right: t, bottom: o, left: a } = e;
945
+ return [
946
+ { x: a, y: r },
947
+ { x: t, y: r },
948
+ { x: t, y: o },
949
+ { x: a, y: o }
950
+ ];
951
+ }
952
+ function fr(e, r) {
953
+ const { x: t, y: o } = e;
954
+ let a = !1;
955
+ for (let c = 0, l = r.length - 1; c < r.length; l = c++) {
956
+ const v = r[c].x, d = r[c].y, i = r[l].x, f = r[l].y;
957
+ d > o != f > o && t < (i - v) * (o - d) / (f - d) + v && (a = !a);
958
+ }
959
+ return a;
960
+ }
961
+ function pr(e) {
962
+ const r = e.slice();
963
+ return r.sort((t, o) => t.x < o.x ? -1 : t.x > o.x ? 1 : t.y < o.y ? -1 : t.y > o.y ? 1 : 0), vr(r);
964
+ }
965
+ function vr(e) {
966
+ if (e.length <= 1) return e.slice();
967
+ const r = [];
968
+ for (let o = 0; o < e.length; o++) {
969
+ const a = e[o];
970
+ for (; r.length >= 2; ) {
971
+ const c = r[r.length - 1], l = r[r.length - 2];
972
+ if ((c.x - l.x) * (a.y - l.y) >= (c.y - l.y) * (a.x - l.x)) r.pop();
973
+ else break;
974
+ }
975
+ r.push(a);
976
+ }
977
+ r.pop();
978
+ const t = [];
979
+ for (let o = e.length - 1; o >= 0; o--) {
980
+ const a = e[o];
981
+ for (; t.length >= 2; ) {
982
+ const c = t[t.length - 1], l = t[t.length - 2];
983
+ if ((c.x - l.x) * (a.y - l.y) >= (c.y - l.y) * (a.x - l.x)) t.pop();
984
+ else break;
985
+ }
986
+ t.push(a);
987
+ }
988
+ return t.pop(), r.length === 1 && t.length === 1 && r[0].x === t[0].x && r[0].y === t[0].y ? r : r.concat(t);
989
+ }
990
+ var mr = fe, xr = pe, hr = ve, wr = xe, gr = he, br = we;
991
+ const Tr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
992
+ __proto__: null,
993
+ Arrow: br,
994
+ Content: gr,
995
+ Portal: wr,
996
+ Provider: mr,
997
+ Root: xr,
998
+ Tooltip: pe,
999
+ TooltipArrow: we,
1000
+ TooltipContent: he,
1001
+ TooltipPortal: xe,
1002
+ TooltipProvider: fe,
1003
+ TooltipTrigger: ve,
1004
+ Trigger: hr,
1005
+ createTooltipScope: er
1006
+ }, Symbol.toStringTag, { value: "Module" })), { Provider: yr, Root: Er, Trigger: Cr, Portal: Pr, Content: Rr, Arrow: kr } = Tr, Ir = ({
1007
+ children: e,
1008
+ className: r,
1009
+ defaultOpen: t,
1010
+ side: o,
1011
+ content: a,
1012
+ delayDuration: c = 0
1013
+ }) => /* @__PURE__ */ s.jsx(yr, { children: /* @__PURE__ */ s.jsxs(Er, { defaultOpen: t, delayDuration: c, children: [
1014
+ /* @__PURE__ */ s.jsx(Cr, { asChild: !0, children: /* @__PURE__ */ s.jsx("div", { children: e }) }),
1015
+ /* @__PURE__ */ s.jsx(Pr, { children: /* @__PURE__ */ s.jsxs(
1016
+ Rr,
1017
+ {
1018
+ side: o,
1019
+ sideOffset: 5,
1020
+ className: C(Ce.content, r),
1021
+ children: [
1022
+ a,
1023
+ /* @__PURE__ */ s.jsx(kr, { className: Ce.arrow })
1024
+ ]
1025
+ }
1026
+ ) })
1027
+ ] }) }), Ce = {
1028
+ content: C(
1029
+ "font-mono select-none w-auto h-auto max-size-32 rounded-[5px] bg-dark-30 px-4 py-2 text-[10px] text-start leading-none text-sidebar-10 z-50",
1030
+ "animate-tooltipFade data-[state=delayed-open]:data-[side=bottom]:animate-slideUpAndFade",
1031
+ "data-[state=delayed-open]:data-[side=left]:animate-slideRightAndFade",
1032
+ "data-[state=delayed-open]:data-[side=right]:animate-slideLeftAndFade",
1033
+ "data-[state=delayed-open]:data-[side=top]:animate-slideDownAndFade"
1034
+ ),
1035
+ arrow: "fill-dark-30"
1036
+ }, Fr = ({
1037
+ value: e,
1038
+ onValueChange: r,
1039
+ classNames: t = {},
1040
+ count: o = 3,
1041
+ ...a
1042
+ }) => /* @__PURE__ */ s.jsx(mt, { value: e, onValueChange: r, children: /* @__PURE__ */ s.jsx(
1043
+ xt,
1044
+ {
1045
+ className: C(oe.container, t.container),
1046
+ ...a,
1047
+ children: Array.from({ length: o }).map((c, l) => /* @__PURE__ */ s.jsx(
1048
+ ht,
1049
+ {
1050
+ value: String(l),
1051
+ className: C(
1052
+ oe.dot,
1053
+ l <= Number(e) && oe.dotActive,
1054
+ t.trigger
1055
+ )
1056
+ },
1057
+ l
1058
+ ))
1059
+ }
1060
+ ) }), oe = {
1061
+ container: "flex items-center gap-1",
1062
+ dot: "size-2 rounded-full bg-dark-30/[.20] transition-colors focus:outline-none focus:ring-offset-0 focus:ring-primary-10",
1063
+ dotActive: "bg-primary-10"
1064
+ };
1065
+ export {
1066
+ Dr as N,
1067
+ Or as S,
1068
+ Lr as T,
1069
+ Ir as a,
1070
+ Ce as b,
1071
+ Fr as c,
1072
+ oe as d,
1073
+ D as s,
1074
+ H as t
1075
+ };