@thecb/components 10.7.1-beta.1 → 10.7.1

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
@@ -4937,6 +4937,18 @@ var SPACING = {
4937
4937
  // Figma: Spacing/XS
4938
4938
  MD: "1.5rem" // Figma: Spacing/Normal
4939
4939
  };
4940
+ var SCREEN_READER_ONLY = {
4941
+ border: 0,
4942
+ clip: "rect(0 0 0 0)",
4943
+ clipPath: "inset(50%)",
4944
+ height: "1px",
4945
+ margin: "-1px",
4946
+ overflow: "hidden",
4947
+ padding: 0,
4948
+ position: "absolute",
4949
+ width: "1px",
4950
+ whiteSpace: "nowrap"
4951
+ };
4940
4952
 
4941
4953
  var style_constants = /*#__PURE__*/Object.freeze({
4942
4954
  __proto__: null,
@@ -4952,7 +4964,8 @@ var style_constants = /*#__PURE__*/Object.freeze({
4952
4964
  JUMBO_HEIGHT: JUMBO_HEIGHT,
4953
4965
  SPACER_HEIGHT: SPACER_HEIGHT,
4954
4966
  LINK_TEXT_DECORATION: LINK_TEXT_DECORATION,
4955
- SPACING: SPACING
4967
+ SPACING: SPACING,
4968
+ SCREEN_READER_ONLY: SCREEN_READER_ONLY
4956
4969
  });
4957
4970
 
4958
4971
  /*
@@ -19325,7 +19338,14 @@ var Alert = function Alert(_ref) {
19325
19338
  }, showQuitLink && /*#__PURE__*/React__default.createElement(Box, {
19326
19339
  padding: "0",
19327
19340
  minHeight: "100%",
19328
- onClick: onLinkClick
19341
+ onClick: onLinkClick,
19342
+ onKeyDown: function onKeyDown(e) {
19343
+ return e.key === "Enter" && onLinkClick();
19344
+ },
19345
+ role: "button",
19346
+ tabIndex: 0,
19347
+ "aria-label": "Close Alert: ".concat(heading),
19348
+ extraStyles: "cursor: pointer;"
19329
19349
  }, /*#__PURE__*/React__default.createElement(IconQuit, null))))));
19330
19350
  return /*#__PURE__*/React__default.createElement(Box, _extends({
19331
19351
  padding: padding,
@@ -39714,11 +39734,7 @@ var WalletName = function WalletName(_ref) {
39714
39734
  _ref$linkButtonExtraS = _ref.linkButtonExtraStyles,
39715
39735
  linkButtonExtraStyles = _ref$linkButtonExtraS === void 0 ? "" : _ref$linkButtonExtraS,
39716
39736
  _ref$isLoading = _ref.isLoading,
39717
- isLoading = _ref$isLoading === void 0 ? false : _ref$isLoading,
39718
- _ref$dataQa = _ref.dataQa,
39719
- dataQa = _ref$dataQa === void 0 ? null : _ref$dataQa,
39720
- _ref$actionTextPositi = _ref.actionTextPositionMobile,
39721
- actionTextPositionMobile = _ref$actionTextPositi === void 0 ? "outside" : _ref$actionTextPositi;
39737
+ isLoading = _ref$isLoading === void 0 ? false : _ref$isLoading;
39722
39738
  var _useContext = React.useContext(styled.ThemeContext),
39723
39739
  isMobile = _useContext.isMobile;
39724
39740
  return /*#__PURE__*/React__default.createElement(React.Fragment, null, /*#__PURE__*/React__default.createElement(Module$1, {
@@ -39741,18 +39757,17 @@ var WalletName = function WalletName(_ref) {
39741
39757
  radius: "10",
39742
39758
  cx: "12",
39743
39759
  cy: "12"
39744
- })) : mainText && /*#__PURE__*/React__default.createElement(Text$1, null, mainText)), (actionTextPositionMobile === "inside" || !isMobile) && /*#__PURE__*/React__default.createElement(Box, {
39760
+ })) : mainText && /*#__PURE__*/React__default.createElement(Text$1, null, mainText)), !isMobile && /*#__PURE__*/React__default.createElement(Box, {
39745
39761
  padding: "0"
39746
39762
  }, text && /*#__PURE__*/React__default.createElement(Text$1, {
39747
39763
  variant: "pXS"
39748
39764
  }, text), (text || actionText) && /*#__PURE__*/React__default.createElement(React__default.Fragment, null, "\xA0"), action && actionText && /*#__PURE__*/React__default.createElement(ButtonWithAction, {
39749
39765
  disabled: disableAction,
39750
39766
  text: actionText,
39751
- dataQa: dataQa,
39752
39767
  action: action,
39753
39768
  variant: "smallGhost",
39754
39769
  extraStyles: "\n margin: 0;\n min-width: 0;\n span {font-size: 0.75rem;}\n ".concat(linkButtonExtraStyles, "\n ")
39755
- })))), !!isMobile && actionTextPositionMobile === "outside" && /*#__PURE__*/React__default.createElement(Cluster, {
39770
+ })))), isMobile && /*#__PURE__*/React__default.createElement(Cluster, {
39756
39771
  align: "center",
39757
39772
  justify: text || actionText ? "flex-end" : "flex-start",
39758
39773
  extraStyles: "margin-top: 0.5rem;"
@@ -46379,15 +46394,13 @@ var NavMenuMobile = function NavMenuMobile(_ref2) {
46379
46394
  };
46380
46395
  var NavMenuMobile$1 = themeComponent(NavMenuMobile, "NavMenu", fallbackValues$K, "profile");
46381
46396
 
46382
- // Uses the theme values (singleIconColor) for the other icons, located in /atoms/icons
46383
-
46384
46397
  var IconsModule = function IconsModule(_ref) {
46385
46398
  var icon = _ref.icon,
46386
46399
  iconDefault = _ref.iconDefault,
46387
46400
  configIconMap = _ref.configIconMap,
46388
46401
  iconValue = _ref.iconValue,
46389
46402
  customAttributes = _ref.customAttributes,
46390
- themeValues = _ref.themeValues;
46403
+ iconColor = _ref.iconColor;
46391
46404
  var Icon;
46392
46405
  if (_typeof(icon) === "object") {
46393
46406
  var _configIconMap$iconID;
@@ -46403,10 +46416,9 @@ var IconsModule = function IconsModule(_ref) {
46403
46416
  justify: "center",
46404
46417
  align: "center"
46405
46418
  }, /*#__PURE__*/React__default.createElement(Icon, {
46406
- color: themeValues.singleIconColor
46419
+ color: iconColor
46407
46420
  })));
46408
46421
  };
46409
- var IconModule = themeComponent(IconsModule, "Icon", fallbackValues$2, "primary");
46410
46422
 
46411
46423
  var TitleModule = function TitleModule(_ref) {
46412
46424
  var title = _ref.title,
@@ -46431,22 +46443,7 @@ var TitleModule = function TitleModule(_ref) {
46431
46443
  }, subtitle)));
46432
46444
  };
46433
46445
 
46434
- var color$c = "#15749D";
46435
- var hoverColor$5 = "#116285";
46436
- var activeColor$8 = "#0E506D";
46437
- var linkColor$4 = "#3176AA";
46438
- var fontWeight$6 = FONT_WEIGHT_REGULAR;
46439
- var modalLinkHoverFocus = "outline: none;\n cursor: pointer;\n text-decoration: underline;\n text-decoration-color: #317D4F;";
46440
- var fallbackValues$L = {
46441
- color: color$c,
46442
- hoverColor: hoverColor$5,
46443
- activeColor: activeColor$8,
46444
- linkColor: linkColor$4,
46445
- fontWeight: fontWeight$6,
46446
- modalLinkHoverFocus: modalLinkHoverFocus
46447
- };
46448
-
46449
- var AutopayModal = function AutopayModal(_ref) {
46446
+ var AutopayModalModule = function AutopayModalModule(_ref) {
46450
46447
  var autoPayActive = _ref.autoPayActive,
46451
46448
  autoPaySchedule = _ref.autoPaySchedule,
46452
46449
  paymentPlanSchedule = _ref.paymentPlanSchedule,
@@ -46457,7 +46454,6 @@ var AutopayModal = function AutopayModal(_ref) {
46457
46454
  _ref$controlType = _ref.controlType,
46458
46455
  controlType = _ref$controlType === void 0 ? "tertiary" : _ref$controlType,
46459
46456
  isMobile = _ref.isMobile,
46460
- themeValues = _ref.themeValues,
46461
46457
  isPaymentPlan = _ref.isPaymentPlan,
46462
46458
  nextAutopayDate = _ref.nextAutopayDate,
46463
46459
  dueDate = _ref.dueDate,
@@ -46491,6 +46487,7 @@ var AutopayModal = function AutopayModal(_ref) {
46491
46487
  toggleModal(false);
46492
46488
  } : navigateToSettings
46493
46489
  };
46490
+ var modalLinkHoverFocus = "\n outline: none;\n cursor: pointer;\n text-decoration: underline;\n text-decoration-color: #317D4F;\n ";
46494
46491
  var hoverStyles = "text-decoration: underline;";
46495
46492
  var activeStyles = "text-decoration: underline;";
46496
46493
  var renderAutoPayControl = function renderAutoPayControl() {
@@ -46545,8 +46542,8 @@ var AutopayModal = function AutopayModal(_ref) {
46545
46542
  tabIndex: "0",
46546
46543
  dataQa: "".concat(shortPlan, " On"),
46547
46544
  color: SEA_GREEN,
46548
- weight: themeValues.fontWeight,
46549
- hoverStyles: themeValues.modalLinkHoverFocus,
46545
+ weight: FONT_WEIGHT_REGULAR,
46546
+ hoverStyles: modalLinkHoverFocus,
46550
46547
  extraStyles: "padding-left: 0.25rem;",
46551
46548
  disabled: disableActions
46552
46549
  }, "".concat(shortPlan, " ").concat(nextAutopayDate))));
@@ -46563,7 +46560,6 @@ var AutopayModal = function AutopayModal(_ref) {
46563
46560
  modalOpen: modalOpen
46564
46561
  }, modalExtraProps), renderAutoPayControl());
46565
46562
  };
46566
- var AutopayModalModule = themeComponent(AutopayModal, "AutopayModal", fallbackValues$L);
46567
46563
 
46568
46564
  var AmountModule = function AmountModule(_ref) {
46569
46565
  var totalAmountDue = _ref.totalAmountDue,
@@ -46922,6 +46918,11 @@ var InactiveTitleModule = function InactiveTitleModule(_ref) {
46922
46918
  }, "This may mean that the balance has been paid, or there was an error loading it.".concat(autoPayEnabled ? " You may disable autopay for this account by pressing the 'Turn off Autopay' button." : ""))));
46923
46919
  };
46924
46920
 
46921
+ var iconColor = ROYAL_BLUE_VIVID;
46922
+ var fallbackValues$L = {
46923
+ iconColor: iconColor
46924
+ };
46925
+
46925
46926
  var Obligation = function Obligation(_ref) {
46926
46927
  var _obligations$, _firstObligation$cust;
46927
46928
  var config = _ref.config,
@@ -46949,7 +46950,8 @@ var Obligation = function Obligation(_ref) {
46949
46950
  _ref$inactiveLookupVa = _ref.inactiveLookupValue,
46950
46951
  inactiveLookupValue = _ref$inactiveLookupVa === void 0 ? "" : _ref$inactiveLookupVa,
46951
46952
  _ref$isInCustomerMana = _ref.isInCustomerManagement,
46952
- isInCustomerManagement = _ref$isInCustomerMana === void 0 ? false : _ref$isInCustomerMana;
46953
+ isInCustomerManagement = _ref$isInCustomerMana === void 0 ? false : _ref$isInCustomerMana,
46954
+ themeValues = _ref.themeValues;
46953
46955
  /*
46954
46956
  The value of obligations is always an array. It can contain:
46955
46957
  - A single obligation
@@ -46994,12 +46996,13 @@ var Obligation = function Obligation(_ref) {
46994
46996
  }, /*#__PURE__*/React__default.createElement(Cluster, {
46995
46997
  justify: "flex-start",
46996
46998
  align: "center"
46997
- }, !isMobile && /*#__PURE__*/React__default.createElement(IconModule, {
46999
+ }, !isMobile && /*#__PURE__*/React__default.createElement(IconsModule, {
46998
47000
  icon: config.icon,
46999
47001
  iconDefault: config.iconDefault,
47000
47002
  configIconMap: config.iconMap,
47001
47003
  iconValue: config.iconValue,
47002
- customAttributes: customAttributes
47004
+ customAttributes: customAttributes,
47005
+ iconColor: themeValues.iconColor
47003
47006
  }), /*#__PURE__*/React__default.createElement(TitleModule, {
47004
47007
  title: description,
47005
47008
  subtitle: subDescription,
@@ -47086,12 +47089,13 @@ var Obligation = function Obligation(_ref) {
47086
47089
  justify: "flex-start",
47087
47090
  align: "center",
47088
47091
  nowrap: true
47089
- }, /*#__PURE__*/React__default.createElement(IconModule, {
47092
+ }, /*#__PURE__*/React__default.createElement(IconsModule, {
47090
47093
  icon: config.icon,
47091
47094
  iconDefault: config.iconDefault,
47092
47095
  configIconMap: config.iconMap,
47093
47096
  iconValue: config.iconValue,
47094
- customAttributes: customAttributes
47097
+ customAttributes: customAttributes,
47098
+ iconColor: themeValues.iconColor
47095
47099
  }), /*#__PURE__*/React__default.createElement(InactiveTitleModule, {
47096
47100
  title: inactiveLookupTitle,
47097
47101
  subtitle: "".concat(inactiveLookupInput, ": ").concat(inactiveLookupValue),
@@ -47137,6 +47141,7 @@ var Obligation = function Obligation(_ref) {
47137
47141
  }))));
47138
47142
  return inactive ? inactiveObligation : activeObligation;
47139
47143
  };
47144
+ var Obligation$1 = themeComponent(Obligation, "Obligation", fallbackValues$L);
47140
47145
 
47141
47146
  var PartialAmountField = function PartialAmountField(_ref) {
47142
47147
  var lineItem = _ref.lineItem,
@@ -47273,9 +47278,9 @@ var arrowColor = WHITE;
47273
47278
  var numberColor = MATISSE_BLUE;
47274
47279
  var hoverBackgroundColor$2 = ALABASTER_WHITE;
47275
47280
  var activeBackgroundColor$2 = WHITE;
47276
- var activeColor$9 = MATISSE_BLUE;
47281
+ var activeColor$8 = MATISSE_BLUE;
47277
47282
  var fallbackValues$M = {
47278
- activeColor: activeColor$9,
47283
+ activeColor: activeColor$8,
47279
47284
  activeBackgroundColor: activeBackgroundColor$2,
47280
47285
  arrowColor: arrowColor,
47281
47286
  hoverBackgroundColor: hoverBackgroundColor$2,
@@ -47498,11 +47503,7 @@ var PaymentButtonBar = function PaymentButtonBar(_ref) {
47498
47503
  buttonGroupStyles = _ref.buttonGroupStyles,
47499
47504
  _ref$hideAdditionalBu = _ref.hideAdditionalButton,
47500
47505
  hideAdditionalButton = _ref$hideAdditionalBu === void 0 ? false : _ref$hideAdditionalBu,
47501
- additionalButton = _ref.additionalButton,
47502
- _ref$nextButtonTestId = _ref.nextButtonTestId,
47503
- nextButtonTestId = _ref$nextButtonTestId === void 0 ? null : _ref$nextButtonTestId,
47504
- _ref$backButtonTestId = _ref.backButtonTestId,
47505
- backButtonTestId = _ref$backButtonTestId === void 0 ? null : _ref$backButtonTestId;
47506
+ additionalButton = _ref.additionalButton;
47506
47507
  var _useContext = React.useContext(styled.ThemeContext),
47507
47508
  isMobile = _useContext.isMobile;
47508
47509
  var backButton = !!cancelURL && !!cancelText ? /*#__PURE__*/React__default.createElement(ButtonWithLink, {
@@ -47510,7 +47511,7 @@ var PaymentButtonBar = function PaymentButtonBar(_ref) {
47510
47511
  url: cancelURL,
47511
47512
  variant: backButtonVariant,
47512
47513
  extraStyles: isMobile && "flex-grow: 1",
47513
- dataQa: backButtonTestId || cancelText,
47514
+ dataQa: cancelText,
47514
47515
  "aria-labelledby": "".concat(kebabCaseString(cancelText), "-button"),
47515
47516
  role: "link"
47516
47517
  }) : backButtonAction && /*#__PURE__*/React__default.createElement(ButtonWithAction, {
@@ -47527,7 +47528,7 @@ var PaymentButtonBar = function PaymentButtonBar(_ref) {
47527
47528
  text: redirectText,
47528
47529
  variant: forwardButtonVariant,
47529
47530
  extraStyles: isMobile && "flex-grow: 1",
47530
- dataQa: nextButtonTestId || redirectText,
47531
+ dataQa: redirectText,
47531
47532
  disabled: isForwardButtonDisabled,
47532
47533
  "aria-labelledby": "".concat(kebabCaseString(redirectText), "-button"),
47533
47534
  role: forwardButtonAriaRole
@@ -47537,7 +47538,7 @@ var PaymentButtonBar = function PaymentButtonBar(_ref) {
47537
47538
  action: forwardButtonAction,
47538
47539
  isLoading: forwardButtonLoading,
47539
47540
  extraStyles: isMobile && "flex-grow: 1",
47540
- dataQa: nextButtonTestId || forwardButtonText,
47541
+ dataQa: forwardButtonText,
47541
47542
  disabled: isForwardButtonDisabled,
47542
47543
  "aria-labelledby": "".concat(kebabCaseString(forwardButtonText), "-button"),
47543
47544
  role: forwardButtonAriaRole
@@ -47942,7 +47943,7 @@ var PaymentDetails = function PaymentDetails(_ref4) {
47942
47943
  };
47943
47944
  var PaymentDetails$1 = themeComponent(PaymentDetails, "PaymentDetails", fallbackValues$N, "default");
47944
47945
 
47945
- var linkColor$5 = {
47946
+ var linkColor$4 = {
47946
47947
  "default": "#3176AA"
47947
47948
  };
47948
47949
  var fontSize$a = {
@@ -47951,21 +47952,21 @@ var fontSize$a = {
47951
47952
  var lineHeight$4 = {
47952
47953
  "default": "1.5rem"
47953
47954
  };
47954
- var fontWeight$7 = {
47955
+ var fontWeight$6 = {
47955
47956
  "default": FONT_WEIGHT_REGULAR
47956
47957
  };
47957
- var modalLinkHoverFocus$1 = {
47958
+ var modalLinkHoverFocus = {
47958
47959
  "default": "outline: none; text-decoration: underline;"
47959
47960
  };
47960
47961
  var linkTextDecoration = {
47961
47962
  "default": LINK_TEXT_DECORATION
47962
47963
  };
47963
47964
  var fallbackValues$O = {
47964
- linkColor: linkColor$5,
47965
+ linkColor: linkColor$4,
47965
47966
  fontSize: fontSize$a,
47966
47967
  lineHeight: lineHeight$4,
47967
- fontWeight: fontWeight$7,
47968
- modalLinkHoverFocus: modalLinkHoverFocus$1,
47968
+ fontWeight: fontWeight$6,
47969
+ modalLinkHoverFocus: modalLinkHoverFocus,
47969
47970
  linkTextDecoration: linkTextDecoration
47970
47971
  };
47971
47972
 
@@ -48030,7 +48031,7 @@ var backgroundColor$d = {
48030
48031
  "default": "#ffffff",
48031
48032
  footer: "#ffffff"
48032
48033
  };
48033
- var linkColor$6 = {
48034
+ var linkColor$5 = {
48034
48035
  "default": "#3176AA",
48035
48036
  footer: "#ffffff"
48036
48037
  };
@@ -48046,12 +48047,12 @@ var lineHeight$5 = {
48046
48047
  "default": "1.5rem",
48047
48048
  footer: "1.25rem"
48048
48049
  };
48049
- var fontWeight$8 = {
48050
+ var fontWeight$7 = {
48050
48051
  "default": FONT_WEIGHT_REGULAR,
48051
48052
  footer: FONT_WEIGHT_SEMIBOLD
48052
48053
  };
48053
48054
  var standardInteractionStyles = "\n &:hover {\n outline: none; \n text-decoration: underline;\n }\n &:focus {\n outline: 3px solid #3181E3;\n outline-offset: 2px;\n }\n";
48054
- var modalLinkHoverFocus$2 = {
48055
+ var modalLinkHoverFocus$1 = {
48055
48056
  "default": standardInteractionStyles,
48056
48057
  footer: standardInteractionStyles
48057
48058
  };
@@ -48061,12 +48062,12 @@ var modalLinkTextDecoration = {
48061
48062
  };
48062
48063
  var fallbackValues$P = {
48063
48064
  backgroundColor: backgroundColor$d,
48064
- linkColor: linkColor$6,
48065
+ linkColor: linkColor$5,
48065
48066
  border: border$3,
48066
48067
  fontSize: fontSize$b,
48067
48068
  lineHeight: lineHeight$5,
48068
- fontWeight: fontWeight$8,
48069
- modalLinkHoverFocus: modalLinkHoverFocus$2,
48069
+ fontWeight: fontWeight$7,
48070
+ modalLinkHoverFocus: modalLinkHoverFocus$1,
48070
48071
  modalLinkTextDecoration: modalLinkTextDecoration
48071
48072
  };
48072
48073
 
@@ -49061,7 +49062,7 @@ var InnerRadioSection = function InnerRadioSection(_ref) {
49061
49062
  }, section.content))));
49062
49063
  };
49063
49064
 
49064
- var _excluded$E = ["themeValues", "isMobile", "supportsTouch", "sections", "openSection", "toggleOpenSection", "staggeredAnimation", "initiallyOpen", "openHeight", "containerStyles", "ariaDescribedBy", "isSectionRequired", "groupedSections", "borderOverride"];
49065
+ var _excluded$E = ["themeValues", "isMobile", "supportsTouch", "sections", "openSection", "toggleOpenSection", "staggeredAnimation", "initiallyOpen", "openHeight", "containerStyles", "ariaDescribedBy", "isSectionRequired", "groupedSections"];
49065
49066
 
49066
49067
  /**
49067
49068
  - The RadioSection component takes either a flat array (via the 'sections'
@@ -49109,7 +49110,6 @@ var RadioSection = function RadioSection(_ref) {
49109
49110
  _ref$isSectionRequire = _ref.isSectionRequired,
49110
49111
  isSectionRequired = _ref$isSectionRequire === void 0 ? false : _ref$isSectionRequire,
49111
49112
  groupedSections = _ref.groupedSections,
49112
- borderOverride = _ref.borderOverride,
49113
49113
  rest = _objectWithoutProperties(_ref, _excluded$E);
49114
49114
  var _useState = React.useState(null),
49115
49115
  _useState2 = _slicedToArray(_useState, 2),
@@ -49142,7 +49142,7 @@ var RadioSection = function RadioSection(_ref) {
49142
49142
  };
49143
49143
  return /*#__PURE__*/React__default.createElement(Box, _extends({
49144
49144
  padding: "1px",
49145
- border: borderOverride || "1px solid ".concat(themeValues.borderColor),
49145
+ border: "1px solid ".concat(themeValues.borderColor),
49146
49146
  borderRadius: "4px",
49147
49147
  extraStyles: containerStyles,
49148
49148
  role: "radiogroup",
@@ -49657,7 +49657,7 @@ var Timeout = function Timeout(_ref) {
49657
49657
  };
49658
49658
  var Timeout$1 = withWindowSize(Timeout);
49659
49659
 
49660
- var _excluded$F = ["variant", "message", "toastOpen", "closeToastNotification", "extraStyles", "minWidth", "maxWidth", "height", "childGap", "backgroundColor", "role", "ariaLive"];
49660
+ var _excluded$F = ["variant", "message", "toastOpen", "closeToastNotification", "extraStyles", "minWidth", "maxWidth", "height", "childGap", "backgroundColor", "role", "ariaLive", "screenReaderMessage", "showScreenReaderMessage"];
49661
49661
  var VARIANTS = {
49662
49662
  SUCCESS: "success",
49663
49663
  ERROR: "error"
@@ -49680,11 +49680,28 @@ var ToastNotification = function ToastNotification(_ref) {
49680
49680
  childGap = _ref$childGap === void 0 ? "1rem" : _ref$childGap,
49681
49681
  backgroundColor = _ref.backgroundColor,
49682
49682
  _ref$role = _ref.role,
49683
- role = _ref$role === void 0 ? "alert" : _ref$role,
49683
+ role = _ref$role === void 0 ? "status" : _ref$role,
49684
49684
  _ref$ariaLive = _ref.ariaLive,
49685
49685
  ariaLive = _ref$ariaLive === void 0 ? "polite" : _ref$ariaLive,
49686
+ screenReaderMessage = _ref.screenReaderMessage,
49687
+ _ref$showScreenReader = _ref.showScreenReaderMessage,
49688
+ showScreenReaderMessage = _ref$showScreenReader === void 0 ? true : _ref$showScreenReader,
49686
49689
  rest = _objectWithoutProperties(_ref, _excluded$F);
49687
- return /*#__PURE__*/React__default.createElement(Box, _extends({
49690
+ var screenReaderMessageRef = React.useRef();
49691
+ var LIVEREGION_TRANSITION_DELAY = 1000;
49692
+ React.useEffect(function () {
49693
+ if (showScreenReaderMessage) {
49694
+ var timeout = setTimeout(function () {
49695
+ if (screenReaderMessageRef.current) {
49696
+ screenReaderMessageRef.current.textContent = "".concat(screenReaderMessage ? screenReaderMessage : message ? message : "");
49697
+ }
49698
+ }, LIVEREGION_TRANSITION_DELAY);
49699
+ return function () {
49700
+ return clearTimeout(timeout);
49701
+ };
49702
+ }
49703
+ }, [showScreenReaderMessage, screenReaderMessage, message]);
49704
+ return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(Box, _extends({
49688
49705
  onClick: closeToastNotification,
49689
49706
  onKeyDown: function onKeyDown(e) {
49690
49707
  return e.key === "Enter" && closeToastNotification();
@@ -49697,9 +49714,7 @@ var ToastNotification = function ToastNotification(_ref) {
49697
49714
  padding: "0rem 1rem",
49698
49715
  borderRadius: "4px",
49699
49716
  boxShadow: generateShadows().standard.base,
49700
- extraStyles: "\n display: ".concat(toastOpen ? "block" : "none", ";\n position: fixed; bottom: 4rem; left: 4rem;\n ").concat(extraStyles, ";\n cursor: pointer;\n "),
49701
- role: role,
49702
- "aria-live": ariaLive
49717
+ extraStyles: "\n display: ".concat(toastOpen ? "block" : "none", ";\n position: fixed; bottom: 4rem; left: 4rem;\n ").concat(extraStyles, ";\n cursor: pointer;\n ")
49703
49718
  }, rest), /*#__PURE__*/React__default.createElement(Cluster, {
49704
49719
  align: "center",
49705
49720
  childGap: childGap,
@@ -49713,16 +49728,22 @@ var ToastNotification = function ToastNotification(_ref) {
49713
49728
  }, /*#__PURE__*/React__default.createElement(Paragraph$1, {
49714
49729
  weight: FONT_WEIGHT_SEMIBOLD,
49715
49730
  extraStyles: "word-break: break-word;"
49716
- }, message))), /*#__PURE__*/React__default.createElement(IconQuitLarge, null)));
49731
+ }, message))), /*#__PURE__*/React__default.createElement(IconQuitLarge, null))), showScreenReaderMessage && /*#__PURE__*/React__default.createElement("span", {
49732
+ ref: screenReaderMessageRef,
49733
+ style: SCREEN_READER_ONLY,
49734
+ role: role,
49735
+ "aria-live": ariaLive,
49736
+ "aria-atomic": true
49737
+ }));
49717
49738
  };
49718
49739
 
49719
- var fontWeight$9 = "600";
49740
+ var fontWeight$8 = "600";
49720
49741
  var fontColor$1 = WHITE;
49721
49742
  var textAlign$1 = "left";
49722
49743
  var headerBackgroundColor$1 = BRIGHT_GREY;
49723
49744
  var imageBackgroundColor$1 = MATISSE_BLUE;
49724
49745
  var fallbackValues$V = {
49725
- fontWeight: fontWeight$9,
49746
+ fontWeight: fontWeight$8,
49726
49747
  fontColor: fontColor$1,
49727
49748
  textAlign: textAlign$1,
49728
49749
  headerBackgroundColor: headerBackgroundColor$1,
@@ -49895,13 +49916,13 @@ var PopupMenuItem = function PopupMenuItem(_ref) {
49895
49916
  };
49896
49917
  var PopupMenuItem$1 = themeComponent(PopupMenuItem, "PopupMenuItem", fallbackValues$W);
49897
49918
 
49898
- var hoverColor$6 = "#116285";
49899
- var activeColor$a = "#0E506D";
49919
+ var hoverColor$5 = "#116285";
49920
+ var activeColor$9 = "#0E506D";
49900
49921
  var menuTriggerColor = "#15749D";
49901
49922
  var backgroundColor$e = "white";
49902
49923
  var fallbackValues$X = {
49903
- hoverColor: hoverColor$6,
49904
- activeColor: activeColor$a,
49924
+ hoverColor: hoverColor$5,
49925
+ activeColor: activeColor$9,
49905
49926
  menuTriggerColor: menuTriggerColor,
49906
49927
  backgroundColor: backgroundColor$e
49907
49928
  };
@@ -50452,7 +50473,7 @@ exports.NavTabs = NavTabs;
50452
50473
  exports.NoCustomerResultsIcon = NoCustomerResultsIcon;
50453
50474
  exports.NoPaymentResultsIcon = NoPaymentResultsIcon;
50454
50475
  exports.NotFoundIcon = NotFoundIcon;
50455
- exports.Obligation = Obligation;
50476
+ exports.Obligation = Obligation$1;
50456
50477
  exports.ObligationIcons = iconsMap;
50457
50478
  exports.Pagination = Pagination$1;
50458
50479
  exports.Paragraph = Paragraph$1;