From 1c888d51f997cc9358ce4d3e09bf7cbf8e5bdae3 Mon Sep 17 00:00:00 2001 From: Eric Huss Date: Sat, 25 Aug 2018 14:15:49 -0700 Subject: [PATCH] rustdoc: Fix gap on section anchor symbol when hovering. Fixes #49485 for section headings. --- src/librustdoc/html/static/rustdoc.css | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/librustdoc/html/static/rustdoc.css b/src/librustdoc/html/static/rustdoc.css index 57a111daa8977..2e7fd22105c55 100644 --- a/src/librustdoc/html/static/rustdoc.css +++ b/src/librustdoc/html/static/rustdoc.css @@ -545,10 +545,8 @@ a { left: -5px; } .small-section-header > .anchor { - left: -20px; -} -.small-section-header > .anchor:not(.field) { left: -28px; + padding-right: 10px; /* avoid gap that causes hover to disappear */ } .anchor:before { content: '\2002\00a7\2002'; @@ -745,6 +743,7 @@ a.test-arrow:hover{ .section-header:hover a:before { position: absolute; left: -25px; + padding-right: 10px; /* avoid gap that causes hover to disappear */ content: '\2002\00a7\2002'; }