Skip to content

Allow message sender to toggle on/off link previews #15917

@ilmotta

Description

@ilmotta

Problem

Depends on #15891

Not all users are willing to affect their privacy to share URLs with previews, so we should not always unfurl URLs.

Solution

Show a confirmation dialog the first time ever the user types a URL and no URL was ever unfurled. See Figma > Composer for Mobile. If the user has enabled link previews, then the dialog won't be shown again. In the future, the user will also be able to change this setting globally from setting's screens.

The options "Always show previews" and "Never show previews" are associated with the type https://github.com/status-im/status-go/blob/ceae9d33ad884baafebcf302df05ba3bcff7f3a9/multiaccounts/settings/enums.go#L29


Furthermore, the user should be able to change the settings later on from the Profile Settings (see in Figma). Ignore the GIF previews feature/setting

Image

The feature is already supported in status-desktop, as we can see from the screenshot below:

Image

Acceptance criteria

  • PR, QA, and design reviews all pass.
  • User can change the unfurling mode in the Profile Settings.
  • The user's choice is persisted between app restarts.
  • There's no major discrepancy in behavior between the Mobile and Desktop clients.
  • Choosing "Show for this message" will only affect the current composer message. As soon as the user goes to another screen and return, if they type a URL they will be asked again for unfurling options. Therefore, this state doesn't need to live in status-go.

Metadata

Metadata

Assignees

No one assigned

    Projects

    Status

    Backlog

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions