Skip to content

Commit 8c7ea3a

Browse files
committed
Standardize setup incomplete warnings and localization keys across API configurations and providers
- api setup incomplete -> setup incomplete (with key and translations) - rename 'no api configu...' to 'setup incomplete.' (with translations and keys) - add missing translations [Fragment] ├── apps │ └── editor │ └── src │ ├── i18n │ │ └── translations │ │ ├── common.ts │ │ └── views │ │ └── shared │ │ └── actions │ │ └── api │ │ └── create │ │ └── interactions │ │ └── initial-select-provider.ts │ ├── utils │ │ └── show-missing-configuration-notification.ts │ └── views │ ├── prompt │ │ └── frontend │ │ ├── Main │ │ │ └── MainView │ │ │ ├── MainView.tsx │ │ │ └── components │ │ │ └── Header │ │ │ ├── Header.module.scss │ │ │ ├── Header.tsx │ │ │ └── index.ts │ │ └── i18n │ │ └── translations │ │ └── configurations.ts │ └── settings │ └── backend │ └── message-handlers │ └── handle-select-default-api-configuration.ts └── packages └── ui └── src └── components └── editor └── prompt └── Configurations └── Configurations.tsx
1 parent 54d501b commit 8c7ea3a

7 files changed

Lines changed: 53 additions & 54 deletions

File tree

‎apps/editor/src/i18n/translations/common.ts‎

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -53,23 +53,23 @@ export const translations = {
5353
hu: 'A felhasználó megszakította a műveletet',
5454
bg: 'Потребителят отмени операцията'
5555
},
56-
'common.warning.no-api-configs': {
57-
en: 'No API configurations found. Please create one first.',
58-
pl: 'Nie znaleziono konfiguracji API. Najpierw utwórz jedną.',
59-
'zh-cn': '未找到 API 配置。请先创建一个。',
60-
ja: 'API設定が見つかりません。先に作成してください。',
61-
'zh-tw': '找不到 API 配置。請先建立一個。',
62-
de: 'Keine API-Konfigurationen gefunden. Bitte erstellen Sie zuerst eine.',
63-
es: 'No se encontraron configuraciones de API. Por favor, cree una primero.',
64-
fr: "Aucune configuration d'API trouvée. Veuillez d'abord en créer une.",
65-
'pt-br': 'Nenhuma configuração de API encontrada. Crie uma primeiro.',
66-
ru: 'Конфигурации API не найдены. Пожалуйста, сначала создайте одну.',
67-
ko: 'API 구성을 찾을 수 없습니다. 먼저 하나를 만드세요.',
68-
it: 'Nessuna configurazione API trovata. Creane prima una.',
69-
tr: 'API yapılandırması bulunamadı. Lütfen önce bir tane oluşturun.',
70-
cs: 'Nebyly nalezeny žádné konfigurace API. Nejprve prosím jednu vytvořte.',
71-
hu: 'Nem találhatók API konfigurációk. Kérjük, először hozzon létre egyet.',
72-
bg: 'Не са намерени API конфигурации. Моля, първо създайте една.'
56+
'common.warning.setup-incomplete': {
57+
en: 'Setup incomplete.',
58+
pl: 'Konfiguracja niekompletna.',
59+
'zh-cn': '设置未完成。',
60+
ja: 'セットアップが未完了です。',
61+
'zh-tw': '設定未完成。',
62+
de: 'Einrichtung unvollständig.',
63+
es: 'Configuración incompleta.',
64+
fr: 'Configuration incomplète.',
65+
'pt-br': 'Configuração incompleta.',
66+
ru: 'Настройка не завершена.',
67+
ko: '설정이 완료되지 않았습니다.',
68+
it: 'Configurazione incompleta.',
69+
tr: 'Kurulum tamamlanmadı.',
70+
cs: 'Nastavení není dokončeno.',
71+
hu: 'A beállítás nem teljes.',
72+
bg: 'Настройката е непълна.'
7373
},
7474
'common.error.provider-not-found': {
7575
en: 'Provider {name} not found.',

‎apps/editor/src/i18n/translations/views/shared/actions/api/create/interactions/initial-select-provider.ts‎

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -58,21 +58,21 @@ export const translations = {
5858
},
5959
'views.shared.actions.api.create.interactions.initial-select-provider.no-providers-found':
6060
{
61-
en: 'No providers found. Please add one first.',
62-
pl: 'Nie znaleziono providerów. Najpierw dodaj jednego.',
63-
'zh-cn': '未找到提供商。请先添加一个。',
64-
ja: 'プロバイダーが見つかりません。まず追加してください。',
65-
'zh-tw': '未找到供應商。請先新增一個。',
66-
de: 'Keine Anbieter gefunden. Bitte fügen Sie zuerst einen hinzu.',
67-
es: 'No se encontraron proveedores. Por favor, añade uno primero.',
68-
fr: "Aucun fournisseur trouvé. Veuillez d'abord en ajouter un.",
69-
'pt-br': 'Nenhum provedor encontrado. Por favor, adicione um primeiro.',
70-
ru: 'Провайдеры не найдены. Пожалуйста, сначала добавьте одного.',
71-
ko: '제공자를 찾을 수 없습니다. 먼저 추가해 주세요.',
72-
it: 'Nessun fornitore trovato. Aggiungine prima uno.',
73-
tr: 'Sağlayıcı bulunamadı. Lütfen önce bir tane ekleyin.',
74-
cs: 'Nebyli nalezeni žádní poskytovatelé. Nejprve prosím nějakého přidejte.',
75-
hu: 'Nem találhatók szolgáltatók. Kérjük, először adjon hozzá egyet.',
76-
bg: 'Не са намерени доставчици. Моля, първо добавете един.'
61+
en: 'No providers found.',
62+
pl: 'Nie znaleziono providerów.',
63+
'zh-cn': '未找到提供商。',
64+
ja: 'プロバイダーが見つかりません。',
65+
'zh-tw': '找不到供應商。',
66+
de: 'Keine Anbieter gefunden.',
67+
es: 'No se encontraron proveedores.',
68+
fr: 'Aucun fournisseur trouvé.',
69+
'pt-br': 'Nenhum provedor encontrado.',
70+
ru: 'Провайдеры не найдены.',
71+
ko: '제공자를 찾을 수 없습니다.',
72+
it: 'Nessun fornitore trovato.',
73+
tr: 'Sağlayıcı bulunamadı.',
74+
cs: 'Nebyli nalezeni žádní poskytovatelé.',
75+
hu: 'Nem találhatók szolgáltatók.',
76+
bg: 'Не са намерени доставчици.'
7777
}
7878
} as const

‎apps/editor/src/utils/show-missing-configuration-notification.ts‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ export const show_incomplete_setup_warning = async (
88
const open_settings_label = t('common.open-settings')
99
const result = await vscode.window.showWarningMessage(
1010
type == 'api'
11-
? t('common.warning.no-api-configs')
11+
? t('common.warning.setup-incomplete')
1212
: t('common.info.no-items-created-yet', { items: 'chatbots' }),
1313
open_settings_label
1414
)

‎apps/editor/src/views/prompt/frontend/Main/MainView/MainView.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -306,7 +306,7 @@ export const MainView: React.FC<Props> = (props) => {
306306
<UiStatusBar
307307
theme="warning"
308308
icon="codicon-warning"
309-
label={t('configurations.api-setup-incomplete')}
309+
label={t('configurations.setup-incomplete')}
310310
actions={[
311311
{
312312
id: 'settings',

‎apps/editor/src/views/prompt/frontend/i18n/translations/configurations.ts‎

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,21 @@
11
export const configurations = {
2-
'configurations.api-setup-incomplete': {
3-
en: 'API setup incomplete',
4-
pl: 'Konfiguracja API niekompletna',
5-
'zh-cn': 'API 设置不完整',
6-
ja: 'API の設定が不完全です',
7-
'zh-tw': 'API 設定不完整',
8-
de: 'API-Einrichtung unvollständig',
9-
es: 'Configuración de API incompleta',
10-
fr: 'Configuration de l’API incomplète',
11-
'pt-br': 'Configuração da API incompleta',
12-
ru: 'Настройка API не завершена',
13-
ko: 'API 설정이 불완전합니다',
14-
it: 'Configurazione API incompleta',
15-
tr: 'API kurulumu eksik',
16-
cs: 'Nastavení API je neúplné',
17-
hu: 'Az API beállítása nem teljes',
18-
bg: 'Настройката на API е непълна'
2+
'configurations.setup-incomplete': {
3+
en: 'Setup incomplete',
4+
pl: 'Konfiguracja niekompletna',
5+
'zh-cn': '设置不完整',
6+
ja: '設定が不完全です',
7+
'zh-tw': '設定不完整',
8+
de: 'Einrichtung unvollständig',
9+
es: 'Configuración incompleta',
10+
fr: 'Configuration incomplète',
11+
'pt-br': 'Configuração incompleta',
12+
ru: 'Настройка не завершена',
13+
ko: '설정이 불완전합니다',
14+
it: 'Configurazione incompleta',
15+
tr: 'Kurulum eksik',
16+
cs: 'Nastavení je neúplné',
17+
hu: 'A beállítás nem teljes',
18+
bg: 'Настройката е непълна'
1919
},
2020
'configurations.empty': {
2121
en: 'No models configured yet',

‎apps/editor/src/views/settings/backend/message-handlers/handle-select-default-api-configuration.ts‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@ export const handle_select_default_api_configuration = async (
1717
const api_configurations = await providers_manager.get_api_configurations()
1818

1919
if (api_configurations.length == 0) {
20-
vscode.window.showInformationMessage(t('common.warning.no-api-configs'))
2120
return
2221
}
2322

‎apps/editor/src/views/shared/actions/api/create/interactions/initial-select-provider.ts‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ export const initial_select_provider = async (
1111

1212
if (providers.length == 0) {
1313
const open_settings_btn = t('common.open-settings')
14-
const selection = await vscode.window.showInformationMessage(
14+
const selection = await vscode.window.showWarningMessage(
1515
t(
1616
'views.shared.actions.api.create.interactions.initial-select-provider.no-providers-found'
1717
),

0 commit comments

Comments
 (0)