@tokenops/sdk 2.0.0-alpha.2 → 2.0.0-alpha.3
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 +39 -3
- package/README.md +11 -5
- package/dist/{chunk-PZZK3O3S.cjs → chunk-4AWQJQXY.cjs} +391 -43
- package/dist/{chunk-SPLNGUFF.js → chunk-4IB4IY5Y.js} +1 -1
- package/dist/{chunk-A4DCEE33.js → chunk-6HCT4QIX.js} +11 -10
- package/dist/{chunk-MM5BV5CS.cjs → chunk-6XOAYDC6.cjs} +4 -4
- package/dist/{chunk-FEDX7B6T.cjs → chunk-AHU2HMNE.cjs} +3 -3
- package/dist/{chunk-IGO5XSPS.js → chunk-BPIVVCSQ.js} +2 -2
- package/dist/{chunk-X7WBPCEU.js → chunk-BXX5TETM.js} +375 -27
- package/dist/{chunk-GADGBQJO.js → chunk-GCJFAY4X.js} +2 -2
- package/dist/{chunk-IUKKNJ2R.cjs → chunk-GKYZQJGP.cjs} +7 -7
- package/dist/{chunk-3YHBO2DL.cjs → chunk-IEKTGJ4J.cjs} +2 -2
- package/dist/{chunk-UHHMVBLU.cjs → chunk-JVNJSDQ4.cjs} +2 -2
- package/dist/{chunk-VW356KR3.js → chunk-LEYYG4RF.js} +126 -3
- package/dist/{chunk-PYYSB5ZN.js → chunk-NGU4JYIR.js} +1 -1
- package/dist/{chunk-FT5H2Q7Y.cjs → chunk-PG3WXT3K.cjs} +11 -10
- package/dist/{chunk-44YJPMQC.js → chunk-PK6Q6J5F.js} +1 -1
- package/dist/{chunk-EBLBPUPI.cjs → chunk-TND5NDV7.cjs} +18 -10
- package/dist/{chunk-EYDA6Q6C.js → chunk-U3TBQRT7.js} +10 -2
- package/dist/{chunk-WJMEBBU7.js → chunk-WRWRA4TN.js} +1 -1
- package/dist/{chunk-FHWSBGWE.cjs → chunk-YABHXJNH.cjs} +5 -5
- package/dist/{chunk-AREQJHKA.cjs → chunk-YTIYTV4K.cjs} +129 -2
- package/dist/core/addresses.d.ts +4 -4
- package/dist/core/errors.d.ts +1 -1
- package/dist/fhe-airdrop/abis/airdrop-base.d.ts +19 -0
- package/dist/fhe-airdrop/abis/ecdsa.d.ts +19 -0
- package/dist/fhe-airdrop/abis/factory.d.ts +113 -0
- package/dist/fhe-airdrop/abis/merkle.d.ts +19 -0
- package/dist/fhe-airdrop/advanced/index.cjs +4 -4
- package/dist/fhe-airdrop/advanced/index.js +1 -1
- package/dist/fhe-airdrop/advanced/react/index.cjs +110 -80
- package/dist/fhe-airdrop/advanced/react/index.d.cts +1 -0
- package/dist/fhe-airdrop/advanced/react/index.d.ts +1 -0
- package/dist/fhe-airdrop/advanced/react/index.js +34 -5
- package/dist/fhe-airdrop/advanced/react/useDisableCustomFee.d.ts +2 -1
- package/dist/fhe-airdrop/advanced/react/useFactoryRenounceRole.d.ts +4 -3
- package/dist/fhe-airdrop/advanced/react/useFactoryRevokeRole.d.ts +9 -7
- package/dist/fhe-airdrop/advanced/react/useFactoryRoleMembers.d.ts +6 -5
- package/dist/fhe-airdrop/advanced/react/useSetCustomFee.d.ts +2 -1
- package/dist/fhe-airdrop/advanced/react/useSetDefaultGasFee.d.ts +5 -3
- package/dist/fhe-airdrop/advanced/react/useSetMaxGasFee.d.ts +33 -0
- package/dist/fhe-airdrop/airdrop-base.d.ts +47 -8
- package/dist/fhe-airdrop/constants.d.ts +9 -1
- package/dist/fhe-airdrop/ecdsa.d.ts +13 -0
- package/dist/fhe-airdrop/errors.d.ts +59 -0
- package/dist/fhe-airdrop/factory.d.ts +62 -22
- package/dist/fhe-airdrop/guards.d.ts +87 -2
- package/dist/fhe-airdrop/index.cjs +67 -55
- package/dist/fhe-airdrop/index.d.cts +3 -3
- package/dist/fhe-airdrop/index.d.ts +3 -3
- package/dist/fhe-airdrop/index.js +4 -4
- package/dist/fhe-airdrop/react/index.cjs +237 -177
- package/dist/fhe-airdrop/react/index.d.cts +4 -1
- package/dist/fhe-airdrop/react/index.d.ts +4 -1
- package/dist/fhe-airdrop/react/index.js +72 -15
- package/dist/fhe-airdrop/react/keys.d.ts +8 -0
- package/dist/fhe-airdrop/react/useFactoryFees.d.ts +11 -4
- package/dist/fhe-airdrop/react/useIsAirdrop.d.ts +44 -0
- package/dist/fhe-airdrop/react/useRefreshComplianceBalance.d.ts +36 -0
- package/dist/fhe-airdrop/react/useResolveGasFee.d.ts +30 -0
- package/dist/fhe-airdrop/types.d.ts +13 -0
- package/dist/fhe-disperse/index.cjs +21 -21
- package/dist/fhe-disperse/index.js +2 -2
- package/dist/fhe-disperse/react/index.cjs +22 -22
- package/dist/fhe-disperse/react/index.js +3 -3
- package/dist/fhe-vesting/advanced/index.cjs +5 -5
- package/dist/fhe-vesting/advanced/index.js +3 -3
- package/dist/fhe-vesting/advanced/react/index.cjs +7 -7
- package/dist/fhe-vesting/advanced/react/index.js +4 -4
- package/dist/fhe-vesting/index.cjs +8 -8
- package/dist/fhe-vesting/index.js +2 -2
- package/dist/fhe-vesting/react/index.cjs +114 -114
- package/dist/fhe-vesting/react/index.js +3 -3
- package/dist/index.cjs +18 -18
- package/dist/index.js +1 -1
- package/dist/testnet-faucet/index.cjs +14 -14
- package/dist/testnet-faucet/index.js +2 -2
- package/dist/testnet-faucet/react/index.cjs +8 -8
- package/dist/testnet-faucet/react/index.js +3 -3
- package/package.json +1 -1
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
export { useEnsureOperator, useIsOperator } from '../../chunk-AXIPOR3C.js';
|
|
2
2
|
import '../../chunk-FT4LNBOS.js';
|
|
3
3
|
import '../../chunk-4TSDNZQ3.js';
|
|
4
|
-
import { useMemoFactoryClient, buildQueryKey, useMemoManagerClient } from '../../chunk-
|
|
4
|
+
import { useMemoFactoryClient, buildQueryKey, useMemoManagerClient } from '../../chunk-BPIVVCSQ.js';
|
|
5
5
|
export { ClaimLockedError, NoPendingTransferError, NotPendingRecipientError, NotVestingRecipientError, TransferAlreadyPendingError, TransferExpiredError, VestingExpiredError, VestingNotFoundError, VestingNotRevocableError, VestingRevokedError } from '../../chunk-TWT3STIX.js';
|
|
6
6
|
import '../../chunk-WMACINXO.js';
|
|
7
7
|
export { encryptUint64, encryptUint64Batch, resolveEncryptor, scaleRatio } from '../../chunk-6GNR22OV.js';
|
|
8
8
|
import '../../chunk-ZWXJTBZO.js';
|
|
9
9
|
import '../../chunk-7VELUOMI.js';
|
|
10
|
-
export { DisclosureType, FeeType } from '../../chunk-
|
|
10
|
+
export { DisclosureType, FeeType } from '../../chunk-WRWRA4TN.js';
|
|
11
11
|
import '../../chunk-NWFMBLSQ.js';
|
|
12
12
|
import '../../chunk-4RAAATVY.js';
|
|
13
|
-
import '../../chunk-
|
|
13
|
+
import '../../chunk-6HCT4QIX.js';
|
|
14
14
|
import '../../chunk-ZA673I3O.js';
|
|
15
15
|
import '../../chunk-KWFFIJYX.js';
|
|
16
16
|
import { MissingClientError } from '../../chunk-QBJ7O2B4.js';
|
package/dist/index.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunkPG3WXT3K_cjs = require('./chunk-PG3WXT3K.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,71 +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 chunkPG3WXT3K_cjs.DEPLOYED_ADDRESSES; }
|
|
19
19
|
});
|
|
20
20
|
Object.defineProperty(exports, "chainsWithDeployment", {
|
|
21
21
|
enumerable: true,
|
|
22
|
-
get: function () { return
|
|
22
|
+
get: function () { return chunkPG3WXT3K_cjs.chainsWithDeployment; }
|
|
23
23
|
});
|
|
24
24
|
Object.defineProperty(exports, "chainsWithKnownRegistryEntry", {
|
|
25
25
|
enumerable: true,
|
|
26
|
-
get: function () { return
|
|
26
|
+
get: function () { return chunkPG3WXT3K_cjs.chainsWithKnownRegistryEntry; }
|
|
27
27
|
});
|
|
28
28
|
Object.defineProperty(exports, "getConfidentialTestTokenAddress", {
|
|
29
29
|
enumerable: true,
|
|
30
|
-
get: function () { return
|
|
30
|
+
get: function () { return chunkPG3WXT3K_cjs.getConfidentialTestTokenAddress; }
|
|
31
31
|
});
|
|
32
32
|
Object.defineProperty(exports, "getDeployedAddress", {
|
|
33
33
|
enumerable: true,
|
|
34
|
-
get: function () { return
|
|
34
|
+
get: function () { return chunkPG3WXT3K_cjs.getDeployedAddress; }
|
|
35
35
|
});
|
|
36
36
|
Object.defineProperty(exports, "getFheAirdropComplianceImplementationAddress", {
|
|
37
37
|
enumerable: true,
|
|
38
|
-
get: function () { return
|
|
38
|
+
get: function () { return chunkPG3WXT3K_cjs.getFheAirdropComplianceImplementationAddress; }
|
|
39
39
|
});
|
|
40
40
|
Object.defineProperty(exports, "getFheAirdropEcdsaImplementationAddress", {
|
|
41
41
|
enumerable: true,
|
|
42
|
-
get: function () { return
|
|
42
|
+
get: function () { return chunkPG3WXT3K_cjs.getFheAirdropEcdsaImplementationAddress; }
|
|
43
43
|
});
|
|
44
44
|
Object.defineProperty(exports, "getFheAirdropFactoryAddress", {
|
|
45
45
|
enumerable: true,
|
|
46
|
-
get: function () { return
|
|
46
|
+
get: function () { return chunkPG3WXT3K_cjs.getFheAirdropFactoryAddress; }
|
|
47
47
|
});
|
|
48
48
|
Object.defineProperty(exports, "getFheAirdropMerkleImplementationAddress", {
|
|
49
49
|
enumerable: true,
|
|
50
|
-
get: function () { return
|
|
50
|
+
get: function () { return chunkPG3WXT3K_cjs.getFheAirdropMerkleImplementationAddress; }
|
|
51
51
|
});
|
|
52
52
|
Object.defineProperty(exports, "getFheDisperseSingletonAddress", {
|
|
53
53
|
enumerable: true,
|
|
54
|
-
get: function () { return
|
|
54
|
+
get: function () { return chunkPG3WXT3K_cjs.getFheDisperseSingletonAddress; }
|
|
55
55
|
});
|
|
56
56
|
Object.defineProperty(exports, "getFheVestingFactoryAddress", {
|
|
57
57
|
enumerable: true,
|
|
58
|
-
get: function () { return
|
|
58
|
+
get: function () { return chunkPG3WXT3K_cjs.getFheVestingFactoryAddress; }
|
|
59
59
|
});
|
|
60
60
|
Object.defineProperty(exports, "getTestTokenAddress", {
|
|
61
61
|
enumerable: true,
|
|
62
|
-
get: function () { return
|
|
62
|
+
get: function () { return chunkPG3WXT3K_cjs.getTestTokenAddress; }
|
|
63
63
|
});
|
|
64
64
|
Object.defineProperty(exports, "requireConfidentialTestTokenAddress", {
|
|
65
65
|
enumerable: true,
|
|
66
|
-
get: function () { return
|
|
66
|
+
get: function () { return chunkPG3WXT3K_cjs.requireConfidentialTestTokenAddress; }
|
|
67
67
|
});
|
|
68
68
|
Object.defineProperty(exports, "requireFheAirdropFactoryAddress", {
|
|
69
69
|
enumerable: true,
|
|
70
|
-
get: function () { return
|
|
70
|
+
get: function () { return chunkPG3WXT3K_cjs.requireFheAirdropFactoryAddress; }
|
|
71
71
|
});
|
|
72
72
|
Object.defineProperty(exports, "requireFheDisperseSingletonAddress", {
|
|
73
73
|
enumerable: true,
|
|
74
|
-
get: function () { return
|
|
74
|
+
get: function () { return chunkPG3WXT3K_cjs.requireFheDisperseSingletonAddress; }
|
|
75
75
|
});
|
|
76
76
|
Object.defineProperty(exports, "requireFheVestingFactoryAddress", {
|
|
77
77
|
enumerable: true,
|
|
78
|
-
get: function () { return
|
|
78
|
+
get: function () { return chunkPG3WXT3K_cjs.requireFheVestingFactoryAddress; }
|
|
79
79
|
});
|
|
80
80
|
Object.defineProperty(exports, "requireTestTokenAddress", {
|
|
81
81
|
enumerable: true,
|
|
82
|
-
get: function () { return
|
|
82
|
+
get: function () { return chunkPG3WXT3K_cjs.requireTestTokenAddress; }
|
|
83
83
|
});
|
|
84
84
|
Object.defineProperty(exports, "asAirdropId", {
|
|
85
85
|
enumerable: true,
|
package/dist/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { DEPLOYED_ADDRESSES, chainsWithDeployment, chainsWithKnownRegistryEntry, getConfidentialTestTokenAddress, getDeployedAddress, getFheAirdropComplianceImplementationAddress, getFheAirdropEcdsaImplementationAddress, getFheAirdropFactoryAddress, getFheAirdropMerkleImplementationAddress, 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-6HCT4QIX.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,9 +1,9 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunkAHU2HMNE_cjs = require('../chunk-AHU2HMNE.cjs');
|
|
4
4
|
require('../chunk-UG5RKLU2.cjs');
|
|
5
5
|
require('../chunk-MVDQMV25.cjs');
|
|
6
|
-
var
|
|
6
|
+
var chunkPG3WXT3K_cjs = require('../chunk-PG3WXT3K.cjs');
|
|
7
7
|
require('../chunk-JK4XMMKM.cjs');
|
|
8
8
|
require('../chunk-66IHPTOK.cjs');
|
|
9
9
|
var chunk67OV5CX2_cjs = require('../chunk-67OV5CX2.cjs');
|
|
@@ -13,51 +13,51 @@ require('../chunk-VJKZWYYJ.cjs');
|
|
|
13
13
|
|
|
14
14
|
Object.defineProperty(exports, "FaucetSupplyExhaustedError", {
|
|
15
15
|
enumerable: true,
|
|
16
|
-
get: function () { return
|
|
16
|
+
get: function () { return chunkAHU2HMNE_cjs.FaucetSupplyExhaustedError; }
|
|
17
17
|
});
|
|
18
18
|
Object.defineProperty(exports, "TESTNET_FAUCET_SUPPORTED_CHAIN_IDS", {
|
|
19
19
|
enumerable: true,
|
|
20
|
-
get: function () { return
|
|
20
|
+
get: function () { return chunkAHU2HMNE_cjs.TESTNET_FAUCET_SUPPORTED_CHAIN_IDS; }
|
|
21
21
|
});
|
|
22
22
|
Object.defineProperty(exports, "TestnetFaucetClient", {
|
|
23
23
|
enumerable: true,
|
|
24
|
-
get: function () { return
|
|
24
|
+
get: function () { return chunkAHU2HMNE_cjs.TestnetFaucetClient; }
|
|
25
25
|
});
|
|
26
26
|
Object.defineProperty(exports, "assertTestnetFaucetChain", {
|
|
27
27
|
enumerable: true,
|
|
28
|
-
get: function () { return
|
|
28
|
+
get: function () { return chunkAHU2HMNE_cjs.assertTestnetFaucetChain; }
|
|
29
29
|
});
|
|
30
30
|
Object.defineProperty(exports, "confidentialTokenopsTestTokenAbi", {
|
|
31
31
|
enumerable: true,
|
|
32
|
-
get: function () { return
|
|
32
|
+
get: function () { return chunkAHU2HMNE_cjs.confidentialTokenopsTestTokenAbi; }
|
|
33
33
|
});
|
|
34
34
|
Object.defineProperty(exports, "createTestnetFaucetClient", {
|
|
35
35
|
enumerable: true,
|
|
36
|
-
get: function () { return
|
|
36
|
+
get: function () { return chunkAHU2HMNE_cjs.createTestnetFaucetClient; }
|
|
37
37
|
});
|
|
38
38
|
Object.defineProperty(exports, "isTestnetFaucetChainId", {
|
|
39
39
|
enumerable: true,
|
|
40
|
-
get: function () { return
|
|
40
|
+
get: function () { return chunkAHU2HMNE_cjs.isTestnetFaucetChainId; }
|
|
41
41
|
});
|
|
42
42
|
Object.defineProperty(exports, "tokenopsTestTokenAbi", {
|
|
43
43
|
enumerable: true,
|
|
44
|
-
get: function () { return
|
|
44
|
+
get: function () { return chunkAHU2HMNE_cjs.tokenopsTestTokenAbi; }
|
|
45
45
|
});
|
|
46
46
|
Object.defineProperty(exports, "getConfidentialTestTokenAddress", {
|
|
47
47
|
enumerable: true,
|
|
48
|
-
get: function () { return
|
|
48
|
+
get: function () { return chunkPG3WXT3K_cjs.getConfidentialTestTokenAddress; }
|
|
49
49
|
});
|
|
50
50
|
Object.defineProperty(exports, "getTestTokenAddress", {
|
|
51
51
|
enumerable: true,
|
|
52
|
-
get: function () { return
|
|
52
|
+
get: function () { return chunkPG3WXT3K_cjs.getTestTokenAddress; }
|
|
53
53
|
});
|
|
54
54
|
Object.defineProperty(exports, "requireConfidentialTestTokenAddress", {
|
|
55
55
|
enumerable: true,
|
|
56
|
-
get: function () { return
|
|
56
|
+
get: function () { return chunkPG3WXT3K_cjs.requireConfidentialTestTokenAddress; }
|
|
57
57
|
});
|
|
58
58
|
Object.defineProperty(exports, "requireTestTokenAddress", {
|
|
59
59
|
enumerable: true,
|
|
60
|
-
get: function () { return
|
|
60
|
+
get: function () { return chunkPG3WXT3K_cjs.requireTestTokenAddress; }
|
|
61
61
|
});
|
|
62
62
|
Object.defineProperty(exports, "AccessDeniedError", {
|
|
63
63
|
enumerable: true,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export { FaucetSupplyExhaustedError, TESTNET_FAUCET_SUPPORTED_CHAIN_IDS, TestnetFaucetClient, assertTestnetFaucetChain, confidentialTokenopsTestTokenAbi, createTestnetFaucetClient, isTestnetFaucetChainId, tokenopsTestTokenAbi } from '../chunk-
|
|
1
|
+
export { FaucetSupplyExhaustedError, TESTNET_FAUCET_SUPPORTED_CHAIN_IDS, TestnetFaucetClient, assertTestnetFaucetChain, confidentialTokenopsTestTokenAbi, createTestnetFaucetClient, isTestnetFaucetChainId, tokenopsTestTokenAbi } from '../chunk-4IB4IY5Y.js';
|
|
2
2
|
import '../chunk-NWFMBLSQ.js';
|
|
3
3
|
import '../chunk-4RAAATVY.js';
|
|
4
|
-
export { getConfidentialTestTokenAddress, getTestTokenAddress, requireConfidentialTestTokenAddress, requireTestTokenAddress } from '../chunk-
|
|
4
|
+
export { getConfidentialTestTokenAddress, getTestTokenAddress, requireConfidentialTestTokenAddress, requireTestTokenAddress } from '../chunk-6HCT4QIX.js';
|
|
5
5
|
import '../chunk-ZA673I3O.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';
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunkAHU2HMNE_cjs = require('../../chunk-AHU2HMNE.cjs');
|
|
4
4
|
var chunkZQUE2B3Q_cjs = require('../../chunk-ZQUE2B3Q.cjs');
|
|
5
5
|
require('../../chunk-UG5RKLU2.cjs');
|
|
6
6
|
require('../../chunk-MVDQMV25.cjs');
|
|
7
|
-
var
|
|
7
|
+
var chunkPG3WXT3K_cjs = require('../../chunk-PG3WXT3K.cjs');
|
|
8
8
|
require('../../chunk-JK4XMMKM.cjs');
|
|
9
9
|
require('../../chunk-66IHPTOK.cjs');
|
|
10
10
|
var chunk67OV5CX2_cjs = require('../../chunk-67OV5CX2.cjs');
|
|
@@ -16,10 +16,10 @@ var wagmi = require('wagmi');
|
|
|
16
16
|
var TESTNET_FAUCET_KEY = "tokenops-sdk";
|
|
17
17
|
var TESTNET_FAUCET_NAMESPACE = "testnet-faucet";
|
|
18
18
|
function tryResolveSingletonAddress(override, chainId) {
|
|
19
|
-
if (chainId !== void 0 && !
|
|
19
|
+
if (chainId !== void 0 && !chunkAHU2HMNE_cjs.isTestnetFaucetChainId(chainId)) return void 0;
|
|
20
20
|
if (override) return override;
|
|
21
21
|
if (chainId === void 0) return void 0;
|
|
22
|
-
return
|
|
22
|
+
return chunkPG3WXT3K_cjs.getConfidentialTestTokenAddress(chainId);
|
|
23
23
|
}
|
|
24
24
|
function useMemoFaucetClient(opts = {}) {
|
|
25
25
|
const publicClient = wagmi.usePublicClient({ chainId: opts.chainId });
|
|
@@ -30,7 +30,7 @@ function useMemoFaucetClient(opts = {}) {
|
|
|
30
30
|
const client = react.useMemo(() => {
|
|
31
31
|
if (!publicClient) return void 0;
|
|
32
32
|
if (!resolvedAddress) return void 0;
|
|
33
|
-
return
|
|
33
|
+
return chunkAHU2HMNE_cjs.createTestnetFaucetClient({
|
|
34
34
|
publicClient,
|
|
35
35
|
...walletClient ? { walletClient } : {},
|
|
36
36
|
...opts.address ? { address: resolvedAddress } : {},
|
|
@@ -47,7 +47,7 @@ function useMemoFaucetClient(opts = {}) {
|
|
|
47
47
|
};
|
|
48
48
|
}
|
|
49
49
|
function computeSingletonResolutionError(override, chainId) {
|
|
50
|
-
if (chainId !== void 0 && !
|
|
50
|
+
if (chainId !== void 0 && !chunkAHU2HMNE_cjs.isTestnetFaucetChainId(chainId)) {
|
|
51
51
|
return new chunk67OV5CX2_cjs.UnsupportedChainError(chainId);
|
|
52
52
|
}
|
|
53
53
|
if (override) return void 0;
|
|
@@ -59,7 +59,7 @@ function computeSingletonResolutionError(override, chainId) {
|
|
|
59
59
|
clientLabel: "TestnetFaucetClient"
|
|
60
60
|
});
|
|
61
61
|
}
|
|
62
|
-
const resolved =
|
|
62
|
+
const resolved = chunkPG3WXT3K_cjs.getConfidentialTestTokenAddress(chainId);
|
|
63
63
|
if (!resolved) {
|
|
64
64
|
return new chunk67OV5CX2_cjs.DeploymentAddressUnavailableError({
|
|
65
65
|
reason: "registry-not-deployed",
|
|
@@ -220,7 +220,7 @@ function useMintUnderlying(options = {}) {
|
|
|
220
220
|
|
|
221
221
|
Object.defineProperty(exports, "FaucetSupplyExhaustedError", {
|
|
222
222
|
enumerable: true,
|
|
223
|
-
get: function () { return
|
|
223
|
+
get: function () { return chunkAHU2HMNE_cjs.FaucetSupplyExhaustedError; }
|
|
224
224
|
});
|
|
225
225
|
Object.defineProperty(exports, "AccessDeniedError", {
|
|
226
226
|
enumerable: true,
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { createTestnetFaucetClient, isTestnetFaucetChainId } from '../../chunk-
|
|
2
|
-
export { FaucetSupplyExhaustedError } from '../../chunk-
|
|
1
|
+
import { createTestnetFaucetClient, isTestnetFaucetChainId } from '../../chunk-4IB4IY5Y.js';
|
|
2
|
+
export { FaucetSupplyExhaustedError } from '../../chunk-4IB4IY5Y.js';
|
|
3
3
|
import { useWagmiAccount } from '../../chunk-FT4LNBOS.js';
|
|
4
4
|
import '../../chunk-NWFMBLSQ.js';
|
|
5
5
|
import '../../chunk-4RAAATVY.js';
|
|
6
|
-
import { getConfidentialTestTokenAddress } from '../../chunk-
|
|
6
|
+
import { getConfidentialTestTokenAddress } from '../../chunk-6HCT4QIX.js';
|
|
7
7
|
import '../../chunk-ZA673I3O.js';
|
|
8
8
|
import '../../chunk-KWFFIJYX.js';
|
|
9
9
|
import { MissingClientError, UnsupportedChainError, DeploymentAddressUnavailableError } from '../../chunk-QBJ7O2B4.js';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tokenops/sdk",
|
|
3
|
-
"version": "2.0.0-alpha.
|
|
3
|
+
"version": "2.0.0-alpha.3",
|
|
4
4
|
"description": "Typed viem-first SDK for TokenOps FHEVM contracts (confidential vesting, confidential airdrops, confidential disperse, plus a testnet faucet for the ERC-7984 test-token pair TTT + CTTT) — consumed by tokenops-app (Next.js) and tokenops-api (Express).",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"sideEffects": false,
|