Skip to content
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

[Hold for #23757][$1000] Web - LHN - Emoji picker doesn't close when navigating to other chat with the browser back button #24559

Closed
1 of 6 tasks
izarutskaya opened this issue Aug 14, 2023 · 24 comments
Assignees
Labels
Bug Something is broken. Auto assigns a BugZero manager. External Added to denote the issue can be worked on by a contributor Weekly KSv2

Comments

@izarutskaya
Copy link

izarutskaya commented Aug 14, 2023

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 a chat with Concierge or other chat
  2. Then proceed to open a chat with user B
  3. Click on emoji icon from composer
  4. Click on the browser's back button
  5. Click on one of the emojis
  6. Open the chat you started before starting chat with user B

Expected Result:

Emoji picker should either close on navigating to other chat or the selected emoji should be entered to the current composer

Actual Result:

Emoji picker doesn't close & selecting emoji inserts emoji user B's composer

Workaround:

unknown

Platforms:

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

  • Android / native
  • Android / Chrome
  • iOS / native
  • iOS / Safari
  • MacOS / Chrome / Safari
  • MacOS / Desktop

Version Number: v1.3.54-2

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

Screencast.from.2023-08-04.23-56-31.mp4
Recording.1194.mp4

Expensify/Expensify Issue URL:

Issue reported by: @Natnael-Guchima

Slack conversation: https://expensify.slack.com/archives/C049HHMV9SM/p1691182964868429

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~01a49af3096640d7b0
  • Upwork Job ID: 1693415547996028928
  • Last Price Increase: 2023-08-21
@izarutskaya izarutskaya added Daily KSv2 Bug Something is broken. Auto assigns a BugZero manager. labels Aug 14, 2023
@melvin-bot
Copy link

melvin-bot bot commented Aug 14, 2023

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

@melvin-bot
Copy link

melvin-bot bot commented Aug 14, 2023

Bug0 Triage Checklist (Main S/O)

  • This "bug" occurs on a supported platform (ensure Platforms in OP are ✅)
  • This bug is not a duplicate report (check E/App issues and #expensify-bugs)
    • If it is, comment with a link to the original report, close the issue and add any novel details to the original issue instead
  • This bug is reproducible using the reproduction steps in the OP. S/O
    • If the reproduction steps are clear and you're unable to reproduce the bug, check with the reporter and QA first, then close the issue.
    • If the reproduction steps aren't clear and you determine the correct steps, please update the OP.
  • This issue is filled out as thoroughly and clearly as possible
    • Pay special attention to the title, results, platforms where the bug occurs, and if the bug happens on staging/production.
  • I have reviewed and subscribed to the linked Slack conversation to ensure Slack/Github stay in sync

@hoangzinh
Copy link
Contributor

hoangzinh commented Aug 15, 2023

Proposal

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

Web - LHN - Emoji picker doesn't close when navigating to other chat with the browser back button

What is the root cause of that problem?

We haven't had any logic to hide the EmojiPicker when the current report is unmount and mount another report

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

I think we can put logic to hide the EmojiPicker when the report action compose is unmounted. That means, in the componentWillUnmount of ReportActionCompose, we can call EmojiPickerActions.hideEmojiPicker to hide emoji picker.

Beside that, with new implement in this PR #24479, before call EmojiPickerActions.hideEmojiPicker, we can check if the EmojiPicker is active for current reportID

@jfquevedol2198
Copy link
Contributor

Proposal

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

Web - LHN - Emoji picker doesn't close when navigating to other chat with the browser back button

What is the root cause of that problem?

When currentReportID is changed, we are not closing EmojiPicker.

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

Add code to hide EmojiPicker when currentReportID is changed in EmojiPickerButton.js

    const {currentReportID} = useCurrentReportID();
    useEffect(() => {
        if (!EmojiPickerAction.emojiPickerRef.current || !EmojiPickerAction.emojiPickerRef.current.isEmojiPickerVisible) return;
        EmojiPickerAction.emojiPickerRef.current.hideEmojiPicker();
    }, [currentReportID])

What alternative solutions did you explore? (Optional)

N/A

@ginsuma

This comment was marked as outdated.

@kadiealexander
Copy link
Contributor

@Natnael-Guchima I'm having a lot of trouble following your reproduction steps. It looks like, from the video, you're logged into two accounts. Can you please write more detailed steps that make it clear which user and tab to use?

@kadiealexander kadiealexander added the Needs Reproduction Reproducible steps needed label Aug 15, 2023
@ShogunFire
Copy link
Contributor

ShogunFire commented Aug 15, 2023

@kadiealexander No need for two accounts to reproduce.

  1. Go to a report
  2. Go to another report
  3. Open the emoji picker
  4. Click on back button

@Natnael-Guchima
Copy link

@kadiealexander please try the steps listed below, and let me know if you are not able to reproduce the issue.

Action Performed:

  1. Open a chat with Concierge or another chat
  2. Then proceed to open a chat with user B
  3. Click on emoji icon from composer
  4. Click on the browser's back button

Expected Result:
Emoji picker should close when navigating to other chat

Screencast.from.2023-08-16.09-37-57.mp4

@kadiealexander
Copy link
Contributor

I can't reproduce on the latest version:

2023-08-16_19-20-13.mp4

@Natnael-Guchima could you please test on version v1.3.54-11 and let me know if you're still experiencing it?

@Natnael-Guchima
Copy link

I am still able to reproduce it on the latest version (v1.3.54-11). I am not sure if this is a device-specific issue. @ShogunFire are you able to reproduce this on that latest release?

Screencast.from.2023-08-16.10-43-41.mp4

@kadiealexander
Copy link
Contributor

@Natnael-Guchima are you testing on Windows? It's possible it's windows-specific.

@Natnael-Guchima
Copy link

Yes, I am testing on windows.

@ShogunFire
Copy link
Contributor

Also testing on windows

@jfquevedol2198
Copy link
Contributor

I can reproduce this on staging (v1.3.54-11) and production (v1.3.53-2)
cc @ShogunFire @kadiealexander @Natnael-Guchima

@Natnael-Guchima
Copy link

What device are you testing on? Is it Mac or Windows? @jfquevedol2198

@jfquevedol2198
Copy link
Contributor

MacOS / Chrome
cc @Natnael-Guchima

@jfquevedol2198
Copy link
Contributor

@Natnael-Guchima I can also reproduce this on Windows

@kadiealexander
Copy link
Contributor

I was able to repro this morning on Mac Chrome v1.3.54-13.

@kadiealexander kadiealexander added External Added to denote the issue can be worked on by a contributor and removed Needs Reproduction Reproducible steps needed labels Aug 21, 2023
@melvin-bot melvin-bot bot changed the title Web - LHN - Emoji picker doesn't close when navigating to other chat with the browser back button [$1000] Web - LHN - Emoji picker doesn't close when navigating to other chat with the browser back button Aug 21, 2023
@melvin-bot
Copy link

melvin-bot bot commented Aug 21, 2023

Job added to Upwork: https://www.upwork.com/jobs/~01a49af3096640d7b0

@melvin-bot melvin-bot bot added the Help Wanted Apply this label when an issue is open to proposals by contributors label Aug 21, 2023
@melvin-bot
Copy link

melvin-bot bot commented Aug 21, 2023

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

@melvin-bot
Copy link

melvin-bot bot commented Aug 21, 2023

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

@aimane-chnaif
Copy link
Contributor

This might be fixed in #23757 so let's put this on hold for now

@kadiealexander kadiealexander added Weekly KSv2 and removed Daily KSv2 Help Wanted Apply this label when an issue is open to proposals by contributors labels Aug 22, 2023
@kadiealexander kadiealexander changed the title [$1000] Web - LHN - Emoji picker doesn't close when navigating to other chat with the browser back button [Hold for #23757][$1000] Web - LHN - Emoji picker doesn't close when navigating to other chat with the browser back button Aug 22, 2023
@Natnael-Guchima
Copy link

Natnael-Guchima commented Aug 25, 2023

@kadiealexander this issue is fixed on dev now. The fixing PR is here which was intended to fix another issue that was reported here. The discussion to fix this issue - the one I reported - on the fixing PR starts here on Aug 15, and I reported this issue on Aug 5. On Aug 15, a new solution was introduced here to fix the issue I reported:

The new solution will also fix #24559 (btw, do we need to compensate @hoangzinh too?).

This is to ask if I am eligible for reporting bonus since the discussion to fix the issue I reported comes after I reported the issue?
Thanks.

The issue fixed on dev:

Screencast.from.2023-08-25.09-27-18.mp4

The current behavior of the issue on the latest staging.

Screencast.from.2023-08-25.09-30-20.mp4

My reporting date

Screenshot from 2023-08-25 09-32-10

@melvin-bot melvin-bot bot added the Overdue label Aug 30, 2023
@kadiealexander
Copy link
Contributor

@Natnael-Guchima I don't think we typically pay out reporting bonuses for issues that were fixed elsewhere. Generally if something goes on hold because another PR will fix it, we don't make any payments when it comes off hold and is fixed. Sorry about that!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something is broken. Auto assigns a BugZero manager. External Added to denote the issue can be worked on by a contributor Weekly KSv2
Projects
None yet
Development

No branches or pull requests

9 participants