-
Notifications
You must be signed in to change notification settings - Fork 2.9k
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
[$250] Expense - Unable to create a new line in description field with SHIFT+ENTER #48061
Comments
Triggered auto assignment to @kadiealexander ( |
Triggered auto assignment to @Gonals ( |
We think that this bug might be related to #wave-collect - Release 1 |
👋 Friendly reminder that deploy blockers are time-sensitive ⏱ issues! Check out the open `StagingDeployCash` deploy checklist to see the list of PRs included in this release, then work quickly to do one of the following:
|
I don't think this needs to be a blocker, as it is a fairly minor bug. @bernhardoj, I think this may have been caused by #46172. Could you take a look? |
I don't think it's caused by that PR since that's deployed to prod a month ago. |
Job added to Upwork: https://www.upwork.com/jobs/~0140f764621c9cb74a |
Triggered auto assignment to Contributor-plus team member for initial proposal review - @s77rt ( |
Edited by proposal-police: This proposal was edited at 2024-08-27 14:27:45 UTC. ProposalPlease re-state the problem that we are trying to solve in this issue.Pressing SHIFT+ENTER submit the description instead of adding new line. What is the root cause of that problem?The page has an ENTER shortcut enabled by default (from the Form) and there is a condition to disable the shortcut if the active element role is in the CONST.ROLE list and not a PRESENTATION role. App/src/components/Button/index.tsx Lines 140 to 146 in db1c4c2
The description ROLE is actually PRESENTATION,
but the live markdown input only accepts so in the end, the role of the input becomes "textbox". However, "textbox" doesn't exist in CONST.ROLE. It was previously existed in CONST.ACCESSIBILITY_ROLE but we remove ACCESSIBILITY_ROLE in favor of ROLE in #47705. This doesn't happen in a non-live markdown multiline text because we already ignore it as shown here. App/src/components/Button/validateSubmitShortcut/index.ts Lines 12 to 16 in 6ca91cd
What changes do you think we should make in order to solve the problem?Add "textbox" back to CONST.ROLE. There are a few roles that exist in CONST.ACCESSIBILITY_ROLE but not in CONST.ROLE. Perhaps we can re-add them all. Unrelated to the solutions.
Regarding this one, maybe we can update it to accept But actually, if we see the doc here, it's mentioned that it's better to use |
@bernhardoj Thanks for the proposal. I think this one should be fixed by the PR author given it's a new regression #47705. cc @Krishna2323 @ZhenjaHorbach |
Oh |
@ZhenjaHorbach, will raise the PR within an hour. |
Since the help wanted label is added, I think we can apply my solution instead of reintroducing deprecated ACCESSIBILITY_ROLE constant and also applying additional changes from my proposal. |
The
This makes sense but it won't fix the problem as if we do that now the role will be |
Looks like it's different between RN and RN-web since RN-web supports all ARIA roles. Maybe on native, it's not explicitly needed to set the role to an input, similar to web where it's recommended to use input without any role.
Yes, that's why I suggest this.
|
@bernhardoj If we remove the role prop from all input, including single-line inputs, then the enter key press won't be captured but it's needed in that case. |
This issue has not been updated in over 15 days. @s77rt, @Gonals, @kadiealexander eroding to Monthly issue. P.S. Is everyone reading this sure this is really a near-term priority? Be brave: if you disagree, go ahead and close it out. If someone disagrees, they'll reopen it, and if they don't: one less thing to do! |
@kadiealexander @Gonals Let's close this. Fixed on #48128 |
If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!
Version Number: v9.0.25-0
Reproducible in staging?: Y
Reproducible in production?: N
Email or phone of affected tester (no customers): applausetester+kh050806@applause.expensifail.com
Issue reported by: Applause Internal Team
Action Performed:
Expected Result:
A new line will be created with SHIFT+ENTER.
Actual Result:
A new line is not created with SHIFT+ENTER. The description is saved instead.
This issue happens in IOU, task and room description.
Workaround:
Unknown
Platforms:
Screenshots/Videos
Bug6583767_1724725007695.20240827_101239.mp4
View all open jobs on GitHub
Upwork Automation - Do Not Edit
Issue Owner
Current Issue Owner: @s77rtThe text was updated successfully, but these errors were encountered: