Skip to content

Conversation

@dchyun
Copy link
Contributor

@dchyun dchyun commented May 22, 2025

📌 Summary

If merged, this PR would update the CodeBlock docs to include new aria arguments from #2879.

The ariaDescribedBy argument was also added to the CodeEditor docs, which was already present in the component through its extension of the hds-code-editor modifier.

🔗 External links

Jira ticket: HDS-3349


👀 Component checklist

💬 Please consider using conventional comments when reviewing this PR.

@vercel
Copy link

vercel bot commented May 22, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
hds-showcase ✅ Ready (Inspect) Visit Preview Jun 4, 2025 6:47pm
hds-website ✅ Ready (Inspect) Visit Preview Jun 4, 2025 6:47pm

@hashibot-hds hashibot-hds added the docs-website Content updates to the documentation website label May 22, 2025
@dchyun dchyun changed the title [Website] CodeBlock a11y improvements docs Website - CodeBlock a11y improvements docs May 22, 2025
@dchyun dchyun marked this pull request as ready for review May 22, 2025 18:35
@dchyun dchyun requested review from a team as code owners May 22, 2025 18:35
zamoore
zamoore previously approved these changes May 22, 2025
Copy link
Contributor

@zamoore zamoore left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Base automatically changed from dchyun/code-block-a11y-improvements to main May 23, 2025 19:37
@dchyun dchyun dismissed zamoore’s stale review May 23, 2025 19:37

The base branch was changed.

@dchyun dchyun force-pushed the dchyun/docs-code-block-a11y-improvements branch from 7a3f514 to 0201cbd Compare May 23, 2025 19:39
@dchyun dchyun changed the base branch from main to release/website-4-20 May 23, 2025 19:43
@dchyun dchyun changed the base branch from release/website-4-20 to main June 4, 2025 12:53
@dchyun dchyun requested a review from a team June 4, 2025 12:55
@dchyun dchyun added this to the [email protected] milestone Jun 4, 2025
Copy link
Contributor

@didoo didoo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Left a couple of questions

`ContentBlock::Description` yielded as contextual component (see below).
</C.Property>
<C.Property @name="ariaLabel" @type="string">
Accepts a localized string. The `ariaLabel` value is applied to the code block pre element.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[question] why are we saying "localized" here? we don't mention localization in any other parts o the APIs (plus it works even if it's not localized)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was matching the language used for the aria attributes in the component api of the Code Editor docs

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK, I'll ask the team what they think of this.

`ContentBlock::Description` yielded as contextual component (see below).
</C.Property>
<C.Property @name="ariaLabel" @type="string">
Accepts a localized string. The `ariaLabel` value is applied to the code block pre element.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK, I'll ask the team what they think of this.

@dchyun dchyun merged commit c3fe034 into main Jun 4, 2025
10 checks passed
@dchyun dchyun deleted the dchyun/docs-code-block-a11y-improvements branch June 4, 2025 19:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

docs-website Content updates to the documentation website

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants