MCPcopy Create free account
hub / github.com/anomalyco/opencode / collapse

Function collapse

packages/app/src/context/server.tsx:93–96  ·  view source on GitHub ↗
(directory: string)

Source from the content-addressed store, hash-verified

91 if (index !== -1) setStore("projects", input.scope(), index, "expanded", true)
92 },
93 collapse(directory: string) {
94 const index = current().findIndex((project) => project.worktree === directory)
95 if (index !== -1) setStore("projects", input.scope(), index, "expanded", false)
96 },
97 move(directory: string, toIndex: number) {
98 const fromIndex = current().findIndex((project) => project.worktree === directory)
99 if (fromIndex === -1 || fromIndex === toIndex) return

Callers

nothing calls this directly

Calls 2

setStoreFunction · 0.85
currentFunction · 0.70

Tested by

no test coverage detected