Context menu item "copy" disabled when triple clicking on element inside shadow DOM
Reported by
eugenit...@gmail.com,
Jul 26 2016
|
|||||||||||||
Issue description
Chrome Version : 49.0.2623.0 (Developer Build) (64-bit)
URLs (if applicable) : NO
Other browsers tested:
FAIL 50.0.2661.8125 (64-bit version)
have tested this issue:
Safari: YES
Firefox: YES
IE: YES
What steps will reproduce the problem?
(1) Create file.html with following content:
<!DOCTYPE html>
<html>
<head>
<script>
var Proto = Object.create(HTMLElement.prototype);
Proto.createdCallback = function() {
// Attach a shadow root on the element.
var shadow = this.createShadowRoot();
// Fill it with text.
shadow.innerHTML = "<strong>Try:</strong> (1) triple click (2) right click (3) copy";
};
// Register custom element
document.registerElement('x-el', { prototype: Proto })
</script>
</head>
<body>
<div>
<x-el></x-el>
</div>
<div>
<x-el></x-el>
</div>
</body>
</html>
(2) Open file in browser
(3) Triple click on SECOND text line (for fast select content)
(4) Right click on selection
(5) Menu item "copy" is enabled
(6) Triple click on FIRST text line (for fast select content)
(7) Right click on selection
What is the expected result?
Menu item "copy" is enabled
What happens instead?
Menu item "copy" is disabled, CMD+C also does not work
Please provide any additional information below. Attach a screenshot if
possible.
(1) If you call in web console:
document.getSelection().type while:
first line selected, you get "Caret"
second line selected, you get "Range"
document.getSelection().toString() while:
first line selected, you get ""
second line selected, you get "Try: (1) triple click (2) right click (3) copy"
(2) System info in attachments
,
Jul 28 2016
Can reproduce with Mac Canary 54.0.2809.0
,
Jul 28 2016
xiaochengh@, could you work on this?
,
Jul 28 2016
Can repro with Version 54.0.2810.0 (64-bit) on ubuntu 14.04, the "copy" is also disabled on the right click menu. For Firefox, it displayed nothing when opening this file.
,
Oct 12 2016
,
Oct 12 2016
,
Dec 6 2016
Any progress?
,
Dec 7 2016
No...
,
Dec 12 2016
yosin@, could you have a chance to take a look?
,
Mar 15 2017
Remove Blink>DOM>Events
,
Mar 23 2017
,
May 26 2017
,
May 28 2018
This issue has been Available for over a year. If it's no longer important or seems unlikely to be fixed, please consider closing it out. If it is important, please re-triage the issue. Sorry for the inconvenience if the bug really should have been left as Available. For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
,
May 28 2018
OK, let's close it
,
May 29 2018
|
|||||||||||||
►
Sign in to add a comment |
|||||||||||||
Comment 1 by tkent@chromium.org
, Jul 26 2016Components: Blink>TextSelection Blink>WebComponents