feat(desktop): open read-only TurkServis combo details in browser pane
This commit is contained in:
1 parent
ff2eb47302
commit
3332458708
16 files changed
+110
-4
No files matched your search
@@ -75,6 +75,8 @@ interface ModelEditSubmenuProps {
|
||||
isActive: boolean
|
||||
/** This row's model id. */
|
||||
model: string
|
||||
/** Read-only details; the owner handles opening without changing selection. */
|
||||
onOpenDetails?: () => void
|
||||
/** Switch to a specific model id (used to swap base ⇄ -fast variant). */
|
||||
onSelectModel: (model: string) => Promise<boolean | void> | void
|
||||
/** Report an option change. This submenu is PURE: it never writes to a
|
||||
@@ -107,6 +109,7 @@ function ModelEditSubmenuBody({
|
||||
effort,
|
||||
fastControl,
|
||||
isActive,
|
||||
onOpenDetails,
|
||||
onSelectModel,
|
||||
onSetOptions,
|
||||
reasoning
|
||||
@@ -140,11 +143,19 @@ function ModelEditSubmenuBody({
|
||||
const hasFast = fastControl.kind !== 'none'
|
||||
const fastOn = fastControl.kind === 'none' ? false : fastControl.on
|
||||
|
||||
return !hasFast && !reasoning ? (
|
||||
return !hasFast && !reasoning && !onOpenDetails ? (
|
||||
<div className="px-2.5 py-3 text-xs text-(--ui-text-tertiary)">{copy.noOptions}</div>
|
||||
) : (
|
||||
<>
|
||||
<DropdownMenuLabel className={dropdownMenuSectionLabel}>{copy.options}</DropdownMenuLabel>
|
||||
{onOpenDetails ? (
|
||||
<>
|
||||
<DropdownMenuItem className={dropdownMenuRow} onSelect={onOpenDetails}>
|
||||
{copy.comboDetails}
|
||||
</DropdownMenuItem>
|
||||
{hasFast || reasoning ? <DropdownMenuSeparator className="mx-0" /> : null}
|
||||
</>
|
||||
) : null}
|
||||
{hasFast || reasoning ? <DropdownMenuLabel className={dropdownMenuSectionLabel}>{copy.options}</DropdownMenuLabel> : null}
|
||||
{showThinkingToggle ? (
|
||||
<DropdownMenuItem className={dropdownMenuRow} onSelect={event => event.preventDefault()}>
|
||||
{copy.thinking}
|
||||
|
||||
Reference in new issue
Block a user