Skip to content

Commit f8f481d

Browse files
[tree view] Improve the typing of the item checkbox slotProps
1 parent d353035 commit f8f481d

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

packages/x-tree-view/src/TreeItem/TreeItem.types.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,11 @@ export interface TreeItemSlotProps extends TreeItemIconSlotProps {
7171
content?: SlotComponentProps<'div', {}, {}>;
7272
groupTransition?: SlotComponentPropsFromProps<TransitionProps, {}, {}>;
7373
iconContainer?: SlotComponentProps<'div', {}, {}>;
74-
checkbox?: SlotComponentProps<'button', {}, {}>;
74+
checkbox?: SlotComponentProps<
75+
React.ElementType<React.HTMLAttributes<HTMLButtonElement> & { visible?: boolean }>,
76+
{},
77+
{}
78+
>;
7579
label?: SlotComponentProps<'div', {}, {}>;
7680
labelInput?: SlotComponentProps<'input', {}, {}>;
7781
dragAndDropOverlay?: SlotComponentProps<'div', {}, {}>;

0 commit comments

Comments
 (0)