@sodax/dapp-kit 1.2.7-beta → 1.3.0-beta
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +6 -7
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +7 -8
- package/dist/index.mjs.map +1 -1
- package/package.json +3 -3
- package/src/hooks/mm/useMMApprove.ts +0 -7
- package/src/hooks/provider/useSpokeProvider.ts +10 -0
package/dist/index.js
CHANGED
|
@@ -193,6 +193,12 @@ function useSpokeProvider(spokeChainId, walletProvider) {
|
|
|
193
193
|
} : sdk.spokeChainConfig[spokeChainId]
|
|
194
194
|
);
|
|
195
195
|
}
|
|
196
|
+
if (xChainType === "NEAR") {
|
|
197
|
+
return new sdk.NearSpokeProvider(
|
|
198
|
+
walletProvider,
|
|
199
|
+
sdk.spokeChainConfig[spokeChainId]
|
|
200
|
+
);
|
|
201
|
+
}
|
|
196
202
|
return void 0;
|
|
197
203
|
}, [spokeChainId, xChainType, walletProvider, rpcConfig]);
|
|
198
204
|
return spokeProvider;
|
|
@@ -354,13 +360,6 @@ function useMMApprove() {
|
|
|
354
360
|
return allowance.value;
|
|
355
361
|
},
|
|
356
362
|
onSuccess: (_, { params, spokeProvider }) => {
|
|
357
|
-
console.log("onSuccess invoked with queryKey:", [
|
|
358
|
-
"mm",
|
|
359
|
-
"allowance",
|
|
360
|
-
spokeProvider?.chainConfig.chain.id,
|
|
361
|
-
params.token,
|
|
362
|
-
params.action
|
|
363
|
-
]);
|
|
364
363
|
queryClient.invalidateQueries({
|
|
365
364
|
queryKey: ["mm", "allowance", spokeProvider?.chainConfig.chain.id, params.token, params.action]
|
|
366
365
|
});
|