MCPcopy
hub / github.com/codeaashu/claude-code / scrollMutated

Function scrollMutated

src/ink/components/ScrollBox.tsx:103–117  ·  view source on GitHub ↗
(el: DOMElement)

Source from the content-addressed store, hash-verified

101 for (const l of listenersRef.current) l();
102 };
103 function scrollMutated(el: DOMElement): void {
104 // Signal background intervals (IDE poll, LSP poll, GCS fetch, orphan
105 // check) to skip their next tick — they compete for the event loop and
106 // contributed to 1402ms max frame gaps during scroll drain.
107 markScrollActivity();
108 markDirty(el);
109 markCommitStart();
110 notify();
111 if (renderQueuedRef.current) return;
112 renderQueuedRef.current = true;
113 queueMicrotask(() => {
114 renderQueuedRef.current = false;
115 scheduleRenderFrom(el);
116 });
117 }
118 useImperativeHandle(ref, (): ScrollBoxHandle => ({
119 scrollTo(y: number) {
120 const el = domRef.current;

Callers 3

scrollToFunction · 0.85
scrollToElementFunction · 0.85
scrollByFunction · 0.85

Calls 5

markScrollActivityFunction · 0.85
markDirtyFunction · 0.85
markCommitStartFunction · 0.85
notifyFunction · 0.85
scheduleRenderFromFunction · 0.85

Tested by

no test coverage detected