@thecb/components 10.3.2-beta.1 → 10.3.3-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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@thecb/components",
3
- "version": "10.3.2-beta.1",
3
+ "version": "10.3.3-beta.0",
4
4
  "description": "Common lib for CityBase react components",
5
5
  "main": "dist/index.cjs.js",
6
6
  "typings": "dist/index.d.ts",
package/src/.DS_Store CHANGED
Binary file
@@ -46,8 +46,7 @@ const Modal = ({
46
46
  buttonExtraStyles,
47
47
  children,
48
48
  dataQa = null,
49
- initialFocusSelector = "",
50
- blurUnderlay = true
49
+ initialFocusSelector = ""
51
50
  }) => {
52
51
  const { isMobile } = useContext(ThemeContext);
53
52
  const modalContainerRef = useRef(null);
@@ -67,10 +66,7 @@ const Modal = ({
67
66
  display: "flex",
68
67
  flexDirection: "column",
69
68
  justifyContent: "center",
70
- alignItems: "center",
71
- background: "rgba(41, 42, 51, 0.45)",
72
- backdropFilter: blurUnderlay ? "blur(4px)" : "none",
73
- WebkitBackdropFilter: blurUnderlay ? "blur(4px)" : "none"
69
+ alignItems: "center"
74
70
  }}
75
71
  dialogStyle={{
76
72
  width: customWidth || "615px",
@@ -35,7 +35,6 @@ export const modal = () => (
35
35
  defaultWrapper={boolean("defaultWrapper", true, groupId)}
36
36
  onlyCloseButton={boolean("onlyCloseButton", false, groupId)}
37
37
  maxHeight={text("maxHeight", null, groupId)}
38
- blurUnderlay={boolean("blurUnderlay", true, groupId)}
39
38
  />
40
39
  );
41
40
 
@@ -81,7 +80,6 @@ export const modalWithoutButtons = () => {
81
80
  defaultWrapper={boolean("defaultWrapper", true, groupId)}
82
81
  noButtons={boolean("noButtons", true, groupId)}
83
82
  maxHeight={text("maxHeight", null, groupId)}
84
- blurUnderlay={boolean("blurUnderlay", false, groupId)}
85
83
  />
86
84
  );
87
85
  };
@@ -13,7 +13,8 @@ import Title from "../../atoms/title";
13
13
  import SolidDivider from "../../atoms/solid-divider";
14
14
  import {
15
15
  FONT_WEIGHT_BOLD,
16
- FONT_WEIGHT_REGULAR
16
+ FONT_WEIGHT_REGULAR,
17
+ FONT_WEIGHT_SEMIBOLD
17
18
  } from "../../../constants/style_constants";
18
19
  import { ATHENS_GREY } from "../../../constants/colors";
19
20
  import ButtonWithAction from "../../atoms/button-with-action";
@@ -255,7 +256,9 @@ const PaymentDetails = ({
255
256
  remainingBalance = false,
256
257
  // end partial void section
257
258
  isLoading = false,
258
- isError = false
259
+ isError = false,
260
+ multiCartEnabled,
261
+ agencyDisplayName
259
262
  }) => {
260
263
  const [isOpen, setIsOpen] = useState(initiallyOpen);
261
264
  const fees = _fees
@@ -345,15 +348,28 @@ const PaymentDetails = ({
345
348
  </Cluster>
346
349
  </Box>
347
350
  ) : (
348
- <Title
349
- as="h2"
350
- weight={FONT_WEIGHT_BOLD}
351
- margin="1rem 0 0 0"
352
- extraStyles={`font-size: 1.75rem;`}
353
- id="payment-details-title"
354
- >
355
- {titleText}
356
- </Title>
351
+ <Box width="100%" padding="none">
352
+ <Cluster justify="space-between" align="center">
353
+ <Title
354
+ as="h2"
355
+ weight={FONT_WEIGHT_BOLD}
356
+ margin="1rem 0 0 0"
357
+ extraStyles={`font-size: 1.75rem;`}
358
+ id="payment-details-title"
359
+ >
360
+ {titleText} HERE
361
+ </Title>
362
+ {multiCartEnabled && (
363
+ <Title
364
+ weight={FONT_WEIGHT_SEMIBOLD}
365
+ as="h3"
366
+ extraStyles={`font-size: 1.375rem;`}
367
+ >
368
+ {agencyDisplayName}
369
+ </Title>
370
+ )}
371
+ </Cluster>
372
+ </Box>
357
373
  );
358
374
  return isCollapsible ? (
359
375
  <Collapsible
@@ -7,8 +7,7 @@ import {
7
7
  hasLowercaseLetter,
8
8
  hasUppercaseLetter,
9
9
  hasSpecialCharacter,
10
- isProbablyEmail,
11
- matchesRegex
10
+ isProbablyEmail
12
11
  } from "redux-freeform";
13
12
  import PasswordRequirements from "../../atoms/password-requirements";
14
13
  import { Box } from "../../atoms/layouts";
@@ -27,12 +26,10 @@ const RegistrationForm = ({
27
26
  useEffect(() => () => actions.form.clear(), []);
28
27
  }
29
28
  const firstNameErrorMessages = {
30
- [required.error]: "First name is required",
31
- [matchesRegex.error]: "First name contains invalid characters"
29
+ [required.error]: "First name is required"
32
30
  };
33
31
  const lastNameErrorMessages = {
34
- [required.error]: "Last name is required",
35
- [matchesRegex.error]: "Last name contains invalid characters"
32
+ [required.error]: "Last name is required"
36
33
  };
37
34
  const emailErrorMessages = {
38
35
  [required.error]: "Email is required",
@@ -7,16 +7,15 @@ import {
7
7
  hasLowercaseLetter,
8
8
  hasUppercaseLetter,
9
9
  hasSpecialCharacter,
10
- isProbablyEmail,
11
- matchesRegex
10
+ isProbablyEmail
12
11
  } from "redux-freeform";
13
12
 
14
13
  const formConfig = {
15
14
  firstName: {
16
- validators: [required(), matchesRegex(/[A-Za-z]+(\s?[A-Za-z\-,'])*/i)]
15
+ validators: [required()]
17
16
  },
18
17
  lastName: {
19
- validators: [required(), matchesRegex(/[A-Za-z]+(\s?[A-Za-z\-,'])*/i)]
18
+ validators: [required()]
20
19
  },
21
20
  email: {
22
21
  validators: [required(), isProbablyEmail()]