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(Button): make children prop optional #3661

Merged
merged 6 commits into from
Sep 7, 2023

Conversation

joshblack
Copy link
Member

@joshblack joshblack commented Aug 23, 2023

Closes https://github.com/github/primer/issues/2601

Update our base ButtonProps so that children is optional. This allows for the following migration pattern to be supported for v36:

// Before
<Button leadingIcon={ChatIcon}>
  <Button.Counter>{5}</Button.Counter>
</Button>

// After
<Button leadingAction={ChatIcon} count={5} />

@joshblack joshblack requested review from a team and mperrotti August 23, 2023 20:25
@changeset-bot
Copy link

changeset-bot bot commented Aug 23, 2023

🦋 Changeset detected

Latest commit: 6f0270a

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@primer/react Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@github-actions
Copy link
Contributor

github-actions bot commented Aug 23, 2023

size-limit report 📦

Path Size
dist/browser.esm.js 100.69 KB (0%)
dist/browser.umd.js 101.27 KB (0%)

@github-actions github-actions bot temporarily deployed to storybook-preview-3661 August 23, 2023 20:31 Inactive
@joshblack joshblack temporarily deployed to github-pages August 23, 2023 20:31 — with GitHub Actions Inactive
@github-actions github-actions bot temporarily deployed to storybook-preview-3661 August 23, 2023 20:32 Inactive
@joshblack joshblack temporarily deployed to github-pages September 6, 2023 20:25 — with GitHub Actions Inactive
@github-actions github-actions bot temporarily deployed to storybook-preview-3661 September 6, 2023 20:26 Inactive
Copy link
Member

@broccolinisoup broccolinisoup left a comment

Choose a reason for hiding this comment

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

🚀

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.

3 participants