From 9f66a9b413bbb05749c6cde464d5f588e3784022 Mon Sep 17 00:00:00 2001 From: perf3ct Date: Sat, 5 Apr 2025 00:52:32 +0000 Subject: [PATCH] add missing translations --- .../type_widgets/options/ai_settings/ai_settings_widget.ts | 6 +++--- src/public/translations/en/translation.json | 7 ++++++- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/src/public/app/widgets/type_widgets/options/ai_settings/ai_settings_widget.ts b/src/public/app/widgets/type_widgets/options/ai_settings/ai_settings_widget.ts index 0c9a3b824..d7d0df507 100644 --- a/src/public/app/widgets/type_widgets/options/ai_settings/ai_settings_widget.ts +++ b/src/public/app/widgets/type_widgets/options/ai_settings/ai_settings_widget.ts @@ -202,7 +202,7 @@ export default class AiSettingsWidget extends OptionsWidget { if (providerPrecedence.includes('openai')) { const openaiApiKey = this.$widget.find('.openai-api-key').val(); if (!openaiApiKey) { - openaiWarnings.push(t("ai_llm.warning_openai_missing_api_key")); + openaiWarnings.push(t("ai_llm.empty_key_warning.openai")); } } @@ -211,7 +211,7 @@ export default class AiSettingsWidget extends OptionsWidget { if (providerPrecedence.includes('anthropic')) { const anthropicApiKey = this.$widget.find('.anthropic-api-key').val(); if (!anthropicApiKey) { - anthropicWarnings.push(t("ai_llm.warning_anthropic_missing_api_key")); + anthropicWarnings.push(t("ai_llm.empty_key_warning.anthropic")); } } @@ -220,7 +220,7 @@ export default class AiSettingsWidget extends OptionsWidget { if (providerPrecedence.includes('voyage')) { const voyageApiKey = this.$widget.find('.voyage-api-key').val(); if (!voyageApiKey) { - voyageWarnings.push(t("ai_llm.warning_voyage_missing_api_key")); + voyageWarnings.push(t("ai_llm.empty_key_warning.voyage")); } } diff --git a/src/public/translations/en/translation.json b/src/public/translations/en/translation.json index 036266848..bbb75b60e 100644 --- a/src/public/translations/en/translation.json +++ b/src/public/translations/en/translation.json @@ -1888,7 +1888,12 @@ "api_key": "API Key", "api_key_tooltip": "API key for accessing the service", "confirm_delete_embeddings": "Are you sure you want to delete all AI embeddings? This will remove all semantic search capabilities until notes are reindexed, which can take a significant amount of time.", - "empty_key_warning": "Warning: Empty API key. You need to configure your API key in settings.", + "empty_key_warning": { + "anthropic": "Anthropic API key is empty. Please enter a valid API key.", + "openai": "OpenAI API key is empty. Please enter a valid API key.", + "voyage": "Voyage API key is empty. Please enter a valid API key.", + "ollama": "Ollama API key is empty. Please enter a valid API key." + }, "enable_ai": "Enable AI Features", "name": "AI", "openai": "OpenAI",