fix scroll speed of InvertedFlatList - #12602
Conversation
|
CLA Assistant Lite bot All contributors have signed the CLA ✍️ ✅ |
|
I have read the CLA Document and I hereby sign the CLA |
| ref={el => this.list = el} | ||
| shouldMeasureItems | ||
| contentContainerStyle={StyleSheet.compose(this.props.contentContainerStyle, styles.justifyContentEnd)} | ||
| style={{transform: [{translateX: 0}, {translateY: 0}, {scaleY: -1}]}} |
There was a problem hiding this comment.
@dbond09 Can you show some clarity on why we don't need this also?
There was a problem hiding this comment.
When the inverted attribute is set on a FlatList, it is also passed to the underlying VirtualizedList, which already defines the scaleY transform that we need here.
mountiny
left a comment
There was a problem hiding this comment.
Tested on web and seems alright to me, time and other situations will show if the speed is exactly as we want. Great job!
@dbond09 can you please add some content to the Details section of the PR body and also update the test/QA steps to mention: the scroll speed is similar to other apps and browser pages so that it does not feel out of place
Thank you!
Reviewer Checklist
Screenshots/VideosWebWeb_scroll.movDesktopScreen.Recording.2022-11-14.at.11.36.04.PM.movAndroid & iOS NativeNative_Scroll.movAndroid & iOS mWebUploading mWeb_Scroll.mov… |
Santhosh-Sellavel
left a comment
There was a problem hiding this comment.
Checklist & Recordings : #12602 (comment)
LGTM tests well!
All you @mountiny
|
@mountiny looks like this was merged without the checklist test passing. Please add a note explaining why this was done and remove the |
|
Not an emergency, test were passing. |
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
|
Stoked for this PR |
|
Same same, my brain melts a little everytime the scroll is weird. |
|
🚀 Deployed to production by @roryabraham in version: 1.2.28-2 🚀
|
Details
The scroll speed on the chat view was inconsistent with the speed observed in other applications and websites, being much faster. This PR fixes the issue, making the scroll speed feel as expected.
Fixed Issues
$ #10654
PROPOSAL: #10654 (comment)
Tests
QA Steps
PR Author Checklist
### Fixed Issuessection aboveTestssectionQA stepssectiontoggleReportand notonIconClick)src/languages/*filesWaiting for Copylabel for a copy review on the original GH to get the correct copy.STYLE.md) were followedAvatar, I verified the components usingAvatarare working as expected)/** comment above it */thisproperly so there are no scoping issues (i.e. foronClick={this.submit}the methodthis.submitshould be bound tothisin the constructor)thisare necessary to be bound (i.e. avoidthis.submit = this.submit.bind(this);ifthis.submitis never passed to a component event handler likeonClick)StyleUtils.getBackgroundAndBorderStyle(themeColors.componentBG)Avataris modified, I verified thatAvataris working as expected in all cases)PR Reviewer Checklist
The reviewer will copy/paste it into a new comment and complete it after the author checklist is completed
### Fixed Issuessection aboveTestssectionQA stepssectiontoggleReportand notonIconClick).src/languages/*filesWaiting for Copylabel for a copy review on the original GH to get the correct copy.STYLE.md) were followedAvatar, I verified the components usingAvatarhave been tested & I retested again)/** comment above it */thisproperly so there are no scoping issues (i.e. foronClick={this.submit}the methodthis.submitshould be bound tothisin the constructor)thisare necessary to be bound (i.e. avoidthis.submit = this.submit.bind(this);ifthis.submitis never passed to a component event handler likeonClick)StyleUtils.getBackgroundAndBorderStyle(themeColors.componentBG)Avataris modified, I verified thatAvataris working as expected in all cases)Screenshots
Web
Screen.Recording.2022-11-09.at.16.58.08.mov
Mobile Web - Chrome
chrome.webm
Mobile Web - Safari
Simulator.Screen.Recording.-.iPhone.13.-.2022-11-09.at.17.07.22.mp4
Desktop
Screen.Recording.2022-11-09.at.17.19.40.mov
iOS
Simulator.Screen.Recording.-.iPhone.13.-.2022-11-09.at.17.06.05.mp4
Android
android.webm