[docs] Remove unused PlatformTag component and redundant tooltip on platform tags#5066
Conversation
… in documentation
|
@apicgg is attempting to deploy a commit to the Meta Open Source Team on Vercel. A member of the Team first needs to authorize it. |
✅ Deploy Preview for react-native ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
Simek
left a comment
There was a problem hiding this comment.
Hey @apicgg, thanks for the updates! 👍
Drop the title attribute on inline platform tags in docs/platform-specific-code.md — the "Android" / "iOS" badge labels are self-explanatory, so the hover tooltip ("This section is related to X platform") adds no information.
Ideally, we should have those more verbose descriptions for a11y purpose, but we can use aria-label instead. I guess that was the idea with the PlatformTag.tsx component, but it's fine to remove it for now, since the component does not support all of the platforms anyway.
Summary
Cleanup of leftover artifacts from two older PRs (#4097, #4178):
website/core/PlatformTag.tsx— the component is not imported or referenced anywhere in the app. Confirmed via repo-wide search; only its own definition andexport defaultexist. Safe to delete as dead code.titleattribute on inline platform tags indocs/platform-specific-code.md— the "Android" / "iOS" badge labels are self-explanatory, so the hover tooltip ("This section is related to X platform") adds no information.Why
These were introduced two years ago but never wired up across the docs. The component has sat unused, and the tooltip duplicates what the badge text already says. Removing both reduces surface area and avoids confusion for future contributors who might wonder which path is canonical.
Changes
website/core/PlatformTag.tsxdocs/platform-specific-code.mdto removetitle="..."from the two inline<div className="label ...">tagsTest plan
c/c @Simek @cortinico