@hawkeyexl/manni 4.29.0 → 4.31.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 (246) hide show
  1. package/README.md +1 -1
  2. package/dist/{batch-LKECW5WN.js → batch-P6LTMOZP.js} +12 -12
  3. package/dist/{build-PIWP7QEQ.js → build-V5JPMFTR.js} +14 -14
  4. package/dist/{calibrate-QBAVFCXX.js → calibrate-YS4NLIC3.js} +13 -13
  5. package/dist/{capture-VS4HY2FL.js → capture-YQDJSSKZ.js} +12 -12
  6. package/dist/check-DVMU74U3.js +58 -0
  7. package/dist/{check-6T3ZZTBW.js → check-FVL7G5PJ.js} +13 -13
  8. package/dist/{check-LKZ2D5Y3.js → check-OWGSBBU7.js} +13 -13
  9. package/dist/{check-C7GN5ZUC.js → check-QAVEMKP2.js} +10 -10
  10. package/dist/{check-HIIEDFCI.js → check-TUP4RG7G.js} +23 -23
  11. package/dist/{chunk-N7HOXMHV.js → chunk-2KGDXZMS.js} +3 -3
  12. package/dist/{chunk-D6HTXNFN.js → chunk-2NB7MT5I.js} +2 -2
  13. package/dist/{chunk-7SYTA2HW.js → chunk-3WX73ME2.js} +3 -3
  14. package/dist/{chunk-6FNRVJQC.js → chunk-4JDOHAHR.js} +6 -6
  15. package/dist/{chunk-HGL5VY2P.js → chunk-66A5PPWF.js} +4 -4
  16. package/dist/{chunk-WV5VMIC5.js → chunk-66U7KHZE.js} +5 -5
  17. package/dist/{chunk-PVAJUMDT.js → chunk-672TCM2Q.js} +4 -4
  18. package/dist/{chunk-OZH46DBT.js → chunk-7OMLNFP7.js} +6 -1
  19. package/dist/chunk-7OMLNFP7.js.map +1 -0
  20. package/dist/{chunk-3FDQKFNQ.js → chunk-7S6H5UML.js} +2 -2
  21. package/dist/{chunk-IYGSEC73.js → chunk-7URMU7S5.js} +2 -2
  22. package/dist/{chunk-OAA6SX2W.js → chunk-AD7IRC5T.js} +3 -3
  23. package/dist/{chunk-4AWM6625.js → chunk-AXIYZIHN.js} +4 -4
  24. package/dist/{chunk-YBDRFSOK.js → chunk-AXSCHC34.js} +5 -5
  25. package/dist/{chunk-NA3M7JLP.js → chunk-BBIEWUO6.js} +6 -6
  26. package/dist/{chunk-FRAEC2Y4.js → chunk-BKLXSWGX.js} +3 -3
  27. package/dist/{chunk-5BHBLVBD.js → chunk-BR6NGHRG.js} +3 -3
  28. package/dist/{chunk-YWHSZSQL.js → chunk-BVQEOF23.js} +3 -3
  29. package/dist/{chunk-4XTNIPXL.js → chunk-CCBIO2CB.js} +2 -2
  30. package/dist/{chunk-44N4NCOQ.js → chunk-CEPNSI4V.js} +2 -2
  31. package/dist/{chunk-Y7SBE6TC.js → chunk-CY4RNLFN.js} +3 -3
  32. package/dist/{chunk-A6FYDQC2.js → chunk-D2N3SAV6.js} +4 -4
  33. package/dist/{chunk-TWOWMTIH.js → chunk-DLIQJJAE.js} +3 -3
  34. package/dist/{chunk-YQG4YCQL.js → chunk-DO5CJVXR.js} +3 -3
  35. package/dist/{chunk-4ZKEJPRY.js → chunk-DOXZ3U4O.js} +50 -20
  36. package/dist/chunk-DOXZ3U4O.js.map +1 -0
  37. package/dist/{chunk-MD52QS2O.js → chunk-DSHAY6YM.js} +3 -3
  38. package/dist/{chunk-I4C5VROJ.js → chunk-EZBWGI25.js} +2 -2
  39. package/dist/{chunk-SF2WTUDR.js → chunk-F6FDIOKE.js} +3 -3
  40. package/dist/{chunk-C7KHPFDN.js → chunk-FJZZYY7Q.js} +8 -8
  41. package/dist/{chunk-A2DDN2HO.js → chunk-GTT7EQEV.js} +2 -2
  42. package/dist/{chunk-DA5RHOH4.js → chunk-GWOVEW53.js} +5 -5
  43. package/dist/{chunk-7QIYWXKX.js → chunk-HVYVIGBP.js} +10 -10
  44. package/dist/{chunk-DM64IZA5.js → chunk-I52GL7N6.js} +3 -3
  45. package/dist/{chunk-LPTOSRG4.js → chunk-ICUKYSPX.js} +2 -2
  46. package/dist/{chunk-KZK5JOET.js → chunk-INDMEKFB.js} +6 -6
  47. package/dist/{chunk-2A7L2AC2.js → chunk-J7OFPDCD.js} +4 -4
  48. package/dist/{chunk-ACHFEEYB.js → chunk-JVZAJBSS.js} +2 -2
  49. package/dist/{chunk-LD7BSZMJ.js → chunk-KPQFF62T.js} +40 -12
  50. package/dist/chunk-KPQFF62T.js.map +1 -0
  51. package/dist/{chunk-ZWE73OJR.js → chunk-KWK6VVK2.js} +7 -7
  52. package/dist/{chunk-IPET4C6M.js → chunk-LU6HSA2N.js} +10 -10
  53. package/dist/{chunk-OY7AMSDK.js → chunk-M5HDMQCI.js} +2 -2
  54. package/dist/{chunk-OPF3NOKF.js → chunk-M77SIRUX.js} +1 -1
  55. package/dist/{chunk-OPF3NOKF.js.map → chunk-M77SIRUX.js.map} +1 -1
  56. package/dist/{chunk-RZX6I2NY.js → chunk-MCUN2JP3.js} +3 -3
  57. package/dist/{chunk-3LAEG2JM.js → chunk-MQ34D4OP.js} +4 -4
  58. package/dist/{chunk-2AC35AS2.js → chunk-MREXYXMW.js} +8 -8
  59. package/dist/{chunk-2HZR3H2N.js → chunk-N7VIVL42.js} +2 -2
  60. package/dist/{chunk-HV6QKQTR.js → chunk-NH4RQUSD.js} +3 -3
  61. package/dist/{chunk-5LSQZBLS.js → chunk-P676AEK6.js} +4 -4
  62. package/dist/{chunk-QEFVMOWF.js → chunk-QYKTIRRE.js} +2 -2
  63. package/dist/{chunk-VGIKTY7D.js → chunk-R64PJYCT.js} +2 -2
  64. package/dist/{chunk-Z2KVPZYI.js → chunk-SORYKTNP.js} +3 -2
  65. package/dist/chunk-SORYKTNP.js.map +1 -0
  66. package/dist/{chunk-DT4VOGC6.js → chunk-SPYYVEWP.js} +8 -8
  67. package/dist/{chunk-C6M7SALA.js → chunk-STPT3WEC.js} +7 -7
  68. package/dist/{chunk-KCNRAZON.js → chunk-TE6SQVNO.js} +8 -8
  69. package/dist/{chunk-BS2HWHLN.js → chunk-TX7NPCCT.js} +6 -6
  70. package/dist/{chunk-XZFJAVX7.js → chunk-UH7KFBBM.js} +9 -8
  71. package/dist/chunk-UH7KFBBM.js.map +1 -0
  72. package/dist/{chunk-6QMD7FTM.js → chunk-VKAE3W6H.js} +4 -4
  73. package/dist/{chunk-Z3YNYZR2.js → chunk-VXZ2CIH7.js} +2 -2
  74. package/dist/{chunk-FR5IEI5I.js → chunk-WX77JHTU.js} +3 -3
  75. package/dist/{chunk-3NGA6KCU.js → chunk-X7UWDGQQ.js} +11 -8
  76. package/dist/chunk-X7UWDGQQ.js.map +1 -0
  77. package/dist/{chunk-AWJ7UWOH.js → chunk-XIEUUETR.js} +6 -6
  78. package/dist/{chunk-SFUKZRTP.js → chunk-YH6MWLDA.js} +2 -2
  79. package/dist/{chunk-TTHG53NH.js → chunk-YT55M4VQ.js} +6 -6
  80. package/dist/{chunk-VQB22TCH.js → chunk-Z7HBBFSZ.js} +578 -28
  81. package/dist/chunk-Z7HBBFSZ.js.map +1 -0
  82. package/dist/{chunk-SXWPKK4D.js → chunk-ZGLLJSL7.js} +2 -2
  83. package/dist/{chunk-77RJZP3W.js → chunk-ZMFSFXQX.js} +17 -12
  84. package/dist/chunk-ZMFSFXQX.js.map +1 -0
  85. package/dist/{chunk-ZMLGMLXE.js → chunk-ZY2XP3AS.js} +13 -13
  86. package/dist/{cli-56Z2RAWA.js → cli-5NIVQZIE.js} +31 -31
  87. package/dist/{cli-ZTSPDBDE.js → cli-7TW4HTQN.js} +14 -14
  88. package/dist/{cli-B3RIVCKY.js → cli-BG6WXYWT.js} +56 -56
  89. package/dist/{cli-YAG5OFYC.js → cli-ME4U7S7Q.js} +28 -28
  90. package/dist/{cli-OIYUAXPA.js → cli-NKGQZKXS.js} +34 -34
  91. package/dist/{cli-RMIZNJL3.js → cli-R5XYFIOY.js} +14 -14
  92. package/dist/{cli-Q3ZRWXB4.js → cli-T2AZSUSY.js} +19 -19
  93. package/dist/{cli-OY6RHP5P.js → cli-TA2IQRYK.js} +7 -7
  94. package/dist/{cli-AVOEQZZM.js → cli-UAM4MBRM.js} +17 -17
  95. package/dist/{cli-BI2GQEDM.js → cli-XVJ5G4EO.js} +27 -27
  96. package/dist/{cli-UINJ634O.js → cli-YKM5YZHY.js} +40 -9
  97. package/dist/cli-YKM5YZHY.js.map +1 -0
  98. package/dist/cli.js +15 -15
  99. package/dist/docmeta.js +6 -6
  100. package/dist/{github-PLPEWRPJ.js → github-SQ2ATTLV.js} +10 -10
  101. package/dist/{github-B3QCNYMP.js → github-X6F2FQL3.js} +13 -13
  102. package/dist/github-ZCA7TOJO.js +49 -0
  103. package/dist/index.d.ts +55 -3
  104. package/dist/index.js +57 -55
  105. package/dist/index.js.map +1 -1
  106. package/dist/{json-UNN7BJM6.js → json-L7QDREEX.js} +10 -10
  107. package/dist/{json-7ERIDOTV.js → json-NSLJFPWD.js} +14 -14
  108. package/dist/{labels-XUW7THEE.js → labels-C4HCKZMZ.js} +9 -9
  109. package/dist/{lint-NWSLIVHJ.js → lint-ODALAI2I.js} +12 -12
  110. package/dist/list-4JLKJOGX.js +56 -0
  111. package/dist/{list-TXOFFLES.js → list-CAE7T5HA.js} +10 -10
  112. package/dist/{list-BKD62XJ4.js → list-TQK3FWC2.js} +13 -13
  113. package/dist/{page-CFDNR2OB.js → page-GB5LHRHX.js} +9 -9
  114. package/dist/{prepare-Y7WBJ3RZ.js → prepare-VCJRE3EY.js} +11 -11
  115. package/dist/{pretty-MTAJRM7S.js → pretty-GP4R3UII.js} +10 -10
  116. package/dist/{pretty-ALGCRVPF.js → pretty-GXLKMUT4.js} +13 -13
  117. package/dist/{pretty-BX6RMDVM.js → pretty-KZPED6KN.js} +23 -23
  118. package/dist/{reporters-QSBVVOX7.js → reporters-GGP4YLIM.js} +11 -11
  119. package/dist/{reporters-OZPJP6UK.js → reporters-GQ2PUWQA.js} +4 -4
  120. package/dist/{reporters-MK62LRGW.js → reporters-Y2AUVODK.js} +4 -4
  121. package/dist/run-SVH32CBO.js +59 -0
  122. package/dist/sarif-CFQJ5HHP.js +50 -0
  123. package/dist/{sarif-JZSDSSBV.js → sarif-UG7F3WQD.js} +8 -8
  124. package/dist/{sarif-KTMQVMN5.js → sarif-UHZD2CJ3.js} +8 -8
  125. package/dist/{strategy-G25TI5UA.js → strategy-Y4NEJRSH.js} +20 -20
  126. package/dist/{term-YYIAR32K.js → term-LQ2F5WEN.js} +15 -15
  127. package/dist/{types-GV2THIRC.js → types-YREQ2DQG.js} +6 -4
  128. package/dist/{validate-VKZJAD77.js → validate-6WBRKEV5.js} +4 -4
  129. package/package.json +2 -1
  130. package/plugin/manni/.claude-plugin/plugin.json +1 -1
  131. package/dist/check-3AZ33DIQ.js +0 -58
  132. package/dist/chunk-3NGA6KCU.js.map +0 -1
  133. package/dist/chunk-4ZKEJPRY.js.map +0 -1
  134. package/dist/chunk-77RJZP3W.js.map +0 -1
  135. package/dist/chunk-LD7BSZMJ.js.map +0 -1
  136. package/dist/chunk-OZH46DBT.js.map +0 -1
  137. package/dist/chunk-VQB22TCH.js.map +0 -1
  138. package/dist/chunk-XZFJAVX7.js.map +0 -1
  139. package/dist/chunk-Z2KVPZYI.js.map +0 -1
  140. package/dist/cli-UINJ634O.js.map +0 -1
  141. package/dist/github-XBGWVVIA.js +0 -49
  142. package/dist/list-WM4EHFC6.js +0 -56
  143. package/dist/run-UTKXWCM4.js +0 -59
  144. package/dist/sarif-6QY3B2KF.js +0 -50
  145. /package/dist/{batch-LKECW5WN.js.map → batch-P6LTMOZP.js.map} +0 -0
  146. /package/dist/{build-PIWP7QEQ.js.map → build-V5JPMFTR.js.map} +0 -0
  147. /package/dist/{calibrate-QBAVFCXX.js.map → calibrate-YS4NLIC3.js.map} +0 -0
  148. /package/dist/{capture-VS4HY2FL.js.map → capture-YQDJSSKZ.js.map} +0 -0
  149. /package/dist/{check-3AZ33DIQ.js.map → check-DVMU74U3.js.map} +0 -0
  150. /package/dist/{check-6T3ZZTBW.js.map → check-FVL7G5PJ.js.map} +0 -0
  151. /package/dist/{check-LKZ2D5Y3.js.map → check-OWGSBBU7.js.map} +0 -0
  152. /package/dist/{check-C7GN5ZUC.js.map → check-QAVEMKP2.js.map} +0 -0
  153. /package/dist/{check-HIIEDFCI.js.map → check-TUP4RG7G.js.map} +0 -0
  154. /package/dist/{chunk-N7HOXMHV.js.map → chunk-2KGDXZMS.js.map} +0 -0
  155. /package/dist/{chunk-D6HTXNFN.js.map → chunk-2NB7MT5I.js.map} +0 -0
  156. /package/dist/{chunk-7SYTA2HW.js.map → chunk-3WX73ME2.js.map} +0 -0
  157. /package/dist/{chunk-6FNRVJQC.js.map → chunk-4JDOHAHR.js.map} +0 -0
  158. /package/dist/{chunk-HGL5VY2P.js.map → chunk-66A5PPWF.js.map} +0 -0
  159. /package/dist/{chunk-WV5VMIC5.js.map → chunk-66U7KHZE.js.map} +0 -0
  160. /package/dist/{chunk-PVAJUMDT.js.map → chunk-672TCM2Q.js.map} +0 -0
  161. /package/dist/{chunk-3FDQKFNQ.js.map → chunk-7S6H5UML.js.map} +0 -0
  162. /package/dist/{chunk-IYGSEC73.js.map → chunk-7URMU7S5.js.map} +0 -0
  163. /package/dist/{chunk-OAA6SX2W.js.map → chunk-AD7IRC5T.js.map} +0 -0
  164. /package/dist/{chunk-4AWM6625.js.map → chunk-AXIYZIHN.js.map} +0 -0
  165. /package/dist/{chunk-YBDRFSOK.js.map → chunk-AXSCHC34.js.map} +0 -0
  166. /package/dist/{chunk-NA3M7JLP.js.map → chunk-BBIEWUO6.js.map} +0 -0
  167. /package/dist/{chunk-FRAEC2Y4.js.map → chunk-BKLXSWGX.js.map} +0 -0
  168. /package/dist/{chunk-5BHBLVBD.js.map → chunk-BR6NGHRG.js.map} +0 -0
  169. /package/dist/{chunk-YWHSZSQL.js.map → chunk-BVQEOF23.js.map} +0 -0
  170. /package/dist/{chunk-4XTNIPXL.js.map → chunk-CCBIO2CB.js.map} +0 -0
  171. /package/dist/{chunk-44N4NCOQ.js.map → chunk-CEPNSI4V.js.map} +0 -0
  172. /package/dist/{chunk-Y7SBE6TC.js.map → chunk-CY4RNLFN.js.map} +0 -0
  173. /package/dist/{chunk-A6FYDQC2.js.map → chunk-D2N3SAV6.js.map} +0 -0
  174. /package/dist/{chunk-TWOWMTIH.js.map → chunk-DLIQJJAE.js.map} +0 -0
  175. /package/dist/{chunk-YQG4YCQL.js.map → chunk-DO5CJVXR.js.map} +0 -0
  176. /package/dist/{chunk-MD52QS2O.js.map → chunk-DSHAY6YM.js.map} +0 -0
  177. /package/dist/{chunk-I4C5VROJ.js.map → chunk-EZBWGI25.js.map} +0 -0
  178. /package/dist/{chunk-SF2WTUDR.js.map → chunk-F6FDIOKE.js.map} +0 -0
  179. /package/dist/{chunk-C7KHPFDN.js.map → chunk-FJZZYY7Q.js.map} +0 -0
  180. /package/dist/{chunk-A2DDN2HO.js.map → chunk-GTT7EQEV.js.map} +0 -0
  181. /package/dist/{chunk-DA5RHOH4.js.map → chunk-GWOVEW53.js.map} +0 -0
  182. /package/dist/{chunk-7QIYWXKX.js.map → chunk-HVYVIGBP.js.map} +0 -0
  183. /package/dist/{chunk-DM64IZA5.js.map → chunk-I52GL7N6.js.map} +0 -0
  184. /package/dist/{chunk-LPTOSRG4.js.map → chunk-ICUKYSPX.js.map} +0 -0
  185. /package/dist/{chunk-KZK5JOET.js.map → chunk-INDMEKFB.js.map} +0 -0
  186. /package/dist/{chunk-2A7L2AC2.js.map → chunk-J7OFPDCD.js.map} +0 -0
  187. /package/dist/{chunk-ACHFEEYB.js.map → chunk-JVZAJBSS.js.map} +0 -0
  188. /package/dist/{chunk-ZWE73OJR.js.map → chunk-KWK6VVK2.js.map} +0 -0
  189. /package/dist/{chunk-IPET4C6M.js.map → chunk-LU6HSA2N.js.map} +0 -0
  190. /package/dist/{chunk-OY7AMSDK.js.map → chunk-M5HDMQCI.js.map} +0 -0
  191. /package/dist/{chunk-RZX6I2NY.js.map → chunk-MCUN2JP3.js.map} +0 -0
  192. /package/dist/{chunk-3LAEG2JM.js.map → chunk-MQ34D4OP.js.map} +0 -0
  193. /package/dist/{chunk-2AC35AS2.js.map → chunk-MREXYXMW.js.map} +0 -0
  194. /package/dist/{chunk-2HZR3H2N.js.map → chunk-N7VIVL42.js.map} +0 -0
  195. /package/dist/{chunk-HV6QKQTR.js.map → chunk-NH4RQUSD.js.map} +0 -0
  196. /package/dist/{chunk-5LSQZBLS.js.map → chunk-P676AEK6.js.map} +0 -0
  197. /package/dist/{chunk-QEFVMOWF.js.map → chunk-QYKTIRRE.js.map} +0 -0
  198. /package/dist/{chunk-VGIKTY7D.js.map → chunk-R64PJYCT.js.map} +0 -0
  199. /package/dist/{chunk-DT4VOGC6.js.map → chunk-SPYYVEWP.js.map} +0 -0
  200. /package/dist/{chunk-C6M7SALA.js.map → chunk-STPT3WEC.js.map} +0 -0
  201. /package/dist/{chunk-KCNRAZON.js.map → chunk-TE6SQVNO.js.map} +0 -0
  202. /package/dist/{chunk-BS2HWHLN.js.map → chunk-TX7NPCCT.js.map} +0 -0
  203. /package/dist/{chunk-6QMD7FTM.js.map → chunk-VKAE3W6H.js.map} +0 -0
  204. /package/dist/{chunk-Z3YNYZR2.js.map → chunk-VXZ2CIH7.js.map} +0 -0
  205. /package/dist/{chunk-FR5IEI5I.js.map → chunk-WX77JHTU.js.map} +0 -0
  206. /package/dist/{chunk-AWJ7UWOH.js.map → chunk-XIEUUETR.js.map} +0 -0
  207. /package/dist/{chunk-SFUKZRTP.js.map → chunk-YH6MWLDA.js.map} +0 -0
  208. /package/dist/{chunk-TTHG53NH.js.map → chunk-YT55M4VQ.js.map} +0 -0
  209. /package/dist/{chunk-SXWPKK4D.js.map → chunk-ZGLLJSL7.js.map} +0 -0
  210. /package/dist/{chunk-ZMLGMLXE.js.map → chunk-ZY2XP3AS.js.map} +0 -0
  211. /package/dist/{cli-56Z2RAWA.js.map → cli-5NIVQZIE.js.map} +0 -0
  212. /package/dist/{cli-ZTSPDBDE.js.map → cli-7TW4HTQN.js.map} +0 -0
  213. /package/dist/{cli-B3RIVCKY.js.map → cli-BG6WXYWT.js.map} +0 -0
  214. /package/dist/{cli-YAG5OFYC.js.map → cli-ME4U7S7Q.js.map} +0 -0
  215. /package/dist/{cli-OIYUAXPA.js.map → cli-NKGQZKXS.js.map} +0 -0
  216. /package/dist/{cli-RMIZNJL3.js.map → cli-R5XYFIOY.js.map} +0 -0
  217. /package/dist/{cli-Q3ZRWXB4.js.map → cli-T2AZSUSY.js.map} +0 -0
  218. /package/dist/{cli-OY6RHP5P.js.map → cli-TA2IQRYK.js.map} +0 -0
  219. /package/dist/{cli-AVOEQZZM.js.map → cli-UAM4MBRM.js.map} +0 -0
  220. /package/dist/{cli-BI2GQEDM.js.map → cli-XVJ5G4EO.js.map} +0 -0
  221. /package/dist/{github-B3QCNYMP.js.map → github-SQ2ATTLV.js.map} +0 -0
  222. /package/dist/{github-PLPEWRPJ.js.map → github-X6F2FQL3.js.map} +0 -0
  223. /package/dist/{github-XBGWVVIA.js.map → github-ZCA7TOJO.js.map} +0 -0
  224. /package/dist/{json-7ERIDOTV.js.map → json-L7QDREEX.js.map} +0 -0
  225. /package/dist/{json-UNN7BJM6.js.map → json-NSLJFPWD.js.map} +0 -0
  226. /package/dist/{labels-XUW7THEE.js.map → labels-C4HCKZMZ.js.map} +0 -0
  227. /package/dist/{lint-NWSLIVHJ.js.map → lint-ODALAI2I.js.map} +0 -0
  228. /package/dist/{list-BKD62XJ4.js.map → list-4JLKJOGX.js.map} +0 -0
  229. /package/dist/{list-TXOFFLES.js.map → list-CAE7T5HA.js.map} +0 -0
  230. /package/dist/{list-WM4EHFC6.js.map → list-TQK3FWC2.js.map} +0 -0
  231. /package/dist/{page-CFDNR2OB.js.map → page-GB5LHRHX.js.map} +0 -0
  232. /package/dist/{prepare-Y7WBJ3RZ.js.map → prepare-VCJRE3EY.js.map} +0 -0
  233. /package/dist/{pretty-ALGCRVPF.js.map → pretty-GP4R3UII.js.map} +0 -0
  234. /package/dist/{pretty-BX6RMDVM.js.map → pretty-GXLKMUT4.js.map} +0 -0
  235. /package/dist/{pretty-MTAJRM7S.js.map → pretty-KZPED6KN.js.map} +0 -0
  236. /package/dist/{reporters-MK62LRGW.js.map → reporters-GGP4YLIM.js.map} +0 -0
  237. /package/dist/{reporters-OZPJP6UK.js.map → reporters-GQ2PUWQA.js.map} +0 -0
  238. /package/dist/{reporters-QSBVVOX7.js.map → reporters-Y2AUVODK.js.map} +0 -0
  239. /package/dist/{run-UTKXWCM4.js.map → run-SVH32CBO.js.map} +0 -0
  240. /package/dist/{sarif-6QY3B2KF.js.map → sarif-CFQJ5HHP.js.map} +0 -0
  241. /package/dist/{sarif-JZSDSSBV.js.map → sarif-UG7F3WQD.js.map} +0 -0
  242. /package/dist/{sarif-KTMQVMN5.js.map → sarif-UHZD2CJ3.js.map} +0 -0
  243. /package/dist/{strategy-G25TI5UA.js.map → strategy-Y4NEJRSH.js.map} +0 -0
  244. /package/dist/{term-YYIAR32K.js.map → term-LQ2F5WEN.js.map} +0 -0
  245. /package/dist/{types-GV2THIRC.js.map → types-YREQ2DQG.js.map} +0 -0
  246. /package/dist/{validate-VKZJAD77.js.map → validate-6WBRKEV5.js.map} +0 -0
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/lint/core/rule-id.ts","../src/lint/reporters/junit.ts","../src/lint/reporters/sarif.ts","../src/lint/reporters/alignment.ts","../src/lint/reporters/index.ts"],"sourcesContent":["/**\n * A finding's **rule identity**: `manni:lint/<job>/<rule>`.\n *\n * One id, in one place, for every consumer that files or correlates findings -\n * the SARIF `ruleId`, the JUnit `<failure type>`, the GitHub annotation's\n * `title`, and the `ruleId` the JSON reporter carries beside `type`. A rule id\n * is durable by contract: rename one and every historical alert in a\n * dashboard closes, then reopens as new.\n *\n * Three segments rather than cite's two. The job is what makes a second lint\n * tool possible without collisions: a prose job will report\n * `manni:lint/prose/Google.Passive`, keeping Vale's own rule name because that\n * is the name Vale's documentation uses, and nothing about it can be confused\n * with a structure rule. Proposal 0050 records the shape, and warns that\n * anything parsing family rule ids must not assume two segments.\n *\n * The rule half is derived from the finding's `type` rather than authored\n * beside it. `type` is already the machine-readable name the JSON reporter\n * publishes - manni docevals' grader reads it - so a hand-maintained second\n * table would be one more thing to keep in step, and the derivation cannot\n * drift. `_error` is dropped because it says only that a finding is a finding;\n * `heading_pattern_error` is the rule \"heading-pattern\".\n */\nimport type { LintJob } from \"./config.js\";\n\n/** Every lint rule id starts here. */\nexport const RULE_ID_PREFIX = \"manni:lint\";\n\n/** The tool that performs the structure job, reported beside every finding. */\nexport const TOOL_NAME = \"manni\";\n\n/** The job every finding in this pipeline reports under. */\nexport const STRUCTURE_JOB: LintJob = \"structure\";\n\n/**\n * `heading_pattern_error` -> `heading-pattern`; `parse_error` -> `parse`.\n *\n * Only a trailing `_error` is dropped, so a rule that is genuinely *about*\n * errors keeps the word.\n */\nexport function ruleName(type: string): string {\n return type.replace(/_error$/, \"\").replace(/_/g, \"-\");\n}\n\n/** `manni:lint/<job>/<rule>` for one finding `type`. */\nexport function ruleId(type: string, job: LintJob = STRUCTURE_JOB): string {\n return `${RULE_ID_PREFIX}/${job}/${ruleName(type)}`;\n}\n","/**\n * JUnit XML, rendered through **meta's** writer rather than a second one.\n *\n * There is no authoritative JUnit schema, and the escaping is the part a\n * hand-rolled writer gets wrong - XML 1.0 forbids characters that sit quite\n * happily in a JavaScript string, and one of them makes the whole document\n * unparseable rather than merely mis-rendered. That work is done once, in\n * `src/meta/reporters/junit.ts`, and cite already rides it. So does lint:\n * adapt the run onto meta's `ValidationResult`, hand it to that writer, and\n * the family ships one XML writer, one escaping rule, and one\n * testcase-per-file convention.\n *\n * What is lint's is the two strings that identify the findings as lint's:\n * the `classname` on every `<testcase>`, and the `<failure type>`, which is\n * the namespaced rule id. A finding's template rides along as meta's\n * `guidance`, so each `<failure>` body says what the template asks for.\n */\nimport {\n isErrorSeverity,\n renderJunit as renderJunitXml,\n type FieldError,\n type ValidationResult,\n} from \"../../meta/index.js\";\nimport { RULE_ID_PREFIX, ruleName, STRUCTURE_JOB } from \"../core/rule-id.js\";\nimport type { LintRun } from \"../commands/lint.js\";\n\n/** JUnit `classname` for this tool's findings, as cite's is `manni.cite`. */\nconst JUNIT_CLASSNAME = \"manni.lint\";\n\n/**\n * One finding as a `FieldError`.\n *\n * `schema` and `keyword` are split where they are because meta's `ruleIdFor`\n * joins them with a `/`, and the id it has to produce is\n * `manni:lint/<job>/<rule>`. The prefix is the schema half and stays one\n * segment, which is what keeps it a built-in-shaped ref: a ref containing a\n * slash classifies as a local file, and a caller that passed a path frame\n * would see it rewritten into a relative path. The job and the rule travel\n * together as the keyword.\n *\n * `instancePath` is `\"\"`, the whole document. A structural finding is about a\n * document's shape and not about a pointer into its metadata, so there is no\n * honest pointer to give; meta spells that `(root)`, as it does for its own\n * parse failures. The section the finding is anchored to is already in the\n * message.\n */\nfunction toFieldError(\n finding: LintRun[\"results\"][number][\"findings\"][number],\n): FieldError {\n return {\n schema: RULE_ID_PREFIX,\n instancePath: \"\",\n message:\n (finding.heading != null\n ? `${finding.heading}: ${finding.message}`\n : finding.message) +\n (finding.includedFrom === undefined\n ? \"\"\n : ` (included from ${finding.includedFrom.file}:${String(finding.includedFrom.line)})`),\n keyword: `${STRUCTURE_JOB}/${ruleName(finding.type)}`,\n severity: finding.severity,\n line: finding.position.start.line,\n col: finding.position.start.column,\n // What the template asks for, which meta's writer prints in the\n // `<failure>` body, as pretty, GitHub and SARIF print it under the finding.\n guidance: finding.template ?? null,\n };\n}\n\n/**\n * The files this run actually checked, as meta's results.\n *\n * The skipped ones are **not** here, and that is the one place this reporter\n * parts company with the others. A skip has to be reported, or a file nothing\n * looked at is indistinguishable from a file that passed - so pretty says so\n * in words and SARIF files a `toolExecutionNotification`. JUnit has neither:\n * meta's writer emits a testcase or a testcase with a failure, so a skipped\n * file can only arrive as a green test. That is worse than absent. It claims a\n * pass on evidence nobody gathered, and it puts the suite's `tests` count three\n * above the `2 files checked, 3 skipped` the same run prints.\n *\n * So the count here is the run's `checked`, by construction: one testcase per\n * file that was linted.\n */\nexport function toValidationResults(run: LintRun): ValidationResult[] {\n return run.results\n .filter((result) => result.skipped == null)\n .map((result) => ({\n file: result.file,\n // meta's `format` is the extractor that read the file. A lint result does\n // not carry the parser that produced its tree, and no reporter reached\n // through here reads the field, so it names the domain rather than\n // inventing a format the run never recorded.\n format: \"lint\",\n // meta's invariant, not a count: `ok` is \"no error-severity finding\".\n // Read as \"no findings at all\", a file whose only finding is a warning\n // renders as a `✗` through meta's own pretty reporter - which is a\n // legitimate consumer, since this function is exported - while lint's\n // exit code says the run passed.\n ok: !result.findings.some(isErrorSeverity),\n schemas: [RULE_ID_PREFIX],\n errors: result.findings.map(toFieldError),\n }));\n}\n\n/**\n * Straight to meta's JUnit writer rather than through its `render`, which\n * takes a `RunSummary` its junit branch does not forward. Building one here\n * only to have it dropped read as though the suite's counts came from the run,\n * and they do not: they are the length of the list above and how much of it\n * carries an error-severity finding.\n */\nexport function renderJunit(run: LintRun): string {\n return renderJunitXml(toValidationResults(run), {\n classname: JUNIT_CLASSNAME,\n });\n}\n","/**\n * SARIF 2.1.0, the format GitHub code scanning ingests.\n *\n * `github` annotations live and die with one check run: no history, nothing to\n * query, and nothing outside GitHub Actions reads them at all. SARIF is the\n * same findings as a durable artifact - uploaded once, tracked across commits,\n * and understood by every dashboard that speaks the standard.\n *\n * The format's failure mode is silence. A SARIF file with a malformed URI, or\n * with results whose `ruleId` names no declared rule, uploads successfully and\n * then annotates nothing: a green check and an empty dashboard. So the two\n * things most likely to be wrong are the two things this module is most\n * careful about - rule descriptors, and URIs.\n */\nimport type {\n Finding,\n FindingTemplate,\n Position,\n Severity,\n SkipReason,\n} from \"../types.js\";\nimport type { LintFileResult, LintRun } from \"../commands/lint.js\";\nimport { ruleId, ruleName } from \"../core/rule-id.js\";\nimport { guidanceLines } from \"../../shared/guidance.js\";\nimport pkg from \"../../../package.json\" with { type: \"json\" };\nimport {\n artifactLocation,\n fileUri,\n normalizeRoot,\n URI_BASE_ID,\n type ArtifactLocation,\n} from \"../../shared/sarif-location.js\";\n\nconst SARIF_VERSION = \"2.1.0\";\nconst SARIF_SCHEMA =\n \"https://docs.oasis-open.org/sarif/sarif/v2.1.0/errata01/os/schemas/sarif-schema-2.1.0.json\";\n/**\n * Where code scanning sends someone who clicks \"more information\" on an alert.\n *\n * Deliberately the post-rename URL, which 404s until `doc-structure-lint` is\n * renamed on GitHub - a manual step outside this repo. Pointing it at the\n * current name instead would mean every SARIF report published from the day of\n * the rename onward links somewhere that has moved, and reports outlive the\n * rename; a link that is briefly wrong beats one that is permanently wrong.\n * `package.json`'s `repository` and `bugs` URLs are forward-looking for the\n * same reason, so all three flip together or not at all.\n */\nconst INFORMATION_URI = \"https://github.com/hawkeyexl/manni\";\n\ntype SarifLevel = \"error\" | \"warning\" | \"note\" | \"none\";\n\ninterface SarifMessage {\n text: string;\n}\n\ninterface ReportingDescriptor {\n id: string;\n name: string;\n shortDescription: SarifMessage;\n defaultConfiguration?: { level: SarifLevel };\n}\n\ninterface Region {\n startLine: number;\n startColumn: number;\n endLine: number;\n endColumn: number;\n}\n\ninterface SarifLocation {\n physicalLocation: { artifactLocation: ArtifactLocation; region?: Region };\n}\n\ninterface SarifResult {\n ruleId: string;\n ruleIndex?: number;\n level: SarifLevel;\n message: SarifMessage;\n locations: SarifLocation[];\n /** The file and line included text came from (proposal 0130). */\n relatedLocations?: (SarifLocation & { id: number; message: SarifMessage })[];\n properties?: { heading?: string; template?: FindingTemplate };\n}\n\ninterface SarifNotification {\n descriptor: { id: string; index: number };\n level: SarifLevel;\n message: SarifMessage;\n locations: SarifLocation[];\n}\n\ninterface SarifInvocation {\n executionSuccessful: boolean;\n toolExecutionNotifications?: SarifNotification[];\n}\n\ninterface SarifDriver {\n name: string;\n informationUri: string;\n version: string;\n rules: ReportingDescriptor[];\n notifications?: ReportingDescriptor[];\n}\n\ninterface SarifLog {\n $schema: string;\n version: string;\n runs: {\n tool: { driver: SarifDriver };\n originalUriBaseIds: Record<string, { uri: string }>;\n invocations: SarifInvocation[];\n results: SarifResult[];\n }[];\n}\n\nexport interface SarifOptions {\n /**\n * Directory the relative paths in `LintRun` are relative to - the lint run's\n * `cwd`. Defaults to the process cwd, which is what `runLint` itself\n * defaults to. It is a parameter rather than a bare read of `process.cwd()`\n * so the URI mapping, the part most likely to be silently wrong, is testable\n * without moving the whole process into a fixture directory.\n */\n root?: string;\n}\n\n/**\n * The family scale -> SARIF `level`. A total map rather than a ternary, so a\n * fourth severity fails to compile here instead of quietly becoming `error`.\n *\n * The family's three values were chosen to be GitHub's, and SARIF agrees on\n * two of them; it spells the lowest one `note`. meta's reporter folds\n * `notice` onto `note` the same way, so a repository uploading both tools'\n * reports sees one scale. SARIF's `none` has no `Severity` that means it.\n */\nconst LEVELS: Record<Severity, SarifLevel> = {\n notice: \"note\",\n warning: \"warning\",\n error: \"error\",\n};\n\n/**\n * Why a file went unlinted, in words. `Record<SkipReason, ...>` on purpose: a\n * new skip reason should fail to compile until someone has decided what the\n * report says about it.\n */\nconst SKIP_DESCRIPTIONS: Record<SkipReason, string> = {\n \"no-template\": \"File was not linted: no template resolved for it.\",\n \"unsupported-format\": \"File was not linted: no parser handles its format.\",\n unreadable: \"File was not linted: it could not be read.\",\n excluded: \"File was not linted: the Flare target excludes it by its conditions.\",\n partial: \"File was not linted alone: a page in the run includes it, and it was assessed there.\",\n};\n\n/**\n * Positions map straight across, with no arithmetic.\n *\n * Both sides are 1-based in line and column. Both also treat the end column as\n * exclusive: SARIF defines `endColumn` as \"the column number of the character\n * following the end of the region\", and `Position` in types.ts is documented\n * as a half-open span with `end` exclusive. Checked against what the parser\n * actually emits rather than taken on trust - remark gives `# Hi`, four\n * characters on line 1, an `end.column` of 5, one past the last character,\n * which is precisely SARIF's convention. So no +1 and no -1 in either\n * direction. A zero-width span (`origin()`, used by findings with nowhere\n * better to point) becomes a zero-length region, which SARIF allows.\n */\nfunction region(position: Position): Region {\n return {\n startLine: position.start.line,\n startColumn: position.start.column,\n endLine: position.end.line,\n endColumn: position.end.column,\n };\n}\n\nfunction location(\n file: string,\n root: string,\n position?: Position,\n): SarifLocation {\n return {\n physicalLocation: {\n artifactLocation: artifactLocation(file, root),\n region: position ? region(position) : undefined,\n },\n };\n}\n\n/**\n * The heading goes in the message *and* in `properties`.\n *\n * In the message because most SARIF viewers show the message and nothing else\n * beside the line: \"Expected at least 2 paragraphs, found 1\" is a different\n * sentence depending on which section it is about, and dropping the heading\n * would make the SARIF annotation less informative than the `github` one for\n * the very same finding. In `properties.heading` because a message is prose\n * and nothing can group or filter on it - a consumer asking for \"every finding\n * under Prerequisites\" should not have to parse English back out.\n *\n * Unlike `renderGithub`, newlines are left intact. A workflow command is one\n * line by definition; a SARIF message is a JSON string with no such limit.\n */\nfunction messageText(finding: Finding): string {\n const text =\n finding.heading != null ? `${finding.heading}: ${finding.message}` : finding.message;\n return [text, ...guidanceLines(finding.template)].join(\"\\n\");\n}\n\nfunction words(id: string): string[] {\n return id.split(/[^A-Za-z0-9]+/).filter(Boolean);\n}\n\n/**\n * `missing_section` -> `MissingSection`. SARIF asks a descriptor `name` to be\n * a single Pascal-case identifier, and GitHub shows it in the rule list.\n */\nfunction pascalCase(id: string): string {\n return words(id)\n .map((w) => w.charAt(0).toUpperCase() + w.slice(1))\n .join(\"\");\n}\n\n/**\n * `missing_section` -> `Missing section`. Derived from the id, not authored:\n * there is no rule catalog to draw a real description from, and the first\n * finding's message describes one occurrence rather than the rule. Restating\n * the id in prose says nothing new, but it beats an empty column in GitHub's\n * rule list and it can never drift out of step with the rule it describes.\n */\nfunction humanize(id: string): string {\n const text = words(id).join(\" \");\n return text.charAt(0).toUpperCase() + text.slice(1);\n}\n\ninterface RuleIndex {\n descriptors: ReportingDescriptor[];\n indexOf: Map<string, number>;\n}\n\n/**\n * One `reportingDescriptor` per distinct finding type, in order of first\n * appearance.\n *\n * This is not optional decoration. A result carrying a `ruleId` that matches\n * no descriptor is accepted by GitHub code scanning and then rendered without\n * a rule name, a description, or a working filter - the alert arrives stripped\n * of everything that makes a dashboard usable, and with no error to explain\n * why.\n */\nfunction buildRules(run: LintRun): RuleIndex {\n const indexOf = new Map<string, number>();\n const order: string[] = [];\n const severities = new Map<string, Set<Severity>>();\n\n for (const result of run.results) {\n for (const finding of result.findings) {\n let seen = severities.get(finding.type);\n if (!seen) {\n seen = new Set<Severity>();\n severities.set(finding.type, seen);\n indexOf.set(finding.type, order.length);\n order.push(finding.type);\n }\n seen.add(finding.severity);\n }\n }\n\n const descriptors = order.map((type) => {\n // The descriptor id is the **family** rule id, not the internal `type`:\n // it is what an alert is filed and de-duplicated under, and it has to be\n // the string every other reporter uses for the same finding. `name` and\n // `shortDescription` are derived from the rule half alone, so GitHub's\n // rule list reads \"MissingSection\", not \"ManniLintStructureMissingSection\".\n const rule = ruleName(type);\n const descriptor: ReportingDescriptor = {\n id: ruleId(type),\n name: pascalCase(rule),\n shortDescription: { text: humanize(rule) },\n };\n // Only when every finding of this type agreed on a severity. Severity is\n // per finding, not per rule, so a type that appeared as both an error and\n // a warning has no honest default - and every result states its own\n // `level` regardless, which is what a consumer actually reads.\n const [only, ...rest] = [...(severities.get(type) ?? [])];\n if (only !== undefined && rest.length === 0) {\n descriptor.defaultConfiguration = { level: LEVELS[only] };\n }\n return descriptor;\n });\n\n return { descriptors, indexOf };\n}\n\nfunction propertiesOf(finding: Finding): SarifResult[\"properties\"] {\n const properties: NonNullable<SarifResult[\"properties\"]> = {};\n if (finding.heading != null) properties.heading = finding.heading;\n if (finding.template != null) properties.template = finding.template;\n return Object.keys(properties).length > 0 ? properties : undefined;\n}\n\nfunction toResult(\n finding: Finding,\n file: string,\n rules: RuleIndex,\n root: string,\n): SarifResult {\n return {\n ruleId: ruleId(finding.type),\n // Always populated in practice, since the index is built from these same\n // findings. Omitted rather than faked if it ever is not: a wrong index\n // points the alert at somebody else's rule, which is worse than none.\n ruleIndex: rules.indexOf.get(finding.type),\n level: LEVELS[finding.severity],\n message: { text: messageText(finding) },\n locations: [location(file, root, finding.position)],\n ...(finding.includedFrom === undefined\n ? {}\n : {\n relatedLocations: [\n {\n id: 0,\n ...location(finding.includedFrom.file, root, {\n start: { line: finding.includedFrom.line, column: 1, offset: 0 },\n end: { line: finding.includedFrom.line, column: 1, offset: 0 },\n }),\n message: { text: \"included from here\" },\n },\n ],\n }),\n properties: propertiesOf(finding),\n };\n}\n\ninterface SkipReport {\n descriptors: ReportingDescriptor[];\n notifications: SarifNotification[];\n}\n\n/**\n * Skipped files become `toolExecutionNotifications`, not results.\n *\n * They cannot simply be dropped - the pretty reporter's rule applies here too:\n * a file that leaves no trace in the report is indistinguishable from a file\n * that passed, and a docset mid-onboarding is mostly unrouted pages. Reading\n * that as a clean bill of health is the exact failure this format exists to\n * prevent.\n *\n * They are not results either. A result is a statement about the content of a\n * document; a skip is a statement about the tool, which declined to look. As\n * results they would open code-scanning alerts against files nothing has\n * examined, and each of those would then have to be triaged and dismissed by\n * hand. `toolExecutionNotifications` is the slot SARIF defines for \"the tool\n * has something to say about its own execution\", which is what a skip is.\n *\n * Level `note` rather than SARIF's default of `warning`: on a repository that\n * has not adopted doctypes yet nearly every page is skipped, and a warning\n * stream that long is one nobody reads.\n */\nfunction buildSkips(run: LintRun, root: string): SkipReport {\n const indexOf = new Map<string, number>();\n const descriptors: ReportingDescriptor[] = [];\n const notifications: SarifNotification[] = [];\n\n for (const result of run.results) {\n const reason = result.skipped;\n if (reason == null) continue;\n\n let index = indexOf.get(reason);\n if (index === undefined) {\n index = descriptors.length;\n indexOf.set(reason, index);\n descriptors.push({\n id: reason,\n name: pascalCase(reason),\n shortDescription: { text: SKIP_DESCRIPTIONS[reason] },\n });\n }\n\n notifications.push({\n // Declared in `tool.driver.notifications` and referenced by id *and*\n // index, for the same reason results reference their rules both ways.\n descriptor: { id: reason, index },\n level: \"note\",\n message: { text: skipMessage(result, reason) },\n locations: [location(result.file, root)],\n });\n }\n\n return { descriptors, notifications };\n}\n\n/** The specific reason when the run recorded one, the generic one otherwise. */\nfunction skipMessage(result: LintFileResult, reason: SkipReason): string {\n return result.reason ?? SKIP_DESCRIPTIONS[reason];\n}\n\nexport function renderSarif(run: LintRun, opts: SarifOptions = {}): string {\n const root = normalizeRoot(opts.root ?? process.cwd());\n const rules = buildRules(run);\n const skips = buildSkips(run, root);\n\n const results = run.results.flatMap((result) =>\n result.findings.map((finding) =>\n toResult(finding, result.file, rules, root),\n ),\n );\n\n const driver: SarifDriver = {\n name: \"manni-lint\",\n informationUri: INFORMATION_URI,\n version: pkg.version,\n // Emitted even when empty: results point into this array, so a consumer\n // always looks here, and a stable shape is cheaper than a special case.\n rules: rules.descriptors,\n notifications: skips.descriptors.length > 0 ? skips.descriptors : undefined,\n };\n\n const invocation: SarifInvocation = {\n // Findings are the tool doing its job, not failing at it. This would only\n // be false if manni lint itself could not run, and that path exits 2\n // before any report is rendered.\n executionSuccessful: true,\n toolExecutionNotifications:\n skips.notifications.length > 0 ? skips.notifications : undefined,\n };\n\n const log: SarifLog = {\n $schema: SARIF_SCHEMA,\n version: SARIF_VERSION,\n runs: [\n {\n tool: { driver },\n // Declared unconditionally: it is what makes every relative `uri` in\n // this report mean anything, and a reader should not have to infer the\n // base from whether some result happened to use it.\n originalUriBaseIds: { [URI_BASE_ID]: { uri: fileUri(root) } },\n invocations: [invocation],\n results,\n },\n ],\n };\n\n return JSON.stringify(log, null, 2);\n}\n","/**\n * The alignment block `--explain` prints under each routed file: which rule\n * claimed which section, and why. It is lint's answer to \"why did it say\n * that\" for the matcher in `core/match.ts` - proposal 0061's stress test 3\n * names this as the cost of an alignment matcher over a left-to-right one: a\n * tie is invisible unless something prints the pairing it chose.\n *\n * This module recomputes the alignment itself by calling the matcher's own,\n * already-exported `matchSections` - it does not reach into `align()`'s\n * internal step sequence, which is module-private. That has one visible\n * consequence: this file has no way to know the *document position* a missing\n * rule or an unexpected section falls at relative to the other, so a missing\n * rule is placed among the sections that did match using rule order alone\n * (`insertMissing` below), which is exact whenever - as in every template this\n * repository ships - the missing rule is not sandwiched between two unexpected\n * sections with nothing matched between them. `core/match.ts` is read-only\n * from here; exporting the step sequence, if this ever needs to be exact, is a\n * change to that file rather than to this one.\n *\n * The other thing this module cannot get from an export: which key in a\n * page's frontmatter is its title. It assumes `title`, the same key\n * `manni meta`'s own schemas require, and re-reads `tree.frontmatter`\n * directly rather than asking a caller to resolve it, so the assumption lives\n * in exactly one place.\n *\n * **The seam this depends on.** `commands/lint.ts` parses every file and\n * loads its template before `--explain` returns - both already exist at that\n * point in `lintOne` - but neither is currently attached to the\n * `LintFileResult` it returns. `render()` (`reporters/index.ts`) reads them\n * off a result through `ExplainSource`, structurally: a result carrying\n * `tree` and `template` gets an alignment block, and one that does not is\n * printed exactly as before. Wiring `commands/lint.ts` to attach them is\n * outside this chunk's files (`src/lint/commands/lint.ts` is not among them).\n */\nimport { LintError, type DocumentTree, type SectionNode } from \"../types.js\";\nimport { matchSections, type Match } from \"../core/match.js\";\nimport { occurrenceRange, type Rule, type Template } from \"../core/template.js\";\n\n/** What a caller must attach to a `LintFileResult` for the block to render. */\nexport interface ExplainSource {\n tree: DocumentTree;\n template: Template;\n}\n\n/** One line of the block, before indentation is joined on. */\nexport interface AlignmentRow {\n depth: number;\n text: string;\n}\n\nconst LABEL_WIDTH = 22;\nconst ARROW = \"←\"; // ←\nconst ELLIPSIS = \"…\"; // …\nconst TIMES = \"×\"; // ×\n\nfunction pad(label: string): string {\n return label.length >= LABEL_WIDTH ? `${label} ` : label.padEnd(LABEL_WIDTH + 1);\n}\n\n/** A section's title, quoted, or `(no heading)` for one that has none. */\nfunction titleText(title: string | null): string {\n return title === null ? \"(no heading)\" : `\"${title}\"`;\n}\n\n/**\n * A rule's display name: its `id` where it has one, else a literal string\n * `heading`, else `(any)` for anything else - an array, a `{ pattern }`,\n * `heading: false`, or a bare wildcard. Mirrors the priority `--explain`'s\n * spec states, which is not the same order `missingMessage` in `match.ts`\n * uses for its prose: that picks the heading first because it is read as a\n * sentence, and this picks the id first because it is a column header.\n */\nfunction ruleLabel(rule: Rule): string {\n if (rule.id !== undefined) return rule.id;\n if (typeof rule.heading === \"string\") return rule.heading;\n return \"(any)\";\n}\n\n/**\n * The page's own heading, and the note explaining where it came from.\n *\n * Mirrors `validator.ts`'s private `pageSection`: a lone top-level heading\n * *is* the page. Most of the time that heading is not literal, though - every\n * parser with both frontmatter and headings (`parsers/metadata.ts`'s\n * `withMetadataTitle`) already synthesizes an H1 from `frontmatter.title` when\n * the body has none, positioned on the frontmatter block itself, precisely so\n * a template written against \"the page's title is its outermost rule\" does\n * not have to know the difference. By the time a tree reaches here that\n * difference is gone from the section's own fields - so it is recovered the\n * same way `titlePosition` was set: a synthesized heading's position is\n * `tree.frontmatterPosition`, verbatim.\n *\n * `frontmatter.title` is read directly only as a fallback, for a tree a\n * caller built by some other means - the programmatic API accepts one from\n * anywhere - where no such synthesis ran at all.\n */\nfunction pageHeading(tree: DocumentTree): { text: string | null; note: string | null } {\n const [only] = tree.sections;\n if (tree.sections.length === 1 && only && only.level <= 1) {\n const text = only.title || null;\n if (text === null) return { text: null, note: \"no heading\" };\n const synthesized =\n only.titlePosition !== null &&\n tree.frontmatterPosition !== null &&\n only.titlePosition.start.offset === tree.frontmatterPosition.start.offset &&\n only.titlePosition.end.offset === tree.frontmatterPosition.end.offset;\n return { text, note: synthesized ? \"synthesized from frontmatter\" : null };\n }\n const raw = tree.frontmatter?.[\"title\"];\n const text = typeof raw === \"string\" && raw !== \"\" ? raw : null;\n return { text, note: text === null ? \"no heading\" : \"synthesized from frontmatter\" };\n}\n\n/** The sections a template's `sections:` rules describe - `pageSection`'s subject. */\nfunction pageSections(tree: DocumentTree): SectionNode[] {\n const [only] = tree.sections;\n if (tree.sections.length === 1 && only && only.level <= 1) return only.sections;\n return tree.sections;\n}\n\n/**\n * One matched or collapsed run of matches, rendered as a single row.\n *\n * Both call sites build `run` by pushing one already-known `Match` before\n * ever calling this, so it is never empty; the guard below exists to let the\n * checker see that rather than to handle a real empty-run case.\n */\nfunction matchedRow(depth: number, run: Match[]): AlignmentRow {\n const head = run[0];\n if (!head) return { depth, text: `${pad(\"(empty run)\")}${ARROW} (missing)` };\n const rule = head.rule;\n const first = head.section;\n const last = (run[run.length - 1] ?? head).section;\n const label = run.length === 1 ? ruleLabel(rule) : `${ruleLabel(rule)} ${TIMES}${run.length}`;\n // Coercion can only ever land on a run of length 1: `ALIGNMENT_COSTS.coerce`\n // is open only to a required occurrence whose `max` is 1 (`match.ts`'s\n // header explains why), and a rule with `max: 1` can never contribute a\n // second match to a run.\n const coerced = run.length === 1 && head.coerced ? \" (coerced)\" : \"\";\n const arrow =\n run.length === 1\n ? `${titleText(first.title || null)}${coerced}`\n : `${titleText(first.title || null)} ${ELLIPSIS} ${titleText(last.title || null)}`;\n return { depth, text: `${pad(label)}${ARROW} ${arrow}` };\n}\n\n/**\n * What an absent rule is called.\n *\n * `(missing)` means exactly what produces a `missing_section` finding, so it\n * is reserved for a rule that had to appear. An optional rule that took\n * nothing is `(none)`: absent, and fine. Sharing one word made a page that\n * lints clean print a row saying something was missing from it, which is the\n * opposite of what `--explain` is for.\n */\nfunction absentLabel(rule: Rule): string {\n return occurrenceRange(rule).min > 0 ? \"(missing)\" : \"(none)\";\n}\n\n/** A rule with nothing to show, or a `repeat` group with nothing at all. */\nfunction missingRows(depth: number, rule: Rule): AlignmentRow[] {\n if (!rule.repeat) {\n return [{ depth, text: `${pad(ruleLabel(rule))}${ARROW} ${absentLabel(rule)}` }];\n }\n // A group's members inherit the group's own occurrence: a member of an\n // optional group is not missing when the whole group never ran.\n const label = absentLabel(rule);\n const rows: AlignmentRow[] = [{ depth, text: pad(rule.id ?? \"(repeat)\").trimEnd() }];\n for (const member of rule.repeat) {\n rows.push({ depth: depth + 1, text: `${pad(ruleLabel(member))}${ARROW} ${label}` });\n }\n return rows;\n}\n\n/**\n * Insert `missing`, each tagged with the index of the rule it is about, among\n * `matched` entries tagged the same way (`null` for one that has no rule -\n * an unexpected section). A missing rule never displaces an unexpected\n * section: only a matched entry's index gates it, so an unexpected section is\n * carried along in whichever position document order already put it in.\n */\nfunction insertMissing(\n matched: { index: number | null; rows: AlignmentRow[] }[],\n missing: { index: number; rows: AlignmentRow[] }[],\n): AlignmentRow[] {\n const out: AlignmentRow[] = [];\n let mi = 0;\n for (const entry of matched) {\n while (mi < missing.length) {\n // `mi < missing.length` just guarded this, so `next` is always here;\n // the check only lets the type checker see the invariant the loop\n // bound already established.\n const next = missing[mi];\n if (!next || (entry.index !== null && next.index >= entry.index)) break;\n out.push(...next.rows);\n mi++;\n }\n out.push(...entry.rows);\n }\n while (mi < missing.length) {\n const next = missing[mi];\n if (!next) break;\n out.push(...next.rows);\n mi++;\n }\n return out;\n}\n\n/**\n * One level: `rules` against `sections`, and every matched pair's own\n * subsections.\n *\n * A `repeat` member's `Match.rule` is the member itself, never the group\n * (`match.ts`'s `compile` only ever assigns an occurrence to a leaf rule), so\n * a group is never a key in `matches`. `rootOf` recovers \"which top-level\n * rule is this a member of\" - itself, for a rule with no group - which is\n * what lets a group be judged matched or missing as one thing while still\n * naming which of its members carried the section.\n */\nfunction alignLevel(\n rules: Rule[] | undefined,\n sections: SectionNode[],\n parent: SectionNode | null,\n depth: number,\n): AlignmentRow[] {\n // `undefined` is the template saying nothing about this level - silence,\n // not \"no sections allowed\" - so there is nothing to align and nothing to\n // print. `matchSections` draws the same line; this mirrors it rather than\n // passing `[]` through, which would turn silence into every section here\n // reading as unexpected.\n if (rules === undefined) return [];\n\n const { matches } = matchSections(sections, rules, { parent });\n const ruleIndex = new Map<Rule, number>(rules.map((r, i) => [r, i]));\n const rootOf = new Map<Rule, Rule>();\n for (const rule of rules) {\n if (rule.repeat) for (const member of rule.repeat) rootOf.set(member, rule);\n else rootOf.set(rule, rule);\n }\n const rootOfRule = (rule: Rule): Rule => rootOf.get(rule) ?? rule;\n const matchedRoots = new Set(matches.map((m) => rootOfRule(m.rule)));\n const bySection = new Map<SectionNode, Match>(matches.map((m) => [m.section, m]));\n\n const matched: { index: number | null; rows: AlignmentRow[] }[] = [];\n let i = 0;\n while (i < sections.length) {\n // `i < sections.length` just guarded this; `section` always exists.\n const section = sections[i];\n if (!section) break;\n const match = bySection.get(section);\n if (!match) {\n matched.push({\n index: null,\n rows: [{ depth, text: `(unexpected) ${titleText(section.title || null)}` }],\n });\n i++;\n continue;\n }\n\n const root = rootOfRule(match.rule);\n if (root.repeat) {\n // Every section, in this run, that belongs to this same group - by\n // whichever member took it, not necessarily the same one twice.\n const taken: Match[] = [];\n while (i < sections.length) {\n const here = sections[i];\n if (!here) break;\n const next = bySection.get(here);\n if (!next || rootOfRule(next.rule) !== root) break;\n taken.push(next);\n i++;\n }\n const rows: AlignmentRow[] = [{ depth, text: pad(root.id ?? \"(repeat)\").trimEnd() }];\n let run: Match[] = [];\n const flushMember = (): void => {\n if (run.length === 0) return;\n rows.push(matchedRow(depth + 1, run));\n for (const m of run) {\n rows.push(...alignLevel(m.rule.sections, m.section.sections, m.section, depth + 2));\n }\n run = [];\n };\n for (const m of taken) {\n const first = run[0];\n if (first && first.rule !== m.rule) flushMember();\n run.push(m);\n }\n flushMember();\n // A member this occurrence never reached prints missing beside the\n // members it did, the same information `missingRows` gives a group with\n // nothing at all.\n const takenMembers = new Set(taken.map((m) => m.rule));\n for (const member of root.repeat) {\n if (takenMembers.has(member)) continue;\n rows.push({ depth: depth + 1, text: `${pad(ruleLabel(member))}${ARROW} (missing)` });\n }\n matched.push({ index: ruleIndex.get(root) ?? null, rows });\n continue;\n }\n\n // A plain rule: gather the run of consecutive sections it claimed.\n const run: Match[] = [match];\n i++;\n while (i < sections.length) {\n const here = sections[i];\n if (!here) break;\n const next = bySection.get(here);\n if (!next || next.rule !== match.rule) break;\n run.push(next);\n i++;\n }\n const rows = [matchedRow(depth, run)];\n for (const m of run) {\n rows.push(...alignLevel(m.rule.sections, m.section.sections, m.section, depth + 1));\n }\n matched.push({ index: ruleIndex.get(match.rule) ?? null, rows });\n }\n\n const missing = rules\n .filter((rule) => !matchedRoots.has(rule))\n .map((rule) => {\n const index = ruleIndex.get(rule);\n if (index === undefined) {\n // `ruleIndex` is built from this exact `rules` array above, so every\n // rule reached here (it came from filtering `rules` itself) has an\n // entry; this is unreachable.\n //\n // `LintError` rather than `Error` even so. Everything this tool throws\n // is caught by the bin runner and exits 2, an operational error; a bare\n // `Error` would escape that and exit 1, which means \"the documents have\n // findings\". An internal fault must never be reported as a lint result.\n throw new LintError(\"alignLevel: rule missing from its own index\");\n }\n return { index, rows: missingRows(depth, rule) };\n });\n\n return insertMissing(matched, missing);\n}\n\n/** The full alignment block for one file: the page row, then its sections. */\nexport function explainAlignment(tree: DocumentTree, template: Template): AlignmentRow[] {\n const heading = pageHeading(tree);\n const arrow =\n heading.text !== null\n ? `${titleText(heading.text)}${heading.note ? ` (${heading.note})` : \"\"}`\n : `(${heading.note ?? \"no heading\"})`;\n const rows: AlignmentRow[] = [{ depth: 0, text: `${pad(\"(page)\")}${ARROW} ${arrow}` }];\n rows.push(...alignLevel(template.sections, pageSections(tree), null, 1));\n return rows;\n}\n\n/** `AlignmentRow[]` as the indented text `renderExplain` prints, two spaces per depth. */\nexport function formatAlignment(rows: AlignmentRow[]): string[] {\n return rows.map((row) => `${\" \".repeat(row.depth)}${row.text}`);\n}\n","/**\n * Reporters render a run to a string. The CLI writes the result to stdout;\n * diagnostics go to stderr separately, so a report is never interleaved with\n * anything a consumer has to parse around.\n */\nimport { LintError, type Finding } from \"../types.js\";\nimport type { LintFileResult, LintRun } from \"../commands/lint.js\";\nimport type { FormatInfo, ToolInfo } from \"../commands/tools.js\";\nimport type { TemplateInfo, TemplatesInfo } from \"../commands/templates.js\";\nimport { palette, type Colors } from \"../../shared/color.js\";\nimport {\n escapeWorkflowCommandMessage,\n escapeWorkflowCommandProperty,\n} from \"../../shared/github.js\";\nimport type { ReportFormat as FamilyFormat } from \"../../meta/index.js\";\nimport { REPORT_FORMAT_LIST } from \"../../meta/internal.js\";\nimport { ruleId, TOOL_NAME } from \"../core/rule-id.js\";\nimport { renderJunit } from \"./junit.js\";\nimport { renderSarif } from \"./sarif.js\";\nimport { guidanceLines } from \"../../shared/guidance.js\";\nimport { explainAlignment, formatAlignment, type ExplainSource } from \"./alignment.js\";\n\nexport { renderJunit, toValidationResults } from \"./junit.js\";\n\n/**\n * Every `-f` value, plus `--explain`.\n *\n * The findings formats are the family's, taken from meta rather than restated,\n * so a format added there is available here the moment lint's `render` grows a\n * case for it - and a value lint does not handle is a compile error instead of\n * a silent fall-through to pretty. `explain` is lint's own: it is reachable\n * through `--explain` and never through `-f`, because it reports on\n * configuration rather than on documents.\n */\nexport type ReportFormat = FamilyFormat | \"explain\";\n\n/** Listing commands have nothing to annotate, so they offer no `github`. */\nexport type ListFormat = \"pretty\" | \"json\";\n\nexport interface ReportOptions {\n color?: boolean;\n /**\n * Directory the run's relative paths are relative to, forwarded to the SARIF\n * reporter and ignored by the others. Defaults to the process cwd, which is\n * right for the CLI because `runLint` defaults its `cwd` the same way.\n *\n * It is here rather than only on `renderSarif` because `render` is the entry\n * point a library caller reaches for, and without it that caller was pinned\n * to the process cwd with no way out short of bypassing `render` entirely -\n * for the one reporter whose whole output is paths.\n */\n root?: string;\n}\n\nfunction plural(n: number, word: string): string {\n return `${n} ${word}${n === 1 ? \"\" : \"s\"}`;\n}\n\n/** `line:column` of a finding, the anchor an editor can jump to. */\nfunction locate(finding: Finding): string {\n return `${finding.position.start.line}:${finding.position.start.column}`;\n}\n\n/** A finding as prose: the heading it is about, then what is wrong with it. */\nfunction describeFinding(finding: Finding): string {\n return finding.heading != null\n ? `${finding.heading}: ${finding.message}`\n : finding.message;\n}\n\n/**\n * Where included text came from (proposal 0130), or \"\" for the page's own.\n * The finding sits at the directive, and this names the file to edit.\n */\nfunction includedSuffix(finding: Finding): string {\n const from = finding.includedFrom;\n return from === undefined ? \"\" : `(included from ${from.file}:${String(from.line)})`;\n}\n\n/**\n * A finding's level prefix, meta's shape: nothing for an error, since the\n * `✗`/`✓` mark already says that; the word itself, coloured, for anything\n * milder. Keeps a passing file's warning from reading as just another\n * anonymous line once it is printed beside real errors on a failing one.\n */\nfunction levelPrefix(c: Colors, severity: Finding[\"severity\"]): string {\n if (severity === \"error\") return \"\";\n return `${severity === \"notice\" ? c.dim(\"notice\") : c.yellow(\"warning\")} `;\n}\n\nexport function renderPretty(run: LintRun, opts: ReportOptions = {}): string {\n const c = palette(opts.color ?? false);\n const lines: string[] = [];\n let warnings = 0;\n let notices = 0;\n\n for (const result of run.results) {\n // A skip is reported, never silently dropped: an unreadable format that\n // leaves no trace is indistinguishable from a file that passed.\n // A partial is assessed through its includer, and the summary counts it.\n if (result.skipped === \"partial\") continue;\n if (result.skipped != null) {\n const why = result.reason ?? result.skipped;\n lines.push(`${c.yellow(\"-\")} ${result.file} ${c.dim(`skipped: ${why}`)}`);\n continue;\n }\n if (result.success && result.findings.length === 0) {\n lines.push(`${c.green(\"✓\")} ${result.file}`);\n continue;\n }\n // `success` means \"no error-severity finding\", not \"no findings\" - a\n // passing file can still hold a warning, such as\n // `unsupported_content_kind`. Reusing `✓` for it would hide the warning\n // behind the same glyph a clean file gets; reusing `✗` would fail a file\n // nothing actually failed. `⚠` (meta's and cite's mark for the same case)\n // says \"passing, but read this\" without claiming either extreme.\n const mark = result.success ? c.yellow(\"⚠\") : c.red(\"✗\");\n lines.push(`${mark} ${result.file}`);\n for (const finding of result.findings) {\n // Counted apart, because they are not the same thing to a reader. Every\n // structure finding used to be an `error` or the occasional `warning`,\n // so \"not an error\" and \"a warning\" were the same set. DITA-OT reports an\n // undefined key reference at `notice`, and calling that a warning on the\n // summary line overstates it.\n if (finding.severity === \"warning\") warnings++;\n else if (finding.severity === \"notice\") notices++;\n // The namespaced id rather than the bare `type`: it is what SARIF,\n // JUnit and the GitHub annotation file the finding under, so the string\n // a reader copies out of the terminal is the one they can search for.\n lines.push(\n ` ${c.dim(locate(finding))} ${c.cyan(ruleId(finding.type))} ` +\n `${levelPrefix(c, finding.severity)}${describeFinding(finding)}`,\n );\n // What the template asks for, under the rule id it explains.\n const indent = \" \".repeat(6 + locate(finding).length);\n const included = includedSuffix(finding);\n if (included !== \"\") lines.push(`${indent}${c.dim(included)}`);\n for (const line of guidanceLines(finding.template)) lines.push(`${indent}${c.dim(line)}`);\n }\n }\n\n const { checked, passed, failed, skipped, partials = 0 } = run.summary;\n // Named only when there are any, as meta and cite do: every run against a\n // format that reports every content kind has none.\n const warningsText = warnings > 0 ? `, ${plural(warnings, \"warning\")}` : \"\";\n const noticesText = notices > 0 ? `, ${plural(notices, \"notice\")}` : \"\";\n const partialsText =\n partials > 0\n ? `, ${partials === 1 ? \"1 partial assessed through its includer\" : `${String(partials)} partials assessed through their includers`}`\n : \"\";\n const summary = `${plural(checked, \"file\")} checked, ${passed} passed, ${failed} failed, ${skipped} skipped${partialsText}${warningsText}${noticesText}`;\n if (lines.length > 0) lines.push(\"\");\n lines.push(failed > 0 ? c.red(summary) : c.green(summary));\n return lines.join(\"\\n\");\n}\n\n/**\n * The published JSON shape, and the reason this builds objects by hand rather\n * than stringifying `run.results` directly.\n *\n * manni docevals reads `[{ file, success, errors: [{ type, heading, message,\n * position: { start: { line, column } } }] }]` off stdout, and it parses\n * rather than validates - a renamed key produces zero findings, not an error.\n * So: a bare array at the top level, and `errors`, even though the internal\n * field is `findings`. Adding keys is safe; renaming or nesting is not.\n */\nexport function renderJson(run: LintRun): string {\n const results = run.results.map((result) => ({\n file: result.file,\n success: result.success,\n errors: result.findings.map((finding) => ({\n type: finding.type,\n // Additive, and deliberately beside `type` rather than instead of it.\n // `ruleId` is the family id every other reporter files this finding\n // under; `tool` names which tool produced it, the question a second\n // lint job makes worth asking.\n ruleId: ruleId(finding.type),\n tool: TOOL_NAME,\n heading: finding.heading,\n message: finding.message,\n position: finding.position,\n // Additive too, and the reason it has to be: `success: true` beside a\n // non-empty `errors` array is exactly what a warning-only file looks\n // like now that `success` means \"no error-severity finding\" rather than\n // \"no findings\". Without this key a consumer has no way to tell that\n // apart from an error the JSON shape simply forgot to fail on.\n severity: finding.severity,\n // Additive: the template that judged the page and the rule this finding\n // is about, or null when no template stands behind it.\n template: finding.template ?? null,\n // Additive: the file and line included text came from (proposal 0130).\n // Absent for the page's own text, where `position` already says it.\n ...(finding.includedFrom === undefined ? {} : { includedFrom: finding.includedFrom }),\n })),\n // Additive, and the one thing this shape could not say. A skipped file is\n // `{success: false, errors: []}`, which is also what a failure whose\n // finding vanished looks like - so a consumer counting failures counted a\n // file nothing read as a file that was read and found wanting. Null rather\n // than absent, because a key that comes and goes makes \"not skipped\" and\n // \"an older manni\" the same observation. The prose `reason` stays off the\n // wire; it is a diagnostic for the pretty and SARIF reports.\n skipped: result.skipped ?? null,\n }));\n return JSON.stringify(results, null, 2);\n}\n\n/**\n * GitHub workflow commands: one annotation per finding, shaped as cite's are -\n * `::<severity> file=…,line=…,col=…,title=<ruleId>::<message>`.\n *\n * The rule id is a `title=` property rather than a `[type]` prefix inside the\n * message. GitHub renders the title as the alert's own heading, so the prefix\n * spelled the rule's name a second time; and `title` is the field a reader can\n * group and filter on, which prose can never be.\n *\n * The level is the severity, not a constant `error`. The family scale was\n * chosen to be GitHub's for exactly this: `::warning` and `::notice` render\n * inline like `::error` but do not fail the check, which is the severity\n * invariant in GitHub's terms, and it is load-bearing rather than theoretical:\n * `unsupported_content_kind` is a `warning`, so it annotates the file without\n * failing the job.\n *\n * Line breaks are escaped rather than collapsed to spaces, as this once did.\n * `%0A` is the format's own answer and GitHub renders it as a multi-line\n * annotation, so the message arrives whole; collapsing threw away the author's\n * line breaks to solve a problem the escape already solves, and its `\\r?\\n`\n * pattern let a bare carriage return through into the command untouched.\n *\n * The escaping itself is the family's, from `src/shared/github.ts`. It lives\n * there precisely so a second renderer cannot re-derive it: the replacements\n * are order-dependent (`%` first, or the escape sequences get escaped again),\n * and a local copy that got the order wrong would look identical in review and\n * only show itself on a message carrying a literal `%`.\n */\nexport function renderGithub(run: LintRun): string {\n const lines: string[] = [];\n for (const result of run.results) {\n for (const finding of result.findings) {\n const params = [\n `file=${escapeWorkflowCommandProperty(result.file)}`,\n `line=${finding.position.start.line}`,\n `col=${finding.position.start.column}`,\n `title=${escapeWorkflowCommandProperty(ruleId(finding.type))}`,\n ];\n const included = includedSuffix(finding);\n const message = escapeWorkflowCommandMessage(\n [\n included === \"\" ? describeFinding(finding) : `${describeFinding(finding)} ${included}`,\n ...guidanceLines(finding.template),\n ].join(\"\\n\"),\n );\n lines.push(`::${finding.severity} ${params.join(\",\")}::${message}`);\n }\n }\n return lines.join(\"\\n\");\n}\n\n/**\n * `--explain`: the resolution chain per file, rather than findings.\n *\n * Printing every stage, including the ones that had nothing to say, is the\n * point. \"Which template linted this page?\" is usually asked because the answer\n * was surprising, and the surprising part is almost always a stage the reader\n * forgot applies - a stray `$template`, an override glob matching more than\n * intended. A report that showed only the winning stage would hide exactly the\n * thing being looked for.\n */\n/**\n * The alignment block riding on a result. `commands/lint.ts` attaches the tree\n * and the loaded template under `alignment` when `--explain` asked for them,\n * and only for a file that routed; a result without it prints as it always did.\n *\n * It is a nested key rather than two flat ones because `template` at the top\n * level is already the template's *ref*, the string the routing line shows.\n */\nfunction alignmentFor(result: LintFileResult): string[] | null {\n const source: ExplainSource | undefined = result.alignment;\n if (!source) return null;\n return formatAlignment(explainAlignment(source.tree, source.template));\n}\n\nexport function renderExplain(run: LintRun, opts: ReportOptions = {}): string {\n const c = palette(opts.color ?? false);\n const lines: string[] = [];\n\n for (const result of run.results) {\n // Not the pass/fail glyphs: `--explain` reports whether a page was routed,\n // and a routed page may still be full of findings. Reusing the tick would\n // read as a clean bill of health for a document nothing has looked at yet.\n const chosen = result.template;\n lines.push(`${chosen ? c.cyan(\"▸\") : c.dim(\"-\")} ${c.bold(result.file)}`);\n\n // What a Flare topic resolved against, ahead of the routing it fed.\n if (result.flare !== undefined) {\n const { project, target } = result.flare;\n const detail =\n target === undefined\n ? `${project}, no target`\n : `${project}, target ${target.name} (${target.from})`;\n lines.push(` ${c.dim(\"·\")} ${\"flare\".padEnd(20)} ${c.dim(detail)}`);\n }\n\n const steps = result.resolution?.steps ?? [];\n if (steps.length === 0) {\n lines.push(` ${c.dim(\"(no resolution recorded)\")}`);\n }\n for (const step of steps) {\n const mark = step.ref ? c.green(\"→\") : c.dim(\"·\");\n const label = step.ref ? c.bold(step.ref) : c.dim(step.detail);\n const suffix = step.ref ? ` ${c.dim(step.detail)}` : \"\";\n lines.push(` ${mark} ${step.stage.padEnd(20)} ${label}${suffix}`);\n }\n\n const alignment = chosen ? alignmentFor(result) : null;\n if (alignment && alignment.length > 0) {\n lines.push(` ${c.dim(\"alignment\")}`);\n for (const row of alignment) lines.push(` ${row}`);\n }\n\n const cause = result.resolution?.cause;\n if (cause === \"unknown-type\") {\n const type = result.resolution?.unknownType ?? \"(none recorded)\";\n const near = result.resolution?.suggestions ?? [];\n const known = result.resolution?.knownTypes ?? [];\n // The same fallback the pretty reporter gives. Without it a typo with no\n // near miss - which is most of them, since a near miss needs the typo to\n // be close - printed the failure and nothing to act on, while the plain\n // lint output for that page listed every doctype available.\n const hint = near.length\n ? `; did you mean ${near.join(\", \")}?`\n : known.length\n ? `; known doctypes: ${known.join(\", \")}`\n : \"\";\n lines.push(` ${c.red(\"✗\")} no template serves type \"${type}\"${hint}`);\n } else if (result.skipped === \"excluded\") {\n lines.push(` ${c.dim(`skipped: ${result.reason ?? \"excluded\"}`)}`);\n } else if (cause === \"no-type\") {\n lines.push(` ${c.dim(\"skipped: the page declares no type\")}`);\n }\n lines.push(\"\");\n }\n\n const routed = run.results.filter((r) => r.template != null).length;\n lines.push(\n `${run.results.length} file${run.results.length === 1 ? \"\" : \"s\"}, ` +\n `${routed} routed, ${run.results.length - routed} unrouted`,\n );\n return lines.join(\"\\n\");\n}\n\nexport function render(\n run: LintRun,\n format: ReportFormat,\n opts: ReportOptions = {},\n): string {\n switch (format) {\n case \"json\":\n return renderJson(run);\n case \"github\":\n return renderGithub(run);\n case \"sarif\":\n return renderSarif(run, opts.root === undefined ? {} : { root: opts.root });\n case \"junit\":\n return renderJunit(run);\n case \"explain\":\n return renderExplain(run, opts);\n case \"pretty\":\n return renderPretty(run, opts);\n default: {\n // Exhaustive, and the guard is what makes the claim true: sharing an arm\n // with `pretty` narrowed nothing, so a format added to meta's\n // `REPORT_FORMATS` - which is what the CLI validates `-f` against - was\n // accepted here and silently rendered as a human report. Now it is a\n // compile error, and this is its runtime half for library callers.\n const unreachable: never = format;\n throw new LintError(\n `Unknown report format ${JSON.stringify(unreachable)}. Use ${REPORT_FORMAT_LIST}.`,\n );\n }\n }\n}\n\n/** One template per line: the ref to pass, its title, and the types it serves. */\nfunction templateLine(c: Colors, entry: TemplateInfo): string {\n const title = entry.title !== \"\" ? ` ${c.dim(\"—\")} ${entry.title}` : \"\";\n const types =\n entry.types.length > 0 ? entry.types.join(\", \") : \"(no types declared)\";\n return ` ${c.cyan(entry.id)}${title} ${c.dim(`types: ${types}`)} ${c.dim(`[${entry.source}]`)}`;\n}\n\nexport function renderTemplates(\n info: TemplatesInfo,\n format: ListFormat,\n opts: ReportOptions = {},\n): string {\n if (format === \"json\") return JSON.stringify(info, null, 2);\n\n const c = palette(opts.color ?? false);\n const lines: string[] = [c.bold(\"Templates:\")];\n if (info.templates.length === 0) {\n lines.push(c.dim(\" (none)\"));\n } else {\n for (const entry of info.templates) lines.push(templateLine(c, entry));\n }\n return lines.join(\"\\n\");\n}\n\n/**\n * One input format as `markdown Markdown (.md, .markdown) kinds: paragraph,\n * codeBlock, list`.\n *\n * The kinds are left out entirely when there are none, rather than printed as\n * an empty list. A tool outside the package answers the job without parsing\n * into the content model, so it has no kinds to report, and a bare `kinds:`\n * label reads as a rendering fault rather than as the answer.\n */\nfunction formatLine(c: Colors, entry: FormatInfo): string {\n const head = ` ${c.cyan(entry.name)} ${entry.label} (${entry.extensions.join(\", \")})`;\n if (entry.kinds.length === 0) return head;\n return `${head} ${c.dim(`kinds: ${entry.kinds.join(\", \")}`)}`;\n}\n\n/**\n * `manni lint tools`: one block per job. Every column is printed for every\n * job, the negatives included - \"not configured\" beside a job that still runs\n * on defaults is the answer someone ran this command to get.\n */\nexport function renderTools(\n tools: ToolInfo[],\n format: ListFormat,\n opts: ReportOptions = {},\n): string {\n if (format === \"json\") return JSON.stringify(tools, null, 2);\n\n const c = palette(opts.color ?? false);\n const lines: string[] = [c.bold(\"Jobs:\")];\n for (const entry of tools) {\n const state = [\n entry.configured ? \"configured\" : \"not configured\",\n entry.available ? \"available\" : \"unavailable\",\n ].join(\", \");\n // A tool that is not here has no version to report, and the row still\n // prints: \"unavailable\" beside a blank cell reads as a rendering fault\n // rather than as the answer. The dash is a cell standing in for a missing\n // value, which is why it is an em dash in a house style that bans them in\n // prose.\n const version = entry.version ?? \"—\";\n lines.push(\n ` ${c.cyan(entry.job)} tool: ${c.bold(entry.tool)} ${version} [${state}]`,\n );\n lines.push(` config: ${c.dim(entry.config)}`);\n lines.push(` ${c.dim(\"formats:\")}`);\n for (const info of entry.formats) lines.push(formatLine(c, info));\n }\n return lines.join(\"\\n\");\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA0BO,IAAM,iBAAiB;AAGvB,IAAM,YAAY;AAGlB,IAAM,gBAAyB;AAQ/B,SAAS,SAAS,MAAsB;AAC7C,SAAO,KAAK,QAAQ,WAAW,EAAE,EAAE,QAAQ,MAAM,GAAG;AACtD;AAGO,SAAS,OAAO,MAAc,MAAe,eAAuB;AACzE,SAAO,GAAG,cAAc,IAAI,GAAG,IAAI,SAAS,IAAI,CAAC;AACnD;;;ACpBA,IAAM,kBAAkB;AAmBxB,SAAS,aACP,SACY;AACZ,SAAO;AAAA,IACL,QAAQ;AAAA,IACR,cAAc;AAAA,IACd,UACG,QAAQ,WAAW,OAChB,GAAG,QAAQ,OAAO,KAAK,QAAQ,OAAO,KACtC,QAAQ,YACX,QAAQ,iBAAiB,SACtB,KACA,mBAAmB,QAAQ,aAAa,IAAI,IAAI,OAAO,QAAQ,aAAa,IAAI,CAAC;AAAA,IACvF,SAAS,GAAG,aAAa,IAAI,SAAS,QAAQ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QAAO;AACrC,SAAO,GAAG,IAAI,KAAK,EAAE,IAAI,UAAU,MAAM,MAAM,KAAK,IAAI,CAAC,EAAE,CAAC;AAC9D;AAOO,SAAS,YACd,OACA,QACA,OAAsB,CAAC,GACf;AACR,MAAI,WAAW,OAAQ,QAAO,KAAK,UAAU,OAAO,MAAM,CAAC;AAE3D,QAAM,IAAI,QAAQ,KAAK,SAAS,KAAK;AACrC,QAAM,QAAkB,CAAC,EAAE,KAAK,OAAO,CAAC;AACxC,aAAW,SAAS,OAAO;AACzB,UAAM,QAAQ;AAAA,MACZ,MAAM,aAAa,eAAe;AAAA,MAClC,MAAM,YAAY,cAAc;AAAA,IAClC,EAAE,KAAK,IAAI;AAMX,UAAM,UAAU,MAAM,WAAW;AACjC,UAAM;AAAA,MACJ,KAAK,EAAE,KAAK,MAAM,GAAG,CAAC,WAAW,EAAE,KAAK,MAAM,IAAI,CAAC,IAAI,OAAO,MAAM,KAAK;AAAA,IAC3E;AACA,UAAM,KAAK,eAAe,EAAE,IAAI,MAAM,MAAM,CAAC,EAAE;AAC/C,UAAM,KAAK,OAAO,EAAE,IAAI,UAAU,CAAC,EAAE;AACrC,eAAW,QAAQ,MAAM,QAAS,OAAM,KAAK,WAAW,GAAG,IAAI,CAAC;AAAA,EAClE;AACA,SAAO,MAAM,KAAK,IAAI;AACxB;","names":["renderJunit","text","i","rows","run","renderJunit"]}
@@ -23,7 +23,7 @@ import {
23
23
  updateConfigEval,
24
24
  updateManifestEval,
25
25
  updatePageEval
26
- } from "./chunk-3NGA6KCU.js";
26
+ } from "./chunk-X7UWDGQQ.js";
27
27
  import {
28
28
  DEFAULT_CONFIG_FILENAME,
29
29
  assertRegisteredGraders,
@@ -45,23 +45,23 @@ import {
45
45
  splitBody,
46
46
  withExternalMetadata,
47
47
  withTemplateEvals
48
- } from "./chunk-4ZKEJPRY.js";
48
+ } from "./chunk-DOXZ3U4O.js";
49
49
  import {
50
50
  isTurnBudgetSkip
51
51
  } from "./chunk-XG6PVB5S.js";
52
52
  import {
53
53
  SUMMARY_FORMATS,
54
54
  parseFormat
55
- } from "./chunk-Z3YNYZR2.js";
55
+ } from "./chunk-VXZ2CIH7.js";
56
56
  import {
57
57
  DocevalsError
58
- } from "./chunk-OZH46DBT.js";
58
+ } from "./chunk-7OMLNFP7.js";
59
59
  import {
60
60
  mergeMetaProvenance
61
- } from "./chunk-PVAJUMDT.js";
61
+ } from "./chunk-672TCM2Q.js";
62
62
  import {
63
63
  notFoundMessage
64
- } from "./chunk-D6HTXNFN.js";
64
+ } from "./chunk-2NB7MT5I.js";
65
65
  import {
66
66
  SEVERITIES
67
67
  } from "./chunk-77AINBYM.js";
@@ -1326,4 +1326,4 @@ export {
1326
1326
  renderCalibration,
1327
1327
  runInit
1328
1328
  };
1329
- //# sourceMappingURL=chunk-ZWE73OJR.js.map
1329
+ //# sourceMappingURL=chunk-KWK6VVK2.js.map
@@ -13,7 +13,7 @@ import {
13
13
  resolveVariant,
14
14
  traverse,
15
15
  withholds
16
- } from "./chunk-FRAEC2Y4.js";
16
+ } from "./chunk-BKLXSWGX.js";
17
17
  import {
18
18
  CONFIGURED_EVALS_LEFT_OUT,
19
19
  COPIED_SHARE,
@@ -26,17 +26,17 @@ import {
26
26
  readSampleQuestions,
27
27
  userFacing,
28
28
  withExternalMetadata
29
- } from "./chunk-4AWM6625.js";
29
+ } from "./chunk-AXIYZIHN.js";
30
30
  import {
31
31
  LOCALIZATIONS_FILENAME,
32
32
  UNDETERMINED,
33
33
  canonicalLanguageTag,
34
34
  isLanguageTag,
35
35
  parseLocalizations
36
- } from "./chunk-OY7AMSDK.js";
36
+ } from "./chunk-M5HDMQCI.js";
37
37
  import {
38
38
  runCheck
39
- } from "./chunk-KZK5JOET.js";
39
+ } from "./chunk-INDMEKFB.js";
40
40
  import {
41
41
  packageRoot
42
42
  } from "./chunk-TIUTIOFB.js";
@@ -61,14 +61,14 @@ import {
61
61
  profileFor,
62
62
  routesFrom,
63
63
  withPrefix
64
- } from "./chunk-YBDRFSOK.js";
64
+ } from "./chunk-AXSCHC34.js";
65
65
  import {
66
66
  plainText
67
- } from "./chunk-7SYTA2HW.js";
67
+ } from "./chunk-3WX73ME2.js";
68
68
  import {
69
69
  readRecord,
70
70
  runDerive
71
- } from "./chunk-PVAJUMDT.js";
71
+ } from "./chunk-672TCM2Q.js";
72
72
  import {
73
73
  bodyLineOf,
74
74
  findWindows,
@@ -76,13 +76,13 @@ import {
76
76
  spellLines,
77
77
  splitLines,
78
78
  toFileLines
79
- } from "./chunk-SXWPKK4D.js";
79
+ } from "./chunk-ZGLLJSL7.js";
80
80
  import {
81
81
  integrityOf,
82
82
  isFlare,
83
83
  locateFrontmatter,
84
84
  supportedExtensions
85
- } from "./chunk-D6HTXNFN.js";
85
+ } from "./chunk-2NB7MT5I.js";
86
86
  import {
87
87
  warn
88
88
  } from "./chunk-HX44GB4Z.js";
@@ -2761,4 +2761,4 @@ export {
2761
2761
  shapeText,
2762
2762
  validateGraph
2763
2763
  };
2764
- //# sourceMappingURL=chunk-IPET4C6M.js.map
2764
+ //# sourceMappingURL=chunk-LU6HSA2N.js.map
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  import {
3
3
  byCodeUnit
4
- } from "./chunk-YBDRFSOK.js";
4
+ } from "./chunk-AXSCHC34.js";
5
5
 
6
6
  // src/graph/core/localizations.ts
7
7
  var LOCALIZATIONS_FILENAME = "localizations.json";
@@ -97,4 +97,4 @@ export {
97
97
  parseLocalizations,
98
98
  isSafeRelativePath
99
99
  };
100
- //# sourceMappingURL=chunk-OY7AMSDK.js.map
100
+ //# sourceMappingURL=chunk-M5HDMQCI.js.map
@@ -14,4 +14,4 @@ var LintError = class extends ToolError {
14
14
  export {
15
15
  LintError
16
16
  };
17
- //# sourceMappingURL=chunk-OPF3NOKF.js.map
17
+ //# sourceMappingURL=chunk-M77SIRUX.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../src/lint/types.ts"],"sourcesContent":["/**\n * The contract every other module is written against.\n *\n * Two shapes matter. `DocumentTree` is what a parser owes the rest of the tool:\n * a nested section tree with real source positions, in a vocabulary that has\n * nothing to do with Markdown. `Finding` is what the tool owes its caller.\n * Everything between the two - matching, rules, reporting - touches neither\n * mdast nor Asciidoctor nor parse5, which is what lets a new input format be\n * one file plus a line in the parser registry.\n */\n\nimport { ToolError } from \"../shared/errors.js\";\nimport type { Severity } from \"../shared/severity.js\";\nimport type { Guidance } from \"../shared/guidance.js\";\nimport type { FlareRun } from \"../shared/flare/index.js\";\n\n/**\n * Operational/usage failure. Exits 2; never used for lint findings.\n *\n * Extends the umbrella's `ToolError`, which is what the shared bin runner\n * matches on; the subclass stays so this tool's tests and library callers can\n * match on it by name. Named for its domain, as `A11yError`, `CiteError` and\n * `KeyError` are.\n */\nexport class LintError extends ToolError {\n constructor(message: string) {\n super(message);\n this.name = \"LintError\";\n }\n}\n\n/** A point in a source file. Line and column are 1-based, offset 0-based. */\nexport interface Point {\n line: number;\n column: number;\n offset: number;\n}\n\n/** A half-open source span, `start` inclusive and `end` exclusive. */\nexport interface Position {\n start: Point;\n end: Point;\n}\n\n/**\n * Content kinds a section can hold, named generically so a rule written once\n * works on every format. Each parser maps its own AST onto these: mdast\n * `paragraph`/`code`/`list`, Asciidoctor `paragraph`/`listing`/`ulist`|`olist`,\n * HTML `<p>`/`<pre>`/`<ul>` - all three onto `paragraph`/`codeBlock`/`list`.\n *\n * The vocabulary is wider than any one parser emits today. `table`,\n * `admonition`, `image`, `blockquote`, `definitionList`, and `element` are\n * declared here, and in each `DocumentParser.kinds`, only once a parser\n * actually produces them - see `src/lint/parsers/index.ts`.\n */\nexport type ContentKind =\n | \"paragraph\"\n | \"codeBlock\"\n | \"list\"\n | \"listItem\"\n | \"table\"\n | \"tableRow\"\n | \"tableCell\"\n | \"admonition\"\n | \"image\"\n | \"blockquote\"\n | \"definitionList\"\n | \"definitionItem\"\n | \"element\";\n\nexport interface ContentNodeBase {\n kind: ContentKind;\n position: Position;\n /** Plain-text rendering, used by pattern rules. */\n text: string;\n}\n\nexport interface ParagraphNode extends ContentNodeBase {\n kind: \"paragraph\";\n}\n\nexport interface CodeNode extends ContentNodeBase {\n kind: \"codeBlock\";\n /** Language, when the format carries one. */\n language?: string;\n /** The info-string tail after the language, when the format carries one. */\n fenceInfo?: string;\n}\n\nexport interface ListItemNode {\n kind: \"listItem\";\n position: Position;\n text: string;\n /** Nested content, so item-level paragraph/code/list rules can run. */\n children: ContentNode[];\n}\n\nexport interface ListNode extends ContentNodeBase {\n kind: \"list\";\n ordered: boolean;\n items: ListItemNode[];\n}\n\nexport interface TableCellNode extends ContentNodeBase {\n kind: \"tableCell\";\n children: ContentNode[];\n}\n\nexport interface TableRowNode extends ContentNodeBase {\n kind: \"tableRow\";\n header: boolean;\n children: TableCellNode[];\n}\n\nexport interface TableNode extends ContentNodeBase {\n kind: \"table\";\n children: TableRowNode[];\n}\n\n/**\n * A callout, and the flavor the source gave it.\n *\n * `variant` is optional because not every format names one this vocabulary\n * has. reStructuredText has `hint`, `attention`, `error` and a generic\n * `admonition` directive, and a bare HTML `<aside>` says nothing at all. Those\n * produce an admonition with no variant rather than an invented equivalence:\n * mapping `hint` onto `tip` would make `variant: tip` pass on a page that\n * never said tip. A `variant:` rule reports such a node as a mismatch, and a\n * plain count rule still counts it.\n */\nexport interface AdmonitionNode extends ContentNodeBase {\n kind: \"admonition\";\n variant?: \"note\" | \"tip\" | \"important\" | \"caution\" | \"warning\" | \"danger\";\n children: ContentNode[];\n}\n\nexport interface ImageNode extends ContentNodeBase {\n kind: \"image\";\n url: string;\n alt: string;\n title?: string;\n}\n\nexport interface BlockquoteNode extends ContentNodeBase {\n kind: \"blockquote\";\n children: ContentNode[];\n}\n\nexport interface DefinitionItemNode {\n kind: \"definitionItem\";\n position: Position;\n text: string;\n term: string;\n definition: ContentNode[];\n}\n\nexport interface DefinitionListNode extends ContentNodeBase {\n kind: \"definitionList\";\n children: DefinitionItemNode[];\n}\n\n/**\n * A named wrapper - an MDX/JSX component today, and where HTML and DITA may\n * eventually anchor a custom element. Its children are its own content, never\n * the enclosing section's: a rule reading a section's `children` must not see\n * inside an `<Element>` it did not ask about.\n */\nexport interface ElementNode extends ContentNodeBase {\n kind: \"element\";\n name: string;\n attributes?: Record<string, string | true>;\n children: ContentNode[];\n}\n\nexport type ContentNode =\n | ParagraphNode\n | CodeNode\n | ListNode\n | TableNode\n | AdmonitionNode\n | ImageNode\n | BlockquoteNode\n | DefinitionListNode\n | ElementNode;\n\n/**\n * One section of a document, demarcated by a heading.\n *\n * `slug`/`title`/`level`/`order`/`parentSlug` intentionally match manni graph's\n * `Section` (dockg/src/types.ts), so its graph can be built from this tree.\n *\n * `children` is in document order and is the single source of truth: the\n * paragraph/codeBlock/list counts every rule needs are queries over it, not\n * separately maintained arrays.\n */\nexport interface SectionNode {\n /** Slug of the heading, disambiguated across the document (`install-1`). */\n slug: string;\n /** Heading text, with inline markup flattened. */\n title: string;\n /** Heading level, 1-6. 0 for the implicit lead section before any heading. */\n level: number;\n /** 1-based position among siblings under the same parent. */\n order: number;\n /** Slug of the enclosing section, or null at the top level. */\n parentSlug: string | null;\n /** Span of the title itself. Null for the implicit lead section. */\n titlePosition: Position | null;\n /**\n * The anchor the source itself gives this section, verbatim - an HTML `id`,\n * a DITA `@id`, an AsciiDoc `[[id]]`, a reST `.. _label:` - when it gives\n * one. `slug` stays the slugged title either way: a link written against\n * the source's own id resolves through this, and nothing lint matches on\n * reads it.\n */\n id?: string;\n /**\n * Set on the level-1 section `withMetadataTitle` made from a metadata\n * `title`, so a consumer can tell it from a heading the author wrote. Its\n * `titlePosition` is not enough: a reST title read back as docinfo shares\n * its span with the frontmatter, written or not.\n */\n synthetic?: true;\n /** Span of the whole section: its heading through the last node before the next sibling heading. */\n position: Position;\n /** Direct content, in document order, excluding anything owned by a subsection. */\n children: ContentNode[];\n /** Nested sections, in document order. */\n sections: SectionNode[];\n}\n\n/** What a parser returns for one file. */\nexport interface DocumentTree {\n /** Name of the parser that produced this (`markdown`, `asciidoc`, ...). */\n format: string;\n /** Path the content came from, for error messages. */\n filePath: string;\n /** Raw frontmatter/metadata values, or null when the file carries none. */\n frontmatter: Record<string, unknown> | null;\n /** Span of the frontmatter block, for anchoring findings about it. */\n frontmatterPosition: Position | null;\n /** Top-level sections, in document order. */\n sections: SectionNode[];\n /**\n * Link targets exactly as the source wrote them, in document order, for\n * `manni graph`. No lint rule reads them. Each parser decides what counts:\n * an anchor to elsewhere does, and a stylesheet, a heading's own permalink,\n * or a key reference resolved only at build time does not.\n */\n links: { target: string; position: Position }[];\n /**\n * The MadCap Flare project a topic resolved against, and its target\n * (proposal 0125). Absent for every other page, and for a topic no project\n * holds. `excluded` marks a topic whose root the target excludes: its\n * resolved view, and so `sections`, is empty, while `links` stay.\n */\n flare?: {\n /** The `.flprj` file's name. */\n project: string;\n target?: { name: string; from: \"tools.flare.target\" | \"the only target\" };\n excluded?: true;\n };\n}\n\n/**\n * What a parser may read beyond the page's own bytes. `parse`'s `filePath`\n * is a display label, so the absolute path rides here. A MadCap Flare topic\n * resolves against its project through `flare` (proposal 0125). A parser\n * with no use for either ignores them.\n */\nexport interface ParseContext {\n absPath: string;\n flare?: FlareRun;\n}\n\n/**\n * A parser for one input format.\n *\n * Shaped after docmeta's `MetadataExtractor` so the two registries read the\n * same way. A format is registered only when its parser reads it, so every\n * registered format is one the tool reads, and an extension no parser claims is\n * skipped by name rather than parsed as Markdown.\n */\nexport interface DocumentParser {\n /** Stable name, also used as `DocumentTree.format`. */\n name: string;\n /** Human-readable label for `manni lint tools`. */\n label: string;\n /**\n * The content kinds this parser actually emits today. A capability\n * declaration, not the full `ContentKind` vocabulary: a kind absent here is\n * one no rule will ever see from this parser's trees, whatever the format\n * could in principle represent.\n */\n kinds: ContentKind[];\n /** Lowercase file extensions this parser handles, incl. dot (e.g. \".md\"). */\n extensions: string[];\n /**\n * Extensions safe to collect from a directory walk. Defaults to\n * `extensions`.\n *\n * The two differ when an extension is a generic container rather than a\n * documentation format. `.xml` is the case: this parser can read a DocBook\n * or DITA document named explicitly, but a docs tree also contains\n * `pom.xml`, `sitemap.xml`, and `.csproj`, and sweeping those in turns a\n * clean run into a failure about files the user never asked to lint.\n */\n walkExtensions?: string[];\n /**\n * Parse raw file content into the generic tree. AsciiDoc's parser returns a\n * promise, because Asciidoctor loads a document asynchronously; the others\n * return the tree itself. A caller awaits either.\n */\n parse(\n content: string,\n filePath: string,\n context?: ParseContext,\n ): DocumentTree | Promise<DocumentTree>;\n}\n\n/**\n * How much a finding weighs, on the one scale every manni tool speaks\n * (`src/shared/severity.ts`): `notice | warning | error`.\n *\n * Almost every structural finding is an `error`, since a template either\n * describes a document or it does not. `unsupported_content_kind` is the\n * exception and is a `warning`: the rule never ran, so the page may still be\n * fine, and a warning never moves the exit code.\n *\n * The scale is the family's and not this tool's private pair, because a flag\n * or config key two domains both have carries the same name *and* the same\n * values. Re-exported so `lint.Severity` names the same type a caller already\n * has.\n */\nexport type { Severity };\n\n/**\n * One structural violation.\n *\n * The field set is pinned by manni docevals' tool adapter, which reads\n * `{ type, heading, message, position }` off the JSON reporter. Additions are\n * safe; renames are not.\n */\nexport interface Finding {\n /** Machine-readable rule id, e.g. `missing_section`. */\n type: string;\n /** Heading of the section the finding is anchored to, if any. */\n heading: string | null;\n message: string;\n position: Position;\n severity: Severity;\n /**\n * The template that judged the page and the rule this finding is about, so\n * an author reads what the section is for beside what is wrong with it.\n * `null` when no template stands behind the finding: a parse failure, an\n * unknown doctype, a broken template, or a tool other than manni.\n */\n template?: FindingTemplate | null;\n}\n\n/**\n * What a template asks for, as a finding carries it: the family's guidance\n * shape (`src/shared/guidance.ts`) under lint's released name.\n *\n * - `id` is the template's ref, as `manni lint templates` lists it and\n * `--template` takes it.\n * - `rule` is the rule's `id`. `null` for a rule without one, the template\n * itself, or no rule at all.\n * - `description` is the rule's `description`, or `null` when it has none.\n * - `guide` is the template's `guide`, after `extends`, or `null`.\n */\nexport type FindingTemplate = Guidance;\n\n/**\n * Why a file was not linted.\n *\n * `unreadable` is the one that is not about the document: the file was found,\n * claimed by a parser, and then could not be opened - a denied permission, a\n * symlink loop, a page a doc build moved between the walk and the read. It is a\n * skip rather than a finding because nothing was checked, and calling it a\n * finding would report the docs as wrong when the filesystem was.\n *\n * `excluded` is a MadCap Flare topic whose root carries conditions the run's\n * target excludes (proposal 0125): the target does not build it.\n */\nexport type SkipReason = \"no-template\" | \"unsupported-format\" | \"unreadable\" | \"excluded\";\n\n/** Result of linting one file. */\nexport interface FileResult {\n file: string;\n /** True when the file was linted and produced no findings. */\n success: boolean;\n findings: Finding[];\n /** Template id/ref applied, or null when skipped. */\n template: string | null;\n /** Set when the file was skipped rather than linted. */\n skipped?: SkipReason;\n}\n"],"mappings":";;;;;;AAwBO,IAAM,YAAN,cAAwB,UAAU;AAAA,EACvC,YAAY,SAAiB;AAC3B,UAAM,OAAO;AACb,SAAK,OAAO;AAAA,EACd;AACF;","names":[]}
1
+ {"version":3,"sources":["../src/lint/types.ts"],"sourcesContent":["/**\n * The contract every other module is written against.\n *\n * Two shapes matter. `DocumentTree` is what a parser owes the rest of the tool:\n * a nested section tree with real source positions, in a vocabulary that has\n * nothing to do with Markdown. `Finding` is what the tool owes its caller.\n * Everything between the two - matching, rules, reporting - touches neither\n * mdast nor Asciidoctor nor parse5, which is what lets a new input format be\n * one file plus a line in the parser registry.\n */\n\nimport { ToolError } from \"../shared/errors.js\";\nimport type { Severity } from \"../shared/severity.js\";\nimport type { Guidance } from \"../shared/guidance.js\";\nimport type { FlareRun } from \"../shared/flare/index.js\";\n\n/**\n * Operational/usage failure. Exits 2; never used for lint findings.\n *\n * Extends the umbrella's `ToolError`, which is what the shared bin runner\n * matches on; the subclass stays so this tool's tests and library callers can\n * match on it by name. Named for its domain, as `A11yError`, `CiteError` and\n * `KeyError` are.\n */\nexport class LintError extends ToolError {\n constructor(message: string) {\n super(message);\n this.name = \"LintError\";\n }\n}\n\n/** A point in a source file. Line and column are 1-based, offset 0-based. */\nexport interface Point {\n line: number;\n column: number;\n offset: number;\n}\n\n/** A half-open source span, `start` inclusive and `end` exclusive. */\nexport interface Position {\n start: Point;\n end: Point;\n}\n\n/**\n * Content kinds a section can hold, named generically so a rule written once\n * works on every format. Each parser maps its own AST onto these: mdast\n * `paragraph`/`code`/`list`, Asciidoctor `paragraph`/`listing`/`ulist`|`olist`,\n * HTML `<p>`/`<pre>`/`<ul>` - all three onto `paragraph`/`codeBlock`/`list`.\n *\n * The vocabulary is wider than any one parser emits today. `table`,\n * `admonition`, `image`, `blockquote`, `definitionList`, and `element` are\n * declared here, and in each `DocumentParser.kinds`, only once a parser\n * actually produces them - see `src/lint/parsers/index.ts`.\n */\nexport type ContentKind =\n | \"paragraph\"\n | \"codeBlock\"\n | \"list\"\n | \"listItem\"\n | \"table\"\n | \"tableRow\"\n | \"tableCell\"\n | \"admonition\"\n | \"image\"\n | \"blockquote\"\n | \"definitionList\"\n | \"definitionItem\"\n | \"element\";\n\nexport interface ContentNodeBase {\n kind: ContentKind;\n position: Position;\n /** Plain-text rendering, used by pattern rules. */\n text: string;\n}\n\nexport interface ParagraphNode extends ContentNodeBase {\n kind: \"paragraph\";\n}\n\nexport interface CodeNode extends ContentNodeBase {\n kind: \"codeBlock\";\n /** Language, when the format carries one. */\n language?: string;\n /** The info-string tail after the language, when the format carries one. */\n fenceInfo?: string;\n}\n\nexport interface ListItemNode {\n kind: \"listItem\";\n position: Position;\n text: string;\n /** Nested content, so item-level paragraph/code/list rules can run. */\n children: ContentNode[];\n}\n\nexport interface ListNode extends ContentNodeBase {\n kind: \"list\";\n ordered: boolean;\n items: ListItemNode[];\n}\n\nexport interface TableCellNode extends ContentNodeBase {\n kind: \"tableCell\";\n children: ContentNode[];\n}\n\nexport interface TableRowNode extends ContentNodeBase {\n kind: \"tableRow\";\n header: boolean;\n children: TableCellNode[];\n}\n\nexport interface TableNode extends ContentNodeBase {\n kind: \"table\";\n children: TableRowNode[];\n}\n\n/**\n * A callout, and the flavor the source gave it.\n *\n * `variant` is optional because not every format names one this vocabulary\n * has. reStructuredText has `hint`, `attention`, `error` and a generic\n * `admonition` directive, and a bare HTML `<aside>` says nothing at all. Those\n * produce an admonition with no variant rather than an invented equivalence:\n * mapping `hint` onto `tip` would make `variant: tip` pass on a page that\n * never said tip. A `variant:` rule reports such a node as a mismatch, and a\n * plain count rule still counts it.\n */\nexport interface AdmonitionNode extends ContentNodeBase {\n kind: \"admonition\";\n variant?: \"note\" | \"tip\" | \"important\" | \"caution\" | \"warning\" | \"danger\";\n children: ContentNode[];\n}\n\nexport interface ImageNode extends ContentNodeBase {\n kind: \"image\";\n url: string;\n alt: string;\n title?: string;\n}\n\nexport interface BlockquoteNode extends ContentNodeBase {\n kind: \"blockquote\";\n children: ContentNode[];\n}\n\nexport interface DefinitionItemNode {\n kind: \"definitionItem\";\n position: Position;\n text: string;\n term: string;\n definition: ContentNode[];\n}\n\nexport interface DefinitionListNode extends ContentNodeBase {\n kind: \"definitionList\";\n children: DefinitionItemNode[];\n}\n\n/**\n * A named wrapper - an MDX/JSX component today, and where HTML and DITA may\n * eventually anchor a custom element. Its children are its own content, never\n * the enclosing section's: a rule reading a section's `children` must not see\n * inside an `<Element>` it did not ask about.\n */\nexport interface ElementNode extends ContentNodeBase {\n kind: \"element\";\n name: string;\n attributes?: Record<string, string | true>;\n children: ContentNode[];\n}\n\nexport type ContentNode =\n | ParagraphNode\n | CodeNode\n | ListNode\n | TableNode\n | AdmonitionNode\n | ImageNode\n | BlockquoteNode\n | DefinitionListNode\n | ElementNode;\n\n/**\n * One section of a document, demarcated by a heading.\n *\n * `slug`/`title`/`level`/`order`/`parentSlug` intentionally match manni graph's\n * `Section` (dockg/src/types.ts), so its graph can be built from this tree.\n *\n * `children` is in document order and is the single source of truth: the\n * paragraph/codeBlock/list counts every rule needs are queries over it, not\n * separately maintained arrays.\n */\nexport interface SectionNode {\n /** Slug of the heading, disambiguated across the document (`install-1`). */\n slug: string;\n /** Heading text, with inline markup flattened. */\n title: string;\n /** Heading level, 1-6. 0 for the implicit lead section before any heading. */\n level: number;\n /** 1-based position among siblings under the same parent. */\n order: number;\n /** Slug of the enclosing section, or null at the top level. */\n parentSlug: string | null;\n /** Span of the title itself. Null for the implicit lead section. */\n titlePosition: Position | null;\n /**\n * The anchor the source itself gives this section, verbatim - an HTML `id`,\n * a DITA `@id`, an AsciiDoc `[[id]]`, a reST `.. _label:` - when it gives\n * one. `slug` stays the slugged title either way: a link written against\n * the source's own id resolves through this, and nothing lint matches on\n * reads it.\n */\n id?: string;\n /**\n * Set on the level-1 section `withMetadataTitle` made from a metadata\n * `title`, so a consumer can tell it from a heading the author wrote. Its\n * `titlePosition` is not enough: a reST title read back as docinfo shares\n * its span with the frontmatter, written or not.\n */\n synthetic?: true;\n /** Span of the whole section: its heading through the last node before the next sibling heading. */\n position: Position;\n /** Direct content, in document order, excluding anything owned by a subsection. */\n children: ContentNode[];\n /** Nested sections, in document order. */\n sections: SectionNode[];\n}\n\n/** What a parser returns for one file. */\nexport interface DocumentTree {\n /** Name of the parser that produced this (`markdown`, `asciidoc`, ...). */\n format: string;\n /** Path the content came from, for error messages. */\n filePath: string;\n /** Raw frontmatter/metadata values, or null when the file carries none. */\n frontmatter: Record<string, unknown> | null;\n /** Span of the frontmatter block, for anchoring findings about it. */\n frontmatterPosition: Position | null;\n /** Top-level sections, in document order. */\n sections: SectionNode[];\n /**\n * Link targets exactly as the source wrote them, in document order, for\n * `manni graph`. No lint rule reads them. Each parser decides what counts:\n * an anchor to elsewhere does, and a stylesheet, a heading's own permalink,\n * or a key reference resolved only at build time does not.\n */\n links: { target: string; position: Position }[];\n /**\n * The MadCap Flare project a topic resolved against, and its target\n * (proposal 0125). Absent for every other page, and for a topic no project\n * holds. `excluded` marks a topic whose root the target excludes: its\n * resolved view, and so `sections`, is empty, while `links` stay.\n */\n flare?: {\n /** The `.flprj` file's name. */\n project: string;\n target?: { name: string; from: \"tools.flare.target\" | \"the only target\" };\n excluded?: true;\n };\n}\n\n/**\n * What a parser may read beyond the page's own bytes. `parse`'s `filePath`\n * is a display label, so the absolute path rides here. A MadCap Flare topic\n * resolves against its project through `flare` (proposal 0125). A parser\n * with no use for either ignores them.\n */\nexport interface ParseContext {\n absPath: string;\n flare?: FlareRun;\n}\n\n/**\n * A parser for one input format.\n *\n * Shaped after docmeta's `MetadataExtractor` so the two registries read the\n * same way. A format is registered only when its parser reads it, so every\n * registered format is one the tool reads, and an extension no parser claims is\n * skipped by name rather than parsed as Markdown.\n */\nexport interface DocumentParser {\n /** Stable name, also used as `DocumentTree.format`. */\n name: string;\n /** Human-readable label for `manni lint tools`. */\n label: string;\n /**\n * The content kinds this parser actually emits today. A capability\n * declaration, not the full `ContentKind` vocabulary: a kind absent here is\n * one no rule will ever see from this parser's trees, whatever the format\n * could in principle represent.\n */\n kinds: ContentKind[];\n /** Lowercase file extensions this parser handles, incl. dot (e.g. \".md\"). */\n extensions: string[];\n /**\n * Extensions safe to collect from a directory walk. Defaults to\n * `extensions`.\n *\n * The two differ when an extension is a generic container rather than a\n * documentation format. `.xml` is the case: this parser can read a DocBook\n * or DITA document named explicitly, but a docs tree also contains\n * `pom.xml`, `sitemap.xml`, and `.csproj`, and sweeping those in turns a\n * clean run into a failure about files the user never asked to lint.\n */\n walkExtensions?: string[];\n /**\n * Parse raw file content into the generic tree. AsciiDoc's parser returns a\n * promise, because Asciidoctor loads a document asynchronously; the others\n * return the tree itself. A caller awaits either.\n */\n parse(\n content: string,\n filePath: string,\n context?: ParseContext,\n ): DocumentTree | Promise<DocumentTree>;\n}\n\n/**\n * How much a finding weighs, on the one scale every manni tool speaks\n * (`src/shared/severity.ts`): `notice | warning | error`.\n *\n * Almost every structural finding is an `error`, since a template either\n * describes a document or it does not. `unsupported_content_kind` is the\n * exception and is a `warning`: the rule never ran, so the page may still be\n * fine, and a warning never moves the exit code.\n *\n * The scale is the family's and not this tool's private pair, because a flag\n * or config key two domains both have carries the same name *and* the same\n * values. Re-exported so `lint.Severity` names the same type a caller already\n * has.\n */\nexport type { Severity };\n\n/**\n * One structural violation.\n *\n * The field set is pinned by manni docevals' tool adapter, which reads\n * `{ type, heading, message, position }` off the JSON reporter. Additions are\n * safe; renames are not.\n */\nexport interface Finding {\n /** Machine-readable rule id, e.g. `missing_section`. */\n type: string;\n /** Heading of the section the finding is anchored to, if any. */\n heading: string | null;\n message: string;\n position: Position;\n severity: Severity;\n /**\n * The template that judged the page and the rule this finding is about, so\n * an author reads what the section is for beside what is wrong with it.\n * `null` when no template stands behind the finding: a parse failure, an\n * unknown doctype, a broken template, or a tool other than manni.\n */\n template?: FindingTemplate | null;\n /**\n * Where the text this finding is about lives, when the page includes it\n * from another file (proposal 0130). `position` is the include directive's\n * place in the page; this names the file to edit. Absent otherwise.\n */\n includedFrom?: { file: string; line: number };\n}\n\n/**\n * What a template asks for, as a finding carries it: the family's guidance\n * shape (`src/shared/guidance.ts`) under lint's released name.\n *\n * - `id` is the template's ref, as `manni lint templates` lists it and\n * `--template` takes it.\n * - `rule` is the rule's `id`. `null` for a rule without one, the template\n * itself, or no rule at all.\n * - `description` is the rule's `description`, or `null` when it has none.\n * - `guide` is the template's `guide`, after `extends`, or `null`.\n */\nexport type FindingTemplate = Guidance;\n\n/**\n * Why a file was not linted.\n *\n * `unreadable` is the one that is not about the document: the file was found,\n * claimed by a parser, and then could not be opened - a denied permission, a\n * symlink loop, a page a doc build moved between the walk and the read. It is a\n * skip rather than a finding because nothing was checked, and calling it a\n * finding would report the docs as wrong when the filesystem was.\n *\n * `excluded` is a MadCap Flare topic whose root carries conditions the run's\n * target excludes (proposal 0125): the target does not build it.\n *\n * `partial` is a file another page in the run includes (proposal 0130). It is\n * assessed as part of that page, where a reader meets it, and never alone.\n */\nexport type SkipReason =\n | \"no-template\"\n | \"unsupported-format\"\n | \"unreadable\"\n | \"excluded\"\n | \"partial\";\n\n/** Result of linting one file. */\nexport interface FileResult {\n file: string;\n /** True when the file was linted and produced no findings. */\n success: boolean;\n findings: Finding[];\n /** Template id/ref applied, or null when skipped. */\n template: string | null;\n /** Set when the file was skipped rather than linted. */\n skipped?: SkipReason;\n}\n"],"mappings":";;;;;;AAwBO,IAAM,YAAN,cAAwB,UAAU;AAAA,EACvC,YAAY,SAAiB;AAC3B,UAAM,OAAO;AACb,SAAK,OAAO;AAAA,EACd;AACF;","names":[]}
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  import {
3
3
  discoverArtifacts
4
- } from "./chunk-SF2WTUDR.js";
4
+ } from "./chunk-F6FDIOKE.js";
5
5
  import {
6
6
  parseHookPayload,
7
7
  readStdin
@@ -12,7 +12,7 @@ import {
12
12
  relPosix,
13
13
  sha256Hex,
14
14
  writeManifest
15
- } from "./chunk-2HZR3H2N.js";
15
+ } from "./chunk-N7VIVL42.js";
16
16
  import {
17
17
  loadConfig
18
18
  } from "./chunk-BTFXOKCP.js";
@@ -212,4 +212,4 @@ export {
212
212
  runCapture,
213
213
  renderCapture
214
214
  };
215
- //# sourceMappingURL=chunk-RZX6I2NY.js.map
215
+ //# sourceMappingURL=chunk-MCUN2JP3.js.map
@@ -4,7 +4,7 @@ import {
4
4
  listInTree,
5
5
  resolveArtifacts,
6
6
  safeRead
7
- } from "./chunk-2HZR3H2N.js";
7
+ } from "./chunk-N7VIVL42.js";
8
8
  import {
9
9
  configDir
10
10
  } from "./chunk-4TSWU2SU.js";
@@ -15,13 +15,13 @@ import {
15
15
  } from "./chunk-VHJ72YCD.js";
16
16
  import {
17
17
  extractEvals
18
- } from "./chunk-Y7SBE6TC.js";
18
+ } from "./chunk-CY4RNLFN.js";
19
19
  import {
20
20
  makeRedactor
21
21
  } from "./chunk-6WJUZQQX.js";
22
22
  import {
23
23
  extractFrontmatter
24
- } from "./chunk-D6HTXNFN.js";
24
+ } from "./chunk-2NB7MT5I.js";
25
25
 
26
26
  // src/tracevals/rules/turn.ts
27
27
  var INJECTED = /<(system-reminder|task-notification|ci-monitor-event|local-command-stdout|local-command-stderr|local-command-caveat)>[\s\S]*?<\/\1>/g;
@@ -673,4 +673,4 @@ export {
673
673
  resolveTurnSources,
674
674
  pathKey
675
675
  };
676
- //# sourceMappingURL=chunk-3LAEG2JM.js.map
676
+ //# sourceMappingURL=chunk-MQ34D4OP.js.map
@@ -17,7 +17,7 @@ import {
17
17
  spliceEntryField,
18
18
  unifiedDiff,
19
19
  withClaimLines
20
- } from "./chunk-C6M7SALA.js";
20
+ } from "./chunk-STPT3WEC.js";
21
21
  import {
22
22
  CITATIONS_KEY,
23
23
  CITE_SECTION,
@@ -59,7 +59,7 @@ import {
59
59
  stripMarkers,
60
60
  twoManifestsRefusal,
61
61
  urlManifestRefusal
62
- } from "./chunk-KZK5JOET.js";
62
+ } from "./chunk-INDMEKFB.js";
63
63
  import {
64
64
  renderCheckJson,
65
65
  renderHistoryJson,
@@ -68,7 +68,7 @@ import {
68
68
  } from "./chunk-IM7C3H4W.js";
69
69
  import {
70
70
  renderCheckGithub
71
- } from "./chunk-YWHSZSQL.js";
71
+ } from "./chunk-BVQEOF23.js";
72
72
  import {
73
73
  refusalLine,
74
74
  removalLine,
@@ -77,7 +77,7 @@ import {
77
77
  renderRemovePretty,
78
78
  renderUpdatePretty,
79
79
  rewriteLine
80
- } from "./chunk-A6FYDQC2.js";
80
+ } from "./chunk-D2N3SAV6.js";
81
81
  import {
82
82
  blockMatches,
83
83
  claimEnd,
@@ -103,7 +103,7 @@ import {
103
103
  toValidationResult,
104
104
  unitAt,
105
105
  unitText
106
- } from "./chunk-2A7L2AC2.js";
106
+ } from "./chunk-J7OFPDCD.js";
107
107
  import {
108
108
  CITE_RULES,
109
109
  CiteError,
@@ -129,7 +129,7 @@ import {
129
129
  sourceRange,
130
130
  spellSource,
131
131
  validateEntry
132
- } from "./chunk-5LSQZBLS.js";
132
+ } from "./chunk-P676AEK6.js";
133
133
  import {
134
134
  MAX_RANGE_LINES,
135
135
  MOVE_BUDGET_BYTES,
@@ -163,7 +163,7 @@ import {
163
163
  statementForms,
164
164
  toBodyLines,
165
165
  toFileLines
166
- } from "./chunk-SXWPKK4D.js";
166
+ } from "./chunk-ZGLLJSL7.js";
167
167
  import {
168
168
  __export
169
169
  } from "./chunk-2H7UOFLK.js";
@@ -456,4 +456,4 @@ export {
456
456
  reencryptCitationEntries,
457
457
  cite_exports
458
458
  };
459
- //# sourceMappingURL=chunk-2AC35AS2.js.map
459
+ //# sourceMappingURL=chunk-MREXYXMW.js.map
@@ -4,7 +4,7 @@ import {
4
4
  } from "./chunk-4TSWU2SU.js";
5
5
  import {
6
6
  offeredNames
7
- } from "./chunk-Y7SBE6TC.js";
7
+ } from "./chunk-CY4RNLFN.js";
8
8
  import {
9
9
  MANIFEST_VERSION
10
10
  } from "./chunk-6WJUZQQX.js";
@@ -769,4 +769,4 @@ export {
769
769
  PROJECT_RULES_FILENAMES,
770
770
  resolveArtifacts
771
771
  };
772
- //# sourceMappingURL=chunk-2HZR3H2N.js.map
772
+ //# sourceMappingURL=chunk-N7VIVL42.js.map
@@ -6,7 +6,7 @@ import {
6
6
  canonicalSchemaRef,
7
7
  fingerprint,
8
8
  isErrorSeverity
9
- } from "./chunk-D6HTXNFN.js";
9
+ } from "./chunk-2NB7MT5I.js";
10
10
  import {
11
11
  escapeWorkflowCommandMessage,
12
12
  escapeWorkflowCommandProperty,
@@ -20,7 +20,7 @@ import {
20
20
  } from "./chunk-CDX4QK6O.js";
21
21
  import {
22
22
  package_default
23
- } from "./chunk-Z2KVPZYI.js";
23
+ } from "./chunk-SORYKTNP.js";
24
24
 
25
25
  // src/meta/reporters/rule-id.ts
26
26
  var SYNTHETIC_SCHEMA = "(parse)";
@@ -407,4 +407,4 @@ export {
407
407
  renderGithub,
408
408
  render
409
409
  };
410
- //# sourceMappingURL=chunk-HV6QKQTR.js.map
410
+ //# sourceMappingURL=chunk-NH4RQUSD.js.map
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  import {
3
3
  RECORD_TYPES
4
- } from "./chunk-PVAJUMDT.js";
4
+ } from "./chunk-672TCM2Q.js";
5
5
  import {
6
6
  LineRangeError,
7
7
  MAX_RANGE_LINES,
@@ -13,7 +13,7 @@ import {
13
13
  parseStatements,
14
14
  sliceLines,
15
15
  statementForms
16
- } from "./chunk-SXWPKK4D.js";
16
+ } from "./chunk-ZGLLJSL7.js";
17
17
  import {
18
18
  __default4 as __default,
19
19
  __default5 as __default2,
@@ -22,7 +22,7 @@ import {
22
22
  hasFrontmatterFence,
23
23
  locateFrontmatter,
24
24
  supportedExtensions
25
- } from "./chunk-D6HTXNFN.js";
25
+ } from "./chunk-2NB7MT5I.js";
26
26
  import {
27
27
  isEncryptedValue
28
28
  } from "./chunk-CDX4QK6O.js";
@@ -623,4 +623,4 @@ export {
623
623
  citationInputs,
624
624
  readPage
625
625
  };
626
- //# sourceMappingURL=chunk-5LSQZBLS.js.map
626
+ //# sourceMappingURL=chunk-P676AEK6.js.map
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  import {
3
3
  LintError
4
- } from "./chunk-OPF3NOKF.js";
4
+ } from "./chunk-M77SIRUX.js";
5
5
 
6
6
  // src/lint/rules/paragraphs.ts
7
7
  function checkParagraphsIn(content, rule, ctx) {
@@ -1147,4 +1147,4 @@ export {
1147
1147
  aboutRule,
1148
1148
  matchSections
1149
1149
  };
1150
- //# sourceMappingURL=chunk-QEFVMOWF.js.map
1150
+ //# sourceMappingURL=chunk-QYKTIRRE.js.map
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  import {
3
3
  displayPath
4
- } from "./chunk-6FNRVJQC.js";
4
+ } from "./chunk-4JDOHAHR.js";
5
5
  import {
6
6
  escapeWorkflowCommandMessage,
7
7
  escapeWorkflowCommandProperty,
@@ -22,4 +22,4 @@ function renderFindingsGithub(report) {
22
22
  export {
23
23
  renderFindingsGithub
24
24
  };
25
- //# sourceMappingURL=chunk-VGIKTY7D.js.map
25
+ //# sourceMappingURL=chunk-R64PJYCT.js.map