MCPcopy Create free account
hub / github.com/CodeGraphContext/CodeGraphContext / fn

Function fn

website/src/components/FlowchartSVG.tsx:269–274  ·  view source on GitHub ↗
(e: WheelEvent)

Source from the content-addressed store, hash-verified

267 const el = svgRef.current;
268 if (!el) return;
269 const fn = (e: WheelEvent) => {
270 e.preventDefault();
271 setZoom((z) =>
272 Math.min(4, Math.max(0.04, z * (e.deltaY > 0 ? 0.92 : 1.08))),
273 );
274 };
275 el.addEventListener("wheel", fn, { passive: false });
276 return () => el.removeEventListener("wheel", fn);
277 }, []);

Callers 15

dispatch_by_stringFunction · 0.85
dynamic_import_callFunction · 0.85
wrapperFunction · 0.85
executeMethod · 0.85
mapFunction · 0.85
flatMapFunction · 0.85
mapErrorFunction · 0.85
wrapMethod · 0.85
tryCatchFunction · 0.85
tryCatchAsyncFunction · 0.85
memoizeFunction · 0.85
debounceFunction · 0.85

Calls 1

maxMethod · 0.80

Tested by

no test coverage detected