Skip to content

Commit 1465483

Browse files
committed
doc: slight design refresh
1 parent 2216001 commit 1465483

File tree

2 files changed

+35
-20
lines changed

2 files changed

+35
-20
lines changed

src/doc/favicon.inc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,3 @@
11
<link rel="shortcut icon" href="http://www.rust-lang.org/favicon.ico">
2+
<link href='http://fonts.googleapis.com/css?family=Source+Code+Pro:400'
3+
rel='stylesheet' type='text/css'>

src/doc/rust.css

Lines changed: 33 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -40,8 +40,15 @@
4040
font-weight: 700;
4141
src: local('Heuristica Bold'), url("http://www.rust-lang.org/fonts/Heuristica-Bold.woff") format('woff');
4242
}
43-
/* Global page semantics
44-
========================================================================== */
43+
44+
* {
45+
-webkit-box-sizing: border-box;
46+
-moz-box-sizing: border-box;
47+
box-sizing: border-box;
48+
}
49+
50+
/* General structure */
51+
4552
body {
4653
margin: 0 auto;
4754
padding: 0 15px;
@@ -157,8 +164,8 @@ footer {
157164
margin-bottom: 1em;
158165
}
159166

160-
/* Links layout
161-
========================================================================== */
167+
/* Links layout */
168+
162169
a {
163170
text-decoration: none;
164171
color: #428BCA;
@@ -183,18 +190,17 @@ h5 a:link, h5 a:visited {color: black;}
183190
h1 a:hover, h2 a:hover, h3 a:hover, h4 a:hover,
184191
h5 a:hover {text-decoration: none;}
185192

186-
/* Code
187-
========================================================================== */
193+
/* Code */
194+
188195
pre, code {
189-
font-family: Menlo, Monaco, Consolas, "DejaVu Sans Mono", monospace;
190-
border-radius: 4px;
196+
font-family: "Source Code Pro", Menlo, Monaco, Consolas, "DejaVu Sans Mono", monospace;
191197
}
192198
pre {
193-
background-color: #FDFDFD;
194-
border: 1px solid #CCC;
195-
border-radius: 0.5em;
199+
border-left: 2px solid #eee;
200+
border-radius: 0;
196201
white-space: pre-wrap;
197-
padding: 9.5px;
202+
padding: 14px;
203+
padding-right: 0;
198204
margin: 20px 0;
199205
font-size: 13px;
200206
word-break: break-all;
@@ -211,7 +217,6 @@ pre code {
211217
color: inherit;
212218
white-space: pre-wrap;
213219
background-color: transparent;
214-
border-radius: 0;
215220
}
216221

217222
/* Code highlighting */
@@ -225,16 +230,16 @@ pre.rust .doccomment { color: #4D4D4C; }
225230
pre.rust .macro, pre.rust .macro-nonterminal { color: #3E999F; }
226231
pre.rust .lifetime { color: #B76514; }
227232

233+
/* The rest */
228234

229-
/* The rest
230-
========================================================================== */
231235
#versioninfo {
232236
text-align: center;
233237
margin: 0.5em;
234238
font-size: 1.1em;
235239
}
236-
@media only screen and (min-width: 768px) {
240+
@media (min-width: 768px) {
237241
#versioninfo {
242+
font-size: 0.8em;
238243
position: fixed;
239244
bottom: 0px;
240245
right: 0px;
@@ -252,10 +257,12 @@ pre.rust .lifetime { color: #B76514; }
252257
}
253258

254259
blockquote {
255-
color: black;
256-
border-left: 5px solid #eee;
257-
margin: 0 0 20px;
258-
padding: 10px 20px;
260+
color: #000;
261+
margin: 20px 0;
262+
padding: 15px 20px;
263+
background-color: #f2f7f9;
264+
border-top: .1em solid #e5eef2;
265+
border-bottom: .1em solid #e5eef2;
259266
}
260267
blockquote p {
261268
font-size: 17px;
@@ -319,6 +326,12 @@ table th {
319326
padding: 5px;
320327
}
321328

329+
@media (min-width: 1170px) {
330+
pre {
331+
font-size: 15px;
332+
}
333+
}
334+
322335
@media print {
323336
* {
324337
text-shadow: none !important;

0 commit comments

Comments
 (0)