mirror of
https://github.com/rust-lang/rust.git
synced 2025-06-04 19:29:07 +00:00
Rollup merge of #78103 - GuillaumeGomez:rustdoc-book, r=jyn514
Add link to rustdoc book in rustdoc help popup Part of #75520. It looks like this:    r? @jyn514
This commit is contained in:
commit
cbcf8d4235
@ -2792,6 +2792,10 @@ function defocusSearchBar() {
|
|||||||
addClass(popup, "hidden");
|
addClass(popup, "hidden");
|
||||||
popup.id = "help";
|
popup.id = "help";
|
||||||
|
|
||||||
|
var book_info = document.createElement("span");
|
||||||
|
book_info.innerHTML = "You can find more information in \
|
||||||
|
<a href=\"https://doc.rust-lang.org/rustdoc/\">the rustdoc book</a>.";
|
||||||
|
|
||||||
var container = document.createElement("div");
|
var container = document.createElement("div");
|
||||||
var shortcuts = [
|
var shortcuts = [
|
||||||
["?", "Show this help dialog"],
|
["?", "Show this help dialog"],
|
||||||
@ -2825,6 +2829,7 @@ function defocusSearchBar() {
|
|||||||
addClass(div_infos, "infos");
|
addClass(div_infos, "infos");
|
||||||
div_infos.innerHTML = "<h2>Search Tricks</h2>" + infos;
|
div_infos.innerHTML = "<h2>Search Tricks</h2>" + infos;
|
||||||
|
|
||||||
|
container.appendChild(book_info);
|
||||||
container.appendChild(div_shortcuts);
|
container.appendChild(div_shortcuts);
|
||||||
container.appendChild(div_infos);
|
container.appendChild(div_infos);
|
||||||
|
|
||||||
|
@ -796,14 +796,22 @@ body.blur > :not(#help) {
|
|||||||
clear: left;
|
clear: left;
|
||||||
display: block;
|
display: block;
|
||||||
}
|
}
|
||||||
|
#help > div > span {
|
||||||
|
text-align: center;
|
||||||
|
display: block;
|
||||||
|
margin: 10px 0;
|
||||||
|
font-size: 18px;
|
||||||
|
border-bottom: 1px solid #ccc;
|
||||||
|
padding-bottom: 4px;
|
||||||
|
margin-bottom: 6px;
|
||||||
|
}
|
||||||
#help dd { margin: 5px 35px; }
|
#help dd { margin: 5px 35px; }
|
||||||
#help .infos { padding-left: 0; }
|
#help .infos { padding-left: 0; }
|
||||||
#help h1, #help h2 { margin-top: 0; }
|
#help h1, #help h2 { margin-top: 0; }
|
||||||
#help > div div {
|
#help > div div {
|
||||||
width: 50%;
|
width: 50%;
|
||||||
float: left;
|
float: left;
|
||||||
padding: 20px;
|
padding: 0 20px 20px 17px;;
|
||||||
padding-left: 17px;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.stab {
|
.stab {
|
||||||
|
@ -219,7 +219,8 @@ a {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.docblock:not(.type-decl) a:not(.srclink):not(.test-arrow),
|
.docblock:not(.type-decl) a:not(.srclink):not(.test-arrow),
|
||||||
.docblock-short a:not(.srclink):not(.test-arrow), .stability a {
|
.docblock-short a:not(.srclink):not(.test-arrow), .stability a,
|
||||||
|
#help a {
|
||||||
color: #39AFD7;
|
color: #39AFD7;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -275,6 +276,10 @@ a {
|
|||||||
border-radius: 4px;
|
border-radius: 4px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#help > div > span {
|
||||||
|
border-bottom-color: #5c6773;
|
||||||
|
}
|
||||||
|
|
||||||
.since {
|
.since {
|
||||||
color: grey;
|
color: grey;
|
||||||
}
|
}
|
||||||
|
@ -177,7 +177,8 @@ a {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.docblock:not(.type-decl) a:not(.srclink):not(.test-arrow),
|
.docblock:not(.type-decl) a:not(.srclink):not(.test-arrow),
|
||||||
.docblock-short a:not(.srclink):not(.test-arrow), .stability a {
|
.docblock-short a:not(.srclink):not(.test-arrow), .stability a,
|
||||||
|
#help a {
|
||||||
color: #D2991D;
|
color: #D2991D;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -231,6 +232,10 @@ a.test-arrow {
|
|||||||
border-color: #bfbfbf;
|
border-color: #bfbfbf;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#help > div > span {
|
||||||
|
border-bottom-color: #bfbfbf;
|
||||||
|
}
|
||||||
|
|
||||||
#help dt {
|
#help dt {
|
||||||
border-color: #bfbfbf;
|
border-color: #bfbfbf;
|
||||||
background: rgba(0,0,0,0);
|
background: rgba(0,0,0,0);
|
||||||
|
@ -175,7 +175,8 @@ a {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.docblock:not(.type-decl) a:not(.srclink):not(.test-arrow),
|
.docblock:not(.type-decl) a:not(.srclink):not(.test-arrow),
|
||||||
.docblock-short a:not(.srclink):not(.test-arrow), .stability a {
|
.docblock-short a:not(.srclink):not(.test-arrow), .stability a,
|
||||||
|
#help a {
|
||||||
color: #3873AD;
|
color: #3873AD;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -229,6 +230,10 @@ a.test-arrow {
|
|||||||
border-color: #bfbfbf;
|
border-color: #bfbfbf;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#help > div > span {
|
||||||
|
border-bottom-color: #bfbfbf;
|
||||||
|
}
|
||||||
|
|
||||||
.since {
|
.since {
|
||||||
color: grey;
|
color: grey;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user