Skip to content

armgit / dub

Public Imported from GitHub
0

The modern link attribution platform. Loved by world-class engineering teams at Twilio, Zillow, Jobber, Vercel, Raycast, and more.

Add same minimum for billing page

Tim Wilson48c2698bedbf
diff --git a/apps/web/app/app.dub.co/(dashboard)/[slug]/settings/billing/plan-usage.tsx b/apps/web/app/app.dub.co/(dashboard)/[slug]/settings/billing/plan-usage.tsx
index 87532735b6..e18a2b6e7f 100644
--- a/apps/web/app/app.dub.co/(dashboard)/[slug]/settings/billing/plan-usage.tsx
+++ b/apps/web/app/app.dub.co/(dashboard)/[slug]/settings/billing/plan-usage.tsx
@@ -270,7 +270,7 @@ function UsageTabCard({
warning && "from-neutral-900/10 via-red-500 to-red-600",
)}
style={{
- transform: `translateX(-${100 - Math.floor((usage / Math.max(0, usage, limit)) * 100)}%)`,
+ transform: `translateX(-${100 - Math.max(Math.floor((usage / Math.max(0, usage, limit)) * 100), usage === 0 ? 0 : 1)}%)`,
}}
/>
</div>