@thecb/components 2.2.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/.eslintrc.json +29 -0
- package/.github/PULL_REQUEST_TEMPLATE.md +18 -0
- package/.github/stale.yml +17 -0
- package/.prettierignore +3 -0
- package/.tool-versions +1 -0
- package/README.md +149 -0
- package/dist/cb-components.cjs.js +77 -0
- package/package.json +96 -0
- package/rollup.config.js +35 -0
- package/src/components/atoms/alert/Alert.js +67 -0
- package/src/components/atoms/alert/Alert.theme.js +71 -0
- package/src/components/atoms/alert/index.js +3 -0
- package/src/components/atoms/amount-callout/AmountCallout.js +27 -0
- package/src/components/atoms/amount-callout/AmountCallout.theme.js +19 -0
- package/src/components/atoms/amount-callout/index.js +3 -0
- package/src/components/atoms/breadcrumb/Breadcrumb.js +50 -0
- package/src/components/atoms/breadcrumb/Breadcrumb.theme.js +25 -0
- package/src/components/atoms/breadcrumb/index.js +3 -0
- package/src/components/atoms/button-with-action/ButtonWithAction.js +128 -0
- package/src/components/atoms/button-with-action/ButtonWithAction.stories.js +125 -0
- package/src/components/atoms/button-with-action/ButtonWithAction.theme.js +360 -0
- package/src/components/atoms/button-with-action/index.js +3 -0
- package/src/components/atoms/button-with-link/ButtonWithLink.js +40 -0
- package/src/components/atoms/button-with-link/index.js +3 -0
- package/src/components/atoms/checkbox/Checkbox.js +143 -0
- package/src/components/atoms/checkbox/Checkbox.theme.js +54 -0
- package/src/components/atoms/checkbox/index.js +3 -0
- package/src/components/atoms/checkbox-list/CheckboxList.js +129 -0
- package/src/components/atoms/checkbox-list/CheckboxList.theme.js +42 -0
- package/src/components/atoms/checkbox-list/index.js +3 -0
- package/src/components/atoms/country-dropdown/CountryDropdown.js +24 -0
- package/src/components/atoms/country-dropdown/index.js +1 -0
- package/src/components/atoms/country-dropdown/options.js +249 -0
- package/src/components/atoms/display-box/DisplayBox.js +22 -0
- package/src/components/atoms/display-box/DisplayBox.theme.js +9 -0
- package/src/components/atoms/display-box/index.js +3 -0
- package/src/components/atoms/display-card/DisplayCard.js +65 -0
- package/src/components/atoms/display-card/index.js +3 -0
- package/src/components/atoms/dropdown/Dropdown.js +299 -0
- package/src/components/atoms/dropdown/Dropdown.theme.js +9 -0
- package/src/components/atoms/dropdown/DropdownIcon.js +31 -0
- package/src/components/atoms/dropdown/index.js +3 -0
- package/src/components/atoms/form-layouts/FormContainer.js +28 -0
- package/src/components/atoms/form-layouts/FormInput.js +218 -0
- package/src/components/atoms/form-layouts/FormInputColumn.js +15 -0
- package/src/components/atoms/form-layouts/FormInputRow.js +26 -0
- package/src/components/atoms/form-layouts/FormLayouts.theme.js +52 -0
- package/src/components/atoms/form-layouts/index.js +6 -0
- package/src/components/atoms/form-select/FormSelect.js +62 -0
- package/src/components/atoms/form-select/FormSelect.styled.js +65 -0
- package/src/components/atoms/form-select/index.js +3 -0
- package/src/components/atoms/formatted-address/FormattedAddress.js +53 -0
- package/src/components/atoms/formatted-address/FormattedAddress.theme.js +11 -0
- package/src/components/atoms/formatted-address/index.js +3 -0
- package/src/components/atoms/hamburger-button/HamburgerButton.js +113 -0
- package/src/components/atoms/hamburger-button/index.js +3 -0
- package/src/components/atoms/heading/Heading.js +37 -0
- package/src/components/atoms/heading/Heading.styled.js +14 -0
- package/src/components/atoms/heading/Heading.theme.js +18 -0
- package/src/components/atoms/heading/index.js +3 -0
- package/src/components/atoms/icons/AccountsAddIcon.js +42 -0
- package/src/components/atoms/icons/AccountsIcon.js +37 -0
- package/src/components/atoms/icons/AccountsIconSmall.js +63 -0
- package/src/components/atoms/icons/ChevronIcon.js +51 -0
- package/src/components/atoms/icons/ForgotPasswordIcon.js +46 -0
- package/src/components/atoms/icons/GoToEmailIcon.js +31 -0
- package/src/components/atoms/icons/Icons.theme.js +38 -0
- package/src/components/atoms/icons/PaymentMethodIcon.js +42 -0
- package/src/components/atoms/icons/PaymentsIconSmall.js +63 -0
- package/src/components/atoms/icons/ProfileIconSmall.js +44 -0
- package/src/components/atoms/icons/PropertiesAddIcon.js +70 -0
- package/src/components/atoms/icons/PropertiesIconSmall.js +32 -0
- package/src/components/atoms/icons/SettingsIconSmall.js +63 -0
- package/src/components/atoms/icons/VerifiedEmailIcon.js +53 -0
- package/src/components/atoms/icons/index.js +28 -0
- package/src/components/atoms/index.js +33 -0
- package/src/components/atoms/labeled-amount/LabeledAmount.js +35 -0
- package/src/components/atoms/labeled-amount/LabeledAmount.theme.js +10 -0
- package/src/components/atoms/labeled-amount/index.js +3 -0
- package/src/components/atoms/layouts/Box.js +83 -0
- package/src/components/atoms/layouts/Box.styled.js +131 -0
- package/src/components/atoms/layouts/Center.js +28 -0
- package/src/components/atoms/layouts/Center.styled.js +18 -0
- package/src/components/atoms/layouts/Cluster.js +37 -0
- package/src/components/atoms/layouts/Cluster.styled.js +21 -0
- package/src/components/atoms/layouts/Cover.js +49 -0
- package/src/components/atoms/layouts/Cover.styled.js +29 -0
- package/src/components/atoms/layouts/Frame.js +28 -0
- package/src/components/atoms/layouts/Frame.styled.js +27 -0
- package/src/components/atoms/layouts/Grid.js +38 -0
- package/src/components/atoms/layouts/Grid.styled.js +22 -0
- package/src/components/atoms/layouts/Imposter.js +52 -0
- package/src/components/atoms/layouts/Imposter.styled.js +19 -0
- package/src/components/atoms/layouts/Motion.js +51 -0
- package/src/components/atoms/layouts/Motion.styled.js +41 -0
- package/src/components/atoms/layouts/Reel.js +28 -0
- package/src/components/atoms/layouts/Reel.styled.js +17 -0
- package/src/components/atoms/layouts/Sidebar.js +42 -0
- package/src/components/atoms/layouts/Sidebar.styled.js +38 -0
- package/src/components/atoms/layouts/Stack.js +36 -0
- package/src/components/atoms/layouts/Stack.styled.js +30 -0
- package/src/components/atoms/layouts/Switcher.js +64 -0
- package/src/components/atoms/layouts/Switcher.styled.js +44 -0
- package/src/components/atoms/layouts/examples/FixedSizeContainer.js +22 -0
- package/src/components/atoms/layouts/examples/FixedSizeContainer.styled.js +20 -0
- package/src/components/atoms/layouts/examples/LayoutContentBlock.js +27 -0
- package/src/components/atoms/layouts/examples/LayoutContentBlock.styled.js +15 -0
- package/src/components/atoms/layouts/examples/ResizingContainer.js +49 -0
- package/src/components/atoms/layouts/examples/ResizingContainer.styled.js +39 -0
- package/src/components/atoms/layouts/examples/cluster-example/ClusterExample.js +10 -0
- package/src/components/atoms/layouts/examples/cluster-example/ClusterExample.stories.js +97 -0
- package/src/components/atoms/layouts/examples/grid-example/GridExample.js +49 -0
- package/src/components/atoms/layouts/examples/grid-example/GridExample.stories.js +44 -0
- package/src/components/atoms/layouts/examples/sidebar-example/SidebarExample.js +11 -0
- package/src/components/atoms/layouts/examples/sidebar-example/SidebarExample.stories.js +87 -0
- package/src/components/atoms/layouts/examples/stack-example/StackExample.js +27 -0
- package/src/components/atoms/layouts/examples/stack-example/StackExample.stories.js +69 -0
- package/src/components/atoms/layouts/examples/switcher-example/SwitcherExample.js +38 -0
- package/src/components/atoms/layouts/examples/switcher-example/SwitcherExample.stories.js +65 -0
- package/src/components/atoms/layouts/index.js +27 -0
- package/src/components/atoms/line-item/LineItem.js +30 -0
- package/src/components/atoms/line-item/LineItem.theme.js +7 -0
- package/src/components/atoms/line-item/index.js +3 -0
- package/src/components/atoms/link/ExternalLink.js +50 -0
- package/src/components/atoms/link/ExternalLink.styled.js +26 -0
- package/src/components/atoms/link/InternalLink.js +51 -0
- package/src/components/atoms/link/InternalLink.styled.js +39 -0
- package/src/components/atoms/link/Link.theme.js +8 -0
- package/src/components/atoms/link/index.js +4 -0
- package/src/components/atoms/nav-footer/NavFooter.js +57 -0
- package/src/components/atoms/nav-footer/index.js +3 -0
- package/src/components/atoms/nav-header/NavHeader.js +36 -0
- package/src/components/atoms/nav-header/index.js +3 -0
- package/src/components/atoms/paragraph/Paragraph.js +31 -0
- package/src/components/atoms/paragraph/Paragraph.styled.js +13 -0
- package/src/components/atoms/paragraph/Paragraph.theme.js +18 -0
- package/src/components/atoms/paragraph/index.js +3 -0
- package/src/components/atoms/password-requirements/PasswordRequirements.js +116 -0
- package/src/components/atoms/password-requirements/index.js +3 -0
- package/src/components/atoms/placeholder/Placeholder.js +122 -0
- package/src/components/atoms/placeholder/Placeholder.theme.js +9 -0
- package/src/components/atoms/placeholder/index.js +3 -0
- package/src/components/atoms/processing-fee/ProcessingFee.js +43 -0
- package/src/components/atoms/processing-fee/ProcessingFee.theme.js +7 -0
- package/src/components/atoms/processing-fee/index.js +3 -0
- package/src/components/atoms/radio-button/RadioButton.js +101 -0
- package/src/components/atoms/radio-button/RadioButton.theme.js +9 -0
- package/src/components/atoms/radio-button/index.js +3 -0
- package/src/components/atoms/solid-divider/SolidDivider.js +22 -0
- package/src/components/atoms/solid-divider/SolidDivider.theme.js +8 -0
- package/src/components/atoms/solid-divider/index.js +3 -0
- package/src/components/atoms/spinner/Spinner.js +61 -0
- package/src/components/atoms/spinner/Spinner.theme.js +5 -0
- package/src/components/atoms/spinner/index.js +3 -0
- package/src/components/atoms/state-province-dropdown/StateProvinceDropdown.js +28 -0
- package/src/components/atoms/state-province-dropdown/index.js +3 -0
- package/src/components/atoms/state-province-dropdown/options.js +3837 -0
- package/src/components/atoms/text/Text.js +37 -0
- package/src/components/atoms/text/Text.styled.js +32 -0
- package/src/components/atoms/text/Text.theme.js +22 -0
- package/src/components/atoms/text/index.js +3 -0
- package/src/components/atoms/toggle-switch/ToggleSwitch.js +212 -0
- package/src/components/atoms/toggle-switch/ToggleSwitch.theme.js +36 -0
- package/src/components/atoms/toggle-switch/index.js +3 -0
- package/src/components/index.js +3 -0
- package/src/components/molecules/address-form/AddressForm.js +110 -0
- package/src/components/molecules/address-form/AddressForm.state.js +52 -0
- package/src/components/molecules/address-form/index.js +11 -0
- package/src/components/molecules/change-password-form/ChangePasswordForm.js +92 -0
- package/src/components/molecules/change-password-form/ChangePasswordForm.state.js +33 -0
- package/src/components/molecules/change-password-form/index.js +11 -0
- package/src/components/molecules/collapsible-section/CollapsibleSection.js +126 -0
- package/src/components/molecules/collapsible-section/CollapsibleSection.theme.js +11 -0
- package/src/components/molecules/collapsible-section/index.js +3 -0
- package/src/components/molecules/edit-name-form/EditNameForm.js +51 -0
- package/src/components/molecules/edit-name-form/EditNameForm.state.js +14 -0
- package/src/components/molecules/edit-name-form/index.js +11 -0
- package/src/components/molecules/email-form/EmailForm.js +55 -0
- package/src/components/molecules/email-form/EmailForm.state.js +19 -0
- package/src/components/molecules/email-form/index.js +11 -0
- package/src/components/molecules/forgot-password-form/ForgotPasswordForm.js +32 -0
- package/src/components/molecules/forgot-password-form/ForgotPasswordForm.state.js +11 -0
- package/src/components/molecules/forgot-password-form/index.js +11 -0
- package/src/components/molecules/highlight-tab-row/HighlightTabRow.js +62 -0
- package/src/components/molecules/highlight-tab-row/HighlightTabRow.theme.js +7 -0
- package/src/components/molecules/highlight-tab-row/index.js +8 -0
- package/src/components/molecules/index.js +24 -0
- package/src/components/molecules/login-form/LoginForm.js +46 -0
- package/src/components/molecules/login-form/LoginForm.state.js +14 -0
- package/src/components/molecules/login-form/index.js +11 -0
- package/src/components/molecules/modal/Modal.js +138 -0
- package/src/components/molecules/modal/index.js +3 -0
- package/src/components/molecules/module/Module.js +42 -0
- package/src/components/molecules/module/Module.theme.js +30 -0
- package/src/components/molecules/module/index.js +8 -0
- package/src/components/molecules/nav-menu/NavMenu.theme.js +5 -0
- package/src/components/molecules/nav-menu/NavMenuDesktop.js +39 -0
- package/src/components/molecules/nav-menu/NavMenuMobile.js +63 -0
- package/src/components/molecules/nav-menu/index.js +4 -0
- package/src/components/molecules/obligation/Obligation.js +69 -0
- package/src/components/molecules/obligation/icons/AccountBillIcon.js +89 -0
- package/src/components/molecules/obligation/icons/AccountConstructionIcon.js +99 -0
- package/src/components/molecules/obligation/icons/AccountDentalIcon.js +94 -0
- package/src/components/molecules/obligation/icons/AccountElectricIcon.js +99 -0
- package/src/components/molecules/obligation/icons/AccountGarbageIcon.js +94 -0
- package/src/components/molecules/obligation/icons/AccountGasIcon.js +94 -0
- package/src/components/molecules/obligation/icons/AccountGenericIcon.js +89 -0
- package/src/components/molecules/obligation/icons/AccountMedicalIcon.js +94 -0
- package/src/components/molecules/obligation/icons/AccountWaterIcon.js +94 -0
- package/src/components/molecules/obligation/icons/PropertyApartmentIcon.js +99 -0
- package/src/components/molecules/obligation/icons/PropertyBusinessIcon.js +94 -0
- package/src/components/molecules/obligation/icons/PropertyCarIcon.js +99 -0
- package/src/components/molecules/obligation/icons/PropertyCommercialVehicleIcon.js +100 -0
- package/src/components/molecules/obligation/icons/PropertyGarageIcon.js +96 -0
- package/src/components/molecules/obligation/icons/PropertyLandIcon.js +99 -0
- package/src/components/molecules/obligation/icons/PropertyMotorcycleIcon.js +99 -0
- package/src/components/molecules/obligation/icons/PropertyPersonalIcon.js +94 -0
- package/src/components/molecules/obligation/icons/PropertyStorefrontIcon.js +100 -0
- package/src/components/molecules/obligation/icons/index.js +60 -0
- package/src/components/molecules/obligation/index.js +3 -0
- package/src/components/molecules/obligation/modules/AmountModule.js +36 -0
- package/src/components/molecules/obligation/modules/IconModule.js +29 -0
- package/src/components/molecules/obligation/modules/PaymentDetailsActions.js +67 -0
- package/src/components/molecules/obligation/modules/TitleModule.js +25 -0
- package/src/components/molecules/obligation/modules/index.js +6 -0
- package/src/components/molecules/payment-button-bar/PaymentButtonBar.js +80 -0
- package/src/components/molecules/payment-button-bar/index.js +3 -0
- package/src/components/molecules/payment-details/PaymentDetails.js +158 -0
- package/src/components/molecules/payment-details/PaymentDetails.theme.js +11 -0
- package/src/components/molecules/payment-details/index.js +1 -0
- package/src/components/molecules/phone-form/PhoneForm.js +44 -0
- package/src/components/molecules/phone-form/PhoneForm.state.js +17 -0
- package/src/components/molecules/phone-form/index.js +11 -0
- package/src/components/molecules/radio-section/RadioSection.js +205 -0
- package/src/components/molecules/radio-section/RadioSection.theme.js +15 -0
- package/src/components/molecules/radio-section/index.js +3 -0
- package/src/components/molecules/registration-form/RegistrationForm.js +104 -0
- package/src/components/molecules/registration-form/RegistrationForm.state.js +40 -0
- package/src/components/molecules/registration-form/index.js +11 -0
- package/src/components/molecules/reset-confirmation-form/ResetConfirmationForm.js +56 -0
- package/src/components/molecules/reset-confirmation-form/index.js +3 -0
- package/src/components/molecules/reset-password-form/ResetPasswordForm.js +67 -0
- package/src/components/molecules/reset-password-form/ResetPasswordForm.state.js +30 -0
- package/src/components/molecules/reset-password-form/index.js +11 -0
- package/src/components/molecules/reset-password-success/ResetPasswordSuccess.js +55 -0
- package/src/components/molecules/reset-password-success/index.js +3 -0
- package/src/components/molecules/tab-sidebar/TabSidebar.js +92 -0
- package/src/components/molecules/tab-sidebar/TabSidebar.theme.js +9 -0
- package/src/components/molecules/tab-sidebar/index.js +3 -0
- package/src/components/molecules/terms-and-conditions/TermsAndConditions.js +73 -0
- package/src/components/molecules/terms-and-conditions/index.js +3 -0
- package/src/components/molecules/terms-and-conditions-modal/TermsAndConditionsModal.js +64 -0
- package/src/components/molecules/terms-and-conditions-modal/TermsAndConditionsModal.theme.js +28 -0
- package/src/components/molecules/terms-and-conditions-modal/index.js +3 -0
- package/src/components/molecules/workflow-tile/WorkflowTile.js +58 -0
- package/src/components/molecules/workflow-tile/index.js +3 -0
- package/src/components/templates/center-single/CenterSingle.js +61 -0
- package/src/components/templates/center-single/index.js +3 -0
- package/src/components/templates/center-stack/CenterStack.js +49 -0
- package/src/components/templates/center-stack/index.js +3 -0
- package/src/components/templates/default-page-template/DefaultPageTemplate.js +49 -0
- package/src/components/templates/default-page-template/index.js +3 -0
- package/src/components/templates/index.js +5 -0
- package/src/components/templates/sidebar-single-content/SidebarSingleContent.js +60 -0
- package/src/components/templates/sidebar-single-content/index.js +3 -0
- package/src/components/templates/sidebar-stack-content/SidebarStackContent.js +81 -0
- package/src/components/templates/sidebar-stack-content/index.js +3 -0
- package/src/components/templates/templates.theme.js +5 -0
- package/src/components/withWindowSize.js +50 -0
- package/src/constants/colors.js +178 -0
- package/src/constants/regex_constants.js +1 -0
- package/src/constants/style_constants.js +21 -0
- package/src/deprecated/colors.js +154 -0
- package/src/deprecated/components/radio-button/index.js +3 -0
- package/src/deprecated/components/radio-button/radio-button.js +44 -0
- package/src/deprecated/icons/AlertErrorIcon.js +42 -0
- package/src/deprecated/icons/AlertInfoIcon.js +42 -0
- package/src/deprecated/icons/AlertSuccessIcon.js +42 -0
- package/src/deprecated/icons/AlertWarningIcon.js +36 -0
- package/src/deprecated/icons/BankIcon.js +82 -0
- package/src/deprecated/icons/GenericCard.js +39 -0
- package/src/deprecated/icons/IconAdd.js +44 -0
- package/src/deprecated/icons/IconCheck.js +23 -0
- package/src/deprecated/icons/IconCheckEmail.js +46 -0
- package/src/deprecated/icons/IconChevron.js +35 -0
- package/src/deprecated/icons/IconEmailVerified.js +62 -0
- package/src/deprecated/icons/IconEye.js +32 -0
- package/src/deprecated/icons/IconEyeSlash.js +48 -0
- package/src/deprecated/icons/IconInvalid.js +69 -0
- package/src/deprecated/icons/IconNeutral.js +27 -0
- package/src/deprecated/icons/IconQuit.js +32 -0
- package/src/deprecated/icons/IconValid.js +72 -0
- package/src/deprecated/icons/IconWarn.js +28 -0
- package/src/deprecated/icons/index.js +40 -0
- package/src/deprecated/index.js +1 -0
- package/src/deprecated/spinner/Spinner.js +68 -0
- package/src/deprecated/spinner/index.js +1 -0
- package/src/deprecated/utility/__tests__/safeConcat.spec.js +59 -0
- package/src/deprecated/utility/__tests__/validateKeyType.spec.js +116 -0
- package/src/deprecated/utility/index.js +2 -0
- package/src/deprecated/utility/safeConcat.js +10 -0
- package/src/deprecated/utility/validateKeyType.js +19 -0
- package/src/index.js +2 -0
- package/src/util/formats.js +30 -0
- package/src/util/general.js +15 -0
- package/src/util/inputValidationUtils.js +257 -0
- package/src/util/router-utils.js +23 -0
- package/src/util/themeUtils.js +144 -0
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import React, { useContext, Fragment } from "react";
|
|
2
|
+
import { ThemeContext } from "styled-components";
|
|
3
|
+
import { fallbackValues } from "../templates.theme";
|
|
4
|
+
import { themeComponent } from "../../../util/themeUtils";
|
|
5
|
+
import withWindowResize from "../../withWindowSize";
|
|
6
|
+
import { Box, Center, Cover } from "../../atoms/layouts";
|
|
7
|
+
|
|
8
|
+
const CenterSingle = ({
|
|
9
|
+
header,
|
|
10
|
+
footer,
|
|
11
|
+
subHeader,
|
|
12
|
+
hideMobileSubHeader = true,
|
|
13
|
+
maxContentWidth = "36.75rem",
|
|
14
|
+
fullWidthMobile = true,
|
|
15
|
+
centeredMobileContent = false,
|
|
16
|
+
content,
|
|
17
|
+
themeValues
|
|
18
|
+
}) => {
|
|
19
|
+
const themeContext = useContext(ThemeContext);
|
|
20
|
+
const { isMobile } = themeContext;
|
|
21
|
+
|
|
22
|
+
return (
|
|
23
|
+
<Box padding="0" minWidth="100%" background={themeValues.pageBackground}>
|
|
24
|
+
<Cover
|
|
25
|
+
minHeight="100vh"
|
|
26
|
+
centerOverride={isMobile && !centeredMobileContent}
|
|
27
|
+
>
|
|
28
|
+
{header ? header : <Box padding="0" />}
|
|
29
|
+
<Box
|
|
30
|
+
padding="0"
|
|
31
|
+
minWidth="100%"
|
|
32
|
+
extraStyles={`z-index: 1;`}
|
|
33
|
+
role="main"
|
|
34
|
+
>
|
|
35
|
+
{subHeader && !(isMobile && hideMobileSubHeader) ? (
|
|
36
|
+
subHeader
|
|
37
|
+
) : (
|
|
38
|
+
<Fragment />
|
|
39
|
+
)}
|
|
40
|
+
<Center
|
|
41
|
+
maxWidth={isMobile && fullWidthMobile ? "100%" : maxContentWidth}
|
|
42
|
+
intrinsic={!isMobile}
|
|
43
|
+
>
|
|
44
|
+
{centeredMobileContent ? (
|
|
45
|
+
<Cover minHeight="100%" singleChild>
|
|
46
|
+
{content}
|
|
47
|
+
</Cover>
|
|
48
|
+
) : (
|
|
49
|
+
<Box padding="0">{content}</Box>
|
|
50
|
+
)}
|
|
51
|
+
</Center>
|
|
52
|
+
</Box>
|
|
53
|
+
{footer ? footer : <Box padding="0" />}
|
|
54
|
+
</Cover>
|
|
55
|
+
</Box>
|
|
56
|
+
);
|
|
57
|
+
};
|
|
58
|
+
|
|
59
|
+
export default withWindowResize(
|
|
60
|
+
themeComponent(CenterSingle, "Global", fallbackValues)
|
|
61
|
+
);
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import React, { useContext, Fragment } from "react";
|
|
2
|
+
import { ThemeContext } from "styled-components";
|
|
3
|
+
import { fallbackValues } from "../templates.theme";
|
|
4
|
+
import { themeComponent } from "../../../util/themeUtils";
|
|
5
|
+
import withWindowResize from "../../withWindowSize";
|
|
6
|
+
import { Box, Center, Cover, Stack } from "../../atoms/layouts";
|
|
7
|
+
|
|
8
|
+
const CenterStack = ({
|
|
9
|
+
header,
|
|
10
|
+
footer,
|
|
11
|
+
subHeader,
|
|
12
|
+
hideMobileSubHeader = true,
|
|
13
|
+
contentSpacing = "1rem",
|
|
14
|
+
maxContentWidth = "36.75rem",
|
|
15
|
+
fullWidthMobile = true,
|
|
16
|
+
content,
|
|
17
|
+
themeValues
|
|
18
|
+
}) => {
|
|
19
|
+
const themeContext = useContext(ThemeContext);
|
|
20
|
+
const { isMobile } = themeContext;
|
|
21
|
+
|
|
22
|
+
return (
|
|
23
|
+
<Box padding="0" minWidth="100%" background={themeValues.pageBackground}>
|
|
24
|
+
<Cover minHeight="100vh">
|
|
25
|
+
{header ? header : <Box padding="0" />}
|
|
26
|
+
<Box padding="0" minWidth="100%" role="main">
|
|
27
|
+
{subHeader && !(isMobile && hideMobileSubHeader) ? (
|
|
28
|
+
subHeader
|
|
29
|
+
) : (
|
|
30
|
+
<Fragment />
|
|
31
|
+
)}
|
|
32
|
+
<Center
|
|
33
|
+
maxWidth={isMobile && fullWidthMobile ? "100%" : maxContentWidth}
|
|
34
|
+
intrinsic={!isMobile}
|
|
35
|
+
>
|
|
36
|
+
<Cover minHeight="100%" singleChild>
|
|
37
|
+
<Stack childGap={contentSpacing}>{content}</Stack>
|
|
38
|
+
</Cover>
|
|
39
|
+
</Center>
|
|
40
|
+
</Box>
|
|
41
|
+
{footer ? footer : <Box padding="0" />}
|
|
42
|
+
</Cover>
|
|
43
|
+
</Box>
|
|
44
|
+
);
|
|
45
|
+
};
|
|
46
|
+
|
|
47
|
+
export default withWindowResize(
|
|
48
|
+
themeComponent(CenterStack, "Global", fallbackValues)
|
|
49
|
+
);
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import React, { useContext, Fragment } from "react";
|
|
2
|
+
import { ThemeContext } from "styled-components";
|
|
3
|
+
import { fallbackValues } from "../templates.theme";
|
|
4
|
+
import { themeComponent } from "../../../util/themeUtils";
|
|
5
|
+
import withWindowResize from "../../withWindowSize";
|
|
6
|
+
import { Box, Center, Cover } from "../../atoms/layouts";
|
|
7
|
+
|
|
8
|
+
const CenterSingle = ({
|
|
9
|
+
header,
|
|
10
|
+
footer,
|
|
11
|
+
subHeader,
|
|
12
|
+
hideMobileSubHeader = false,
|
|
13
|
+
content,
|
|
14
|
+
themeValues,
|
|
15
|
+
maxWidth = "75rem",
|
|
16
|
+
gutters = "2rem"
|
|
17
|
+
}) => {
|
|
18
|
+
const themeContext = useContext(ThemeContext);
|
|
19
|
+
const { isMobile } = themeContext;
|
|
20
|
+
|
|
21
|
+
return (
|
|
22
|
+
<Box padding="0" minWidth="100%" background={themeValues.pageBackground}>
|
|
23
|
+
<Cover minHeight="100vh" childGap="0" fillCenter>
|
|
24
|
+
{header ? header : <Box padding="0" />}
|
|
25
|
+
<Box
|
|
26
|
+
padding="0"
|
|
27
|
+
minWidth="100%"
|
|
28
|
+
minHeight="100%"
|
|
29
|
+
extraStyles={`z-index: 1;`}
|
|
30
|
+
role="main"
|
|
31
|
+
>
|
|
32
|
+
{subHeader && !(isMobile && hideMobileSubHeader) ? (
|
|
33
|
+
subHeader
|
|
34
|
+
) : (
|
|
35
|
+
<Fragment />
|
|
36
|
+
)}
|
|
37
|
+
<Center maxWidth={maxWidth} gutters={gutters}>
|
|
38
|
+
{content}
|
|
39
|
+
</Center>
|
|
40
|
+
</Box>
|
|
41
|
+
{footer ? footer : <Box padding="0" />}
|
|
42
|
+
</Cover>
|
|
43
|
+
</Box>
|
|
44
|
+
);
|
|
45
|
+
};
|
|
46
|
+
|
|
47
|
+
export default withWindowResize(
|
|
48
|
+
themeComponent(CenterSingle, "Global", fallbackValues)
|
|
49
|
+
);
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export { default as CenterSingle } from "./center-single";
|
|
2
|
+
export { default as CenterStack } from "./center-stack";
|
|
3
|
+
export { default as DefaultPageTemplate } from "./default-page-template";
|
|
4
|
+
export { default as SidebarSingleContent } from "./sidebar-single-content";
|
|
5
|
+
export { default as SidebarStackContent } from "./sidebar-stack-content";
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
import React, { useContext, Fragment } from "react";
|
|
2
|
+
import { ThemeContext } from "styled-components";
|
|
3
|
+
import { fallbackValues } from "../templates.theme";
|
|
4
|
+
import { themeComponent } from "../../../util/themeUtils";
|
|
5
|
+
import withWindowResize from "../../withWindowSize";
|
|
6
|
+
import { Box, Center, Cover, Sidebar } from "../../atoms/layouts";
|
|
7
|
+
|
|
8
|
+
const SidebarSingleContent = ({
|
|
9
|
+
header,
|
|
10
|
+
footer,
|
|
11
|
+
subHeader,
|
|
12
|
+
hideMobileSubHeader = true,
|
|
13
|
+
sidebarWrapperPadding = "0",
|
|
14
|
+
sidebarWrapperMaxWidth = "auto",
|
|
15
|
+
sidebarContent,
|
|
16
|
+
mainContent,
|
|
17
|
+
sidebarOnRight = false,
|
|
18
|
+
sidebarTargetWidth = "10rem",
|
|
19
|
+
sidebarContentGap = "1rem",
|
|
20
|
+
mainContentMinWidth = "50%",
|
|
21
|
+
sidebarVerticalCenter = false,
|
|
22
|
+
themeValues
|
|
23
|
+
}) => {
|
|
24
|
+
const themeContext = useContext(ThemeContext);
|
|
25
|
+
const { isMobile } = themeContext;
|
|
26
|
+
|
|
27
|
+
return (
|
|
28
|
+
<Box padding="0" minWidth="100%" background={themeValues.pageBackground}>
|
|
29
|
+
<Cover minHeight="100vh" centerOverride={!sidebarVerticalCenter}>
|
|
30
|
+
{header ? header : <Box padding="0" />}
|
|
31
|
+
<Box padding="0" minWidth="100%" role="main">
|
|
32
|
+
{subHeader && !(isMobile && hideMobileSubHeader) ? (
|
|
33
|
+
subHeader
|
|
34
|
+
) : (
|
|
35
|
+
<Fragment />
|
|
36
|
+
)}
|
|
37
|
+
<Box padding={sidebarWrapperPadding}>
|
|
38
|
+
<Center maxWidth={sidebarWrapperMaxWidth}>
|
|
39
|
+
<Sidebar
|
|
40
|
+
width={sidebarTargetWidth}
|
|
41
|
+
childGap={sidebarContentGap}
|
|
42
|
+
onRight={sidebarOnRight}
|
|
43
|
+
contentMinWidth={mainContentMinWidth}
|
|
44
|
+
>
|
|
45
|
+
{sidebarOnRight ? <Fragment /> : sidebarContent}
|
|
46
|
+
{mainContent}
|
|
47
|
+
{sidebarOnRight ? sidebarContent : <Fragment />}
|
|
48
|
+
</Sidebar>
|
|
49
|
+
</Center>
|
|
50
|
+
</Box>
|
|
51
|
+
</Box>
|
|
52
|
+
{footer ? footer : <Box padding="0" />}
|
|
53
|
+
</Cover>
|
|
54
|
+
</Box>
|
|
55
|
+
);
|
|
56
|
+
};
|
|
57
|
+
|
|
58
|
+
export default withWindowResize(
|
|
59
|
+
themeComponent(SidebarSingleContent, "Global", fallbackValues)
|
|
60
|
+
);
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
import React, { useContext, Fragment } from "react";
|
|
2
|
+
import { ThemeContext } from "styled-components";
|
|
3
|
+
import { fallbackValues } from "../templates.theme";
|
|
4
|
+
import { themeComponent } from "../../../util/themeUtils";
|
|
5
|
+
import withWindowResize from "../../withWindowSize";
|
|
6
|
+
import { Box, Center, Cover, Sidebar, Stack } from "../../atoms/layouts";
|
|
7
|
+
|
|
8
|
+
const SidebarStackContent = ({
|
|
9
|
+
header,
|
|
10
|
+
footer,
|
|
11
|
+
subHeader,
|
|
12
|
+
hideMobileSubHeader = true,
|
|
13
|
+
sidebarWrapperPadding = "0",
|
|
14
|
+
sidebarWrapperMaxWidth = "auto",
|
|
15
|
+
sidebarContent,
|
|
16
|
+
mainContent,
|
|
17
|
+
sidebarOnRight = false,
|
|
18
|
+
sidebarTargetWidth = "10rem",
|
|
19
|
+
sidebarContentGap = "1rem",
|
|
20
|
+
contentStackGap = "1rem",
|
|
21
|
+
mainContentMinWidth = "50%",
|
|
22
|
+
sidebarVerticalCenter = false,
|
|
23
|
+
themeValues
|
|
24
|
+
}) => {
|
|
25
|
+
const themeContext = useContext(ThemeContext);
|
|
26
|
+
const { isMobile } = themeContext;
|
|
27
|
+
|
|
28
|
+
return (
|
|
29
|
+
<Box
|
|
30
|
+
padding="0"
|
|
31
|
+
minWidth="100%"
|
|
32
|
+
background={themeValues.pageBackground}
|
|
33
|
+
key="page-bg"
|
|
34
|
+
>
|
|
35
|
+
<Cover
|
|
36
|
+
minHeight="100vh"
|
|
37
|
+
centerOverride={!sidebarVerticalCenter}
|
|
38
|
+
key="page-cover"
|
|
39
|
+
>
|
|
40
|
+
{header ? header : <Box padding="0" key="header-box" />}
|
|
41
|
+
<Box padding="0" minWidth="100%" key="content-box" role="main">
|
|
42
|
+
{subHeader && !(isMobile && hideMobileSubHeader) ? (
|
|
43
|
+
subHeader
|
|
44
|
+
) : (
|
|
45
|
+
<Fragment />
|
|
46
|
+
)}
|
|
47
|
+
<Box padding={sidebarWrapperPadding} key="content-wrapper">
|
|
48
|
+
<Center maxWidth={sidebarWrapperMaxWidth} key="content-center">
|
|
49
|
+
<Sidebar
|
|
50
|
+
width={sidebarTargetWidth}
|
|
51
|
+
childGap={sidebarContentGap}
|
|
52
|
+
onRight={sidebarOnRight}
|
|
53
|
+
contentMinWidth={mainContentMinWidth}
|
|
54
|
+
key="content-sidebar"
|
|
55
|
+
>
|
|
56
|
+
{sidebarOnRight ? (
|
|
57
|
+
<Fragment key="sidebar-fragment" />
|
|
58
|
+
) : (
|
|
59
|
+
sidebarContent
|
|
60
|
+
)}
|
|
61
|
+
<Stack key="content-stack" childGap={contentStackGap}>
|
|
62
|
+
{mainContent}
|
|
63
|
+
</Stack>
|
|
64
|
+
{sidebarOnRight ? (
|
|
65
|
+
sidebarContent
|
|
66
|
+
) : (
|
|
67
|
+
<Fragment key="sidebar-fragment" />
|
|
68
|
+
)}
|
|
69
|
+
</Sidebar>
|
|
70
|
+
</Center>
|
|
71
|
+
</Box>
|
|
72
|
+
</Box>
|
|
73
|
+
{footer ? footer : <Box padding="0" key="footer-box" />}
|
|
74
|
+
</Cover>
|
|
75
|
+
</Box>
|
|
76
|
+
);
|
|
77
|
+
};
|
|
78
|
+
|
|
79
|
+
export default withWindowResize(
|
|
80
|
+
themeComponent(SidebarStackContent, "Global", fallbackValues)
|
|
81
|
+
);
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import React, { useState, useLayoutEffect, useRef } from "react";
|
|
2
|
+
import { ThemeProvider } from "styled-components";
|
|
3
|
+
|
|
4
|
+
const MOBILE_WIDTH = 768;
|
|
5
|
+
|
|
6
|
+
const throttle = (delay, fn) => {
|
|
7
|
+
let lastCall = 0;
|
|
8
|
+
return (...args) => {
|
|
9
|
+
const now = new Date().getTime();
|
|
10
|
+
if (now - lastCall < delay) {
|
|
11
|
+
return;
|
|
12
|
+
}
|
|
13
|
+
lastCall = now;
|
|
14
|
+
return fn(...args);
|
|
15
|
+
};
|
|
16
|
+
};
|
|
17
|
+
|
|
18
|
+
const withWindowSize = Child => ({ ...props }) => {
|
|
19
|
+
const [state, setState] = useState({
|
|
20
|
+
isMobile: window.innerWidth < MOBILE_WIDTH,
|
|
21
|
+
mobileWidth: MOBILE_WIDTH,
|
|
22
|
+
supportsTouch: "ontouchstart" in window || navigator.maxTouchPoints > 1
|
|
23
|
+
});
|
|
24
|
+
const isMobileRef = useRef(state.isMobile);
|
|
25
|
+
const onResize = throttle(25, () => {
|
|
26
|
+
const width = window.innerWidth;
|
|
27
|
+
const newMobileState = width <= MOBILE_WIDTH;
|
|
28
|
+
if (newMobileState !== isMobileRef.current) {
|
|
29
|
+
isMobileRef.current = newMobileState;
|
|
30
|
+
setState({
|
|
31
|
+
isMobile: width <= MOBILE_WIDTH,
|
|
32
|
+
mobileWidth: MOBILE_WIDTH,
|
|
33
|
+
supportsTouch: "ontouchstart" in window || navigator.maxTouchPoints > 1
|
|
34
|
+
});
|
|
35
|
+
}
|
|
36
|
+
});
|
|
37
|
+
useLayoutEffect(() => {
|
|
38
|
+
window.addEventListener("resize", onResize);
|
|
39
|
+
return () => {
|
|
40
|
+
window.removeEventListener("resize", onResize);
|
|
41
|
+
};
|
|
42
|
+
}, []);
|
|
43
|
+
return (
|
|
44
|
+
<ThemeProvider theme={state}>
|
|
45
|
+
<Child {...props} />
|
|
46
|
+
</ThemeProvider>
|
|
47
|
+
);
|
|
48
|
+
};
|
|
49
|
+
|
|
50
|
+
export default withWindowSize;
|
|
@@ -0,0 +1,178 @@
|
|
|
1
|
+
/*
|
|
2
|
+
Need to add a new color? Visit http://chir.ag/projects/name-that-color to generate a color name.
|
|
3
|
+
|
|
4
|
+
Name already taken? If you can't use the existing color, then use thesaurus.com to pick a similar name
|
|
5
|
+
to the one generated by name-that-color.
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
const TRANSPARENT = "transparent";
|
|
9
|
+
// WHITE
|
|
10
|
+
const WHITE = "#FFFFFF";
|
|
11
|
+
const SOLITUDE_WHITE = "#EBEDF1";
|
|
12
|
+
const SEASHELL_WHITE = "#F1F1F1";
|
|
13
|
+
const ALABASTER_WHITE = "#F7F7F7";
|
|
14
|
+
const AQUA_HAZE_WHITE = "#F7F9FA";
|
|
15
|
+
const BLEACH_WHITE = "#FEF4d7";
|
|
16
|
+
const CATSKILL_WHITE = "#EAF2F6";
|
|
17
|
+
// GREY
|
|
18
|
+
const ATHENS_GREY = "#F6F6F9";
|
|
19
|
+
const ALTO_GREY = "#d1d1d1";
|
|
20
|
+
const SILVER_GREY = "#cdcdcd";
|
|
21
|
+
const PEWTER_GREY = "#DFE1E4";
|
|
22
|
+
const ASH_GREY = "#979797";
|
|
23
|
+
const IRON_GREY = "#d5d8dc";
|
|
24
|
+
const GHOST_GREY = "#CACED8";
|
|
25
|
+
const DUSTY_GREY = "#9B9B9B";
|
|
26
|
+
const REGENT_GREY = "#959EA7";
|
|
27
|
+
const STORM_GREY = "#6E727E";
|
|
28
|
+
const TROUT_GREY = "#515660";
|
|
29
|
+
const MINESHAFT_GREY = "#333333";
|
|
30
|
+
const SOOT_GREY = "#999999";
|
|
31
|
+
const FIREFLY_GREY = "#091325";
|
|
32
|
+
const BRIGHT_GREY = "#3B414D";
|
|
33
|
+
const CHARADE_GREY = "#292A33";
|
|
34
|
+
const GRECIAN_GREY = "#E5E7EC";
|
|
35
|
+
const BLACK_SQUEEZE = "#EAF2F7";
|
|
36
|
+
const GREY_CHATEAU = "#959CA8";
|
|
37
|
+
// BLUE
|
|
38
|
+
const CLOUDBURST_BLUE = "#26395c";
|
|
39
|
+
const ZODIAC_BLUE = "#14284b";
|
|
40
|
+
const CONGRESS_BLUE = "#005095";
|
|
41
|
+
const SCIENCE_BLUE = "#0074D9";
|
|
42
|
+
const MARINER_BLUE = "#2E75D2";
|
|
43
|
+
const CURIOUS_BLUE = "#27A9E1";
|
|
44
|
+
const SELAGO_BLUE = "#F2F8FD";
|
|
45
|
+
const ONAHAU_BLUE = "#D1ECFF";
|
|
46
|
+
const PICKLED_BLUE = "#2C3E50";
|
|
47
|
+
const CERULEAN_BLUE = "#0D8DC4";
|
|
48
|
+
const FOAM_BLUE = "#EFF4FD";
|
|
49
|
+
const CELLO_BLUE = "#214566";
|
|
50
|
+
const BOSTON_BLUE = "#357fb8";
|
|
51
|
+
const INFO_BLUE = "#E4F4FD";
|
|
52
|
+
const HOVER_LIGHT_BLUE = "#EFFAFF";
|
|
53
|
+
const MATISSE_BLUE = "#15749D";
|
|
54
|
+
// GREEN
|
|
55
|
+
const FOREST_GREEN = "#19b03F";
|
|
56
|
+
const MEADOW_GREEN = "#16C98D";
|
|
57
|
+
const POLAR_GREEN = "#DCF7EE";
|
|
58
|
+
const ICE_GREEN = "#A4F6DF";
|
|
59
|
+
const HAZE_GREEN = "#05A670";
|
|
60
|
+
const EMERALD_GREEN = "#47B872";
|
|
61
|
+
const HINT_GREEN = "#E8FFEF";
|
|
62
|
+
const SEA_GREEN = "#317D4F";
|
|
63
|
+
// YELLOW
|
|
64
|
+
const SELECTIVE_YELLOW = "#F8B700";
|
|
65
|
+
const MUSTARD_YELLOW = "#FFD459";
|
|
66
|
+
// ORANGE
|
|
67
|
+
const CARROT_ORANGE = "#ED9620";
|
|
68
|
+
const ZEST_ORANGE = "#F47820";
|
|
69
|
+
const APRICOT_ORANGE = "#FFE8D8";
|
|
70
|
+
// RED
|
|
71
|
+
const RED = "#FF0000";
|
|
72
|
+
const CRIMSON_RED = "#ED1C24";
|
|
73
|
+
const THUNDERBIRD_RED = "#C3191F";
|
|
74
|
+
const RAZZMATAZZ_RED = "#ED125F";
|
|
75
|
+
const FANTASY_RED = "#FCF4F4";
|
|
76
|
+
const COSMOS_RED = "#FFD0D3";
|
|
77
|
+
const BLUSH_RED = "#FFF0F5";
|
|
78
|
+
|
|
79
|
+
// Second level color constants
|
|
80
|
+
const ERROR_COLOR = RAZZMATAZZ_RED;
|
|
81
|
+
|
|
82
|
+
// These colors are sequestered so that the alert component can reference them // by type of alert
|
|
83
|
+
const ALERT_COLORS = {
|
|
84
|
+
warn: {
|
|
85
|
+
background: APRICOT_ORANGE,
|
|
86
|
+
border: ZEST_ORANGE,
|
|
87
|
+
iconBackground: MUSTARD_YELLOW,
|
|
88
|
+
iconFill: CARROT_ORANGE
|
|
89
|
+
},
|
|
90
|
+
info: {
|
|
91
|
+
background: INFO_BLUE,
|
|
92
|
+
border: CURIOUS_BLUE,
|
|
93
|
+
iconBackground: ONAHAU_BLUE,
|
|
94
|
+
iconFill: CONGRESS_BLUE
|
|
95
|
+
},
|
|
96
|
+
error: {
|
|
97
|
+
background: BLUSH_RED,
|
|
98
|
+
border: RAZZMATAZZ_RED,
|
|
99
|
+
iconBackground: COSMOS_RED,
|
|
100
|
+
iconFill: THUNDERBIRD_RED
|
|
101
|
+
},
|
|
102
|
+
success: {
|
|
103
|
+
background: HINT_GREEN,
|
|
104
|
+
border: EMERALD_GREEN,
|
|
105
|
+
iconBackground: ICE_GREEN,
|
|
106
|
+
iconFill: HAZE_GREEN
|
|
107
|
+
},
|
|
108
|
+
text: ZODIAC_BLUE,
|
|
109
|
+
link: SCIENCE_BLUE
|
|
110
|
+
};
|
|
111
|
+
|
|
112
|
+
export {
|
|
113
|
+
TRANSPARENT,
|
|
114
|
+
WHITE,
|
|
115
|
+
SOLITUDE_WHITE,
|
|
116
|
+
SEASHELL_WHITE,
|
|
117
|
+
ALABASTER_WHITE,
|
|
118
|
+
AQUA_HAZE_WHITE,
|
|
119
|
+
BLEACH_WHITE,
|
|
120
|
+
CATSKILL_WHITE,
|
|
121
|
+
ATHENS_GREY,
|
|
122
|
+
ALTO_GREY,
|
|
123
|
+
SILVER_GREY,
|
|
124
|
+
PEWTER_GREY,
|
|
125
|
+
ASH_GREY,
|
|
126
|
+
IRON_GREY,
|
|
127
|
+
GHOST_GREY,
|
|
128
|
+
DUSTY_GREY,
|
|
129
|
+
REGENT_GREY,
|
|
130
|
+
STORM_GREY,
|
|
131
|
+
TROUT_GREY,
|
|
132
|
+
MINESHAFT_GREY,
|
|
133
|
+
FIREFLY_GREY,
|
|
134
|
+
SOOT_GREY,
|
|
135
|
+
BRIGHT_GREY,
|
|
136
|
+
CHARADE_GREY,
|
|
137
|
+
GRECIAN_GREY,
|
|
138
|
+
BLACK_SQUEEZE,
|
|
139
|
+
GREY_CHATEAU,
|
|
140
|
+
CLOUDBURST_BLUE,
|
|
141
|
+
INFO_BLUE,
|
|
142
|
+
ZODIAC_BLUE,
|
|
143
|
+
CONGRESS_BLUE,
|
|
144
|
+
SCIENCE_BLUE,
|
|
145
|
+
MARINER_BLUE,
|
|
146
|
+
CURIOUS_BLUE,
|
|
147
|
+
SELAGO_BLUE,
|
|
148
|
+
ONAHAU_BLUE,
|
|
149
|
+
PICKLED_BLUE,
|
|
150
|
+
CERULEAN_BLUE,
|
|
151
|
+
FOAM_BLUE,
|
|
152
|
+
CELLO_BLUE,
|
|
153
|
+
BOSTON_BLUE,
|
|
154
|
+
HOVER_LIGHT_BLUE,
|
|
155
|
+
MATISSE_BLUE,
|
|
156
|
+
FOREST_GREEN,
|
|
157
|
+
MEADOW_GREEN,
|
|
158
|
+
POLAR_GREEN,
|
|
159
|
+
ICE_GREEN,
|
|
160
|
+
HAZE_GREEN,
|
|
161
|
+
EMERALD_GREEN,
|
|
162
|
+
HINT_GREEN,
|
|
163
|
+
SEA_GREEN,
|
|
164
|
+
SELECTIVE_YELLOW,
|
|
165
|
+
MUSTARD_YELLOW,
|
|
166
|
+
CARROT_ORANGE,
|
|
167
|
+
ZEST_ORANGE,
|
|
168
|
+
APRICOT_ORANGE,
|
|
169
|
+
RED,
|
|
170
|
+
CRIMSON_RED,
|
|
171
|
+
THUNDERBIRD_RED,
|
|
172
|
+
RAZZMATAZZ_RED,
|
|
173
|
+
FANTASY_RED,
|
|
174
|
+
COSMOS_RED,
|
|
175
|
+
BLUSH_RED,
|
|
176
|
+
ALERT_COLORS,
|
|
177
|
+
ERROR_COLOR
|
|
178
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export const URL_TEST = /(([a-z]{3,6}:\/\/)|(^|\s))([a-zA-Z0-9\-]+\.)+[a-z]{2,13}[\.\?\=\&\%\/\w\-]*\b([^@]|$)/;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/* These are constants used by nav frontend components */
|
|
2
|
+
|
|
3
|
+
const HEADER_HEIGHT = "104px";
|
|
4
|
+
const FOOTER_HEIGHT = "100px";
|
|
5
|
+
const SPACER_HEIGHT = "65px";
|
|
6
|
+
const JUMBO_HEIGHT = "300px";
|
|
7
|
+
const COMPACT_JUMBO_HEIGHT = "65px";
|
|
8
|
+
const FONT_WEIGHT_REGULAR = "400";
|
|
9
|
+
const FONT_WEIGHT_BOLD = "700";
|
|
10
|
+
const FONT_WEIGHT_SEMIBOLD = "600";
|
|
11
|
+
|
|
12
|
+
export {
|
|
13
|
+
HEADER_HEIGHT,
|
|
14
|
+
FOOTER_HEIGHT,
|
|
15
|
+
SPACER_HEIGHT,
|
|
16
|
+
JUMBO_HEIGHT,
|
|
17
|
+
COMPACT_JUMBO_HEIGHT,
|
|
18
|
+
FONT_WEIGHT_REGULAR,
|
|
19
|
+
FONT_WEIGHT_BOLD,
|
|
20
|
+
FONT_WEIGHT_SEMIBOLD
|
|
21
|
+
};
|