@thecb/components 10.2.4-beta.8 → 10.3.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.
Files changed (57) hide show
  1. package/README.md +2 -2
  2. package/dist/index.cjs.js +588 -273
  3. package/dist/index.cjs.js.map +1 -1
  4. package/dist/index.d.ts +64 -1
  5. package/dist/index.esm.js +584 -272
  6. package/dist/index.esm.js.map +1 -1
  7. package/package.json +1 -1
  8. package/src/components/atoms/badge/Badge.stories.js +1 -2
  9. package/src/components/atoms/badge/Badge.theme.js +4 -8
  10. package/src/components/atoms/breadcrumb/Breadcrumb.js +4 -3
  11. package/src/components/atoms/breadcrumb/Breadcrumb.theme.js +5 -2
  12. package/src/components/atoms/button-with-action/ButtonWithAction.js +6 -14
  13. package/src/components/atoms/button-with-action/ButtonWithAction.stories.js +0 -1
  14. package/src/components/atoms/button-with-action/ButtonWithAction.theme.js +37 -33
  15. package/src/components/atoms/button-with-link/ButtonWithLink.js +2 -2
  16. package/src/components/atoms/form-layouts/FormInput.js +1 -1
  17. package/src/components/atoms/icons/CloseIcon.d.ts +1 -0
  18. package/src/components/atoms/icons/CloseIcon.js +48 -0
  19. package/src/components/atoms/icons/TrashIconV2.d.ts +1 -0
  20. package/src/components/atoms/icons/TrashIconV2.js +41 -0
  21. package/src/components/atoms/icons/icons.stories.js +5 -1
  22. package/src/components/atoms/icons/index.d.ts +2 -0
  23. package/src/components/atoms/icons/index.js +5 -1
  24. package/src/components/atoms/layouts/Box.js +0 -1
  25. package/src/components/atoms/layouts/examples/box-example/BoxExample.stories.js +1 -2
  26. package/src/components/atoms/link/ExternalLink.styled.js +6 -3
  27. package/src/components/atoms/link/InternalLink.styled.js +6 -3
  28. package/src/components/atoms/placeholder/Placeholder.js +74 -87
  29. package/src/components/atoms/placeholder/Placeholder.stories.js +9 -22
  30. package/src/components/atoms/text/Text.styled.js +1 -0
  31. package/src/components/molecules/account-and-routing-modal/AccountAndRoutingModal.js +1 -0
  32. package/src/components/molecules/account-and-routing-modal/AccountAndRoutingModal.stories.js +41 -0
  33. package/src/components/molecules/account-and-routing-modal/AccountAndRoutingModal.theme.js +10 -2
  34. package/src/components/molecules/index.d.ts +1 -0
  35. package/src/components/molecules/index.js +1 -0
  36. package/src/components/molecules/link-card/LinkCard.js +2 -5
  37. package/src/components/molecules/link-card/LinkCard.stories.js +34 -62
  38. package/src/components/molecules/link-card/LinkCard.theme.js +5 -19
  39. package/src/components/molecules/obligation/Obligation.js +1 -4
  40. package/src/components/molecules/obligation/modules/AutopayModalModule.js +1 -4
  41. package/src/components/molecules/obligation/modules/PaymentDetailsActions.js +1 -5
  42. package/src/components/molecules/pagination/Pagination.js +1 -7
  43. package/src/components/molecules/pagination/Pagination.stories.js +32 -0
  44. package/src/components/molecules/pagination/Pagination.theme.js +1 -2
  45. package/src/components/molecules/tab-sidebar/TabSidebar.js +2 -2
  46. package/src/components/molecules/terms-and-conditions-modal/TermsAndConditionsModal.js +1 -0
  47. package/src/components/molecules/terms-and-conditions-modal/TermsAndConditionsModal.theme.js +10 -2
  48. package/src/components/templates/default-page-template/DefaultPageTemplate.js +3 -2
  49. package/src/constants/index.d.ts +2 -1
  50. package/src/constants/index.js +12 -3
  51. package/src/constants/style_constants.d.ts +11 -0
  52. package/src/constants/style_constants.js +3 -1
  53. package/dist/src/apps/checkout/pages/payment/sub-pages/payment-amount/PaymentAmount_old.js +0 -49322
  54. package/src/.DS_Store +0 -0
  55. package/src/components/.DS_Store +0 -0
  56. package/src/components/atoms/.DS_Store +0 -0
  57. package/src/components/atoms/icons/.DS_Store +0 -0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@thecb/components",
3
- "version": "10.2.4-beta.8",
3
+ "version": "10.3.0",
4
4
  "description": "Common lib for CityBase react components",
5
5
  "main": "dist/index.cjs.js",
6
6
  "typings": "dist/index.d.ts",
@@ -9,8 +9,7 @@ const variants = {
9
9
  info: "info",
10
10
  warn: "warn",
11
11
  primary: "primary",
12
- success: "success",
13
- disabled: "disabled"
12
+ success: "success"
14
13
  };
15
14
 
16
15
  const defaultValue = "success";
@@ -1,6 +1,4 @@
1
1
  import {
2
- MANATEE_GREY,
3
- GRECIAN_GREY,
4
2
  CORNFLOWER_BLUE,
5
3
  HALF_COLONIAL_WHITE,
6
4
  HINT_GREEN,
@@ -15,19 +13,17 @@ const background = {
15
13
  info: `${INFO_BLUE}`,
16
14
  warn: `${HALF_COLONIAL_WHITE}`,
17
15
  primary: `${CORNFLOWER_BLUE}`,
18
- success: `${HINT_GREEN}`,
19
- disabled: `${GRECIAN_GREY}`
16
+ success: `${HINT_GREEN}`
20
17
  };
21
18
 
22
19
  const color = {
23
20
  info: `${MATISSE_BLUE}`,
24
21
  warn: `${ZEST_ORANGE}`,
25
22
  primary: `${ROYAL_BLUE_VIVID}`,
26
- success: `${SEA_GREEN}`,
27
- disabled: `${MANATEE_GREY}`
23
+ success: `${SEA_GREEN}`
28
24
  };
29
25
 
30
26
  export const fallbackValues = {
31
- background: background,
32
- color: color
27
+ background,
28
+ color
33
29
  };
@@ -33,15 +33,16 @@ const Breadcrumbs = ({ breadcrumbsList = [] }) => {
33
33
  margin={themeValues.margin}
34
34
  extraStyles={`
35
35
  text-transform: uppercase;
36
+ text-decoration: none;
36
37
  ${isActive.toString() === "true" &&
37
- `pointer-events: none;
38
- color: ${themeValues.activeBreadcrumbColor};
38
+ `color: ${themeValues.activeBreadcrumbColor};
39
+ pointer-events: none;
39
40
  `}
40
41
  &:first-child {
41
42
  margin-left: 0;
42
43
  }
43
44
  &:active {
44
- color: ${themeValues.activeColor};
45
+ color: ${themeValues.activeColor};
45
46
  }`}
46
47
  >
47
48
  {linkText}
@@ -1,5 +1,8 @@
1
1
  // import theme from "styled-theming";
2
- import { MATISSE_BLUE, STORM_GREY } from "../../../constants/colors";
2
+ import { colors, styleConstants } from "../../../constants";
3
+
4
+ const { MATISSE_BLUE, STORM_GREY } = colors;
5
+ const { LINK_TEXT_DECORATION } = styleConstants;
3
6
 
4
7
  /*
5
8
  For now I'm using string values, eventually shared components library will have its own constants file
@@ -13,7 +16,7 @@ const fontSize = "0.875rem";
13
16
  const lineHeight = "1.25rem";
14
17
  const fontWeight = "400";
15
18
  const margin = "0.5rem";
16
- const hover = `text-decoration: none;`;
19
+ const hover = `text-decoration: ${LINK_TEXT_DECORATION};`;
17
20
 
18
21
  export const fallbackValues = {
19
22
  color,
@@ -57,7 +57,7 @@ const Spinner = ({ color, isMobile }) => (
57
57
 
58
58
  Note: the children prop is only used if contentOverride is set to true, in which case
59
59
  the text prop is ignored.
60
-
60
+
61
61
  */
62
62
 
63
63
  const ButtonWithAction = forwardRef(
@@ -81,7 +81,6 @@ const ButtonWithAction = forwardRef(
81
81
  },
82
82
  ref
83
83
  ) => {
84
- const isGhostVariant = variant === "ghost" || variant === "smallGhost";
85
84
  const themeContext = useContext(ThemeContext);
86
85
  const themeValues = createThemeValues(
87
86
  themeContext,
@@ -96,9 +95,6 @@ const ButtonWithAction = forwardRef(
96
95
  background-color: ${themeValues.hoverBackgroundColor};
97
96
  border-color: ${themeValues.hoverBorderColor};
98
97
  color: ${themeValues.hoverColor};
99
- text-decoration: ${
100
- variant === "ghost" || variant === "smallGhost" ? "underline" : "none"
101
- };
102
98
  cursor: pointer;
103
99
  `;
104
100
  const activeStyles = `
@@ -106,14 +102,11 @@ const ButtonWithAction = forwardRef(
106
102
  background-color: ${themeValues.activeBackgroundColor};
107
103
  border-color: ${themeValues.activeBorderColor};
108
104
  color: ${themeValues.activeColor};
109
- text-decoration: ${
110
- variant === "ghost" || variant === "smallGhost" ? "underline" : "none"
111
- };
112
105
  `;
113
106
  const disabledStyles = `
114
- background-color: ${isGhostVariant ? "transparent;" : "#6D717E;"};
115
- border-color: ${isGhostVariant ? "transparent;" : "#6D717E;"};
116
- color: ${isGhostVariant ? "#6D717E;" : "#FFFFFF"};
107
+ background-color: #6D717E;
108
+ border-color: #6D717E;
109
+ color: #FFFFFF;
117
110
  cursor: default;
118
111
  &:focus {
119
112
  outline: 3px solid #6D717E;
@@ -155,10 +148,9 @@ const ButtonWithAction = forwardRef(
155
148
  weight={themeValues.fontWeight}
156
149
  variant={themeValues.fontSizeVariant}
157
150
  color={themeValues.color}
151
+ textDecoration={themeValues.textDecoration}
158
152
  textWrap={textWrap}
159
- extraStyles={
160
- disabled ? textExtraStyles + disabledStyles : textExtraStyles
161
- }
153
+ extraStyles={textExtraStyles}
162
154
  >
163
155
  {text}
164
156
  </Text>
@@ -13,7 +13,6 @@ const variants = {
13
13
  ghost: "ghost",
14
14
  smallGhost: "smallGhost",
15
15
  danger: "danger",
16
- disabled: "disabled",
17
16
  None: undefined
18
17
  };
19
18
  const defaultValue = "primary";
@@ -1,14 +1,16 @@
1
- import {
1
+ import { colors, styleConstants } from "../../../constants";
2
+
3
+ const {
2
4
  WHITE,
3
5
  TRANSPARENT,
4
6
  SAPPHIRE_BLUE,
5
7
  PEACOCK_BLUE,
6
- MANATEE_GREY,
7
8
  MATISSE_BLUE,
8
9
  RASPBERRY,
9
- ERROR_COLOR,
10
- GRECIAN_GREY
11
- } from "../../../constants/colors";
10
+ ERROR_COLOR
11
+ } = colors;
12
+
13
+ const { LINK_TEXT_DECORATION } = styleConstants;
12
14
 
13
15
  const padding = {
14
16
  primary: "0.75rem 1.5rem",
@@ -22,8 +24,7 @@ const padding = {
22
24
  danger: "0.75rem 1.5rem",
23
25
  dangerSecondary: "0.75rem 1.5rem",
24
26
  whiteSecondary: "0.75rem 2rem",
25
- whitePrimary: "1.125rem 0.75rem",
26
- disabled: "0.75rem 1.5rem"
27
+ whitePrimary: "1.125rem 0.75rem"
27
28
  };
28
29
 
29
30
  const color = {
@@ -38,8 +39,7 @@ const color = {
38
39
  danger: WHITE,
39
40
  dangerSecondary: ERROR_COLOR,
40
41
  whiteSecondary: WHITE,
41
- whitePrimary: WHITE,
42
- disabled: MANATEE_GREY
42
+ whitePrimary: WHITE
43
43
  };
44
44
 
45
45
  const fontSizeVariant = {
@@ -54,8 +54,7 @@ const fontSizeVariant = {
54
54
  danger: "pS",
55
55
  dangerSecondary: "pS",
56
56
  whiteSecondary: "pS",
57
- whitePrimary: "pS",
58
- disabled: "pS"
57
+ whitePrimary: "pS"
59
58
  };
60
59
 
61
60
  const fontWeight = {
@@ -70,8 +69,7 @@ const fontWeight = {
70
69
  danger: "600",
71
70
  dangerSecondary: "600",
72
71
  whiteSecondary: "600",
73
- whitePrimary: "600",
74
- disabled: "600"
72
+ whitePrimary: "600"
75
73
  };
76
74
 
77
75
  const height = {
@@ -86,8 +84,7 @@ const height = {
86
84
  danger: "3rem",
87
85
  dangerSecondary: "3rem",
88
86
  whiteSecondary: "3rem",
89
- whitePrimary: "auto",
90
- disabled: "3rem"
87
+ whitePrimary: "auto"
91
88
  };
92
89
 
93
90
  const minWidth = {
@@ -102,8 +99,22 @@ const minWidth = {
102
99
  danger: "130px",
103
100
  dangerSecondary: "157px",
104
101
  whiteSecondary: "160px",
105
- whitePrimary: "130px",
106
- disabled: "130px"
102
+ whitePrimary: "130px"
103
+ };
104
+
105
+ const textDecoration = {
106
+ primary: "none",
107
+ secondary: "none",
108
+ back: "none",
109
+ smallPrimary: "none",
110
+ smallSecondary: "none",
111
+ smallGhost: LINK_TEXT_DECORATION,
112
+ ghost: LINK_TEXT_DECORATION,
113
+ tertiary: "none",
114
+ danger: "none",
115
+ dangerSecondary: "none",
116
+ whiteSecondary: "none",
117
+ whitePrimary: "none"
107
118
  };
108
119
 
109
120
  const backgroundColor = {
@@ -118,8 +129,7 @@ const backgroundColor = {
118
129
  danger: RASPBERRY,
119
130
  dangerSecondary: TRANSPARENT,
120
131
  whiteSecondary: TRANSPARENT,
121
- whitePrimary: TRANSPARENT,
122
- disabled: GRECIAN_GREY
132
+ whitePrimary: TRANSPARENT
123
133
  };
124
134
 
125
135
  const border = {
@@ -134,8 +144,7 @@ const border = {
134
144
  danger: "2px solid " + RASPBERRY,
135
145
  dangerSecondary: "2px solid " + ERROR_COLOR,
136
146
  whiteSecondary: "2px solid " + WHITE,
137
- whitePrimary: "2px solid " + TRANSPARENT,
138
- disabled: "2px solid " + MANATEE_GREY
147
+ whitePrimary: "2px solid " + TRANSPARENT
139
148
  };
140
149
 
141
150
  const hoverBackgroundColor = {
@@ -150,8 +159,7 @@ const hoverBackgroundColor = {
150
159
  danger: "#BA002C",
151
160
  dangerSecondary: "#FAE7EE",
152
161
  whiteSecondary: TRANSPARENT,
153
- whitePrimary: TRANSPARENT,
154
- disabled: TRANSPARENT
162
+ whitePrimary: TRANSPARENT
155
163
  };
156
164
 
157
165
  const hoverBorderColor = {
@@ -166,8 +174,7 @@ const hoverBorderColor = {
166
174
  danger: "#BA002C",
167
175
  dangerSecondary: "#B10541",
168
176
  whiteSecondary: "2px solid " + TRANSPARENT,
169
- whitePrimary: "2px solid " + TRANSPARENT,
170
- disabled: MANATEE_GREY
177
+ whitePrimary: "2px solid " + TRANSPARENT
171
178
  };
172
179
 
173
180
  const hoverColor = {
@@ -182,8 +189,7 @@ const hoverColor = {
182
189
  danger: WHITE,
183
190
  dangerSecondary: "#B10541",
184
191
  whiteSecondary: WHITE,
185
- whitePrimary: WHITE,
186
- disabled: MANATEE_GREY
192
+ whitePrimary: WHITE
187
193
  };
188
194
 
189
195
  const activeBackgroundColor = {
@@ -198,8 +204,7 @@ const activeBackgroundColor = {
198
204
  danger: "#870000",
199
205
  dangerSecondary: "#FAE7EE",
200
206
  whiteSecondary: TRANSPARENT,
201
- whitePrimary: TRANSPARENT,
202
- disabled: TRANSPARENT
207
+ whitePrimary: TRANSPARENT
203
208
  };
204
209
 
205
210
  const activeBorderColor = {
@@ -214,8 +219,7 @@ const activeBorderColor = {
214
219
  danger: "#870000",
215
220
  dangerSecondary: "#910029",
216
221
  whiteSecondary: "2px solid " + TRANSPARENT,
217
- whitePrimary: "2px solid " + TRANSPARENT,
218
- disabled: TRANSPARENT
222
+ whitePrimary: "2px solid " + TRANSPARENT
219
223
  };
220
224
 
221
225
  const activeColor = {
@@ -230,8 +234,7 @@ const activeColor = {
230
234
  danger: WHITE,
231
235
  dangerSecondary: "#910029",
232
236
  whiteSecondary: WHITE,
233
- whitePrimary: WHITE,
234
- disabled: MANATEE_GREY
237
+ whitePrimary: WHITE
235
238
  };
236
239
 
237
240
  export const fallbackValues = {
@@ -241,6 +244,7 @@ export const fallbackValues = {
241
244
  fontWeight,
242
245
  height,
243
246
  minWidth,
247
+ textDecoration,
244
248
  backgroundColor,
245
249
  border,
246
250
  hoverBackgroundColor,
@@ -9,8 +9,8 @@ const ButtonWithLink = ({
9
9
  url = "/",
10
10
  disabled = false,
11
11
  fileLink = false,
12
- extraStyles,
13
- linkExtraStyles,
12
+ extraStyles = "",
13
+ linkExtraStyles = "",
14
14
  newTab = false,
15
15
  dataQa,
16
16
  ...otherProps
@@ -172,7 +172,7 @@ const FormInput = ({
172
172
  color={themeValues.linkColor}
173
173
  weight={themeValues.fontWeight}
174
174
  hoverStyles={themeValues.hoverFocusStyles}
175
- extraStyles={`cursor: pointer; &:focus { outline-offset: -2px; }`}
175
+ extraStyles={`text-decoration: underline; cursor: pointer; &:focus { outline-offset: -2px; }`}
176
176
  onClick={() => setShowPassword(!showPassword)}
177
177
  tabIndex="0"
178
178
  aria-label={showPassword ? "Hide Password" : "Show password"}
@@ -0,0 +1 @@
1
+ export const CloseIcon: JSX.Element;
@@ -0,0 +1,48 @@
1
+ import React from "react";
2
+
3
+ export const CloseIcon = ({
4
+ iconFill = "#3B414D",
5
+ iconWidth = "24",
6
+ iconHeight = "24",
7
+ ...rest
8
+ }) => {
9
+ return (
10
+ <svg
11
+ xmlns="http://www.w3.org/2000/svg"
12
+ width={iconWidth}
13
+ height={iconHeight}
14
+ viewBox="0 0 24 24"
15
+ fill="none"
16
+ {...rest}
17
+ >
18
+ <title>Close Icon</title>
19
+ <path
20
+ fillRule="evenodd"
21
+ clipRule="evenodd"
22
+ d="M17.3033 5.98982C17.108 5.79456 16.7915 5.79456 16.5962 5.98982L12 10.586L7.40381 5.98982C7.20854 5.79456 6.89196 5.79456 6.6967 5.98982L5.98959 6.69693C5.79433 6.89219 5.79433 7.20878 5.98959 7.40404L10.5858 12.0002L5.98959 16.5964C5.79433 16.7917 5.79433 17.1083 5.98959 17.3035L6.6967 18.0106C6.89196 18.2059 7.20854 18.2059 7.40381 18.0106L12 13.4144L16.5962 18.0106C16.7915 18.2059 17.108 18.2059 17.3033 18.0106L18.0104 17.3035C18.2057 17.1083 18.2057 16.7917 18.0104 16.5964L13.4142 12.0002L18.0104 7.40404C18.2057 7.20878 18.2057 6.89219 18.0104 6.69693L17.3033 5.98982Z"
23
+ fill={iconFill}
24
+ />
25
+ <mask
26
+ id="mask0_3727_16765"
27
+ style={{ maskType: "luminance" }}
28
+ maskUnits="userSpaceOnUse"
29
+ x="5"
30
+ y="5"
31
+ width="14"
32
+ height="14"
33
+ >
34
+ <path
35
+ fillRule="evenodd"
36
+ clipRule="evenodd"
37
+ d="M17.3033 5.98982C17.108 5.79456 16.7915 5.79456 16.5962 5.98982L12 10.586L7.40381 5.98982C7.20854 5.79456 6.89196 5.79456 6.6967 5.98982L5.98959 6.69693C5.79433 6.89219 5.79433 7.20878 5.98959 7.40404L10.5858 12.0002L5.98959 16.5964C5.79433 16.7917 5.79433 17.1083 5.98959 17.3035L6.6967 18.0106C6.89196 18.2059 7.20854 18.2059 7.40381 18.0106L12 13.4144L16.5962 18.0106C16.7915 18.2059 17.108 18.2059 17.3033 18.0106L18.0104 17.3035C18.2057 17.1083 18.2057 16.7917 18.0104 16.5964L13.4142 12.0002L18.0104 7.40404C18.2057 7.20878 18.2057 6.89219 18.0104 6.69693L17.3033 5.98982Z"
38
+ fill="none"
39
+ />
40
+ </mask>
41
+ <g mask="url(#mask0_3727_16765)">
42
+ <path d="M0 0H24V24H0V0Z" fill={iconFill} />
43
+ </g>
44
+ </svg>
45
+ );
46
+ };
47
+
48
+ export default CloseIcon;
@@ -0,0 +1 @@
1
+ export const TrashIconV2: JSX.Element;
@@ -0,0 +1,41 @@
1
+ import React from "react";
2
+ import { fallbackValues } from "./Icons.theme";
3
+ import { themeComponent } from "../../../util/themeUtils";
4
+
5
+ const TrashIconV2 = ({ themeValues, iconFill }) => {
6
+ return (
7
+ <svg
8
+ xmlns="http://www.w3.org/2000/svg"
9
+ width="18"
10
+ height="18"
11
+ viewBox="0 0 18 18"
12
+ fill="none"
13
+ >
14
+ <path
15
+ fillRule="evenodd"
16
+ clipRule="evenodd"
17
+ d="M11.5 4H14V6H4V4H6.5L7.21429 3H10.7857L11.5 4ZM6.99048 15C6.25714 15 5.65714 14.4857 5.65714 13.8571L4.85714 7H12.8571L12.0571 13.8571C12.0571 14.4857 11.4571 15 10.7238 15H6.99048Z"
18
+ fill={iconFill ?? themeValues.singleIconColor}
19
+ />
20
+ <mask
21
+ id="mask0_4292_11876"
22
+ style={{ maskType: "luminance" }}
23
+ maskUnits="userSpaceOnUse"
24
+ x="4"
25
+ y="3"
26
+ width="10"
27
+ height="12"
28
+ >
29
+ <path
30
+ fillRule="evenodd"
31
+ clipRule="evenodd"
32
+ d="M11.5 4H14V6H4V4H6.5L7.21429 3H10.7857L11.5 4ZM6.99048 15C6.25714 15 5.65714 14.4857 5.65714 13.8571L4.85714 7H12.8571L12.0571 13.8571C12.0571 14.4857 11.4571 15 10.7238 15H6.99048Z"
33
+ fill="white"
34
+ />
35
+ </mask>
36
+ <g mask="url(#mask0_4292_11876)"></g>
37
+ </svg>
38
+ );
39
+ };
40
+
41
+ export default themeComponent(TrashIconV2, "Icons", fallbackValues, "primary");
@@ -40,7 +40,9 @@ import {
40
40
  StatusUnknownIcon,
41
41
  AutopayIcon,
42
42
  KebabMenuIcon,
43
- MultiCartIcon
43
+ MultiCartIcon,
44
+ CloseIcon,
45
+ TrashIconV2
44
46
  } from "./index";
45
47
 
46
48
  const story = page({
@@ -88,3 +90,5 @@ export const statusUnknownIcon = () => <StatusUnknownIcon />;
88
90
  export const autopayIcon = () => <AutopayIcon />;
89
91
  export const kebabMenuIcon = () => <KebabMenuIcon />;
90
92
  export const multiCartIcon = () => <MultiCartIcon />;
93
+ export const closeIcon = () => <CloseIcon />;
94
+ export const trashIconV2 = () => <TrashIconV2 />;
@@ -23,3 +23,5 @@ export * from "./XCircleIconMedium";
23
23
  export * from "./XCircleIconSmall";
24
24
  export * from "./KebabMenuIcon";
25
25
  export * from "./MultiCartIcon";
26
+ export * from "./CloseIcon";
27
+ export * from "./TrashIconV2";
@@ -88,6 +88,8 @@ import ChargebackReversalIconMedium from "./ChargebackReversalIconMedium";
88
88
  import PlusCircleIcon from "./PlusCircleIcon";
89
89
  import KebabMenuIcon from "./KebabMenuIcon";
90
90
  import MultiCartIcon from "./MultiCartIcon";
91
+ import CloseIcon from "./CloseIcon";
92
+ import TrashIconV2 from "./TrashIconV2";
91
93
 
92
94
  export {
93
95
  AccountsIcon,
@@ -179,5 +181,7 @@ export {
179
181
  ChargebackReversalIconMedium,
180
182
  PlusCircleIcon,
181
183
  KebabMenuIcon,
182
- MultiCartIcon
184
+ MultiCartIcon,
185
+ CloseIcon,
186
+ TrashIconV2
183
187
  };
@@ -45,7 +45,6 @@ const Box = forwardRef(
45
45
  extraStyles,
46
46
  srOnly = false,
47
47
  dataQa,
48
- disabled = false,
49
48
  children,
50
49
  ...rest
51
50
  },
@@ -1,5 +1,5 @@
1
1
  import React from "react";
2
- import { boolean, text, radios, select } from "@storybook/addon-knobs";
2
+ import { text, radios, select } from "@storybook/addon-knobs";
3
3
 
4
4
  import page from "../../../../../../.storybook/page";
5
5
  import Box from "../../Box";
@@ -47,7 +47,6 @@ export const box = () => (
47
47
  onFocus={text("onFocus", () => {}, groupId)}
48
48
  onBlur={text("onBlur", () => {}, groupId)}
49
49
  onTouchEnd={text("onTouchEnd", () => {}, groupId)}
50
- disabled={boolean("disabled", false, groupId)}
51
50
  >
52
51
  Text Child
53
52
  <LayoutContentBlock
@@ -1,6 +1,10 @@
1
1
  import React, { forwardRef } from "react";
2
2
  import styled from "styled-components";
3
- import { ROYAL_BLUE } from "../../../constants/colors";
3
+ import { colors, styleConstants } from "../../../constants";
4
+
5
+ const { ROYAL_BLUE } = colors;
6
+ const { LINK_TEXT_DECORATION } = styleConstants;
7
+
4
8
  /*
5
9
  The extracting of props and the disabling of the eslint rule is to stop React from complaining about
6
10
  unrecognized DOM attributes.
@@ -18,10 +22,10 @@ export const StyledExternalLink = styled(
18
22
  font-weight: ${({ weight }) => weight};
19
23
  font-family: ${({ fontFamily }) => fontFamily};
20
24
  line-height: ${({ lineheight }) => lineheight};
25
+ text-decoration: ${LINK_TEXT_DECORATION};
21
26
 
22
27
  &:hover {
23
28
  color: ${({ hoverColor }) => hoverColor};
24
- text-decoration: underline;
25
29
  }
26
30
 
27
31
  &:focus {
@@ -30,7 +34,6 @@ export const StyledExternalLink = styled(
30
34
  }
31
35
 
32
36
  &:active {
33
- text-decoration: underline;
34
37
  color: ${({ activeColor }) => activeColor};
35
38
  }
36
39
 
@@ -1,7 +1,11 @@
1
1
  import React, { forwardRef } from "react";
2
2
  import styled from "styled-components";
3
3
  import { Link } from "react-router-dom";
4
- import { ROYAL_BLUE } from "../../../constants/colors";
4
+ import { colors, styleConstants } from "../../../constants";
5
+
6
+ const { ROYAL_BLUE } = colors;
7
+ const { LINK_TEXT_DECORATION } = styleConstants;
8
+
5
9
  /*
6
10
  The extracting of props and the disabling of the eslint rule is to stop React from complaining about
7
11
  unrecognized DOM attributes.
@@ -24,10 +28,10 @@ export const StyledInternalLink = styled(
24
28
  font-size: ${({ fontSize }) => fontSize};
25
29
  font-family: ${({ fontFamily }) => fontFamily};
26
30
  margin: ${({ margin }) => margin};
31
+ text-decoration: ${LINK_TEXT_DECORATION};
27
32
 
28
33
  &:hover {
29
34
  color: ${({ hoverColor }) => hoverColor};
30
- text-decoration: underline;
31
35
  }
32
36
 
33
37
  &:focus {
@@ -36,7 +40,6 @@ export const StyledInternalLink = styled(
36
40
  }
37
41
 
38
42
  &:active {
39
- text-decoration: underline;
40
43
  color: ${({ activeColor }) => activeColor};
41
44
  }
42
45