Repository navigation
Proper way to add the row gap #834
Unanswered
cojoclaudiu
asked this question in
Q&A
Replies: 3 comments
|
I think this is the fix of my issue https://virtuoso.dev/troubleshooting/#list-does-not-scroll-to-the-bottom--items-jump-around |
0 replies
|
I use this method to add a gap between elements ( this may not necessarily be the optimal method )
const Wrapper = (props) => <div {...props} className='wrapper' />
<Virtuoso
components={{ Item: Wrapper }}
itemContent={ /* content */}
/>
.wrapper:not([data-index='0']) {
padding-top: 0.6rem;
} |
0 replies
|
How I did it (don't use <Virtuoso
data={images}
itemContent={(index, src) => {
return <img src={src} alt="" style={{
paddingTop: index === 0 ? 0 : 8,
}}/>;
}}
/> |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Hello, what is the proper way to add the row gap between elements?
At the moment I'm using margin bottom to all the elements in the list but when I scroll to the last element I get a "little jump" of the scroll if I try to scroll more.
All reactions