-
Notifications
You must be signed in to change notification settings - Fork 568
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
cleanup: remove deprecated underline attribute #5581
Conversation
|
size-limit report 📦
|
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.
Since we're using inline
, do we need to add data-a11y-link-underlines="true"
to the containers of the links so that the underlines will show? I did something similar in another PR, but now I'm wondering if there's some sort of base Storybook component we could add this to 🤔
Edit: We might be able to add the data-*
attribute to the <div>
in preview.jsx
, if we did go that route!
0acefdf
to
8b8c9ae
Compare
👋 Hi, this pull request contains changes to the source code that github/github depends on. If you are GitHub staff, we recommend testing these changes with github/github using the integration workflow. Thanks! |
@TylerJDev I think this route makes sense! We have something similar in dotcom! |
a7c946c
to
c65126d
Compare
5a1f66f
to
033ced5
Compare
@@ -271,6 +270,14 @@ export const decorators = [ | |||
document.body.setAttribute('data-dark-theme', darkTheme) | |||
}, [colorScheme]) | |||
|
|||
// Set data-a11y-link-underlines=true to enable underlines in all stories except the Link DevOnly Inline Story. |
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.
The Link Devonly inline story has examples to show what impact this underline data attribute has.
Adding this conditional to avoid ending up with this markup on that particular story, because it results in all links being underlined.=:
<div data-a11y-link-underlines="true">
...
...
<div data-a11y-link-underlines="false">
Learn more <Link href="#">about GitHub</Link>
</div>
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.
Looks great! Thank you for all the work on this ✨
Small change to clean up deprecated
underline
attributes!I was getting bothered in storybook files that this
underline
attribute is deprecated, but it's used in many examples.Let's clean this up so developers don't add undesirable usage in their code when copying examples from Primer's storybook.
Changelog
New
Changed
Removed
underline
attribute usage in stories.Rollout strategy
Testing & Reviewing
Merge checklist