@thecb/components 4.1.15 → 4.1.16-beta.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 (22) hide show
  1. package/dist/index.cjs.js +201 -435
  2. package/package.json +1 -1
  3. package/src/components/atoms/checkbox/Checkbox.js +64 -49
  4. package/src/components/atoms/dropdown/Dropdown.js +2 -2
  5. package/src/components/atoms/form-select/FormSelect.js +6 -4
  6. package/src/components/atoms/form-select/FormSelect.styled.js +0 -17
  7. package/src/components/atoms/text/Text.js +2 -0
  8. package/src/components/molecules/account-and-routing-modal/AccountAndRoutingModal.js +14 -16
  9. package/src/components/molecules/account-and-routing-modal/AccountAndRoutingModal.theme.js +6 -11
  10. package/src/components/molecules/address-form/AddressForm.js +7 -27
  11. package/src/components/molecules/email-form/EmailForm.js +7 -27
  12. package/src/components/molecules/email-form/EmailForm.stories.js +4 -1
  13. package/src/components/molecules/modal/Modal.js +3 -3
  14. package/src/components/molecules/obligation/modules/AmountModule.stories.js +27 -0
  15. package/src/components/molecules/obligation/modules/AutopayModalModule.js +47 -38
  16. package/src/components/molecules/obligation/modules/AutopayModalModule.theme.js +12 -1
  17. package/src/components/molecules/payment-form-ach/PaymentFormACH.js +22 -57
  18. package/src/components/molecules/payment-form-card/PaymentFormCard.js +7 -26
  19. package/src/components/molecules/phone-form/PhoneForm.js +7 -27
  20. package/src/components/molecules/terms-and-conditions/TermsAndConditions.js +15 -45
  21. package/src/components/molecules/terms-and-conditions-modal/TermsAndConditionsModal.js +14 -15
  22. package/src/components/molecules/terms-and-conditions-modal/TermsAndConditionsModal.theme.js +1 -1
package/dist/index.cjs.js CHANGED
@@ -6121,10 +6121,11 @@ var Text = function Text(_ref) {
6121
6121
  extraStyles = _ref$extraStyles === void 0 ? "" : _ref$extraStyles,
6122
6122
  hoverStyles = _ref.hoverStyles,
6123
6123
  onClick = _ref.onClick,
6124
+ onKeyPress = _ref.onKeyPress,
6124
6125
  as = _ref.as,
6125
6126
  dataQa = _ref.dataQa,
6126
6127
  children = _ref.children,
6127
- rest = _objectWithoutProperties(_ref, ["themeValues", "weight", "color", "extraStyles", "hoverStyles", "onClick", "as", "dataQa", "children"]);
6128
+ rest = _objectWithoutProperties(_ref, ["themeValues", "weight", "color", "extraStyles", "hoverStyles", "onClick", "onKeyPress", "as", "dataQa", "children"]);
6128
6129
 
6129
6130
  return /*#__PURE__*/React__default.createElement(TextSpan, _extends({
6130
6131
  fontSize: themeValues.fontSize,
@@ -6135,6 +6136,7 @@ var Text = function Text(_ref) {
6135
6136
  extraStyles: extraStyles,
6136
6137
  hoverStyles: hoverStyles,
6137
6138
  onClick: onClick,
6139
+ onKeyPress: onKeyPress,
6138
6140
  "data-qa": dataQa
6139
6141
  }, rest), safeChildren(children, /*#__PURE__*/React__default.createElement("span", null)));
6140
6142
  };
@@ -18372,7 +18374,7 @@ function _templateObject8() {
18372
18374
  }
18373
18375
 
18374
18376
  function _templateObject7() {
18375
- var data = _taggedTemplateLiteral(["\n display: inline-block;\n width: 24px;\n height: 24px;\n border-radius: 2px;\n transition: all 150ms;\n\n ", " {\n visibility: ", ";\n }\n\n ", ";\n"]);
18377
+ var data = _taggedTemplateLiteral(["\n display: inline-block;\n margin-right: 16px;\n width: 24px;\n height: 24px;\n border-radius: 2px;\n transition: all 150ms;\n\n ", " {\n visibility: ", ";\n }\n\n ", ";\n"]);
18376
18378
 
18377
18379
  _templateObject7 = function _templateObject7() {
18378
18380
  return data;
@@ -18475,17 +18477,38 @@ var Checkbox = function Checkbox(_ref4) {
18475
18477
  onChange = _ref4$onChange === void 0 ? noop : _ref4$onChange,
18476
18478
  _ref4$disabled = _ref4.disabled,
18477
18479
  disabled = _ref4$disabled === void 0 ? false : _ref4$disabled,
18478
- _ref4$focused = _ref4.focused,
18479
- focused = _ref4$focused === void 0 ? false : _ref4$focused,
18480
18480
  themeValues = _ref4.themeValues,
18481
18481
  _ref4$hidden = _ref4.hidden,
18482
18482
  hidden = _ref4$hidden === void 0 ? false : _ref4$hidden,
18483
18483
  _ref4$error = _ref4.error,
18484
18484
  error = _ref4$error === void 0 ? false : _ref4$error;
18485
+
18486
+ var _useState = React.useState(false),
18487
+ _useState2 = _slicedToArray(_useState, 2),
18488
+ focused = _useState2[0],
18489
+ setFocused = _useState2[1];
18490
+
18491
+ var handleClick = function handleClick(e, func) {
18492
+ if ((e === null || e === void 0 ? void 0 : e.keyCode) === 13) {
18493
+ func();
18494
+ }
18495
+ };
18496
+
18485
18497
  return /*#__PURE__*/React__default.createElement(Box, {
18486
18498
  padding: "0",
18499
+ tabIndex: "0",
18500
+ onFocus: function onFocus() {
18501
+ return setFocused(true);
18502
+ },
18503
+ onBlur: function onBlur() {
18504
+ return setFocused(false);
18505
+ },
18506
+ onKeyDown: function onKeyDown(e) {
18507
+ return handleClick(e, onChange);
18508
+ },
18487
18509
  hiddenStyles: hidden,
18488
- background: themeValues.backgroundColor
18510
+ background: themeValues.backgroundColor,
18511
+ extraStyles: "outline: none;"
18489
18512
  }, /*#__PURE__*/React__default.createElement(CheckboxLabelContainer, null, /*#__PURE__*/React__default.createElement(CheckboxContainer, {
18490
18513
  "data-qa": "Checkbox"
18491
18514
  }, /*#__PURE__*/React__default.createElement(HiddenCheckbox, {
@@ -19008,7 +19031,6 @@ var Dropdown = function Dropdown(_ref9) {
19008
19031
  return /*#__PURE__*/React__default.createElement(Box, {
19009
19032
  onKeyDown: onKeyDown,
19010
19033
  onClick: onClick,
19011
- tabIndex: 0,
19012
19034
  padding: "0",
19013
19035
  width: "100%",
19014
19036
  hoverStyles: "background-color: ".concat(themeValues.hoverColor, ";"),
@@ -19022,7 +19044,8 @@ var Dropdown = function Dropdown(_ref9) {
19022
19044
  borderSize: "1px",
19023
19045
  borderColor: isError ? ERROR_COLOR : isOpen ? themeValues.selectedColor : GREY_CHATEAU,
19024
19046
  borderRadius: "2px",
19025
- extraStyles: "tabindex: 0; height: 48px;",
19047
+ tabIndex: 0,
19048
+ extraStyles: "height: 48px;",
19026
19049
  dataQa: placeholder
19027
19050
  }, /*#__PURE__*/React__default.createElement(Stack, {
19028
19051
  direction: "row",
@@ -19071,18 +19094,8 @@ var Dropdown = function Dropdown(_ref9) {
19071
19094
 
19072
19095
  var Dropdown$1 = themeComponent(Dropdown, "Dropdown", fallbackValues$e);
19073
19096
 
19074
- function _templateObject4$3() {
19075
- var data = _taggedTemplateLiteral([""]);
19076
-
19077
- _templateObject4$3 = function _templateObject4() {
19078
- return data;
19079
- };
19080
-
19081
- return data;
19082
- }
19083
-
19084
19097
  function _templateObject3$6() {
19085
- var data = _taggedTemplateLiteral(["\n border: 1px solid\n ", ";\n border-radius: 2px;\n height: 48px;\n width: 100%;\n padding: 0.75rem 1rem;\n min-width: 100px;\n margin: 0;\n box-sizing: border-box;\n position: relative;\n font-size: 1.1rem;\n font-family: Public Sans;\n line-height: 2rem;\n font-weight: ", ";\n background-color: ", ";\n color: ", ";\n box-shadow: none;\n\n &:focus {\n border: 1px solid ", ";\n }\n"]);
19098
+ var data = _taggedTemplateLiteral([""]);
19086
19099
 
19087
19100
  _templateObject3$6 = function _templateObject3() {
19088
19101
  return data;
@@ -19092,7 +19105,7 @@ function _templateObject3$6() {
19092
19105
  }
19093
19106
 
19094
19107
  function _templateObject2$c() {
19095
- var data = _taggedTemplateLiteral(["\n color: ", ";\n font-size: 14px;\n line-height: 18px;\n font-weight: ", ";\n margin-bottom: 4px;\n font-family: Public Sans;\n\n &::first-letter {\n text-transform: uppercase;\n }\n"]);
19108
+ var data = _taggedTemplateLiteral(["\n border: 1px solid\n ", ";\n border-radius: 2px;\n height: 48px;\n width: 100%;\n padding: 0.75rem 1rem;\n min-width: 100px;\n margin: 0;\n box-sizing: border-box;\n position: relative;\n font-size: 1.1rem;\n font-family: Public Sans;\n line-height: 2rem;\n font-weight: ", ";\n background-color: ", ";\n color: ", ";\n box-shadow: none;\n\n &:focus {\n border: 1px solid ", ";\n }\n"]);
19096
19109
 
19097
19110
  _templateObject2$c = function _templateObject2() {
19098
19111
  return data;
@@ -19111,23 +19124,18 @@ function _templateObject$o() {
19111
19124
  return data;
19112
19125
  }
19113
19126
  var SelectContainer = styled__default.div(_templateObject$o());
19114
- var SelectLabel = styled__default.label(_templateObject2$c(), function (_ref) {
19127
+ var SelectField = styled__default.select(_templateObject2$c(), function (_ref) {
19115
19128
  var field = _ref.field,
19116
19129
  showErrors = _ref.showErrors;
19117
- return field.dirty && field.hasErrors || field.hasErrors && showErrors ? ERROR_COLOR : STORM_GREY;
19118
- }, FONT_WEIGHT_REGULAR);
19119
- var SelectField = styled__default.select(_templateObject3$6(), function (_ref2) {
19120
- var field = _ref2.field,
19121
- showErrors = _ref2.showErrors;
19122
19130
  return field.dirty && field.hasErrors || field.hasErrors && showErrors ? ERROR_COLOR : GHOST_GREY;
19123
- }, FONT_WEIGHT_REGULAR, function (_ref3) {
19124
- var themeValues = _ref3.themeValues;
19131
+ }, FONT_WEIGHT_REGULAR, function (_ref2) {
19132
+ var themeValues = _ref2.themeValues;
19125
19133
  return themeValues.inputBackgroundColor && themeValues.inputBackgroundColor;
19126
- }, function (_ref4) {
19127
- var themeValues = _ref4.themeValues;
19134
+ }, function (_ref3) {
19135
+ var themeValues = _ref3.themeValues;
19128
19136
  return themeValues.color && themeValues.color;
19129
19137
  }, MATISSE_BLUE);
19130
- var SelectOption = styled__default.option(_templateObject4$3());
19138
+ var SelectOption = styled__default.option(_templateObject3$6());
19131
19139
 
19132
19140
  var linkColor$1 = {
19133
19141
  "default": "".concat(MATISSE_BLUE),
@@ -19233,8 +19241,10 @@ var FormSelect = function FormSelect(_ref) {
19233
19241
  variant: "pS",
19234
19242
  color: themeValues.labelColor,
19235
19243
  weight: themeValues.fontWeight,
19236
- extraStyles: "word-break: break-word;\n font-family: Public Sans;\n &::first-letter {\n text-transform: uppercase;\n }"
19244
+ extraStyles: "word-break: break-word;\n font-family: Public Sans;\n &::first-letter {\n text-transform: uppercase;\n }",
19245
+ id: labelTextWhenNoError.replace(/\s+/g, "-")
19237
19246
  }, labelTextWhenNoError))), /*#__PURE__*/React__default.createElement(Dropdown$1, {
19247
+ "aria-labelledby": labelTextWhenNoError.replace(/\s+/g, "-"),
19238
19248
  maxHeight: dropdownMaxHeight,
19239
19249
  placeholder: options[0] ? options[0].text : "",
19240
19250
  options: options,
@@ -19250,9 +19260,9 @@ var FormSelect = function FormSelect(_ref) {
19250
19260
  onClick: function onClick() {
19251
19261
  return setOpen(!open);
19252
19262
  }
19253
- }), /*#__PURE__*/React__default.createElement(SelectLabel, {
19254
- field: field,
19255
- showErrors: showErrors
19263
+ }), /*#__PURE__*/React__default.createElement(Stack, {
19264
+ direction: "row",
19265
+ justify: "space-between"
19256
19266
  }, field.hasErrors && field.dirty || field.hasErrors && showErrors ? /*#__PURE__*/React__default.createElement(Text$1, {
19257
19267
  color: ERROR_COLOR,
19258
19268
  variant: "pXS",
@@ -20456,10 +20466,10 @@ var fallbackValues$h = {
20456
20466
  hoverFocusStyles: hoverFocusStyles$1
20457
20467
  };
20458
20468
 
20459
- function _templateObject4$4() {
20469
+ function _templateObject4$3() {
20460
20470
  var data = _taggedTemplateLiteral(["\n ", "\n "]);
20461
20471
 
20462
- _templateObject4$4 = function _templateObject4() {
20472
+ _templateObject4$3 = function _templateObject4() {
20463
20473
  return data;
20464
20474
  };
20465
20475
 
@@ -20540,7 +20550,7 @@ var FormattedInputField = styled__default(function (_ref7) {
20540
20550
  return themeValues.color && themeValues.color;
20541
20551
  }, MATISSE_BLUE, function (_ref12) {
20542
20552
  var extraStyles = _ref12.extraStyles;
20543
- return styled.css(_templateObject4$4(), extraStyles);
20553
+ return styled.css(_templateObject4$3(), extraStyles);
20544
20554
  });
20545
20555
 
20546
20556
  var FormInput = function FormInput(_ref13) {
@@ -21295,10 +21305,10 @@ function _templateObject5$2() {
21295
21305
  return data;
21296
21306
  }
21297
21307
 
21298
- function _templateObject4$5() {
21308
+ function _templateObject4$4() {
21299
21309
  var data = _taggedTemplateLiteral(["", " is not a valid length"]);
21300
21310
 
21301
- _templateObject4$5 = function _templateObject4() {
21311
+ _templateObject4$4 = function _templateObject4() {
21302
21312
  return data;
21303
21313
  };
21304
21314
 
@@ -21374,7 +21384,7 @@ with interpolation.
21374
21384
  */
21375
21385
 
21376
21386
 
21377
- var DEFAULT_ERROR_MESSAGES = (_DEFAULT_ERROR_MESSAG = {}, _defineProperty(_DEFAULT_ERROR_MESSAG, MIN_LENGTH_ERROR, genErrorMessage(_templateObject$t(), "fieldLabel")), _defineProperty(_DEFAULT_ERROR_MESSAG, MAX_LENGTH_ERROR, genErrorMessage(_templateObject2$h(), "fieldLabel")), _defineProperty(_DEFAULT_ERROR_MESSAG, EXACT_LENGTH_ERROR, genErrorMessage(_templateObject3$9(), "fieldLabel")), _defineProperty(_DEFAULT_ERROR_MESSAG, MULTIPLE_LENGTHS_ERROR, genErrorMessage(_templateObject4$5(), "fieldLabel")), _defineProperty(_DEFAULT_ERROR_MESSAG, EMAIL_ERROR, genErrorMessage(_templateObject5$2(), "fieldLabel")), _defineProperty(_DEFAULT_ERROR_MESSAG, HAS_NUMBER_ERROR, genErrorMessage(_templateObject6$2(), "fieldLabel")), _defineProperty(_DEFAULT_ERROR_MESSAG, HAS_UPPERCASE_LETTER_ERROR, genErrorMessage(_templateObject7$1(), "fieldLabel")), _defineProperty(_DEFAULT_ERROR_MESSAG, HAS_LOWERCASE_LETTER_ERROR, genErrorMessage(_templateObject8$1(), "fieldLabel")), _defineProperty(_DEFAULT_ERROR_MESSAG, HAS_SPECIAL_CHARACTER_ERROR, genErrorMessage(_templateObject9$1(), "fieldLabel")), _defineProperty(_DEFAULT_ERROR_MESSAG, ONLY_NUMBERS_ERROR, genErrorMessage(_templateObject10$1(), "fieldLabel")), _defineProperty(_DEFAULT_ERROR_MESSAG, ONLY_LETTERS_ERROR, genErrorMessage(_templateObject11$1(), "fieldLabel")), _defineProperty(_DEFAULT_ERROR_MESSAG, REQUIRED_FIELD_ERROR, genErrorMessage(_templateObject12(), "fieldLabel")), _defineProperty(_DEFAULT_ERROR_MESSAG, NUM_GREATER_THAN_ERROR, genErrorMessage(_templateObject13(), "fieldLabel")), _defineProperty(_DEFAULT_ERROR_MESSAG, NUM_LESS_THAN_ERROR, genErrorMessage(_templateObject14(), "fieldLabel")), _defineProperty(_DEFAULT_ERROR_MESSAG, MATCHES_FIELD_ERROR, genErrorMessage(_templateObject15(), "fieldLabel", "matchField")), _defineProperty(_DEFAULT_ERROR_MESSAG, VALID_SELECT_OPTION_ERROR, genErrorMessage(_templateObject16(), "fieldLabel")), _DEFAULT_ERROR_MESSAG); // Constants to represent an input's state
21387
+ var DEFAULT_ERROR_MESSAGES = (_DEFAULT_ERROR_MESSAG = {}, _defineProperty(_DEFAULT_ERROR_MESSAG, MIN_LENGTH_ERROR, genErrorMessage(_templateObject$t(), "fieldLabel")), _defineProperty(_DEFAULT_ERROR_MESSAG, MAX_LENGTH_ERROR, genErrorMessage(_templateObject2$h(), "fieldLabel")), _defineProperty(_DEFAULT_ERROR_MESSAG, EXACT_LENGTH_ERROR, genErrorMessage(_templateObject3$9(), "fieldLabel")), _defineProperty(_DEFAULT_ERROR_MESSAG, MULTIPLE_LENGTHS_ERROR, genErrorMessage(_templateObject4$4(), "fieldLabel")), _defineProperty(_DEFAULT_ERROR_MESSAG, EMAIL_ERROR, genErrorMessage(_templateObject5$2(), "fieldLabel")), _defineProperty(_DEFAULT_ERROR_MESSAG, HAS_NUMBER_ERROR, genErrorMessage(_templateObject6$2(), "fieldLabel")), _defineProperty(_DEFAULT_ERROR_MESSAG, HAS_UPPERCASE_LETTER_ERROR, genErrorMessage(_templateObject7$1(), "fieldLabel")), _defineProperty(_DEFAULT_ERROR_MESSAG, HAS_LOWERCASE_LETTER_ERROR, genErrorMessage(_templateObject8$1(), "fieldLabel")), _defineProperty(_DEFAULT_ERROR_MESSAG, HAS_SPECIAL_CHARACTER_ERROR, genErrorMessage(_templateObject9$1(), "fieldLabel")), _defineProperty(_DEFAULT_ERROR_MESSAG, ONLY_NUMBERS_ERROR, genErrorMessage(_templateObject10$1(), "fieldLabel")), _defineProperty(_DEFAULT_ERROR_MESSAG, ONLY_LETTERS_ERROR, genErrorMessage(_templateObject11$1(), "fieldLabel")), _defineProperty(_DEFAULT_ERROR_MESSAG, REQUIRED_FIELD_ERROR, genErrorMessage(_templateObject12(), "fieldLabel")), _defineProperty(_DEFAULT_ERROR_MESSAG, NUM_GREATER_THAN_ERROR, genErrorMessage(_templateObject13(), "fieldLabel")), _defineProperty(_DEFAULT_ERROR_MESSAG, NUM_LESS_THAN_ERROR, genErrorMessage(_templateObject14(), "fieldLabel")), _defineProperty(_DEFAULT_ERROR_MESSAG, MATCHES_FIELD_ERROR, genErrorMessage(_templateObject15(), "fieldLabel", "matchField")), _defineProperty(_DEFAULT_ERROR_MESSAG, VALID_SELECT_OPTION_ERROR, genErrorMessage(_templateObject16(), "fieldLabel")), _DEFAULT_ERROR_MESSAG); // Constants to represent an input's state
21378
21388
  // Neutral - has not been validated
21379
21389
  // Invalid - has been validated and has an error
21380
21390
  // Valid - has been validated and has no error
@@ -32337,10 +32347,10 @@ var fallbackValues$r = {
32337
32347
  leftLabelStyles: leftLabelStyles
32338
32348
  };
32339
32349
 
32340
- function _templateObject4$6() {
32350
+ function _templateObject4$5() {
32341
32351
  var data = _taggedTemplateLiteral(["\n position: absolute;\n width: 14px;\n height: 14px;\n top: 3px;\n left: 3px;\n right: 3px;\n bottom: 3px;\n border-radius: 50%;\n box-sizing: border-box;\n"]);
32342
32352
 
32343
- _templateObject4$6 = function _templateObject4() {
32353
+ _templateObject4$5 = function _templateObject4() {
32344
32354
  return data;
32345
32355
  };
32346
32356
 
@@ -32394,7 +32404,7 @@ var VisibleSwitchComponent = styled__default.label(_templateObject2$i(), functio
32394
32404
  return isMobile ? "transform: scale(0.75)" : "";
32395
32405
  });
32396
32406
  var ToggleSwitchMiddleRingComponent = styled__default.div(_templateObject3$a());
32397
- var ToggleSwitchInnerRingComponent = styled__default.div(_templateObject4$6());
32407
+ var ToggleSwitchInnerRingComponent = styled__default.div(_templateObject4$5());
32398
32408
 
32399
32409
  var ToggleSwitch = function ToggleSwitch(_ref6) {
32400
32410
  var _ref6$isOn = _ref6.isOn,
@@ -34193,17 +34203,6 @@ var formats = /*#__PURE__*/Object.freeze({
34193
34203
  moneyFormat: moneyFormat
34194
34204
  });
34195
34205
 
34196
- function _templateObject$x() {
34197
- var data = _taggedTemplateLiteral(["\n outline: none;\n"]);
34198
-
34199
- _templateObject$x = function _templateObject() {
34200
- return data;
34201
- };
34202
-
34203
- return data;
34204
- }
34205
- var CheckboxWrapper = styled__default.div(_templateObject$x());
34206
-
34207
34206
  var AddressForm = function AddressForm(_ref) {
34208
34207
  var _zipErrorMessages;
34209
34208
 
@@ -34219,17 +34218,6 @@ var AddressForm = function AddressForm(_ref) {
34219
34218
  saveToWallet = _ref.saveToWallet,
34220
34219
  walletCheckboxMarked = _ref.walletCheckboxMarked;
34221
34220
 
34222
- var _useState = React.useState(false),
34223
- _useState2 = _slicedToArray(_useState, 2),
34224
- checkboxFocused = _useState2[0],
34225
- focusCheckbox = _useState2[1];
34226
-
34227
- var handleClick = function handleClick(e, func) {
34228
- if ((e === null || e === void 0 ? void 0 : e.keyCode) === 13) {
34229
- func();
34230
- }
34231
- };
34232
-
34233
34221
  if (clearOnDismount) {
34234
34222
  React.useEffect(function () {
34235
34223
  return function () {
@@ -34317,24 +34305,12 @@ var AddressForm = function AddressForm(_ref) {
34317
34305
  onKeyDown: function onKeyDown(e) {
34318
34306
  return e.key === "Enter" && handleSubmit(e);
34319
34307
  }
34320
- }), showWalletCheckbox && /*#__PURE__*/React__default.createElement(CheckboxWrapper, {
34321
- tabIndex: "0",
34322
- onFocus: function onFocus() {
34323
- return focusCheckbox(true);
34324
- },
34325
- onBlur: function onBlur() {
34326
- return focusCheckbox(false);
34327
- },
34328
- onKeyDown: function onKeyDown(e) {
34329
- return handleClick(e, saveToWallet);
34330
- }
34331
- }, /*#__PURE__*/React__default.createElement(Checkbox$1, {
34308
+ }), showWalletCheckbox && /*#__PURE__*/React__default.createElement(Checkbox$1, {
34332
34309
  name: "address checkbox",
34333
34310
  title: "Save address to wallet",
34334
34311
  checked: walletCheckboxMarked,
34335
- onChange: saveToWallet,
34336
- focused: checkboxFocused
34337
- }))));
34312
+ onChange: saveToWallet
34313
+ })));
34338
34314
  };
34339
34315
 
34340
34316
  var formConfig = {
@@ -34637,16 +34613,16 @@ function _templateObject2$j() {
34637
34613
  return data;
34638
34614
  }
34639
34615
 
34640
- function _templateObject$y() {
34616
+ function _templateObject$x() {
34641
34617
  var data = _taggedTemplateLiteral(["\n box-sizing: border-box;\n background: ", ";\n height: ", ";\n display: flex;\n justify-content: space-between;\n align-items: center;\n padding: 1.5rem;\n :not(:last-child),\n :not(:first-child) {\n box-shadow: inset 0px -1px 0px 0px rgb(202, 206, 216);\n }\n :first-child {\n border-top-left-radius: 3px;\n border-top-right-radius: 3px;\n }\n :last-child {\n border-bottom-left-radius: 3px;\n border-bottom-right-radius: 3px;\n box-shadow: none;\n }\n"]);
34642
34618
 
34643
- _templateObject$y = function _templateObject() {
34619
+ _templateObject$x = function _templateObject() {
34644
34620
  return data;
34645
34621
  };
34646
34622
 
34647
34623
  return data;
34648
34624
  }
34649
- var EditableListItem = styled__default.div(_templateObject$y(), WHITE, function (_ref) {
34625
+ var EditableListItem = styled__default.div(_templateObject$x(), WHITE, function (_ref) {
34650
34626
  var listItemSize = _ref.listItemSize;
34651
34627
  return listItemSize === "big" ? "120px" : "72px";
34652
34628
  });
@@ -34801,10 +34777,10 @@ function _templateObject5$3() {
34801
34777
  return data;
34802
34778
  }
34803
34779
 
34804
- function _templateObject4$7() {
34780
+ function _templateObject4$6() {
34805
34781
  var data = _taggedTemplateLiteral(["\n color: ", ";\n align-items: center;\n font-size: 1rem;\n padding-right: 1rem;\n cursor: pointer;\n display: ", ";\n"]);
34806
34782
 
34807
- _templateObject4$7 = function _templateObject4() {
34783
+ _templateObject4$6 = function _templateObject4() {
34808
34784
  return data;
34809
34785
  };
34810
34786
 
@@ -34831,16 +34807,16 @@ function _templateObject2$k() {
34831
34807
  return data;
34832
34808
  }
34833
34809
 
34834
- function _templateObject$z() {
34810
+ function _templateObject$y() {
34835
34811
  var data = _taggedTemplateLiteral(["\n display: ", ";\n flex-direction: column;\n flex: 1;\n"]);
34836
34812
 
34837
- _templateObject$z = function _templateObject() {
34813
+ _templateObject$y = function _templateObject() {
34838
34814
  return data;
34839
34815
  };
34840
34816
 
34841
34817
  return data;
34842
34818
  }
34843
- var EditableTableContainer = styled__default.div(_templateObject$z(), function (_ref) {
34819
+ var EditableTableContainer = styled__default.div(_templateObject$y(), function (_ref) {
34844
34820
  var hide = _ref.hide;
34845
34821
  return hide ? "none" : "flex";
34846
34822
  });
@@ -34858,7 +34834,7 @@ var EditableTableListItem = styled__default.div(_templateObject2$k(), function (
34858
34834
  return isMobile ? "padding: 1rem 0.5rem" : "padding: 0 0.5rem";
34859
34835
  });
34860
34836
  var EditableListItemControls$1 = styled__default.div(_templateObject3$b());
34861
- var EditableListAction = styled__default.div(_templateObject4$7(), MATISSE_BLUE, function (_ref6) {
34837
+ var EditableListAction = styled__default.div(_templateObject4$6(), MATISSE_BLUE, function (_ref6) {
34862
34838
  var hide = _ref6.hide;
34863
34839
  return hide ? "none" : "flex";
34864
34840
  });
@@ -34952,17 +34928,6 @@ var TableListItem = function TableListItem(_ref) {
34952
34928
  }, "Edit")) : /*#__PURE__*/React__default.createElement(React.Fragment, null))));
34953
34929
  };
34954
34930
 
34955
- function _templateObject$A() {
34956
- var data = _taggedTemplateLiteral(["\n outline: none;\n"]);
34957
-
34958
- _templateObject$A = function _templateObject() {
34959
- return data;
34960
- };
34961
-
34962
- return data;
34963
- }
34964
- var CheckboxWrapper$1 = styled__default.div(_templateObject$A());
34965
-
34966
34931
  var EmailForm = function EmailForm(_ref) {
34967
34932
  var _emailFieldErrorMessa;
34968
34933
 
@@ -34979,17 +34944,6 @@ var EmailForm = function EmailForm(_ref) {
34979
34944
  saveToWallet = _ref.saveToWallet,
34980
34945
  walletCheckboxMarked = _ref.walletCheckboxMarked;
34981
34946
 
34982
- var _useState = React.useState(false),
34983
- _useState2 = _slicedToArray(_useState, 2),
34984
- checkboxFocused = _useState2[0],
34985
- focusCheckbox = _useState2[1];
34986
-
34987
- var handleClick = function handleClick(e, func) {
34988
- if ((e === null || e === void 0 ? void 0 : e.keyCode) === 13) {
34989
- func();
34990
- }
34991
- };
34992
-
34993
34947
  if (clearOnDismount) {
34994
34948
  React.useEffect(function () {
34995
34949
  return function () {
@@ -35015,24 +34969,12 @@ var EmailForm = function EmailForm(_ref) {
35015
34969
  onKeyDown: function onKeyDown(e) {
35016
34970
  return e.key === "Enter" && handleSubmit(e);
35017
34971
  }
35018
- }), showWalletCheckbox && /*#__PURE__*/React__default.createElement(CheckboxWrapper$1, {
35019
- tabIndex: "0",
35020
- onFocus: function onFocus() {
35021
- return focusCheckbox(true);
35022
- },
35023
- onBlur: function onBlur() {
35024
- return focusCheckbox(false);
35025
- },
35026
- onKeyDown: function onKeyDown(e) {
35027
- return handleClick(e, saveToWallet);
35028
- }
35029
- }, /*#__PURE__*/React__default.createElement(Checkbox$1, {
34972
+ }), showWalletCheckbox && /*#__PURE__*/React__default.createElement(Checkbox$1, {
35030
34973
  name: "email checkbox",
35031
34974
  title: "Save email address to wallet",
35032
34975
  checked: walletCheckboxMarked,
35033
- onChange: saveToWallet,
35034
- focused: checkboxFocused
35035
- }))));
34976
+ onChange: saveToWallet
34977
+ })));
35036
34978
  };
35037
34979
 
35038
34980
  var formConfig$3 = {
@@ -36376,8 +36318,7 @@ var getApplicationNode = function getApplicationNode() {
36376
36318
  };
36377
36319
 
36378
36320
  var Modal$1 = function Modal(_ref) {
36379
- var ModalLink = _ref.ModalLink,
36380
- hideModal = _ref.hideModal,
36321
+ var hideModal = _ref.hideModal,
36381
36322
  continueAction = _ref.continueAction,
36382
36323
  cancelAction = _ref.cancelAction,
36383
36324
  modalOpen = _ref.modalOpen,
@@ -36399,12 +36340,13 @@ var Modal$1 = function Modal(_ref) {
36399
36340
  onlyCloseButton = _ref$onlyCloseButton === void 0 ? false : _ref$onlyCloseButton,
36400
36341
  maxHeight = _ref.maxHeight,
36401
36342
  _ref$underlayClickExi = _ref.underlayClickExits,
36402
- underlayClickExits = _ref$underlayClickExi === void 0 ? true : _ref$underlayClickExi;
36343
+ underlayClickExits = _ref$underlayClickExi === void 0 ? true : _ref$underlayClickExi,
36344
+ children = _ref.children;
36403
36345
 
36404
36346
  var _useContext = React.useContext(styled.ThemeContext),
36405
36347
  isMobile = _useContext.isMobile;
36406
36348
 
36407
- return /*#__PURE__*/React__default.createElement(React.Fragment, null, /*#__PURE__*/React__default.createElement(ModalLink, null), modalOpen && /*#__PURE__*/React__default.createElement(reactAriaModal, {
36349
+ return /*#__PURE__*/React__default.createElement(React.Fragment, null, modalOpen && /*#__PURE__*/React__default.createElement(reactAriaModal, {
36408
36350
  onExit: hideModal,
36409
36351
  getApplicationNode: getApplicationNode,
36410
36352
  titleText: modalHeaderText,
@@ -36476,7 +36418,7 @@ var Modal$1 = function Modal(_ref) {
36476
36418
  variant: "primary",
36477
36419
  text: "Close",
36478
36420
  dataQa: "Close"
36479
- })))))))));
36421
+ })))))))), children);
36480
36422
  };
36481
36423
 
36482
36424
  var fontSize$8 = {
@@ -36613,10 +36555,10 @@ var NavMenuDesktop = function NavMenuDesktop(_ref) {
36613
36555
 
36614
36556
  var NavMenuDesktop$1 = themeComponent(NavMenuDesktop, "NavMenu", fallbackValues$v, "profile");
36615
36557
 
36616
- function _templateObject$B() {
36558
+ function _templateObject$z() {
36617
36559
  var data = _taggedTemplateLiteral(["\n position: fixed;\n top: 72px;\n"]);
36618
36560
 
36619
- _templateObject$B = function _templateObject() {
36561
+ _templateObject$z = function _templateObject() {
36620
36562
  return data;
36621
36563
  };
36622
36564
 
@@ -36652,7 +36594,7 @@ var menu = posed.div({
36652
36594
  }
36653
36595
  }
36654
36596
  });
36655
- var ImposterMenu = styled__default(menu)(_templateObject$B());
36597
+ var ImposterMenu = styled__default(menu)(_templateObject$z());
36656
36598
 
36657
36599
  var NavMenuMobile = function NavMenuMobile(_ref) {
36658
36600
  var id = _ref.id,
@@ -38175,10 +38117,16 @@ var TitleModule = function TitleModule(_ref) {
38175
38117
  var color$a = "#15749D";
38176
38118
  var hoverColor$4 = "#116285";
38177
38119
  var activeColor$5 = "#0E506D";
38120
+ var linkColor$3 = "#357fb8";
38121
+ var fontWeight$6 = FONT_WEIGHT_REGULAR;
38122
+ var modalLinkHoverFocus = "outline: none;\n cursor: pointer;\n text-decoration: underline;\n text-decoration-color: #357fb8;";
38178
38123
  var fallbackValues$w = {
38179
38124
  color: color$a,
38180
38125
  hoverColor: hoverColor$4,
38181
- activeColor: activeColor$5
38126
+ activeColor: activeColor$5,
38127
+ linkColor: linkColor$3,
38128
+ fontWeight: fontWeight$6,
38129
+ modalLinkHoverFocus: modalLinkHoverFocus
38182
38130
  };
38183
38131
 
38184
38132
  var AutopayModal = function AutopayModal(_ref) {
@@ -38208,34 +38156,6 @@ var AutopayModal = function AutopayModal(_ref) {
38208
38156
  var activeStyles = "\n &:active {\n .autopayIcon { fill: ".concat(themeValues.activeColor, "; text-decoration: underline; }\n }");
38209
38157
  var defaultStyles = "\n .autopayIcon { fill: ".concat(themeValues.color, "; text-decoration: underline; }\n ");
38210
38158
  return /*#__PURE__*/React__default.createElement(Modal$1, _extends({
38211
- ModalLink: function ModalLink() {
38212
- return buttonLinkType ? /*#__PURE__*/React__default.createElement(ButtonWithAction, {
38213
- text: autoPayActive ? "Manage ".concat(planType) : "Set Up ".concat(planType),
38214
- variant: "tertiary",
38215
- action: function action() {
38216
- toggleModal(true);
38217
- },
38218
- dataQa: "Manage Autopay",
38219
- extraStyles: isMobile && "flex-grow: 1; width: 100%;"
38220
- }) : /*#__PURE__*/React__default.createElement(Box, {
38221
- padding: "0",
38222
- onClick: function onClick() {
38223
- toggleModal(true);
38224
- },
38225
- hoverStyles: hoverStyles,
38226
- activeStyles: activeStyles,
38227
- extraStyles: defaultStyles
38228
- }, /*#__PURE__*/React__default.createElement(Cluster, {
38229
- justify: isMobile ? "flex-start" : "flex-end",
38230
- align: "center"
38231
- }, /*#__PURE__*/React__default.createElement(AutopayOnIcon$1, null), /*#__PURE__*/React__default.createElement(ButtonWithAction, {
38232
- text: "".concat(planType, " On"),
38233
- variant: "smallGhost",
38234
- dataQa: "Autopay On",
38235
- textExtraStyles: "font-size: 0.875rem; ",
38236
- extraStyles: "min-width: auto; padding: 0 0 0 6px;"
38237
- })));
38238
- },
38239
38159
  showModal: function showModal() {
38240
38160
  return toggleModal(true);
38241
38161
  },
@@ -38243,7 +38163,43 @@ var AutopayModal = function AutopayModal(_ref) {
38243
38163
  return toggleModal(false);
38244
38164
  },
38245
38165
  modalOpen: modalOpen
38246
- }, modalExtraProps));
38166
+ }, modalExtraProps), buttonLinkType ? /*#__PURE__*/React__default.createElement(ButtonWithAction, {
38167
+ text: autoPayActive ? "Manage ".concat(planType) : "Set Up ".concat(planType),
38168
+ variant: "tertiary",
38169
+ action: function action() {
38170
+ toggleModal(true);
38171
+ },
38172
+ dataQa: "Manage Autopay",
38173
+ extraStyles: isMobile && "flex-grow: 1; width: 100%;"
38174
+ }) : /*#__PURE__*/React__default.createElement(Box, {
38175
+ padding: "0",
38176
+ onClick: function onClick() {
38177
+ toggleModal(true);
38178
+ },
38179
+ hoverStyles: hoverStyles,
38180
+ activeStyles: activeStyles,
38181
+ extraStyles: defaultStyles
38182
+ }, /*#__PURE__*/React__default.createElement(Cluster, {
38183
+ justify: isMobile ? "flex-start" : "flex-end",
38184
+ align: "center"
38185
+ }, /*#__PURE__*/React__default.createElement(AutopayOnIcon$1, null), /*#__PURE__*/React__default.createElement(Text$1, {
38186
+ variant: "pS",
38187
+ onClick: function onClick() {
38188
+ return toggleModal(true);
38189
+ },
38190
+ onKeyPress: function onKeyPress(e) {
38191
+ console.log({
38192
+ e: e
38193
+ });
38194
+ e.key === "Enter" && toggleModal(true);
38195
+ },
38196
+ tabIndex: "0",
38197
+ dataQa: "".concat(planType, " On"),
38198
+ color: themeValues.linkColor,
38199
+ weight: themeValues.fontWeight,
38200
+ hoverStyles: themeValues.modalLinkHoverFocus,
38201
+ extraStyles: "padding: 0 0 0 6px;"
38202
+ }, "".concat(planType, " On")))));
38247
38203
  };
38248
38204
 
38249
38205
  var AutopayModalModule = themeComponent(AutopayModal, "AutopayModal", fallbackValues$w);
@@ -38981,32 +38937,27 @@ var PaymentDetails = function PaymentDetails(_ref4) {
38981
38937
 
38982
38938
  var PaymentDetails$1 = themeComponent(PaymentDetails, "PaymentDetails", fallbackValues$x, "default");
38983
38939
 
38984
- var linkColor$3 = {
38985
- "default": "#357fb8",
38986
- footer: "#ffffff"
38940
+ var linkColor$4 = {
38941
+ "default": "#357fb8"
38987
38942
  };
38988
38943
  var fontSize$9 = {
38989
- "default": "1rem",
38990
- footer: "0.875rem"
38944
+ "default": "1rem"
38991
38945
  };
38992
38946
  var lineHeight$5 = {
38993
- "default": "1.5rem",
38994
- footer: "1.25rem"
38947
+ "default": "1.5rem"
38995
38948
  };
38996
- var fontWeight$6 = {
38997
- "default": FONT_WEIGHT_REGULAR,
38998
- footer: FONT_WEIGHT_SEMIBOLD
38949
+ var fontWeight$7 = {
38950
+ "default": FONT_WEIGHT_REGULAR
38999
38951
  };
39000
- var modalLinkHoverFocus = {
39001
- "default": "",
39002
- footer: "outline: none; text-decoration: underline;"
38952
+ var modalLinkHoverFocus$1 = {
38953
+ "default": "outline: none; text-decoration: underline;"
39003
38954
  };
39004
38955
  var fallbackValues$y = {
39005
- linkColor: linkColor$3,
38956
+ linkColor: linkColor$4,
39006
38957
  fontSize: fontSize$9,
39007
38958
  lineHeight: lineHeight$5,
39008
- fontWeight: fontWeight$6,
39009
- modalLinkHoverFocus: modalLinkHoverFocus
38959
+ fontWeight: fontWeight$7,
38960
+ modalLinkHoverFocus: modalLinkHoverFocus$1
39010
38961
  };
39011
38962
 
39012
38963
  var AccountAndRoutingModal = function AccountAndRoutingModal(_ref) {
@@ -39018,25 +38969,8 @@ var AccountAndRoutingModal = function AccountAndRoutingModal(_ref) {
39018
38969
  acceptText = _ref.acceptText,
39019
38970
  content = _ref.content,
39020
38971
  imageType = _ref.imageType,
39021
- variant = _ref.variant,
39022
38972
  themeValues = _ref.themeValues;
39023
38973
  return /*#__PURE__*/React__default.createElement(Modal$1, {
39024
- ModalLink: function ModalLink() {
39025
- return /*#__PURE__*/React__default.createElement(Text$1, {
39026
- variant: variant === "default" ? "pS" : "pXS",
39027
- onClick: function onClick() {
39028
- return toggleOpen(true);
39029
- },
39030
- color: themeValues.linkColor,
39031
- weight: themeValues.fontWeight,
39032
- hoverStyles: themeValues.modalLinkHoverFocus,
39033
- extraStyles: "cursor: pointer;",
39034
- tabIndex: "0",
39035
- onKeyPress: function onKeyPress(e) {
39036
- return e.key === "Enter" && toggleOpen(true);
39037
- }
39038
- }, link);
39039
- },
39040
38974
  modalOpen: isOpen,
39041
38975
  hideModal: function hideModal() {
39042
38976
  return toggleOpen(false);
@@ -39061,33 +38995,24 @@ var AccountAndRoutingModal = function AccountAndRoutingModal(_ref) {
39061
38995
  toggleAccepted(true);
39062
38996
  toggleOpen(false);
39063
38997
  }
39064
- });
38998
+ }, /*#__PURE__*/React__default.createElement(Text$1, {
38999
+ variant: "pS",
39000
+ onClick: function onClick() {
39001
+ return toggleOpen(true);
39002
+ },
39003
+ onKeyPress: function onKeyPress(e) {
39004
+ return e.key === "Enter" && toggleOpen(true);
39005
+ },
39006
+ tabIndex: "0",
39007
+ color: themeValues.linkColor,
39008
+ weight: themeValues.fontWeight,
39009
+ hoverStyles: themeValues.modalLinkHoverFocus,
39010
+ extraStyles: "cursor: pointer;"
39011
+ }, link));
39065
39012
  };
39066
39013
 
39067
39014
  var AccountAndRoutingModal$1 = themeComponent(AccountAndRoutingModal, "AccountAndRoutingModal", fallbackValues$y, "default");
39068
39015
 
39069
- function _templateObject2$l() {
39070
- var data = _taggedTemplateLiteral(["\n outline: none;\n"]);
39071
-
39072
- _templateObject2$l = function _templateObject2() {
39073
- return data;
39074
- };
39075
-
39076
- return data;
39077
- }
39078
-
39079
- function _templateObject$C() {
39080
- var data = _taggedTemplateLiteral([""]);
39081
-
39082
- _templateObject$C = function _templateObject() {
39083
- return data;
39084
- };
39085
-
39086
- return data;
39087
- }
39088
- var ModalWrapper = styled__default.div(_templateObject$C());
39089
- var CheckboxWrapper$2 = styled__default.div(_templateObject2$l());
39090
-
39091
39016
  var PaymentFormACH = function PaymentFormACH(_ref) {
39092
39017
  var _routingNumberErrors, _accountNumberErrors;
39093
39018
 
@@ -39108,17 +39033,6 @@ var PaymentFormACH = function PaymentFormACH(_ref) {
39108
39033
  saveToWallet = _ref.saveToWallet,
39109
39034
  walletCheckboxMarked = _ref.walletCheckboxMarked;
39110
39035
 
39111
- var _useState = React.useState(false),
39112
- _useState2 = _slicedToArray(_useState, 2),
39113
- checkboxFocused = _useState2[0],
39114
- focusCheckbox = _useState2[1];
39115
-
39116
- var handleClick = function handleClick(e, func) {
39117
- if ((e === null || e === void 0 ? void 0 : e.keyCode) === 13) {
39118
- func();
39119
- }
39120
- };
39121
-
39122
39036
  if (clearOnDismount) {
39123
39037
  React.useEffect(function () {
39124
39038
  return function () {
@@ -39127,15 +39041,15 @@ var PaymentFormACH = function PaymentFormACH(_ref) {
39127
39041
  }, []);
39128
39042
  }
39129
39043
 
39044
+ var _useState = React.useState(false),
39045
+ _useState2 = _slicedToArray(_useState, 2),
39046
+ showRouting = _useState2[0],
39047
+ toggleShowRouting = _useState2[1];
39048
+
39130
39049
  var _useState3 = React.useState(false),
39131
39050
  _useState4 = _slicedToArray(_useState3, 2),
39132
- showRouting = _useState4[0],
39133
- toggleShowRouting = _useState4[1];
39134
-
39135
- var _useState5 = React.useState(false),
39136
- _useState6 = _slicedToArray(_useState5, 2),
39137
- showAccount = _useState6[0],
39138
- toggleShowAccount = _useState6[1];
39051
+ showAccount = _useState4[0],
39052
+ toggleShowAccount = _useState4[1];
39139
39053
 
39140
39054
  var nameErrors = _defineProperty({}, required.error, "Name is required");
39141
39055
 
@@ -39169,19 +39083,14 @@ var PaymentFormACH = function PaymentFormACH(_ref) {
39169
39083
  fieldActions: actions.fields.routingNumber,
39170
39084
  showErrors: showErrors,
39171
39085
  helperModal: function helperModal() {
39172
- return /*#__PURE__*/React__default.createElement(ModalWrapper, {
39173
- tabIndex: "0",
39174
- onKeyDown: function onKeyDown(e) {
39175
- return e.key === "Enter" && toggleShowAccount(!showRouting);
39176
- }
39177
- }, /*#__PURE__*/React__default.createElement(AccountAndRoutingModal$1, {
39086
+ return /*#__PURE__*/React__default.createElement(AccountAndRoutingModal$1, {
39178
39087
  link: "What is this?",
39179
39088
  title: "Where is my routing number?",
39180
39089
  content: "Your routing number is the 9-digit number in the bottom left corner of your check.",
39181
39090
  imageType: "Routing",
39182
39091
  isOpen: showRouting,
39183
39092
  toggleOpen: toggleShowRouting
39184
- }));
39093
+ });
39185
39094
  },
39186
39095
  onKeyDown: function onKeyDown(e) {
39187
39096
  return e.key === "Enter" && handleSubmit(e);
@@ -39202,19 +39111,14 @@ var PaymentFormACH = function PaymentFormACH(_ref) {
39202
39111
  fieldActions: actions.fields.accountNumber,
39203
39112
  showErrors: showErrors,
39204
39113
  helperModal: function helperModal() {
39205
- return /*#__PURE__*/React__default.createElement(ModalWrapper, {
39206
- tabIndex: "0",
39207
- onKeyDown: function onKeyDown(e) {
39208
- return e.key === "Enter" && toggleShowAccount(!showAccount);
39209
- }
39210
- }, /*#__PURE__*/React__default.createElement(AccountAndRoutingModal$1, {
39114
+ return /*#__PURE__*/React__default.createElement(AccountAndRoutingModal$1, {
39211
39115
  link: "What is this?",
39212
39116
  title: "Where is my account number?",
39213
39117
  content: "Your account number is usually the 10-digit number in the bottom of your check to the right of the routing number.",
39214
39118
  imageType: "Account",
39215
39119
  isOpen: showAccount,
39216
39120
  toggleOpen: toggleShowAccount
39217
- }));
39121
+ });
39218
39122
  },
39219
39123
  onKeyDown: function onKeyDown(e) {
39220
39124
  return e.key === "Enter" && handleSubmit(e);
@@ -39250,24 +39154,12 @@ var PaymentFormACH = function PaymentFormACH(_ref) {
39250
39154
  onChange: toggleCheckbox,
39251
39155
  checked: defaultMethod.value,
39252
39156
  hidden: hideDefaultPayment
39253
- }), showWalletCheckbox && /*#__PURE__*/React__default.createElement(CheckboxWrapper$2, {
39254
- tabIndex: "0",
39255
- onFocus: function onFocus() {
39256
- return focusCheckbox(true);
39257
- },
39258
- onBlur: function onBlur() {
39259
- return focusCheckbox(false);
39260
- },
39261
- onKeyDown: function onKeyDown(e) {
39262
- return handleClick(e, saveToWallet);
39263
- }
39264
- }, /*#__PURE__*/React__default.createElement(Checkbox$1, {
39157
+ }), showWalletCheckbox && /*#__PURE__*/React__default.createElement(Checkbox$1, {
39265
39158
  name: "bank checkbox",
39266
39159
  title: "Save bank account to wallet",
39267
39160
  checked: walletCheckboxMarked,
39268
- onChange: saveToWallet,
39269
- focused: checkboxFocused
39270
- }))));
39161
+ onChange: saveToWallet
39162
+ })));
39271
39163
  };
39272
39164
 
39273
39165
  var formConfig$6 = {
@@ -39307,17 +39199,6 @@ PaymentFormACH.mapDispatchToProps = mapDispatchToProps$6;
39307
39199
 
39308
39200
  var _creditCardNumberErro, _expirationDateErrors, _cvvErrors, _zipCodeErrors;
39309
39201
 
39310
- function _templateObject$D() {
39311
- var data = _taggedTemplateLiteral(["\n outline: none;\n"]);
39312
-
39313
- _templateObject$D = function _templateObject() {
39314
- return data;
39315
- };
39316
-
39317
- return data;
39318
- }
39319
- var CheckboxWrapper$3 = styled__default.div(_templateObject$D());
39320
-
39321
39202
  var nameOnCardErrors = _defineProperty({}, required.error, "Name is required");
39322
39203
 
39323
39204
  var creditCardNumberErrors = (_creditCardNumberErro = {}, _defineProperty(_creditCardNumberErro, required.error, "Credit card number is required"), _defineProperty(_creditCardNumberErro, hasLength.error, "Credit card number is invalid"), _creditCardNumberErro);
@@ -39342,18 +39223,6 @@ var PaymentFormCard = function PaymentFormCard(_ref) {
39342
39223
  showWalletCheckbox = _ref.showWalletCheckbox,
39343
39224
  saveToWallet = _ref.saveToWallet,
39344
39225
  walletCheckboxMarked = _ref.walletCheckboxMarked;
39345
-
39346
- var _useState = React.useState(false),
39347
- _useState2 = _slicedToArray(_useState, 2),
39348
- checkboxFocused = _useState2[0],
39349
- focusCheckbox = _useState2[1];
39350
-
39351
- var handleClick = function handleClick(e, func) {
39352
- if ((e === null || e === void 0 ? void 0 : e.keyCode) === 13) {
39353
- func();
39354
- }
39355
- };
39356
-
39357
39226
  React.useEffect(function () {
39358
39227
  if (clearOnDismount) {
39359
39228
  return function () {
@@ -39434,24 +39303,12 @@ var PaymentFormCard = function PaymentFormCard(_ref) {
39434
39303
  onKeyDown: function onKeyDown(e) {
39435
39304
  return e.key === "Enter" && handleSubmit(e);
39436
39305
  }
39437
- })), showWalletCheckbox && /*#__PURE__*/React__default.createElement(CheckboxWrapper$3, {
39438
- tabIndex: "0",
39439
- onFocus: function onFocus() {
39440
- return focusCheckbox(true);
39441
- },
39442
- onBlur: function onBlur() {
39443
- return focusCheckbox(false);
39444
- },
39445
- onKeyDown: function onKeyDown(e) {
39446
- return handleClick(e, saveToWallet);
39447
- }
39448
- }, /*#__PURE__*/React__default.createElement(Checkbox$1, {
39306
+ })), showWalletCheckbox && /*#__PURE__*/React__default.createElement(Checkbox$1, {
39449
39307
  name: "credit card checkbox",
39450
39308
  title: "Save credit card to wallet",
39451
39309
  checked: walletCheckboxMarked,
39452
- onChange: saveToWallet,
39453
- focused: checkboxFocused
39454
- }))));
39310
+ onChange: saveToWallet
39311
+ })));
39455
39312
  };
39456
39313
 
39457
39314
  var formConfig$7 = {
@@ -39489,17 +39346,6 @@ PaymentFormCard.reducer = reducer$7;
39489
39346
  PaymentFormCard.mapStateToProps = mapStateToProps$8;
39490
39347
  PaymentFormCard.mapDispatchToProps = mapDispatchToProps$7;
39491
39348
 
39492
- function _templateObject$E() {
39493
- var data = _taggedTemplateLiteral(["\n outline: none;\n"]);
39494
-
39495
- _templateObject$E = function _templateObject() {
39496
- return data;
39497
- };
39498
-
39499
- return data;
39500
- }
39501
- var CheckboxWrapper$4 = styled__default.div(_templateObject$E());
39502
-
39503
39349
  var PhoneForm = function PhoneForm(_ref) {
39504
39350
  var _phoneErrorMessage;
39505
39351
 
@@ -39515,17 +39361,6 @@ var PhoneForm = function PhoneForm(_ref) {
39515
39361
  saveToWallet = _ref.saveToWallet,
39516
39362
  walletCheckboxMarked = _ref.walletCheckboxMarked;
39517
39363
 
39518
- var _useState = React.useState(false),
39519
- _useState2 = _slicedToArray(_useState, 2),
39520
- checkboxFocused = _useState2[0],
39521
- focusCheckbox = _useState2[1];
39522
-
39523
- var handleClick = function handleClick(e, func) {
39524
- if ((e === null || e === void 0 ? void 0 : e.keyCode) === 13) {
39525
- func();
39526
- }
39527
- };
39528
-
39529
39364
  if (clearOnDismount) {
39530
39365
  React.useEffect(function () {
39531
39366
  return function () {
@@ -39549,24 +39384,12 @@ var PhoneForm = function PhoneForm(_ref) {
39549
39384
  onKeyUp: function onKeyUp(e) {
39550
39385
  return e.key === "Enter" && handleSubmit(e);
39551
39386
  }
39552
- }), showWalletCheckbox && /*#__PURE__*/React__default.createElement(CheckboxWrapper$4, {
39553
- tabIndex: "0",
39554
- onFocus: function onFocus() {
39555
- return focusCheckbox(true);
39556
- },
39557
- onBlur: function onBlur() {
39558
- return focusCheckbox(false);
39559
- },
39560
- onKeyDown: function onKeyDown(e) {
39561
- return handleClick(e, saveToWallet);
39562
- }
39563
- }, /*#__PURE__*/React__default.createElement(Checkbox$1, {
39387
+ }), showWalletCheckbox && /*#__PURE__*/React__default.createElement(Checkbox$1, {
39564
39388
  name: "phone checkbox",
39565
39389
  title: "Save phone number to wallet",
39566
39390
  checked: walletCheckboxMarked,
39567
- onChange: saveToWallet,
39568
- focused: checkboxFocused
39569
- }))));
39391
+ onChange: saveToWallet
39392
+ })));
39570
39393
  };
39571
39394
 
39572
39395
  var formConfig$8 = {
@@ -39598,10 +39421,10 @@ var fallbackValues$z = {
39598
39421
  focusStyles: focusStyles
39599
39422
  };
39600
39423
 
39601
- function _templateObject$F() {
39424
+ function _templateObject$A() {
39602
39425
  var data = _taggedTemplateLiteral(["\n height: ", ";\n width: ", ";\n ", "\n transition: opacity 0.3s ease;\n "]);
39603
39426
 
39604
- _templateObject$F = function _templateObject() {
39427
+ _templateObject$A = function _templateObject() {
39605
39428
  return data;
39606
39429
  };
39607
39430
 
@@ -39671,7 +39494,7 @@ var RadioSection = function RadioSection(_ref) {
39671
39494
  }
39672
39495
  };
39673
39496
  var borderStyles = "\n border-width: 0 0 1px 0;\n border-color: ".concat(themeValues.borderColor, ";\n border-style: solid;\n border-radius: 0px;\n transform-origin: 100% 0;\n\n &:last-child {\n border-width: 0;\n }\n ");
39674
- var RightIcon = styled__default.img(_templateObject$F(), function (_ref2) {
39497
+ var RightIcon = styled__default.img(_templateObject$A(), function (_ref2) {
39675
39498
  var isMobile = _ref2.isMobile;
39676
39499
  return isMobile ? "14px" : "18px";
39677
39500
  }, function (_ref3) {
@@ -40132,7 +39955,7 @@ var backgroundColor$9 = {
40132
39955
  "default": "#ffffff",
40133
39956
  footer: "#ffffff"
40134
39957
  };
40135
- var linkColor$4 = {
39958
+ var linkColor$5 = {
40136
39959
  "default": "#357fb8",
40137
39960
  footer: "#ffffff"
40138
39961
  };
@@ -40148,22 +39971,22 @@ var lineHeight$6 = {
40148
39971
  "default": "1.5rem",
40149
39972
  footer: "1.25rem"
40150
39973
  };
40151
- var fontWeight$7 = {
39974
+ var fontWeight$8 = {
40152
39975
  "default": FONT_WEIGHT_REGULAR,
40153
39976
  footer: FONT_WEIGHT_SEMIBOLD
40154
39977
  };
40155
- var modalLinkHoverFocus$1 = {
40156
- "default": "",
39978
+ var modalLinkHoverFocus$2 = {
39979
+ "default": "outline: none; text-decoration: underline;",
40157
39980
  footer: "outline: none; text-decoration: underline;"
40158
39981
  };
40159
39982
  var fallbackValues$B = {
40160
39983
  backgroundColor: backgroundColor$9,
40161
- linkColor: linkColor$4,
39984
+ linkColor: linkColor$5,
40162
39985
  border: border$2,
40163
39986
  fontSize: fontSize$a,
40164
39987
  lineHeight: lineHeight$6,
40165
- fontWeight: fontWeight$7,
40166
- modalLinkHoverFocus: modalLinkHoverFocus$1
39988
+ fontWeight: fontWeight$8,
39989
+ modalLinkHoverFocus: modalLinkHoverFocus$2
40167
39990
  };
40168
39991
 
40169
39992
  var TermsAndConditionsModal = function TermsAndConditionsModal(_ref) {
@@ -40178,22 +40001,6 @@ var TermsAndConditionsModal = function TermsAndConditionsModal(_ref) {
40178
40001
  variant = _ref.variant,
40179
40002
  themeValues = _ref.themeValues;
40180
40003
  return /*#__PURE__*/React__default.createElement(Modal$1, {
40181
- ModalLink: function ModalLink() {
40182
- return /*#__PURE__*/React__default.createElement(Text$1, {
40183
- variant: variant === "default" ? "pS" : "pXS",
40184
- onClick: function onClick() {
40185
- return toggleOpen(true);
40186
- },
40187
- color: themeValues.linkColor,
40188
- weight: themeValues.fontWeight,
40189
- hoverStyles: themeValues.modalLinkHoverFocus,
40190
- extraStyles: "cursor: pointer;",
40191
- tabIndex: "0",
40192
- onKeyPress: function onKeyPress(e) {
40193
- return e.key === "Enter" && toggleOpen(true);
40194
- }
40195
- }, link);
40196
- },
40197
40004
  modalOpen: isOpen,
40198
40005
  hideModal: function hideModal() {
40199
40006
  return toggleOpen(false);
@@ -40217,33 +40024,24 @@ var TermsAndConditionsModal = function TermsAndConditionsModal(_ref) {
40217
40024
  toggleAccepted(true);
40218
40025
  toggleOpen(false);
40219
40026
  }
40220
- });
40027
+ }, /*#__PURE__*/React__default.createElement(Text$1, {
40028
+ variant: variant === "default" ? "pS" : "pXS",
40029
+ onClick: function onClick() {
40030
+ return toggleOpen(true);
40031
+ },
40032
+ onKeyPress: function onKeyPress(e) {
40033
+ return e.key === "Enter" && toggleOpen(true);
40034
+ },
40035
+ tabIndex: "0",
40036
+ color: themeValues.linkColor,
40037
+ weight: themeValues.fontWeight,
40038
+ hoverStyles: themeValues.modalLinkHoverFocus,
40039
+ extraStyles: "cursor: pointer;"
40040
+ }, link));
40221
40041
  };
40222
40042
 
40223
40043
  var TermsAndConditionsModal$1 = themeComponent(TermsAndConditionsModal, "TermsAndConditionsModal", fallbackValues$B, "default");
40224
40044
 
40225
- function _templateObject2$m() {
40226
- var data = _taggedTemplateLiteral([""]);
40227
-
40228
- _templateObject2$m = function _templateObject2() {
40229
- return data;
40230
- };
40231
-
40232
- return data;
40233
- }
40234
-
40235
- function _templateObject$G() {
40236
- var data = _taggedTemplateLiteral(["\n outline: none;\n"]);
40237
-
40238
- _templateObject$G = function _templateObject() {
40239
- return data;
40240
- };
40241
-
40242
- return data;
40243
- }
40244
- var CheckboxWrapper$5 = styled__default.div(_templateObject$G());
40245
- var ModalWrapper$1 = styled__default.div(_templateObject2$m());
40246
-
40247
40045
  var TermsAndConditions = function TermsAndConditions(_ref) {
40248
40046
  var onCheck = _ref.onCheck,
40249
40047
  isChecked = _ref.isChecked,
@@ -40257,49 +40055,17 @@ var TermsAndConditions = function TermsAndConditions(_ref) {
40257
40055
  showTerms = _useState2[0],
40258
40056
  toggleShowTerms = _useState2[1];
40259
40057
 
40260
- var _useState3 = React.useState(false),
40261
- _useState4 = _slicedToArray(_useState3, 2),
40262
- checkboxFocused = _useState4[0],
40263
- focusCheckbox = _useState4[1];
40264
-
40265
- var handleClick = function handleClick(e, func) {
40266
- if ((e === null || e === void 0 ? void 0 : e.keyCode) === 13) {
40267
- func();
40268
- }
40269
- };
40270
-
40271
- return /*#__PURE__*/React__default.createElement(DisplayBox$1, null, /*#__PURE__*/React__default.createElement(Stack, {
40272
- direction: "row"
40273
- }, /*#__PURE__*/React__default.createElement(CheckboxWrapper$5, {
40274
- tabIndex: "0",
40275
- onFocus: function onFocus() {
40276
- return focusCheckbox(true);
40277
- },
40278
- onBlur: function onBlur() {
40279
- return focusCheckbox(false);
40280
- },
40281
- onKeyDown: function onKeyDown(e) {
40282
- return handleClick(e, onCheck);
40283
- }
40284
- }, /*#__PURE__*/React__default.createElement(Checkbox$1, {
40058
+ return /*#__PURE__*/React__default.createElement(DisplayBox$1, null, /*#__PURE__*/React__default.createElement(Stack, null, /*#__PURE__*/React__default.createElement(Checkbox$1, {
40285
40059
  name: "terms",
40060
+ title: "Terms and Conditions",
40286
40061
  error: error,
40287
40062
  checked: isChecked,
40288
- onChange: onCheck,
40289
- focused: checkboxFocused
40290
- })), /*#__PURE__*/React__default.createElement(Stack, null, /*#__PURE__*/React__default.createElement(Text$1, {
40291
- variant: "p",
40292
- fontWeight: FONT_WEIGHT_BOLD
40293
- }, "Terms and Conditions"), /*#__PURE__*/React__default.createElement(Box, {
40063
+ onChange: onCheck
40064
+ }), /*#__PURE__*/React__default.createElement(Box, {
40065
+ padding: "0 0 0 58px"
40066
+ }, /*#__PURE__*/React__default.createElement(Stack, null, /*#__PURE__*/React__default.createElement(Box, {
40294
40067
  padding: "0"
40295
- }, html), terms && /*#__PURE__*/React__default.createElement(ModalWrapper$1, {
40296
- tabIndex: "0",
40297
- onKeyDown: function onKeyDown(e) {
40298
- return handleClick(e, function () {
40299
- return toggleShowTerms(!showTerms);
40300
- });
40301
- }
40302
- }, /*#__PURE__*/React__default.createElement(TermsAndConditionsModal$1, {
40068
+ }, html), terms && /*#__PURE__*/React__default.createElement(TermsAndConditionsModal$1, {
40303
40069
  link: "Learn More",
40304
40070
  terms: terms,
40305
40071
  isOpen: showTerms,
@@ -40344,29 +40110,29 @@ var Timeout = function Timeout(_ref) {
40344
40110
 
40345
40111
  var Timeout$1 = withWindowSize(Timeout);
40346
40112
 
40347
- var fontWeight$8 = "600";
40113
+ var fontWeight$9 = "600";
40348
40114
  var fontColor$1 = WHITE;
40349
40115
  var textAlign$1 = "left";
40350
40116
  var headerBackgroundColor = BRIGHT_GREY;
40351
40117
  var imageBackgroundColor = MATISSE_BLUE;
40352
40118
  var fallbackValues$C = {
40353
- fontWeight: fontWeight$8,
40119
+ fontWeight: fontWeight$9,
40354
40120
  fontColor: fontColor$1,
40355
40121
  textAlign: textAlign$1,
40356
40122
  headerBackgroundColor: headerBackgroundColor,
40357
40123
  imageBackgroundColor: imageBackgroundColor
40358
40124
  };
40359
40125
 
40360
- function _templateObject$H() {
40126
+ function _templateObject$B() {
40361
40127
  var data = _taggedTemplateLiteral(["\n width: auto;\n height: 215px;\n"]);
40362
40128
 
40363
- _templateObject$H = function _templateObject() {
40129
+ _templateObject$B = function _templateObject() {
40364
40130
  return data;
40365
40131
  };
40366
40132
 
40367
40133
  return data;
40368
40134
  }
40369
- var WelcomeImage = styled__default.img(_templateObject$H());
40135
+ var WelcomeImage = styled__default.img(_templateObject$B());
40370
40136
 
40371
40137
  var WelcomeModule = function WelcomeModule(_ref) {
40372
40138
  var heading = _ref.heading,