@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.
- package/dist/.ts-temp/tsconfig.tsbuildinfo +1 -1
- package/dist/_virtual/_rolldown/runtime.cjs +1 -0
- package/dist/_virtual/_rolldown/runtime.js +20 -0
- package/dist/index.cjs +1 -1
- package/dist/index.js +112 -488
- package/dist/node_modules/.pnpm/@noble_curves@1.0.0/node_modules/@noble/curves/esm/_shortw_utils.cjs +1 -1
- package/dist/node_modules/.pnpm/@noble_curves@1.0.0/node_modules/@noble/curves/esm/_shortw_utils.js +11 -11
- package/dist/node_modules/.pnpm/@noble_curves@1.0.0/node_modules/@noble/curves/esm/abstract/curve.cjs +1 -1
- package/dist/node_modules/.pnpm/@noble_curves@1.0.0/node_modules/@noble/curves/esm/abstract/curve.js +62 -85
- package/dist/node_modules/.pnpm/@noble_curves@1.0.0/node_modules/@noble/curves/esm/abstract/modular.cjs +1 -1
- package/dist/node_modules/.pnpm/@noble_curves@1.0.0/node_modules/@noble/curves/esm/abstract/modular.js +153 -190
- package/dist/node_modules/.pnpm/@noble_curves@1.0.0/node_modules/@noble/curves/esm/abstract/poseidon.cjs +1 -1
- package/dist/node_modules/.pnpm/@noble_curves@1.0.0/node_modules/@noble/curves/esm/abstract/poseidon.js +56 -65
- package/dist/node_modules/.pnpm/@noble_curves@1.0.0/node_modules/@noble/curves/esm/abstract/utils.cjs +1 -1
- package/dist/node_modules/.pnpm/@noble_curves@1.0.0/node_modules/@noble/curves/esm/abstract/utils.js +125 -151
- package/dist/node_modules/.pnpm/@noble_curves@1.0.0/node_modules/@noble/curves/esm/abstract/weierstrass.cjs +1 -1
- package/dist/node_modules/.pnpm/@noble_curves@1.0.0/node_modules/@noble/curves/esm/abstract/weierstrass.js +470 -575
- package/dist/node_modules/.pnpm/@noble_hashes@1.3.0/node_modules/@noble/hashes/esm/_assert.cjs +1 -1
- package/dist/node_modules/.pnpm/@noble_hashes@1.3.0/node_modules/@noble/hashes/esm/_assert.js +26 -40
- package/dist/node_modules/.pnpm/@noble_hashes@1.3.0/node_modules/@noble/hashes/esm/crypto.cjs +1 -1
- package/dist/node_modules/.pnpm/@noble_hashes@1.3.0/node_modules/@noble/hashes/esm/crypto.js +4 -4
- package/dist/node_modules/.pnpm/@noble_hashes@1.3.0/node_modules/@noble/hashes/esm/hmac.cjs +1 -1
- package/dist/node_modules/.pnpm/@noble_hashes@1.3.0/node_modules/@noble/hashes/esm/hmac.js +38 -42
- package/dist/node_modules/.pnpm/@noble_hashes@1.3.0/node_modules/@noble/hashes/esm/utils.cjs +1 -1
- package/dist/node_modules/.pnpm/@noble_hashes@1.3.0/node_modules/@noble/hashes/esm/utils.js +28 -42
- package/dist/node_modules/.pnpm/@noble_hashes@1.3.3/node_modules/@noble/hashes/esm/_assert.cjs +1 -1
- package/dist/node_modules/.pnpm/@noble_hashes@1.3.3/node_modules/@noble/hashes/esm/_assert.js +17 -26
- package/dist/node_modules/.pnpm/@noble_hashes@1.3.3/node_modules/@noble/hashes/esm/_sha2.cjs +1 -1
- package/dist/node_modules/.pnpm/@noble_hashes@1.3.3/node_modules/@noble/hashes/esm/_sha2.js +52 -59
- package/dist/node_modules/.pnpm/@noble_hashes@1.3.3/node_modules/@noble/hashes/esm/_u64.cjs +1 -1
- package/dist/node_modules/.pnpm/@noble_hashes@1.3.3/node_modules/@noble/hashes/esm/_u64.js +20 -19
- package/dist/node_modules/.pnpm/@noble_hashes@1.3.3/node_modules/@noble/hashes/esm/sha256.cjs +1 -1
- package/dist/node_modules/.pnpm/@noble_hashes@1.3.3/node_modules/@noble/hashes/esm/sha256.js +118 -113
- package/dist/node_modules/.pnpm/@noble_hashes@1.3.3/node_modules/@noble/hashes/esm/sha3.cjs +1 -1
- package/dist/node_modules/.pnpm/@noble_hashes@1.3.3/node_modules/@noble/hashes/esm/sha3.js +95 -105
- package/dist/node_modules/.pnpm/@noble_hashes@1.3.3/node_modules/@noble/hashes/esm/utils.cjs +1 -1
- package/dist/node_modules/.pnpm/@noble_hashes@1.3.3/node_modules/@noble/hashes/esm/utils.js +26 -32
- package/dist/node_modules/.pnpm/@noble_hashes@2.0.0/node_modules/@noble/hashes/_md.cjs +1 -1
- package/dist/node_modules/.pnpm/@noble_hashes@2.0.0/node_modules/@noble/hashes/_md.js +71 -82
- package/dist/node_modules/.pnpm/@noble_hashes@2.0.0/node_modules/@noble/hashes/_u64.cjs +1 -1
- package/dist/node_modules/.pnpm/@noble_hashes@2.0.0/node_modules/@noble/hashes/_u64.js +20 -20
- package/dist/node_modules/.pnpm/@noble_hashes@2.0.0/node_modules/@noble/hashes/sha2.cjs +1 -1
- package/dist/node_modules/.pnpm/@noble_hashes@2.0.0/node_modules/@noble/hashes/sha2.js +125 -124
- package/dist/node_modules/.pnpm/@noble_hashes@2.0.0/node_modules/@noble/hashes/sha3.cjs +1 -1
- package/dist/node_modules/.pnpm/@noble_hashes@2.0.0/node_modules/@noble/hashes/sha3.js +102 -116
- package/dist/node_modules/.pnpm/@noble_hashes@2.0.0/node_modules/@noble/hashes/utils.cjs +1 -1
- package/dist/node_modules/.pnpm/@noble_hashes@2.0.0/node_modules/@noble/hashes/utils.js +62 -76
- package/dist/node_modules/.pnpm/bignumber.js@9.1.2/node_modules/bignumber.js/bignumber.cjs +1 -1
- package/dist/node_modules/.pnpm/bignumber.js@9.1.2/node_modules/bignumber.js/bignumber.js +519 -614
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_Hash.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_Hash.js +15 -19
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_ListCache.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_ListCache.js +15 -19
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_Map.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_Map.js +6 -6
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_MapCache.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_MapCache.js +15 -19
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_Set.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_Set.js +5 -5
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_SetCache.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_SetCache.js +10 -12
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_Symbol.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_Symbol.js +5 -5
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_arrayIncludes.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_arrayIncludes.js +6 -7
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_arrayIncludesWith.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_arrayIncludesWith.js +6 -8
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_assocIndexOf.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_assocIndexOf.js +7 -9
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_baseFindIndex.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_baseFindIndex.js +6 -8
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_baseGetTag.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_baseGetTag.js +9 -9
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_baseIndexOf.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_baseIndexOf.js +7 -7
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_baseIsNaN.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_baseIsNaN.js +5 -5
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_baseIsNative.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_baseIsNative.js +10 -15
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_baseUniq.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_baseUniq.js +26 -32
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_cacheHas.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_cacheHas.js +5 -5
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_coreJsData.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_coreJsData.js +5 -5
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_createSet.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_createSet.js +7 -7
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_freeGlobal.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_freeGlobal.js +4 -4
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_getMapData.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_getMapData.js +6 -6
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_getNative.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_getNative.js +8 -8
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_getRawTag.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_getRawTag.js +12 -13
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_getValue.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_getValue.js +5 -5
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_hashClear.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_hashClear.js +6 -6
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_hashDelete.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_hashDelete.js +6 -6
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_hashGet.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_hashGet.js +11 -11
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_hashHas.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_hashHas.js +8 -8
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_hashSet.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_hashSet.js +7 -7
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_isKeyable.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_isKeyable.js +6 -6
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_isMasked.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_isMasked.js +9 -9
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_listCacheClear.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_listCacheClear.js +5 -5
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_listCacheDelete.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_listCacheDelete.js +8 -11
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_listCacheGet.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_listCacheGet.js +7 -7
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_listCacheHas.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_listCacheHas.js +6 -6
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_listCacheSet.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_listCacheSet.js +6 -6
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_mapCacheClear.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_mapCacheClear.js +11 -11
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_mapCacheDelete.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_mapCacheDelete.js +7 -7
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_mapCacheGet.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_mapCacheGet.js +6 -6
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_mapCacheHas.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_mapCacheHas.js +6 -6
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_mapCacheSet.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_mapCacheSet.js +7 -7
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_nativeCreate.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_nativeCreate.js +4 -4
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_objectToString.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_objectToString.js +6 -6
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_root.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_root.js +4 -4
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_setCacheAdd.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_setCacheAdd.js +6 -6
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_setCacheHas.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_setCacheHas.js +5 -5
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_setToArray.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_setToArray.js +8 -8
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_strictIndexOf.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_strictIndexOf.js +6 -8
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_toSource.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/_toSource.js +14 -16
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/eq.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/eq.js +5 -5
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/isFunction.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/isFunction.js +10 -11
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/isObject.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/isObject.js +6 -6
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/noop.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/noop.js +4 -5
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/uniqWith.cjs +1 -1
- package/dist/node_modules/.pnpm/lodash-es@4.17.21/node_modules/lodash-es/uniqWith.js +6 -6
- package/dist/node_modules/.pnpm/micro-starknet@0.2.3/node_modules/micro-starknet/lib/esm/index.cjs +1 -1
- package/dist/node_modules/.pnpm/micro-starknet@0.2.3/node_modules/micro-starknet/lib/esm/index.js +121 -118
- package/dist/node_modules/.pnpm/numeral@2.0.6/node_modules/numeral/numeral.cjs +1 -1
- package/dist/node_modules/.pnpm/numeral@2.0.6/node_modules/numeral/numeral.js +377 -417
- package/dist/node_modules/.pnpm/semver@6.3.1/node_modules/semver/semver.cjs +1 -1
- package/dist/node_modules/.pnpm/semver@6.3.1/node_modules/semver/semver.js +546 -635
- package/dist/paymaster.cjs +1 -1
- package/dist/paymaster.js +2 -11
- package/dist/simulation.cjs +1 -1
- package/dist/simulation.js +22 -90
- package/dist/src/account/account.model.cjs +1 -1
- package/dist/src/account/account.model.js +58 -52
- package/dist/src/account/accountv4.cjs +1 -1
- package/dist/src/account/accountv4.js +9 -11
- package/dist/src/account/preferences.model.cjs +1 -1
- package/dist/src/account/preferences.model.js +12 -10
- package/dist/src/accountNameGenerator/colors.cjs +1 -1
- package/dist/src/accountNameGenerator/colors.js +24 -24
- package/dist/src/accountNameGenerator/index.cjs +1 -1
- package/dist/src/accountNameGenerator/index.js +23 -23
- package/dist/src/accountNameGenerator/x-names.json.cjs +1 -1
- package/dist/src/accountNameGenerator/x-names.json.js +1922 -7
- package/dist/src/assets/tokens.json.cjs +1 -1
- package/dist/src/assets/tokens.json.js +180 -180
- package/dist/src/backend/schema.cjs +1 -1
- package/dist/src/backend/schema.js +9 -12
- package/dist/src/backend/sessionKeys/schema.cjs +1 -1
- package/dist/src/backend/sessionKeys/schema.js +27 -30
- package/dist/src/bigdecimal/constants.cjs +1 -1
- package/dist/src/bigdecimal/constants.js +6 -3
- package/dist/src/bigdecimal/createUnitsSchema.cjs +1 -1
- package/dist/src/bigdecimal/createUnitsSchema.js +7 -7
- package/dist/src/bigdecimal/formatUnits.cjs +1 -1
- package/dist/src/bigdecimal/formatUnits.js +9 -10
- package/dist/src/bigdecimal/index.cjs +1 -1
- package/dist/src/bigdecimal/index.js +45 -41
- package/dist/src/bigdecimal/lib.cjs +1 -1
- package/dist/src/bigdecimal/lib.js +105 -117
- package/dist/src/bigdecimal/parseUnits.cjs +1 -1
- package/dist/src/bigdecimal/parseUnits.js +18 -21
- package/dist/src/bigdecimal/utils.cjs +1 -1
- package/dist/src/bigdecimal/utils.js +33 -30
- package/dist/src/cache/CacheService.cjs +1 -1
- package/dist/src/cache/CacheService.js +32 -36
- package/dist/src/chains/starknet/address.cjs +1 -1
- package/dist/src/chains/starknet/address.js +73 -117
- package/dist/src/chains/starknet/addressDomain.cjs +1 -1
- package/dist/src/chains/starknet/addressDomain.js +14 -29
- package/dist/src/chains/starknet/addressInput.cjs +1 -1
- package/dist/src/chains/starknet/addressInput.js +6 -7
- package/dist/src/chains/starknet/argentName.cjs +1 -1
- package/dist/src/chains/starknet/argentName.js +10 -14
- package/dist/src/chains/starknet/cairoVersionSchema.cjs +1 -1
- package/dist/src/chains/starknet/cairoVersionSchema.js +5 -5
- package/dist/src/chains/starknet/constants.cjs +1 -1
- package/dist/src/chains/starknet/constants.js +4 -10
- package/dist/src/chains/starknet/getAddressFromArgentName.cjs +1 -1
- package/dist/src/chains/starknet/getAddressFromArgentName.js +38 -46
- package/dist/src/chains/starknet/getAddressFromStarkName.cjs +1 -1
- package/dist/src/chains/starknet/getAddressFromStarkName.js +59 -66
- package/dist/src/chains/starknet/network.cjs +1 -1
- package/dist/src/chains/starknet/network.js +20 -26
- package/dist/src/chains/starknet/services/address/StarknetAddressService.cjs +1 -1
- package/dist/src/chains/starknet/services/address/StarknetAddressService.js +31 -36
- package/dist/src/chains/starknet/services/deploymentData/constants.cjs +1 -1
- package/dist/src/chains/starknet/services/deploymentData/constants.js +14 -21
- package/dist/src/chains/starknet/services/deploymentData/deploymentData.schema.cjs +1 -1
- package/dist/src/chains/starknet/services/deploymentData/deploymentData.schema.js +15 -17
- package/dist/src/chains/starknet/services/deploymentData/findImplementationForAccount.cjs +1 -1
- package/dist/src/chains/starknet/services/deploymentData/findImplementationForAccount.js +61 -65
- package/dist/src/chains/starknet/services/deploymentData/getAccountClassHash.cjs +1 -1
- package/dist/src/chains/starknet/services/deploymentData/getAccountClassHash.js +46 -65
- package/dist/src/chains/starknet/starknetId.cjs +1 -1
- package/dist/src/chains/starknet/starknetId.js +10 -14
- package/dist/src/currencyFetchService/CurrencyFetchService.cjs +1 -1
- package/dist/src/currencyFetchService/CurrencyFetchService.js +13 -18
- package/dist/src/currencyFetchService/types.ts.cjs +1 -1
- package/dist/src/currencyFetchService/types.ts.js +9 -12
- package/dist/src/errors/account.cjs +1 -1
- package/dist/src/errors/account.js +12 -13
- package/dist/src/errors/address.cjs +1 -1
- package/dist/src/errors/address.js +11 -12
- package/dist/src/errors/baseErrors.cjs +1 -1
- package/dist/src/errors/baseErrors.js +14 -14
- package/dist/src/errors/call.cjs +1 -1
- package/dist/src/errors/call.js +12 -13
- package/dist/src/errors/network.cjs +1 -1
- package/dist/src/errors/network.js +11 -12
- package/dist/src/errors/review.cjs +1 -1
- package/dist/src/errors/review.js +11 -12
- package/dist/src/errors/swap.cjs +1 -1
- package/dist/src/errors/swap.js +12 -13
- package/dist/src/features/paymaster/PaymasterService.cjs +1 -1
- package/dist/src/features/paymaster/PaymasterService.js +73 -87
- package/dist/src/features/paymaster/types.cjs +1 -1
- package/dist/src/features/paymaster/types.js +41 -51
- package/dist/src/features/simulation/activity/normalize.cjs +1 -1
- package/dist/src/features/simulation/activity/normalize.js +36 -38
- package/dist/src/features/simulation/activity/schema.cjs +1 -1
- package/dist/src/features/simulation/activity/schema.js +224 -250
- package/dist/src/features/simulation/activity/utils/createNativeActivity.cjs +1 -1
- package/dist/src/features/simulation/activity/utils/createNativeActivity.js +23 -27
- package/dist/src/features/simulation/activity/utils/getAnyActivityTitle.cjs +1 -1
- package/dist/src/features/simulation/activity/utils/getAnyActivityTitle.js +14 -21
- package/dist/src/features/simulation/activity/utils/getOverallLastModified.cjs +1 -1
- package/dist/src/features/simulation/activity/utils/getOverallLastModified.js +5 -5
- package/dist/src/features/simulation/activity/utils/hasDelegationActivity.cjs +1 -1
- package/dist/src/features/simulation/activity/utils/hasDelegationActivity.js +4 -4
- package/dist/src/features/simulation/activity/utils/isAddMultisigSignersActivity.cjs +1 -1
- package/dist/src/features/simulation/activity/utils/isAddMultisigSignersActivity.js +15 -19
- package/dist/src/features/simulation/activity/utils/isChangeMultisigThresholdActivity.cjs +1 -1
- package/dist/src/features/simulation/activity/utils/isChangeMultisigThresholdActivity.js +15 -19
- package/dist/src/features/simulation/activity/utils/isMulticallWithDeploymentActivity.cjs +1 -1
- package/dist/src/features/simulation/activity/utils/isMulticallWithDeploymentActivity.js +5 -5
- package/dist/src/features/simulation/activity/utils/isRejectOnChainActivity.cjs +1 -1
- package/dist/src/features/simulation/activity/utils/isRejectOnChainActivity.js +19 -21
- package/dist/src/features/simulation/activity/utils/isRemoveMultisigSignersActivity.cjs +1 -1
- package/dist/src/features/simulation/activity/utils/isRemoveMultisigSignersActivity.js +15 -19
- package/dist/src/features/simulation/activity/utils/isSwapActivity.cjs +1 -1
- package/dist/src/features/simulation/activity/utils/isSwapActivity.js +17 -18
- package/dist/src/features/simulation/activity/utils/isUpgradeActivity.cjs +1 -1
- package/dist/src/features/simulation/activity/utils/isUpgradeActivity.js +15 -19
- package/dist/src/features/simulation/activity/utils/parseAccountActivities.cjs +1 -1
- package/dist/src/features/simulation/activity/utils/parseAccountActivities.js +12 -12
- package/dist/src/features/simulation/activity/utils/parseFinanceActivities.cjs +1 -1
- package/dist/src/features/simulation/activity/utils/parseFinanceActivities.js +32 -32
- package/dist/src/features/simulation/fees/schema.cjs +1 -1
- package/dist/src/features/simulation/fees/schema.js +33 -47
- package/dist/src/features/simulation/transactionReview/getErrorMessageAndLabelFromSimulation.cjs +1 -1
- package/dist/src/features/simulation/transactionReview/getErrorMessageAndLabelFromSimulation.js +15 -17
- package/dist/src/features/simulation/transactionReview/getMessageFromSimulationError.cjs +1 -1
- package/dist/src/features/simulation/transactionReview/getMessageFromSimulationError.js +5 -5
- package/dist/src/features/simulation/transactionReview/schema.cjs +1 -1
- package/dist/src/features/simulation/transactionReview/schema.js +221 -242
- package/dist/src/features/simulation/warning/helper.cjs +1 -1
- package/dist/src/features/simulation/warning/helper.js +12 -11
- package/dist/src/features/simulation/warning/schema.cjs +1 -1
- package/dist/src/features/simulation/warning/schema.js +10 -11
- package/dist/src/features/swap/models/order.model.cjs +1 -1
- package/dist/src/features/swap/models/order.model.js +16 -19
- package/dist/src/features/swap/models/quote.model.cjs +1 -1
- package/dist/src/features/swap/models/quote.model.js +31 -35
- package/dist/src/features/swap/models/trade.model.cjs +1 -1
- package/dist/src/features/swap/models/trade.model.js +25 -27
- package/dist/src/features/swap/services/SwapSharedService.cjs +1 -1
- package/dist/src/features/swap/services/SwapSharedService.js +71 -75
- package/dist/src/features/swap/services/SwapTransactionService.cjs +1 -1
- package/dist/src/features/swap/services/SwapTransactionService.js +57 -63
- package/dist/src/features/swap/utils/slippage.cjs +1 -1
- package/dist/src/features/swap/utils/slippage.js +18 -25
- package/dist/src/features/swap/utils/totalFee.cjs +1 -1
- package/dist/src/features/swap/utils/totalFee.js +12 -12
- package/dist/src/http/DateService.cjs +1 -1
- package/dist/src/http/DateService.js +15 -18
- package/dist/src/http/HttpError.cjs +1 -1
- package/dist/src/http/HttpError.js +7 -7
- package/dist/src/http/HttpService.cjs +1 -1
- package/dist/src/http/HttpService.js +117 -134
- package/dist/src/http/IHttpService.cjs +1 -1
- package/dist/src/http/IHttpService.js +6 -6
- package/dist/src/http/SWRService.cjs +1 -1
- package/dist/src/http/SWRService.js +50 -57
- package/dist/src/http/fetcher.cjs +1 -1
- package/dist/src/http/fetcher.js +29 -35
- package/dist/src/http/time.cjs +1 -1
- package/dist/src/http/time.js +15 -18
- package/dist/src/knownDapps/KnownDappsBackendService.cjs +1 -1
- package/dist/src/knownDapps/KnownDappsBackendService.js +13 -14
- package/dist/src/knownDapps/schema.cjs +1 -1
- package/dist/src/knownDapps/schema.js +41 -44
- package/dist/src/knownDapps/utils/getDapplandUrl.cjs +1 -1
- package/dist/src/knownDapps/utils/getDapplandUrl.js +7 -8
- package/dist/src/nameResolution/ResolveNameService.cjs +1 -1
- package/dist/src/nameResolution/ResolveNameService.js +34 -41
- package/dist/src/nameResolution/schema.cjs +1 -1
- package/dist/src/nameResolution/schema.js +20 -25
- package/dist/src/nfts/BackendNftService.cjs +1 -1
- package/dist/src/nfts/BackendNftService.js +103 -116
- package/dist/src/nfts/BackendPaginationError.cjs +1 -1
- package/dist/src/nfts/BackendPaginationError.js +11 -12
- package/dist/src/nfts/utils.cjs +1 -1
- package/dist/src/nfts/utils.js +11 -14
- package/dist/src/onchainRecovery/OnchainRecoveryService.cjs +1 -1
- package/dist/src/onchainRecovery/OnchainRecoveryService.js +38 -68
- package/dist/src/onchainRecovery/schema.cjs +1 -1
- package/dist/src/onchainRecovery/schema.js +35 -49
- package/dist/src/platform/isBraveBrowser.cjs +1 -1
- package/dist/src/platform/isBraveBrowser.js +8 -10
- package/dist/src/platform/isBrowser.cjs +1 -1
- package/dist/src/platform/isBrowser.js +17 -22
- package/dist/src/signer/mergeOwnerGuardianSignatures.cjs +1 -1
- package/dist/src/signer/mergeOwnerGuardianSignatures.js +28 -30
- package/dist/src/signer/multisigner.cjs +1 -1
- package/dist/src/signer/multisigner.js +16 -17
- package/dist/src/signer/seedphrase.cjs +1 -1
- package/dist/src/signer/seedphrase.js +7 -7
- package/dist/src/staking/schema.cjs +1 -1
- package/dist/src/staking/schema.js +146 -162
- package/dist/src/storage/base.cjs +1 -1
- package/dist/src/storage/base.js +33 -34
- package/dist/src/storage/utils.cjs +1 -1
- package/dist/src/storage/utils.js +19 -28
- package/dist/src/tokens/balances.cjs +1 -1
- package/dist/src/tokens/balances.js +34 -38
- package/dist/src/tokens/constants.cjs +1 -1
- package/dist/src/tokens/constants.js +4 -4
- package/dist/src/tokens/convertCurrencyValueToTokenAmount.cjs +1 -1
- package/dist/src/tokens/convertCurrencyValueToTokenAmount.js +8 -9
- package/dist/src/tokens/convertTokenAmountToCurrencyValue.cjs +1 -1
- package/dist/src/tokens/convertTokenAmountToCurrencyValue.js +14 -15
- package/dist/src/tokens/convertTokenUnitAmountWithDecimals.cjs +1 -1
- package/dist/src/tokens/convertTokenUnitAmountWithDecimals.js +8 -9
- package/dist/src/tokens/ensureDecimals.cjs +1 -1
- package/dist/src/tokens/ensureDecimals.js +4 -4
- package/dist/src/tokens/getCurrencySymbol.cjs +1 -1
- package/dist/src/tokens/getCurrencySymbol.js +14 -14
- package/dist/src/tokens/isUnlimitedAmount.cjs +1 -1
- package/dist/src/tokens/isUnlimitedAmount.js +5 -5
- package/dist/src/tokens/prettifyCurrencyValue.cjs +1 -1
- package/dist/src/tokens/prettifyCurrencyValue.js +13 -14
- package/dist/src/tokens/prettifyTokenAmount.cjs +1 -1
- package/dist/src/tokens/prettifyTokenAmount.js +22 -22
- package/dist/src/tokens/service/implementation.cjs +1 -1
- package/dist/src/tokens/service/implementation.js +28 -40
- package/dist/src/tokens/service/tokenError.cjs +1 -1
- package/dist/src/tokens/service/tokenError.js +11 -12
- package/dist/src/tokens/service/types/backend.model.cjs +1 -1
- package/dist/src/tokens/service/types/backend.model.js +128 -163
- package/dist/src/tokens/service/types/defiPosition.model.cjs +1 -1
- package/dist/src/tokens/service/types/defiPosition.model.js +83 -99
- package/dist/src/tokens/service/types/defiPositionType.model.cjs +1 -1
- package/dist/src/tokens/service/types/defiPositionType.model.js +9 -9
- package/dist/src/tokens/service/types/unclaimedRewards.model.cjs +1 -1
- package/dist/src/tokens/service/types/unclaimedRewards.model.js +15 -16
- package/dist/src/tokens/service/types/webToken.model.cjs +1 -1
- package/dist/src/tokens/service/types/webToken.model.js +28 -51
- package/dist/src/tokens/utils.cjs +1 -1
- package/dist/src/tokens/utils.js +5 -9
- package/dist/src/transactions/amount.cjs +1 -1
- package/dist/src/transactions/amount.js +17 -24
- package/dist/src/transactions/buildTransactions.cjs +1 -1
- package/dist/src/transactions/buildTransactions.js +30 -33
- package/dist/src/transactions/errors.cjs +1 -1
- package/dist/src/transactions/errors.js +11 -18
- package/dist/src/transactions/estimate/adjustment.cjs +1 -1
- package/dist/src/transactions/estimate/adjustment.js +6 -6
- package/dist/src/transactions/estimate/argentMaxFee.cjs +1 -1
- package/dist/src/transactions/estimate/argentMaxFee.js +10 -13
- package/dist/src/transactions/estimate/error.cjs +1 -1
- package/dist/src/transactions/estimate/error.js +12 -13
- package/dist/src/transactions/estimate/model.cjs +1 -1
- package/dist/src/transactions/estimate/model.js +18 -13
- package/dist/src/transactions/estimate/utils.cjs +1 -1
- package/dist/src/transactions/estimate/utils.js +139 -172
- package/dist/src/transactions/findTransfersAndApprovals.cjs +1 -1
- package/dist/src/transactions/findTransfersAndApprovals.js +34 -30
- package/dist/src/transactions/getPrettyRcpError.cjs +1 -1
- package/dist/src/transactions/getPrettyRcpError.js +8 -10
- package/dist/src/transactions/service/implementation.cjs +1 -1
- package/dist/src/transactions/service/implementation.js +187 -208
- package/dist/src/transactions/service/types.cjs +1 -1
- package/dist/src/transactions/service/types.js +9 -9
- package/dist/src/transactions/service/utils.cjs +1 -1
- package/dist/src/transactions/service/utils.js +24 -25
- package/dist/src/transactions/transactionExecuteTypes.cjs +1 -1
- package/dist/src/transactions/transactionExecuteTypes.js +8 -9
- package/dist/src/transactions/transactionReviewTypes.cjs +1 -1
- package/dist/src/transactions/transactionReviewTypes.js +9 -9
- package/dist/src/transactions/transactionVersion.cjs +1 -1
- package/dist/src/transactions/transactionVersion.js +8 -13
- package/dist/src/transactions/txv3.cjs +1 -1
- package/dist/src/transactions/txv3.js +10 -11
- package/dist/src/utils/address.cjs +1 -1
- package/dist/src/utils/address.js +4 -4
- package/dist/src/utils/arrays.cjs +1 -1
- package/dist/src/utils/arrays.js +4 -4
- package/dist/src/utils/avatarImage.cjs +4 -4
- package/dist/src/utils/avatarImage.js +35 -40
- package/dist/src/utils/base58.cjs +1 -1
- package/dist/src/utils/base58.js +12 -15
- package/dist/src/utils/bigNumber.cjs +1 -1
- package/dist/src/utils/bigNumber.d.ts +1 -1
- package/dist/src/utils/bigNumber.js +5 -7
- package/dist/src/utils/bips.cjs +1 -1
- package/dist/src/utils/bips.js +12 -10
- package/dist/src/utils/daysBetween.cjs +1 -1
- package/dist/src/utils/daysBetween.js +6 -6
- package/dist/src/utils/env.cjs +1 -1
- package/dist/src/utils/env.js +4 -4
- package/dist/src/utils/hex.cjs +1 -1
- package/dist/src/utils/hex.js +7 -8
- package/dist/src/utils/id.cjs +1 -1
- package/dist/src/utils/id.js +7 -7
- package/dist/src/utils/initials.cjs +1 -1
- package/dist/src/utils/initials.js +12 -15
- package/dist/src/utils/isContractDeployed.cjs +1 -1
- package/dist/src/utils/isContractDeployed.js +9 -9
- package/dist/src/utils/nonNullable.cjs +1 -1
- package/dist/src/utils/nonNullable.js +6 -6
- package/dist/src/utils/number/abbreviateNumber.cjs +1 -1
- package/dist/src/utils/number/abbreviateNumber.js +13 -14
- package/dist/src/utils/number/isAllowedAddressHexInputValue.cjs +1 -1
- package/dist/src/utils/number/isAllowedAddressHexInputValue.js +4 -7
- package/dist/src/utils/number/isAllowedNumericInputValue.cjs +1 -1
- package/dist/src/utils/number/isAllowedNumericInputValue.js +5 -5
- package/dist/src/utils/number/isNumeric.cjs +1 -1
- package/dist/src/utils/number/isNumeric.js +4 -4
- package/dist/src/utils/number/prettifyNumber.cjs +1 -1
- package/dist/src/utils/number/prettifyNumber.js +65 -75
- package/dist/src/utils/parseAmount.cjs +1 -1
- package/dist/src/utils/parseAmount.js +10 -11
- package/dist/src/utils/pluralise.cjs +1 -1
- package/dist/src/utils/pluralise.js +4 -4
- package/dist/src/utils/readFileAsString.cjs +1 -1
- package/dist/src/utils/readFileAsString.js +6 -6
- package/dist/src/utils/retryUntilInitialised.cjs +1 -1
- package/dist/src/utils/retryUntilInitialised.js +21 -20
- package/dist/src/utils/schemas.cjs +1 -1
- package/dist/src/utils/schemas.js +29 -26
- package/dist/src/utils/starknet/starknet.cjs +1 -1
- package/dist/src/utils/starknet/starknet.js +64 -77
- package/dist/src/utils/starknet/starknetLibTypes.cjs +1 -1
- package/dist/src/utils/starknet/starknetLibTypes.js +7 -7
- package/dist/src/utils/starknet/starknetSchemas.cjs +1 -1
- package/dist/src/utils/starknet/starknetSchemas.js +84 -99
- package/dist/src/utils/transactions.cjs +1 -1
- package/dist/src/utils/transactions.js +10 -10
- package/dist/src/utils/url/urlWithQuery.cjs +1 -1
- package/dist/src/utils/url/urlWithQuery.js +8 -8
- package/dist/src/utils/voidify.cjs +1 -1
- package/dist/src/utils/voidify.js +7 -7
- package/dist/swap.cjs +1 -1
- package/dist/swap.js +8 -22
- package/package.json +20 -19
- package/dist/.eslintrc.d.cts +0 -39
- package/dist/_virtual/_commonjsHelpers.cjs +0 -1
- package/dist/_virtual/_commonjsHelpers.js +0 -6
- package/dist/_virtual/numeral.cjs +0 -1
- package/dist/_virtual/numeral.js +0 -7
- package/dist/_virtual/numeral2.cjs +0 -1
- package/dist/_virtual/numeral2.js +0 -4
- package/dist/_virtual/semver.cjs +0 -1
- package/dist/_virtual/semver.js +0 -7
- package/dist/_virtual/semver2.cjs +0 -1
- package/dist/_virtual/semver2.js +0 -4
|
@@ -1,163 +1,147 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { callSchema as
|
|
3
|
-
import {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
stakingAction: d,
|
|
146
|
-
stakerInfo: o,
|
|
147
|
-
tokenAddress: s,
|
|
148
|
-
amount: e.string(),
|
|
149
|
-
...g.shape
|
|
1
|
+
import { addressSchema as e, addressSchemaArgentBackend as t } from "../chains/starknet/address.js";
|
|
2
|
+
import { callSchema as n } from "../utils/starknet/starknet.js";
|
|
3
|
+
import { z as r } from "zod";
|
|
4
|
+
//#region src/staking/schema.ts
|
|
5
|
+
var i = r.object({
|
|
6
|
+
id: r.string(),
|
|
7
|
+
dappId: r.string(),
|
|
8
|
+
productId: r.string(),
|
|
9
|
+
productName: r.string(),
|
|
10
|
+
chain: r.string(),
|
|
11
|
+
name: r.string(),
|
|
12
|
+
description: r.string(),
|
|
13
|
+
iconUrl: r.string().url(),
|
|
14
|
+
learnMoreUrl: r.string().url().optional(),
|
|
15
|
+
riskFactor: r.enum(["low"]),
|
|
16
|
+
metrics: r.object({
|
|
17
|
+
baseApy: r.string(),
|
|
18
|
+
totalApy: r.string(),
|
|
19
|
+
tvl: r.string().optional()
|
|
20
|
+
}),
|
|
21
|
+
incentives: r.array(r.object({
|
|
22
|
+
name: r.string(),
|
|
23
|
+
description: r.string(),
|
|
24
|
+
iconUrl: r.string().url(),
|
|
25
|
+
learnMoreUrl: r.string().url(),
|
|
26
|
+
metric: r.object({ apy: r.string() })
|
|
27
|
+
})),
|
|
28
|
+
buyEnabled: r.boolean(),
|
|
29
|
+
sellEnabled: r.boolean()
|
|
30
|
+
}), a = i.extend({
|
|
31
|
+
category: r.literal("staking"),
|
|
32
|
+
investableAssets: r.object({
|
|
33
|
+
tokenAddresses: r.array(t),
|
|
34
|
+
tokensRequirement: r.enum(["any"])
|
|
35
|
+
}),
|
|
36
|
+
withdrawableAssets: r.object({
|
|
37
|
+
tokenAddresses: r.array(t),
|
|
38
|
+
tokensRequirement: r.enum(["any"])
|
|
39
|
+
}),
|
|
40
|
+
fees: r.object({
|
|
41
|
+
depositFees: r.object({
|
|
42
|
+
protocolFee: r.string().nullable().optional(),
|
|
43
|
+
totalFee: r.string()
|
|
44
|
+
}),
|
|
45
|
+
withdrawalFees: r.object({
|
|
46
|
+
protocolFee: r.string().nullable().optional(),
|
|
47
|
+
totalFee: r.string()
|
|
48
|
+
}),
|
|
49
|
+
performanceFees: r.object({
|
|
50
|
+
argentFee: r.string().nullable().optional(),
|
|
51
|
+
protocolFee: r.string().nullable().optional(),
|
|
52
|
+
providerFee: r.string().nullable().optional(),
|
|
53
|
+
totalFee: r.string()
|
|
54
|
+
}).optional()
|
|
55
|
+
})
|
|
56
|
+
}), o = i.extend({
|
|
57
|
+
category: r.literal("lending"),
|
|
58
|
+
investableAssets: r.object({
|
|
59
|
+
tokenAddresses: r.array(t),
|
|
60
|
+
tokensRequirement: r.enum(["any"])
|
|
61
|
+
}),
|
|
62
|
+
withdrawableAssets: r.object({
|
|
63
|
+
tokenAddresses: r.array(t),
|
|
64
|
+
tokensRequirement: r.enum(["any"])
|
|
65
|
+
}),
|
|
66
|
+
claimRewardsUrl: r.url().optional(),
|
|
67
|
+
externalUrl: r.url().optional(),
|
|
68
|
+
fees: r.object({
|
|
69
|
+
depositFees: r.object({ totalFee: r.string() }),
|
|
70
|
+
withdrawalFees: r.object({ totalFee: r.string() })
|
|
71
|
+
})
|
|
72
|
+
}), s = r.object({
|
|
73
|
+
name: r.string().optional(),
|
|
74
|
+
iconUrl: r.string().url().optional(),
|
|
75
|
+
address: r.string().optional()
|
|
76
|
+
}), c = i.extend({
|
|
77
|
+
category: r.literal("strkDelegatedStaking"),
|
|
78
|
+
stakerInfo: s,
|
|
79
|
+
investableAssets: r.object({
|
|
80
|
+
tokenAddresses: r.array(t),
|
|
81
|
+
tokensRequirement: r.enum(["any"]),
|
|
82
|
+
useDecomposedBalances: r.boolean().optional()
|
|
83
|
+
}),
|
|
84
|
+
withdrawableAssets: r.object({
|
|
85
|
+
tokenAddresses: r.array(t),
|
|
86
|
+
tokensRequirement: r.enum(["any"]),
|
|
87
|
+
useDecomposedBalances: r.boolean().optional(),
|
|
88
|
+
amountsRequirement: r.enum(["fullBalance"]).optional(),
|
|
89
|
+
timelockDuration: r.number().optional()
|
|
90
|
+
}),
|
|
91
|
+
fees: r.object({
|
|
92
|
+
depositFees: r.object({
|
|
93
|
+
argentFee: r.string().nullable().optional(),
|
|
94
|
+
protocolFee: r.string().nullable().optional(),
|
|
95
|
+
providerFee: r.string().nullable().optional(),
|
|
96
|
+
totalFee: r.string()
|
|
97
|
+
}),
|
|
98
|
+
withdrawalFees: r.object({
|
|
99
|
+
argentFee: r.string().nullable().optional(),
|
|
100
|
+
protocolFee: r.string().nullable().optional(),
|
|
101
|
+
providerFee: r.string().nullable().optional(),
|
|
102
|
+
totalFee: r.string()
|
|
103
|
+
}),
|
|
104
|
+
performanceFees: r.object({
|
|
105
|
+
argentFee: r.string().nullable().optional(),
|
|
106
|
+
protocolFee: r.string().nullable().optional(),
|
|
107
|
+
providerFee: r.string().nullable().optional(),
|
|
108
|
+
totalFee: r.string()
|
|
109
|
+
}).optional()
|
|
110
|
+
}),
|
|
111
|
+
buyEnabled: r.boolean().optional(),
|
|
112
|
+
sellEnabled: r.boolean().optional(),
|
|
113
|
+
claimEnabled: r.boolean().optional()
|
|
114
|
+
}), l = r.discriminatedUnion("category", [
|
|
115
|
+
a,
|
|
116
|
+
o,
|
|
117
|
+
c
|
|
118
|
+
]), u = r.object({ investments: r.array(l) }), d = r.object({ calls: r.array(n) }), f = r.object({
|
|
119
|
+
investmentId: r.string(),
|
|
120
|
+
investmentType: r.enum([
|
|
121
|
+
"staking",
|
|
122
|
+
"lending",
|
|
123
|
+
"strkDelegatedStaking"
|
|
124
|
+
]).optional(),
|
|
125
|
+
accountAddress: t,
|
|
126
|
+
tokenAddress: t,
|
|
127
|
+
stakerInfo: s,
|
|
128
|
+
amount: r.string()
|
|
129
|
+
}), p = r.enum([
|
|
130
|
+
"deposit",
|
|
131
|
+
"stake",
|
|
132
|
+
"initiateWithdraw",
|
|
133
|
+
"withdraw",
|
|
134
|
+
"claim"
|
|
135
|
+
]), m = r.object({
|
|
136
|
+
useFullBalance: r.boolean().optional(),
|
|
137
|
+
subsequentTransaction: r.boolean().optional()
|
|
138
|
+
}), h = r.object({
|
|
139
|
+
investmentId: r.string().optional(),
|
|
140
|
+
stakingAction: p,
|
|
141
|
+
stakerInfo: s,
|
|
142
|
+
tokenAddress: e,
|
|
143
|
+
amount: r.string(),
|
|
144
|
+
...m.shape
|
|
150
145
|
});
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
j as investmentMetaSchema,
|
|
154
|
-
c as investmentSchema,
|
|
155
|
-
u as investmentsResponseSchema,
|
|
156
|
-
r as lendingInvestmentSchema,
|
|
157
|
-
l as liquidStakingInvestmentSchema,
|
|
158
|
-
o as stakerInfoSchema,
|
|
159
|
-
d as stakingActionSchema,
|
|
160
|
-
i as strkDelegatedStakingInvestmentSchema,
|
|
161
|
-
k as strkStakingCalldataResponseSchema,
|
|
162
|
-
F as strkStakingCalldataSchema
|
|
163
|
-
};
|
|
146
|
+
//#endregion
|
|
147
|
+
export { m as buildSellOptsSchema, h as investmentMetaSchema, l as investmentSchema, u as investmentsResponseSchema, o as lendingInvestmentSchema, a as liquidStakingInvestmentSchema, s as stakerInfoSchema, p as stakingActionSchema, c as strkDelegatedStakingInvestmentSchema, d as strkStakingCalldataResponseSchema, f as strkStakingCalldataSchema };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
require(`../../_virtual/_rolldown/runtime.cjs`);let e=require(`lodash-es`);function t(t){return{compareFn:e.isEqual,mergeFn:(e,t)=>t,...t}}function n(e,n={}){let{compareFn:r,mergeFn:i}=t(n);return e.reduce((e,t)=>e.some(e=>r(e,t))?e.map(e=>r(e,t)?i(e,t):e):[...e,t],[])}function r(e,r,i={}){let{compareFn:a,mergeFn:o}=t(i),s=i.insertMode??`push`,c=n(e,i);return r.reduce((e,t)=>{let n=e.findIndex(e=>a(e,t));return n===-1?s===`unshift`?[t,...e]:[...e,t]:[...e.slice(0,n),o(e[n],t),...e.slice(n+1)]},c)}function i(e){let t=e=>e;return{defaults:[],serialize:t,deserialize:t,compare:(e,t)=>e===t,merge:(e,t)=>t,...e}}exports.mergeArrayStableWith=r,exports.optionsWithDefaults=i;
|
package/dist/src/storage/base.js
CHANGED
|
@@ -1,38 +1,37 @@
|
|
|
1
|
-
import { isEqual as
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
1
|
+
import { isEqual as e } from "lodash-es";
|
|
2
|
+
//#region src/storage/base.ts
|
|
3
|
+
function t(t) {
|
|
4
|
+
return {
|
|
5
|
+
compareFn: e,
|
|
6
|
+
mergeFn: (e, t) => t,
|
|
7
|
+
...t
|
|
8
|
+
};
|
|
8
9
|
}
|
|
9
|
-
function
|
|
10
|
-
|
|
11
|
-
|
|
10
|
+
function n(e, n = {}) {
|
|
11
|
+
let { compareFn: r, mergeFn: i } = t(n);
|
|
12
|
+
return e.reduce((e, t) => e.some((e) => r(e, t)) ? e.map((e) => r(e, t) ? i(e, t) : e) : [...e, t], []);
|
|
12
13
|
}
|
|
13
|
-
function
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
14
|
+
function r(e, r, i = {}) {
|
|
15
|
+
let { compareFn: a, mergeFn: o } = t(i), s = i.insertMode ?? "push", c = n(e, i);
|
|
16
|
+
return r.reduce((e, t) => {
|
|
17
|
+
let n = e.findIndex((e) => a(e, t));
|
|
18
|
+
return n === -1 ? s === "unshift" ? [t, ...e] : [...e, t] : [
|
|
19
|
+
...e.slice(0, n),
|
|
20
|
+
o(e[n], t),
|
|
21
|
+
...e.slice(n + 1)
|
|
22
|
+
];
|
|
23
|
+
}, c);
|
|
23
24
|
}
|
|
24
|
-
function
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
25
|
+
function i(e) {
|
|
26
|
+
let t = (e) => e;
|
|
27
|
+
return {
|
|
28
|
+
defaults: [],
|
|
29
|
+
serialize: t,
|
|
30
|
+
deserialize: t,
|
|
31
|
+
compare: (e, t) => e === t,
|
|
32
|
+
merge: (e, t) => t,
|
|
33
|
+
...e
|
|
34
|
+
};
|
|
34
35
|
}
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
F as optionsWithDefaults
|
|
38
|
-
};
|
|
36
|
+
//#endregion
|
|
37
|
+
export { r as mergeArrayStableWith, i as optionsWithDefaults };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
function e(t,n,r,i){if(typeof t==`object`&&t)for(let a in t)typeof t[a]==`object`&&t[a]!==null?e(t[a],n,r,i):(!i||i.includes(a))&&t[a]===n&&(t[a]=r);else Array.isArray(t)&&t.forEach((a,o)=>{typeof a==`object`&&a?e(a,n,r,i):a===n&&(t[o]=r)})}function t(e,n){if(typeof e==`object`&&e){for(let r in e)if(typeof e[r]==`object`&&e[r]!==null){if(t(e[r],n))return!0}else if(e[r]===n)return!0}else if(Array.isArray(e)){for(let r of e)if(typeof r==`object`&&r){if(t(r,n))return!0}else if(r===n)return!0}return!1}exports.containsValue=t,exports.replaceValueRecursively=e;
|
|
@@ -1,30 +1,21 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
});
|
|
1
|
+
//#region src/storage/utils.ts
|
|
2
|
+
function e(t, n, r, i) {
|
|
3
|
+
if (typeof t == "object" && t) for (let a in t) typeof t[a] == "object" && t[a] !== null ? e(t[a], n, r, i) : (!i || i.includes(a)) && t[a] === n && (t[a] = r);
|
|
4
|
+
else Array.isArray(t) && t.forEach((a, o) => {
|
|
5
|
+
typeof a == "object" && a ? e(a, n, r, i) : a === n && (t[o] = r);
|
|
6
|
+
});
|
|
8
7
|
}
|
|
9
|
-
function
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
if (c(f, t))
|
|
21
|
-
return !0;
|
|
22
|
-
} else if (f === t)
|
|
23
|
-
return !0;
|
|
24
|
-
}
|
|
25
|
-
return !1;
|
|
8
|
+
function t(e, n) {
|
|
9
|
+
if (typeof e == "object" && e) {
|
|
10
|
+
for (let r in e) if (typeof e[r] == "object" && e[r] !== null) {
|
|
11
|
+
if (t(e[r], n)) return !0;
|
|
12
|
+
} else if (e[r] === n) return !0;
|
|
13
|
+
} else if (Array.isArray(e)) {
|
|
14
|
+
for (let r of e) if (typeof r == "object" && r) {
|
|
15
|
+
if (t(r, n)) return !0;
|
|
16
|
+
} else if (r === n) return !0;
|
|
17
|
+
}
|
|
18
|
+
return !1;
|
|
26
19
|
}
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
n as replaceValueRecursively
|
|
30
|
-
};
|
|
20
|
+
//#endregion
|
|
21
|
+
export { t as containsValue, e as replaceValueRecursively };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
require(`../../_virtual/_rolldown/runtime.cjs`);const e=require(`../assets/tokens.json.cjs`);let t=require(`lodash-es`),n=require(`starknet`);var r=async(e,t,r)=>{let i=await r.callContract({contractAddress:e,entrypoint:`balanceOf`,calldata:[t]});return BigInt(n.num.toHex(n.uint256.uint256ToBN({low:i[0],high:i[1]})))},i=async(r,i,a)=>{let o=e.default.filter(e=>e.networkId===r);return(await Promise.allSettled(o.map(e=>i.callContract({contractAddress:e.address,entrypoint:`balanceOf`,calldata:[a]})))).reduce((e,r,i)=>{if(r.status===`fulfilled`&&(0,t.isUndefined)(r.value)||r.status===`rejected`||r.value[0]===`0x0`&&r.value[1]===`0x0`)return e;let a=BigInt(n.num.toHex(n.uint256.uint256ToBN({low:r.value[0],high:r.value[1]}))),s={...o[i],balance:a};return e.push(s),e},[])},a=async()=>e.default,o=({address:t,networkId:n})=>e.default.find(e=>e.address===t&&e.networkId===n);exports.getTokenBalance=r,exports.getTokens=a,exports.getTokensBalances=i,exports.useToken=o;
|
|
@@ -1,38 +1,34 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
import r from "
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
},
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
B as getTokens,
|
|
36
|
-
w as getTokensBalances,
|
|
37
|
-
b as useToken
|
|
38
|
-
};
|
|
1
|
+
import e from "../assets/tokens.json.js";
|
|
2
|
+
import { isUndefined as t } from "lodash-es";
|
|
3
|
+
import { num as n, uint256 as r } from "starknet";
|
|
4
|
+
//#region src/tokens/balances.ts
|
|
5
|
+
var i = async (e, t, i) => {
|
|
6
|
+
let a = await i.callContract({
|
|
7
|
+
contractAddress: e,
|
|
8
|
+
entrypoint: "balanceOf",
|
|
9
|
+
calldata: [t]
|
|
10
|
+
});
|
|
11
|
+
return BigInt(n.toHex(r.uint256ToBN({
|
|
12
|
+
low: a[0],
|
|
13
|
+
high: a[1]
|
|
14
|
+
})));
|
|
15
|
+
}, a = async (i, a, o) => {
|
|
16
|
+
let s = e.filter((e) => e.networkId === i);
|
|
17
|
+
return (await Promise.allSettled(s.map((e) => a.callContract({
|
|
18
|
+
contractAddress: e.address,
|
|
19
|
+
entrypoint: "balanceOf",
|
|
20
|
+
calldata: [o]
|
|
21
|
+
})))).reduce((e, i, a) => {
|
|
22
|
+
if (i.status === "fulfilled" && t(i.value) || i.status === "rejected" || i.value[0] === "0x0" && i.value[1] === "0x0") return e;
|
|
23
|
+
let o = BigInt(n.toHex(r.uint256ToBN({
|
|
24
|
+
low: i.value[0],
|
|
25
|
+
high: i.value[1]
|
|
26
|
+
}))), c = {
|
|
27
|
+
...s[a],
|
|
28
|
+
balance: o
|
|
29
|
+
};
|
|
30
|
+
return e.push(c), e;
|
|
31
|
+
}, []);
|
|
32
|
+
}, o = async () => e, s = ({ address: t, networkId: n }) => e.find((e) => e.address === t && e.networkId === n);
|
|
33
|
+
//#endregion
|
|
34
|
+
export { i as getTokenBalance, o as getTokens, a as getTokensBalances, s as useToken };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
var e=18;exports.DEFAULT_TOKEN_DECIMALS=e;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
};
|
|
1
|
+
//#region src/tokens/constants.ts
|
|
2
|
+
var e = 18;
|
|
3
|
+
//#endregion
|
|
4
|
+
export { e as DEFAULT_TOKEN_DECIMALS };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
const e=require(`../bigdecimal/utils.cjs`),t=require(`../utils/number/isNumeric.cjs`);var n=({currencyValue:n,decimals:r,unitCurrencyValue:i})=>{if(!t.isNumeric(n)||!t.isNumeric(r)||!t.isNumeric(i))return;let a=Number(r),o=e.parseCurrency(n.toString()).value,s=e.parseCurrency(i.toString()).value;return o*BigInt(10**a)/s};exports.convertCurrencyValueToTokenAmount=n;
|
|
@@ -1,11 +1,10 @@
|
|
|
1
|
-
import { isNumeric as t } from "../utils/number/isNumeric.js";
|
|
2
1
|
import { parseCurrency as e } from "../bigdecimal/utils.js";
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
export {
|
|
10
|
-
a as convertCurrencyValueToTokenAmount
|
|
2
|
+
import { isNumeric as t } from "../utils/number/isNumeric.js";
|
|
3
|
+
//#region src/tokens/convertCurrencyValueToTokenAmount.ts
|
|
4
|
+
var n = ({ currencyValue: n, decimals: r, unitCurrencyValue: i }) => {
|
|
5
|
+
if (!t(n) || !t(r) || !t(i)) return;
|
|
6
|
+
let a = Number(r), o = e(n.toString()).value, s = e(i.toString()).value;
|
|
7
|
+
return o * BigInt(10 ** a) / s;
|
|
11
8
|
};
|
|
9
|
+
//#endregion
|
|
10
|
+
export { n as convertCurrencyValueToTokenAmount };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
require(`./constants.cjs`);const e=require(`../bigdecimal/formatUnits.cjs`),t=require(`../bigdecimal/utils.cjs`),n=require(`../utils/number/isNumeric.cjs`);var r=({amount:r,decimals:i,unitCurrencyValue:a})=>{if(!n.isNumeric(r)||!n.isNumeric(i)||!n.isNumeric(a))return;let o=Number(i),s=BigInt(r)*t.parseCurrency(a.toString()).value;return e.formatUnits({value:s,decimals:o+18})};exports.convertTokenAmountToCurrencyValue=r;
|
|
@@ -1,16 +1,15 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
import { parseCurrency as
|
|
4
|
-
import {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
};
|
|
14
|
-
export {
|
|
15
|
-
l as convertTokenAmountToCurrencyValue
|
|
1
|
+
import "./constants.js";
|
|
2
|
+
import { formatUnits as e } from "../bigdecimal/formatUnits.js";
|
|
3
|
+
import { parseCurrency as t } from "../bigdecimal/utils.js";
|
|
4
|
+
import { isNumeric as n } from "../utils/number/isNumeric.js";
|
|
5
|
+
//#region src/tokens/convertTokenAmountToCurrencyValue.ts
|
|
6
|
+
var r = ({ amount: r, decimals: i, unitCurrencyValue: a }) => {
|
|
7
|
+
if (!n(r) || !n(i) || !n(a)) return;
|
|
8
|
+
let o = Number(i);
|
|
9
|
+
return e({
|
|
10
|
+
value: BigInt(r) * t(a.toString()).value,
|
|
11
|
+
decimals: o + 18
|
|
12
|
+
});
|
|
16
13
|
};
|
|
14
|
+
//#endregion
|
|
15
|
+
export { r as convertTokenAmountToCurrencyValue };
|