mirror of
https://github.com/farion1231/cc-switch.git
synced 2026-08-03 11:01:22 +08:00
fix(opencode): fix add/remove provider flow and toast messages
- Create separate removeFromLiveConfig API for additive mode apps (remove only removes from live config, not database) - Fix useSwitchProviderMutation to invalidate opencodeLiveProviderIds cache so button state updates correctly after add operation - Show appropriate toast messages: - Add: "已添加到配置" / "Added to config" - Remove: "已从配置移除" / "Removed from config" - Add i18n texts for addToConfigSuccess and removeFromConfigSuccess
This commit is contained in:
@@ -137,6 +137,8 @@
|
||||
"providerSaved": "Provider configuration saved",
|
||||
"providerDeleted": "Provider deleted successfully",
|
||||
"switchSuccess": "Switch successful!",
|
||||
"addToConfigSuccess": "Added to config",
|
||||
"removeFromConfigSuccess": "Removed from config",
|
||||
"switchFailedTitle": "Switch failed",
|
||||
"switchFailed": "Switch failed: {{error}}",
|
||||
"autoImported": "Default provider created from existing configuration",
|
||||
|
||||
@@ -137,6 +137,8 @@
|
||||
"providerSaved": "プロバイダー設定を保存しました",
|
||||
"providerDeleted": "プロバイダーを削除しました",
|
||||
"switchSuccess": "切り替え成功!",
|
||||
"addToConfigSuccess": "設定に追加しました",
|
||||
"removeFromConfigSuccess": "設定から削除しました",
|
||||
"switchFailedTitle": "切り替えに失敗しました",
|
||||
"switchFailed": "切り替えに失敗しました: {{error}}",
|
||||
"autoImported": "既存設定からデフォルトプロバイダーを自動作成しました",
|
||||
|
||||
@@ -137,6 +137,8 @@
|
||||
"providerSaved": "供应商配置已保存",
|
||||
"providerDeleted": "供应商删除成功",
|
||||
"switchSuccess": "切换成功!",
|
||||
"addToConfigSuccess": "已添加到配置",
|
||||
"removeFromConfigSuccess": "已从配置移除",
|
||||
"switchFailedTitle": "切换失败",
|
||||
"switchFailed": "切换失败:{{error}}",
|
||||
"autoImported": "已从现有配置创建默认供应商",
|
||||
|
||||
Reference in New Issue
Block a user