liferay / clay

A web implementation of the Lexicon Experience Language
http://clayui.com
Other
206 stars 470 forks source link

Add Collection implementation with virtualization for Tree #5030

Open matuzalemsteles opened 2 years ago

matuzalemsteles commented 2 years ago

This is an extension of issue #5009, to better understand the context I recommend reading the comments in PR #5013. Following the implementation of the Collection pattern, to finish this first step we need to implement the Tree virtualization functionality for the Collection, this case would be more exclusive for the TreeView but it is quite likely that we can also use it for more complex cases with DropDown that has some nested items.

As a goal this issue should implement the functionality of virtualization in Tree and asynchronous paged loading of data for the useResource hook.

matuzalemsteles commented 2 years ago

I'm adding some thoughts as I'm working on this. One of the big downsides of implementing virtualization for tree based structure is that we need to convert the data to list structure this has some issues I see:

It won't be accessible, as all nodes are rendered in a single list instead of nested and the group semantics doesn't fit here and this is very bad especially for DropDown which has to be accessible.

matuzalemsteles commented 1 year ago

Just to complement, some researches to develop the virtualization mechanism for Tree but without much success and also due to other priorities it was put on hold, see the comments in the PR where I leave information about the first attempt to develop this.

https://github.com/liferay/clay/pull/5045#issuecomment-1249980691

matuzalemsteles commented 1 year ago

LPS Ticket https://liferay.atlassian.net/browse/LPS-190531