Skip to content

Commit

Permalink
Merge pull request #19 from Synthetixio/fix/many-charts
Browse files Browse the repository at this point in the history
Fix Many-type Charts
  • Loading branch information
Tburm authored Oct 17, 2024
2 parents c1f7906 + 02105fd commit 9acb139
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions dashboards/utils/charts.py
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,6 @@ def chart_many_bars(
color: Optional[str] = None,
x_format: str = "#",
y_format: str = "$",
help_text: Optional[str] = None,
):
"""Create a bar chart with multiple series."""
fig = px.bar(
Expand All @@ -151,7 +150,7 @@ def chart_many_bars(
fig.update_layout(
font=dict(family=FONT_FAMILY),
)
return update_layout(fig, help_text=help_text)
return fig


def chart_many_lines(
Expand All @@ -162,7 +161,6 @@ def chart_many_lines(
color: Optional[str] = None,
x_format: str = "#",
y_format: str = "$",
help_text: Optional[str] = None,
):
"""Create a line chart with multiple series."""
fig = px.line(
Expand All @@ -175,7 +173,7 @@ def chart_many_lines(
template=PLOTLY_TEMPLATE,
)
fig = set_axes(fig, x_format, y_format)
return update_layout(fig, help_text=help_text)
return fig


def chart_bars(
Expand Down

0 comments on commit 9acb139

Please sign in to comment.