@stokr/components-library 3.3.0 → 4.0.0
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/components/AdminDashboard/Table/Table.styles.js +7 -13
- package/dist/components/BasicTable/BasicTable.js +1 -3
- package/dist/components/BlogPost/BlogPost.styles.js +2 -2
- package/dist/components/Button/Button.styles.d.ts +28 -0
- package/dist/components/Button/Button.styles.js +27 -38
- package/dist/components/Button/GlareButton.js +2 -2
- package/dist/components/CardTabs/CardTabs.d.ts +41 -0
- package/dist/components/CardTabs/CardTabs.js +130 -0
- package/dist/components/CardTabs/CardTabs.styles.d.ts +56 -0
- package/dist/components/CardTabs/CardTabs.styles.js +171 -0
- package/dist/components/Chips/Chip.js +32 -8
- package/dist/components/Chips/Chip.styles.js +24 -28
- package/dist/components/Collapsible/Collapsible.d.ts +18 -0
- package/dist/components/Collapsible/Collapsible.js +44 -0
- package/dist/components/Collapsible/Collapsible.styles.d.ts +18 -0
- package/dist/components/Collapsible/Collapsible.styles.js +94 -0
- package/dist/components/ComponentWrapper/ComponentWrapper.styles.d.ts +31 -0
- package/dist/components/ComponentWrapper/ComponentWrapper.styles.js +107 -109
- package/dist/components/Copy/Copy.d.ts +20 -0
- package/dist/components/Copy/Copy.js +0 -9
- package/dist/components/Copy/copySource.d.ts +20 -0
- package/dist/components/Copy/flatten.d.ts +3 -0
- package/dist/components/CopyToClipboardTooltip/CopyToClipboardTooltip.d.ts +15 -0
- package/dist/components/CopyToClipboardTooltip/CopyToClipboardTooltip.styles.d.ts +6 -0
- package/dist/components/CryptoAddress/CryptoAddress.js +3 -3
- package/dist/components/InfoIcon/InfoIcon.d.ts +33 -0
- package/dist/components/InfoIcon/InfoIcon.styles.d.ts +12 -0
- package/dist/components/Input/Input.d.ts +23 -0
- package/dist/components/Input/Input.js +17 -27
- package/dist/components/Input/Input.styles.d.ts +15 -0
- package/dist/components/Input/InputPassword.js +1 -0
- package/dist/components/Input/InputPassword.styles.js +4 -1
- package/dist/components/Input/MultiSelect.js +1 -0
- package/dist/components/Input/RangeInput.js +49 -53
- package/dist/components/Input/Textarea.styles.js +1 -1
- package/dist/components/MaterialIcon/MaterialIcon.d.ts +43 -0
- package/dist/components/MaterialIcon/MaterialIcon.js +56 -0
- package/dist/components/MaterialIcon/MaterialIcon.styles.d.ts +9 -0
- package/dist/components/MaterialIcon/MaterialIcon.styles.js +25 -0
- package/dist/components/MaterialIcon/iconConfig.d.ts +3 -0
- package/dist/components/MaterialIcon/iconConfig.js +11 -0
- package/dist/components/Modal/Modal.d.ts +26 -0
- package/dist/components/Modal/Modal.js +1 -18
- package/dist/components/Modal/Modal.styles.d.ts +59 -0
- package/dist/components/Modal/Modal.styles.js +18 -3
- package/dist/components/Modal/PaymentModal.js +16 -19
- package/dist/components/Modal/SideModal.d.ts +47 -0
- package/dist/components/Modal/SideModal.js +197 -73
- package/dist/components/Modal/SideModal.styles.d.ts +28 -0
- package/dist/components/Modal/SideModal.styles.js +56 -16
- package/dist/components/Modal/SideModalContext.d.ts +12 -0
- package/dist/components/Modal/SideModalContext.js +10 -0
- package/dist/components/Modal/SideModalParts.d.ts +20 -0
- package/dist/components/Modal/SideModalParts.js +95 -0
- package/dist/components/Pagination/Pagination.js +2 -2
- package/dist/components/Pagination/PaginationControls.js +2 -2
- package/dist/components/Payment/TimerComponent.js +1 -2
- package/dist/components/RefreshButton/RefreshButton.styles.js +2 -2
- package/dist/components/RequestDataBox/RequestDataBox.js +2 -2
- package/dist/components/Section/Section.d.ts +32 -0
- package/dist/components/Section/Section.js +80 -0
- package/dist/components/Section/Section.styles.d.ts +34 -0
- package/dist/components/Section/Section.styles.js +143 -0
- package/dist/components/Skeleton/Skeleton.d.ts +44 -0
- package/dist/components/Skeleton/Skeleton.js +48 -0
- package/dist/components/Skeleton/Skeleton.styles.d.ts +14 -0
- package/dist/components/Skeleton/Skeleton.styles.js +51 -0
- package/dist/components/StokrLoader/StokrLoader.d.ts +20 -0
- package/dist/components/StokrLoader/StokrLoader.js +21 -22
- package/dist/components/Tabs/Tabs.styles.js +3 -1
- package/dist/components/TabsNav/TabsNav.js +1 -1
- package/dist/components/TabsNav/TabsNav.styles.js +1 -1
- package/dist/components/Text/Text.styles.d.ts +20 -0
- package/dist/components/Text/Text.styles.js +2 -2
- package/dist/components/TextLink/TextLink.styles.js +1 -2
- package/dist/components/Tooltip/Tooltip.d.ts +42 -0
- package/dist/components/Tooltip/Tooltip.styles.d.ts +10 -0
- package/dist/constants/globalVariables.js +1 -39
- package/dist/hooks/useMediaQuery.d.ts +7 -0
- package/dist/hooks/useMediaQuery.js +19 -0
- package/dist/index.d.ts +299 -0
- package/dist/index.js +97 -211
- package/dist/styles/colors.d.ts +68 -0
- package/dist/styles/colors.js +13 -1
- package/dist/styles/elevation.d.ts +13 -0
- package/dist/styles/elevation.js +15 -0
- package/dist/styles/fonts.js +0 -65
- package/dist/styles/global.js +0 -2
- package/dist/styles/grid.d.ts +27 -0
- package/dist/styles/grid.js +8 -1
- package/dist/styles/rwd.d.ts +48 -0
- package/dist/styles/rwd.js +33 -17
- package/dist/styles/spacing.d.ts +36 -0
- package/dist/styles/spacing.js +30 -0
- package/dist/styles/theme.d.ts +92 -0
- package/dist/styles/theme.js +2 -0
- package/dist/styles/typography.d.ts +42 -0
- package/dist/styles/typography.js +56 -0
- package/dist/utils/capitalize.d.ts +2 -0
- package/dist/utils/capitalize.js +4 -0
- package/dist/utils/copy-text-to-clipboard.d.ts +10 -0
- package/dist/utils/copyToClipboard.d.ts +27 -0
- package/dist/utils/csv.d.ts +14 -0
- package/dist/utils/csv.js +25 -0
- package/dist/utils/customHooks.d.ts +20 -0
- package/dist/utils/customHooks.js +16 -11
- package/dist/utils/fix-decimals.d.ts +14 -0
- package/dist/utils/formatAmount.d.ts +109 -0
- package/dist/utils/formatAmount.js +170 -0
- package/dist/utils/formatCurrencyValue.d.ts +46 -0
- package/dist/utils/formatCurrencyValue.js +6 -21
- package/dist/utils/formatDate.d.ts +19 -0
- package/dist/utils/formatDate.js +44 -0
- package/dist/utils/get-short-address.d.ts +13 -0
- package/dist/utils/get-short-address.js +9 -2
- package/dist/utils/inertProp.d.ts +5 -0
- package/dist/utils/inertProp.js +6 -0
- package/dist/utils/isUSInvestor.d.ts +4 -0
- package/dist/utils/km_ify.d.ts +5 -0
- package/dist/utils/km_ify.js +19 -18
- package/dist/utils/password-validation.d.ts +16 -0
- package/dist/utils/saveAs.d.ts +2 -0
- package/dist/utils/saveAs.js +5 -2
- package/dist/utils/scrollUtils.d.ts +25 -0
- package/dist/utils/scrollUtils.js +13 -10
- package/dist/utils/transition.d.ts +45 -0
- package/dist/utils/transition.js +0 -28
- package/package.json +11 -12
- package/dist/components/AccountBalance/AccountBalance.js +0 -35
- package/dist/components/AccountBalance/AccountBalance.styles.js +0 -48
- package/dist/components/AdminDashboard/Table/Table.js +0 -123
- package/dist/components/ButtonContainer/ButtonContainer.styles.js +0 -51
- package/dist/components/CryptoAddressDetails/CryptoAddressDetails.js +0 -34
- package/dist/components/CryptoAddressDetails/CryptoAddressDetails.styles.js +0 -125
- package/dist/components/DoubleButton/DoubleButton.styles.js +0 -27
- package/dist/components/ErrorMessage/ErrorMessage.styles.js +0 -9
- package/dist/components/Icon/Icon2.js +0 -12
- package/dist/components/Input/InputUsername.js +0 -92
- package/dist/components/Input/RangeInput.styles.js +0 -129
- package/dist/components/InvestmentStat/InvestmentStat.js +0 -24
- package/dist/components/InvestmentStat/InvestmentStat.styles.js +0 -62
- package/dist/components/LatestUpdate/LatestUpdate.js +0 -24
- package/dist/components/LatestUpdate/LatestUpdate.styles.js +0 -90
- package/dist/components/MultiProgressBar/MultiProgressBar.js +0 -28
- package/dist/components/MultiProgressBar/MultiProgressBar.styles.js +0 -105
- package/dist/components/PageTransition/PageTransition.js +0 -51
- package/dist/components/ProfileStat/ProfileStat.js +0 -29
- package/dist/components/ProfileStat/ProfileStat.styles.js +0 -90
- package/dist/components/SEO/SEO.js +0 -66
- package/dist/components/SideLine/SideLine.js +0 -7
- package/dist/components/SideLine/SideLine.styles.js +0 -33
- package/dist/components/Slider/Slider.js +0 -31
- package/dist/components/Slider/Slider.styles.js +0 -120
- package/dist/components/StatusBadge/StatusBadge.styles.js +0 -18
- package/dist/components/StokrLoader/media.js +0 -23
- package/dist/components/SvgIcons/CameraSvg.js +0 -31
- package/dist/components/SvgIcons/DocumentBackSvg.js +0 -20
- package/dist/components/SvgIcons/DocumentSmallSvg.js +0 -41
- package/dist/components/SvgIcons/DocumentSvg.js +0 -39
- package/dist/components/SvgIcons/EthSvg.js +0 -28
- package/dist/components/SvgIcons/EurSvg.js +0 -27
- package/dist/components/SvgIcons/FaceScanIconSvg.js +0 -17
- package/dist/components/SvgIcons/FourSvg.js +0 -7
- package/dist/components/SvgIcons/Glassess.js +0 -26
- package/dist/components/SvgIcons/OneSvg.js +0 -10
- package/dist/components/SvgIcons/PassportSvg.js +0 -37
- package/dist/components/SvgIcons/SocialInstagram.js +0 -13
- package/dist/components/SvgIcons/SocialMedium.js +0 -21
- package/dist/components/SvgIcons/SocialReddit.js +0 -21
- package/dist/components/SvgIcons/SocialYoutube.js +0 -22
- package/dist/components/SvgIcons/ThreeSvg.js +0 -7
- package/dist/components/SvgIcons/TwoSidedDocumentSvg.js +0 -48
- package/dist/components/SvgIcons/TwoSvg.js +0 -10
- package/dist/components/SvgIcons/UpdateDefaultSvg.js +0 -12
- package/dist/components/SvgIcons/UpdateHardSvg.js +0 -10
- package/dist/components/SvgIcons/UpdateSoftSvg.js +0 -11
- package/dist/components/SvgIcons/UploadSvg.js +0 -12
- package/dist/components/TeamOverview/TeamOverview.js +0 -79
- package/dist/components/TeamOverview/TeamOverview.styles.js +0 -167
- package/dist/components/TransactionDetails/TransactionDetails.js +0 -27
- package/dist/components/TransactionDetails/TransactionDetails.styles.js +0 -38
- package/dist/components/TransactionInfo/TransactionInfo.js +0 -41
- package/dist/components/TransactionInfo/TransactionInfo.styles.js +0 -75
- package/dist/components/icons/Arrow.js +0 -38
- package/dist/components/icons/Check.js +0 -16
- package/dist/components/icons/Facebook.js +0 -10
- package/dist/components/icons/Info.js +0 -27
- package/dist/components/icons/Instagram.js +0 -10
- package/dist/components/icons/LinkIcon.js +0 -49
- package/dist/components/icons/LinkedIn.js +0 -13
- package/dist/components/icons/Medium.js +0 -13
- package/dist/components/icons/Reddit.js +0 -16
- package/dist/components/icons/Share.js +0 -31
- package/dist/components/icons/Telegram.js +0 -13
- package/dist/components/icons/Twitter.js +0 -10
- package/dist/components/icons/X.js +0 -10
- package/dist/components/icons/Youtube.js +0 -10
- package/dist/components/icons/index.js +0 -32
- package/dist/components/landing-page/List.js +0 -51
- package/dist/components/landing-page/PageContent.js +0 -65
- package/dist/components/landing-page/PageText.js +0 -171
- package/dist/components/landing-page/PageTitle.js +0 -259
- package/dist/constants/style.js +0 -48
- package/dist/favicon.ico +0 -0
- package/dist/logo192.png +0 -0
- package/dist/logo512.png +0 -0
- package/dist/manifest.json +0 -25
- package/dist/robots.txt +0 -3
- package/dist/static/fonts/OpenSans/OpenSans-Bold.ttf +0 -0
- package/dist/static/fonts/OpenSans/OpenSans-Bold.ttf.js +0 -4
- package/dist/static/fonts/OpenSans/OpenSans-Bold.woff +0 -0
- package/dist/static/fonts/OpenSans/OpenSans-Bold.woff.js +0 -4
- package/dist/static/fonts/OpenSans/OpenSans-Bold.woff2 +0 -0
- package/dist/static/fonts/OpenSans/OpenSans-Bold.woff2.js +0 -4
- package/dist/static/fonts/OpenSans/OpenSans-ExtraBold.ttf +0 -0
- package/dist/static/fonts/OpenSans/OpenSans-ExtraBold.ttf.js +0 -4
- package/dist/static/fonts/OpenSans/OpenSans-ExtraBold.woff +0 -0
- package/dist/static/fonts/OpenSans/OpenSans-ExtraBold.woff.js +0 -4
- package/dist/static/fonts/OpenSans/OpenSans-ExtraBold.woff2 +0 -0
- package/dist/static/fonts/OpenSans/OpenSans-ExtraBold.woff2.js +0 -4
- package/dist/static/fonts/OpenSans/OpenSans-Light.ttf +0 -0
- package/dist/static/fonts/OpenSans/OpenSans-Light.ttf.js +0 -4
- package/dist/static/fonts/OpenSans/OpenSans-Light.woff +0 -0
- package/dist/static/fonts/OpenSans/OpenSans-Light.woff.js +0 -4
- package/dist/static/fonts/OpenSans/OpenSans-Light.woff2 +0 -0
- package/dist/static/fonts/OpenSans/OpenSans-Light.woff2.js +0 -4
- package/dist/static/fonts/OpenSans/OpenSans-Regular.ttf +0 -0
- package/dist/static/fonts/OpenSans/OpenSans-Regular.ttf.js +0 -4
- package/dist/static/fonts/OpenSans/OpenSans-Regular.woff +0 -0
- package/dist/static/fonts/OpenSans/OpenSans-Regular.woff.js +0 -4
- package/dist/static/fonts/OpenSans/OpenSans-Regular.woff2 +0 -0
- package/dist/static/fonts/OpenSans/OpenSans-Regular.woff2.js +0 -4
- package/dist/static/fonts/OpenSans/OpenSans-SemiBold.ttf +0 -0
- package/dist/static/fonts/OpenSans/OpenSans-SemiBold.ttf.js +0 -4
- package/dist/static/fonts/OpenSans/OpenSans-SemiBold.woff +0 -0
- package/dist/static/fonts/OpenSans/OpenSans-SemiBold.woff.js +0 -4
- package/dist/static/fonts/OpenSans/OpenSans-SemiBold.woff2 +0 -0
- package/dist/static/fonts/OpenSans/OpenSans-SemiBold.woff2.js +0 -4
- package/dist/static/images/avatar-placeholder.png.js +0 -4
- package/dist/styles/reactTippy.js +0 -5
- package/dist/styles/semanticUi.js +0 -84
- package/dist/utils/check-sale-time-left.js +0 -85
- package/dist/utils/moment.js +0 -26
|
@@ -1,125 +0,0 @@
|
|
|
1
|
-
import styled from "styled-components";
|
|
2
|
-
import grid from "../../styles/grid.js";
|
|
3
|
-
import rwd from "../../styles/rwd.js";
|
|
4
|
-
import theme from "../../styles/theme.js";
|
|
5
|
-
const Container = styled.div`
|
|
6
|
-
position: relative;
|
|
7
|
-
`;
|
|
8
|
-
const Row = styled.div.withConfig({
|
|
9
|
-
shouldForwardProp: (props) => !["head"].includes(props)
|
|
10
|
-
})`
|
|
11
|
-
background-color: ${() => theme.cPrimaryDark};
|
|
12
|
-
color: ${() => theme.cWhite};
|
|
13
|
-
padding: 22px 32px;
|
|
14
|
-
|
|
15
|
-
${rwd.Medium`
|
|
16
|
-
display: flex;
|
|
17
|
-
flex-direction: row;
|
|
18
|
-
align-items: center;
|
|
19
|
-
padding: 22px ${grid(1.5)};
|
|
20
|
-
`}
|
|
21
|
-
|
|
22
|
-
${(props) => props.head && `
|
|
23
|
-
display: none;
|
|
24
|
-
background-color: ${theme.cPrimary};
|
|
25
|
-
color: #ffffff;
|
|
26
|
-
font-size: 11px;
|
|
27
|
-
line-height: 24px;
|
|
28
|
-
letter-spacing: 2.06px;
|
|
29
|
-
text-transform: uppercase;
|
|
30
|
-
min-height: 56px;
|
|
31
|
-
padding: 10px 32px;
|
|
32
|
-
|
|
33
|
-
${rwd.Medium`
|
|
34
|
-
display: flex;
|
|
35
|
-
padding: 10px ${grid(1.5)};
|
|
36
|
-
`}
|
|
37
|
-
`}
|
|
38
|
-
|
|
39
|
-
&:nth-child(n+3) {
|
|
40
|
-
border-top: 1px solid #003e9d;
|
|
41
|
-
}
|
|
42
|
-
`;
|
|
43
|
-
const Column = styled.div.withConfig({
|
|
44
|
-
shouldForwardProp: (props) => !["balance", "transfer", "tokens", "nameBox", "balanceText"].includes(props)
|
|
45
|
-
})`
|
|
46
|
-
${(props) => props.balance && `
|
|
47
|
-
margin-top: 20px;
|
|
48
|
-
`}
|
|
49
|
-
|
|
50
|
-
${(props) => props.transfer && `
|
|
51
|
-
margin-top: 20px;
|
|
52
|
-
`}
|
|
53
|
-
|
|
54
|
-
${rwd.Medium`
|
|
55
|
-
display: inline-block;
|
|
56
|
-
|
|
57
|
-
${(props) => props.tokens && `
|
|
58
|
-
width: 40%;
|
|
59
|
-
padding-right: 10px;
|
|
60
|
-
`}
|
|
61
|
-
|
|
62
|
-
${(props) => props.balance && `
|
|
63
|
-
width: 30%;
|
|
64
|
-
padding-right: 10px;
|
|
65
|
-
margin-top: 0;
|
|
66
|
-
`}
|
|
67
|
-
|
|
68
|
-
${(props) => props.transfer && `
|
|
69
|
-
width: 30%;
|
|
70
|
-
margin-top: 0;
|
|
71
|
-
`}
|
|
72
|
-
|
|
73
|
-
${(props) => props.nameBox && `
|
|
74
|
-
display: flex;
|
|
75
|
-
`}
|
|
76
|
-
`}
|
|
77
|
-
|
|
78
|
-
${(props) => props.balanceText && `
|
|
79
|
-
font-weight: 300;
|
|
80
|
-
font-size: 22px;
|
|
81
|
-
line-height: 28px;
|
|
82
|
-
letter-spacing: 0.8px;
|
|
83
|
-
text-transform: uppercase;
|
|
84
|
-
`}
|
|
85
|
-
|
|
86
|
-
${(props) => props.nameBox && `
|
|
87
|
-
display: flex;
|
|
88
|
-
flex-direction: row;
|
|
89
|
-
justify-content: flex-start;
|
|
90
|
-
align-items: center;
|
|
91
|
-
`}
|
|
92
|
-
`;
|
|
93
|
-
const Avatar = styled.div`
|
|
94
|
-
display: inline-block;
|
|
95
|
-
width: 48px;
|
|
96
|
-
height: 48px;
|
|
97
|
-
border-radius: 24px;
|
|
98
|
-
background-color: ${() => theme.cPrimary};
|
|
99
|
-
overflow: hidden;
|
|
100
|
-
box-shadow: 0 1px 8px 0 rgba(0, 0, 0, 0.1);
|
|
101
|
-
`;
|
|
102
|
-
const AvatarImg = styled.img`
|
|
103
|
-
display: block;
|
|
104
|
-
width: 100%;
|
|
105
|
-
height: 100%;
|
|
106
|
-
object-fit: cover;
|
|
107
|
-
object-position: center center;
|
|
108
|
-
`;
|
|
109
|
-
const Name = styled.div`
|
|
110
|
-
display: inline-block;
|
|
111
|
-
margin-left: 26px;
|
|
112
|
-
font-weight: 600;
|
|
113
|
-
font-size: 16px;
|
|
114
|
-
line-height: 24px;
|
|
115
|
-
letter-spacing: 0.6px;
|
|
116
|
-
word-break: break-all;
|
|
117
|
-
`;
|
|
118
|
-
export {
|
|
119
|
-
Avatar,
|
|
120
|
-
AvatarImg,
|
|
121
|
-
Column,
|
|
122
|
-
Container,
|
|
123
|
-
Name,
|
|
124
|
-
Row
|
|
125
|
-
};
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
import styled from "styled-components";
|
|
2
|
-
import rwd from "../../styles/rwd.js";
|
|
3
|
-
import stdin_default from "../Button/Button.styles.js";
|
|
4
|
-
const DoubleButtons = styled.div.withConfig({
|
|
5
|
-
shouldForwardProp: (props) => !["column"].includes(props)
|
|
6
|
-
})`
|
|
7
|
-
margin: -12px;
|
|
8
|
-
|
|
9
|
-
${stdin_default} {
|
|
10
|
-
width: 100%;
|
|
11
|
-
margin: 12px;
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
${rwd.Medium`
|
|
15
|
-
display: flex;
|
|
16
|
-
flex-direction: ${({ column }) => column ? "column" : "row"};
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
${stdin_default} {
|
|
20
|
-
width: auto;
|
|
21
|
-
flex: 1;
|
|
22
|
-
}
|
|
23
|
-
`}
|
|
24
|
-
`;
|
|
25
|
-
export {
|
|
26
|
-
DoubleButtons
|
|
27
|
-
};
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { jsx } from "react/jsx-runtime";
|
|
2
|
-
import * as index from "../icons/index.js";
|
|
3
|
-
const Icon2 = ({ name = "IconNotFound", ...p }) => {
|
|
4
|
-
const Ico = index[name];
|
|
5
|
-
if (typeof Ico === "undefined") {
|
|
6
|
-
console.error(`Icon name ${name} not found`);
|
|
7
|
-
}
|
|
8
|
-
return Ico ? /* @__PURE__ */ jsx(Ico, { ...p }) : null;
|
|
9
|
-
};
|
|
10
|
-
export {
|
|
11
|
-
Icon2
|
|
12
|
-
};
|
|
@@ -1,92 +0,0 @@
|
|
|
1
|
-
import { jsxs, jsx } from "react/jsx-runtime";
|
|
2
|
-
import { PureComponent } from "react";
|
|
3
|
-
import PropTypes from "prop-types";
|
|
4
|
-
import { Wrapper, Label, InputWrap } from "./Input.styles.js";
|
|
5
|
-
class InputUsername extends PureComponent {
|
|
6
|
-
state = {
|
|
7
|
-
labelUp: false,
|
|
8
|
-
hasFocus: false
|
|
9
|
-
};
|
|
10
|
-
componentDidMount() {
|
|
11
|
-
this.checkLabel(false);
|
|
12
|
-
}
|
|
13
|
-
componentDidUpdate() {
|
|
14
|
-
this.checkLabel(false);
|
|
15
|
-
}
|
|
16
|
-
onFocus = (e, field) => {
|
|
17
|
-
const { onFocus } = this.props;
|
|
18
|
-
onFocus?.(e, field);
|
|
19
|
-
this.checkLabel(true);
|
|
20
|
-
};
|
|
21
|
-
onBlur = (e, field) => {
|
|
22
|
-
const { onBlur } = this.props;
|
|
23
|
-
onBlur?.(e, field);
|
|
24
|
-
this.checkLabel(false);
|
|
25
|
-
};
|
|
26
|
-
onChange = (e, field) => {
|
|
27
|
-
const { onChange } = this.props;
|
|
28
|
-
onChange?.(e, field);
|
|
29
|
-
};
|
|
30
|
-
checkLabel = (focus) => {
|
|
31
|
-
const { value } = this.props;
|
|
32
|
-
this.setState({
|
|
33
|
-
labelUp: focus || !!value,
|
|
34
|
-
hasFocus: focus
|
|
35
|
-
});
|
|
36
|
-
};
|
|
37
|
-
render() {
|
|
38
|
-
const { labelUp, hasFocus } = this.state;
|
|
39
|
-
const {
|
|
40
|
-
type = "text",
|
|
41
|
-
id,
|
|
42
|
-
name,
|
|
43
|
-
label = "",
|
|
44
|
-
placeholder = "",
|
|
45
|
-
value = "",
|
|
46
|
-
error = false,
|
|
47
|
-
touched = false,
|
|
48
|
-
readOnly = false,
|
|
49
|
-
inverted = false,
|
|
50
|
-
dashboard = false
|
|
51
|
-
} = this.props;
|
|
52
|
-
if (value && !labelUp) {
|
|
53
|
-
this.setState({ labelUp: true });
|
|
54
|
-
}
|
|
55
|
-
return /* @__PURE__ */ jsxs(Wrapper, { inverted, children: [
|
|
56
|
-
label && /* @__PURE__ */ jsx(Label, { isUp: labelUp, active: hasFocus, error: error && touched, htmlFor: id, children: label }),
|
|
57
|
-
/* @__PURE__ */ jsx(InputWrap, { error: error && touched, dashboard, children: /* @__PURE__ */ jsx(
|
|
58
|
-
"input",
|
|
59
|
-
{
|
|
60
|
-
type,
|
|
61
|
-
id,
|
|
62
|
-
name,
|
|
63
|
-
value,
|
|
64
|
-
onChange: this.onChange,
|
|
65
|
-
onBlur: this.onBlur,
|
|
66
|
-
onFocus: this.onFocus,
|
|
67
|
-
readOnly,
|
|
68
|
-
placeholder
|
|
69
|
-
}
|
|
70
|
-
) })
|
|
71
|
-
] });
|
|
72
|
-
}
|
|
73
|
-
}
|
|
74
|
-
InputUsername.propTypes = {
|
|
75
|
-
type: PropTypes.string,
|
|
76
|
-
id: PropTypes.string.isRequired,
|
|
77
|
-
name: PropTypes.string,
|
|
78
|
-
label: PropTypes.string,
|
|
79
|
-
placeholder: PropTypes.string,
|
|
80
|
-
value: PropTypes.string,
|
|
81
|
-
error: PropTypes.bool,
|
|
82
|
-
touched: PropTypes.bool,
|
|
83
|
-
onChange: PropTypes.func,
|
|
84
|
-
onBlur: PropTypes.func,
|
|
85
|
-
onFocus: PropTypes.func,
|
|
86
|
-
readOnly: PropTypes.bool,
|
|
87
|
-
inverted: PropTypes.bool,
|
|
88
|
-
dashboard: PropTypes.bool
|
|
89
|
-
};
|
|
90
|
-
export {
|
|
91
|
-
InputUsername
|
|
92
|
-
};
|
|
@@ -1,129 +0,0 @@
|
|
|
1
|
-
import styled, { css } from "styled-components";
|
|
2
|
-
import theme from "../../styles/theme.js";
|
|
3
|
-
const sliderThumbSize = 26;
|
|
4
|
-
const sliderLineThickness = 8;
|
|
5
|
-
const sliderThumbStyle = css`
|
|
6
|
-
background: ${() => theme.cPrimary};
|
|
7
|
-
border: 4px solid ${() => theme.cWhite};
|
|
8
|
-
height: ${sliderThumbSize}px;
|
|
9
|
-
width: ${sliderThumbSize}px;
|
|
10
|
-
`;
|
|
11
|
-
const sliderDefaultBackground = css`
|
|
12
|
-
background: ${(props) => `linear-gradient(${theme.cPrimary}, ${theme.cPrimary}) 0/ ${props.valuePercent}% 100% no-repeat ${theme.cLightGrey}`};
|
|
13
|
-
`;
|
|
14
|
-
const sliderTrackFocusedStyle = css`
|
|
15
|
-
background: ${(props) => `linear-gradient(${theme.cPrimaryDark}, ${theme.cPrimaryDark}) 0/ ${props.valuePercent}% 100% no-repeat ${theme.cLightGrey}`};
|
|
16
|
-
`;
|
|
17
|
-
const sliderTrackStyle = css`
|
|
18
|
-
/* background: ${() => theme.cLightGrey}; */
|
|
19
|
-
border-radius: ${sliderLineThickness / 2}px;
|
|
20
|
-
height: ${sliderLineThickness}px;
|
|
21
|
-
${sliderDefaultBackground};
|
|
22
|
-
`;
|
|
23
|
-
const sliderThumbFocusedStyle = css`
|
|
24
|
-
border-color: ${() => theme.cLightGrey};
|
|
25
|
-
`;
|
|
26
|
-
const sliderThumbHoverStyle = css`
|
|
27
|
-
background: ${() => theme.cPrimaryDark};
|
|
28
|
-
`;
|
|
29
|
-
const chromeRangeInputStyle = css`
|
|
30
|
-
&::-webkit-slider-thumb {
|
|
31
|
-
margin-top: -${sliderThumbSize / 2 - sliderLineThickness / 2}px;
|
|
32
|
-
${sliderThumbStyle};
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
&:focus::-webkit-slider-thumb {
|
|
36
|
-
${sliderThumbFocusedStyle};
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
&:hover::-webkit-slider-thumb {
|
|
40
|
-
${sliderThumbHoverStyle};
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
&::-webkit-slider-runnable-track {
|
|
44
|
-
${sliderTrackStyle};
|
|
45
|
-
}
|
|
46
|
-
|
|
47
|
-
&:focus::-webkit-slider-runnable-track {
|
|
48
|
-
${sliderDefaultBackground};
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
&:active::-webkit-slider-runnable-track,
|
|
52
|
-
&:hover::-webkit-slider-runnable-track {
|
|
53
|
-
${sliderTrackFocusedStyle};
|
|
54
|
-
}
|
|
55
|
-
`;
|
|
56
|
-
const firefoxRangeInputStyle = css`
|
|
57
|
-
&::-moz-range-thumb {
|
|
58
|
-
${sliderThumbStyle};
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
&:focus::-moz-range-thumb {
|
|
62
|
-
${sliderThumbFocusedStyle};
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
&:hover::-moz-range-thumb {
|
|
66
|
-
${sliderThumbHoverStyle};
|
|
67
|
-
}
|
|
68
|
-
|
|
69
|
-
&::-moz-range-track {
|
|
70
|
-
${sliderTrackStyle};
|
|
71
|
-
}
|
|
72
|
-
|
|
73
|
-
&:focus::-moz-range-track {
|
|
74
|
-
${sliderDefaultBackground};
|
|
75
|
-
}
|
|
76
|
-
|
|
77
|
-
&:active::-moz-range-track,
|
|
78
|
-
&:hover::-moz-range-track {
|
|
79
|
-
${sliderTrackFocusedStyle};
|
|
80
|
-
}
|
|
81
|
-
`;
|
|
82
|
-
const IERangeInputStyle = css`
|
|
83
|
-
&::-ms-thumb {
|
|
84
|
-
${sliderThumbStyle};
|
|
85
|
-
margin-top: -${sliderThumbSize / 2 - sliderLineThickness / 2}px;
|
|
86
|
-
}
|
|
87
|
-
|
|
88
|
-
&:focus::-ms-thumb {
|
|
89
|
-
${sliderThumbFocusedStyle};
|
|
90
|
-
}
|
|
91
|
-
|
|
92
|
-
&:hover::-ms-thumb {
|
|
93
|
-
${sliderThumbHoverStyle};
|
|
94
|
-
}
|
|
95
|
-
|
|
96
|
-
&::-ms-track {
|
|
97
|
-
height: ${sliderLineThickness}px;
|
|
98
|
-
}
|
|
99
|
-
|
|
100
|
-
&::-ms-fill-lower {
|
|
101
|
-
background: ${() => theme.cPrimary};
|
|
102
|
-
border-radius: ${sliderLineThickness / 2}px;
|
|
103
|
-
}
|
|
104
|
-
|
|
105
|
-
&::-ms-fill-upper {
|
|
106
|
-
background: ${() => theme.cLightGrey};
|
|
107
|
-
border-radius: ${sliderLineThickness / 2}px;
|
|
108
|
-
}
|
|
109
|
-
|
|
110
|
-
&:active::-ms-fill-lower,
|
|
111
|
-
&:hover::-ms-fill-lower {
|
|
112
|
-
background: ${() => theme.cPrimaryDark};
|
|
113
|
-
}
|
|
114
|
-
|
|
115
|
-
&:active::-ms-fill-upper,
|
|
116
|
-
&:hover::-ms-fill-upper {
|
|
117
|
-
background: ${() => theme.cLightGrey};
|
|
118
|
-
}
|
|
119
|
-
`;
|
|
120
|
-
const RangeWrapper = styled.div.withConfig({
|
|
121
|
-
shouldForwardProp: (props) => !["valuePercent"].includes(props)
|
|
122
|
-
})`
|
|
123
|
-
input {
|
|
124
|
-
${chromeRangeInputStyle} ${firefoxRangeInputStyle} ${IERangeInputStyle};
|
|
125
|
-
}
|
|
126
|
-
`;
|
|
127
|
-
export {
|
|
128
|
-
RangeWrapper as default
|
|
129
|
-
};
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { jsxs, jsx } from "react/jsx-runtime";
|
|
2
|
-
import "react";
|
|
3
|
-
import PropTypes from "prop-types";
|
|
4
|
-
import { Container, Title, DataContainer, Content } from "./InvestmentStat.styles.js";
|
|
5
|
-
import { InfoIcon } from "../InfoIcon/InfoIcon.js";
|
|
6
|
-
const InvestmentStat = (props) => {
|
|
7
|
-
const { title, content, state = "", primaryBg = false, tooltip } = props;
|
|
8
|
-
return /* @__PURE__ */ jsxs(Container, { primaryBg, ...props, children: [
|
|
9
|
-
/* @__PURE__ */ jsx(Title, { children: title }),
|
|
10
|
-
/* @__PURE__ */ jsxs(DataContainer, { children: [
|
|
11
|
-
/* @__PURE__ */ jsx(Content, { state, children: content }),
|
|
12
|
-
tooltip && /* @__PURE__ */ jsx(InfoIcon, { position: "left", title: tooltip })
|
|
13
|
-
] })
|
|
14
|
-
] });
|
|
15
|
-
};
|
|
16
|
-
InvestmentStat.propTypes = {
|
|
17
|
-
title: PropTypes.string.isRequired,
|
|
18
|
-
content: PropTypes.string.isRequired,
|
|
19
|
-
state: PropTypes.string,
|
|
20
|
-
primaryBg: PropTypes.bool
|
|
21
|
-
};
|
|
22
|
-
export {
|
|
23
|
-
InvestmentStat
|
|
24
|
-
};
|
|
@@ -1,62 +0,0 @@
|
|
|
1
|
-
import styled, { css } from "styled-components";
|
|
2
|
-
import { ComponentWrapper } from "../ComponentWrapper/ComponentWrapper.styles.js";
|
|
3
|
-
import rwd from "../../styles/rwd.js";
|
|
4
|
-
import theme from "../../styles/theme.js";
|
|
5
|
-
const Title = styled.div`
|
|
6
|
-
font-size: 11px;
|
|
7
|
-
line-height: 12px;
|
|
8
|
-
letter-spacing: 2px;
|
|
9
|
-
text-transform: uppercase;
|
|
10
|
-
color: ${() => theme.cBlack};
|
|
11
|
-
white-space: nowrap;
|
|
12
|
-
`;
|
|
13
|
-
const Content = styled.div.withConfig({
|
|
14
|
-
shouldForwardProp: (props) => !["state"].includes(props)
|
|
15
|
-
})`
|
|
16
|
-
margin-top: 8px;
|
|
17
|
-
font-size: 22px;
|
|
18
|
-
line-height: 28px;
|
|
19
|
-
letter-spacing: 0.6px;
|
|
20
|
-
font-weight: 300;
|
|
21
|
-
|
|
22
|
-
${(props) => props.state === "warning" && `
|
|
23
|
-
color: ${theme.cWarning};
|
|
24
|
-
`}
|
|
25
|
-
`;
|
|
26
|
-
const Container = styled(ComponentWrapper).withConfig({
|
|
27
|
-
shouldForwardProp: (props) => !["primaryBg"].includes(props)
|
|
28
|
-
})`
|
|
29
|
-
padding: 40px 20px;
|
|
30
|
-
text-align: center;
|
|
31
|
-
display: flex;
|
|
32
|
-
flex-direction: column;
|
|
33
|
-
align-items: center;
|
|
34
|
-
justify-content: center;
|
|
35
|
-
height: 100%;
|
|
36
|
-
|
|
37
|
-
${rwd.Medium`
|
|
38
|
-
padding: 40px 20px;
|
|
39
|
-
`}
|
|
40
|
-
|
|
41
|
-
${(props) => props.primaryBg && css`
|
|
42
|
-
background: ${theme.cPrimaryDark};
|
|
43
|
-
|
|
44
|
-
${Title} {
|
|
45
|
-
color: ${theme.cWhite};
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
${Content} {
|
|
49
|
-
color: ${theme.cWhite};
|
|
50
|
-
}
|
|
51
|
-
`}
|
|
52
|
-
`;
|
|
53
|
-
const DataContainer = styled.div`
|
|
54
|
-
align-items: center;
|
|
55
|
-
display: flex;
|
|
56
|
-
`;
|
|
57
|
-
export {
|
|
58
|
-
Container,
|
|
59
|
-
Content,
|
|
60
|
-
DataContainer,
|
|
61
|
-
Title
|
|
62
|
-
};
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
|
-
import "react";
|
|
3
|
-
import PropTypes from "prop-types";
|
|
4
|
-
import { Container, ItemLink, ImageWrap, Image, Tag, Title, Text, ReadMore } from "./LatestUpdate.styles.js";
|
|
5
|
-
import { LatestUpdateWrapper } from "./LatestUpdate.styles.js";
|
|
6
|
-
const LatestUpdate = ({ image = "", tag = "", title, text, url, horizontalPadding = false }) => /* @__PURE__ */ jsx(Container, { to: url, horizontalPadding, children: /* @__PURE__ */ jsxs(ItemLink, { to: url, children: [
|
|
7
|
-
image && /* @__PURE__ */ jsx(ImageWrap, { children: /* @__PURE__ */ jsx(Image, { src: image }) }),
|
|
8
|
-
tag && /* @__PURE__ */ jsx(Tag, { children: tag }),
|
|
9
|
-
/* @__PURE__ */ jsx(Title, { children: title }),
|
|
10
|
-
/* @__PURE__ */ jsx(Text, { children: text }),
|
|
11
|
-
/* @__PURE__ */ jsx(ReadMore, { as: "span", children: "read more" })
|
|
12
|
-
] }) });
|
|
13
|
-
LatestUpdate.propTypes = {
|
|
14
|
-
image: PropTypes.string,
|
|
15
|
-
tag: PropTypes.string,
|
|
16
|
-
title: PropTypes.string.isRequired,
|
|
17
|
-
text: PropTypes.string.isRequired,
|
|
18
|
-
url: PropTypes.string.isRequired,
|
|
19
|
-
horizontalPadding: PropTypes.bool
|
|
20
|
-
};
|
|
21
|
-
export {
|
|
22
|
-
LatestUpdate,
|
|
23
|
-
LatestUpdateWrapper
|
|
24
|
-
};
|
|
@@ -1,90 +0,0 @@
|
|
|
1
|
-
import styled from "styled-components";
|
|
2
|
-
import { Link } from "react-router-dom";
|
|
3
|
-
import rwd from "../../styles/rwd.js";
|
|
4
|
-
import { ComponentWrapper } from "../ComponentWrapper/ComponentWrapper.styles.js";
|
|
5
|
-
import { TextLink } from "../TextLink/TextLink.styles.js";
|
|
6
|
-
styled.div`
|
|
7
|
-
font-size: 11px;
|
|
8
|
-
line-height: 24px;
|
|
9
|
-
letter-spacing: 2.06px;
|
|
10
|
-
text-transform: uppercase;
|
|
11
|
-
margin-bottom: 9px;
|
|
12
|
-
`;
|
|
13
|
-
styled.div`
|
|
14
|
-
font-size: 22px;
|
|
15
|
-
font-weight: 900;
|
|
16
|
-
letter-spacing: 0.8px;
|
|
17
|
-
line-height: 28px;
|
|
18
|
-
text-transform: uppercase;
|
|
19
|
-
`;
|
|
20
|
-
const LatestUpdateWrapper = styled(ComponentWrapper)`
|
|
21
|
-
padding: 80px 32px;
|
|
22
|
-
${rwd.Medium`
|
|
23
|
-
padding: 128px 64px;
|
|
24
|
-
`}
|
|
25
|
-
`;
|
|
26
|
-
const Container = styled.div.withConfig({
|
|
27
|
-
shouldForwardProp: (props) => !["horizontalPadding"].includes(props)
|
|
28
|
-
})`
|
|
29
|
-
display: block;
|
|
30
|
-
padding: 20px 0;
|
|
31
|
-
|
|
32
|
-
${rwd.Medium`
|
|
33
|
-
${(props) => props.horizontalPadding && `
|
|
34
|
-
padding: 20px 5%;
|
|
35
|
-
`}
|
|
36
|
-
`}
|
|
37
|
-
`;
|
|
38
|
-
const ItemLink = styled(Link)`
|
|
39
|
-
display: block;
|
|
40
|
-
`;
|
|
41
|
-
const ImageWrap = styled.div`
|
|
42
|
-
display: block;
|
|
43
|
-
height: 42px;
|
|
44
|
-
margin-bottom: 12px;
|
|
45
|
-
`;
|
|
46
|
-
const Image = styled.img`
|
|
47
|
-
display: inline-block;
|
|
48
|
-
max-width: 100%;
|
|
49
|
-
max-height: 100%;
|
|
50
|
-
margin-bottom: 12px;
|
|
51
|
-
object-fit: contain;
|
|
52
|
-
object-position: 0 100%;
|
|
53
|
-
`;
|
|
54
|
-
const Tag = styled.span`
|
|
55
|
-
display: block;
|
|
56
|
-
font-size: 11px;
|
|
57
|
-
line-height: 24px;
|
|
58
|
-
margin-bottom: 12px;
|
|
59
|
-
text-transform: uppercase;
|
|
60
|
-
`;
|
|
61
|
-
const Title = styled.h3`
|
|
62
|
-
display: block;
|
|
63
|
-
font-family: 'Open Sans';
|
|
64
|
-
font-weight: 600;
|
|
65
|
-
font-size: 16px;
|
|
66
|
-
line-height: 24px;
|
|
67
|
-
margin: 0;
|
|
68
|
-
margin-bottom: 20px;
|
|
69
|
-
`;
|
|
70
|
-
const Text = styled.span`
|
|
71
|
-
display: block;
|
|
72
|
-
font-size: 16px;
|
|
73
|
-
font-weight: 300;
|
|
74
|
-
line-height: 24px;
|
|
75
|
-
margin-bottom: 20px;
|
|
76
|
-
`;
|
|
77
|
-
const ReadMore = styled(TextLink)`
|
|
78
|
-
letter-spacing: 2px;
|
|
79
|
-
`;
|
|
80
|
-
export {
|
|
81
|
-
Container,
|
|
82
|
-
Image,
|
|
83
|
-
ImageWrap,
|
|
84
|
-
ItemLink,
|
|
85
|
-
LatestUpdateWrapper,
|
|
86
|
-
ReadMore,
|
|
87
|
-
Tag,
|
|
88
|
-
Text,
|
|
89
|
-
Title
|
|
90
|
-
};
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
import { jsxs, jsx } from "react/jsx-runtime";
|
|
2
|
-
import "react";
|
|
3
|
-
import PropTypes from "prop-types";
|
|
4
|
-
import { Bar, BackBar, BarPart, FillProgress, FillBar } from "./MultiProgressBar.styles.js";
|
|
5
|
-
const MultiProgressBar = ({ backParts, fillParts, fill }) => /* @__PURE__ */ jsxs(Bar, { children: [
|
|
6
|
-
/* @__PURE__ */ jsx(BackBar, { children: backParts?.map((part) => /* @__PURE__ */ jsx(BarPart, { percent: part.value, color: `back-${part.label}` }, part.label)) }),
|
|
7
|
-
/* @__PURE__ */ jsx(FillProgress, { percent: fill, children: /* @__PURE__ */ jsx(FillBar, { percent: fill, children: fillParts?.map((part) => /* @__PURE__ */ jsx(BarPart, { percent: part.value, color: `fill-${part.label}` }, part.label)) }) })
|
|
8
|
-
] });
|
|
9
|
-
const MultiProgressBarPropTypes = {
|
|
10
|
-
backParts: PropTypes.arrayOf(
|
|
11
|
-
PropTypes.shape({
|
|
12
|
-
value: PropTypes.number.isRequired,
|
|
13
|
-
label: PropTypes.string.isRequired
|
|
14
|
-
})
|
|
15
|
-
).isRequired,
|
|
16
|
-
fillParts: PropTypes.arrayOf(
|
|
17
|
-
PropTypes.shape({
|
|
18
|
-
value: PropTypes.number.isRequired,
|
|
19
|
-
label: PropTypes.string.isRequired
|
|
20
|
-
})
|
|
21
|
-
).isRequired,
|
|
22
|
-
fill: PropTypes.number.isRequired
|
|
23
|
-
};
|
|
24
|
-
MultiProgressBar.propTypes = MultiProgressBarPropTypes;
|
|
25
|
-
export {
|
|
26
|
-
MultiProgressBar,
|
|
27
|
-
MultiProgressBarPropTypes
|
|
28
|
-
};
|