feat:黄炎培对话对接中

This commit is contained in:
zhongyidian committed 2026-01-07 21:08:38 +08:00
1 parent 3611a0857a
commit 6ab184b328
125 files changed
+6617 -2391

No files matched your search

+34 -20
View File
@@ -7,10 +7,12 @@ import { useState } from "react";
const starName = "luxun";
// 展品 ID 与资源路径映射
const exhibitSrcMap: Record<1 | 2 | 3, string> = {
1: "luxun/place3/展品8",
2: "luxun/place3/展品7",
3: "luxun/place3/展品6",
const exhibitSrcMap: Record<1 | 2 | 3 | 4 | 5, string> = {
1: "luxun/place3/6",
2: "luxun/place3/7",
3: "luxun/place3/8",
4: "luxun/place3/9",
5: "luxun/place3/10",
};
const LuxunPlace3 = () => {
@@ -19,21 +21,21 @@ const LuxunPlace3 = () => {
moduleName: string;
}>();
const [activeExhibitId, setActiveExhibitId] = useState<1 | 2 | 3 | null>(
null
);
const [activeExhibitId, setActiveExhibitId] = useState<
1 | 2 | 3 | 4 | 5 | null
>(null);
const [visited, setVisited] = useState<Set<number>>(new Set());
const handleOpenExhibit = (index: 1 | 2 | 3) => {
const handleOpenExhibit = (index: 1 | 2 | 3 | 4 | 5) => {
setActiveExhibitId(index);
};
const progressCount = visited.size;
const total = 3;
const total = 5;
const completed = progressCount >= total;
const subtitle = completed
? "探索二楼卧室兼书房(已完成)"
: `探索二楼卧室兼书房(${progressCount}/${total})`;
? "探索二楼卧室兼书房的书桌(已完成)"
: `探索二楼卧室兼书房的书桌(${progressCount}/${total})`;
const subtitleClassName = completed
? "text-[#fff998] [text-shadow:_0_8px_8px_rgba(0,0,0,0.35),_0_0_16px_rgba(0,0,0,0.25)]"
: undefined;
@@ -46,7 +48,7 @@ const LuxunPlace3 = () => {
}}
>
<Title
title="历史新编中的现实呐喊"
title="历史新编中的现实呐喊&为亡友编纂的精神丰碑"
subtitle={subtitle}
subtitleClassName={subtitleClassName}
className="absolute top-10 left-1/2 -translate-x-1/2"
@@ -65,28 +67,40 @@ const LuxunPlace3 = () => {
{/* 展品 */}
<Cursor
className="absolute left-90 bottom-140"
className="absolute right-114 bottom-130"
onClick={() => handleOpenExhibit(1)}
size={0.4}
size={0.6}
read={visited.has(1)}
/>
<Cursor
className="absolute right-225 bottom-120"
className="absolute right-130 bottom-115"
onClick={() => handleOpenExhibit(2)}
size={0.4}
size={0.6}
read={visited.has(2)}
/>
<Cursor
className="absolute right-214 bottom-123"
className="absolute left-76 bottom-140"
onClick={() => handleOpenExhibit(3)}
size={0.4}
size={0.6}
read={visited.has(3)}
/>
<Cursor
className="absolute right-238 bottom-125"
onClick={() => handleOpenExhibit(4)}
size={0.6}
read={visited.has(4)}
/>
<Cursor
className="absolute right-258 bottom-118"
onClick={() => handleOpenExhibit(5)}
size={0.6}
read={visited.has(5)}
/>
{completed && (
<Image
className="absolute bottom-25 right-[calc(50%-270px)]"
src={getStaticImage("luxun/place3/前进")}
className="absolute bottom-0 right-130"
src={getStaticImage("luxun/place3/前进按钮")}
button
onClick={() => {
navigate(`/${moduleName}/${starName}/place4`);