Commit graph

1284 commits

Author SHA1 Message Date
Michael Telatynski
83cb1e6e29 tell guests they can't use filepanel until they register
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2017-05-15 10:15:35 +01:00
Matthew Hodgson
317e24852d explicitly label email & phone add sections; fixes https://github.com/vector-im/riot-web/issues/3531 2017-05-15 03:03:17 +01:00
Matthew Hodgson
7d8c104cb8 Merge pull request #884 from matrix-org/t3chguy/tiny_usersettings_fixes
I broke UserSettings for webpack-dev-server
2017-05-15 01:57:45 +01:00
Matthew Hodgson
7f78e737eb Merge pull request #880 from matrix-org/t3chguy/fixRoomHeaderPreviewing
various fixes to RoomHeader
2017-05-15 01:52:42 +01:00
Matthew Hodgson
38cb123506 Merge pull request #883 from matrix-org/t3chguy/file_panel_fixes
show error if we can't set a filter because no room
2017-05-15 00:19:45 +01:00
Michael Telatynski
6ec799a028 I broke UserSettings for webpack-dev-server
where version file doesn't exist, version starts as null
then gets set to undefined by the promise
this wasn't handled and now undefined is understood to be unknown
rather than null

also picked up on a small casing error
threePids vs threepids, most things using the latter apart from the init

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2017-05-13 15:04:20 +01:00
Michael Telatynski
29568feb95 show error if we can't set a filter
this way it still works for a room we've been in before

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2017-05-12 22:38:57 +01:00
Michael Telatynski
5e4467adce hide settings/search appropriately
pass inRoom prop to RoomHeader (defaults to false)
remove default onSettingsClick, handle if it is passed EVERYWHERE

if onSettingsClick is passes, show that button
show search button only if we are in the room, seems to fail otherwise
this seems to handle all cases I could throw at it. Give it your best

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2017-05-11 17:35:06 +01:00
Luke Barnard
2437eb7910 Merge pull request #874 from matrix-org/luke/fix-rm-not-updating
Fix RM not updating if RR event unpaginated
2017-05-11 15:54:49 +01:00
Luke Barnard
852e1eb720 Rename some variables
`ReadUpTo` -> `RR`
`ReadReceipt` -> `RR`
`ReadMarker` -> `RM`
2017-05-11 09:31:59 +01:00
Luke Barnard
3815ad6cd0 Sent -> Event 2017-05-11 09:20:34 +01:00
Luke Barnard
856ef58d46 fix commen 2017-05-10 14:55:58 +01:00
Luke Barnard
fe8ea4ffe7 Rename vars, linting 2017-05-10 14:51:47 +01:00
Luke Barnard
30e183a7f1 Only send RR if we should 2017-05-10 14:48:01 +01:00
Luke Barnard
7f766d89c3 Rename variables, more comments 2017-05-10 14:42:06 +01:00
Luke Barnard
ca79d9bb6e Separate predicates for RM/RR
Instead of modifying the condition for updating the RR, separate the RM and RR conditions and use an OR to decide when to set both.

Make some logs only log when DEBUG.
2017-05-09 17:36:19 +01:00
Luke Barnard
ac25fd6d87 Remove log 2017-05-09 10:16:37 +01:00
Luke Barnard
488fa3745b Fix RM not updating if RR event unpaginated
If the RR event has been unpaginated, the logic in `sendReadReceipt` will now fallback on the event ID of the RM which in theory is always =< RR event ID stream-wise.
2017-05-09 10:03:40 +01:00
David Baker
85ed39b9d8 Put room name in 'leave room' confirmation dialog
https://github.com/vector-im/riot-web/issues/3850
2017-05-08 16:49:40 +01:00
Matthew Hodgson
5900c879ce Merge pull request #851 from t3chguy/warn_on_unload
Warn on unload
2017-05-07 18:17:18 +01:00
David Baker
e00605571b Fix the spinner to actually appear
We started with clientSyncState being null, which it remained
until the SYNCING event was emitted. We need to set
clientSyncState's initial value correctly.
2017-05-05 10:48:54 +01:00
Luke Barnard
8e3851b380 Merge pull request #860 from t3chguy/patch-4
Guests can't send RR so no point trying
2017-05-04 17:53:59 +01:00
Michael Telatynski
f76b9b4489 remove link to issue
not very useful
2017-05-04 17:25:23 +01:00
Luke Barnard
7918ff2fc2 Merge pull request #857 from t3chguy/t3chguy/settings_versions_improvements
T3chguy/settings versions improvements
2017-05-04 16:56:45 +01:00
Michael Telatynski
da4c2f8b31 Guests can't send RR
so they shouldn't try
lets not hit the HS quite as much
2017-05-04 16:42:41 +01:00
Michael Telatynski
3c6e301f7f Improve regex to ignore trailing -dirty and for rc tags
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2017-05-04 16:22:39 +01:00
Michael Telatynski
2edfc3e598 remove commented out code as per review
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2017-05-04 15:51:31 +01:00
Michael Telatynski
cb478f1194 no idea why those got in there...
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2017-05-04 15:50:52 +01:00
Luke Barnard
694fc26a55 Merge pull request #855 from matrix-org/luke/fix-jump-to-rm-in-mels
Fix jumping to an unread event when in MELS
2017-05-04 13:03:30 +01:00
Luke Barnard
6d9a1f047d Typo 2017-05-04 13:03:04 +01:00
Luke Barnard
bfa3123f9b Combine data-scroll-token and -contained-scroll-tokens
- Instead of using one attribute, use one that might just contain one token
 - Use the first token when tracking a child
 - Mandate that no commas can be in individual tokens
2017-05-04 10:00:13 +01:00
Michael Telatynski
9d92f93fcb consolidate call onPageUnload handler into RoomView
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2017-05-03 16:39:19 +01:00
Michael Telatynski
356d29939c also warn when quitting mid-call
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2017-05-03 16:25:27 +01:00
Michael Telatynski
74b2c86f93 tidy up UserSettings
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2017-05-02 21:17:12 +01:00
Michael Telatynski
76e98d4267 improve version hyperlinking
removed redundant v prefix (key already says version)
links to most applicable version/tag
tag-commit -> commit
commit1-commit2-commit3 -> commit1
(v)x.y.z -> tag<x.y.z>
commit -> commit

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2017-05-02 21:12:58 +01:00
Luke Barnard
af137f8867 Validate phone number on login
To prevent confusion when accidently inputting mxid or email. Fixes https://github.com/vector-im/riot-web/issues/3637
2017-05-02 18:30:46 +01:00
Luke Barnard
4febc63aee Add comment to _scrollToToken 2017-05-02 17:41:09 +01:00
Luke Barnard
fe83a99ab7 Update ScrollPanel docs 2017-05-02 17:36:59 +01:00
Luke Barnard
3f25928380 Fix jumping to an unread event when in MELS
This adds the `data-contained-scroll-tokens` API to elements in `ScrollPanel` which allows arbitrary containers of elements with scroll tokens to declare their contained scroll tokens. When jumping to a scroll token inside a container, the `ScrollPanel` will act as if it is scrolling to the container itself, not the child.

MELS has been modified such that it exposes the scroll tokens of all events that exist within it.This means "Jump to unread message" will work if the unread event is within a MELS (which is any member event, because even individual member events surrounded by other events are put inside a MELS).
2017-05-02 16:34:39 +01:00
Michael Telatynski
daae3bd1ec warn on unload when uploading file(s)
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2017-04-29 06:27:06 +01:00
David Baker
b91f53652d Merge pull request #848 from matrix-org/luke/room-directory-improve
Improve RoomDirectory Look & Feel
2017-04-27 18:28:28 +01:00
Luke Barnard
791f7f7f6b Merge branch 'luke/room-directory-remove-rhs' into luke/room-directory-improve 2017-04-27 17:57:19 +01:00
Luke Barnard
9d57e8b959 Merge pull request #845 from matrix-org/luke/rm-fix
Only show jumpToReadMarker bar when RM !== RR
2017-04-27 17:01:39 +01:00
Luke Barnard
6313193aa8 Null check readMarkerEventId, update comment 2017-04-27 16:52:40 +01:00
Luke Barnard
50831796bb Remove RHS when viewing RoomDirectory 2017-04-27 16:49:23 +01:00
Luke Barnard
2012513c0e Allow MELS to have its own RM
This inserts a RM if any of the events in a MELS if the RM is tracking an event within it.

Fixes https://github.com/vector-im/riot-web/issues/3749
2017-04-27 14:16:50 +01:00
Luke Barnard
8f7359fce1 Only show jumpToReadMarker bar when RM !== RR
If RM !== RR, use the pos. of the RM to determine whether it is visible, as before.
2017-04-27 14:03:54 +01:00
David Baker
4910a225d1 Fix spinner that shows until the first sync
Listen for the sync event and update when it changes
2017-04-26 17:26:53 +01:00
Luke Barnard
9ac06d4c79 Merge pull request #839 from matrix-org/dbkr/spinner_until_sync
Show spinner until first sync has completed
2017-04-26 14:34:08 +01:00
David Baker
df283dae47 Show spinner until first sync has completed
Shows the 'forward paginating' spinner until the first sync has
completed.

Fixes https://github.com/vector-im/riot-web/issues/3318
2017-04-26 14:05:09 +01:00
David Baker
04f44e9201 Style fixes for LoggedInView
PRing this becaise I was going to change LoggedInView, so did
some code style updates, but then decided the do the change
elsewhere.
2017-04-26 13:48:03 +01:00
David Baker
fa9c2d1373 Fix specifying custom server for registration
Broken by 9cd7914ea5
(ServerConfig interface changed but Registration not updated)
2017-04-25 19:21:09 +01:00
Luke Barnard
96e7479d8b Show "jump to message" when message is not paginated 2017-04-25 17:19:36 +01:00
Matthew Hodgson
29e48d1801 Merge pull request #826 from matrix-org/matthew/mels-profile-changes
summarise profile changes in MELS
2017-04-25 00:18:19 +01:00
Michael Telatynski
3997974f0f remove debug console log (ignore its content pls)
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2017-04-24 22:16:15 +01:00
Michael Telatynski
bfba25f3da we don't care about rhs state anymore as we can just restore it sanely
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2017-04-24 22:10:14 +01:00
Michael Telatynski
4cf9e0c1ae Create a way to restore last state of the rhs panel.
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2017-04-24 22:00:59 +01:00
Michael Telatynski
ee560a969a upon forwarding message to current room, explicitly remove clear from aux
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2017-04-24 20:17:29 +01:00
Michael Telatynski
fbca0e0d0d correct cancel appearing when it shouldn't
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2017-04-24 20:03:07 +01:00
Michael Telatynski
4285c395f5 Merge branch 'develop' of https://github.com/matrix-org/matrix-react-sdk into forward_message
Conflicts:
	src/components/structures/RoomView.js
2017-04-24 18:36:33 +01:00
Richard van der Hoff
96e733b487 Merge pull request #825 from matrix-org/matthew/missing-keyboard-modifiers
limit our keyboard shortcut modifiers correctly
2017-04-23 12:02:29 +01:00
Matthew Hodgson
24f2aed45f summarise profile changes in MELS
fixes https://github.com/vector-im/riot-web/issues/3463
2017-04-23 04:05:50 +01:00
Matthew Hodgson
a2be764681 display err.message to user if available in error msgs 2017-04-23 01:48:27 +01:00
Matthew Hodgson
7854cac61d hook up keyb shortcuts for roomdir 2017-04-23 01:00:44 +01:00
Matthew Hodgson
fa033e6116 limit our keyboard shortcut modifiers correctly
fixes https://github.com/vector-im/riot-web/issues/3614
2017-04-23 00:49:14 +01:00
Matthew Hodgson
e18e965eb8 missing key attr 2017-04-22 16:26:39 +01:00
Michael Telatynski
33e841a786 move user settings outward and use built in read receipts disabling
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2017-04-22 15:40:29 +01:00
Matthew Hodgson
6c177bc617 Merge pull request #806 from t3chguy/t3chguy/show_access_token
Show Access Token under Advanced in Settings
2017-04-22 02:51:54 +01:00
Matthew Hodgson
ad76dd0dd1 Merge pull request #810 from t3chguy/t3chguy/settings_versions_improvements
Link tags/commit hashes in the UserSettings version section
2017-04-22 02:38:30 +01:00
Matthew Hodgson
febd9c637e Merge pull request #813 from t3chguy/RoomSettings_close_focus_composer
On return to RoomView from auxPanel, send focus back to Composer
2017-04-22 02:08:48 +01:00
Matthew Hodgson
872d0e0f50 Merge branch 'develop' into travis/hide-read-receipts 2017-04-22 01:36:38 +01:00
turt2live
64e416e117 Add option to not send typing notifications
Addresses vector-im/riot-web#3220

Fix applies to both the RTE and plain editor.

Signed-off-by: Travis Ralston <travpc@gmail.com>
2017-04-21 14:50:26 -06:00
turt2live
e4c4adc517 Add option to hide other people's read receipts.
Addresses vector-im/riot-web#2526

Signed-off-by: Travis Ralston <travpc@gmail.com>
2017-04-21 14:28:28 -06:00
Michael Telatynski
fdc26a490a On return to RoomView from auxPanel, send focus back to Composer
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2017-04-21 18:45:28 +01:00
Luke Barnard
ae8d04b35d Merge pull request #805 from matrix-org/luke/feature-read-marker
Sync RM across instances of Riot
2017-04-21 16:52:46 +01:00
Luke Barnard
29c2bd3d18 reset last_rr_sent on error
Indicate that setting the RR was a failure and that hitting the API should be retried (in the case where the errcode !== "M_UNRECOGNISED")
2017-04-21 16:46:36 +01:00
Luke Barnard
19d6d1ef4b Merge pull request #811 from matrix-org/luke/login-ui
First iteration on improving login UI
2017-04-21 16:25:16 +01:00
Luke Barnard
9c4c706120 Remove :server.name for custom servers
Custom servers may not be configured such that their domain name === domain part.
2017-04-21 16:09:11 +01:00
Michael Telatynski
b6ca16fc2f add RoomView state for message being forwarded
add RoomView action handler for message forward
clear forwardingMessage onCancelClick RoomView
change var into const in render RoomView
load ForwardMessage from rooms.ForwardMessage
if there is a messageForwarding object in state show panel in aux

Create ForwardMessage class

Modify RoomHeader so that it shows the cancel button more greedily

reskindex

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2017-04-21 13:50:22 +01:00
Luke Barnard
9cd7914ea5 Finishing off the first iteration on login UI
This makes the following changes:
 - Improve CountryDropdown by allowing all countries to be displayed at once and using PNGs for performance (trading of quality - the pngs are scaled down from 32px to 25px)
 - "I want to sign in with" dropdown to select login method
 - MXID login field that suffixes HS domain (whether custom or matrix.org) and prefixes "@"
 - Email field which is secretly the same as the username field but with a different placeholder
 - No more login flickering when changing ServerConfig (!) fixes https://github.com/vector-im/riot-web/issues/1517

This implements most of the design in https://github.com/vector-im/riot-web/issues/3524 but neglects the phone number login:
![login_with_msisdn](https://cloud.githubusercontent.com/assets/1922197/24864469/30a921fc-1dfc-11e7-95d1-76f619da1402.png)

This will be updated in another PR to implement desired things:
 - Country code visible once a country has been selected (propbably but as a prefix to the phone number input box.
 - Use square flags
 - Move CountryDropdown above phone input and make it show the full country name when not expanded
 - Auto-select country based on IP
2017-04-21 11:37:08 +01:00
Michael Telatynski
bbd1f34336 Prepend REACT_SDK_VERSION with a v to match riot-web version output
Add simple helper to construct version/commit hash urls
var -> let/const and prepend olmVersionString with v for same reason

for both matrix-react-sdk and riot-web, if unknown/local don't do anything
else try to create a link to the commit hash/tag name

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2017-04-21 03:04:34 +01:00
Michael Telatynski
be9b858193 focus on composer after jumping to bottom
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2017-04-21 01:06:00 +01:00
Luke Barnard
67089cb527 If new RR-RM API not implemented, fallback to RR-only API 2017-04-20 14:34:59 +01:00
Luke Barnard
a4ba5f041c Remove log, reinstate comment 2017-04-19 10:46:08 +01:00
Luke Barnard
edeaef8c2f Initialise last_rm_sent_event_id 2017-04-19 10:28:38 +01:00
Luke Barnard
81bf2be13b Make note of inconsistant roomReadMarkerTsMap
This will become redundant when there is server support for directionality of the RM
2017-04-19 10:27:43 +01:00
Luke Barnard
a787ee8480 Remove spammy log 2017-04-19 10:20:53 +01:00
Luke Barnard
00cf5b5918 Revert change 2017-04-19 10:20:24 +01:00
Luke Barnard
e32f153573 Remove Room.accountData listener on unmount 2017-04-19 10:18:25 +01:00
Luke Barnard
28818b857a Remove log 2017-04-19 10:17:44 +01:00
Luke Barnard
81bdfe2126 Update to match renamed API 2017-04-19 10:14:57 +01:00
Michael Telatynski
61071b89df Show Access Token under Advanced in Settings
behind a Spoiler, onClick = spoil+select

Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
2017-04-18 19:55:08 +01:00
Matthew Hodgson
c1c3956df4 fix bugs, and handle shortcircuit react when updating roomtile 2017-04-18 19:28:24 +01:00
Luke Barnard
c431c9ab22 Clarify comment 2017-04-18 15:18:21 +01:00
Luke Barnard
d38520dfb4 Undo change in ghost RM logic
Put a XXX to indicate that the ghost tile should be replaced with something mor e stable. As it stands, the ghost will appear, potentially at a different position to the RMs actual position
2017-04-18 15:17:42 +01:00
Luke Barnard
d33afa99ab marker -> event_id 2017-04-18 15:13:05 +01:00
Luke Barnard
4b5364e9ae Merge branch 'develop' into luke/feature-read-marker 2017-04-18 14:45:18 +01:00
Luke Barnard
28ed69b617 m.read_marker -> m.fully_read 2017-04-18 14:44:43 +01:00
Matthew Hodgson
da569c2c8d add constantTimeDispatcher and use it for strategic refreshes.
constantTimeDispatcher lets you poke a specific react component to do something
without having to do any O(N) operations.  This is useful if you have thousands
of RoomTiles in a RoomSubList and want to just tell one of them to update,
without either having to do a full comparison of this.props.list or have each
and every RoomTile subscribe to a generic event from flux or node's eventemitter

*UNTESTED*
2017-04-17 21:06:37 +01:00
Luke Barnard
a29d8c2af2 Merge pull request #765 from t3chguy/t3chguy/escape-closes-user-settings
Escape closes UserSettings
2017-04-12 15:18:19 +01:00