Skip to content

[fix] Links in previews don't open on click #36

@wiese

Description

@wiese

Describe the bug

Node.js version: v16.18.1

OS version: Fedora release 38 (Thirty Eight)

Description: Links in previews don't open on click. Is this an intentional security feature?

Actual behavior

Click on links in the email preview do not open after update from 3.0.10 to 3.0.17 (I assume due to ce6d443sandbox attribute).

Console error message, e.g. in chrome:

Blocked opening '<redacted>' in a new window because the request was made in a sandboxed frame whose 'allow-popups' permission is not set.

I can still work around this via "Open link in new tab" in the context menu (proving the link works in principle).

Expected behavior

Click on links in the email preview opens in new tab.

If no general safe solution can be found, maybe make the attribute value configurable by the (library) user.

Code to reproduce

file:///tmp/3aa0abe6-c509-4f8d-a359-a110c2facf8e.html opened in browser, rendering HTML preview of message incl.

…
<a href="http://localhost:3000/<redacted>" target="">Sign In</a>

Checklist

  • I have searched through GitHub issues for similar issues.
  • I have completely read through the README and documentation.
  • I have tested my code with the latest version of Node.js and this package and confirmed it is still not working.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions