Commit Graph

16420 Commits

Author SHA1 Message Date
ElementBot be98d04f40 Update screenshots 2026-10-14 10:26:25 +00:00
Benoit Marty 933fc54e12 Iterate on add account onboarding UI. 2026-10-14 12:03:14 +02:00
Benoit Marty 6a516a02ae Iterate on the identity confirmation screen
Follow the multi-account design for the "Confirm your digital identity"
screen: use the dedicated "Sign out" string for the top bar action and add
a leading icon to the "Use another device" button.

Add a test to check that clicking on "Sign out" emits the expected event.

Part of #7768

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-14 11:56:28 +02:00
Benoit Marty f72af72d80 Add a back button to the account provider confirmation screen
The screen where the user enters the server address only supported the
system back gesture. Add a top app bar with a back button, consistent with
the screen to choose the account provider and FlowStepPage, so the user can
navigate back from it, especially when adding another account.

Part of #7768

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-14 11:35:13 +02:00
Jorge Martin Espinosa 566eb1f4f3 Use local SDK library for EC native too (#7916)
When a local SDK AAR file is present, ignore the version needed by the Element Call Matrix library.

This allows us to test local SDK builds.
2026-10-14 11:14:38 +02:00
Jorge Martin Espinosa 241f8e67bd Fix side-effects when tapping on a link in the new renderer (#7906)
The case where we move the pointer once we've started the click on a link wasn't taken into account, so the click or long click gestures weren't canceled if the gesture ended up being a 'move' one.

Simplify the handler and make it more idiomatic too.
2026-10-14 11:13:59 +02:00
Jorge Martin Espinosa 8a5c50d2b8 Fix File.getSizeOfFiles() double counting some files (#7907)
The `File.length()` docs state:

> Returns the length of the file denoted by this abstract pathname. The return value is unspecified if this pathname denotes a directory.

On Android, it *seems* to currently have the right behaviour, summing up the size of its children, which made `File.getSizeOfFiles()` double-count the size of some directories.

To avoid this, and be able to control the actual behaviour no matter what future Android versions do, let's count those ourselves.
2026-10-14 11:13:14 +02:00
Benoit Marty 6c1cc4e3f7 Handle account switch in RootFlowNode instead of in presenters
PreferencesRootPresenter and HomePresenter were updating the latest session
in the session store directly, relying on RootNavStateFlow to trigger the
navigation as a side effect. Changing the current session is app-level
navigation, so it is now forwarded through a new `navigateToSession` callback
up to RootFlowNode, which performs the session store update.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-14 10:37:15 +02:00
Benoit Marty 799f60b955 Generate null MapTiler BuildConfig values when not provided
Remove the default values from the Gradle file, the public MapTiler defaults
are now only defined in MapTilerDefaults. buildConfigFieldStr now accepts a
null value.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-14 10:11:08 +02:00
Benoit Marty 0149e6f65b Do not mix the homeserver MapTiler config with the build time one
The map URL builders now only use the MapTilerConfig they are given, falling
back to the public MapTiler defaults for the missing values, instead of the
values defined at build time. This avoids for instance sending the build time
API key to a tile server provided by the homeserver.

When there is no config, no static map URL builder is created, so no request
is performed.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-14 10:11:07 +02:00
renovate[bot] 9b3a9a0a2d Update dependency io.element.android:element-call-embedded to v0.28.0 (#7912)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2026-10-14 09:49:35 +02:00
Benoit Marty 80cfc2be8d Merge pull request #7911 from element-hq/feature/bma/disableLocationSharingWithoutMapTiler
Disable location sharing when no MapTiler config is available
2026-10-14 09:43:52 +02:00
Jorge Martin Espinosa 213ed22cad Bump SDK bindings to 26.10.12-nightly (#7909)
* Bump SDK bindings to `26.10.12-nightly`

* Fix API breaks in SDK bindings

* Fix doc comment
2026-10-13 22:28:22 +02:00
ElementBot cff4562b79 Update screenshots 2026-10-13 18:15:31 +00:00
renovate[bot] b84cf2aced Update sqldelight to v2.4.1 2026-10-13 17:56:01 +00:00
Benoit Marty 4b97d6ab96 Disable location sharing when no MapTiler config is available
LocationService now exposes the MapTiler config to use: the one provided by the
homeserver takes precedence over the build time one, and null means that no map
provider is configured. It is now session scoped, and isServiceAvailable()
returns a StateFlow derived from this config.

When no config is available:
- the location sharing option is hidden from the composer, and location events
  cannot be opened in the location viewer;
- the "Location sharing" entry is hidden from the settings;
- location events in the timeline render a placeholder, without performing any
  request to MapTiler.

The show and share location screens now get the config from LocationService
rather than fetching the homeserver config by themselves.

Closes element-hq/element-android-enterprise#69

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-13 17:15:37 +02:00
ganfra 9e12ec7505 Improve accessibility of timeline selection mode 2026-10-13 14:45:00 +02:00
Benoit Marty 5104e044ff Merge pull request #7862 from element-hq/renovate/kotlin
Update dependency org.jetbrains.kotlinx:kover-gradle-plugin to v0.9.11
2026-10-13 13:01:19 +02:00
Jorge Martin Espinosa 9cc5cf9a01 Add total unread notification count to home screen (#7891)
* Add total unread notification count to home screen

This will be calculated on each sync heartbeat (for now, using the state updates for the room list service).

* Simplify `counter` parameter logic

* Read the total unread count when the home screen is first displayed

---------

Co-authored-by: Benoit Marty <benoitm@element.io>
2026-10-13 10:58:07 +00:00
Benoit Marty f187409db3 Apply suggestion: 'rangeTo' or the '..' call should be replaced with '..<' 2026-10-13 12:55:50 +02:00
ElementBot 0dce4b9e49 Update screenshots 2026-10-13 10:11:22 +00:00
Benoit Marty 8923ba1e1b Animate the dismissal of the banners in the room list
Add DismissibleBanner, which makes a banner shrink and fade out when it is dismissed, and
invokes the dismiss callback when the animation is over, so that the banner is removed from
the list when its height is 0. Apply it to all the dismissible banners of the room list.

The banners are now rendered in a slot which is always the first item of the room list, so
that the rooms, which do not have a key, keep the same index and the scroll position is
preserved when a banner is removed. The visible range of rooms sent to the SDK does not
include this slot anymore.

FullScreenIntentPermissionBanner and BatteryOptimizationBanner now take callbacks instead
of their state, like the other banners.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-13 11:45:01 +02:00
Benoit Marty 14710599a7 Announce the swipe gesture on the account avatar
Display a banner on the room list when 2 or more accounts are logged in, to let the user know
that they can swipe their avatar to switch account. The banner is stored as a new
Announcement.SwipeAvatarToSwitchAccount, and is dismissed when the user taps on it, or when
the user switches account by swiping their avatar.

The banner is displayed at the same place as the new notification sound banner, but never
at the same time.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-13 11:44:44 +02:00
Benoit Marty 50aa723f63 Merge pull request #7899 from element-hq/feature/bma/multiAccountDeviceVerification
Show account information on the identity confirmation screen
2026-10-13 11:31:13 +02:00
Benoit Marty ffe8f4a14e Merge pull request #7900 from element-hq/feature/bma/settingsMainThreadJank
Fix animation glitches when opening the settings
2026-10-13 11:30:36 +02:00
ElementBot 092cded211 Update Matrix Rust SDK to 26.10.07-nightly (#7880)
* Update Matrix Rust SDK to 26.10.07-nightly

* Adapt to the new QR code login task API

`generate()` and `scan()` of `GrantLoginWithQrCodeHandler` and `LoginWithQrCodeHandler`
now return a task instead of suspending until the flow is over. Wait for the task to
complete, and cancel it if the coroutine is cancelled, so that the flow is also stopped
on the Rust side.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>

* Add tests for the cancellation of the QR code login tasks

Check that cancelling the coroutine of the link new device handlers and of the QR code
login cancels the task returned by the SDK, so that the flow is stopped on the Rust side.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>

* Fix import ordering in the link new device handler tests

ktlint expects the imports to be sorted in lexicographic order.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: Benoit Marty <benoit@matrix.org>
Co-authored-by: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-13 11:21:21 +02:00
Benoit Marty 3170ff4422 Remove useless Unit type. 2026-10-13 10:42:05 +02:00
Benoit Marty 259fc222da Import strings for the swipe account banner 2026-10-13 09:45:23 +02:00
Benoit Marty d5780507c9 Make storeUserProfile main-safe instead of wrapping getUserProfile 2026-10-13 09:28:49 +02:00
Benoit Marty 6049f25a3e Create the LocalMedia off the main thread when picking or sharing media
LocalMediaFactory.createFromUri queries the ContentResolver and can decode the media, it was called on the main thread from the picker callbacks and when sharing a file.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-12 14:33:18 +02:00
Benoit Marty 865cca6764 Load the push distributors off the main thread in the notification settings
Getting the distributors queries the PackageManager and the Play Services, it was done during the first composition of the screen.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-12 14:33:17 +02:00
Benoit Marty 6efb10df11 Write the push history off the main thread
The push history was written to the database synchronously, from the app coroutine scope which runs on the main thread, for every received push. Make PushHistoryService.onPushResult suspend and run all the database queries on the IO dispatcher.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-12 14:33:17 +02:00
Benoit Marty 9be2a31c5f Schedule the background search backfill off the main thread
Checking if the work is already scheduled does a blocking WorkManager query, which was done on the main thread at session start.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-12 14:33:16 +02:00
Benoit Marty 149dedcc03 Store the user profile off the main thread when it is updated by the SDK
Same issue as when refreshing the profile manually: the profile listener stored the profile (Base64 encoding and session database access) from the session coroutine scope, which runs on the main thread.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-12 14:33:16 +02:00
Benoit Marty 404c26c62e Fetch and map the thread list items off the main thread
The thread list subscription was launched in the room coroutine scope, which runs on the main thread, so the initial sync FFI call and the mapping of all the items and diffs were done on the main thread every time a room was opened.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-12 14:33:15 +02:00
Benoit Marty 23a79ad987 Merge pull request #7896 from element-hq/sync-localazy
Sync Strings
2026-10-12 13:56:43 +02:00
Benoit Marty 80578d799f Merge pull request #7882 from element-hq/feature/bma/multiAccountShareAtRoot
Keep the incoming share displayed when the current account is signed out
2026-10-12 11:19:49 +02:00
ElementBot 9beef99760 Update screenshots 2026-10-12 09:07:31 +00:00
Benoit Marty 8912341439 Avoid database access on the main thread when opening the settings
`getUserProfile()` was storing the user profile (DB read, avatar Base64 encoding, DB write) on the caller
dispatcher, i.e. the main thread when called from a presenter, causing glitches in the screen transition.
- Run the whole `getUserProfile()` on the session dispatcher.
- Make `DatabaseSessionStore` main-safe by running the queries on the IO dispatcher.
- Do not refresh the profile twice from the settings screen.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-12 10:42:19 +02:00
ElementBot 7ffb36fe4b Update screenshots 2026-10-12 08:13:03 +00:00
Benoit Marty 87e1deaccf Show account info on the identity confirmation screen
Render an AccountInfoCard with the current user on the "Confirm your digital identity" screen,
so the user knows which account needs to be verified.

Closes #7898

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-12 09:56:57 +02:00
bmarty 8100fa6555 Sync Strings from Localazy 2026-10-12 00:37:35 +00:00
Jorge Martin Espinosa f12b9c77d5 Enable global search feature flag (#7890)
Enable the global search feature by default for all variants of the app
2026-10-09 15:24:29 +00:00
Benoit Marty d29e4e5f0c Merge remote-tracking branch 'origin/develop' into feature/bma/multiAccountShareAtRoot
# Conflicts:
#	libraries/roomselect/impl/src/test/kotlin/io/element/android/libraries/roomselect/impl/RoomSelectPresenterTest.kt
2026-10-09 17:11:58 +02:00
Benoit Marty 00dab131dd Ask for session verification before sharing with an unverified account
The incoming share is now displayed on top of the root, so the FTUE, and the session verification in particular, could be bypassed.

- When the current account is not verified, wait for the FTUE to be complete before displaying the incoming share, as before.
- When the user selects another account which is not verified in the room select screen, display the session verification flow of
  the FTUE for this account on top of the share. As in the FTUE, the user has to verify the session or to sign out.
- Expose the FTUE session verification flow with a new SessionVerificationEntryPoint, displayed by OtherSessionVerificationNode
  which sets up the session graph of the account to verify.
- Introduce RoomSelectNavigator so that RoomSelectPresenter can request the verification of the selected session.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-09 17:00:48 +02:00
Benoit Marty 5d498ee37b Merge pull request #7883 from element-hq/feature/bma/roomSelectSearchField
Use a search field to filter the rooms in the room select screen
2026-10-09 15:09:50 +02:00
Benoit Marty 135c10b37f Merge pull request #7886 from element-hq/feature/valere/element_call_rc7
Update element-call-android to 0.1.0-rc.7
2026-10-09 14:45:39 +02:00
Benoit Marty 3ae227946b Merge pull request #7798 from element-hq/renovate/io.element.android-element-call-embedded-0.x
Update dependency io.element.android:element-call-embedded to v0.27.0
2026-10-09 14:39:16 +02:00
Benoit Marty 3b5696d37d Merge pull request #7843 from element-hq/renovate/io.sentry-sentry-android-8.x
Update dependency io.sentry:sentry-android to v8.59.0
2026-10-09 14:38:34 +02:00
Benoit Marty 85224988af Room select: address review remarks
- Scroll the list to the top using a LaunchedEffect instead of recreating the LazyListState on each search query change.
- Use isBlank to check the search query, to match the logic of RoomSelectSearchDataSource.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-09 14:34:45 +02:00