@rango-dev/ui 0.22.1-next.1 → 0.22.1-next.11
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/translations/en.d.ts.map +1 -1
- package/dist/translations/es.d.ts.map +1 -1
- package/dist/translations/fr.d.ts.map +1 -1
- package/dist/translations/ja.d.ts.map +1 -1
- package/dist/widget/ui/src/components/Alert/Alert.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/Checkbox/Checkbox.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/ListItem/ListItem.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/QuoteCost/QuoteCost.d.ts +4 -0
- package/dist/widget/ui/src/components/QuoteCost/QuoteCost.d.ts.map +1 -0
- package/dist/widget/ui/src/components/{BestRoute/BestRouteSkeleton.styles.d.ts → QuoteCost/QuoteCost.styles.d.ts} +3 -7
- package/dist/widget/ui/src/components/QuoteCost/QuoteCost.styles.d.ts.map +1 -0
- package/dist/widget/ui/src/components/{RouteCost/RouteCost.types.d.ts → QuoteCost/QuoteCost.types.d.ts} +1 -1
- package/dist/widget/ui/src/components/QuoteCost/QuoteCost.types.d.ts.map +1 -0
- package/dist/widget/ui/src/components/QuoteCost/index.d.ts +2 -0
- package/dist/widget/ui/src/components/QuoteCost/index.d.ts.map +1 -0
- package/dist/widget/ui/src/components/Radio/Radio.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/RoutesOverview/RoutesOverview.d.ts.map +1 -1
- package/dist/widget/ui/src/components/SelectableCategoryList/SelectableCategoryList.d.ts.map +1 -1
- package/dist/widget/ui/src/components/SelectableCategoryList/SelectableCategoryList.helpers.d.ts +16 -2
- package/dist/widget/ui/src/components/SelectableCategoryList/SelectableCategoryList.helpers.d.ts.map +1 -1
- package/dist/widget/ui/src/components/SelectableCategoryList/index.d.ts +1 -0
- package/dist/widget/ui/src/components/SelectableCategoryList/index.d.ts.map +1 -1
- package/dist/widget/ui/src/components/StepDetails/StepDetails.styles.d.ts +1 -1
- package/dist/widget/ui/src/components/StepDetails/StepDetails.types.d.ts +16 -2
- package/dist/widget/ui/src/components/StepDetails/StepDetails.types.d.ts.map +1 -1
- package/dist/widget/ui/src/components/StepDetails/index.d.ts +1 -1
- package/dist/widget/ui/src/components/StepDetails/index.d.ts.map +1 -1
- package/dist/widget/ui/src/components/StepDetails/mock.d.ts +1 -1
- package/dist/widget/ui/src/components/StepDetails/mock.d.ts.map +1 -1
- package/dist/widget/ui/src/components/Switch/Switch.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/components/index.d.ts +1 -2
- package/dist/widget/ui/src/components/index.d.ts.map +1 -1
- package/dist/widget/ui/src/containers/BlockchainSelector/BlockchainSelector.d.ts +3 -3
- package/dist/widget/ui/src/containers/BlockchainSelector/BlockchainSelector.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 +159 -0
- package/dist/widget/ui/src/containers/SwapInput/SwapInput.styles.d.ts.map +1 -1
- package/dist/widget/ui/src/containers/SwapInput/SwapInput.types.d.ts +1 -0
- package/dist/widget/ui/src/containers/SwapInput/SwapInput.types.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.map +1 -1
- package/dist/widget/ui/src/containers/TokenSelector/TokenSelector.d.ts +2 -2
- package/dist/widget/ui/src/containers/TokenSelector/TokenSelector.d.ts.map +1 -1
- package/dist/widget/ui/src/icons/CosmosCategory.d.ts +5 -0
- package/dist/widget/ui/src/icons/CosmosCategory.d.ts.map +1 -0
- package/dist/widget/ui/src/icons/EvmCategory.d.ts +5 -0
- package/dist/widget/ui/src/icons/EvmCategory.d.ts.map +1 -0
- package/dist/widget/ui/src/icons/Language.d.ts +5 -0
- package/dist/widget/ui/src/icons/Language.d.ts.map +1 -0
- package/dist/widget/ui/src/icons/OtherCategory.d.ts +5 -0
- package/dist/widget/ui/src/icons/OtherCategory.d.ts.map +1 -0
- package/dist/widget/ui/src/icons/UtxoCategory.d.ts +5 -0
- package/dist/widget/ui/src/icons/UtxoCategory.d.ts.map +1 -0
- package/dist/widget/ui/src/icons/index.d.ts +5 -0
- package/dist/widget/ui/src/icons/index.d.ts.map +1 -1
- package/dist/widget/ui/src/index.d.ts +0 -1
- package/dist/widget/ui/src/index.d.ts.map +1 -1
- package/dist/widget/ui/src/{helper → utils}/index.d.ts +0 -3
- package/dist/widget/ui/src/utils/index.d.ts.map +1 -0
- package/package.json +2 -2
- package/src/components/Alert/Alert.styles.ts +2 -5
- package/src/components/Checkbox/Checkbox.styles.ts +5 -1
- package/src/components/ListItem/ListItem.styles.ts +7 -0
- package/src/components/ListItem/ListItem.tsx +1 -1
- package/src/components/PriceImpact/PriceImpact.tsx +2 -2
- package/src/components/{RouteCost/RouteCost.styles.ts → QuoteCost/QuoteCost.styles.ts} +7 -0
- package/src/components/{RouteCost/RouteCost.tsx → QuoteCost/QuoteCost.tsx} +3 -4
- package/src/components/QuoteCost/index.ts +1 -0
- package/src/components/Radio/Radio.styles.tsx +5 -2
- package/src/components/RoutesOverview/RoutesOverview.tsx +6 -2
- package/src/components/SelectableCategoryList/SelectableCategoryList.helpers.ts +40 -13
- package/src/components/SelectableCategoryList/SelectableCategoryList.tsx +47 -46
- package/src/components/SelectableCategoryList/index.ts +1 -0
- package/src/components/SelectableWalletList/SelectableWalletList.tsx +1 -1
- package/src/components/StepDetails/StepDetails.stories.tsx +1 -1
- package/src/components/StepDetails/StepDetails.styles.ts +4 -4
- package/src/components/StepDetails/StepDetails.tsx +3 -3
- package/src/components/StepDetails/StepDetails.types.ts +17 -2
- package/src/components/StepDetails/index.ts +1 -1
- package/src/components/StepDetails/mock.ts +1 -1
- package/src/components/SvgIcon/SvgIcon.style.ts +1 -1
- package/src/components/Switch/Switch.styles.tsx +6 -2
- package/src/components/index.ts +1 -2
- package/src/containers/BlockchainSelector/BlockchainSelector.tsx +9 -8
- package/src/containers/SwapInput/SwapInput.styles.ts +33 -0
- package/src/containers/SwapInput/SwapInput.tsx +16 -19
- package/src/containers/SwapInput/SwapInput.types.ts +1 -0
- package/src/containers/SwapInput/TokenSection.styles.ts +8 -0
- package/src/containers/SwapInput/TokenSection.tsx +4 -1
- package/src/containers/TokenSelector/TokenSelector.tsx +8 -10
- package/src/icons/CosmosCategory.tsx +137 -0
- package/src/icons/EvmCategory.tsx +74 -0
- package/src/icons/Language.tsx +55 -0
- package/src/icons/OtherCategory.tsx +72 -0
- package/src/icons/UtxoCategory.tsx +44 -0
- package/src/icons/index.ts +5 -0
- package/src/index.ts +0 -1
- package/src/theme.ts +4 -4
- package/src/utils/index.ts +23 -0
- package/dist/widget/ui/src/components/BestRoute/BestRoute.d.ts +0 -4
- package/dist/widget/ui/src/components/BestRoute/BestRoute.d.ts.map +0 -1
- package/dist/widget/ui/src/components/BestRoute/BestRoute.stories.d.ts +0 -7
- package/dist/widget/ui/src/components/BestRoute/BestRoute.stories.d.ts.map +0 -1
- package/dist/widget/ui/src/components/BestRoute/BestRoute.styles.d.ts +0 -1429
- package/dist/widget/ui/src/components/BestRoute/BestRoute.styles.d.ts.map +0 -1
- package/dist/widget/ui/src/components/BestRoute/BestRoute.types.d.ts +0 -34
- package/dist/widget/ui/src/components/BestRoute/BestRoute.types.d.ts.map +0 -1
- package/dist/widget/ui/src/components/BestRoute/BestRouteSkeleton.d.ts +0 -4
- package/dist/widget/ui/src/components/BestRoute/BestRouteSkeleton.d.ts.map +0 -1
- package/dist/widget/ui/src/components/BestRoute/BestRouteSkeleton.styles.d.ts.map +0 -1
- package/dist/widget/ui/src/components/BestRoute/BestRouteSkeleton.types.d.ts +0 -6
- package/dist/widget/ui/src/components/BestRoute/BestRouteSkeleton.types.d.ts.map +0 -1
- package/dist/widget/ui/src/components/BestRoute/RouteSummary.d.ts +0 -12
- package/dist/widget/ui/src/components/BestRoute/RouteSummary.d.ts.map +0 -1
- package/dist/widget/ui/src/components/BestRoute/RouteSummary.styles.d.ts +0 -158
- package/dist/widget/ui/src/components/BestRoute/RouteSummary.styles.d.ts.map +0 -1
- package/dist/widget/ui/src/components/BestRoute/index.d.ts +0 -5
- package/dist/widget/ui/src/components/BestRoute/index.d.ts.map +0 -1
- package/dist/widget/ui/src/components/BestRoute/mock.d.ts +0 -3
- package/dist/widget/ui/src/components/BestRoute/mock.d.ts.map +0 -1
- package/dist/widget/ui/src/components/RouteCost/RouteCost.d.ts +0 -4
- package/dist/widget/ui/src/components/RouteCost/RouteCost.d.ts.map +0 -1
- package/dist/widget/ui/src/components/RouteCost/RouteCost.styles.d.ts +0 -158
- package/dist/widget/ui/src/components/RouteCost/RouteCost.styles.d.ts.map +0 -1
- package/dist/widget/ui/src/components/RouteCost/RouteCost.types.d.ts.map +0 -1
- package/dist/widget/ui/src/components/RouteCost/index.d.ts +0 -2
- package/dist/widget/ui/src/components/RouteCost/index.d.ts.map +0 -1
- package/dist/widget/ui/src/helper/index.d.ts.map +0 -1
- package/src/components/BestRoute/BestRoute.stories.tsx +0 -17
- package/src/components/BestRoute/BestRoute.styles.ts +0 -213
- package/src/components/BestRoute/BestRoute.tsx +0 -176
- package/src/components/BestRoute/BestRoute.types.ts +0 -32
- package/src/components/BestRoute/BestRouteSkeleton.styles.ts +0 -110
- package/src/components/BestRoute/BestRouteSkeleton.tsx +0 -112
- package/src/components/BestRoute/BestRouteSkeleton.types.ts +0 -5
- package/src/components/BestRoute/RouteSummary.styles.ts +0 -15
- package/src/components/BestRoute/RouteSummary.tsx +0 -48
- package/src/components/BestRoute/index.ts +0 -4
- package/src/components/BestRoute/mock.ts +0 -142
- package/src/components/RouteCost/index.ts +0 -1
- package/src/helper/index.ts +0 -99
- /package/src/components/{RouteCost/RouteCost.types.ts → QuoteCost/QuoteCost.types.ts} +0 -0
|
@@ -1 +1 @@
|
|
|
1
|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Ac,SAAS,CAAC
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,cAAc,CAAC;AAC7B,cAAc,cAAc,CAAC;AAC7B,cAAc,SAAS,CAAC;AACxB,cAAc,SAAS,CAAC;AACxB,cAAc,SAAS,CAAC;AACxB,cAAc,SAAS,CAAC"}
|
|
@@ -1,6 +1,3 @@
|
|
|
1
1
|
export declare function containsText(text: string, searchText: string): boolean;
|
|
2
2
|
export declare function getConciseAddress(address: string | null, maxChars?: number, ellipsisLength?: number): string | null;
|
|
3
|
-
export declare const generateRangeColors: (name: string, mode: 'light' | 'dark', color?: string) => {
|
|
4
|
-
[x: string]: string | undefined;
|
|
5
|
-
};
|
|
6
3
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/utils/index.ts"],"names":[],"mappings":"AAEA,wBAAgB,YAAY,CAAC,IAAI,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,GAAG,OAAO,CAEtE;AAED,wBAAgB,iBAAiB,CAC/B,OAAO,EAAE,MAAM,GAAG,IAAI,EACtB,QAAQ,SAAI,EACZ,cAAc,SAAI,GACjB,MAAM,GAAG,IAAI,CAYf"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@rango-dev/ui",
|
|
3
|
-
"version": "0.22.1-next.
|
|
3
|
+
"version": "0.22.1-next.11",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"module": "./dist/index.js",
|
|
@@ -65,7 +65,7 @@
|
|
|
65
65
|
"@radix-ui/react-radio-group": "^1.1.1",
|
|
66
66
|
"@radix-ui/react-switch": "^1.0.1",
|
|
67
67
|
"@radix-ui/react-tooltip": "^1.0.2",
|
|
68
|
-
"@rango-dev/wallets-shared": "^0.21.1-next.
|
|
68
|
+
"@rango-dev/wallets-shared": "^0.21.1-next.3",
|
|
69
69
|
"@stitches/react": "^1.2.8",
|
|
70
70
|
"rango-sdk": "^0.1.35",
|
|
71
71
|
"react-virtualized-auto-sizer": "^1.0.7",
|
|
@@ -20,11 +20,7 @@ export const Container = styled('div', {
|
|
|
20
20
|
paddingLeft: '$24',
|
|
21
21
|
},
|
|
22
22
|
'.description': {
|
|
23
|
-
|
|
24
|
-
[`.${darkTheme} &`]: {
|
|
25
|
-
$$color: '$colors$neutral600',
|
|
26
|
-
},
|
|
27
|
-
color: '$$color',
|
|
23
|
+
color: '$neutral700',
|
|
28
24
|
fontSize: '$10',
|
|
29
25
|
lineHeight: '$12',
|
|
30
26
|
},
|
|
@@ -124,6 +120,7 @@ export const IconHighlight = styled('div', {
|
|
|
124
120
|
justifyContent: 'center',
|
|
125
121
|
alignItems: 'center',
|
|
126
122
|
alignSelf: 'flex-start',
|
|
123
|
+
flexShrink: 0,
|
|
127
124
|
variants: {
|
|
128
125
|
type: {
|
|
129
126
|
success: {
|
|
@@ -13,7 +13,11 @@ export const CheckboxRoot = styled(RadixCheckbox.Root, {
|
|
|
13
13
|
width: '1rem',
|
|
14
14
|
height: '1rem',
|
|
15
15
|
padding: 0,
|
|
16
|
-
|
|
16
|
+
$$borderColor: '$colors$neutral600',
|
|
17
|
+
[`.${darkTheme} &`]: {
|
|
18
|
+
$$borderColor: '$colors$neutral700',
|
|
19
|
+
},
|
|
20
|
+
border: '1px solid $$borderColor',
|
|
17
21
|
backgroundColor: 'transparent',
|
|
18
22
|
cursor: 'pointer',
|
|
19
23
|
'&[data-state="checked"]': {
|
|
@@ -22,6 +22,13 @@ export const BaseListItem = styled('li', {
|
|
|
22
22
|
flexShrink: 1,
|
|
23
23
|
flexBasis: 'auto',
|
|
24
24
|
textAlign: 'left',
|
|
25
|
+
'._description': {
|
|
26
|
+
$$color: '$colors$neutral600',
|
|
27
|
+
[`.${darkTheme} &`]: {
|
|
28
|
+
$$color: '$colors$neutral700',
|
|
29
|
+
},
|
|
30
|
+
color: '$$color',
|
|
31
|
+
},
|
|
25
32
|
|
|
26
33
|
'.item-text-title': {
|
|
27
34
|
fontWeight: 'bold',
|
|
@@ -16,7 +16,7 @@ function ListItem(props: ListItemProps) {
|
|
|
16
16
|
<div className="item-text-container">
|
|
17
17
|
{title && <div className="item-text-title">{title}</div>}
|
|
18
18
|
{description && (
|
|
19
|
-
<Typography variant="body"
|
|
19
|
+
<Typography variant="body" className="_description" size="small">
|
|
20
20
|
{description}
|
|
21
21
|
</Typography>
|
|
22
22
|
)}
|
|
@@ -9,7 +9,7 @@ import { Container } from './PriceImpact.styles';
|
|
|
9
9
|
export function PriceImpact(props: PriceImpactProps) {
|
|
10
10
|
const { size, outputUsdValue, percentageChange, warningLevel, error } = props;
|
|
11
11
|
|
|
12
|
-
let percentageChangeColor = '$
|
|
12
|
+
let percentageChangeColor = '$neutral600';
|
|
13
13
|
if (!outputUsdValue || warningLevel === 'low') {
|
|
14
14
|
percentageChangeColor = '$warning500';
|
|
15
15
|
} else if (warningLevel === 'high') {
|
|
@@ -22,7 +22,7 @@ export function PriceImpact(props: PriceImpactProps) {
|
|
|
22
22
|
<Typography
|
|
23
23
|
size={size === 'small' ? 'small' : 'medium'}
|
|
24
24
|
variant="body"
|
|
25
|
-
color=
|
|
25
|
+
color="$neutral600">
|
|
26
26
|
{`~$${outputUsdValue}`}
|
|
27
27
|
</Typography>
|
|
28
28
|
)}
|
|
@@ -1,14 +1,13 @@
|
|
|
1
|
-
import type { PropTypes } from './
|
|
1
|
+
import type { PropTypes } from './QuoteCost.types';
|
|
2
2
|
|
|
3
3
|
import React from 'react';
|
|
4
4
|
|
|
5
5
|
import { GasIcon, NumberIcon, TimeIcon } from '../../icons';
|
|
6
|
-
import { Separator } from '../BestRoute/BestRoute.styles';
|
|
7
6
|
import { Typography } from '../Typography';
|
|
8
7
|
|
|
9
|
-
import { Container } from './
|
|
8
|
+
import { Container, Separator } from './QuoteCost.styles';
|
|
10
9
|
|
|
11
|
-
export function
|
|
10
|
+
export function QuoteCost(props: PropTypes) {
|
|
12
11
|
const { fee, time, steps } = props;
|
|
13
12
|
return (
|
|
14
13
|
<Container>
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { QuoteCost } from './QuoteCost';
|
|
@@ -9,8 +9,11 @@ export const StyledItem = styled(Radio.Item, {
|
|
|
9
9
|
borderRadius: '100%',
|
|
10
10
|
cursor: 'pointer',
|
|
11
11
|
backgroundColor: 'transparent',
|
|
12
|
-
|
|
13
|
-
|
|
12
|
+
$$borderColor: '$colors$neutral600',
|
|
13
|
+
[`.${darkTheme} &`]: {
|
|
14
|
+
$$borderColor: '$colors$neutral700',
|
|
15
|
+
},
|
|
16
|
+
border: '1px solid $$borderColor',
|
|
14
17
|
'&[data-state="checked"]': {
|
|
15
18
|
$$color: '$colors$secondary500',
|
|
16
19
|
[`.${darkTheme} &`]: {
|
|
@@ -2,7 +2,7 @@ import type { BestRouteResponse } from 'rango-sdk';
|
|
|
2
2
|
|
|
3
3
|
import React from 'react';
|
|
4
4
|
|
|
5
|
-
import { styled } from '../../theme';
|
|
5
|
+
import { darkTheme, styled } from '../../theme';
|
|
6
6
|
import { Divider } from '../Divider';
|
|
7
7
|
import { AngleRightIcon, GasIcon } from '../Icon';
|
|
8
8
|
|
|
@@ -13,7 +13,11 @@ export const Container = styled('div', {
|
|
|
13
13
|
padding: '$8',
|
|
14
14
|
borderRadius: '$xs',
|
|
15
15
|
backgroundColor: '$background',
|
|
16
|
-
color: '$neutral600',
|
|
16
|
+
$$color: '$colors$neutral600',
|
|
17
|
+
[`.${darkTheme} &`]: {
|
|
18
|
+
$$color: '$colors$neutral700',
|
|
19
|
+
},
|
|
20
|
+
color: '$$color',
|
|
17
21
|
fontSize: '$12',
|
|
18
22
|
|
|
19
23
|
'.routes': {
|
|
@@ -1,7 +1,29 @@
|
|
|
1
1
|
import { type BlockchainMeta, TransactionType } from 'rango-sdk';
|
|
2
2
|
|
|
3
|
+
import {
|
|
4
|
+
CosmosCategoryIcon,
|
|
5
|
+
EvmCategoryIcon,
|
|
6
|
+
OtherCategoryIcon,
|
|
7
|
+
UtxoCategoryIcon,
|
|
8
|
+
} from '../../icons';
|
|
9
|
+
|
|
3
10
|
import { BlockchainCategories } from './SelectableCategoryList.types';
|
|
4
11
|
|
|
12
|
+
export const blockchainCategoryIcons = {
|
|
13
|
+
[BlockchainCategories.EVM]: EvmCategoryIcon,
|
|
14
|
+
[BlockchainCategories.COSMOS]: CosmosCategoryIcon,
|
|
15
|
+
[BlockchainCategories.UTXO]: UtxoCategoryIcon,
|
|
16
|
+
[BlockchainCategories.OTHER]: OtherCategoryIcon,
|
|
17
|
+
};
|
|
18
|
+
|
|
19
|
+
export const blockchainCategoryLabel = {
|
|
20
|
+
[BlockchainCategories.ALL]: 'All',
|
|
21
|
+
[BlockchainCategories.EVM]: 'EVM',
|
|
22
|
+
[BlockchainCategories.COSMOS]: 'Cosmos',
|
|
23
|
+
[BlockchainCategories.UTXO]: 'UTXO',
|
|
24
|
+
[BlockchainCategories.OTHER]: 'Other',
|
|
25
|
+
};
|
|
26
|
+
|
|
5
27
|
const filterByType = (blockchain: BlockchainMeta, type: string): boolean => {
|
|
6
28
|
switch (type) {
|
|
7
29
|
case BlockchainCategories.ALL:
|
|
@@ -19,17 +41,22 @@ const filterByType = (blockchain: BlockchainMeta, type: string): boolean => {
|
|
|
19
41
|
}
|
|
20
42
|
};
|
|
21
43
|
|
|
22
|
-
const
|
|
23
|
-
[BlockchainCategories.EVM]: ['ETH', 'BSC', 'POLYGON'],
|
|
24
|
-
[BlockchainCategories.COSMOS]: ['COSMOS', 'OSMOSIS', 'JUNO'],
|
|
25
|
-
[BlockchainCategories.UTXO]: ['BTC', 'LTC', 'BCH'],
|
|
26
|
-
[BlockchainCategories.OTHER]: ['STARKNET', 'TRON', 'SOLANA'],
|
|
27
|
-
};
|
|
28
|
-
|
|
29
|
-
export const generateBlockchainsLogo = (
|
|
44
|
+
export const hasAnyCategory = (
|
|
30
45
|
list: BlockchainMeta[],
|
|
31
|
-
|
|
32
|
-
) =>
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
46
|
+
blockchainType: string
|
|
47
|
+
) => list.some((blockchain) => filterByType(blockchain, blockchainType));
|
|
48
|
+
|
|
49
|
+
export const getCountCategories = (list: BlockchainMeta[]) => {
|
|
50
|
+
const categoriesToCheck = Object.values(BlockchainCategories).filter(
|
|
51
|
+
(category) => category !== BlockchainCategories.ALL
|
|
52
|
+
);
|
|
53
|
+
|
|
54
|
+
const categoriesCount = categoriesToCheck.reduce((count, category) => {
|
|
55
|
+
const isCategoryPresent = list.some((blockchain) =>
|
|
56
|
+
filterByType(blockchain, category)
|
|
57
|
+
);
|
|
58
|
+
return count + (isCategoryPresent ? 1 : 0);
|
|
59
|
+
}, 0);
|
|
60
|
+
|
|
61
|
+
return categoriesCount;
|
|
62
|
+
};
|
|
@@ -4,19 +4,19 @@ import type { PropTypes } from './SelectableCategoryList.types';
|
|
|
4
4
|
import { i18n } from '@lingui/core';
|
|
5
5
|
import React from 'react';
|
|
6
6
|
|
|
7
|
-
import { Divider,
|
|
7
|
+
import { Divider, Skeleton, Typography } from '..';
|
|
8
8
|
import { BlockchainsChip } from '../BlockchainsChip';
|
|
9
9
|
|
|
10
|
-
import { generateBlockchainsLogo } from './SelectableCategoryList.helpers';
|
|
11
10
|
import {
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
} from './SelectableCategoryList.
|
|
11
|
+
blockchainCategoryIcons,
|
|
12
|
+
blockchainCategoryLabel,
|
|
13
|
+
hasAnyCategory,
|
|
14
|
+
} from './SelectableCategoryList.helpers';
|
|
15
|
+
import { Container } from './SelectableCategoryList.styles';
|
|
16
16
|
import { BlockchainCategories } from './SelectableCategoryList.types';
|
|
17
17
|
|
|
18
18
|
export function SelectableCategoryList(props: PropTypes) {
|
|
19
|
-
const { setCategory, category,
|
|
19
|
+
const { setCategory, category, isLoading, blockchains } = props;
|
|
20
20
|
const categories = Object.keys(
|
|
21
21
|
BlockchainCategories
|
|
22
22
|
) as BlockchainCategories[];
|
|
@@ -32,45 +32,46 @@ export function SelectableCategoryList(props: PropTypes) {
|
|
|
32
32
|
/>
|
|
33
33
|
))}
|
|
34
34
|
{!isLoading &&
|
|
35
|
-
categories.map((blockchainCategory) =>
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
35
|
+
categories.map((blockchainCategory) => {
|
|
36
|
+
const Logo =
|
|
37
|
+
blockchainCategory !== BlockchainCategories.ALL
|
|
38
|
+
? blockchainCategoryIcons[blockchainCategory]
|
|
39
|
+
: null;
|
|
40
|
+
|
|
41
|
+
const hasBlockchain = hasAnyCategory(blockchains, blockchainCategory);
|
|
42
|
+
|
|
43
|
+
return (
|
|
44
|
+
hasBlockchain && (
|
|
45
|
+
<BlockchainsChip
|
|
46
|
+
selected={category === blockchainCategory}
|
|
47
|
+
key={blockchainCategory}
|
|
48
|
+
onClick={() => setCategory(blockchainCategory)}>
|
|
49
|
+
{Logo && (
|
|
50
|
+
<>
|
|
51
|
+
<Logo size={28} />
|
|
52
|
+
<Divider size={12} />
|
|
53
|
+
</>
|
|
54
|
+
)}
|
|
55
|
+
<Typography
|
|
56
|
+
size="xsmall"
|
|
57
|
+
variant="body"
|
|
58
|
+
color={
|
|
59
|
+
blockchainCategory === BlockchainCategories.ALL
|
|
60
|
+
? 'secondary500'
|
|
61
|
+
: undefined
|
|
62
|
+
}>
|
|
63
|
+
{i18n.t({
|
|
64
|
+
id: '{blockchainCategory}',
|
|
65
|
+
values: {
|
|
66
|
+
blockchainCategory:
|
|
67
|
+
blockchainCategoryLabel[blockchainCategory],
|
|
68
|
+
},
|
|
69
|
+
})}
|
|
70
|
+
</Typography>
|
|
71
|
+
</BlockchainsChip>
|
|
72
|
+
)
|
|
73
|
+
);
|
|
74
|
+
})}
|
|
74
75
|
</Container>
|
|
75
76
|
);
|
|
76
77
|
}
|
|
@@ -2,8 +2,8 @@ import type { PropsWithChildren } from 'react';
|
|
|
2
2
|
|
|
3
3
|
import React, { useEffect, useState } from 'react';
|
|
4
4
|
|
|
5
|
-
import { getConciseAddress } from '../../helper';
|
|
6
5
|
import { styled } from '../../theme';
|
|
6
|
+
import { getConciseAddress } from '../../utils';
|
|
7
7
|
import { Image } from '../common';
|
|
8
8
|
import { Typography } from '../Typography';
|
|
9
9
|
|
|
@@ -8,8 +8,8 @@ export const Container = styled('div', {
|
|
|
8
8
|
border: '1px solid transparent',
|
|
9
9
|
variants: {
|
|
10
10
|
type: {
|
|
11
|
-
'
|
|
12
|
-
'
|
|
11
|
+
'quote-details': { border: 'none' },
|
|
12
|
+
'swap-progress': {
|
|
13
13
|
$$color: '$colors$neutral100',
|
|
14
14
|
[`.${darkTheme} &`]: {
|
|
15
15
|
$$color: '$colors$neutral300',
|
|
@@ -63,8 +63,8 @@ export const Container = styled('div', {
|
|
|
63
63
|
|
|
64
64
|
export const SwapperImage = styled('div', {
|
|
65
65
|
borderRadius: '100%',
|
|
66
|
-
width: '
|
|
67
|
-
height: '
|
|
66
|
+
width: '24px',
|
|
67
|
+
height: '24px',
|
|
68
68
|
overflow: 'hidden',
|
|
69
69
|
border: '1.5px solid transparent',
|
|
70
70
|
variants: {
|
|
@@ -40,7 +40,7 @@ const StepDetailsComponent = forwardRef<HTMLDivElement, StepDetailsProps>(
|
|
|
40
40
|
ref={containerRef}
|
|
41
41
|
tabIndex={tabIndex}>
|
|
42
42
|
<div className="swapper">
|
|
43
|
-
{type === '
|
|
43
|
+
{type === 'swap-progress' && hasSeparator && (
|
|
44
44
|
<StepSeparator state={state} />
|
|
45
45
|
)}
|
|
46
46
|
<SwapperImage state={state}>
|
|
@@ -61,7 +61,7 @@ const StepDetailsComponent = forwardRef<HTMLDivElement, StepDetailsProps>(
|
|
|
61
61
|
</Typography>
|
|
62
62
|
</div>
|
|
63
63
|
<div className="step-info">
|
|
64
|
-
<DashedLine invisible={!hasSeparator || type === '
|
|
64
|
+
<DashedLine invisible={!hasSeparator || type === 'swap-progress'} />
|
|
65
65
|
<div className="tokens-container">
|
|
66
66
|
<div className="tokens">
|
|
67
67
|
<ChainToken
|
|
@@ -90,7 +90,7 @@ const StepDetailsComponent = forwardRef<HTMLDivElement, StepDetailsProps>(
|
|
|
90
90
|
step.to.price.value
|
|
91
91
|
} ${step.to.token.displayName}`}</Typography>
|
|
92
92
|
</div>
|
|
93
|
-
<Alerts pb={hasSeparator && type === '
|
|
93
|
+
<Alerts pb={hasSeparator && type === 'quote-details'}>
|
|
94
94
|
{step.alerts}
|
|
95
95
|
</Alerts>
|
|
96
96
|
</div>
|
|
@@ -1,9 +1,24 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
2
|
+
import type { SwapInputProps } from 'src/containers/SwapInput/SwapInput.types';
|
|
3
|
+
|
|
4
|
+
type BaseStep = Pick<SwapInputProps, 'chain' | 'token' | 'price'>;
|
|
5
|
+
|
|
6
|
+
export type Step = {
|
|
7
|
+
swapper: SwapInputProps['chain'];
|
|
8
|
+
from: BaseStep;
|
|
9
|
+
to: BaseStep;
|
|
10
|
+
error?: {
|
|
11
|
+
title?: string;
|
|
12
|
+
description?: string;
|
|
13
|
+
};
|
|
14
|
+
alerts?: ReactNode;
|
|
15
|
+
state?: 'error' | 'warning';
|
|
16
|
+
};
|
|
2
17
|
|
|
3
18
|
export type StepDetailsProps = {
|
|
4
19
|
step: Step;
|
|
5
20
|
hasSeparator: boolean;
|
|
6
|
-
type: '
|
|
21
|
+
type: 'quote-details' | 'swap-progress';
|
|
7
22
|
state?: 'default' | 'in-progress' | 'completed' | 'warning' | 'error';
|
|
8
23
|
isFocused?: boolean;
|
|
9
24
|
tabIndex?: number;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
export { StepDetails } from './StepDetails';
|
|
2
|
-
export type { StepDetailsProps } from './StepDetails.types';
|
|
2
|
+
export type { StepDetailsProps, Step } from './StepDetails.types';
|
|
@@ -8,8 +8,12 @@ export const StyledSwitchRoot = styled(RadixSwitch.Root, {
|
|
|
8
8
|
borderStyle: 'solid',
|
|
9
9
|
width: '24px',
|
|
10
10
|
height: '16px',
|
|
11
|
-
|
|
12
|
-
|
|
11
|
+
$$color: '$colors$neutral600',
|
|
12
|
+
[`.${darkTheme} &`]: {
|
|
13
|
+
$$color: '$colors$neutral700',
|
|
14
|
+
},
|
|
15
|
+
backgroundColor: '$$color',
|
|
16
|
+
borderColor: '$$color',
|
|
13
17
|
borderRadius: '99999px',
|
|
14
18
|
position: 'relative',
|
|
15
19
|
padding: '0',
|
package/src/components/index.ts
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
export * from './I18nManager';
|
|
2
2
|
export * from './Alert';
|
|
3
|
-
export * from './BestRoute';
|
|
4
3
|
export * from './BlockchainsChip';
|
|
5
4
|
export * from './BottomLogo';
|
|
6
5
|
export * from './Button';
|
|
@@ -45,7 +44,7 @@ export * from './ListItem';
|
|
|
45
44
|
export * from './NotFound';
|
|
46
45
|
export * from './MessageBox';
|
|
47
46
|
export * from './IconButton';
|
|
48
|
-
export * from './
|
|
47
|
+
export * from './QuoteCost';
|
|
49
48
|
export * from './TokenAmount';
|
|
50
49
|
export * from './StepDetails';
|
|
51
50
|
export * from './Popover';
|
|
@@ -1,14 +1,16 @@
|
|
|
1
|
+
import type { LoadingStatus } from '../../types/meta';
|
|
2
|
+
import type { CSSProperties } from '@stitches/react';
|
|
3
|
+
import type { BlockchainMeta } from 'rango-sdk';
|
|
4
|
+
|
|
1
5
|
import React from 'react';
|
|
2
|
-
|
|
6
|
+
|
|
7
|
+
import { LoadingFailedAlert } from '../../components/Alert/LoadingFailedAlert';
|
|
8
|
+
import { NotFoundAlert } from '../../components/Alert/NotFoundAlert';
|
|
3
9
|
import { BlockchainsList } from '../../components/BlockchainsList';
|
|
4
10
|
import { SecondaryPage } from '../../components/SecondaryPage/SecondaryPage';
|
|
5
11
|
import { Spinner } from '../../components/Spinner';
|
|
6
12
|
import { styled } from '../../theme';
|
|
7
|
-
import {
|
|
8
|
-
import { containsText } from '../../helper';
|
|
9
|
-
import { LoadingStatus } from '../../types/meta';
|
|
10
|
-
import { LoadingFailedAlert } from '../../components/Alert/LoadingFailedAlert';
|
|
11
|
-
import { NotFoundAlert } from '../../components/Alert/NotFoundAlert';
|
|
13
|
+
import { containsText } from '../../utils';
|
|
12
14
|
import { LoaderContainer } from '../TokenSelector/TokenSelector';
|
|
13
15
|
|
|
14
16
|
const ListContainer = styled('div', {
|
|
@@ -56,8 +58,7 @@ export function BlockchainSelector(props: PropTypes) {
|
|
|
56
58
|
hasHeader={hasHeader}
|
|
57
59
|
textFieldPlaceholder="Search blockchains by name"
|
|
58
60
|
title={`Select ${type} Blockchain`}
|
|
59
|
-
onBack={onBack}
|
|
60
|
-
>
|
|
61
|
+
onBack={onBack}>
|
|
61
62
|
{(searchedFor) => {
|
|
62
63
|
const filteredBlockchains = filterBlockchains(list, searchedFor);
|
|
63
64
|
return (
|
|
@@ -17,6 +17,13 @@ export const Container = styled('div', {
|
|
|
17
17
|
},
|
|
18
18
|
},
|
|
19
19
|
},
|
|
20
|
+
'& .gray-text': {
|
|
21
|
+
$$color: '$colors$neutral600',
|
|
22
|
+
[`.${darkTheme} &`]: {
|
|
23
|
+
$$color: '$colors$neutral700',
|
|
24
|
+
},
|
|
25
|
+
color: '$$color',
|
|
26
|
+
},
|
|
20
27
|
'& .label__container': {
|
|
21
28
|
paddingBottom: '$5',
|
|
22
29
|
},
|
|
@@ -62,3 +69,29 @@ export const MaxButton = styled(Button, {
|
|
|
62
69
|
},
|
|
63
70
|
backgroundColor: '$$color',
|
|
64
71
|
});
|
|
72
|
+
|
|
73
|
+
export const ValueTypography = styled('div', {
|
|
74
|
+
width: 140,
|
|
75
|
+
textAlign: 'right',
|
|
76
|
+
whiteSpace: 'nowrap',
|
|
77
|
+
overflow: 'hidden',
|
|
78
|
+
textOverflow: 'ellipsis',
|
|
79
|
+
variants: {
|
|
80
|
+
hasWarning: {
|
|
81
|
+
true: {
|
|
82
|
+
'& ._typography': {
|
|
83
|
+
color: '$warning500',
|
|
84
|
+
},
|
|
85
|
+
},
|
|
86
|
+
false: {
|
|
87
|
+
'& ._typography': {
|
|
88
|
+
$$color: '$colors$neutral600',
|
|
89
|
+
[`.${darkTheme} &`]: {
|
|
90
|
+
$$color: '$colors$neutral700',
|
|
91
|
+
},
|
|
92
|
+
color: '$$color',
|
|
93
|
+
},
|
|
94
|
+
},
|
|
95
|
+
},
|
|
96
|
+
},
|
|
97
|
+
});
|