carbon-react 104.53.3 → 104.53.4

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.
@@ -7,7 +7,9 @@ export default function useInputAccessibility({
7
7
  fieldHelp
8
8
  }) {
9
9
  const labelId = label ? `${id}-label` : undefined;
10
- const validationIconId = [error, warning, info].filter(validation => typeof validation === "string").length ? `${id}-validation-icon` : undefined;
10
+ const validationIconId = [error, warning, info].filter(validation => {
11
+ return validation && typeof validation === "string";
12
+ }).length ? `${id}-validation-icon` : undefined;
11
13
  const fieldHelpId = fieldHelp ? `${id}-field-help` : undefined;
12
14
  const ariaDescribedBy = [fieldHelpId, validationIconId].filter(Boolean).join(" ");
13
15
  const ariaLabelledBy = labelId;
@@ -14,7 +14,9 @@ function useInputAccessibility({
14
14
  fieldHelp
15
15
  }) {
16
16
  const labelId = label ? `${id}-label` : undefined;
17
- const validationIconId = [error, warning, info].filter(validation => typeof validation === "string").length ? `${id}-validation-icon` : undefined;
17
+ const validationIconId = [error, warning, info].filter(validation => {
18
+ return validation && typeof validation === "string";
19
+ }).length ? `${id}-validation-icon` : undefined;
18
20
  const fieldHelpId = fieldHelp ? `${id}-field-help` : undefined;
19
21
  const ariaDescribedBy = [fieldHelpId, validationIconId].filter(Boolean).join(" ");
20
22
  const ariaLabelledBy = labelId;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "carbon-react",
3
- "version": "104.53.3",
3
+ "version": "104.53.4",
4
4
  "description": "A library of reusable React components for easily building user interfaces.",
5
5
  "engineStrict": true,
6
6
  "engines": {