@skip-go/widget 3.12.11-alpha.0 → 3.12.11

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.
@@ -45486,7 +45486,7 @@ function walletConnect(parameters) {
45486
45486
  const optionalChains = config2.chains.map((x2) => x2.id);
45487
45487
  if (!optionalChains.length)
45488
45488
  return;
45489
- const { EthereumProvider } = await import("./index.es-BAMGhIE-.js");
45489
+ const { EthereumProvider } = await import("./index.es-BhgJ58L0.js");
45490
45490
  return await EthereumProvider.init({
45491
45491
  ...parameters,
45492
45492
  disableProviderPing: true,
@@ -48078,8 +48078,7 @@ const useGetAccount = () => {
48078
48078
  chainType,
48079
48079
  wallet: {
48080
48080
  name: "injected",
48081
- prettyName: "injected",
48082
- logo: chain == null ? void 0 : chain.logoUri
48081
+ prettyName: "injected"
48083
48082
  }
48084
48083
  };
48085
48084
  }
@@ -51220,6 +51219,7 @@ const useAutoSetAddress = () => {
51220
51219
  const [isLoading, setIsLoading] = useState(true);
51221
51220
  const [walletHasChanged, setWalletHasChanged] = useState(false);
51222
51221
  const [currentSourceWallets, setCurrentSourceWallets] = useState();
51222
+ const [currentConnectedAddress, setCurrentConnectedAddress] = useState();
51223
51223
  const { createCosmosWallets } = useCreateCosmosWallets();
51224
51224
  const { createEvmWallets } = useCreateEvmWallets();
51225
51225
  const { createSolanaWallets } = useCreateSolanaWallets();
@@ -51269,7 +51269,7 @@ const useAutoSetAddress = () => {
51269
51269
  walletPrettyName: "injected",
51270
51270
  walletChainType: chainType,
51271
51271
  walletInfo: {
51272
- logo: chain.logoUri
51272
+ logo: void 0
51273
51273
  }
51274
51274
  }
51275
51275
  }
@@ -51283,7 +51283,9 @@ const useAutoSetAddress = () => {
51283
51283
  const walletName = (_a2 = sourceWallet[chainType]) == null ? void 0 : _a2.walletName;
51284
51284
  const wallet = wallets.find((w2) => w2.walletName === walletName);
51285
51285
  const isSignRequired = signRequiredChains == null ? void 0 : signRequiredChains.includes(chainId);
51286
- const response = await ((_b2 = wallet == null ? void 0 : wallet.getAddress) == null ? void 0 : _b2.call(wallet, { signRequired: isSignRequired }));
51286
+ const response = await ((_b2 = wallet == null ? void 0 : wallet.getAddress) == null ? void 0 : _b2.call(wallet, {
51287
+ signRequired: isSignRequired
51288
+ }));
51287
51289
  const isInjectedWallet2 = connectedAddress == null ? void 0 : connectedAddress[chainId];
51288
51290
  const address = (connectedAddress == null ? void 0 : connectedAddress[chainId]) ?? (response == null ? void 0 : response.address);
51289
51291
  if (!address) {
@@ -51350,12 +51352,19 @@ const useAutoSetAddress = () => {
51350
51352
  return;
51351
51353
  }
51352
51354
  const hasWalletChanged = ((_a2 = sourceWallet.cosmos) == null ? void 0 : _a2.id) !== ((_b2 = currentSourceWallets == null ? void 0 : currentSourceWallets.cosmos) == null ? void 0 : _b2.id) || ((_c2 = sourceWallet.evm) == null ? void 0 : _c2.id) !== ((_d = currentSourceWallets == null ? void 0 : currentSourceWallets.evm) == null ? void 0 : _d.id) || ((_e2 = sourceWallet.svm) == null ? void 0 : _e2.id) !== ((_f = currentSourceWallets == null ? void 0 : currentSourceWallets.svm) == null ? void 0 : _f.id);
51355
+ const hasConnectedAddressChanged = JSON.stringify(connectedAddress) !== JSON.stringify(currentConnectedAddress);
51356
+ if (hasConnectedAddressChanged) {
51357
+ setCurrentConnectedAddress(connectedAddress);
51358
+ setWalletHasChanged(true);
51359
+ }
51353
51360
  if (hasWalletChanged) {
51354
51361
  setCurrentSourceWallets(sourceWallet);
51355
51362
  setWalletHasChanged(true);
51356
51363
  }
51357
51364
  }, [
51358
51365
  connectRequiredChains,
51366
+ connectedAddress,
51367
+ currentConnectedAddress,
51359
51368
  (_a = currentSourceWallets == null ? void 0 : currentSourceWallets.cosmos) == null ? void 0 : _a.id,
51360
51369
  (_b = currentSourceWallets == null ? void 0 : currentSourceWallets.evm) == null ? void 0 : _b.id,
51361
51370
  (_c = currentSourceWallets == null ? void 0 : currentSourceWallets.svm) == null ? void 0 : _c.id,
@@ -54325,7 +54334,7 @@ const initSentry = () => {
54325
54334
  };
54326
54335
  const name = "@skip-go/widget";
54327
54336
  const description = "Swap widget";
54328
- const version = "3.12.11-alpha.0";
54337
+ const version = "3.12.11";
54329
54338
  const repository = {
54330
54339
  url: "https://github.com/skip-mev/skip-go",
54331
54340
  directory: "packages/widget"
@@ -54342,7 +54351,9 @@ const scripts = {
54342
54351
  "build:web-component": "NODE_OPTIONS=--max-old-space-size=32384 webpack --config webpack.config.js",
54343
54352
  "publish:web-component": "npm run build:web-component && cd web-component && npm publish && cd ..",
54344
54353
  prepack: "yarn run pre",
54354
+ postpack: "yarn run post",
54345
54355
  pre: "npm run build && node scripts/prepublish.cjs",
54356
+ post: "git checkout -- package.json",
54346
54357
  "generate-chains": "node scripts/generate-chains.cjs",
54347
54358
  "update-registries": "yarn up @initia/initia-registry chain-registry",
54348
54359
  test: "yarn playwright test",
@@ -1,4 +1,4 @@
1
- import { g as getAugmentedNamespace, c as commonjsGlobal, a as getDefaultExportFromCjs, p as process$1 } from "./index-WwrLRy4v.js";
1
+ import { g as getAugmentedNamespace, c as commonjsGlobal, a as getDefaultExportFromCjs, p as process$1 } from "./index-CSCk_22k.js";
2
2
  import qg, { PROPOSAL_EXPIRY_MESSAGE } from "@walletconnect/sign-client";
3
3
  const global = globalThis || void 0 || self;
4
4
  var buffer$1 = {};
package/build/index.js CHANGED
@@ -1,4 +1,4 @@
1
- import { W, d, l, o, r, s } from "./index-WwrLRy4v.js";
1
+ import { W, d, l, o, r, s } from "./index-CSCk_22k.js";
2
2
  export {
3
3
  W as Widget,
4
4
  d as defaultTheme,
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@skip-go/widget",
3
3
  "description": "Swap widget",
4
- "version": "3.12.11-alpha.0",
4
+ "version": "3.12.11",
5
5
  "repository": {
6
6
  "url": "https://github.com/skip-mev/skip-go",
7
7
  "directory": "packages/widget"