Commit Graph

593 Commits

Author SHA1 Message Date
ganfra
4fe142c624 Rust sdk : update to 0.2.42 2024-09-04 16:37:46 +02:00
Jorge Martin Espinosa
4fbf98700a Make sure to save the tokens the Client might return when its session is restored (#3378)
* Use `ClientSessionDelegate` to ensure tokens are always updated.

Refreshed tokens on client restoration might not have been stored to disk if the token refresh happened before `RustMatrixClient` was built and the `ClientDelegate` was set in it.

Using `ClientSessionDelegate` should ensure the tokens refreshed callback is called at any point in time.

* Improve how assigning the Client works, fix docs

* Fix review comments
2024-09-04 10:54:31 +02:00
renovate[bot]
5ba88dc5b0 Update dependency org.matrix.rustcomponents:sdk-android to v0.2.41 (#3384)
* Introduce value class UniqueId.

* Allow reactions on non-sent Event, the SDK can now handle it.

Also the SDK will manage local echo for reactions.

* Update dependency org.matrix.rustcomponents:sdk-android to v0.2.41

* Fixes after SDK upgrade:

- Use `ClientBuilderSlidingSync` to set `SlidingSyncVersionBuilder` in `RustMatrixClientFactory`.
- `Room.toggleReaction(emoji: String, eventId: EventId)` is now `Room.toggleReaction(emoji: String, uniqueId: UniqueId)`, since reactions can now be applied to local echoes too in the SDK.

* Rename exception case

* Fix wrong error case being used in test

---------

Co-authored-by: Benoit Marty <benoit@matrix.org>
Co-authored-by: Benoit Marty <benoitm@matrix.org>
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Jorge Martín <jorgem@element.io>
2024-09-03 20:09:33 +02:00
Benoit Marty
82fa369c8b Merge pull request #3320 from element-hq/feature/bma/cleanNotificationOfRedactedEvent
Redact message on displayed notification
2024-08-29 14:46:13 +02:00
Benoit Marty
b4e9799fec Better handling on null reset handler.
This is not an error, but in this case, the reset identity is successful.
2024-08-29 09:41:13 +02:00
Benoit Marty
3b12d54dad Cleanup notification for redacted event. 2024-08-28 10:29:01 +02:00
ganfra
f06b2290ea Rust sdk : handle the remaining changes 2024-08-27 17:45:32 +02:00
ganfra
18959a930f Rust sdk : refactor LocalSendState to use the new failure states as iOS does 2024-08-27 17:45:22 +02:00
ganfra
57c6abfe47 Rust sdk : use newMessageShield state 2024-08-27 17:43:07 +02:00
Benoit Marty
4b8985e501 Suggestion for room alias.
Rename `Mention` to `IntentionalMention` for clarity
Remove dead code, there is no intentional mention for Room or RoomAlias.
Rename `IntentionalMention.AtRoom` to `IntentionalMention.Room` to match Rust naming
2024-08-21 15:32:05 +02:00
Benoit Marty
c420fcad18 Merge pull request #3240 from element-hq/feature/valere/message_shields
Timeline UI | MessageShield Support
2024-08-16 14:25:33 +02:00
Benoit Marty
0362498fae Make extension isCritical a val instead of a fun. 2024-08-16 09:56:01 +02:00
Benoit Marty
34268a30ea Iterate on shield mapping and rendering
Also handle click on the timeline and information displayed on long click.
2024-08-14 17:24:11 +02:00
Benoit Marty
5dceba8146 Merge branch 'develop' into feature/valere/message_shields 2024-08-14 12:37:31 +02:00
Jorge Martín
0ddadd8c5a Fix lint issues 2024-08-13 08:55:06 +02:00
Jorge Martín
903d24ea2f Improve APIs, add tests 2024-08-13 08:55:06 +02:00
Jorge Martín
252b3e11a0 Improve existing APIs 2024-08-13 08:55:06 +02:00
Jorge Martín
e16057a366 Initial implementation of the reset identity feature 2024-08-13 08:55:05 +02:00
ganfra
fa3fa2623e Merge branch 'develop' into feature/fga/pinned_message_banner_logic 2024-08-07 16:05:41 +02:00
ganfra
30e5688e26 timeline : allow rendering m.room.pinned_events 2024-08-06 17:28:23 +02:00
ganfra
ebc9fd745e Pinned events : introduce pinnedEventsTimeline method. 2024-08-01 18:22:22 +02:00
ganfra
3bc6cc0a94 Pinned events : clean up code 2024-07-30 16:40:18 +02:00
ganfra
6ad547833f Refactor userEventPermissions 2024-07-29 13:43:47 +02:00
ganfra
2605ddec7a Pin : expose the new rust sdk apis 2024-07-29 12:50:35 +02:00
ganfra
3adc6d0be8 Timeline Action : refactor how it's computed and align with iOS 2024-07-26 18:20:03 +02:00
Valere
33e09edd62 Timeline UI | MessageShield Support 2024-07-25 10:01:27 +02:00
ganfra
d1b1e16620 Merge branch 'develop' into feature/fga/room_preview_join_button_fallback 2024-07-24 16:34:35 +02:00
ganfra
f5d215ba0f Edit : fallback to room.edit when timeline item is not found. 2024-07-24 11:49:16 +02:00
ganfra
85d6acfc48 Join Room : makes sure we can join by alias 2024-07-23 21:17:35 +02:00
renovate[bot]
8a2335f7aa Update dependency org.matrix.rustcomponents:sdk-android to v0.2.33 (#3220)
* Update dependency org.matrix.rustcomponents:sdk-android to v0.2.33

* Fix API breaks

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Jorge Martín <jorgem@element.io>
2024-07-19 13:33:27 +02:00
Jorge Martin Espinosa
30154783e8 Use the right filename for log files so they're sorted in rageshakes (#3219)
* Use the right filename for log files so they're sorted in rageshakes

* Hide the suffix part so it's not changed by accident
2024-07-19 10:33:33 +00:00
Jorge Martin Espinosa
896b1a3e60 Add logging to help debug forced logout issues (#3208)
* Add logging to help debug forced logout issues

* Use tags instead of manually adding the values to the logs.

- Also add extension functions to easily get anonymized tokens from `Session`/`SessionData`.

* Make sure only 1 operation related to token persistence can run at the same time
2024-07-18 13:16:20 +00:00
Benoit Marty
79660dab51 Be more lenient on Matrix pattern to support existing rooms in the wild (will fix crash on debug build). 2024-07-17 10:08:25 +02:00
Benoit Marty
81bd3dcca0 Still need to support both eventId legacy and v4 2024-07-16 18:40:03 +02:00
Benoit Marty
48cbf57340 Add extra test for room alias. 2024-07-16 18:25:20 +02:00
Benoit Marty
7506070698 No need to make the block optional. 2024-07-16 18:23:25 +02:00
Benoit Marty
da7743f0bb Add test on MatrixPatterns functions. 2024-07-16 18:21:02 +02:00
Benoit Marty
220a8f67f5 Iterate on MatrixPatterns. 2024-07-16 18:06:18 +02:00
Jorge Martin Espinosa
89ec904c4a Restore intentional mentions in the markdown/plain text editor (#3193)
* Restore intentional mentions in the markdown/plain text editor

---------

Co-authored-by: ElementBot <benoitm+elementbot@element.io>
2024-07-15 18:27:59 +02:00
Jorge Martin Espinosa
176755ac33 Subscribe to RoomListItems in the visible range (#3169)
* Subscribe to `RoomListItems` in the visible range

This ensures the room list items always have updated info.
2024-07-11 10:54:56 +02:00
Jorge Martin Espinosa
bb47ff8f49 Unify the way we decide whether a room is a DM or a group room (#3100)
* Add centralised 'room is DM' check

Also add extension functions for `MatrixRoom` and `MatrixRoomInfo`.

* Use the centralised method and extension functions through the app, including:

- Room list.
- Room details screen.
- Invites.
- Notifications.

Replace most `isDirect` usages with `isDm`.

* Update screenshots

---------

Co-authored-by: ElementBot <benoitm+elementbot@element.io>
2024-07-10 16:28:46 +00:00
renovate[bot]
8aa4fbdade Update dependency org.matrix.rustcomponents:sdk-android to v0.2.31 (#3145)
* Update dependency org.matrix.rustcomponents:sdk-android to v0.2.31

* Use new Rust client side sorting API

* Make `RoomListEntriesUpdate.describe()` an extension function

* Remove `RoomListSummary.Filled` and `RoomListSummary.Empty`

* Fix icon sizes to pass the lint checks

* Update screenshots

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Jorge Martín <jorgem@element.io>
Co-authored-by: ElementBot <benoitm+elementbot@element.io>
2024-07-05 15:25:42 +00:00
Benoit Marty
b709984582 Use SDK to get Element Wellknown content. 2024-07-02 13:28:26 +02:00
Benoit Marty
cfa3035f4c Introduce UserServerResolver. 2024-07-02 10:22:56 +02:00
Benoit Marty
265ccae48f Remove dead code. 2024-07-02 10:20:25 +02:00
Benoit Marty
2663c3f26b Remove default value for languageTag and theme. 2024-07-01 14:30:18 +02:00
Jorge Martin Espinosa
cdbb46fa22 Bump Rust SDK version and adapt our code (#3068)
* Use the new SDK version
* Adapt the authentication service to the new Rust SDK APIs
* Remove `Timeline.enterSpecialMode(...)` as it's no longer necessary
2024-06-27 09:44:14 +00:00
ganfra
a77e5edef4 Merge branch 'develop' into feature/fga/draft_support 2024-06-26 15:22:00 +02:00
ganfra
ece740322c Draft : makes sure all existing tests passes 2024-06-25 15:17:18 +02:00
Benoit Marty
4d6a67e4d6 Let role and permissions screens works for invited room members too. 2024-06-24 13:21:46 +02:00