-
Notifications
You must be signed in to change notification settings - Fork 3k
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
fix: Change emoji navigation with arrow keys #7127
fix: Change emoji navigation with arrow keys #7127
Conversation
@rushatgabhane I've started with this PR. I have a question, can we use App/src/pages/home/report/EmojiPickerMenu/index.js Lines 373 to 383 in 913bd46
I need to be able to set the cursor to the end of the string. At the moment in |
Yeah sure, go ahead |
…oji-right-arrow-key
The I need this resolved because we want the emoji to be highlighted only if the cursor is at the end of the string. Once this is resolved rest is done. |
Just to clarify, we only wanna go to the first emoji when cursor is at the end of search query.
As mentioned in the issue description |
I think we should skip it then. React Native has an open issue on controlled selection facebook/react-native#29063 Alternative approachWhen search is refocused, we should highlight the search query, so it can be replaced by typing. This can be achieved by |
That is what is handled with ArrowUp that the whole string is selected. This can be done. |
@rushatgabhane Looks like I was wrong. This isn't how
While the second one is easy, I feel we might need the |
Gothu, but to verify.
Umm, I think you can check if cursor is at end using |
@rushatgabhane Yeah the updated PR covers the above cases. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just left a small comment. Otherwise LGTM and tests well. Great work @mananjadhav!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice work! Minor suggestions
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! 🎉
cc: @luacmartins
Thanks! @mananjadhav and @parasharrajat! |
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
🚀 Deployed to staging by @luacmartins in version: 1.1.30-4 🚀
|
🚀 Deployed to production by @chiragsalian in version: 1.1.31-1 🚀
|
Details
Fixed Issues
$ #7035
Tests
ArrowRight
to ensure that it selects the first emoji when the cursor is at the end of the stringArrowDown
should ensure that it goes to the first emoji irrespective of the cursor positionArrowUp
andArrowLeft
would select the text in the input and rest of the cursor works fine.QA Steps
right arrow
keyleft arrow
, it should focus the search input and select the textTested On
Screenshots
Web
web-emoji-arrow-keys.mov
Mobile Web
NA
Desktop
desktop-emoji-arrow-keys.mov
iOS
NA
Android
NA