Skip to content

Commit e3768f4

Browse files
estelleteoli2003
andauthored
New example: generated content (mdn#151)
* New example: generated content * New example: generated content * Update modules/generated_content.html --------- Co-authored-by: Jean-Yves Perrier <jypenator@gmail.com>
1 parent 3d66056 commit e3768f4

File tree

1 file changed

+61
-0
lines changed

1 file changed

+61
-0
lines changed

modules/generated_content.html

Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
<!DOCTYPE html>
2+
<html lang="en-us">
3+
<head>
4+
<meta charset="utf-8" />
5+
<meta name="viewport" content="width=device-width" />
6+
<title>Generated content</title>
7+
<style>
8+
body {
9+
background-image: linear-gradient(#3a67ab, #e8f6ff 100%); height: 100vh;
10+
width: 100vw;
11+
}
12+
13+
div {
14+
position: absolute;
15+
right: 0;
16+
bottom: 0;
17+
width: 400px;
18+
height: 400px;
19+
background-image:
20+
linear-gradient(115deg, transparent 48%, brown, #996600, brown, transparent 52%),
21+
linear-gradient(60deg, transparent 48%, brown, #996600, brown, transparent 52%),
22+
radial-gradient(circle 10px at 50% 50%, #333333 30%, #999999 50%, transparent 50%),
23+
radial-gradient(circle 10px at 50% 50%, #333333 30%, #999999 50%, transparent 50%),
24+
radial-gradient(circle at 50% 50%, white 30%, #eeeeee 50%, transparent 50%),
25+
radial-gradient(circle at 50% 50%, white 30%, #eeeeee 50%, transparent 50%),
26+
radial-gradient(circle at 50% 50%, white 30%, #eeeeee 50%, transparent 50%);
27+
background-repeat: no-repeat;
28+
background-size:
29+
100px 100px, 100px 100px,
30+
15px 15px, 15px 15px,
31+
200px 200px, 300px 300px, 400px 400px;
32+
background-position:
33+
95% 120px, 5% 120px,
34+
46% 80px, 54% 80px,
35+
50% 0, 50% 90px, 50% 220px;
36+
}
37+
38+
div::after {
39+
content: "";
40+
border: transparent solid 4px;
41+
border-left: orange 30px solid;
42+
height: 1px;
43+
width: 1px;
44+
position: absolute;
45+
left: 50%;
46+
top: 100px;
47+
}
48+
49+
div::before {
50+
content: "Only one <div>";
51+
font-size: min(6vh, 2rem);
52+
justify-content: center;
53+
display: flex;
54+
font-family: comic-sans, papyrus, sans-serif;
55+
}
56+
</style>
57+
</head>
58+
<body>
59+
<div></div>
60+
</body>
61+
</html>

0 commit comments

Comments
 (0)