MCPcopy Index your code
hub / github.com/anomalyco/opencode / taskTab

Function taskTab

packages/opencode/src/cli/cmd/run/subagent-data.ts:311–327  ·  view source on GitHub ↗
(part: ToolPart, sessionID: string)

Source from the content-addressed store, hash-verified

309}
310
311function taskTab(part: ToolPart, sessionID: string): FooterSubagentTab {
312 const label = Locale.titlecase(text(part.state.input.subagent_type) ?? "general")
313 const description = text(part.state.input.description) ?? stateTitle(part) ?? inputLabel(part.state.input) ?? ""
314
315 return {
316 sessionID,
317 partID: part.id,
318 callID: part.callID,
319 label,
320 description,
321 status: taskStatus(part),
322 background: metadata(part, "background") === true,
323 title: stateTitle(part),
324 toolCalls: num(metadata(part, "toolcalls")) ?? num(metadata(part, "toolCalls")) ?? num(metadata(part, "calls")),
325 lastUpdatedAt: stateUpdatedAt(part),
326 }
327}
328
329function taskSessionID(part: ToolPart) {
330 return text(metadata(part, "sessionId")) ?? text(metadata(part, "sessionID"))

Callers 1

syncTaskTabFunction · 0.85

Calls 7

stateTitleFunction · 0.85
taskStatusFunction · 0.85
stateUpdatedAtFunction · 0.85
textFunction · 0.70
inputLabelFunction · 0.70
metadataFunction · 0.70
numFunction · 0.70

Tested by

no test coverage detected