@lifi/widget 3.12.6-alpha.0 → 3.13.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/CHANGELOG.md +15 -0
- package/dist/esm/AppProvider.js +9 -2
- package/dist/esm/AppProvider.js.map +1 -1
- package/dist/esm/components/ActiveTransactions/ActiveTransactionItem.js +15 -3
- package/dist/esm/components/ActiveTransactions/ActiveTransactionItem.js.map +1 -1
- package/dist/esm/components/ActiveTransactions/ActiveTransactions.js +4 -1
- package/dist/esm/components/ActiveTransactions/ActiveTransactions.js.map +1 -1
- package/dist/esm/components/ActiveTransactions/ActiveTransactions.style.d.ts +4 -6
- package/dist/esm/components/AlertMessage/AlertMessage.style.js +29 -12
- package/dist/esm/components/AlertMessage/AlertMessage.style.js.map +1 -1
- package/dist/esm/components/AmountInput/AmountInput.js +7 -1
- package/dist/esm/components/AmountInput/AmountInput.js.map +1 -1
- package/dist/esm/components/AmountInput/AmountInput.style.d.ts +1 -1
- package/dist/esm/components/AmountInput/AmountInputAdornment.style.d.ts +1 -1
- package/dist/esm/components/AmountInput/PriceFormHelperText.js +13 -2
- package/dist/esm/components/AmountInput/PriceFormHelperText.js.map +1 -1
- package/dist/esm/components/AppContainer.d.ts +1 -1
- package/dist/esm/components/AppContainer.js +34 -21
- package/dist/esm/components/AppContainer.js.map +1 -1
- package/dist/esm/components/Avatar/Avatar.style.d.ts +4 -2
- package/dist/esm/components/Avatar/Avatar.style.js +8 -6
- package/dist/esm/components/Avatar/Avatar.style.js.map +1 -1
- package/dist/esm/components/Avatar/SmallAvatar.d.ts +1 -1
- package/dist/esm/components/ButtonTertiary.d.ts +1 -1
- package/dist/esm/components/Card/Card.js +60 -33
- package/dist/esm/components/Card/Card.js.map +1 -1
- package/dist/esm/components/Card/CardHeader.d.ts +1 -1
- package/dist/esm/components/Card/CardLabel.js +46 -29
- package/dist/esm/components/Card/CardLabel.js.map +1 -1
- package/dist/esm/components/Card/CardTitle.js +12 -2
- package/dist/esm/components/Card/CardTitle.js.map +1 -1
- package/dist/esm/components/Card/InputCard.d.ts +1 -1
- package/dist/esm/components/ChainSelect/ChainSelect.js +3 -1
- package/dist/esm/components/ChainSelect/ChainSelect.js.map +1 -1
- package/dist/esm/components/ContractComponent/ItemPrice.js +2 -1
- package/dist/esm/components/ContractComponent/ItemPrice.js.map +1 -1
- package/dist/esm/components/ContractComponent/NFT/NFT.js +2 -1
- package/dist/esm/components/ContractComponent/NFT/NFT.js.map +1 -1
- package/dist/esm/components/ContractComponent/NFT/NFT.style.d.ts +1 -1
- package/dist/esm/components/ContractComponent/NFT/NFTBase.js +16 -1
- package/dist/esm/components/ContractComponent/NFT/NFTBase.js.map +1 -1
- package/dist/esm/components/FeeBreakdownTooltip.js +7 -2
- package/dist/esm/components/FeeBreakdownTooltip.js.map +1 -1
- package/dist/esm/components/GasMessage/FundsSufficiencyMessage.js +4 -1
- package/dist/esm/components/GasMessage/FundsSufficiencyMessage.js.map +1 -1
- package/dist/esm/components/GasMessage/GasMessage.style.js +8 -6
- package/dist/esm/components/GasMessage/GasMessage.style.js.map +1 -1
- package/dist/esm/components/GasMessage/GasRefuelMessage.js +11 -1
- package/dist/esm/components/GasMessage/GasRefuelMessage.js.map +1 -1
- package/dist/esm/components/GasMessage/GasSufficiencyMessage.js +9 -1
- package/dist/esm/components/GasMessage/GasSufficiencyMessage.js.map +1 -1
- package/dist/esm/components/Header/Header.style.d.ts +2 -2
- package/dist/esm/components/Header/NavigationHeader.js +11 -2
- package/dist/esm/components/Header/NavigationHeader.js.map +1 -1
- package/dist/esm/components/Header/SettingsButton.style.d.ts +1 -1
- package/dist/esm/components/Header/WalletMenu.js +12 -3
- package/dist/esm/components/Header/WalletMenu.js.map +1 -1
- package/dist/esm/components/IconTypography.js +4 -3
- package/dist/esm/components/IconTypography.js.map +1 -1
- package/dist/esm/components/ListItem/ListItem.d.ts +2 -4
- package/dist/esm/components/ListItem/ListItemButton.d.ts +1 -1
- package/dist/esm/components/ListItemButton.d.ts +1 -1
- package/dist/esm/components/ListItemButton.js +14 -3
- package/dist/esm/components/ListItemButton.js.map +1 -1
- package/dist/esm/components/NotFound.js +11 -1
- package/dist/esm/components/NotFound.js.map +1 -1
- package/dist/esm/components/PageContainer.d.ts +1 -1
- package/dist/esm/components/PageContainer.js +10 -4
- package/dist/esm/components/PageContainer.js.map +1 -1
- package/dist/esm/components/PoweredBy/PoweredBy.js +14 -2
- package/dist/esm/components/PoweredBy/PoweredBy.js.map +1 -1
- package/dist/esm/components/PoweredBy/PoweredBy.style.d.ts +1 -1
- package/dist/esm/components/ProgressToNextUpdate.js +8 -6
- package/dist/esm/components/ProgressToNextUpdate.js.map +1 -1
- package/dist/esm/components/RouteCard/RouteCard.js +9 -3
- package/dist/esm/components/RouteCard/RouteCard.js.map +1 -1
- package/dist/esm/components/RouteCard/RouteCardEssentials.js +28 -2
- package/dist/esm/components/RouteCard/RouteCardEssentials.js.map +1 -1
- package/dist/esm/components/RouteCard/RouteCardEssentialsExpanded.js +20 -1
- package/dist/esm/components/RouteCard/RouteCardEssentialsExpanded.js.map +1 -1
- package/dist/esm/components/RouteCard/RouteCardSkeleton.js +12 -2
- package/dist/esm/components/RouteCard/RouteCardSkeleton.js.map +1 -1
- package/dist/esm/components/RouteCard/RouteNotFoundCard.js +12 -1
- package/dist/esm/components/RouteCard/RouteNotFoundCard.js.map +1 -1
- package/dist/esm/components/Routes/Routes.js +12 -3
- package/dist/esm/components/Routes/Routes.js.map +1 -1
- package/dist/esm/components/Routes/RoutesExpanded.js +14 -4
- package/dist/esm/components/Routes/RoutesExpanded.js.map +1 -1
- package/dist/esm/components/Select.js +16 -5
- package/dist/esm/components/Select.js.map +1 -1
- package/dist/esm/components/SelectTokenButton/SelectTokenButton.style.d.ts +1 -1
- package/dist/esm/components/SelectTokenButton/SelectTokenButton.style.js +34 -8
- package/dist/esm/components/SelectTokenButton/SelectTokenButton.style.js.map +1 -1
- package/dist/esm/components/SendToWallet/SendToWallet.style.d.ts +1 -1
- package/dist/esm/components/SendToWallet/SendToWallet.style.js +28 -7
- package/dist/esm/components/SendToWallet/SendToWallet.style.js.map +1 -1
- package/dist/esm/components/SendToWallet/SendToWalletButton.js +9 -2
- package/dist/esm/components/SendToWallet/SendToWalletButton.js.map +1 -1
- package/dist/esm/components/SettingsListItemButton.d.ts +1 -1
- package/dist/esm/components/Skeleton/WidgetSkeleton.style.d.ts +3 -3
- package/dist/esm/components/Step/DestinationWalletAddress.js +10 -2
- package/dist/esm/components/Step/DestinationWalletAddress.js.map +1 -1
- package/dist/esm/components/Step/Step.js +5 -3
- package/dist/esm/components/Step/Step.js.map +1 -1
- package/dist/esm/components/Step/StepProcess.js +16 -3
- package/dist/esm/components/Step/StepProcess.js.map +1 -1
- package/dist/esm/components/Step/StepTimer.js +5 -1
- package/dist/esm/components/Step/StepTimer.js.map +1 -1
- package/dist/esm/components/StepActions/StepActions.js +22 -3
- package/dist/esm/components/StepActions/StepActions.js.map +1 -1
- package/dist/esm/components/StepActions/StepActions.style.d.ts +1 -1
- package/dist/esm/components/StepActions/StepActions.style.js +19 -10
- package/dist/esm/components/StepActions/StepActions.style.js.map +1 -1
- package/dist/esm/components/StepActions/StepFees.js +9 -1
- package/dist/esm/components/StepActions/StepFees.js.map +1 -1
- package/dist/esm/components/StepDivider/StepDivider.style.d.ts +1 -1
- package/dist/esm/components/Switch.js +12 -7
- package/dist/esm/components/Switch.js.map +1 -1
- package/dist/esm/components/Tabs/Tabs.style.js +16 -12
- package/dist/esm/components/Tabs/Tabs.style.js.map +1 -1
- package/dist/esm/components/ToAddressRequiredMessage.js +4 -1
- package/dist/esm/components/ToAddressRequiredMessage.js.map +1 -1
- package/dist/esm/components/Token/Token.js +47 -6
- package/dist/esm/components/Token/Token.js.map +1 -1
- package/dist/esm/components/Token/Token.style.js +14 -7
- package/dist/esm/components/Token/Token.style.js.map +1 -1
- package/dist/esm/components/TokenList/TokenList.style.d.ts +3 -5
- package/dist/esm/components/TokenList/TokenListItem.js +21 -4
- package/dist/esm/components/TokenList/TokenListItem.js.map +1 -1
- package/dist/esm/components/TokenList/VirtualizedTokenList.js +8 -1
- package/dist/esm/components/TokenList/VirtualizedTokenList.js.map +1 -1
- package/dist/esm/components/TransactionDetails.js +52 -6
- package/dist/esm/components/TransactionDetails.js.map +1 -1
- package/dist/esm/config/version.d.ts +1 -1
- package/dist/esm/config/version.js +1 -1
- package/dist/esm/config/version.js.map +1 -1
- package/dist/esm/hooks/useGasRefuel.js +6 -9
- package/dist/esm/hooks/useGasRefuel.js.map +1 -1
- package/dist/esm/hooks/useIsContractAddress.js.map +1 -1
- package/dist/esm/hooks/useRoutes.js +6 -4
- package/dist/esm/hooks/useRoutes.js.map +1 -1
- package/dist/esm/i18n/en.json +5 -1
- package/dist/esm/index.d.ts +1 -1
- package/dist/esm/index.js +1 -1
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/pages/ActiveTransactionsPage/ActiveTransactionsEmpty.js +11 -1
- package/dist/esm/pages/ActiveTransactionsPage/ActiveTransactionsEmpty.js.map +1 -1
- package/dist/esm/pages/MainPage/MainPage.js +6 -1
- package/dist/esm/pages/MainPage/MainPage.js.map +1 -1
- package/dist/esm/pages/MainPage/MainPage.style.d.ts +1 -1
- package/dist/esm/pages/SelectTokenPage/SelectTokenPage.js +8 -1
- package/dist/esm/pages/SelectTokenPage/SelectTokenPage.js.map +1 -1
- package/dist/esm/pages/SendToWallet/BookmarkAddressSheet.js +4 -1
- package/dist/esm/pages/SendToWallet/BookmarkAddressSheet.js.map +1 -1
- package/dist/esm/pages/SendToWallet/ConfirmAddressSheet.js +4 -1
- package/dist/esm/pages/SendToWallet/ConfirmAddressSheet.js.map +1 -1
- package/dist/esm/pages/SendToWallet/EmptyListIndicator.js +5 -1
- package/dist/esm/pages/SendToWallet/EmptyListIndicator.js.map +1 -1
- package/dist/esm/pages/SendToWallet/SendToWalletPage.js +7 -1
- package/dist/esm/pages/SendToWallet/SendToWalletPage.js.map +1 -1
- package/dist/esm/pages/SendToWallet/SendToWalletPage.style.d.ts +4 -4
- package/dist/esm/pages/SendToWallet/SendToWalletPage.style.js +6 -6
- package/dist/esm/pages/SendToWallet/SendToWalletPage.style.js.map +1 -1
- package/dist/esm/pages/SettingsPage/ResetSettingsButton.js +9 -2
- package/dist/esm/pages/SettingsPage/ResetSettingsButton.js.map +1 -1
- package/dist/esm/pages/SettingsPage/ResetSettingsButton.style.js.map +1 -1
- package/dist/esm/pages/SettingsPage/SettingsCard/SettingCard.style.d.ts +1 -1
- package/dist/esm/pages/SettingsPage/SlippageSettings/SlippageSettings.js +7 -2
- package/dist/esm/pages/SettingsPage/SlippageSettings/SlippageSettings.js.map +1 -1
- package/dist/esm/pages/SettingsPage/SlippageSettings/SlippageSettings.style.js +4 -3
- package/dist/esm/pages/SettingsPage/SlippageSettings/SlippageSettings.style.js.map +1 -1
- package/dist/esm/pages/TransactionDetailsPage/TransactionDetailsPage.js +10 -3
- package/dist/esm/pages/TransactionDetailsPage/TransactionDetailsPage.js.map +1 -1
- package/dist/esm/pages/TransactionDetailsPage/TransactionDetailsSkeleton.js +16 -3
- package/dist/esm/pages/TransactionDetailsPage/TransactionDetailsSkeleton.js.map +1 -1
- package/dist/esm/pages/TransactionDetailsPage/TransferIdCard.js +6 -1
- package/dist/esm/pages/TransactionDetailsPage/TransferIdCard.js.map +1 -1
- package/dist/esm/pages/TransactionHistoryPage/TransactionHistoryEmpty.js +11 -1
- package/dist/esm/pages/TransactionHistoryPage/TransactionHistoryEmpty.js.map +1 -1
- package/dist/esm/pages/TransactionHistoryPage/TransactionHistoryItem.js +14 -2
- package/dist/esm/pages/TransactionHistoryPage/TransactionHistoryItem.js.map +1 -1
- package/dist/esm/pages/TransactionHistoryPage/TransactionHistorySkeleton.js +10 -2
- package/dist/esm/pages/TransactionHistoryPage/TransactionHistorySkeleton.js.map +1 -1
- package/dist/esm/pages/TransactionPage/ExchangeRateBottomSheet.js +35 -3
- package/dist/esm/pages/TransactionPage/ExchangeRateBottomSheet.js.map +1 -1
- package/dist/esm/pages/TransactionPage/StatusBottomSheet.js +12 -2
- package/dist/esm/pages/TransactionPage/StatusBottomSheet.js.map +1 -1
- package/dist/esm/pages/TransactionPage/TokenValueBottomSheet.js +45 -1
- package/dist/esm/pages/TransactionPage/TokenValueBottomSheet.js.map +1 -1
- package/dist/esm/pages/TransactionPage/TransactionPage.js +4 -1
- package/dist/esm/pages/TransactionPage/TransactionPage.js.map +1 -1
- package/dist/esm/types/widget.d.ts +2 -1
- package/package.json +10 -11
- package/src/AppProvider.tsx +16 -2
- package/src/components/ActiveTransactions/ActiveTransactionItem.tsx +16 -9
- package/src/components/ActiveTransactions/ActiveTransactions.tsx +7 -1
- package/src/components/AlertMessage/AlertMessage.style.tsx +30 -14
- package/src/components/AmountInput/AmountInput.tsx +9 -1
- package/src/components/AmountInput/PriceFormHelperText.tsx +12 -10
- package/src/components/AppContainer.tsx +34 -23
- package/src/components/Avatar/Avatar.style.tsx +8 -8
- package/src/components/Card/Card.tsx +60 -37
- package/src/components/Card/CardLabel.tsx +69 -43
- package/src/components/Card/CardTitle.tsx +12 -2
- package/src/components/ChainSelect/ChainSelect.tsx +7 -1
- package/src/components/ContractComponent/ItemPrice.tsx +8 -3
- package/src/components/ContractComponent/NFT/NFT.tsx +8 -3
- package/src/components/ContractComponent/NFT/NFTBase.tsx +33 -6
- package/src/components/FeeBreakdownTooltip.tsx +9 -3
- package/src/components/GasMessage/FundsSufficiencyMessage.tsx +7 -1
- package/src/components/GasMessage/GasMessage.style.ts +8 -8
- package/src/components/GasMessage/GasRefuelMessage.tsx +19 -6
- package/src/components/GasMessage/GasSufficiencyMessage.tsx +21 -3
- package/src/components/Header/NavigationHeader.tsx +23 -5
- package/src/components/Header/WalletMenu.tsx +18 -3
- package/src/components/IconTypography.ts +4 -4
- package/src/components/ListItemButton.tsx +21 -12
- package/src/components/NotFound.tsx +17 -6
- package/src/components/PageContainer.ts +19 -15
- package/src/components/PoweredBy/PoweredBy.tsx +16 -8
- package/src/components/ProgressToNextUpdate.tsx +8 -8
- package/src/components/RouteCard/RouteCard.tsx +14 -4
- package/src/components/RouteCard/RouteCardEssentials.tsx +38 -16
- package/src/components/RouteCard/RouteCardEssentialsExpanded.tsx +30 -11
- package/src/components/RouteCard/RouteCardSkeleton.tsx +19 -3
- package/src/components/RouteCard/RouteNotFoundCard.tsx +18 -7
- package/src/components/Routes/Routes.tsx +20 -6
- package/src/components/Routes/RoutesExpanded.tsx +25 -6
- package/src/components/Select.tsx +16 -6
- package/src/components/SelectTokenButton/SelectTokenButton.style.tsx +34 -8
- package/src/components/SendToWallet/SendToWallet.style.tsx +28 -7
- package/src/components/SendToWallet/SendToWalletButton.tsx +21 -5
- package/src/components/Step/DestinationWalletAddress.tsx +14 -2
- package/src/components/Step/Step.tsx +7 -3
- package/src/components/Step/StepProcess.tsx +18 -9
- package/src/components/Step/StepTimer.tsx +9 -5
- package/src/components/StepActions/StepActions.style.tsx +19 -13
- package/src/components/StepActions/StepActions.tsx +32 -10
- package/src/components/StepActions/StepFees.tsx +9 -4
- package/src/components/Switch.tsx +12 -9
- package/src/components/Tabs/Tabs.style.tsx +16 -16
- package/src/components/ToAddressRequiredMessage.tsx +7 -1
- package/src/components/Token/Token.style.tsx +14 -8
- package/src/components/Token/Token.tsx +75 -12
- package/src/components/TokenList/TokenListItem.tsx +37 -8
- package/src/components/TokenList/VirtualizedTokenList.tsx +8 -6
- package/src/components/TransactionDetails.tsx +75 -17
- package/src/config/version.ts +1 -1
- package/src/hooks/useGasRefuel.ts +6 -18
- package/src/hooks/useIsContractAddress.ts +1 -0
- package/src/hooks/useRoutes.ts +6 -4
- package/src/i18n/en.json +5 -1
- package/src/i18n/i18next.d.ts +4 -8
- package/src/index.ts +1 -1
- package/src/pages/ActiveTransactionsPage/ActiveTransactionsEmpty.tsx +17 -6
- package/src/pages/MainPage/MainPage.tsx +16 -9
- package/src/pages/SelectTokenPage/SelectTokenPage.tsx +17 -3
- package/src/pages/SendToWallet/BookmarkAddressSheet.tsx +6 -1
- package/src/pages/SendToWallet/ConfirmAddressSheet.tsx +6 -1
- package/src/pages/SendToWallet/EmptyListIndicator.tsx +7 -1
- package/src/pages/SendToWallet/SendToWalletPage.style.tsx +6 -9
- package/src/pages/SendToWallet/SendToWalletPage.tsx +17 -3
- package/src/pages/SettingsPage/ResetSettingsButton.style.tsx +0 -1
- package/src/pages/SettingsPage/ResetSettingsButton.tsx +18 -3
- package/src/pages/SettingsPage/SlippageSettings/SlippageSettings.style.tsx +4 -5
- package/src/pages/SettingsPage/SlippageSettings/SlippageSettings.tsx +11 -2
- package/src/pages/TransactionDetailsPage/TransactionDetailsPage.tsx +16 -4
- package/src/pages/TransactionDetailsPage/TransactionDetailsSkeleton.tsx +29 -9
- package/src/pages/TransactionDetailsPage/TransferIdCard.tsx +6 -4
- package/src/pages/TransactionHistoryPage/TransactionHistoryEmpty.tsx +17 -6
- package/src/pages/TransactionHistoryPage/TransactionHistoryItem.tsx +24 -6
- package/src/pages/TransactionHistoryPage/TransactionHistorySkeleton.tsx +14 -4
- package/src/pages/TransactionPage/ExchangeRateBottomSheet.tsx +70 -11
- package/src/pages/TransactionPage/StatusBottomSheet.tsx +27 -4
- package/src/pages/TransactionPage/TokenValueBottomSheet.tsx +92 -15
- package/src/pages/TransactionPage/TransactionPage.tsx +6 -1
- package/src/types/widget.ts +2 -1
- package/tsconfig.json +4 -2
|
@@ -98,15 +98,36 @@ export const TokenBase: FC<TokenProps & BoxProps> = ({
|
|
|
98
98
|
) : null
|
|
99
99
|
|
|
100
100
|
return (
|
|
101
|
-
<Box
|
|
101
|
+
<Box
|
|
102
|
+
{...other}
|
|
103
|
+
sx={[
|
|
104
|
+
{
|
|
105
|
+
flex: 1,
|
|
106
|
+
display: 'flex',
|
|
107
|
+
alignItems: 'center',
|
|
108
|
+
},
|
|
109
|
+
...(Array.isArray(other.sx) ? other.sx : [other.sx]),
|
|
110
|
+
]}
|
|
111
|
+
>
|
|
102
112
|
<TokenAvatar
|
|
103
113
|
token={token}
|
|
104
114
|
chain={chain}
|
|
105
115
|
isLoading={isLoading}
|
|
106
116
|
sx={{ marginRight: 2 }}
|
|
107
117
|
/>
|
|
108
|
-
<Box
|
|
109
|
-
|
|
118
|
+
<Box
|
|
119
|
+
sx={{
|
|
120
|
+
flex: 1,
|
|
121
|
+
}}
|
|
122
|
+
>
|
|
123
|
+
<Box
|
|
124
|
+
sx={{
|
|
125
|
+
mb: 0.5,
|
|
126
|
+
height: 24,
|
|
127
|
+
display: 'flex',
|
|
128
|
+
alignItems: 'center',
|
|
129
|
+
}}
|
|
130
|
+
>
|
|
110
131
|
<TextFitter
|
|
111
132
|
height={30}
|
|
112
133
|
textStyle={{
|
|
@@ -118,7 +139,7 @@ export const TokenBase: FC<TokenProps & BoxProps> = ({
|
|
|
118
139
|
})}
|
|
119
140
|
</TextFitter>
|
|
120
141
|
</Box>
|
|
121
|
-
<TextSecondaryContainer
|
|
142
|
+
<TextSecondaryContainer as="span">
|
|
122
143
|
<TextSecondary>
|
|
123
144
|
{t('format.currency', {
|
|
124
145
|
value: tokenPrice,
|
|
@@ -175,7 +196,14 @@ const TokenStep: FC<PropsWithChildren<Partial<TokenProps>>> = ({
|
|
|
175
196
|
children,
|
|
176
197
|
}) => {
|
|
177
198
|
return (
|
|
178
|
-
<Box
|
|
199
|
+
<Box
|
|
200
|
+
sx={{
|
|
201
|
+
flex: 1,
|
|
202
|
+
position: 'relative',
|
|
203
|
+
overflow: 'hidden',
|
|
204
|
+
height: 16,
|
|
205
|
+
}}
|
|
206
|
+
>
|
|
179
207
|
<Grow
|
|
180
208
|
in={!stepVisible && !disableDescription}
|
|
181
209
|
style={{
|
|
@@ -184,7 +212,13 @@ const TokenStep: FC<PropsWithChildren<Partial<TokenProps>>> = ({
|
|
|
184
212
|
appear={false}
|
|
185
213
|
timeout={225}
|
|
186
214
|
>
|
|
187
|
-
<Box
|
|
215
|
+
<Box
|
|
216
|
+
sx={{
|
|
217
|
+
display: 'flex',
|
|
218
|
+
alignItems: 'center',
|
|
219
|
+
height: 16,
|
|
220
|
+
}}
|
|
221
|
+
>
|
|
188
222
|
{children as ReactElement}
|
|
189
223
|
</Box>
|
|
190
224
|
</Grow>
|
|
@@ -196,8 +230,19 @@ const TokenStep: FC<PropsWithChildren<Partial<TokenProps>>> = ({
|
|
|
196
230
|
appear={false}
|
|
197
231
|
timeout={225}
|
|
198
232
|
>
|
|
199
|
-
<Box
|
|
200
|
-
|
|
233
|
+
<Box
|
|
234
|
+
sx={{
|
|
235
|
+
display: 'flex',
|
|
236
|
+
alignItems: 'center',
|
|
237
|
+
height: 16,
|
|
238
|
+
}}
|
|
239
|
+
>
|
|
240
|
+
<Box
|
|
241
|
+
sx={{
|
|
242
|
+
mr: 0.75,
|
|
243
|
+
height: 16,
|
|
244
|
+
}}
|
|
245
|
+
>
|
|
201
246
|
<SmallAvatar
|
|
202
247
|
src={step?.toolDetails.logoURI}
|
|
203
248
|
alt={step?.toolDetails.name}
|
|
@@ -218,12 +263,30 @@ export const TokenSkeleton: FC<Partial<TokenProps> & BoxProps> = ({
|
|
|
218
263
|
...other
|
|
219
264
|
}) => {
|
|
220
265
|
return (
|
|
221
|
-
<Box
|
|
222
|
-
|
|
266
|
+
<Box
|
|
267
|
+
{...other}
|
|
268
|
+
sx={[
|
|
269
|
+
{
|
|
270
|
+
flex: 1,
|
|
271
|
+
},
|
|
272
|
+
...(Array.isArray(other.sx) ? other.sx : [other.sx]),
|
|
273
|
+
]}
|
|
274
|
+
>
|
|
275
|
+
<Box
|
|
276
|
+
sx={{
|
|
277
|
+
display: 'flex',
|
|
278
|
+
flex: 1,
|
|
279
|
+
alignItems: 'center',
|
|
280
|
+
}}
|
|
281
|
+
>
|
|
223
282
|
<AvatarBadgedSkeleton sx={{ marginRight: 2 }} />
|
|
224
|
-
<Box
|
|
283
|
+
<Box
|
|
284
|
+
sx={{
|
|
285
|
+
flex: 1,
|
|
286
|
+
}}
|
|
287
|
+
>
|
|
225
288
|
<Skeleton width={112} height={24} variant="text" />
|
|
226
|
-
<TextSecondaryContainer
|
|
289
|
+
<TextSecondaryContainer as="span">
|
|
227
290
|
<Skeleton
|
|
228
291
|
width={48}
|
|
229
292
|
height={12}
|
|
@@ -112,7 +112,13 @@ export const TokenListItemButton: React.FC<TokenListItemButtonProps> = ({
|
|
|
112
112
|
component: 'div',
|
|
113
113
|
}}
|
|
114
114
|
secondary={
|
|
115
|
-
<Box
|
|
115
|
+
<Box
|
|
116
|
+
ref={container}
|
|
117
|
+
sx={{
|
|
118
|
+
position: 'relative',
|
|
119
|
+
height: 20,
|
|
120
|
+
}}
|
|
121
|
+
>
|
|
116
122
|
<Slide
|
|
117
123
|
direction="down"
|
|
118
124
|
in={!showAddress}
|
|
@@ -122,7 +128,13 @@ export const TokenListItemButton: React.FC<TokenListItemButtonProps> = ({
|
|
|
122
128
|
}}
|
|
123
129
|
appear={false}
|
|
124
130
|
>
|
|
125
|
-
<Box
|
|
131
|
+
<Box
|
|
132
|
+
sx={{
|
|
133
|
+
pt: 0.25,
|
|
134
|
+
}}
|
|
135
|
+
>
|
|
136
|
+
{token.name}
|
|
137
|
+
</Box>
|
|
126
138
|
</Slide>
|
|
127
139
|
<Slide
|
|
128
140
|
direction="up"
|
|
@@ -134,8 +146,18 @@ export const TokenListItemButton: React.FC<TokenListItemButtonProps> = ({
|
|
|
134
146
|
appear={false}
|
|
135
147
|
mountOnEnter
|
|
136
148
|
>
|
|
137
|
-
<Box
|
|
138
|
-
|
|
149
|
+
<Box
|
|
150
|
+
sx={{
|
|
151
|
+
display: 'flex',
|
|
152
|
+
}}
|
|
153
|
+
>
|
|
154
|
+
<Box
|
|
155
|
+
sx={{
|
|
156
|
+
display: 'flex',
|
|
157
|
+
alignItems: 'center',
|
|
158
|
+
pt: 0.125,
|
|
159
|
+
}}
|
|
160
|
+
>
|
|
139
161
|
{shortenAddress(tokenAddress)}
|
|
140
162
|
</Box>
|
|
141
163
|
<IconButton
|
|
@@ -159,7 +181,12 @@ export const TokenListItemButton: React.FC<TokenListItemButtonProps> = ({
|
|
|
159
181
|
) : (
|
|
160
182
|
<Box sx={{ textAlign: 'right' }}>
|
|
161
183
|
{token.amount ? (
|
|
162
|
-
<Typography
|
|
184
|
+
<Typography
|
|
185
|
+
noWrap
|
|
186
|
+
sx={{
|
|
187
|
+
fontWeight: 600,
|
|
188
|
+
}}
|
|
189
|
+
>
|
|
163
190
|
{t('format.number', {
|
|
164
191
|
value: formatTokenAmount(token.amount, token.decimals),
|
|
165
192
|
})}
|
|
@@ -167,10 +194,12 @@ export const TokenListItemButton: React.FC<TokenListItemButtonProps> = ({
|
|
|
167
194
|
) : null}
|
|
168
195
|
{tokenPrice ? (
|
|
169
196
|
<Typography
|
|
170
|
-
fontWeight={500}
|
|
171
|
-
fontSize={12}
|
|
172
|
-
color="text.secondary"
|
|
173
197
|
data-price={token.priceUSD}
|
|
198
|
+
sx={{
|
|
199
|
+
fontWeight: 500,
|
|
200
|
+
fontSize: 12,
|
|
201
|
+
color: 'text.secondary',
|
|
202
|
+
}}
|
|
174
203
|
>
|
|
175
204
|
{t('format.currency', {
|
|
176
205
|
value: tokenPrice,
|
|
@@ -131,12 +131,14 @@ export const VirtualizedTokenList: FC<VirtualizedTokenListProps> = ({
|
|
|
131
131
|
startAdornment={
|
|
132
132
|
startAdornmentLabel ? (
|
|
133
133
|
<Typography
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
134
|
+
sx={{
|
|
135
|
+
fontSize: 14,
|
|
136
|
+
fontWeight: 600,
|
|
137
|
+
lineHeight: '16px',
|
|
138
|
+
px: 1.5,
|
|
139
|
+
pt: isFirstFeaturedToken ? 0 : 1,
|
|
140
|
+
pb: 1,
|
|
141
|
+
}}
|
|
140
142
|
>
|
|
141
143
|
{startAdornmentLabel}
|
|
142
144
|
</Typography>
|
|
@@ -71,30 +71,48 @@ export const TransactionDetails: React.FC<TransactionDetailsProps> = ({
|
|
|
71
71
|
|
|
72
72
|
return (
|
|
73
73
|
<Card selectionColor="secondary" {...props}>
|
|
74
|
-
<Box
|
|
75
|
-
|
|
74
|
+
<Box
|
|
75
|
+
sx={{
|
|
76
|
+
display: 'flex',
|
|
77
|
+
alignItems: 'center',
|
|
78
|
+
px: 2,
|
|
79
|
+
py: 1.75,
|
|
80
|
+
}}
|
|
81
|
+
>
|
|
82
|
+
<Box
|
|
83
|
+
sx={{
|
|
84
|
+
display: 'flex',
|
|
85
|
+
flex: 1,
|
|
86
|
+
alignItems: 'center',
|
|
87
|
+
justifyContent: 'left',
|
|
88
|
+
}}
|
|
89
|
+
>
|
|
76
90
|
<TokenRate route={route} />
|
|
77
91
|
</Box>
|
|
78
92
|
<Collapse timeout={100} in={!cardExpanded} mountOnEnter>
|
|
79
93
|
<FeeBreakdownTooltip gasCosts={gasCosts} feeCosts={feeCosts}>
|
|
80
94
|
<Box
|
|
81
|
-
display="flex"
|
|
82
|
-
alignItems="center"
|
|
83
95
|
onClick={toggleCard}
|
|
84
96
|
// biome-ignore lint/a11y/useSemanticElements:
|
|
85
97
|
role="button"
|
|
86
|
-
sx={{
|
|
87
|
-
|
|
98
|
+
sx={{
|
|
99
|
+
display: 'flex',
|
|
100
|
+
alignItems: 'center',
|
|
101
|
+
px: 1,
|
|
102
|
+
cursor: 'pointer',
|
|
103
|
+
}}
|
|
88
104
|
>
|
|
89
105
|
<IconTypography mr={0.5} fontSize={16}>
|
|
90
106
|
<LocalGasStationRounded fontSize="inherit" />
|
|
91
107
|
</IconTypography>
|
|
92
108
|
<Typography
|
|
93
|
-
fontSize={14}
|
|
94
|
-
color="text.primary"
|
|
95
|
-
fontWeight="600"
|
|
96
|
-
lineHeight={1.429}
|
|
97
109
|
data-value={combinedFeesUSD}
|
|
110
|
+
sx={{
|
|
111
|
+
fontSize: 14,
|
|
112
|
+
color: 'text.primary',
|
|
113
|
+
fontWeight: '600',
|
|
114
|
+
lineHeight: 1.429,
|
|
115
|
+
}}
|
|
98
116
|
>
|
|
99
117
|
{t('format.currency', { value: combinedFeesUSD })}
|
|
100
118
|
</Typography>
|
|
@@ -110,8 +128,19 @@ export const TransactionDetails: React.FC<TransactionDetailsProps> = ({
|
|
|
110
128
|
</CardIconButton>
|
|
111
129
|
</Box>
|
|
112
130
|
<Collapse timeout={225} in={cardExpanded} mountOnEnter>
|
|
113
|
-
<Box
|
|
114
|
-
|
|
131
|
+
<Box
|
|
132
|
+
sx={{
|
|
133
|
+
px: 2,
|
|
134
|
+
pb: 2,
|
|
135
|
+
}}
|
|
136
|
+
>
|
|
137
|
+
<Box
|
|
138
|
+
sx={{
|
|
139
|
+
display: 'flex',
|
|
140
|
+
justifyContent: 'space-between',
|
|
141
|
+
mb: 0.5,
|
|
142
|
+
}}
|
|
143
|
+
>
|
|
115
144
|
<Typography variant="body2">{t('main.fees.network')}</Typography>
|
|
116
145
|
<FeeBreakdownTooltip gasCosts={gasCosts}>
|
|
117
146
|
<Typography variant="body2">
|
|
@@ -122,7 +151,13 @@ export const TransactionDetails: React.FC<TransactionDetailsProps> = ({
|
|
|
122
151
|
</FeeBreakdownTooltip>
|
|
123
152
|
</Box>
|
|
124
153
|
{feeCosts.length ? (
|
|
125
|
-
<Box
|
|
154
|
+
<Box
|
|
155
|
+
sx={{
|
|
156
|
+
display: 'flex',
|
|
157
|
+
justifyContent: 'space-between',
|
|
158
|
+
mb: 0.5,
|
|
159
|
+
}}
|
|
160
|
+
>
|
|
126
161
|
<Typography variant="body2">{t('main.fees.provider')}</Typography>
|
|
127
162
|
<FeeBreakdownTooltip feeCosts={feeCosts}>
|
|
128
163
|
<Typography variant="body2">
|
|
@@ -134,7 +169,13 @@ export const TransactionDetails: React.FC<TransactionDetailsProps> = ({
|
|
|
134
169
|
</Box>
|
|
135
170
|
) : null}
|
|
136
171
|
{showIntegratorFeeCollectionDetails ? (
|
|
137
|
-
<Box
|
|
172
|
+
<Box
|
|
173
|
+
sx={{
|
|
174
|
+
display: 'flex',
|
|
175
|
+
justifyContent: 'space-between',
|
|
176
|
+
mb: 0.5,
|
|
177
|
+
}}
|
|
178
|
+
>
|
|
138
179
|
<Typography variant="body2">
|
|
139
180
|
{feeConfig?.name
|
|
140
181
|
? t('main.fees.integrator', { tool: feeConfig.name })
|
|
@@ -160,7 +201,13 @@ export const TransactionDetails: React.FC<TransactionDetailsProps> = ({
|
|
|
160
201
|
)}
|
|
161
202
|
</Box>
|
|
162
203
|
) : null}
|
|
163
|
-
<Box
|
|
204
|
+
<Box
|
|
205
|
+
sx={{
|
|
206
|
+
display: 'flex',
|
|
207
|
+
justifyContent: 'space-between',
|
|
208
|
+
mb: 0.5,
|
|
209
|
+
}}
|
|
210
|
+
>
|
|
164
211
|
<Typography variant="body2">{t('main.priceImpact')}</Typography>
|
|
165
212
|
<Tooltip title={t('tooltip.priceImpact')} sx={{ cursor: 'help' }}>
|
|
166
213
|
<Typography variant="body2">
|
|
@@ -170,7 +217,13 @@ export const TransactionDetails: React.FC<TransactionDetailsProps> = ({
|
|
|
170
217
|
</Box>
|
|
171
218
|
{!isRouteDone(route) ? (
|
|
172
219
|
<>
|
|
173
|
-
<Box
|
|
220
|
+
<Box
|
|
221
|
+
sx={{
|
|
222
|
+
display: 'flex',
|
|
223
|
+
justifyContent: 'space-between',
|
|
224
|
+
mb: 0.5,
|
|
225
|
+
}}
|
|
226
|
+
>
|
|
174
227
|
<Typography variant="body2">{t('main.maxSlippage')}</Typography>
|
|
175
228
|
<Tooltip title={t('tooltip.slippage')} sx={{ cursor: 'help' }}>
|
|
176
229
|
<Typography variant="body2">
|
|
@@ -180,7 +233,12 @@ export const TransactionDetails: React.FC<TransactionDetailsProps> = ({
|
|
|
180
233
|
</Typography>
|
|
181
234
|
</Tooltip>
|
|
182
235
|
</Box>
|
|
183
|
-
<Box
|
|
236
|
+
<Box
|
|
237
|
+
sx={{
|
|
238
|
+
display: 'flex',
|
|
239
|
+
justifyContent: 'space-between',
|
|
240
|
+
}}
|
|
241
|
+
>
|
|
184
242
|
<Typography variant="body2">{t('main.minReceived')}</Typography>
|
|
185
243
|
<Tooltip
|
|
186
244
|
title={t('tooltip.minReceived')}
|
package/src/config/version.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
export const name = '@lifi/widget'
|
|
2
|
-
export const version = '3.
|
|
2
|
+
export const version = '3.13.0'
|
|
@@ -19,29 +19,18 @@ export const useGasRefuel = () => {
|
|
|
19
19
|
const toChain = getChainById(toChainId)
|
|
20
20
|
const fromChain = getChainById(fromChainId)
|
|
21
21
|
|
|
22
|
-
const {
|
|
22
|
+
const { account: toAccount } = useAccount({ chainType: toChain?.chainType })
|
|
23
23
|
|
|
24
|
-
const
|
|
25
|
-
(account) => account.chainType === fromChain?.chainType
|
|
26
|
-
)
|
|
27
|
-
|
|
28
|
-
const toAccount = accounts.find(
|
|
29
|
-
(account) => account.chainType === toChain?.chainType
|
|
30
|
-
)
|
|
24
|
+
const effectiveToAddress = toAddress || toAccount?.address
|
|
31
25
|
|
|
32
|
-
const isFromContractAddress = useIsContractAddress(
|
|
33
|
-
fromAccount?.address,
|
|
34
|
-
fromChainId,
|
|
35
|
-
fromAccount?.chainType
|
|
36
|
-
)
|
|
37
26
|
const isToContractAddress = useIsContractAddress(
|
|
38
|
-
|
|
27
|
+
effectiveToAddress,
|
|
39
28
|
toChainId,
|
|
40
29
|
toChain?.chainType
|
|
41
30
|
)
|
|
42
31
|
|
|
43
32
|
const { token: destinationNativeToken } = useTokenBalance(
|
|
44
|
-
|
|
33
|
+
effectiveToAddress,
|
|
45
34
|
toChainId ? toChain?.nativeToken : undefined
|
|
46
35
|
)
|
|
47
36
|
|
|
@@ -55,9 +44,8 @@ export const useGasRefuel = () => {
|
|
|
55
44
|
const isChainTypeSatisfied =
|
|
56
45
|
fromChain?.chainType !== toChain?.chainType ? Boolean(toAddress) : true
|
|
57
46
|
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
: true
|
|
47
|
+
// We should not refuel to the contract address
|
|
48
|
+
const isToAddressSatisfied = effectiveToAddress && !isToContractAddress
|
|
61
49
|
|
|
62
50
|
const enabled = useMemo(() => {
|
|
63
51
|
if (
|
package/src/hooks/useRoutes.ts
CHANGED
|
@@ -177,6 +177,7 @@ export const useRoutes = ({ observableRoute }: RoutesProps = {}) => {
|
|
|
177
177
|
signal,
|
|
178
178
|
}) => {
|
|
179
179
|
const fromAmount = parseUnits(fromTokenAmount, fromToken!.decimals)
|
|
180
|
+
const toAmount = parseUnits(toTokenAmount, toToken!.decimals)
|
|
180
181
|
const formattedSlippage = Number.parseFloat(slippage) / 100
|
|
181
182
|
|
|
182
183
|
const allowBridges = swapOnly
|
|
@@ -210,17 +211,18 @@ export const useRoutes = ({ observableRoute }: RoutesProps = {}) => {
|
|
|
210
211
|
fromAddress,
|
|
211
212
|
toAddress,
|
|
212
213
|
fromAmount,
|
|
214
|
+
toAmount,
|
|
213
215
|
slippage: formattedSlippage,
|
|
214
216
|
})
|
|
215
217
|
|
|
216
|
-
if (subvariant === 'custom' && contractCalls &&
|
|
218
|
+
if (subvariant === 'custom' && contractCalls && toAmount) {
|
|
217
219
|
const contractCallQuote = await getContractCallsQuote(
|
|
218
220
|
{
|
|
219
221
|
// Contract calls are enabled only when fromAddress is set
|
|
220
222
|
fromAddress: fromAddress as string,
|
|
221
223
|
fromChain: fromChainId,
|
|
222
224
|
fromToken: fromTokenAddress,
|
|
223
|
-
toAmount:
|
|
225
|
+
toAmount: toAmount.toString(),
|
|
224
226
|
toChain: toChainId,
|
|
225
227
|
toToken: toTokenAddress,
|
|
226
228
|
contractCalls,
|
|
@@ -265,8 +267,8 @@ export const useRoutes = ({ observableRoute }: RoutesProps = {}) => {
|
|
|
265
267
|
fromAddress: contractCallQuote.action.fromAddress,
|
|
266
268
|
toChainId: contractCallQuote.action.toChainId,
|
|
267
269
|
toAmountUSD: contractCallQuote.estimate.toAmountUSD || '',
|
|
268
|
-
toAmount:
|
|
269
|
-
toAmountMin:
|
|
270
|
+
toAmount: contractCallQuote.estimate.toAmount,
|
|
271
|
+
toAmountMin: contractCallQuote.estimate.toAmountMin,
|
|
270
272
|
toToken: toToken!,
|
|
271
273
|
toAddress:
|
|
272
274
|
contractCallQuote.action.toAddress ||
|
package/src/i18n/en.json
CHANGED
|
@@ -52,12 +52,14 @@
|
|
|
52
52
|
},
|
|
53
53
|
"header": {
|
|
54
54
|
"activeTransactions": "Active transactions",
|
|
55
|
+
"amount": "Amount",
|
|
55
56
|
"bookmarkedWallets": "Bookmarked wallets",
|
|
56
57
|
"bridge": "Bridge",
|
|
57
58
|
"checkout": "Checkout",
|
|
58
59
|
"checkoutDetails": "Checkout details",
|
|
59
60
|
"deposit": "Deposit",
|
|
60
61
|
"depositDetails": "Deposit details",
|
|
62
|
+
"depositTo": "Deposit to",
|
|
61
63
|
"exchange": "Exchange",
|
|
62
64
|
"from": "Exchange from",
|
|
63
65
|
"gas": "Gas",
|
|
@@ -265,13 +267,15 @@
|
|
|
265
267
|
"stepBridge": "Bridge",
|
|
266
268
|
"stepBridgeAndBuy": "Bridge and buy",
|
|
267
269
|
"stepBridgeAndDeposit": "Bridge and deposit",
|
|
270
|
+
"stepBuy": "Buy",
|
|
271
|
+
"stepDeposit": "Deposit",
|
|
268
272
|
"stepDetails": "{{tool}} via LI.FI",
|
|
269
273
|
"stepSwap": "Swap",
|
|
270
274
|
"stepSwapAndBridge": "Swap and bridge",
|
|
271
275
|
"stepSwapAndBuy": "Swap and buy",
|
|
272
276
|
"stepSwapAndDeposit": "Swap and deposit",
|
|
273
|
-
"transferId": "Transfer ID",
|
|
274
277
|
"swapStepDetails": "Swap on {{chain}} via {{tool}}",
|
|
278
|
+
"transferId": "Transfer ID",
|
|
275
279
|
"tags": {
|
|
276
280
|
"cheapest": "Best Return",
|
|
277
281
|
"fastest": "Fastest"
|
package/src/i18n/i18next.d.ts
CHANGED
|
@@ -2,13 +2,9 @@ import en from './en.json' with { type: 'json' }
|
|
|
2
2
|
|
|
3
3
|
const defaultResource = { translation: en }
|
|
4
4
|
|
|
5
|
-
declare
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
defaultNS: 'translation'
|
|
10
|
-
resources: typeof defaultResource
|
|
11
|
-
}
|
|
12
|
-
}
|
|
5
|
+
declare module 'i18next' {
|
|
6
|
+
interface CustomTypeOptions {
|
|
7
|
+
defaultNS: 'translation'
|
|
8
|
+
resources: typeof defaultResource
|
|
13
9
|
}
|
|
14
10
|
}
|
package/src/index.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export type * from '@lifi/sdk'
|
|
2
|
-
export { ChainType, ChainId } from '@lifi/sdk'
|
|
2
|
+
export { ChainType, ChainId, CoinKey } from '@lifi/sdk'
|
|
3
3
|
export { App as LiFiWidget } from './App.js'
|
|
4
4
|
export type { WidgetDrawer } from './AppDrawer.js'
|
|
5
5
|
export * from './components/ContractComponent/ItemPrice.js'
|
|
@@ -15,17 +15,28 @@ export const ActiveTransactionsEmpty: React.FC = () => {
|
|
|
15
15
|
paddingY: 12,
|
|
16
16
|
}}
|
|
17
17
|
>
|
|
18
|
-
<Typography
|
|
18
|
+
<Typography
|
|
19
|
+
sx={{
|
|
20
|
+
fontSize: 48,
|
|
21
|
+
}}
|
|
22
|
+
>
|
|
19
23
|
<SwapHoriz fontSize="inherit" />
|
|
20
24
|
</Typography>
|
|
21
|
-
<Typography
|
|
25
|
+
<Typography
|
|
26
|
+
sx={{
|
|
27
|
+
fontSize: 18,
|
|
28
|
+
fontWeight: 700,
|
|
29
|
+
}}
|
|
30
|
+
>
|
|
22
31
|
{t('info.title.emptyActiveTransactions')}
|
|
23
32
|
</Typography>
|
|
24
33
|
<Typography
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
34
|
+
sx={{
|
|
35
|
+
fontSize: 14,
|
|
36
|
+
color: 'text.secondary',
|
|
37
|
+
textAlign: 'center',
|
|
38
|
+
mt: 2,
|
|
39
|
+
}}
|
|
29
40
|
>
|
|
30
41
|
{t('info.message.emptyActiveTransactions')}
|
|
31
42
|
</Typography>
|
|
@@ -31,25 +31,32 @@ export const MainPage: React.FC = () => {
|
|
|
31
31
|
: subvariant === 'refuel'
|
|
32
32
|
? t('header.gas')
|
|
33
33
|
: t('header.exchange')
|
|
34
|
+
|
|
34
35
|
useHeader(title)
|
|
35
36
|
|
|
37
|
+
const marginSx = { marginBottom: 2 }
|
|
38
|
+
|
|
36
39
|
return (
|
|
37
40
|
<PageContainer>
|
|
38
|
-
<ActiveTransactions sx={
|
|
41
|
+
<ActiveTransactions sx={marginSx} />
|
|
39
42
|
{custom ? (
|
|
40
|
-
<ContractComponent sx={{
|
|
41
|
-
{contractComponent}
|
|
42
|
-
</ContractComponent>
|
|
43
|
+
<ContractComponent sx={marginSx}>{contractComponent}</ContractComponent>
|
|
43
44
|
) : null}
|
|
44
45
|
<SelectChainAndToken mb={2} />
|
|
45
|
-
{!custom ? (
|
|
46
|
-
<AmountInput formType="from" sx={
|
|
46
|
+
{!custom || subvariantOptions?.custom === 'deposit' ? (
|
|
47
|
+
<AmountInput formType="from" sx={marginSx} />
|
|
47
48
|
) : null}
|
|
48
|
-
{!wideVariant ? <Routes sx={
|
|
49
|
-
<SendToWalletButton sx={
|
|
49
|
+
{!wideVariant ? <Routes sx={marginSx} /> : null}
|
|
50
|
+
<SendToWalletButton sx={marginSx} />
|
|
50
51
|
<GasRefuelMessage mb={2} />
|
|
51
52
|
<MainMessages mb={2} />
|
|
52
|
-
<Box
|
|
53
|
+
<Box
|
|
54
|
+
sx={{
|
|
55
|
+
display: 'flex',
|
|
56
|
+
mb: showPoweredBy ? 1 : 3,
|
|
57
|
+
gap: 1.5,
|
|
58
|
+
}}
|
|
59
|
+
>
|
|
53
60
|
<ReviewButton />
|
|
54
61
|
<SendToWalletExpandButton />
|
|
55
62
|
</Box>
|
|
@@ -41,13 +41,27 @@ export const SelectTokenPage: FC<FormTypeProps> = ({ formType }) => {
|
|
|
41
41
|
|
|
42
42
|
return (
|
|
43
43
|
<FullPageContainer disableGutters>
|
|
44
|
-
<Box
|
|
44
|
+
<Box
|
|
45
|
+
ref={headerRef}
|
|
46
|
+
sx={{
|
|
47
|
+
pb: 2,
|
|
48
|
+
px: 3,
|
|
49
|
+
}}
|
|
50
|
+
>
|
|
45
51
|
{!hideChainSelect ? <ChainSelect formType={formType} /> : null}
|
|
46
|
-
<Box
|
|
52
|
+
<Box
|
|
53
|
+
sx={{
|
|
54
|
+
mt: !hideChainSelect ? 2 : 0,
|
|
55
|
+
}}
|
|
56
|
+
>
|
|
47
57
|
<SearchTokenInput />
|
|
48
58
|
</Box>
|
|
49
59
|
</Box>
|
|
50
|
-
<Box
|
|
60
|
+
<Box
|
|
61
|
+
sx={{
|
|
62
|
+
height: minListHeight,
|
|
63
|
+
}}
|
|
64
|
+
>
|
|
51
65
|
<TokenList
|
|
52
66
|
parentRef={listParentRef}
|
|
53
67
|
height={tokenListHeight}
|
|
@@ -148,7 +148,12 @@ export const BookmarkAddressSheet = forwardRef<
|
|
|
148
148
|
{validatedWallet ? (
|
|
149
149
|
<SheetAddressContainer>
|
|
150
150
|
{validatedWallet?.name ? (
|
|
151
|
-
<Typography
|
|
151
|
+
<Typography
|
|
152
|
+
sx={{
|
|
153
|
+
fontWeight: 600,
|
|
154
|
+
mb: 0.5,
|
|
155
|
+
}}
|
|
156
|
+
>
|
|
152
157
|
{validatedWallet?.name}
|
|
153
158
|
</Typography>
|
|
154
159
|
) : null}
|