@stokr/components-library 3.2.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 -224
- 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 -13
- package/dist/analytics/index.js +0 -185
- 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,123 +0,0 @@
|
|
|
1
|
-
import { jsxs, jsx } from "react/jsx-runtime";
|
|
2
|
-
import { PureComponent } from "react";
|
|
3
|
-
import PropTypes from "prop-types";
|
|
4
|
-
import stdin_default from "../../ComponentScroll/ComponentScroll.js";
|
|
5
|
-
import { Container, HeadWrapper, StyledTable, Head, Row, Column, TableWrapper, Body } from "./Table.styles.js";
|
|
6
|
-
const OptionalScroll = ({ children, maxHeight = 500, noScroll = false, onScroll }) => {
|
|
7
|
-
if (noScroll) {
|
|
8
|
-
return children;
|
|
9
|
-
}
|
|
10
|
-
return /* @__PURE__ */ jsx(
|
|
11
|
-
stdin_default,
|
|
12
|
-
{
|
|
13
|
-
autoHeight: maxHeight !== 0,
|
|
14
|
-
autoHeightMax: maxHeight || void 0,
|
|
15
|
-
offset: 4,
|
|
16
|
-
barPadding: 8,
|
|
17
|
-
topPadding: 48,
|
|
18
|
-
handleScroll: onScroll,
|
|
19
|
-
children
|
|
20
|
-
}
|
|
21
|
-
);
|
|
22
|
-
};
|
|
23
|
-
OptionalScroll.propTypes = {
|
|
24
|
-
children: PropTypes.node.isRequired,
|
|
25
|
-
maxHeight: PropTypes.number.isRequired,
|
|
26
|
-
noScroll: PropTypes.bool.isRequired,
|
|
27
|
-
onScroll: PropTypes.func.isRequired
|
|
28
|
-
};
|
|
29
|
-
class Table extends PureComponent {
|
|
30
|
-
componentDidMount() {
|
|
31
|
-
this.setColumnsWidth();
|
|
32
|
-
window.addEventListener("resize", this.onResize);
|
|
33
|
-
}
|
|
34
|
-
componentWillUnmount() {
|
|
35
|
-
clearTimeout(this.resizeTimeout);
|
|
36
|
-
window.removeEventListener("resize", this.onResize);
|
|
37
|
-
}
|
|
38
|
-
onResize = () => {
|
|
39
|
-
clearTimeout(this.resizeTimeout);
|
|
40
|
-
this.resizeTimeout = setTimeout(this.setColumnsWidth, 200);
|
|
41
|
-
};
|
|
42
|
-
setColumnsWidth = () => {
|
|
43
|
-
const headColumns = this.headTableEl.children[0].children[0].children;
|
|
44
|
-
const bodyColumns = this.bodyTableEl.children[0].children[0].children;
|
|
45
|
-
Array.prototype.forEach.call(bodyColumns, (column, columnKey) => {
|
|
46
|
-
bodyColumns[columnKey].style.width = "";
|
|
47
|
-
});
|
|
48
|
-
this.headTableEl.style.width = "";
|
|
49
|
-
Array.prototype.forEach.call(bodyColumns, (column, columnKey) => {
|
|
50
|
-
headColumns[columnKey].style.width = `${column.offsetWidth}px`;
|
|
51
|
-
bodyColumns[columnKey].style.width = `${column.offsetWidth}px`;
|
|
52
|
-
});
|
|
53
|
-
this.headTableEl.style.width = `${this.bodyTableEl.offsetWidth}px`;
|
|
54
|
-
};
|
|
55
|
-
onScroll = (e) => {
|
|
56
|
-
if (!e) return;
|
|
57
|
-
this.headTableWrapperEl.scrollLeft = e.target.scrollLeft;
|
|
58
|
-
};
|
|
59
|
-
render() {
|
|
60
|
-
const { columns, data, maxHeight, noScroll } = this.props;
|
|
61
|
-
const columnsProps = {};
|
|
62
|
-
columns.map((column) => {
|
|
63
|
-
columnsProps[column.key] = {
|
|
64
|
-
width: column.width,
|
|
65
|
-
align: column.align,
|
|
66
|
-
marginLeft: column.marginLeft
|
|
67
|
-
};
|
|
68
|
-
return column;
|
|
69
|
-
});
|
|
70
|
-
return /* @__PURE__ */ jsxs(Container, { children: [
|
|
71
|
-
/* @__PURE__ */ jsx(
|
|
72
|
-
HeadWrapper,
|
|
73
|
-
{
|
|
74
|
-
ref: (el) => {
|
|
75
|
-
this.headTableWrapperEl = el;
|
|
76
|
-
},
|
|
77
|
-
children: /* @__PURE__ */ jsx(
|
|
78
|
-
StyledTable,
|
|
79
|
-
{
|
|
80
|
-
ref: (el) => {
|
|
81
|
-
this.headTableEl = el;
|
|
82
|
-
},
|
|
83
|
-
children: /* @__PURE__ */ jsx(Head, { children: /* @__PURE__ */ jsx(Row, { children: columns.map((column) => /* @__PURE__ */ jsx(Column, { align: column.align, children: column.label }, column.key)) }) })
|
|
84
|
-
}
|
|
85
|
-
)
|
|
86
|
-
}
|
|
87
|
-
),
|
|
88
|
-
/* @__PURE__ */ jsx(TableWrapper, { children: /* @__PURE__ */ jsx(OptionalScroll, { maxHeight, noScroll, onScroll: this.onScroll, children: /* @__PURE__ */ jsxs(
|
|
89
|
-
StyledTable,
|
|
90
|
-
{
|
|
91
|
-
ref: (el) => {
|
|
92
|
-
this.bodyTableEl = el;
|
|
93
|
-
},
|
|
94
|
-
children: [
|
|
95
|
-
/* @__PURE__ */ jsx(Head, { hidden: true, children: /* @__PURE__ */ jsx(Row, { children: columns.map((column) => /* @__PURE__ */ jsx(
|
|
96
|
-
Column,
|
|
97
|
-
{
|
|
98
|
-
colWidth: column.width,
|
|
99
|
-
minWidth: column.minWidth,
|
|
100
|
-
maxWidth: column.maxWidth,
|
|
101
|
-
align: column.align,
|
|
102
|
-
children: column.label
|
|
103
|
-
},
|
|
104
|
-
column.key
|
|
105
|
-
)) }) }),
|
|
106
|
-
/* @__PURE__ */ jsx(Body, { children: data.map((row) => /* @__PURE__ */ jsx(Row, { children: Object.keys(row).map(
|
|
107
|
-
(columnKey) => columnsProps[columnKey] && /* @__PURE__ */ jsx(Column, { align: columnsProps[columnKey].align, children: row[columnKey] }, columnKey)
|
|
108
|
-
) }, row.id)) })
|
|
109
|
-
]
|
|
110
|
-
}
|
|
111
|
-
) }) })
|
|
112
|
-
] });
|
|
113
|
-
}
|
|
114
|
-
}
|
|
115
|
-
Table.propTypes = {
|
|
116
|
-
columns: PropTypes.arrayOf(Object).isRequired,
|
|
117
|
-
data: PropTypes.arrayOf(Object).isRequired,
|
|
118
|
-
maxHeight: PropTypes.number,
|
|
119
|
-
noScroll: PropTypes.bool
|
|
120
|
-
};
|
|
121
|
-
export {
|
|
122
|
-
Table
|
|
123
|
-
};
|
|
@@ -1,51 +0,0 @@
|
|
|
1
|
-
import styled from "styled-components";
|
|
2
|
-
import stdin_default from "../Button/Button.styles.js";
|
|
3
|
-
const ButtonContainer = styled.div.withConfig({
|
|
4
|
-
shouldForwardProp: (props) => !["flexColumn"].includes(props)
|
|
5
|
-
})`
|
|
6
|
-
align-items: center;
|
|
7
|
-
display: flex;
|
|
8
|
-
justify-content: center;
|
|
9
|
-
${(props) => props.flexColumn && `
|
|
10
|
-
flex-direction:column;
|
|
11
|
-
`}
|
|
12
|
-
|
|
13
|
-
${stdin_default} {
|
|
14
|
-
min-width: 150px;
|
|
15
|
-
max-width: 300px;
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
@media screen and (max-width: 767px) {
|
|
19
|
-
flex-direction: column;
|
|
20
|
-
|
|
21
|
-
${stdin_default} {
|
|
22
|
-
min-width: 150px;
|
|
23
|
-
max-width: 400px;
|
|
24
|
-
}
|
|
25
|
-
}
|
|
26
|
-
`;
|
|
27
|
-
const ButtonGridContainer = styled.div`
|
|
28
|
-
display: grid;
|
|
29
|
-
grid-template-columns: repeat(2, 1fr);
|
|
30
|
-
gap: 10px;
|
|
31
|
-
justify-items: center;
|
|
32
|
-
align-items: center;
|
|
33
|
-
|
|
34
|
-
${stdin_default} {
|
|
35
|
-
min-width: 150px;
|
|
36
|
-
max-width: 300px;
|
|
37
|
-
width: 100%;
|
|
38
|
-
}
|
|
39
|
-
|
|
40
|
-
@media screen and (max-width: 767px) {
|
|
41
|
-
grid-template-columns: repeat(1, 1fr);
|
|
42
|
-
|
|
43
|
-
${stdin_default} {
|
|
44
|
-
max-width: 400px;
|
|
45
|
-
}
|
|
46
|
-
}
|
|
47
|
-
`;
|
|
48
|
-
export {
|
|
49
|
-
ButtonContainer,
|
|
50
|
-
ButtonGridContainer
|
|
51
|
-
};
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
import { jsxs, jsx } from "react/jsx-runtime";
|
|
2
|
-
import "react";
|
|
3
|
-
import PropTypes from "prop-types";
|
|
4
|
-
import stdin_default from "../Button/Button.styles.js";
|
|
5
|
-
import { Container, Row, Column, Avatar, AvatarImg, Name } from "./CryptoAddressDetails.styles.js";
|
|
6
|
-
const CryptoAddressDetails = ({ data }) => /* @__PURE__ */ jsxs(Container, { children: [
|
|
7
|
-
/* @__PURE__ */ jsxs(Row, { head: true, children: [
|
|
8
|
-
/* @__PURE__ */ jsx(Column, { tokens: true, children: "Tokens" }),
|
|
9
|
-
/* @__PURE__ */ jsx(Column, { balance: true, children: "Balance" }),
|
|
10
|
-
/* @__PURE__ */ jsx(Column, { transfer: true })
|
|
11
|
-
] }),
|
|
12
|
-
data.map((datum, index) => /* @__PURE__ */ jsxs(Row, { children: [
|
|
13
|
-
/* @__PURE__ */ jsxs(Column, { tokens: true, nameBox: true, children: [
|
|
14
|
-
/* @__PURE__ */ jsx(Avatar, { children: /* @__PURE__ */ jsx(AvatarImg, { src: datum.avatar, alt: "avatar" }) }),
|
|
15
|
-
/* @__PURE__ */ jsx(Name, { children: datum.name })
|
|
16
|
-
] }),
|
|
17
|
-
/* @__PURE__ */ jsx(Column, { balance: true, balanceText: true, children: datum.balance }),
|
|
18
|
-
/* @__PURE__ */ jsx(Column, { transfer: true, children: /* @__PURE__ */ jsx(stdin_default, { outline: true, fluid: true, onClick: datum.transferClick, children: "Transfer" }) })
|
|
19
|
-
] }, `${datum.id}-${index.toString()}`))
|
|
20
|
-
] });
|
|
21
|
-
CryptoAddressDetails.propTypes = {
|
|
22
|
-
data: PropTypes.arrayOf(
|
|
23
|
-
PropTypes.shape({
|
|
24
|
-
id: PropTypes.number,
|
|
25
|
-
avatar: PropTypes.string,
|
|
26
|
-
name: PropTypes.string,
|
|
27
|
-
balance: PropTypes.string,
|
|
28
|
-
transferClick: PropTypes.func
|
|
29
|
-
})
|
|
30
|
-
).isRequired
|
|
31
|
-
};
|
|
32
|
-
export {
|
|
33
|
-
CryptoAddressDetails
|
|
34
|
-
};
|
|
@@ -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
|
-
};
|