- {t('flowViz.totalRequests')}
+
+ {showVisibleMetrics ? t('flowViz.visibleTotalRequests') : t('flowViz.totalRequests')}
+
{totalRequests.toLocaleString()}
- {t('flowViz.accounts')}
+
+ {showVisibleMetrics ? t('flowViz.visibleAccounts') : t('flowViz.accounts')}
+
{accounts.length}
+ {showVisibleMetrics && hiddenPausedCount > 0 && (
+
+ {t('flowViz.excludingPausedAccounts', { count: hiddenPausedCount })}
+
+ )}
);
diff --git a/ui/src/lib/i18n.ts b/ui/src/lib/i18n.ts
index 72e73701..4d695cd7 100644
--- a/ui/src/lib/i18n.ts
+++ b/ui/src/lib/i18n.ts
@@ -673,6 +673,11 @@ const resources = {
backToProviders: 'Back to providers',
showDetails: 'Show Details',
hideDetails: 'Hide Details',
+ showPausedAccounts: 'Show Paused ({{count}})',
+ hidePausedAccounts: 'Hide Paused ({{count}})',
+ visibleTotalRequests: 'Visible Requests',
+ visibleAccounts: 'Visible Accounts',
+ excludingPausedAccounts: 'Excluding {{count}} paused',
resetLayout: 'Reset layout',
provider: 'Provider',
totalRequests: 'Total Requests',
@@ -1986,6 +1991,11 @@ const resources = {
backToProviders: '返回提供商',
showDetails: '显示详情',
hideDetails: '隐藏详情',
+ showPausedAccounts: '显示已暂停 ({{count}})',
+ hidePausedAccounts: '隐藏已暂停 ({{count}})',
+ visibleTotalRequests: '可见请求数',
+ visibleAccounts: '可见账号',
+ excludingPausedAccounts: '已排除 {{count}} 个已暂停',
resetLayout: '重置布局',
provider: '提供商',
totalRequests: '总请求数',
@@ -3345,6 +3355,11 @@ const resources = {
backToProviders: 'Quay lại nhà cung cấp',
showDetails: 'Hiển thị chi tiết',
hideDetails: 'Ẩn chi tiết',
+ showPausedAccounts: 'Hiện tạm dừng ({{count}})',
+ hidePausedAccounts: 'Ẩn tạm dừng ({{count}})',
+ visibleTotalRequests: 'Yêu cầu hiển thị',
+ visibleAccounts: 'Tài khoản hiển thị',
+ excludingPausedAccounts: 'Đang loại trừ {{count}} tài khoản tạm dừng',
resetLayout: 'Đặt lại bố cục',
provider: 'Nhà cung cấp',
totalRequests: 'Tổng số yêu cầu',
@@ -4729,6 +4744,11 @@ const resources = {
backToProviders: 'プロバイダーに戻る',
showDetails: '詳細を表示',
hideDetails: '詳細を隠す',
+ showPausedAccounts: '一時停止を表示 ({{count}})',
+ hidePausedAccounts: '一時停止を非表示 ({{count}})',
+ visibleTotalRequests: '表示中のリクエスト',
+ visibleAccounts: '表示中のアカウント',
+ excludingPausedAccounts: '一時停止 {{count}} 件を除外中',
resetLayout: 'レイアウトをリセット',
provider: 'プロバイダー',
totalRequests: '総リクエスト数',
diff --git a/ui/tests/unit/components/account/flow-viz/index.test.tsx b/ui/tests/unit/components/account/flow-viz/index.test.tsx
new file mode 100644
index 00000000..8cdb584d
--- /dev/null
+++ b/ui/tests/unit/components/account/flow-viz/index.test.tsx
@@ -0,0 +1,169 @@
+import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest';
+import { render, screen, userEvent } from '@tests/setup/test-utils';
+import { AccountFlowViz } from '@/components/account-flow-viz';
+import type { ProviderData } from '@/components/account/flow-viz/types';
+
+vi.mock(import('react-i18next'), async (importOriginal) => {
+ const actual = await importOriginal();
+
+ return {
+ ...actual,
+ useTranslation: () => ({
+ t: (key: string, options?: { count?: number }) => {
+ const translations: Record