"use client"
import { useState } from "react"
import { Card, CardContent, CardDescription, CardHeader, CardTitle } from "@/components/ui/card"
import { Button } from "@/components/ui/button"
import { Badge } from "@/components/ui/badge"
import { Progress } from "@/components/ui/progress"
import { Select, SelectContent, SelectItem, SelectTrigger, SelectValue } from "@/components/ui/select"
import {
Database,
Target,
Brain,
Search,
BarChart3,
RefreshCw,
Download,
ChevronRight,
Activity,
Zap,
} from "lucide-react"
import Link from "next/link"
export default function HomePage() {
const [timeRange, setTimeRange] = useState("today")
// 今日数据概览
const todayStats = {
dataSync: {
total: 1245678,
growth: "+12.5%",
sources: 8,
lastUpdate: "2分钟前",
},
userDiscovery: {
activeUsers: 45678,
newUsers: 1234,
engagement: "87.5%",
growth: "+8.2%",
},
userValuation: {
avgValue: 3248,
highValue: 12456,
growth: "+15.8%",
upgradeRate: "12.5%",
},
aiAnalysis: {
insights: 156,
anomalies: 3,
predictions: 89,
accuracy: "94.2%",
},
}
// 实时活动数据
const realtimeActivities = [
{
id: 1,
type: "data_sync",
message: "电商平台数据同步完成",
time: "刚刚",
status: "success",
},
{
id: 2,
type: "user_discovery",
message: "发现新用户行为模式",
time: "2分钟前",
status: "info",
},
{
id: 3,
type: "ai_analysis",
message: "AI检测到异常流量",
time: "5分钟前",
status: "warning",
},
{
id: 4,
type: "user_valuation",
message: "用户价值模型更新完成",
time: "8分钟前",
status: "success",
},
]
const getActivityIcon = (type: string) => {
switch (type) {
case "data_sync":
return
智能数据分析平台总览
{activity.message}
{activity.time}