RAC Tree (#5756)
* start scaffolding
* some planning
* got the nested rendering to work
* saving progress
* more musings
* finally got static and dynamic working
* tentative modifications to useTreeState and fix cases with static renderProps functions
* updating so Content has renderProps instead
* Fix dynamic case
* clean up
* add treegridlist hooks and convert list stuff to use it
* fix expanding and collapsing
* update the collection processing so that node index info ignores existence of content nodes
* fix flattened row array
now that we are iterating over every tree item, we need to check if a rows parent is in the expanded key AND is also in the flattened row list. This is essentially checking if every parent above it is expanded as well since that is the only way its immediate parent would be in the flattened row list
* move code for expanding/collapsing and other treegrid stuff into useGridListItem
this is because we need to stop the grid list keyboard navigation if we are going to perform an expand or collapse but cant do so since it is a capturing listener. An alternative is to copy all the code from useGridListItem as is to useTreeGridListItem but that can be discussed.
* adding renderProps for expanded,level,etc and supporting empty state
* some cleanup
* fix TS strict
* add a checkbox to story and get rid of row double labelling
* update styles
* fix some styling and lint
* forgot to make the tree package not private
* updating story as per testing review
* add support for row expansion when clicking the row, onAction, and linkaction
* first batch of tests, basic interactions common to gridlist
* Add ability to set disabledBehavior and default it to selection
* Add empty state test
* making data-expanded only appear on rows that are actually expandable
* update note from chevron focus skipping exploration and save progress
* add keyboard interaction tests
* clean up some todos
* fix defaultSlot
* fixing tests and some final cleanup
* Update packages/react-aria-components/src/Tree.tsx
Co-authored-by: Reid Barber <reid@reidbarber.com>
* addressing some review comments
added test util and updating some tests for consistency
* forgot one review comment
* make test file tsx
---------
Co-authored-by: Reid Barber <reid@reidbarber.com>