Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(19)

Side by Side Diff: LayoutTests/fast/shapes/shape-outside-floats/shape-outside-clip-path-selection.html

Issue 240423005: [CSS Shapes] Can't select content within the area of the floating box when clip-path is applied (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Try to make test more stable Created 6 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
1 <style>
2 body {
3 width: 600px;
4 font: 18px/1 Ahem;
5 }
6
7 #background {
8 position: absolute;
9 top: 8px;
10 left: 8px;
11 z-index: -1;
12 width: 200px;
13 height: 200px;
14 background: lightgreen;
15 }
16
17 #triangleLeft {
18 width: 200px;
19 height: 200px;
20 float: left;
21 shape-outside: polygon(0 0, 100% 50%, 0 100%);
22 -webkit-clip-path: polygon(0 0, 100% 50%, 0 100%);
23 shape-margin: 4px;
24 background-color: yellow;
25 }
26 </style>
27
28 <div id="triangleLeft"></div>Although the Culture was originated by humanoid spe cies, subsequent interactions with other civilizations have introduced many non- humanoid species into the Culture (including some former enemy civilizations), t hough the majority of the biological Culture is still pan-human. Little uniformi ty exists in the Culture, and its citizens are such by choice, free to change ph ysical form and even species (though some stranger biological conversions are ir reversible, and conversion from biological to artificial sentience is considered to be what is known as an Unusual Life Choice). All members are also free to jo in, leave, and rejoin, or indeed declare themselves to be, say, 80% Culture.
29
30 <script src="../../../resources/js-test.js"></script>
31 <script>
32 var sel = window.getSelection();
33 sel.removeAllRanges();
34 // select part of the polygon, not the text
35 eventSender.mouseMoveTo(80, 100);
36 eventSender.mouseDown();
37 eventSender.mouseMoveTo(140, 100);
38 eventSender.mouseUp();
39 shouldBe('sel.toString()', '""');
40
41 // select 'other' using select drag.
42 sel.removeAllRanges();
43 eventSender.mouseMoveTo(80, 50);
44 eventSender.mouseDown();
45 eventSender.mouseMoveTo(260, 50);
46 eventSender.mouseUp();
47 // verify that 'other' was selected
48 shouldBe('sel.toString()', '"originated"');
49 </script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698