Skip to content

fix: unstick the blur and touches after taking a profile photo on iOS - #341

Merged
PierreVieira merged 3 commits into
mainfrom
fix/camera-crop-blur-stuck
Aug 11, 2026
Merged

fix: unstick the blur and touches after taking a profile photo on iOS#341
PierreVieira merged 3 commits into
mainfrom
fix/camera-crop-blur-stuck

Conversation

@PierreVieira

Copy link
Copy Markdown
Member

Fixes three problems in the profile photo camera flow on iOS, all rooted in how Compose Multiplatform 1.11 hosts dialogs in their own window above modal view controllers:

  • Crop screen stayed blurred. The backdrop blur set by the expanded photo overlay is global state that was cleared only by onDispose inside the dialog's composition. On real devices (never reproducible in the simulator), pushing the crop route right after the camera dismissal leaks that dialog composition, so the blur stayed on over the crop screen. WindowContentBlurEffect now also observes the nav entry's Lifecycle, which is driven from the main composition: ON_STOP/ON_DESTROY force the radius back to zero and ON_START restores it, so the blur follows the back stack even if the dialog composition is never disposed. This also makes the blur behave correctly across backgrounding.

  • Taps stopped working after closing the photo dialogs. FileKit presents the camera from the top-most view controller, which on CMP 1.11 sits below the Compose dialog window — the exact scenario that corrupted touch handling app-wide after dismissal and that the pre-0.15 hand-rolled picker (feature: edit profile name and photo #281) worked around. The picker now reuses that proven presentation recipe through FileKit's own hook: FileKitOpenCameraSettings(presenter) points at the root view controller of a dedicated transparent UIWindow made key above alerts, attached at launch and detached (restoring the previous key window) when the result or an error arrives. FileKit still owns all the picker mechanics, including the deliver-after-dismissal fix from 🐛 [iOS] Deliver camera result after dismissal and encode JPEG off the main thread vinceglb/FileKit#619.

  • No feedback while the camera opens. The old workaround's spinner was lost in chore: bump FileKit to 0.15.0 and drop the iOS camera workaround #340. A scrim with a spinner now shows from the camera tap until FileKit delivers a result, composed after the overlay/sheet content so it draws on top, and the pickers use the onError overload so a picker failure can't leave it stuck.

Verified on a physical iPhone: crop opens sharp after taking a photo, taps keep working after closing the dialogs, the spinner shows while the camera opens, and the gallery path is unaffected. Release notes updated in the 2.5.0 slot for the three languages.

🤖 Generated with Claude Code

PierreVieira and others added 3 commits August 11, 2026 16:13
The backdrop blur set by ExpandedPhotoOverlay is global state cleared
only by the DisposableEffect's onDispose inside the dialog's
composition. On iOS devices, pushing the crop route right after the
camera dismissal leaks that dialog composition, so the blur stayed on
over the crop screen. WindowContentBlurEffect now also observes the nav
entry's Lifecycle, which is driven from the main composition: ON_STOP /
ON_DESTROY force the radius back to zero (and ON_START restores it),
so the blur follows the back stack even if the dialog composition is
never disposed.

Also restores the launch feedback lost with the old hand-rolled camera
picker: a scrim with a spinner shows from the camera tap until FileKit
delivers a result, and the pickers now use the onError overload so a
picker failure can't leave the overlay stuck.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
FileKit 0.15 presents the camera from the top-most view controller,
which on CMP 1.11 sits below the Compose dialog window; after the
picker dismissal, touch handling on the underlying screen was corrupted
app-wide — the problem the pre-0.15 hand-rolled picker avoided. The iOS
picker now reuses that proven presentation recipe through FileKit's own
hook: FileKitOpenCameraSettings(presenter) points at the root view
controller of a dedicated transparent UIWindow made key above alerts,
attached at launch and detached (restoring the previous key window)
when the result or an error arrives. FileKit still owns all the picker
mechanics.

Also composes ProfilePhotoPickers after the overlay/sheet content so
the camera-launch spinner draws on top of it instead of behind it.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@PierreVieira PierreVieira added the bug Something isn't working label Aug 11, 2026
@PierreVieira PierreVieira self-assigned this Aug 11, 2026
@PierreVieira
PierreVieira merged commit a3a97ef into main Aug 11, 2026
1 check passed
@PierreVieira
PierreVieira deleted the fix/camera-crop-blur-stuck branch August 11, 2026 19:39
@PierreVieira

Copy link
Copy Markdown
Member Author

Lets keep an eye in vinceglb/FileKit#639 it is related to this one

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant