LearnNewsExamplesServices
Frontmatter
id9386
titleE2E: Add min velocity threshold to Grid Predictive Scrolling
stateClosed
labels
aiperformancegrid
assigneestobiu
createdAtMar 7, 2026, 11:44 PM
updatedAtMar 7, 2026, 11:47 PM
githubUrlhttps://github.com/neomjs/neo/issues/9386
authortobiu
commentsCount1
parentIssue9380
subIssues[]
subIssuesCompleted0
subIssuesTotal0
blockedBy[]
blocking[]
closedAtMar 7, 2026, 11:47 PM

E2E: Add min velocity threshold to Grid Predictive Scrolling

Closed v12.1.0 aiperformancegrid
tobiu
tobiu commented on Mar 7, 2026, 11:44 PM

This ticket tracks the implementation of a minimum velocity threshold for Predictive Delta Injection in ScrollManager.

Goal: Fix the "jumpy" and "flickering" rendering behavior during low-velocity scrolling (e.g., mousewheel).

Tasks:

  1. Update syncGridBody to require a minimum scrollVelocity (e.g., > 0.5 px/ms) before applying the kinematic prediction math.
  2. For velocities below the threshold, fall back to rendering the exact, actual scrollTop.

This ensures that prediction only engages during deliberate, fast thumb drags where the worker pipeline lag actually causes a visible gap, preserving 1:1 pixel accuracy for precise scrolling.

This is a sub-task of the Epic to resolve Grid Scroll Thrashing.

tobiu added the ai label on Mar 7, 2026, 11:44 PM
tobiu added the performance label on Mar 7, 2026, 11:44 PM
tobiu added the grid label on Mar 7, 2026, 11:44 PM
tobiu added parent issue #9380 on Mar 7, 2026, 11:44 PM
tobiu referenced in commit 7e62b15 - "fix: Add min velocity threshold to Grid Predictive Scrolling (#9386) on Mar 7, 2026, 11:46 PM
tobiu assigned to @tobiu on Mar 7, 2026, 11:46 PM
tobiu
tobiu Mar 7, 2026, 11:46 PM

Input from Gemini 3.1 Pro:

✦ I have implemented the minimum velocity threshold in ScrollManager.

The kinematic prediction math now only engages if Math.abs(scrollVelocity) > 0.5. For low-velocity scrolling (like a typical mousewheel tick), the Grid simply renders the exact, real-time scrollTop of the native container. This completely eliminates the decoupling effect and fixes the "jumpy/flickering" visual regression for precise scroll movements.

Closing this ticket as complete. We can now proceed with extracting E2E benchmark logs or tackling the directional buffer expansion for massive thumb jumps.

tobiu closed this issue on Mar 7, 2026, 11:47 PM