diff --git a/site/src/content/docs/forms/select-input.mdx b/site/src/content/docs/forms/select-input.mdx index ccf0e94ed1..60868d3aa9 100644 --- a/site/src/content/docs/forms/select-input.mdx +++ b/site/src/content/docs/forms/select-input.mdx @@ -165,13 +165,13 @@ If the helper text is not sufficient, it’s possible to offer the user an addit To display a helper link below selects, use a standard small link [with `.link` and `.link-small` classes]([[docsref:/components/links#sizes]]) as a sibling of a `.select-input-container`. -If a helper link is used in conjunction with a helper text, the `aria-describedby` attribute should refer to the helper text and the helper link should be referenced by the `aria-labelledby` attribute. +Helper link should be explicitly labelled using the `aria-labelledby` attribute in which you must combine the helper link id and the related select input label id. This will ensure that assistive technologies—such as screen readers—will announce this helper link in relation with the select input. We also recommend adding a `.visually-hidden` span inside the link to coordinate the link content and the label.
- @@ -181,22 +181,22 @@ If a helper link is used in conjunction with a helper text, the `aria-describedb

Choose a number.

- - More information about how to choose a number + + More information about the
-
- - More information about how to choose a number with a link + + More information about the
`} /> @@ -286,13 +286,13 @@ Add the `readonly` boolean attribute on an input to prevent modification of the To display an invalid select, add `.is-invalid` to a `.select-input-field` within the `.select-input-container`. Please take a look at our [Validation page to learn more]([[docsref:/forms/validation]]). -For accessibility purposes, the invalid state should be associated with a `.error-text` as a sibling of a `.select-input-container` and related to it with an `aria-labelledby` attribute when displayed. Note that the `.error-text` will replace the helper text, so it should be descriptive enough to convey the error. +For accessibility purposes, the invalid state should be associated with a `.error-text` as a sibling of a `.select-input-container` and related to it with an `aria-describedby` attribute when displayed. Note that the `.error-text` will replace the helper text, so it should be descriptive enough to convey the error note that the `.error-text` will replace the helper text, so it should be descriptive enough to convey the error and you must dynamically replace the `aria-describedby` attribute when the select input becomes invalid.
- @@ -305,15 +305,15 @@ For accessibility purposes, the invalid state should be associated with a `.erro

A number is required.

- - More information about how to choose a number from these three + + More information about the
- @@ -326,15 +326,15 @@ For accessibility purposes, the invalid state should be associated with a `.erro

A number is required.

- - More information about how to choose a number from the three available options + + More information about the
- @@ -354,7 +354,7 @@ For accessibility purposes, the invalid state should be associated with a `.erro - diff --git a/site/src/content/docs/forms/text-area.mdx b/site/src/content/docs/forms/text-area.mdx index c7c9d9a758..9aa4786c13 100644 --- a/site/src/content/docs/forms/text-area.mdx +++ b/site/src/content/docs/forms/text-area.mdx @@ -91,28 +91,28 @@ If the helper text is not sufficient, it’s possible to offer the user an addit To display a helper link below text areas, use a standard small link [with `.link` and `.link-small` classes]([[docsref:/components/links#sizes]]) as a sibling of a `.text-area-container`. -If a helper link is used in conjunction with a helper text, the `aria-describedby` attribute should refer to the helper text and the helper link should be referenced by the `aria-labelledby` attribute. +Helper link should be explicitly described using the `aria-labelledby` attribute in which you must combine the helper link id and the related text area label id. This will ensure that assistive technologies—such as screen readers—will announce this helper link in relation with the text area. We also recommend adding a `.visually-hidden` span inside the link to coordinate the link content and the label.
- +

Please be concise and limit your comment to 180 characters.

- - More information + + More information on
- - + +
- - More information + + More information on
`} /> @@ -175,13 +175,13 @@ Add the `readonly` boolean attribute on a text area to prevent modification of t To display an invalid text area, add `.is-invalid` to a `.text-area-field` within the `.text-area-container`. Please take a look at our [Validation page to learn more]([[docsref:/forms/validation]]). -For accessibility purposes, the invalid state should be associated with a `.error-text` as a sibling of a `.text-area-container` and related to it with an `aria-labelledby` attribute when displayed. Note that the `.error-text` will replace the helper text, so it should be descriptive enough to convey the error. +For accessibility purposes, the invalid state should be associated with a `.error-text` as a sibling of a `.text-area-container` and related to it with an `aria-describedby` attribute when displayed. Note that the `.error-text` will replace the helper text, so it should be descriptive enough to convey the error and you must dynamically replace the `aria-describedby` attribute when the text area becomes invalid.
- +

Please be concise and limit your comment to 180 characters. @@ -192,8 +192,8 @@ For accessibility purposes, the invalid state should be associated with a `.erro

- - + +

Please be concise and limit your comment to 180 characters. @@ -201,7 +201,7 @@ For accessibility purposes, the invalid state should be associated with a `.erro

Your comment exceeded the limit of 180 characters.

- - More information + + More information on
`} /> diff --git a/site/src/content/docs/forms/text-input.mdx b/site/src/content/docs/forms/text-input.mdx index 5e569293ab..7246125a3d 100644 --- a/site/src/content/docs/forms/text-input.mdx +++ b/site/src/content/docs/forms/text-input.mdx @@ -188,28 +188,28 @@ If the helper text is not sufficient, it's possible to offer the user an additio To display a helper link below inputs, use a standard small link [with `.link` and `.link-small` classes]([[docsref:/components/links#sizes]]) as a sibling of a `.text-input-container`. -If a helper link is used in conjunction with a helper text, the `aria-describedby` attribute should refer to the helper text and the helper link should be referenced by the `aria-labelledby` attribute. +Helper link should be explicitly described using the `aria-labelledby` attribute in which you must combine the helper link id and the related text input label id. This will ensure that assistive technologies—such as screen readers—will announce this helper link in relation with the input. We also recommend adding a `.visually-hidden` span inside the link to coordinate the link content and the label.
- +

Please describe your feedback in a few words.

- - More information + + More information on
- +
- - More information + + More information on
`} /> @@ -366,13 +366,13 @@ Add the `readonly` boolean attribute on an input to prevent modification of the To display an invalid input, add `.is-invalid` to a `.text-input-field` within the `.text-input-container`. Please take a look at our [Validation page to learn more]([[docsref:/forms/validation]]). -For accessibility purposes, the invalid state should be associated with a `.error-text` as a sibling of a `.text-input-container` and related to it with an `aria-labelledby` attribute when displayed. Note that the `.error-text` will replace the helper text, so it should be descriptive enough to convey the error. +For accessibility purposes, the invalid state should be associated with a `.error-text` as a sibling of a `.text-input-container` and related to it with an `aria-describedby` attribute when displayed. Note that the `.error-text` will replace the helper text, so it should be descriptive enough to convey the error and you must dynamically replace the `aria-describedby` attribute when switching the text input to invalid.
- +

Please choose a username. @@ -384,7 +384,7 @@ For accessibility purposes, the invalid state should be associated with a `.erro

- +

Address is required. @@ -411,7 +411,7 @@ For accessibility purposes, the invalid state should be associated with a `.erro

- +

City is invalid. @@ -424,7 +424,7 @@ For accessibility purposes, the invalid state should be associated with a `.erro

- +

@@ -438,7 +438,7 @@ For accessibility purposes, the invalid state should be associated with a `.erro

- +
`} />