@argent/x-shared 1.79.0 → 1.79.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (502) hide show
  1. package/dist/.ts-temp/tsconfig.tsbuildinfo +1 -1
  2. package/dist/_virtual/_rolldown/runtime.cjs +1 -0
  3. package/dist/_virtual/_rolldown/runtime.js +20 -0
  4. package/dist/index.cjs +1 -1
  5. package/dist/index.js +112 -488
  6. package/dist/node_modules/.pnpm/@noble_curves@1.0.0/node_modules/@noble/curves/esm/_shortw_utils.cjs +1 -1
  7. package/dist/node_modules/.pnpm/@noble_curves@1.0.0/node_modules/@noble/curves/esm/_shortw_utils.js +11 -11
  8. package/dist/node_modules/.pnpm/@noble_curves@1.0.0/node_modules/@noble/curves/esm/abstract/curve.cjs +1 -1
  9. package/dist/node_modules/.pnpm/@noble_curves@1.0.0/node_modules/@noble/curves/esm/abstract/curve.js +62 -85
  10. package/dist/node_modules/.pnpm/@noble_curves@1.0.0/node_modules/@noble/curves/esm/abstract/modular.cjs +1 -1
  11. package/dist/node_modules/.pnpm/@noble_curves@1.0.0/node_modules/@noble/curves/esm/abstract/modular.js +153 -190
  12. package/dist/node_modules/.pnpm/@noble_curves@1.0.0/node_modules/@noble/curves/esm/abstract/poseidon.cjs +1 -1
  13. package/dist/node_modules/.pnpm/@noble_curves@1.0.0/node_modules/@noble/curves/esm/abstract/poseidon.js +56 -65
  14. package/dist/node_modules/.pnpm/@noble_curves@1.0.0/node_modules/@noble/curves/esm/abstract/utils.cjs +1 -1
  15. package/dist/node_modules/.pnpm/@noble_curves@1.0.0/node_modules/@noble/curves/esm/abstract/utils.js +125 -151
  16. package/dist/node_modules/.pnpm/@noble_curves@1.0.0/node_modules/@noble/curves/esm/abstract/weierstrass.cjs +1 -1
  17. package/dist/node_modules/.pnpm/@noble_curves@1.0.0/node_modules/@noble/curves/esm/abstract/weierstrass.js +470 -575
  18. package/dist/node_modules/.pnpm/@noble_hashes@1.3.0/node_modules/@noble/hashes/esm/_assert.cjs +1 -1
  19. package/dist/node_modules/.pnpm/@noble_hashes@1.3.0/node_modules/@noble/hashes/esm/_assert.js +26 -40
  20. package/dist/node_modules/.pnpm/@noble_hashes@1.3.0/node_modules/@noble/hashes/esm/crypto.cjs +1 -1
  21. package/dist/node_modules/.pnpm/@noble_hashes@1.3.0/node_modules/@noble/hashes/esm/crypto.js +4 -4
  22. package/dist/node_modules/.pnpm/@noble_hashes@1.3.0/node_modules/@noble/hashes/esm/hmac.cjs +1 -1
  23. package/dist/node_modules/.pnpm/@noble_hashes@1.3.0/node_modules/@noble/hashes/esm/hmac.js +38 -42
  24. package/dist/node_modules/.pnpm/@noble_hashes@1.3.0/node_modules/@noble/hashes/esm/utils.cjs +1 -1
  25. package/dist/node_modules/.pnpm/@noble_hashes@1.3.0/node_modules/@noble/hashes/esm/utils.js +28 -42
  26. package/dist/node_modules/.pnpm/@noble_hashes@1.3.3/node_modules/@noble/hashes/esm/_assert.cjs +1 -1
  27. package/dist/node_modules/.pnpm/@noble_hashes@1.3.3/node_modules/@noble/hashes/esm/_assert.js +17 -26
  28. package/dist/node_modules/.pnpm/@noble_hashes@1.3.3/node_modules/@noble/hashes/esm/_sha2.cjs +1 -1
  29. package/dist/node_modules/.pnpm/@noble_hashes@1.3.3/node_modules/@noble/hashes/esm/_sha2.js +52 -59
  30. package/dist/node_modules/.pnpm/@noble_hashes@1.3.3/node_modules/@noble/hashes/esm/_u64.cjs +1 -1
  31. package/dist/node_modules/.pnpm/@noble_hashes@1.3.3/node_modules/@noble/hashes/esm/_u64.js +20 -19
  32. package/dist/node_modules/.pnpm/@noble_hashes@1.3.3/node_modules/@noble/hashes/esm/sha256.cjs +1 -1
  33. package/dist/node_modules/.pnpm/@noble_hashes@1.3.3/node_modules/@noble/hashes/esm/sha256.js +118 -113
  34. package/dist/node_modules/.pnpm/@noble_hashes@1.3.3/node_modules/@noble/hashes/esm/sha3.cjs +1 -1
  35. package/dist/node_modules/.pnpm/@noble_hashes@1.3.3/node_modules/@noble/hashes/esm/sha3.js +95 -105
  36. package/dist/node_modules/.pnpm/@noble_hashes@1.3.3/node_modules/@noble/hashes/esm/utils.cjs +1 -1
  37. package/dist/node_modules/.pnpm/@noble_hashes@1.3.3/node_modules/@noble/hashes/esm/utils.js +26 -32
  38. package/dist/node_modules/.pnpm/@noble_hashes@2.0.0/node_modules/@noble/hashes/_md.cjs +1 -1
  39. package/dist/node_modules/.pnpm/@noble_hashes@2.0.0/node_modules/@noble/hashes/_md.js +71 -82
  40. package/dist/node_modules/.pnpm/@noble_hashes@2.0.0/node_modules/@noble/hashes/_u64.cjs +1 -1
  41. package/dist/node_modules/.pnpm/@noble_hashes@2.0.0/node_modules/@noble/hashes/_u64.js +20 -20
  42. package/dist/node_modules/.pnpm/@noble_hashes@2.0.0/node_modules/@noble/hashes/sha2.cjs +1 -1
  43. package/dist/node_modules/.pnpm/@noble_hashes@2.0.0/node_modules/@noble/hashes/sha2.js +125 -124
  44. package/dist/node_modules/.pnpm/@noble_hashes@2.0.0/node_modules/@noble/hashes/sha3.cjs +1 -1
  45. package/dist/node_modules/.pnpm/@noble_hashes@2.0.0/node_modules/@noble/hashes/sha3.js +102 -116
  46. package/dist/node_modules/.pnpm/@noble_hashes@2.0.0/node_modules/@noble/hashes/utils.cjs +1 -1
  47. package/dist/node_modules/.pnpm/@noble_hashes@2.0.0/node_modules/@noble/hashes/utils.js +62 -76
  48. package/dist/node_modules/.pnpm/bignumber.js@9.1.2/node_modules/bignumber.js/bignumber.cjs +1 -1
  49. package/dist/node_modules/.pnpm/bignumber.js@9.1.2/node_modules/bignumber.js/bignumber.js +519 -614
  50. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_Hash.cjs +1 -1
  51. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_Hash.js +15 -19
  52. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_ListCache.cjs +1 -1
  53. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_ListCache.js +15 -19
  54. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_Map.cjs +1 -1
  55. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_Map.js +6 -6
  56. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_MapCache.cjs +1 -1
  57. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_MapCache.js +15 -19
  58. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_Set.cjs +1 -1
  59. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_Set.js +5 -5
  60. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_SetCache.cjs +1 -1
  61. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_SetCache.js +10 -12
  62. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_Symbol.cjs +1 -1
  63. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_Symbol.js +5 -5
  64. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_arrayIncludes.cjs +1 -1
  65. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_arrayIncludes.js +6 -7
  66. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_arrayIncludesWith.cjs +1 -1
  67. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_arrayIncludesWith.js +6 -8
  68. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_assocIndexOf.cjs +1 -1
  69. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_assocIndexOf.js +7 -9
  70. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_baseFindIndex.cjs +1 -1
  71. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_baseFindIndex.js +6 -8
  72. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_baseGetTag.cjs +1 -1
  73. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_baseGetTag.js +9 -9
  74. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_baseIndexOf.cjs +1 -1
  75. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_baseIndexOf.js +7 -7
  76. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_baseIsNaN.cjs +1 -1
  77. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_baseIsNaN.js +5 -5
  78. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_baseIsNative.cjs +1 -1
  79. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_baseIsNative.js +10 -15
  80. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_baseUniq.cjs +1 -1
  81. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_baseUniq.js +26 -32
  82. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_cacheHas.cjs +1 -1
  83. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_cacheHas.js +5 -5
  84. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_coreJsData.cjs +1 -1
  85. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_coreJsData.js +5 -5
  86. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_createSet.cjs +1 -1
  87. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_createSet.js +7 -7
  88. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_freeGlobal.cjs +1 -1
  89. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_freeGlobal.js +4 -4
  90. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_getMapData.cjs +1 -1
  91. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_getMapData.js +6 -6
  92. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_getNative.cjs +1 -1
  93. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_getNative.js +8 -8
  94. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_getRawTag.cjs +1 -1
  95. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_getRawTag.js +12 -13
  96. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_getValue.cjs +1 -1
  97. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_getValue.js +5 -5
  98. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_hashClear.cjs +1 -1
  99. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_hashClear.js +6 -6
  100. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_hashDelete.cjs +1 -1
  101. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_hashDelete.js +6 -6
  102. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_hashGet.cjs +1 -1
  103. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_hashGet.js +11 -11
  104. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_hashHas.cjs +1 -1
  105. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_hashHas.js +8 -8
  106. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_hashSet.cjs +1 -1
  107. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_hashSet.js +7 -7
  108. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_isKeyable.cjs +1 -1
  109. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_isKeyable.js +6 -6
  110. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_isMasked.cjs +1 -1
  111. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_isMasked.js +9 -9
  112. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_listCacheClear.cjs +1 -1
  113. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_listCacheClear.js +5 -5
  114. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_listCacheDelete.cjs +1 -1
  115. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_listCacheDelete.js +8 -11
  116. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_listCacheGet.cjs +1 -1
  117. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_listCacheGet.js +7 -7
  118. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_listCacheHas.cjs +1 -1
  119. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_listCacheHas.js +6 -6
  120. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_listCacheSet.cjs +1 -1
  121. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_listCacheSet.js +6 -6
  122. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_mapCacheClear.cjs +1 -1
  123. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_mapCacheClear.js +11 -11
  124. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_mapCacheDelete.cjs +1 -1
  125. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_mapCacheDelete.js +7 -7
  126. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_mapCacheGet.cjs +1 -1
  127. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_mapCacheGet.js +6 -6
  128. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_mapCacheHas.cjs +1 -1
  129. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_mapCacheHas.js +6 -6
  130. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_mapCacheSet.cjs +1 -1
  131. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_mapCacheSet.js +7 -7
  132. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_nativeCreate.cjs +1 -1
  133. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_nativeCreate.js +4 -4
  134. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_objectToString.cjs +1 -1
  135. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_objectToString.js +6 -6
  136. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_root.cjs +1 -1
  137. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_root.js +4 -4
  138. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_setCacheAdd.cjs +1 -1
  139. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_setCacheAdd.js +6 -6
  140. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_setCacheHas.cjs +1 -1
  141. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_setCacheHas.js +5 -5
  142. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_setToArray.cjs +1 -1
  143. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_setToArray.js +8 -8
  144. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_strictIndexOf.cjs +1 -1
  145. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_strictIndexOf.js +6 -8
  146. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_toSource.cjs +1 -1
  147. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_toSource.js +14 -16
  148. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/eq.cjs +1 -1
  149. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/eq.js +5 -5
  150. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/isFunction.cjs +1 -1
  151. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/isFunction.js +10 -11
  152. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/isObject.cjs +1 -1
  153. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/isObject.js +6 -6
  154. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/noop.cjs +1 -1
  155. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/noop.js +4 -5
  156. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/uniqWith.cjs +1 -1
  157. package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/uniqWith.js +6 -6
  158. package/dist/node_modules/.pnpm/micro-starknet@0.2.3/node_modules/micro-starknet/lib/esm/index.cjs +1 -1
  159. package/dist/node_modules/.pnpm/micro-starknet@0.2.3/node_modules/micro-starknet/lib/esm/index.js +121 -118
  160. package/dist/node_modules/.pnpm/numeral@2.0.6/node_modules/numeral/numeral.cjs +1 -1
  161. package/dist/node_modules/.pnpm/numeral@2.0.6/node_modules/numeral/numeral.js +377 -417
  162. package/dist/node_modules/.pnpm/semver@6.3.1/node_modules/semver/semver.cjs +1 -1
  163. package/dist/node_modules/.pnpm/semver@6.3.1/node_modules/semver/semver.js +546 -635
  164. package/dist/paymaster.cjs +1 -1
  165. package/dist/paymaster.js +2 -11
  166. package/dist/simulation.cjs +1 -1
  167. package/dist/simulation.js +22 -90
  168. package/dist/src/account/account.model.cjs +1 -1
  169. package/dist/src/account/account.model.js +58 -52
  170. package/dist/src/account/accountv4.cjs +1 -1
  171. package/dist/src/account/accountv4.js +9 -11
  172. package/dist/src/account/preferences.model.cjs +1 -1
  173. package/dist/src/account/preferences.model.js +12 -10
  174. package/dist/src/accountNameGenerator/colors.cjs +1 -1
  175. package/dist/src/accountNameGenerator/colors.js +24 -24
  176. package/dist/src/accountNameGenerator/index.cjs +1 -1
  177. package/dist/src/accountNameGenerator/index.js +23 -23
  178. package/dist/src/accountNameGenerator/x-names.json.cjs +1 -1
  179. package/dist/src/accountNameGenerator/x-names.json.js +1922 -7
  180. package/dist/src/assets/tokens.json.cjs +1 -1
  181. package/dist/src/assets/tokens.json.js +180 -180
  182. package/dist/src/backend/schema.cjs +1 -1
  183. package/dist/src/backend/schema.js +9 -12
  184. package/dist/src/backend/sessionKeys/schema.cjs +1 -1
  185. package/dist/src/backend/sessionKeys/schema.js +27 -30
  186. package/dist/src/bigdecimal/constants.cjs +1 -1
  187. package/dist/src/bigdecimal/constants.js +6 -3
  188. package/dist/src/bigdecimal/createUnitsSchema.cjs +1 -1
  189. package/dist/src/bigdecimal/createUnitsSchema.js +7 -7
  190. package/dist/src/bigdecimal/formatUnits.cjs +1 -1
  191. package/dist/src/bigdecimal/formatUnits.js +9 -10
  192. package/dist/src/bigdecimal/index.cjs +1 -1
  193. package/dist/src/bigdecimal/index.js +45 -41
  194. package/dist/src/bigdecimal/lib.cjs +1 -1
  195. package/dist/src/bigdecimal/lib.js +105 -117
  196. package/dist/src/bigdecimal/parseUnits.cjs +1 -1
  197. package/dist/src/bigdecimal/parseUnits.js +18 -21
  198. package/dist/src/bigdecimal/utils.cjs +1 -1
  199. package/dist/src/bigdecimal/utils.js +33 -30
  200. package/dist/src/cache/CacheService.cjs +1 -1
  201. package/dist/src/cache/CacheService.js +32 -36
  202. package/dist/src/chains/starknet/address.cjs +1 -1
  203. package/dist/src/chains/starknet/address.js +73 -117
  204. package/dist/src/chains/starknet/addressDomain.cjs +1 -1
  205. package/dist/src/chains/starknet/addressDomain.js +14 -29
  206. package/dist/src/chains/starknet/addressInput.cjs +1 -1
  207. package/dist/src/chains/starknet/addressInput.js +6 -7
  208. package/dist/src/chains/starknet/argentName.cjs +1 -1
  209. package/dist/src/chains/starknet/argentName.js +10 -14
  210. package/dist/src/chains/starknet/cairoVersionSchema.cjs +1 -1
  211. package/dist/src/chains/starknet/cairoVersionSchema.js +5 -5
  212. package/dist/src/chains/starknet/constants.cjs +1 -1
  213. package/dist/src/chains/starknet/constants.js +4 -10
  214. package/dist/src/chains/starknet/getAddressFromArgentName.cjs +1 -1
  215. package/dist/src/chains/starknet/getAddressFromArgentName.js +38 -46
  216. package/dist/src/chains/starknet/getAddressFromStarkName.cjs +1 -1
  217. package/dist/src/chains/starknet/getAddressFromStarkName.js +59 -66
  218. package/dist/src/chains/starknet/network.cjs +1 -1
  219. package/dist/src/chains/starknet/network.js +20 -26
  220. package/dist/src/chains/starknet/services/address/StarknetAddressService.cjs +1 -1
  221. package/dist/src/chains/starknet/services/address/StarknetAddressService.js +31 -36
  222. package/dist/src/chains/starknet/services/deploymentData/constants.cjs +1 -1
  223. package/dist/src/chains/starknet/services/deploymentData/constants.js +14 -21
  224. package/dist/src/chains/starknet/services/deploymentData/deploymentData.schema.cjs +1 -1
  225. package/dist/src/chains/starknet/services/deploymentData/deploymentData.schema.js +15 -17
  226. package/dist/src/chains/starknet/services/deploymentData/findImplementationForAccount.cjs +1 -1
  227. package/dist/src/chains/starknet/services/deploymentData/findImplementationForAccount.js +61 -65
  228. package/dist/src/chains/starknet/services/deploymentData/getAccountClassHash.cjs +1 -1
  229. package/dist/src/chains/starknet/services/deploymentData/getAccountClassHash.js +46 -65
  230. package/dist/src/chains/starknet/starknetId.cjs +1 -1
  231. package/dist/src/chains/starknet/starknetId.js +10 -14
  232. package/dist/src/currencyFetchService/CurrencyFetchService.cjs +1 -1
  233. package/dist/src/currencyFetchService/CurrencyFetchService.js +13 -18
  234. package/dist/src/currencyFetchService/types.ts.cjs +1 -1
  235. package/dist/src/currencyFetchService/types.ts.js +9 -12
  236. package/dist/src/errors/account.cjs +1 -1
  237. package/dist/src/errors/account.js +12 -13
  238. package/dist/src/errors/address.cjs +1 -1
  239. package/dist/src/errors/address.js +11 -12
  240. package/dist/src/errors/baseErrors.cjs +1 -1
  241. package/dist/src/errors/baseErrors.js +14 -14
  242. package/dist/src/errors/call.cjs +1 -1
  243. package/dist/src/errors/call.js +12 -13
  244. package/dist/src/errors/network.cjs +1 -1
  245. package/dist/src/errors/network.js +11 -12
  246. package/dist/src/errors/review.cjs +1 -1
  247. package/dist/src/errors/review.js +11 -12
  248. package/dist/src/errors/swap.cjs +1 -1
  249. package/dist/src/errors/swap.js +12 -13
  250. package/dist/src/features/paymaster/PaymasterService.cjs +1 -1
  251. package/dist/src/features/paymaster/PaymasterService.js +73 -87
  252. package/dist/src/features/paymaster/types.cjs +1 -1
  253. package/dist/src/features/paymaster/types.js +41 -51
  254. package/dist/src/features/simulation/activity/normalize.cjs +1 -1
  255. package/dist/src/features/simulation/activity/normalize.js +36 -38
  256. package/dist/src/features/simulation/activity/schema.cjs +1 -1
  257. package/dist/src/features/simulation/activity/schema.js +224 -250
  258. package/dist/src/features/simulation/activity/utils/createNativeActivity.cjs +1 -1
  259. package/dist/src/features/simulation/activity/utils/createNativeActivity.js +23 -27
  260. package/dist/src/features/simulation/activity/utils/getAnyActivityTitle.cjs +1 -1
  261. package/dist/src/features/simulation/activity/utils/getAnyActivityTitle.js +14 -21
  262. package/dist/src/features/simulation/activity/utils/getOverallLastModified.cjs +1 -1
  263. package/dist/src/features/simulation/activity/utils/getOverallLastModified.js +5 -5
  264. package/dist/src/features/simulation/activity/utils/hasDelegationActivity.cjs +1 -1
  265. package/dist/src/features/simulation/activity/utils/hasDelegationActivity.js +4 -4
  266. package/dist/src/features/simulation/activity/utils/isAddMultisigSignersActivity.cjs +1 -1
  267. package/dist/src/features/simulation/activity/utils/isAddMultisigSignersActivity.js +15 -19
  268. package/dist/src/features/simulation/activity/utils/isChangeMultisigThresholdActivity.cjs +1 -1
  269. package/dist/src/features/simulation/activity/utils/isChangeMultisigThresholdActivity.js +15 -19
  270. package/dist/src/features/simulation/activity/utils/isMulticallWithDeploymentActivity.cjs +1 -1
  271. package/dist/src/features/simulation/activity/utils/isMulticallWithDeploymentActivity.js +5 -5
  272. package/dist/src/features/simulation/activity/utils/isRejectOnChainActivity.cjs +1 -1
  273. package/dist/src/features/simulation/activity/utils/isRejectOnChainActivity.js +19 -21
  274. package/dist/src/features/simulation/activity/utils/isRemoveMultisigSignersActivity.cjs +1 -1
  275. package/dist/src/features/simulation/activity/utils/isRemoveMultisigSignersActivity.js +15 -19
  276. package/dist/src/features/simulation/activity/utils/isSwapActivity.cjs +1 -1
  277. package/dist/src/features/simulation/activity/utils/isSwapActivity.js +17 -18
  278. package/dist/src/features/simulation/activity/utils/isUpgradeActivity.cjs +1 -1
  279. package/dist/src/features/simulation/activity/utils/isUpgradeActivity.js +15 -19
  280. package/dist/src/features/simulation/activity/utils/parseAccountActivities.cjs +1 -1
  281. package/dist/src/features/simulation/activity/utils/parseAccountActivities.js +12 -12
  282. package/dist/src/features/simulation/activity/utils/parseFinanceActivities.cjs +1 -1
  283. package/dist/src/features/simulation/activity/utils/parseFinanceActivities.js +32 -32
  284. package/dist/src/features/simulation/fees/schema.cjs +1 -1
  285. package/dist/src/features/simulation/fees/schema.js +33 -47
  286. package/dist/src/features/simulation/transactionReview/getErrorMessageAndLabelFromSimulation.cjs +1 -1
  287. package/dist/src/features/simulation/transactionReview/getErrorMessageAndLabelFromSimulation.js +15 -17
  288. package/dist/src/features/simulation/transactionReview/getMessageFromSimulationError.cjs +1 -1
  289. package/dist/src/features/simulation/transactionReview/getMessageFromSimulationError.js +5 -5
  290. package/dist/src/features/simulation/transactionReview/schema.cjs +1 -1
  291. package/dist/src/features/simulation/transactionReview/schema.js +221 -242
  292. package/dist/src/features/simulation/warning/helper.cjs +1 -1
  293. package/dist/src/features/simulation/warning/helper.js +12 -11
  294. package/dist/src/features/simulation/warning/schema.cjs +1 -1
  295. package/dist/src/features/simulation/warning/schema.js +10 -11
  296. package/dist/src/features/swap/models/order.model.cjs +1 -1
  297. package/dist/src/features/swap/models/order.model.js +16 -19
  298. package/dist/src/features/swap/models/quote.model.cjs +1 -1
  299. package/dist/src/features/swap/models/quote.model.js +31 -35
  300. package/dist/src/features/swap/models/trade.model.cjs +1 -1
  301. package/dist/src/features/swap/models/trade.model.js +25 -27
  302. package/dist/src/features/swap/services/SwapSharedService.cjs +1 -1
  303. package/dist/src/features/swap/services/SwapSharedService.js +71 -75
  304. package/dist/src/features/swap/services/SwapTransactionService.cjs +1 -1
  305. package/dist/src/features/swap/services/SwapTransactionService.js +57 -63
  306. package/dist/src/features/swap/utils/slippage.cjs +1 -1
  307. package/dist/src/features/swap/utils/slippage.js +18 -25
  308. package/dist/src/features/swap/utils/totalFee.cjs +1 -1
  309. package/dist/src/features/swap/utils/totalFee.js +12 -12
  310. package/dist/src/http/DateService.cjs +1 -1
  311. package/dist/src/http/DateService.js +15 -18
  312. package/dist/src/http/HttpError.cjs +1 -1
  313. package/dist/src/http/HttpError.js +7 -7
  314. package/dist/src/http/HttpService.cjs +1 -1
  315. package/dist/src/http/HttpService.js +117 -134
  316. package/dist/src/http/IHttpService.cjs +1 -1
  317. package/dist/src/http/IHttpService.js +6 -6
  318. package/dist/src/http/SWRService.cjs +1 -1
  319. package/dist/src/http/SWRService.js +50 -57
  320. package/dist/src/http/fetcher.cjs +1 -1
  321. package/dist/src/http/fetcher.js +29 -35
  322. package/dist/src/http/time.cjs +1 -1
  323. package/dist/src/http/time.js +15 -18
  324. package/dist/src/knownDapps/KnownDappsBackendService.cjs +1 -1
  325. package/dist/src/knownDapps/KnownDappsBackendService.js +13 -14
  326. package/dist/src/knownDapps/schema.cjs +1 -1
  327. package/dist/src/knownDapps/schema.js +41 -44
  328. package/dist/src/knownDapps/utils/getDapplandUrl.cjs +1 -1
  329. package/dist/src/knownDapps/utils/getDapplandUrl.js +7 -8
  330. package/dist/src/nameResolution/ResolveNameService.cjs +1 -1
  331. package/dist/src/nameResolution/ResolveNameService.js +34 -41
  332. package/dist/src/nameResolution/schema.cjs +1 -1
  333. package/dist/src/nameResolution/schema.js +20 -25
  334. package/dist/src/nfts/BackendNftService.cjs +1 -1
  335. package/dist/src/nfts/BackendNftService.js +103 -116
  336. package/dist/src/nfts/BackendPaginationError.cjs +1 -1
  337. package/dist/src/nfts/BackendPaginationError.js +11 -12
  338. package/dist/src/nfts/utils.cjs +1 -1
  339. package/dist/src/nfts/utils.js +11 -14
  340. package/dist/src/onchainRecovery/OnchainRecoveryService.cjs +1 -1
  341. package/dist/src/onchainRecovery/OnchainRecoveryService.js +38 -68
  342. package/dist/src/onchainRecovery/schema.cjs +1 -1
  343. package/dist/src/onchainRecovery/schema.js +35 -49
  344. package/dist/src/platform/isBraveBrowser.cjs +1 -1
  345. package/dist/src/platform/isBraveBrowser.js +8 -10
  346. package/dist/src/platform/isBrowser.cjs +1 -1
  347. package/dist/src/platform/isBrowser.js +17 -22
  348. package/dist/src/signer/mergeOwnerGuardianSignatures.cjs +1 -1
  349. package/dist/src/signer/mergeOwnerGuardianSignatures.js +28 -30
  350. package/dist/src/signer/multisigner.cjs +1 -1
  351. package/dist/src/signer/multisigner.js +16 -17
  352. package/dist/src/signer/seedphrase.cjs +1 -1
  353. package/dist/src/signer/seedphrase.js +7 -7
  354. package/dist/src/staking/schema.cjs +1 -1
  355. package/dist/src/staking/schema.js +146 -162
  356. package/dist/src/storage/base.cjs +1 -1
  357. package/dist/src/storage/base.js +33 -34
  358. package/dist/src/storage/utils.cjs +1 -1
  359. package/dist/src/storage/utils.js +19 -28
  360. package/dist/src/tokens/balances.cjs +1 -1
  361. package/dist/src/tokens/balances.js +34 -38
  362. package/dist/src/tokens/constants.cjs +1 -1
  363. package/dist/src/tokens/constants.js +4 -4
  364. package/dist/src/tokens/convertCurrencyValueToTokenAmount.cjs +1 -1
  365. package/dist/src/tokens/convertCurrencyValueToTokenAmount.js +8 -9
  366. package/dist/src/tokens/convertTokenAmountToCurrencyValue.cjs +1 -1
  367. package/dist/src/tokens/convertTokenAmountToCurrencyValue.js +14 -15
  368. package/dist/src/tokens/convertTokenUnitAmountWithDecimals.cjs +1 -1
  369. package/dist/src/tokens/convertTokenUnitAmountWithDecimals.js +8 -9
  370. package/dist/src/tokens/ensureDecimals.cjs +1 -1
  371. package/dist/src/tokens/ensureDecimals.js +4 -4
  372. package/dist/src/tokens/getCurrencySymbol.cjs +1 -1
  373. package/dist/src/tokens/getCurrencySymbol.js +14 -14
  374. package/dist/src/tokens/isUnlimitedAmount.cjs +1 -1
  375. package/dist/src/tokens/isUnlimitedAmount.js +5 -5
  376. package/dist/src/tokens/prettifyCurrencyValue.cjs +1 -1
  377. package/dist/src/tokens/prettifyCurrencyValue.js +13 -14
  378. package/dist/src/tokens/prettifyTokenAmount.cjs +1 -1
  379. package/dist/src/tokens/prettifyTokenAmount.js +22 -22
  380. package/dist/src/tokens/service/implementation.cjs +1 -1
  381. package/dist/src/tokens/service/implementation.js +28 -40
  382. package/dist/src/tokens/service/tokenError.cjs +1 -1
  383. package/dist/src/tokens/service/tokenError.js +11 -12
  384. package/dist/src/tokens/service/types/backend.model.cjs +1 -1
  385. package/dist/src/tokens/service/types/backend.model.js +128 -163
  386. package/dist/src/tokens/service/types/defiPosition.model.cjs +1 -1
  387. package/dist/src/tokens/service/types/defiPosition.model.js +83 -99
  388. package/dist/src/tokens/service/types/defiPositionType.model.cjs +1 -1
  389. package/dist/src/tokens/service/types/defiPositionType.model.js +9 -9
  390. package/dist/src/tokens/service/types/unclaimedRewards.model.cjs +1 -1
  391. package/dist/src/tokens/service/types/unclaimedRewards.model.js +15 -16
  392. package/dist/src/tokens/service/types/webToken.model.cjs +1 -1
  393. package/dist/src/tokens/service/types/webToken.model.js +28 -51
  394. package/dist/src/tokens/utils.cjs +1 -1
  395. package/dist/src/tokens/utils.js +5 -9
  396. package/dist/src/transactions/amount.cjs +1 -1
  397. package/dist/src/transactions/amount.js +17 -24
  398. package/dist/src/transactions/buildTransactions.cjs +1 -1
  399. package/dist/src/transactions/buildTransactions.js +30 -33
  400. package/dist/src/transactions/errors.cjs +1 -1
  401. package/dist/src/transactions/errors.js +11 -18
  402. package/dist/src/transactions/estimate/adjustment.cjs +1 -1
  403. package/dist/src/transactions/estimate/adjustment.js +6 -6
  404. package/dist/src/transactions/estimate/argentMaxFee.cjs +1 -1
  405. package/dist/src/transactions/estimate/argentMaxFee.js +10 -13
  406. package/dist/src/transactions/estimate/error.cjs +1 -1
  407. package/dist/src/transactions/estimate/error.js +12 -13
  408. package/dist/src/transactions/estimate/model.cjs +1 -1
  409. package/dist/src/transactions/estimate/model.js +18 -13
  410. package/dist/src/transactions/estimate/utils.cjs +1 -1
  411. package/dist/src/transactions/estimate/utils.js +139 -172
  412. package/dist/src/transactions/findTransfersAndApprovals.cjs +1 -1
  413. package/dist/src/transactions/findTransfersAndApprovals.js +34 -30
  414. package/dist/src/transactions/getPrettyRcpError.cjs +1 -1
  415. package/dist/src/transactions/getPrettyRcpError.js +8 -10
  416. package/dist/src/transactions/service/implementation.cjs +1 -1
  417. package/dist/src/transactions/service/implementation.js +187 -208
  418. package/dist/src/transactions/service/types.cjs +1 -1
  419. package/dist/src/transactions/service/types.js +9 -9
  420. package/dist/src/transactions/service/utils.cjs +1 -1
  421. package/dist/src/transactions/service/utils.js +24 -25
  422. package/dist/src/transactions/transactionExecuteTypes.cjs +1 -1
  423. package/dist/src/transactions/transactionExecuteTypes.js +8 -9
  424. package/dist/src/transactions/transactionReviewTypes.cjs +1 -1
  425. package/dist/src/transactions/transactionReviewTypes.js +9 -9
  426. package/dist/src/transactions/transactionVersion.cjs +1 -1
  427. package/dist/src/transactions/transactionVersion.js +8 -13
  428. package/dist/src/transactions/txv3.cjs +1 -1
  429. package/dist/src/transactions/txv3.js +10 -11
  430. package/dist/src/utils/address.cjs +1 -1
  431. package/dist/src/utils/address.js +4 -4
  432. package/dist/src/utils/arrays.cjs +1 -1
  433. package/dist/src/utils/arrays.js +4 -4
  434. package/dist/src/utils/avatarImage.cjs +4 -4
  435. package/dist/src/utils/avatarImage.js +35 -40
  436. package/dist/src/utils/base58.cjs +1 -1
  437. package/dist/src/utils/base58.js +12 -15
  438. package/dist/src/utils/bigNumber.cjs +1 -1
  439. package/dist/src/utils/bigNumber.d.ts +1 -1
  440. package/dist/src/utils/bigNumber.js +5 -7
  441. package/dist/src/utils/bips.cjs +1 -1
  442. package/dist/src/utils/bips.js +12 -10
  443. package/dist/src/utils/daysBetween.cjs +1 -1
  444. package/dist/src/utils/daysBetween.js +6 -6
  445. package/dist/src/utils/env.cjs +1 -1
  446. package/dist/src/utils/env.js +4 -4
  447. package/dist/src/utils/hex.cjs +1 -1
  448. package/dist/src/utils/hex.js +7 -8
  449. package/dist/src/utils/id.cjs +1 -1
  450. package/dist/src/utils/id.js +7 -7
  451. package/dist/src/utils/initials.cjs +1 -1
  452. package/dist/src/utils/initials.js +12 -15
  453. package/dist/src/utils/isContractDeployed.cjs +1 -1
  454. package/dist/src/utils/isContractDeployed.js +9 -9
  455. package/dist/src/utils/nonNullable.cjs +1 -1
  456. package/dist/src/utils/nonNullable.js +6 -6
  457. package/dist/src/utils/number/abbreviateNumber.cjs +1 -1
  458. package/dist/src/utils/number/abbreviateNumber.js +13 -14
  459. package/dist/src/utils/number/isAllowedAddressHexInputValue.cjs +1 -1
  460. package/dist/src/utils/number/isAllowedAddressHexInputValue.js +4 -7
  461. package/dist/src/utils/number/isAllowedNumericInputValue.cjs +1 -1
  462. package/dist/src/utils/number/isAllowedNumericInputValue.js +5 -5
  463. package/dist/src/utils/number/isNumeric.cjs +1 -1
  464. package/dist/src/utils/number/isNumeric.js +4 -4
  465. package/dist/src/utils/number/prettifyNumber.cjs +1 -1
  466. package/dist/src/utils/number/prettifyNumber.js +65 -75
  467. package/dist/src/utils/parseAmount.cjs +1 -1
  468. package/dist/src/utils/parseAmount.js +10 -11
  469. package/dist/src/utils/pluralise.cjs +1 -1
  470. package/dist/src/utils/pluralise.js +4 -4
  471. package/dist/src/utils/readFileAsString.cjs +1 -1
  472. package/dist/src/utils/readFileAsString.js +6 -6
  473. package/dist/src/utils/retryUntilInitialised.cjs +1 -1
  474. package/dist/src/utils/retryUntilInitialised.js +21 -20
  475. package/dist/src/utils/schemas.cjs +1 -1
  476. package/dist/src/utils/schemas.js +29 -26
  477. package/dist/src/utils/starknet/starknet.cjs +1 -1
  478. package/dist/src/utils/starknet/starknet.js +64 -77
  479. package/dist/src/utils/starknet/starknetLibTypes.cjs +1 -1
  480. package/dist/src/utils/starknet/starknetLibTypes.js +7 -7
  481. package/dist/src/utils/starknet/starknetSchemas.cjs +1 -1
  482. package/dist/src/utils/starknet/starknetSchemas.js +84 -99
  483. package/dist/src/utils/transactions.cjs +1 -1
  484. package/dist/src/utils/transactions.js +10 -10
  485. package/dist/src/utils/url/urlWithQuery.cjs +1 -1
  486. package/dist/src/utils/url/urlWithQuery.js +8 -8
  487. package/dist/src/utils/voidify.cjs +1 -1
  488. package/dist/src/utils/voidify.js +7 -7
  489. package/dist/swap.cjs +1 -1
  490. package/dist/swap.js +8 -22
  491. package/package.json +20 -19
  492. package/dist/.eslintrc.d.cts +0 -39
  493. package/dist/_virtual/_commonjsHelpers.cjs +0 -1
  494. package/dist/_virtual/_commonjsHelpers.js +0 -6
  495. package/dist/_virtual/numeral.cjs +0 -1
  496. package/dist/_virtual/numeral.js +0 -7
  497. package/dist/_virtual/numeral2.cjs +0 -1
  498. package/dist/_virtual/numeral2.js +0 -4
  499. package/dist/_virtual/semver.cjs +0 -1
  500. package/dist/_virtual/semver.js +0 -7
  501. package/dist/_virtual/semver2.cjs +0 -1
  502. package/dist/_virtual/semver2.js +0 -4
@@ -1,76 +1,66 @@
1
- import { BigNumber as u } from "../../../node_modules/.pnpm/bignumber.js@9.1.2/node_modules/bignumber.js/bignumber.js";
2
- import { isNumeric as y } from "./isNumeric.js";
3
- const N = {
4
- CURRENCY: {
5
- minDecimalPlaces: 2,
6
- maxDecimalPlaces: 10,
7
- minDecimalSignificantDigits: 2,
8
- decimalPlacesWhenZero: 2,
9
- allowLeadingZerosInDecimalPart: !0,
10
- groupSeparator: ",",
11
- decimalSeparator: "."
12
- },
13
- TOKEN: {
14
- minDecimalPlaces: 4,
15
- maxDecimalPlaces: 16,
16
- minDecimalSignificantDigits: 2,
17
- decimalPlacesWhenZero: 1,
18
- allowLeadingZerosInDecimalPart: !0,
19
- groupSeparator: ",",
20
- decimalSeparator: "."
21
- }
22
- }, T = (r, e) => x(r, {
23
- ...N.CURRENCY,
24
- ...e || {}
25
- }), d = (r, e) => x(r, {
26
- ...N.TOKEN,
27
- ...e || {}
28
- }), F = {
29
- groupSize: 3,
30
- decimalSeparator: ".",
31
- groupSeparator: ","
32
- }, x = (r, { minDecimalPlaces: e, maxDecimalPlaces: O, minDecimalSignificantDigits: w, decimalPlacesWhenZero: p, allowLeadingZerosInDecimalPart: P, groupSeparator: h, decimalSeparator: s = F.decimalSeparator, maxNrDigits: g, roundingMode: c } = N.CURRENCY) => {
33
- if (!y(r))
34
- return null;
35
- const a = {
36
- ...F,
37
- groupSeparator: h,
38
- decimalSeparator: s
39
- }, i = new u(typeof r == "bigint" ? r.toString() : r);
40
- let o;
41
- const C = `0.${"".padStart(p - 1, "0")}1`;
42
- if (i.lt(new u(C)) && !P)
43
- o = `0.${"".padStart(p, "0")}`;
44
- else if (i.gte(1))
45
- o = e !== 0 ? c ? i.toFormat(e, c, a) : i.toFormat(e, a) : i.toFormat(e, u.ROUND_FLOOR, a);
46
- else {
47
- const l = (c ? i.toFormat(O, c, a) : i.toFormat(O, a)).split(s)[1].match(/^0+/), m = P && l && l.length ? l[0].length : 0, f = Math.max(m + w, e);
48
- o = c ? i.toFormat(f, c, a) : i.toFormat(f, a);
49
- }
50
- const [D, R] = o.split(s);
51
- let t = D;
52
- if (R) {
53
- const n = R.replace(/0+$/, "");
54
- t += n ? `.${n}` : "";
55
- }
56
- const S = 1 + o.indexOf(".") + p;
57
- if (t.length < S && (t = o.substring(0, S)), g) {
58
- const n = t.replace(new RegExp(`[${h}${s}]`, "g"), "").length;
59
- if (D.replace(new RegExp(`[${h}]`, "g"), "").length > g)
60
- t = D;
61
- else if (n > g) {
62
- const l = n - g, m = t.indexOf(s);
63
- if (m !== -1) {
64
- const f = Math.max(0, t.length - m - 1 - l);
65
- t = t.substring(0, m + 1 + f);
66
- }
67
- }
68
- }
69
- return t;
70
- };
71
- export {
72
- T as prettifyCurrencyNumber,
73
- x as prettifyNumber,
74
- N as prettifyNumberConfig,
75
- d as prettifyTokenNumber
1
+ import { isNumeric as e } from "./isNumeric.js";
2
+ import t from "../../../node_modules/.pnpm/bignumber.js@9.1.2/node_modules/bignumber.js/bignumber.js";
3
+ //#region src/utils/number/prettifyNumber.ts
4
+ var n = {
5
+ CURRENCY: {
6
+ minDecimalPlaces: 2,
7
+ maxDecimalPlaces: 10,
8
+ minDecimalSignificantDigits: 2,
9
+ decimalPlacesWhenZero: 2,
10
+ allowLeadingZerosInDecimalPart: !0,
11
+ groupSeparator: ",",
12
+ decimalSeparator: "."
13
+ },
14
+ TOKEN: {
15
+ minDecimalPlaces: 4,
16
+ maxDecimalPlaces: 16,
17
+ minDecimalSignificantDigits: 2,
18
+ decimalPlacesWhenZero: 1,
19
+ allowLeadingZerosInDecimalPart: !0,
20
+ groupSeparator: ",",
21
+ decimalSeparator: "."
22
+ }
23
+ }, r = (e, t) => o(e, {
24
+ ...n.CURRENCY,
25
+ ...t || {}
26
+ }), i = (e, t) => o(e, {
27
+ ...n.TOKEN,
28
+ ...t || {}
29
+ }), a = {
30
+ groupSize: 3,
31
+ decimalSeparator: ".",
32
+ groupSeparator: ","
33
+ }, o = (r, { minDecimalPlaces: i, maxDecimalPlaces: o, minDecimalSignificantDigits: s, decimalPlacesWhenZero: c, allowLeadingZerosInDecimalPart: l, groupSeparator: u, decimalSeparator: d = a.decimalSeparator, maxNrDigits: f, roundingMode: p } = n.CURRENCY) => {
34
+ if (!e(r)) return null;
35
+ let m = {
36
+ ...a,
37
+ groupSeparator: u,
38
+ decimalSeparator: d
39
+ }, h = new t(typeof r == "bigint" ? r.toString() : r), g, _ = `0.${"".padStart(c - 1, "0")}1`;
40
+ if (h.lt(new t(_)) && !l) g = `0.${"".padStart(c, "0")}`;
41
+ else if (h.gte(1)) g = i === 0 ? h.toFormat(i, t.ROUND_FLOOR, m) : p ? h.toFormat(i, p, m) : h.toFormat(i, m);
42
+ else {
43
+ let e = (p ? h.toFormat(o, p, m) : h.toFormat(o, m)).split(d)[1].match(/^0+/), t = l && e && e.length ? e[0].length : 0, n = Math.max(t + s, i);
44
+ g = p ? h.toFormat(n, p, m) : h.toFormat(n, m);
45
+ }
46
+ let [v, y] = g.split(d), b = v;
47
+ if (y) {
48
+ let e = y.replace(/0+$/, "");
49
+ b += e ? `.${e}` : "";
50
+ }
51
+ let x = 1 + g.indexOf(".") + c;
52
+ if (b.length < x && (b = g.substring(0, x)), f) {
53
+ let e = b.replace(RegExp(`[${u}${d}]`, "g"), "").length;
54
+ if (v.replace(RegExp(`[${u}]`, "g"), "").length > f) b = v;
55
+ else if (e > f) {
56
+ let t = e - f, n = b.indexOf(d);
57
+ if (n !== -1) {
58
+ let e = Math.max(0, b.length - n - 1 - t);
59
+ b = b.substring(0, n + 1 + e);
60
+ }
61
+ }
62
+ }
63
+ return b;
76
64
  };
65
+ //#endregion
66
+ export { r as prettifyCurrencyNumber, o as prettifyNumber, n as prettifyNumberConfig, i as prettifyTokenNumber };
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("starknet"),u=require("./number/isNumeric.cjs"),a=require("../bigdecimal/parseUnits.cjs"),i=(e,r=18)=>{const t=e.replace(",",".");return!e||!u.isNumeric(t)?0n:a.parseUnits(t,Number(r)).value};function o(e){return n.uint256.bnToUint256(e)}exports.getUint256CalldataFromBN=o;exports.parseAmountValue=i;
1
+ require(`../../_virtual/_rolldown/runtime.cjs`);const e=require(`../bigdecimal/parseUnits.cjs`),t=require(`./number/isNumeric.cjs`);let n=require(`starknet`);var r=(n,r=18)=>{let i=n.replace(`,`,`.`);return!n||!t.isNumeric(i)?0n:e.parseUnits(i,Number(r)).value};function i(e){return n.uint256.bnToUint256(e)}exports.getUint256CalldataFromBN=i,exports.parseAmountValue=r;
@@ -1,14 +1,13 @@
1
+ import { parseUnits as e } from "../bigdecimal/parseUnits.js";
2
+ import { isNumeric as t } from "./number/isNumeric.js";
1
3
  import { uint256 as n } from "starknet";
2
- import { isNumeric as e } from "./number/isNumeric.js";
3
- import { parseUnits as m } from "../bigdecimal/parseUnits.js";
4
- const p = (r, o = 18) => {
5
- const t = r.replace(",", ".");
6
- return !r || !e(t) ? 0n : m(t, Number(o)).value;
4
+ //#region src/utils/parseAmount.ts
5
+ var r = (n, r = 18) => {
6
+ let i = n.replace(",", ".");
7
+ return !n || !t(i) ? 0n : e(i, Number(r)).value;
7
8
  };
8
- function s(r) {
9
- return n.bnToUint256(r);
9
+ function i(e) {
10
+ return n.bnToUint256(e);
10
11
  }
11
- export {
12
- s as getUint256CalldataFromBN,
13
- p as parseAmountValue
14
- };
12
+ //#endregion
13
+ export { i as getUint256CalldataFromBN, r as parseAmountValue };
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=(e,r)=>`${e} ${r}${e===1?"":"s"}`;exports.pluralise=t;
1
+ var e=(e,t)=>`${e} ${t}${e===1?``:`s`}`;exports.pluralise=e;
@@ -1,4 +1,4 @@
1
- const t = (r, s) => `${r} ${s}${r === 1 ? "" : "s"}`;
2
- export {
3
- t as pluralise
4
- };
1
+ //#region src/utils/pluralise.ts
2
+ var e = (e, t) => `${e} ${t}${e === 1 ? "" : "s"}`;
3
+ //#endregion
4
+ export { e as pluralise };
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=n=>new Promise((o,e)=>{const r=new FileReader;r.onload=()=>r.result?o(r.result?.toString()):e(new Error("Could not read file")),r.onerror=e,r.onabort=e.bind(null,new Error("User aborted")),r.readAsText(n)});exports.readFileAsString=t;
1
+ var e=e=>new Promise((t,n)=>{let r=new FileReader;r.onload=()=>r.result?t(r.result?.toString()):n(Error(`Could not read file`)),r.onerror=n,r.onabort=n.bind(null,Error(`User aborted`)),r.readAsText(e)});exports.readFileAsString=e;
@@ -1,7 +1,7 @@
1
- const t = (n) => new Promise((o, e) => {
2
- const r = new FileReader();
3
- r.onload = () => r.result ? o(r.result?.toString()) : e(new Error("Could not read file")), r.onerror = e, r.onabort = e.bind(null, new Error("User aborted")), r.readAsText(n);
1
+ //#region src/utils/readFileAsString.ts
2
+ var e = (e) => new Promise((t, n) => {
3
+ let r = new FileReader();
4
+ r.onload = () => r.result ? t(r.result?.toString()) : n(/* @__PURE__ */ Error("Could not read file")), r.onerror = n, r.onabort = n.bind(null, /* @__PURE__ */ Error("User aborted")), r.readAsText(e);
4
5
  });
5
- export {
6
- t as readFileAsString
7
- };
6
+ //#endregion
7
+ export { e as readFileAsString };
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("async-retry"),o=require("./schemas.cjs");async function u(n,i,s={retries:5,minTimeout:5e3}){return a(async e=>{let t=null;try{t=await n()}catch{return e(new Error("Error fetching")),null}const r=o.safeParseAndWarn(i,t);if(!r.success)return e(new Error("Error parsing response")),null;if(r.data.status!=="initialised")throw new Error("Not initialised yet");return r.data},s)}exports.retryUntilInitialised=u;
1
+ const e=require(`../../_virtual/_rolldown/runtime.cjs`),t=require(`./schemas.cjs`);let n=require(`async-retry`);n=e.__toESM(n);async function r(e,r,i={retries:5,minTimeout:5e3}){return(0,n.default)(async n=>{let i;try{i=await e()}catch{return n(Error(`Error fetching`)),null}let a=t.safeParseAndWarn(r,i);if(!a.success)return n(Error(`Error parsing response`)),null;if(a.data.status!==`initialised`)throw Error(`Not initialised yet`);return a.data},i)}exports.retryUntilInitialised=r;
@@ -1,21 +1,22 @@
1
- import a from "async-retry";
2
- import { safeParseAndWarn as o } from "./schemas.js";
3
- async function c(n, i, s = { retries: 5, minTimeout: 5e3 }) {
4
- return a(async (t) => {
5
- let e = null;
6
- try {
7
- e = await n();
8
- } catch {
9
- return t(new Error("Error fetching")), null;
10
- }
11
- const r = o(i, e);
12
- if (!r.success)
13
- return t(new Error("Error parsing response")), null;
14
- if (r.data.status !== "initialised")
15
- throw new Error("Not initialised yet");
16
- return r.data;
17
- }, s);
1
+ import { safeParseAndWarn as e } from "./schemas.js";
2
+ import t from "async-retry";
3
+ //#region src/utils/retryUntilInitialised.ts
4
+ async function n(n, r, i = {
5
+ retries: 5,
6
+ minTimeout: 5e3
7
+ }) {
8
+ return t(async (t) => {
9
+ let i;
10
+ try {
11
+ i = await n();
12
+ } catch {
13
+ return t(/* @__PURE__ */ Error("Error fetching")), null;
14
+ }
15
+ let a = e(r, i);
16
+ if (!a.success) return t(/* @__PURE__ */ Error("Error parsing response")), null;
17
+ if (a.data.status !== "initialised") throw Error("Not initialised yet");
18
+ return a.data;
19
+ }, i);
18
20
  }
19
- export {
20
- c as retryUntilInitialised
21
- };
21
+ //#endregion
22
+ export { n as retryUntilInitialised };
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("zod"),c=r.z.boolean().transform(e=>String(e)),i=r.z.string().transform(e=>e==="true");function o(e){return r.z.object(e).passthrough().superRefine(t=>{const n=Object.keys(e),a=Object.keys(t).filter(s=>!n.includes(s));a.length>0&&`${a.join(", ")}`})}function u(e){const t=o(e);return Object.assign(t,{extend:n=>o({...e,...n})})}const l=(e,t)=>{try{return{success:!0,data:e.parse(t)}}catch(n){if(n instanceof r.z.ZodError)return console.error("Validation warnings:",n.issues),{success:!1,error:n};throw n}};exports.booleanToStringSchema=c;exports.createSchemaWithWarnings=u;exports.safeParseAndWarn=l;exports.stringToBooleanSchema=i;
1
+ require(`../../_virtual/_rolldown/runtime.cjs`);let e=require(`zod`);var t=e.z.boolean().transform(e=>String(e)),n=e.z.string().transform(e=>e===`true`);function r(t){return e.z.object(t).passthrough().superRefine(e=>{let n=Object.keys(t),r=Object.keys(e).filter(e=>!n.includes(e));r.length>0&&console.warn(`Unknown properties detected: ${r.join(`, `)}`)})}function i(e){let t=r(e);return Object.assign(t,{extend:t=>r({...e,...t})})}var a=(t,n)=>{try{return{success:!0,data:t.parse(n)}}catch(t){if(t instanceof e.z.ZodError)return console.error(`Validation warnings:`,t.issues),{success:!1,error:t};throw t}};exports.booleanToStringSchema=t,exports.createSchemaWithWarnings=i,exports.safeParseAndWarn=a,exports.stringToBooleanSchema=n;
@@ -1,29 +1,32 @@
1
- import { z as r } from "zod";
2
- const i = r.boolean().transform((e) => String(e)), u = r.string().transform((e) => e === "true");
3
- function s(e) {
4
- return r.object(e).passthrough().superRefine((t) => {
5
- const n = Object.keys(e), o = Object.keys(t).filter((a) => !n.includes(a));
6
- o.length > 0 && `${o.join(", ")}`;
7
- });
1
+ import { z as e } from "zod";
2
+ //#region src/utils/schemas.ts
3
+ var t = e.boolean().transform((e) => String(e)), n = e.string().transform((e) => e === "true");
4
+ function r(t) {
5
+ return e.object(t).passthrough().superRefine((e) => {
6
+ let n = Object.keys(t), r = Object.keys(e).filter((e) => !n.includes(e));
7
+ r.length > 0 && console.warn(`Unknown properties detected: ${r.join(", ")}`);
8
+ });
8
9
  }
9
- function d(e) {
10
- const t = s(e);
11
- return Object.assign(t, {
12
- extend: (n) => s({ ...e, ...n })
13
- });
10
+ function i(e) {
11
+ let t = r(e);
12
+ return Object.assign(t, { extend: (t) => r({
13
+ ...e,
14
+ ...t
15
+ }) });
14
16
  }
15
- const f = (e, t) => {
16
- try {
17
- return { success: !0, data: e.parse(t) };
18
- } catch (n) {
19
- if (n instanceof r.ZodError)
20
- return console.error("Validation warnings:", n.issues), { success: !1, error: n };
21
- throw n;
22
- }
23
- };
24
- export {
25
- i as booleanToStringSchema,
26
- d as createSchemaWithWarnings,
27
- f as safeParseAndWarn,
28
- u as stringToBooleanSchema
17
+ var a = (t, n) => {
18
+ try {
19
+ return {
20
+ success: !0,
21
+ data: t.parse(n)
22
+ };
23
+ } catch (t) {
24
+ if (t instanceof e.ZodError) return console.error("Validation warnings:", t.issues), {
25
+ success: !1,
26
+ error: t
27
+ };
28
+ throw t;
29
+ }
29
30
  };
31
+ //#endregion
32
+ export { t as booleanToStringSchema, i as createSchemaWithWarnings, a as safeParseAndWarn, n as stringToBooleanSchema };
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("zod"),h=require("../../chains/starknet/address.cjs"),t=a.z.union([a.z.string(),a.z.number(),a.z.bigint()]),l=a.z.object({low:t,high:t}),o=a.z.array(a.z.string()).and(a.z.object({__compiled__:a.z.boolean().optional()}).optional()),s=a.z.lazy(()=>a.z.array(a.z.union([r,a.z.array(r),c]))),r=a.z.union([t,l,a.z.any(),a.z.boolean()]),i=a.z.lazy(()=>a.z.record(a.z.string(),a.z.union([r,a.z.array(r),c]))),c=a.z.lazy(()=>a.z.union([i,s])),z=a.z.union([c,o]).optional(),m=a.z.lazy(()=>a.z.object({contractAddress:a.z.string(),calldata:z,entrypoint:a.z.string().optional()})),d=a.z.lazy(()=>m.and(a.z.object({entrypoint:a.z.string()}))),e=a.z.string().refine(n=>typeof parseInt(n)=="number"),g=a.z.tuple([e]),S=a.z.tuple([e]),u=a.z.object({new_threshold:a.z.string().refine(n=>typeof parseInt(n)=="number"),signers_to_add:a.z.array(e)}),p=a.z.object({new_threshold:a.z.string().refine(n=>typeof parseInt(n)=="number"),signers_to_remove:a.z.array(e)}),y=a.z.object({signer_to_remove:e,signer_to_add:e}),b=a.z.tuple([e]),C=a.z.tuple([e]),j=a.z.tuple([e]),w=a.z.tuple([e]).rest(e),_=a.z.object({recipient:h.addressSchema,amount:a.z.object({low:t,high:t})}),f=a.z.object({types:a.z.record(a.z.string(),a.z.array(a.z.union([a.z.object({name:a.z.string(),type:a.z.literal("merkletree"),contains:a.z.string()}),a.z.object({name:a.z.string(),type:a.z.literal("enum"),contains:a.z.string()}),a.z.object({name:a.z.string(),type:a.z.string()})]))),primaryType:a.z.string(),domain:a.z.record(a.z.string(),a.z.unknown()),message:a.z.record(a.z.string(),a.z.any()).or(a.z.object({}).passthrough())});exports.addOwnersCalldataSchema=u;exports.addPluginCalldataSchema=C;exports.bigNumberishSchema=t;exports.callDetailsSchema=m;exports.callSchema=d;exports.calldataSchema=o;exports.changeGuardianCalldataSchema=g;exports.changeThresholdCalldataSchema=b;exports.escapeGuardianCalldataSchema=S;exports.executeOnPluginCalldataSchema=w;exports.feltSchema=e;exports.looseCalldataSchema=z;exports.multiTypeSchema=r;exports.rawArgsArraySchema=s;exports.rawArgsObjectSchema=i;exports.rawArgsSchema=c;exports.removeOwnersCalldataSchema=p;exports.removePluginCalldataSchema=j;exports.replaceSignerCalldataSchema=y;exports.transferCalldataSchema=_;exports.typedDataSchema=f;exports.uint256Schema=l;
1
+ require(`../../../_virtual/_rolldown/runtime.cjs`);const e=require(`../../chains/starknet/address.cjs`);let t=require(`zod`);var n=t.z.union([t.z.string(),t.z.number(),t.z.bigint()]),r=t.z.object({low:n,high:n}),i=t.z.array(t.z.string()).and(t.z.object({__compiled__:t.z.boolean().optional()}).optional()),a=t.z.lazy(()=>t.z.array(t.z.union([o,t.z.array(o),c]))),o=t.z.union([n,r,t.z.any(),t.z.boolean()]),s=t.z.lazy(()=>t.z.record(t.z.string(),t.z.union([o,t.z.array(o),c]))),c=t.z.lazy(()=>t.z.union([s,a])),l=t.z.union([c,i]).optional(),u=t.z.lazy(()=>t.z.object({contractAddress:t.z.string(),calldata:l,entrypoint:t.z.string().optional()})),d=t.z.lazy(()=>u.and(t.z.object({entrypoint:t.z.string()}))),f=t.z.string().refine(e=>typeof parseInt(e)==`number`),p=t.z.tuple([f]),m=t.z.tuple([f]),h=t.z.object({new_threshold:t.z.string().refine(e=>typeof parseInt(e)==`number`),signers_to_add:t.z.array(f)}),g=t.z.object({new_threshold:t.z.string().refine(e=>typeof parseInt(e)==`number`),signers_to_remove:t.z.array(f)}),_=t.z.object({signer_to_remove:f,signer_to_add:f}),v=t.z.tuple([f]),y=t.z.tuple([f]),b=t.z.tuple([f]),x=t.z.tuple([f]).rest(f),S=t.z.object({recipient:e.addressSchema,amount:t.z.object({low:n,high:n})}),C=t.z.object({types:t.z.record(t.z.string(),t.z.array(t.z.union([t.z.object({name:t.z.string(),type:t.z.literal(`merkletree`),contains:t.z.string()}),t.z.object({name:t.z.string(),type:t.z.literal(`enum`),contains:t.z.string()}),t.z.object({name:t.z.string(),type:t.z.string()})]))),primaryType:t.z.string(),domain:t.z.record(t.z.string(),t.z.unknown()),message:t.z.record(t.z.string(),t.z.any()).or(t.z.object({}).passthrough())});exports.addOwnersCalldataSchema=h,exports.addPluginCalldataSchema=y,exports.bigNumberishSchema=n,exports.callDetailsSchema=u,exports.callSchema=d,exports.calldataSchema=i,exports.changeGuardianCalldataSchema=p,exports.changeThresholdCalldataSchema=v,exports.escapeGuardianCalldataSchema=m,exports.executeOnPluginCalldataSchema=x,exports.feltSchema=f,exports.looseCalldataSchema=l,exports.multiTypeSchema=o,exports.rawArgsArraySchema=a,exports.rawArgsObjectSchema=s,exports.rawArgsSchema=c,exports.removeOwnersCalldataSchema=g,exports.removePluginCalldataSchema=b,exports.replaceSignerCalldataSchema=_,exports.transferCalldataSchema=S,exports.typedDataSchema=C,exports.uint256Schema=r;
@@ -1,78 +1,65 @@
1
- import { z as a } from "zod";
2
- import { addressSchema as c } from "../../chains/starknet/address.js";
3
- const n = a.union([a.string(), a.number(), a.bigint()]), s = a.object({
4
- low: n,
5
- high: n
6
- }), l = a.array(a.string()).and(a.object({
7
- __compiled__: a.boolean().optional()
8
- }).optional()), i = a.lazy(() => a.array(a.union([r, a.array(r), o]))), r = a.union([
9
- n,
10
- s,
11
- a.any(),
12
- a.boolean()
13
- ]), m = a.lazy(() => a.record(a.string(), a.union([r, a.array(r), o]))), o = a.lazy(() => a.union([m, i])), d = a.union([o, l]).optional(), g = a.lazy(() => a.object({
14
- contractAddress: a.string(),
15
- calldata: d,
16
- entrypoint: a.string().optional()
17
- })), u = a.lazy(() => g.and(a.object({
18
- entrypoint: a.string()
19
- }))), e = a.string().refine((t) => typeof parseInt(t) == "number"), y = a.tuple([e]), b = a.tuple([e]), S = a.object({
20
- new_threshold: a.string().refine((t) => typeof parseInt(t) == "number"),
21
- signers_to_add: a.array(e)
22
- }), j = a.object({
23
- new_threshold: a.string().refine((t) => typeof parseInt(t) == "number"),
24
- signers_to_remove: a.array(e)
25
- }), _ = a.object({
26
- signer_to_remove: e,
27
- signer_to_add: e
28
- }), C = a.tuple([e]), f = a.tuple([e]), w = a.tuple([e]), z = a.tuple([e]).rest(e), A = a.object({
29
- recipient: c,
30
- amount: a.object({
31
- low: n,
32
- high: n
33
- })
34
- }), v = a.object({
35
- types: a.record(a.string(), a.array(a.union([
36
- a.object({
37
- name: a.string(),
38
- type: a.literal("merkletree"),
39
- contains: a.string()
40
- }),
41
- a.object({
42
- name: a.string(),
43
- type: a.literal("enum"),
44
- contains: a.string()
45
- }),
46
- a.object({
47
- name: a.string(),
48
- type: a.string()
49
- })
50
- ]))),
51
- primaryType: a.string(),
52
- domain: a.record(a.string(), a.unknown()),
53
- message: a.record(a.string(), a.any()).or(a.object({}).passthrough())
1
+ import { addressSchema as e } from "../../chains/starknet/address.js";
2
+ import { z as t } from "zod";
3
+ //#region src/utils/starknet/starknet.ts
4
+ var n = t.union([
5
+ t.string(),
6
+ t.number(),
7
+ t.bigint()
8
+ ]), r = t.object({
9
+ low: n,
10
+ high: n
11
+ }), i = t.array(t.string()).and(t.object({ __compiled__: t.boolean().optional() }).optional()), a = t.lazy(() => t.array(t.union([
12
+ o,
13
+ t.array(o),
14
+ c
15
+ ]))), o = t.union([
16
+ n,
17
+ r,
18
+ t.any(),
19
+ t.boolean()
20
+ ]), s = t.lazy(() => t.record(t.string(), t.union([
21
+ o,
22
+ t.array(o),
23
+ c
24
+ ]))), c = t.lazy(() => t.union([s, a])), l = t.union([c, i]).optional(), u = t.lazy(() => t.object({
25
+ contractAddress: t.string(),
26
+ calldata: l,
27
+ entrypoint: t.string().optional()
28
+ })), d = t.lazy(() => u.and(t.object({ entrypoint: t.string() }))), f = t.string().refine((e) => typeof parseInt(e) == "number"), p = t.tuple([f]), m = t.tuple([f]), h = t.object({
29
+ new_threshold: t.string().refine((e) => typeof parseInt(e) == "number"),
30
+ signers_to_add: t.array(f)
31
+ }), g = t.object({
32
+ new_threshold: t.string().refine((e) => typeof parseInt(e) == "number"),
33
+ signers_to_remove: t.array(f)
34
+ }), _ = t.object({
35
+ signer_to_remove: f,
36
+ signer_to_add: f
37
+ }), v = t.tuple([f]), y = t.tuple([f]), b = t.tuple([f]), x = t.tuple([f]).rest(f), S = t.object({
38
+ recipient: e,
39
+ amount: t.object({
40
+ low: n,
41
+ high: n
42
+ })
43
+ }), C = t.object({
44
+ types: t.record(t.string(), t.array(t.union([
45
+ t.object({
46
+ name: t.string(),
47
+ type: t.literal("merkletree"),
48
+ contains: t.string()
49
+ }),
50
+ t.object({
51
+ name: t.string(),
52
+ type: t.literal("enum"),
53
+ contains: t.string()
54
+ }),
55
+ t.object({
56
+ name: t.string(),
57
+ type: t.string()
58
+ })
59
+ ]))),
60
+ primaryType: t.string(),
61
+ domain: t.record(t.string(), t.unknown()),
62
+ message: t.record(t.string(), t.any()).or(t.object({}).passthrough())
54
63
  });
55
- export {
56
- S as addOwnersCalldataSchema,
57
- f as addPluginCalldataSchema,
58
- n as bigNumberishSchema,
59
- g as callDetailsSchema,
60
- u as callSchema,
61
- l as calldataSchema,
62
- y as changeGuardianCalldataSchema,
63
- C as changeThresholdCalldataSchema,
64
- b as escapeGuardianCalldataSchema,
65
- z as executeOnPluginCalldataSchema,
66
- e as feltSchema,
67
- d as looseCalldataSchema,
68
- r as multiTypeSchema,
69
- i as rawArgsArraySchema,
70
- m as rawArgsObjectSchema,
71
- o as rawArgsSchema,
72
- j as removeOwnersCalldataSchema,
73
- w as removePluginCalldataSchema,
74
- _ as replaceSignerCalldataSchema,
75
- A as transferCalldataSchema,
76
- v as typedDataSchema,
77
- s as uint256Schema
78
- };
64
+ //#endregion
65
+ export { h as addOwnersCalldataSchema, y as addPluginCalldataSchema, n as bigNumberishSchema, u as callDetailsSchema, d as callSchema, i as calldataSchema, p as changeGuardianCalldataSchema, v as changeThresholdCalldataSchema, m as escapeGuardianCalldataSchema, x as executeOnPluginCalldataSchema, f as feltSchema, l as looseCalldataSchema, o as multiTypeSchema, a as rawArgsArraySchema, s as rawArgsObjectSchema, c as rawArgsSchema, g as removeOwnersCalldataSchema, b as removePluginCalldataSchema, _ as replaceSignerCalldataSchema, S as transferCalldataSchema, C as typedDataSchema, r as uint256Schema };
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});exports.FunctionAbiType=void 0;(function(t){t[t.function=0]="function",t[t.l1_handler=1]="l1_handler",t[t.constructor=2]="constructor"})(exports.FunctionAbiType||(exports.FunctionAbiType={}));
1
+ var e;(function(e){e[e.function=0]=`function`,e[e.l1_handler=1]=`l1_handler`,e[e.constructor=2]=`constructor`})(e||={}),Object.defineProperty(exports,`FunctionAbiType`,{enumerable:!0,get:function(){return e}});
@@ -1,7 +1,7 @@
1
- var l;
2
- (function(r) {
3
- r[r.function = 0] = "function", r[r.l1_handler = 1] = "l1_handler", r[r.constructor = 2] = "constructor";
4
- })(l || (l = {}));
5
- export {
6
- l as FunctionAbiType
7
- };
1
+ //#region src/utils/starknet/starknetLibTypes.ts
2
+ var e;
3
+ (function(e) {
4
+ e[e.function = 0] = "function", e[e.l1_handler = 1] = "l1_handler", e[e.constructor = 2] = "constructor";
5
+ })(e ||= {});
6
+ //#endregion
7
+ export { e as FunctionAbiType };
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("zod"),f=require("./starknetLibTypes.cjs"),c=e.z.array(e.z.string()),t=e.z.object({selector:e.z.string(),offset:e.z.string(),builtins:c.optional()}),i=e.z.object({CONSTRUCTOR:e.z.array(t),EXTERNAL:e.z.array(t),L1_HANDLER:e.z.array(t)}),C=e.z.string(),m=e.z.object({builtins:c,data:e.z.array(e.z.string())}),r=e.z.object({name:e.z.string(),type:e.z.union([e.z.literal("felt"),e.z.literal("felt*"),e.z.string()])}),z=e.z.nativeEnum(f.FunctionAbiType),y=e.z.object({inputs:e.z.array(r),name:e.z.string(),outputs:e.z.array(r),stateMutability:e.z.literal("view").optional(),state_mutability:e.z.string().optional(),type:z}),n=e.z.object({name:e.z.string(),type:e.z.union([e.z.literal("felt"),e.z.literal("felt*"),e.z.string()]),kind:e.z.union([e.z.literal("key"),e.z.literal("data")])}),l=e.z.object({name:e.z.string(),type:e.z.literal("event"),data:e.z.array(n),keys:e.z.array(n)}),b=e.z.object({name:e.z.string(),members:e.z.array(n),kind:e.z.literal("struct"),type:e.z.literal("event")}),S=e.z.object({members:e.z.array(r.and(e.z.object({offset:e.z.number()}))),name:e.z.string(),size:e.z.number(),type:e.z.literal("struct")}),h=e.z.union([b,l]),o=e.z.array(e.z.union([y,h,S,e.z.any()])),p=e.z.object({program:m,entry_points_by_type:i,abi:o}),s=e.z.array(e.z.string()),u=e.z.object({type_names:e.z.array(e.z.tuple([e.z.number(),e.z.string()])),libfunc_names:e.z.array(e.z.tuple([e.z.number(),e.z.string()])),user_func_names:e.z.array(e.z.tuple([e.z.number(),e.z.string()]))}),a=e.z.object({selector:e.z.string(),function_idx:e.z.number()}),g=e.z.object({CONSTRUCTOR:e.z.array(a),EXTERNAL:e.z.array(a),L1_HANDLER:e.z.array(a)}),d=e.z.object({sierra_program:s,sierra_program_debug_info:u.optional(),contract_class_version:e.z.string(),entry_points_by_type:g,abi:o}),_=e.z.array(e.z.tuple([e.z.number(),e.z.array(e.z.string())])),E=e.z.object({prime:e.z.string(),compiler_version:e.z.string(),bytecode:s,hints:e.z.array(e.z.any()),pythonic_hints:_,entry_points_by_type:i}),j=E,v=e.z.union([p,d]);exports.abiEntrySchema=r;exports.abiSchema=o;exports.builtinsSchema=c;exports.byteCodeSchema=s;exports.cairo1EventSchema=b;exports.cairoAssemblySchema=E;exports.compiledContractClassSchema=v;exports.compiledSierraCasmSchema=j;exports.compiledSierraSchema=d;exports.compressedProgramSchema=C;exports.contractEntryPointFieldsSchema=t;exports.entryPointsByTypeSchema=i;exports.eventAbiSchema=h;exports.eventEntrySchema=n;exports.functionAbiSchema=y;exports.functionAbiTypeSchema=z;exports.legacyContractClassSchema=p;exports.legacyEventSchema=l;exports.programSchema=m;exports.pythonicHintsSchema=_;exports.sierraContractEntryPointFieldsSchema=a;exports.sierraEntryPointsByTypeSchema=g;exports.sierraProgramDebugInfoSchema=u;exports.structAbiSchema=S;
1
+ require(`../../../_virtual/_rolldown/runtime.cjs`);const e=require(`./starknetLibTypes.cjs`);let t=require(`zod`);var n=t.z.array(t.z.string()),r=t.z.object({selector:t.z.string(),offset:t.z.string(),builtins:n.optional()}),i=t.z.object({CONSTRUCTOR:t.z.array(r),EXTERNAL:t.z.array(r),L1_HANDLER:t.z.array(r)}),a=t.z.string(),o=t.z.object({builtins:n,data:t.z.array(t.z.string())}),s=t.z.object({name:t.z.string(),type:t.z.union([t.z.literal(`felt`),t.z.literal(`felt*`),t.z.string()])}),c=t.z.nativeEnum(e.FunctionAbiType),l=t.z.object({inputs:t.z.array(s),name:t.z.string(),outputs:t.z.array(s),stateMutability:t.z.literal(`view`).optional(),state_mutability:t.z.string().optional(),type:c}),u=t.z.object({name:t.z.string(),type:t.z.union([t.z.literal(`felt`),t.z.literal(`felt*`),t.z.string()]),kind:t.z.union([t.z.literal(`key`),t.z.literal(`data`)])}),d=t.z.object({name:t.z.string(),type:t.z.literal(`event`),data:t.z.array(u),keys:t.z.array(u)}),f=t.z.object({name:t.z.string(),members:t.z.array(u),kind:t.z.literal(`struct`),type:t.z.literal(`event`)}),p=t.z.object({members:t.z.array(s.and(t.z.object({offset:t.z.number()}))),name:t.z.string(),size:t.z.number(),type:t.z.literal(`struct`)}),m=t.z.union([f,d]),h=t.z.array(t.z.union([l,m,p,t.z.any()])),g=t.z.object({program:o,entry_points_by_type:i,abi:h}),_=t.z.array(t.z.string()),v=t.z.object({type_names:t.z.array(t.z.tuple([t.z.number(),t.z.string()])),libfunc_names:t.z.array(t.z.tuple([t.z.number(),t.z.string()])),user_func_names:t.z.array(t.z.tuple([t.z.number(),t.z.string()]))}),y=t.z.object({selector:t.z.string(),function_idx:t.z.number()}),b=t.z.object({CONSTRUCTOR:t.z.array(y),EXTERNAL:t.z.array(y),L1_HANDLER:t.z.array(y)}),x=t.z.object({sierra_program:_,sierra_program_debug_info:v.optional(),contract_class_version:t.z.string(),entry_points_by_type:b,abi:h}),S=t.z.array(t.z.tuple([t.z.number(),t.z.array(t.z.string())])),C=t.z.object({prime:t.z.string(),compiler_version:t.z.string(),bytecode:_,hints:t.z.array(t.z.any()),pythonic_hints:S,entry_points_by_type:i}),w=C,T=t.z.union([g,x]);exports.abiEntrySchema=s,exports.abiSchema=h,exports.builtinsSchema=n,exports.byteCodeSchema=_,exports.cairo1EventSchema=f,exports.cairoAssemblySchema=C,exports.compiledContractClassSchema=T,exports.compiledSierraCasmSchema=w,exports.compiledSierraSchema=x,exports.compressedProgramSchema=a,exports.contractEntryPointFieldsSchema=r,exports.entryPointsByTypeSchema=i,exports.eventAbiSchema=m,exports.eventEntrySchema=u,exports.functionAbiSchema=l,exports.functionAbiTypeSchema=c,exports.legacyContractClassSchema=g,exports.legacyEventSchema=d,exports.programSchema=o,exports.pythonicHintsSchema=S,exports.sierraContractEntryPointFieldsSchema=y,exports.sierraEntryPointsByTypeSchema=b,exports.sierraProgramDebugInfoSchema=v,exports.structAbiSchema=p;