Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Links open in in-app browser #3885

Open
richvdh opened this issue Nov 18, 2024 · 3 comments · May be fixed by #4198
Open

Links open in in-app browser #3885

richvdh opened this issue Nov 18, 2024 · 3 comments · May be fixed by #4198
Labels
O-Occasional Affects or can be seen by some users regularly or most users rarely S-Tolerable Low/no impact on users T-Enhancement New features, changes in functionality, performance boosts, user-facing improvements X-Needs-Product Issue needs input from Product team

Comments

@richvdh
Copy link
Member

richvdh commented Nov 18, 2024

Steps to reproduce

Click on a link in the chat

Outcome

What did you expect?

Link opens in external browser

What happened instead?

Link opens in some sort of in-app web view. This is okayyyyy (if ugly), but the real problem is that there is no way to keep the web view open if I want to go back to chatting.

Your phone model

Samsung S22

Operating system version

Android 14

Application version and app store

0.7.3-nithgly 666cedd

Homeserver

No response

Will you send logs?

No

Are you willing to provide a PR?

No

@richvdh richvdh added the T-Defect Something isn't working: bugs, crashes, hangs and other reported problems label Nov 18, 2024
@jmartinesp
Copy link
Member

We can probably add some option to use an external browser instead (lots of apps have this), but you should be able to open the link in the actual web browser without it, like this:

image

@jmartinesp jmartinesp added X-Needs-Product Issue needs input from Product team S-Tolerable Low/no impact on users T-Enhancement New features, changes in functionality, performance boosts, user-facing improvements O-Occasional Affects or can be seen by some users regularly or most users rarely and removed T-Defect Something isn't working: bugs, crashes, hangs and other reported problems labels Nov 18, 2024
@davidegirardi
Copy link

I am getting into the habit of always clicking on an hamburger menu to open the full browser but it's an extra step for basically every link I tap on.

@cbs228
Copy link

cbs228 commented Jan 25, 2025

This web browser behavior is due to the use of Chrome Custom Tabs. Both Chrome and Firefox act as custom tab providers, and neither browser permits this behavior to be disabled anymore. Custom tabs are great for OIDC authentication flows and such, but I believe that using them for general web links is not ideal.

In-app browsers, and the remote tab apps which mimic them, are usually considered an anti-feature. They do not offer the user's other tabs, bookmarks, search, or an editable URL bar. The "back" button returns the user to the app—not to their browser or the previous page they were looking at. These are all design patterns which hold users "captive" within an app—usually to drive engagement and ad impressions. Obviously, this is not what Element X is after. Are there other compelling reasons to use Custom Tabs? Element Android classic did not work this way.

Very frequently I want to background a tab so I can read it later, at my leisure. Opening a full tab in my full web browser should be one tap, not three. On a large phone with small hands, those last two taps can be hard targets. If I want to return to Element from my full browser, I can just double-tap the Overview button. That's an action I am very accustomed to, in all sorts of apps, but it actually doesn't work correctly within the Custom Tab.

cbs228 pushed a commit to cbs228/element-x-android that referenced this issue Jan 26, 2025
In [1], all hyperlinks within `MessagesNode` switched to using

    activity.openUrlInChromeCustomTab()

instead of with `openUrlInExternalApp()`.

This causes web links in chat messages to open in an "in-app"
Chrome Custom Tab [2] instead of the user's configured "full"
web browser. This is a UX nuisance. Open web links in a full
browser instead.

Closes element-hq#3885 [3].

[1]: 5baefd4 (Identity change: handle click on "learn more")

[2]: https://developer.chrome.com/docs/android/custom-tabs/guide-get-started#opening_a_custom_tab

[3]: element-hq#3885
cbs228 added a commit to cbs228/element-x-android that referenced this issue Jan 26, 2025
In [1], all hyperlinks within `MessagesNode` switched to using

    activity.openUrlInChromeCustomTab()

instead of with `openUrlInExternalApp()`.

This causes web links in chat messages to open in an "in-app"
Chrome Custom Tab [2] instead of the user's configured "full"
web browser. This is a UX nuisance. Open web links in a full
browser instead.

Closes element-hq#3885 [3].

[1]: 5baefd4 (Identity change: handle click on "learn more")

[2]: https://developer.chrome.com/docs/android/custom-tabs/guide-get-started#opening_a_custom_tab

[3]: element-hq#3885
@cbs228 cbs228 linked a pull request Jan 26, 2025 that will close this issue
9 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
O-Occasional Affects or can be seen by some users regularly or most users rarely S-Tolerable Low/no impact on users T-Enhancement New features, changes in functionality, performance boosts, user-facing improvements X-Needs-Product Issue needs input from Product team
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants