Граф коммитов

2662 Коммитов

Автор SHA1 Сообщение Дата
Ryan Kelly dffe305e3d feat(signin): Re-authenticate an existing session if possible. (#5899) r=@vladikoff,@vbudhram
Fixes #5703
2018-03-06 14:10:22 -05:00
Vlad Filippov 96ca4c0903
fix(sign_up): changes to l10n string and style based on feedback (#5952) 2018-03-06 12:25:09 -05:00
Vlad Filippov bac0c07c69
feat(forms): replace our password advice with responsive message (#5940) r=@vbudhram,@ryanfeeley
Fixes #5750
2018-03-02 20:41:37 -05:00
Vijay Budhram 20863f876f fix(css): fixes button misalignment when refreshing clients (#5945) r=@vladikoff
Fixes mozilla/fxa-bugzilla-mirror#456
2018-03-01 16:37:40 -05:00
Vlad Filippov a336fba0e8
fix(styles): add position fixed to success messages if user scrolls too far (#5943) r=@vbudhram
Fixes #5552
2018-03-01 16:26:56 -05:00
Vlad Filippov 3fa0254252
fix(styles): fix unlock button for email settings unlock (#5944) 2018-03-01 14:50:46 -05:00
Vlad Filippov be30740e08
fix(strings): change 'confirm email' design to let users know that they should FxA to the address book (#5941) r=@vbudhram
Fixes https://github.com/mozilla/fxa-auth-server/issues/2255
2018-02-28 22:10:27 -05:00
Vlad Filippov 24eddb8a28
feat(avatars): support new default avatar API (#5942)
Unblocks the functional tests on the content server due to profile server API changes
2018-02-28 21:34:03 -05:00
Vlad Filippov d78c038988
Merge pull request #5929 from mozilla/train-106
Uplift v1.106.3 into master
2018-02-23 10:19:06 -05:00
Vlad Filippov a151f7c9bb
fix(tests): fixes for oauth tests and reset password (#5928) r=@philbooth
Fixes #5927
2018-02-23 09:15:25 -05:00
Vijay Budhram 2ad238a04e
fix(basket): Show service unavaible when no basket account prefs set (#5867), r=@philbooth 2018-02-22 15:00:32 +00:00
Phil Booth fb2729593d Merge branch 'train-106' 2018-02-22 07:24:08 +00:00
Princi Vershwal 4eda3b60c7 fix(settingView): All panels will be closed while navigating from a child-view to settings. (#5803) r=@vladikoff 2018-02-21 14:47:33 -05:00
Vijay Budhram c99b5ca042 feat(code): enable token code experiment sync users for 1.8% each cohort (#5926) r=@vladikoff 2018-02-21 14:34:09 -05:00
Phil Booth d04620efd2
fix(errors): ensure that toError always behaves sanely
https://github.com/mozilla/fxa-content-server/pull/5905
r=vbudhram
2018-02-17 07:49:46 +00:00
Vijay Budhram d1f878b0d4
chore(password): graduate confirm password experiment (#5917), r=@philbooth, @vladikoff 2018-02-16 18:31:20 +00:00
Vijay Budhram 60e9164bb2 fix(experiment): fix the token code experiment (#5918) r=@vladikoff 2018-02-16 12:13:41 -05:00
Ryan Feeley 0c1e614c41 fix(copy): Show email section to view status (#5908), r=@vbudhram 2018-02-16 15:35:25 +00:00
Vlad Filippov a6d7a94550
refactor(deps): remove bower (#5915) r=@vbudhram 2018-02-15 15:52:17 -05:00
Vlad Filippov b5f42686df fix(styles): fix icon overlap in CWTS on iOS (#5909), r=@vbudhram 2018-02-15 15:32:43 +00:00
Vlad Filippov a98d7a359d fix(strings): update communication pref strings (#5910), r=@vbudhram 2018-02-15 14:53:51 +00:00
Vlad Filippov 771c4cb54b
revert(tokencode): revert isSync detection (#5913) r=@rfk
See https://github.com/mozilla/fxa-content-server/issues/5912
2018-02-14 18:14:57 -05:00
vladikoff a1a1715e1b Merge branch 'train-105' 2018-02-12 16:53:22 -05:00
Vlad Filippov de3d61e2db
refactor(strings): remove "cloud services" (#5904) r=@vbudhram,@ryanfeeley 2018-02-12 16:40:50 -05:00
Vlad Filippov 1514796b2b
fix(style): swap reset links per feedback (#5903) r=@ryanfeeley 2018-02-12 15:29:25 -05:00
Vlad Filippov 6e05ab9e7e
feat(styles): improve reset password for reliers (#5896) r=@ryanfeeley,@vbudhram
Fixes #5776
Fixes https://github.com/mozilla/fxa-bugzilla-mirror/issues/458
2018-02-09 20:10:25 -05:00
Vijay Budhram 5f714def11 fix(tokenCode): Add support for tokenCode sync experiment (#5894) r=@vladikoff
Fixes #5886

This PR adds support to perform tokenCode experiment on sync users. WIP Until mozilla/fxa-auth-db-mysql#303 and mozilla/fxa-auth-server#2287 are merged.
2018-02-08 13:53:03 -05:00
Vlad Filippov 08e931e848
feat(eslint): bring back indent rule (#5887) r=@vbudhram
Fixes #5875
2018-02-08 09:35:23 -05:00
Vlad Filippov 6bd8b5cd44
fix(avatar): add spinner to avatar loading (#5888) r=@vladikoff
Fixes #5006

Co-authored-by: Soumya Himanish Mohapatra <shmiitian@gmail.com>
2018-02-07 20:14:13 -05:00
Phil Booth 5cbac34512 fix(cad): hide the success message after direct navigation (#5881) r=@vladikoff
Fixes #5852
2018-02-07 11:11:33 -05:00
Vlad Filippov e0bd497f91
feat(build): migrate to webpack (#5868) r=@philbooth,@vbudhram
Fixes https://github.com/mozilla/fxa-content-server/issues/5831

Co-authored-by: Shane Tomlinson <stomlinson@mozilla.com>
2018-02-07 10:46:46 -05:00
Anwesh Nayak d481849335 fix(style) : Setting section success messages border color (#5884) r=@vladikoff
fixes mozilla/fxa#272
2018-02-07 09:39:19 -05:00
Vlad Filippov 936faf8dc7
feat(sms): deploy SMS in Australia to 100% (#5885) r=@rfk
Fixes #5883
2018-02-06 21:09:21 -05:00
Phil Booth e5db03ad22
fix(metrics): emit amplitude click events earlier
Previously, amplitude click events were being triggered from the
verification.success front-end events. As the name suggests, those
events don't occur until after verification has succeeded. This change
ensures they happen as early as possible after the user has clicked.

https://github.com/mozilla/fxa-content-server/pull/5880
r=vbudhram
2018-02-02 22:46:21 +00:00
Vijay Budhram 6174a5c8b5
fix(market): Show marketing when opening on FxiOS (#5871), r=@philbooth 2018-02-02 15:26:41 +00:00
Vijay Budhram 4d6f048eea fix(test): Fix sign-in code test (#5877) r=@vladikoff
Fixes #5874
2018-02-01 23:04:53 -05:00
Anwesh Nayak 35441fc081 fix(notification_align): make notification button align better (#5861) r=@vladikoff,@vbudhram
fixes #5860
2018-01-30 18:21:20 -05:00
Anwesh Nayak a66fa84495 fix(input_capitalize): make input field capitalize (#5862), r=@vbudhram, @vladikoff 2018-01-30 21:53:24 +00:00
Vijay Budhram df6efe5a00
fix(experiment): Add the `treatment-link` to token code experiment (#5849), r=@philbooth 2018-01-25 15:46:45 +00:00
Vijay Budhram bdb690bd6d
fix(emails): enable change email for users (#5851), r=@philbooth 2018-01-25 14:54:15 +00:00
Soumya Himanish Mohapatra c34800aaa8 fix(style): add padding over save settings button (#5841), r=@vbudhram 2018-01-22 20:45:29 +00:00
Soumya Himanish Mohapatra f86889b2e9 refactor(icon): replace firefox-notes icon (#5833), r=@vbudhram 2018-01-19 11:34:17 -05:00
Vlad Filippov bf4d9adb31 feat(sms): enable sms 100% for PT, ES, FR, IT. 50% for AU (#5829); r=rfk 2018-01-17 16:49:58 +11:00
Vijay Budhram 4fb8208ba4
feat(signin): Add token codes experiment (#5706), r=@pb, @vladikoff 2018-01-16 12:25:46 -05:00
vladikoff d71916ffc3 revert(settings): #4982 clear inputs on Esc keyup (#5821) r=@vladikoff
This reverts commit bdd3915

Reason: https://github.com/mozilla/fxa-content-server/pull/5821#issuecomment-357100379
2018-01-11 18:58:08 -05:00
Vlad Filippov 1982475cf3
refactor(ios): remove old timer hack for Firefox iOS6, remove old tests (#5823) r=@vbudhram
Fixes #5820
2018-01-11 17:39:48 -05:00
Vlad Filippov 18228ec4c3
fix(typo): typo in test name and fxa-client (#5828) 2018-01-11 17:39:03 -05:00
Mutasem Aldmour bdd39157b4 fix(settings): #4982 clear inputs on Esc keyup (#5821) r=@vladikoff
Fixes #4982 clear inputs on Esc keyup event
2018-01-11 16:36:25 -05:00
vladikoff 592d0e0018 refactor(sms): clean up 2018-01-04 22:03:39 -05:00
shikhar-scs 98373a06ad perf(fxa-client): removed sms-errors.js
perf(fxa-client): removed sms-errors.js

perf(fxa-client): removed sms-errors.js

perf(fxa-client): removed sms-errors.js

perf(fxa-client): removed sms-errors.js

perf(fxa-client): removed sms-errors.js
2018-01-04 22:03:39 -05:00
Vlad Filippov 1a18855ba5
revert(sms): "Remove sms errors.js" (#5811)
* Revert "feat(client): update to fxa-js-client 0.1.70 (#5809)"

This reverts commit 8ecd8873c4.

* Revert "refactor(sms): remove sms errors.js"

This reverts commit fd3399f84a.
2018-01-04 20:53:14 -05:00
Vlad Filippov fd3399f84a
refactor(sms): remove sms errors.js
Fixes #5708

From https://github.com/mozilla/fxa-content-server/pull/5808
2018-01-04 19:29:57 -05:00
Shane Tomlinson cb3acb2336 feat(SMS): Set France (FR) to 50% (#5800) r=@vladikoff 2018-01-04 15:15:09 -05:00
Shane Tomlinson 9dd4e4a4e1 refactor(l10n): Make translation fetch Webpack compatible. (#5785) r=@vladikoff
Using `require('/i18n/clients.json');` works perfectly
in RequireJS because it makes a network request for the
resource, but not in Webpack where the bundler
attempts to read that file from disk.

Instead of leaning on RequireJS to fetch the resource
using an XHR request, use an XHR request directly.

Note: this only affects dev mode, translations
are still built into the final bundle in prod mode.
2017-12-21 11:53:43 -06:00
Shane Tomlinson d29140e57e feat(CAD): /connect_another_device redirects to /sms for eligible users. (#5766) r=@vladikoff
fixes #5737
2017-12-20 14:00:28 -06:00
Shane Tomlinson b66a317723 feat(SMS): Set Italy (IT) to 50% (#5799), r=@vbudhram 2017-12-20 14:36:02 -05:00
Shane Tomlinson 5a37b5d183
feat(CAD): Enable CAD on signin for everyone. (#5794) r=@vbudhram
With the caveat that we still show the old screen
for users who are ineligible for CAD - meaning
if another user is currently signed in.

fixes #5793
2017-12-20 16:03:49 +00:00
Mutasem Aldmour 166d63a547 fix(settings): #5680 dismiss tooltips on cancel in settings (#5791) r=@shane-tomlinson
fixes #5680
2017-12-19 15:35:34 +00:00
Princi Vershwal c1977b59be fix(delete_account): Made 'Incorrect Password' error field specific (#5792) r=@shane-tomlinson 2017-12-19 15:22:56 +00:00
Shane Tomlinson 9dff9ab799 feat(sms): Rollout rate of 0.5 for ES, PT, 1 for RO (#5783) r=@vladikoff
fixes #5782
2017-12-18 10:40:52 -06:00
Shane Tomlinson c8f8c93a9f
feat(sms): Add Australia (AU) (#5781) r=@rfk
Goes with https://github.com/mozilla/fxa-auth-server/pull/2248
2017-12-15 17:56:15 +00:00
Shane Tomlinson e977be433c Merge branch 'train-101' 2017-12-07 14:47:50 +00:00
Shane Tomlinson 4563a61d1f
feat(sms): Fully roll out Germany (DE) and Austria (AT) (#5775) 2017-12-07 14:45:10 +00:00
Ryan Feeley 2f29c7a5c0 fix(image):Descaled icons for snappier rendering (#5770) r=@shane-tomlinson
Noticed that on a low-resolution screen that these images were being scaled and were not pixel snapped (a + should render with no anti-aliasing on right angles). I hope this fixes it, give it a try before accepting please.
2017-12-06 15:08:32 +00:00
Ryan Kelly 4dc0a9883a
Merge pull request #5773 from mozilla/train-101
Merge train-101 point release to master
2017-12-06 12:04:15 +11:00
Shane Tomlinson 5d7366bb26 fix(email-first): Fix FxA resizing in the firstrun page for email-first (#5765); r=rfk
The min-height forced the iframe to be too large on the firstrun page
in the email-first flow. In chromeless, it doesn't really matter
how big the #main-content is, there's no shadow, etc, to display.

Remove the min-height: 300 declaration for chromeless
2017-12-06 10:52:56 +11:00
Vlad Filippov a6429eda17 fix(apps): Update Notes icon (#5768) r=@shane-tomlinson
Fixes #5767
2017-12-04 16:24:31 +00:00
MeridelW c8c8afe07a fix(copy): update sync-engines.js (#5769) r=@vladikoff,@ryanfeeley
Replace"Passwords" with "Logins" to be consistent with Firefox client.
2017-12-01 16:24:55 -05:00
Shane Tomlinson 27c189d3d0
refactor(client): Replace p-promise with native promises (#5543) r=@vbudhram
Replace the p-promise library with native promises. The es6-promise polyfill
is used for browsers that do not support native promises.

BAM!
2017-11-29 19:22:48 +00:00
Shane Tomlinson e191b19402
feat(sms): Enable SMS in Denmark (DK) and the Netherlands (NL) (#5749) r=@vbudhram
fixes #5746
2017-11-29 16:02:37 +00:00
Phil Booth ddd11a2b6a fix(metrics): ensure metrics always has a uid (#5764) r=@vladikoff 2017-11-29 09:55:55 -05:00
Shane Tomlinson 0c585ab1bd fix(test): Fix the StaleElementReference error in the SMS resent test. (#5747)
fixes #5745
2017-11-27 12:21:06 -05:00
Vlad Filippov 302e84f9de
fix(config): switch to .com scopes (#5754) r=@rfk 2017-11-23 22:37:23 -05:00
Shane Tomlinson 924588b68d fix(CWTS): Fix CWTS columns when firstrun is 420px. (#5738) r=@vladikoff,@ryanfeeley,@vbudhram
Set the column width to 150px in the "small" UI.

fixes #5710
2017-11-23 14:39:57 -05:00
Shane Tomlinson 79ef689533
feat(cwts): Move the back button below the submit button. (#5739) r=@ryanfeeley, @vbudhram
fixes #5711
fixes #5724
2017-11-21 20:37:50 +00:00
Ryan Feeley c4422ec8d4 Removed Sync from Sync devices (#5741) r=@shane-tomlinson
We are syncing with other things like password manager and Test Pilot, so I think "devices" is sufficient
2017-11-21 20:37:01 +00:00
Vlad Filippov 13a7525e1c
feat(keys): add HKDF uid salt to scoped keys (#5736) r=@rfk
Add HKDF uid salt to scoped keys
2017-11-20 18:05:26 -05:00
Shane Tomlinson 08ba4de419 fix(modules): Use Webpack compatible module define statements. (#5733) r=@vladikoff
Webpack chockes on `define((require, exports, module) => {`.
Instead, it needs `define(function(require, exports, module) {`

Part of the drive to replace RequireJS with Webpack.
2017-11-17 12:16:06 -05:00
Shane Tomlinson e35b847cac
fix(deps): Forbid use of $ w/o requiring jquery. (#5732) r=@vbudhram
This is in preparation for Webpack. Webpack cannot
use the global `$` reference, the reference must
be made explicit.
2017-11-17 17:07:48 +00:00
Shane Tomlinson 58ddff7c7a
fix(test): A signup test mixed `done` and promises. (#5734) r=@philbooth
Stop returning the promise, only use `done` for this test.

Part of the webpack work.
2017-11-17 17:07:25 +00:00
Shane Tomlinson 48d37cabc9
feat(sms): Enable SMS in Spain (ES), Italy (IT), Portugal (PT) (#5726)
fixes #5574
2017-11-17 17:07:02 +00:00
Shane Tomlinson 20e9aa9898
refactor(l10n): Remove the global `Translator` object. (#5731) r=@philbooth
Not part of any issue.
2017-11-17 17:06:21 +00:00
Shane Tomlinson a4e0fb1d1e
chore(fx-57): Use Fx 57 logo for everyone. (#5729) r=@philbooth
Remove all gating logic and just use the new logo.

fixes #5719
2017-11-17 14:09:06 +00:00
Vlad Filippov dd53307ecf
feat(keys): add support for deriving scoped keys in the oauth flow (#5675) r=@rfk,@shane-tomlinson
Fixes #5494
Fixes #5701
2017-11-17 00:37:08 -05:00
Shane Tomlinson 759e976301 fix(SMS): soft-launch LU. Change default rolloutRate to 0. (#5728) r=@vbudhram
I forgot to add a `rolloutRate` to Luxembourg (LU) which meant
it was being shipped fully rolled out. This is an easy mistake
to make. Instead of setting the default rolloutRate to 1, this
PR changes that to be 0 to avoid this problem. If a country is
fully rolled out, it's rolloutRate must be set to 1.

fixes #5727
2017-11-16 20:56:07 +00:00
Shane Tomlinson 8bee8b7e53
feat(CAD): Enable CAD on signin for 50% of people. (#5722) r=@philbooth
We did all the groundwork to release CAD on signin
but forgot to pull the trigger!

fixes #5721
2017-11-16 13:23:44 +00:00
Shane Tomlinson ac57c33956
feat(sms): Enable SMS to 50% of Germany (DE) (#5723) r=@philbooth 2017-11-16 13:22:23 +00:00
Phil Booth 2c06f6eb51 fix(ui): move device manager buttons to new row on mobile (#5714) r=@shane-tomlinson,@vladikoff,@ryanfeeley
Fixes #5712. Includes and supercedes #5713.
2017-11-14 15:10:24 -05:00
Shane Tomlinson 1d3644e4f6 feat(sms): Bump Austria (AT) to 50% (#5718) r=@vladikoff
An Austria based Mozillian was gracious enough
to test for us and gave us a thumbs up.

Does not have a feature.
2017-11-14 14:56:26 -05:00
Shane Tomlinson a5c28820a8 fix(style): Fix styling for 2nd password experiment. (#5704) r=@vladikoff,@ryanfeeley
fixes #5580
fixes #5581
2017-11-14 14:38:23 -05:00
Shane Tomlinson 9677ec1eac fix(errors): Ensure all server returned errors have entries. r=vladikoff,philbooth (#5707)
This does not fix #4906, but should reduce the number of
errors reported as invalid.

issue #4906
2017-11-14 06:51:53 -05:00
Shane Tomlinson 83dc5ed9af
feat(sms): Enable SMS in Belgium, France, Luxembourg (#5698) r=@philbooth
Monaco is not yet enabled, I have not found a phone
number that validates.

I was being too clever with the phone number validation and
was looking for mobile prefixes. At the same time, I had
the validation logic wrong. For many European countries
a trunk line prefix of `0` can be specified IFF the
country code prefix is not specified. For BE,
FR, and GB, I erroneously allowed the user to delete
the country code prefix, but did not force the trunk
prefix. This is fixed.

@philbooth also noticed that the unit tests for the module
were exploding as more countries are added. He suggested
that I convert the tests to be table driven, which condenses
the tests quite a bit.

issue #5573
2017-11-13 14:24:39 +00:00
Shane Tomlinson 38688e0940 feat(sass): SASS lint warnings are now errors. (#5700) r=@vladikoff
Also fix the errors that remain.

fixes #5699
2017-11-10 10:20:01 -05:00
Shane Tomlinson 455f2ce2fd fix(sms): SMS exp metrics are not reported for fully rolled out countries. (#5683), @vbudhram 2017-11-09 14:32:45 -05:00
Vijay Budhram 04cff4e99f
feat(session): Upgrade user session (#5626), r=@shane-tomlinson, @vladikoff 2017-11-09 11:33:18 -05:00
Vijay Budhram b01a496145 fix(restmail): Fix open restmail links (#5696) r=@vladikoff
Fixes #5666
2017-11-08 17:56:35 -05:00
Edouard Oger 2b403d6621
feat(broker): redirect to Choose What to Sync on newer versions of Firefox for iOS (#5640) r=shane-tomlinson 2017-11-08 14:52:58 -05:00
Shane Tomlinson 4a77b2f468 fix(back-mixin): Fix the "New broker method needed for click" error. (#5695) r=@vladikoff
The back-mixin erroneously passed the back button click event
as `nextViewData` when it invoked the `back` method.

The fix is to use a delegate method that invoked `back`
without the event.

fixes #5515
2017-11-08 13:18:52 -05:00
Phil Booth 3c25d9e850 fix(ui): ensure that long lines wrap in device manager (#5693), r=@vbudhram 2017-11-08 09:15:04 -05:00
Phil Booth d911bcfbcc fix(devices): use initial capital letter on strings (#5692), r=@vbudhram 2017-11-08 09:03:48 -05:00
Shane Tomlinson c982e6ab7b Merge branch 'train-99' 2017-11-08 11:10:07 +00:00
Shane Tomlinson 6b1617bd6a
fix(sms): If SMS is enabled, always send a signinCode. (#5688) r=@vbudhram
We know that SMS with signinCodes perform better than SMS w/o signinCodes.
Always use a signinCode if SMS is enabled.

The second half of the fix for #5685

issue #5685
2017-11-07 22:25:52 +00:00
Shane Tomlinson beb319045b Merge branch 'train-99' 2017-11-07 18:28:07 +00:00
Mutasem Aldmour 4ccff91a03 fix(signin): autofocus on sign in button when password is not required (#5657) r=@vladikoff
Fixes #5636.

(Circle CI fail due to old Git SHA)
2017-11-07 13:07:03 -05:00
Shane Tomlinson a9886f605f fix(sms): Allow SMS sending again. (#5687) r=@vladikoff
In `_areSmsRequirementsMet`, `isInExperiment` was called
w/o a `country`. The experiment itself requires a country,
so it returned that the user was not a member of the experiment.
Because of this, all users were sent to /connect_another_device,
even if in a country where SMS is was supported.

This fixes that by *not* calling `isInExperiment` in
`_areSmsRequirementsMet` and instead depends on the
call to `getExperimentGroup` in
`navigateToConnectAnotherDeviceScreen` to determine whether
the user is in an experiment group. The user's country is
known at this point and the correct answer will be returned.
If the user is not a member of the experiment, log
it there instead of in `_areSmsRequirementsMet`

Note, there are no functional test updates for this. We
are in a bit of a pickle here because the user is not
enrolled in any experiments within the functional tests
unless the `forceExperiment` query parameter is specified.

fixes #5685
2017-11-07 12:36:14 -05:00
Phil Booth eee6e92632 feat(devices): include location in the last sync/active string (#5682) r=@vladikoff
Fixes #5597
2017-11-07 11:34:00 -05:00
Vijay Budhram b0d2b24d7d fix(css): correctly wrap button for emails (#5681) r=vladikoff
Fixes #5508
2017-11-03 10:54:43 -04:00
Ryan Feeley 68767376c2 fix(copy): Added a hyphen to Sign-in confirmed (#5679) r=vladikoff
When a verb we say "sign in" and when a noun we say "sign-in".
2017-11-03 10:50:57 -04:00
Vlad Filippov 78cccaae2e fix(CAD): remove Maybe Later (#5674), r=@vbudhram
Fixes #5610

* fix(links): remove left class for link
2017-11-02 09:05:26 -04:00
Vlad Filippov f4d27c24af Train 98 uplift (#5667) 2017-10-31 11:41:15 -04:00
Vlad Filippov 3996b69048 Revert "fix(styles): fix logo styling"
This reverts commit dbf2425ddd.
2017-10-30 19:25:38 -04:00
Vlad Filippov dbf2425ddd fix(styles): fix logo styling 2017-10-30 19:24:55 -04:00
Phil Booth 1bbf1a9d1e
feat(metrics): emit timing flow events for settings activity
https://github.com/mozilla/fxa-content-server/pull/5654
r=shane-tomlinson
2017-10-30 12:04:17 +00:00
Shane Tomlinson 040f26cd35
fix(metrics): Fix the "working" error being reported in cwts. (#5656) r=@philbooth
Spotted by @ryanfeeley, starting with train-97.

The problem is the submit handler of CWTS finishes by calling `onSubmitComplete` and
propagating that functions return value. `this.onSubmitComplete` is set in the SignupMixin.
`onSignUpSuccess` will delegate to the `afterSignUp` method in the broker, which returns a
`NavigateBehavior` to `/confirm`. A `NavigateBehavior` returns a promise which never resolves,
causing `working` to be logged.

`signup`, `choose_what_to_sync`, and `signup_permissions` should all have the same
increase in "working" errors.

fixes #5655
2017-10-27 17:30:48 +01:00
Shane Tomlinson b3b9d520a4 feat(sms): Add support for Austria, Germany (#5624) r=@philbooth
Both countries have a rolloutRate of 0 so they can be soft-launched
and tested by visiting the /sms link directly.

fixes #5572
2017-10-26 15:18:22 +01:00
Shane Tomlinson ea199fe50e fix(sms): Fully rolled out countries all use `signinCodes` (#5647) r=@philbooth
fixes #5632
2017-10-25 17:09:45 +01:00
Shane Tomlinson f6054ff32e fix(style): Remove the duplicate border declaration. 2017-10-25 14:05:21 +01:00
Shane Tomlinson ed47618694 Merge branch 'train-98' 2017-10-25 14:04:23 +01:00
Shane Tomlinson 5d0bf08be3 fix(style): Fix sasslint warnings. 2017-10-25 13:00:05 +01:00
Shane Tomlinson e5e3f9968b fix(sms): Use the same graphic on /sms/sent as /sms (#5601) r=@ryanfeeley
Removed the sms-sent* images, they are no longer used.

fixes #5589
2017-10-25 12:56:34 +01:00
Tommasina bc03d2bc68 fix(style): Account for emoji shifting line height of device information (#5630) r=@ryanfeeley, @shane-tomlinson
Restrict line height to 1.2 to account for emoji in device names.
Previously, the device information line height got out of alignment
with emoji in device names.

Closes #5516
2017-10-25 12:56:11 +01:00
Erika Jonell e222543fcc fix(css): Show password border radius problem (#5628) r=@vbudhram, @ryanfeeley, @shane-tomlinson
fixes #5233 

Thank you so much for this @xevrem, this looks much nicer than what I came up with previously!
2017-10-25 12:53:59 +01:00
Shane Tomlinson 46921fbaee fix(logo): Use the new Firefox logo in Fx Desktop/Android >= 57, iOS >= 10. (#5643) r=@vbudhram, @ryanfeeley
Do some UA sniffing on startup to add the "fx-57" class
to the HTML element. If "fx-57" exists, display the
new logo.

fixes #5588
2017-10-25 12:49:47 +01:00
Erika Jonell f0d1fca161 fix(css): Show password border radius problem (#5628) r=@vbudhram, @ryanfeeley, @shane-tomlinson
fixes #5233 

Thank you so much for this @xevrem, this looks much nicer than what I came up with previously!
2017-10-25 12:04:11 +01:00
Ryan Feeley df00da53c9 fix(emails): Remove question mark (#5645) r=@shane-tomlinson
Noticed that this had a trailing question mark, and should instead follow the example set in other places, and not
2017-10-25 11:43:36 +01:00
Tommasina 726b033cb9 fix(style): Account for emoji shifting line height of device information (#5630) r=@ryanfeeley, @shane-tomlinson
Restrict line height to 1.2 to account for emoji in device names.
Previously, the device information line height got out of alignment
with emoji in device names.

Closes #5516
2017-10-24 11:10:29 +01:00
Phil Booth 7074dda73c feat(clients): display approximate last active times for old clients
https://github.com/mozilla/fxa-content-server/pull/5627
r=shane-tomlinson
2017-10-23 13:13:52 +01:00
Shane Tomlinson 46fe49eb90 feat(sms): Open SMS up to 50% of RO users. (#5623) r=@vbudhram
Simplify the SMS experiment logic by consolidating into a single
experiment, send-sms-install-link. send-sms-enabled-for-country
is removed.

This also consolidates logic to enable/roll out new countries. New
countries only need to be defined in `lib/country-telephone-info.js`.
If a country's entry contains `rolloutRate`, the experiment will
be rolled out at that rate. If a country is in the process of being
rolled out, it uses the `control` group so we can better compare
against CAD phase 1. Countries that are fully rolled out
use only `treatment` and `signinCodes`.

The plus side of this work is that the tests are far simpler
and a lot of code was able to be removed!

fixes #5611
2017-10-23 12:58:55 +01:00
Shane Tomlinson 2f5c83adc0 revert(style): Replaced active with hover active (#5631)
This reverts commit b0a6f8270c.

The "delete account" button turns blue with this change.

Reverts #5609
2017-10-23 12:58:16 +01:00
Vijay Budhram 16259d03ac fix(css): Fix secondary email margin (#5620), r=@philbooth 2017-10-20 14:47:49 -04:00
Shane Tomlinson 6597224d69 refactor(sms): Use formatted phone number returned from auth-server. (#5621) r=@philbooth 2017-10-20 14:55:52 +01:00
Shane Tomlinson f52e33649c chore(sms): Fix spacing in country-telephone-info.js and test (#5622) r=@shane-tomlinson
There was one extra space on every line.

With `?w=1`, GitHub says "Whitespace only changes". Self merge.
2017-10-20 09:47:59 +01:00
Ryan Feeley b0a6f8270c feat(metrics): Replaced active with hover active (#5609), r=@vbudhram 2017-10-19 20:08:27 -04:00
Shane Tomlinson 8439e85ea2 fix(avatar): Use the Photon icons for avatar change. (#5602) r=@ryanfeeley
fixes #5530
2017-10-19 21:03:35 +01:00
Shane Tomlinson a9d217dfc3 fix(style): Update the color of the devices "open panel" spinner. (#5604) r=@ryanfeeley
Add an opacity of 0.5 so that it matches the "Refresh" spinner.

fixes #5568
2017-10-19 20:51:38 +01:00
Shane Tomlinson 1b32c22351 fix(sms): Use the same graphic on /sms/sent as /sms (#5601) r=@ryanfeeley
Removed the sms-sent* images, they are no longer used.

fixes #5589
2017-10-19 20:51:09 +01:00
Phil Booth 85799de28e Merge branch 'train-98' 2017-10-19 15:24:32 +01:00
Shane Tomlinson ecab8bb0f3 fix(style): Ensure the content box-shadow is not visibile in the firstrun flow. (#5614), r=@vbudhram 2017-10-19 09:40:40 -04:00
Shane Tomlinson 15e20a7362 chore(sms): Fix the spacing in the sms_send test. (#5618) r=@shane-tomlinson
There was one too many spaces at the beginning of each line.

`?w=1` says `Whitespace-only changes.`. Self merge.
2017-10-19 14:22:36 +01:00
Shane Tomlinson 8805aa6cd7 chore(test): Fix the spacing in sms_sent.js (#5616) r=@shane-tomlinson
There was one too many (or too few) spaces at the beginning of each line.

?w=1 says: `Whitespace-only changes.` Self-merge
2017-10-19 14:21:53 +01:00
Vlad Filippov 2722bba3c8 feat(settings): remove Unsubcribe, link out to email prefs (#5551) r=@philbooth
The settings pane within Fx for iOS cannot open external links,
so users would be unable to manage their communication preferences.

Instead of showing a bad experience, disable the feature for
Fx for iOS until we have a better solution.

The `opt-in from settings after signin` is more or less
equivalent to `opt-in from settings after signup`. Only
one tests is needed.

Fixes #5465
2017-10-17 15:56:27 +01:00
Vijay Budhram 86dc936fa2 fix(css): Add photon shadow style and easing (#5550) r=@shane-tomlinson
fixes #5531
2017-10-17 11:22:12 +01:00
Shane Tomlinson 122f930a99 fix(email-first): Show a readonly on the signin/signup pages. (#5591) r=@vbudhram
We believe the editible email fields may be causing user dropoff.
The editible looking email fields are replaced with readonly
fields like /force_auth's.

fixes #5582
2017-10-17 10:27:00 +01:00
Vlad Filippov 7b9ab94133 refactor(form): remove disabled form state (#5437) r=@vbudhram
A combined effort of @vladikoff and @shane-tomlinson.

This removed the "disabled form state" from all
forms except /settings/display_name.

Things that are removed:
* Experiment code.
* Notifications to the firstrun iframe parent.
* Code that disables/enables forms in form.js.

A small mixin was created to allow individual
forms to re-add "disabled" state if needed.
2017-10-16 16:18:22 +01:00
Shane Tomlinson 848cef10cb feat(sms): Remove the `control` group from the `sendSms` experiment. (#5590) r=@philbooth
`control` performs worse than either `treatment` or `sendSms`. We
are continuing with the experiment pushing all users through
`treatment` and `sendSms`. This should boost the # of users in
each of the remaining groups.

fixes #5561
2017-10-16 16:15:47 +01:00
Shane Tomlinson 61d03d355b fix(sync): Firefox 58 transitions after email verification, not 57. r=@philbooth
The patch to let FxA transition after email-verification
from within about:accounts landed in Firefox 58, not 57.
This updates the check/tests to use 58 instead.

fixes #5556
2017-10-12 15:05:06 +01:00
Shane Tomlinson 7c33ed65f9 fix(signup): Show signup bounced errors in about:accounts from /confirm
Fx Desktop <= 58 takes control of about:accounts to redirect the user
to about:preferences#sync once it detects a user has verified their email.

We originally used this to reduce polling load on the server. Since
the browser was polling and would redirect once it detected the user
had verified their email, FxA did not poll. The problem is that
we added bounce detection, and we cannot detect bounces within
FxA w/o polling.

This change has FxA poll within about:accounts, but lets the browser
perform the screen transition once verification has been detected.

fixes #5566
2017-10-11 17:06:57 +01:00
Shane Tomlinson 6448c3880b Merge pull request #5564 from mozilla/train-97
merge(train-97): Merge train-97.2 into master
2017-10-09 16:20:55 +01:00
Phil Booth ba39aeb80f feat(metrics): add uid to metrics payload
https://github.com/mozilla/fxa-content-server/pull/5560
r=vbudhram
2017-10-06 17:57:27 +01:00
Shane Tomlinson 110a3adc7b fix(CAD): Do not show the "sign in" button if the user is at CWTS. (#5557) r=vladikoff
If a user verifies at CWTS, no verification data has been
written to localStorage, nor has the browser been informed
of the user's intent to signup/in. When the verification page
is opened, it looks like no user is signed in, so the user
was being asked to sign in again.

This PR fixes the problem by writing the "SameBrowserVerificationInfo"
to localStorage when the user first views CWTS. When the user verifies,
we look for the SameBrowserVerificationInfo, if it's available and
the user has made it as far as CAD, we know the account has been verified
in the same browser and the user will be fully signed in momentarily.

fixes #5554
2017-10-05 15:56:49 -04:00
Shane Tomlinson 04544713f6 chore(app-start): Replace _.bind with fat arrows for readability. (#5559) r=vladikoff 2017-10-05 11:27:49 -04:00
Shane Tomlinson 78f820f18b fix(signin-unblock): Fix Fx >= 57 screen transition after signin unblock. (#5518) r=vladikoff
Esp in Fx >= 57.

Turns out there were a lot of corner cases that weren't correctly addressed.

fixes #5488
2017-10-04 14:57:16 -04:00
Shane Tomlinson 0f6c4813d5 fix(CAD): Ensure CAD is displayed if the user verifies at CWTS. (#5546) r=vladikoff
Users who verify their email while looking at CWTS
have `account.verifed=true` when signup-mixin.onSignUpSuccess
is called. This resulted in the `broker.afterSignIn` function
being called, which only sends users to CAD if they are
part of the CAD on signin experiment.

This was wrong. These users are signing up and should be sent
to CAD.

The problem is the code that sent users to `afterSignIn` was
leftover to handle pre-verified users for users coming from
AMO. We removed this feature long ago, but this code hung
around, and in this case, caused a problem.

To fix this problem, in signinMixin.onSignUpSuccess, always
send users to broker.afterSignUp. If the account is verified,
broker.afterSignUp delegates to broker.afterSignUpConfirmationPoll,
which is the step after `/confirm`.

Extraction from #5518
2017-10-04 09:46:48 -04:00
Shane Tomlinson 1f645ede9e refactor(CAD): Simplify logic to decide whether to show CAD after email verification. (#5545) r=@philbooth
There were two capabilities, `cadAfterSignInConfirmationPoll`
and `cadAfterSignUpConfirmationPoll` that were used to decide
whether to show CAD after an email confirmation poll. These
two capabilities are set to `true` only when another capabilty,
`browserTransitionsAfterEmailVerification` is set to `false`.

Might as well ditch the extra capabilities and just use
`browserTransitionsAfterEmailVerification` and simplify the logic.

Extraction from #5518
2017-09-29 09:47:43 +01:00
Shane Tomlinson 829b0e867b fix(behavior): Propagate account info in the navigate behavior. (#5544) r=@philbooth
Behaviors are passed a view and an account. The account was not
propagated to the next view in the `view.navigate` call.

This PR changes that by propagating the account.

Extraction from #5518
2017-09-29 09:47:25 +01:00
Shane Tomlinson d3b00a1a7d Merge train 96 to master (#5540) r=vladikoff 2017-09-28 16:41:15 -04:00
Shane Tomlinson 5e6d22937f Merge branch 'train-96' 2017-09-27 18:23:02 +01:00
Shane Tomlinson 9121fe0531 fix(test): Fix the Sync v1 reset_password test. (#5529) r=@vbudhram, @vladikoff
The `customizeSync` attribute was not available on the account.

This is a regression due to us filtering out `undefined` values
on login data, introduced in d31de3522a.

fixes #5528
2017-09-27 18:18:04 +01:00
Vlad Filippov d22718431f feat(email): update newsletter strings (#5513) r=vbudhram,davismtl 2017-09-27 12:40:06 -04:00
Shane Tomlinson 461ea2b291 Merge branch 'train-96' 2017-09-26 14:22:31 +01:00
Shane Tomlinson cb2e1dca79 fix(email-first): Bump the email-first sample rate to 2.5%. (#5524) r=@philbooth
With #5479, we isolated the email-first experiment from
other "q3FormChanges" experiments, which caused the number
of users in this experiment to drop to 25% of its original
value. This PR says that enable the experiment for all
users that are chosen in q3FormChanges, as long as
they have metrics reporting enabled. The result is
a 2.5% sample rate.

fixes #5502
2017-09-26 14:20:36 +01:00
Shane Tomlinson 5380a3fe95 chore(assertion): Document why cert/assertion durations are what they are. (#5499); r=rfk
issue #5497
2017-09-26 09:23:26 +10:00
Shane Tomlinson d0a52607b3 fix(css): Fix the sass warning about height/margin being in the wrong order. (#5521) r=vladikoff,philbooth
Not attached to an issue.
2017-09-25 11:12:35 -04:00
Phil Booth 63f710b430 Merge branch 'train-96' 2017-09-21 21:55:15 +01:00
Phil Booth 491c967ff0 feat(metrics): include utm params in metrics context 2017-09-21 21:48:46 +01:00
Shane Tomlinson 8bfd44f9da fix(cwts): Ensure a two column display on CWTS in EN. (#5500) r=@ryanfeeley
* For the trustedUI form factor, set the column width to 118px
* Set the font size of the items to 14px
* Set the label color to grey
* Adjust the margins around the graphic

fixes #5442
2017-09-19 16:47:21 +01:00
Shane Tomlinson 3cae04cfa7 fix(OAuth): Correctly handle expired assertions. (#5498) r=vladikoff
The Account assertion cache incorrectly created the expiration
time to always be one hour from now. This sets the
expiration time to be one hour from the creation time.

fixes #4949
2017-09-19 08:39:57 -04:00
Shane Tomlinson ead2f2cbb5 refactor(client): Use relative paths (#5495)
refactor(client): Use relative paths
2017-09-19 11:05:27 +01:00
Shane Tomlinson b5de42b5f9 fix(l10n): Fix double escaping problems on /*_complete pages. (#5491) r=vladikoff
The header and button text are translated within the views
and passed to the templates. When the strings are translated
within the views, they are already HTML escaped. Then, the
template was escaping them again!

fixes #5407
2017-09-18 10:32:30 -04:00
Edouard Oger 453a3f6be0 revert(brokers): add uid to can_link_account in FxSyncChannel (#5492) r=@shane-tomlinson
This reverts commit 7f2abc6837.
2017-09-18 14:01:00 +01:00
Shane Tomlinson 381f050072 fix(test): Fix a typo, users go to /connect_another_device post-verification. 2017-09-14 14:54:15 +01:00
Shane Tomlinson f1f8a00cc6 fix(cad): Fixes based on @vladikoff's feedback.
* Rename `_areSubjectPrereqsMet` to `_isValidSubject`
* Remove the `instructions` class.
* Add docs about views/base.js->hasNavigated
* Fix some typos.
* Remove the temporary strings from strings.js
2017-09-14 14:12:02 +01:00
Shane Tomlinson 81fb406db5 fix(test): Revert changes to fennec/ios suites.
The experiment is not enabled for Fennec and iOS.
2017-09-14 14:12:02 +01:00
Shane Tomlinson ef9eb398f2 feat(CAD): Add CAD to signin
fixes #5262
2017-09-14 14:12:02 +01:00
Shane Tomlinson d31de3522a feat(sync): Transition screens after login message in Fx >= 57
fixes #5197
2017-09-13 16:05:44 +01:00
Shane Tomlinson 16ff59e2a1 fix(experiments): Only enable the experiment defined by `forceExperiment`. (#5447) r=vladikoff
In the functional test we use the forceExperiment and
forceExperimentGroup query parameters to force users
into an experiment. To avoid unexpected behaviors,
within the functional tests experiments are usually
disabled, unless of course, forceExperiment is defined.
The problem is, if forceExperiment is defined, all
experiments are then enabled. Independent experiments
that do not have a meta-experiment to choose between
them, e.g., q3FormChanges, can all be chosen. This
leads to unexpected behaviors in the functional tests.

If forceExperiment is defined, only that experiment should be enabled.

fixes #5446
2017-09-13 09:12:07 -04:00
Vlad Filippov 57568aa13f feat(devices): add loading indicator to device list (#5423) r=shane-tomlinson
Fixes #5040
2017-09-12 17:12:48 -04:00
Vijay Budhram c02d094d11 fix(avatar): For ios devices, only show change avatar for ios > 10 (#5480) r=vladikoff,shane-tomlinson
Fixes #5436
2017-09-12 15:18:43 -04:00
Vlad Filippov b05b52100b fix(styles): use an svg spinner (#5483) r=shane-tomlinson,vbudhram 2017-09-12 12:57:06 -04:00
Shane Tomlinson e547780071 Merge branch 'train-95' 2017-09-12 17:02:49 +01:00
Shane Tomlinson bca0f72eed fix(email-first): email-first experiment is isolated from other experiments. (#5479) r=vladikoff
Remove `static get name` from the email-first experiment rule
which blew up Safari 9 on iOS.

When combined with #5478,
fixes #5469
fixes #5452
2017-09-12 11:19:56 -04:00
Shane Tomlinson 2a8279f5f0 fix(email-first): Remove the vpassword field in email-first. (#5478) r=vladikoff
We have seen from the verification password experiment that
the 2nd password field causes ~ 6% drop in registrations.
Including the verification password here makes it impossible
to compare apples and apples because not all users in
the control group have `vpassword` either.

issue #5469
2017-09-12 09:29:00 -04:00
Phil Booth 35a703f813 fix(metrics): include deviceId in metricsContext data
https://github.com/mozilla/fxa-content-server/pull/5459
r=shane-tomlinson
2017-09-11 18:46:31 +01:00
Shane Tomlinson 1cc0044cbd fix(l10n): Fix the signin header and button text in `rm`. (#5470) r=vladikoff
Rhaeto-Romanic (rm) uses a `'` character in the header and
button text of the signin page. These characters were being
escaped, which looked ugly. Do not escape them.

fixes #5407
2017-09-11 11:52:03 -04:00
Shane Tomlinson a1bb9bc5c3 fix(style): Double link margins when two links are stacked on mobile. (#5471) r=vladikoff
fixes #4655
2017-09-11 11:23:56 -04:00
Shane Tomlinson 8de4a84398 Merge branch 'train-95' 2017-09-11 14:21:31 +01:00
Shane Tomlinson e1d59cad22 fix(email-first): Report flow events from /signin, /signup.
I forgot to add the FlowEventsMixin to
sign_in_password.js and sign_up_password.js

fixes #5455
2017-09-11 13:53:29 +01:00
Vlad Filippov 1c11944de4 feat(styles): animate some icons (#5419) r=ryanfeeley
Fixes #5319
Fixes #5168
2017-09-07 13:09:17 -04:00
Phil Booth 386886ee0c feat(metrics): send amplitude events to the logs (#5412) r=vladikoff
Fixes #5346
2017-09-06 13:51:27 -04:00
Shane Tomlinson 105db7bf6f chore(metrics): Log how frequently users are forcibly signed out from /settings. (#5441) r=vladikoff,philbooth
fixes #5435
2017-09-06 10:12:35 -04:00
Shane Tomlinson d276e10a5f refactor(brokers): Extract next steps from complete_sign_up to broker behaviors. (#5430) r=vladikoff
The next step logic in views/complete_sign_up.js was a rats nest, and easy
to mess up when adding new verification reasons, including mading the CAD
on signin modifications. This complexity has always been a sore point of mine,
and I've had 3 or 4 stabs at this previously but was never happy with the
result. This time I am.

Brokers are great at isolating behaviors for a particular integration
without affecting others. `afterCompleteSignUp` has two corresponding
siblings, `afterCompleteSignIn` and `afterCompleteSecondaryEmail`.

The broker behaviors define the next steps for each of these.

Much cleaner.

Extraction from #5308
2017-09-06 09:44:24 -04:00
Phil Booth f22b341e94 fix(settings): stop logging screen.settings when closing child views (#5439) r=@shane-tomlinson 2017-09-06 14:39:33 +01:00
Vlad Filippov 5eea74110c refactor(settings): adjust assertion caching (#5422) r=shane-tomlinson
Fixes #4949
2017-09-05 10:47:16 -04:00
Vlad Filippov 240c2045ea refactor(tests): sinon 3 migration (#5429) r=@shane-tomlinson 2017-09-05 13:09:00 +01:00
Vlad Filippov cb5633f4d2 fix(styles): fix alert styles (#5421) r=@shane-tomlinson 2017-09-04 10:27:30 +01:00
Vlad Filippov f73a15ee9c fix(avatars): fix egg shaped avatars (#5420) r=@shane-tomlinson
Fixes #5011 

Nice, simple fix @vladikoff, thanks!
2017-09-04 10:24:38 +01:00
Vijay Budhram c6f715c2c5 fix(email): Add success message when removing secondary email (#5391) r=@shane-tomlinson
fixes #5367 

Thanks @vbudhram!
2017-09-04 10:11:23 +01:00
Shane Tomlinson e3d4fdee1a fix(test): Bump the automated test startup delay to 750ms. (#5410) r=vladikoff
The Firstrun Sync v2 email first - email specified by relier, not registered
test frequently fails, I believe because the WebChannel listener is not
yet hooked up for the fxaccounts:can_link_account message.

I moved the delays that were in the auth_brokers/base.js broker and views/index.js
and moved this to app-start.js so that we can stop thinking about it.

In addition, I noticed while testing that sometimes a single listener could
be added multiple times. The listener would be added, but jQuery was not yet
in the DOM, and the try/catch block used in respondToWebChannelMessage would
try to attach a 2nd listener.

Instead of using jQuery, create the element manually.

issue #5390
2017-09-03 12:39:56 -04:00
Shane Tomlinson ac50d4e22c fix(CAD): Add the CAD on signin strings for l10n extraction. (#5417) r=@shane-tomlinson
Ref PR #5408
issue #5262

Self-merge to get these in before the deadline.
2017-09-01 17:27:27 +01:00
Shane Tomlinson bb0d84af6d refactor(views): Use ES2015 Class syntax for CAD/SmsSend views. (#5409) r=vladikoff
Extraction from #5408
2017-08-31 10:15:28 -04:00
Shane Tomlinson 6934d009b7 fix(style): Only add `centered` to links containers that need it. (#5393) r=@vbudhram
If a view contained more than one `.links` element and only one
of them needed to stack the links, the `centered` class would
be applied to all `.links` containers.

This iterates through each `.links` element and determines
if any of its child elements cause stackage.

fixes #5392
2017-08-31 14:52:49 +01:00
Shane Tomlinson e46f52602d Merge branch 'train-94' 2017-08-30 17:45:23 +01:00
Shane Tomlinson 968b7a88e1 fix(metrics): `engaged` flow events should only be triggered if the user engages! (#5401) r=@philbooth
There were two problems:

- If any of the view's input elements have a value prefilled from the
  form-prefill model, an engaged event will be logged as a result of
  the input event being fired on the element.
- The check for whether an element should be prefilled will respond
  with true even if the formPrefill model contains an empty string
  for that field. Users that go from the signin to signup page w/o
  entering anything on the signin page will have an empty string saved
  for both the email and password fields.

This fixes the problem by:

- No longer trigger an `input` event to cause the form to be enabled. Instead,
  update the element values in a `rendered` event handler, which is triggered
  before `afterRender` is run. `afterRender` will take care of enabling the form
  if valid.
- Only update a form value if the prefill model has a string with a length. Not
  strictly necessary, but it seems like the right thing to do.
- Move where the `rendered` event is triggered in the BaseView. It now occurs
  just after the template is rendered, before `afterRender`. Before this,
  `rendered` was only listened for in unit tests, so this is safe.

fixes #5388
2017-08-30 17:36:37 +01:00
Shane Tomlinson 1e4cf298e1 fix(metrics): Ensure emailFirst experiment metrics are reported. (#5402) r=vladikoff
The problem is `createExperiment` was called without a groupType.

fixes #5397
2017-08-30 11:19:06 -04:00
Edouard Oger 7f2abc6837 feat(brokers): add uid to can_link_account in FxSyncChannel (#5386) r=@shane-tomlinson 2017-08-29 15:25:20 +01:00
Shane Tomlinson 765b2b41dc feat(sms): Log why users are ineligible for the SMS experiment. (#5385) r=@philbooth
These are logged as flow evnets.

Possible flow events:
* flow.sms.ineligible.android
* flow.sms.ineligible.control_group
* flow.sms.ineligible.ios
* flow.sms.ineligible.not_in_experiment
* flow.sms.ineligible.no_session
* flow.sms.ineligible.other_user_signed_in
* flow.sms.ineligible.signin
* flow.sms.ineligible.unsupported_country
* flow.sms.ineligible.xhr_error

In addition, the country returned from the auth-server is logged:

* flow.sms.status.country.<TWO_LETTER_COUNTRY_CODE>

fixes #5382
2017-08-23 18:04:53 +01:00
Shane Tomlinson 1d23bced0b feat(email-first): Handle relier specified emails in email-first flow. (#5381) r=@philbooth
If the relier specifies an email, check whether the email is registered.
Do the right thing afterwards.

fixes #5353
2017-08-22 16:39:05 +01:00
Shane Tomlinson ce4b91116a fix(experiments): Replace crc with md5 as the hashing function. (#5380) r=vladikoff
We originally chose crc32 as the hashing function because it's small.
This worked fine when experiment.choose for two experiments were
called independently, but when one experiment was used to choose
another, *all* users of the chosen experiment were placed into
the same bucket. md5 doesn't suffer from this problem.

fixes #5378
2017-08-22 08:09:16 -04:00
Shane Tomlinson e8a9af8a3c fix(metrics): Do not log views that navigate in afterRender. (#5377) r=@philbooth
Views that navigate in `beforeRender` are not rendered to the DOM
and are not logged in metrics. Views that navigate in `afterRender`
erroneously are. This unifies the behavior so that if `navigate`
is called any time during `render`, the view is not rendered
to the DOM, nor is the view logged in metrics.

This fixes a problem where users that visit `/` and immediately
redirect to `/signup` or `/settings` still have the `/` view
logged, skewing the metrics making it seem like more people
see `/` than really do.

fixes #5375
2017-08-21 17:10:05 +01:00
Shane Tomlinson 1fdf6e94eb fix(metrics): Use `enter-email` as the viewName for `/`. (#5376) r=@philbooth
viewNames are normally created from the URL pathname.
The pathname for `/` is ``, meaning the view had no name.
This would show up in metrics with things like `flow..view`

This sets the viewName for `/` to `email-first`

fixes #5372
2017-08-21 14:29:41 +01:00
Shane Tomlinson 89d33bd93f fix(email-first): Navigate to `/`, not `/email` if no account. (#5371) r=@philbooth
The signin and signup pages for the email-first flow erroneously
redirected the user to `/email` instead of `/`.

Not attached to a bug.
2017-08-21 10:17:40 +01:00
Ryan Feeley 448104fe63 fix(email) (#5373) r=@shane-tomlinson
Making the button match the call-to-action in the heading
2017-08-21 10:17:12 +01:00
Vlad Filippov 1acf7aeb09 feat(devices): add Pontoon to client list (#5366), r=@vbudhram 2017-08-16 15:08:16 -04:00
apoorvasingh17 274103a336 fix(form): On device disconnect,"Rather not say" is selected by default (#5289) r=vladikoff
Fixes #5277
2017-08-15 11:38:04 -04:00
Ryan Feeley 05f9ffba3b fix(styles): update to new Photon colours (#5344) 2017-08-14 11:39:31 -04:00
Shane Tomlinson f022a24b46 feat(email-first): A/B test for email-first. (#5351) r=@philbooth
fixes #5335
2017-08-10 14:10:19 +01:00
Shane Tomlinson 5e3bc73c2c fix(cwts): Handle bounced emails and confirmations while on CWTS. (#5343) r=@philbooth
Use the session-verification-poll-mixin in the CWTS page to
handle both bounces and auto-submit the form if verification completes.

fixes #4094
fixes #4193
2017-08-10 13:16:06 +01:00
Shane Tomlinson aee366ccfc fix(signup): Stop polling after leaving the /confirm page. (#5342) r=@vbudhram
Extract the logic to do the signup/signin verification polling
from models/account.js into its own model, models/polls/session.js

Extract most of the polling logic from /confirm into
its own mixin, session-verification-poll-mixin. This
will allow the common logic to be used on CWTS.

The poll is started when entering the /confirm page,
stopped when leaving.

The hope is that this will make #4094 and #4193 very easy.

fixes #5323
fixes #5325
2017-08-09 15:50:20 +01:00
Vlad Filippov bb4f7578a7 feat(clients): add location information, update title hover location (#5329) r=udaraweerasinghege
Fixes #5291
2017-08-08 16:59:13 -04:00
Sean McArthur c977f07c52 feat(signup): add a Confirm Password field (#5249) r=@shane-tomlinson 2017-08-08 13:23:32 +01:00
Shane Tomlinson 11d10d8d59 fix(mailcheck): Fix the flaky mailcheck test (#5340) r=vladikoff
Instead of using a nth-child selector in the tests, give the
email-suggestion element an ID that can be checked for and
clicked. Hopefully this is a bit more sane.

Tangential changes:
* Modify the styles slightly to not use a `> span`, and instead
use classes and IDs. > span is slow because of CSS pattern matches
operate from right to left.

fixes #5309
2017-08-04 09:45:47 -04:00
Phil Booth 4e03b36ed7 fix(signin): redirect to signin if bounced screen has no email
https://github.com/mozilla/fxa-content-server/pull/5339
r=shane-tomlinson
2017-08-04 10:00:01 +01:00
Shane Tomlinson adb8a712b3 revert(cwts): Revert the revert - re-check addresses and creditcards. (#5337) r=vladikoff
This reverts commit b76d67b12a.
2017-08-03 13:50:22 -04:00
Shane Tomlinson 5db6d3268f feat(client): email first flow (#5177)
The email first flow is available for Sync if the action=email query parameter is specified. The opt-in allows us to release and test without interfering w/ other views & flows. If action=email is not specified and no user is signed in, users should be sent to /signup. If a user is signed in, action is ignored, the user will be sent to /settings.

On the / screen, if the user enters an email that is registered, they will be sent to /signin. If the email isn't registered, they'll be sent to /signup. Note, an email that is registered but has not yet verified will be sent to /signin. The user can reset their password if they really want to re-register.

Once a user is on /signin or /signup, if the user decides they want to change their email, they'll be sent back to / to edit their email. This avoids having to deal with things like signin-from-signup or handling Account doesn't exist errors on the signin page.

I opted to use totally new views instead of the existing SignInView and SignUpView for a couple of reasons. First, this is an experiment. If the experiment fails, I want to be able to easily remove the code. Second, if the experiment succeeds, I want to be able to rip out the old views. There is so much complexity to handle corner cases that'll be avoided with this flow.

If the experiment succeeds, we'll need to update the new signin view to handle OAuth flows and the user's avatar, but that's in the future.

Note, I did not add an A/B test or metrics for this. That'll be a follow on PR, this portion is already large enough.

Note for testing: open https://127.0.0.1:3030/?service=sync&context=fx_firstrun_v2&action=email

fixes #5194
2017-08-03 18:29:41 +01:00
Shane Tomlinson 84d5709e2c feat(CAD): ABC test for CAD phase 3 (deep link) (#5332) r=@philbooth
The new officially supported way to enable signinCodes is to use:

`&forceExperiment=sendSms&forceExperimentGroup=signinCodes`

Support for `&signinCodes=true` has been removed.

After adding the ExperimentMixin to the SmsMixin, I saw a bug
in the ExperimentMixin where it assumes `this._account` always
exists on the View, which isn't the case for the SMSSendView.
Most views declare a `this.getAccount()` function that returns
the account being used. I updated the mixin to first check for
`this.getAccount`, then as a fallback, use `this._account`

fixes #5278
2017-08-03 16:42:34 +01:00
Shane Tomlinson a334ce0e2a fix(test): Fix the fx_firstrun_v2 signup tests in Fx 54. (#5331) r=vladikoff
The tests that deselected a bucket on CWTS failed on Fx 54
because the original input element is too small to click
after being updated to use the Google Material style.

The fixes the problem by moving the label used as the selector
from the input element to the label, which is always visible.

fixes #5330
2017-08-03 10:29:22 -04:00
Shane Tomlinson 0cf878ab03 fix(experiments): Do not delegate to `experiments` methods after view.destroy (#5333) r=@philbooth
The experiment mixin made an assumption that `this.experiments` was always
available in the delegate methods. This assumption is invalid once view.destroy
is called.

This caused a problem on the confirm page - if the app was polling for
an email confirmation and the user clicks the browser's `back` button,
the confirm view was destroyed when the page went back to CWTS, but
the poll continued. If the user verified their email, the poll would
complete, which would then attempt to call the confirm view's
`isInExperimentGroup` function. Since the view was destroyed,
`view.experiments` was `null`. Kaboom.

issue #5323
fixes #5324
2017-08-03 14:50:50 +01:00
Phil Booth 8c844a5c01 feat(signin): add a sign-in bounced email screen
https://github.com/mozilla/fxa-content-server/pull/5318
r=vbudhram,shane-tomlinson
2017-08-03 14:48:29 +01:00
Vijay Budhram 074c8d7c82 fix(css): remove left margin (#5327) r=vladikoff 2017-08-02 12:23:46 -04:00
Shane Tomlinson f9f7f10d43 refactor(reset_password): Use back-mixin in reset_password (#5316) r=vladikoff,philbooth
The reset_password view hard coded it's previous view,
which makes it more difficult to use reset_password
from other views than needs to be.

Use the back-mixin which provides generic functionality.
2017-08-01 08:39:00 -04:00
Shane Tomlinson b76d67b12a revert(cwts): Revert "Check addresses and creditcards by default." (#5315) r=vladikoff
This reverts commit 3b3dbe57d5.

Reverts #5282
fixes #5314
2017-08-01 08:38:32 -04:00
Shane Tomlinson f91075edd9 fix(reset_password): Update formPrefill only if user enters an email address (#5295) r=@vladikoff
fixes #5293
2017-07-31 21:43:33 +01:00
Shane Tomlinson a9178e9679 fix(back): Clicks on the hash button no longer append # to the URL. (#5303) r=vladikoff
* fix(back): Clicks on the hash button no longer append # to the URL.

`preventDefaultThen` was being called in the wrong place. We were not
calling it on click handlers, but we were always calling it on keyup,
event if the key was not `ENTER`.

fixes #5290

* fix(test): Test to ensure event.preventDefault is called on #back.
2017-07-28 13:24:47 -04:00
Shane Tomlinson 08d29b4b8c Merge branch 'train-92' 2017-07-28 13:09:13 +01:00
Ryan Kelly e3d9cc0932 fix(sync): Only show `addresses` if the browser says it's supported. (#5296) r=@philbooth (#5299)
fixes #5292
2017-07-28 12:58:39 +01:00
Shane Tomlinson 22f383829a fix(sms): Ensure SMS can be sent on Fx 55+. (#5301) r=@philbooth
After requesting account data from the browser it is written
to storage inside of a promise. We were not waiting for the
promise to complete before starting the complete_sign_up
view, which checks storage for the account data that is not
yet written. No account is returned, so a new account is
created with the data present in the verification link,
which does not include a sessionToken. When the SMS check
occurs, the account has no sessionToken, so we force
the user down the CAD flow.

The fix? Add a `return` so the promise is propagated
whenever user.setSignedInAccountFromBrowserAccountData is
called.

fixes #5285
2017-07-28 12:58:18 +01:00
Vlad Filippov fdf724ef1d feat(forms): add non-disabled button experiment (#5268) r=shane-tomlinson
Fixes #5130
2017-07-27 17:41:26 -04:00
Shane Tomlinson 228b8f03c3 fix(sync): Only show `addresses` if the browser says it's supported. (#5296) r=@philbooth
fixes #5292
2017-07-27 15:49:05 +01:00
Shane Tomlinson 78658f094d fix(router): Fix model management when going "back" through history. (#5288) r=@philbooth
What is the problem?
When going "back" through history, the router creates a new model
for the previous view. This causes problems in email-first where
the user's email address on /signup_password is filled in from
an `account` model. Users that go to the TOS/PP agreements then
click "back" are sent all the way back to `/email` because a new
view is created for /signup_password.

How does this fix the problem?
Keep a stack of viewModels. When going back through history,
re-use the same model that was used the first time a view is
displayed.

extraction from #5177
2017-07-27 12:59:05 +01:00
Shane Tomlinson 3c14509b38 fix(signup): Remove `isSyncSuggestionEnabled` from signup-mixin. (#5286) r=philbooth,vladikoff
The function is duplicated by the sync-suggestion-mixin.

extraction from #5177
2017-07-26 07:51:49 -04:00
Shane Tomlinson 16045ba05d fix(sign_up): Ensure `beforeRender` calls FormView's `beforeRender` (#5284) r=vladikoff 2017-07-25 12:26:03 -04:00
Shane Tomlinson d8f2aa4418 fix(firstrun): Fix styles in firstrun. (#5283) r=vladikoff
* Set the font-size of the marketing opt-in text to 12px.
* Ensure the entire "Save settings" button text displays in CWTS.

fixes #5271
fixes #5273
2017-07-25 12:01:27 -04:00
Vijay Budhram 39bb7715c0 feat(emails): Add support for change email (#5242) r=shane-tomlinson,vladikoff 2017-07-25 09:57:10 -04:00
Vlad Filippov 413d65c9a8 fix(cwts): Check addresses and creditcards by default. (#5282) r=shane-tomlinson
Addresses and creditcards were not checked by default. @markh
says they should be.

fixes #5269
2017-07-25 09:37:23 -04:00
Shane Tomlinson deb16e3535 fix(signup): Focus the age input if email/password prefilled (#5281) r=philbooth,vladikoff
fixes #5280

The mile high bug.
2017-07-25 08:36:31 -04:00
Shane Tomlinson 808a814677 refactor(coppa): Make the COPPA view a mixin for easier reuse. (#5261) r=@philbooth
COPPA was originally extracted from the signup flow into its own
view because we had two variations to A/B test. This variant won.

I want to re-use the COPPA logic in the email-first flow. Initially
a mixin was created that creates the COPPA logic. The mixin ended
up doing a lot of plumbing between the consuming object and the
COPPA object, things like delegating to COPPA object methods, event
delegation from the COPPA object to the consuming object, etc.
This housekeeping seemed unnecessary with mixins. Instead
of pushing all responsibilities to the COPPA object, the consuming
object takes over these responsibilities via the mixin.

Extraction from #5177
2017-07-25 12:56:36 +01:00
Udara Weerasinghege 91e98e8ec7 feat(clientsList): order by type and time, and correct text (#5264) r=vladikoff 2017-07-24 13:07:23 -04:00
Shane Tomlinson 8fafad7f41 refactor(email-opt-in): Extract the email-opt-in frontend logic for re-use. (#5275) r=@vbudhram
Extract the email-opt-in login to a mixin for use in the email-first flow.
2017-07-24 15:37:50 +01:00
Shane Tomlinson 59f014ed01 fix(test): Increase automatedBrowser timeout to fetch fxaStatus. (#5274) r=vladikoff
* fix(test): Increase automatedBrowser timeout to fetch fxaStatus.

200ms does not seem to be enough on Circle. Bump to 500ms.

fixes #5247

* refactor(test): Move the flaky handshake tests to the top of the circle list.
2017-07-24 10:36:46 -04:00
Shane Tomlinson 294a3f65cd refactor(client): Extract a form-prefill-mixin. (#5258) r=vladikoff,seanmonstar
* refactor(client): Extract a form-prefill-mixin.

Form elements that have a `name` or `id` attribute and
do not have `data-novalue` are eligible for form-prefill.

Values are prefilled if:
* Above prerequisites are met.
* Element does not have an `autocomplete="off"` attribute.
* Form prefill model has a value for the field.

Values are saved if:
* Above prerequisites are met.

Element name/id attributes are used as the key into
the formPrefill model.

Extraction from #5177

* fix(form-prefill): Cleanup based on @seanmonstar's feedback.

* Remove extra `beforeDestroy` in sign_up.js
* Remove extra `password` context value in sign_up.js
* Remvoe extra `value={{password}}` in templates.
2017-07-24 10:02:33 -04:00
Vlad Filippov dff0aeac91 fix(styles): add active styles to primary buttons in settings (#5267), r=@vbudhram 2017-07-22 09:39:18 -04:00
Vlad Filippov b3d92fd963 fix(settings): fix typo in iPad device css (#5266) r=vbudhram
Fixes #5051
2017-07-21 14:28:24 -04:00
Vlad Filippov 9625526c2f fix(strings): update OAuth Apps with a "Revoke" string (#5263) r=ryanfeeley
Fixes #5036
2017-07-20 16:56:24 -04:00
Vlad Filippov 2a49cf6e2e feat(email): add new email graphic, switch to SVG (#5124) r=ryanfeeley
* feat(email): add new email graphic, switch to SVG

Fixes #5105
2017-07-20 15:25:24 -04:00
Shane Tomlinson 42a3219ebb feat(sync): Extract the Sync Suggestion logic into a mixin to be shared. (#5253) r=philbooth
The Sync suggestion will be showed on the `/email` page in the Email-first flow.

Extraction from #5177
2017-07-20 16:45:00 +01:00
Vlad Filippov 8ea6907cc0 fix(styles): add new CWTS image (#5259) r=ryanfeeley,shane-tomlinson
Fixes #5098
2017-07-20 11:04:05 -04:00
Vlad Filippov 9a8369ce6c fix(clients): add 'last sync time unknown' (#5257) r=shane-tomlinson
Fixes #4988
2017-07-20 09:41:14 -04:00
Shane Tomlinson b5942aee40 refactor(mixins): Mixins can now declare other mixins as dependencies. (#5251) r=@shane-tomlinson
What is the problem?
A lot of mixins require other mixins to function. To make this work,
a View would have to mix-in all of the dependent mixins too, or
a mixin would have to mix the dependent mixin to itself. It was
difficult to know what to do whenever adding a mixin that depended
on others, like the connect-another-device-mixin.

How does this fix the problem?
A mixin that depends on other mixins can declare an array `dependsOn`.
Each mixin declared in `dependsOn` will be mixed into the
consuming object before the mixin itself.

This also takes care of the possibility of a mixin being added
multiple times.
2017-07-20 11:47:26 +01:00
Vlad Filippov 89e0d6aa63 fix(clients): update strings to support first and last sync isMemoryToken values (#5256) r=udaraweerasinghege
Fixes #3908
2017-07-19 16:02:45 -04:00
Shane Tomlinson 5f1325289a refactor(client): ServiceMixin sets `service`, `serviceName` in setInitialContext. (#5250) r=@philbooth
`serviceName` especially was set in all of the views that consumed the ServiceMixin.
Might as well reduce duplicate effort and set the value in one place.

Extraction from #5177
2017-07-19 17:23:22 +01:00
Sean McArthur d136eecba1 Merge pull request #5212 from mozilla/signup-marketing-optin
feat(signin): send `marketingOptIn` parameter to server
2017-07-18 09:54:52 -07:00
Shane Tomlinson 75d8c4b8e1 fix(sms): Allow the user to go back after resending an SMS. (#5246) r=vladikoff,philbooth
All the text has been moved to the template.

fixes #5244
2017-07-18 10:29:13 -04:00
Vlad Filippov f86a8c2380 feat(clients): add new Firefox Notes icon (#5245) r=vbudhram 2017-07-17 10:43:05 -04:00
Shane Tomlinson 84819574b2 fix(cwts): Success message updates. (#5224) r=vladikoff
* fix(devices): Correctly print a session's name if no userAgent is sent.

If no userAgent was sent for a session, we displayed the session
name as "Web Session,". Notice the extra comma.

This gets rid of the extra comma if no userAgent is sent,
instead printing "Web Session".

fixes #5230

* fix(cwts): Success message updates.

* Update the success message to include a "Mistyped email?" link.
* Remove the "Back" link since this is duplicate functionality.

fixes #4726

* fix(cwts): Change ":email created" to ":email registered"
2017-07-13 09:49:06 -04:00
Shane Tomlinson eccb6aaaa9 fix(devices): Correctly print a session's name if no userAgent is sent. (#5231) r=vladikoff
If no userAgent was sent for a session, we displayed the session
name as "Web Session,". Notice the extra comma.

This gets rid of the extra comma if no userAgent is sent,
instead printing "Web Session".

fixes #5230
2017-07-13 09:46:46 -04:00
Sean McArthur eb2e97367c feat(signin): send `marketingOptIn` parameter to server
Closes #5195
2017-07-11 16:34:45 -07:00
Vijay Budhram 359e45fc86 feat(emails): Check with auth-server to ensure secondary emails is enabled for user (#5214), r=@shane-tomlinson 2017-07-10 09:41:52 -04:00
Vlad Filippov 9bc4821e09 fix(styles): match the radio button style with Firefox Desktop (#5207) r=philbooth
Fixes #5143
2017-07-04 13:03:44 -04:00
Vlad Filippov 6298cad9da fix(settings): add primary button box-shadow (#5208) r=philbooth
Fixes #5179
2017-07-04 13:03:32 -04:00
Vlad Filippov d9e063c379 fix(lint): fix sasslint warning for the settings module 2017-07-04 12:05:15 -04:00
Vlad Filippov 1d5438a718 fix(devices): support the new Add-ons client in the devices view (#5206) r=philbooth
Fixes #4835
2017-07-04 11:53:07 -04:00
Princi Vershwal 11c120252c fix(scssFile): fixes padding mismatch of client name (#5200) r=vladikoff 2017-07-04 11:20:14 -04:00
Phil Booth cfa3870f70 fix(metrics): categorise the performance flow events
https://github.com/mozilla/fxa-content-server/pull/5199
r=shane-tomlinson
2017-07-01 06:38:30 -07:00
Shane Tomlinson 93f2db2fd2 feat(sync): Add support for creditcards and addresses as sync engines. (#5158) r=@vladikoff
The new engines are only supported in Firefox >= 56. `addresses` is always
supported, `creditcards` is only supported if the browser includes
it in it's list of supported engines when requesting fxaccounts:fxa_status.

fixes #5087
2017-07-01 01:33:00 +01:00
Ryan Feeley 67bd80aa89 Add non-breaking space between mistyped and number (#5172) r=@shane-tomlinson
To avoid a line break on a two word link, I have replaced the
space in Mistyped number? with a non-breaking unicode 
space. We should probably be doing this more often in other 
places to avoid "typographic orphans".
2017-07-01 01:07:34 +01:00
Ryan Feeley e80b5582ed chore(text): Put Back link on bottom (#5184) r=@shane-tomlinson
Looked weird with one word link above big sentence link.

Shorten "resend" text to better fit on mobile.
2017-07-01 01:06:51 +01:00
Ryan Feeley a779203def chore(text): Centered blue message (#5191) r=@shane-tomlinson
The blue message should be centered, and the close X should be a little higher.
2017-06-30 21:44:12 +01:00
Ryan Feeley 078f1031e9 chore(text): Remove unneeded periods (#5187) r=@shane-tomlinson
Got rid of periods on two links
2017-06-30 21:31:37 +01:00
Ryan Feeley 2ba1290a38 chore(text): Removed fake bold and a period (#5182) r=vladikoff
We don't load a bold font, so I removed the strong tag, and also a stray period on the link
2017-06-30 09:54:41 -07:00
Ryan Feeley 4517cde23d chore(text): Removed stray period and underline (#5183) r=vladikoff
Make it tidier
2017-06-30 09:54:05 -07:00
Ryan Feeley 723a296055 chore(text): Removed pad class (#5190) r=vladikoff
Noticed this AMO migration message had a pad. Doesn't need it, so I removed it.
2017-06-30 09:53:40 -07:00
Ryan Feeley b04e2a027b chore(text): Removed click here (#5189) r=vladikoff
Tap is on touch device, click on mobile. I removed the click language.
2017-06-29 20:56:44 -07:00
Shane Tomlinson 8f1ddd1411 refactor(client): Fix "context" data setting w/ mixins (#5174) r=@philbooth
What is the problem?
When rendering a template, or translating a string, a view's `context()` function returns an object.
This paradigm makes it almost impossible for `context` to be overridden easily in mixins.

How does this fix the problem?
First, rename `context` to `updateContext`. Instead of having `updateContext` return an object,
pass in a Backbone model that each `updateContext` method can update. Mixins can override
`updateContext` and set the data on the passed in model.
2017-06-29 22:34:23 +01:00
Ryan Feeley d12ce201ff fix(sign-in): Put registration links on left/top (#5123) r=@shane-tomlinson
Put registration links on left OR top (responsive) based on feedback that some 
users struggle to find the registration links.
2017-06-22 13:04:11 +01:00
Shane Tomlinson d6d416fc56 fix(cwts): Remove the leftover CWTS styles. (#5166) r=vladikoff
.extra-links-choose-what-to-sync is no longer needed, removing.
2017-06-21 12:41:44 -04:00
Ryan Feeley 33677076ea fix(CWTS): removed desktop-only caveat (#5165) r=vladikoff
Add-ons, preferences, and soon addresses and credit cards will not be in parity on Android. I don't think this point in the process is the right time to mention it. Few care, and those that do won't be noticing here.
2017-06-21 12:33:48 -04:00
Shane Tomlinson ccbfa6c7b7 refactor(broker): Clean up the fx-sync-channel broker. (#5163) r=vladikoff
This does nothing but shift bits around so that related
concepts (*_LOGIN_FIELDS) are placed together.

Extracted from #5158
2017-06-21 11:02:23 -04:00
Phil Booth d7c576f701 feat(metrics): emit flow events for newsletter subscription
https://github.com/mozilla/fxa-content-server/pull/5160
r=shane-tomlinson
2017-06-20 12:04:17 +01:00
Vlad Filippov 645b49381b feat(oauth): support PKCE oauth parameters (#5126) r=shane-tomlinson 2017-06-18 20:52:19 -04:00
Udara Weerasinghege f0502acc25 fix(styles): add hover state to primary buttons (#5157) r=vladikoff 2017-06-18 19:52:06 -04:00
Shane Tomlinson d3a5f4d15f feat(experiments): Internalize experiment rules. (#4902) r=vladikoff
Remove able. All grouping rules have been imported
to app/scripts/lib/experiments/grouping-rules.

Documentation has been added on how to create a new
grouping rule, look at
app/scripts/lib/experiments/grouping-rules/README.md

fixes #4893
2017-06-15 14:31:42 -04:00
Shane Tomlinson 3cca54ebee feat(brokers): Add brokers for `mob_android_v1` and `mob_ios_v1` (#5084) r=@philbooth
When the user verifies their email, a `fxaccounts:verified` message is sent over the WebChannel.

fixes #5029
2017-06-15 13:47:43 +01:00
Ryan Feeley 5a9db37c75 fix(strings): update strings in confirm and unblock r=vladikoff
Rewrote copy to omit the term "better" as users interpreted it as an optional step.
2017-06-14 18:55:29 -04:00
Shane Tomlinson aba3a1549d refactor(broker): Extract `finishOAuthFlowIfOriginalTab` to share between methods. (#5141) r=@philbooth
This is extracted from #5090 with the intent to make that easier to review.
2017-06-14 16:35:14 +01:00
Vlad Filippov 5be33ef091 feat(settings): Reorder settings so display name is below account picture (#5139), r=@vbudhram 2017-06-13 14:02:25 -04:00
vladikoff f4d138cc6e fix(strings): update "Why Sync multiple devices?"
Fixes #5035
2017-06-13 12:21:54 -04:00
Vijay Budhram 5735b07777 feat(emails): Update verification email sent string (#5135) r=vladikoff,shane-tomlinson 2017-06-13 10:44:24 -04:00
Shane Tomlinson b8d7e567e4 feat(metrics): Add a `flow.signup.link.signin` flow event. (#5116) r=@philbooth
This required a larger change than I had hoped. The external-links-mixin
was capturing the click and then calling `event.stopImmediatePropagation()`
on the event, meaning the click handler in the flow-events-mixin was
never called. :/

fixes #4680
fixes #5115
2017-06-07 17:51:12 +01:00
Shane Tomlinson 25b4c302cb feat(sms): Add support for the SMS signinCode (#5092) r=@vbudhram, @philbooth
To enable signinCodes to be sent, add the `signinCode=true` query parameter.

fixes #5060
2017-06-07 15:00:18 +01:00
Shane Tomlinson dd656b52c4 Merge branch 'train-88' 2017-06-01 22:11:59 +01:00
Shane Tomlinson c20bc4c020 feat(CAD): Make it easier to find `.smsStatus` errors in the logs. (#5121) r=@philbooth
Add an `.smsStatus` suffix to the error context, which is included
in messages sent to DataDog, e.g.,:

error.verify-email.smsStatus.auth.999

issue #5109
2017-06-01 22:07:47 +01:00
Shane Tomlinson d4c0343c74 fix(WebChannel): Fix the startup hang if the UA errors fetching fxaccounts:fxa_status (#5117) r=@philbooth, @vbudhram
If the browser responds to an fxaccounts:fxa_status message with a `No Such Webchannel`
error, that means the UA either does not support the channel name, or is not set up
to communicate with this FxA server. In either case, FxA and the UA cannot communicate
using WebChannels.

If this happens, log the error and set the `fxaStatus` broker capability to `false`.
This will cause the session to use state stored in localStorage rather than the
state stored by the browser.

fixes #5114
2017-06-01 21:50:43 +01:00
Shane Tomlinson b639e0a028 revert(sms): Re-add the "Maybe later" link. (#5119) r=@vbudhram
This reverts commit 1c71687b34.

fixes #5117
2017-06-01 15:54:05 +01:00
Shane Tomlinson 8c55d183b5 feat(CAD): Log clicks on app store links into flow metrics. (#5113) r=@philbooth
New flow events:

* flow.sms.link.app-store.(android|ios)
* flow.sms.sent.link.app-store.(android|ios)
* flow.reset-password-confirmed.link.app-store.(android|ios)
* flow.reset-password-verified.link.app-store.(android|ios)
* flow.secondary-email-verified.link.app-store.(android|ios)
* flow.signin-confirmed.link.app-store.(android|ios)
* flow.signin-verified.link.app-store.(android|ios)
* flow.signup-confirmed.link.app-store.(android|ios)
* flow.signup-verified.link.app-store.(android|ios)

fixes #5112
2017-06-01 14:38:24 +01:00
Shane Tomlinson a338756e8d fix(sms): Handle errors to /sms/status (#5110) r=@philbooth
Before this fix, if a call to /sms/status failed,
signup confirmation would appear to fail with an
"Unexpected error".

Instead of failing, log and drop errors to /sms/status.

fixes #5109
2017-06-01 10:57:06 +01:00
Shane Tomlinson 277e046a3a refactor(fxa-client): Reduce boilerplate when delegating to fxa-js-client. (#5108) r=@philbooth
Use a `createClientDelegate` method to pass all method call parameters
directly to the delegated to method in the fxa-js-client.

Also removed fxa-client->signOut, the functionality
was a subset to the more full featured sessionDestroy.

Finally, add lots of documentation.

Extracted from #5092
2017-05-31 10:57:36 +01:00
Shane Tomlinson c8fba8ffda fix(test): Fix "Upgrade from account that has `accountData`" (#5107) r=vladikoff,philbooth
With the changes to fetch user state brom the browser, we were
attempting to check the signed in account before the storage
formats were updated. An Account model was created with `accountData`,
causing an exception to be thrown.

Updates the stored accounts before checking for
the signed in account.

Since a functional test caught this, no new functional tests
were added, only unit tests.

fixes #5104
2017-05-30 09:07:16 -04:00
Shane Tomlinson 921be2fa59 Merge branch 'train-87' 2017-05-26 12:57:35 +01:00
Shane Tomlinson d7298f5a11 fix(sign_in): Fix how the listener is bound for account->chang:accessToken (#5103) r=@philbooth
We were binding using `account.on` in `beforeRender`. This didn't cause any
visible problems, but caused two problems behind the scenes:

1. The view to be retained in memory after being torn down because the
   account kept a reference to the View.
2. If the accessToken was invalidated after the view was destroyed, the
   *view would re-render anyways*, just not visibly.

Using view.listenTo, the listener is removed from the account whenever
the view is torn down. In addition, this is only done in afterVisible
so that only one listener is ever bound. If done in `beforeRender`,
a new listener was attached on every render.

Not attached to an issue.
2017-05-25 13:42:12 +01:00
Shane Tomlinson 18fa0d584e feat(client): Sync state with the browser! (#4695) r=@philbooth
Adds a new WebChannel command, `fxaccounts:fxa_status`. In Firefox Desktop >= 55, 
it uses this command to request the browser's view of the world.
2017-05-25 11:45:03 +01:00
Shane Tomlinson 3f665b627a refactor(test): Modernize the sign_in view unit test. (#5102) r=self
Use fat arrows to make code more consise, let, const, etc.
Only render to the DOM when absolutely needed to speed up tests.

This is such a low-risk unit test only change that I self-merged.
2017-05-25 11:15:57 +01:00
Shane Tomlinson efea8259ee refactor(mixins): Move search-param-mixin and user-agent-mixin to /lib (#5099) r=vladikoff
The move is so these mixins can be used by any objects. This is an extraction
from #4695.

issue #4252
2017-05-24 13:52:29 -04:00
Shane Tomlinson 5f7d8b6cc5 refactor(test): In app-start.js, convert to fat arrows. (#5100) r=vladikoff
This is an extraction from #4695
issue #4252
2017-05-24 13:50:31 -04:00
Vijay Budhram dae0ff61d8 feat(emails): Add emails feature flag check (#5093), r=@shane-tomlinson 2017-05-24 09:06:15 -04:00
Vijay Budhram 0fe39b84cc feat(emails): Disable secondary emails for everyone (#5095) r=vladikoff 2017-05-23 14:05:16 -04:00
Shane Tomlinson a574d841d7 feat(CAD): Add CAD to the signup tab in firstrun (#5026) r=@philbooth, @ryanfeeley
fixes #4944
2017-05-19 18:28:45 +01:00
Shane Tomlinson 252ba6eff1 fix(app-store): Open app-store links in a new tab. (#5083) r=@philbooth
fixes #5079
2017-05-19 13:20:15 +01:00
Shane Tomlinson 6ec3f64f66 refactor(client): Clean up invoke* using ES2015. (#5075) r=@philbooth
Update invokeBrokerMethod, invokeBehavior, and invokeHandler
to use ES2015 rest & spread operators.

Also make `invokeBehavior` always return a promise.
2017-05-18 12:53:44 +01:00
Shane Tomlinson 218ef6cfae fix(devices): Add the 1800 ms artificial delay when clicking `Refresh` (#5074) r=@vbudhram, @philbooth
Done by having the progress indicator decorator look on the target element
for a `data-min-progress-indicator-ms` attribute. If it exists, wait for
the time to elapse before completing the submit action.

Use this in the "settings clients" functional tests to ensure the refresh
has completed to continue with the tests.

fixes #4570
fixes #5071
2017-05-18 10:20:28 +01:00
Shane Tomlinson f1cbf2b272 refactor(metrics): Remove `viewToId` and helpers.testIsViewLogged (#5069) r=@philbooth
They were only used in one place and didn't provide much value.

Done while working on #5026
2017-05-17 16:52:43 +01:00
Shane Tomlinson 2ab905a235 Merge branch 'train-87' 2017-05-17 15:04:31 +01:00
Shane Tomlinson 4542ccd057 fix(broker): Fix the POST /metrics validation error w/ FxSync broker. (#5067) r=@philbooth
Server validation allows `-`, not `_`. This updates the FxSync
broker's type to be consistent with others and use `-` instead of `_`.

fixes #5066
2017-05-17 15:01:27 +01:00
Shane Tomlinson 3224eb8043 fix(firstrun): Show the `continue to Firefox Sync` subheader in the firstrun page (#5064) r=@ryanfeeley, @philbooth
fixes #5063
2017-05-17 09:35:52 +01:00
Shane Tomlinson 4bbbfb5544 fix(cad): Always show app store buttons for /connect_another_device, /sms (#5061) r=@vbudhram
The app store buttons were only shown if ?service=sync was specified on
the URL. This caused confusion whenever loading the two screens during
manual testing. Since these screens are only shown for the Sync flow,
always show them.

fixes #4948
2017-05-16 21:20:30 +01:00
Vlad Filippov 3064f0323c fix(devices): bring back sync start date to device view (#5058) r=vbudhram 2017-05-16 16:04:29 -04:00
Vlad Filippov 314e593ea2 feat(emails): UX for additional emails r=vladikoff,vbudhram,shane-tomlinson
Fixes #4756
2017-05-15 18:08:57 -04:00
Shane Tomlinson bdb02dcb80 refactor(channels): Place all web channel command declarations in one location. (#5055) r=@philbooth
The web channel command declarations were sprinkled throughout several modules.
This centralizes the location to lib/channels/web.js

This does not fix #3432, but takes the first step - centralizing where
the commands are declared.

issue #3432
2017-05-15 14:29:01 +01:00
Shane Tomlinson 676a34e589 fix(reliers): Fix problems with OAuth reliers that specify service=sync. (#5050) r=@vbudhram
If an OAuth relier specified service=sync, the Sync relier model was used
and caused the UI to say "Sign in to continue to Sync".

This could cause confusion.

This ensures that if the user is in an OAuth flow, the OAuth relier model
is used. OAuth relier models no longer import the `service` query parameter
for signin and signup, only for verification where `service` is used
as `clientId`.
2017-05-15 11:02:41 +01:00
Vlad Filippov 8556c14ff1 fix(clients): open devices SUMO help in a new window (#5038)
Fixes bz1360126
2017-05-13 22:05:25 -04:00
Shane Tomlinson 9df2f8ff42 refactor(brokers): Split off `web`, `fx-sync-channel` auth brokers. (#4995) r=@vbudhram
Why this change?
The long term intent is to completely remove the implicit state
machine from within the views. To do so, the implicit state machine
needs to be made explicit. The state machine is unique for each
browser integration. Auth brokers are created for each integration,
and are currently our best mechanism for creating per-integration
state machines.

What are the broker updates?
* `web` is for people who browse directly to the site.
* `fx-sync` - re-purposed to define generic Sync behaviors, does not
  contain any references to channels. Used when someone signs up for
  Sync and verifies in a 2nd browser.
* `fx-sync-channel` is the former `fx-sync` broker, it defines Sync
  behaviors but has channels.

Since each integration will have its own broker, which defines its own
behaviors, we can remove `isDirectAccess` from the relier.
2017-05-10 11:01:16 +01:00
Shane Tomlinson 1c71687b34 refactor(sms): Remove the "Maybe later" link. (#5045) r=vladikoff
@ryanfeeley and @davismtl both agree that "Maybe later"
should be removed from the /sms screen. Doing so will
probably boost the number of users who send an SMS,
and most /connect_another_device screens show the
user the same app store links as showed on the /sms page.

fixes #5044
2017-05-09 13:19:38 -04:00
Shane Tomlinson 1a68000cb9 fix(sms): Update SMS legal text to cover more countries. (#5034) r=@philbooth
SMS legal text is made more generic to cover any country
for which the feature is enabled.

fixes #4945
2017-05-04 13:48:05 +01:00
Shane Tomlinson 0a337ae936 refactor(client): Automate link transforming for OAuth integrations. (#5033) r=@philbooth
service-mixin calls `transformLinks` in afterRender instead of
calling `transformLinks` imperatively in each view.

Not attached to any issue.
2017-05-04 12:22:26 +01:00
morrme d5279cad66 fix(strings): modify success message (#5030) r=vladikoff
Fixes: #5012
2017-05-03 11:55:33 -04:00
Vijay Budhram 22c58ffac4 fix(css): Use warning style when in disconnect client modal (#5022) r=vladikoff 2017-05-02 11:15:26 -04:00
Vlad Filippov 5f1af068cf fix(eslint): update to latest eslint, style fixes (#5020), r=@vbudhram 2017-05-01 16:39:08 -04:00
Vlad Filippov ff87ed3b0a fix(userAgent): fix parseVersion for bad user agents (#5018), r=@vbudhram 2017-05-01 10:02:22 -04:00
Shane Tomlinson 3ceb9fbb69 refactor(brokers): Rename redirect.js to oauth-redirect.js (#5017) r=vladikoff
This name is a bit more explicit.
2017-04-28 11:35:20 -04:00
Shane Tomlinson c897b6d1ce refactor(gravatar): Remove gravatar (#4927) r=vladikoff
Fixes #4931
2017-04-28 09:58:41 -04:00
Vlad Filippov d3668b997d feat(devices): add OS device icons (#4975) r=shane-tomlinson
Fixes #4049
Fixes #4985
2017-04-26 12:32:33 -04:00
Shane Tomlinson e80fba2015 refactor(test): Remove the oauth `keys` tests. (#5002) r=vladikoff
`keys` support was removed a while ago, yet the tests remain. This removes
the leftovers from the tests, as well as from the relier.

fixes #5001
2017-04-26 12:22:08 -04:00
Ryan Kelly 6e9a824813 Disable web sessions by default (#4999) r=vladikoff 2017-04-26 10:45:49 -04:00
Shane Tomlinson 5515f609a1 fix(sms): Fix the SMS experiment bucketing logic. (#4977) r=vladikoff
Issue #4944


Users in the SMS "control" group must be in CAD, we are comparing
SMS against the CAD screens, not the general population.

This PR makes that happen. The SMS/CAD selection logic is extracted
into its own mixin so that it can be independently tested and
used on the "signup" page too.

From the experiment-mixin, trigger `flow.initialized` which
will force the flow model to initialize for experiments
that are created at runtime.
2017-04-26 10:36:04 -04:00
Shane Tomlinson 7648a8c7dd refactor(validation): Use VAT for validation everywhere on the front. (#4981) r=@philbooth
What does this do?
Replaces direct references to lib/validate w/ lib/vat.
VAT still delegates to Validate, the next step is for VAT to
take over responsibilities of Validate.

WHY?
While I was was working on using the same RegExps for both
the front and back-ends, I grew frustrated that the
front-end had multiple ways of validating. The same
mechanism should be used everywhere on the frontend.

Why did so many tests change?
The notifier now fully validates the uid and email fields. Tests that
expected proper uids and emails had to be updated. Some other tests
tried to sign in w/o a sessionTokenContext.
2017-04-25 12:27:06 +01:00
Shane Tomlinson ecc007c6f8 feat(channels): Unify how channels handle errors. (#4889) r=vladikoff
Pass errors back to the caller of `request`, if possible.

This will be used when requesting user data from the browser,
if for whatever the web channel returns an error, the user
should continue with the flow, so the caller should be
responsible for stopping the flow.
2017-04-21 15:34:22 -04:00
Princi Vershwal 1760d1e983 fix(setting): Made Add… buttons blue. (#4823) r=@shane-tomlinson
fixes #4818

This is excellent work @vershwal, thanks for working through it with me! r+
2017-04-21 13:41:40 +01:00
Vlad Filippov e39410c42e feat(sessions): make sessions available to all (#4964) r=vbudhram 2017-04-19 11:37:35 -04:00
Shane Tomlinson c8f854a2e7 fix(test): Fix the failing unit tests in Chrome. (#4963) r=vladikoff
I made the assumption that tests would be run on Firefox Desktop. Not always
the case. Force the expected UA.

fixes #4793
2017-04-19 09:37:10 -04:00
Shane Tomlinson a0b0d1f495 fix(metrics): Allow entrypoints with the fxa: prefix (#4962) r=@philbooth
Also convert the `connect_another_device` entrypoint to `fxa:connect_another_device`

fixes #4887
2017-04-19 13:25:20 +01:00
Ryan Feeley d4f87864e1 fix(sessions): made web session icon match add-ons colour r=vladikoff
Fies #4951
2017-04-17 15:59:22 -04:00