Expensify / App

Welcome to New Expensify: a complete re-imagination of financial collaboration, centered around chat. Help us build the next generation of Expensify by sharing feedback and contributing to the code.
https://new.expensify.com
MIT License
3.45k stars 2.81k forks source link

[HOLD #10414] [$1000] mWeb/Safari - Chat - Focus is lost and keyboard does not open when selecting ‘Edit comment’ #25477

Open lanitochka17 opened 1 year ago

lanitochka17 commented 1 year ago

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:

  1. Open staging.new.expensify.com in Mobile Safari on iPhone
  2. Login with any account
  3. Go to any chat with existing messages or send new message
  4. Long tap on message
  5. Select 'Edit comment' in context menu

Expected Result:

Message in 'Edit' mode > Keyboard is open and focus on the edited message

Actual Result:

Focus is lost and keyboard does not open when selecting ‘Edit comment’

Workaround:

Unknown

Platforms:

Which of our officially supported platforms is this issue occurring on?

Version Number: 1.3.55-3

Reproducible in staging?: Yes

Reproducible in production?: Yes

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

https://github.com/Expensify/App/assets/78819774/9e292965-b54e-46d5-938c-14a0b4e107bf

Expensify/Expensify Issue URL:

Issue reported by: Applause - Internal Team

Slack conversation:

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~019d806d4cf680deb9
  • Upwork Job ID: 1693666426126630912
  • Last Price Increase: 2023-09-04
melvin-bot[bot] commented 1 year ago

Triggered auto assignment to @sakluger (Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details.

melvin-bot[bot] commented 1 year ago

Bug0 Triage Checklist (Main S/O)

sakluger commented 1 year ago

Different issue, but slightly related to https://github.com/Expensify/App/issues/24555 in that they are both unexpected behaviors when selecting Edit Comment in the mobile app.

melvin-bot[bot] commented 1 year ago

Job added to Upwork: https://www.upwork.com/jobs/~019d806d4cf680deb9

melvin-bot[bot] commented 1 year ago

Current assignee @sakluger is eligible for the External assigner, not assigning anyone new.

melvin-bot[bot] commented 1 year ago

Triggered auto assignment to Contributor-plus team member for initial proposal review - @jjcoffee (External)

shubham1206agra commented 1 year ago

Unable to repro in DEV Is there any extra steps?

swakeert commented 1 year ago

Proposal

Please re-state the problem that we are trying to solve in this issue.

After clicking Edit Comment, the text input box is not getting focussed, resulting in keyboard not opening automatically on mobile phones.

What is the root cause of that problem?

https://github.com/Expensify/App/blob/main/src/pages/home/report/ContextMenu/ContextMenuActions.js#L283

In the editAction function, we are not calling the focus method when closePopover is true. In all the other functions, ReportActionComposeFocusManager.focus(); is called in one way or the other, making sure the focus is correctly and manually set.

What changes do you think we should make in order to solve the problem?

We need to ensure the focus gets set on the correct text input. The ReportActionComposeFocusManager only handles focus on the default text input box for the main chat.

I would suggest creating a FocusManager that focuses on the newly created Edit Textbox and switches focus to it.

What alternative solutions did you explore? (Optional)

We can open the edit in its own page like 'reply in thread' functionality and set the focus to the default chat box using ReportActionComposeFocusManager, but that changes the UI and is not a bugfix. PS: Seems like reply in thread is also not setting the focus correctly.

jjcoffee commented 1 year ago

@swakeert Your RCA is missing an explanation of why this would only apply to Safari mWeb (if that is indeed the case!). I'm also curious if you're able to reproduce the issue on latest main?

sakluger commented 1 year ago

Waiting on more proposals.

jjcoffee commented 1 year ago

@lanitochka17 are you still able to reproduce? We've reports that it's no longer reproducible.

melvin-bot[bot] commented 1 year ago

📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸

pradeepmdk commented 1 year ago

this is a webkit issue https://bugs.webkit.org/show_bug.cgi?id=195884. both chrome and safari we will face this issue.

jjcoffee commented 1 year ago

@pradeepmdk Are you able to reproduce the issue on latest main? You're welcome to raise a proposal to fix the issue if so!

pradeepmdk commented 1 year ago

yes, @jjcoffee is still an issue there. i will try prepare the solution

sakluger commented 1 year ago

I was still able to reproduce this on staging and prod. @pradeepmdk looking forward to your proposal!

melvin-bot[bot] commented 1 year ago

@sakluger @jjcoffee 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!

sakluger commented 1 year ago

@pradeepmdk how's it coming?

If we don't get any proposals soon, I'll ask our expert contributors to help out with this one.

pradeepmdk commented 1 year ago

@sakluger not yet. because they are allowing only user touch events based on their showing. We can't do anything here We can check with expert contributors as well.

melvin-bot[bot] commented 1 year ago

📣 It's been a week! Do we have any satisfactory proposals yet? Do we need to adjust the bounty for this issue? 💸

melvin-bot[bot] commented 1 year ago

@sakluger, @jjcoffee Whoops! This issue is 2 days overdue. Let's get this updated quick!

jjcoffee commented 1 year ago

Waiting for proposals!

@swakeert are you interested in fleshing out your proposal with more details?

pradeepmdk commented 1 year ago

@jjcoffee I found this https://github.com/Expensify/App/issues/10414

sakluger commented 1 year ago

@jjcoffee I found this https://github.com/Expensify/App/issues/10414

Interesting, good find! I left a comment there asking if their PR will fix this issue. I'll put this one on hold while we wait for a response.

sakluger commented 1 year ago

No response, asked again.

sakluger commented 1 year ago

Parashat said we can leave this issue on hold for https://github.com/Expensify/App/issues/10414. Setting to Monthly to match the hold issue.

sakluger commented 11 months ago

Still on hold for https://github.com/Expensify/App/issues/10414, which ended up getting delayed when an edge case was discovered that made the fix not work.

sakluger commented 10 months ago

Still no updates on the hold issue.

sakluger commented 9 months ago

Still on hold.

sakluger commented 8 months ago

Still on hold for https://github.com/Expensify/App/issues/10414. I commented on that issue to see if we still planned to fix that one.

sakluger commented 7 months ago

Still on hold for https://github.com/Expensify/App/issues/10414.

sakluger commented 6 months ago

Adding to vip-vsb since this is chat-related funcationality.

sakluger commented 5 months ago

Still on hold for https://github.com/Expensify/App/issues/10414

sakluger commented 3 months ago

No updates on the hold issue.

sakluger commented 2 months ago

Still on hold.

sakluger commented 1 month ago

No update.

sakluger commented 2 weeks ago

Still no updates on the hold issue.