Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adds highlight color to linked anchors and changes the global highlight color to a lighter yellow #1170

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

nienn
Copy link
Contributor

@nienn nienn commented Jun 25, 2021

Related issues: #869, #810

Adds highlight color to linked anchors

Highlights any targeted dt and any h1 h2 h3 h4 or h5 that is a direct child of a targeted section by adding CSS styles to those elements.

Targeted anchor headers
HighlightedAnchorHeader

Targeted anchor dts
HighlightedAnchorDt1
HighlightedAnchorDt2



Changes the global highlight color to a lighter yellow

It also styles the .highlighted text to color: $text-color ( #404040 ).

Before
HighlightedText-before

After
HighlightedText-after

@Blendify
Copy link
Member

Blendify commented Aug 6, 2021

The lighter yellow is a nice change however, I find highlighting the whole section heading distracting.

Perhaps a better solution would just be to pulse/animate a highlight once. This would solve the UX issue while not being distracting

@nienn
Copy link
Contributor Author

nienn commented Aug 9, 2021

A pulse/animate highlight is a good solution for the linked anchors 👍

For search results (class .highlighted) I think it provides better user experience to leave the results highlighted.

@campellcl
Copy link

This would especially be nice for the Sphinx glossary directive as mentioned in #877!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants