fix(webview): open Discover's external links in the in-app browser so they have a way back [PERA-4742] - #1096
Merged
Merged
Conversation
yasin-ce
force-pushed
the
yasince/fix/PERA-4742
branch
from
July 30, 2026 13:21
af9349e to
f12cc4b
Compare
5 tasks
yasin-ce
force-pushed
the
yasince/fix/PERA-4742
branch
from
July 31, 2026 06:41
f12cc4b to
fec4051
Compare
Collaborator
|
@yasin-ce QA and code review done ✅ |
yasin-ce
marked this pull request as ready for review
July 31, 2026 09:14
wjbeau
approved these changes
Jul 31, 2026
… they have a way back [PERA-4742]
yasin-ce
force-pushed
the
yasince/fix/PERA-4742
branch
from
July 31, 2026 09:22
fec4051 to
82af426
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Related Issues
Checklist
Additional Notes
Rebased through the conflict with #1055 (PERA-4673, social-media handoff), which landed first and touches the same guard. Two things about that resolution a reviewer should know:
Ordering is load-bearing. The social-media handoff is checked before
isExternalToHost. A social link is external to the host, so evaluating the external check first would route X / Telegram / Discord links into the in-app browser instead of the native app — silently reverting what #1055 just shipped. Both features' tests pass together: 7 social + 4 external-navigation, 29 in the spec.Both web-return points are gated.
maingrew a secondreturn truefor plain web navigation after this branch was written;isExternalToHostis applied at both, so a deeplink-adjacent path cannot bypass the handoff.isExternalToHostrequiresrequest.isTopFrame !== false, so an iframe cannot spawn a browser sheet.Touches
PWWebView.tsx, which PERA-4668 also touches — whichever lands second needs a rebase.