-
Notifications
You must be signed in to change notification settings - Fork 616
Button API alignment #2893
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
Merged
Merged
Button API alignment #2893
Changes from all commits
Commits
Show all changes
36 commits
Select commit
Hold shift + click to select a range
c5d5d5d
copy from other pr
langermank ce151b7
snippy snaps
langermank b09569d
Create .changeset/flat-onions-sort.md
langermank fa46713
color swaps
langermank e883481
Merge branch 'button-api-breaking-changes' of https://github.com/prim…
langermank 24960bb
snappy snips
langermank df4ca84
add missing type
langermank cff1ce8
Merge branch 'main' into button-api-breaking-changes
broccolinisoup 526cdf1
use the correct prop for ActionMenu.Button
broccolinisoup 90f8241
Merge branch 'main' into button-api-breaking-changes
broccolinisoup 9925d0c
type fixes
broccolinisoup 1b28ee6
Merge branch 'main' into button-api-breaking-changes
broccolinisoup d189074
Merge branch 'main' of https://github.com/primer/react into button-ap…
langermank 333deb5
fix docs
langermank 32217f1
snaps
langermank b9b9a0e
Update flat-onions-sort.md
langermank 43d1226
Merge branch 'next-major' into button-api-breaking-changes
langermank f5b93c8
fix merge conflict?
langermank 8d2fea3
change to count prop
langermank 2068339
Merge branch 'next-major' into button-api-breaking-changes
broccolinisoup 43a7649
remove Button.Counter in favor of count prop
broccolinisoup 6e555d8
Merge branch 'next-major' into button-api-breaking-changes
broccolinisoup d32f2cc
Hoping to revert some unnecessary snaps diff
broccolinisoup ad7a6e8
update Button.Counter to use count prop
broccolinisoup e5b9201
update changeset and remove outine button examples from the story
broccolinisoup 1a4db9c
Update generated/components.json
broccolinisoup f53c55a
Merge branch 'next-major' into button-api-breaking-changes
broccolinisoup acdd42d
test: remove outline tests
joshblack f9bbce7
Merge branch 'next-major' into button-api-breaking-changes
broccolinisoup ea92994
Merge branch 'next-major' into button-api-breaking-changes
joshblack de0facf
test(e2e): remove outline tests
joshblack fd99baf
test(e2e): remove outdated snapshots
joshblack 761b226
Merge branch 'next-major' into button-api-breaking-changes
joshblack e138704
test(vrt): update snapshots
joshblack 7b9586d
fix stories, fix count and trailing vis conflict
langermank de3dc1c
test(vrt): update snapshots
langermank File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
--- | ||
"@primer/react": major | ||
--- | ||
|
||
- Changes `leadingIcon` and `trailingIcon` to `leadingVisual` and `trailingVisual` | ||
- Removes `Button.Counter` as a child component, replacing it with a `count` prop. This change allows us to use the `trailingVisual` slot for counters. | ||
- Removes the `outline` button variant as we wish to only support `invisible` buttons. |
Binary file modified
BIN
+35 Bytes
(100%)
....test.ts-snapshots/ActionMenu-Groups-And-Descriptions-dark-colorblind-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+28 Bytes
(100%)
...Menu.test.ts-snapshots/ActionMenu-Groups-And-Descriptions-dark-dimmed-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+25 Bytes
(100%)
...st.ts-snapshots/ActionMenu-Groups-And-Descriptions-dark-high-contrast-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+36 Bytes
(100%)
.../ActionMenu.test.ts-snapshots/ActionMenu-Groups-And-Descriptions-dark-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+35 Bytes
(100%)
....test.ts-snapshots/ActionMenu-Groups-And-Descriptions-dark-tritanopia-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+15 Bytes
(100%)
...test.ts-snapshots/ActionMenu-Groups-And-Descriptions-light-colorblind-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
-12 Bytes
(100%)
...t.ts-snapshots/ActionMenu-Groups-And-Descriptions-light-high-contrast-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
-4 Bytes
(100%)
...ActionMenu.test.ts-snapshots/ActionMenu-Groups-And-Descriptions-light-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+15 Bytes
(100%)
...test.ts-snapshots/ActionMenu-Groups-And-Descriptions-light-tritanopia-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+810 Bytes
(110%)
...ts/Button.test.ts-snapshots/Button-Invisible-Variants-dark-colorblind-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+866 Bytes
(110%)
...onents/Button.test.ts-snapshots/Button-Invisible-Variants-dark-dimmed-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+547 Bytes
(100%)
...Button.test.ts-snapshots/Button-Invisible-Variants-dark-high-contrast-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+789 Bytes
(110%)
...ts/components/Button.test.ts-snapshots/Button-Invisible-Variants-dark-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+810 Bytes
(110%)
...ts/Button.test.ts-snapshots/Button-Invisible-Variants-dark-tritanopia-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+790 Bytes
(110%)
...s/Button.test.ts-snapshots/Button-Invisible-Variants-light-colorblind-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+522 Bytes
(100%)
...utton.test.ts-snapshots/Button-Invisible-Variants-light-high-contrast-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+759 Bytes
(110%)
...s/components/Button.test.ts-snapshots/Button-Invisible-Variants-light-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified
BIN
+790 Bytes
(110%)
...s/Button.test.ts-snapshots/Button-Invisible-Variants-light-tritanopia-linux.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed
BIN
-6.17 KB
...ts/components/Button.test.ts-snapshots/Button-Outline-dark-colorblind-linux.png
Binary file not shown.
Binary file removed
BIN
-6.11 KB
...pshots/components/Button.test.ts-snapshots/Button-Outline-dark-dimmed-linux.png
Binary file not shown.
Binary file removed
BIN
-6.18 KB
...components/Button.test.ts-snapshots/Button-Outline-dark-high-contrast-linux.png
Binary file not shown.
Binary file removed
BIN
-6.17 KB
...ght/snapshots/components/Button.test.ts-snapshots/Button-Outline-dark-linux.png
Binary file not shown.
Binary file removed
BIN
-6.17 KB
...ts/components/Button.test.ts-snapshots/Button-Outline-dark-tritanopia-linux.png
Binary file not shown.
Binary file removed
BIN
-6.18 KB
...s/components/Button.test.ts-snapshots/Button-Outline-light-colorblind-linux.png
Binary file not shown.
Binary file removed
BIN
-6.29 KB
...omponents/Button.test.ts-snapshots/Button-Outline-light-high-contrast-linux.png
Binary file not shown.
Binary file removed
BIN
-6.18 KB
...ht/snapshots/components/Button.test.ts-snapshots/Button-Outline-light-linux.png
Diff not rendered.
Binary file removed
BIN
-6.18 KB
...s/components/Button.test.ts-snapshots/Button-Outline-light-tritanopia-linux.png
Diff not rendered.
Binary file modified
BIN
-207 Bytes
(97%)
...components/Button.test.ts-snapshots/Button-Playground-dark-colorblind-linux.png
Oops, something went wrong.
Binary file modified
BIN
-247 Bytes
(96%)
...ots/components/Button.test.ts-snapshots/Button-Playground-dark-dimmed-linux.png
Oops, something went wrong.
Binary file modified
BIN
-210 Bytes
(97%)
...ponents/Button.test.ts-snapshots/Button-Playground-dark-high-contrast-linux.png
Oops, something went wrong.
Binary file modified
BIN
-207 Bytes
(97%)
.../snapshots/components/Button.test.ts-snapshots/Button-Playground-dark-linux.png
Oops, something went wrong.
Binary file modified
BIN
-207 Bytes
(97%)
...components/Button.test.ts-snapshots/Button-Playground-dark-tritanopia-linux.png
Oops, something went wrong.
Binary file modified
BIN
-212 Bytes
(97%)
...omponents/Button.test.ts-snapshots/Button-Playground-light-colorblind-linux.png
Oops, something went wrong.
Binary file modified
BIN
-196 Bytes
(97%)
...onents/Button.test.ts-snapshots/Button-Playground-light-high-contrast-linux.png
Oops, something went wrong.
Binary file modified
BIN
-213 Bytes
(97%)
...snapshots/components/Button.test.ts-snapshots/Button-Playground-light-linux.png
Oops, something went wrong.
Binary file modified
BIN
-212 Bytes
(97%)
...omponents/Button.test.ts-snapshots/Button-Playground-light-tritanopia-linux.png
Oops, something went wrong.
Binary file modified
BIN
-8 Bytes
(100%)
...ts/Button.test.ts-snapshots/Button-Trailing-Visual-dark-high-contrast-linux.png
Oops, something went wrong.
Binary file modified
BIN
-12 Bytes
(100%)
...s/Button.test.ts-snapshots/Button-Trailing-Visual-light-high-contrast-linux.png
Oops, something went wrong.
Binary file modified
BIN
+1.93 KB
(110%)
...ts/components/Button.test.ts-snapshots/Button-sx-prop-dark-colorblind-linux.png
Oops, something went wrong.
Binary file modified
BIN
+1.84 KB
(110%)
...pshots/components/Button.test.ts-snapshots/Button-sx-prop-dark-dimmed-linux.png
Oops, something went wrong.
Binary file modified
BIN
+1.89 KB
(110%)
...components/Button.test.ts-snapshots/Button-sx-prop-dark-high-contrast-linux.png
Oops, something went wrong.
Binary file modified
BIN
+1.9 KB
(110%)
...ght/snapshots/components/Button.test.ts-snapshots/Button-sx-prop-dark-linux.png
Oops, something went wrong.
Binary file modified
BIN
+1.93 KB
(110%)
...ts/components/Button.test.ts-snapshots/Button-sx-prop-dark-tritanopia-linux.png
Oops, something went wrong.
Binary file modified
BIN
+1.86 KB
(110%)
...s/components/Button.test.ts-snapshots/Button-sx-prop-light-colorblind-linux.png
Oops, something went wrong.
Binary file modified
BIN
+1.88 KB
(110%)
...omponents/Button.test.ts-snapshots/Button-sx-prop-light-high-contrast-linux.png
Oops, something went wrong.
Binary file modified
BIN
+1.86 KB
(110%)
...ht/snapshots/components/Button.test.ts-snapshots/Button-sx-prop-light-linux.png
Oops, something went wrong.
Binary file modified
BIN
+1.86 KB
(110%)
...s/components/Button.test.ts-snapshots/Button-sx-prop-light-tritanopia-linux.png
Oops, something went wrong.
Binary file removed
BIN
-6.29 KB
...nents/LinkButton.test.ts-snapshots/LinkButton-Outline-dark-colorblind-linux.png
Diff not rendered.
Binary file removed
BIN
-6.22 KB
...omponents/LinkButton.test.ts-snapshots/LinkButton-Outline-dark-dimmed-linux.png
Diff not rendered.
Binary file removed
BIN
-6.3 KB
...ts/LinkButton.test.ts-snapshots/LinkButton-Outline-dark-high-contrast-linux.png
Diff not rendered.
Binary file removed
BIN
-6.29 KB
...shots/components/LinkButton.test.ts-snapshots/LinkButton-Outline-dark-linux.png
Diff not rendered.
Binary file removed
BIN
-6.29 KB
...nents/LinkButton.test.ts-snapshots/LinkButton-Outline-dark-tritanopia-linux.png
Diff not rendered.
Binary file removed
BIN
-6.25 KB
...ents/LinkButton.test.ts-snapshots/LinkButton-Outline-light-colorblind-linux.png
Diff not rendered.
Binary file removed
BIN
-6.34 KB
...s/LinkButton.test.ts-snapshots/LinkButton-Outline-light-high-contrast-linux.png
Diff not rendered.
Binary file removed
BIN
-6.25 KB
...hots/components/LinkButton.test.ts-snapshots/LinkButton-Outline-light-linux.png
Diff not rendered.
Binary file removed
BIN
-6.25 KB
...ents/LinkButton.test.ts-snapshots/LinkButton-Outline-light-tritanopia-linux.png
Diff not rendered.
Binary file modified
BIN
-8 Bytes
(100%)
...utton.test.ts-snapshots/LinkButton-Trailing-Visual-dark-high-contrast-linux.png
Oops, something went wrong.
Binary file modified
BIN
-12 Bytes
(100%)
...tton.test.ts-snapshots/LinkButton-Trailing-Visual-light-high-contrast-linux.png
Oops, something went wrong.
Binary file modified
BIN
-31 Bytes
(100%)
.../PageHeader.test.ts-snapshots/PageHeader-With-Actions-dark-colorblind-linux.png
Oops, something went wrong.
Binary file modified
BIN
-16 Bytes
(100%)
...ents/PageHeader.test.ts-snapshots/PageHeader-With-Actions-dark-dimmed-linux.png
Oops, something went wrong.
Binary file modified
BIN
+95 Bytes
(100%)
...geHeader.test.ts-snapshots/PageHeader-With-Actions-dark-high-contrast-linux.png
Oops, something went wrong.
Binary file modified
BIN
-5 Bytes
(100%)
.../components/PageHeader.test.ts-snapshots/PageHeader-With-Actions-dark-linux.png
Oops, something went wrong.
Binary file modified
BIN
-31 Bytes
(100%)
.../PageHeader.test.ts-snapshots/PageHeader-With-Actions-dark-tritanopia-linux.png
Oops, something went wrong.
Binary file modified
BIN
+1 Byte
(100%)
...PageHeader.test.ts-snapshots/PageHeader-With-Actions-light-colorblind-linux.png
Oops, something went wrong.
Binary file modified
BIN
-17 Bytes
(100%)
...eHeader.test.ts-snapshots/PageHeader-With-Actions-light-high-contrast-linux.png
Oops, something went wrong.
Binary file modified
BIN
-29 Bytes
(100%)
...components/PageHeader.test.ts-snapshots/PageHeader-With-Actions-light-linux.png
Oops, something went wrong.
Binary file modified
BIN
+1 Byte
(100%)
...PageHeader.test.ts-snapshots/PageHeader-With-Actions-light-tritanopia-linux.png
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.