Skip to content

feat: extra small buttons #19435

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

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

asfordmatt
Copy link
Member

@asfordmatt asfordmatt commented May 20, 2025

Closes #19423

Adds support for a new "xs" button size (24px)

Changelog

New

  • Button size prop now supports a value of "xs" for Extra Small (24px)

Testing / Reviewing

Storybook (React & Web Components)

PR Checklist

As the author of this PR, before marking ready for review, confirm you:

  • Reviewed every line of the diff
  • Updated documentation and storybook examples
  • Wrote passing tests that cover this change
  • Addressed any impact on accessibility (a11y)
  • Tested for cross-browser consistency
  • Validated that this code is ready for review and status checks should pass

More details can be found in the pull request guide

@asfordmatt asfordmatt requested review from a team as code owners May 20, 2025 16:16
Copy link
Contributor

github-actions bot commented May 20, 2025

All contributors have signed the DCO.
Posted by the DCO Assistant Lite bot.

@asfordmatt
Copy link
Member Author

I have read the DCO document and I hereby sign the DCO.

@asfordmatt
Copy link
Member Author

recheck

Copy link

netlify bot commented May 20, 2025

Deploy Preview for v11-carbon-web-components ready!

Name Link
🔨 Latest commit 45b7f17
🔍 Latest deploy log https://app.netlify.com/projects/v11-carbon-web-components/deploys/682caad738dd520008715ed1
😎 Deploy Preview https://deploy-preview-19435--v11-carbon-web-components.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

Copy link

netlify bot commented May 20, 2025

Deploy Preview for v11-carbon-web-components ready!

Name Link
🔨 Latest commit a1fabbb
🔍 Latest deploy log https://app.netlify.com/projects/v11-carbon-web-components/deploys/682caae6713c60000843c48a
😎 Deploy Preview https://deploy-preview-19435--v11-carbon-web-components.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

Copy link

netlify bot commented May 20, 2025

Deploy Preview for v11-carbon-react ready!

Built without sensitive environment variables

Name Link
🔨 Latest commit 45b7f17
🔍 Latest deploy log https://app.netlify.com/projects/v11-carbon-react/deploys/682caad78ae8c30008e1124e
😎 Deploy Preview https://deploy-preview-19435--v11-carbon-react.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

Copy link

netlify bot commented May 20, 2025

Deploy Preview for v11-carbon-react ready!

Built without sensitive environment variables

Name Link
🔨 Latest commit a1fabbb
🔍 Latest deploy log https://app.netlify.com/projects/v11-carbon-react/deploys/682caae6d376910008ebfe13
😎 Deploy Preview https://deploy-preview-19435--v11-carbon-react.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

Copy link

codecov bot commented May 20, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 84.87%. Comparing base (66f151d) to head (a1fabbb).
Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main   #19435   +/-   ##
=======================================
  Coverage   84.87%   84.87%           
=======================================
  Files         372      372           
  Lines       14430    14431    +1     
  Branches     4694     4695    +1     
=======================================
+ Hits        12247    12248    +1     
  Misses       2037     2037           
  Partials      146      146           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@alisonjoseph alisonjoseph requested review from a team and laurenmrice and removed request for a team May 20, 2025 17:04
@@ -150,7 +150,7 @@ export interface IconButtonProps
/**
* Specify the size of the Button.
*/
size?: Extract<ButtonSize, 'sm' | 'md' | 'lg'>;
size?: Extract<ButtonSize, 'xs' | 'sm' | 'md' | 'lg'>;
Copy link
Contributor

Choose a reason for hiding this comment

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

The accessibility task isn't marked as completed in #19435 (comment). Do xs IconButtons meet https://www.ibm.com/able/requirements/requirements/?version=v7_3#2_5_8?

Copy link
Member Author

@asfordmatt asfordmatt May 21, 2025

Choose a reason for hiding this comment

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

Yes, xs icon buttons are 24 x 24 pixels, so just meet accessibility requirements

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Feature Request]: 24px button variant.
3 participants