Skip to content

fix: open all links in new tab in embed view - fixes #4214#11879

Open
faratabassum09-a11y wants to merge 1 commit into
publiclab:mainfrom
faratabassum09-a11y:fix/issue-11620
Open

fix: open all links in new tab in embed view - fixes #4214#11879
faratabassum09-a11y wants to merge 1 commit into
publiclab:mainfrom
faratabassum09-a11y:fix/issue-11620

Conversation

@faratabassum09-a11y

Copy link
Copy Markdown

What does this PR do?

Fixes #4214

Changes made

  • Added JavaScript to app/views/tag/gridsEmbed.html.erb that sets target="_blank" and rel="noopener noreferrer" on all anchor tags
  • This ensures links in embedded grids open in a new tab instead of loading inside the iframe
  • The fix only applies to the embed view, not normal inline grids

Checklist

  • Tested the change locally
  • No existing functionality broken
  • The fix is scoped only to the embed view

@welcome

welcome Bot commented Jun 13, 2026

Copy link
Copy Markdown

Thanks for opening this pull request! This space is protected by our Code of Conduct - and we're here to help.
Dangerbot will test out your code and reply in a bit with some pointers and requests.
Also please refer here for installation help 💿
There may be some errors, but don't worry! We'll work through them with you! 👍🎉😄


One thing that can help to get started is to make sure you've included a link back to the original issue you're solving, in the format fixes #0000 (for example). And to make sure the PR title describes what you're trying to do! (often it can be the same as the issue title) Thanks! 🙌


Then, you can say hello in our chatroom & share a link to this PR to get a review! 👋 ✅

@faratabassum09-a11y

Copy link
Copy Markdown
Author

Hi maintainers!
I'm a new contributor working toward GSoC 2027.
Could someone please review this PR when they get a chance?
The failing tests appear to be pre-existing Ruby/Rails test failures
unrelated to my JavaScript change in gridsEmbed.html.erb.
Thank you!

@faratabassum09-a11y

Copy link
Copy Markdown
Author

This PR fixes #4214

Adds JavaScript to gridsEmbed.html.erb to ensure all links
open in a new tab when viewed in embed mode, preventing
the iframe from loading entire pages within itself.

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.

Links in embeddable grids should open new browser tab

1 participant