@thecb/components 4.2.7-beta.9 → 4.2.8-beta.2

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/dist/index.cjs.js CHANGED
@@ -13775,41 +13775,54 @@ var IconAdd = function IconAdd() {
13775
13775
  }))))));
13776
13776
  };
13777
13777
 
13778
- var IconQuit = function IconQuit(_ref) {
13778
+ var IconQuitLarge = function IconQuitLarge(_ref) {
13779
13779
  var _ref$fill = _ref.fill,
13780
- fill = _ref$fill === void 0 ? MINESHAFT_GREY : _ref$fill,
13781
- _ref$width = _ref.width,
13782
- width = _ref$width === void 0 ? "24px" : _ref$width,
13783
- _ref$height = _ref.height,
13784
- height = _ref$height === void 0 ? "24px" : _ref$height;
13780
+ fill = _ref$fill === void 0 ? "#091325" : _ref$fill;
13785
13781
  return /*#__PURE__*/React__default.createElement("svg", {
13782
+ width: "14px",
13783
+ height: "14px",
13784
+ viewBox: "0 0 14 14",
13785
+ version: "1.1",
13786
13786
  xmlns: "http://www.w3.org/2000/svg",
13787
- xmlnsXlink: "http://www.w3.org/1999/xlink",
13788
- width: width,
13789
- height: height,
13790
- viewBox: "0 0 24 24"
13791
- }, /*#__PURE__*/React__default.createElement("defs", null, /*#__PURE__*/React__default.createElement("path", {
13792
- id: "quit",
13793
- d: "M18.9999989 6.40999946L17.589999 4.9999997 11.9999993 10.5899995 6.40999946 4.9999997 4.9999997 6.40999946 10.5899995 11.9999993 4.9999997 17.589999 6.40999946 18.9999989 11.9999993 13.409999 17.589999 18.9999989 18.9999989 17.589999 13.409999 11.9999993z"
13787
+ xmlnsXlink: "http://www.w3.org/1999/xlink"
13788
+ }, /*#__PURE__*/React__default.createElement("title", null, "Icon/X"), /*#__PURE__*/React__default.createElement("defs", null, /*#__PURE__*/React__default.createElement("polygon", {
13789
+ id: "quit-large-path-1",
13790
+ points: "18.9999989 6.40999946 17.589999 4.9999997 11.9999993 10.5899995 6.40999946 4.9999997 4.9999997 6.40999946 10.5899995 11.9999993 4.9999997 17.589999 6.40999946 18.9999989 11.9999993 13.409999 17.589999 18.9999989 18.9999989 17.589999 13.409999 11.9999993"
13794
13791
  })), /*#__PURE__*/React__default.createElement("g", {
13795
- fill: "none",
13796
- fillRule: "evenodd",
13792
+ id: "quit-large-[D]-Cart---Slideout",
13797
13793
  stroke: "none",
13798
- strokeWidth: "1"
13794
+ strokeWidth: "1",
13795
+ fill: "none",
13796
+ fillRule: "evenodd"
13797
+ }, /*#__PURE__*/React__default.createElement("g", {
13798
+ id: "quit-large-[D]-Cart-Slideout---Standard",
13799
+ transform: "translate(-741.000000, -34.000000)"
13800
+ }, /*#__PURE__*/React__default.createElement("g", {
13801
+ id: "quit-large-Close-Icon",
13802
+ transform: "translate(724.000000, 17.000000)"
13803
+ }, /*#__PURE__*/React__default.createElement("g", {
13804
+ id: "quit-large-Group",
13805
+ transform: "translate(12.000000, 12.000000)"
13799
13806
  }, /*#__PURE__*/React__default.createElement("mask", {
13800
- id: "quitMask",
13801
- fill: "#fff"
13807
+ id: "quit-large-mask-2",
13808
+ fill: "white"
13802
13809
  }, /*#__PURE__*/React__default.createElement("use", {
13803
- xlinkHref: "#quit"
13810
+ xlinkHref: "#quit-large-path-1"
13804
13811
  })), /*#__PURE__*/React__default.createElement("use", {
13812
+ id: "quit-large-Fill-2",
13805
13813
  fill: fill,
13806
- xlinkHref: "#quit"
13814
+ xlinkHref: "#quit-large-path-1"
13807
13815
  }), /*#__PURE__*/React__default.createElement("g", {
13816
+ mask: "url(#quit-large-mask-2)",
13808
13817
  fill: fill,
13809
- mask: "url(#quitMask)"
13810
- }, /*#__PURE__*/React__default.createElement("path", {
13811
- d: "M0 0H24V24H0z"
13812
- }))));
13818
+ id: "quit-large-\u2B91\uD83C\uDFA8"
13819
+ }, /*#__PURE__*/React__default.createElement("g", null, /*#__PURE__*/React__default.createElement("rect", {
13820
+ id: "quit-large-\u279D\u270F\uFE0F",
13821
+ x: "0",
13822
+ y: "0",
13823
+ width: "24",
13824
+ height: "24"
13825
+ }))))))));
13813
13826
  };
13814
13827
 
13815
13828
  var TimeoutImage = function TimeoutImage() {
@@ -15285,6 +15298,43 @@ var AlertWarningIcon = function AlertWarningIcon() {
15285
15298
  })))));
15286
15299
  };
15287
15300
 
15301
+ var IconQuit = function IconQuit(_ref) {
15302
+ var _ref$fill = _ref.fill,
15303
+ fill = _ref$fill === void 0 ? MINESHAFT_GREY : _ref$fill,
15304
+ _ref$width = _ref.width,
15305
+ width = _ref$width === void 0 ? "24px" : _ref$width,
15306
+ _ref$height = _ref.height,
15307
+ height = _ref$height === void 0 ? "24px" : _ref$height;
15308
+ return /*#__PURE__*/React__default.createElement("svg", {
15309
+ xmlns: "http://www.w3.org/2000/svg",
15310
+ xmlnsXlink: "http://www.w3.org/1999/xlink",
15311
+ width: width,
15312
+ height: height,
15313
+ viewBox: "0 0 24 24"
15314
+ }, /*#__PURE__*/React__default.createElement("defs", null, /*#__PURE__*/React__default.createElement("path", {
15315
+ id: "quit",
15316
+ d: "M18.9999989 6.40999946L17.589999 4.9999997 11.9999993 10.5899995 6.40999946 4.9999997 4.9999997 6.40999946 10.5899995 11.9999993 4.9999997 17.589999 6.40999946 18.9999989 11.9999993 13.409999 17.589999 18.9999989 18.9999989 17.589999 13.409999 11.9999993z"
15317
+ })), /*#__PURE__*/React__default.createElement("g", {
15318
+ fill: "none",
15319
+ fillRule: "evenodd",
15320
+ stroke: "none",
15321
+ strokeWidth: "1"
15322
+ }, /*#__PURE__*/React__default.createElement("mask", {
15323
+ id: "quitMask",
15324
+ fill: "#fff"
15325
+ }, /*#__PURE__*/React__default.createElement("use", {
15326
+ xlinkHref: "#quit"
15327
+ })), /*#__PURE__*/React__default.createElement("use", {
15328
+ fill: fill,
15329
+ xlinkHref: "#quit"
15330
+ }), /*#__PURE__*/React__default.createElement("g", {
15331
+ fill: fill,
15332
+ mask: "url(#quitMask)"
15333
+ }, /*#__PURE__*/React__default.createElement("path", {
15334
+ d: "M0 0H24V24H0z"
15335
+ }))));
15336
+ };
15337
+
15288
15338
  var AlertIcons = {
15289
15339
  error: AlertErrorIcon,
15290
15340
  info: AlertInfoIcon,
@@ -21206,7 +21256,11 @@ var Jumbo = function Jumbo(_ref) {
21206
21256
  _ref$largeSide = _ref.largeSide,
21207
21257
  largeSide = _ref$largeSide === void 0 ? "right" : _ref$largeSide,
21208
21258
  _ref$largeSideSize = _ref.largeSideSize,
21209
- largeSideSize = _ref$largeSideSize === void 0 ? "2" : _ref$largeSideSize;
21259
+ largeSideSize = _ref$largeSideSize === void 0 ? "2" : _ref$largeSideSize,
21260
+ CartStatus = _ref.cartStatus,
21261
+ total = _ref.total,
21262
+ showCartStatus = _ref.showCartStatus,
21263
+ openCartSlider = _ref.openCartSlider;
21210
21264
 
21211
21265
  var _useContext = React.useContext(styled.ThemeContext),
21212
21266
  isMobile = _useContext.isMobile;
@@ -21228,7 +21282,7 @@ var Jumbo = function Jumbo(_ref) {
21228
21282
  childGap: "0.25rem"
21229
21283
  }, /*#__PURE__*/React__default.createElement(Cluster, {
21230
21284
  minHeight: "100%",
21231
- justify: isMobile ? "center" : showButton ? "space-between" : "left",
21285
+ justify: isMobile ? "center" : showButton || showCartStatus ? "space-between" : "left",
21232
21286
  align: "center"
21233
21287
  }, /*#__PURE__*/React__default.createElement(Heading$1, {
21234
21288
  variant: isMobile ? "h5" : "h3",
@@ -21244,6 +21298,9 @@ var Jumbo = function Jumbo(_ref) {
21244
21298
  text: buttonText || "Browse Services",
21245
21299
  variant: "primary",
21246
21300
  extraStyles: "margin: 0 0 65px 0; min-width: 320px;"
21301
+ }), showCartStatus && /*#__PURE__*/React__default.createElement(CartStatus, {
21302
+ total: total,
21303
+ openCart: openCartSlider
21247
21304
  }))))));
21248
21305
  };
21249
21306
 
@@ -34754,7 +34811,9 @@ var CollapsibleSection = function CollapsibleSection(_ref) {
34754
34811
  customTitle = _ref$customTitle === void 0 ? false : _ref$customTitle,
34755
34812
  _ref$stackTitle = _ref.stackTitle,
34756
34813
  stackTitle = _ref$stackTitle === void 0 ? false : _ref$stackTitle,
34757
- stackTitleContent = _ref.stackTitleContent;
34814
+ stackTitleContent = _ref.stackTitleContent,
34815
+ _ref$sectionGap = _ref.sectionGap,
34816
+ sectionGap = _ref$sectionGap === void 0 ? "0.5rem" : _ref$sectionGap;
34758
34817
 
34759
34818
  var handleKeyDown = function handleKeyDown(e) {
34760
34819
  if (e.keyCode === 13) {
@@ -34797,7 +34856,7 @@ var CollapsibleSection = function CollapsibleSection(_ref) {
34797
34856
  animate: isOpen ? "open" : "closed",
34798
34857
  positionTransition: true
34799
34858
  }, stackTitle && /*#__PURE__*/React__default.createElement(React.Fragment, null, stackTitleContent), /*#__PURE__*/React__default.createElement(Stack, {
34800
- childGap: isOpen && !isMobile ? "0.5rem" : "0rem"
34859
+ childGap: isOpen && !isMobile ? sectionGap : "0rem"
34801
34860
  }, /*#__PURE__*/React__default.createElement(Box, {
34802
34861
  padding: customPadding ? customPadding : "0",
34803
34862
  background: themeValues.headingBackgroundColor,
@@ -40932,7 +40991,7 @@ exports.HamburgerButton = HamburgerButton;
40932
40991
  exports.Heading = Heading$1;
40933
40992
  exports.HighlightTabRow = HighlightTabRow$1;
40934
40993
  exports.IconAdd = IconAdd;
40935
- exports.IconQuit = IconQuit;
40994
+ exports.IconQuitLarge = IconQuitLarge;
40936
40995
  exports.Imposter = Imposter;
40937
40996
  exports.InternalLink = InternalLink;
40938
40997
  exports.Jumbo = Jumbo$1;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@thecb/components",
3
- "version": "4.2.7-beta.9",
3
+ "version": "4.2.8-beta.2",
4
4
  "description": "Common lib for CityBase react components",
5
5
  "main": "dist/index.cjs.js",
6
6
  "module": "dist/index.esm.js",
@@ -1,6 +1,5 @@
1
1
  import React from "react";
2
- import { AlertIcons } from "../../../deprecated/icons";
3
- import { IconQuit } from "../icons";
2
+ import { AlertIcons, IconQuit } from "../../../deprecated/icons";
4
3
  import { Box, Center, Cluster, Stack, Cover, Sidebar } from "../layouts";
5
4
  import Text from "../text";
6
5
  import { fallbackValues } from "./Alert.theme";
@@ -0,0 +1,61 @@
1
+ import React from "react";
2
+
3
+ const IconQuitLarge = ({ fill = "#091325" }) => (
4
+ <svg
5
+ width="14px"
6
+ height="14px"
7
+ viewBox="0 0 14 14"
8
+ version="1.1"
9
+ xmlns="http://www.w3.org/2000/svg"
10
+ xmlnsXlink="http://www.w3.org/1999/xlink"
11
+ >
12
+ <title>Icon/X</title>
13
+ <defs>
14
+ <polygon
15
+ id="quit-large-path-1"
16
+ points="18.9999989 6.40999946 17.589999 4.9999997 11.9999993 10.5899995 6.40999946 4.9999997 4.9999997 6.40999946 10.5899995 11.9999993 4.9999997 17.589999 6.40999946 18.9999989 11.9999993 13.409999 17.589999 18.9999989 18.9999989 17.589999 13.409999 11.9999993"
17
+ ></polygon>
18
+ </defs>
19
+ <g
20
+ id="quit-large-[D]-Cart---Slideout"
21
+ stroke="none"
22
+ strokeWidth="1"
23
+ fill="none"
24
+ fillRule="evenodd"
25
+ >
26
+ <g
27
+ id="quit-large-[D]-Cart-Slideout---Standard"
28
+ transform="translate(-741.000000, -34.000000)"
29
+ >
30
+ <g
31
+ id="quit-large-Close-Icon"
32
+ transform="translate(724.000000, 17.000000)"
33
+ >
34
+ <g id="quit-large-Group" transform="translate(12.000000, 12.000000)">
35
+ <mask id="quit-large-mask-2" fill="white">
36
+ <use xlinkHref="#quit-large-path-1"></use>
37
+ </mask>
38
+ <use
39
+ id="quit-large-Fill-2"
40
+ fill={fill}
41
+ xlinkHref="#quit-large-path-1"
42
+ ></use>
43
+ <g mask="url(#quit-large-mask-2)" fill={fill} id="quit-large-⮑🎨">
44
+ <g>
45
+ <rect
46
+ id="quit-large-➝✏️"
47
+ x="0"
48
+ y="0"
49
+ width="24"
50
+ height="24"
51
+ ></rect>
52
+ </g>
53
+ </g>
54
+ </g>
55
+ </g>
56
+ </g>
57
+ </g>
58
+ </svg>
59
+ );
60
+
61
+ export default IconQuitLarge;
@@ -19,7 +19,7 @@ import BankIcon from "./BankIcon";
19
19
  import GenericCard from "./GenericCard";
20
20
  import PaymentIcon from "./PaymentIcon";
21
21
  import IconAdd from "./IconAdd";
22
- import IconQuit from "./IconQuit";
22
+ import IconQuitLarge from "./IconQuitLarge";
23
23
  import TimeoutImage from "./TimeoutImage";
24
24
  import AutopayOnIcon from "./AutopayOnIcon";
25
25
  import NotFoundIcon from "./NotFoundIcon";
@@ -69,7 +69,7 @@ export {
69
69
  GenericCard,
70
70
  PaymentIcon,
71
71
  IconAdd,
72
- IconQuit,
72
+ IconQuitLarge,
73
73
  TimeoutImage,
74
74
  AutopayOnIcon,
75
75
  NotFoundIcon,
@@ -14,7 +14,11 @@ const Jumbo = ({
14
14
  buttonText,
15
15
  slug,
16
16
  largeSide = "right",
17
- largeSideSize = "2"
17
+ largeSideSize = "2",
18
+ cartStatus: CartStatus,
19
+ total,
20
+ showCartStatus,
21
+ openCartSlider
18
22
  }) => {
19
23
  const { isMobile } = useContext(ThemeContext);
20
24
  return (
@@ -35,7 +39,11 @@ const Jumbo = ({
35
39
  <Cluster
36
40
  minHeight="100%"
37
41
  justify={
38
- isMobile ? `center` : showButton ? `space-between` : `left`
42
+ isMobile
43
+ ? `center`
44
+ : showButton || showCartStatus
45
+ ? `space-between`
46
+ : `left`
39
47
  }
40
48
  align="center"
41
49
  >
@@ -65,6 +73,9 @@ const Jumbo = ({
65
73
  extraStyles={`margin: 0 0 65px 0; min-width: 320px;`}
66
74
  />
67
75
  )}
76
+ {showCartStatus && (
77
+ <CartStatus total={total} openCart={openCartSlider} />
78
+ )}
68
79
  </Cluster>
69
80
  </Switcher>
70
81
  </Cover>
@@ -21,7 +21,8 @@ const CollapsibleSection = ({
21
21
  children,
22
22
  customTitle = false,
23
23
  stackTitle = false,
24
- stackTitleContent
24
+ stackTitleContent,
25
+ sectionGap = "0.5rem"
25
26
  }) => {
26
27
  const handleKeyDown = e => {
27
28
  if (e.keyCode === 13) {
@@ -69,7 +70,7 @@ const CollapsibleSection = ({
69
70
  positionTransition
70
71
  >
71
72
  {stackTitle && <Fragment>{stackTitleContent}</Fragment>}
72
- <Stack childGap={isOpen && !isMobile ? "0.5rem" : "0rem"}>
73
+ <Stack childGap={isOpen && !isMobile ? sectionGap : "0rem"}>
73
74
  <Box
74
75
  padding={customPadding ? customPadding : "0"}
75
76
  background={themeValues.headingBackgroundColor}
@@ -1,7 +1,7 @@
1
1
  import React from "react";
2
- import { MINESHAFT_GREY } from "../../../constants/colors";
2
+ import { MINESHAFT_GREY } from "../../constants/colors";
3
3
 
4
- const IconQuit = ({
4
+ export const IconQuit = ({
5
5
  fill = MINESHAFT_GREY,
6
6
  width = "24px",
7
7
  height = "24px"
@@ -30,5 +30,3 @@ const IconQuit = ({
30
30
  </g>
31
31
  </svg>
32
32
  );
33
-
34
- export default IconQuit;
@@ -13,6 +13,7 @@ import { AlertInfoIcon } from "./AlertInfoIcon";
13
13
  import { AlertErrorIcon } from "./AlertErrorIcon";
14
14
  import { AlertSuccessIcon } from "./AlertSuccessIcon";
15
15
  import { AlertWarningIcon } from "./AlertWarningIcon";
16
+ import { IconQuit } from "./IconQuit";
16
17
 
17
18
  const AlertIcons = {
18
19
  error: AlertErrorIcon,
@@ -32,5 +33,6 @@ export {
32
33
  IconNeutral,
33
34
  IconValid,
34
35
  IconInvalid,
35
- AlertIcons
36
+ AlertIcons,
37
+ IconQuit
36
38
  };