Rollup merge of #76126 - camelid:crate-list-font, r=GuillaumeGomez
Use "Fira Sans" for crate list font Fira Sans is what's used for module lists and other item lists. Previously, the default body font, "Source Serif Pro", was used for crate lists, which didn't visually match other item lists. @rustbot modify labels: T-rustdoc
This commit is contained in:
commit
9a055826f9
@ -1062,12 +1062,13 @@ fn to_json_string(&self) -> String {
|
|||||||
let content = format!(
|
let content = format!(
|
||||||
"<h1 class='fqn'>\
|
"<h1 class='fqn'>\
|
||||||
<span class='in-band'>List of all crates</span>\
|
<span class='in-band'>List of all crates</span>\
|
||||||
</h1><ul class='mod'>{}</ul>",
|
</h1>\
|
||||||
|
<ul class='crate mod'>{}</ul>",
|
||||||
krates
|
krates
|
||||||
.iter()
|
.iter()
|
||||||
.map(|s| {
|
.map(|s| {
|
||||||
format!(
|
format!(
|
||||||
"<li><a class=\"mod\" href=\"{}index.html\">{}</a></li>",
|
"<li><a class=\"crate mod\" href=\"{}index.html\">{}</a></li>",
|
||||||
ensure_trailing_slash(s),
|
ensure_trailing_slash(s),
|
||||||
s
|
s
|
||||||
)
|
)
|
||||||
|
@ -178,6 +178,9 @@ pre {
|
|||||||
.content span.externcrate, .content span.mod, .content a.mod {
|
.content span.externcrate, .content span.mod, .content a.mod {
|
||||||
color: #acccf9;
|
color: #acccf9;
|
||||||
}
|
}
|
||||||
|
.content ul.crate a.crate {
|
||||||
|
font: 16px/1.6 "Fira Sans";
|
||||||
|
}
|
||||||
.content span.struct, .content a.struct {
|
.content span.struct, .content a.struct {
|
||||||
color: #ffa0a5;
|
color: #ffa0a5;
|
||||||
}
|
}
|
||||||
|
@ -6,6 +6,6 @@
|
|||||||
|
|
||||||
// @has foo/../index.html
|
// @has foo/../index.html
|
||||||
// @has - '//span[@class="in-band"]' 'List of all crates'
|
// @has - '//span[@class="in-band"]' 'List of all crates'
|
||||||
// @has - '//ul[@class="mod"]//a[@href="foo/index.html"]' 'foo'
|
// @has - '//ul[@class="crate mod"]//a[@href="foo/index.html"]' 'foo'
|
||||||
// @has - '//ul[@class="mod"]//a[@href="all_item_types/index.html"]' 'all_item_types'
|
// @has - '//ul[@class="crate mod"]//a[@href="all_item_types/index.html"]' 'all_item_types'
|
||||||
pub struct Foo;
|
pub struct Foo;
|
||||||
|
Loading…
Reference in New Issue
Block a user