@ozdao/prometheus-framework 0.2.111 → 0.2.113

Sign up to get free protection for your applications and to get access to all the features.
Files changed (533) hide show
  1. package/dist/common.schema-BFhpUXUt.js +12 -0
  2. package/dist/common.schema-ChBVARrs.mjs +13 -0
  3. package/dist/community.server.js +6 -4
  4. package/dist/community.server.mjs +4 -2
  5. package/dist/engagement.schema-CI2ifjXN.mjs +28 -0
  6. package/dist/engagement.schema-fdLNO2_6.js +27 -0
  7. package/dist/events.server.js +6 -4
  8. package/dist/events.server.mjs +4 -2
  9. package/dist/files.server.js +81 -29
  10. package/dist/files.server.mjs +81 -29
  11. package/dist/gallery.server.js +66 -39
  12. package/dist/gallery.server.mjs +66 -39
  13. package/dist/main-8APITHuW.mjs +14201 -0
  14. package/dist/main-8N2Jmsuk.js +2 -2
  15. package/dist/main-BJvlNekm.mjs +5 -5
  16. package/dist/main-BQisDfLk.js +2 -2
  17. package/dist/main-BV1Yv9Hy.js +2 -2
  18. package/dist/main-Bw0PvTs-.mjs +5 -5
  19. package/dist/main-ByCtZbHD.mjs +5 -5
  20. package/dist/main-CX2ISR43.mjs +5 -5
  21. package/dist/main-CXObXjv-.js +2 -2
  22. package/dist/main-CkeuHuCY.mjs +5 -5
  23. package/dist/main-CnfcBov2.mjs +5 -5
  24. package/dist/main-D50VqYhy.js +2 -2
  25. package/dist/main-D8gNZLSa.js +2 -2
  26. package/dist/main-DPsHxX0l.mjs +5 -5
  27. package/dist/main-DTlUA63C.mjs +5 -5
  28. package/dist/main-DfD5hLQo.mjs +5 -5
  29. package/dist/main-Dh6Zfei9.js +2 -2
  30. package/dist/main-DmNP-t33.mjs +5 -5
  31. package/dist/main-DwyUYWFX.js +2 -2
  32. package/dist/main-VcxO-jAt.js +92 -0
  33. package/dist/main-cffh4bbv.js +2 -2
  34. package/dist/main-pGo7JpSP.js +2 -2
  35. package/dist/main.css +1 -1
  36. package/dist/metadata.schema-6slGhpQS.js +40 -0
  37. package/dist/metadata.schema-CK5e2O3f.mjs +41 -0
  38. package/dist/node_modules/embla-carousel/esm/embla-carousel.esm.cjs +1 -1
  39. package/dist/node_modules/embla-carousel/esm/embla-carousel.esm.js +410 -407
  40. package/dist/node_modules/vue-qrcode-reader/dist/vue-qrcode-reader.cjs +3 -3
  41. package/dist/node_modules/vue-qrcode-reader/dist/vue-qrcode-reader.js +469 -456
  42. package/dist/node_modules/web3/lib/esm/accounts.cjs +1 -1
  43. package/dist/node_modules/web3/lib/esm/accounts.js +5 -2
  44. package/dist/node_modules/web3/lib/esm/index.cjs +1 -1
  45. package/dist/node_modules/web3/lib/esm/index.js +45 -42
  46. package/dist/node_modules/web3/lib/esm/version.cjs +1 -1
  47. package/dist/node_modules/web3/lib/esm/version.js +1 -1
  48. package/dist/node_modules/web3/lib/esm/web3.cjs +1 -1
  49. package/dist/node_modules/web3/lib/esm/web3.js +40 -37
  50. package/dist/node_modules/web3-core/lib/esm/web3_config.cjs +1 -1
  51. package/dist/node_modules/web3-core/lib/esm/web3_config.js +28 -18
  52. package/dist/node_modules/web3-core/lib/esm/web3_context.cjs +1 -1
  53. package/dist/node_modules/web3-core/lib/esm/web3_context.js +56 -53
  54. package/dist/node_modules/web3-core/lib/esm/web3_request_manager.cjs +1 -1
  55. package/dist/node_modules/web3-core/lib/esm/web3_request_manager.js +100 -87
  56. package/dist/node_modules/web3-errors/lib/esm/error_codes.cjs +1 -1
  57. package/dist/node_modules/web3-errors/lib/esm/error_codes.js +97 -95
  58. package/dist/node_modules/web3-errors/lib/esm/errors/contract_errors.cjs +1 -1
  59. package/dist/node_modules/web3-errors/lib/esm/errors/contract_errors.js +8 -8
  60. package/dist/node_modules/web3-errors/lib/esm/errors/response_errors.cjs +1 -1
  61. package/dist/node_modules/web3-errors/lib/esm/errors/response_errors.js +20 -20
  62. package/dist/node_modules/web3-errors/lib/esm/errors/transaction_errors.cjs +4 -4
  63. package/dist/node_modules/web3-errors/lib/esm/errors/transaction_errors.js +2 -2
  64. package/dist/node_modules/web3-errors/lib/esm/errors/utils_errors.cjs +1 -1
  65. package/dist/node_modules/web3-errors/lib/esm/errors/utils_errors.js +33 -27
  66. package/dist/node_modules/web3-errors/lib/esm/web3_error_base.cjs +1 -1
  67. package/dist/node_modules/web3-errors/lib/esm/web3_error_base.js +33 -12
  68. package/dist/node_modules/web3-eth/lib/esm/rpc_method_wrappers.cjs +1 -1
  69. package/dist/node_modules/web3-eth/lib/esm/rpc_method_wrappers.js +183 -179
  70. package/dist/node_modules/web3-eth/lib/esm/utils/get_revert_reason.cjs +1 -1
  71. package/dist/node_modules/web3-eth/lib/esm/utils/get_revert_reason.js +10 -10
  72. package/dist/node_modules/web3-eth/lib/esm/utils/get_transaction_gas_pricing.cjs +1 -1
  73. package/dist/node_modules/web3-eth/lib/esm/utils/get_transaction_gas_pricing.js +45 -44
  74. package/dist/node_modules/web3-eth/lib/esm/utils/send_tx_helper.cjs +1 -1
  75. package/dist/node_modules/web3-eth/lib/esm/utils/send_tx_helper.js +59 -57
  76. package/dist/node_modules/web3-eth/lib/esm/utils/transaction_builder.cjs +1 -1
  77. package/dist/node_modules/web3-eth/lib/esm/utils/transaction_builder.js +43 -43
  78. package/dist/node_modules/web3-eth/lib/esm/utils/wait_for_transaction_receipt.cjs +1 -1
  79. package/dist/node_modules/web3-eth/lib/esm/utils/wait_for_transaction_receipt.js +31 -31
  80. package/dist/node_modules/web3-eth/lib/esm/utils/watch_transaction_by_polling.cjs +1 -1
  81. package/dist/node_modules/web3-eth/lib/esm/utils/watch_transaction_by_polling.js +26 -26
  82. package/dist/node_modules/web3-eth/lib/esm/utils/watch_transaction_by_subscription.cjs +1 -1
  83. package/dist/node_modules/web3-eth/lib/esm/utils/watch_transaction_by_subscription.js +53 -51
  84. package/dist/node_modules/web3-eth/lib/esm/utils/watch_transaction_for_confirmations.cjs +1 -1
  85. package/dist/node_modules/web3-eth/lib/esm/utils/watch_transaction_for_confirmations.js +25 -23
  86. package/dist/node_modules/web3-eth/lib/esm/web3_eth.cjs +1 -1
  87. package/dist/node_modules/web3-eth/lib/esm/web3_eth.js +103 -101
  88. package/dist/node_modules/web3-eth-contract/lib/esm/contract.cjs +2 -2
  89. package/dist/node_modules/web3-eth-contract/lib/esm/contract.js +159 -156
  90. package/dist/node_modules/web3-eth-contract/lib/esm/encoding.cjs +1 -1
  91. package/dist/node_modules/web3-eth-contract/lib/esm/encoding.js +11 -8
  92. package/dist/node_modules/web3-eth-contract/lib/esm/index.cjs +1 -1
  93. package/dist/node_modules/web3-eth-contract/lib/esm/index.js +3 -0
  94. package/dist/node_modules/web3-eth-contract/lib/esm/log_subscription.cjs +1 -1
  95. package/dist/node_modules/web3-eth-contract/lib/esm/log_subscription.js +5 -2
  96. package/dist/node_modules/web3-eth-ens/lib/esm/ens.cjs +1 -1
  97. package/dist/node_modules/web3-eth-ens/lib/esm/ens.js +19 -16
  98. package/dist/node_modules/web3-eth-ens/lib/esm/registry.cjs +1 -1
  99. package/dist/node_modules/web3-eth-ens/lib/esm/registry.js +5 -2
  100. package/dist/node_modules/web3-eth-personal/lib/esm/rpc_method_wrappers.cjs +1 -1
  101. package/dist/node_modules/web3-eth-personal/lib/esm/rpc_method_wrappers.js +50 -47
  102. package/dist/node_modules/web3-net/lib/esm/net.cjs +1 -1
  103. package/dist/node_modules/web3-net/lib/esm/net.js +27 -27
  104. package/dist/node_modules/web3-utils/lib/esm/converters.cjs +1 -1
  105. package/dist/node_modules/web3-utils/lib/esm/converters.js +100 -83
  106. package/dist/node_modules/web3-utils/lib/esm/formatter.cjs +1 -1
  107. package/dist/node_modules/web3-utils/lib/esm/formatter.js +123 -104
  108. package/dist/node_modules/web3-validator/lib/esm/utils.cjs +1 -1
  109. package/dist/node_modules/web3-validator/lib/esm/utils.js +21 -21
  110. package/dist/node_modules/web3-validator/lib/esm/validation/bytes.cjs +1 -1
  111. package/dist/node_modules/web3-validator/lib/esm/validation/bytes.js +10 -10
  112. package/dist/node_modules/web3-validator/lib/esm/validation/numbers.cjs +1 -1
  113. package/dist/node_modules/web3-validator/lib/esm/validation/numbers.js +30 -28
  114. package/dist/orders.server.js +1 -1
  115. package/dist/orders.server.mjs +1 -1
  116. package/dist/organizations.server.js +56 -59
  117. package/dist/organizations.server.mjs +56 -59
  118. package/dist/products.server.js +1 -1
  119. package/dist/products.server.mjs +1 -1
  120. package/dist/prometheus-framework/src/components/Address/Address.vue2.cjs +1 -1
  121. package/dist/prometheus-framework/src/components/Address/Address.vue2.js +17 -17
  122. package/dist/prometheus-framework/src/components/Block/Block.vue.cjs +1 -1
  123. package/dist/prometheus-framework/src/components/Block/Block.vue.js +5 -5
  124. package/dist/prometheus-framework/src/components/Checkbox/Checkbox.vue.cjs +1 -1
  125. package/dist/prometheus-framework/src/components/Checkbox/Checkbox.vue.js +33 -30
  126. package/dist/prometheus-framework/src/components/Chips/Chips.vue.cjs +1 -1
  127. package/dist/prometheus-framework/src/components/Chips/Chips.vue.js +9 -9
  128. package/dist/prometheus-framework/src/components/DatePicker/Calendar.vue.cjs +1 -0
  129. package/dist/prometheus-framework/src/components/DatePicker/Calendar.vue.js +1 -0
  130. package/dist/prometheus-framework/src/components/DatePicker/Calendar.vue2.cjs +1 -0
  131. package/dist/prometheus-framework/src/components/DatePicker/Calendar.vue2.js +165 -0
  132. package/dist/prometheus-framework/src/components/Dropdown/Dropdown.vue.cjs +1 -1
  133. package/dist/prometheus-framework/src/components/Dropdown/Dropdown.vue.js +22 -19
  134. package/dist/prometheus-framework/src/components/Feed/Feed.vue.cjs +1 -1
  135. package/dist/prometheus-framework/src/components/Feed/Feed.vue.js +132 -64
  136. package/dist/prometheus-framework/src/components/Feed/Feed.vue2.cjs +1 -0
  137. package/dist/prometheus-framework/src/components/Feed/Feed.vue2.js +1 -0
  138. package/dist/prometheus-framework/src/components/FieldTags/BlockTags.vue.cjs +1 -1
  139. package/dist/prometheus-framework/src/components/FieldTags/BlockTags.vue.js +9 -9
  140. package/dist/prometheus-framework/src/components/FieldTags/FieldTags.vue.cjs +1 -1
  141. package/dist/prometheus-framework/src/components/FieldTags/FieldTags.vue.js +12 -12
  142. package/dist/prometheus-framework/src/components/LocationMarker/LocationMarker.vue2.cjs +1 -1
  143. package/dist/prometheus-framework/src/components/LocationMarker/LocationMarker.vue2.js +16 -16
  144. package/dist/prometheus-framework/src/components/Map/Map.vue.cjs +1 -1
  145. package/dist/prometheus-framework/src/components/Map/Map.vue.js +14 -13
  146. package/dist/prometheus-framework/src/components/Marquee/Marquee.vue.cjs +1 -0
  147. package/dist/prometheus-framework/src/components/Marquee/Marquee.vue.js +121 -0
  148. package/dist/prometheus-framework/src/components/Marquee/Marquee.vue2.cjs +1 -0
  149. package/dist/prometheus-framework/src/components/Marquee/Marquee.vue2.js +1 -0
  150. package/dist/prometheus-framework/src/components/Radio/Radio.vue.cjs +1 -1
  151. package/dist/prometheus-framework/src/components/Radio/Radio.vue.js +29 -36
  152. package/dist/prometheus-framework/src/components/Tooltip/Tooltip.vue.cjs +1 -1
  153. package/dist/prometheus-framework/src/components/Tooltip/Tooltip.vue.js +1 -45
  154. package/dist/prometheus-framework/src/components/Tooltip/Tooltip.vue2.cjs +1 -1
  155. package/dist/prometheus-framework/src/components/Tooltip/Tooltip.vue2.js +45 -1
  156. package/dist/prometheus-framework/src/modules/auth/components/layouts/Auth.vue.cjs +1 -1
  157. package/dist/prometheus-framework/src/modules/auth/components/layouts/Auth.vue.js +1 -1
  158. package/dist/prometheus-framework/src/modules/auth/components/pages/EnterCode.vue.cjs +1 -1
  159. package/dist/prometheus-framework/src/modules/auth/components/pages/EnterCode.vue.js +6 -6
  160. package/dist/prometheus-framework/src/modules/auth/components/pages/EnterPassword.vue.cjs +1 -1
  161. package/dist/prometheus-framework/src/modules/auth/components/pages/EnterPassword.vue.js +17 -17
  162. package/dist/prometheus-framework/src/modules/auth/components/pages/Invite.vue.cjs +1 -1
  163. package/dist/prometheus-framework/src/modules/auth/components/pages/Invite.vue.js +6 -6
  164. package/dist/prometheus-framework/src/modules/auth/components/pages/ResetPassword.vue.cjs +1 -1
  165. package/dist/prometheus-framework/src/modules/auth/components/pages/ResetPassword.vue.js +3 -3
  166. package/dist/prometheus-framework/src/modules/auth/components/pages/SignIn.vue.cjs +1 -1
  167. package/dist/prometheus-framework/src/modules/auth/components/pages/SignIn.vue.js +24 -24
  168. package/dist/prometheus-framework/src/modules/auth/components/pages/SignUp.vue.cjs +1 -1
  169. package/dist/prometheus-framework/src/modules/auth/components/pages/SignUp.vue.js +24 -24
  170. package/dist/prometheus-framework/src/modules/backoffice/components/pages/Dashboard.vue.cjs +1 -1
  171. package/dist/prometheus-framework/src/modules/backoffice/components/pages/Dashboard.vue.js +11 -11
  172. package/dist/prometheus-framework/src/modules/community/components/blocks/CardBlogpost.vue.cjs +1 -1
  173. package/dist/prometheus-framework/src/modules/community/components/blocks/CardBlogpost.vue.js +26 -26
  174. package/dist/prometheus-framework/src/modules/community/components/layouts/Community.vue.cjs +1 -1
  175. package/dist/prometheus-framework/src/modules/community/components/layouts/Community.vue.js +14 -14
  176. package/dist/prometheus-framework/src/modules/community/components/pages/BlogPost.vue.cjs +1 -1
  177. package/dist/prometheus-framework/src/modules/community/components/pages/BlogPost.vue.js +6 -6
  178. package/dist/prometheus-framework/src/modules/community/components/pages/CreateBlogPost.vue.cjs +1 -1
  179. package/dist/prometheus-framework/src/modules/community/components/pages/CreateBlogPost.vue.js +45 -45
  180. package/dist/prometheus-framework/src/modules/community/components/sections/Comments.vue.cjs +1 -1
  181. package/dist/prometheus-framework/src/modules/community/components/sections/Comments.vue.js +13 -13
  182. package/dist/prometheus-framework/src/modules/community/components/sections/Feed.vue.cjs +1 -1
  183. package/dist/prometheus-framework/src/modules/community/components/sections/Feed.vue.js +5 -5
  184. package/dist/prometheus-framework/src/modules/community/components/sections/HotPosts.vue.cjs +1 -1
  185. package/dist/prometheus-framework/src/modules/community/components/sections/HotPosts.vue.js +19 -16
  186. package/dist/prometheus-framework/src/modules/constructor/components/elements/Image.vue.cjs +1 -1
  187. package/dist/prometheus-framework/src/modules/constructor/components/elements/Image.vue.js +3 -3
  188. package/dist/prometheus-framework/src/modules/constructor/components/elements/Video.vue.cjs +1 -1
  189. package/dist/prometheus-framework/src/modules/constructor/components/elements/Video.vue.js +13 -13
  190. package/dist/prometheus-framework/src/modules/events/components/blocks/CardEvent.vue.cjs +1 -1
  191. package/dist/prometheus-framework/src/modules/events/components/blocks/CardEvent.vue.js +1 -1
  192. package/dist/prometheus-framework/src/modules/events/components/pages/EditEvent.vue.cjs +1 -1
  193. package/dist/prometheus-framework/src/modules/events/components/pages/EditEvent.vue.js +213 -213
  194. package/dist/prometheus-framework/src/modules/events/components/pages/EditEventTickets.vue.cjs +1 -1
  195. package/dist/prometheus-framework/src/modules/events/components/pages/EditEventTickets.vue.js +8 -8
  196. package/dist/prometheus-framework/src/modules/events/components/pages/Event.vue.cjs +2 -2
  197. package/dist/prometheus-framework/src/modules/events/components/pages/Event.vue.js +23 -23
  198. package/dist/prometheus-framework/src/modules/events/components/pages/Events.vue.cjs +1 -1
  199. package/dist/prometheus-framework/src/modules/events/components/pages/Events.vue.js +9 -9
  200. package/dist/prometheus-framework/src/modules/events/components/sections/Feed.vue.cjs +1 -1
  201. package/dist/prometheus-framework/src/modules/events/components/sections/Feed.vue.js +3 -3
  202. package/dist/prometheus-framework/src/modules/events/components/sections/List.vue.cjs +1 -1
  203. package/dist/prometheus-framework/src/modules/events/components/sections/List.vue.js +9 -9
  204. package/dist/prometheus-framework/src/modules/gallery/components/pages/Gallery.vue.js +8 -8
  205. package/dist/prometheus-framework/src/modules/gallery/components/sections/BackofficeGallery.vue.cjs +1 -1
  206. package/dist/prometheus-framework/src/modules/gallery/components/sections/BackofficeGallery.vue.js +167 -202
  207. package/dist/prometheus-framework/src/modules/gallery/components/sections/GalleryWithCategories.vue.cjs +1 -1
  208. package/dist/prometheus-framework/src/modules/gallery/components/sections/GalleryWithCategories.vue.js +73 -165
  209. package/dist/prometheus-framework/src/modules/gallery/store/gallery.cjs +1 -1
  210. package/dist/prometheus-framework/src/modules/gallery/store/gallery.js +3 -47
  211. package/dist/prometheus-framework/src/modules/globals/components/blocks/BlockSearch.vue.cjs +1 -1
  212. package/dist/prometheus-framework/src/modules/globals/components/blocks/BlockSearch.vue.js +1 -1
  213. package/dist/prometheus-framework/src/modules/globals/components/blocks/BlockSorting.vue.cjs +1 -0
  214. package/dist/prometheus-framework/src/modules/globals/components/blocks/BlockSorting.vue.js +75 -0
  215. package/dist/prometheus-framework/src/modules/globals/components/blocks/CardHeader.vue.cjs +1 -1
  216. package/dist/prometheus-framework/src/modules/globals/components/blocks/CardHeader.vue.js +96 -77
  217. package/dist/prometheus-framework/src/modules/globals/components/elements/ButtonDate.vue.cjs +1 -0
  218. package/dist/prometheus-framework/src/modules/globals/components/elements/ButtonDate.vue.js +1 -0
  219. package/dist/prometheus-framework/src/modules/globals/components/elements/ButtonDate.vue2.cjs +1 -0
  220. package/dist/prometheus-framework/src/modules/globals/components/elements/ButtonDate.vue2.js +27 -0
  221. package/dist/prometheus-framework/src/modules/globals/components/elements/ButtonSort.vue.cjs +1 -0
  222. package/dist/prometheus-framework/src/modules/globals/components/elements/ButtonSort.vue.js +31 -0
  223. package/dist/prometheus-framework/src/modules/globals/services/globals.store.cjs +1 -1
  224. package/dist/prometheus-framework/src/modules/globals/services/globals.store.js +21 -19
  225. package/dist/prometheus-framework/src/modules/globals/store/globals.cjs +1 -1
  226. package/dist/prometheus-framework/src/modules/globals/store/globals.js +10 -4
  227. package/dist/prometheus-framework/src/modules/icons/navigation/IconCalendar.vue.cjs +1 -0
  228. package/dist/prometheus-framework/src/modules/icons/navigation/IconCalendar.vue.js +31 -0
  229. package/dist/prometheus-framework/src/modules/icons/navigation/IconFilter.vue.cjs +1 -0
  230. package/dist/prometheus-framework/src/modules/icons/navigation/IconFilter.vue.js +31 -0
  231. package/dist/prometheus-framework/src/modules/icons/navigation/IconSort.vue.cjs +1 -0
  232. package/dist/prometheus-framework/src/modules/icons/navigation/IconSort.vue.js +59 -0
  233. package/dist/prometheus-framework/src/modules/landing/components/sections/SubscribeNewsletter.vue.cjs +1 -0
  234. package/dist/prometheus-framework/src/modules/landing/components/sections/SubscribeNewsletter.vue.js +80 -0
  235. package/dist/prometheus-framework/src/modules/landing/components/sections/SubscribeNewsletter.vue2.cjs +1 -0
  236. package/dist/prometheus-framework/src/modules/landing/components/sections/SubscribeNewsletter.vue2.js +1 -0
  237. package/dist/prometheus-framework/src/modules/landing/landing.client.cjs +1 -1
  238. package/dist/prometheus-framework/src/modules/landing/landing.client.js +8 -6
  239. package/dist/prometheus-framework/src/modules/legal/components/pages/Legal.vue.cjs +1 -1
  240. package/dist/prometheus-framework/src/modules/legal/components/pages/Legal.vue.js +5 -5
  241. package/dist/prometheus-framework/src/modules/legal/components/pages/legal/Cookies.vue.cjs +1 -1
  242. package/dist/prometheus-framework/src/modules/legal/components/pages/legal/Cookies.vue.js +1 -1
  243. package/dist/prometheus-framework/src/modules/legal/components/pages/legal/EULA.vue.cjs +1 -1
  244. package/dist/prometheus-framework/src/modules/legal/components/pages/legal/EULA.vue.js +1 -1
  245. package/dist/prometheus-framework/src/modules/legal/components/pages/legal/Privacy.vue.cjs +1 -1
  246. package/dist/prometheus-framework/src/modules/legal/components/pages/legal/Privacy.vue.js +1 -1
  247. package/dist/prometheus-framework/src/modules/legal/components/pages/legal/Terms.vue.cjs +1 -1
  248. package/dist/prometheus-framework/src/modules/legal/components/pages/legal/Terms.vue.js +30 -30
  249. package/dist/prometheus-framework/src/modules/marketplace/store/marketplace.cjs +1 -1
  250. package/dist/prometheus-framework/src/modules/marketplace/store/marketplace.js +21 -45
  251. package/dist/prometheus-framework/src/modules/mobile/components/Menu/Menu.vue.cjs +1 -1
  252. package/dist/prometheus-framework/src/modules/mobile/components/Menu/Menu.vue.js +13 -1
  253. package/dist/prometheus-framework/src/modules/mobile/components/Menu/Menu.vue2.cjs +1 -1
  254. package/dist/prometheus-framework/src/modules/mobile/components/Menu/Menu.vue2.js +1 -13
  255. package/dist/prometheus-framework/src/modules/orders/components/blocks/CardOrderItem.vue.cjs +1 -1
  256. package/dist/prometheus-framework/src/modules/orders/components/blocks/CardOrderItem.vue.js +36 -36
  257. package/dist/prometheus-framework/src/modules/orders/components/blocks/StatusHistory.vue.cjs +1 -1
  258. package/dist/prometheus-framework/src/modules/orders/components/blocks/StatusHistory.vue.js +1 -1
  259. package/dist/prometheus-framework/src/modules/orders/components/pages/Order.vue.cjs +1 -1
  260. package/dist/prometheus-framework/src/modules/orders/components/pages/Order.vue.js +53 -53
  261. package/dist/prometheus-framework/src/modules/orders/components/pages/OrderBackoffice.vue.cjs +1 -1
  262. package/dist/prometheus-framework/src/modules/orders/components/pages/OrderBackoffice.vue.js +33 -33
  263. package/dist/prometheus-framework/src/modules/orders/components/pages/OrderCreate.vue.cjs +1 -1
  264. package/dist/prometheus-framework/src/modules/orders/components/pages/OrderCreate.vue.js +1 -1
  265. package/dist/prometheus-framework/src/modules/orders/components/pages/OrderCreateBackoffice.vue.cjs +1 -1
  266. package/dist/prometheus-framework/src/modules/orders/components/pages/OrderCreateBackoffice.vue.js +10 -10
  267. package/dist/prometheus-framework/src/modules/orders/components/pages/Orders.vue.cjs +1 -1
  268. package/dist/prometheus-framework/src/modules/orders/components/pages/Orders.vue.js +5 -5
  269. package/dist/prometheus-framework/src/modules/orders/components/partials/ShopCart.vue.cjs +1 -1
  270. package/dist/prometheus-framework/src/modules/orders/components/partials/ShopCart.vue.js +1 -1
  271. package/dist/prometheus-framework/src/modules/orders/components/sections/FormAddCustomer.vue.cjs +1 -1
  272. package/dist/prometheus-framework/src/modules/orders/components/sections/FormAddCustomer.vue.js +24 -24
  273. package/dist/prometheus-framework/src/modules/orders/components/sections/FormDelivery.vue.cjs +1 -1
  274. package/dist/prometheus-framework/src/modules/orders/components/sections/FormDelivery.vue.js +5 -5
  275. package/dist/prometheus-framework/src/modules/orders/store/applications.cjs +1 -0
  276. package/dist/prometheus-framework/src/modules/orders/store/applications.js +37 -0
  277. package/dist/prometheus-framework/src/modules/organizations/components/blocks/CardOrganization.vue.cjs +1 -1
  278. package/dist/prometheus-framework/src/modules/organizations/components/blocks/CardOrganization.vue.js +5 -5
  279. package/dist/prometheus-framework/src/modules/organizations/components/blocks/Contacts.vue.cjs +1 -1
  280. package/dist/prometheus-framework/src/modules/organizations/components/blocks/Contacts.vue.js +11 -11
  281. package/dist/prometheus-framework/src/modules/organizations/components/blocks/DepartmentMemberModify.vue.cjs +1 -1
  282. package/dist/prometheus-framework/src/modules/organizations/components/blocks/DepartmentMemberModify.vue.js +1 -1
  283. package/dist/prometheus-framework/src/modules/organizations/components/pages/Department.vue.cjs +1 -1
  284. package/dist/prometheus-framework/src/modules/organizations/components/pages/Department.vue.js +16 -16
  285. package/dist/prometheus-framework/src/modules/organizations/components/pages/DepartmentEdit.vue.cjs +1 -1
  286. package/dist/prometheus-framework/src/modules/organizations/components/pages/DepartmentEdit.vue.js +41 -41
  287. package/dist/prometheus-framework/src/modules/organizations/components/pages/Members.vue.cjs +1 -1
  288. package/dist/prometheus-framework/src/modules/organizations/components/pages/Members.vue.js +11 -11
  289. package/dist/prometheus-framework/src/modules/organizations/components/pages/Organization.vue.cjs +1 -1
  290. package/dist/prometheus-framework/src/modules/organizations/components/pages/Organization.vue.js +17 -17
  291. package/dist/prometheus-framework/src/modules/organizations/components/pages/OrganizationEdit.vue.cjs +1 -1
  292. package/dist/prometheus-framework/src/modules/organizations/components/pages/OrganizationEdit.vue.js +36 -36
  293. package/dist/prometheus-framework/src/modules/organizations/components/pages/Organizations.vue.cjs +1 -1
  294. package/dist/prometheus-framework/src/modules/organizations/components/pages/Organizations.vue.js +8 -8
  295. package/dist/prometheus-framework/src/modules/organizations/components/sections/DetailsTab.vue.cjs +1 -1
  296. package/dist/prometheus-framework/src/modules/organizations/components/sections/DetailsTab.vue.js +2 -2
  297. package/dist/prometheus-framework/src/modules/organizations/components/sections/Feed.vue.cjs +1 -1
  298. package/dist/prometheus-framework/src/modules/organizations/components/sections/Feed.vue.js +20 -20
  299. package/dist/prometheus-framework/src/modules/organizations/components/sections/MembersAdd.vue.cjs +1 -1
  300. package/dist/prometheus-framework/src/modules/organizations/components/sections/MembersAdd.vue.js +12 -12
  301. package/dist/prometheus-framework/src/modules/organizations/components/sections/Publics.vue.cjs +1 -1
  302. package/dist/prometheus-framework/src/modules/organizations/components/sections/Publics.vue.js +13 -13
  303. package/dist/prometheus-framework/src/modules/organizations/store/organizations.cjs +1 -1
  304. package/dist/prometheus-framework/src/modules/organizations/store/organizations.js +33 -34
  305. package/dist/prometheus-framework/src/modules/products/components/blocks/CardPosition.vue.cjs +1 -1
  306. package/dist/prometheus-framework/src/modules/products/components/blocks/CardPosition.vue.js +16 -16
  307. package/dist/prometheus-framework/src/modules/products/components/blocks/LeftoverPositions.vue.cjs +1 -1
  308. package/dist/prometheus-framework/src/modules/products/components/blocks/LeftoverPositions.vue.js +15 -15
  309. package/dist/prometheus-framework/src/modules/products/components/pages/Categories.vue.cjs +1 -1
  310. package/dist/prometheus-framework/src/modules/products/components/pages/Categories.vue.js +8 -8
  311. package/dist/prometheus-framework/src/modules/products/components/pages/EditLeftover.vue.cjs +1 -1
  312. package/dist/prometheus-framework/src/modules/products/components/pages/EditLeftover.vue.js +8 -8
  313. package/dist/prometheus-framework/src/modules/products/components/pages/Leftovers.vue.cjs +1 -1
  314. package/dist/prometheus-framework/src/modules/products/components/pages/Leftovers.vue.js +9 -9
  315. package/dist/prometheus-framework/src/modules/products/components/pages/Product.vue.cjs +1 -1
  316. package/dist/prometheus-framework/src/modules/products/components/pages/Product.vue.js +1 -1
  317. package/dist/prometheus-framework/src/modules/products/components/pages/ProductEdit.vue.cjs +1 -1
  318. package/dist/prometheus-framework/src/modules/products/components/pages/ProductEdit.vue.js +22 -22
  319. package/dist/prometheus-framework/src/modules/products/components/pages/Products.vue.cjs +1 -1
  320. package/dist/prometheus-framework/src/modules/products/components/pages/Products.vue.js +6 -6
  321. package/dist/prometheus-framework/src/modules/products/components/sections/EditProductInfo.vue.cjs +1 -1
  322. package/dist/prometheus-framework/src/modules/products/components/sections/EditProductInfo.vue.js +8 -8
  323. package/dist/prometheus-framework/src/modules/products/components/sections/FilterProducts.vue.js +14 -14
  324. package/dist/prometheus-framework/src/modules/products/components/sections/HeroRecommendation.vue.cjs +1 -1
  325. package/dist/prometheus-framework/src/modules/products/components/sections/HeroRecommendation.vue.js +51 -56
  326. package/dist/prometheus-framework/src/modules/products/components/sections/PopularProducts.vue.cjs +1 -1
  327. package/dist/prometheus-framework/src/modules/products/components/sections/PopularProducts.vue.js +4 -4
  328. package/dist/prometheus-framework/src/modules/products/components/sections/SectionProduct.vue.cjs +1 -1
  329. package/dist/prometheus-framework/src/modules/products/components/sections/SectionProduct.vue.js +32 -32
  330. package/dist/prometheus-framework/src/modules/products/components/sections/SortProducts.vue.cjs +1 -1
  331. package/dist/prometheus-framework/src/modules/products/components/sections/SortProducts.vue.js +1 -1
  332. package/dist/prometheus-framework/src/modules/products/products.client.cjs +1 -1
  333. package/dist/prometheus-framework/src/modules/products/products.client.js +28 -30
  334. package/dist/prometheus-framework/src/modules/reports/components/pages/BackofficeReports.vue.cjs +1 -1
  335. package/dist/prometheus-framework/src/modules/reports/components/pages/BackofficeReports.vue.js +12 -12
  336. package/dist/prometheus-framework/src/modules/spots/components/blocks/CardSpot.vue.cjs +1 -1
  337. package/dist/prometheus-framework/src/modules/spots/components/blocks/CardSpot.vue.js +30 -26
  338. package/dist/prometheus-framework/src/modules/users/components/blocks/CardUser.vue.cjs +1 -1
  339. package/dist/prometheus-framework/src/modules/users/components/blocks/CardUser.vue.js +6 -6
  340. package/dist/prometheus-framework/src/modules/users/components/pages/Profile.vue.cjs +1 -1
  341. package/dist/prometheus-framework/src/modules/users/components/pages/Profile.vue.js +35 -35
  342. package/dist/prometheus-framework/src/modules/users/components/pages/ProfileBlogposts.vue.cjs +1 -1
  343. package/dist/prometheus-framework/src/modules/users/components/pages/ProfileBlogposts.vue.js +11 -11
  344. package/dist/prometheus-framework/src/modules/users/components/pages/ProfileEdit.vue.cjs +1 -1
  345. package/dist/prometheus-framework/src/modules/users/components/pages/ProfileEdit.vue.js +41 -41
  346. package/dist/prometheus-framework/src/modules/users/components/pages/ProfileEvents.vue.cjs +1 -1
  347. package/dist/prometheus-framework/src/modules/users/components/pages/ProfileEvents.vue.js +13 -13
  348. package/dist/prometheus-framework/src/modules/users/components/sections/FeaturedUsers.vue.cjs +1 -0
  349. package/dist/prometheus-framework/src/modules/users/components/sections/FeaturedUsers.vue.js +102 -0
  350. package/dist/prometheus-framework/src/modules/users/components/sections/FeaturedUsers.vue2.cjs +1 -0
  351. package/dist/prometheus-framework/src/modules/users/components/sections/FeaturedUsers.vue2.js +1 -0
  352. package/dist/prometheus-framework/src/modules/users/users.client.cjs +1 -1
  353. package/dist/prometheus-framework/src/modules/users/users.client.js +8 -6
  354. package/dist/prometheus-framework/src/modules/wallet/views/components/pages/Payments.vue.cjs +1 -1
  355. package/dist/prometheus-framework/src/modules/wallet/views/components/pages/Payments.vue.js +8 -8
  356. package/dist/prometheus-framework/src/modules/wallet/views/components/pages/Wallet.vue.cjs +1 -1
  357. package/dist/prometheus-framework/src/modules/wallet/views/components/pages/Wallet.vue.js +14 -11
  358. package/dist/prometheus-framework.cjs.js +1 -1
  359. package/dist/prometheus-framework.es.js +1 -1
  360. package/dist/queryProcessor-BJoJAetd.mjs +162 -0
  361. package/dist/queryProcessor-DWf9tsis.js +161 -0
  362. package/dist/style.css +1 -1
  363. package/dist/wallet.server.js +1 -1
  364. package/dist/wallet.server.mjs +1 -1
  365. package/dist/web-TGdVOTnw.js +1 -0
  366. package/dist/web-_W9a_nWD.mjs +54 -0
  367. package/package.json +1 -1
  368. package/src/components/Address/Address.vue +1 -1
  369. package/src/components/AskToLogin/AskToLogin.vue +1 -1
  370. package/src/components/Block/Block.vue +1 -1
  371. package/src/components/Checkbox/Checkbox.vue +40 -43
  372. package/src/components/Chips/Chips.vue +2 -2
  373. package/src/components/DatePicker/Calendar.vue +29 -31
  374. package/src/components/Dropdown/Dropdown.vue +5 -11
  375. package/src/components/Feed/Feed.vue +98 -15
  376. package/src/components/FieldTags/BlockTags.vue +3 -3
  377. package/src/components/FieldTags/FieldTags.vue +1 -1
  378. package/src/components/FieldTags/vue-tags-input.scss +1 -1
  379. package/src/components/LocationMarker/LocationMarker.vue +1 -1
  380. package/src/components/LocationSelection/LocationSelection.vue +5 -30
  381. package/src/components/Map/LoaderGMaps.js +66 -0
  382. package/src/components/Map/Map.vue +2 -1
  383. package/src/components/Marquee/Marquee.vue +1 -1
  384. package/src/components/Radio/Radio.vue +36 -13
  385. package/src/configurator/components/pages/Styles.vue +1 -1
  386. package/src/modules/auth/components/layouts/Auth.vue +1 -1
  387. package/src/modules/auth/components/pages/EnterCode.vue +4 -4
  388. package/src/modules/auth/components/pages/EnterPassword.vue +2 -2
  389. package/src/modules/auth/components/pages/Invite.vue +2 -2
  390. package/src/modules/auth/components/pages/ResetPassword.vue +3 -3
  391. package/src/modules/auth/components/pages/SignIn.vue +4 -4
  392. package/src/modules/auth/components/pages/SignUp.vue +3 -3
  393. package/src/modules/backoffice/components/admin/Backcalls.vue +1 -1
  394. package/src/modules/backoffice/components/admin/FastOrders.vue +1 -1
  395. package/src/modules/backoffice/components/admin/Pages.vue +1 -1
  396. package/src/modules/backoffice/components/admin/ProductEdit.vue +1 -1
  397. package/src/modules/backoffice/components/admin/UserEdit.vue +1 -1
  398. package/src/modules/backoffice/components/admin/Users.vue +1 -1
  399. package/src/modules/backoffice/components/pages/Dashboard.vue +3 -3
  400. package/src/modules/community/components/blocks/CardBlogpost.vue +1 -1
  401. package/src/modules/community/components/layouts/Community.vue +2 -2
  402. package/src/modules/community/components/pages/BlogPost.vue +2 -2
  403. package/src/modules/community/components/pages/CreateBlogPost.vue +4 -4
  404. package/src/modules/community/components/sections/Comments.vue +2 -2
  405. package/src/modules/community/components/sections/Feed.vue +1 -1
  406. package/src/modules/community/components/sections/HotPosts.vue +1 -1
  407. package/src/modules/constructor/components/elements/Image.vue +1 -1
  408. package/src/modules/constructor/components/elements/Video.vue +2 -2
  409. package/src/modules/events/components/blocks/CardEvent.vue +1 -1
  410. package/src/modules/events/components/pages/EditEvent.vue +32 -32
  411. package/src/modules/events/components/pages/EditEventTickets.vue +1 -1
  412. package/src/modules/events/components/pages/Event.vue +3 -3
  413. package/src/modules/events/components/pages/Events.vue +4 -3
  414. package/src/modules/events/components/sections/Feed.vue +3 -3
  415. package/src/modules/events/components/sections/List.vue +2 -2
  416. package/src/modules/files/controllers/files.controller.js +8 -6
  417. package/src/modules/files/middlewares/server/middlewareBusboy.js +79 -14
  418. package/src/modules/files/routes/files.routes.js +11 -9
  419. package/src/modules/gallery/components/sections/BackofficeGallery.vue +158 -355
  420. package/src/modules/gallery/components/sections/GalleryWithCategories.vue +26 -244
  421. package/src/modules/gallery/controllers/gallery.controller.js +57 -38
  422. package/src/modules/gallery/models/photo.model.js +20 -11
  423. package/src/modules/gallery/routes/gallery.routes.js +3 -3
  424. package/src/modules/gallery/store/gallery.js +3 -78
  425. package/src/modules/globals/components/blocks/BlockSearch.vue +1 -1
  426. package/src/modules/globals/components/blocks/BlockSorting.vue +77 -0
  427. package/src/modules/globals/components/blocks/CardHeader.vue +27 -25
  428. package/src/modules/globals/components/elements/ButtonDate.vue +66 -0
  429. package/src/modules/globals/components/elements/ButtonSort.vue +41 -0
  430. package/src/modules/globals/components/layouts/Client.vue +273 -0
  431. package/src/{components/Footer → modules/globals/components/partials}/Footer.vue +1 -1
  432. package/src/{components/Header → modules/globals/components/partials}/Header.vue +98 -84
  433. package/src/modules/globals/controllers/utils/queryProcessor.js +3 -3
  434. package/src/modules/globals/models/common.schema.js +1 -1
  435. package/src/modules/globals/services/globals.store.js +11 -6
  436. package/src/modules/globals/store/globals.js +12 -10
  437. package/src/modules/icons/logos/Logotype.vue +23 -19
  438. package/src/modules/icons/navigation/IconCalendar.vue +18 -0
  439. package/src/modules/icons/navigation/IconFilter.vue +18 -0
  440. package/src/modules/icons/navigation/IconSearch.vue +1 -3
  441. package/src/modules/icons/navigation/IconSort.vue +21 -0
  442. package/src/modules/landing/components/pages/Home.vue +4 -4
  443. package/src/modules/landing/components/sections/FeatureSection.vue +5 -5
  444. package/src/modules/landing/components/sections/HowToBuyWDR.vue +2 -2
  445. package/src/modules/landing/components/sections/SectionFeature.vue +2 -2
  446. package/src/modules/landing/components/sections/SectionFeaturesImages.vue +2 -2
  447. package/src/modules/landing/components/sections/SectionsSection.vue +4 -4
  448. package/src/modules/{orders → landing}/components/sections/SubscribeNewsletter.vue +0 -2
  449. package/src/modules/landing/components/sections/WhatIsWDRSection.vue +6 -6
  450. package/src/modules/landing/landing.client.js +2 -0
  451. package/src/modules/landing/router/landing.js +1 -1
  452. package/src/modules/legal/components/pages/Legal.vue +2 -2
  453. package/src/modules/legal/components/pages/legal/Cookies.vue +1 -1
  454. package/src/modules/legal/components/pages/legal/EULA.vue +1 -1
  455. package/src/modules/legal/components/pages/legal/Privacy.vue +1 -1
  456. package/src/modules/legal/components/pages/legal/Terms.vue +1 -1
  457. package/src/modules/marketplace/components/layouts/Marketplace.vue +37 -49
  458. package/src/modules/marketplace/components/pages/Catalog.vue +43 -131
  459. package/src/modules/marketplace/components/sections/Filters.vue +63 -115
  460. package/src/modules/marketplace/store/marketplace.js +22 -167
  461. package/src/modules/mobile/components/Walkthrough/Walkthrough.vue +1 -1
  462. package/src/modules/orders/components/blocks/CardOrderItem.vue +6 -6
  463. package/src/modules/orders/components/blocks/CardOrderVar1.vue +1 -1
  464. package/src/modules/orders/components/blocks/StatusHistory.vue +1 -1
  465. package/src/modules/orders/components/pages/Order.vue +8 -8
  466. package/src/modules/orders/components/pages/OrderBackoffice.vue +7 -7
  467. package/src/modules/orders/components/pages/OrderCreate.vue +1 -1
  468. package/src/modules/orders/components/pages/OrderCreateBackoffice.vue +3 -3
  469. package/src/modules/orders/components/pages/Orders.vue +3 -5
  470. package/src/modules/orders/components/partials/ShopCart.vue +5 -1
  471. package/src/modules/orders/components/sections/FormAddCustomer.vue +2 -2
  472. package/src/modules/orders/components/sections/FormDelivery.vue +1 -1
  473. package/src/modules/orders/store/applications.js +1 -1
  474. package/src/modules/organizations/components/blocks/CardOrganization.vue +1 -1
  475. package/src/modules/organizations/components/blocks/Contacts.vue +4 -4
  476. package/src/modules/organizations/components/pages/Department.vue +3 -3
  477. package/src/modules/organizations/components/pages/DepartmentEdit.vue +6 -6
  478. package/src/modules/organizations/components/pages/Members.vue +4 -4
  479. package/src/modules/organizations/components/pages/Organization.vue +3 -3
  480. package/src/modules/organizations/components/pages/OrganizationCreate.vue +2 -2
  481. package/src/modules/organizations/components/pages/OrganizationDetails.vue +1 -1
  482. package/src/modules/organizations/components/pages/OrganizationDocuments.vue +1 -1
  483. package/src/modules/organizations/components/pages/OrganizationEdit.vue +9 -9
  484. package/src/modules/organizations/components/pages/OrganizationPeople.vue +1 -1
  485. package/src/modules/organizations/components/pages/Organizations.vue +1 -1
  486. package/src/modules/organizations/components/sections/DetailsTab.vue +4 -4
  487. package/src/modules/organizations/components/sections/Feed.vue +2 -2
  488. package/src/modules/organizations/components/sections/MembersAdd.vue +2 -2
  489. package/src/modules/organizations/components/sections/Publics.vue +1 -1
  490. package/src/modules/organizations/controllers/organizations.controller.js +103 -93
  491. package/src/modules/organizations/models/organization.model.js +10 -7
  492. package/src/modules/organizations/store/organizations.js +3 -34
  493. package/src/modules/products/components/blocks/CardPosition.vue +2 -2
  494. package/src/modules/products/components/blocks/LeftoverPositions.vue +2 -2
  495. package/src/modules/products/components/pages/Categories.vue +1 -1
  496. package/src/modules/products/components/pages/EditLeftover.vue +1 -1
  497. package/src/modules/products/components/pages/Leftovers.vue +4 -4
  498. package/src/modules/products/components/pages/Product.vue +1 -5
  499. package/src/modules/products/components/pages/ProductEdit.vue +1 -1
  500. package/src/modules/products/components/pages/Products.vue +2 -2
  501. package/src/modules/products/components/sections/EditProductInfo.vue +1 -1
  502. package/src/modules/products/components/sections/FilterProducts.vue +1 -1
  503. package/src/modules/products/components/sections/HeroRecommendation.vue +67 -74
  504. package/src/modules/products/components/sections/MenuSection.vue +2 -2
  505. package/src/modules/products/components/sections/PopularProducts.vue +2 -2
  506. package/src/modules/products/components/sections/SectionProduct.vue +3 -3
  507. package/src/modules/products/products.client.js +0 -2
  508. package/src/modules/reports/components/pages/BackofficeReports.vue +4 -4
  509. package/src/modules/spots/components/blocks/CardSpot.vue +9 -1
  510. package/src/modules/spots/components/blocks/SpotMemberModify.vue +2 -2
  511. package/src/modules/spots/components/layouts/Spots.vue +0 -2
  512. package/src/modules/spots/components/pages/Spot.vue +4 -4
  513. package/src/modules/spots/components/pages/SpotEdit.vue +1 -1
  514. package/src/modules/spots/components/sections/PlaceModify.vue +1 -1
  515. package/src/modules/spots/components/sections/Places.vue +1 -1
  516. package/src/modules/users/components/blocks/CardUser.vue +3 -3
  517. package/src/modules/users/components/pages/Profile.vue +5 -5
  518. package/src/modules/users/components/pages/ProfileBlogposts.vue +1 -1
  519. package/src/modules/users/components/pages/ProfileComments.vue +1 -1
  520. package/src/modules/users/components/pages/ProfileEdit.vue +11 -11
  521. package/src/modules/users/components/pages/ProfileEvents.vue +1 -1
  522. package/src/modules/users/components/pages/ProfileLikes.vue +1 -1
  523. package/src/modules/users/components/sections/FeaturedUsers.vue +76 -14
  524. package/src/modules/users/users.client.js +5 -0
  525. package/src/modules/wallet/views/components/pages/Payments.vue +2 -2
  526. package/src/modules/wallet/views/components/pages/Wallet.vue +3 -3
  527. package/src/styles/base/borders.scss +4 -0
  528. package/src/styles/base/shadow_transitions_hover_refactor.scss +4 -0
  529. package/src/styles/config.scss +15 -9
  530. package/src/styles/layout.scss +37 -8
  531. package/src/styles/typography.scss +24 -24
  532. package/src/modules/products/components/sections/SortProducts.vue +0 -74
  533. /package/src/{components/Navigation → modules/globals/components/partials}/Navigation.vue +0 -0
@@ -1,21 +1,21 @@
1
- import { keccak256 as U } from "../../../ethereum-cryptography/esm/keccak.js";
2
- import { bytesToUtf8 as w } from "../../../ethereum-cryptography/esm/utils.js";
3
- import { InvalidBytesError as C, HexProcessingError as W, InvalidNumberError as A, InvalidUnitError as S, InvalidAddressError as k, InvalidBooleanError as D } from "../../../web3-errors/lib/esm/errors/utils_errors.js";
1
+ import { keccak256 as W } from "../../../ethereum-cryptography/esm/keccak.js";
2
+ import { bytesToUtf8 as a } from "../../../ethereum-cryptography/esm/utils.js";
3
+ import { InvalidBytesError as u, HexProcessingError as k, InvalidNumberError as A, InvalidUnitError as N, InvalidIntegerError as S, InvalidAddressError as D, InvalidBooleanError as L } from "../../../web3-errors/lib/esm/errors/utils_errors.js";
4
4
  import "../../../web3-errors/lib/esm/errors/rpc_errors.js";
5
5
  import "../../../web3-validator/lib/esm/formats.js";
6
- import * as M from "../../../web3-validator/lib/esm/utils.js";
7
- import { hexToUint8Array as _, hexToNumber as F, numberToHex as G, uint8ArrayToHexString as L, ensureIfUint8Array as O } from "../../../web3-validator/lib/esm/utils.js";
6
+ import * as V from "../../../web3-validator/lib/esm/utils.js";
7
+ import { hexToUint8Array as _, hexToNumber as F, numberToHex as G, uint8ArrayToHexString as M, ensureIfUint8Array as P } from "../../../web3-validator/lib/esm/utils.js";
8
8
  import { validator as s } from "../../../web3-validator/lib/esm/default_validator.js";
9
- import { isAddress as a } from "../../../web3-validator/lib/esm/validation/address.js";
9
+ import { isAddress as T } from "../../../web3-validator/lib/esm/validation/address.js";
10
10
  import "../../../web3-types/lib/esm/data_format_types.js";
11
11
  import "../../../web3-types/lib/esm/eth_types.js";
12
12
  import "../../../web3-types/lib/esm/web3_base_provider.js";
13
- import { isInt as b, isUInt as y } from "../../../web3-validator/lib/esm/validation/numbers.js";
14
- import { isHexStrict as m, isHex as x } from "../../../web3-validator/lib/esm/validation/string.js";
15
- import { isNullish as V } from "../../../web3-validator/lib/esm/validation/object.js";
16
- import { isUint8Array as T } from "./uint8array.js";
17
- import { utf8ToBytes as z } from "../../../@noble/hashes/esm/utils.js";
18
- const N = {
13
+ import { isInt as y, isUInt as w, bigintPower as l } from "../../../web3-validator/lib/esm/validation/numbers.js";
14
+ import { isHexStrict as m, isHex as B } from "../../../web3-validator/lib/esm/validation/string.js";
15
+ import { isNullish as z } from "../../../web3-validator/lib/esm/validation/object.js";
16
+ import { isUint8Array as $ } from "./uint8array.js";
17
+ import { utf8ToBytes as O } from "../../../@noble/hashes/esm/utils.js";
18
+ const H = {
19
19
  noether: BigInt(0),
20
20
  wei: BigInt(1),
21
21
  kwei: BigInt(1e3),
@@ -43,32 +43,32 @@ const N = {
43
43
  mether: BigInt("1000000000000000000000000"),
44
44
  gether: BigInt("1000000000000000000000000000"),
45
45
  tether: BigInt("1000000000000000000000000000000")
46
- }, d = (t) => {
47
- if (s.validate(["bytes"], [t]), T(t))
46
+ }, p = "Warning: Using type `number` with values that are large or contain many decimals may cause loss of precision, it is recommended to use type `string` or `BigInt` when using conversion methods", b = (t) => {
47
+ if (s.validate(["bytes"], [t]), $(t))
48
48
  return t;
49
49
  if (Array.isArray(t))
50
50
  return new Uint8Array(t);
51
51
  if (typeof t == "string")
52
52
  return _(t);
53
- throw new C(t);
54
- }, { uint8ArrayToHexString: P } = M, $ = (t) => P(d(t)), H = (t) => typeof t == "string" && t.slice(0, 2).toLowerCase() !== "0x" ? d(`0x${t}`) : d(t), p = (t) => (s.validate(["hex"], [t]), F(t)), f0 = p, g = (t, r) => {
53
+ throw new u(t);
54
+ }, { uint8ArrayToHexString: R } = V, E = (t) => R(b(t)), U = (t) => typeof t == "string" && t.slice(0, 2).toLowerCase() !== "0x" ? b(`0x${t}`) : b(t), x = (t) => (s.validate(["hex"], [t]), F(t)), m0 = x, g = (t, r) => {
55
55
  typeof t != "bigint" && s.validate(["int"], [t]);
56
- let n = G(t);
57
- return r && (!n.startsWith("-") && n.length % 2 === 1 ? n = "0x0".concat(n.slice(2)) : n.length % 2 === 0 && n.startsWith("-") && (n = "-0x0".concat(n.slice(3)))), n;
58
- }, c0 = g, g0 = (t) => p(t).toString(), h = (t) => {
56
+ let i = G(t);
57
+ return r && (!i.startsWith("-") && i.length % 2 === 1 ? i = "0x0".concat(i.slice(2)) : i.length % 2 === 0 && i.startsWith("-") && (i = "-0x0".concat(i.slice(3)))), i;
58
+ }, h0 = g, I0 = (t) => x(t).toString(), h = (t) => {
59
59
  s.validate(["string"], [t]);
60
60
  let r = t.replace(/^(?:\u0000)/, "");
61
- return r = r.replace(/(?:\u0000)$/, ""), $(new TextEncoder().encode(r));
62
- }, m0 = h, h0 = h, E = (t) => w(H(t)), I0 = (t) => typeof t == "string" ? E(t) : (s.validate(["bytes"], [t]), w(t)), R = z, B0 = E, X = (t) => {
61
+ return r = r.replace(/(?:\u0000)$/, ""), E(new TextEncoder().encode(r));
62
+ }, d0 = h, B0 = h, C = (t) => a(U(t)), p0 = (t) => typeof t == "string" ? C(t) : (s.validate(["bytes"], [t]), a(t)), X = O, b0 = C, j = (t) => {
63
63
  s.validate(["string"], [t]);
64
64
  let r = "";
65
- for (let n = 0; n < t.length; n += 1) {
66
- const i = t.charCodeAt(n).toString(16);
67
- r += i.length % 2 !== 0 ? `0${i}` : i;
65
+ for (let i = 0; i < t.length; i += 1) {
66
+ const n = t.charCodeAt(i).toString(16);
67
+ r += n.length % 2 !== 0 ? `0${n}` : n;
68
68
  }
69
69
  return `0x${r}`;
70
- }, x0 = X, Z = (t) => new TextDecoder("ascii").decode(H(t)), d0 = Z, p0 = (t, r) => {
71
- if (typeof t == "string" && a(t))
70
+ }, x0 = j, J = (t) => new TextDecoder("ascii").decode(U(t)), y0 = J, w0 = (t, r) => {
71
+ if (typeof t == "string" && T(t))
72
72
  return r ? "address" : `0x${t.toLowerCase().replace(/^0x/i, "")}`;
73
73
  if (typeof t == "boolean")
74
74
  return r ? "bool" : t ? "0x01" : "0x00";
@@ -76,8 +76,8 @@ const N = {
76
76
  return r ? t < 0 ? "int256" : "uint256" : g(t);
77
77
  if (typeof t == "bigint")
78
78
  return r ? "bigint" : g(t);
79
- if (T(t))
80
- return r ? "bytes" : $(t);
79
+ if ($(t))
80
+ return r ? "bytes" : E(t);
81
81
  if (typeof t == "object" && t)
82
82
  return r ? "string" : h(JSON.stringify(t));
83
83
  if (typeof t == "string") {
@@ -85,62 +85,79 @@ const N = {
85
85
  return r ? "int256" : g(t);
86
86
  if (m(t))
87
87
  return r ? "bytes" : t;
88
- if (x(t) && !b(t) && !y(t))
88
+ if (B(t) && !y(t) && !w(t))
89
89
  return r ? "bytes" : `0x${t}`;
90
- if (x(t) && !b(t) && y(t))
90
+ if (B(t) && !y(t) && w(t))
91
91
  return r ? "uint" : g(t);
92
92
  if (!Number.isFinite(t))
93
93
  return r ? "string" : h(t);
94
94
  }
95
- throw new W(t);
95
+ throw new k(t);
96
96
  }, I = (t) => {
97
97
  if (typeof t == "number")
98
- return t > 1e20 ? BigInt(t) : t;
98
+ return t > 1e20 ? (console.warn(p), BigInt(t)) : t;
99
99
  if (typeof t == "bigint")
100
100
  return t >= Number.MIN_SAFE_INTEGER && t <= Number.MAX_SAFE_INTEGER ? Number(t) : t;
101
101
  if (typeof t == "string" && m(t))
102
- return p(t);
102
+ return x(t);
103
103
  try {
104
104
  return I(BigInt(t));
105
105
  } catch {
106
106
  throw new A(t);
107
107
  }
108
- }, b0 = (t) => {
108
+ }, a0 = (t) => {
109
109
  if (typeof t == "number")
110
110
  return BigInt(t);
111
111
  if (typeof t == "bigint")
112
112
  return t;
113
- if (typeof t == "string" && x(t))
113
+ if (typeof t == "string" && B(t))
114
114
  return t.startsWith("-") ? -BigInt(t.substring(1)) : BigInt(t);
115
115
  throw new A(t);
116
- }, y0 = (t, r) => {
117
- const n = N[r];
118
- if (!n)
119
- throw new S(r);
120
- const i = String(I(t)), o = n.toString().length - 1;
116
+ }, A0 = (t, r) => {
117
+ let i;
118
+ if (typeof r == "string") {
119
+ if (i = H[r], !i)
120
+ throw new N(r);
121
+ } else {
122
+ if (r < 0 || !Number.isInteger(r))
123
+ throw new S(r);
124
+ i = l(BigInt(10), BigInt(r));
125
+ }
126
+ const n = String(I(t)), o = i.toString().length - 1;
121
127
  if (o <= 0)
122
- return i.toString();
123
- const e = i.padStart(o, "0"), f = e.slice(0, -o), c = e.slice(-o).replace(/\.?0+$/, "");
124
- return f === "" ? `0.${c}` : c === "" ? f : `${f}.${c}`;
125
- }, w0 = (t, r) => {
128
+ return n.toString();
129
+ const e = n.padStart(o, "0"), c = e.slice(0, -o), f = e.slice(-o).replace(/\.?0+$/, "");
130
+ return c === "" ? `0.${f}` : f === "" ? c : `${c}.${f}`.slice(0, c.length + o + 1);
131
+ }, N0 = (t, r) => {
126
132
  s.validate(["number"], [t]);
127
- const n = N[r];
128
- if (!n)
129
- throw new S(r);
130
- const [i, o] = String(typeof t == "string" && !m(t) ? t : I(t)).split(".").concat(""), f = BigInt(`${i}${o}`) * n, c = n.toString().length - 1, B = Math.min(o.length, c);
131
- return B === 0 ? f.toString() : f.toString().padStart(B, "0").slice(0, -B);
132
- }, A0 = (t) => {
133
- if (!a(t, !1))
134
- throw new k(t);
135
- const r = t.toLowerCase().replace(/^0x/i, ""), n = L(U(O(R(r))));
136
- if (V(n) || n === "0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470")
133
+ let i;
134
+ if (typeof r == "string") {
135
+ if (i = H[r], !i)
136
+ throw new N(r);
137
+ } else {
138
+ if (r < 0 || !Number.isInteger(r))
139
+ throw new S(r);
140
+ i = l(BigInt(10), BigInt(r));
141
+ }
142
+ let n = t;
143
+ typeof n == "number" && (n < 1e-15 && console.warn(p), n > 1e20 ? (console.warn(p), n = BigInt(n)) : n = n.toLocaleString("fullwide", {
144
+ useGrouping: !1,
145
+ maximumFractionDigits: 20
146
+ }));
147
+ const [o, e] = String(typeof n == "string" && !m(n) ? n : I(n)).split(".").concat(""), f = BigInt(`${o}${e}`) * i, d = e.length;
148
+ return d === 0 ? f.toString() : f.toString().slice(0, -d);
149
+ }, S0 = (t) => {
150
+ if (!T(t, !1))
151
+ throw new D(t);
152
+ const r = t.toLowerCase().replace(/^0x/i, ""), i = M(W(P(X(r))));
153
+ if (z(i) || i === "0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470")
137
154
  return "";
138
- let i = "0x";
139
- const o = n.replace(/^0x/i, "");
155
+ let n = "0x";
156
+ const o = i.replace(/^0x/i, "");
140
157
  for (let e = 0; e < r.length; e += 1)
141
- parseInt(o[e], 16) > 7 ? i += r[e].toUpperCase() : i += r[e];
142
- return i;
143
- }, S0 = (t) => {
158
+ parseInt(o[e], 16) > 7 ? n += r[e].toUpperCase() : n += r[e];
159
+ return n;
160
+ }, T0 = (t) => {
144
161
  if (typeof t == "boolean")
145
162
  return t;
146
163
  if (typeof t == "number" && (t === 0 || t === 1) || typeof t == "bigint" && (t === BigInt(0) || t === BigInt(1)))
@@ -149,34 +166,34 @@ const N = {
149
166
  return t === "true" ? !0 : t === "false" ? !1 : !!Number(t);
150
167
  if (typeof t == "string" && m(t) && (t === "0x1" || t === "0x0"))
151
168
  return !!I(t);
152
- throw new D(t);
169
+ throw new L(t);
153
170
  };
154
171
  export {
155
- X as asciiToHex,
156
- $ as bytesToHex,
157
- d as bytesToUint8Array,
158
- N as ethUnitMap,
172
+ j as asciiToHex,
173
+ E as bytesToHex,
174
+ b as bytesToUint8Array,
175
+ H as ethUnitMap,
159
176
  x0 as fromAscii,
160
- c0 as fromDecimal,
161
- m0 as fromUtf8,
162
- y0 as fromWei,
163
- Z as hexToAscii,
164
- H as hexToBytes,
165
- p as hexToNumber,
166
- g0 as hexToNumberString,
167
- B0 as hexToString,
168
- E as hexToUtf8,
177
+ h0 as fromDecimal,
178
+ d0 as fromUtf8,
179
+ A0 as fromWei,
180
+ J as hexToAscii,
181
+ U as hexToBytes,
182
+ x as hexToNumber,
183
+ I0 as hexToNumberString,
184
+ b0 as hexToString,
185
+ C as hexToUtf8,
169
186
  g as numberToHex,
170
- h0 as stringToHex,
171
- d0 as toAscii,
172
- b0 as toBigInt,
173
- S0 as toBool,
174
- A0 as toChecksumAddress,
175
- f0 as toDecimal,
176
- p0 as toHex,
187
+ B0 as stringToHex,
188
+ y0 as toAscii,
189
+ a0 as toBigInt,
190
+ T0 as toBool,
191
+ S0 as toChecksumAddress,
192
+ m0 as toDecimal,
193
+ w0 as toHex,
177
194
  I as toNumber,
178
- I0 as toUtf8,
179
- w0 as toWei,
180
- R as utf8ToBytes,
195
+ p0 as toUtf8,
196
+ N0 as toWei,
197
+ X as utf8ToBytes,
181
198
  h as utf8ToHex
182
199
  };
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const g=require("../../../web3-errors/lib/esm/errors/generic_errors.cjs");require("../../../web3-errors/lib/esm/errors/rpc_errors.cjs");const v=require("../../../web3-types/lib/esm/data_format_types.cjs");require("../../../web3-types/lib/esm/eth_types.cjs");require("../../../web3-types/lib/esm/web3_base_provider.cjs");require("../../../web3-validator/lib/esm/formats.cjs");const _=require("../../../web3-validator/lib/esm/utils.cjs");require("../../../web3-validator/lib/esm/default_validator.cjs");const p=require("../../../web3-validator/lib/esm/validation/object.cjs"),b=require("./converters.cjs"),q=require("./objects.cjs"),E=require("./string_manipulation.cjs"),a=require("./uint8array.cjs"),{parseBaseType:M}=_,N=r=>typeof r=="object"&&!p.isNullish(r)&&"number"in r&&"bytes"in r,I=(r,s,i=[])=>{let e=Object.assign({},r),o;for(const u of s){if(e.oneOf&&o){const c=i.find(function(y){return this===y[0]},o??"");c&&c[0]===o&&(e=e.oneOf[c[1]])}if(!e.properties&&!e.items)return;if(e.properties)e=e.properties[u];else if(e.items&&e.items.properties){const c=e.items.properties;if(!c)return;e=c[u]}else e.items&&p.isObject(e.items)?e=e.items:e.items&&Array.isArray(e.items)&&(e=e.items[parseInt(u,10)]);e&&u&&(o=u)}return e},m=(r,s,i)=>{try{const{baseType:e,baseTypeSize:o}=M(s);if(e==="int"||e==="uint")switch(i.number){case v.FMT_NUMBER.NUMBER:return Number(b.toBigInt(r));case v.FMT_NUMBER.HEX:return b.numberToHex(b.toBigInt(r));case v.FMT_NUMBER.STR:return b.toBigInt(r).toString();case v.FMT_NUMBER.BIGINT:return b.toBigInt(r);default:throw new g.FormatterError(`Invalid format: ${String(i.number)}`)}if(e==="bytes"){let u;switch(o?typeof r=="string"?u=E.padLeft(r,o*2):a.isUint8Array(r)&&(u=a.uint8ArrayConcat(new Uint8Array(o-r.length),r)):u=r,i.bytes){case v.FMT_BYTES.HEX:return b.bytesToHex(b.bytesToUint8Array(u));case v.FMT_BYTES.UINT8ARRAY:return b.bytesToUint8Array(u);default:throw new g.FormatterError(`Invalid format: ${String(i.bytes)}`)}}}catch{return r}return r},A=(r,s,i,e,o=[])=>{var u,c;if(!p.isObject(r)&&!Array.isArray(r))return m(r,s==null?void 0:s.format,e);const y=r;for(const[d,l]of Object.entries(y)){i.push(d);const f=I(s,i,o);if(p.isNullish(f)){delete y[d],i.pop();continue}if(p.isObject(l)){A(l,s,i,e),i.pop();continue}if(Array.isArray(l)){let n=f;if((f==null?void 0:f.oneOf)!==void 0&&f.oneOf.forEach((t,B)=>{var T,j;!Array.isArray(f==null?void 0:f.items)&&(typeof l[0]=="object"&&((T=t==null?void 0:t.items)===null||T===void 0?void 0:T.type)==="object"||typeof l[0]=="string"&&((j=t==null?void 0:t.items)===null||j===void 0?void 0:j.type)!=="object")&&(n=t,o.push([d,B]))}),p.isNullish(n==null?void 0:n.items)){delete y[d],i.pop();continue}if(p.isObject(n.items)&&!p.isNullish(n.items.format)){for(let t=0;t<l.length;t+=1)y[d][t]=m(l[t],(u=n==null?void 0:n.items)===null||u===void 0?void 0:u.format,e);i.pop();continue}if(!Array.isArray(n==null?void 0:n.items)&&((c=n==null?void 0:n.items)===null||c===void 0?void 0:c.type)==="object"){for(const t of l)A(t,s,i,e,o);i.pop();continue}if(Array.isArray(n==null?void 0:n.items)){for(let t=0;t<l.length;t+=1)y[d][t]=m(l[t],n.items[t].format,e);i.pop();continue}}y[d]=m(l,f.format,e),i.pop()}return y},U=(r,s,i)=>{let e;p.isObject(s)?e=q.mergeDeep({},s):Array.isArray(s)?e=[...s]:e=s;const o=p.isObject(r)?r:_.ethAbiToJsonSchema(r);if(!o.properties&&!o.items&&!o.format)throw new g.FormatterError("Invalid json schema for formatting");return A(e,o,[],i)};exports.convert=A;exports.convertScalarValue=m;exports.format=U;exports.isDataFormat=N;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const g=require("../../../web3-errors/lib/esm/errors/generic_errors.cjs");require("../../../web3-errors/lib/esm/errors/rpc_errors.cjs");const b=require("../../../web3-types/lib/esm/data_format_types.cjs");require("../../../web3-types/lib/esm/eth_types.cjs");require("../../../web3-types/lib/esm/web3_base_provider.cjs");require("../../../web3-validator/lib/esm/formats.cjs");const E=require("../../../web3-validator/lib/esm/utils.cjs");require("../../../web3-validator/lib/esm/default_validator.cjs");const f=require("../../../web3-validator/lib/esm/validation/object.cjs"),p=require("./converters.cjs"),q=require("./objects.cjs"),M=require("./string_manipulation.cjs"),_=require("./uint8array.cjs"),{parseBaseType:N}=E,U=e=>typeof e=="object"&&!f.isNullish(e)&&"number"in e&&"bytes"in e,I=(e,i,s=[])=>{let r=Object.assign({},e),t;for(const n of i){if(r.oneOf&&t){const u=s.find(function(c){return this===c[0]},t??"");u&&u[0]===t&&(r=r.oneOf[u[1]])}if(!r.properties&&!r.items)return;if(r.properties)r=r.properties[n];else if(r.items&&r.items.properties){const u=r.items.properties;if(!u)return;r=u[n]}else r.items&&f.isObject(r.items)?r=r.items:r.items&&Array.isArray(r.items)&&(r=r.items[parseInt(n,10)]);r&&n&&(t=n)}return r},v=(e,i,s)=>{try{const{baseType:r,baseTypeSize:t}=N(i);if(r==="int"||r==="uint")switch(s.number){case b.FMT_NUMBER.NUMBER:return Number(p.toBigInt(e));case b.FMT_NUMBER.HEX:return p.numberToHex(p.toBigInt(e));case b.FMT_NUMBER.STR:return p.toBigInt(e).toString();case b.FMT_NUMBER.BIGINT:return p.toBigInt(e);default:throw new g.FormatterError(`Invalid format: ${String(s.number)}`)}if(r==="bytes"){let n;switch(t?typeof e=="string"?n=M.padLeft(e,t*2):_.isUint8Array(e)&&(n=_.uint8ArrayConcat(new Uint8Array(t-e.length),e)):n=e,s.bytes){case b.FMT_BYTES.HEX:return p.bytesToHex(p.bytesToUint8Array(n));case b.FMT_BYTES.UINT8ARRAY:return p.bytesToUint8Array(n);default:throw new g.FormatterError(`Invalid format: ${String(s.bytes)}`)}}}catch{return e}return e},m=({value:e,schemaProp:i,schema:s,object:r,key:t,dataPath:n,format:u,oneOfPath:c=[]})=>{var y,d;if(Array.isArray(e)){let l=i;if((i==null?void 0:i.oneOf)!==void 0&&i.oneOf.forEach((o,B)=>{var T,j;!Array.isArray(i==null?void 0:i.items)&&(typeof e[0]=="object"&&((T=o==null?void 0:o.items)===null||T===void 0?void 0:T.type)==="object"||typeof e[0]=="string"&&((j=o==null?void 0:o.items)===null||j===void 0?void 0:j.type)!=="object")&&(l=o,c.push([t,B]))}),f.isNullish(l==null?void 0:l.items))return delete r[t],n.pop(),!0;if(f.isObject(l.items)&&!f.isNullish(l.items.format)){for(let o=0;o<e.length;o+=1)r[t][o]=v(e[o],(y=l==null?void 0:l.items)===null||y===void 0?void 0:y.format,u);return n.pop(),!0}if(!Array.isArray(l==null?void 0:l.items)&&((d=l==null?void 0:l.items)===null||d===void 0?void 0:d.type)==="object"){for(const o of e)A(o,s,n,u,c);return n.pop(),!0}if(Array.isArray(l==null?void 0:l.items)){for(let o=0;o<e.length;o+=1)r[t][o]=v(e[o],l.items[o].format,u);return n.pop(),!0}}return!1},A=(e,i,s,r,t=[])=>{var n;if(!f.isObject(e)&&!Array.isArray(e))return v(e,i==null?void 0:i.format,r);const u=e;if(Array.isArray(u)&&(i==null?void 0:i.type)==="array"&&((n=i==null?void 0:i.items)===null||n===void 0?void 0:n.type)==="object")m({value:u,schemaProp:i,schema:i,object:u,key:"",dataPath:s,format:r,oneOfPath:t});else for(const[c,y]of Object.entries(u)){s.push(c);const d=I(i,s,t);if(f.isNullish(d)){delete u[c],s.pop();continue}if(f.isObject(y)){A(y,i,s,r),s.pop();continue}m({value:y,schemaProp:d,schema:i,object:u,key:c,dataPath:s,format:r,oneOfPath:t})||(u[c]=v(y,d.format,r),s.pop())}return u},R=(e,i,s=b.DEFAULT_RETURN_FORMAT)=>{let r;f.isObject(i)?r=q.mergeDeep({},i):Array.isArray(i)?r=[...i]:r=i;const t=f.isObject(e)?e:E.ethAbiToJsonSchema(e);if(!t.properties&&!t.items&&!t.format)throw new g.FormatterError("Invalid json schema for formatting");return A(r,t,[],s)};exports.convert=A;exports.convertScalarValue=v;exports.format=R;exports.isDataFormat=U;
@@ -1,134 +1,153 @@
1
- import { FormatterError as j } from "../../../web3-errors/lib/esm/errors/generic_errors.js";
1
+ import { FormatterError as g } from "../../../web3-errors/lib/esm/errors/generic_errors.js";
2
2
  import "../../../web3-errors/lib/esm/errors/rpc_errors.js";
3
- import { FMT_NUMBER as d, FMT_BYTES as I } from "../../../web3-types/lib/esm/data_format_types.js";
3
+ import { FMT_NUMBER as m, FMT_BYTES as _, DEFAULT_RETURN_FORMAT as R } from "../../../web3-types/lib/esm/data_format_types.js";
4
4
  import "../../../web3-types/lib/esm/eth_types.js";
5
5
  import "../../../web3-types/lib/esm/web3_base_provider.js";
6
6
  import "../../../web3-validator/lib/esm/formats.js";
7
- import * as _ from "../../../web3-validator/lib/esm/utils.js";
8
- import { ethAbiToJsonSchema as N } from "../../../web3-validator/lib/esm/utils.js";
7
+ import * as U from "../../../web3-validator/lib/esm/utils.js";
8
+ import { ethAbiToJsonSchema as B } from "../../../web3-validator/lib/esm/utils.js";
9
9
  import "../../../web3-validator/lib/esm/default_validator.js";
10
- import { isNullish as A, isObject as y } from "../../../web3-validator/lib/esm/validation/object.js";
11
- import { toBigInt as v, numberToHex as U, bytesToUint8Array as B, bytesToHex as R } from "./converters.js";
12
- import { mergeDeep as D } from "./objects.js";
10
+ import { isNullish as A, isObject as d } from "../../../web3-validator/lib/esm/validation/object.js";
11
+ import { toBigInt as v, numberToHex as N, bytesToUint8Array as w, bytesToHex as D } from "./converters.js";
12
+ import { mergeDeep as M } from "./objects.js";
13
13
  import { padLeft as H } from "./string_manipulation.js";
14
- import { isUint8Array as M, uint8ArrayConcat as S } from "./uint8array.js";
15
- const { parseBaseType: x } = _, Q = (e) => typeof e == "object" && !A(e) && "number" in e && "bytes" in e, V = (e, s, r = []) => {
16
- let i = Object.assign({}, e), o;
17
- for (const f of s) {
18
- if (i.oneOf && o) {
19
- const l = r.find(function(m) {
20
- return this === m[0];
21
- }, o ?? "");
22
- l && l[0] === o && (i = i.oneOf[l[1]]);
14
+ import { isUint8Array as S, uint8ArrayConcat as x } from "./uint8array.js";
15
+ const { parseBaseType: F } = U, Z = (i) => typeof i == "object" && !A(i) && "number" in i && "bytes" in i, L = (i, t, s = []) => {
16
+ let r = Object.assign({}, i), e;
17
+ for (const o of t) {
18
+ if (r.oneOf && e) {
19
+ const f = s.find(function(p) {
20
+ return this === p[0];
21
+ }, e ?? "");
22
+ f && f[0] === e && (r = r.oneOf[f[1]]);
23
23
  }
24
- if (!i.properties && !i.items)
24
+ if (!r.properties && !r.items)
25
25
  return;
26
- if (i.properties)
27
- i = i.properties[f];
28
- else if (i.items && i.items.properties) {
29
- const l = i.items.properties;
30
- if (!l)
26
+ if (r.properties)
27
+ r = r.properties[o];
28
+ else if (r.items && r.items.properties) {
29
+ const f = r.items.properties;
30
+ if (!f)
31
31
  return;
32
- i = l[f];
32
+ r = f[o];
33
33
  } else
34
- i.items && y(i.items) ? i = i.items : i.items && Array.isArray(i.items) && (i = i.items[parseInt(f, 10)]);
35
- i && f && (o = f);
34
+ r.items && d(r.items) ? r = r.items : r.items && Array.isArray(r.items) && (r = r.items[parseInt(o, 10)]);
35
+ r && o && (e = o);
36
36
  }
37
- return i;
38
- }, b = (e, s, r) => {
37
+ return r;
38
+ }, b = (i, t, s) => {
39
39
  try {
40
- const { baseType: i, baseTypeSize: o } = x(s);
41
- if (i === "int" || i === "uint")
42
- switch (r.number) {
43
- case d.NUMBER:
44
- return Number(v(e));
45
- case d.HEX:
46
- return U(v(e));
47
- case d.STR:
48
- return v(e).toString();
49
- case d.BIGINT:
50
- return v(e);
40
+ const { baseType: r, baseTypeSize: e } = F(t);
41
+ if (r === "int" || r === "uint")
42
+ switch (s.number) {
43
+ case m.NUMBER:
44
+ return Number(v(i));
45
+ case m.HEX:
46
+ return N(v(i));
47
+ case m.STR:
48
+ return v(i).toString();
49
+ case m.BIGINT:
50
+ return v(i);
51
51
  default:
52
- throw new j(`Invalid format: ${String(r.number)}`);
52
+ throw new g(`Invalid format: ${String(s.number)}`);
53
53
  }
54
- if (i === "bytes") {
55
- let f;
56
- switch (o ? typeof e == "string" ? f = H(e, o * 2) : M(e) && (f = S(new Uint8Array(o - e.length), e)) : f = e, r.bytes) {
57
- case I.HEX:
58
- return R(B(f));
59
- case I.UINT8ARRAY:
60
- return B(f);
54
+ if (r === "bytes") {
55
+ let o;
56
+ switch (e ? typeof i == "string" ? o = H(i, e * 2) : S(i) && (o = x(new Uint8Array(e - i.length), i)) : o = i, s.bytes) {
57
+ case _.HEX:
58
+ return D(w(o));
59
+ case _.UINT8ARRAY:
60
+ return w(o);
61
61
  default:
62
- throw new j(`Invalid format: ${String(r.bytes)}`);
62
+ throw new g(`Invalid format: ${String(s.bytes)}`);
63
63
  }
64
64
  }
65
65
  } catch {
66
- return e;
66
+ return i;
67
67
  }
68
- return e;
69
- }, w = (e, s, r, i, o = []) => {
70
- var f, l;
71
- if (!y(e) && !Array.isArray(e))
72
- return b(e, s == null ? void 0 : s.format, i);
73
- const m = e;
74
- for (const [c, p] of Object.entries(m)) {
75
- r.push(c);
76
- const u = V(s, r, o);
77
- if (A(u)) {
78
- delete m[c], r.pop();
79
- continue;
68
+ return i;
69
+ }, E = ({ value: i, schemaProp: t, schema: s, object: r, key: e, dataPath: o, format: f, oneOfPath: p = [] }) => {
70
+ var u, y;
71
+ if (Array.isArray(i)) {
72
+ let l = t;
73
+ if ((t == null ? void 0 : t.oneOf) !== void 0 && t.oneOf.forEach((n, I) => {
74
+ var c, T;
75
+ !Array.isArray(t == null ? void 0 : t.items) && (typeof i[0] == "object" && ((c = n == null ? void 0 : n.items) === null || c === void 0 ? void 0 : c.type) === "object" || typeof i[0] == "string" && ((T = n == null ? void 0 : n.items) === null || T === void 0 ? void 0 : T.type) !== "object") && (l = n, p.push([e, I]));
76
+ }), A(l == null ? void 0 : l.items))
77
+ return delete r[e], o.pop(), !0;
78
+ if (d(l.items) && !A(l.items.format)) {
79
+ for (let n = 0; n < i.length; n += 1)
80
+ r[e][n] = b(
81
+ i[n],
82
+ // eslint-disable-next-line @typescript-eslint/no-unsafe-argument
83
+ (u = l == null ? void 0 : l.items) === null || u === void 0 ? void 0 : u.format,
84
+ f
85
+ );
86
+ return o.pop(), !0;
80
87
  }
81
- if (y(p)) {
82
- w(p, s, r, i), r.pop();
83
- continue;
88
+ if (!Array.isArray(l == null ? void 0 : l.items) && ((y = l == null ? void 0 : l.items) === null || y === void 0 ? void 0 : y.type) === "object") {
89
+ for (const n of i)
90
+ j(n, s, o, f, p);
91
+ return o.pop(), !0;
84
92
  }
85
- if (Array.isArray(p)) {
86
- let n = u;
87
- if ((u == null ? void 0 : u.oneOf) !== void 0 && u.oneOf.forEach((t, E) => {
88
- var T, g;
89
- !Array.isArray(u == null ? void 0 : u.items) && (typeof p[0] == "object" && ((T = t == null ? void 0 : t.items) === null || T === void 0 ? void 0 : T.type) === "object" || typeof p[0] == "string" && ((g = t == null ? void 0 : t.items) === null || g === void 0 ? void 0 : g.type) !== "object") && (n = t, o.push([c, E]));
90
- }), A(n == null ? void 0 : n.items)) {
91
- delete m[c], r.pop();
92
- continue;
93
- }
94
- if (y(n.items) && !A(n.items.format)) {
95
- for (let t = 0; t < p.length; t += 1)
96
- m[c][t] = b(
97
- p[t],
98
- // eslint-disable-next-line @typescript-eslint/no-unsafe-argument
99
- (f = n == null ? void 0 : n.items) === null || f === void 0 ? void 0 : f.format,
100
- i
101
- );
102
- r.pop();
103
- continue;
104
- }
105
- if (!Array.isArray(n == null ? void 0 : n.items) && ((l = n == null ? void 0 : n.items) === null || l === void 0 ? void 0 : l.type) === "object") {
106
- for (const t of p)
107
- w(t, s, r, i, o);
108
- r.pop();
93
+ if (Array.isArray(l == null ? void 0 : l.items)) {
94
+ for (let n = 0; n < i.length; n += 1)
95
+ r[e][n] = b(i[n], l.items[n].format, f);
96
+ return o.pop(), !0;
97
+ }
98
+ }
99
+ return !1;
100
+ }, j = (i, t, s, r, e = []) => {
101
+ var o;
102
+ if (!d(i) && !Array.isArray(i))
103
+ return b(i, t == null ? void 0 : t.format, r);
104
+ const f = i;
105
+ if (Array.isArray(f) && (t == null ? void 0 : t.type) === "array" && ((o = t == null ? void 0 : t.items) === null || o === void 0 ? void 0 : o.type) === "object")
106
+ E({
107
+ value: f,
108
+ schemaProp: t,
109
+ schema: t,
110
+ object: f,
111
+ key: "",
112
+ dataPath: s,
113
+ format: r,
114
+ oneOfPath: e
115
+ });
116
+ else
117
+ for (const [p, u] of Object.entries(f)) {
118
+ s.push(p);
119
+ const y = L(t, s, e);
120
+ if (A(y)) {
121
+ delete f[p], s.pop();
109
122
  continue;
110
123
  }
111
- if (Array.isArray(n == null ? void 0 : n.items)) {
112
- for (let t = 0; t < p.length; t += 1)
113
- m[c][t] = b(p[t], n.items[t].format, i);
114
- r.pop();
124
+ if (d(u)) {
125
+ j(u, t, s, r), s.pop();
115
126
  continue;
116
127
  }
128
+ E({
129
+ value: u,
130
+ schemaProp: y,
131
+ schema: t,
132
+ object: f,
133
+ key: p,
134
+ dataPath: s,
135
+ format: r,
136
+ oneOfPath: e
137
+ }) || (f[p] = b(u, y.format, r), s.pop());
117
138
  }
118
- m[c] = b(p, u.format, i), r.pop();
119
- }
120
- return m;
121
- }, W = (e, s, r) => {
122
- let i;
123
- y(s) ? i = D({}, s) : Array.isArray(s) ? i = [...s] : i = s;
124
- const o = y(e) ? e : N(e);
125
- if (!o.properties && !o.items && !o.format)
126
- throw new j("Invalid json schema for formatting");
127
- return w(i, o, [], r);
139
+ return f;
140
+ }, k = (i, t, s = R) => {
141
+ let r;
142
+ d(t) ? r = M({}, t) : Array.isArray(t) ? r = [...t] : r = t;
143
+ const e = d(i) ? i : B(i);
144
+ if (!e.properties && !e.items && !e.format)
145
+ throw new g("Invalid json schema for formatting");
146
+ return j(r, e, [], s);
128
147
  };
129
148
  export {
130
- w as convert,
149
+ j as convert,
131
150
  b as convertScalarValue,
132
- W as format,
133
- Q as isDataFormat
151
+ k as format,
152
+ Z as isDataFormat
134
153
  };
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const S=require("../../../web3-errors/lib/esm/errors/utils_errors.cjs");require("../../../web3-errors/lib/esm/errors/rpc_errors.cjs");const W=require("./constants.cjs"),N=require("./validation/abi.cjs"),b=require("./validation/string.cjs"),E=require("./errors.cjs"),q=["hex","number","blockNumber","blockNumberOrTag","filter","bloom"],g=e=>{let t=e.replace(/ /,""),n,r=!1,s=[];if(e.includes("[")&&(t=t.slice(0,t.indexOf("[")),s=[...e.matchAll(/(?:\[(\d*)\])/g)].map(i=>parseInt(i[1],10)).map(i=>Number.isNaN(i)?-1:i),r=s.length>0),W.VALID_ETH_BASE_TYPES.includes(t))return{baseType:t,isArray:r,baseTypeSize:n,arraySizes:s};if(t.startsWith("int"))n=parseInt(t.substring(3),10),t="int";else if(t.startsWith("uint"))n=parseInt(e.substring(4),10),t="uint";else if(t.startsWith("bytes"))n=parseInt(t.substring(5),10),t="bytes";else return{baseType:void 0,isArray:!1,baseTypeSize:void 0,arraySizes:s};return{baseType:t,isArray:r,baseTypeSize:n,arraySizes:s}},T=(e,t={})=>{if(Object.keys(t).includes("type"))throw new E.Web3ValidatorError([{keyword:"eth",message:'Either "eth" or "type" can be presented in schema',params:{eth:e},instancePath:"",schemaPath:""}]);const{baseType:r,baseTypeSize:s}=g(e);if(!r&&!q.includes(e))throw new E.Web3ValidatorError([{keyword:"eth",message:`Eth data type "${e}" is not valid`,params:{eth:e},instancePath:"",schemaPath:""}]);if(r){if(r==="tuple")throw new Error('"tuple" type is not implemented directly.');return{format:`${r}${s??""}`,required:!0}}return e?{format:e,required:!0}:{}},d=(e,t="/0")=>{const n={type:"array",items:[],maxItems:e.length,minItems:e.length};for(const[r,s]of e.entries()){let i,o,f=[];N.isAbiParameterSchema(s)?(i=s.type,o=s.name,f=s.components):typeof s=="string"?(i=s,o=`${t}/${r}`):Array.isArray(s)&&(s[0]&&typeof s[0]=="string"&&s[0].startsWith("tuple")&&!Array.isArray(s[0])&&s[1]&&Array.isArray(s[1])?(i=s[0],o=`${t}/${r}`,f=s[1]):(i="tuple",o=`${t}/${r}`,f=s));const{baseType:u,isArray:y,arraySizes:p}=g(i);let m,c=n;for(let a=p.length-1;a>0;a-=1)m={type:"array",$id:o,items:[],maxItems:p[a],minItems:p[a]},p[a]<0&&(delete m.maxItems,delete m.minItems),Array.isArray(c.items)?c.items.length===0?c.items=[m]:c.items.push(m):c.items=[c.items,m],c=m;if(u==="tuple"&&!y){const a=d(f,o);a.$id=o,c.items.push(a)}else if(u==="tuple"&&y){const a=p[0],h=Object.assign({type:"array",$id:o,items:d(f,o)},a>=0&&{minItems:a,maxItems:a});c.items.push(h)}else if(y){const a=p[0],h=Object.assign({type:"array",$id:o,items:T(i)},a>=0&&{minItems:a,maxItems:a});c.items.push(h)}else Array.isArray(c.items)?c.items.push(Object.assign({$id:o},T(i))):c.items.push(Object.assign({$id:o},T(i)));c=n}return n},_=e=>d(e),I=(e,t)=>t===1?e:I(e[0],t-1),A=(e,t,n)=>{const r=[];for(const[s,i]of e.entries()){let o,f,u=[];N.isAbiParameterSchema(i)?(o=i.type,f=i.name,u=i.components):typeof i=="string"?o=i:Array.isArray(i)&&(i[1]&&Array.isArray(i[1])?(o=i[0],u=i[1]):(o="tuple",u=i));const{baseType:y,isArray:p,arraySizes:m}=g(o),c=Array.isArray(t)?t[s]:t[f];if(y==="tuple"&&!p)r.push(A(u,c,n));else if(y==="tuple"&&p){const a=[];for(const h of c)if(m.length>1){const z=I(h,m.length-1),$=[];for(const H of z)$.push(A(u,H,n));a.push($)}else a.push(A(u,h,n));r.push(a)}else r.push(c)}return n=n??[],n.push(...r),n},B=e=>{if(e>=48&&e<=57)return e-48;if(e>=65&&e<=70)return e-55;if(e>=97&&e<=102)return e-87;throw new Error(`Invalid code point: ${e}`)},O=e=>{if(!b.isHexStrict(e))throw new Error("Invalid hex string");const[t,n]=e.startsWith("-")?[!0,e.slice(1)]:[!1,e],r=BigInt(n);return r>Number.MAX_SAFE_INTEGER?t?-r:r:r<Number.MIN_SAFE_INTEGER?r:t?-1*Number(r):Number(r)},x=e=>{if((typeof e=="number"||typeof e=="bigint")&&e<0)return`-0x${e.toString(16).slice(1)}`;if((typeof e=="number"||typeof e=="bigint")&&e>=0)return`0x${e.toString(16)}`;if(typeof e=="string"&&b.isHexStrict(e)){const[t,n]=e.startsWith("-")?[!0,e.slice(1)]:[!1,e],r=n.split(/^(-)?0(x|X)/).slice(-1)[0];return`${t?"-":""}0x${r.replace(/^0+/,"").toLowerCase()}`}if(typeof e=="string"&&!b.isHexStrict(e))return x(BigInt(e));throw new S.InvalidNumberError(e)},U=(e,t,n="0")=>{if(typeof e=="string"&&!b.isHexStrict(e))return e.padStart(t,n);const r=typeof e=="string"&&b.isHexStrict(e)?e:x(e),[s,i]=r.startsWith("-")?["-0x",r.slice(3)]:["0x",r.slice(2)];return`${s}${i.padStart(t,n)}`};function j(e){let t="0x";for(const n of e){const r=n.toString(16);t+=r.length===1?`0${r}`:r}return t}const l={zero:48,nine:57,A:65,F:70,a:97,f:102};function w(e){if(e>=l.zero&&e<=l.nine)return e-l.zero;if(e>=l.A&&e<=l.F)return e-(l.A-10);if(e>=l.a&&e<=l.f)return e-(l.a-10)}function C(e){let t=0;if(e.startsWith("0")&&(e[1]==="x"||e[1]==="X")&&(t=2),e.length%2!==0)throw new S.InvalidBytesError(`hex string has odd length: ${e}`);const n=(e.length-t)/2,r=new Uint8Array(n);for(let s=0,i=t;s<n;s+=1){const o=w(e.charCodeAt(i++)),f=w(e.charCodeAt(i++));if(o===void 0||f===void 0)throw new S.InvalidBytesError(`Invalid byte sequence ("${e[i-2]}${e[i-1]}" in "${e}").`);r[s]=o*16+f}return r}function F(e){var t;return!(e instanceof Uint8Array)&&((t=e==null?void 0:e.constructor)===null||t===void 0?void 0:t.name)==="Uint8Array"?Uint8Array.from(e):e}exports.abiSchemaToJsonSchema=d;exports.codePointToInt=B;exports.ensureIfUint8Array=F;exports.ethAbiToJsonSchema=_;exports.fetchArrayElement=I;exports.hexToNumber=O;exports.hexToUint8Array=C;exports.numberToHex=x;exports.padLeft=U;exports.parseBaseType=g;exports.transformJsonDataToAbiFormat=A;exports.uint8ArrayToHexString=j;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const S=require("../../../web3-errors/lib/esm/errors/utils_errors.cjs");require("../../../web3-errors/lib/esm/errors/rpc_errors.cjs");const W=require("./constants.cjs"),N=require("./validation/abi.cjs"),b=require("./validation/string.cjs"),E=require("./errors.cjs"),q=["hex","number","blockNumber","blockNumberOrTag","filter","bloom"],g=e=>{let t=e.replace(/ /,""),n,r=!1,s=[];if(e.includes("[")&&(t=t.slice(0,t.indexOf("[")),s=[...e.matchAll(/(?:\[(\d*)\])/g)].map(i=>parseInt(i[1],10)).map(i=>Number.isNaN(i)?-1:i),r=s.length>0),W.VALID_ETH_BASE_TYPES.includes(t))return{baseType:t,isArray:r,baseTypeSize:n,arraySizes:s};if(t.startsWith("int"))n=parseInt(t.substring(3),10),t="int";else if(t.startsWith("uint"))n=parseInt(e.substring(4),10),t="uint";else if(t.startsWith("bytes"))n=parseInt(t.substring(5),10),t="bytes";else return{baseType:void 0,isArray:!1,baseTypeSize:void 0,arraySizes:s};return{baseType:t,isArray:r,baseTypeSize:n,arraySizes:s}},T=(e,t={})=>{if(Object.keys(t).includes("type"))throw new E.Web3ValidatorError([{keyword:"eth",message:'Either "eth" or "type" can be presented in schema',params:{eth:e},instancePath:"",schemaPath:""}]);const{baseType:r,baseTypeSize:s}=g(e);if(!r&&!q.includes(e))throw new E.Web3ValidatorError([{keyword:"eth",message:`Eth data type "${e}" is not valid`,params:{eth:e},instancePath:"",schemaPath:""}]);if(r){if(r==="tuple")throw new Error('"tuple" type is not implemented directly.');return{format:`${r}${s??""}`,required:!0}}return e?{format:e,required:!0}:{}},d=(e,t="/0")=>{const n={type:"array",items:[],maxItems:e.length,minItems:e.length};for(const[r,s]of e.entries()){let i,o,f=[];N.isAbiParameterSchema(s)?(i=s.type,o=s.name||`${t}/${r}`,f=s.components):typeof s=="string"?(i=s,o=`${t}/${r}`):Array.isArray(s)&&(s[0]&&typeof s[0]=="string"&&s[0].startsWith("tuple")&&!Array.isArray(s[0])&&s[1]&&Array.isArray(s[1])?(i=s[0],o=`${t}/${r}`,f=s[1]):(i="tuple",o=`${t}/${r}`,f=s));const{baseType:u,isArray:l,arraySizes:p}=g(i);let m,c=n;for(let a=p.length-1;a>0;a-=1)m={type:"array",$id:o,items:[],maxItems:p[a],minItems:p[a]},p[a]<0&&(delete m.maxItems,delete m.minItems),Array.isArray(c.items)?c.items.length===0?c.items=[m]:c.items.push(m):c.items=[c.items,m],c=m;if(u==="tuple"&&!l){const a=d(f,o);a.$id=o,c.items.push(a)}else if(u==="tuple"&&l){const a=p[0],h=Object.assign({type:"array",$id:o,items:d(f,o)},a>=0&&{minItems:a,maxItems:a});c.items.push(h)}else if(l){const a=p[0],h=Object.assign({type:"array",$id:o,items:T(i)},a>=0&&{minItems:a,maxItems:a});c.items.push(h)}else Array.isArray(c.items)?c.items.push(Object.assign({$id:o},T(i))):c.items.push(Object.assign({$id:o},T(i)));c=n}return n},_=e=>d(e),I=(e,t)=>t===1?e:I(e[0],t-1),A=(e,t,n)=>{const r=[];for(const[s,i]of e.entries()){let o,f,u=[];N.isAbiParameterSchema(i)?(o=i.type,f=i.name,u=i.components):typeof i=="string"?o=i:Array.isArray(i)&&(i[1]&&Array.isArray(i[1])?(o=i[0],u=i[1]):(o="tuple",u=i));const{baseType:l,isArray:p,arraySizes:m}=g(o),c=Array.isArray(t)?t[s]:t[f];if(l==="tuple"&&!p)r.push(A(u,c,n));else if(l==="tuple"&&p){const a=[];for(const h of c)if(m.length>1){const z=I(h,m.length-1),$=[];for(const H of z)$.push(A(u,H,n));a.push($)}else a.push(A(u,h,n));r.push(a)}else r.push(c)}return n=n??[],n.push(...r),n},B=e=>{if(e>=48&&e<=57)return e-48;if(e>=65&&e<=70)return e-55;if(e>=97&&e<=102)return e-87;throw new Error(`Invalid code point: ${e}`)},O=e=>{if(!b.isHexStrict(e))throw new Error("Invalid hex string");const[t,n]=e.startsWith("-")?[!0,e.slice(1)]:[!1,e],r=BigInt(n);return r>Number.MAX_SAFE_INTEGER?t?-r:r:r<Number.MIN_SAFE_INTEGER?r:t?-1*Number(r):Number(r)},x=e=>{if((typeof e=="number"||typeof e=="bigint")&&e<0)return`-0x${e.toString(16).slice(1)}`;if((typeof e=="number"||typeof e=="bigint")&&e>=0)return`0x${e.toString(16)}`;if(typeof e=="string"&&b.isHexStrict(e)){const[t,n]=e.startsWith("-")?[!0,e.slice(1)]:[!1,e],r=n.split(/^(-)?0(x|X)/).slice(-1)[0];return`${t?"-":""}0x${r.replace(/^0+/,"").toLowerCase()}`}if(typeof e=="string"&&!b.isHexStrict(e))return x(BigInt(e));throw new S.InvalidNumberError(e)},U=(e,t,n="0")=>{if(typeof e=="string"&&!b.isHexStrict(e))return e.padStart(t,n);const r=typeof e=="string"&&b.isHexStrict(e)?e:x(e),[s,i]=r.startsWith("-")?["-0x",r.slice(3)]:["0x",r.slice(2)];return`${s}${i.padStart(t,n)}`};function j(e){let t="0x";for(const n of e){const r=n.toString(16);t+=r.length===1?`0${r}`:r}return t}const y={zero:48,nine:57,A:65,F:70,a:97,f:102};function w(e){if(e>=y.zero&&e<=y.nine)return e-y.zero;if(e>=y.A&&e<=y.F)return e-(y.A-10);if(e>=y.a&&e<=y.f)return e-(y.a-10)}function C(e){let t=0;if(e.startsWith("0")&&(e[1]==="x"||e[1]==="X")&&(t=2),e.length%2!==0)throw new S.InvalidBytesError(`hex string has odd length: ${e}`);const n=(e.length-t)/2,r=new Uint8Array(n);for(let s=0,i=t;s<n;s+=1){const o=w(e.charCodeAt(i++)),f=w(e.charCodeAt(i++));if(o===void 0||f===void 0)throw new S.InvalidBytesError(`Invalid byte sequence ("${e[i-2]}${e[i-1]}" in "${e}").`);r[s]=o*16+f}return r}function F(e){var t;return!(e instanceof Uint8Array)&&((t=e==null?void 0:e.constructor)===null||t===void 0?void 0:t.name)==="Uint8Array"?Uint8Array.from(e):e}exports.abiSchemaToJsonSchema=d;exports.codePointToInt=B;exports.ensureIfUint8Array=F;exports.ethAbiToJsonSchema=_;exports.fetchArrayElement=I;exports.hexToNumber=O;exports.hexToUint8Array=C;exports.numberToHex=x;exports.padLeft=U;exports.parseBaseType=g;exports.transformJsonDataToAbiFormat=A;exports.uint8ArrayToHexString=j;