@skip-go/widget 3.9.5 → 3.9.7

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.
@@ -5151,10 +5151,10 @@ const _skipRouteAtom = atomWithQuery((get) => {
5151
5151
  const isInvertingSwap = get(isInvertingSwapAtom);
5152
5152
  const error = get(errorAtom);
5153
5153
  const routeConfig = get(routeConfigAtom);
5154
- const routePreference = get(routePreferenceAtom);
5154
+ const swapSettings = get(swapSettingsAtom);
5155
5155
  const queryEnabled = params !== void 0 && (Number(params.amountIn) > 0 || Number(params.amountOut) > 0) && !isInvertingSwap && currentPage === Routes.SwapPage && error === void 0;
5156
5156
  return {
5157
- queryKey: ["skipRoute", params, routeConfig, routePreference],
5157
+ queryKey: ["skipRoute", params, routeConfig, swapSettings],
5158
5158
  queryFn: async () => {
5159
5159
  if (!params) {
5160
5160
  throw new Error("No route request provided");
@@ -5164,7 +5164,7 @@ const _skipRouteAtom = atomWithQuery((get) => {
5164
5164
  ...params,
5165
5165
  smartRelay: true,
5166
5166
  ...routeConfig,
5167
- goFast: routePreference === RoutePreference.FASTEST,
5167
+ goFast: swapSettings.routePreference === RoutePreference.FASTEST,
5168
5168
  abortDuplicateRequests: true
5169
5169
  });
5170
5170
  return response;
@@ -43189,7 +43189,7 @@ function walletConnect(parameters) {
43189
43189
  const optionalChains = config2.chains.map((x2) => x2.id);
43190
43190
  if (!optionalChains.length)
43191
43191
  return;
43192
- const { EthereumProvider } = await import("./index.es-tDCHajGo.js");
43192
+ const { EthereumProvider } = await import("./index.es-DIYOrfZy.js");
43193
43193
  return await EthereumProvider.init({
43194
43194
  ...parameters,
43195
43195
  disableProviderPing: true,
@@ -43724,7 +43724,7 @@ const setSwapExecutionStateAtom = atom$1(null, (get, set) => {
43724
43724
  }
43725
43725
  });
43726
43726
  } else {
43727
- track("error page: unexpected error");
43727
+ track("error page: unexpected error", { error, route: route2 });
43728
43728
  set(errorAtom, {
43729
43729
  errorType: ErrorType.Unexpected,
43730
43730
  error,
@@ -45484,7 +45484,8 @@ const useCreateCosmosWallets = () => {
45484
45484
  track("wallet connected", {
45485
45485
  walletName: wallet,
45486
45486
  chainId: chainIdToConnect,
45487
- chainType: ChainType.Cosmos
45487
+ chainType: ChainType.Cosmos,
45488
+ address
45488
45489
  });
45489
45490
  return { address };
45490
45491
  } catch (e) {
@@ -45779,7 +45780,8 @@ const useCreateEvmWallets = () => {
45779
45780
  track("wallet connected", {
45780
45781
  walletName: connector.name,
45781
45782
  chainId: chainIdToConnect,
45782
- chainType: ChainType.Evm
45783
+ chainType: ChainType.Evm,
45784
+ address: account[0]
45783
45785
  });
45784
45786
  return { address: account[0], logo: (_e2 = walletConnectMetadata == null ? void 0 : walletConnectMetadata.icons) == null ? void 0 : _e2[0] };
45785
45787
  } catch (e) {
@@ -50688,7 +50690,7 @@ const SwapPage = () => {
50688
50690
  switchEvmchainId(asset == null ? void 0 : asset.chainId);
50689
50691
  setSourceAssetAmount("");
50690
50692
  setDestinationAssetAmount("");
50691
- NiceModal.hide(Modals.AssetAndChainSelectorModal);
50693
+ NiceModal.remove(Modals.AssetAndChainSelectorModal);
50692
50694
  }
50693
50695
  });
50694
50696
  }, [setDestinationAssetAmount, setSourceAsset, setSourceAssetAmount, switchEvmchainId]);
@@ -50703,7 +50705,7 @@ const SwapPage = () => {
50703
50705
  ...asset
50704
50706
  }));
50705
50707
  switchEvmchainId(asset == null ? void 0 : asset.chainId);
50706
- NiceModal.hide(Modals.AssetAndChainSelectorModal);
50708
+ NiceModal.remove(Modals.AssetAndChainSelectorModal);
50707
50709
  },
50708
50710
  selectedAsset: getClientAsset(sourceAsset == null ? void 0 : sourceAsset.denom, sourceAsset == null ? void 0 : sourceAsset.chainId),
50709
50711
  selectChain: true
@@ -50719,7 +50721,7 @@ const SwapPage = () => {
50719
50721
  ...old,
50720
50722
  ...asset
50721
50723
  }));
50722
- NiceModal.hide(Modals.AssetAndChainSelectorModal);
50724
+ NiceModal.remove(Modals.AssetAndChainSelectorModal);
50723
50725
  }
50724
50726
  });
50725
50727
  }, [setDestinationAsset]);
@@ -50733,7 +50735,7 @@ const SwapPage = () => {
50733
50735
  ...old,
50734
50736
  ...asset
50735
50737
  }));
50736
- NiceModal.hide(Modals.AssetAndChainSelectorModal);
50738
+ NiceModal.remove(Modals.AssetAndChainSelectorModal);
50737
50739
  },
50738
50740
  selectedAsset: getClientAsset(destinationAsset == null ? void 0 : destinationAsset.denom, destinationAsset == null ? void 0 : destinationAsset.chainId),
50739
50741
  selectChain: true
@@ -52235,7 +52237,7 @@ const initSentry = () => {
52235
52237
  };
52236
52238
  const name = "@skip-go/widget";
52237
52239
  const description = "Swap widget";
52238
- const version = "3.9.5";
52240
+ const version = "3.9.7";
52239
52241
  const repository = {
52240
52242
  url: "https://github.com/skip-mev/skip-go",
52241
52243
  directory: "packages/widget"
@@ -52410,7 +52412,6 @@ const initAmplitude = () => {
52410
52412
  init$1("14616a575f32087cf0403ab8f3ea3ce0", {
52411
52413
  autocapture: true,
52412
52414
  appVersion: version
52413
- // serverUrl: "https://go.skip.build/api/amplitude"
52414
52415
  });
52415
52416
  isAmplitudeInitialized = true;
52416
52417
  };
@@ -1,4 +1,4 @@
1
- import { g as getAugmentedNamespace, c as commonjsGlobal, a as getDefaultExportFromCjs, p as process$1 } from "./index-DRALD_14.js";
1
+ import { g as getAugmentedNamespace, c as commonjsGlobal, a as getDefaultExportFromCjs, p as process$1 } from "./index-BwjkVbQ6.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 } from "./index-DRALD_14.js";
1
+ import { W, d, l, o, r } from "./index-BwjkVbQ6.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.9.5",
4
+ "version": "3.9.7",
5
5
  "repository": {
6
6
  "url": "https://github.com/skip-mev/skip-go",
7
7
  "directory": "packages/widget"
@@ -44,7 +44,7 @@
44
44
  "@penumbra-zone/transport-dom": "^7.5.0",
45
45
  "@r2wc/react-to-web-component": "^2.0.3",
46
46
  "@sentry/react": "^8.46.0",
47
- "@skip-go/client": "1.0.5",
47
+ "@skip-go/client": "1.0.6",
48
48
  "@solana/spl-token": "^0.4.8",
49
49
  "@solana/wallet-adapter-backpack": "^0.1.14",
50
50
  "@solana/wallet-adapter-coinbase": "^0.1.19",