@thecb/components 8.4.0-beta.0 → 8.4.0-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 +30 -41
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +30 -41
- package/dist/index.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/components/molecules/link-card/LinkCard.js +45 -47
- package/src/components/molecules/link-card/LinkCard.stories.js +30 -8
- package/src/components/molecules/link-card/index.d.ts +6 -3
package/dist/index.esm.js
CHANGED
|
@@ -42837,32 +42837,39 @@ var fallbackValues$I = {
|
|
|
42837
42837
|
color: color$b
|
|
42838
42838
|
};
|
|
42839
42839
|
|
|
42840
|
+
// import ArrowRightIcon from "../../atoms/icons/ArrowRightIcon";
|
|
42841
|
+
|
|
42840
42842
|
var LinkCard = function LinkCard(_ref) {
|
|
42841
42843
|
var _ref$variant = _ref.variant,
|
|
42842
|
-
_ref$
|
|
42843
|
-
|
|
42844
|
-
_ref$
|
|
42845
|
-
|
|
42846
|
-
_ref$workflowActionNa = _ref.workflowActionName,
|
|
42847
|
-
workflowActionName = _ref$workflowActionNa === void 0 ? "Find" : _ref$workflowActionNa,
|
|
42844
|
+
_ref$title = _ref.title,
|
|
42845
|
+
title = _ref$title === void 0 ? "Test Workflow" : _ref$title,
|
|
42846
|
+
_ref$subtitle = _ref.subtitle,
|
|
42847
|
+
subtitle = _ref$subtitle === void 0 ? "Link your benefit plan" : _ref$subtitle,
|
|
42848
42848
|
themeValues = _ref.themeValues,
|
|
42849
|
-
|
|
42849
|
+
path = _ref.path,
|
|
42850
|
+
showLeft = _ref.showLeft,
|
|
42851
|
+
leftContent = _ref.leftContent,
|
|
42852
|
+
showRight = _ref.showRight,
|
|
42853
|
+
rightContent = _ref.rightContent;
|
|
42850
42854
|
var navigate = useNavigate();
|
|
42855
|
+
var activeHoverStyles = "\n border-radius: 8px;\n cursor: pointer;\n border: 1px solid ".concat(themeValues.color, ";\n background: var(--primary-color-primary-10, #EBEFFB);\n /* Primitives/New Shadow/3-Pressed-New */\n box-shadow: 0px 0px 0px 0px rgba(41, 42, 51, 0.10), 0px 5px 11px 0px rgba(41, 42, 51, 0.10), 0px 4px 19px 0px rgba(41, 42, 51, 0.09), 0px 27px 26px 0px rgba(41, 42, 51, 0.05), 0px 56px 31px 0px rgba(41, 42, 51, 0.01), 0px 80px 33px 0px rgba(41, 42, 51, 0.00);\n .show-on-hover {color: ").concat(themeValues.color, ";}\n ");
|
|
42851
42856
|
return /*#__PURE__*/React.createElement(Box, {
|
|
42852
42857
|
background: "#FEFEFE" // --grays-cool-gray-00
|
|
42853
42858
|
,
|
|
42854
42859
|
border: "1px solid #C4CEF4;" // --primary-color-primary-30
|
|
42855
42860
|
,
|
|
42856
|
-
padding: 0,
|
|
42857
42861
|
borderRadius: "8px",
|
|
42858
|
-
dataQa: "link-card-".concat(
|
|
42859
|
-
|
|
42860
|
-
|
|
42862
|
+
dataQa: "link-card-".concat(title),
|
|
42863
|
+
width: "100%",
|
|
42864
|
+
maxWidth: "288px",
|
|
42865
|
+
minWidth: "240px",
|
|
42866
|
+
minHeight: "141px",
|
|
42867
|
+
padding: "16px 24px",
|
|
42868
|
+
extraStyles: " display: flex; flex-direction: column; align-items: flex-start; gap: 40px; flex-shrink: 0; align-self: stretch;",
|
|
42869
|
+
hoverStyles: activeHoverStyles,
|
|
42870
|
+
activeStyles: activeHoverStyles,
|
|
42861
42871
|
onClick: function onClick() {
|
|
42862
|
-
|
|
42863
|
-
console.log("attempting navigation..."); // window.location.pathname = `/service/${slug}`;
|
|
42864
|
-
|
|
42865
|
-
navigate("/service/".concat(slug));
|
|
42872
|
+
navigate(path);
|
|
42866
42873
|
}
|
|
42867
42874
|
}, /*#__PURE__*/React.createElement(Stack, {
|
|
42868
42875
|
childGap: 0,
|
|
@@ -42874,42 +42881,24 @@ var LinkCard = function LinkCard(_ref) {
|
|
|
42874
42881
|
variant: "h6",
|
|
42875
42882
|
weight: FONT_WEIGHT_SEMIBOLD,
|
|
42876
42883
|
color: themeValues.color,
|
|
42877
|
-
margin:
|
|
42884
|
+
margin: 0,
|
|
42878
42885
|
extraStyles: "display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; align-self: stretch; overflow: hidden; text-overflow: ellipsis; font-family: Public Sans; font-size: 16px; font-style: normal; font-weight: 600; line-height: 150%;"
|
|
42879
|
-
},
|
|
42880
|
-
padding: "0 1rem
|
|
42881
|
-
minHeight
|
|
42886
|
+
}, title)), /*#__PURE__*/React.createElement(Box, {
|
|
42887
|
+
padding: "0 1rem 40px"
|
|
42888
|
+
/* minHeight={"4.25rem"}*/
|
|
42889
|
+
|
|
42882
42890
|
}, /*#__PURE__*/React.createElement(Paragraph$1, {
|
|
42883
42891
|
variant: "pS",
|
|
42884
42892
|
color: themeValues.color,
|
|
42885
42893
|
extraStyles: "overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; align-self: stretch; /* CB Standard/Desktop/D - P Small - Regular */ font-family: Public Sans; font-size: 14px; font-style: normal; font-weight: 400; line-height: 150%; /* 21px */ letter-spacing: 0.14px;"
|
|
42886
|
-
},
|
|
42894
|
+
}, subtitle)), /*#__PURE__*/React.createElement(Box, {
|
|
42887
42895
|
background: "transparent",
|
|
42888
42896
|
borderWidthOverride: "0 0 0 0",
|
|
42889
|
-
padding: "
|
|
42897
|
+
padding: "0 1rem 1rem 1rem"
|
|
42890
42898
|
}, /*#__PURE__*/React.createElement(Stack, {
|
|
42891
42899
|
direction: "row",
|
|
42892
42900
|
justify: "space-between"
|
|
42893
|
-
},
|
|
42894
|
-
background: "transparent",
|
|
42895
|
-
borderWidthOverride: "0 0 0 0",
|
|
42896
|
-
padding: "0"
|
|
42897
|
-
}, /*#__PURE__*/React.createElement(Badge$1, {
|
|
42898
|
-
label: "Autopay Available",
|
|
42899
|
-
Icon: AutopayIcon
|
|
42900
|
-
})), /*#__PURE__*/React.createElement(Stack, {
|
|
42901
|
-
direction: "row",
|
|
42902
|
-
childGap: "6px"
|
|
42903
|
-
}, /*#__PURE__*/React.createElement(Text$1, {
|
|
42904
|
-
variant: "pS",
|
|
42905
|
-
color: themeValues.color,
|
|
42906
|
-
extraStyles: "text-align: right; color: transparent;",
|
|
42907
|
-
className: "show-on-hover"
|
|
42908
|
-
}, workflowActionName), workflowActionName === "Find" && /*#__PURE__*/React.createElement(PlusCircleIcon, {
|
|
42909
|
-
color: themeValues.color
|
|
42910
|
-
}), workflowActionName === "Pay" && /*#__PURE__*/React.createElement(ArrowRightIcon, {
|
|
42911
|
-
color: themeValues.color
|
|
42912
|
-
}))))));
|
|
42901
|
+
}, showLeft && leftContent, showRight && rightContent))));
|
|
42913
42902
|
};
|
|
42914
42903
|
|
|
42915
42904
|
var LinkCard$1 = themeComponent(LinkCard, "LinkCard", fallbackValues$I, "default");
|