Uh oh!
There was an error while loading. Please reload this page.
chore(DataTable.Pagination): Convert DataTable.Pagination to CSS modules - #6273
Conversation
🦋 Changeset detectedLatest commit: 90e70cc The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
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 |
👋 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! |
size-limit report 📦
|
👋 Hi from github/github! Your integration PR is ready: https://github.com/github/github/pull/388357 |
There was a problem hiding this comment.
Pull Request Overview
This PR converts the styling of the DataTable.Pagination component (and the internal ButtonReset component) from styled-components to CSS modules.
- Replaces the styled-components-based
ButtonResetwith a functional component that applies a CSS module andclsx. - Migrates all pagination-related styles in
DataTable.Paginationto a CSS module, replacingStyledPaginationand scoped class names. - Adds a changeset entry for a minor release.
Reviewed Changes
Copilot reviewed 3 out of 5 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| packages/react/src/internal/components/ButtonReset.tsx | Replaced styled-components with ButtonReset.module.css and a functional component. |
| packages/react/src/DataTable/Pagination.tsx | Swapped out StyledPagination and inline styles for Pagination.module.css + clsx. |
| .changeset/polite-pandas-tie.md | Added changeset marking the minor version bump for this chore. |
Files not reviewed (2)
- packages/react/src/DataTable/Pagination.module.css: Language not supported
- packages/react/src/internal/components/ButtonReset.module.css: Language not supported
Comments suppressed due to low confidence (1)
packages/react/src/internal/components/ButtonReset.tsx:11
- Missing import of React for using
React.PropsWithChildrenandReact.ButtonHTMLAttributes. Please addimport type React from 'react'at the top.
}: React.PropsWithChildren & React.ButtonHTMLAttributes<HTMLButtonElement>) => {
Uh oh!
There was an error while loading. Please reload this page.
🟢 golden-jobs completed with status |
joshblack
left a comment
There was a problem hiding this comment.
Just one suggestion for the ButtonReset but otherwise LGTM 👍
Uh oh!
There was an error while loading. Please reload this page.
| border-end-end-radius: var(--borderRadius-medium); | ||
| } | ||
| @media ((max-width: calc(768px - 0.02px))) { |
There was a problem hiding this comment.
Completely separate from the refactor, would this be something we would ever want a container query for now that we can use them or is this best tied to the viewport range? (Was just curious)
There was a problem hiding this comment.
Yes I think this was a bit verbose and would love either media query variables here or container queries.
Co-authored-by: Josh Black <joshblack@github.com>
👋 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! |
👋 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! |
👋 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! |
Uh oh!
There was an error while loading. Please reload this page.
👋 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! |
…les (#6273) Co-authored-by: Josh Black <joshblack@github.com> Co-authored-by: primer[bot] <119360173+primer[bot]@users.noreply.github.com>
This converts the
DataTable.Paginationcomponent to CSS modules. This was overlooked in the original migration.Changelog
New
Changed
Converts styled-component styling to CSS modules.
Removed
Rollout strategy
Testing & Reviewing
Merge checklist