diff --git a/web/src/features/keys/components/data-table-row-actions.tsx b/web/src/features/keys/components/data-table-row-actions.tsx index 5a75d5f62a1c..bb6c5e567c16 100644 --- a/web/src/features/keys/components/data-table-row-actions.tsx +++ b/web/src/features/keys/components/data-table-row-actions.tsx @@ -23,7 +23,6 @@ import { Power, PowerOff, ExternalLink, - ArrowRightLeft, Copy, Link, Loader2, @@ -35,12 +34,12 @@ import { toast } from 'sonner' import { DataTableRowActionMenu } from '@/components/data-table/core/row-action-menu' import { Button } from '@/components/ui/button' import { + DropdownMenu, + DropdownMenuContent, DropdownMenuItem, DropdownMenuSeparator, - DropdownMenuSub, - DropdownMenuSubContent, - DropdownMenuSubTrigger, DropdownMenuShortcut, + DropdownMenuTrigger, } from '@/components/ui/dropdown-menu' import { Tooltip, @@ -213,6 +212,46 @@ export function DataTableRowActions({ {toggleLabel} + {hasChatPresets && ( + + } + > + {t('Chat (Export to)')} + + + {chatPresets.map((preset) => ( + handleOpenChatPreset(preset)} + > + {preset.name} + {preset.type !== 'web' && ( + + + + )} + + ))} + + + )} + + + ({ - { - const realKey = await resolveRealKey(apiKey.id) - if (!realKey) return - setResolvedKey(realKey) - setCurrentRow(apiKey) - setOpen('cc-switch') - }} - > - {t('CC Switch')} - - - - - {hasChatPresets && ( - - {t('Chat')} - - {chatPresets.map((preset) => ( - handleOpenChatPreset(preset)} - > - {preset.name} - {preset.type !== 'web' && ( - - - - )} - - ))} - - - )} - { setCurrentRow(apiKey) diff --git a/web/src/i18n/locales/zh.json b/web/src/i18n/locales/zh.json index f81d71999bb8..f3375f1e41bd 100644 --- a/web/src/i18n/locales/zh.json +++ b/web/src/i18n/locales/zh.json @@ -725,6 +725,8 @@ "Category name must be less than 50 characters": "分类名称不能超过 50 个字符", "Caution": "注意", "CC Switch": "CC Switch", + "Chat (Export to)": "聊天(导出到)", + "Export to CCS": "导出到 CCS", "Centered": "居中", "Chain": "链路", "Change": "更改",