Animate the paid checkmark when paying expense#49438
Conversation
|
@ZhenjaHorbach 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] |
Reviewer Checklist
Screenshots/VideosAndroid: Nativeios.movAndroid: mWeb Chromeandroid-web.moviOS: Nativeios.moviOS: mWeb Safariios-web.movMacOS: Chrome / Safariweb.movMacOS: Desktopdesktop.mov |
|
@bernhardoj |
|
Done |
|
I also noticed that we have animation for the header preview on example |
|
Done. It's quite different though because looks like on the GIF, there are 2 preview messages, 1 fades out, 1 fades in, while in the component, we reuse 1 text only. a.mp4 |
|
We need to fix eslint one more time 😅 |
|
Everything is good now |
|
The only thing I would do Anyway LGTM ! |
| height.value = withDelay( | ||
| totalDelay, | ||
| withTiming(0, {duration: CONST.ANIMATION_PAY_BUTTON_DURATION}, () => runOnJS(onAnimationFinish)()), | ||
| withTiming(0, {duration: CONST.ANIMATION_PAID_DURATION}, () => runOnJS(onAnimationFinish)()), |
There was a problem hiding this comment.
Small thing I'm noticing is that we're just using withTiming, but we could use withSpring and/or withBounce to give these animations a more natural feel.
There was a problem hiding this comment.
we talked in slack about using bounce for showing the checkmark
|
The recording in the original post looks pretty good. Would be cool to delay the checkmark animation about 300ms to ensure it catches the attention a bit more. |
|
@roryabraham @dubielzyk-expensify Checkmark Delay 300ms + (Fade replaced with) Bounce (using withSpring) web.mp4Shorter bounce duration (200ms) web.mp4 |
|
Lovely! I am digging the shorter duration version more I think. |
|
Same! I am loving the |
|
Great, pushed the update |
|
Looks nice and works well ! |
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
|
🚀 Deployed to staging by https://github.com/roryabraham in version: 9.0.40-0 🚀
|
|
🚀 Deployed to production by https://github.com/AndrewGable in version: 9.0.40-6 🚀
|
|
|
||
| const iouSettled = ReportUtils.isSettled(iouReportID) || action?.childStatusNum === CONST.REPORT.STATUS_NUM.REIMBURSED; | ||
| const previewMessageOpacity = useSharedValue(1); | ||
| const previewMessageStyle = useAnimatedStyle(() => ({ |
There was a problem hiding this comment.
bug: preview does not display checkmark - #50219
for details, see - #50554 (comment).

Details
We want to also animate the checkmark when paying expense.
Fixed Issues
$ #48036
PROPOSAL: #48036 (comment)
Tests
Same as QA Steps
Offline tests
Same as QA Steps
QA Steps
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectiontoggleReportand notonIconClick)myBool && <MyComponent />.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.mp4
Android: mWeb Chrome
android.mweb.mp4
iOS: Native
ios.mp4
iOS: mWeb Safari
ios.mweb.mp4
MacOS: Chrome / Safari
web.mp4
MacOS: Desktop
desktop.mp4