ionic-framework icon indicating copy to clipboard operation
ionic-framework copied to clipboard

bug: Cannot move cursor into middle of contenteditable

Open CatoTH opened this issue 11 years ago • 9 comments

Type: bug

Platform: all

If you have a

<div contenteditable="true"></div>

and enter some text, it is not possible to move the text cursor somewhere into the middle of the text using mouse clicks or tap gestures, only to the very beginning or end of the text.

This can be seen here: http://codepen.io/anon/pen/vEyrqe

It seems to work if you replace the condition "ele.contentEditable === 'true'" in js/utils/tap.js (line 164 in the current master) by "ele.isContentEditable".

CatoTH avatar Jan 05 '15 15:01 CatoTH

I've just run into this one, and the resolution does appear to make it better for me.

morungos avatar Apr 12 '15 20:04 morungos

Hello! Are you guys still experiencing this issue with the latest version of ionic?

jgw96 avatar Mar 23 '16 18:03 jgw96

I've not tested it for a very long time. Sorry.

morungos avatar Mar 23 '16 19:03 morungos

@morungos No problem! Thanks for using Ionic! This looks like something i will look into on our end. I will be closing this issue for now, but feel free to continue the conversation!

jgw96 avatar Mar 23 '16 19:03 jgw96

I tested on this: http://codepen.io/anon/pen/vEyrqe There are still problems

sanmaozhao avatar Mar 24 '16 02:03 sanmaozhao

https://github.com/driftyco/ionic/blob/aef490b177406f9bd7d532294abd6c3198357622/js/utils/tap.js#L164

changing ele.contentEditable === 'true' to ele.isContentEditable works

jiazhengshi avatar Mar 31 '16 21:03 jiazhengshi

This bug still alive, It's happening when you have a contenteditable element inside ion-side-menu-content directive, when its clean inside ion-view with ion-content works fine, i think some event handler is preventing the gesture.

regards

emolinaglobant avatar Mar 28 '17 16:03 emolinaglobant

Still happening.

ghost avatar Jul 12 '17 12:07 ghost

Thanks for the issue! This issue is being locked to prevent comments that are not relevant to the original issue. If this is still an issue with the latest version of Ionic, please create a new issue and ensure the template is fully filled out.

ionitron-bot[bot] avatar Sep 02 '18 12:09 ionitron-bot[bot]