+def _make_bar_graph_text(text: BarGraphText, current: int, total: int, percentage: float):
+ if text == BarGraphText.NONE:
+ return ""
+ elif text == BarGraphText.PERCENTAGE:
+ return f'{percentage:.1f}'
+ elif text == BarGraphText.FRACTION:
+ return f'{current} / {total}'
+ raise ValueError(text)
+
+
+def bar_graph_string(
+ current: int,
+ total: int,