You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Due for payment 2026-05-07] iOS - Distance - Receipt view remains zoomed after landscape to portrait rotation #87356
Version Number: v9.3.54-0 Reproducible in staging?: Yes Reproducible in production?: N/A - new feature, doesn't exist in prod If this was caught during regression testing, add the test name, ID and link from BrowserStack:#85229 Email or phone of affected tester (no customers):htad26+etreti@gmail.com Issue reported by: Applause Internal Team Bug source: Exploratory - Significant User Experience Deterioration Device used: iOS 26.3/iPhone 13 App Component: Money Requests
Action Performed:
Launch the app
Navigate to a workspace chat
Create a map distance expense
Open the expense details in landscape mode and tap the receipt thumbnail
While the receipt thumbnail view is open, rotate the device to portrait mode
Expected Result:
The receipt view adjusts to portrait orientation and displays the full receipt.
Actual Result:
The receipt remains zoomed in and does not adjust to display the full content in portrait mode.
👋 Friendly reminder that deploy blockers are time-sensitive ⏱ issues! Check out the open `StagingDeployCash` deploy checklist to see the list of PRs included in this release, then work quickly to do one of the following:
Identify the pull request that introduced this issue and revert it.
MultiGestureCanvas (index.tsx:104-122) manages zoom and pan state via Reanimated shared values (zoomScale, offsetX, offsetY, panTranslateX/Y, pinchTranslateX/Y). These values are only reset when isActive becomes false (e.g., swiping to another image in a carousel). When the device rotates, canvasSize updates via onLayout and minContentScale recalculates, but the zoom/translation shared values are never reset. Since totalScale = zoomScale * minContentScale, a stale zoomScale from landscape combined with a new portrait minContentScale produces an incorrect zoom level.
This affects all images viewed through the Lightbox, not just distance receipts — distance map receipts just make the misalignment more obvious due to their aspect ratio.
What changes do you think we should make in order to solve the problem?
Add an effect in MultiGestureCanvas that calls reset(true) (animated) when canvasSize changes, similar to the existing reset on isActive change. This ensures zoom and pan state are reset to fit the new canvas dimensions after rotation.
Additionally, usePanGesture.ts has module-level constants SCREEN_HEIGHT/SNAP_POINT/SNAP_POINT_HIDDEN (line 17-19) that use Dimensions.get('screen').height at import time and never update on rotation. These should be moved inside the hook or use a listener so swipe-to-close thresholds stay correct after rotation.
What alternative solutions did you explore? (Optional)
Adjusting zoomScale proportionally to the canvas size ratio change (preserving relative zoom) — rejected because it adds complexity and users generally expect a clean reset on rotation.
Handling the reset in Lightbox rather than MultiGestureCanvas — rejected because MultiGestureCanvas owns the zoom state and already has the reset function, so it's the natural place for this logic.
Next Steps for Contributor+ team: Reply with @MelvinBot implement this to create a draft PR, @MelvinBot <your feedback> to refine this analysis, or explain why you are rejecting Melvin's proposal.
Activity
melvin-bot commentedon Apr 8, 2026
@mjasikowski recently merged #85229, but they are OOO right now, so I'll auto-assign someone else.
melvin-bot commentedon Apr 8, 2026
Triggered auto assignment to @neil-marcellini (
DeployBlockerCash), see https://stackoverflowteams.com/c/expensify/questions/9980/ for more details.melvin-bot commentedon Apr 8, 2026
💬 A slack conversation has been started in #expensify-open-source
github-actions commentedon Apr 8, 2026
👋 Friendly reminder that deploy blockers are time-sensitive ⏱ issues! Check out the open `StagingDeployCash` deploy checklist to see the list of PRs included in this release, then work quickly to do one of the following:
MelvinBot commentedon Apr 8, 2026
Proposal
What is the root cause of that problem?
MultiGestureCanvas(index.tsx:104-122) manages zoom and pan state via Reanimated shared values (zoomScale,offsetX,offsetY,panTranslateX/Y,pinchTranslateX/Y). These values are only reset whenisActivebecomesfalse(e.g., swiping to another image in a carousel). When the device rotates,canvasSizeupdates viaonLayoutandminContentScalerecalculates, but the zoom/translation shared values are never reset. SincetotalScale = zoomScale * minContentScale, a stalezoomScalefrom landscape combined with a new portraitminContentScaleproduces an incorrect zoom level.This affects all images viewed through the Lightbox, not just distance receipts — distance map receipts just make the misalignment more obvious due to their aspect ratio.
What changes do you think we should make in order to solve the problem?
Add an effect in
MultiGestureCanvasthat callsreset(true)(animated) whencanvasSizechanges, similar to the existing reset onisActivechange. This ensures zoom and pan state are reset to fit the new canvas dimensions after rotation.Additionally,
usePanGesture.tshas module-level constantsSCREEN_HEIGHT/SNAP_POINT/SNAP_POINT_HIDDEN(line 17-19) that useDimensions.get('screen').heightat import time and never update on rotation. These should be moved inside the hook or use a listener so swipe-to-close thresholds stay correct after rotation.What alternative solutions did you explore? (Optional)
zoomScaleproportionally to the canvas size ratio change (preserving relative zoom) — rejected because it adds complexity and users generally expect a clean reset on rotation.Lightboxrather thanMultiGestureCanvas— rejected becauseMultiGestureCanvasowns the zoom state and already has theresetfunction, so it's the natural place for this logic.Next Steps for Contributor+ team: Reply with
@MelvinBot implement thisto create a draft PR,@MelvinBot <your feedback>to refine this analysis, or explain why you are rejecting Melvin's proposal.27 remaining items
melvin-bot commentedon May 7, 2026
Payment Summary
Upwork Job
BugZero Checklist (@mallenexpensify)
mallenexpensify commentedon May 8, 2026
@truph01 regression from here?
melvin-bot commentedon May 11, 2026
@mallenexpensify Uh oh! This issue is overdue by 2 days. Don't forget to update your issues!
melvin-bot commentedon May 18, 2026
@mallenexpensify Eep! 4 days overdue now. Issues have feelings too...
truph01 commentedon May 19, 2026
@mallenexpensify It is related to #77280.
So, we can close this one.