@@ -3,13 +3,10 @@ import type { FC } from 'react'
3
3
import { useEffect , useState } from 'react'
4
4
import cn from 'classnames'
5
5
import BlockIcon from './block-icon'
6
- import CodeEditor from './code-editor'
7
- import { CodeLanguage } from '@/types/app'
8
6
import AlertCircle from '@/app/components/base/icons/line/alert-circle'
9
7
import AlertTriangle from '@/app/components/base/icons/line/alert-triangle'
10
8
import Loading02 from '@/app/components/base/icons/line/loading-02'
11
9
import CheckCircle from '@/app/components/base/icons/line/check-circle'
12
- import ChevronRight from '@/app/components/base/icons/line/chevron-right'
13
10
import type { NodeTracing } from '@/types/app'
14
11
15
12
type Props = {
@@ -52,12 +49,6 @@ const NodePanel: FC<Props> = ({ nodeInfo, hideInfo = false }) => {
52
49
) }
53
50
onClick = { ( ) => setCollapseState ( ! collapseState ) }
54
51
>
55
- < ChevronRight
56
- className = { cn (
57
- 'shrink-0 w-3 h-3 mr-1 text-gray-400 transition-all group-hover:text-gray-500' ,
58
- ! collapseState && 'rotate-90' ,
59
- ) }
60
- />
61
52
< BlockIcon size = { hideInfo ? 'xs' : 'sm' } className = { cn ( 'shrink-0 mr-2' , hideInfo && '!mr-1' ) } type = { nodeInfo . node_type } toolIcon = { nodeInfo . extras ?. icon || nodeInfo . extras } />
62
53
< div className = { cn (
63
54
'grow text-gray-700 text-[13px] leading-[16px] font-semibold truncate' ,
@@ -82,48 +73,6 @@ const NodePanel: FC<Props> = ({ nodeInfo, hideInfo = false }) => {
82
73
</ div >
83
74
) }
84
75
</ div >
85
- { ! collapseState && (
86
- < div className = 'pb-2' >
87
- < div className = { cn ( 'px-[10px] py-1' , hideInfo && '!px-2 !py-0.5' ) } >
88
- { nodeInfo . status === 'failed' && (
89
- < div className = 'px-3 py-[10px] bg-[#fef3f2] rounded-lg border-[0.5px] border-[rbga(0,0,0,0.05)] text-xs leading-[18px] text-[#d92d20] shadow-xs' > { nodeInfo . error } </ div >
90
- ) }
91
- </ div >
92
- { nodeInfo . inputs && (
93
- < div className = { cn ( 'px-[10px] py-1' , hideInfo && '!px-2 !py-0.5' ) } >
94
- < CodeEditor
95
- readOnly
96
- title = { < div > INPUT</ div > }
97
- language = { CodeLanguage . json }
98
- value = { nodeInfo . inputs }
99
- isJSONStringifyBeauty
100
- />
101
- </ div >
102
- ) }
103
- { nodeInfo . process_data && (
104
- < div className = { cn ( 'px-[10px] py-1' , hideInfo && '!px-2 !py-0.5' ) } >
105
- < CodeEditor
106
- readOnly
107
- title = { < div > PROCESS DATA</ div > }
108
- language = { CodeLanguage . json }
109
- value = { nodeInfo . process_data }
110
- isJSONStringifyBeauty
111
- />
112
- </ div >
113
- ) }
114
- { nodeInfo . outputs && (
115
- < div className = { cn ( 'px-[10px] py-1' , hideInfo && '!px-2 !py-0.5' ) } >
116
- < CodeEditor
117
- readOnly
118
- title = { < div > OUTPUT</ div > }
119
- language = { CodeLanguage . json }
120
- value = { nodeInfo . outputs }
121
- isJSONStringifyBeauty
122
- />
123
- </ div >
124
- ) }
125
- </ div >
126
- ) }
127
76
</ div >
128
77
</ div >
129
78
)
0 commit comments