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

[$500] Edit private note form doesn't submit by enter key #28860

Closed
2 of 6 tasks
m-natarajan opened this issue Oct 4, 2023 · 15 comments
Closed
2 of 6 tasks

[$500] Edit private note form doesn't submit by enter key #28860

m-natarajan opened this issue Oct 4, 2023 · 15 comments
Assignees
Labels
Bug Something is broken. Auto assigns a BugZero manager. Daily KSv2 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

Comments

@m-natarajan
Copy link

m-natarajan commented Oct 4, 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 report that has the private note option
  2. Click on the header > Private notes
  3. Select a private note to open the edit page
  4. Edit the private note and press enter key

Expected Result:

The private note should be saved and go back to the previous page

Actual Result:

The input adds a new line

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: 1.3.77-5
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.2023-10-04.at.15.07.46.mov
Screen.Recording.2023-10-04.at.15.08.32.mov
Recording.470.mp4

Expensify/Expensify Issue URL:
Issue reported by: @dukenv0307
Slack conversation: https://expensify.slack.com/archives/C049HHMV9SM/p1696405348401729

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~01114e9ac4dbe61472
  • Upwork Job ID: 1709667574583115776
  • Last Price Increase: 2023-10-11
@m-natarajan m-natarajan added the External Added to denote the issue can be worked on by a contributor label Oct 4, 2023
@melvin-bot melvin-bot bot changed the title Edit private note form doesn't submit by enter key [$500] Edit private note form doesn't submit by enter key Oct 4, 2023
@melvin-bot
Copy link

melvin-bot bot commented Oct 4, 2023

Job added to Upwork: https://www.upwork.com/jobs/~01114e9ac4dbe61472

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

melvin-bot bot commented Oct 4, 2023

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

@melvin-bot melvin-bot bot added the Daily KSv2 label Oct 4, 2023
@m-natarajan
Copy link
Author

Proposal by @dukenv0307

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

Edit private note form doesn't submit by pressing enter key

What is the root cause of that problem?

We don't add submitOnEnter prop to allow the submission of the form by pressing the enter key


We should add submitOnEnter prop to the text input to make the form can be submitted by pressing enter key

What alternative solutions did you explore? (Optional)

NA

Result

Screencast.from.04-10-2023.15.19.04.webm

@alitoshmatov
Copy link
Contributor

Looks like it is intended behavior. Since notes might be multiline

@ayazalavi
Copy link
Contributor

Proposal

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

Enter button is not submitting privates notes form.

What is the root cause of that problem?

Root cause of the problem is we have policy about when form should be submitted on pressing enter and when we should add a new line on pressing shift+enter. There is prop for multiline inputs that allow us to handle form like this

submitOnEnter: PropTypes.bool,

it is not added

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

Add submitOnEnter={!Browser.isMobile()} prop here

Above change will ensure that enter behavior gets updated for desktop browsers and for mobile apps only.

What alternative solutions did you explore? (Optional)

N/A

@cubuspl42
Copy link
Contributor

@ayazalavi Does it do any harm to add submitOnEnter for mobile browsers too? Don't we support a rare but possible scenario like an Android phone/tablet with a Bluetooth hardware keyboard + mobile Chrome?

@dukenv0307
Copy link
Contributor

@cubuspl42 Actually, we use submitOnEnter={!Browser.isMobile()} in other page and this PR introduce this #27702

@cubuspl42
Copy link
Contributor

I asked also on Slack

@ayazalavi
Copy link
Contributor

@cubuspl42, I believe this form submission behavior is intended for platforms other than mobile browsers. Mobile browsers have different form submission behavior due to the lack of implementation for interactions between soft keyboards and HTML forms in the app. Please take a look at this issue for more information: Link to Issue #28569.

@melvin-bot
Copy link

melvin-bot bot commented Oct 10, 2023

@cubuspl42 Huh... This is 4 days overdue. Who can take care of this?

@melvin-bot melvin-bot bot added the Overdue label Oct 10, 2023
@cubuspl42
Copy link
Contributor

@m-natarajan Let's close this. This might be intended and in another thread we decided that private notes are not a priority as they are mostly an internal feature.

@melvin-bot melvin-bot bot removed the Overdue label Oct 11, 2023
@melvin-bot
Copy link

melvin-bot bot commented Oct 11, 2023

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

@m-natarajan m-natarajan added the Bug Something is broken. Auto assigns a BugZero manager. label Oct 13, 2023
@melvin-bot melvin-bot bot added the Overdue label Oct 13, 2023
@melvin-bot
Copy link

melvin-bot bot commented Oct 13, 2023

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

@melvin-bot
Copy link

melvin-bot bot commented Oct 13, 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

@puneetlath
Copy link
Contributor

I agree with @cubuspl42 and I believe this page is being revamped anyways, so let's close this for now.

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. Daily KSv2 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
Projects
None yet
Development

No branches or pull requests

6 participants