material icon indicating copy to clipboard operation
material copied to clipboard

Touch does not place cursor on input fields on Android

Open vbraun opened this issue 9 years ago • 12 comments

Actual Behavior:

  • What is the issue? *

Touch on input field does not place the cursor at different text positions on Android phone

  • What is the expected behavior?

When there is a input field with text, the cursor should be placed at the touch location.

CodePen (or steps to reproduce the issue): *

  1. Open the input demos (https://material.angularjs.org/latest/demo/input) on an Android phone.
  2. Enter some text in an input field.
  3. Touching different positions in the entered text does not place the cursor.

You can move the cursor by dragging the blue cursor location icon, but the cursor cannot be placed by touch events inside the text.

With $mdGestureProvider.skipClickHijack() this also works, i.e., touch events change the cursor location.

Angular Versions: *

  • Angular Version: 1.5.8
  • Angular Material Version: 1.1.1

Additional Information:

  • Browser Type: * Mobile chrome
  • Browser Version: * Android
  • OS: * 7

Related tickets:

  • #10058 references ionic, but the issue is independent of ionic.
  • #9333 was imho wrongly closed; The issue is on Android but it was closed because iOS behavior is different.
  • #8829 same issue reported for mobile firefox, comment says it also happens on mobile chrome

vbraun avatar Jan 25 '17 10:01 vbraun

Any progress here, guys? I have the same issue.

dkirsanov avatar Apr 07 '17 11:04 dkirsanov

Good to see this is a known issue and others have run into it. It is a pretty impactful bug for a special p2p web app we're trying to launch.

loggerq avatar Apr 07 '17 12:04 loggerq

I have the same issue.

mkuzmych avatar Apr 14 '17 05:04 mkuzmych

Same problem here, reproduced with chrome developper console on Windows.

  1. Go to https://material.angularjs.org/latest/demo/input
  2. Open the developper Console
  3. Toggle device toolbar (Ctrl + Shift + M)
  4. Refresh (Ctrl + F5)

By the way, there's also a problem with textarea (all text is selected)

This is really impactful.

niroussel avatar Jun 07 '17 21:06 niroussel

Agreed, this is really impactful.

This is the kind of issue which make an entire app down. It's probably something with focus events... I understand the effort to move to angular 4, but leaving the communauty which such an issue don't encourage to move to angular 4...

PhMetzger avatar Jun 28 '17 17:06 PhMetzger

Any progress on this one? This is a blocking issue. Unfortunately this makes the whole framework useless because this is a major issue that makes any app unusable. Is there at least a workaround? Thank you very much.

simentesempre avatar Jul 11 '17 07:07 simentesempre

Also reported by at least one Google team

jelbourn avatar Jul 26 '17 18:07 jelbourn

This problem still happening on mobile

gelordi avatar Dec 19 '17 14:12 gelordi

Its fixed for me; Do you have the right version?

vbraun avatar Dec 19 '17 14:12 vbraun

yes, i have 1.1.5 and it doesn't work on android/chrome/mobile. i can't edit textarea content

gelordi avatar Dec 19 '17 15:12 gelordi

Can you guys check this problem?

gelordi avatar Dec 20 '17 20:12 gelordi

@gelordi please open a new issue with a CodePen reproduction.

Splaktar avatar Sep 20 '18 18:09 Splaktar