Commit Graph

853 Commits

Author SHA1 Message Date
Jorge Martin Espinosa
1f5f6896c6 Fix marking a room as read re-instantiates its timeline (#5628)
* Add `Timeline.markAsRead` to avoid reinstantiating the timeline using `Room.markAsRead`

* Mark as read when exiting the room screen, destroy the timeline when fully closed

* Ensure `MarkAsFullyReadAndExit` event can only be processed once

* Fix `DelayedVisibility` not being displayed in previews
2025-10-30 08:39:06 +01:00
Benoit Marty
cc050a1f26 Merge branch 'develop' into feature/bma/mediaForward
# Conflicts:
#	appnav/src/main/kotlin/io/element/android/appnav/room/joined/JoinedRoomLoadedFlowNode.kt
2025-10-29 12:41:58 +01:00
Benoit Marty
21bae4aee2 Add Forward action to MediaDetailsBottomSheet. Closes #5454
Improve API of Callback when forwarding Event.
2025-10-28 18:13:53 +01:00
Jorge Martín
003af22c31 Fix api breaks:
- `ComposerDraft` now takes a list of media attachments.
- `HumanQrLoginException` has a couple of new cases.
- `Client.loginWithQrCode` now returns a `LoginWithQrCodeHandle`, which we need to call using `scan` to have the same behaviour as before.
2025-10-28 17:14:40 +01:00
Benoit Marty
826cacf209 Remove @Inject, not necessary anymore when class is annotated with @ContributesBinding 2025-10-22 18:52:37 +02:00
Jorge Martin Espinosa
7491b5479a Allow uploading notification push rules in bug reports (#5538)
* Allow uploading push rules in bug reports

* Improve bug report screen previews

* Update screenshots

---------

Co-authored-by: ElementBot <android@element.io>
2025-10-15 11:45:04 +02:00
Benoit Marty
a83630169e Fix API break in QrCodeLoginStep. 2025-10-13 15:52:06 +02:00
Benoit Marty
245509cd88 Make Timeline.Mode stable 2025-10-09 18:22:40 +02:00
Benoit Marty
264cf9e1b3 Make VerificationRequest stable 2025-10-09 18:22:38 +02:00
Benoit Marty
2d9b034940 Make Outgoing stable 2025-10-09 18:22:36 +02:00
Benoit Marty
e6cd8d5fb5 Remove useless Immutable annotation 2025-10-09 18:22:33 +02:00
Benoit Marty
589954203b Make Role stable 2025-10-09 18:22:30 +02:00
Benoit Marty
8f703c2aa7 Rename RoomDirectoryList.State to RoomDirectoryList.SearchResult to avoid this class to be checked for stability. 2025-10-09 18:22:27 +02:00
Benoit Marty
7ce2c08f6e Merge pull request #5490 from element-hq/feature/bma/improveImmutables
Ensure that we are using Immutable instead of Persistent
2025-10-09 11:48:32 +02:00
Benoit Marty
9dd6f7be68 Let SpaceRoom be stable the proper way. 2025-10-08 16:42:48 +02:00
Benoit Marty
da78386d25 Add Konsist test to check that toPersistentList() is not used.
Same for `toPersistentSet()` and `toPersistentMap()`.
Fix existing issues.
2025-10-08 15:51:18 +02:00
ganfra
4b39c668db feature(space): makes sure SpaceRoom is marked as Immutable 2025-10-08 14:07:57 +02:00
ganfra
dde6dd0ed5 feature(space): use SpaceRoom.displayName from sdk 2025-10-07 20:15:46 +02:00
Benoit Marty
365116a40a Map SpaceRoom.displayName 2025-10-07 18:07:27 +02:00
ganfra
824d4075f6 Merge pull request #5468 from element-hq/feature/fga/space_tweaks
Spaces : some tweaks around ui
2025-10-07 10:55:05 +02:00
ganfra
1c819e5774 feature(space): introduce SpaceRoomVisibility and remove room count 2025-10-06 20:50:05 +02:00
Benoit Marty
cabeb19ae1 Naming convention and use MatrixMediaLoader instead of MatrixClient for Coil factories. 2025-10-06 15:13:41 +02:00
Benoit Marty
67c6a1bd5f Let MatrixClient exposes val instead of fun for the services. 2025-10-06 15:12:35 +02:00
ganfra
ea08edb912 feature(space): compute space room name locally 2025-10-06 14:21:01 +02:00
Hubert Chathi
7c61c70b62 Only offer to verify if a cross-signed device is available (#5433)
* Only offer to verify if a cross-signed device is available

* Fix tests

* use the right exception mapper

* adjust flag name and logic in ChooseSelfVerificationState

* add comment

* switch order of states to match previous logic
2025-10-06 12:40:52 +02:00
Benoit Marty
ffde95fb84 Merge pull request #5432 from element-hq/feature/bma/leaveSpace
Leave space: use SDK API.
2025-10-03 16:43:45 +02:00
ganfra
d577f02126 Merge pull request #5449 from element-hq/feature/fga/room_list_space_invite
Room list space invite
2025-10-03 13:17:28 +02:00
ganfra
576429b183 feature(space) : filter space manually so we can show space invites 2025-10-02 17:38:47 +02:00
Benoit Marty
c36577889d Leave space: use the SDK API. 2025-10-02 17:26:02 +02:00
Benoit Marty
fb346a1587 Let SpaceId be an alias of RoomId 2025-10-02 17:25:33 +02:00
Benoit Marty
a36f10ae30 Update SDK 2025-10-02 17:25:31 +02:00
Benoit Marty
0f94ebc56e We do not need CurrentSessionIdHolder anymore.
The SessionId can be provided by SessionMatrixModule and injected in constructors directly.
2025-10-01 17:57:13 +02:00
ganfra
388cb31700 misc (space) : ensure SpaceRoomList is destroyed 2025-10-01 10:49:35 +02:00
Jorge Martin Espinosa
80e869c93e Follow permalinks to and from threads (#5414)
* Implement navigation to event inside a thread when a permalink is used

* Fix permalink navigation in threads to rooms

* Fix navigating to a different thread from a permalink in an existing thread

* Fix tests

* Add missing tests for thread navigation

* Reduce number of diff between ThreadedMessagesNode.kt and MessagesNode.kt

* Navigate back to the room when a link to the current room is clicked in a thread.

---------

Co-authored-by: Benoit Marty <benoitm@element.io>
Co-authored-by: Benoit Marty <benoit@matrix.org>
2025-09-30 09:18:13 +00:00
Benoit Marty
ef29c4ba97 Remove code duplication around UserProfile mapper. 2025-09-29 15:38:08 +02:00
Benoit Marty
fd2041a7ef SessionVerificationRequestDetails: map deviceDisplayName. 2025-09-29 15:38:07 +02:00
Benoit Marty
a6720078b4 Merge branch 'develop' into feature/bma/leaveSpace 2025-09-26 15:46:57 +02:00
Benoit Marty
73a6ba2849 Multi accounts - experimental first implementation (#5285)
* Multi account - Do not reset analytics store on sign out.

Else when 1 of many accounts is removed, the analytics opt in screen is displayed again.

* Multi accounts - first implementation.

* Multi accounts - Prevent user from logging twice with the same account

* Multi accounts - ignore automatic GoBack in case of error.

* Multi accounts - update first view when adding an account.

* Rename method storeData to addSession.

* Multi accounts - handle account switch when coming from a notification

* Multi accounts - handle login link when there is already an account.

* Multi accounts - handle click on push history for not current account.

* Multi accounts - improve layout and add preview.

* Add accountselect modules

* Multi accounts - incoming share with account selection

* Multi accounts - check the feature flag before allowing login using login link.

* Multi accounts - swipe on account icon

* Cleanup

* Multi accounts - fix other implementation of SessionStore

* Multi accounts - fix PreferencesRootPresenterTest

* Multi accounts - Add test on AccountSelectPresenter

* Multi accounts - Fix test on HomePresenter - WIP

* Update database to be able to sort accounts by creation date.

* Add unit test on takeCurrentUserWithNeighbors

* Fix test and improve code.

* Add exception

* Multi accounts - handle permalink

* Code quality

* Multi accounts - localization

* Fix issue after rebase on develop

* Fix issue after rebase on develop

* Fix tests

* Fix tests

* Fix tests

* Fix tests

* Update Multi accounts flag details.

* Add missing test on DatabaseSessionStore

* Add missing preview on LoginModeView

* Remove dead code.

* Add missing preview on PushHistoryView

* Document API.

* Rename API and update test.

* Remove MatrixAuthenticationService.loggedInStateFlow()

* Update screenshots

* Remove unused import

* Add exception

* Fix compilation issue after rebase on develop.

* Update screenshots

* Fix test

* Avoid calling getLatestSession() twice

* Rename `matrixUserAndNeighbors` to `currentUserAndNeighbors`

* Extract code to its own class.

* Add comment to clarify the code.

* Init current user profile with what we now have in the database.

It allows having the cached data (user display name and avatar) when starting the application when no network is available.

* Let the RustMatrixClient update the profile in the session database

* Fix test.

* When logging out from Pin code screen, logout from all the sessions.

tom

* Make PushData.clientSecret mandatory.
Also do not restore the last session as a fallback, it can lead to error in a multi account context, or even when a ghost pusher send a Push.

* Change test in RustMatrixAuthenticationServiceTest

* Do not use MatrixAuthenticationService in RootFlowNode, only use SessionStore

* Remove MatrixAuthenticationService.getLatestSessionId()

* Fix compilation issue after merging develop

* Add test on DefaultAccountSelectEntryPoint

* Fix compilation issue after merging develop

* Introduce LoggedInAccountSwitcherNode, to improve animation when switching between accounts.

* Rename Node to follow naming convention.

* Fix navigation issue after login.

* Remove unused import

* Revert "Fix navigation issue after login."

This reverts commit e409630856d7a7e741548016d7afe174ff1b40f7.

* Revert "Rename Node to follow naming convention."

This reverts commit 883b1f37c7207512d9f6605749977ad9045846a1.

* Revert "Introduce LoggedInAccountSwitcherNode, to improve animation when switching between accounts."

This reverts commit 9c698ff8152aceb5fd2b8b5ab5f609d28de64d24.

* Metro now have `@AssistedInject`.

* Update screenshots

* Introduce DelegateTransitionHandler and use it in RootFlowNode

---------

Co-authored-by: ElementBot <android@element.io>
Co-authored-by: ganfra <francoisg@element.io>
2025-09-26 15:45:06 +02:00
Benoit Marty
bc465d724a Leave space - Add screen to leave a space. 2025-09-26 14:14:00 +02:00
Jorge Martin Espinosa
f1cd80ede8 Use shared recent emoji reactions from account data (#5402)
* Use shared recent emoji reactions from account data

- Add `AddRecentEmoji` and `GetRecentEmojis` use cases to avoid injecting the whole `MatrixClient` for just one of these operations.
- Update the UI and logic of the emoji picker and message context menu to include the recent emojis.
- Add `CoroutineDispatchers.Default` with the defaults coroutines to use in the app for ease of use.

* Instead of replacing suggested emojis, concatenate recent ones removing duplicates

* Update screenshots

---------

Co-authored-by: ElementBot <android@element.io>
2025-09-26 11:04:34 +00:00
renovate[bot]
644c8284e4 Update dependency org.matrix.rustcomponents:sdk-android to v25.9.25 (#5412)
* Update dependency org.matrix.rustcomponents:sdk-android to v25.9.25

* Adapt to SDK changes:

`MessageLikeEventType` is now a sealed interface and has a new `data class Other(val v1: String)` case.

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Jorge Martín <jorgem@element.io>
2025-09-25 14:33:15 +00:00
ganfra
28bca11c03 sdk (space) : expose the via parameter from space room 2025-09-24 14:11:17 +02:00
ganfra
718b4dd11b sdk (space) : use the new space/spaceUpdate api from space list 2025-09-24 12:48:24 +02:00
Benoit Marty
461565fc9c Merge branch 'develop' into feature/fga/join_space 2025-09-24 11:20:17 +02:00
Jorge Martin Espinosa
3a3dce150a Add thread decoration with latest event details (#5355)
* Add thread decoration with latest event details
* Update screenshots

---------

Co-authored-by: ElementBot <android@element.io>
2025-09-23 14:57:50 +00:00
ganfra
5cda6730c4 Merge branch 'develop' into feature/fga/join_space 2025-09-19 16:35:55 +02:00
Benoit Marty
37d036cb12 Remove MatrixAuthenticationService.getLatestSessionId() 2025-09-19 10:57:26 +02:00
Benoit Marty
d9755234dc Remove MatrixAuthenticationService.loggedInStateFlow() 2025-09-19 10:57:20 +02:00
Benoit Marty
595cec7d33 Merge branch 'develop' into feature/bma/testEntryPoint 2025-09-18 18:58:30 +02:00
Benoit Marty
6ad8be2b12 Merge pull request #5306 from element-hq/feature/bma/removeDeadCode
Remove dead code
2025-09-18 18:11:06 +02:00