Skip to content

feat: open external sidebar links in new tab#3388

Draft
jarrensj wants to merge 3 commits intoacademicpages:masterfrom
jarrensj:feat/open-external-links-in-new-tab
Draft

feat: open external sidebar links in new tab#3388
jarrensj wants to merge 3 commits intoacademicpages:masterfrom
jarrensj:feat/open-external-links-in-new-tab

Conversation

@jarrensj
Copy link
Copy Markdown
Contributor

Add target="_blank" and rel="noopener noreferrer" to all external links in the author sidebar

Add target="_blank" and rel="noopener noreferrer" to all external links in the author sidebar
@rjzupkoii
Copy link
Copy Markdown
Collaborator

I have mixed feelings about target="_blank" since I tend to just open in a new tab by default; however, note that rel="noopener" is a bit redundant these days since modern browsers add it by default to <a> elements.

@jarrensj
Copy link
Copy Markdown
Contributor Author

I have mixed feelings about target="_blank" since I tend to just open in a new tab by default; however, note that rel="noopener" is a bit redundant these days since modern browsers add it by default to <a> elements.

all good, just felt like I kept clicking sidebar social links and then losing the original page I was on so I was hoping it would open a new tab instead but I think whatever you think is best for the template works for me!

I normally just anticipate it opening in a new tab so I don't often then I need to intentionally right-click to open into a new tab. We can close this PR though if you think it's not needed!

@jarrensj
Copy link
Copy Markdown
Contributor Author

Let me know if I should close this (or keep but remove noopener) and I can get that done!

@rjzupkoii
Copy link
Copy Markdown
Collaborator

I'm inclined to keep it, but we should make sure that if we are doing it for the side bar that other spots with social media links behave the same. Likewise the redundant code should be cleaned up just to keep things up to date with web standards.

- Add target="_blank" rel="noopener noreferrer" to social media links in footer and share buttons
- Apply same attributes to academic, repository, and documentation links
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants