Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: top/left align icon in s2 badge #7691

Merged
merged 2 commits into from
Jan 31, 2025
Merged

Conversation

yihuiliao
Copy link
Member

Closes

✅ Pull Request Checklist:

  • Included link to corresponding React Spectrum GitHub Issue.
  • Added/updated unit tests and storybook for this change (for new code or code which already has tests).
  • Filled out test instructions.
  • Updated documentation (if it already exists for this component).
  • Looked at the Accessibility Practices for this feature - Aria Practices

📝 Test Instructions:

🧢 Your Project:

@rspbot
Copy link

rspbot commented Jan 30, 2025

Copy link
Member

@snowystinger snowystinger left a comment

Choose a reason for hiding this comment

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

The icon looks a little high/misplaced in the icon only one. I think you'll want to follow Button's styles, and have a center alignment for iconOnly.
Screenshot 2025-01-31 at 7 20 12 am

@yihuiliao yihuiliao changed the title fix: top/left align icon in s2 badge (wip) fix: top/left align icon in s2 badge Jan 30, 2025
@rspbot
Copy link

rspbot commented Jan 30, 2025

@yihuiliao yihuiliao changed the title (wip) fix: top/left align icon in s2 badge fix: top/left align icon in s2 badge Jan 30, 2025
Copy link
Member

@ktabors ktabors left a comment

Choose a reason for hiding this comment

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

Icon only seems to position the icon too high. (and XL might reveal the cause.)
image
image

@snowystinger
Copy link
Member

@ktabors looks fine to me, can you check your cache?
Screenshot 2025-01-31 at 10 46 16 am

@yihuiliao
Copy link
Member Author

yihuiliao commented Jan 31, 2025

Icon only seems to position the icon too high. (and XL might reveal the cause.)

also seems fine to me. tried it with the other variants too. you might have been on the older storybook link?

@yihuiliao yihuiliao added this pull request to the merge queue Jan 31, 2025
Merged via the queue into main with commit b86dc20 Jan 31, 2025
31 checks passed
@yihuiliao yihuiliao deleted the fix-s2-badge-icon-placement branch January 31, 2025 00:25
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.

5 participants