feat: 页面模板差异化改进 + 配置优化 + 兼容清理 (#29)

- 首页判定:navigation 第一项
- 模板:page/projects/articles/bookmarks/search-results
- bookmarks:update: YYYY-MM-DD | from: git|mtime
- articles:RSS 聚合只读条目 + 分类聚合 + 影子写回结构
- projects:repo 卡片 + 可选热力图 + 自动抓取元信息
- 工作流:构建前 sync + schedule 定时刷新
- 移除兼容:config.yml/config.yaml、navigation.yml、home 特例
- 迁移说明:config/update-instructions.md
This commit is contained in:
rbetree
2025-12-28 00:22:54 +08:00
committed by GitHub
parent 1475a8a0d3
commit 387cd2492e
35 changed files with 2927 additions and 851 deletions

View File

@@ -32,9 +32,37 @@ fonts:
# 个人资料:显示在首页顶部的欢迎信息
profile:
# 注意:首页(导航第一项)标题区优先使用 profile.title/profile.subtitle
# 因此建议把首页希望展示的文案写在这里,避免“改了 pages/<首页id>.yml 但首页不生效”的误会
title: Hello,
subtitle: Welcome to My Navigation
# RSSPhase 2用于 articles 页面文章聚合
# 说明:
# - `npm run build` 默认不联网;仅 `npm run sync-articles` 会联网抓取并写入缓存
# - 缓存目录建议放在 dev/(仓库默认 gitignore避免误提交
rss:
enabled: true
cacheDir: dev
fetch:
timeoutMs: 10000 # 单请求超时(毫秒)
totalTimeoutMs: 60000 # 全流程总超时(毫秒)
concurrency: 5 # 并发抓取站点数
maxRetries: 1 # 单站点重试次数best-effort
maxRedirects: 3 # 最大重定向次数
articles:
perSite: 8 # 单站点最多抓取条数
total: 50 # 全站聚合上限
summaryMaxLength: 200 # 摘要最大长度(字符)
# GitHub用于 projects 页面右侧“贡献热力图”(可选)
# - username你的 GitHub 用户名(例如 torvalds
# - heatmapColor热力图主题色不带 #,例如 339af0
github:
username: "rbetree" # 你的 GitHub 用户名(例如 torvalds为空则 projects 页不展示热力图)
heatmapColor: 339af0
cacheDir: dev # projects 仓库元信息缓存目录(默认 dev仓库默认 gitignore
# 社交媒体链接:显示在侧边栏底部;可按需增删
social:
- name: GitHub
@@ -54,16 +82,13 @@ social:
navigation:
- name: 常用 # 菜单名称
icon: fas fa-star # Font Awesome 图标类
id: home # 页面标识符(唯一,需与 pages/<id>.yml 对应)
id: common # 页面标识符(唯一,需与 pages/<id>.yml 对应)
- name: 项目
icon: fas fa-project-diagram
id: projects
- name: 文章
icon: fas fa-book
id: articles
- name: 朋友
icon: fas fa-users
id: friends
- name: 书签
icon: fas fa-bookmark
id: bookmarks