3957e36c41
- 详情页补齐原站 MDX 组件:左侧目录(2xl 固定定位、滚动高亮 top≤96、 点击平滑滚动)、标题锚点(hover #、点击复制链接 + replaceState)、 代码块(语言标签 + COPY/COPIED + 原站 prism token HTML 按行号渲染, --code-* 配色变量)、页脚 Metadata(实时视口尺寸 / 正文字符数)与 Work/Contact 按钮(sessionStorage hq:pendingScrollAnchor → 首页过渡后 滚动到对应区块,SmoothScroller 消费) - content/workArticles.ts 重新提取:内联 strong/em/code 片段、标题 id、 代码块语言 + 高亮 HTML + 纯文本(bs4 全量解析 6 篇文章) - 详情页不再显示十字网格(BackgroundGrid 按 pathname 门控,置于全部 hooks 之后避免 hook 数量变化崩溃) - 首页层叠修复:WebGL 容器改为原站的 top-0 left-0 -z-1 fixed(此前 z-auto fixed 按 CSS 绘制顺序盖住 banner 文案与作品说明文字),footer 改为原站的 z-10 relative,body 背景移至 html 根节点(否则普通流 body 背景会盖住 -z-1 场景)
112 lines
4.2 KiB
TypeScript
112 lines
4.2 KiB
TypeScript
"use client";
|
|
|
|
import ScrambleReveal from "@/components/dom/ScrambleReveal";
|
|
|
|
/**
|
|
* #contact footer — 1:1 port of the original footer (chunk 2689132c4e070b68.js
|
|
* module 28192):
|
|
*
|
|
* - `<footer id="contact">` fills the last viewport (h-dvh / lg:h-screen)
|
|
* and carries `data-section="footer"` — SmoothScroller's sP f2 factor and
|
|
* PostFX's bright-source gating both read this attribute.
|
|
* - Headline: three 12-col grid rows at 6svw, "Let's / Create / Something /
|
|
* Extraordinary"; "Create" and "Extraordinary" use reverse reveal (chars
|
|
* run last→first).
|
|
* - Bottom bar: mailto + Twitter/X / Figma / GitHub links with the dotted
|
|
* hover border.
|
|
*
|
|
* NOTE: contact email is chenchun@virtheart.com (user-provided); social
|
|
* URLs are still placeholders.
|
|
*/
|
|
|
|
const CONTACT_EMAIL = "chenchun@virtheart.com";
|
|
|
|
const dottedLink =
|
|
"block before:absolute relative before:inset-0 p-2 lg:hover:before:border-l1 before:border-2 before:border-transparent active:before:border-l1 before:border-dotted uppercase before:content-[''] before:transition-colors before:duration-200 cursor-pointer pointer-events-auto before:pointer-events-none";
|
|
|
|
const SOCIALS = [
|
|
{ href: "#", label: "Twitter/X" },
|
|
{ href: "#", label: "Figma" },
|
|
{ href: "#", label: "GitHub" },
|
|
];
|
|
|
|
export default function FooterSection() {
|
|
return (
|
|
<footer
|
|
id="contact"
|
|
data-section="footer"
|
|
className="z-10 relative flex flex-col justify-center p-6 lg:p-16 w-full h-dvh lg:h-screen pointer-events-none"
|
|
>
|
|
<div
|
|
className="gap-2 grid grid-cols-12 font-bold text-[7.2svw] lg:text-[6svw] 2xl:text-[5svw] xl:text-[5.6svw] uppercase leading-none"
|
|
style={{ fontVariationSettings: '"wdth" 120' }}
|
|
>
|
|
<ScrambleReveal
|
|
text="Let's"
|
|
className="col-span-6 md:col-span-5 xl:col-span-4 md:col-start-2 xl:col-start-3 text-left pointer-events-auto"
|
|
startDelayMs={300}
|
|
scrambleColors={false}
|
|
/>
|
|
<ScrambleReveal
|
|
text="Create"
|
|
className="col-span-6 md:col-span-5 xl:col-span-4 text-right pointer-events-auto"
|
|
startDelayMs={300}
|
|
reverse
|
|
scrambleColors={false}
|
|
/>
|
|
</div>
|
|
<div
|
|
className="gap-2 grid grid-cols-12 font-bold text-[7.2svw] lg:text-[6svw] 2xl:text-[5svw] xl:text-[5.6svw] uppercase leading-none"
|
|
style={{ fontVariationSettings: '"wdth" 120' }}
|
|
>
|
|
<ScrambleReveal
|
|
text="Something"
|
|
className="col-span-12 md:col-start-2 xl:col-start-3 text-left pointer-events-auto"
|
|
startDelayMs={300}
|
|
scrambleColors={false}
|
|
/>
|
|
</div>
|
|
<div
|
|
className="gap-2 grid grid-cols-12 font-bold text-[7.2svw] lg:text-[6svw] 2xl:text-[5svw] xl:text-[5.6svw] uppercase leading-none"
|
|
style={{ fontVariationSettings: '"wdth" 120' }}
|
|
>
|
|
<ScrambleReveal
|
|
text="Extraordinary"
|
|
className="col-span-12 md:col-end-12 xl:col-end-11 text-right pointer-events-auto"
|
|
startDelayMs={300}
|
|
reverse
|
|
scrambleColors={false}
|
|
/>
|
|
</div>
|
|
<div className="absolute inset-0 flex flex-col justify-end px-4 lg:px-14 py-18 lg:py-24 font-mono-2 text-sm lg:text-base">
|
|
<div className="flex lg:flex-row flex-col justify-between w-full">
|
|
<a className={dottedLink} href={`mailto:${CONTACT_EMAIL}`}>
|
|
<ScrambleReveal
|
|
text={CONTACT_EMAIL}
|
|
startDelayMs={300}
|
|
scrambleColors={false}
|
|
/>
|
|
</a>
|
|
<div className="flex flex-row items-center gap-2 lg:gap-4">
|
|
{/* TODO: replace with the real VIRTHEART social URLs. */}{SOCIALS.map(({ href, label }) => (
|
|
<a
|
|
key={label}
|
|
className={dottedLink}
|
|
href={href}
|
|
target={href.startsWith("http") ? "_blank" : undefined}
|
|
rel={href.startsWith("http") ? "noopener noreferrer" : undefined}
|
|
>
|
|
<ScrambleReveal
|
|
text={label}
|
|
startDelayMs={300}
|
|
scrambleColors={false}
|
|
/>
|
|
</a>
|
|
))}
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</footer>
|
|
);
|
|
}
|