Skip to content

Conversation

@liuliu-dev
Copy link
Contributor

@liuliu-dev liuliu-dev commented Aug 27, 2025

Removes support for the sx prop from the RadioGroup component

  • RadioGroup: Removed SxProp and replace sx in Banner.examples.stories that uses RadioGroup
  • Migrates the Truncate component away from BoxWithFallback components and sx prop support to use CSS modules

Note:

Screenshot 2025-09-15 at 4 17 52 PM
  • Multiple repos are using Truncate with sx props including github/github-ui, need to update the import in github/github-ui, wait until this change is in to update the export pattens.
Screenshot 2025-09-15 at 4 18 26 PM
  • Major release; if selected, include a written rollout or migration plan

@changeset-bot
Copy link

changeset-bot bot commented Aug 27, 2025

🦋 Changeset detected

Latest commit: 90be68b

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

This PR includes changesets to release 2 packages
Name Type
@primer/react Major
@primer/styled-react Major

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 github-actions bot added the integration-tests: recommended This change needs to be tested for breaking changes. See https://arc.net/l/quote/tdmpakpm label Aug 27, 2025
@github-actions
Copy link
Contributor

👋 Hi, this pull request contains changes to the source code that github/github depends on. If you are GitHub staff, we recommend testing these changes with github/github using the integration workflow. Thanks!

@liuliu-dev liuliu-dev requested a review from joshblack August 27, 2025 22:27
@github-actions github-actions bot requested a deployment to storybook-preview-6685 August 27, 2025 22:30 Abandoned
@github-actions github-actions bot temporarily deployed to storybook-preview-6685 August 27, 2025 22:38 Inactive
@github-actions
Copy link
Contributor

github-actions bot commented Aug 27, 2025

size-limit report 📦

Path Size
packages/react/dist/browser.esm.js 89.81 KB (+0.07% 🔺)
packages/react/dist/browser.umd.js 89.9 KB (+0.02% 🔺)

@github-actions
Copy link
Contributor

Uh oh! @liuliu-dev, at least one image you shared is missing helpful alt text. Check your pull request body to fix the following violations:

  • Images should have meaningful alternative text (alt text) at line 10
  • Images should have meaningful alternative text (alt text) at line 14

Alt text is an invisible description that helps screen readers describe images to blind or low-vision users. If you are using markdown to display images, add your alt text inside the brackets of the markdown image.

Learn more about alt text at Basic writing and formatting syntax: images on GitHub Docs.

🤖 Beep boop! This comment was added automatically by github/accessibility-alt-text-bot.

@github-actions github-actions bot temporarily deployed to storybook-preview-6685 September 15, 2025 23:23 Inactive
@github-actions github-actions bot removed the integration-tests: recommended This change needs to be tested for breaking changes. See https://arc.net/l/quote/tdmpakpm label Sep 15, 2025
@github-actions github-actions bot temporarily deployed to storybook-preview-6685 September 16, 2025 17:30 Inactive
@github-actions github-actions bot added integration-tests: passing Changes in this PR do NOT cause breaking changes in gh/gh and removed integration-tests: failing Changes in this PR cause breaking changes in gh/gh labels Sep 16, 2025
@liuliu-dev liuliu-dev marked this pull request as ready for review September 16, 2025 18:01
@liuliu-dev liuliu-dev requested a review from a team as a code owner September 16, 2025 18:01
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR removes the sx prop support from the RadioGroup and Truncate components as part of migrating away from styled-components to CSS modules. The changes ensure backward compatibility by maintaining sx support in the styled-react package while removing it from the core components.

  • Removes sx prop from RadioGroup and Truncate components in the main package
  • Adds wrapper components in styled-react package to maintain backward compatibility
  • Migrates Truncate from BoxWithFallback to native React components with CSS modules

Reviewed Changes

Copilot reviewed 11 out of 11 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
packages/styled-react/src/index.tsx Adds wrapper components for RadioGroup and Truncate that restore sx prop support for backward compatibility
packages/react/src/index.ts Exports RadioGroupProps type for external usage
packages/react/src/Truncate/Truncate.tsx Removes sx prop and BoxWithFallback dependency, migrates to CSS modules
packages/react/src/RadioGroup/RadioGroup.tsx Removes sx prop from RadioGroupProps type definition
packages/react/src/Banner/Banner.examples.stories.tsx Replaces sx prop usage with CSS module class
packages/react/src/ActionList/Description.tsx Removes sx prop usage from Truncate component

@github-actions
Copy link
Contributor

👋 Hi, there are new commits since the last successful integration test. We recommend running the integration workflow once more, unless you are sure the new changes do not affect github/github. Thanks!

@github-actions github-actions bot added the integration-tests: recommended This change needs to be tested for breaking changes. See https://arc.net/l/quote/tdmpakpm label Sep 17, 2025
@github-actions github-actions bot temporarily deployed to storybook-preview-6685 September 17, 2025 18:58 Inactive
@github-actions github-actions bot removed the integration-tests: recommended This change needs to be tested for breaking changes. See https://arc.net/l/quote/tdmpakpm label Sep 17, 2025
@github-actions
Copy link
Contributor

👋 Hi, there are new commits since the last successful integration test. We recommend running the integration workflow once more, unless you are sure the new changes do not affect github/github. Thanks!

@github-actions github-actions bot added integration-tests: recommended This change needs to be tested for breaking changes. See https://arc.net/l/quote/tdmpakpm and removed integration-tests: recommended This change needs to be tested for breaking changes. See https://arc.net/l/quote/tdmpakpm labels Sep 22, 2025
@primer-integration
Copy link

👋 Hi from github/github-ui! Your integration PR is ready: https://github.com/github/github-ui/pull/3014

@primer-integration
Copy link

🟢 ci completed with status success.

@liuliu-dev liuliu-dev added this pull request to the merge queue Sep 22, 2025
Merged via the queue into main with commit 00261c9 Sep 22, 2025
43 checks passed
@liuliu-dev liuliu-dev deleted the liuliu/remove-sx-from-RadioGroup-and-Truncate branch September 22, 2025 19:03
@primer primer bot mentioned this pull request Sep 22, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

integration-tests: passing Changes in this PR do NOT cause breaking changes in gh/gh

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants