Commit graph

948 commits

Author SHA1 Message Date
Benoit Marty
4ad495d36c
Add support for slash commands (under Feature Flag) (#6482)
* Add support for slash commands

* Update screenshots

* Rename module `slash` to `slashcommands`

* Rename `SlashCommand` to `SlashCommandService`

* Introduce MsgType in order to send text message with a different msgtype value.

* Format file and add parameter names, add default values and cleanup

* Add isSupported parameter to filter out unsupported yet commands.

* Slash commands: disable suggestions if the feature is disabled.

* Fix sending shrug command.

* Add missing test on SuggestionsProcessor

* Add tests on MessageComposerPresenter about slash command.

* Fix import ordering

* Add missing tests on CommandExecutor

* Add missing tests in MarkdownTextEditorStateTest

* Slash commands: Improve code when sending message with prefix.

* Slash commands: Add support for /unflip

---------

Co-authored-by: ElementBot <android@element.io>
2026-04-02 16:15:32 +02:00
ganfra
92920b862b
Merge pull request #6342 from element-hq/feature/fga/live_location_sharing_setup
Setup live location sharing feature
2026-03-24 15:46:45 +01:00
renovate[bot]
a6a63736e7
fix(deps): update dependency org.matrix.rustcomponents:sdk-android to v26.03.23 (#6444)
* fix(deps): update dependency org.matrix.rustcomponents:sdk-android to v26.03.23

* Fix `RoomInfo` test fixture

* Add `activeCallIntentConsensus` to `RoomInfo`

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Jorge Martín <jorgem@element.io>
2026-03-24 11:22:32 +01:00
ganfra
9a984e1423 Merge branch 'develop' into feature/fga/live_location_sharing_setup 2026-03-24 10:17:24 +01:00
renovate[bot]
0c8a01d2cf
fix(deps): update dependency org.matrix.rustcomponents:sdk-android to v26.03.19 (#6411)
* fix(deps): update dependency org.matrix.rustcomponents:sdk-android to v26.03.18

* Fix API breaks

* Add compatibility with rustls (#6367)

A new `rustls-platform-verifier-android` library has to be added to the project, it'll be called from Rust to get access to the certificates on Android.

Originally, this was supposed to be added as a local maven repo pointing to the rust crate that publishes the AAR, but that's just plain terrible (more details [here](https://github.com/rustls/rustls-platform-verifier#android).

Instead, what we can do is use a script that uses `cargo-download` to download the latest crate or a specified version, unzip it and add the `aar` file to the `:libraries:matrix:impl` module.

* Try fixing Sonar with local AAR files

* Remove `UserCertificatesProvider`: this is no longer needed after integrating rustls

* Added some docs for rustls and its `platform-verifier` library

* Upgrade SDK to `26.03.19`: this version contains a workaround that allows the app to use the same TLS verifier as before, fixing the Let's Encrypt issues we saw with some homeservers (like element.io)

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Jorge Martín <jorgem@element.io>
2026-03-20 16:20:37 +01:00
ganfra
96147967ac Code cleanup 2026-03-12 12:35:46 +01:00
ganfra
0056a3f163 Fix compilation 2026-03-09 21:19:57 +01:00
ganfra
f2d4ffc5bd Introduce LiveLocationContent for the timeline (needs sdk) 2026-03-09 20:54:01 +01:00
ganfra
ffad69b7b9 Make sure we can display both Live and Static locations in ShowLocation 2026-03-09 20:54:01 +01:00
ganfra
f25b2a8045 Expose liveLocationSharing methods from sdk 2026-03-09 20:54:01 +01:00
Valere
14cea294bb Merge branch 'develop' into valere/rtc/voice_call 2026-03-06 12:22:28 +01:00
Valere
bad6085fb2 review: consistency use isAudioCall everywhere (instead of voiceOnly) 2026-03-06 12:19:05 +01:00
Benoit Marty
c97bf08008 Rename our classes too. 2026-03-04 17:41:44 +01:00
Valere
0e3722e52e Merge branch 'develop' into valere/rtc/voice_call 2026-03-04 13:46:54 +01:00
Valere
7ef43abd57 Support incoming audio only calls 2026-03-04 08:56:33 +01:00
Jorge Martin Espinosa
8fab22ec7d
Make 'room list catch-up' analytics transaction network aware (#6233)
* Make 'room list catch-up' analytics transaction network aware.
* Add `RoomListService.isInitialSyncDone`. Use this to simplify `DefaultAnalyticsRoomListStateWatcher`'s logic.
2026-03-03 13:16:58 +01:00
Benoit Marty
b65b9eeab9
Merge pull request #6035 from element-hq/fix/remove-fragment-part-in-mxc-urls
Add `MediaSource.safeUrl` for removing invalid fragment part from URLs
2026-03-03 11:57:49 +01:00
Valere
5491040ac5 WIP: Support using Element Call for voice calls in DMs 2026-03-03 11:50:22 +01:00
Benoit Marty
04977f655f Fix API break. 2026-03-02 09:40:42 +01:00
Benoit Marty
43319f6e90 Handle EventRedacted case. Fixes #5569 2026-03-02 09:15:53 +01:00
Jorge Martín
5fb9dcb0da Apply suggestion:
- Added `MediaSource.safeUrl` property replacing `withCleanUrl` method.
- Made `url` private so it can't be used externally.
- Reverted code in `CoilMediaFetcher`
- Also add tests
2026-02-27 09:52:17 +01:00
Jorge Martín
fecbabb0e4 Add MediaSource.withCleanUrl method that removes invalid fragment data from MXC urls
We've seen some MXC urls in the wild having some `mxc://foo/bar#auto` fragment suffix, which is invalid, but the URL before that fragment part is valid and can be displayed
2026-02-27 09:52:17 +01:00
renovate[bot]
efb20985a0
Update dependency org.matrix.rustcomponents:sdk-android to v26.02.19 (#6229)
* Update dependency org.matrix.rustcomponents:sdk-android to v26.02.19

* Fix breaking API changes: added `isLowPriority` to `RoomInfo` and `RoomSummary`.

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Jorge Martín <jorgem@element.io>
2026-02-20 09:01:07 +01:00
renovate[bot]
8c20770d21
Update dependency org.matrix.rustcomponents:sdk-android to v26.2.16 (#6211)
* Update dependency org.matrix.rustcomponents:sdk-android to v26.2.16

* Fix log rotation breaking changes. The new values match iOS (https://github.com/element-hq/element-x-ios/pull/5108/)

* Fix `aRustRoomInfo()` test fixture

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Jorge Martín <jorgem@element.io>
2026-02-17 10:42:31 +01:00
Benoit Marty
f93dfbdae4 Remove NavigationState.Space.
We do not have the concept of current space.
2026-02-11 20:41:55 +01:00
ganfra
0dec3a1cb6 Merge branch 'develop' into feature/fga/space_ui_tweaks 2026-02-10 09:31:50 +01:00
Benoit Marty
0311fc9f01 QRCode login: treat not found error as expired error.
Reorder some when cases.
2026-02-09 15:14:18 +01:00
Skye Elliot
1e268b0709
Add history sharing badges to room details (#6132)
* feat: Add history sharing badges to room details view

* tests: Add snapshots for history sharing room details badges

* fix: Disable soft-wrapping in badges, use FlowRow

* tests: Add unit test for `RoomDetailsState` and history sharing badges.

* tests: Add `MatrixBadgeAtomNeutralWrappingPreview` to exceptions

* chore: Re-order `MatrixBadgeAtom` previews

* fix: Add `Immutable` annotation to `RoomHistoryVisibility`.

* fix: Correct translation for shared badge
2026-02-06 19:03:52 +00:00
renovate[bot]
4cb3b16914
Update dependency org.matrix.rustcomponents:sdk-android to v26.2.6 (#6144)
* Update dependency org.matrix.rustcomponents:sdk-android to v26.2.5

* Fix breaking API changes:
- Add temporary imlementation for `RustClientSessionDelegate.onBackgroundTaskErrorReport`, logging unrecoverable errors in background tasks of the SDK.
- Change `TimelineEventTypeFilter` to `TimelineEventFilter`.
- Support new `LatestEventValue.RemoteInvite`.

* Update the Rust SDK to `26.2.6`

* Fix API changes: `TimelineFocus.PinnedEvents` no longer takes any arguments

* Fix test fixtures: `NotificationItem` has a `rawEvent` field now

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Jorge Martín <jorgem@element.io>
2026-02-06 12:40:03 +00:00
ganfra
0118b47a38 Update SpaceRoom visibility related UI 2026-02-06 09:36:42 +01:00
ganfra
6327641469
Merge pull request #6136 from element-hq/feature/fga/space_room_list_filter
Add Space Filters feature for Room List
2026-02-05 16:14:16 +01:00
ganfra
c7015c367c Add tests for SpaceFiltersPresenter and SpaceFiltersView and fix quality 2026-02-04 14:42:57 +01:00
Jorge Martin Espinosa
bd6bad963e
Remove JoinRule.Private from the codebase (#6129)
It shouldn't be in use, since it was never properly defined:

- The `Private` values coming from the SDK are considered to be `Invite` instead.
- Remove any existing `JoinRule.Private` usages in our code.
2026-02-03 19:27:22 +01:00
ganfra
212a8e3aa3 Add room list filter combining based on space selection 2026-02-02 21:46:33 +01:00
ganfra
a60d07eb2a Spaces : expose new SpaceServiceFilter 2026-02-02 21:02:55 +01:00
ganfra
bc9a46a821 Spaces : some cleanup on SpaceService 2026-02-02 21:02:54 +01:00
ganfra
440eacc892
Merge pull request #6117 from element-hq/feature/fga/room_list_filter_rust
Refactor room list filtering to use Rust SDK
2026-02-02 10:58:21 +01:00
ganfra
babaa7351f Add tests and clean code after RoomList Filter rework 2026-01-30 15:33:51 +01:00
Jorge Martin Espinosa
95b6356d0b
Add special flow for leaving a space as the last owner (#6112)
* When the user is in a v12 room, use different UI to select the last owner when leaving

- Add `LeaveSpaceRoom.areCreatorsPrivileged` to detect when this is happening.
- Import new strings.
- Build the new UI.
- Attach it to a change member roles screen navigation.

* Don't display the `isLastOwner` UI if the user is the only joined one in the room

* Rename `LeaveSpaceState.isLastOwner` to `.needsOwnerChange`. This way, it's easier to understand the difference with the passed `LeaveSpaceRoom.isLastOwner` value

* Add a test for the new check of user not being the last joined member

* Fix paddings in `LeaveSpaceView`

* Update screenshots

---------

Co-authored-by: ElementBot <android@element.io>
2026-01-30 09:10:00 +00:00
ganfra
5c3fc13052 Refactor room list filtering to use Rust SDK 2026-01-29 22:08:12 +01:00
ganfra
a85c566341 Clean up unused imports and improve code documentation 2026-01-27 18:43:38 +01:00
ganfra
e896c7604d Iterate on manage space rooms, but not happy with the reset method. 2026-01-27 18:43:38 +01:00
ganfra
ae4d635357 Add SpaceRoomList extension functions for pagination 2026-01-27 18:43:38 +01:00
ganfra
5f52b38de6 Add reset method to SpaceRoomList 2026-01-27 18:43:38 +01:00
renovate[bot]
bcd707d307
Update dependency org.matrix.rustcomponents:sdk-android to v26.1.27 (#6096)
* Update dependency org.matrix.rustcomponents:sdk-android to v26.1.27

* Fix breaking API changes: `LeaveSpaceRoom.isLastAdmin` is now `LeaveSpaceRoom.isLastOwner`.

* Rename `isLastAdmin` to `isLastOwner` in our codebase too.

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Jorge Martín <jorgem@element.io>
2026-01-27 15:02:55 +00:00
Jorge Martin Espinosa
62768359cb
Create a new room in a space (#6061)
* Add `SpaceService.editableSpaces` and `SpaceService.addChildToSpace`

* Add `parentSpace` to `CreateRoomConfig`

* Allow setting a parent space to a room in `ConfigureRoomPresenter`, make sure the room is added to the parent space when creating it

* `ConfigureRoomPresenter`: Load the list of possible spaces a room can be added to

* Refactor `RoomVisibilityState` to internally use `JoinRuleItem`

This gets rid of `RoomAccess` and `RoomAccessItem`, and it will allow us to map the join rule items in a cleaner way to both join rules and the UI

* Implement the UI changes:

- Display the parent space.
- Allow selecting a new one.
- Import needed strings.

* Fix existing tests

* Add `@Immutable` annotation to `SpaceRoom`, since it was detected as unstable.

Maybe because of `RoomType`?

* Update screenshots

---------

Co-authored-by: ElementBot <android@element.io>
2026-01-26 18:23:02 +01:00
Jorge Martin Espinosa
57e0b74482
Use MediaPreviewValue.Private to check if media should be displayed in notifications (#6038)
* Use `MediaPreviewValue.Private` to check if images should be displayed in notifications

Also added `NotificationData.roomJoinRule` so we can use it to check if the room is public or not

* Add logging message for cases when we should have an image uri it turns out we don't
2026-01-23 09:01:52 +00:00
ganfra
c53dbf7b2d Quality improvements after PR review 2026-01-22 19:57:04 +01:00
ganfra
8e69174a11 Implement Space "Add existing rooms" logic and ui 2026-01-21 17:33:30 +01:00
ganfra
4d73f9fb43 Add addChildToSpace method to SpaceService 2026-01-21 17:33:30 +01:00