[PR #96] [CLOSED] feat(quota): add provider-wide aggregate quota card #100

Closed
opened 2026-02-27 16:42:33 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/router-for-me/Cli-Proxy-API-Management-Center/pull/96
Author: @umbra2728
Created: 2/7/2026
Status: Closed

Base: mainHead: feature/provider-quota-analytics


📝 Commits (5)

  • ad56b7f feat(quota): add provider-wide aggregate quota card
  • bf63495 refactor(quota): address code review feedback
  • 9e767d9 fix(quota): account for aggregate card in grid pagination
  • a135174 fix(quota): render warning overlay via portal
  • 28ad8f8 Merge pull request #1 from kavore/feature/provider-quota-analytics

📊 Changes

10 files changed (+570 additions, -15 deletions)

View changed files

src/components/quota/QuotaAggregateCard.tsx (+251 -0)
📝 src/components/quota/QuotaSection.tsx (+26 -12)
📝 src/components/quota/index.ts (+1 -0)
📝 src/i18n/locales/en.json (+4 -1)
📝 src/i18n/locales/ru.json (+4 -1)
📝 src/i18n/locales/zh-CN.json (+4 -1)
📝 src/pages/QuotaPage.module.scss (+54 -0)
📝 src/types/quota.ts (+29 -0)
src/utils/quota/aggregation.ts (+196 -0)
📝 src/utils/quota/index.ts (+1 -0)

📄 Description

Summary

  • Add aggregate quota card showing average statistics across all credentials per provider
  • Calculate average remaining quota per model group
  • Display credential count badge and reset time range
  • Thicker border with provider-specific colors
  • Hide when only one credential exists
  • Show idle state before first refresh
  • Fix grid pagination to account for aggregate card (ensures proper 3x3 tiling)

Screenshots for UI changes

image image image image

Verification notes

  • npm run type-check passes
  • npm run lint — new files have no errors (existing warnings/errors are pre-existing)

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/router-for-me/Cli-Proxy-API-Management-Center/pull/96 **Author:** [@umbra2728](https://github.com/umbra2728) **Created:** 2/7/2026 **Status:** ❌ Closed **Base:** `main` ← **Head:** `feature/provider-quota-analytics` --- ### 📝 Commits (5) - [`ad56b7f`](https://github.com/router-for-me/Cli-Proxy-API-Management-Center/commit/ad56b7f3e435dde3e65357bf5cd8424d337bb241) feat(quota): add provider-wide aggregate quota card - [`bf63495`](https://github.com/router-for-me/Cli-Proxy-API-Management-Center/commit/bf63495e40eb7e941104835c26686608ee8aa03c) refactor(quota): address code review feedback - [`9e767d9`](https://github.com/router-for-me/Cli-Proxy-API-Management-Center/commit/9e767d9d30c6b32a91df51c281cbfb38e51cea47) fix(quota): account for aggregate card in grid pagination - [`a135174`](https://github.com/router-for-me/Cli-Proxy-API-Management-Center/commit/a1351746d8c1ac9f00e62afadf74d91789095285) fix(quota): render warning overlay via portal - [`28ad8f8`](https://github.com/router-for-me/Cli-Proxy-API-Management-Center/commit/28ad8f828ad8567b68adc63932e4546fbe32ccc1) Merge pull request #1 from kavore/feature/provider-quota-analytics ### 📊 Changes **10 files changed** (+570 additions, -15 deletions) <details> <summary>View changed files</summary> ➕ `src/components/quota/QuotaAggregateCard.tsx` (+251 -0) 📝 `src/components/quota/QuotaSection.tsx` (+26 -12) 📝 `src/components/quota/index.ts` (+1 -0) 📝 `src/i18n/locales/en.json` (+4 -1) 📝 `src/i18n/locales/ru.json` (+4 -1) 📝 `src/i18n/locales/zh-CN.json` (+4 -1) 📝 `src/pages/QuotaPage.module.scss` (+54 -0) 📝 `src/types/quota.ts` (+29 -0) ➕ `src/utils/quota/aggregation.ts` (+196 -0) 📝 `src/utils/quota/index.ts` (+1 -0) </details> ### 📄 Description ## Summary - Add aggregate quota card showing average statistics across all credentials per provider - Calculate average remaining quota per model group - Display credential count badge and reset time range - Thicker border with provider-specific colors - Hide when only one credential exists - Show idle state before first refresh - Fix grid pagination to account for aggregate card (ensures proper 3x3 tiling) ## Screenshots for UI changes <img width="1994" height="654" alt="image" src="https://github.com/user-attachments/assets/547b93d9-5908-4e17-8b6a-7efb5ae28c3d" /> <img width="1982" height="1048" alt="image" src="https://github.com/user-attachments/assets/bd7948ea-2838-4add-9792-2cf8a66d2170" /> <img width="2002" height="630" alt="image" src="https://github.com/user-attachments/assets/b5af5497-5700-4d9c-b12b-1d2a20e42259" /> <img width="1978" height="1432" alt="image" src="https://github.com/user-attachments/assets/1f0fb0ee-4808-4388-93f9-65f57f056710" /> ## Verification notes - `npm run type-check` ✅ passes - `npm run lint` — new files have no errors (existing warnings/errors are pre-existing) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-02-27 16:42:33 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/Cli-Proxy-API-Management-Center#100
No description provided.