@thecb/components 8.4.11-beta.1 → 8.4.11-beta.3
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 +17 -13
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +17 -13
- package/dist/index.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/components/atoms/alert/Alert.js +1 -0
- package/src/components/atoms/checkbox/Checkbox.js +1 -1
- package/src/components/molecules/address-form/AddressForm.js +13 -10
package/package.json
CHANGED
|
@@ -51,7 +51,6 @@ const AddressForm = ({
|
|
|
51
51
|
<CountryDropdown
|
|
52
52
|
labelTextWhenNoError="Country"
|
|
53
53
|
errorMessages={countryErrorMessages}
|
|
54
|
-
aria-label="country"
|
|
55
54
|
field={fields.country}
|
|
56
55
|
onChange={value => {
|
|
57
56
|
actions.fields.country.set(value);
|
|
@@ -65,17 +64,19 @@ const AddressForm = ({
|
|
|
65
64
|
}
|
|
66
65
|
}}
|
|
67
66
|
showErrors={showErrors}
|
|
67
|
+
aria-label="country"
|
|
68
|
+
aria-role="listbox"
|
|
68
69
|
/>
|
|
69
70
|
<FormInput
|
|
70
71
|
labelTextWhenNoError="Address"
|
|
71
72
|
errorMessages={street1ErrorMessages}
|
|
72
73
|
required={true}
|
|
73
|
-
aria-label="address line 1"
|
|
74
74
|
field={fields.street1}
|
|
75
75
|
fieldActions={actions.fields.street1}
|
|
76
76
|
showErrors={showErrors}
|
|
77
77
|
onKeyDown={e => e.key === "Enter" && handleSubmit(e)}
|
|
78
|
-
|
|
78
|
+
autocomplete="address-line1"
|
|
79
|
+
aria-label="address line 1"
|
|
79
80
|
/>
|
|
80
81
|
<FormInput
|
|
81
82
|
labelTextWhenNoError="Apt, Suite, Unit, Floor, etc. (Optional)"
|
|
@@ -83,18 +84,19 @@ const AddressForm = ({
|
|
|
83
84
|
fieldActions={actions.fields.street2}
|
|
84
85
|
showErrors={showErrors}
|
|
85
86
|
onKeyDown={e => e.key === "Enter" && handleSubmit(e)}
|
|
86
|
-
|
|
87
|
+
autocomplete="address-line2"
|
|
88
|
+
aria-label="address line 2"
|
|
87
89
|
/>
|
|
88
90
|
<FormInput
|
|
89
91
|
labelTextWhenNoError="City"
|
|
90
|
-
aria-label="city"
|
|
91
92
|
required={true}
|
|
92
93
|
errorMessages={cityErrorMessages}
|
|
93
94
|
field={fields.city}
|
|
94
95
|
fieldActions={actions.fields.city}
|
|
95
96
|
showErrors={showErrors}
|
|
96
97
|
onKeyDown={e => e.key === "Enter" && handleSubmit(e)}
|
|
97
|
-
|
|
98
|
+
autocomplete="city"
|
|
99
|
+
aria-label="city"
|
|
98
100
|
/>
|
|
99
101
|
<StateProvinceDropdown
|
|
100
102
|
labelTextWhenNoError={isUS ? "State" : "State or Province"}
|
|
@@ -104,8 +106,8 @@ const AddressForm = ({
|
|
|
104
106
|
fieldActions={actions.fields.stateProvince}
|
|
105
107
|
showErrors={showErrors}
|
|
106
108
|
onKeyDown={e => e.key === "Enter" && handleSubmit(e)}
|
|
107
|
-
autoComplete="
|
|
108
|
-
aria-label={isUS ? "
|
|
109
|
+
autoComplete="administrative-area"
|
|
110
|
+
aria-label={isUS ? "state" : "state or province"}
|
|
109
111
|
required={true}
|
|
110
112
|
/>
|
|
111
113
|
<FormInput
|
|
@@ -117,12 +119,13 @@ const AddressForm = ({
|
|
|
117
119
|
fieldActions={actions.fields.zip}
|
|
118
120
|
showErrors={showErrors}
|
|
119
121
|
onKeyDown={e => e.key === "Enter" && handleSubmit(e)}
|
|
120
|
-
|
|
122
|
+
aria-label="zip code"
|
|
123
|
+
autocomplete="postal-code"
|
|
121
124
|
/>
|
|
122
125
|
{showWalletCheckbox && (
|
|
123
126
|
<Checkbox
|
|
124
127
|
name="address checkbox"
|
|
125
|
-
title="Save address to
|
|
128
|
+
title="Save address to Wallet"
|
|
126
129
|
checked={walletCheckboxMarked}
|
|
127
130
|
onChange={saveToWallet}
|
|
128
131
|
/>
|