-
Notifications
You must be signed in to change notification settings - Fork 536
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
[UnderlineNav] : Final implementation and UI fixes & docs improvement #2425
Conversation
|
size-limit report 📦
|
b0441c4
to
0f802ff
Compare
ae778b8
to
a1e23aa
Compare
8f9bb3d
to
eaf355f
Compare
eaf355f
to
e59e212
Compare
👋🏼 @danielguillan I have implemented the feedback you have given me here. I have a concern here for the touch target size though. I am not sure if it would be semantically correct to make the 44x44 wrapper div clickable to achieve the min touch target while keeping the button in a smaller width and height (because the focus ring should be around the button) if that makes sense. I think, the entire target touch area should be a button element. If that is the case, here how they will/should look. Unless I am missing a point here! Rest should be fine. I would appreciate your feedback on the fixes 🙏🏼 Also just to provide a context on giving Looking forward to hearing your feedback 🙌🏼 |
Overflow behaviour drastically changed due to the accessibility concerns and it would have been too complex to deal with merge conflicts here. So I am closing this PR and addressed above issues separately in these PRs: |
TLDR: This PR addresses a couple of implementation issues, UI fixes as well as some documentation improvement.
Storybook link: https://primer-7f80a98c95-13348165.drafts.github.io/storybook/?path=/story/components-underlinenav--internal-responsive-nav
Docs link: https://primer-7f80a98c95-13348165.drafts.github.io/drafts/UnderlineNav2
Issues addressed in this PR:
as
prop to the UnderlineNavnav
with a container thatoverflow: hidden
to prevent arrow buttons showing up when they are supposed to be hidden.string
type tocounter
prop to support cases like12K
event.preventDefault()
from click and keypress handlers as UnderlineNav should support withhref
along with react routing configuration. When react routing is configured, it ignores thehref
4px
left and right padding off from the link items and add8px
as agap
between the list items to align with design specs and take that gap value into account when calculating the possible number of items that can fit in the screen.Improvements in this PR:
Merge checklist
Take a look at the What we look for in reviews section of the contributing guidelines for more information on how we review PRs.