Unable to open basket communication preferences from within Firefox Accounts




a year ago
a year ago


(Reporter: stomlinson, Unassigned)



Firefox Tracking Flags



(Whiteboard: [fxa], URL)



a year ago
Firefox Accounts links out to several external URLs, notably from the terms of service, privacy policy, and communication preferences in the settings page. The panel in which FxA is embedded is unable to open new tabs, either via window.open or adding a `target=_blank` attribute to the anchor element. 

To work around this, we convert external links to be visible text so that curious users are still able to open the referenced content by copying the text and opening a new tab.

This approach falls down with communication preferences on the /settings page. If a user is opted into marketing emails, we show a button that links to the centralized Mozilla marketing email dashboard (basket).

Some possible approaches to this problem (I'm sure I'm missing something obvious too)

1. Fx for iOS honors the `target=_blank` attribute on an anchor and open a new tab.
2. FxA detects that the user clicked on an anchor with `target=_blank` and sends Fx for iOS a message, which causes the new tab to be opened.
3. FxA opens all of those links inline for Fx for iOS.

#1 and #2 are functionally equivalent, but #1 has the advantage that FxA doesn't really need to do anything. Things would "Just Work." The problem with this is that users will need to re-enter Fx for iOS preferences to get back to FxA.

#3 seems reasonable, but once users are redirected to basket there is no way to go "back" to FxA. No back button. No back link.

Any ideas?

Comment 1

a year ago
Drive-by comment as I haven't looked at webview component we use to show FxA: 
WKWebView has a delegate callback `webview:createWebViewWith` that gets triggered on _blank targets, so opening a new tab to show the content shouldn't be an issue.
I think this function can be used to open in-line (actually I thought _blank was opened in-line if not handled specially).

The in-line case seems most like what a user would want, so we should have the navigation bar back title change from '< Settings' to '< Back'

Comment 2

a year ago
I just clicked 'Terms of Service' and it opened in-line, but pressing the back nav for 'Settings' will bring you back to top-level settings list view.
tracking-fxios: ? → 10.1
Priority: -- → P3
tracking-fxios: 10.1 → 10.3
tracking-fxios: 10.3 → 11.0
You need to log in before you can comment on or make changes to this bug.