Skip to content

[BUG] Layout issues using useWindowScroll and a header component #1257

@blynx

Description

@blynx

Describe the bug

When using a Header (via components prop) in a Virtuoso composition and switching useWindowScroll to true, will cause layout issues as seen in the linked codesandbox:

In the initial state, the first group header will be directly sticky and at the top of the box instead of the desired global header. The global header is covered by the first group header.

Reproduction

https://codesandbox.io/p/sandbox/practical-sid-pwywgc

To Reproduce

  • Build a basic grouped Virtuoso composition
  • add a Header (via components prop)
  • set useWindowScroll to true

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions