Files
users/app/settings/page.tsx
v0 2408d50cb0 refactor: overhaul UI for streamlined user experience
Redesign navigation, home overview, user portrait, and valuation pages
with improved functionality and responsive design.

Co-authored-by: null <4804959+fnvtk@users.noreply.github.com>
2025-07-18 13:47:12 +00:00

119 lines
4.7 KiB
TypeScript

"use client"
import { useState } from "react"
import { Settings, Database, Shield, Bell, HelpCircle } from "lucide-react"
import { Card, CardContent, CardDescription, CardHeader, CardTitle } from "@/components/ui/card"
import { Button } from "@/components/ui/button"
import { Switch } from "@/components/ui/switch"
import { Label } from "@/components/ui/label"
import { Avatar, AvatarFallback, AvatarImage } from "@/components/ui/avatar"
export default function SettingsPage() {
const [notifications, setNotifications] = useState(true)
const [dataSync, setDataSync] = useState(true)
const [autoAnalysis, setAutoAnalysis] = useState(false)
return (
<div className="flex-1 bg-gradient-to-b from-blue-50 to-white pb-16">
<header className="sticky top-0 z-10 bg-white/80 backdrop-blur-sm border-b">
<div className="flex justify-between items-center p-4">
<h1 className="text-xl font-semibold text-blue-600"></h1>
</div>
</header>
<div className="p-4 space-y-6">
{/* 用户信息卡片 */}
<Card className="p-6">
<div className="flex items-center space-x-4">
<Avatar className="w-20 h-20">
<AvatarImage src="https://images.unsplash.com/photo-1568602471122-7832951cc4c5?w=400&h=400&auto=format&fit=crop" />
<AvatarFallback></AvatarFallback>
</Avatar>
<div className="flex-1">
<h2 className="text-xl font-semibold text-blue-600"></h2>
<p className="text-gray-500"></p>
</div>
</div>
</Card>
{/* 系统设置 */}
<Card>
<CardHeader>
<CardTitle className="flex items-center">
<Settings className="w-5 h-5 mr-2" />
</CardTitle>
<CardDescription></CardDescription>
</CardHeader>
<CardContent className="space-y-4">
<div className="flex items-center justify-between">
<div className="space-y-0.5">
<Label htmlFor="notifications"></Label>
<p className="text-sm text-gray-500"></p>
</div>
<Switch id="notifications" checked={notifications} onCheckedChange={setNotifications} />
</div>
<div className="flex items-center justify-between">
<div className="space-y-0.5">
<Label htmlFor="dataSync"></Label>
<p className="text-sm text-gray-500"></p>
</div>
<Switch id="dataSync" checked={dataSync} onCheckedChange={setDataSync} />
</div>
<div className="flex items-center justify-between">
<div className="space-y-0.5">
<Label htmlFor="autoAnalysis"></Label>
<p className="text-sm text-gray-500">AI自动分析功能</p>
</div>
<Switch id="autoAnalysis" checked={autoAnalysis} onCheckedChange={setAutoAnalysis} />
</div>
</CardContent>
</Card>
{/* 数据管理 */}
<Card>
<CardHeader>
<CardTitle className="flex items-center">
<Database className="w-5 h-5 mr-2" />
</CardTitle>
<CardDescription></CardDescription>
</CardHeader>
<CardContent className="space-y-3">
<Button variant="outline" className="w-full justify-start bg-transparent">
<Database className="w-4 h-4 mr-2" />
</Button>
<Button variant="outline" className="w-full justify-start bg-transparent">
<Shield className="w-4 h-4 mr-2" />
</Button>
</CardContent>
</Card>
{/* 帮助与支持 */}
<Card>
<CardHeader>
<CardTitle className="flex items-center">
<HelpCircle className="w-5 h-5 mr-2" />
</CardTitle>
</CardHeader>
<CardContent className="space-y-3">
<Button variant="outline" className="w-full justify-start bg-transparent">
<HelpCircle className="w-4 h-4 mr-2" />
使
</Button>
<Button variant="outline" className="w-full justify-start bg-transparent">
<Bell className="w-4 h-4 mr-2" />
</Button>
</CardContent>
</Card>
</div>
</div>
)
}