Skip to content

Commit 95b2969

Browse files
committed
rename to avoid name ambiguity
Signed-off-by: Teo Koon Peng <[email protected]>
1 parent c7902fa commit 95b2969

17 files changed

+75
-73
lines changed

diagram-editor/frontend/nodes/buffer-access-node.tsx

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,9 @@ import type { OperationNode } from '.';
33
import BaseNode from './base-node';
44
import { BufferAccessIcon } from './icons';
55

6-
function BufferAccessNode(props: NodeProps<OperationNode<'buffer_access'>>) {
6+
function BufferAccessNodeComp(
7+
props: NodeProps<OperationNode<'buffer_access'>>,
8+
) {
79
return (
810
<BaseNode
911
{...props}
@@ -14,4 +16,4 @@ function BufferAccessNode(props: NodeProps<OperationNode<'buffer_access'>>) {
1416
);
1517
}
1618

17-
export default BufferAccessNode;
19+
export default BufferAccessNodeComp;

diagram-editor/frontend/nodes/buffer-node.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import type { OperationNode } from '.';
33
import BaseNode from './base-node';
44
import { BufferIcon } from './icons';
55

6-
function BufferNode(props: NodeProps<OperationNode<'buffer'>>) {
6+
function BufferNodeComp(props: NodeProps<OperationNode<'buffer'>>) {
77
return (
88
<BaseNode
99
{...props}
@@ -14,4 +14,4 @@ function BufferNode(props: NodeProps<OperationNode<'buffer'>>) {
1414
);
1515
}
1616

17-
export default BufferNode;
17+
export default BufferNodeComp;

diagram-editor/frontend/nodes/fork-clone-node.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import type { OperationNode } from '.';
33
import BaseNode from './base-node';
44
import { ForkCloneIcon } from './icons';
55

6-
function ForkCloneNode(props: NodeProps<OperationNode<'fork_clone'>>) {
6+
function ForkCloneNodeComp(props: NodeProps<OperationNode<'fork_clone'>>) {
77
return (
88
<BaseNode
99
{...props}
@@ -14,4 +14,4 @@ function ForkCloneNode(props: NodeProps<OperationNode<'fork_clone'>>) {
1414
);
1515
}
1616

17-
export default ForkCloneNode;
17+
export default ForkCloneNodeComp;

diagram-editor/frontend/nodes/fork-result-node.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import type { OperationNode } from '.';
33
import BaseNode from './base-node';
44
import { ForkResultIcon } from './icons';
55

6-
function ForkResultNode(props: NodeProps<OperationNode<'fork_result'>>) {
6+
function ForkResultNodeComp(props: NodeProps<OperationNode<'fork_result'>>) {
77
return (
88
<BaseNode
99
{...props}
@@ -14,4 +14,4 @@ function ForkResultNode(props: NodeProps<OperationNode<'fork_result'>>) {
1414
);
1515
}
1616

17-
export default ForkResultNode;
17+
export default ForkResultNodeComp;

diagram-editor/frontend/nodes/index.ts

Lines changed: 38 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,26 @@
11
import type { DiagramOperation } from '../types/api';
22
import type { Node } from '../types/react-flow';
3-
import BufferAccessNode from './buffer-access-node';
4-
import BufferNode from './buffer-node';
5-
import ForkCloneNode from './fork-clone-node';
6-
import ForkResultNode from './fork-result-node';
7-
import JoinNode from './join-node';
8-
import ListenNode from './listen-node';
9-
import NodeNode from './node-node';
10-
import ScopeNode from './scope-node';
11-
import SectionNode, {
12-
SectionBufferNode,
13-
SectionInputNode,
3+
import BufferAccessNodeComp from './buffer-access-node';
4+
import BufferNodeComp from './buffer-node';
5+
import ForkCloneNodeComp from './fork-clone-node';
6+
import ForkResultNodeComp from './fork-result-node';
7+
import JoinNodeComp from './join-node';
8+
import ListenNodeComp from './listen-node';
9+
import NodeNodeComp from './node-node';
10+
import ScopeNodeComp from './scope-node';
11+
import SectionNodeComp, {
12+
SectionBufferNodeComp,
13+
SectionInputNodeComp,
1414
type SectionInterfaceNode,
15-
SectionOutputNode,
15+
SectionOutputNodeComp,
1616
} from './section-node';
17-
import SerializedJoinNode from './serialized-join-node';
18-
import SplitNode from './split-node';
19-
import StartNode from './start-node';
20-
import StreamOutNode from './stream-out-node';
21-
import TerminateNode from './terminate-node';
22-
import TransformNode from './transform-node';
23-
import UnzipNode from './unzip-node';
17+
import SerializedJoinNodeComp from './serialized-join-node';
18+
import SplitNodeComp from './split-node';
19+
import StartNodeComp from './start-node';
20+
import StreamOutNodeComp from './stream-out-node';
21+
import TerminateNodeComp from './terminate-node';
22+
import TransformNodeComp from './transform-node';
23+
import UnzipNodeComp from './unzip-node';
2424

2525
export * from './icons';
2626
export type {
@@ -39,25 +39,25 @@ export const START_ID = '__builtin_start__';
3939
export const TERMINATE_ID = '__builtin_terminate__';
4040

4141
export const NODE_TYPES = {
42-
start: StartNode,
43-
terminate: TerminateNode,
44-
node: NodeNode,
45-
section: SectionNode,
46-
sectionInput: SectionInputNode,
47-
sectionOutput: SectionOutputNode,
48-
sectionBuffer: SectionBufferNode,
49-
fork_clone: ForkCloneNode,
50-
unzip: UnzipNode,
51-
fork_result: ForkResultNode,
52-
split: SplitNode,
53-
join: JoinNode,
54-
serialized_join: SerializedJoinNode,
55-
transform: TransformNode,
56-
buffer: BufferNode,
57-
buffer_access: BufferAccessNode,
58-
listen: ListenNode,
59-
scope: ScopeNode,
60-
stream_out: StreamOutNode,
42+
start: StartNodeComp,
43+
terminate: TerminateNodeComp,
44+
node: NodeNodeComp,
45+
section: SectionNodeComp,
46+
sectionInput: SectionInputNodeComp,
47+
sectionOutput: SectionOutputNodeComp,
48+
sectionBuffer: SectionBufferNodeComp,
49+
fork_clone: ForkCloneNodeComp,
50+
unzip: UnzipNodeComp,
51+
fork_result: ForkResultNodeComp,
52+
split: SplitNodeComp,
53+
join: JoinNodeComp,
54+
serialized_join: SerializedJoinNodeComp,
55+
transform: TransformNodeComp,
56+
buffer: BufferNodeComp,
57+
buffer_access: BufferAccessNodeComp,
58+
listen: ListenNodeComp,
59+
scope: ScopeNodeComp,
60+
stream_out: StreamOutNodeComp,
6161
};
6262

6363
export type NodeTypes = keyof typeof NODE_TYPES;

diagram-editor/frontend/nodes/join-node.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import type { OperationNode } from '.';
33
import BaseNode from './base-node';
44
import { JoinIcon } from './icons';
55

6-
function JoinNode(props: NodeProps<OperationNode<'join'>>) {
6+
function JoinNodeComp(props: NodeProps<OperationNode<'join'>>) {
77
return (
88
<BaseNode
99
{...props}
@@ -14,4 +14,4 @@ function JoinNode(props: NodeProps<OperationNode<'join'>>) {
1414
);
1515
}
1616

17-
export default JoinNode;
17+
export default JoinNodeComp;

diagram-editor/frontend/nodes/listen-node.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import type { OperationNode } from '.';
33
import BaseNode from './base-node';
44
import { ListenIcon } from './icons';
55

6-
function ListenNode(props: NodeProps<OperationNode<'listen'>>) {
6+
function ListenNodeComp(props: NodeProps<OperationNode<'listen'>>) {
77
return (
88
<BaseNode
99
{...props}
@@ -14,4 +14,4 @@ function ListenNode(props: NodeProps<OperationNode<'listen'>>) {
1414
);
1515
}
1616

17-
export default ListenNode;
17+
export default ListenNodeComp;

diagram-editor/frontend/nodes/node-node.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import type { OperationNode } from '.';
33
import BaseNode from './base-node';
44
import { NodeIcon } from './icons';
55

6-
function NodeNode(props: NodeProps<OperationNode<'node'>>) {
6+
function NodeNodeComp(props: NodeProps<OperationNode<'node'>>) {
77
return (
88
<BaseNode
99
{...props}
@@ -14,4 +14,4 @@ function NodeNode(props: NodeProps<OperationNode<'node'>>) {
1414
);
1515
}
1616

17-
export default NodeNode;
17+
export default NodeNodeComp;

diagram-editor/frontend/nodes/scope-node.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import { Box, useTheme } from '@mui/material';
22
import { Handle, type NodeProps, Position } from '@xyflow/react';
33
import type { OperationNode } from '.';
44

5-
function ScopeNode({
5+
function ScopeNodeComp({
66
isConnectable,
77
sourcePosition = Position.Bottom,
88
targetPosition = Position.Top,
@@ -38,4 +38,4 @@ function ScopeNode({
3838
);
3939
}
4040

41-
export default ScopeNode;
41+
export default ScopeNodeComp;

diagram-editor/frontend/nodes/section-node.tsx

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ export type SectionInterfaceNode =
3333
| SectionOutputNode
3434
| SectionBufferNode;
3535

36-
export function SectionNode(props: NodeProps<OperationNode<'section'>>) {
36+
export function SectionNodeComp(props: NodeProps<OperationNode<'section'>>) {
3737
const label = isSectionBuilder(props.data.op)
3838
? props.data.op.builder
3939
: props.data.op.template;
@@ -47,14 +47,14 @@ export function SectionNode(props: NodeProps<OperationNode<'section'>>) {
4747
);
4848
}
4949

50-
export default SectionNode;
50+
export default SectionNodeComp;
5151

5252
export type SectionInterfaceNodeTypes =
5353
| 'sectionInput'
5454
| 'sectionOutput'
5555
| 'sectionBuffer';
5656

57-
export function SectionInputNode(props: NodeProps<SectionInputNode>) {
57+
export function SectionInputNodeComp(props: NodeProps<SectionInputNode>) {
5858
return (
5959
<BaseNode
6060
{...props}
@@ -66,7 +66,7 @@ export function SectionInputNode(props: NodeProps<SectionInputNode>) {
6666
);
6767
}
6868

69-
export function SectionOutputNode(props: NodeProps<SectionOutputNode>) {
69+
export function SectionOutputNodeComp(props: NodeProps<SectionOutputNode>) {
7070
return (
7171
<BaseNode
7272
{...props}
@@ -78,7 +78,7 @@ export function SectionOutputNode(props: NodeProps<SectionOutputNode>) {
7878
);
7979
}
8080

81-
export function SectionBufferNode(props: NodeProps<SectionBufferNode>) {
81+
export function SectionBufferNodeComp(props: NodeProps<SectionBufferNode>) {
8282
return (
8383
<BaseNode
8484
{...props}

0 commit comments

Comments
 (0)