@tokenops/sdk 2.0.0-alpha.3 → 2.0.0-alpha.4

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.
Files changed (151) hide show
  1. package/CHANGELOG.md +53 -0
  2. package/README.md +71 -35
  3. package/SUPPORT.md +1 -1
  4. package/dist/{chunk-NGU4JYIR.js → chunk-2ND7US2I.js} +1 -1
  5. package/dist/{chunk-U3TBQRT7.js → chunk-3ZSPRHR3.js} +55 -12
  6. package/dist/{chunk-BXX5TETM.js → chunk-67Q6KSVV.js} +4114 -3267
  7. package/dist/{chunk-JVNJSDQ4.cjs → chunk-6AYJRUGP.cjs} +7 -50
  8. package/dist/{chunk-AHU2HMNE.cjs → chunk-6FUHF73F.cjs} +5 -5
  9. package/dist/{chunk-NWFMBLSQ.js → chunk-7KY4K4PH.js} +1 -1
  10. package/dist/{chunk-YABHXJNH.cjs → chunk-ARZ5C3FS.cjs} +7 -7
  11. package/dist/{chunk-4IB4IY5Y.js → chunk-AX6MQAWU.js} +2 -2
  12. package/dist/{chunk-BPIVVCSQ.js → chunk-BSXEX2SH.js} +3 -3
  13. package/dist/{chunk-PK6Q6J5F.js → chunk-CHGY6B7L.js} +34 -81
  14. package/dist/{chunk-GKYZQJGP.cjs → chunk-DFK5GCJP.cjs} +55 -72
  15. package/dist/{chunk-4AWQJQXY.cjs → chunk-E4IV4M4E.cjs} +4126 -3279
  16. package/dist/{chunk-6HCT4QIX.js → chunk-GHGF65LN.js} +16 -13
  17. package/dist/{chunk-TWT3STIX.js → chunk-K3R27WX4.js} +8 -46
  18. package/dist/{chunk-GCJFAY4X.js → chunk-KJUNBOJQ.js} +52 -71
  19. package/dist/{chunk-6XOAYDC6.cjs → chunk-PO3A2AQX.cjs} +4 -4
  20. package/dist/{chunk-TND5NDV7.cjs → chunk-QHDMPT7I.cjs} +64 -19
  21. package/dist/{chunk-IEKTGJ4J.cjs → chunk-S47IBDTA.cjs} +36 -83
  22. package/dist/{chunk-UG5RKLU2.cjs → chunk-SUYBAF27.cjs} +1 -1
  23. package/dist/{chunk-WRWRA4TN.js → chunk-TWU7L5H7.js} +5 -48
  24. package/dist/{chunk-WJLECC22.cjs → chunk-UUSSWOPR.cjs} +9 -47
  25. package/dist/{chunk-YTIYTV4K.cjs → chunk-VHKMWWBA.cjs} +319 -40
  26. package/dist/{chunk-PG3WXT3K.cjs → chunk-YAL6JSAZ.cjs} +16 -13
  27. package/dist/{chunk-LEYYG4RF.js → chunk-YMWMIWBP.js} +315 -42
  28. package/dist/core/addresses.d.ts +4 -4
  29. package/dist/core/errors.d.ts +1 -1
  30. package/dist/core/index.d.ts +1 -0
  31. package/dist/core/pending.d.ts +57 -0
  32. package/dist/core/version.d.ts +1 -1
  33. package/dist/fhe/operators.d.ts +6 -5
  34. package/dist/fhe/types.d.ts +1 -1
  35. package/dist/fhe-airdrop/abis/airdrop-base.d.ts +81 -4
  36. package/dist/fhe-airdrop/abis/ecdsa.d.ts +101 -4
  37. package/dist/fhe-airdrop/abis/factory.d.ts +222 -4
  38. package/dist/fhe-airdrop/abis/merkle.d.ts +100 -4
  39. package/dist/fhe-airdrop/advanced/index.cjs +8 -4
  40. package/dist/fhe-airdrop/advanced/index.d.cts +1 -0
  41. package/dist/fhe-airdrop/advanced/index.d.ts +1 -0
  42. package/dist/fhe-airdrop/advanced/index.js +1 -1
  43. package/dist/fhe-airdrop/advanced/react/index.cjs +121 -143
  44. package/dist/fhe-airdrop/advanced/react/index.js +55 -77
  45. package/dist/fhe-airdrop/advanced/react/useClearCompliancePolicy.d.ts +3 -1
  46. package/dist/fhe-airdrop/advanced/react/useDisableCustomFee.d.ts +3 -1
  47. package/dist/fhe-airdrop/advanced/react/useFactoryComplianceDelegate.d.ts +2 -4
  48. package/dist/fhe-airdrop/advanced/react/useSetComplianceDelegate.d.ts +7 -7
  49. package/dist/fhe-airdrop/advanced/react/useSetComplianceManagerImpl.d.ts +3 -1
  50. package/dist/fhe-airdrop/advanced/react/useSetCompliancePolicy.d.ts +2 -1
  51. package/dist/fhe-airdrop/advanced/react/useSetCustomFee.d.ts +3 -1
  52. package/dist/fhe-airdrop/advanced/react/useSetDefaultDelegateToCompliance.d.ts +5 -4
  53. package/dist/fhe-airdrop/advanced/react/useSetDefaultGasFee.d.ts +3 -1
  54. package/dist/fhe-airdrop/advanced/react/useSetMaxGasFee.d.ts +7 -3
  55. package/dist/fhe-airdrop/airdrop-base.d.ts +95 -10
  56. package/dist/fhe-airdrop/campaign.d.ts +37 -73
  57. package/dist/fhe-airdrop/compliance-clone.d.ts +21 -0
  58. package/dist/fhe-airdrop/constants.d.ts +3 -1
  59. package/dist/fhe-airdrop/ecdsa.d.ts +67 -27
  60. package/dist/fhe-airdrop/encryption.d.ts +19 -6
  61. package/dist/fhe-airdrop/errors.d.ts +77 -2
  62. package/dist/fhe-airdrop/factory-params.d.ts +2361 -0
  63. package/dist/fhe-airdrop/factory.d.ts +142 -68
  64. package/dist/fhe-airdrop/guards.d.ts +110 -31
  65. package/dist/fhe-airdrop/index.cjs +79 -59
  66. package/dist/fhe-airdrop/index.d.cts +11 -9
  67. package/dist/fhe-airdrop/index.d.ts +11 -9
  68. package/dist/fhe-airdrop/index.js +5 -5
  69. package/dist/fhe-airdrop/merkle-tree.d.ts +9 -9
  70. package/dist/fhe-airdrop/merkle.d.ts +32 -11
  71. package/dist/fhe-airdrop/react/_shared.d.ts +12 -6
  72. package/dist/fhe-airdrop/react/index.cjs +294 -258
  73. package/dist/fhe-airdrop/react/index.d.cts +16 -9
  74. package/dist/fhe-airdrop/react/index.d.ts +16 -9
  75. package/dist/fhe-airdrop/react/index.js +114 -110
  76. package/dist/fhe-airdrop/react/keys.d.ts +46 -7
  77. package/dist/fhe-airdrop/react/useAccessEcdsaClaimAmount.d.ts +6 -3
  78. package/dist/fhe-airdrop/react/useAccessMerkleClaimAmount.d.ts +2 -2
  79. package/dist/fhe-airdrop/react/useAirdropConfig.d.ts +8 -3
  80. package/dist/fhe-airdrop/react/useAirdropPause.d.ts +5 -0
  81. package/dist/fhe-airdrop/react/useBuildMerkleCampaign.d.ts +4 -6
  82. package/dist/fhe-airdrop/react/useComplianceManager.d.ts +2 -2
  83. package/dist/fhe-airdrop/react/useComplianceManagerOf.d.ts +1 -2
  84. package/dist/fhe-airdrop/react/useCreateAndFundEcdsaAirdrop.d.ts +16 -11
  85. package/dist/fhe-airdrop/react/useCreateAndFundMerkleAirdrop.d.ts +23 -7
  86. package/dist/fhe-airdrop/react/useCreateEcdsaAirdrop.d.ts +13 -8
  87. package/dist/fhe-airdrop/react/useCreateMerkleAirdrop.d.ts +27 -7
  88. package/dist/fhe-airdrop/react/useDedupMode.d.ts +16 -0
  89. package/dist/fhe-airdrop/react/useDiscloseHandleToParty.d.ts +4 -3
  90. package/dist/fhe-airdrop/react/useEcdsaClaim.d.ts +6 -4
  91. package/dist/fhe-airdrop/react/useEcdsaClaimAndUnwrap.d.ts +15 -8
  92. package/dist/fhe-airdrop/react/useEcdsaDomain.d.ts +1 -1
  93. package/dist/fhe-airdrop/react/useEncryptCampaignAmounts.d.ts +5 -7
  94. package/dist/fhe-airdrop/react/useExtendClaimWindow.d.ts +4 -1
  95. package/dist/fhe-airdrop/react/useFundAirdrop.d.ts +3 -4
  96. package/dist/fhe-airdrop/react/useGrantInstanceRoles.d.ts +2 -1
  97. package/dist/fhe-airdrop/react/useIsSignatureValid.d.ts +5 -4
  98. package/dist/fhe-airdrop/react/useMerkleClaim.d.ts +4 -1
  99. package/dist/fhe-airdrop/react/useMerkleClaimAndUnwrap.d.ts +14 -3
  100. package/dist/fhe-airdrop/react/usePlanMerkleCampaign.d.ts +18 -3
  101. package/dist/fhe-airdrop/react/usePreflightClaim.d.ts +1 -1
  102. package/dist/fhe-airdrop/react/usePreflightCreateAirdrop.d.ts +34 -13
  103. package/dist/fhe-airdrop/react/useRescueERC20.d.ts +3 -3
  104. package/dist/fhe-airdrop/react/useRescueNativeToken.d.ts +23 -0
  105. package/dist/fhe-airdrop/react/useRotateMerkleRoot.d.ts +5 -2
  106. package/dist/fhe-airdrop/react/useSignClaimAuthorization.d.ts +4 -0
  107. package/dist/fhe-airdrop/react/useTokenOf.d.ts +29 -0
  108. package/dist/fhe-airdrop/react/useUnwrapRequest.d.ts +25 -0
  109. package/dist/fhe-airdrop/react/useWithdrawConfidential.d.ts +4 -0
  110. package/dist/fhe-airdrop/roles.d.ts +82 -7
  111. package/dist/fhe-airdrop/types.d.ts +109 -14
  112. package/dist/fhe-disperse/errors.d.ts +3 -3
  113. package/dist/fhe-disperse/index.cjs +22 -22
  114. package/dist/fhe-disperse/index.d.cts +2 -1
  115. package/dist/fhe-disperse/index.d.ts +2 -1
  116. package/dist/fhe-disperse/index.js +3 -3
  117. package/dist/fhe-disperse/react/index.cjs +27 -25
  118. package/dist/fhe-disperse/react/index.d.cts +2 -1
  119. package/dist/fhe-disperse/react/index.d.ts +2 -1
  120. package/dist/fhe-disperse/react/index.js +8 -6
  121. package/dist/fhe-disperse/react/useDisperse.d.ts +6 -2
  122. package/dist/fhe-disperse/react/useRegister.d.ts +9 -3
  123. package/dist/fhe-disperse/react/useSingletonWithdrawTokenFee.d.ts +7 -2
  124. package/dist/fhe-disperse/react/useWithdrawTokenFee.d.ts +7 -2
  125. package/dist/fhe-disperse/singleton.d.ts +33 -19
  126. package/dist/fhe-disperse/types.d.ts +48 -8
  127. package/dist/fhe-vesting/advanced/index.cjs +6 -6
  128. package/dist/fhe-vesting/advanced/index.js +4 -4
  129. package/dist/fhe-vesting/advanced/react/index.cjs +9 -9
  130. package/dist/fhe-vesting/advanced/react/index.js +6 -6
  131. package/dist/fhe-vesting/factory.d.ts +31 -8
  132. package/dist/fhe-vesting/index.cjs +23 -23
  133. package/dist/fhe-vesting/index.d.cts +3 -2
  134. package/dist/fhe-vesting/index.d.ts +3 -2
  135. package/dist/fhe-vesting/index.js +4 -4
  136. package/dist/fhe-vesting/manager.d.ts +27 -2
  137. package/dist/fhe-vesting/react/index.cjs +126 -126
  138. package/dist/fhe-vesting/react/index.d.cts +3 -2
  139. package/dist/fhe-vesting/react/index.d.ts +3 -2
  140. package/dist/fhe-vesting/react/index.js +5 -5
  141. package/dist/fhe-vesting/react/useCreateManager.d.ts +16 -9
  142. package/dist/fhe-vesting/react/useCreateManagerAndGetAddress.d.ts +9 -5
  143. package/dist/fhe-vesting/react/useSplitVesting.d.ts +9 -3
  144. package/dist/index.cjs +18 -18
  145. package/dist/index.js +1 -1
  146. package/dist/testnet-faucet/faucet.d.ts +3 -0
  147. package/dist/testnet-faucet/index.cjs +15 -15
  148. package/dist/testnet-faucet/index.js +3 -3
  149. package/dist/testnet-faucet/react/index.cjs +9 -9
  150. package/dist/testnet-faucet/react/index.js +4 -4
  151. package/package.json +1 -1
@@ -55,6 +55,10 @@ export declare const merkleConfidentialAirdropAbi: readonly [{
55
55
  readonly inputs: readonly [];
56
56
  readonly name: "ClaimsPaused";
57
57
  readonly type: "error";
58
+ }, {
59
+ readonly inputs: readonly [];
60
+ readonly name: "ClawbackRequiresPause";
61
+ readonly type: "error";
58
62
  }, {
59
63
  readonly inputs: readonly [{
60
64
  readonly internalType: "address";
@@ -179,6 +183,10 @@ export declare const merkleConfidentialAirdropAbi: readonly [{
179
183
  readonly inputs: readonly [];
180
184
  readonly name: "LastFeeCollector";
181
185
  readonly type: "error";
186
+ }, {
187
+ readonly inputs: readonly [];
188
+ readonly name: "NativeRescueRequiresZeroFee";
189
+ readonly type: "error";
182
190
  }, {
183
191
  readonly inputs: readonly [];
184
192
  readonly name: "NotInitializing";
@@ -231,6 +239,14 @@ export declare const merkleConfidentialAirdropAbi: readonly [{
231
239
  }];
232
240
  readonly name: "UnauthorizedRedirect";
233
241
  readonly type: "error";
242
+ }, {
243
+ readonly inputs: readonly [];
244
+ readonly name: "UninitializedDelivery";
245
+ readonly type: "error";
246
+ }, {
247
+ readonly inputs: readonly [];
248
+ readonly name: "UninitializedHandle";
249
+ readonly type: "error";
234
250
  }, {
235
251
  readonly inputs: readonly [];
236
252
  readonly name: "ZamaProtocolUnsupported";
@@ -300,13 +316,33 @@ export declare const merkleConfidentialAirdropAbi: readonly [{
300
316
  }, {
301
317
  readonly indexed: false;
302
318
  readonly internalType: "uint256";
303
- readonly name: "deploymentBlockNumber";
319
+ readonly name: "gasFee";
304
320
  readonly type: "uint256";
305
321
  }, {
306
322
  readonly indexed: false;
307
- readonly internalType: "uint256";
308
- readonly name: "gasFee";
309
- readonly type: "uint256";
323
+ readonly internalType: "uint32";
324
+ readonly name: "startTime";
325
+ readonly type: "uint32";
326
+ }, {
327
+ readonly indexed: false;
328
+ readonly internalType: "uint32";
329
+ readonly name: "endTime";
330
+ readonly type: "uint32";
331
+ }, {
332
+ readonly indexed: false;
333
+ readonly internalType: "bool";
334
+ readonly name: "canExtendClaimWindow";
335
+ readonly type: "bool";
336
+ }, {
337
+ readonly indexed: false;
338
+ readonly internalType: "bool";
339
+ readonly name: "unwrappable";
340
+ readonly type: "bool";
341
+ }, {
342
+ readonly indexed: false;
343
+ readonly internalType: "address";
344
+ readonly name: "complianceManager";
345
+ readonly type: "address";
310
346
  }];
311
347
  readonly name: "AirdropInitialized";
312
348
  readonly type: "event";
@@ -450,6 +486,21 @@ export declare const merkleConfidentialAirdropAbi: readonly [{
450
486
  }];
451
487
  readonly name: "Initialized";
452
488
  readonly type: "event";
489
+ }, {
490
+ readonly anonymous: false;
491
+ readonly inputs: readonly [{
492
+ readonly indexed: true;
493
+ readonly internalType: "bytes32";
494
+ readonly name: "merkleRoot";
495
+ readonly type: "bytes32";
496
+ }, {
497
+ readonly indexed: false;
498
+ readonly internalType: "bool";
499
+ readonly name: "isMerkleRootMutable";
500
+ readonly type: "bool";
501
+ }];
502
+ readonly name: "MerkleAirdropInitialized";
503
+ readonly type: "event";
453
504
  }, {
454
505
  readonly anonymous: false;
455
506
  readonly inputs: readonly [{
@@ -465,6 +516,21 @@ export declare const merkleConfidentialAirdropAbi: readonly [{
465
516
  }];
466
517
  readonly name: "MerkleRootSet";
467
518
  readonly type: "event";
519
+ }, {
520
+ readonly anonymous: false;
521
+ readonly inputs: readonly [{
522
+ readonly indexed: true;
523
+ readonly internalType: "address";
524
+ readonly name: "recipient";
525
+ readonly type: "address";
526
+ }, {
527
+ readonly indexed: false;
528
+ readonly internalType: "uint256";
529
+ readonly name: "amount";
530
+ readonly type: "uint256";
531
+ }];
532
+ readonly name: "NativeTokenRescued";
533
+ readonly type: "event";
468
534
  }, {
469
535
  readonly anonymous: false;
470
536
  readonly inputs: readonly [{
@@ -732,6 +798,16 @@ export declare const merkleConfidentialAirdropAbi: readonly [{
732
798
  readonly outputs: readonly [];
733
799
  readonly stateMutability: "nonpayable";
734
800
  readonly type: "function";
801
+ }, {
802
+ readonly inputs: readonly [];
803
+ readonly name: "canExtendClaimWindow";
804
+ readonly outputs: readonly [{
805
+ readonly internalType: "bool";
806
+ readonly name: "";
807
+ readonly type: "bool";
808
+ }];
809
+ readonly stateMutability: "view";
810
+ readonly type: "function";
735
811
  }, {
736
812
  readonly inputs: readonly [{
737
813
  readonly internalType: "address";
@@ -790,6 +866,16 @@ export declare const merkleConfidentialAirdropAbi: readonly [{
790
866
  }];
791
867
  readonly stateMutability: "view";
792
868
  readonly type: "function";
869
+ }, {
870
+ readonly inputs: readonly [];
871
+ readonly name: "deploymentBlockNumber";
872
+ readonly outputs: readonly [{
873
+ readonly internalType: "uint256";
874
+ readonly name: "";
875
+ readonly type: "uint256";
876
+ }];
877
+ readonly stateMutability: "view";
878
+ readonly type: "function";
793
879
  }, {
794
880
  readonly inputs: readonly [{
795
881
  readonly internalType: "euint64";
@@ -1140,6 +1226,16 @@ export declare const merkleConfidentialAirdropAbi: readonly [{
1140
1226
  readonly outputs: readonly [];
1141
1227
  readonly stateMutability: "nonpayable";
1142
1228
  readonly type: "function";
1229
+ }, {
1230
+ readonly inputs: readonly [{
1231
+ readonly internalType: "address";
1232
+ readonly name: "recipient";
1233
+ readonly type: "address";
1234
+ }];
1235
+ readonly name: "rescueNativeToken";
1236
+ readonly outputs: readonly [];
1237
+ readonly stateMutability: "nonpayable";
1238
+ readonly type: "function";
1143
1239
  }, {
1144
1240
  readonly inputs: readonly [{
1145
1241
  readonly internalType: "address";
@@ -1,6 +1,6 @@
1
1
  'use strict';
2
2
 
3
- var chunkYTIYTV4K_cjs = require('../../chunk-YTIYTV4K.cjs');
3
+ var chunkVHKMWWBA_cjs = require('../../chunk-VHKMWWBA.cjs');
4
4
  require('../../chunk-MVDQMV25.cjs');
5
5
  require('../../chunk-67OV5CX2.cjs');
6
6
 
@@ -8,13 +8,17 @@ require('../../chunk-67OV5CX2.cjs');
8
8
 
9
9
  Object.defineProperty(exports, "DEPLOYMENT_MODE", {
10
10
  enumerable: true,
11
- get: function () { return chunkYTIYTV4K_cjs.DEPLOYMENT_MODE; }
11
+ get: function () { return chunkVHKMWWBA_cjs.DEPLOYMENT_MODE; }
12
12
  });
13
13
  Object.defineProperty(exports, "assertPredictionFresh", {
14
14
  enumerable: true,
15
- get: function () { return chunkYTIYTV4K_cjs.assertPredictionFresh; }
15
+ get: function () { return chunkVHKMWWBA_cjs.assertPredictionFresh; }
16
16
  });
17
17
  Object.defineProperty(exports, "assertSaltAvailable", {
18
18
  enumerable: true,
19
- get: function () { return chunkYTIYTV4K_cjs.assertSaltAvailable; }
19
+ get: function () { return chunkVHKMWWBA_cjs.assertSaltAvailable; }
20
+ });
21
+ Object.defineProperty(exports, "predictComplianceManagerClone", {
22
+ enumerable: true,
23
+ get: function () { return chunkVHKMWWBA_cjs.predictComplianceManagerClone; }
20
24
  });
@@ -29,6 +29,7 @@
29
29
  * argument types are re-exported below so this subpath is self-contained.
30
30
  */
31
31
  export type { InitCodeHashArgs, PredictArgs } from "../factory.js";
32
+ export { predictComplianceManagerClone } from "../compliance-clone.js";
32
33
  /** @alpha */
33
34
  export { DEPLOYMENT_MODE } from "../constants.js";
34
35
  export type { DeploymentMode } from "../constants.js";
@@ -29,6 +29,7 @@
29
29
  * argument types are re-exported below so this subpath is self-contained.
30
30
  */
31
31
  export type { InitCodeHashArgs, PredictArgs } from "../factory.js";
32
+ export { predictComplianceManagerClone } from "../compliance-clone.js";
32
33
  /** @alpha */
33
34
  export { DEPLOYMENT_MODE } from "../constants.js";
34
35
  export type { DeploymentMode } from "../constants.js";
@@ -1,3 +1,3 @@
1
- export { DEPLOYMENT_MODE, assertPredictionFresh, assertSaltAvailable } from '../../chunk-LEYYG4RF.js';
1
+ export { DEPLOYMENT_MODE, assertPredictionFresh, assertSaltAvailable, predictComplianceManagerClone } from '../../chunk-YMWMIWBP.js';
2
2
  import '../../chunk-4RAAATVY.js';
3
3
  import '../../chunk-QBJ7O2B4.js';