Bug 148061

Summary: REGRESSION: Can't move cursor to start of text after entering long string of text into <input type=text>
Product: WebKit Reporter: Chris Rebert <webkit>
Component: FormsAssignee: Megan Gardner <megan_gardner>
Status: RESOLVED DUPLICATE    
Severity: Major CC: a.grossauer, ainop, fryngies, gchatz, jaan.murumets, Jaycezhang9602, megan_gardner, osrec1, sonderbazz, wenson_hsieh, ylvamendes
Priority: P2 Keywords: HasReduction, InRadar
Version: Safari 9   
Hardware: iPhone / iPad   
OS: iOS 10   
URL: http://jsfiddle.net/cvrebert/cjn5n4z2/show/
Bug Depends on:    
Bug Blocks: 159753    

Description Chris Rebert 2015-08-15 15:18:08 PDT
Platform: iOS 8.4
Hardware: iPhone 5S
Original Bootstrap issue: https://github.com/twbs/bootstrap/issues/16988

To reproduce:
1. Open http://jsfiddle.net/cvrebert/cjn5n4z2/show/ in iOS Safari.
2. Tap into the text input.
3. Type in a long string of text, such that the start of the text has been pushed to far to the left that it's no longer visible.
4. Attempt to move the cursor towards the start of the text by long pressing within the input and then, without taking your finger off the touchscreen, moving your finger beyond the left edge of the text input field.

Expected result:
The text in the input should start moving to the right, so that eventually the beginning of the text is reached.

Actual result:
The text in the input does not start moving to the right.

--------
Copy of JS Fiddle testcase:

HTML:
<br /><br />
<input type="text" />

CSS:
input {
    /*ensure there's some empty space on both sides of the input*/
    position: relative;
    left: 33%;
    width: 33%;
}
Comment 1 Chris Rebert 2015-08-15 15:26:40 PDT
Also filed a Radar:
<rdar://problem/22299624>
Comment 3 Chris Rebert 2016-01-22 01:23:01 PST
<rdar://problem/19005092>
Comment 4 Chris Rebert 2016-02-18 23:18:12 PST
*** Bug 150260 has been marked as a duplicate of this bug. ***
Comment 5 sonderbazz 2017-03-28 04:03:00 PDT
How come this is not being taken seriously??
It's still a major issue. 
Tested on IOS 10.3.

Tested using google.com search input field....
Comment 6 OSREC 2017-06-06 09:51:52 PDT
Please can we try and sort this asap - it is quite a glaring bug and has caused a number of users a whole lot of pain... I really don't understand why this doesn't even have an assignee despite being reported 2 years ago?!!
Comment 7 Jaan Murumets 2017-06-06 13:05:55 PDT
We hit also to this bug, is there any known workaround?
Comment 8 Mikhail Menshikov 2017-06-26 09:25:14 PDT
Ran into this issue today. Very inconvenient and annoying behavior. Also my QA engineer insist it has to be fixed.
It's still an issue on Safari 10 / iPhone iOS 10.
Comment 9 Alexander Gro├čauer 2018-02-19 06:12:50 PST
I can't understand how it's possible that this major bug is still not fixed in iOS 11.2.5 after more than two years??

Is there a known workaround?
For example: convince the iOS keyboard to show arrow keys with a CSS property?
Comment 10 Wenson Hsieh 2018-02-19 07:36:11 PST
I think Megan fixed this on trunk after adding support for autoscrolling in editable elements (see <https://trac.webkit.org/changeset/226067/webkit> and <https://trac.webkit.org/changeset/228549/webkit>).
Comment 11 Megan Gardner 2018-02-19 11:59:12 PST
Wenson is correct! This is resolved on trunk and should be available in the current developer seed. Please test and verify with the latest seed

*** This bug has been marked as a duplicate of bug 180789 ***