Commit graph

3037 commits

Author SHA1 Message Date
Mark Haines
13f28e53e1 Generate thumbnails when sending m.image and m.video messages. (#555)
* Send a thumbnail when sending a m.image

* Use the 'thumbnail_file' when displaying encrypted images

* Whitespace

* Generate thumbnails for m.video

* Fix docstring, remove unused vars, use const

* Don't change the upload promise behaviour

* Polyfill for Canvas.toBlob to support older browsers

* Lowercase for integer types in jsdoc
2016-11-15 11:22:39 +00:00
Richard van der Hoff
b209cc551e Update eventtiles when the events are decrypted
Events are sometimes decrypted after they arrive, so add an eventlistener for
it and update the tile.
2016-11-15 11:12:52 +00:00
Richard van der Hoff
22757cfcd3 Inject MatrixClient into React context in tests
Now that EventTile expects MatrixClient in the context, we had better provide
it.
2016-11-14 18:22:56 +00:00
Richard van der Hoff
0e8a49ebb7 Update EventTile to use WithMatrixClient instead of MatrixClientPeg 2016-11-14 16:00:24 +00:00
Richard van der Hoff
34df6ea242 Complete attachment-encryption patch
https://github.com/matrix-org/matrix-react-sdk/pull/533 originally landed in
the wrong branch, and was reverted by
https://github.com/matrix-org/matrix-react-sdk/pull/546.
https://github.com/matrix-org/matrix-react-sdk/pull/548 attempted to land it on
the develop branch, but omitted a small amount of the patch.

This lands the final part, which got missed out.
2016-11-12 12:20:36 +00:00
David Baker
062cb7a52e Add isomorphic fetch
because the attachment crypto uses it
2016-11-11 17:22:44 +00:00
David Baker
45bd234c38 Merge pull request #549 from matrix-org/markjh/disable_conferencing_for_e2e
Disable conference calling for encrypted rooms
2016-11-11 16:01:47 +00:00
Mark Haines
2eb9d90b86 Disable conference calling for encrypted rooms 2016-11-11 15:49:21 +00:00
David Baker
1ff3a86457 Merge pull request #548 from matrix-org/markjh/encrypted-attachments
Encrypt attachments in encrypted rooms
2016-11-11 14:49:52 +00:00
Mark Haines
0bfcb38879 Add dependency on browser-encrypted-attachment 2016-11-11 14:42:33 +00:00
Richard van der Hoff
b7fce70ce5 Merge pull request #547 from matrix-org/luke/fix-memberavatar-proptypes
Fix MemberAvatar PropTypes & MemberEventListSummary key
2016-11-11 14:00:02 +00:00
Mark Haines
72d24f58d0 Make the promises be q promises 2016-11-11 13:57:45 +00:00
Mark Haines
9edfea3b32 Make imports more consistent, fix m.video 2016-11-11 13:57:45 +00:00
Mark Haines
bf5ecbd016 Review comments
Conflicts:
	src/ContentMessages.js
2016-11-11 13:57:42 +00:00
Mark Haines
734c4eb638 Fix gif hoverover 2016-11-11 13:57:11 +00:00
Mark Haines
de384480c6 Pass the decryptedUrl to the MFileBody so that it doesn't need to decrypt it itself.
Conflicts:
	src/components/views/messages/MImageBody.js
2016-11-11 13:57:08 +00:00
Mark Haines
736ab743ee Make everything use MFileBody for downloads, ensure that encrypted attachments are actually downloaded
Conflicts:
	src/components/views/messages/MImageBody.js
2016-11-11 13:56:30 +00:00
Mark Haines
ee1768f644 Use data:// URI rather than blob: URI to avoid XSS 2016-11-11 13:55:57 +00:00
Mark Haines
b69e88d4e3 Decrypt m.file attachments 2016-11-11 13:55:57 +00:00
Mark Haines
4e01a4f692 Decrypt m.audio attachments 2016-11-11 13:55:57 +00:00
Mark Haines
48340a2817 Fix unencrypted video thumbnail 2016-11-11 13:55:57 +00:00
Mark Haines
b56417f46e Remove spurious TODO 2016-11-11 13:55:57 +00:00
Mark Haines
95e8889857 Decypt m.video events 2016-11-11 13:55:57 +00:00
Mark Haines
a4a0d02848 Move decryptFile into a utility function so that it can be shared between different components
Conflicts:
	src/components/views/messages/MImageBody.js
2016-11-11 13:55:48 +00:00
Luke Barnard
5109833c42 Use correct prop types 2016-11-11 13:55:32 +00:00
Mark Haines
49b3aec1e2 Include the mimetype with the file info. Store the objectURL in state so that it can be used normally by the exising templates
Conflicts:
	src/ContentMessages.js
	src/components/views/messages/MImageBody.js
2016-11-11 13:54:07 +00:00
Luke Barnard
2a1d32f4d5 Add key prop to memberlist summary 2016-11-11 13:49:25 +00:00
Mark Haines
23e764604c Merge remote-tracking branch 'origin/master' into develop 2016-11-11 12:00:53 +00:00
Mark Haines
f6b3248c9d Merge pull request #546 from matrix-org/revert-533-markjh/encrypted-attachments
Revert "Encrypt attachments in encrypted rooms,"
2016-11-11 12:00:43 +00:00
Mark Haines
61921327c2 Merge remote-tracking branch 'origin/master' into develop 2016-11-11 12:00:30 +00:00
David Baker
1e163eabf0 Revert "Encrypt attachments in encrypted rooms," 2016-11-11 11:59:08 +00:00
Richard van der Hoff
998690431f Merge pull request #542 from matrix-org/dbkr/get_app_version
Fix the vector web version in UserSettings
2016-11-11 11:11:36 +00:00
Richard van der Hoff
00ecff7497 Merge pull request #544 from matrix-org/luke/feature-truncate-m-room-member-events
Truncate consecutive member events
2016-11-11 11:01:47 +00:00
David Baker
857c0d1747 Wrap getAppVersion() in promise
in case it throws
2016-11-11 10:05:53 +00:00
Luke Barnard
d3a548773a Remove redundant lines 2016-11-10 18:01:34 +00:00
Luke Barnard
3d7f6919cf Refactor renderNameList (thanks, @richvdh) 2016-11-10 17:36:22 +00:00
Luke Barnard
0695037f5f pass in prop onClick by default 2016-11-10 17:30:35 +00:00
Luke Barnard
87e8f0e4da trailing commas 2016-11-10 17:27:59 +00:00
Luke Barnard
3ec7940d12 Inline renderEvents 2016-11-10 17:26:36 +00:00
Luke Barnard
d2d7ebc979 correct comment 2016-11-10 17:22:16 +00:00
Luke Barnard
b11dd9542f Add class to expand link for pointer and colour 2016-11-10 17:09:18 +00:00
Luke Barnard
e05aeb35a1 npm run reskindex 2016-11-10 17:03:24 +00:00
Luke Barnard
ac460122cc revert now redundant TruncatedList edits 2016-11-10 15:51:27 +00:00
Luke Barnard
f71ac93946 Prefer null to falsy, use correct plural 2016-11-10 15:38:20 +00:00
Luke Barnard
1a4df38500 remove href 2016-11-10 15:20:53 +00:00
Luke Barnard
d8bc4d9a6f Factor out avatar click leads to view_user 2016-11-10 15:18:59 +00:00
Luke Barnard
6b2aa43b71 Factor out "and others" 2016-11-10 14:33:41 +00:00
Luke Barnard
d6b74becfc Children are required 2016-11-10 14:12:45 +00:00
Luke Barnard
370f5f0a11 Use _ prefix for private methods 2016-11-10 14:12:05 +00:00
Luke Barnard
8422017827 events are required 2016-11-10 14:09:40 +00:00