From 9f66e6e357828d71332400247efc657059424e49 Mon Sep 17 00:00:00 2001 From: JzoNg Date: Wed, 18 Sep 2024 13:36:11 +0800 Subject: [PATCH] fix feature bar in basic chabot --- .../debug/debug-with-multiple-model/index.tsx | 7 +++++-- .../components/base/chat/chat/chat-input.tsx | 19 +++++++++++++------ web/app/components/base/chat/chat/index.tsx | 12 ++++++++---- 3 files changed, 26 insertions(+), 12 deletions(-) diff --git a/web/app/components/app/configuration/debug/debug-with-multiple-model/index.tsx b/web/app/components/app/configuration/debug/debug-with-multiple-model/index.tsx index 91614c6a93..9957649c32 100644 --- a/web/app/components/app/configuration/debug/debug-with-multiple-model/index.tsx +++ b/web/app/components/app/configuration/debug/debug-with-multiple-model/index.tsx @@ -17,7 +17,7 @@ import ChatInput from '@/app/components/base/chat/chat/chat-input' import type { VisionFile } from '@/app/components/base/chat/types' import { useDebugConfigurationContext } from '@/context/debug-configuration' import { useFeatures } from '@/app/components/base/features/hooks' -// import { useStore as useAppStore } from '@/app/components/app/store' +import { useStore as useAppStore } from '@/app/components/app/store' import { Resolution, TransferMethod } from '@/types/app' const DebugWithMultipleModel = () => { @@ -106,7 +106,7 @@ const DebugWithMultipleModel = () => { } }, [twoLine, threeLine, fourLine]) - // const setShowAppConfigureFeaturesModal = useAppStore(s => s.setShowAppConfigureFeaturesModal) + const setShowAppConfigureFeaturesModal = useAppStore(s => s.setShowAppConfigureFeaturesModal) return (
@@ -140,6 +140,9 @@ const DebugWithMultipleModel = () => { {isChatMode && (
void visionConfig?: VisionConfig speechToTextConfig?: EnableType onSend?: OnSend @@ -42,6 +47,10 @@ type ChatInputProps = { noSpacing?: boolean } const ChatInput: FC = ({ + showFeatureBar, + showFileUpload, + featureBarDisabled, + onFeatureBarClick, visionConfig, speechToTextConfig, onSend, @@ -149,12 +158,9 @@ const ChatInput: FC = ({ return ( <> -
+
{ visionConfig?.enabled && ( @@ -180,7 +186,7 @@ const ChatInput: FC = ({ ) }