diff --git a/components/model-config-dialog.tsx b/components/model-config-dialog.tsx index b7a5ba0..de1ba11 100644 --- a/components/model-config-dialog.tsx +++ b/components/model-config-dialog.tsx @@ -376,7 +376,7 @@ export function ModelConfigDialog({ handleAddProvider(v as ProviderName) } > - + @@ -697,7 +697,7 @@ export function ModelConfigDialog({ } }} > - + Suggested diff --git a/components/ui/command.tsx b/components/ui/command.tsx index f0940ff..82e269a 100644 --- a/components/ui/command.tsx +++ b/components/ui/command.tsx @@ -145,6 +145,18 @@ function CommandItem({ "data-[selected=true]:bg-accent data-[selected=true]:text-accent-foreground [&_svg:not([class*='text-'])]:text-muted-foreground relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[disabled=true]:pointer-events-none data-[disabled=true]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", className )} + onMouseEnter={(e) => { + // Ensure hover updates selection for visual feedback + const item = e.currentTarget + item.setAttribute("data-selected", "true") + // Deselect siblings + const siblings = item.parentElement?.querySelectorAll("[cmdk-item]") + siblings?.forEach((sibling) => { + if (sibling !== item) { + sibling.setAttribute("data-selected", "false") + } + }) + }} {...props} /> ) diff --git a/components/ui/select.tsx b/components/ui/select.tsx index f58365e..25e5439 100644 --- a/components/ui/select.tsx +++ b/components/ui/select.tsx @@ -37,7 +37,7 @@ function SelectTrigger({ data-slot="select-trigger" data-size={size} className={cn( - "border-input data-[placeholder]:text-muted-foreground [&_svg:not([class*='text-'])]:text-muted-foreground focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive hover:bg-accent dark:bg-input/30 dark:hover:bg-input/50 flex w-fit items-center justify-between gap-2 rounded-md border bg-transparent px-3 py-2 text-sm whitespace-nowrap shadow-xs transition-[color,box-shadow] outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50 data-[size=default]:h-9 data-[size=sm]:h-8 *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-2 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", + "border-input data-[placeholder]:text-muted-foreground [&_svg:not([class*='text-'])]:text-muted-foreground focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive dark:bg-input/30 dark:hover:bg-input/50 flex w-fit items-center justify-between gap-2 rounded-md border bg-transparent px-3 py-2 text-sm whitespace-nowrap shadow-xs transition-[color,box-shadow] outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50 data-[size=default]:h-9 data-[size=sm]:h-8 *:data-[slot=select-value]:line-clamp-1 *:data-[slot=select-value]:flex *:data-[slot=select-value]:items-center *:data-[slot=select-value]:gap-2 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4", className )} {...props}