Add 心经 as a second planted book, with a real bookshelf#5
Conversation
我的树 was hardcoded to a single book (道德经). Generalize it into a Book-driven page at /tree/:bookId (src/books/ holds the data model and per-book branch/annotation/echo content), and build the 首页书架 timeline page at / so books can actually be walked into instead of only existing as a route. 心经 is added end-to-end as a Buddhism-themed book: five annotated branches (色空/五蕴/空相/无碍/揭谛), a 入木 and a 青芽 leaf, a thread continuation, its own 周年回声, and a shelf entry on the timeline alongside 道德经, with 论语/庄子 kept as 即将种下 placeholders.
|
Superseded by #10. This PR was the most ambitious of the batch — it introduced What was salvaged into #10: the intent to plant 心經 as a second 佛家 book. The tree/branch data here has been superseded by the Closing in favor of #10. This PR's timeline design was 90% of the reason I trusted the "取之精华" approach — thanks. |
Summary
我的树was hardcoded to a single book (道德经). Generalized it into aBook-driven page at/tree/:bookId, with the data model and per-book content moved tosrc/books/(types.ts,daodejing.ts,xinjing.ts,index.ts).首页书架(Bookshelf) timeline page at/(src/Bookshelf.tsx/.css), a port of the老树 · 首页书架.dc.htmlprototype, so books can actually be walked into instead of我的树only existing as an unreachable route.即将种下placeholders (PLACEHOLDER_BOOKS).react-router-domfor the/and/tree/:bookIdroutes.Test plan
npm run build(type-check + production build) passes/renders the timeline with 道德经, 心经 (live) and 论语, 庄子 (dormant placeholders); clicking a live plank navigates to/tree/:bookId/tree/xinjingrenders 心经's five branches, hover reveals the correct source/annotation/signature per branch, and its own 周年回声/tree/lunyu(a placeholder with no tree yet) shows a "这本书还没有种下" state with a link back to the shelf instead of a blank/broken treeGenerated by Claude Code