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

Make links from Jupyter AI chat open in new tab (vs in the same tab currently) #474

Merged
merged 1 commit into from
Nov 17, 2023

Conversation

andrii-i
Copy link
Collaborator

@andrii-i andrii-i commented Nov 16, 2023

Problem

Links in Jupyter AI chat are opening in the current window effectively closing the JupyterLab application when clicked. This is confusing and not optimal UX as people usually don't want to close the JupyterLab when clicking a help/documentation link.

Proposed solution

Open links from Jupyter Ai chat in new tab.

This PR introduces a NewTabLink subcomponent to open links in new tabs. This component applies target="_blank" for opening in new tabs and rel="noopener noreferrer" for security and privacy.

Before:
Before

After:
After

@3coins 3coins added the bug Something isn't working label Nov 16, 2023
Copy link
Member

@dlqqq dlqqq left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! I think @JasonWeill can help test, as we will do so prior to release later this afternoon.

@JasonWeill
Copy link
Collaborator

Let's plan on putting this into our December release, as I think it should go out with any other issues identified later this month.

@andrii-i andrii-i force-pushed the open_help_links_in_new_tab branch from 5aaa6c6 to fefed50 Compare November 17, 2023 00:13
@andrii-i andrii-i merged commit 69d5712 into jupyterlab:main Nov 17, 2023
4 checks passed
@andrii-i andrii-i deleted the open_help_links_in_new_tab branch November 17, 2023 01:04
@andrii-i
Copy link
Collaborator Author

@meeseeksdev please backport to 1.x

meeseeksmachine pushed a commit to meeseeksmachine/jupyter-ai that referenced this pull request Nov 17, 2023
andrii-i added a commit that referenced this pull request Nov 17, 2023
… in the same tab currently) (#476)

Co-authored-by: Andrii Ieroshenko <aieroshe@amazon.com>
dbelgrod pushed a commit to dbelgrod/jupyter-ai that referenced this pull request Jun 10, 2024
Marchlak pushed a commit to Marchlak/jupyter-ai that referenced this pull request Oct 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants