From 1894e65495ef2e77cee462c692bb0a92c1eeb0db Mon Sep 17 00:00:00 2001 From: Till JS Date: Mon, 27 Apr 2026 02:14:40 +0200 Subject: [PATCH] =?UTF-8?q?i18n(automations):=20translate=20ListView=20via?= =?UTF-8?q?=20$=5F()=20=E2=80=94=20suggestions,=20create=20form,=20flow=20?= =?UTF-8?q?visualization,=20empty=20state?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Section labels (Vorschläge/Aktive Regeln), suggestion CTAs (Aktivieren/Nein), '+ Neu' button - Create form: name placeholder, WENN/FILTER/DANN step badges, source/action/habit/value selectors and placeholders, source-op options (erstellt wird / geändert wird), 'Kein Filter' option, Abbrechen/Erstellen footer - Toggle title (Deaktivieren/Aktivieren), delete title (Löschen) - Flow-chip 'wenn' marker, sourceDetail() helper now i18n's the 'erstellt'/'geändert' particle - Empty state: title, hint, action Baselines: hardcoded 1242 → 1230 (12 cleared); missing-keys baseline unchanged. Co-Authored-By: Claude Opus 4.7 (1M context) --- .../lib/modules/automations/ListView.svelte | 64 +++++++++++-------- scripts/i18n-hardcoded-baseline.json | 1 - 2 files changed, 39 insertions(+), 26 deletions(-) diff --git a/apps/mana/apps/web/src/lib/modules/automations/ListView.svelte b/apps/mana/apps/web/src/lib/modules/automations/ListView.svelte index 54e570510..27361615b 100644 --- a/apps/mana/apps/web/src/lib/modules/automations/ListView.svelte +++ b/apps/mana/apps/web/src/lib/modules/automations/ListView.svelte @@ -14,6 +14,7 @@ import { Trash } from '@mana/shared-icons'; import { generateSuggestions, dismissSuggestion, isSuggestionDismissed } from '$lib/triggers'; import type { AutomationSuggestion } from '$lib/triggers'; + import { _ } from 'svelte-i18n'; let { navigate, goBack, params }: ViewProps = $props(); @@ -147,7 +148,10 @@ const src = SOURCE_OPTIONS.find( (s) => s.app === a.sourceApp && s.collection === a.sourceCollection ); - const opLabel = a.sourceOp === 'insert' ? 'erstellt' : 'geaendert'; + const opLabel = + a.sourceOp === 'insert' + ? $_('automations.list_view.detail_inserted') + : $_('automations.list_view.detail_updated'); return src ? `${src.collectionLabel} ${opLabel}` : `${a.sourceCollection} ${opLabel}`; } @@ -177,7 +181,7 @@ {#if suggestions.length > 0}
- + {#each suggestions as sug (sug.id)}
@@ -188,8 +192,12 @@ {sug.description}
- - + +
{/each} @@ -199,9 +207,11 @@
- + {#if !showCreate} - + {/if}
@@ -210,15 +220,15 @@
- WENN + {$_('automations.list_view.step_when')}
- - + + {/if}
@@ -236,10 +246,10 @@ {#if selectedSource}
- FILTER + {$_('automations.list_view.step_filter')}
{/if} @@ -262,10 +272,10 @@ {/if}
- DANN + {$_('automations.list_view.step_then')}