@rango-dev/widget-embedded 0.1.19 → 0.1.20-next.1

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 (154) hide show
  1. package/dist/QueueManager.d.ts +3 -3
  2. package/dist/QueueManager.d.ts.map +1 -1
  3. package/dist/Widget.d.ts +8 -0
  4. package/dist/Widget.d.ts.map +1 -0
  5. package/dist/components/AppRouter.d.ts +7 -7
  6. package/dist/components/AppRouter.d.ts.map +1 -1
  7. package/dist/components/AppRoutes.d.ts +7 -7
  8. package/dist/components/AppRoutes.d.ts.map +1 -1
  9. package/dist/components/BottomLogo.d.ts +2 -2
  10. package/dist/components/BottomLogo.d.ts.map +1 -1
  11. package/dist/components/ChangeSlippageButton.d.ts +2 -2
  12. package/dist/components/ChangeSlippageButton.d.ts.map +1 -1
  13. package/dist/components/ConfirmSwapErrors.d.ts +3 -3
  14. package/dist/components/ConfirmSwapErrors.d.ts.map +1 -1
  15. package/dist/components/ConfirmSwapWarnings.d.ts +2 -2
  16. package/dist/components/ConfirmSwapWarnings.d.ts.map +1 -1
  17. package/dist/components/Footer.d.ts +111 -1
  18. package/dist/components/Footer.d.ts.map +1 -1
  19. package/dist/components/HeaderButtons.d.ts +6 -6
  20. package/dist/components/HeaderButtons.d.ts.map +1 -1
  21. package/dist/components/Layout.d.ts +6 -6
  22. package/dist/components/Layout.d.ts.map +1 -1
  23. package/dist/components/PercentageChange.d.ts +8 -8
  24. package/dist/components/PercentageChange.d.ts.map +1 -1
  25. package/dist/components/RoutesOverview.d.ts +119 -9
  26. package/dist/components/RoutesOverview.d.ts.map +1 -1
  27. package/dist/components/SwapDetailsPlaceholder.d.ts +119 -9
  28. package/dist/components/SwapDetailsPlaceholder.d.ts.map +1 -1
  29. package/dist/components/SwitchFromAndTo.d.ts +3 -3
  30. package/dist/components/SwitchFromAndTo.d.ts.map +1 -1
  31. package/dist/components/TokenInfo.d.ts +17 -17
  32. package/dist/components/TokenInfo.d.ts.map +1 -1
  33. package/dist/components/TokenPreview.d.ts +20 -20
  34. package/dist/components/TokenPreview.d.ts.map +1 -1
  35. package/dist/components/UpdateUrl.d.ts +1 -1
  36. package/dist/components/UpdateUrl.d.ts.map +1 -1
  37. package/dist/components/warnings/BalanceErrors.d.ts +6 -6
  38. package/dist/components/warnings/BalanceErrors.d.ts.map +1 -1
  39. package/dist/components/warnings/ConfirmSwapExtraMessages.d.ts +6 -6
  40. package/dist/components/warnings/ConfirmSwapExtraMessages.d.ts.map +1 -1
  41. package/dist/components/warnings/HighSlippageWarning.d.ts +6 -6
  42. package/dist/components/warnings/HighSlippageWarning.d.ts.map +1 -1
  43. package/dist/components/warnings/MinRequiredSlippage.d.ts +6 -6
  44. package/dist/components/warnings/MinRequiredSlippage.d.ts.map +1 -1
  45. package/dist/constants/errors.d.ts +3 -3
  46. package/dist/constants/errors.d.ts.map +1 -1
  47. package/dist/constants/navigationRoutes.d.ts +13 -13
  48. package/dist/constants/navigationRoutes.d.ts.map +1 -1
  49. package/dist/constants/numbers.d.ts +2 -2
  50. package/dist/constants/numbers.d.ts.map +1 -1
  51. package/dist/constants/searchParams.d.ts +7 -7
  52. package/dist/constants/searchParams.d.ts.map +1 -1
  53. package/dist/constants/swapSettings.d.ts +5 -5
  54. package/dist/constants/swapSettings.d.ts.map +1 -1
  55. package/dist/globalStyles.d.ts +1 -1
  56. package/dist/globalStyles.d.ts.map +1 -1
  57. package/dist/hooks/useConfirmSwap.d.ts +10 -10
  58. package/dist/hooks/useConfirmSwap.d.ts.map +1 -1
  59. package/dist/hooks/useNavigateBack.d.ts +3 -3
  60. package/dist/hooks/useNavigateBack.d.ts.map +1 -1
  61. package/dist/hooks/usePrevious.d.ts +1 -1
  62. package/dist/hooks/usePrevious.d.ts.map +1 -1
  63. package/dist/hooks/useSelectLanguage.d.ts +4 -4
  64. package/dist/hooks/useSelectLanguage.d.ts.map +1 -1
  65. package/dist/hooks/useTheme.d.ts +30 -4
  66. package/dist/hooks/useTheme.d.ts.map +1 -1
  67. package/dist/i18n.d.ts +2 -2
  68. package/dist/i18n.d.ts.map +1 -1
  69. package/dist/index.d.ts +5 -9
  70. package/dist/index.d.ts.map +1 -1
  71. package/dist/index.js +2 -8
  72. package/dist/index.js.map +7 -0
  73. package/dist/mockData/pendingSwap.d.ts +1 -1
  74. package/dist/mockData/pendingSwap.d.ts.map +1 -1
  75. package/dist/pages/ConfirmSwapPage.d.ts +2 -2
  76. package/dist/pages/ConfirmSwapPage.d.ts.map +1 -1
  77. package/dist/pages/HistoryPage.d.ts +2 -2
  78. package/dist/pages/HistoryPage.d.ts.map +1 -1
  79. package/dist/pages/Home.d.ts +2 -2
  80. package/dist/pages/Home.d.ts.map +1 -1
  81. package/dist/pages/LiquiditySourcesPage.d.ts +6 -6
  82. package/dist/pages/LiquiditySourcesPage.d.ts.map +1 -1
  83. package/dist/pages/SelectChainPage.d.ts +7 -7
  84. package/dist/pages/SelectChainPage.d.ts.map +1 -1
  85. package/dist/pages/SelectTokenPage.d.ts +14 -14
  86. package/dist/pages/SelectTokenPage.d.ts.map +1 -1
  87. package/dist/pages/SettingsPage.d.ts +7 -7
  88. package/dist/pages/SettingsPage.d.ts.map +1 -1
  89. package/dist/pages/SwapDetailsPage.d.ts +2 -2
  90. package/dist/pages/SwapDetailsPage.d.ts.map +1 -1
  91. package/dist/pages/WalletsPage.d.ts +8 -8
  92. package/dist/pages/WalletsPage.d.ts.map +1 -1
  93. package/dist/services/httpService.d.ts +3 -3
  94. package/dist/services/httpService.d.ts.map +1 -1
  95. package/dist/store/bestRoute.d.ts +67 -31
  96. package/dist/store/bestRoute.d.ts.map +1 -1
  97. package/dist/store/meta.d.ts +17 -8
  98. package/dist/store/meta.d.ts.map +1 -1
  99. package/dist/store/selectors.d.ts +10 -10
  100. package/dist/store/selectors.d.ts.map +1 -1
  101. package/dist/store/settings.d.ts +55 -18
  102. package/dist/store/settings.d.ts.map +1 -1
  103. package/dist/store/ui.d.ts +22 -1
  104. package/dist/store/ui.d.ts.map +1 -1
  105. package/dist/store/wallets.d.ts +55 -33
  106. package/dist/store/wallets.d.ts.map +1 -1
  107. package/dist/types/config.d.ts +114 -114
  108. package/dist/types/config.d.ts.map +1 -1
  109. package/dist/types/index.d.ts +4 -4
  110. package/dist/types/index.d.ts.map +1 -1
  111. package/dist/types/routing.d.ts +57 -57
  112. package/dist/types/routing.d.ts.map +1 -1
  113. package/dist/types/swap.d.ts +16 -16
  114. package/dist/types/swap.d.ts.map +1 -1
  115. package/dist/types/wallets.d.ts +6 -6
  116. package/dist/types/wallets.d.ts.map +1 -1
  117. package/dist/utils/common.d.ts +3 -3
  118. package/dist/utils/common.d.ts.map +1 -1
  119. package/dist/utils/configs.d.ts +6 -6
  120. package/dist/utils/configs.d.ts.map +1 -1
  121. package/dist/utils/date.d.ts +2 -2
  122. package/dist/utils/date.d.ts.map +1 -1
  123. package/dist/utils/numbers.d.ts +13 -13
  124. package/dist/utils/numbers.d.ts.map +1 -1
  125. package/dist/utils/queue.d.ts +3 -3
  126. package/dist/utils/queue.d.ts.map +1 -1
  127. package/dist/utils/routing.d.ts +17 -17
  128. package/dist/utils/routing.d.ts.map +1 -1
  129. package/dist/utils/swap.d.ts +50 -50
  130. package/dist/utils/swap.d.ts.map +1 -1
  131. package/dist/utils/time.d.ts +3 -3
  132. package/dist/utils/time.d.ts.map +1 -1
  133. package/dist/utils/wallets.d.ts +27 -27
  134. package/dist/utils/wallets.d.ts.map +1 -1
  135. package/package.json +15 -11
  136. package/src/QueueManager.tsx +5 -1
  137. package/src/{index.tsx → Widget.tsx} +1 -14
  138. package/src/components/Layout.tsx +23 -17
  139. package/src/components/RoutesOverview.tsx +2 -2
  140. package/src/components/TokenInfo.tsx +4 -4
  141. package/src/components/TokenPreview.tsx +3 -3
  142. package/src/components/warnings/BalanceErrors.tsx +2 -2
  143. package/src/components/warnings/MinRequiredSlippage.tsx +2 -2
  144. package/src/index.ts +18 -0
  145. package/src/pages/ConfirmSwapPage.tsx +14 -12
  146. package/src/pages/SwapDetailsPage.tsx +1 -1
  147. package/src/pages/WalletsPage.tsx +6 -2
  148. package/src/utils/wallets.ts +6 -3
  149. package/dist/widget-embedded.cjs.development.js +0 -3398
  150. package/dist/widget-embedded.cjs.development.js.map +0 -1
  151. package/dist/widget-embedded.cjs.production.min.js +0 -3398
  152. package/dist/widget-embedded.cjs.production.min.js.map +0 -1
  153. package/dist/widget-embedded.esm.js +0 -3384
  154. package/dist/widget-embedded.esm.js.map +0 -1
@@ -1,116 +1,116 @@
1
- import { Asset } from 'rango-sdk';
2
- import { WalletType } from '@rango-dev/wallets-shared';
3
- /**
4
- * The above type defines a set of optional color properties for a widget.
5
- * @property {string} background
6
- * @property {string} foreground
7
- * @property {string} primary
8
- * @property {string} success
9
- * @property {string} error
10
- * @property {string} warning
11
- * @property {string} surface
12
- * @property {string} neutral
1
+ import { Asset } from 'rango-sdk';
2
+ import { WalletType } from '@rango-dev/wallets-shared';
3
+ /**
4
+ * The above type defines a set of optional color properties for a widget.
5
+ * @property {string} background
6
+ * @property {string} foreground
7
+ * @property {string} primary
8
+ * @property {string} success
9
+ * @property {string} error
10
+ * @property {string} warning
11
+ * @property {string} surface
12
+ * @property {string} neutral
13
13
 
14
- */
15
- export declare type WidgetColors = {
16
- background?: string;
17
- foreground?: string;
18
- primary?: string;
19
- success?: string;
20
- error?: string;
21
- warning?: string;
22
- surface?: string;
23
- neutral?: string;
24
- };
25
- /**
26
- * The `WidgetTheme` defines the properties of a widget theme, including mode, font family, colors, border
27
- * radius, width, and height.
28
- * @property {'auto' | 'light' | 'dark'} mode - The mode property is used to specify the default theme for
29
- * the widget.
30
- * @property {string} fontFamily - The font family to be used in the widget.
31
- * @property {Colors} colors - The `colors` property is a sub-property of the `WidgetTheme` object that
32
- * defines the color scheme for the widget. It is of type `Colors`, which is likely another object that
33
- * contains specific color values for various parts of the widget (e.g. background color, text color,
34
- * border color
35
- * @property {number} borderRadius - `borderRadius` is a property of the `WidgetTheme` type that
36
- * specifies the radius of the corners of a widget.
37
- * @property {number} width - The `width` property is a number that represents the width of the widget.
38
- * @property {number} height - The `height` property is a number that specifies the height of the widget.
39
- * @property {boolean} singleTheme - The `singleTheme` property is a boolean that specifies the theme is support dark and light or only light.
40
- */
41
- export declare type WidgetTheme = {
42
- mode?: 'auto' | 'light' | 'dark';
43
- fontFamily?: string;
44
- colors?: {
45
- light: WidgetColors;
46
- dark: WidgetColors;
47
- };
48
- borderRadius?: number;
49
- width?: number;
50
- height?: number;
51
- singleTheme?: boolean;
52
- };
53
- /**
54
- * `BlockchainAndTokenConfig`
55
- *
56
- * @property {string} blockchain - This property is optional and represents the default selected blockchain.
57
- * @property {Asset} token - The `token` property is a type of `Asset` and represents the default token
58
- * which is selected. e.g. {blockchain: 'BSC', symbol: 'BNB', address: null}
59
- * @property {string[]} blockchains - An optional array of strings representing the supported
60
- * blockchains. e.g. ['BSC','ETHEREUM']
61
- * @property {Asset[]} tokens - The `tokens` property is an optional array of `Asset` objects that
62
- * you could use that to limit tokens to some limited ones.
63
- */
64
- export declare type BlockchainAndTokenConfig = {
65
- blockchain?: string;
66
- token?: Asset;
67
- blockchains?: string[];
68
- tokens?: Asset[];
69
- };
70
- /**
71
- * The type WidgetConfig defines the configuration options for a widget, including API key, affiliate
72
- * reference, amount, blockchain and token configurations, liquidity sources, wallet types, language,
73
- * and theme.
74
- *
75
- * @property {string} apiKey - The API key used to communicate with Rango API
76
- * @property {string} affiliateRef - The affiliate reference is an optional string property in the
77
- * WidgetConfig type. It is used to set and track referrals or affiliations for the dApps.
78
- * @property {number} amount - The default input amount.
79
- * @property {BlockchainAndTokenConfig} from - The `from` property is an optional property of type
80
- * `BlockchainAndTokenConfig` that specifies the default blockchain and token from which the user wants to
81
- * exchange.It can also used to limit source swap blockchains/tokens to some limited ones.
82
- * @property {BlockchainAndTokenConfig} to - The "to" property is an optional property of type
83
- * "BlockchainAndTokenConfig" that specifies the default blockchain and token to which the user wants to
84
- * exchange.It can also used to limit destination swap blockchains/tokens to some limited ones.
85
- * blockchain during the transaction.
86
- * @property {string[]} liquiditySources - The `liquiditySources` property is an optional array of
87
- * strings that specifies the liquidity sources allowed dexes and bridges for the routing
88
- * @property {WalletType[]} wallets - The `wallets` property is an optional array of `WalletType`
89
- * values that represent the types of wallets that the widget should support. For example, it could
90
- * include values like `"metamask"`, `"kepler"`, or `"phantom"`.
91
- * @property {boolean} multiWallets - The `multiWallets` property is a boolean value that indicates
92
- * whether the widget should allow the user to select multiple wallets for the transaction.
93
- * @property {boolean} customAddress - A boolean value indicating whether the user can input a custom
94
- * address for the transaction. If set to true, the widget will allow the user to input a custom
95
- * address for the destination.
96
- * @property {string} language - The language property is an optional string that specifies the
97
- * default language in which the widget should be displayed. If not provided, the widget will default to the
98
- * language of the user's browser.
99
- * @property {WidgetTheme} theme - The `theme` property is a part of the `WidgetConfig` type and is
100
- * used to specify the visual theme of the widget. It is of type `WidgetTheme`, which is an interface
101
- * that defines the various properties of the theme, such as colors, fonts, and others.
102
- */
103
- export declare type WidgetConfig = {
104
- apiKey: string;
105
- affiliateRef?: string;
106
- amount?: number;
107
- from?: BlockchainAndTokenConfig;
108
- to?: BlockchainAndTokenConfig;
109
- liquiditySources?: string[];
110
- wallets?: WalletType[];
111
- multiWallets?: boolean;
112
- customAddress?: boolean;
113
- language?: string;
114
- theme?: WidgetTheme;
115
- };
14
+ */
15
+ export type WidgetColors = {
16
+ background?: string;
17
+ foreground?: string;
18
+ primary?: string;
19
+ success?: string;
20
+ error?: string;
21
+ warning?: string;
22
+ surface?: string;
23
+ neutral?: string;
24
+ };
25
+ /**
26
+ * The `WidgetTheme` defines the properties of a widget theme, including mode, font family, colors, border
27
+ * radius, width, and height.
28
+ * @property {'auto' | 'light' | 'dark'} mode - The mode property is used to specify the default theme for
29
+ * the widget.
30
+ * @property {string} fontFamily - The font family to be used in the widget.
31
+ * @property {Colors} colors - The `colors` property is a sub-property of the `WidgetTheme` object that
32
+ * defines the color scheme for the widget. It is of type `Colors`, which is likely another object that
33
+ * contains specific color values for various parts of the widget (e.g. background color, text color,
34
+ * border color
35
+ * @property {number} borderRadius - `borderRadius` is a property of the `WidgetTheme` type that
36
+ * specifies the radius of the corners of a widget.
37
+ * @property {number} width - The `width` property is a number that represents the width of the widget.
38
+ * @property {number} height - The `height` property is a number that specifies the height of the widget.
39
+ * @property {boolean} singleTheme - The `singleTheme` property is a boolean that specifies the theme is support dark and light or only light.
40
+ */
41
+ export type WidgetTheme = {
42
+ mode?: 'auto' | 'light' | 'dark';
43
+ fontFamily?: string;
44
+ colors?: {
45
+ light: WidgetColors;
46
+ dark: WidgetColors;
47
+ };
48
+ borderRadius?: number;
49
+ width?: number;
50
+ height?: number;
51
+ singleTheme?: boolean;
52
+ };
53
+ /**
54
+ * `BlockchainAndTokenConfig`
55
+ *
56
+ * @property {string} blockchain - This property is optional and represents the default selected blockchain.
57
+ * @property {Asset} token - The `token` property is a type of `Asset` and represents the default token
58
+ * which is selected. e.g. {blockchain: 'BSC', symbol: 'BNB', address: null}
59
+ * @property {string[]} blockchains - An optional array of strings representing the supported
60
+ * blockchains. e.g. ['BSC','ETHEREUM']
61
+ * @property {Asset[]} tokens - The `tokens` property is an optional array of `Asset` objects that
62
+ * you could use that to limit tokens to some limited ones.
63
+ */
64
+ export type BlockchainAndTokenConfig = {
65
+ blockchain?: string;
66
+ token?: Asset;
67
+ blockchains?: string[];
68
+ tokens?: Asset[];
69
+ };
70
+ /**
71
+ * The type WidgetConfig defines the configuration options for a widget, including API key, affiliate
72
+ * reference, amount, blockchain and token configurations, liquidity sources, wallet types, language,
73
+ * and theme.
74
+ *
75
+ * @property {string} apiKey - The API key used to communicate with Rango API
76
+ * @property {string} affiliateRef - The affiliate reference is an optional string property in the
77
+ * WidgetConfig type. It is used to set and track referrals or affiliations for the dApps.
78
+ * @property {number} amount - The default input amount.
79
+ * @property {BlockchainAndTokenConfig} from - The `from` property is an optional property of type
80
+ * `BlockchainAndTokenConfig` that specifies the default blockchain and token from which the user wants to
81
+ * exchange.It can also used to limit source swap blockchains/tokens to some limited ones.
82
+ * @property {BlockchainAndTokenConfig} to - The "to" property is an optional property of type
83
+ * "BlockchainAndTokenConfig" that specifies the default blockchain and token to which the user wants to
84
+ * exchange.It can also used to limit destination swap blockchains/tokens to some limited ones.
85
+ * blockchain during the transaction.
86
+ * @property {string[]} liquiditySources - The `liquiditySources` property is an optional array of
87
+ * strings that specifies the liquidity sources allowed dexes and bridges for the routing
88
+ * @property {WalletType[]} wallets - The `wallets` property is an optional array of `WalletType`
89
+ * values that represent the types of wallets that the widget should support. For example, it could
90
+ * include values like `"metamask"`, `"kepler"`, or `"phantom"`.
91
+ * @property {boolean} multiWallets - The `multiWallets` property is a boolean value that indicates
92
+ * whether the widget should allow the user to select multiple wallets for the transaction.
93
+ * @property {boolean} customAddress - A boolean value indicating whether the user can input a custom
94
+ * address for the transaction. If set to true, the widget will allow the user to input a custom
95
+ * address for the destination.
96
+ * @property {string} language - The language property is an optional string that specifies the
97
+ * default language in which the widget should be displayed. If not provided, the widget will default to the
98
+ * language of the user's browser.
99
+ * @property {WidgetTheme} theme - The `theme` property is a part of the `WidgetConfig` type and is
100
+ * used to specify the visual theme of the widget. It is of type `WidgetTheme`, which is an interface
101
+ * that defines the various properties of the theme, such as colors, fonts, and others.
102
+ */
103
+ export type WidgetConfig = {
104
+ apiKey: string;
105
+ affiliateRef?: string;
106
+ amount?: number;
107
+ from?: BlockchainAndTokenConfig;
108
+ to?: BlockchainAndTokenConfig;
109
+ liquiditySources?: string[];
110
+ wallets?: WalletType[];
111
+ multiWallets?: boolean;
112
+ customAddress?: boolean;
113
+ language?: string;
114
+ theme?: WidgetTheme;
115
+ };
116
116
  //# sourceMappingURL=config.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../src/types/config.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,WAAW,CAAC;AAClC,OAAO,EAAE,UAAU,EAAE,MAAM,2BAA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UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,KAAK,CAAC,EAAE,KAAK,CAAC;IACd,WAAW,CAAC,EAAE,MAAM,EAAE,CAAC;IACvB,MAAM,CAAC,EAAE,KAAK,EAAE,CAAC;CAClB,CAAC;AAEF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgCG;AACH,MAAM,MAAM,YAAY,GAAG;IACzB,MAAM,EAAE,MAAM,CAAC;IACf,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,IAAI,CAAC,EAAE,wBAAwB,CAAC;IAChC,EAAE,CAAC,EAAE,wBAAwB,CAAC;IAC9B,gBAAgB,CAAC,EAAE,MAAM,EAAE,CAAC;IAC5B,OAAO,CAAC,EAAE,UAAU,EAAE,CAAC;IACvB,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,KAAK,CAAC,EAAE,WAAW,CAAC;CACrB,CAAC"}
@@ -1,5 +1,5 @@
1
- export * from './swap';
2
- export * from './config';
3
- export * from './routing';
4
- export * from './wallets';
1
+ export * from './swap';
2
+ export * from './config';
3
+ export * from './routing';
4
+ export * from './wallets';
5
5
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/types/index.ts"],"names":[],"mappings":"AAAA,cAAc,QAAQ,CAAC;AACvB,cAAc,UAAU,CAAC;AACzB,cAAc,WAAW,CAAC;AAC1B,cAAc,WAAW,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/types/index.ts"],"names":[],"mappings":"AAAA,cAAc,QAAQ,CAAC;AACvB,cAAc,UAAU,CAAC;AACzB,cAAc,WAAW,CAAC;AAC1B,cAAc,WAAW,CAAC"}
@@ -1,58 +1,58 @@
1
- import { RouteState } from '../store/bestRoute';
2
- import { SettingsState } from '../store/settings';
3
- interface BestRouteStoreParams {
4
- fromChain?: RouteState['fromChain'];
5
- toChain?: RouteState['toChain'];
6
- fromToken?: RouteState['fromToken'];
7
- toToken?: RouteState['toToken'];
8
- inputAmount?: RouteState['inputAmount'];
9
- }
10
- interface SettingsStoreParams {
11
- slippage?: SettingsState['slippage'];
12
- customSlippage?: SettingsState['customSlippage'];
13
- disabledLiquiditySources?: SettingsState['disabledLiquiditySources'];
14
- infiniteApprove?: SettingsState['infiniteApprove'];
15
- }
16
- export declare type BestRouteEqualityParams = {
17
- store: 'bestRoute';
18
- prevState: BestRouteStoreParams;
19
- currentState: BestRouteStoreParams;
20
- } | {
21
- store: 'settings';
22
- prevState: SettingsStoreParams;
23
- currentState: SettingsStoreParams;
24
- };
25
- export declare enum ConfirmSwapErrorTypes {
26
- NO_ROUTE = 0,
27
- ROUTE_UPDATED_WITH_HIGH_VALUE_LOSS = 1,
28
- REQUEST_FAILED = 2,
29
- INSUFFICIENT_SLIPPAGE = 3,
30
- INSUFFICIENT_BALANCE = 4
31
- }
32
- export declare type ConfirmSwapError = {
33
- type: ConfirmSwapErrorTypes.REQUEST_FAILED;
34
- status?: number;
35
- } | {
36
- type: ConfirmSwapErrorTypes.INSUFFICIENT_SLIPPAGE;
37
- minRequiredSlippage: string | null;
38
- } | {
39
- type: ConfirmSwapErrorTypes.INSUFFICIENT_BALANCE;
40
- messages: string[];
41
- } | {
42
- type: Exclude<ConfirmSwapErrorTypes, ConfirmSwapErrorTypes.REQUEST_FAILED | ConfirmSwapErrorTypes.INSUFFICIENT_SLIPPAGE | ConfirmSwapErrorTypes.INSUFFICIENT_BALANCE>;
43
- };
44
- export declare type ConfirmSwapWarnings = {
45
- type: ConfirmSwapWarningTypes.ROUTE_AND_OUTPUT_AMOUNT_UPDATED;
46
- newOutputAmount: string;
47
- percentageChange: string;
48
- } | {
49
- type: Exclude<ConfirmSwapWarningTypes, ConfirmSwapWarningTypes.ROUTE_AND_OUTPUT_AMOUNT_UPDATED>;
50
- };
51
- export declare enum ConfirmSwapWarningTypes {
52
- ROUTE_UPDATED = 0,
53
- ROUTE_SWAPPERS_UPDATED = 1,
54
- ROUTE_COINS_UPDATED = 2,
55
- ROUTE_AND_OUTPUT_AMOUNT_UPDATED = 3
56
- }
57
- export {};
1
+ import { RouteState } from '../store/bestRoute';
2
+ import { SettingsState } from '../store/settings';
3
+ interface BestRouteStoreParams {
4
+ fromChain?: RouteState['fromChain'];
5
+ toChain?: RouteState['toChain'];
6
+ fromToken?: RouteState['fromToken'];
7
+ toToken?: RouteState['toToken'];
8
+ inputAmount?: RouteState['inputAmount'];
9
+ }
10
+ interface SettingsStoreParams {
11
+ slippage?: SettingsState['slippage'];
12
+ customSlippage?: SettingsState['customSlippage'];
13
+ disabledLiquiditySources?: SettingsState['disabledLiquiditySources'];
14
+ infiniteApprove?: SettingsState['infiniteApprove'];
15
+ }
16
+ export type BestRouteEqualityParams = {
17
+ store: 'bestRoute';
18
+ prevState: BestRouteStoreParams;
19
+ currentState: BestRouteStoreParams;
20
+ } | {
21
+ store: 'settings';
22
+ prevState: SettingsStoreParams;
23
+ currentState: SettingsStoreParams;
24
+ };
25
+ export declare enum ConfirmSwapErrorTypes {
26
+ NO_ROUTE = 0,
27
+ ROUTE_UPDATED_WITH_HIGH_VALUE_LOSS = 1,
28
+ REQUEST_FAILED = 2,
29
+ INSUFFICIENT_SLIPPAGE = 3,
30
+ INSUFFICIENT_BALANCE = 4
31
+ }
32
+ export type ConfirmSwapError = {
33
+ type: ConfirmSwapErrorTypes.REQUEST_FAILED;
34
+ status?: number;
35
+ } | {
36
+ type: ConfirmSwapErrorTypes.INSUFFICIENT_SLIPPAGE;
37
+ minRequiredSlippage: string | null;
38
+ } | {
39
+ type: ConfirmSwapErrorTypes.INSUFFICIENT_BALANCE;
40
+ messages: string[];
41
+ } | {
42
+ type: Exclude<ConfirmSwapErrorTypes, ConfirmSwapErrorTypes.REQUEST_FAILED | ConfirmSwapErrorTypes.INSUFFICIENT_SLIPPAGE | ConfirmSwapErrorTypes.INSUFFICIENT_BALANCE>;
43
+ };
44
+ export type ConfirmSwapWarnings = {
45
+ type: ConfirmSwapWarningTypes.ROUTE_AND_OUTPUT_AMOUNT_UPDATED;
46
+ newOutputAmount: string;
47
+ percentageChange: string;
48
+ } | {
49
+ type: Exclude<ConfirmSwapWarningTypes, ConfirmSwapWarningTypes.ROUTE_AND_OUTPUT_AMOUNT_UPDATED>;
50
+ };
51
+ export declare enum ConfirmSwapWarningTypes {
52
+ ROUTE_UPDATED = 0,
53
+ ROUTE_SWAPPERS_UPDATED = 1,
54
+ ROUTE_COINS_UPDATED = 2,
55
+ ROUTE_AND_OUTPUT_AMOUNT_UPDATED = 3
56
+ }
57
+ export {};
58
58
  //# sourceMappingURL=routing.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"routing.d.ts","sourceRoot":"","sources":["../src/types/routing.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAChD,OAAO,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAC;AAElD,UAAU,oBAAoB;IAC5B,SAAS,CAAC,EAAE,UAAU,CAAC,WAAW,CAAC,CAAC;IACpC,OAAO,CAAC,EAAE,UAAU,CAAC,SAAS,CAAC,CAAC;IAChC,SAAS,CAAC,EAAE,UAAU,CAAC,WAAW,CAAC,CAAC;IACpC,OAAO,CAAC,EAAE,UAAU,CAAC,SAAS,CAAC,CAAC;IAChC,WAAW,CAAC,EAAE,UAAU,CAAC,aAAa,CAAC,CAAC;CACzC;AAED,UAAU,mBAAmB;IAC3B,QAAQ,CAAC,EAAE,aAAa,CAAC,UAAU,CAAC,CAAC;IACrC,cAAc,CAAC,EAAE,aAAa,CAAC,gBAAgB,CAAC,CAAC;IACjD,wBAAwB,CAAC,EAAE,aAAa,CAAC,0BAA0B,CAAC,CAAC;IACrE,eAAe,CAAC,EAAE,aAAa,CAAC,iBAAiB,CAAC,CAAC;CACpD;A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,IAAI,CAAC;CACpC,GACD;IAAE,IAAI,EAAE,qBAAqB,CAAC,oBAAoB,CAAC;IAAC,QAAQ,EAAE,MAAM,EAAE,CAAA;CAAE,GACxE;IACE,IAAI,EAAE,OAAO,CACX,qBAAqB,EACnB,qBAAqB,CAAC,cAAc,GACpC,qBAAqB,CAAC,qBAAqB,GAC3C,qBAAqB,CAAC,oBAAoB,CAC7C,CAAC;CACH,CAAC;AAEN,MAAM,MAAM,mBAAmB,GAC3B;IACE,IAAI,EAAE,uBAAuB,CAAC,+BAA+B,CAAC;IAC9D,eAAe,EAAE,MAAM,CAAC;IACxB,gBAAgB,EAAE,MAAM,CAAC;CAC1B,GACD;IACE,IAAI,EAAE,OAAO,CACX,uBAAuB,EACvB,uBAAuB,CAAC,+BAA+B,CACxD,CAAC;CACH,CAAC;AAEN,oBAAY,uBAAuB;IACjC,aAAa,IAAA;IACb,sBAAsB,IAAA;IACtB,mBAAmB,IAAA;IACnB,+BAA+B,IAAA;CAChC"}
@@ -1,17 +1,17 @@
1
- import { SwapSavedSettings } from '@rango-dev/ui/dist/types/swaps';
2
- export declare type PendingSwapSettings = Omit<SwapSavedSettings, 'disabledSwappersIds'>;
3
- export declare type SwapButtonState = ({
4
- disabled: true;
5
- } | {
6
- disabled: false;
7
- hasWarning?: boolean;
8
- }) & {
9
- title: string;
10
- };
11
- export declare type ConvertedToken = {
12
- symbol: string;
13
- address: string | null;
14
- blockchain: string;
15
- outputAmount: string | null;
16
- } | null;
1
+ import { SwapSavedSettings } from '@rango-dev/ui/dist/types/swaps';
2
+ export type PendingSwapSettings = Omit<SwapSavedSettings, 'disabledSwappersIds'>;
3
+ export type SwapButtonState = ({
4
+ disabled: true;
5
+ } | {
6
+ disabled: false;
7
+ hasWarning?: boolean;
8
+ }) & {
9
+ title: string;
10
+ };
11
+ export type ConvertedToken = {
12
+ symbol: string;
13
+ address: string | null;
14
+ blockchain: string;
15
+ outputAmount: string | null;
16
+ } | null;
17
17
  //# sourceMappingURL=swap.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"swap.d.ts","sourceRoot":"","sources":["../src/types/swap.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,gCAAgC,CAAC;AAEnE,oBAAY,mBAAmB,GAAG,IAAI,CACpC,iBAAiB,EACjB,qBAAqB,CACtB,CAAC;AAEF,oBAAY,eAAe,GAAG,CAC1B;IAAE,QAAQ,EAAE,IAAI,CAAA;CAAE,GAClB;IAAE,QAAQ,EAAE,KAAK,CAAC;IAAC,UAAU,CAAC,EAAE,OAAO,CAAA;CAAE,CAC5C,GAAG;IACF,KAAK,EAAE,MAAM,CAAC;CACf,CAAC;AAEF,oBAAY,cAAc,GAAG;IAC3B,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IACvB,UAAU,EAAE,MAAM,CAAC;IACnB,YAAY,EAAE,MAAM,GAAG,IAAI,CAAC;CAC7B,GAAG,IAAI,CAAC"}
1
+ {"version":3,"file":"swap.d.ts","sourceRoot":"","sources":["../../src/types/swap.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,gCAAgC,CAAC;AAEnE,MAAM,MAAM,mBAAmB,GAAG,IAAI,CACpC,iBAAiB,EACjB,qBAAqB,CACtB,CAAC;AAEF,MAAM,MAAM,eAAe,GAAG,CAC1B;IAAE,QAAQ,EAAE,IAAI,CAAA;CAAE,GAClB;IAAE,QAAQ,EAAE,KAAK,CAAC;IAAC,UAAU,CAAC,EAAE,OAAO,CAAA;CAAE,CAC5C,GAAG;IACF,KAAK,EAAE,MAAM,CAAC;CACf,CAAC;AAEF,MAAM,MAAM,cAAc,GAAG;IAC3B,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IACvB,UAAU,EAAE,MAAM,CAAC;IACnB,YAAY,EAAE,MAAM,GAAG,IAAI,CAAC;CAC7B,GAAG,IAAI,CAAC"}
@@ -1,7 +1,7 @@
1
- import { WalletType } from '@rango-dev/wallets-shared';
2
- export interface Wallet {
3
- chain: string;
4
- address: string;
5
- walletType: WalletType;
6
- }
1
+ import { WalletType } from '@rango-dev/wallets-shared';
2
+ export interface Wallet {
3
+ chain: string;
4
+ address: string;
5
+ walletType: WalletType;
6
+ }
7
7
  //# sourceMappingURL=wallets.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"wallets.d.ts","sourceRoot":"","sources":["../src/types/wallets.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,2BAA2B,CAAC;AAEvD,MAAM,WAAW,MAAM;IACrB,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,CAAC;IAChB,UAAU,EAAE,UAAU,CAAC;CACxB"}
1
+ {"version":3,"file":"wallets.d.ts","sourceRoot":"","sources":["../../src/types/wallets.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,2BAA2B,CAAC;AAEvD,MAAM,WAAW,MAAM;IACrB,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,CAAC;IAChB,UAAU,EAAE,UAAU,CAAC;CACxB"}
@@ -1,4 +1,4 @@
1
- export declare function removeDuplicateFrom<T>(array: T[]): T[];
2
- export declare function areEqual(array1: (number | string)[], array2: (number | string)[]): boolean;
3
- export declare function debounce(fn: Function, time: number): (...args: any) => void;
1
+ export declare function removeDuplicateFrom<T>(array: T[]): T[];
2
+ export declare function areEqual(array1: (number | string)[], array2: (number | string)[]): boolean;
3
+ export declare function debounce(fn: Function, time: number): (...args: any) => void;
4
4
  //# sourceMappingURL=common.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"common.d.ts","sourceRoot":"","sources":["../src/utils/common.ts"],"names":[],"mappings":"AAAA,wBAAgB,mBAAmB,CAAC,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,GAAG,CAAC,EAAE,CAEtD;AAED,wBAAgB,QAAQ,CACtB,MAAM,EAAE,CAAC,MAAM,GAAG,MAAM,CAAC,EAAE,EAC3B,MAAM,EAAE,CAAC,MAAM,GAAG,MAAM,CAAC,EAAE,WAK5B;AAID,wBAAgB,QAAQ,CAAC,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,MAAM,aAGvB,GAAG,UAS9B"}
1
+ {"version":3,"file":"common.d.ts","sourceRoot":"","sources":["../../src/utils/common.ts"],"names":[],"mappings":"AAAA,wBAAgB,mBAAmB,CAAC,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,GAAG,CAAC,EAAE,CAEtD;AAED,wBAAgB,QAAQ,CACtB,MAAM,EAAE,CAAC,MAAM,GAAG,MAAM,CAAC,EAAE,EAC3B,MAAM,EAAE,CAAC,MAAM,GAAG,MAAM,CAAC,EAAE,WAK5B;AAID,wBAAgB,QAAQ,CAAC,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,MAAM,aAGvB,GAAG,UAS9B"}
@@ -1,7 +1,7 @@
1
- export interface Configs {
2
- API_KEY: string;
3
- }
4
- export declare function getConfig(name: keyof Configs): string;
5
- export declare function setConfig(name: keyof Configs, value: any): any;
6
- export declare function initConfig(nextConfigs: Configs): Configs;
1
+ export interface Configs {
2
+ API_KEY: string;
3
+ }
4
+ export declare function getConfig(name: keyof Configs): string;
5
+ export declare function setConfig(name: keyof Configs, value: any): any;
6
+ export declare function initConfig(nextConfigs: Configs): Configs;
7
7
  //# sourceMappingURL=configs.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"configs.d.ts","sourceRoot":"","sources":["../src/utils/configs.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,OAAO;IACtB,OAAO,EAAE,MAAM,CAAC;CACjB;AAQD,wBAAgB,SAAS,CAAC,IAAI,EAAE,MAAM,OAAO,UAE5C;AAED,wBAAgB,SAAS,CAAC,IAAI,EAAE,MAAM,OAAO,EAAE,KAAK,EAAE,GAAG,OAIxD;AAED,wBAAgB,UAAU,CAAC,WAAW,EAAE,OAAO,WAS9C"}
1
+ {"version":3,"file":"configs.d.ts","sourceRoot":"","sources":["../../src/utils/configs.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,OAAO;IACtB,OAAO,EAAE,MAAM,CAAC;CACjB;AAQD,wBAAgB,SAAS,CAAC,IAAI,EAAE,MAAM,OAAO,UAE5C;AAED,wBAAgB,SAAS,CAAC,IAAI,EAAE,MAAM,OAAO,EAAE,KAAK,EAAE,GAAG,OAIxD;AAED,wBAAgB,UAAU,CAAC,WAAW,EAAE,OAAO,WAS9C"}
@@ -1,3 +1,3 @@
1
- import { GroupBy } from '@rango-dev/ui';
2
- export declare const groupSwapsByDate: GroupBy;
1
+ import { GroupBy } from '@rango-dev/ui';
2
+ export declare const groupSwapsByDate: GroupBy;
3
3
  //# sourceMappingURL=date.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"date.d.ts","sourceRoot":"","sources":["../src/utils/date.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AAExC,eAAO,MAAM,gBAAgB,EAAE,OAyD9B,CAAC"}
1
+ {"version":3,"file":"date.d.ts","sourceRoot":"","sources":["../../src/utils/date.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AAExC,eAAO,MAAM,gBAAgB,EAAE,OAyD9B,CAAC"}
@@ -1,14 +1,14 @@
1
- import { BigNumber } from 'bignumber.js';
2
- import { BestRouteResponse } from 'rango-sdk';
3
- export declare const percentToString: (p: number, fractions?: number) => string;
4
- export declare const secondsToString: (s: number) => string;
5
- export declare const numberToString: (number: BigNumber | string | null | undefined, minDecimals?: number | null, maxDecimals?: number | null) => string;
6
- export declare const convertBigNumberToHex: (value: BigNumber, decimals: number) => string;
7
- export declare const uint8ArrayToHex: (buffer: Uint8Array) => string;
8
- export declare function dollarToConciseString(num: number | undefined): string;
9
- export declare function removeExtraDecimals(num: string, maxDecimals: number): string;
10
- export declare const totalArrivalTime: (data: BestRouteResponse | null) => number;
11
- export declare const rawFees: (data: BestRouteResponse) => string;
12
- export declare const containsText: (text: string, searchText: string) => boolean;
13
- export declare const isPositiveNumber: (text?: string | undefined) => boolean;
1
+ import { BigNumber } from 'bignumber.js';
2
+ import { BestRouteResponse } from 'rango-sdk';
3
+ export declare const percentToString: (p: number, fractions?: number) => string;
4
+ export declare const secondsToString: (s: number) => string;
5
+ export declare const numberToString: (number: BigNumber | string | null | undefined, minDecimals?: number | null, maxDecimals?: number | null) => string;
6
+ export declare const convertBigNumberToHex: (value: BigNumber, decimals: number) => string;
7
+ export declare const uint8ArrayToHex: (buffer: Uint8Array) => string;
8
+ export declare function dollarToConciseString(num: number | undefined): string;
9
+ export declare function removeExtraDecimals(num: string, maxDecimals: number): string;
10
+ export declare const totalArrivalTime: (data: BestRouteResponse | null) => number;
11
+ export declare const rawFees: (data: BestRouteResponse) => string;
12
+ export declare const containsText: (text: string, searchText: string) => boolean;
13
+ export declare const isPositiveNumber: (text?: string) => boolean;
14
14
  //# sourceMappingURL=numbers.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"numbers.d.ts","sourceRoot":"","sources":["../src/utils/numbers.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACzC,OAAO,EAAE,iBAAiB,EAAE,MAAM,WAAW,CAAC;AAE9C,eAAO,MAAM,eAAe,MAAO,MAAM,yBAAkB,MAC7B,CAAC;AAC/B,eAAO,MAAM,eAAe,MAAO,MAAM,KAAG,MAM3C,CAAC;AAEF,eAAO,MAAM,cAAc,WACjB,SAAS,GAAG,MAAM,GAAG,IAAI,GAAG,SAAS,gBAChC,MAAM,GAAG,IAAI,gBACb,MAAM,GAAG,IAAI,KACzB,MA6DF,CAAC;AAEF,eAAO,MAAM,qBAAqB,UACzB,SAAS,YACN,MAAM,KACf,MAEF,CAAC;AAEF,eAAO,MAAM,eAAe,WAAY,UAAU,KAAG,MAIpD,CAAC;AAE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B,eAAO,MAAM,YAAY,SAAU,MAAM,cAAc,MAAM,YACF,CAAC;AAE5D,eAAO,MAAM,gBAAgB,UAAW,MAAM,YACd,CAAC"}
@@ -1,4 +1,4 @@
1
- import { Manager } from '@rango-dev/queue-manager-core';
2
- import { PendingSwapWithQueueID } from '@rango-dev/queue-manager-rango-preset';
3
- export declare const getPendingSwaps: (manager: Manager | undefined) => PendingSwapWithQueueID[];
1
+ import { Manager } from '@rango-dev/queue-manager-core';
2
+ import { PendingSwapWithQueueID } from '@rango-dev/queue-manager-rango-preset';
3
+ export declare const getPendingSwaps: (manager: Manager | undefined) => PendingSwapWithQueueID[];
4
4
  //# sourceMappingURL=queue.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"queue.d.ts","sourceRoot":"","sources":["../src/utils/queue.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,+BAA+B,CAAC;AACxD,OAAO,EACL,sBAAsB,EAEvB,MAAM,uCAAuC,CAAC;AAE/C,eAAO,MAAM,eAAe,YAAa,OAAO,GAAG,SAAS,6BAiB3D,CAAC"}
1
+ {"version":3,"file":"queue.d.ts","sourceRoot":"","sources":["../../src/utils/queue.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,+BAA+B,CAAC;AACxD,OAAO,EACL,sBAAsB,EAEvB,MAAM,uCAAuC,CAAC;AAE/C,eAAO,MAAM,eAAe,YAAa,OAAO,GAAG,SAAS,6BAiB3D,CAAC"}
@@ -1,18 +1,18 @@
1
- import { SimulationAssetAndAmount, SimulationValidationStatus } from '@rango-dev/ui/dist/types/swaps';
2
- import BigNumber from 'bignumber.js';
3
- import { BestRouteResponse, BlockchainMeta, Token } from 'rango-sdk';
4
- import { BestRouteEqualityParams, Wallet } from '../types';
5
- import { PendingSwap } from '@rango-dev/queue-manager-rango-preset';
6
- export declare function searchParamsToToken(tokens: Token[], searchParams: string | null, chain: BlockchainMeta | null): Token | null;
7
- export declare function getBestRouteToTokenUsdPrice(bestRoute: BestRouteResponse | null): number | null | undefined;
8
- export declare function isNumberOfSwapsChanged(route1: BestRouteResponse, route2: BestRouteResponse): boolean;
9
- export declare function isRouteSwappersUpdated(route1: BestRouteResponse, route2: BestRouteResponse): boolean;
10
- export declare function isRouteInternalCoinsUpdated(route1: BestRouteResponse, route2: BestRouteResponse): boolean;
11
- export declare function isRouteChanged(route1: BestRouteResponse, route2: BestRouteResponse): boolean;
12
- export declare function outToRatioHasWarning(fromUsdValue: BigNumber | null, outToInRatio: BigNumber | 0): boolean;
13
- export declare function getRequiredBalanceOfWallet(selectedWallet: Wallet, fee: SimulationValidationStatus[] | null): SimulationAssetAndAmount[] | null;
14
- export declare function isRouteParametersChanged(params: BestRouteEqualityParams): boolean | undefined;
15
- export declare function getFormatedBestRoute(bestRoute: BestRouteResponse | null): BestRouteResponse | null;
16
- export declare function getFormatedPendingSwap(pendingSwap: PendingSwap): PendingSwap;
17
- export declare const getBestRouteStatus: (loading: boolean, error: boolean) => "failed" | "success" | "loading";
1
+ import { SimulationAssetAndAmount, SimulationValidationStatus } from '@rango-dev/ui/dist/types/swaps';
2
+ import BigNumber from 'bignumber.js';
3
+ import { BestRouteResponse, BlockchainMeta, Token } from 'rango-sdk';
4
+ import { BestRouteEqualityParams, Wallet } from '../types';
5
+ import { PendingSwap } from '@rango-dev/queue-manager-rango-preset';
6
+ export declare function searchParamsToToken(tokens: Token[], searchParams: string | null, chain: BlockchainMeta | null): Token | null;
7
+ export declare function getBestRouteToTokenUsdPrice(bestRoute: BestRouteResponse | null): number | null | undefined;
8
+ export declare function isNumberOfSwapsChanged(route1: BestRouteResponse, route2: BestRouteResponse): boolean;
9
+ export declare function isRouteSwappersUpdated(route1: BestRouteResponse, route2: BestRouteResponse): boolean;
10
+ export declare function isRouteInternalCoinsUpdated(route1: BestRouteResponse, route2: BestRouteResponse): boolean;
11
+ export declare function isRouteChanged(route1: BestRouteResponse, route2: BestRouteResponse): boolean;
12
+ export declare function outToRatioHasWarning(fromUsdValue: BigNumber | null, outToInRatio: BigNumber | 0): boolean;
13
+ export declare function getRequiredBalanceOfWallet(selectedWallet: Wallet, fee: SimulationValidationStatus[] | null): SimulationAssetAndAmount[] | null;
14
+ export declare function isRouteParametersChanged(params: BestRouteEqualityParams): boolean | undefined;
15
+ export declare function getFormatedBestRoute(bestRoute: BestRouteResponse | null): BestRouteResponse | null;
16
+ export declare function getFormatedPendingSwap(pendingSwap: PendingSwap): PendingSwap;
17
+ export declare const getBestRouteStatus: (loading: boolean, error: boolean) => "loading" | "success" | "failed";
18
18
  //# sourceMappingURL=routing.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"routing.d.ts","sourceRoot":"","sources":["../src/utils/routing.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,wBAAwB,EACxB,0BAA0B,EAC3B,MAAM,gCAAgC,CAAC;AACxC,OAAO,SAAS,MAAM,cAAc,CAAC;AACrC,OAAO,EAAE,iBAAiB,EAAE,cAAc,EAAE,KAAK,EAAE,MAAM,WAAW,CAAC;AAErE,OAAO,EAAE,uBAAuB,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAE3D,OAAO,EAAE,WAAW,EAAE,MAAM,uCAAuC,CAAC;AAEpE,wBAAgB,mBAAmB,CACjC,MAAM,EAAE,KAAK,EAAE,EACf,YAAY,EAAE,MAAM,GAAG,IAAI,EAC3B,KAAK,EAAE,cAAc,GAAG,IAAI,GAC3B,KAAK,GAAG,IAAI,CAkBd;AAED,wBAAgB,2BAA2B,CACzC,SAAS,EAAE,iBAAiB,GAAG,IAAI,GAClC,MAAM,GAAG,IAAI,GAAG,SAAS,CAG3B;AAED,wBAAgB,sBAAsB,CACpC,MAAM,EAAE,iBAAiB,EACzB,MAAM,EAAE,iBAAiB,WAK1B;AAED,wBAAgB,sBAAsB,CACpC,MAAM,EAAE,iBAAiB,EACzB,MAAM,EAAE,iBAAiB,WAO1B;AAED,wBAAgB,2BAA2B,CACzC,MAAM,EAAE,iBAAiB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