1
0
mirror of https://github.com/element-hq/element-x-android.git synced 2026-10-25 06:59:19 +03:00

47 Commits

Author SHA1 Message Date
mxandreas
13a5c5ce1d Merge remote-tracking branch 'origin/develop' into mxandreas/disable-public-rooms
# Conflicts:
#	enterprise
2026-10-09 09:58:27 +03:00
mxandreas
118b5448ac Revert to the SessionEnterpriseService approach 2026-10-09 09:50:14 +03:00
mxandreas
f2310cc530 Made the hooks of room creation and security & privacy screen more generic. 2026-10-06 09:53:26 +03:00
mxandreas
84fdbbe573 Add a hook to disable public rooms/spaces on UI. 2026-10-05 09:31:31 +03:00
Benoit Marty
954eb731e7 Remove unused Gradle dependencies
Remove dependencies flagged as unused by the Dependency Analysis Gradle Plugin
(`./gradlew buildHealth`) and explicitly declared in module build files.

Removals were skipped when the dependency provides transitively something the
module (or a consumer of an `api` dependency) uses directly, as well as for
runtime-only dependencies (element-call-embedded, sentry-android,
rustls-platform-verifier). Dependencies added by the convention plugin helpers
(composeDependencies, testCommonDependencies) are left untouched.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-02 15:47:48 +02:00
Benoit Marty
6887092ce4 Replace String by AccountProvider to be able to get baseUrl and serverName. 2026-09-14 09:56:16 +02:00
Benoit Marty
a817b6f219 Rename methods and update documentation. 2026-09-08 17:06:53 +02:00
Benoit Marty
1f18a18917 Iterate on hooks implementation 2026-09-08 16:47:57 +02:00
Richard van der Hoff
712fe5b217 Implement a hook allowing enterprise modules to perform actions on startup
Add an interface `io.element.android.features.enterprise.api.AppStartupHook`,
which can be implemented in the enterprise build to perform certain actions on
startup.

It's a bit of a kludge for now since it doesn't block the rest of the app from
proceeding, but it will serve our purposes for now.
2026-08-27 22:36:47 +01:00
Jorge Martín
c56bb66307 Fix ClientBuilderEnterpriseHook not returning an updated ClientBuilder 2026-08-21 17:32:45 +02:00
Jorge Martín
4b32816b32 Add ClientEnterpriseHook and ClientBuilderEnterpriseHook
These allow us to not expose the enterprise internal when setting up custom configs for both `ClientBuilder` and `Client`
2026-08-21 10:05:00 +02:00
Jorge Martin Espinosa
a1e86ad499 Use the right base URL for the ESS config/well known endpoints (#7469)
* Rename `UrlContentFetcher` to `ClientUrlContentFetcher` and add missing base URL data (server name, homeserver URL)

* Avoid passing the `homeserverUrl/serverName` around.

Calculate the URL in `DefaultRemoteEnterpriseConfigRetriever` using the newly added `homserver` and `server` values as the possible base URLs, depending on the remote config source

* Make sure we don't perform blocking requests to fetch the remote config when restoring a session

Add a `needsRefresh` parameter to `RemoteEnterpriseConfigResult.NotFound` to handle this, and store a `no-config` value in the store to indicate an endpoint has been checked and no config was found

* Bump enterprise module
2026-08-19 09:24:22 +02:00
Jorge Martin Espinosa
8b2c207728 Move the :libraries:wellknown logic into enterprise modules (#7429)
* Extract `IsEnterpriseBuild` use case

Having it inside `EnterpriseService` made having DI cycles with the `BuildMeta` provider too easy

* Rename `EnterpriseService.defaultHomeserverList()` to `homeserverAllowList()`

This seems more aligned with the way this list works

* Move most of the logic from `:libraries:wellknown` to `:enterprise:feature:enterprise`, both `shared` and `impl` modules

Ideally I would have added everything into `impl`, but some of the classes needed to be shared between the different `:enterprise:features` modules, and those are in the `shared` module, lacking a better name/strategy

* Add `EnterpriseService.isElementProEnforced`

With this, we don't need to provide the `RemoteEnterpriseConfig` anymore to any consumers, everything goes through `EnterpriseService` or other providers

* Remove `EnterpriseService.overriddenElementWellKnown`

This leaks the remote enterprise config/element well known contents to the app in a public interface.

* Create `CustomMapTilerConfigProvider` to avoid leaking the `RemoteEnterpriseConfig` in public APIs

This commit also starts moving some of the well-known related values to the enterprise modules

* Add missing docs to `EnterpriseService` and `SessionEnterpriseService`

* Fix tests

* Fix lint issues

* Bump enterprise module
2026-08-17 13:21:47 +00:00
Benoit Marty
7f3d896a3e Add KDoc to the features/enterprise API interfaces
Document EnterpriseService, SessionEnterpriseService and
RemoteEnterpriseConfigProvider along with all their members and parameters.

Two points that callers get wrong are stated explicitly: these services return
permissive defaults on a standard build, so there is no need to branch on the
build type, and SessionEnterpriseService only answers meaningfully once init has
run. The many nullable getters now say what null means in each case, which is
generally "no override, use the app default".

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-14 10:01:14 +02:00
Jorge Martín
e371b46c68 Rename GetUrlResolver to UrlContentFetcher and TemporaryMatrixClientFactory.createTemporaryMatrixClient to just create 2026-08-11 13:18:49 +02:00
Jorge Martín
90d4fbe0bd Apply the GetUrlResolver pattern using unauthenticated matrix clients where possible 2026-08-11 13:18:49 +02:00
Jorge Martín
fd3c671301 Create RemoteEnterpriseConfigProvider wrapper
For Pro, this will check different remote config sources and return the result. For FOSS, this will always return a `NotFound` result
2026-08-11 13:18:49 +02:00
Jorge Martín
59758a20a5 Add RemoteEnterpriseConfig typealias for ElementWellKnown
In the future, we want to move the enterprise config to the private Element Pro repo, this is a first step
2026-08-11 13:18:49 +02:00
Jorge Martin Espinosa
925376b6af Allow adding extra elements to the developer settings from external modules (#7230)
* Add `ExtraDeveloperOptionsRenderer` to display extra UI components in the developer settings screen. It defaults to not displaying anything, using `NoopExtraDeveloperOptionsRenderer`

* Add `EnterpriseService.overriddenElementWellKnown` method to fetch the current overridden element well known value, if any

* Modify the well known retrievers to use the overridden value if it's there. Also extract the JSON parsing to its own `ElementWellKnownParser` component.

* Bump enterprise repo reference.
2026-07-21 10:18:56 +02:00
Jorge Martin Espinosa
62cc7e0505 Allow homeserver to disable encryption in Element Pro (#7198)
* Allow HS to disable encryption in Element Pro

Add `force_disable_e2ee` support in the Element well known retriever and cache to allow a homeserver to disable encrypted room creation and enabling encryption in an existing room in Element Pro clients

* Bump enterprise repo back to `main` branch
2026-07-15 13:29:16 +02:00
Benoit Marty
a76b55e580 Add a way to tweak MAS url. 2026-04-29 22:29:40 +02:00
Benoit Marty
df4c719151 Let enterprise build be able to use a different notification channel for noisy notification. 2026-02-11 11:57:01 +01:00
Benoit Marty
eb31505dc7 Copyright: Add Element Creations Ltd. copyright 2025-11-10 11:05:05 +01:00
Benoit Marty
f86431e663 Copyright: Add final period 2025-11-10 10:13:41 +01:00
Benoit Marty
c4e0370f41 Copyright: run command uv run license-editor --repository ../element-x-android 2025-11-10 10:09:26 +01:00
Benoit Marty
6e9af83b6a Let notifications uses the brandColor. 2025-10-24 17:04:48 +02:00
Benoit Marty
07b9a8456b Move SemanticColorsLightDark to compound module 2025-10-22 09:35:55 +02:00
Benoit Marty
49c23a922e Improve API and fix theme glitch when switching between accounts. 2025-10-22 09:32:15 +02:00
Benoit Marty
c5da479065 Improve API and documentation 2025-10-21 11:53:36 +02:00
Benoit Marty
38908a42a2 Update API around brandColor. 2025-10-20 16:33:46 +02:00
Benoit Marty
844e1d2ce5 Let the enterprise build be able to update the colors. 2025-10-15 11:25:58 +02:00
Benoit Marty
95f1dc9bae Import Compound code from project https://github.com/element-hq/compound-android 2025-10-03 18:23:27 +02:00
Benoit Marty
d9b274b6cf Let enterprise build be able to override (or disable) the bug report URL. 2025-08-08 17:23:39 +02:00
Benoit Marty
25ba79a681 Move isElementCallAvailable fun to new SessionEnterpriseService, which implementations can get the current MatrixClient. 2025-06-24 11:28:25 +02:00
Benoit Marty
5b9da3c41b Hide Element Call entry point if Element Call service is not available. (#4783)
* Hide Element Call entry point if Element Call service is not available.

* No need to preview the case RoomCallState.Unavailable

* Hide start call action from user profile if Element Call is not available.

* Add mising `use` and cover the problem by a test.

* Update screenshots

* Update enterprise submodule ref.

* Ensure `enterpriseService.isElementCallAvailable()` is not called several times.
And fix unit tests on CI

---------

Co-authored-by: ElementBot <android@element.io>
2025-05-27 16:31:05 +02:00
Benoit Marty
b926f5f5dc On boarding flow: add a screen to select account provider among a fixed list (#4769)
* Hide login with QrCode when the app is opened by a link

* Fix UI on ChangeAccountProviderView.

* Add flow to choose between a fixed list of account provider

* Update screenshots

* Fix licence header

* Rename preview.

* Ensure that the default account provider cannot be "*"
This should not happen IRL, but better be robust against issue in application configuration.

* Create const of any account provider value

* Fix typo

---------

Co-authored-by: ElementBot <android@element.io>
2025-05-23 18:36:48 +02:00
Benoit Marty
3cf8237d29 Allow configuration to provide multiple account providers. (#4742)
* Allow several account provider in configuration

* Target latest private modules.

* Fix tests

* Target latest private modules.

* Trigger CI

* Fix formatting issue
2025-05-20 08:57:01 +02:00
Benoit Marty
8ca5f8bc9d Let EnterpriseService prevent usage of homeserver (#4682)
* Add check on homeserver url.

* Update screenshots

* Add missing test

* Update submodule link.

---------

Co-authored-by: ElementBot <android@element.io>
2025-05-06 17:25:07 +00:00
Benoit Marty
5cab146eed Give ability to configure the UnifiedPush default push gateway. 2025-03-12 17:10:33 +01:00
Benoit Marty
cf60f943a8 Give ability to configure the Firebase push gateway. 2025-03-12 16:50:46 +01:00
Benoit Marty
0a5784992f Add a way to override default homeserver. 2025-02-20 18:05:49 +01:00
Benoit Marty
b7dc2e3551 No need to expose libs.compound here. 2025-02-06 15:10:15 +01:00
Benoit Marty
1654f569a0 Add ability to EnterpriseService to override theme colors 2025-02-06 15:10:14 +01:00
Benoit Marty
97f3be3dc5 Apply dual licenses: AGPL + Element Commercial to file headers.
2 replace all actions have been performed:
- "SPDX-License-Identifier: AGPL-3.0-only" to "SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-Element-Commercial"
- "Please see LICENSE in the repository root for full details." to "Please see LICENSE files in the repository root for full details."
2025-01-07 10:05:04 +01:00
Benoit Marty
f61df38e55 Migrate license to AGPL.
Run script `uv run license-editor --repository ../element-x-android`
2024-09-06 17:19:19 +02:00
Benoit Marty
4c77201a4e Fix quality issue and add tests. 2024-06-26 11:59:44 +02:00
Benoit Marty
1b72221df7 Add first EnterpriseService. 2024-06-26 11:59:41 +02:00