diff --git a/src/app/(dashboard)/dashboard/usage/components/ProviderLimits/QuotaTable.js b/src/app/(dashboard)/dashboard/usage/components/ProviderLimits/QuotaTable.js index 299445ef..9f18e5d1 100644 --- a/src/app/(dashboard)/dashboard/usage/components/ProviderLimits/QuotaTable.js +++ b/src/app/(dashboard)/dashboard/usage/components/ProviderLimits/QuotaTable.js @@ -148,103 +148,100 @@ export default function QuotaTable({ )} -
- - - {currentPageRows.map((quota) => { - const colors = getColorClasses(quota.remaining); - const countdown = formatResetTime(quota.resetAt); - const resetDisplay = formatResetTimeDisplay(quota.resetAt); - // recurring defaults true: a missing flag means the quota - // refreshes at resetAt. Bonus/one-shot packs set recurring:false - // and their resetAt is a hard expiry, so word it as "expires". - const recurring = quota.recurring !== false; - const countdownLabel = recurring ? `in ${countdown}` : `expires in ${countdown}`; +
+ {currentPageRows.map((quota) => { + const colors = getColorClasses(quota.remaining); + const countdown = formatResetTime(quota.resetAt); + const resetDisplay = formatResetTimeDisplay(quota.resetAt); + // recurring defaults true: a missing flag means the quota + // refreshes at resetAt. Bonus/one-shot packs set recurring:false + // and their resetAt is a hard expiry, so word it as "expires". + const recurring = quota.recurring !== false; + const countdownLabel = recurring ? `in ${countdown}` : `expires in ${countdown}`; - return ( -
+ {/* Name */} +
+ {colors.emoji} + + {quota.name} + +
+ + {/* Progress + used/total */} +
+
+
+
+ +
+ 0 ? quota.total.toLocaleString() : "∞"}`} + > + {quota.used.toLocaleString()} / {quota.total > 0 ? quota.total.toLocaleString() : "∞"} + + + {quota.remaining}% + +
+
+ + {/* Reset time */} +
+ {countdown !== "-" || resetDisplay ? ( + compact ? ( +
+ {countdown !== "-" ? countdownLabel : resetDisplay} +
+ ) : ( +
+ {countdown !== "-" && ( +
+ {countdownLabel} +
+ )} + {resetDisplay && ( +
+ {resetDisplay} +
+ )} +
+ ) + ) : ( +
N/A
+ )} +
+ + {/* Hide action */} + {hasHideAction && ( +
- - - - - - {hasHideAction && ( - - )} - - ); - })} - -
-
- {colors.emoji} - - {quota.name} - -
-
-
-
-
-
- -
- - {quota.used.toLocaleString()} / {quota.total > 0 ? quota.total.toLocaleString() : "∞"} - - - {quota.remaining}% - -
-
-
- {countdown !== "-" || resetDisplay ? ( - compact ? ( -
- {countdown !== "-" ? countdownLabel : resetDisplay} -
- ) : ( -
- {countdown !== "-" && ( -
- {countdownLabel} -
- )} - {resetDisplay && ( -
- {resetDisplay} -
- )} -
- ) - ) : ( -
N/A
- )} -
- -
+ + visibility_off + + + )} +
+ ); + })} {totalPages > 1 && ( diff --git a/src/app/(dashboard)/dashboard/usage/components/ProviderLimits/index.js b/src/app/(dashboard)/dashboard/usage/components/ProviderLimits/index.js index b573272e..eb486cc0 100644 --- a/src/app/(dashboard)/dashboard/usage/components/ProviderLimits/index.js +++ b/src/app/(dashboard)/dashboard/usage/components/ProviderLimits/index.js @@ -1270,7 +1270,7 @@ export default function ProviderLimits() { visibility_off Hidden: -
+
{hiddenQuotaRows.map((quotaRow) => (