New issue
Advanced search Search tips

Issue 882614 link

Starred by 4 users

Issue metadata

Status: Available
Owner: ----
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux , Windows , Mac
Pri: 2
Type: Bug



Sign in to add a comment

SelectionEnd in TextArea with newlines seems wrong when using Ctrl-A

Reported by alban.le...@gmail.com, Sep 10

Issue description

UserAgent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/69.0.3497.81 Safari/537.36

Steps to reproduce the problem:
See https://jsfiddle.net/b8ee0gnu/1190/
1. Type 'a'
2. Type <Shift-Return>
3. Type <Ctrl-A>

The selection after the keyup event is start=0, end=3

What is the expected behavior?
The expected behavior would be to get a selection equal to start=0, end=2

What went wrong?
The selection has the wrong value after using Ctrl-A when the Textarea has newlines

Did this work before? No 

Chrome version: 69.0.3497.81  Channel: stable
OS Version: 10.0
Flash Version: Flash disabled
 
Labels: Needs-Triage-M69
Cc: susan.boorgula@chromium.org
Labels: Triaged-ET Target-71 M-71 FoundIn-71 OS-Linux OS-Mac
Status: Untriaged (was: Unconfirmed)
alban.lefebvre@ Thanks for the issue.

Able to reproduce the issue on Windows 10, Mac OS 10.13.3 and Ubuntu 17.10 on the latest Stable 69.0.3497.81 and the latest Canary 71.0.3548.0.
Cannot observe the correct keyup event values equal to start=0, end=2 after following the steps mentioned above.
Attached is the screen shot for reference.

This is a Non-Regression issue as this is observed from M-60 chrome builds.
Hence marking this as Untriaged for further updates from Dev.

Thanks..
882614-M60.PNG
109 KB View Download
Components: -Blink Blink>Editing>Selection
Components: -Blink>Editing>Selection Blink>Forms>Textarea
Route to Blink>Forms>Textarea since it seems this is an issue of calculating HTMLTextFromElement's selection offset from FrameSelection.
Status: Available (was: Untriaged)
It seems "PlaceholderBreakElement" is included in the selection, and counted as 1.

Sign in to add a comment