@getpara/evm-wallet-connectors 1.7.0 → 1.7.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/dist/index.js CHANGED
@@ -92,7 +92,7 @@ var getWalletConnectUri = (connector, uriConverter) => __async(void 0, null, fun
92
92
  import {
93
93
  isMobile,
94
94
  useExternalWalletProviderStore,
95
- useWallet,
95
+ useWalletState,
96
96
  WalletType
97
97
  } from "@getpara/react-sdk";
98
98
  import { normalize } from "viem/ens";
@@ -141,7 +141,7 @@ function EvmExternalWalletProvider({ children, para, onSwitchWallet }) {
141
141
  name: normalize(ensName)
142
142
  });
143
143
  const fullAuthWallets = useExternalWalletProviderStore((state) => state.fullAuthWallets);
144
- const { data: wallet } = useWallet();
144
+ const { selectedWallet } = useWalletState();
145
145
  const isLocalConnecting = useExternalWalletStore((state) => state.isConnecting);
146
146
  const updateExternalWalletState = useExternalWalletStore((state) => state.updateState);
147
147
  const verificationMessage = useRef();
@@ -166,10 +166,11 @@ function EvmExternalWalletProvider({ children, para, onSwitchWallet }) {
166
166
  }
167
167
  }, [isLocalConnecting, wagmiAddress, isReconnecting, isConnecting]);
168
168
  useEffect(() => {
169
+ const wallet = para.findWallet(selectedWallet.id, selectedWallet.type);
169
170
  if (wallet && connectedConnector && wallet.type === WalletType.EVM && (connectedConnector.id === "para" && wallet.isExternal || connectedConnector.id !== "para" && !wallet.isExternal)) {
170
171
  switchAccount(wallet.isExternal ? wallet.name : "Para");
171
172
  }
172
- }, [wallet]);
173
+ }, [selectedWallet]);
173
174
  const connectors = untypedConnectors;
174
175
  const reset = () => __async(this, null, function* () {
175
176
  yield disconnectAsync();
package/dist/index.js.br CHANGED
Binary file
package/dist/index.js.gz CHANGED
Binary file
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@getpara/evm-wallet-connectors",
3
- "version": "1.7.0",
3
+ "version": "1.7.1",
4
4
  "type": "module",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -10,8 +10,8 @@
10
10
  },
11
11
  "dependencies": {
12
12
  "@coinbase/wallet-sdk": "4.3.0",
13
- "@getpara/react-sdk": "1.7.0",
14
- "@getpara/wagmi-v2-integration": "1.7.0",
13
+ "@getpara/react-sdk": "1.7.1",
14
+ "@getpara/wagmi-v2-integration": "1.7.1",
15
15
  "zustand": "^4.5.2",
16
16
  "zustand-sync-tabs": "^0.2.2"
17
17
  },
@@ -37,5 +37,5 @@
37
37
  "dist",
38
38
  "package.json"
39
39
  ],
40
- "gitHead": "241b03ee3d3502af3b8d702dabd615b266da10ae"
40
+ "gitHead": "767395af96d4a724946a092de760e9137a73369a"
41
41
  }