@rango-dev/ui 0.22.1-next.16 → 0.22.1-next.18
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +6 -6
- package/dist/index.js.map +4 -4
- package/dist/widget/ui/src/components/Alert/Alert.styles.d.ts +157 -0
- package/dist/widget/ui/src/components/Alert/Alert.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/BlockchainsChip/BlockchainsChip.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/QuoteCost/QuoteCost.d.ts.map +1 -1
- package/dist/widget/ui/src/components/QuoteCost/QuoteCost.styles.d.ts +314 -0
- package/dist/widget/ui/src/components/QuoteCost/QuoteCost.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/StepDetails/StepDetails.d.ts.map +1 -1
- package/dist/widget/ui/src/components/StepDetails/StepDetails.styles.d.ts +6 -0
- package/dist/widget/ui/src/components/StepDetails/StepDetails.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/SwapListItem/mock.d.ts +1 -1
- package/dist/widget/ui/src/components/SwapListItem/mock.d.ts.map +1 -1
- package/dist/widget/ui/src/components/TokenAmount/TokenAmount.d.ts.map +1 -1
- package/dist/widget/ui/src/components/TokenAmount/TokenAmount.styles.d.ts +471 -1
- package/dist/widget/ui/src/components/TokenAmount/TokenAmount.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/common/Image.d.ts +157 -0
- package/dist/widget/ui/src/components/common/Image.d.ts.map +1 -1
- package/dist/widget/ui/src/components/common/index.d.ts +1 -1
- package/dist/widget/ui/src/components/common/index.d.ts.map +1 -1
- package/dist/widget/ui/src/containers/SwapHistory/SwapHistory.d.ts +1 -1
- package/dist/widget/ui/src/containers/SwapHistory/SwapHistory.d.ts.map +1 -1
- package/dist/widget/ui/src/containers/SwapHistory/SwapHistory.stories.d.ts +2 -2
- package/dist/widget/ui/src/containers/SwapHistory/SwapHistory.stories.d.ts.map +1 -1
- package/dist/widget/ui/src/containers/SwapHistory/mock.d.ts +1 -1
- package/dist/widget/ui/src/containers/SwapHistory/mock.d.ts.map +1 -1
- package/dist/widget/ui/src/containers/SwapInput/SwapInput.d.ts.map +1 -1
- package/dist/widget/ui/src/containers/SwapInput/SwapInput.styles.d.ts +942 -0
- package/dist/widget/ui/src/containers/SwapInput/SwapInput.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/containers/SwapInput/TokenSection.d.ts.map +1 -1
- package/dist/widget/ui/src/containers/SwapInput/TokenSection.styles.d.ts +471 -0
- package/dist/widget/ui/src/containers/SwapInput/TokenSection.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/types/index.d.ts +0 -1
- package/dist/widget/ui/src/types/index.d.ts.map +1 -1
- package/dist/widget/ui/src/types/swaps.d.ts +1 -27
- package/dist/widget/ui/src/types/swaps.d.ts.map +1 -1
- package/package.json +4 -4
- package/src/components/Alert/Alert.styles.ts +7 -7
- package/src/components/Alert/Alert.tsx +2 -2
- package/src/components/BlockchainsChip/BlockchainsChip.styles.ts +2 -1
- package/src/components/QuoteCost/QuoteCost.styles.ts +14 -12
- package/src/components/QuoteCost/QuoteCost.tsx +12 -7
- package/src/components/StepDetails/StepDetails.styles.ts +32 -24
- package/src/components/StepDetails/StepDetails.tsx +8 -4
- package/src/components/SwapListItem/mock.ts +21 -6
- package/src/components/TokenAmount/TokenAmount.styles.ts +12 -10
- package/src/components/TokenAmount/TokenAmount.tsx +23 -17
- package/src/components/common/Image.tsx +1 -2
- package/src/components/common/index.ts +1 -1
- package/src/containers/SwapHistory/SwapHistory.stories.tsx +5 -2
- package/src/containers/SwapHistory/SwapHistory.tsx +1 -1
- package/src/containers/SwapHistory/mock.ts +24 -8
- package/src/containers/SwapInput/SwapInput.styles.ts +34 -27
- package/src/containers/SwapInput/SwapInput.tsx +14 -8
- package/src/containers/SwapInput/TokenSection.styles.ts +16 -13
- package/src/containers/SwapInput/TokenSection.tsx +10 -4
- package/src/types/index.ts +0 -1
- package/src/types/swaps.ts +0 -38
- package/dist/widget/ui/src/containers/History/types.d.ts +0 -2
- package/dist/widget/ui/src/containers/History/types.d.ts.map +0 -1
- package/src/containers/History/types.tsx +0 -1
|
@@ -5,7 +5,13 @@ import React from 'react';
|
|
|
5
5
|
|
|
6
6
|
import { ChainToken, Divider, Skeleton, Typography } from '../../components';
|
|
7
7
|
|
|
8
|
-
import {
|
|
8
|
+
import {
|
|
9
|
+
chainNameStyles,
|
|
10
|
+
Container,
|
|
11
|
+
skeletonStyles,
|
|
12
|
+
tokenChainStyles,
|
|
13
|
+
TokenSectionContainer,
|
|
14
|
+
} from './TokenSection.styles';
|
|
9
15
|
|
|
10
16
|
export function TokenSection(props: TokenSectionProps) {
|
|
11
17
|
const {
|
|
@@ -27,9 +33,9 @@ export function TokenSection(props: TokenSectionProps) {
|
|
|
27
33
|
tokenImage={tokenImage}
|
|
28
34
|
loading={loading}
|
|
29
35
|
/>
|
|
30
|
-
<div className=
|
|
36
|
+
<div className={tokenChainStyles()}>
|
|
31
37
|
{loading ? (
|
|
32
|
-
<div className=
|
|
38
|
+
<div className={skeletonStyles()}>
|
|
33
39
|
<Skeleton variant="text" size="large" width={92} />
|
|
34
40
|
<Divider size={8} />
|
|
35
41
|
<Skeleton variant="text" size="medium" width={92} />
|
|
@@ -44,7 +50,7 @@ export function TokenSection(props: TokenSectionProps) {
|
|
|
44
50
|
<Typography
|
|
45
51
|
variant="body"
|
|
46
52
|
size="medium"
|
|
47
|
-
className=
|
|
53
|
+
className={chainNameStyles()}>
|
|
48
54
|
{error || (!loading && !chain) ? i18n.t('Chain') : chain}
|
|
49
55
|
</Typography>
|
|
50
56
|
</>
|
package/src/types/index.ts
CHANGED
package/src/types/swaps.ts
CHANGED
|
@@ -1,45 +1,7 @@
|
|
|
1
1
|
import type {
|
|
2
|
-
BestRouteResponse,
|
|
3
2
|
BlockchainValidationStatus,
|
|
4
|
-
SimulationResult,
|
|
5
|
-
SwapResult,
|
|
6
3
|
WalletRequiredAssets,
|
|
7
4
|
} from 'rango-sdk';
|
|
8
5
|
|
|
9
|
-
export type SwapStatus = 'running' | 'failed' | 'success';
|
|
10
|
-
export type MessageSeverity = 'error' | 'warning' | 'info' | 'success';
|
|
11
|
-
|
|
12
|
-
export type StepStatus =
|
|
13
|
-
| 'created'
|
|
14
|
-
| 'running'
|
|
15
|
-
| 'failed'
|
|
16
|
-
| 'success'
|
|
17
|
-
| 'waitingForApproval'
|
|
18
|
-
| 'approved';
|
|
19
|
-
|
|
20
|
-
export enum PendingSwapNetworkStatus {
|
|
21
|
-
WaitingForConnectingWallet = 'waitingForConnectingWallet',
|
|
22
|
-
WaitingForQueue = 'waitingForQueue',
|
|
23
|
-
WaitingForNetworkChange = 'waitingForNetworkChange',
|
|
24
|
-
NetworkChanged = 'networkChanged',
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
export type WalletTypeAndAddress = {
|
|
28
|
-
walletType: string;
|
|
29
|
-
address: string;
|
|
30
|
-
};
|
|
31
|
-
export type SwapSavedSettings = {
|
|
32
|
-
slippage: string;
|
|
33
|
-
disabledSwappersIds: string[];
|
|
34
|
-
disabledSwappersGroups: string[];
|
|
35
|
-
};
|
|
36
|
-
|
|
37
6
|
export type SimulationAssetAndAmount = WalletRequiredAssets;
|
|
38
7
|
export type SimulationValidationStatus = BlockchainValidationStatus;
|
|
39
|
-
export type BestRouteType = BestRouteResponse;
|
|
40
|
-
|
|
41
|
-
export type BestRouteWithFee = Omit<BestRouteResponse, 'result'> & {
|
|
42
|
-
result: Omit<SimulationResult, 'swaps'> & {
|
|
43
|
-
swaps: (SwapResult & { feeInUsd?: string })[];
|
|
44
|
-
};
|
|
45
|
-
};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../../../src/containers/History/types.tsx"],"names":[],"mappings":"AAAA,YAAY,EAAE,WAAW,EAAE,MAAM,uCAAuC,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export type { PendingSwap } from '@rango-dev/queue-manager-rango-preset';
|