feat(#145): internationalise dashboard widget strings (de/en/es)
Replace all hardcoded German strings in dashboard components with Paraglide translation keys. Date locale uses getLocale() instead of the hardcoded 'de-DE'. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -1,4 +1,6 @@
|
||||
<script lang="ts">
|
||||
import * as m from '$lib/paraglide/messages.js';
|
||||
|
||||
type NotificationDTO = {
|
||||
id: string;
|
||||
type: 'REPLY' | 'MENTION';
|
||||
@@ -18,7 +20,7 @@ let { mentions }: Props = $props();
|
||||
{#if mentions.length > 0}
|
||||
<div data-testid="dashboard-mentions" class="rounded-sm border border-line bg-surface p-6">
|
||||
<h2 class="mb-4 font-sans text-xs font-bold tracking-widest text-gray-400 uppercase">
|
||||
Benachrichtigungen
|
||||
{m.dashboard_notifications_heading()}
|
||||
</h2>
|
||||
{#each mentions as mention (mention.id)}
|
||||
<div class="flex items-center gap-3 border-b border-line py-2 last:border-0">
|
||||
@@ -29,8 +31,10 @@ let { mentions }: Props = $props();
|
||||
>
|
||||
{mention.actorName ?? ''}
|
||||
{#if mention.type === 'MENTION'}<span class="ml-1 font-sans text-xs text-gray-400"
|
||||
>erwähnt Sie</span
|
||||
>{:else}<span class="ml-1 font-sans text-xs text-gray-400">hat geantwortet</span>{/if}
|
||||
>{m.dashboard_notification_mentioned()}</span
|
||||
>{:else}<span class="ml-1 font-sans text-xs text-gray-400"
|
||||
>{m.dashboard_notification_replied()}</span
|
||||
>{/if}
|
||||
</a>
|
||||
{:else}
|
||||
<span class="font-serif text-sm text-ink">{mention.actorName ?? ''}</span>
|
||||
|
||||
Reference in New Issue
Block a user