From 4525eb112b0d154204268b8c5a88263700191d02 Mon Sep 17 00:00:00 2001 From: Michael Howell Date: Thu, 17 Nov 2022 15:24:39 -0700 Subject: rustdoc: use `code-header` class to format enum variants The font size and weights should be exactly the same after this commit, but the spacing is changed to be exactly the same as methods. --- src/librustdoc/html/static/css/rustdoc.css | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) (limited to 'src/librustdoc/html/static/css/rustdoc.css') diff --git a/src/librustdoc/html/static/css/rustdoc.css b/src/librustdoc/html/static/css/rustdoc.css index 9b1cac85cfd..27ffd7682e9 100644 --- a/src/librustdoc/html/static/css/rustdoc.css +++ b/src/librustdoc/html/static/css/rustdoc.css @@ -709,8 +709,6 @@ a { } .small-section-header { - display: flex; - justify-content: space-between; position: relative; } @@ -718,7 +716,7 @@ a { display: initial; } -.impl:hover > .anchor, .trait-impl:hover > .anchor { +.impl:hover > .anchor, .trait-impl:hover > .anchor, .variant:hover > .anchor { display: inline-block; position: absolute; } @@ -1235,12 +1233,6 @@ a.test-arrow:hover { font-size: 1.25rem; } -h3.variant { - font-weight: 600; - font-size: 1.125rem; - margin-bottom: 10px; -} - .sub-variant h4 { font-size: 1rem; font-weight: 400; @@ -1909,6 +1901,7 @@ in storage.js } } +.variant, .implementors-toggle > summary, .impl, #implementors-list > .docblock, @@ -1920,6 +1913,7 @@ in storage.js margin-bottom: 0.75em; } +.variants > .docblock, .impl-items > .rustdoc-toggle[open]:not(:last-child), .methods > .rustdoc-toggle[open]:not(:last-child), .implementors-toggle[open]:not(:last-child) { -- cgit 1.4.1-3-g733a5