Don't show hover text on sleep pattern bars

This commit is contained in:
Christopher C. Wells 2021-08-28 13:30:36 -07:00
parent 4de006783e
commit fb16cdb676
1 changed files with 4 additions and 2 deletions

View File

@ -119,10 +119,12 @@ def sleep_pattern(instances):
traces.append(go.Bar( traces.append(go.Bar(
x=dates, x=dates,
y=list(y.values()), y=list(y.values()),
text=list(text.values()), hovertext=list(text.values()),
# `hoverinfo` is deprecated but if we use the new `hovertemplate`
# the "filler" areas for awake time get a hover that says "null" and
# there is no way to prevent this currently with Plotly.
hoverinfo='text', hoverinfo='text',
marker={'color': color}, marker={'color': color},
marker_line_width=0,
showlegend=False, showlegend=False,
)) ))
if color == 'rgba(255, 255, 255, 0)': if color == 'rgba(255, 255, 255, 0)':