-
Notifications
You must be signed in to change notification settings - Fork 506
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
Make sure Link is underlined when inline={true}
#4531
base: main
Are you sure you want to change the base?
Conversation
🦋 Changeset detectedLatest commit: 7088054 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 |
inline={true}
size-limit report 📦
|
text-decoration: ${props => (props.underline ? 'underline' : undefined)}; | ||
text-decoration: ${props => (props.inline ? 'underline' : undefined)}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we'll need one line otherwise the inline
value will always override, maybe something like:
text-decoration: ${props => (props.underline ? 'underline' : undefined)}; | |
text-decoration: ${props => (props.inline ? 'underline' : undefined)}; | |
text-decoration: ${props => (props.underline || props.inline ? 'underline' : undefined)}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you, it's not a problem but definitely better style. Remaining problem is the data attribute if set to false
affecting the underline: true
. We might want to deprecate underline
first 🤔
Related to https://github.com/github/primer/issues/2099
Currently, the
inline
property only works in combination with thedata-a11y-link-underlines
attribute. However, the link should always be underlined ifinline
is set to true and no attribute is provided.Changelog
Changed
If
inline
is set totrue
, the Link will be underlined even if not using thedata-a11y-link-underlines
attribute.Rollout strategy
Testing & Reviewing
Merge checklist