Skip to content
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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor(Stack): write to single custom property for gap changes #4589

Merged
merged 7 commits into from
May 22, 2024

Conversation

joshblack
Copy link
Member

Closes #4587

Update the strategy for setting gap in Stack to use a single custom property, --stack-gap, that is written to a stack gap value (e.g. --stack-gap-normal). This is an attempt at refactoring this code so that we are writing to this value across breakpoints so that tracing down why something is happening at a breakpoint is only one jump (finding where the property is set) instead of two jumps (finding the variable for the breakpoint, finding the value that is being set for it). Curious to hear if this approach seems more clear if they are the same 馃憖

Changelog

New

Changed

  • Update how gap is set on Stack
  • Address gap issues on larger breakpoints

Removed

Rollout strategy

  • Patch release

Testing & Reviewing

  • Verify that gap is being set correct across breakpoints, for example if none is set then it should be none across breakpoints

Copy link

changeset-bot bot commented May 13, 2024

馃 Changeset detected

Latest commit: c902c03

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

This PR includes changesets to release 1 package
Name Type
@primer/react Patch

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

Copy link
Contributor

github-actions bot commented May 13, 2024

size-limit report 馃摝

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

@joshblack joshblack requested a review from langermank May 13, 2024 19:03
@joshblack joshblack marked this pull request as ready for review May 13, 2024 19:03
@joshblack joshblack requested a review from a team as a code owner May 13, 2024 19:03
@joshblack joshblack requested a deployment to github-pages May 13, 2024 19:06 — with GitHub Actions Abandoned
@github-actions github-actions bot temporarily deployed to storybook-preview-4589 May 13, 2024 19:06 Inactive
@joshblack
Copy link
Member Author

bump @langermank when you get a sec 馃憖

Copy link
Contributor

@langermank langermank left a comment

Choose a reason for hiding this comment

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

馃殌

@joshblack joshblack added this pull request to the merge queue May 22, 2024
Merged via the queue into main with commit ed701be May 22, 2024
30 checks passed
@joshblack joshblack deleted the fix/update-gap-stack branch May 22, 2024 20:30
@primer primer bot mentioned this pull request May 22, 2024
khiga8 pushed a commit that referenced this pull request May 31, 2024
* refactor(Stack): write to single custom property for gap changes

* chore: add changeset

* test: update style test

* refactor(Stack): use primitive tokens directly with fallback value

* test(Stack): update test with new fallback in custom property

---------

Co-authored-by: Josh Black <joshblack@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Stack gap is overridden on wider layouts
2 participants