OLD | NEW |
| (Empty) |
1 <!DOCTYPE html> | |
2 <html> | |
3 <head> | |
4 <style> | |
5 .shape-inside { | |
6 width: 200px; | |
7 height: 300px; | |
8 shape-inside: polygon(10px 15px, 180px 15px, 180px 295px, 10px 295px); | |
9 position: relative; | |
10 } | |
11 .rl { -webkit-writing-mode: vertical-rl; } | |
12 .lr { -webkit-writing-mode: vertical-lr; } | |
13 .border { | |
14 position: absolute; | |
15 top: 13px; | |
16 left: 8px; | |
17 width: 170px; | |
18 height: 280px; | |
19 border: 2px solid blue; | |
20 } | |
21 p { -webkit-margin-before: 0; } | |
22 </style> | |
23 </head> | |
24 <body> | |
25 <div class="shape-inside rl"> | |
26 <div class="border"></div> | |
27 <div> | |
28 <p>Paragraph 1. This paragraph should start at the top right corner
of the blue | |
29 rectangle. Its top and bottom edges should be within the blue rectan
gle. | |
30 </div> | |
31 <p>Paragraph 2. This paragraph should be to the left of paragraph 1. Its
top | |
32 and bottom edges should also be within the blue rectangle. | |
33 </div> | |
34 <div class="shape-inside lr"> | |
35 <div class="border"></div> | |
36 <div> | |
37 <p>Paragraph 1. This paragraph should start at the top left corner o
f the blue | |
38 rectangle. Its top and bottom edges should be within the blue rectan
gle. | |
39 </div> | |
40 <p>Paragraph 2. This paragraph should be to the right of paragraph 1. It
s top | |
41 and bottom edges should also be within the blue rectangle. | |
42 </div> | |
43 </body> | |
44 </html> | |
OLD | NEW |