Skip to content
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

[feat]: <rh-jump-links> ready to migrate #539

Open
1 of 5 tasks
markcaron opened this issue Sep 21, 2022 · 12 comments · May be fixed by #2194
Open
1 of 5 tasks

[feat]: <rh-jump-links> ready to migrate #539

markcaron opened this issue Sep 21, 2022 · 12 comments · May be fixed by #2194
Assignees
Labels
for dev Ready for development priority: high High priority

Comments

@markcaron
Copy link
Collaborator

markcaron commented Sep 21, 2022

Tag Name

pfe-jump-links

RHDS Only

  • The component will be RHDS only, delete the PFE component once published

Additional Info

  • Build/migrate <rh-jump-links> from <pfe-jump-links>.
  • Contact Cheryl Little about use case in article templates.

Current design specs
2022 study about jump links on redhat.com

To do

@markcaron
Copy link
Collaborator Author

@bennypowers I believe you had an idea on implementation on this, so we'll need your advisement.

@marionnegp
Copy link
Collaborator

@coreyvickery and I will have to update the docs too.

@markcaron
Copy link
Collaborator Author

markcaron commented Nov 7, 2023

While discussing Jump Links with @Nouveau today, we realized that we're likely going to run into an issue with Jump Links and color-palette / color-context as it remains sticky and slides over different colored "bands" (i.e. dark and light). This may mean that Jump Links must have a background color, otherwise the context switching as the user scrolls will never work well (or be 100% accessible).

CC: @marionnegp @coreyvickery @nikkimk @jvanpelt

@markcaron markcaron added the needs revisiting Outdated issues worth revisiting in the future label Feb 7, 2024
@markcaron markcaron removed this from the 2024/Q1 — Chansey release milestone Mar 21, 2024
@markcaron markcaron changed the title [feat]: <rh-jump-links> ready to migrate [feat]: <rh-jump-links> ready to migrate Apr 29, 2024
@marionnegp
Copy link
Collaborator

On my smaller laptop screen, jump links with many items end up getting cut off. The jump links on the All products page just barely fits if I make my window fullscreen.
Screenshot 2024-06-17 at 3 43 53 PM

Dan suggested potentially decreasing the padding for each item.

@hellogreg hellogreg added for design Design work is requested and removed for dev Ready for development labels Oct 3, 2024
@markcaron
Copy link
Collaborator Author

After our <rh-jump-links> discovery meeting last week...

We discussed the following problems:

  1. Sticky scroll over top of inverted color-palettes / themes (e.g., bands) causes accessibility / contrast issues
  2. Long lists of links can get cut-off
  3. Orientation back to the menu. Sighted keyboard users will have a difficult time navigation back "up" to the nav. Screen reader users should be able to get to the nav via its landmark.
  4. Layout issues across media and container queries with handling the switch from vertical to horizontal, since the layout exists outside of the component itself.

And we came to the following decisions:

  1. Jump Links won't solve page layout issues. If using the vertical variant, it will remain vertical across all media and container queries. Same for horizontal, though we can provide an overflow/scroll somewhat similar to Subnav and Tabs.
  2. Sticky positioning and scrollspy features will be pattern-based add-ons.
  3. Jump Links will use the <nav> role internally as a built-in landmark.
  4. Documentation guidelines will strongly advise that implementers add "back to nav" type links to each section referenced in the Jump Links nav. These have to be manually added (at least for now).
  5. Documentation will suggest limiting the nav to a certain numbers of items (TBD, but likely 7) to keep the menu easy to understand and less likely to cause overflow issues.
  6. Documentation will suggest that you implement horizontal Jump Links when you have "bands" of content or alternating themed sections on pages AND when you're making them "sticky".
  7. Design will update the Jump Links component design to include a background color behind the links with a drop shadow (on light) and border (on dark) when "sticky".

@markcaron markcaron removed needs discovery Needs discovery needs revisiting Outdated issues worth revisiting in the future labels Oct 31, 2024
@markcaron markcaron moved this from Hold 🔴 to Todo in Red Hat Design System Oct 31, 2024
@markcaron
Copy link
Collaborator Author

markcaron commented Oct 31, 2024

Waiting on design updates (#7 above)

CC: @marionnegp @coreyvickery

@coreyvickery
Copy link
Collaborator

@markcaron Marionne will be taking on this work.

@marionnegp
Copy link
Collaborator

marionnegp commented Feb 11, 2025

@coreyvickery, here's the mock up of jump links. Not much has changed because most of the accessibility improvements are in guidelines that are specced out in this file as well. The table of contents variation has also been removed as we discussed.

For point #7, I added a border only for both light and dark theme to make the design a little easier to theme.

@bennypowers
Copy link
Member

bennypowers commented Mar 3, 2025

Resolved at office hours today:

  • disclosure at mobile / small container is a pattern, not built in to the shadow root. In other words - jump links is only a nav list of links.
    <rh-disclosure>
      <h3 id="jump-links-title" slot="summary">Title</h3>
      <rh-jump-links role="nav" aria-labelledby="jump-links-title">...</rh-jump-links>
    </rh-disclosure>
  • heading, even horizontal at full width is a pattern, we provide fallback aria-label, after checking whether or not there is a labelledby element
    We will need to carefully document mobile and accessibility patterns

@bennypowers bennypowers linked a pull request Mar 4, 2025 that will close this issue
@marionnegp
Copy link
Collaborator

@coreyvickery, here are updated to the mockups for jump links. This round includes a vertical sticky jump link.

@coreyvickery
Copy link
Collaborator

@marionnegp All looks good to me. Would you be able to tackle the docs?

@marionnegp
Copy link
Collaborator

@coreyvickery, yep, I can do docs.

@marionnegp marionnegp added for dev Ready for development and removed for design Design work is requested labels Mar 19, 2025
@marionnegp marionnegp moved this from Todo to In Progress 🟢 in Red Hat Design System Mar 19, 2025
@marionnegp marionnegp moved this from Todo to In Progress 🟢 in Red Hat Design System Roadmap Mar 19, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
for dev Ready for development priority: high High priority
Projects
Status: In Progress 🟢
Status: In Progress 🟢
Development

Successfully merging a pull request may close this issue.

7 participants