@argent/x-shared 1.39.0 → 1.39.1
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/index.cjs +1 -1
- package/dist/index.js +267 -265
- package/dist/src/signer/index.d.ts +1 -0
- package/dist/src/signer/mergeOwnerGuardianSignatures.cjs +1 -0
- package/dist/src/signer/mergeOwnerGuardianSignatures.d.ts +26 -0
- package/dist/src/signer/mergeOwnerGuardianSignatures.js +30 -0
- package/dist/src/transactions/estimate/model.d.ts +2 -2
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const Z=require("./src/bigdecimal/index.cjs"),Q=require("./src/errors/baseErrors.cjs"),q=require("./src/account/account.model.cjs"),R=require("./src/account/accountv4.cjs"),_=require("./src/account/preferences.model.cjs"),A=require("./src/backend/schema.cjs"),J=require("./src/cache/CacheService.cjs"),n=require("./src/chains/starknet/address.cjs"),d=require("./src/chains/starknet/addressDomain.cjs"),w=require("./src/chains/starknet/addressInput.cjs"),p=require("./src/chains/starknet/argentName.cjs"),ee=require("./src/chains/starknet/cairoVersionSchema.cjs"),S=require("./src/chains/starknet/constants.cjs"),H=require("./src/chains/starknet/getAddressFromArgentName.cjs"),T=require("./src/chains/starknet/getAddressFromStarkName.cjs"),ae=require("./src/chains/starknet/network.cjs"),re=require("./src/chains/starknet/services/address/StarknetAddressService.cjs"),f=require("./src/chains/starknet/services/deploymentData/constants.cjs"),b=require("./src/chains/starknet/services/deploymentData/deploymentData.schema.cjs"),h=require("./src/chains/starknet/services/deploymentData/findImplementationForAccount.cjs"),i=require("./src/chains/starknet/services/deploymentData/getAccountClassHash.cjs"),g=require("./src/chains/starknet/starknetId.cjs"),te=require("./src/http/DateService.cjs"),ne=require("./src/http/HttpError.cjs"),se=require("./src/http/HttpService.cjs"),ce=require("./src/http/IHttpService.cjs"),oe=require("./src/http/SWRService.cjs"),N=require("./src/http/fetcher.cjs"),O=require("./src/http/time.cjs"),ie=require("./src/knownDapps/KnownDappsBackendService.cjs"),y=require("./src/knownDapps/schema.cjs"),L=require("./src/knownDapps/utils/getDapplandUrl.cjs"),me=require("./src/nameResolution/ResolveNameService.cjs"),l=require("./src/nameResolution/schema.cjs"),Se=require("./src/nfts/BackendNftService.cjs"),V=require("./src/nfts/utils.cjs"),de=require("./src/onchainRecovery/OnchainRecoveryService.cjs"),c=require("./src/onchainRecovery/schema.cjs"),le=require("./src/platform/isBraveBrowser.cjs"),u=require("./src/platform/isBrowser.cjs"),ue=require("./src/signer/seedphrase.cjs"),x=require("./src/signer/multisigner.cjs"),m=require("./src/staking/schema.cjs"),C=require("./src/tokens/balances.cjs"),he=require("./src/tokens/constants.cjs"),Ae=require("./src/tokens/convertTokenAmountToCurrencyValue.cjs"),pe=require("./src/tokens/convertTokenUnitAmountWithDecimals.cjs"),Te=require("./src/tokens/ensureDecimals.cjs"),ge=require("./src/tokens/isUnlimitedAmount.cjs"),ye=require("./src/tokens/prettifyCurrencyValue.cjs"),M=require("./src/tokens/prettifyTokenAmount.cjs"),Ce=require("./src/tokens/getCurrencySymbol.cjs"),ke=require("./src/tokens/service/implementation.cjs"),W=require("./src/tokens/service/tokenError.cjs"),a=require("./src/tokens/service/types/backend.model.cjs"),s=require("./src/tokens/service/types/defiPosition.model.cjs"),Ee=require("./src/tokens/service/types/defiPositionType.model.cjs"),U=require("./src/tokens/service/types/unclaimedRewards.model.cjs"),o=require("./src/tokens/service/types/webToken.model.cjs"),P=require("./src/transactions/amount.cjs"),F=require("./src/transactions/buildTransactions.cjs"),G=require("./src/transactions/errors.cjs"),I=require("./src/transactions/estimate/argentMaxFee.cjs"),z=require("./src/transactions/estimate/error.cjs"),De=require("./src/transactions/estimate/model.cjs"),t=require("./src/transactions/estimate/utils.cjs"),j=require("./src/transactions/findTransfersAndApprovals.cjs"),ve=require("./src/transactions/getPrettyRcpError.cjs"),B=require("./src/transactions/getTransactionVersion.cjs"),qe=require("./src/transactions/service/implementation.cjs"),Re=require("./src/transactions/service/types.cjs"),fe=require("./src/transactions/transactionReviewTypes.cjs"),K=require("./src/transactions/transactionVersion.cjs"),X=require("./src/transactions/txv3.cjs"),be=require("./src/utils/address.cjs"),Ne=require("./src/utils/arrays.cjs"),k=require("./src/utils/avatarImage.cjs"),E=require("./src/utils/base58.cjs"),Pe=require("./src/utils/bigNumber.cjs"),Fe=require("./src/utils/daysBetween.cjs"),Ie=require("./src/utils/env.cjs"),$=require("./src/utils/hex.cjs"),Be=require("./src/utils/id.cjs"),_e=require("./src/utils/initials.cjs"),we=require("./src/utils/isContractDeployed.cjs"),He=require("./src/utils/nonNullable.cjs"),Oe=require("./src/utils/number/isAllowedAddressHexInputValue.cjs"),Le=require("./src/utils/number/isAllowedNumericInputValue.cjs"),Ve=require("./src/utils/number/isNumeric.cjs"),D=require("./src/utils/number/prettifyNumber.cjs"),Y=require("./src/utils/parseAmount.cjs"),xe=require("./src/utils/pluralise.cjs"),Me=require("./src/utils/readFileAsString.cjs"),v=require("./src/utils/schemas.cjs"),r=require("./src/utils/starknet/starknet.cjs"),e=require("./src/utils/starknet/starknetSchemas.cjs"),We=require("./src/utils/transactions.cjs"),Ue=require("./src/utils/url/urlWithQuery.cjs"),Ge=require("./src/utils/voidify.cjs"),ze=require("./src/utils/bips.cjs");exports.bigDecimal=Z;exports.BaseError=Q.BaseError;exports.AddSmartAccountResponseSchema=q.AddSmartAccountResponseSchema;exports.AddSmartAcountRequestSchema=q.AddSmartAcountRequestSchema;exports.BackendAccountSchema=q.BackendAccountSchema;exports.isAccountV4=R.isAccountV4;exports.isAccountV5=R.isAccountV5;exports.isAccountV6=R.isAccountV6;exports.preferencesEndpointPayload=_.preferencesEndpointPayload;exports.preferencesSchema=_.preferencesSchema;exports.argentBackendNetworkIdSchema=A.argentBackendNetworkIdSchema;exports.argentNetworkIdSchema=A.argentNetworkIdSchema;exports.isArgentBackendNetworkId=A.isArgentBackendNetworkId;exports.isArgentNetworkId=A.isArgentNetworkId;exports.CacheService=J.CacheService;exports.addressOrEmptyUndefinedSchema=n.addressOrEmptyUndefinedSchema;exports.addressSchema=n.addressSchema;exports.addressSchemaArgentBackend=n.addressSchemaArgentBackend;exports.addressSchemaBase=n.addressSchemaBase;exports.addressSchemaLooseLength=n.addressSchemaLooseLength;exports.addressSchemaStrictLength=n.addressSchemaStrictLength;exports.formatFullAddress=n.formatFullAddress;exports.formatTruncatedAddress=n.formatTruncatedAddress;exports.formatTruncatedSignerKey=n.formatTruncatedSignerKey;exports.formatTruncatedString=n.formatTruncatedString;exports.includesAddress=n.includesAddress;exports.isAddress=n.isAddress;exports.isEqualAddress=n.isEqualAddress;exports.isValidAddress=n.isValidAddress;exports.isZeroAddress=n.isZeroAddress;exports.normalizeAddress=n.normalizeAddress;exports.validChecksumAddressSchema=n.validChecksumAddressSchema;exports.validateAddressRangeSchema=n.validateAddressRangeSchema;exports.addressOrDomainInputSchema=d.addressOrDomainInputSchema;exports.addressOrDomainSchema=d.addressOrDomainSchema;exports.isEqualStarknetDomainName=d.isEqualStarknetDomainName;exports.isStarknetDomainName=d.isStarknetDomainName;exports.normalizeAddressOrDomain=d.normalizeAddressOrDomain;exports.starknetDomainNameSchema=d.starknetDomainNameSchema;exports.addressInputCharactersAndLengthSchema=w.addressInputCharactersAndLengthSchema;exports.addressInputSchema=w.addressInputSchema;exports.argentNameSchema=p.argentNameSchema;exports.isArgentName=p.isArgentName;exports.isEqualArgentName=p.isEqualArgentName;exports.normalizeArgentName=p.normalizeArgentName;exports.cairoVersionSchema=ee.cairoVersionSchema;exports.ETH_TOKEN_ADDRESS=S.ETH_TOKEN_ADDRESS;exports.STANDARD_DEVNET_ACCOUNT_CLASS_HASH=S.STANDARD_DEVNET_ACCOUNT_CLASS_HASH;exports.STRK_TOKEN_ADDRESS=S.STRK_TOKEN_ADDRESS;exports.TXV1_ACCOUNT_CLASS_HASH=S.TXV1_ACCOUNT_CLASS_HASH;exports.TXV1_MULTISIG_CLASS_HASH=S.TXV1_MULTISIG_CLASS_HASH;exports.TXV3_ACCOUNT_CLASS_HASH=S.TXV3_ACCOUNT_CLASS_HASH;exports.TXV3_MULTISIG_CLASS_HASH=S.TXV3_MULTISIG_CLASS_HASH;exports.apiWalletResponseSchema=H.apiWalletResponseSchema;exports.getAddressFromArgentName=H.getAddressFromArgentName;exports.getAddressFromStarkName=T.getAddressFromStarkName;exports.getCallFromStarkName=T.getCallFromStarkName;exports.getStarknetIdContractAddressFromNetworkId=T.getStarknetIdContractAddressFromNetworkId;exports.starkNameToCallDataDomain=T.starkNameToCallDataDomain;exports.getChainIdFromNetworkId=ae.getChainIdFromNetworkId;exports.StarknetAddressService=re.StarknetAddressService;exports.ARGENT_ACCOUNT_CONTRACT_CLASS_HASHES=f.ARGENT_ACCOUNT_CONTRACT_CLASS_HASHES;exports.ARGENT_MULTISIG_CONTRACT_CLASS_HASHES=f.ARGENT_MULTISIG_CONTRACT_CLASS_HASHES;exports.C0_PROXY_CONTRACT_CLASS_HASHES=f.C0_PROXY_CONTRACT_CLASS_HASHES;exports.constructorCallDataSchemaC0=b.constructorCallDataSchemaC0;exports.constructorCallDataSchemaC1V1=b.constructorCallDataSchemaC1V1;exports.implementationSchema=b.implementationSchema;exports.buildConstructorCalldata=h.buildConstructorCalldata;exports.findImplementationForAccount=h.findImplementationForAccount;exports.getAccountContractAddress=h.getAccountContractAddress;exports.getAccountDeploymentPayload=h.getAccountDeploymentPayload;exports.isEqualImplementation=h.isEqualImplementation;exports.getArgentAccountClassHashes=i.getArgentAccountClassHashes;exports.getArgentAccountClassHashesWithTxV3Support=i.getArgentAccountClassHashesWithTxV3Support;exports.getArgentAccountWithMultiSignerClassHashes=i.getArgentAccountWithMultiSignerClassHashes;exports.getLastCairo0ArgentAccountClassHash=i.getLastCairo0ArgentAccountClassHash;exports.getLatestArgentAccountClassHash=i.getLatestArgentAccountClassHash;exports.getLatestArgentMultisigClassHash=i.getLatestArgentMultisigClassHash;exports.getLatestLedgerAccountClassHash=i.getLatestLedgerAccountClassHash;exports.getLedgerAccountClassHashes=i.getLedgerAccountClassHashes;exports.isEqualStarknetId=g.isEqualStarknetId;exports.isStarknetId=g.isStarknetId;exports.normalizeStarknetId=g.normalizeStarknetId;exports.starknetIdSchema=g.starknetIdSchema;exports.DateService=te.DateService;exports.HttpError=ne.HttpError;exports.HTTPService=se.HTTPService;Object.defineProperty(exports,"HTTP_ERROR_MESSAGE",{enumerable:!0,get:()=>ce.HTTP_ERROR_MESSAGE});exports.SWRService=oe.SWRService;exports.fetchData=N.fetchData;exports.fetcherError=N.fetcherError;exports.postData=N.postData;exports.getBackendTimeNowSeconds=O.getBackendTimeNowSeconds;exports.getBackendTimeSeconds=O.getBackendTimeSeconds;exports.KnownDappsBackendService=ie.KnownDappsBackendService;exports.dappContractSchema=y.dappContractSchema;exports.dappLinkSchema=y.dappLinkSchema;exports.knownDappSchema=y.knownDappSchema;exports.knownDappsSchema=y.knownDappsSchema;exports.getDapplandLinkForDapp=L.getDapplandLinkForDapp;exports.getDapplandUrlForDapp=L.getDapplandUrlForDapp;exports.ResolveNameService=me.ResolveNameService;exports.nameProviderResolutionSchema=l.nameProviderResolutionSchema;exports.nameResolutionAddressSchema=l.nameResolutionAddressSchema;exports.nameResolutionAddressesSchema=l.nameResolutionAddressesSchema;exports.nameResolutionStarknetIdSchema=l.nameResolutionStarknetIdSchema;exports.nameResolutionStarknetIdsSchema=l.nameResolutionStarknetIdsSchema;exports.providersNamesSchema=l.providersNamesSchema;exports.BackendNftService=Se.BackendNftService;exports.equalNft=V.equalNft;exports.getNftPicture=V.getNftPicture;exports.OnchainRecoveryService=de.OnchainRecoveryService;Object.defineProperty(exports,"RecoveryStatusEnum",{enumerable:!0,get:()=>c.RecoveryStatusEnum});Object.defineProperty(exports,"StartOnchainRecoveryErrorStatusEnum",{enumerable:!0,get:()=>c.StartOnchainRecoveryErrorStatusEnum});exports.activeOnchainRecoverySchema=c.activeOnchainRecoverySchema;exports.onchainRecoverySchema=c.onchainRecoverySchema;exports.recoveryBaseSchema=c.recoveryBaseSchema;exports.recoveryBodySchema=c.recoveryBodySchema;exports.recoveryStatusSchema=c.recoveryStatusSchema;exports.startOnchainRecoveryErrorSchema=c.startOnchainRecoveryErrorSchema;exports.startOnchainRecoveryErrorStatusSchema=c.startOnchainRecoveryErrorStatusSchema;exports.startOnchainRecoverySchema=c.startOnchainRecoverySchema;exports.isBraveBrowser=le.isBraveBrowser;exports.getUAParserResult=u.getUAParserResult;exports.isBrowser=u.isBrowser;exports.isChromeBrowser=u.isChromeBrowser;exports.isEdgeBrowser=u.isEdgeBrowser;exports.isFirefoxBrowser=u.isFirefoxBrowser;exports.isSafariBrowser=u.isSafariBrowser;exports.seedphraseSchema=ue.seedphraseSchema;Object.defineProperty(exports,"MultiSigner",{enumerable:!0,get:()=>x.MultiSigner});exports.getSignerForMultiSigner=x.getSignerForMultiSigner;exports.buildBuyCalldataResponseSchema=m.buildBuyCalldataResponseSchema;exports.buildBuyCalldataSchema=m.buildBuyCalldataSchema;exports.investmentMetaSchema=m.investmentMetaSchema;exports.investmentSchema=m.investmentSchema;exports.investmentsResponseSchema=m.investmentsResponseSchema;exports.lendingInvestmentSchema=m.lendingInvestmentSchema;exports.stakingInvestmentSchema=m.stakingInvestmentSchema;exports.strkDelegatedStakingInvestmentSchema=m.strkDelegatedStakingInvestmentSchema;exports.getTokenBalance=C.getTokenBalance;exports.getTokens=C.getTokens;exports.getTokensBalances=C.getTokensBalances;exports.useToken=C.useToken;exports.DEFAULT_TOKEN_DECIMALS=he.DEFAULT_TOKEN_DECIMALS;exports.convertTokenAmountToCurrencyValue=Ae.convertTokenAmountToCurrencyValue;exports.convertTokenUnitAmountWithDecimals=pe.convertTokenUnitAmountWithDecimals;exports.ensureDecimals=Te.ensureDecimals;exports.isUnlimitedAmount=ge.isUnlimitedAmount;exports.prettifyCurrencyValue=ye.prettifyCurrencyValue;exports.PRETTY_UNLIMITED=M.PRETTY_UNLIMITED;exports.prettifyTokenAmount=M.prettifyTokenAmount;exports.getCurrencySymbol=Ce.getCurrencySymbol;exports.TokenServiceWeb=ke.TokenServiceWeb;Object.defineProperty(exports,"TOKEN_ERROR_MESSAGES",{enumerable:!0,get:()=>W.TOKEN_ERROR_MESSAGES});exports.TokenError=W.TokenError;exports.apiAccountTokenBalancesSchema=a.apiAccountTokenBalancesSchema;exports.apiAirdropSchema=a.apiAirdropSchema;exports.apiCollateralizedDebtPositionSchema=a.apiCollateralizedDebtPositionSchema;exports.apiCollateralizedDebtPositionsSchema=a.apiCollateralizedDebtPositionsSchema;exports.apiConcentratedLiquidityPositionSchema=a.apiConcentratedLiquidityPositionSchema;exports.apiConcentratedLiquidityPositionsSchema=a.apiConcentratedLiquidityPositionsSchema;exports.apiDefiDecompositionProduct=a.apiDefiDecompositionProduct;exports.apiDefiDecompositionProducts=a.apiDefiDecompositionProducts;exports.apiDefiDecompositionSchema=a.apiDefiDecompositionSchema;exports.apiDefiDecompositionToken=a.apiDefiDecompositionToken;exports.apiDefiPositionsSchema=a.apiDefiPositionsSchema;exports.apiDelegatedTokensArraySchema=a.apiDelegatedTokensArraySchema;exports.apiDelegatedTokensSchema=a.apiDelegatedTokensSchema;exports.apiPriceDataResponseSchema=a.apiPriceDataResponseSchema;exports.apiPriceDetailsSchema=a.apiPriceDetailsSchema;exports.apiStakingPositionSchema=a.apiStakingPositionSchema;exports.apiStakingPositionsSchema=a.apiStakingPositionsSchema;exports.apiTokenInfoResponseSchema=a.apiTokenInfoResponseSchema;exports.apiTokenInfoSchema=a.apiTokenInfoSchema;exports.apiTokensInfoResponseSchema=a.apiTokensInfoResponseSchema;exports.apiUnclaimedRewardsSchema=a.apiUnclaimedRewardsSchema;exports.collateralizedDebtGroupSchema=s.collateralizedDebtGroupSchema;exports.collateralizedDebtPositionSchema=s.collateralizedDebtPositionSchema;exports.collateralizedDebtPositionsSchema=s.collateralizedDebtPositionsSchema;exports.concentratedLiquidityPositionSchema=s.concentratedLiquidityPositionSchema;exports.concentratedLiquidityPositionsSchema=s.concentratedLiquidityPositionsSchema;exports.defiDappsProductsSchema=s.defiDappsProductsSchema;exports.defiPositionSchema=s.defiPositionSchema;exports.defiProductSchema=s.defiProductSchema;exports.defiProductsSchema=s.defiProductsSchema;exports.delegatedTokensArraySchema=s.delegatedTokensArraySchema;exports.delegatedTokensSchema=s.delegatedTokensSchema;exports.productGroupsSchema=s.productGroupsSchema;exports.defiPositionTypeSchema=Ee.defiPositionTypeSchema;exports.airdropSchema=U.airdropSchema;exports.unclaimedRewardsSchema=U.unclaimedRewardsSchema;exports.webBaseTokenSchema=o.webBaseTokenSchema;exports.webBaseTokenWithBalanceSchema=o.webBaseTokenWithBalanceSchema;exports.webTokenInfoDetailsSchema=o.webTokenInfoDetailsSchema;exports.webTokenPriceDetailsSchema=o.webTokenPriceDetailsSchema;exports.webTokenSchema=o.webTokenSchema;exports.webTokenWithBalanceAndPriceSchema=o.webTokenWithBalanceAndPriceSchema;exports.webTokenWithBalanceSchema=o.webTokenWithBalanceSchema;exports.webTokenWithPriceSchema=o.webTokenWithPriceSchema;exports.webTokensWithBalanceAndPriceSchema=o.webTokensWithBalanceAndPriceSchema;exports.inputAmountSchema=P.inputAmountSchema;exports.isValidInputAmount=P.isValidInputAmount;exports.parseAmount=P.parseAmount;exports.erc20TransferTransaction=F.erc20TransferTransaction;exports.erc721SafeTransferFromTransaction=F.erc721SafeTransferFromTransaction;exports.erc721TransferFromTransaction=F.erc721TransferFromTransaction;exports.getMessageFromTrpcError=G.getMessageFromTrpcError;exports.trpcErrorSchema=G.trpcErrorSchema;exports.FEE_OVERHEAD=I.FEE_OVERHEAD;exports.argentMaxFee=I.argentMaxFee;exports.modifySnjsFeeOverhead=I.modifySnjsFeeOverhead;Object.defineProperty(exports,"ESTIMATE_ERROR_MESSAGES",{enumerable:!0,get:()=>z.ESTIMATE_ERROR_MESSAGES});exports.EstimateError=z.EstimateError;exports.transactionReviewTransactionsSchema=De.transactionReviewTransactionsSchema;exports.buildDummyTx=t.buildDummyTx;exports.calculateCubeRootAdjustment=t.calculateCubeRootAdjustment;exports.calculateNonLinearAdjustment=t.calculateNonLinearAdjustment;exports.calculateSqrtAdjustment=t.calculateSqrtAdjustment;exports.castFeeEstimation=t.castFeeEstimation;exports.estimatedFeeToMaxFeeTotal=t.estimatedFeeToMaxFeeTotal;exports.estimatedFeeToMaxResourceBounds=t.estimatedFeeToMaxResourceBounds;exports.estimatedFeeToTotal=t.estimatedFeeToTotal;exports.estimatedFeesToMaxFeeTotal=t.estimatedFeesToMaxFeeTotal;exports.estimatedFeesToTotal=t.estimatedFeesToTotal;exports.getEstimatedFeeFromBulkSimulation=t.getEstimatedFeeFromBulkSimulation;exports.getEstimatedFeeFromSimulationAndRespectWatermarkFee=t.getEstimatedFeeFromSimulationAndRespectWatermarkFee;exports.getPayloadFromTransaction=t.getPayloadFromTransaction;exports.getWatermarkedMaxFeeTotal=t.getWatermarkedMaxFeeTotal;exports.isFRI=t.isFRI;exports.isWEI=t.isWEI;exports.multiplyBigIntByFloat=t.multiplyBigIntByFloat;exports.toMax=t.toMax;exports.tokensRequireTxV3Support=t.tokensRequireTxV3Support;exports.unitToFeeTokenAddress=t.unitToFeeTokenAddress;exports.EventsBySelector=j.EventsBySelector;exports.findTransfersAndApprovals=j.findTransfersAndApprovals;exports.getPrettyRpcError=ve.getPrettyRpcError;exports.getSimulationTxVersionFromFeeToken=B.getSimulationTxVersionFromFeeToken;exports.getTxVersionFromFeeToken=B.getTxVersionFromFeeToken;exports.getTxVersionFromFeeTokenForDeclareContract=B.getTxVersionFromFeeTokenForDeclareContract;exports.TransactionReviewServiceWeb=qe.TransactionReviewServiceWeb;exports.transactionReviewWarningSchema=Re.transactionReviewWarningSchema;exports.apiTransactionReviewActivityType=fe.apiTransactionReviewActivityType;exports.denyTxV3=K.denyTxV3;exports.txVersionSchema=K.txVersionSchema;exports.classHashSupportsTxV3=X.classHashSupportsTxV3;exports.feeTokenNeedsTxV3Support=X.feeTokenNeedsTxV3Support;exports.formatAddress=be.formatAddress;exports.ensureArray=Ne.ensureArray;exports.generateAvatarImage=k.generateAvatarImage;exports.getColor=k.getColor;exports.getNetworkAccountImageUrl=k.getNetworkAccountImageUrl;exports.stripAddressZeroPadding=k.stripAddressZeroPadding;exports.decodeBase58=E.decodeBase58;exports.decodeBase58Array=E.decodeBase58Array;exports.encodeBase58=E.encodeBase58;exports.encodeBase58Array=E.encodeBase58Array;exports.bigNumberSchema=Pe.bigNumberSchema;exports.daysBetween=Fe.daysBetween;exports.isFeatureEnabled=Ie.isFeatureEnabled;exports.hexSchema=$.hexSchema;exports.hexSchemaBase=$.hexSchemaBase;exports.id=Be.id;exports.getInitials=_e.getInitials;exports.isContractDeployed=we.isContractDeployed;exports.nonNullable=He.nonNullable;exports.isAllowedAddressHexInputValue=Oe.isAllowedAddressHexInputValue;exports.isAllowedNumericInputValue=Le.isAllowedNumericInputValue;exports.isNumeric=Ve.isNumeric;exports.prettifyCurrencyNumber=D.prettifyCurrencyNumber;exports.prettifyNumber=D.prettifyNumber;exports.prettifyNumberConfig=D.prettifyNumberConfig;exports.prettifyTokenNumber=D.prettifyTokenNumber;exports.getUint256CalldataFromBN=Y.getUint256CalldataFromBN;exports.parseAmountValue=Y.parseAmountValue;exports.pluralise=xe.pluralise;exports.readFileAsString=Me.readFileAsString;exports.booleanToStringSchema=v.booleanToStringSchema;exports.createSchemaWithWarnings=v.createSchemaWithWarnings;exports.safeParseAndWarn=v.safeParseAndWarn;exports.stringToBooleanSchema=v.stringToBooleanSchema;exports.addOwnersCalldataSchema=r.addOwnersCalldataSchema;exports.addPluginCalldataSchema=r.addPluginCalldataSchema;exports.bigNumberishSchema=r.bigNumberishSchema;exports.callDetailsSchema=r.callDetailsSchema;exports.callSchema=r.callSchema;exports.calldataSchema=r.calldataSchema;exports.changeGuardianCalldataSchema=r.changeGuardianCalldataSchema;exports.changeThresholdCalldataSchema=r.changeThresholdCalldataSchema;exports.escapeGuardianCalldataSchema=r.escapeGuardianCalldataSchema;exports.executeOnPluginCalldataSchema=r.executeOnPluginCalldataSchema;exports.feltSchema=r.feltSchema;exports.looseCalldataSchema=r.looseCalldataSchema;exports.multiTypeSchema=r.multiTypeSchema;exports.rawArgsArraySchema=r.rawArgsArraySchema;exports.rawArgsObjectSchema=r.rawArgsObjectSchema;exports.rawArgsSchema=r.rawArgsSchema;exports.removeOwnersCalldataSchema=r.removeOwnersCalldataSchema;exports.removePluginCalldataSchema=r.removePluginCalldataSchema;exports.replaceSignerCalldataSchema=r.replaceSignerCalldataSchema;exports.transferCalldataSchema=r.transferCalldataSchema;exports.uint256Schema=r.uint256Schema;exports.abiEntrySchema=e.abiEntrySchema;exports.abiSchema=e.abiSchema;exports.builtinsSchema=e.builtinsSchema;exports.byteCodeSchema=e.byteCodeSchema;exports.cairo1EventSchema=e.cairo1EventSchema;exports.cairoAssemblySchema=e.cairoAssemblySchema;exports.compiledContractClassSchema=e.compiledContractClassSchema;exports.compiledSierraCasmSchema=e.compiledSierraCasmSchema;exports.compiledSierraSchema=e.compiledSierraSchema;exports.compressedProgramSchema=e.compressedProgramSchema;exports.contractEntryPointFieldsSchema=e.contractEntryPointFieldsSchema;exports.entryPointsByTypeSchema=e.entryPointsByTypeSchema;exports.eventAbiSchema=e.eventAbiSchema;exports.eventEntrySchema=e.eventEntrySchema;exports.functionAbiSchema=e.functionAbiSchema;exports.functionAbiTypeSchema=e.functionAbiTypeSchema;exports.legacyContractClassSchema=e.legacyContractClassSchema;exports.legacyEventSchema=e.legacyEventSchema;exports.programSchema=e.programSchema;exports.pythonicHintsSchema=e.pythonicHintsSchema;exports.sierraContractEntryPointFieldsSchema=e.sierraContractEntryPointFieldsSchema;exports.sierraEntryPointsByTypeSchema=e.sierraEntryPointsByTypeSchema;exports.sierraProgramDebugInfoSchema=e.sierraProgramDebugInfoSchema;exports.structAbiSchema=e.structAbiSchema;exports.entryPointToHumanReadable=We.entryPointToHumanReadable;exports.urlWithQuery=Ue.urlWithQuery;exports.voidify=Ge.voidify;exports.bipsToPercent=ze.bipsToPercent;
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const Z=require("./src/bigdecimal/index.cjs"),Q=require("./src/errors/baseErrors.cjs"),q=require("./src/account/account.model.cjs"),R=require("./src/account/accountv4.cjs"),w=require("./src/account/preferences.model.cjs"),A=require("./src/backend/schema.cjs"),J=require("./src/cache/CacheService.cjs"),n=require("./src/chains/starknet/address.cjs"),d=require("./src/chains/starknet/addressDomain.cjs"),_=require("./src/chains/starknet/addressInput.cjs"),p=require("./src/chains/starknet/argentName.cjs"),ee=require("./src/chains/starknet/cairoVersionSchema.cjs"),S=require("./src/chains/starknet/constants.cjs"),O=require("./src/chains/starknet/getAddressFromArgentName.cjs"),T=require("./src/chains/starknet/getAddressFromStarkName.cjs"),ae=require("./src/chains/starknet/network.cjs"),re=require("./src/chains/starknet/services/address/StarknetAddressService.cjs"),f=require("./src/chains/starknet/services/deploymentData/constants.cjs"),b=require("./src/chains/starknet/services/deploymentData/deploymentData.schema.cjs"),h=require("./src/chains/starknet/services/deploymentData/findImplementationForAccount.cjs"),i=require("./src/chains/starknet/services/deploymentData/getAccountClassHash.cjs"),g=require("./src/chains/starknet/starknetId.cjs"),te=require("./src/http/DateService.cjs"),ne=require("./src/http/HttpError.cjs"),se=require("./src/http/HttpService.cjs"),ce=require("./src/http/IHttpService.cjs"),oe=require("./src/http/SWRService.cjs"),N=require("./src/http/fetcher.cjs"),H=require("./src/http/time.cjs"),ie=require("./src/knownDapps/KnownDappsBackendService.cjs"),y=require("./src/knownDapps/schema.cjs"),L=require("./src/knownDapps/utils/getDapplandUrl.cjs"),me=require("./src/nameResolution/ResolveNameService.cjs"),l=require("./src/nameResolution/schema.cjs"),Se=require("./src/nfts/BackendNftService.cjs"),V=require("./src/nfts/utils.cjs"),de=require("./src/onchainRecovery/OnchainRecoveryService.cjs"),c=require("./src/onchainRecovery/schema.cjs"),le=require("./src/platform/isBraveBrowser.cjs"),u=require("./src/platform/isBrowser.cjs"),ue=require("./src/signer/seedphrase.cjs"),x=require("./src/signer/multisigner.cjs"),he=require("./src/signer/mergeOwnerGuardianSignatures.cjs"),m=require("./src/staking/schema.cjs"),C=require("./src/tokens/balances.cjs"),Ae=require("./src/tokens/constants.cjs"),pe=require("./src/tokens/convertTokenAmountToCurrencyValue.cjs"),Te=require("./src/tokens/convertTokenUnitAmountWithDecimals.cjs"),ge=require("./src/tokens/ensureDecimals.cjs"),ye=require("./src/tokens/isUnlimitedAmount.cjs"),Ce=require("./src/tokens/prettifyCurrencyValue.cjs"),M=require("./src/tokens/prettifyTokenAmount.cjs"),ke=require("./src/tokens/getCurrencySymbol.cjs"),Ee=require("./src/tokens/service/implementation.cjs"),W=require("./src/tokens/service/tokenError.cjs"),a=require("./src/tokens/service/types/backend.model.cjs"),s=require("./src/tokens/service/types/defiPosition.model.cjs"),De=require("./src/tokens/service/types/defiPositionType.model.cjs"),U=require("./src/tokens/service/types/unclaimedRewards.model.cjs"),o=require("./src/tokens/service/types/webToken.model.cjs"),P=require("./src/transactions/amount.cjs"),F=require("./src/transactions/buildTransactions.cjs"),G=require("./src/transactions/errors.cjs"),I=require("./src/transactions/estimate/argentMaxFee.cjs"),z=require("./src/transactions/estimate/error.cjs"),ve=require("./src/transactions/estimate/model.cjs"),t=require("./src/transactions/estimate/utils.cjs"),j=require("./src/transactions/findTransfersAndApprovals.cjs"),qe=require("./src/transactions/getPrettyRcpError.cjs"),B=require("./src/transactions/getTransactionVersion.cjs"),Re=require("./src/transactions/service/implementation.cjs"),fe=require("./src/transactions/service/types.cjs"),be=require("./src/transactions/transactionReviewTypes.cjs"),K=require("./src/transactions/transactionVersion.cjs"),X=require("./src/transactions/txv3.cjs"),Ne=require("./src/utils/address.cjs"),Pe=require("./src/utils/arrays.cjs"),k=require("./src/utils/avatarImage.cjs"),E=require("./src/utils/base58.cjs"),Fe=require("./src/utils/bigNumber.cjs"),Ie=require("./src/utils/daysBetween.cjs"),Be=require("./src/utils/env.cjs"),$=require("./src/utils/hex.cjs"),we=require("./src/utils/id.cjs"),_e=require("./src/utils/initials.cjs"),Oe=require("./src/utils/isContractDeployed.cjs"),He=require("./src/utils/nonNullable.cjs"),Le=require("./src/utils/number/isAllowedAddressHexInputValue.cjs"),Ve=require("./src/utils/number/isAllowedNumericInputValue.cjs"),xe=require("./src/utils/number/isNumeric.cjs"),D=require("./src/utils/number/prettifyNumber.cjs"),Y=require("./src/utils/parseAmount.cjs"),Me=require("./src/utils/pluralise.cjs"),We=require("./src/utils/readFileAsString.cjs"),v=require("./src/utils/schemas.cjs"),r=require("./src/utils/starknet/starknet.cjs"),e=require("./src/utils/starknet/starknetSchemas.cjs"),Ue=require("./src/utils/transactions.cjs"),Ge=require("./src/utils/url/urlWithQuery.cjs"),ze=require("./src/utils/voidify.cjs"),je=require("./src/utils/bips.cjs");exports.bigDecimal=Z;exports.BaseError=Q.BaseError;exports.AddSmartAccountResponseSchema=q.AddSmartAccountResponseSchema;exports.AddSmartAcountRequestSchema=q.AddSmartAcountRequestSchema;exports.BackendAccountSchema=q.BackendAccountSchema;exports.isAccountV4=R.isAccountV4;exports.isAccountV5=R.isAccountV5;exports.isAccountV6=R.isAccountV6;exports.preferencesEndpointPayload=w.preferencesEndpointPayload;exports.preferencesSchema=w.preferencesSchema;exports.argentBackendNetworkIdSchema=A.argentBackendNetworkIdSchema;exports.argentNetworkIdSchema=A.argentNetworkIdSchema;exports.isArgentBackendNetworkId=A.isArgentBackendNetworkId;exports.isArgentNetworkId=A.isArgentNetworkId;exports.CacheService=J.CacheService;exports.addressOrEmptyUndefinedSchema=n.addressOrEmptyUndefinedSchema;exports.addressSchema=n.addressSchema;exports.addressSchemaArgentBackend=n.addressSchemaArgentBackend;exports.addressSchemaBase=n.addressSchemaBase;exports.addressSchemaLooseLength=n.addressSchemaLooseLength;exports.addressSchemaStrictLength=n.addressSchemaStrictLength;exports.formatFullAddress=n.formatFullAddress;exports.formatTruncatedAddress=n.formatTruncatedAddress;exports.formatTruncatedSignerKey=n.formatTruncatedSignerKey;exports.formatTruncatedString=n.formatTruncatedString;exports.includesAddress=n.includesAddress;exports.isAddress=n.isAddress;exports.isEqualAddress=n.isEqualAddress;exports.isValidAddress=n.isValidAddress;exports.isZeroAddress=n.isZeroAddress;exports.normalizeAddress=n.normalizeAddress;exports.validChecksumAddressSchema=n.validChecksumAddressSchema;exports.validateAddressRangeSchema=n.validateAddressRangeSchema;exports.addressOrDomainInputSchema=d.addressOrDomainInputSchema;exports.addressOrDomainSchema=d.addressOrDomainSchema;exports.isEqualStarknetDomainName=d.isEqualStarknetDomainName;exports.isStarknetDomainName=d.isStarknetDomainName;exports.normalizeAddressOrDomain=d.normalizeAddressOrDomain;exports.starknetDomainNameSchema=d.starknetDomainNameSchema;exports.addressInputCharactersAndLengthSchema=_.addressInputCharactersAndLengthSchema;exports.addressInputSchema=_.addressInputSchema;exports.argentNameSchema=p.argentNameSchema;exports.isArgentName=p.isArgentName;exports.isEqualArgentName=p.isEqualArgentName;exports.normalizeArgentName=p.normalizeArgentName;exports.cairoVersionSchema=ee.cairoVersionSchema;exports.ETH_TOKEN_ADDRESS=S.ETH_TOKEN_ADDRESS;exports.STANDARD_DEVNET_ACCOUNT_CLASS_HASH=S.STANDARD_DEVNET_ACCOUNT_CLASS_HASH;exports.STRK_TOKEN_ADDRESS=S.STRK_TOKEN_ADDRESS;exports.TXV1_ACCOUNT_CLASS_HASH=S.TXV1_ACCOUNT_CLASS_HASH;exports.TXV1_MULTISIG_CLASS_HASH=S.TXV1_MULTISIG_CLASS_HASH;exports.TXV3_ACCOUNT_CLASS_HASH=S.TXV3_ACCOUNT_CLASS_HASH;exports.TXV3_MULTISIG_CLASS_HASH=S.TXV3_MULTISIG_CLASS_HASH;exports.apiWalletResponseSchema=O.apiWalletResponseSchema;exports.getAddressFromArgentName=O.getAddressFromArgentName;exports.getAddressFromStarkName=T.getAddressFromStarkName;exports.getCallFromStarkName=T.getCallFromStarkName;exports.getStarknetIdContractAddressFromNetworkId=T.getStarknetIdContractAddressFromNetworkId;exports.starkNameToCallDataDomain=T.starkNameToCallDataDomain;exports.getChainIdFromNetworkId=ae.getChainIdFromNetworkId;exports.StarknetAddressService=re.StarknetAddressService;exports.ARGENT_ACCOUNT_CONTRACT_CLASS_HASHES=f.ARGENT_ACCOUNT_CONTRACT_CLASS_HASHES;exports.ARGENT_MULTISIG_CONTRACT_CLASS_HASHES=f.ARGENT_MULTISIG_CONTRACT_CLASS_HASHES;exports.C0_PROXY_CONTRACT_CLASS_HASHES=f.C0_PROXY_CONTRACT_CLASS_HASHES;exports.constructorCallDataSchemaC0=b.constructorCallDataSchemaC0;exports.constructorCallDataSchemaC1V1=b.constructorCallDataSchemaC1V1;exports.implementationSchema=b.implementationSchema;exports.buildConstructorCalldata=h.buildConstructorCalldata;exports.findImplementationForAccount=h.findImplementationForAccount;exports.getAccountContractAddress=h.getAccountContractAddress;exports.getAccountDeploymentPayload=h.getAccountDeploymentPayload;exports.isEqualImplementation=h.isEqualImplementation;exports.getArgentAccountClassHashes=i.getArgentAccountClassHashes;exports.getArgentAccountClassHashesWithTxV3Support=i.getArgentAccountClassHashesWithTxV3Support;exports.getArgentAccountWithMultiSignerClassHashes=i.getArgentAccountWithMultiSignerClassHashes;exports.getLastCairo0ArgentAccountClassHash=i.getLastCairo0ArgentAccountClassHash;exports.getLatestArgentAccountClassHash=i.getLatestArgentAccountClassHash;exports.getLatestArgentMultisigClassHash=i.getLatestArgentMultisigClassHash;exports.getLatestLedgerAccountClassHash=i.getLatestLedgerAccountClassHash;exports.getLedgerAccountClassHashes=i.getLedgerAccountClassHashes;exports.isEqualStarknetId=g.isEqualStarknetId;exports.isStarknetId=g.isStarknetId;exports.normalizeStarknetId=g.normalizeStarknetId;exports.starknetIdSchema=g.starknetIdSchema;exports.DateService=te.DateService;exports.HttpError=ne.HttpError;exports.HTTPService=se.HTTPService;Object.defineProperty(exports,"HTTP_ERROR_MESSAGE",{enumerable:!0,get:()=>ce.HTTP_ERROR_MESSAGE});exports.SWRService=oe.SWRService;exports.fetchData=N.fetchData;exports.fetcherError=N.fetcherError;exports.postData=N.postData;exports.getBackendTimeNowSeconds=H.getBackendTimeNowSeconds;exports.getBackendTimeSeconds=H.getBackendTimeSeconds;exports.KnownDappsBackendService=ie.KnownDappsBackendService;exports.dappContractSchema=y.dappContractSchema;exports.dappLinkSchema=y.dappLinkSchema;exports.knownDappSchema=y.knownDappSchema;exports.knownDappsSchema=y.knownDappsSchema;exports.getDapplandLinkForDapp=L.getDapplandLinkForDapp;exports.getDapplandUrlForDapp=L.getDapplandUrlForDapp;exports.ResolveNameService=me.ResolveNameService;exports.nameProviderResolutionSchema=l.nameProviderResolutionSchema;exports.nameResolutionAddressSchema=l.nameResolutionAddressSchema;exports.nameResolutionAddressesSchema=l.nameResolutionAddressesSchema;exports.nameResolutionStarknetIdSchema=l.nameResolutionStarknetIdSchema;exports.nameResolutionStarknetIdsSchema=l.nameResolutionStarknetIdsSchema;exports.providersNamesSchema=l.providersNamesSchema;exports.BackendNftService=Se.BackendNftService;exports.equalNft=V.equalNft;exports.getNftPicture=V.getNftPicture;exports.OnchainRecoveryService=de.OnchainRecoveryService;Object.defineProperty(exports,"RecoveryStatusEnum",{enumerable:!0,get:()=>c.RecoveryStatusEnum});Object.defineProperty(exports,"StartOnchainRecoveryErrorStatusEnum",{enumerable:!0,get:()=>c.StartOnchainRecoveryErrorStatusEnum});exports.activeOnchainRecoverySchema=c.activeOnchainRecoverySchema;exports.onchainRecoverySchema=c.onchainRecoverySchema;exports.recoveryBaseSchema=c.recoveryBaseSchema;exports.recoveryBodySchema=c.recoveryBodySchema;exports.recoveryStatusSchema=c.recoveryStatusSchema;exports.startOnchainRecoveryErrorSchema=c.startOnchainRecoveryErrorSchema;exports.startOnchainRecoveryErrorStatusSchema=c.startOnchainRecoveryErrorStatusSchema;exports.startOnchainRecoverySchema=c.startOnchainRecoverySchema;exports.isBraveBrowser=le.isBraveBrowser;exports.getUAParserResult=u.getUAParserResult;exports.isBrowser=u.isBrowser;exports.isChromeBrowser=u.isChromeBrowser;exports.isEdgeBrowser=u.isEdgeBrowser;exports.isFirefoxBrowser=u.isFirefoxBrowser;exports.isSafariBrowser=u.isSafariBrowser;exports.seedphraseSchema=ue.seedphraseSchema;Object.defineProperty(exports,"MultiSigner",{enumerable:!0,get:()=>x.MultiSigner});exports.getSignerForMultiSigner=x.getSignerForMultiSigner;exports.mergeOwnerGuardianSignatures=he.mergeOwnerGuardianSignatures;exports.buildBuyCalldataResponseSchema=m.buildBuyCalldataResponseSchema;exports.buildBuyCalldataSchema=m.buildBuyCalldataSchema;exports.investmentMetaSchema=m.investmentMetaSchema;exports.investmentSchema=m.investmentSchema;exports.investmentsResponseSchema=m.investmentsResponseSchema;exports.lendingInvestmentSchema=m.lendingInvestmentSchema;exports.stakingInvestmentSchema=m.stakingInvestmentSchema;exports.strkDelegatedStakingInvestmentSchema=m.strkDelegatedStakingInvestmentSchema;exports.getTokenBalance=C.getTokenBalance;exports.getTokens=C.getTokens;exports.getTokensBalances=C.getTokensBalances;exports.useToken=C.useToken;exports.DEFAULT_TOKEN_DECIMALS=Ae.DEFAULT_TOKEN_DECIMALS;exports.convertTokenAmountToCurrencyValue=pe.convertTokenAmountToCurrencyValue;exports.convertTokenUnitAmountWithDecimals=Te.convertTokenUnitAmountWithDecimals;exports.ensureDecimals=ge.ensureDecimals;exports.isUnlimitedAmount=ye.isUnlimitedAmount;exports.prettifyCurrencyValue=Ce.prettifyCurrencyValue;exports.PRETTY_UNLIMITED=M.PRETTY_UNLIMITED;exports.prettifyTokenAmount=M.prettifyTokenAmount;exports.getCurrencySymbol=ke.getCurrencySymbol;exports.TokenServiceWeb=Ee.TokenServiceWeb;Object.defineProperty(exports,"TOKEN_ERROR_MESSAGES",{enumerable:!0,get:()=>W.TOKEN_ERROR_MESSAGES});exports.TokenError=W.TokenError;exports.apiAccountTokenBalancesSchema=a.apiAccountTokenBalancesSchema;exports.apiAirdropSchema=a.apiAirdropSchema;exports.apiCollateralizedDebtPositionSchema=a.apiCollateralizedDebtPositionSchema;exports.apiCollateralizedDebtPositionsSchema=a.apiCollateralizedDebtPositionsSchema;exports.apiConcentratedLiquidityPositionSchema=a.apiConcentratedLiquidityPositionSchema;exports.apiConcentratedLiquidityPositionsSchema=a.apiConcentratedLiquidityPositionsSchema;exports.apiDefiDecompositionProduct=a.apiDefiDecompositionProduct;exports.apiDefiDecompositionProducts=a.apiDefiDecompositionProducts;exports.apiDefiDecompositionSchema=a.apiDefiDecompositionSchema;exports.apiDefiDecompositionToken=a.apiDefiDecompositionToken;exports.apiDefiPositionsSchema=a.apiDefiPositionsSchema;exports.apiDelegatedTokensArraySchema=a.apiDelegatedTokensArraySchema;exports.apiDelegatedTokensSchema=a.apiDelegatedTokensSchema;exports.apiPriceDataResponseSchema=a.apiPriceDataResponseSchema;exports.apiPriceDetailsSchema=a.apiPriceDetailsSchema;exports.apiStakingPositionSchema=a.apiStakingPositionSchema;exports.apiStakingPositionsSchema=a.apiStakingPositionsSchema;exports.apiTokenInfoResponseSchema=a.apiTokenInfoResponseSchema;exports.apiTokenInfoSchema=a.apiTokenInfoSchema;exports.apiTokensInfoResponseSchema=a.apiTokensInfoResponseSchema;exports.apiUnclaimedRewardsSchema=a.apiUnclaimedRewardsSchema;exports.collateralizedDebtGroupSchema=s.collateralizedDebtGroupSchema;exports.collateralizedDebtPositionSchema=s.collateralizedDebtPositionSchema;exports.collateralizedDebtPositionsSchema=s.collateralizedDebtPositionsSchema;exports.concentratedLiquidityPositionSchema=s.concentratedLiquidityPositionSchema;exports.concentratedLiquidityPositionsSchema=s.concentratedLiquidityPositionsSchema;exports.defiDappsProductsSchema=s.defiDappsProductsSchema;exports.defiPositionSchema=s.defiPositionSchema;exports.defiProductSchema=s.defiProductSchema;exports.defiProductsSchema=s.defiProductsSchema;exports.delegatedTokensArraySchema=s.delegatedTokensArraySchema;exports.delegatedTokensSchema=s.delegatedTokensSchema;exports.productGroupsSchema=s.productGroupsSchema;exports.defiPositionTypeSchema=De.defiPositionTypeSchema;exports.airdropSchema=U.airdropSchema;exports.unclaimedRewardsSchema=U.unclaimedRewardsSchema;exports.webBaseTokenSchema=o.webBaseTokenSchema;exports.webBaseTokenWithBalanceSchema=o.webBaseTokenWithBalanceSchema;exports.webTokenInfoDetailsSchema=o.webTokenInfoDetailsSchema;exports.webTokenPriceDetailsSchema=o.webTokenPriceDetailsSchema;exports.webTokenSchema=o.webTokenSchema;exports.webTokenWithBalanceAndPriceSchema=o.webTokenWithBalanceAndPriceSchema;exports.webTokenWithBalanceSchema=o.webTokenWithBalanceSchema;exports.webTokenWithPriceSchema=o.webTokenWithPriceSchema;exports.webTokensWithBalanceAndPriceSchema=o.webTokensWithBalanceAndPriceSchema;exports.inputAmountSchema=P.inputAmountSchema;exports.isValidInputAmount=P.isValidInputAmount;exports.parseAmount=P.parseAmount;exports.erc20TransferTransaction=F.erc20TransferTransaction;exports.erc721SafeTransferFromTransaction=F.erc721SafeTransferFromTransaction;exports.erc721TransferFromTransaction=F.erc721TransferFromTransaction;exports.getMessageFromTrpcError=G.getMessageFromTrpcError;exports.trpcErrorSchema=G.trpcErrorSchema;exports.FEE_OVERHEAD=I.FEE_OVERHEAD;exports.argentMaxFee=I.argentMaxFee;exports.modifySnjsFeeOverhead=I.modifySnjsFeeOverhead;Object.defineProperty(exports,"ESTIMATE_ERROR_MESSAGES",{enumerable:!0,get:()=>z.ESTIMATE_ERROR_MESSAGES});exports.EstimateError=z.EstimateError;exports.transactionReviewTransactionsSchema=ve.transactionReviewTransactionsSchema;exports.buildDummyTx=t.buildDummyTx;exports.calculateCubeRootAdjustment=t.calculateCubeRootAdjustment;exports.calculateNonLinearAdjustment=t.calculateNonLinearAdjustment;exports.calculateSqrtAdjustment=t.calculateSqrtAdjustment;exports.castFeeEstimation=t.castFeeEstimation;exports.estimatedFeeToMaxFeeTotal=t.estimatedFeeToMaxFeeTotal;exports.estimatedFeeToMaxResourceBounds=t.estimatedFeeToMaxResourceBounds;exports.estimatedFeeToTotal=t.estimatedFeeToTotal;exports.estimatedFeesToMaxFeeTotal=t.estimatedFeesToMaxFeeTotal;exports.estimatedFeesToTotal=t.estimatedFeesToTotal;exports.getEstimatedFeeFromBulkSimulation=t.getEstimatedFeeFromBulkSimulation;exports.getEstimatedFeeFromSimulationAndRespectWatermarkFee=t.getEstimatedFeeFromSimulationAndRespectWatermarkFee;exports.getPayloadFromTransaction=t.getPayloadFromTransaction;exports.getWatermarkedMaxFeeTotal=t.getWatermarkedMaxFeeTotal;exports.isFRI=t.isFRI;exports.isWEI=t.isWEI;exports.multiplyBigIntByFloat=t.multiplyBigIntByFloat;exports.toMax=t.toMax;exports.tokensRequireTxV3Support=t.tokensRequireTxV3Support;exports.unitToFeeTokenAddress=t.unitToFeeTokenAddress;exports.EventsBySelector=j.EventsBySelector;exports.findTransfersAndApprovals=j.findTransfersAndApprovals;exports.getPrettyRpcError=qe.getPrettyRpcError;exports.getSimulationTxVersionFromFeeToken=B.getSimulationTxVersionFromFeeToken;exports.getTxVersionFromFeeToken=B.getTxVersionFromFeeToken;exports.getTxVersionFromFeeTokenForDeclareContract=B.getTxVersionFromFeeTokenForDeclareContract;exports.TransactionReviewServiceWeb=Re.TransactionReviewServiceWeb;exports.transactionReviewWarningSchema=fe.transactionReviewWarningSchema;exports.apiTransactionReviewActivityType=be.apiTransactionReviewActivityType;exports.denyTxV3=K.denyTxV3;exports.txVersionSchema=K.txVersionSchema;exports.classHashSupportsTxV3=X.classHashSupportsTxV3;exports.feeTokenNeedsTxV3Support=X.feeTokenNeedsTxV3Support;exports.formatAddress=Ne.formatAddress;exports.ensureArray=Pe.ensureArray;exports.generateAvatarImage=k.generateAvatarImage;exports.getColor=k.getColor;exports.getNetworkAccountImageUrl=k.getNetworkAccountImageUrl;exports.stripAddressZeroPadding=k.stripAddressZeroPadding;exports.decodeBase58=E.decodeBase58;exports.decodeBase58Array=E.decodeBase58Array;exports.encodeBase58=E.encodeBase58;exports.encodeBase58Array=E.encodeBase58Array;exports.bigNumberSchema=Fe.bigNumberSchema;exports.daysBetween=Ie.daysBetween;exports.isFeatureEnabled=Be.isFeatureEnabled;exports.hexSchema=$.hexSchema;exports.hexSchemaBase=$.hexSchemaBase;exports.id=we.id;exports.getInitials=_e.getInitials;exports.isContractDeployed=Oe.isContractDeployed;exports.nonNullable=He.nonNullable;exports.isAllowedAddressHexInputValue=Le.isAllowedAddressHexInputValue;exports.isAllowedNumericInputValue=Ve.isAllowedNumericInputValue;exports.isNumeric=xe.isNumeric;exports.prettifyCurrencyNumber=D.prettifyCurrencyNumber;exports.prettifyNumber=D.prettifyNumber;exports.prettifyNumberConfig=D.prettifyNumberConfig;exports.prettifyTokenNumber=D.prettifyTokenNumber;exports.getUint256CalldataFromBN=Y.getUint256CalldataFromBN;exports.parseAmountValue=Y.parseAmountValue;exports.pluralise=Me.pluralise;exports.readFileAsString=We.readFileAsString;exports.booleanToStringSchema=v.booleanToStringSchema;exports.createSchemaWithWarnings=v.createSchemaWithWarnings;exports.safeParseAndWarn=v.safeParseAndWarn;exports.stringToBooleanSchema=v.stringToBooleanSchema;exports.addOwnersCalldataSchema=r.addOwnersCalldataSchema;exports.addPluginCalldataSchema=r.addPluginCalldataSchema;exports.bigNumberishSchema=r.bigNumberishSchema;exports.callDetailsSchema=r.callDetailsSchema;exports.callSchema=r.callSchema;exports.calldataSchema=r.calldataSchema;exports.changeGuardianCalldataSchema=r.changeGuardianCalldataSchema;exports.changeThresholdCalldataSchema=r.changeThresholdCalldataSchema;exports.escapeGuardianCalldataSchema=r.escapeGuardianCalldataSchema;exports.executeOnPluginCalldataSchema=r.executeOnPluginCalldataSchema;exports.feltSchema=r.feltSchema;exports.looseCalldataSchema=r.looseCalldataSchema;exports.multiTypeSchema=r.multiTypeSchema;exports.rawArgsArraySchema=r.rawArgsArraySchema;exports.rawArgsObjectSchema=r.rawArgsObjectSchema;exports.rawArgsSchema=r.rawArgsSchema;exports.removeOwnersCalldataSchema=r.removeOwnersCalldataSchema;exports.removePluginCalldataSchema=r.removePluginCalldataSchema;exports.replaceSignerCalldataSchema=r.replaceSignerCalldataSchema;exports.transferCalldataSchema=r.transferCalldataSchema;exports.uint256Schema=r.uint256Schema;exports.abiEntrySchema=e.abiEntrySchema;exports.abiSchema=e.abiSchema;exports.builtinsSchema=e.builtinsSchema;exports.byteCodeSchema=e.byteCodeSchema;exports.cairo1EventSchema=e.cairo1EventSchema;exports.cairoAssemblySchema=e.cairoAssemblySchema;exports.compiledContractClassSchema=e.compiledContractClassSchema;exports.compiledSierraCasmSchema=e.compiledSierraCasmSchema;exports.compiledSierraSchema=e.compiledSierraSchema;exports.compressedProgramSchema=e.compressedProgramSchema;exports.contractEntryPointFieldsSchema=e.contractEntryPointFieldsSchema;exports.entryPointsByTypeSchema=e.entryPointsByTypeSchema;exports.eventAbiSchema=e.eventAbiSchema;exports.eventEntrySchema=e.eventEntrySchema;exports.functionAbiSchema=e.functionAbiSchema;exports.functionAbiTypeSchema=e.functionAbiTypeSchema;exports.legacyContractClassSchema=e.legacyContractClassSchema;exports.legacyEventSchema=e.legacyEventSchema;exports.programSchema=e.programSchema;exports.pythonicHintsSchema=e.pythonicHintsSchema;exports.sierraContractEntryPointFieldsSchema=e.sierraContractEntryPointFieldsSchema;exports.sierraEntryPointsByTypeSchema=e.sierraEntryPointsByTypeSchema;exports.sierraProgramDebugInfoSchema=e.sierraProgramDebugInfoSchema;exports.structAbiSchema=e.structAbiSchema;exports.entryPointToHumanReadable=Ue.entryPointToHumanReadable;exports.urlWithQuery=Ge.urlWithQuery;exports.voidify=ze.voidify;exports.bipsToPercent=je.bipsToPercent;
|
package/dist/index.js
CHANGED
|
@@ -5,7 +5,7 @@ import { isAccountV4 as i, isAccountV5 as S, isAccountV6 as d } from "./src/acco
|
|
|
5
5
|
import { preferencesEndpointPayload as l, preferencesSchema as h } from "./src/account/preferences.model.js";
|
|
6
6
|
import { argentBackendNetworkIdSchema as u, argentNetworkIdSchema as A, isArgentBackendNetworkId as x, isArgentNetworkId as T } from "./src/backend/schema.js";
|
|
7
7
|
import { CacheService as C } from "./src/cache/CacheService.js";
|
|
8
|
-
import { addressOrEmptyUndefinedSchema as y, addressSchema as E, addressSchemaArgentBackend as D, addressSchemaBase as R, addressSchemaLooseLength as v, addressSchemaStrictLength as N, formatFullAddress as F, formatTruncatedAddress as P, formatTruncatedSignerKey as b, formatTruncatedString as I, includesAddress as B, isAddress as _, isEqualAddress as w, isValidAddress as H, isZeroAddress as
|
|
8
|
+
import { addressOrEmptyUndefinedSchema as y, addressSchema as E, addressSchemaArgentBackend as D, addressSchemaBase as R, addressSchemaLooseLength as v, addressSchemaStrictLength as N, formatFullAddress as F, formatTruncatedAddress as P, formatTruncatedSignerKey as b, formatTruncatedString as I, includesAddress as B, isAddress as _, isEqualAddress as w, isValidAddress as H, isZeroAddress as O, normalizeAddress as L, validChecksumAddressSchema as V, validateAddressRangeSchema as M } from "./src/chains/starknet/address.js";
|
|
9
9
|
import { addressOrDomainInputSchema as U, addressOrDomainSchema as q, isEqualStarknetDomainName as G, isStarknetDomainName as z, normalizeAddressOrDomain as K, starknetDomainNameSchema as j } from "./src/chains/starknet/addressDomain.js";
|
|
10
10
|
import { addressInputCharactersAndLengthSchema as Y, addressInputSchema as Z } from "./src/chains/starknet/addressInput.js";
|
|
11
11
|
import { argentNameSchema as J, isArgentName as $, isEqualArgentName as ee, normalizeArgentName as re } from "./src/chains/starknet/argentName.js";
|
|
@@ -17,7 +17,7 @@ import { getChainIdFromNetworkId as Ce } from "./src/chains/starknet/network.js"
|
|
|
17
17
|
import { StarknetAddressService as ye } from "./src/chains/starknet/services/address/StarknetAddressService.js";
|
|
18
18
|
import { ARGENT_ACCOUNT_CONTRACT_CLASS_HASHES as De, ARGENT_MULTISIG_CONTRACT_CLASS_HASHES as Re, C0_PROXY_CONTRACT_CLASS_HASHES as ve } from "./src/chains/starknet/services/deploymentData/constants.js";
|
|
19
19
|
import { constructorCallDataSchemaC0 as Fe, constructorCallDataSchemaC1V1 as Pe, implementationSchema as be } from "./src/chains/starknet/services/deploymentData/deploymentData.schema.js";
|
|
20
|
-
import { buildConstructorCalldata as Be, findImplementationForAccount as _e, getAccountContractAddress as we, getAccountDeploymentPayload as He, isEqualImplementation as
|
|
20
|
+
import { buildConstructorCalldata as Be, findImplementationForAccount as _e, getAccountContractAddress as we, getAccountDeploymentPayload as He, isEqualImplementation as Oe } from "./src/chains/starknet/services/deploymentData/findImplementationForAccount.js";
|
|
21
21
|
import { getArgentAccountClassHashes as Ve, getArgentAccountClassHashesWithTxV3Support as Me, getArgentAccountWithMultiSignerClassHashes as We, getLastCairo0ArgentAccountClassHash as Ue, getLatestArgentAccountClassHash as qe, getLatestArgentMultisigClassHash as Ge, getLatestLedgerAccountClassHash as ze, getLedgerAccountClassHashes as Ke } from "./src/chains/starknet/services/deploymentData/getAccountClassHash.js";
|
|
22
22
|
import { isEqualStarknetId as Xe, isStarknetId as Ye, normalizeStarknetId as Ze, starknetIdSchema as Qe } from "./src/chains/starknet/starknetId.js";
|
|
23
23
|
import { DateService as $e } from "./src/http/DateService.js";
|
|
@@ -33,71 +33,72 @@ import { getDapplandLinkForDapp as yr, getDapplandUrlForDapp as Er } from "./src
|
|
|
33
33
|
import { ResolveNameService as Rr } from "./src/nameResolution/ResolveNameService.js";
|
|
34
34
|
import { nameProviderResolutionSchema as Nr, nameResolutionAddressSchema as Fr, nameResolutionAddressesSchema as Pr, nameResolutionStarknetIdSchema as br, nameResolutionStarknetIdsSchema as Ir, providersNamesSchema as Br } from "./src/nameResolution/schema.js";
|
|
35
35
|
import { BackendNftService as wr } from "./src/nfts/BackendNftService.js";
|
|
36
|
-
import { equalNft as
|
|
36
|
+
import { equalNft as Or, getNftPicture as Lr } from "./src/nfts/utils.js";
|
|
37
37
|
import { OnchainRecoveryService as Mr } from "./src/onchainRecovery/OnchainRecoveryService.js";
|
|
38
38
|
import { RecoveryStatusEnum as Ur, StartOnchainRecoveryErrorStatusEnum as qr, activeOnchainRecoverySchema as Gr, onchainRecoverySchema as zr, recoveryBaseSchema as Kr, recoveryBodySchema as jr, recoveryStatusSchema as Xr, startOnchainRecoveryErrorSchema as Yr, startOnchainRecoveryErrorStatusSchema as Zr, startOnchainRecoverySchema as Qr } from "./src/onchainRecovery/schema.js";
|
|
39
39
|
import { isBraveBrowser as $r } from "./src/platform/isBraveBrowser.js";
|
|
40
40
|
import { getUAParserResult as ra, isBrowser as aa, isChromeBrowser as ta, isEdgeBrowser as oa, isFirefoxBrowser as ma, isSafariBrowser as na } from "./src/platform/isBrowser.js";
|
|
41
41
|
import { seedphraseSchema as sa } from "./src/signer/seedphrase.js";
|
|
42
42
|
import { MultiSigner as Sa, getSignerForMultiSigner as da } from "./src/signer/multisigner.js";
|
|
43
|
-
import {
|
|
44
|
-
import {
|
|
45
|
-
import {
|
|
46
|
-
import {
|
|
47
|
-
import {
|
|
48
|
-
import {
|
|
49
|
-
import {
|
|
50
|
-
import {
|
|
51
|
-
import {
|
|
52
|
-
import {
|
|
53
|
-
import {
|
|
54
|
-
import {
|
|
55
|
-
import {
|
|
56
|
-
import {
|
|
57
|
-
import {
|
|
58
|
-
import {
|
|
59
|
-
import {
|
|
60
|
-
import {
|
|
61
|
-
import {
|
|
62
|
-
import {
|
|
63
|
-
import {
|
|
64
|
-
import {
|
|
65
|
-
import {
|
|
66
|
-
import {
|
|
67
|
-
import {
|
|
68
|
-
import {
|
|
69
|
-
import {
|
|
70
|
-
import {
|
|
71
|
-
import {
|
|
72
|
-
import {
|
|
73
|
-
import {
|
|
74
|
-
import {
|
|
75
|
-
import {
|
|
76
|
-
import {
|
|
77
|
-
import {
|
|
78
|
-
import {
|
|
79
|
-
import {
|
|
80
|
-
import {
|
|
81
|
-
import {
|
|
82
|
-
import {
|
|
83
|
-
import {
|
|
84
|
-
import {
|
|
85
|
-
import {
|
|
86
|
-
import {
|
|
87
|
-
import {
|
|
88
|
-
import {
|
|
89
|
-
import {
|
|
90
|
-
import {
|
|
91
|
-
import {
|
|
92
|
-
import {
|
|
93
|
-
import {
|
|
94
|
-
import {
|
|
95
|
-
import {
|
|
96
|
-
import {
|
|
97
|
-
import {
|
|
98
|
-
import {
|
|
99
|
-
import {
|
|
100
|
-
import {
|
|
43
|
+
import { mergeOwnerGuardianSignatures as la } from "./src/signer/mergeOwnerGuardianSignatures.js";
|
|
44
|
+
import { buildBuyCalldataResponseSchema as fa, buildBuyCalldataSchema as ua, investmentMetaSchema as Aa, investmentSchema as xa, investmentsResponseSchema as Ta, lendingInvestmentSchema as ga, stakingInvestmentSchema as Ca, strkDelegatedStakingInvestmentSchema as ka } from "./src/staking/schema.js";
|
|
45
|
+
import { getTokenBalance as Ea, getTokens as Da, getTokensBalances as Ra, useToken as va } from "./src/tokens/balances.js";
|
|
46
|
+
import { DEFAULT_TOKEN_DECIMALS as Fa } from "./src/tokens/constants.js";
|
|
47
|
+
import { convertTokenAmountToCurrencyValue as ba } from "./src/tokens/convertTokenAmountToCurrencyValue.js";
|
|
48
|
+
import { convertTokenUnitAmountWithDecimals as Ba } from "./src/tokens/convertTokenUnitAmountWithDecimals.js";
|
|
49
|
+
import { ensureDecimals as wa } from "./src/tokens/ensureDecimals.js";
|
|
50
|
+
import { isUnlimitedAmount as Oa } from "./src/tokens/isUnlimitedAmount.js";
|
|
51
|
+
import { prettifyCurrencyValue as Va } from "./src/tokens/prettifyCurrencyValue.js";
|
|
52
|
+
import { PRETTY_UNLIMITED as Wa, prettifyTokenAmount as Ua } from "./src/tokens/prettifyTokenAmount.js";
|
|
53
|
+
import { getCurrencySymbol as Ga } from "./src/tokens/getCurrencySymbol.js";
|
|
54
|
+
import { TokenServiceWeb as Ka } from "./src/tokens/service/implementation.js";
|
|
55
|
+
import { TOKEN_ERROR_MESSAGES as Xa, TokenError as Ya } from "./src/tokens/service/tokenError.js";
|
|
56
|
+
import { apiAccountTokenBalancesSchema as Qa, apiAirdropSchema as Ja, apiCollateralizedDebtPositionSchema as $a, apiCollateralizedDebtPositionsSchema as et, apiConcentratedLiquidityPositionSchema as rt, apiConcentratedLiquidityPositionsSchema as at, apiDefiDecompositionProduct as tt, apiDefiDecompositionProducts as ot, apiDefiDecompositionSchema as mt, apiDefiDecompositionToken as nt, apiDefiPositionsSchema as ct, apiDelegatedTokensArraySchema as st, apiDelegatedTokensSchema as it, apiPriceDataResponseSchema as St, apiPriceDetailsSchema as dt, apiStakingPositionSchema as pt, apiStakingPositionsSchema as lt, apiTokenInfoResponseSchema as ht, apiTokenInfoSchema as ft, apiTokensInfoResponseSchema as ut, apiUnclaimedRewardsSchema as At } from "./src/tokens/service/types/backend.model.js";
|
|
57
|
+
import { collateralizedDebtGroupSchema as Tt, collateralizedDebtPositionSchema as gt, collateralizedDebtPositionsSchema as Ct, concentratedLiquidityPositionSchema as kt, concentratedLiquidityPositionsSchema as yt, defiDappsProductsSchema as Et, defiPositionSchema as Dt, defiProductSchema as Rt, defiProductsSchema as vt, delegatedTokensArraySchema as Nt, delegatedTokensSchema as Ft, productGroupsSchema as Pt } from "./src/tokens/service/types/defiPosition.model.js";
|
|
58
|
+
import { defiPositionTypeSchema as It } from "./src/tokens/service/types/defiPositionType.model.js";
|
|
59
|
+
import { airdropSchema as _t, unclaimedRewardsSchema as wt } from "./src/tokens/service/types/unclaimedRewards.model.js";
|
|
60
|
+
import { webBaseTokenSchema as Ot, webBaseTokenWithBalanceSchema as Lt, webTokenInfoDetailsSchema as Vt, webTokenPriceDetailsSchema as Mt, webTokenSchema as Wt, webTokenWithBalanceAndPriceSchema as Ut, webTokenWithBalanceSchema as qt, webTokenWithPriceSchema as Gt, webTokensWithBalanceAndPriceSchema as zt } from "./src/tokens/service/types/webToken.model.js";
|
|
61
|
+
import { inputAmountSchema as jt, isValidInputAmount as Xt, parseAmount as Yt } from "./src/transactions/amount.js";
|
|
62
|
+
import { erc20TransferTransaction as Qt, erc721SafeTransferFromTransaction as Jt, erc721TransferFromTransaction as $t } from "./src/transactions/buildTransactions.js";
|
|
63
|
+
import { getMessageFromTrpcError as ro, trpcErrorSchema as ao } from "./src/transactions/errors.js";
|
|
64
|
+
import { FEE_OVERHEAD as oo, argentMaxFee as mo, modifySnjsFeeOverhead as no } from "./src/transactions/estimate/argentMaxFee.js";
|
|
65
|
+
import { ESTIMATE_ERROR_MESSAGES as so, EstimateError as io } from "./src/transactions/estimate/error.js";
|
|
66
|
+
import { transactionReviewTransactionsSchema as po } from "./src/transactions/estimate/model.js";
|
|
67
|
+
import { buildDummyTx as ho, calculateCubeRootAdjustment as fo, calculateNonLinearAdjustment as uo, calculateSqrtAdjustment as Ao, castFeeEstimation as xo, estimatedFeeToMaxFeeTotal as To, estimatedFeeToMaxResourceBounds as go, estimatedFeeToTotal as Co, estimatedFeesToMaxFeeTotal as ko, estimatedFeesToTotal as yo, getEstimatedFeeFromBulkSimulation as Eo, getEstimatedFeeFromSimulationAndRespectWatermarkFee as Do, getPayloadFromTransaction as Ro, getWatermarkedMaxFeeTotal as vo, isFRI as No, isWEI as Fo, multiplyBigIntByFloat as Po, toMax as bo, tokensRequireTxV3Support as Io, unitToFeeTokenAddress as Bo } from "./src/transactions/estimate/utils.js";
|
|
68
|
+
import { EventsBySelector as wo, findTransfersAndApprovals as Ho } from "./src/transactions/findTransfersAndApprovals.js";
|
|
69
|
+
import { getPrettyRpcError as Lo } from "./src/transactions/getPrettyRcpError.js";
|
|
70
|
+
import { getSimulationTxVersionFromFeeToken as Mo, getTxVersionFromFeeToken as Wo, getTxVersionFromFeeTokenForDeclareContract as Uo } from "./src/transactions/getTransactionVersion.js";
|
|
71
|
+
import { TransactionReviewServiceWeb as Go } from "./src/transactions/service/implementation.js";
|
|
72
|
+
import { transactionReviewWarningSchema as Ko } from "./src/transactions/service/types.js";
|
|
73
|
+
import { apiTransactionReviewActivityType as Xo } from "./src/transactions/transactionReviewTypes.js";
|
|
74
|
+
import { denyTxV3 as Zo, txVersionSchema as Qo } from "./src/transactions/transactionVersion.js";
|
|
75
|
+
import { classHashSupportsTxV3 as $o, feeTokenNeedsTxV3Support as em } from "./src/transactions/txv3.js";
|
|
76
|
+
import { formatAddress as am } from "./src/utils/address.js";
|
|
77
|
+
import { ensureArray as om } from "./src/utils/arrays.js";
|
|
78
|
+
import { generateAvatarImage as nm, getColor as cm, getNetworkAccountImageUrl as sm, stripAddressZeroPadding as im } from "./src/utils/avatarImage.js";
|
|
79
|
+
import { decodeBase58 as dm, decodeBase58Array as pm, encodeBase58 as lm, encodeBase58Array as hm } from "./src/utils/base58.js";
|
|
80
|
+
import { bigNumberSchema as um } from "./src/utils/bigNumber.js";
|
|
81
|
+
import { daysBetween as xm } from "./src/utils/daysBetween.js";
|
|
82
|
+
import { isFeatureEnabled as gm } from "./src/utils/env.js";
|
|
83
|
+
import { hexSchema as km, hexSchemaBase as ym } from "./src/utils/hex.js";
|
|
84
|
+
import { id as Dm } from "./src/utils/id.js";
|
|
85
|
+
import { getInitials as vm } from "./src/utils/initials.js";
|
|
86
|
+
import { isContractDeployed as Fm } from "./src/utils/isContractDeployed.js";
|
|
87
|
+
import { nonNullable as bm } from "./src/utils/nonNullable.js";
|
|
88
|
+
import { isAllowedAddressHexInputValue as Bm } from "./src/utils/number/isAllowedAddressHexInputValue.js";
|
|
89
|
+
import { isAllowedNumericInputValue as wm } from "./src/utils/number/isAllowedNumericInputValue.js";
|
|
90
|
+
import { isNumeric as Om } from "./src/utils/number/isNumeric.js";
|
|
91
|
+
import { prettifyCurrencyNumber as Vm, prettifyNumber as Mm, prettifyNumberConfig as Wm, prettifyTokenNumber as Um } from "./src/utils/number/prettifyNumber.js";
|
|
92
|
+
import { getUint256CalldataFromBN as Gm, parseAmountValue as zm } from "./src/utils/parseAmount.js";
|
|
93
|
+
import { pluralise as jm } from "./src/utils/pluralise.js";
|
|
94
|
+
import { readFileAsString as Ym } from "./src/utils/readFileAsString.js";
|
|
95
|
+
import { booleanToStringSchema as Qm, createSchemaWithWarnings as Jm, safeParseAndWarn as $m, stringToBooleanSchema as en } from "./src/utils/schemas.js";
|
|
96
|
+
import { addOwnersCalldataSchema as an, addPluginCalldataSchema as tn, bigNumberishSchema as on, callDetailsSchema as mn, callSchema as nn, calldataSchema as cn, changeGuardianCalldataSchema as sn, changeThresholdCalldataSchema as Sn, escapeGuardianCalldataSchema as dn, executeOnPluginCalldataSchema as pn, feltSchema as ln, looseCalldataSchema as hn, multiTypeSchema as fn, rawArgsArraySchema as un, rawArgsObjectSchema as An, rawArgsSchema as xn, removeOwnersCalldataSchema as Tn, removePluginCalldataSchema as gn, replaceSignerCalldataSchema as Cn, transferCalldataSchema as kn, uint256Schema as yn } from "./src/utils/starknet/starknet.js";
|
|
97
|
+
import { abiEntrySchema as Dn, abiSchema as Rn, builtinsSchema as vn, byteCodeSchema as Nn, cairo1EventSchema as Fn, cairoAssemblySchema as Pn, compiledContractClassSchema as bn, compiledSierraCasmSchema as In, compiledSierraSchema as Bn, compressedProgramSchema as _n, contractEntryPointFieldsSchema as wn, entryPointsByTypeSchema as Hn, eventAbiSchema as On, eventEntrySchema as Ln, functionAbiSchema as Vn, functionAbiTypeSchema as Mn, legacyContractClassSchema as Wn, legacyEventSchema as Un, programSchema as qn, pythonicHintsSchema as Gn, sierraContractEntryPointFieldsSchema as zn, sierraEntryPointsByTypeSchema as Kn, sierraProgramDebugInfoSchema as jn, structAbiSchema as Xn } from "./src/utils/starknet/starknetSchemas.js";
|
|
98
|
+
import { entryPointToHumanReadable as Zn } from "./src/utils/transactions.js";
|
|
99
|
+
import { urlWithQuery as Jn } from "./src/utils/url/urlWithQuery.js";
|
|
100
|
+
import { voidify as ec } from "./src/utils/voidify.js";
|
|
101
|
+
import { bipsToPercent as ac } from "./src/utils/bips.js";
|
|
101
102
|
export {
|
|
102
103
|
De as ARGENT_ACCOUNT_CONTRACT_CLASS_HASHES,
|
|
103
104
|
Re as ARGENT_MULTISIG_CONTRACT_CLASS_HASHES,
|
|
@@ -108,20 +109,20 @@ export {
|
|
|
108
109
|
t as BaseError,
|
|
109
110
|
ve as C0_PROXY_CONTRACT_CLASS_HASHES,
|
|
110
111
|
C as CacheService,
|
|
111
|
-
|
|
112
|
+
Fa as DEFAULT_TOKEN_DECIMALS,
|
|
112
113
|
$e as DateService,
|
|
113
|
-
|
|
114
|
+
so as ESTIMATE_ERROR_MESSAGES,
|
|
114
115
|
me as ETH_TOKEN_ADDRESS,
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
116
|
+
io as EstimateError,
|
|
117
|
+
wo as EventsBySelector,
|
|
118
|
+
oo as FEE_OVERHEAD,
|
|
118
119
|
tr as HTTPService,
|
|
119
120
|
mr as HTTP_ERROR_MESSAGE,
|
|
120
121
|
rr as HttpError,
|
|
121
122
|
ur as KnownDappsBackendService,
|
|
122
123
|
Sa as MultiSigner,
|
|
123
124
|
Mr as OnchainRecoveryService,
|
|
124
|
-
|
|
125
|
+
Wa as PRETTY_UNLIMITED,
|
|
125
126
|
Ur as RecoveryStatusEnum,
|
|
126
127
|
Rr as ResolveNameService,
|
|
127
128
|
ne as STANDARD_DEVNET_ACCOUNT_CLASS_HASH,
|
|
@@ -129,19 +130,19 @@ export {
|
|
|
129
130
|
cr as SWRService,
|
|
130
131
|
ye as StarknetAddressService,
|
|
131
132
|
qr as StartOnchainRecoveryErrorStatusEnum,
|
|
132
|
-
|
|
133
|
+
Xa as TOKEN_ERROR_MESSAGES,
|
|
133
134
|
se as TXV1_ACCOUNT_CLASS_HASH,
|
|
134
135
|
ie as TXV1_MULTISIG_CLASS_HASH,
|
|
135
136
|
Se as TXV3_ACCOUNT_CLASS_HASH,
|
|
136
137
|
de as TXV3_MULTISIG_CLASS_HASH,
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
138
|
+
Ya as TokenError,
|
|
139
|
+
Ka as TokenServiceWeb,
|
|
140
|
+
Go as TransactionReviewServiceWeb,
|
|
141
|
+
Dn as abiEntrySchema,
|
|
142
|
+
Rn as abiSchema,
|
|
142
143
|
Gr as activeOnchainRecoverySchema,
|
|
143
|
-
|
|
144
|
-
|
|
144
|
+
an as addOwnersCalldataSchema,
|
|
145
|
+
tn as addPluginCalldataSchema,
|
|
145
146
|
Y as addressInputCharactersAndLengthSchema,
|
|
146
147
|
Z as addressInputSchema,
|
|
147
148
|
U as addressOrDomainInputSchema,
|
|
@@ -152,119 +153,119 @@ export {
|
|
|
152
153
|
R as addressSchemaBase,
|
|
153
154
|
v as addressSchemaLooseLength,
|
|
154
155
|
N as addressSchemaStrictLength,
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
156
|
+
_t as airdropSchema,
|
|
157
|
+
Qa as apiAccountTokenBalancesSchema,
|
|
158
|
+
Ja as apiAirdropSchema,
|
|
159
|
+
$a as apiCollateralizedDebtPositionSchema,
|
|
160
|
+
et as apiCollateralizedDebtPositionsSchema,
|
|
161
|
+
rt as apiConcentratedLiquidityPositionSchema,
|
|
162
|
+
at as apiConcentratedLiquidityPositionsSchema,
|
|
163
|
+
tt as apiDefiDecompositionProduct,
|
|
164
|
+
ot as apiDefiDecompositionProducts,
|
|
165
|
+
mt as apiDefiDecompositionSchema,
|
|
166
|
+
nt as apiDefiDecompositionToken,
|
|
167
|
+
ct as apiDefiPositionsSchema,
|
|
168
|
+
st as apiDelegatedTokensArraySchema,
|
|
169
|
+
it as apiDelegatedTokensSchema,
|
|
170
|
+
St as apiPriceDataResponseSchema,
|
|
171
|
+
dt as apiPriceDetailsSchema,
|
|
172
|
+
pt as apiStakingPositionSchema,
|
|
173
|
+
lt as apiStakingPositionsSchema,
|
|
174
|
+
ht as apiTokenInfoResponseSchema,
|
|
175
|
+
ft as apiTokenInfoSchema,
|
|
176
|
+
ut as apiTokensInfoResponseSchema,
|
|
177
|
+
Xo as apiTransactionReviewActivityType,
|
|
178
|
+
At as apiUnclaimedRewardsSchema,
|
|
178
179
|
le as apiWalletResponseSchema,
|
|
179
180
|
u as argentBackendNetworkIdSchema,
|
|
180
|
-
|
|
181
|
+
mo as argentMaxFee,
|
|
181
182
|
J as argentNameSchema,
|
|
182
183
|
A as argentNetworkIdSchema,
|
|
183
184
|
e as bigDecimal,
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
185
|
+
um as bigNumberSchema,
|
|
186
|
+
on as bigNumberishSchema,
|
|
187
|
+
ac as bipsToPercent,
|
|
188
|
+
Qm as booleanToStringSchema,
|
|
189
|
+
fa as buildBuyCalldataResponseSchema,
|
|
190
|
+
ua as buildBuyCalldataSchema,
|
|
190
191
|
Be as buildConstructorCalldata,
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
192
|
+
ho as buildDummyTx,
|
|
193
|
+
vn as builtinsSchema,
|
|
194
|
+
Nn as byteCodeSchema,
|
|
195
|
+
Fn as cairo1EventSchema,
|
|
196
|
+
Pn as cairoAssemblySchema,
|
|
196
197
|
te as cairoVersionSchema,
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
198
|
+
fo as calculateCubeRootAdjustment,
|
|
199
|
+
uo as calculateNonLinearAdjustment,
|
|
200
|
+
Ao as calculateSqrtAdjustment,
|
|
201
|
+
mn as callDetailsSchema,
|
|
202
|
+
nn as callSchema,
|
|
203
|
+
cn as calldataSchema,
|
|
204
|
+
xo as castFeeEstimation,
|
|
205
|
+
sn as changeGuardianCalldataSchema,
|
|
206
|
+
Sn as changeThresholdCalldataSchema,
|
|
207
|
+
$o as classHashSupportsTxV3,
|
|
208
|
+
Tt as collateralizedDebtGroupSchema,
|
|
209
|
+
gt as collateralizedDebtPositionSchema,
|
|
210
|
+
Ct as collateralizedDebtPositionsSchema,
|
|
211
|
+
bn as compiledContractClassSchema,
|
|
212
|
+
In as compiledSierraCasmSchema,
|
|
213
|
+
Bn as compiledSierraSchema,
|
|
214
|
+
_n as compressedProgramSchema,
|
|
215
|
+
kt as concentratedLiquidityPositionSchema,
|
|
216
|
+
yt as concentratedLiquidityPositionsSchema,
|
|
216
217
|
Fe as constructorCallDataSchemaC0,
|
|
217
218
|
Pe as constructorCallDataSchemaC1V1,
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
219
|
+
wn as contractEntryPointFieldsSchema,
|
|
220
|
+
ba as convertTokenAmountToCurrencyValue,
|
|
221
|
+
Ba as convertTokenUnitAmountWithDecimals,
|
|
222
|
+
Jm as createSchemaWithWarnings,
|
|
222
223
|
xr as dappContractSchema,
|
|
223
224
|
Tr as dappLinkSchema,
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
225
|
+
xm as daysBetween,
|
|
226
|
+
dm as decodeBase58,
|
|
227
|
+
pm as decodeBase58Array,
|
|
228
|
+
Et as defiDappsProductsSchema,
|
|
229
|
+
Dt as defiPositionSchema,
|
|
230
|
+
It as defiPositionTypeSchema,
|
|
231
|
+
Rt as defiProductSchema,
|
|
232
|
+
vt as defiProductsSchema,
|
|
233
|
+
Nt as delegatedTokensArraySchema,
|
|
234
|
+
Ft as delegatedTokensSchema,
|
|
235
|
+
Zo as denyTxV3,
|
|
236
|
+
lm as encodeBase58,
|
|
237
|
+
hm as encodeBase58Array,
|
|
238
|
+
om as ensureArray,
|
|
239
|
+
wa as ensureDecimals,
|
|
240
|
+
Zn as entryPointToHumanReadable,
|
|
241
|
+
Hn as entryPointsByTypeSchema,
|
|
242
|
+
Or as equalNft,
|
|
243
|
+
Qt as erc20TransferTransaction,
|
|
244
|
+
Jt as erc721SafeTransferFromTransaction,
|
|
245
|
+
$t as erc721TransferFromTransaction,
|
|
246
|
+
dn as escapeGuardianCalldataSchema,
|
|
247
|
+
To as estimatedFeeToMaxFeeTotal,
|
|
248
|
+
go as estimatedFeeToMaxResourceBounds,
|
|
249
|
+
Co as estimatedFeeToTotal,
|
|
250
|
+
ko as estimatedFeesToMaxFeeTotal,
|
|
251
|
+
yo as estimatedFeesToTotal,
|
|
252
|
+
On as eventAbiSchema,
|
|
253
|
+
Ln as eventEntrySchema,
|
|
254
|
+
pn as executeOnPluginCalldataSchema,
|
|
255
|
+
em as feeTokenNeedsTxV3Support,
|
|
256
|
+
ln as feltSchema,
|
|
256
257
|
ir as fetchData,
|
|
257
258
|
Sr as fetcherError,
|
|
258
259
|
_e as findImplementationForAccount,
|
|
259
|
-
|
|
260
|
-
|
|
260
|
+
Ho as findTransfersAndApprovals,
|
|
261
|
+
am as formatAddress,
|
|
261
262
|
F as formatFullAddress,
|
|
262
263
|
P as formatTruncatedAddress,
|
|
263
264
|
b as formatTruncatedSignerKey,
|
|
264
265
|
I as formatTruncatedString,
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
266
|
+
Vn as functionAbiSchema,
|
|
267
|
+
Mn as functionAbiTypeSchema,
|
|
268
|
+
nm as generateAvatarImage,
|
|
268
269
|
we as getAccountContractAddress,
|
|
269
270
|
He as getAccountDeploymentPayload,
|
|
270
271
|
he as getAddressFromArgentName,
|
|
@@ -276,158 +277,159 @@ export {
|
|
|
276
277
|
hr as getBackendTimeSeconds,
|
|
277
278
|
Ae as getCallFromStarkName,
|
|
278
279
|
Ce as getChainIdFromNetworkId,
|
|
279
|
-
|
|
280
|
-
|
|
280
|
+
cm as getColor,
|
|
281
|
+
Ga as getCurrencySymbol,
|
|
281
282
|
yr as getDapplandLinkForDapp,
|
|
282
283
|
Er as getDapplandUrlForDapp,
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
284
|
+
Eo as getEstimatedFeeFromBulkSimulation,
|
|
285
|
+
Do as getEstimatedFeeFromSimulationAndRespectWatermarkFee,
|
|
286
|
+
vm as getInitials,
|
|
286
287
|
Ue as getLastCairo0ArgentAccountClassHash,
|
|
287
288
|
qe as getLatestArgentAccountClassHash,
|
|
288
289
|
Ge as getLatestArgentMultisigClassHash,
|
|
289
290
|
ze as getLatestLedgerAccountClassHash,
|
|
290
291
|
Ke as getLedgerAccountClassHashes,
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
292
|
+
ro as getMessageFromTrpcError,
|
|
293
|
+
sm as getNetworkAccountImageUrl,
|
|
294
|
+
Lr as getNftPicture,
|
|
295
|
+
Ro as getPayloadFromTransaction,
|
|
296
|
+
Lo as getPrettyRpcError,
|
|
296
297
|
da as getSignerForMultiSigner,
|
|
297
|
-
|
|
298
|
+
Mo as getSimulationTxVersionFromFeeToken,
|
|
298
299
|
xe as getStarknetIdContractAddressFromNetworkId,
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
300
|
+
Ea as getTokenBalance,
|
|
301
|
+
Da as getTokens,
|
|
302
|
+
Ra as getTokensBalances,
|
|
303
|
+
Wo as getTxVersionFromFeeToken,
|
|
304
|
+
Uo as getTxVersionFromFeeTokenForDeclareContract,
|
|
304
305
|
ra as getUAParserResult,
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
306
|
+
Gm as getUint256CalldataFromBN,
|
|
307
|
+
vo as getWatermarkedMaxFeeTotal,
|
|
308
|
+
km as hexSchema,
|
|
309
|
+
ym as hexSchemaBase,
|
|
310
|
+
Dm as id,
|
|
310
311
|
be as implementationSchema,
|
|
311
312
|
B as includesAddress,
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
313
|
+
jt as inputAmountSchema,
|
|
314
|
+
Aa as investmentMetaSchema,
|
|
315
|
+
xa as investmentSchema,
|
|
316
|
+
Ta as investmentsResponseSchema,
|
|
316
317
|
i as isAccountV4,
|
|
317
318
|
S as isAccountV5,
|
|
318
319
|
d as isAccountV6,
|
|
319
320
|
_ as isAddress,
|
|
320
|
-
|
|
321
|
-
|
|
321
|
+
Bm as isAllowedAddressHexInputValue,
|
|
322
|
+
wm as isAllowedNumericInputValue,
|
|
322
323
|
x as isArgentBackendNetworkId,
|
|
323
324
|
$ as isArgentName,
|
|
324
325
|
T as isArgentNetworkId,
|
|
325
326
|
$r as isBraveBrowser,
|
|
326
327
|
aa as isBrowser,
|
|
327
328
|
ta as isChromeBrowser,
|
|
328
|
-
|
|
329
|
+
Fm as isContractDeployed,
|
|
329
330
|
oa as isEdgeBrowser,
|
|
330
331
|
w as isEqualAddress,
|
|
331
332
|
ee as isEqualArgentName,
|
|
332
|
-
|
|
333
|
+
Oe as isEqualImplementation,
|
|
333
334
|
G as isEqualStarknetDomainName,
|
|
334
335
|
Xe as isEqualStarknetId,
|
|
335
|
-
|
|
336
|
-
|
|
336
|
+
No as isFRI,
|
|
337
|
+
gm as isFeatureEnabled,
|
|
337
338
|
ma as isFirefoxBrowser,
|
|
338
|
-
|
|
339
|
+
Om as isNumeric,
|
|
339
340
|
na as isSafariBrowser,
|
|
340
341
|
z as isStarknetDomainName,
|
|
341
342
|
Ye as isStarknetId,
|
|
342
|
-
|
|
343
|
+
Oa as isUnlimitedAmount,
|
|
343
344
|
H as isValidAddress,
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
345
|
+
Xt as isValidInputAmount,
|
|
346
|
+
Fo as isWEI,
|
|
347
|
+
O as isZeroAddress,
|
|
347
348
|
gr as knownDappSchema,
|
|
348
349
|
Cr as knownDappsSchema,
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
350
|
+
Wn as legacyContractClassSchema,
|
|
351
|
+
Un as legacyEventSchema,
|
|
352
|
+
ga as lendingInvestmentSchema,
|
|
353
|
+
hn as looseCalldataSchema,
|
|
354
|
+
la as mergeOwnerGuardianSignatures,
|
|
355
|
+
no as modifySnjsFeeOverhead,
|
|
356
|
+
fn as multiTypeSchema,
|
|
357
|
+
Po as multiplyBigIntByFloat,
|
|
356
358
|
Nr as nameProviderResolutionSchema,
|
|
357
359
|
Fr as nameResolutionAddressSchema,
|
|
358
360
|
Pr as nameResolutionAddressesSchema,
|
|
359
361
|
br as nameResolutionStarknetIdSchema,
|
|
360
362
|
Ir as nameResolutionStarknetIdsSchema,
|
|
361
|
-
|
|
362
|
-
|
|
363
|
+
bm as nonNullable,
|
|
364
|
+
L as normalizeAddress,
|
|
363
365
|
K as normalizeAddressOrDomain,
|
|
364
366
|
re as normalizeArgentName,
|
|
365
367
|
Ze as normalizeStarknetId,
|
|
366
368
|
zr as onchainRecoverySchema,
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
369
|
+
Yt as parseAmount,
|
|
370
|
+
zm as parseAmountValue,
|
|
371
|
+
jm as pluralise,
|
|
370
372
|
dr as postData,
|
|
371
373
|
l as preferencesEndpointPayload,
|
|
372
374
|
h as preferencesSchema,
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
375
|
+
Vm as prettifyCurrencyNumber,
|
|
376
|
+
Va as prettifyCurrencyValue,
|
|
377
|
+
Mm as prettifyNumber,
|
|
378
|
+
Wm as prettifyNumberConfig,
|
|
379
|
+
Ua as prettifyTokenAmount,
|
|
380
|
+
Um as prettifyTokenNumber,
|
|
381
|
+
Pt as productGroupsSchema,
|
|
382
|
+
qn as programSchema,
|
|
381
383
|
Br as providersNamesSchema,
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
384
|
+
Gn as pythonicHintsSchema,
|
|
385
|
+
un as rawArgsArraySchema,
|
|
386
|
+
An as rawArgsObjectSchema,
|
|
387
|
+
xn as rawArgsSchema,
|
|
388
|
+
Ym as readFileAsString,
|
|
387
389
|
Kr as recoveryBaseSchema,
|
|
388
390
|
jr as recoveryBodySchema,
|
|
389
391
|
Xr as recoveryStatusSchema,
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
392
|
+
Tn as removeOwnersCalldataSchema,
|
|
393
|
+
gn as removePluginCalldataSchema,
|
|
394
|
+
Cn as replaceSignerCalldataSchema,
|
|
395
|
+
$m as safeParseAndWarn,
|
|
394
396
|
sa as seedphraseSchema,
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
397
|
+
zn as sierraContractEntryPointFieldsSchema,
|
|
398
|
+
Kn as sierraEntryPointsByTypeSchema,
|
|
399
|
+
jn as sierraProgramDebugInfoSchema,
|
|
400
|
+
Ca as stakingInvestmentSchema,
|
|
399
401
|
Te as starkNameToCallDataDomain,
|
|
400
402
|
j as starknetDomainNameSchema,
|
|
401
403
|
Qe as starknetIdSchema,
|
|
402
404
|
Yr as startOnchainRecoveryErrorSchema,
|
|
403
405
|
Zr as startOnchainRecoveryErrorStatusSchema,
|
|
404
406
|
Qr as startOnchainRecoverySchema,
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
407
|
+
en as stringToBooleanSchema,
|
|
408
|
+
im as stripAddressZeroPadding,
|
|
409
|
+
ka as strkDelegatedStakingInvestmentSchema,
|
|
410
|
+
Xn as structAbiSchema,
|
|
411
|
+
bo as toMax,
|
|
412
|
+
Io as tokensRequireTxV3Support,
|
|
413
|
+
po as transactionReviewTransactionsSchema,
|
|
414
|
+
Ko as transactionReviewWarningSchema,
|
|
415
|
+
kn as transferCalldataSchema,
|
|
416
|
+
ao as trpcErrorSchema,
|
|
417
|
+
Qo as txVersionSchema,
|
|
418
|
+
yn as uint256Schema,
|
|
419
|
+
wt as unclaimedRewardsSchema,
|
|
420
|
+
Bo as unitToFeeTokenAddress,
|
|
421
|
+
Jn as urlWithQuery,
|
|
422
|
+
va as useToken,
|
|
421
423
|
V as validChecksumAddressSchema,
|
|
422
424
|
M as validateAddressRangeSchema,
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
425
|
+
ec as voidify,
|
|
426
|
+
Ot as webBaseTokenSchema,
|
|
427
|
+
Lt as webBaseTokenWithBalanceSchema,
|
|
428
|
+
Vt as webTokenInfoDetailsSchema,
|
|
429
|
+
Mt as webTokenPriceDetailsSchema,
|
|
430
|
+
Wt as webTokenSchema,
|
|
431
|
+
Ut as webTokenWithBalanceAndPriceSchema,
|
|
432
|
+
qt as webTokenWithBalanceSchema,
|
|
433
|
+
Gt as webTokenWithPriceSchema,
|
|
434
|
+
zt as webTokensWithBalanceAndPriceSchema
|
|
433
435
|
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("lodash-es"),n=require("starknet"),d=require("../chains/starknet/services/deploymentData/getAccountClassHash.cjs"),S=require("../chains/starknet/address.cjs"),m=async({ownerPubKey:e,ownerSignature:t,guardianPubKey:r,guardianSignature:s,classHash:c})=>{const a=l.isEmpty(s);if(p(c)){const i=o(e,t);if(a)return u(i);const g=o(r,s);return u(i,g)}return a?[t].flatMap(n.stark.signatureToDecimalArray):[t,s].flatMap(n.stark.signatureToDecimalArray)},o=(e,t)=>{const r=n.stark.formatSignature(t);return new n.CairoCustomEnum({Starknet:{signer:e,r:r[0],s:r[1]},Secp256k1:void 0,Secp256r1:void 0,Eip191:void 0,Webauthn:void 0})},u=(...e)=>{const t=e.length.toString(),r=n.CallData.compile(e);return[t,...r]},p=e=>d.getArgentAccountWithMultiSignerClassHashes().some(t=>S.isEqualAddress(t,e));exports.mergeOwnerGuardianSignatures=m;
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { Signature } from 'starknet';
|
|
2
|
+
interface MergeOwnerGuardianSignaturesParams {
|
|
3
|
+
ownerPubKey: string;
|
|
4
|
+
ownerSignature: Signature;
|
|
5
|
+
guardianPubKey: string;
|
|
6
|
+
guardianSignature: Signature;
|
|
7
|
+
classHash: string | undefined;
|
|
8
|
+
}
|
|
9
|
+
/**
|
|
10
|
+
* Merges the owner and guardian signatures into a single signature.
|
|
11
|
+
*
|
|
12
|
+
* @param {Object} params - The parameters for merging signatures.
|
|
13
|
+
* @param {string} params.ownerPubKey - The public key of the owner.
|
|
14
|
+
* @param {Signature} params.ownerSignature - The signature of the owner.
|
|
15
|
+
* @param {string} params.guardianPubKey - The public key of the guardian.
|
|
16
|
+
* @param {Signature} params.guardianSignature - The signature of the guardian.
|
|
17
|
+
* @param {string} params.classHash - The class hash of the account.
|
|
18
|
+
* @returns {Promise<Signature>} - A promise that resolves to the merged signature.
|
|
19
|
+
*
|
|
20
|
+
* @remarks
|
|
21
|
+
* - If the guardian signature is empty, it indicates that a co-signer is not required.
|
|
22
|
+
* - If multi-signer support is enabled, the signatures are formatted and prepended with their lengths.
|
|
23
|
+
* - If multi-signer support is not enabled, the signatures are converted to decimal arrays.
|
|
24
|
+
*/
|
|
25
|
+
declare const mergeOwnerGuardianSignatures: ({ ownerPubKey, ownerSignature, guardianPubKey, guardianSignature, classHash, }: MergeOwnerGuardianSignaturesParams) => Promise<Signature>;
|
|
26
|
+
export { mergeOwnerGuardianSignatures };
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { isEmpty as p } from "lodash-es";
|
|
2
|
+
import { stark as i, CairoCustomEnum as g, CallData as l } from "starknet";
|
|
3
|
+
import { getArgentAccountWithMultiSignerClassHashes as S } from "../chains/starknet/services/deploymentData/getAccountClassHash.js";
|
|
4
|
+
import { isEqualAddress as d } from "../chains/starknet/address.js";
|
|
5
|
+
const y = async ({ ownerPubKey: r, ownerSignature: t, guardianPubKey: n, guardianSignature: e, classHash: c }) => {
|
|
6
|
+
const o = p(e);
|
|
7
|
+
if (f(c)) {
|
|
8
|
+
const a = s(r, t);
|
|
9
|
+
if (o)
|
|
10
|
+
return u(a);
|
|
11
|
+
const m = s(n, e);
|
|
12
|
+
return u(a, m);
|
|
13
|
+
}
|
|
14
|
+
return o ? [t].flatMap(i.signatureToDecimalArray) : [t, e].flatMap(i.signatureToDecimalArray);
|
|
15
|
+
}, s = (r, t) => {
|
|
16
|
+
const n = i.formatSignature(t);
|
|
17
|
+
return new g({
|
|
18
|
+
Starknet: { signer: r, r: n[0], s: n[1] },
|
|
19
|
+
Secp256k1: void 0,
|
|
20
|
+
Secp256r1: void 0,
|
|
21
|
+
Eip191: void 0,
|
|
22
|
+
Webauthn: void 0
|
|
23
|
+
});
|
|
24
|
+
}, u = (...r) => {
|
|
25
|
+
const t = r.length.toString(), n = l.compile(r);
|
|
26
|
+
return [t, ...n];
|
|
27
|
+
}, f = (r) => S().some((t) => d(t, r));
|
|
28
|
+
export {
|
|
29
|
+
y as mergeOwnerGuardianSignatures
|
|
30
|
+
};
|
|
@@ -12,15 +12,15 @@ export declare const transactionReviewTransactionsSchema: z.ZodObject<{
|
|
|
12
12
|
salt?: `0x${string}` | undefined;
|
|
13
13
|
signature?: string[] | undefined;
|
|
14
14
|
calldata?: string[] | undefined;
|
|
15
|
-
calls?: Call | Call[] | undefined;
|
|
16
15
|
classHash?: `0x${string}` | undefined;
|
|
16
|
+
calls?: Call | Call[] | undefined;
|
|
17
17
|
}, {
|
|
18
18
|
type?: "DECLARE" | "DEPLOY" | "DEPLOY_ACCOUNT" | "INVOKE" | undefined;
|
|
19
19
|
salt?: string | undefined;
|
|
20
20
|
signature?: string[] | undefined;
|
|
21
21
|
calldata?: string[] | undefined;
|
|
22
|
-
calls?: Call | Call[] | undefined;
|
|
23
22
|
classHash?: string | undefined;
|
|
23
|
+
calls?: Call | Call[] | undefined;
|
|
24
24
|
}>;
|
|
25
25
|
export type TransactionReviewTransactions = z.infer<typeof transactionReviewTransactionsSchema>;
|
|
26
26
|
export type WEI = "WEI" | "wei";
|