@lifi/widget 3.12.6-beta.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.
Files changed (236) hide show
  1. package/CHANGELOG.md +15 -0
  2. package/dist/esm/AppProvider.js +9 -2
  3. package/dist/esm/AppProvider.js.map +1 -1
  4. package/dist/esm/components/ActiveTransactions/ActiveTransactionItem.js +15 -3
  5. package/dist/esm/components/ActiveTransactions/ActiveTransactionItem.js.map +1 -1
  6. package/dist/esm/components/ActiveTransactions/ActiveTransactions.js +4 -1
  7. package/dist/esm/components/ActiveTransactions/ActiveTransactions.js.map +1 -1
  8. package/dist/esm/components/ActiveTransactions/ActiveTransactions.style.d.ts +3 -5
  9. package/dist/esm/components/AlertMessage/AlertMessage.style.js +29 -12
  10. package/dist/esm/components/AlertMessage/AlertMessage.style.js.map +1 -1
  11. package/dist/esm/components/AmountInput/PriceFormHelperText.js +13 -2
  12. package/dist/esm/components/AmountInput/PriceFormHelperText.js.map +1 -1
  13. package/dist/esm/components/AppContainer.js +34 -21
  14. package/dist/esm/components/AppContainer.js.map +1 -1
  15. package/dist/esm/components/Avatar/Avatar.style.d.ts +3 -1
  16. package/dist/esm/components/Avatar/Avatar.style.js +8 -6
  17. package/dist/esm/components/Avatar/Avatar.style.js.map +1 -1
  18. package/dist/esm/components/Card/Card.js +60 -33
  19. package/dist/esm/components/Card/Card.js.map +1 -1
  20. package/dist/esm/components/Card/CardLabel.js +46 -29
  21. package/dist/esm/components/Card/CardLabel.js.map +1 -1
  22. package/dist/esm/components/Card/CardTitle.js +12 -2
  23. package/dist/esm/components/Card/CardTitle.js.map +1 -1
  24. package/dist/esm/components/Card/InputCard.d.ts +1 -1
  25. package/dist/esm/components/ChainSelect/ChainSelect.js +3 -1
  26. package/dist/esm/components/ChainSelect/ChainSelect.js.map +1 -1
  27. package/dist/esm/components/ContractComponent/NFT/NFTBase.js +16 -1
  28. package/dist/esm/components/ContractComponent/NFT/NFTBase.js.map +1 -1
  29. package/dist/esm/components/FeeBreakdownTooltip.js +7 -2
  30. package/dist/esm/components/FeeBreakdownTooltip.js.map +1 -1
  31. package/dist/esm/components/GasMessage/FundsSufficiencyMessage.js +4 -1
  32. package/dist/esm/components/GasMessage/FundsSufficiencyMessage.js.map +1 -1
  33. package/dist/esm/components/GasMessage/GasMessage.style.js +8 -6
  34. package/dist/esm/components/GasMessage/GasMessage.style.js.map +1 -1
  35. package/dist/esm/components/GasMessage/GasRefuelMessage.js +11 -1
  36. package/dist/esm/components/GasMessage/GasRefuelMessage.js.map +1 -1
  37. package/dist/esm/components/GasMessage/GasSufficiencyMessage.js +9 -1
  38. package/dist/esm/components/GasMessage/GasSufficiencyMessage.js.map +1 -1
  39. package/dist/esm/components/Header/NavigationHeader.js +11 -2
  40. package/dist/esm/components/Header/NavigationHeader.js.map +1 -1
  41. package/dist/esm/components/Header/WalletMenu.js +12 -3
  42. package/dist/esm/components/Header/WalletMenu.js.map +1 -1
  43. package/dist/esm/components/IconTypography.js +4 -3
  44. package/dist/esm/components/IconTypography.js.map +1 -1
  45. package/dist/esm/components/ListItem/ListItem.d.ts +2 -4
  46. package/dist/esm/components/ListItem/ListItemButton.d.ts +1 -1
  47. package/dist/esm/components/ListItemButton.d.ts +1 -1
  48. package/dist/esm/components/ListItemButton.js +14 -3
  49. package/dist/esm/components/ListItemButton.js.map +1 -1
  50. package/dist/esm/components/NotFound.js +11 -1
  51. package/dist/esm/components/NotFound.js.map +1 -1
  52. package/dist/esm/components/PageContainer.js +10 -4
  53. package/dist/esm/components/PageContainer.js.map +1 -1
  54. package/dist/esm/components/PoweredBy/PoweredBy.js +14 -2
  55. package/dist/esm/components/PoweredBy/PoweredBy.js.map +1 -1
  56. package/dist/esm/components/PoweredBy/PoweredBy.style.d.ts +1 -1
  57. package/dist/esm/components/ProgressToNextUpdate.js +8 -6
  58. package/dist/esm/components/ProgressToNextUpdate.js.map +1 -1
  59. package/dist/esm/components/RouteCard/RouteCard.js +7 -1
  60. package/dist/esm/components/RouteCard/RouteCard.js.map +1 -1
  61. package/dist/esm/components/RouteCard/RouteCardEssentials.js +28 -2
  62. package/dist/esm/components/RouteCard/RouteCardEssentials.js.map +1 -1
  63. package/dist/esm/components/RouteCard/RouteCardEssentialsExpanded.js +20 -1
  64. package/dist/esm/components/RouteCard/RouteCardEssentialsExpanded.js.map +1 -1
  65. package/dist/esm/components/RouteCard/RouteCardSkeleton.js +12 -2
  66. package/dist/esm/components/RouteCard/RouteCardSkeleton.js.map +1 -1
  67. package/dist/esm/components/RouteCard/RouteNotFoundCard.js +12 -1
  68. package/dist/esm/components/RouteCard/RouteNotFoundCard.js.map +1 -1
  69. package/dist/esm/components/Routes/Routes.js +5 -1
  70. package/dist/esm/components/Routes/Routes.js.map +1 -1
  71. package/dist/esm/components/Routes/RoutesExpanded.js +8 -1
  72. package/dist/esm/components/Routes/RoutesExpanded.js.map +1 -1
  73. package/dist/esm/components/Select.js +16 -5
  74. package/dist/esm/components/Select.js.map +1 -1
  75. package/dist/esm/components/SelectTokenButton/SelectTokenButton.style.js +34 -8
  76. package/dist/esm/components/SelectTokenButton/SelectTokenButton.style.js.map +1 -1
  77. package/dist/esm/components/SendToWallet/SendToWallet.style.js +28 -7
  78. package/dist/esm/components/SendToWallet/SendToWallet.style.js.map +1 -1
  79. package/dist/esm/components/SendToWallet/SendToWalletButton.js +5 -1
  80. package/dist/esm/components/SendToWallet/SendToWalletButton.js.map +1 -1
  81. package/dist/esm/components/SettingsListItemButton.d.ts +1 -1
  82. package/dist/esm/components/Skeleton/WidgetSkeleton.style.d.ts +1 -1
  83. package/dist/esm/components/Step/DestinationWalletAddress.js +10 -2
  84. package/dist/esm/components/Step/DestinationWalletAddress.js.map +1 -1
  85. package/dist/esm/components/Step/Step.js +3 -1
  86. package/dist/esm/components/Step/Step.js.map +1 -1
  87. package/dist/esm/components/Step/StepProcess.js +16 -3
  88. package/dist/esm/components/Step/StepProcess.js.map +1 -1
  89. package/dist/esm/components/Step/StepTimer.js +5 -1
  90. package/dist/esm/components/Step/StepTimer.js.map +1 -1
  91. package/dist/esm/components/StepActions/StepActions.js +22 -3
  92. package/dist/esm/components/StepActions/StepActions.js.map +1 -1
  93. package/dist/esm/components/StepActions/StepActions.style.js +19 -10
  94. package/dist/esm/components/StepActions/StepActions.style.js.map +1 -1
  95. package/dist/esm/components/StepActions/StepFees.js +9 -1
  96. package/dist/esm/components/StepActions/StepFees.js.map +1 -1
  97. package/dist/esm/components/Switch.js +12 -7
  98. package/dist/esm/components/Switch.js.map +1 -1
  99. package/dist/esm/components/Tabs/Tabs.style.d.ts +1 -1
  100. package/dist/esm/components/Tabs/Tabs.style.js +16 -12
  101. package/dist/esm/components/Tabs/Tabs.style.js.map +1 -1
  102. package/dist/esm/components/ToAddressRequiredMessage.js +4 -1
  103. package/dist/esm/components/ToAddressRequiredMessage.js.map +1 -1
  104. package/dist/esm/components/Token/Token.js +47 -6
  105. package/dist/esm/components/Token/Token.js.map +1 -1
  106. package/dist/esm/components/Token/Token.style.js +14 -7
  107. package/dist/esm/components/Token/Token.style.js.map +1 -1
  108. package/dist/esm/components/TokenList/TokenList.style.d.ts +3 -5
  109. package/dist/esm/components/TokenList/TokenListItem.js +21 -4
  110. package/dist/esm/components/TokenList/TokenListItem.js.map +1 -1
  111. package/dist/esm/components/TokenList/VirtualizedTokenList.js +8 -1
  112. package/dist/esm/components/TokenList/VirtualizedTokenList.js.map +1 -1
  113. package/dist/esm/components/TransactionDetails.js +52 -6
  114. package/dist/esm/components/TransactionDetails.js.map +1 -1
  115. package/dist/esm/config/version.d.ts +1 -1
  116. package/dist/esm/config/version.js +1 -1
  117. package/dist/esm/config/version.js.map +1 -1
  118. package/dist/esm/pages/ActiveTransactionsPage/ActiveTransactionsEmpty.js +11 -1
  119. package/dist/esm/pages/ActiveTransactionsPage/ActiveTransactionsEmpty.js.map +1 -1
  120. package/dist/esm/pages/MainPage/MainPage.js +5 -1
  121. package/dist/esm/pages/MainPage/MainPage.js.map +1 -1
  122. package/dist/esm/pages/SelectTokenPage/SelectTokenPage.js +8 -1
  123. package/dist/esm/pages/SelectTokenPage/SelectTokenPage.js.map +1 -1
  124. package/dist/esm/pages/SendToWallet/BookmarkAddressSheet.js +4 -1
  125. package/dist/esm/pages/SendToWallet/BookmarkAddressSheet.js.map +1 -1
  126. package/dist/esm/pages/SendToWallet/ConfirmAddressSheet.js +4 -1
  127. package/dist/esm/pages/SendToWallet/ConfirmAddressSheet.js.map +1 -1
  128. package/dist/esm/pages/SendToWallet/EmptyListIndicator.js +5 -1
  129. package/dist/esm/pages/SendToWallet/EmptyListIndicator.js.map +1 -1
  130. package/dist/esm/pages/SendToWallet/SendToWalletPage.js +7 -1
  131. package/dist/esm/pages/SendToWallet/SendToWalletPage.js.map +1 -1
  132. package/dist/esm/pages/SendToWallet/SendToWalletPage.style.d.ts +1 -1
  133. package/dist/esm/pages/SendToWallet/SendToWalletPage.style.js +6 -6
  134. package/dist/esm/pages/SendToWallet/SendToWalletPage.style.js.map +1 -1
  135. package/dist/esm/pages/SettingsPage/ResetSettingsButton.js +9 -2
  136. package/dist/esm/pages/SettingsPage/ResetSettingsButton.js.map +1 -1
  137. package/dist/esm/pages/SettingsPage/ResetSettingsButton.style.js.map +1 -1
  138. package/dist/esm/pages/SettingsPage/SlippageSettings/SlippageSettings.js +7 -2
  139. package/dist/esm/pages/SettingsPage/SlippageSettings/SlippageSettings.js.map +1 -1
  140. package/dist/esm/pages/SettingsPage/SlippageSettings/SlippageSettings.style.js +4 -3
  141. package/dist/esm/pages/SettingsPage/SlippageSettings/SlippageSettings.style.js.map +1 -1
  142. package/dist/esm/pages/TransactionDetailsPage/TransactionDetailsPage.js +10 -3
  143. package/dist/esm/pages/TransactionDetailsPage/TransactionDetailsPage.js.map +1 -1
  144. package/dist/esm/pages/TransactionDetailsPage/TransactionDetailsSkeleton.js +16 -3
  145. package/dist/esm/pages/TransactionDetailsPage/TransactionDetailsSkeleton.js.map +1 -1
  146. package/dist/esm/pages/TransactionDetailsPage/TransferIdCard.js +6 -1
  147. package/dist/esm/pages/TransactionDetailsPage/TransferIdCard.js.map +1 -1
  148. package/dist/esm/pages/TransactionHistoryPage/TransactionHistoryEmpty.js +11 -1
  149. package/dist/esm/pages/TransactionHistoryPage/TransactionHistoryEmpty.js.map +1 -1
  150. package/dist/esm/pages/TransactionHistoryPage/TransactionHistoryItem.js +14 -2
  151. package/dist/esm/pages/TransactionHistoryPage/TransactionHistoryItem.js.map +1 -1
  152. package/dist/esm/pages/TransactionHistoryPage/TransactionHistorySkeleton.js +10 -2
  153. package/dist/esm/pages/TransactionHistoryPage/TransactionHistorySkeleton.js.map +1 -1
  154. package/dist/esm/pages/TransactionPage/ExchangeRateBottomSheet.js +35 -3
  155. package/dist/esm/pages/TransactionPage/ExchangeRateBottomSheet.js.map +1 -1
  156. package/dist/esm/pages/TransactionPage/StatusBottomSheet.js +12 -2
  157. package/dist/esm/pages/TransactionPage/StatusBottomSheet.js.map +1 -1
  158. package/dist/esm/pages/TransactionPage/TokenValueBottomSheet.js +45 -1
  159. package/dist/esm/pages/TransactionPage/TokenValueBottomSheet.js.map +1 -1
  160. package/dist/esm/pages/TransactionPage/TransactionPage.js +4 -1
  161. package/dist/esm/pages/TransactionPage/TransactionPage.js.map +1 -1
  162. package/package.json +18 -18
  163. package/src/AppProvider.tsx +16 -2
  164. package/src/components/ActiveTransactions/ActiveTransactionItem.tsx +16 -9
  165. package/src/components/ActiveTransactions/ActiveTransactions.tsx +7 -1
  166. package/src/components/AlertMessage/AlertMessage.style.tsx +30 -14
  167. package/src/components/AmountInput/PriceFormHelperText.tsx +12 -10
  168. package/src/components/AppContainer.tsx +34 -23
  169. package/src/components/Avatar/Avatar.style.tsx +8 -8
  170. package/src/components/Card/Card.tsx +60 -37
  171. package/src/components/Card/CardLabel.tsx +69 -43
  172. package/src/components/Card/CardTitle.tsx +12 -2
  173. package/src/components/ChainSelect/ChainSelect.tsx +7 -1
  174. package/src/components/ContractComponent/NFT/NFTBase.tsx +33 -6
  175. package/src/components/FeeBreakdownTooltip.tsx +9 -3
  176. package/src/components/GasMessage/FundsSufficiencyMessage.tsx +7 -1
  177. package/src/components/GasMessage/GasMessage.style.ts +8 -8
  178. package/src/components/GasMessage/GasRefuelMessage.tsx +19 -6
  179. package/src/components/GasMessage/GasSufficiencyMessage.tsx +21 -3
  180. package/src/components/Header/NavigationHeader.tsx +23 -5
  181. package/src/components/Header/WalletMenu.tsx +18 -3
  182. package/src/components/IconTypography.ts +4 -4
  183. package/src/components/ListItemButton.tsx +21 -12
  184. package/src/components/NotFound.tsx +17 -6
  185. package/src/components/PageContainer.ts +19 -15
  186. package/src/components/PoweredBy/PoweredBy.tsx +16 -8
  187. package/src/components/ProgressToNextUpdate.tsx +8 -8
  188. package/src/components/RouteCard/RouteCard.tsx +12 -2
  189. package/src/components/RouteCard/RouteCardEssentials.tsx +38 -16
  190. package/src/components/RouteCard/RouteCardEssentialsExpanded.tsx +30 -11
  191. package/src/components/RouteCard/RouteCardSkeleton.tsx +19 -3
  192. package/src/components/RouteCard/RouteNotFoundCard.tsx +18 -7
  193. package/src/components/Routes/Routes.tsx +10 -2
  194. package/src/components/Routes/RoutesExpanded.tsx +16 -2
  195. package/src/components/Select.tsx +16 -6
  196. package/src/components/SelectTokenButton/SelectTokenButton.style.tsx +34 -8
  197. package/src/components/SendToWallet/SendToWallet.style.tsx +28 -7
  198. package/src/components/SendToWallet/SendToWalletButton.tsx +7 -1
  199. package/src/components/Step/DestinationWalletAddress.tsx +14 -2
  200. package/src/components/Step/Step.tsx +5 -1
  201. package/src/components/Step/StepProcess.tsx +18 -9
  202. package/src/components/Step/StepTimer.tsx +9 -5
  203. package/src/components/StepActions/StepActions.style.tsx +19 -13
  204. package/src/components/StepActions/StepActions.tsx +32 -10
  205. package/src/components/StepActions/StepFees.tsx +9 -4
  206. package/src/components/Switch.tsx +12 -9
  207. package/src/components/Tabs/Tabs.style.tsx +16 -16
  208. package/src/components/ToAddressRequiredMessage.tsx +7 -1
  209. package/src/components/Token/Token.style.tsx +14 -8
  210. package/src/components/Token/Token.tsx +75 -12
  211. package/src/components/TokenList/TokenListItem.tsx +37 -8
  212. package/src/components/TokenList/VirtualizedTokenList.tsx +8 -6
  213. package/src/components/TransactionDetails.tsx +75 -17
  214. package/src/config/version.ts +1 -1
  215. package/src/pages/ActiveTransactionsPage/ActiveTransactionsEmpty.tsx +17 -6
  216. package/src/pages/MainPage/MainPage.tsx +7 -1
  217. package/src/pages/SelectTokenPage/SelectTokenPage.tsx +17 -3
  218. package/src/pages/SendToWallet/BookmarkAddressSheet.tsx +6 -1
  219. package/src/pages/SendToWallet/ConfirmAddressSheet.tsx +6 -1
  220. package/src/pages/SendToWallet/EmptyListIndicator.tsx +7 -1
  221. package/src/pages/SendToWallet/SendToWalletPage.style.tsx +6 -9
  222. package/src/pages/SendToWallet/SendToWalletPage.tsx +17 -3
  223. package/src/pages/SettingsPage/ResetSettingsButton.style.tsx +0 -1
  224. package/src/pages/SettingsPage/ResetSettingsButton.tsx +18 -3
  225. package/src/pages/SettingsPage/SlippageSettings/SlippageSettings.style.tsx +4 -5
  226. package/src/pages/SettingsPage/SlippageSettings/SlippageSettings.tsx +11 -2
  227. package/src/pages/TransactionDetailsPage/TransactionDetailsPage.tsx +16 -4
  228. package/src/pages/TransactionDetailsPage/TransactionDetailsSkeleton.tsx +29 -9
  229. package/src/pages/TransactionDetailsPage/TransferIdCard.tsx +6 -4
  230. package/src/pages/TransactionHistoryPage/TransactionHistoryEmpty.tsx +17 -6
  231. package/src/pages/TransactionHistoryPage/TransactionHistoryItem.tsx +24 -6
  232. package/src/pages/TransactionHistoryPage/TransactionHistorySkeleton.tsx +14 -4
  233. package/src/pages/TransactionPage/ExchangeRateBottomSheet.tsx +70 -11
  234. package/src/pages/TransactionPage/StatusBottomSheet.tsx +27 -4
  235. package/src/pages/TransactionPage/TokenValueBottomSheet.tsx +92 -15
  236. package/src/pages/TransactionPage/TransactionPage.tsx +6 -1
@@ -3,26 +3,26 @@ import { CardHeader } from '../Card/CardHeader.js'
3
3
 
4
4
  export const SendToWalletCardHeader = styled(CardHeader, {
5
5
  shouldForwardProp: (prop) => !['selected'].includes(prop as string),
6
- })<{ selected?: boolean }>(({ theme, selected }) => ({
6
+ })<{ selected?: boolean }>(({ theme }) => ({
7
7
  width: '100%',
8
8
  [`.${cardHeaderClasses.title}`]: {
9
- color: selected ? theme.palette.text.primary : theme.palette.text.secondary,
9
+ color: theme.palette.text.secondary,
10
10
  textOverflow: 'ellipsis',
11
11
  whiteSpace: 'nowrap',
12
12
  overflow: 'hidden',
13
- fontWeight: selected ? 600 : 500,
14
- width: selected ? 224 : 254,
13
+ fontWeight: 500,
14
+ width: 254,
15
15
  [theme.breakpoints.down(theme.breakpoints.values.sm)]: {
16
- width: selected ? 192 : 224,
16
+ width: 224,
17
17
  },
18
18
  },
19
19
  [`.${cardHeaderClasses.subheader}`]: {
20
20
  textOverflow: 'ellipsis',
21
21
  whiteSpace: 'nowrap',
22
22
  overflow: 'hidden',
23
- width: selected ? 224 : 254,
23
+ width: 254,
24
24
  [theme.breakpoints.down(theme.breakpoints.values.sm)]: {
25
- width: selected ? 192 : 224,
25
+ width: 224,
26
26
  },
27
27
  },
28
28
  [`.${cardHeaderClasses.action}`]: {
@@ -31,4 +31,25 @@ export const SendToWalletCardHeader = styled(CardHeader, {
31
31
  [`.${cardHeaderClasses.action} > button`]: {
32
32
  fontSize: 16,
33
33
  },
34
+ variants: [
35
+ {
36
+ props: ({ selected }) => selected,
37
+ style: {
38
+ [`.${cardHeaderClasses.title}`]: {
39
+ color: theme.palette.text.primary,
40
+ fontWeight: 600,
41
+ width: 224,
42
+ [theme.breakpoints.down(theme.breakpoints.values.sm)]: {
43
+ width: 192,
44
+ },
45
+ },
46
+ [`.${cardHeaderClasses.subheader}`]: {
47
+ width: 224,
48
+ [theme.breakpoints.down(theme.breakpoints.values.sm)]: {
49
+ width: 192,
50
+ },
51
+ },
52
+ },
53
+ },
54
+ ],
34
55
  }))
@@ -140,7 +140,13 @@ export const SendToWalletButton: React.FC<CardProps> = (props) => {
140
140
  sx={{ width: '100%', ...props.sx }}
141
141
  >
142
142
  <CardTitle required={requiredToAddress}>{title}</CardTitle>
143
- <Box display="flex" justifyContent="center" alignItems="center">
143
+ <Box
144
+ sx={{
145
+ display: 'flex',
146
+ justifyContent: 'center',
147
+ alignItems: 'center',
148
+ }}
149
+ >
144
150
  <SendToWalletCardHeader
145
151
  avatar={
146
152
  <AccountAvatar
@@ -13,7 +13,12 @@ export const DestinationWalletAddress: React.FC<{
13
13
  const { t } = useTranslation()
14
14
  const isDone = step.execution?.status === 'DONE'
15
15
  return (
16
- <Box px={2} py={1}>
16
+ <Box
17
+ sx={{
18
+ px: 2,
19
+ py: 1,
20
+ }}
21
+ >
17
22
  <Box
18
23
  sx={{
19
24
  display: 'flex',
@@ -29,7 +34,14 @@ export const DestinationWalletAddress: React.FC<{
29
34
  }}
30
35
  />
31
36
  </CircularIcon>
32
- <Typography mx={2} flex={1} fontSize={14} fontWeight={400}>
37
+ <Typography
38
+ sx={{
39
+ mx: 2,
40
+ flex: 1,
41
+ fontSize: 14,
42
+ fontWeight: 400,
43
+ }}
44
+ >
33
45
  {isDone
34
46
  ? t('main.sentToAddress', {
35
47
  address: toAddress,
@@ -82,7 +82,11 @@ export const Step: React.FC<{
82
82
  <StepTimer step={step} />
83
83
  </CardTitle>
84
84
  </Box>
85
- <Box py={1}>
85
+ <Box
86
+ sx={{
87
+ py: 1,
88
+ }}
89
+ >
86
90
  {fromToken ? <Token token={fromToken} px={2} py={1} /> : null}
87
91
  <StepActions step={step} px={2} py={1} dense />
88
92
  {step.execution?.process.map((process, index) => (
@@ -14,7 +14,12 @@ export const StepProcess: React.FC<{
14
14
  const { getTransactionLink } = useExplorer()
15
15
 
16
16
  return (
17
- <Box px={2} py={1}>
17
+ <Box
18
+ sx={{
19
+ px: 2,
20
+ py: 1,
21
+ }}
22
+ >
18
23
  <Box
19
24
  sx={{
20
25
  display: 'flex',
@@ -23,10 +28,12 @@ export const StepProcess: React.FC<{
23
28
  >
24
29
  <CircularProgress process={process} />
25
30
  <Typography
26
- mx={2}
27
- flex={1}
28
- fontSize={14}
29
- fontWeight={process.error ? 600 : 400}
31
+ sx={{
32
+ mx: 2,
33
+ flex: 1,
34
+ fontSize: 14,
35
+ fontWeight: process.error ? 600 : 400,
36
+ }}
30
37
  >
31
38
  {title}
32
39
  </Typography>
@@ -54,10 +61,12 @@ export const StepProcess: React.FC<{
54
61
  </Box>
55
62
  {message ? (
56
63
  <Typography
57
- ml={7}
58
- fontSize={14}
59
- fontWeight={500}
60
- color="text.secondary"
64
+ sx={{
65
+ ml: 7,
66
+ fontSize: 14,
67
+ fontWeight: 500,
68
+ color: 'text.secondary',
69
+ }}
61
70
  >
62
71
  {message}
63
72
  </Typography>
@@ -111,11 +111,15 @@ const StepTimerContent: FC<PropsWithChildren> = ({ children }) => {
111
111
  const { t } = useTranslation()
112
112
  return (
113
113
  <Tooltip title={t('tooltip.estimatedTime')} sx={{ cursor: 'help' }}>
114
- <Box component="span" display="flex" alignItems="center" height={14}>
115
- <IconTypography
116
- component="span"
117
- sx={{ marginRight: 0.5, fontSize: 16 }}
118
- >
114
+ <Box
115
+ component="span"
116
+ sx={{
117
+ display: 'flex',
118
+ alignItems: 'center',
119
+ height: 14,
120
+ }}
121
+ >
122
+ <IconTypography as="span" sx={{ marginRight: 0.5, fontSize: 16 }}>
119
123
  <AccessTimeFilled fontSize="inherit" />
120
124
  </IconTypography>
121
125
  <Box
@@ -18,10 +18,10 @@ export const StepConnector = styled(MuiStepConnector, {
18
18
  [`.${stepConnectorClasses.line}`]: {
19
19
  minHeight: 8,
20
20
  borderLeftWidth: 2,
21
- borderColor:
22
- theme.palette.mode === 'light'
23
- ? alpha(theme.palette.common.black, 0.12)
24
- : alpha(theme.palette.common.white, 0.16),
21
+ borderColor: alpha(theme.palette.common.white, 0.16),
22
+ ...theme.applyStyles('light', {
23
+ borderColor: alpha(theme.palette.common.black, 0.12),
24
+ }),
25
25
  },
26
26
  }))
27
27
 
@@ -55,16 +55,22 @@ export const StepLabelTypography = styled(Typography)(({ theme }) => ({
55
55
 
56
56
  export const StepContent = styled(Box, {
57
57
  shouldForwardProp: (prop) => !['last'].includes(prop as string),
58
- })<{ last: boolean }>(({ theme, last }) => ({
59
- borderLeft: last
60
- ? 'none'
61
- : `2px solid ${
62
- theme.palette.mode === 'light'
63
- ? alpha(theme.palette.common.black, 0.12)
64
- : alpha(theme.palette.common.white, 0.16)
65
- }`,
58
+ })<{ last: boolean }>(({ theme }) => ({
59
+ borderLeft: `2px solid ${alpha(theme.palette.common.white, 0.16)}`,
66
60
  margin: theme.spacing(0, 0, 0, 2.375),
67
- paddingLeft: last ? theme.spacing(4.625) : theme.spacing(4.375),
61
+ paddingLeft: theme.spacing(4.375),
62
+ variants: [
63
+ {
64
+ props: ({ last }) => last,
65
+ style: {
66
+ borderLeft: 'none',
67
+ paddingLeft: theme.spacing(4.625),
68
+ },
69
+ },
70
+ ],
71
+ ...theme.applyStyles('light', {
72
+ borderLeft: `2px solid ${alpha(theme.palette.common.black, 0.12)}`,
73
+ }),
68
74
  }))
69
75
 
70
76
  export const StepAvatar = styled(AvatarMasked)(({ theme }) => ({
@@ -58,7 +58,12 @@ export const StepActions: React.FC<StepActionsProps> = ({
58
58
 
59
59
  return (
60
60
  <Box {...other}>
61
- <Box display="flex" alignItems="center">
61
+ <Box
62
+ sx={{
63
+ display: 'flex',
64
+ alignItems: 'center',
65
+ }}
66
+ >
62
67
  <Badge
63
68
  overlap="circular"
64
69
  anchorOrigin={{ vertical: 'bottom', horizontal: 'right' }}
@@ -72,8 +77,19 @@ export const StepActions: React.FC<StepActionsProps> = ({
72
77
  {toolDetails.name[0]}
73
78
  </StepAvatar>
74
79
  </Badge>
75
- <Box flex={1}>
76
- <Typography fontSize={18} fontWeight={600} lineHeight={1.3334} ml={2}>
80
+ <Box
81
+ sx={{
82
+ flex: 1,
83
+ }}
84
+ >
85
+ <Typography
86
+ sx={{
87
+ fontSize: 18,
88
+ fontWeight: 600,
89
+ lineHeight: 1.3334,
90
+ ml: 2,
91
+ }}
92
+ >
77
93
  {toolDetails.name?.includes('LI.FI')
78
94
  ? toolDetails.name
79
95
  : t('main.stepDetails', {
@@ -146,7 +162,11 @@ export const IncludedSteps: React.FC<IncludedStepsProps> = ({ step }) => {
146
162
  }
147
163
 
148
164
  return (
149
- <Box mt={1}>
165
+ <Box
166
+ sx={{
167
+ mt: 1,
168
+ }}
169
+ >
150
170
  <Stepper
151
171
  orientation="vertical"
152
172
  connector={<StepConnector />}
@@ -212,12 +232,14 @@ export const StepDetailsContent: React.FC<{
212
232
 
213
233
  return (
214
234
  <Typography
215
- fontSize={12}
216
- lineHeight={1}
217
- fontWeight="500"
218
- color="text.secondary"
219
- alignItems="center"
220
- display="flex"
235
+ sx={{
236
+ fontSize: 12,
237
+ lineHeight: 1,
238
+ fontWeight: '500',
239
+ color: 'text.secondary',
240
+ alignItems: 'center',
241
+ display: 'flex',
242
+ }}
221
243
  >
222
244
  {!showToAmount ? (
223
245
  <>
@@ -31,11 +31,16 @@ export const StepFees: React.FC<
31
31
 
32
32
  return (
33
33
  <Typography
34
- fontSize={12}
35
- fontWeight="500"
36
- color="text.secondary"
37
- lineHeight={1.3334}
38
34
  {...other}
35
+ sx={[
36
+ {
37
+ fontSize: 12,
38
+ fontWeight: '500',
39
+ color: 'text.secondary',
40
+ lineHeight: 1.3334,
41
+ },
42
+ ...(Array.isArray(other.sx) ? other.sx : [other.sx]),
43
+ ]}
39
44
  >
40
45
  {t('format.currency', { value: fees })}{' '}
41
46
  {isDone ? t('main.fees.paid') : t('main.fees.estimated')}
@@ -31,13 +31,16 @@ export const Switch = styled(MuiSwitch)(({ theme }) => ({
31
31
  borderColor: theme.palette.common.white,
32
32
  },
33
33
  [`&.${switchClasses.disabled} .${switchClasses.thumb}`]: {
34
- color:
35
- theme.palette.mode === 'light'
36
- ? alpha(theme.palette.common.black, 0.12)
37
- : alpha(theme.palette.common.white, 0.12),
34
+ color: alpha(theme.palette.common.white, 0.12),
35
+ ...theme.applyStyles('light', {
36
+ color: alpha(theme.palette.common.black, 0.12),
37
+ }),
38
38
  },
39
39
  [`&.${switchClasses.disabled} + .${switchClasses.track}`]: {
40
- opacity: theme.palette.mode === 'light' ? 0.7 : 0.3,
40
+ opacity: 0.3,
41
+ ...theme.applyStyles('light', {
42
+ opacity: 0.7,
43
+ }),
41
44
  },
42
45
  },
43
46
  [`.${switchClasses.thumb}`]: {
@@ -47,13 +50,13 @@ export const Switch = styled(MuiSwitch)(({ theme }) => ({
47
50
  },
48
51
  [`.${switchClasses.track}`]: {
49
52
  borderRadius: 24 / 2,
50
- backgroundColor:
51
- theme.palette.mode === 'light'
52
- ? alpha(theme.palette.common.black, 0.16)
53
- : alpha(theme.palette.common.white, 0.16),
53
+ backgroundColor: alpha(theme.palette.common.white, 0.16),
54
54
  opacity: 1,
55
55
  transition: theme.transitions.create(['background-color'], {
56
56
  duration: theme.transitions.duration.standard,
57
57
  }),
58
+ ...theme.applyStyles('light', {
59
+ backgroundColor: alpha(theme.palette.common.black, 0.16),
60
+ }),
58
61
  },
59
62
  }))
@@ -22,16 +22,16 @@ export const Tabs = styled(MuiTabs)(({ theme }) => ({
22
22
  }))
23
23
 
24
24
  export const CardTabs = styled(Tabs)(({ theme }) => ({
25
- backgroundColor:
26
- theme.palette.mode === 'light'
27
- ? alpha(theme.palette.common.black, 0.04)
28
- : alpha(theme.palette.common.white, 0.08),
25
+ backgroundColor: alpha(theme.palette.common.white, 0.08),
29
26
  [`.${tabsClasses.indicator}`]: {
30
- backgroundColor:
31
- theme.palette.mode === 'light'
32
- ? theme.palette.background.paper
33
- : alpha(theme.palette.common.black, 0.56),
27
+ backgroundColor: alpha(theme.palette.common.black, 0.56),
28
+ ...theme.applyStyles('light', {
29
+ backgroundColor: theme.palette.background.paper,
30
+ }),
34
31
  },
32
+ ...theme.applyStyles('light', {
33
+ backgroundColor: alpha(theme.palette.common.black, 0.04),
34
+ }),
35
35
  }))
36
36
 
37
37
  export const Tab = styled(MuiTab)<TabProps>(({ theme }) => ({
@@ -40,14 +40,14 @@ export const Tab = styled(MuiTab)<TabProps>(({ theme }) => ({
40
40
  textTransform: 'none',
41
41
  fontSize: '1rem',
42
42
  fontWeight: 700,
43
- color:
44
- theme.palette.mode === 'light'
45
- ? theme.palette.common.black
46
- : theme.palette.common.white,
43
+ color: theme.palette.common.white,
47
44
  [`&.${tabClasses.selected}`]: {
48
- color:
49
- theme.palette.mode === 'light'
50
- ? theme.palette.common.black
51
- : theme.palette.common.white,
45
+ color: theme.palette.common.white,
46
+ ...theme.applyStyles('light', {
47
+ color: theme.palette.common.black,
48
+ }),
52
49
  },
50
+ ...theme.applyStyles('light', {
51
+ color: theme.palette.common.black,
52
+ }),
53
53
  }))
@@ -25,7 +25,13 @@ export const ToAddressRequiredMessage: React.FC<
25
25
  <Box {...props}>
26
26
  <AlertMessage
27
27
  title={
28
- <Typography variant="body2" px={1} color="text.primary">
28
+ <Typography
29
+ variant="body2"
30
+ sx={{
31
+ px: 1,
32
+ color: 'text.primary',
33
+ }}
34
+ >
29
35
  {t('info.message.toAddressIsRequired')}
30
36
  </Typography>
31
37
  }
@@ -9,22 +9,28 @@ export const TextSecondaryContainer = styled(Box)(() => ({
9
9
 
10
10
  export const TextSecondary = styled(Typography, {
11
11
  shouldForwardProp: (prop: string) => !['dot'].includes(prop),
12
- })<{ dot?: boolean }>(({ theme, dot }) => ({
12
+ })<{ dot?: boolean }>(({ theme }) => ({
13
13
  fontSize: 12,
14
14
  lineHeight: 1,
15
15
  fontWeight: 500,
16
- color: dot
17
- ? alpha(theme.palette.text.secondary, 0.56)
18
- : theme.palette.text.secondary,
16
+ color: theme.palette.text.secondary,
19
17
  whiteSpace: 'nowrap',
18
+ variants: [
19
+ {
20
+ props: ({ dot }) => dot,
21
+ style: {
22
+ color: alpha(theme.palette.text.secondary, 0.56),
23
+ },
24
+ },
25
+ ],
20
26
  }))
21
27
 
22
28
  export const TokenDivider = styled(Box)(({ theme }) => ({
23
29
  height: 16,
24
30
  borderLeftWidth: 2,
25
31
  borderLeftStyle: 'solid',
26
- borderColor:
27
- theme.palette.mode === 'light'
28
- ? theme.palette.grey[300]
29
- : theme.palette.grey[800],
32
+ borderColor: theme.palette.grey[800],
33
+ ...theme.applyStyles('light', {
34
+ borderColor: theme.palette.grey[300],
35
+ }),
30
36
  }))
@@ -98,15 +98,36 @@ export const TokenBase: FC<TokenProps & BoxProps> = ({
98
98
  ) : null
99
99
 
100
100
  return (
101
- <Box flex={1} display="flex" alignItems="center" {...other}>
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 flex={1}>
109
- <Box mb={0.5} height={24} display="flex" alignItems="center">
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 component="span">
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 flex={1} position="relative" overflow="hidden" height={16}>
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 display="flex" alignItems="center" height={16}>
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 display="flex" alignItems="center" height={16}>
200
- <Box mr={0.75} height={16}>
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 flex={1} {...other}>
222
- <Box display="flex" flex={1} alignItems="center">
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 flex={1}>
283
+ <Box
284
+ sx={{
285
+ flex: 1,
286
+ }}
287
+ >
225
288
  <Skeleton width={112} height={24} variant="text" />
226
- <TextSecondaryContainer component="span">
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 position="relative" height={20} ref={container}>
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 pt={0.25}>{token.name}</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 display="flex">
138
- <Box display="flex" alignItems="center" pt={0.125}>
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 fontWeight={600} noWrap>
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,