MCPcopy Create free account
hub / github.com/Alphanimble/htmlstream / turnLabel

Function turnLabel

demo/chat/SessionSidebar.tsx:32–36  ·  view source on GitHub ↗
(message: ChatMessage, index: number)

Source from the content-addressed store, hash-verified

30}
31
32function turnLabel(message: ChatMessage, index: number): string {
33 const plain = message.content.replace(/<[^>]+>/g, " ").replace(/\s+/g, " ").trim();
34 const snippet = plain.slice(0, 48) || "(empty)";
35 return `#${index + 1} · ${snippet}${plain.length > 48 ? "…" : ""}`;
36}
37
38export function SessionSidebar({
39 sessions,

Callers 1

SessionSidebarFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected