@thecb/components 3.5.16 → 3.6.0-beta.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/.storybook/main.js +1 -1
- package/.storybook/page.js +0 -2
- package/dist/index.cjs.js +406 -442
- package/package.json +2 -2
- package/src/components/atoms/alert/Alert.js +34 -50
- package/src/components/atoms/breadcrumb/Breadcrumb.js +1 -4
- package/src/components/atoms/button-with-action/ButtonWithAction.js +1 -1
- package/src/components/atoms/checkbox/Checkbox.js +0 -1
- package/src/components/atoms/checkbox-list/CheckboxList.js +1 -3
- package/src/components/atoms/display-card/DisplayCard.js +2 -4
- package/src/components/atoms/dropdown/Dropdown.js +3 -3
- package/src/components/atoms/dropdown/Dropdown.stories.js +33 -10
- package/src/components/atoms/form-layouts/FormInput.js +7 -27
- package/src/components/atoms/form-layouts/FormLayouts.stories.js +5 -5
- package/src/components/atoms/hamburger-button/HamburgerButton.js +3 -4
- package/src/components/atoms/icons/AccountsIconSmall.js +13 -6
- package/src/components/atoms/icons/icons.stories.js +1 -1
- package/src/components/atoms/layouts/Box.styled.js +0 -1
- package/src/components/atoms/layouts/Cluster.styled.js +1 -5
- package/src/components/atoms/layouts/Cover.styled.js +1 -0
- package/src/components/atoms/layouts/Imposter.styled.js +1 -0
- package/src/components/atoms/layouts/Sidebar.js +2 -2
- package/src/components/atoms/layouts/Sidebar.styled.js +3 -9
- package/src/components/atoms/radio-button/RadioButton.js +0 -1
- package/src/components/atoms/radio-button/RadioButton.stories.js +61 -26
- package/src/components/atoms/toggle-switch/ToggleSwitch.js +0 -1
- package/src/components/atoms/toggle-switch/ToggleSwitch.stories.js +51 -10
- package/src/components/molecules/content/Content.js +20 -0
- package/src/components/molecules/content/Content.theme.js +60 -0
- package/src/components/molecules/content/blocks/accordion-block/AccordionBlock.js +108 -0
- package/src/components/molecules/content/blocks/accordion-block/index.js +3 -0
- package/src/components/molecules/content/blocks/article-block/ArticleBlock.js +58 -0
- package/src/components/molecules/content/blocks/article-block/index.js +3 -0
- package/src/components/molecules/content/blocks/attached-file-block/AttachedFileBlock.js +60 -0
- package/src/components/molecules/content/blocks/attached-file-block/index.js +3 -0
- package/src/components/molecules/content/blocks/featured-content-block/FeaturedContentBlock.js +0 -0
- package/src/components/molecules/content/blocks/featured-content-block/index.js +0 -0
- package/src/components/molecules/content/blocks/hero-block/HeroBlock.js +54 -0
- package/src/components/molecules/content/blocks/hero-block/index.js +3 -0
- package/src/components/molecules/content/blocks/highlight-block/HighlightBlock.js +42 -0
- package/src/components/molecules/content/blocks/highlight-block/index.js +3 -0
- package/src/components/molecules/content/blocks/index.js +33 -0
- package/src/components/molecules/content/blocks/info-block/InfoBlock.js +15 -0
- package/src/components/molecules/content/blocks/info-block/index.js +3 -0
- package/src/components/molecules/content/blocks/location-block/LocationBlock.js +228 -0
- package/src/components/molecules/content/blocks/location-block/index.js +3 -0
- package/src/components/molecules/content/blocks/related-links-block/RelatedLinksBlock.js +35 -0
- package/src/components/molecules/content/blocks/related-links-block/index.js +3 -0
- package/src/components/molecules/content/blocks/screendoor-block/ScreendoorBlock.js +57 -0
- package/src/components/molecules/content/blocks/screendoor-block/ScreendoorForm.styled.js +314 -0
- package/src/components/molecules/content/blocks/screendoor-block/index.js +3 -0
- package/src/components/molecules/content/blocks/tagline-block/TaglineBlock.js +45 -0
- package/src/components/molecules/content/blocks/tagline-block/index.js +3 -0
- package/src/components/molecules/content/blocks/task-block/TaskBlock.js +40 -0
- package/src/components/molecules/content/blocks/task-block/index.js +3 -0
- package/src/components/molecules/content/blocks/text-block/TextBlock.js +40 -0
- package/src/components/molecules/content/blocks/text-block/index.js +3 -0
- package/src/components/molecules/content/header/Header.js +283 -0
- package/src/components/molecules/content/header/Header.theme.js +11 -0
- package/src/components/molecules/content/header/index.js +3 -0
- package/src/components/molecules/content/index.js +3 -0
- package/src/components/molecules/editable-list/EditableList.js +8 -11
- package/src/components/molecules/nav-menu/NavMenuDesktop.js +1 -2
- package/src/components/molecules/nav-menu/NavMenuMobile.js +1 -7
- package/src/components/molecules/radio-section/RadioSection.js +6 -15
- package/src/components/molecules/workflow-tile/WorkflowTile.js +3 -4
- package/src/deprecated/components/radio-button/radio-button.js +1 -5
- package/src/deprecated/icons/AlertSuccessIcon.js +3 -3
- package/src/deprecated/icons/IconInvalid.js +31 -7
- package/src/deprecated/icons/IconNeutral.js +4 -5
- package/src/deprecated/icons/IconValid.js +33 -8
- package/src/util/general.js +1 -10
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
|
|
3
|
+
import {
|
|
4
|
+
Box,
|
|
5
|
+
Stack,
|
|
6
|
+
Cluster,
|
|
7
|
+
Heading,
|
|
8
|
+
Paragraph,
|
|
9
|
+
ButtonWithLink
|
|
10
|
+
} from "@thecb/components";
|
|
11
|
+
import { FONT_WEIGHT_SEMIBOLD } from "../../../../constants/style_constants";
|
|
12
|
+
|
|
13
|
+
const TaskBlock = ({ themeValues, headline, text, callToAction, url }) => (
|
|
14
|
+
<Box
|
|
15
|
+
padding="24px 16px"
|
|
16
|
+
boxShadow={`inset 0px 3px 0px 0px rgb(21, 116, 157),
|
|
17
|
+
0px 2px 4px 0px rgba(41, 42, 51, 0.4);`}
|
|
18
|
+
borderRadius="4px"
|
|
19
|
+
background="#ffffff"
|
|
20
|
+
maxWidth="47.5rem"
|
|
21
|
+
>
|
|
22
|
+
<Stack childGap="1.5rem">
|
|
23
|
+
<Heading
|
|
24
|
+
variant="h3"
|
|
25
|
+
color={themeValues.darkText}
|
|
26
|
+
weight={FONT_WEIGHT_SEMIBOLD}
|
|
27
|
+
>
|
|
28
|
+
{headline}
|
|
29
|
+
</Heading>
|
|
30
|
+
<Paragraph color={themeValues.darkText}>{text}</Paragraph>
|
|
31
|
+
<Box padding="0" minWidth="100%">
|
|
32
|
+
<Cluster justify="flex-end" align="center">
|
|
33
|
+
<ButtonWithLink variant="secondary" url={url} text={callToAction} />
|
|
34
|
+
</Cluster>
|
|
35
|
+
</Box>
|
|
36
|
+
</Stack>
|
|
37
|
+
</Box>
|
|
38
|
+
);
|
|
39
|
+
|
|
40
|
+
export default TaskBlock;
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { Box, Stack, Paragraph } from "@thecb/components";
|
|
3
|
+
|
|
4
|
+
const TextBlock = ({
|
|
5
|
+
themeValues,
|
|
6
|
+
textContent = ""
|
|
7
|
+
//variant = "placeholder"
|
|
8
|
+
}) => {
|
|
9
|
+
const paragraphs =
|
|
10
|
+
textContent
|
|
11
|
+
?.split("\n")
|
|
12
|
+
.filter(string => string !== "")
|
|
13
|
+
.map((string, index) => (
|
|
14
|
+
<Box padding="0">
|
|
15
|
+
<Paragraph
|
|
16
|
+
key={`paragraph-${index}`}
|
|
17
|
+
variant="pL"
|
|
18
|
+
color={themeValues.darkText}
|
|
19
|
+
>
|
|
20
|
+
{string}
|
|
21
|
+
</Paragraph>
|
|
22
|
+
</Box>
|
|
23
|
+
)) ?? [];
|
|
24
|
+
return (
|
|
25
|
+
<Box
|
|
26
|
+
minWidth="100%"
|
|
27
|
+
minHeight="500px"
|
|
28
|
+
padding={"32px 24px"}
|
|
29
|
+
background="white"
|
|
30
|
+
>
|
|
31
|
+
<Stack childGap="24px">
|
|
32
|
+
<Box padding="0">
|
|
33
|
+
<Stack>{paragraphs}</Stack>
|
|
34
|
+
</Box>
|
|
35
|
+
</Stack>
|
|
36
|
+
</Box>
|
|
37
|
+
);
|
|
38
|
+
};
|
|
39
|
+
|
|
40
|
+
export default TextBlock;
|
|
@@ -0,0 +1,283 @@
|
|
|
1
|
+
import React, { useContext, useState, Fragment } from "react";
|
|
2
|
+
import { ThemeContext } from "styled-components";
|
|
3
|
+
import { IoIosArrowRoundForward } from "react-icons/io";
|
|
4
|
+
import {
|
|
5
|
+
Box,
|
|
6
|
+
Cover,
|
|
7
|
+
Cluster,
|
|
8
|
+
Stack,
|
|
9
|
+
Heading,
|
|
10
|
+
Paragraph,
|
|
11
|
+
//Imposter,
|
|
12
|
+
NavHeader,
|
|
13
|
+
//HamburgerButton,
|
|
14
|
+
ExternalLink,
|
|
15
|
+
InternalLink,
|
|
16
|
+
withWindowSize,
|
|
17
|
+
Switcher,
|
|
18
|
+
Motion,
|
|
19
|
+
Center
|
|
20
|
+
} from "@thecb/components";
|
|
21
|
+
import { Helmet } from "react-helmet";
|
|
22
|
+
import { fallbackValues } from "./Header.theme";
|
|
23
|
+
import { themeComponent } from "../../../util/themeUtils";
|
|
24
|
+
//import { URL_TEST } from "../../constants/regex_constants";
|
|
25
|
+
import {
|
|
26
|
+
FONT_WEIGHT_SEMIBOLD,
|
|
27
|
+
FONT_WEIGHT_BOLD
|
|
28
|
+
} from "../../../constants/style_constants";
|
|
29
|
+
|
|
30
|
+
const Header = ({ navigation, title, themeValues }) => {
|
|
31
|
+
const { isMobile } = useContext(ThemeContext);
|
|
32
|
+
const [navMenuOpen, setNavMenuOpen] = useState();
|
|
33
|
+
const [selectedNavMenu, setSelectedMenu] = useState(0);
|
|
34
|
+
const [isAnimating, setIsAnimating] = useState();
|
|
35
|
+
const headerLogoSrc =
|
|
36
|
+
"https://cb-public-assets.s3-us-west-2.amazonaws.com/mgw/water-works.png";
|
|
37
|
+
const headerLogoLink = "/cms/home";
|
|
38
|
+
const favicon =
|
|
39
|
+
"https://cb-public-assets.s3-us-west-2.amazonaws.com/mgw/water-works.ico";
|
|
40
|
+
const HeaderLogoWrapper = ({ children }) =>
|
|
41
|
+
headerLogoLink ? (
|
|
42
|
+
false ? (
|
|
43
|
+
<ExternalLink href={headerLogoLink}>{children}</ExternalLink>
|
|
44
|
+
) : (
|
|
45
|
+
<InternalLink to={headerLogoLink}>{children}</InternalLink>
|
|
46
|
+
)
|
|
47
|
+
) : (
|
|
48
|
+
<Fragment>{children}</Fragment>
|
|
49
|
+
);
|
|
50
|
+
const headerLogo = (
|
|
51
|
+
<HeaderLogoWrapper>
|
|
52
|
+
<Box padding="0" minHeight="100%">
|
|
53
|
+
<Cover singleChild minHeight="100%">
|
|
54
|
+
<Box padding="0">
|
|
55
|
+
<img
|
|
56
|
+
src={headerLogoSrc}
|
|
57
|
+
height={isMobile ? "42px" : themeValues.logoHeight}
|
|
58
|
+
alt="header logo"
|
|
59
|
+
/>
|
|
60
|
+
</Box>
|
|
61
|
+
</Cover>
|
|
62
|
+
</Box>
|
|
63
|
+
</HeaderLogoWrapper>
|
|
64
|
+
);
|
|
65
|
+
|
|
66
|
+
const navLinks = navigation?.sections?.map((link, index) => (
|
|
67
|
+
<Box
|
|
68
|
+
padding="2rem 1.5rem"
|
|
69
|
+
borderColor={navMenuOpen ? themeValues.darkText : "transparent"}
|
|
70
|
+
borderSize="4px"
|
|
71
|
+
borderWidthOverride="0 0 4px 0"
|
|
72
|
+
onClick={() => {
|
|
73
|
+
console.log("i'm getting called!");
|
|
74
|
+
setSelectedMenu(index);
|
|
75
|
+
setNavMenuOpen(!navMenuOpen);
|
|
76
|
+
setIsAnimating(true);
|
|
77
|
+
setTimeout(() => {
|
|
78
|
+
setIsAnimating(false);
|
|
79
|
+
}, 600);
|
|
80
|
+
}}
|
|
81
|
+
onMouseEnter={() => {
|
|
82
|
+
if (navMenuOpen !== true) {
|
|
83
|
+
setSelectedMenu(index);
|
|
84
|
+
setNavMenuOpen(true);
|
|
85
|
+
setIsAnimating(true);
|
|
86
|
+
setTimeout(() => {
|
|
87
|
+
setIsAnimating(false);
|
|
88
|
+
}, 600);
|
|
89
|
+
} else if (selectedNavMenu !== index) {
|
|
90
|
+
setSelectedMenu(index);
|
|
91
|
+
}
|
|
92
|
+
}}
|
|
93
|
+
>
|
|
94
|
+
<Heading variant="h5" color={themeValues.darkText}>
|
|
95
|
+
{link?.name}
|
|
96
|
+
</Heading>
|
|
97
|
+
</Box>
|
|
98
|
+
));
|
|
99
|
+
|
|
100
|
+
const navLinksContainer = (
|
|
101
|
+
<Box padding="0" minWidth="100%">
|
|
102
|
+
<Cluster justify="space-between" align="stretch">
|
|
103
|
+
<Box padding="1.5rem">{headerLogo}</Box>
|
|
104
|
+
{navLinks}
|
|
105
|
+
</Cluster>
|
|
106
|
+
</Box>
|
|
107
|
+
);
|
|
108
|
+
console.log("navigation in header is", navigation);
|
|
109
|
+
const navItems =
|
|
110
|
+
navigation?.sections?.map(section => (
|
|
111
|
+
<Fragment key={section?.id}>
|
|
112
|
+
<Box key="title-desc" padding="0">
|
|
113
|
+
<Stack>
|
|
114
|
+
<Box padding="0">
|
|
115
|
+
<Cluster justify="flex-start" align="center">
|
|
116
|
+
<Heading
|
|
117
|
+
variant="h4"
|
|
118
|
+
color={themeValues.darkText}
|
|
119
|
+
weight={FONT_WEIGHT_BOLD}
|
|
120
|
+
>
|
|
121
|
+
{section?.name}
|
|
122
|
+
</Heading>
|
|
123
|
+
<Box padding="0 8px" extraStyles={`margin-top: 8px;`}>
|
|
124
|
+
<IoIosArrowRoundForward
|
|
125
|
+
size="29px"
|
|
126
|
+
color={themeValues.darkText}
|
|
127
|
+
/>
|
|
128
|
+
</Box>
|
|
129
|
+
</Cluster>
|
|
130
|
+
</Box>
|
|
131
|
+
<Box padding="0">
|
|
132
|
+
<Paragraph>{section?.description}</Paragraph>
|
|
133
|
+
</Box>
|
|
134
|
+
</Stack>
|
|
135
|
+
</Box>
|
|
136
|
+
<Box key="linked-items" padding="0" minWidth="70%">
|
|
137
|
+
<Cluster justify="space-around" align="stretch">
|
|
138
|
+
{section?.linkLists?.map(linkList => (
|
|
139
|
+
<Box padding="0" extraStyles={`flex: 1;`}>
|
|
140
|
+
<Stack>
|
|
141
|
+
<Cluster justify="flex-start" align="center">
|
|
142
|
+
<Heading
|
|
143
|
+
variant="h4"
|
|
144
|
+
color={themeValues.darkText}
|
|
145
|
+
weight={FONT_WEIGHT_BOLD}
|
|
146
|
+
>
|
|
147
|
+
{linkList?.name}
|
|
148
|
+
</Heading>
|
|
149
|
+
<Box padding="0 8px" extraStyles={`margin-top: 8px;`}>
|
|
150
|
+
<IoIosArrowRoundForward
|
|
151
|
+
size="29px"
|
|
152
|
+
color={themeValues.darkText}
|
|
153
|
+
/>
|
|
154
|
+
</Box>
|
|
155
|
+
</Cluster>
|
|
156
|
+
<Box padding="24px 0">
|
|
157
|
+
<Stack>
|
|
158
|
+
{linkList?.links?.map(link => (
|
|
159
|
+
<Box padding="0">
|
|
160
|
+
<InternalLink to={link.externalUrl}>
|
|
161
|
+
<Paragraph color={themeValues.darkText}>
|
|
162
|
+
{link.text}
|
|
163
|
+
</Paragraph>
|
|
164
|
+
</InternalLink>
|
|
165
|
+
</Box>
|
|
166
|
+
))}
|
|
167
|
+
</Stack>
|
|
168
|
+
</Box>
|
|
169
|
+
</Stack>
|
|
170
|
+
</Box>
|
|
171
|
+
))}
|
|
172
|
+
<Box padding="0" key="featured-items" extraStyles={`flex: 1;`}>
|
|
173
|
+
<Stack>
|
|
174
|
+
<Heading
|
|
175
|
+
variant="h4"
|
|
176
|
+
weight={FONT_WEIGHT_BOLD}
|
|
177
|
+
color={themeValues.darkText}
|
|
178
|
+
>
|
|
179
|
+
Featured Items
|
|
180
|
+
</Heading>
|
|
181
|
+
{section?.featuredLinks?.links?.map(feat => (
|
|
182
|
+
<Box padding="0" minWidth="100%">
|
|
183
|
+
<Cluster justify="space-between" align="center">
|
|
184
|
+
<InternalLink to={feat.url}>
|
|
185
|
+
<Cluster justify="flex-start" align="center">
|
|
186
|
+
<Heading
|
|
187
|
+
variant="h6"
|
|
188
|
+
weight={FONT_WEIGHT_SEMIBOLD}
|
|
189
|
+
color={themeValues.darkText}
|
|
190
|
+
>
|
|
191
|
+
{feat.text}
|
|
192
|
+
</Heading>
|
|
193
|
+
<Box padding="0 8px" extraStyles={`margin-top: 8px;`}>
|
|
194
|
+
<IoIosArrowRoundForward
|
|
195
|
+
size="29px"
|
|
196
|
+
color={themeValues.darkText}
|
|
197
|
+
/>
|
|
198
|
+
</Box>
|
|
199
|
+
</Cluster>
|
|
200
|
+
</InternalLink>
|
|
201
|
+
</Cluster>
|
|
202
|
+
</Box>
|
|
203
|
+
))}
|
|
204
|
+
</Stack>
|
|
205
|
+
</Box>
|
|
206
|
+
</Cluster>
|
|
207
|
+
</Box>
|
|
208
|
+
</Fragment>
|
|
209
|
+
)) ?? [];
|
|
210
|
+
|
|
211
|
+
const menuWrapper = {
|
|
212
|
+
open: {
|
|
213
|
+
top: "0px",
|
|
214
|
+
transition: {
|
|
215
|
+
duration: 0.5
|
|
216
|
+
}
|
|
217
|
+
},
|
|
218
|
+
closed: {
|
|
219
|
+
top: "-500px",
|
|
220
|
+
transition: {
|
|
221
|
+
duration: 0.5
|
|
222
|
+
}
|
|
223
|
+
}
|
|
224
|
+
};
|
|
225
|
+
console.log("nav items are", navItems);
|
|
226
|
+
const menu = (
|
|
227
|
+
<Motion
|
|
228
|
+
padding="0"
|
|
229
|
+
variants={menuWrapper}
|
|
230
|
+
animate={navMenuOpen ? "open" : "closed"}
|
|
231
|
+
extraStyles={`position: absolute; z-index: 3;`}
|
|
232
|
+
positionTransition
|
|
233
|
+
minWidth="100%"
|
|
234
|
+
>
|
|
235
|
+
<Box
|
|
236
|
+
minWidth="100%"
|
|
237
|
+
background={themeValues.menuColor}
|
|
238
|
+
padding="0"
|
|
239
|
+
minHeight="29rem"
|
|
240
|
+
onMouseLeave={() => {
|
|
241
|
+
if (isAnimating === false) {
|
|
242
|
+
setNavMenuOpen(false);
|
|
243
|
+
}
|
|
244
|
+
}}
|
|
245
|
+
>
|
|
246
|
+
<Center maxWidth={isMobile ? "100%" : "76.5rem"} intrinsic={!isMobile}>
|
|
247
|
+
<Cluster justify="center" align="center" minWidth="100%">
|
|
248
|
+
<Box minHeight="29rem" padding="24px 0">
|
|
249
|
+
<Switcher breakpoint="45rem" largeChild="4" largeChildSize="2">
|
|
250
|
+
{navItems[selectedNavMenu]}
|
|
251
|
+
</Switcher>
|
|
252
|
+
</Box>
|
|
253
|
+
</Cluster>
|
|
254
|
+
</Center>
|
|
255
|
+
</Box>
|
|
256
|
+
</Motion>
|
|
257
|
+
);
|
|
258
|
+
console.log("navMenuOpen is....", navMenuOpen);
|
|
259
|
+
return (
|
|
260
|
+
<Box padding="0" role="banner">
|
|
261
|
+
<Helmet>
|
|
262
|
+
<title>{title.text}</title>
|
|
263
|
+
<link rel="shortcut icon" href={favicon} />
|
|
264
|
+
</Helmet>
|
|
265
|
+
<Box
|
|
266
|
+
padding="0"
|
|
267
|
+
extraStyles={`z-index: 25;`}
|
|
268
|
+
boxShadow={`0px 4px 2px 0px rgba(0, 0, 0, 0.19);`}
|
|
269
|
+
>
|
|
270
|
+
<NavHeader
|
|
271
|
+
backgroundColor={"#FFFFFF"}
|
|
272
|
+
leftContent={navLinksContainer}
|
|
273
|
+
isMobile={isMobile}
|
|
274
|
+
/>
|
|
275
|
+
</Box>
|
|
276
|
+
<Box padding="0" minWidth="100%">
|
|
277
|
+
{menu}
|
|
278
|
+
</Box>
|
|
279
|
+
</Box>
|
|
280
|
+
);
|
|
281
|
+
};
|
|
282
|
+
|
|
283
|
+
export default withWindowSize(themeComponent(Header, "Header", fallbackValues));
|
|
@@ -55,25 +55,24 @@ const EditableList = ({
|
|
|
55
55
|
extraStyles={`box-shadow: 0px 2px 14px 0px rgb(246, 246, 249),
|
|
56
56
|
0px 3px 8px 0px rgb(202, 206, 216);`}
|
|
57
57
|
>
|
|
58
|
-
{items.map(
|
|
58
|
+
{items.map(props => {
|
|
59
59
|
const [modalOpen, toggleModal] = useState(false);
|
|
60
60
|
return (
|
|
61
61
|
<EditableListItem
|
|
62
62
|
listItemSize={
|
|
63
|
-
!!
|
|
63
|
+
!!props.id && props.id === autoPayMethod ? "big" : listItemSize
|
|
64
64
|
}
|
|
65
|
-
key={
|
|
65
|
+
key={props.id}
|
|
66
66
|
>
|
|
67
67
|
<Text variant="p" color={CHARADE_GREY}>
|
|
68
|
-
{renderItem(
|
|
68
|
+
{renderItem(props)}
|
|
69
69
|
</Text>
|
|
70
70
|
<EditableListItemControls>
|
|
71
|
-
{
|
|
71
|
+
{props.isPrimary && (
|
|
72
72
|
<Text
|
|
73
73
|
variant="p"
|
|
74
74
|
color={STORM_GREY}
|
|
75
75
|
extraStyles={`font-style: italic;`}
|
|
76
|
-
key={`Default ${itemName}`}
|
|
77
76
|
>
|
|
78
77
|
Default {itemName}
|
|
79
78
|
</Text>
|
|
@@ -84,11 +83,10 @@ const EditableList = ({
|
|
|
84
83
|
border="2px solid transparent"
|
|
85
84
|
extraStyles={`:not(:first-child) { border-left: 2px solid ${BOSTON_BLUE};}`}
|
|
86
85
|
dataQa={qaPrefix + " Remove"}
|
|
87
|
-
key={`Remove ${item.id}`}
|
|
88
86
|
>
|
|
89
87
|
{useModal ? (
|
|
90
88
|
<Modal
|
|
91
|
-
item={{ ...
|
|
89
|
+
item={{ ...props }}
|
|
92
90
|
{...modalProps}
|
|
93
91
|
modalOpen={modalOpen}
|
|
94
92
|
toggleModal={toggleModal}
|
|
@@ -97,7 +95,7 @@ const EditableList = ({
|
|
|
97
95
|
<ButtonWithAction
|
|
98
96
|
variant="smallGhost"
|
|
99
97
|
text="Remove"
|
|
100
|
-
action={() => removeItem(
|
|
98
|
+
action={() => removeItem(props.id)}
|
|
101
99
|
extraStyles={`min-width: 0;`}
|
|
102
100
|
/>
|
|
103
101
|
)}
|
|
@@ -109,12 +107,11 @@ const EditableList = ({
|
|
|
109
107
|
border="2px solid transparent"
|
|
110
108
|
extraStyles={`:not(:first-child) { border-left: 2px solid ${BOSTON_BLUE};}`}
|
|
111
109
|
dataQa={qaPrefix + " Edit"}
|
|
112
|
-
key={`Edit ${item.id}`}
|
|
113
110
|
>
|
|
114
111
|
<ButtonWithAction
|
|
115
112
|
variant="smallGhost"
|
|
116
113
|
text="Edit"
|
|
117
|
-
action={() => editItem(
|
|
114
|
+
action={() => editItem(props.id)}
|
|
118
115
|
extraStyles={`min-width: 0;`}
|
|
119
116
|
/>
|
|
120
117
|
</Box>
|
|
@@ -4,7 +4,6 @@ import { fallbackValues } from "./NavMenu.theme.js";
|
|
|
4
4
|
import { themeComponent } from "../../../util/themeUtils";
|
|
5
5
|
|
|
6
6
|
const NavMenuDesktop = ({
|
|
7
|
-
id,
|
|
8
7
|
top = "125%",
|
|
9
8
|
left = "-100%",
|
|
10
9
|
menuContent = [],
|
|
@@ -18,7 +17,7 @@ const NavMenuDesktop = ({
|
|
|
18
17
|
const menuCarat = `&:after { bottom: 100%; right: 10px; border: solid transparent; content: " "; height: 0; width: 0; position: absolute; pointer-events: none; border-color: ${themeValues.backgroundColor}00; border-bottom-color: ${themeValues.backgroundColor}; border-width: 10px; margin-left: -10px; }`;
|
|
19
18
|
|
|
20
19
|
return (
|
|
21
|
-
<Imposter
|
|
20
|
+
<Imposter breakout top={top} left={left} visible={visible}>
|
|
22
21
|
<Box
|
|
23
22
|
minWidth="240px"
|
|
24
23
|
padding="1rem 0.5rem"
|
|
@@ -42,15 +42,9 @@ const ImposterMenu = styled(menu)`
|
|
|
42
42
|
top: 72px;
|
|
43
43
|
`;
|
|
44
44
|
|
|
45
|
-
const NavMenuMobile = ({
|
|
46
|
-
id,
|
|
47
|
-
menuContent = [],
|
|
48
|
-
visible = false,
|
|
49
|
-
themeValues
|
|
50
|
-
}) => {
|
|
45
|
+
const NavMenuMobile = ({ menuContent = [], visible = false, themeValues }) => {
|
|
51
46
|
return (
|
|
52
47
|
<ImposterMenu
|
|
53
|
-
id={id}
|
|
54
48
|
initialPose="invisible"
|
|
55
49
|
pose={visible ? "visible" : "invisible"}
|
|
56
50
|
>
|
|
@@ -122,12 +122,12 @@ const RadioSection = ({
|
|
|
122
122
|
: themeValues.headingBackgroundColor
|
|
123
123
|
}
|
|
124
124
|
onClick={
|
|
125
|
-
|
|
125
|
+
isMobile && supportsTouch
|
|
126
126
|
? noop
|
|
127
127
|
: () => toggleOpenSection(section.id)
|
|
128
128
|
}
|
|
129
129
|
onTouchEnd={
|
|
130
|
-
|
|
130
|
+
isMobile && supportsTouch
|
|
131
131
|
? () => toggleOpenSection(section.id)
|
|
132
132
|
: noop
|
|
133
133
|
}
|
|
@@ -155,23 +155,14 @@ const RadioSection = ({
|
|
|
155
155
|
name={section.id}
|
|
156
156
|
radioOn={openSection === section.id}
|
|
157
157
|
radioFocused={focused === section.id}
|
|
158
|
-
toggleRadio={
|
|
159
|
-
section.disabled
|
|
160
|
-
? noop
|
|
161
|
-
: () => toggleOpenSection(section.id)
|
|
162
|
-
}
|
|
158
|
+
toggleRadio={() => toggleOpenSection(section.id)}
|
|
163
159
|
tabIndex="-1"
|
|
164
160
|
/>
|
|
165
161
|
</Box>
|
|
166
162
|
)}
|
|
167
|
-
{
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
<Box padding={section.titleIcon ? "0 0 0 8px" : "0"}>
|
|
171
|
-
<Text variant="p" color={CHARADE_GREY} aria-level="3">
|
|
172
|
-
{section.title}
|
|
173
|
-
</Text>
|
|
174
|
-
</Box>
|
|
163
|
+
<Text variant="p" color={CHARADE_GREY} aria-level="3">
|
|
164
|
+
{section.title}
|
|
165
|
+
</Text>
|
|
175
166
|
</Cluster>
|
|
176
167
|
{section.rightIcons && (
|
|
177
168
|
<Cluster childGap="0.5rem">
|
|
@@ -14,8 +14,7 @@ import ButtonWithLink from "../../atoms/button-with-link";
|
|
|
14
14
|
import { Box, Stack } from "../../atoms/layouts";
|
|
15
15
|
const WorkflowTile = ({
|
|
16
16
|
workflowName = "Test Workflow",
|
|
17
|
-
workflowDescription
|
|
18
|
-
workflowActionName = "Search",
|
|
17
|
+
workflowDescription,
|
|
19
18
|
slug
|
|
20
19
|
}) => (
|
|
21
20
|
<Box
|
|
@@ -36,7 +35,7 @@ const WorkflowTile = ({
|
|
|
36
35
|
</Box>
|
|
37
36
|
<Box padding={"0 1rem 1rem 1rem"} minHeight={"4.25rem"}>
|
|
38
37
|
<Paragraph variant="pS" color={STORM_GREY}>
|
|
39
|
-
{workflowDescription}
|
|
38
|
+
{workflowDescription || `Link your benefit plan`}
|
|
40
39
|
</Paragraph>
|
|
41
40
|
</Box>
|
|
42
41
|
<Box padding={"1.5rem 1rem"} background={GRECIAN_GREY}>
|
|
@@ -46,7 +45,7 @@ const WorkflowTile = ({
|
|
|
46
45
|
fontWeight={FONT_WEIGHT_SEMIBOLD}
|
|
47
46
|
fontSize={"1.125rem"}
|
|
48
47
|
borderRadius={"0px"}
|
|
49
|
-
text={
|
|
48
|
+
text={"Link Benefits"}
|
|
50
49
|
minWidth={"100%"}
|
|
51
50
|
url={`/service/${slug}`}
|
|
52
51
|
extraStyles={`width: 100%;`}
|
|
@@ -36,11 +36,7 @@ const RadioButtonCenter = styled.div`
|
|
|
36
36
|
RadioButtonCenter.defaultProps = defaultTheme;
|
|
37
37
|
|
|
38
38
|
const RadioButton = ({ isSelected, name }) => (
|
|
39
|
-
<RadioButtonBorder
|
|
40
|
-
isSelected={isSelected}
|
|
41
|
-
name={name}
|
|
42
|
-
aria-checked={isSelected}
|
|
43
|
-
>
|
|
39
|
+
<RadioButtonBorder isSelected={isSelected} name={name}>
|
|
44
40
|
{isSelected && <RadioButtonCenter />}
|
|
45
41
|
</RadioButtonBorder>
|
|
46
42
|
);
|
|
@@ -11,7 +11,7 @@ export const AlertSuccessIcon = () => (
|
|
|
11
11
|
<defs>
|
|
12
12
|
<path
|
|
13
13
|
d="M12,24 C18.627417,24 24,18.627417 24,12 C24,5.372583 18.627417,0 12,0 C5.372583,0 0,5.372583 0,12 C0,18.627417 5.372583,24 12,24 Z M16.9497475,7.46446609 L18.363961,8.87867966 L9.87867966,17.363961 L5.63603897,13.1213203 L7.05025253,11.7071068 L9.87803897,14.5354661 L16.9497475,7.46446609 Z"
|
|
14
|
-
id="
|
|
14
|
+
id="path-1"
|
|
15
15
|
></path>
|
|
16
16
|
</defs>
|
|
17
17
|
<g
|
|
@@ -27,13 +27,13 @@ export const AlertSuccessIcon = () => (
|
|
|
27
27
|
transform="translate(24.000000, 34.000000)"
|
|
28
28
|
>
|
|
29
29
|
<mask id="mask-2" fill="white">
|
|
30
|
-
<use xlinkHref="#
|
|
30
|
+
<use xlinkHref="#path-1"></use>
|
|
31
31
|
</mask>
|
|
32
32
|
<use
|
|
33
33
|
id="background-2"
|
|
34
34
|
fill="#47B872"
|
|
35
35
|
fillRule="nonzero"
|
|
36
|
-
xlinkHref="#
|
|
36
|
+
xlinkHref="#path-1"
|
|
37
37
|
></use>
|
|
38
38
|
</g>
|
|
39
39
|
</g>
|
|
@@ -16,23 +16,47 @@ export const IconInvalid = ({
|
|
|
16
16
|
xmlns="http://www.w3.org/2000/svg"
|
|
17
17
|
xmlnsXlink="http://www.w3.org/1999/xlink"
|
|
18
18
|
style={{ margin }}
|
|
19
|
-
aria-label="Invalid"
|
|
20
19
|
>
|
|
21
|
-
<g
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
20
|
+
<g
|
|
21
|
+
id="icon-invalid-Authentication"
|
|
22
|
+
stroke="none"
|
|
23
|
+
strokeWidth="1"
|
|
24
|
+
fill="none"
|
|
25
|
+
fillRule="evenodd"
|
|
26
|
+
>
|
|
27
|
+
<g
|
|
28
|
+
id="icon-invalid-00.1.0.1---HSS---Register---Already-Exists-Error"
|
|
29
|
+
transform="translate(-538.000000, -1064.000000)"
|
|
30
|
+
fillRule="nonzero"
|
|
31
|
+
>
|
|
32
|
+
<g
|
|
33
|
+
id="icon-invalid-Password-Requirements"
|
|
34
|
+
transform="translate(457.000000, 938.000000)"
|
|
35
|
+
>
|
|
36
|
+
<g
|
|
37
|
+
id="icon-invalid-Group-2"
|
|
38
|
+
transform="translate(81.000000, 20.000000)"
|
|
39
|
+
>
|
|
40
|
+
<g
|
|
41
|
+
id="icon-invalid-PasswordVerification-Error"
|
|
42
|
+
transform="translate(0.000000, 106.000000)"
|
|
43
|
+
>
|
|
26
44
|
<circle
|
|
45
|
+
id="icon-invalid-Oval"
|
|
27
46
|
stroke={bgFill}
|
|
28
47
|
fill={bgFill}
|
|
29
48
|
cx="9"
|
|
30
49
|
cy="9"
|
|
31
50
|
r="8.5"
|
|
32
51
|
></circle>
|
|
33
|
-
<g
|
|
52
|
+
<g
|
|
53
|
+
id="icon-invalid-Icon/Close"
|
|
54
|
+
transform="translate(2.000000, 2.000000)"
|
|
55
|
+
fill={iconFill}
|
|
56
|
+
>
|
|
34
57
|
<path
|
|
35
58
|
d="M7.58333333,7.58333333 L7.58333333,11.6666667 L6.41666667,11.6666667 L6.41666667,7.58333333 L2.33333333,7.58333333 L2.33333333,6.41666667 L6.41666667,6.41666667 L6.41666667,2.33333333 L7.58333333,2.33333333 L7.58333333,6.41666667 L11.6666667,6.41666667 L11.6666667,7.58333333 L7.58333333,7.58333333 Z"
|
|
59
|
+
id="icon-invalid-x"
|
|
36
60
|
transform="translate(7.000000, 7.000000) rotate(45.000000) translate(-7.000000, -7.000000) "
|
|
37
61
|
></path>
|
|
38
62
|
</g>
|