Skip to content

feat(ui): add setting to always show external images - #13947

Open
felixschndr wants to merge 1 commit into
nextcloud:mainfrom
felixschndr:feat/always-show-external-images
Open

felixschndr wants to merge 1 commit into
nextcloud:mainfrom
felixschndr:feat/always-show-external-images

Conversation

@felixschndr

Copy link
Copy Markdown

Summary

Adds a "Always show images" switch to Mail settings → Privacy. When enabled, remote images and styles are loaded for every message without the blocked-content warning, instead of requiring each sender or domain to be trusted manually.

  • Stored as the user preference always-show-external-images (default false), provided via initial state
  • MessageHTMLBody treats every sender as trusted while the preference is on; no trusted-sender entries are created
  • The trusted senders list is hidden while the switch is on, because it has no effect then

Testing

  • New Vitest case: images are shown and no sender gets trusted when the preference is on
  • Updated PageControllerTest for the new initial-state key
  • Manually tested on Nextcloud 33 with a local IMAP server: images blocked before, loaded right after enabling the switch and reloading
image image

🤖 AI (if applicable)

  • The content of this PR was partly or fully generated using AI (N/A)

Readers who don't care about remote-content tracking had to trust every
sender or domain one by one before images showed. A per-user preference
now loads remote content for all messages, the same way it is loaded for
a trusted sender.

The trusted senders list is hidden while the preference is on, since it
has no effect then. Existing trusted senders are kept, so turning the
preference off restores the previous behavior. The default stays off to
keep the privacy-preserving behavior for everyone else.

Assisted-by: ClaudeCode:claude-opus-5-5
Signed-off-by: Felix Schneider <mail@fschneider.me>
@welcome

welcome Bot commented Oct 26, 2026

Copy link
Copy Markdown

Thanks for opening your first pull request in this repository! ✌️

@odzhychko

Copy link
Copy Markdown
Contributor

I'm not sure, if we want to add this setting.

@felixschndr

Copy link
Copy Markdown
Author

Why not? It's an opt-in setting for users and many mail platforms do this as their default. I don't see a point of not giving the user the option

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants