diff --git a/src/pages/AIChatPage.tsx b/src/pages/AIChatPage.tsx index 8c4b2ffc..26754b26 100644 --- a/src/pages/AIChatPage.tsx +++ b/src/pages/AIChatPage.tsx @@ -15,7 +15,7 @@ import { Textarea } from '@/components/ui/textarea'; import { ScrollArea } from '@/components/ui/scroll-area'; import { Select, SelectContent, SelectItem, SelectTrigger, SelectValue } from '@/components/ui/select'; -import { Skeleton } from '@/components/ui/skeleton'; + import { cn } from '@/lib/utils'; import type { ThemeConfig } from '@/themes'; @@ -472,10 +472,7 @@ export function AIChatPage() { {/* Loading indicator */} {(isStreaming || apiLoading) && messages[messages.length - 1]?.role === 'user' && ( -
- - -
+ )} {/* Error display */} @@ -518,6 +515,28 @@ export function AIChatPage() { // ─── Sub-Components ─── +const DORK_ANIMATION = [ + '<[o_o]>', + '>[-_-]<', + '<[0_0]>', + '>[-_-]<', +]; + +function DorkThinking() { + const [frame, setFrame] = useState(0); + + useEffect(() => { + const interval = setInterval(() => { + setFrame((f) => (f + 1) % DORK_ANIMATION.length); + }, 400); + return () => clearInterval(interval); + }, []); + + return ( +
{DORK_ANIMATION[frame]}
+ ); +} + const DORK_GREETINGS = [ "Hi, I'm Dork! What would you like me to do?", "Dork here! What do you need?",