collabmd 0.1.33 → 0.1.35

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 (271) hide show
  1. package/dist/client/assets/{CodeMirrorEditor-UCMRAMCV-Bg0dawOb.js → CodeMirrorEditor-UCMRAMCV-CvLFeHXu.js} +1 -1
  2. package/dist/client/assets/_baseFor-Bfo4esZ5.js +1 -0
  3. package/dist/client/assets/arc-tRoMuWFi.js +1 -0
  4. package/dist/client/assets/architecture-YZFGNWBL-CtU43_5T.js +1 -0
  5. package/dist/client/assets/{architectureDiagram-2XIMDMQ5-kYbOThe4.js → architectureDiagram-Q4EWVU46-CVdcOotN.js} +4 -4
  6. package/dist/client/assets/blockDiagram-DXYQGD6D-B_gNUKQ4.js +132 -0
  7. package/dist/client/assets/c4Diagram-AHTNJAMY-BSDwfduG.js +10 -0
  8. package/dist/client/assets/channel-BDb1g_mJ.js +1 -0
  9. package/dist/client/assets/chunk-2KRD3SAO-C6u8y11R.js +1 -0
  10. package/dist/client/assets/chunk-336JU56O-Ch9X5KoM.js +2 -0
  11. package/dist/client/assets/{chunk-HHEYEP7N-DlevL8bq.js → chunk-426QAEUC-CwJ7loGf.js} +1 -1
  12. package/dist/client/assets/chunk-4TB4RGXK-BEsauZP5.js +206 -0
  13. package/dist/client/assets/chunk-5FUZZQ4R-6x8SlhH9.js +62 -0
  14. package/dist/client/assets/chunk-5PVQY5BW-R5SE6dhE.js +2 -0
  15. package/dist/client/assets/chunk-67CJDMHE-CjXw5hFa.js +1 -0
  16. package/dist/client/assets/chunk-7N4EOEYR-DNHyuswJ.js +1 -0
  17. package/dist/client/assets/chunk-AA7GKIK3-DayE4IF_.js +1 -0
  18. package/dist/client/assets/chunk-BSJP7CBP-CexlYBxB.js +1 -0
  19. package/dist/client/assets/chunk-CIAEETIT-CkDJ4DYI.js +1 -0
  20. package/dist/client/assets/{chunk-KX2RTZJC-BTiOJb7N.js → chunk-EDXVE4YY-BVR_nF3y.js} +1 -1
  21. package/dist/client/assets/chunk-ENJZ2VHE-CFVWytAB.js +10 -0
  22. package/dist/client/assets/chunk-FOC6F5B3-DzCiCLGs.js +1 -0
  23. package/dist/client/assets/chunk-ICPOFSXX-B9LPHgU7.js +122 -0
  24. package/dist/client/assets/chunk-K5T4RW27-kmGSebVE.js +94 -0
  25. package/dist/client/assets/chunk-KGLVRYIC-DVjPRsaR.js +1 -0
  26. package/dist/client/assets/chunk-LIHQZDEY-DKFj13sC.js +1 -0
  27. package/dist/client/assets/chunk-NU2UP6EN-UVL-wkIc.js +35 -0
  28. package/dist/client/assets/chunk-ORNJ4GCN-D0uTAC-5.js +1 -0
  29. package/dist/client/assets/{chunk-NQ4KR5QH-CMJKI6Oj.js → chunk-OYMX7WX6-nWiNHNyD.js} +25 -14
  30. package/dist/client/assets/{chunk-PU5JKC2W-D_6N6t8f.js → chunk-U2HBQHQK-Bue4Ufzn.js} +6 -6
  31. package/dist/client/assets/{chunk-PQ6SQG4A-D1AbThjy.js → chunk-X2U36JSP-CRE6lp7n.js} +1 -1
  32. package/dist/client/assets/{chunk-XPW4576I-DJr4_4Yy.js → chunk-XPW4576I-BL5M-tF8.js} +1 -1
  33. package/dist/client/assets/{chunk-JSJVCQXG-DPQ9cPJt.js → chunk-YZCP3GAM-D7Z5wUWA.js} +1 -1
  34. package/dist/client/assets/chunk-ZZ45TVLE-CBbl1Qec.js +1 -0
  35. package/dist/client/assets/classDiagram-6PBFFD2Q-MIbgV5UL.js +1 -0
  36. package/dist/client/assets/classDiagram-v2-HSJHXN6E-Bb70vg2O.js +1 -0
  37. package/dist/client/assets/clike-BFTLRaGS.js +1 -0
  38. package/dist/client/assets/clone-D6JWrlxJ.js +1 -0
  39. package/dist/client/assets/{coffeescript-B_7eyHAa.js → coffeescript-B7GZajzV.js} +1 -1
  40. package/dist/client/assets/{cose-bilkent-S5V4N54A-DASO2hrk.js → cose-bilkent-S5V4N54A-xxgR5OJ-.js} +1 -1
  41. package/dist/client/assets/{cypher-DE6I2lIA.js → cypher-DEGl2llJ.js} +1 -1
  42. package/dist/client/assets/cytoscape.esm-B3PRdePO.js +321 -0
  43. package/dist/client/assets/{d-BNkKjn0o.js → d-BspB0dox.js} +1 -1
  44. package/dist/client/assets/dagre-KV5264BT-C2K9mFg1.js +4 -0
  45. package/dist/client/assets/dagre-VaFYRFbD.js +1 -0
  46. package/dist/client/assets/diagram-5BDNPKRD-DE0M0jaM.js +10 -0
  47. package/dist/client/assets/diagram-G4DWMVQ6-BfaRuSTT.js +24 -0
  48. package/dist/client/assets/diagram-MMDJMWI5-91Bly_hN.js +43 -0
  49. package/dist/client/assets/diagram-TYMM5635-fBkLwZGN.js +24 -0
  50. package/dist/client/assets/{dist-BzpfHRaE.js → dist-74GtnE06.js} +1 -1
  51. package/dist/client/assets/dist-B3lARV_e.js +1 -0
  52. package/dist/client/assets/{dist-O1z0Ayg0.js → dist-BCvzlTeb.js} +1 -1
  53. package/dist/client/assets/{dist-DsL7sqZR.js → dist-BMlUxhOz.js} +1 -1
  54. package/dist/client/assets/dist-BSED50tI.js +13 -0
  55. package/dist/client/assets/{dist-B-02vKOA.js → dist-Bkn7JaJv.js} +1 -1
  56. package/dist/client/assets/dist-Bq8Z0WUT.js +1 -0
  57. package/dist/client/assets/{dist-E_jPb93e.js → dist-Bzb9nPam.js} +1 -1
  58. package/dist/client/assets/{dist-CL-jjdvG.js → dist-C0e9kfNh.js} +1 -1
  59. package/dist/client/assets/dist-C8wdW7W4.js +1 -0
  60. package/dist/client/assets/dist-CDUQ5ELn.js +1 -0
  61. package/dist/client/assets/dist-CHSg_nUM.js +1 -0
  62. package/dist/client/assets/dist-CSAH9iuE.js +6 -0
  63. package/dist/client/assets/{dist-CxfohGIV.js → dist-CSNMpi-w.js} +1 -1
  64. package/dist/client/assets/dist-CZPTvk_g2.js +1 -0
  65. package/dist/client/assets/{dist-k47-Io7D.js → dist-Co8HE14w.js} +1 -1
  66. package/dist/client/assets/{dist-Bc2ND6i3.js → dist-CqU98NzX.js} +1 -1
  67. package/dist/client/assets/{dist-BzbYwa8m.js → dist-D0dQAc9b.js} +1 -1
  68. package/dist/client/assets/{dist-Dyt7n5Ui.js → dist-D1-dK0Dk.js} +1 -1
  69. package/dist/client/assets/{dist-B4uQVR_X.js → dist-DAKGEzm0.js} +1 -1
  70. package/dist/client/assets/dist-DBzteOlY.js +1 -0
  71. package/dist/client/assets/{dist-CjII8VDS.js → dist-DSRCADL9.js} +1 -1
  72. package/dist/client/assets/{dist-lDhnP-K1.js → dist-DdR2aYqj.js} +1 -1
  73. package/dist/client/assets/{dist-DUvaQ-Bj.js → dist-DidT3Jay.js} +1 -1
  74. package/dist/client/assets/dist-Doo91MTa.js +1 -0
  75. package/dist/client/assets/{dist-BLAlZer_.js → dist-Dwy75xI6.js} +1 -1
  76. package/dist/client/assets/{dist-3uAMa5w5.js → dist-FC9LftvP.js} +1 -1
  77. package/dist/client/assets/{dist-CGV1S_as.js → dist-PPAeaw4t.js} +1 -1
  78. package/dist/client/assets/{dist-BtnXjRx0.js → dist-VPEWg0Ob.js} +1 -1
  79. package/dist/client/assets/{dist-CXpKYW9s.js → dist-cQSK4Xor.js} +1 -1
  80. package/dist/client/assets/{dist-rMhng5DK.js → dist-r5I9Jgww.js} +1 -1
  81. package/dist/client/assets/drawio-editor-CWLEpwps.js +9 -0
  82. package/dist/client/assets/{drawioEditor-D6clB5OH.js → drawioEditor-5rJhxjA4.js} +2 -2
  83. package/dist/client/assets/{ecl-M7Iek4lq.js → ecl-D9rhJ9-u.js} +1 -1
  84. package/dist/client/assets/{editor-session-Dzy_85Wp.js → editor-session-CLOuvy37.js} +3 -3
  85. package/dist/client/assets/{erDiagram-INFDFZHY-DlIf-fb7.js → erDiagram-SMLLAGMA-DUQcqEQ1.js} +33 -18
  86. package/dist/client/assets/excalidraw-editor-ukEKPqGJ.js +9 -0
  87. package/dist/client/assets/{excalidraw-mermaid-stub-Bwe-bKcT.js → excalidraw-mermaid-stub-Df0Q2qkW.js} +1 -1
  88. package/dist/client/assets/excalidraw-scene-CDK3oDnm.js +176 -0
  89. package/dist/client/assets/excalidrawEditor-BJ8QLmWc.js +2 -0
  90. package/dist/client/assets/{export-page-PeexH2QK.js → export-page-D2rCmrUH.js} +2 -2
  91. package/dist/client/assets/exportDocument-Dunnjgii.js +2 -0
  92. package/dist/client/assets/{fcl-BWKK0S4-.js → fcl-CUXJFJn1.js} +1 -1
  93. package/dist/client/assets/flatten-CX_XvnUf.js +1 -0
  94. package/dist/client/assets/flowDiagram-DWJPFMVM-B_A5JyId.js +162 -0
  95. package/dist/client/assets/ganttDiagram-T4ZO3ILL-HM3CD7bk.js +292 -0
  96. package/dist/client/assets/gitGraph-7Q5UKJZL-BrBlB49D.js +1 -0
  97. package/dist/client/assets/gitGraphDiagram-UUTBAWPF-Dw7twZDm.js +106 -0
  98. package/dist/client/assets/graphlib-DDD4Vdye.js +1 -0
  99. package/dist/client/assets/{groovy-BEKazBrO.js → groovy-Di--Vb9Z.js} +1 -1
  100. package/dist/client/assets/{haxe-BY9d_5nB.js → haxe-CcPA1xnA.js} +1 -1
  101. package/dist/client/assets/image-XLNPCCAD-BFNybKza.js +1 -0
  102. package/dist/client/assets/{image-blob-reduce.esm-DriR2zT9.js → image-blob-reduce.esm-DiuPkovC.js} +1 -1
  103. package/dist/client/assets/{index-Czg_KL-i.js → index-BbziNMqE.js} +2 -2
  104. package/dist/client/assets/info-OMHHGYJF-BcmgcSx1.js +1 -0
  105. package/dist/client/assets/{infoDiagram-LFFYTUFH-DFTI0nfs.js → infoDiagram-42DDH7IO-DX-d3DMp.js} +1 -1
  106. package/dist/client/assets/isEmpty-BKDbo1FH.js +1 -0
  107. package/dist/client/assets/ishikawaDiagram-UXIWVN3A-BHmsxpMs.js +70 -0
  108. package/dist/client/assets/{javascript-CdiVhQeA.js → javascript-gTK9fxz6.js} +1 -1
  109. package/dist/client/assets/javascript-qUBHINSy.js +1 -0
  110. package/dist/client/assets/{journeyDiagram-4ABVD52K-DDur6iHm.js → journeyDiagram-VCZTEJTY-jxDSjgE1.js} +2 -2
  111. package/dist/client/assets/{jsx-runtime-C2p7wRmT.js → jsx-runtime-B_8UNt-W.js} +1 -1
  112. package/dist/client/assets/{kanban-definition-K7BYSVSG-dA6NPLsg.js → kanban-definition-6JOO6SKY-od3qY1mE.js} +2 -2
  113. package/dist/client/assets/line-CZsGUM4H.js +1 -0
  114. package/dist/client/assets/{lua-kutgyRGY.js → lua-Cg0FqIlO.js} +1 -1
  115. package/dist/client/assets/main-CN0kbtGk.js +1369 -0
  116. package/dist/client/assets/mermaid-parser.core-DtIbxv6L.js +4 -0
  117. package/dist/client/assets/mermaid-runtime-vVJfjscE.js +11 -0
  118. package/dist/client/assets/{mindmap-definition-YRQLILUH-DjQcsPoe.js → mindmap-definition-QFDTVHPH-C9qrdAqo.js} +39 -11
  119. package/dist/client/assets/packet-4T2RLAQJ-DYYSvRuJ.js +1 -0
  120. package/dist/client/assets/pica-BEurQXMu.js +2 -0
  121. package/dist/client/assets/pie-ZZUOXDRM-cG65Mc64.js +1 -0
  122. package/dist/client/assets/pieDiagram-DEJITSTG-BHXxj7wl.js +30 -0
  123. package/dist/client/assets/{preview-render-compiler-BjLlHmiQ.js → preview-render-compiler-BHeDhYho.js} +2 -2
  124. package/dist/client/assets/preview-render-compiler-D3QM1Ryz.js +1 -0
  125. package/dist/client/assets/{preview-render-profile-CR4dJZrp.js → preview-render-profile-BF6os3x9.js} +5 -5
  126. package/dist/client/assets/{preview-render-worker-B4dH2yxj.js → preview-render-worker-C4AFtMIr.js} +6 -6
  127. package/dist/client/assets/{pug-DkUcLYWt.js → pug-lkTEco3G.js} +1 -1
  128. package/dist/client/assets/{python-CZtTmYkS.js → python-BUyhM0Ew.js} +1 -1
  129. package/dist/client/assets/{q-I27iQntV.js → q-Dls1OX0D.js} +1 -1
  130. package/dist/client/assets/{quadrantDiagram-337W2JSQ-CYKgdx7K.js → quadrantDiagram-34T5L4WZ-CWW7LORF.js} +1 -1
  131. package/dist/client/assets/{quick-switcher-controller-DcyllYpm.js → quick-switcher-controller-B1erSgJ1.js} +1 -1
  132. package/dist/client/assets/{r-DN_EydfL.js → r-DeZ8Mdev.js} +1 -1
  133. package/dist/client/assets/radar-PYXPWWZC-Bmpup_xw.js +1 -0
  134. package/dist/client/assets/reduce-C6FuFJbE.js +1 -0
  135. package/dist/client/assets/requirementDiagram-MS252O5E-CTljNdQH.js +84 -0
  136. package/dist/client/assets/{room-yJaBAoEU.js → room-DI7DXGeS.js} +1 -1
  137. package/dist/client/assets/{sankeyDiagram-WA2Y5GQK-CfHe3D6R.js → sankeyDiagram-XADWPNL6-CCfFkC74.js} +1 -1
  138. package/dist/client/assets/sequenceDiagram-FGHM5R23-BD9vj6WG.js +157 -0
  139. package/dist/client/assets/{sparql-BOvq0dv7.js → sparql-vm8qNO8J.js} +1 -1
  140. package/dist/client/assets/sql-GL7dVWcd.js +1 -0
  141. package/dist/client/assets/stateDiagram-FHFEXIEX-CpiX3KPd.js +1 -0
  142. package/dist/client/assets/stateDiagram-v2-QKLJ7IA2-D_5ufPqT.js +1 -0
  143. package/dist/client/assets/{swift-BCxe4-cw.js → swift-CKcKnWv9.js} +1 -1
  144. package/dist/client/assets/timeline-definition-GMOUNBTQ-BafRAkSF.js +120 -0
  145. package/dist/client/assets/treeView-SZITEDCU-NbjhK5cw.js +1 -0
  146. package/dist/client/assets/treemap-W4RFUUIX-DJzRbb-x.js +1 -0
  147. package/dist/client/assets/{turtle-GBz_E4RG.js → turtle-BkP3ExOG.js} +1 -1
  148. package/dist/client/assets/{vault-api-client-p7h7cXKM.js → vault-api-client-DSx3mWkH.js} +1 -1
  149. package/dist/client/assets/{vault-utils-5Xr0MXCb.js → vault-utils-CRpy8MQz.js} +1 -1
  150. package/dist/client/assets/vennDiagram-DHZGUBPP-DSngq_Zj.js +34 -0
  151. package/dist/client/assets/{verilog-C4wTycyo.js → verilog-DSARZZPc.js} +1 -1
  152. package/dist/client/assets/{vhdl-Bwndeg44.js → vhdl-CnYyYTpa.js} +1 -1
  153. package/dist/client/assets/wardley-RL74JXVD-DTNoH_BY.js +1 -0
  154. package/dist/client/assets/wardleyDiagram-NUSXRM2D-CAEd2kJG.js +20 -0
  155. package/dist/client/assets/{xychartDiagram-JWTSCODW-C3vA70iJ.js → xychartDiagram-5P7HB3ND-BScQpnru.js} +6 -6
  156. package/dist/client/assets/{yjs-provider-reset-guard-CtERLBID.js → yjs-provider-reset-guard-_Q3mj6tP.js} +1 -1
  157. package/dist/client/drawio-editor.html +1 -1
  158. package/dist/client/excalidraw-editor.html +1 -1
  159. package/dist/client/export-document.html +1 -1
  160. package/dist/client/index.html +1 -1
  161. package/package.json +12 -11
  162. package/src/client/application/app-shell/git-feature.js +44 -36
  163. package/src/client/application/app-shell/ui-feature-shell.js +87 -63
  164. package/src/client/application/quick-switcher-loader.js +39 -0
  165. package/src/client/bootstrap/collabmd-app-shell.js +16 -20
  166. package/src/client/domain/keyboard-shortcuts.js +8 -0
  167. package/src/client/drawio-editor.js +13 -0
  168. package/src/client/excalidraw-editor.js +13 -0
  169. package/src/client/infrastructure/excalidraw-room-client.js +1 -1
  170. package/src/client/infrastructure/workspace-sync-client.js +26 -3
  171. package/src/client/presentation/comment-ui/comment-ui-card.js +83 -3
  172. package/src/client/presentation/comment-ui/comment-ui-state.js +25 -2
  173. package/src/client/presentation/drawio-embed-controller.js +18 -0
  174. package/src/client/presentation/excalidraw-embed-controller.js +11 -1
  175. package/src/client/presentation/file-history-view-controller.js +9 -1
  176. package/src/client/presentation/git-panel-controller.js +103 -91
  177. package/src/server/domain/backlink-index.js +74 -94
  178. package/src/server/domain/bases/base-index-snapshot-store.js +46 -62
  179. package/src/server/domain/markdown-reference-extractor.js +233 -0
  180. package/src/server/infrastructure/http/create-request-handler.js +63 -28
  181. package/src/server/infrastructure/http/create-vault-api-command-handler.js +275 -256
  182. package/src/server/infrastructure/http/create-vault-api-query-handler.js +255 -233
  183. package/src/server/infrastructure/persistence/vault-file-store.js +107 -16
  184. package/src/server/infrastructure/workspace/file-system-sync-service.js +37 -11
  185. package/dist/client/assets/_basePickBy-Dv0sK1l7.js +0 -1
  186. package/dist/client/assets/_baseUniq-DKYX57ji.js +0 -1
  187. package/dist/client/assets/arc-DrfYGhWk.js +0 -1
  188. package/dist/client/assets/architecture-PBZL5I3N-DiglIZi9.js +0 -1
  189. package/dist/client/assets/blockDiagram-WCTKOSBZ-GIgTqnhk.js +0 -132
  190. package/dist/client/assets/c4Diagram-IC4MRINW-CkHO1i_L.js +0 -10
  191. package/dist/client/assets/channel-CgsU9TSN.js +0 -1
  192. package/dist/client/assets/chunk-7E7YKBS2-TdU92i9i.js +0 -1
  193. package/dist/client/assets/chunk-7R4GIKGN-mqd2GwMg.js +0 -80
  194. package/dist/client/assets/chunk-C72U2L5F-CJKQWBtz.js +0 -1
  195. package/dist/client/assets/chunk-EGIJ26TM-C4nq20om.js +0 -1
  196. package/dist/client/assets/chunk-GEFDOKGD-Bs7FmFox.js +0 -2
  197. package/dist/client/assets/chunk-GLR3WWYH-qQe2O5VQ.js +0 -2
  198. package/dist/client/assets/chunk-KYZI473N-CTSCuqRb.js +0 -53
  199. package/dist/client/assets/chunk-L3YUKLVL-CJZMBtKF.js +0 -1
  200. package/dist/client/assets/chunk-MX3YWQON-DQpSwRf6.js +0 -1
  201. package/dist/client/assets/chunk-NU2UP6EN-DlUENSHU.js +0 -35
  202. package/dist/client/assets/chunk-O4XLMI2P-CcVxZh41.js +0 -7
  203. package/dist/client/assets/chunk-OZEHJAEY-DjBZbgu0.js +0 -1
  204. package/dist/client/assets/chunk-R5LLSJPH-CkjKXM73.js +0 -1
  205. package/dist/client/assets/chunk-WL4C6EOR-axcuKSup.js +0 -189
  206. package/dist/client/assets/chunk-XIRO2GV7-4wqVHjs_.js +0 -1
  207. package/dist/client/assets/chunk-XZSTWKYB-C8Y_hIKZ.js +0 -94
  208. package/dist/client/assets/chunk-YBOYWFTD-CKg4ymFF.js +0 -1
  209. package/dist/client/assets/classDiagram-VBA2DB6C-BHZpvOxK.js +0 -1
  210. package/dist/client/assets/classDiagram-v2-RAHNMMFH-DA7HMUUs.js +0 -1
  211. package/dist/client/assets/clike-1_ZsiVV8.js +0 -1
  212. package/dist/client/assets/clone-Dgi8Z4IL.js +0 -1
  213. package/dist/client/assets/cytoscape.esm-Czjc507F.js +0 -321
  214. package/dist/client/assets/dagre-CfB3Fw33.js +0 -1
  215. package/dist/client/assets/dagre-KLK3FWXG-CC7tq2Ky.js +0 -4
  216. package/dist/client/assets/diagram-E7M64L7V-CMt7BN5M.js +0 -24
  217. package/dist/client/assets/diagram-IFDJBPK2-BFMBUGpd.js +0 -43
  218. package/dist/client/assets/diagram-P4PSJMXO-CviA1xXr.js +0 -24
  219. package/dist/client/assets/dist-3bQB_we3.js +0 -1
  220. package/dist/client/assets/dist-8Igu3Ee_2.js +0 -1
  221. package/dist/client/assets/dist-BU8uusJX.js +0 -1
  222. package/dist/client/assets/dist-BVB8rn7o.js +0 -1
  223. package/dist/client/assets/dist-D5QOYy7y.js +0 -6
  224. package/dist/client/assets/dist-DIi0uqLJ.js +0 -1
  225. package/dist/client/assets/dist-DJ16N7ol.js +0 -1
  226. package/dist/client/assets/dist-DWJL3_bF.js +0 -13
  227. package/dist/client/assets/dist-OQE68wIX.js +0 -1
  228. package/dist/client/assets/dist-x7PIEmJu.js +0 -1
  229. package/dist/client/assets/drawio-editor-BMTwP5mD.js +0 -9
  230. package/dist/client/assets/excalidraw-editor-CAP9F8CB.js +0 -9
  231. package/dist/client/assets/excalidraw-scene-BF_bT1OL.js +0 -176
  232. package/dist/client/assets/excalidrawEditor-DD4AvzYP.js +0 -2
  233. package/dist/client/assets/exportDocument-Zfwq1XVx.js +0 -2
  234. package/dist/client/assets/flowDiagram-PKNHOUZH-C_t-mkwb.js +0 -162
  235. package/dist/client/assets/ganttDiagram-A5KZAMGK-BtK9Tb--.js +0 -292
  236. package/dist/client/assets/gitGraph-HDMCJU4V-CT7YfbD3.js +0 -1
  237. package/dist/client/assets/gitGraphDiagram-K3NZZRJ6-DULDLGiJ.js +0 -65
  238. package/dist/client/assets/graphlib-BgRST-Qg.js +0 -1
  239. package/dist/client/assets/image-XLNPCCAD-CFiKwiWK.js +0 -1
  240. package/dist/client/assets/info-3K5VOQVL-DUpNyDC-.js +0 -1
  241. package/dist/client/assets/isArrayLikeObject-BId_dPHM.js +0 -1
  242. package/dist/client/assets/isEmpty-CVvRj8fj.js +0 -1
  243. package/dist/client/assets/ishikawaDiagram-PHBUUO56-DpBuDpC6.js +0 -70
  244. package/dist/client/assets/javascript-UJe68_xi.js +0 -1
  245. package/dist/client/assets/line-B2GMovaI.js +0 -1
  246. package/dist/client/assets/main-DeowJOSp.js +0 -1368
  247. package/dist/client/assets/math-B-LMBwub.js +0 -1
  248. package/dist/client/assets/mermaid-parser.core-B1ogGcR8.js +0 -4
  249. package/dist/client/assets/mermaid-runtime-Bn8A6DGx.js +0 -11
  250. package/dist/client/assets/packet-RMMSAZCW-DEwNbIrA.js +0 -1
  251. package/dist/client/assets/pica-C1TdTz-C.js +0 -2
  252. package/dist/client/assets/pie-UPGHQEXC-D5M_lSjo.js +0 -1
  253. package/dist/client/assets/pieDiagram-SKSYHLDU-jhHouFpk.js +0 -30
  254. package/dist/client/assets/preview-render-compiler-Duy_3IcP.js +0 -1
  255. package/dist/client/assets/radar-KQ55EAFF-AU1qh3Bw.js +0 -1
  256. package/dist/client/assets/requirementDiagram-Z7DCOOCP-D9SHxoW7.js +0 -73
  257. package/dist/client/assets/sequenceDiagram-2WXFIKYE-CZsMMqAJ.js +0 -145
  258. package/dist/client/assets/sql-DDFeQNTK.js +0 -1
  259. package/dist/client/assets/stateDiagram-RAJIS63D-CoNZjTYV.js +0 -1
  260. package/dist/client/assets/stateDiagram-v2-FVOUBMTO-1zOw6NmQ.js +0 -1
  261. package/dist/client/assets/timeline-definition-YZTLITO2-DSe2mrG8.js +0 -61
  262. package/dist/client/assets/treemap-KZPCXAKY-C9UI2fwP.js +0 -1
  263. package/dist/client/assets/vennDiagram-LZ73GAT5-xSzaIpy1.js +0 -34
  264. /package/dist/client/assets/{chunk-55IACEB6-CpncB3ru.js → chunk-55IACEB6-DLqevMSj.js} +0 -0
  265. /package/dist/client/assets/{chunk-QZHKN3VN-CgLPFSk5.js → chunk-QZHKN3VN-BnOS2iQW.js} +0 -0
  266. /package/dist/client/assets/{drawio-room-DEivFyNV.js → drawio-room-1i6Nn0_Z.js} +0 -0
  267. /package/dist/client/assets/{excalidraw-mermaid-stub-BZPU4ZhU.js → excalidraw-mermaid-stub-DzxtBcQW.js} +0 -0
  268. /package/dist/client/assets/{file-kind-DBptLlF_.js → file-kind-DmKq2MvD.js} +0 -0
  269. /package/dist/client/assets/{preview-diagram-utils-COt-IYMD.js → preview-diagram-utils-D8VypUft.js} +0 -0
  270. /package/dist/client/assets/{rough.esm-DE_lJ5Ge.js → rough.esm-BU2knLt9.js} +0 -0
  271. /package/dist/client/assets/{runtime-config-CqhchMC4.js → runtime-config-DWTejofP.js} +0 -0
@@ -117,263 +117,285 @@ async function streamDirectoryArchive(req, res, {
117
117
  await responsePromise;
118
118
  }
119
119
 
120
- export function createVaultApiQueryHandler({
121
- baseQueryService = null,
122
- backlinkIndex,
123
- vaultFileStore,
124
- workspaceMutationCoordinator = null,
125
- }) {
126
- return async function handleVaultApiQuery(req, res, requestUrl) {
127
- if (requestUrl.pathname === '/api/base/query' && req.method === 'POST') {
128
- try {
129
- if (!baseQueryService?.query) {
130
- jsonResponse(req, res, 503, { error: 'Bases query service is unavailable' });
131
- return true;
132
- }
133
-
134
- const body = await parseJsonBody(req);
135
- const result = await baseQueryService.query({
136
- activeFilePath: body?.activeFilePath ?? '',
137
- basePath: body?.path ?? '',
138
- search: body?.search ?? '',
139
- source: typeof body?.source === 'string' ? body.source : null,
140
- sourcePath: body?.sourcePath ?? '',
141
- view: body?.view ?? '',
142
- });
143
-
144
- jsonResponse(req, res, 200, { ok: true, result });
145
- } catch (error) {
146
- console.error('[api] Failed to query base:', error.message);
147
- jsonResponse(req, res, 400, { error: error.message || 'Failed to query base' });
148
- }
149
- return true;
150
- }
120
+ // --- Route handlers ---
151
121
 
152
- if (requestUrl.pathname === '/api/base/property-values' && req.method === 'POST') {
153
- try {
154
- if (!baseQueryService?.propertyValues) {
155
- jsonResponse(req, res, 503, { error: 'Bases query service is unavailable' });
156
- return true;
157
- }
158
-
159
- const body = await parseJsonBody(req);
160
- const result = await baseQueryService.propertyValues({
161
- activeFilePath: body?.activeFilePath ?? '',
162
- basePath: body?.path ?? '',
163
- propertyId: body?.propertyId ?? '',
164
- query: body?.query ?? '',
165
- source: typeof body?.source === 'string' ? body.source : null,
166
- sourcePath: body?.sourcePath ?? '',
167
- view: body?.view ?? '',
168
- });
169
-
170
- jsonResponse(req, res, 200, { ok: true, result });
171
- } catch (error) {
172
- console.error('[api] Failed to read base property values:', error.message);
173
- jsonResponse(req, res, 400, { error: error.message || 'Failed to read base property values' });
174
- }
175
- return true;
122
+ async function handleBaseQuery(req, res, _requestUrl, { baseQueryService }) {
123
+ try {
124
+ if (!baseQueryService?.query) {
125
+ jsonResponse(req, res, 503, { error: 'Bases query service is unavailable' });
126
+ return;
176
127
  }
177
128
 
178
- if (requestUrl.pathname === '/api/base/transform' && req.method === 'POST') {
179
- try {
180
- if (!baseQueryService?.transform) {
181
- jsonResponse(req, res, 503, { error: 'Bases query service is unavailable' });
182
- return true;
183
- }
184
-
185
- const body = await parseJsonBody(req);
186
- const result = await baseQueryService.transform({
187
- activeFilePath: body?.activeFilePath ?? '',
188
- basePath: body?.path ?? '',
189
- mutation: body?.mutation ?? null,
190
- source: typeof body?.source === 'string' ? body.source : null,
191
- sourcePath: body?.sourcePath ?? '',
192
- view: body?.view ?? '',
193
- });
194
-
195
- jsonResponse(req, res, 200, { ok: true, result });
196
- } catch (error) {
197
- console.error('[api] Failed to transform base:', error.message);
198
- jsonResponse(req, res, 400, { error: error.message || 'Failed to transform base' });
199
- }
200
- return true;
129
+ const body = await parseJsonBody(req);
130
+ const result = await baseQueryService.query({
131
+ activeFilePath: body?.activeFilePath ?? '',
132
+ basePath: body?.path ?? '',
133
+ search: body?.search ?? '',
134
+ source: typeof body?.source === 'string' ? body.source : null,
135
+ sourcePath: body?.sourcePath ?? '',
136
+ view: body?.view ?? '',
137
+ });
138
+
139
+ jsonResponse(req, res, 200, { ok: true, result });
140
+ } catch (error) {
141
+ console.error('[api] Failed to query base:', error.message);
142
+ jsonResponse(req, res, 400, { error: error.message || 'Failed to query base' });
143
+ }
144
+ }
145
+
146
+ async function handleBasePropertyValues(req, res, _requestUrl, { baseQueryService }) {
147
+ try {
148
+ if (!baseQueryService?.propertyValues) {
149
+ jsonResponse(req, res, 503, { error: 'Bases query service is unavailable' });
150
+ return;
201
151
  }
202
152
 
203
- if (requestUrl.pathname === '/api/base/export' && req.method === 'POST') {
204
- try {
205
- if (!baseQueryService?.query) {
206
- jsonResponse(req, res, 503, { error: 'Bases query service is unavailable' });
207
- return true;
208
- }
209
-
210
- const body = await parseJsonBody(req);
211
- const result = await baseQueryService.query({
212
- activeFilePath: body?.activeFilePath ?? '',
213
- basePath: body?.path ?? '',
214
- includeCsv: true,
215
- search: body?.search ?? '',
216
- source: typeof body?.source === 'string' ? body.source : null,
217
- sourcePath: body?.sourcePath ?? '',
218
- view: body?.view ?? '',
219
- });
220
- const fileName = basename(String(body?.path || body?.sourcePath || 'base')).replace(/\.[^.]+$/u, '') || 'base';
221
- sendResponse(req, res, {
222
- body: result.csv,
223
- headers: {
224
- 'Cache-Control': 'no-store',
225
- 'Content-Disposition': `attachment; filename="${createSafeAsciiFilename(`${fileName}.csv`)}"; filename*=UTF-8''${encodeContentDispositionFilename(`${fileName}.csv`)}`,
226
- 'Content-Type': 'text/csv; charset=utf-8',
227
- 'X-Content-Type-Options': 'nosniff',
228
- },
229
- statusCode: 200,
230
- });
231
- } catch (error) {
232
- console.error('[api] Failed to export base CSV:', error.message);
233
- jsonResponse(req, res, 400, { error: error.message || 'Failed to export base CSV' });
234
- }
235
- return true;
153
+ const body = await parseJsonBody(req);
154
+ const result = await baseQueryService.propertyValues({
155
+ activeFilePath: body?.activeFilePath ?? '',
156
+ basePath: body?.path ?? '',
157
+ propertyId: body?.propertyId ?? '',
158
+ query: body?.query ?? '',
159
+ source: typeof body?.source === 'string' ? body.source : null,
160
+ sourcePath: body?.sourcePath ?? '',
161
+ view: body?.view ?? '',
162
+ });
163
+
164
+ jsonResponse(req, res, 200, { ok: true, result });
165
+ } catch (error) {
166
+ console.error('[api] Failed to read base property values:', error.message);
167
+ jsonResponse(req, res, 400, { error: error.message || 'Failed to read base property values' });
168
+ }
169
+ }
170
+
171
+ async function handleBaseTransform(req, res, _requestUrl, { baseQueryService }) {
172
+ try {
173
+ if (!baseQueryService?.transform) {
174
+ jsonResponse(req, res, 503, { error: 'Bases query service is unavailable' });
175
+ return;
236
176
  }
237
177
 
238
- if (requestUrl.pathname === '/api/files' && req.method === 'GET') {
239
- try {
240
- const tree = workspaceMutationCoordinator?.getWorkspaceTree?.() ?? await vaultFileStore.tree();
241
- jsonResponse(req, res, 200, { tree });
242
- } catch (error) {
243
- console.error('[api] Failed to read file tree:', error.message);
244
- jsonResponse(req, res, 500, { error: 'Failed to read file tree' });
245
- }
246
- return true;
178
+ const body = await parseJsonBody(req);
179
+ const result = await baseQueryService.transform({
180
+ activeFilePath: body?.activeFilePath ?? '',
181
+ basePath: body?.path ?? '',
182
+ mutation: body?.mutation ?? null,
183
+ source: typeof body?.source === 'string' ? body.source : null,
184
+ sourcePath: body?.sourcePath ?? '',
185
+ view: body?.view ?? '',
186
+ });
187
+
188
+ jsonResponse(req, res, 200, { ok: true, result });
189
+ } catch (error) {
190
+ console.error('[api] Failed to transform base:', error.message);
191
+ jsonResponse(req, res, 400, { error: error.message || 'Failed to transform base' });
192
+ }
193
+ }
194
+
195
+ async function handleBaseExport(req, res, _requestUrl, { baseQueryService }) {
196
+ try {
197
+ if (!baseQueryService?.query) {
198
+ jsonResponse(req, res, 503, { error: 'Bases query service is unavailable' });
199
+ return;
247
200
  }
248
201
 
249
- if (requestUrl.pathname === '/api/file' && req.method === 'GET') {
250
- const filePath = requestUrl.searchParams.get('path');
251
- if (!filePath) {
252
- jsonResponse(req, res, 400, { error: 'Missing path parameter' });
253
- return true;
254
- }
202
+ const body = await parseJsonBody(req);
203
+ const result = await baseQueryService.query({
204
+ activeFilePath: body?.activeFilePath ?? '',
205
+ basePath: body?.path ?? '',
206
+ includeCsv: true,
207
+ search: body?.search ?? '',
208
+ source: typeof body?.source === 'string' ? body.source : null,
209
+ sourcePath: body?.sourcePath ?? '',
210
+ view: body?.view ?? '',
211
+ });
212
+ const fileName = basename(String(body?.path || body?.sourcePath || 'base')).replace(/\.[^.]+$/u, '') || 'base';
213
+ sendResponse(req, res, {
214
+ body: result.csv,
215
+ headers: {
216
+ 'Cache-Control': 'no-store',
217
+ 'Content-Disposition': `attachment; filename="${createSafeAsciiFilename(`${fileName}.csv`)}"; filename*=UTF-8''${encodeContentDispositionFilename(`${fileName}.csv`)}`,
218
+ 'Content-Type': 'text/csv; charset=utf-8',
219
+ 'X-Content-Type-Options': 'nosniff',
220
+ },
221
+ statusCode: 200,
222
+ });
223
+ } catch (error) {
224
+ console.error('[api] Failed to export base CSV:', error.message);
225
+ jsonResponse(req, res, 400, { error: error.message || 'Failed to export base CSV' });
226
+ }
227
+ }
255
228
 
256
- try {
257
- const content = await selectReadOperation(vaultFileStore, filePath);
258
- if (content === null) {
259
- jsonResponse(req, res, 404, { error: 'File not found' });
260
- return true;
261
- }
262
-
263
- jsonResponse(req, res, 200, { path: filePath, content });
264
- } catch (error) {
265
- console.error('[api] Failed to read file:', error.message);
266
- jsonResponse(req, res, 500, { error: 'Failed to read file' });
267
- }
268
- return true;
229
+ async function handleFileTree(req, res, _requestUrl, { vaultFileStore, workspaceMutationCoordinator }) {
230
+ try {
231
+ const tree = workspaceMutationCoordinator?.getWorkspaceTree?.() ?? await vaultFileStore.tree();
232
+ jsonResponse(req, res, 200, { tree });
233
+ } catch (error) {
234
+ console.error('[api] Failed to read file tree:', error.message);
235
+ jsonResponse(req, res, 500, { error: 'Failed to read file tree' });
236
+ }
237
+ }
238
+
239
+ async function handleFileRead(req, res, requestUrl, { vaultFileStore }) {
240
+ const filePath = requestUrl.searchParams.get('path');
241
+ if (!filePath) {
242
+ jsonResponse(req, res, 400, { error: 'Missing path parameter' });
243
+ return;
244
+ }
245
+
246
+ try {
247
+ const content = await selectReadOperation(vaultFileStore, filePath);
248
+ if (content === null) {
249
+ jsonResponse(req, res, 404, { error: 'File not found' });
250
+ return;
269
251
  }
270
252
 
271
- if (requestUrl.pathname === '/api/download/file' && req.method === 'GET') {
272
- const filePath = requestUrl.searchParams.get('path');
273
- if (!filePath) {
274
- jsonResponse(req, res, 400, { error: 'Missing path parameter' });
275
- return true;
276
- }
253
+ jsonResponse(req, res, 200, { path: filePath, content });
254
+ } catch (error) {
255
+ console.error('[api] Failed to read file:', error.message);
256
+ jsonResponse(req, res, 500, { error: 'Failed to read file' });
257
+ }
258
+ }
277
259
 
278
- try {
279
- const download = await vaultFileStore.readDownloadFile(filePath);
280
- if (!download) {
281
- jsonResponse(req, res, 404, { error: 'File not found' });
282
- return true;
283
- }
284
-
285
- sendResponse(req, res, {
286
- body: download.content,
287
- headers: createDownloadHeaders(
288
- basename(String(download.path ?? 'download')),
289
- download.mimeType || 'application/octet-stream',
290
- ),
291
- statusCode: 200,
292
- });
293
- } catch (error) {
294
- console.error('[api] Failed to download file:', error.message);
295
- jsonResponse(req, res, 500, { error: 'Failed to download file' });
296
- }
297
- return true;
260
+ async function handleFileDownload(req, res, requestUrl, { vaultFileStore }) {
261
+ const filePath = requestUrl.searchParams.get('path');
262
+ if (!filePath) {
263
+ jsonResponse(req, res, 400, { error: 'Missing path parameter' });
264
+ return;
265
+ }
266
+
267
+ try {
268
+ const download = await vaultFileStore.readDownloadFile(filePath);
269
+ if (!download) {
270
+ jsonResponse(req, res, 404, { error: 'File not found' });
271
+ return;
298
272
  }
299
273
 
300
- if (requestUrl.pathname === '/api/download/directory' && req.method === 'GET') {
301
- const directoryPath = requestUrl.searchParams.get('path');
302
- if (!directoryPath) {
303
- jsonResponse(req, res, 400, { error: 'Missing path parameter' });
304
- return true;
305
- }
274
+ sendResponse(req, res, {
275
+ body: download.content,
276
+ headers: createDownloadHeaders(
277
+ basename(String(download.path ?? 'download')),
278
+ download.mimeType || 'application/octet-stream',
279
+ ),
280
+ statusCode: 200,
281
+ });
282
+ } catch (error) {
283
+ console.error('[api] Failed to download file:', error.message);
284
+ jsonResponse(req, res, 500, { error: 'Failed to download file' });
285
+ }
286
+ }
306
287
 
307
- try {
308
- const result = await vaultFileStore.listDirectoryEntriesForDownload(directoryPath);
309
- if (!result.ok) {
310
- jsonResponse(req, res, result.error === 'Directory not found' ? 404 : 400, { error: result.error });
311
- return true;
312
- }
313
-
314
- await streamDirectoryArchive(req, res, {
315
- entries: result.entries,
316
- rootName: result.rootName || 'archive',
317
- });
318
- } catch (error) {
319
- console.error('[api] Failed to download directory:', error.message);
320
- if (!res.headersSent) {
321
- jsonResponse(req, res, 500, { error: 'Failed to download directory' });
322
- } else {
323
- res.destroy(error);
324
- }
325
- }
326
- return true;
288
+ async function handleDirectoryDownload(req, res, requestUrl, { vaultFileStore }) {
289
+ const directoryPath = requestUrl.searchParams.get('path');
290
+ if (!directoryPath) {
291
+ jsonResponse(req, res, 400, { error: 'Missing path parameter' });
292
+ return;
293
+ }
294
+
295
+ try {
296
+ const result = await vaultFileStore.listDirectoryEntriesForDownload(directoryPath);
297
+ if (!result.ok) {
298
+ jsonResponse(req, res, result.error === 'Directory not found' ? 404 : 400, { error: result.error });
299
+ return;
327
300
  }
328
301
 
329
- if (requestUrl.pathname === '/api/attachment' && req.method === 'GET') {
330
- const filePath = requestUrl.searchParams.get('path');
331
- if (!filePath) {
332
- jsonResponse(req, res, 400, { error: 'Missing path parameter' });
333
- return true;
334
- }
302
+ await streamDirectoryArchive(req, res, {
303
+ entries: result.entries,
304
+ rootName: result.rootName || 'archive',
305
+ });
306
+ } catch (error) {
307
+ console.error('[api] Failed to download directory:', error.message);
308
+ if (!res.headersSent) {
309
+ jsonResponse(req, res, 500, { error: 'Failed to download directory' });
310
+ } else {
311
+ res.destroy(error);
312
+ }
313
+ }
314
+ }
335
315
 
336
- if (!isImageAttachmentFilePath(filePath)) {
337
- jsonResponse(req, res, 400, { error: 'Unsupported attachment path' });
338
- return true;
339
- }
316
+ async function handleAttachmentRead(req, res, requestUrl, { vaultFileStore }) {
317
+ const filePath = requestUrl.searchParams.get('path');
318
+ if (!filePath) {
319
+ jsonResponse(req, res, 400, { error: 'Missing path parameter' });
320
+ return;
321
+ }
340
322
 
341
- try {
342
- const attachment = await vaultFileStore.readImageAttachmentFile(filePath);
343
- if (!attachment) {
344
- jsonResponse(req, res, 404, { error: 'Attachment not found' });
345
- return true;
346
- }
347
-
348
- sendResponse(req, res, {
349
- body: attachment.content,
350
- headers: createAttachmentHeaders(attachment),
351
- statusCode: 200,
352
- });
353
- } catch (error) {
354
- console.error('[api] Failed to read attachment:', error.message);
355
- jsonResponse(req, res, 500, { error: 'Failed to read attachment' });
356
- }
357
- return true;
323
+ if (!isImageAttachmentFilePath(filePath)) {
324
+ jsonResponse(req, res, 400, { error: 'Unsupported attachment path' });
325
+ return;
326
+ }
327
+
328
+ try {
329
+ const attachment = await vaultFileStore.readImageAttachmentFile(filePath);
330
+ if (!attachment) {
331
+ jsonResponse(req, res, 404, { error: 'Attachment not found' });
332
+ return;
358
333
  }
359
334
 
360
- if (requestUrl.pathname === '/api/backlinks' && req.method === 'GET') {
361
- const filePath = requestUrl.searchParams.get('file');
362
- if (!filePath) {
363
- jsonResponse(req, res, 400, { error: 'Missing file parameter' });
364
- return true;
365
- }
335
+ sendResponse(req, res, {
336
+ body: attachment.content,
337
+ headers: createAttachmentHeaders(attachment),
338
+ statusCode: 200,
339
+ });
340
+ } catch (error) {
341
+ console.error('[api] Failed to read attachment:', error.message);
342
+ jsonResponse(req, res, 500, { error: 'Failed to read attachment' });
343
+ }
344
+ }
345
+
346
+ async function handleBacklinks(req, res, requestUrl, { backlinkIndex }) {
347
+ const filePath = requestUrl.searchParams.get('file');
348
+ if (!filePath) {
349
+ jsonResponse(req, res, 400, { error: 'Missing file parameter' });
350
+ return;
351
+ }
352
+
353
+ try {
354
+ jsonResponse(req, res, 200, {
355
+ backlinks: backlinkIndex ? await backlinkIndex.getBacklinks(filePath) : [],
356
+ file: filePath,
357
+ });
358
+ } catch (error) {
359
+ console.error('[api] Failed to get backlinks:', error.message);
360
+ jsonResponse(req, res, 500, { error: 'Failed to get backlinks' });
361
+ }
362
+ }
366
363
 
367
- try {
368
- jsonResponse(req, res, 200, {
369
- backlinks: backlinkIndex ? await backlinkIndex.getBacklinks(filePath) : [],
370
- file: filePath,
371
- });
372
- } catch (error) {
373
- console.error('[api] Failed to get backlinks:', error.message);
374
- jsonResponse(req, res, 500, { error: 'Failed to get backlinks' });
364
+ // --- Route table ---
365
+
366
+ function createRouteTable(context) {
367
+ return [
368
+ { method: 'POST', path: '/api/base/query', handler: handleBaseQuery },
369
+ { method: 'POST', path: '/api/base/property-values', handler: handleBasePropertyValues },
370
+ { method: 'POST', path: '/api/base/transform', handler: handleBaseTransform },
371
+ { method: 'POST', path: '/api/base/export', handler: handleBaseExport },
372
+ { method: 'GET', path: '/api/files', handler: handleFileTree },
373
+ { method: 'GET', path: '/api/file', handler: handleFileRead },
374
+ { method: 'GET', path: '/api/download/file', handler: handleFileDownload },
375
+ { method: 'GET', path: '/api/download/directory', handler: handleDirectoryDownload },
376
+ { method: 'GET', path: '/api/attachment', handler: handleAttachmentRead },
377
+ { method: 'GET', path: '/api/backlinks', handler: handleBacklinks },
378
+ ].map((route) => ({
379
+ ...route,
380
+ handler: (req, res, requestUrl) => route.handler(req, res, requestUrl, context),
381
+ }));
382
+ }
383
+
384
+ export function createVaultApiQueryHandler({
385
+ baseQueryService = null,
386
+ backlinkIndex,
387
+ vaultFileStore,
388
+ workspaceMutationCoordinator = null,
389
+ }) {
390
+ const context = { baseQueryService, backlinkIndex, vaultFileStore, workspaceMutationCoordinator };
391
+ const routes = createRouteTable(context);
392
+
393
+ return async function handleVaultApiQuery(req, res, requestUrl) {
394
+ for (const route of routes) {
395
+ if (req.method === route.method && requestUrl.pathname === route.path) {
396
+ await route.handler(req, res, requestUrl);
397
+ return true;
375
398
  }
376
- return true;
377
399
  }
378
400
 
379
401
  return false;