Create a Unicode progress bar.
(remaining: int, total: int, width: int = 30)
| 8 | |
| 9 | |
| 10 | def _create_progress_bar(remaining: int, total: int, width: int = 30) -> str: |
| 11 | """Create a Unicode progress bar.""" |
| 12 | if total == 0: |
| 13 | filled = 0 |
| 14 | else: |
| 15 | filled = int((remaining / total) * width) |
| 16 | |
| 17 | empty = width - filled |
| 18 | return "█" * filled + "░" * empty |
| 19 | |
| 20 | |
| 21 | def _display_credit_line(plan_credits: dict) -> None: |
no outgoing calls