Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[TreeView] Create an "Item customization" doc page that uses useTreeItem2 and TreeItem2 #13161

Open
flaviendelangle opened this issue May 17, 2024 · 0 comments
Labels
component: tree view TreeView, TreeItem. This is the name of the generic UI component, not the React module! docs Improvements or additions to the documentation

Comments

@flaviendelangle
Copy link
Member

flaviendelangle commented May 17, 2024

The TreeItem2 component and useTreeItem2 hooks have been released during the v7 beta and will replace the TreeItem component in the next major (v8).

We lack a proper documentation about these new elements.
The scope of this issue is:

  1. Present each slot (2 example per slot on for slots and one for slotProps, similar to this page)
  2. Present useTreeItem2 and how to use it to replace a ContentComponent prop on TreeItem
  3. Present how to disable some default behaviors using .defaultMuiPrevented
  4. Link this new page in "Simple Tree View => Customization" and "Rich Tree View => Customization"
  5. Show how to access the item object inside the Tree Item component (see [TreeView] Tree Item do not receive the item defined in RichTreeViewProps['item'] #12697)

Search keywords:

@flaviendelangle flaviendelangle added docs Improvements or additions to the documentation component: tree view TreeView, TreeItem. This is the name of the generic UI component, not the React module! labels May 17, 2024
@flaviendelangle flaviendelangle changed the title [TreeView] Create a "Items customization" that uses useTreeItem2 and TreeItem2 [TreeView] Create an "Item customization" doc page that uses useTreeItem2 and TreeItem2 May 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: tree view TreeView, TreeItem. This is the name of the generic UI component, not the React module! docs Improvements or additions to the documentation
Projects
None yet
Development

No branches or pull requests

1 participant