diff --git a/frontend/src/lib/components/runs/RunsQueue.svelte b/frontend/src/lib/components/runs/RunsQueue.svelte
index 6967c92222..fd3688b848 100644
--- a/frontend/src/lib/components/runs/RunsQueue.svelte
+++ b/frontend/src/lib/components/runs/RunsQueue.svelte
@@ -22,6 +22,12 @@
onJobsWaiting,
onJobsSuspended
}: Props = $props()
+
+ function formatCount(count: number | undefined, limit: number = 99): string {
+ if (count === undefined || count === null) return '...'
+ if (count > limit) return `${limit}+`
+ return count.toFixed(0)
+ }
@@ -32,9 +38,10 @@
{#if queue_count && ($queue_count ?? 0) > 0}
- {queue_count ? ($queue_count ?? 0).toFixed(0) : '...'}
+ {formatCount($queue_count, 99)}
{/if}
@@ -54,9 +61,10 @@
0
- ? 'bg-yellow-500 text-white rounded-full w-6 h-6 flex center-center'
- : ''}>{queue_count ? ($queue_count ?? 0).toFixed(0) : '...'}
{formatCount($queue_count, 999)}