posit-dev / posit-dev/py-shiny
Tooltip inside popover doesn't work, throws error
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 1.8k
- Forks
- 135
- Avg merge
- 2d 18h
- Merged PRs (30d)
- 21
Description
When a tooltip is placed inside a popover element, a console error is thrown when the popover is displayed, and the tooltip doesn't show when hovering over the popover:
from shiny import App, ui
app_ui = ui.page_fluid(
ui.popover(
ui.input_action_button("btn", "A button", class_="mt-3"),
ui.tooltip("A popover", "A tooltip"),
id="btn_popover",
),
)
app = App(app_ui, server=None)
Uncaught TypeError: e is null
connectedCallback tooltip.ts:90
show tooltip.js:210
_enter tooltip.js:509
setTimeout handler*_setTimeout tooltip.js:530
_enter tooltip.js:507
toggle tooltip.js:167
_setListeners tooltip.js:450
i event-handler.js:98
Is there a fix or a workaround? I need to be able to show help information for my pop-up controls.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the issue with the provided Python app and inspect the tooltip.ts and tooltip.js frames named in the console trace, starting at connectedCallback. Done means displaying the popover causes no TypeError and the tooltip appears when hovering over the popover.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- frontend, web-dev
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100