Unverified 提交 46610123 authored 作者: Will Chen's avatar Will Chen 提交者: GitHub

Do not allow custom models for (dyad/auto) & drive-by: key improvement (#156)

上级 069c2212
...@@ -84,7 +84,7 @@ export function ModelsSection({ providerId }: ModelsSectionProps) { ...@@ -84,7 +84,7 @@ export function ModelsSection({ providerId }: ModelsSectionProps) {
<div className="mt-4 space-y-3"> <div className="mt-4 space-y-3">
{models.map((model) => ( {models.map((model) => (
<div <div
key={model.apiName} key={model.apiName + model.displayName}
className="p-4 bg-white dark:bg-gray-800 border border-gray-200 dark:border-gray-700 rounded-lg shadow-sm" className="p-4 bg-white dark:bg-gray-800 border border-gray-200 dark:border-gray-700 rounded-lg shadow-sm"
> >
<div className="flex justify-between items-center"> <div className="flex justify-between items-center">
...@@ -145,13 +145,15 @@ export function ModelsSection({ providerId }: ModelsSectionProps) { ...@@ -145,13 +145,15 @@ export function ModelsSection({ providerId }: ModelsSectionProps) {
)} )}
{/* End Custom Models List Area */} {/* End Custom Models List Area */}
<Button {providerId !== "auto" && (
onClick={() => setIsCustomModelDialogOpen(true)} <Button
variant="outline" onClick={() => setIsCustomModelDialogOpen(true)}
className="mt-6" variant="outline"
> className="mt-6"
<PlusIcon className="mr-2 h-4 w-4" /> Add Custom Model >
</Button> <PlusIcon className="mr-2 h-4 w-4" /> Add Custom Model
</Button>
)}
{/* Render the dialog */} {/* Render the dialog */}
<CreateCustomModelDialog <CreateCustomModelDialog
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论