@tokenops/sdk 1.5.1 → 2.0.0-alpha.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/CHANGELOG.md +198 -2
- package/CONTRIBUTING.md +4 -2
- package/README.md +146 -90
- package/SECURITY.md +7 -1
- package/SUPPORT.md +47 -0
- package/dist/{chunk-YQIBBEFJ.js → chunk-335Z2W67.js} +1 -1
- package/dist/{chunk-2NCLOQ56.cjs → chunk-3QHNYEQD.cjs} +77 -0
- package/dist/chunk-456VDDA3.js +370 -0
- package/dist/{chunk-SG65XWH7.js → chunk-4RAAATVY.js} +1 -3
- package/dist/{chunk-6BMP4ICG.js → chunk-4TSDNZQ3.js} +60 -2
- package/dist/{chunk-PUPKNW3R.cjs → chunk-5576FRT3.cjs} +30 -6
- package/dist/{chunk-AOP6HMPW.js → chunk-6GNR22OV.js} +75 -1
- package/dist/{chunk-NTZY6IB7.js → chunk-6NAVMWZQ.js} +4 -3
- package/dist/{chunk-C7BRZXJA.cjs → chunk-6PXXGACR.cjs} +8 -7
- package/dist/{chunk-IJFQ5L4I.js → chunk-74QFZ5MK.js} +4 -3
- package/dist/chunk-7AFPOE7N.cjs +59 -0
- package/dist/chunk-AXIPOR3C.js +56 -0
- package/dist/chunk-CTED3MTR.cjs +380 -0
- package/dist/{chunk-XGGTQQFH.js → chunk-DZHYSUGY.js} +28 -7
- package/dist/{chunk-OXTLPTO3.js → chunk-EAJ7SYHE.js} +4 -3
- package/dist/{chunk-V2PXZVBF.cjs → chunk-FGEB7RMY.cjs} +4 -4
- package/dist/chunk-GKKDAW44.js +8823 -0
- package/dist/{chunk-2PWNH3UE.js → chunk-H5POPGOZ.js} +63 -5
- package/dist/{chunk-W7IGCOVL.cjs → chunk-JQYC66TO.cjs} +9 -8
- package/dist/{chunk-PFXURMBZ.cjs → chunk-JZLGCTGK.cjs} +68 -8
- package/dist/{chunk-JYOTGRSO.cjs → chunk-KFRDLKMA.cjs} +61 -1
- package/dist/chunk-M4IT6DNJ.cjs +608 -0
- package/dist/{chunk-KLKI352M.cjs → chunk-MVDQMV25.cjs} +0 -3
- package/dist/chunk-NCVX3K2N.cjs +161 -0
- package/dist/chunk-NWFMBLSQ.js +4 -0
- package/dist/chunk-O5676ZWY.js +585 -0
- package/dist/chunk-PUX5VXDB.cjs +8845 -0
- package/dist/{chunk-IXLO7GO5.js → chunk-TWT3STIX.js} +46 -80
- package/dist/chunk-UG5RKLU2.cjs +6 -0
- package/dist/chunk-VP2B4WM2.js +154 -0
- package/dist/{chunk-5X5WL5CU.cjs → chunk-WJLECC22.cjs} +51 -88
- package/dist/{chunk-WENHUPZC.cjs → chunk-XAYGD4E4.cjs} +9 -8
- package/dist/core/addresses.d.ts +15 -3
- package/dist/core/brands.d.ts +8 -2
- package/dist/core/errors.d.ts +71 -10
- package/dist/core/preflight.d.ts +1 -0
- package/dist/fhe/erc7984-abi.d.ts +1 -0
- package/dist/fhe/index.cjs +34 -13
- package/dist/fhe/index.d.cts +1 -0
- package/dist/fhe/index.d.ts +1 -0
- package/dist/fhe/index.js +19 -6
- package/dist/fhe/mock-erc7984.d.ts +4 -4
- package/dist/fhe/operators.d.ts +160 -3
- package/dist/fhe/react/index.cjs +14 -0
- package/dist/fhe/react/index.d.cts +2 -0
- package/dist/fhe/react/index.d.ts +2 -0
- package/dist/fhe/react/index.js +6 -0
- package/dist/fhe/react/useEnsureOperator.d.ts +56 -0
- package/dist/fhe/react/useIsOperator.d.ts +54 -0
- package/dist/fhe/sepolia-encryptor-web.d.ts +18 -3
- package/dist/fhe/types.d.ts +6 -0
- package/dist/fhe-airdrop/abis/{cloneable.d.ts → airdrop-base.d.ts} +254 -396
- package/dist/fhe-airdrop/abis/compliance.d.ts +422 -0
- package/dist/fhe-airdrop/abis/ecdsa.d.ts +1316 -0
- package/dist/fhe-airdrop/abis/factory.d.ts +1319 -190
- package/dist/fhe-airdrop/abis/index.d.ts +5 -2
- package/dist/fhe-airdrop/abis/merkle.d.ts +1238 -0
- package/dist/fhe-airdrop/advanced/index.cjs +10 -12
- package/dist/fhe-airdrop/advanced/index.d.cts +34 -11
- package/dist/fhe-airdrop/advanced/index.d.ts +34 -11
- package/dist/fhe-airdrop/advanced/index.js +2 -8
- package/dist/fhe-airdrop/advanced/react/index.cjs +34 -48
- package/dist/fhe-airdrop/advanced/react/index.d.cts +9 -3
- package/dist/fhe-airdrop/advanced/react/index.d.ts +9 -3
- package/dist/fhe-airdrop/advanced/react/index.js +33 -48
- package/dist/fhe-airdrop/advanced/react/usePredictEcdsaAirdropAddress.d.ts +33 -0
- package/dist/fhe-airdrop/advanced/react/usePredictMerkleAirdropAddress.d.ts +27 -0
- package/dist/fhe-airdrop/airdrop-base.d.ts +600 -0
- package/dist/fhe-airdrop/campaign.d.ts +297 -0
- package/dist/fhe-airdrop/compliance.d.ts +302 -0
- package/dist/fhe-airdrop/constants.d.ts +33 -0
- package/dist/fhe-airdrop/ecdsa.d.ts +263 -0
- package/dist/fhe-airdrop/encryption.d.ts +92 -14
- package/dist/fhe-airdrop/errors.d.ts +245 -15
- package/dist/fhe-airdrop/factory.d.ts +533 -274
- package/dist/fhe-airdrop/guards.d.ts +273 -0
- package/dist/fhe-airdrop/index.cjs +1089 -33
- package/dist/fhe-airdrop/index.d.cts +46 -8
- package/dist/fhe-airdrop/index.d.ts +46 -8
- package/dist/fhe-airdrop/index.js +929 -7
- package/dist/fhe-airdrop/merkle-tree.d.ts +103 -0
- package/dist/fhe-airdrop/merkle.d.ts +180 -0
- package/dist/fhe-airdrop/react/_shared.d.ts +144 -71
- package/dist/fhe-airdrop/react/index.cjs +364 -413
- package/dist/fhe-airdrop/react/index.d.cts +53 -72
- package/dist/fhe-airdrop/react/index.d.ts +53 -72
- package/dist/fhe-airdrop/react/index.js +258 -369
- package/dist/fhe-airdrop/react/useAirdropGasFee.d.ts +10 -5
- package/dist/fhe-airdrop/react/useAirdropHasRole.d.ts +15 -6
- package/dist/fhe-airdrop/react/useAirdropPause.d.ts +30 -0
- package/dist/fhe-airdrop/react/useAirdropPaused.d.ts +17 -0
- package/dist/fhe-airdrop/react/useAirdropToken.d.ts +11 -4
- package/dist/fhe-airdrop/react/useAirdropWindow.d.ts +37 -0
- package/dist/fhe-airdrop/react/useClaimedAmount.d.ts +29 -0
- package/dist/fhe-airdrop/react/useComplianceManager.d.ts +16 -0
- package/dist/fhe-airdrop/react/useCreateEcdsaAirdrop.d.ts +28 -0
- package/dist/fhe-airdrop/react/useCreateMerkleAirdrop.d.ts +25 -0
- package/dist/fhe-airdrop/react/useEcdsaClaim.d.ts +23 -0
- package/dist/fhe-airdrop/react/useEffectiveUpgradeable.d.ts +20 -0
- package/dist/fhe-airdrop/react/useExtendClaimWindow.d.ts +17 -12
- package/dist/fhe-airdrop/react/useFactoryFees.d.ts +28 -0
- package/dist/fhe-airdrop/react/useFactoryRegistry.d.ts +35 -0
- package/dist/fhe-airdrop/react/useFundAirdrop.d.ts +35 -0
- package/dist/fhe-airdrop/react/useGrantInstanceRoles.d.ts +35 -0
- package/dist/fhe-airdrop/react/useMerkleClaim.d.ts +34 -0
- package/dist/fhe-airdrop/react/useMerkleRoot.d.ts +15 -0
- package/dist/fhe-airdrop/react/useSetMerkleRoot.d.ts +22 -0
- package/dist/fhe-airdrop/react/useWithdrawConfidential.d.ts +23 -0
- package/dist/fhe-airdrop/roles.d.ts +147 -0
- package/dist/fhe-airdrop/types.d.ts +68 -55
- package/dist/fhe-disperse/errors.d.ts +55 -0
- package/dist/fhe-disperse/index.cjs +34 -25
- package/dist/fhe-disperse/index.d.cts +1 -1
- package/dist/fhe-disperse/index.d.ts +1 -1
- package/dist/fhe-disperse/index.js +6 -5
- package/dist/fhe-disperse/react/index.cjs +42 -23
- package/dist/fhe-disperse/react/index.d.cts +3 -1
- package/dist/fhe-disperse/react/index.d.ts +3 -1
- package/dist/fhe-disperse/react/index.js +9 -6
- package/dist/fhe-vesting/advanced/index.cjs +8 -7
- package/dist/fhe-vesting/advanced/index.js +6 -5
- package/dist/fhe-vesting/advanced/react/index.cjs +12 -11
- package/dist/fhe-vesting/advanced/react/index.js +9 -8
- package/dist/fhe-vesting/index.cjs +35 -34
- package/dist/fhe-vesting/index.js +7 -6
- package/dist/fhe-vesting/manager.d.ts +19 -0
- package/dist/fhe-vesting/react/index.cjs +160 -140
- package/dist/fhe-vesting/react/index.d.cts +6 -4
- package/dist/fhe-vesting/react/index.d.ts +6 -4
- package/dist/fhe-vesting/react/index.js +24 -16
- package/dist/fhe-vesting/react/useAccessClaimableAmount.d.ts +11 -3
- package/dist/fhe-vesting/react/useAccessSettledAmount.d.ts +11 -3
- package/dist/fhe-vesting/react/useAccessTotalAllocation.d.ts +11 -3
- package/dist/fhe-vesting/react/useAccessVestedAmount.d.ts +11 -3
- package/dist/fhe-vesting/react/useAdminGetClaimableAmount.d.ts +1 -1
- package/dist/fhe-vesting/react/useAdminGetSettledAmount.d.ts +1 -1
- package/dist/fhe-vesting/react/useAdminGetTotalAllocation.d.ts +1 -1
- package/dist/fhe-vesting/react/useAdminGetVestedAmount.d.ts +1 -1
- package/dist/fhe-vesting/react/useAdminPartialClaim.d.ts +8 -0
- package/dist/fhe-vesting/react/useClaim.d.ts +1 -1
- package/dist/fhe-vesting/react/useDiscloseHandleToParty.d.ts +1 -1
- package/dist/fhe-vesting/react/useManagerDiscloseHandleToParty.d.ts +1 -1
- package/dist/fhe-vesting/react/usePartialClaim.d.ts +1 -1
- package/dist/fhe-vesting/react/useVestingInfo.d.ts +1 -1
- package/dist/fhe-vesting/types.d.ts +12 -1
- package/dist/index.cjs +27 -15
- package/dist/index.js +1 -1
- package/dist/testnet-faucet/index.cjs +17 -16
- package/dist/testnet-faucet/index.js +5 -4
- package/dist/testnet-faucet/react/index.cjs +11 -10
- package/dist/testnet-faucet/react/index.js +6 -5
- package/package.json +18 -9
- package/dist/chunk-4WPGQSNT.cjs +0 -44
- package/dist/chunk-6R4KNAPK.js +0 -1630
- package/dist/chunk-DUZIIRPF.js +0 -1655
- package/dist/chunk-MCRBVJGZ.cjs +0 -1637
- package/dist/chunk-ODLTEGHB.js +0 -41
- package/dist/chunk-ORFTDNFZ.js +0 -105
- package/dist/chunk-T46YXSBP.cjs +0 -109
- package/dist/chunk-TIUKIY5V.cjs +0 -1663
- package/dist/fhe-airdrop/advanced/factory-advanced.d.ts +0 -53
- package/dist/fhe-airdrop/advanced/react/usePredictAirdropAddress.d.ts +0 -49
- package/dist/fhe-airdrop/airdrop.d.ts +0 -310
- package/dist/fhe-airdrop/react/useAccessClaimAmount.d.ts +0 -31
- package/dist/fhe-airdrop/react/useAirdropCanExtendClaimWindow.d.ts +0 -7
- package/dist/fhe-airdrop/react/useAirdropClaim.d.ts +0 -27
- package/dist/fhe-airdrop/react/useAirdropClaimTypehash.d.ts +0 -10
- package/dist/fhe-airdrop/react/useAirdropClaimedSignatures.d.ts +0 -16
- package/dist/fhe-airdrop/react/useAirdropDeploymentBlockNumber.d.ts +0 -6
- package/dist/fhe-airdrop/react/useAirdropDomainSeparator.d.ts +0 -8
- package/dist/fhe-airdrop/react/useAirdropEndTime.d.ts +0 -10
- package/dist/fhe-airdrop/react/useAirdropFactoryCustomFee.d.ts +0 -17
- package/dist/fhe-airdrop/react/useAirdropFactoryDefaultGasFee.d.ts +0 -10
- package/dist/fhe-airdrop/react/useAirdropFactoryDisableCustomFee.d.ts +0 -15
- package/dist/fhe-airdrop/react/useAirdropFactoryFeeCollector.d.ts +0 -11
- package/dist/fhe-airdrop/react/useAirdropFactoryInitCodeHash.d.ts +0 -17
- package/dist/fhe-airdrop/react/useAirdropFactorySetCustomFee.d.ts +0 -17
- package/dist/fhe-airdrop/react/useAirdropFactorySetDefaultGasFee.d.ts +0 -16
- package/dist/fhe-airdrop/react/useAirdropFactorySetFeeCollector.d.ts +0 -15
- package/dist/fhe-airdrop/react/useAirdropGrantRole.d.ts +0 -16
- package/dist/fhe-airdrop/react/useAirdropHasClaimEnded.d.ts +0 -7
- package/dist/fhe-airdrop/react/useAirdropHasClaimStarted.d.ts +0 -7
- package/dist/fhe-airdrop/react/useAirdropIsClaimWindowActive.d.ts +0 -9
- package/dist/fhe-airdrop/react/useAirdropIsPaused.d.ts +0 -8
- package/dist/fhe-airdrop/react/useAirdropIsSignatureClaimed.d.ts +0 -22
- package/dist/fhe-airdrop/react/useAirdropIsSignatureValid.d.ts +0 -51
- package/dist/fhe-airdrop/react/useAirdropRevokeRole.d.ts +0 -15
- package/dist/fhe-airdrop/react/useAirdropStartTime.d.ts +0 -10
- package/dist/fhe-airdrop/react/useAirdropWithdrawGasFee.d.ts +0 -15
- package/dist/fhe-airdrop/react/useAirdropWithdrawOtherConfidentialToken.d.ts +0 -14
- package/dist/fhe-airdrop/react/useAirdropWithdrawOtherToken.d.ts +0 -14
- package/dist/fhe-airdrop/react/useClaim.d.ts +0 -31
- package/dist/fhe-airdrop/react/useConfidentialAirdropFactoryImplementation.d.ts +0 -11
- package/dist/fhe-airdrop/react/useCreateAndFundConfidentialAirdrop.d.ts +0 -41
- package/dist/fhe-airdrop/react/useCreateAndFundConfidentialAirdropAndGetAddress.d.ts +0 -48
- package/dist/fhe-airdrop/react/useCreateConfidentialAirdrop.d.ts +0 -29
- package/dist/fhe-airdrop/react/useCreateConfidentialAirdropAndGetAddress.d.ts +0 -31
- package/dist/fhe-airdrop/react/useDisableCustomFee.d.ts +0 -14
- package/dist/fhe-airdrop/react/useFactoryCustomFee.d.ts +0 -17
- package/dist/fhe-airdrop/react/useFactoryDefaultGasFee.d.ts +0 -10
- package/dist/fhe-airdrop/react/useFactoryFeeCollector.d.ts +0 -11
- package/dist/fhe-airdrop/react/useFactoryInitCodeHash.d.ts +0 -17
- package/dist/fhe-airdrop/react/useFundConfidentialAirdrop.d.ts +0 -33
- package/dist/fhe-airdrop/react/useGetClaimAmount.d.ts +0 -30
- package/dist/fhe-airdrop/react/usePreflightCreateAirdrop.d.ts +0 -51
- package/dist/fhe-airdrop/react/useSetCustomFee.d.ts +0 -16
- package/dist/fhe-airdrop/react/useSetDefaultGasFee.d.ts +0 -15
- package/dist/fhe-airdrop/react/useSetFeeCollector.d.ts +0 -14
- package/dist/fhe-airdrop/react/useSetPaused.d.ts +0 -14
- package/dist/fhe-airdrop/react/useSignClaimAuthorization.d.ts +0 -31
- package/dist/fhe-airdrop/react/useWithdraw.d.ts +0 -12
- package/dist/fhe-airdrop/react/useWithdrawOtherConfidentialToken.d.ts +0 -13
- package/dist/fhe-airdrop/react/useWithdrawOtherToken.d.ts +0 -13
- package/dist/fhe-vesting/react/useGetClaimableAmount.d.ts +0 -13
- package/dist/fhe-vesting/react/useGetSettledAmount.d.ts +0 -14
- package/dist/fhe-vesting/react/useGetTotalAllocation.d.ts +0 -13
- package/dist/fhe-vesting/react/useGetVestedAmount.d.ts +0 -25
|
@@ -72,10 +72,10 @@ export { useRecipientVestingsSliced, type UseRecipientVestingsSlicedArgs, } from
|
|
|
72
72
|
export { usePendingVestingTransfer, type UsePendingVestingTransferArgs, } from "./usePendingVestingTransfer.js";
|
|
73
73
|
export { useHasRole, type UseHasRoleArgs } from "./useHasRole.js";
|
|
74
74
|
export { useRoleConstants, type RoleConstants } from "./useRoleConstants.js";
|
|
75
|
-
export { useGetVestedAmount, type UseGetVestedAmountArgs } from "./
|
|
76
|
-
export { useGetClaimableAmount, type UseGetClaimableAmountArgs } from "./
|
|
77
|
-
export { useGetTotalAllocation, type UseGetTotalAllocationArgs } from "./
|
|
78
|
-
export { useGetSettledAmount, type UseGetSettledAmountArgs } from "./
|
|
75
|
+
export { useAccessVestedAmount, useGetVestedAmount, type UseAccessVestedAmountArgs, type UseGetVestedAmountArgs, } from "./useAccessVestedAmount.js";
|
|
76
|
+
export { useAccessClaimableAmount, useGetClaimableAmount, type UseAccessClaimableAmountArgs, type UseGetClaimableAmountArgs, } from "./useAccessClaimableAmount.js";
|
|
77
|
+
export { useAccessTotalAllocation, useGetTotalAllocation, type UseAccessTotalAllocationArgs, type UseGetTotalAllocationArgs, } from "./useAccessTotalAllocation.js";
|
|
78
|
+
export { useAccessSettledAmount, useGetSettledAmount, type UseAccessSettledAmountArgs, type UseGetSettledAmountArgs, } from "./useAccessSettledAmount.js";
|
|
79
79
|
export { useAdminGetVestedAmount, type UseAdminGetVestedAmountArgs, } from "./useAdminGetVestedAmount.js";
|
|
80
80
|
export { useAdminGetClaimableAmount, type UseAdminGetClaimableAmountArgs, } from "./useAdminGetClaimableAmount.js";
|
|
81
81
|
export { useAdminGetTotalAllocation, type UseAdminGetTotalAllocationArgs, } from "./useAdminGetTotalAllocation.js";
|
|
@@ -122,3 +122,5 @@ export { scaleRatio, type ScaleRatioArgs, type ScaledRatio } from "../../fhe/sca
|
|
|
122
122
|
export { TokenOpsSdkError, isTokenOpsSdkError, DeploymentAddressUnavailableError, UnsupportedChainError, MissingAccountError, MissingClientError, MissingEncryptorError, MissingPublicClientError, MissingWalletClientError, InvalidArgumentError, ReceiptEventAmbiguousError, ReceiptEventNotFoundError, ContractRevertError, PausedError, AccessDeniedError, OperatorNotApprovedError, InsufficientFeeError, InsufficientBalanceError, BatchTooLargeError, FeatureDisabledError, TransferFailedError, FheHandleNotAllowedError, AlreadyInitializedError, ReentrancyError, InvalidSignatureError, WalletRejectedError, WalletChainMismatchError, NetworkError, InsufficientGasFundsError, UnknownWriteFailureError, UserRejectedSignatureError, SigningFailedError, RelayerUnreachableError, EncryptionFailedError, DecryptionFailedError, UserDecryptNotAllowedError, type DeploymentAddressUnavailableReason, type TokenOpsSdkErrorCode, } from "../../core/errors.js";
|
|
123
123
|
export { type PreflightResult } from "../../core/preflight.js";
|
|
124
124
|
export { VestingNotFoundError, NotVestingRecipientError, ClaimLockedError, VestingRevokedError, VestingNotRevocableError, VestingExpiredError, TransferAlreadyPendingError, NoPendingTransferError, NotPendingRecipientError, TransferExpiredError, } from "../errors.js";
|
|
125
|
+
export { useIsOperator, type UseIsOperatorOptions } from "../../fhe/react/useIsOperator.js";
|
|
126
|
+
export { useEnsureOperator, type UseEnsureOperatorOptions, type EnsureOperatorVariables, } from "../../fhe/react/useEnsureOperator.js";
|
|
@@ -72,10 +72,10 @@ export { useRecipientVestingsSliced, type UseRecipientVestingsSlicedArgs, } from
|
|
|
72
72
|
export { usePendingVestingTransfer, type UsePendingVestingTransferArgs, } from "./usePendingVestingTransfer.js";
|
|
73
73
|
export { useHasRole, type UseHasRoleArgs } from "./useHasRole.js";
|
|
74
74
|
export { useRoleConstants, type RoleConstants } from "./useRoleConstants.js";
|
|
75
|
-
export { useGetVestedAmount, type UseGetVestedAmountArgs } from "./
|
|
76
|
-
export { useGetClaimableAmount, type UseGetClaimableAmountArgs } from "./
|
|
77
|
-
export { useGetTotalAllocation, type UseGetTotalAllocationArgs } from "./
|
|
78
|
-
export { useGetSettledAmount, type UseGetSettledAmountArgs } from "./
|
|
75
|
+
export { useAccessVestedAmount, useGetVestedAmount, type UseAccessVestedAmountArgs, type UseGetVestedAmountArgs, } from "./useAccessVestedAmount.js";
|
|
76
|
+
export { useAccessClaimableAmount, useGetClaimableAmount, type UseAccessClaimableAmountArgs, type UseGetClaimableAmountArgs, } from "./useAccessClaimableAmount.js";
|
|
77
|
+
export { useAccessTotalAllocation, useGetTotalAllocation, type UseAccessTotalAllocationArgs, type UseGetTotalAllocationArgs, } from "./useAccessTotalAllocation.js";
|
|
78
|
+
export { useAccessSettledAmount, useGetSettledAmount, type UseAccessSettledAmountArgs, type UseGetSettledAmountArgs, } from "./useAccessSettledAmount.js";
|
|
79
79
|
export { useAdminGetVestedAmount, type UseAdminGetVestedAmountArgs, } from "./useAdminGetVestedAmount.js";
|
|
80
80
|
export { useAdminGetClaimableAmount, type UseAdminGetClaimableAmountArgs, } from "./useAdminGetClaimableAmount.js";
|
|
81
81
|
export { useAdminGetTotalAllocation, type UseAdminGetTotalAllocationArgs, } from "./useAdminGetTotalAllocation.js";
|
|
@@ -122,3 +122,5 @@ export { scaleRatio, type ScaleRatioArgs, type ScaledRatio } from "../../fhe/sca
|
|
|
122
122
|
export { TokenOpsSdkError, isTokenOpsSdkError, DeploymentAddressUnavailableError, UnsupportedChainError, MissingAccountError, MissingClientError, MissingEncryptorError, MissingPublicClientError, MissingWalletClientError, InvalidArgumentError, ReceiptEventAmbiguousError, ReceiptEventNotFoundError, ContractRevertError, PausedError, AccessDeniedError, OperatorNotApprovedError, InsufficientFeeError, InsufficientBalanceError, BatchTooLargeError, FeatureDisabledError, TransferFailedError, FheHandleNotAllowedError, AlreadyInitializedError, ReentrancyError, InvalidSignatureError, WalletRejectedError, WalletChainMismatchError, NetworkError, InsufficientGasFundsError, UnknownWriteFailureError, UserRejectedSignatureError, SigningFailedError, RelayerUnreachableError, EncryptionFailedError, DecryptionFailedError, UserDecryptNotAllowedError, type DeploymentAddressUnavailableReason, type TokenOpsSdkErrorCode, } from "../../core/errors.js";
|
|
123
123
|
export { type PreflightResult } from "../../core/preflight.js";
|
|
124
124
|
export { VestingNotFoundError, NotVestingRecipientError, ClaimLockedError, VestingRevokedError, VestingNotRevocableError, VestingExpiredError, TransferAlreadyPendingError, NoPendingTransferError, NotPendingRecipientError, TransferExpiredError, } from "../errors.js";
|
|
125
|
+
export { useIsOperator, type UseIsOperatorOptions } from "../../fhe/react/useIsOperator.js";
|
|
126
|
+
export { useEnsureOperator, type UseEnsureOperatorOptions, type EnsureOperatorVariables, } from "../../fhe/react/useEnsureOperator.js";
|
|
@@ -1,17 +1,21 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
export { useEnsureOperator, useIsOperator } from '../../chunk-AXIPOR3C.js';
|
|
2
|
+
import '../../chunk-FT4LNBOS.js';
|
|
3
|
+
import '../../chunk-4TSDNZQ3.js';
|
|
4
|
+
import { useMemoFactoryClient, buildQueryKey, useMemoManagerClient } from '../../chunk-6NAVMWZQ.js';
|
|
5
|
+
export { ClaimLockedError, NoPendingTransferError, NotPendingRecipientError, NotVestingRecipientError, TransferAlreadyPendingError, TransferExpiredError, VestingExpiredError, VestingNotFoundError, VestingNotRevocableError, VestingRevokedError } from '../../chunk-TWT3STIX.js';
|
|
3
6
|
import '../../chunk-WMACINXO.js';
|
|
4
|
-
export { scaleRatio } from '../../chunk-
|
|
7
|
+
export { encryptUint64, encryptUint64Batch, resolveEncryptor, scaleRatio } from '../../chunk-6GNR22OV.js';
|
|
5
8
|
import '../../chunk-ZWXJTBZO.js';
|
|
6
9
|
import '../../chunk-7VELUOMI.js';
|
|
7
|
-
export { DisclosureType, FeeType } from '../../chunk-
|
|
8
|
-
import '../../chunk-
|
|
9
|
-
import '../../chunk-
|
|
10
|
+
export { DisclosureType, FeeType } from '../../chunk-EAJ7SYHE.js';
|
|
11
|
+
import '../../chunk-NWFMBLSQ.js';
|
|
12
|
+
import '../../chunk-4RAAATVY.js';
|
|
13
|
+
import '../../chunk-DZHYSUGY.js';
|
|
10
14
|
import '../../chunk-ZA673I3O.js';
|
|
11
|
-
import '../../chunk-Q2GP5UDC.js';
|
|
12
15
|
import '../../chunk-KWFFIJYX.js';
|
|
13
16
|
import { MissingClientError } from '../../chunk-QBJ7O2B4.js';
|
|
14
17
|
export { AccessDeniedError, AlreadyInitializedError, BatchTooLargeError, ContractRevertError, DecryptionFailedError, DeploymentAddressUnavailableError, EncryptionFailedError, FeatureDisabledError, FheHandleNotAllowedError, InsufficientBalanceError, InsufficientFeeError, InsufficientGasFundsError, InvalidArgumentError, InvalidSignatureError, MissingAccountError, MissingClientError, MissingEncryptorError, MissingPublicClientError, MissingWalletClientError, NetworkError, OperatorNotApprovedError, PausedError, ReceiptEventAmbiguousError, ReceiptEventNotFoundError, ReentrancyError, RelayerUnreachableError, SigningFailedError, TokenOpsSdkError, TransferFailedError, UnknownWriteFailureError, UnsupportedChainError, UserDecryptNotAllowedError, UserRejectedSignatureError, WalletChainMismatchError, WalletRejectedError, isTokenOpsSdkError } from '../../chunk-QBJ7O2B4.js';
|
|
18
|
+
import '../../chunk-Q2GP5UDC.js';
|
|
15
19
|
import { useQuery, useMutation } from '@tanstack/react-query';
|
|
16
20
|
|
|
17
21
|
function useConfidentialVestingFactoryImplementation(options = {}) {
|
|
@@ -415,42 +419,46 @@ function useRoleConstants(options) {
|
|
|
415
419
|
staleTime: 0
|
|
416
420
|
});
|
|
417
421
|
}
|
|
418
|
-
function
|
|
422
|
+
function useAccessVestedAmount(options) {
|
|
419
423
|
const { client } = useMemoManagerClient(options);
|
|
420
424
|
return useMutation({
|
|
421
425
|
mutationFn: async (args) => {
|
|
422
|
-
if (!client) throw new MissingClientError("
|
|
426
|
+
if (!client) throw new MissingClientError("useAccessVestedAmount", "manager");
|
|
423
427
|
return client.getVestedAmount(args);
|
|
424
428
|
}
|
|
425
429
|
});
|
|
426
430
|
}
|
|
427
|
-
|
|
431
|
+
var useGetVestedAmount = useAccessVestedAmount;
|
|
432
|
+
function useAccessClaimableAmount(options) {
|
|
428
433
|
const { client } = useMemoManagerClient(options);
|
|
429
434
|
return useMutation({
|
|
430
435
|
mutationFn: async (args) => {
|
|
431
|
-
if (!client) throw new MissingClientError("
|
|
436
|
+
if (!client) throw new MissingClientError("useAccessClaimableAmount", "manager");
|
|
432
437
|
return client.getClaimableAmount(args);
|
|
433
438
|
}
|
|
434
439
|
});
|
|
435
440
|
}
|
|
436
|
-
|
|
441
|
+
var useGetClaimableAmount = useAccessClaimableAmount;
|
|
442
|
+
function useAccessTotalAllocation(options) {
|
|
437
443
|
const { client } = useMemoManagerClient(options);
|
|
438
444
|
return useMutation({
|
|
439
445
|
mutationFn: async (args) => {
|
|
440
|
-
if (!client) throw new MissingClientError("
|
|
446
|
+
if (!client) throw new MissingClientError("useAccessTotalAllocation", "manager");
|
|
441
447
|
return client.getTotalAllocation(args);
|
|
442
448
|
}
|
|
443
449
|
});
|
|
444
450
|
}
|
|
445
|
-
|
|
451
|
+
var useGetTotalAllocation = useAccessTotalAllocation;
|
|
452
|
+
function useAccessSettledAmount(options) {
|
|
446
453
|
const { client } = useMemoManagerClient(options);
|
|
447
454
|
return useMutation({
|
|
448
455
|
mutationFn: async (args) => {
|
|
449
|
-
if (!client) throw new MissingClientError("
|
|
456
|
+
if (!client) throw new MissingClientError("useAccessSettledAmount", "manager");
|
|
450
457
|
return client.getSettledAmount(args);
|
|
451
458
|
}
|
|
452
459
|
});
|
|
453
460
|
}
|
|
461
|
+
var useGetSettledAmount = useAccessSettledAmount;
|
|
454
462
|
function useAdminGetVestedAmount(options) {
|
|
455
463
|
const { client } = useMemoManagerClient(options);
|
|
456
464
|
return useMutation({
|
|
@@ -785,4 +793,4 @@ function useRenounceRole(options) {
|
|
|
785
793
|
});
|
|
786
794
|
}
|
|
787
795
|
|
|
788
|
-
export { useAcceptVestingTransfer, useAdminBatchDiscloseToParty, useAdminClaim, useAdminDiscloseToParty, useAdminGetClaimableAmount, useAdminGetSettledAmount, useAdminGetTokenBalance, useAdminGetTotalAllocation, useAdminGetVestedAmount, useAdminPartialClaim, useAllRecipients, useAllRecipientsLength, useAllRecipientsSliced, useBatchCreateVesting, useBatchDiscloseHandlesToParty, useBatchDiscloseToParty, useBatchRevokeVesting, useCancelVestingTransfer, useClaim, useConfidentialVestingFactoryImplementation, useCreateManager, useCreateManagerAndGetAddress, useCreateVesting, useDirectVestingTransfer, useDisableCustomFee, useDiscloseHandleToParty, useDiscloseToParty, useFactoryCustomFee, useFactoryDefaultFeeType, useFactoryDefaultGasFee, useFactoryDefaultTokenFee, useFactoryFeeCollector, useFactoryInitCodeHash, useGetClaimableAmount, useGetSettledAmount, useGetTotalAllocation, useGetVestedAmount, useGrantRole, useHasRole, useInitiateVestingTransfer, useIsRecipient, useManagerDeploymentBlockNumber, useManagerFee, useManagerFeeInfo, useManagerFeeType, useManagerIsPausable, useManagerIsSplitEnabled, useManagerMaxBatchSize, useManagerMaxRevokeBatchSize, useManagerPaused, useManagerToken, usePartialClaim, usePause, usePendingVestingTransfer, usePreflightCreateVesting, useRecipientVestings, useRecipientVestingsLength, useRecipientVestingsSliced, useRenounceRole, useResetGasFee, useResetTokenFee, useRevokeRole, useRevokeVesting, useRoleConstants, useSetCustomFee, useSetDefaultFeeType, useSetDefaultGasFee, useSetDefaultTokenFee, useSetFeeCollector, useSetMaxBatchSize, useSetMaxRevokeBatchSize, useSplitVesting, useTransferFeeCollectorRole, useUnpause, useVestingInfo, useWithdrawAdmin, useWithdrawGasFee, useWithdrawOtherConfidentialToken, useWithdrawOtherToken, useWithdrawTokenFee };
|
|
796
|
+
export { useAcceptVestingTransfer, useAccessClaimableAmount, useAccessSettledAmount, useAccessTotalAllocation, useAccessVestedAmount, useAdminBatchDiscloseToParty, useAdminClaim, useAdminDiscloseToParty, useAdminGetClaimableAmount, useAdminGetSettledAmount, useAdminGetTokenBalance, useAdminGetTotalAllocation, useAdminGetVestedAmount, useAdminPartialClaim, useAllRecipients, useAllRecipientsLength, useAllRecipientsSliced, useBatchCreateVesting, useBatchDiscloseHandlesToParty, useBatchDiscloseToParty, useBatchRevokeVesting, useCancelVestingTransfer, useClaim, useConfidentialVestingFactoryImplementation, useCreateManager, useCreateManagerAndGetAddress, useCreateVesting, useDirectVestingTransfer, useDisableCustomFee, useDiscloseHandleToParty, useDiscloseToParty, useFactoryCustomFee, useFactoryDefaultFeeType, useFactoryDefaultGasFee, useFactoryDefaultTokenFee, useFactoryFeeCollector, useFactoryInitCodeHash, useGetClaimableAmount, useGetSettledAmount, useGetTotalAllocation, useGetVestedAmount, useGrantRole, useHasRole, useInitiateVestingTransfer, useIsRecipient, useManagerDeploymentBlockNumber, useManagerFee, useManagerFeeInfo, useManagerFeeType, useManagerIsPausable, useManagerIsSplitEnabled, useManagerMaxBatchSize, useManagerMaxRevokeBatchSize, useManagerPaused, useManagerToken, usePartialClaim, usePause, usePendingVestingTransfer, usePreflightCreateVesting, useRecipientVestings, useRecipientVestingsLength, useRecipientVestingsSliced, useRenounceRole, useResetGasFee, useResetTokenFee, useRevokeRole, useRevokeVesting, useRoleConstants, useSetCustomFee, useSetDefaultFeeType, useSetDefaultGasFee, useSetDefaultTokenFee, useSetFeeCollector, useSetMaxBatchSize, useSetMaxRevokeBatchSize, useSplitVesting, useTransferFeeCollectorRole, useUnpause, useVestingInfo, useWithdrawAdmin, useWithdrawGasFee, useWithdrawOtherConfidentialToken, useWithdrawOtherToken, useWithdrawTokenFee };
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import { type UseMutationResult } from "@tanstack/react-query";
|
|
2
|
-
import type { Account, Address } from "viem";
|
|
3
|
-
import type { VestingId } from "../../core/brands.js";
|
|
2
|
+
import type { Account, Address, Hex } from "viem";
|
|
4
3
|
import type { EncryptedViewResult } from "../manager.js";
|
|
5
4
|
import { type ManagerHookOptions } from "./_shared.js";
|
|
6
5
|
export interface UseAccessClaimableAmountArgs {
|
|
7
|
-
vestingId:
|
|
6
|
+
vestingId: Hex;
|
|
8
7
|
account?: Account | Address;
|
|
9
8
|
}
|
|
10
9
|
/**
|
|
@@ -12,3 +11,12 @@ export interface UseAccessClaimableAmountArgs {
|
|
|
12
11
|
* `euint128` handle. Pass `data.handle` to the Zama relayer's `userDecrypt`.
|
|
13
12
|
*/
|
|
14
13
|
export declare function useAccessClaimableAmount(options: ManagerHookOptions): UseMutationResult<EncryptedViewResult, Error, UseAccessClaimableAmountArgs>;
|
|
14
|
+
/**
|
|
15
|
+
* @deprecated Renamed to {@link useAccessClaimableAmount}. Both submit a transaction, and the
|
|
16
|
+
* `useGet*` name reads as a free query — which misled bounty builders. This
|
|
17
|
+
* is the same function object, not a wrapper: behavior, argument types and
|
|
18
|
+
* thrown errors are identical. Removed in the next major.
|
|
19
|
+
*/
|
|
20
|
+
export declare const useGetClaimableAmount: typeof useAccessClaimableAmount;
|
|
21
|
+
/** @deprecated Renamed to {@link UseAccessClaimableAmountArgs}. Identical shape. */
|
|
22
|
+
export type UseGetClaimableAmountArgs = UseAccessClaimableAmountArgs;
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import { type UseMutationResult } from "@tanstack/react-query";
|
|
2
|
-
import type { Account, Address } from "viem";
|
|
3
|
-
import type { VestingId } from "../../core/brands.js";
|
|
2
|
+
import type { Account, Address, Hex } from "viem";
|
|
4
3
|
import type { EncryptedViewResult } from "../manager.js";
|
|
5
4
|
import { type ManagerHookOptions } from "./_shared.js";
|
|
6
5
|
export interface UseAccessSettledAmountArgs {
|
|
7
|
-
vestingId:
|
|
6
|
+
vestingId: Hex;
|
|
8
7
|
account?: Account | Address;
|
|
9
8
|
}
|
|
10
9
|
/**
|
|
@@ -13,3 +12,12 @@ export interface UseAccessSettledAmountArgs {
|
|
|
13
12
|
* `userDecrypt`.
|
|
14
13
|
*/
|
|
15
14
|
export declare function useAccessSettledAmount(options: ManagerHookOptions): UseMutationResult<EncryptedViewResult, Error, UseAccessSettledAmountArgs>;
|
|
15
|
+
/**
|
|
16
|
+
* @deprecated Renamed to {@link useAccessSettledAmount}. Both submit a transaction, and the
|
|
17
|
+
* `useGet*` name reads as a free query — which misled bounty builders. This
|
|
18
|
+
* is the same function object, not a wrapper: behavior, argument types and
|
|
19
|
+
* thrown errors are identical. Removed in the next major.
|
|
20
|
+
*/
|
|
21
|
+
export declare const useGetSettledAmount: typeof useAccessSettledAmount;
|
|
22
|
+
/** @deprecated Renamed to {@link UseAccessSettledAmountArgs}. Identical shape. */
|
|
23
|
+
export type UseGetSettledAmountArgs = UseAccessSettledAmountArgs;
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import { type UseMutationResult } from "@tanstack/react-query";
|
|
2
|
-
import type { Account, Address } from "viem";
|
|
3
|
-
import type { VestingId } from "../../core/brands.js";
|
|
2
|
+
import type { Account, Address, Hex } from "viem";
|
|
4
3
|
import type { EncryptedViewResult } from "../manager.js";
|
|
5
4
|
import { type ManagerHookOptions } from "./_shared.js";
|
|
6
5
|
export interface UseAccessTotalAllocationArgs {
|
|
7
|
-
vestingId:
|
|
6
|
+
vestingId: Hex;
|
|
8
7
|
account?: Account | Address;
|
|
9
8
|
}
|
|
10
9
|
/**
|
|
@@ -12,3 +11,12 @@ export interface UseAccessTotalAllocationArgs {
|
|
|
12
11
|
* `euint128` handle. Pass `data.handle` to the Zama relayer's `userDecrypt`.
|
|
13
12
|
*/
|
|
14
13
|
export declare function useAccessTotalAllocation(options: ManagerHookOptions): UseMutationResult<EncryptedViewResult, Error, UseAccessTotalAllocationArgs>;
|
|
14
|
+
/**
|
|
15
|
+
* @deprecated Renamed to {@link useAccessTotalAllocation}. Both submit a transaction, and the
|
|
16
|
+
* `useGet*` name reads as a free query — which misled bounty builders. This
|
|
17
|
+
* is the same function object, not a wrapper: behavior, argument types and
|
|
18
|
+
* thrown errors are identical. Removed in the next major.
|
|
19
|
+
*/
|
|
20
|
+
export declare const useGetTotalAllocation: typeof useAccessTotalAllocation;
|
|
21
|
+
/** @deprecated Renamed to {@link UseAccessTotalAllocationArgs}. Identical shape. */
|
|
22
|
+
export type UseGetTotalAllocationArgs = UseAccessTotalAllocationArgs;
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import { type UseMutationResult } from "@tanstack/react-query";
|
|
2
|
-
import type { Account, Address } from "viem";
|
|
3
|
-
import type { VestingId } from "../../core/brands.js";
|
|
2
|
+
import type { Account, Address, Hex } from "viem";
|
|
4
3
|
import type { EncryptedViewResult } from "../manager.js";
|
|
5
4
|
import { type ManagerHookOptions } from "./_shared.js";
|
|
6
5
|
export interface UseAccessVestedAmountArgs {
|
|
7
|
-
vestingId:
|
|
6
|
+
vestingId: Hex;
|
|
8
7
|
/** Unix timestamp (seconds) — `Math.floor(Date.now() / 1000)` for "now". */
|
|
9
8
|
timestamp: number;
|
|
10
9
|
account?: Account | Address;
|
|
@@ -24,3 +23,12 @@ export interface UseAccessVestedAmountArgs {
|
|
|
24
23
|
* // getVested.data → { handle: "0x...", hash: "0x..." }
|
|
25
24
|
*/
|
|
26
25
|
export declare function useAccessVestedAmount(options: ManagerHookOptions): UseMutationResult<EncryptedViewResult, Error, UseAccessVestedAmountArgs>;
|
|
26
|
+
/**
|
|
27
|
+
* @deprecated Renamed to {@link useAccessVestedAmount}. Both submit a transaction, and the
|
|
28
|
+
* `useGet*` name reads as a free query — which misled bounty builders. This
|
|
29
|
+
* is the same function object, not a wrapper: behavior, argument types and
|
|
30
|
+
* thrown errors are identical. Removed in the next major.
|
|
31
|
+
*/
|
|
32
|
+
export declare const useGetVestedAmount: typeof useAccessVestedAmount;
|
|
33
|
+
/** @deprecated Renamed to {@link UseAccessVestedAmountArgs}. Identical shape. */
|
|
34
|
+
export type UseGetVestedAmountArgs = UseAccessVestedAmountArgs;
|
|
@@ -7,7 +7,7 @@ export interface UseAdminGetClaimableAmountArgs {
|
|
|
7
7
|
account?: Account | Address;
|
|
8
8
|
}
|
|
9
9
|
/**
|
|
10
|
-
* Admin variant of {@link
|
|
10
|
+
* Admin variant of {@link useAccessClaimableAmount} — caller must hold
|
|
11
11
|
* `DISCLOSURE_ADMIN_ROLE`. Submits a tx; returns an `euint128` handle.
|
|
12
12
|
*/
|
|
13
13
|
export declare function useAdminGetClaimableAmount(options: ManagerHookOptions): UseMutationResult<EncryptedViewResult, Error, UseAdminGetClaimableAmountArgs>;
|
|
@@ -7,7 +7,7 @@ export interface UseAdminGetSettledAmountArgs {
|
|
|
7
7
|
account?: Account | Address;
|
|
8
8
|
}
|
|
9
9
|
/**
|
|
10
|
-
* Admin variant of {@link
|
|
10
|
+
* Admin variant of {@link useAccessSettledAmount} — caller must hold
|
|
11
11
|
* `DISCLOSURE_ADMIN_ROLE`. Submits a tx; returns an `euint128` handle.
|
|
12
12
|
*/
|
|
13
13
|
export declare function useAdminGetSettledAmount(options: ManagerHookOptions): UseMutationResult<EncryptedViewResult, Error, UseAdminGetSettledAmountArgs>;
|
|
@@ -7,7 +7,7 @@ export interface UseAdminGetTotalAllocationArgs {
|
|
|
7
7
|
account?: Account | Address;
|
|
8
8
|
}
|
|
9
9
|
/**
|
|
10
|
-
* Admin variant of {@link
|
|
10
|
+
* Admin variant of {@link useAccessTotalAllocation} — caller must hold
|
|
11
11
|
* `DISCLOSURE_ADMIN_ROLE`. Submits a tx; returns an `euint128` handle.
|
|
12
12
|
*/
|
|
13
13
|
export declare function useAdminGetTotalAllocation(options: ManagerHookOptions): UseMutationResult<EncryptedViewResult, Error, UseAdminGetTotalAllocationArgs>;
|
|
@@ -8,7 +8,7 @@ export interface UseAdminGetVestedAmountArgs {
|
|
|
8
8
|
account?: Account | Address;
|
|
9
9
|
}
|
|
10
10
|
/**
|
|
11
|
-
* Admin variant of {@link
|
|
11
|
+
* Admin variant of {@link useAccessVestedAmount} — caller must hold
|
|
12
12
|
* `DISCLOSURE_ADMIN_ROLE`. Submits a tx; returns an `euint128` handle granted
|
|
13
13
|
* to the admin caller. Pass `data.handle` to the Zama relayer's `userDecrypt`.
|
|
14
14
|
*/
|
|
@@ -5,6 +5,14 @@ import { type ManagerHookOptions } from "./_shared.js";
|
|
|
5
5
|
/**
|
|
6
6
|
* Admin variant of {@link usePartialClaim} — caller must hold `CLAIMER_ROLE`.
|
|
7
7
|
*
|
|
8
|
+
* **Amount units:** TokenOps confidential (ERC-7984) tokens use a 6-decimals
|
|
9
|
+
* convention (1 token = 1_000_000 base units), not the 18 decimals typical of
|
|
10
|
+
* ERC-20. Amount parameters are base units of the token's actual decimals:
|
|
11
|
+
* for the CTTT test token (6 decimals) `1_000_000n` = 1 CTTT, while the
|
|
12
|
+
* transparent TTT test token uses 18 decimals. This hook shares
|
|
13
|
+
* {@link PartialClaimArgs} with {@link usePartialClaim}, so an 18-decimals
|
|
14
|
+
* assumption over-claims by 10^12.
|
|
15
|
+
*
|
|
8
16
|
* **Silent-zero transfers.** ERC-7984 transfers do not revert when the sender's encrypted balance is insufficient — the transfer succeeds and moves an encrypted zero instead. This is by design: reverting would leak balance information. The transaction receipt alone cannot tell you whether value actually moved.
|
|
9
17
|
*/
|
|
10
18
|
export declare function useAdminPartialClaim(options: ManagerHookOptions): UseMutationResult<Hex, Error, PartialClaimArgs>;
|
|
@@ -9,7 +9,7 @@ import { type ManagerHookOptions } from "./_shared.js";
|
|
|
9
9
|
* {@link useManagerFeeInfo} to read it. For `FeeType.DistributionToken`,
|
|
10
10
|
* omit `value`.
|
|
11
11
|
*
|
|
12
|
-
* After success, invalidate `
|
|
12
|
+
* After success, invalidate `useAccessClaimableAmount` (the encrypted view) and
|
|
13
13
|
* any UI counts you computed off it.
|
|
14
14
|
*
|
|
15
15
|
* **Silent-zero transfers.** ERC-7984 transfers do not revert when the sender's encrypted balance is insufficient — the transfer succeeds and moves an encrypted zero instead. This is by design: reverting would leak balance information. The transaction receipt alone cannot tell you whether value actually moved.
|
|
@@ -8,7 +8,7 @@ export interface UseDiscloseHandleToPartyArgs {
|
|
|
8
8
|
}
|
|
9
9
|
/**
|
|
10
10
|
* Grant `party` decrypt access to an arbitrary already-allowed `handle` you
|
|
11
|
-
* own. Typical use: forward a handle returned by `
|
|
11
|
+
* own. Typical use: forward a handle returned by `useAccessClaimableAmount` to
|
|
12
12
|
* an auditor without leaking plaintext.
|
|
13
13
|
*/
|
|
14
14
|
export declare function useDiscloseHandleToParty(options: ManagerHookOptions): UseMutationResult<Hex, Error, UseDiscloseHandleToPartyArgs>;
|
|
@@ -10,7 +10,7 @@ export interface UseManagerDiscloseHandleToPartyArgs {
|
|
|
10
10
|
}
|
|
11
11
|
/**
|
|
12
12
|
* Grant `party` decrypt access to an arbitrary already-allowed `handle` you
|
|
13
|
-
* own. Typical use: forward a handle returned by `
|
|
13
|
+
* own. Typical use: forward a handle returned by `useAccessClaimableAmount` to
|
|
14
14
|
* an auditor without leaking plaintext.
|
|
15
15
|
*/
|
|
16
16
|
export declare function useManagerDiscloseHandleToParty(options: ManagerHookOptions): UseMutationResult<TxHash, Error, UseManagerDiscloseHandleToPartyArgs>;
|
|
@@ -12,7 +12,7 @@ import { type ManagerHookOptions } from "./_shared.js";
|
|
|
12
12
|
* for the CTTT test token (6 decimals) `1_000_000n` = 1 CTTT, while the
|
|
13
13
|
* transparent TTT test token uses 18 decimals.
|
|
14
14
|
*
|
|
15
|
-
* After success, invalidate `
|
|
15
|
+
* After success, invalidate `useAccessClaimableAmount` and `useAccessSettledAmount`.
|
|
16
16
|
*
|
|
17
17
|
* **Silent-zero transfers.** ERC-7984 transfers do not revert when the sender's encrypted balance is insufficient — the transfer succeeds and moves an encrypted zero instead. This is by design: reverting would leak balance information. The transaction receipt alone cannot tell you whether value actually moved.
|
|
18
18
|
*
|
|
@@ -8,7 +8,7 @@ export interface UseVestingInfoArgs extends ManagerHookOptions {
|
|
|
8
8
|
/**
|
|
9
9
|
* Read the plaintext snapshot of a vesting schedule — recipient, timestamps,
|
|
10
10
|
* unlock bps, revocability flag. **Amounts are encrypted and NOT in this
|
|
11
|
-
* payload** — use {@link
|
|
11
|
+
* payload** — use {@link useAccessTotalAllocation} / {@link useAccessVestedAmount}
|
|
12
12
|
* for encrypted-amount handles.
|
|
13
13
|
*
|
|
14
14
|
* @remarks
|
|
@@ -79,6 +79,13 @@ export interface PendingTransfer {
|
|
|
79
79
|
* - `isOperatorSet` — `true` when the creator has approved the manager as an
|
|
80
80
|
* ERC-7984 operator on `token` (required for the manager's
|
|
81
81
|
* `confidentialTransferFrom` pull).
|
|
82
|
+
*
|
|
83
|
+
* **`false` does not mean "not approved" on its own** — it is also `false`
|
|
84
|
+
* when approval could not be determined at all: the bound `token` is not an
|
|
85
|
+
* ERC-7984 token, so the `isOperator` read failed. Do not render an
|
|
86
|
+
* "approve the manager" prompt off this field alone; check `blockerErrors`
|
|
87
|
+
* for `TOKENOPS_OPERATOR_NOT_APPROVED` first, which is present only when
|
|
88
|
+
* the approval genuinely is the missing step.
|
|
82
89
|
* - `ready` — `true` when no blockers were detected.
|
|
83
90
|
* - `blockers` — human-readable blocker descriptions. Empty when
|
|
84
91
|
* `ready === true`.
|
|
@@ -90,7 +97,11 @@ export interface CreateVestingPreflightReport {
|
|
|
90
97
|
token: Address;
|
|
91
98
|
/** `true` when the creator holds `VESTING_CREATOR_ROLE` on the manager. */
|
|
92
99
|
hasCreatorRole: boolean;
|
|
93
|
-
/**
|
|
100
|
+
/**
|
|
101
|
+
* `true` when the creator has approved the manager as operator on `token`.
|
|
102
|
+
* Also `false` when approval could not be determined (non-ERC-7984 token);
|
|
103
|
+
* branch on `blockerErrors` rather than this field alone.
|
|
104
|
+
*/
|
|
94
105
|
isOperatorSet: boolean;
|
|
95
106
|
/** `true` when no blockers were detected — green light to submit the write. */
|
|
96
107
|
ready: boolean;
|
package/dist/index.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunk5576FRT3_cjs = require('./chunk-5576FRT3.cjs');
|
|
4
4
|
var chunk66IHPTOK_cjs = require('./chunk-66IHPTOK.cjs');
|
|
5
5
|
var chunk67OV5CX2_cjs = require('./chunk-67OV5CX2.cjs');
|
|
6
6
|
var chains = require('viem/chains');
|
|
@@ -15,59 +15,71 @@ function isSupportedChainId(chainId) {
|
|
|
15
15
|
|
|
16
16
|
Object.defineProperty(exports, "DEPLOYED_ADDRESSES", {
|
|
17
17
|
enumerable: true,
|
|
18
|
-
get: function () { return
|
|
18
|
+
get: function () { return chunk5576FRT3_cjs.DEPLOYED_ADDRESSES; }
|
|
19
19
|
});
|
|
20
20
|
Object.defineProperty(exports, "chainsWithDeployment", {
|
|
21
21
|
enumerable: true,
|
|
22
|
-
get: function () { return
|
|
22
|
+
get: function () { return chunk5576FRT3_cjs.chainsWithDeployment; }
|
|
23
23
|
});
|
|
24
24
|
Object.defineProperty(exports, "chainsWithKnownRegistryEntry", {
|
|
25
25
|
enumerable: true,
|
|
26
|
-
get: function () { return
|
|
26
|
+
get: function () { return chunk5576FRT3_cjs.chainsWithKnownRegistryEntry; }
|
|
27
27
|
});
|
|
28
28
|
Object.defineProperty(exports, "getConfidentialTestTokenAddress", {
|
|
29
29
|
enumerable: true,
|
|
30
|
-
get: function () { return
|
|
30
|
+
get: function () { return chunk5576FRT3_cjs.getConfidentialTestTokenAddress; }
|
|
31
31
|
});
|
|
32
32
|
Object.defineProperty(exports, "getDeployedAddress", {
|
|
33
33
|
enumerable: true,
|
|
34
|
-
get: function () { return
|
|
34
|
+
get: function () { return chunk5576FRT3_cjs.getDeployedAddress; }
|
|
35
|
+
});
|
|
36
|
+
Object.defineProperty(exports, "getFheAirdropComplianceImplementationAddress", {
|
|
37
|
+
enumerable: true,
|
|
38
|
+
get: function () { return chunk5576FRT3_cjs.getFheAirdropComplianceImplementationAddress; }
|
|
39
|
+
});
|
|
40
|
+
Object.defineProperty(exports, "getFheAirdropEcdsaImplementationAddress", {
|
|
41
|
+
enumerable: true,
|
|
42
|
+
get: function () { return chunk5576FRT3_cjs.getFheAirdropEcdsaImplementationAddress; }
|
|
35
43
|
});
|
|
36
44
|
Object.defineProperty(exports, "getFheAirdropFactoryAddress", {
|
|
37
45
|
enumerable: true,
|
|
38
|
-
get: function () { return
|
|
46
|
+
get: function () { return chunk5576FRT3_cjs.getFheAirdropFactoryAddress; }
|
|
47
|
+
});
|
|
48
|
+
Object.defineProperty(exports, "getFheAirdropMerkleImplementationAddress", {
|
|
49
|
+
enumerable: true,
|
|
50
|
+
get: function () { return chunk5576FRT3_cjs.getFheAirdropMerkleImplementationAddress; }
|
|
39
51
|
});
|
|
40
52
|
Object.defineProperty(exports, "getFheDisperseSingletonAddress", {
|
|
41
53
|
enumerable: true,
|
|
42
|
-
get: function () { return
|
|
54
|
+
get: function () { return chunk5576FRT3_cjs.getFheDisperseSingletonAddress; }
|
|
43
55
|
});
|
|
44
56
|
Object.defineProperty(exports, "getFheVestingFactoryAddress", {
|
|
45
57
|
enumerable: true,
|
|
46
|
-
get: function () { return
|
|
58
|
+
get: function () { return chunk5576FRT3_cjs.getFheVestingFactoryAddress; }
|
|
47
59
|
});
|
|
48
60
|
Object.defineProperty(exports, "getTestTokenAddress", {
|
|
49
61
|
enumerable: true,
|
|
50
|
-
get: function () { return
|
|
62
|
+
get: function () { return chunk5576FRT3_cjs.getTestTokenAddress; }
|
|
51
63
|
});
|
|
52
64
|
Object.defineProperty(exports, "requireConfidentialTestTokenAddress", {
|
|
53
65
|
enumerable: true,
|
|
54
|
-
get: function () { return
|
|
66
|
+
get: function () { return chunk5576FRT3_cjs.requireConfidentialTestTokenAddress; }
|
|
55
67
|
});
|
|
56
68
|
Object.defineProperty(exports, "requireFheAirdropFactoryAddress", {
|
|
57
69
|
enumerable: true,
|
|
58
|
-
get: function () { return
|
|
70
|
+
get: function () { return chunk5576FRT3_cjs.requireFheAirdropFactoryAddress; }
|
|
59
71
|
});
|
|
60
72
|
Object.defineProperty(exports, "requireFheDisperseSingletonAddress", {
|
|
61
73
|
enumerable: true,
|
|
62
|
-
get: function () { return
|
|
74
|
+
get: function () { return chunk5576FRT3_cjs.requireFheDisperseSingletonAddress; }
|
|
63
75
|
});
|
|
64
76
|
Object.defineProperty(exports, "requireFheVestingFactoryAddress", {
|
|
65
77
|
enumerable: true,
|
|
66
|
-
get: function () { return
|
|
78
|
+
get: function () { return chunk5576FRT3_cjs.requireFheVestingFactoryAddress; }
|
|
67
79
|
});
|
|
68
80
|
Object.defineProperty(exports, "requireTestTokenAddress", {
|
|
69
81
|
enumerable: true,
|
|
70
|
-
get: function () { return
|
|
82
|
+
get: function () { return chunk5576FRT3_cjs.requireTestTokenAddress; }
|
|
71
83
|
});
|
|
72
84
|
Object.defineProperty(exports, "asAirdropId", {
|
|
73
85
|
enumerable: true,
|
package/dist/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { DEPLOYED_ADDRESSES, chainsWithDeployment, chainsWithKnownRegistryEntry, getConfidentialTestTokenAddress, getDeployedAddress, getFheAirdropFactoryAddress, getFheDisperseSingletonAddress, getFheVestingFactoryAddress, getTestTokenAddress, requireConfidentialTestTokenAddress, requireFheAirdropFactoryAddress, requireFheDisperseSingletonAddress, requireFheVestingFactoryAddress, requireTestTokenAddress } from './chunk-
|
|
1
|
+
export { DEPLOYED_ADDRESSES, chainsWithDeployment, chainsWithKnownRegistryEntry, getConfidentialTestTokenAddress, getDeployedAddress, getFheAirdropComplianceImplementationAddress, getFheAirdropEcdsaImplementationAddress, getFheAirdropFactoryAddress, getFheAirdropMerkleImplementationAddress, getFheDisperseSingletonAddress, getFheVestingFactoryAddress, getTestTokenAddress, requireConfidentialTestTokenAddress, requireFheAirdropFactoryAddress, requireFheDisperseSingletonAddress, requireFheVestingFactoryAddress, requireTestTokenAddress } from './chunk-DZHYSUGY.js';
|
|
2
2
|
export { asAirdropId, asDisperseId, asEncryptedHandle, asExternalInputProof, asRole, asSignature, asTxHash, asVestingId } from './chunk-KWFFIJYX.js';
|
|
3
3
|
export { AccessDeniedError, AlreadyInitializedError, BatchTooLargeError, ContractRevertError, DecryptionFailedError, DeploymentAddressUnavailableError, EncryptionFailedError, FeatureDisabledError, FheHandleNotAllowedError, InsufficientBalanceError, InsufficientFeeError, InsufficientGasFundsError, InvalidArgumentError, InvalidSignatureError, MissingAccountError, MissingClientError, MissingEncryptorError, MissingPublicClientError, MissingWalletClientError, NetworkError, OPERATOR_NOT_APPROVED_REMEDIATION, OperatorNotApprovedError, PausedError, ReceiptEventAmbiguousError, ReceiptEventNotFoundError, ReentrancyError, RelayerUnreachableError, SigningFailedError, TokenOpsContractError, TokenOpsSdkError, TokenOpsValidationError, TransferFailedError, UnknownWriteFailureError, UnsupportedChainError, UserDecryptNotAllowedError, UserRejectedSignatureError, WalletChainMismatchError, WalletRejectedError, isTokenOpsSdkError } from './chunk-QBJ7O2B4.js';
|
|
4
4
|
import { sepolia, mainnet } from 'viem/chains';
|
|
@@ -1,62 +1,63 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
require('../chunk-
|
|
5
|
-
|
|
3
|
+
var chunkXAYGD4E4_cjs = require('../chunk-XAYGD4E4.cjs');
|
|
4
|
+
require('../chunk-UG5RKLU2.cjs');
|
|
5
|
+
require('../chunk-MVDQMV25.cjs');
|
|
6
|
+
var chunk5576FRT3_cjs = require('../chunk-5576FRT3.cjs');
|
|
6
7
|
require('../chunk-JK4XMMKM.cjs');
|
|
7
|
-
require('../chunk-VJKZWYYJ.cjs');
|
|
8
8
|
require('../chunk-66IHPTOK.cjs');
|
|
9
9
|
var chunk67OV5CX2_cjs = require('../chunk-67OV5CX2.cjs');
|
|
10
|
+
require('../chunk-VJKZWYYJ.cjs');
|
|
10
11
|
|
|
11
12
|
|
|
12
13
|
|
|
13
14
|
Object.defineProperty(exports, "FaucetSupplyExhaustedError", {
|
|
14
15
|
enumerable: true,
|
|
15
|
-
get: function () { return
|
|
16
|
+
get: function () { return chunkXAYGD4E4_cjs.FaucetSupplyExhaustedError; }
|
|
16
17
|
});
|
|
17
18
|
Object.defineProperty(exports, "TESTNET_FAUCET_SUPPORTED_CHAIN_IDS", {
|
|
18
19
|
enumerable: true,
|
|
19
|
-
get: function () { return
|
|
20
|
+
get: function () { return chunkXAYGD4E4_cjs.TESTNET_FAUCET_SUPPORTED_CHAIN_IDS; }
|
|
20
21
|
});
|
|
21
22
|
Object.defineProperty(exports, "TestnetFaucetClient", {
|
|
22
23
|
enumerable: true,
|
|
23
|
-
get: function () { return
|
|
24
|
+
get: function () { return chunkXAYGD4E4_cjs.TestnetFaucetClient; }
|
|
24
25
|
});
|
|
25
26
|
Object.defineProperty(exports, "assertTestnetFaucetChain", {
|
|
26
27
|
enumerable: true,
|
|
27
|
-
get: function () { return
|
|
28
|
+
get: function () { return chunkXAYGD4E4_cjs.assertTestnetFaucetChain; }
|
|
28
29
|
});
|
|
29
30
|
Object.defineProperty(exports, "confidentialTokenopsTestTokenAbi", {
|
|
30
31
|
enumerable: true,
|
|
31
|
-
get: function () { return
|
|
32
|
+
get: function () { return chunkXAYGD4E4_cjs.confidentialTokenopsTestTokenAbi; }
|
|
32
33
|
});
|
|
33
34
|
Object.defineProperty(exports, "createTestnetFaucetClient", {
|
|
34
35
|
enumerable: true,
|
|
35
|
-
get: function () { return
|
|
36
|
+
get: function () { return chunkXAYGD4E4_cjs.createTestnetFaucetClient; }
|
|
36
37
|
});
|
|
37
38
|
Object.defineProperty(exports, "isTestnetFaucetChainId", {
|
|
38
39
|
enumerable: true,
|
|
39
|
-
get: function () { return
|
|
40
|
+
get: function () { return chunkXAYGD4E4_cjs.isTestnetFaucetChainId; }
|
|
40
41
|
});
|
|
41
42
|
Object.defineProperty(exports, "tokenopsTestTokenAbi", {
|
|
42
43
|
enumerable: true,
|
|
43
|
-
get: function () { return
|
|
44
|
+
get: function () { return chunkXAYGD4E4_cjs.tokenopsTestTokenAbi; }
|
|
44
45
|
});
|
|
45
46
|
Object.defineProperty(exports, "getConfidentialTestTokenAddress", {
|
|
46
47
|
enumerable: true,
|
|
47
|
-
get: function () { return
|
|
48
|
+
get: function () { return chunk5576FRT3_cjs.getConfidentialTestTokenAddress; }
|
|
48
49
|
});
|
|
49
50
|
Object.defineProperty(exports, "getTestTokenAddress", {
|
|
50
51
|
enumerable: true,
|
|
51
|
-
get: function () { return
|
|
52
|
+
get: function () { return chunk5576FRT3_cjs.getTestTokenAddress; }
|
|
52
53
|
});
|
|
53
54
|
Object.defineProperty(exports, "requireConfidentialTestTokenAddress", {
|
|
54
55
|
enumerable: true,
|
|
55
|
-
get: function () { return
|
|
56
|
+
get: function () { return chunk5576FRT3_cjs.requireConfidentialTestTokenAddress; }
|
|
56
57
|
});
|
|
57
58
|
Object.defineProperty(exports, "requireTestTokenAddress", {
|
|
58
59
|
enumerable: true,
|
|
59
|
-
get: function () { return
|
|
60
|
+
get: function () { return chunk5576FRT3_cjs.requireTestTokenAddress; }
|
|
60
61
|
});
|
|
61
62
|
Object.defineProperty(exports, "AccessDeniedError", {
|
|
62
63
|
enumerable: true,
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
export { FaucetSupplyExhaustedError, TESTNET_FAUCET_SUPPORTED_CHAIN_IDS, TestnetFaucetClient, assertTestnetFaucetChain, confidentialTokenopsTestTokenAbi, createTestnetFaucetClient, isTestnetFaucetChainId, tokenopsTestTokenAbi } from '../chunk-
|
|
2
|
-
import '../chunk-
|
|
3
|
-
|
|
1
|
+
export { FaucetSupplyExhaustedError, TESTNET_FAUCET_SUPPORTED_CHAIN_IDS, TestnetFaucetClient, assertTestnetFaucetChain, confidentialTokenopsTestTokenAbi, createTestnetFaucetClient, isTestnetFaucetChainId, tokenopsTestTokenAbi } from '../chunk-74QFZ5MK.js';
|
|
2
|
+
import '../chunk-NWFMBLSQ.js';
|
|
3
|
+
import '../chunk-4RAAATVY.js';
|
|
4
|
+
export { getConfidentialTestTokenAddress, getTestTokenAddress, requireConfidentialTestTokenAddress, requireTestTokenAddress } from '../chunk-DZHYSUGY.js';
|
|
4
5
|
import '../chunk-ZA673I3O.js';
|
|
5
|
-
import '../chunk-Q2GP5UDC.js';
|
|
6
6
|
import '../chunk-KWFFIJYX.js';
|
|
7
7
|
export { AccessDeniedError, AlreadyInitializedError, BatchTooLargeError, ContractRevertError, DecryptionFailedError, DeploymentAddressUnavailableError, EncryptionFailedError, FeatureDisabledError, FheHandleNotAllowedError, InsufficientBalanceError, InsufficientFeeError, InsufficientGasFundsError, InvalidArgumentError, InvalidSignatureError, MissingAccountError, MissingClientError, MissingEncryptorError, MissingPublicClientError, MissingWalletClientError, NetworkError, OperatorNotApprovedError, PausedError, ReceiptEventAmbiguousError, ReceiptEventNotFoundError, ReentrancyError, RelayerUnreachableError, SigningFailedError, TokenOpsContractError, TokenOpsSdkError, TokenOpsValidationError, TransferFailedError, UnknownWriteFailureError, UnsupportedChainError, UserDecryptNotAllowedError, UserRejectedSignatureError, WalletChainMismatchError, WalletRejectedError, isTokenOpsSdkError } from '../chunk-QBJ7O2B4.js';
|
|
8
|
+
import '../chunk-Q2GP5UDC.js';
|