mirror of
https://github.com/infiniflow/ragflow.git
synced 2025-12-24 07:26:47 +08:00
### What problem does this PR solve? Feat: Use memo to wrap canvas nodes to improve fluency #3221 ### Type of change - [x] New Feature (non-breaking change which adds functionality)
This commit is contained in:
@ -5,12 +5,13 @@ import { Handle, NodeProps, Position } from '@xyflow/react';
|
||||
import { Flex } from 'antd';
|
||||
import classNames from 'classnames';
|
||||
import { get } from 'lodash';
|
||||
import { memo } from 'react';
|
||||
import { RightHandleStyle } from './handle-icon';
|
||||
import { useBuildCategorizeHandlePositions } from './hooks';
|
||||
import styles from './index.less';
|
||||
import NodeHeader from './node-header';
|
||||
|
||||
export function CategorizeNode({
|
||||
export function InnerCategorizeNode({
|
||||
id,
|
||||
data,
|
||||
selected,
|
||||
@ -66,3 +67,5 @@ export function CategorizeNode({
|
||||
</section>
|
||||
);
|
||||
}
|
||||
|
||||
export const CategorizeNode = memo(InnerCategorizeNode);
|
||||
|
||||
Reference in New Issue
Block a user