-
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
[HOLD for payment 2023-05-29] [$1000] Pressing ESC when emoji suggestions list is open clears the composer #18434
Comments
Triggered auto assignment to @dylanexpensify ( |
Bug0 Triage Checklist (Main S/O)
|
ProposalPlease re-state the problem that we are trying to solve in this issue.Pressing ESC when emoji suggestions list is open clears the composer What is the root cause of that problem?The root cause is come from this hotkey listener App/src/pages/home/report/ReportActionCompose.js Lines 230 to 237 in 5f649d5
When we press "Escape" key, it will clear the content in composer. What changes do you think we should make in order to solve the problem?We have a That means, we need to update current
Code ref: if (e.key === CONST.KEYBOARD_SHORTCUTS.ESCAPE.shortcutKey) {
e.preventDefault();
if (this.state.suggestedEmojis.length) {
this.resetSuggestedEmojis();
} else {
this.updateComment('', true);
}
return;
} What alternative solutions did you explore? (Optional)Another option I would like to propose is still keep current keyboard listener in the componentDidMount, but update the condition so that it won't clear content if having suggested emojis. More details, replace this line by: if (!this.state.isFocused || this.comment.length === 0 || this.state.suggestedEmojis.length) |
Didn't get to this today due to prioritizing Payroll, CPM, ECUK items! Will review Monday! |
Will work on reproducing today, then if good will make external |
Melvin, I just posted above! |
Job added to Upwork: https://www.upwork.com/jobs/~01808b10a5f865a8d3 |
Current assignee @dylanexpensify is eligible for the External assigner, not assigning anyone new. |
Triggered auto assignment to Contributor-plus team member for initial proposal review - @mollfpr ( |
Triggered auto assignment to @puneetlath ( |
@dylanexpensify Is not reproducible anymore; I think it's already fixed here #18469. |
I agree it fixed in PR mentioned above. But do you think it's worth to refactor it a bit like I mentioned in my proposal here => centralize hotkey logics in 1 place |
@hoangzinh would you mind explaining how your proposal is different than what we have today and why you think it would be better? |
@puneetlath sure. So my point is centralize logic.
So I think it's better if we can centralize those logic in 1 place if it's possible like I suggested in my proposal #18434 (comment). Advantages:
So it's my point of views |
I still feel good with the current implementation. @hoangzinh If you still think this should be done, let's drop it in Slack. |
Coming back from OOO! @hoangzinh did you bring this up in Slack? |
@dylanexpensify merged! |
Current assignee @puneetlath is eligible for the Bug assigner, not assigning anyone new. |
I'm heading OOO tomorrow for about a week so adding another BZ member while I'm away to help keep the train moving! 🚂 @puneetlath lmk if this works ok with you assigned! |
|
The solution for this issue has been 🚀 deployed to production 🚀 in version 1.3.16-7 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue: If no regressions arise, payment will be issued on 2023-05-29. 🎊 After the hold period is over and BZ checklist items are completed, please complete any of the applicable payments for this issue, and check them off once done.
As a reminder, here are the bonuses/penalties that should be applied for any External issue:
|
BugZero Checklist: The PR fixing this issue has been merged! The following checklist (instructions) will need to be completed before the issue can be closed:
|
@huzaifa-99 @hoangzinh can you apply to the Upwork job please? https://www.upwork.com/jobs/~01808b10a5f865a8d3 |
Applied to the Upwork job |
Applied. Thanks for the ping @puneetlath. |
Paid @huzaifa-99 and @hoangzinh. @mollfpr I'll pay you out once the checklist is done. |
Thanks @puneetlath!
No offending PR
Regression step should be enough.
We can update the TC Compose Box - Emoji Suggestions Desktop/Web - ESC Keypress
|
Thanks @mollfpr looks great. Issue to create regression test is here: https://github.com/Expensify/Expensify/issues/287251 And everyone has been paid. Thanks everyone! |
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:
Expected Result:
Pressing ESC when emoji suggestions list is open should close the suggestions list, when the list is closed than pressing esc should clear it.
Actual Result:
Composer is cleared on pressing ESC when emoji suggestions are shown
Workaround:
Can the user still use Expensify without this being fixed? Have you informed them of the workaround?
Platforms:
Which of our officially supported platforms is this issue occurring on?
Version Number: 1.3.10.4
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-05-04.at.3.22.33.PM.mov
Recording.486.mp4
Expensify/Expensify Issue URL:
Issue reported by: https://expensify.slack.com/archives/C049HHMV9SM/p1683196034617709
Slack conversation: @huzaifa-99
View all open jobs on GitHub
Upwork Automation - Do Not Edit
The text was updated successfully, but these errors were encountered: