From 57c33d586917bfc887183ae8da970b56f0276bf9 Mon Sep 17 00:00:00 2001 From: twwu Date: Mon, 12 Jan 2026 14:51:48 +0800 Subject: [PATCH] refactor(draggable-plugin, hitl-input, human-input): update styles and improve layout for better UI consistency --- .../plugins/draggable-plugin/index.tsx | 4 +- .../plugins/hitl-input-block/component-ui.tsx | 2 +- .../human-input/components/form-content.tsx | 90 ++++++++++--------- .../workflow/nodes/human-input/panel.tsx | 9 +- 4 files changed, 59 insertions(+), 46 deletions(-) diff --git a/web/app/components/base/prompt-editor/plugins/draggable-plugin/index.tsx b/web/app/components/base/prompt-editor/plugins/draggable-plugin/index.tsx index 2a550d86c0..6260cc3e98 100644 --- a/web/app/components/base/prompt-editor/plugins/draggable-plugin/index.tsx +++ b/web/app/components/base/prompt-editor/plugins/draggable-plugin/index.tsx @@ -61,7 +61,7 @@ export default function DraggableBlockPlugin({ menuComponent={ isSupportDrag ? ( -
+
) @@ -74,7 +74,7 @@ export default function DraggableBlockPlugin({ // style={{ width: 500 }} // width not worked here >
diff --git a/web/app/components/base/prompt-editor/plugins/hitl-input-block/component-ui.tsx b/web/app/components/base/prompt-editor/plugins/hitl-input-block/component-ui.tsx index 1426d57451..45c7c97bd4 100644 --- a/web/app/components/base/prompt-editor/plugins/hitl-input-block/component-ui.tsx +++ b/web/app/components/base/prompt-editor/plugins/hitl-input-block/component-ui.tsx @@ -129,7 +129,7 @@ const HITLInputComponentUI: FC = ({ {/* Actions */} {!readonly && ( -
+
diff --git a/web/app/components/workflow/nodes/human-input/components/form-content.tsx b/web/app/components/workflow/nodes/human-input/components/form-content.tsx index 3a1c4bc25d..627d629e08 100644 --- a/web/app/components/workflow/nodes/human-input/components/form-content.tsx +++ b/web/app/components/workflow/nodes/human-input/components/form-content.tsx @@ -105,47 +105,55 @@ const FormContent: FC = ({ }, {}) return ( -
- ( - - ), - }]} - /> +
+
+ ( + + ), + }]} + /> +
{isFocus && (
> = ({ const [isExpandFormContent, { toggle: toggleExpandFormContent, }] = useBoolean(false) - const panelWidth = useStore(state => state.panelWidth) + const nodePanelWidth = useStore(state => state.nodePanelWidth) const [isPreview, { toggle: togglePreview, @@ -89,7 +89,12 @@ const Panel: FC> = ({
{/* form content */} -
+
{t(`${i18nPrefix}.formContent.title`, { ns: 'workflow' })}