From 2cb8c825d077c08b209e8aa11e897db772ce7850 Mon Sep 17 00:00:00 2001 From: Dustin Loring Date: Sat, 14 Dec 2024 22:25:28 -0500 Subject: [PATCH] ui-ux: prompt enhanced toast notification changed prompt enhanced to give a toast notification instead of changing the ui. --- app/components/chat/BaseChat.tsx | 19 +++++++------------ 1 file changed, 7 insertions(+), 12 deletions(-) diff --git a/app/components/chat/BaseChat.tsx b/app/components/chat/BaseChat.tsx index 09f3c1681..162241d98 100644 --- a/app/components/chat/BaseChat.tsx +++ b/app/components/chat/BaseChat.tsx @@ -27,6 +27,7 @@ import { ModelSelector } from '~/components/chat/ModelSelector'; import { SpeechRecognitionButton } from '~/components/chat/SpeechRecognition'; import type { IProviderSetting, ProviderInfo } from '~/types/model'; import { ScreenshotStateManager } from './ScreenshotStateManager'; +import { toast } from 'react-toastify'; const TEXTAREA_MIN_HEIGHT = 76; @@ -492,22 +493,16 @@ export const BaseChat = React.forwardRef( className={classNames( 'transition-all', enhancingPrompt ? 'opacity-100' : '', - promptEnhanced ? 'text-bolt-elements-item-contentAccent' : '', - promptEnhanced ? 'pr-1.5' : '', - promptEnhanced ? 'enabled:hover:bg-bolt-elements-item-backgroundAccent' : '', )} - onClick={() => enhancePrompt?.()} + onClick={() => { + enhancePrompt?.(); + toast.success('Prompt enhanced!'); + }} > {enhancingPrompt ? ( - <> -
-
Enhancing prompt...
- +
) : ( - <> -
- {promptEnhanced &&
Prompt enhanced
} - +
)}