From 837098798bb5d17008416a085bfc81870b09f27f Mon Sep 17 00:00:00 2001 From: Michael Howell Date: Sun, 25 Aug 2024 08:23:08 -0700 Subject: [PATCH] Make the help button look more like the rest --- src/librustdoc/html/sources.rs | 4 +++- src/librustdoc/html/static/css/rustdoc.css | 7 ++++--- src/librustdoc/html/static/js/search.js | 3 ++- 3 files changed, 9 insertions(+), 5 deletions(-) diff --git a/src/librustdoc/html/sources.rs b/src/librustdoc/html/sources.rs index 8156478104ec..5f3f0254f0b4 100644 --- a/src/librustdoc/html/sources.rs +++ b/src/librustdoc/html/sources.rs @@ -346,5 +346,7 @@ pub(crate) fn print_src( } else { None }, - }.render_into(&mut writer).unwrap(); + } + .render_into(&mut writer) + .unwrap(); } diff --git a/src/librustdoc/html/static/css/rustdoc.css b/src/librustdoc/html/static/css/rustdoc.css index b966a0253dac..40881eed5593 100644 --- a/src/librustdoc/html/static/css/rustdoc.css +++ b/src/librustdoc/html/static/css/rustdoc.css @@ -1754,6 +1754,7 @@ a.tooltip:hover::after { width: 80px; } #sidebar-button > a { + background-color: var(--button-background-color); border-color: var(--border-color); width: 33px; } @@ -1800,7 +1801,7 @@ button#toggle-all-docs:before { /* Question mark with circle */ content: url('data:image/svg+xml,\ - \ + \ ?'); width: 18px; height: 18px; @@ -1833,7 +1834,7 @@ rustdoc-toolbar span.label { /* sidebar resizer image */ content: url('data:image/svg+xml,\ - \ + \ \ '); width: 22px; @@ -2232,7 +2233,7 @@ in src-script.js and main.js #sidebar-button > a:before { content: url('data:image/svg+xml,\ - \ + \ \ '); width: 22px; diff --git a/src/librustdoc/html/static/js/search.js b/src/librustdoc/html/static/js/search.js index 56adb52a69b5..5133edc0e19e 100644 --- a/src/librustdoc/html/static/js/search.js +++ b/src/librustdoc/html/static/js/search.js @@ -2817,7 +2817,8 @@ ${item.displayPath}${name}\ crates += ""; } - let output = `

Results${crates}

`; + let output = `
\ +

Results${crates}

`; if (results.query.error !== null) { const error = results.query.error; error.forEach((value, index) => {