This commit is contained in:
Li1304553726 2025-11-18 17:24:49 +08:00
commit a6ce98bff0
7 changed files with 144 additions and 0 deletions

View File

@ -0,0 +1,54 @@
import React from 'react';
export default function CultureBgPage() {
// 定义logo数据
const logos = [
{ id: 1, src: '/public/logo/1.png', alt: 'Logo 1' },
{ id: 2, src: '/public/logo/1.png', alt: 'Logo 2' },
{ id: 3, src: '/public/logo/1.png', alt: 'Logo 3' },
{ id: 4, src: '/public/logo/1.png', alt: 'Logo 4' },
{ id: 5, src: '/public/logo/1.png', alt: 'Logo 5' },
{ id: 6, src: '/public/logo/1.png', alt: 'Logo 6' },
{ id: 7, src: '/public/logo/1.png', alt: 'Logo 7' },
{ id: 8, src: '/public/logo/1.png', alt: 'Logo 8' },
{ id: 9, src: '/public/logo/1.png', alt: 'Logo 9' },
{ id: 10, src: '/public/logo/1.png', alt: 'Logo 10' },
{ id: 11, src: '/public/logo/1.png', alt: 'Logo 11' },
{ id: 12, src: '/public/logo/1.png', alt: 'Logo 12' },
{ id: 13, src: '/public/logo/1.png', alt: 'Logo 13' },
{ id: 14, src: '/public/logo/1.png', alt: 'Logo 14' },
{ id: 15, src: '/public/logo/1.png', alt: 'Logo 15' },
{ id: 16, src: '/public/logo/1.png', alt: 'Logo 16' },
];
return (
<div className="h-[700px] w-[1550px] mx-auto relative mb-40">
<div
className="h-[200px] w-full bg-cover"
style={{
backgroundImage: 'url(/culture.png)',
backgroundSize: '100% 100%',
backgroundRepeat: 'no-repeat',
backgroundPosition: 'center',
}}
/>
<div className="h-[500px] w-full absolute top-30 flex items-center justify-center p-8">
<div className="w-full h-full flex items-center justify-center mb-10">
{/* 两行八列flex + wrap */}
<div className="flex flex-wrap justify-center gap-x-15 gap-y-16">
{logos.map((logo) => (
<img
key={logo.id}
src={logo.src}
alt={logo.alt}
className="w-[130px] h-[130px] rounded-full object-contain hover:scale-[1.85] transition-transform duration-200 cursor-pointer"
style={{ transformOrigin: 'center' }}
/>
))}
</div>
</div>
</div>
</div>
);
}

View File

@ -0,0 +1,72 @@
import type { IconType } from 'react-icons';
import {
FaUserGraduate,
FaUserShield,
FaLaptopCode,
FaMicrophoneLines,
FaEnvelopeOpenText,
FaWrench,
FaRegFileLines,
FaSpellCheck,
FaChartPie,
FaGlobe,
FaBookOpenReader,
FaPenRuler,
} from 'react-icons/fa6';
type ServiceItem = {
icon: IconType;
label: string;
href: string;
};
const services: ServiceItem[] = [
{ icon: FaUserGraduate, label: '警队自考', href: '/study' },
{ icon: FaUserShield, label: '警队教育', href: '/scholarship' },
{ icon: FaLaptopCode, label: '常用软件', href: '/software' },
{ icon: FaMicrophoneLines, label: '智能语音', href: '/voice' },
{ icon: FaEnvelopeOpenText, label: '蓝天邮局', href: '/mail' },
{ icon: FaWrench, label: '策划工具', href: '/plan' },
{ icon: FaRegFileLines, label: '办公模板', href: '/office' },
{ icon: FaSpellCheck, label: '智能校对', href: '/ai-check' },
{ icon: FaChartPie, label: '警情调研', href: '/survey' },
{ icon: FaGlobe, label: '上网助手', href: '/net' },
{ icon: FaBookOpenReader, label: '考试平台', href: '/exam' },
{ icon: FaPenRuler, label: '学习平台', href: '/study' },
];
const columns = Array.from({ length: 3 }, (_, colIndex) =>
services.slice(colIndex * 4, colIndex * 4 + 4)
);
export default function Integrated() {
return (
<div className="w-[1514px] h-[573px] mx-auto absolute bottom-0 left-1/2 -translate-x-1/2">
<div className="w-full h-[488px]">
<div className="w-full h-[82px] flex items-center pt-30 ml-10">
<div className="w-3 h-15 bg-[#005d93] mr-3" />
<h2 className="text-4xl font-bold text-[#005d93]"></h2>
</div>
<div className="flex gap-45 h-full px-8 py-6 pb-20 pt-15">
{columns.map((group, colIdx) => (
<div key={colIdx} className="flex-1 grid grid-cols-2 gap-x-8 gap-y-6">
{group.map((service) => (
<a
key={service.label}
href={service.href}
className="flex flex-col items-center text-[#0f172a] transition hover:text-[#005d93]"
>
<div className="w-16 h-16 flex items-center justify-center rounded-full bg-[#005d93]/10 text-[#005d93] mb-2">
<service.icon className="w-8 h-8" aria-hidden />
</div>
<span className="text-base font-semibold text-center">{service.label}</span>
</a>
))}
</div>
))}
</div>
</div>
</div>
);
}

View File

@ -1,5 +1,7 @@
import { CarouselDemo } from "@/components/Carousel"; import { CarouselDemo } from "@/components/Carousel";
import type { Route } from "./+types/news"; import type { Route } from "./+types/news";
import Integrated from "@/components/news/body/Integrated";
import CultureBgPage from "@/components/news/body/Culturebg";
import {Header} from "@/components/header/Header"; import {Header} from "@/components/header/Header";
import {TopNav} from "@/components/header/TopNav"; import {TopNav} from "@/components/header/TopNav";
import NewsList from "@/components/list/NewsList"; import NewsList from "@/components/list/NewsList";
@ -12,6 +14,7 @@ export function meta( ) {
} }
export default function Home() { export default function Home() {
return ( return (
<div> <div>
<Header /> <Header />
@ -19,6 +22,8 @@ export default function Home() {
<NewsList /> <NewsList />
<ImageGridSection /> <ImageGridSection />
<Integrated />
<CultureBgPage />
</div> </div>
); );
} }

View File

@ -27,6 +27,7 @@
"lucide-react": "^0.553.0", "lucide-react": "^0.553.0",
"next-themes": "^0.4.6", "next-themes": "^0.4.6",
"react": "^19.1.1", "react": "^19.1.1",
"react-icons": "^5.5.0",
"react-dom": "^19.1.1", "react-dom": "^19.1.1",
"react-router": "^7.9.2", "react-router": "^7.9.2",
"shadcn": "^3.5.0", "shadcn": "^3.5.0",

View File

@ -65,6 +65,9 @@ importers:
react-dom: react-dom:
specifier: ^19.1.1 specifier: ^19.1.1
version: 19.2.0(react@19.2.0) version: 19.2.0(react@19.2.0)
react-icons:
specifier: ^5.5.0
version: 5.5.0(react@19.2.0)
react-router: react-router:
specifier: ^7.9.2 specifier: ^7.9.2
version: 7.9.6(react-dom@19.2.0(react@19.2.0))(react@19.2.0) version: 7.9.6(react-dom@19.2.0(react@19.2.0))(react@19.2.0)
@ -2382,6 +2385,11 @@ packages:
peerDependencies: peerDependencies:
react: ^19.2.0 react: ^19.2.0
react-icons@5.5.0:
resolution: {integrity: sha512-MEFcXdkP3dLo8uumGI5xN3lDFNsRtrjbOEKDLD7yv76v4wpnEq2Lt2qeHaQOr34I/wPN3s3+N08WkQ+CW37Xiw==}
peerDependencies:
react: '*'
react-refresh@0.14.2: react-refresh@0.14.2:
resolution: {integrity: sha512-jCvmsr+1IUSMUyzOkRcvnVbX3ZYC6g9TDrDbFuFmRDq7PD4yaGbLKNQL6k2jnArV8hjYxh7hVhAZB6s9HDGpZA==} resolution: {integrity: sha512-jCvmsr+1IUSMUyzOkRcvnVbX3ZYC6g9TDrDbFuFmRDq7PD4yaGbLKNQL6k2jnArV8hjYxh7hVhAZB6s9HDGpZA==}
engines: {node: '>=0.10.0'} engines: {node: '>=0.10.0'}
@ -5082,6 +5090,10 @@ snapshots:
react: 19.2.0 react: 19.2.0
scheduler: 0.27.0 scheduler: 0.27.0
react-icons@5.5.0(react@19.2.0):
dependencies:
react: 19.2.0
react-refresh@0.14.2: {} react-refresh@0.14.2: {}
react-remove-scroll-bar@2.3.8(@types/react@19.2.6)(react@19.2.0): react-remove-scroll-bar@2.3.8(@types/react@19.2.6)(react@19.2.0):

BIN
public/culture.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 26 KiB

BIN
public/logo/1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.5 MiB