-
Notifications
You must be signed in to change notification settings - Fork 599
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
Add prop to PageHeader to allow a bottom border #5741
base: main
Are you sure you want to change the base?
Conversation
🦋 Changeset detectedLatest commit: 47c50c7 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 |
Uh oh! @mperrotti, at least one image you shared is missing helpful alt text. Check your pull request body to fix the following violations:
Alt text is an invisible description that helps screen readers describe images to blind or low-vision users. If you are using markdown to display images, add your alt text inside the brackets of the markdown image. Learn more about alt text at Basic writing and formatting syntax: images on GitHub Docs.
|
👋 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! |
size-limit report 📦
|
@@ -176,6 +183,7 @@ const Root = React.forwardRef<HTMLDivElement, React.PropsWithChildren<PageHeader | |||
ref={rootRef} | |||
as={as} | |||
className={clsx(enabled && classes.PageHeader, className)} | |||
data-has-border={hasBorder} |
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.
data-has-border={hasBorder} | |
data-has-border={hasBorder ? '' : undefined} |
Small suggestion so that in the HTML it shows up as data-has-border
when true and then we can target it with just [data-has-border]
. When it's not in the DOM it's removed.
I also asked this question in our CSS Modules group to see if there was a style preference here 🤔 Not sure what folks prefer and this is definitely just a style thing
@@ -754,6 +762,7 @@ const Navigation: React.FC<React.PropsWithChildren<NavigationProps>> = ({ | |||
aria-label={as === 'nav' ? ariaLabel : undefined} | |||
aria-labelledby={as === 'nav' ? ariaLabelledBy : undefined} | |||
className={clsx(enabled && classes.Navigation, className)} | |||
data-component="PH_Navigation" |
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.
data-component="PH_Navigation" | |
data-component="PageHeader.Navigation" |
One suggestion that could make it more clear what the component is when coming back to this later
@mperrotti somehow I can't add this comment to the code, but we need this: |
Relates to https://github.com/github/primer/issues/2837
Changelog
New
hasBorder
prop onPageHeader
Changed
Removed
Rollout strategy
Testing & Reviewing
Merge checklist