feat: Reduce amount of items displayed per page of SelectionList#65636
Conversation
|
@jayeshmangwani 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] |
|
When recording test evidence I've noticed an issue that became more apparent after decreasing the amount of initially rendered items to 50. Whenever a user was selecting an item past the initial threshold currently displayed page was getting reset. This is also currently a problem on main that was happening regardless of the set amount of items to render. I've updated a PR with a fix for that as well. Changing the CONST to 50 made this issue popup more frequently now so I've decided to fix it here. Hope it's not a problem 😅 |
|
@MrMuzyk @mountiny , just confirming - after this PR, we're now displaying 50 tags, whereas on staging currently shows 500 on the first render(initially). Can we confirm that this is the expected behavior going forward? Then we should explicitly specify this in the QA steps; otherwise, it might cause a deploy blocker - since, according to the issue #31218, showing 500 tags on the initial render is the expected behavior. |
|
@jayeshmangwani Sure, I can mention this list. But since we're updating all of the lists in the app it's hard for me to mention every single one. Searching the project for usage of SelectionList gives me +100 results |
|
Okay cool, let’s not do it for every list - if anything comes up related to the number of items to display, we’ll clarify then. |
Reviewer Checklist
Screenshots/VideosAndroid: HybridAppAndroid.movAndroid: mWeb Chromemweb-chrome.moviOS: HybridAppiOS.moviOS: mWeb Safarimweb-safari.movMacOS: Chrome / Safariweb.movMacOS: Desktopdesktop.mov |
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
|
This change caused a regression when rendering lists with more than 50 items e.g. country list Screen.Recording.2025-07-10.at.2.30.26.AM.mov |
|
I reproduced the crash as well, looks like a deploy blocker if it'll do the same thing on staging / production. Better get it fixed before it hits staging 💯 |
|
Thanks for reporting this, @ikevin127. |
|
Because there are possibly more places where this happened the best way would probably be to revert that and I will investigate and fix these issues today |
|
Thanks |
|
Thanks, @s77rt, for reporting this - we’ve reverted this PR. |
|
🚀 Deployed to staging by https://github.com/mountiny in version: 9.1.79-0 🚀
|
|
🚀 Deployed to production by https://github.com/Julesssss in version: 9.1.79-11 🚀
|


Explanation of Change
Changed CONST that was used in BaseSelectionList to indicate how many items we should initially render. Decreased it to 50 to make it more in-line with usual amount of items displayed per page of paginated content.
I've also fixed a case where user loaded more items on the list and selected one of the items that wasn't initially loaded. Previously it was resetting the set page.
Fixed Issues
$ #65634
PROPOSAL:
Tests
Same as QA steps
Offline tests
QA Steps
Note:
All of the selection lists in the project will now initially load 50 items instead of 500. Most notable cases are long list that are in the app, ie: selecting users in filters or Tags list. Verifying that one of the lists works correctly should give us confidence that the remaining lists work without any issues as well.
Precondition: Be on account that has many reports from 100+ different users
FromfilterShow morebutton allowing him to load more itemsShow morebuttonPR 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))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.native.mov
Android: mWeb Chrome
android.web.mov
iOS: Native
ios.native.mov
iOS: mWeb Safari
ios.web.mov
MacOS: Chrome / Safari
web.mov
MacOS: Desktop
desktop.mov