SwiftFormat 0.64.4 flags `else { if … }` blocks with its nestedIf rule,
which fails the lint check in the pre-commit hook and on CI. Flatten the
five remaining cases into `else if` chains. No behaviour change.
Drop -test-repetition-relaunch-enabled from the run-tests command. With
it, xcodebuild re-runs the whole test selection after any failure, even
though Swift Testing (6.4+) already retries just the failing test case
in-process. The tradeoff is that a runner crash is no longer retried.
Set diagnosticCollectionPolicy to Never in the UnitTests and
PreviewTests plans. On any recorded issue xcodebuild otherwise tries to
collect simulator diagnostics, which locally timed out after 600
seconds. IntegrationTests keeps its Always policy.
The ignore and unignore tests waited for isProcessingIgnoreRequest to
transition through [true, false]. The mocked client call returns almost
immediately, so under load the observation can coalesce and only ever
see false, making the test time out after 10 seconds and triggering a
CI retry.
Wait on the durable outcome instead (the recipient's ignored state, or
the alert on failure) and assert only that, dropping the processing
state checks which no longer cover anything.
Load the picked screenshot with .task(id:) instead of an unstructured Task
so that picking a new item or removing the screenshot cancels any load in
progress. Previously a slow load could finish after removal and re-attach
the screenshot, or overwrite a newer pick.
Clear the picker selection once each load finishes, successful or not, so
picking the same item again always triggers a new load.
The PhotosPicker selection binding was never cleared when removing the
screenshot, so the picker kept showing the item as selected and picking
it again didn't change the binding, meaning onChange never fired and the
image couldn't be attached again. Reset the selection on removal.
Fixes#6258
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* Fix custom titles covering the toolbar after a cancelled swipe back
On iOS 26 and 27, cancelling the interactive pop gesture leaves a custom
navigation title view (e.g. the room header) at its full width, so it
covers the trailing toolbar buttons until the screen is left. UIKit
restores the title's container but never lays the title out inside it
again.
Work around it by observing both pop gestures and laying out the title
view's container again when the pop is cancelled. It's only applied on
iOS 26+ and marked with a TODO to remove once Apple fixes the bug.
* Make singletons a last resort in AGENTS.md
Add a Dependency Injection rule: use a shared singleton only as a last
resort.
* Apply the cancelled swipe back title fix only to room header screens
Review feedback: hooking every navigation stack does more introspection
than needed. The bug only shows up when RoomHeaderView is the title, so
move the workaround next to it and apply it to the 4 screens that use
it: room, thread, space and join room (knocked).
Checked on the simulator: with the fix removed, a cancelled swipe back
leaves the title too wide on the room, thread and join room screens;
with the fix applied, the room, thread, join room and space titles stay
truncated.
Re-record the SpaceScreen preview snapshots. Wrapping that screen in
any if/else changes how the snapshot test renders it, even when the
workaround itself doesn't run. The app isn't affected.
* Move mapTilerConfiguration into `AccountSettings`.
* Re-order notification tone setting into the Configuration section.
* Update the Enterprise submodule.
The notification extension increments the app badge for every
notification it delivers, without the app knowing about it. The app
used to correct this drift by setting the badge from the room list on
every update, but since #6337 the NotificationService only publishes
the badge count when it changes.
Publish the badge count on every room list update again so the
NotificationManager always resets the app badge.
Brings in a fix for rooms that kept back-paginating in the background
while looking for their latest event, which started with 26.10.20.
The SDK mocks are regenerated for the new optional request config
parameter on the raw send methods.
matrix-rust-sdk: 8de215a0aa0026afa5754ae5f05a6d168d1a1d60
* Fix a crash when opening the camera while it's unavailable.
The app set the image picker's source to the camera without checking it
could be used. iOS throws when it can't: when Screen Time or a device
management profile blocks the camera, or while it's already in use.
Check AppMediator.isCameraAvailable when Camera or Take photo is tapped in
the room and thread composers, profile editing, room editing and room
creation. If it's unavailable, show a toast instead of opening the picker.
Also handle Cancel in the camera picker so the sheet closes through the
coordinator, like the photo library and document pickers.
Sentry: ELEMENT-X-IOS-SP
* Update the Enterprise submodule.
Picks up the create room hook test fix that passes the new appMediator argument.
* Use the Localazy string for the camera unavailable toast.
The copy is now in Localazy as error_camera_unavailable ("The camera is
not available"), so it replaces the untranslated string.
* Order appMediator consistently with CommonFlowParameters.
Move appMediator before analytics and userIndicatorController in the create room, room details edit and user details edit screens, their call sites and tests.
Co-authored-by: Velin92 <34335419+Velin92@users.noreply.github.com>
* Update the Enterprise submodule.
Picks up the create room hook test passing appMediator before analytics, to
match the new init order.
* Update the Enterprise submodule.
Points at Enterprise main now that element-ios-enterprise#42 is merged.
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Replaces the shared CodeHyphenationLayoutManagerDelegate with an
NSLayoutManagerDelegate conformance on MessageTextView, as it's already
the delegate for its gesture recognizers and pills. The layout manager
only holds its delegate weakly and the text view owns the layout manager,
so no shared instance or stored property is needed.
The code block test now uses a <pre> without a nested <code>, so it
actually covers the CodeBlock check rather than passing through the
InlineCode one.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
When a word in inline code (or a code block) is too long for the line,
TextKit breaks it with an inserted hyphen, so commit hashes, UUIDs and
identifiers render with characters that aren't part of the code.
Disabling hyphenation through the paragraph style has no effect on this
fallback, so MessageText now sets an NSLayoutManagerDelegate that refuses
to hyphenate before any character marked as code. Code wraps by character
instead while regular message text keeps its existing behaviour.
The delegate is a shared instance rather than a stored property on
MessageTextView: UITextView(usingTextLayoutManager:) skips the subclass's
stored property initialisers, so such a property would be nil.
Fixes#5725
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Multi-select forwarding is ready to ship, so Forward from the message menu now
always starts a selection in the room, thread, focused and pinned timelines.
Media timelines still forward the single item straight away.
Removes the messageMultiSelectEnabled setting and its developer option, the
selection state's isEnabled gate and the publisher that kept it in sync, the two
unit tests that only covered the flag, and the preview setup that switched it on.
Like Android, a call that comes in while another one rings, or while a web view call runs, no longer rings: it's reported to CallKit as missed so it shows in Recents. An ongoing native call is left alone, since CallKit tracks it and offers its own call waiting. A second push for the ring that's already ringing is reported as handled, without a missed entry.
An answered call that never opens (e.g. its room isn't joined) is dropped when its call session is torn down, so it can't block later calls. The unanswered timeout is now cancelled as soon as a call is answered, rather than a second later, when it may already belong to a call that rang since.
CompoundIcon already scales its size with Dynamic Type, but the chevron
was given a size that was itself a @ScaledMetric, so it scaled twice:
the button reached about 202pt at the largest accessibility size, more
than twice the composer's mic button.
Pass the base icon size and scale the icon, its padding and the badge
once, relative to headingLG like the composer buttons. The button now
keeps its proportions at every size (72pt at the largest, mic 88pt)
and is unchanged at the default size.
Only the first image was checked for GPS before stripping, so a file
whose later images carried a location, but not its first, was sent
unchanged with that location. Every image is checked now.
GPS stored only in XMP was already caught, because ImageIO reports it
in the image's GPS properties.
Spatial photos pair their images in a stereo group. ImageIO only writes
that group from the properties each image is added with, so re-encoding
a photo to remove its location dropped the pairing, and the photo was
sent as a flat one with hidden extra images.
Each image is now added with its stereo group again, read from the
source's container properties, so the left, right and monoscopic images
keep their roles along with the group's disparity adjustment. ImageIO
ignores the group's image index keys and anything it can't write, so the
group is passed on as it is.
Brings in event cache fixes: no automatic back-pagination for spaces
and non-joined rooms, and rooms shrink again after background
back-pagination.
matrix-rust-sdk: 56bc59112822e7eb25943a95e02502855cdeef2d
Create account sent prompt=consent, the same as Sign in, so MAS opened its
sign-in page and new users were asked for a password they didn't have.
The create prompt was turned off because MAS used to sign you straight into
an existing browser session (element-hq/matrix-authentication-service#3429).
MAS v0.15.0 fixed that by always showing its consent page, so send
prompt=create again for registration, but only when the server advertises it.
The eye button shows what tapping it will do, so a hidden key shows the
open eye. This restores Compound's original icon order.
Re-record the recovery key screen and the encryption settings out-of-sync
UI test snapshots for the new field.
The recovery key field now uses Compound's secure text field style, which
adds the show/hide button Android already has. Autocapitalisation and
autocorrection are off so a revealed key isn't altered while typing.
Compound's eye icon now shows a crossed eye while the text is hidden and an
open eye while it's shown, matching Android and Compound web.
Expiry was only checked when a location update arrived. A phone that
doesn't move gets none, so an expired share kept GPS, the location
indicator and the room banner on.
Each account's service now schedules one task for the next share to
expire, rescheduled whenever its shares change and re-armed if the wall
clock lags behind the sleep. Shares that expired while the app wasn't
running are dropped when the service starts. Time comes from an
injected TimeProvider so the tests drive it with ManualClock.
Closes#6367
Core Location reports CLError.locationUnknown when it can't get a fix
straight away and keeps trying, but didFailWithError stopped every
account's shares on any error. Ignore that one error and keep stopping
on real failures such as .denied.
Closes#6366
* Remove the homeserver parameter from user hooks.
* Split the OAuthPresenter hook into two.
With one living directly on the UserHooks.
* Add developerOptionsScreenHook to the UserHooks.
* Remove appHooks from the flowParameters.
Element X Android doesn't start SAS after accepting a request, so iOS
requests to it never progressed. Either side may start per the spec and the
SDK resolves the conflict if both do.
Requires the SDK change making `didAcceptVerificationRequest` fire only on
the requesting side.
* Store live location shares per account
The active shares were stored for the whole app, so with several accounts signed in every account's manager ran location updates and tried to send to every shared room, and could stop another account's share. They now live in the account settings and are migrated to the first account restored.
* Share one location manager between accounts
Each user session now has a LiveLocationService with its own shares, while a single app-level LiveLocationManager owns the CLLocationManager, runs location updates while any account shares, hands each location to the sharing accounts and mirrors the authorization status into every service. Signing out stops the account's shares before logging out, so other people don't keep seeing a frozen live location.
* Publish the live location shares migrated into an account
Sessions are built before the migrations run, so the account's live location service had already read an empty list of shares and the raw migration didn't tell it about the moved ones. An upgrade during a share left it showing as sharing without sending anything until the next launch. The migration now sets the value again once moved, which publishes it.
* Don't migrate the live location shares
Sessions are built before the migrations run, so a migrated share wouldn't resume until the next launch without re-publishing the value. That isn't worth the extra code for a rare case: a share running during the update just stops sending until it expires.
* Apply review suggestions to live location sharing
- Keep the live location shares with the other session activity settings instead of in their own section.
- The LiveLocationManager now remembers that Always authorization was requested; the services only check the flag before asking.
- Rename the manager's helpers to isSharingChanged(_:for:), syncLocationUpdates() and process(_:).
- Clarify the doc comments on the service's action and authorization status.
* Rename the notification manager's action handler to process
Matches the LiveLocationManager and what view models call it.
The biometric state hash now comes from LAContext.domainState, which
unlike the deprecated evaluatedPolicyDomainState doesn't need
canEvaluatePolicy to be called before it can be read. Drop
updateBiometrics() and make LAContextMock return its values directly
instead of waiting for a policy evaluation.