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

Can we tweak the background color of the tooltips #12

Open
pique-b opened this issue Jan 12, 2024 · 1 comment
Open

Can we tweak the background color of the tooltips #12

pique-b opened this issue Jan 12, 2024 · 1 comment

Comments

@pique-b
Copy link

pique-b commented Jan 12, 2024

I have been trying to adapt sphinx-hoverxref in my documnetation project, however not being able to test it in local system was quite limiting. Found the sphinx-tippy extension from a link to my question about the issue.

So far as basic tooltips are concerned, tippy seems to work. I was wondering if we can change the background color from the default (which comes out as black presently) to something lighter, preferably white. With a dark background some of the texts in the tip are obscured.

Check this image:

example_tip

Can you suggest a way around to do so in the present scheme of things?

If I may, there is another query:

The wikipedia tips are quite nice. However, I was wondering if we may do a similar thing with other sources, say an imdb page?

@ValMystletainn
Copy link
Contributor

You can do it by custom the css by yourself. see the guid given by the author in the important block

This package just add the javascript code from tippy.js, and the default theme provided by tippy.js is dark theme. Now the author not setting the theme in his/her invoking js code. So another solution is add a python readable config option named "theme", and pass it to the javascript code

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

No branches or pull requests

2 participants