Files
frontend/src/app/page.tsx
Mikuisnotavailable c903bf5284 first save
2025-07-30 03:08:49 +08:00

174 lines
8.1 KiB
TypeScript
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

// src/app/page.tsx
import Link from 'next/link';
import Image from 'next/image';
import { Button } from '@/components/ui/button';
import { Card, CardContent, CardFooter, CardHeader, CardTitle } from '@/components/ui/card';
export default function HomePage() {
return (
<div className="min-h-screen bg-gradient-to-br from-green-50 to-cyan-100 dark:from-gray-900 dark:to-gray-800">
{/* 导航栏 */}
<nav className="bg-white dark:bg-gray-800 shadow-md py-4 px-6 flex justify-between items-center">
<div className="flex items-center space-x-2">
<div className="bg-gray-200 border-2 border-dashed rounded-xl w-10 h-10" />
<span className="text-xl font-bold text-green-600 dark:text-green-400">HITWH皮肤库</span>
</div>
<div className="flex space-x-4">
<Button asChild variant="outline" className="border-green-600 text-green-600 hover:bg-green-50">
<Link href="/login"></Link>
</Button>
<Button asChild className="bg-green-600 hover:bg-green-700">
<Link href="/register"></Link>
</Button>
</div>
</nav>
{/* 区域 */}
<section className="container mx-auto px-4 py-16 flex flex-col md:flex-row items-center justify-between">
<div className="md:w-1/2 mb-12 md:mb-0">
<h1 className="text-4xl md:text-5xl font-bold text-gray-800 dark:text-white mb-6">
<span className="text-green-600 dark:text-green-400"> Minecraft </span>
</h1>
<p className="text-lg text-gray-600 dark:text-gray-300 mb-8 max-w-lg">
3D预览中查看效果HITWH的大家分享你的创作
</p>
<div className="flex flex-col sm:flex-row gap-4">
<Button asChild size="lg" className="text-lg bg-green-600 hover:bg-green-700 py-6">
<Link href="/skins/upload"></Link>
</Button>
<Button asChild variant="outline" size="lg" className="text-lg border-green-600 text-green-600 hover:bg-green-50 py-6">
<Link href="/dashboard"></Link>
</Button>
</div>
</div>
<div className="md:w-1/2 flex justify-center">
<div className="relative w-full max-w-md">
<div className="absolute inset-0 bg-green-500 rounded-2xl transform rotate-6"></div>
<div className="relative bg-gray-200 border-2 border-dashed rounded-xl w-full h-96 flex items-center justify-center">
<div className="text-center p-6">
<h3 className="text-xl font-bold mb-4"></h3>
<p className="text-gray-600">3D皮肤预览</p>
</div>
</div>
</div>
</div>
</section>
{/* 功能特性区域 */}
<section className="py-16 bg-white dark:bg-gray-800">
<div className="container mx-auto px-4">
<h2 className="text-3xl font-bold text-center text-gray-800 dark:text-white mb-16">
</h2>
<div className="grid grid-cols-1 md:grid-cols-3 gap-8">
<FeatureCard
title="3D实时预览"
description="上传后立即在3D模型中查看皮肤效果支持360度旋转查看"
icon="👁️"
/>
<FeatureCard
title="一键应用"
description="获取皮肤链接在Minecraft游戏中一键应用你的新皮肤"
icon="⚡"
/>
<FeatureCard
title="社区分享"
description="社区认同和安全保障(大概?"
icon="🌍"
/>
</div>
</div>
</section>
{/* 行动号召区域 */}
<section className="py-20 bg-gradient-to-r from-green-500 to-cyan-500 dark:from-green-700 dark:to-cyan-700">
<div className="container mx-auto px-4 text-center">
<h2 className="text-3xl md:text-4xl font-bold text-white mb-6">
HITWH300众
</h2>
<p className="text-xl text-green-100 max-w-2xl mx-auto mb-10">
</p>
<div className="flex flex-col sm:flex-row justify-center gap-4">
<Button asChild size="lg" className="text-lg bg-white text-green-600 hover:bg-green-50 py-6">
<Link href="/register"></Link>
</Button>
<Button asChild variant="outline" size="lg" className="text-lg border-white text-white hover:bg-green-600 py-6">
<Link href="/login"></Link>
</Button>
</div>
</div>
</section>
{/* 页脚 */}
<footer className="bg-gray-800 text-gray-300 py-10">
<div className="container mx-auto px-4">
<div className="flex flex-col md:flex-row justify-between items-center">
<div className="mb-6 md:mb-0">
<div className="flex items-center space-x-2">
<div className="bg-gray-200 border-2 border-dashed rounded-xl w-8 h-8" />
<span className="text-xl font-bold text-green-400">HITWH皮肤库</span>
</div>
<p className="mt-2 text-sm"> Minecraft </p>
</div>
<div className="grid grid-cols-2 md:grid-cols-3 gap-8">
<div>
<h3 className="text-green-400 font-semibold mb-3"></h3>
<ul className="space-y-2">
<li><Link href="/" className="hover:text-white"></Link></li>
<li><Link href="/dashboard" className="hover:text-white"></Link></li>
<li><Link href="/skins/upload" className="hover:text-white"></Link></li>
</ul>
</div>
<div>
<h3 className="text-green-400 font-semibold mb-3"></h3>
<ul className="space-y-2">
<li><Link href="/login" className="hover:text-white"></Link></li>
<li><Link href="/register" className="hover:text-white"></Link></li>
<li><Link href="/dashboard" className="hover:text-white"></Link></li>
</ul>
</div>
<div>
<h3 className="text-green-400 font-semibold mb-3"></h3>
<ul className="space-y-2">
<li><Link href="/help" className="hover:text-white"></Link></li>
<li><Link href="/contact" className="hover:text-white"></Link></li>
<li><Link href="/terms" className="hover:text-white"></Link></li>
</ul>
</div>
</div>
</div>
<div className="border-t border-gray-700 mt-10 pt-6 text-center text-sm">
<p>© {new Date().getFullYear()} HITWHGAMES. .</p>
</div>
</div>
</footer>
</div>
);
}
// 功能卡片组件
function FeatureCard({ title, description, icon }: { title: string; description: string; icon: string }) {
return (
<Card className="h-full transition-transform hover:scale-[1.02] hover:shadow-lg">
<CardHeader>
<div className="text-4xl mb-4">{icon}</div>
<CardTitle className="text-xl">{title}</CardTitle>
</CardHeader>
<CardContent>
<p className="text-gray-600 dark:text-gray-300">{description}</p>
</CardContent>
<CardFooter>
<Button variant="link" className="text-green-600 dark:text-green-400 p-0">
</Button>
</CardFooter>
</Card>
);
}