thirdweb 5.88.4 → 5.88.5-nightly-52cbcd2d57abf4d69ee417fe98fca815e19f2f34-20250216000400
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/cjs/contract/deployment/deploy-via-autofactory.js +33 -9
- package/dist/cjs/contract/deployment/deploy-via-autofactory.js.map +1 -1
- package/dist/cjs/exports/contract.js +3 -1
- package/dist/cjs/exports/contract.js.map +1 -1
- package/dist/cjs/exports/modules.js +3 -1
- package/dist/cjs/exports/modules.js.map +1 -1
- package/dist/cjs/extensions/modules/common/installPublishedModule.js +4 -1
- package/dist/cjs/extensions/modules/common/installPublishedModule.js.map +1 -1
- package/dist/cjs/extensions/prebuilts/deploy-published.js +14 -2
- package/dist/cjs/extensions/prebuilts/deploy-published.js.map +1 -1
- package/dist/cjs/extensions/thirdweb/__generated__/IContractFactory/events/ProxyDeployedV2.js +33 -0
- package/dist/cjs/extensions/thirdweb/__generated__/IContractFactory/events/ProxyDeployedV2.js.map +1 -0
- package/dist/cjs/extensions/thirdweb/__generated__/IContractFactory/write/deployProxyByImplementationV2.js +152 -0
- package/dist/cjs/extensions/thirdweb/__generated__/IContractFactory/write/deployProxyByImplementationV2.js.map +1 -0
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/BuyScreen.js +66 -56
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/BuyScreen.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/PayWIthCreditCard.js +3 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/PayWIthCreditCard.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/TransactionModeScreen.js +2 -2
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/TransactionModeScreen.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/fiat/FiatScreenContent.js +13 -13
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/fiat/FiatScreenContent.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/fiat/currencies.js +6 -0
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/fiat/currencies.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/main/useUISelectionStates.js +3 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/main/useUISelectionStates.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/swap/BuyTokenInput.js +2 -26
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/swap/BuyTokenInput.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/swap/FiatValue.js +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/swap/FiatValue.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/swap/PayWithCrypto.js +6 -12
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/swap/PayWithCrypto.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/swap/SwapScreenContent.js +2 -2
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/swap/SwapScreenContent.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/swap/TokenSelectorScreen.js +198 -0
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/swap/TokenSelectorScreen.js.map +1 -0
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/swap/TransferConfirmationScreen.js +3 -3
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/swap/TransferConfirmationScreen.js.map +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/SignatureScreen.js +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/SignatureScreen.js.map +1 -1
- package/dist/cjs/react/web/ui/components/buttons.js +11 -0
- package/dist/cjs/react/web/ui/components/buttons.js.map +1 -1
- package/dist/cjs/react/web/ui/components/token/TokenRow.js +36 -0
- package/dist/cjs/react/web/ui/components/token/TokenRow.js.map +1 -0
- package/dist/cjs/utils/abi/normalizeFunctionParams.js +6 -2
- package/dist/cjs/utils/abi/normalizeFunctionParams.js.map +1 -1
- package/dist/cjs/utils/ens/namehash.js.map +1 -1
- package/dist/cjs/version.js +1 -1
- package/dist/cjs/version.js.map +1 -1
- package/dist/esm/contract/deployment/deploy-via-autofactory.js +33 -9
- package/dist/esm/contract/deployment/deploy-via-autofactory.js.map +1 -1
- package/dist/esm/exports/contract.js +1 -0
- package/dist/esm/exports/contract.js.map +1 -1
- package/dist/esm/exports/modules.js +1 -0
- package/dist/esm/exports/modules.js.map +1 -1
- package/dist/esm/extensions/modules/common/installPublishedModule.js +4 -1
- package/dist/esm/extensions/modules/common/installPublishedModule.js.map +1 -1
- package/dist/esm/extensions/prebuilts/deploy-published.js +14 -2
- package/dist/esm/extensions/prebuilts/deploy-published.js.map +1 -1
- package/dist/esm/extensions/thirdweb/__generated__/IContractFactory/events/ProxyDeployedV2.js +30 -0
- package/dist/esm/extensions/thirdweb/__generated__/IContractFactory/events/ProxyDeployedV2.js.map +1 -0
- package/dist/esm/extensions/thirdweb/__generated__/IContractFactory/write/deployProxyByImplementationV2.js +145 -0
- package/dist/esm/extensions/thirdweb/__generated__/IContractFactory/write/deployProxyByImplementationV2.js.map +1 -0
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/BuyScreen.js +68 -58
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/BuyScreen.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/PayWIthCreditCard.js +3 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/PayWIthCreditCard.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/TransactionModeScreen.js +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/TransactionModeScreen.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/fiat/FiatScreenContent.js +13 -13
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/fiat/FiatScreenContent.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/fiat/currencies.js +6 -0
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/fiat/currencies.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/main/useUISelectionStates.js +3 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/main/useUISelectionStates.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/swap/BuyTokenInput.js +3 -27
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/swap/BuyTokenInput.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/swap/FiatValue.js +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/swap/FiatValue.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/swap/PayWithCrypto.js +6 -12
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/swap/PayWithCrypto.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/swap/SwapScreenContent.js +2 -2
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/swap/SwapScreenContent.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/swap/TokenSelectorScreen.js +194 -0
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/swap/TokenSelectorScreen.js.map +1 -0
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/swap/TransferConfirmationScreen.js +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/swap/TransferConfirmationScreen.js.map +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/SignatureScreen.js +1 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/SignatureScreen.js.map +1 -1
- package/dist/esm/react/web/ui/components/buttons.js +11 -0
- package/dist/esm/react/web/ui/components/buttons.js.map +1 -1
- package/dist/esm/react/web/ui/components/token/TokenRow.js +33 -0
- package/dist/esm/react/web/ui/components/token/TokenRow.js.map +1 -0
- package/dist/esm/utils/abi/normalizeFunctionParams.js +6 -2
- package/dist/esm/utils/abi/normalizeFunctionParams.js.map +1 -1
- package/dist/esm/utils/ens/namehash.js.map +1 -1
- package/dist/esm/version.js +1 -1
- package/dist/esm/version.js.map +1 -1
- package/dist/types/contract/deployment/deploy-via-autofactory.d.ts +8 -2
- package/dist/types/contract/deployment/deploy-via-autofactory.d.ts.map +1 -1
- package/dist/types/exports/contract.d.ts +1 -0
- package/dist/types/exports/contract.d.ts.map +1 -1
- package/dist/types/exports/modules.d.ts +1 -0
- package/dist/types/exports/modules.d.ts.map +1 -1
- package/dist/types/extensions/modules/common/installPublishedModule.d.ts +1 -0
- package/dist/types/extensions/modules/common/installPublishedModule.d.ts.map +1 -1
- package/dist/types/extensions/prebuilts/deploy-published.d.ts +2 -0
- package/dist/types/extensions/prebuilts/deploy-published.d.ts.map +1 -1
- package/dist/types/extensions/thirdweb/__generated__/IContractFactory/events/ProxyDeployedV2.d.ts +70 -0
- package/dist/types/extensions/thirdweb/__generated__/IContractFactory/events/ProxyDeployedV2.d.ts.map +1 -0
- package/dist/types/extensions/thirdweb/__generated__/IContractFactory/write/deployProxyByImplementationV2.d.ts +100 -0
- package/dist/types/extensions/thirdweb/__generated__/IContractFactory/write/deployProxyByImplementationV2.d.ts.map +1 -0
- package/dist/types/react/web/ui/ConnectWallet/screens/Buy/BuyScreen.d.ts.map +1 -1
- package/dist/types/react/web/ui/ConnectWallet/screens/Buy/PayWIthCreditCard.d.ts.map +1 -1
- package/dist/types/react/web/ui/ConnectWallet/screens/Buy/fiat/FiatScreenContent.d.ts.map +1 -1
- package/dist/types/react/web/ui/ConnectWallet/screens/Buy/fiat/currencies.d.ts +1 -0
- package/dist/types/react/web/ui/ConnectWallet/screens/Buy/fiat/currencies.d.ts.map +1 -1
- package/dist/types/react/web/ui/ConnectWallet/screens/Buy/main/useUISelectionStates.d.ts.map +1 -1
- package/dist/types/react/web/ui/ConnectWallet/screens/Buy/swap/BuyTokenInput.d.ts.map +1 -1
- package/dist/types/react/web/ui/ConnectWallet/screens/Buy/swap/FiatValue.d.ts.map +1 -1
- package/dist/types/react/web/ui/ConnectWallet/screens/Buy/swap/PayWithCrypto.d.ts +1 -0
- package/dist/types/react/web/ui/ConnectWallet/screens/Buy/swap/PayWithCrypto.d.ts.map +1 -1
- package/dist/types/react/web/ui/ConnectWallet/screens/Buy/swap/SwapScreenContent.d.ts.map +1 -1
- package/dist/types/react/web/ui/ConnectWallet/screens/Buy/swap/{PaymentSelectionScreen.d.ts → TokenSelectorScreen.d.ts} +19 -14
- package/dist/types/react/web/ui/ConnectWallet/screens/Buy/swap/TokenSelectorScreen.d.ts.map +1 -0
- package/dist/types/react/web/ui/ConnectWallet/screens/Buy/swap/TransferConfirmationScreen.d.ts.map +1 -1
- package/dist/types/react/web/ui/components/buttons.d.ts.map +1 -1
- package/dist/types/react/web/ui/components/token/TokenRow.d.ts +14 -0
- package/dist/types/react/web/ui/components/token/TokenRow.d.ts.map +1 -0
- package/dist/types/utils/abi/normalizeFunctionParams.d.ts.map +1 -1
- package/dist/types/utils/ens/namehash.d.ts.map +1 -1
- package/dist/types/version.d.ts +1 -1
- package/dist/types/version.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/contract/deployment/deploy-via-autofactory.test.ts +166 -0
- package/src/contract/deployment/deploy-via-autofactory.ts +50 -10
- package/src/exports/contract.ts +1 -0
- package/src/exports/modules.ts +1 -0
- package/src/extensions/modules/common/installPublishedModule.ts +5 -0
- package/src/extensions/prebuilts/deploy-published.ts +18 -2
- package/src/extensions/thirdweb/__generated__/IContractFactory/events/ProxyDeployedV2.ts +55 -0
- package/src/extensions/thirdweb/__generated__/IContractFactory/write/deployProxyByImplementationV2.ts +184 -0
- package/src/react/web/ui/ConnectWallet/screens/Buy/BuyScreen.tsx +132 -86
- package/src/react/web/ui/ConnectWallet/screens/Buy/PayWIthCreditCard.tsx +6 -1
- package/src/react/web/ui/ConnectWallet/screens/Buy/TransactionModeScreen.tsx +1 -1
- package/src/react/web/ui/ConnectWallet/screens/Buy/fiat/FiatScreenContent.tsx +67 -66
- package/src/react/web/ui/ConnectWallet/screens/Buy/fiat/currencies.tsx +7 -0
- package/src/react/web/ui/ConnectWallet/screens/Buy/main/useUISelectionStates.ts +3 -1
- package/src/react/web/ui/ConnectWallet/screens/Buy/swap/BuyTokenInput.tsx +9 -75
- package/src/react/web/ui/ConnectWallet/screens/Buy/swap/FiatValue.tsx +3 -1
- package/src/react/web/ui/ConnectWallet/screens/Buy/swap/PayWithCrypto.tsx +13 -41
- package/src/react/web/ui/ConnectWallet/screens/Buy/swap/SwapScreenContent.tsx +59 -53
- package/src/react/web/ui/ConnectWallet/screens/Buy/swap/TokenSelectorScreen.tsx +437 -0
- package/src/react/web/ui/ConnectWallet/screens/Buy/swap/TransferConfirmationScreen.tsx +1 -1
- package/src/react/web/ui/ConnectWallet/screens/SignatureScreen.tsx +1 -1
- package/src/react/web/ui/components/buttons.tsx +12 -0
- package/src/react/web/ui/components/token/TokenRow.tsx +111 -0
- package/src/utils/abi/normalizeFunctionParams.test.ts +26 -1
- package/src/utils/abi/normalizeFunctionParams.ts +9 -4
- package/src/utils/ens/namehash.ts +4 -1
- package/src/version.ts +1 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/WalletSelectorButton.js +0 -85
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/WalletSelectorButton.js.map +0 -1
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/swap/PaymentSelectionScreen.js +0 -142
- package/dist/cjs/react/web/ui/ConnectWallet/screens/Buy/swap/PaymentSelectionScreen.js.map +0 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/WalletSelectorButton.js +0 -81
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/WalletSelectorButton.js.map +0 -1
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/swap/PaymentSelectionScreen.js +0 -139
- package/dist/esm/react/web/ui/ConnectWallet/screens/Buy/swap/PaymentSelectionScreen.js.map +0 -1
- package/dist/types/react/web/ui/ConnectWallet/screens/Buy/WalletSelectorButton.d.ts +0 -22
- package/dist/types/react/web/ui/ConnectWallet/screens/Buy/WalletSelectorButton.d.ts.map +0 -1
- package/dist/types/react/web/ui/ConnectWallet/screens/Buy/swap/PaymentSelectionScreen.d.ts.map +0 -1
- package/src/react/web/ui/ConnectWallet/screens/Buy/WalletSelectorButton.tsx +0 -220
- package/src/react/web/ui/ConnectWallet/screens/Buy/swap/PaymentSelectionScreen.tsx +0 -263
@@ -5,11 +5,14 @@ import type { ThirdwebClient } from "../../../../../../client/client.js";
|
|
5
5
|
import { NATIVE_TOKEN_ADDRESS } from "../../../../../../constants/addresses.js";
|
6
6
|
import type { BuyWithCryptoStatus } from "../../../../../../pay/buyWithCrypto/getStatus.js";
|
7
7
|
import type { BuyWithFiatStatus } from "../../../../../../pay/buyWithFiat/getStatus.js";
|
8
|
+
import { formatNumber } from "../../../../../../utils/formatNumber.js";
|
8
9
|
import type { Account } from "../../../../../../wallets/interfaces/wallet.js";
|
9
10
|
import type { WalletId } from "../../../../../../wallets/wallet-types.js";
|
11
|
+
import { useCustomTheme } from "../../../../../core/design-system/CustomThemeProvider.js";
|
10
12
|
import {
|
11
13
|
type Theme,
|
12
14
|
fontSize,
|
15
|
+
radius,
|
13
16
|
spacing,
|
14
17
|
} from "../../../../../core/design-system/index.js";
|
15
18
|
import type {
|
@@ -24,7 +27,7 @@ import { LoadingScreen } from "../../../../wallets/shared/LoadingScreen.js";
|
|
24
27
|
import type { PayEmbedConnectOptions } from "../../../PayEmbed.js";
|
25
28
|
import { ChainName } from "../../../components/ChainName.js";
|
26
29
|
import { Spacer } from "../../../components/Spacer.js";
|
27
|
-
import { Container,
|
30
|
+
import { Container, ModalHeader } from "../../../components/basic.js";
|
28
31
|
import { Button } from "../../../components/buttons.js";
|
29
32
|
import { Input } from "../../../components/formElements.js";
|
30
33
|
import { Text } from "../../../components/text.js";
|
@@ -53,9 +56,9 @@ import {
|
|
53
56
|
} from "./main/useUISelectionStates.js";
|
54
57
|
import { BuyTokenInput } from "./swap/BuyTokenInput.js";
|
55
58
|
import { FiatValue } from "./swap/FiatValue.js";
|
56
|
-
import { PaymentSelectionScreen } from "./swap/PaymentSelectionScreen.js";
|
57
59
|
import { SwapFlow } from "./swap/SwapFlow.js";
|
58
60
|
import { SwapScreenContent } from "./swap/SwapScreenContent.js";
|
61
|
+
import { TokenSelectorScreen } from "./swap/TokenSelectorScreen.js";
|
59
62
|
import { TransferFlow } from "./swap/TransferFlow.js";
|
60
63
|
import {
|
61
64
|
type SupportedChainAndTokens,
|
@@ -453,30 +456,39 @@ function BuyScreenContent(props: BuyScreenContentProps) {
|
|
453
456
|
}
|
454
457
|
|
455
458
|
return (
|
456
|
-
<
|
459
|
+
<TokenSelectorScreen
|
457
460
|
onBack={goBack}
|
458
|
-
|
459
|
-
(
|
460
|
-
|
461
|
-
|
462
|
-
|
463
|
-
|
461
|
+
onConnect={() => {
|
462
|
+
setScreen({
|
463
|
+
id: "connect-payer-wallet",
|
464
|
+
backScreen: screen,
|
465
|
+
});
|
466
|
+
}}
|
467
|
+
modalTitle="Available tokens"
|
468
|
+
connectLocale={props.connectLocale}
|
469
|
+
client={props.client}
|
470
|
+
sourceTokens={sourceSupportedTokens}
|
471
|
+
sourceSupportedTokens={sourceSupportedTokens}
|
472
|
+
toChain={toChain}
|
473
|
+
toToken={toToken}
|
474
|
+
tokenAmount={tokenAmount}
|
475
|
+
fromChain={fromChain}
|
476
|
+
fromToken={fromToken}
|
477
|
+
mode={payOptions.mode}
|
478
|
+
hiddenWallets={props.hiddenWallets}
|
479
|
+
onSelect={(w, token, chain) => {
|
480
|
+
const account = w.getAccount();
|
481
|
+
if (account) {
|
482
|
+
setPayer({
|
483
|
+
account,
|
484
|
+
chain,
|
485
|
+
wallet: w,
|
486
|
+
});
|
487
|
+
setFromToken(token);
|
488
|
+
setFromChain(chain);
|
489
|
+
}
|
464
490
|
goBack();
|
465
491
|
}}
|
466
|
-
chain={fromChain}
|
467
|
-
chainSelection={
|
468
|
-
// hide chain selection if it's disabled
|
469
|
-
payOptions.buyWithCrypto !== false &&
|
470
|
-
payOptions.buyWithCrypto?.prefillSource?.allowEdits?.chain !== false
|
471
|
-
? {
|
472
|
-
chains: supportedSourcesQuery.data.map((x) => x.chain),
|
473
|
-
select: (c) => setFromChain(c),
|
474
|
-
}
|
475
|
-
: undefined
|
476
|
-
}
|
477
|
-
connectLocale={connectLocale}
|
478
|
-
client={client}
|
479
|
-
modalTitle="Pay with"
|
480
492
|
/>
|
481
493
|
);
|
482
494
|
}
|
@@ -517,6 +529,16 @@ function BuyScreenContent(props: BuyScreenContentProps) {
|
|
517
529
|
screen.id === "buy-with-fiat") &&
|
518
530
|
payer && (
|
519
531
|
<TokenSelectedLayout
|
532
|
+
isBuyWithFiatEnabled={enabledPaymentMethods.buyWithFiatEnabled}
|
533
|
+
isBuyWithCryptoEnabled={
|
534
|
+
enabledPaymentMethods.buyWithCryptoEnabled
|
535
|
+
}
|
536
|
+
mode={screen.id === "buy-with-fiat" ? "buy" : "swap"}
|
537
|
+
onModeChange={(mode) => {
|
538
|
+
setScreen({
|
539
|
+
id: mode === "swap" ? "buy-with-crypto" : "buy-with-fiat",
|
540
|
+
});
|
541
|
+
}}
|
520
542
|
disabled={
|
521
543
|
("prefillBuy" in payOptions &&
|
522
544
|
payOptions.prefillBuy?.allowEdits?.amount === false) ||
|
@@ -529,60 +551,9 @@ function BuyScreenContent(props: BuyScreenContentProps) {
|
|
529
551
|
setTokenAmount={setTokenAmount}
|
530
552
|
client={client}
|
531
553
|
onBack={() => {
|
532
|
-
|
533
|
-
enabledPaymentMethods.buyWithCryptoEnabled &&
|
534
|
-
screen.id === "buy-with-fiat"
|
535
|
-
) {
|
536
|
-
setScreen({ id: "select-payment-method" });
|
537
|
-
} else if (screen.id === "buy-with-crypto") {
|
538
|
-
setScreen({ id: "select-payment-method" });
|
539
|
-
} else {
|
540
|
-
setScreen({ id: "main" });
|
541
|
-
}
|
554
|
+
setScreen({ id: "main" });
|
542
555
|
}}
|
543
556
|
>
|
544
|
-
{screen.id === "select-payment-method" && (
|
545
|
-
<PaymentSelectionScreen
|
546
|
-
client={client}
|
547
|
-
mode={payOptions.mode}
|
548
|
-
sourceSupportedTokens={sourceSupportedTokens}
|
549
|
-
hiddenWallets={props.hiddenWallets}
|
550
|
-
payWithFiatEnabled={props.payOptions.buyWithFiat !== false}
|
551
|
-
toChain={toChain}
|
552
|
-
toToken={toToken}
|
553
|
-
tokenAmount={tokenAmount}
|
554
|
-
onSelect={(w, token, chain) => {
|
555
|
-
const account = w.getAccount();
|
556
|
-
if (account) {
|
557
|
-
setPayer({
|
558
|
-
account,
|
559
|
-
chain,
|
560
|
-
wallet: w,
|
561
|
-
});
|
562
|
-
setFromToken(token);
|
563
|
-
setFromChain(chain);
|
564
|
-
setScreen({ id: "buy-with-crypto" });
|
565
|
-
}
|
566
|
-
}}
|
567
|
-
onSelectFiat={() => {
|
568
|
-
setScreen({ id: "buy-with-fiat" });
|
569
|
-
}}
|
570
|
-
showAllWallets={!!props.connectOptions?.showAllWallets}
|
571
|
-
wallets={props.connectOptions?.wallets}
|
572
|
-
onBack={() => {
|
573
|
-
// no-op
|
574
|
-
}}
|
575
|
-
onConnect={() => {
|
576
|
-
setScreen({
|
577
|
-
id: "connect-payer-wallet",
|
578
|
-
backScreen: {
|
579
|
-
id: "select-payment-method",
|
580
|
-
},
|
581
|
-
});
|
582
|
-
}}
|
583
|
-
/>
|
584
|
-
)}
|
585
|
-
|
586
557
|
{screen.id === "buy-with-crypto" && activeAccount && (
|
587
558
|
<SwapScreenContent
|
588
559
|
setScreen={setScreen}
|
@@ -659,8 +630,9 @@ function SelectedTokenInfo(props: {
|
|
659
630
|
disabled?: boolean;
|
660
631
|
}) {
|
661
632
|
const getWidth = () => {
|
662
|
-
|
663
|
-
|
633
|
+
const amount = formatNumber(Number(props.tokenAmount), 5).toString();
|
634
|
+
let chars = amount.replace(".", "").length;
|
635
|
+
const hasDot = amount.includes(".");
|
664
636
|
if (hasDot) {
|
665
637
|
chars += 0.3;
|
666
638
|
}
|
@@ -685,7 +657,11 @@ function SelectedTokenInfo(props: {
|
|
685
657
|
placeholder="0"
|
686
658
|
type="text"
|
687
659
|
data-placeholder={props.tokenAmount === ""}
|
688
|
-
value={
|
660
|
+
value={
|
661
|
+
props.tokenAmount
|
662
|
+
? formatNumber(Number(props.tokenAmount), 5)
|
663
|
+
: "0"
|
664
|
+
}
|
689
665
|
disabled={props.disabled}
|
690
666
|
onClick={(e) => {
|
691
667
|
// put cursor at the end of the input
|
@@ -826,7 +802,7 @@ function MainScreen(props: {
|
|
826
802
|
if (buyWithFiatEnabled && !buyWithCryptoEnabled) {
|
827
803
|
props.setScreen({ id: "buy-with-fiat" });
|
828
804
|
} else {
|
829
|
-
props.setScreen({ id: "
|
805
|
+
props.setScreen({ id: "buy-with-crypto" });
|
830
806
|
}
|
831
807
|
}}
|
832
808
|
/>
|
@@ -849,7 +825,7 @@ function MainScreen(props: {
|
|
849
825
|
if (buyWithFiatEnabled && !buyWithCryptoEnabled) {
|
850
826
|
props.setScreen({ id: "buy-with-fiat" });
|
851
827
|
} else {
|
852
|
-
props.setScreen({ id: "
|
828
|
+
props.setScreen({ id: "buy-with-crypto" });
|
853
829
|
}
|
854
830
|
}}
|
855
831
|
/>
|
@@ -885,7 +861,7 @@ function MainScreen(props: {
|
|
885
861
|
client={props.client}
|
886
862
|
/>
|
887
863
|
|
888
|
-
<Spacer y="
|
864
|
+
<Spacer y="md" />
|
889
865
|
|
890
866
|
{/* Continue */}
|
891
867
|
<Container flex="column" gap="sm">
|
@@ -912,7 +888,7 @@ function MainScreen(props: {
|
|
912
888
|
if (buyWithFiatEnabled && !buyWithCryptoEnabled) {
|
913
889
|
props.setScreen({ id: "buy-with-fiat" });
|
914
890
|
} else {
|
915
|
-
props.setScreen({ id: "
|
891
|
+
props.setScreen({ id: "buy-with-crypto" });
|
916
892
|
}
|
917
893
|
}}
|
918
894
|
>
|
@@ -936,7 +912,12 @@ function TokenSelectedLayout(props: {
|
|
936
912
|
client: ThirdwebClient;
|
937
913
|
onBack: () => void;
|
938
914
|
disabled?: boolean;
|
915
|
+
mode: "buy" | "swap";
|
916
|
+
onModeChange: (mode: "buy" | "swap") => void;
|
917
|
+
isBuyWithFiatEnabled: boolean;
|
918
|
+
isBuyWithCryptoEnabled: boolean;
|
939
919
|
}) {
|
920
|
+
const theme = useCustomTheme();
|
940
921
|
return (
|
941
922
|
<Container>
|
942
923
|
<Container p="lg">
|
@@ -959,12 +940,77 @@ function TokenSelectedLayout(props: {
|
|
959
940
|
disabled={props.disabled}
|
960
941
|
/>
|
961
942
|
|
962
|
-
<Spacer y="md" />
|
963
|
-
<Line />
|
964
943
|
<Spacer y="lg" />
|
944
|
+
<Container flex="row" gap="md" center="y">
|
945
|
+
<Text size="sm"> Pay with </Text>
|
946
|
+
{props.isBuyWithFiatEnabled && props.isBuyWithCryptoEnabled && (
|
947
|
+
<Container
|
948
|
+
flex="row"
|
949
|
+
style={{
|
950
|
+
flex: 1,
|
951
|
+
justifyContent: "center",
|
952
|
+
borderRadius: radius.xl,
|
953
|
+
border: `1px solid ${theme.colors.borderColor}`,
|
954
|
+
alignItems: "stretch",
|
955
|
+
}}
|
956
|
+
>
|
957
|
+
<Button
|
958
|
+
variant="ghost"
|
959
|
+
style={{
|
960
|
+
flex: 1,
|
961
|
+
background:
|
962
|
+
props.mode === "swap"
|
963
|
+
? theme.colors.tertiaryBg
|
964
|
+
: "transparent",
|
965
|
+
borderRadius: radius.xl,
|
966
|
+
borderTopRightRadius: 0,
|
967
|
+
borderBottomRightRadius: 0,
|
968
|
+
padding: spacing.xs,
|
969
|
+
}}
|
970
|
+
onClick={() => props.onModeChange("swap")}
|
971
|
+
>
|
972
|
+
<Text
|
973
|
+
size="sm"
|
974
|
+
color={
|
975
|
+
props.mode === "swap" ? "primaryText" : "secondaryText"
|
976
|
+
}
|
977
|
+
>
|
978
|
+
Crypto
|
979
|
+
</Text>
|
980
|
+
</Button>
|
981
|
+
<div
|
982
|
+
style={{
|
983
|
+
width: "1px",
|
984
|
+
background: theme.colors.borderColor,
|
985
|
+
}}
|
986
|
+
/>
|
987
|
+
<Button
|
988
|
+
variant="ghost"
|
989
|
+
style={{
|
990
|
+
flex: 1,
|
991
|
+
background:
|
992
|
+
props.mode === "buy"
|
993
|
+
? theme.colors.tertiaryBg
|
994
|
+
: "transparent",
|
995
|
+
borderRadius: radius.xl,
|
996
|
+
borderTopLeftRadius: 0,
|
997
|
+
borderBottomLeftRadius: 0,
|
998
|
+
padding: spacing.xs,
|
999
|
+
}}
|
1000
|
+
onClick={() => props.onModeChange("buy")}
|
1001
|
+
>
|
1002
|
+
<Text
|
1003
|
+
size="sm"
|
1004
|
+
color={props.mode === "buy" ? "primaryText" : "secondaryText"}
|
1005
|
+
>
|
1006
|
+
Card
|
1007
|
+
</Text>
|
1008
|
+
</Button>
|
1009
|
+
</Container>
|
1010
|
+
)}
|
1011
|
+
</Container>
|
965
1012
|
|
966
|
-
<
|
967
|
-
<Spacer y="sm" />
|
1013
|
+
<Spacer y="lg" />
|
968
1014
|
|
969
1015
|
{props.children}
|
970
1016
|
</Container>
|
@@ -82,7 +82,12 @@ export function PayWithCreditCard(props: {
|
|
82
82
|
<Skeleton width="100px" height={fontSize.lg} />
|
83
83
|
) : (
|
84
84
|
<Text size="lg" color={props.value ? "primaryText" : "secondaryText"}>
|
85
|
-
{props.value
|
85
|
+
{props.value
|
86
|
+
? `${props.currency.symbol}${formatNumber(
|
87
|
+
Number(props.value),
|
88
|
+
6,
|
89
|
+
)}`
|
90
|
+
: "--"}
|
86
91
|
</Text>
|
87
92
|
)}
|
88
93
|
</div>
|
@@ -32,8 +32,8 @@ import {
|
|
32
32
|
NATIVE_TOKEN,
|
33
33
|
isNativeToken,
|
34
34
|
} from "../nativeToken.js";
|
35
|
-
import { WalletRow } from "./WalletSelectorButton.js";
|
36
35
|
import { useTransactionCostAndData } from "./main/useBuyTxStates.js";
|
36
|
+
import { WalletRow } from "./swap/TokenSelectorScreen.js";
|
37
37
|
import type { SupportedChainAndTokens } from "./swap/useSwapSupportedChains.js";
|
38
38
|
|
39
39
|
export function TransactionModeScreen(props: {
|
@@ -157,7 +157,7 @@ export function FiatScreenContent(props: {
|
|
157
157
|
: undefined;
|
158
158
|
|
159
159
|
return (
|
160
|
-
<Container flex="column" gap="
|
160
|
+
<Container flex="column" gap="lg" animate="fadein">
|
161
161
|
{isOpen && (
|
162
162
|
<>
|
163
163
|
<DrawerOverlay ref={drawerOverlayRef} />
|
@@ -198,74 +198,75 @@ export function FiatScreenContent(props: {
|
|
198
198
|
</>
|
199
199
|
)}
|
200
200
|
|
201
|
-
<
|
202
|
-
<PayWithCreditCard
|
203
|
-
isLoading={fiatQuoteQuery.isLoading}
|
204
|
-
value={fiatQuoteQuery.data?.fromCurrencyWithFees.amount}
|
205
|
-
client={client}
|
206
|
-
currency={selectedCurrency}
|
207
|
-
onSelectCurrency={showCurrencySelector}
|
208
|
-
/>
|
209
|
-
<Container
|
210
|
-
bg="tertiaryBg"
|
211
|
-
flex="row"
|
212
|
-
borderColor="borderColor"
|
213
|
-
style={{
|
214
|
-
paddingLeft: spacing.md,
|
215
|
-
justifyContent: "space-between",
|
216
|
-
alignItems: "center",
|
217
|
-
borderWidth: "1px",
|
218
|
-
borderStyle: "solid",
|
219
|
-
borderBottom: "none",
|
220
|
-
}}
|
221
|
-
>
|
222
|
-
<Text size="xs" color="secondaryText">
|
223
|
-
Provider
|
224
|
-
</Text>
|
225
|
-
<Button variant="ghost" onClick={showProviders}>
|
226
|
-
<Container flex="row" center="y" gap="xxs" color="secondaryText">
|
227
|
-
<Text size="xs">
|
228
|
-
{preferredProvider
|
229
|
-
? `${preferredProvider.charAt(0).toUpperCase() + preferredProvider.slice(1).toLowerCase()}`
|
230
|
-
: fiatQuoteQuery.data?.provider
|
231
|
-
? `${fiatQuoteQuery.data?.provider.charAt(0).toUpperCase() + fiatQuoteQuery.data?.provider.slice(1).toLowerCase()}`
|
232
|
-
: ""}
|
233
|
-
</Text>
|
234
|
-
<ChevronDownIcon width={iconSize.sm} height={iconSize.sm} />
|
235
|
-
</Container>
|
236
|
-
</Button>
|
237
|
-
</Container>
|
238
|
-
{/* Estimated time + View fees button */}
|
239
|
-
<EstimatedTimeAndFees
|
240
|
-
quoteIsLoading={fiatQuoteQuery.isLoading}
|
241
|
-
estimatedSeconds={fiatQuoteQuery.data?.estimatedDurationSeconds}
|
242
|
-
onViewFees={showFees}
|
243
|
-
/>
|
244
|
-
<Spacer y="md" />
|
245
|
-
</div>
|
246
|
-
|
247
|
-
{/* Error message */}
|
248
|
-
{errorMsg && (
|
201
|
+
<Container flex="column" gap="sm">
|
249
202
|
<div>
|
250
|
-
|
251
|
-
|
252
|
-
|
253
|
-
|
254
|
-
|
255
|
-
|
256
|
-
|
257
|
-
|
258
|
-
|
259
|
-
|
260
|
-
|
203
|
+
<PayWithCreditCard
|
204
|
+
isLoading={fiatQuoteQuery.isLoading}
|
205
|
+
value={fiatQuoteQuery.data?.fromCurrencyWithFees.amount}
|
206
|
+
client={client}
|
207
|
+
currency={selectedCurrency}
|
208
|
+
onSelectCurrency={showCurrencySelector}
|
209
|
+
/>
|
210
|
+
<Container
|
211
|
+
bg="tertiaryBg"
|
212
|
+
flex="row"
|
213
|
+
borderColor="borderColor"
|
214
|
+
style={{
|
215
|
+
paddingLeft: spacing.md,
|
216
|
+
justifyContent: "space-between",
|
217
|
+
alignItems: "center",
|
218
|
+
borderWidth: "1px",
|
219
|
+
borderStyle: "solid",
|
220
|
+
borderBottom: "none",
|
221
|
+
}}
|
222
|
+
>
|
223
|
+
<Text size="xs" color="secondaryText">
|
224
|
+
Provider
|
261
225
|
</Text>
|
262
|
-
|
263
|
-
|
264
|
-
|
265
|
-
|
266
|
-
|
226
|
+
<Button variant="ghost" onClick={showProviders}>
|
227
|
+
<Container flex="row" center="y" gap="xxs" color="secondaryText">
|
228
|
+
<Text size="xs">
|
229
|
+
{preferredProvider
|
230
|
+
? `${preferredProvider.charAt(0).toUpperCase() + preferredProvider.slice(1).toLowerCase()}`
|
231
|
+
: fiatQuoteQuery.data?.provider
|
232
|
+
? `${fiatQuoteQuery.data?.provider.charAt(0).toUpperCase() + fiatQuoteQuery.data?.provider.slice(1).toLowerCase()}`
|
233
|
+
: ""}
|
234
|
+
</Text>
|
235
|
+
<ChevronDownIcon width={iconSize.sm} height={iconSize.sm} />
|
236
|
+
</Container>
|
237
|
+
</Button>
|
238
|
+
</Container>
|
239
|
+
{/* Estimated time + View fees button */}
|
240
|
+
<EstimatedTimeAndFees
|
241
|
+
quoteIsLoading={fiatQuoteQuery.isLoading}
|
242
|
+
estimatedSeconds={fiatQuoteQuery.data?.estimatedDurationSeconds}
|
243
|
+
onViewFees={showFees}
|
244
|
+
/>
|
267
245
|
</div>
|
268
|
-
|
246
|
+
|
247
|
+
{/* Error message */}
|
248
|
+
{errorMsg && (
|
249
|
+
<div>
|
250
|
+
{errorMsg.data?.minimumAmountEth ? (
|
251
|
+
<Text color="danger" size="sm" center multiline>
|
252
|
+
Minimum amount is{" "}
|
253
|
+
{formatNumber(Number(errorMsg.data.minimumAmountEth), 6)}{" "}
|
254
|
+
<TokenSymbol
|
255
|
+
token={toToken}
|
256
|
+
chain={toChain}
|
257
|
+
size="sm"
|
258
|
+
inline
|
259
|
+
color="danger"
|
260
|
+
/>
|
261
|
+
</Text>
|
262
|
+
) : (
|
263
|
+
<Text color="danger" size="sm" center multiline>
|
264
|
+
{errorMsg.message || defaultMessage}
|
265
|
+
</Text>
|
266
|
+
)}
|
267
|
+
</div>
|
268
|
+
)}
|
269
|
+
</Container>
|
269
270
|
|
270
271
|
{errorMsg?.data?.minimumAmountEth ? (
|
271
272
|
<Button
|
@@ -9,12 +9,14 @@ import type { IconFC } from "../../../icons/types.js";
|
|
9
9
|
export type CurrencyMeta = {
|
10
10
|
shorthand: "USD" | "CAD" | "GBP" | "EUR" | "JPY";
|
11
11
|
name: string;
|
12
|
+
symbol: string;
|
12
13
|
icon: IconFC;
|
13
14
|
};
|
14
15
|
|
15
16
|
export const usdCurrency: CurrencyMeta = {
|
16
17
|
shorthand: "USD",
|
17
18
|
name: "US Dollar",
|
19
|
+
symbol: "$",
|
18
20
|
icon: USDIcon,
|
19
21
|
};
|
20
22
|
|
@@ -23,21 +25,25 @@ export const currencies: CurrencyMeta[] = [
|
|
23
25
|
{
|
24
26
|
shorthand: "CAD",
|
25
27
|
name: "Canadian Dollar",
|
28
|
+
symbol: "$",
|
26
29
|
icon: CADIcon,
|
27
30
|
},
|
28
31
|
{
|
29
32
|
shorthand: "GBP",
|
30
33
|
name: "British Pound",
|
34
|
+
symbol: "£",
|
31
35
|
icon: GBPIcon,
|
32
36
|
},
|
33
37
|
{
|
34
38
|
shorthand: "EUR",
|
35
39
|
name: "Euro",
|
40
|
+
symbol: "€",
|
36
41
|
icon: EURIcon,
|
37
42
|
},
|
38
43
|
{
|
39
44
|
shorthand: "JPY",
|
40
45
|
name: "Japanese Yen",
|
46
|
+
symbol: "¥",
|
41
47
|
icon: JPYIcon,
|
42
48
|
},
|
43
49
|
];
|
@@ -51,6 +57,7 @@ export function getCurrencyMeta(shorthand: string): CurrencyMeta {
|
|
51
57
|
// This should never happen
|
52
58
|
icon: UnknownCurrencyIcon,
|
53
59
|
name: shorthand,
|
60
|
+
symbol: "$",
|
54
61
|
shorthand: shorthand as CurrencyMeta["shorthand"],
|
55
62
|
}
|
56
63
|
);
|
@@ -80,7 +80,9 @@ export function useFromTokenSelectionStates(options: {
|
|
80
80
|
|
81
81
|
// --------------------------------------------------------------------------
|
82
82
|
const firstSupportedSource = supportedSources?.length
|
83
|
-
? supportedSources
|
83
|
+
? supportedSources.length === 1
|
84
|
+
? supportedSources[0]
|
85
|
+
: supportedSources.find((x) => x.chain.id !== 1) // dont use mainnet as a default source, unless its the only source
|
84
86
|
: undefined;
|
85
87
|
|
86
88
|
// Source token and chain selection ---------------------------------------------------
|
@@ -1,21 +1,10 @@
|
|
1
|
-
import styled from "@emotion/styled";
|
2
|
-
import { ChevronDownIcon } from "@radix-ui/react-icons";
|
3
1
|
import type { Chain } from "../../../../../../../chains/types.js";
|
4
2
|
import type { ThirdwebClient } from "../../../../../../../client/client.js";
|
5
|
-
import {
|
6
|
-
import {
|
7
|
-
fontSize,
|
8
|
-
iconSize,
|
9
|
-
spacing,
|
10
|
-
} from "../../../../../../core/design-system/index.js";
|
11
|
-
import { useChainName } from "../../../../../../core/hooks/others/useChainQuery.js";
|
12
|
-
import { Skeleton } from "../../../../components/Skeleton.js";
|
3
|
+
import { fontSize } from "../../../../../../core/design-system/index.js";
|
13
4
|
import { Spacer } from "../../../../components/Spacer.js";
|
14
|
-
import { TokenIcon } from "../../../../components/TokenIcon.js";
|
15
5
|
import { Container } from "../../../../components/basic.js";
|
16
|
-
import { Button } from "../../../../components/buttons.js";
|
17
6
|
import { Input } from "../../../../components/formElements.js";
|
18
|
-
import {
|
7
|
+
import { TokenRow } from "../../../../components/token/TokenRow.js";
|
19
8
|
import { TokenSymbol } from "../../../../components/token/TokenSymbol.js";
|
20
9
|
import type { ERC20OrNativeToken } from "../../nativeToken.js";
|
21
10
|
import { getBuyTokenAmountFontSize } from "../utils.js";
|
@@ -35,7 +24,6 @@ export function BuyTokenInput(props: {
|
|
35
24
|
freezeAmount?: boolean;
|
36
25
|
freezeChainAndToken?: boolean;
|
37
26
|
}) {
|
38
|
-
const { name } = useChainName(props.chain);
|
39
27
|
const getWidth = () => {
|
40
28
|
let chars = props.value.replace(".", "").length;
|
41
29
|
const hasDot = props.value.includes(".");
|
@@ -144,70 +132,16 @@ export function BuyTokenInput(props: {
|
|
144
132
|
|
145
133
|
{/* Token / Chain selector */}
|
146
134
|
<Container flex="row" center="x">
|
147
|
-
<
|
148
|
-
|
149
|
-
|
150
|
-
|
151
|
-
|
152
|
-
}
|
153
|
-
|
154
|
-
onClick={props.onSelectToken}
|
155
|
-
disabled={props.freezeChainAndToken}
|
156
|
-
>
|
157
|
-
<Container flex="row" center="y" gap="sm">
|
158
|
-
<TokenIcon
|
159
|
-
token={props.token}
|
160
|
-
chain={props.chain}
|
161
|
-
size="md"
|
162
|
-
client={props.client}
|
163
|
-
/>
|
164
|
-
|
165
|
-
<Container
|
166
|
-
flex="column"
|
167
|
-
style={{
|
168
|
-
gap: "4px",
|
169
|
-
}}
|
170
|
-
>
|
171
|
-
{/* Token Symbol */}
|
172
|
-
<TokenSymbol
|
173
|
-
token={props.token}
|
174
|
-
chain={props.chain}
|
175
|
-
size="sm"
|
176
|
-
/>
|
177
|
-
|
178
|
-
{/* Network Name */}
|
179
|
-
{name ? (
|
180
|
-
<Text size="xs" color="secondaryText">
|
181
|
-
{name}
|
182
|
-
</Text>
|
183
|
-
) : (
|
184
|
-
<Skeleton width="90px" height={fontSize.xs} />
|
185
|
-
)}
|
186
|
-
</Container>
|
187
|
-
</Container>
|
188
|
-
|
189
|
-
<ChevronDownIcon
|
190
|
-
width={iconSize.sm}
|
191
|
-
height={iconSize.sm}
|
192
|
-
style={{
|
193
|
-
marginLeft: "auto",
|
194
|
-
}}
|
195
|
-
/>
|
196
|
-
</TokenButton>
|
135
|
+
<TokenRow
|
136
|
+
token={props.token}
|
137
|
+
chain={props.chain}
|
138
|
+
client={props.client}
|
139
|
+
onSelectToken={props.onSelectToken}
|
140
|
+
freezeChainAndToken={props.freezeChainAndToken}
|
141
|
+
/>
|
197
142
|
</Container>
|
198
143
|
</>
|
199
144
|
)}
|
200
145
|
</Container>
|
201
146
|
);
|
202
147
|
}
|
203
|
-
|
204
|
-
const TokenButton = /* @__PURE__ */ styled(Button)(() => {
|
205
|
-
const theme = useCustomTheme();
|
206
|
-
return {
|
207
|
-
background: theme.colors.tertiaryBg,
|
208
|
-
border: `1px solid ${theme.colors.borderColor}`,
|
209
|
-
justifyContent: "flex-start",
|
210
|
-
transition: "background 0.3s",
|
211
|
-
padding: spacing.sm,
|
212
|
-
};
|
213
|
-
});
|