diff --git a/web/app/components/workflow/variable-inspect/left.tsx b/web/app/components/workflow/variable-inspect/left.tsx new file mode 100644 index 0000000000..b196f96139 --- /dev/null +++ b/web/app/components/workflow/variable-inspect/left.tsx @@ -0,0 +1,157 @@ +// import { useState } from 'react' +import { + RiArrowRightSLine, + RiErrorWarningFill, + RiLoader2Line, +} from '@remixicon/react' + // import { useStore } from '../store' + import { BlockEnum } from '../types' +import Button from '@/app/components/base/button' +// import ActionButton from '@/app/components/base/action-button' +// import Tooltip from '@/app/components/base/tooltip' +import BlockIcon from '@/app/components/workflow/block-icon' +import { BubbleX, Env } from '@/app/components/base/icons/src/vender/line/others' +import { Variable02 } from '@/app/components/base/icons/src/vender/solid/development' +import useCurrentVars from '../hooks/use-current-vars' +import cn from '@/utils/classnames' + +type Props = { + handleMenuClick: (state: any) => void +} + +const Left = ({ handleMenuClick }: Props) => { + // const bottomPanelWidth = useStore(s => s.bottomPanelWidth) + // const setShowVariableInspectPanel = useStore(s => s.setShowVariableInspectPanel) + const { + clearCurrentVars, + } = useCurrentVars() + + // TODO node selection + const selectedNode = 3 < 4 + + return ( +
+ {/* header */} +
+
Variable inspect
+ +
+ {/* content */} +
+ {/* group ENV */} +
+ {/* node item */} +
+ +
+
Environment
+
+
+ {/* var item list */} +
+
+ +
SECRET_KEY
+
string
+
+
+ {selectedNode && } + +
PORT
+
number
+
+
+
+ {/* group CHAT VAR */} +
+ {/* node item */} +
+ +
+
Conversation
+
+
+ {/* var item list */} +
+
+ +
chat_history
+
array
+
+
+ {selectedNode && } + +
custom_chat_history
+
array
+
+
+
+ {/* divider */} +
+
+
+ {/* group nodes */} +
+ {/* node item */} +
+ +
+ +
LLM
+
+
+ {/* var item list */} +
+
+ +
chat_history
+
array
+
+
+ {selectedNode && } + +
custom_chat_history
+
array
+
+
+
+ {/* group nodes */} +
+ {/* node item */} +
+ +
+ +
Question Classifier
+
+
+
+ {/* group nodes */} +
+ {/* node item */} +
+ +
+ +
HTTP Request
+
+
+
+
+
+ ) +} + +export default Left diff --git a/web/app/components/workflow/variable-inspect/panel.tsx b/web/app/components/workflow/variable-inspect/panel.tsx index ab4e0c6a59..54b9ff9480 100644 --- a/web/app/components/workflow/variable-inspect/panel.tsx +++ b/web/app/components/workflow/variable-inspect/panel.tsx @@ -5,6 +5,7 @@ import { } from '@remixicon/react' import { useStore } from '../store' import Empty from './empty' +import Left from './left' import Right from './right' import ActionButton from '@/app/components/base/action-button' import cn from '@/utils/classnames' @@ -45,7 +46,7 @@ const Panel: FC = () => { : 'block', )} > - left + {/* right */}