MCPcopy Create free account
hub / github.com/AnukarOP/claude-code-leaked / shouldShowUserMessage

Function shouldShowUserMessage

source code/utils/messages.ts:4660–4679  ·  view source on GitHub ↗
(
  message: NormalizedMessage,
  isTranscriptMode: boolean,
)

Source from the content-addressed store, hash-verified

4658}
4659
4660export function shouldShowUserMessage(
4661 message: NormalizedMessage,
4662 isTranscriptMode: boolean,
4663): boolean {
4664 if (message.type !== 'user') return true
4665 if (message.isMeta) {
4666 // Channel messages stay isMeta (for snip-tag/turn-boundary/brief-mode
4667 // semantics) but render in the default transcript — the keyboard user
4668 // should see what arrived. The <channel> tag in UserTextMessage handles
4669 // the actual rendering.
4670 if (
4671 (feature('KAIROS') || feature('KAIROS_CHANNELS')) &&
4672 message.origin?.kind === 'channel'
4673 )
4674 return true
4675 return false
4676 }
4677 if (message.isVisibleInTranscriptOnly && !isTranscriptMode) return false
4678 return true
4679}
4680
4681export function isThinkingMessage(message: Message): boolean {
4682 if (message.type !== 'assistant') return false

Callers 1

MessagesImplFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected