-
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
[$500] mWeb - Request money - Composer doesn't get focused when coming back with back button from receipt page #28139
Comments
Triggered auto assignment to @JmillsExpensify ( |
Bug0 Triage Checklist (Main S/O)
|
Job added to Upwork: https://www.upwork.com/jobs/~011f26b03f915d1334 |
Current assignee @JmillsExpensify is eligible for the External assigner, not assigning anyone new. |
Triggered auto assignment to Contributor-plus team member for initial proposal review - @ntdiary ( |
ProposalPlease re-state the problem that we are trying to solve in this issueComposer gets focused when going back through the app back button but doesn't get focused when going back using the system/browser back button. What is the root cause of that problem?The cause of the problem is the default popstate behaviour of the browser when using the back button, which causes the modal to unmount without animation and prevents the input autofocus from being triggered. What changes do you think we should make in order to solve the problem?First of, within the AttachementModal.js component I added a useEffect that detects popstate event and if the modal is open it makes the modal close properly with animation:
Second, within the ReportActionCompose.js component I added a useEffect that listens to the focus event of the navigation (when modal closes) and if the composer input is NOT focused, using setTimeout o skip the blur function triggered by the modal close event, I focus the composer input like so:
What alternative solutions did you explore? (Optional)N/A Videos:web.mp4desktop.mp4ios.mp4android.mp4 |
📣 @ikevin127! 📣
|
Contributor details |
✅ Contributor details stored successfully. Thank you for contributing to Expensify! |
Hi @ikevin127, thank you for your proposal. : ) |
@JmillsExpensify, @ntdiary Whoops! This issue is 2 days overdue. Let's get this updated quick! |
📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸 |
@JmillsExpensify, @ntdiary Eep! 4 days overdue now. Issues have feelings too... |
@JmillsExpensify, @ntdiary Still overdue 6 days?! Let's take care of this! |
@JmillsExpensify @ntdiary this issue was created 2 weeks ago. Are we close to approving a proposal? If not, what's blocking us from getting this issue assigned? Don't hesitate to create a thread in #expensify-open-source to align faster in real time. Thanks! |
📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸 |
@JmillsExpensify, @ntdiary 10 days overdue. I'm getting more depressed than Marvin. |
I agree with @ntdiary, though as you can see in that linked issue, this isn't a priority for us at the moment. |
As a result, I've added it to that issue and I think we can still open this issue up for proposals. That is what similarly linked issues are also doing. |
Actually wait a second. |
This is actually not what we want, because we specially only want focus when in a request once you've tapped on the chat input. For all other cases, we actively don't want focus in the chat input. That gets in the way of the data. |
@JmillsExpensify @ntdiary this issue is now 3 weeks old. There is one more week left before this issue breaks WAQ and will need to go internal. What needs to happen to get a PR in review this week? Please create a thread in #expensify-open-source to discuss. Thanks! |
@JmillsExpensify, @ntdiary Eep! 4 days overdue now. Issues have feelings too... |
📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸 |
Given that we don't want the composer focused by design on the request details screen, I'm going to close. |
If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!
Action Performed:
Expected Result:
Composer should be focused on both scenarios (i.e on step 5 and on step 7)
Actual Result:
Composer gets focused when going back through the app back button but doesn't get focused when going back using the system/browser back button
Workaround:
Unknown
Platforms:
Which of our officially supported platforms is this issue occurring on?
Version Number: v1.3.74-0
Reproducible in staging?: Y
Reproducible in production?: Y
If this was caught during regression testing, add the test name, ID and link from TestRail:
Email or phone of affected tester (no customers):
Logs: https://stackoverflow.com/c/expensify/questions/4856
Notes/Photos/Videos: Any additional supporting documentation
Screen_Recording_20230920_130434_Chrome.mp4
Screen_Recording_20230925_165641_Chrome.mp4
Expensify/Expensify Issue URL:
Issue reported by: @Nathan-Mulugeta
Slack conversation: https://expensify.slack.com/archives/C049HHMV9SM/p1695204465763599
View all open jobs on GitHub
Upwork Automation - Do Not Edit
The text was updated successfully, but these errors were encountered: