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

Cleanup popup #6207

Merged
merged 8 commits into from
May 7, 2024
Merged
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions holoviews/plotting/bokeh/callbacks.py
Original file line number Diff line number Diff line change
Expand Up @@ -693,15 +693,15 @@ def _process_selection_event(self):
if popup is None:
if self._panel.visible:
self._panel.visible = False
if self._existing_popup and not self._existing_popup.visible:
self._existing_popup.visible = False
return

if event is not None:
position = self._get_position(event)
else:
position = None
popup_pane = panel(popup)
if not popup_pane.visible:
return

if not popup_pane.stylesheets:
self._panel.stylesheets = [
Expand All @@ -722,10 +722,9 @@ def _process_selection_event(self):
# meaning the popup has already been removed; we need to regenerate
if self._existing_popup and not self._existing_popup.visible:
if position:
self._panel.position = XY(**position)
self._existing_popup.visible = True
if self.plot.comm:
push_on_root(self.plot.root.ref['id'])
self._panel.position = XY(**position)
ahuang11 marked this conversation as resolved.
Show resolved Hide resolved
return

model = popup_pane.get_root(self.plot.document, self.plot.comm)
Expand Down