@thecb/components 9.2.10-beta.11 → 9.2.10-beta.13
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 +7 -4
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +7 -4
- package/dist/index.esm.js.map +1 -1
- package/package.json +1 -1
- package/src/components/atoms/checkbox/Checkbox.js +6 -1
- package/src/components/atoms/checkbox/Checkbox.stories.js +1 -1
- package/src/components/molecules/terms-and-conditions/TermsAndConditionsControlV1.js +1 -1
- package/src/components/molecules/terms-and-conditions/TermsAndConditionsControlV2.js +1 -1
package/package.json
CHANGED
|
@@ -127,8 +127,8 @@ const Checkbox = ({
|
|
|
127
127
|
id={`checkbox-${name}`}
|
|
128
128
|
disabled={disabled}
|
|
129
129
|
name={name}
|
|
130
|
-
aria-label={checkboxAriaLabel || `${title} checkbox`}
|
|
131
130
|
checked={checked}
|
|
131
|
+
hidden={true}
|
|
132
132
|
onChange={onChange}
|
|
133
133
|
tabIndex="-1"
|
|
134
134
|
aria-invalid={error}
|
|
@@ -150,6 +150,10 @@ const Checkbox = ({
|
|
|
150
150
|
disabledStyles={themeValues.disabledStyles}
|
|
151
151
|
disabledCheckedStyles={themeValues.disabledCheckedStyles}
|
|
152
152
|
focusedStyles={themeValues.focusedStyles}
|
|
153
|
+
aria-describedby={error ? `${name}-error-message` : ""}
|
|
154
|
+
aria-labelledby={
|
|
155
|
+
!checkboxAriaLabel ? `${name}_checkbox_title` : undefined
|
|
156
|
+
}
|
|
153
157
|
{...checkboxProps}
|
|
154
158
|
>
|
|
155
159
|
<CheckboxIcon
|
|
@@ -165,6 +169,7 @@ const Checkbox = ({
|
|
|
165
169
|
{title && (
|
|
166
170
|
<Text
|
|
167
171
|
variant="p"
|
|
172
|
+
id={`${name}_checkbox_title`}
|
|
168
173
|
weight={themeValues.textFontWeight}
|
|
169
174
|
color={themeValues.textColor}
|
|
170
175
|
extraStyles={
|
|
@@ -59,7 +59,7 @@ const TermsAndConditionsControlV2 = ({
|
|
|
59
59
|
onChange={onCheck}
|
|
60
60
|
checkboxMargin={checkboxMargin}
|
|
61
61
|
extraStyles={`align-self: flex-start;`}
|
|
62
|
-
|
|
62
|
+
checkboxAriaLabel={checkboxAriaLabel}
|
|
63
63
|
/>
|
|
64
64
|
)}
|
|
65
65
|
<Stack childGap="0.25rem" fullHeight>
|