Skip to content

Commit

Permalink
feat(styles): synced Link component (#1675)
Browse files Browse the repository at this point in the history
* fix: synced Link styles

* fix: updated screenshots

* fix: addressed comments

* fix: missed dash

* feat: updated `font-weight` for button link to be aligned with link

* Update packages/react/src/components/Link/index.css

Co-authored-by: Jason <jason@scurker.com>

* fix: changed font-weight for buttons

---------

Co-authored-by: Jason <jason@scurker.com>
  • Loading branch information
orest-s and scurker committed Sep 19, 2024
1 parent e1e6898 commit 8ff3885
Show file tree
Hide file tree
Showing 8 changed files with 12 additions and 9 deletions.
Binary file modified e2e/screenshots/button-variant-link-.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 e2e/screenshots/dark--button-variant-link-.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 e2e/screenshots/dark--link.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 e2e/screenshots/link.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 6 additions & 0 deletions packages/react/src/components/Link/index.css
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
a.Button--primary,
a.Button--secondary,
a.Button--thin {
font-weight: var(--font-weight-medium);
}

a.Button--primary,
a.Button--secondary {
text-decoration: none;
Expand Down
1 change: 0 additions & 1 deletion packages/styles/base.css
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,6 @@ button,

a {
color: var(--link-text-color);
font-weight: var(--font-weight-medium);
}

p {
Expand Down
1 change: 1 addition & 0 deletions packages/styles/button.css
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@
button.Link {
cursor: pointer;
font-size: inherit;
font-weight: var(--font-weight-normal);
}

.Button--primary:focus,
Expand Down
13 changes: 5 additions & 8 deletions packages/styles/link.css
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,6 @@
.Link {
text-decoration: underline;
color: var(--link-text-color);
font-weight: var(--font-weight-medium);
display: inline-block;
padding: var(--space-quarter);
background: transparent;
vertical-align: baseline;
Expand All @@ -29,10 +27,9 @@
outline-offset: 0;
}

p .Link {
margin: 0 2px;
display: inline;
text-decoration: underline;
color: var(--link-text-color);
font-weight: var(--font-weight-normal);
.Link:has(.Icon) {
display: inline-flex;
align-items: center;
gap: var(--space-half);
flex-wrap: wrap;
}

0 comments on commit 8ff3885

Please sign in to comment.