markshelf 0.2.2 → 0.2.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (235) hide show
  1. package/.next/standalone/.next/BUILD_ID +1 -1
  2. package/.next/standalone/.next/build-manifest.json +6 -6
  3. package/.next/standalone/.next/prerender-manifest.json +3 -3
  4. package/.next/standalone/.next/server/app/_global-error/page/build-manifest.json +3 -3
  5. package/.next/standalone/.next/server/app/_global-error/page.js +3 -3
  6. package/.next/standalone/.next/server/app/_global-error/page.js.nft.json +1 -1
  7. package/.next/standalone/.next/server/app/_global-error.html +1 -1
  8. package/.next/standalone/.next/server/app/_global-error.rsc +1 -1
  9. package/.next/standalone/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +1 -1
  10. package/.next/standalone/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
  11. package/.next/standalone/.next/server/app/_global-error.segments/_head.segment.rsc +1 -1
  12. package/.next/standalone/.next/server/app/_global-error.segments/_index.segment.rsc +1 -1
  13. package/.next/standalone/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
  14. package/.next/standalone/.next/server/app/_not-found/page/build-manifest.json +3 -3
  15. package/.next/standalone/.next/server/app/_not-found/page.js +3 -3
  16. package/.next/standalone/.next/server/app/_not-found/page.js.nft.json +1 -1
  17. package/.next/standalone/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
  18. package/.next/standalone/.next/server/app/_not-found.html +1 -1
  19. package/.next/standalone/.next/server/app/_not-found.rsc +2 -2
  20. package/.next/standalone/.next/server/app/_not-found.segments/_full.segment.rsc +2 -2
  21. package/.next/standalone/.next/server/app/_not-found.segments/_head.segment.rsc +1 -1
  22. package/.next/standalone/.next/server/app/_not-found.segments/_index.segment.rsc +2 -2
  23. package/.next/standalone/.next/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +1 -1
  24. package/.next/standalone/.next/server/app/_not-found.segments/_not-found.segment.rsc +1 -1
  25. package/.next/standalone/.next/server/app/_not-found.segments/_tree.segment.rsc +2 -2
  26. package/.next/standalone/.next/server/app/api/asset/route.js.nft.json +1 -1
  27. package/.next/standalone/.next/server/app/api/diff/route.js +2 -2
  28. package/.next/standalone/.next/server/app/api/diff/route.js.nft.json +1 -1
  29. package/.next/standalone/.next/server/app/api/file/route.js.nft.json +1 -1
  30. package/.next/standalone/.next/server/app/api/graph/route.js.nft.json +1 -1
  31. package/.next/standalone/.next/server/app/api/history/route.js +2 -2
  32. package/.next/standalone/.next/server/app/api/history/route.js.nft.json +1 -1
  33. package/.next/standalone/.next/server/app/api/search/route.js.nft.json +1 -1
  34. package/.next/standalone/.next/server/app/api/timeline/route.js +2 -2
  35. package/.next/standalone/.next/server/app/api/timeline/route.js.nft.json +1 -1
  36. package/.next/standalone/.next/server/app/api/tree/route.js.nft.json +1 -1
  37. package/.next/standalone/.next/server/app/index.html +1 -1
  38. package/.next/standalone/.next/server/app/index.rsc +3 -3
  39. package/.next/standalone/.next/server/app/index.segments/__PAGE__.segment.rsc +2 -2
  40. package/.next/standalone/.next/server/app/index.segments/_full.segment.rsc +3 -3
  41. package/.next/standalone/.next/server/app/index.segments/_head.segment.rsc +1 -1
  42. package/.next/standalone/.next/server/app/index.segments/_index.segment.rsc +2 -2
  43. package/.next/standalone/.next/server/app/index.segments/_tree.segment.rsc +2 -2
  44. package/.next/standalone/.next/server/app/page/build-manifest.json +3 -3
  45. package/.next/standalone/.next/server/app/page.js +3 -3
  46. package/.next/standalone/.next/server/app/page.js.nft.json +1 -1
  47. package/.next/standalone/.next/server/app/page_client-reference-manifest.js +1 -1
  48. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0-_k816._.js +1 -1
  49. package/.next/standalone/.next/server/chunks/[root-of-the-server]__01e7zo7._.js +1 -1
  50. package/.next/standalone/.next/server/chunks/[root-of-the-server]__04mxfkc._.js +1 -1
  51. package/.next/standalone/.next/server/chunks/[root-of-the-server]__04y6-r0._.js +4 -0
  52. package/.next/standalone/.next/server/chunks/[root-of-the-server]__053gm34._.js +1 -1
  53. package/.next/standalone/.next/server/chunks/[root-of-the-server]__09ya8im._.js +3 -0
  54. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0i.wyss._.js +1 -1
  55. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0k4icrn._.js +3 -0
  56. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0op9af~._.js +1 -1
  57. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0t-.934._.js +3 -0
  58. package/.next/standalone/.next/server/chunks/[root-of-the-server]__13vatcq._.js +1 -1
  59. package/.next/standalone/.next/server/chunks/node_modules_next_dist_esm_build_templates_app-route_0m.429v.js +1 -1
  60. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__01.l28-._.js +3 -0
  61. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__01rprsr._.js +3 -0
  62. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__03ck6d2._.js +3 -0
  63. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__05fmntc._.js +3 -0
  64. package/.next/standalone/.next/server/chunks/ssr/{[root-of-the-server]__0_o.omz._.js → [root-of-the-server]__05tr62g._.js} +2 -2
  65. package/.next/standalone/.next/server/chunks/ssr/{[root-of-the-server]__0u7hi3-._.js → [root-of-the-server]__086mpiv._.js} +2 -2
  66. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__09qrkq5._.js +4 -4
  67. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0_5115u._.js +3 -0
  68. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0bb8oda._.js +3 -0
  69. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0bd.lu~._.js +3 -0
  70. package/.next/standalone/.next/server/chunks/ssr/{[root-of-the-server]__05ar4zx._.js → [root-of-the-server]__0d1c58~._.js} +2 -2
  71. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0f.8h3t._.js +3 -0
  72. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0f_1wxu._.js +3 -0
  73. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0iwc7oc._.js +3 -0
  74. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0j63551._.js +3 -0
  75. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0j_j_lp._.js +3 -0
  76. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0n1ij50._.js +3 -0
  77. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0uzyvey._.js +3 -0
  78. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__11hul.m._.js +3 -0
  79. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__13z1ev9._.js +3 -0
  80. package/.next/standalone/.next/server/chunks/ssr/{node_modules_0m258l0._.js → node_modules_00r~6av._.js} +2 -2
  81. package/.next/standalone/.next/server/chunks/ssr/node_modules_05l396c._.js +3 -0
  82. package/.next/standalone/.next/server/chunks/ssr/{node_modules_035nqw0._.js → node_modules_05lp.r.._.js} +2 -2
  83. package/.next/standalone/.next/server/chunks/ssr/{node_modules_0d0g.gp._.js → node_modules_070pb23._.js} +2 -2
  84. package/.next/standalone/.next/server/chunks/ssr/{node_modules_0uebmgu._.js → node_modules_08o~z._._.js} +2 -2
  85. package/.next/standalone/.next/server/chunks/ssr/{node_modules_0~vmgv6._.js → node_modules_0k66hfg._.js} +2 -2
  86. package/.next/standalone/.next/server/chunks/ssr/{node_modules_0sxu8tl._.js → node_modules_0kc_w1l._.js} +2 -2
  87. package/.next/standalone/.next/server/chunks/ssr/{node_modules_0_lpyzd._.js → node_modules_0m_rzcx._.js} +2 -2
  88. package/.next/standalone/.next/server/chunks/ssr/{node_modules_0ub-k6d._.js → node_modules_0~o049i._.js} +2 -2
  89. package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_0.jrk~x._.js +1 -1
  90. package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_0ppctuh._.js +19 -0
  91. package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_esm_build_templates_app-page_03-z2qq.js +2 -2
  92. package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_esm_build_templates_app-page_07vh7rm.js +2 -2
  93. package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_esm_build_templates_app-page_0qp4u6g.js +2 -2
  94. package/.next/standalone/.next/server/middleware-build-manifest.js +6 -6
  95. package/.next/standalone/.next/server/pages/404.html +1 -1
  96. package/.next/standalone/.next/server/pages/500.html +1 -1
  97. package/.next/standalone/.next/server/server-reference-manifest.js +1 -1
  98. package/.next/standalone/.next/server/server-reference-manifest.json +1 -1
  99. package/.next/standalone/.next/static/chunks/{0-mgdjw03nw5i.js → 00_m52wgaznut.js} +1 -1
  100. package/.next/standalone/.next/static/chunks/044c~ak~uxs77.js +5 -0
  101. package/.next/standalone/.next/static/chunks/{0.9a.v2u8pdez.css → 0l2qiktz0q_g..css} +1 -1
  102. package/.next/{static/chunks/10.v6fb-ptj.a.js → standalone/.next/static/chunks/0mdgmoqrwz~wx.js} +4 -4
  103. package/.next/standalone/.next/static/chunks/{turbopack-0uufb5vlljeny.js → turbopack-16gy5uwpc4o1_.js} +1 -1
  104. package/.next/standalone/DEPLOY.md +91 -0
  105. package/.next/standalone/docker/Dockerfile.demo +55 -0
  106. package/.next/standalone/docker/Dockerfile.demo.dockerignore +28 -0
  107. package/.next/standalone/docs//344/273/225/346/247/230/SPEC1-CLI/SPEC1.1-bin-cli.md +1 -1
  108. package/.next/standalone/docs//344/273/225/346/247/230/SPEC1-CLI/SPEC1.2-Dockerfile.md +1 -1
  109. package/.next/standalone/docs//344/273/225/346/247/230/SPEC1-CLI/SPEC1.3-basePath.md +1 -1
  110. package/.next/standalone/docs//344/273/225/346/247/230/SPEC1-CLI/SPEC1.4-/347/222/260/345/242/203/345/244/211/346/225/260.md +1 -1
  111. package/.next/standalone/docs//344/273/225/346/247/230/SPEC2-/343/202/260/343/203/251/343/203/225/346/217/217/347/224/273/SPEC2.1-graph-api.md +1 -1
  112. package/.next/standalone/docs//344/273/225/346/247/230/SPEC2-/343/202/260/343/203/251/343/203/225/346/217/217/347/224/273/SPEC2.2-breadthfirst-layout.md +1 -1
  113. package/.next/standalone/docs//344/273/225/346/247/230/SPEC2-/343/202/260/343/203/251/343/203/225/346/217/217/347/224/273/SPEC2.3-/343/203/252/343/203/263/343/202/257/350/247/243/346/236/220.md +1 -1
  114. package/.next/standalone/docs//344/273/225/346/247/230/SPEC3-UI/343/202/263/343/203/263/343/203/235/343/203/274/343/203/215/343/203/263/343/203/210/SPEC3.1-PreviewPopup.md +1 -1
  115. package/.next/standalone/docs//344/273/225/346/247/230/SPEC3-UI/343/202/263/343/203/263/343/203/235/343/203/274/343/203/215/343/203/263/343/203/210/SPEC3.2-TreeView.md +1 -1
  116. package/.next/standalone/docs//344/273/225/346/247/230/SPEC3-UI/343/202/263/343/203/263/343/203/235/343/203/274/343/203/215/343/203/263/343/203/210/SPEC3.3-TableOfContents.md +2 -1
  117. package/.next/standalone/docs//344/273/225/346/247/230/SPEC3-UI/343/202/263/343/203/263/343/203/235/343/203/274/343/203/215/343/203/263/343/203/210/SPEC3.4-DetailPanel/343/202/277/343/203/226.md +2 -1
  118. package/.next/standalone/docs//344/273/225/346/247/230/SPEC3-UI/343/202/263/343/203/263/343/203/235/343/203/274/343/203/215/343/203/263/343/203/210/SPEC3.5-Markdown/343/203/254/343/203/263/343/203/200/343/203/252/343/203/263/343/202/260.md +5 -2
  119. package/.next/standalone/docs//344/273/225/346/247/230/SPEC3-UI/343/202/263/343/203/263/343/203/235/343/203/274/343/203/215/343/203/263/343/203/210/SPEC3.6-SearchBar.md +2 -2
  120. package/.next/standalone/docs//344/273/225/346/247/230/SPEC3-UI/343/202/263/343/203/263/343/203/235/343/203/274/343/203/215/343/203/263/343/203/210/SPEC3.7-/343/203/221/343/203/215/343/203/253/343/203/252/343/202/265/343/202/244/343/202/266/343/203/274.md +1 -1
  121. package/.next/standalone/docs//344/273/225/346/247/230/SPEC3-UI/343/202/263/343/203/263/343/203/235/343/203/274/343/203/215/343/203/263/343/203/210/SPEC3.8-/347/224/273/345/203/217/343/203/227/343/203/254/343/203/223/343/203/245/343/203/274.md +1 -1
  122. package/.next/standalone/docs//344/273/225/346/247/230/SPEC4-API/SPEC4.1-tree.md +1 -1
  123. package/.next/standalone/docs//344/273/225/346/247/230/SPEC4-API/SPEC4.2-file.md +1 -1
  124. package/.next/standalone/docs//344/273/225/346/247/230/SPEC4-API/SPEC4.3-search.md +1 -1
  125. package/.next/standalone/docs//344/273/225/346/247/230/SPEC4-API/SPEC4.4-watch.md +1 -1
  126. package/.next/standalone/docs//344/273/225/346/247/230/SPEC4-API/SPEC4.5-history.md +1 -1
  127. package/.next/standalone/docs//344/273/225/346/247/230/SPEC4-API/SPEC4.6-timeline.md +1 -1
  128. package/.next/standalone/docs//344/273/225/346/247/230/SPEC4-API/SPEC4.7-diff.md +1 -1
  129. package/.next/standalone/docs//344/273/225/346/247/230/SPEC4-API/SPEC4.8-asset.md +1 -1
  130. package/.next/standalone/docs//344/273/225/346/247/230/SPEC5-/346/260/270/347/266/232/345/214/226/README.md +1 -1
  131. package/.next/standalone/docs//344/273/225/346/247/230/SPEC5-/346/260/270/347/266/232/345/214/226/SPEC5.1-localStorage.md +6 -6
  132. package/.next/standalone/docs//344/273/225/346/247/230/SPEC5-/346/260/270/347/266/232/345/214/226/SPEC5.2-URL/343/202/257/343/202/250/343/203/252.md +10 -1
  133. package/.next/standalone/docs//347/224/250/350/252/236/351/233/206/Mermaid.md +5 -0
  134. package/.next/standalone/docs//350/246/201/344/273/266/345/256/232/347/276/251/REQ4-/343/203/212/343/203/223/343/202/262/343/203/274/343/202/267/343/203/247/343/203/263/REQ4.2-/345/205/261/346/234/211/345/217/257/350/203/275URL.md +8 -0
  135. package/.next/standalone/docs//350/246/201/346/261/202/345/256/232/347/276/251/R1-/343/203/211/343/202/255/343/203/245/343/203/241/343/203/263/343/203/210/351/226/262/350/246/247/346/200/247/R1.5-/345/205/261/346/234/211/345/217/257/350/203/275URL.md +3 -1
  136. package/.next/standalone/eslint.config.mjs +55 -0
  137. package/.next/standalone/fly.preview.toml +33 -0
  138. package/.next/standalone/fly.toml +38 -0
  139. package/.next/standalone/loop/progress.md +26 -0
  140. package/.next/standalone/loop/run-loop.md +51 -0
  141. package/.next/standalone/node_modules/@next/env/package.json +1 -1
  142. package/.next/standalone/node_modules/next/dist/build/static-paths/app.js +2 -1
  143. package/.next/standalone/node_modules/next/dist/build/swc/index.js +1 -1
  144. package/.next/standalone/node_modules/next/dist/build/utils.js +2 -1
  145. package/.next/standalone/node_modules/next/dist/client/components/router-reducer/fetch-server-response.js +2 -2
  146. package/.next/standalone/node_modules/next/dist/client/components/router-reducer/set-cache-busting-search-param.js +8 -2
  147. package/.next/standalone/node_modules/next/dist/client/route-params.js +23 -6
  148. package/.next/standalone/node_modules/next/dist/compiled/next-server/app-page-turbo-experimental.runtime.prod.js +13 -13
  149. package/.next/standalone/node_modules/next/dist/compiled/next-server/app-page-turbo.runtime.prod.js +11 -11
  150. package/.next/standalone/node_modules/next/dist/compiled/next-server/app-route-turbo.runtime.prod.js +2 -2
  151. package/.next/standalone/node_modules/next/dist/compiled/next-server/pages-turbo.runtime.prod.js +10 -10
  152. package/.next/standalone/node_modules/next/dist/lib/patch-incorrect-lockfile.js +3 -3
  153. package/.next/standalone/node_modules/next/dist/server/app-render/action-handler.js +3 -6
  154. package/.next/standalone/node_modules/next/dist/server/app-render/app-render.js +62 -9
  155. package/.next/standalone/node_modules/next/dist/server/app-render/collect-segment-data.js +16 -0
  156. package/.next/standalone/node_modules/next/dist/server/app-render/create-component-tree.js +49 -19
  157. package/.next/standalone/node_modules/next/dist/server/app-render/get-script-nonce-from-header.js +8 -20
  158. package/.next/standalone/node_modules/next/dist/server/app-render/metadata-insertion/create-server-inserted-metadata.js +8 -7
  159. package/.next/standalone/node_modules/next/dist/server/app-render/use-flight-response.js +2 -2
  160. package/.next/standalone/node_modules/next/dist/server/async-storage/work-store.js +2 -1
  161. package/.next/standalone/node_modules/next/dist/server/base-server.js +13 -5
  162. package/.next/standalone/node_modules/next/dist/server/config.js +1 -1
  163. package/.next/standalone/node_modules/next/dist/server/dev/hot-reloader-turbopack.js +2 -2
  164. package/.next/standalone/node_modules/next/dist/server/dev/hot-reloader-webpack.js +1 -1
  165. package/.next/standalone/node_modules/next/dist/server/dev/static-paths-worker.js +2 -1
  166. package/.next/standalone/node_modules/next/dist/server/image-optimizer.js +22 -2
  167. package/.next/standalone/node_modules/next/dist/server/lib/app-info-log.js +1 -1
  168. package/.next/standalone/node_modules/next/dist/server/lib/is-rsc-request.js +18 -0
  169. package/.next/standalone/node_modules/next/dist/server/lib/mock-request.js +30 -5
  170. package/.next/standalone/node_modules/next/dist/server/lib/patch-set-header.js +7 -0
  171. package/.next/standalone/node_modules/next/dist/server/lib/router-server.js +6 -3
  172. package/.next/standalone/node_modules/next/dist/server/lib/router-utils/resolve-routes.js +18 -4
  173. package/.next/standalone/node_modules/next/dist/server/lib/server-ipc/utils.js +3 -1
  174. package/.next/standalone/node_modules/next/dist/server/lib/start-server.js +1 -1
  175. package/.next/standalone/node_modules/next/dist/server/next-server.js +1 -1
  176. package/.next/standalone/node_modules/next/dist/server/request/fallback-params.js +27 -1
  177. package/.next/standalone/node_modules/next/dist/server/route-modules/app-route/module.js +1 -0
  178. package/.next/standalone/node_modules/next/dist/server/route-modules/route-module.js +11 -1
  179. package/.next/standalone/node_modules/next/dist/server/server-utils.js +19 -2
  180. package/.next/standalone/node_modules/next/dist/server/stream-utils/node-web-streams-helper.js +5 -5
  181. package/.next/standalone/node_modules/next/dist/server/use-cache/use-cache-wrapper.js +1 -1
  182. package/.next/standalone/node_modules/next/dist/server/web/adapter.js +4 -1
  183. package/.next/standalone/node_modules/next/dist/server/web/edge-route-module-wrapper.js +2 -1
  184. package/.next/standalone/node_modules/next/dist/shared/lib/errors/canary-only-config-error.js +1 -1
  185. package/.next/standalone/node_modules/next/dist/{server → shared/lib}/htmlescape.js +15 -0
  186. package/.next/standalone/node_modules/next/dist/shared/lib/router/routes/app.js +13 -1
  187. package/.next/standalone/node_modules/next/dist/shared/lib/router/utils/cache-busting-search-param.js +56 -10
  188. package/.next/standalone/node_modules/next/dist/telemetry/anonymous-meta.js +1 -1
  189. package/.next/standalone/node_modules/next/dist/telemetry/events/swc-load-failure.js +1 -1
  190. package/.next/standalone/node_modules/next/dist/telemetry/events/version.js +2 -2
  191. package/.next/standalone/node_modules/next/package.json +15 -15
  192. package/.next/standalone/package-lock.json +4138 -525
  193. package/.next/standalone/package.json +13 -3
  194. package/.next/standalone/scripts/smoke-test.sh +40 -0
  195. package/.next/standalone/src/app/page.tsx +9 -0
  196. package/.next/standalone/src/components/DetailPanel.tsx +34 -0
  197. package/.next/standalone/src/components/Markdown.tsx +68 -10
  198. package/.next/standalone/src/components/TableOfContents.tsx +7 -0
  199. package/.next/standalone/src/lib/links.test.ts +68 -0
  200. package/.next/standalone/vitest.config.ts +8 -0
  201. package/.next/static/chunks/{0-mgdjw03nw5i.js → 00_m52wgaznut.js} +1 -1
  202. package/.next/static/chunks/044c~ak~uxs77.js +5 -0
  203. package/.next/static/chunks/{0.9a.v2u8pdez.css → 0l2qiktz0q_g..css} +1 -1
  204. package/.next/{standalone/.next/static/chunks/10.v6fb-ptj.a.js → static/chunks/0mdgmoqrwz~wx.js} +4 -4
  205. package/.next/static/chunks/{turbopack-0uufb5vlljeny.js → turbopack-16gy5uwpc4o1_.js} +1 -1
  206. package/package.json +13 -3
  207. package/.next/standalone/.next/server/chunks/[root-of-the-server]__00jpzal._.js +0 -4
  208. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0d.-s5p._.js +0 -3
  209. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0nr71d2._.js +0 -3
  210. package/.next/standalone/.next/server/chunks/[root-of-the-server]__0rwylex._.js +0 -3
  211. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__05-we0.._.js +0 -3
  212. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__05v7q28._.js +0 -3
  213. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0ax36b7._.js +0 -3
  214. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0c2g0v3._.js +0 -3
  215. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0e3so8g._.js +0 -3
  216. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0mwp_9m._.js +0 -3
  217. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0n3ik5m._.js +0 -3
  218. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0q9c57y._.js +0 -3
  219. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0r-95-k._.js +0 -3
  220. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0shsacv._.js +0 -3
  221. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0ta32-~._.js +0 -3
  222. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__0~65l4k._.js +0 -3
  223. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__10szabd._.js +0 -3
  224. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__131xoj~._.js +0 -3
  225. package/.next/standalone/.next/server/chunks/ssr/[root-of-the-server]__13_.rw3._.js +0 -3
  226. package/.next/standalone/.next/server/chunks/ssr/node_modules_0vtdjw7._.js +0 -3
  227. package/.next/standalone/.next/server/chunks/ssr/node_modules_next_dist_03nkrli._.js +0 -19
  228. package/.next/standalone/.next/static/chunks/15s~ckf06mjoj.js +0 -5
  229. package/.next/static/chunks/15s~ckf06mjoj.js +0 -5
  230. /package/.next/standalone/.next/static/{03Y0Qmra9pQhnypCdj6Wp → i-NjNCumIJ0s9aQuDXbGX}/_buildManifest.js +0 -0
  231. /package/.next/standalone/.next/static/{03Y0Qmra9pQhnypCdj6Wp → i-NjNCumIJ0s9aQuDXbGX}/_clientMiddlewareManifest.js +0 -0
  232. /package/.next/standalone/.next/static/{03Y0Qmra9pQhnypCdj6Wp → i-NjNCumIJ0s9aQuDXbGX}/_ssgManifest.js +0 -0
  233. /package/.next/static/{03Y0Qmra9pQhnypCdj6Wp → i-NjNCumIJ0s9aQuDXbGX}/_buildManifest.js +0 -0
  234. /package/.next/static/{03Y0Qmra9pQhnypCdj6Wp → i-NjNCumIJ0s9aQuDXbGX}/_clientMiddlewareManifest.js +0 -0
  235. /package/.next/static/{03Y0Qmra9pQhnypCdj6Wp → i-NjNCumIJ0s9aQuDXbGX}/_ssgManifest.js +0 -0
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "markshelf",
3
- "version": "0.2.2",
3
+ "version": "0.2.3",
4
4
  "description": "Structured markdown viewer for git repositories",
5
5
  "license": "MIT",
6
6
  "author": "sksp.work",
@@ -36,6 +36,10 @@
36
36
  "dev": "next dev --hostname 0.0.0.0",
37
37
  "build": "next build && node scripts/pack-static.mjs",
38
38
  "start": "next start",
39
+ "lint": "eslint .",
40
+ "typecheck": "tsc --noEmit",
41
+ "test": "vitest run",
42
+ "test:watch": "vitest",
39
43
  "docker:build": "docker build -t markshelf-base .",
40
44
  "docker:run": "node scripts/docker-run.mjs",
41
45
  "prepublishOnly": "npm run build"
@@ -45,7 +49,7 @@
45
49
  "cytoscape": "^3.33.2",
46
50
  "lucide-react": "^1.8.0",
47
51
  "mermaid": "^11.14.0",
48
- "next": "16.2.4",
52
+ "next": "16.2.6",
49
53
  "react": "19.2.4",
50
54
  "react-dom": "19.2.4",
51
55
  "react-markdown": "^10.1.0",
@@ -53,12 +57,18 @@
53
57
  "simple-git": "^3.36.0"
54
58
  },
55
59
  "devDependencies": {
60
+ "@next/eslint-plugin-next": "^16.2.4",
56
61
  "@tailwindcss/postcss": "^4",
57
62
  "@types/cytoscape": "^3.21.9",
58
63
  "@types/node": "^20",
59
64
  "@types/react": "^19",
60
65
  "@types/react-dom": "^19",
66
+ "eslint": "^9.39.4",
67
+ "eslint-plugin-react-hooks": "^6.1.1",
68
+ "globals": "^16.5.0",
61
69
  "tailwindcss": "^4",
62
- "typescript": "^5"
70
+ "typescript": "^5",
71
+ "typescript-eslint": "^8.62.0",
72
+ "vitest": "^3.2.6"
63
73
  }
64
74
  }
@@ -0,0 +1,40 @@
1
+ #!/usr/bin/env bash
2
+ #
3
+ # Post-deploy smoke test: verify the LIVE markshelf deployment actually serves
4
+ # the baked docs and that its git-backed APIs work. Run by the deploy workflow
5
+ # after `flyctl deploy`, but also usable locally:
6
+ #
7
+ # scripts/smoke-test.sh https://markshelf-demo.fly.dev
8
+ #
9
+ set -euo pipefail
10
+
11
+ BASE="${1:?usage: smoke-test.sh <base-url>}"
12
+ BASE="${BASE%/}" # strip trailing slash
13
+ TMP="$(mktemp -d)"
14
+ trap 'rm -rf "$TMP"' EXIT
15
+
16
+ fail() { echo "❌ $1"; exit 1; }
17
+
18
+ # Common curl options: retry through cold starts / brief 5xx while the machine boots.
19
+ CURL=(curl -sS --retry 8 --retry-all-errors --retry-delay 5 --max-time 30)
20
+
21
+ echo "→ Smoke testing $BASE"
22
+
23
+ # 1. Home page renders (HTTP 200 + app shell)
24
+ code="$("${CURL[@]}" -o "$TMP/home.html" -w '%{http_code}' "$BASE/")"
25
+ [ "$code" = "200" ] || fail "home page returned HTTP $code"
26
+ grep -qi "markshelf" "$TMP/home.html" || fail "home page missing 'markshelf' marker"
27
+ echo " ✓ home page (200)"
28
+
29
+ # 2. Tree API returns the baked docs (confirms docs/ was actually bundled)
30
+ "${CURL[@]}" -o "$TMP/tree.json" "$BASE/api/tree"
31
+ grep -q '要求定義' "$TMP/tree.json" || fail "/api/tree missing expected docs content (要求定義)"
32
+ echo " ✓ /api/tree serves docs"
33
+
34
+ # 3. Timeline API returns at least one entry (confirms .git history was baked
35
+ # and git safe.directory is configured — otherwise this is silently empty)
36
+ "${CURL[@]}" -o "$TMP/timeline.json" "$BASE/api/timeline"
37
+ grep -q '"hash"' "$TMP/timeline.json" || fail "/api/timeline has no entries — git history not available in the image"
38
+ echo " ✓ /api/timeline reflects git history"
39
+
40
+ echo "✅ Smoke test passed"
@@ -61,6 +61,15 @@ export default function Home() {
61
61
  setBackStack((s) => [...s, selectedPath]);
62
62
  setForwardStack([]);
63
63
  }
64
+ // Switching files drops any heading hash — it points at a heading in the
65
+ // file we're leaving. Shared-link loads bypass navigateTo and keep theirs.
66
+ if (path !== selectedPath && typeof window !== "undefined" && window.location.hash) {
67
+ window.history.replaceState(
68
+ null,
69
+ "",
70
+ window.location.pathname + window.location.search,
71
+ );
72
+ }
64
73
  setSelectedPath(path);
65
74
  }, [selectedPath]);
66
75
 
@@ -64,6 +64,39 @@ export function DetailPanel({ filePath, fileRefs, folders, onNavigate, onGoBack,
64
64
  .catch(() => setContent(null));
65
65
  }, [filePath, refreshTick]);
66
66
 
67
+ // When opened via a shared link (?file=...#heading-id), scroll the matching
68
+ // heading into view once its content has rendered. Runs once per file load.
69
+ const scrolledHashRef = useRef<string | null>(null);
70
+ useEffect(() => {
71
+ scrolledHashRef.current = null;
72
+ }, [filePath]);
73
+ useEffect(() => {
74
+ if (tab !== "content" || content === null || headings.length === 0) return;
75
+ if (typeof window === "undefined") return;
76
+ const rawHash = window.location.hash.replace(/^#/, "");
77
+ if (!rawHash) return;
78
+ let hash = rawHash;
79
+ try {
80
+ hash = decodeURIComponent(rawHash);
81
+ } catch {
82
+ /* keep raw */
83
+ }
84
+ const key = `${filePath}#${hash}`;
85
+ if (scrolledHashRef.current === key) return;
86
+ if (!headings.some((h) => h.id === hash)) return;
87
+
88
+ const raf = requestAnimationFrame(() => {
89
+ const container = scrollRef.current;
90
+ const el = document.getElementById(hash);
91
+ if (!container || !el) return;
92
+ const cRect = container.getBoundingClientRect();
93
+ const eRect = el.getBoundingClientRect();
94
+ container.scrollTop += eRect.top - cRect.top - 16;
95
+ scrolledHashRef.current = key;
96
+ });
97
+ return () => cancelAnimationFrame(raf);
98
+ }, [tab, content, headings, filePath]);
99
+
67
100
  const handlePreviewShow = useCallback((path: string, rect: DOMRect) => {
68
101
  if (hideTimer.current) clearTimeout(hideTimer.current);
69
102
  if (showTimer.current) clearTimeout(showTimer.current);
@@ -183,6 +216,7 @@ export function DetailPanel({ filePath, fileRefs, folders, onNavigate, onGoBack,
183
216
  <div className="flex-1 overflow-y-auto" ref={scrollRef}>
184
217
  <div className="p-4">
185
218
  <Markdown
219
+ enableHeadingLinks
186
220
  onHeadingsExtracted={setHeadings}
187
221
  fileRefs={fileRefs}
188
222
  currentPath={filePath}
@@ -1,8 +1,9 @@
1
1
  "use client";
2
2
 
3
- import { useEffect, useMemo } from "react";
3
+ import { useEffect, useMemo, useState } from "react";
4
4
  import ReactMarkdown, { Components } from "react-markdown";
5
5
  import remarkGfm from "remark-gfm";
6
+ import { Link2, Check } from "lucide-react";
6
7
  import type { HeadingInfo } from "./TableOfContents";
7
8
  import { MermaidBlock } from "./MermaidBlock";
8
9
  import { withBasePath } from "@/lib/basePath";
@@ -20,6 +21,47 @@ interface Props {
20
21
  onNavigate?: (path: string) => void;
21
22
  onPreviewShow?: (path: string, rect: DOMRect) => void;
22
23
  onPreviewHide?: () => void;
24
+ /** Show a per-heading anchor link that copies a shareable URL (main content only). */
25
+ enableHeadingLinks?: boolean;
26
+ }
27
+
28
+ /**
29
+ * Anchor rendered next to a heading. Clicking it points the URL hash at the
30
+ * heading and copies the resulting shareable link (?file=...#heading-id) to the
31
+ * clipboard so it can be sent to someone else and opened scrolled to that spot.
32
+ */
33
+ function HeadingAnchor({ id }: { id: string }) {
34
+ const [copied, setCopied] = useState(false);
35
+
36
+ const handleClick = (e: React.MouseEvent) => {
37
+ e.preventDefault();
38
+ if (typeof window === "undefined") return;
39
+ const url = new URL(window.location.href);
40
+ url.hash = id;
41
+ const full = url.toString();
42
+ window.history.replaceState(null, "", full);
43
+ const done = () => {
44
+ setCopied(true);
45
+ window.setTimeout(() => setCopied(false), 1500);
46
+ };
47
+ if (navigator.clipboard?.writeText) {
48
+ navigator.clipboard.writeText(full).then(done).catch(done);
49
+ } else {
50
+ done();
51
+ }
52
+ };
53
+
54
+ return (
55
+ <a
56
+ href={`#${id}`}
57
+ onClick={handleClick}
58
+ className="ml-2 inline-flex items-center align-middle text-[var(--text-muted)] no-underline opacity-0 group-hover:opacity-100 focus:opacity-100 hover:text-[var(--brand-primary)] transition-opacity"
59
+ title={copied ? "リンクをコピーしました" : "このヘッダーへのリンクをコピー"}
60
+ aria-label="このヘッダーへのリンクをコピー"
61
+ >
62
+ {copied ? <Check size={13} /> : <Link2 size={13} />}
63
+ </a>
64
+ );
23
65
  }
24
66
 
25
67
  function slugify(text: string): string {
@@ -73,6 +115,7 @@ export function Markdown({
73
115
  onNavigate,
74
116
  onPreviewShow,
75
117
  onPreviewHide,
118
+ enableHeadingLinks = false,
76
119
  }: Props) {
77
120
  // Parse headings deterministically from the markdown source
78
121
  const headings = useMemo(() => parseHeadings(children), [children]);
@@ -210,19 +253,34 @@ export function Markdown({
210
253
  }
211
254
 
212
255
  function makeHeadingComponent(level: number) {
213
- return function HeadingWithId(props: React.HTMLAttributes<HTMLHeadingElement>) {
256
+ return function HeadingWithId({
257
+ children: headingChildren,
258
+ className,
259
+ ...props
260
+ }: React.HTMLAttributes<HTMLHeadingElement>) {
214
261
  const text =
215
- typeof props.children === "string"
216
- ? props.children
217
- : extractText(props.children);
262
+ typeof headingChildren === "string"
263
+ ? headingChildren
264
+ : extractText(headingChildren);
218
265
  const id = getIdForHeading(text);
219
266
 
220
- const hProps = { ...props, id };
267
+ // `scroll-mt-4` keeps the heading clear of the container's top edge when
268
+ // scrolled to via a shared hash link; `group` drives the anchor's hover.
269
+ const mergedClassName = enableHeadingLinks
270
+ ? `group scroll-mt-4${className ? ` ${className}` : ""}`
271
+ : className;
272
+ const hProps = { ...props, id, className: mergedClassName };
273
+ const inner = (
274
+ <>
275
+ {headingChildren}
276
+ {enableHeadingLinks && <HeadingAnchor id={id} />}
277
+ </>
278
+ );
221
279
  switch (level) {
222
- case 1: return <h1 {...hProps} />;
223
- case 2: return <h2 {...hProps} />;
224
- case 3: return <h3 {...hProps} />;
225
- default: return <h4 {...hProps} />;
280
+ case 1: return <h1 {...hProps}>{inner}</h1>;
281
+ case 2: return <h2 {...hProps}>{inner}</h2>;
282
+ case 3: return <h3 {...hProps}>{inner}</h3>;
283
+ default: return <h4 {...hProps}>{inner}</h4>;
226
284
  }
227
285
  };
228
286
  }
@@ -46,6 +46,13 @@ export function TableOfContents({ headings, scrollContainer }: Props) {
46
46
  if (el) {
47
47
  el.scrollIntoView({ behavior: "smooth", block: "start" });
48
48
  setActiveId(id);
49
+ // Reflect the section in the URL hash so the address bar stays a
50
+ // shareable deep link (?file=...#heading-id) without adding history.
51
+ if (typeof window !== "undefined") {
52
+ const url = new URL(window.location.href);
53
+ url.hash = id;
54
+ window.history.replaceState(null, "", url.toString());
55
+ }
49
56
  }
50
57
  },
51
58
  [],
@@ -0,0 +1,68 @@
1
+ import { describe, it, expect } from "vitest";
2
+ import { buildLinkGraph } from "./links";
3
+ import type { FileRef } from "./docs";
4
+
5
+ // readFile を差し替えてグラフ生成のみを純粋に検証する。
6
+ function graphOf(files: FileRef[], contents: Record<string, string>) {
7
+ return buildLinkGraph(files, (p) => contents[p] ?? null);
8
+ }
9
+
10
+ describe("buildLinkGraph", () => {
11
+ it("明示的な相対リンクをエッジにする", () => {
12
+ const files: FileRef[] = [
13
+ { path: "a.md", displayName: "a-document" },
14
+ { path: "b.md", displayName: "b-document" },
15
+ ];
16
+ const { edges } = graphOf(files, {
17
+ "a.md": "[B へ](b.md)",
18
+ "b.md": "# b",
19
+ });
20
+ expect(edges).toEqual([{ source: "a.md", target: "b.md" }]);
21
+ });
22
+
23
+ it("フォルダ宛リンクを README.md に補完する", () => {
24
+ const files: FileRef[] = [
25
+ { path: "a.md", displayName: "a-document" },
26
+ { path: "sub/README.md", displayName: "sub-folder" },
27
+ ];
28
+ const { edges } = graphOf(files, {
29
+ "a.md": "[sub へ](sub/)",
30
+ "sub/README.md": "# sub",
31
+ });
32
+ expect(edges).toEqual([{ source: "a.md", target: "sub/README.md" }]);
33
+ });
34
+
35
+ it("画像リンク・コードブロック内・外部URLはエッジにしない", () => {
36
+ const files: FileRef[] = [
37
+ { path: "a.md", displayName: "a-document" },
38
+ { path: "b.md", displayName: "b-document" },
39
+ ];
40
+ const { edges } = graphOf(files, {
41
+ "a.md": [
42
+ "![alt](b.md)", // 画像は除外
43
+ "`[code](b.md)`", // インラインコードは除外
44
+ "[外部](https://example.com/b.md)", // 外部は除外
45
+ ].join("\n"),
46
+ "b.md": "# b",
47
+ });
48
+ expect(edges).toHaveLength(0);
49
+ });
50
+
51
+ it("本文中の displayName 自動マッチをエッジにする", () => {
52
+ const files: FileRef[] = [
53
+ { path: "a.md", displayName: "a-document" },
54
+ { path: "glossary.md", displayName: "用語サンプル" },
55
+ ];
56
+ const { edges } = graphOf(files, {
57
+ "a.md": "この文書は 用語サンプル を説明する。",
58
+ "glossary.md": "# 用語サンプル",
59
+ });
60
+ expect(edges).toContainEqual({ source: "a.md", target: "glossary.md" });
61
+ });
62
+
63
+ it("自己参照はエッジにしない", () => {
64
+ const files: FileRef[] = [{ path: "a.md", displayName: "a-document" }];
65
+ const { edges } = graphOf(files, { "a.md": "[自分](a.md)" });
66
+ expect(edges).toHaveLength(0);
67
+ });
68
+ });
@@ -0,0 +1,8 @@
1
+ import { defineConfig } from "vitest/config";
2
+
3
+ export default defineConfig({
4
+ test: {
5
+ environment: "node",
6
+ include: ["src/**/*.test.ts", "src/**/*.test.tsx"],
7
+ },
8
+ });