@imtbl/checkout-widgets 2.0.0-alpha.0
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/LICENSE.md +176 -0
- package/README.md +3 -0
- package/dist/browser/AddTokensWidget-QGKGQBKZ.js +1 -0
- package/dist/browser/BridgeWidget-2JZZV7LZ.js +1 -0
- package/dist/browser/CommerceWidget-IVNOVHCZ.js +1 -0
- package/dist/browser/ConnectWidget-ZM6T4NZJ.js +1 -0
- package/dist/browser/OnRampWidget-CXSJR4D2.js +1 -0
- package/dist/browser/SaleWidget-NS5UQNBN.js +1 -0
- package/dist/browser/SwapWidget-3DWYEOCD.js +1 -0
- package/dist/browser/WalletWidget-XWB6VELR.js +1 -0
- package/dist/browser/chunk-273L75VZ.js +26 -0
- package/dist/browser/chunk-3AHRPZYV.js +2 -0
- package/dist/browser/chunk-5AVK5XOU.js +4 -0
- package/dist/browser/chunk-5U7AR7XV.js +1 -0
- package/dist/browser/chunk-65KT4KZW.js +1 -0
- package/dist/browser/chunk-AWLYHJ5L.js +2 -0
- package/dist/browser/chunk-BVF4MRFQ.js +2 -0
- package/dist/browser/chunk-DVUYKTGV.js +2 -0
- package/dist/browser/chunk-ECAH5RC3.js +1 -0
- package/dist/browser/chunk-EEDQFEKZ.js +2 -0
- package/dist/browser/chunk-EZWBOX2K.js +1 -0
- package/dist/browser/chunk-I3HZNWUF.js +1 -0
- package/dist/browser/chunk-JF3XWEEL.js +2 -0
- package/dist/browser/chunk-JV43EWXA.js +1 -0
- package/dist/browser/chunk-K3KIUMY7.js +1 -0
- package/dist/browser/chunk-KOBELCOG.js +1 -0
- package/dist/browser/chunk-MADECDXT.js +2 -0
- package/dist/browser/chunk-ME7FB46X.js +1 -0
- package/dist/browser/chunk-NNMZJ5NV.js +2 -0
- package/dist/browser/chunk-OPMBNAY3.js +1 -0
- package/dist/browser/chunk-P7Y5EGBN.js +1 -0
- package/dist/browser/chunk-QJTHBCR2.js +1 -0
- package/dist/browser/chunk-QPOHDTWR.js +12 -0
- package/dist/browser/chunk-R5TRMOBS.js +1 -0
- package/dist/browser/chunk-R7NCCCUY.js +1 -0
- package/dist/browser/chunk-RTSPX46P.js +1 -0
- package/dist/browser/chunk-UNEH2WXY.js +1 -0
- package/dist/browser/chunk-UNLLKACC.js +1 -0
- package/dist/browser/chunk-WCTMM2S2.js +2 -0
- package/dist/browser/chunk-WWUSGIQB.js +2 -0
- package/dist/browser/chunk-XE2T4YRZ.js +2 -0
- package/dist/browser/chunk-Y7N65KJX.js +1 -0
- package/dist/browser/chunk-YOCWSYBR.js +1 -0
- package/dist/browser/chunk-Z52PVTUZ.js +2 -0
- package/dist/browser/index.cdn.js +2611 -0
- package/dist/browser/index.js +14 -0
- package/dist/node/AddTokensWidget-JVV5SAXW.js +1 -0
- package/dist/node/AddTokensWidget-LS55AEAX.cjs +1 -0
- package/dist/node/BridgeWidget-ANWHTETV.cjs +1 -0
- package/dist/node/BridgeWidget-BEHWLY4M.js +1 -0
- package/dist/node/CommerceWidget-572UHGHP.js +1 -0
- package/dist/node/CommerceWidget-RJBIBYDR.cjs +1 -0
- package/dist/node/ConnectWidget-KSU76TQZ.cjs +1 -0
- package/dist/node/ConnectWidget-SUTP57IU.js +1 -0
- package/dist/node/OnRampWidget-KWATCRL6.cjs +1 -0
- package/dist/node/OnRampWidget-XTLZQCYU.js +1 -0
- package/dist/node/SaleWidget-AKMOR4MS.cjs +1 -0
- package/dist/node/SaleWidget-MHO7WXRH.js +1 -0
- package/dist/node/SwapWidget-MNOU735K.js +1 -0
- package/dist/node/SwapWidget-OAO2LUH7.cjs +1 -0
- package/dist/node/WalletWidget-3O2ZGGS3.js +1 -0
- package/dist/node/WalletWidget-6EVH2BKX.cjs +1 -0
- package/dist/node/chunk-22SKYDXN.cjs +13 -0
- package/dist/node/chunk-2MYO4ISV.js +13 -0
- package/dist/node/chunk-3U2JWMZP.js +1 -0
- package/dist/node/chunk-3YTH4LI4.js +1 -0
- package/dist/node/chunk-4IFPHDUT.js +1 -0
- package/dist/node/chunk-6H2BBDML.js +1 -0
- package/dist/node/chunk-6TWJH2AM.js +1 -0
- package/dist/node/chunk-7UY5KYHG.cjs +1 -0
- package/dist/node/chunk-AAYNER66.js +1 -0
- package/dist/node/chunk-AIYMKAUY.cjs +1 -0
- package/dist/node/chunk-BYAQUPEK.js +1 -0
- package/dist/node/chunk-C6FRHKWB.js +2 -0
- package/dist/node/chunk-CB2MUIJZ.cjs +1 -0
- package/dist/node/chunk-FNPSTVDH.cjs +1 -0
- package/dist/node/chunk-GLDQ7MF4.js +1 -0
- package/dist/node/chunk-GNHN2ICF.cjs +1 -0
- package/dist/node/chunk-HDLNJM65.js +1 -0
- package/dist/node/chunk-HI6MCAVV.cjs +1 -0
- package/dist/node/chunk-HZLDGMYD.js +1 -0
- package/dist/node/chunk-HZNOURGW.js +1 -0
- package/dist/node/chunk-JKILWATI.js +1 -0
- package/dist/node/chunk-K52NEJW2.cjs +1 -0
- package/dist/node/chunk-KGOQ6VFE.js +1 -0
- package/dist/node/chunk-KNH42REY.js +1 -0
- package/dist/node/chunk-KSTBNWCA.js +1 -0
- package/dist/node/chunk-KWBEZYZZ.cjs +1 -0
- package/dist/node/chunk-LJK7NSTD.js +1 -0
- package/dist/node/chunk-MD2VWWAQ.js +1 -0
- package/dist/node/chunk-MKJ4R6WO.cjs +1 -0
- package/dist/node/chunk-NZFR53NE.cjs +1 -0
- package/dist/node/chunk-OQQYEFTA.js +1 -0
- package/dist/node/chunk-OXPQRBCG.js +1 -0
- package/dist/node/chunk-PBOKGTIX.cjs +1 -0
- package/dist/node/chunk-PH7MBID7.cjs +2 -0
- package/dist/node/chunk-PUPRBAZB.cjs +1 -0
- package/dist/node/chunk-QCLRQLDO.cjs +1 -0
- package/dist/node/chunk-QHSNFLEV.cjs +1 -0
- package/dist/node/chunk-QRVHE5Y7.cjs +1 -0
- package/dist/node/chunk-QYNUE7DW.js +1 -0
- package/dist/node/chunk-RA25BPS6.cjs +1 -0
- package/dist/node/chunk-RJ7GFDCE.cjs +26 -0
- package/dist/node/chunk-RLN6G3DA.js +1 -0
- package/dist/node/chunk-ROFHVMKI.cjs +1 -0
- package/dist/node/chunk-RXF5UFTS.cjs +1 -0
- package/dist/node/chunk-SLZNA32D.cjs +1 -0
- package/dist/node/chunk-TR6RIRY5.js +1 -0
- package/dist/node/chunk-U35NC4YR.js +1 -0
- package/dist/node/chunk-U3UYGXTO.cjs +1 -0
- package/dist/node/chunk-U5NIPQGN.js +1 -0
- package/dist/node/chunk-UAFMLOWU.cjs +1 -0
- package/dist/node/chunk-UQ6XJRZD.cjs +1 -0
- package/dist/node/chunk-VBZYATUZ.cjs +1 -0
- package/dist/node/chunk-VRNYQKKE.js +1 -0
- package/dist/node/chunk-WFETTIGN.cjs +1 -0
- package/dist/node/chunk-WM3DCFTT.cjs +1 -0
- package/dist/node/chunk-WMW6GDIT.cjs +1 -0
- package/dist/node/chunk-WRCRJRRN.cjs +1 -0
- package/dist/node/chunk-WX7AXFHF.js +1 -0
- package/dist/node/chunk-XOR3FOOQ.cjs +1 -0
- package/dist/node/chunk-XPPN74JV.js +1 -0
- package/dist/node/chunk-Y4BXGSPS.cjs +1 -0
- package/dist/node/chunk-YWKKC4WT.cjs +1 -0
- package/dist/node/chunk-YZP7VIZZ.js +1 -0
- package/dist/node/chunk-Z3BWDS2L.js +1 -0
- package/dist/node/chunk-ZDBKUGOB.js +26 -0
- package/dist/node/chunk-ZESSPNGI.js +1 -0
- package/dist/node/chunk-ZHUX33PW.cjs +1 -0
- package/dist/node/chunk-ZMA2BB4P.js +1 -0
- package/dist/node/index.cjs +13 -0
- package/dist/node/index.js +13 -0
- package/dist/types/components/Body/SimpleTextBody.d.ts +5 -0
- package/dist/types/components/Body/SimpleTextBodyStyles.d.ts +10 -0
- package/dist/types/components/CenteredBoxContent/CenteredBoxContent.d.ts +5 -0
- package/dist/types/components/CenteredBoxContent/CenteredBoxStyles.d.ts +6 -0
- package/dist/types/components/ChangedYourMindDrawer/ChangedYourMindDrawer.d.ts +8 -0
- package/dist/types/components/CoinSelector/CoinSelector.d.ts +12 -0
- package/dist/types/components/CoinSelector/CoinSelectorOption.d.ts +15 -0
- package/dist/types/components/CoinSelector/CoinSelectorStyles.d.ts +12 -0
- package/dist/types/components/ConnectLoader/ConnectLoader.d.ts +21 -0
- package/dist/types/components/ConnectLoader/ConnectLoaderSuccess.d.ts +5 -0
- package/dist/types/components/EOAWarningDrawer/EOAWarningDrawer.d.ts +5 -0
- package/dist/types/components/Fees/FeeStyles.d.ts +18 -0
- package/dist/types/components/Fees/Fees.d.ts +14 -0
- package/dist/types/components/FeesBreakdown/FeeItem.d.ts +9 -0
- package/dist/types/components/FeesBreakdown/FeesBreakdown.d.ts +13 -0
- package/dist/types/components/FeesBreakdown/FeesBreakdownStyles.d.ts +28 -0
- package/dist/types/components/Footer/FooterButton.d.ts +9 -0
- package/dist/types/components/Footer/FooterLogo.d.ts +4 -0
- package/dist/types/components/Footer/FooterStyles.d.ts +41 -0
- package/dist/types/components/Footer/QuickswapFooter.d.ts +7 -0
- package/dist/types/components/FormComponents/FormControlWrapper/FormControlWrapper.d.ts +12 -0
- package/dist/types/components/FormComponents/SelectForm/SelectForm.d.ts +21 -0
- package/dist/types/components/FormComponents/SelectInput/SelectInput.d.ts +34 -0
- package/dist/types/components/FormComponents/SelectInput/SelectInputStyles.d.ts +12 -0
- package/dist/types/components/FormComponents/TextInputForm/TextInputForm.d.ts +21 -0
- package/dist/types/components/Handover/Handover.d.ts +5 -0
- package/dist/types/components/Handover/HandoverAnimation.d.ts +4 -0
- package/dist/types/components/Handover/HandoverContent.d.ts +9 -0
- package/dist/types/components/Header/HeaderNavigation.d.ts +10 -0
- package/dist/types/components/Header/HeaderStyles.d.ts +6 -0
- package/dist/types/components/Hero/BridgeHero.d.ts +1 -0
- package/dist/types/components/Hero/CreditCardWarningHero.d.ts +1 -0
- package/dist/types/components/Hero/EthereumPlanetHero.d.ts +1 -0
- package/dist/types/components/Hero/HeroImageStyles.d.ts +19 -0
- package/dist/types/components/Hero/IMXCoinsHero.d.ts +1 -0
- package/dist/types/components/Hero/ImmutablePlanetHero.d.ts +1 -0
- package/dist/types/components/Hero/MetamaskConnectHero.d.ts +1 -0
- package/dist/types/components/Hero/NoServiceHero.d.ts +1 -0
- package/dist/types/components/Hero/PassportConnectHero.d.ts +1 -0
- package/dist/types/components/Hero/RocketHero.d.ts +6 -0
- package/dist/types/components/Hero/SanctionsHero.d.ts +1 -0
- package/dist/types/components/Hero/SatelliteHero.d.ts +1 -0
- package/dist/types/components/Hero/SpendingCapHero.d.ts +1 -0
- package/dist/types/components/Hero/TransferAssetsL1WarningHero.d.ts +1 -0
- package/dist/types/components/Hero/WalletApproveHero.d.ts +1 -0
- package/dist/types/components/Hero/WalletWarningHero.d.ts +1 -0
- package/dist/types/components/Hero/WarningHero.d.ts +1 -0
- package/dist/types/components/NetworkSwitchDrawer/NetworkSwitchDrawer.d.ts +10 -0
- package/dist/types/components/NotEnoughGas/NotEnoughGas.d.ts +11 -0
- package/dist/types/components/NotEnoughGas/NotEnoughGasStyles.d.ts +40 -0
- package/dist/types/components/NotEnoughImx/NotEnoughImx.d.ts +11 -0
- package/dist/types/components/NotEnoughImx/NotEnoughImxStyles.d.ts +33 -0
- package/dist/types/components/RawImage/RawImage.d.ts +6 -0
- package/dist/types/components/RawImage/RawImageStyles.d.ts +22 -0
- package/dist/types/components/SimpleLayout/SimpleLayout.d.ts +13 -0
- package/dist/types/components/SimpleLayout/SimpleLayoutStyles.d.ts +49 -0
- package/dist/types/components/Status/StatusBox.d.ts +7 -0
- package/dist/types/components/Status/StatusType.d.ts +7 -0
- package/dist/types/components/Status/StatusView.d.ts +14 -0
- package/dist/types/components/Status/StatusViewStyles.d.ts +22 -0
- package/dist/types/components/ThemeProvider/ThemeProvider.d.ts +10 -0
- package/dist/types/components/ThemeProvider/themeProviderStyles.d.ts +9 -0
- package/dist/types/components/TokenImage/TokenImage.d.ts +19 -0
- package/dist/types/components/TransactionRejected/TransactionRejected.d.ts +8 -0
- package/dist/types/components/TransactionRejected/TransactionRejectedStyles.d.ts +26 -0
- package/dist/types/components/Transactions/ChangeWallet.d.ts +4 -0
- package/dist/types/components/Transactions/ChangeWalletStyles.d.ts +31 -0
- package/dist/types/components/Transactions/ClaimWithdrawalInProgress.d.ts +6 -0
- package/dist/types/components/Transactions/EmptyStateNotConnected.d.ts +5 -0
- package/dist/types/components/Transactions/EmptyStateNotConnectedStyles.d.ts +10 -0
- package/dist/types/components/Transactions/NoTransactions.d.ts +8 -0
- package/dist/types/components/Transactions/NotEnoughEthToWithdraw.d.ts +6 -0
- package/dist/types/components/Transactions/NotEnoughEthToWithdrawStyles.d.ts +37 -0
- package/dist/types/components/Transactions/Shimmer.d.ts +1 -0
- package/dist/types/components/Transactions/SupportMessage.d.ts +7 -0
- package/dist/types/components/Transactions/SupportMessageStyles.d.ts +9 -0
- package/dist/types/components/Transactions/TransactionDetails.d.ts +7 -0
- package/dist/types/components/Transactions/TransactionItem.d.ts +18 -0
- package/dist/types/components/Transactions/TransactionItemWithdrawPending.d.ts +13 -0
- package/dist/types/components/Transactions/TransactionList.d.ts +13 -0
- package/dist/types/components/Transactions/TransactionListStyles.d.ts +16 -0
- package/dist/types/components/Transactions/Transactions.d.ts +6 -0
- package/dist/types/components/Transactions/TransactionsStyles.d.ts +26 -0
- package/dist/types/components/Transactions/noTransactionStyles.d.ts +26 -0
- package/dist/types/components/Transactions/transactionItemStyles.d.ts +30 -0
- package/dist/types/components/Transactions/transactionsType.d.ts +6 -0
- package/dist/types/components/Transak/TransakEvents.d.ts +42 -0
- package/dist/types/components/Transak/TransakIframe.d.ts +13 -0
- package/dist/types/components/Transak/TransakTypes.d.ts +9 -0
- package/dist/types/components/Transak/useTransakEvents.d.ts +24 -0
- package/dist/types/components/Transak/useTransakIframe.d.ts +41 -0
- package/dist/types/components/UnableToConnectDrawer/UnableToConnectDrawer.d.ts +8 -0
- package/dist/types/components/WalletDrawer/ConnectWalletDrawer.d.ts +23 -0
- package/dist/types/components/WalletDrawer/DeliverToWalletDrawer.d.ts +9 -0
- package/dist/types/components/WalletDrawer/PayWithWalletDrawer.d.ts +12 -0
- package/dist/types/components/WalletDrawer/WalletConnectItem.d.ts +7 -0
- package/dist/types/components/WalletDrawer/WalletDrawer.d.ts +25 -0
- package/dist/types/components/WalletDrawer/WalletDrawerEvents.d.ts +6 -0
- package/dist/types/components/WalletDrawer/WalletDrawerStyles.d.ts +7 -0
- package/dist/types/components/WalletDrawer/WalletItem.d.ts +15 -0
- package/dist/types/components/WithdrawalQueueDrawer/WithdrawalQueueDrawer.d.ts +14 -0
- package/dist/types/context/analytics-provider/CustomAnalyticsProvider.d.ts +7 -0
- package/dist/types/context/analytics-provider/SegmentAnalyticsProvider.d.ts +42 -0
- package/dist/types/context/analytics-provider/SetupAnalytics.d.ts +7 -0
- package/dist/types/context/connect-loader-context/ConnectLoader.test.d.ts +1 -0
- package/dist/types/context/connect-loader-context/ConnectLoaderContext.d.ts +48 -0
- package/dist/types/context/connect-loader-context/test-components/ConnectLoaderTestComponent.d.ts +7 -0
- package/dist/types/context/crypto-fiat-context/CryptoFiat.d.ts +4 -0
- package/dist/types/context/crypto-fiat-context/CryptoFiatContext.d.ts +45 -0
- package/dist/types/context/crypto-fiat-context/CryptoFiatContext.test.d.ts +1 -0
- package/dist/types/context/crypto-fiat-context/CryptoFiatProvider.d.ts +9 -0
- package/dist/types/context/crypto-fiat-context/test-components/CryptoFiatTestComponent.d.ts +5 -0
- package/dist/types/context/event-target-context/EventTarget.test.d.ts +1 -0
- package/dist/types/context/event-target-context/EventTargetContext.d.ts +24 -0
- package/dist/types/context/event-target-context/test-components/EventTargetTestComponent.d.ts +7 -0
- package/dist/types/context/handover-context/HandoverContext.d.ts +29 -0
- package/dist/types/context/handover-context/HandoverProvider.d.ts +11 -0
- package/dist/types/context/providers-context/ProvidersContext.d.ts +59 -0
- package/dist/types/context/view-context/AddTokensViewContextTypes.d.ts +29 -0
- package/dist/types/context/view-context/BridgeViewContextTypes.d.ts +66 -0
- package/dist/types/context/view-context/CheckoutWidgetViewContextTypes.d.ts +53 -0
- package/dist/types/context/view-context/ConnectViewContextTypes.d.ts +18 -0
- package/dist/types/context/view-context/OnRampViewContextTypes.d.ts +35 -0
- package/dist/types/context/view-context/PurchaseViewContextTypes.d.ts +20 -0
- package/dist/types/context/view-context/SaleViewContextTypes.d.ts +44 -0
- package/dist/types/context/view-context/SwapViewContextTypes.d.ts +64 -0
- package/dist/types/context/view-context/ViewContext.d.ts +75 -0
- package/dist/types/context/view-context/ViewContext.test.d.ts +1 -0
- package/dist/types/context/view-context/ViewType.d.ts +4 -0
- package/dist/types/context/view-context/WalletViewContextTypes.d.ts +26 -0
- package/dist/types/context/view-context/test-components/ViewContextTestComponent.d.ts +7 -0
- package/dist/types/factory.d.ts +9 -0
- package/dist/types/hooks/useMount.d.ts +9 -0
- package/dist/types/i18n.d.ts +2 -0
- package/dist/types/index.d.ts +1 -0
- package/dist/types/lib/addressUtils.d.ts +1 -0
- package/dist/types/lib/addressUtils.test.d.ts +1 -0
- package/dist/types/lib/analytics/identifyUser.d.ts +8 -0
- package/dist/types/lib/analytics/identifyUser.test.d.ts +1 -0
- package/dist/types/lib/animation/listAnimation.d.ts +23 -0
- package/dist/types/lib/async/cancellablePromise.d.ts +19 -0
- package/dist/types/lib/async/cancellablePromise.test.d.ts +1 -0
- package/dist/types/lib/balance.d.ts +15 -0
- package/dist/types/lib/balance.test.d.ts +1 -0
- package/dist/types/lib/chains.d.ts +5 -0
- package/dist/types/lib/chains.test.d.ts +1 -0
- package/dist/types/lib/clients/checkoutApi.d.ts +39 -0
- package/dist/types/lib/clients/checkoutApi.test.d.ts +1 -0
- package/dist/types/lib/clients/checkoutApiType.d.ts +34 -0
- package/dist/types/lib/clients/index.d.ts +2 -0
- package/dist/types/lib/connectEIP6963Provider.d.ts +10 -0
- package/dist/types/lib/constants.d.ts +88 -0
- package/dist/types/lib/eip1193Events.d.ts +12 -0
- package/dist/types/lib/feeEstimation.d.ts +5 -0
- package/dist/types/lib/feeEstimation.test.d.ts +1 -0
- package/dist/types/lib/fetchTokenSymbols.d.ts +2 -0
- package/dist/types/lib/fetchTokenSymbols.test.d.ts +1 -0
- package/dist/types/lib/gasBalanceCheck.d.ts +2 -0
- package/dist/types/lib/gasBalanceCheck.test.d.ts +1 -0
- package/dist/types/lib/hooks/useAsyncMemo.d.ts +5 -0
- package/dist/types/lib/hooks/useBalance.d.ts +11 -0
- package/dist/types/lib/hooks/useDebounce.d.ts +2 -0
- package/dist/types/lib/hooks/useHandover.d.ts +12 -0
- package/dist/types/lib/hooks/useInjectedProviders.d.ts +16 -0
- package/dist/types/lib/hooks/useInterval.d.ts +1 -0
- package/dist/types/lib/hooks/useIsSmallScreen.d.ts +4 -0
- package/dist/types/lib/hooks/usePortalId.d.ts +1 -0
- package/dist/types/lib/hooks/useQuoteOrder.d.ts +12 -0
- package/dist/types/lib/hooks/useSignOrder.d.ts +12 -0
- package/dist/types/lib/hooks/useWalletConnect.d.ts +15 -0
- package/dist/types/lib/index.d.ts +6 -0
- package/dist/types/lib/logoUtils.d.ts +3 -0
- package/dist/types/lib/metrics.d.ts +3 -0
- package/dist/types/lib/networkStyles.d.ts +22 -0
- package/dist/types/lib/networkUtils.d.ts +3 -0
- package/dist/types/lib/orchestrationEvents.d.ts +14 -0
- package/dist/types/lib/primary-sales.d.ts +221 -0
- package/dist/types/lib/provider/index.d.ts +2 -0
- package/dist/types/lib/provider/providers.d.ts +3 -0
- package/dist/types/lib/provider/providers.test.d.ts +1 -0
- package/dist/types/lib/provider/utils.d.ts +21 -0
- package/dist/types/lib/provider/utils.test.d.ts +1 -0
- package/dist/types/lib/providerEvents.d.ts +2 -0
- package/dist/types/lib/retry.d.ts +7 -0
- package/dist/types/lib/retry.test.d.ts +1 -0
- package/dist/types/lib/squid/components/SquidFooter.d.ts +1 -0
- package/dist/types/lib/squid/components/SquidIcon.d.ts +5 -0
- package/dist/types/lib/squid/config.d.ts +2 -0
- package/dist/types/lib/squid/functions/convertToUsd.d.ts +3 -0
- package/dist/types/lib/squid/functions/fetchBalances.d.ts +5 -0
- package/dist/types/lib/squid/functions/fetchChains.d.ts +9 -0
- package/dist/types/lib/squid/functions/fetchTokens.d.ts +2 -0
- package/dist/types/lib/squid/functions/getRouteAndTokenBalances.d.ts +8 -0
- package/dist/types/lib/squid/functions/getRouteChains.d.ts +12 -0
- package/dist/types/lib/squid/functions/getTotalRouteFees.d.ts +12 -0
- package/dist/types/lib/squid/functions/isSquidNativeToken.d.ts +1 -0
- package/dist/types/lib/squid/functions/sortRoutesByFastestTime.d.ts +2 -0
- package/dist/types/lib/squid/hooks/useExecute.d.ts +13 -0
- package/dist/types/lib/squid/hooks/useRoutes.d.ts +9 -0
- package/dist/types/lib/squid/hooks/useSquid.d.ts +3 -0
- package/dist/types/lib/squid/hooks/useTokens.d.ts +3 -0
- package/dist/types/lib/squid/types.d.ts +40 -0
- package/dist/types/lib/storage.d.ts +4 -0
- package/dist/types/lib/theme.d.ts +3 -0
- package/dist/types/lib/theme.test.d.ts +1 -0
- package/dist/types/lib/utils.d.ts +28 -0
- package/dist/types/lib/utils.test.d.ts +1 -0
- package/dist/types/lib/validations/amountInputValidations.d.ts +1 -0
- package/dist/types/lib/validations/amountInputValidations.test.d.ts +1 -0
- package/dist/types/lib/validations/widgetValidators.d.ts +3 -0
- package/dist/types/lib/validations/widgetValidators.test.d.ts +1 -0
- package/dist/types/lib/walletConnect.d.ts +40 -0
- package/dist/types/lib/withDefaultWidgetConfig.d.ts +11 -0
- package/dist/types/lib/withDefaultWidgetConfig.test.d.ts +1 -0
- package/dist/types/setupTests.d.ts +1 -0
- package/dist/types/views/error/ErrorView.d.ts +8 -0
- package/dist/types/views/error/ServiceUnavailableErrorView.d.ts +5 -0
- package/dist/types/views/error/ServiceUnavailableToRegionErrorView.d.ts +10 -0
- package/dist/types/views/error/serviceTypes.d.ts +5 -0
- package/dist/types/views/loading/LoadingView.d.ts +7 -0
- package/dist/types/views/top-up/TopUpMenuItem.d.ts +14 -0
- package/dist/types/views/top-up/TopUpView.d.ts +29 -0
- package/dist/types/widgets/BaseWidgetRoot.d.ts +39 -0
- package/dist/types/widgets/add-tokens/AddTokensRoot.d.ts +8 -0
- package/dist/types/widgets/add-tokens/AddTokensWidget.d.ts +6 -0
- package/dist/types/widgets/add-tokens/AddTokensWidgetEvents.d.ts +5 -0
- package/dist/types/widgets/add-tokens/components/AddressMissmatchDrawer.d.ts +5 -0
- package/dist/types/widgets/add-tokens/components/FiatOption.d.ts +11 -0
- package/dist/types/widgets/add-tokens/components/OnboardingDrawer.d.ts +5 -0
- package/dist/types/widgets/add-tokens/components/Options.d.ts +16 -0
- package/dist/types/widgets/add-tokens/components/OptionsDrawer.d.ts +17 -0
- package/dist/types/widgets/add-tokens/components/RouteFees.d.ts +9 -0
- package/dist/types/widgets/add-tokens/components/RouteOption.d.ts +14 -0
- package/dist/types/widgets/add-tokens/components/SelectedRouteOption.d.ts +14 -0
- package/dist/types/widgets/add-tokens/components/SelectedWallet.d.ts +20 -0
- package/dist/types/widgets/add-tokens/components/TokenDrawerMenu.d.ts +12 -0
- package/dist/types/widgets/add-tokens/context/AddTokensContext.d.ts +87 -0
- package/dist/types/widgets/add-tokens/functions/amountValidation.d.ts +10 -0
- package/dist/types/widgets/add-tokens/functions/checkSanctionedAddresses.d.ts +2 -0
- package/dist/types/widgets/add-tokens/functions/convertToNetworkChangeableProvider.d.ts +2 -0
- package/dist/types/widgets/add-tokens/functions/delay.d.ts +1 -0
- package/dist/types/widgets/add-tokens/functions/errorType.d.ts +1 -0
- package/dist/types/widgets/add-tokens/functions/getDurationFormatted.d.ts +1 -0
- package/dist/types/widgets/add-tokens/functions/getFormattedNumber.d.ts +9 -0
- package/dist/types/widgets/add-tokens/functions/onboardingState.d.ts +7 -0
- package/dist/types/widgets/add-tokens/hooks/useError.d.ts +5 -0
- package/dist/types/widgets/add-tokens/types.d.ts +28 -0
- package/dist/types/widgets/add-tokens/utils/animation.d.ts +1 -0
- package/dist/types/widgets/add-tokens/utils/config.d.ts +6 -0
- package/dist/types/widgets/add-tokens/views/AddTokens.d.ts +16 -0
- package/dist/types/widgets/add-tokens/views/Review.d.ts +9 -0
- package/dist/types/widgets/bridge/BridgeWidget.d.ts +8 -0
- package/dist/types/widgets/bridge/BridgeWidgetEvents.d.ts +5 -0
- package/dist/types/widgets/bridge/BridgeWidgetRoot.d.ts +8 -0
- package/dist/types/widgets/bridge/components/BridgeForm.d.ts +13 -0
- package/dist/types/widgets/bridge/components/BridgeFormStyles.d.ts +18 -0
- package/dist/types/widgets/bridge/components/BridgeReviewSummary.d.ts +1 -0
- package/dist/types/widgets/bridge/components/BridgeReviewSummaryStyles.d.ts +65 -0
- package/dist/types/widgets/bridge/components/NetworkItem.d.ts +10 -0
- package/dist/types/widgets/bridge/components/TokenSelectShimmer.d.ts +4 -0
- package/dist/types/widgets/bridge/components/WalletAndNetworkSelector.d.ts +1 -0
- package/dist/types/widgets/bridge/components/WalletAndNetworkSelectorStyles.d.ts +15 -0
- package/dist/types/widgets/bridge/components/WalletNetworkButton.d.ts +16 -0
- package/dist/types/widgets/bridge/components/WalletNetworkButtonStyles.d.ts +51 -0
- package/dist/types/widgets/bridge/context/BridgeContext.d.ts +78 -0
- package/dist/types/widgets/bridge/context/BridgeContext.test.d.ts +1 -0
- package/dist/types/widgets/bridge/functions/BridgeFees.d.ts +4 -0
- package/dist/types/widgets/bridge/functions/BridgeFormValidator.d.ts +3 -0
- package/dist/types/widgets/bridge/functions/TransferErc20.d.ts +2 -0
- package/dist/types/widgets/bridge/test-components/BridgeWidgetTestComponent.d.ts +8 -0
- package/dist/types/widgets/bridge/views/ApproveTransaction.d.ts +12 -0
- package/dist/types/widgets/bridge/views/Bridge.d.ts +8 -0
- package/dist/types/widgets/bridge/views/BridgeReview.d.ts +1 -0
- package/dist/types/widgets/bridge/views/ClaimWithdrawal.d.ts +5 -0
- package/dist/types/widgets/bridge/views/MoveInProgress.d.ts +5 -0
- package/dist/types/widgets/bridge/views/WalletNetworkSelectionView.d.ts +5 -0
- package/dist/types/widgets/connect/ConnectWidget.d.ts +16 -0
- package/dist/types/widgets/connect/ConnectWidgetRoot.d.ts +8 -0
- package/dist/types/widgets/connect/components/BrowserWalletItem.d.ts +6 -0
- package/dist/types/widgets/connect/components/NonPassportWarningDrawer.d.ts +5 -0
- package/dist/types/widgets/connect/components/WalletConnectItem.d.ts +5 -0
- package/dist/types/widgets/connect/components/WalletItem.d.ts +10 -0
- package/dist/types/widgets/connect/components/WalletList.d.ts +9 -0
- package/dist/types/widgets/connect/components/WalletListStyles.d.ts +8 -0
- package/dist/types/widgets/connect/connectWidgetEvents.d.ts +6 -0
- package/dist/types/widgets/connect/connectWidgetStyles.d.ts +17 -0
- package/dist/types/widgets/connect/context/ConnectContext.d.ts +50 -0
- package/dist/types/widgets/connect/context/ConnectContext.test.d.ts +1 -0
- package/dist/types/widgets/connect/views/ConnectWallet.d.ts +11 -0
- package/dist/types/widgets/connect/views/ReadyToConnect.d.ts +6 -0
- package/dist/types/widgets/connect/views/SwitchNetworkEth.d.ts +1 -0
- package/dist/types/widgets/connect/views/SwitchNetworkZkEVM.d.ts +1 -0
- package/dist/types/widgets/immutable-commerce/CommerceWidget.d.ts +10 -0
- package/dist/types/widgets/immutable-commerce/CommerceWidgetEvents.d.ts +6 -0
- package/dist/types/widgets/immutable-commerce/CommerceWidgetRoot.d.ts +66 -0
- package/dist/types/widgets/immutable-commerce/context/CommerceContext.d.ts +37 -0
- package/dist/types/widgets/immutable-commerce/functions/deduplicateSaleItemsArray.d.ts +2 -0
- package/dist/types/widgets/immutable-commerce/functions/getCommerceWidgetEvent.d.ts +5 -0
- package/dist/types/widgets/immutable-commerce/functions/getConnectLoaderParams.d.ts +7 -0
- package/dist/types/widgets/immutable-commerce/functions/getFlowRequiresContext.d.ts +8 -0
- package/dist/types/widgets/immutable-commerce/functions/getViewFromOrchestrationEventType.d.ts +5 -0
- package/dist/types/widgets/immutable-commerce/functions/isOrchestrationEvent.d.ts +7 -0
- package/dist/types/widgets/immutable-commerce/functions/isValidCommerceFlow.d.ts +7 -0
- package/dist/types/widgets/immutable-commerce/hooks/useMount.d.ts +5 -0
- package/dist/types/widgets/immutable-commerce/hooks/useWidgetEvents.d.ts +6 -0
- package/dist/types/widgets/on-ramp/OnRampWidget.d.ts +6 -0
- package/dist/types/widgets/on-ramp/OnRampWidgetEvents.d.ts +3 -0
- package/dist/types/widgets/on-ramp/OnRampWidgetRoot.d.ts +9 -0
- package/dist/types/widgets/on-ramp/TransakEvents.d.ts +19 -0
- package/dist/types/widgets/on-ramp/views/OnRampMain.d.ts +10 -0
- package/dist/types/widgets/on-ramp/views/OrderInProgress.d.ts +1 -0
- package/dist/types/widgets/on-ramp/views/onRampStyles.d.ts +14 -0
- package/dist/types/widgets/purchase/PurchaseWidget.d.ts +6 -0
- package/dist/types/widgets/purchase/PurchaseWidgetEvents.d.ts +5 -0
- package/dist/types/widgets/purchase/PurchaseWidgetRoot.d.ts +8 -0
- package/dist/types/widgets/purchase/context/PurchaseContext.d.ts +24 -0
- package/dist/types/widgets/purchase/types.d.ts +0 -0
- package/dist/types/widgets/purchase/views/Purchase.d.ts +7 -0
- package/dist/types/widgets/purchase/views/Review.d.ts +1 -0
- package/dist/types/widgets/sale/SaleWidget.d.ts +13 -0
- package/dist/types/widgets/sale/SaleWidgetEvents.d.ts +8 -0
- package/dist/types/widgets/sale/SaleWidgetRoot.d.ts +10 -0
- package/dist/types/widgets/sale/components/CoinsDrawer.d.ts +19 -0
- package/dist/types/widgets/sale/components/CoinsDrawerItem.d.ts +17 -0
- package/dist/types/widgets/sale/components/CreditCardWarningDrawer.d.ts +1 -0
- package/dist/types/widgets/sale/components/FundingRouteExecute/FundingRouteExecute.d.ts +7 -0
- package/dist/types/widgets/sale/components/OrderFees.d.ts +15 -0
- package/dist/types/widgets/sale/components/OrderItem.d.ts +14 -0
- package/dist/types/widgets/sale/components/OrderItems.d.ts +12 -0
- package/dist/types/widgets/sale/components/OrderReview.d.ts +15 -0
- package/dist/types/widgets/sale/components/PaymentOption.d.ts +12 -0
- package/dist/types/widgets/sale/components/PaymentOptions.d.ts +11 -0
- package/dist/types/widgets/sale/components/SelectCoinDropdown.d.ts +13 -0
- package/dist/types/widgets/sale/components/WithCard.d.ts +9 -0
- package/dist/types/widgets/sale/context/SaleContextProvider.d.ts +57 -0
- package/dist/types/widgets/sale/functions/fetchFundingBalances.d.ts +20 -0
- package/dist/types/widgets/sale/functions/fetchFundingBalancesUtils.d.ts +12 -0
- package/dist/types/widgets/sale/functions/fetchFundingBalancesUtils.test.d.ts +4 -0
- package/dist/types/widgets/sale/functions/fundingBalanceFees.d.ts +7 -0
- package/dist/types/widgets/sale/functions/fundingBalanceFees.test.d.ts +2 -0
- package/dist/types/widgets/sale/functions/getTopUpViewData.d.ts +16 -0
- package/dist/types/widgets/sale/functions/getTopUpViewData.test.d.ts +1 -0
- package/dist/types/widgets/sale/functions/signUtils.d.ts +3 -0
- package/dist/types/widgets/sale/functions/transformToOrderQuote.d.ts +28 -0
- package/dist/types/widgets/sale/functions/transformToOrderQuote.test.d.ts +1 -0
- package/dist/types/widgets/sale/functions/utils.d.ts +5 -0
- package/dist/types/widgets/sale/functions/utils.test.d.ts +1 -0
- package/dist/types/widgets/sale/hooks/useFundingBalances.d.ts +10 -0
- package/dist/types/widgets/sale/hooks/useHandoverSteps.d.ts +26 -0
- package/dist/types/widgets/sale/hooks/useQuoteOrder.d.ts +21 -0
- package/dist/types/widgets/sale/hooks/useSaleEvents.d.ts +36 -0
- package/dist/types/widgets/sale/hooks/useSignOrder.d.ts +12 -0
- package/dist/types/widgets/sale/types.d.ts +119 -0
- package/dist/types/widgets/sale/utils/analytics.d.ts +3 -0
- package/dist/types/widgets/sale/utils/config.d.ts +4 -0
- package/dist/types/widgets/sale/utils/pricing.d.ts +2 -0
- package/dist/types/widgets/sale/utils/pricing.test.d.ts +1 -0
- package/dist/types/widgets/sale/views/LoadingHandover.d.ts +7 -0
- package/dist/types/widgets/sale/views/OrderSummary.d.ts +6 -0
- package/dist/types/widgets/sale/views/PayWithCard.d.ts +1 -0
- package/dist/types/widgets/sale/views/PayWithCoins.d.ts +1 -0
- package/dist/types/widgets/sale/views/PaymentMethods.d.ts +1 -0
- package/dist/types/widgets/sale/views/SaleErrorView.d.ts +10 -0
- package/dist/types/widgets/swap/GeoblockLoader.d.ts +8 -0
- package/dist/types/widgets/swap/SwapStyles.d.ts +26 -0
- package/dist/types/widgets/swap/SwapWidget.d.ts +6 -0
- package/dist/types/widgets/swap/SwapWidgetEvents.d.ts +4 -0
- package/dist/types/widgets/swap/SwapWidgetRoot.d.ts +10 -0
- package/dist/types/widgets/swap/components/SwapButton.d.ts +6 -0
- package/dist/types/widgets/swap/components/SwapButtonStyles.d.ts +9 -0
- package/dist/types/widgets/swap/components/SwapForm.d.ts +8 -0
- package/dist/types/widgets/swap/components/TokenSelect.d.ts +10 -0
- package/dist/types/widgets/swap/components/UnableToSwap.d.ts +6 -0
- package/dist/types/widgets/swap/components/UnableToSwapStyles.d.ts +40 -0
- package/dist/types/widgets/swap/components/swapFormTypes.d.ts +8 -0
- package/dist/types/widgets/swap/context/SwapContext.d.ts +73 -0
- package/dist/types/widgets/swap/context/SwapContext.test.d.ts +6 -0
- package/dist/types/widgets/swap/functions/FetchQuote.d.ts +6 -0
- package/dist/types/widgets/swap/functions/FetchQuote.test.d.ts +1 -0
- package/dist/types/widgets/swap/functions/SwapValidator.d.ts +5 -0
- package/dist/types/widgets/swap/functions/SwapValidator.test.d.ts +1 -0
- package/dist/types/widgets/swap/functions/processGasFree.d.ts +8 -0
- package/dist/types/widgets/swap/functions/processGasFree.test.d.ts +1 -0
- package/dist/types/widgets/swap/functions/processQuoteToken.d.ts +8 -0
- package/dist/types/widgets/swap/functions/processSecondaryFees.d.ts +10 -0
- package/dist/types/widgets/swap/functions/processSecondaryFees.test.d.ts +1 -0
- package/dist/types/widgets/swap/functions/swapConversionRate.d.ts +4 -0
- package/dist/types/widgets/swap/functions/swapConversionRate.test.d.ts +1 -0
- package/dist/types/widgets/swap/functions/swapFees.d.ts +18 -0
- package/dist/types/widgets/swap/functions/swapFees.test.d.ts +1 -0
- package/dist/types/widgets/swap/helpers.d.ts +10 -0
- package/dist/types/widgets/swap/test-components/SwapWidgetTestComponent.d.ts +8 -0
- package/dist/types/widgets/swap/views/ApproveERC20Onboarding.d.ts +5 -0
- package/dist/types/widgets/swap/views/SwapCoins.d.ts +11 -0
- package/dist/types/widgets/swap/views/SwapInProgress.d.ts +8 -0
- package/dist/types/widgets/wallet/WalletWidget.d.ts +8 -0
- package/dist/types/widgets/wallet/WalletWidgetEvents.d.ts +4 -0
- package/dist/types/widgets/wallet/WalletWidgetRoot.d.ts +8 -0
- package/dist/types/widgets/wallet/components/BalanceItem/BalanceItem.d.ts +8 -0
- package/dist/types/widgets/wallet/components/BalanceItem/BalanceItemStyles.d.ts +3 -0
- package/dist/types/widgets/wallet/components/NetworkMenu/NetworkMenu.d.ts +1 -0
- package/dist/types/widgets/wallet/components/NetworkMenu/NetworkMenuStyles.d.ts +22 -0
- package/dist/types/widgets/wallet/components/TokenBalanceList/TokenBalanceList.d.ts +9 -0
- package/dist/types/widgets/wallet/components/TokenBalanceList/TokenBalanceListStyles.d.ts +14 -0
- package/dist/types/widgets/wallet/components/TotalTokenBalance/TotalTokenBalance.d.ts +6 -0
- package/dist/types/widgets/wallet/components/TotalTokenBalance/TotalTokenBalanceStyles.d.ts +20 -0
- package/dist/types/widgets/wallet/components/TransferAssetsL1Warning.d.ts +6 -0
- package/dist/types/widgets/wallet/components/WalletAddress/WalletAddress.d.ts +6 -0
- package/dist/types/widgets/wallet/context/WalletContext.d.ts +54 -0
- package/dist/types/widgets/wallet/context/WalletContext.test.d.ts +1 -0
- package/dist/types/widgets/wallet/functions/tokenBalances.d.ts +12 -0
- package/dist/types/widgets/wallet/functions/tokenBalances.test.d.ts +1 -0
- package/dist/types/widgets/wallet/test-components/WalletWidgetTestComponent.d.ts +8 -0
- package/dist/types/widgets/wallet/tokenDataStub.d.ts +6 -0
- package/dist/types/widgets/wallet/views/CoinInfo.d.ts +1 -0
- package/dist/types/widgets/wallet/views/Settings.d.ts +4 -0
- package/dist/types/widgets/wallet/views/SettingsStyles.d.ts +9 -0
- package/dist/types/widgets/wallet/views/WalletBalances.d.ts +8 -0
- package/dist/types/widgets/wallet/views/WalletBalancesStyles.d.ts +23 -0
- package/package.json +116 -0
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { TokenInfo } from '@imtbl/checkout-sdk';
|
|
2
|
+
import { TransactionResponse } from '@imtbl/dex-sdk';
|
|
3
|
+
/**
|
|
4
|
+
* Ensures that the fees token has the correct symbol. At the moment the dex quote doesn't return it.
|
|
5
|
+
* Assumes the fee token is the from token. If it's not, it will be incorrect.
|
|
6
|
+
* TODO: Fix this when the canonical tokens list comes into play so we can look up the symbol based on address
|
|
7
|
+
* @param fromToken Assumption is fees are delineated in this from token
|
|
8
|
+
* @param currentQuote
|
|
9
|
+
*/
|
|
10
|
+
export declare const processSecondaryFees: (fromToken: TokenInfo, currentQuote: TransactionResponse) => TransactionResponse;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { TransactionResponse } from '@imtbl/dex-sdk';
|
|
2
|
+
import { TFunction } from 'i18next';
|
|
3
|
+
import { TokenInfo } from '@imtbl/checkout-sdk';
|
|
4
|
+
export declare const formatQuoteConversionRate: (amount: string, token: TokenInfo, quote: TransactionResponse, labelKey: string, t: TFunction) => string;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { Token, TransactionResponse } from '@imtbl/dex-sdk';
|
|
2
|
+
import { TFunction } from 'i18next';
|
|
3
|
+
import { TokenInfo } from '@imtbl/checkout-sdk';
|
|
4
|
+
import { CryptoFiatState } from '../../../context/crypto-fiat-context/CryptoFiatContext';
|
|
5
|
+
export type FormattedFee = {
|
|
6
|
+
label: string;
|
|
7
|
+
fiatAmount: string;
|
|
8
|
+
amount: string;
|
|
9
|
+
prefix?: string;
|
|
10
|
+
token: Token | TokenInfo;
|
|
11
|
+
};
|
|
12
|
+
/**
|
|
13
|
+
* Formats a quote into a list of fees for the fee drawer
|
|
14
|
+
* @param swapQuote
|
|
15
|
+
* @param cryptoFiatState
|
|
16
|
+
* @param t
|
|
17
|
+
*/
|
|
18
|
+
export declare const formatSwapFees: (swapQuote: TransactionResponse, cryptoFiatState: CryptoFiatState, t: TFunction) => FormattedFee[];
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { TokenInfo } from '@imtbl/checkout-sdk';
|
|
2
|
+
export declare const alphaSortTokensList: (tokens: TokenInfo[]) => TokenInfo[];
|
|
3
|
+
export declare const topUpBridgeOption: (isBridgeEnabled: boolean, isNotPassport: boolean) => {
|
|
4
|
+
textKey: string;
|
|
5
|
+
action: () => void;
|
|
6
|
+
} | undefined;
|
|
7
|
+
export declare const topUpOnRampOption: (isOnRampEnabled: boolean) => {
|
|
8
|
+
textKey: string;
|
|
9
|
+
action: () => void;
|
|
10
|
+
} | undefined;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { SwapState } from '../context/SwapContext';
|
|
3
|
+
export interface TestProps {
|
|
4
|
+
children: React.ReactNode;
|
|
5
|
+
initialStateOverride?: SwapState;
|
|
6
|
+
cryptoConversionsOverride?: Map<string, number>;
|
|
7
|
+
}
|
|
8
|
+
export declare function SwapWidgetTestComponent({ children, initialStateOverride, cryptoConversionsOverride }: TestProps): import("@emotion/react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { ApproveERC20SwapData } from '../../../context/view-context/SwapViewContextTypes';
|
|
2
|
+
export interface ApproveERC20Props {
|
|
3
|
+
data: ApproveERC20SwapData;
|
|
4
|
+
}
|
|
5
|
+
export declare function ApproveERC20Onboarding({ data }: ApproveERC20Props): import("@emotion/react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { WidgetTheme } from '@imtbl/checkout-sdk';
|
|
2
|
+
export interface SwapCoinsProps {
|
|
3
|
+
theme: WidgetTheme;
|
|
4
|
+
cancelAutoProceed: () => void;
|
|
5
|
+
fromAmount?: string;
|
|
6
|
+
toAmount?: string;
|
|
7
|
+
fromTokenAddress?: string;
|
|
8
|
+
toTokenAddress?: string;
|
|
9
|
+
showBackButton?: boolean;
|
|
10
|
+
}
|
|
11
|
+
export declare function SwapCoins({ theme, cancelAutoProceed, fromAmount, toAmount, fromTokenAddress, toTokenAddress, showBackButton, }: SwapCoinsProps): import("@emotion/react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { TransactionResponse } from 'ethers';
|
|
2
|
+
import { PrefilledSwapForm } from '../../../context/view-context/SwapViewContextTypes';
|
|
3
|
+
interface SwapInProgressProps {
|
|
4
|
+
transactionResponse: TransactionResponse;
|
|
5
|
+
swapForm: PrefilledSwapForm;
|
|
6
|
+
}
|
|
7
|
+
export declare function SwapInProgress({ transactionResponse, swapForm, }: SwapInProgressProps): import("@emotion/react/jsx-runtime").JSX.Element;
|
|
8
|
+
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { WalletWidgetParams } from '@imtbl/checkout-sdk';
|
|
2
|
+
import { WalletConfiguration } from './context/WalletContext';
|
|
3
|
+
import { StrongCheckoutWidgetsConfig } from '../../lib/withDefaultWidgetConfig';
|
|
4
|
+
export type WalletWidgetInputs = WalletWidgetParams & {
|
|
5
|
+
config: StrongCheckoutWidgetsConfig;
|
|
6
|
+
walletConfig: WalletConfiguration;
|
|
7
|
+
};
|
|
8
|
+
export default function WalletWidget(props: WalletWidgetInputs): import("@emotion/react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { NetworkInfo, WrappedBrowserProvider } from '@imtbl/checkout-sdk';
|
|
2
|
+
export declare function sendWalletWidgetCloseEvent(eventTarget: Window | EventTarget): void;
|
|
3
|
+
export declare function sendNetworkSwitchEvent(eventTarget: Window | EventTarget, provider: WrappedBrowserProvider, network: NetworkInfo): void;
|
|
4
|
+
export declare function sendDisconnectWalletEvent(eventTarget: Window | EventTarget): void;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { IMTBLWidgetEvents, WalletWidgetParams, WidgetProperties, WidgetType } from '@imtbl/checkout-sdk';
|
|
2
|
+
import { Base } from '../BaseWidgetRoot';
|
|
3
|
+
export declare class Wallet extends Base<WidgetType.WALLET> {
|
|
4
|
+
protected eventTopic: IMTBLWidgetEvents;
|
|
5
|
+
protected getValidatedProperties({ config }: WidgetProperties<WidgetType.WALLET>): WidgetProperties<WidgetType.WALLET>;
|
|
6
|
+
protected getValidatedParameters(params: WalletWidgetParams): WalletWidgetParams;
|
|
7
|
+
protected render(): void;
|
|
8
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { WidgetTheme } from '@imtbl/checkout-sdk';
|
|
2
|
+
import { BalanceInfo } from '../../functions/tokenBalances';
|
|
3
|
+
export interface BalanceItemProps {
|
|
4
|
+
balanceInfo: BalanceInfo;
|
|
5
|
+
theme: WidgetTheme;
|
|
6
|
+
bridgeToL2OnClick: (address?: string) => void;
|
|
7
|
+
}
|
|
8
|
+
export declare function BalanceItem({ balanceInfo, theme, bridgeToL2OnClick, }: BalanceItemProps): import("@emotion/react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function NetworkMenu(): import("@emotion/react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
export declare const networkMenuStyles: {
|
|
2
|
+
display: string;
|
|
3
|
+
flexDirection: string;
|
|
4
|
+
alignItems: string;
|
|
5
|
+
paddingTop: string;
|
|
6
|
+
};
|
|
7
|
+
export declare const activeNetworkButtonStyle: {
|
|
8
|
+
fontWeight: string;
|
|
9
|
+
borderColor: string;
|
|
10
|
+
borderStyle: string;
|
|
11
|
+
borderWidth: string;
|
|
12
|
+
};
|
|
13
|
+
export declare const networkButtonStyle: {
|
|
14
|
+
fontWeight: string;
|
|
15
|
+
};
|
|
16
|
+
export declare const logoStyle: (isActive: boolean) => {
|
|
17
|
+
filter: string | undefined;
|
|
18
|
+
};
|
|
19
|
+
export declare const networkHeadingStyle: {
|
|
20
|
+
paddingX: string;
|
|
21
|
+
paddingY: string;
|
|
22
|
+
};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { WidgetTheme } from '@imtbl/checkout-sdk';
|
|
2
|
+
import { BalanceInfo } from '../../functions/tokenBalances';
|
|
3
|
+
interface TokenBalanceListProps {
|
|
4
|
+
balanceInfoItems: BalanceInfo[];
|
|
5
|
+
theme: WidgetTheme;
|
|
6
|
+
bridgeToL2OnClick: (address?: string) => void;
|
|
7
|
+
}
|
|
8
|
+
export declare function TokenBalanceList({ balanceInfoItems, theme, bridgeToL2OnClick, }: TokenBalanceListProps): import("@emotion/react/jsx-runtime").JSX.Element;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
export declare const tokenBalanceListStyle: {
|
|
2
|
+
width: string;
|
|
3
|
+
height: string;
|
|
4
|
+
display: string;
|
|
5
|
+
flexDirection: string;
|
|
6
|
+
rowGap: string;
|
|
7
|
+
};
|
|
8
|
+
export declare const noTokensStyle: {
|
|
9
|
+
width: string;
|
|
10
|
+
height: string;
|
|
11
|
+
display: string;
|
|
12
|
+
justifyContent: string;
|
|
13
|
+
alignItems: string;
|
|
14
|
+
};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
export declare const totalTokenBalanceStyle: {
|
|
2
|
+
display: string;
|
|
3
|
+
flexDirection: string;
|
|
4
|
+
justifyContent: string;
|
|
5
|
+
paddingX: string;
|
|
6
|
+
paddingY: string;
|
|
7
|
+
};
|
|
8
|
+
export declare const totalTokenBalanceValueStyle: {
|
|
9
|
+
display: string;
|
|
10
|
+
direction: string;
|
|
11
|
+
columnGap: string;
|
|
12
|
+
alignItems: string;
|
|
13
|
+
};
|
|
14
|
+
export declare const coinInfoButtonStyle: {
|
|
15
|
+
height: string;
|
|
16
|
+
width: string;
|
|
17
|
+
minWidth: string;
|
|
18
|
+
fill: string;
|
|
19
|
+
cursor: string;
|
|
20
|
+
};
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { WrappedBrowserProvider } from '@imtbl/checkout-sdk';
|
|
2
|
+
export declare function TransferAssetsL1Warning({ provider, showL1Warning, setShowL1Warning, }: {
|
|
3
|
+
provider?: WrappedBrowserProvider;
|
|
4
|
+
showL1Warning: boolean;
|
|
5
|
+
setShowL1Warning: (show: boolean) => void;
|
|
6
|
+
}): import("@emotion/react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { WrappedBrowserProvider } from '@imtbl/checkout-sdk';
|
|
2
|
+
export declare function WalletAddress({ provider, showL1Warning, setShowL1Warning, }: {
|
|
3
|
+
provider?: WrappedBrowserProvider;
|
|
4
|
+
showL1Warning: boolean;
|
|
5
|
+
setShowL1Warning: (show: boolean) => void;
|
|
6
|
+
}): import("@emotion/react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import { WalletProviderName, NetworkInfo, GetBalanceResult } from '@imtbl/checkout-sdk';
|
|
2
|
+
export type WalletConfiguration = {
|
|
3
|
+
showDisconnectButton: boolean;
|
|
4
|
+
showNetworkMenu: boolean;
|
|
5
|
+
};
|
|
6
|
+
export interface WalletState {
|
|
7
|
+
walletProviderName: WalletProviderName | null;
|
|
8
|
+
network: NetworkInfo | null;
|
|
9
|
+
tokenBalances: GetBalanceResult[];
|
|
10
|
+
supportedTopUps: TopUpFeature | null;
|
|
11
|
+
walletConfig: WalletConfiguration;
|
|
12
|
+
}
|
|
13
|
+
export interface TopUpFeature {
|
|
14
|
+
isOnRampEnabled?: boolean;
|
|
15
|
+
isSwapEnabled?: boolean;
|
|
16
|
+
isBridgeEnabled?: boolean;
|
|
17
|
+
isSwapAvailable?: boolean;
|
|
18
|
+
isAddTokensEnabled?: boolean;
|
|
19
|
+
}
|
|
20
|
+
export declare const initialWalletState: WalletState;
|
|
21
|
+
export interface WalletContextState {
|
|
22
|
+
walletState: WalletState;
|
|
23
|
+
walletDispatch: React.Dispatch<WalletAction>;
|
|
24
|
+
}
|
|
25
|
+
export interface WalletAction {
|
|
26
|
+
payload: ActionPayload;
|
|
27
|
+
}
|
|
28
|
+
type ActionPayload = SetWalletProviderNamePayload | SetSwitchNetworkPayload | SetTokenBalancesPayload | SetSupportedTopUpPayload;
|
|
29
|
+
export declare enum WalletActions {
|
|
30
|
+
SET_WALLET_PROVIDER_NAME = "SET_WALLET_PROVIDER_NAME",
|
|
31
|
+
SET_NETWORK = "SET_NETWORK",
|
|
32
|
+
SET_TOKEN_BALANCES = "SET_TOKEN_BALANCES",
|
|
33
|
+
SET_SUPPORTED_TOP_UPS = "SUPPORTED_TOP_UPS"
|
|
34
|
+
}
|
|
35
|
+
export interface SetWalletProviderNamePayload {
|
|
36
|
+
type: WalletActions.SET_WALLET_PROVIDER_NAME;
|
|
37
|
+
walletProviderName: WalletProviderName;
|
|
38
|
+
}
|
|
39
|
+
export interface SetSwitchNetworkPayload {
|
|
40
|
+
type: WalletActions.SET_NETWORK;
|
|
41
|
+
network: NetworkInfo;
|
|
42
|
+
}
|
|
43
|
+
export interface SetTokenBalancesPayload {
|
|
44
|
+
type: WalletActions.SET_TOKEN_BALANCES;
|
|
45
|
+
tokenBalances: GetBalanceResult[];
|
|
46
|
+
}
|
|
47
|
+
export interface SetSupportedTopUpPayload {
|
|
48
|
+
type: WalletActions.SET_SUPPORTED_TOP_UPS;
|
|
49
|
+
supportedTopUps: TopUpFeature;
|
|
50
|
+
}
|
|
51
|
+
export declare const WalletContext: import("react").Context<WalletContextState>;
|
|
52
|
+
export type Reducer<S, A> = (prevState: S, action: A) => S;
|
|
53
|
+
export declare const walletReducer: Reducer<WalletState, WalletAction>;
|
|
54
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { Checkout, ChainId, GetBalanceResult, WrappedBrowserProvider } from '@imtbl/checkout-sdk';
|
|
2
|
+
export type BalanceInfo = {
|
|
3
|
+
id: string;
|
|
4
|
+
symbol: string;
|
|
5
|
+
address?: string;
|
|
6
|
+
description?: string;
|
|
7
|
+
balance: string;
|
|
8
|
+
fiatAmount: string;
|
|
9
|
+
icon?: string;
|
|
10
|
+
};
|
|
11
|
+
export declare const getTokenBalances: (checkout: Checkout, provider: WrappedBrowserProvider, chainId: ChainId) => Promise<GetBalanceResult[]>;
|
|
12
|
+
export declare const mapTokenBalancesWithConversions: (chainId: ChainId, balances: GetBalanceResult[], conversions: Map<string, number>) => BalanceInfo[];
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { WalletState } from '../context/WalletContext';
|
|
3
|
+
export interface TestProps {
|
|
4
|
+
children: React.ReactNode;
|
|
5
|
+
initialStateOverride?: WalletState;
|
|
6
|
+
cryptoConversionsOverride?: Map<string, number>;
|
|
7
|
+
}
|
|
8
|
+
export declare function WalletWidgetTestComponent({ children, initialStateOverride, cryptoConversionsOverride, }: TestProps): import("@emotion/react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function CoinInfo(): import("@emotion/react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { WidgetTheme } from '@imtbl/checkout-sdk';
|
|
2
|
+
type WalletBalancesProps = {
|
|
3
|
+
balancesLoading: boolean;
|
|
4
|
+
theme: WidgetTheme;
|
|
5
|
+
showNetworkMenu: boolean;
|
|
6
|
+
};
|
|
7
|
+
export declare function WalletBalances({ balancesLoading, theme, showNetworkMenu, }: WalletBalancesProps): import("@emotion/react/jsx-runtime").JSX.Element;
|
|
8
|
+
export {};
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
export declare const walletBalanceOuterContainerStyles: {
|
|
2
|
+
display: string;
|
|
3
|
+
flexDirection: string;
|
|
4
|
+
rowGap: string;
|
|
5
|
+
paddingX: string;
|
|
6
|
+
flex: number;
|
|
7
|
+
};
|
|
8
|
+
export declare const walletBalanceContainerStyles: {
|
|
9
|
+
backgroundColor: string;
|
|
10
|
+
paddingX: string;
|
|
11
|
+
borderRadius: string;
|
|
12
|
+
flex: number;
|
|
13
|
+
};
|
|
14
|
+
export declare const walletBalanceLoadingIconStyles: {
|
|
15
|
+
display: string;
|
|
16
|
+
flexDirection: string;
|
|
17
|
+
rowGap: string;
|
|
18
|
+
};
|
|
19
|
+
export declare const walletBalanceListContainerStyles: (showNetworkMenu: boolean, showAddCoins: boolean) => {
|
|
20
|
+
height: string;
|
|
21
|
+
overflowY: string;
|
|
22
|
+
borderRadius: string;
|
|
23
|
+
};
|
package/package.json
ADDED
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@imtbl/checkout-widgets",
|
|
3
|
+
"version": "2.0.0-alpha.0",
|
|
4
|
+
"browserslist": {
|
|
5
|
+
"production": [
|
|
6
|
+
">0.2%",
|
|
7
|
+
"not dead",
|
|
8
|
+
"not op_mini all"
|
|
9
|
+
],
|
|
10
|
+
"development": [
|
|
11
|
+
"last 1 chrome version",
|
|
12
|
+
"last 1 firefox version",
|
|
13
|
+
"last 1 safari version"
|
|
14
|
+
]
|
|
15
|
+
},
|
|
16
|
+
"dependencies": {
|
|
17
|
+
"@0xsquid/sdk": "^2.8.25",
|
|
18
|
+
"@biom3/design-tokens": "^0.4.5",
|
|
19
|
+
"@biom3/react": "^0.28.13",
|
|
20
|
+
"@imtbl/bridge-sdk": "2.0.0-alpha.0",
|
|
21
|
+
"@imtbl/checkout-sdk": "2.0.0-alpha.0",
|
|
22
|
+
"@imtbl/config": "2.0.0-alpha.0",
|
|
23
|
+
"@imtbl/cryptofiat": "2.0.0-alpha.0",
|
|
24
|
+
"@imtbl/dex-sdk": "2.0.0-alpha.0",
|
|
25
|
+
"@imtbl/passport": "2.0.0-alpha.0",
|
|
26
|
+
"@imtbl/react-analytics": "0.3.2-alpha",
|
|
27
|
+
"@rive-app/react-canvas-lite": "^4.9.0",
|
|
28
|
+
"@walletconnect/ethereum-provider": "^2.11.1",
|
|
29
|
+
"@walletconnect/modal": "^2.6.2",
|
|
30
|
+
"axios": "^1.6.5",
|
|
31
|
+
"ethers": "^6.13.4",
|
|
32
|
+
"framer-motion": "^11.0.6",
|
|
33
|
+
"i18next": "^23.7.6",
|
|
34
|
+
"i18next-browser-languagedetector": "^7.2.0",
|
|
35
|
+
"localforage": "^1.10.0",
|
|
36
|
+
"lodash.debounce": "^4.0.8",
|
|
37
|
+
"pako": "^2.1.0",
|
|
38
|
+
"pino-pretty": "^11.2.2",
|
|
39
|
+
"react": "^18.2.0",
|
|
40
|
+
"react-dom": "^18.2.0",
|
|
41
|
+
"react-i18next": "^13.5.0",
|
|
42
|
+
"ts-deepmerge": "^7.0.2",
|
|
43
|
+
"uuid": "^8.3.2"
|
|
44
|
+
},
|
|
45
|
+
"devDependencies": {
|
|
46
|
+
"@0xsquid/squid-types": "^0.1.108",
|
|
47
|
+
"@jest/globals": "^29.5.0",
|
|
48
|
+
"@segment/analytics-next": "^1.53.2",
|
|
49
|
+
"@svgr/webpack": "^8.0.1",
|
|
50
|
+
"@swc/core": "^1.3.36",
|
|
51
|
+
"@testing-library/jest-dom": "^5.16.5",
|
|
52
|
+
"@testing-library/react": "^13.4.0",
|
|
53
|
+
"@testing-library/user-event": "^13.5.0",
|
|
54
|
+
"@types/jest": "^29.4.3",
|
|
55
|
+
"@types/lodash.debounce": "^4.0.9",
|
|
56
|
+
"@types/node": "^18.14.2",
|
|
57
|
+
"@types/react": "^18.3.5",
|
|
58
|
+
"@types/react-dom": "^18.3.0",
|
|
59
|
+
"@types/uuid": "^8.3.4",
|
|
60
|
+
"esbuild-plugins-node-modules-polyfill": "^1.6.7",
|
|
61
|
+
"eslint": "^8.40.0",
|
|
62
|
+
"jest": "^29.4.3",
|
|
63
|
+
"jest-environment-jsdom": "^29.4.3",
|
|
64
|
+
"react-scripts": "5.0.1",
|
|
65
|
+
"rimraf": "^6.0.1",
|
|
66
|
+
"terser": "^5.34.1",
|
|
67
|
+
"ts-jest": "^29.1.0",
|
|
68
|
+
"tsup": "^8.3.5",
|
|
69
|
+
"typescript": "^5.6.2",
|
|
70
|
+
"web-vitals": "^2.1.4"
|
|
71
|
+
},
|
|
72
|
+
"exports": {
|
|
73
|
+
"development": {
|
|
74
|
+
"types": "./src/index.ts",
|
|
75
|
+
"browser": "./dist/browser/index.js",
|
|
76
|
+
"require": "./dist/node/index.cjs",
|
|
77
|
+
"default": "./dist/node/index.js"
|
|
78
|
+
},
|
|
79
|
+
"default": {
|
|
80
|
+
"types": "./dist/types/index.d.ts",
|
|
81
|
+
"browser": "./dist/browser/index.js",
|
|
82
|
+
"require": "./dist/node/index.cjs",
|
|
83
|
+
"default": "./dist/node/index.js"
|
|
84
|
+
}
|
|
85
|
+
},
|
|
86
|
+
"files": [
|
|
87
|
+
"dist"
|
|
88
|
+
],
|
|
89
|
+
"homepage": "https://github.com/immutable/ts-immutable-sdk",
|
|
90
|
+
"keywords": [
|
|
91
|
+
"immutable"
|
|
92
|
+
],
|
|
93
|
+
"license": "ISC",
|
|
94
|
+
"main": "dist/main.js",
|
|
95
|
+
"module": "dist/index.js",
|
|
96
|
+
"publishConfig": {
|
|
97
|
+
"access": "public"
|
|
98
|
+
},
|
|
99
|
+
"repository": "immutable/ts-immutable-sdk.git",
|
|
100
|
+
"type": "module",
|
|
101
|
+
"types": "./dist/types/index.d.ts",
|
|
102
|
+
"scripts": {
|
|
103
|
+
"build": "pnpm transpile && pnpm typegen",
|
|
104
|
+
"transpile": "tsup src/index.ts --config ./tsup.config.js",
|
|
105
|
+
"typegen": "tsc --customConditions default --emitDeclarationOnly --outDir dist/types",
|
|
106
|
+
"build:local": "pnpm build && mkdir -p ../widgets-sample-app/public/lib/js && cp dist/*.js ../widgets-sample-app/public/lib/js/",
|
|
107
|
+
"lint": "eslint ./src --ext .ts,.jsx,.tsx --max-warnings=0",
|
|
108
|
+
"lint:fix": "eslint ./src --ext .ts,.jsx,.tsx --max-warnings=0 --fix",
|
|
109
|
+
"prepare:examplewidgets": "pnpm --filter @examples/commerce-widget-nextjs exec mkdir -p tests/utils/local-widgets-js/ && cp ./dist/*.js $(pnpm --filter @examples/commerce-widget-nextjs exec pwd)/tests/utils/local-widgets-js/",
|
|
110
|
+
"prepare:testwidgets": "pnpm --filter @tests/checkout-widgets-nextjs exec mkdir -p tests/utils/local-widgets-js/ && cp ./dist/*.js $(pnpm --filter @tests/checkout-widgets-nextjs exec pwd)/tests/utils/local-widgets-js/",
|
|
111
|
+
"start": "NODE_ENV=development tsup --config ./tsup.config.js --watch",
|
|
112
|
+
"test": "jest test --passWithNoTests",
|
|
113
|
+
"test:watch": "jest test --passWithNoTests --watch",
|
|
114
|
+
"typecheck": "tsc --customConditions default --customConditions \"default\" --noEmit"
|
|
115
|
+
}
|
|
116
|
+
}
|