Context
The Copy button confirms by changing its own visible text to "Copied". A screen reader will not announce that change, because nothing tells it to. A blind user presses the button and gets silence — with no way to know whether it worked.
What to change
Files: js/copy-code.js, and possibly the page markup
Requirements:
- Announce success and failure through a polite live region
- One shared live region is fine and is preferable to one per button
- The failure path — where the label becomes "Press Ctrl+C" — needs announcing too
- Do not make the announcement assertive; this does not warrant interrupting
Acceptance criteria
How to verify locally
python3 -m http.server 8000
Then open http://localhost:8000.
Difficulty
Intermediate. Please test with an actual screen reader rather than assuming.
New here? Comment /claim on this issue and a bot will assign it to you. Then read CONTRIBUTING.md.
Stuck at any point? Comment here saying what you have tried and where it stopped working — that is not an admission of failure, it is how we find out the instructions were unclear. You can also come to a PR Debug Clinic (Oct 12 or Oct 21).
Context
The Copy button confirms by changing its own visible text to "Copied". A screen reader will not announce that change, because nothing tells it to. A blind user presses the button and gets silence — with no way to know whether it worked.
What to change
Files:
js/copy-code.js, and possibly the page markupRequirements:
Acceptance criteria
How to verify locally
Then open http://localhost:8000.
Difficulty
Intermediate. Please test with an actual screen reader rather than assuming.
New here? Comment
/claimon this issue and a bot will assign it to you. Then read CONTRIBUTING.md.Stuck at any point? Comment here saying what you have tried and where it stopped working — that is not an admission of failure, it is how we find out the instructions were unclear. You can also come to a PR Debug Clinic (Oct 12 or Oct 21).