Commit Graph

159 Commits

Author SHA1 Message Date
Doug
28bd7a0d6a Update the SDK. (#4517) 2025-09-17 15:43:38 +01:00
Valere Fedronic
dc1f174d40 Element Call: Send rtc.decline event when incoming call is declined (#4499) 2025-09-16 09:14:04 +01:00
Stefan Ceriu
bae0d02fde Add SwiftSoup to the project 2025-09-09 17:17:40 +01:00
Doug
2b65844ac6 Use the SDK's offline detection everywhere (except for restarting the sync loop). (#4472)
* Use the SDK's offline state to drive the offline indicator.

* Only use network reachability for restarting the sync loop, use the homeserver reachability for requests.

* Add a separate indicator to distinguish when the server is unreachable but the device is online.
2025-09-08 12:18:02 +00:00
Doug
9ff82a478e Add a feature flag for spaces. (#4429)
* Remove the huge conditional compilation block on AppSettings.

It is still required for the ElementCallBaseURL however.

* Add a feature flag for spaces.
2025-08-22 13:47:23 +01:00
Doug
6408432c76 Add a couple of logs to debug badge counts. (#4425) 2025-08-20 10:26:45 +01:00
Doug
974a3ad74f Handle TimelineDiff as an enum with associated values. (#4379)
* Handle TimelineDiff as a true enum.

* Update the SDK.

* Silence some warnings.
2025-08-05 09:23:22 +01:00
Doug
ee9f055822 Add a TracingHook. (#4345) 2025-07-23 14:29:31 +01:00
Doug
b7867dac85 Make the remote settings hook usable within the app extensions. (#4342) 2025-07-22 17:09:53 +01:00
Doug
f65b191c8a Refactor Rageshake URL and Target configuration. (#4337)
* Move the rageshakeURL configuration from the BugReportService to AppSettings.

* Refactor Target to return a handle when configuring.

This helps with reconfiguration and removes the @MainActor constraint.
2025-07-22 10:19:26 +01:00
Mauro
84e095f726 Automatic Accessibility Audits on previews part 1 (#4322)
* setup target

* accessibility tests implementation

* removed ipad check

* pr improvements

* updated project
2025-07-15 14:40:16 +02:00
Stefan Ceriu
4d616c550c Add support for the new client wide threads feature flag
- enable it everywhere as it's safer than dealing with different configurations
2025-07-04 16:04:46 +03:00
Stefan Ceriu
d2933df2d0 Bump the RustSDK to v25.07.04 2025-07-04 16:04:46 +03:00
Richard van der Hoff
24ce5c03de Add a developer option for history sharing on invite
Adds a new developer flag, enabling our experimental support for MSC4268.
2025-06-11 11:24:29 +03:00
Stefan Ceriu
2993f9b6a2 Fix breaking changes following SDK update. 2025-06-10 15:09:20 +03:00
Stefan Ceriu
a6c3b5d4af Allow multiple room info updates when receiving a call before deciding the room doesn't have an active call anymore. 2025-06-05 11:06:07 +03:00
Mauro
c1dfce4935 Handle media previews and invite avatars through the account data (#4142)
* added account data media display policy handling to NSE

* pr suggestions

* update compound

* code improvement
2025-05-28 19:51:34 +02:00
Stefan Ceriu
3dd98adeeb Setup the new RustSDK sentry integration 2025-05-27 18:21:11 +03:00
Doug
91195305aa Add a developer option that hides notification alerts when a sound wouldn't be played.
Enabling this makes isNoisy behave like iMessage's Hide Alerts option.
2025-05-26 16:05:38 +03:00
Stefan Ceriu
2c4a8b34a7 Bump the SDK to 25.05.21 and adopt the new way of dealing with timelines and delegates.
The room list items no longer hold any timeline instances and they can now be created through the normal `room.timelineWithConfiguration` mechanism.
This also means that we can move the UTD hook away from the sync service and into the client itself but setting it is now fallible as it can only be set once.
2025-05-22 18:14:55 +03:00
Stefan Ceriu
4c7791ab24 Fix various small errors when running in the Swift 6 language mode (#4109)
* Fix various small errors when running in the Swift 6 language mode

* Make the `TargetConfiguration` run on the main actor.

* Fixed a comment

* Add a comment as to why we can't make the whole NSE a main actor.

* Fix the unit tests

* Fix `blankLinesAtStartOfScope` swiftformat error.
2025-05-13 11:43:47 +03:00
Stefan Ceriu
08e265220d Always set the push notification badge, even if the unread count is missing. 2025-05-02 11:41:46 +03:00
Stefan Ceriu
ce1c26c3d4 Fix compilation errors - make sure we update the push notification badge using the received, server-provided unread count. 2025-05-02 11:27:49 +03:00
Stefan Ceriu
ef7aa3b9b3 Make sure we update the push notification badge using the received, server-provided unread count. 2025-05-02 11:18:10 +03:00
Stefan Ceriu
b4ee531a13 Flatten out the NSE file structure and switch room fetching to the notificationClient instead of the base one
- the notification client uses its internal in-memory store backed client which has up to date data after running the sliding sync loop
- see https://github.com/matrix-org/matrix-rust-sdk/pull/4991 for more details
2025-04-30 12:33:20 +02:00
Stefan Ceriu
16f16b488f Replace the old RoomInfoUpdateListener with the SDKListener 2025-04-29 19:45:55 +03:00
Stefan Ceriu
8d1fab245b Set a total request max retry time for network requests originating in the notification service extension. 2025-04-29 19:45:55 +03:00
Stefan Ceriu
f24e81ae9f Rely on the room's info to decide whether a call ringing notification is outdated and should be ignored as opposed to a time based approach. 2025-04-29 19:45:55 +03:00
Stefan Ceriu
e5eed4709d Reduce the timeout for network requests originating in the notification service extension 2025-04-29 19:45:55 +03:00
Stefan Ceriu
cd983a9d45 Introduce a NotificationHandler object to split out notification content handling from the rest of the NSE core logic. 2025-04-17 15:24:12 +03:00
Stefan Ceriu
b9092bc3a6 Remove unused NSE Task extension 2025-04-17 15:24:12 +03:00
Stefan Ceriu
77bb613e62 Switch from an always returning the notification content approach at every step to passing it in as mutable. 2025-04-17 15:24:12 +03:00
Stefan Ceriu
4bff7df821 Extract NSE specific code out of the UNNotificationContent extension 2025-04-17 15:24:12 +03:00
Stefan Ceriu
558a77525b Refactor the NSE so that the original notification content is preserved between all the different processing steps
- building brand new content is probably interfering with how iOS syncs up delivered and seen notifications between devices
- simplify all the various steps and make the flows easier to follow
2025-04-17 15:24:12 +03:00
Doug
4ed3f44a51 Fix a bug where your own emotes showed as '* You emoted'. (#4038) 2025-04-17 12:39:41 +01:00
Mauro Romito
6c07af84cc sdk: update to 25.04.14 2025-04-14 14:15:42 +02:00
Mauro Romito
eb98606201 change: hiding timeline media has three options 2025-04-09 18:55:34 +02:00
Stefan Ceriu
0ba083f513 Set the NSE client as memory constrained. This, following the roomLoadSettings tweaks, changes SQLite store settings and further decreases memory consumption. 2025-04-08 12:23:37 +03:00
Stefan Ceriu
0c8b3470e1 Refactor the NSE to create a new UserSession every time a payload comes in and pass the room down to the SDK so it can optimize how many rooms it loads from the store and how much memory it's using.
- this will undo creating at most one user session pe process as that shoulnd't be a problem anymore
- it also renames some methods and improves the logging
2025-04-03 18:08:34 +03:00
Stefan Ceriu
346e4adde3 Remove the event cache feature flag, it's enabled by default on the SDK and we haven't had any bug reports for it. 2025-04-03 18:08:34 +03:00
Stefan Ceriu
881017f97a Bump the RustSDK to v25.04.02 2025-04-03 18:08:34 +03:00
Doug
0badcd1303 Add developer options for Rust's Trace Log Packs. (#3929)
* Add support for configuring log packs.

* Update call widget parameters.

* Update the SDK.
2025-03-21 19:00:13 +00:00
Mauro Romito
208e7de3ee hide invite avatars when such flag is on
This affects:
- Invited room preview inviter avatar
- Invited room preview room avatar
- Invited room cell inviter avatar in the room list
- Invited room cell room avatar in the room list
- Push notification for an invite
2025-03-21 15:41:39 +01:00
Mauro Romito
4843bf0f01 phishing alert implementation
we now check when building the string through the `AttributedStringBuilder` if a URL is actually hiding a different link, if so, we create a custom URL that contains both the external and the internal URL to advise the user through an Alert about the risk
2025-03-17 16:21:09 +01:00
Mauro Romito
0c7707a57c removed images in pills in favour of text decos
FIX

fix
2025-03-17 14:45:23 +01:00
Stefan Ceriu
1ae6fc67c4 SDK update (#3891)
* Bump the RustSDK to v25.03.11

* Replace oidc login prompt with nil following the changes from https://github.com/matrix-org/matrix-rust-sdk/pull/4761

```
/// * `prompt` - The desired user experience in the web UI. No value means
///   that the user wishes to login into an existing account, and a value of
///   `Create` means that the user wishes to register a new account.
```

* Fix trailing closure warnings

* Update the client proxy after making `getNotificationSettings()` and  `cachedAvatarUrl()` async (they used to be blocking on the rust side).

* Move `Room.isEncrypted` to the info publisher and manually update the encryption state when creating the room.

* Bump the SDK again to v25.03.12 - This introduces a new way to configure the tokio runtime that we can use to have extensions use less memory
- introduce a new Target struct that takes care of setting up rust services (tracing and tokio) for our various targets
- cleanup MXLog and friends

* Address PR comments

* Bump the SDK again, switch back to using `.consent` as the OIDC login prompt (which was reintroduced in matrix-org/matrix-rust-sdk/pull/4791)
2025-03-13 11:17:37 +02:00
Doug
fa73f1992a Project updates. (#3837)
* Don't use the AppIdentifierPrefix as it breaks when re-signing.

* Generate entitlements using XcodeGen.

* Ignore Xcode Archives.

* Remove the (unused) NCE.

* Update submodule.
2025-02-26 18:29:20 +00:00
Doug
97a4f4fcfe Add a couple of extra logs around the state of call ringing notifications. (#3808) 2025-02-24 10:07:33 +00:00
Doug
6c51cc4b61 Log whether a notification is expected to make a noise. (#3782)
* Log whether a notification is expected to make a noise.

* Also log the system notification sound setting too.
2025-02-11 09:59:46 +00:00
Stefan Ceriu
6f3b4feade Refactor how notifications are preprocessed and be explicit about which ones are supposed to be displayed or discarded. 2025-02-10 12:28:17 +02:00