Fix viewport is scrolled in some pages on iOS mWeb#70643
Fix viewport is scrolled in some pages on iOS mWeb#70643bernhardoj wants to merge 8 commits intoExpensify:mainfrom
Conversation
|
@sobitneupane Please copy/paste the Reviewer Checklist from here into a new comment on this PR and complete it. If you have the K2 extension, you can simply click: [this button] |
|
Recording for the other pages: ios.mweb.mp4 |
|
@bernhardoj We currently close the keyboard for all lists except Workspace. Do you know why that is? Could we also close it on the Workspace page? I think we’ve discussed this before. |
|
After the keyboard is opened, some padding is added above it. Screen.Recording.2025-09-23.at.19.19.09.mov |
|
Some part of the last workspace is cut off by the keyboard. Screen.Recording.2025-09-23.at.19.08.41.mov |
|
@sobitneupane Sorry for missing this.
You mean close the keyboard while scrolling? We close on scrolling when using SelectionList. App/src/components/SelectionListWithSections/index.tsx Lines 59 to 65 in 3e4193a But the WS list page uses FlatList. App/src/pages/workspace/WorkspacesListPage.tsx Lines 568 to 580 in 3e4193a Should we add onScroll and dismiss the keyboard too?
I can't reproduce this one, but most likely it's the viewport autoscroll of Safari.
Can't repro this one either. |
|
@sobitneupane bump |
I think it makes sense for consistency. What do you think? I'll try reproducing the other issues and update you soon. |
|
I can still reproduce this issue on mWeb/Safari. @bernhardoj Could you please test it again? Screen.Recording.2025-10-07.at.14.56.16.movI can still reproduce this issue on IOS/native. However, this should no longer be a problem once we implement this fix. Screen.Recording.2025-10-07.at.15.03.06.mov@bernhardoj Both issues are consistently reproducible on my end. These issues are not reproducible in main. |
|
I can reproduce the first issue now. It also happens on main and staging. ios.mweb.mp4The 2nd issue also happens on main. ios.mp4
I'm not 100% sure. I think it's best to replace the FlatList to SelectionList if we want the keyboard dismiss on scroll behavior (but I'm afraid this would cause regressions). Otherwise, we need to create a hook(?) to DRY up the logic and create a separate native and non native files. |
|
In this issue, I am talking about the highlighted area (spacing above the keyboard). I can not reproduce it on main.
|
In that case, let's focus on the issue described in the OP. |
I was also able to reproduce the issue on main. 👍 |
|
Bump @bernhardoj |
Ah, I see. That happens because of the
|
|
@sobitneupane bump |
|
Sorry for the delay @bernhardoj It’s been a busy week, but I’ll do my best to get it done by the weekend. |
|
@bernhardoj I could not reproduce this issue on staging.
|
|
Just rechecked and yeah it doesn't happen on that currency page. This only happens when we focus on the text input and the viewport is automatically scrolled. This is just to show that it could happens to any page with shouldEnableMaxHeight and the input is positioned in a position that when focused, will trigger the viewport scroll. ios.a.mp4 |
|
Thanks for the update, @bernhardoj. Why do we auto-scroll the viewport on Workspace feature pages? Merging the PR as it is will introduce a regression in these pages. I believe we should address the issue here before proceeding. |
That's the iOS Safari behavior. I don't have a fix for that. If we want to fix it, then it's better to have a new issue for that. Here is another example where this issue happens. ios.mweb.mp4We actually have a workaround here to scroll the viewport back to 0, but not sure why it doesn't work reliably. Log doesn't show in my Safari Inspector, so I can't investigate it. App/src/hooks/useTackInputFocus/index.ts Lines 37 to 48 in 0171f0a |
Codecov Report✅ Changes either increased or maintained existing code coverage, great job!
|
|
@bernhardoj Are you able to consistently reproduce the issue you mentioned #70643 (comment) ? I was only able to reproduce it once, and that was only when the user was offline. I’d like to get this resolved before merging the PR. If you have reliable reproduction steps, we can create a dedicated issue and address it before moving forward with the merge. |
|
Yes, online or offline. |
|
@bernhardoj If you’re able to reproduce the issue consistently, could you please report the bug and share the link here? I haven’t been able to reproduce it reliably on my end. |
|
@sobitneupane Here is the issue: #74559 |
|
I'm keeping a close eye on that issue. There aren't any proposals yet. I think we can merge this PR once we confirm that the solution in #74559 actually fixes the problem here. |
|
Same as above — no progress yet on the linked issue. |
PR on HOLDSame as above — no progress yet on the linked issue. |
|
@sobitneupane the other PR is merged. This issue is now fixed. |
JmillsExpensify
left a comment
There was a problem hiding this comment.
No product concerns from me.







Explanation of Change
Fixed Issues
$ #67351
PROPOSAL: #67351 (comment)
Tests
Prerequisite: have more than 15 workspaces
Only for mWeb/iOS/Android
Offline tests
QA Steps
// TODO: These must be filled out, or the issue title must include "[No QA]."
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectioncanBeMissingparam foruseOnyxtoggleReportand notonIconClick)src/languages/*files and using the translation methodSTYLE.md) were followedAvatar, I verified the components usingAvatarare working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))npm run compress-svg)Avataris modified, I verified thatAvataris working as expected in all cases)Designlabel and/or tagged@Expensify/designso the design team can review the changes.ScrollViewcomponent to make it scrollable when more elements are added to the page.mainbranch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTeststeps.Screenshots/Videos
Android: Native
Android: mWeb Chrome
android.mweb.mp4
iOS: Native
ios.mp4
iOS: mWeb Safari
ios.mweb.mp4
MacOS: Chrome / Safari
MacOS: Desktop