@sundaeswap/wallet-lite 0.0.18 → 0.0.20
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/cjs/classes/WalletAssetMap.class.js +1 -1
- package/dist/cjs/classes/WalletAssetMap.class.js.map +1 -1
- package/dist/cjs/react-components/hooks/useWalletHandles.js +10 -14
- package/dist/cjs/react-components/hooks/useWalletHandles.js.map +1 -1
- package/dist/esm/classes/WalletAssetMap.class.js +1 -1
- package/dist/esm/classes/WalletAssetMap.class.js.map +1 -1
- package/dist/esm/react-components/hooks/useWalletHandles.js +3 -8
- package/dist/esm/react-components/hooks/useWalletHandles.js.map +1 -1
- package/dist/types/classes/WalletAssetMap.class.d.ts.map +1 -1
- package/dist/types/react-components/hooks/useWalletHandles.d.ts.map +1 -1
- package/dist/types/tsconfig.build.tsbuildinfo +1 -1
- package/package.json +1 -1
- package/src/classes/WalletAssetMap.class.ts +2 -1
- package/src/react-components/hooks/useWalletHandles.ts +4 -10
package/package.json
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { AssetAmount, IAssetAmountMetadata } from "@sundaeswap/asset";
|
|
2
|
-
|
|
2
|
+
|
|
3
|
+
import { normalizeAssetIdWithDot } from "../utils/assets.js";
|
|
3
4
|
|
|
4
5
|
/**
|
|
5
6
|
* Map wrapper to enforce asset id normalization when setting and getting assets.
|
|
@@ -33,20 +33,16 @@ export const useWalletHandles = <
|
|
|
33
33
|
}
|
|
34
34
|
|
|
35
35
|
try {
|
|
36
|
-
const
|
|
37
|
-
default: HandleClient,
|
|
38
|
-
HandleClientContext,
|
|
39
|
-
KoraLabsProvider,
|
|
40
|
-
} = await import("@koralabs/adahandle-sdk");
|
|
36
|
+
const HandleClient = await import("@koralabs/adahandle-sdk");
|
|
41
37
|
const context =
|
|
42
38
|
state.network === 1
|
|
43
|
-
? HandleClientContext.MAINNET
|
|
44
|
-
: HandleClientContext.PREVIEW;
|
|
39
|
+
? HandleClient.HandleClientContext.MAINNET
|
|
40
|
+
: HandleClient.HandleClientContext.PREVIEW;
|
|
45
41
|
|
|
46
42
|
// @ts-ignore Type isn't exported from default.
|
|
47
43
|
const sdk = new HandleClient({
|
|
48
44
|
context,
|
|
49
|
-
provider: new KoraLabsProvider(context),
|
|
45
|
+
provider: new HandleClient.KoraLabsProvider(context),
|
|
50
46
|
});
|
|
51
47
|
|
|
52
48
|
// Restore once SDK updated
|
|
@@ -122,7 +118,5 @@ export const useWalletHandles = <
|
|
|
122
118
|
[handles, loadingHandles]
|
|
123
119
|
);
|
|
124
120
|
|
|
125
|
-
console.log(handles, loadingHandles);
|
|
126
|
-
|
|
127
121
|
return data;
|
|
128
122
|
};
|