@stokr/components-library 3.0.16 → 3.0.18
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +261 -262
- package/dist/analytics/index.js +180 -0
- package/dist/api/auth.js +15 -0
- package/dist/api/fetchData.js +27 -0
- package/dist/api/fetchDataPublic.js +19 -0
- package/dist/auth/index.js +32 -0
- package/dist/components/2FA/Connect2FA.js +55 -0
- package/dist/components/2FA/EnterCode.js +63 -0
- package/dist/components/2FA/InstallAuthApp.js +64 -0
- package/dist/components/2FA/ResetCode.js +33 -0
- package/dist/components/2FA/Sucess2FA.js +51 -0
- package/dist/components/2FA/disable-2fa-flow.js +91 -0
- package/dist/components/2FA/enable-2fa-flow.js +137 -0
- package/dist/components/2FA/login-with-otp-flow.js +206 -0
- package/dist/components/2FA/main-flow.js +217 -0
- package/dist/components/AccountBalance/AccountBalance.js +35 -0
- package/dist/components/AccountBalance/AccountBalance.styles.js +48 -0
- package/dist/components/AdminDashboard/Table/ReactTable.js +266 -0
- package/dist/components/AdminDashboard/Table/ReactTableWrapper.js +65 -0
- package/dist/components/AdminDashboard/Table/Table.js +123 -0
- package/dist/components/AdminDashboard/Table/Table.styles.js +263 -0
- package/dist/components/AgreementItem/AgreementItem.js +39 -0
- package/dist/components/AgreementItem/AgreementItem.styles.js +32 -0
- package/dist/components/BackButton/BackButton.js +34 -0
- package/dist/components/BackButton/BackButton.styles.js +123 -0
- package/dist/components/Background/Background.js +45 -0
- package/dist/components/Background/Background.styles.js +119 -0
- package/dist/components/BasicTable/BasicTable.js +25 -0
- package/dist/components/BasicTable/BasicTable.styles.js +76 -0
- package/dist/components/BlogPost/BlogPost.js +98 -0
- package/dist/components/BlogPost/BlogPost.styles.js +230 -0
- package/dist/components/Button/Button.styles.js +207 -0
- package/dist/components/ButtonContainer/ButtonContainer.styles.js +51 -0
- package/dist/components/CapitalRaisedSummary/CaptialRaisedSummary.js +18 -0
- package/dist/components/CapitalRaisedSummary/CaptialRaisedSummary.styles.js +41 -0
- package/dist/components/Card/Card.styles.js +97 -0
- package/dist/components/ChartLegend/ChartLegend.js +62 -0
- package/dist/components/ChartLegend/ChartLegend.styles.js +133 -0
- package/dist/components/Checkbox/Checkbox.js +80 -0
- package/dist/components/Checkbox/Checkbox.styles.js +133 -0
- package/dist/components/Checklist/ChecklistCard.js +71 -0
- package/dist/components/Checklist/ChecklistCard.styles.js +82 -0
- package/dist/components/Chips/Chip.js +23 -0
- package/dist/components/Chips/Chip.styles.js +72 -0
- package/dist/components/Chips/ChipWrapper.js +50 -0
- package/dist/components/ComponentScroll/ComponentScroll.js +70 -0
- package/dist/components/ComponentScroll/ComponentScroll.styles.js +127 -0
- package/dist/components/ComponentWrapper/ComponentWrapper.styles.js +165 -0
- package/dist/components/ConfirmModal/ConfirmModal.js +199 -0
- package/dist/components/ConfirmModal/ConfirmModal.styles.js +44 -0
- package/dist/components/CryptoAddress/ComponentWrap.js +16 -0
- package/dist/components/CryptoAddress/CryptoAddress.js +151 -0
- package/dist/components/CryptoAddress/CryptoAddress.styles.js +443 -0
- package/dist/components/CryptoAddress/RadioWrap.js +47 -0
- package/dist/components/CryptoAddressDetails/CryptoAddressDetails.js +34 -0
- package/dist/components/CryptoAddressDetails/CryptoAddressDetails.styles.js +125 -0
- package/dist/components/CryptoAddressWrapper/CryptoAddressWrapper.js +25 -0
- package/dist/components/CryptoAddressWrapper/CryptoAddressWrapper.styles.js +111 -0
- package/dist/components/DoubleButton/DoubleButton.styles.js +27 -0
- package/dist/components/ErrorMessage/ErrorMessage.styles.js +9 -0
- package/dist/components/FAQ/FAQ.js +73 -0
- package/dist/components/FAQ/FAQ.styles.js +128 -0
- package/dist/components/Footer/Footer.js +55 -0
- package/dist/components/Footer/Footer.styles.js +256 -0
- package/dist/components/Footer/FooterLayout.js +145 -0
- package/dist/components/Footer/FooterMenu.js +100 -0
- package/dist/components/Footer/FooterMenu.styles.js +321 -0
- package/dist/components/ForgotPasswordModal/ForgotPasswordModal.js +100 -0
- package/dist/components/Form/Form.js +21 -0
- package/dist/components/Form/Form.styles.js +72 -0
- package/dist/components/Grid/Grid.styles.js +212 -0
- package/dist/components/Header/Header.js +425 -0
- package/dist/components/Header/Header.styles.js +567 -0
- package/dist/components/HeroBlock/HeroVideoBlock.js +105 -0
- package/dist/components/Icon/Icon.style.js +92 -0
- package/dist/components/Icon/Icon2.js +12 -0
- package/dist/components/InfoBox/InfoBox.js +93 -0
- package/dist/components/InfoIcon/InfoIcon.js +62 -0
- package/dist/components/InfoIcon/InfoIcon.styles.js +64 -0
- package/dist/components/Input/DatePickerInput.js +139 -0
- package/dist/components/Input/DatePickerInput.styles.js +165 -0
- package/dist/components/Input/Input.js +108 -0
- package/dist/components/Input/Input.styles.js +154 -0
- package/dist/components/Input/InputPassword.js +122 -0
- package/dist/components/Input/InputPassword.styles.js +166 -0
- package/dist/components/Input/InputUsername.js +92 -0
- package/dist/components/Input/InputWithButton.js +53 -0
- package/dist/components/Input/InputWithButton.styles.js +57 -0
- package/dist/components/Input/MultiSelect.js +306 -0
- package/dist/components/Input/OtpInput.js +70 -0
- package/dist/components/Input/RangeInput.js +80 -0
- package/dist/components/Input/RangeInput.styles.js +129 -0
- package/dist/components/Input/SearchInput.js +68 -0
- package/dist/components/Input/SearchInput.styles.js +92 -0
- package/dist/components/Input/Select.js +151 -0
- package/dist/components/Input/Select.styles.js +148 -0
- package/dist/components/Input/TableFilterDropdown.js +247 -0
- package/dist/components/Input/Textarea.js +51 -0
- package/dist/components/Input/Textarea.styles.js +62 -0
- package/dist/components/InvestCalculator/InvestCalculator.js +283 -0
- package/dist/components/InvestCalculator/InvestCalculator.styles.js +94 -0
- package/dist/components/InvestmentStat/InvestmentStat.js +24 -0
- package/dist/components/InvestmentStat/InvestmentStat.styles.js +62 -0
- package/dist/components/LatestUpdate/LatestUpdate.js +24 -0
- package/dist/components/LatestUpdate/LatestUpdate.styles.js +90 -0
- package/dist/components/Layout/Layout.js +69 -0
- package/dist/components/LearnMoreCarousel/LearnMoreCarousel.js +32 -0
- package/dist/components/LearnMoreCarousel/LearnMoreCarousel.styles.js +208 -0
- package/dist/components/LearnMorePage/LearnMore.js +190 -0
- package/dist/components/LearnMorePage/LearnMore.propTypes.js +20 -0
- package/dist/components/LearnMorePage/LearnMore.shared.styles.js +56 -0
- package/dist/components/LearnMorePage/LearnMore.styles.js +276 -0
- package/dist/components/LearnMorePage/LearnMoreExampleObject.js +120 -0
- package/dist/components/LearnMorePage/LearnMoreItem.js +57 -0
- package/dist/components/LearnMorePage/LearnMoreItem.styles.js +234 -0
- package/dist/components/LearnMoreSection/LearnMore.js +138 -0
- package/dist/components/LearnMoreSection/LearnMore.styles.js +147 -0
- package/dist/components/LearnMoreSection/LearnMoreItem.js +33 -0
- package/dist/components/LearnMoreSection/LearnMoreItem.styles.js +60 -0
- package/dist/components/LoginModal/LoginModal.js +142 -0
- package/dist/components/MainMenu/DynamicMainMenu.js +38 -0
- package/dist/components/MainMenu/MainMenu.js +210 -0
- package/dist/components/MainMenu/MainMenu.styles.js +362 -0
- package/dist/components/MenuNav/MenuNav.styles.js +66 -0
- package/dist/components/Modal/Modal.js +119 -0
- package/dist/components/Modal/Modal.styles.js +450 -0
- package/dist/components/Modal/NewVentureModal/NewVentureModal.js +262 -0
- package/dist/components/Modal/PaymentModal.js +149 -0
- package/dist/components/Modal/SideModal.js +134 -0
- package/dist/components/Modal/SideModal.styles.js +55 -0
- package/dist/components/Modal/SuccessModal/SuccessModal.js +170 -0
- package/dist/components/Modal/SuccessModal/SuccessModal.styles.js +53 -0
- package/dist/components/MultiProgressBar/MultiProgressBar.js +30 -0
- package/dist/components/MultiProgressBar/MultiProgressBar.styles.js +105 -0
- package/dist/components/Newsletter/Newsletter.js +122 -0
- package/dist/components/Newsletter/Newsletter.styles.js +186 -0
- package/dist/components/NotificationCounter/NotificationCounter.styles.js +38 -0
- package/dist/components/Number/Number.js +50 -0
- package/dist/components/Number/Number.styles.js +23 -0
- package/dist/components/PageTransition/PageTransition.js +51 -0
- package/dist/components/Pagination/Pagination.js +58 -0
- package/dist/components/Pagination/Pagination.styles.js +59 -0
- package/dist/components/Pagination/PaginationControls.js +113 -0
- package/dist/components/Pagination/usePagination.js +40 -0
- package/dist/components/Payment/PaymentDetailsCard.js +359 -0
- package/dist/components/Payment/PaymentDisplay.js +199 -0
- package/dist/components/Payment/TimerComponent.js +92 -0
- package/dist/components/Process/Process.styles.js +84 -0
- package/dist/components/ProfileBadge/ProfileBadge.js +35 -0
- package/dist/components/ProfileBadge/ProfileBadge.styles.js +53 -0
- package/dist/components/ProfileBox/ProfileBox.js +27 -0
- package/dist/components/ProfileBox/ProfileBox.styles.js +67 -0
- package/dist/components/ProfileStat/ProfileStat.js +29 -0
- package/dist/components/ProfileStat/ProfileStat.styles.js +90 -0
- package/dist/components/QRCode/QRCode.js +51 -0
- package/dist/components/Radio/Radio.js +51 -0
- package/dist/components/Radio/Radio.styles.js +100 -0
- package/dist/components/RefreshButton/RefreshButton.js +21 -0
- package/dist/components/RefreshButton/RefreshButton.styles.js +64 -0
- package/dist/components/RegisterConfirmModal/RegisterConfirmModal.js +65 -0
- package/dist/components/RegisterConfirmModal/RegisterConfirmModal.styles.js +20 -0
- package/dist/components/RegisterModal/RegisterModal.js +248 -0
- package/dist/components/RequestDataBox/RequestDataBox.js +21 -0
- package/dist/components/RequestDataBox/RequestDataBox.styles.js +43 -0
- package/dist/components/ResetConfirmModal/ResetConfirmModal.js +44 -0
- package/dist/components/ResetConfirmModal/ResetConfirmModal.styles.js +41 -0
- package/dist/components/ResetPasswordModal/ResetPasswordModal.js +134 -0
- package/dist/components/SEO/SEO.js +66 -0
- package/dist/components/SectionTitle/SectionTitle.styles.js +26 -0
- package/dist/components/SideLine/SideLine.js +7 -0
- package/dist/components/SideLine/SideLine.styles.js +33 -0
- package/dist/components/Slider/Slider.js +31 -0
- package/dist/components/Slider/Slider.styles.js +120 -0
- package/dist/components/Snackbar/Snackbar.js +111 -0
- package/dist/components/Snackbar/Snackbar.styles.js +230 -0
- package/dist/components/Snackbar/SnackbarProvider.js +66 -0
- package/dist/components/Snackbar/useSnackbar.js +12 -0
- package/dist/components/SpanButton/SpanButton.styles.js +19 -0
- package/dist/components/StatusBadge/StatusBadge.styles.js +18 -0
- package/dist/components/StatusTag/StatusTag.js +105 -0
- package/dist/components/StatusTag/StatusTag.styles.js +88 -0
- package/dist/components/StepController/StepController.js +86 -0
- package/dist/components/StepController/StepController.styles.js +33 -0
- package/dist/components/StepController/StepControllerContext.js +65 -0
- package/dist/components/StepController/StepControllerProgress.js +37 -0
- package/dist/components/StepsProgress/StepIndicator.js +40 -0
- package/dist/components/StepsProgress/StepIndicator.styles.js +69 -0
- package/dist/components/StepsProgress/StepsProgress.js +67 -0
- package/dist/components/StepsProgress/StepsProgress.styles.js +105 -0
- package/dist/components/StokrLoader/StokrLoader.js +111 -0
- package/dist/components/StokrLoader/media.js +23 -0
- package/dist/components/SvgIcons/AdminBadgeSvg.js +27 -0
- package/dist/components/SvgIcons/CameraSvg.js +31 -0
- package/dist/components/SvgIcons/CapsLockSvg.js +36 -0
- package/dist/components/SvgIcons/DocumentBackSvg.js +20 -0
- package/dist/components/SvgIcons/DocumentSmallSvg.js +41 -0
- package/dist/components/SvgIcons/DocumentSvg.js +39 -0
- package/dist/components/SvgIcons/EthSvg.js +28 -0
- package/dist/components/SvgIcons/EurSvg.js +27 -0
- package/dist/components/SvgIcons/FaceScanIconSvg.js +17 -0
- package/dist/components/SvgIcons/FourSvg.js +7 -0
- package/dist/components/SvgIcons/Glassess.js +26 -0
- package/dist/components/SvgIcons/LogoSvg.js +17 -0
- package/dist/components/SvgIcons/OneSvg.js +10 -0
- package/dist/components/SvgIcons/PassportSvg.js +37 -0
- package/dist/components/SvgIcons/RefreshSvg.js +28 -0
- package/dist/components/SvgIcons/SocialFacebook.js +22 -0
- package/dist/components/SvgIcons/SocialInstagram.js +13 -0
- package/dist/components/SvgIcons/SocialLinkedIn.js +31 -0
- package/dist/components/SvgIcons/SocialMedium.js +21 -0
- package/dist/components/SvgIcons/SocialReddit.js +21 -0
- package/dist/components/SvgIcons/SocialTelegram.js +60 -0
- package/dist/components/SvgIcons/SocialTwitter.js +62 -0
- package/dist/components/SvgIcons/SocialYoutube.js +22 -0
- package/dist/components/SvgIcons/ThreeSvg.js +7 -0
- package/dist/components/SvgIcons/TwoSidedDocumentSvg.js +48 -0
- package/dist/components/SvgIcons/TwoSvg.js +10 -0
- package/dist/components/SvgIcons/UpdateDefaultSvg.js +12 -0
- package/dist/components/SvgIcons/UpdateHardSvg.js +10 -0
- package/dist/components/SvgIcons/UpdateSoftSvg.js +11 -0
- package/dist/components/SvgIcons/UploadSvg.js +12 -0
- package/dist/components/SvgIcons/VerifiedBadge.js +16 -0
- package/dist/components/Switch/Switch.js +63 -0
- package/dist/components/Switch/Switch.styles.js +126 -0
- package/dist/components/Tabs/Tabs.js +54 -0
- package/dist/components/Tabs/Tabs.styles.js +15 -0
- package/dist/components/TabsNav/TabNav.js +16 -0
- package/dist/components/TabsNav/TabsNav.js +30 -0
- package/dist/components/TabsNav/TabsNav.styles.js +103 -0
- package/dist/components/TeamOverview/TeamOverview.js +80 -0
- package/dist/components/TeamOverview/TeamOverview.styles.js +167 -0
- package/dist/components/TermsModal/TermsModal.js +145 -0
- package/dist/components/TermsModal/_styles.js +313 -0
- package/dist/components/Text/Text.styles.js +220 -0
- package/dist/components/TextLink/TextLink.styles.js +67 -0
- package/dist/components/Timeline/Timeline.js +44 -0
- package/dist/components/Timeline/Timeline.styles.js +147 -0
- package/dist/components/Timeline/TimelineStep.js +58 -0
- package/dist/components/ToDoList/ToDoList.js +172 -0
- package/dist/components/ToDoList/ToDoList.styles.js +122 -0
- package/dist/components/ToDoList/ToDoListTask.js +95 -0
- package/dist/components/ToDoList/ToDoListTask.styles.js +119 -0
- package/dist/components/TransactionDetails/TransactionDetails.js +27 -0
- package/dist/components/TransactionDetails/TransactionDetails.styles.js +38 -0
- package/dist/components/TransactionInfo/TransactionInfo.js +41 -0
- package/dist/components/TransactionInfo/TransactionInfo.styles.js +75 -0
- package/dist/components/VerifyEmailModal/VerifyEmailModal.js +122 -0
- package/dist/components/breakdown/Breakdown.js +126 -0
- package/dist/components/headerHo/HeaderHo.js +709 -0
- package/dist/components/icons/Arrow.js +38 -0
- package/dist/components/icons/ArrowSimple.js +34 -0
- package/dist/components/icons/Check.js +16 -0
- package/dist/components/icons/Facebook.js +10 -0
- package/dist/components/icons/Info.js +27 -0
- package/dist/components/icons/Instagram.js +10 -0
- package/dist/components/icons/LinkIcon.js +49 -0
- package/dist/components/icons/LinkedIn.js +13 -0
- package/dist/components/icons/Medium.js +13 -0
- package/dist/components/icons/Reddit.js +16 -0
- package/dist/components/icons/Share.js +31 -0
- package/dist/components/icons/Telegram.js +13 -0
- package/dist/components/icons/Twitter.js +10 -0
- package/dist/components/icons/X.js +10 -0
- package/dist/components/icons/Youtube.js +10 -0
- package/dist/components/icons/index.js +32 -0
- package/dist/components/landing-page/List.js +51 -0
- package/dist/components/landing-page/PageContent.js +65 -0
- package/dist/components/landing-page/PageText.js +171 -0
- package/dist/components/landing-page/PageTitle.js +259 -0
- package/dist/components/logo/Logo.js +57 -0
- package/dist/components/taxId/complete.js +24 -0
- package/dist/components/taxId/flow.js +53 -0
- package/dist/components/taxId/register-taxid.js +166 -0
- package/dist/config.js +44 -0
- package/dist/constants/globalVariables.js +87 -0
- package/dist/constants/style.js +48 -0
- package/dist/context/Auth.js +396 -0
- package/dist/context/AuthContext.js +781 -0
- package/dist/context/Checkbox/CheckboxContext.js +151 -0
- package/dist/firebase-config.js +73 -0
- package/dist/hooks/useNewVentureForm.js +262 -0
- package/dist/hooks/useTimer.js +89 -0
- package/dist/hooks/useTransactionPolling.js +100 -0
- package/dist/index.js +632 -25463
- package/dist/model/axios.js +10 -0
- package/dist/model/axiosPublic.js +9 -0
- package/dist/services/TimerService.js +80 -0
- package/dist/static/animations/checked.lottie.js +4 -0
- package/dist/static/animations/progress.lottie.js +4 -0
- package/dist/static/fonts/Ionicons/Ionicons.ttf.js +4 -0
- package/dist/static/fonts/Ionicons/Ionicons.woff.js +4 -0
- package/dist/static/fonts/Ionicons/Ionicons.woff2.js +4 -0
- package/dist/static/fonts/Ionicons/ionicons.min.css.js +4 -0
- package/dist/static/fonts/OpenSans/OpenSans-Bold.ttf.js +4 -0
- package/dist/static/fonts/OpenSans/OpenSans-Bold.woff.js +4 -0
- package/dist/static/fonts/OpenSans/OpenSans-Bold.woff2.js +4 -0
- package/dist/static/fonts/OpenSans/OpenSans-ExtraBold.ttf.js +4 -0
- package/dist/static/fonts/OpenSans/OpenSans-ExtraBold.woff.js +4 -0
- package/dist/static/fonts/OpenSans/OpenSans-ExtraBold.woff2.js +4 -0
- package/dist/static/fonts/OpenSans/OpenSans-Light.ttf.js +4 -0
- package/dist/static/fonts/OpenSans/OpenSans-Light.woff.js +4 -0
- package/dist/static/fonts/OpenSans/OpenSans-Light.woff2.js +4 -0
- package/dist/static/fonts/OpenSans/OpenSans-Regular.ttf.js +4 -0
- package/dist/static/fonts/OpenSans/OpenSans-Regular.woff.js +4 -0
- package/dist/static/fonts/OpenSans/OpenSans-Regular.woff2.js +4 -0
- package/dist/static/fonts/OpenSans/OpenSans-SemiBold.ttf.js +4 -0
- package/dist/static/fonts/OpenSans/OpenSans-SemiBold.woff.js +4 -0
- package/dist/static/fonts/OpenSans/OpenSans-SemiBold.woff2.js +4 -0
- package/dist/static/fonts/icomoon/icomoon.eot.js +4 -0
- package/dist/static/fonts/icomoon/icomoon.svg.js +4 -0
- package/dist/static/fonts/icomoon/icomoon.ttf.js +4 -0
- package/dist/static/fonts/icomoon/icomoon.woff.js +4 -0
- package/dist/static/images/add-folder-icon.svg.js +5 -0
- package/dist/static/images/address-refreshing.gif.js +4 -0
- package/dist/static/images/arrow-down-black.svg.js +4 -0
- package/dist/static/images/avatar-placeholder.png.js +4 -0
- package/dist/static/images/background3.png.js +4 -0
- package/dist/static/images/bitcoin-logo.svg.js +4 -0
- package/dist/static/images/bmn2-logo.svg.js +4 -0
- package/dist/static/images/check-icon.svg.js +5 -0
- package/dist/static/images/checkmark-circle-icon.svg.js +5 -0
- package/dist/static/images/close-circle-icon.svg.js +5 -0
- package/dist/static/images/copy_icon.svg.js +5 -0
- package/dist/static/images/cross-icon.svg.js +5 -0
- package/dist/static/images/early-adopter.png.js +4 -0
- package/dist/static/images/eth_logo.svg.js +4 -0
- package/dist/static/images/external-link-icon.svg +3 -0
- package/dist/static/images/external-link-icon.svg.js +4 -0
- package/dist/static/images/filter-icon.svg.js +5 -0
- package/dist/static/images/google_auth.png.js +4 -0
- package/dist/static/images/graduation.png.js +4 -0
- package/dist/static/images/mangopay.svg.js +4 -0
- package/dist/static/images/numbers/number_eight.svg.js +5 -0
- package/dist/static/images/numbers/number_five.svg.js +5 -0
- package/dist/static/images/numbers/number_four.svg.js +5 -0
- package/dist/static/images/numbers/number_nine.svg.js +5 -0
- package/dist/static/images/numbers/number_one.svg.js +5 -0
- package/dist/static/images/numbers/number_seven.svg.js +5 -0
- package/dist/static/images/numbers/number_six.svg.js +5 -0
- package/dist/static/images/numbers/number_three.svg.js +5 -0
- package/dist/static/images/numbers/number_two.svg.js +5 -0
- package/dist/static/images/numbers/number_zero.svg.js +5 -0
- package/dist/static/images/process-waiting.gif.js +4 -0
- package/dist/static/images/search-icon.svg.js +5 -0
- package/dist/static/images/social/Facebook_Logo.png.js +4 -0
- package/dist/static/images/social/LI-In-Bug.png.js +4 -0
- package/dist/static/images/social/Telegram-Logo.png.js +4 -0
- package/dist/static/images/social/X-logo-black.png.js +4 -0
- package/dist/static/images/social/youtube_social_circle_red.png.js +4 -0
- package/dist/static/images/transfer-icon.svg.js +5 -0
- package/dist/static/images/usdc-logo.svg.js +4 -0
- package/dist/static/images/usdq-logo.png.js +4 -0
- package/dist/static/images/warning-filled.svg.js +5 -0
- package/dist/styles/colors.js +57 -0
- package/dist/styles/fonts.js +100 -0
- package/dist/styles/global.js +74 -0
- package/dist/styles/grid.js +11 -0
- package/dist/styles/ioniconsStyles.js +31 -0
- package/dist/styles/reactTippy.js +40 -0
- package/dist/styles/rwd.js +56 -0
- package/dist/styles/semanticUi.js +84 -0
- package/dist/styles/spacing.js +8 -0
- package/dist/styles/theme.js +34 -0
- package/dist/utils/check-sale-time-left.js +85 -0
- package/dist/utils/check-todo-status.js +11 -0
- package/dist/utils/checklistGenerator.js +195 -0
- package/dist/utils/copyToClipboard.js +92 -0
- package/dist/utils/customHooks.js +126 -0
- package/dist/utils/delete-redirect-cookie-and-navigate.js +12 -0
- package/dist/utils/fix-decimals.js +5 -0
- package/dist/utils/formatCurrencyValue.js +95 -0
- package/dist/utils/get-cookie-domain.js +10 -0
- package/dist/utils/get-short-address.js +4 -0
- package/dist/utils/isUSInvestor.js +6 -0
- package/dist/utils/km_ify.js +33 -0
- package/dist/utils/moment.js +26 -0
- package/dist/utils/redirect-url.js +5 -0
- package/dist/utils/saveAs.js +17 -0
- package/dist/utils/scrollUtils.js +63 -0
- package/dist/utils/set-redirect-cookie.js +16 -0
- package/dist/utils/transition.js +101 -0
- package/dist/utils/withRouter.js +24 -0
- package/package.json +11 -11
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import styled 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 Wrapper = styled(ComponentWrapper)`
|
|
6
|
+
background: ${() => theme.cPrimary};
|
|
7
|
+
display: flex;
|
|
8
|
+
flex-direction: column;
|
|
9
|
+
justify-content: center;
|
|
10
|
+
height: 100%;
|
|
11
|
+
margin-top: -1px;
|
|
12
|
+
`;
|
|
13
|
+
const Title = styled.div`
|
|
14
|
+
font-size: 11px;
|
|
15
|
+
line-height: 20px;
|
|
16
|
+
letter-spacing: 2px;
|
|
17
|
+
margin-bottom: 14px;
|
|
18
|
+
color: ${() => theme.cWhite};
|
|
19
|
+
`;
|
|
20
|
+
const Amount = styled.div`
|
|
21
|
+
font-size: 34px;
|
|
22
|
+
line-height: 40px;
|
|
23
|
+
font-weight: 300;
|
|
24
|
+
margin-bottom: 20px;
|
|
25
|
+
letter-spacing: 2px;
|
|
26
|
+
color: ${() => theme.cWhite};
|
|
27
|
+
white-space: nowrap;
|
|
28
|
+
|
|
29
|
+
${rwd.Medium`
|
|
30
|
+
font-size: 28px;
|
|
31
|
+
`}
|
|
32
|
+
|
|
33
|
+
${rwd.Large`
|
|
34
|
+
font-size: 34px;
|
|
35
|
+
`}
|
|
36
|
+
`;
|
|
37
|
+
export {
|
|
38
|
+
Amount,
|
|
39
|
+
Title,
|
|
40
|
+
Wrapper
|
|
41
|
+
};
|
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
import styled, { css } from "styled-components";
|
|
2
|
+
import rwd from "../../styles/rwd.js";
|
|
3
|
+
import { SelectWrapper } from "../Input/Select.styles.js";
|
|
4
|
+
import theme from "../../styles/theme.js";
|
|
5
|
+
const Card = styled.div.withConfig({
|
|
6
|
+
shouldForwardProp: (props) => !["lessPadding", "lessPaddingHorizontal", "lessPaddingVertical", "chartPadding", "noPadding", "grow"].includes(
|
|
7
|
+
props
|
|
8
|
+
)
|
|
9
|
+
})`
|
|
10
|
+
padding: 28px 22px;
|
|
11
|
+
background: ${theme.cWhite};
|
|
12
|
+
|
|
13
|
+
${rwd.Medium`
|
|
14
|
+
padding: 40px 50px;
|
|
15
|
+
|
|
16
|
+
${(props) => props.lessPadding && css`
|
|
17
|
+
padding: 28px 22px;
|
|
18
|
+
`}
|
|
19
|
+
|
|
20
|
+
${(props) => props.lessPaddingHorizontal && css`
|
|
21
|
+
padding: 40px 22px;
|
|
22
|
+
`}
|
|
23
|
+
|
|
24
|
+
${(props) => props.lessPaddingVertical && css`
|
|
25
|
+
padding: 28px 50px;
|
|
26
|
+
`}
|
|
27
|
+
|
|
28
|
+
${(props) => props.chartPadding && css`
|
|
29
|
+
padding: 20px;
|
|
30
|
+
`}
|
|
31
|
+
|
|
32
|
+
${(props) => props.noPadding && css`
|
|
33
|
+
padding: 0;
|
|
34
|
+
`}
|
|
35
|
+
`}
|
|
36
|
+
|
|
37
|
+
${(props) => props.chartPadding && css`
|
|
38
|
+
padding: 10px;
|
|
39
|
+
`}
|
|
40
|
+
|
|
41
|
+
${(props) => props.noPadding && css`
|
|
42
|
+
padding: 0;
|
|
43
|
+
`}
|
|
44
|
+
|
|
45
|
+
${(props) => props.grow && `
|
|
46
|
+
flex-grow: ${props.grow};
|
|
47
|
+
`}
|
|
48
|
+
`;
|
|
49
|
+
const CardTitle = styled.div`
|
|
50
|
+
font-size: 16px;
|
|
51
|
+
line-height: 22px;
|
|
52
|
+
font-weight: 600;
|
|
53
|
+
`;
|
|
54
|
+
const CardTitleContainer = styled.div`
|
|
55
|
+
display: flex;
|
|
56
|
+
flex-direction: row;
|
|
57
|
+
align-items: center;
|
|
58
|
+
`;
|
|
59
|
+
const CardRightText = styled.div`
|
|
60
|
+
margin-left: auto;
|
|
61
|
+
font-size: 16px;
|
|
62
|
+
`;
|
|
63
|
+
const CardLeftText = styled.div`
|
|
64
|
+
margin-left: 18px;
|
|
65
|
+
font-size: 16px;
|
|
66
|
+
`;
|
|
67
|
+
const CardHeader = styled.div.withConfig({
|
|
68
|
+
shouldForwardProp: (props) => !["paddingRight"].includes(props)
|
|
69
|
+
})`
|
|
70
|
+
display: flex;
|
|
71
|
+
flex-direction: row;
|
|
72
|
+
justify-content: space-between;
|
|
73
|
+
align-items: center;
|
|
74
|
+
flex-wrap: wrap;
|
|
75
|
+
|
|
76
|
+
${(props) => props.paddingRight && css`
|
|
77
|
+
padding-right: ${props.paddingRight};
|
|
78
|
+
`}
|
|
79
|
+
|
|
80
|
+
${SelectWrapper} {
|
|
81
|
+
height: 22px;
|
|
82
|
+
margin-top: -8px;
|
|
83
|
+
}
|
|
84
|
+
`;
|
|
85
|
+
const CardHeaderRegular = styled.div`
|
|
86
|
+
font-weight: 400;
|
|
87
|
+
display: inline-block;
|
|
88
|
+
`;
|
|
89
|
+
export {
|
|
90
|
+
Card,
|
|
91
|
+
CardHeader,
|
|
92
|
+
CardHeaderRegular,
|
|
93
|
+
CardLeftText,
|
|
94
|
+
CardRightText,
|
|
95
|
+
CardTitle,
|
|
96
|
+
CardTitleContainer
|
|
97
|
+
};
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { useState } from "react";
|
|
3
|
+
import PropTypes from "prop-types";
|
|
4
|
+
import { Collapse } from "react-collapse";
|
|
5
|
+
import { Items, Item, Head, ColorLabel, NameCol, LargeText, SmallText, MarketDataCol, Arrow, Body } from "./ChartLegend.styles.js";
|
|
6
|
+
const ChartLegend = (props) => {
|
|
7
|
+
const { data } = props;
|
|
8
|
+
const [activeItems, setActiveItems] = useState(data.map(() => false));
|
|
9
|
+
const toggleItem = (key) => {
|
|
10
|
+
let newActiveItems = data.map((item, itemKey) => {
|
|
11
|
+
return itemKey === key ? !activeItems[itemKey] : activeItems[itemKey];
|
|
12
|
+
});
|
|
13
|
+
setActiveItems(newActiveItems);
|
|
14
|
+
};
|
|
15
|
+
return /* @__PURE__ */ jsx(Items, { children: data.map((item, itemKey) => /* @__PURE__ */ jsxs(Item, { children: [
|
|
16
|
+
/* @__PURE__ */ jsxs(Head, { onClick: () => toggleItem(itemKey), children: [
|
|
17
|
+
/* @__PURE__ */ jsx(ColorLabel, { itemColor: item.color }),
|
|
18
|
+
/* @__PURE__ */ jsxs(NameCol, { children: [
|
|
19
|
+
/* @__PURE__ */ jsx(
|
|
20
|
+
LargeText,
|
|
21
|
+
{
|
|
22
|
+
onClick: (e) => {
|
|
23
|
+
item.onNameClick?.(e, item);
|
|
24
|
+
},
|
|
25
|
+
isLink: !!item.onNameClick,
|
|
26
|
+
children: item.name
|
|
27
|
+
}
|
|
28
|
+
),
|
|
29
|
+
/* @__PURE__ */ jsx(SmallText, { children: item.subname })
|
|
30
|
+
] }),
|
|
31
|
+
/* @__PURE__ */ jsxs(NameCol, { children: [
|
|
32
|
+
/* @__PURE__ */ jsx(LargeText, { children: item.value }),
|
|
33
|
+
/* @__PURE__ */ jsx(SmallText, { children: item.info })
|
|
34
|
+
] }),
|
|
35
|
+
/* @__PURE__ */ jsxs(MarketDataCol, { isPositive: item.isPositive, children: [
|
|
36
|
+
/* @__PURE__ */ jsx(LargeText, { isPositive: item.isPositive, children: item.marketValue }),
|
|
37
|
+
/* @__PURE__ */ jsx(SmallText, { children: item.marketInfo })
|
|
38
|
+
] }),
|
|
39
|
+
item.details && /* @__PURE__ */ jsx(Arrow, { isOpened: activeItems[itemKey] })
|
|
40
|
+
] }),
|
|
41
|
+
item.details && /* @__PURE__ */ jsx(Collapse, { isOpened: activeItems[itemKey], children: /* @__PURE__ */ jsx(Body, { children: item.details }) })
|
|
42
|
+
] }, item.name)) });
|
|
43
|
+
};
|
|
44
|
+
ChartLegend.propTypes = {
|
|
45
|
+
data: PropTypes.arrayOf(
|
|
46
|
+
PropTypes.shape({
|
|
47
|
+
value: PropTypes.number.isRequired,
|
|
48
|
+
name: PropTypes.string,
|
|
49
|
+
onNameClick: PropTypes.func,
|
|
50
|
+
color: PropTypes.string,
|
|
51
|
+
subname: PropTypes.string,
|
|
52
|
+
info: PropTypes.string,
|
|
53
|
+
details: PropTypes.any,
|
|
54
|
+
isPositive: PropTypes.bool,
|
|
55
|
+
marketValue: PropTypes.string,
|
|
56
|
+
marketInfo: PropTypes.string
|
|
57
|
+
})
|
|
58
|
+
).isRequired
|
|
59
|
+
};
|
|
60
|
+
export {
|
|
61
|
+
ChartLegend
|
|
62
|
+
};
|
|
@@ -0,0 +1,133 @@
|
|
|
1
|
+
import styled from "styled-components";
|
|
2
|
+
import theme from "../../styles/theme.js";
|
|
3
|
+
const Items = styled.div`
|
|
4
|
+
display: block;
|
|
5
|
+
margin: -16px 0;
|
|
6
|
+
`;
|
|
7
|
+
const Item = styled.div`
|
|
8
|
+
padding: 16px 0;
|
|
9
|
+
`;
|
|
10
|
+
const Head = styled.div`
|
|
11
|
+
cursor: pointer;
|
|
12
|
+
position: relative;
|
|
13
|
+
font-size: 0;
|
|
14
|
+
padding: 0 46px;
|
|
15
|
+
`;
|
|
16
|
+
const Body = styled.div`
|
|
17
|
+
padding: 18px 0;
|
|
18
|
+
`;
|
|
19
|
+
const ColorLabel = styled.div.withConfig({
|
|
20
|
+
shouldForwardProp: (props) => props !== "itemColor"
|
|
21
|
+
})`
|
|
22
|
+
display: block;
|
|
23
|
+
width: 28px;
|
|
24
|
+
height: 28px;
|
|
25
|
+
background-color: ${(props) => props.itemColor};
|
|
26
|
+
position: absolute;
|
|
27
|
+
top: 0;
|
|
28
|
+
left: 0;
|
|
29
|
+
`;
|
|
30
|
+
const NameCol = styled.div`
|
|
31
|
+
width: 40%;
|
|
32
|
+
display: inline-block;
|
|
33
|
+
vertical-align: top;
|
|
34
|
+
`;
|
|
35
|
+
styled.div`
|
|
36
|
+
width: 50%;
|
|
37
|
+
display: inline-block;
|
|
38
|
+
vertical-align: top;
|
|
39
|
+
`;
|
|
40
|
+
const LargeText = styled.div.withConfig({
|
|
41
|
+
shouldForwardProp: (props) => !["isPositive", "isLink"].includes(props)
|
|
42
|
+
})`
|
|
43
|
+
font-weight: 300;
|
|
44
|
+
font-size: 22px;
|
|
45
|
+
line-height: 28px;
|
|
46
|
+
|
|
47
|
+
${(props) => props.isPositive && `
|
|
48
|
+
color: ${theme.cProgressDone};
|
|
49
|
+
`}
|
|
50
|
+
|
|
51
|
+
${(props) => props.isPositive === false && `
|
|
52
|
+
color: ${theme.cWarning};
|
|
53
|
+
`}
|
|
54
|
+
|
|
55
|
+
${(props) => props.isLink && `
|
|
56
|
+
text-decoration:underline;
|
|
57
|
+
text-decoration-thickness: from-font;
|
|
58
|
+
`}
|
|
59
|
+
`;
|
|
60
|
+
const SmallText = styled.div`
|
|
61
|
+
font-size: 11px;
|
|
62
|
+
line-height: 12px;
|
|
63
|
+
margin-top: 4px;
|
|
64
|
+
font-style: italic;
|
|
65
|
+
`;
|
|
66
|
+
const MarketDataCol = styled.div.withConfig({
|
|
67
|
+
shouldForwardProp: (props) => props !== "isPositive"
|
|
68
|
+
})`
|
|
69
|
+
width: 20%;
|
|
70
|
+
display: inline-block;
|
|
71
|
+
vertical-align: top;
|
|
72
|
+
position: relative;
|
|
73
|
+
|
|
74
|
+
${SmallText} {
|
|
75
|
+
position: relative;
|
|
76
|
+
left: -20px;
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
&::before {
|
|
80
|
+
display: block;
|
|
81
|
+
position: absolute;
|
|
82
|
+
content: '';
|
|
83
|
+
top: 30%;
|
|
84
|
+
left: -20px;
|
|
85
|
+
width: 0;
|
|
86
|
+
height: 0;
|
|
87
|
+
border-left: 5px solid transparent;
|
|
88
|
+
border-right: 5px solid transparent;
|
|
89
|
+
${(props) => props.isPositive && `
|
|
90
|
+
border-bottom: 7px solid
|
|
91
|
+
${theme.cProgressDone};
|
|
92
|
+
`}
|
|
93
|
+
|
|
94
|
+
${(props) => props.isPositive === false && `
|
|
95
|
+
border-top: 7px solid
|
|
96
|
+
${theme.cWarning};
|
|
97
|
+
`}
|
|
98
|
+
}
|
|
99
|
+
`;
|
|
100
|
+
const Arrow = styled.i.withConfig({
|
|
101
|
+
shouldForwardProp: (props) => props !== "isOpened"
|
|
102
|
+
}).attrs({
|
|
103
|
+
className: "ion ion-ios-arrow-down"
|
|
104
|
+
})`
|
|
105
|
+
& {
|
|
106
|
+
position: absolute;
|
|
107
|
+
top: 14px;
|
|
108
|
+
right: 24px;
|
|
109
|
+
transition: 0.3s transform;
|
|
110
|
+
transform: rotate(0);
|
|
111
|
+
text-align: center;
|
|
112
|
+
font-size: 16px;
|
|
113
|
+
line-height: 16px;
|
|
114
|
+
height: 16px;
|
|
115
|
+
margin-top: -8px;
|
|
116
|
+
|
|
117
|
+
${(props) => props.isOpened && `
|
|
118
|
+
transform: rotate(180deg);
|
|
119
|
+
`}
|
|
120
|
+
}
|
|
121
|
+
`;
|
|
122
|
+
export {
|
|
123
|
+
Arrow,
|
|
124
|
+
Body,
|
|
125
|
+
ColorLabel,
|
|
126
|
+
Head,
|
|
127
|
+
Item,
|
|
128
|
+
Items,
|
|
129
|
+
LargeText,
|
|
130
|
+
MarketDataCol,
|
|
131
|
+
NameCol,
|
|
132
|
+
SmallText
|
|
133
|
+
};
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
import { jsxs, jsx } from "react/jsx-runtime";
|
|
2
|
+
import "react";
|
|
3
|
+
import styled from "styled-components";
|
|
4
|
+
import PropTypes from "prop-types";
|
|
5
|
+
import { Wrapper, Label, Input } from "./Checkbox.styles.js";
|
|
6
|
+
const CheckBoxCaption = styled.div`
|
|
7
|
+
padding-top: 12px;
|
|
8
|
+
letter-spacing: 0.4px;
|
|
9
|
+
font-size: 11px;
|
|
10
|
+
font-weight: 400;
|
|
11
|
+
`;
|
|
12
|
+
const Checkbox = ({
|
|
13
|
+
id,
|
|
14
|
+
name = "",
|
|
15
|
+
text = "",
|
|
16
|
+
label = "",
|
|
17
|
+
value = "",
|
|
18
|
+
checked = false,
|
|
19
|
+
large = false,
|
|
20
|
+
error = false,
|
|
21
|
+
touched = false,
|
|
22
|
+
onChange = () => {
|
|
23
|
+
},
|
|
24
|
+
onBlur = () => {
|
|
25
|
+
},
|
|
26
|
+
onFocus = () => {
|
|
27
|
+
},
|
|
28
|
+
textStyle = {},
|
|
29
|
+
disabled,
|
|
30
|
+
onClick = () => {
|
|
31
|
+
},
|
|
32
|
+
marginTop,
|
|
33
|
+
...props
|
|
34
|
+
}) => /* @__PURE__ */ jsxs(Wrapper, { marginTop, children: [
|
|
35
|
+
label && /* @__PURE__ */ jsx(Label, { error: error && touched, htmlFor: id, children: label }),
|
|
36
|
+
/* @__PURE__ */ jsxs(Input, { error, large, disabled, children: [
|
|
37
|
+
/* @__PURE__ */ jsx(
|
|
38
|
+
"input",
|
|
39
|
+
{
|
|
40
|
+
type: "checkbox",
|
|
41
|
+
id,
|
|
42
|
+
name: name || id,
|
|
43
|
+
value,
|
|
44
|
+
checked,
|
|
45
|
+
onChange,
|
|
46
|
+
onBlur,
|
|
47
|
+
disabled,
|
|
48
|
+
onFocus,
|
|
49
|
+
onClick,
|
|
50
|
+
...props
|
|
51
|
+
}
|
|
52
|
+
),
|
|
53
|
+
/* @__PURE__ */ jsx("label", { htmlFor: id, style: textStyle, children: text })
|
|
54
|
+
] })
|
|
55
|
+
] });
|
|
56
|
+
const CheckboxPropTypes = {
|
|
57
|
+
id: PropTypes.string.isRequired,
|
|
58
|
+
name: PropTypes.string,
|
|
59
|
+
text: PropTypes.oneOfType([PropTypes.string, PropTypes.node]),
|
|
60
|
+
label: PropTypes.string,
|
|
61
|
+
value: PropTypes.string,
|
|
62
|
+
checked: PropTypes.bool,
|
|
63
|
+
large: PropTypes.bool,
|
|
64
|
+
error: PropTypes.bool,
|
|
65
|
+
touched: PropTypes.bool,
|
|
66
|
+
onChange: PropTypes.func,
|
|
67
|
+
onBlur: PropTypes.func,
|
|
68
|
+
onFocus: PropTypes.func,
|
|
69
|
+
onClick: PropTypes.func,
|
|
70
|
+
textStyle: PropTypes.object,
|
|
71
|
+
defaultChecked: PropTypes.bool
|
|
72
|
+
};
|
|
73
|
+
Checkbox.propTypes = CheckboxPropTypes;
|
|
74
|
+
var stdin_default = Checkbox;
|
|
75
|
+
export {
|
|
76
|
+
CheckBoxCaption,
|
|
77
|
+
Checkbox,
|
|
78
|
+
CheckboxPropTypes,
|
|
79
|
+
stdin_default as default
|
|
80
|
+
};
|
|
@@ -0,0 +1,133 @@
|
|
|
1
|
+
import styled from "styled-components";
|
|
2
|
+
import { Label as Label$1 } from "../Input/Input.styles.js";
|
|
3
|
+
import theme from "../../styles/theme.js";
|
|
4
|
+
const Wrapper = styled.div.withConfig({
|
|
5
|
+
shouldForwardProp: (props) => !["marginTop"].includes(props)
|
|
6
|
+
})`
|
|
7
|
+
position: relative;
|
|
8
|
+
display: block;
|
|
9
|
+
margin-top: ${({ marginTop }) => marginTop && "7px"};
|
|
10
|
+
`;
|
|
11
|
+
const Label = styled(Label$1)`
|
|
12
|
+
position: relative;
|
|
13
|
+
top: 0;
|
|
14
|
+
transform: none;
|
|
15
|
+
font-size: 10px;
|
|
16
|
+
margin-bottom: 5px;
|
|
17
|
+
`;
|
|
18
|
+
const Input = styled.div.withConfig({
|
|
19
|
+
shouldForwardProp: (props) => !["error", "large", "disabled"].includes(props)
|
|
20
|
+
})`
|
|
21
|
+
position: relative;
|
|
22
|
+
|
|
23
|
+
& > input {
|
|
24
|
+
z-index: -1;
|
|
25
|
+
position: absolute;
|
|
26
|
+
top: 4px;
|
|
27
|
+
left: 4px;
|
|
28
|
+
display: block;
|
|
29
|
+
width: 1px;
|
|
30
|
+
height: 0;
|
|
31
|
+
opacity: 0;
|
|
32
|
+
border: 0;
|
|
33
|
+
|
|
34
|
+
& + label {
|
|
35
|
+
position: relative;
|
|
36
|
+
display: inline-block;
|
|
37
|
+
max-width: 100%;
|
|
38
|
+
padding-left: 28px;
|
|
39
|
+
font-family: 'Open Sans';
|
|
40
|
+
font-size: 12px;
|
|
41
|
+
line-height: 16px;
|
|
42
|
+
font-weight: 300;
|
|
43
|
+
letter-spacing: 0.4px;
|
|
44
|
+
cursor: pointer;
|
|
45
|
+
|
|
46
|
+
p {
|
|
47
|
+
margin: 0;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
${(props) => props.error && `color: ${theme.cWarning}`};
|
|
51
|
+
|
|
52
|
+
p {
|
|
53
|
+
font-size: 12px;
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
&:before,
|
|
57
|
+
&:after {
|
|
58
|
+
display: block;
|
|
59
|
+
position: absolute;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
&:before {
|
|
63
|
+
content: '';
|
|
64
|
+
top: 0;
|
|
65
|
+
left: 0;
|
|
66
|
+
width: 16px;
|
|
67
|
+
height: 16px;
|
|
68
|
+
border-radius: 3px;
|
|
69
|
+
border: 1px solid #9b9b9b;
|
|
70
|
+
box-shadow: none;
|
|
71
|
+
transition: border-color 0.2s;
|
|
72
|
+
|
|
73
|
+
${(props) => props.large && `
|
|
74
|
+
width: 20px;
|
|
75
|
+
height: 20px;
|
|
76
|
+
border-radius: 4px;
|
|
77
|
+
`}
|
|
78
|
+
${(props) => props.disabled && `
|
|
79
|
+
background-color: #9b9b9b30;
|
|
80
|
+
|
|
81
|
+
`}
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
&:after {
|
|
85
|
+
content: '\\f3ff';
|
|
86
|
+
font-family: 'Ionicons';
|
|
87
|
+
speak: none;
|
|
88
|
+
font-style: normal;
|
|
89
|
+
font-weight: normal;
|
|
90
|
+
font-variant: normal;
|
|
91
|
+
text-transform: none;
|
|
92
|
+
text-rendering: auto;
|
|
93
|
+
-webkit-font-smoothing: antialiased;
|
|
94
|
+
-moz-osx-font-smoothing: grayscale;
|
|
95
|
+
top: 3px;
|
|
96
|
+
left: 3px;
|
|
97
|
+
width: 10px;
|
|
98
|
+
height: 10px;
|
|
99
|
+
font-size: 22px;
|
|
100
|
+
line-height: 10px;
|
|
101
|
+
text-align: center;
|
|
102
|
+
color: transparent;
|
|
103
|
+
|
|
104
|
+
${(props) => props.large && `
|
|
105
|
+
top: 0;
|
|
106
|
+
left: 0;
|
|
107
|
+
width: 20px;
|
|
108
|
+
height: 20px;
|
|
109
|
+
font-size: 34px;
|
|
110
|
+
line-height: 20px;
|
|
111
|
+
`};
|
|
112
|
+
}
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
&:focus + label,
|
|
116
|
+
&:hover + label {
|
|
117
|
+
&:before {
|
|
118
|
+
border-color: ${(props) => props.disabled ? "none" : theme.cPrimary};
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
&:checked + label {
|
|
123
|
+
&:after {
|
|
124
|
+
color: ${() => theme.cPrimary};
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
`;
|
|
129
|
+
export {
|
|
130
|
+
Input,
|
|
131
|
+
Label,
|
|
132
|
+
Wrapper
|
|
133
|
+
};
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
import { jsxs, jsx } from "react/jsx-runtime";
|
|
2
|
+
import "react";
|
|
3
|
+
import PropTypes from "prop-types";
|
|
4
|
+
import { iconsMap } from "../Icon/Icon.style.js";
|
|
5
|
+
import { CardContainer, IconBlock, IconCopy, CardTitle, CardDescription } from "./ChecklistCard.styles.js";
|
|
6
|
+
import { Icon } from "../ToDoList/ToDoListTask.styles.js";
|
|
7
|
+
import { colors } from "../../styles/colors.js";
|
|
8
|
+
import SvgWarningFilled from "../../static/images/warning-filled.svg.js";
|
|
9
|
+
const ICON_MAP = {
|
|
10
|
+
done: {
|
|
11
|
+
icon: iconsMap.check,
|
|
12
|
+
color: colors.freshGreen
|
|
13
|
+
},
|
|
14
|
+
missing: {
|
|
15
|
+
icon: /* @__PURE__ */ jsx(SvgWarningFilled, {}),
|
|
16
|
+
color: colors.warningYellow
|
|
17
|
+
},
|
|
18
|
+
in_progress: {
|
|
19
|
+
icon: iconsMap.inProgress,
|
|
20
|
+
color: colors.lightGrey
|
|
21
|
+
}
|
|
22
|
+
};
|
|
23
|
+
const ChecklistCard = ({
|
|
24
|
+
iconState = "missing",
|
|
25
|
+
title,
|
|
26
|
+
description,
|
|
27
|
+
link,
|
|
28
|
+
onClick,
|
|
29
|
+
iconCopy,
|
|
30
|
+
disabled = false,
|
|
31
|
+
isClickable = true,
|
|
32
|
+
...rest
|
|
33
|
+
}) => {
|
|
34
|
+
const { icon, color } = ICON_MAP[iconState] || ICON_MAP["missing"];
|
|
35
|
+
const iconElement = typeof icon === "string" ? /* @__PURE__ */ jsx(Icon, { icon, style: { color, display: "block", fontSize: 16 } }) : /* @__PURE__ */ jsx("span", { style: { display: "inline-flex", width: 20, height: 20, color }, children: icon });
|
|
36
|
+
const content = /* @__PURE__ */ jsxs(
|
|
37
|
+
CardContainer,
|
|
38
|
+
{
|
|
39
|
+
"aria-disabled": disabled,
|
|
40
|
+
isClickable,
|
|
41
|
+
tabIndex: disabled ? -1 : 0,
|
|
42
|
+
...onClick ? { role: "button", onClick } : {},
|
|
43
|
+
...rest,
|
|
44
|
+
children: [
|
|
45
|
+
/* @__PURE__ */ jsxs(IconBlock, { children: [
|
|
46
|
+
iconElement,
|
|
47
|
+
/* @__PURE__ */ jsx(IconCopy, { children: iconCopy })
|
|
48
|
+
] }),
|
|
49
|
+
/* @__PURE__ */ jsx(CardTitle, { children: title }),
|
|
50
|
+
/* @__PURE__ */ jsx(CardDescription, { children: description })
|
|
51
|
+
]
|
|
52
|
+
}
|
|
53
|
+
);
|
|
54
|
+
if (link && !onClick && !disabled) {
|
|
55
|
+
return /* @__PURE__ */ jsx("a", { href: link, tabIndex: 0, "aria-disabled": disabled, style: { textDecoration: "none", color: "inherit" }, children: content });
|
|
56
|
+
}
|
|
57
|
+
return content;
|
|
58
|
+
};
|
|
59
|
+
ChecklistCard.propTypes = {
|
|
60
|
+
iconState: PropTypes.oneOf(["done", "missing", "in_progress"]),
|
|
61
|
+
title: PropTypes.string.isRequired,
|
|
62
|
+
description: PropTypes.string.isRequired,
|
|
63
|
+
link: PropTypes.string,
|
|
64
|
+
onClick: PropTypes.func,
|
|
65
|
+
tooltip: PropTypes.string,
|
|
66
|
+
iconCopy: PropTypes.string.isRequired,
|
|
67
|
+
disabled: PropTypes.bool
|
|
68
|
+
};
|
|
69
|
+
export {
|
|
70
|
+
ChecklistCard
|
|
71
|
+
};
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
import styled from "styled-components";
|
|
2
|
+
import rwd from "../../styles/rwd.js";
|
|
3
|
+
const CardContainer = styled.div.withConfig({
|
|
4
|
+
shouldForwardProp: (props) => !["isClickable"].includes(props)
|
|
5
|
+
})`
|
|
6
|
+
display: flex;
|
|
7
|
+
flex-direction: column;
|
|
8
|
+
align-items: flex-start;
|
|
9
|
+
border: 1px solid #eaeaea;
|
|
10
|
+
border-radius: 1px;
|
|
11
|
+
background: #fff;
|
|
12
|
+
padding: 32px 32px 32px 32px;
|
|
13
|
+
min-width: 320px;
|
|
14
|
+
min-height: 220px;
|
|
15
|
+
height: 100%;
|
|
16
|
+
box-sizing: border-box;
|
|
17
|
+
transition: box-shadow 0.2s;
|
|
18
|
+
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.01);
|
|
19
|
+
position: relative;
|
|
20
|
+
cursor: pointer;
|
|
21
|
+
&:hover {
|
|
22
|
+
box-shadow: 0 4px 16px rgba(0, 0, 0, 0.04);
|
|
23
|
+
}
|
|
24
|
+
${({ isClickable }) => !isClickable && `
|
|
25
|
+
cursor: initial;
|
|
26
|
+
`}
|
|
27
|
+
|
|
28
|
+
&[aria-disabled='true'] {
|
|
29
|
+
opacity: 0.5;
|
|
30
|
+
cursor: not-allowed;
|
|
31
|
+
}
|
|
32
|
+
`;
|
|
33
|
+
const IconBlock = styled.div`
|
|
34
|
+
display: flex;
|
|
35
|
+
align-items: center;
|
|
36
|
+
margin-bottom: 32px;
|
|
37
|
+
`;
|
|
38
|
+
const IconCopy = styled.span`
|
|
39
|
+
font-size: 11px;
|
|
40
|
+
font-weight: 400;
|
|
41
|
+
letter-spacing: 2px;
|
|
42
|
+
margin-left: 8px;
|
|
43
|
+
line-height: 16px;
|
|
44
|
+
text-transform: uppercase;
|
|
45
|
+
`;
|
|
46
|
+
const CardTitle = styled.div`
|
|
47
|
+
margin-bottom: 32px;
|
|
48
|
+
text-transform: uppercase;
|
|
49
|
+
color: #202020;
|
|
50
|
+
font-weight: 800;
|
|
51
|
+
word-wrap: break-word;
|
|
52
|
+
font-size: 16px;
|
|
53
|
+
line-height: 24px;
|
|
54
|
+
letter-spacing: 0.6px;
|
|
55
|
+
|
|
56
|
+
${rwd.Medium`
|
|
57
|
+
font-size: 22px;
|
|
58
|
+
letter-spacing: 0.8px;
|
|
59
|
+
line-height: 28px;
|
|
60
|
+
`}
|
|
61
|
+
`;
|
|
62
|
+
const CardDescription = styled.div`
|
|
63
|
+
color: #202020;
|
|
64
|
+
font-size: 14px;
|
|
65
|
+
font-weight: 300;
|
|
66
|
+
line-height: 20px;
|
|
67
|
+
letter-spacing: 0.5px;
|
|
68
|
+
word-wrap: break-word;
|
|
69
|
+
|
|
70
|
+
${rwd.Medium`
|
|
71
|
+
font-size: 16px;
|
|
72
|
+
line-height: 24px;
|
|
73
|
+
letter-spacing: 0.8px;
|
|
74
|
+
`}
|
|
75
|
+
`;
|
|
76
|
+
export {
|
|
77
|
+
CardContainer,
|
|
78
|
+
CardDescription,
|
|
79
|
+
CardTitle,
|
|
80
|
+
IconBlock,
|
|
81
|
+
IconCopy
|
|
82
|
+
};
|