fix: goose recipe prompt is not shown again when switch the view from settings to chat (#2870)

This commit is contained in:
Lifei Zhou
2025-06-18 09:30:59 +10:00
committed by GitHub
parent 21ea7524f6
commit 5ddb93e7b8
3 changed files with 6 additions and 16 deletions
+1 -5
View File
@@ -56,13 +56,11 @@ const isUserMessage = (message: Message): boolean => {
};
export default function ChatView({
readyForAutoUserPrompt,
chat,
setChat,
setView,
setIsGoosehintsModalOpen,
}: {
readyForAutoUserPrompt: boolean;
chat: ChatType;
setChat: (chat: ChatType) => void;
setView: (view: View, viewOptions?: ViewOptions) => void;
@@ -71,7 +69,6 @@ export default function ChatView({
return (
<ChatContextManagerProvider>
<ChatContent
readyForAutoUserPrompt={readyForAutoUserPrompt}
chat={chat}
setChat={setChat}
setView={setView}
@@ -87,7 +84,6 @@ function ChatContent({
setView,
setIsGoosehintsModalOpen,
}: {
readyForAutoUserPrompt: boolean;
chat: ChatType;
setChat: (chat: ChatType) => void;
setView: (view: View, viewOptions?: ViewOptions) => void;
@@ -628,7 +624,7 @@ function ChatContent({
isLoading={isLoading}
onStop={onStopGoose}
commandHistory={commandHistory}
initialValue={_input || initialPrompt}
initialValue={_input || (hasMessages ? _input : initialPrompt)}
setView={setView}
hasMessages={hasMessages}
numTokens={sessionTokenCount}