Registry / devops / sphinx-tippy

sphinx-tippy

JSON →
library0.4.3pypypi✓ verified 80d ago

sphinx-tippy is a Sphinx extension that enables rich tooltips for references and glossary terms using the Tippy.js library. Version 0.4.3 supports Python 3.8+ and integrates seamlessly with Sphinx documentation. It provides automatic tooltip generation for cross-references, glossaries, and custom directives, enhancing reader experience without requiring JavaScript expertise.

pip install sphinx-tippy
INSTALL
IMPORT
SIG · SPHINX-TIPPY
S
sphinx-tippy
devopspythonv0.4.3
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

TippyConfig
from sphinx_tippy import TippyConfig
from sphinx_tippy import tippy_extension
TippyData
from sphinx_tippy import TippyData
TippyPageData
from sphinx_tippy import TippyPageData

Add 'sphinx_tippy' to the extensions list in conf.py. Optional configuration: tippy_anchor_parent, tippy_max_width, tippy_theme, etc.

extensions = ['sphinx_tippy'] tippy_anchor_parent = 'content' # optional, default 'document' tippy_max_width = 300 # optional, default 350
Debug
Known issues
gotchaThe extension requires JavaScript; ensure your Sphinx theme does not block scripts (e.g., content_security_policy). Tooltips may not work in certain offline builds.
fix
If using a strict CSP, add 'unsafe-inline' for scripts or use a permissive config. For offline builds, consider using a local copy of Tippy.js assets.
affects: >=0.1.0
gotchaTooltips are not generated for references that are not resolved; unresolved references will have no tooltip. This can lead to inconsistent behavior if you have broken cross-references.
fix
Ensure all cross-references in your documentation are valid. Run 'make linkcheck' to find broken references.
affects: >=0.1.0
deprecatedThe configuration option 'tippy_theme' is deprecated in favor of 'tippy_theme_css' to allow custom CSS. Old theme names may stop working in future versions.
fix
Replace 'tippy_theme = ' with 'tippy_theme_css = ' and use a CSS class. See documentation for examples.
affects: >=0.4.0
Upgrade
Version history
0.4.3latest on PyPI · released Apr 23, 2024
Audit
Dependencies
sphinxrequiredCore requirement; sphinx-tippy is a Sphinx extension.
Agent activity
5 hits · last 30 days
node
4
Resources

No resource links recorded.

sphinx-tippy — pip install sphinx-tippy · libregistry