chore(react): cleanup exports
This commit is contained in:
@@ -6,11 +6,11 @@ import { shallow } from 'zustand/shallow';
|
||||
import { getNodesBounds, getBoundsOfRects, XYMinimap, type Rect, type XYMinimapInstance } from '@xyflow/system';
|
||||
|
||||
import { useStore, useStoreApi } from '../../hooks/useStore';
|
||||
import Panel from '../../components/Panel';
|
||||
import { Panel } from '../../components/Panel';
|
||||
import type { ReactFlowState } from '../../types';
|
||||
|
||||
import type { MiniMapProps } from './types';
|
||||
import MiniMapNodes from './MiniMapNodes';
|
||||
import type { MiniMapProps } from './types';
|
||||
|
||||
const defaultWidth = 200;
|
||||
const defaultHeight = 150;
|
||||
@@ -37,7 +37,7 @@ const selector = (s: ReactFlowState) => {
|
||||
|
||||
const ARIA_LABEL_KEY = 'react-flow__minimap-desc';
|
||||
|
||||
function MiniMap({
|
||||
function MiniMapComponent({
|
||||
style,
|
||||
className,
|
||||
nodeStrokeColor,
|
||||
@@ -171,6 +171,6 @@ function MiniMap({
|
||||
);
|
||||
}
|
||||
|
||||
MiniMap.displayName = 'MiniMap';
|
||||
MiniMapComponent.displayName = 'MiniMap';
|
||||
|
||||
export default memo(MiniMap);
|
||||
export const MiniMap = memo(MiniMapComponent);
|
||||
|
||||
@@ -3,7 +3,7 @@ import cc from 'classcat';
|
||||
|
||||
import type { MiniMapNodeProps } from './types';
|
||||
|
||||
function MiniMapNode({
|
||||
function MiniMapNodeComponent({
|
||||
id,
|
||||
x,
|
||||
y,
|
||||
@@ -42,4 +42,4 @@ function MiniMapNode({
|
||||
);
|
||||
}
|
||||
|
||||
export default memo(MiniMapNode);
|
||||
export const MiniMapNode = memo(MiniMapNodeComponent);
|
||||
|
||||
@@ -5,8 +5,8 @@ import { NodeOrigin, getNodePositionWithOrigin } from '@xyflow/system';
|
||||
import { shallow } from 'zustand/shallow';
|
||||
|
||||
import { useStore } from '../../hooks/useStore';
|
||||
import { MiniMapNode } from './MiniMapNode';
|
||||
import type { ReactFlowState } from '../../types';
|
||||
import MiniMapNode from './MiniMapNode';
|
||||
import type { MiniMapNodes as MiniMapNodesProps, GetMiniMapNodeAttribute, MiniMapNodeProps } from './types';
|
||||
|
||||
declare const window: any;
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
export { default as MiniMap } from './MiniMap';
|
||||
export { MiniMap } from './MiniMap';
|
||||
export * from './types';
|
||||
|
||||
Reference in New Issue
Block a user