Protected ReadonlyrenderedRendered text by the object it was rendered for, reused while its source text is unchanged.
Protected Static ReadonlyWORD_VS Code's default editor.wordSeparators; whitespace separates words as well.
ProtectedcollectBuilds the regular expression shared by model matching and DOM highlighting.
undefined for an empty query or an invalid regular expression.
All non-empty occurrences of regexp in text, in order.
All matches in tree order: request row, then response row, content parts in order, offsets ascending.
ProtectedgetThe text of markdown rendered the way useMarkdownRendering renders it, cached per owner.
ProtectedgetThe request text as rendered by ChatRequestRender: agent, variable and function mentions as labels,
text parts as inline markdown, inline image parts skipped.
ProtectedgetThe searchable text of a response part as it is rendered, or undefined for kinds that are not searched
(tool calls, reasoning, progress, informational content, which the chat does not render, ...).
ProtectedwrapRestricts source to whole words the way VS Code does: each end of a match must be the end of the text, next
to a word separator, or itself a word separator. Unlike \b, this also works for queries such as C++ or foo().
Computes find matches over a chat session model. Only the displayed branch (
model.getRequests()) is searched.Text is searched as it is rendered, not as it is stored: markdown is rendered the way the chat renders it and its text read with ChatFindText, the same way the highlighter reads the mounted DOM, so match offsets are valid in both. Subclass and override getSearchableText to search additional content kinds.