Commit Graph

16 Commits (b437a2559dd62207272bda52221c46e7c4543230)

Author SHA1 Message Date
David Baker b437a2559d PR feedback 2017-10-27 18:59:13 +01:00
David Baker 5312a869e4 Try lowercase username on login
Fixes https://github.com/vector-im/riot-web/issues/5446
2017-10-27 18:36:59 +01:00
Luke Barnard d3f9a3aeb5 Run eslint --fix
Fixing 1000s of lint issues. Some rules cannot be `--fix`ed but this goes some way to linting the entire codebase.
2017-10-11 17:56:17 +01:00
Richard van der Hoff 0254d2b3a2 q(...) -> Promise.resolve
```
find src test -name '*.js' | xargs perl -i -pe 's/\b[qQ]\(/Promise.resolve(/'
```
2017-07-12 18:05:08 +01:00
Richard van der Hoff a06bd84213 replace imports of `q` with bluebird
update `package.json`

```
find src test -name '*.js' |
   xargs perl -i -pe 'if (/require\(.[qQ].\)/) { $_ = "import Promise from '\''bluebird'\'';\n"; }'

find src test -name '*.js' |
   xargs perl -i -pe 'if (/import [qQ]/) { $_ = "import Promise from '\''bluebird'\'';\n"; }'
```
2017-07-12 18:05:08 +01:00
Richard van der Hoff 1f719b3f7d Avoid getting stuck in a loop in CAS login
498ea53 made it so that the #/login URL fragment was prioritised over the token
params in the query string; unfortunately that also means that CAS login gets
stuck in a loop where you always get redirected back to the login view.

Prioritising the URL fragment over the token params may or may not be the
correct thing to, but I also think it's incorrect that we ask the CAS server to
redirect us back to #/login. Accordingly, the easiest fix here is just to clear
the URL fragment before redirecting to CAS.
2017-06-16 13:06:28 +01:00
David Baker d691c891e7 Move all login error string generation into view
This makes all the various hits done by login report the same
useful error messages and gets rid of the broken ones like printing
the http status code even if it was undefined. Also add text for
the case of overzealous browser extensions because lots of people
get bitten by it.
2017-06-08 15:49:48 +01:00
David Baker ec9a436625 Formatting 2017-06-08 11:56:48 +01:00
Kegan Dougal a0c21854a9 Make it compile 2017-06-01 15:45:31 +01:00
Kegan Dougal f75e714c3a More translations.. 2017-06-01 15:18:06 +01:00
David Baker 2c1ac29d30 Send legacy parameters on login call
To support login on old HSes
2017-03-14 14:37:18 +00:00
David Baker 878413f6a4 Support msisdn signin
Changes from https://github.com/matrix-org/matrix-react-sdk/pull/742
2017-03-14 11:50:13 +00:00
Richard van der Hoff 2786fb0f46 Revert "Support registration & login with phone number (#742)"
This reverts commit 0269562383.

This breaks against the current synapse release. We need to think more
carefully about backwards compatibility.
2017-03-09 18:32:44 +00:00
David Baker 0269562383 Support registration & login with phone number (#742)
* WIP msisdn sign in

* A mostly working country picker

* Fix bug where you'dbe logged out after registering

Stop the guest sync, otherwise it gets 401ed for using a guest
access token for a non-guest, causing us to beliebe we've been
logged out.

* Use InteractiveAuth component for registration

* Fix tests

* Remove old signup code

* Signup -> Login

Now that Signup contains no code whatsoever related to signing up,
rename it to Login. Get rid of the Signup class.

* Stray newline

* Fix more merge failing

* Get phone country & number to the right place

* More-or-less working msisdn auth component

* Send the bind_msisdn param on registration

* Refinements to country dropdown

Rendering the whole lot when the component was rendered just makes
the page load really slow, so just show 2 at a time and rely on
type-to-search.

Make type-to-search always display an exact iso2 match first

* Propagate initial inputs to the phone input

* Support msisdn login

* semicolon

* Fix PropTypes

* Oops, use the 1qst element of the array

Not the array of object keys which has no particular order

* Make dropdown/countrydropdown controlled

* Unused line

* Add note on DOM layout

* onOptionChange is required

* More docs

* Add missing propTypes

* Don't resume promise on error

* Use React.Children to manipulate children

* Make catch less weird

* Fix null dereference

Assuming [0] of an empty list == undefined doesn't work if you're
then taking a property of it.
2017-03-09 10:59:22 +00:00
David Baker 88586a0823 Oops, lost defaultDeviceDisplayName 2017-03-02 15:01:56 +00:00
David Baker 51467506f8 Port registration over to use InteractiveAuth
These changes are moved over from the dbkr/msisdn_signin branch
2017-02-24 11:41:23 +00:00