forked from huijing/slides
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path06-florence.html
158 lines (130 loc) · 3.18 KB
/
06-florence.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>cmd7 - Variable sizing</title>
<meta name="description" content="">
<meta name="author" content="Chen Hui Jing">
<style>
@font-face {
font-family: 'Volkhov';
src: url("fonts/volkhov-regular.woff2") format("woff2"), url("fonts/volkhov-regular.woff") format("woff");
font-weight: normal;
font-style: normal;
}
@font-face {
font-family: 'Volkhov';
src: url("fonts/volkhov-bold.woff2") format("woff2"), url("fonts/volkhov-bold.woff") format("woff");
font-weight: 700;
font-style: normal;
}
body {
font-family: "Volkhov", Georgia, serif;
font-size: calc(1em + 0.5vw);
min-width: 20em;
}
div {
margin-bottom: 1em;
}
h1 {
font-size: 2em;
font-weight: bold;
background-color: rgba(255, 255, 255, 0.5);
margin: 0.5em 0;
padding: 0.25em;
line-height: 1.1;
}
p {
line-height: 1.3;
}
img {
max-width: 100%;
}
hr {
margin: 2em 0;
}
.float {
overflow: hidden;
}
.float img {
float: left;
width: 65%;
}
.float h1 {
float: right;
width: 55%;
margin-top: -3em;
}
.float p {
float: right;
width: 55%;
}
.grid {
display: grid;
grid-template-columns: fit-content(55%) minmax(15em, 20%) auto;
grid-template-rows: 1fr min-content auto;
}
.grid img {
grid-row: 1 / 3;
grid-column: 1 / 3;
}
.grid h1 {
grid-row: 2;
grid-column: 2 / 4;
}
.grid p {
grid-row: 3;
grid-column: 2 / 4;
}
input[type=checkbox] ~ label {
position: absolute;
right: 0;
top: 0;
width: 3em;
height: 3em;
z-index: 1;
cursor: pointer;
}
input[type=checkbox] {
position: absolute;
opacity: 0;
z-index: -1;
}
input[type=checkbox]:checked ~ .float {
display: none;
}
.twitter {
position: fixed;
top: 0.5rem;
right: 0.5rem;
color: darkgreen;
writing-mode: vertical-rl;
mix-blend-mode: difference;
opacity: 0.6;
font-size: initial;
margin: 0;
}
</style>
<!--[if lt IE 9]>
<script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
</head>
<body>
<input type="checkbox" id="toggle">
<label for="toggle"></label>
<div class="float">
<img src="img/florence.jpg" srcset="img/[email protected] 2x" alt="Florence and the Machine, live at Austin City Limits Festival">
<h1>The Liberation of Florence Welch</h1>
<p>How Florence and the Machine singer overcame personal demons to write her first-ever Number One album and bring it on the road for her biggest tour yet</p>
</div>
<hr class="float">
<div class="grid">
<img src="img/florence.jpg" srcset="img/[email protected] 2x" alt="Florence and the Machine, live at Austin City Limits Festival">
<h1>The Liberation of Florence Welch</h1>
<p>How Florence and the Machine singer overcame personal demons to write her first-ever Number One album and bring it on the road for her biggest tour yet</p>
</div>
<p class="twitter">@hj_chen</p>
</body>
</html>