PMorningstar98/Parth-Jamodkar

GitHub: PMorningstar98/Parth-Jamodkar

一个基于 Next.js 和 JSON 数据文件的安全研究个人门户模板,支持静态导出和零代码内容更新。

Stars: 0 | Forks: 0

# Parth Jamodkar — 安全研究门户 一个使用 Next.js (App Router)、Tailwind CSS 和 Framer Motion 构建的数据驱动型个人研究门户。 包含暗色模式、毛玻璃效果、终端风格的 UI,以及首屏区域的双色调 “已知 / 未知” 解码雨视觉效果。 每一份出版物、演讲、代码库和博客文章都存储在一个 JSON 数据文件中 —— 添加新 内容只需添加一个条目,而无需修改页面代码。 ## 1. 启动前:填充占位符 有些内容被保留为清晰标记的占位符,因为只有你才有真实的值: | 文件 | 需要更新的内容 | |---|---| | `data/site.json` | `email`(目前为 `your-email@example.com`)、`location`(可选),如果你重命名了文件,还需更新 `resumeUrl` | | `data/timeline.json` | `year` 字段留空为了 `""` —— 为每个里程碑添加真实的年份 | | `data/content.json` | 大部分项目的 `date` 字段留空为了 `""` —— 找到后请添加发布日期 | | `public/resume.pdf` | 在此处添加你真实的简历 PDF(“下载简历”按钮链接至 `/resume.pdf`) | | `app/layout.js`, `app/sitemap.js`, `app/robots.js`, `app/rss.xml/route.js` | 一旦你拥有了真实域名,请将占位符 `siteUrl`(`https://parthjamodkar.com`)替换为你的真实域名 | ## 2. 本地运行 需要 Node.js 18.17+。 ``` npm install npm run dev ``` 访问 `http://localhost:3000`。 ## 3. 添加新内容(无需更改代码) 所有内容都以单个数组的形式存储在 `data/content.json` 中。每个条目如下所示: ``` { "id": "unique-slug", "type": "publication", "title": "Article title", "description": "One or two sentences.", "url": "https://example.com/the-article", "source": "Microsoft Security Blog", "date": "2026-08-01", "categories": ["Threat Hunting", "Detection Engineering"], "tags": ["KQL", "MITRE ATT&CK"], "featured": false } ``` - `type` 必须是以下之一:`publication`、`talk`、`opensource`、`blog`。 - `categories` 应与 `data/research-categories.json` 中的名称相匹配,以便该项目 显示在 Research 页面上。 - 设置 `featured: true` 可使项目在首页的“最新研究”部分突出显示。 - 新条目会自动出现在:其对应的板块页面(Publications/Talks/Open Source/Blog)、Research 页面(在匹配的类别下)、Public Work 页面、 首页动态(如果设为 featured)、RSS 订阅源以及搜索中。 要添加职业里程碑,请在 `data/timeline.json` 中添加条目。要添加/移除技能 标签,请编辑 `data/skills.json`。 ## 4. 生产环境构建 ``` npm run build ``` 这会在 `out/` 文件夹中生成一个完全静态的站点(`next.config.mjs` 设置了 `output: 'export'`),因此它可以托管在任何提供静态文件服务的地方 —— 不需要 Node 服务器。 ## 5. 部署 ### 选项 A — GitHub Pages 1. 将此项目推送到 GitHub 代码库。 2. 运行 `npm run build` 以生成 `out/`。 3. 将 `out/` 的内容部署到 `gh-pages` 分支(例如使用 `gh-pages` npm 包,或者使用运行 `npm run build` 并发布 `out/` 的 GitHub Actions 工作流)。 4. `public/` 中已包含 `.nojekyll`,因此 GitHub Pages 不会忽略 `_next` 文件夹。 5. 如果部署到 **项目** 页面(`username.github.io/repo-name`)而不是 **用户** 页面(`username.github.io`),请在 `next.config.mjs` 中添加 `basePath: '/repo-name'`。 ### 选项 B — Vercel / Netlify 直接连接 GitHub 代码库 —— 两个平台都会自动检测 Next.js 并 在每次推送时进行构建和部署。`output: 'export'` 依然有效;Vercel 也将 以静态站点的形式提供服务。 ## 6. 项目结构 ``` app/ Routes (App Router) — one folder per page page.js Home about/ research/ Grouped by category publications/ talks/ open-source/ blog/ public-work/ Aggregator page — the "everything in one place" view contact/ search/ Client-side search across all content sitemap.js Auto-generated sitemap.xml robots.js Auto-generated robots.txt rss.xml/route.js Auto-generated RSS feed components/ Shared UI (Header, Footer, Hero, ContentCard, Timeline, etc.) data/ All editable content — JSON only, no code site.json Name, roles, tagline, social links, nav content.json Publications, talks, open-source items, blog posts timeline.json Career milestones skills.json Skill tags research-categories.json Research category descriptions lib/search.js Shared search-matching logic ``` ## 7. 设计说明 - **主题**:暗色、蓝/紫双色调、毛玻璃面板,标题/标签使用等宽字体 (JetBrains Mono),正文使用 Inter 字体。 - **标志性视觉效果**:首屏区域的解码雨画布将标语直观化 —— 蓝色列代表解析并稳定的“已知”信号,紫色列代表不断变幻的 “未知”信号。这是唯一一个刻意引人注目的元素; 其余设计均保持低调克制。 - 支持 `prefers-reduced-motion`(雨速变慢,其他动画缩短)。 - 键盘焦点随处可见;所有交互元素均为真实的 ``/`
标签:Tailwind CSS, 个人主页, 内容管理, 前端模板, 数据可视化, 自定义脚本