| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Detect icon-only buttons with useSlot
sr-only spans made slots.default truthy, breaking auto-detection. aria-label is an equivalent accessible alternative that lets the slot be empty.
icon-only for mobile only breaks auto-detection. Manually override padding on mobile.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Sorry, something went wrong.
|
All the errors scared me for a second but it seems like it's an issue with a package install? |
Sorry, something went wrong.
There was a problem hiding this comment.
I left a nit-pick comment, feel free to check it out and apply it or not.
Sorry, something went wrong.
Co-authored-by: Sybren W <sybren.willemot@gmail.com>
📝 Walkthrough
WalkthroughThis pull request adds icon-only detection to Button and Link base components and updates their medium/small size class bindings accordingly, then converts several package-related link/button instances to use explicit aria-label attributes instead of nested visually-hidden spans. ChangesIcon-aware styling and accessibility improvements
Possibly related PRs
Suggested reviewers
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches 🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. ❤️ ShareComment @coderabbitai help to get the list of available commands and usage tips. |
Sorry, something went wrong.
Codecov Report❌ Patch coverage is 50.00000% with 2 lines in your changes missing coverage. Please review.
📢 Thoughts on this report? Let us know! |
Sorry, something went wrong.
There was a problem hiding this comment.
Actionable comments posted: 1
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)app/components/Link/Base.vue (1)68-87: ⚠️ Potential issue | 🟡 Minor
Disabled LinkBase drops classicon content.
In the disabled branch, only <slot /> is rendered. At Line 68-87, links configured with classicon (especially icon-only usage) can render as an empty control.
🔧 Proposed fix- <span + <span v-if="disabled" @@ - ><slot - /></span> + > + <span v-if="classicon" class="size-[1em]" :class="classicon" aria-hidden="true" /> + <slot /> + </span>
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
📥 CommitsReviewing files that changed from the base of the PR and between 365bd9f and 4d3d6cd.
📒 Files selected for processing (7)
Sorry, something went wrong.
There was a problem hiding this comment.
@NeeshSamsi would you be up for updating this PR?
Sorry, something went wrong.
|
I took the liberty to update this PR with new changes from main. |
Sorry, something went wrong.
|
The difference seems to be negligible, perhaps it was bigger at the time of the PR opening 🤔 I'll close this for now, but please re-open if anyone disagrees 🙏 cc: @alexdln
|
Sorry, something went wrong.
|
Actually I do see it xD |
Sorry, something went wrong.
|
Thanks for your first contribution, @NeeshSamsi! 💫 We'd love to welcome you to the npmx community. Come and say hi on Discord! And once you've joined, visit npmx.wamellow.com to claim the contributor role. |
Sorry, something went wrong.
Co-authored-by: Sybren W <sybren.willemot@gmail.com> Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com> Co-authored-by: Felix Schneider <99918022+trueberryless@users.noreply.github.com> Co-authored-by: Willow (GHOST) <git@willow.sh>
Co-authored-by: Sybren W <sybren.willemot@gmail.com> Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com> Co-authored-by: Felix Schneider <99918022+trueberryless@users.noreply.github.com> Co-authored-by: Willow (GHOST) <git@willow.sh>
| Back | FazBrowse Home | New Git URL |
Fixes #1255
When detecting an icon-only button, I am detecting an empty slot. This was not working with the current sr-only spans. I replaced them with aria-label. As far as I know, this shouldn't be a problem but please let me know if that was overstepping on the scope of this change.
This is my first contribution to a major opensource project. Please let me know if I made any mistakes so I can figure it out.