diff --git a/apps/desktop/src/renderer/src/pages/onboarding/try-it.tsx b/apps/desktop/src/renderer/src/pages/onboarding/try-it.tsx index da01ddf8..90e3108d 100644 --- a/apps/desktop/src/renderer/src/pages/onboarding/try-it.tsx +++ b/apps/desktop/src/renderer/src/pages/onboarding/try-it.tsx @@ -1,28 +1,46 @@ import { useNavigate } from 'react-router-dom' import { Button } from '@multica/ui/components/ui/button' +import { Loading } from '@multica/ui/components/ui/loading' +import { ChatView } from '@multica/ui/components/chat-view' import { HugeiconsIcon } from '@hugeicons/react' import { ArrowLeft02Icon } from '@hugeicons/core-free-icons' import { SamplePrompt } from '../../components/onboarding/sample-prompt' import { useOnboardingStore } from '../../stores/onboarding' +import { useLocalChat } from '../../hooks/use-local-chat' const samplePrompts = [ { - title: 'Summarize a webpage', - prompt: 'Summarize the key points from this article for me', + title: 'Say hello', + prompt: 'Say hello and briefly introduce yourself in 2-3 sentences.', }, { - title: 'Write a script', - prompt: 'Write a Python script that converts CSV files to JSON', + title: 'Write a haiku', + prompt: 'Write a haiku about coding.', }, { - title: 'Explain code', - prompt: 'Explain how React hooks work with a simple example', + title: 'Quick math', + prompt: "What's 123 × 456? Show your reasoning.", }, ] export default function TryItStep() { const navigate = useNavigate() const { completeOnboarding } = useOnboardingStore() + const { + agentId, + initError, + messages, + streamingIds, + isLoading, + isLoadingHistory, + isLoadingMore, + hasMore, + error, + pendingApprovals, + sendMessage, + loadMore, + resolveApproval, + } = useLocalChat() const handleComplete = () => { completeOnboarding() @@ -33,9 +51,11 @@ export default function TryItStep() { navigate('/onboarding/connect') } + const hasMessages = messages.length > 0 + return (
✨
-- Chat with your agent, automate tasks, run shell commands - with approval, and connect to Telegram or Discord channels. -
-+ Click a prompt on the left to start a conversation, or type + your own message below. +
+