MCPcopy Index your code
hub / github.com/codeaashu/claude-code / clearHighlights

Function clearHighlights

web/components/file-viewer/SearchBar.tsx:136–144  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

134 }, [query, isRegex, caseSensitive, currentMatch, totalMatches]);
135
136 function clearHighlights() {
137 if (!containerRef.current) return;
138 const marks = containerRef.current.querySelectorAll("mark.search-highlight");
139 marks.forEach((mark) => {
140 mark.replaceWith(mark.textContent ?? "");
141 });
142 // Normalize text nodes
143 containerRef.current.normalize();
144 }
145
146 const goNext = () => {
147 setCurrentMatch((c) => (c >= totalMatches ? 1 : c + 1));

Callers 2

SearchBarFunction · 0.85
handleKeyDownFunction · 0.85

Calls 1

forEachMethod · 0.80

Tested by

no test coverage detected