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 payment 2021-08-02] Desktop - Unable to use grammar recommendation when editing a message #4107

Closed
isagoico opened this issue Jul 16, 2021 · 10 comments
Assignees
Labels
Engineering External Added to denote the issue can be worked on by a contributor Improvement Item broken or needs improvement. Reviewing Has a PR in review Weekly KSv2

Comments

@isagoico
Copy link

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 e.cash app in Desktop
  2. Navigate to a conversation
  3. Send a message with a grammar mistake
  4. Edit the same message
  5. Try to use word recommendation on the misspelled word

Expected Result:

User should be able to use the right click on the misspelled word.

Actual Result:

User is unable to use right click on the misspelled word.

Workaround:

Unknown.

Platform:

Where is this issue occurring?

Web
iOS
Android
Desktop App ✔️
Mobile Web

Version Number: 1.0.79-0

Logs: https://stackoverflow.com/c/expensify/questions/4856

Notes/Photos/Videos: Any additional supporting documentation

image

Expensify/Expensify Issue URL:

View all open jobs on Upwork


From @mallenexpensify https://expensify.slack.com/archives/C01GTK53T8Q/p1626286431252400

When composing a message on desktop (Mac), if you misspell a word, a redline shows below it and you can right click the misspelled word to get a recommendation for the correct spelling. If you've already sent the message, click edit, you're unable to right click the redlined, misspelled word to get a recommendation for the correct spelling.

@MelvinBot
Copy link

Triggered auto assignment to @deetergp (Engineering), see https://stackoverflow.com/c/expensify/questions/4319 for more details.

@deetergp
Copy link
Contributor

It looks like there's something in the edit box suppressing the use of context menus all together. I think this is something on which an external contractor should be able to work.

@deetergp deetergp added the External Added to denote the issue can be worked on by a contributor label Jul 22, 2021
@MelvinBot
Copy link

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

@parasharrajat
Copy link
Member

parasharrajat commented Jul 22, 2021

Yes @deetergp PressableWithSecondaryInteraction prevents the Context-menu or right-click which blocks the default menu from opening.

To fix this we can add a prop to PressableWithSecondaryInteraction, called preventDefault which will be set to true by default and allow the normal operation as now.

When we are editing a message i.e. this.props.draftMessage=== true, we can set this preventDefault=false which will not block the right-click.

  if (this.props.preventDefault) {
            e.preventDefault();
    }

Now a native menu will work.

@deetergp
Copy link
Contributor

@parasharrajat That looks good, let's do it!

@arielgreen Not sure how I managed to un-assign you, but now I've added you back. Let's get this into Upwork so Rajat can work on it.

@arielgreen
Copy link
Contributor

@parasharrajat I just sent over an offer on Upwork.

@parasharrajat
Copy link
Member

parasharrajat commented Jul 22, 2021

@arielgreen I just sent the PR over Github. 😺

@deetergp
Copy link
Contributor

Apologies for the delay, reviewing the PR now.

@MelvinBot MelvinBot removed the Overdue label Jul 26, 2021
@deetergp deetergp added the Reviewing Has a PR in review label Jul 26, 2021
@deetergp
Copy link
Contributor

Reviewed, approved, and merged!

@arielgreen arielgreen changed the title Desktop - Unable to use grammar recommendation when editing a message [Hold for payment 2021-08-02] Desktop - Unable to use grammar recommendation when editing a message Jul 27, 2021
@arielgreen arielgreen added Weekly KSv2 and removed Daily KSv2 labels Jul 27, 2021
@arielgreen
Copy link
Contributor

Paid! Thanks for the bump, @parasharrajat 😅

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Engineering External Added to denote the issue can be worked on by a contributor Improvement Item broken or needs improvement. Reviewing Has a PR in review Weekly KSv2
Projects
None yet
Development

No branches or pull requests

5 participants