🤖 Prevent navigation outside the domain details webview - #19570
Merged
Conversation
Contributor
Author
Adding the |
antonis
marked this pull request as ready for review
November 8, 2023 13:55
Contributor
|
| App Name | WordPress |
|
| Flavor | Jalapeno | |
| Build Type | Debug | |
| Version | pr19570-01aa44d | |
| Commit | 01aa44d | |
| Direct Download | wordpress-prototype-build-pr19570-01aa44d.apk |
Contributor
|
| App Name | Jetpack |
|
| Flavor | Jalapeno | |
| Build Type | Debug | |
| Version | pr19570-01aa44d | |
| Commit | 01aa44d | |
| Direct Download | jetpack-prototype-build-pr19570-01aa44d.apk |
Contributor
Generated by 🚫 Danger |
justtwago
approved these changes
Nov 8, 2023
justtwago
left a comment
Contributor
There was a problem hiding this comment.
Finally "purchased" a test domain to test it and it works nice! All the external links are opened in an external browser. Thanks for adding tests for the delegate! 🎸
Contributor
Author
|
Thank you for reviewing and testing @justtwago 🙇 |
12 tasks
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.


Fixes #19501
Description
This PR prevents navigation outside of the domain details context. Any other url is intercepted and opened in the device’s browser instead.
It also extracts the common navigation delegate functionality used in two other places with d52d5b8
To test:
domain_managementfeature flagMe>Domainsor `My Site>More>Domains>ALL)Screen_recording_20231108_154509.mp4
Regression Notes
Potential unintended areas of impact
campaign details webview and domain registration webview
What I did to test those areas of impact (or what existing automated tests I relied on)
Manual testing and relied on existing
DomainRegistrationCheckoutWebViewNavigationDelegateTestandCampaignDetailWebViewNavigationDelegateTestWhat automated tests I added (or what prevented me from doing so)
Added
DomainManagementDetailsWebViewNavigationDelegateTestPR submission checklist:
RELEASE-NOTES.txtif necessary.UI Changes testing checklist: