Hacktoberfest 2026:維護者為十月標記出來的 issue,仍然開放、適合新手。 瀏覽 Hacktoberfest issue

Scroll lag / stutter when page zoom is exactly 100%

未關閉
#1,099 0 則留言 1 個 reaction 已指派 0 人 在 GitHub 檢視

維護者通常 1 天內回覆

還沒有人認領這個 Issue。

評估

難度
4/5
預估耗時
3-5 天
新手友好度
35/100
Issue 類型
缺陷
描述清晰度
需要釐清
活躍度
停滯
技術堆疊
typescript

研究方向

從 FE-WMS 儲存庫中連結的 Storybook 重現開始,使用 @tanstack/virtual 3.13.5 比較瀏覽器縮放比例為 100% 與 90% 和 110% 時的捲動效果。調查虛擬清單周圍回報的測量和版面配置行為,然後驗證在這三個縮放級別下捲動是否都流暢且一致。

由索引模型根據 Issue 內容生成。

描述

Describe the bug
🐛 Bug: Scroll lag / stutter when page zoom is exactly 100%

Description

When using @tanstack/virtual, scrolling becomes noticeably laggy/stuttery if the browser page zoom is set to 100% (default).
Interestingly, the issue disappears and scrolling becomes smooth again when changing the page zoom to 90% or 110%.

This behavior is consistently reproducible and seems to be tied specifically to the 100% zoom level.


🔁 Steps to Reproduce
  1. Open an app/page that uses @tanstack/virtual
  2. Set browser zoom to 100%
  3. Scroll the virtualized list
    → Observe scroll lag / stuttering
  4. Change browser zoom to 90% or 110%
  5. Scroll again
    → Scrolling becomes smooth

✅ Expected Behavior

Scrolling should be smooth and consistent regardless of browser zoom level (including the default 100%).


❌ Actual Behavior

Scrolling is laggy only when zoom is exactly 100%.
Non-100% zoom levels do not show the issue.


🧠 Additional Notes / Observations
  • This may be related to:

    • sub-pixel rounding
    • layout measurements using fractional values
    • getBoundingClientRect, offsetHeight, or ResizeObserver behavior at 100% zoom
  • The issue occurs even on high-performance machines

  • The problem feels like repeated re-layout or recalculation during scroll


🧪 Environment
  • Library: @tanstack/virtual
  • Browser: (Chrome / Edge / Firefox / Brave)
  • OS: (Windows)
  • tanstack/virtual version: 3.13.5

📎 Reproduction

Please clone the repository and run Storybook to reproduce the issue.
http://localhost:6006/?path=/story/components-datagrid--default

Repository:
https://github.com/quanghiep03198/FE-WMS

The issue can be observed directly in Storybook and is isolated to the usage of @tanstack/virtual.

Your minimal, reproducible example

http://localhost:6006/?path=/story/components-datagrid--default

Steps to reproduce

Scrolling should be smooth and consistent regardless of browser zoom level (including the default 100%).

Expected behavior

When using @tanstack/virtual, scrolling becomes noticeably laggy/stuttery if the browser page zoom is set to 100% (default).
Interestingly, the issue disappears and scrolling becomes smooth again when changing the page zoom to 90% or 110%.

This behavior is consistently reproducible and seems to be tied specifically to the 100% zoom level.

How often does this bug happen?

Every time

Screenshots or Videos

https://www.loom.com/share/8fedb0086ade42d5855986d2951c856d

Platform
  • OS: Windows
  • Browsers: Chrome/Edge/Brave
tanstack-virtual version

3.13.5

TypeScript version

5.7.3

Additional context

When using default page zoom (100%)

Terms & Code of Conduct
  • I agree to follow this project's Code of Conduct
  • I understand that if my bug cannot be reliable reproduced in a debuggable environment, it will probably not be fixed and this issue may even be closed.
主要語言
TypeScript
星號
7.1k
分支
472
平均合併
1 天 1 小時
30 天內合併 PR
11

環境準備

從這裡開始

  1. 先讀完整個 Issue,再讀專案的貢獻指南。
  2. 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
  3. Fork 儲存庫,在一個分支上完成修改。
  4. 送出 Pull Request,並在描述裡引用這個 Issue 編號。

TanStack/virtual 的其他 Issue

查看 TanStack/virtual 的全部 Issue

相似的 Issue

更多 TypeScript Issue

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。