@berachain/berajs 0.2.13 → 0.3.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/actions/clients/BeraApolloClient.d.ts.map +1 -1
- package/dist/actions/clients/clientName.d.ts +10 -0
- package/dist/actions/clients/clientName.d.ts.map +1 -0
- package/dist/actions/clients/clientName.unit.test.d.ts +2 -0
- package/dist/actions/clients/clientName.unit.test.d.ts.map +1 -0
- package/dist/actions/clients/exports.d.ts +2 -0
- package/dist/actions/clients/exports.d.ts.map +1 -1
- package/dist/actions/clients/exports.mjs +26 -7
- package/dist/actions/clients/exports.mjs.map +1 -1
- package/dist/actions/clients/fetchBeep.d.ts +2 -2
- package/dist/actions/clients/fetchBeep.d.ts.map +1 -1
- package/dist/actions/clients/fetchEnso.d.ts +17 -0
- package/dist/actions/clients/fetchEnso.d.ts.map +1 -0
- package/dist/actions/clients/fetchLayerzero.d.ts +12 -0
- package/dist/actions/clients/fetchLayerzero.d.ts.map +1 -0
- package/dist/actions/clients/fetchOpenApi.d.ts +4 -1
- package/dist/actions/clients/fetchOpenApi.d.ts.map +1 -1
- package/dist/actions/clients/getApolloClient.d.ts.map +1 -1
- package/dist/actions/dex/aggregators/base.d.ts +30 -5
- package/dist/actions/dex/aggregators/base.d.ts.map +1 -1
- package/dist/actions/dex/aggregators/bex.d.ts +11 -1
- package/dist/actions/dex/aggregators/bex.d.ts.map +1 -1
- package/dist/actions/dex/aggregators/bgt.d.ts +2 -2
- package/dist/actions/dex/aggregators/bgt.d.ts.map +1 -1
- package/dist/actions/dex/aggregators/enso/enso.d.ts.map +1 -1
- package/dist/actions/dex/aggregators/enso/ensoErc4626.d.ts +1 -0
- package/dist/actions/dex/aggregators/enso/ensoErc4626.d.ts.map +1 -1
- package/dist/actions/dex/aggregators/erc4626.d.ts +2 -2
- package/dist/actions/dex/aggregators/erc4626.d.ts.map +1 -1
- package/dist/actions/dex/aggregators/fly.d.ts.map +1 -1
- package/dist/actions/dex/aggregators/haiku.d.ts +7 -1
- package/dist/actions/dex/aggregators/haiku.d.ts.map +1 -1
- package/dist/actions/dex/aggregators/honey.d.ts +2 -2
- package/dist/actions/dex/aggregators/honey.d.ts.map +1 -1
- package/dist/actions/dex/aggregators/kyberswap.d.ts.map +1 -1
- package/dist/actions/dex/aggregators/oogabooga.d.ts.map +1 -1
- package/dist/actions/dex/aggregators/openOcean.d.ts.map +1 -1
- package/dist/actions/dex/aggregators/wbera.d.ts +3 -2
- package/dist/actions/dex/aggregators/wbera.d.ts.map +1 -1
- package/dist/actions/dex/getAllPools.d.ts.map +1 -1
- package/dist/actions/dex/getApiPool.d.ts.map +1 -1
- package/dist/actions/enso/getEnsoUserTokensWithBalances.d.ts.map +1 -1
- package/dist/actions/enso/util.d.ts +1 -6
- package/dist/actions/enso/util.d.ts.map +1 -1
- package/dist/actions/exports.d.ts +3 -5
- package/dist/actions/exports.d.ts.map +1 -1
- package/dist/actions/exports.mjs +33 -64
- package/dist/actions/exports.mjs.map +1 -1
- package/dist/actions/governance/exports.mjs +3 -3
- package/dist/actions/honey/getChartData.d.ts +1 -1
- package/dist/actions/honey/getChartData.d.ts.map +1 -1
- package/dist/actions/honey/getHoney24hVolume.d.ts +2 -2
- package/dist/actions/honey/getHoney24hVolume.d.ts.map +1 -1
- package/dist/actions/honey/getHoneyCollaterals.d.ts +1 -1
- package/dist/actions/honey/getHoneyCollaterals.d.ts.map +1 -1
- package/dist/actions/honey/getHoneyTxns.d.ts +1 -1
- package/dist/actions/honey/getHoneyTxns.d.ts.map +1 -1
- package/dist/actions/pol/getBGTGlobalInfo.d.ts +0 -1
- package/dist/actions/pol/getBGTGlobalInfo.d.ts.map +1 -1
- package/dist/actions/pol/getBeraTokenTotalSupply.d.ts.map +1 -1
- package/dist/actions/pol/getEarnedStakedBeraVault.d.ts +4 -27
- package/dist/actions/pol/getEarnedStakedBeraVault.d.ts.map +1 -1
- package/dist/actions/pol/getLSTStakeConfig.d.ts.map +1 -1
- package/dist/actions/pol/getRewardVaults.d.ts.map +1 -1
- package/dist/actions/pol/getSWBeraVaultMetadata.d.ts +1 -14
- package/dist/actions/pol/getSWBeraVaultMetadata.d.ts.map +1 -1
- package/dist/actions/pol/getStakedBeraAPY.d.ts +14 -0
- package/dist/actions/pol/getStakedBeraAPY.d.ts.map +1 -0
- package/dist/actions/pol/getStakedBeraSnapshots.d.ts +14 -4
- package/dist/actions/pol/getStakedBeraSnapshots.d.ts.map +1 -1
- package/dist/actions/pol/getStakingDailyAssets.d.ts +2 -2
- package/dist/actions/pol/getStakingDailyAssets.d.ts.map +1 -1
- package/dist/actions/server/exports.mjs +5 -5
- package/dist/actions/server/exports.mjs.map +1 -1
- package/dist/actions/server/getDailyValidatorBlockStats.d.ts +1 -1
- package/dist/actions/server/getDailyValidatorBlockStats.d.ts.map +1 -1
- package/dist/actions/validators/getActiveBoostAndCommissionChangeDelay.d.ts +1 -1
- package/dist/actions/validators/getActiveBoostAndCommissionChangeDelay.d.ts.map +1 -1
- package/dist/actions/validators/getUserActiveValidators.d.ts +37 -1
- package/dist/actions/validators/getUserActiveValidators.d.ts.map +1 -1
- package/dist/actions/validators/getValidatorIncentiveDistribution.d.ts +1 -1
- package/dist/actions/validators/getValidatorIncentiveDistribution.d.ts.map +1 -1
- package/dist/actions/validators/getValidatorRewardAllocation.d.ts +4 -0
- package/dist/actions/validators/getValidatorRewardAllocation.d.ts.map +1 -1
- package/dist/chunk-3TRTSTDH.mjs +19 -0
- package/dist/chunk-3TRTSTDH.mjs.map +1 -0
- package/dist/{chunk-ZWTGVIPJ.mjs → chunk-4576RF2K.mjs} +29 -4
- package/dist/chunk-4576RF2K.mjs.map +1 -0
- package/dist/{chunk-PHYZRH4I.mjs → chunk-5MUCX35C.mjs} +9 -13
- package/dist/chunk-5MUCX35C.mjs.map +1 -0
- package/dist/{chunk-UA3Z47LT.mjs → chunk-6D4S3EAC.mjs} +97 -26
- package/dist/chunk-6D4S3EAC.mjs.map +1 -0
- package/dist/{chunk-AEN6IJFU.mjs → chunk-7KN7TDUC.mjs} +2 -2
- package/dist/{chunk-LE4CYW7S.mjs → chunk-FWRYUIJK.mjs} +3 -3
- package/dist/chunk-GDUKRUHE.mjs +29 -0
- package/dist/chunk-GDUKRUHE.mjs.map +1 -0
- package/dist/{chunk-PJRLHTGC.mjs → chunk-HPRLNT6R.mjs} +3 -3
- package/dist/{chunk-DOZJB6IJ.mjs → chunk-KY7JMIIS.mjs} +394 -346
- package/dist/chunk-KY7JMIIS.mjs.map +1 -0
- package/dist/{chunk-P3YZ7F22.mjs → chunk-LL7XR2H5.mjs} +34 -3
- package/dist/chunk-LL7XR2H5.mjs.map +1 -0
- package/dist/{chunk-EJIGERYM.mjs → chunk-M3MIGSH3.mjs} +2 -2
- package/dist/{chunk-NZAH3SGT.mjs → chunk-MVNQY2D4.mjs} +9 -4
- package/dist/chunk-MVNQY2D4.mjs.map +1 -0
- package/dist/{chunk-TGN55GKE.mjs → chunk-SC3BSCTN.mjs} +2 -2
- package/dist/{chunk-QQASX4LJ.mjs → chunk-TXWDUJOY.mjs} +2 -2
- package/dist/{chunk-EGAB6NFQ.mjs → chunk-UWJQ6UKG.mjs} +2 -2
- package/dist/chunk-XO2BFPTB.mjs +50 -0
- package/dist/chunk-XO2BFPTB.mjs.map +1 -0
- package/dist/{chunk-7TFV6UKF.mjs → chunk-XXKPXNQD.mjs} +1 -2
- package/dist/chunk-XXKPXNQD.mjs.map +1 -0
- package/dist/{chunk-IFNIPVTZ.mjs → chunk-Z337NBBW.mjs} +5 -49
- package/dist/chunk-Z337NBBW.mjs.map +1 -0
- package/dist/{chunk-J3LTASDE.mjs → chunk-ZHV3MQ4F.mjs} +4 -4
- package/dist/contexts/BeraFlags/BeraFlags.d.ts +1 -1
- package/dist/contexts/BeraFlags/BeraFlags.d.ts.map +1 -1
- package/dist/contexts/BeraFlags/defaultFlags.d.ts +2 -2
- package/dist/contexts/BeraFlags/defaultFlags.d.ts.map +1 -1
- package/dist/contexts/BexStatusProvider.d.ts +1 -1
- package/dist/contexts/BexStatusProvider.d.ts.map +1 -1
- package/dist/contexts/TokensProvider.d.ts +1 -1
- package/dist/contexts/TokensProvider.d.ts.map +1 -1
- package/dist/contexts/exports.mjs +9 -9
- package/dist/enum/contracts.d.ts +3 -0
- package/dist/enum/contracts.d.ts.map +1 -1
- package/dist/enum/exports.mjs +6 -4
- package/dist/enum/exports.mjs.map +1 -1
- package/dist/enum/txnEnum.d.ts +1 -1
- package/dist/enum/txnEnum.d.ts.map +1 -1
- package/dist/errors/RequestError.d.ts +19 -0
- package/dist/errors/RequestError.d.ts.map +1 -1
- package/dist/errors/errorMap.d.ts +4 -3
- package/dist/errors/errorMap.d.ts.map +1 -1
- package/dist/errors/exports.mjs +5 -5
- package/dist/errors/getErrorMessage.unit.test.d.ts +2 -0
- package/dist/errors/getErrorMessage.unit.test.d.ts.map +1 -0
- package/dist/generated/beep.d.ts +1597 -0
- package/dist/generated/beep.d.ts.map +1 -0
- package/dist/generated/enso.d.ts +4957 -0
- package/dist/generated/enso.d.ts.map +1 -0
- package/dist/generated/layerzero.d.ts +2057 -0
- package/dist/generated/layerzero.d.ts.map +1 -0
- package/dist/hooks/dex/useAggregatorsQuotes.d.ts.map +1 -1
- package/dist/hooks/dex/useAllUserPools.d.ts.map +1 -1
- package/dist/hooks/dex/useCrossChainNativeFee.d.ts +32 -0
- package/dist/hooks/dex/useCrossChainNativeFee.d.ts.map +1 -0
- package/dist/hooks/dex/useCrossChainNativeFee.unit.test.d.ts +2 -0
- package/dist/hooks/dex/useCrossChainNativeFee.unit.test.d.ts.map +1 -0
- package/dist/hooks/dex/useOnChainPoolData.d.ts.map +1 -1
- package/dist/hooks/dex/usePools.d.ts.map +1 -1
- package/dist/hooks/dex/useSingleAggregatorQuote.d.ts.map +1 -1
- package/dist/hooks/dex/useSingleAggregatorQuote.unit.test.d.ts +2 -0
- package/dist/hooks/dex/useSingleAggregatorQuote.unit.test.d.ts.map +1 -0
- package/dist/hooks/enso/useBendZapSupply.d.ts +2 -2
- package/dist/hooks/enso/useBendZapSupply.d.ts.map +1 -1
- package/dist/hooks/enso/useBendZapSupply.unit.test.d.ts +2 -0
- package/dist/hooks/enso/useBendZapSupply.unit.test.d.ts.map +1 -0
- package/dist/hooks/enso/useEnsoUserTokensWithBalances.d.ts.map +1 -1
- package/dist/hooks/enso/useEnsoUserTokensWithBalances.unit.test.d.ts +2 -0
- package/dist/hooks/enso/useEnsoUserTokensWithBalances.unit.test.d.ts.map +1 -0
- package/dist/hooks/enso/useZapStakeBera.d.ts.map +1 -1
- package/dist/hooks/enso/useZapStakeBera.unit.test.d.ts +2 -0
- package/dist/hooks/enso/useZapStakeBera.unit.test.d.ts.map +1 -0
- package/dist/hooks/exports.d.ts +2 -5
- package/dist/hooks/exports.d.ts.map +1 -1
- package/dist/hooks/exports.mjs +615 -911
- package/dist/hooks/exports.mjs.map +1 -1
- package/dist/hooks/governance/exports.mjs +4 -4
- package/dist/hooks/honey/useHoneyChartData.d.ts +4 -4
- package/dist/hooks/honey/useHoneyChartData.d.ts.map +1 -1
- package/dist/hooks/pol/useAutoclaimedIncentives.d.ts.map +1 -1
- package/dist/hooks/pol/useAutoclaimedIncentivesTxHash.d.ts.map +1 -1
- package/dist/hooks/pol/useRewardTokenToBeraRate.d.ts.map +1 -1
- package/dist/hooks/pol/useRewardVaultBalanceFromStakingToken.d.ts.map +1 -1
- package/dist/hooks/pol/useRewardVaults.d.ts.map +1 -1
- package/dist/hooks/pol/useStakedAPY.d.ts +11 -0
- package/dist/hooks/pol/useStakedAPY.d.ts.map +1 -0
- package/dist/hooks/pol/useStakedData.d.ts +4 -2
- package/dist/hooks/pol/useStakedData.d.ts.map +1 -1
- package/dist/hooks/pol/useStakedSnapshots.d.ts +1 -1
- package/dist/hooks/pol/useStakedSnapshots.d.ts.map +1 -1
- package/dist/hooks/pol/useStakingVaultsMetadata.d.ts +0 -1
- package/dist/hooks/pol/useStakingVaultsMetadata.d.ts.map +1 -1
- package/dist/hooks/tokens/useMultipleTokenInformation.d.ts +30 -0
- package/dist/hooks/tokens/useMultipleTokenInformation.d.ts.map +1 -1
- package/dist/hooks/tokens/useMultipleTokenInformation.unit.test.d.ts +2 -0
- package/dist/hooks/tokens/useMultipleTokenInformation.unit.test.d.ts.map +1 -0
- package/dist/hooks/tokens/usePollBalance.d.ts.map +1 -1
- package/dist/hooks/validators/useUserActiveValidators.d.ts +5 -0
- package/dist/hooks/validators/useUserActiveValidators.d.ts.map +1 -1
- package/dist/hooks/validators/useValidator.d.ts +0 -1
- package/dist/hooks/validators/useValidator.d.ts.map +1 -1
- package/dist/hooks/validators/useValidatorIncentiveDistribution.d.ts +4 -5
- package/dist/hooks/validators/useValidatorIncentiveDistribution.d.ts.map +1 -1
- package/dist/hooks/validators/useValidatorRewardAllocation.d.ts +1 -0
- package/dist/hooks/validators/useValidatorRewardAllocation.d.ts.map +1 -1
- package/dist/types/beep/exports.d.ts +2 -0
- package/dist/types/beep/exports.d.ts.map +1 -0
- package/dist/types/beep/exports.mjs +1 -0
- package/dist/types/beep/exports.mjs.map +1 -0
- package/dist/types/bribeBoost.d.ts +0 -49
- package/dist/types/dex.d.ts +17 -0
- package/dist/types/enso.d.ts +1 -27
- package/dist/types/global.d.ts +7 -0
- package/dist/types/pol.d.ts +3 -48
- package/dist/utils/crossChainBridge.d.ts +74 -0
- package/dist/utils/crossChainBridge.d.ts.map +1 -0
- package/dist/utils/crossChainBridge.unit.test.d.ts +2 -0
- package/dist/utils/crossChainBridge.unit.test.d.ts.map +1 -0
- package/dist/utils/exports.d.ts +1 -1
- package/dist/utils/exports.d.ts.map +1 -1
- package/dist/utils/exports.mjs +142 -72
- package/dist/utils/exports.mjs.map +1 -1
- package/dist/utils/getTestClient.d.ts +5 -3
- package/dist/utils/getTestClient.d.ts.map +1 -1
- package/dist/utils/parseWhiskToken.d.ts.map +1 -1
- package/package.json +14 -10
- package/src/actions/clients/BeraApolloClient.ts +4 -2
- package/src/actions/clients/clientName.ts +17 -0
- package/src/actions/clients/clientName.unit.test.ts +39 -0
- package/src/actions/clients/exports.ts +2 -0
- package/src/actions/clients/fetchBeep.ts +6 -4
- package/src/actions/clients/fetchEnso.ts +47 -0
- package/src/actions/clients/fetchLayerzero.ts +33 -0
- package/src/actions/clients/fetchOpenApi.ts +9 -2
- package/src/actions/clients/fetchOpenApi.unit.test.ts +27 -12
- package/src/actions/clients/getApolloClient.ts +3 -11
- package/src/actions/dex/__tests__/aggregators.unit.test.ts +231 -2
- package/src/actions/dex/aggregators/base.ts +75 -17
- package/src/actions/dex/aggregators/bex.ts +41 -1
- package/src/actions/dex/aggregators/bgt.ts +11 -6
- package/src/actions/dex/aggregators/enso/enso.ts +1 -0
- package/src/actions/dex/aggregators/enso/ensoErc4626.ts +27 -9
- package/src/actions/dex/aggregators/erc4626.ts +19 -5
- package/src/actions/dex/aggregators/fly.ts +1 -0
- package/src/actions/dex/aggregators/haiku.ts +33 -2
- package/src/actions/dex/aggregators/honey.ts +17 -6
- package/src/actions/dex/aggregators/kyberswap.ts +1 -0
- package/src/actions/dex/aggregators/oogabooga.ts +1 -0
- package/src/actions/dex/aggregators/openOcean.ts +1 -0
- package/src/actions/dex/aggregators/wbera.ts +17 -11
- package/src/actions/enso/getBendMultiplyBundle.ts +1 -1
- package/src/actions/enso/getEnsoUserTokensWithBalances.ts +4 -8
- package/src/actions/enso/util.ts +0 -59
- package/src/actions/exports.ts +3 -5
- package/src/actions/honey/getChartData.ts +2 -3
- package/src/actions/honey/getHoney24hVolume.ts +4 -13
- package/src/actions/honey/getHoneyCollaterals.ts +1 -1
- package/src/actions/honey/getHoneyTxns.ts +2 -3
- package/src/actions/pol/getBGTGlobalInfo.ts +0 -2
- package/src/actions/pol/getBeraTokenTotalSupply.ts +3 -33
- package/src/actions/pol/getEarnedStakedBeraVault.ts +1 -1
- package/src/actions/pol/getLSTStakeConfig.ts +0 -6
- package/src/actions/pol/getRewardVaults.ts +0 -1
- package/src/actions/pol/getSWBeraVaultMetadata.ts +2 -106
- package/src/actions/pol/getStakedBeraAPY.ts +44 -0
- package/src/actions/pol/getStakedBeraSnapshots.ts +17 -34
- package/src/actions/pol/getStakingDailyAssets.ts +1 -1
- package/src/actions/server/getDailyValidatorBlockStats.ts +1 -2
- package/src/actions/validators/getActiveBoostAndCommissionChangeDelay.ts +1 -1
- package/src/actions/validators/getUserActiveValidators.ts +116 -54
- package/src/actions/validators/getValidatorIncentiveDistribution.ts +1 -2
- package/src/actions/validators/getValidatorRewardAllocation.ts +12 -1
- package/src/contexts/BeraFlags/BeraFlags.tsx +1 -4
- package/src/contexts/BeraFlags/defaultFlags.ts +1 -3
- package/src/contexts/BexStatusProvider.tsx +1 -1
- package/src/contexts/TokensProvider.tsx +1 -4
- package/src/enum/contracts.ts +3 -0
- package/src/enum/txnEnum.ts +1 -1
- package/src/errors/BeraError.unit.test.ts +23 -0
- package/src/errors/RequestError.ts +46 -9
- package/src/errors/RequestError.unit.test.ts +54 -0
- package/src/errors/errorMap.ts +8 -3
- package/src/errors/getErrorMessage.unit.test.ts +32 -0
- package/src/generated/beep.ts +1605 -0
- package/src/generated/enso.ts +4965 -0
- package/src/generated/layerzero.ts +2065 -0
- package/src/hooks/dex/useAggregatorsQuotes.ts +7 -1
- package/src/hooks/dex/useCrossChainNativeFee.ts +83 -0
- package/src/hooks/dex/useCrossChainNativeFee.unit.test.ts +63 -0
- package/src/hooks/dex/useOnChainPoolData.ts +30 -13
- package/src/hooks/dex/useSingleAggregatorQuote.ts +10 -5
- package/src/hooks/dex/useSingleAggregatorQuote.unit.test.ts +86 -0
- package/src/hooks/enso/useBendZapSupply.ts +10 -38
- package/src/hooks/enso/useBendZapSupply.unit.test.ts +98 -0
- package/src/hooks/enso/useEnsoUserTokensWithBalances.ts +13 -3
- package/src/hooks/enso/useEnsoUserTokensWithBalances.unit.test.ts +69 -0
- package/src/hooks/enso/useZapStakeBera.ts +8 -1
- package/src/hooks/enso/useZapStakeBera.unit.test.ts +97 -0
- package/src/hooks/exports.ts +2 -5
- package/src/hooks/pol/useAutoclaimedIncentives.ts +6 -3
- package/src/hooks/pol/useAutoclaimedIncentivesTxHash.ts +5 -2
- package/src/hooks/pol/useRewardTokenToBeraRate.ts +5 -4
- package/src/hooks/pol/useRewardVaultBalanceFromStakingToken.ts +0 -1
- package/src/hooks/pol/{useStakedAPR.ts → useStakedAPY.ts} +11 -9
- package/src/hooks/pol/useStakedData.ts +15 -14
- package/src/hooks/pol/useStakedSnapshots.ts +1 -1
- package/src/hooks/pol/useStakingVaultsMetadata.ts +3 -8
- package/src/hooks/tokens/useMultipleTokenInformation.ts +64 -21
- package/src/hooks/tokens/useMultipleTokenInformation.unit.test.ts +91 -0
- package/src/hooks/tokens/usePollBalance.ts +4 -2
- package/src/hooks/validators/useUserActiveValidators.ts +54 -9
- package/src/hooks/validators/useValidatorIncentiveDistribution.ts +4 -5
- package/src/types/beep/exports.ts +4 -0
- package/src/types/bribeBoost.d.ts +0 -49
- package/src/types/dex.d.ts +17 -0
- package/src/types/enso.d.ts +1 -27
- package/src/types/global.d.ts +7 -0
- package/src/types/pol.d.ts +3 -48
- package/src/utils/crossChainBridge.ts +290 -0
- package/src/utils/crossChainBridge.unit.test.ts +177 -0
- package/src/utils/exports.ts +1 -1
- package/dist/BeraError-7-A5JYy_.d.ts +0 -123
- package/dist/BexStatusProvider-DRymVlQf.d.ts +0 -70
- package/dist/HoneyConfigProvider-COOuDNra.d.ts +0 -390
- package/dist/RequestError-DkUbo3ro.d.ts +0 -145
- package/dist/actions/dex/b-sdk.d.ts +0 -3
- package/dist/actions/enso/getEnsoSwapBundle.d.ts +0 -3
- package/dist/actions/enso/getEnsoSwapBundle.d.ts.map +0 -1
- package/dist/actions/pol/getBgtIncentiveDistributorPaused.d.ts +0 -10
- package/dist/actions/pol/getBgtIncentiveDistributorPaused.d.ts.map +0 -1
- package/dist/actions/pol/getRewardProofsByValidator.d.ts +0 -9
- package/dist/actions/pol/getRewardProofsByValidator.d.ts.map +0 -1
- package/dist/actions/pol/getStakedBeraAPR.d.ts +0 -12
- package/dist/actions/pol/getStakedBeraAPR.d.ts.map +0 -1
- package/dist/actions/pol/getUserClaimableIncentives.d.ts +0 -9
- package/dist/actions/pol/getUserClaimableIncentives.d.ts.map +0 -1
- package/dist/actions/validators/getValidatorAnalytics.d.ts +0 -12
- package/dist/actions/validators/getValidatorAnalytics.d.ts.map +0 -1
- package/dist/chunk-7TFV6UKF.mjs.map +0 -1
- package/dist/chunk-BSOWLS3W.mjs +0 -40
- package/dist/chunk-BSOWLS3W.mjs.map +0 -1
- package/dist/chunk-DOZJB6IJ.mjs.map +0 -1
- package/dist/chunk-IFNIPVTZ.mjs.map +0 -1
- package/dist/chunk-NZAH3SGT.mjs.map +0 -1
- package/dist/chunk-P3YZ7F22.mjs.map +0 -1
- package/dist/chunk-PHYZRH4I.mjs.map +0 -1
- package/dist/chunk-UA3Z47LT.mjs.map +0 -1
- package/dist/chunk-ZWTGVIPJ.mjs.map +0 -1
- package/dist/contexts/block-time-provider.d.ts +0 -10
- package/dist/defaultFlags-D6KfkTZx.d.ts +0 -10
- package/dist/dex-C_BB0b0O.d.ts +0 -37
- package/dist/getApolloClient-MWm_iq4u.d.ts +0 -39
- package/dist/getProposalVotes-DAUrdX2n.d.ts +0 -12
- package/dist/getValidatorQueuedOperatorAddress-N2I7wHd6.d.ts +0 -511
- package/dist/global.d-CR3zicga.d.ts +0 -231
- package/dist/global.d-CiZJ2eHz.d.ts +0 -231
- package/dist/honey-CYm0RWf4.d.ts +0 -14
- package/dist/hooks/enso/useEnsoSwapBundle.d.ts +0 -26
- package/dist/hooks/enso/useEnsoSwapBundle.d.ts.map +0 -1
- package/dist/hooks/pol/useBgtIncentiveDistributorPaused.d.ts +0 -8
- package/dist/hooks/pol/useBgtIncentiveDistributorPaused.d.ts.map +0 -1
- package/dist/hooks/pol/useStakedAPR.d.ts +0 -11
- package/dist/hooks/pol/useStakedAPR.d.ts.map +0 -1
- package/dist/hooks/validators/useUserClaimableIncentives.d.ts +0 -8
- package/dist/hooks/validators/useUserClaimableIncentives.d.ts.map +0 -1
- package/dist/hooks/validators/useValidatorAnalytics.d.ts +0 -11
- package/dist/hooks/validators/useValidatorAnalytics.d.ts.map +0 -1
- package/dist/pol.d-CeRgXBL8.d.ts +0 -167
- package/dist/txnEnum-ByI5dtDi.d.ts +0 -106
- package/dist/types/bribe-boost.d.ts +0 -69
- package/dist/useHoneySwapState-CXVWAThr.d.ts +0 -32
- package/dist/useHoneySwapState-twi7NTaO.d.ts +0 -32
- package/dist/utils/formatIncentivesTokenMap.d.ts +0 -3
- package/dist/utils/formatIncentivesTokenMap.d.ts.map +0 -1
- package/dist/utils/layerZeroScan.d.ts +0 -39
- package/dist/utils/layerZeroScan.d.ts.map +0 -1
- package/src/actions/enso/getEnsoSwapBundle.ts +0 -72
- package/src/actions/pol/getBgtIncentiveDistributorPaused.ts +0 -28
- package/src/actions/pol/getRewardProofsByValidator.ts +0 -49
- package/src/actions/pol/getStakedBeraAPR.ts +0 -56
- package/src/actions/pol/getUserClaimableIncentives.ts +0 -40
- package/src/actions/validators/getValidatorAnalytics.ts +0 -37
- package/src/hooks/enso/useEnsoSwapBundle.ts +0 -121
- package/src/hooks/pol/useBgtIncentiveDistributorPaused.ts +0 -34
- package/src/hooks/validators/useUserClaimableIncentives.ts +0 -148
- package/src/hooks/validators/useValidatorAnalytics.ts +0 -37
- package/src/utils/formatIncentivesTokenMap.ts +0 -19
- package/src/utils/layerZeroScan.ts +0 -124
- /package/dist/{chunk-AEN6IJFU.mjs.map → chunk-7KN7TDUC.mjs.map} +0 -0
- /package/dist/{chunk-LE4CYW7S.mjs.map → chunk-FWRYUIJK.mjs.map} +0 -0
- /package/dist/{chunk-PJRLHTGC.mjs.map → chunk-HPRLNT6R.mjs.map} +0 -0
- /package/dist/{chunk-EJIGERYM.mjs.map → chunk-M3MIGSH3.mjs.map} +0 -0
- /package/dist/{chunk-TGN55GKE.mjs.map → chunk-SC3BSCTN.mjs.map} +0 -0
- /package/dist/{chunk-QQASX4LJ.mjs.map → chunk-TXWDUJOY.mjs.map} +0 -0
- /package/dist/{chunk-EGAB6NFQ.mjs.map → chunk-UWJQ6UKG.mjs.map} +0 -0
- /package/dist/{chunk-J3LTASDE.mjs.map → chunk-ZHV3MQ4F.mjs.map} +0 -0
|
@@ -5,7 +5,7 @@ import {
|
|
|
5
5
|
getProposalDetails,
|
|
6
6
|
getProposalFromTx,
|
|
7
7
|
getProposalVotes
|
|
8
|
-
} from "../../chunk-
|
|
8
|
+
} from "../../chunk-UWJQ6UKG.mjs";
|
|
9
9
|
import "../../chunk-KL6YZ5VR.mjs";
|
|
10
10
|
import {
|
|
11
11
|
useSWR,
|
|
@@ -15,11 +15,11 @@ import "../../chunk-GLWPRM33.mjs";
|
|
|
15
15
|
import {
|
|
16
16
|
assertDefined,
|
|
17
17
|
assertPublicClient
|
|
18
|
-
} from "../../chunk-
|
|
18
|
+
} from "../../chunk-TXWDUJOY.mjs";
|
|
19
19
|
import {
|
|
20
20
|
parseBaseArgs
|
|
21
|
-
} from "../../chunk-
|
|
22
|
-
import "../../chunk-
|
|
21
|
+
} from "../../chunk-SC3BSCTN.mjs";
|
|
22
|
+
import "../../chunk-MVNQY2D4.mjs";
|
|
23
23
|
|
|
24
24
|
// src/hooks/governance/useCreateProposal.ts
|
|
25
25
|
import { useCallback, useEffect, useState } from "react";
|
|
@@ -2,9 +2,9 @@ export declare function useHoneyChartData({ days }: {
|
|
|
2
2
|
days: number;
|
|
3
3
|
}): import("@berachain/utils/pkg/swr").BeraSwrResponse<{
|
|
4
4
|
timestamp: number;
|
|
5
|
-
mintVolume: import("
|
|
6
|
-
redeemVolume: import("
|
|
7
|
-
totalVolume: import("
|
|
8
|
-
totalSupply: import("
|
|
5
|
+
mintVolume: import("../../generated/beep").components["schemas"]["DecimalStr"];
|
|
6
|
+
redeemVolume: import("../../generated/beep").components["schemas"]["DecimalStr"];
|
|
7
|
+
totalVolume: import("../../generated/beep").components["schemas"]["DecimalStr"];
|
|
8
|
+
totalSupply: import("../../generated/beep").components["schemas"]["DecimalStr"];
|
|
9
9
|
}[], any>;
|
|
10
10
|
//# sourceMappingURL=useHoneyChartData.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useHoneyChartData.d.ts","sourceRoot":"","sources":["../../../src/hooks/honey/useHoneyChartData.ts"],"names":[],"mappings":"AAIA,wBAAgB,iBAAiB,CAAC,EAAE,IAAI,EAAE,EAAE;IAAE,IAAI,EAAE,MAAM,CAAA;CAAE;;
|
|
1
|
+
{"version":3,"file":"useHoneyChartData.d.ts","sourceRoot":"","sources":["../../../src/hooks/honey/useHoneyChartData.ts"],"names":[],"mappings":"AAIA,wBAAgB,iBAAiB,CAAC,EAAE,IAAI,EAAE,EAAE;IAAE,IAAI,EAAE,MAAM,CAAA;CAAE;;gBAKgsjB,oDAAsB;kBAAyC,oDAAsB;iBAAwC,oDAAsB;iBAAwC,oDAAsB;UAD58jB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useAutoclaimedIncentives.d.ts","sourceRoot":"","sources":["../../../src/hooks/pol/useAutoclaimedIncentives.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,6BAA6B,EAAE,MAAM,wBAAwB,CAAC;AAC5E,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,oBAAoB,CAAC;
|
|
1
|
+
{"version":3,"file":"useAutoclaimedIncentives.d.ts","sourceRoot":"","sources":["../../../src/hooks/pol/useAutoclaimedIncentives.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,6BAA6B,EAAE,MAAM,wBAAwB,CAAC;AAC5E,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,oBAAoB,CAAC;AAGhE,UAAU,4BAA4B;IAIpC,OAAO,EAAE,OAAO,CAAC;CAClB;AAED,wBAAgB,wBAAwB,CAAC,EACvC,OAAO,GACR,EAAE,4BAA4B,GAAG,qBAAqB,CAAC,6BAA6B,GAAG,IAAI,CAAC,CAmB5F"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useAutoclaimedIncentivesTxHash.d.ts","sourceRoot":"","sources":["../../../src/hooks/pol/useAutoclaimedIncentivesTxHash.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,mCAAmC,EAAE,MAAM,wBAAwB,CAAC;AAClF,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,oBAAoB,CAAC;
|
|
1
|
+
{"version":3,"file":"useAutoclaimedIncentivesTxHash.d.ts","sourceRoot":"","sources":["../../../src/hooks/pol/useAutoclaimedIncentivesTxHash.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,mCAAmC,EAAE,MAAM,wBAAwB,CAAC;AAClF,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,oBAAoB,CAAC;AAGhE,UAAU,kCAAkC;IAG1C,OAAO,EAAE,OAAO,CAAC;CAClB;AAED,wBAAgB,8BAA8B,CAAC,EAC7C,OAAO,GACR,EAAE,kCAAkC,GAAG,qBAAqB,CAAC,mCAAmC,GAAG,IAAI,CAAC,CAwBxG"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useRewardTokenToBeraRate.d.ts","sourceRoot":"","sources":["../../../src/hooks/pol/useRewardTokenToBeraRate.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,MAAM,CAAC;AASpC,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAC;AAE7D,wBAAgB,wBAAwB,CACtC,EACE,OAAO,GACR,EAAE;IACD,OAAO,EAAE,OAAO,GAAG,SAAS,CAAC;CAC9B,EACD,GAAG,CAAC,EAAE,kBAAkB,
|
|
1
|
+
{"version":3,"file":"useRewardTokenToBeraRate.d.ts","sourceRoot":"","sources":["../../../src/hooks/pol/useRewardTokenToBeraRate.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,MAAM,CAAC;AASpC,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAC;AAE7D,wBAAgB,wBAAwB,CACtC,EACE,OAAO,GACR,EAAE;IACD,OAAO,EAAE,OAAO,GAAG,SAAS,CAAC;CAC9B,EACD,GAAG,CAAC,EAAE,kBAAkB,mEAuBzB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useRewardVaultBalanceFromStakingToken.d.ts","sourceRoot":"","sources":["../../../src/hooks/pol/useRewardVaultBalanceFromStakingToken.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,OAAO,EAA0B,MAAM,MAAM,CAAC;AAQ5D,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAC;AAI7D,wBAAgB,qCAAqC,CACnD,EACE,YAAY,EACZ,kBAAkB,EAAE,mBAAmB,GACxC,EAAE;IACD,YAAY,EAAE,OAAO,GAAG,SAAS,CAAC;IAClC,kBAAkB,CAAC,EAAE,OAAO,CAAC;CAC9B,EACD,OAAO,CAAC,EAAE,kBAAkB;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"useRewardVaultBalanceFromStakingToken.d.ts","sourceRoot":"","sources":["../../../src/hooks/pol/useRewardVaultBalanceFromStakingToken.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,OAAO,EAA0B,MAAM,MAAM,CAAC;AAQ5D,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAC;AAI7D,wBAAgB,qCAAqC,CACnD,EACE,YAAY,EACZ,kBAAkB,EAAE,mBAAmB,GACxC,EAAE;IACD,YAAY,EAAE,OAAO,GAAG,SAAS,CAAC;IAClC,kBAAkB,CAAC,EAAE,OAAO,CAAC;CAC9B,EACD,OAAO,CAAC,EAAE,kBAAkB;;;;;;;;;EA6D7B"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useRewardVaults.d.ts","sourceRoot":"","sources":["../../../src/hooks/pol/useRewardVaults.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,4BAA4B,CAAC;AAK1E,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAC;AAE7D,wBAAgB,uBAAuB,CACrC,MAAM,CAAC,EAAE,uBAAuB,EAChC,iBAAiB,UAAQ;;+
|
|
1
|
+
{"version":3,"file":"useRewardVaults.d.ts","sourceRoot":"","sources":["../../../src/hooks/pol/useRewardVaults.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,4BAA4B,CAAC;AAK1E,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAC;AAE7D,wBAAgB,uBAAuB,CACrC,MAAM,CAAC,EAAE,uBAAuB,EAChC,iBAAiB,UAAQ;;+DA4B4vlG,mDAAc;2DAAkC,mDAAc;;;6DAAoJ,sDAAiB;yBAzBz/lG;AAED,wBAAgB,eAAe,CAC7B,IAAI,EAAE;IACJ,MAAM,CAAC,EAAE,uBAAuB,CAAC;IACjC,iBAAiB,CAAC,EAAE,OAAO,CAAC;CAC7B,EACD,OAAO,CAAC,EAAE,kBAAkB,2HAiB7B"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { type StakeSnapshotRange } from "../../actions/pol/getStakedBeraSnapshots";
|
|
2
|
+
import type { DefaultHookReturnType } from "../../types/global";
|
|
3
|
+
type UseStakedAPY = {
|
|
4
|
+
timestamp: number;
|
|
5
|
+
apy: number | null;
|
|
6
|
+
}[];
|
|
7
|
+
export declare function useStakedAPY({ range, }: {
|
|
8
|
+
range: StakeSnapshotRange;
|
|
9
|
+
}): DefaultHookReturnType<UseStakedAPY>;
|
|
10
|
+
export {};
|
|
11
|
+
//# sourceMappingURL=useStakedAPY.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useStakedAPY.d.ts","sourceRoot":"","sources":["../../../src/hooks/pol/useStakedAPY.ts"],"names":[],"mappings":"AAEA,OAAO,EAEL,KAAK,kBAAkB,EACxB,MAAM,0CAA0C,CAAC;AAClD,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,oBAAoB,CAAC;AAGhE,KAAK,YAAY,GAAG;IAClB,SAAS,EAAE,MAAM,CAAC;IAClB,GAAG,EAAE,MAAM,GAAG,IAAI,CAAC;CACpB,EAAE,CAAC;AACJ,wBAAgB,YAAY,CAAC,EAC3B,KAAK,GACN,EAAE;IACD,KAAK,EAAE,kBAAkB,CAAC;CAC3B,GAAG,qBAAqB,CAAC,YAAY,CAAC,CAgBtC"}
|
|
@@ -3,7 +3,7 @@ import type { StakingConfig } from "../../types/staking";
|
|
|
3
3
|
/**
|
|
4
4
|
* Fetches staked asset data in two phases for progressive loading:
|
|
5
5
|
*
|
|
6
|
-
* 1.
|
|
6
|
+
* 1. APY — independent fetch, resolves quickly, shared by both phases.
|
|
7
7
|
* 2. Balances (fast path) — wallet balances (via usePollWalletBalances),
|
|
8
8
|
* token prices (via useTokenPrices), and exchange rates.
|
|
9
9
|
* Provides staked amounts and USD values immediately (earnings are 0).
|
|
@@ -13,6 +13,8 @@ import type { StakingConfig } from "../../types/staking";
|
|
|
13
13
|
* Consumers can show `balances` right away and swap in `data` once positions resolve.
|
|
14
14
|
*/
|
|
15
15
|
export declare function useStakedData(stakingConfigs: StakingConfig[]): {
|
|
16
|
+
/** Overall staked-BERA APY. Wallet-independent. */
|
|
17
|
+
apy: number | undefined;
|
|
16
18
|
/** Fast path: staked amounts + USD values (no earnings) */
|
|
17
19
|
balances: StakedBeraAsset[] | undefined;
|
|
18
20
|
/** Slow path: full enriched positions with earnings */
|
|
@@ -25,7 +27,7 @@ export declare function useStakedData(stakingConfigs: StakingConfig[]): {
|
|
|
25
27
|
/**
|
|
26
28
|
* Hard error: the RPC fast-path could not produce staked balances (wallet
|
|
27
29
|
* balances or exchange-rate reads failed). Price and earnings backend
|
|
28
|
-
* failures are intentionally excluded — those degrade gracefully (USD/
|
|
30
|
+
* failures are intentionally excluded — those degrade gracefully (USD/APY
|
|
29
31
|
* render as "—", earnings stop loading) so RPC-derived amounts still show.
|
|
30
32
|
*/
|
|
31
33
|
error: any;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useStakedData.d.ts","sourceRoot":"","sources":["../../../src/hooks/pol/useStakedData.ts"],"names":[],"mappings":"AAYA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,iBAAiB,CAAC;AACvD,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAIzD;;;;;;;;;;;GAWG;AACH,wBAAgB,aAAa,CAAC,cAAc,EAAE,aAAa,EAAE;
|
|
1
|
+
{"version":3,"file":"useStakedData.d.ts","sourceRoot":"","sources":["../../../src/hooks/pol/useStakedData.ts"],"names":[],"mappings":"AAYA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,iBAAiB,CAAC;AACvD,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAIzD;;;;;;;;;;;GAWG;AACH,wBAAgB,aAAa,CAAC,cAAc,EAAE,aAAa,EAAE;IA2LzD,mDAAmD;;IAEnD,2DAA2D;;IAE3D,uDAAuD;;IAEvD,mEAAmE;;;;;IAKnE;;;;;OAKG;;IAEH,wDAAwD;;IAExD;;;;OAIG;;EAGN"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { Address } from "viem";
|
|
2
|
-
import type { StakeStatsByDayResponse } from "
|
|
2
|
+
import type { StakeStatsByDayResponse } from "../../generated/beep";
|
|
3
3
|
import type { DefaultHookReturnType } from "../../types/global";
|
|
4
4
|
type UseStakedBeraSnapshot = Record<Address, StakeStatsByDayResponse>;
|
|
5
5
|
export declare function useStakedSnapshots({ range, addresses, }: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useStakedSnapshots.d.ts","sourceRoot":"","sources":["../../../src/hooks/pol/useStakedSnapshots.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,MAAM,CAAC;
|
|
1
|
+
{"version":3,"file":"useStakedSnapshots.d.ts","sourceRoot":"","sources":["../../../src/hooks/pol/useStakedSnapshots.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,MAAM,CAAC;AAKpC,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,sBAAsB,CAAC;AACpE,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,oBAAoB,CAAC;AAGhE,KAAK,qBAAqB,GAAG,MAAM,CAAC,OAAO,EAAE,uBAAuB,CAAC,CAAC;AACtE,wBAAgB,kBAAkB,CAAC,EACjC,KAAK,EACL,SAAS,GACV,EAAE;IACD,SAAS,EAAE,OAAO,EAAE,CAAC;IACrB,KAAK,EAAE,EAAE,GAAG,EAAE,GAAG,EAAE,CAAC;CACrB,GAAG,qBAAqB,CAAC,qBAAqB,CAAC,CA0B/C"}
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import type { Address } from "viem";
|
|
2
2
|
export type StakingVaultEntry = {
|
|
3
3
|
address: Address;
|
|
4
|
-
underlyingAsset: Address;
|
|
5
4
|
};
|
|
6
5
|
export declare function useStakingVaultsMetadata(vaults?: StakingVaultEntry[]): import("@berachain/utils/pkg/swr").BeraSwrResponse<import("../../actions/pol/getSWBeraVaultMetadata").VaultMetadata[], any>;
|
|
7
6
|
//# sourceMappingURL=useStakingVaultsMetadata.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useStakingVaultsMetadata.d.ts","sourceRoot":"","sources":["../../../src/hooks/pol/useStakingVaultsMetadata.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,MAAM,CAAC;
|
|
1
|
+
{"version":3,"file":"useStakingVaultsMetadata.d.ts","sourceRoot":"","sources":["../../../src/hooks/pol/useStakingVaultsMetadata.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,MAAM,CAAC;AASpC,MAAM,MAAM,iBAAiB,GAAG;IAC9B,OAAO,EAAE,OAAO,CAAC;CAClB,CAAC;AAEF,wBAAgB,wBAAwB,CAAC,MAAM,GAAE,iBAAiB,EAAO,+HAqBxE"}
|
|
@@ -1,9 +1,39 @@
|
|
|
1
|
+
import type { PublicClient } from "viem";
|
|
2
|
+
import type { ChainId } from "@berachain/config";
|
|
1
3
|
import type { Token } from "../../types/dex";
|
|
2
4
|
import type { DefaultHookOptions, DefaultHookReturnType } from "../../types/global";
|
|
3
5
|
export type UseMultipleTokenInformationResponse = DefaultHookReturnType<Token[]>;
|
|
6
|
+
/**
|
|
7
|
+
* Resolve ERC20 metadata for a batch of addresses, best-effort. An address whose
|
|
8
|
+
* metadata can't be read — a non-ERC20 / codeless contract (e.g. a single-asset
|
|
9
|
+
* staking vault whose `decimals()` reverts), an invalid address, or a missing
|
|
10
|
+
* token — is simply omitted from the result rather than failing the whole batch.
|
|
11
|
+
* Consumers key results by address and treat a missing entry as absent.
|
|
12
|
+
*/
|
|
13
|
+
export declare function fetchMultipleTokenInformation({ addresses, publicClient, chainId, }: {
|
|
14
|
+
addresses: readonly string[];
|
|
15
|
+
publicClient: PublicClient;
|
|
16
|
+
chainId: ChainId;
|
|
17
|
+
}): Promise<Token[]>;
|
|
4
18
|
export type useMultipleTokenInformationArgs = {
|
|
19
|
+
/** Addresses to resolve metadata for. `undefined` disables the query. */
|
|
5
20
|
addresses: string[] | readonly string[] | undefined;
|
|
21
|
+
/** Chain to read from. Defaults to the app's `defaultChainId`. */
|
|
6
22
|
chainId?: number;
|
|
7
23
|
};
|
|
24
|
+
/**
|
|
25
|
+
* Batch-resolves ERC20 metadata for `addresses`, best-effort.
|
|
26
|
+
*
|
|
27
|
+
* Metadata resolution is best-effort:
|
|
28
|
+
* any address that can't be resolved — a non-ERC20 / codeless contract (e.g. a
|
|
29
|
+
* single-asset staking vault whose `decimals()` reverts), an invalid address, or
|
|
30
|
+
* a missing token — is OMITTED rather than failing the whole batch. So the result
|
|
31
|
+
* length and order do not necessarily match the input `addresses`.
|
|
32
|
+
*
|
|
33
|
+
* ⚠️ The returned array is NOT positional.
|
|
34
|
+
* Do NOT index the result positionally (`data[i]` for `addresses[i]`). Always
|
|
35
|
+
* look tokens up by address, e.g. `data?.find(t => t.address === addr)` or build
|
|
36
|
+
* an address-keyed map.
|
|
37
|
+
*/
|
|
8
38
|
export declare function useMultipleTokenInformation(args: useMultipleTokenInformationArgs, options?: DefaultHookOptions): UseMultipleTokenInformationResponse;
|
|
9
39
|
//# sourceMappingURL=useMultipleTokenInformation.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useMultipleTokenInformation.d.ts","sourceRoot":"","sources":["../../../src/hooks/tokens/useMultipleTokenInformation.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"useMultipleTokenInformation.d.ts","sourceRoot":"","sources":["../../../src/hooks/tokens/useMultipleTokenInformation.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,MAAM,CAAC;AAEzC,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAQjD,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,iBAAiB,CAAC;AAC7C,OAAO,KAAK,EACV,kBAAkB,EAClB,qBAAqB,EACtB,MAAM,oBAAoB,CAAC;AAE5B,MAAM,MAAM,mCAAmC,GAAG,qBAAqB,CACrE,KAAK,EAAE,CACR,CAAC;AAEF;;;;;;GAMG;AACH,wBAAsB,6BAA6B,CAAC,EAClD,SAAS,EACT,YAAY,EACZ,OAAO,GACR,EAAE;IACD,SAAS,EAAE,SAAS,MAAM,EAAE,CAAC;IAC7B,YAAY,EAAE,YAAY,CAAC;IAC3B,OAAO,EAAE,OAAO,CAAC;CAClB,GAAG,OAAO,CAAC,KAAK,EAAE,CAAC,CAsBnB;AAED,MAAM,MAAM,+BAA+B,GAAG;IAC5C,yEAAyE;IACzE,SAAS,EAAE,MAAM,EAAE,GAAG,SAAS,MAAM,EAAE,GAAG,SAAS,CAAC;IACpD,kEAAkE;IAClE,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB,CAAC;AAEF;;;;;;;;;;;;;GAaG;AACH,wBAAgB,2BAA2B,CACzC,IAAI,EAAE,+BAA+B,EACrC,OAAO,CAAC,EAAE,kBAAkB,GAC3B,mCAAmC,CA4BrC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useMultipleTokenInformation.unit.test.d.ts","sourceRoot":"","sources":["../../../src/hooks/tokens/useMultipleTokenInformation.unit.test.ts"],"names":[],"mappings":""}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"usePollBalance.d.ts","sourceRoot":"","sources":["../../../src/hooks/tokens/usePollBalance.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,OAAO,EAMb,MAAM,MAAM,CAAC;AASd,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AACpD,OAAO,KAAK,EACV,kBAAkB,EAClB,qBAAqB,EACtB,MAAM,oBAAoB,CAAC;AAI5B,wBAAgB,cAAc,CAC5B,EACE,OAAO,EAAE,aAAa,EACtB,KAAK,EACL,OAAwB,GACzB,EAAE;IACD;;OAEG;IACH,OAAO,EAAE,MAAM,GAAG,SAAS,CAAC;IAC5B,KAAK,CAAC,EAAE,OAAO,GAAG,SAAS,CAAC;IAC5B,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB,EACD,OAAO,CAAC,EAAE,kBAAkB,GAC3B,IAAI,CAAC,qBAAqB,CAAC,YAAY,GAAG,SAAS,CAAC,EAAE,QAAQ,CAAC,
|
|
1
|
+
{"version":3,"file":"usePollBalance.d.ts","sourceRoot":"","sources":["../../../src/hooks/tokens/usePollBalance.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,OAAO,EAMb,MAAM,MAAM,CAAC;AASd,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AACpD,OAAO,KAAK,EACV,kBAAkB,EAClB,qBAAqB,EACtB,MAAM,oBAAoB,CAAC;AAI5B,wBAAgB,cAAc,CAC5B,EACE,OAAO,EAAE,aAAa,EACtB,KAAK,EACL,OAAwB,GACzB,EAAE;IACD;;OAEG;IACH,OAAO,EAAE,MAAM,GAAG,SAAS,CAAC;IAC5B,KAAK,CAAC,EAAE,OAAO,GAAG,SAAS,CAAC;IAC5B,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB,EACD,OAAO,CAAC,EAAE,kBAAkB,GAC3B,IAAI,CAAC,qBAAqB,CAAC,YAAY,GAAG,SAAS,CAAC,EAAE,QAAQ,CAAC,CAgFjE"}
|
|
@@ -1,6 +1,11 @@
|
|
|
1
1
|
import { type ValidatorWithUserBoost } from "../../actions/validators/getUserActiveValidators";
|
|
2
2
|
import type { DefaultHookOptions, DefaultHookReturnType } from "../../types/global";
|
|
3
3
|
interface UseUserActiveValidatorsResponse extends DefaultHookReturnType<ValidatorWithUserBoost[] | undefined> {
|
|
4
|
+
/**
|
|
5
|
+
* Re-reads the on-chain boost amounts without re-fetching the API validator
|
|
6
|
+
* list. Use after a boost/drop tx to reflect new amounts immediately.
|
|
7
|
+
*/
|
|
8
|
+
refreshOnChain: () => void;
|
|
4
9
|
}
|
|
5
10
|
export declare function useUserActiveValidators(options?: DefaultHookOptions): UseUserActiveValidatorsResponse;
|
|
6
11
|
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useUserActiveValidators.d.ts","sourceRoot":"","sources":["../../../src/hooks/validators/useUserActiveValidators.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"useUserActiveValidators.d.ts","sourceRoot":"","sources":["../../../src/hooks/validators/useUserActiveValidators.ts"],"names":[],"mappings":"AAKA,OAAO,EAIL,KAAK,sBAAsB,EAC5B,MAAM,kDAAkD,CAAC;AAE1D,OAAO,KAAK,EACV,kBAAkB,EAClB,qBAAqB,EACtB,MAAM,oBAAoB,CAAC;AAE5B,UAAU,+BACR,SAAQ,qBAAqB,CAAC,sBAAsB,EAAE,GAAG,SAAS,CAAC;IACnE;;;OAGG;IACH,cAAc,EAAE,MAAM,IAAI,CAAC;CAC5B;AAED,wBAAgB,uBAAuB,CACrC,OAAO,CAAC,EAAE,kBAAkB,GAC3B,+BAA+B,CAyDjC"}
|
|
@@ -50,7 +50,6 @@ export declare function useValidator({ pubkey }: {
|
|
|
50
50
|
address: `0x${string}`;
|
|
51
51
|
dynamicData?: {
|
|
52
52
|
__typename?: "GqlRewardVaultDynamicData";
|
|
53
|
-
allTimeRewards: string;
|
|
54
53
|
apr?: number | null;
|
|
55
54
|
rewardCapturePercentage: number;
|
|
56
55
|
rewardCapturePerBlock: number;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useValidator.d.ts","sourceRoot":"","sources":["../../../src/hooks/validators/useValidator.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,OAAO,EAAa,MAAM,MAAM,CAAC;AAE/C,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,4BAA4B,CAAC;AAG1E,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAC;AAI7D,wBAAgB,YAAY,CAC1B,EAAE,MAAM,EAAE,EAAE;IAAE,MAAM,EAAE,OAAO,CAAA;CAAE,EAC/B,OAAO,EAAE,kBAAkB;;;;;;;;;;;;;;;;;;;;;0BAkDL,uBAAuB,CAAC,UAAU,CAAC;;;gBAIS,OAAO;oBAE9B,OAAO;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"useValidator.d.ts","sourceRoot":"","sources":["../../../src/hooks/validators/useValidator.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,OAAO,EAAa,MAAM,MAAM,CAAC;AAE/C,OAAO,KAAK,EAAE,uBAAuB,EAAE,MAAM,4BAA4B,CAAC;AAG1E,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAC;AAI7D,wBAAgB,YAAY,CAC1B,EAAE,MAAM,EAAE,EAAE;IAAE,MAAM,EAAE,OAAO,CAAA;CAAE,EAC/B,OAAO,EAAE,kBAAkB;;;;;;;;;;;;;;;;;;;;;0BAkDL,uBAAuB,CAAC,UAAU,CAAC;;;gBAIS,OAAO;oBAE9B,OAAO;;;;;;;;;;;;;;8BAc0wwG,CAAC;;;;;;+BAAwO,CAAC;kCAA8B,CAAC;2BAAkD,CAAC;;;;;2BAAuO,CAAC;;;kCAA6F,CAAC;;;;;;4BAAyL,CAAC;kCAA8B,CAAC;;;;;;;;;;;kCAA0Y,CAAC;;;;;;;;sCAAwU,CAAC;;;;;;;;;;;;;;;;;;;;;;;EAD52zG"}
|
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
import type { Address } from "viem";
|
|
2
|
-
import type { ValidatorIncentivesResponse } from "
|
|
2
|
+
import type { ValidatorIncentivesResponse } from "../../generated/beep";
|
|
3
3
|
import type { DefaultHookReturnType } from "../../types/global";
|
|
4
4
|
/**
|
|
5
|
-
* Historical per-validator incentive distribution
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
* `GetValidatorAnalytics` query.
|
|
5
|
+
* Historical per-validator incentive distribution, powering the
|
|
6
|
+
* IncentivesEarned chart. Owns its own data source so it can be swapped
|
|
7
|
+
* independently.
|
|
9
8
|
*/
|
|
10
9
|
export declare function useValidatorIncentiveDistribution({ pubkey, dayRange, }: {
|
|
11
10
|
pubkey: Address | undefined;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useValidatorIncentiveDistribution.d.ts","sourceRoot":"","sources":["../../../src/hooks/validators/useValidatorIncentiveDistribution.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,MAAM,CAAC;
|
|
1
|
+
{"version":3,"file":"useValidatorIncentiveDistribution.d.ts","sourceRoot":"","sources":["../../../src/hooks/validators/useValidatorIncentiveDistribution.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,MAAM,CAAC;AAMpC,OAAO,KAAK,EAAE,2BAA2B,EAAE,MAAM,sBAAsB,CAAC;AACxE,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,oBAAoB,CAAC;AAEhE;;;;GAIG;AACH,wBAAgB,iCAAiC,CAAC,EAChD,MAAM,EACN,QAAQ,GACT,EAAE;IACD,MAAM,EAAE,OAAO,GAAG,SAAS,CAAC;IAC5B,QAAQ,EAAE,MAAM,CAAC;CAClB,GAAG,qBAAqB,CAAC,2BAA2B,CAAC,CAerD"}
|
|
@@ -4,6 +4,7 @@ export declare function useValidatorRewardAllocation(pubKey: Address, options?:
|
|
|
4
4
|
activeRewardAllocation: import("../../actions/validators/getValidatorRewardAllocation").ValidatorRewardAllocation;
|
|
5
5
|
setRewardAllocation: import("../../actions/validators/getValidatorRewardAllocation").ValidatorRewardAllocation;
|
|
6
6
|
isBaseline: boolean;
|
|
7
|
+
isDefault: boolean;
|
|
7
8
|
isNeverSet: boolean;
|
|
8
9
|
}, any>;
|
|
9
10
|
//# sourceMappingURL=useValidatorRewardAllocation.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useValidatorRewardAllocation.d.ts","sourceRoot":"","sources":["../../../src/hooks/validators/useValidatorRewardAllocation.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAgB,MAAM,MAAM,CAAC;AAMlD,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAC;AAE7D,wBAAgB,4BAA4B,CAC1C,MAAM,EAAE,OAAO,EACf,OAAO,CAAC,EAAE,kBAAkB
|
|
1
|
+
{"version":3,"file":"useValidatorRewardAllocation.d.ts","sourceRoot":"","sources":["../../../src/hooks/validators/useValidatorRewardAllocation.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAgB,MAAM,MAAM,CAAC;AAMlD,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAC;AAE7D,wBAAgB,4BAA4B,CAC1C,MAAM,EAAE,OAAO,EACf,OAAO,CAAC,EAAE,kBAAkB;;;;;;QAoB7B"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"exports.d.ts","sourceRoot":"","sources":["../../../src/types/beep/exports.ts"],"names":[],"mappings":"AAGA,mBAAmB,sBAAsB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
//# sourceMappingURL=exports.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
|
|
@@ -1,37 +1,5 @@
|
|
|
1
1
|
import type { Address } from "viem";
|
|
2
2
|
|
|
3
|
-
export interface BribeBoostReward {
|
|
4
|
-
token: string;
|
|
5
|
-
total_unclaimed: string;
|
|
6
|
-
}
|
|
7
|
-
|
|
8
|
-
export interface BribeBoostRewardItem {
|
|
9
|
-
rewards: BribeBoostReward[];
|
|
10
|
-
validator: string;
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
export interface BribeBoostRewardProof {
|
|
14
|
-
validator?: string;
|
|
15
|
-
pagination: {
|
|
16
|
-
next: number;
|
|
17
|
-
previous: number;
|
|
18
|
-
record_per_page: number;
|
|
19
|
-
current_page: number;
|
|
20
|
-
total_page: number;
|
|
21
|
-
};
|
|
22
|
-
rewards:
|
|
23
|
-
| {
|
|
24
|
-
id: string;
|
|
25
|
-
dist_id: string;
|
|
26
|
-
token: Address;
|
|
27
|
-
recipient: string;
|
|
28
|
-
amount: string;
|
|
29
|
-
merkle_proof: string[];
|
|
30
|
-
available_at: number;
|
|
31
|
-
}[]
|
|
32
|
-
| null;
|
|
33
|
-
}
|
|
34
|
-
|
|
35
3
|
// Response shape of GET /api/v1/wallets/:wallet/autoclaimed:
|
|
36
4
|
// { [wallet]: { [validatorPubkey]: { [tokenAddress]: { amount } } } }
|
|
37
5
|
// `amount` is a stringified bigint in token base units. The backend now
|
|
@@ -50,20 +18,3 @@ export type AutoclaimedIncentivesTxHashResponse = Record<
|
|
|
50
18
|
Address,
|
|
51
19
|
Record<Address, Record<Address, { txhash: string }>>
|
|
52
20
|
>;
|
|
53
|
-
|
|
54
|
-
export interface BribeBoostValidatorApr {
|
|
55
|
-
id: string;
|
|
56
|
-
boost_total_bgt: string;
|
|
57
|
-
rewards_total_usd: string;
|
|
58
|
-
daily_rate: string;
|
|
59
|
-
apr: string;
|
|
60
|
-
apy: string;
|
|
61
|
-
tokens: Address[]; // Confirm this type with backend real data
|
|
62
|
-
validator: string;
|
|
63
|
-
start_block: number;
|
|
64
|
-
end_block: number;
|
|
65
|
-
start_timestamp: number;
|
|
66
|
-
end_timestamp: number;
|
|
67
|
-
created_at: string;
|
|
68
|
-
updated_at: string;
|
|
69
|
-
}
|
package/dist/types/dex.d.ts
CHANGED
|
@@ -195,6 +195,13 @@ export type Calldata = {
|
|
|
195
195
|
data?: Hex;
|
|
196
196
|
value: bigint;
|
|
197
197
|
gasLimit?: bigint;
|
|
198
|
+
/**
|
|
199
|
+
* Extra Sentry tags to attach when this calldata is submitted via `useTxn`.
|
|
200
|
+
* Aggregators set `{ aggregator: this.name }` so failures like
|
|
201
|
+
* AggregatorNotWhitelisted can be attributed to a source without decoding
|
|
202
|
+
* calldata.
|
|
203
|
+
*/
|
|
204
|
+
extraTags?: Record<string, string>;
|
|
198
205
|
};
|
|
199
206
|
|
|
200
207
|
export type IRawAggregatorQuote = {
|
|
@@ -208,6 +215,16 @@ export type IRawAggregatorQuote = {
|
|
|
208
215
|
isNativeSwap?: boolean;
|
|
209
216
|
priceImpactPercentage?: number | null;
|
|
210
217
|
swapFeeBps: number;
|
|
218
|
+
/** True when the route bridges chains; set by the aggregator (source of truth). */
|
|
219
|
+
isCrossChain?: boolean;
|
|
220
|
+
/** Chain the input token (and therefore the tx) lives on. */
|
|
221
|
+
srcChainId?: number;
|
|
222
|
+
/**
|
|
223
|
+
* Bridge the cross-chain route uses, from Enso's chosen bridge hop
|
|
224
|
+
* (`relay` | `stargate` | `ccip`). Drives which explorer/status API the
|
|
225
|
+
* tracker uses; undefined for same-chain routes.
|
|
226
|
+
*/
|
|
227
|
+
bridgeProtocol?: string;
|
|
211
228
|
getCalldata?: ({ account }: { account: Address }) => Calldata;
|
|
212
229
|
};
|
|
213
230
|
|
package/dist/types/enso.d.ts
CHANGED
|
@@ -1,26 +1,9 @@
|
|
|
1
|
-
import type { BundleData
|
|
1
|
+
import type { BundleData } from "@ensofinance/sdk";
|
|
2
2
|
import type { Address, Hex, PublicClient, TransactionRequest } from "viem";
|
|
3
3
|
|
|
4
4
|
import type { MinimalERC20 } from "./dex";
|
|
5
5
|
|
|
6
6
|
export type Quantity = string | number;
|
|
7
|
-
export type ActionOutputReference<T> = T | StrictOutputReference<T>;
|
|
8
|
-
type StrictOutputReference<T> = {
|
|
9
|
-
useOutputOfCallAt: number;
|
|
10
|
-
index?: number;
|
|
11
|
-
};
|
|
12
|
-
|
|
13
|
-
export interface GetEnsoSwapBundleArgs {
|
|
14
|
-
fromAddress: Address;
|
|
15
|
-
amountIn: Quantity;
|
|
16
|
-
tokenIn: Address;
|
|
17
|
-
tokenOut: Address;
|
|
18
|
-
chainId: number;
|
|
19
|
-
ensoClient: EnsoClient;
|
|
20
|
-
slippage: number;
|
|
21
|
-
destinationChainId?: number;
|
|
22
|
-
publicClient: PublicClient;
|
|
23
|
-
}
|
|
24
7
|
|
|
25
8
|
export type GetZapTransaction = TransactionRequest & {
|
|
26
9
|
to: Address;
|
|
@@ -29,15 +12,6 @@ export type GetZapTransaction = TransactionRequest & {
|
|
|
29
12
|
gasLimit?: bigint;
|
|
30
13
|
};
|
|
31
14
|
export type GetZapTransactions = GetZapTransaction[];
|
|
32
|
-
export interface GetZapTransactionsArgs {
|
|
33
|
-
fromAddress: Address;
|
|
34
|
-
amountIn: Quantity;
|
|
35
|
-
tokenIn: Address;
|
|
36
|
-
chainId: number;
|
|
37
|
-
ensoClient: EnsoClient;
|
|
38
|
-
bundle: BundleData;
|
|
39
|
-
publicClient: PublicClient;
|
|
40
|
-
}
|
|
41
15
|
|
|
42
16
|
export interface GetEnsoWalletTransactionsWithApprovalArgs {
|
|
43
17
|
fromAddress: Address;
|
package/dist/types/global.d.ts
CHANGED
|
@@ -94,6 +94,13 @@ export type IContractWrite<
|
|
|
94
94
|
*/
|
|
95
95
|
actionType: TransactionActionType;
|
|
96
96
|
txnName?: string;
|
|
97
|
+
/**
|
|
98
|
+
* Extra Sentry tags to attach to this transaction's scope, merged under the
|
|
99
|
+
* `operation.txn.*` namespace (e.g. `{ aggregator: "oogabooga" }` becomes the
|
|
100
|
+
* `operation.txn.aggregator` tag). Use for context that helps triage failures
|
|
101
|
+
* without decoding calldata.
|
|
102
|
+
*/
|
|
103
|
+
extraTags?: Record<string, string>;
|
|
97
104
|
gasLimit?: bigint;
|
|
98
105
|
account?: Account | Address;
|
|
99
106
|
/**
|
package/dist/types/pol.d.ts
CHANGED
|
@@ -1,49 +1,4 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
|
|
3
|
-
import type { ApiValidatorFragment } from "@berachain/graphql/pol/api";
|
|
4
|
-
|
|
5
|
-
import type { Token, TokenWithMetadata } from "./dex";
|
|
6
|
-
|
|
7
|
-
export type IncentiveReward = {
|
|
8
|
-
tokenMetadata: Token | undefined;
|
|
9
|
-
tokenPrice: number;
|
|
10
|
-
tokenValue: number;
|
|
11
|
-
id: string;
|
|
12
|
-
dist_id: string;
|
|
13
|
-
token: string;
|
|
14
|
-
recipient: string;
|
|
15
|
-
formattedAmount: string;
|
|
16
|
-
amount: string;
|
|
17
|
-
merkle_proof: string[];
|
|
18
|
-
available_at: number;
|
|
19
|
-
};
|
|
20
|
-
export interface IncentiveRewardChunksWithValidatorData {
|
|
21
|
-
validator: ApiValidatorInListFragment | ApiValidatorFragment | undefined;
|
|
22
|
-
maxTimestamp: number | undefined;
|
|
23
|
-
minTimestamp: number | undefined;
|
|
24
|
-
totalValue: number;
|
|
25
|
-
tokenTotals: {
|
|
26
|
-
chainId: number;
|
|
27
|
-
address: Address;
|
|
28
|
-
amount: number;
|
|
29
|
-
value: number;
|
|
30
|
-
metadata: Token | undefined;
|
|
31
|
-
}[];
|
|
32
|
-
rewards: IncentiveReward[];
|
|
33
|
-
isCurrent: boolean;
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
export interface AggregatedTokenTotals {
|
|
37
|
-
address: Address;
|
|
38
|
-
amount: number;
|
|
39
|
-
value: number;
|
|
40
|
-
metadata: Token | undefined;
|
|
41
|
-
chainId: number;
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
export type ClaimedIncentives = Record<string, string>;
|
|
45
|
-
|
|
46
|
-
export type ClaimedIncentivesLocalState = Record<string, ClaimedIncentives>;
|
|
1
|
+
import type { TokenWithMetadata } from "./dex";
|
|
47
2
|
|
|
48
3
|
export interface UserVaultInfo {
|
|
49
4
|
balance: bigint;
|
|
@@ -56,11 +11,11 @@ export interface UserVaultInfo {
|
|
|
56
11
|
export type StakedBeraAsset = {
|
|
57
12
|
token: TokenWithMetadata;
|
|
58
13
|
/**
|
|
59
|
-
* Staking
|
|
14
|
+
* Staking APY, or `undefined` when unavailable (e.g. the APY backend is
|
|
60
15
|
* down). `undefined` lets the UI render a "—" placeholder instead of a
|
|
61
16
|
* misleading "0%".
|
|
62
17
|
*/
|
|
63
|
-
|
|
18
|
+
apy: number | undefined;
|
|
64
19
|
stakedAmount: number;
|
|
65
20
|
/**
|
|
66
21
|
* USD value of the staked amount, or `undefined` when the token price is
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
export type BridgeProtocol = "relay" | "stargate" | "ccip" | "layerzero";
|
|
2
|
+
export declare enum BridgeMessageStatus {
|
|
3
|
+
INFLIGHT = "INFLIGHT",
|
|
4
|
+
DELIVERED = "DELIVERED",
|
|
5
|
+
FAILED = "FAILED"
|
|
6
|
+
}
|
|
7
|
+
export type BridgeMessage = {
|
|
8
|
+
srcTxHash?: string;
|
|
9
|
+
dstTxHash?: string;
|
|
10
|
+
status: BridgeMessageStatus;
|
|
11
|
+
statusMessage?: string;
|
|
12
|
+
/**
|
|
13
|
+
* Bridge-specific id for deep-linking the explorer, when the explorer keys
|
|
14
|
+
* on something other than the source tx hash (Relay uses its requestId).
|
|
15
|
+
*/
|
|
16
|
+
explorerId?: string;
|
|
17
|
+
};
|
|
18
|
+
export type BridgeDeliveredMessage = BridgeMessage & {
|
|
19
|
+
dstTxHash: string;
|
|
20
|
+
};
|
|
21
|
+
export interface BridgeExplorerUrlArgs {
|
|
22
|
+
/** Bridge Enso routed through; picks which explorer to link. */
|
|
23
|
+
bridgeProtocol?: string;
|
|
24
|
+
/** Source-chain tx hash — how LayerZero/Stargate + the fallback key. */
|
|
25
|
+
srcTxHash?: string;
|
|
26
|
+
/**
|
|
27
|
+
* Relay's requestId, when known. Relay's explorer prefers it but also resolves
|
|
28
|
+
* on the src tx hash, so a missing id still links to the bridge explorer.
|
|
29
|
+
*/
|
|
30
|
+
explorerId?: string;
|
|
31
|
+
/**
|
|
32
|
+
* Source-chain block explorer origin (e.g. https://etherscan.io). Only a
|
|
33
|
+
* last resort for an unknown/untracked bridge; tracked bridges always link to
|
|
34
|
+
* their own bridge explorer (which shows the src→dst delivery still in flight).
|
|
35
|
+
*/
|
|
36
|
+
fallbackExplorerUrl: string;
|
|
37
|
+
}
|
|
38
|
+
/**
|
|
39
|
+
* Deep-link a bridged tx to the right *bridge* explorer — the one showing the
|
|
40
|
+
* source→destination delivery, which is what's still in flight once a tracker is
|
|
41
|
+
* visible (the source tx already confirmed). Enso picks the bridge per-route, so
|
|
42
|
+
* a single hardcoded explorer is wrong for the others; each keys differently
|
|
43
|
+
* (LayerZero/Stargate on the src tx hash, Relay on its requestId or the src tx
|
|
44
|
+
* hash). Only a genuinely unknown protocol falls back to the source chain's own
|
|
45
|
+
* block explorer.
|
|
46
|
+
*
|
|
47
|
+
* We deliberately don't route this through Enso's `getBridgeStatus`
|
|
48
|
+
* (`/{protocol}/bridge/check`): it normalizes status but doesn't return Relay's
|
|
49
|
+
* requestId, which the Relay deep link prefers — so we'd still branch per bridge.
|
|
50
|
+
*/
|
|
51
|
+
export declare function getBridgeExplorerUrl({ bridgeProtocol, srcTxHash, explorerId, fallbackExplorerUrl, }: BridgeExplorerUrlArgs): string | undefined;
|
|
52
|
+
/**
|
|
53
|
+
* One-shot status lookup for a bridged tx. Used to grab the explorer id (e.g.
|
|
54
|
+
* Relay's requestId) for the pending-state link before delivery. Swallows
|
|
55
|
+
* errors into an INFLIGHT result so a not-yet-indexed tx doesn't throw.
|
|
56
|
+
*/
|
|
57
|
+
export declare function getBridgeMessageOnce(bridgeProtocol: string, srcTxHash: string): Promise<BridgeMessage>;
|
|
58
|
+
export type WaitForMessageReceivedOptions = {
|
|
59
|
+
/** Which bridge Enso routed through; narrowed at getBridgeMessage's switch. */
|
|
60
|
+
bridgeProtocol: string;
|
|
61
|
+
/** Polling interval in ms (default: 3000). */
|
|
62
|
+
pollInterval?: number;
|
|
63
|
+
/** Timeout in ms (default: 600000 / 10 minutes). */
|
|
64
|
+
timeout?: number;
|
|
65
|
+
};
|
|
66
|
+
/**
|
|
67
|
+
* Polls the bridge's status API until the cross-chain message is delivered or
|
|
68
|
+
* fails, then resolves with the delivered message (incl. destination tx hash).
|
|
69
|
+
* HTTP errors are silently retried until timeout. Throws InvalidArgumentError
|
|
70
|
+
* if srcTxHash/bridgeProtocol is missing or unsupported, or BeraError if the
|
|
71
|
+
* message fails or times out.
|
|
72
|
+
*/
|
|
73
|
+
export declare function waitForBridgeMessageReceived(srcTxHash: string, options: WaitForMessageReceivedOptions): Promise<BridgeDeliveredMessage>;
|
|
74
|
+
//# sourceMappingURL=crossChainBridge.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"crossChainBridge.d.ts","sourceRoot":"","sources":["../../src/utils/crossChainBridge.ts"],"names":[],"mappings":"AASA,MAAM,MAAM,cAAc,GAAG,OAAO,GAAG,UAAU,GAAG,MAAM,GAAG,WAAW,CAAC;AAQzE,oBAAY,mBAAmB;IAC7B,QAAQ,aAAa;IACrB,SAAS,cAAc;IACvB,MAAM,WAAW;CAClB;AAED,MAAM,MAAM,aAAa,GAAG;IAC1B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,MAAM,EAAE,mBAAmB,CAAC;IAC5B,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB;;;OAGG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB,CAAC;AAEF,MAAM,MAAM,sBAAsB,GAAG,aAAa,GAAG;IACnD,SAAS,EAAE,MAAM,CAAC;CACnB,CAAC;AA4GF,MAAM,WAAW,qBAAqB;IACpC,gEAAgE;IAChE,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,wEAAwE;IACxE,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;;OAGG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB;;;;OAIG;IACH,mBAAmB,EAAE,MAAM,CAAC;CAC7B;AAED;;;;;;;;;;;;GAYG;AACH,wBAAgB,oBAAoB,CAAC,EACnC,cAAc,EACd,SAAS,EACT,UAAU,EACV,mBAAmB,GACpB,EAAE,qBAAqB,GAAG,MAAM,GAAG,SAAS,CAmB5C;AAED;;;;GAIG;AACH,wBAAsB,oBAAoB,CACxC,cAAc,EAAE,MAAM,EACtB,SAAS,EAAE,MAAM,GAChB,OAAO,CAAC,aAAa,CAAC,CAMxB;AAED,MAAM,MAAM,6BAA6B,GAAG;IAC1C,+EAA+E;IAC/E,cAAc,EAAE,MAAM,CAAC;IACvB,8CAA8C;IAC9C,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,oDAAoD;IACpD,OAAO,CAAC,EAAE,MAAM,CAAC;CAClB,CAAC;AAEF;;;;;;GAMG;AACH,wBAAsB,4BAA4B,CAChD,SAAS,EAAE,MAAM,EACjB,OAAO,EAAE,6BAA6B,GACrC,OAAO,CAAC,sBAAsB,CAAC,CAoDjC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"crossChainBridge.unit.test.d.ts","sourceRoot":"","sources":["../../src/utils/crossChainBridge.unit.test.ts"],"names":[],"mappings":""}
|
package/dist/utils/exports.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
export { defaultFlags as defaultBeraFlags } from "../contexts/BeraFlags/defaultFlags";
|
|
2
2
|
export * from "./beraFetch";
|
|
3
3
|
export * from "./constants";
|
|
4
|
+
export * from "./crossChainBridge";
|
|
4
5
|
export * from "./formatInputTokenValue";
|
|
5
6
|
export * from "./formatNumber";
|
|
6
7
|
export * from "./formatTimestamps";
|
|
@@ -11,7 +12,6 @@ export * from "./getServerSideClient";
|
|
|
11
12
|
export { getTestClient } from "./getTestClient";
|
|
12
13
|
export * from "./isDifferenceExceedingThreshold";
|
|
13
14
|
export * from "./isSubgraphStale";
|
|
14
|
-
export * from "./layerZeroScan";
|
|
15
15
|
export * from "./math";
|
|
16
16
|
export * from "./parseBaseArgs";
|
|
17
17
|
export * from "./parseWhiskToken";
|