Commit Graph

66 Commits

Author SHA1 Message Date
Aidan Gauland 35780f5ae0 Remove use of deprecated React.PropTypes
Replace all uses of React.PropTypes with PropTypes and importing PropTypes from
'prop-types'.
2017-12-26 14:03:18 +13:00
Luke Barnard 7ec4010881 Make GroupStore use MatrixClientPeg
To avoid weirdness with using a cached matrix client
2017-11-28 11:54:05 +00:00
Luke Barnard d4f5e7e6d7 Deal with errors, lack of groups, loading 2017-11-28 10:46:20 +00:00
Luke Barnard 0d5f7ef246 Avoid NPE 2017-11-28 10:12:46 +00:00
Luke Barnard 3342754a72 Catch and log errors from getting group profile 2017-11-28 10:11:25 +00:00
lukebarnard 9ed9422af8 Move group publication toggles to UserSettings 2017-11-27 17:24:42 +00:00
krombel 7c5f74e18a Fix GroupMemberList search for users without displayname
When there is a user in a group which has no displayname set
the search failed with "Cannot read property 'toLowerCase' of null"
2017-11-20 17:02:20 +01:00
Luke Barnard 74c6ebc5c6 Merge pull request #1595 from matrix-org/luke/groups-show-user-profile-on-action
Display group member profile (avatar/displayname) in ConfirmUserActionDialog
2017-11-10 12:31:47 +00:00
Luke Barnard 90a63d78b9 Merge pull request #1597 from matrix-org/luke/groups-fix-invite-avatar
Convert group avatar URL to HTTP before handing to BaseAvatar
2017-11-10 11:41:51 +00:00
Luke Barnard 31be27515c Modify the group room visibility API to reflect the js-sdk changes
See https://github.com/matrix-org/matrix-js-sdk/pull/569
2017-11-09 16:28:21 +00:00
Luke Barnard a8487c540f Convert group avatar URL to HTTP before handing to BaseAvatar
This is yet another component that imports the MatrixClient just for mxcUrlToHttp. It'd be much nicer to have an avatar component that accepted MXCs, e.g. by wrapping or modifying BaseAvatar.
2017-11-09 14:34:04 +00:00
Luke Barnard 9a6c9594a1 Correctly display group invite
By making sure the groupName truncates in the right place
2017-11-09 14:16:54 +00:00
Luke Barnard 6eeb91ee2e Display group member profile (avatar/displayname) in ConfirmUserActionDialog
Fixes https://github.com/vector-im/riot-web/issues/5486
2017-11-09 12:24:20 +00:00
Luke Barnard e2a0cba6cb If group member privilege level is equal, disambiguate with displayname or userId 2017-11-08 13:57:38 +00:00
Luke Barnard e3e161fbea Order users in the group member list with admins first 2017-11-08 11:51:58 +00:00
Luke Barnard c1d9d3714a Fix not being able to filter community rooms - fixes vector-im/vector-web#5538 2017-11-08 10:55:51 +00:00
Luke Barnard 7a09127687 Alter group member api
To match https://github.com/matrix-org/synapse/pull/2647
2017-11-07 11:27:42 +00:00
Luke Barnard d6a6e59d6c Indicate admins in the group member list with a sheriff badge 2017-11-06 16:37:16 +00:00
Luke Barnard 151f9917b1 Fix group invites such that they look similar to room invites
- Change GroupInviteTile to use RoomTile CSS
 - Give group invites their own sub list, with heading "Community Invites"
2017-11-03 12:19:37 +00:00
Luke Barnard 982e87e01c Communities are communities, wrap div for label alignment 2017-11-02 15:04:40 +00:00
Luke Barnard bf77b51b5e Merge branch 'develop' into luke/groups-room-publicity 2017-11-02 13:39:33 +00:00
Luke Barnard 790db94fd7 Add toggle to alter the visibility of a room-group association 2017-11-02 13:31:11 +00:00
Luke Barnard e909d859ab Merge branch 'develop' into luke/groups-room-info 2017-11-02 10:56:33 +00:00
Luke Barnard 64a369216a Implement simple GroupRoomInfo
which replaces the "X" on the GroupRoomTile with "Remove from community" under Admin Tools.
2017-11-01 17:27:35 +00:00
Stefan Parviainen e1e4fc2dac Make eslint happy
Signed-off-by: Stefan Parviainen <pafcu@iki.fi>
2017-11-01 16:18:48 +01:00
Stefan Parviainen d6f1e12bee Fix merge conflict
Signed-off-by: Stefan Parviainen <pafcu@iki.fi>
2017-11-01 15:50:45 +01:00
Luke Barnard 4e234cfc3b Alter UI for disinviting a group member
The same API as kicking is used for disinviting, so only cosmetic changes needed here.
2017-10-30 18:17:35 +00:00
Luke Barnard 3e64333ada Only show admin tools to privileged users 2017-10-30 16:45:45 +00:00
Stefan Parviainen 95b2392104 Merge branch 'develop' into departify 2017-10-27 19:23:13 +02:00
Luke Barnard e094c32c62 Simplify GroupStore listener registration 2017-10-27 11:38:10 +01:00
Luke Barnard eec6ed36cd Use correct icon for group room deletion and make themeable
Also fix cancel icons to have class mx_filterFlipColor
2017-10-26 14:05:58 +01:00
Stefan Parviainen 4ff369c884 Merge branch 'develop' into departify 2017-10-24 18:27:24 +02:00
Luke Barnard d1db0d6426 Deduplicate members, key by userId 2017-10-24 10:50:31 +01:00
Luke Barnard 1cc427ba46 Fix some react warnings in GroupMemberList
- If the list contains two users twice, react would warn about duplicate keys. Use `index` instead.
 - Check if unmounted before setting state after fetching members.
2017-10-24 09:58:45 +01:00
Stefan Parviainen 115772d526 Fix merge conflict
Signed-off-by: Stefan Parviainen <pafcu@iki.fi>
2017-10-23 19:57:52 +02:00
Luke Barnard 0799e5cde4 Refresh group member lists after inviting users 2017-10-23 16:04:26 +01:00
Luke Barnard ea1dbe1f76 Fix invites to groups without names 2017-10-19 15:47:52 +01:00
Luke Barnard 2be0ebdd1d More Groups->Communities 2017-10-19 15:01:16 +01:00
Luke Barnard 85d99d429d Use correct logic operator 2017-10-17 09:49:39 +01:00
Luke Barnard 14eee9a37a Only show invited section if there are invited group members 2017-10-16 17:59:53 +01:00
Luke Barnard 9b08f4d11f Separate fetching indicator state 2017-10-16 17:21:05 +01:00
Luke Barnard 008e8d4f54 Show "Invited" section in the user list 2017-10-16 16:38:32 +01:00
Stefan Parviainen 9495ccdbb5 Don't hardcode ConfirmUserActionDialog title
Signed-off-by: Stefan Parviainen <pafcu@iki.fi>
2017-10-12 22:15:53 +02:00
Luke Barnard 917957c1dc Modify the group store to include group rooms
and modify components to use this new part of the store such that feedback can be given
when adding or removing a room from the room list.
2017-10-05 14:30:04 +01:00
Luke Barnard 6b834bc72e Add confirmation dialog for removing room from group 2017-10-03 11:16:22 +01:00
Luke Barnard 0116c4b486 Log the error when failing to removie room from group 2017-10-03 10:14:08 +01:00
Luke Barnard 3e34a460a4 Add error dialog for when removing room fails 2017-10-03 10:12:11 +01:00
Luke Barnard 955ca6cd2b Implement button to remove a room from a group
NB: This doesn't provide any feedback to the user. We should use a GroupSummaryStore-style component to refresh the view after a successful hit to the API. This could affect the summary view as well, because when rooms are removed from a group, they are also removed from the summary (if necessary).
2017-09-29 17:59:24 +01:00
Luke Barnard 6b9a2909df Add rule to enforce spacing in curly brackets in JSX children
This required an updated in version of eslint-plugin-react to 7.4.0.
2017-09-28 11:21:06 +01:00
Luke Barnard 1ca9102442 Fix spinner appearing above RP header
By wrapping the spinner in the mx_MemberList class. Also, use mx_RoomHeader_cancelButton for group settings cancel
2017-09-27 10:36:44 +01:00