@orbe-agro/client-core 5.3.86 → 5.3.89

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 (502) hide show
  1. package/dist/@ecme/assets/styles/app.css +1 -1
  2. package/dist/@ecme/assets/styles/components/_dialog.css +1 -1
  3. package/dist/@ecme/assets/styles/components/_drawer.css +1 -1
  4. package/dist/@ecme/assets/styles/components/_scrollbar.css +1 -1
  5. package/dist/@ecme/assets/styles/components/_switcher.css +1 -1
  6. package/dist/@ecme/assets/styles/components/_upload.css +1 -1
  7. package/dist/@ecme/assets/styles/components/index.css +1 -1
  8. package/dist/@ecme/assets/styles/tailwind/index.css +1 -1
  9. package/dist/@ecme/auth/AuthProvider.js +58 -62
  10. package/dist/@ecme/auth/AuthProvider.js.map +1 -1
  11. package/dist/@ecme/components/docs/DemoCard/DemoCard.js +18 -19
  12. package/dist/@ecme/components/docs/DemoCard/DemoCard.js.map +1 -1
  13. package/dist/@ecme/components/layouts/PostLoginLayout/PostLoginLayout.js +29 -30
  14. package/dist/@ecme/components/layouts/PostLoginLayout/PostLoginLayout.js.map +1 -1
  15. package/dist/@ecme/components/layouts/PostLoginLayout/components/ContentOverlay.js +56 -56
  16. package/dist/@ecme/components/layouts/PostLoginLayout/components/ContentOverlay.js.map +1 -1
  17. package/dist/@ecme/components/shared/Affix.js +9 -10
  18. package/dist/@ecme/components/shared/Affix.js.map +1 -1
  19. package/dist/@ecme/components/shared/AutoComplete.js +27 -28
  20. package/dist/@ecme/components/shared/AutoComplete.js.map +1 -1
  21. package/dist/@ecme/components/shared/CalendarView.js +19 -20
  22. package/dist/@ecme/components/shared/CalendarView.js.map +1 -1
  23. package/dist/@ecme/components/shared/ConfirmDialog.js +16 -16
  24. package/dist/@ecme/components/shared/ConfirmDialog.js.map +1 -1
  25. package/dist/@ecme/components/shared/DataTable.js +151 -151
  26. package/dist/@ecme/components/shared/DataTable.js.map +1 -1
  27. package/dist/@ecme/components/shared/DebounceInput.js +11 -12
  28. package/dist/@ecme/components/shared/DebounceInput.js.map +1 -1
  29. package/dist/@ecme/components/shared/GanttChart/GanttChart.js +20 -20
  30. package/dist/@ecme/components/shared/GanttChart/GanttChart.js.map +1 -1
  31. package/dist/@ecme/components/shared/GanttChart/TaskListTable.js +22 -22
  32. package/dist/@ecme/components/shared/GanttChart/TaskListTable.js.map +1 -1
  33. package/dist/@ecme/components/shared/ImageGallery.js +18 -18
  34. package/dist/@ecme/components/shared/ImageGallery.js.map +1 -1
  35. package/dist/@ecme/components/shared/Masonry/Masonry.js +25 -25
  36. package/dist/@ecme/components/shared/Masonry/Masonry.js.map +1 -1
  37. package/dist/@ecme/components/shared/OtpInput.js +54 -56
  38. package/dist/@ecme/components/shared/OtpInput.js.map +1 -1
  39. package/dist/@ecme/components/shared/PasswordInput.js +6 -6
  40. package/dist/@ecme/components/shared/PasswordInput.js.map +1 -1
  41. package/dist/@ecme/components/shared/RegionMap.js +9 -9
  42. package/dist/@ecme/components/shared/RegionMap.js.map +1 -1
  43. package/dist/@ecme/components/shared/RichTextEditor/RichTextEditor.js +47 -47
  44. package/dist/@ecme/components/shared/RichTextEditor/RichTextEditor.js.map +1 -1
  45. package/dist/@ecme/components/shared/UsersAvatarGroup.js +24 -24
  46. package/dist/@ecme/components/shared/UsersAvatarGroup.js.map +1 -1
  47. package/dist/@ecme/components/template/HorizontalMenuContent/HorizontalMenuContent.js +63 -69
  48. package/dist/@ecme/components/template/HorizontalMenuContent/HorizontalMenuContent.js.map +1 -1
  49. package/dist/@ecme/components/template/HorizontalMenuContent/HorizontalMenuDropdown.js +48 -48
  50. package/dist/@ecme/components/template/HorizontalMenuContent/HorizontalMenuDropdown.js.map +1 -1
  51. package/dist/@ecme/components/template/HorizontalMenuContent/HorizontalMenuDropdownContent.js +220 -231
  52. package/dist/@ecme/components/template/HorizontalMenuContent/HorizontalMenuDropdownContent.js.map +1 -1
  53. package/dist/@ecme/components/template/LanguageSelector.js +10 -13
  54. package/dist/@ecme/components/template/LanguageSelector.js.map +1 -1
  55. package/dist/@ecme/components/template/Search.js +85 -92
  56. package/dist/@ecme/components/template/Search.js.map +1 -1
  57. package/dist/@ecme/components/template/ThemeConfigurator/DirectionSwitcher.js +18 -18
  58. package/dist/@ecme/components/template/ThemeConfigurator/DirectionSwitcher.js.map +1 -1
  59. package/dist/@ecme/components/template/VerticalMenuContent/VerticalCollapsedMenuItem.js +17 -17
  60. package/dist/@ecme/components/template/VerticalMenuContent/VerticalCollapsedMenuItem.js.map +1 -1
  61. package/dist/@ecme/components/template/VerticalMenuContent/VerticalMenuContent.js +59 -59
  62. package/dist/@ecme/components/template/VerticalMenuContent/VerticalMenuContent.js.map +1 -1
  63. package/dist/@ecme/components/template/VerticalMenuContent/VerticalSingleMenuItem.js +34 -34
  64. package/dist/@ecme/components/template/VerticalMenuContent/VerticalSingleMenuItem.js.map +1 -1
  65. package/dist/@ecme/components/ui/Alert/Alert.js +29 -29
  66. package/dist/@ecme/components/ui/Alert/Alert.js.map +1 -1
  67. package/dist/@ecme/components/ui/Avatar/AvatarGroup.js +30 -30
  68. package/dist/@ecme/components/ui/Avatar/AvatarGroup.js.map +1 -1
  69. package/dist/@ecme/components/ui/Button/Button.js +66 -67
  70. package/dist/@ecme/components/ui/Button/Button.js.map +1 -1
  71. package/dist/@ecme/components/ui/Card/Card.js +39 -40
  72. package/dist/@ecme/components/ui/Card/Card.js.map +1 -1
  73. package/dist/@ecme/components/ui/Checkbox/Checkbox.js +42 -42
  74. package/dist/@ecme/components/ui/Checkbox/Checkbox.js.map +1 -1
  75. package/dist/@ecme/components/ui/Checkbox/Group.js +27 -27
  76. package/dist/@ecme/components/ui/Checkbox/Group.js.map +1 -1
  77. package/dist/@ecme/components/ui/DatePicker/BasePicker.js +67 -67
  78. package/dist/@ecme/components/ui/DatePicker/BasePicker.js.map +1 -1
  79. package/dist/@ecme/components/ui/DatePicker/Calendar.js +18 -18
  80. package/dist/@ecme/components/ui/DatePicker/Calendar.js.map +1 -1
  81. package/dist/@ecme/components/ui/DatePicker/CalendarBase.js +77 -78
  82. package/dist/@ecme/components/ui/DatePicker/CalendarBase.js.map +1 -1
  83. package/dist/@ecme/components/ui/DatePicker/DatePicker.js +67 -71
  84. package/dist/@ecme/components/ui/DatePicker/DatePicker.js.map +1 -1
  85. package/dist/@ecme/components/ui/DatePicker/DatePickerRange.js +94 -98
  86. package/dist/@ecme/components/ui/DatePicker/DatePickerRange.js.map +1 -1
  87. package/dist/@ecme/components/ui/DatePicker/DateTimepicker.js +51 -58
  88. package/dist/@ecme/components/ui/DatePicker/DateTimepicker.js.map +1 -1
  89. package/dist/@ecme/components/ui/DatePicker/tables/DateTable.js +67 -67
  90. package/dist/@ecme/components/ui/DatePicker/tables/DateTable.js.map +1 -1
  91. package/dist/@ecme/components/ui/DatePicker/tables/components/Day.js +12 -12
  92. package/dist/@ecme/components/ui/DatePicker/tables/components/Day.js.map +1 -1
  93. package/dist/@ecme/components/ui/Dialog/Dialog.js +25 -25
  94. package/dist/@ecme/components/ui/Dialog/Dialog.js.map +1 -1
  95. package/dist/@ecme/components/ui/Drawer/Drawer.js +32 -32
  96. package/dist/@ecme/components/ui/Drawer/Drawer.js.map +1 -1
  97. package/dist/@ecme/components/ui/Dropdown/DropdownItem.js +58 -58
  98. package/dist/@ecme/components/ui/Dropdown/DropdownItem.js.map +1 -1
  99. package/dist/@ecme/components/ui/Dropdown/DropdownMenu.js +99 -100
  100. package/dist/@ecme/components/ui/Dropdown/DropdownMenu.js.map +1 -1
  101. package/dist/@ecme/components/ui/Dropdown/DropdownSubItem.js +26 -26
  102. package/dist/@ecme/components/ui/Dropdown/DropdownSubItem.js.map +1 -1
  103. package/dist/@ecme/components/ui/Form/FormContainer.js +17 -17
  104. package/dist/@ecme/components/ui/Form/FormContainer.js.map +1 -1
  105. package/dist/@ecme/components/ui/Form/FormItem.js +38 -38
  106. package/dist/@ecme/components/ui/Form/FormItem.js.map +1 -1
  107. package/dist/@ecme/components/ui/Input/Input.js +50 -52
  108. package/dist/@ecme/components/ui/Input/Input.js.map +1 -1
  109. package/dist/@ecme/components/ui/InputGroup/Addon.js +12 -13
  110. package/dist/@ecme/components/ui/InputGroup/Addon.js.map +1 -1
  111. package/dist/@ecme/components/ui/InputGroup/InputGroup.js +10 -11
  112. package/dist/@ecme/components/ui/InputGroup/InputGroup.js.map +1 -1
  113. package/dist/@ecme/components/ui/Notification/Notification.js +19 -19
  114. package/dist/@ecme/components/ui/Notification/Notification.js.map +1 -1
  115. package/dist/@ecme/components/ui/Pagination/Pagination.js +45 -45
  116. package/dist/@ecme/components/ui/Pagination/Pagination.js.map +1 -1
  117. package/dist/@ecme/components/ui/Radio/Group.js +28 -28
  118. package/dist/@ecme/components/ui/Radio/Group.js.map +1 -1
  119. package/dist/@ecme/components/ui/Radio/Radio.js +42 -42
  120. package/dist/@ecme/components/ui/Radio/Radio.js.map +1 -1
  121. package/dist/@ecme/components/ui/Segment/SegmentItem.js +53 -53
  122. package/dist/@ecme/components/ui/Segment/SegmentItem.js.map +1 -1
  123. package/dist/@ecme/components/ui/Select/Select.js +40 -41
  124. package/dist/@ecme/components/ui/Select/Select.js.map +1 -1
  125. package/dist/@ecme/components/ui/Steps/StepItem.js +33 -33
  126. package/dist/@ecme/components/ui/Steps/StepItem.js.map +1 -1
  127. package/dist/@ecme/components/ui/Switcher/Switcher.js +24 -24
  128. package/dist/@ecme/components/ui/Switcher/Switcher.js.map +1 -1
  129. package/dist/@ecme/components/ui/Tabs/TabNav.js +22 -22
  130. package/dist/@ecme/components/ui/Tabs/TabNav.js.map +1 -1
  131. package/dist/@ecme/components/ui/TimeInput/AmPmInput.js +25 -27
  132. package/dist/@ecme/components/ui/TimeInput/AmPmInput.js.map +1 -1
  133. package/dist/@ecme/components/ui/TimeInput/TimeInput.js +130 -135
  134. package/dist/@ecme/components/ui/TimeInput/TimeInput.js.map +1 -1
  135. package/dist/@ecme/components/ui/TimeInput/TimeInputField.js +22 -24
  136. package/dist/@ecme/components/ui/TimeInput/TimeInputField.js.map +1 -1
  137. package/dist/@ecme/components/ui/TimeInput/TimeInputRange.js +65 -68
  138. package/dist/@ecme/components/ui/TimeInput/TimeInputRange.js.map +1 -1
  139. package/dist/@ecme/components/ui/TimeInput/utils/createAmPmHandler.js +11 -12
  140. package/dist/@ecme/components/ui/TimeInput/utils/createAmPmHandler.js.map +1 -1
  141. package/dist/@ecme/components/ui/TimeInput/utils/createTimeHandler.js +19 -20
  142. package/dist/@ecme/components/ui/TimeInput/utils/createTimeHandler.js.map +1 -1
  143. package/dist/@ecme/components/ui/Upload/Upload.js +67 -68
  144. package/dist/@ecme/components/ui/Upload/Upload.js.map +1 -1
  145. package/dist/@ecme/components/ui/hooks/useCallbackRef.js +7 -10
  146. package/dist/@ecme/components/ui/hooks/useCallbackRef.js.map +1 -1
  147. package/dist/@ecme/components/ui/hooks/useRootClose.js +32 -32
  148. package/dist/@ecme/components/ui/hooks/useRootClose.js.map +1 -1
  149. package/dist/@ecme/components/ui/hooks/useTimeout.js +12 -13
  150. package/dist/@ecme/components/ui/hooks/useTimeout.js.map +1 -1
  151. package/dist/@ecme/components/ui/toast/ToastWrapper.js +58 -61
  152. package/dist/@ecme/components/ui/toast/ToastWrapper.js.map +1 -1
  153. package/dist/@ecme/components/ui/toast/toast.js +16 -19
  154. package/dist/@ecme/components/ui/toast/toast.js.map +1 -1
  155. package/dist/@ecme/components/view/Activity/ActivityEvent.js +63 -67
  156. package/dist/@ecme/components/view/Activity/ActivityEvent.js.map +1 -1
  157. package/dist/@ecme/components/view/ChatBox/components/Attachment.js +8 -9
  158. package/dist/@ecme/components/view/ChatBox/components/Attachment.js.map +1 -1
  159. package/dist/@ecme/components/view/ChatBox/components/ChatInput.js +37 -39
  160. package/dist/@ecme/components/view/ChatBox/components/ChatInput.js.map +1 -1
  161. package/dist/@ecme/components/view/ChatBox/components/Message.js +10 -10
  162. package/dist/@ecme/components/view/ChatBox/components/Message.js.map +1 -1
  163. package/dist/@ecme/components/view/CreditCardDialog/CreditCardDialog.js +36 -37
  164. package/dist/@ecme/components/view/CreditCardDialog/CreditCardDialog.js.map +1 -1
  165. package/dist/@ecme/components/view/TaskItem/TaskItem.js +33 -33
  166. package/dist/@ecme/components/view/TaskItem/TaskItem.js.map +1 -1
  167. package/dist/@ecme/mock/fakeApi/chatFakeApi.js +16 -18
  168. package/dist/@ecme/mock/fakeApi/chatFakeApi.js.map +1 -1
  169. package/dist/@ecme/mock/fakeApi/customersFakeApi.js +10 -11
  170. package/dist/@ecme/mock/fakeApi/customersFakeApi.js.map +1 -1
  171. package/dist/@ecme/mock/fakeApi/helpCenterFakeApi.js +10 -11
  172. package/dist/@ecme/mock/fakeApi/helpCenterFakeApi.js.map +1 -1
  173. package/dist/@ecme/mock/fakeApi/mailFakeApi.js +9 -10
  174. package/dist/@ecme/mock/fakeApi/mailFakeApi.js.map +1 -1
  175. package/dist/@ecme/mock/fakeApi/ordersFakeApi.js +9 -10
  176. package/dist/@ecme/mock/fakeApi/ordersFakeApi.js.map +1 -1
  177. package/dist/@ecme/mock/fakeApi/productsFakeApi.js +7 -8
  178. package/dist/@ecme/mock/fakeApi/productsFakeApi.js.map +1 -1
  179. package/dist/@ecme/mock/fakeApi/projectsFakeApi.js +10 -11
  180. package/dist/@ecme/mock/fakeApi/projectsFakeApi.js.map +1 -1
  181. package/dist/@ecme/utils/hooks/useInfiniteScroll.js +11 -11
  182. package/dist/@ecme/utils/hooks/useInfiniteScroll.js.map +1 -1
  183. package/dist/@ecme/utils/hooks/useMenuActive.js +11 -12
  184. package/dist/@ecme/utils/hooks/useMenuActive.js.map +1 -1
  185. package/dist/@ecme/views/auth/ForgotPassword/components/ForgotPasswordForm.js +36 -37
  186. package/dist/@ecme/views/auth/ForgotPassword/components/ForgotPasswordForm.js.map +1 -1
  187. package/dist/@ecme/views/auth/OtpVerification/OtpVerification.js +14 -14
  188. package/dist/@ecme/views/auth/OtpVerification/OtpVerification.js.map +1 -1
  189. package/dist/@ecme/views/auth/OtpVerification/components/OtpVerificationForm.js +41 -42
  190. package/dist/@ecme/views/auth/OtpVerification/components/OtpVerificationForm.js.map +1 -1
  191. package/dist/@ecme/views/auth/ResetPassword/components/ResetPasswordForm.js +59 -60
  192. package/dist/@ecme/views/auth/ResetPassword/components/ResetPasswordForm.js.map +1 -1
  193. package/dist/@ecme/views/auth/SignIn/components/OauthSignIn.js +27 -27
  194. package/dist/@ecme/views/auth/SignIn/components/OauthSignIn.js.map +1 -1
  195. package/dist/@ecme/views/auth/SignIn/components/SignInForm.js +57 -58
  196. package/dist/@ecme/views/auth/SignIn/components/SignInForm.js.map +1 -1
  197. package/dist/@ecme/views/auth/SignUp/components/SignUpForm.js +37 -38
  198. package/dist/@ecme/views/auth/SignUp/components/SignUpForm.js.map +1 -1
  199. package/dist/@ecme/views/concepts/accounts/Pricing/components/PaymentDialog.js +44 -45
  200. package/dist/@ecme/views/concepts/accounts/Pricing/components/PaymentDialog.js.map +1 -1
  201. package/dist/@ecme/views/concepts/accounts/Pricing/components/Plans.js +5 -5
  202. package/dist/@ecme/views/concepts/accounts/Pricing/components/Plans.js.map +1 -1
  203. package/dist/@ecme/views/concepts/accounts/RolesPermissions/components/RolesPermissionsAccessDialog.js +34 -35
  204. package/dist/@ecme/views/concepts/accounts/RolesPermissions/components/RolesPermissionsAccessDialog.js.map +1 -1
  205. package/dist/@ecme/views/concepts/accounts/RolesPermissions/components/RolesPermissionsUserAction.js +26 -26
  206. package/dist/@ecme/views/concepts/accounts/RolesPermissions/components/RolesPermissionsUserAction.js.map +1 -1
  207. package/dist/@ecme/views/concepts/accounts/RolesPermissions/components/RolesPermissionsUserTable.js +28 -29
  208. package/dist/@ecme/views/concepts/accounts/RolesPermissions/components/RolesPermissionsUserTable.js.map +1 -1
  209. package/dist/@ecme/views/concepts/accounts/RolesPermissions/hooks/useRolePermissonsUsers.js +8 -8
  210. package/dist/@ecme/views/concepts/accounts/RolesPermissions/hooks/useRolePermissonsUsers.js.map +1 -1
  211. package/dist/@ecme/views/concepts/accounts/Settings/components/SettingMobileMenu.js +10 -11
  212. package/dist/@ecme/views/concepts/accounts/Settings/components/SettingMobileMenu.js.map +1 -1
  213. package/dist/@ecme/views/concepts/accounts/Settings/components/SettingsBilling.js +48 -49
  214. package/dist/@ecme/views/concepts/accounts/Settings/components/SettingsBilling.js.map +1 -1
  215. package/dist/@ecme/views/concepts/accounts/Settings/components/SettingsMenu.js +14 -14
  216. package/dist/@ecme/views/concepts/accounts/Settings/components/SettingsMenu.js.map +1 -1
  217. package/dist/@ecme/views/concepts/accounts/Settings/components/SettingsProfile.js +102 -103
  218. package/dist/@ecme/views/concepts/accounts/Settings/components/SettingsProfile.js.map +1 -1
  219. package/dist/@ecme/views/concepts/accounts/Settings/components/SettingsSecurity.js +34 -35
  220. package/dist/@ecme/views/concepts/accounts/Settings/components/SettingsSecurity.js.map +1 -1
  221. package/dist/@ecme/views/concepts/ai/Chat/components/ChatCustomAction.js +16 -16
  222. package/dist/@ecme/views/concepts/ai/Chat/components/ChatCustomAction.js.map +1 -1
  223. package/dist/@ecme/views/concepts/ai/Chat/components/ChatCustomContent.js +76 -78
  224. package/dist/@ecme/views/concepts/ai/Chat/components/ChatCustomContent.js.map +1 -1
  225. package/dist/@ecme/views/concepts/ai/Chat/components/ChatHistory.js +23 -23
  226. package/dist/@ecme/views/concepts/ai/Chat/components/ChatHistory.js.map +1 -1
  227. package/dist/@ecme/views/concepts/ai/Chat/components/ChatHistoryItem.js +48 -49
  228. package/dist/@ecme/views/concepts/ai/Chat/components/ChatHistoryItem.js.map +1 -1
  229. package/dist/@ecme/views/concepts/ai/Chat/components/ChatHistoryRenameDialog.js +34 -35
  230. package/dist/@ecme/views/concepts/ai/Chat/components/ChatHistoryRenameDialog.js.map +1 -1
  231. package/dist/@ecme/views/concepts/ai/Chat/components/ChatMobileNav.js +11 -14
  232. package/dist/@ecme/views/concepts/ai/Chat/components/ChatMobileNav.js.map +1 -1
  233. package/dist/@ecme/views/concepts/ai/Chat/components/ChatSideNav.js +19 -19
  234. package/dist/@ecme/views/concepts/ai/Chat/components/ChatSideNav.js.map +1 -1
  235. package/dist/@ecme/views/concepts/ai/Chat/components/ChatView.js +22 -26
  236. package/dist/@ecme/views/concepts/ai/Chat/components/ChatView.js.map +1 -1
  237. package/dist/@ecme/views/concepts/ai/Chat/store/generativeChatStore.js +18 -24
  238. package/dist/@ecme/views/concepts/ai/Chat/store/generativeChatStore.js.map +1 -1
  239. package/dist/@ecme/views/concepts/ai/Image/components/ConfigDropdown.js +22 -22
  240. package/dist/@ecme/views/concepts/ai/Image/components/ConfigDropdown.js.map +1 -1
  241. package/dist/@ecme/views/concepts/ai/Image/components/GeneratorPrompt.js +31 -32
  242. package/dist/@ecme/views/concepts/ai/Image/components/GeneratorPrompt.js.map +1 -1
  243. package/dist/@ecme/views/concepts/ai/Image/components/ImageDialog.js +31 -32
  244. package/dist/@ecme/views/concepts/ai/Image/components/ImageDialog.js.map +1 -1
  245. package/dist/@ecme/views/concepts/calendar/Calendar/Calendar.js +38 -39
  246. package/dist/@ecme/views/concepts/calendar/Calendar/Calendar.js.map +1 -1
  247. package/dist/@ecme/views/concepts/calendar/Calendar/components/EventDialog.js +68 -69
  248. package/dist/@ecme/views/concepts/calendar/Calendar/components/EventDialog.js.map +1 -1
  249. package/dist/@ecme/views/concepts/chat/Chat/components/ChatBody.js +63 -66
  250. package/dist/@ecme/views/concepts/chat/Chat/components/ChatBody.js.map +1 -1
  251. package/dist/@ecme/views/concepts/chat/Chat/components/ChatList.js +21 -22
  252. package/dist/@ecme/views/concepts/chat/Chat/components/ChatList.js.map +1 -1
  253. package/dist/@ecme/views/concepts/chat/Chat/components/ContactInfoDrawer.js +84 -85
  254. package/dist/@ecme/views/concepts/chat/Chat/components/ContactInfoDrawer.js.map +1 -1
  255. package/dist/@ecme/views/concepts/customers/CustomerDetails/ActivitySection.js +19 -19
  256. package/dist/@ecme/views/concepts/customers/CustomerDetails/ActivitySection.js.map +1 -1
  257. package/dist/@ecme/views/concepts/customers/CustomerDetails/BillingSection.js +51 -58
  258. package/dist/@ecme/views/concepts/customers/CustomerDetails/BillingSection.js.map +1 -1
  259. package/dist/@ecme/views/concepts/customers/CustomerDetails/ProfileSection.js +76 -89
  260. package/dist/@ecme/views/concepts/customers/CustomerDetails/ProfileSection.js.map +1 -1
  261. package/dist/@ecme/views/concepts/customers/CustomerForm/AddressSection.js +104 -107
  262. package/dist/@ecme/views/concepts/customers/CustomerForm/AddressSection.js.map +1 -1
  263. package/dist/@ecme/views/concepts/customers/CustomerForm/CustomerForm.js +22 -22
  264. package/dist/@ecme/views/concepts/customers/CustomerForm/CustomerForm.js.map +1 -1
  265. package/dist/@ecme/views/concepts/customers/CustomerForm/OverviewSection.js +38 -39
  266. package/dist/@ecme/views/concepts/customers/CustomerForm/OverviewSection.js.map +1 -1
  267. package/dist/@ecme/views/concepts/customers/CustomerList/hooks/useCustomerList.js +20 -20
  268. package/dist/@ecme/views/concepts/customers/CustomerList/hooks/useCustomerList.js.map +1 -1
  269. package/dist/@ecme/views/concepts/files/FileManager/components/FileItemDropdown.js +32 -33
  270. package/dist/@ecme/views/concepts/files/FileManager/components/FileItemDropdown.js.map +1 -1
  271. package/dist/@ecme/views/concepts/help-center/EditArticle/components/EditArticleHeader.js +17 -18
  272. package/dist/@ecme/views/concepts/help-center/EditArticle/components/EditArticleHeader.js.map +1 -1
  273. package/dist/@ecme/views/concepts/help-center/ManageArticle/hooks/useManageArticle.js +5 -5
  274. package/dist/@ecme/views/concepts/help-center/ManageArticle/hooks/useManageArticle.js.map +1 -1
  275. package/dist/@ecme/views/concepts/help-center/SupportHub/components/TopSection.js +12 -13
  276. package/dist/@ecme/views/concepts/help-center/SupportHub/components/TopSection.js.map +1 -1
  277. package/dist/@ecme/views/concepts/mail/Mail/components/MailDetailAction.js +28 -29
  278. package/dist/@ecme/views/concepts/mail/Mail/components/MailDetailAction.js.map +1 -1
  279. package/dist/@ecme/views/concepts/mail/Mail/components/MailDetailContent.js +63 -67
  280. package/dist/@ecme/views/concepts/mail/Mail/components/MailDetailContent.js.map +1 -1
  281. package/dist/@ecme/views/concepts/mail/Mail/components/MailDetailTitle.js +8 -8
  282. package/dist/@ecme/views/concepts/mail/Mail/components/MailDetailTitle.js.map +1 -1
  283. package/dist/@ecme/views/concepts/mail/Mail/components/MailEditor.js +36 -37
  284. package/dist/@ecme/views/concepts/mail/Mail/components/MailEditor.js.map +1 -1
  285. package/dist/@ecme/views/concepts/mail/Mail/components/MailList.js +134 -137
  286. package/dist/@ecme/views/concepts/mail/Mail/components/MailList.js.map +1 -1
  287. package/dist/@ecme/views/concepts/orders/OrderDetails/components/OrderDetailProducts.js +17 -17
  288. package/dist/@ecme/views/concepts/orders/OrderDetails/components/OrderDetailProducts.js.map +1 -1
  289. package/dist/@ecme/views/concepts/orders/OrderEdit/OrderEdit.js +35 -35
  290. package/dist/@ecme/views/concepts/orders/OrderEdit/OrderEdit.js.map +1 -1
  291. package/dist/@ecme/views/concepts/orders/OrderForm/OrderForm.js +38 -38
  292. package/dist/@ecme/views/concepts/orders/OrderForm/OrderForm.js.map +1 -1
  293. package/dist/@ecme/views/concepts/orders/OrderForm/components/BillingAddressSection.js +108 -111
  294. package/dist/@ecme/views/concepts/orders/OrderForm/components/BillingAddressSection.js.map +1 -1
  295. package/dist/@ecme/views/concepts/orders/OrderForm/components/CustomerDetailSection.js +44 -45
  296. package/dist/@ecme/views/concepts/orders/OrderForm/components/CustomerDetailSection.js.map +1 -1
  297. package/dist/@ecme/views/concepts/orders/OrderForm/components/PaymentMethodSection.js +211 -214
  298. package/dist/@ecme/views/concepts/orders/OrderForm/components/PaymentMethodSection.js.map +1 -1
  299. package/dist/@ecme/views/concepts/orders/OrderList/components/OrderListTableFilter.js +17 -17
  300. package/dist/@ecme/views/concepts/orders/OrderList/components/OrderListTableFilter.js.map +1 -1
  301. package/dist/@ecme/views/concepts/orders/OrderList/hooks/useOrderlist.js +15 -15
  302. package/dist/@ecme/views/concepts/orders/OrderList/hooks/useOrderlist.js.map +1 -1
  303. package/dist/@ecme/views/concepts/products/ProductForm/ProductForm.js +4 -4
  304. package/dist/@ecme/views/concepts/products/ProductForm/ProductForm.js.map +1 -1
  305. package/dist/@ecme/views/concepts/products/ProductForm/components/AttributeSection.js +97 -100
  306. package/dist/@ecme/views/concepts/products/ProductForm/components/AttributeSection.js.map +1 -1
  307. package/dist/@ecme/views/concepts/products/ProductForm/components/GeneralSection.js +68 -71
  308. package/dist/@ecme/views/concepts/products/ProductForm/components/GeneralSection.js.map +1 -1
  309. package/dist/@ecme/views/concepts/products/ProductForm/components/ImageSection.js +85 -86
  310. package/dist/@ecme/views/concepts/products/ProductForm/components/ImageSection.js.map +1 -1
  311. package/dist/@ecme/views/concepts/products/ProductForm/components/PricingSection.js +121 -124
  312. package/dist/@ecme/views/concepts/products/ProductForm/components/PricingSection.js.map +1 -1
  313. package/dist/@ecme/views/concepts/products/ProductList/components/ProductListSearch.js +11 -11
  314. package/dist/@ecme/views/concepts/products/ProductList/components/ProductListSearch.js.map +1 -1
  315. package/dist/@ecme/views/concepts/products/ProductList/components/ProductTableFilter.js +17 -17
  316. package/dist/@ecme/views/concepts/products/ProductList/components/ProductTableFilter.js.map +1 -1
  317. package/dist/@ecme/views/concepts/products/ProductList/hooks/useProductList.js +17 -17
  318. package/dist/@ecme/views/concepts/products/ProductList/hooks/useProductList.js.map +1 -1
  319. package/dist/@ecme/views/concepts/projects/Issue/components/IssueBody.js +101 -105
  320. package/dist/@ecme/views/concepts/projects/Issue/components/IssueBody.js.map +1 -1
  321. package/dist/@ecme/views/concepts/projects/Issue/components/IssueFooter.js +57 -58
  322. package/dist/@ecme/views/concepts/projects/Issue/components/IssueFooter.js.map +1 -1
  323. package/dist/@ecme/views/concepts/projects/ProjectDetails/components/ProjectDetailsHeader.js +51 -52
  324. package/dist/@ecme/views/concepts/projects/ProjectDetails/components/ProjectDetailsHeader.js.map +1 -1
  325. package/dist/@ecme/views/concepts/projects/ProjectDetails/components/ProjectDetailsOverview.js +22 -23
  326. package/dist/@ecme/views/concepts/projects/ProjectDetails/components/ProjectDetailsOverview.js.map +1 -1
  327. package/dist/@ecme/views/concepts/projects/ProjectDetails/components/ProjectDetailsSetting.js +45 -46
  328. package/dist/@ecme/views/concepts/projects/ProjectDetails/components/ProjectDetailsSetting.js.map +1 -1
  329. package/dist/@ecme/views/concepts/projects/ProjectDetails/components/ProjectDetailsTask.js +62 -65
  330. package/dist/@ecme/views/concepts/projects/ProjectDetails/components/ProjectDetailsTask.js.map +1 -1
  331. package/dist/@ecme/views/concepts/projects/ProjectList/components/NewProjectForm.js +52 -53
  332. package/dist/@ecme/views/concepts/projects/ProjectList/components/NewProjectForm.js.map +1 -1
  333. package/dist/@ecme/views/concepts/projects/ProjectList/components/NewTaskField.js +23 -25
  334. package/dist/@ecme/views/concepts/projects/ProjectList/components/NewTaskField.js.map +1 -1
  335. package/dist/@ecme/views/concepts/projects/ProjectList/components/ProjectListContent.js +15 -15
  336. package/dist/@ecme/views/concepts/projects/ProjectList/components/ProjectListContent.js.map +1 -1
  337. package/dist/@ecme/views/concepts/projects/ProjectList/components/ProjectListHeader.js +16 -16
  338. package/dist/@ecme/views/concepts/projects/ProjectList/components/ProjectListHeader.js.map +1 -1
  339. package/dist/@ecme/views/concepts/projects/ProjectList/hooks/useProjectList.js +9 -9
  340. package/dist/@ecme/views/concepts/projects/ProjectList/hooks/useProjectList.js.map +1 -1
  341. package/dist/@ecme/views/concepts/projects/ScrumBoard/components/AddNewColumnContent.js +40 -41
  342. package/dist/@ecme/views/concepts/projects/ScrumBoard/components/AddNewColumnContent.js.map +1 -1
  343. package/dist/@ecme/views/concepts/projects/ScrumBoard/components/AddNewTicketContent.js +33 -34
  344. package/dist/@ecme/views/concepts/projects/ScrumBoard/components/AddNewTicketContent.js.map +1 -1
  345. package/dist/@ecme/views/concepts/projects/ScrumBoard/components/BoardCardList.js +33 -33
  346. package/dist/@ecme/views/concepts/projects/ScrumBoard/components/BoardCardList.js.map +1 -1
  347. package/dist/@ecme/views/concepts/projects/ScrumBoard/components/TicketContent.js +203 -210
  348. package/dist/@ecme/views/concepts/projects/ScrumBoard/components/TicketContent.js.map +1 -1
  349. package/dist/@ecme/views/concepts/projects/Tasks/components/AddTask.js +53 -56
  350. package/dist/@ecme/views/concepts/projects/Tasks/components/AddTask.js.map +1 -1
  351. package/dist/@ecme/views/concepts/projects/Tasks/components/TaskList.js +80 -83
  352. package/dist/@ecme/views/concepts/projects/Tasks/components/TaskList.js.map +1 -1
  353. package/dist/@ecme/views/dashboards/AnalyticDashboard/components/AnalyticHeader.js +6 -6
  354. package/dist/@ecme/views/dashboards/AnalyticDashboard/components/AnalyticHeader.js.map +1 -1
  355. package/dist/@ecme/views/dashboards/EcommerceDashboard/components/Overview.js +21 -21
  356. package/dist/@ecme/views/dashboards/EcommerceDashboard/components/Overview.js.map +1 -1
  357. package/dist/@ecme/views/dashboards/EcommerceDashboard/components/RevenueByChannel.js +27 -27
  358. package/dist/@ecme/views/dashboards/EcommerceDashboard/components/RevenueByChannel.js.map +1 -1
  359. package/dist/@ecme/views/dashboards/EcommerceDashboard/components/SalesTarget.js +27 -27
  360. package/dist/@ecme/views/dashboards/EcommerceDashboard/components/SalesTarget.js.map +1 -1
  361. package/dist/@ecme/views/dashboards/MarketingDashboard/components/CreateCampaign.js +59 -60
  362. package/dist/@ecme/views/dashboards/MarketingDashboard/components/CreateCampaign.js.map +1 -1
  363. package/dist/@ecme/views/dashboards/ProjectDashboard/components/CreateEventDialog.js +76 -77
  364. package/dist/@ecme/views/dashboards/ProjectDashboard/components/CreateEventDialog.js.map +1 -1
  365. package/dist/@ecme/views/dashboards/ProjectDashboard/components/UpcomingSchedule.js +30 -30
  366. package/dist/@ecme/views/dashboards/ProjectDashboard/components/UpcomingSchedule.js.map +1 -1
  367. package/dist/@ecme/views/guide/SharedComponentsDoc/components/CustomFormatInputDoc/WithForm.js +21 -22
  368. package/dist/@ecme/views/guide/SharedComponentsDoc/components/CustomFormatInputDoc/WithForm.js.map +1 -1
  369. package/dist/@ecme/views/guide/SharedComponentsDoc/components/ImageGalleryDoc/Example.js +15 -15
  370. package/dist/@ecme/views/guide/SharedComponentsDoc/components/ImageGalleryDoc/Example.js.map +1 -1
  371. package/dist/@ecme/views/guide/SharedComponentsDoc/components/NumericInputDoc/WithForm.js +20 -21
  372. package/dist/@ecme/views/guide/SharedComponentsDoc/components/NumericInputDoc/WithForm.js.map +1 -1
  373. package/dist/@ecme/views/guide/SharedComponentsDoc/components/PatternInputDoc/WithForm.js +20 -21
  374. package/dist/@ecme/views/guide/SharedComponentsDoc/components/PatternInputDoc/WithForm.js.map +1 -1
  375. package/dist/@ecme/views/guide/SharedComponentsDoc/components/RichTextEditorDoc/WithForm.js +20 -21
  376. package/dist/@ecme/views/guide/SharedComponentsDoc/components/RichTextEditorDoc/WithForm.js.map +1 -1
  377. package/dist/@ecme/views/ui-components/data-display/Table/Editable.js +17 -18
  378. package/dist/@ecme/views/ui-components/data-display/Table/Editable.js.map +1 -1
  379. package/dist/@ecme/views/ui-components/data-display/Table/PaginationTable.js +12 -12
  380. package/dist/@ecme/views/ui-components/data-display/Table/PaginationTable.js.map +1 -1
  381. package/dist/@ecme/views/ui-components/forms/FormControl/AsyncValidation.js +28 -29
  382. package/dist/@ecme/views/ui-components/forms/FormControl/AsyncValidation.js.map +1 -1
  383. package/dist/@ecme/views/ui-components/forms/FormControl/Basic.js +21 -22
  384. package/dist/@ecme/views/ui-components/forms/FormControl/Basic.js.map +1 -1
  385. package/dist/@ecme/views/ui-components/forms/FormControl/DependentValidation.js +24 -25
  386. package/dist/@ecme/views/ui-components/forms/FormControl/DependentValidation.js.map +1 -1
  387. package/dist/@ecme/views/ui-components/forms/FormControl/DynamicForm.js +75 -79
  388. package/dist/@ecme/views/ui-components/forms/FormControl/DynamicForm.js.map +1 -1
  389. package/dist/@ecme/views/ui-components/forms/FormControl/FieldValidation.js +19 -20
  390. package/dist/@ecme/views/ui-components/forms/FormControl/FieldValidation.js.map +1 -1
  391. package/dist/@ecme/views/ui-components/forms/FormControl/MixedFormControl.js +90 -91
  392. package/dist/@ecme/views/ui-components/forms/FormControl/MixedFormControl.js.map +1 -1
  393. package/dist/@ecme/views/ui-components/forms/FormControl/SchemaValidation.js +22 -23
  394. package/dist/@ecme/views/ui-components/forms/FormControl/SchemaValidation.js.map +1 -1
  395. package/dist/@types/base/configs/api.config.d.ts +0 -19
  396. package/dist/@types/base/configs/api.config.d.ts.map +1 -1
  397. package/dist/base/assets/styles/init.css +1 -1
  398. package/dist/base/components/forms/ArraysForms/GenericArrayNumberFormSection.js +24 -25
  399. package/dist/base/components/forms/ArraysForms/GenericArrayNumberFormSection.js.map +1 -1
  400. package/dist/base/components/forms/ArraysForms/GenericArrayStringFormSection.js +23 -24
  401. package/dist/base/components/forms/ArraysForms/GenericArrayStringFormSection.js.map +1 -1
  402. package/dist/base/components/forms/GenericFomrsSetValue/GenericNumberFormSectionPrice.js +30 -31
  403. package/dist/base/components/forms/GenericFomrsSetValue/GenericNumberFormSectionPrice.js.map +1 -1
  404. package/dist/base/components/forms/GenericFomrsSetValue/GenericStringFormSection.js +25 -26
  405. package/dist/base/components/forms/GenericFomrsSetValue/GenericStringFormSection.js.map +1 -1
  406. package/dist/base/components/forms/GenericForms/GenericArrayFormSection.js +49 -50
  407. package/dist/base/components/forms/GenericForms/GenericArrayFormSection.js.map +1 -1
  408. package/dist/base/components/forms/GenericForms/GenericNumberFormSection.js +27 -28
  409. package/dist/base/components/forms/GenericForms/GenericNumberFormSection.js.map +1 -1
  410. package/dist/base/components/forms/GenericForms/GenericStringFormSection.js +23 -24
  411. package/dist/base/components/forms/GenericForms/GenericStringFormSection.js.map +1 -1
  412. package/dist/base/components/forms/GenericForms/GenericUploadFormSection.js +27 -28
  413. package/dist/base/components/forms/GenericForms/GenericUploadFormSection.js.map +1 -1
  414. package/dist/base/components/forms/NumberFormVariant/GenericNumberFormSectionPercentage.js +29 -30
  415. package/dist/base/components/forms/NumberFormVariant/GenericNumberFormSectionPercentage.js.map +1 -1
  416. package/dist/base/components/forms/NumberFormVariant/GenericNumberFormSectionPrice.js +27 -28
  417. package/dist/base/components/forms/NumberFormVariant/GenericNumberFormSectionPrice.js.map +1 -1
  418. package/dist/base/components/forms/NumberFormVariant/GenericNumberFormSectionWeight.js +27 -28
  419. package/dist/base/components/forms/NumberFormVariant/GenericNumberFormSectionWeight.js.map +1 -1
  420. package/dist/base/components/shared/TransferirProcessoDialog.js +10 -10
  421. package/dist/base/components/shared/TransferirProcessoDialog.js.map +1 -1
  422. package/dist/base/components/tools/NavFilter.js +68 -75
  423. package/dist/base/components/tools/NavFilter.js.map +1 -1
  424. package/dist/base/configs/api.config.js +11 -14
  425. package/dist/base/configs/api.config.js.map +1 -1
  426. package/dist/base/hooks/adm/roles/useRolesList.js +11 -11
  427. package/dist/base/hooks/adm/roles/useRolesList.js.map +1 -1
  428. package/dist/base/hooks/adm/users/useUsersList.js +10 -10
  429. package/dist/base/hooks/adm/users/useUsersList.js.map +1 -1
  430. package/dist/base/hooks/dm/businessPartner/useBusinessPartnerClienteList.js +5 -5
  431. package/dist/base/hooks/dm/businessPartner/useBusinessPartnerClienteList.js.map +1 -1
  432. package/dist/base/hooks/dm/businessPartner/useBusinessPartnerFornecedorList.js +7 -7
  433. package/dist/base/hooks/dm/businessPartner/useBusinessPartnerFornecedorList.js.map +1 -1
  434. package/dist/base/hooks/dm/businessPartner/useBusinessPartnerList.js +10 -10
  435. package/dist/base/hooks/dm/businessPartner/useBusinessPartnerList.js.map +1 -1
  436. package/dist/base/hooks/dm/canalDistribuicao/useCanalDistribuicaoByCodigoList.js +8 -8
  437. package/dist/base/hooks/dm/canalDistribuicao/useCanalDistribuicaoByCodigoList.js.map +1 -1
  438. package/dist/base/hooks/dm/canalDistribuicao/useCanalDistribuicaoList.js +8 -8
  439. package/dist/base/hooks/dm/canalDistribuicao/useCanalDistribuicaoList.js.map +1 -1
  440. package/dist/base/hooks/dm/centro/useCentroByCodigoList.js +13 -13
  441. package/dist/base/hooks/dm/centro/useCentroByCodigoList.js.map +1 -1
  442. package/dist/base/hooks/dm/centro/useCentroList.js +6 -6
  443. package/dist/base/hooks/dm/centro/useCentroList.js.map +1 -1
  444. package/dist/base/hooks/dm/condicaoPagamento/useCondicaoPagamentoList.js +4 -4
  445. package/dist/base/hooks/dm/condicaoPagamento/useCondicaoPagamentoList.js.map +1 -1
  446. package/dist/base/hooks/dm/deposito/useDepositoByCodigoList.js +9 -9
  447. package/dist/base/hooks/dm/deposito/useDepositoByCodigoList.js.map +1 -1
  448. package/dist/base/hooks/dm/deposito/useDepositoList.js +5 -5
  449. package/dist/base/hooks/dm/deposito/useDepositoList.js.map +1 -1
  450. package/dist/base/hooks/dm/deposito/useDepositosByCodigoCentroList.js +13 -13
  451. package/dist/base/hooks/dm/deposito/useDepositosByCodigoCentroList.js.map +1 -1
  452. package/dist/base/hooks/dm/equipeVenda/useEquipeVendaByCodigoList.js +8 -8
  453. package/dist/base/hooks/dm/equipeVenda/useEquipeVendaByCodigoList.js.map +1 -1
  454. package/dist/base/hooks/dm/equipeVenda/useEquipeVendaList.js +6 -6
  455. package/dist/base/hooks/dm/equipeVenda/useEquipeVendaList.js.map +1 -1
  456. package/dist/base/hooks/dm/escritorioVenda/useEscritorioVendaByCodigoList.js +10 -10
  457. package/dist/base/hooks/dm/escritorioVenda/useEscritorioVendaByCodigoList.js.map +1 -1
  458. package/dist/base/hooks/dm/escritorioVenda/useEscritorioVendaList.js +7 -7
  459. package/dist/base/hooks/dm/escritorioVenda/useEscritorioVendaList.js.map +1 -1
  460. package/dist/base/hooks/dm/formaPagamento/useFormaPagamentoByCodigoList.js +10 -10
  461. package/dist/base/hooks/dm/formaPagamento/useFormaPagamentoByCodigoList.js.map +1 -1
  462. package/dist/base/hooks/dm/formaPagamento/useFormaPagamentoList.js +1 -1
  463. package/dist/base/hooks/dm/formaPagamento/useFormaPagamentoList.js.map +1 -1
  464. package/dist/base/hooks/dm/grupoVenda/useGrupoVendaByCodigoList.js +11 -11
  465. package/dist/base/hooks/dm/grupoVenda/useGrupoVendaByCodigoList.js.map +1 -1
  466. package/dist/base/hooks/dm/grupoVenda/useGrupoVendaList.js +9 -9
  467. package/dist/base/hooks/dm/grupoVenda/useGrupoVendaList.js.map +1 -1
  468. package/dist/base/hooks/dm/incoterms/useIncotermsList.js +17 -18
  469. package/dist/base/hooks/dm/incoterms/useIncotermsList.js.map +1 -1
  470. package/dist/base/hooks/dm/produto/useProdutoByCodigoList.js +13 -13
  471. package/dist/base/hooks/dm/produto/useProdutoByCodigoList.js.map +1 -1
  472. package/dist/base/hooks/dm/produto/useProdutoByGrupoProdutoList.js +21 -21
  473. package/dist/base/hooks/dm/produto/useProdutoByGrupoProdutoList.js.map +1 -1
  474. package/dist/base/hooks/dm/produto/useProdutoFindList.js +8 -8
  475. package/dist/base/hooks/dm/produto/useProdutoFindList.js.map +1 -1
  476. package/dist/base/hooks/dm/produto/useProdutoFindMonitorList.js +11 -11
  477. package/dist/base/hooks/dm/produto/useProdutoFindMonitorList.js.map +1 -1
  478. package/dist/base/hooks/dm/produto/useProdutoIsPrecificadoRacaoList.js +9 -9
  479. package/dist/base/hooks/dm/produto/useProdutoIsPrecificadoRacaoList.js.map +1 -1
  480. package/dist/base/hooks/dm/setorAtividade/useSetorAtividadeList.js +5 -5
  481. package/dist/base/hooks/dm/setorAtividade/useSetorAtividadeList.js.map +1 -1
  482. package/dist/base/hooks/dm/tipoDocumentoVenda/useTipoDocumentoVendaByCodigoList.js +9 -9
  483. package/dist/base/hooks/dm/tipoDocumentoVenda/useTipoDocumentoVendaByCodigoList.js.map +1 -1
  484. package/dist/base/hooks/dm/tipoDocumentoVenda/useTipoDocumentoVendaList.js +9 -9
  485. package/dist/base/hooks/dm/tipoDocumentoVenda/useTipoDocumentoVendaList.js.map +1 -1
  486. package/dist/base/hooks/dm/tipoOrdemVenda/useTipoOrdemVendaByCodigoList.js +10 -10
  487. package/dist/base/hooks/dm/tipoOrdemVenda/useTipoOrdemVendaByCodigoList.js.map +1 -1
  488. package/dist/base/hooks/dm/tipoOrdemVenda/useTipoOrdemVendaList.js +9 -9
  489. package/dist/base/hooks/dm/tipoOrdemVenda/useTipoOrdemVendaList.js.map +1 -1
  490. package/dist/base/hooks/useList.js +10 -10
  491. package/dist/base/hooks/useList.js.map +1 -1
  492. package/dist/base/services/modules/transportadora/ControleDescarga/ControleDescargaService.js +15 -15
  493. package/dist/base/services/modules/transportadora/ControleDescarga/ControleDescargaService.js.map +1 -1
  494. package/dist/base/services/modules/transportadora/ControleEmbarque/ControleEmbarqueService.js +7 -7
  495. package/dist/base/services/modules/transportadora/ControleEmbarque/ControleEmbarqueService.js.map +1 -1
  496. package/dist/base/services/modules/transportadora/NaturezaCarga/NaturezaCargaService.js +5 -5
  497. package/dist/base/services/modules/transportadora/NaturezaCarga/NaturezaCargaService.js.map +1 -1
  498. package/dist/base/utils/functions/stringUtils.js +14 -15
  499. package/dist/base/utils/functions/stringUtils.js.map +1 -1
  500. package/lib/base/configs/api.config.ts +6 -7
  501. package/package.json +1 -1
  502. package/tsconfig.json +6 -1
@@ -1,80 +1,80 @@
1
- import { jsx as D } from "react/jsx-runtime";
2
- import { useContext as h, useCallback as x, isValidElement as A, cloneElement as F } from "react";
3
- import H from "lodash/isNil";
4
- import K from "../hooks/useUncertainRef.js";
5
- import O from "../hooks/useUniqueId.js";
6
- import b from "../utils/classNames.js";
7
- import g from "./context/dropdownContext.js";
8
- import V from "./context/menuContext.js";
9
- import _ from "../MenuItem/index.js";
10
- import { DROPDOWN_ITEM_TYPE as j } from "../utils/constants.js";
11
- import { useFloatingTree as q } from "@floating-ui/react";
12
- const { DEFAULT: L, DIVIDER: W, HEADER: N, CUSTOM: l } = j, ee = (R) => {
1
+ import { jsx as I } from "react/jsx-runtime";
2
+ import { useContext as D, useCallback as h, isValidElement as U, cloneElement as w } from "react";
3
+ import A from "lodash/isNil";
4
+ import H from "../hooks/useUncertainRef.js";
5
+ import K from "../hooks/useUniqueId.js";
6
+ import O from "../utils/classNames.js";
7
+ import b from "./context/dropdownContext.js";
8
+ import g from "./context/menuContext.js";
9
+ import S from "../MenuItem/index.js";
10
+ import { DROPDOWN_ITEM_TYPE as V } from "../utils/constants.js";
11
+ import { useFloatingTree as _ } from "@floating-ui/react";
12
+ const { DEFAULT: j, DIVIDER: q, HEADER: k, CUSTOM: i } = V, ee = (x) => {
13
13
  const {
14
- asElement: u = "li",
15
- children: r,
16
- active: T,
17
- disabled: c,
18
- className: f,
19
- style: p,
20
- eventKey: m,
21
- onSelect: o,
22
- onClick: s,
23
- onFocus: a,
24
- ref: y = null,
25
- variant: t = L,
26
- ...v
27
- } = R, n = h(g), d = h(V), E = K(
28
- y
29
- ), M = O("menu-item-"), P = T || !H(n == null ? void 0 : n.activeKey) && (n == null ? void 0 : n.activeKey) === m, i = q(), I = x(
14
+ asElement: m = "li",
15
+ children: n,
16
+ active: F,
17
+ disabled: r,
18
+ className: s,
19
+ style: c,
20
+ eventKey: o,
21
+ onSelect: l,
22
+ onClick: a,
23
+ onFocus: N,
24
+ ref: R = null,
25
+ variant: t = j,
26
+ ...u
27
+ } = x, f = D(b), d = D(g), p = H(
28
+ R
29
+ ), T = K("menu-item-"), y = F || !A(f?.activeKey) && f?.activeKey === o, v = _(), E = h(
30
30
  (e) => {
31
- o == null || o(m || "", e), s == null || s(e);
31
+ l?.(o || "", e), a?.(e);
32
32
  },
33
- [m, s, o]
34
- ), U = x(
33
+ [o, a, l]
34
+ ), M = h(
35
35
  (e) => {
36
- c || (I(e), i == null || i.events.emit("click"));
36
+ r || (E(e), v?.events.emit("click"));
37
37
  },
38
- [c, I, i == null ? void 0 : i.events]
38
+ [r, E, v?.events]
39
39
  ), C = {
40
40
  ...d.getItemProps({
41
41
  onClick(e) {
42
- U(e);
42
+ M(e);
43
43
  },
44
44
  onFocus(e) {
45
- a == null || a(e), d.setHasFocusInside(!0);
45
+ N?.(e), d.setHasFocusInside(!0);
46
46
  }
47
47
  })
48
48
  };
49
- if (t === W || t === N || t === l)
50
- return /* @__PURE__ */ D(
51
- u,
49
+ if (t === q || t === k || t === i)
50
+ return /* @__PURE__ */ I(
51
+ m,
52
52
  {
53
- ref: E,
54
- id: M,
55
- style: p,
56
- className: b(`menu-item-${t}`, f),
57
- ...t === l ? C : {},
58
- ...v,
59
- children: (t === N || t === l) && r
53
+ ref: p,
54
+ id: T,
55
+ style: c,
56
+ className: O(`menu-item-${t}`, s),
57
+ ...t === i ? C : {},
58
+ ...u,
59
+ children: (t === k || t === i) && n
60
60
  }
61
61
  );
62
- function k() {
63
- return A(r) ? F(r) : r;
62
+ function P() {
63
+ return U(n) ? w(n) : n;
64
64
  }
65
- return /* @__PURE__ */ D(
66
- _,
65
+ return /* @__PURE__ */ I(
66
+ S,
67
67
  {
68
- ref: E,
69
- asElement: u,
70
- style: p,
71
- isActive: P,
72
- disabled: c,
73
- eventKey: m,
74
- className: f,
68
+ ref: p,
69
+ asElement: m,
70
+ style: c,
71
+ isActive: y,
72
+ disabled: r,
73
+ eventKey: o,
74
+ className: s,
75
75
  ...C,
76
- ...v,
77
- children: k()
76
+ ...u,
77
+ children: P()
78
78
  }
79
79
  );
80
80
  };
@@ -1 +1 @@
1
- {"version":3,"file":"DropdownItem.js","sources":["../../../../../lib/@ecme/components/ui/Dropdown/DropdownItem.tsx"],"sourcesContent":["import { useContext, useCallback, isValidElement, cloneElement } from 'react'\nimport isNil from 'lodash/isNil'\nimport useUncertainRef from '../hooks/useUncertainRef'\nimport useUniqueId from '../hooks/useUniqueId'\nimport classNames from '../utils/classNames'\nimport DropdownContext from './context/dropdownContext'\nimport MenuContext from './context/menuContext'\nimport MenuItem from '../MenuItem'\nimport { DROPDOWN_ITEM_TYPE } from '../utils/constants'\nimport { useFloatingTree } from '@floating-ui/react'\nimport type { CommonProps } from '../@types/common'\nimport type {\n SyntheticEvent,\n RefObject,\n ElementType,\n ReactElement,\n MouseEvent,\n FocusEvent,\n Ref,\n} from 'react'\n\nexport interface DropdownItemProps extends CommonProps {\n asElement?: ElementType\n active?: boolean\n disabled?: boolean\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n submenu?: ReactElement<any>\n eventKey?: string\n onSelect?: (eventKey: string, e: SyntheticEvent) => void\n onFocus?: (e: SyntheticEvent) => void\n onClick?: (e: SyntheticEvent) => void\n ref?: Ref<HTMLElement>\n variant?: 'default' | 'header' | 'divider' | 'custom'\n}\n\nconst { DEFAULT, DIVIDER, HEADER, CUSTOM } = DROPDOWN_ITEM_TYPE\n\nconst DropdownItem = (props: DropdownItemProps) => {\n const {\n asElement: Component = 'li',\n children,\n active: activeProp,\n disabled,\n className,\n style,\n eventKey,\n onSelect,\n onClick,\n onFocus,\n ref = null,\n variant = DEFAULT,\n ...rest\n } = props\n\n const dropdown = useContext(DropdownContext)\n const menu = useContext(MenuContext)\n\n const menuitemRef = useUncertainRef<HTMLElement>(\n ref,\n ) as RefObject<HTMLElement | null>\n\n const menuitemId = useUniqueId('menu-item-')\n\n const active =\n activeProp ||\n (!isNil(dropdown?.activeKey) && dropdown?.activeKey === eventKey)\n\n const tree = useFloatingTree()\n\n const activate = useCallback(\n (e: SyntheticEvent) => {\n onSelect?.(eventKey || '', e)\n onClick?.(e)\n },\n [eventKey, onClick, onSelect],\n )\n\n const handleClick = useCallback(\n (e: SyntheticEvent) => {\n if (disabled) {\n return\n }\n\n activate(e)\n tree?.events.emit('click')\n },\n [disabled, activate, tree?.events],\n )\n\n const menuitemEventHandlers = {\n ...menu.getItemProps({\n onClick(event: MouseEvent<HTMLElement>) {\n handleClick(event)\n },\n onFocus(event: FocusEvent<HTMLElement>) {\n onFocus?.(event)\n menu.setHasFocusInside(true)\n },\n }),\n }\n\n if (variant === DIVIDER || variant === HEADER || variant === CUSTOM) {\n return (\n <Component\n ref={menuitemRef}\n id={menuitemId}\n style={style}\n className={classNames(`menu-item-${variant}`, className)}\n {...(variant === CUSTOM ? menuitemEventHandlers : {})}\n {...rest}\n >\n {(variant === HEADER || variant === CUSTOM) && children}\n </Component>\n )\n }\n\n function renderChildren() {\n if (!isValidElement(children)) {\n return children\n }\n return cloneElement(children)\n }\n\n return (\n <MenuItem\n ref={menuitemRef}\n asElement={Component}\n style={style}\n isActive={active}\n disabled={disabled}\n eventKey={eventKey}\n className={className}\n {...menuitemEventHandlers}\n {...rest}\n >\n {renderChildren()}\n </MenuItem>\n )\n}\n\nexport default DropdownItem\n"],"names":["DEFAULT","DIVIDER","HEADER","CUSTOM","DROPDOWN_ITEM_TYPE","DropdownItem","props","Component","children","activeProp","disabled","className","style","eventKey","onSelect","onClick","onFocus","ref","variant","rest","dropdown","useContext","DropdownContext","menu","MenuContext","menuitemRef","useUncertainRef","menuitemId","useUniqueId","active","isNil","tree","useFloatingTree","activate","useCallback","handleClick","menuitemEventHandlers","event","jsx","classNames","renderChildren","isValidElement","cloneElement","MenuItem"],"mappings":";;;;;;;;;;;AAmCA,MAAM,EAAE,SAAAA,GAAS,SAAAC,GAAS,QAAAC,GAAQ,QAAAC,MAAWC,GAEvCC,KAAe,CAACC,MAA6B;AAC/C,QAAM;AAAA,IACF,WAAWC,IAAY;AAAA,IACvB,UAAAC;AAAA,IACA,QAAQC;AAAA,IACR,UAAAC;AAAA,IACA,WAAAC;AAAA,IACA,OAAAC;AAAA,IACA,UAAAC;AAAA,IACA,UAAAC;AAAA,IACA,SAAAC;AAAA,IACA,SAAAC;AAAA,IACA,KAAAC,IAAM;AAAA,IACN,SAAAC,IAAUlB;AAAA,IACV,GAAGmB;AAAA,EAAA,IACHb,GAEEc,IAAWC,EAAWC,CAAe,GACrCC,IAAOF,EAAWG,CAAW,GAE7BC,IAAcC;AAAA,IAChBT;AAAA,EAAA,GAGEU,IAAaC,EAAY,YAAY,GAErCC,IACFpB,KACC,CAACqB,EAAMV,KAAA,gBAAAA,EAAU,SAAS,MAAKA,KAAA,gBAAAA,EAAU,eAAcP,GAEtDkB,IAAOC,EAAA,GAEPC,IAAWC;AAAA,IACb,CAAC,MAAsB;AACnB,MAAApB,KAA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AqB,EAAA;AAAA,IAAe;AAAA,EAAA;AAG5B;"}
1
+ {"version":3,"file":"DropdownItem.js","sources":["../../../../../lib/@ecme/components/ui/Dropdown/DropdownItem.tsx"],"sourcesContent":["import { useContext, useCallback, isValidElement, cloneElement } from 'react'\nimport isNil from 'lodash/isNil'\nimport useUncertainRef from '../hooks/useUncertainRef'\nimport useUniqueId from '../hooks/useUniqueId'\nimport classNames from '../utils/classNames'\nimport DropdownContext from './context/dropdownContext'\nimport MenuContext from './context/menuContext'\nimport MenuItem from '../MenuItem'\nimport { DROPDOWN_ITEM_TYPE } from '../utils/constants'\nimport { useFloatingTree } from '@floating-ui/react'\nimport type { CommonProps } from '../@types/common'\nimport type {\n SyntheticEvent,\n RefObject,\n ElementType,\n ReactElement,\n MouseEvent,\n FocusEvent,\n Ref,\n} from 'react'\n\nexport interface DropdownItemProps extends CommonProps {\n asElement?: ElementType\n active?: boolean\n disabled?: boolean\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n submenu?: ReactElement<any>\n eventKey?: string\n onSelect?: (eventKey: string, e: SyntheticEvent) => void\n onFocus?: (e: SyntheticEvent) => void\n onClick?: (e: SyntheticEvent) => void\n ref?: Ref<HTMLElement>\n variant?: 'default' | 'header' | 'divider' | 'custom'\n}\n\nconst { DEFAULT, DIVIDER, HEADER, CUSTOM } = DROPDOWN_ITEM_TYPE\n\nconst DropdownItem = (props: DropdownItemProps) => {\n const {\n asElement: Component = 'li',\n children,\n active: activeProp,\n disabled,\n className,\n style,\n eventKey,\n onSelect,\n onClick,\n onFocus,\n ref = null,\n variant = DEFAULT,\n ...rest\n } = props\n\n const dropdown = useContext(DropdownContext)\n const menu = useContext(MenuContext)\n\n const menuitemRef = useUncertainRef<HTMLElement>(\n ref,\n ) as RefObject<HTMLElement | null>\n\n const menuitemId = useUniqueId('menu-item-')\n\n const active =\n activeProp ||\n (!isNil(dropdown?.activeKey) && dropdown?.activeKey === eventKey)\n\n const tree = useFloatingTree()\n\n const activate = useCallback(\n (e: SyntheticEvent) => {\n onSelect?.(eventKey || '', e)\n onClick?.(e)\n },\n [eventKey, onClick, onSelect],\n )\n\n const handleClick = useCallback(\n (e: SyntheticEvent) => {\n if (disabled) {\n return\n }\n\n activate(e)\n tree?.events.emit('click')\n },\n [disabled, activate, tree?.events],\n )\n\n const menuitemEventHandlers = {\n ...menu.getItemProps({\n onClick(event: MouseEvent<HTMLElement>) {\n handleClick(event)\n },\n onFocus(event: FocusEvent<HTMLElement>) {\n onFocus?.(event)\n menu.setHasFocusInside(true)\n },\n }),\n }\n\n if (variant === DIVIDER || variant === HEADER || variant === CUSTOM) {\n return (\n <Component\n ref={menuitemRef}\n id={menuitemId}\n style={style}\n className={classNames(`menu-item-${variant}`, className)}\n {...(variant === CUSTOM ? menuitemEventHandlers : {})}\n {...rest}\n >\n {(variant === HEADER || variant === CUSTOM) && children}\n </Component>\n )\n }\n\n function renderChildren() {\n if (!isValidElement(children)) {\n return children\n }\n return cloneElement(children)\n }\n\n return (\n <MenuItem\n ref={menuitemRef}\n asElement={Component}\n style={style}\n isActive={active}\n disabled={disabled}\n eventKey={eventKey}\n className={className}\n {...menuitemEventHandlers}\n {...rest}\n >\n {renderChildren()}\n </MenuItem>\n )\n}\n\nexport default DropdownItem\n"],"names":["DEFAULT","DIVIDER","HEADER","CUSTOM","DROPDOWN_ITEM_TYPE","DropdownItem","props","Component","children","activeProp","disabled","className","style","eventKey","onSelect","onClick","onFocus","ref","variant","rest","dropdown","useContext","DropdownContext","menu","MenuContext","menuitemRef","useUncertainRef","menuitemId","useUniqueId","active","isNil","tree","useFloatingTree","activate","useCallback","handleClick","menuitemEventHandlers","event","jsx","classNames","renderChildren","isValidElement","cloneElement","MenuItem"],"mappings":";;;;;;;;;;;AAmCA,MAAM,EAAE,SAAAA,GAAS,SAAAC,GAAS,QAAAC,GAAQ,QAAAC,MAAWC,GAEvCC,KAAe,CAACC,MAA6B;AAC/C,QAAM;AAAA,IACF,WAAWC,IAAY;AAAA,IACvB,U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AA,QACtD,GAAIO,MAAYf,IAASiC,IAAwB,CAAA;AAAA,QACjD,GAAGjB;AAAA,QAEF,WAAAD,MAAYhB,KAAUgB,MAAYf,MAAWK;AAAA,MAAA;AAAA,IAAA;AAK3D,WAASgC,IAAiB;AACtB,WAAKC,EAAejC,CAAQ,IAGrBkC,EAAalC,CAAQ,IAFjBA;AAAA,EAGf;AAEA,SACI,gBAAA8B;AAAA,IAACK;AAAA,IAAA;AAAA,MACG,KAAKlB;AAAA,MACL,WAAWlB;AAAA,MACX,OAAAK;AAAA,MACA,UAAUiB;AAAA,MACV,UAAAnB;AAAA,MACA,UAAAG;AAAA,MACA,WAAAF;AAAA,MACC,GAAGyB;AAAA,MACH,GAAGjB;AAAA,MAEH,UAAAqB,EAAA;AAAA,IAAe;AAAA,EAAA;AAG5B;"}
@@ -1,44 +1,44 @@
1
1
  import { jsxs as te, jsx as n } from "react/jsx-runtime";
2
- import { useState as v, useRef as L, useContext as oe, useEffect as Y, useImperativeHandle as ne } from "react";
2
+ import { useState as g, useRef as E, useContext as ne, useEffect as L, useImperativeHandle as oe } from "react";
3
3
  import se from "./DropdownToggle.js";
4
- import ie from "./DropdownSubItem.js";
5
- import j from "./context/menuContext.js";
6
- import I from "../utils/classNames.js";
4
+ import re from "./DropdownSubItem.js";
5
+ import Y from "./context/menuContext.js";
6
+ import h from "../utils/classNames.js";
7
7
  import "../ConfigProvider/index.js";
8
- import { useFloatingTree as re, useFloatingNodeId as ae, useFloatingParentNodeId as le, useListItem as ce, useFloating as de, autoUpdate as ue, flip as fe, shift as me, useTransitionStyles as ge, useHover as pe, safePolygon as he, useClick as ve, useRole as Ie, useDismiss as Fe, useListNavigation as be, useTypeahead as xe, useInteractions as Ne, useMergeRefs as ye, FloatingNode as Pe, FloatingList as Ce, FloatingPortal as Me, FloatingFocusManager as we } from "@floating-ui/react";
8
+ import { useFloatingTree as ie, useFloatingNodeId as ae, useFloatingParentNodeId as le, useListItem as ce, useFloating as de, autoUpdate as ue, flip as fe, shift as me, useTransitionStyles as pe, useHover as ge, safePolygon as he, useClick as ve, useRole as Ie, useDismiss as Fe, useListNavigation as be, useTypeahead as xe, useInteractions as Ne, useMergeRefs as ye, FloatingNode as Pe, FloatingList as Ce, FloatingPortal as Me, FloatingFocusManager as we } from "@floating-ui/react";
9
9
  import { useConfig as Re } from "../ConfigProvider/ConfigProvider.js";
10
- const ze = (z) => {
10
+ const je = (j) => {
11
11
  const {
12
- children: A,
13
- title: F,
14
- renderTitle: f,
15
- disabled: b,
16
- toggleClassName: x,
17
- menuClass: U,
18
- placement: N,
19
- trigger: m = "click",
20
- onOpen: e,
21
- ref: y,
22
- ...u
23
- } = z, [r, l] = v(!1), [P, C] = v(!1), [g, p] = v(null), M = L([]), w = L([]), { direction: R } = Re(), h = oe(j), o = re(), a = ae(), c = le(), D = ce(), s = c != null, k = (t) => {
24
- b || (l(t), e == null || e(t));
25
- }, q = () => R === "ltr" ? "bottom-start" : "bottom-end", B = () => R === "ltr" ? "right-start" : "left-start", { floatingStyles: G, refs: T, context: i } = de({
12
+ children: z,
13
+ title: v,
14
+ renderTitle: d,
15
+ disabled: I,
16
+ toggleClassName: F,
17
+ menuClass: A,
18
+ placement: b,
19
+ trigger: u = "click",
20
+ onOpen: i,
21
+ ref: x,
22
+ ...N
23
+ } = j, [r, l] = g(!1), [y, P] = g(!1), [f, m] = g(null), C = E([]), M = E([]), { direction: w } = Re(), p = ne(Y), t = ie(), a = ae(), c = le(), R = ce(), o = c != null, D = (e) => {
24
+ I || (l(e), i?.(e));
25
+ }, U = () => w === "ltr" ? "bottom-start" : "bottom-end", q = () => w === "ltr" ? "right-start" : "left-start", { floatingStyles: B, refs: k, context: s } = de({
26
26
  nodeId: a,
27
27
  open: r,
28
- onOpenChange: (t) => {
29
- k(t);
28
+ onOpenChange: (e) => {
29
+ D(e);
30
30
  },
31
- placement: N || (s ? B() : q()),
31
+ placement: b || (o ? q() : U()),
32
32
  middleware: [fe(), me()],
33
33
  whileElementsMounted: ue
34
- }), { isMounted: J, styles: K } = ge(i, {
35
- common: ({ side: t }) => ({
34
+ }), { isMounted: G, styles: J } = pe(s, {
35
+ common: ({ side: e }) => ({
36
36
  transformOrigin: {
37
37
  top: "bottom",
38
38
  bottom: "top",
39
39
  left: "right",
40
40
  right: "left"
41
- }[t]
41
+ }[e]
42
42
  }),
43
43
  initial: {
44
44
  transform: "translateY(-5%)",
@@ -53,131 +53,130 @@ const ze = (z) => {
53
53
  opacity: 0,
54
54
  transform: "translateY(-5%)"
55
55
  }
56
- }), Q = pe(i, {
57
- enabled: s || m === "hover",
56
+ }), K = ge(s, {
57
+ enabled: o || u === "hover",
58
58
  delay: { open: 75 },
59
59
  handleClose: he({ blockPointerEvents: !0 })
60
- }), V = ve(i, {
60
+ }), Q = ve(s, {
61
61
  event: "mousedown",
62
- toggle: !s,
63
- ignoreMouse: s
64
- }), W = Ie(i, { role: "menu" }), X = Fe(i, { bubbles: !0 }), Z = be(i, {
62
+ toggle: !o,
63
+ ignoreMouse: o
64
+ }), V = Ie(s, { role: "menu" }), W = Fe(s, { bubbles: !0 }), X = be(s, {
65
+ listRef: C,
66
+ activeIndex: f,
67
+ nested: o,
68
+ onNavigate: m
69
+ }), Z = xe(s, {
65
70
  listRef: M,
66
- activeIndex: g,
67
- nested: s,
68
- onNavigate: p
69
- }), _ = xe(i, {
70
- listRef: w,
71
- onMatch: r ? p : void 0,
72
- activeIndex: g
73
- }), { getReferenceProps: $, getFloatingProps: O, getItemProps: ee } = Ne([
74
- Q,
71
+ onMatch: r ? m : void 0,
72
+ activeIndex: f
73
+ }), { getReferenceProps: _, getFloatingProps: $, getItemProps: ee } = Ne([
74
+ K,
75
+ V,
75
76
  W,
76
77
  X,
77
78
  Z,
78
- _,
79
- ...m === "click" ? [V] : []
79
+ ...u === "click" ? [Q] : []
80
80
  ]);
81
- Y(() => {
82
- if (!o) return;
83
- function t() {
84
- l(!1), e == null || e(!1);
81
+ L(() => {
82
+ if (!t) return;
83
+ function e() {
84
+ l(!1), i?.(!1);
85
85
  }
86
- function d(E) {
87
- E.nodeId !== a && E.parentId === c && (l(!1), e == null || e(!1));
86
+ function S(H) {
87
+ H.nodeId !== a && H.parentId === c && (l(!1), i?.(!1));
88
88
  }
89
- return o.events.on("click", t), o.events.on("menuopen", d), () => {
90
- o.events.off("click", t), o.events.off("menuopen", d);
89
+ return t.events.on("click", e), t.events.on("menuopen", S), () => {
90
+ t.events.off("click", e), t.events.off("menuopen", S);
91
91
  };
92
- }, [o, a, c]), Y(() => {
93
- r && o && o.events.emit("menuopen", { parentId: c, nodeId: a });
94
- }, [o, r, a, c]);
95
- const S = ye([T.setReference, D.ref, y]);
96
- ne(y, () => ({
92
+ }, [t, a, c]), L(() => {
93
+ r && t && t.events.emit("menuopen", { parentId: c, nodeId: a });
94
+ }, [t, r, a, c]);
95
+ const O = ye([k.setReference, R.ref, x]);
96
+ oe(x, () => ({
97
97
  handleDropdownOpen: () => {
98
- l(!0), e == null || e(!0);
98
+ l(!0), i?.(!0);
99
99
  },
100
100
  handleDropdownClose: () => {
101
- l(!1), e == null || e(!1);
101
+ l(!1), i?.(!1);
102
102
  }
103
- }), [e]);
104
- const H = {
105
- ...$(
106
- h.getItemProps({
107
- ...u,
108
- onFocus(t) {
109
- var d;
110
- (d = u.onFocus) == null || d.call(u, t), C(!1), h.setHasFocusInside(!0);
103
+ }), [i]);
104
+ const T = {
105
+ ..._(
106
+ p.getItemProps({
107
+ ...N,
108
+ onFocus(e) {
109
+ N.onFocus?.(e), P(!1), p.setHasFocusInside(!0);
111
110
  }
112
111
  })
113
112
  ),
114
- ...m === "context" ? {
115
- onContextMenu: (t) => {
116
- t.preventDefault(), k(!0);
113
+ ...u === "context" ? {
114
+ onContextMenu: (e) => {
115
+ e.preventDefault(), D(!0);
117
116
  }
118
117
  } : {}
119
118
  };
120
119
  return /* @__PURE__ */ te(Pe, { id: a, children: [
121
- s ? /* @__PURE__ */ n(
120
+ o ? /* @__PURE__ */ n(
122
121
  "li",
123
122
  {
124
- ref: S,
125
- tabIndex: h.activeIndex === D.index ? 0 : -1,
123
+ ref: O,
124
+ tabIndex: p.activeIndex === R.index ? 0 : -1,
126
125
  "data-open": r ? "" : void 0,
127
126
  "data-nested": "",
128
- "data-focus-inside": P ? "" : void 0,
129
- className: I(x, "outline-none"),
130
- ...H,
131
- children: /* @__PURE__ */ n(ie, { children: f || F })
127
+ "data-focus-inside": y ? "" : void 0,
128
+ className: h(F, "outline-none"),
129
+ ...T,
130
+ children: /* @__PURE__ */ n(re, { children: d || v })
132
131
  }
133
132
  ) : /* @__PURE__ */ n(
134
133
  se,
135
134
  {
136
- ref: S,
135
+ ref: O,
137
136
  role: "menuitem",
138
137
  "data-open": r ? "" : void 0,
139
- "data-focus-inside": P ? "" : void 0,
140
- className: I(x),
141
- disabled: b,
142
- placement: N,
143
- renderTitle: f,
144
- ...H,
145
- children: F
138
+ "data-focus-inside": y ? "" : void 0,
139
+ className: h(F),
140
+ disabled: I,
141
+ placement: b,
142
+ renderTitle: d,
143
+ ...T,
144
+ children: v
146
145
  }
147
146
  ),
148
147
  /* @__PURE__ */ n(
149
- j.Provider,
148
+ Y.Provider,
150
149
  {
151
150
  value: {
152
- activeIndex: g,
153
- setActiveIndex: p,
151
+ activeIndex: f,
152
+ setActiveIndex: m,
154
153
  getItemProps: ee,
155
- setHasFocusInside: C,
154
+ setHasFocusInside: P,
156
155
  isOpen: r
157
156
  },
158
- children: /* @__PURE__ */ n(Ce, { elementsRef: M, labelsRef: w, children: J && /* @__PURE__ */ n(Me, { children: /* @__PURE__ */ n(
157
+ children: /* @__PURE__ */ n(Ce, { elementsRef: C, labelsRef: M, children: G && /* @__PURE__ */ n(Me, { children: /* @__PURE__ */ n(
159
158
  we,
160
159
  {
161
- context: i,
160
+ context: s,
162
161
  modal: !1,
163
- initialFocus: s ? -1 : 0,
164
- returnFocus: !s,
162
+ initialFocus: o ? -1 : 0,
163
+ returnFocus: !o,
165
164
  children: /* @__PURE__ */ n(
166
165
  "div",
167
166
  {
168
- ref: T.setFloating,
169
- style: G,
170
- ...O(),
167
+ ref: k.setFloating,
168
+ style: B,
169
+ ...$(),
171
170
  className: "outline-none z-30",
172
171
  children: /* @__PURE__ */ n(
173
172
  "ul",
174
173
  {
175
- className: I(
174
+ className: h(
176
175
  "dropdown-menu min-w-[160px]",
177
- U
176
+ A
178
177
  ),
179
- style: K,
180
- children: A
178
+ style: J,
179
+ children: z
181
180
  }
182
181
  )
183
182
  }
@@ -189,6 +188,6 @@ const ze = (z) => {
189
188
  ] });
190
189
  };
191
190
  export {
192
- ze as default
191
+ je as default
193
192
  };
194
193
  //# sourceMappingURL=DropdownMenu.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"DropdownMenu.js","sources":["../../../../../lib/@ecme/components/ui/Dropdown/DropdownMenu.tsx"],"sourcesContent":["import {\n useState,\n useRef,\n useContext,\n useEffect,\n useImperativeHandle,\n} from 'react'\nimport DropdownToggle from './DropdownToggle'\nimport DropdownSubItem from './DropdownSubItem'\nimport MenuContext from './context/menuContext'\nimport classNames from '../utils/classNames'\nimport { useConfig } from '../ConfigProvider'\nimport {\n autoUpdate,\n flip,\n FloatingFocusManager,\n FloatingList,\n FloatingNode,\n FloatingPortal,\n safePolygon,\n shift,\n useClick,\n useDismiss,\n useFloating,\n useFloatingNodeId,\n useFloatingParentNodeId,\n useFloatingTree,\n useHover,\n useInteractions,\n useListItem,\n useListNavigation,\n useMergeRefs,\n useRole,\n useTypeahead,\n useTransitionStyles,\n} from '@floating-ui/react'\nimport type { CommonProps } from '../@types/common'\nimport type { DropdownToggleSharedProps } from './DropdownToggle'\nimport type { DropdownSubItemSharedProps } from './DropdownSubItem'\nimport type { Placement } from '@floating-ui/react'\nimport type { HTMLProps, FocusEvent, MouseEvent, ReactNode, Ref } from 'react'\n\nexport interface DropdownMenuProps\n extends CommonProps,\n DropdownToggleSharedProps,\n DropdownSubItemSharedProps {\n activeKey?: string\n title?: string | ReactNode\n menuClass?: string\n trigger?: 'click' | 'hover' | 'context'\n placement?: Placement\n onOpen?: (bool: boolean) => void\n ref?: Ref<HTMLElement | DropdownMenuRef>\n}\n\nexport type DropdownMenuRef = {\n handleDropdownOpen: () => void\n handleDropdownClose: () => void\n}\n\nconst DropdownMenu = (props: DropdownMenuProps & HTMLProps<HTMLElement>) => {\n const {\n children,\n title,\n renderTitle,\n disabled,\n toggleClassName,\n menuClass,\n placement,\n trigger = 'click',\n onOpen,\n ref,\n ...rest\n } = props\n\n const [isOpen, setIsOpen] = useState(false)\n const [hasFocusInside, setHasFocusInside] = useState(false)\n const [activeIndex, setActiveIndex] = useState<number | null>(null)\n\n const elementsRef = useRef<Array<HTMLElement | null>>([])\n const labelsRef = useRef<Array<string | null>>([])\n\n const { direction } = useConfig()\n\n const parent = useContext(MenuContext)\n\n const tree = useFloatingTree()\n const nodeId = useFloatingNodeId()\n const parentId = useFloatingParentNodeId()\n const item = useListItem()\n\n const isNested = parentId != null\n\n const handleOpen = (open: boolean) => {\n if (disabled) {\n return\n }\n setIsOpen(open)\n onOpen?.(open)\n }\n\n const getDefaultPlacement = () => {\n return direction === 'ltr' ? 'bottom-start' : 'bottom-end'\n }\n\n const getNestedDefaultPlacement = () => {\n return direction === 'ltr' ? 'right-start' : 'left-start'\n }\n\n const { floatingStyles, refs, context } = useFloating<HTMLElement>({\n nodeId,\n open: isOpen,\n onOpenChange: (open) => {\n handleOpen(open)\n },\n placement:\n placement ||\n (isNested ? getNestedDefaultPlacement() : getDefaultPlacement()),\n middleware: [flip(), shift()],\n whileElementsMounted: autoUpdate,\n })\n\n const { isMounted, styles } = useTransitionStyles(context, {\n common: ({ side }) => ({\n transformOrigin: {\n top: 'bottom',\n bottom: 'top',\n left: 'right',\n right: 'left',\n }[side],\n }),\n initial: {\n transform: 'translateY(-5%)',\n opacity: 0,\n },\n duration: 200,\n open: {\n opacity: 1,\n transform: 'translateY(0%)',\n },\n close: {\n opacity: 0,\n transform: 'translateY(-5%)',\n },\n })\n\n const hover = useHover(context, {\n enabled: isNested || trigger === 'hover',\n delay: { open: 75 },\n handleClose: safePolygon({ blockPointerEvents: true }),\n })\n\n const click = useClick(context, {\n event: 'mousedown',\n toggle: !isNested,\n ignoreMouse: isNested,\n })\n\n const role = useRole(context, { role: 'menu' })\n\n const dismiss = useDismiss(context, { bubbles: true })\n\n const listNavigation = useListNavigation(context, {\n listRef: elementsRef,\n activeIndex,\n nested: isNested,\n onNavigate: setActiveIndex,\n })\n const typeahead = useTypeahead(context, {\n listRef: labelsRef,\n onMatch: isOpen ? setActiveIndex : undefined,\n activeIndex,\n })\n\n const { getReferenceProps, getFloatingProps, getItemProps } =\n useInteractions([\n hover,\n role,\n dismiss,\n listNavigation,\n typeahead,\n ...(trigger === 'click' ? [click] : []),\n ])\n\n useEffect(() => {\n if (!tree) return\n\n function handleTreeClick() {\n setIsOpen(false)\n onOpen?.(false)\n }\n\n function onSubMenuOpen(event: { nodeId: string; parentId: string }) {\n if (event.nodeId !== nodeId && event.parentId === parentId) {\n setIsOpen(false)\n onOpen?.(false)\n }\n }\n\n tree.events.on('click', handleTreeClick)\n tree.events.on('menuopen', onSubMenuOpen)\n\n return () => {\n tree.events.off('click', handleTreeClick)\n tree.events.off('menuopen', onSubMenuOpen)\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [tree, nodeId, parentId])\n\n useEffect(() => {\n if (isOpen && tree) {\n tree.events.emit('menuopen', { parentId, nodeId })\n }\n }, [tree, isOpen, nodeId, parentId])\n\n const toggleRef = useMergeRefs([refs.setReference, item.ref, ref])\n\n useImperativeHandle(ref, () => {\n return {\n handleDropdownOpen: () => {\n setIsOpen(true)\n onOpen?.(true)\n },\n handleDropdownClose: () => {\n setIsOpen(false)\n onOpen?.(false)\n },\n }\n }, [onOpen])\n\n const toggleProps = {\n ...getReferenceProps(\n parent.getItemProps({\n ...rest,\n onFocus(event: FocusEvent<HTMLElement>) {\n rest.onFocus?.(event)\n setHasFocusInside(false)\n parent.setHasFocusInside(true)\n },\n }),\n ),\n ...(trigger === 'context'\n ? {\n onContextMenu: (e: MouseEvent<HTMLElement>) => {\n e.preventDefault()\n handleOpen(true)\n },\n }\n : {}),\n }\n\n return (\n <FloatingNode id={nodeId}>\n {!isNested ? (\n <DropdownToggle\n ref={toggleRef}\n role={'menuitem'}\n data-open={isOpen ? '' : undefined}\n data-focus-inside={hasFocusInside ? '' : undefined}\n className={classNames(toggleClassName)}\n disabled={disabled}\n placement={placement}\n renderTitle={renderTitle}\n {...toggleProps}\n >\n {title}\n </DropdownToggle>\n ) : (\n <li\n ref={toggleRef}\n tabIndex={parent.activeIndex === item.index ? 0 : -1}\n data-open={isOpen ? '' : undefined}\n data-nested={''}\n data-focus-inside={hasFocusInside ? '' : undefined}\n className={classNames(toggleClassName, 'outline-none')}\n {...toggleProps}\n >\n <DropdownSubItem>\n {renderTitle ? renderTitle : title}\n </DropdownSubItem>\n </li>\n )}\n <MenuContext.Provider\n value={{\n activeIndex,\n setActiveIndex,\n getItemProps,\n setHasFocusInside,\n isOpen,\n }}\n >\n <FloatingList elementsRef={elementsRef} labelsRef={labelsRef}>\n {isMounted && (\n <FloatingPortal>\n <FloatingFocusManager\n context={context}\n modal={false}\n initialFocus={isNested ? -1 : 0}\n returnFocus={!isNested}\n >\n <div\n ref={refs.setFloating}\n style={floatingStyles}\n {...getFloatingProps()}\n className=\"outline-none z-30\"\n >\n <ul\n className={classNames(\n 'dropdown-menu min-w-[160px]',\n menuClass,\n )}\n style={styles}\n >\n {children}\n </ul>\n </div>\n </FloatingFocusManager>\n </FloatingPortal>\n )}\n </FloatingList>\n </MenuContext.Provider>\n </FloatingNode>\n )\n}\n\nexport default DropdownMenu\n"],"names":["DropdownMenu","props","children","title","renderTitle","disabled","toggleClassName","menuClass","placement","trigger","onOpen","ref","rest","isOpen","setIsOpen","useState","hasFocusInside","setHasFocusInside","activeIndex","setActiveIndex","elementsRef","useRef","labelsRef","direction","useConfig","parent","useContext","MenuContext","tree","useFloatingTree","nodeId","useFloatingNodeId","parentId","useFloatingParentNodeId","item","useListItem","isNested","handleOpen","open","getDefaultPlacement","getNestedDefaultPlacement","floatingStyles","refs","context","useFloating","flip","shift","autoUpdate","isMounted","styles","useTransitionStyles","side","hover","useHover","safePolygon","click","useClick","role","useRole","dismiss","useDismiss","listNavigation","useListNavigation","typeahead","useTypeahead","getReferenceProps","getFloatingProps","getItemProps","useInteractions","useEffect","handleTreeClick","onSubMenuOpen","event","toggleRef","useMergeRefs","useImperativeHandle","toggleProps","_a","e","jsxs","FloatingNode","jsx","classNames","DropdownSubItem","DropdownToggle","FloatingList","FloatingPortal","FloatingFocusManager"],"mappings":";;;;;;;;;AA4DA,MAAMA,KAAe,CAACC,MAAsD;AACxE,QAAM;AAAA,IACF,UAAAC;AAAA,IACA,OAAAC;AAAA,IACA,aAAAC;AAAA,IACA,UAAAC;AAAA,IACA,iBAAAC;AAAA,IACA,WAAAC;AAAA,IACA,WAAAC;AAAA,IACA,SAAAC,IAAU;AAAA,IACV,QAAAC;AAAA,IACA,KAAAC;AAAA,IACA,GAAGC;AAAA,EAAA,IACHX,GAEE,CAACY,GAAQC,CAAS,IAAIC,EAAS,EAAK,GACpC,CAACC,GAAgBC,CAAiB,IAAIF,EAAS,EAAK,GACpD,CAACG,GAAaC,CAAc,IAAIJ,EAAwB,IAAI,GAE5DK,IAAcC,EAAkC,EAAE,GAClDC,IAAYD,EAA6B,EAAE,GAE3C,EAAE,WAAAE,EAAA,IAAcC,GAAA,GAEhBC,IAASC,GAAWC,CAAW,GAE/BC,IAAOC,GAAA,GACPC,IAASC,GAAA,GACTC,IAAWC,GAAA,GACXC,IAAOC,GAAA,GAEPC,IAAWJ,KAAY,MAEvBK,IAAa,CAACC,MAAkB;AAClC,IAAIjC,MAGJS,EAAUwB,CAAI,GACd5B,KAAA,QAAAA,EAAS4B;AAAA,EACb,GAEMC,IAAsB,MACjBhB,MAAc,QAAQ,iBAAiB,cAG5CiB,IAA4B,MACvBjB,MAAc,QAAQ,gBAAgB,cAG3C,EA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,QAEH,UAAAzE;AAAA,MAAA;AAAA,IAAA;AAAA,IAiBT,gBAAA8E;AAAA,MAACtD,EAAY;AAAA,MAAZ;AAAA,QACG,OAAO;AAAA,UACH,aAAAT;AAAA,UACA,gBAAAC;AAAA,UACA,cAAAgD;AAAA,UACA,mBAAAlD;AAAA,UACA,QAAAJ;AAAA,QAAA;AAAA,QAGJ,4BAACwE,IAAA,EAAa,aAAAjE,GAA0B,WAAAE,GACnC,UAAA0B,uBACIsC,IAAA,EACG,UAAA,gBAAAL;AAAA,UAACM;AAAA,UAAA;AAAA,YACG,SAAA5C;AAAA,YACA,OAAO;AAAA,YACP,cAAcP,IAAW,KAAK;AAAA,YAC9B,aAAa,CAACA;AAAA,YAEd,UAAA,gBAAA6C;AAAA,cAAC;AAAA,cAAA;AAAA,gBACG,KAAKvC,EAAK;AAAA,gBACV,OAAOD;AAAA,gBACN,GAAGyB,EAAA;AAAA,gBACJ,WAAU;AAAA,gBAEV,UAAA,gBAAAe;AAAA,kBAAC;AAAA,kBAAA;AAAA,oBACG,WAAWC;AAAA,sBACP;AAAA,sBACA3E;AAAA,oBAAA;AAAA,oBAEJ,OAAO0C;AAAA,oBAEN,UAAA/C;AAAA,kBAAA;AAAA,gBAAA;AAAA,cACL;AAAA,YAAA;AAAA,UACJ;AAAA,QAAA,GAER,EAAA,CAER;AAAA,MAAA;AAAA,IAAA;AAAA,EACJ,GACJ;AAER;"}
1
+ {"version":3,"file":"DropdownMenu.js","sources":["../../../../../lib/@ecme/components/ui/Dropdown/DropdownMenu.tsx"],"sourcesContent":["import {\n useState,\n useRef,\n useContext,\n useEffect,\n useImperativeHandle,\n} from 'react'\nimport DropdownToggle from './DropdownToggle'\nimport DropdownSubItem from './DropdownSubItem'\nimport MenuContext from './context/menuContext'\nimport classNames from '../utils/classNames'\nimport { useConfig } from '../ConfigProvider'\nimport {\n autoUpdate,\n flip,\n FloatingFocusManager,\n FloatingList,\n FloatingNode,\n FloatingPortal,\n safePolygon,\n shift,\n useClick,\n useDismiss,\n useFloating,\n useFloatingNodeId,\n useFloatingParentNodeId,\n useFloatingTree,\n useHover,\n useInteractions,\n useListItem,\n useListNavigation,\n useMergeRefs,\n useRole,\n useTypeahead,\n useTransitionStyles,\n} from '@floating-ui/react'\nimport type { CommonProps } from '../@types/common'\nimport type { DropdownToggleSharedProps } from './DropdownToggle'\nimport type { DropdownSubItemSharedProps } from './DropdownSubItem'\nimport type { Placement } from '@floating-ui/react'\nimport type { HTMLProps, FocusEvent, MouseEvent, ReactNode, Ref } from 'react'\n\nexport interface DropdownMenuProps\n extends CommonProps,\n DropdownToggleSharedProps,\n DropdownSubItemSharedProps {\n activeKey?: string\n title?: string | ReactNode\n menuClass?: string\n trigger?: 'click' | 'hover' | 'context'\n placement?: Placement\n onOpen?: (bool: boolean) => void\n ref?: Ref<HTMLElement | DropdownMenuRef>\n}\n\nexport type DropdownMenuRef = {\n handleDropdownOpen: () => void\n handleDropdownClose: () => void\n}\n\nconst DropdownMenu = (props: DropdownMenuProps & HTMLProps<HTMLElement>) => {\n const {\n children,\n title,\n renderTitle,\n disabled,\n toggleClassName,\n menuClass,\n placement,\n trigger = 'click',\n onOpen,\n ref,\n ...rest\n } = props\n\n const [isOpen, setIsOpen] = useState(false)\n const [hasFocusInside, setHasFocusInside] = useState(false)\n const [activeIndex, setActiveIndex] = useState<number | null>(null)\n\n const elementsRef = useRef<Array<HTMLElement | null>>([])\n const labelsRef = useRef<Array<string | null>>([])\n\n const { direction } = useConfig()\n\n const parent = useContext(MenuContext)\n\n const tree = useFloatingTree()\n const nodeId = useFloatingNodeId()\n const parentId = useFloatingParentNodeId()\n const item = useListItem()\n\n const isNested = parentId != null\n\n const handleOpen = (open: boolean) => {\n if (disabled) {\n return\n }\n setIsOpen(open)\n onOpen?.(open)\n }\n\n const getDefaultPlacement = () => {\n return direction === 'ltr' ? 'bottom-start' : 'bottom-end'\n }\n\n const getNestedDefaultPlacement = () => {\n return direction === 'ltr' ? 'right-start' : 'left-start'\n }\n\n const { floatingStyles, refs, context } = useFloating<HTMLElement>({\n nodeId,\n open: isOpen,\n onOpenChange: (open) => {\n handleOpen(open)\n },\n placement:\n placement ||\n (isNested ? getNestedDefaultPlacement() : getDefaultPlacement()),\n middleware: [flip(), shift()],\n whileElementsMounted: autoUpdate,\n })\n\n const { isMounted, styles } = useTransitionStyles(context, {\n common: ({ side }) => ({\n transformOrigin: {\n top: 'bottom',\n bottom: 'top',\n left: 'right',\n right: 'left',\n }[side],\n }),\n initial: {\n transform: 'translateY(-5%)',\n opacity: 0,\n },\n duration: 200,\n open: {\n opacity: 1,\n transform: 'translateY(0%)',\n },\n close: {\n opacity: 0,\n transform: 'translateY(-5%)',\n },\n })\n\n const hover = useHover(context, {\n enabled: isNested || trigger === 'hover',\n delay: { open: 75 },\n handleClose: safePolygon({ blockPointerEvents: true }),\n })\n\n const click = useClick(context, {\n event: 'mousedown',\n toggle: !isNested,\n ignoreMouse: isNested,\n })\n\n const role = useRole(context, { role: 'menu' })\n\n const dismiss = useDismiss(context, { bubbles: true })\n\n const listNavigation = useListNavigation(context, {\n listRef: elementsRef,\n activeIndex,\n nested: isNested,\n onNavigate: setActiveIndex,\n })\n const typeahead = useTypeahead(context, {\n listRef: labelsRef,\n onMatch: isOpen ? setActiveIndex : undefined,\n activeIndex,\n })\n\n const { getReferenceProps, getFloatingProps, getItemProps } =\n useInteractions([\n hover,\n role,\n dismiss,\n listNavigation,\n typeahead,\n ...(trigger === 'click' ? [click] : []),\n ])\n\n useEffect(() => {\n if (!tree) return\n\n function handleTreeClick() {\n setIsOpen(false)\n onOpen?.(false)\n }\n\n function onSubMenuOpen(event: { nodeId: string; parentId: string }) {\n if (event.nodeId !== nodeId && event.parentId === parentId) {\n setIsOpen(false)\n onOpen?.(false)\n }\n }\n\n tree.events.on('click', handleTreeClick)\n tree.events.on('menuopen', onSubMenuOpen)\n\n return () => {\n tree.events.off('click', handleTreeClick)\n tree.events.off('menuopen', onSubMenuOpen)\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [tree, nodeId, parentId])\n\n useEffect(() => {\n if (isOpen && tree) {\n tree.events.emit('menuopen', { parentId, nodeId })\n }\n }, [tree, isOpen, nodeId, parentId])\n\n const toggleRef = useMergeRefs([refs.setReference, item.ref, ref])\n\n useImperativeHandle(ref, () => {\n return {\n handleDropdownOpen: () => {\n setIsOpen(true)\n onOpen?.(true)\n },\n handleDropdownClose: () => {\n setIsOpen(false)\n onOpen?.(false)\n },\n }\n }, [onOpen])\n\n const toggleProps = {\n ...getReferenceProps(\n parent.getItemProps({\n ...rest,\n onFocus(event: FocusEvent<HTMLElement>) {\n rest.onFocus?.(event)\n setHasFocusInside(false)\n parent.setHasFocusInside(true)\n },\n }),\n ),\n ...(trigger === 'context'\n ? {\n onContextMenu: (e: MouseEvent<HTMLElement>) => {\n e.preventDefault()\n handleOpen(true)\n },\n }\n : {}),\n }\n\n return (\n <FloatingNode id={nodeId}>\n {!isNested ? (\n <DropdownToggle\n ref={toggleRef}\n role={'menuitem'}\n data-open={isOpen ? '' : undefined}\n data-focus-inside={hasFocusInside ? '' : undefined}\n className={classNames(toggleClassName)}\n disabled={disabled}\n placement={placement}\n renderTitle={renderTitle}\n {...toggleProps}\n >\n {title}\n </DropdownToggle>\n ) : (\n <li\n ref={toggleRef}\n tabIndex={parent.activeIndex === item.index ? 0 : -1}\n data-open={isOpen ? '' : undefined}\n data-nested={''}\n data-focus-inside={hasFocusInside ? '' : undefined}\n className={classNames(toggleClassName, 'outline-none')}\n {...toggleProps}\n >\n <DropdownSubItem>\n {renderTitle ? renderTitle : title}\n </DropdownSubItem>\n </li>\n )}\n <MenuContext.Provider\n value={{\n activeIndex,\n setActiveIndex,\n getItemProps,\n setHasFocusInside,\n isOpen,\n }}\n >\n <FloatingList elementsRef={elementsRef} labelsRef={labelsRef}>\n {isMounted && (\n <FloatingPortal>\n <FloatingFocusManager\n context={context}\n modal={false}\n initialFocus={isNested ? -1 : 0}\n returnFocus={!isNested}\n >\n <div\n ref={refs.setFloating}\n style={floatingStyles}\n {...getFloatingProps()}\n className=\"outline-none z-30\"\n >\n <ul\n className={classNames(\n 'dropdown-menu min-w-[160px]',\n menuClass,\n )}\n style={styles}\n >\n {children}\n </ul>\n </div>\n </FloatingFocusManager>\n </FloatingPortal>\n )}\n </FloatingList>\n </MenuContext.Provider>\n </FloatingNode>\n )\n}\n\nexport default DropdownMenu\n"],"names":["DropdownMenu","props","children","title","renderTitle","disabled","toggleClassName","menuClass","placement","trigger","onOpen","ref","rest","isOpen","setIsOpen","useState","hasFocusInside","setHasFocusInside","activeIndex","setActiveIndex","elementsRef","useRef","labelsRef","direction","useConfig","parent","useContext","MenuContext","tree","useFloatingTree","nodeId","useFloatingNodeId","parentId","useFloatingParentNodeId","item","useListItem","isNested","handleOpen","open","getDefaultPlacement","getNestedDefaultPlacement","floatingStyles","refs","context","useFloating","flip","shift","autoUpdate","isMounted","styles","useTransitionStyles","side","hover","useHover","safePolygon","click","useClick","role","useRole","dismiss","useDismiss","listNavigation","useListNavigation","typeahead","useTypeahead","getReferenceProps","getFloatingProps","getItemProps","useInteractions","useEffect","handleTreeClick","onSubMenuOpen","event","toggleRef","useMergeRefs","useImperativeHandle","toggleProps","jsxs","FloatingNode","jsx","classNames","DropdownSubItem","DropdownToggle","FloatingList","FloatingPortal","FloatingFocusManager"],"mappings":";;;;;;;;;AA4DA,MAAMA,KAAe,CAACC,MAAsD;AACxE,QAAM;AAAA,IACF,UAAAC;AAAA,IACA,OAAAC;AAAA,IACA,aAAAC;AAAA,IACA,UAAAC;AAAA,IACA,iBAAAC;AAAA,IACA,WAAAC;AAAA,IACA,WAAAC;AAAA,IACA,SAAAC,IAAU;AAAA,IACV,QAAAC;AAAA,IACA,KAAAC;AAAA,IACA,GAAGC;AAAA,EAAA,IACHX,GAEE,CAACY,GAAQC,CAAS,IAAIC,EAAS,EAAK,GACpC,CAACC,GAAgBC,CAAiB,IAAIF,EAAS,EAAK,GACpD,CAACG,GAAaC,CAAc,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A;AAAA,EACJ,GACJ;AAER;"}
@@ -1,43 +1,43 @@
1
- import { jsx as t, jsxs as C } from "react/jsx-runtime";
1
+ import { jsx as e, jsxs as C } from "react/jsx-runtime";
2
2
  import { useContext as b } from "react";
3
3
  import x from "lodash/isNil";
4
4
  import N from "../hooks/useUncertainRef.js";
5
- import y from "../hooks/useUniqueId.js";
5
+ import w from "../hooks/useUniqueId.js";
6
6
  import "../ConfigProvider/index.js";
7
- import I from "../utils/classNames.js";
8
- import K from "./context/dropdownContext.js";
9
- import R from "../MenuItem/index.js";
10
- import { TbChevronLeft as g, TbChevronRight as j } from "react-icons/tb";
11
- import { useConfig as D } from "../ConfigProvider/ConfigProvider.js";
12
- const z = (i) => {
7
+ import y from "../utils/classNames.js";
8
+ import I from "./context/dropdownContext.js";
9
+ import K from "../MenuItem/index.js";
10
+ import { TbChevronLeft as R, TbChevronRight as g } from "react-icons/tb";
11
+ import { useConfig as j } from "../ConfigProvider/ConfigProvider.js";
12
+ const z = (r) => {
13
13
  const {
14
- asElement: m = "li",
15
- children: r,
16
- active: n,
14
+ asElement: n = "li",
15
+ children: i,
16
+ active: m,
17
17
  disabled: s,
18
18
  className: c,
19
19
  style: a,
20
- eventKey: o,
20
+ eventKey: t,
21
21
  onSelect: l,
22
- ref: f = null,
23
- ...u
24
- } = i, { direction: p } = D(), e = b(K), v = N(
25
- f
26
- ), d = y("menu-item-"), h = n || !x(e == null ? void 0 : e.activeKey) && (e == null ? void 0 : e.activeKey) === o;
27
- return /* @__PURE__ */ t("ul", { style: a, className: "relative", ...u, children: /* @__PURE__ */ C(
28
- R,
22
+ ref: p = null,
23
+ ...f
24
+ } = r, { direction: u } = j(), o = b(I), d = N(
25
+ p
26
+ ), v = w("menu-item-"), h = m || !x(o?.activeKey) && o?.activeKey === t;
27
+ return /* @__PURE__ */ e("ul", { style: a, className: "relative", ...f, children: /* @__PURE__ */ C(
28
+ K,
29
29
  {
30
- ref: v,
30
+ ref: d,
31
31
  disabled: s,
32
- asElement: m,
33
- id: d,
32
+ asElement: n,
33
+ id: v,
34
34
  isActive: h,
35
- eventKey: o,
36
- className: I("dropdown-submenu-item", c),
35
+ eventKey: t,
36
+ className: y("dropdown-submenu-item", c),
37
37
  onSelect: l,
38
38
  children: [
39
- /* @__PURE__ */ t("span", { children: r }),
40
- p === "rtl" ? /* @__PURE__ */ t(g, {}) : /* @__PURE__ */ t(j, {})
39
+ /* @__PURE__ */ e("span", { children: i }),
40
+ u === "rtl" ? /* @__PURE__ */ e(R, {}) : /* @__PURE__ */ e(g, {})
41
41
  ]
42
42
  }
43
43
  ) });
@@ -1 +1 @@
1
- {"version":3,"file":"DropdownSubItem.js","sources":["../../../../../lib/@ecme/components/ui/Dropdown/DropdownSubItem.tsx"],"sourcesContent":["import { useContext } from 'react'\nimport isNil from 'lodash/isNil'\nimport useUncertainRef from '../hooks/useUncertainRef'\nimport useUniqueId from '../hooks/useUniqueId'\nimport { useConfig } from '../ConfigProvider'\nimport classNames from '../utils/classNames'\nimport DropdownContext from './context/dropdownContext'\nimport MenuItem from '../MenuItem'\nimport { TbChevronRight, TbChevronLeft } from 'react-icons/tb'\nimport type { CommonProps } from '../@types/common'\nimport type { SyntheticEvent, RefObject, ElementType, Ref } from 'react'\n\nexport interface DropdownSubItemSharedProps {\n onClick?: (e: SyntheticEvent) => void\n onSelect?: (eventKey: string, e: MouseEvent) => void\n disabled?: boolean\n eventKey?: string\n}\n\ninterface DropdownSubItemProps extends CommonProps, DropdownSubItemSharedProps {\n asElement?: ElementType\n active?: boolean\n ref?: Ref<HTMLElement>\n}\n\nconst DropdownSubMenu = (props: DropdownSubItemProps) => {\n const {\n asElement: Component = 'li',\n children,\n active: activeProp,\n disabled,\n className,\n style,\n eventKey,\n onSelect,\n ref = null,\n ...rest\n } = props\n\n const { direction } = useConfig()\n\n const dropdown = useContext(DropdownContext)\n\n const menuitemRef = useUncertainRef<HTMLElement>(\n ref,\n ) as RefObject<HTMLElement | null>\n const menuitemId = useUniqueId('menu-item-')\n\n const active =\n activeProp ||\n (!isNil(dropdown?.activeKey) && dropdown?.activeKey === eventKey)\n\n return (\n <ul style={style} className=\"relative\" {...rest}>\n <MenuItem\n ref={menuitemRef}\n disabled={disabled}\n asElement={Component}\n id={menuitemId}\n isActive={active}\n eventKey={eventKey}\n className={classNames('dropdown-submenu-item', className)}\n onSelect={onSelect}\n >\n <span>{children}</span>\n {direction === 'rtl' ? <TbChevronLeft /> : <TbChevronRight />}\n </MenuItem>\n </ul>\n )\n}\n\nexport default DropdownSubMenu\n"],"names":["DropdownSubMenu","props","Component","children","activeProp","disabled","className","style","eventKey","onSelect","ref","rest","direction","useConfig","dropdown","useContext","DropdownContext","menuitemRef","useUncertainRef","menuitemId","useUniqueId","active","isNil","jsxs","MenuItem","classNames","jsx","TbChevronLeft","TbChevronRight"],"mappings":";;;;;;;;;;;AAyBA,MAAMA,IAAkB,CAACC,MAAgC;AACrD,QAAM;AAAA,IACF,WAAWC,IAAY;AAAA,IACvB,UAAAC;AAAA,IACA,QAAQC;AAAA,IACR,UAAAC;AAAA,IACA,WAAAC;AAAA,IACA,OAAAC;AAAA,IACA,UAAAC;AAAA,IACA,UAAAC;AAAA,IACA,KAAAC,IAAM;AAAA,IACN,GAAGC;AAAA,EAAA,IACHV,GAEE,EAAE,WAAAW,EAAA,IAAcC,EAAA,GAEhBC,IAAWC,EAAWC,CAAe,GAErCC,IAAcC;AAAA,IAChBR;AAAA,EAAA,GAEES,IAAaC,EAAY,YAAY,GAErCC,IACFjB,KACC,CAACkB,EAAMR,KAAA,gBAAAA,EAAU,SAAS,MAAKA,KAAA,gBAAAA,EAAU,eAAcN;AAE5D,2BACK,MAAA,EAAG,OAAAD,GAAc,WAAU,YAAY,GAAGI,GACvC,UAAA,gBAAAY;AAAA,IAACC;AAAA,IAAA;AAAA,MACG,KAAKP;AAAA,MACL,UAAAZ;AAAA,MACA,WAAWH;AAAA,MACX,IAAIiB;AAAA,MACJ,UAAUE;AAAA,MACV,UAAAb;AAAA,MACA,WAAWiB,EAAW,yBAAyBnB,CAAS;AAAA,MACxD,UAAAG;AAAA,MAEA,UAAA;AAAA,QAAA,gBAAAiB,EAAC,UAAM,UAAAvB,GAAS;AAAA,QACfS,MAAc,QAAQ,gBAAAc,EAACC,GAAA,CAAA,CAAc,sBAAMC,GAAA,CAAA,CAAe;AAAA,MAAA;AAAA,IAAA;AAAA,EAAA,GAEnE;AAER;"}
1
+ {"version":3,"file":"DropdownSubItem.js","sources":["../../../../../lib/@ecme/components/ui/Dropdown/DropdownSubItem.tsx"],"sourcesContent":["import { useContext } from 'react'\nimport isNil from 'lodash/isNil'\nimport useUncertainRef from '../hooks/useUncertainRef'\nimport useUniqueId from '../hooks/useUniqueId'\nimport { useConfig } from '../ConfigProvider'\nimport classNames from '../utils/classNames'\nimport DropdownContext from './context/dropdownContext'\nimport MenuItem from '../MenuItem'\nimport { TbChevronRight, TbChevronLeft } from 'react-icons/tb'\nimport type { CommonProps } from '../@types/common'\nimport type { SyntheticEvent, RefObject, ElementType, Ref } from 'react'\n\nexport interface DropdownSubItemSharedProps {\n onClick?: (e: SyntheticEvent) => void\n onSelect?: (eventKey: string, e: MouseEvent) => void\n disabled?: boolean\n eventKey?: string\n}\n\ninterface DropdownSubItemProps extends CommonProps, DropdownSubItemSharedProps {\n asElement?: ElementType\n active?: boolean\n ref?: Ref<HTMLElement>\n}\n\nconst DropdownSubMenu = (props: DropdownSubItemProps) => {\n const {\n asElement: Component = 'li',\n children,\n active: activeProp,\n disabled,\n className,\n style,\n eventKey,\n onSelect,\n ref = null,\n ...rest\n } = props\n\n const { direction } = useConfig()\n\n const dropdown = useContext(DropdownContext)\n\n const menuitemRef = useUncertainRef<HTMLElement>(\n ref,\n ) as RefObject<HTMLElement | null>\n const menuitemId = useUniqueId('menu-item-')\n\n const active =\n activeProp ||\n (!isNil(dropdown?.activeKey) && dropdown?.activeKey === eventKey)\n\n return (\n <ul style={style} className=\"relative\" {...rest}>\n <MenuItem\n ref={menuitemRef}\n disabled={disabled}\n asElement={Component}\n id={menuitemId}\n isActive={active}\n eventKey={eventKey}\n className={classNames('dropdown-submenu-item', className)}\n onSelect={onSelect}\n >\n <span>{children}</span>\n {direction === 'rtl' ? <TbChevronLeft /> : <TbChevronRight />}\n </MenuItem>\n </ul>\n )\n}\n\nexport default DropdownSubMenu\n"],"names":["DropdownSubMenu","props","Component","children","activeProp","disabled","className","style","eventKey","onSelect","ref","rest","direction","useConfig","dropdown","useContext","DropdownContext","menuitemRef","useUncertainRef","menuitemId","useUniqueId","active","isNil","jsxs","MenuItem","classNames","jsx","TbChevronLeft","TbChevronRight"],"mappings":";;;;;;;;;;;AAyBA,MAAMA,IAAkB,CAACC,MAAgC;AACrD,QAAM;AAAA,IACF,WAAWC,IAAY;AAAA,IACvB,UAAAC;AAAA,IACA,QAAQC;AAAA,IACR,UAAAC;AAAA,IACA,WAAAC;AAAA,IACA,OAAAC;AAAA,IACA,UAAAC;AAAA,IACA,UAAAC;AAAA,IACA,KAAAC,IAAM;AAAA,IACN,GAAGC;AAAA,EAAA,IACHV,GAEE,EAAE,WAAAW,EAAA,IAAcC,EAAA,GAEhBC,IAAWC,EAAWC,CAAe,GAErCC,IAAcC;AAAA,IAChBR;AAAA,EAAA,GAEES,IAAaC,EAAY,YAAY,GAErCC,IACFjB,KACC,CAACkB,EAAMR,GAAU,SAAS,KAAKA,GAAU,cAAcN;AAE5D,2BACK,MAAA,EAAG,OAAAD,GAAc,WAAU,YAAY,GAAGI,GACvC,UAAA,gBAAAY;AAAA,IAACC;AAAA,IAAA;AAAA,MACG,KAAKP;AAAA,MACL,UAAAZ;AAAA,MACA,WAAWH;AAAA,MACX,IAAIiB;AAAA,MACJ,UAAUE;AAAA,MACV,UAAAb;AAAA,MACA,WAAWiB,EAAW,yBAAyBnB,CAAS;AAAA,MACxD,UAAAG;AAAA,MAEA,UAAA;AAAA,QAAA,gBAAAiB,EAAC,UAAM,UAAAvB,GAAS;AAAA,QACfS,MAAc,QAAQ,gBAAAc,EAACC,GAAA,CAAA,CAAc,sBAAMC,GAAA,CAAA,CAAe;AAAA,MAAA;AAAA,IAAA;AAAA,EAAA,GAEnE;AAER;"}