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 - $250] Firefox - Chat- Intended comment not copied to clipboard after highlighting a part of the text and selecting another message reported by @daraksha-dk #12523

Closed
kavimuru opened this issue Nov 7, 2022 · 14 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 Help Wanted Apply this label when an issue is open to proposals by contributors Weekly KSv2

Comments

@kavimuru
Copy link

kavimuru commented Nov 7, 2022

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. Go to any chat
  2. Select a part of any message
  3. Open the context menu for any message
  4. Select "Copy to Clipboard" option
  5. the selected part in 2nd step will be copied instead of the message on 3rd step

Expected Result:

the whole message should get copied for which the context menu was open

Actual Result :
Only the initial selected text is getting copied

Workaround:

unknown

Platform:

Where is this issue occurring?

  • Web - Firefox only

Version Number: 1.2.24-1
Reproducible in staging?: y
Reproducible in production?: y
Email or phone of affected tester (no customers):
Logs: https://stackoverflow.com/c/expensify/questions/4856
Notes/Photos/Videos:

copy.issue.mp4
Recording.865.mp4

Expensify/Expensify Issue URL:
Issue reported by: @daraksha-dk
Slack conversation: https://expensify.slack.com/archives/C01GTK53T8Q/p1667833739312529

View all open jobs on GitHub

@kavimuru kavimuru added Daily KSv2 Bug Something is broken. Auto assigns a BugZero manager. labels Nov 7, 2022
@melvin-bot
Copy link

melvin-bot bot commented Nov 7, 2022

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

@NicMendonca
Copy link
Contributor

I am having trouble reproducing this, so asking here

@NicMendonca NicMendonca added the External Added to denote the issue can be worked on by a contributor label Nov 8, 2022
@melvin-bot
Copy link

melvin-bot bot commented Nov 8, 2022

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

@melvin-bot
Copy link

melvin-bot bot commented Nov 8, 2022

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

@melvin-bot melvin-bot bot added the Help Wanted Apply this label when an issue is open to proposals by contributors label Nov 8, 2022
@melvin-bot
Copy link

melvin-bot bot commented Nov 8, 2022

Triggered auto assignment to @tgolen (External), see https://stackoverflow.com/c/expensify/questions/7972 for more details.

@melvin-bot melvin-bot bot changed the title Firefox - Chat- Intended comment not copied to clipboard after highlighting a part of the text and selecting another message reported by @daraksha-dk [$250] Firefox - Chat- Intended comment not copied to clipboard after highlighting a part of the text and selecting another message reported by @daraksha-dk Nov 8, 2022
@NicMendonca
Copy link
Contributor

@s77rt
Copy link
Contributor

s77rt commented Nov 8, 2022

Proposal

--- a/src/pages/home/report/ReportActionItem.js
+++ b/src/pages/home/report/ReportActionItem.js
@@ -107,6 +107,13 @@ class ReportActionItem extends Component {
         if (this.props.draftMessage) {
             return;
         }
+
+        const windowSelection = window.getSelection();
+        if (!event.target.contains(windowSelection.focusNode)) {
+            windowSelection.selectAllChildren(event.target);
+            windowSelection.removeAllRanges();
+        }
+
         const selection = SelectionScraper.getCurrentSelection();
         ReportActionContextMenu.showContextMenu(
             ContextMenuActions.CONTEXT_MENU_TYPES.REPORT_ACTION,

Pros & Cons

Pros:

  • Fix the issue
  • Identical behaviour on all browsers

Cons: (maybe Pros2?)

Kooha-2022-11-08-17-43-58.mp4

@NicMendonca
Copy link
Contributor

I am about to go OOO for a week, so re-assigning.

@NicMendonca NicMendonca removed their assignment Nov 9, 2022
@NicMendonca NicMendonca added Bug Something is broken. Auto assigns a BugZero manager. and removed Bug Something is broken. Auto assigns a BugZero manager. labels Nov 9, 2022
@melvin-bot
Copy link

melvin-bot bot commented Nov 9, 2022

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

@s77rt
Copy link
Contributor

s77rt commented Nov 12, 2022

I think this should be set on hold in favour of #12521

@melvin-bot melvin-bot bot added the Overdue label Nov 12, 2022
@slafortune slafortune added Weekly KSv2 and removed Daily KSv2 labels Nov 15, 2022
@melvin-bot melvin-bot bot removed the Overdue label Nov 15, 2022
@slafortune slafortune changed the title [$250] Firefox - Chat- Intended comment not copied to clipboard after highlighting a part of the text and selecting another message reported by @daraksha-dk [Hold - $250] Firefox - Chat- Intended comment not copied to clipboard after highlighting a part of the text and selecting another message reported by @daraksha-dk Nov 15, 2022
@melvin-bot melvin-bot bot added the Overdue label Nov 23, 2022
@slafortune
Copy link
Contributor

@tgolen @s77rt @Santhosh-Sellavel The other issue is moving along nicely - any reason why this one can't be closed?

@melvin-bot melvin-bot bot removed the Overdue label Nov 23, 2022
@s77rt
Copy link
Contributor

s77rt commented Nov 23, 2022

@slafortune Not the same issue.
I though fixing the first issue will fix this as well but does not seem like it

@iwiznia
Copy link
Contributor

iwiznia commented Nov 25, 2022

AFAIK we said we would not be focusing on supporting firefox, so I think we should close this issue.

@slafortune
Copy link
Contributor

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 Help Wanted Apply this label when an issue is open to proposals by contributors Weekly KSv2
Projects
None yet
Development

No branches or pull requests

7 participants