mirror of
https://github.com/farion1231/cc-switch.git
synced 2026-07-27 16:26:16 +08:00
feat: differentiate fetch models error messages by failure type
Distinguish between missing API key, missing endpoint, auth failure, unsupported provider (404/405), and timeout errors instead of showing a generic failure toast for all cases.
This commit is contained in:
@@ -795,7 +795,13 @@
|
||||
"fetchingModels": "Fetching...",
|
||||
"fetchModelsSuccess": "Found {{count}} models",
|
||||
"fetchModelsFailed": "Failed to fetch models",
|
||||
"fetchModelsEmpty": "No models found"
|
||||
"fetchModelsEmpty": "No models found",
|
||||
"fetchModelsNeedApiKey": "Please fill in API Key first",
|
||||
"fetchModelsNeedEndpoint": "Please fill in API endpoint first",
|
||||
"fetchModelsNeedConfig": "Please fill in API endpoint and API Key first",
|
||||
"fetchModelsAuthFailed": "API Key is invalid or lacks permission",
|
||||
"fetchModelsNotSupported": "This provider does not support fetching model list",
|
||||
"fetchModelsTimeout": "Request timed out, please check network connection"
|
||||
},
|
||||
"copilot": {
|
||||
"authSection": "GitHub Copilot Authentication",
|
||||
|
||||
@@ -795,7 +795,13 @@
|
||||
"fetchingModels": "取得中...",
|
||||
"fetchModelsSuccess": "{{count}}件のモデルを取得",
|
||||
"fetchModelsFailed": "モデル一覧の取得に失敗しました",
|
||||
"fetchModelsEmpty": "モデルが見つかりません"
|
||||
"fetchModelsEmpty": "モデルが見つかりません",
|
||||
"fetchModelsNeedApiKey": "先に API Key を入力してください",
|
||||
"fetchModelsNeedEndpoint": "先に API エンドポイントを入力してください",
|
||||
"fetchModelsNeedConfig": "先に API エンドポイントと API Key を入力してください",
|
||||
"fetchModelsAuthFailed": "API Key が無効か、権限がありません",
|
||||
"fetchModelsNotSupported": "このプロバイダーはモデル一覧の取得に対応していません",
|
||||
"fetchModelsTimeout": "リクエストがタイムアウトしました。ネットワーク接続を確認してください"
|
||||
},
|
||||
"copilot": {
|
||||
"authSection": "GitHub Copilot 認証",
|
||||
|
||||
@@ -795,7 +795,13 @@
|
||||
"fetchingModels": "正在获取...",
|
||||
"fetchModelsSuccess": "获取到 {{count}} 个模型",
|
||||
"fetchModelsFailed": "获取模型列表失败",
|
||||
"fetchModelsEmpty": "未找到可用模型"
|
||||
"fetchModelsEmpty": "未找到可用模型",
|
||||
"fetchModelsNeedApiKey": "请先填写 API Key",
|
||||
"fetchModelsNeedEndpoint": "请先填写 API 端点",
|
||||
"fetchModelsNeedConfig": "请先填写 API 端点和 API Key",
|
||||
"fetchModelsAuthFailed": "API Key 无效或无权限",
|
||||
"fetchModelsNotSupported": "该供应商不支持获取模型列表",
|
||||
"fetchModelsTimeout": "请求超时,请检查网络连接"
|
||||
},
|
||||
"copilot": {
|
||||
"authSection": "GitHub Copilot 认证",
|
||||
|
||||
Reference in New Issue
Block a user