diff --git a/client/src/components/Nav/SettingsTabs/Data/Import/Progress.tsx b/client/src/components/Nav/SettingsTabs/Data/Import/Progress.tsx
index 53c1807e42..114f9b5fff 100644
--- a/client/src/components/Nav/SettingsTabs/Data/Import/Progress.tsx
+++ b/client/src/components/Nav/SettingsTabs/Data/Import/Progress.tsx
@@ -62,14 +62,14 @@ export default function Progress({ job, onCancel, onReset, isCancelling }: Progr
<>
{localize('com_ui_import_report', {
- count: job.report.imported,
- skipped: job.report.skipped,
+ 0: job.report.imported,
+ 1: job.report.skipped,
})}
{localize('com_ui_import_report_assets', {
- count: job.report.assetsImported,
- unavailable: job.report.assetsUnavailable,
+ 0: job.report.assetsImported,
+ 1: job.report.assetsUnavailable,
})}
>
@@ -116,7 +116,7 @@ export default function Progress({ job, onCancel, onReset, isCancelling }: Progr
{isTerminal && job.report && job.report.errors.length > 0 && (
- {localize('com_ui_import_errors', { count: job.report.errors.length })}
+ {localize('com_ui_import_errors', { 0: job.report.errors.length })}
{job.report.errors.map((error, index) => (
diff --git a/client/src/components/Nav/SettingsTabs/Data/Import/Summary.tsx b/client/src/components/Nav/SettingsTabs/Data/Import/Summary.tsx
index 13c5c8a7e7..5cd2a7dc7e 100644
--- a/client/src/components/Nav/SettingsTabs/Data/Import/Summary.tsx
+++ b/client/src/components/Nav/SettingsTabs/Data/Import/Summary.tsx
@@ -57,11 +57,11 @@ export default function Summary({
{localize('com_ui_import_detected', { 0: sourceLabel })}
- - {localize('com_ui_import_stat_conversations', { count: summary.conversations })}
+ - {localize('com_ui_import_stat_conversations', { 0: summary.conversations })}
-
{localize('com_ui_import_assets', {
- count: summary.assets,
- size: formatAssetSize(summary.assetBytes),
+ 0: summary.assets,
+ 1: formatAssetSize(summary.assetBytes),
})}
- {localize('com_ui_import_stat_archived', { 0: summary.archived })}
diff --git a/client/src/components/Nav/SettingsTabs/Data/Import/__tests__/Import.spec.tsx b/client/src/components/Nav/SettingsTabs/Data/Import/__tests__/Import.spec.tsx
index 42841d7b77..0a27acaca2 100644
--- a/client/src/components/Nav/SettingsTabs/Data/Import/__tests__/Import.spec.tsx
+++ b/client/src/components/Nav/SettingsTabs/Data/Import/__tests__/Import.spec.tsx
@@ -381,14 +381,13 @@ describe('Import panel', () => {
render();
/* Exactly once: the count is the summary. It used to also be
- repeated in the status block above, which this assertion enshrined.
- Singular, because a single failure is one item, not "1 items". */
- expect(screen.getAllByText(/^1 item could not be imported$/i)).toHaveLength(1);
+ repeated in the status block above, which this assertion enshrined. */
+ expect(screen.getAllByText(/^1 items could not be imported$/i)).toHaveLength(1);
expect(screen.getByText(/conversation 11 malformed/i)).toBeInTheDocument();
expect(screen.getByText(/archive truncated/i)).toBeInTheDocument();
});
- it('pluralizes the error count for more than one failure', () => {
+ it('shows the error count for more than one failure', () => {
dataProvider.useImportJobQuery.mockReturnValue({
data: job({
phase: 'failed',
@@ -408,27 +407,6 @@ describe('Import panel', () => {
expect(screen.getByText(/^2 items could not be imported$/i)).toBeInTheDocument();
});
- it('pluralizes the report counts, so a single conversation is not "1 conversations"', () => {
- dataProvider.useImportJobQuery.mockReturnValue({
- data: job({
- phase: 'completed',
- status: 'completed',
- report: {
- imported: 1,
- skipped: 0,
- assetsImported: 1,
- assetsUnavailable: 0,
- errors: [],
- },
- }),
- });
-
- render();
-
- expect(screen.getByText('1 conversation imported, 0 skipped')).toBeInTheDocument();
- expect(screen.getByText('1 attachment imported, 0 unavailable')).toBeInTheDocument();
- });
-
it('moves focus back to the import control after starting another import', () => {
dataProvider.useImportJobQuery.mockReturnValue({
data: job({
diff --git a/client/src/locales/en/translation.json b/client/src/locales/en/translation.json
index 00e3a4ea8d..a67c938765 100644
--- a/client/src/locales/en/translation.json
+++ b/client/src/locales/en/translation.json
@@ -1286,8 +1286,7 @@
"com_ui_image_gen_failed": "Image generation failed",
"com_ui_import": "Import",
"com_ui_import_another": "Import another file",
- "com_ui_import_assets": "{{count}} attachments ({{size}})",
- "com_ui_import_assets_one": "{{count}} attachment ({{size}})",
+ "com_ui_import_assets": "{{0}} attachments ({{1}})",
"com_ui_import_cancel": "Cancel import",
"com_ui_import_cancelled": "Import cancelled",
"com_ui_import_conversation_error": "There was an error importing your data",
@@ -1296,22 +1295,18 @@
"com_ui_import_conversation_upload_error": "Error uploading file. Please try again.",
"com_ui_import_detected": "Detected {{0}} export",
"com_ui_import_drop": "Drop your export here to import",
- "com_ui_import_errors": "{{count}} items could not be imported",
- "com_ui_import_errors_one": "{{count}} item could not be imported",
+ "com_ui_import_errors": "{{0}} items could not be imported",
"com_ui_import_lost": "This import could not be found. It may have already finished or expired.",
"com_ui_import_phase_assets": "Importing attachments",
"com_ui_import_phase_conversations": "Importing conversations",
"com_ui_import_progress_of": "{{0}} of {{1}}",
- "com_ui_import_report": "{{count}} conversations imported, {{skipped}} skipped",
- "com_ui_import_report_assets": "{{count}} attachments imported, {{unavailable}} unavailable",
- "com_ui_import_report_assets_one": "{{count}} attachment imported, {{unavailable}} unavailable",
- "com_ui_import_report_one": "{{count}} conversation imported, {{skipped}} skipped",
+ "com_ui_import_report": "{{0}} conversations imported, {{1}} skipped",
+ "com_ui_import_report_assets": "{{0}} attachments imported, {{1}} unavailable",
"com_ui_import_source_chatgpt": "ChatGPT",
"com_ui_import_source_claude": "Claude",
"com_ui_import_source_grok": "Grok",
"com_ui_import_stat_archived": "{{0}} archived",
- "com_ui_import_stat_conversations": "{{count}} conversations",
- "com_ui_import_stat_conversations_one": "{{count}} conversation",
+ "com_ui_import_stat_conversations": "{{0}} conversations",
"com_ui_import_stat_starred": "{{0}} starred",
"com_ui_importing": "Importing",
"com_ui_include_shadcnui": "Include shadcn/ui components instructions",