9router/src/shared/components
Dũng A Tô Ri A 4677a9139a
feat(usage): đặt mặc định period là Today khi mở dashboard/usage (#1141)
* feat(usage): add Today period option to Usage & Analytics

Bổ sung lựa chọn Today vào bộ lọc thời gian của trang Usage & Analytics
(trước đây chỉ có 24h, 7D, 30D, 60D).

Khác biệt với 24h:
- 24h: cuộn 24 giờ trước → hiện tại
- Today: cố định từ 00:00 hôm nay (giờ local) → hiện tại

Thay đổi:
- page.js, UsageStats.js: thêm option Today vào danh sách PERIODS,
  đổi grid mobile từ 4 cột sang 5 cột để fit option mới.
- api/usage/stats, api/usage/chart: cho phép giá trị period today.
- usageRepo.js:
  + getUsageStats: dùng nhánh live history khi period = today,
    cutoff lấy từ 00:00 hôm nay theo local time.
  + getChartData: thêm 24 bucket theo giờ từ 00:00 → 23:59 hôm nay.

* feat(usage): đặt mặc định period là Today khi mở dashboard/usage

Người dùng thường quan tâm usage trong ngày hôm nay nhiều hơn 7 ngày,
nên hiển thị Today ngay khi vừa mở trang để giảm 1 thao tác chuyển period.
Đồng bộ luôn fallback trong UsageStats để giữ nhất quán khi component
dùng standalone.
2026-05-15 09:16:02 +07:00
..
layouts Refactor global styles and enhance MITM functionality 2026-05-03 18:00:35 +07:00
AddCustomEmbeddingModal.js Enhance image and embedding provider support 2026-04-25 16:22:30 +07:00
Avatar.js Initial commit 2026-01-05 09:58:59 +07:00
Badge.js Refactor global styles and enhance MITM functionality 2026-05-03 18:00:35 +07:00
Button.js Refactor global styles and enhance MITM functionality 2026-05-03 18:00:35 +07:00
Card.js Refactor global styles and enhance MITM functionality 2026-05-03 18:00:35 +07:00
ChangelogModal.js Add marked package, update Qwen executor for OAuth handling, and enhance changelog styles 2026-04-17 12:15:10 +07:00
ComboFormModal.js feat(ui): add Done button to ModelSelectModal in combo creation (#1031) 2026-05-12 09:23:51 +07:00
CursorAuthModal.js fix: use better-sqlite3 for Cursor auto-import, drop sqlite3 CLI requirement (closes #395) (#411) 2026-03-27 10:45:11 +07:00
Drawer.js Refactor global styles and enhance MITM functionality 2026-05-03 18:00:35 +07:00
EditConnectionModal.js Squashed commit of the following: 2026-05-03 15:35:34 +07:00
Footer.js Initial commit 2026-01-05 09:58:59 +07:00
GitLabAuthModal.js feat: add GitLab Duo and CodeBuddy support, update observability settings 2026-03-30 11:28:07 +07:00
Header.js Fix 2026-05-12 09:54:58 +07:00
HeaderMenu.js Enhance error formatting to include low-level cause details, update HeaderMenu to use MenuItem component for better structure, and improve LanguageSwitcher to support controlled open state. Update subproject commit status. 2026-04-17 12:15:10 +07:00
IFlowCookieModal.js - Refines the overall structure of the CLI tools and MITM server functionalities. 2026-03-05 11:25:03 +07:00
index.js feat: Added McpMarketplaceModal to the CoworkToolCard for improved plugin management. 2026-05-09 10:15:38 +07:00
Input.js Refactor global styles and enhance MITM functionality 2026-05-03 18:00:35 +07:00
KiroAuthModal.js * feat(kiro): wire aws identity center device flow into provider oauth (#587) 2026-04-15 11:44:46 +07:00
KiroOAuthWrapper.js Added profile ARN handling in OAuth provider mapping and improved polling logic in OAuth modal for better user experience. 2026-03-06 00:21:27 +07:00
KiroSocialOAuthModal.js - Updated Kiro OAuth configuration 2026-01-27 11:35:28 +07:00
LanguageSwitcher.js Enhance error formatting to include low-level cause details, update HeaderMenu to use MenuItem component for better structure, and improve LanguageSwitcher to support controlled open state. Update subproject commit status. 2026-04-17 12:15:10 +07:00
Loading.js Refactor global styles and enhance MITM functionality 2026-05-03 18:00:35 +07:00
ManualConfigModal.js fix: add clipboard fallback for navigator.clipboard unavailable contexts (closes #696) (#699) 2026-04-22 10:12:55 +07:00
McpMarketplaceModal.js feat: Added McpMarketplaceModal to the CoworkToolCard for improved plugin management. 2026-05-09 10:15:38 +07:00
Modal.js Refactor global styles and enhance MITM functionality 2026-05-03 18:00:35 +07:00
ModelSelectModal.js feat(ui): add Done button to ModelSelectModal in combo creation (#1031) 2026-05-12 09:23:51 +07:00
NineRemoteButton.js Fix Model Price 2026-04-04 14:40:49 +07:00
NineRemotePromoModal.js Refactor global styles and enhance MITM functionality 2026-05-03 18:00:35 +07:00
NoAuthProxyCard.js Add Cloudflare AI provider support and enhance connection management 2026-04-28 11:07:39 +07:00
OAuthModal.js feat: add STT support, Gemini TTS, and expand usage tracking 2026-05-05 10:32:59 +07:00
Pagination.js fix: improve dropdown text readability in dark theme on usage page (#997) 2026-05-10 21:07:59 +07:00
PricingModal.js feat(ui): add cost tracking to usage dashboard and pricing settings 2026-01-09 17:49:59 +07:00
ProviderIcon.js fix(ui): restore provider assets and model availability endpoint (#367) 2026-03-23 09:16:10 +07:00
ProviderInfoCard.js Update version to 0.4.9, enhance README with Trendshift badge, and add new embedding models to providerModels.js. Refactor TTS handling to support additional providers and improve API key validation for media providers. 2026-04-29 11:34:39 +07:00
RequestLogger.js feat(db): migrate from lowdb to SQLite with repos pattern 2026-05-09 17:48:20 +07:00
SegmentedControl.js Refactor global styles and enhance MITM functionality 2026-05-03 18:00:35 +07:00
Select.js Refactor global styles and enhance MITM functionality 2026-05-03 18:00:35 +07:00
Sidebar.js chore: release v0.4.27 2026-05-09 22:48:07 +07:00
ThemeProvider.js Initial commit 2026-01-05 09:58:59 +07:00
ThemeToggle.js Refactor global styles and enhance MITM functionality 2026-05-03 18:00:35 +07:00
Toggle.js Refactor global styles and enhance MITM functionality 2026-05-03 18:00:35 +07:00
Tooltip.js feat(chat): Enhance bypass handling and introduce CC filter naming feature 2026-03-13 09:41:40 +07:00
UsageStats.js feat(usage): đặt mặc định period là Today khi mở dashboard/usage (#1141) 2026-05-15 09:16:02 +07:00