App icon indicating copy to clipboard operation
App copied to clipboard

Android - Emoji - Cursor is not in front of the emoji

Open isagoico opened this issue 5 years ago • 7 comments

If you haven’t already, check out our contributing guidelines for onboarding and email [email protected] to request to join our Slack channel!


Expected Result

Cursor position should display in front of the emoji

Actual Result

Cursor position is not in front of the emoji. Sometimes is behind the emoji and sometimes 2 characters ahead.

Action Performed

  1. Launch the app
  2. Log in with any account
  3. Type some text
  4. Add emoji in the middle of text

Workaround:

Can the user still use Expensify without this being fixed? Have you informed them of the workaround?

Platform:

Where is this issue occurring?

Web iOS Android ✔️ Desktop App Mobile Web

Version Number: 1.0.55-0

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

Notes/Photos/Videos:

image

Expensify/Expensify Issue URL:

View all open jobs on Upwork


Originally posted here: https://github.com/Expensify/Expensify.cash/pull/3080#issuecomment-849069503

isagoico avatar May 27 '21 17:05 isagoico

CC @aliabbasmalik8

isagoico avatar May 27 '21 17:05 isagoico

Going to unassign myself and set it as weekly given that there's an easy workaround on Android by just using the native emoji picker. @aliabbasmalik8 brought up what the issue is in this comment here.

nickmurray47 avatar May 27 '21 18:05 nickmurray47

Issue reproducible today during KI retests

isagoico avatar May 31 '21 00:05 isagoico

SOLUTION for android It can be fixed by adding

this.textInput.setNativeProps({selection: updatedSelection});

at here https://github.com/Expensify/Expensify.cash/blob/e95f5a3d07408794e8055b955f1a5666a9508e0c/src/pages/home/report/ReportActionCompose.js#L288

Actually selection props have some serious problem with native platforms you can see on this link github.com/facebook/react-native/issues/29063 so we can fix it by using direct manipulation like mentioned above

REF: https://reactnative.dev/docs/direct-manipulation#:~:text=It%20is%20sometimes%20necessary%20to,for%20views%20in%20mobile%20apps.

Thanks

aliabbasmalik8 avatar May 31 '21 23:05 aliabbasmalik8

@aliabbasmalik8 this should be fixed as part of https://github.com/Expensify/Expensify.cash/pull/3080 -- all fixes submitted should resolve the issue for all platforms. In your PR you flagged that you tested Android but it was not addressed in your fix.

jboniface avatar Jun 03 '21 18:06 jboniface

@jboniface yeah, I'm on it, just want to discuss the solution for this issue because selection has some issue on android. yes, I tested on Android as well but it did not produce every time on android so that's the reason it missed.

aliabbasmalik8 avatar Jun 03 '21 19:06 aliabbasmalik8

Issue reproducible today during KI retests

isagoico avatar Jun 07 '21 01:06 isagoico