New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 703807 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
NOT IN USE
Closed: May 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux , Windows , Mac
Pri: 2
Type: Bug



Sign in to add a comment

CSS counter in generated content can be selected

Reported by drbradt...@gmail.com, Mar 21 2017

Issue description

UserAgent: Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko) Chrome/57.0.2987.98 Safari/537.36

Steps to reproduce the problem:
1. Open the test.html file sent and select more than 1 line of text.

What is the expected behavior?
The line numbers wont be selected with the rest of the contenteditable

What went wrong?
The line numbers where selected even when you try user-select: none; and ::selection.

Did this work before? No 
 
Labels: Needs-Feedback
could you please provide the file.
Ya, sorry I could have sworn I added the file. -Looking further into this, it may be a webkit bug.
test.html
421 bytes View Download
Project Member

Comment 3 by sheriffbot@chromium.org, Mar 22 2017

Cc: nyerramilli@chromium.org
Labels: -Needs-Feedback
Thank you for providing more feedback. Adding requester "nyerramilli@chromium.org" to the cc list and removing "Needs-Feedback" label.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Labels: Needs-Milestone
Cc: sureshkumari@chromium.org
Components: Blink>CSS
Labels: -Pri-3 -Needs-Milestone M-60 OS-Linux OS-Mac OS-Windows Pri-2
Status: Untriaged (was: Unconfirmed)
Able to reproduce the issue on Windows-7,Mac-10.12.4 and Linux Ubuntu-14.04 using Chrome stable version 	58.0.3029.96 and canary 60.0.3091.0 with provided file in comment#2.
This is Non-regression issue, observed from M30 #30.0.1550.0 and marking it as untriaged to get more inputs from dev team.

Thanks.

Comment 6 by r...@opera.com, May 8 2017

Components: -Blink>CSS Blink>Layout
Owner: r...@opera.com
Status: Started (was: Untriaged)
Summary: CSS counter in generated content can be selected (was: CSS :before counter in contenteditables :before can be selected)
This is not related to editing. It's a general issue with selectability of counters in generated ::before/::after. Also, it looks like it's only a paint artifact.

edit.html
232 bytes View Download
Project Member

Comment 8 by bugdroid1@chromium.org, May 8 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/9d8a90f8a7f49c673bcd4e369efc84c62cc18285

commit 9d8a90f8a7f49c673bcd4e369efc84c62cc18285
Author: rune <rune@opera.com>
Date: Mon May 08 21:54:23 2017

Counters are always generated content and cannot be selected.

Copying selection across generated ::before/::after with counter() did
not copy the contents, but the counter content was painted as selected
as if it was.

LayoutTextFragment was already overriding the implementation of
CanBeSelectionLeaf() to skip generated content, but LayoutCounter
inherits from LayoutText which returns always true. Return false for
LayoutCounter as it is always generated content.

R=mstensho@opera.com
BUG= 703807 

Review-Url: https://codereview.chromium.org/2867083003
Cr-Commit-Position: refs/heads/master@{#470141}

[add] https://crrev.com/9d8a90f8a7f49c673bcd4e369efc84c62cc18285/third_party/WebKit/LayoutTests/paint/selection/text-selection-counter-expected.html
[add] https://crrev.com/9d8a90f8a7f49c673bcd4e369efc84c62cc18285/third_party/WebKit/LayoutTests/paint/selection/text-selection-counter.html
[modify] https://crrev.com/9d8a90f8a7f49c673bcd4e369efc84c62cc18285/third_party/WebKit/Source/core/layout/LayoutCounter.h

Comment 9 by r...@opera.com, May 8 2017

Status: Fixed (was: Started)
Labels: TE-Verified-60.0.3095.5 TE-Verified-M60
Tested this issue on Windows 7, mac 10.12.4 & Ubuntu 14.04 using chrome Dev#60.0.3095.5 as per html provided in comment#2 & comment#6.

Observed line numbers are not getting selected when we try to select the lines.As it is working as intended, adding TE Verified labels.

Please find the attached screen cast for reference.

Thanks..!!


703807.mp4
286 KB View Download

Sign in to add a comment