@imtbl/checkout-widgets 2.0.0-alpha.13 → 2.0.0-alpha.15
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/browser/{AddTokensWidget-CzgX9heG.js → AddTokensWidget-BQahyA3-.js} +15 -15
- package/dist/browser/{BridgeWidget-Crk1usAK.js → BridgeWidget-ZpF_tJSc.js} +23 -23
- package/dist/browser/{CommerceWidget-DePTbE4O.js → CommerceWidget-DBWhiBvT.js} +161 -161
- package/dist/browser/{FeesBreakdown-C69PA3Ib.js → FeesBreakdown-DdGiRw8P.js} +1 -1
- package/dist/browser/{OnRampWidget-CsogmXN6.js → OnRampWidget-sGvxUYOI.js} +5 -5
- package/dist/browser/{SaleWidget-DoCX5fdJ.js → SaleWidget-DFK9l2Z4.js} +53 -53
- package/dist/browser/{SpendingCapHero-qaTypYdu.js → SpendingCapHero-DRswIR2n.js} +1 -1
- package/dist/browser/SwapWidget-B5C3gpxa.js +1850 -0
- package/dist/browser/{TokenImage-D4yE9eX_.js → TokenImage-DNYI0i8E.js} +1 -1
- package/dist/browser/{TopUpView-CleczVDG.js → TopUpView-_N2gg9jT.js} +4 -4
- package/dist/browser/{WalletApproveHero-CiiXIT6K.js → WalletApproveHero-BT_Y3Q0t.js} +4 -4
- package/dist/browser/{WalletWidget-CLGxyMuN.js → WalletWidget-yY1474i7.js} +14 -14
- package/dist/browser/{auto-track-B6OrkcgK.js → auto-track-EsPRmuOe.js} +1 -1
- package/dist/browser/{index-C848PTQn.js → index-BMwU0tSw.js} +1 -1
- package/dist/browser/{index-ClevRkXY.js → index-BXDoJOWg.js} +289 -365
- package/dist/browser/{index-DHuLAS6t.js → index-ByR2YjB2.js} +2 -2
- package/dist/browser/{index-BpM1cBnm.js → index-CH0Rm1XT.js} +1 -1
- package/dist/browser/{index-DETDiGVw.js → index-CNRxg_7d.js} +1 -1
- package/dist/browser/{index-CdQSsHNW.js → index-CQlitk4E.js} +1 -1
- package/dist/browser/{index-Bew2zgex.js → index-DoEpK5dt.js} +1 -1
- package/dist/browser/{index-BsPQQ9Rb.js → index-MluRDUBR.js} +1 -1
- package/dist/browser/index.cdn.js +686 -650
- package/dist/browser/index.js +1 -1
- package/dist/browser/{index.umd-BZ33ZTmJ.js → index.umd-DW0Lbx8I.js} +1 -1
- package/dist/browser/{useInterval-Q9YR_BRJ.js → useInterval-Y7Ilt91Q.js} +1 -1
- package/dist/types/widgets/swap/GeoblockLoader.d.ts +1 -1
- package/dist/types/widgets/swap/SwapWidget.d.ts +1 -1
- package/dist/types/widgets/swap/SwapWidgetRoot.d.ts +0 -2
- package/package.json +7 -7
- package/src/lib/metrics.ts +4 -3
- package/src/widgets/swap/GeoblockLoader.tsx +3 -1
- package/src/widgets/swap/SwapWidget.tsx +216 -153
- package/src/widgets/swap/SwapWidgetRoot.tsx +17 -80
- package/dist/browser/SwapWidget-Bjzgrcnk.js +0 -1738
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { r as reactExports,
|
|
2
|
-
import { T as TokenImage } from './TokenImage-
|
|
3
|
-
import { F as FeesBreakdown } from './FeesBreakdown-
|
|
1
|
+
import { r as reactExports, u as uo, k as ko, v as commonjsGlobal, x as getDefaultExportFromCjs, l as jsx, n as jsxs, B as Box, c as useTranslation, D as Drawer, z as Divider, H as Heading, F as Button, G as useProvidersContext, K as useAnalytics, W as WalletDrawer, U as UnableToConnectDrawer, M as Fragment, N as jt, Q as UserJourney, X as removeSpace, Y as getProviderSlugFromRdns, Z as W, _ as isPassportProvider, $ as connectEIP6963Provider, a0 as identifyUser, a1 as ConnectEIP6963ProviderError, a2 as ProvidersContextActions, a3 as MenuItem, a4 as SQUID_NATIVE_TOKEN, J, a5 as commonjsRequire, a6 as getRemoteImage, a7 as vFlex, a8 as OnboardingPagination, a9 as ViewContext, aa as useHandover, ab as HandoverTarget, ac as EventTargetContext, V as ViewActions, ad as getRemoteRive, ae as APPROVE_TXN_ANIMATION, af as RiveStateMachineInput, ag as HandoverContent, ah as keyframes, ai as getDefaultTokenImage, aj as ie, a as getL2ChainId, ak as isNativeToken, al as getTokenImageByAddress, am as TOKEN_PRIORITY_ORDER, an as SmartClone, ao as FramedImage, ap as FramedIcon, aq as ButtCon, ar as TextInput, as as VerticalMenu, at as Body, au as EllipsizedText, av as Tooltip, aw as Sticker, ax as getDurationFormatted, ay as getTotalRouteFees, az as getRouteAndTokenBalances, aA as Stack, aB as hFlex, aC as centerFlexChildren, aD as Icon, aE as Badge, aF as getFormattedAmounts, aG as getRemoteVideo, aH as FramedVideo, aI as listVariants, aJ as motion, aK as listItemVariants, aL as Banner, aM as xt, aN as Bt, aO as useRoutes, aP as useInjectedProviders, aQ as hn, aR as RouteError, aS as HeroFormControl, aT as SimpleLayout, aU as dist, i as SharedViews, aV as orchestrationEvents, aW as HeroTextInput, aX as SquidFooter, aY as TOOLKIT_SQUID_URL, aZ as merge, a_ as SvgIcon, a$ as WalletWarningHero, b0 as getFormattedNumber, b1 as FIXED_HANDOVER_DURATION, b2 as EXECUTE_TXN_ANIMATION, b3 as Link, b4 as Trans, b5 as useExecute, b6 as getRouteChains, b7 as t, b8 as convertToNetworkChangeableProvider, b9 as verifyAndSwitchChain, ba as PriceDisplay, L as LoadingView, bb as useTheme, bc as viewReducer, bd as initialViewState, be as useSquid, bf as useTokens, bg as v4, bh as K, bi as isValidAddress, bj as amountInputValidation, bk as fetchChains, bl as fetchBalances, bm as CloudImage, o as ErrorView, bn as ServiceUnavailableErrorView } from './index-BXDoJOWg.js';
|
|
2
|
+
import { T as TokenImage } from './TokenImage-DNYI0i8E.js';
|
|
3
|
+
import { F as FeesBreakdown } from './FeesBreakdown-DdGiRw8P.js';
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
6
|
* The function `useInterval` sets up an interval that repeatedly calls a given callback function with
|
|
@@ -31,9 +31,9 @@ function useInterval(callback, interval) {
|
|
|
31
31
|
|
|
32
32
|
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
33
33
|
function sendAddTokensCloseEvent(eventTarget) {
|
|
34
|
-
const closeWidgetEvent = new CustomEvent(
|
|
34
|
+
const closeWidgetEvent = new CustomEvent(uo.IMTBL_ADD_TOKENS_WIDGET_EVENT, {
|
|
35
35
|
detail: {
|
|
36
|
-
type:
|
|
36
|
+
type: ko.CLOSE_WIDGET,
|
|
37
37
|
data: {},
|
|
38
38
|
},
|
|
39
39
|
});
|
|
@@ -44,9 +44,9 @@ function sendAddTokensCloseEvent(eventTarget) {
|
|
|
44
44
|
eventTarget.dispatchEvent(closeWidgetEvent);
|
|
45
45
|
}
|
|
46
46
|
function sendConnectProviderSuccessEvent(eventTarget, providerType, provider, providerInfo) {
|
|
47
|
-
const successEvent = new CustomEvent(
|
|
47
|
+
const successEvent = new CustomEvent(uo.IMTBL_ADD_TOKENS_WIDGET_EVENT, {
|
|
48
48
|
detail: {
|
|
49
|
-
type:
|
|
49
|
+
type: ko.CONNECT_SUCCESS,
|
|
50
50
|
data: {
|
|
51
51
|
provider,
|
|
52
52
|
providerType,
|
|
@@ -60,9 +60,9 @@ function sendConnectProviderSuccessEvent(eventTarget, providerType, provider, pr
|
|
|
60
60
|
eventTarget.dispatchEvent(successEvent);
|
|
61
61
|
}
|
|
62
62
|
const sendAddTokensSuccessEvent = (eventTarget, transactionHash) => {
|
|
63
|
-
const successEvent = new CustomEvent(
|
|
63
|
+
const successEvent = new CustomEvent(uo.IMTBL_ADD_TOKENS_WIDGET_EVENT, {
|
|
64
64
|
detail: {
|
|
65
|
-
type:
|
|
65
|
+
type: ko.SUCCESS,
|
|
66
66
|
data: {
|
|
67
67
|
transactionHash,
|
|
68
68
|
},
|
|
@@ -74,9 +74,9 @@ const sendAddTokensSuccessEvent = (eventTarget, transactionHash) => {
|
|
|
74
74
|
eventTarget.dispatchEvent(successEvent);
|
|
75
75
|
};
|
|
76
76
|
const sendAddTokensFailedEvent = (eventTarget, reason) => {
|
|
77
|
-
const failedEvent = new CustomEvent(
|
|
77
|
+
const failedEvent = new CustomEvent(uo.IMTBL_ADD_TOKENS_WIDGET_EVENT, {
|
|
78
78
|
detail: {
|
|
79
|
-
type:
|
|
79
|
+
type: ko.FAILURE,
|
|
80
80
|
data: {
|
|
81
81
|
reason,
|
|
82
82
|
timestamp: new Date().getTime(),
|
|
@@ -3893,7 +3893,7 @@ function TokenDrawerMenu({ checkout, config, toTokenAddress, addTokensState, add
|
|
|
3893
3893
|
(async () => {
|
|
3894
3894
|
try {
|
|
3895
3895
|
const tokenResponse = await checkout.getTokenAllowList({
|
|
3896
|
-
type:
|
|
3896
|
+
type: ie.SWAP,
|
|
3897
3897
|
chainId: getL2ChainId(checkout.config),
|
|
3898
3898
|
});
|
|
3899
3899
|
if (tokenResponse?.tokens.length > 0) {
|
|
@@ -4403,7 +4403,7 @@ function AddTokens({ checkout, toAmount, config, toTokenAddress, showOnrampOptio
|
|
|
4403
4403
|
const fetchOnRampTokens = async () => {
|
|
4404
4404
|
try {
|
|
4405
4405
|
const tokenResponse = await checkout.getTokenAllowList({
|
|
4406
|
-
type:
|
|
4406
|
+
type: ie.ONRAMP,
|
|
4407
4407
|
chainId: getL2ChainId(checkout.config),
|
|
4408
4408
|
});
|
|
4409
4409
|
if (tokenResponse?.tokens.length > 0) {
|
|
@@ -4447,7 +4447,7 @@ function AddTokens({ checkout, toAmount, config, toTokenAddress, showOnrampOptio
|
|
|
4447
4447
|
showBackButton: true,
|
|
4448
4448
|
provider: toProvider,
|
|
4449
4449
|
};
|
|
4450
|
-
orchestrationEvents.sendRequestOnrampEvent(eventTarget,
|
|
4450
|
+
orchestrationEvents.sendRequestOnrampEvent(eventTarget, uo.IMTBL_ADD_TOKENS_WIDGET_EVENT, data);
|
|
4451
4451
|
};
|
|
4452
4452
|
const handleCardClick = () => {
|
|
4453
4453
|
setPayWithCardClicked(true);
|
|
@@ -5296,7 +5296,7 @@ function AddTokensWidget({ showOnrampOption = true, showSwapOption = true, showB
|
|
|
5296
5296
|
objectFit: 'cover',
|
|
5297
5297
|
objectPosition: 'center',
|
|
5298
5298
|
} }), viewState.view.type === AddTokensWidgetViews.ADD_TOKENS && (jsx(AddTokens, { config: config, checkout: checkout, toTokenAddress: toTokenAddress, toAmount: toAmount, showBackButton: showBackButton, showOnrampOption: showOnrampOption, showSwapOption: showSwapOption, showBridgeOption: showBridgeOption, onCloseButtonClick: () => sendAddTokensCloseEvent(eventTarget), onBackButtonClick: () => {
|
|
5299
|
-
orchestrationEvents.sendRequestGoBackEvent(eventTarget,
|
|
5299
|
+
orchestrationEvents.sendRequestGoBackEvent(eventTarget, uo.IMTBL_ADD_TOKENS_WIDGET_EVENT, {});
|
|
5300
5300
|
} })), viewState.view.type === AddTokensWidgetViews.REVIEW && (jsx(Review, { data: viewState.view.data, onCloseButtonClick: () => sendAddTokensCloseEvent(eventTarget), onBackButtonClick: () => {
|
|
5301
5301
|
viewDispatch({
|
|
5302
5302
|
payload: {
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { c3 as axios, c4 as k, c5 as q, r as reactExports,
|
|
2
|
-
import { T as TokenImage } from './TokenImage-
|
|
3
|
-
import { B as BridgeWidgetViews, T as TopUpView } from './TopUpView-
|
|
4
|
-
import { S as SelectForm, T as TextInputForm, a as TransactionRejected, g as getAllowedBalances, F as Fees, N as NetworkSwitchDrawer, W as WalletApproveHero } from './WalletApproveHero-
|
|
5
|
-
import { u as useInterval } from './useInterval-
|
|
6
|
-
import './FeesBreakdown-
|
|
1
|
+
import { c3 as axios, c4 as k, c5 as q, r as reactExports, u as uo, T as To, n as jsxs, l as jsx, c6 as ShimmerBox, a3 as MenuItem, aA as Stack, c as useTranslation, at as Body, F as Button, B as Box, c7 as PASSPORT_URL, b3 as Link, c8 as getChainIdBySlug, c9 as getChainImage, ca as networkName, ao as FramedImage, au as EllipsizedText, aD as Icon, K as useAnalytics, Q as UserJourney, cb as Accordion, z as Divider, a9 as ViewContext, M as Fragment, V as ViewActions, cc as useWalletConnect, cd as isWalletConnectProvider, ce as Logo, cf as RawImage, bU as CryptoFiatContext, cg as AXELAR_SCAN_URL, ak as isNativeToken, al as getTokenImageByAddress, ch as getNativeSymbolByChainSlug, bM as formatUnits, bt as calculateCryptoToFiat, ac as EventTargetContext, _ as isPassportProvider, b as getL1ChainId, aj as ie, a as getL2ChainId, N as jt, Z as W, aP as useInjectedProviders, ci as retry, bC as HeaderNavigation, bF as FooterLogo, W as WalletDrawer, aT as SimpleLayout, cj as getChainSlugById, ck as JsonRpcProvider, b$ as CryptoFiatActions, cl as DEFAULT_TRANSACTIONS_RETRY_POLICY, L as LoadingView, J, cm as getChainNameById, bb as useTheme, H as Heading, cn as getWalletProviderNameByProvider, co as isMetaMaskProvider, cp as me, D as Drawer, aq as ButtCon, cq as ButtonNavigationStyles, aV as orchestrationEvents, bI as tokenValueFormat, cr as formatZeroAmount, cs as NATIVE, aM as xt, bj as amountInputValidation, a6 as getRemoteImage, bm as CloudImage, ct as ETH_TOKEN_SYMBOL, bo as Contract, bh as K, cu as parseUnits, cv as st, cw as DEFAULT_TOKEN_DECIMALS, cx as DEFAULT_QUOTE_REFRESH_INTERVAL, cy as addChainChangedListener, cz as removeChainChangedListener, aN as Bt, cA as IMX_TOKEN_SYMBOL, i as SharedViews, cB as dist, cC as CHECKOUT_CDN_BASE_URL, cD as heroBackGroundStyles, cE as heroImageStyles, aE as Badge, cF as SimpleTextBody, cG as FooterButton, cH as getEthTokenImage, cI as WITHDRAWAL_CLAIM_GAS_LIMIT, cJ as Ct, ai as getDefaultTokenImage, bc as viewReducer, bd as initialViewState, cK as Qe, cL as r, cM as $e, cN as StatusView, bG as StatusType, o as ErrorView, bn as ServiceUnavailableErrorView, c2 as CryptoFiatProvider, cO as O, cP as $, cQ as P } from './index-BXDoJOWg.js';
|
|
2
|
+
import { T as TokenImage } from './TokenImage-DNYI0i8E.js';
|
|
3
|
+
import { B as BridgeWidgetViews, T as TopUpView } from './TopUpView-_N2gg9jT.js';
|
|
4
|
+
import { S as SelectForm, T as TextInputForm, a as TransactionRejected, g as getAllowedBalances, F as Fees, N as NetworkSwitchDrawer, W as WalletApproveHero } from './WalletApproveHero-BT_Y3Q0t.js';
|
|
5
|
+
import { u as useInterval } from './useInterval-Y7Ilt91Q.js';
|
|
6
|
+
import './FeesBreakdown-DdGiRw8P.js';
|
|
7
7
|
|
|
8
8
|
// This module is intended to unwrap Axios default export as named.
|
|
9
9
|
// Keep top-level export same with static properties
|
|
@@ -220,9 +220,9 @@ const bridgeReducer = (state, action) => {
|
|
|
220
220
|
};
|
|
221
221
|
|
|
222
222
|
const sendBridgeTransactionSentEvent = (eventTarget, transactionHash) => {
|
|
223
|
-
const successEvent = new CustomEvent(
|
|
223
|
+
const successEvent = new CustomEvent(uo.IMTBL_BRIDGE_WIDGET_EVENT, {
|
|
224
224
|
detail: {
|
|
225
|
-
type:
|
|
225
|
+
type: To.TRANSACTION_SENT,
|
|
226
226
|
data: {
|
|
227
227
|
transactionHash,
|
|
228
228
|
},
|
|
@@ -234,9 +234,9 @@ const sendBridgeTransactionSentEvent = (eventTarget, transactionHash) => {
|
|
|
234
234
|
eventTarget.dispatchEvent(successEvent);
|
|
235
235
|
};
|
|
236
236
|
const sendBridgeFailedEvent = (eventTarget, reason) => {
|
|
237
|
-
const failedEvent = new CustomEvent(
|
|
237
|
+
const failedEvent = new CustomEvent(uo.IMTBL_BRIDGE_WIDGET_EVENT, {
|
|
238
238
|
detail: {
|
|
239
|
-
type:
|
|
239
|
+
type: To.FAILURE,
|
|
240
240
|
data: {
|
|
241
241
|
reason,
|
|
242
242
|
timestamp: new Date().getTime(),
|
|
@@ -249,9 +249,9 @@ const sendBridgeFailedEvent = (eventTarget, reason) => {
|
|
|
249
249
|
eventTarget.dispatchEvent(failedEvent);
|
|
250
250
|
};
|
|
251
251
|
function sendBridgeWidgetCloseEvent(eventTarget) {
|
|
252
|
-
const closeWidgetEvent = new CustomEvent(
|
|
252
|
+
const closeWidgetEvent = new CustomEvent(uo.IMTBL_BRIDGE_WIDGET_EVENT, {
|
|
253
253
|
detail: {
|
|
254
|
-
type:
|
|
254
|
+
type: To.CLOSE_WIDGET,
|
|
255
255
|
data: {},
|
|
256
256
|
},
|
|
257
257
|
});
|
|
@@ -261,9 +261,9 @@ function sendBridgeWidgetCloseEvent(eventTarget) {
|
|
|
261
261
|
eventTarget.dispatchEvent(closeWidgetEvent);
|
|
262
262
|
}
|
|
263
263
|
const sendBridgeClaimWithdrawalSuccessEvent = (eventTarget, transactionHash) => {
|
|
264
|
-
const successEvent = new CustomEvent(
|
|
264
|
+
const successEvent = new CustomEvent(uo.IMTBL_BRIDGE_WIDGET_EVENT, {
|
|
265
265
|
detail: {
|
|
266
|
-
type:
|
|
266
|
+
type: To.CLAIM_WITHDRAWAL_SUCCESS,
|
|
267
267
|
data: {
|
|
268
268
|
transactionHash,
|
|
269
269
|
},
|
|
@@ -275,9 +275,9 @@ const sendBridgeClaimWithdrawalSuccessEvent = (eventTarget, transactionHash) =>
|
|
|
275
275
|
eventTarget.dispatchEvent(successEvent);
|
|
276
276
|
};
|
|
277
277
|
const sendBridgeClaimWithdrawalFailedEvent = (eventTarget, transactionHash, reason) => {
|
|
278
|
-
const failedEvent = new CustomEvent(
|
|
278
|
+
const failedEvent = new CustomEvent(uo.IMTBL_BRIDGE_WIDGET_EVENT, {
|
|
279
279
|
detail: {
|
|
280
|
-
type:
|
|
280
|
+
type: To.CLAIM_WITHDRAWAL_FAILURE,
|
|
281
281
|
data: {
|
|
282
282
|
transactionHash,
|
|
283
283
|
reason,
|
|
@@ -705,7 +705,7 @@ function Transactions({ defaultTokenImage, onBackButtonClick, }) {
|
|
|
705
705
|
const rootChainId = getL1ChainId(checkout.config);
|
|
706
706
|
try {
|
|
707
707
|
const tokens = (await checkout.getTokenAllowList({
|
|
708
|
-
type:
|
|
708
|
+
type: ie.BRIDGE,
|
|
709
709
|
chainId: rootChainId,
|
|
710
710
|
})).tokens ?? [];
|
|
711
711
|
return tokens.reduce((out, current) => {
|
|
@@ -1447,7 +1447,7 @@ function WalletAndNetworkSelector() {
|
|
|
1447
1447
|
display: 'flex',
|
|
1448
1448
|
flexDirection: 'column',
|
|
1449
1449
|
gap: 'base.spacing.x10',
|
|
1450
|
-
}, children: [jsx(WalletNetworkButton, { testId: testId$1, walletProviderDetail: fromWallet?.providerDetail, walletProvider: fromWalletBrowserProvider, walletName: fromWalletProviderName, walletAddress: abbreviateAddress(fromWalletAddress), chainId: fromNetwork, disableNetworkButton: fromWalletProviderName ===
|
|
1450
|
+
}, children: [jsx(WalletNetworkButton, { testId: testId$1, walletProviderDetail: fromWallet?.providerDetail, walletProvider: fromWalletBrowserProvider, walletName: fromWalletProviderName, walletAddress: abbreviateAddress(fromWalletAddress), chainId: fromNetwork, disableNetworkButton: fromWalletProviderName === me.PASSPORT.toString(), onWalletClick: () => {
|
|
1451
1451
|
// TODO: Force an account selection here
|
|
1452
1452
|
setFromWalletDrawerOpen(true);
|
|
1453
1453
|
}, onNetworkClick: () => setFromNetworkDrawerOpen(true), environment: environment }), jsxs(Box, { children: [jsx(Heading, { size: "xSmall", sx: { paddingBottom: 'base.spacing.x2' }, children: t('views.WALLET_NETWORK_SELECTION.toFormInput.heading') }), jsx(WalletDrawer, { testId: `${testId$1}-to`, drawerText: {
|
|
@@ -1467,7 +1467,7 @@ function WalletAndNetworkSelector() {
|
|
|
1467
1467
|
flexDirection: 'column',
|
|
1468
1468
|
justifyContent: 'space-between',
|
|
1469
1469
|
}, children: [jsx(WalletNetworkButton, { testId: testId$1, walletProviderDetail: toWallet?.providerDetail, walletProvider: toWalletBrowserProvider, walletName: toWalletProviderName, walletAddress: abbreviateAddress(toWalletAddress), chainId: toNetwork, disableNetworkButton: fromNetwork === l1NetworkChainId
|
|
1470
|
-
|| toWalletProviderName ===
|
|
1470
|
+
|| toWalletProviderName === me.PASSPORT.toString()
|
|
1471
1471
|
|| fromWalletAddress === toWalletAddress, onWalletClick: () => {
|
|
1472
1472
|
setToWalletDrawerOpen(true);
|
|
1473
1473
|
}, onNetworkClick: () => {
|
|
@@ -1494,7 +1494,7 @@ function WalletNetworkSelectionView({ showBackButton, }) {
|
|
|
1494
1494
|
},
|
|
1495
1495
|
});
|
|
1496
1496
|
}, testId: "move-transactions-button" })), showBack: showBackButton, onBackButtonClick: () => {
|
|
1497
|
-
orchestrationEvents.sendRequestGoBackEvent(eventTarget,
|
|
1497
|
+
orchestrationEvents.sendRequestGoBackEvent(eventTarget, uo.IMTBL_BRIDGE_WIDGET_EVENT, {});
|
|
1498
1498
|
} })), footer: jsx(FooterLogo, {}), children: jsx(WalletAndNetworkSelector, {}) }));
|
|
1499
1499
|
}
|
|
1500
1500
|
|
|
@@ -1811,7 +1811,7 @@ function Bridge({ amount, tokenAddress, defaultTokenImage, theme, }) {
|
|
|
1811
1811
|
checkout,
|
|
1812
1812
|
provider: from.browserProvider,
|
|
1813
1813
|
chainId: from?.network,
|
|
1814
|
-
allowTokenListType:
|
|
1814
|
+
allowTokenListType: ie.BRIDGE,
|
|
1815
1815
|
// Skip retry given that in this case it is not needed;
|
|
1816
1816
|
// refreshBalances will be, automatically, called again
|
|
1817
1817
|
// after REFRESH_TOKENS_INTERVAL_MS.
|
|
@@ -2816,7 +2816,7 @@ function ClaimWithdrawal({ transaction }) {
|
|
|
2816
2816
|
if (isPassportProvider(from?.browserProvider) || forceChangeAccount) {
|
|
2817
2817
|
// user should switch to MetaMask
|
|
2818
2818
|
try {
|
|
2819
|
-
const createProviderResult = await checkout.createProvider({ walletProviderName:
|
|
2819
|
+
const createProviderResult = await checkout.createProvider({ walletProviderName: me.METAMASK });
|
|
2820
2820
|
const connectResult = await checkout.connect({
|
|
2821
2821
|
provider: createProviderResult.provider,
|
|
2822
2822
|
requestWalletPermissions: true,
|
|
@@ -3056,7 +3056,7 @@ function BridgeWidget({ checkout, browserProvider, config, amount, tokenAddress,
|
|
|
3056
3056
|
userJourney: UserJourney.BRIDGE,
|
|
3057
3057
|
screen: 'Error',
|
|
3058
3058
|
});
|
|
3059
|
-
} })), viewState.view.type === SharedViews.TOP_UP_VIEW && (jsx(TopUpView, { analytics: { userJourney: UserJourney.BRIDGE }, widgetEvent:
|
|
3059
|
+
} })), viewState.view.type === SharedViews.TOP_UP_VIEW && (jsx(TopUpView, { analytics: { userJourney: UserJourney.BRIDGE }, widgetEvent: uo.IMTBL_BRIDGE_WIDGET_EVENT, checkout: checkout, provider: browserProvider, showOnrampOption: isOnRampEnabled, showSwapOption: isSwapEnabled, showBridgeOption: isBridgeEnabled, onCloseButtonClick: () => sendBridgeWidgetCloseEvent(eventTarget) })), viewState.view.type === BridgeWidgetViews.CLAIM_WITHDRAWAL_IN_PROGRESS && (jsx(ClaimWithdrawalInProgress, { transactionResponse: viewState.view.transactionResponse })), viewState.view.type === BridgeWidgetViews.CLAIM_WITHDRAWAL_SUCCESS && (jsx(StatusView, { statusText: t('views.CLAIM_WITHDRAWAL.IN_PROGRESS.success.text'), actionText: t('views.CLAIM_WITHDRAWAL.IN_PROGRESS.success.actionText'), onRenderEvent: () => {
|
|
3060
3060
|
page({
|
|
3061
3061
|
userJourney: UserJourney.BRIDGE,
|
|
3062
3062
|
screen: 'ClaimWithdrawalSuccess',
|