fix(bulk-upload): i18n hardcoded strings in BulkDropZone and FileSwitcherStrip
- Add bulk_drop_desc, bulk_select_files, bulk_drop_zone_label, bulk_remove_file keys to de/en/es message files - BulkDropZone: use m.bulk_drop_zone_label(), m.bulk_drop_desc(), m.bulk_select_files() — removes all hardcoded German - FileSwitcherStrip: use m.bulk_remove_file() on × button; move aria-live from <ul> to a dedicated visually-hidden region above the strip (screen readers now announce changes without coupling the live region to the list) - Spec: import FileEntry from component instead of re-declaring; use data-remove-id selector instead of hardcoded German aria-label Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -58,6 +58,7 @@ $effect(() => {
|
||||
});
|
||||
</script>
|
||||
|
||||
<div aria-live="polite" aria-atomic="true" class="sr-only"></div>
|
||||
<div
|
||||
data-testid="file-switcher-strip"
|
||||
class="flex h-11 shrink-0 items-center gap-1 border-t border-line bg-pdf-ctrl px-2"
|
||||
@@ -71,7 +72,7 @@ $effect(() => {
|
||||
>
|
||||
|
||||
<div bind:this={trackEl} class="flex flex-1 gap-1 overflow-x-auto" style="scrollbar-width:none">
|
||||
<ul bind:this={listEl} aria-live="polite" role="list" class="flex flex-row gap-1 py-1">
|
||||
<ul bind:this={listEl} role="list" class="flex flex-row gap-1 py-1">
|
||||
{#each files as entry, i (entry.id)}
|
||||
<li role="listitem" class="inline-flex shrink-0 items-center">
|
||||
<button
|
||||
@@ -102,7 +103,7 @@ $effect(() => {
|
||||
</button>
|
||||
<button
|
||||
type="button"
|
||||
aria-label="Entfernen"
|
||||
aria-label={m.bulk_remove_file()}
|
||||
data-remove-id={entry.id}
|
||||
onclick={() => onRemove(entry.id)}
|
||||
class="ml-0.5 flex h-[44px] w-[44px] items-center justify-center text-base text-ink-3 hover:text-ink focus:outline-none focus-visible:ring-2 focus-visible:ring-accent"
|
||||
|
||||
Reference in New Issue
Block a user