Skip to content

Commit

Permalink
[TreeView] Export TreeItem2DragAndDropOverlay and `TreeItem2LabelIn…
Browse files Browse the repository at this point in the history
…put` from the root of each package (#15208)
  • Loading branch information
flaviendelangle authored Oct 31, 2024
1 parent 523fc06 commit 0b6ab89
Show file tree
Hide file tree
Showing 6 changed files with 25 additions and 0 deletions.
2 changes: 2 additions & 0 deletions packages/x-tree-view-pro/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ export * from '@mui/x-tree-view/TreeItem2';
export * from '@mui/x-tree-view/useTreeItem2';
export * from '@mui/x-tree-view/TreeItem2Icon';
export * from '@mui/x-tree-view/TreeItem2Provider';
export * from '@mui/x-tree-view/TreeItem2DragAndDropOverlay';
export * from '@mui/x-tree-view/TreeItem2LabelInput';

export { unstable_resetCleanupTracking } from '@mui/x-tree-view/internals';

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import * as React from 'react';
import PropTypes from 'prop-types';
import { alpha } from '@mui/material/styles';
import { shouldForwardProp } from '@mui/system';
import { TreeItem2DragAndDropOverlayProps } from './TreeItem2DragAndDropOverlay.types';
Expand Down Expand Up @@ -62,4 +63,13 @@ function TreeItem2DragAndDropOverlay(props: TreeItem2DragAndDropOverlayProps) {
return <TreeItem2DragAndDropOverlayRoot {...props} />;
}

TreeItem2DragAndDropOverlay.propTypes = {
// ----------------------------- Warning --------------------------------
// | These PropTypes are generated from the TypeScript type definitions |
// | To update them edit the TypeScript types and run "pnpm proptypes" |
// ----------------------------------------------------------------------
action: PropTypes.oneOf(['make-child', 'move-to-parent', 'reorder-above', 'reorder-below']),
style: PropTypes.object,
} as any;

export { TreeItem2DragAndDropOverlay };
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
import { styled } from '../internals/zero-styled';

/**
* @ignore - internal component.
*/
const TreeItem2LabelInput = styled('input', {
name: 'MuiTreeItem2',
slot: 'LabelInput',
Expand Down
2 changes: 2 additions & 0 deletions packages/x-tree-view/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ export * from './TreeItem2';
export * from './useTreeItem2';
export * from './TreeItem2Icon';
export * from './TreeItem2Provider';
export * from './TreeItem2DragAndDropOverlay';
export * from './TreeItem2LabelInput';

export { unstable_resetCleanupTracking } from './internals/hooks/useInstanceEventHandler';

Expand Down
4 changes: 4 additions & 0 deletions scripts/x-tree-view-pro.exports.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,17 @@
{ "name": "TreeItem2", "kind": "Variable" },
{ "name": "TreeItem2Checkbox", "kind": "Variable" },
{ "name": "TreeItem2Content", "kind": "Variable" },
{ "name": "TreeItem2DragAndDropOverlay", "kind": "Function" },
{ "name": "TreeItem2DragAndDropOverlayProps", "kind": "Interface" },
{ "name": "TreeItem2GroupTransition", "kind": "Variable" },
{ "name": "TreeItem2Icon", "kind": "Function" },
{ "name": "TreeItem2IconContainer", "kind": "Variable" },
{ "name": "TreeItem2IconProps", "kind": "Interface" },
{ "name": "TreeItem2IconSlotProps", "kind": "Interface" },
{ "name": "TreeItem2IconSlots", "kind": "Interface" },
{ "name": "TreeItem2Label", "kind": "Variable" },
{ "name": "TreeItem2LabelInput", "kind": "Variable" },
{ "name": "TreeItem2LabelInputProps", "kind": "Interface" },
{ "name": "TreeItem2Props", "kind": "Interface" },
{ "name": "TreeItem2Provider", "kind": "Function" },
{ "name": "TreeItem2ProviderProps", "kind": "Interface" },
Expand Down
4 changes: 4 additions & 0 deletions scripts/x-tree-view.exports.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,13 +31,17 @@
{ "name": "TreeItem2", "kind": "Variable" },
{ "name": "TreeItem2Checkbox", "kind": "Variable" },
{ "name": "TreeItem2Content", "kind": "Variable" },
{ "name": "TreeItem2DragAndDropOverlay", "kind": "Function" },
{ "name": "TreeItem2DragAndDropOverlayProps", "kind": "Interface" },
{ "name": "TreeItem2GroupTransition", "kind": "Variable" },
{ "name": "TreeItem2Icon", "kind": "Function" },
{ "name": "TreeItem2IconContainer", "kind": "Variable" },
{ "name": "TreeItem2IconProps", "kind": "Interface" },
{ "name": "TreeItem2IconSlotProps", "kind": "Interface" },
{ "name": "TreeItem2IconSlots", "kind": "Interface" },
{ "name": "TreeItem2Label", "kind": "Variable" },
{ "name": "TreeItem2LabelInput", "kind": "Variable" },
{ "name": "TreeItem2LabelInputProps", "kind": "Interface" },
{ "name": "TreeItem2Props", "kind": "Interface" },
{ "name": "TreeItem2Provider", "kind": "Function" },
{ "name": "TreeItem2ProviderProps", "kind": "Interface" },
Expand Down

0 comments on commit 0b6ab89

Please sign in to comment.