@lifi/widget 1.13.4 → 1.13.7

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 (208) hide show
  1. package/App.d.ts +1 -1
  2. package/AppDrawer.d.ts +3 -3
  3. package/AppProvider.d.ts +2 -2
  4. package/AppProvider.js +1 -3
  5. package/cjs/App.d.ts +1 -1
  6. package/cjs/AppDrawer.d.ts +3 -3
  7. package/cjs/AppProvider.d.ts +2 -2
  8. package/cjs/AppProvider.js +0 -2
  9. package/cjs/components/AppContainer.d.ts +1 -1
  10. package/cjs/components/BottomSheet/BottomSheet.d.ts +1 -1
  11. package/cjs/components/BottomSheet/types.d.ts +2 -2
  12. package/cjs/components/Card/Card.d.ts +1 -1
  13. package/cjs/components/Dialog.d.ts +2 -2
  14. package/cjs/components/GasSufficiencyMessage/GasSufficiencyMessage.d.ts +2 -2
  15. package/cjs/components/Header/Header.d.ts +1 -1
  16. package/cjs/components/Header/useHeaderActionStore.d.ts +1 -1
  17. package/cjs/components/LiFiLogo.d.ts +1 -1
  18. package/cjs/components/ProgressToNextUpdate/ProgressToNextUpdate.d.ts +1 -1
  19. package/cjs/components/SelectChainAndToken.d.ts +1 -1
  20. package/cjs/components/SelectTokenButton/SelectTokenButton.d.ts +1 -1
  21. package/cjs/components/Step/CircularProgress.d.ts +1 -1
  22. package/cjs/components/Step/CircularProgress.style.d.ts +2 -2
  23. package/cjs/components/Step/Step.d.ts +1 -1
  24. package/cjs/components/Step/StepProcess.d.ts +1 -1
  25. package/cjs/components/Step/StepTimer.d.ts +1 -1
  26. package/cjs/components/Step/utils.d.ts +2 -2
  27. package/cjs/components/StepActions/StepActions.d.ts +2 -2
  28. package/cjs/components/StepActions/types.d.ts +2 -2
  29. package/cjs/components/SwapButton/SwapButton.d.ts +1 -1
  30. package/cjs/components/SwapInProgress/SwapInProgress.d.ts +1 -1
  31. package/cjs/components/SwapInput/FormPriceHelperText.d.ts +1 -1
  32. package/cjs/components/SwapInput/SwapInput.d.ts +1 -1
  33. package/cjs/components/SwapInput/SwapInputAdornment.d.ts +1 -1
  34. package/cjs/components/SwapRouteCard/SwapRouteCard.d.ts +2 -2
  35. package/cjs/components/SwapRouteCard/SwapRouteCardSkeleton.d.ts +2 -2
  36. package/cjs/components/SwapRouteCard/SwapRouteNotFoundCard.d.ts +2 -2
  37. package/cjs/components/SwapRouteCard/types.d.ts +1 -1
  38. package/cjs/components/TextFitter/TextFitter.d.ts +2 -2
  39. package/cjs/components/TextFitter/types.d.ts +1 -1
  40. package/cjs/components/Token/Token.d.ts +2 -2
  41. package/cjs/components/TokenAvatar/TokenAvatar.d.ts +2 -2
  42. package/cjs/components/TokenList/TokenList.d.ts +2 -2
  43. package/cjs/components/TokenList/TokenListItem.d.ts +1 -1
  44. package/cjs/components/TokenList/VirtualizedTokenList.d.ts +2 -2
  45. package/cjs/components/TokenList/types.d.ts +4 -4
  46. package/cjs/config/lifi.d.ts +2 -1
  47. package/cjs/config/theme.d.ts +2 -2
  48. package/cjs/config/theme.js +4 -4
  49. package/cjs/config/version.d.ts +1 -1
  50. package/cjs/config/version.js +1 -1
  51. package/cjs/fonts/Inter-Black.woff +0 -0
  52. package/cjs/fonts/Inter-Black.woff2 +0 -0
  53. package/cjs/fonts/Inter-BlackItalic.woff +0 -0
  54. package/cjs/fonts/Inter-BlackItalic.woff2 +0 -0
  55. package/cjs/fonts/Inter-Bold.woff +0 -0
  56. package/cjs/fonts/Inter-Bold.woff2 +0 -0
  57. package/cjs/fonts/Inter-BoldItalic.woff +0 -0
  58. package/cjs/fonts/Inter-BoldItalic.woff2 +0 -0
  59. package/cjs/fonts/Inter-ExtraBold.woff +0 -0
  60. package/cjs/fonts/Inter-ExtraBold.woff2 +0 -0
  61. package/cjs/fonts/Inter-ExtraBoldItalic.woff +0 -0
  62. package/cjs/fonts/Inter-ExtraBoldItalic.woff2 +0 -0
  63. package/cjs/fonts/Inter-ExtraLight.woff +0 -0
  64. package/cjs/fonts/Inter-ExtraLight.woff2 +0 -0
  65. package/cjs/fonts/Inter-ExtraLightItalic.woff +0 -0
  66. package/cjs/fonts/Inter-ExtraLightItalic.woff2 +0 -0
  67. package/cjs/fonts/Inter-Italic.woff +0 -0
  68. package/cjs/fonts/Inter-Italic.woff2 +0 -0
  69. package/cjs/fonts/Inter-Light.woff +0 -0
  70. package/cjs/fonts/Inter-Light.woff2 +0 -0
  71. package/cjs/fonts/Inter-LightItalic.woff +0 -0
  72. package/cjs/fonts/Inter-LightItalic.woff2 +0 -0
  73. package/cjs/fonts/Inter-Medium.woff +0 -0
  74. package/cjs/fonts/Inter-Medium.woff2 +0 -0
  75. package/cjs/fonts/Inter-MediumItalic.woff +0 -0
  76. package/cjs/fonts/Inter-MediumItalic.woff2 +0 -0
  77. package/cjs/fonts/Inter-Regular.woff +0 -0
  78. package/cjs/fonts/Inter-Regular.woff2 +0 -0
  79. package/cjs/fonts/Inter-SemiBold.woff +0 -0
  80. package/cjs/fonts/Inter-SemiBold.woff2 +0 -0
  81. package/cjs/fonts/Inter-SemiBoldItalic.woff +0 -0
  82. package/cjs/fonts/Inter-SemiBoldItalic.woff2 +0 -0
  83. package/cjs/fonts/Inter-Thin.woff +0 -0
  84. package/cjs/fonts/Inter-Thin.woff2 +0 -0
  85. package/cjs/fonts/Inter-ThinItalic.woff +0 -0
  86. package/cjs/fonts/Inter-ThinItalic.woff2 +0 -0
  87. package/cjs/fonts/Inter-italic.var.woff2 +0 -0
  88. package/cjs/fonts/Inter-roman.var.woff2 +0 -0
  89. package/cjs/fonts/Inter.var.woff2 +0 -0
  90. package/cjs/fonts/inter.css +200 -0
  91. package/cjs/hooks/useGasSufficiency.d.ts +1 -1
  92. package/cjs/hooks/useRouteExecution.d.ts +1 -1
  93. package/cjs/hooks/useTokenBalances.d.ts +1 -1
  94. package/cjs/hooks/useTokenSearch.d.ts +1 -1
  95. package/cjs/hooks/useTokens.d.ts +1 -1
  96. package/cjs/hooks/useTools.d.ts +1 -1
  97. package/cjs/i18n/en/translation.json +167 -167
  98. package/cjs/icons/LiFiFullLogo.d.ts +1 -1
  99. package/cjs/icons/LiFiLogo.d.ts +1 -1
  100. package/cjs/icons/LiFiToolLogo.d.ts +1 -1
  101. package/cjs/pages/MainPage/SwapRoutes.d.ts +1 -1
  102. package/cjs/pages/SelectTokenPage/ChainSelect.d.ts +1 -1
  103. package/cjs/pages/SelectTokenPage/SelectTokenPage.d.ts +2 -2
  104. package/cjs/pages/SwapHistoryPage/SwapHistoryItem.d.ts +1 -1
  105. package/cjs/pages/SwapPage/StatusBottomSheet.d.ts +1 -1
  106. package/cjs/pages/SwapPage/StatusBottomSheet.style.d.ts +2 -2
  107. package/cjs/pages/SwapPage/utils.d.ts +2 -2
  108. package/cjs/pages/SwapRoutesPage/SwapRoutesPage.d.ts +1 -1
  109. package/cjs/providers/WalletProvider/WalletProvider.d.ts +3 -3
  110. package/cjs/providers/WalletProvider/types.d.ts +3 -3
  111. package/cjs/providers/WidgetProvider/types.d.ts +1 -1
  112. package/cjs/stores/route/types.d.ts +1 -1
  113. package/cjs/stores/route/useExecutingRoutes.d.ts +1 -1
  114. package/cjs/stores/route/useSwapHistory.d.ts +1 -1
  115. package/cjs/stores/settings/types.d.ts +2 -2
  116. package/cjs/stores/settings/useAppearance.d.ts +1 -1
  117. package/cjs/stores/settings/useSetSettings.d.ts +1 -1
  118. package/cjs/stores/settings/useSettings.d.ts +1 -1
  119. package/cjs/stores/settings/useSettingsStore.d.ts +1 -1
  120. package/cjs/types/token.d.ts +1 -1
  121. package/cjs/types/widget.d.ts +5 -5
  122. package/cjs/utils/colors.d.ts +2 -2
  123. package/cjs/utils/colors.js +4 -4
  124. package/components/AppContainer.d.ts +1 -1
  125. package/components/BottomSheet/BottomSheet.d.ts +1 -1
  126. package/components/BottomSheet/types.d.ts +2 -2
  127. package/components/Card/Card.d.ts +1 -1
  128. package/components/Dialog.d.ts +2 -2
  129. package/components/GasSufficiencyMessage/GasSufficiencyMessage.d.ts +2 -2
  130. package/components/Header/Header.d.ts +1 -1
  131. package/components/Header/useHeaderActionStore.d.ts +1 -1
  132. package/components/LiFiLogo.d.ts +1 -1
  133. package/components/ProgressToNextUpdate/ProgressToNextUpdate.d.ts +1 -1
  134. package/components/ProgressToNextUpdate/ProgressToNextUpdate.js +1 -1
  135. package/components/SelectChainAndToken.d.ts +1 -1
  136. package/components/SelectTokenButton/SelectTokenButton.d.ts +1 -1
  137. package/components/SelectTokenButton/SelectTokenButton.js +1 -1
  138. package/components/Step/CircularProgress.d.ts +1 -1
  139. package/components/Step/CircularProgress.style.d.ts +2 -2
  140. package/components/Step/Step.d.ts +1 -1
  141. package/components/Step/StepProcess.d.ts +1 -1
  142. package/components/Step/StepTimer.d.ts +1 -1
  143. package/components/Step/utils.d.ts +2 -2
  144. package/components/Step/utils.js +1 -1
  145. package/components/StepActions/StepActions.d.ts +2 -2
  146. package/components/StepActions/StepActions.js +1 -1
  147. package/components/StepActions/types.d.ts +2 -2
  148. package/components/SwapButton/SwapButton.d.ts +1 -1
  149. package/components/SwapInProgress/SwapInProgress.d.ts +1 -1
  150. package/components/SwapInput/FormPriceHelperText.d.ts +1 -1
  151. package/components/SwapInput/FormPriceHelperText.js +1 -1
  152. package/components/SwapInput/SwapInput.d.ts +1 -1
  153. package/components/SwapInput/SwapInput.js +1 -1
  154. package/components/SwapInput/SwapInputAdornment.d.ts +1 -1
  155. package/components/SwapInput/SwapInputAdornment.js +1 -1
  156. package/components/SwapRouteCard/SwapRouteCard.d.ts +2 -2
  157. package/components/SwapRouteCard/SwapRouteCardSkeleton.d.ts +2 -2
  158. package/components/SwapRouteCard/SwapRouteNotFoundCard.d.ts +2 -2
  159. package/components/SwapRouteCard/types.d.ts +1 -1
  160. package/components/TextFitter/TextFitter.d.ts +2 -2
  161. package/components/TextFitter/TextFitter.js +1 -1
  162. package/components/TextFitter/types.d.ts +1 -1
  163. package/components/Token/Token.d.ts +2 -2
  164. package/components/TokenAvatar/TokenAvatar.d.ts +2 -2
  165. package/components/TokenList/TokenList.d.ts +2 -2
  166. package/components/TokenList/TokenListItem.d.ts +1 -1
  167. package/components/TokenList/VirtualizedTokenList.d.ts +2 -2
  168. package/components/TokenList/types.d.ts +4 -4
  169. package/config/lifi.d.ts +2 -1
  170. package/config/theme.d.ts +2 -2
  171. package/config/theme.js +4 -4
  172. package/config/version.d.ts +1 -1
  173. package/config/version.js +1 -1
  174. package/hooks/useGasSufficiency.d.ts +1 -1
  175. package/hooks/useRouteExecution.d.ts +1 -1
  176. package/hooks/useTokenBalances.d.ts +1 -1
  177. package/hooks/useTokenSearch.d.ts +1 -1
  178. package/hooks/useTokens.d.ts +1 -1
  179. package/hooks/useTools.d.ts +1 -1
  180. package/icons/LiFiFullLogo.d.ts +1 -1
  181. package/icons/LiFiLogo.d.ts +1 -1
  182. package/icons/LiFiToolLogo.d.ts +1 -1
  183. package/package.json +5 -5
  184. package/pages/MainPage/SwapRoutes.d.ts +1 -1
  185. package/pages/SelectTokenPage/ChainSelect.d.ts +1 -1
  186. package/pages/SelectTokenPage/SelectTokenPage.d.ts +2 -2
  187. package/pages/SwapHistoryPage/SwapHistoryItem.d.ts +1 -1
  188. package/pages/SwapPage/StatusBottomSheet.d.ts +1 -1
  189. package/pages/SwapPage/StatusBottomSheet.style.d.ts +2 -2
  190. package/pages/SwapPage/utils.d.ts +2 -2
  191. package/pages/SwapPage/utils.js +1 -1
  192. package/pages/SwapRoutesPage/SwapRoutesPage.d.ts +1 -1
  193. package/providers/WalletProvider/WalletProvider.d.ts +3 -3
  194. package/providers/WalletProvider/types.d.ts +3 -3
  195. package/providers/WidgetProvider/types.d.ts +1 -1
  196. package/stores/route/types.d.ts +1 -1
  197. package/stores/route/useExecutingRoutes.d.ts +1 -1
  198. package/stores/route/useSwapHistory.d.ts +1 -1
  199. package/stores/settings/types.d.ts +2 -2
  200. package/stores/settings/useAppearance.d.ts +1 -1
  201. package/stores/settings/useSetSettings.d.ts +1 -1
  202. package/stores/settings/useSettings.d.ts +1 -1
  203. package/stores/settings/useSettingsStore.d.ts +1 -1
  204. package/tsconfig.cjs.tsbuildinfo +1 -1
  205. package/types/token.d.ts +1 -1
  206. package/types/widget.d.ts +5 -5
  207. package/utils/colors.d.ts +2 -2
  208. package/utils/colors.js +4 -4
package/types/token.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { TokenAmount } from '@lifi/sdk';
1
+ import type { TokenAmount } from '@lifi/sdk';
2
2
  export interface Token extends TokenAmount {
3
3
  featured?: boolean;
4
4
  }
package/types/widget.d.ts CHANGED
@@ -1,8 +1,8 @@
1
- import { ChainKey, Token } from '@lifi/sdk';
2
- import { PaletteMode, PaletteOptions, Shape } from '@mui/material';
3
- import { TypographyOptions } from '@mui/material/styles/createTypography';
4
- import { Signer } from 'ethers';
5
- import { CSSProperties } from 'react';
1
+ import type { ChainKey, Token } from '@lifi/sdk';
2
+ import type { PaletteMode, PaletteOptions, Shape } from '@mui/material';
3
+ import type { TypographyOptions } from '@mui/material/styles/createTypography';
4
+ import type { Signer } from 'ethers';
5
+ import type { CSSProperties } from 'react';
6
6
  export declare type Appearance = PaletteMode | 'auto';
7
7
  export declare type ThemeConfig = {
8
8
  palette?: Pick<PaletteOptions, 'primary' | 'secondary'>;
package/utils/colors.d.ts CHANGED
@@ -1,3 +1,3 @@
1
- import { Theme } from '@mui/material';
1
+ import type { Theme } from '@mui/material';
2
2
  export declare const getContrastAlphaColor: (theme: Theme, alpha: string | number) => string;
3
- export declare const getContrastTextColor: (theme: Theme, background?: string) => string;
3
+ export declare const getContrastTextColor: (theme: Theme, background?: string) => "#fff" | "#000";
package/utils/colors.js CHANGED
@@ -1,8 +1,8 @@
1
+ import { common } from '@mui/material/colors';
1
2
  import { getContrastRatio } from '@mui/material/styles';
2
- import { dark, light } from '@mui/material/styles/createPalette';
3
3
  export const getContrastAlphaColor = (theme, alpha) => theme.palette.mode === 'light'
4
4
  ? `rgb(0 0 0 / ${alpha})`
5
5
  : `rgb(255 255 255 / ${alpha})`;
6
- export const getContrastTextColor = (theme, background) => getContrastRatio(dark.text.primary, background !== null && background !== void 0 ? background : theme.palette.primary.main) >= 3
7
- ? dark.text.primary
8
- : light.text.primary;
6
+ export const getContrastTextColor = (theme, background) => getContrastRatio(common.white, background !== null && background !== void 0 ? background : theme.palette.primary.main) >= 3
7
+ ? common.white
8
+ : common.black;