react icon indicating copy to clipboard operation
react copied to clipboard

Button content grid cells are equal

Open dusave opened this issue 3 years ago • 2 comments

Describe the bug With version 35.x, Buttons have a new content grid, containing spots for leading and trailing icons along with the content of the button. The issue is that the columns are all 1fr by default, giving much more space to the icon cells than they need whilst compressing the content cell.

To Reproduce Steps to reproduce the behavior:

  1. Create a button with leading and/or trailing icons, along with content
  2. See error
image

Expected behavior Grid cells should be gridTemplateColumns: "min-content 1fr min-content" image

dusave avatar Mar 17 '22 19:03 dusave

Hi! This issue has been marked as stale because it has been open with no activity for 180 days. You can comment on the issue or remove the stale label to keep it open. If you do nothing, this issue will be closed in 7 days.

github-actions[bot] avatar Sep 13 '22 20:09 github-actions[bot]

Hey @dusave, I'm so sorry we didn't get back to you on this much sooner! Apologies 🙏🏻

Are you able to confirm this is still a problem?

lesliecdubs avatar Sep 14 '22 04:09 lesliecdubs

Update, @langermank is working on resolving this right now 🎉

tallys avatar Oct 03 '22 16:10 tallys

Noting that the linked PR includes breaking changes, so we'd schedule them to go out with the next major release.

@joshblack noted there may be some changes we could pull out of this PR to release as non-breaking. cc @langermank

lesliecdubs avatar Nov 07 '22 22:11 lesliecdubs

Addressed here https://github.com/primer/react/pull/2792

langermank avatar Feb 02 '23 20:02 langermank