Self-hosted, Self-Improving, Federated Everything App — dev management, agent orchestration, persistent mind, digital twin, second brain, and creative pipeline from a single dashboard over Tailscale to port the user into the OS
JavaScript ai-agentsdashboarddeveloper-toolsdigital-twinquantified-selfsecond-brainself-hostedtailscale
stop an unmeasured quota window rendering as 0% used
[._.]/ Adam Eivy5e03f4d0bdcf
diff --git a/client/src/components/usage/UsageMeter.jsx b/client/src/components/usage/UsageMeter.jsxindex 8d4e752a50..e400e6ea97 100644--- a/client/src/components/usage/UsageMeter.jsx+++ b/client/src/components/usage/UsageMeter.jsx@@ -54,7 +54,12 @@ export default function UsageMeter({ limit }) {</div><ProgressBar percent={used} tone={meterTone(limit.percentUsed)} label={`${limit.label} quota used`} /><div className="flex flex-col sm:flex-row sm:items-start sm:justify-between gap-0.5 sm:gap-1 mt-0.5 sm:mt-1">- <span className="text-[9px] sm:text-xs text-gray-500">{used}% used</span>+ {/* An unread percentage reads '—', never '0% used' — the same rule the+ remainder beside it and meterTone already keep. A plan that may be+ fully spent must not render as untouched. */}+ <span className="text-[9px] sm:text-xs text-gray-500">+ {limit.percentUsed == null ? '—' : `${used}% used`}+ </span>{limit.resetsAt && (<span className="flex min-w-0 text-[9px] sm:text-xs text-gray-500 items-start sm:justify-end gap-1 sm:text-right leading-tight"><Clock size={11} className="shrink-0" /> resets {formatResetsAt(limit.resetsAt)}diff --git a/client/src/components/usage/UsageMeter.test.jsx b/client/src/components/usage/UsageMeter.test.jsxindex 4ded91b45e..ba6bf4b065 100644--- a/client/src/components/usage/UsageMeter.test.jsx+++ b/client/src/components/usage/UsageMeter.test.jsx@@ -46,4 +46,13 @@ describe('UsageMeter', () => {render(<UsageMeter limit={{ key: 'week', label: 'Weekly', percentUsed: 40, percentRemaining: null }} />);expect(screen.getByText('—')).toBeInTheDocument();});++ // An unmeasured window is not an untouched one. Rendering `0% used` for a+ // plan that may be fully spent is the same fabrication the remainder and the+ // meter tone already refuse.+ it('renders an unmeasured used share as unknown, never as 0%', () => {+ render(<UsageMeter limit={{ key: 'week', label: 'Weekly', percentUsed: null, percentRemaining: null }} />);+ expect(screen.queryByText('0% used')).not.toBeInTheDocument();+ expect(screen.getAllByText('—')).toHaveLength(2);+ });});