MCPcopy Create free account
hub / github.com/Acode-Foundation/Acode / scrollContainer

Function scrollContainer

src/handlers/editorFileTab.js:396–405  ·  view source on GitHub ↗

* Scrolls the container using animation frame

()

Source from the content-addressed store, hash-verified

394 * Scrolls the container using animation frame
395 */
396function scrollContainer() {
397 return animate();
398
399 function animate() {
400 const scroll = getScroll();
401 if (!scroll) return;
402 prevScrollLeft = $parent.scrollLeft += scroll;
403 animationFrame = requestAnimationFrame(animate);
404 }
405}
406
407/**
408 * Gets the client position from the event

Callers 1

onDragFunction · 0.85

Calls 1

animateFunction · 0.70

Tested by

no test coverage detected