feat: add provider duplicate functionality in edit mode
Add a duplicate button next to the drag handle in edit mode that allows users to quickly copy existing provider configurations. - Add Copy icon button in ProviderCard next to drag handle - Implement handleDuplicateProvider in App.tsx with deep cloning - Copy all provider settings (settingsConfig, websiteUrl, category, meta) - Auto-generate new ID and timestamp, omit sortIndex for natural sorting - Append " copy" to duplicated provider name - Add i18n support (zh: "复制", en: "Duplicate") - Wire onDuplicate callback through ProviderList to ProviderCard The duplicated provider will appear below the original provider in the list, sorted by creation time.
This commit is contained in:
@@ -72,6 +72,7 @@
|
||||
"removeFromClaudePlugin": "从 Claude 插件移除",
|
||||
"dragToReorder": "拖拽以重新排序",
|
||||
"dragHandle": "拖拽排序",
|
||||
"duplicate": "复制",
|
||||
"sortUpdateFailed": "排序更新失败",
|
||||
"configureUsage": "配置用量查询",
|
||||
"name": "供应商名称",
|
||||
|
||||
Reference in New Issue
Block a user