Commit graph

320 commits

Author SHA1 Message Date
Richard van der Hoff
e6d7eedbe6 Remove NeedToRegisterDialog
- since it's no longer used anywhere
2017-06-12 08:36:41 +01:00
Kegan Dougal
9baaf5499f Linting 2017-06-08 14:58:54 +01:00
Kegan Dougal
c57823a31d Merge branch 'develop' into kegan/translation-tamarin 2017-06-08 14:19:56 +01:00
Kegan Dougal
1c58a9cd5e Everything but src/components/views/rooms 2017-06-08 12:33:29 +01:00
Kegan Dougal
0f4028da07 Add more translations.. 2017-06-08 09:44:58 +01:00
Matthew Hodgson
8228db88d2 oops, fix more i18n var name typos 2017-06-07 18:28:49 +01:00
Matthew Hodgson
ef2fedc3a9 fix missing translations and typos in i18n 2017-06-07 18:24:35 +01:00
Luke Barnard
29da25529c Make it backwards compatible
Hit the user_directory API and if M_UNRECOGNIZED, do a local search and continue to search locally therein.
2017-06-07 17:53:58 +01:00
Luke Barnard
68ddf35db4 Use then, catch, done and display any errors that occur during search 2017-06-07 17:33:15 +01:00
Luke Barnard
3b6599dcdc Use user_directory endpoint to populate ChatInviteDialog
Also attempt to slightly improve the feedback given when searching. There is still room for improvement - it's not totally obvious whether to display a spinner because it's quite jarring were it to replace the dd. This does mean that "No results" will flash awkardly between two queries, neither of which return any results.
2017-06-07 16:05:36 +01:00
Richard van der Hoff
27e5098e00 Merge remote-tracking branch 'origin/develop' into rav/handle_received_room_key_requests 2017-06-07 15:44:33 +01:00
Richard van der Hoff
c1151fd31c Merge branch 'develop' into rav/handle_received_room_key_requests 2017-06-07 15:37:38 +01:00
Luke Barnard
53ea41e8a5 Merge branch 'develop' into new-guest-access 2017-06-07 12:08:37 +01:00
Richard van der Hoff
32e3ea0601 Address review comments 2017-06-05 17:58:11 +01:00
Luke Barnard
619830617a Merge branch 'develop' into luke/ilag-i18n
In order to get ILAG internationalised

Conflicts:
	src/components/structures/LoggedInView.js
	src/components/structures/MatrixChat.js
	src/components/views/dialogs/ChatCreateOrReuseDialog.js
	src/components/views/dialogs/SetDisplayNameDialog.js
	src/createRoom.js
	src/i18n/strings/en_EN.json
2017-06-05 16:08:03 +01:00
Luke Barnard
6125395675 _t for SetMxIdDialog 2017-06-05 15:36:10 +01:00
Michael Telatynski
464863acd6 remove unused imports
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2017-06-02 21:35:55 +01:00
Michael Telatynski
5e85723b5a fix typo and missing import
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2017-06-02 21:09:19 +01:00
Luke Barnard
6e84b6e996 Display profile errors better 2017-06-02 11:50:58 +01:00
Luke Barnard
defecb1b14 Implement /user/@userid:domain?action=chat
This is a URL that can be used to start a chat with a user.
 - If the user is a guest, setMxId dialog will appear before anything and a defered action will cause `ChatCreateOrReuseDialog` to appear once they've logged in.
 - If the user is registered, they will not see the setMxId dialog.

fixes https://github.com/vector-im/riot-web/issues/4034
2017-06-02 11:36:18 +01:00
Kegan Dougal
f54c182eb1 Add remaining strings for vector-im/riot-web#4151 2017-06-02 10:47:08 +01:00
Richard van der Hoff
d5bc24d9f7 Initial implementation of KeyRequestHandler, KeyShareDialog etc 2017-06-01 18:40:04 +01:00
Richard van der Hoff
cbbed3f544 Fixes to i18n code 2017-05-31 18:31:10 +01:00
Matthew Hodgson
e30e45a82c Merge branch 'develop' into new-guest-access 2017-05-30 21:05:07 +01:00
Matthew Hodgson
93a35dc07a Merge branch 'develop' into t3chguy/piwik 2017-05-30 15:58:55 +01:00
Marcel
70e7d81093 More i18n strings (#963)
* Add i18n for E2E import and Export Dialogs

Signed-off-by: MTRNord <mtrnord1@gmail.com>

* Add various previous missing i18n strings

Signed-off-by: MTRNord <mtrnord1@gmail.com>

* Translate CreateRoomButton

Signed-off-by: MTRNord <mtrnord1@gmail.com>

* Add ChatInviteDialog and fix missing to.

Signed-off-by: MTRNord <mtrnord1@gmail.com>

* Add ConfitmRedactDialog translations

Signed-off-by: MTRNord <mtrnord1@gmail.com>

* Add DeactivateAccountDialog translations

Signed-off-by: MTRNord <mtrnord1@gmail.com>

* Add DeviceVerifyDialog translations

Signed-off-by: MTRNord <mtrnord1@gmail.com>

* Add SessionRestoreErrorDialog translations

Signed-off-by: MTRNord <mtrnord1@gmail.com>

* Add SetDisplayNameDialog translations

Signed-off-by: MTRNord <mtrnord1@gmail.com>

* Add UnknownDeviceDialog translations

Signed-off-by: MTRNord <mtrnord1@gmail.com>

* Add AddressTile translations

Signed-off-by: MTRNord <mtrnord1@gmail.com>

* Add DeviceVerifyButtons translations

Signed-off-by: MTRNord <mtrnord1@gmail.com>

* Add Dropdown translations

Signed-off-by: MTRNord <mtrnord1@gmail.com>

* Add UserSelector translations

Signed-off-by: MTRNord <mtrnord1@gmail.com>

* Add CaptchaForm translations

Signed-off-by: MTRNord <mtrnord1@gmail.com>

* Add CasLogin translations

Signed-off-by: MTRNord <mtrnord1@gmail.com>

* Add CustomServerDialog translations

Signed-off-by: MTRNord <mtrnord1@gmail.com>

* Add InteractiveAuthEntryComponents translations

Signed-off-by: MTRNord <mtrnord1@gmail.com>

* Add LoginFooter translations

Signed-off-by: MTRNord <mtrnord1@gmail.com>

* Add RegistrationForm translations

Signed-off-by: MTRNord <mtrnord1@gmail.com>

* Add ServerConfig translations

Signed-off-by: MTRNord <mtrnord1@gmail.com>

* Add MAudioBody translations

Signed-off-by: MTRNord <mtrnord1@gmail.com>

* Add MImageBody translations

Signed-off-by: MTRNord <mtrnord1@gmail.com>

* Add MVideoBody translations

Signed-off-by: MTRNord <mtrnord1@gmail.com>

* Add TextualBody translations

Signed-off-by: MTRNord <mtrnord1@gmail.com>

* Add UnknownBody translations

Signed-off-by: MTRNord <mtrnord1@gmail.com>

* Add UrlPreviewSettings translations

Signed-off-by: MTRNord <mtrnord1@gmail.com>

* Add AuxPanel translations

Signed-off-by: MTRNord <mtrnord1@gmail.com>

* Add PresenceLabel translations

Signed-off-by: MTRNord <mtrnord1@gmail.com>

* fix syntax error

* weird space :P

* missing ','

* fix missing value

* fix json fail

* remove acidential added file

* fix another json fail
2017-05-30 15:09:57 +01:00
Luke Barnard
47bf5401fa Use KeyCode.ENTER instead of 13 2017-05-30 13:14:14 +01:00
Luke Barnard
952651c685 Allow pressing Enter to submit setMxId 2017-05-30 13:02:35 +01:00
Luke Barnard
4e4c670458 Improve ChatInviteDialog perf by ditching fuse, using indexOf and lastActiveTs() 2017-05-30 12:34:19 +01:00
Michael Telatynski
b65e4960a5 move Dialog analytics to Modal controller
mark title as required, it sorta is, why isn't this based on BaseDialog?

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2017-05-29 17:39:03 +01:00
Michael Telatynski
42e20c38f9 Merge branch 'develop' of github.com:matrix-org/matrix-react-sdk into t3chguy/piwik 2017-05-29 15:23:05 +01:00
Matthew Hodgson
df599890c5 add login link to SetMxIdDialog 2017-05-29 01:32:31 +01:00
Matthew Hodgson
1efc5c2b25 speed up SetMxIdDialog user check to 250ms as it was driving me MAD
i18nize new bottomleftmenu buttons
2017-05-28 23:28:40 +01:00
Matthew Hodgson
5c885922d9 Merge branch 'develop' into new-guest-access 2017-05-28 22:58:18 +01:00
Travis Ralston
1b6685c5da Merge branch 'develop' into travis/redact-to-remove 2017-05-28 17:45:32 -04:00
Michael Telatynski
fb3187b58e change event wording
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2017-05-28 13:26:33 +01:00
Michael Telatynski
98c2f9201b initial piwik stuff
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2017-05-27 20:47:09 +01:00
Luke Barnard
28094a9a66 Show "Something went wrong!" when errcode undefined 2017-05-26 13:13:57 +01:00
David Baker
443ab1add7 Put back default strings on dialogs
But make them work by calling _t in render rather than
getDefaultProps().

Also sort out some 'Warning!' strings
2017-05-25 18:20:48 +01:00
Luke Barnard
2265b59287 Remove warm-fuzzy after setting mxid 2017-05-25 14:54:28 +01:00
David Baker
5c359e63ab Bulk change counterpart imports
to use languageHandler wrapper func
2017-05-25 11:39:08 +01:00
Luke Barnard
298c5e4df3 Implement a store for RoomView
This allows for a truely flux-y way of storing the currently viewed room, making some callbacks (like onRoomIdResolved) redundant and making sure that the currently viewed room (ID) is only stored in one place as opposed to the previous many places.

This was required for the `join_room` action which can be dispatched to join the currently viewed room.

Another change was to introduce `LifeCycleStore` which is a start at encorporating state related to the lifecycle of the app into a flux store. Currently it only contains an action which will be dispatched when the sync state has become PREPARED. This was necessary to do a deferred dispatch of `join_room` following the registration of a PWLU (PassWord-Less User).

The following actions are introduced:
 - RoomViewStore:
    - `view_room`: dispatch to change the currently viewed room ID
    - `join_room`: dispatch to join the currently viewed room
 - LifecycleStore:
    - `do_after_sync_prepared`: dispatch to store an action which will be dispatched when `sync_state` is dispatched with `state = 'PREPARED'`
 - MatrixChat:
    - `sync_state`: dispatched when the sync state changes. Ideally there'd be a SyncStateStore that emitted an `update` upon receiving this, but for now the `LifecycleStore` will listen for `sync_state` directly.
2017-05-24 16:56:13 +01:00
David Baker
d419c42a4f Squash merge https://github.com/matrix-org/matrix-react-sdk/pull/801 2017-05-23 15:16:31 +01:00
Luke Barnard
05aaa599cc Merge branch 'develop' into new-guest-access
Conflicts:
	src/components/structures/MatrixChat.js
2017-05-22 16:19:10 +01:00
Richard van der Hoff
fc08dc33c6 Group e2e keys into blocks of 4 characters
Hopefully this will make them a bit easier to compare.
2017-05-22 12:01:09 +01:00
Richard van der Hoff
574b820d11 Factor out DeviceVerifyDialog 2017-05-22 11:12:36 +01:00
Luke Barnard
96c3bf56f8 Implement warm-fuzzy success dialog for SetMxIdDialog 2017-05-19 09:43:56 +01:00
David Baker
ebfafb3639 Revert "Merge pull request #807 from matrix-org/matthew/quick-search"
This reverts commit 0ad1d8caf3, reversing
changes made to 1189368aab.
2017-05-16 16:11:01 +01:00
David Baker
ff9c40472a Revert "Merge pull request #822 from t3chguy/BaseDialog_restore_focus"
This reverts commit 0ac836919d, reversing
changes made to 7e07ffd55f.
2017-05-16 14:50:29 +01:00
David Baker
19dcd83aeb Revert "Merge pull request #841 from matrix-org/luke/fix-double-dialogs"
This reverts commit 1913a32fbd, reversing
changes made to 0c16298c45.
2017-05-16 14:50:19 +01:00
David Baker
6bd7af2917 Revert "Merge pull request #867 from matrix-org/t3chguy/BaseDialog-patch1"
This reverts commit 3549ff2543, reversing
changes made to 1db677141e.
2017-05-16 14:00:09 +01:00
Luke Barnard
f199f3599e Replace NeedToRegisterDialog /w SetMxIdDialog
This uses MatrixChat's `view_set_mxid`
2017-05-15 17:31:26 +01:00
Luke Barnard
5151264f60 Merge branch 'develop' into new-guest-access
Conflicts:
	src/component-index.js
2017-05-11 13:22:30 +01:00
Luke Barnard
6257bfcd87 Add prop type for onDifferentServerClicked 2017-05-10 14:28:48 +01:00
Luke Barnard
ad2ed12980 Redesign mxID chooser, add availability checking
Requires https://github.com/matrix-org/matrix-js-sdk/pull/432 for availability checking.

Changes:
 - Redesign the dialog to look more like https://github.com/vector-im/riot-web/issues/3604#issuecomment-299226875
 - Attempt to fix wrong password being stored by generating one per SetMxIdDialog (there's no issue tracking this for now, I shall open one if it persists)
 - Backwards compatible with servers that don't support register/availability - a spinner will appear the first time a username is checked because server support can only be determined after a request.
 - Rate-limited by a 2s debounce
 - General style improvements
2017-05-10 14:22:17 +01:00
Michael Telatynski
f02e659fb7 Consume key{up,down,pressed} events
so they don't trigger other things bubbling up
until Modal is closed
2017-05-09 11:27:06 +01:00
Michael Telatynski
bd32df4ef6 comment wording 2017-05-07 20:58:30 +01:00
Michael Telatynski
360f1cd250 completely missed the ESC check
I need sleep
2017-05-07 20:57:54 +01:00
Michael Telatynski
78e7272344 Fixes 2 issues with Dialog closing
+ Upload Confirmation dialog would just change focus on ESC and not close
+ Keywords Dialog in UserSettings would also close UserSettings because event bubbled up
2017-05-07 20:43:42 +01:00
Michael Telatynski
18ba5d3e49 fix typo
made in #849
2017-05-03 12:39:24 +01:00
Luke Barnard
4f71f4c331 Store mx_pass at the same point as access_token
So that we don't overwrite the existing one every time we try to register.
2017-05-02 10:07:06 +01:00
Luke Barnard
a887af9f92 copyright 2017-05-02 09:56:14 +01:00
Luke Barnard
8774100508 Initial implementation: SetDisplayName -> SetMxIdDialog
- Replaces SetDisplayNameDialog with SetMxIdDialog. This new dialog will use InteractiveAuth to authenticate a user with their chosen mxid.

De-scoped:
 - style tweaks for the InteractiveAuth in the dialog (capcha) and error message.
 - checking for mxid availability
2017-04-28 13:22:55 +01:00
Luke Barnard
5f0ecc588f Fix dialog reappearing after hitting Enter
Fixes https://github.com/vector-im/riot-web/issues/3714

https://github.com/vector-im/riot-web/issues/3714#issuecomment-297460620 :
> It's as if there are two dialogs and as one closes, the other one appears. For some reason matrix-org/matrix-react-sdk#822 is causing this.
> I've realised it's because the `priorActiveElement` is probably the button that opened the dialog. If this is focused and the enter key is released, this triggers a keyPress which fires once the dialog has closed and the button has been focused 😬 the BaseDialog only calls stopPropagation _onKeyDown.

The soln. was to submit the dialog as finished `onKeyUp`. This means the `priorActiveElement` is focussed after any key events that should be associated with the dialog.
2017-04-26 17:37:52 +01:00
Luke Barnard
5c83d4d2ed Merge pull request #832 from t3chguy/ude_break_out_room
show the room name in the UDE Dialog
2017-04-25 10:04:23 +01:00
Michael Telatynski
e64b647799 show the room name in the UDE Dialog
especially useful when it appears after you switch rooms

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2017-04-25 09:26:21 +01:00
turt2live
e6fd380947 Change redact -> remove for clarity
Addresses vector-im/riot-web#2814

Non-technical users may not understand what 'redact' means and can more easily understand what 'Remove' does. See discussion on vector-im/riot-web#2814 for more information.

Signed-off-by: Travis Ralston <travpc@gmail.com>
2017-04-24 12:49:09 -06:00
Matthew Hodgson
a2be764681 display err.message to user if available in error msgs 2017-04-23 01:48:27 +01:00
Matthew Hodgson
34c1a8f3cf make autofocus explicit on errordialog as it autoFocus attr seems unreliable 2017-04-22 17:28:48 +01:00
Michael Telatynski
6a657a6555 Remember element that was in focus before rendering dialog
restore focus to that element when we unmount

also remove some whitespace because ESLint is a big bad bully...

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2017-04-22 05:44:27 +01:00
Matthew Hodgson
90f526bdeb autofocus doesn't seem to work on this button 2017-04-20 00:42:13 +01:00
David Baker
db3339de33 I still can't type 2017-03-27 17:03:59 +01:00
David Baker
9125c1b2cc I can't type 2017-03-27 17:00:05 +01:00
David Baker
a230354dbe Fix bug where you can't invite a valid address
Always show the entered text as an option if it's a valid address,
otherwise there's no way to invite an address that is valid and
also returns other mxids in the search results.

Fixes https://github.com/vector-im/riot-web/issues/3496
2017-03-27 16:40:01 +01:00
Matthew Hodgson
df63c779dd clarify that redact === delete 2017-03-19 02:34:25 +00:00
Keyvan Fatehi
25a4f4e3b6 Add ConfirmRedactDialog component
Signed-off-by: Keyvan Fatehi <keyvanfatehi@gmail.com>
2017-03-18 18:58:28 -07:00
Luke Barnard
b21f016d37 Add "Export E2E keys" option to logout dialog
Fixes https://github.com/vector-im/riot-web/issues/3184
2017-03-16 14:18:18 +00:00
Luke Barnard
ba0715ba7c Fix import for Lifecycle
This fixes https://github.com/vector-im/riot-web/issues/2991 although we might need to give more feedback than just showing the login screen. Maybe a dialog that says "your account has been deactivated".
2017-03-13 14:10:14 +00:00
Matthew Hodgson
925bbb79ad fix kick dialog CSS 2017-03-13 00:47:33 +00:00
Matthew Hodgson
8a0b08e7f6 fix CSS for ChatCreateOrReuseDialog.js 2017-03-13 00:03:33 +00:00
Matthew Hodgson
bf64f387ce name class to match file 2017-03-12 23:50:12 +00:00
Matthew Hodgson
3a849bce60 name class to match file 2017-03-12 23:48:57 +00:00
Matthew Hodgson
3aaf37df1a beautify a tonne more errors 2017-03-12 22:59:41 +00:00
Matthew Hodgson
e5a5b5cd08 oops 2017-03-12 20:13:39 +00:00
Matthew Hodgson
b7d5d2fd56 beautify UserSettings error msg
fix up default dialog cancel button
2017-03-12 20:03:14 +00:00
Luke Barnard
b7f1b1a424 Merge pull request #736 from matrix-org/luke/chat-create-or-reuse-dialog
Allow user to choose from existing DMs on new chat
2017-03-07 16:22:52 +00:00
Luke Barnard
bf348a0f78 Instead of listening for view_room, use a callback
But make sure that nothing other than the callback is done when RoomTile is clicked.
2017-03-06 17:44:29 +00:00
Luke Barnard
20fa36325f Remember to unregister on unmoun 2017-03-06 15:01:46 +00:00
Luke Barnard
4548d1b824 Use dispatch instead of passing onClick, adjust dialog wording. 2017-03-06 14:51:01 +00:00
Luke Barnard
a122b5d88e Style 2017-03-06 14:22:12 +00:00
David Baker
30eddf9fda Merge pull request #734 from matrix-org/luke/fix-resend
Fix resend bar and "send anyway" in UDD
2017-03-06 11:06:52 +00:00
David Baker
62d9439530 Remove old import & pass through result
in InteractiveAuthDialog
2017-03-03 14:31:52 +00:00
Luke Barnard
ca5c2fb82e Allow user to choose from existing DMs on new chat
When creating a new chat with one person, show a dialog that asks the user whether they'd like to use an existing chat or actually create a new room.

Fixes https://github.com/vector-im/riot-web/issues/2760
2017-03-03 13:48:37 +00:00
David Baker
1bdf213d67 Merge pull request #729 from matrix-org/dbkr/register_ui_auth
Port registration over to use InteractiveAuth
2017-03-03 13:37:41 +00:00
David Baker
977b8a7379 Make UIAuth Dialog show an error
when auth fails
2017-03-03 12:08:26 +00:00
Luke Barnard
ab9aaa9174 Merge pull request #732 from matrix-org/luke/fuse-test
Test to see how fuse feels
2017-03-03 10:46:41 +00:00
Luke Barnard
b822bc66ee Remove redundant null check 2017-03-03 10:22:02 +00:00
Luke Barnard
4fff383de5 Fix resend bar and "send anyway" in UDD 2017-03-03 10:02:08 +00:00
David Baker
0035a91596 Merge pull request #731 from matrix-org/luke/warn-users-e2e-first-time
Warn users about using e2e for the first time
2017-03-02 13:28:15 +00:00
Luke Barnard
6d296a0e7a Warn users about using e2e for the first time 2017-03-01 15:41:13 +00:00