@xyo-network/xl1-protocol 1.25.33 → 1.26.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/neutral/index.d.ts +4 -24
- package/dist/neutral/index.d.ts.map +1 -1
- package/dist/neutral/index.mjs +5 -2047
- package/dist/neutral/index.mjs.map +1 -1
- package/package.json +17 -14
- package/src/index.ts +4 -24
- package/LICENSE +0 -165
- package/README.md +0 -81
- package/dist/neutral/BlockNumber/BlockNumber.d.ts +0 -35
- package/dist/neutral/BlockNumber/BlockNumber.d.ts.map +0 -1
- package/dist/neutral/BlockNumber/EthBlockNumber.d.ts +0 -46
- package/dist/neutral/BlockNumber/EthBlockNumber.d.ts.map +0 -1
- package/dist/neutral/BlockNumber/Numberish.d.ts +0 -6
- package/dist/neutral/BlockNumber/Numberish.d.ts.map +0 -1
- package/dist/neutral/BlockNumber/XL1BlockNumber.d.ts +0 -46
- package/dist/neutral/BlockNumber/XL1BlockNumber.d.ts.map +0 -1
- package/dist/neutral/BlockNumber/index.d.ts +0 -5
- package/dist/neutral/BlockNumber/index.d.ts.map +0 -1
- package/dist/neutral/Initializable.d.ts +0 -9
- package/dist/neutral/Initializable.d.ts.map +0 -1
- package/dist/neutral/OpenTelemetryProviders.d.ts +0 -7
- package/dist/neutral/OpenTelemetryProviders.d.ts.map +0 -1
- package/dist/neutral/RecordKeyType.d.ts +0 -4
- package/dist/neutral/RecordKeyType.d.ts.map +0 -1
- package/dist/neutral/Step/StepHash.d.ts +0 -11
- package/dist/neutral/Step/StepHash.d.ts.map +0 -1
- package/dist/neutral/Step/StepIdentity.d.ts +0 -19
- package/dist/neutral/Step/StepIdentity.d.ts.map +0 -1
- package/dist/neutral/Step/StepSizes.d.ts +0 -12
- package/dist/neutral/Step/StepSizes.d.ts.map +0 -1
- package/dist/neutral/Step/index.d.ts +0 -4
- package/dist/neutral/Step/index.d.ts.map +0 -1
- package/dist/neutral/TransferPayload.d.ts +0 -79
- package/dist/neutral/TransferPayload.d.ts.map +0 -1
- package/dist/neutral/amount/ShiftedBigIntConfig.d.ts +0 -9
- package/dist/neutral/amount/ShiftedBigIntConfig.d.ts.map +0 -1
- package/dist/neutral/amount/XL1AmountInstance.d.ts +0 -16
- package/dist/neutral/amount/XL1AmountInstance.d.ts.map +0 -1
- package/dist/neutral/amount/index.d.ts +0 -3
- package/dist/neutral/amount/index.d.ts.map +0 -1
- package/dist/neutral/block/AllowedBlockPayload.d.ts +0 -40
- package/dist/neutral/block/AllowedBlockPayload.d.ts.map +0 -1
- package/dist/neutral/block/BlockBoundWitness.d.ts +0 -544
- package/dist/neutral/block/BlockBoundWitness.d.ts.map +0 -1
- package/dist/neutral/block/HydratedBlock.d.ts +0 -1466
- package/dist/neutral/block/HydratedBlock.d.ts.map +0 -1
- package/dist/neutral/block/index.d.ts +0 -6
- package/dist/neutral/block/index.d.ts.map +0 -1
- package/dist/neutral/block/signed/SignedBlockBoundWitness.d.ts +0 -168
- package/dist/neutral/block/signed/SignedBlockBoundWitness.d.ts.map +0 -1
- package/dist/neutral/block/signed/SignedBlockBoundWitnessWithHashMeta.d.ts +0 -286
- package/dist/neutral/block/signed/SignedBlockBoundWitnessWithHashMeta.d.ts.map +0 -1
- package/dist/neutral/block/signed/SignedBlockBoundWitnessWithStorageMeta.d.ts +0 -343
- package/dist/neutral/block/signed/SignedBlockBoundWitnessWithStorageMeta.d.ts.map +0 -1
- package/dist/neutral/block/signed/index.d.ts +0 -4
- package/dist/neutral/block/signed/index.d.ts.map +0 -1
- package/dist/neutral/block/unsigned/UnsignedBlockBoundWitness.d.ts +0 -168
- package/dist/neutral/block/unsigned/UnsignedBlockBoundWitness.d.ts.map +0 -1
- package/dist/neutral/block/unsigned/index.d.ts +0 -2
- package/dist/neutral/block/unsigned/index.d.ts.map +0 -1
- package/dist/neutral/chain/Chain.d.ts +0 -4
- package/dist/neutral/chain/Chain.d.ts.map +0 -1
- package/dist/neutral/chain/ChainAnalyzer.d.ts +0 -10
- package/dist/neutral/chain/ChainAnalyzer.d.ts.map +0 -1
- package/dist/neutral/chain/ChainId.d.ts +0 -4
- package/dist/neutral/chain/ChainId.d.ts.map +0 -1
- package/dist/neutral/chain/index.d.ts +0 -4
- package/dist/neutral/chain/index.d.ts.map +0 -1
- package/dist/neutral/fields/Addressable.d.ts +0 -6
- package/dist/neutral/fields/Addressable.d.ts.map +0 -1
- package/dist/neutral/fields/BlockDuration.d.ts +0 -25
- package/dist/neutral/fields/BlockDuration.d.ts.map +0 -1
- package/dist/neutral/fields/BlockNumber.d.ts +0 -32
- package/dist/neutral/fields/BlockNumber.d.ts.map +0 -1
- package/dist/neutral/fields/ChainReference.d.ts +0 -11
- package/dist/neutral/fields/ChainReference.d.ts.map +0 -1
- package/dist/neutral/fields/index.d.ts +0 -5
- package/dist/neutral/fields/index.d.ts.map +0 -1
- package/dist/neutral/map/AsyncMap.d.ts +0 -42
- package/dist/neutral/map/AsyncMap.d.ts.map +0 -1
- package/dist/neutral/map/MapType.d.ts +0 -17
- package/dist/neutral/map/MapType.d.ts.map +0 -1
- package/dist/neutral/map/SyncMap.d.ts +0 -41
- package/dist/neutral/map/SyncMap.d.ts.map +0 -1
- package/dist/neutral/map/index.d.ts +0 -4
- package/dist/neutral/map/index.d.ts.map +0 -1
- package/dist/neutral/model/AccountBalance.d.ts +0 -133
- package/dist/neutral/model/AccountBalance.d.ts.map +0 -1
- package/dist/neutral/model/ArrayBuffer.d.ts +0 -6
- package/dist/neutral/model/ArrayBuffer.d.ts.map +0 -1
- package/dist/neutral/model/BlockRange/BlockRange.d.ts +0 -32
- package/dist/neutral/model/BlockRange/BlockRange.d.ts.map +0 -1
- package/dist/neutral/model/BlockRange/EthBlockRange.d.ts +0 -32
- package/dist/neutral/model/BlockRange/EthBlockRange.d.ts.map +0 -1
- package/dist/neutral/model/BlockRange/Numberish.d.ts +0 -4
- package/dist/neutral/model/BlockRange/Numberish.d.ts.map +0 -1
- package/dist/neutral/model/BlockRange/Range.d.ts +0 -18
- package/dist/neutral/model/BlockRange/Range.d.ts.map +0 -1
- package/dist/neutral/model/BlockRange/XL1BlockRange.d.ts +0 -32
- package/dist/neutral/model/BlockRange/XL1BlockRange.d.ts.map +0 -1
- package/dist/neutral/model/BlockRange/index.d.ts +0 -5
- package/dist/neutral/model/BlockRange/index.d.ts.map +0 -1
- package/dist/neutral/model/BlockRate.d.ts +0 -290
- package/dist/neutral/model/BlockRate.d.ts.map +0 -1
- package/dist/neutral/model/ChainQualification.d.ts +0 -57
- package/dist/neutral/model/ChainQualification.d.ts.map +0 -1
- package/dist/neutral/model/Context/BaseContext.d.ts +0 -5
- package/dist/neutral/model/Context/BaseContext.d.ts.map +0 -1
- package/dist/neutral/model/Context/BaseContext.zod.d.ts +0 -26
- package/dist/neutral/model/Context/BaseContext.zod.d.ts.map +0 -1
- package/dist/neutral/model/Context/BlockContext.d.ts +0 -9
- package/dist/neutral/model/Context/BlockContext.d.ts.map +0 -1
- package/dist/neutral/model/Context/BlockContext.zod.d.ts +0 -33
- package/dist/neutral/model/Context/BlockContext.zod.d.ts.map +0 -1
- package/dist/neutral/model/Context/CachingContext.d.ts +0 -5
- package/dist/neutral/model/Context/CachingContext.d.ts.map +0 -1
- package/dist/neutral/model/Context/CachingContext.zod.d.ts +0 -10
- package/dist/neutral/model/Context/CachingContext.zod.d.ts.map +0 -1
- package/dist/neutral/model/Context/ChainContext.d.ts +0 -9
- package/dist/neutral/model/Context/ChainContext.d.ts.map +0 -1
- package/dist/neutral/model/Context/ChainContext.zod.d.ts +0 -115
- package/dist/neutral/model/Context/ChainContext.zod.d.ts.map +0 -1
- package/dist/neutral/model/Context/HeadContext.d.ts +0 -5
- package/dist/neutral/model/Context/HeadContext.d.ts.map +0 -1
- package/dist/neutral/model/Context/HeadContext.zod.d.ts +0 -70
- package/dist/neutral/model/Context/HeadContext.zod.d.ts.map +0 -1
- package/dist/neutral/model/Context/index.d.ts +0 -11
- package/dist/neutral/model/Context/index.d.ts.map +0 -1
- package/dist/neutral/model/GatewayName.d.ts +0 -6
- package/dist/neutral/model/GatewayName.d.ts.map +0 -1
- package/dist/neutral/model/HydratedTransaction.d.ts +0 -2300
- package/dist/neutral/model/HydratedTransaction.d.ts.map +0 -1
- package/dist/neutral/model/OpCodes.d.ts +0 -3
- package/dist/neutral/model/OpCodes.d.ts.map +0 -1
- package/dist/neutral/model/PayloadMap.d.ts +0 -10
- package/dist/neutral/model/PayloadMap.d.ts.map +0 -1
- package/dist/neutral/model/Permission.d.ts +0 -59
- package/dist/neutral/model/Permission.d.ts.map +0 -1
- package/dist/neutral/model/Position.d.ts +0 -13
- package/dist/neutral/model/Position.d.ts.map +0 -1
- package/dist/neutral/model/PositionId.d.ts +0 -6
- package/dist/neutral/model/PositionId.d.ts.map +0 -1
- package/dist/neutral/model/RangeMultipliers.d.ts +0 -10
- package/dist/neutral/model/RangeMultipliers.d.ts.map +0 -1
- package/dist/neutral/model/RewardShare.d.ts +0 -3
- package/dist/neutral/model/RewardShare.d.ts.map +0 -1
- package/dist/neutral/model/RewardsRangeOptions.d.ts +0 -16
- package/dist/neutral/model/RewardsRangeOptions.d.ts.map +0 -1
- package/dist/neutral/model/Sequence.d.ts +0 -15
- package/dist/neutral/model/Sequence.d.ts.map +0 -1
- package/dist/neutral/model/Stake.d.ts +0 -121
- package/dist/neutral/model/Stake.d.ts.map +0 -1
- package/dist/neutral/model/StakeShare.d.ts +0 -3
- package/dist/neutral/model/StakeShare.d.ts.map +0 -1
- package/dist/neutral/model/TimeDomain.d.ts +0 -4
- package/dist/neutral/model/TimeDomain.d.ts.map +0 -1
- package/dist/neutral/model/TransferPair.d.ts +0 -12
- package/dist/neutral/model/TransferPair.d.ts.map +0 -1
- package/dist/neutral/model/addresses.d.ts +0 -28
- package/dist/neutral/model/addresses.d.ts.map +0 -1
- package/dist/neutral/model/defaultRewardRatio.d.ts +0 -3
- package/dist/neutral/model/defaultRewardRatio.d.ts.map +0 -1
- package/dist/neutral/model/defaultTransactionFees.d.ts +0 -4
- package/dist/neutral/model/defaultTransactionFees.d.ts.map +0 -1
- package/dist/neutral/model/index.d.ts +0 -28
- package/dist/neutral/model/index.d.ts.map +0 -1
- package/dist/neutral/model/minTransactionFees.d.ts +0 -4
- package/dist/neutral/model/minTransactionFees.d.ts.map +0 -1
- package/dist/neutral/model/rewards.d.ts +0 -15
- package/dist/neutral/model/rewards.d.ts.map +0 -1
- package/dist/neutral/model/version.d.ts +0 -11
- package/dist/neutral/model/version.d.ts.map +0 -1
- package/dist/neutral/network/NetworkId.d.ts +0 -12
- package/dist/neutral/network/NetworkId.d.ts.map +0 -1
- package/dist/neutral/network/Status.d.ts +0 -26
- package/dist/neutral/network/Status.d.ts.map +0 -1
- package/dist/neutral/network/index.d.ts +0 -3
- package/dist/neutral/network/index.d.ts.map +0 -1
- package/dist/neutral/payload/StepIdentityPayload.d.ts +0 -20
- package/dist/neutral/payload/StepIdentityPayload.d.ts.map +0 -1
- package/dist/neutral/payload/elevatable/Bridge/BridgeCompletion.d.ts +0 -23
- package/dist/neutral/payload/elevatable/Bridge/BridgeCompletion.d.ts.map +0 -1
- package/dist/neutral/payload/elevatable/Bridge/BridgeDestinationObservation.d.ts +0 -33
- package/dist/neutral/payload/elevatable/Bridge/BridgeDestinationObservation.d.ts.map +0 -1
- package/dist/neutral/payload/elevatable/Bridge/BridgeDetails.d.ts +0 -45
- package/dist/neutral/payload/elevatable/Bridge/BridgeDetails.d.ts.map +0 -1
- package/dist/neutral/payload/elevatable/Bridge/BridgeIntent.d.ts +0 -31
- package/dist/neutral/payload/elevatable/Bridge/BridgeIntent.d.ts.map +0 -1
- package/dist/neutral/payload/elevatable/Bridge/BridgeSourceObservation.d.ts +0 -33
- package/dist/neutral/payload/elevatable/Bridge/BridgeSourceObservation.d.ts.map +0 -1
- package/dist/neutral/payload/elevatable/Bridge/index.d.ts +0 -6
- package/dist/neutral/payload/elevatable/Bridge/index.d.ts.map +0 -1
- package/dist/neutral/payload/elevatable/ChainStakeIntent.d.ts +0 -24
- package/dist/neutral/payload/elevatable/ChainStakeIntent.d.ts.map +0 -1
- package/dist/neutral/payload/elevatable/Executable.d.ts +0 -20
- package/dist/neutral/payload/elevatable/Executable.d.ts.map +0 -1
- package/dist/neutral/payload/elevatable/Hash.d.ts +0 -21
- package/dist/neutral/payload/elevatable/Hash.d.ts.map +0 -1
- package/dist/neutral/payload/elevatable/StepComplete.d.ts +0 -22
- package/dist/neutral/payload/elevatable/StepComplete.d.ts.map +0 -1
- package/dist/neutral/payload/elevatable/Time.d.ts +0 -71
- package/dist/neutral/payload/elevatable/Time.d.ts.map +0 -1
- package/dist/neutral/payload/elevatable/index.d.ts +0 -7
- package/dist/neutral/payload/elevatable/index.d.ts.map +0 -1
- package/dist/neutral/payload/index.d.ts +0 -3
- package/dist/neutral/payload/index.d.ts.map +0 -1
- package/dist/neutral/permissions/InvokerPermission.d.ts +0 -53
- package/dist/neutral/permissions/InvokerPermission.d.ts.map +0 -1
- package/dist/neutral/permissions/XyoPermissions.d.ts +0 -33
- package/dist/neutral/permissions/XyoPermissions.d.ts.map +0 -1
- package/dist/neutral/permissions/index.d.ts +0 -3
- package/dist/neutral/permissions/index.d.ts.map +0 -1
- package/dist/neutral/provider/Provider.d.ts +0 -6
- package/dist/neutral/provider/Provider.d.ts.map +0 -1
- package/dist/neutral/provider/ProviderMoniker.d.ts +0 -9
- package/dist/neutral/provider/ProviderMoniker.d.ts.map +0 -1
- package/dist/neutral/provider/index.d.ts +0 -3
- package/dist/neutral/provider/index.d.ts.map +0 -1
- package/dist/neutral/providers/DataLake/Provider.d.ts +0 -10
- package/dist/neutral/providers/DataLake/Provider.d.ts.map +0 -1
- package/dist/neutral/providers/DataLake/Runner.d.ts +0 -15
- package/dist/neutral/providers/DataLake/Runner.d.ts.map +0 -1
- package/dist/neutral/providers/DataLake/Viewer.d.ts +0 -14
- package/dist/neutral/providers/DataLake/Viewer.d.ts.map +0 -1
- package/dist/neutral/providers/DataLake/index.d.ts +0 -4
- package/dist/neutral/providers/DataLake/index.d.ts.map +0 -1
- package/dist/neutral/providers/TransactionHelper.d.ts +0 -9
- package/dist/neutral/providers/TransactionHelper.d.ts.map +0 -1
- package/dist/neutral/providers/XyoClient.d.ts +0 -23
- package/dist/neutral/providers/XyoClient.d.ts.map +0 -1
- package/dist/neutral/providers/XyoConnection.d.ts +0 -18
- package/dist/neutral/providers/XyoConnection.d.ts.map +0 -1
- package/dist/neutral/providers/XyoGateway.d.ts +0 -20
- package/dist/neutral/providers/XyoGateway.d.ts.map +0 -1
- package/dist/neutral/providers/XyoGatewayRunner.d.ts +0 -55
- package/dist/neutral/providers/XyoGatewayRunner.d.ts.map +0 -1
- package/dist/neutral/providers/XyoNetwork.d.ts +0 -7
- package/dist/neutral/providers/XyoNetwork.d.ts.map +0 -1
- package/dist/neutral/providers/XyoRunner.d.ts +0 -17
- package/dist/neutral/providers/XyoRunner.d.ts.map +0 -1
- package/dist/neutral/providers/index.d.ts +0 -9
- package/dist/neutral/providers/index.d.ts.map +0 -1
- package/dist/neutral/providers/signer/XyoSigner.d.ts +0 -25
- package/dist/neutral/providers/signer/XyoSigner.d.ts.map +0 -1
- package/dist/neutral/providers/signer/index.d.ts +0 -2
- package/dist/neutral/providers/signer/index.d.ts.map +0 -1
- package/dist/neutral/repository/Repository.d.ts +0 -27
- package/dist/neutral/repository/Repository.d.ts.map +0 -1
- package/dist/neutral/repository/TransactionReadRepository.d.ts +0 -7
- package/dist/neutral/repository/TransactionReadRepository.d.ts.map +0 -1
- package/dist/neutral/repository/TransactionRepository.d.ts +0 -13
- package/dist/neutral/repository/TransactionRepository.d.ts.map +0 -1
- package/dist/neutral/repository/TransactionRepositoryIterator.d.ts +0 -7
- package/dist/neutral/repository/TransactionRepositoryIterator.d.ts.map +0 -1
- package/dist/neutral/repository/TransactionWriteRepository.d.ts +0 -6
- package/dist/neutral/repository/TransactionWriteRepository.d.ts.map +0 -1
- package/dist/neutral/repository/index.d.ts +0 -6
- package/dist/neutral/repository/index.d.ts.map +0 -1
- package/dist/neutral/runners/Block.d.ts +0 -17
- package/dist/neutral/runners/Block.d.ts.map +0 -1
- package/dist/neutral/runners/Finalization.d.ts +0 -16
- package/dist/neutral/runners/Finalization.d.ts.map +0 -1
- package/dist/neutral/runners/Mempool.d.ts +0 -27
- package/dist/neutral/runners/Mempool.d.ts.map +0 -1
- package/dist/neutral/runners/index.d.ts +0 -4
- package/dist/neutral/runners/index.d.ts.map +0 -1
- package/dist/neutral/transaction/TransactionBoundWitness.d.ts +0 -2127
- package/dist/neutral/transaction/TransactionBoundWitness.d.ts.map +0 -1
- package/dist/neutral/transaction/TransactionFees.d.ts +0 -138
- package/dist/neutral/transaction/TransactionFees.d.ts.map +0 -1
- package/dist/neutral/transaction/TransactionGasCosts.d.ts +0 -38
- package/dist/neutral/transaction/TransactionGasCosts.d.ts.map +0 -1
- package/dist/neutral/transaction/index.d.ts +0 -4
- package/dist/neutral/transaction/index.d.ts.map +0 -1
- package/dist/neutral/validation/block/BlockValidationFunction.d.ts +0 -8
- package/dist/neutral/validation/block/BlockValidationFunction.d.ts.map +0 -1
- package/dist/neutral/validation/block/HydratedBlockStateValidationFunction.d.ts +0 -22
- package/dist/neutral/validation/block/HydratedBlockStateValidationFunction.d.ts.map +0 -1
- package/dist/neutral/validation/block/HydratedBlockValidationFunction.d.ts +0 -17
- package/dist/neutral/validation/block/HydratedBlockValidationFunction.d.ts.map +0 -1
- package/dist/neutral/validation/block/error.d.ts +0 -22
- package/dist/neutral/validation/block/error.d.ts.map +0 -1
- package/dist/neutral/validation/block/index.d.ts +0 -5
- package/dist/neutral/validation/block/index.d.ts.map +0 -1
- package/dist/neutral/validation/boundwitness/BoundWitnessValidationFunction.d.ts +0 -6
- package/dist/neutral/validation/boundwitness/BoundWitnessValidationFunction.d.ts.map +0 -1
- package/dist/neutral/validation/boundwitness/HydratedBoundWitnessValidationFunction.d.ts +0 -8
- package/dist/neutral/validation/boundwitness/HydratedBoundWitnessValidationFunction.d.ts.map +0 -1
- package/dist/neutral/validation/boundwitness/error.d.ts +0 -13
- package/dist/neutral/validation/boundwitness/error.d.ts.map +0 -1
- package/dist/neutral/validation/boundwitness/index.d.ts +0 -4
- package/dist/neutral/validation/boundwitness/index.d.ts.map +0 -1
- package/dist/neutral/validation/error.d.ts +0 -11
- package/dist/neutral/validation/error.d.ts.map +0 -1
- package/dist/neutral/validation/index.d.ts +0 -6
- package/dist/neutral/validation/index.d.ts.map +0 -1
- package/dist/neutral/validation/payload/InBlockPayloadValidationFunction.d.ts +0 -11
- package/dist/neutral/validation/payload/InBlockPayloadValidationFunction.d.ts.map +0 -1
- package/dist/neutral/validation/payload/error.d.ts +0 -12
- package/dist/neutral/validation/payload/error.d.ts.map +0 -1
- package/dist/neutral/validation/payload/index.d.ts +0 -3
- package/dist/neutral/validation/payload/index.d.ts.map +0 -1
- package/dist/neutral/validation/transaction/HydratedTransactionStateValidationFunction.d.ts +0 -19
- package/dist/neutral/validation/transaction/HydratedTransactionStateValidationFunction.d.ts.map +0 -1
- package/dist/neutral/validation/transaction/HydratedTransactionValidationFunction.d.ts +0 -18
- package/dist/neutral/validation/transaction/HydratedTransactionValidationFunction.d.ts.map +0 -1
- package/dist/neutral/validation/transaction/error.d.ts +0 -8
- package/dist/neutral/validation/transaction/error.d.ts.map +0 -1
- package/dist/neutral/validation/transaction/index.d.ts +0 -4
- package/dist/neutral/validation/transaction/index.d.ts.map +0 -1
- package/dist/neutral/viewers/Block.d.ts +0 -33
- package/dist/neutral/viewers/Block.d.ts.map +0 -1
- package/dist/neutral/viewers/BlockInvalidation.d.ts +0 -69
- package/dist/neutral/viewers/BlockInvalidation.d.ts.map +0 -1
- package/dist/neutral/viewers/BlockReward.d.ts +0 -16
- package/dist/neutral/viewers/BlockReward.d.ts.map +0 -1
- package/dist/neutral/viewers/BlockValidation.d.ts +0 -69
- package/dist/neutral/viewers/BlockValidation.d.ts.map +0 -1
- package/dist/neutral/viewers/ChainContract.d.ts +0 -24
- package/dist/neutral/viewers/ChainContract.d.ts.map +0 -1
- package/dist/neutral/viewers/ChainStakeViewer.d.ts +0 -11
- package/dist/neutral/viewers/ChainStakeViewer.d.ts.map +0 -1
- package/dist/neutral/viewers/Finalization.d.ts +0 -21
- package/dist/neutral/viewers/Finalization.d.ts.map +0 -1
- package/dist/neutral/viewers/Fork.d.ts +0 -9
- package/dist/neutral/viewers/Fork.d.ts.map +0 -1
- package/dist/neutral/viewers/Mempool.d.ts +0 -33
- package/dist/neutral/viewers/Mempool.d.ts.map +0 -1
- package/dist/neutral/viewers/NetworkStake/NetworkStakeViewer.d.ts +0 -17
- package/dist/neutral/viewers/NetworkStake/NetworkStakeViewer.d.ts.map +0 -1
- package/dist/neutral/viewers/NetworkStake/Rewards/ByPositionViewer.d.ts +0 -14
- package/dist/neutral/viewers/NetworkStake/Rewards/ByPositionViewer.d.ts.map +0 -1
- package/dist/neutral/viewers/NetworkStake/Rewards/ByStakerViewer.d.ts +0 -15
- package/dist/neutral/viewers/NetworkStake/Rewards/ByStakerViewer.d.ts.map +0 -1
- package/dist/neutral/viewers/NetworkStake/Rewards/ByStepViewer.d.ts +0 -15
- package/dist/neutral/viewers/NetworkStake/Rewards/ByStepViewer.d.ts.map +0 -1
- package/dist/neutral/viewers/NetworkStake/Rewards/Options.d.ts +0 -20
- package/dist/neutral/viewers/NetworkStake/Rewards/Options.d.ts.map +0 -1
- package/dist/neutral/viewers/NetworkStake/Rewards/TotalViewer.d.ts +0 -15
- package/dist/neutral/viewers/NetworkStake/Rewards/TotalViewer.d.ts.map +0 -1
- package/dist/neutral/viewers/NetworkStake/Rewards/Viewer.d.ts +0 -20
- package/dist/neutral/viewers/NetworkStake/Rewards/Viewer.d.ts.map +0 -1
- package/dist/neutral/viewers/NetworkStake/Rewards/index.d.ts +0 -8
- package/dist/neutral/viewers/NetworkStake/Rewards/index.d.ts.map +0 -1
- package/dist/neutral/viewers/NetworkStake/Rewards/templates/ByIndexMethodsTemplate.d.ts +0 -7
- package/dist/neutral/viewers/NetworkStake/Rewards/templates/ByIndexMethodsTemplate.d.ts.map +0 -1
- package/dist/neutral/viewers/NetworkStake/Rewards/templates/MethodsTemplate.d.ts +0 -10
- package/dist/neutral/viewers/NetworkStake/Rewards/templates/MethodsTemplate.d.ts.map +0 -1
- package/dist/neutral/viewers/NetworkStake/Rewards/templates/index.d.ts +0 -3
- package/dist/neutral/viewers/NetworkStake/Rewards/templates/index.d.ts.map +0 -1
- package/dist/neutral/viewers/NetworkStake/index.d.ts +0 -3
- package/dist/neutral/viewers/NetworkStake/index.d.ts.map +0 -1
- package/dist/neutral/viewers/NetworkStakeStepReward.d.ts +0 -42
- package/dist/neutral/viewers/NetworkStakeStepReward.d.ts.map +0 -1
- package/dist/neutral/viewers/Stake.d.ts +0 -39
- package/dist/neutral/viewers/Stake.d.ts.map +0 -1
- package/dist/neutral/viewers/StakeEvents.d.ts +0 -44
- package/dist/neutral/viewers/StakeEvents.d.ts.map +0 -1
- package/dist/neutral/viewers/StakeIntent.d.ts +0 -17
- package/dist/neutral/viewers/StakeIntent.d.ts.map +0 -1
- package/dist/neutral/viewers/StakeTotals.d.ts +0 -20
- package/dist/neutral/viewers/StakeTotals.d.ts.map +0 -1
- package/dist/neutral/viewers/StepStake.d.ts +0 -15
- package/dist/neutral/viewers/StepStake.d.ts.map +0 -1
- package/dist/neutral/viewers/StepViewer.d.ts +0 -39
- package/dist/neutral/viewers/StepViewer.d.ts.map +0 -1
- package/dist/neutral/viewers/TimeSync.d.ts +0 -22
- package/dist/neutral/viewers/TimeSync.d.ts.map +0 -1
- package/dist/neutral/viewers/Transaction.d.ts +0 -23
- package/dist/neutral/viewers/Transaction.d.ts.map +0 -1
- package/dist/neutral/viewers/TransactionInvalidation.d.ts +0 -67
- package/dist/neutral/viewers/TransactionInvalidation.d.ts.map +0 -1
- package/dist/neutral/viewers/TransactionValidation.d.ts +0 -68
- package/dist/neutral/viewers/TransactionValidation.d.ts.map +0 -1
- package/dist/neutral/viewers/TransferBalance.d.ts +0 -35
- package/dist/neutral/viewers/TransferBalance.d.ts.map +0 -1
- package/dist/neutral/viewers/WindowedBlock.d.ts +0 -19
- package/dist/neutral/viewers/WindowedBlock.d.ts.map +0 -1
- package/dist/neutral/viewers/XyoViewer.d.ts +0 -57
- package/dist/neutral/viewers/XyoViewer.d.ts.map +0 -1
- package/dist/neutral/viewers/index.d.ts +0 -24
- package/dist/neutral/viewers/index.d.ts.map +0 -1
- package/dist/neutral/xl1/AttoXL1.d.ts +0 -15
- package/dist/neutral/xl1/AttoXL1.d.ts.map +0 -1
- package/dist/neutral/xl1/FemtoXL1.d.ts +0 -15
- package/dist/neutral/xl1/FemtoXL1.d.ts.map +0 -1
- package/dist/neutral/xl1/MicroXL1.d.ts +0 -15
- package/dist/neutral/xl1/MicroXL1.d.ts.map +0 -1
- package/dist/neutral/xl1/MilliXL1.d.ts +0 -15
- package/dist/neutral/xl1/MilliXL1.d.ts.map +0 -1
- package/dist/neutral/xl1/NanoXL1.d.ts +0 -15
- package/dist/neutral/xl1/NanoXL1.d.ts.map +0 -1
- package/dist/neutral/xl1/PicoXL1.d.ts +0 -15
- package/dist/neutral/xl1/PicoXL1.d.ts.map +0 -1
- package/dist/neutral/xl1/XL1.d.ts +0 -15
- package/dist/neutral/xl1/XL1.d.ts.map +0 -1
- package/dist/neutral/xl1/XL1Units.d.ts +0 -10
- package/dist/neutral/xl1/XL1Units.d.ts.map +0 -1
- package/dist/neutral/xl1/index.d.ts +0 -9
- package/dist/neutral/xl1/index.d.ts.map +0 -1
- package/dist/neutral/xl1/isXL1Factory.d.ts +0 -12
- package/dist/neutral/xl1/isXL1Factory.d.ts.map +0 -1
- package/dist/neutral/xl1/xl1MaxValue.d.ts +0 -3
- package/dist/neutral/xl1/xl1MaxValue.d.ts.map +0 -1
- package/src/BlockNumber/BlockNumber.ts +0 -24
- package/src/BlockNumber/EthBlockNumber.ts +0 -25
- package/src/BlockNumber/Numberish.ts +0 -9
- package/src/BlockNumber/XL1BlockNumber.ts +0 -25
- package/src/BlockNumber/index.ts +0 -4
- package/src/Initializable.ts +0 -13
- package/src/OpenTelemetryProviders.ts +0 -7
- package/src/RecordKeyType.ts +0 -5
- package/src/Step/StepHash.ts +0 -10
- package/src/Step/StepIdentity.ts +0 -46
- package/src/Step/StepSizes.ts +0 -47
- package/src/Step/index.ts +0 -3
- package/src/TransferPayload.ts +0 -35
- package/src/amount/ShiftedBigIntConfig.ts +0 -8
- package/src/amount/XL1AmountInstance.ts +0 -19
- package/src/amount/index.ts +0 -2
- package/src/block/AllowedBlockPayload.ts +0 -73
- package/src/block/BlockBoundWitness.ts +0 -72
- package/src/block/HydratedBlock.ts +0 -135
- package/src/block/index.ts +0 -5
- package/src/block/signed/SignedBlockBoundWitness.ts +0 -22
- package/src/block/signed/SignedBlockBoundWitnessWithHashMeta.ts +0 -35
- package/src/block/signed/SignedBlockBoundWitnessWithStorageMeta.ts +0 -41
- package/src/block/signed/index.ts +0 -3
- package/src/block/unsigned/UnsignedBlockBoundWitness.ts +0 -22
- package/src/block/unsigned/index.ts +0 -1
- package/src/chain/Chain.ts +0 -7
- package/src/chain/ChainAnalyzer.ts +0 -11
- package/src/chain/ChainId.ts +0 -4
- package/src/chain/index.ts +0 -3
- package/src/fields/Addressable.ts +0 -7
- package/src/fields/BlockDuration.ts +0 -25
- package/src/fields/BlockNumber.ts +0 -40
- package/src/fields/ChainReference.ts +0 -11
- package/src/fields/index.ts +0 -4
- package/src/map/AsyncMap.ts +0 -38
- package/src/map/MapType.ts +0 -27
- package/src/map/SyncMap.ts +0 -38
- package/src/map/index.ts +0 -3
- package/src/model/AccountBalance.ts +0 -58
- package/src/model/ArrayBuffer.ts +0 -44
- package/src/model/BlockRange/BlockRange.ts +0 -43
- package/src/model/BlockRange/EthBlockRange.ts +0 -43
- package/src/model/BlockRange/Numberish.ts +0 -6
- package/src/model/BlockRange/Range.ts +0 -17
- package/src/model/BlockRange/XL1BlockRange.ts +0 -43
- package/src/model/BlockRange/index.ts +0 -4
- package/src/model/BlockRate.ts +0 -108
- package/src/model/ChainQualification.ts +0 -48
- package/src/model/Context/BaseContext.ts +0 -6
- package/src/model/Context/BaseContext.zod.ts +0 -36
- package/src/model/Context/BlockContext.ts +0 -12
- package/src/model/Context/BlockContext.zod.ts +0 -20
- package/src/model/Context/CachingContext.ts +0 -6
- package/src/model/Context/CachingContext.zod.ts +0 -4
- package/src/model/Context/ChainContext.ts +0 -12
- package/src/model/Context/ChainContext.zod.ts +0 -17
- package/src/model/Context/HeadContext.ts +0 -6
- package/src/model/Context/HeadContext.zod.ts +0 -13
- package/src/model/Context/index.ts +0 -10
- package/src/model/GatewayName.ts +0 -4
- package/src/model/HydratedTransaction.ts +0 -169
- package/src/model/OpCodes.ts +0 -2
- package/src/model/PayloadMap.ts +0 -13
- package/src/model/Permission.ts +0 -29
- package/src/model/Position.ts +0 -21
- package/src/model/PositionId.ts +0 -4
- package/src/model/RangeMultipliers.ts +0 -13
- package/src/model/RewardShare.ts +0 -2
- package/src/model/RewardsRangeOptions.ts +0 -13
- package/src/model/Sequence.ts +0 -21
- package/src/model/Stake.ts +0 -47
- package/src/model/StakeShare.ts +0 -2
- package/src/model/TimeDomain.ts +0 -8
- package/src/model/TransferPair.ts +0 -7
- package/src/model/addresses.ts +0 -36
- package/src/model/defaultRewardRatio.ts +0 -3
- package/src/model/defaultTransactionFees.ts +0 -11
- package/src/model/index.ts +0 -27
- package/src/model/minTransactionFees.ts +0 -10
- package/src/model/rewards.ts +0 -18
- package/src/model/spec/fixtures/index.ts +0 -2
- package/src/model/spec/fixtures/signedHydratedTransaction.ts +0 -58
- package/src/model/spec/fixtures/unsignedHydratedTransaction.ts +0 -62
- package/src/model/version.ts +0 -10
- package/src/network/NetworkId.ts +0 -6
- package/src/network/Status.ts +0 -30
- package/src/network/index.ts +0 -2
- package/src/payload/StepIdentityPayload.ts +0 -25
- package/src/payload/elevatable/Bridge/BridgeCompletion.ts +0 -28
- package/src/payload/elevatable/Bridge/BridgeDestinationObservation.ts +0 -38
- package/src/payload/elevatable/Bridge/BridgeDetails.ts +0 -69
- package/src/payload/elevatable/Bridge/BridgeIntent.ts +0 -36
- package/src/payload/elevatable/Bridge/BridgeSourceObservation.ts +0 -37
- package/src/payload/elevatable/Bridge/index.ts +0 -5
- package/src/payload/elevatable/ChainStakeIntent.ts +0 -45
- package/src/payload/elevatable/Executable.ts +0 -35
- package/src/payload/elevatable/Hash.ts +0 -25
- package/src/payload/elevatable/StepComplete.ts +0 -31
- package/src/payload/elevatable/Time.ts +0 -61
- package/src/payload/elevatable/index.ts +0 -6
- package/src/payload/index.ts +0 -2
- package/src/permissions/InvokerPermission.ts +0 -58
- package/src/permissions/XyoPermissions.ts +0 -41
- package/src/permissions/index.ts +0 -2
- package/src/provider/Provider.ts +0 -6
- package/src/provider/ProviderMoniker.ts +0 -15
- package/src/provider/index.ts +0 -2
- package/src/providers/DataLake/Provider.ts +0 -12
- package/src/providers/DataLake/Runner.ts +0 -16
- package/src/providers/DataLake/Viewer.ts +0 -16
- package/src/providers/DataLake/index.ts +0 -3
- package/src/providers/TransactionHelper.ts +0 -16
- package/src/providers/XyoClient.ts +0 -26
- package/src/providers/XyoConnection.ts +0 -19
- package/src/providers/XyoGateway.ts +0 -23
- package/src/providers/XyoGatewayRunner.ts +0 -76
- package/src/providers/XyoNetwork.ts +0 -8
- package/src/providers/XyoRunner.ts +0 -20
- package/src/providers/index.ts +0 -8
- package/src/providers/signer/XyoSigner.ts +0 -39
- package/src/providers/signer/index.ts +0 -1
- package/src/repository/Repository.ts +0 -32
- package/src/repository/TransactionReadRepository.ts +0 -6
- package/src/repository/TransactionRepository.ts +0 -12
- package/src/repository/TransactionRepositoryIterator.ts +0 -6
- package/src/repository/TransactionWriteRepository.ts +0 -5
- package/src/repository/index.ts +0 -5
- package/src/runners/Block.ts +0 -22
- package/src/runners/Finalization.ts +0 -19
- package/src/runners/Mempool.ts +0 -32
- package/src/runners/index.ts +0 -3
- package/src/transaction/TransactionBoundWitness.ts +0 -187
- package/src/transaction/TransactionFees.ts +0 -73
- package/src/transaction/TransactionGasCosts.ts +0 -42
- package/src/transaction/index.ts +0 -3
- package/src/validation/block/BlockValidationFunction.ts +0 -13
- package/src/validation/block/HydratedBlockStateValidationFunction.ts +0 -31
- package/src/validation/block/HydratedBlockValidationFunction.ts +0 -22
- package/src/validation/block/error.ts +0 -50
- package/src/validation/block/index.ts +0 -4
- package/src/validation/boundwitness/BoundWitnessValidationFunction.ts +0 -9
- package/src/validation/boundwitness/HydratedBoundWitnessValidationFunction.ts +0 -15
- package/src/validation/boundwitness/error.ts +0 -29
- package/src/validation/boundwitness/index.ts +0 -3
- package/src/validation/error.ts +0 -25
- package/src/validation/index.ts +0 -5
- package/src/validation/payload/InBlockPayloadValidationFunction.ts +0 -17
- package/src/validation/payload/error.ts +0 -24
- package/src/validation/payload/index.ts +0 -2
- package/src/validation/transaction/HydratedTransactionStateValidationFunction.ts +0 -27
- package/src/validation/transaction/HydratedTransactionValidationFunction.ts +0 -23
- package/src/validation/transaction/error.ts +0 -15
- package/src/validation/transaction/index.ts +0 -3
- package/src/viewers/Block.ts +0 -44
- package/src/viewers/BlockInvalidation.ts +0 -80
- package/src/viewers/BlockReward.ts +0 -19
- package/src/viewers/BlockValidation.ts +0 -80
- package/src/viewers/ChainContract.ts +0 -29
- package/src/viewers/ChainStakeViewer.ts +0 -14
- package/src/viewers/Finalization.ts +0 -24
- package/src/viewers/Fork.ts +0 -11
- package/src/viewers/Mempool.ts +0 -41
- package/src/viewers/NetworkStake/NetworkStakeViewer.ts +0 -20
- package/src/viewers/NetworkStake/Rewards/ByPositionViewer.ts +0 -18
- package/src/viewers/NetworkStake/Rewards/ByStakerViewer.ts +0 -20
- package/src/viewers/NetworkStake/Rewards/ByStepViewer.ts +0 -18
- package/src/viewers/NetworkStake/Rewards/Options.ts +0 -24
- package/src/viewers/NetworkStake/Rewards/TotalViewer.ts +0 -17
- package/src/viewers/NetworkStake/Rewards/Viewer.ts +0 -21
- package/src/viewers/NetworkStake/Rewards/index.ts +0 -7
- package/src/viewers/NetworkStake/Rewards/templates/ByIndexMethodsTemplate.ts +0 -7
- package/src/viewers/NetworkStake/Rewards/templates/MethodsTemplate.ts +0 -10
- package/src/viewers/NetworkStake/Rewards/templates/index.ts +0 -2
- package/src/viewers/NetworkStake/index.ts +0 -4
- package/src/viewers/NetworkStakeStepReward.ts +0 -83
- package/src/viewers/Stake.ts +0 -45
- package/src/viewers/StakeEvents.ts +0 -55
- package/src/viewers/StakeIntent.ts +0 -22
- package/src/viewers/StakeTotals.ts +0 -22
- package/src/viewers/StepStake.ts +0 -28
- package/src/viewers/StepViewer.ts +0 -57
- package/src/viewers/TimeSync.ts +0 -27
- package/src/viewers/Transaction.ts +0 -27
- package/src/viewers/TransactionInvalidation.ts +0 -70
- package/src/viewers/TransactionValidation.ts +0 -71
- package/src/viewers/TransferBalance.ts +0 -39
- package/src/viewers/WindowedBlock.ts +0 -22
- package/src/viewers/XyoViewer.ts +0 -74
- package/src/viewers/index.ts +0 -23
- package/src/xl1/AttoXL1.ts +0 -19
- package/src/xl1/FemtoXL1.ts +0 -20
- package/src/xl1/MicroXL1.ts +0 -20
- package/src/xl1/MilliXL1.ts +0 -20
- package/src/xl1/NanoXL1.ts +0 -20
- package/src/xl1/PicoXL1.ts +0 -20
- package/src/xl1/XL1.ts +0 -20
- package/src/xl1/XL1Units.ts +0 -26
- package/src/xl1/index.ts +0 -8
- package/src/xl1/isXL1Factory.ts +0 -56
- package/src/xl1/xl1MaxValue.ts +0 -2
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
/** Maximum value for the FemtoXL1 branded type. */
|
|
2
|
-
export declare const FemtoXL1MaxValue: bigint;
|
|
3
|
-
/** FemtoXL1 type. */
|
|
4
|
-
export type FemtoXL1 = bigint & {
|
|
5
|
-
readonly _tag: 'FemtoXL1';
|
|
6
|
-
};
|
|
7
|
-
/** Type guard that checks if a value is a valid FemtoXL1. */
|
|
8
|
-
export declare const isFemtoXL1: (val: unknown) => val is FemtoXL1;
|
|
9
|
-
/** Converts a value to FemtoXL1, throwing if invalid. */
|
|
10
|
-
export declare const asFemtoXL1: (val: unknown) => FemtoXL1;
|
|
11
|
-
/** Converts a bigint value to FemtoXL1 without validation. */
|
|
12
|
-
export declare const toFemtoXL1: (val: unknown) => FemtoXL1 | undefined;
|
|
13
|
-
/** Shorthand alias for asFemtoXL1. */
|
|
14
|
-
export declare const FemtoXL1: (val: unknown) => FemtoXL1;
|
|
15
|
-
//# sourceMappingURL=FemtoXL1.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"FemtoXL1.d.ts","sourceRoot":"","sources":["../../../src/xl1/FemtoXL1.ts"],"names":[],"mappings":"AAMA,mDAAmD;AACnD,eAAO,MAAM,gBAAgB,QAA+B,CAAA;AAC5D,qBAAqB;AACrB,MAAM,MAAM,QAAQ,GAAG,MAAM,GAAG;IAAE,QAAQ,CAAC,IAAI,EAAE,UAAU,CAAA;CAAE,CAAA;AAC7D,6DAA6D;AAC7D,eAAO,MAAM,UAAU,mCAA0C,CAAA;AACjE,yDAAyD;AACzD,eAAO,MAAM,UAAU,4BAA0C,CAAA;AAEjE,8DAA8D;AAC9D,eAAO,MAAM,UAAU,wCAA0C,CAAA;AAEjE,sCAAsC;AACtC,eAAO,MAAM,QAAQ,4BAAa,CAAA"}
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
/** Maximum value for the MicroXL1 branded type. */
|
|
2
|
-
export declare const MicroXL1MaxValue: bigint;
|
|
3
|
-
/** MicroXL1 type. */
|
|
4
|
-
export type MicroXL1 = bigint & {
|
|
5
|
-
readonly _tag: 'MicroXL1';
|
|
6
|
-
};
|
|
7
|
-
/** Type guard that checks if a value is a valid MicroXL1. */
|
|
8
|
-
export declare const isMicroXL1: (val: unknown) => val is MicroXL1;
|
|
9
|
-
/** Converts a value to MicroXL1, throwing if invalid. */
|
|
10
|
-
export declare const asMicroXL1: (val: unknown) => MicroXL1;
|
|
11
|
-
/** Converts a bigint value to MicroXL1 without validation. */
|
|
12
|
-
export declare const toMicroXL1: (val: unknown) => MicroXL1 | undefined;
|
|
13
|
-
/** Shorthand alias for asMicroXL1. */
|
|
14
|
-
export declare const MicroXL1: (val: unknown) => MicroXL1;
|
|
15
|
-
//# sourceMappingURL=MicroXL1.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"MicroXL1.d.ts","sourceRoot":"","sources":["../../../src/xl1/MicroXL1.ts"],"names":[],"mappings":"AAMA,mDAAmD;AACnD,eAAO,MAAM,gBAAgB,QAA+B,CAAA;AAC5D,qBAAqB;AACrB,MAAM,MAAM,QAAQ,GAAG,MAAM,GAAG;IAAE,QAAQ,CAAC,IAAI,EAAE,UAAU,CAAA;CAAE,CAAA;AAC7D,6DAA6D;AAC7D,eAAO,MAAM,UAAU,mCAA0C,CAAA;AACjE,yDAAyD;AACzD,eAAO,MAAM,UAAU,4BAA0C,CAAA;AAEjE,8DAA8D;AAC9D,eAAO,MAAM,UAAU,wCAA0C,CAAA;AAEjE,sCAAsC;AACtC,eAAO,MAAM,QAAQ,4BAAa,CAAA"}
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
/** Maximum value for the MilliXL1 branded type. */
|
|
2
|
-
export declare const MilliXL1MaxValue: bigint;
|
|
3
|
-
/** MilliXL1 type. */
|
|
4
|
-
export type MilliXL1 = bigint & {
|
|
5
|
-
readonly _tag: 'MilliXL1';
|
|
6
|
-
};
|
|
7
|
-
/** Type guard that checks if a value is a valid MilliXL1. */
|
|
8
|
-
export declare const isMilliXL1: (val: unknown) => val is MilliXL1;
|
|
9
|
-
/** Converts a value to MilliXL1, throwing if invalid. */
|
|
10
|
-
export declare const asMilliXL1: (val: unknown) => MilliXL1;
|
|
11
|
-
/** Converts a bigint value to MilliXL1 without validation. */
|
|
12
|
-
export declare const toMilliXL1: (val: unknown) => MilliXL1 | undefined;
|
|
13
|
-
/** Shorthand alias for asMilliXL1. */
|
|
14
|
-
export declare const MilliXL1: (val: unknown) => MilliXL1;
|
|
15
|
-
//# sourceMappingURL=MilliXL1.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"MilliXL1.d.ts","sourceRoot":"","sources":["../../../src/xl1/MilliXL1.ts"],"names":[],"mappings":"AAMA,mDAAmD;AACnD,eAAO,MAAM,gBAAgB,QAA+B,CAAA;AAC5D,qBAAqB;AACrB,MAAM,MAAM,QAAQ,GAAG,MAAM,GAAG;IAAE,QAAQ,CAAC,IAAI,EAAE,UAAU,CAAA;CAAE,CAAA;AAC7D,6DAA6D;AAC7D,eAAO,MAAM,UAAU,mCAA0C,CAAA;AACjE,yDAAyD;AACzD,eAAO,MAAM,UAAU,4BAA0C,CAAA;AAEjE,8DAA8D;AAC9D,eAAO,MAAM,UAAU,wCAA0C,CAAA;AAEjE,sCAAsC;AACtC,eAAO,MAAM,QAAQ,4BAAa,CAAA"}
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
/** Maximum value for the NanoXL1 branded type. */
|
|
2
|
-
export declare const NanoXL1MaxValue: bigint;
|
|
3
|
-
/** NanoXL1 type. */
|
|
4
|
-
export type NanoXL1 = bigint & {
|
|
5
|
-
readonly _tag: 'NanoXL1';
|
|
6
|
-
};
|
|
7
|
-
/** Type guard that checks if a value is a valid NanoXL1. */
|
|
8
|
-
export declare const isNanoXL1: (val: unknown) => val is NanoXL1;
|
|
9
|
-
/** Converts a value to NanoXL1, throwing if invalid. */
|
|
10
|
-
export declare const asNanoXL1: (val: unknown) => NanoXL1;
|
|
11
|
-
/** Converts a bigint value to NanoXL1 without validation. */
|
|
12
|
-
export declare const toNanoXL1: (val: unknown) => NanoXL1 | undefined;
|
|
13
|
-
/** Shorthand alias for asNanoXL1. */
|
|
14
|
-
export declare const NanoXL1: (val: unknown) => NanoXL1;
|
|
15
|
-
//# sourceMappingURL=NanoXL1.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"NanoXL1.d.ts","sourceRoot":"","sources":["../../../src/xl1/NanoXL1.ts"],"names":[],"mappings":"AAMA,kDAAkD;AAClD,eAAO,MAAM,eAAe,QAA8B,CAAA;AAC1D,oBAAoB;AACpB,MAAM,MAAM,OAAO,GAAG,MAAM,GAAG;IAAE,QAAQ,CAAC,IAAI,EAAE,SAAS,CAAA;CAAE,CAAA;AAC3D,4DAA4D;AAC5D,eAAO,MAAM,SAAS,kCAAwC,CAAA;AAC9D,wDAAwD;AACxD,eAAO,MAAM,SAAS,2BAAwC,CAAA;AAE9D,6DAA6D;AAC7D,eAAO,MAAM,SAAS,uCAAwC,CAAA;AAE9D,qCAAqC;AACrC,eAAO,MAAM,OAAO,2BAAY,CAAA"}
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
/** PicoXL1MaxValue constant. */
|
|
2
|
-
export declare const PicoXL1MaxValue: bigint;
|
|
3
|
-
/** PicoXL1 type. */
|
|
4
|
-
export type PicoXL1 = bigint & {
|
|
5
|
-
readonly _tag: 'PicoXL1';
|
|
6
|
-
};
|
|
7
|
-
/** Type guard that checks if a value is a valid PicoXL1. */
|
|
8
|
-
export declare const isPicoXL1: (val: unknown) => val is PicoXL1;
|
|
9
|
-
/** Converts a value to PicoXL1, throwing if invalid. */
|
|
10
|
-
export declare const asPicoXL1: (val: unknown) => PicoXL1;
|
|
11
|
-
/** toPicoXL1 constant. */
|
|
12
|
-
export declare const toPicoXL1: (val: unknown) => PicoXL1 | undefined;
|
|
13
|
-
/** PicoXL1 constant. */
|
|
14
|
-
export declare const PicoXL1: (val: unknown) => PicoXL1;
|
|
15
|
-
//# sourceMappingURL=PicoXL1.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"PicoXL1.d.ts","sourceRoot":"","sources":["../../../src/xl1/PicoXL1.ts"],"names":[],"mappings":"AAMA,gCAAgC;AAChC,eAAO,MAAM,eAAe,QAA8B,CAAA;AAC1D,oBAAoB;AACpB,MAAM,MAAM,OAAO,GAAG,MAAM,GAAG;IAAE,QAAQ,CAAC,IAAI,EAAE,SAAS,CAAA;CAAE,CAAA;AAC3D,4DAA4D;AAC5D,eAAO,MAAM,SAAS,kCAAwC,CAAA;AAC9D,wDAAwD;AACxD,eAAO,MAAM,SAAS,2BAAwC,CAAA;AAE9D,0BAA0B;AAC1B,eAAO,MAAM,SAAS,uCAAwC,CAAA;AAE9D,wBAAwB;AACxB,eAAO,MAAM,OAAO,2BAAY,CAAA"}
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
/** XL1MaxValue constant. */
|
|
2
|
-
export declare const XL1MaxValue: bigint;
|
|
3
|
-
/** XL1 type. */
|
|
4
|
-
export type XL1 = bigint & {
|
|
5
|
-
readonly _tag: 'XL1';
|
|
6
|
-
};
|
|
7
|
-
/** Type guard that checks if a value is a valid XL1. */
|
|
8
|
-
export declare const isXL1: (val: unknown) => val is XL1;
|
|
9
|
-
/** Converts a value to XL1, throwing if invalid. */
|
|
10
|
-
export declare const asXL1: (val: unknown) => XL1;
|
|
11
|
-
/** toXL1 constant. */
|
|
12
|
-
export declare const toXL1: (val: unknown) => XL1 | undefined;
|
|
13
|
-
/** XL1 constant. */
|
|
14
|
-
export declare const XL1: (val: unknown) => XL1;
|
|
15
|
-
//# sourceMappingURL=XL1.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"XL1.d.ts","sourceRoot":"","sources":["../../../src/xl1/XL1.ts"],"names":[],"mappings":"AAMA,4BAA4B;AAC5B,eAAO,MAAM,WAAW,QAA6B,CAAA;AACrD,gBAAgB;AAChB,MAAM,MAAM,GAAG,GAAG,MAAM,GAAG;IAAE,QAAQ,CAAC,IAAI,EAAE,KAAK,CAAA;CAAE,CAAA;AACnD,wDAAwD;AACxD,eAAO,MAAM,KAAK,8BAAmC,CAAA;AACrD,oDAAoD;AACpD,eAAO,MAAM,KAAK,uBAAmC,CAAA;AAErD,sBAAsB;AACtB,eAAO,MAAM,KAAK,mCAAmC,CAAA;AAErD,oBAAoB;AACpB,eAAO,MAAM,GAAG,uBAAQ,CAAA"}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
type XL1Units = 'xl1' | 'milli' | 'micro' | 'nano' | 'pico' | 'femto' | 'atto';
|
|
2
|
-
/** Decimal place definitions for each XL1 currency unit (atto=18, femto=15, etc.). */
|
|
3
|
-
export declare const XL1Places: Record<XL1Units, bigint>;
|
|
4
|
-
/**
|
|
5
|
-
* Convert factor by which a respective unit is multiplied to convert it to AttoXL1 or
|
|
6
|
-
* by which AttoXL1 is divided to convert it to respective unit is multiplied.
|
|
7
|
-
*/
|
|
8
|
-
export declare const AttoXL1ConvertFactor: Record<XL1Units, bigint>;
|
|
9
|
-
export {};
|
|
10
|
-
//# sourceMappingURL=XL1Units.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"XL1Units.d.ts","sourceRoot":"","sources":["../../../src/xl1/XL1Units.ts"],"names":[],"mappings":"AAAA,KAAK,QAAQ,GAAG,KAAK,GAAG,OAAO,GAAG,OAAO,GAAG,MAAM,GAAG,MAAM,GAAG,OAAO,GAAG,MAAM,CAAA;AAE9E,sFAAsF;AACtF,eAAO,MAAM,SAAS,EAAE,MAAM,CAAC,QAAQ,EAAE,MAAM,CAQrC,CAAA;AAEV;;;GAGG;AACH,eAAO,MAAM,oBAAoB,EAAE,MAAM,CAAC,QAAQ,EAAE,MAAM,CAQhD,CAAA"}
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
export * from './AttoXL1.ts';
|
|
2
|
-
export * from './FemtoXL1.ts';
|
|
3
|
-
export * from './MicroXL1.ts';
|
|
4
|
-
export * from './MilliXL1.ts';
|
|
5
|
-
export * from './NanoXL1.ts';
|
|
6
|
-
export * from './PicoXL1.ts';
|
|
7
|
-
export * from './XL1.ts';
|
|
8
|
-
export * from './XL1Units.ts';
|
|
9
|
-
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/xl1/index.ts"],"names":[],"mappings":"AAAA,cAAc,cAAc,CAAA;AAC5B,cAAc,eAAe,CAAA;AAC7B,cAAc,eAAe,CAAA;AAC7B,cAAc,eAAe,CAAA;AAC7B,cAAc,cAAc,CAAA;AAC5B,cAAc,cAAc,CAAA;AAC5B,cAAc,UAAU,CAAA;AACxB,cAAc,eAAe,CAAA"}
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { z } from 'zod';
|
|
2
|
-
/** Type guard that checks if a value is a valid XL1Factory. */
|
|
3
|
-
export declare const isXL1Factory: <T extends bigint>(places: bigint) => (val: unknown) => val is T;
|
|
4
|
-
/** Creates a Zod schema factory for XL1 branded bigint types. */
|
|
5
|
-
export declare const XL1ZodFactory: <T extends bigint>(places: bigint, name: string) => z.ZodBigInt & z.ZodType<T, bigint, z.core.$ZodTypeInternals<T, bigint>>;
|
|
6
|
-
/** Creates a Zod transform factory that converts values between XL1 unit types. */
|
|
7
|
-
export declare const XL1TransformZodFactory: <T extends bigint>(places: bigint, name: string) => z.ZodPipe<z.ZodUnion<readonly [z.ZodBigInt, z.ZodNumber, z.ZodString, z.ZodBoolean]>, z.ZodTransform<Awaited<T>, string | number | bigint | boolean>>;
|
|
8
|
-
/** Converts a value to XL1Factory, throwing if invalid. */
|
|
9
|
-
export declare const asXL1Factory: <T extends bigint>(places: bigint) => (val: unknown) => T;
|
|
10
|
-
/** Creates a factory function that converts bigint values to a specific XL1 branded type. */
|
|
11
|
-
export declare const toXL1Factory: <T extends bigint>(places: bigint) => (val: unknown) => T | undefined;
|
|
12
|
-
//# sourceMappingURL=isXL1Factory.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"isXL1Factory.d.ts","sourceRoot":"","sources":["../../../src/xl1/isXL1Factory.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAIvB,+DAA+D;AAC/D,eAAO,MAAM,YAAY,GAAI,CAAC,SAAS,MAAM,EAAE,QAAQ,MAAM,MAAM,KAAK,OAAO,KAAG,GAAG,IAAI,CAGxF,CAAA;AAED,iEAAiE;AACjE,eAAO,MAAM,aAAa,GAAI,CAAC,SAAS,MAAM,EAAE,QAAQ,MAAM,EAAE,MAAM,MAAM,4EAU3E,CAAA;AAED,mFAAmF;AACnF,eAAO,MAAM,sBAAsB,GAAI,CAAC,SAAS,MAAM,EAAE,QAAQ,MAAM,EAAE,MAAM,MAAM,0JAUpF,CAAA;AAED,2DAA2D;AAC3D,eAAO,MAAM,YAAY,GAAI,CAAC,SAAS,MAAM,EAAE,QAAQ,MAAM,MAEnD,KAAK,OAAO,KAAG,CAOxB,CAAA;AAED,6FAA6F;AAC7F,eAAO,MAAM,YAAY,GAAI,CAAC,SAAS,MAAM,EAAE,QAAQ,MAAM,MAEnD,KAAK,OAAO,KAAG,CAAC,GAAG,SAI5B,CAAA"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"xl1MaxValue.d.ts","sourceRoot":"","sources":["../../../src/xl1/xl1MaxValue.ts"],"names":[],"mappings":"AAAA,2EAA2E;AAC3E,eAAO,MAAM,WAAW,GAAI,QAAQ,MAAM,WAA+B,CAAA"}
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { type Brand } from '@xylabs/sdk-js'
|
|
2
|
-
import { zodAsFactory, zodToFactory } from '@xylabs/sdk-js'
|
|
3
|
-
import { z } from 'zod'
|
|
4
|
-
|
|
5
|
-
import { NumberishZod } from './Numberish.ts'
|
|
6
|
-
|
|
7
|
-
/** Branded number type representing a generic block number */
|
|
8
|
-
export type BlockNumber = Brand<number, { readonly __blockNumber: true }>
|
|
9
|
-
|
|
10
|
-
/** Zod schema that validates and brands a number as a BlockNumber */
|
|
11
|
-
export const BlockNumberZod = z.number().transform(v => v as BlockNumber)
|
|
12
|
-
/** Zod schema that coerces a Numberish value into a BlockNumber */
|
|
13
|
-
export const BlockNumberishZod = NumberishZod.transform(v => v as BlockNumber)
|
|
14
|
-
|
|
15
|
-
/** Input type for BlockNumberishZod, accepting number, string, or bigint */
|
|
16
|
-
export type BlockNumberish = z.input<typeof BlockNumberishZod>
|
|
17
|
-
|
|
18
|
-
/** Casts a number to BlockNumber, returning undefined if validation fails */
|
|
19
|
-
export const asBlockNumber = zodAsFactory<BlockNumber>(BlockNumberZod, 'asBlockNumber')
|
|
20
|
-
/** Coerces a Numberish value to BlockNumber, returning undefined if conversion fails */
|
|
21
|
-
export const toBlockNumber = zodToFactory<BlockNumber>(BlockNumberishZod, 'toBlockNumber')
|
|
22
|
-
|
|
23
|
-
/** The zero block number constant */
|
|
24
|
-
export const BLOCK_NUMBER_ZERO = asBlockNumber(0)
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
import { type Brand } from '@xylabs/sdk-js'
|
|
2
|
-
import { zodAsFactory, zodToFactory } from '@xylabs/sdk-js'
|
|
3
|
-
import { z } from 'zod'
|
|
4
|
-
|
|
5
|
-
import type { BlockNumber } from './BlockNumber.ts'
|
|
6
|
-
import { BlockNumberishZod } from './BlockNumber.ts'
|
|
7
|
-
|
|
8
|
-
/** Branded type representing a block number on the Ethereum chain */
|
|
9
|
-
export type EthBlockNumber = Brand<BlockNumber, { readonly __ethBlockNumber: true }>
|
|
10
|
-
|
|
11
|
-
/** Zod schema that validates and brands a number as an EthBlockNumber */
|
|
12
|
-
export const EthBlockNumberZod = z.number().transform(v => v as EthBlockNumber)
|
|
13
|
-
/** Zod schema that coerces a Numberish value into an EthBlockNumber */
|
|
14
|
-
export const EthBlockNumberishZod = BlockNumberishZod.transform(v => v as EthBlockNumber)
|
|
15
|
-
|
|
16
|
-
/** Input type for EthBlockNumberishZod, accepting number, string, or bigint */
|
|
17
|
-
export type EthBlockNumberish = z.input<typeof EthBlockNumberishZod>
|
|
18
|
-
|
|
19
|
-
/** Casts a number to EthBlockNumber, returning undefined if validation fails */
|
|
20
|
-
export const asEthBlockNumber = zodAsFactory<EthBlockNumber>(EthBlockNumberZod, 'asEthBlockNumber')
|
|
21
|
-
/** Coerces a Numberish value to EthBlockNumber, returning undefined if conversion fails */
|
|
22
|
-
export const toEthBlockNumber = zodToFactory<EthBlockNumber>(EthBlockNumberishZod, 'toEthBlockNumber')
|
|
23
|
-
|
|
24
|
-
/** The zero block number constant for the Ethereum chain */
|
|
25
|
-
export const ETH_BLOCK_NUMBER_ZERO = asEthBlockNumber(0)
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { z } from 'zod'
|
|
2
|
-
|
|
3
|
-
/** Zod schema that accepts number, string, or bigint and coerces to number */
|
|
4
|
-
export const NumberishZod = z.union([z.number(), z.string(), z.bigint()])
|
|
5
|
-
.transform(v => (typeof v === 'bigint' ? Number(v) : typeof v === 'string' ? Number(v) : v))
|
|
6
|
-
.pipe(z.number())
|
|
7
|
-
|
|
8
|
-
/** A value that can be coerced to a number: number, string, or bigint */
|
|
9
|
-
export type Numberish = z.input<typeof NumberishZod>
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
import { type Brand } from '@xylabs/sdk-js'
|
|
2
|
-
import { zodAsFactory, zodToFactory } from '@xylabs/sdk-js'
|
|
3
|
-
import { z } from 'zod'
|
|
4
|
-
|
|
5
|
-
import type { BlockNumber } from './BlockNumber.ts'
|
|
6
|
-
import { BlockNumberishZod } from './BlockNumber.ts'
|
|
7
|
-
|
|
8
|
-
/** Branded type representing a block number on the XL1 chain */
|
|
9
|
-
export type XL1BlockNumber = Brand<BlockNumber, { readonly __xl1BlockNumber: true }>
|
|
10
|
-
|
|
11
|
-
/** Zod schema that validates and brands a number as an XL1BlockNumber */
|
|
12
|
-
export const XL1BlockNumberZod = z.number().transform(v => v as XL1BlockNumber)
|
|
13
|
-
/** Zod schema that coerces a Numberish value into an XL1BlockNumber */
|
|
14
|
-
export const XL1BlockNumberishZod = BlockNumberishZod.transform(v => v as XL1BlockNumber)
|
|
15
|
-
|
|
16
|
-
/** Input type for XL1BlockNumberishZod, accepting number, string, or bigint */
|
|
17
|
-
export type XL1BlockNumberish = z.input<typeof XL1BlockNumberishZod>
|
|
18
|
-
|
|
19
|
-
/** Casts a number to XL1BlockNumber, returning undefined if validation fails */
|
|
20
|
-
export const asXL1BlockNumber = zodAsFactory<XL1BlockNumber>(XL1BlockNumberZod, 'asXL1BlockNumber')
|
|
21
|
-
/** Coerces a Numberish value to XL1BlockNumber, returning undefined if conversion fails */
|
|
22
|
-
export const toXL1BlockNumber = zodToFactory<XL1BlockNumber>(XL1BlockNumberishZod, 'toXL1BlockNumber')
|
|
23
|
-
|
|
24
|
-
/** The zero block number constant for the XL1 chain */
|
|
25
|
-
export const XL1_BLOCK_NUMBER_ZERO = asXL1BlockNumber(0)
|
package/src/BlockNumber/index.ts
DELETED
package/src/Initializable.ts
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
EmptyObject, Logger, Promisable,
|
|
3
|
-
} from '@xylabs/sdk-js'
|
|
4
|
-
|
|
5
|
-
/** @deprecated */
|
|
6
|
-
export type InitializableParams<T extends EmptyObject = {}> = T & {
|
|
7
|
-
logger?: Logger
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
/** @deprecated */
|
|
11
|
-
|
|
12
|
-
/** Initializable type. */
|
|
13
|
-
export type Initializable<T extends EmptyObject, R> = (params: InitializableParams<T>) => Promisable<R>
|
package/src/RecordKeyType.ts
DELETED
package/src/Step/StepHash.ts
DELETED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import type { Brand, Hash } from '@xylabs/sdk-js'
|
|
2
|
-
|
|
3
|
-
/** A block hash paired with its step index */
|
|
4
|
-
export interface StepHash {
|
|
5
|
-
block: Hash
|
|
6
|
-
step: number
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
/** Branded string representing a hash and step index separated by a pipe character */
|
|
10
|
-
export type StepHashString = Brand<string, { readonly __stepHashString: true }>
|
package/src/Step/StepIdentity.ts
DELETED
|
@@ -1,46 +0,0 @@
|
|
|
1
|
-
import { type Brand, isUndefined } from '@xylabs/sdk-js'
|
|
2
|
-
import { z } from 'zod'
|
|
3
|
-
|
|
4
|
-
import { toXL1BlockNumber, XL1BlockNumberZod } from '../BlockNumber/index.ts'
|
|
5
|
-
|
|
6
|
-
/** Zod schema for a step identity combining a block number and step index */
|
|
7
|
-
export const StepIdentityZod = z.object({
|
|
8
|
-
block: XL1BlockNumberZod.describe('The block number at which the step occurs'),
|
|
9
|
-
step: z.number().int().nonnegative().describe('The index of the step into the StepSize array'),
|
|
10
|
-
})
|
|
11
|
-
/** Identifies a specific step by its block number and step index */
|
|
12
|
-
export type StepIdentity = z.infer<typeof StepIdentityZod>
|
|
13
|
-
|
|
14
|
-
/** @deprecated use StepIdentity instead */
|
|
15
|
-
export interface StepContext extends StepIdentity {}
|
|
16
|
-
|
|
17
|
-
/** Branded string representing a block number and step index separated by a pipe character */
|
|
18
|
-
export type StepIdentityString = Brand<string, { readonly __stepIdentityString: true }>
|
|
19
|
-
|
|
20
|
-
function tryParseInt(value: string): number | undefined {
|
|
21
|
-
// Prevent coercion of empty strings to 0
|
|
22
|
-
if (value === '') return undefined
|
|
23
|
-
// Parse number
|
|
24
|
-
const num = Number(value)
|
|
25
|
-
// Check if integer
|
|
26
|
-
return Number.isInteger(num) ? num : undefined
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
/** Parses a pipe-separated string into a StepIdentity, returning undefined if invalid */
|
|
30
|
-
export const asStepIdentity = (stepIdentityString: string): StepIdentity | undefined => {
|
|
31
|
-
try {
|
|
32
|
-
const [blockNumberString, stepString] = stepIdentityString.split('|')
|
|
33
|
-
if (isUndefined(blockNumberString) || isUndefined(stepString)) {
|
|
34
|
-
return undefined
|
|
35
|
-
}
|
|
36
|
-
const step = tryParseInt(stepString)
|
|
37
|
-
const block = toXL1BlockNumber(blockNumberString)
|
|
38
|
-
if (isUndefined(block) || isUndefined(step)) {
|
|
39
|
-
return undefined
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
return { block, step }
|
|
43
|
-
} catch {
|
|
44
|
-
return undefined
|
|
45
|
-
}
|
|
46
|
-
}
|
package/src/Step/StepSizes.ts
DELETED
|
@@ -1,47 +0,0 @@
|
|
|
1
|
-
import { AsTypeFactory } from '@xylabs/sdk-js'
|
|
2
|
-
|
|
3
|
-
import { asXL1BlockNumber, type XL1BlockNumber } from '../BlockNumber/index.ts'
|
|
4
|
-
|
|
5
|
-
// StepsV2 are primorial(n+2) + 1, where n is the index of the step size
|
|
6
|
-
// primorial(n+2) = 2 → 2×3=6 → 6×5=30 → 30×7=210 → 210×11=2310
|
|
7
|
-
|
|
8
|
-
/** Array of step sizes based on primorial(n+2) + 1, defining the block intervals for each step level */
|
|
9
|
-
export const StepSizes: XL1BlockNumber[] = [
|
|
10
|
-
asXL1BlockNumber(7, true),
|
|
11
|
-
asXL1BlockNumber(31, true),
|
|
12
|
-
asXL1BlockNumber(211, true),
|
|
13
|
-
asXL1BlockNumber(2311, true),
|
|
14
|
-
asXL1BlockNumber(30_031, true),
|
|
15
|
-
asXL1BlockNumber(510_511, true),
|
|
16
|
-
asXL1BlockNumber(9_699_691, true),
|
|
17
|
-
asXL1BlockNumber(223_092_871, true),
|
|
18
|
-
asXL1BlockNumber(6_469_693_231, true),
|
|
19
|
-
]
|
|
20
|
-
|
|
21
|
-
/** Type guard that checks if a value is a valid step index within the StepSizes array */
|
|
22
|
-
export function isValidStep(step: unknown): step is number {
|
|
23
|
-
if (typeof step === 'number' && Number.isInteger(step)) {
|
|
24
|
-
return ((step >= 0) && (step < StepSizes.length))
|
|
25
|
-
}
|
|
26
|
-
return false
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
/** Casts a value to a valid step index, returning undefined if invalid */
|
|
30
|
-
export const asValidStep = AsTypeFactory.create<number>(isValidStep)
|
|
31
|
-
|
|
32
|
-
/** Returns the block interval size for a given step index */
|
|
33
|
-
export function stepSize(step: number): number {
|
|
34
|
-
const validatedStep = asValidStep(step, () => `Invalid step (${step}), must be an integer between 0 and ${StepSizes.length - 1}`, { required: true })
|
|
35
|
-
return StepSizes[validatedStep]
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
/** Fraction of block rewards allocated at each step level, expressed as [numerator, denominator] pairs */
|
|
39
|
-
export const StepRewardFractions = [
|
|
40
|
-
[0n, 1n], // 0%
|
|
41
|
-
[0n, 1n], // 0%
|
|
42
|
-
[0n, 1n], // 0%
|
|
43
|
-
[1n, 10_000n], // 0.01%
|
|
44
|
-
[2n, 1000n], // 0.2%
|
|
45
|
-
[3n, 100n], // 3%
|
|
46
|
-
[45n, 100n], // 45%
|
|
47
|
-
] as const
|
package/src/Step/index.ts
DELETED
package/src/TransferPayload.ts
DELETED
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
AddressZod,
|
|
3
|
-
AsObjectFactory, HexZod, JsonObjectZod,
|
|
4
|
-
} from '@xylabs/sdk-js'
|
|
5
|
-
import {
|
|
6
|
-
asSchema, isPayloadOfSchemaType, PayloadZodOfSchema,
|
|
7
|
-
} from '@xyo-network/sdk-js'
|
|
8
|
-
import { z } from 'zod'
|
|
9
|
-
|
|
10
|
-
/** Schema identifier for XYO transfer payloads */
|
|
11
|
-
export const TransferSchema = asSchema('network.xyo.transfer', true)
|
|
12
|
-
/** The literal type of the transfer schema string */
|
|
13
|
-
export type TransferSchema = typeof TransferSchema
|
|
14
|
-
|
|
15
|
-
/** Zod schema for the fields specific to a transfer payload */
|
|
16
|
-
export const TransferFieldsZod = z.object({
|
|
17
|
-
// Removed as only transaction have opCodes
|
|
18
|
-
// $opCodes: z.array(z.string()).optional(),
|
|
19
|
-
context: JsonObjectZod.optional(),
|
|
20
|
-
epoch: z.number(),
|
|
21
|
-
from: AddressZod,
|
|
22
|
-
transfers: z.record(AddressZod, HexZod),
|
|
23
|
-
})
|
|
24
|
-
|
|
25
|
-
/** Zod schema for a complete transfer payload including schema and fields */
|
|
26
|
-
export const TransferZod = PayloadZodOfSchema(TransferSchema).extend(TransferFieldsZod.shape)
|
|
27
|
-
|
|
28
|
-
/** A transfer payload representing the movement of XL1 tokens between addresses */
|
|
29
|
-
export type Transfer = z.infer<typeof TransferZod>
|
|
30
|
-
|
|
31
|
-
/** Type guard that checks if a value is a Transfer payload */
|
|
32
|
-
export const isTransfer = isPayloadOfSchemaType<Transfer>(TransferSchema)
|
|
33
|
-
|
|
34
|
-
/** Casts a value to Transfer or returns undefined if invalid */
|
|
35
|
-
export const asTransfer = AsObjectFactory.create(isTransfer)
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
AttoXL1, FemtoXL1, MicroXL1, MilliXL1, NanoXL1, PicoXL1, XL1,
|
|
3
|
-
} from '../xl1/index.ts'
|
|
4
|
-
import type { ShiftedBigIntConfig } from './ShiftedBigIntConfig.ts'
|
|
5
|
-
|
|
6
|
-
/** Interface for an XL1 token amount with conversion accessors for various denominations */
|
|
7
|
-
export interface XL1AmountInstance {
|
|
8
|
-
atto: AttoXL1
|
|
9
|
-
femto: FemtoXL1
|
|
10
|
-
micro: MicroXL1
|
|
11
|
-
milli: MilliXL1
|
|
12
|
-
nano: NanoXL1
|
|
13
|
-
pico: PicoXL1
|
|
14
|
-
value: AttoXL1
|
|
15
|
-
xl1: XL1
|
|
16
|
-
|
|
17
|
-
to(places: bigint | number): bigint
|
|
18
|
-
toString(places: number, config: Partial<ShiftedBigIntConfig>): string
|
|
19
|
-
}
|
package/src/amount/index.ts
DELETED
|
@@ -1,73 +0,0 @@
|
|
|
1
|
-
import { zodIsFactory } from '@xylabs/sdk-js'
|
|
2
|
-
import type {
|
|
3
|
-
Schema, SchemaPayload, WithStorageMeta,
|
|
4
|
-
} from '@xyo-network/sdk-js'
|
|
5
|
-
import {
|
|
6
|
-
BoundWitnessSchema, isHashMeta, isSchemaPayload, SchemaSchema,
|
|
7
|
-
} from '@xyo-network/sdk-js'
|
|
8
|
-
import { z } from 'zod'
|
|
9
|
-
|
|
10
|
-
import type {
|
|
11
|
-
BridgeDestinationObservation, BridgeIntent, BridgeSourceObservation, ChainStakeIntent, HashPayload, StepComplete, TimePayload,
|
|
12
|
-
} from '../payload/index.ts'
|
|
13
|
-
import {
|
|
14
|
-
BridgeDestinationObservationSchema, BridgeIntentSchema, BridgeSourceObservationSchema, ChainStakeIntentSchema, HashSchema,
|
|
15
|
-
isBridgeDestinationObservation, isBridgeIntent, isBridgeSourceObservation, isChainStakeIntent, isHashPayload, isTimePayload, StepCompleteSchema,
|
|
16
|
-
TimeSchema,
|
|
17
|
-
} from '../payload/index.ts'
|
|
18
|
-
import { isTransactionBoundWitness, type TransactionBoundWitness } from '../transaction/index.ts'
|
|
19
|
-
import {
|
|
20
|
-
isTransfer, type Transfer, TransferSchema,
|
|
21
|
-
} from '../TransferPayload.ts'
|
|
22
|
-
|
|
23
|
-
/** AllowedBlockPayload type. */
|
|
24
|
-
export type AllowedBlockPayload
|
|
25
|
-
= | BridgeDestinationObservation
|
|
26
|
-
| BridgeIntent
|
|
27
|
-
| BridgeSourceObservation
|
|
28
|
-
| ChainStakeIntent
|
|
29
|
-
| HashPayload
|
|
30
|
-
| SchemaPayload
|
|
31
|
-
| StepComplete
|
|
32
|
-
| TimePayload
|
|
33
|
-
| TransactionBoundWitness
|
|
34
|
-
| Transfer
|
|
35
|
-
|
|
36
|
-
/** AllowedBlockPayloadSchemas constant. */
|
|
37
|
-
export const AllowedBlockPayloadSchemas = [
|
|
38
|
-
BoundWitnessSchema,
|
|
39
|
-
BridgeDestinationObservationSchema,
|
|
40
|
-
BridgeIntentSchema,
|
|
41
|
-
BridgeSourceObservationSchema,
|
|
42
|
-
ChainStakeIntentSchema,
|
|
43
|
-
HashSchema,
|
|
44
|
-
SchemaSchema,
|
|
45
|
-
StepCompleteSchema,
|
|
46
|
-
TimeSchema,
|
|
47
|
-
TransferSchema,
|
|
48
|
-
] satisfies Schema[]
|
|
49
|
-
|
|
50
|
-
/** AllowedBlockPayloadSchemaZod constant. */
|
|
51
|
-
export const AllowedBlockPayloadSchemaZod = z.enum(AllowedBlockPayloadSchemas)
|
|
52
|
-
/** Schema type for AllowedBlockPayload payloads. */
|
|
53
|
-
export type AllowedBlockPayloadSchema = z.infer<typeof AllowedBlockPayloadSchemaZod>
|
|
54
|
-
/** Schema identifier for isAllowedBlockPayload payloads. */
|
|
55
|
-
export const isAllowedBlockPayloadSchema = zodIsFactory(AllowedBlockPayloadSchemaZod)
|
|
56
|
-
|
|
57
|
-
/** Type guard that checks if a value is a valid AllowedBlockPayload. */
|
|
58
|
-
export const isAllowedBlockPayload = <T>(value: T): value is AllowedBlockPayload & T => {
|
|
59
|
-
return isTransfer(value)
|
|
60
|
-
|| isBridgeDestinationObservation(value)
|
|
61
|
-
|| isBridgeIntent(value)
|
|
62
|
-
|| isBridgeSourceObservation(value)
|
|
63
|
-
|| isChainStakeIntent(value)
|
|
64
|
-
|| isHashPayload(value)
|
|
65
|
-
|| isSchemaPayload(value)
|
|
66
|
-
|| isTimePayload(value)
|
|
67
|
-
|| isTransactionBoundWitness(value)
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
/** Type guard that checks if a value is a valid AllowedBlockPayloadWithHashMeta. */
|
|
71
|
-
export const isAllowedBlockPayloadWithHashMeta = <T>(value: T): value is WithStorageMeta<AllowedBlockPayload & T> => {
|
|
72
|
-
return isAllowedBlockPayload(value) && isHashMeta(value)
|
|
73
|
-
}
|
|
@@ -1,72 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
HashZod,
|
|
3
|
-
zodAsFactory, zodIsFactory, zodToFactory,
|
|
4
|
-
} from '@xylabs/sdk-js'
|
|
5
|
-
import {
|
|
6
|
-
BoundWitnessZod,
|
|
7
|
-
WithHashMetaZod,
|
|
8
|
-
WithStorageMetaZod,
|
|
9
|
-
} from '@xyo-network/sdk-js'
|
|
10
|
-
import { z } from 'zod'
|
|
11
|
-
|
|
12
|
-
import { XL1BlockNumberZod } from '../BlockNumber/index.ts'
|
|
13
|
-
import { ChainZod } from '../chain/index.ts'
|
|
14
|
-
|
|
15
|
-
/** BlockBoundWitnessFieldsZod constant. */
|
|
16
|
-
export const BlockBoundWitnessFieldsZod = z.object({
|
|
17
|
-
block: XL1BlockNumberZod,
|
|
18
|
-
chain: ChainZod,
|
|
19
|
-
previous: HashZod.nullable(),
|
|
20
|
-
protocol: z.number().optional(),
|
|
21
|
-
step_hashes: z.array(HashZod).optional(),
|
|
22
|
-
})
|
|
23
|
-
|
|
24
|
-
/** BlockBoundWitnessMetaZod constant. */
|
|
25
|
-
export const BlockBoundWitnessMetaZod = z.object({ $epoch: z.number() })
|
|
26
|
-
|
|
27
|
-
/** BlockBoundWitnessZod constant. */
|
|
28
|
-
export const BlockBoundWitnessZod = z.object({
|
|
29
|
-
...BoundWitnessZod.shape,
|
|
30
|
-
...BlockBoundWitnessFieldsZod.shape,
|
|
31
|
-
...BlockBoundWitnessMetaZod.shape,
|
|
32
|
-
})
|
|
33
|
-
|
|
34
|
-
/** BlockBoundWitness type. */
|
|
35
|
-
export type BlockBoundWitness = z.infer<typeof BlockBoundWitnessZod>
|
|
36
|
-
|
|
37
|
-
/** Type guard that checks if a value is a valid BlockBoundWitness. */
|
|
38
|
-
export const isBlockBoundWitness = zodIsFactory(BlockBoundWitnessZod)
|
|
39
|
-
/** Converts a value to BlockBoundWitness, throwing if invalid. */
|
|
40
|
-
export const asBlockBoundWitness = zodAsFactory(BlockBoundWitnessZod, 'asBlockBoundWitness')
|
|
41
|
-
/** toBlockBoundWitness constant. */
|
|
42
|
-
export const toBlockBoundWitness = zodToFactory(BlockBoundWitnessZod, 'toBlockBoundWitness')
|
|
43
|
-
|
|
44
|
-
/** @deprecated use WithHashMetaZod(BlockBoundWitnessZod) instead */
|
|
45
|
-
export const BlockBoundWitnessWithHashMetaZod = WithHashMetaZod(BlockBoundWitnessZod)
|
|
46
|
-
|
|
47
|
-
/** @deprecated use WithHashMeta(BlockBoundWitness) instead */
|
|
48
|
-
|
|
49
|
-
/** BlockBoundWitnessWithHashMeta type. */
|
|
50
|
-
export type BlockBoundWitnessWithHashMeta = z.infer<typeof BlockBoundWitnessWithHashMetaZod>
|
|
51
|
-
|
|
52
|
-
/** Type guard that checks if a value is a valid BlockBoundWitnessWithHashMeta. */
|
|
53
|
-
export const isBlockBoundWitnessWithHashMeta = zodIsFactory(WithHashMetaZod(BlockBoundWitnessZod))
|
|
54
|
-
/** Converts a value to BlockBoundWitnessWithHashMeta, throwing if invalid. */
|
|
55
|
-
export const asBlockBoundWitnessWithHashMeta = zodAsFactory(WithHashMetaZod(BlockBoundWitnessZod), 'asBlockBoundWitnessWithHashMeta')
|
|
56
|
-
/** toBlockBoundWitnessWithHashMeta constant. */
|
|
57
|
-
export const toBlockBoundWitnessWithHashMeta = zodToFactory(WithHashMetaZod(BlockBoundWitnessZod), 'toBlockBoundWitnessWithHashMeta')
|
|
58
|
-
|
|
59
|
-
/** @deprecated use WithStorageMetaZod(BlockBoundWitnessZod) instead */
|
|
60
|
-
export const BlockBoundWitnessWithStorageMetaZod = WithStorageMetaZod(BlockBoundWitnessZod)
|
|
61
|
-
|
|
62
|
-
/** @deprecated use WithStorageMeta(BlockBoundWitness) instead */
|
|
63
|
-
|
|
64
|
-
/** BlockBoundWitnessWithStorageMeta type. */
|
|
65
|
-
export type BlockBoundWitnessWithStorageMeta = z.infer<typeof BlockBoundWitnessWithStorageMetaZod>
|
|
66
|
-
|
|
67
|
-
/** Type guard that checks if a value is a valid BlockBoundWitnessWithStorageMeta. */
|
|
68
|
-
export const isBlockBoundWitnessWithStorageMeta = zodIsFactory(WithStorageMetaZod(BlockBoundWitnessZod))
|
|
69
|
-
/** Converts a value to BlockBoundWitnessWithStorageMeta, throwing if invalid. */
|
|
70
|
-
export const asBlockBoundWitnessWithStorageMeta = zodAsFactory(WithStorageMetaZod(BlockBoundWitnessZod), 'asBlockBoundWitnessWithStorageMeta')
|
|
71
|
-
/** toBlockBoundWitnessWithStorageMeta constant. */
|
|
72
|
-
export const toBlockBoundWitnessWithStorageMeta = zodToFactory(WithStorageMetaZod(BlockBoundWitnessZod), 'toBlockBoundWitnessWithStorageMeta')
|