MCPcopy
hub / github.com/anomalyco/opencode / toggleTerminal

Function toggleTerminal

packages/app/src/components/session/session-header.tsx:212–220  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

210 })
211
212 const toggleTerminal = () => {
213 const next = !view().terminal.opened()
214 view().terminal.toggle()
215 if (!next) return
216
217 const id = terminal.active()
218 if (!id) return
219 focusTerminalById(id)
220 }
221
222 const [prefs, setPrefs] = persisted(Persist.global("open.app"), createStore({ app: "finder" as OpenApp }))
223 const [menu, setMenu] = createStore({ open: false })

Callers

nothing calls this directly

Calls 3

focusTerminalByIdFunction · 0.90
viewFunction · 0.85
activeMethod · 0.80

Tested by

no test coverage detected