@thecb/components 12.0.0-beta.2 → 12.0.0-beta.4

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.esm.js CHANGED
@@ -45806,9 +45806,8 @@ var disabledBorderColor$1 = GHOST_GREY;
45806
45806
  var disabledColor$2 = MANATEE_GREY;
45807
45807
  var activeBackgroundColor$1 = CORNFLOWER_BLUE;
45808
45808
  var backgroundColor$a = LINK_WATER;
45809
- var borderColor$5 = MANATEE_GREY;
45809
+ var borderColor$5 = MOON_RAKER;
45810
45810
  var color$c = ROYAL_BLUE_VIVID;
45811
- var textColor$5 = BRIGHT_GREY;
45812
45811
  var fallbackValues$L = {
45813
45812
  disabledBackgroundColor: disabledBackgroundColor$1,
45814
45813
  disabledBorderColor: disabledBorderColor$1,
@@ -45816,37 +45815,39 @@ var fallbackValues$L = {
45816
45815
  activeBackgroundColor: activeBackgroundColor$1,
45817
45816
  backgroundColor: backgroundColor$a,
45818
45817
  borderColor: borderColor$5,
45819
- color: color$c,
45820
- textColor: textColor$5
45818
+ color: color$c
45821
45819
  };
45822
45820
 
45823
- var Container = styled(Box).withConfig({
45824
- displayName: "LinkCardstyled__Container",
45821
+ var LinkWrapper = styled(Link).withConfig({
45822
+ displayName: "LinkCardstyled__LinkWrapper",
45825
45823
  componentId: "sc-l5q1h2-0"
45826
- })(["display:flex;flex-direction:column;align-items:flex-start;align-self:stretch;border-radius:8px;padding:24px;", " text-decoration:none;transition:all 0.2s ease-in-out;", ""], function (_ref) {
45827
- var disabled = _ref.disabled,
45828
- themeValues = _ref.themeValues;
45829
- return "\n background-color: ".concat(disabled ? themeValues.disabledBackgroundColor : themeValues.backgroundColor, ";\n border: 1px solid ").concat(disabled ? themeValues.disabledBorderColor : themeValues.borderColor, ";\n ");
45824
+ })(["display:flex;flex-direction:column;align-items:flex-start;width:100%;gap:40px;flex-shrink:0;padding:24px;max-width:", ";min-height:141px;align-self:stretch;border-radius:8px;text-decoration:none;", " transition:all .2s ease-in-out;", ""], function (_ref) {
45825
+ var isMobile = _ref.isMobile;
45826
+ return isMobile ? "100%" : "288px";
45830
45827
  }, function (_ref2) {
45831
- var disabled = _ref2.disabled,
45832
- themeValues = _ref2.themeValues;
45833
- return disabled ? "\n &:hover,\n &:active {\n cursor: default;\n box-shadow: none;\n border: 1px solid ".concat(themeValues.disabledBorderColor, ";\n }\n ") : "\n &:hover,\n &:active {\n cursor: pointer;\n box-shadow: 0px 0px 0px 0px rgba(41, 42, 51, 0.1),\n 0px 5px 11px 0px rgba(41, 42, 51, 0.1),\n 0px 4px 19px 0px rgba(41, 42, 51, 0.09),\n 0px 27px 26px 0px rgba(41, 42, 51, 0.05),\n 0px 56px 31px 0px rgba(41, 42, 51, 0.01),\n 0px 80px 33px 0px rgba(41, 42, 51, 0);\n }\n\n &:hover:not(:active) {\n border: 1px solid ".concat(themeValues.borderColor, ";\n }\n\n &:active {\n background-color: ").concat(themeValues.activeBackgroundColor, ";\n border: ").concat(BORDER_THIN, " solid ").concat(themeValues.borderColor, ";\n }\n ");
45828
+ var isDisabled = _ref2.isDisabled,
45829
+ theme = _ref2.theme;
45830
+ return "\n background-color: ".concat(isDisabled ? theme.disabledBackgroundColor : theme.backgroundColor, ";\n border: 1px solid ").concat(isDisabled ? theme.disabledBorderColor : theme.borderColor, ";\n ");
45831
+ }, function (_ref3) {
45832
+ var isDisabled = _ref3.isDisabled,
45833
+ theme = _ref3.theme;
45834
+ return isDisabled ? "\n &:hover,\n &:active {\n cursor: default;\n box-shadow: none;\n border: 1px solid ".concat(theme.disabledBorderColor, ";\n }\n ") : "\n &:hover,\n &:active {\n cursor: pointer;\n box-shadow: 0px 0px 0px 0px rgba(41, 42, 51, 0.1),\n 0px 5px 11px 0px rgba(41, 42, 51, 0.1),\n 0px 4px 19px 0px rgba(41, 42, 51, 0.09),\n 0px 27px 26px 0px rgba(41, 42, 51, 0.05),\n 0px 56px 31px 0px rgba(41, 42, 51, 0.01),\n 0px 80px 33px 0px rgba(41, 42, 51, 0);\n }\n\n &:hover:not(:active) {\n border: 1px solid ".concat(theme.borderColor, ";\n }\n\n &:active {\n background-color: ").concat(theme.activeBackgroundColor, ";\n border: 1px solid ").concat(theme.borderColor, ";\n }\n ");
45834
45835
  });
45835
45836
  var Title$2 = styled(Heading$1).withConfig({
45836
45837
  displayName: "LinkCardstyled__Title",
45837
45838
  componentId: "sc-l5q1h2-1"
45838
- })(["display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;align-self:stretch;overflow:hidden;text-overflow:ellipsis;font-size:", ";line-height:150%;background-color:transparent;font-weight:", ";", ";"], FONT_SIZE.MD, FONT_WEIGHT_SEMIBOLD, function (_ref3) {
45839
- var disabled = _ref3.disabled,
45840
- themeValues = _ref3.themeValues;
45841
- return "color: ".concat(disabled ? themeValues.disabledColor : themeValues.color, ";");
45839
+ })(["display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;align-self:stretch;overflow:hidden;text-overflow:ellipsis;font-size:16px;line-height:150%;background-color:transparent;font-weight:", ";", ";"], FONT_WEIGHT_SEMIBOLD, function (_ref4) {
45840
+ var isDisabled = _ref4.isDisabled,
45841
+ theme = _ref4.theme;
45842
+ return "color: ".concat(isDisabled ? theme.disabledColor : theme.color, ";");
45842
45843
  });
45843
45844
  var Subtitle = styled(Paragraph$1).withConfig({
45844
45845
  displayName: "LinkCardstyled__Subtitle",
45845
45846
  componentId: "sc-l5q1h2-2"
45846
- })(["overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;align-self:stretch;font-size:", ";line-height:150%;letter-spacing:0.14px;font-weight:", ";", ";"], FONT_SIZE.SM, FONT_WEIGHT_REGULAR, function (_ref4) {
45847
- var disabled = _ref4.disabled,
45848
- themeValues = _ref4.themeValues;
45849
- return "color: ".concat(disabled ? themeValues.disabledColor : themeValues.textColor, ";");
45847
+ })(["overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;align-self:stretch;font-size:14px;line-height:150%;letter-spacing:0.14px;font-weight:", ";", ";"], FONT_WEIGHT_REGULAR, function (_ref5) {
45848
+ var isDisabled = _ref5.isDisabled,
45849
+ theme = _ref5.theme;
45850
+ return "color: ".concat(isDisabled ? theme.disabledColor : theme.textColor, ";");
45850
45851
  });
45851
45852
  var Footer = styled(Stack).withConfig({
45852
45853
  displayName: "LinkCardstyled__Footer",
@@ -45865,6 +45866,7 @@ var LinkCard = function LinkCard(_ref) {
45865
45866
  leftContent = _ref.leftContent,
45866
45867
  showRight = _ref.showRight,
45867
45868
  rightContent = _ref.rightContent,
45869
+ href = _ref.href,
45868
45870
  _ref$extraStyles = _ref.extraStyles,
45869
45871
  extraStyles = _ref$extraStyles === void 0 ? "" : _ref$extraStyles,
45870
45872
  _ref$extraHoverStyles = _ref.extraHoverStyles,
@@ -45877,26 +45879,23 @@ var LinkCard = function LinkCard(_ref) {
45877
45879
  _ref$disabled = _ref.disabled,
45878
45880
  disabled = _ref$disabled === void 0 ? false : _ref$disabled,
45879
45881
  _ref$isExternalLink = _ref.isExternalLink,
45880
- isExternalLink = _ref$isExternalLink === void 0 ? false : _ref$isExternalLink,
45881
- _ref$href = _ref.href,
45882
- href = _ref$href === void 0 ? "" : _ref$href;
45882
+ isExternalLink = _ref$isExternalLink === void 0 ? false : _ref$isExternalLink;
45883
45883
  var _useContext = useContext(ThemeContext),
45884
45884
  isMobile = _useContext.isMobile;
45885
45885
  var regex = /\W/g;
45886
45886
  var locatorSlug = title === null || title === void 0 || (_title$toLowerCase = title.toLowerCase) === null || _title$toLowerCase === void 0 || (_title$toLowerCase = _title$toLowerCase.call(title)) === null || _title$toLowerCase === void 0 || (_title$toLowerCase$re = _title$toLowerCase.replaceAll) === null || _title$toLowerCase$re === void 0 ? void 0 : _title$toLowerCase$re.call(_title$toLowerCase, regex, "-");
45887
- return /*#__PURE__*/React__default.createElement(Container, {
45888
- as: "a",
45887
+ return /*#__PURE__*/React__default.createElement(LinkWrapper, {
45888
+ as: Link,
45889
+ to: disabled ? undefined : href,
45889
45890
  role: "link",
45890
- href: disabled ? undefined : href,
45891
- tabIndex: disabled ? -1 : 0,
45892
- borderRadius: "8px",
45891
+ isMobile: isMobile,
45893
45892
  dataQa: "link-card-".concat(locatorSlug),
45894
- themeValues: themeValues,
45893
+ theme: themeValues,
45895
45894
  extraStyles: extraStyles,
45896
45895
  hoverStyles: extraHoverStyles,
45897
45896
  activeStyles: extraActiveStyles,
45898
45897
  "aria-disabled": disabled,
45899
- disabled: disabled,
45898
+ isDisabled: disabled,
45900
45899
  "aria-label": "".concat(title, ", ").concat(subtitle)
45901
45900
  }, /*#__PURE__*/React__default.createElement(Stack, {
45902
45901
  childGap: 0,
@@ -45912,9 +45911,9 @@ var LinkCard = function LinkCard(_ref) {
45912
45911
  extraStyles: "align-items: center;"
45913
45912
  }, /*#__PURE__*/React__default.createElement(Title$2, {
45914
45913
  variant: titleVariant,
45915
- themeValues: themeValues,
45914
+ theme: themeValues,
45916
45915
  margin: 0,
45917
- disabled: disabled
45916
+ isDisabled: disabled
45918
45917
  }, title), isExternalLink && /*#__PURE__*/React__default.createElement(ExternalLinkIcon, {
45919
45918
  linkColor: themeValues.color,
45920
45919
  text: locatorSlug,
@@ -45927,8 +45926,8 @@ var LinkCard = function LinkCard(_ref) {
45927
45926
  width: "100%"
45928
45927
  }, /*#__PURE__*/React__default.createElement(Subtitle, {
45929
45928
  variant: "pS",
45930
- themeValues: themeValues,
45931
- disabled: disabled
45929
+ theme: themeValues,
45930
+ isDisabled: disabled
45932
45931
  }, subtitle)), /*#__PURE__*/React__default.createElement(Box, {
45933
45932
  background: "transparent",
45934
45933
  borderWidthOverride: "0 0 0 0",
@@ -50914,7 +50913,7 @@ var MultipleSelectFilter = function MultipleSelectFilter(_ref) {
50914
50913
  var MultipleSelectFilter$1 = themeComponent(MultipleSelectFilter, "MultipleSelectFilter", fallbackValues$10);
50915
50914
 
50916
50915
  var TextWrapStyles = css(["word-wrap:break-word;overflow-wrap:break-word;white-space:normal;max-width:100%;"]);
50917
- var Container$1 = styled(Box).withConfig({
50916
+ var Container = styled(Box).withConfig({
50918
50917
  displayName: "ContactCardstyled__Container",
50919
50918
  componentId: "sc-1v62a1n-0"
50920
50919
  })(["height:fit-content;display:flex;padding:1rem;flex-direction:column;align-items:flex-start;gap:1.5rem;border-radius:8px;", ""], function (_ref) {
@@ -50952,7 +50951,7 @@ var ContactCard = function ContactCard(_ref) {
50952
50951
  externalLinkColor: ROYAL_BLUE_VIVID
50953
50952
  };
50954
50953
  var linkThemeValues = createThemeValues(themeContext, linkFallbackValues, "Link", linkVariant);
50955
- return /*#__PURE__*/React__default.createElement(Container$1, {
50954
+ return /*#__PURE__*/React__default.createElement(Container, {
50956
50955
  borderRadius: "8px",
50957
50956
  background: WHITE,
50958
50957
  boxShadow: "0px 2px 4px rgba(0, 0, 0, 0.25)",
@@ -51466,12 +51465,12 @@ var TurnstileWidget = /*#__PURE__*/forwardRef(function (_ref4, ref) {
51466
51465
  var hoverColor$6 = ROYAL_BLUE;
51467
51466
  var activeColor$b = CONGRESS_BLUE;
51468
51467
  var linkColor$6 = ROYAL_BLUE_VIVID;
51469
- var textColor$6 = CHARADE_GREY;
51468
+ var textColor$5 = CHARADE_GREY;
51470
51469
  var fallbackValues$12 = {
51471
51470
  linkColor: linkColor$6,
51472
51471
  hoverColor: hoverColor$6,
51473
51472
  activeColor: activeColor$b,
51474
- textColor: textColor$6
51473
+ textColor: textColor$5
51475
51474
  };
51476
51475
 
51477
51476
  var TOOLTIP_THEME_SOURCE = "Popover";