Skip to content

Commit b72f190

Browse files
committed
Extract styles into stylesheet.
1 parent 0e50388 commit b72f190

2 files changed

Lines changed: 68 additions & 70 deletions

File tree

index.html

Lines changed: 1 addition & 70 deletions
Original file line numberDiff line numberDiff line change
@@ -12,76 +12,7 @@
1212
<meta name="theme-color" content="#ffd675">
1313

1414
<link rel="shortcut icon" href="https://rhai.rs/book/favicon.png">
15-
16-
<style>
17-
* {
18-
margin: 0;
19-
padding: 0;
20-
box-sizing: border-box;
21-
font-family: sans-serif;
22-
}
23-
24-
body {
25-
/* Gradient from logo */
26-
background: #f67501;
27-
background: linear-gradient(180deg, #ffd675 0%, #f67501 100%);
28-
}
29-
30-
.center {
31-
margin: 1rem;
32-
min-height: calc(100vh - 2rem);
33-
display: flex;
34-
justify-content: center;
35-
align-items: center;
36-
text-align: center;
37-
}
38-
39-
main {
40-
max-width: 42rem;
41-
padding: 1rem;
42-
background: white;
43-
border-radius: 0.5rem;
44-
line-height: 1.5rem;
45-
}
46-
47-
.space-lg {
48-
margin-top: 1.5rem;
49-
}
50-
51-
.space-sm {
52-
margin-top: 0.5rem;
53-
}
54-
55-
.logo {
56-
display: block;
57-
max-width: 50%;
58-
margin: 0 auto;
59-
}
60-
61-
.icon {
62-
height: 1.25rem;
63-
display: inline-block;
64-
vertical-align: bottom;
65-
margin-right: 0.1rem;
66-
}
67-
68-
a {
69-
text-decoration: none;
70-
}
71-
72-
a:hover {
73-
text-decoration: underline;
74-
}
75-
76-
h1 {
77-
font-size: 1.3rem;
78-
}
79-
80-
.item {
81-
display: inline-block;
82-
margin: 0.2rem 0.25rem;
83-
}
84-
</style>
15+
<link rel="stylesheet" type="text/css" href="styles.css" />
8516
</head>
8617

8718
<body>

styles.css

Lines changed: 67 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
* {
2+
margin: 0;
3+
padding: 0;
4+
box-sizing: border-box;
5+
font-family: sans-serif;
6+
}
7+
8+
body {
9+
/* Gradient from logo */
10+
background: #f67501;
11+
background: linear-gradient(180deg, #ffd675 0%, #f67501 100%);
12+
}
13+
14+
.center {
15+
margin: 1rem;
16+
min-height: calc(100vh - 2rem);
17+
display: flex;
18+
justify-content: center;
19+
align-items: center;
20+
text-align: center;
21+
}
22+
23+
main {
24+
max-width: 42rem;
25+
padding: 1rem;
26+
background: white;
27+
border-radius: 0.5rem;
28+
line-height: 1.5rem;
29+
}
30+
31+
.space-lg {
32+
margin-top: 1.5rem;
33+
}
34+
35+
.space-sm {
36+
margin-top: 0.5rem;
37+
}
38+
39+
.logo {
40+
display: block;
41+
max-width: 50%;
42+
margin: 0 auto;
43+
}
44+
45+
.icon {
46+
height: 1.25rem;
47+
display: inline-block;
48+
vertical-align: bottom;
49+
margin-right: 0.1rem;
50+
}
51+
52+
a {
53+
text-decoration: none;
54+
}
55+
56+
a:hover {
57+
text-decoration: underline;
58+
}
59+
60+
h1 {
61+
font-size: 1.3rem;
62+
}
63+
64+
.item {
65+
display: inline-block;
66+
margin: 0.2rem 0.25rem;
67+
}

0 commit comments

Comments
 (0)