@thecb/components 8.4.11-beta.20 → 8.4.11-beta.22
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 +33 -23
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +33 -23
- package/dist/index.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/components/atoms/form-select/FormSelect.js +2 -0
- package/src/components/molecules/address-form/AddressForm.js +7 -0
- package/src/components/molecules/payment-form-ach/PaymentFormACH.js +8 -8
- package/src/components/molecules/payment-form-card/PaymentFormCard.js +7 -6
package/dist/index.esm.js
CHANGED
|
@@ -24203,6 +24203,7 @@ var FormSelect = function FormSelect(_ref) {
|
|
|
24203
24203
|
extraStyles: "word-break: break-word;\n font-family: Public Sans;\n &::first-letter {\n text-transform: uppercase;\n }",
|
|
24204
24204
|
id: createIdFromString(labelTextWhenNoError)
|
|
24205
24205
|
}, labelTextWhenNoError))), /*#__PURE__*/React.createElement(Dropdown$1, {
|
|
24206
|
+
"data-qa": labelTextWhenNoError,
|
|
24206
24207
|
ariaLabelledby: createIdFromString(labelTextWhenNoError),
|
|
24207
24208
|
"aria-describedby": createIdFromString(labelTextWhenNoError, "error message"),
|
|
24208
24209
|
maxHeight: dropdownMaxHeight,
|
|
@@ -24236,7 +24237,8 @@ var FormSelect = function FormSelect(_ref) {
|
|
|
24236
24237
|
weight: themeValues.fontWeight,
|
|
24237
24238
|
extraStyles: "\n word-break: break-word;\n font-family: Public Sans;\n &::first-letter {\n text-transform: uppercase;\n }\n ",
|
|
24238
24239
|
id: createIdFromString(labelTextWhenNoError, "error message"),
|
|
24239
|
-
"aria-live": "polite"
|
|
24240
|
+
"aria-live": "polite",
|
|
24241
|
+
"data-qa": labelTextWhenNoError
|
|
24240
24242
|
}, field.hasErrors && field.dirty || field.hasErrors && showErrors ? errorMessages[field.errors[0]] : "")));
|
|
24241
24243
|
};
|
|
24242
24244
|
|
|
@@ -40372,7 +40374,8 @@ var AddressForm = function AddressForm(_ref) {
|
|
|
40372
40374
|
actions.fields.zip.set("");
|
|
40373
40375
|
}
|
|
40374
40376
|
},
|
|
40375
|
-
showErrors: showErrors
|
|
40377
|
+
showErrors: showErrors,
|
|
40378
|
+
"data-qa": "Country"
|
|
40376
40379
|
}), /*#__PURE__*/React.createElement(FormInput$1, {
|
|
40377
40380
|
labelTextWhenNoError: "Address",
|
|
40378
40381
|
errorMessages: street1ErrorMessages,
|
|
@@ -40384,7 +40387,8 @@ var AddressForm = function AddressForm(_ref) {
|
|
|
40384
40387
|
return e.key === "Enter" && handleSubmit(e);
|
|
40385
40388
|
},
|
|
40386
40389
|
autocomplete: "address-line1",
|
|
40387
|
-
"aria-label": "Address Line 1"
|
|
40390
|
+
"aria-label": "Address Line 1",
|
|
40391
|
+
"data-qa": "Address Line 1"
|
|
40388
40392
|
}), /*#__PURE__*/React.createElement(FormInput$1, {
|
|
40389
40393
|
labelTextWhenNoError: "Apt, Suite, Unit, Floor, etc. (Optional)",
|
|
40390
40394
|
field: fields.street2,
|
|
@@ -40394,7 +40398,8 @@ var AddressForm = function AddressForm(_ref) {
|
|
|
40394
40398
|
return e.key === "Enter" && handleSubmit(e);
|
|
40395
40399
|
},
|
|
40396
40400
|
autocomplete: "address-line2",
|
|
40397
|
-
"aria-label": "Address Line 2"
|
|
40401
|
+
"aria-label": "Address Line 2",
|
|
40402
|
+
"data-qa": "Address Line 2"
|
|
40398
40403
|
}), /*#__PURE__*/React.createElement(FormInput$1, {
|
|
40399
40404
|
labelTextWhenNoError: "City",
|
|
40400
40405
|
required: true,
|
|
@@ -40406,7 +40411,8 @@ var AddressForm = function AddressForm(_ref) {
|
|
|
40406
40411
|
return e.key === "Enter" && handleSubmit(e);
|
|
40407
40412
|
},
|
|
40408
40413
|
autocomplete: "city",
|
|
40409
|
-
"aria-label": "City"
|
|
40414
|
+
"aria-label": "City",
|
|
40415
|
+
"data-qa": "City"
|
|
40410
40416
|
}), /*#__PURE__*/React.createElement(FormStateDropdown, {
|
|
40411
40417
|
labelTextWhenNoError: isUS ? "State" : "State or Province",
|
|
40412
40418
|
errorMessages: stateProvinceErrorMessages,
|
|
@@ -40419,7 +40425,8 @@ var AddressForm = function AddressForm(_ref) {
|
|
|
40419
40425
|
},
|
|
40420
40426
|
"aria-label": isUS ? "State" : "State or Province",
|
|
40421
40427
|
required: true,
|
|
40422
|
-
autocomplete: "administrative-area"
|
|
40428
|
+
autocomplete: "administrative-area",
|
|
40429
|
+
"data-qa": "State or Province"
|
|
40423
40430
|
}), /*#__PURE__*/React.createElement(FormInput$1, {
|
|
40424
40431
|
isNum: isUS,
|
|
40425
40432
|
formatter: isUS ? zipFormat : null,
|
|
@@ -40433,12 +40440,14 @@ var AddressForm = function AddressForm(_ref) {
|
|
|
40433
40440
|
},
|
|
40434
40441
|
"aria-label": "Zip code",
|
|
40435
40442
|
autocomplete: "postal-code",
|
|
40436
|
-
required: true
|
|
40443
|
+
required: true,
|
|
40444
|
+
"data-qa": "Zip code"
|
|
40437
40445
|
}), showWalletCheckbox && /*#__PURE__*/React.createElement(Checkbox$1, {
|
|
40438
40446
|
name: "address checkbox",
|
|
40439
40447
|
title: "Save address to wallet",
|
|
40440
40448
|
checked: walletCheckboxMarked,
|
|
40441
|
-
onChange: saveToWallet
|
|
40449
|
+
onChange: saveToWallet,
|
|
40450
|
+
"data-qa": "Save address to wallet"
|
|
40442
40451
|
})));
|
|
40443
40452
|
};
|
|
40444
40453
|
|
|
@@ -48871,7 +48880,7 @@ var PaymentFormACH = function PaymentFormACH(_ref) {
|
|
|
48871
48880
|
"aria-label": "ACH Payment"
|
|
48872
48881
|
}, /*#__PURE__*/React.createElement(FormInputColumn, null, /*#__PURE__*/React.createElement(FormInput$1, {
|
|
48873
48882
|
labelTextWhenNoError: "Name on checking account",
|
|
48874
|
-
|
|
48883
|
+
"data-qa": "Name on checking account",
|
|
48875
48884
|
errorMessages: nameErrors,
|
|
48876
48885
|
field: fields.name,
|
|
48877
48886
|
fieldActions: actions.fields.name,
|
|
@@ -48882,7 +48891,7 @@ var PaymentFormACH = function PaymentFormACH(_ref) {
|
|
|
48882
48891
|
autocomplete: "name"
|
|
48883
48892
|
}), /*#__PURE__*/React.createElement(FormInput$1, {
|
|
48884
48893
|
labelTextWhenNoError: "Routing number",
|
|
48885
|
-
|
|
48894
|
+
"data-qa": "Routing number",
|
|
48886
48895
|
errorMessages: routingNumberErrors,
|
|
48887
48896
|
field: fields.routingNumber,
|
|
48888
48897
|
fieldActions: actions.fields.routingNumber,
|
|
@@ -48903,7 +48912,7 @@ var PaymentFormACH = function PaymentFormACH(_ref) {
|
|
|
48903
48912
|
}
|
|
48904
48913
|
}), /*#__PURE__*/React.createElement(FormInput$1, {
|
|
48905
48914
|
labelTextWhenNoError: "Confirm routing number",
|
|
48906
|
-
|
|
48915
|
+
"data-qa": "Confirm routing number",
|
|
48907
48916
|
errorMessages: confirmRoutingNumberErrors,
|
|
48908
48917
|
field: fields.confirmRoutingNumber,
|
|
48909
48918
|
fieldActions: actions.fields.confirmRoutingNumber,
|
|
@@ -48914,7 +48923,7 @@ var PaymentFormACH = function PaymentFormACH(_ref) {
|
|
|
48914
48923
|
isNum: true
|
|
48915
48924
|
}), /*#__PURE__*/React.createElement(FormInput$1, {
|
|
48916
48925
|
labelTextWhenNoError: "Account number",
|
|
48917
|
-
|
|
48926
|
+
"data-qa": "Account number",
|
|
48918
48927
|
errorMessages: accountNumberErrors,
|
|
48919
48928
|
field: fields.accountNumber,
|
|
48920
48929
|
fieldActions: actions.fields.accountNumber,
|
|
@@ -48935,7 +48944,7 @@ var PaymentFormACH = function PaymentFormACH(_ref) {
|
|
|
48935
48944
|
}
|
|
48936
48945
|
}), /*#__PURE__*/React.createElement(FormInput$1, {
|
|
48937
48946
|
labelTextWhenNoError: "Confirm account number",
|
|
48938
|
-
|
|
48947
|
+
"data-qa": "Confirm account number",
|
|
48939
48948
|
errorMessages: confirmAccountNumberErrors,
|
|
48940
48949
|
field: fields.confirmAccountNumber,
|
|
48941
48950
|
fieldActions: actions.fields.confirmAccountNumber,
|
|
@@ -48946,7 +48955,7 @@ var PaymentFormACH = function PaymentFormACH(_ref) {
|
|
|
48946
48955
|
isNum: true
|
|
48947
48956
|
}), allowBankAccountType && /*#__PURE__*/React.createElement(FormSelect$1, {
|
|
48948
48957
|
labelTextWhenNoError: "Account type",
|
|
48949
|
-
|
|
48958
|
+
"data-qa": "Account type",
|
|
48950
48959
|
options: [{
|
|
48951
48960
|
text: "Select account type",
|
|
48952
48961
|
value: ""
|
|
@@ -48963,7 +48972,7 @@ var PaymentFormACH = function PaymentFormACH(_ref) {
|
|
|
48963
48972
|
field: fields.accountType
|
|
48964
48973
|
}), !hideDefaultPayment && /*#__PURE__*/React.createElement(Checkbox$1, {
|
|
48965
48974
|
title: "Save as Default Payment Method",
|
|
48966
|
-
|
|
48975
|
+
"data-qa": "default-payment-ach",
|
|
48967
48976
|
name: "default-payment-ach",
|
|
48968
48977
|
onChange: toggleCheckbox,
|
|
48969
48978
|
checked: defaultMethod.value,
|
|
@@ -48973,7 +48982,7 @@ var PaymentFormACH = function PaymentFormACH(_ref) {
|
|
|
48973
48982
|
align: "center"
|
|
48974
48983
|
}, showWalletCheckbox && /*#__PURE__*/React.createElement(Checkbox$1, {
|
|
48975
48984
|
name: "bank checkbox",
|
|
48976
|
-
|
|
48985
|
+
"data-qa": "Save checking account to wallet",
|
|
48977
48986
|
title: "Save checking account to wallet.",
|
|
48978
48987
|
checked: walletCheckboxMarked,
|
|
48979
48988
|
onChange: saveToWallet
|
|
@@ -49086,10 +49095,11 @@ var PaymentFormCard = function PaymentFormCard(_ref) {
|
|
|
49086
49095
|
actions.fields.zipCode.set("");
|
|
49087
49096
|
}
|
|
49088
49097
|
},
|
|
49089
|
-
showErrors: showErrors
|
|
49098
|
+
showErrors: showErrors,
|
|
49099
|
+
"data-qa": "Country"
|
|
49090
49100
|
}), /*#__PURE__*/React.createElement(FormInput$1, {
|
|
49091
49101
|
labelTextWhenNoError: "Name on card",
|
|
49092
|
-
|
|
49102
|
+
"data-qa": "Name on card",
|
|
49093
49103
|
errorMessages: nameOnCardErrors,
|
|
49094
49104
|
field: fields.nameOnCard,
|
|
49095
49105
|
fieldActions: actions.fields.nameOnCard,
|
|
@@ -49100,7 +49110,7 @@ var PaymentFormCard = function PaymentFormCard(_ref) {
|
|
|
49100
49110
|
autocomplete: "cc-name"
|
|
49101
49111
|
}), /*#__PURE__*/React.createElement(FormInput$1, {
|
|
49102
49112
|
labelTextWhenNoError: "Credit card number",
|
|
49103
|
-
|
|
49113
|
+
"data-qa": "Credit card number",
|
|
49104
49114
|
errorMessages: creditCardNumberErrors,
|
|
49105
49115
|
field: fields.creditCardNumber,
|
|
49106
49116
|
fieldActions: actions.fields.creditCardNumber,
|
|
@@ -49116,7 +49126,7 @@ var PaymentFormCard = function PaymentFormCard(_ref) {
|
|
|
49116
49126
|
childGap: isMobile ? "0rem" : "1rem"
|
|
49117
49127
|
}, /*#__PURE__*/React.createElement(FormInput$1, {
|
|
49118
49128
|
labelTextWhenNoError: "Expiration date (MM/YY)",
|
|
49119
|
-
|
|
49129
|
+
"data-qa": "Expiration date",
|
|
49120
49130
|
errorMessages: expirationDateErrors,
|
|
49121
49131
|
field: fields.expirationDate,
|
|
49122
49132
|
fieldActions: actions.fields.expirationDate,
|
|
@@ -49131,7 +49141,7 @@ var PaymentFormCard = function PaymentFormCard(_ref) {
|
|
|
49131
49141
|
autocomplete: "cc-exp"
|
|
49132
49142
|
}), /*#__PURE__*/React.createElement(FormInput$1, {
|
|
49133
49143
|
labelTextWhenNoError: "CVV",
|
|
49134
|
-
|
|
49144
|
+
"data-qa": "CVV",
|
|
49135
49145
|
errorMessages: cvvErrors,
|
|
49136
49146
|
field: fields.cvv,
|
|
49137
49147
|
fieldActions: actions.fields.cvv,
|
|
@@ -49149,7 +49159,7 @@ var PaymentFormCard = function PaymentFormCard(_ref) {
|
|
|
49149
49159
|
isNum: isUS,
|
|
49150
49160
|
formatter: isUS ? zipFormat : null,
|
|
49151
49161
|
labelTextWhenNoError: "Zip code",
|
|
49152
|
-
|
|
49162
|
+
"data-qa": "Zip code",
|
|
49153
49163
|
errorMessages: zipCodeErrors,
|
|
49154
49164
|
field: fields.zipCode,
|
|
49155
49165
|
fieldActions: actions.fields.zipCode,
|
|
@@ -49163,7 +49173,7 @@ var PaymentFormCard = function PaymentFormCard(_ref) {
|
|
|
49163
49173
|
align: "center"
|
|
49164
49174
|
}, showWalletCheckbox && /*#__PURE__*/React.createElement(Checkbox$1, {
|
|
49165
49175
|
name: "credit card checkbox",
|
|
49166
|
-
|
|
49176
|
+
"data-qa": "Save credit card to wallet",
|
|
49167
49177
|
title: "Save credit card to wallet.",
|
|
49168
49178
|
checked: walletCheckboxMarked,
|
|
49169
49179
|
onChange: saveToWallet
|