fix(tui): give shell mode its own prompt color under new designs (#63605)

This commit is contained in:
James Long
2026-11-12 15:09:20 -06:00
committed by GitHub
Unverified
parent 9bc30594ab
commit fd6a1167b4
+5 -2
View File
@@ -48,7 +48,7 @@ import { useConnected } from "../use-connected"
import { useToast } from "../../ui/toast"
import { createFadeIn } from "../../util/signal"
import { DialogSkill } from "../dialog-skill"
import { useConfig, useCursorStyle } from "../../config"
import { useConfig, useCursorStyle, useNewDesigns } from "../../config"
import { usePromptMove } from "./move"
import { promptFilesForServer, resolvePastedAttachments } from "./local-attachment"
import { locationKey, useData } from "../../context/data"
@@ -218,6 +218,7 @@ export function Prompt(props: PromptProps) {
const exit = useExit()
const dimensions = useTerminalDimensions()
const theme = useTheme()
const newDesigns = useNewDesigns()
const { currentSyntax: syntax } = useThemes()
const animationsEnabled = createMemo(() => config.animations ?? true)
const list = createMemo(() => props.placeholders?.normal ?? [])
@@ -1583,7 +1584,9 @@ export function Prompt(props: PromptProps) {
})
const highlight = createMemo(() => {
if (muted()) return theme.border.base
if (store.mode === "shell") return theme.text.action.primary.selected
if (store.mode === "shell")
// The new designs' interactive color matches the first agent's, so shell takes the second categorical color.
return newDesigns() ? (theme.categorical[1] ?? theme.categorical[0])[400] : theme.text.action.primary.selected
return promptDisplay().agentColor ?? theme.border.base
})
const agentLabel = createMemo(() => (store.mode === "shell" ? "Shell" : promptDisplay().agentLabel))