Skip to content

Commit

Permalink
Debug
Browse files Browse the repository at this point in the history
  • Loading branch information
hoxbro committed Sep 12, 2024
1 parent 7746ecc commit ddbc31f
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
2 changes: 1 addition & 1 deletion holonote/annotate/annotator.py
Original file line number Diff line number Diff line change
Expand Up @@ -321,7 +321,7 @@ class Annotator(AnnotatorInterface):

groupby = param.Selector(default=None, doc="Groupby dimension", allow_refs=True)
visible = param.ListSelector(
default=[], doc="Visible dimensions, needs groupby enabled", allow_refs=True
default=None, doc="Visible dimensions, needs groupby enabled", allow_refs=True
)
style = param.ClassSelector(default=Style(), class_=Style, doc="Style parameters")

Expand Down
8 changes: 6 additions & 2 deletions holonote/annotate/display.py
Original file line number Diff line number Diff line change
Expand Up @@ -537,8 +537,12 @@ def static_indicators(self, **events):
msg = f"{self.region_format} not implemented"
raise NotImplementedError(msg)

if len(indicator.data) == 0 or not self.annotator.visible:
return hv.NdOverlay({0: self._make_empty_element()}).opts(show_legend=False)
if len(indicator.data) == 0 or (
self.annotator.groupby
and self.annotator.visible is not None
and not len(self.annotator.visible)
):
return hv.NdOverlay({0: self._make_empty_element()}) # .opts(show_legend=False)

if self.annotator.groupby and self.annotator.visible:
indicator = indicator.get(self.annotator.visible)
Expand Down

0 comments on commit ddbc31f

Please sign in to comment.