primevue icon indicating copy to clipboard operation
primevue copied to clipboard

VirtualScroller: support for variable items sizes

Open vvy6791 opened this issue 2 years ago • 4 comments

Describe the feature you would like to see added

"itemSize" is required property for the VirtualScroller component. That means that all items must have a fixed size.

But what about variable item size? For example item contains a text of variable length, so height of text will be also variable. There are other components for Vue exists, that realized this fiture. Those componets has properties such as minSize (for minimal value) or estimatedSize (for average value) instead of fixed itemSize.

Is your feature request related to a problem?

PrimeVue has no any component that can scroll a list of a lot of items of variable size.

Describe the solution you'd like

Improve the VirtualScroller to support items of variable size. Or create other component for Vue 3 that will suport items of variable size.

It is highly desirable that component will have a method, that can determine the specific item offset (in px) ralative to the edges of the VirtualScroller visible scroll area. It's need for detect is the item visible to user now or not (or what part of item is visible).

Describe alternatives you have considered

https://github.com/Akryum/vue-virtual-scroller https://github.com/reactjser/vue3-virtual-scroll-list

Additional context

No response

vvy6791 avatar Oct 31 '22 18:10 vvy6791