-
Notifications
You must be signed in to change notification settings - Fork 2.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[$250] Expense - Page blinks when opening Hold RHP from report details page #44203
Comments
Triggered auto assignment to @stephanieelliott ( |
Triggered auto assignment to @nkuoch ( |
👋 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:
|
@nkuoch FYI I haven't added the External label as I wasn't 100% sure about this issue. Please take a look and add the label if you agree it's a bug and can be handled by external contributors |
We think that this bug might be related to #wave-collect - Release 1 |
ProposalPlease re-state the problem that we are trying to solve in this issue.The page behind the RHP looks like blinking when pressing the hold button in details page. What is the root cause of that problem?When we choose the hold button, we do 2 things. First, dismiss the modal, and second, navigate to the hold reason page. App/src/components/PromotedActionsBar.tsx Lines 68 to 71 in 0176052
Lines 2808 to 2809 in 0176052
If we see the video slowly, we can notice that it's not blinking but the multiple navigations are happening at the same time causing the RHP overlay to become darker and then lighter. Screen.Recording.2024-06-23.at.18.26.47.movWhat changes do you think we should make in order to solve the problem?I don't know if it's expected to dismiss the modal when choosing the hold button, but if it's not, then we can remove it. Screen.Recording.2024-06-23.at.18.32.56.mov |
If you are the assigned CME please investigate whether the linked PR caused a regression and leave a comment with the results. If a regression has occurred and you are the assigned CM follow the instructions here. If this regression could have been avoided please consider also proposing a recommendation to the PR checklist so that we can avoid it in the future. |
Job added to Upwork: https://www.upwork.com/jobs/~01849f37018df4c9e8 |
Triggered auto assignment to Contributor-plus team member for initial proposal review - @ishpaul777 ( |
Thanks for your proposal @bernhardoj, I noticed that if we use yor solution then we'll have this issue we'll have this navigation glitch issue after submitting the hold reason Screen.Recording.2024-06-24.at.3.11.49.PM.mov |
@ishpaul777 I checked that it's because of the focus trap initial focus on the hold explanation page. That kind of sliding issue is similar to #43806 where we focus immediately while an animation is ongoing. This issue doesn't happen when you submit the hold with a mouse. One way to solve this is to delay the focus-trap by App/src/components/FocusTrap/FocusTrapForScreen/index.web.tsx Lines 43 to 47 in d7db203
|
Contributor details ProposalPlease re-state the problem that we are trying to solve in this issue.Page blinks when opening Hold RHP from report details page What is the root cause of that problem?The issue happens because the 2 Navigation Modal Items overlaps each other during close/open animation effect. So, the backdrop opacity of the 1st one overlaps the 2nd one during the opacity animation effect here: Line 1906 in d7db203
At some point the opacity sum of backdrops of the 1st modal and 2nd modal can give more than 0.72 (as was prescribed) and make the glitch effect of increasing backdrop opacity to 1 and back. so we have the glitch effect. What changes do you think we should make in order to solve the problem?Using the index property of useCardAnimation in BaseOverlay
and pass it to style can help us to undentify if we open next modal and turn off backdrop opacity animation, so we will have smooth effect without glitches DemoDemo-ExpenseApp-24.06.2024-oleksolv-Upwork.mov |
📣 @oleksolv! 📣
|
i am not confident with your RCA and solution for second problem @bernhardoj, mainly because i dont understand why this only happen after changes suggested in your Proposal, I guess the problem lies in this part of code that we'd have to return to report screen to navigate to hold educational page App/src/components/MoneyRequestHeader.tsx Lines 187 to 199 in 64dec34
|
Sorry, I am first time contributing to Expense, do I need anything to add to my previous post, so you can test that my solution works for modals stack? :) |
@ishpaul777 after my change, pressing the Hold button won't close the details page. [details, hold reason] Submitting the hold reason will pop the hold reason page which animates the page to slide from right to left and the details page from left to right, and at the same time the hold explanation page is showing with animation interrupted. |
@oleksolv Sorry for not providing the feedback earlier, I believe your proposal dont fix the issue at its root so for now i have not considered your proposal for this issue. |
I could be wrong @bernhardoj but as far as i understand Submitting the hold reason will navigate to report screen and then it navigates to hold reason page currently (backTo param), after removing |
@ishpaul777 If you do not mind I will provide some more details why it is the root issue and it will fix:
First call will trigger close modal. It spends up to 600ms to close the existed modal and trigger open new modal up to 600ms to open the new one. In this case each modal will have its backdrop: you can debug this in browser and see that the animation is in progress for both of the modals. One modal is interpolating from 0.72 - 0 and other from 0 - 0.72. Here the code you can test, the PR is not ready for review but you can see the changes and the issue fixed for all modals that are calling one by one: This solution will turn off the backdrop entering animation if the next screen is also modal. |
Yes, correct. App/src/pages/iou/HoldReasonPage.tsx Lines 56 to 69 in 2526e31
|
Hm then why not we directly navigate to Hold explaination page after submitting hold reason without the background useEffect, like we usually do for every page? Anything benifit of doing it the way it is now ? |
If you open a transaction report that is on hold, the hold explanation page will show because of the useEffect, so I believe that's the reason. |
@bernhardoj Can we disable the background navigation when the report screen is background, possibly by using |
I think we can do that, but I see this PR is working on a fix for this issue too. |
Oh lets Hold for the PR to merge and then retest if there's any issue left us to solve. Thanks! |
That PR was merged to prod yesterday! I'm not able to repro this one -- @ishpaul777 can you try testing and see if it's still happening for you? |
@nkuoch, @stephanieelliott, @ishpaul777 Uh oh! This issue is overdue by 2 days. Don't forget to update your issues! |
Issue is fixed 🎉 Screen.Recording.2024-06-29.at.4.30.39.AM.mov |
Yay! Thanks @ishpaul777 |
If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!
Version Number: 9.0.1-0
Reproducible in staging?: y
Reproducible in production?: no, new feature
If this was caught during regression testing, add the test name, ID and link from TestRail: Exp around https://expensify.testrail.io/index.php?/tests/view/4661954
Email or phone of affected tester (no customers):
Logs: https://stackoverflow.com/c/expensify/questions/4856
Expensify/Expensify Issue URL:
Issue reported by: Applause internal team
Slack conversation:
Action Performed:
Expected Result:
Page will not blink when opening Hold RHP from report details page.
Actual Result:
Page blinks when opening Hold RHP from report details page.
Workaround:
unknown
Platforms:
Which of our officially supported platforms is this issue occurring on?
Screenshots/Videos
Bug6521446_1719056245054.20240622_193147.mp4
View all open jobs on GitHub
Upwork Automation - Do Not Edit
Issue Owner
Current Issue Owner: @ishpaul777The text was updated successfully, but these errors were encountered: