Skip to content

Conversation

@yanthomasdev
Copy link

@yanthomasdev yanthomasdev commented Jan 19, 2026

This PR adds screen reader-only text to the copy-code.tsx component with aria-live to give feedback once the content is copied.

This is meant to make it compliant with WCAG's Success Criterion 1.1.1: Non-text Content (Level A), ensuring the button's purpose and state, represented by an icon, can be understood by users of assistive technologies.

Changes were tested on Windows 11, Chrome, NVDA. For reference, before the announcement would be "button", now "button, copy to clipboard" and "copied" after clicked.

I haven't opened an issue since it wasn't clear if they should be opened for issues/bugs outside the library itself. Let me know if one's necessary.


Summary by cubic

Adds a screen reader–only live region to the copy-code button so assistive tech announces “Copy to clipboard” and “Copied.” This clarifies the button’s purpose and state and aligns with WCAG 1.1.1.

Written for commit 187e0ff. Summary will update on new commits.

@changeset-bot
Copy link

changeset-bot bot commented Jan 19, 2026

⚠️ No Changeset found

Latest commit: 187e0ff

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@vercel
Copy link

vercel bot commented Jan 19, 2026

@yanthomasdev is attempting to deploy a commit to the resend Team on Vercel.

A member of the Team first needs to authorize it.

@yanthomasdev yanthomasdev changed the base branch from canary to main January 19, 2026 20:37
Copy link
Contributor

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

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

No issues found across 1 file

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant