Merge branch 'main' of https://git.coastit.co.za/caitlin/CRM_ENVR
Build & Auto-Repair / build (push) Has been cancelled
Build & Auto-Repair / build (push) Has been cancelled
This commit is contained in:
@@ -5,14 +5,6 @@ import { AIChat, type AIChatHandle } from "@/components/ai/ai-chat"
|
|||||||
import { JobSelector } from "@/components/ai/job-selector"
|
import { JobSelector } from "@/components/ai/job-selector"
|
||||||
import { Bot, ChevronRight } from "lucide-react"
|
import { Bot, ChevronRight } from "lucide-react"
|
||||||
|
|
||||||
const tips = [
|
|
||||||
"Ask for cold email templates for a specific job",
|
|
||||||
"Request objection handling tips",
|
|
||||||
"Ask for outreach strategies per industry",
|
|
||||||
"Generate a follow up sequence",
|
|
||||||
"Get LinkedIn connection message templates",
|
|
||||||
]
|
|
||||||
|
|
||||||
export default function AIAssistantPage() {
|
export default function AIAssistantPage() {
|
||||||
const [selectedJob, setSelectedJob] = useState<{ job_title: string; keywords: string[]; industry: string; description: string } | null>(null)
|
const [selectedJob, setSelectedJob] = useState<{ job_title: string; keywords: string[]; industry: string; description: string } | null>(null)
|
||||||
const [recentPrompts, setRecentPrompts] = useState<string[]>([])
|
const [recentPrompts, setRecentPrompts] = useState<string[]>([])
|
||||||
@@ -60,10 +52,6 @@ export default function AIAssistantPage() {
|
|||||||
}
|
}
|
||||||
}, [])
|
}, [])
|
||||||
|
|
||||||
const handleTipClick = useCallback((tip: string) => {
|
|
||||||
aiChatRef.current?.fillInput(tip)
|
|
||||||
}, [])
|
|
||||||
|
|
||||||
const handleRecentPromptClick = useCallback((prompt: string) => {
|
const handleRecentPromptClick = useCallback((prompt: string) => {
|
||||||
aiChatRef.current?.fillInput(prompt)
|
aiChatRef.current?.fillInput(prompt)
|
||||||
}, [])
|
}, [])
|
||||||
@@ -123,53 +111,7 @@ export default function AIAssistantPage() {
|
|||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
<div className="mt-6">
|
|
||||||
<div className="flex items-center gap-2 mb-3">
|
|
||||||
<span className="w-1.5 h-1.5 rounded-full bg-primary" />
|
|
||||||
<span className="text-primary text-[10px] font-bold uppercase tracking-[0.15em]">Quick Tips</span>
|
|
||||||
</div>
|
|
||||||
{tips.map((tip, i) => (
|
|
||||||
<div
|
|
||||||
key={i}
|
|
||||||
onClick={() => handleTipClick(tip)}
|
|
||||||
className="flex items-start gap-2.5 bg-card/50 hover:bg-card border border-border hover:border-primary/20 rounded-xl p-3.5 mb-2 cursor-pointer transition-all duration-200 group"
|
|
||||||
>
|
|
||||||
<ChevronRight className="h-3.5 w-3.5 mt-0.5 text-muted-foreground group-hover:text-primary transition-colors duration-200 flex-shrink-0" />
|
|
||||||
<span className="text-muted-foreground text-xs leading-5 group-hover:text-foreground transition-colors duration-200">{tip}</span>
|
|
||||||
</div>
|
|
||||||
))}
|
|
||||||
</div>
|
|
||||||
<div className="mt-6">
|
|
||||||
<div className="flex items-center gap-2 mb-3">
|
|
||||||
<span className="w-1.5 h-1.5 rounded-full bg-primary" />
|
|
||||||
<span className="text-primary text-[10px] font-bold uppercase tracking-[0.15em]">Recent Prompts</span>
|
|
||||||
</div>
|
|
||||||
{recentPrompts.length > 0 ? (
|
|
||||||
recentPrompts.map((prompt, i) => (
|
|
||||||
<div
|
|
||||||
key={i}
|
|
||||||
onClick={() => handleRecentPromptClick(prompt)}
|
|
||||||
className="bg-card/50 rounded-xl p-3 mb-2 border border-border text-muted-foreground text-xs truncate hover:text-foreground cursor-pointer transition-colors duration-200"
|
|
||||||
>
|
|
||||||
{prompt}
|
|
||||||
</div>
|
|
||||||
))
|
|
||||||
) : (
|
|
||||||
<div className="text-muted-foreground text-xs text-center py-4">Your recent prompts will appear here</div>
|
|
||||||
)}
|
|
||||||
</div>
|
|
||||||
<div className="mt-auto border-t border-border pt-4">
|
|
||||||
<div className="flex gap-4">
|
|
||||||
<div className="flex-1">
|
|
||||||
<div className="text-muted-foreground text-[10px] uppercase tracking-wide">Messages today</div>
|
|
||||||
<div className="text-foreground text-sm font-semibold mt-0.5">24</div>
|
|
||||||
</div>
|
|
||||||
<div className="flex-1">
|
|
||||||
<div className="text-muted-foreground text-[10px] uppercase tracking-wide">Tokens used</div>
|
|
||||||
<div className="text-foreground text-sm font-semibold mt-0.5">12.4k</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
)
|
)
|
||||||
|
|||||||
Reference in New Issue
Block a user