@rango-dev/ui 0.1.14-next.0 → 0.1.14-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/CHANGELOG.md +11 -0
- package/dist/components/Alert/Alert.d.ts +7 -7
- package/dist/components/Alert/Alert.stories.d.ts +7 -5
- package/dist/components/Alert/LoadingFailedAlert.d.ts +2 -2
- package/dist/components/Alert/NotFoundAlert.d.ts +7 -7
- package/dist/components/Alert/index.d.ts +2 -2
- package/dist/components/BestRoute/BestRoute.d.ts +15 -12
- package/dist/components/BestRoute/BestRoute.stories.d.ts +10 -8
- package/dist/components/BestRoute/index.d.ts +1 -1
- package/dist/components/BestRoute/mock.d.ts +4 -4
- package/dist/components/BlockchainsList/BlockchainsList.d.ts +10 -10
- package/dist/components/BlockchainsList/BlockchainsList.stories.d.ts +5 -5
- package/dist/components/BlockchainsList/index.d.ts +1 -1
- package/dist/components/BlockchainsList/mockData.d.ts +2 -2
- package/dist/components/Button/Button.d.ts +17 -17
- package/dist/components/Button/Button.stories.d.ts +10 -8
- package/dist/components/Button/index.d.ts +1 -1
- package/dist/components/Checkbox/Checkbox.d.ts +11 -11
- package/dist/components/Checkbox/Checkbox.stories.d.ts +7 -5
- package/dist/components/Checkbox/index.d.ts +1 -1
- package/dist/components/Chip/Chip.d.ts +12 -12
- package/dist/components/Chip/Chip.stories.d.ts +7 -7
- package/dist/components/Chip/index.d.ts +1 -1
- package/dist/components/ColorPicker/ColorPicker.d.ts +9 -9
- package/dist/components/ColorPicker/ColorPicker.stories.d.ts +5 -5
- package/dist/components/ColorPicker/index.d.ts +1 -1
- package/dist/components/Divider/Divider.d.ts +6 -6
- package/dist/components/Divider/index.d.ts +1 -1
- package/dist/components/Drawer/Drawer.d.ts +13 -13
- package/dist/components/Drawer/Drawer.stories.d.ts +8 -8
- package/dist/components/Drawer/index.d.ts +1 -1
- package/dist/components/Header/Header.d.ts +9 -9
- package/dist/components/Header/index.d.ts +1 -1
- package/dist/components/Icon/AddCircleIcon.d.ts +3 -3
- package/dist/components/Icon/AddIcon.d.ts +3 -3
- package/dist/components/Icon/AddWalletIcon.d.ts +3 -3
- package/dist/components/Icon/AngleDownIcon.d.ts +3 -3
- package/dist/components/Icon/AngleLeftIcon.d.ts +3 -3
- package/dist/components/Icon/AngleRightIcon.d.ts +3 -3
- package/dist/components/Icon/AngleUpIcon.d.ts +3 -3
- package/dist/components/Icon/ArrowRightIcon.d.ts +3 -3
- package/dist/components/Icon/BagIcon.d.ts +3 -3
- package/dist/components/Icon/BanIcon.d.ts +3 -3
- package/dist/components/Icon/CheckCircleIcon.d.ts +3 -3
- package/dist/components/Icon/CheckIcon.d.ts +3 -3
- package/dist/components/Icon/CheckSquareIcon.d.ts +3 -3
- package/dist/components/Icon/CheckWalletIcon.d.ts +3 -3
- package/dist/components/Icon/ChevronRightIcon.d.ts +3 -3
- package/dist/components/Icon/CloseIcon.d.ts +112 -1
- package/dist/components/Icon/CopyIcon.d.ts +3 -3
- package/dist/components/Icon/DeleteCircleIcon.d.ts +3 -3
- package/dist/components/Icon/DeleteWalletIcon.d.ts +3 -3
- package/dist/components/Icon/DisconnectIcon.d.ts +3 -3
- package/dist/components/Icon/DownloadIcon.d.ts +3 -3
- package/dist/components/Icon/GasIcon.d.ts +3 -3
- package/dist/components/Icon/HistoryIcon.d.ts +3 -3
- package/dist/components/Icon/HorizontalSwapIcon.d.ts +3 -3
- package/dist/components/Icon/Icons.stories.d.ts +5 -5
- package/dist/components/Icon/InfoCircleIcon.d.ts +3 -3
- package/dist/components/Icon/MinusCircleIcon.d.ts +3 -3
- package/dist/components/Icon/RetryIcon.d.ts +3 -3
- package/dist/components/Icon/RetryLeftIcon.d.ts +3 -3
- package/dist/components/Icon/RetryRightIcon.d.ts +3 -3
- package/dist/components/Icon/SearchIcon.d.ts +3 -3
- package/dist/components/Icon/SearchMinusIcon.d.ts +3 -3
- package/dist/components/Icon/SettingIcon.d.ts +3 -3
- package/dist/components/Icon/SignatureIcon.d.ts +3 -3
- package/dist/components/Icon/SwapWalletIcon.d.ts +3 -3
- package/dist/components/Icon/TimeIcon.d.ts +3 -3
- package/dist/components/Icon/TrashIcon.d.ts +3 -3
- package/dist/components/Icon/TryAgainIcon.d.ts +3 -3
- package/dist/components/Icon/VerticalSwapIcon.d.ts +3 -3
- package/dist/components/Icon/WalletIconIcon.d.ts +3 -3
- package/dist/components/Icon/WarningIcon.d.ts +3 -3
- package/dist/components/Icon/common.d.ts +228 -2
- package/dist/components/Icon/index.d.ts +40 -40
- package/dist/components/Icon/types.d.ts +7 -7
- package/dist/components/LiquiditySourceList/LiquiditySource.stories.d.ts +5 -5
- package/dist/components/LiquiditySourceList/LiquiditySourceList.d.ts +11 -11
- package/dist/components/LiquiditySourceList/index.d.ts +1 -1
- package/dist/components/LiquiditySourceList/mockData.d.ts +2 -2
- package/dist/components/Modal/Modal.d.ts +11 -11
- package/dist/components/Modal/Modal.stories.d.ts +5 -5
- package/dist/components/Modal/index.d.ts +1 -1
- package/dist/components/Radio/Radio.d.ts +13 -13
- package/dist/components/Radio/Radio.stories.d.ts +5 -5
- package/dist/components/Radio/index.d.ts +1 -1
- package/dist/components/SecondaryPage/SecondaryPage.d.ts +16 -16
- package/dist/components/SecondaryPage/SecondaryPage.stories.d.ts +5 -2
- package/dist/components/SecondaryPage/index.d.ts +1 -1
- package/dist/components/SelectableWalletList/SelectableWalletList.d.ts +7 -7
- package/dist/components/SelectableWalletList/SelectableWalletList.stories.d.ts +7 -5
- package/dist/components/SelectableWalletList/index.d.ts +1 -1
- package/dist/components/SelectableWalletList/mock.d.ts +2 -2
- package/dist/components/Skeleton/Skeleton.d.ts +6 -6
- package/dist/components/Skeleton/Skeleton.stories.d.ts +5 -5
- package/dist/components/Skeleton/index.d.ts +1 -1
- package/dist/components/Spinner/Spinner.d.ts +6 -6
- package/dist/components/Spinner/Spinner.stories.d.ts +5 -5
- package/dist/components/Spinner/index.d.ts +1 -1
- package/dist/components/StatusDrawer/StatusDrawer.d.ts +11 -11
- package/dist/components/StatusDrawer/StatusDrawer.stories.d.ts +5 -5
- package/dist/components/StatusDrawer/index.d.ts +1 -1
- package/dist/components/StepDetail/StepDetail.d.ts +12 -12
- package/dist/components/StepDetail/StepDetail.stories.d.ts +7 -5
- package/dist/components/StepDetail/index.d.ts +1 -1
- package/dist/components/SwapContainer/SwapContainer.d.ts +7 -7
- package/dist/components/SwapContainer/index.d.ts +1 -1
- package/dist/components/SwapDetail/SwapDetail.d.ts +8 -8
- package/dist/components/SwapDetail/SwapDetail.stories.d.ts +7 -5
- package/dist/components/SwapDetail/Token.d.ts +17 -17
- package/dist/components/SwapDetail/index.d.ts +1 -1
- package/dist/components/SwapDetail/mock.d.ts +2 -2
- package/dist/components/Switch/Switch.d.ts +6 -6
- package/dist/components/Switch/Switch.stories.d.ts +5 -5
- package/dist/components/Switch/index.d.ts +1 -1
- package/dist/components/TextField/TextField.d.ts +10 -10
- package/dist/components/TextField/TextField.stories.d.ts +7 -7
- package/dist/components/TextField/index.d.ts +1 -1
- package/dist/components/TokenList/TokenItem.d.ts +11 -11
- package/dist/components/TokenList/TokenList.d.ts +17 -17
- package/dist/components/TokenList/TokenList.stories.d.ts +5 -5
- package/dist/components/TokenList/index.d.ts +1 -1
- package/dist/components/TokenList/mockData.d.ts +2 -2
- package/dist/components/Tooltip/Tooltip.d.ts +7 -7
- package/dist/components/Tooltip/Tooltip.stories.d.ts +7 -5
- package/dist/components/Tooltip/index.d.ts +1 -1
- package/dist/components/Typography/Typography.d.ts +18 -18
- package/dist/components/Typography/Typography.stories.d.ts +7 -5
- package/dist/components/Typography/index.d.ts +1 -1
- package/dist/components/VirtualizedList/VirtualizedList.d.ts +17 -17
- package/dist/components/Wallet/State.d.ts +7 -7
- package/dist/components/Wallet/Wallet.d.ts +7 -7
- package/dist/components/Wallet/Wallet.stories.d.ts +7 -5
- package/dist/components/Wallet/index.d.ts +1 -1
- package/dist/components/common/FilledCircle.d.ts +111 -1
- package/dist/components/common/Image.d.ts +6 -6
- package/dist/components/common/index.d.ts +2 -2
- package/dist/components/index.d.ts +25 -31
- package/dist/{components → containers}/BlockchainSelector/BlockchainSelector.d.ts +17 -17
- package/dist/{components → containers}/BlockchainSelector/BlockchainSelector.stories.d.ts +5 -5
- package/dist/containers/ConfirmSwap/ConfirmSwap.d.ts +22 -22
- package/dist/containers/ConfirmSwap/ConfirmSwap.stories.d.ts +8 -6
- package/dist/containers/ConfirmSwap/index.d.ts +1 -1
- package/dist/containers/ConfirmSwap/mock.d.ts +5 -5
- package/dist/{components → containers}/ConnectWalletsModal/ConnectWallets.stories.d.ts +5 -5
- package/dist/{components → containers}/ConnectWalletsModal/ConnectWalletsModal.d.ts +10 -11
- package/dist/{components → containers}/ConnectWalletsModal/mockData.d.ts +2 -2
- package/dist/containers/History/History.d.ts +6 -6
- package/dist/containers/History/History.stories.d.ts +9 -5
- package/dist/containers/History/SwapsGroup.d.ts +13 -13
- package/dist/containers/History/index.d.ts +3 -2
- package/dist/containers/History/mock.d.ts +2 -2
- package/dist/containers/History/types.d.ts +39 -39
- package/dist/{components → containers}/LiquiditySourcesSelector/LiquiditySourcesSelector.d.ts +13 -13
- package/dist/{components → containers}/LiquiditySourcesSelector/LiquiditySourcesSelector.stories.d.ts +5 -5
- package/dist/{components → containers}/Settings/Settings.d.ts +24 -23
- package/dist/{components → containers}/Settings/Settings.stories.d.ts +5 -5
- package/dist/containers/SwapHistory/SwapHistory.d.ts +1128 -24
- package/dist/containers/SwapHistory/SwapHistory.stories.d.ts +14 -5
- package/dist/containers/SwapHistory/SwapMessages.d.ts +17 -17
- package/dist/containers/SwapHistory/index.d.ts +1 -1
- package/dist/containers/SwapHistory/mock.d.ts +2 -2
- package/dist/containers/TokenSelector/TokenSelector.d.ts +124 -0
- package/dist/{components → containers}/TokenSelector/TokenSelector.stories.d.ts +5 -5
- package/dist/containers/index.d.ts +8 -3
- package/dist/helper/index.d.ts +6 -3
- package/dist/hooks/index.d.ts +1 -1
- package/dist/hooks/useCopyToClipboard.d.ts +1 -1
- package/dist/index.d.ts +6 -5
- package/dist/index.js +20 -8
- package/dist/index.js.map +7 -0
- package/dist/theme.d.ts +928 -8
- package/dist/types/index.d.ts +2 -2
- package/dist/types/meta.d.ts +23 -23
- package/dist/types/swaps.d.ts +29 -29
- package/dist/types/wallet.d.ts +23 -23
- package/package.json +21 -40
- package/src/components/Alert/Alert.stories.tsx +19 -6
- package/src/components/Alert/Alert.tsx +5 -5
- package/src/components/BestRoute/BestRoute.stories.tsx +15 -5
- package/src/components/BestRoute/BestRoute.tsx +4 -3
- package/src/components/BestRoute/mock.ts +1 -1
- package/src/components/BlockchainsList/BlockchainsList.stories.tsx +9 -3
- package/src/components/BlockchainsList/mockData.ts +603 -108
- package/src/components/Button/Button.stories.tsx +8 -3
- package/src/components/Button/Button.tsx +42 -42
- package/src/components/Checkbox/Checkbox.stories.tsx +6 -2
- package/src/components/Checkbox/Checkbox.tsx +2 -0
- package/src/components/Chip/Chip.stories.tsx +23 -7
- package/src/components/Chip/Chip.tsx +1 -1
- package/src/components/ColorPicker/ColorPicker.stories.tsx +15 -5
- package/src/components/ColorPicker/ColorPicker.tsx +34 -10
- package/src/components/Divider/Divider.tsx +113 -11
- package/src/components/Drawer/Drawer.stories.tsx +8 -11
- package/src/components/Icon/Icons.stories.tsx +8 -4
- package/src/components/Icon/common.ts +2 -2
- package/src/components/LiquiditySourceList/LiquiditySource.stories.tsx +6 -3
- package/src/components/LiquiditySourceList/LiquiditySourceList.tsx +5 -5
- package/src/components/Modal/Modal.stories.tsx +9 -10
- package/src/components/Modal/Modal.tsx +3 -2
- package/src/components/Radio/Radio.stories.tsx +12 -7
- package/src/components/Radio/Radio.tsx +2 -2
- package/src/components/SecondaryPage/SecondaryPage.stories.tsx +12 -3
- package/src/components/SelectableWalletList/SelectableWalletList.stories.tsx +2 -2
- package/src/components/SelectableWalletList/SelectableWalletList.tsx +5 -5
- package/src/components/Skeleton/Skeleton.stories.tsx +6 -2
- package/src/components/Skeleton/Skeleton.tsx +1 -1
- package/src/components/Spinner/Spinner.stories.tsx +6 -2
- package/src/components/Spinner/Spinner.tsx +1 -1
- package/src/components/StatusDrawer/StatusDrawer.stories.tsx +7 -2
- package/src/components/StatusDrawer/StatusDrawer.tsx +2 -2
- package/src/components/StepDetail/StepDetail.stories.tsx +9 -2
- package/src/components/StepDetail/StepDetail.tsx +4 -4
- package/src/components/SwapContainer/SwapContainer.tsx +3 -3
- package/src/components/SwapDetail/SwapDetail.stories.tsx +5 -2
- package/src/components/SwapDetail/SwapDetail.tsx +4 -4
- package/src/components/SwapDetail/Token.tsx +6 -6
- package/src/components/Switch/Switch.stories.tsx +2 -2
- package/src/components/Switch/Switch.tsx +2 -2
- package/src/components/TextField/TextField.stories.tsx +3 -2
- package/src/components/TextField/TextField.tsx +3 -3
- package/src/components/TokenList/TokenItem.tsx +1 -1
- package/src/components/TokenList/TokenList.stories.tsx +3 -3
- package/src/components/Tooltip/Tooltip.stories.tsx +7 -2
- package/src/components/Tooltip/Tooltip.tsx +2 -2
- package/src/components/Typography/Typography.stories.tsx +2 -2
- package/src/components/Wallet/Wallet.stories.tsx +7 -13
- package/src/components/index.ts +0 -6
- package/src/containers/BlockchainSelector/BlockchainSelector.stories.tsx +41 -0
- package/src/{components → containers}/BlockchainSelector/BlockchainSelector.tsx +5 -5
- package/{dist/components/BlockchainSelector/index.d.ts → src/containers/BlockchainSelector/index.ts} +1 -1
- package/src/containers/ConfirmSwap/ConfirmSwap.stories.tsx +223 -10
- package/src/containers/ConfirmSwap/ConfirmSwap.tsx +25 -16
- package/src/containers/ConnectWalletsModal/ConnectWallets.stories.tsx +24 -0
- package/src/{components → containers}/ConnectWalletsModal/ConnectWalletsModal.tsx +3 -4
- package/{dist/components/ConnectWalletsModal/index.d.ts → src/containers/ConnectWalletsModal/index.ts} +1 -1
- package/src/containers/History/History.stories.tsx +2 -2
- package/src/containers/History/History.tsx +1 -1
- package/src/containers/History/SwapsGroup.tsx +1 -1
- package/src/containers/History/index.ts +2 -1
- package/src/containers/History/mock.ts +3 -3
- package/src/containers/History/types.tsx +1 -1
- package/src/{components → containers}/LiquiditySourcesSelector/LiquiditySourcesSelector.stories.tsx +7 -4
- package/src/{components → containers}/LiquiditySourcesSelector/LiquiditySourcesSelector.tsx +2 -3
- package/{dist/components/LiquiditySourcesSelector/index.d.ts → src/containers/LiquiditySourcesSelector/index.ts} +1 -1
- package/src/containers/Settings/Settings.stories.tsx +27 -0
- package/src/{components → containers}/Settings/Settings.tsx +33 -26
- package/{dist/components/Settings/index.d.ts → src/containers/Settings/index.ts} +1 -1
- package/src/containers/SwapHistory/SwapHistory.stories.tsx +3 -3
- package/src/containers/SwapHistory/SwapHistory.tsx +8 -9
- package/src/containers/SwapHistory/mock.ts +2 -2
- package/src/{components → containers}/TokenSelector/TokenSelector.stories.tsx +7 -8
- package/src/{components → containers}/TokenSelector/TokenSelector.tsx +7 -6
- package/{dist/components/TokenSelector/index.d.ts → src/containers/TokenSelector/index.ts} +1 -1
- package/src/containers/index.ts +5 -0
- package/src/helper/index.ts +75 -0
- package/src/index.ts +1 -0
- package/src/theme.ts +34 -36
- package/src/types/index.ts +1 -1
- package/dist/components/Spacer/Spacer.d.ts +0 -6
- package/dist/components/Spacer/Spacer.stories.d.ts +0 -5
- package/dist/components/Spacer/index.d.ts +0 -1
- package/dist/components/SwapContainer/SwapContainer.stories.d.ts +0 -5
- package/dist/components/TokenSelector/TokenSelector.d.ts +0 -14
- package/dist/ui.cjs.development.js +0 -5094
- package/dist/ui.cjs.development.js.map +0 -1
- package/dist/ui.cjs.production.min.js +0 -2
- package/dist/ui.cjs.production.min.js.map +0 -1
- package/dist/ui.esm.js +0 -5005
- package/dist/ui.esm.js.map +0 -1
- package/src/components/BlockchainSelector/BlockchainSelector.stories.tsx +0 -25
- package/src/components/ConnectWalletsModal/ConnectWallets.stories.tsx +0 -13
- package/src/components/Settings/Settings.stories.tsx +0 -34
- package/src/components/Spacer/Spacer.stories.tsx +0 -31
- package/src/components/Spacer/Spacer.tsx +0 -128
- package/src/components/Spacer/index.ts +0 -1
- package/src/components/SwapContainer/SwapContainer.stories.tsx +0 -13
- /package/{src/components/BlockchainSelector/index.ts → dist/containers/BlockchainSelector/index.d.ts} +0 -0
- /package/{src/components/ConnectWalletsModal/index.ts → dist/containers/ConnectWalletsModal/index.d.ts} +0 -0
- /package/{src/components/LiquiditySourcesSelector/index.ts → dist/containers/LiquiditySourcesSelector/index.d.ts} +0 -0
- /package/{src/components/Settings/index.ts → dist/containers/Settings/index.d.ts} +0 -0
- /package/{src/components/TokenSelector/index.ts → dist/containers/TokenSelector/index.d.ts} +0 -0
- /package/src/{components → containers}/ConnectWalletsModal/mockData.ts +0 -0
|
@@ -1,12 +1,16 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { Icon, IconProps } from './types';
|
|
3
3
|
import * as Icons from '.';
|
|
4
|
-
import {
|
|
4
|
+
import { Meta } from '@storybook/react';
|
|
5
5
|
import { styled } from '../../theme';
|
|
6
6
|
|
|
7
7
|
export default {
|
|
8
8
|
title: 'Components/Icons',
|
|
9
9
|
component: Icons.AngleRightIcon,
|
|
10
|
+
args: {
|
|
11
|
+
size: 16,
|
|
12
|
+
color: 'black',
|
|
13
|
+
},
|
|
10
14
|
argTypes: {
|
|
11
15
|
color: {
|
|
12
16
|
name: 'color',
|
|
@@ -16,12 +20,12 @@ export default {
|
|
|
16
20
|
|
|
17
21
|
size: {
|
|
18
22
|
name: 'size',
|
|
19
|
-
control: { type: '
|
|
23
|
+
control: { type: 'select' },
|
|
20
24
|
options: [16, 18, 20, 24, 28, 32, 36, 40],
|
|
21
25
|
defaultValue: 16,
|
|
22
26
|
},
|
|
23
27
|
},
|
|
24
|
-
} as
|
|
28
|
+
} as Meta<typeof Icons.AngleRightIcon>;
|
|
25
29
|
|
|
26
30
|
const Container = styled('div', {
|
|
27
31
|
display: 'grid',
|
|
@@ -31,7 +35,7 @@ const Container = styled('div', {
|
|
|
31
35
|
|
|
32
36
|
export const Main = (props: IconProps) => (
|
|
33
37
|
<Container>
|
|
34
|
-
{Object.keys(Icons).map(icon => {
|
|
38
|
+
{Object.keys(Icons).map((icon) => {
|
|
35
39
|
const Component = Icons[icon as Icon];
|
|
36
40
|
return (
|
|
37
41
|
<div>
|
|
@@ -33,7 +33,7 @@ export const SvgWithStrokeColor = styled('svg', {
|
|
|
33
33
|
},
|
|
34
34
|
disabled: {
|
|
35
35
|
true: {
|
|
36
|
-
stroke: '$
|
|
36
|
+
stroke: '$neutral400',
|
|
37
37
|
},
|
|
38
38
|
},
|
|
39
39
|
},
|
|
@@ -72,7 +72,7 @@ export const SvgWithFillColor = styled('svg', {
|
|
|
72
72
|
},
|
|
73
73
|
disabled: {
|
|
74
74
|
true: {
|
|
75
|
-
stroke: '$
|
|
75
|
+
stroke: '$neutral400',
|
|
76
76
|
},
|
|
77
77
|
},
|
|
78
78
|
},
|
|
@@ -1,12 +1,15 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { Meta } from '@storybook/react';
|
|
3
3
|
import { LiquiditySourceList, PropTypes } from './LiquiditySourceList';
|
|
4
4
|
import { liquiditySources } from './mockData';
|
|
5
5
|
|
|
6
6
|
export default {
|
|
7
|
-
title: 'Liquidity Source List',
|
|
7
|
+
title: 'Components/Liquidity Source List',
|
|
8
8
|
component: LiquiditySourceList,
|
|
9
|
-
|
|
9
|
+
args: {
|
|
10
|
+
loadingStatus: 'success',
|
|
11
|
+
},
|
|
12
|
+
} as Meta<typeof LiquiditySourceList>;
|
|
10
13
|
|
|
11
14
|
export const Main = (args: PropTypes) => (
|
|
12
15
|
<LiquiditySourceList {...args} list={liquiditySources} />
|
|
@@ -3,7 +3,7 @@ import React, { useEffect, useState } from 'react';
|
|
|
3
3
|
import { styled } from '../../theme';
|
|
4
4
|
import { LiquiditySource, LoadingStatus } from '../../types/meta';
|
|
5
5
|
import { Button } from '../Button/Button';
|
|
6
|
-
import {
|
|
6
|
+
import { Divider } from '../Divider';
|
|
7
7
|
import { Switch } from '../Switch';
|
|
8
8
|
import { Typography } from '../Typography';
|
|
9
9
|
import { Spinner } from '../Spinner';
|
|
@@ -105,13 +105,13 @@ export function LiquiditySourceList(props: PropTypes) {
|
|
|
105
105
|
<div>
|
|
106
106
|
<LiquiditySourceType>
|
|
107
107
|
<Typography variant="h5">Bridges</Typography>
|
|
108
|
-
<Typography variant="body1" color="
|
|
108
|
+
<Typography variant="body1" color="neutral800">
|
|
109
109
|
{totalSelectedBridges === totalBridges
|
|
110
110
|
? totalBridges
|
|
111
111
|
: `${totalSelectedBridges} / ${totalBridges}`}
|
|
112
112
|
</Typography>
|
|
113
113
|
</LiquiditySourceType>
|
|
114
|
-
<
|
|
114
|
+
<Divider size={12} />
|
|
115
115
|
{loadingStatus === 'loading' && (
|
|
116
116
|
<LoaderContainer>
|
|
117
117
|
<Spinner size={24} />
|
|
@@ -138,13 +138,13 @@ export function LiquiditySourceList(props: PropTypes) {
|
|
|
138
138
|
<div>
|
|
139
139
|
<LiquiditySourceType>
|
|
140
140
|
<Typography variant="h5">Exchanges</Typography>
|
|
141
|
-
<Typography variant="body1" color="
|
|
141
|
+
<Typography variant="body1" color="neutral800">
|
|
142
142
|
{totalSelectedExchanges === totalExchanges
|
|
143
143
|
? totalExchanges
|
|
144
144
|
: `${totalSelectedExchanges} / ${totalExchanges}`}
|
|
145
145
|
</Typography>
|
|
146
146
|
</LiquiditySourceType>
|
|
147
|
-
<
|
|
147
|
+
<Divider size={12} />
|
|
148
148
|
{loadingStatus === 'loading' && (
|
|
149
149
|
<LoaderContainer>
|
|
150
150
|
<Spinner size={24} />
|
|
@@ -1,22 +1,21 @@
|
|
|
1
1
|
import React, { useState } from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { Meta } from '@storybook/react';
|
|
3
3
|
import { Modal, PropTypes } from './Modal';
|
|
4
4
|
|
|
5
|
-
export default {
|
|
6
|
-
|
|
7
|
-
|
|
5
|
+
export default {
|
|
6
|
+
name: 'Modal',
|
|
7
|
+
component: Modal,
|
|
8
|
+
args: {
|
|
9
|
+
title: 'I`m a modal',
|
|
10
|
+
},
|
|
11
|
+
} as Meta<typeof Modal>;
|
|
8
12
|
|
|
9
13
|
export const Main = (args: PropTypes) => {
|
|
10
14
|
const [open, setOpen] = useState<boolean>(false);
|
|
11
15
|
return (
|
|
12
16
|
<div>
|
|
13
17
|
<button onClick={() => setOpen(true)}>Open Modal</button>
|
|
14
|
-
<Modal
|
|
15
|
-
{...args}
|
|
16
|
-
open={open}
|
|
17
|
-
title="I'm modal"
|
|
18
|
-
onClose={() => setOpen(false)}
|
|
19
|
-
/>
|
|
18
|
+
<Modal {...args} open={open} onClose={() => setOpen(false)} />
|
|
20
19
|
</div>
|
|
21
20
|
);
|
|
22
21
|
};
|
|
@@ -24,6 +24,8 @@ const BackDrop = styled('div', {
|
|
|
24
24
|
width: '100vw',
|
|
25
25
|
height: '100vh',
|
|
26
26
|
backgroundColor: 'rgba(0,0,0,.1)',
|
|
27
|
+
zIndex: 10,
|
|
28
|
+
|
|
27
29
|
});
|
|
28
30
|
|
|
29
31
|
const ModalContainer = styled('div', {
|
|
@@ -32,8 +34,7 @@ const ModalContainer = styled('div', {
|
|
|
32
34
|
padding: '$16 $16',
|
|
33
35
|
display: 'flex',
|
|
34
36
|
flexDirection: 'column',
|
|
35
|
-
|
|
36
|
-
zIndex: 10,
|
|
37
|
+
zIndex: 20,
|
|
37
38
|
});
|
|
38
39
|
const Row = styled('div', {
|
|
39
40
|
display: 'flex',
|
|
@@ -1,10 +1,19 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { Meta } from '@storybook/react';
|
|
3
3
|
import { PropTypes, Radio } from './Radio';
|
|
4
4
|
|
|
5
5
|
export default {
|
|
6
|
-
title: 'Radio',
|
|
6
|
+
title: 'Components/Radio',
|
|
7
7
|
component: Radio,
|
|
8
|
+
args: {
|
|
9
|
+
options: [
|
|
10
|
+
{ value: 'one', label: 'One' },
|
|
11
|
+
{ value: 'two', label: 'Two' },
|
|
12
|
+
{ value: 'three', label: 'Three' },
|
|
13
|
+
],
|
|
14
|
+
direction: 'horizontal',
|
|
15
|
+
defaultValue: 'one',
|
|
16
|
+
},
|
|
8
17
|
argTypes: {
|
|
9
18
|
options: {
|
|
10
19
|
defaultValue: [
|
|
@@ -13,11 +22,7 @@ export default {
|
|
|
13
22
|
{ value: 'three', label: 'Three' },
|
|
14
23
|
],
|
|
15
24
|
},
|
|
16
|
-
defaultValue: { defaultValue: 'one' },
|
|
17
|
-
direction: {
|
|
18
|
-
defaultValue: 'horizontal',
|
|
19
|
-
},
|
|
20
25
|
},
|
|
21
|
-
} as
|
|
26
|
+
} as Meta<typeof Radio>;
|
|
22
27
|
|
|
23
28
|
export const Main = (args: PropTypes) => <Radio {...args} />;
|
|
@@ -32,10 +32,10 @@ const StyledItem = styled(RadioGroup.Item, {
|
|
|
32
32
|
borderRadius: '100%',
|
|
33
33
|
cursor: 'pointer',
|
|
34
34
|
backgroundColor: '$background',
|
|
35
|
-
border: '1px solid $
|
|
35
|
+
border: '1px solid $neutral400',
|
|
36
36
|
|
|
37
37
|
'&:hover': {
|
|
38
|
-
borderColor: '$
|
|
38
|
+
borderColor: '$neutral600',
|
|
39
39
|
},
|
|
40
40
|
});
|
|
41
41
|
|
|
@@ -1,7 +1,16 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { SecondaryPage } from './SecondaryPage';
|
|
1
|
+
import { Meta } from '@storybook/react';
|
|
2
|
+
import { PropTypes, SecondaryPage } from './SecondaryPage';
|
|
3
|
+
import React from 'react';
|
|
3
4
|
|
|
4
5
|
export default {
|
|
5
6
|
title: 'Components/Secondary Page',
|
|
6
7
|
component: SecondaryPage,
|
|
7
|
-
|
|
8
|
+
args:{
|
|
9
|
+
textField:true,
|
|
10
|
+
textFieldPlaceholder:'Search',
|
|
11
|
+
title:'Secondary Page'
|
|
12
|
+
}
|
|
13
|
+
} as Meta<typeof SecondaryPage>;
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
export const Main = (args: PropTypes) => <SecondaryPage {...args} />;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { Meta } from '@storybook/react';
|
|
3
3
|
|
|
4
4
|
import { SelectableWalletList, PropTypes } from './SelectableWalletList';
|
|
5
5
|
import { data } from './mock';
|
|
@@ -7,7 +7,7 @@ import { data } from './mock';
|
|
|
7
7
|
export default {
|
|
8
8
|
title: 'Components/SelectableWalletList',
|
|
9
9
|
component: SelectableWalletList,
|
|
10
|
-
} as
|
|
10
|
+
} as Meta<typeof SelectableWalletList>;
|
|
11
11
|
|
|
12
12
|
export const Main = (props: PropTypes) => (
|
|
13
13
|
<SelectableWalletList {...props} list={data} />
|
|
@@ -14,7 +14,7 @@ const Circle = styled('div', {
|
|
|
14
14
|
width: 12,
|
|
15
15
|
height: 12,
|
|
16
16
|
borderRadius: 6,
|
|
17
|
-
border: '1px solid $
|
|
17
|
+
border: '1px solid $neutral400',
|
|
18
18
|
position: 'absolute',
|
|
19
19
|
top: 12,
|
|
20
20
|
right: 12,
|
|
@@ -24,7 +24,7 @@ const Circle = styled('div', {
|
|
|
24
24
|
borderColor: '$success',
|
|
25
25
|
},
|
|
26
26
|
false: {
|
|
27
|
-
borderColor: '$
|
|
27
|
+
borderColor: '$neutral400',
|
|
28
28
|
},
|
|
29
29
|
},
|
|
30
30
|
},
|
|
@@ -40,7 +40,7 @@ const SolidCircle = styled('div', {
|
|
|
40
40
|
backgroundColor: '$success',
|
|
41
41
|
},
|
|
42
42
|
false: {
|
|
43
|
-
backgroundColor: '$
|
|
43
|
+
backgroundColor: '$neutral400',
|
|
44
44
|
},
|
|
45
45
|
},
|
|
46
46
|
},
|
|
@@ -65,8 +65,8 @@ const Container = styled('div', {
|
|
|
65
65
|
color: '$success',
|
|
66
66
|
},
|
|
67
67
|
false: {
|
|
68
|
-
borderColor: '$
|
|
69
|
-
color: '$
|
|
68
|
+
borderColor: '$neutral400',
|
|
69
|
+
color: '$neutral400',
|
|
70
70
|
},
|
|
71
71
|
},
|
|
72
72
|
},
|
|
@@ -1,10 +1,14 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Meta } from '@storybook/react';
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import { Skeleton, PropTypes } from './Skeleton';
|
|
4
4
|
|
|
5
5
|
export default {
|
|
6
6
|
title: 'Components/Skeleton',
|
|
7
7
|
component: Skeleton,
|
|
8
|
+
args: {
|
|
9
|
+
width: 20,
|
|
10
|
+
height: 20,
|
|
11
|
+
},
|
|
8
12
|
argTypes: {
|
|
9
13
|
width: {
|
|
10
14
|
name: 'width',
|
|
@@ -19,6 +23,6 @@ export default {
|
|
|
19
23
|
defaultValue: 20,
|
|
20
24
|
},
|
|
21
25
|
},
|
|
22
|
-
} as
|
|
26
|
+
} as Meta<typeof Skeleton>;
|
|
23
27
|
|
|
24
28
|
export const Main = (props: PropTypes) => <Skeleton {...props} />;
|
|
@@ -12,7 +12,7 @@ const waveSquares = keyframes({
|
|
|
12
12
|
|
|
13
13
|
const SkeletonContainer = styled('div', {
|
|
14
14
|
borderRadius: '$5',
|
|
15
|
-
backgroundColor: '$
|
|
15
|
+
backgroundColor: '$neutral100',
|
|
16
16
|
background: `linear-gradient(to right, rgba(130, 130, 130, 0.2) 8%, rgba(130, 130, 130, 0.3) 18%, rgba(130, 130, 130, 0.2) 33%)`,
|
|
17
17
|
backgroundSize: '800px 100px',
|
|
18
18
|
animation: `${waveSquares} 2s infinite ease-out`,
|
|
@@ -1,10 +1,14 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Meta } from '@storybook/react';
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import { Spinner, PropTypes } from './Spinner';
|
|
4
4
|
|
|
5
5
|
export default {
|
|
6
6
|
title: 'Components/Spinner',
|
|
7
7
|
component: Spinner,
|
|
8
|
+
args: {
|
|
9
|
+
color: 'primary',
|
|
10
|
+
size: 16,
|
|
11
|
+
},
|
|
8
12
|
argTypes: {
|
|
9
13
|
color: {
|
|
10
14
|
name: 'color',
|
|
@@ -20,6 +24,6 @@ export default {
|
|
|
20
24
|
defaultValue: 16,
|
|
21
25
|
},
|
|
22
26
|
},
|
|
23
|
-
} as
|
|
27
|
+
} as Meta<typeof Spinner>;
|
|
24
28
|
|
|
25
29
|
export const Main = (props: PropTypes) => <Spinner {...props} />;
|
|
@@ -10,7 +10,7 @@ const spin = keyframes({
|
|
|
10
10
|
const SpinnerContainer = styled('div', {
|
|
11
11
|
borderRadius: '50%',
|
|
12
12
|
position: 'relative',
|
|
13
|
-
border: `2px solid $
|
|
13
|
+
border: `2px solid $neutral100`,
|
|
14
14
|
borderRight: `2px solid`,
|
|
15
15
|
animation: `${spin} 1.5s linear infinite`,
|
|
16
16
|
margin: `0px $8`,
|
|
@@ -1,11 +1,16 @@
|
|
|
1
1
|
import React, { useState } from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { Meta } from '@storybook/react';
|
|
3
3
|
import { StatusDrawer, PropTypes } from './StatusDrawer';
|
|
4
4
|
import { SwapContainer } from '../SwapContainer';
|
|
5
5
|
|
|
6
6
|
export default {
|
|
7
7
|
name: 'Components/StatusDrawer',
|
|
8
8
|
component: StatusDrawer,
|
|
9
|
+
args: {
|
|
10
|
+
status: 'success',
|
|
11
|
+
title: 'Swap successful',
|
|
12
|
+
subtitle: 'There are now 0.0493 BNB in 0x542...C2Df wallet on BSC chain.',
|
|
13
|
+
},
|
|
9
14
|
argTypes: {
|
|
10
15
|
status: {
|
|
11
16
|
name: 'status',
|
|
@@ -25,7 +30,7 @@ export default {
|
|
|
25
30
|
'There are now 0.0493 BNB in 0x542...C2Df wallet on BSC chain.',
|
|
26
31
|
},
|
|
27
32
|
},
|
|
28
|
-
} as
|
|
33
|
+
} as Meta<typeof StatusDrawer>;
|
|
29
34
|
|
|
30
35
|
export const Main = (args: PropTypes) => {
|
|
31
36
|
const [open, setOpen] = useState<boolean>(false);
|
|
@@ -3,7 +3,7 @@ import { styled } from '../../theme';
|
|
|
3
3
|
import { Button } from '../Button';
|
|
4
4
|
import { Drawer } from '../Drawer';
|
|
5
5
|
import { CheckCircleIcon, InfoCircleIcon, WarningIcon } from '../Icon';
|
|
6
|
-
import {
|
|
6
|
+
import { Divider } from '../Divider';
|
|
7
7
|
import { Typography } from '../Typography';
|
|
8
8
|
|
|
9
9
|
export interface PropTypes {
|
|
@@ -60,7 +60,7 @@ export function StatusDrawer({
|
|
|
60
60
|
{status === 'success' ? 'Cancel' : 'See detailes'}
|
|
61
61
|
</Button>
|
|
62
62
|
)}
|
|
63
|
-
<
|
|
63
|
+
<Divider size={16} direction='horizontal' />
|
|
64
64
|
<Button
|
|
65
65
|
fullWidth
|
|
66
66
|
onClick={onSubmit}
|
|
@@ -1,10 +1,17 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { Meta } from '@storybook/react';
|
|
3
3
|
import { StepDetail, PropTypes } from './StepDetail';
|
|
4
4
|
|
|
5
5
|
export default {
|
|
6
6
|
title: 'Components/StepDetail',
|
|
7
7
|
component: StepDetail,
|
|
8
|
+
args: {
|
|
9
|
+
logo: 'https://api.rango.exchange/tokens/COSMOS/JUNO.png',
|
|
10
|
+
chainLogo: 'https://api.rango.exchange/swappers/osmosis.png',
|
|
11
|
+
amount: '1',
|
|
12
|
+
symbol: 'JUNO',
|
|
13
|
+
blockchain: 'OSMOSIS',
|
|
14
|
+
},
|
|
8
15
|
argTypes: {
|
|
9
16
|
logo: {
|
|
10
17
|
name: 'logo',
|
|
@@ -32,6 +39,6 @@ export default {
|
|
|
32
39
|
defaultValue: 'OSMOSIS',
|
|
33
40
|
},
|
|
34
41
|
},
|
|
35
|
-
} as
|
|
42
|
+
} as Meta<typeof StepDetail>;
|
|
36
43
|
|
|
37
44
|
export const Main = (props: PropTypes) => <StepDetail {...props} />;
|
|
@@ -30,7 +30,7 @@ const ChainLogo = styled('div', {
|
|
|
30
30
|
padding: '$2',
|
|
31
31
|
borderRadius: '50%',
|
|
32
32
|
backgroundColor: '$background',
|
|
33
|
-
border: '1px solid $
|
|
33
|
+
border: '1px solid $neutral400',
|
|
34
34
|
|
|
35
35
|
img: {
|
|
36
36
|
width: '100%',
|
|
@@ -74,7 +74,7 @@ const Detail = styled('div', {
|
|
|
74
74
|
},
|
|
75
75
|
});
|
|
76
76
|
const SubTitle = styled(Typography, {
|
|
77
|
-
color: '$
|
|
77
|
+
color: '$neutral600',
|
|
78
78
|
display: 'block',
|
|
79
79
|
paddingLeft: '$8',
|
|
80
80
|
});
|
|
@@ -121,7 +121,7 @@ export function StepDetail(props: PropsWithChildren<PropTypes>) {
|
|
|
121
121
|
<Typography
|
|
122
122
|
noWrap
|
|
123
123
|
variant={direction === 'vertical' ? 'body2' : 'title'}
|
|
124
|
-
color={'$
|
|
124
|
+
color={'$neutral600'}
|
|
125
125
|
>
|
|
126
126
|
{estimatedAmount}
|
|
127
127
|
</Typography>
|
|
@@ -133,7 +133,7 @@ export function StepDetail(props: PropsWithChildren<PropTypes>) {
|
|
|
133
133
|
>
|
|
134
134
|
{symbol}
|
|
135
135
|
</Typography>
|
|
136
|
-
<SubTitle noWrap variant="caption" color="$
|
|
136
|
+
<SubTitle noWrap variant="caption" color="$neutral800">
|
|
137
137
|
on {blockchain}
|
|
138
138
|
</SubTitle>
|
|
139
139
|
</Detail>
|
|
@@ -20,14 +20,14 @@ const MainContainer = styled('div', {
|
|
|
20
20
|
listStyleType: 'none',
|
|
21
21
|
'&::-webkit-scrollbar': { width: '$8', height: '$8' },
|
|
22
22
|
'&::-webkit-scrollbar-thumb': {
|
|
23
|
-
backgroundColor: '$
|
|
23
|
+
backgroundColor: '$neutral400',
|
|
24
24
|
borderRadius: '$10',
|
|
25
25
|
},
|
|
26
26
|
'&::-webkit-scrollbar-thumb:hover': {
|
|
27
|
-
backgroundColor: '$
|
|
27
|
+
backgroundColor: '$neutral500',
|
|
28
28
|
},
|
|
29
29
|
'&::-webkit-scrollbar-track': {
|
|
30
|
-
backgroundColor: '$
|
|
30
|
+
backgroundColor: '$neutral100',
|
|
31
31
|
},
|
|
32
32
|
},
|
|
33
33
|
variants: {
|
|
@@ -1,11 +1,14 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { Meta } from '@storybook/react';
|
|
3
3
|
import { SwapDetail, PropTypes } from './SwapDetail';
|
|
4
4
|
import { swap } from './mock';
|
|
5
5
|
|
|
6
6
|
export default {
|
|
7
7
|
title: 'Components/Swap Detail',
|
|
8
8
|
component: SwapDetail,
|
|
9
|
+
args:{
|
|
10
|
+
status:'running'
|
|
11
|
+
},
|
|
9
12
|
argTypes: {
|
|
10
13
|
status: {
|
|
11
14
|
name: 'status',
|
|
@@ -14,6 +17,6 @@ export default {
|
|
|
14
17
|
defaultValue: 'running',
|
|
15
18
|
},
|
|
16
19
|
},
|
|
17
|
-
} as
|
|
20
|
+
} as Meta<typeof SwapDetail>;
|
|
18
21
|
|
|
19
22
|
export const Main = (props: PropTypes) => <SwapDetail {...props} swap={swap} />;
|
|
@@ -3,7 +3,7 @@ import { PendingSwap } from '../../containers/History/types';
|
|
|
3
3
|
import { styled } from '../../theme';
|
|
4
4
|
import { Button } from '../Button';
|
|
5
5
|
import { ArrowRightIcon } from '../Icon';
|
|
6
|
-
import {
|
|
6
|
+
import { Divider } from '../Divider';
|
|
7
7
|
import { Spinner } from '../Spinner';
|
|
8
8
|
import { Token } from './Token';
|
|
9
9
|
import { limitDecimalPlaces } from '../../helper';
|
|
@@ -14,7 +14,7 @@ const Container = styled('div', {
|
|
|
14
14
|
justifyContent: 'space-between',
|
|
15
15
|
alignItems: 'center',
|
|
16
16
|
padding: '$16 0',
|
|
17
|
-
borderBottom: '1px solid $
|
|
17
|
+
borderBottom: '1px solid $neutral100',
|
|
18
18
|
|
|
19
19
|
'& > .info': {
|
|
20
20
|
display: 'flex',
|
|
@@ -71,9 +71,9 @@ export function SwapDetail({
|
|
|
71
71
|
amount: limitDecimalPlaces(swap.inputAmount),
|
|
72
72
|
}}
|
|
73
73
|
/>
|
|
74
|
-
<
|
|
74
|
+
<Divider size={12} direction="horizontal" />
|
|
75
75
|
<ArrowRightIcon size={12} />
|
|
76
|
-
<
|
|
76
|
+
<Divider size={12} direction="horizontal" />
|
|
77
77
|
<Token
|
|
78
78
|
data={{
|
|
79
79
|
token: {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { styled } from '../../theme';
|
|
3
|
-
import {
|
|
3
|
+
import { Divider } from '../Divider';
|
|
4
4
|
import { Image } from '../common';
|
|
5
5
|
|
|
6
6
|
const TokenContainer = styled('div', {
|
|
@@ -12,13 +12,13 @@ const TokenContainer = styled('div', {
|
|
|
12
12
|
fontWeight: 'bold',
|
|
13
13
|
},
|
|
14
14
|
'& .estimated': {
|
|
15
|
-
color: '$
|
|
15
|
+
color: '$neutral600',
|
|
16
16
|
},
|
|
17
17
|
});
|
|
18
18
|
|
|
19
19
|
const TokenImage = styled('div', {
|
|
20
20
|
position: 'relative',
|
|
21
|
-
|
|
21
|
+
img: {
|
|
22
22
|
borderRadius: '50%',
|
|
23
23
|
},
|
|
24
24
|
'.overlay': {
|
|
@@ -33,7 +33,7 @@ const TokenImage = styled('div', {
|
|
|
33
33
|
justifyContent: 'center',
|
|
34
34
|
alignItems: 'center',
|
|
35
35
|
backgroundColor: '$background',
|
|
36
|
-
border: '1px solid $
|
|
36
|
+
border: '1px solid $neutral400',
|
|
37
37
|
},
|
|
38
38
|
});
|
|
39
39
|
|
|
@@ -63,12 +63,12 @@ export function Token(props: PropTypes) {
|
|
|
63
63
|
<Image src={blockchain.logo} alt={blockchain.name} size={12} />
|
|
64
64
|
</div>
|
|
65
65
|
</TokenImage>
|
|
66
|
-
<
|
|
66
|
+
<Divider size={8} direction="horizontal" />
|
|
67
67
|
{!!amount && <span className="amount">{props.data.amount}</span>}
|
|
68
68
|
{!amount && estimatedAmount && (
|
|
69
69
|
<span className="amount estimated">{props.data.estimatedAmount}</span>
|
|
70
70
|
)}
|
|
71
|
-
<
|
|
71
|
+
<Divider size={4} direction="horizontal" />
|
|
72
72
|
{token.symbol}
|
|
73
73
|
</TokenContainer>
|
|
74
74
|
);
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Meta } from '@storybook/react';
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import { Switch, PropTypes } from './Switch';
|
|
4
4
|
|
|
5
|
-
export default { title: 'Switch', component: Switch } as
|
|
5
|
+
export default { title: 'Components/Switch', component: Switch } as Meta<
|
|
6
6
|
typeof Switch
|
|
7
7
|
>;
|
|
8
8
|
|
|
@@ -9,8 +9,8 @@ const StyledSwitchRoot = styled(RadixSwitch.Root, {
|
|
|
9
9
|
borderStyle: 'solid',
|
|
10
10
|
width: '42px',
|
|
11
11
|
height: '22px',
|
|
12
|
-
backgroundColor: '$
|
|
13
|
-
borderColor: '$
|
|
12
|
+
backgroundColor: '$neutral600',
|
|
13
|
+
borderColor: '$neutral600',
|
|
14
14
|
borderRadius: '99999px',
|
|
15
15
|
position: 'relative',
|
|
16
16
|
padding: '0',
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { Meta } from '@storybook/react';
|
|
3
3
|
|
|
4
4
|
import { TextField, PropTypes } from './TextField';
|
|
5
5
|
import { SearchIcon } from '../Icon';
|
|
@@ -8,6 +8,7 @@ export default {
|
|
|
8
8
|
title: 'Components/Text Field',
|
|
9
9
|
|
|
10
10
|
component: TextField,
|
|
11
|
+
|
|
11
12
|
argTypes: {
|
|
12
13
|
disabled: {
|
|
13
14
|
name: 'disabled',
|
|
@@ -18,7 +19,7 @@ export default {
|
|
|
18
19
|
type: 'string',
|
|
19
20
|
},
|
|
20
21
|
},
|
|
21
|
-
} as
|
|
22
|
+
} as Meta<typeof TextField>;
|
|
22
23
|
|
|
23
24
|
export const Main = (args: PropTypes) => <TextField {...args} />;
|
|
24
25
|
|