Repository navigation
feat(Stack): support balanced wrapping - #8692
Conversation
🦋 Changeset detectedLatest commit: 9063ce2 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 |
|
|
Integration test results from github/github-ui PR: |
There was a problem hiding this comment.
🟢 Approval recommended
No active review issues are reported for the Stack balanced-wrapping addition.
No open issues 🎉
What changed in this PR
Adds balance to Primer React’s Stack wrap prop, including responsive values, with ordinary wrapping as a fallback for browsers that do not support balanced flex wrapping.
Changes:
- Extends the wrap type and CSS rules across all supported breakpoints.
- Updates Storybook controls, API metadata, and attribute tests for the new value.
- Adds a minor-release changeset for
@primer/react.
| File | Description |
|---|---|
packages/react/src/Stack/Stack.tsx |
Adds balance to the supported wrap values. |
packages/react/src/Stack/Stack.stories.tsx |
Exposes balance in base and responsive controls. |
packages/react/src/Stack/Stack.module.css |
Adds balanced wrapping rules with wrap fallbacks. |
packages/react/src/Stack/Stack.docs.json |
Documents the expanded wrap type. |
packages/react/src/Stack/__tests__/Stack.test.tsx |
Checks base and responsive balance attributes. |
.changeset/stack-balanced-wrap.md |
Records the new API option as a minor release. |
Review effort: Balanced
|
One or more custom setup steps configured for this repository failed during this Copilot code review run: Setup steps run before each review. If the review above is missing context, or no review was posted at all, the failing step above may be the cause. See the workflow run for failure details, fix your setup steps configuration, and re-request a review. Note You can configure setup steps for Copilot code review separately from Copilot cloud agent with a |
No linked issue.
Adds CSS Flexbox
balanceas a supported value for Stack'swrapprop, including responsive values and Storybook controls.Changelog
New
balanceas a value for thewrapprop.Changed
Removed
Rollout strategy
Testing & Reviewing
npm test Stack— passed (43 passed, 1 todo).npm run type-check— passed.npm run lint:css— passed.npm run format:diff— passed.flex-wrap: balance; CSS includes awrapfallback.