Skip to content

Update Textarea stories to no longer use styled-components #6513

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 8 commits into
base: main
Choose a base branch
from

Conversation

llastflowers
Copy link
Contributor

Closes https://github.com/github/primer/issues/5639
Closes https://github.com/github/primer/issues/5640
Closes https://github.com/github/primer/issues/5641

Changelog

New

Added new CSS module

Changed

Changed Textarea.stories.tsx and Textarea.dev.stories.tsx and Textarea.features.stories.tsx to no longer use styled-components

Removed

Removed anything associated with styled-components

Rollout strategy

  • Patch release
  • Minor release
  • Major release; if selected, include a written rollout or migration plan
  • None; if selected, include a brief description as to why

Testing & Reviewing

Merge checklist

@llastflowers llastflowers self-assigned this Aug 7, 2025
@llastflowers llastflowers added skip changeset This change does not need a changelog integration-tests: skipped manually Changes in this PR do not require an integration test labels Aug 7, 2025

This comment was marked as resolved.

Copy link
Contributor

github-actions bot commented Aug 7, 2025

size-limit report 📦

Path Size
packages/react/dist/browser.esm.js 90.2 KB (0%)
packages/react/dist/browser.umd.js 90.38 KB (0%)

@github-actions github-actions bot temporarily deployed to storybook-preview-6513 August 7, 2025 20:23 Inactive
@llastflowers llastflowers changed the title Llastflowers/5639 5641/no sc textarea stories Update Textarea stories to no longer use styled-components Aug 7, 2025
@github-actions github-actions bot temporarily deployed to storybook-preview-6513 August 7, 2025 20:51 Inactive
@llastflowers llastflowers marked this pull request as ready for review August 7, 2025 22:26
@Copilot Copilot AI review requested due to automatic review settings August 7, 2025 22:26
@llastflowers llastflowers requested review from a team as code owners August 7, 2025 22:26
@llastflowers llastflowers requested a review from mperrotti August 7, 2025 22:26
Copy link
Contributor

@Copilot 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 dependencies on styled-components from Textarea Storybook stories by replacing Box components with native HTML form elements and replacing the sx prop with CSS modules for styling.

  • Removed Box component imports and usage across three story files
  • Created a new CSS module file for custom styling previously handled by the sx prop
  • Replaced styled-components approach with native HTML elements and CSS modules

Reviewed Changes

Copilot reviewed 4 out of 8 changed files in this pull request and generated no comments.

File Description
packages/react/src/Textarea/Textarea.stories.tsx Removed Box import and replaced Box as="form" with native form elements
packages/react/src/Textarea/Textarea.features.stories.tsx Removed Box import and replaced all Box as="form" instances with native form elements
packages/react/src/Textarea/Textarea.dev.stories.tsx Removed Box import, replaced Box as="form" with form, and replaced sx prop with CSS module class
packages/react/src/Textarea/Textarea.dev.stories.module.css Added new CSS module with background color styling to replace sx prop usage

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
integration-tests: skipped manually Changes in this PR do not require an integration test skip changeset This change does not need a changelog
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants