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

Bug - JumpLinksItem - href does not work properly #8309

Closed
jenny-s51 opened this issue Oct 31, 2022 · 3 comments · Fixed by #9307
Closed

Bug - JumpLinksItem - href does not work properly #8309

jenny-s51 opened this issue Oct 31, 2022 · 3 comments · Fixed by #9307
Assignees
Labels
bug P1 ⭐ top priority issues pinned
Milestone

Comments

@jenny-s51
Copy link
Contributor

jenny-s51 commented Oct 31, 2022

Describe the problem
A clear and concise description of the problem. Which components are affected?
If a JumpLinksItem is clicked, the url does not update as expected when clicked.

How do you reproduce the problem?
Provide steps to reproduce. A codesandbox demonstrating the problem is appreciated.
https://www.patternfly.org/v4/components/jump-links/react-demos/scrollspy-with-subsections/

  1. Right click on a jumplink.
  2. Click "Open in new tab"
  3. See that the anchor tag is appended to the URL for the jump link.
  4. Go back to the same demo in the other tab.
  5. Now Left click on any of the jump links.
  6. Notice that the anchor is never appended to the URL.

Expected behavior
A clear and concise description of the expected behavior.
We expect the URL to always append the anchor tag through the href attribute in the same window/tab.

Is this issue blocking you?
Cannot implement this feature in org until this bug is fixed.
See patternfly/patternfly-org#3120

Screenshots

Current:
Screen Shot 2022-10-31 at 11 06 54 AM

Expected:
Screen Shot 2022-10-31 at 11 07 44 AM

What is your environment?

  • Chrome
@jenny-s51
Copy link
Contributor Author

💡: This behavior is due to the ev.preventDefault in the scroll logic of JumpLinks.tsx. When it's removed we see the anchor tag get appended to the url, but this causes some other issues with scroll tracking.

@mcarrano mcarrano added this to the Prioritized Backlog milestone Nov 15, 2022
@stale
Copy link

stale bot commented Jan 14, 2023

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

@nicolethoen
Copy link
Contributor

closed by #9307

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug P1 ⭐ top priority issues pinned
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

5 participants