Skip to content

Commit

Permalink
Remove Extra Padding on Highlighted search results (readthedocs#860)
Browse files Browse the repository at this point in the history
* Remove Extra Padding on Highlighted search results

There are some cases where the highlighted CSS class creates overlapping text, for example on [Rendering » Shader Nodes » Texture](https://docs.blender.org/manual/en/dev/render/shader_nodes/textures/index.html?highlight=texture) when highlighting "texture". 

This issue is exacerbated by some custom styling rules that we have set, however, this issue is still visible in the stock theme.

* Address Review Comments

- Use constant instead of a magic number
- Remove Padding
  • Loading branch information
Blendify committed Apr 6, 2020
1 parent fd6f31f commit 3503493
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/sass/_theme_rst.sass
Original file line number Diff line number Diff line change
Expand Up @@ -223,9 +223,9 @@
// Sphinx can highlight searched text with ?highlighted=searchterm
.highlighted
background: $highlight-color
display: inline-block
box-shadow: 0 0 0 $base-line-height / 12 $highlight-color
display: inline
font-weight: bold
padding: 0 $base-line-height / 4

// These are the little citation links [1] that show up within paragraphs.
.footnote-reference, .citation-reference
Expand Down

0 comments on commit 3503493

Please sign in to comment.