fix: remove invalid alt attribute from anchor tag in Print component#7924
Merged
alexander-akait merged 1 commit intowebpack:mainfrom Mar 6, 2026
Merged
Conversation
alt is not a valid HTML attribute for <a> elements. It is only valid on <img>, <input type="image">, and <area>. The attribute was silently ignored by browsers but flagged as invalid HTML by validators. The link already has title="Print" for the tooltip and the nested <img> already has the correct alt="Printer Icon".
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
rahul-kr-rai
reviewed
Mar 5, 2026
Contributor
rahul-kr-rai
left a comment
There was a problem hiding this comment.
The core change is the removal of the alt attribute from the anchor <a> tag in Print.jsx. This is a valid technical cleanup because alt is not a permitted attribute for links in HTML5.
The component maintains accessibility through the existing title attribute and link text.
Ready to merge.
alexander-akait
approved these changes
Mar 6, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Removes an invalid attribute from the "" tag in the Print sidebar component. "alt" is not a valid HTML attribute for anchor elements : - browsers silently ignore it but it fails HTML validation. link already has its title="Print" for the tooltip and the nested image already has alt="Printer Icon" .
What kind of change does this PR introduce?
fix
Did you add tests for your changes?
No , removing an attribute which was already ignored cannot affect behavior.
Does this PR introduce a breaking change?
No
If relevant, what needs to be documented once your changes are merged or what have you already documented?
N/A
Use of AI
N/A