@zkp2p/sdk 0.3.0 → 0.3.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +6 -6
- package/dist/index.cjs +137 -41
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.mts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.mjs +137 -41
- package/dist/index.mjs.map +1 -1
- package/dist/react.cjs +4 -1
- package/dist/react.cjs.map +1 -1
- package/dist/react.d.mts +4 -10
- package/dist/react.d.ts +4 -10
- package/dist/react.mjs +4 -1
- package/dist/react.mjs.map +1 -1
- package/dist/{vaultUtils-sodi4Xx-.d.mts → vaultUtils-DATqc35J.d.mts} +52 -35
- package/dist/{vaultUtils-sodi4Xx-.d.ts → vaultUtils-DATqc35J.d.ts} +52 -35
- package/package.json +1 -1
package/dist/react.d.mts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { Z as Zkp2pClient, i as SignalIntentMethodParams, aj as PreparedTransaction, am as TakerTier, f as GetTakerTierRequest, g as GetTakerTierResponse, F as FulfillIntentMethodParams, bB as SendTransactionFn, bC as SendBatchFn, bz as DelegationDepositTarget, bA as BatchResult } from './vaultUtils-
|
|
2
|
-
export { bx as DelegationRoute, by as DelegationState, bD as VAULT_ZERO_ADDRESS, br as ZERO_RATE_MANAGER_ID, bE as asErrorMessage, bF as assertDelegationMethodSupport, bw as classifyDelegationState, bv as getDelegationRoute, bs as isZeroRateManagerId, bt as normalizeRateManagerId, bu as normalizeRegistry } from './vaultUtils-
|
|
1
|
+
import { Z as Zkp2pClient, P as PostDepositDetailsRequest, i as SignalIntentMethodParams, aj as PreparedTransaction, am as TakerTier, f as GetTakerTierRequest, g as GetTakerTierResponse, F as FulfillIntentMethodParams, bB as SendTransactionFn, bC as SendBatchFn, bz as DelegationDepositTarget, bA as BatchResult } from './vaultUtils-DATqc35J.mjs';
|
|
2
|
+
export { bx as DelegationRoute, by as DelegationState, bD as VAULT_ZERO_ADDRESS, br as ZERO_RATE_MANAGER_ID, bE as asErrorMessage, bF as assertDelegationMethodSupport, bw as classifyDelegationState, bv as getDelegationRoute, bs as isZeroRateManagerId, bt as normalizeRateManagerId, bu as normalizeRegistry } from './vaultUtils-DATqc35J.mjs';
|
|
3
3
|
import { Hash, Address, Hex } from 'viem';
|
|
4
4
|
import '@zkp2p/indexer-schema';
|
|
5
5
|
import 'abitype';
|
|
@@ -8,10 +8,7 @@ interface UseCreateDepositOptions {
|
|
|
8
8
|
client: Zkp2pClient | null;
|
|
9
9
|
onSuccess?: (result: {
|
|
10
10
|
hash: Hash;
|
|
11
|
-
depositDetails:
|
|
12
|
-
processorName: string;
|
|
13
|
-
depositData: Record<string, string>;
|
|
14
|
-
}>;
|
|
11
|
+
depositDetails: PostDepositDetailsRequest[];
|
|
15
12
|
}) => void;
|
|
16
13
|
onError?: (error: Error) => void;
|
|
17
14
|
}
|
|
@@ -20,10 +17,7 @@ declare function useCreateDeposit({ client, onSuccess, onError }: UseCreateDepos
|
|
|
20
17
|
isLoading: boolean;
|
|
21
18
|
error: Error | null;
|
|
22
19
|
txHash: `0x${string}` | null;
|
|
23
|
-
depositDetails:
|
|
24
|
-
processorName: string;
|
|
25
|
-
depositData: Record<string, string>;
|
|
26
|
-
}[] | null;
|
|
20
|
+
depositDetails: PostDepositDetailsRequest[] | null;
|
|
27
21
|
};
|
|
28
22
|
|
|
29
23
|
interface UseSignalIntentOptions {
|
package/dist/react.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { Z as Zkp2pClient, i as SignalIntentMethodParams, aj as PreparedTransaction, am as TakerTier, f as GetTakerTierRequest, g as GetTakerTierResponse, F as FulfillIntentMethodParams, bB as SendTransactionFn, bC as SendBatchFn, bz as DelegationDepositTarget, bA as BatchResult } from './vaultUtils-
|
|
2
|
-
export { bx as DelegationRoute, by as DelegationState, bD as VAULT_ZERO_ADDRESS, br as ZERO_RATE_MANAGER_ID, bE as asErrorMessage, bF as assertDelegationMethodSupport, bw as classifyDelegationState, bv as getDelegationRoute, bs as isZeroRateManagerId, bt as normalizeRateManagerId, bu as normalizeRegistry } from './vaultUtils-
|
|
1
|
+
import { Z as Zkp2pClient, P as PostDepositDetailsRequest, i as SignalIntentMethodParams, aj as PreparedTransaction, am as TakerTier, f as GetTakerTierRequest, g as GetTakerTierResponse, F as FulfillIntentMethodParams, bB as SendTransactionFn, bC as SendBatchFn, bz as DelegationDepositTarget, bA as BatchResult } from './vaultUtils-DATqc35J.js';
|
|
2
|
+
export { bx as DelegationRoute, by as DelegationState, bD as VAULT_ZERO_ADDRESS, br as ZERO_RATE_MANAGER_ID, bE as asErrorMessage, bF as assertDelegationMethodSupport, bw as classifyDelegationState, bv as getDelegationRoute, bs as isZeroRateManagerId, bt as normalizeRateManagerId, bu as normalizeRegistry } from './vaultUtils-DATqc35J.js';
|
|
3
3
|
import { Hash, Address, Hex } from 'viem';
|
|
4
4
|
import '@zkp2p/indexer-schema';
|
|
5
5
|
import 'abitype';
|
|
@@ -8,10 +8,7 @@ interface UseCreateDepositOptions {
|
|
|
8
8
|
client: Zkp2pClient | null;
|
|
9
9
|
onSuccess?: (result: {
|
|
10
10
|
hash: Hash;
|
|
11
|
-
depositDetails:
|
|
12
|
-
processorName: string;
|
|
13
|
-
depositData: Record<string, string>;
|
|
14
|
-
}>;
|
|
11
|
+
depositDetails: PostDepositDetailsRequest[];
|
|
15
12
|
}) => void;
|
|
16
13
|
onError?: (error: Error) => void;
|
|
17
14
|
}
|
|
@@ -20,10 +17,7 @@ declare function useCreateDeposit({ client, onSuccess, onError }: UseCreateDepos
|
|
|
20
17
|
isLoading: boolean;
|
|
21
18
|
error: Error | null;
|
|
22
19
|
txHash: `0x${string}` | null;
|
|
23
|
-
depositDetails:
|
|
24
|
-
processorName: string;
|
|
25
|
-
depositData: Record<string, string>;
|
|
26
|
-
}[] | null;
|
|
20
|
+
depositDetails: PostDepositDetailsRequest[] | null;
|
|
27
21
|
};
|
|
28
22
|
|
|
29
23
|
interface UseSignalIntentOptions {
|
package/dist/react.mjs
CHANGED
|
@@ -37,7 +37,10 @@ function useCreateDeposit({ client, onSuccess, onError }) {
|
|
|
37
37
|
},
|
|
38
38
|
[client, onSuccess, onError]
|
|
39
39
|
);
|
|
40
|
-
return useMemo(
|
|
40
|
+
return useMemo(
|
|
41
|
+
() => ({ createDeposit, isLoading, error, txHash, depositDetails }),
|
|
42
|
+
[createDeposit, isLoading, error, txHash, depositDetails]
|
|
43
|
+
);
|
|
41
44
|
}
|
|
42
45
|
function useSignalIntent({ client, onSuccess, onError }) {
|
|
43
46
|
const [isLoading, setIsLoading] = useState(false);
|