Commit Graph

2231 Commits

Author SHA1 Message Date
Richard van der Hoff
0bd1e65b49 update changelogs 2023-07-11 16:41:45 +01:00
Richard van der Hoff
fd3c4f669d matrix-sdk-crypto-js v0.1.3 2023-07-11 16:41:22 +01:00
Richard van der Hoff
a3a36291ad crypto-js Fix return type of receiveSyncChanges
https://github.com/matrix-org/matrix-rust-sdk/pull/2142 introduced an
unintended change such that `receiveSyncChanges` returned an array of arrays.
2023-07-11 16:29:17 +01:00
Jonas Platte
53ac8bea14 ffi: Provide tokio context for async exported method 2023-07-11 15:54:38 +02:00
Benjamin Bouvier
2d9f7d2f89 ffi: remove bindings for manually creating EncryptionSync and RoomList 2023-07-11 14:07:27 +02:00
Benjamin Bouvier
dbc8f0136b ffi: add bindings for App 2023-07-11 14:07:27 +02:00
Richard van der Hoff
00e85ef275 Disable debug logging for tests
Because https://github.com/jestjs/jest/issues/4156 is closed
2023-07-11 10:56:42 +02:00
Mauro Romito
bc811cc1dc ui: Add a unique ID for all timeline items
Co-authored-by: Jonas Platte <jplatte@matrix.org>
2023-07-10 19:19:31 +02:00
Benjamin Bouvier
2acc13ed2c feat: add a new NotificationClient API 📬 (#2235)
* chore: rename EncryptionSyncMode variants

* feat: split the encryption sync modes into two different functions

* feat: make locking optional in the `EncryptionSync`

* feat: experimental notification client that retries decryption if it failed the first time

* fix: don't iloop retrying decryption

* chore: helper to convert from bool to `WithLocking`

* feat: don't loop and just retry decryption of the notification event linearly

* feat: remove unused set_notification_delegate

Dead code is dead.

* ffi: get rid of `get_notification_item` and introduce the `NotificationClient`

* fmt

* feat: don't swallow encryption sync errors when retrying notification event decryption

* keeping a tidy commit history is NP-hard

* will i ever learn

* chore: enable experimental-notification-client in the FFI crate

* test: add basic integration test for the common path

* Address first batch of review comments, thanks Jonas!
2023-07-10 18:06:13 +02:00
Richard van der Hoff
bf1595309c matrix-sdk-crypto-js v0.1.2 2023-07-10 12:03:32 +01:00
Richard van der Hoff
caa70db31b Prepare changelog for v0.1.2 2023-07-10 12:03:12 +01:00
aringenbach
89aa2916c7 ui/ffi: Add timestamp to reactions 2023-07-10 10:13:53 +00:00
Benjamin Bouvier
2225e8ad80 feat: make it possible to configure the state store as an in-memory store in FFI 2023-07-10 12:04:52 +02:00
Richard van der Hoff
708a7d95a7 Add Qr.state() 2023-07-10 11:45:33 +02:00
Richard van der Hoff
0ccb1efded Enable rust-sdk tracing for device tests
... because knowing why your tests are failing is nice
2023-07-10 11:45:33 +02:00
Richard van der Hoff
0a5ef29c34 device.test: Stop pretending we have independent tests
This file claimed to have lots of tests, but actually they are not independent
- they are just one big test.

It's not ideal to have one massive test like this, but I don't really have time
to rewrite them and we should stop pretending.
2023-07-10 11:45:33 +02:00
Damir Jelić
9f68b3838f Merge pull request #2142 from matrix-org/andybalaam/cache-last-event-in-roominfo
Store the last timeline event in RoomInfo
2023-07-10 11:30:13 +02:00
Jonas Platte
0a6234f40a ffi: Send initial back-pagination status to subscriber immediately
… right as the subscriber is registered.
2023-07-10 11:07:43 +02:00
Richard van der Hoff
0bf99d5c73 Fix handling of SAS start events once we have shown a QR code (#2242)
Fixes #2237

Also a couple of other cleanups while I'm in the area.
2023-07-07 17:55:13 +01:00
Andy Balaam
ff0cd7c592 Fix one more JS test 2023-07-07 15:55:29 +01:00
Andy Balaam
9bcc1e9e00 More JavaScript test updates 2023-07-07 15:31:09 +01:00
Andy Balaam
c9a11a58bf Format JavaScript 2023-07-07 15:11:00 +01:00
Andy Balaam
82c7a05f01 Fixes for problems found through CI 2023-07-07 15:05:48 +01:00
Nicolas Mauri
fa4c1ef00b ffi: expose the notification settings (#2223) 2023-07-07 15:07:31 +02:00
Andy Balaam
6cb3afe6fd Merge branch 'main' into andybalaam/cache-last-event-in-roominfo 2023-07-07 13:14:52 +01:00
Andy Balaam
3fd1542a25 Fetch sender profile when returning latest event 2023-07-07 12:59:49 +01:00
Jonas Platte
0ef819bca7 ffi: Use proc-macros for SessionVerificationControllerDelegate 2023-07-06 18:26:40 +02:00
Andy Balaam
98882b9c23 Store the last timeline event in RoomInfo
and the latest few encrypted events in Room.
Use the latest event to provide a room preview, and use the encrypted
events to replace the laest event when they are decrypted.
2023-07-06 16:48:27 +01:00
Florian Duros
c600c64b95 BindingsJS: Release v0.1.1 (#2234) 2023-07-06 17:25:02 +02:00
Jonas Platte
fe189fda06 bindings: Rename subscribe_to_back_pagination_{status => state}
For consistency with the UI crate.
2023-07-06 15:55:49 +02:00
Florian Duros
0384a52f1e Expose the verify method for the Device in the bindings (#2229) 2023-07-06 15:46:52 +02:00
Jonas Platte
ae17273a37 ui: Replace loading indicator and timeline start virtual timeline items
… with a BackPaginationState observable.
2023-07-06 13:57:40 +02:00
Damir Jelić
75dbfb4d46 Remove an unnecessary unwrap in the crypto crate (#2226) 2023-07-06 12:40:04 +02:00
Ivan Enderlin
6cca4ab3e5 chore(ffi): Bye bye Sliding Sync bindings!
The `RoomList` and `EncryptionSync` API provide a better developer
experience and address concrete needs. Nobody no longer uses the Sliding
Sync bindings, so we can remove them.
2023-07-05 15:05:08 +02:00
Jonas Platte
87782e9567 ffi: Expose EventTimelineItem::origin 2023-07-04 19:50:08 +02:00
Mauro Romito
f4929fd064 joined members is now in the notification 2023-07-04 19:39:43 +02:00
Jonas Platte
cb2e97f06a Upgrade eyeball to 0.8 2023-07-04 16:22:45 +00:00
Jonas Platte
7bcc886429 Re-format with latest rustfmt 2023-07-03 18:57:05 +02:00
Alfonso Grillo
147cd970c4 Map MSC3488 fields for UniFFI (#2187)
* Update ruma

* Refactor send_location

* Add timeline parser

* Fix code format

* Add zoom_level

* Update ruma

* Map zoom_level

* Format code

* Cleanup

* Refactor LocationContent

* Apply suggestion

* Fix format issue
2023-07-03 13:34:07 +00:00
Ivan Enderlin
9f90b6d4a8 chore(ui): Rename room_list module to room_list_service. 2023-06-30 19:59:13 +02:00
jonnyandrew
3180a1ba7c ffi: Expose proxy and insecure SSL settings (#2191)
Co-authored-by: Damir Jelić <poljar@termina.org.uk>
2023-06-30 15:31:20 +02:00
Benjamin Bouvier
d642c22db7 feat: implement a generation counter for the CryptoStore lock 2023-06-30 12:41:04 +02:00
Benjamin Bouvier
77290ff2c1 feat: Get rid of "common extensions"
Common extensions are confusing, and they've included `e2ee` and `to-device` by default. This is not a sane default anymore,
now that there's the concept of `EncryptionSync`: it's either we have the encryption sync that enables e2ee and to-device +
a room list sync that doesn't, OR we have a single room list that has both.

Room List was misconfigured to always use `e2ee` and `to-device`, which was incorrect when it's running with the `EncryptionSync`
in the background. This is now removed, and properly tested.
2023-06-30 09:56:29 +02:00
Ivan Enderlin
91bf84714d feat(ffi): Add methods on RoomListItem so that full_room isn't necessary
feat(ffi): Add methods on `RoomListItem` so that `full_room` isn't necessary
2023-06-29 15:39:45 +02:00
Richard van der Hoff
757716c924 matrix-sdk-crypto-js v0.1.0 2023-06-29 15:22:00 +02:00
Richard van der Hoff
1b2b6c011b update changelog 2023-06-29 15:22:00 +02:00
Ivan Enderlin
bd148fd422 chore(ffi): RoomListItem::is_direct returns a bool. 2023-06-29 15:14:53 +02:00
Ivan Enderlin
363b0d9ee6 doc(ffi): Add some precisions. 2023-06-29 15:07:46 +02:00
Ivan Enderlin
0cd0ade2bc feat(ffi): Add methods on RoomListItem so that full_room isn't necessary.
Calling `RoomListItem::full_room` creates its associated `Timeline`.

ElementX calls `full_room` to get the `is_direct`, `avatar_url` and
`canonical_alias` values for _all_ rooms in the room list. Instead of
doing so, let's add those methods directly in `RoomListItem` so that the
`Timeline` isn't created for _all_ rooms.
2023-06-29 14:48:37 +02:00
Ivan Enderlin
6d67375f8e fix(ffi): Simplify Room::add_timeline_listener
fix(ffi): Simplify `Room::add_timeline_listener`
2023-06-29 13:24:05 +02:00