MCPcopy Create free account
hub / github.com/WJX20/claude-code / isTextBreaker

Function isTextBreaker

src/utils/collapseReadSearch.ts:354–362  ·  view source on GitHub ↗

* Check if a message is assistant text that should break a group.

(msg: RenderableMessage)

Source from the content-addressed store, hash-verified

352 * Check if a message is assistant text that should break a group.
353 */
354function isTextBreaker(msg: RenderableMessage): boolean {
355 if (msg.type === 'assistant') {
356 const content = getFirstContentItem(msg.message?.content)
357 if (content && content.type === 'text' && (content as { type: 'text'; text: string }).text.trim().length > 0) {
358 return true
359 }
360 }
361 return false
362}
363
364/**
365 * Check if a message is a non-collapsible tool use that should break a group.

Callers 1

collapseReadSearchGroupsFunction · 0.85

Calls 1

getFirstContentItemFunction · 0.85

Tested by

no test coverage detected