docs-i18n 0.11.0 → 0.12.0

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 (205) hide show
  1. package/admin/app/worker.ts +43 -0
  2. package/admin/dist/server/assets/{__tanstack-start-server-fn-resolver-qK0Yfvti.js → __tanstack-start-server-fn-resolver-D1Ni2lpa.js} +17 -17
  3. package/admin/dist/server/assets/{dist-DBv71kqn.js → dist-BnKtYOU0.js} +8319 -99
  4. package/admin/dist/server/assets/{init-CJJUsPDL.js → init-SZW7wW3l.js} +1 -1
  5. package/admin/dist/server/assets/{jobs-DrEe9YOj.js → jobs-DVAdIxgN.js} +2 -2
  6. package/admin/dist/server/assets/{misc-BSoYldBT.js → misc-D0n9L-9D.js} +3 -3
  7. package/admin/dist/server/assets/{router-D-82slI-.js → router-noqexgr0.js} +2 -2
  8. package/admin/dist/server/assets/{routes-C9huiZHw.js → routes-BG89QZ0_.js} +1 -1
  9. package/admin/dist/server/assets/{routes-B1pNmxF3.js → routes-CLdSUfb7.js} +2 -2
  10. package/admin/dist/server/assets/{status-B1AGLvHn.js → status-BYF_y9fT.js} +1 -1
  11. package/admin/dist/server/assets/{status-D7PU72hm.js → status-C-jmHj1T.js} +2 -2
  12. package/admin/dist/server/server.js +6 -5
  13. package/dist/chunk-BHYFOPS6.js +111 -0
  14. package/dist/cli.js +44 -5
  15. package/dist/index.d.ts +108 -1
  16. package/dist/index.js +224 -1
  17. package/dist/pipeline-3XGFR4QL.js +104 -0
  18. package/dist/{rescan-HXMWFAOC.js → rescan-7XDHUNH5.js} +33 -2
  19. package/dist/runner-KUGSO4CL.js +10 -0
  20. package/package.json +2 -1
  21. package/template/dist/client/assets/{Doc-BKO69_nz.js → Doc-CbmLeLjl.js} +1 -1
  22. package/template/dist/client/assets/{DocsLayout-BGugXxEQ.js → DocsLayout-ERG7nrAc.js} +1 -1
  23. package/template/dist/client/assets/{FileTabs-4fZriOj4.js → FileTabs-CCynw0nL.js} +1 -1
  24. package/template/dist/client/assets/{Footer-DYh1AfWA.js → Footer-l6Y8-ltB.js} +1 -1
  25. package/template/dist/client/assets/{FrameworkContent-rVvjxASn.js → FrameworkContent-pNf68F7f.js} +1 -1
  26. package/template/dist/client/assets/{MarkdownHeadingContext-CdvUDZFU.js → MarkdownHeadingContext-6I862CKH.js} +4 -4
  27. package/template/dist/client/assets/{PostNotFound-WoSYGsGu.js → PostNotFound-ScC0039d.js} +1 -1
  28. package/template/dist/client/assets/{_basePickBy-Dd7GuR7A.js → _basePickBy-B-GcvGxW.js} +1 -1
  29. package/template/dist/client/assets/{_baseUniq-DMxQLGFI.js → _baseUniq-C1WySGZQ.js} +1 -1
  30. package/template/dist/client/assets/_lang-B3tRf7os.js +1 -0
  31. package/template/dist/client/assets/_lang._project-CH0inpmY.js +1 -0
  32. package/template/dist/client/assets/_lang._project._version-CESvrqds.js +1 -0
  33. package/template/dist/client/assets/{_lang._project._version.docs-DokNGgvU.js → _lang._project._version.docs-aw08dKvN.js} +1 -1
  34. package/template/dist/client/assets/{_lang._project._version.docs._-CXCNZzOb.js → _lang._project._version.docs._-B4Vb_S0V.js} +1 -1
  35. package/template/dist/client/assets/_lang._project._version.docs._-BexMyJr9.js +1 -0
  36. package/template/dist/client/assets/_lang._project._version.docs.framework._framework._-BbQgUWTH.js +1 -0
  37. package/template/dist/client/assets/{_lang._project._version.docs.framework._framework.index-DsYjXRdj.js → _lang._project._version.docs.framework._framework.index-DInYPTXM.js} +1 -1
  38. package/template/dist/client/assets/{_lang._project._version.docs.framework.index-DQX1lBi3.js → _lang._project._version.docs.framework.index-B7EvJmBI.js} +1 -1
  39. package/template/dist/client/assets/{_lang._project.docs-DsYQj9jI.js → _lang._project.docs-4oX3ADgu.js} +1 -1
  40. package/template/dist/client/assets/_lang._project.docs._-R9bOn492.js +1 -0
  41. package/template/dist/client/assets/{_lang._project.docs._-l2tTjx80.js → _lang._project.docs._-emq0IsQw.js} +1 -1
  42. package/template/dist/client/assets/_lang.blog-BViCs72M.js +1 -0
  43. package/template/dist/client/assets/_lang.blog-DhVkwYEk.js +1 -0
  44. package/template/dist/client/assets/_lang.blog._-BHdaHDBU.js +1 -0
  45. package/template/dist/client/assets/{_lang.blog._-Umz18sQE.js → _lang.blog._-DErizs7q.js} +1 -1
  46. package/template/dist/client/assets/_lang.blog.index-CELEUrkj.js +1 -0
  47. package/template/dist/client/assets/{_lang.blog.index-DzUqpOBE.js → _lang.blog.index-DZDuDkQr.js} +1 -1
  48. package/template/dist/client/assets/{_lang.docs-CUh3R7DD.js → _lang.docs-CQK0rfqt.js} +1 -1
  49. package/template/dist/client/assets/{_lang.docs._-DlgTPy3s.js → _lang.docs._-BiCvgeV1.js} +1 -1
  50. package/template/dist/client/assets/_lang.docs._-axvS_dfl.js +1 -0
  51. package/template/dist/client/assets/_lang.docs.framework._framework._-D2FAQ0gW.js +1 -0
  52. package/template/dist/client/assets/{_lang.docs.framework._framework.index-DTg6Xd3p.js → _lang.docs.framework._framework.index-Bu5p5Q_r.js} +1 -1
  53. package/template/dist/client/assets/{_lang.docs.framework.index-BQ2enasl.js → _lang.docs.framework.index-uTDFLagP.js} +1 -1
  54. package/template/dist/client/assets/{arc-DGPgC_QF.js → arc-C16C7aa3.js} +1 -1
  55. package/template/dist/client/assets/{architectureDiagram-2XIMDMQ5-yI53_GAi.js → architectureDiagram-2XIMDMQ5-DgSSDH9Z.js} +1 -1
  56. package/template/dist/client/assets/{blockDiagram-WCTKOSBZ-C3tr24zy.js → blockDiagram-WCTKOSBZ-Bs8e58Or.js} +1 -1
  57. package/template/dist/client/assets/{c4Diagram-IC4MRINW-DOA-mowm.js → c4Diagram-IC4MRINW-DsGaAPtm.js} +1 -1
  58. package/template/dist/client/assets/channel-Clrp6Lr4.js +1 -0
  59. package/template/dist/client/assets/{chunk-4BX2VUAB-B6NSnNJJ.js → chunk-4BX2VUAB-BQdq93Vq.js} +1 -1
  60. package/template/dist/client/assets/{chunk-55IACEB6-CWYwArBH.js → chunk-55IACEB6-zjp4uUiZ.js} +1 -1
  61. package/template/dist/client/assets/{chunk-FMBD7UC4-DSyn2wIW.js → chunk-FMBD7UC4-CEdYlBOF.js} +1 -1
  62. package/template/dist/client/assets/{chunk-JSJVCQXG-D83nm5W0.js → chunk-JSJVCQXG-CVkDw9ls.js} +1 -1
  63. package/template/dist/client/assets/{chunk-KX2RTZJC-DD7fN9e9.js → chunk-KX2RTZJC--1vKv-mr.js} +1 -1
  64. package/template/dist/client/assets/{chunk-NQ4KR5QH-C3YlYiU5.js → chunk-NQ4KR5QH-Cpo-W18l.js} +1 -1
  65. package/template/dist/client/assets/{chunk-QZHKN3VN-B7wBEuCG.js → chunk-QZHKN3VN-BizWJuB4.js} +1 -1
  66. package/template/dist/client/assets/{chunk-WL4C6EOR-ByA1FloT.js → chunk-WL4C6EOR-6lLYa9R1.js} +1 -1
  67. package/template/dist/client/assets/classDiagram-VBA2DB6C-Beq6_jEy.js +1 -0
  68. package/template/dist/client/assets/classDiagram-v2-RAHNMMFH-Beq6_jEy.js +1 -0
  69. package/template/dist/client/assets/clone-BbBu6MzK.js +1 -0
  70. package/template/dist/client/assets/{cose-bilkent-S5V4N54A-nt_sXfWc.js → cose-bilkent-S5V4N54A-CaD0EGPJ.js} +1 -1
  71. package/template/dist/client/assets/{dagre-KLK3FWXG-DUsyMTPd.js → dagre-KLK3FWXG-h4F9WtDQ.js} +1 -1
  72. package/template/dist/client/assets/{diagram-E7M64L7V-D5SAypX0.js → diagram-E7M64L7V-CBUSWzH5.js} +1 -1
  73. package/template/dist/client/assets/{diagram-IFDJBPK2-WhP5c8Vz.js → diagram-IFDJBPK2-C5oMubv0.js} +1 -1
  74. package/template/dist/client/assets/{diagram-P4PSJMXO-AMrwIlhf.js → diagram-P4PSJMXO-DdPwwhHR.js} +1 -1
  75. package/template/dist/client/assets/{erDiagram-INFDFZHY-BxifSpCV.js → erDiagram-INFDFZHY-0U5A-RF0.js} +1 -1
  76. package/template/dist/client/assets/{flowDiagram-PKNHOUZH-BMAowE9I.js → flowDiagram-PKNHOUZH-CXN3pvSW.js} +1 -1
  77. package/template/dist/client/assets/{ganttDiagram-A5KZAMGK-Bay-0iRq.js → ganttDiagram-A5KZAMGK-DlovlSO7.js} +1 -1
  78. package/template/dist/client/assets/{gitGraphDiagram-K3NZZRJ6-Va91W3gw.js → gitGraphDiagram-K3NZZRJ6-Bo-Jjy7v.js} +1 -1
  79. package/template/dist/client/assets/{graph-CbBYObK_.js → graph-C0TauvuO.js} +1 -1
  80. package/template/dist/client/assets/{index-CF6qz2tX.js → index-iATq4LEm.js} +1 -1
  81. package/template/dist/client/assets/{infoDiagram-LFFYTUFH-Byd5C-4U.js → infoDiagram-LFFYTUFH-BbvPzztn.js} +1 -1
  82. package/template/dist/client/assets/{ishikawaDiagram-PHBUUO56-DxOKnE1v.js → ishikawaDiagram-PHBUUO56-DKCMONMO.js} +1 -1
  83. package/template/dist/client/assets/{journeyDiagram-4ABVD52K-IRmt7RI4.js → journeyDiagram-4ABVD52K-D9NP_vvu.js} +1 -1
  84. package/template/dist/client/assets/{kanban-definition-K7BYSVSG-BjTVXn-R.js → kanban-definition-K7BYSVSG-X-u_nWxK.js} +1 -1
  85. package/template/dist/client/assets/{layout-Bbx6A0bC.js → layout-IeRzBrUX.js} +1 -1
  86. package/template/dist/client/assets/{linear-Df2eAW4A.js → linear-DEzVUeiK.js} +1 -1
  87. package/template/dist/client/assets/{main-DqZtiCro.js → main-Csj9i19C.js} +2 -2
  88. package/template/dist/client/assets/{mermaid.core-BIoiBcAA.js → mermaid.core-CCnh2DG0.js} +4 -4
  89. package/template/dist/client/assets/{mindmap-definition-YRQLILUH-Btzz0iIP.js → mindmap-definition-YRQLILUH-DgyN4Ft-.js} +1 -1
  90. package/template/dist/client/assets/ordinal-BENe2yWM.js +1 -0
  91. package/template/dist/client/assets/{pieDiagram-SKSYHLDU-C2amrGtU.js → pieDiagram-SKSYHLDU-DDVqU_2Q.js} +1 -1
  92. package/template/dist/client/assets/{quadrantDiagram-337W2JSQ-EVgH9VuN.js → quadrantDiagram-337W2JSQ-BeUxMqle.js} +1 -1
  93. package/template/dist/client/assets/{react-qvbbiZob.js → react-os8EX6z1.js} +1 -1
  94. package/template/dist/client/assets/{requirementDiagram-Z7DCOOCP-BkYPbRis.js → requirementDiagram-Z7DCOOCP-CpzdlyEd.js} +1 -1
  95. package/template/dist/client/assets/{sankeyDiagram-WA2Y5GQK-B5EIaP-h.js → sankeyDiagram-WA2Y5GQK-CmSWF6XU.js} +1 -1
  96. package/template/dist/client/assets/{sequenceDiagram-2WXFIKYE-BC33VGOc.js → sequenceDiagram-2WXFIKYE-DarofLka.js} +1 -1
  97. package/template/dist/client/assets/{stateDiagram-RAJIS63D-DiKvWUYb.js → stateDiagram-RAJIS63D-CEio2h-7.js} +1 -1
  98. package/template/dist/client/assets/stateDiagram-v2-FVOUBMTO-CbfK0_BD.js +1 -0
  99. package/template/dist/client/assets/{timeline-definition-YZTLITO2-QiFlgbRA.js → timeline-definition-YZTLITO2-By_Wk6uc.js} +1 -1
  100. package/template/dist/client/assets/{treemap-KZPCXAKY-BOYbyS9G.js → treemap-KZPCXAKY-mKcaMbv9.js} +1 -1
  101. package/template/dist/client/assets/{vennDiagram-LZ73GAT5-CqmW7j4r.js → vennDiagram-LZ73GAT5-Dx_Fh7nH.js} +1 -1
  102. package/template/dist/client/assets/{xychartDiagram-JWTSCODW-gj6oWX8l.js → xychartDiagram-JWTSCODW-DSAwWbBw.js} +1 -1
  103. package/template/dist/server/assets/{Doc-9tJiX5y6.js → Doc-B8TJBEmx.js} +3 -3
  104. package/template/dist/server/assets/{DocsLayout-BTjhU_W5.js → DocsLayout-CnWgvk8u.js} +2 -2
  105. package/template/dist/server/assets/{Footer-CefTi2yh.js → Footer-WapWK45U.js} +1 -1
  106. package/template/dist/server/assets/{FrameworkContent-BkJvuP04.js → FrameworkContent-gzqT-Q1n.js} +2 -2
  107. package/template/dist/server/assets/{MarkdownHeadingContext-37oQpb36.js → MarkdownHeadingContext-Iyk66Y4x.js} +3 -3
  108. package/template/dist/server/assets/{PostNotFound-BqBZf83v.js → PostNotFound-GKdNuzsX.js} +1 -1
  109. package/template/dist/server/assets/{_basePickBy-DZ3TPUta.js → _basePickBy-DJ9gzwF8.js} +2 -2
  110. package/template/dist/server/assets/{_baseUniq-DKicWTQT.js → _baseUniq-CezmbvU2.js} +1 -1
  111. package/template/dist/server/assets/{_lang._project._version.docs-U-t4mk5_.js → _lang._project._version.docs-BOZ34yW7.js} +3 -3
  112. package/template/dist/server/assets/{_lang._project._version.docs._-DMgnElWM.js → _lang._project._version.docs._-5W2jN7Re.js} +5 -5
  113. package/template/dist/server/assets/{_lang._project._version.docs.framework._framework._-kBw_9L-F.js → _lang._project._version.docs.framework._framework._-DeN_oA8l.js} +5 -5
  114. package/template/dist/server/assets/{_lang._project._version.docs.framework._framework.index-Bsyj0DD5.js → _lang._project._version.docs.framework._framework.index-jWKDCQSE.js} +1 -1
  115. package/template/dist/server/assets/{_lang._project._version.docs.framework.index-CmLAP_Io.js → _lang._project._version.docs.framework.index-DOT4MtjZ.js} +1 -1
  116. package/template/dist/server/assets/{_lang._project.docs-Bb4ZZ_jr.js → _lang._project.docs-r4V9TXuu.js} +3 -3
  117. package/template/dist/server/assets/{_lang._project.docs._-ChrpJ61j.js → _lang._project.docs._-Bge7JaYE.js} +5 -5
  118. package/template/dist/server/assets/{_lang.blog-8j6IvzvQ.js → _lang.blog-DJOfiyA8.js} +2 -2
  119. package/template/dist/server/assets/{_lang.blog._-DNX8UglA.js → _lang.blog._-C7iqMj9O.js} +2 -2
  120. package/template/dist/server/assets/{_lang.blog._-BPzP97Ac.js → _lang.blog._-yJSqbX08.js} +2 -2
  121. package/template/dist/server/assets/{_lang.blog.index-DzVKqoC4.js → _lang.blog.index-CrdyROhK.js} +2 -2
  122. package/template/dist/server/assets/{_lang.blog.index-CeZnMJBi.js → _lang.blog.index-Df_6_IKx.js} +1 -1
  123. package/template/dist/server/assets/{_lang.docs-B4StnHMb.js → _lang.docs-Jwt4deTW.js} +3 -3
  124. package/template/dist/server/assets/{_lang.docs._--c0In1AT.js → _lang.docs._-D_DdKLAV.js} +5 -5
  125. package/template/dist/server/assets/{_lang.docs.framework._framework._-Be0U7cDg.js → _lang.docs.framework._framework._-BkQaZ_1f.js} +5 -5
  126. package/template/dist/server/assets/{_lang.docs.framework._framework.index-BZ512aSk.js → _lang.docs.framework._framework.index-BLx8p8IS.js} +1 -1
  127. package/template/dist/server/assets/{_lang.docs.framework.index-U8z3j4kz.js → _lang.docs.framework.index-BytQ_q8T.js} +1 -1
  128. package/template/dist/server/assets/{_tanstack-start-manifest_v-DXpQ8503.js → _tanstack-start-manifest_v-RX6ItZ5S.js} +1 -1
  129. package/template/dist/server/assets/{arc-B4h6h_n6.js → arc-BwftnT5H.js} +1 -1
  130. package/template/dist/server/assets/{architecture-PBZL5I3N-CUwqLXkR.js → architecture-PBZL5I3N-KbDVC6gM.js} +6 -6
  131. package/template/dist/server/assets/{architectureDiagram-2XIMDMQ5-CuCoxdBe.js → architectureDiagram-2XIMDMQ5-BoLvWxb3.js} +6 -6
  132. package/template/dist/server/assets/{blockDiagram-WCTKOSBZ-D5PsUOim.js → blockDiagram-WCTKOSBZ-GPFcXs-f.js} +6 -6
  133. package/template/dist/server/assets/{c4Diagram-IC4MRINW-CXy5xO3o.js → c4Diagram-IC4MRINW-EQwQCspo.js} +2 -2
  134. package/template/dist/server/assets/{channel-D0l-mWaF.js → channel-CxvwuPH7.js} +1 -1
  135. package/template/dist/server/assets/{chunk-4BX2VUAB-M7FVHMss.js → chunk-4BX2VUAB-DUgcw5ei.js} +1 -1
  136. package/template/dist/server/assets/{chunk-55IACEB6-D_gDAje5.js → chunk-55IACEB6-Cn15uD91.js} +1 -1
  137. package/template/dist/server/assets/{chunk-FMBD7UC4-B5Bebx-Y.js → chunk-FMBD7UC4-Ck3iyLPu.js} +1 -1
  138. package/template/dist/server/assets/{chunk-JSJVCQXG-DxBkq-uB.js → chunk-JSJVCQXG-VAT8yncE.js} +1 -1
  139. package/template/dist/server/assets/{chunk-KX2RTZJC-BMHm1EGi.js → chunk-KX2RTZJC-B1bd2VmA.js} +1 -1
  140. package/template/dist/server/assets/{chunk-NQ4KR5QH-Cp28pTwT.js → chunk-NQ4KR5QH-CR67GG9C.js} +3 -3
  141. package/template/dist/server/assets/{chunk-QZHKN3VN-Bq5GZqaR.js → chunk-QZHKN3VN-B9SSazM4.js} +1 -1
  142. package/template/dist/server/assets/{chunk-WL4C6EOR-C9Nj5GdW.js → chunk-WL4C6EOR-DZ4Pjuao.js} +5 -5
  143. package/template/dist/server/assets/{classDiagram-VBA2DB6C-CUchv9T5.js → classDiagram-VBA2DB6C-CA6_4Wb2.js} +6 -6
  144. package/template/dist/server/assets/{classDiagram-v2-RAHNMMFH-CUchv9T5.js → classDiagram-v2-RAHNMMFH-CA6_4Wb2.js} +6 -6
  145. package/template/dist/server/assets/{clone-CJcTi58S.js → clone-DJHP_iVy.js} +1 -1
  146. package/template/dist/server/assets/{cose-bilkent-S5V4N54A-CxvCMhN_.js → cose-bilkent-S5V4N54A-DtU-cN6W.js} +1 -1
  147. package/template/dist/server/assets/{dagre-KLK3FWXG-B5bQP7FL.js → dagre-KLK3FWXG-yZYrVU4p.js} +6 -6
  148. package/template/dist/server/assets/{diagram-E7M64L7V-NjHca90S.js → diagram-E7M64L7V-8Yyz0aw0.js} +8 -8
  149. package/template/dist/server/assets/{diagram-IFDJBPK2-CoTCfBKd.js → diagram-IFDJBPK2-DcxFYI3M.js} +6 -6
  150. package/template/dist/server/assets/{diagram-P4PSJMXO-DHvGgYjH.js → diagram-P4PSJMXO-CehxUcI0.js} +6 -6
  151. package/template/dist/server/assets/{erDiagram-INFDFZHY-01crajKr.js → erDiagram-INFDFZHY-Bu2p1_Pj.js} +4 -4
  152. package/template/dist/server/assets/{flowDiagram-PKNHOUZH-BkUQ_vxg.js → flowDiagram-PKNHOUZH-B_eKR7I0.js} +6 -6
  153. package/template/dist/server/assets/{ganttDiagram-A5KZAMGK-DvrO-w2P.js → ganttDiagram-A5KZAMGK-DP6YEZof.js} +2 -2
  154. package/template/dist/server/assets/{gitGraph-HDMCJU4V-h9JNaxB7.js → gitGraph-HDMCJU4V-Bt0qhVL4.js} +6 -6
  155. package/template/dist/server/assets/{gitGraphDiagram-K3NZZRJ6-BoKm6Fm-.js → gitGraphDiagram-K3NZZRJ6-DwvkdYrg.js} +7 -7
  156. package/template/dist/server/assets/{graph-BoxbfI7Z.js → graph-BVFNe_k5.js} +2 -2
  157. package/template/dist/server/assets/{index-Jfzi6SZW.js → index-DvBGSZeA.js} +2 -2
  158. package/template/dist/server/assets/{info-3K5VOQVL-DgaSHqkS.js → info-3K5VOQVL-CFejRnvB.js} +6 -6
  159. package/template/dist/server/assets/{infoDiagram-LFFYTUFH-DgV5W8-I.js → infoDiagram-LFFYTUFH-D0v9uyXI.js} +5 -5
  160. package/template/dist/server/assets/{ishikawaDiagram-PHBUUO56-CqlMQ0Fq.js → ishikawaDiagram-PHBUUO56-DZumspL4.js} +1 -1
  161. package/template/dist/server/assets/{journeyDiagram-4ABVD52K-D6ySTub8.js → journeyDiagram-4ABVD52K-nRp_-qZp.js} +4 -4
  162. package/template/dist/server/assets/{kanban-definition-K7BYSVSG-BT8m7Cwk.js → kanban-definition-K7BYSVSG-BMKyyzjt.js} +2 -2
  163. package/template/dist/server/assets/{layout-CkYcErfn.js → layout-mpiN5R-5.js} +4 -4
  164. package/template/dist/server/assets/{linear-F_0dWGZL.js → linear-CqNYgjEx.js} +1 -1
  165. package/template/dist/server/assets/{mermaid-parser.core-q5MdUJuo.js → mermaid-parser.core-B8Uu3QZY.js} +11 -11
  166. package/template/dist/server/assets/{mermaid.core-DOWTODR1.js → mermaid.core-BI3nMhNO.js} +31 -31
  167. package/template/dist/server/assets/{mindmap-definition-YRQLILUH-BQxlQqn-.js → mindmap-definition-YRQLILUH-DCoFqLPh.js} +3 -3
  168. package/template/dist/server/assets/{ordinal-CxptdPJm.js → ordinal-Bcam90FY.js} +1 -1
  169. package/template/dist/server/assets/{packet-RMMSAZCW-D8FkLZuP.js → packet-RMMSAZCW-djgonfKN.js} +6 -6
  170. package/template/dist/server/assets/{pie-UPGHQEXC-Diw2fHLk.js → pie-UPGHQEXC-Dug2t-PE.js} +6 -6
  171. package/template/dist/server/assets/{pieDiagram-SKSYHLDU-B1J4UJZ7.js → pieDiagram-SKSYHLDU-CS0_hW4w.js} +8 -8
  172. package/template/dist/server/assets/{quadrantDiagram-337W2JSQ-BvjKLapg.js → quadrantDiagram-337W2JSQ-BpQNM0zu.js} +2 -2
  173. package/template/dist/server/assets/{radar-KQ55EAFF-CcBdPU3n.js → radar-KQ55EAFF-3ir2W9Wi.js} +6 -6
  174. package/template/dist/server/assets/{requirementDiagram-Z7DCOOCP-Bgr_wnAs.js → requirementDiagram-Z7DCOOCP-D92RyjV4.js} +3 -3
  175. package/template/dist/server/assets/{router-DxwPl-Dc.js → router-DPPgDicW.js} +18 -18
  176. package/template/dist/server/assets/{sankeyDiagram-WA2Y5GQK-B0UwtyW3.js → sankeyDiagram-WA2Y5GQK-DCPRB-xO.js} +2 -2
  177. package/template/dist/server/assets/{sequenceDiagram-2WXFIKYE-BbxQJHjO.js → sequenceDiagram-2WXFIKYE-C1ab2VvU.js} +3 -3
  178. package/template/dist/server/assets/{stateDiagram-RAJIS63D-Cg-uJ_UO.js → stateDiagram-RAJIS63D-GhG1G3ff.js} +8 -8
  179. package/template/dist/server/assets/{stateDiagram-v2-FVOUBMTO-BWVPrqfa.js → stateDiagram-v2-FVOUBMTO-C-KtMadV.js} +4 -4
  180. package/template/dist/server/assets/{timeline-definition-YZTLITO2-DCSJT2WT.js → timeline-definition-YZTLITO2-DyfAQCd4.js} +2 -2
  181. package/template/dist/server/assets/{treemap-KZPCXAKY-a0nhlKgx.js → treemap-KZPCXAKY-Cn0Cw4Cl.js} +6 -6
  182. package/template/dist/server/assets/{vennDiagram-LZ73GAT5-Bk2HQEQq.js → vennDiagram-LZ73GAT5-D2Ak5JUa.js} +1 -1
  183. package/template/dist/server/assets/{xychartDiagram-JWTSCODW-C4svHkt_.js → xychartDiagram-JWTSCODW-DqoBOs1L.js} +3 -3
  184. package/template/dist/server/server.js +14 -13
  185. package/template/dist/client/assets/_lang-3AqGszEy.js +0 -1
  186. package/template/dist/client/assets/_lang._project-COkrIqzH.js +0 -1
  187. package/template/dist/client/assets/_lang._project._version-B8vRZczu.js +0 -1
  188. package/template/dist/client/assets/_lang._project._version.docs._-DR0WSQEb.js +0 -1
  189. package/template/dist/client/assets/_lang._project._version.docs.framework._framework._-C_Grro8r.js +0 -1
  190. package/template/dist/client/assets/_lang._project.docs._-DlM_D6DD.js +0 -1
  191. package/template/dist/client/assets/_lang.blog-CEwEtalL.js +0 -1
  192. package/template/dist/client/assets/_lang.blog-D6YGC3tK.js +0 -1
  193. package/template/dist/client/assets/_lang.blog._-DgHu4oLy.js +0 -1
  194. package/template/dist/client/assets/_lang.blog.index-C8LKUFtD.js +0 -1
  195. package/template/dist/client/assets/_lang.docs._-DmaQE7lx.js +0 -1
  196. package/template/dist/client/assets/_lang.docs.framework._framework._-B4C4uDFp.js +0 -1
  197. package/template/dist/client/assets/channel-DzZD7dUQ.js +0 -1
  198. package/template/dist/client/assets/classDiagram-VBA2DB6C-CRozKaUD.js +0 -1
  199. package/template/dist/client/assets/classDiagram-v2-RAHNMMFH-CRozKaUD.js +0 -1
  200. package/template/dist/client/assets/clone-CGnOEl4E.js +0 -1
  201. package/template/dist/client/assets/ordinal-Cboi1Yqb.js +0 -1
  202. package/template/dist/client/assets/stateDiagram-v2-FVOUBMTO-DjKMPYGe.js +0 -1
  203. package/dist/{assemble-CP2BRYQJ.js → assemble-S3MWVLBI.js} +1 -1
  204. package/dist/{status-AGZDXOTZ.js → status-NX47XZIU.js} +1 -1
  205. package/dist/{translate-A5X6MX4Y.js → translate-AGUNMZMQ.js} +1 -1
package/dist/index.js CHANGED
@@ -617,18 +617,241 @@ function getPackageVersion() {
617
617
  }
618
618
  return "unknown";
619
619
  }
620
+
621
+ // src/plugins/runner.ts
622
+ import { existsSync, readFileSync as readFileSync2, readdirSync, writeFileSync } from "fs";
623
+ import { join, resolve as resolve2 } from "path";
624
+ import matter from "gray-matter";
625
+ function walkFiles(dir, extensions) {
626
+ const results = [];
627
+ if (!existsSync(dir)) return results;
628
+ for (const entry of readdirSync(dir, { withFileTypes: true })) {
629
+ const fullPath = join(dir, entry.name);
630
+ if (entry.isDirectory()) {
631
+ results.push(...walkFiles(fullPath, extensions));
632
+ } else if (extensions.some((ext) => entry.name.endsWith(ext))) {
633
+ results.push(fullPath);
634
+ }
635
+ }
636
+ return results;
637
+ }
638
+ function runBeforeScan(plugins, config, opts) {
639
+ const beforeScanPlugins = plugins.filter((p) => p.beforeScan);
640
+ if (beforeScanPlugins.length === 0) return 0;
641
+ const sources = flattenSources(config);
642
+ const extensions = (config.include ?? ["**/*.mdx", "**/*.md"]).map(
643
+ (p) => p.replace("**/*", "")
644
+ );
645
+ let modifiedCount = 0;
646
+ for (const source of sources) {
647
+ if (opts?.project && source.project !== opts.project) continue;
648
+ if (opts?.version && source.version !== opts.version) continue;
649
+ const enDir = resolve2(source.sourcePath);
650
+ if (!existsSync(enDir)) {
651
+ console.log(` [SKIP] ${source.versionKey}: source dir not found`);
652
+ continue;
653
+ }
654
+ const files = walkFiles(enDir, extensions);
655
+ for (const filePath of files) {
656
+ const content = readFileSync2(filePath, "utf-8");
657
+ let parsed;
658
+ try {
659
+ parsed = matter(content);
660
+ } catch {
661
+ continue;
662
+ }
663
+ const readFile = (refPath) => {
664
+ const fromDir = filePath.substring(0, filePath.lastIndexOf("/"));
665
+ const candidates = [
666
+ resolve2(fromDir, refPath),
667
+ resolve2(enDir, refPath),
668
+ resolve2(process.cwd(), refPath)
669
+ ];
670
+ for (const candidate of candidates) {
671
+ if (existsSync(candidate)) {
672
+ return readFileSync2(candidate, "utf-8");
673
+ }
674
+ }
675
+ return null;
676
+ };
677
+ let modified = content;
678
+ let wasModified = false;
679
+ for (const plugin of beforeScanPlugins) {
680
+ const result = plugin.beforeScan({
681
+ filePath,
682
+ content: modified,
683
+ frontmatter: parsed.data,
684
+ readFile,
685
+ project: source.project,
686
+ version: source.version
687
+ });
688
+ if (typeof result === "string") {
689
+ modified = result;
690
+ wasModified = true;
691
+ try {
692
+ parsed = matter(modified);
693
+ } catch {
694
+ }
695
+ }
696
+ }
697
+ if (wasModified) {
698
+ const relPath = filePath.slice(enDir.length + 1);
699
+ if (opts?.dryRun) {
700
+ console.log(` [DRY-RUN] ${source.versionKey}/${relPath}`);
701
+ } else {
702
+ writeFileSync(filePath, modified, "utf-8");
703
+ console.log(` [RESOLVED] ${source.versionKey}/${relPath}`);
704
+ }
705
+ modifiedCount++;
706
+ }
707
+ }
708
+ }
709
+ return modifiedCount;
710
+ }
711
+ function createShouldScanBody(plugins) {
712
+ const hooks = plugins.filter((p) => p.shouldScanBody);
713
+ if (hooks.length === 0) return void 0;
714
+ return (ctx) => {
715
+ for (const plugin of hooks) {
716
+ if (plugin.shouldScanBody(ctx) === false) {
717
+ return false;
718
+ }
719
+ }
720
+ return true;
721
+ };
722
+ }
723
+
724
+ // src/plugins/presets/tanstack-ref.ts
725
+ import matter2 from "gray-matter";
726
+ var MAX_REF_DEPTH = 4;
727
+ function replaceContent(text, originFrontmatter) {
728
+ let result = text;
729
+ const replace = originFrontmatter.data.replace;
730
+ if (replace) {
731
+ for (const [key, value] of Object.entries(replace)) {
732
+ result = result.replace(new RegExp(key, "g"), value);
733
+ }
734
+ }
735
+ return result;
736
+ }
737
+ function replaceSections(text, originFrontmatter) {
738
+ let result = text;
739
+ const sectionMarkerRegex = /\[\/\/\]: # '([a-zA-Z\d]*)'/g;
740
+ const sectionRegex = /\[\/\/\]: # '([a-zA-Z\d]*)'[\S\s]*?\[\/\/\]: # '([a-zA-Z\d]*)'/g;
741
+ const substitutes = /* @__PURE__ */ new Map();
742
+ for (const match of originFrontmatter.content.matchAll(sectionRegex)) {
743
+ if (match[1] !== match[2]) {
744
+ console.error(
745
+ `Origin section '${match[1]}' does not have matching closing token (found '${match[2]}'). Please make sure that each section has corresponding closing token and that sections are not nested.`
746
+ );
747
+ }
748
+ substitutes.set(match[1], match);
749
+ }
750
+ const sections = /* @__PURE__ */ new Map();
751
+ for (const match of result.matchAll(sectionRegex)) {
752
+ if (match[1] !== match[2]) {
753
+ console.error(
754
+ `Target section '${match[1]}' does not have matching closing token (found '${match[2]}'). Please make sure that each section has corresponding closing token and that sections are not nested.`
755
+ );
756
+ }
757
+ sections.set(match[1], match);
758
+ }
759
+ Array.from(substitutes.entries()).reverse().forEach(([key, value]) => {
760
+ const sectionMatch = sections.get(key);
761
+ if (sectionMatch) {
762
+ result = result.slice(0, sectionMatch.index) + value[0] + result.slice(sectionMatch.index + sectionMatch[0].length, result.length);
763
+ }
764
+ });
765
+ result = result.replaceAll(sectionMarkerRegex, "");
766
+ return result;
767
+ }
768
+ function normalizeRefPath(ref) {
769
+ if (ref.startsWith("docs/")) {
770
+ return ref.slice(5);
771
+ }
772
+ return ref;
773
+ }
774
+ function tryReadRef(refPath, readFile) {
775
+ let content = readFile(refPath);
776
+ if (content) return content;
777
+ const normalized = normalizeRefPath(refPath);
778
+ if (normalized !== refPath) {
779
+ content = readFile(normalized);
780
+ if (content) return content;
781
+ }
782
+ return null;
783
+ }
784
+ function tanstackRefPlugin() {
785
+ return {
786
+ name: "tanstack-ref",
787
+ beforeScan(ctx) {
788
+ const { filePath, content, frontmatter, readFile } = ctx;
789
+ if (!frontmatter.ref) {
790
+ return void 0;
791
+ }
792
+ const originParsed = matter2(content);
793
+ let refPath = frontmatter.ref;
794
+ let currentDepth = 1;
795
+ while (currentDepth <= MAX_REF_DEPTH) {
796
+ const refContent = tryReadRef(refPath, readFile);
797
+ if (!refContent) {
798
+ console.warn(` [tanstack-ref] ${filePath}: ref target not found: ${refPath}`);
799
+ return void 0;
800
+ }
801
+ const refParsed = matter2(refContent);
802
+ if (!refParsed.data.ref) {
803
+ return resolveWithContent(refContent, originParsed);
804
+ }
805
+ refPath = refParsed.data.ref;
806
+ currentDepth++;
807
+ }
808
+ console.warn(` [tanstack-ref] ${filePath}: ref chain exceeded max depth of ${MAX_REF_DEPTH}`);
809
+ return void 0;
810
+ }
811
+ };
812
+ }
813
+ function resolveWithContent(targetRaw, originParsed) {
814
+ let content = targetRaw;
815
+ content = replaceContent(content, originParsed);
816
+ content = replaceSections(content, originParsed);
817
+ const newData = { ...originParsed.data };
818
+ delete newData.ref;
819
+ delete newData.replace;
820
+ const targetParsed = matter2(content);
821
+ const mergedData = { ...targetParsed.data, ...newData };
822
+ delete mergedData.ref;
823
+ delete mergedData.replace;
824
+ return matter2.stringify(targetParsed.content, mergedData);
825
+ }
826
+
827
+ // src/plugins/presets/nextjs-source.ts
828
+ function nextjsSourcePlugin() {
829
+ return {
830
+ name: "nextjs-source",
831
+ shouldScanBody(ctx) {
832
+ if (ctx.frontmatter.source) {
833
+ return false;
834
+ }
835
+ return true;
836
+ }
837
+ };
838
+ }
620
839
  export {
621
840
  TranslationCache,
622
841
  assemble,
842
+ createShouldScanBody,
623
843
  defineConfig,
624
844
  extractHeadings,
625
845
  extractTranslatableFields,
626
846
  flattenSources,
627
847
  getPackageVersion,
628
848
  loadConfig,
849
+ nextjsSourcePlugin,
629
850
  normalize,
630
851
  parseMdx,
631
852
  processor,
632
853
  reconstructFrontmatter,
633
- renderMarkdown
854
+ renderMarkdown,
855
+ runBeforeScan,
856
+ tanstackRefPlugin
634
857
  };
@@ -0,0 +1,104 @@
1
+ import {
2
+ createShouldScanBody,
3
+ runBeforeScan
4
+ } from "./chunk-BHYFOPS6.js";
5
+ import "./chunk-TRURQFP4.js";
6
+ import "./chunk-PNKVD2UK.js";
7
+
8
+ // src/commands/pipeline.ts
9
+ import { execSync } from "child_process";
10
+ async function pipeline(config, opts) {
11
+ const plugins = config.plugins ?? [];
12
+ const syncScript = config.syncScript;
13
+ const d1 = config.d1;
14
+ const t0 = Date.now();
15
+ if (syncScript && !opts.skipSync) {
16
+ console.log("\n=== Step 1: Sync ===");
17
+ if (opts.dryRun) {
18
+ console.log(` [DRY-RUN] Would run: ${syncScript}`);
19
+ } else {
20
+ console.log(` Running: ${syncScript}`);
21
+ execSync(syncScript, { stdio: "inherit", shell: "/bin/bash" });
22
+ }
23
+ } else {
24
+ console.log("\n=== Step 1: Sync (skipped) ===");
25
+ }
26
+ console.log("\n=== Step 2: Resolve ===");
27
+ if (plugins.length > 0) {
28
+ const modified = runBeforeScan(plugins, config, {
29
+ project: opts.project,
30
+ version: opts.version,
31
+ dryRun: opts.dryRun
32
+ });
33
+ console.log(` ${modified} file(s) resolved`);
34
+ } else {
35
+ console.log(" No plugins configured, skipping");
36
+ }
37
+ console.log("\n=== Step 3: Rescan ===");
38
+ const { rescan } = await import("./rescan-7XDHUNH5.js");
39
+ const shouldScanBody = createShouldScanBody(plugins);
40
+ await rescan(config, {
41
+ project: opts.project,
42
+ version: opts.version,
43
+ shouldScanBody
44
+ });
45
+ if (!opts.skipTranslate) {
46
+ console.log("\n=== Step 4: Translate ===");
47
+ const { translate } = await import("./translate-AGUNMZMQ.js");
48
+ const langs = opts.lang ? [opts.lang] : config.languages;
49
+ for (const lang of langs) {
50
+ await translate(config, {
51
+ lang,
52
+ project: opts.project,
53
+ version: opts.version,
54
+ max: opts.max,
55
+ concurrency: opts.concurrency,
56
+ dryRun: opts.dryRun
57
+ });
58
+ }
59
+ } else {
60
+ console.log("\n=== Step 4: Translate (skipped) ===");
61
+ }
62
+ if (!opts.skipUpload && d1) {
63
+ console.log("\n=== Step 5: Upload ===");
64
+ if (opts.dryRun) {
65
+ console.log(" [DRY-RUN] Would upload to D1");
66
+ } else {
67
+ console.log(" Uploading to D1...");
68
+ const { collectContentFiles, generateContentSql, collectTranslations, generateTranslationSql } = await import("./upload-KYKJVERO.js");
69
+ const { writeFileSync } = await import("fs");
70
+ const { resolve } = await import("path");
71
+ const { tmpdir } = await import("os");
72
+ const projectRoot = process.cwd();
73
+ const contentRows = collectContentFiles(projectRoot);
74
+ const contentSql = generateContentSql(contentRows);
75
+ const translationData = collectTranslations(projectRoot);
76
+ const translationSql = generateTranslationSql(translationData);
77
+ const allSql = [...contentSql, ...translationSql];
78
+ const sqlFile = resolve(tmpdir(), "docs-i18n-pipeline-upload.sql");
79
+ writeFileSync(sqlFile, allSql.join("\n"));
80
+ const dbName = d1.database;
81
+ const wranglerArgs = ["d1", "execute", dbName, "--file", sqlFile, "--remote"];
82
+ console.log(` wrangler ${wranglerArgs.join(" ")}`);
83
+ const { spawnSync } = await import("child_process");
84
+ const result = spawnSync("npx", ["wrangler", ...wranglerArgs], {
85
+ stdio: "inherit",
86
+ shell: true
87
+ });
88
+ if (result.status !== 0) {
89
+ console.error(" Upload failed");
90
+ }
91
+ }
92
+ } else {
93
+ console.log("\n=== Step 5: Upload (skipped) ===");
94
+ }
95
+ console.log("\n=== Step 6: Status ===");
96
+ const { status } = await import("./status-NX47XZIU.js");
97
+ await status(config, { lang: opts.lang });
98
+ const elapsed = ((Date.now() - t0) / 1e3).toFixed(1);
99
+ console.log(`
100
+ Pipeline complete in ${elapsed}s`);
101
+ }
102
+ export {
103
+ pipeline
104
+ };
@@ -5,10 +5,10 @@ import {
5
5
  import {
6
6
  TranslationCache
7
7
  } from "./chunk-QKIR7RKQ.js";
8
+ import "./chunk-L64GJ4OB.js";
8
9
  import {
9
10
  flattenSources
10
11
  } from "./chunk-TRURQFP4.js";
11
- import "./chunk-L64GJ4OB.js";
12
12
  import "./chunk-PNKVD2UK.js";
13
13
 
14
14
  // src/commands/rescan.ts
@@ -28,6 +28,23 @@ function walkFiles(dir, patterns) {
28
28
  }
29
29
  return results;
30
30
  }
31
+ function parseFrontmatter(content) {
32
+ const match = content.match(/^---\n([\s\S]*?)\n---/);
33
+ if (!match) return {};
34
+ try {
35
+ const lines = match[1].split("\n");
36
+ const data = {};
37
+ for (const line of lines) {
38
+ const kv = line.match(/^(\w[\w.-]*)\s*:\s*(.+)/);
39
+ if (kv) {
40
+ data[kv[1]] = kv[2].trim().replace(/^['"]|['"]$/g, "");
41
+ }
42
+ }
43
+ return data;
44
+ } catch {
45
+ return {};
46
+ }
47
+ }
31
48
  async function rescan(config, opts) {
32
49
  const cacheDir = resolve(config.cacheDir ?? ".cache");
33
50
  const cache = new TranslationCache(cacheDir);
@@ -47,12 +64,22 @@ async function rescan(config, opts) {
47
64
  const files = walkFiles(enDir, extensions);
48
65
  cache.clearSources("", source.versionKey);
49
66
  let nodeCount = 0;
67
+ let skippedBodyCount = 0;
50
68
  for (const file of files) {
51
69
  const relPath = file.slice(enDir.length + 1);
52
70
  const content = readFileSync(file, "utf8");
53
71
  const nodes = parseMdx(content);
72
+ let scanBody = true;
73
+ if (opts.shouldScanBody) {
74
+ const frontmatter = parseFrontmatter(content);
75
+ scanBody = opts.shouldScanBody({ filePath: file, frontmatter });
76
+ if (!scanBody) skippedBodyCount++;
77
+ }
54
78
  for (const node of nodes) {
55
79
  if (node.needsTranslation && node.md5) {
80
+ if (!scanBody && node.type !== "frontmatter") {
81
+ continue;
82
+ }
56
83
  const line = content.substring(0, node.startOffset).split("\n").length;
57
84
  cache.setSource(node.md5, node.rawText, node.type);
58
85
  cache.updateSource("", node.md5, relPath, line, source.versionKey);
@@ -60,7 +87,11 @@ async function rescan(config, opts) {
60
87
  }
61
88
  }
62
89
  }
63
- console.log(`\u2705 ${source.versionKey}: ${files.length} files, ${nodeCount} nodes`);
90
+ let msg = `\u2705 ${source.versionKey}: ${files.length} files, ${nodeCount} nodes`;
91
+ if (skippedBodyCount > 0) {
92
+ msg += ` (${skippedBodyCount} body-skipped)`;
93
+ }
94
+ console.log(msg);
64
95
  }
65
96
  const orphanT = cache.db.prepare("DELETE FROM translations WHERE key NOT IN (SELECT DISTINCT key FROM source_files)").run();
66
97
  if (orphanT.changes > 0) console.log(`\u{1F5D1}\uFE0F Deleted ${orphanT.changes} orphan translations`);
@@ -0,0 +1,10 @@
1
+ import {
2
+ createShouldScanBody,
3
+ runBeforeScan
4
+ } from "./chunk-BHYFOPS6.js";
5
+ import "./chunk-TRURQFP4.js";
6
+ import "./chunk-PNKVD2UK.js";
7
+ export {
8
+ createShouldScanBody,
9
+ runBeforeScan
10
+ };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "docs-i18n",
3
- "version": "0.11.0",
3
+ "version": "0.12.0",
4
4
  "description": "Universal documentation translation engine — parse, translate, cache, assemble, manage.",
5
5
  "type": "module",
6
6
  "bin": {
@@ -30,6 +30,7 @@
30
30
  "dependencies": {
31
31
  "better-sqlite3": "^12.8.0",
32
32
  "glob": "^11.0.2",
33
+ "gray-matter": "^4.0.3",
33
34
  "hono": "^4.12.0",
34
35
  "jiti": "^2.4.0",
35
36
  "openai": "^5.1.1",
@@ -1 +1 @@
1
- import{z as C,o as E,j as e,r as l,s as W,t as A}from"./main-DqZtiCro.js";import{u as S,a as L,b as T}from"./DocsLayout-BGugXxEQ.js";import{B as O,r as U,F as $,M as V,a as _}from"./MarkdownHeadingContext-CdvUDZFU.js";const G=C("FoldHorizontal",[["path",{d:"M2 12h6",key:"1wqiqv"}],["path",{d:"M22 12h-6",key:"1eg9hc"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M12 8v2",key:"1woqiv"}],["path",{d:"M12 14v2",key:"8jcxud"}],["path",{d:"M12 20v2",key:"1lh1kg"}],["path",{d:"m19 9-3 3 3 3",key:"12ol22"}],["path",{d:"m5 15 3-3-3-3",key:"1kdhjc"}]]);const J=C("UnfoldHorizontal",[["path",{d:"M16 12h6",key:"15xry1"}],["path",{d:"M8 12H2",key:"1jqql6"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M12 8v2",key:"1woqiv"}],["path",{d:"M12 14v2",key:"8jcxud"}],["path",{d:"M12 20v2",key:"1lh1kg"}],["path",{d:"m19 15 3-3-3-3",key:"wjy7rq"}],["path",{d:"m5 9-3 3 3 3",key:"j64kie"}]]);function K(i,n){for(const t of i.sections){for(const r of t.children)if(r.to===n)return t.label;if(t.frameworks){for(const r of t.frameworks)for(const o of r.children)if(o.to===n)return t.label}}return null}function P({config:i,headings:n}){const{_splat:t,framework:r}=E({strict:!1}),o=r?`framework/${r}/${t}`:t,h=o?K(i,o):null;return h?e.jsx(O,{section:h,headings:n,tocHiddenBreakpoint:"lg"}):null}function ee({title:i,content:n,repo:t,branch:r,filePath:o,shouldRenderToc:h=!0,colorFrom:H,colorTo:N,textColor:q,config:w,footer:B,framework:g,isFallback:D=!1,locale:y}){const{headings:u,markup:R}=l.useMemo(()=>U(n),[n]),{framework:v}=E({strict:!1}),j=S(),M=l.useMemo(()=>{const s=g||v||j.currentFramework||"react";return typeof s=="string"?s.toLowerCase():s},[g,v,j.currentFramework]),f=h&&u.length>1,b=l.useRef(null),[z,I]=l.useState([]),m=l.useRef({});let c=!1,k;try{const s=L();c=s.isFullWidth,k=s.setIsFullWidth}catch{}return l.useEffect(()=>{const s=x=>{m.current=x.reduce((a,d)=>(a[d.target.id]=d,a),m.current);const p=[];Object.keys(m.current).forEach(a=>{const d=m.current[a];d.isIntersecting&&p.push(d)}),p.length>=1&&I(p.map(a=>a.target.id))},F=new IntersectionObserver(s,{rootMargin:"0px",threshold:.2});return Array.from(b.current?.querySelectorAll("h2[id], h3[id], h4[id], h5[id], h6[id]")??[]).forEach(x=>F.observe(x)),()=>F.disconnect()},[u]),e.jsxs("div",{className:"flex-1 min-h-0 flex flex-col pt-4 lg:pt-6 xl:pt-8",children:[D&&y&&e.jsx($,{locale:y}),e.jsxs("div",{className:A("w-full flex mx-auto max-w-[768px]",(f||c)&&"max-w-full"),children:[e.jsxs("div",{className:"flex flex-col w-full min-w-0",children:[w&&e.jsx("div",{className:"mb-3",children:e.jsx(P,{config:w,headings:f?u:void 0})}),e.jsx(V,{title:i,repo:t,branch:r,filePath:o,htmlMarkup:R,containerRef:b,currentFramework:M,customComponents:W.components,titleBarActions:k?e.jsx("button",{onClick:()=>k(!c),className:"p-2 mr-4 text-gray-600 hover:text-gray-800 dark:text-gray-400 dark:hover:text-gray-200 hover:bg-gray-100 dark:hover:bg-gray-700 rounded-lg transition-colors shrink-0 hidden [@media(min-width:1535px)]:inline-flex",title:c?"Constrain width":"Expand width",children:c?e.jsx(G,{className:"w-4 h-4"}):e.jsx(J,{className:"w-4 h-4"})}):null}),B??e.jsx(T,{})]}),f&&e.jsx("div",{className:"pl-4 w-32 lg:w-36 xl:w-44 2xl:w-56 3xl:w-64 shrink-0 hidden lg:block transition-all",children:e.jsx(_,{headings:u,activeHeadings:z,colorFrom:H,colorTo:N,textColor:q,currentFramework:M})})]})]})}export{ee as D};
1
+ import{z as C,o as E,j as e,r as l,s as W,t as A}from"./main-Csj9i19C.js";import{u as S,a as L,b as T}from"./DocsLayout-ERG7nrAc.js";import{B as O,r as U,F as $,M as V,a as _}from"./MarkdownHeadingContext-6I862CKH.js";const G=C("FoldHorizontal",[["path",{d:"M2 12h6",key:"1wqiqv"}],["path",{d:"M22 12h-6",key:"1eg9hc"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M12 8v2",key:"1woqiv"}],["path",{d:"M12 14v2",key:"8jcxud"}],["path",{d:"M12 20v2",key:"1lh1kg"}],["path",{d:"m19 9-3 3 3 3",key:"12ol22"}],["path",{d:"m5 15 3-3-3-3",key:"1kdhjc"}]]);const J=C("UnfoldHorizontal",[["path",{d:"M16 12h6",key:"15xry1"}],["path",{d:"M8 12H2",key:"1jqql6"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M12 8v2",key:"1woqiv"}],["path",{d:"M12 14v2",key:"8jcxud"}],["path",{d:"M12 20v2",key:"1lh1kg"}],["path",{d:"m19 15 3-3-3-3",key:"wjy7rq"}],["path",{d:"m5 9-3 3 3 3",key:"j64kie"}]]);function K(i,n){for(const t of i.sections){for(const r of t.children)if(r.to===n)return t.label;if(t.frameworks){for(const r of t.frameworks)for(const o of r.children)if(o.to===n)return t.label}}return null}function P({config:i,headings:n}){const{_splat:t,framework:r}=E({strict:!1}),o=r?`framework/${r}/${t}`:t,h=o?K(i,o):null;return h?e.jsx(O,{section:h,headings:n,tocHiddenBreakpoint:"lg"}):null}function ee({title:i,content:n,repo:t,branch:r,filePath:o,shouldRenderToc:h=!0,colorFrom:H,colorTo:N,textColor:q,config:w,footer:B,framework:g,isFallback:D=!1,locale:y}){const{headings:u,markup:R}=l.useMemo(()=>U(n),[n]),{framework:v}=E({strict:!1}),j=S(),M=l.useMemo(()=>{const s=g||v||j.currentFramework||"react";return typeof s=="string"?s.toLowerCase():s},[g,v,j.currentFramework]),f=h&&u.length>1,b=l.useRef(null),[z,I]=l.useState([]),m=l.useRef({});let c=!1,k;try{const s=L();c=s.isFullWidth,k=s.setIsFullWidth}catch{}return l.useEffect(()=>{const s=x=>{m.current=x.reduce((a,d)=>(a[d.target.id]=d,a),m.current);const p=[];Object.keys(m.current).forEach(a=>{const d=m.current[a];d.isIntersecting&&p.push(d)}),p.length>=1&&I(p.map(a=>a.target.id))},F=new IntersectionObserver(s,{rootMargin:"0px",threshold:.2});return Array.from(b.current?.querySelectorAll("h2[id], h3[id], h4[id], h5[id], h6[id]")??[]).forEach(x=>F.observe(x)),()=>F.disconnect()},[u]),e.jsxs("div",{className:"flex-1 min-h-0 flex flex-col pt-4 lg:pt-6 xl:pt-8",children:[D&&y&&e.jsx($,{locale:y}),e.jsxs("div",{className:A("w-full flex mx-auto max-w-[768px]",(f||c)&&"max-w-full"),children:[e.jsxs("div",{className:"flex flex-col w-full min-w-0",children:[w&&e.jsx("div",{className:"mb-3",children:e.jsx(P,{config:w,headings:f?u:void 0})}),e.jsx(V,{title:i,repo:t,branch:r,filePath:o,htmlMarkup:R,containerRef:b,currentFramework:M,customComponents:W.components,titleBarActions:k?e.jsx("button",{onClick:()=>k(!c),className:"p-2 mr-4 text-gray-600 hover:text-gray-800 dark:text-gray-400 dark:hover:text-gray-200 hover:bg-gray-100 dark:hover:bg-gray-700 rounded-lg transition-colors shrink-0 hidden [@media(min-width:1535px)]:inline-flex",title:c?"Constrain width":"Expand width",children:c?e.jsx(G,{className:"w-4 h-4"}):e.jsx(J,{className:"w-4 h-4"})}):null}),B??e.jsx(T,{})]}),f&&e.jsx("div",{className:"pl-4 w-32 lg:w-36 xl:w-44 2xl:w-56 3xl:w-64 shrink-0 hidden lg:block transition-all",children:e.jsx(_,{headings:u,activeHeadings:z,colorFrom:H,colorTo:N,textColor:q,currentFramework:M})})]})]})}export{ee as D};
@@ -1,4 +1,4 @@
1
- import{z as L,r as n,B as K,o as I,j as e,S as Q,D as fe,L as E,q as w,t as b,E as xe,F as H,G as ge,M as U,C as J}from"./main-DqZtiCro.js";import{F as he}from"./Footer-DYh1AfWA.js";import{c as X}from"./react-qvbbiZob.js";const pe=L("ChevronLeft",[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]]);const ve=L("ChevronRight",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]);const be=L("Tag",[["path",{d:"M12.586 2.586A2 2 0 0 0 11.172 2H4a2 2 0 0 0-2 2v7.172a2 2 0 0 0 .586 1.414l8.704 8.704a2.426 2.426 0 0 0 3.42 0l6.58-6.58a2.426 2.426 0 0 0 0-3.42z",key:"vktsd0"}],["circle",{cx:"7.5",cy:"7.5",r:".5",fill:"currentColor",key:"kqv944"}]]);function we(r){if(typeof window>"u")return;const t=localStorage.getItem(r);if(t)try{const l=JSON.parse(t);if(!l.ttl)return l.value;if(new Date().getTime()>l.ttl){localStorage.removeItem(r);return}return l.value}catch{localStorage.removeItem(r);return}}function ke(r,t,l){const[a,s]=n.useState(t);return n.useEffect(()=>{const d=we(r);d!==void 0&&s(d)},[r]),n.useEffect(()=>{localStorage.setItem(r,JSON.stringify({value:a,ttl:null}))},[r,a,l]),[a,s]}function je(r){return r[r.length-1]}const Y=[{label:"React",value:"react",logo:"/images/frameworks/react-logo.svg",color:"bg-blue-500",fontColor:"text-sky-500"},{label:"Preact",value:"preact",logo:"/images/frameworks/preact-logo.svg",color:"bg-purple-500",fontColor:"text-purple-500"},{label:"Vue",value:"vue",logo:"/images/frameworks/vue-logo.svg",color:"bg-green-500",fontColor:"text-green-500"},{label:"Angular",value:"angular",logo:"/images/frameworks/angular-logo.svg",color:"bg-red-500",fontColor:"text-fuchsia-500"},{label:"Solid",value:"solid",logo:"/images/frameworks/solid-logo.svg",color:"bg-blue-600",fontColor:"text-blue-600"},{label:"Lit",value:"lit",logo:"/images/frameworks/lit-logo.svg",color:"bg-emerald-500",fontColor:"text-emerald-500"},{label:"Svelte",value:"svelte",logo:"/images/frameworks/svelte-logo.svg",color:"bg-orange-600",fontColor:"text-orange-600"},{label:"Qwik",value:"qwik",logo:"/images/frameworks/qwik-logo.svg",color:"bg-indigo-500",fontColor:"text-indigo-500"},{label:"Vanilla",value:"vanilla",logo:"/images/frameworks/js-logo.svg",color:"bg-yellow-500",fontColor:"text-yellow-500"}];function ye(r){return Y.filter(t=>r.includes(t.value))}function _({frameworks:r}){const t=Ce({frameworks:r}),l=t.available.find(a=>a.value===t.selected);return e.jsx(Q,{className:"w-full",icon:l?.logo?e.jsx("img",{src:l.logo,alt:l.label,className:"w-4 h-4"}):void 0,selected:t.selected,available:t.available,onSelect:t.onSelect})}const Ne=X(r=>({currentFramework:typeof document<"u"&&localStorage.getItem("framework")||void 0,setCurrentFramework:t=>{localStorage.setItem("framework",t),r({currentFramework:t})}}));function Ce({frameworks:r}){const t=O(r);return n.useMemo(()=>({label:"Framework",selected:r.includes(t.framework)?t.framework:"react",available:ye(r),onSelect:a=>{t.setFramework(a.value)}}),[r,t])}function O(r){const t=K(),{framework:l}=I({strict:!1}),a=Ne();let s=l||a.currentFramework||"react";s=r.includes(s)?s:"react";const d=n.useCallback(i=>{t({params:{framework:i}}),a.setCurrentFramework(i)},[a,t]);return n.useEffect(()=>{a.currentFramework||a.setCurrentFramework(s),l&&l!==a.currentFramework&&a.setCurrentFramework(l)}),{framework:s,setFramework:d}}function B({versions:r}){const t=Ie({versions:r});return e.jsx(Q,{className:"w-full",icon:e.jsx(be,{className:"w-3.5 h-3.5 opacity-60"}),selected:t.selected,available:t.available,onSelect:t.onSelect})}const Se=X(r=>({currentVersion:typeof document<"u"&&localStorage.getItem("version")||void 0,setCurrentVersion:t=>{localStorage.setItem("version",t),r({currentVersion:t})}}));function Fe(r){const t=K(),{version:l}=I({strict:!1}),a=Se();let s=l||a.currentVersion||"latest";s=r.includes(s)?s:"latest";const d=n.useCallback(i=>{t({params:{version:i}}),a.setCurrentVersion(i)},[a,t]);return n.useEffect(()=>{a.currentVersion||a.setCurrentVersion(s),l&&l!==a.currentVersion&&a.setCurrentVersion(l)}),{version:s,setVersion:d}}function Ie({versions:r}){const t=Fe(r);return n.useMemo(()=>{const a=r.reduce((s,d)=>(s.push({label:d,value:d}),s),[{label:"Latest",value:"latest"}]);return{label:"Version",selected:r.includes(t.version)?t.version:"latest",available:a,onSelect:s=>{t.setVersion(s.value)}}},[t,r])}function Me({menuConfig:r,activeItem:t,fullPathname:l,colorFrom:a,colorTo:s,frameworkLogo:d,version:i,onHover:y,onClick:N}){const f=[];r.forEach(c=>{f.push({label:c.label,isSection:!0}),c.children?.forEach(x=>{f.push({to:x.to,label:x.label,isSection:!1})})});const h=c=>{if(!c||c.startsWith("http"))return!1;if(c===t)return!0;if(c==="..")return l.match(/^\/[^/]+\/[^/]+\/?$/)!==null;if(c==="./framework")return l.includes("/docs/framework")&&!l.match(/\/docs\/framework\/[^/]+/);if(c.includes("/$libraryId")){const x=c.split("/docs/")[1];if(x&&l.includes(`/docs/${x}`))return!0}return!1};return e.jsxs("button",{type:"button",className:"flex flex-col gap-2 py-2 px-2 cursor-pointer h-full w-full focus:outline-none focus:ring-2 focus:ring-inset focus:ring-gray-400/50",onPointerEnter:y,onFocus:y,onClick:N,"aria-label":"Open documentation menu",children:[e.jsxs("div",{className:"flex flex-col gap-2 shrink-0",children:[e.jsx("div",{className:"flex items-center justify-center",children:e.jsx("span",{className:"flex items-center justify-center w-6 h-6",children:d?e.jsx("img",{src:d,alt:"",className:"w-4 h-4"}):e.jsx(U,{className:"w-3.5 h-3.5 opacity-60"})})}),e.jsx("div",{className:"flex items-center justify-center",children:e.jsx("span",{className:"flex items-center justify-center px-1 py-0.5 text-[9px] font-medium opacity-60 border border-gray-500/30 rounded",children:i})})]}),e.jsx("div",{className:"flex-1 flex flex-col gap-1 min-h-0",children:f.map((c,x)=>{const p=!c.isSection&&h(c.to);return e.jsx("div",{className:b("flex-1 min-h-[4px] max-h-[9px] min-w-[20px] rounded-sm",c.isSection?"w-full bg-current opacity-15":p?"ml-2 w-[calc(100%-0.5rem)]":"ml-2 w-[calc(100%-0.5rem)] bg-current opacity-[0.06]"),style:!c.isSection&&p?{backgroundImage:`linear-gradient(to right, ${w(a)}, ${w(s)})`}:void 0,title:typeof c.label=="string"?c.label:`Item ${x+1}`},x)})})]})}const Z=n.createContext(null),De=()=>{const r=n.useContext(Z);if(!r)throw new Error("useWidthToggle must be used within a WidthToggleProvider");return r},ee=n.createContext(null),Ve=()=>n.useContext(ee);function Ae(){const r=Ve();if(!r)return null;const{prevItem:t,nextItem:l,colorFrom:a,colorTo:s,textColor:d,docsBasePath:i}=r;return!t&&!l?null:e.jsxs("div",{className:"sticky flex items-stretch bottom-2 z-10 right-0 text-[10px] sm:text-xs md:text-sm print:hidden",children:[e.jsx("div",{className:"flex-1 flex justify-start",children:t?e.jsxs(J,{as:E,from:i,to:t.to,params:!0,className:"py-1 px-2 sm:py-2 sm:px-3 flex items-center gap-1 sm:gap-2",children:[e.jsx(pe,{className:"w-3 h-3 sm:w-4 sm:h-4"}),e.jsxs("div",{className:"flex flex-col",children:[e.jsx("span",{className:"hidden sm:block text-[10px] uppercase tracking-wider opacity-60 mb-0.5",children:"Previous"}),e.jsx("span",{className:"font-bold",children:t.label})]})]}):null}),e.jsx("div",{className:"flex-1 flex justify-end",children:l?e.jsxs(J,{as:E,from:i,to:l.to,params:!0,className:"py-1 px-2 sm:py-2 sm:px-3 flex items-center gap-1 sm:gap-2",children:[e.jsxs("div",{className:"flex flex-col items-end",children:[e.jsx("span",{className:"hidden sm:block text-[10px] uppercase tracking-wider opacity-60 mb-0.5",children:"Next"}),e.jsx("span",{className:"font-bold text-right bg-clip-text text-transparent",style:{backgroundImage:`linear-gradient(to right, ${w(a)}, ${w(s)})`},children:l.label})]}),e.jsx(ve,{className:"w-3 h-3 sm:w-4 sm:h-4",style:{color:w(d)}})]}):null})]})}const $e=({config:r,repo:t,frameworks:l,libraryId:a})=>{const s=O(l);return[{label:"Menu",children:[{label:"Home",to:".."},...l.length>1?[{label:"Frameworks",to:"./framework"}]:[],{label:e.jsxs("div",{className:"flex items-center gap-2",children:["GitHub ",e.jsx(ge,{className:"opacity-20"})]}),to:`https://github.com/${t}`}]},...r.sections.map(i=>{const N=i.frameworks?.find(h=>h.label===s.framework)?.children??[],f=[...(i.children??[]).map(h=>({...h,badge:"core"})),...N.map(h=>({...h,badge:s.framework}))];if(f.length!==0)return{label:i.label,children:f,collapsible:i.collapsible??!1,defaultCollapsed:i.defaultCollapsed??!1}})].filter(i=>i!==void 0)};function Te({colorFrom:r,colorTo:t,textColor:l,config:a,frameworks:s,versions:d,repo:i,children:y,version:N,isLandingPage:f=!1,docsBasePath:h="/$lang/$project/$version/docs"}){const{project:c}=I({strict:!1}),{_splat:x}=I({strict:!1}),p=$e({config:a,frameworks:s,repo:i,libraryId:c}),C=fe(),D=je(C),te=C.some(o=>o.pathname.includes("/examples/")),re=C.some(o=>o.pathname.includes("/docs/npm-stats")),A=n.useRef(null),T=n.useMemo(()=>p.flatMap(o=>o?.children),[p]),M=n.useMemo(()=>T.filter(o=>o&&!o.to.startsWith("http")),[T]),le=C.find(o=>o.pathname.includes("/docs"))?.pathname??"",R=D.pathname.replace(le+"/",""),z=M.findIndex(o=>o?.to===R),ae=M[z-1],se=M[z+1],oe=O(s),ne=Y.find(o=>o.value===oe.framework),[P,ie]=ke("docsFullWidth",!1),V=n.useMemo(()=>p.reduce((o,u,g)=>{const v=u.children.some(k=>k.to===x),m=`${g}:${String(u.label)}`;return o[m]=v?!0:typeof u.defaultCollapsed<"u"?!u.defaultCollapsed:!1,o},{}),[p,x]),[ce,q]=n.useState(V);n.useEffect(()=>{q(o=>{let u=!1;const g={...o};return Object.entries(V).forEach(([v,m])=>{if(!(v in g)){g[v]=m,u=!0;return}m&&!g[v]&&(g[v]=!0,u=!0)}),u?g:o})},[V]);const G=p.map((o,u)=>{const g=`${u}:${String(o.label)}`,v=e.jsxs(e.Fragment,{children:[o.collapsible?e.jsx("summary",{className:"text-[.8em] font-bold leading-4 px-2 ts-sidebar-label",children:o.label}):e.jsx("div",{className:"text-[.8em] font-bold leading-4 px-2 ts-sidebar-label",children:o.label}),e.jsx("div",{className:"h-2"}),e.jsx("ul",{className:"text-[.85em] leading-snug list-none",children:o?.children?.map((m,k)=>{const j="flex gap-2 items-center justify-between group px-2 py-1.5 rounded-lg hover:bg-gray-500/10 opacity-60 hover:opacity-100";return e.jsx("li",{children:m.to.startsWith("http")?e.jsx("a",{href:m.to,className:j,target:"_blank",rel:"noopener noreferrer",children:m.label}):e.jsx(E,{from:h,to:m.to,params:!0,onClick:()=>{A.current.removeAttribute("open")},preload:!1,activeOptions:{exact:!0,includeHash:!1,includeSearch:!1},className:"relative",children:W=>e.jsx("div",{className:b(j,W.isActive&&"opacity-100"),children:e.jsx("div",{className:b("w-full",W.isActive?"font-bold text-transparent bg-clip-text":""),style:W.isActive?{backgroundImage:`linear-gradient(to right, ${w(r)}, ${w(t)})`}:void 0,children:m.label})})})},k)})})]});return o.collapsible?e.jsx("details",{className:"[&>summary]:before:mr-1 [&>summary]:marker:text-[0.8em] [&>summary]:marker:leading-4 relative select-none",open:ce[g]??!1,onToggle:m=>{const k=m.currentTarget.open;q(j=>j[g]===k?j:{...j,[g]:k})},children:v},`group-${u}`):e.jsx("div",{className:"[&>summary]:before:mr-1 [&>summary]:marker:text-[0.8em] [&>summary]:marker:leading-4 relative select-none",children:v},`group-${u}`)}),de=e.jsx("div",{className:`md:hidden bg-white/50 sticky top-[var(--navbar-height)]
1
+ import{z as L,r as n,B as K,o as I,j as e,S as Q,D as fe,L as E,q as w,t as b,E as xe,F as H,G as ge,M as U,C as J}from"./main-Csj9i19C.js";import{F as he}from"./Footer-l6Y8-ltB.js";import{c as X}from"./react-os8EX6z1.js";const pe=L("ChevronLeft",[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]]);const ve=L("ChevronRight",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]);const be=L("Tag",[["path",{d:"M12.586 2.586A2 2 0 0 0 11.172 2H4a2 2 0 0 0-2 2v7.172a2 2 0 0 0 .586 1.414l8.704 8.704a2.426 2.426 0 0 0 3.42 0l6.58-6.58a2.426 2.426 0 0 0 0-3.42z",key:"vktsd0"}],["circle",{cx:"7.5",cy:"7.5",r:".5",fill:"currentColor",key:"kqv944"}]]);function we(r){if(typeof window>"u")return;const t=localStorage.getItem(r);if(t)try{const l=JSON.parse(t);if(!l.ttl)return l.value;if(new Date().getTime()>l.ttl){localStorage.removeItem(r);return}return l.value}catch{localStorage.removeItem(r);return}}function ke(r,t,l){const[a,s]=n.useState(t);return n.useEffect(()=>{const d=we(r);d!==void 0&&s(d)},[r]),n.useEffect(()=>{localStorage.setItem(r,JSON.stringify({value:a,ttl:null}))},[r,a,l]),[a,s]}function je(r){return r[r.length-1]}const Y=[{label:"React",value:"react",logo:"/images/frameworks/react-logo.svg",color:"bg-blue-500",fontColor:"text-sky-500"},{label:"Preact",value:"preact",logo:"/images/frameworks/preact-logo.svg",color:"bg-purple-500",fontColor:"text-purple-500"},{label:"Vue",value:"vue",logo:"/images/frameworks/vue-logo.svg",color:"bg-green-500",fontColor:"text-green-500"},{label:"Angular",value:"angular",logo:"/images/frameworks/angular-logo.svg",color:"bg-red-500",fontColor:"text-fuchsia-500"},{label:"Solid",value:"solid",logo:"/images/frameworks/solid-logo.svg",color:"bg-blue-600",fontColor:"text-blue-600"},{label:"Lit",value:"lit",logo:"/images/frameworks/lit-logo.svg",color:"bg-emerald-500",fontColor:"text-emerald-500"},{label:"Svelte",value:"svelte",logo:"/images/frameworks/svelte-logo.svg",color:"bg-orange-600",fontColor:"text-orange-600"},{label:"Qwik",value:"qwik",logo:"/images/frameworks/qwik-logo.svg",color:"bg-indigo-500",fontColor:"text-indigo-500"},{label:"Vanilla",value:"vanilla",logo:"/images/frameworks/js-logo.svg",color:"bg-yellow-500",fontColor:"text-yellow-500"}];function ye(r){return Y.filter(t=>r.includes(t.value))}function _({frameworks:r}){const t=Ce({frameworks:r}),l=t.available.find(a=>a.value===t.selected);return e.jsx(Q,{className:"w-full",icon:l?.logo?e.jsx("img",{src:l.logo,alt:l.label,className:"w-4 h-4"}):void 0,selected:t.selected,available:t.available,onSelect:t.onSelect})}const Ne=X(r=>({currentFramework:typeof document<"u"&&localStorage.getItem("framework")||void 0,setCurrentFramework:t=>{localStorage.setItem("framework",t),r({currentFramework:t})}}));function Ce({frameworks:r}){const t=O(r);return n.useMemo(()=>({label:"Framework",selected:r.includes(t.framework)?t.framework:"react",available:ye(r),onSelect:a=>{t.setFramework(a.value)}}),[r,t])}function O(r){const t=K(),{framework:l}=I({strict:!1}),a=Ne();let s=l||a.currentFramework||"react";s=r.includes(s)?s:"react";const d=n.useCallback(i=>{t({params:{framework:i}}),a.setCurrentFramework(i)},[a,t]);return n.useEffect(()=>{a.currentFramework||a.setCurrentFramework(s),l&&l!==a.currentFramework&&a.setCurrentFramework(l)}),{framework:s,setFramework:d}}function B({versions:r}){const t=Ie({versions:r});return e.jsx(Q,{className:"w-full",icon:e.jsx(be,{className:"w-3.5 h-3.5 opacity-60"}),selected:t.selected,available:t.available,onSelect:t.onSelect})}const Se=X(r=>({currentVersion:typeof document<"u"&&localStorage.getItem("version")||void 0,setCurrentVersion:t=>{localStorage.setItem("version",t),r({currentVersion:t})}}));function Fe(r){const t=K(),{version:l}=I({strict:!1}),a=Se();let s=l||a.currentVersion||"latest";s=r.includes(s)?s:"latest";const d=n.useCallback(i=>{t({params:{version:i}}),a.setCurrentVersion(i)},[a,t]);return n.useEffect(()=>{a.currentVersion||a.setCurrentVersion(s),l&&l!==a.currentVersion&&a.setCurrentVersion(l)}),{version:s,setVersion:d}}function Ie({versions:r}){const t=Fe(r);return n.useMemo(()=>{const a=r.reduce((s,d)=>(s.push({label:d,value:d}),s),[{label:"Latest",value:"latest"}]);return{label:"Version",selected:r.includes(t.version)?t.version:"latest",available:a,onSelect:s=>{t.setVersion(s.value)}}},[t,r])}function Me({menuConfig:r,activeItem:t,fullPathname:l,colorFrom:a,colorTo:s,frameworkLogo:d,version:i,onHover:y,onClick:N}){const f=[];r.forEach(c=>{f.push({label:c.label,isSection:!0}),c.children?.forEach(x=>{f.push({to:x.to,label:x.label,isSection:!1})})});const h=c=>{if(!c||c.startsWith("http"))return!1;if(c===t)return!0;if(c==="..")return l.match(/^\/[^/]+\/[^/]+\/?$/)!==null;if(c==="./framework")return l.includes("/docs/framework")&&!l.match(/\/docs\/framework\/[^/]+/);if(c.includes("/$libraryId")){const x=c.split("/docs/")[1];if(x&&l.includes(`/docs/${x}`))return!0}return!1};return e.jsxs("button",{type:"button",className:"flex flex-col gap-2 py-2 px-2 cursor-pointer h-full w-full focus:outline-none focus:ring-2 focus:ring-inset focus:ring-gray-400/50",onPointerEnter:y,onFocus:y,onClick:N,"aria-label":"Open documentation menu",children:[e.jsxs("div",{className:"flex flex-col gap-2 shrink-0",children:[e.jsx("div",{className:"flex items-center justify-center",children:e.jsx("span",{className:"flex items-center justify-center w-6 h-6",children:d?e.jsx("img",{src:d,alt:"",className:"w-4 h-4"}):e.jsx(U,{className:"w-3.5 h-3.5 opacity-60"})})}),e.jsx("div",{className:"flex items-center justify-center",children:e.jsx("span",{className:"flex items-center justify-center px-1 py-0.5 text-[9px] font-medium opacity-60 border border-gray-500/30 rounded",children:i})})]}),e.jsx("div",{className:"flex-1 flex flex-col gap-1 min-h-0",children:f.map((c,x)=>{const p=!c.isSection&&h(c.to);return e.jsx("div",{className:b("flex-1 min-h-[4px] max-h-[9px] min-w-[20px] rounded-sm",c.isSection?"w-full bg-current opacity-15":p?"ml-2 w-[calc(100%-0.5rem)]":"ml-2 w-[calc(100%-0.5rem)] bg-current opacity-[0.06]"),style:!c.isSection&&p?{backgroundImage:`linear-gradient(to right, ${w(a)}, ${w(s)})`}:void 0,title:typeof c.label=="string"?c.label:`Item ${x+1}`},x)})})]})}const Z=n.createContext(null),De=()=>{const r=n.useContext(Z);if(!r)throw new Error("useWidthToggle must be used within a WidthToggleProvider");return r},ee=n.createContext(null),Ve=()=>n.useContext(ee);function Ae(){const r=Ve();if(!r)return null;const{prevItem:t,nextItem:l,colorFrom:a,colorTo:s,textColor:d,docsBasePath:i}=r;return!t&&!l?null:e.jsxs("div",{className:"sticky flex items-stretch bottom-2 z-10 right-0 text-[10px] sm:text-xs md:text-sm print:hidden",children:[e.jsx("div",{className:"flex-1 flex justify-start",children:t?e.jsxs(J,{as:E,from:i,to:t.to,params:!0,className:"py-1 px-2 sm:py-2 sm:px-3 flex items-center gap-1 sm:gap-2",children:[e.jsx(pe,{className:"w-3 h-3 sm:w-4 sm:h-4"}),e.jsxs("div",{className:"flex flex-col",children:[e.jsx("span",{className:"hidden sm:block text-[10px] uppercase tracking-wider opacity-60 mb-0.5",children:"Previous"}),e.jsx("span",{className:"font-bold",children:t.label})]})]}):null}),e.jsx("div",{className:"flex-1 flex justify-end",children:l?e.jsxs(J,{as:E,from:i,to:l.to,params:!0,className:"py-1 px-2 sm:py-2 sm:px-3 flex items-center gap-1 sm:gap-2",children:[e.jsxs("div",{className:"flex flex-col items-end",children:[e.jsx("span",{className:"hidden sm:block text-[10px] uppercase tracking-wider opacity-60 mb-0.5",children:"Next"}),e.jsx("span",{className:"font-bold text-right bg-clip-text text-transparent",style:{backgroundImage:`linear-gradient(to right, ${w(a)}, ${w(s)})`},children:l.label})]}),e.jsx(ve,{className:"w-3 h-3 sm:w-4 sm:h-4",style:{color:w(d)}})]}):null})]})}const $e=({config:r,repo:t,frameworks:l,libraryId:a})=>{const s=O(l);return[{label:"Menu",children:[{label:"Home",to:".."},...l.length>1?[{label:"Frameworks",to:"./framework"}]:[],{label:e.jsxs("div",{className:"flex items-center gap-2",children:["GitHub ",e.jsx(ge,{className:"opacity-20"})]}),to:`https://github.com/${t}`}]},...r.sections.map(i=>{const N=i.frameworks?.find(h=>h.label===s.framework)?.children??[],f=[...(i.children??[]).map(h=>({...h,badge:"core"})),...N.map(h=>({...h,badge:s.framework}))];if(f.length!==0)return{label:i.label,children:f,collapsible:i.collapsible??!1,defaultCollapsed:i.defaultCollapsed??!1}})].filter(i=>i!==void 0)};function Te({colorFrom:r,colorTo:t,textColor:l,config:a,frameworks:s,versions:d,repo:i,children:y,version:N,isLandingPage:f=!1,docsBasePath:h="/$lang/$project/$version/docs"}){const{project:c}=I({strict:!1}),{_splat:x}=I({strict:!1}),p=$e({config:a,frameworks:s,repo:i,libraryId:c}),C=fe(),D=je(C),te=C.some(o=>o.pathname.includes("/examples/")),re=C.some(o=>o.pathname.includes("/docs/npm-stats")),A=n.useRef(null),T=n.useMemo(()=>p.flatMap(o=>o?.children),[p]),M=n.useMemo(()=>T.filter(o=>o&&!o.to.startsWith("http")),[T]),le=C.find(o=>o.pathname.includes("/docs"))?.pathname??"",R=D.pathname.replace(le+"/",""),z=M.findIndex(o=>o?.to===R),ae=M[z-1],se=M[z+1],oe=O(s),ne=Y.find(o=>o.value===oe.framework),[P,ie]=ke("docsFullWidth",!1),V=n.useMemo(()=>p.reduce((o,u,g)=>{const v=u.children.some(k=>k.to===x),m=`${g}:${String(u.label)}`;return o[m]=v?!0:typeof u.defaultCollapsed<"u"?!u.defaultCollapsed:!1,o},{}),[p,x]),[ce,q]=n.useState(V);n.useEffect(()=>{q(o=>{let u=!1;const g={...o};return Object.entries(V).forEach(([v,m])=>{if(!(v in g)){g[v]=m,u=!0;return}m&&!g[v]&&(g[v]=!0,u=!0)}),u?g:o})},[V]);const G=p.map((o,u)=>{const g=`${u}:${String(o.label)}`,v=e.jsxs(e.Fragment,{children:[o.collapsible?e.jsx("summary",{className:"text-[.8em] font-bold leading-4 px-2 ts-sidebar-label",children:o.label}):e.jsx("div",{className:"text-[.8em] font-bold leading-4 px-2 ts-sidebar-label",children:o.label}),e.jsx("div",{className:"h-2"}),e.jsx("ul",{className:"text-[.85em] leading-snug list-none",children:o?.children?.map((m,k)=>{const j="flex gap-2 items-center justify-between group px-2 py-1.5 rounded-lg hover:bg-gray-500/10 opacity-60 hover:opacity-100";return e.jsx("li",{children:m.to.startsWith("http")?e.jsx("a",{href:m.to,className:j,target:"_blank",rel:"noopener noreferrer",children:m.label}):e.jsx(E,{from:h,to:m.to,params:!0,onClick:()=>{A.current.removeAttribute("open")},preload:!1,activeOptions:{exact:!0,includeHash:!1,includeSearch:!1},className:"relative",children:W=>e.jsx("div",{className:b(j,W.isActive&&"opacity-100"),children:e.jsx("div",{className:b("w-full",W.isActive?"font-bold text-transparent bg-clip-text":""),style:W.isActive?{backgroundImage:`linear-gradient(to right, ${w(r)}, ${w(t)})`}:void 0,children:m.label})})})},k)})})]});return o.collapsible?e.jsx("details",{className:"[&>summary]:before:mr-1 [&>summary]:marker:text-[0.8em] [&>summary]:marker:leading-4 relative select-none",open:ce[g]??!1,onToggle:m=>{const k=m.currentTarget.open;q(j=>j[g]===k?j:{...j,[g]:k})},children:v},`group-${u}`):e.jsx("div",{className:"[&>summary]:before:mr-1 [&>summary]:marker:text-[0.8em] [&>summary]:marker:leading-4 relative select-none",children:v},`group-${u}`)}),de=e.jsx("div",{className:`md:hidden bg-white/50 sticky top-[var(--navbar-height)]
2
2
  max-h-[calc(100dvh-var(--navbar-height))] overflow-y-auto z-20 dark:bg-black/60 backdrop-blur-lg`,children:e.jsxs("details",{ref:A,id:"docs-details",className:"border-b border-gray-500/20",children:[e.jsxs("summary",{className:"py-2 px-4 flex gap-2 items-center",children:[e.jsxs("div",{className:"flex gap-2 items-center shrink-0 pr-2",children:[e.jsx(U,{className:"cursor-pointer"}),"Docs"]}),e.jsx("div",{className:"w-px h-6 bg-gray-300 dark:bg-gray-600 shrink-0"}),e.jsx("div",{className:"flex-1 flex items-center gap-2 min-w-0"})]}),e.jsxs("div",{className:"flex flex-col gap-4 p-4 overflow-y-auto border-t border-gray-500/20 bg-white/20 text-lg dark:bg-black/20",children:[e.jsxs("div",{className:"flex flex-col gap-1",children:[e.jsx(_,{frameworks:s}),e.jsx(B,{versions:d}),e.jsx(H,{})]}),G]})]})}),[$,S]=n.useState(!1),F=n.useRef(void 0),ue=xe({enabled:$&&typeof window<"u"&&window.innerWidth<1280,onClickOutside:()=>S(!1)}),me=e.jsxs(e.Fragment,{children:[e.jsx("div",{className:b("hidden md:flex xl:hidden flex-col overflow-hidden","sticky top-[var(--navbar-height)] h-[calc(100dvh-var(--navbar-height))]","z-10 border-r border-gray-500/20","bg-white/50 dark:bg-black/30","w-10"),children:e.jsx(Me,{menuConfig:p,activeItem:R,fullPathname:D.pathname,colorFrom:r,colorTo:t,frameworkLogo:ne?.logo,version:N,onHover:()=>{window.innerWidth<1280&&(clearTimeout(F.current),S(!0))},onClick:()=>{window.innerWidth<1280&&(clearTimeout(F.current),S(!0))}})}),e.jsx("div",{ref:ue,className:b("max-w-[250px] xl:max-w-[300px] 2xl:max-w-[400px]","flex-col overflow-hidden","h-[calc(100dvh-var(--navbar-height))] top-[var(--navbar-height)]","z-20 border-r border-gray-500/20","transition-all duration-300","hidden md:flex","md:fixed md:left-0 md:bg-white md:dark:bg-black/95 md:backdrop-blur-lg md:shadow-xl","xl:sticky xl:bg-transparent xl:dark:bg-transparent xl:backdrop-blur-none xl:shadow-none",!$&&"md:-translate-x-full xl:translate-x-0",$&&"md:translate-x-0"),onPointerEnter:o=>{o.pointerType!=="touch"&&window.innerWidth<1280&&clearTimeout(F.current)},onPointerLeave:o=>{o.pointerType!=="touch"&&window.innerWidth<1280&&(F.current=setTimeout(()=>{S(!1)},300))},children:e.jsxs("div",{className:"flex-1 flex flex-col overflow-y-auto",children:[e.jsxs("div",{className:"flex flex-col gap-1 p-4",children:[e.jsx(_,{frameworks:s}),e.jsx(B,{versions:d}),e.jsx(H,{})]}),e.jsx("div",{className:"flex-1 flex flex-col gap-4 text-base px-4 pt-0 pb-4",children:G})]})})]});return e.jsx(Z.Provider,{value:{isFullWidth:P,setIsFullWidth:ie},children:e.jsx(ee.Provider,{value:{prevItem:ae,nextItem:se,colorFrom:r,colorTo:t,textColor:l,docsBasePath:h},children:e.jsxs("div",{className:`
3
3
  md:min-h-[calc(100dvh-var(--navbar-height))]
4
4
  flex flex-col md:flex-row
@@ -1 +1 @@
1
- import{r as n,j as e}from"./main-DqZtiCro.js";function c({tabs:t,children:o}){const s=n.useId(),d=n.Children.toArray(o),[l,i]=n.useState(t[0]?.slug??"");return t.length===0?null:e.jsxs("div",{className:"not-prose my-4",children:[e.jsx("div",{className:"flex items-center justify-start gap-0 overflow-x-auto overflow-y-hidden bg-gray-100 dark:bg-gray-900 border border-b-0 border-gray-500/20 rounded-t-md",children:t.map(r=>e.jsx("button",{type:"button",onClick:()=>i(r.slug),"aria-label":r.name,title:r.name,className:`px-3 py-1.5 text-sm font-medium transition-colors border-b-2 -mb-[1px] ${l===r.slug?"border-current text-current bg-white dark:bg-gray-950":"border-transparent text-gray-600 dark:text-gray-400 hover:text-gray-900 dark:hover:text-gray-200 hover:bg-gray-200 dark:hover:bg-gray-800"}`,children:r.name},`${s}-${r.slug}`))}),e.jsx("div",{children:d.map((r,g)=>{const a=t[g];return a?e.jsx("div",{"data-tab":a.slug,hidden:a.slug!==l,className:"file-tabs-panel",children:r},`${s}-${a.slug}-panel`):null})})]})}export{c as FileTabs};
1
+ import{r as n,j as e}from"./main-Csj9i19C.js";function c({tabs:t,children:o}){const s=n.useId(),d=n.Children.toArray(o),[l,i]=n.useState(t[0]?.slug??"");return t.length===0?null:e.jsxs("div",{className:"not-prose my-4",children:[e.jsx("div",{className:"flex items-center justify-start gap-0 overflow-x-auto overflow-y-hidden bg-gray-100 dark:bg-gray-900 border border-b-0 border-gray-500/20 rounded-t-md",children:t.map(r=>e.jsx("button",{type:"button",onClick:()=>i(r.slug),"aria-label":r.name,title:r.name,className:`px-3 py-1.5 text-sm font-medium transition-colors border-b-2 -mb-[1px] ${l===r.slug?"border-current text-current bg-white dark:bg-gray-950":"border-transparent text-gray-600 dark:text-gray-400 hover:text-gray-900 dark:hover:text-gray-200 hover:bg-gray-200 dark:hover:bg-gray-800"}`,children:r.name},`${s}-${r.slug}`))}),e.jsx("div",{children:d.map((r,g)=>{const a=t[g];return a?e.jsx("div",{"data-tab":a.slug,hidden:a.slug!==l,className:"file-tabs-panel",children:r},`${s}-${a.slug}-panel`):null})})]})}export{c as FileTabs};
@@ -1,2 +1,2 @@
1
- import{j as e,C as t,L as r}from"./main-DqZtiCro.js";function a(){return e.jsxs(t,{className:`relative flex flex-col items-start justify-center gap-4 p-8
1
+ import{j as e,C as t,L as r}from"./main-Csj9i19C.js";function a(){return e.jsxs(t,{className:`relative flex flex-col items-start justify-center gap-4 p-8
2
2
  max-w-(--breakpoint-lg) mx-auto text-sm`,children:[e.jsxs("div",{className:"grid gap-1 sm:grid-cols-2 md:grid-cols-3",children:[e.jsx("div",{children:e.jsx(r,{to:"/",children:"Home"})}),e.jsx("div",{children:e.jsx("a",{href:"https://github.com/tanstack",target:"_blank",rel:"noreferrer",children:"GitHub"})})]}),e.jsxs("div",{className:"text-center opacity-60",children:["© ",new Date().getFullYear()," TanStack"]})]})}export{a as F};
@@ -1 +1 @@
1
- import{o as u,j as e,r as d}from"./main-DqZtiCro.js";import{T as k}from"./MarkdownHeadingContext-CdvUDZFU.js";import"./react-qvbbiZob.js";function w(){if(!(typeof document>"u"))return localStorage.getItem("framework")||void 0}function j({codeBlocksByFramework:a,panelsByFramework:n}){const{framework:s}=u({strict:!1}),c=w(),o=(s||c||"react").toLowerCase(),t=a[o]||[],r=n[o];if(!r)return null;if(t.length===0)return e.jsx("div",{className:"framework-content",children:r});if(t.length===1)return e.jsx("div",{className:"framework-content",children:r});const m=t.map((i,f)=>({slug:`file-${f}`,name:i.title||"Untitled"})),l=d.Children.toArray(r);return e.jsx("div",{className:"framework-content",children:e.jsx(k,{tabs:m,children:l})})}export{j as FrameworkContent};
1
+ import{o as u,j as e,r as d}from"./main-Csj9i19C.js";import{T as k}from"./MarkdownHeadingContext-6I862CKH.js";import"./react-os8EX6z1.js";function w(){if(!(typeof document>"u"))return localStorage.getItem("framework")||void 0}function j({codeBlocksByFramework:a,panelsByFramework:n}){const{framework:s}=u({strict:!1}),c=w(),o=(s||c||"react").toLowerCase(),t=a[o]||[],r=n[o];if(!r)return null;if(t.length===0)return e.jsx("div",{className:"framework-content",children:r});if(t.length===1)return e.jsx("div",{className:"framework-content",children:r});const m=t.map((i,f)=>({slug:`file-${f}`,name:i.title||"Untitled"})),l=d.Children.toArray(r);return e.jsx("div",{className:"framework-content",children:e.jsx(k,{tabs:m,children:l})})}export{j as FrameworkContent};