From 1cf69a061d99c575e96ed4a5dc6d0df2f1f5838a Mon Sep 17 00:00:00 2001 From: Maya Date: Thu, 31 Jul 2025 16:40:04 +0300 Subject: [PATCH] fix: dropdown translations --- messages/en.json | 7 +++++++ messages/es.json | 7 +++++++ src/lib/components/functional/FormatDropdown.svelte | 4 ++-- src/lib/converters/index.ts | 4 ++-- 4 files changed, 18 insertions(+), 4 deletions(-) diff --git a/messages/en.json b/messages/en.json index c201a6f..de11f31 100644 --- a/messages/en.json +++ b/messages/en.json @@ -50,6 +50,13 @@ "set_all_to": "Set all to", "na": "N/A" }, + "dropdown": { + "audio": "Audio", + "video": "Video", + "doc": "Document", + "image": "Image", + "placeholder": "Search format" + }, "tooltips": { "unknown_file": "Unknown file type", "audio_file": "Audio file", diff --git a/messages/es.json b/messages/es.json index 66d5d12..d9c6174 100644 --- a/messages/es.json +++ b/messages/es.json @@ -50,6 +50,13 @@ "set_all_to": "Cambiar todos a", "na": "N/A" }, + "dropdown": { + "audio": "Audio", + "video": "Video", + "doc": "Documento", + "image": "Imagen", + "placeholder": "Buscar formato" + }, "tooltips": { "unknown_file": "Formato de archivo desconocido", "audio_file": "Audio", diff --git a/src/lib/components/functional/FormatDropdown.svelte b/src/lib/components/functional/FormatDropdown.svelte index a72a0d4..2f181bc 100644 --- a/src/lib/components/functional/FormatDropdown.svelte +++ b/src/lib/components/functional/FormatDropdown.svelte @@ -317,7 +317,7 @@
selectCategory(category)} > - {(m as any)[`upload.cards.${category}`]?.() || category} + {(m as any)[`convert.dropdown.${category}`]?.()} {/each}
diff --git a/src/lib/converters/index.ts b/src/lib/converters/index.ts index 6b9433d..5c03d02 100644 --- a/src/lib/converters/index.ts +++ b/src/lib/converters/index.ts @@ -25,7 +25,7 @@ export const categories: Categories = { image: { formats: [""], canConvertTo: [] }, video: { formats: [""], canConvertTo: ["audio"] }, audio: { formats: [""], canConvertTo: ["video"] }, - docs: { formats: [""], canConvertTo: [] }, + doc: { formats: [""], canConvertTo: [] }, }; categories.audio.formats = @@ -42,7 +42,7 @@ categories.image.formats = converters .find((c) => c.name === "imagemagick") ?.formatStrings((f) => f.toSupported) || []; -categories.docs.formats = +categories.doc.formats = converters .find((c) => c.name === "pandoc") ?.supportedFormats.filter((f) => f.toSupported && f.isNative)