Skip to content

GridLayout's minSpace option has an unexpected/ambiguous behavior #9869

@GustavoHenriqueP

Description

@GustavoHenriqueP

Provide a general summary of the issue here

In Virtualizer's docs, the GridLayout.minSpace option is described as "The minimum space required between items.".

Due to the use of the word between, also used in the description of the ListLayout.gap option, I believe it is understood that this option would function like a CSS's grid layout (minimum) gap. But what happens is that this space is distributed between the inner and outer margins of the grid.

🤔 Expected Behavior?

The GridLayout.minSpace option apply only inner gaps between the grid items.

😯 Current Behavior

The GridLayout.minSpace option is distributing its Size between inner and outer gaps.

💁 Possible Solution

I don't know if this behavior was intentional, but would be really helpful to allow an option to apply only inner gaps on the grid, mimicking the CSS grid layout behavior.

🔦 Context

No response

🖥️ Steps to Reproduce

https://codesandbox.io/p/devbox/58q8x8?migrateFrom=9mk59p

Version

RAC 1.16.0

What browsers are you seeing the problem on?

Chrome

If other, please specify.

No response

What operating system are you using?

Windows 11

🧢 Your Company/Team

No response

🕷 Tracking Issue

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    Status

    🩺 To Triage

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions