allyhub 0.13.0 → 0.15.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 (245) hide show
  1. package/CHANGELOG.md +14 -0
  2. package/dist/commands/frames.js +9 -11
  3. package/dist/node_modules/@allyhub/3d-extension/package.json +1 -1
  4. package/dist/node_modules/@allyhub/audio/package.json +1 -1
  5. package/dist/node_modules/@allyhub/browser/package.json +1 -1
  6. package/dist/node_modules/@allyhub/build/package.json +1 -1
  7. package/dist/node_modules/@allyhub/canvas-extension/package.json +1 -1
  8. package/dist/node_modules/@allyhub/canvas-model/package.json +1 -1
  9. package/dist/node_modules/@allyhub/chart/package.json +1 -1
  10. package/dist/node_modules/@allyhub/check/package.json +1 -1
  11. package/dist/node_modules/@allyhub/cloud/package.json +1 -1
  12. package/dist/node_modules/@allyhub/components/package.json +1 -1
  13. package/dist/node_modules/@allyhub/dev-server/dist/tools.js +1 -1
  14. package/dist/node_modules/@allyhub/dev-server/package.json +1 -1
  15. package/dist/node_modules/@allyhub/diagnostics/package.json +1 -1
  16. package/dist/node_modules/@allyhub/doc/package.json +1 -1
  17. package/dist/node_modules/@allyhub/doc-extension/package.json +1 -1
  18. package/dist/node_modules/@allyhub/doc-print/package.json +1 -1
  19. package/dist/node_modules/@allyhub/export/package.json +1 -1
  20. package/dist/node_modules/@allyhub/extension-api/package.json +1 -1
  21. package/dist/node_modules/@allyhub/extension-host/dist/points.js +1 -1
  22. package/dist/node_modules/@allyhub/extension-host/package.json +1 -1
  23. package/dist/node_modules/@allyhub/formats/dist/files.d.ts +9 -2
  24. package/dist/node_modules/@allyhub/formats/dist/files.js +1 -1
  25. package/dist/node_modules/@allyhub/formats/dist/note-shape.d.ts +9 -0
  26. package/dist/node_modules/@allyhub/formats/dist/note-shape.js +1 -1
  27. package/dist/node_modules/@allyhub/formats/package.json +1 -1
  28. package/dist/node_modules/@allyhub/i18n/package.json +1 -1
  29. package/dist/node_modules/@allyhub/image-draw/package.json +1 -1
  30. package/dist/node_modules/@allyhub/image-extension/package.json +1 -1
  31. package/dist/node_modules/@allyhub/image-measure/package.json +1 -1
  32. package/dist/node_modules/@allyhub/image-psd/package.json +1 -1
  33. package/dist/node_modules/@allyhub/image-render/package.json +1 -1
  34. package/dist/node_modules/@allyhub/image-runtime/package.json +1 -1
  35. package/dist/node_modules/@allyhub/image-sdk/package.json +1 -1
  36. package/dist/node_modules/@allyhub/jobs/package.json +1 -1
  37. package/dist/node_modules/@allyhub/linkedin-extension/package.json +1 -1
  38. package/dist/node_modules/@allyhub/linkedin-model/package.json +1 -1
  39. package/dist/node_modules/@allyhub/linkedin-view/package.json +1 -1
  40. package/dist/node_modules/@allyhub/measure/package.json +1 -1
  41. package/dist/node_modules/@allyhub/media/package.json +1 -1
  42. package/dist/node_modules/@allyhub/media-extension/package.json +39 -1
  43. package/dist/node_modules/@allyhub/model/package.json +1 -1
  44. package/dist/node_modules/@allyhub/ooxml/package.json +1 -1
  45. package/dist/node_modules/@allyhub/piece/package.json +1 -1
  46. package/dist/node_modules/@allyhub/project/package.json +1 -1
  47. package/dist/node_modules/@allyhub/protocol/dist/tools.d.ts +36 -0
  48. package/dist/node_modules/@allyhub/protocol/dist/tools.js +1 -1
  49. package/dist/node_modules/@allyhub/protocol/package.json +1 -1
  50. package/dist/node_modules/@allyhub/registry/package.json +1 -1
  51. package/dist/node_modules/@allyhub/render/package.json +1 -1
  52. package/dist/node_modules/@allyhub/runtime/package.json +1 -1
  53. package/dist/node_modules/@allyhub/runtimes/package.json +1 -1
  54. package/dist/node_modules/@allyhub/scaffold/package.json +1 -1
  55. package/dist/node_modules/@allyhub/scenery/package.json +1 -1
  56. package/dist/node_modules/@allyhub/scenery-host/package.json +1 -1
  57. package/dist/node_modules/@allyhub/sheet/package.json +1 -1
  58. package/dist/node_modules/@allyhub/sheet-extension/package.json +1 -1
  59. package/dist/node_modules/@allyhub/slides-core/package.json +1 -1
  60. package/dist/node_modules/@allyhub/slides-extension/package.json +1 -1
  61. package/dist/node_modules/@allyhub/slides-pptx/package.json +1 -1
  62. package/dist/node_modules/@allyhub/slides-runtime/package.json +1 -1
  63. package/dist/node_modules/@allyhub/stage/package.json +1 -1
  64. package/dist/node_modules/@allyhub/stage-page/package.json +1 -1
  65. package/dist/node_modules/@allyhub/stage-runtime/package.json +1 -1
  66. package/dist/node_modules/@allyhub/telemetry/package.json +1 -1
  67. package/dist/node_modules/@allyhub/text-extension/markup/allyhub.yaml +2 -0
  68. package/dist/node_modules/@allyhub/text-extension/markup/markup.json +19 -0
  69. package/dist/node_modules/@allyhub/text-extension/markup/notes/launch.md +9 -0
  70. package/dist/node_modules/@allyhub/text-extension/package.json +64 -0
  71. package/dist/node_modules/@allyhub/video-core/package.json +1 -1
  72. package/dist/node_modules/@allyhub/video-extension/package.json +1 -1
  73. package/dist/node_modules/@allyhub/video-measure/package.json +1 -1
  74. package/dist/node_modules/@allyhub/video-sdk/package.json +1 -1
  75. package/dist/node_modules/@allyhub/website/package.json +1 -1
  76. package/dist/node_modules/@allyhub/website-extension/package.json +1 -1
  77. package/dist/node_modules/@allyhub/x-extension/package.json +1 -1
  78. package/dist/node_modules/@allyhub/x-model/package.json +1 -1
  79. package/dist/node_modules/@allyhub/x-view/package.json +1 -1
  80. package/dist/package.json +12 -12
  81. package/dist/works.js +1 -1
  82. package/editor-web/assets/{abnfDiagram-WEYOIA3C-D70jg8mE.js → abnfDiagram-WEYOIA3C-BHI0AbUY.js} +1 -1
  83. package/editor-web/assets/{architecture-WOLXFQ4H-CrXS3E8e.js → architecture-WOLXFQ4H-BMQS-OKZ.js} +1 -1
  84. package/editor-web/assets/{architectureDiagram-ZHVYKT53-JrBljCOx.js → architectureDiagram-ZHVYKT53-DZp9CM6P.js} +1 -1
  85. package/editor-web/assets/{article-BWrfVMRA.js → article-C_mBG5a1.js} +4 -4
  86. package/editor-web/assets/{article-hxHjqzV1.js → article-DWBxNvX0.js} +2 -2
  87. package/editor-web/assets/{blockDiagram-RJAE7QA3-BzfC1xTS.js → blockDiagram-RJAE7QA3-h6LWaev4.js} +1 -1
  88. package/editor-web/assets/{textarea-DBwRbOyF.js → browser-C9NP0ZYz.js} +47 -47
  89. package/editor-web/assets/button-BVQH7zxz.js +41 -0
  90. package/editor-web/assets/{c4Diagram-XDPPPE54-s2TpXKgH.js → c4Diagram-XDPPPE54-BvSMs7J4.js} +1 -1
  91. package/editor-web/assets/channel-BFHB0S0f.js +1 -0
  92. package/editor-web/assets/{chunk-2E7WHVMD-DyE9v6UX.js → chunk-2E7WHVMD-0EJTAmDF.js} +1 -1
  93. package/editor-web/assets/{chunk-4EMNKR2T-CCunMMcT.js → chunk-4EMNKR2T-BeYB4AEY.js} +1 -1
  94. package/editor-web/assets/{chunk-55XCU76K-CZgJYrN4.js → chunk-55XCU76K-BPFOPTBe.js} +1 -1
  95. package/editor-web/assets/{chunk-7S6XSTFO-B01FlTFf.js → chunk-7S6XSTFO-CZ2C7ULu.js} +1 -1
  96. package/editor-web/assets/{chunk-AQDTSKZB-latWUvVu.js → chunk-AQDTSKZB-B5RtsZkj.js} +1 -1
  97. package/editor-web/assets/{chunk-DSNLSHJZ-BHFiQInN.js → chunk-DSNLSHJZ-_3G4hddj.js} +1 -1
  98. package/editor-web/assets/{chunk-HAGFOTED-C4hR36ab.js → chunk-HAGFOTED-DO5b4ll2.js} +1 -1
  99. package/editor-web/assets/{chunk-HNE4Q36P-CNrxiD2Q.js → chunk-HNE4Q36P-C6XNI71Q.js} +1 -1
  100. package/editor-web/assets/{chunk-NQOKRVIF-DpyEHKEY.js → chunk-NQOKRVIF-nDCX29rQ.js} +1 -1
  101. package/editor-web/assets/{chunk-UHW7PFBP-SIEJdixh.js → chunk-UHW7PFBP-CRCOiitq.js} +1 -1
  102. package/editor-web/assets/{chunk-VQ5W62QI-CxWnQRxx.js → chunk-VQ5W62QI-hNPKKjCN.js} +1 -1
  103. package/editor-web/assets/{chunk-WQQL4CDK-CbRuCBm6.js → chunk-WQQL4CDK-KlnVtIDc.js} +1 -1
  104. package/editor-web/assets/{chunk-YZO67HFG-Cgu-EQvs.js → chunk-YZO67HFG-B76hDUrM.js} +1 -1
  105. package/editor-web/assets/{chunk-ZAUX2LTX-pAl5CV3o.js → chunk-ZAUX2LTX-D9m1N0wI.js} +1 -1
  106. package/editor-web/assets/{chunk-ZCHMQSOR-Du5hY-FP.js → chunk-ZCHMQSOR-443euxzo.js} +1 -1
  107. package/editor-web/assets/{classDiagram-v2-4MYWR3UA-CevU94T6.js → classDiagram-v2-4MYWR3UA-Bbw-8Ons.js} +1 -1
  108. package/editor-web/assets/{collaborator-C6IJkcGR.js → collaborator-2qfw-8OJ.js} +1 -1
  109. package/editor-web/assets/{cynefin-EF2NZ3EQ-DBHwpMRJ.js → cynefin-EF2NZ3EQ-C4E7TlUr.js} +1 -1
  110. package/editor-web/assets/{cynefinDiagram-WF24UDRP-CxUzpjvG.js → cynefinDiagram-WF24UDRP-PBPGa_HS.js} +1 -1
  111. package/editor-web/assets/{dagre-NK4GIZVX-BAJNBDYO.js → dagre-NK4GIZVX-DwXdEtQG.js} +1 -1
  112. package/editor-web/assets/{diagram-CBK3MWTC-BQW9Fbw-.js → diagram-CBK3MWTC-BE3FwdX7.js} +1 -1
  113. package/editor-web/assets/{diagram-I5XIIV2D-DQBROUfn.js → diagram-I5XIIV2D-BPl2ZY33.js} +1 -1
  114. package/editor-web/assets/{diagram-ODIL2UCW-DEoK31qy.js → diagram-ODIL2UCW-BLVPYSzw.js} +1 -1
  115. package/editor-web/assets/{diagram-PFBEJUXE-BTCa2We1.js → diagram-PFBEJUXE-BVZk62FO.js} +1 -1
  116. package/editor-web/assets/{diagram-RJA3I4VV-DNM8qWC3.js → diagram-RJA3I4VV-Z75LSbxH.js} +1 -1
  117. package/editor-web/assets/{diagram-TYUNFSNR-BcKpED4d.js → diagram-TYUNFSNR-BynGqDAg.js} +1 -1
  118. package/editor-web/assets/{dist-RkxskWGK.js → dist--ijXGgvi.js} +4 -4
  119. package/editor-web/assets/dist-BrGYx10E.js +2 -0
  120. package/editor-web/assets/{dist-Dpet39Yp.js → dist-C-yi9AAi.js} +27 -27
  121. package/editor-web/assets/dist-CIQUbiAd.js +38 -0
  122. package/editor-web/assets/{dist-BSPs7tZR.js → dist-Ch34PllS.js} +1 -1
  123. package/editor-web/assets/dist-CxlIyluY.js +43 -0
  124. package/editor-web/assets/{dist-DMZ1VHPK.js → dist-D9N4Fxqr.js} +1 -1
  125. package/editor-web/assets/dist-DWKEqAou.js +6 -0
  126. package/editor-web/assets/{dist-aANR6S2I.js → dist-DX0VLTRV.js} +3 -3
  127. package/editor-web/assets/dist-D_xVYGnk.js +45 -0
  128. package/editor-web/assets/dist-Nc_h0Jye.js +4 -0
  129. package/editor-web/assets/dist-UG2TIZxP.js +16 -0
  130. package/editor-web/assets/dist-VP4ECMOk.js +1 -0
  131. package/editor-web/assets/dist-cUeSwqws.js +1 -0
  132. package/editor-web/assets/dist-xpAaABxb.js +24 -0
  133. package/editor-web/assets/{ebnfDiagram-V4P3TTPT-D-1x27Eh.js → ebnfDiagram-V4P3TTPT-SwhqbeK4.js} +1 -1
  134. package/editor-web/assets/{elk-QONTBCTQ-BJSCxiTH.js → elk-QONTBCTQ-Bb1GSt2Z.js} +1 -1
  135. package/editor-web/assets/{erDiagram-KYQIGQAA-C7Q357iD.js → erDiagram-KYQIGQAA-qUy0NDKn.js} +1 -1
  136. package/editor-web/assets/{eventmodeling-K75KTNOO-kXrQLSF5.js → eventmodeling-K75KTNOO-BYBYso_j.js} +1 -1
  137. package/editor-web/assets/file-exclamation-point-C_fX4fpI.js +1 -0
  138. package/editor-web/assets/flowDiagram-IUGLLWBU-BSCBBtP3.js +1 -0
  139. package/editor-web/assets/{ganttDiagram-R7GPNTJY-Bt3SRgK7.js → ganttDiagram-R7GPNTJY-Cw-BkZT8.js} +1 -1
  140. package/editor-web/assets/{gitGraph-VSP46ZUC-DS4CkhfK.js → gitGraph-VSP46ZUC-CTXzWPq_.js} +1 -1
  141. package/editor-web/assets/{gitGraphDiagram-PDYL7XHY-BgfmSVdI.js → gitGraphDiagram-PDYL7XHY-Jd9HU3WA.js} +1 -1
  142. package/editor-web/assets/{hint-BmRKl2nL.js → hint-mQB8slJ2.js} +1 -1
  143. package/editor-web/assets/index-Br4a-QEv.css +2 -0
  144. package/editor-web/assets/index-CglHrLRS.js +28 -0
  145. package/editor-web/assets/{info-OHQRW6UA-BZjctF3x.js → info-OHQRW6UA-C4oj5BpF.js} +1 -1
  146. package/editor-web/assets/{infoDiagram-MVDRKAX5-BAp5oUXk.js → infoDiagram-MVDRKAX5-D09aYJ28.js} +1 -1
  147. package/editor-web/assets/{ishikawaDiagram-HPEHV2GE-DGL7ZfUu.js → ishikawaDiagram-HPEHV2GE-BEdXoXb2.js} +1 -1
  148. package/editor-web/assets/{journeyDiagram-BOSHW7O7-DOOoBGx-.js → journeyDiagram-BOSHW7O7-DE-_0aww.js} +1 -1
  149. package/editor-web/assets/{kanban-definition-FNSA4HC5-lbLuUiMW.js → kanban-definition-FNSA4HC5-Cn3_bvPS.js} +1 -1
  150. package/editor-web/assets/{mermaid-parser.core-RkCFmJcg.js → mermaid-parser.core-BK52JMZH.js} +3 -3
  151. package/editor-web/assets/{mermaid.core-BVUl-afX.js → mermaid.core-CmfBU89G.js} +4 -4
  152. package/editor-web/assets/{mindmap-definition-6OY57UG3-C3DC4T1J.js → mindmap-definition-6OY57UG3-CtUhkv9I.js} +1 -1
  153. package/editor-web/assets/{packet-JDAUHWVQ-Bkd6YpX8.js → packet-JDAUHWVQ-C7nciBNp.js} +1 -1
  154. package/editor-web/assets/pdf-BHx8b9rl.js +54 -0
  155. package/editor-web/assets/pdf.worker.min-CjEcRF4W.mjs +28 -0
  156. package/editor-web/assets/pdf.worker.min-DI4FfYVf.js +1 -0
  157. package/editor-web/assets/{pegDiagram-ECIUJNBX-B5Seh4Oe.js → pegDiagram-ECIUJNBX-DUkbAcTs.js} +1 -1
  158. package/editor-web/assets/{pie-XZMESJXO-BNbb4Q8k.js → pie-XZMESJXO-BIGyKhav.js} +1 -1
  159. package/editor-web/assets/{pieDiagram-GNMPY74T-_hnbUloZ.js → pieDiagram-GNMPY74T-DrYj-JeG.js} +1 -1
  160. package/editor-web/assets/{progress-D6wSFdpY.js → progress-udl4pNsP.js} +1 -1
  161. package/editor-web/assets/{props-form-BfwEi6jW.js → props-form-DrZYDmSM.js} +1 -1
  162. package/editor-web/assets/{quadrantDiagram-D57K4MC3-1rbqW-KO.js → quadrantDiagram-D57K4MC3-qkBoh1ep.js} +1 -1
  163. package/editor-web/assets/{radar-ABXABTNO-BWSnhBSp.js → radar-ABXABTNO-BkJmvR6a.js} +1 -1
  164. package/editor-web/assets/{railroad-I3PHUGI6-BNB-OKs1.js → railroad-I3PHUGI6-BFH-ip4B.js} +1 -1
  165. package/editor-web/assets/{railroad-abnf-LNEFI6M7-BKgidf_B.js → railroad-abnf-LNEFI6M7-BBlzHL6Z.js} +1 -1
  166. package/editor-web/assets/{railroad-ebnf-DWYD2UWJ-CNCnxtHp.js → railroad-ebnf-DWYD2UWJ-CCVsG0ui.js} +1 -1
  167. package/editor-web/assets/{railroad-peg-JR7BVNR7-CyBW6_0o.js → railroad-peg-JR7BVNR7-Puo7BFPl.js} +1 -1
  168. package/editor-web/assets/{railroadDiagram-Y72NRBL7-Cud3SJ7O.js → railroadDiagram-Y72NRBL7-DCwfkv35.js} +1 -1
  169. package/editor-web/assets/{requirementDiagram-EQYSW5RA-BrSCcpqV.js → requirementDiagram-EQYSW5RA-DSTcDj32.js} +1 -1
  170. package/editor-web/assets/{row-VwyPfa1b.js → row-dgHEAE7h.js} +1 -1
  171. package/editor-web/assets/{sankeyDiagram-SY24JHO5-rJV4dJFn.js → sankeyDiagram-SY24JHO5-Kqq4fCvG.js} +1 -1
  172. package/editor-web/assets/schemas-B89k2jEC.js +1 -0
  173. package/editor-web/assets/scissors-BURkYWPv.js +1 -0
  174. package/editor-web/assets/search-jKDvFIEU.js +1 -0
  175. package/editor-web/assets/{sequenceDiagram-BLEHNHQU-CEUuD2n6.js → sequenceDiagram-BLEHNHQU-B1uodEgL.js} +1 -1
  176. package/editor-web/assets/{session-DE0fvAcs.js → session-CUCSWPTE.js} +1 -1
  177. package/editor-web/assets/{slides-BgacyjJW.js → slides-BdaWgL_N.js} +1 -1
  178. package/editor-web/assets/{snapshots-D8TtZp1x.js → snapshots-CTS2iez5.js} +1 -1
  179. package/editor-web/assets/{split-Cx2MMnC_.js → split-Cu0fidVK.js} +1 -1
  180. package/editor-web/assets/{stateDiagram-v2-A6IESKWZ-BRE_C2he.js → stateDiagram-v2-A6IESKWZ-B6gG3vUm.js} +1 -1
  181. package/editor-web/assets/surface-D9qJjJQL.js +1 -0
  182. package/editor-web/assets/swatch-S8YuBYyj.js +1 -0
  183. package/editor-web/assets/{swimlanes-B3ENRKFQ-BEPqWgVe.js → swimlanes-B3ENRKFQ-CZayRtvU.js} +1 -1
  184. package/editor-web/assets/swimlanesDiagram-AYQRV4AK-B9tLTrym.js +8 -0
  185. package/editor-web/assets/{switch-DaG6OuAi.js → switch-D5kPl2jO.js} +1 -1
  186. package/editor-web/assets/syntax-DSsHrzWF.js +1 -0
  187. package/editor-web/assets/{syntax-CLaCSmoi.js → syntax-PERQ2szW.js} +1 -1
  188. package/editor-web/assets/tabs-B_K0Db1I.js +1 -0
  189. package/editor-web/assets/textarea-mzr9Kfuf.js +1 -0
  190. package/editor-web/assets/{timeline-definition-JXYKGLGB-p8Qeg4pS.js → timeline-definition-JXYKGLGB-5YoY8Xhw.js} +1 -1
  191. package/editor-web/assets/{treeView-D4JQ5SDB-C9FTdXKq.js → treeView-D4JQ5SDB-Brd_NUPx.js} +1 -1
  192. package/editor-web/assets/{treemap-SAJKECNS-XAeLVOtI.js → treemap-SAJKECNS-DmfdnlWl.js} +1 -1
  193. package/editor-web/assets/{usecaseDiagram-WPOLBNNX-BV3AMRuH.js → usecaseDiagram-WPOLBNNX-lcAkMviI.js} +1 -1
  194. package/editor-web/assets/{vennDiagram-Q3Y3IDCW-CJdKcYyA.js → vennDiagram-Q3Y3IDCW-DY_n48hQ.js} +1 -1
  195. package/editor-web/assets/{video-He8p6dr6.js → video-Bv3rETBU.js} +1 -1
  196. package/editor-web/assets/w3c-keyname-BOAvb0qz.js +1 -0
  197. package/editor-web/assets/{wardley-7MLQ67FV-DZh6Mf22.js → wardley-7MLQ67FV-DzIFSBQz.js} +1 -1
  198. package/editor-web/assets/{wardleyDiagram-IVAIDKWA-XtvKSX-m.js → wardleyDiagram-IVAIDKWA-CsXNajIg.js} +1 -1
  199. package/editor-web/assets/whole-word-6DliXke2.js +1 -0
  200. package/editor-web/assets/{words-CjW-1tZI.js → words-BTRrBFUo.js} +1 -1
  201. package/editor-web/assets/{words-CPHp_0tt.js → words-ll_94CD2.js} +1 -1
  202. package/editor-web/assets/{xychartDiagram-4URNHDU4-CGkL42sz.js → xychartDiagram-4URNHDU4-DDpGFEum.js} +1 -1
  203. package/editor-web/index.html +4 -4
  204. package/package.json +2 -8
  205. package/dist/commands/frames/report.js +0 -2
  206. package/dist/node_modules/@allyhub/report-extension/dist/build.js +0 -2
  207. package/dist/node_modules/@allyhub/report-extension/dist/check.js +0 -3
  208. package/dist/node_modules/@allyhub/report-extension/dist/cli/find.js +0 -2
  209. package/dist/node_modules/@allyhub/report-extension/dist/cli/index.js +0 -5
  210. package/dist/node_modules/@allyhub/report-extension/dist/cli/picture.js +0 -30
  211. package/dist/node_modules/@allyhub/report-extension/dist/export.js +0 -2
  212. package/dist/node_modules/@allyhub/report-extension/dist/inline.js +0 -58
  213. package/dist/node_modules/@allyhub/report-extension/dist/page.js +0 -21
  214. package/dist/node_modules/@allyhub/report-extension/dist/project-tools.js +0 -21
  215. package/dist/node_modules/@allyhub/report-extension/dist/styles.js +0 -5
  216. package/dist/node_modules/@allyhub/report-extension/dist/theme.js +0 -2
  217. package/dist/node_modules/@allyhub/report-extension/dist/tools.js +0 -2
  218. package/dist/node_modules/@allyhub/report-extension/dist/workspace.js +0 -2
  219. package/dist/node_modules/@allyhub/report-extension/package.json +0 -182
  220. package/dist/node_modules/@allyhub/report-extension/styles/allyhub/STYLE.md +0 -139
  221. package/dist/node_modules/@allyhub/report-extension/styles/allyhub/style.css +0 -109
  222. package/dist/node_modules/@allyhub/report-extension/styles/allyhub/style.json +0 -17
  223. package/dist/node_modules/@allyhub/report-extension/styles/allyhub/tokens.js +0 -40
  224. package/editor-web/assets/button-EftXSfev.js +0 -41
  225. package/editor-web/assets/channel-BFbXY6R0.js +0 -1
  226. package/editor-web/assets/dist-90dg0B0d.js +0 -2
  227. package/editor-web/assets/dist-CP9XwbBS.js +0 -45
  228. package/editor-web/assets/dist-CRxtC7DG.js +0 -24
  229. package/editor-web/assets/dist-Cmnq14RO.js +0 -6
  230. package/editor-web/assets/dist-CrZwqOm2.js +0 -1
  231. package/editor-web/assets/dist-CzUWTcvC.js +0 -38
  232. package/editor-web/assets/dist-DYnXIW8F.js +0 -16
  233. package/editor-web/assets/dist-Dre4Cwpz.js +0 -1
  234. package/editor-web/assets/dist-qSuFWuVB.js +0 -4
  235. package/editor-web/assets/flowDiagram-IUGLLWBU-GSC4btef.js +0 -1
  236. package/editor-web/assets/index-D8qc_ipi.js +0 -28
  237. package/editor-web/assets/index-DDtZpLDF.css +0 -2
  238. package/editor-web/assets/palette-INFK0Zsr.js +0 -1
  239. package/editor-web/assets/scissors-D9WmgvNP.js +0 -1
  240. package/editor-web/assets/swatch-lxK4C8fD.js +0 -1
  241. package/editor-web/assets/swimlanesDiagram-AYQRV4AK-DAcNszZ6.js +0 -8
  242. package/editor-web/assets/syntax-9LD8MzGy.js +0 -1
  243. package/editor-web/assets/tabs-DjhzblAG.js +0 -1
  244. package/editor-web/assets/trash-2-DrnRa91l.js +0 -1
  245. /package/dist/node_modules/@allyhub/{report-extension → text-extension}/LICENSE +0 -0
@@ -1,54 +1,54 @@
1
- import"./rolldown-runtime-COiEfhsA.js";import{v as e}from"./react-Bk7NnOLX.js";import{gt as t}from"./button-EftXSfev.js";import{t as n}from"./jsx-runtime-DePvh3-m.js";var r=Symbol.for(`yaml.alias`),i=Symbol.for(`yaml.document`),a=Symbol.for(`yaml.map`),o=Symbol.for(`yaml.pair`),s=Symbol.for(`yaml.scalar`),c=Symbol.for(`yaml.seq`),l=Symbol.for(`yaml.node.type`),u=e=>!!e&&typeof e==`object`&&e[l]===r,d=e=>!!e&&typeof e==`object`&&e[l]===i,f=e=>!!e&&typeof e==`object`&&e[l]===a,p=e=>!!e&&typeof e==`object`&&e[l]===o,m=e=>!!e&&typeof e==`object`&&e[l]===s,h=e=>!!e&&typeof e==`object`&&e[l]===c;function g(e){if(e&&typeof e==`object`)switch(e[l]){case a:case c:return!0}return!1}function _(e){if(e&&typeof e==`object`)switch(e[l]){case r:case a:case s:case c:return!0}return!1}var v=e=>(m(e)||g(e))&&!!e.anchor,y=Symbol(`break visit`),b=Symbol(`skip children`),x=Symbol(`remove node`);function S(e,t){let n=ee(t);d(e)?C(null,e.contents,n,Object.freeze([e]))===x&&(e.contents=null):C(null,e,n,Object.freeze([]))}S.BREAK=y,S.SKIP=b,S.REMOVE=x;function C(e,t,n,r){let i=w(e,t,n,r);if(_(i)||p(i))return T(e,r,i),C(e,i,n,r);if(typeof i!=`symbol`){if(g(t)){r=Object.freeze(r.concat(t));for(let e=0;e<t.items.length;++e){let i=C(e,t.items[e],n,r);if(typeof i==`number`)e=i-1;else if(i===y)return y;else i===x&&(t.items.splice(e,1),--e)}}else if(p(t)){r=Object.freeze(r.concat(t));let e=C(`key`,t.key,n,r);if(e===y)return y;e===x&&(t.key=null);let i=C(`value`,t.value,n,r);if(i===y)return y;i===x&&(t.value=null)}}return i}function ee(e){return typeof e==`object`&&(e.Collection||e.Node||e.Value)?Object.assign({Alias:e.Node,Map:e.Node,Scalar:e.Node,Seq:e.Node},e.Value&&{Map:e.Value,Scalar:e.Value,Seq:e.Value},e.Collection&&{Map:e.Collection,Seq:e.Collection},e):e}function w(e,t,n,r){if(typeof n==`function`)return n(e,t,r);if(f(t))return n.Map?.(e,t,r);if(h(t))return n.Seq?.(e,t,r);if(p(t))return n.Pair?.(e,t,r);if(m(t))return n.Scalar?.(e,t,r);if(u(t))return n.Alias?.(e,t,r)}function T(e,t,n){let r=t[t.length-1];if(g(r))r.items[e]=n;else if(p(r))e===`key`?r.key=n:r.value=n;else if(d(r))r.contents=n;else{let e=u(r)?`alias`:`scalar`;throw Error(`Cannot replace node with ${e} parent`)}}var te={"!":`%21`,",":`%2C`,"[":`%5B`,"]":`%5D`,"{":`%7B`,"}":`%7D`},ne=e=>e.replace(/[!,[\]{}]/g,e=>te[e]),E=class e{constructor(t,n){this.docStart=null,this.docEnd=!1,this.yaml=Object.assign({},e.defaultYaml,t),this.tags=Object.assign({},e.defaultTags,n)}clone(){let t=new e(this.yaml,this.tags);return t.docStart=this.docStart,t}atDocument(){let t=new e(this.yaml,this.tags);switch(this.yaml.version){case`1.1`:this.atNextDocument=!0;break;case`1.2`:this.atNextDocument=!1,this.yaml={explicit:e.defaultYaml.explicit,version:`1.2`},this.tags=Object.assign({},e.defaultTags)}return t}add(t,n){this.atNextDocument&&=(this.yaml={explicit:e.defaultYaml.explicit,version:`1.1`},this.tags=Object.assign({},e.defaultTags),!1);let r=t.trim().split(/[ \t]+/),i=r.shift();switch(i){case`%TAG`:{if(r.length!==2&&(n(0,`%TAG directive should contain exactly two parts`),r.length<2))return!1;let[e,t]=r;return this.tags[e]=t,!0}case`%YAML`:{if(this.yaml.explicit=!0,r.length!==1)return n(0,`%YAML directive should contain exactly one part`),!1;let[e]=r;if(e===`1.1`||e===`1.2`)return this.yaml.version=e,!0;{let t=/^\d+\.\d+$/.test(e);return n(6,`Unsupported YAML version ${e}`,t),!1}}default:return n(0,`Unknown directive ${i}`,!0),!1}}tagName(e,t){if(e===`!`)return`!`;if(e[0]!==`!`)return t(`Not a valid tag: ${e}`),null;if(e[1]===`<`){let n=e.slice(2,-1);return n===`!`||n===`!!`?(t(`Verbatim tags aren't resolved, so ${e} is invalid.`),null):(e[e.length-1]!==`>`&&t(`Verbatim tags must end with a >`),n)}let[,n,r]=e.match(/^(.*!)([^!]*)$/s);r||t(`The ${e} tag has no suffix`);let i=this.tags[n];if(i)try{return i+decodeURIComponent(r)}catch(e){return t(String(e)),null}return n===`!`?e:(t(`Could not resolve tag: ${e}`),null)}tagString(e){for(let[t,n]of Object.entries(this.tags))if(e.startsWith(n))return t+ne(e.substring(n.length));return e[0]===`!`?e:`!<${e}>`}toString(e){let t=this.yaml.explicit?[`%YAML ${this.yaml.version||`1.2`}`]:[],n=Object.entries(this.tags),r;if(e&&n.length>0&&_(e.contents)){let t={};S(e.contents,(e,n)=>{_(n)&&n.tag&&(t[n.tag]=!0)}),r=Object.keys(t)}else r=[];for(let[i,a]of n)i===`!!`&&a===`tag:yaml.org,2002:`||e&&!r.some(e=>e.startsWith(a))||t.push(`%TAG ${i} ${a}`);return t.join(`
2
- `)}};E.defaultYaml={explicit:!1,version:`1.2`},E.defaultTags={"!!":`tag:yaml.org,2002:`};function re(e){if(/[\x00-\x19\s,[\]{}]/.test(e)){let t=`Anchor must not contain whitespace or control characters: ${JSON.stringify(e)}`;throw Error(t)}return!0}function ie(e){let t=new Set;return S(e,{Value(e,n){n.anchor&&t.add(n.anchor)}}),t}function ae(e,t){for(let n=1;;++n){let r=`${e}${n}`;if(!t.has(r))return r}}function oe(e,t){let n=[],r=new Map,i=null;return{onAnchor:r=>{n.push(r),i??=ie(e);let a=ae(t,i);return i.add(a),a},setAnchors:()=>{for(let e of n){let t=r.get(e);if(typeof t==`object`&&t.anchor&&(m(t.node)||g(t.node)))t.node.anchor=t.anchor;else{let t=Error(`Failed to resolve repeated object (this should not happen)`);throw t.source=e,t}}},sourceObjects:r}}function D(e,t,n,r){if(r&&typeof r==`object`){if(Array.isArray(r))for(let t=0,n=r.length;t<n;++t){let n=r[t],i=D(e,r,String(t),n);i===void 0?delete r[t]:i!==n&&(r[t]=i)}else if(r instanceof Map)for(let t of Array.from(r.keys())){let n=r.get(t),i=D(e,r,t,n);i===void 0?r.delete(t):i!==n&&r.set(t,i)}else if(r instanceof Set)for(let t of Array.from(r)){let n=D(e,r,t,t);n===void 0?r.delete(t):n!==t&&(r.delete(t),r.add(n))}else for(let[t,n]of Object.entries(r)){let i=D(e,r,t,n);i===void 0?delete r[t]:i!==n&&(r[t]=i)}}return e.call(t,n,r)}function O(e,t,n){if(Array.isArray(e))return e.map((e,t)=>O(e,String(t),n));if(e&&typeof e.toJSON==`function`){if(!n||!v(e))return e.toJSON(t,n);let r={aliasCount:0,count:1,res:void 0};n.anchors.set(e,r),n.onCreate=e=>{r.res=e,delete n.onCreate};let i=e.toJSON(t,n);return n.onCreate&&n.onCreate(i),i}return typeof e==`bigint`&&!n?.keep?Number(e):e}var se=class{constructor(e){Object.defineProperty(this,l,{value:e})}clone(){let e=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));return this.range&&(e.range=this.range.slice()),e}toJS(e,{mapAsMap:t,maxAliasCount:n,onAnchor:r,reviver:i}={}){if(!d(e))throw TypeError(`A document argument is required`);let a={anchors:new Map,doc:e,keep:!0,mapAsMap:t===!0,mapKeyWarned:!1,maxAliasCount:typeof n==`number`?n:100},o=O(this,``,a);if(typeof r==`function`)for(let{count:e,res:t}of a.anchors.values())r(t,e);return typeof i==`function`?D(i,{"":o},``,o):o}},ce=class extends se{constructor(e){super(r),this.source=e,Object.defineProperty(this,"tag",{set(){throw Error(`Alias nodes cannot have tags`)}})}resolve(e,t){if(t?.maxAliasCount===0)throw ReferenceError(`Alias resolution is disabled`);let n;t?.aliasResolveCache?n=t.aliasResolveCache:(n=[],S(e,{Node:(e,t)=>{(u(t)||v(t))&&n.push(t)}}),t&&(t.aliasResolveCache=n));let r;for(let e of n){if(e===this)break;e.anchor===this.source&&(r=e)}if(r&&t){let{anchors:e,doc:n,maxAliasCount:i}=t,a=e.get(r);if(a||=(O(r,null,t),e.get(r)),a?.res===void 0)throw ReferenceError(`This should not happen: Alias anchor was not resolved?`);if(i>=0&&(a.count+=1,a.aliasCount===0&&(a.aliasCount=le(n,r,e)),a.count*a.aliasCount>i))throw ReferenceError(`Excessive alias count indicates a resource exhaustion attack`)}return r}toJSON(e,t){if(!t)return{source:this.source};let n=this.resolve(t.doc,t);if(!n){let e=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw ReferenceError(e)}return t.anchors.get(n).res}toString(e,t,n){let r=`*${this.source}`;if(e){if(re(this.source),e.options.verifyAliasOrder&&!e.anchors.has(this.source)){let e=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw Error(e)}if(e.implicitKey)return`${r} `}return r}};function le(e,t,n){if(u(t)){let r=t.resolve(e),i=n&&r&&n.get(r);return i?i.count*i.aliasCount:0}if(g(t)){let r=0;for(let i of t.items){let t=le(e,i,n);t>r&&(r=t)}return r}if(p(t)){let r=le(e,t.key,n),i=le(e,t.value,n);return Math.max(r,i)}return 1}var ue=e=>!e||typeof e!=`function`&&typeof e!=`object`,k=class extends se{constructor(e){super(s),this.value=e}toJSON(e,t){return t?.keep?this.value:O(this.value,e,t)}toString(){return String(this.value)}};k.BLOCK_FOLDED=`BLOCK_FOLDED`,k.BLOCK_LITERAL=`BLOCK_LITERAL`,k.PLAIN=`PLAIN`,k.QUOTE_DOUBLE=`QUOTE_DOUBLE`,k.QUOTE_SINGLE=`QUOTE_SINGLE`;var de=`tag:yaml.org,2002:`;function fe(e,t,n){if(t){let e=n.filter(e=>e.tag===t),r=e.find(e=>!e.format)??e[0];if(!r)throw Error(`Tag ${t} not found`);return r}return n.find(t=>t.identify?.(e)&&!t.format)}function A(e,t,n){if(d(e)&&(e=e.contents),_(e))return e;if(p(e)){let t=n.schema[a].createNode?.(n.schema,null,n);return t.items.push(e),t}(e instanceof String||e instanceof Number||e instanceof Boolean||typeof BigInt<`u`&&e instanceof BigInt)&&(e=e.valueOf());let{aliasDuplicateObjects:r,onAnchor:i,onTagObj:o,schema:s,sourceObjects:l}=n,u;if(r&&e&&typeof e==`object`){if(u=l.get(e),u)return u.anchor??(u.anchor=i(e)),new ce(u.anchor);u={anchor:null,node:null},l.set(e,u)}t?.startsWith(`!!`)&&(t=de+t.slice(2));let f=fe(e,t,s.tags);if(!f){if(e&&typeof e.toJSON==`function`&&(e=e.toJSON()),!e||typeof e!=`object`){let t=new k(e);return u&&(u.node=t),t}f=e instanceof Map?s[a]:Symbol.iterator in Object(e)?s[c]:s[a]}o&&(o(f),delete n.onTagObj);let m=f?.createNode?f.createNode(n.schema,e,n):typeof f?.nodeClass?.from==`function`?f.nodeClass.from(n.schema,e,n):new k(e);return t?m.tag=t:f.default||(m.tag=f.tag),u&&(u.node=m),m}function pe(e,t,n){let r=n;for(let e=t.length-1;e>=0;--e){let n=t[e];if(typeof n==`number`&&Number.isInteger(n)&&n>=0){let e=[];e[n]=r,r=e}else r=new Map([[n,r]])}return A(r,void 0,{aliasDuplicateObjects:!1,keepUndefined:!1,onAnchor:()=>{throw Error(`This should not happen, please report a bug.`)},schema:e,sourceObjects:new Map})}var me=e=>e==null||typeof e==`object`&&!!e[Symbol.iterator]().next().done,he=class extends se{constructor(e,t){super(e),Object.defineProperty(this,"schema",{value:t,configurable:!0,enumerable:!1,writable:!0})}clone(e){let t=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));return e&&(t.schema=e),t.items=t.items.map(t=>_(t)||p(t)?t.clone(e):t),this.range&&(t.range=this.range.slice()),t}addIn(e,t){if(me(e))this.add(t);else{let[n,...r]=e,i=this.get(n,!0);if(g(i))i.addIn(r,t);else if(i===void 0&&this.schema)this.set(n,pe(this.schema,r,t));else throw Error(`Expected YAML collection at ${n}. Remaining path: ${r}`)}}deleteIn(e){let[t,...n]=e;if(n.length===0)return this.delete(t);let r=this.get(t,!0);if(g(r))return r.deleteIn(n);throw Error(`Expected YAML collection at ${t}. Remaining path: ${n}`)}getIn(e,t){let[n,...r]=e,i=this.get(n,!0);return r.length===0?!t&&m(i)?i.value:i:g(i)?i.getIn(r,t):void 0}hasAllNullValues(e){return this.items.every(t=>{if(!p(t))return!1;let n=t.value;return n==null||e&&m(n)&&n.value==null&&!n.commentBefore&&!n.comment&&!n.tag})}hasIn(e){let[t,...n]=e;if(n.length===0)return this.has(t);let r=this.get(t,!0);return g(r)?r.hasIn(n):!1}setIn(e,t){let[n,...r]=e;if(r.length===0)this.set(n,t);else{let e=this.get(n,!0);if(g(e))e.setIn(r,t);else if(e===void 0&&this.schema)this.set(n,pe(this.schema,r,t));else throw Error(`Expected YAML collection at ${n}. Remaining path: ${r}`)}}},ge=e=>e.replace(/^(?!$)(?: $)?/gm,`#`);function j(e,t){return/^\n+$/.test(e)?e.substring(1):t?e.replace(/^(?! *$)/gm,t):e}var M=(e,t,n)=>e.endsWith(`
1
+ var e=Symbol.for(`yaml.alias`),t=Symbol.for(`yaml.document`),n=Symbol.for(`yaml.map`),r=Symbol.for(`yaml.pair`),i=Symbol.for(`yaml.scalar`),a=Symbol.for(`yaml.seq`),o=Symbol.for(`yaml.node.type`),s=t=>!!t&&typeof t==`object`&&t[o]===e,c=e=>!!e&&typeof e==`object`&&e[o]===t,l=e=>!!e&&typeof e==`object`&&e[o]===n,u=e=>!!e&&typeof e==`object`&&e[o]===r,d=e=>!!e&&typeof e==`object`&&e[o]===i,f=e=>!!e&&typeof e==`object`&&e[o]===a;function p(e){if(e&&typeof e==`object`)switch(e[o]){case n:case a:return!0}return!1}function m(t){if(t&&typeof t==`object`)switch(t[o]){case e:case n:case i:case a:return!0}return!1}var h=e=>(d(e)||p(e))&&!!e.anchor,g=Symbol(`break visit`),_=Symbol(`skip children`),v=Symbol(`remove node`);function y(e,t){let n=x(t);c(e)?b(null,e.contents,n,Object.freeze([e]))===v&&(e.contents=null):b(null,e,n,Object.freeze([]))}y.BREAK=g,y.SKIP=_,y.REMOVE=v;function b(e,t,n,r){let i=S(e,t,n,r);if(m(i)||u(i))return C(e,r,i),b(e,i,n,r);if(typeof i!=`symbol`){if(p(t)){r=Object.freeze(r.concat(t));for(let e=0;e<t.items.length;++e){let i=b(e,t.items[e],n,r);if(typeof i==`number`)e=i-1;else if(i===g)return g;else i===v&&(t.items.splice(e,1),--e)}}else if(u(t)){r=Object.freeze(r.concat(t));let e=b(`key`,t.key,n,r);if(e===g)return g;e===v&&(t.key=null);let i=b(`value`,t.value,n,r);if(i===g)return g;i===v&&(t.value=null)}}return i}function x(e){return typeof e==`object`&&(e.Collection||e.Node||e.Value)?Object.assign({Alias:e.Node,Map:e.Node,Scalar:e.Node,Seq:e.Node},e.Value&&{Map:e.Value,Scalar:e.Value,Seq:e.Value},e.Collection&&{Map:e.Collection,Seq:e.Collection},e):e}function S(e,t,n,r){if(typeof n==`function`)return n(e,t,r);if(l(t))return n.Map?.(e,t,r);if(f(t))return n.Seq?.(e,t,r);if(u(t))return n.Pair?.(e,t,r);if(d(t))return n.Scalar?.(e,t,r);if(s(t))return n.Alias?.(e,t,r)}function C(e,t,n){let r=t[t.length-1];if(p(r))r.items[e]=n;else if(u(r))e===`key`?r.key=n:r.value=n;else if(c(r))r.contents=n;else{let e=s(r)?`alias`:`scalar`;throw Error(`Cannot replace node with ${e} parent`)}}var ee={"!":`%21`,",":`%2C`,"[":`%5B`,"]":`%5D`,"{":`%7B`,"}":`%7D`},w=e=>e.replace(/[!,[\]{}]/g,e=>ee[e]),T=class e{constructor(t,n){this.docStart=null,this.docEnd=!1,this.yaml=Object.assign({},e.defaultYaml,t),this.tags=Object.assign({},e.defaultTags,n)}clone(){let t=new e(this.yaml,this.tags);return t.docStart=this.docStart,t}atDocument(){let t=new e(this.yaml,this.tags);switch(this.yaml.version){case`1.1`:this.atNextDocument=!0;break;case`1.2`:this.atNextDocument=!1,this.yaml={explicit:e.defaultYaml.explicit,version:`1.2`},this.tags=Object.assign({},e.defaultTags)}return t}add(t,n){this.atNextDocument&&=(this.yaml={explicit:e.defaultYaml.explicit,version:`1.1`},this.tags=Object.assign({},e.defaultTags),!1);let r=t.trim().split(/[ \t]+/),i=r.shift();switch(i){case`%TAG`:{if(r.length!==2&&(n(0,`%TAG directive should contain exactly two parts`),r.length<2))return!1;let[e,t]=r;return this.tags[e]=t,!0}case`%YAML`:{if(this.yaml.explicit=!0,r.length!==1)return n(0,`%YAML directive should contain exactly one part`),!1;let[e]=r;if(e===`1.1`||e===`1.2`)return this.yaml.version=e,!0;{let t=/^\d+\.\d+$/.test(e);return n(6,`Unsupported YAML version ${e}`,t),!1}}default:return n(0,`Unknown directive ${i}`,!0),!1}}tagName(e,t){if(e===`!`)return`!`;if(e[0]!==`!`)return t(`Not a valid tag: ${e}`),null;if(e[1]===`<`){let n=e.slice(2,-1);return n===`!`||n===`!!`?(t(`Verbatim tags aren't resolved, so ${e} is invalid.`),null):(e[e.length-1]!==`>`&&t(`Verbatim tags must end with a >`),n)}let[,n,r]=e.match(/^(.*!)([^!]*)$/s);r||t(`The ${e} tag has no suffix`);let i=this.tags[n];if(i)try{return i+decodeURIComponent(r)}catch(e){return t(String(e)),null}return n===`!`?e:(t(`Could not resolve tag: ${e}`),null)}tagString(e){for(let[t,n]of Object.entries(this.tags))if(e.startsWith(n))return t+w(e.substring(n.length));return e[0]===`!`?e:`!<${e}>`}toString(e){let t=this.yaml.explicit?[`%YAML ${this.yaml.version||`1.2`}`]:[],n=Object.entries(this.tags),r;if(e&&n.length>0&&m(e.contents)){let t={};y(e.contents,(e,n)=>{m(n)&&n.tag&&(t[n.tag]=!0)}),r=Object.keys(t)}else r=[];for(let[i,a]of n)i===`!!`&&a===`tag:yaml.org,2002:`||e&&!r.some(e=>e.startsWith(a))||t.push(`%TAG ${i} ${a}`);return t.join(`
2
+ `)}};T.defaultYaml={explicit:!1,version:`1.2`},T.defaultTags={"!!":`tag:yaml.org,2002:`};function te(e){if(/[\x00-\x19\s,[\]{}]/.test(e)){let t=`Anchor must not contain whitespace or control characters: ${JSON.stringify(e)}`;throw Error(t)}return!0}function ne(e){let t=new Set;return y(e,{Value(e,n){n.anchor&&t.add(n.anchor)}}),t}function re(e,t){for(let n=1;;++n){let r=`${e}${n}`;if(!t.has(r))return r}}function ie(e,t){let n=[],r=new Map,i=null;return{onAnchor:r=>{n.push(r),i??=ne(e);let a=re(t,i);return i.add(a),a},setAnchors:()=>{for(let e of n){let t=r.get(e);if(typeof t==`object`&&t.anchor&&(d(t.node)||p(t.node)))t.node.anchor=t.anchor;else{let t=Error(`Failed to resolve repeated object (this should not happen)`);throw t.source=e,t}}},sourceObjects:r}}function E(e,t,n,r){if(r&&typeof r==`object`){if(Array.isArray(r))for(let t=0,n=r.length;t<n;++t){let n=r[t],i=E(e,r,String(t),n);i===void 0?delete r[t]:i!==n&&(r[t]=i)}else if(r instanceof Map)for(let t of Array.from(r.keys())){let n=r.get(t),i=E(e,r,t,n);i===void 0?r.delete(t):i!==n&&r.set(t,i)}else if(r instanceof Set)for(let t of Array.from(r)){let n=E(e,r,t,t);n===void 0?r.delete(t):n!==t&&(r.delete(t),r.add(n))}else for(let[t,n]of Object.entries(r)){let i=E(e,r,t,n);i===void 0?delete r[t]:i!==n&&(r[t]=i)}}return e.call(t,n,r)}function D(e,t,n){if(Array.isArray(e))return e.map((e,t)=>D(e,String(t),n));if(e&&typeof e.toJSON==`function`){if(!n||!h(e))return e.toJSON(t,n);let r={aliasCount:0,count:1,res:void 0};n.anchors.set(e,r),n.onCreate=e=>{r.res=e,delete n.onCreate};let i=e.toJSON(t,n);return n.onCreate&&n.onCreate(i),i}return typeof e==`bigint`&&!n?.keep?Number(e):e}var ae=class{constructor(e){Object.defineProperty(this,o,{value:e})}clone(){let e=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));return this.range&&(e.range=this.range.slice()),e}toJS(e,{mapAsMap:t,maxAliasCount:n,onAnchor:r,reviver:i}={}){if(!c(e))throw TypeError(`A document argument is required`);let a={anchors:new Map,doc:e,keep:!0,mapAsMap:t===!0,mapKeyWarned:!1,maxAliasCount:typeof n==`number`?n:100},o=D(this,``,a);if(typeof r==`function`)for(let{count:e,res:t}of a.anchors.values())r(t,e);return typeof i==`function`?E(i,{"":o},``,o):o}},oe=class extends ae{constructor(t){super(e),this.source=t,Object.defineProperty(this,"tag",{set(){throw Error(`Alias nodes cannot have tags`)}})}resolve(e,t){if(t?.maxAliasCount===0)throw ReferenceError(`Alias resolution is disabled`);let n;t?.aliasResolveCache?n=t.aliasResolveCache:(n=[],y(e,{Node:(e,t)=>{(s(t)||h(t))&&n.push(t)}}),t&&(t.aliasResolveCache=n));let r;for(let e of n){if(e===this)break;e.anchor===this.source&&(r=e)}if(r&&t){let{anchors:e,doc:n,maxAliasCount:i}=t,a=e.get(r);if(a||=(D(r,null,t),e.get(r)),a?.res===void 0)throw ReferenceError(`This should not happen: Alias anchor was not resolved?`);if(i>=0&&(a.count+=1,a.aliasCount===0&&(a.aliasCount=se(n,r,e)),a.count*a.aliasCount>i))throw ReferenceError(`Excessive alias count indicates a resource exhaustion attack`)}return r}toJSON(e,t){if(!t)return{source:this.source};let n=this.resolve(t.doc,t);if(!n){let e=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw ReferenceError(e)}return t.anchors.get(n).res}toString(e,t,n){let r=`*${this.source}`;if(e){if(te(this.source),e.options.verifyAliasOrder&&!e.anchors.has(this.source)){let e=`Unresolved alias (the anchor must be set before the alias): ${this.source}`;throw Error(e)}if(e.implicitKey)return`${r} `}return r}};function se(e,t,n){if(s(t)){let r=t.resolve(e),i=n&&r&&n.get(r);return i?i.count*i.aliasCount:0}if(p(t)){let r=0;for(let i of t.items){let t=se(e,i,n);t>r&&(r=t)}return r}if(u(t)){let r=se(e,t.key,n),i=se(e,t.value,n);return Math.max(r,i)}return 1}var ce=e=>!e||typeof e!=`function`&&typeof e!=`object`,O=class extends ae{constructor(e){super(i),this.value=e}toJSON(e,t){return t?.keep?this.value:D(this.value,e,t)}toString(){return String(this.value)}};O.BLOCK_FOLDED=`BLOCK_FOLDED`,O.BLOCK_LITERAL=`BLOCK_LITERAL`,O.PLAIN=`PLAIN`,O.QUOTE_DOUBLE=`QUOTE_DOUBLE`,O.QUOTE_SINGLE=`QUOTE_SINGLE`;var le=`tag:yaml.org,2002:`;function ue(e,t,n){if(t){let e=n.filter(e=>e.tag===t),r=e.find(e=>!e.format)??e[0];if(!r)throw Error(`Tag ${t} not found`);return r}return n.find(t=>t.identify?.(e)&&!t.format)}function k(e,t,r){if(c(e)&&(e=e.contents),m(e))return e;if(u(e)){let t=r.schema[n].createNode?.(r.schema,null,r);return t.items.push(e),t}(e instanceof String||e instanceof Number||e instanceof Boolean||typeof BigInt<`u`&&e instanceof BigInt)&&(e=e.valueOf());let{aliasDuplicateObjects:i,onAnchor:o,onTagObj:s,schema:l,sourceObjects:d}=r,f;if(i&&e&&typeof e==`object`){if(f=d.get(e),f)return f.anchor??(f.anchor=o(e)),new oe(f.anchor);f={anchor:null,node:null},d.set(e,f)}t?.startsWith(`!!`)&&(t=le+t.slice(2));let p=ue(e,t,l.tags);if(!p){if(e&&typeof e.toJSON==`function`&&(e=e.toJSON()),!e||typeof e!=`object`){let t=new O(e);return f&&(f.node=t),t}p=e instanceof Map?l[n]:Symbol.iterator in Object(e)?l[a]:l[n]}s&&(s(p),delete r.onTagObj);let h=p?.createNode?p.createNode(r.schema,e,r):typeof p?.nodeClass?.from==`function`?p.nodeClass.from(r.schema,e,r):new O(e);return t?h.tag=t:p.default||(h.tag=p.tag),f&&(f.node=h),h}function de(e,t,n){let r=n;for(let e=t.length-1;e>=0;--e){let n=t[e];if(typeof n==`number`&&Number.isInteger(n)&&n>=0){let e=[];e[n]=r,r=e}else r=new Map([[n,r]])}return k(r,void 0,{aliasDuplicateObjects:!1,keepUndefined:!1,onAnchor:()=>{throw Error(`This should not happen, please report a bug.`)},schema:e,sourceObjects:new Map})}var A=e=>e==null||typeof e==`object`&&!!e[Symbol.iterator]().next().done,fe=class extends ae{constructor(e,t){super(e),Object.defineProperty(this,"schema",{value:t,configurable:!0,enumerable:!1,writable:!0})}clone(e){let t=Object.create(Object.getPrototypeOf(this),Object.getOwnPropertyDescriptors(this));return e&&(t.schema=e),t.items=t.items.map(t=>m(t)||u(t)?t.clone(e):t),this.range&&(t.range=this.range.slice()),t}addIn(e,t){if(A(e))this.add(t);else{let[n,...r]=e,i=this.get(n,!0);if(p(i))i.addIn(r,t);else if(i===void 0&&this.schema)this.set(n,de(this.schema,r,t));else throw Error(`Expected YAML collection at ${n}. Remaining path: ${r}`)}}deleteIn(e){let[t,...n]=e;if(n.length===0)return this.delete(t);let r=this.get(t,!0);if(p(r))return r.deleteIn(n);throw Error(`Expected YAML collection at ${t}. Remaining path: ${n}`)}getIn(e,t){let[n,...r]=e,i=this.get(n,!0);return r.length===0?!t&&d(i)?i.value:i:p(i)?i.getIn(r,t):void 0}hasAllNullValues(e){return this.items.every(t=>{if(!u(t))return!1;let n=t.value;return n==null||e&&d(n)&&n.value==null&&!n.commentBefore&&!n.comment&&!n.tag})}hasIn(e){let[t,...n]=e;if(n.length===0)return this.has(t);let r=this.get(t,!0);return p(r)?r.hasIn(n):!1}setIn(e,t){let[n,...r]=e;if(r.length===0)this.set(n,t);else{let e=this.get(n,!0);if(p(e))e.setIn(r,t);else if(e===void 0&&this.schema)this.set(n,de(this.schema,r,t));else throw Error(`Expected YAML collection at ${n}. Remaining path: ${r}`)}}},pe=e=>e.replace(/^(?!$)(?: $)?/gm,`#`);function j(e,t){return/^\n+$/.test(e)?e.substring(1):t?e.replace(/^(?! *$)/gm,t):e}var M=(e,t,n)=>e.endsWith(`
3
3
  `)?j(n,t):n.includes(`
4
4
  `)?`
5
- `+j(n,t):(e.endsWith(` `)?``:` `)+n,_e=`flow`,ve=`block`,ye=`quoted`;function be(e,t,n=`flow`,{indentAtStart:r,lineWidth:i=80,minContentWidth:a=20,onFold:o,onOverflow:s}={}){if(!i||i<0)return e;i<a&&(a=0);let c=Math.max(1+a,1+i-t.length);if(e.length<=c)return e;let l=[],u={},d=i-t.length;typeof r==`number`&&(r>i-Math.max(2,a)?l.push(0):d=i-r);let f,p,m=!1,h=-1,g=-1,_=-1;n===`block`&&(h=xe(e,h,t.length),h!==-1&&(d=h+c));for(let r;r=e[h+=1];){if(n===`quoted`&&r===`\\`){switch(g=h,e[h+1]){case`x`:h+=3;break;case`u`:h+=5;break;case`U`:h+=9;break;default:h+=1}_=h}if(r===`
6
- `)n===`block`&&(h=xe(e,h,t.length)),d=h+t.length+c,f=void 0;else{if(r===` `&&p&&p!==` `&&p!==`
5
+ `+j(n,t):(e.endsWith(` `)?``:` `)+n,me=`flow`,he=`block`,ge=`quoted`;function _e(e,t,n=`flow`,{indentAtStart:r,lineWidth:i=80,minContentWidth:a=20,onFold:o,onOverflow:s}={}){if(!i||i<0)return e;i<a&&(a=0);let c=Math.max(1+a,1+i-t.length);if(e.length<=c)return e;let l=[],u={},d=i-t.length;typeof r==`number`&&(r>i-Math.max(2,a)?l.push(0):d=i-r);let f,p,m=!1,h=-1,g=-1,_=-1;n===`block`&&(h=ve(e,h,t.length),h!==-1&&(d=h+c));for(let r;r=e[h+=1];){if(n===`quoted`&&r===`\\`){switch(g=h,e[h+1]){case`x`:h+=3;break;case`u`:h+=5;break;case`U`:h+=9;break;default:h+=1}_=h}if(r===`
6
+ `)n===`block`&&(h=ve(e,h,t.length)),d=h+t.length+c,f=void 0;else{if(r===` `&&p&&p!==` `&&p!==`
7
7
  `&&p!==` `){let t=e[h+1];t&&t!==` `&&t!==`
8
- `&&t!==` `&&(f=h)}if(h>=d){if(f)l.push(f),d=f+c,f=void 0;else if(n===`quoted`){for(;p===` `||p===` `;)p=r,r=e[h+=1],m=!0;let t=h>_+1?h-2:g-1;if(u[t])return e;l.push(t),u[t]=!0,d=t+c,f=void 0}else m=!0}}p=r}if(m&&s&&s(),l.length===0)return e;o&&o();let v=e.slice(0,l[0]);for(let r=0;r<l.length;++r){let i=l[r],a=l[r+1]||e.length;i===0?v=`\n${t}${e.slice(0,a)}`:(n===`quoted`&&u[i]&&(v+=`${e[i]}\\`),v+=`\n${t}${e.slice(i+1,a)}`)}return v}function xe(e,t,n){let r=t,i=t+1,a=e[i];for(;a===` `||a===` `;)if(t<i+n)a=e[++t];else{do a=e[++t];while(a&&a!==`
9
- `);r=t,i=t+1,a=e[i]}return r}var Se=(e,t)=>({indentAtStart:t?e.indent.length:e.indentAtStart,lineWidth:e.options.lineWidth,minContentWidth:e.options.minContentWidth}),Ce=e=>/^(%|---|\.\.\.)/m.test(e);function we(e,t,n){if(!t||t<0)return!1;let r=t-n,i=e.length;if(i<=r)return!1;for(let t=0,n=0;t<i;++t)if(e[t]===`
10
- `){if(t-n>r)return!0;if(n=t+1,i-n<=r)return!1}return!0}function N(e,t){let n=JSON.stringify(e);if(t.options.doubleQuotedAsJSON)return n;let{implicitKey:r}=t,i=t.options.doubleQuotedMinMultiLineLength,a=t.indent||(Ce(e)?` `:``),o=``,s=0;for(let e=0,t=n[e];t;t=n[++e])if(t===` `&&n[e+1]===`\\`&&n[e+2]===`n`&&(o+=n.slice(s,e)+`\\ `,e+=1,s=e,t=`\\`),t===`\\`)switch(n[e+1]){case`u`:{o+=n.slice(s,e);let t=n.substr(e+2,4);switch(t){case`0000`:o+=`\\0`;break;case`0007`:o+=`\\a`;break;case`000b`:o+=`\\v`;break;case`001b`:o+=`\\e`;break;case`0085`:o+=`\\N`;break;case`00a0`:o+=`\\_`;break;case`2028`:o+=`\\L`;break;case`2029`:o+=`\\P`;break;default:t.substr(0,2)===`00`?o+=`\\x`+t.substr(2):o+=n.substr(e,6)}e+=5,s=e+1}break;case`n`:if(r||n[e+2]===`"`||n.length<i)e+=1;else{for(o+=n.slice(s,e)+`
8
+ `&&t!==` `&&(f=h)}if(h>=d){if(f)l.push(f),d=f+c,f=void 0;else if(n===`quoted`){for(;p===` `||p===` `;)p=r,r=e[h+=1],m=!0;let t=h>_+1?h-2:g-1;if(u[t])return e;l.push(t),u[t]=!0,d=t+c,f=void 0}else m=!0}}p=r}if(m&&s&&s(),l.length===0)return e;o&&o();let v=e.slice(0,l[0]);for(let r=0;r<l.length;++r){let i=l[r],a=l[r+1]||e.length;i===0?v=`\n${t}${e.slice(0,a)}`:(n===`quoted`&&u[i]&&(v+=`${e[i]}\\`),v+=`\n${t}${e.slice(i+1,a)}`)}return v}function ve(e,t,n){let r=t,i=t+1,a=e[i];for(;a===` `||a===` `;)if(t<i+n)a=e[++t];else{do a=e[++t];while(a&&a!==`
9
+ `);r=t,i=t+1,a=e[i]}return r}var ye=(e,t)=>({indentAtStart:t?e.indent.length:e.indentAtStart,lineWidth:e.options.lineWidth,minContentWidth:e.options.minContentWidth}),be=e=>/^(%|---|\.\.\.)/m.test(e);function xe(e,t,n){if(!t||t<0)return!1;let r=t-n,i=e.length;if(i<=r)return!1;for(let t=0,n=0;t<i;++t)if(e[t]===`
10
+ `){if(t-n>r)return!0;if(n=t+1,i-n<=r)return!1}return!0}function N(e,t){let n=JSON.stringify(e);if(t.options.doubleQuotedAsJSON)return n;let{implicitKey:r}=t,i=t.options.doubleQuotedMinMultiLineLength,a=t.indent||(be(e)?` `:``),o=``,s=0;for(let e=0,t=n[e];t;t=n[++e])if(t===` `&&n[e+1]===`\\`&&n[e+2]===`n`&&(o+=n.slice(s,e)+`\\ `,e+=1,s=e,t=`\\`),t===`\\`)switch(n[e+1]){case`u`:{o+=n.slice(s,e);let t=n.substr(e+2,4);switch(t){case`0000`:o+=`\\0`;break;case`0007`:o+=`\\a`;break;case`000b`:o+=`\\v`;break;case`001b`:o+=`\\e`;break;case`0085`:o+=`\\N`;break;case`00a0`:o+=`\\_`;break;case`2028`:o+=`\\L`;break;case`2029`:o+=`\\P`;break;default:t.substr(0,2)===`00`?o+=`\\x`+t.substr(2):o+=n.substr(e,6)}e+=5,s=e+1}break;case`n`:if(r||n[e+2]===`"`||n.length<i)e+=1;else{for(o+=n.slice(s,e)+`
11
11
 
12
12
  `;n[e+2]===`\\`&&n[e+3]===`n`&&n[e+4]!==`"`;)o+=`
13
- `,e+=2;o+=a,n[e+2]===` `&&(o+=`\\`),e+=1,s=e+1}break;default:e+=1}return o=s?o+n.slice(s):n,r?o:be(o,a,ye,Se(t,!1))}function Te(e,t){if(t.options.singleQuote===!1||t.implicitKey&&e.includes(`
14
- `)||/[ \t]\n|\n[ \t]/.test(e))return N(e,t);let n=t.indent||(Ce(e)?` `:``),r=`'`+e.replace(/'/g,`''`).replace(/\n+/g,`$&\n${n}`)+`'`;return t.implicitKey?r:be(r,n,_e,Se(t,!1))}function P(e,t){let{singleQuote:n}=t.options,r;if(n===!1)r=N;else{let t=e.includes(`"`),i=e.includes(`'`);r=t&&!i?Te:i&&!t?N:n?Te:N}return r(e,t)}var Ee;try{Ee=RegExp(`(^|(?<!
13
+ `,e+=2;o+=a,n[e+2]===` `&&(o+=`\\`),e+=1,s=e+1}break;default:e+=1}return o=s?o+n.slice(s):n,r?o:_e(o,a,ge,ye(t,!1))}function Se(e,t){if(t.options.singleQuote===!1||t.implicitKey&&e.includes(`
14
+ `)||/[ \t]\n|\n[ \t]/.test(e))return N(e,t);let n=t.indent||(be(e)?` `:``),r=`'`+e.replace(/'/g,`''`).replace(/\n+/g,`$&\n${n}`)+`'`;return t.implicitKey?r:_e(r,n,me,ye(t,!1))}function P(e,t){let{singleQuote:n}=t.options,r;if(n===!1)r=N;else{let t=e.includes(`"`),i=e.includes(`'`);r=t&&!i?Se:i&&!t?N:n?Se:N}return r(e,t)}var Ce;try{Ce=RegExp(`(^|(?<!
15
15
  ))
16
16
  +(?!
17
- |$)`,`g`)}catch{Ee=/\n+(?!\n|$)/g}function De({comment:e,type:t,value:n},r,i,a){let{blockQuote:o,commentString:s,lineWidth:c}=r.options;if(!o||/\n[\t ]+$/.test(n))return P(n,r);let l=r.indent||(r.forceBlockIndent||Ce(n)?` `:``),u=o===`literal`?!0:o===`folded`||t===k.BLOCK_FOLDED?!1:t===k.BLOCK_LITERAL||!we(n,c,l.length);if(!n)return u?`|
17
+ |$)`,`g`)}catch{Ce=/\n+(?!\n|$)/g}function we({comment:e,type:t,value:n},r,i,a){let{blockQuote:o,commentString:s,lineWidth:c}=r.options;if(!o||/\n[\t ]+$/.test(n))return P(n,r);let l=r.indent||(r.forceBlockIndent||be(n)?` `:``),u=o===`literal`?!0:o===`folded`||t===O.BLOCK_FOLDED?!1:t===O.BLOCK_LITERAL||!xe(n,c,l.length);if(!n)return u?`|
18
18
  `:`>
19
19
  `;let d,f;for(f=n.length;f>0;--f){let e=n[f-1];if(e!==`
20
20
  `&&e!==` `&&e!==` `)break}let p=n.substring(f),m=p.indexOf(`
21
21
  `);m===-1?d=`-`:n===p||m!==p.length-1?(d=`+`,a&&a()):d=``,p&&=(n=n.slice(0,-p.length),p[p.length-1]===`
22
- `&&(p=p.slice(0,-1)),p.replace(Ee,`$&${l}`));let h=!1,g,_=-1;for(g=0;g<n.length;++g){let e=n[g];if(e===` `)h=!0;else if(e===`
22
+ `&&(p=p.slice(0,-1)),p.replace(Ce,`$&${l}`));let h=!1,g,_=-1;for(g=0;g<n.length;++g){let e=n[g];if(e===` `)h=!0;else if(e===`
23
23
  `)_=g;else break}let v=n.substring(0,_<g?_+1:g);v&&=(n=n.substring(v.length),v.replace(/\n+/g,`$&${l}`));let y=(h?l?`2`:`1`:``)+d;if(e&&(y+=` `+s(e.replace(/ ?[\r\n]+/g,` `)),i&&i()),!u){let e=n.replace(/\n+/g,`
24
- $&`).replace(/(?:^|\n)([\t ].*)(?:([\n\t ]*)\n(?![\n\t ]))?/g,`$1$2`).replace(/\n+/g,`$&${l}`),i=!1,a=Se(r,!0);o!==`folded`&&t!==k.BLOCK_FOLDED&&(a.onOverflow=()=>{i=!0});let s=be(`${v}${e}${p}`,l,ve,a);if(!i)return`>${y}\n${l}${s}`}return n=n.replace(/\n+/g,`$&${l}`),`|${y}\n${l}${v}${n}${p}`}function Oe(e,t,n,r){let{type:i,value:a}=e,{actualString:o,implicitKey:s,indent:c,indentStep:l,inFlow:u}=t;if(s&&a.includes(`
24
+ $&`).replace(/(?:^|\n)([\t ].*)(?:([\n\t ]*)\n(?![\n\t ]))?/g,`$1$2`).replace(/\n+/g,`$&${l}`),i=!1,a=ye(r,!0);o!==`folded`&&t!==O.BLOCK_FOLDED&&(a.onOverflow=()=>{i=!0});let s=_e(`${v}${e}${p}`,l,he,a);if(!i)return`>${y}\n${l}${s}`}return n=n.replace(/\n+/g,`$&${l}`),`|${y}\n${l}${v}${n}${p}`}function Te(e,t,n,r){let{type:i,value:a}=e,{actualString:o,implicitKey:s,indent:c,indentStep:l,inFlow:u}=t;if(s&&a.includes(`
25
25
  `)||u&&/[[\]{},]/.test(a))return P(a,t);if(/^[\n\t ,[\]{}#&*!|>'"%@`]|^[?-]$|^[?-][ \t]|[\n:][ \t]|[ \t]\n|[\n\t ]#|[\n\t :]$/.test(a))return s||u||!a.includes(`
26
- `)?P(a,t):De(e,t,n,r);if(!s&&!u&&i!==k.PLAIN&&a.includes(`
27
- `))return De(e,t,n,r);if(Ce(a)){if(c===``)return t.forceBlockIndent=!0,De(e,t,n,r);if(s&&c===l)return P(a,t)}let d=a.replace(/\n+/g,`$&\n${c}`);if(o){let e=e=>e.default&&e.tag!==`tag:yaml.org,2002:str`&&e.test?.test(d),{compat:n,tags:r}=t.doc.schema;if(r.some(e)||n?.some(e))return P(a,t)}return s?d:be(d,c,_e,Se(t,!1))}function ke(e,t,n,r){let{implicitKey:i,inFlow:a}=t,o=typeof e.value==`string`?e:Object.assign({},e,{value:String(e.value)}),{type:s}=e;s!==k.QUOTE_DOUBLE&&/[\x00-\x08\x0b-\x1f\x7f-\x9f\u{D800}-\u{DFFF}]/u.test(o.value)&&(s=k.QUOTE_DOUBLE);let c=e=>{switch(e){case k.BLOCK_FOLDED:case k.BLOCK_LITERAL:return i||a?P(o.value,t):De(o,t,n,r);case k.QUOTE_DOUBLE:return N(o.value,t);case k.QUOTE_SINGLE:return Te(o.value,t);case k.PLAIN:return Oe(o,t,n,r);default:return null}},l=c(s);if(l===null){let{defaultKeyType:e,defaultStringType:n}=t.options,r=i&&e||n;if(l=c(r),l===null)throw Error(`Unsupported default string type ${r}`)}return l}function Ae(e,t){let n=Object.assign({blockQuote:!0,commentString:ge,defaultKeyType:null,defaultStringType:`PLAIN`,directives:null,doubleQuotedAsJSON:!1,doubleQuotedMinMultiLineLength:40,falseStr:`false`,flowCollectionPadding:!0,indentSeq:!0,lineWidth:80,minContentWidth:20,nullStr:`null`,simpleKeys:!1,singleQuote:null,trailingComma:!1,trueStr:`true`,verifyAliasOrder:!0},e.schema.toStringOptions,t),r;switch(n.collectionStyle){case`block`:r=!1;break;case`flow`:r=!0;break;default:r=null}return{anchors:new Set,doc:e,flowCollectionPadding:n.flowCollectionPadding?` `:``,indent:``,indentStep:typeof n.indent==`number`?` `.repeat(n.indent):` `,inFlow:r,options:n}}function je(e,t){if(t.tag){let n=e.filter(e=>e.tag===t.tag);if(n.length>0)return n.find(e=>e.format===t.format)??n[0]}let n,r;if(m(t)){r=t.value;let i=e.filter(e=>e.identify?.(r));if(i.length>1){let e=i.filter(e=>e.test);e.length>0&&(i=e)}n=i.find(e=>e.format===t.format)??i.find(e=>!e.format)}else r=t,n=e.find(e=>e.nodeClass&&r instanceof e.nodeClass);if(!n){let e=r?.constructor?.name??(r===null?`null`:typeof r);throw Error(`Tag not resolved for ${e} value`)}return n}function Me(e,t,{anchors:n,doc:r}){if(!r.directives)return``;let i=[],a=(m(e)||g(e))&&e.anchor;a&&re(a)&&(n.add(a),i.push(`&${a}`));let o=e.tag??(t.default?null:t.tag);return o&&i.push(r.directives.tagString(o)),i.join(` `)}function F(e,t,n,r){if(p(e))return e.toString(t,n,r);if(u(e)){if(t.doc.directives)return e.toString(t);if(t.resolvedAliases?.has(e))throw TypeError(`Cannot stringify circular structure without alias nodes`);t.resolvedAliases?t.resolvedAliases.add(e):t.resolvedAliases=new Set([e]),e=e.resolve(t.doc)}let i,a=_(e)?e:t.doc.createNode(e,{onTagObj:e=>i=e});i??=je(t.doc.schema.tags,a);let o=Me(a,i,t);o.length>0&&(t.indentAtStart=(t.indentAtStart??0)+o.length+1);let s=typeof i.stringify==`function`?i.stringify(a,t,n,r):m(a)?ke(a,t,n,r):a.toString(t,n,r);return o?m(a)||s[0]===`{`||s[0]===`[`?`${o} ${s}`:`${o}\n${t.indent}${s}`:s}function Ne({key:e,value:t},n,r,i){let{allNullValues:a,doc:o,indent:s,indentStep:c,options:{commentString:l,indentSeq:u,simpleKeys:d}}=n,f=_(e)&&e.comment||null;if(d){if(f)throw Error(`With simple keys, key nodes cannot have comments`);if(g(e)||!_(e)&&typeof e==`object`)throw Error(`With simple keys, collection cannot be used as a key value`)}let p=!d&&(!e||f&&t==null&&!n.inFlow||g(e)||(m(e)?e.type===k.BLOCK_FOLDED||e.type===k.BLOCK_LITERAL:typeof e==`object`));n=Object.assign({},n,{allNullValues:!1,implicitKey:!p&&(d||!a),indent:s+c});let v=!1,y=!1,b=F(e,n,()=>v=!0,()=>y=!0);if(!p&&!n.inFlow&&b.length>1024){if(d)throw Error(`With simple keys, single line scalar must not span more than 1024 characters`);p=!0}if(n.inFlow){if(a||t==null)return v&&r&&r(),b===``?`?`:p?`? ${b}`:b}else if(a&&!d||t==null&&p)return b=`? ${b}`,f&&!v?b+=M(b,n.indent,l(f)):y&&i&&i(),b;v&&(f=null),p?(f&&(b+=M(b,n.indent,l(f))),b=`? ${b}\n${s}:`):(b=`${b}:`,f&&(b+=M(b,n.indent,l(f))));let x,S,C;_(t)?(x=!!t.spaceBefore,S=t.commentBefore,C=t.comment):(x=!1,S=null,C=null,t&&typeof t==`object`&&(t=o.createNode(t))),n.implicitKey=!1,!p&&!f&&m(t)&&(n.indentAtStart=b.length+1),y=!1,!u&&c.length>=2&&!n.inFlow&&!p&&h(t)&&!t.flow&&!t.tag&&!t.anchor&&(n.indent=n.indent.substring(2));let ee=!1,w=F(t,n,()=>ee=!0,()=>y=!0),T=` `;if(f||x||S){if(T=x?`
26
+ `)?P(a,t):we(e,t,n,r);if(!s&&!u&&i!==O.PLAIN&&a.includes(`
27
+ `))return we(e,t,n,r);if(be(a)){if(c===``)return t.forceBlockIndent=!0,we(e,t,n,r);if(s&&c===l)return P(a,t)}let d=a.replace(/\n+/g,`$&\n${c}`);if(o){let e=e=>e.default&&e.tag!==`tag:yaml.org,2002:str`&&e.test?.test(d),{compat:n,tags:r}=t.doc.schema;if(r.some(e)||n?.some(e))return P(a,t)}return s?d:_e(d,c,me,ye(t,!1))}function Ee(e,t,n,r){let{implicitKey:i,inFlow:a}=t,o=typeof e.value==`string`?e:Object.assign({},e,{value:String(e.value)}),{type:s}=e;s!==O.QUOTE_DOUBLE&&/[\x00-\x08\x0b-\x1f\x7f-\x9f\u{D800}-\u{DFFF}]/u.test(o.value)&&(s=O.QUOTE_DOUBLE);let c=e=>{switch(e){case O.BLOCK_FOLDED:case O.BLOCK_LITERAL:return i||a?P(o.value,t):we(o,t,n,r);case O.QUOTE_DOUBLE:return N(o.value,t);case O.QUOTE_SINGLE:return Se(o.value,t);case O.PLAIN:return Te(o,t,n,r);default:return null}},l=c(s);if(l===null){let{defaultKeyType:e,defaultStringType:n}=t.options,r=i&&e||n;if(l=c(r),l===null)throw Error(`Unsupported default string type ${r}`)}return l}function De(e,t){let n=Object.assign({blockQuote:!0,commentString:pe,defaultKeyType:null,defaultStringType:`PLAIN`,directives:null,doubleQuotedAsJSON:!1,doubleQuotedMinMultiLineLength:40,falseStr:`false`,flowCollectionPadding:!0,indentSeq:!0,lineWidth:80,minContentWidth:20,nullStr:`null`,simpleKeys:!1,singleQuote:null,trailingComma:!1,trueStr:`true`,verifyAliasOrder:!0},e.schema.toStringOptions,t),r;switch(n.collectionStyle){case`block`:r=!1;break;case`flow`:r=!0;break;default:r=null}return{anchors:new Set,doc:e,flowCollectionPadding:n.flowCollectionPadding?` `:``,indent:``,indentStep:typeof n.indent==`number`?` `.repeat(n.indent):` `,inFlow:r,options:n}}function Oe(e,t){if(t.tag){let n=e.filter(e=>e.tag===t.tag);if(n.length>0)return n.find(e=>e.format===t.format)??n[0]}let n,r;if(d(t)){r=t.value;let i=e.filter(e=>e.identify?.(r));if(i.length>1){let e=i.filter(e=>e.test);e.length>0&&(i=e)}n=i.find(e=>e.format===t.format)??i.find(e=>!e.format)}else r=t,n=e.find(e=>e.nodeClass&&r instanceof e.nodeClass);if(!n){let e=r?.constructor?.name??(r===null?`null`:typeof r);throw Error(`Tag not resolved for ${e} value`)}return n}function ke(e,t,{anchors:n,doc:r}){if(!r.directives)return``;let i=[],a=(d(e)||p(e))&&e.anchor;a&&te(a)&&(n.add(a),i.push(`&${a}`));let o=e.tag??(t.default?null:t.tag);return o&&i.push(r.directives.tagString(o)),i.join(` `)}function F(e,t,n,r){if(u(e))return e.toString(t,n,r);if(s(e)){if(t.doc.directives)return e.toString(t);if(t.resolvedAliases?.has(e))throw TypeError(`Cannot stringify circular structure without alias nodes`);t.resolvedAliases?t.resolvedAliases.add(e):t.resolvedAliases=new Set([e]),e=e.resolve(t.doc)}let i,a=m(e)?e:t.doc.createNode(e,{onTagObj:e=>i=e});i??=Oe(t.doc.schema.tags,a);let o=ke(a,i,t);o.length>0&&(t.indentAtStart=(t.indentAtStart??0)+o.length+1);let c=typeof i.stringify==`function`?i.stringify(a,t,n,r):d(a)?Ee(a,t,n,r):a.toString(t,n,r);return o?d(a)||c[0]===`{`||c[0]===`[`?`${o} ${c}`:`${o}\n${t.indent}${c}`:c}function Ae({key:e,value:t},n,r,i){let{allNullValues:a,doc:o,indent:s,indentStep:c,options:{commentString:l,indentSeq:u,simpleKeys:h}}=n,g=m(e)&&e.comment||null;if(h){if(g)throw Error(`With simple keys, key nodes cannot have comments`);if(p(e)||!m(e)&&typeof e==`object`)throw Error(`With simple keys, collection cannot be used as a key value`)}let _=!h&&(!e||g&&t==null&&!n.inFlow||p(e)||(d(e)?e.type===O.BLOCK_FOLDED||e.type===O.BLOCK_LITERAL:typeof e==`object`));n=Object.assign({},n,{allNullValues:!1,implicitKey:!_&&(h||!a),indent:s+c});let v=!1,y=!1,b=F(e,n,()=>v=!0,()=>y=!0);if(!_&&!n.inFlow&&b.length>1024){if(h)throw Error(`With simple keys, single line scalar must not span more than 1024 characters`);_=!0}if(n.inFlow){if(a||t==null)return v&&r&&r(),b===``?`?`:_?`? ${b}`:b}else if(a&&!h||t==null&&_)return b=`? ${b}`,g&&!v?b+=M(b,n.indent,l(g)):y&&i&&i(),b;v&&(g=null),_?(g&&(b+=M(b,n.indent,l(g))),b=`? ${b}\n${s}:`):(b=`${b}:`,g&&(b+=M(b,n.indent,l(g))));let x,S,C;m(t)?(x=!!t.spaceBefore,S=t.commentBefore,C=t.comment):(x=!1,S=null,C=null,t&&typeof t==`object`&&(t=o.createNode(t))),n.implicitKey=!1,!_&&!g&&d(t)&&(n.indentAtStart=b.length+1),y=!1,!u&&c.length>=2&&!n.inFlow&&!_&&f(t)&&!t.flow&&!t.tag&&!t.anchor&&(n.indent=n.indent.substring(2));let ee=!1,w=F(t,n,()=>ee=!0,()=>y=!0),T=` `;if(g||x||S){if(T=x?`
28
28
  `:``,S){let e=l(S);T+=`\n${j(e,n.indent)}`}w===``&&!n.inFlow?T===`
29
29
  `&&C&&(T=`
30
30
 
31
- `):T+=`\n${n.indent}`}else if(!p&&g(t)){let e=w[0],r=w.indexOf(`
31
+ `):T+=`\n${n.indent}`}else if(!_&&p(t)){let e=w[0],r=w.indexOf(`
32
32
  `),i=r!==-1,a=n.inFlow??t.flow??t.items.length===0;if(i||!a){let t=!1;if(i&&(e===`&`||e===`!`)){let n=w.indexOf(` `);e===`&`&&n!==-1&&n<r&&w[n+1]===`!`&&(n=w.indexOf(` `,n+1)),(n===-1||r<n)&&(t=!0)}t||(T=`\n${n.indent}`)}}else(w===``||w[0]===`
33
- `)&&(T=``);return b+=T+w,n.inFlow?ee&&r&&r():C&&!ee?b+=M(b,n.indent,l(C)):y&&i&&i(),b}function Pe(e,t){(e===`debug`||e===`warn`)&&console.warn(t)}var Fe=`<<`,I={identify:e=>e===Fe||typeof e==`symbol`&&e.description===Fe,default:`key`,tag:`tag:yaml.org,2002:merge`,test:/^<<$/,resolve:()=>Object.assign(new k(Symbol(Fe)),{addToJSMap:Le}),stringify:()=>Fe},Ie=(e,t)=>(I.identify(t)||m(t)&&(!t.type||t.type===k.PLAIN)&&I.identify(t.value))&&e?.doc.schema.tags.some(e=>e.tag===I.tag&&e.default);function Le(e,t,n){let r=ze(e,n);if(h(r))for(let n of r.items)Re(e,t,n);else if(Array.isArray(r))for(let n of r)Re(e,t,n);else Re(e,t,r)}function Re(e,t,n){let r=ze(e,n);if(!f(r))throw Error(`Merge sources must be maps or map aliases`);let i=r.toJSON(null,e,Map);for(let[e,n]of i)t instanceof Map?t.has(e)||t.set(e,n):t instanceof Set?t.add(e):Object.prototype.hasOwnProperty.call(t,e)||Object.defineProperty(t,e,{value:n,writable:!0,enumerable:!0,configurable:!0});return t}function ze(e,t){return e&&u(t)?t.resolve(e.doc,e):t}function Be(e,t,{key:n,value:r}){if(_(n)&&n.addToJSMap)n.addToJSMap(e,t,r);else if(Ie(e,n))Le(e,t,r);else{let i=O(n,``,e);if(t instanceof Map)t.set(i,O(r,i,e));else if(t instanceof Set)t.add(i);else{let a=Ve(n,i,e),o=O(r,a,e);a in t?Object.defineProperty(t,a,{value:o,writable:!0,enumerable:!0,configurable:!0}):t[a]=o}}return t}function Ve(e,t,n){if(t===null)return``;if(typeof t!=`object`)return String(t);if(_(e)&&n?.doc){let t=Ae(n.doc,{});t.anchors=new Set;for(let e of n.anchors.keys())t.anchors.add(e.anchor);t.inFlow=!0,t.inStringifyKey=!0;let r=e.toString(t);if(!n.mapKeyWarned){let e=JSON.stringify(r);e.length>40&&(e=e.substring(0,36)+`..."`),Pe(n.doc.options.logLevel,`Keys with collection values will be stringified due to JS Object restrictions: ${e}. Set mapAsMap: true to use object keys.`),n.mapKeyWarned=!0}return r}return JSON.stringify(t)}function He(e,t,n){return new L(A(e,void 0,n),A(t,void 0,n))}var L=class e{constructor(e,t=null){Object.defineProperty(this,l,{value:o}),this.key=e,this.value=t}clone(t){let{key:n,value:r}=this;return _(n)&&(n=n.clone(t)),_(r)&&(r=r.clone(t)),new e(n,r)}toJSON(e,t){return Be(t,t?.mapAsMap?new Map:{},this)}toString(e,t,n){return e?.doc?Ne(this,e,t,n):JSON.stringify(this)}};function Ue(e,t,n){return(t.inFlow??e.flow?Ge:We)(e,t,n)}function We({comment:e,items:t},n,{blockItemPrefix:r,flowChars:i,itemIndent:a,onChompKeep:o,onComment:s}){let{indent:c,options:{commentString:l}}=n,u=Object.assign({},n,{indent:a,type:null}),d=!1,f=[];for(let e=0;e<t.length;++e){let i=t[e],o=null;if(_(i))!d&&i.spaceBefore&&f.push(``),Ke(n,f,i.commentBefore,d),i.comment&&(o=i.comment);else if(p(i)){let e=_(i.key)?i.key:null;e&&(!d&&e.spaceBefore&&f.push(``),Ke(n,f,e.commentBefore,d))}d=!1;let s=F(i,u,()=>o=null,()=>d=!0);o&&(s+=M(s,a,l(o))),d&&o&&(d=!1),f.push(r+s)}let m;if(f.length===0)m=i.start+i.end;else{m=f[0];for(let e=1;e<f.length;++e){let t=f[e];m+=t?`\n${c}${t}`:`
34
- `}}return e?(m+=`
35
- `+j(l(e),c),s&&s()):d&&o&&o(),m}function Ge({items:e},t,{flowChars:n,itemIndent:r}){let{indent:i,indentStep:a,flowCollectionPadding:o,options:{commentString:s}}=t;r+=a;let c=Object.assign({},t,{indent:r,inFlow:!0,type:null}),l=!1,u=0,d=[];for(let n=0;n<e.length;++n){let i=e[n],a=null;if(_(i))i.spaceBefore&&d.push(``),Ke(t,d,i.commentBefore,!1),i.comment&&(a=i.comment);else if(p(i)){let e=_(i.key)?i.key:null;e&&(e.spaceBefore&&d.push(``),Ke(t,d,e.commentBefore,!1),e.comment&&(l=!0));let n=_(i.value)?i.value:null;n?(n.comment&&(a=n.comment),n.commentBefore&&(l=!0)):i.value==null&&e?.comment&&(a=e.comment)}a&&(l=!0);let o=F(i,c,()=>a=null);l||=d.length>u||o.includes(`
36
- `),n<e.length-1?o+=`,`:t.options.trailingComma&&(t.options.lineWidth>0&&(l||=d.reduce((e,t)=>e+t.length+2,2)+(o.length+2)>t.options.lineWidth),l&&(o+=`,`)),a&&(o+=M(o,r,s(a))),d.push(o),u=d.length}let{start:f,end:m}=n;if(d.length===0)return f+m;if(!l){let e=d.reduce((e,t)=>e+t.length+2,2);l=t.options.lineWidth>0&&e>t.options.lineWidth}if(l){let e=f;for(let t of d)e+=t?`\n${a}${i}${t}`:`
37
- `;return`${e}\n${i}${m}`}return`${f}${o}${d.join(` `)}${o}${m}`}function Ke({indent:e,options:{commentString:t}},n,r,i){if(r&&i&&(r=r.replace(/^\n+/,``)),r){let i=j(t(r),e);n.push(i.trimStart())}}function R(e,t){let n=m(t)?t.value:t;for(let r of e)if(p(r)&&(r.key===t||r.key===n||m(r.key)&&r.key.value===n))return r}var z=class extends he{static get tagName(){return`tag:yaml.org,2002:map`}constructor(e){super(a,e),this.items=[]}static from(e,t,n){let{keepUndefined:r,replacer:i}=n,a=new this(e),o=(e,o)=>{if(typeof i==`function`)o=i.call(t,e,o);else if(Array.isArray(i)&&!i.includes(e))return;(o!==void 0||r)&&a.items.push(He(e,o,n))};if(t instanceof Map)for(let[e,n]of t)o(e,n);else if(t&&typeof t==`object`)for(let e of Object.keys(t))o(e,t[e]);return typeof e.sortMapEntries==`function`&&a.items.sort(e.sortMapEntries),a}add(e,t){let n;n=p(e)?e:!e||typeof e!=`object`||!(`key`in e)?new L(e,e?.value):new L(e.key,e.value);let r=R(this.items,n.key),i=this.schema?.sortMapEntries;if(r){if(!t)throw Error(`Key ${n.key} already set`);m(r.value)&&ue(n.value)?r.value.value=n.value:r.value=n.value}else if(i){let e=this.items.findIndex(e=>i(n,e)<0);e===-1?this.items.push(n):this.items.splice(e,0,n)}else this.items.push(n)}delete(e){let t=R(this.items,e);return t?this.items.splice(this.items.indexOf(t),1).length>0:!1}get(e,t){let n=R(this.items,e)?.value;return(!t&&m(n)?n.value:n)??void 0}has(e){return!!R(this.items,e)}set(e,t){this.add(new L(e,t),!0)}toJSON(e,t,n){let r=n?new n:t?.mapAsMap?new Map:{};t?.onCreate&&t.onCreate(r);for(let e of this.items)Be(t,r,e);return r}toString(e,t,n){if(!e)return JSON.stringify(this);for(let e of this.items)if(!p(e))throw Error(`Map items must all be pairs; found ${JSON.stringify(e)} instead`);return!e.allNullValues&&this.hasAllNullValues(!1)&&(e=Object.assign({},e,{allNullValues:!0})),Ue(this,e,{blockItemPrefix:``,flowChars:{start:`{`,end:`}`},itemIndent:e.indent||``,onChompKeep:n,onComment:t})}},B={collection:`map`,default:!0,nodeClass:z,tag:`tag:yaml.org,2002:map`,resolve(e,t){return f(e)||t(`Expected a mapping for this tag`),e},createNode:(e,t,n)=>z.from(e,t,n)},V=class extends he{static get tagName(){return`tag:yaml.org,2002:seq`}constructor(e){super(c,e),this.items=[]}add(e){this.items.push(e)}delete(e){let t=qe(e);return typeof t==`number`&&this.items.splice(t,1).length>0}get(e,t){let n=qe(e);if(typeof n!=`number`)return;let r=this.items[n];return!t&&m(r)?r.value:r}has(e){let t=qe(e);return typeof t==`number`&&t<this.items.length}set(e,t){let n=qe(e);if(typeof n!=`number`)throw Error(`Expected a valid index, not ${e}.`);let r=this.items[n];m(r)&&ue(t)?r.value=t:this.items[n]=t}toJSON(e,t){let n=[];t?.onCreate&&t.onCreate(n);let r=0;for(let e of this.items)n.push(O(e,String(r++),t));return n}toString(e,t,n){return e?Ue(this,e,{blockItemPrefix:`- `,flowChars:{start:`[`,end:`]`},itemIndent:(e.indent||``)+` `,onChompKeep:n,onComment:t}):JSON.stringify(this)}static from(e,t,n){let{replacer:r}=n,i=new this(e);if(t&&Symbol.iterator in Object(t)){let e=0;for(let a of t){if(typeof r==`function`){let n=t instanceof Set?a:String(e++);a=r.call(t,n,a)}i.items.push(A(a,void 0,n))}}return i}};function qe(e){let t=m(e)?e.value:e;return t&&typeof t==`string`&&(t=Number(t)),typeof t==`number`&&Number.isInteger(t)&&t>=0?t:null}var H={collection:`seq`,default:!0,nodeClass:V,tag:`tag:yaml.org,2002:seq`,resolve(e,t){return h(e)||t(`Expected a sequence for this tag`),e},createNode:(e,t,n)=>V.from(e,t,n)},Je={identify:e=>typeof e==`string`,default:!0,tag:`tag:yaml.org,2002:str`,resolve:e=>e,stringify(e,t,n,r){return t=Object.assign({actualString:!0},t),ke(e,t,n,r)}},Ye={identify:e=>e==null,createNode:()=>new k(null),default:!0,tag:`tag:yaml.org,2002:null`,test:/^(?:~|[Nn]ull|NULL)?$/,resolve:()=>new k(null),stringify:({source:e},t)=>typeof e==`string`&&Ye.test.test(e)?e:t.options.nullStr},Xe={identify:e=>typeof e==`boolean`,default:!0,tag:`tag:yaml.org,2002:bool`,test:/^(?:[Tt]rue|TRUE|[Ff]alse|FALSE)$/,resolve:e=>new k(e[0]===`t`||e[0]===`T`),stringify({source:e,value:t},n){return e&&Xe.test.test(e)&&t===(e[0]===`t`||e[0]===`T`)?e:t?n.options.trueStr:n.options.falseStr}};function U({format:e,minFractionDigits:t,tag:n,value:r}){if(typeof r==`bigint`)return String(r);let i=typeof r==`number`?r:Number(r);if(!isFinite(i))return isNaN(i)?`.nan`:i<0?`-.inf`:`.inf`;let a=Object.is(r,-0)?`-0`:JSON.stringify(r);if(!e&&t&&(!n||n===`tag:yaml.org,2002:float`)&&/^-?\d/.test(a)&&!a.includes(`e`)){let e=a.indexOf(`.`);e<0&&(e=a.length,a+=`.`);let n=t-(a.length-e-1);for(;n-->0;)a+=`0`}return a}var Ze={identify:e=>typeof e==`number`,default:!0,tag:`tag:yaml.org,2002:float`,test:/^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,resolve:e=>e.slice(-3).toLowerCase()===`nan`?NaN:e[0]===`-`?-1/0:1/0,stringify:U},Qe={identify:e=>typeof e==`number`,default:!0,tag:`tag:yaml.org,2002:float`,format:`EXP`,test:/^[-+]?(?:\.[0-9]+|[0-9]+(?:\.[0-9]*)?)[eE][-+]?[0-9]+$/,resolve:e=>parseFloat(e),stringify(e){let t=Number(e.value);return isFinite(t)?t.toExponential():U(e)}},$e={identify:e=>typeof e==`number`,default:!0,tag:`tag:yaml.org,2002:float`,test:/^[-+]?(?:\.[0-9]+|[0-9]+\.[0-9]*)$/,resolve(e){let t=new k(parseFloat(e)),n=e.indexOf(`.`);return n!==-1&&e[e.length-1]===`0`&&(t.minFractionDigits=e.length-n-1),t},stringify:U},et=e=>typeof e==`bigint`||Number.isInteger(e),tt=(e,t,n,{intAsBigInt:r})=>r?BigInt(e):parseInt(e.substring(t),n);function nt(e,t,n){let{value:r}=e;return et(r)&&r>=0?n+r.toString(t):U(e)}var rt={identify:e=>et(e)&&e>=0,default:!0,tag:`tag:yaml.org,2002:int`,format:`OCT`,test:/^0o[0-7]+$/,resolve:(e,t,n)=>tt(e,2,8,n),stringify:e=>nt(e,8,`0o`)},it={identify:et,default:!0,tag:`tag:yaml.org,2002:int`,test:/^[-+]?[0-9]+$/,resolve:(e,t,n)=>tt(e,0,10,n),stringify:U},at={identify:e=>et(e)&&e>=0,default:!0,tag:`tag:yaml.org,2002:int`,format:`HEX`,test:/^0x[0-9a-fA-F]+$/,resolve:(e,t,n)=>tt(e,2,16,n),stringify:e=>nt(e,16,`0x`)},ot=[B,H,Je,Ye,Xe,rt,it,at,Ze,Qe,$e];function st(e){return typeof e==`bigint`||Number.isInteger(e)}var ct=({value:e})=>JSON.stringify(e),lt=[{identify:e=>typeof e==`string`,default:!0,tag:`tag:yaml.org,2002:str`,resolve:e=>e,stringify:ct},{identify:e=>e==null,createNode:()=>new k(null),default:!0,tag:`tag:yaml.org,2002:null`,test:/^null$/,resolve:()=>null,stringify:ct},{identify:e=>typeof e==`boolean`,default:!0,tag:`tag:yaml.org,2002:bool`,test:/^true$|^false$/,resolve:e=>e===`true`,stringify:ct},{identify:st,default:!0,tag:`tag:yaml.org,2002:int`,test:/^-?(?:0|[1-9][0-9]*)$/,resolve:(e,t,{intAsBigInt:n})=>n?BigInt(e):parseInt(e,10),stringify:({value:e})=>st(e)?e.toString():JSON.stringify(e)},{identify:e=>typeof e==`number`,default:!0,tag:`tag:yaml.org,2002:float`,test:/^-?(?:0|[1-9][0-9]*)(?:\.[0-9]*)?(?:[eE][-+]?[0-9]+)?$/,resolve:e=>parseFloat(e),stringify:ct}],ut=[B,H].concat(lt,{default:!0,tag:``,test:/^/,resolve(e,t){return t(`Unresolved plain scalar ${JSON.stringify(e)}`),e}}),dt={identify:e=>e instanceof Uint8Array,default:!1,tag:`tag:yaml.org,2002:binary`,resolve(e,t){if(typeof atob==`function`){let t=atob(e.replace(/[\n\r]/g,``)),n=new Uint8Array(t.length);for(let e=0;e<t.length;++e)n[e]=t.charCodeAt(e);return n}return t(`This environment does not support reading binary tags; either Buffer or atob is required`),e},stringify({comment:e,type:t,value:n},r,i,a){if(!n)return``;let o=n,s;if(typeof btoa==`function`){let e=``;for(let t=0;t<o.length;++t)e+=String.fromCharCode(o[t]);s=btoa(e)}else throw Error(`This environment does not support writing binary tags; either Buffer or btoa is required`);if(t??=k.BLOCK_LITERAL,t!==k.QUOTE_DOUBLE){let e=Math.max(r.options.lineWidth-r.indent.length,r.options.minContentWidth),n=Math.ceil(s.length/e),i=Array(n);for(let t=0,r=0;t<n;++t,r+=e)i[t]=s.substr(r,e);s=i.join(t===k.BLOCK_LITERAL?`
38
- `:` `)}return ke({comment:e,type:t,value:s},r,i,a)}};function ft(e,t){if(h(e))for(let n=0;n<e.items.length;++n){let r=e.items[n];if(!p(r)){if(f(r)){r.items.length>1&&t(`Each pair must have its own sequence indicator`);let e=r.items[0]||new L(new k(null));if(r.commentBefore&&(e.key.commentBefore=e.key.commentBefore?`${r.commentBefore}\n${e.key.commentBefore}`:r.commentBefore),r.comment){let t=e.value??e.key;t.comment=t.comment?`${r.comment}\n${t.comment}`:r.comment}r=e}e.items[n]=p(r)?r:new L(r)}}else t(`Expected a sequence for this tag`);return e}function pt(e,t,n){let{replacer:r}=n,i=new V(e);i.tag=`tag:yaml.org,2002:pairs`;let a=0;if(t&&Symbol.iterator in Object(t))for(let e of t){typeof r==`function`&&(e=r.call(t,String(a++),e));let o,s;if(Array.isArray(e)){if(e.length===2)o=e[0],s=e[1];else throw TypeError(`Expected [key, value] tuple: ${e}`)}else if(e&&e instanceof Object){let t=Object.keys(e);if(t.length===1)o=t[0],s=e[o];else throw TypeError(`Expected tuple with one key, not ${t.length} keys`)}else o=e;i.items.push(He(o,s,n))}return i}var mt={collection:`seq`,default:!1,tag:`tag:yaml.org,2002:pairs`,resolve:ft,createNode:pt},ht=class e extends V{constructor(){super(),this.add=z.prototype.add.bind(this),this.delete=z.prototype.delete.bind(this),this.get=z.prototype.get.bind(this),this.has=z.prototype.has.bind(this),this.set=z.prototype.set.bind(this),this.tag=e.tag}toJSON(e,t){if(!t)return super.toJSON(e);let n=new Map;t?.onCreate&&t.onCreate(n);for(let e of this.items){let r,i;if(p(e)?(r=O(e.key,``,t),i=O(e.value,r,t)):r=O(e,``,t),n.has(r))throw Error(`Ordered maps must not include duplicate keys`);n.set(r,i)}return n}static from(e,t,n){let r=pt(e,t,n),i=new this;return i.items=r.items,i}};ht.tag=`tag:yaml.org,2002:omap`;var gt={collection:`seq`,identify:e=>e instanceof Map,nodeClass:ht,default:!1,tag:`tag:yaml.org,2002:omap`,resolve(e,t){let n=ft(e,t),r=[];for(let{key:e}of n.items)m(e)&&(r.includes(e.value)?t(`Ordered maps must not include duplicate keys: ${e.value}`):r.push(e.value));return Object.assign(new ht,n)},createNode:(e,t,n)=>ht.from(e,t,n)};function _t({value:e,source:t},n){return t&&(e?vt:yt).test.test(t)?t:e?n.options.trueStr:n.options.falseStr}var vt={identify:e=>e===!0,default:!0,tag:`tag:yaml.org,2002:bool`,test:/^(?:Y|y|[Yy]es|YES|[Tt]rue|TRUE|[Oo]n|ON)$/,resolve:()=>new k(!0),stringify:_t},yt={identify:e=>e===!1,default:!0,tag:`tag:yaml.org,2002:bool`,test:/^(?:N|n|[Nn]o|NO|[Ff]alse|FALSE|[Oo]ff|OFF)$/,resolve:()=>new k(!1),stringify:_t},bt={identify:e=>typeof e==`number`,default:!0,tag:`tag:yaml.org,2002:float`,test:/^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,resolve:e=>e.slice(-3).toLowerCase()===`nan`?NaN:e[0]===`-`?-1/0:1/0,stringify:U},xt={identify:e=>typeof e==`number`,default:!0,tag:`tag:yaml.org,2002:float`,format:`EXP`,test:/^[-+]?(?:[0-9][0-9_]*)?(?:\.[0-9_]*)?[eE][-+]?[0-9]+$/,resolve:e=>parseFloat(e.replace(/_/g,``)),stringify(e){let t=Number(e.value);return isFinite(t)?t.toExponential():U(e)}},St={identify:e=>typeof e==`number`,default:!0,tag:`tag:yaml.org,2002:float`,test:/^[-+]?(?:[0-9][0-9_]*)?\.[0-9_]*$/,resolve(e){let t=new k(parseFloat(e.replace(/_/g,``))),n=e.indexOf(`.`);if(n!==-1){let r=e.substring(n+1).replace(/_/g,``);r[r.length-1]===`0`&&(t.minFractionDigits=r.length)}return t},stringify:U},W=e=>typeof e==`bigint`||Number.isInteger(e);function Ct(e,t,n,{intAsBigInt:r}){let i=e[0];if((i===`-`||i===`+`)&&(t+=1),e=e.substring(t).replace(/_/g,``),r){switch(n){case 2:e=`0b${e}`;break;case 8:e=`0o${e}`;break;case 16:e=`0x${e}`}let t=BigInt(e);return i===`-`?BigInt(-1)*t:t}let a=parseInt(e,n);return i===`-`?-1*a:a}function wt(e,t,n){let{value:r}=e;if(W(r)){let e=r.toString(t);return r<0?`-`+n+e.substr(1):n+e}return U(e)}var Tt={identify:W,default:!0,tag:`tag:yaml.org,2002:int`,format:`BIN`,test:/^[-+]?0b[0-1_]+$/,resolve:(e,t,n)=>Ct(e,2,2,n),stringify:e=>wt(e,2,`0b`)},Et={identify:W,default:!0,tag:`tag:yaml.org,2002:int`,format:`OCT`,test:/^[-+]?0[0-7_]+$/,resolve:(e,t,n)=>Ct(e,1,8,n),stringify:e=>wt(e,8,`0`)},Dt={identify:W,default:!0,tag:`tag:yaml.org,2002:int`,test:/^[-+]?[0-9][0-9_]*$/,resolve:(e,t,n)=>Ct(e,0,10,n),stringify:U},Ot={identify:W,default:!0,tag:`tag:yaml.org,2002:int`,format:`HEX`,test:/^[-+]?0x[0-9a-fA-F_]+$/,resolve:(e,t,n)=>Ct(e,2,16,n),stringify:e=>wt(e,16,`0x`)},kt=class e extends z{constructor(t){super(t),this.tag=e.tag}add(e){let t;t=p(e)?e:e&&typeof e==`object`&&`key`in e&&`value`in e&&e.value===null?new L(e.key,null):new L(e,null),R(this.items,t.key)||this.items.push(t)}get(e,t){let n=R(this.items,e);return!t&&p(n)?m(n.key)?n.key.value:n.key:n}set(e,t){if(typeof t!=`boolean`)throw Error(`Expected boolean value for set(key, value) in a YAML set, not ${typeof t}`);let n=R(this.items,e);n&&!t?this.items.splice(this.items.indexOf(n),1):!n&&t&&this.items.push(new L(e))}toJSON(e,t){return super.toJSON(e,t,Set)}toString(e,t,n){if(!e)return JSON.stringify(this);if(this.hasAllNullValues(!0))return super.toString(Object.assign({},e,{allNullValues:!0}),t,n);throw Error(`Set items must all have null values`)}static from(e,t,n){let{replacer:r}=n,i=new this(e);if(t&&Symbol.iterator in Object(t))for(let e of t)typeof r==`function`&&(e=r.call(t,e,e)),i.items.push(He(e,null,n));return i}};kt.tag=`tag:yaml.org,2002:set`;var At={collection:`map`,identify:e=>e instanceof Set,nodeClass:kt,default:!1,tag:`tag:yaml.org,2002:set`,createNode:(e,t,n)=>kt.from(e,t,n),resolve(e,t){if(f(e)){if(e.hasAllNullValues(!0))return Object.assign(new kt,e);t(`Set items must all have null values`)}else t(`Expected a mapping for this tag`);return e}};function jt(e,t){let n=e[0],r=n===`-`||n===`+`?e.substring(1):e,i=e=>t?BigInt(e):Number(e),a=r.replace(/_/g,``).split(`:`).reduce((e,t)=>e*i(60)+i(t),i(0));return n===`-`?i(-1)*a:a}function Mt(e){let{value:t}=e,n=e=>e;if(typeof t==`bigint`)n=e=>BigInt(e);else if(isNaN(t)||!isFinite(t))return U(e);let r=``;t<0&&(r=`-`,t*=n(-1));let i=n(60),a=[t%i];return t<60?a.unshift(0):(t=(t-a[0])/i,a.unshift(t%i),t>=60&&(t=(t-a[0])/i,a.unshift(t))),r+a.map(e=>String(e).padStart(2,`0`)).join(`:`).replace(/000000\d*$/,``)}var Nt={identify:e=>typeof e==`bigint`||Number.isInteger(e),default:!0,tag:`tag:yaml.org,2002:int`,format:`TIME`,test:/^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+$/,resolve:(e,t,{intAsBigInt:n})=>jt(e,n),stringify:Mt},Pt={identify:e=>typeof e==`number`,default:!0,tag:`tag:yaml.org,2002:float`,format:`TIME`,test:/^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\.[0-9_]*$/,resolve:e=>jt(e,!1),stringify:Mt},Ft={identify:e=>e instanceof Date,default:!0,tag:`tag:yaml.org,2002:timestamp`,test:RegExp(`^([0-9]{4})-([0-9]{1,2})-([0-9]{1,2})(?:(?:t|T|[ \\t]+)([0-9]{1,2}):([0-9]{1,2}):([0-9]{1,2}(\\.[0-9]+)?)(?:[ \\t]*(Z|[-+][012]?[0-9](?::[0-9]{2})?))?)?$`),resolve(e){let t=e.match(Ft.test);if(!t)throw Error(`!!timestamp expects a date, starting with yyyy-mm-dd`);let[,n,r,i,a,o,s]=t.map(Number),c=t[7]?Number((t[7]+`00`).substr(1,3)):0,l=Date.UTC(n,r-1,i,a||0,o||0,s||0,c),u=t[8];if(u&&u!==`Z`){let e=jt(u,!1);Math.abs(e)<30&&(e*=60),l-=6e4*e}return new Date(l)},stringify:({value:e})=>e?.toISOString().replace(/(T00:00:00)?\.000Z$/,``)??``},It=[B,H,Je,Ye,vt,yt,Tt,Et,Dt,Ot,bt,xt,St,dt,I,gt,mt,At,Nt,Pt,Ft],Lt=new Map([[`core`,ot],[`failsafe`,[B,H,Je]],[`json`,ut],[`yaml11`,It],[`yaml-1.1`,It]]),Rt={binary:dt,bool:Xe,float:$e,floatExp:Qe,floatNaN:Ze,floatTime:Pt,int:it,intHex:at,intOct:rt,intTime:Nt,map:B,merge:I,null:Ye,omap:gt,pairs:mt,seq:H,set:At,timestamp:Ft},zt={"tag:yaml.org,2002:binary":dt,"tag:yaml.org,2002:merge":I,"tag:yaml.org,2002:omap":gt,"tag:yaml.org,2002:pairs":mt,"tag:yaml.org,2002:set":At,"tag:yaml.org,2002:timestamp":Ft};function Bt(e,t,n){let r=Lt.get(t);if(r&&!e)return n&&!r.includes(I)?r.concat(I):r.slice();let i=r;if(!i){if(Array.isArray(e))i=[];else{let e=Array.from(Lt.keys()).filter(e=>e!==`yaml11`).map(e=>JSON.stringify(e)).join(`, `);throw Error(`Unknown schema "${t}"; use one of ${e} or define customTags array`)}}if(Array.isArray(e))for(let t of e)i=i.concat(t);else typeof e==`function`&&(i=e(i.slice()));return n&&(i=i.concat(I)),i.reduce((e,t)=>{let n=typeof t==`string`?Rt[t]:t;if(!n){let e=JSON.stringify(t),n=Object.keys(Rt).map(e=>JSON.stringify(e)).join(`, `);throw Error(`Unknown custom tag ${e}; use one of ${n}`)}return e.includes(n)||e.push(n),e},[])}var Vt=(e,t)=>e.key<t.key?-1:+(e.key>t.key),Ht=class e{constructor({compat:e,customTags:t,merge:n,resolveKnownTags:r,schema:i,sortMapEntries:o,toStringDefaults:l}){this.compat=Array.isArray(e)?Bt(e,`compat`):e?Bt(null,e):null,this.name=typeof i==`string`&&i||`core`,this.knownTags=r?zt:{},this.tags=Bt(t,this.name,n),this.toStringOptions=l??null,Object.defineProperty(this,a,{value:B}),Object.defineProperty(this,s,{value:Je}),Object.defineProperty(this,c,{value:H}),this.sortMapEntries=typeof o==`function`?o:o===!0?Vt:null}clone(){let t=Object.create(e.prototype,Object.getOwnPropertyDescriptors(this));return t.tags=this.tags.slice(),t}};function Ut(e,t){let n=[],r=t.directives===!0;if(t.directives!==!1&&e.directives){let t=e.directives.toString(e);t?(n.push(t),r=!0):e.directives.docStart&&(r=!0)}r&&n.push(`---`);let i=Ae(e,t),{commentString:a}=i.options;if(e.commentBefore){n.length!==1&&n.unshift(``);let t=a(e.commentBefore);n.unshift(j(t,``))}let o=!1,s=null;if(e.contents){if(_(e.contents)){if(e.contents.spaceBefore&&r&&n.push(``),e.contents.commentBefore){let t=a(e.contents.commentBefore);n.push(j(t,``))}i.forceBlockIndent=!!e.comment,s=e.contents.comment}let t=s?void 0:()=>o=!0,c=F(e.contents,i,()=>s=null,t);s&&(c+=M(c,``,a(s))),(c[0]===`|`||c[0]===`>`)&&n[n.length-1]===`---`?n[n.length-1]=`--- ${c}`:n.push(c)}else n.push(F(e.contents,i));if(e.directives?.docEnd){if(e.comment){let t=a(e.comment);t.includes(`
33
+ `)&&(T=``);return b+=T+w,n.inFlow?ee&&r&&r():C&&!ee?b+=M(b,n.indent,l(C)):y&&i&&i(),b}function je(e,t){(e===`debug`||e===`warn`)&&console.warn(t)}var Me=`<<`,I={identify:e=>e===Me||typeof e==`symbol`&&e.description===Me,default:`key`,tag:`tag:yaml.org,2002:merge`,test:/^<<$/,resolve:()=>Object.assign(new O(Symbol(Me)),{addToJSMap:Pe}),stringify:()=>Me},Ne=(e,t)=>(I.identify(t)||d(t)&&(!t.type||t.type===O.PLAIN)&&I.identify(t.value))&&e?.doc.schema.tags.some(e=>e.tag===I.tag&&e.default);function Pe(e,t,n){let r=Ie(e,n);if(f(r))for(let n of r.items)Fe(e,t,n);else if(Array.isArray(r))for(let n of r)Fe(e,t,n);else Fe(e,t,r)}function Fe(e,t,n){let r=Ie(e,n);if(!l(r))throw Error(`Merge sources must be maps or map aliases`);let i=r.toJSON(null,e,Map);for(let[e,n]of i)t instanceof Map?t.has(e)||t.set(e,n):t instanceof Set?t.add(e):Object.prototype.hasOwnProperty.call(t,e)||Object.defineProperty(t,e,{value:n,writable:!0,enumerable:!0,configurable:!0});return t}function Ie(e,t){return e&&s(t)?t.resolve(e.doc,e):t}function Le(e,t,{key:n,value:r}){if(m(n)&&n.addToJSMap)n.addToJSMap(e,t,r);else if(Ne(e,n))Pe(e,t,r);else{let i=D(n,``,e);if(t instanceof Map)t.set(i,D(r,i,e));else if(t instanceof Set)t.add(i);else{let a=Re(n,i,e),o=D(r,a,e);a in t?Object.defineProperty(t,a,{value:o,writable:!0,enumerable:!0,configurable:!0}):t[a]=o}}return t}function Re(e,t,n){if(t===null)return``;if(typeof t!=`object`)return String(t);if(m(e)&&n?.doc){let t=De(n.doc,{});t.anchors=new Set;for(let e of n.anchors.keys())t.anchors.add(e.anchor);t.inFlow=!0,t.inStringifyKey=!0;let r=e.toString(t);if(!n.mapKeyWarned){let e=JSON.stringify(r);e.length>40&&(e=e.substring(0,36)+`..."`),je(n.doc.options.logLevel,`Keys with collection values will be stringified due to JS Object restrictions: ${e}. Set mapAsMap: true to use object keys.`),n.mapKeyWarned=!0}return r}return JSON.stringify(t)}function ze(e,t,n){return new L(k(e,void 0,n),k(t,void 0,n))}var L=class e{constructor(e,t=null){Object.defineProperty(this,o,{value:r}),this.key=e,this.value=t}clone(t){let{key:n,value:r}=this;return m(n)&&(n=n.clone(t)),m(r)&&(r=r.clone(t)),new e(n,r)}toJSON(e,t){return Le(t,t?.mapAsMap?new Map:{},this)}toString(e,t,n){return e?.doc?Ae(this,e,t,n):JSON.stringify(this)}};function Be(e,t,n){return(t.inFlow??e.flow?He:Ve)(e,t,n)}function Ve({comment:e,items:t},n,{blockItemPrefix:r,flowChars:i,itemIndent:a,onChompKeep:o,onComment:s}){let{indent:c,options:{commentString:l}}=n,d=Object.assign({},n,{indent:a,type:null}),f=!1,p=[];for(let e=0;e<t.length;++e){let i=t[e],o=null;if(m(i))!f&&i.spaceBefore&&p.push(``),Ue(n,p,i.commentBefore,f),i.comment&&(o=i.comment);else if(u(i)){let e=m(i.key)?i.key:null;e&&(!f&&e.spaceBefore&&p.push(``),Ue(n,p,e.commentBefore,f))}f=!1;let s=F(i,d,()=>o=null,()=>f=!0);o&&(s+=M(s,a,l(o))),f&&o&&(f=!1),p.push(r+s)}let h;if(p.length===0)h=i.start+i.end;else{h=p[0];for(let e=1;e<p.length;++e){let t=p[e];h+=t?`\n${c}${t}`:`
34
+ `}}return e?(h+=`
35
+ `+j(l(e),c),s&&s()):f&&o&&o(),h}function He({items:e},t,{flowChars:n,itemIndent:r}){let{indent:i,indentStep:a,flowCollectionPadding:o,options:{commentString:s}}=t;r+=a;let c=Object.assign({},t,{indent:r,inFlow:!0,type:null}),l=!1,d=0,f=[];for(let n=0;n<e.length;++n){let i=e[n],a=null;if(m(i))i.spaceBefore&&f.push(``),Ue(t,f,i.commentBefore,!1),i.comment&&(a=i.comment);else if(u(i)){let e=m(i.key)?i.key:null;e&&(e.spaceBefore&&f.push(``),Ue(t,f,e.commentBefore,!1),e.comment&&(l=!0));let n=m(i.value)?i.value:null;n?(n.comment&&(a=n.comment),n.commentBefore&&(l=!0)):i.value==null&&e?.comment&&(a=e.comment)}a&&(l=!0);let o=F(i,c,()=>a=null);l||=f.length>d||o.includes(`
36
+ `),n<e.length-1?o+=`,`:t.options.trailingComma&&(t.options.lineWidth>0&&(l||=f.reduce((e,t)=>e+t.length+2,2)+(o.length+2)>t.options.lineWidth),l&&(o+=`,`)),a&&(o+=M(o,r,s(a))),f.push(o),d=f.length}let{start:p,end:h}=n;if(f.length===0)return p+h;if(!l){let e=f.reduce((e,t)=>e+t.length+2,2);l=t.options.lineWidth>0&&e>t.options.lineWidth}if(l){let e=p;for(let t of f)e+=t?`\n${a}${i}${t}`:`
37
+ `;return`${e}\n${i}${h}`}return`${p}${o}${f.join(` `)}${o}${h}`}function Ue({indent:e,options:{commentString:t}},n,r,i){if(r&&i&&(r=r.replace(/^\n+/,``)),r){let i=j(t(r),e);n.push(i.trimStart())}}function R(e,t){let n=d(t)?t.value:t;for(let r of e)if(u(r)&&(r.key===t||r.key===n||d(r.key)&&r.key.value===n))return r}var z=class extends fe{static get tagName(){return`tag:yaml.org,2002:map`}constructor(e){super(n,e),this.items=[]}static from(e,t,n){let{keepUndefined:r,replacer:i}=n,a=new this(e),o=(e,o)=>{if(typeof i==`function`)o=i.call(t,e,o);else if(Array.isArray(i)&&!i.includes(e))return;(o!==void 0||r)&&a.items.push(ze(e,o,n))};if(t instanceof Map)for(let[e,n]of t)o(e,n);else if(t&&typeof t==`object`)for(let e of Object.keys(t))o(e,t[e]);return typeof e.sortMapEntries==`function`&&a.items.sort(e.sortMapEntries),a}add(e,t){let n;n=u(e)?e:!e||typeof e!=`object`||!(`key`in e)?new L(e,e?.value):new L(e.key,e.value);let r=R(this.items,n.key),i=this.schema?.sortMapEntries;if(r){if(!t)throw Error(`Key ${n.key} already set`);d(r.value)&&ce(n.value)?r.value.value=n.value:r.value=n.value}else if(i){let e=this.items.findIndex(e=>i(n,e)<0);e===-1?this.items.push(n):this.items.splice(e,0,n)}else this.items.push(n)}delete(e){let t=R(this.items,e);return t?this.items.splice(this.items.indexOf(t),1).length>0:!1}get(e,t){let n=R(this.items,e)?.value;return(!t&&d(n)?n.value:n)??void 0}has(e){return!!R(this.items,e)}set(e,t){this.add(new L(e,t),!0)}toJSON(e,t,n){let r=n?new n:t?.mapAsMap?new Map:{};t?.onCreate&&t.onCreate(r);for(let e of this.items)Le(t,r,e);return r}toString(e,t,n){if(!e)return JSON.stringify(this);for(let e of this.items)if(!u(e))throw Error(`Map items must all be pairs; found ${JSON.stringify(e)} instead`);return!e.allNullValues&&this.hasAllNullValues(!1)&&(e=Object.assign({},e,{allNullValues:!0})),Be(this,e,{blockItemPrefix:``,flowChars:{start:`{`,end:`}`},itemIndent:e.indent||``,onChompKeep:n,onComment:t})}},B={collection:`map`,default:!0,nodeClass:z,tag:`tag:yaml.org,2002:map`,resolve(e,t){return l(e)||t(`Expected a mapping for this tag`),e},createNode:(e,t,n)=>z.from(e,t,n)},V=class extends fe{static get tagName(){return`tag:yaml.org,2002:seq`}constructor(e){super(a,e),this.items=[]}add(e){this.items.push(e)}delete(e){let t=We(e);return typeof t==`number`&&this.items.splice(t,1).length>0}get(e,t){let n=We(e);if(typeof n!=`number`)return;let r=this.items[n];return!t&&d(r)?r.value:r}has(e){let t=We(e);return typeof t==`number`&&t<this.items.length}set(e,t){let n=We(e);if(typeof n!=`number`)throw Error(`Expected a valid index, not ${e}.`);let r=this.items[n];d(r)&&ce(t)?r.value=t:this.items[n]=t}toJSON(e,t){let n=[];t?.onCreate&&t.onCreate(n);let r=0;for(let e of this.items)n.push(D(e,String(r++),t));return n}toString(e,t,n){return e?Be(this,e,{blockItemPrefix:`- `,flowChars:{start:`[`,end:`]`},itemIndent:(e.indent||``)+` `,onChompKeep:n,onComment:t}):JSON.stringify(this)}static from(e,t,n){let{replacer:r}=n,i=new this(e);if(t&&Symbol.iterator in Object(t)){let e=0;for(let a of t){if(typeof r==`function`){let n=t instanceof Set?a:String(e++);a=r.call(t,n,a)}i.items.push(k(a,void 0,n))}}return i}};function We(e){let t=d(e)?e.value:e;return t&&typeof t==`string`&&(t=Number(t)),typeof t==`number`&&Number.isInteger(t)&&t>=0?t:null}var H={collection:`seq`,default:!0,nodeClass:V,tag:`tag:yaml.org,2002:seq`,resolve(e,t){return f(e)||t(`Expected a sequence for this tag`),e},createNode:(e,t,n)=>V.from(e,t,n)},Ge={identify:e=>typeof e==`string`,default:!0,tag:`tag:yaml.org,2002:str`,resolve:e=>e,stringify(e,t,n,r){return t=Object.assign({actualString:!0},t),Ee(e,t,n,r)}},Ke={identify:e=>e==null,createNode:()=>new O(null),default:!0,tag:`tag:yaml.org,2002:null`,test:/^(?:~|[Nn]ull|NULL)?$/,resolve:()=>new O(null),stringify:({source:e},t)=>typeof e==`string`&&Ke.test.test(e)?e:t.options.nullStr},qe={identify:e=>typeof e==`boolean`,default:!0,tag:`tag:yaml.org,2002:bool`,test:/^(?:[Tt]rue|TRUE|[Ff]alse|FALSE)$/,resolve:e=>new O(e[0]===`t`||e[0]===`T`),stringify({source:e,value:t},n){return e&&qe.test.test(e)&&t===(e[0]===`t`||e[0]===`T`)?e:t?n.options.trueStr:n.options.falseStr}};function U({format:e,minFractionDigits:t,tag:n,value:r}){if(typeof r==`bigint`)return String(r);let i=typeof r==`number`?r:Number(r);if(!isFinite(i))return isNaN(i)?`.nan`:i<0?`-.inf`:`.inf`;let a=Object.is(r,-0)?`-0`:JSON.stringify(r);if(!e&&t&&(!n||n===`tag:yaml.org,2002:float`)&&/^-?\d/.test(a)&&!a.includes(`e`)){let e=a.indexOf(`.`);e<0&&(e=a.length,a+=`.`);let n=t-(a.length-e-1);for(;n-->0;)a+=`0`}return a}var Je={identify:e=>typeof e==`number`,default:!0,tag:`tag:yaml.org,2002:float`,test:/^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,resolve:e=>e.slice(-3).toLowerCase()===`nan`?NaN:e[0]===`-`?-1/0:1/0,stringify:U},Ye={identify:e=>typeof e==`number`,default:!0,tag:`tag:yaml.org,2002:float`,format:`EXP`,test:/^[-+]?(?:\.[0-9]+|[0-9]+(?:\.[0-9]*)?)[eE][-+]?[0-9]+$/,resolve:e=>parseFloat(e),stringify(e){let t=Number(e.value);return isFinite(t)?t.toExponential():U(e)}},Xe={identify:e=>typeof e==`number`,default:!0,tag:`tag:yaml.org,2002:float`,test:/^[-+]?(?:\.[0-9]+|[0-9]+\.[0-9]*)$/,resolve(e){let t=new O(parseFloat(e)),n=e.indexOf(`.`);return n!==-1&&e[e.length-1]===`0`&&(t.minFractionDigits=e.length-n-1),t},stringify:U},Ze=e=>typeof e==`bigint`||Number.isInteger(e),Qe=(e,t,n,{intAsBigInt:r})=>r?BigInt(e):parseInt(e.substring(t),n);function $e(e,t,n){let{value:r}=e;return Ze(r)&&r>=0?n+r.toString(t):U(e)}var et={identify:e=>Ze(e)&&e>=0,default:!0,tag:`tag:yaml.org,2002:int`,format:`OCT`,test:/^0o[0-7]+$/,resolve:(e,t,n)=>Qe(e,2,8,n),stringify:e=>$e(e,8,`0o`)},tt={identify:Ze,default:!0,tag:`tag:yaml.org,2002:int`,test:/^[-+]?[0-9]+$/,resolve:(e,t,n)=>Qe(e,0,10,n),stringify:U},nt={identify:e=>Ze(e)&&e>=0,default:!0,tag:`tag:yaml.org,2002:int`,format:`HEX`,test:/^0x[0-9a-fA-F]+$/,resolve:(e,t,n)=>Qe(e,2,16,n),stringify:e=>$e(e,16,`0x`)},rt=[B,H,Ge,Ke,qe,et,tt,nt,Je,Ye,Xe];function it(e){return typeof e==`bigint`||Number.isInteger(e)}var at=({value:e})=>JSON.stringify(e),ot=[{identify:e=>typeof e==`string`,default:!0,tag:`tag:yaml.org,2002:str`,resolve:e=>e,stringify:at},{identify:e=>e==null,createNode:()=>new O(null),default:!0,tag:`tag:yaml.org,2002:null`,test:/^null$/,resolve:()=>null,stringify:at},{identify:e=>typeof e==`boolean`,default:!0,tag:`tag:yaml.org,2002:bool`,test:/^true$|^false$/,resolve:e=>e===`true`,stringify:at},{identify:it,default:!0,tag:`tag:yaml.org,2002:int`,test:/^-?(?:0|[1-9][0-9]*)$/,resolve:(e,t,{intAsBigInt:n})=>n?BigInt(e):parseInt(e,10),stringify:({value:e})=>it(e)?e.toString():JSON.stringify(e)},{identify:e=>typeof e==`number`,default:!0,tag:`tag:yaml.org,2002:float`,test:/^-?(?:0|[1-9][0-9]*)(?:\.[0-9]*)?(?:[eE][-+]?[0-9]+)?$/,resolve:e=>parseFloat(e),stringify:at}],st=[B,H].concat(ot,{default:!0,tag:``,test:/^/,resolve(e,t){return t(`Unresolved plain scalar ${JSON.stringify(e)}`),e}}),ct={identify:e=>e instanceof Uint8Array,default:!1,tag:`tag:yaml.org,2002:binary`,resolve(e,t){if(typeof atob==`function`){let t=atob(e.replace(/[\n\r]/g,``)),n=new Uint8Array(t.length);for(let e=0;e<t.length;++e)n[e]=t.charCodeAt(e);return n}return t(`This environment does not support reading binary tags; either Buffer or atob is required`),e},stringify({comment:e,type:t,value:n},r,i,a){if(!n)return``;let o=n,s;if(typeof btoa==`function`){let e=``;for(let t=0;t<o.length;++t)e+=String.fromCharCode(o[t]);s=btoa(e)}else throw Error(`This environment does not support writing binary tags; either Buffer or btoa is required`);if(t??=O.BLOCK_LITERAL,t!==O.QUOTE_DOUBLE){let e=Math.max(r.options.lineWidth-r.indent.length,r.options.minContentWidth),n=Math.ceil(s.length/e),i=Array(n);for(let t=0,r=0;t<n;++t,r+=e)i[t]=s.substr(r,e);s=i.join(t===O.BLOCK_LITERAL?`
38
+ `:` `)}return Ee({comment:e,type:t,value:s},r,i,a)}};function lt(e,t){if(f(e))for(let n=0;n<e.items.length;++n){let r=e.items[n];if(!u(r)){if(l(r)){r.items.length>1&&t(`Each pair must have its own sequence indicator`);let e=r.items[0]||new L(new O(null));if(r.commentBefore&&(e.key.commentBefore=e.key.commentBefore?`${r.commentBefore}\n${e.key.commentBefore}`:r.commentBefore),r.comment){let t=e.value??e.key;t.comment=t.comment?`${r.comment}\n${t.comment}`:r.comment}r=e}e.items[n]=u(r)?r:new L(r)}}else t(`Expected a sequence for this tag`);return e}function ut(e,t,n){let{replacer:r}=n,i=new V(e);i.tag=`tag:yaml.org,2002:pairs`;let a=0;if(t&&Symbol.iterator in Object(t))for(let e of t){typeof r==`function`&&(e=r.call(t,String(a++),e));let o,s;if(Array.isArray(e)){if(e.length===2)o=e[0],s=e[1];else throw TypeError(`Expected [key, value] tuple: ${e}`)}else if(e&&e instanceof Object){let t=Object.keys(e);if(t.length===1)o=t[0],s=e[o];else throw TypeError(`Expected tuple with one key, not ${t.length} keys`)}else o=e;i.items.push(ze(o,s,n))}return i}var dt={collection:`seq`,default:!1,tag:`tag:yaml.org,2002:pairs`,resolve:lt,createNode:ut},ft=class e extends V{constructor(){super(),this.add=z.prototype.add.bind(this),this.delete=z.prototype.delete.bind(this),this.get=z.prototype.get.bind(this),this.has=z.prototype.has.bind(this),this.set=z.prototype.set.bind(this),this.tag=e.tag}toJSON(e,t){if(!t)return super.toJSON(e);let n=new Map;t?.onCreate&&t.onCreate(n);for(let e of this.items){let r,i;if(u(e)?(r=D(e.key,``,t),i=D(e.value,r,t)):r=D(e,``,t),n.has(r))throw Error(`Ordered maps must not include duplicate keys`);n.set(r,i)}return n}static from(e,t,n){let r=ut(e,t,n),i=new this;return i.items=r.items,i}};ft.tag=`tag:yaml.org,2002:omap`;var pt={collection:`seq`,identify:e=>e instanceof Map,nodeClass:ft,default:!1,tag:`tag:yaml.org,2002:omap`,resolve(e,t){let n=lt(e,t),r=[];for(let{key:e}of n.items)d(e)&&(r.includes(e.value)?t(`Ordered maps must not include duplicate keys: ${e.value}`):r.push(e.value));return Object.assign(new ft,n)},createNode:(e,t,n)=>ft.from(e,t,n)};function mt({value:e,source:t},n){return t&&(e?ht:gt).test.test(t)?t:e?n.options.trueStr:n.options.falseStr}var ht={identify:e=>e===!0,default:!0,tag:`tag:yaml.org,2002:bool`,test:/^(?:Y|y|[Yy]es|YES|[Tt]rue|TRUE|[Oo]n|ON)$/,resolve:()=>new O(!0),stringify:mt},gt={identify:e=>e===!1,default:!0,tag:`tag:yaml.org,2002:bool`,test:/^(?:N|n|[Nn]o|NO|[Ff]alse|FALSE|[Oo]ff|OFF)$/,resolve:()=>new O(!1),stringify:mt},_t={identify:e=>typeof e==`number`,default:!0,tag:`tag:yaml.org,2002:float`,test:/^(?:[-+]?\.(?:inf|Inf|INF)|\.nan|\.NaN|\.NAN)$/,resolve:e=>e.slice(-3).toLowerCase()===`nan`?NaN:e[0]===`-`?-1/0:1/0,stringify:U},vt={identify:e=>typeof e==`number`,default:!0,tag:`tag:yaml.org,2002:float`,format:`EXP`,test:/^[-+]?(?:[0-9][0-9_]*)?(?:\.[0-9_]*)?[eE][-+]?[0-9]+$/,resolve:e=>parseFloat(e.replace(/_/g,``)),stringify(e){let t=Number(e.value);return isFinite(t)?t.toExponential():U(e)}},yt={identify:e=>typeof e==`number`,default:!0,tag:`tag:yaml.org,2002:float`,test:/^[-+]?(?:[0-9][0-9_]*)?\.[0-9_]*$/,resolve(e){let t=new O(parseFloat(e.replace(/_/g,``))),n=e.indexOf(`.`);if(n!==-1){let r=e.substring(n+1).replace(/_/g,``);r[r.length-1]===`0`&&(t.minFractionDigits=r.length)}return t},stringify:U},W=e=>typeof e==`bigint`||Number.isInteger(e);function bt(e,t,n,{intAsBigInt:r}){let i=e[0];if((i===`-`||i===`+`)&&(t+=1),e=e.substring(t).replace(/_/g,``),r){switch(n){case 2:e=`0b${e}`;break;case 8:e=`0o${e}`;break;case 16:e=`0x${e}`}let t=BigInt(e);return i===`-`?BigInt(-1)*t:t}let a=parseInt(e,n);return i===`-`?-1*a:a}function xt(e,t,n){let{value:r}=e;if(W(r)){let e=r.toString(t);return r<0?`-`+n+e.substr(1):n+e}return U(e)}var St={identify:W,default:!0,tag:`tag:yaml.org,2002:int`,format:`BIN`,test:/^[-+]?0b[0-1_]+$/,resolve:(e,t,n)=>bt(e,2,2,n),stringify:e=>xt(e,2,`0b`)},Ct={identify:W,default:!0,tag:`tag:yaml.org,2002:int`,format:`OCT`,test:/^[-+]?0[0-7_]+$/,resolve:(e,t,n)=>bt(e,1,8,n),stringify:e=>xt(e,8,`0`)},wt={identify:W,default:!0,tag:`tag:yaml.org,2002:int`,test:/^[-+]?[0-9][0-9_]*$/,resolve:(e,t,n)=>bt(e,0,10,n),stringify:U},Tt={identify:W,default:!0,tag:`tag:yaml.org,2002:int`,format:`HEX`,test:/^[-+]?0x[0-9a-fA-F_]+$/,resolve:(e,t,n)=>bt(e,2,16,n),stringify:e=>xt(e,16,`0x`)},Et=class e extends z{constructor(t){super(t),this.tag=e.tag}add(e){let t;t=u(e)?e:e&&typeof e==`object`&&`key`in e&&`value`in e&&e.value===null?new L(e.key,null):new L(e,null),R(this.items,t.key)||this.items.push(t)}get(e,t){let n=R(this.items,e);return!t&&u(n)?d(n.key)?n.key.value:n.key:n}set(e,t){if(typeof t!=`boolean`)throw Error(`Expected boolean value for set(key, value) in a YAML set, not ${typeof t}`);let n=R(this.items,e);n&&!t?this.items.splice(this.items.indexOf(n),1):!n&&t&&this.items.push(new L(e))}toJSON(e,t){return super.toJSON(e,t,Set)}toString(e,t,n){if(!e)return JSON.stringify(this);if(this.hasAllNullValues(!0))return super.toString(Object.assign({},e,{allNullValues:!0}),t,n);throw Error(`Set items must all have null values`)}static from(e,t,n){let{replacer:r}=n,i=new this(e);if(t&&Symbol.iterator in Object(t))for(let e of t)typeof r==`function`&&(e=r.call(t,e,e)),i.items.push(ze(e,null,n));return i}};Et.tag=`tag:yaml.org,2002:set`;var Dt={collection:`map`,identify:e=>e instanceof Set,nodeClass:Et,default:!1,tag:`tag:yaml.org,2002:set`,createNode:(e,t,n)=>Et.from(e,t,n),resolve(e,t){if(l(e)){if(e.hasAllNullValues(!0))return Object.assign(new Et,e);t(`Set items must all have null values`)}else t(`Expected a mapping for this tag`);return e}};function Ot(e,t){let n=e[0],r=n===`-`||n===`+`?e.substring(1):e,i=e=>t?BigInt(e):Number(e),a=r.replace(/_/g,``).split(`:`).reduce((e,t)=>e*i(60)+i(t),i(0));return n===`-`?i(-1)*a:a}function kt(e){let{value:t}=e,n=e=>e;if(typeof t==`bigint`)n=e=>BigInt(e);else if(isNaN(t)||!isFinite(t))return U(e);let r=``;t<0&&(r=`-`,t*=n(-1));let i=n(60),a=[t%i];return t<60?a.unshift(0):(t=(t-a[0])/i,a.unshift(t%i),t>=60&&(t=(t-a[0])/i,a.unshift(t))),r+a.map(e=>String(e).padStart(2,`0`)).join(`:`).replace(/000000\d*$/,``)}var At={identify:e=>typeof e==`bigint`||Number.isInteger(e),default:!0,tag:`tag:yaml.org,2002:int`,format:`TIME`,test:/^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+$/,resolve:(e,t,{intAsBigInt:n})=>Ot(e,n),stringify:kt},jt={identify:e=>typeof e==`number`,default:!0,tag:`tag:yaml.org,2002:float`,format:`TIME`,test:/^[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\.[0-9_]*$/,resolve:e=>Ot(e,!1),stringify:kt},Mt={identify:e=>e instanceof Date,default:!0,tag:`tag:yaml.org,2002:timestamp`,test:RegExp(`^([0-9]{4})-([0-9]{1,2})-([0-9]{1,2})(?:(?:t|T|[ \\t]+)([0-9]{1,2}):([0-9]{1,2}):([0-9]{1,2}(\\.[0-9]+)?)(?:[ \\t]*(Z|[-+][012]?[0-9](?::[0-9]{2})?))?)?$`),resolve(e){let t=e.match(Mt.test);if(!t)throw Error(`!!timestamp expects a date, starting with yyyy-mm-dd`);let[,n,r,i,a,o,s]=t.map(Number),c=t[7]?Number((t[7]+`00`).substr(1,3)):0,l=Date.UTC(n,r-1,i,a||0,o||0,s||0,c),u=t[8];if(u&&u!==`Z`){let e=Ot(u,!1);Math.abs(e)<30&&(e*=60),l-=6e4*e}return new Date(l)},stringify:({value:e})=>e?.toISOString().replace(/(T00:00:00)?\.000Z$/,``)??``},Nt=[B,H,Ge,Ke,ht,gt,St,Ct,wt,Tt,_t,vt,yt,ct,I,pt,dt,Dt,At,jt,Mt],Pt=new Map([[`core`,rt],[`failsafe`,[B,H,Ge]],[`json`,st],[`yaml11`,Nt],[`yaml-1.1`,Nt]]),Ft={binary:ct,bool:qe,float:Xe,floatExp:Ye,floatNaN:Je,floatTime:jt,int:tt,intHex:nt,intOct:et,intTime:At,map:B,merge:I,null:Ke,omap:pt,pairs:dt,seq:H,set:Dt,timestamp:Mt},It={"tag:yaml.org,2002:binary":ct,"tag:yaml.org,2002:merge":I,"tag:yaml.org,2002:omap":pt,"tag:yaml.org,2002:pairs":dt,"tag:yaml.org,2002:set":Dt,"tag:yaml.org,2002:timestamp":Mt};function Lt(e,t,n){let r=Pt.get(t);if(r&&!e)return n&&!r.includes(I)?r.concat(I):r.slice();let i=r;if(!i){if(Array.isArray(e))i=[];else{let e=Array.from(Pt.keys()).filter(e=>e!==`yaml11`).map(e=>JSON.stringify(e)).join(`, `);throw Error(`Unknown schema "${t}"; use one of ${e} or define customTags array`)}}if(Array.isArray(e))for(let t of e)i=i.concat(t);else typeof e==`function`&&(i=e(i.slice()));return n&&(i=i.concat(I)),i.reduce((e,t)=>{let n=typeof t==`string`?Ft[t]:t;if(!n){let e=JSON.stringify(t),n=Object.keys(Ft).map(e=>JSON.stringify(e)).join(`, `);throw Error(`Unknown custom tag ${e}; use one of ${n}`)}return e.includes(n)||e.push(n),e},[])}var Rt=(e,t)=>e.key<t.key?-1:+(e.key>t.key),zt=class e{constructor({compat:e,customTags:t,merge:r,resolveKnownTags:o,schema:s,sortMapEntries:c,toStringDefaults:l}){this.compat=Array.isArray(e)?Lt(e,`compat`):e?Lt(null,e):null,this.name=typeof s==`string`&&s||`core`,this.knownTags=o?It:{},this.tags=Lt(t,this.name,r),this.toStringOptions=l??null,Object.defineProperty(this,n,{value:B}),Object.defineProperty(this,i,{value:Ge}),Object.defineProperty(this,a,{value:H}),this.sortMapEntries=typeof c==`function`?c:c===!0?Rt:null}clone(){let t=Object.create(e.prototype,Object.getOwnPropertyDescriptors(this));return t.tags=this.tags.slice(),t}};function Bt(e,t){let n=[],r=t.directives===!0;if(t.directives!==!1&&e.directives){let t=e.directives.toString(e);t?(n.push(t),r=!0):e.directives.docStart&&(r=!0)}r&&n.push(`---`);let i=De(e,t),{commentString:a}=i.options;if(e.commentBefore){n.length!==1&&n.unshift(``);let t=a(e.commentBefore);n.unshift(j(t,``))}let o=!1,s=null;if(e.contents){if(m(e.contents)){if(e.contents.spaceBefore&&r&&n.push(``),e.contents.commentBefore){let t=a(e.contents.commentBefore);n.push(j(t,``))}i.forceBlockIndent=!!e.comment,s=e.contents.comment}let t=s?void 0:()=>o=!0,c=F(e.contents,i,()=>s=null,t);s&&(c+=M(c,``,a(s))),(c[0]===`|`||c[0]===`>`)&&n[n.length-1]===`---`?n[n.length-1]=`--- ${c}`:n.push(c)}else n.push(F(e.contents,i));if(e.directives?.docEnd){if(e.comment){let t=a(e.comment);t.includes(`
39
39
  `)?(n.push(`...`),n.push(j(t,``))):n.push(`... ${t}`)}else n.push(`...`)}else{let t=e.comment;t&&o&&(t=t.replace(/^\n+/,``)),t&&((!o||s)&&n[n.length-1]!==``&&n.push(``),n.push(j(a(t),``)))}return n.join(`
40
40
  `)+`
41
- `}var Wt=class e{constructor(e,t,n){this.commentBefore=null,this.comment=null,this.errors=[],this.warnings=[],Object.defineProperty(this,l,{value:i});let r=null;typeof t==`function`||Array.isArray(t)?r=t:n===void 0&&t&&(n=t,t=void 0);let a=Object.assign({intAsBigInt:!1,keepSourceTokens:!1,logLevel:`warn`,prettyErrors:!0,strict:!0,stringKeys:!1,uniqueKeys:!0,version:`1.2`},n);this.options=a;let{version:o}=a;n?._directives?(this.directives=n._directives.atDocument(),this.directives.yaml.explicit&&(o=this.directives.yaml.version)):this.directives=new E({version:o}),this.setSchema(o,n),this.contents=e===void 0?null:this.createNode(e,r,n)}clone(){let t=Object.create(e.prototype,{[l]:{value:i}});return t.commentBefore=this.commentBefore,t.comment=this.comment,t.errors=this.errors.slice(),t.warnings=this.warnings.slice(),t.options=Object.assign({},this.options),this.directives&&(t.directives=this.directives.clone()),t.schema=this.schema.clone(),t.contents=_(this.contents)?this.contents.clone(t.schema):this.contents,this.range&&(t.range=this.range.slice()),t}add(e){G(this.contents)&&this.contents.add(e)}addIn(e,t){G(this.contents)&&this.contents.addIn(e,t)}createAlias(e,t){if(!e.anchor){let n=ie(this);e.anchor=!t||n.has(t)?ae(t||`a`,n):t}return new ce(e.anchor)}createNode(e,t,n){let r;if(typeof t==`function`)e=t.call({"":e},``,e),r=t;else if(Array.isArray(t)){let e=t.filter(e=>typeof e==`number`||e instanceof String||e instanceof Number).map(String);e.length>0&&(t=t.concat(e)),r=t}else n===void 0&&t&&(n=t,t=void 0);let{aliasDuplicateObjects:i,anchorPrefix:a,flow:o,keepUndefined:s,onTagObj:c,tag:l}=n??{},{onAnchor:u,setAnchors:d,sourceObjects:f}=oe(this,a||`a`),p={aliasDuplicateObjects:i??!0,keepUndefined:s??!1,onAnchor:u,onTagObj:c,replacer:r,schema:this.schema,sourceObjects:f},m=A(e,l,p);return o&&g(m)&&(m.flow=!0),d(),m}createPair(e,t,n={}){return new L(this.createNode(e,null,n),this.createNode(t,null,n))}delete(e){return G(this.contents)?this.contents.delete(e):!1}deleteIn(e){return me(e)?this.contents!=null&&(this.contents=null,!0):G(this.contents)?this.contents.deleteIn(e):!1}get(e,t){return g(this.contents)?this.contents.get(e,t):void 0}getIn(e,t){return me(e)?!t&&m(this.contents)?this.contents.value:this.contents:g(this.contents)?this.contents.getIn(e,t):void 0}has(e){return g(this.contents)?this.contents.has(e):!1}hasIn(e){return me(e)?this.contents!==void 0:g(this.contents)?this.contents.hasIn(e):!1}set(e,t){this.contents==null?this.contents=pe(this.schema,[e],t):G(this.contents)&&this.contents.set(e,t)}setIn(e,t){me(e)?this.contents=t:this.contents==null?this.contents=pe(this.schema,Array.from(e),t):G(this.contents)&&this.contents.setIn(e,t)}setSchema(e,t={}){typeof e==`number`&&(e=String(e));let n;switch(e){case`1.1`:this.directives?this.directives.yaml.version=`1.1`:this.directives=new E({version:`1.1`}),n={resolveKnownTags:!1,schema:`yaml-1.1`};break;case`1.2`:case`next`:this.directives?this.directives.yaml.version=e:this.directives=new E({version:e}),n={resolveKnownTags:!0,schema:`core`};break;case null:this.directives&&delete this.directives,n=null;break;default:{let t=JSON.stringify(e);throw Error(`Expected '1.1', '1.2' or null as first argument, but found: ${t}`)}}if(t.schema instanceof Object)this.schema=t.schema;else if(n)this.schema=new Ht(Object.assign(n,t));else throw Error(`With a null YAML version, the { schema: Schema } option is required`)}toJS({json:e,jsonArg:t,mapAsMap:n,maxAliasCount:r,onAnchor:i,reviver:a}={}){let o={anchors:new Map,doc:this,keep:!e,mapAsMap:n===!0,mapKeyWarned:!1,maxAliasCount:typeof r==`number`?r:100},s=O(this.contents,t??``,o);if(typeof i==`function`)for(let{count:e,res:t}of o.anchors.values())i(t,e);return typeof a==`function`?D(a,{"":s},``,s):s}toJSON(e,t){return this.toJS({json:!0,jsonArg:e,mapAsMap:!1,onAnchor:t})}toString(e={}){if(this.errors.length>0)throw Error(`Document with errors cannot be stringified`);if(`indent`in e&&(!Number.isInteger(e.indent)||Number(e.indent)<=0)){let t=JSON.stringify(e.indent);throw Error(`"indent" option must be a positive integer, not ${t}`)}return Ut(this,e)}};function G(e){if(g(e))return!0;throw Error(`Expected a YAML collection as document contents`)}var Gt=class extends Error{constructor(e,t,n,r){super(),this.name=e,this.code=n,this.message=r,this.pos=t}},K=class extends Gt{constructor(e,t,n){super(`YAMLParseError`,e,t,n)}},Kt=class extends Gt{constructor(e,t,n){super(`YAMLWarning`,e,t,n)}},qt=(e,t)=>n=>{if(n.pos[0]===-1)return;n.linePos=n.pos.map(e=>t.linePos(e));let{line:r,col:i}=n.linePos[0];n.message+=` at line ${r}, column ${i}`;let a=i-1,o=e.substring(t.lineStarts[r-1],t.lineStarts[r]).replace(/[\n\r]+$/,``);if(a>=60&&o.length>80){let e=Math.min(a-39,o.length-79);o=`…`+o.substring(e),a-=e-1}if(o.length>80&&(o=o.substring(0,79)+`…`),r>1&&/^ *$/.test(o.substring(0,a))){let n=e.substring(t.lineStarts[r-2],t.lineStarts[r-1]);n.length>80&&(n=n.substring(0,79)+`…
41
+ `}var Vt=class e{constructor(e,n,r){this.commentBefore=null,this.comment=null,this.errors=[],this.warnings=[],Object.defineProperty(this,o,{value:t});let i=null;typeof n==`function`||Array.isArray(n)?i=n:r===void 0&&n&&(r=n,n=void 0);let a=Object.assign({intAsBigInt:!1,keepSourceTokens:!1,logLevel:`warn`,prettyErrors:!0,strict:!0,stringKeys:!1,uniqueKeys:!0,version:`1.2`},r);this.options=a;let{version:s}=a;r?._directives?(this.directives=r._directives.atDocument(),this.directives.yaml.explicit&&(s=this.directives.yaml.version)):this.directives=new T({version:s}),this.setSchema(s,r),this.contents=e===void 0?null:this.createNode(e,i,r)}clone(){let n=Object.create(e.prototype,{[o]:{value:t}});return n.commentBefore=this.commentBefore,n.comment=this.comment,n.errors=this.errors.slice(),n.warnings=this.warnings.slice(),n.options=Object.assign({},this.options),this.directives&&(n.directives=this.directives.clone()),n.schema=this.schema.clone(),n.contents=m(this.contents)?this.contents.clone(n.schema):this.contents,this.range&&(n.range=this.range.slice()),n}add(e){G(this.contents)&&this.contents.add(e)}addIn(e,t){G(this.contents)&&this.contents.addIn(e,t)}createAlias(e,t){if(!e.anchor){let n=ne(this);e.anchor=!t||n.has(t)?re(t||`a`,n):t}return new oe(e.anchor)}createNode(e,t,n){let r;if(typeof t==`function`)e=t.call({"":e},``,e),r=t;else if(Array.isArray(t)){let e=t.filter(e=>typeof e==`number`||e instanceof String||e instanceof Number).map(String);e.length>0&&(t=t.concat(e)),r=t}else n===void 0&&t&&(n=t,t=void 0);let{aliasDuplicateObjects:i,anchorPrefix:a,flow:o,keepUndefined:s,onTagObj:c,tag:l}=n??{},{onAnchor:u,setAnchors:d,sourceObjects:f}=ie(this,a||`a`),m={aliasDuplicateObjects:i??!0,keepUndefined:s??!1,onAnchor:u,onTagObj:c,replacer:r,schema:this.schema,sourceObjects:f},h=k(e,l,m);return o&&p(h)&&(h.flow=!0),d(),h}createPair(e,t,n={}){return new L(this.createNode(e,null,n),this.createNode(t,null,n))}delete(e){return G(this.contents)?this.contents.delete(e):!1}deleteIn(e){return A(e)?this.contents!=null&&(this.contents=null,!0):G(this.contents)?this.contents.deleteIn(e):!1}get(e,t){return p(this.contents)?this.contents.get(e,t):void 0}getIn(e,t){return A(e)?!t&&d(this.contents)?this.contents.value:this.contents:p(this.contents)?this.contents.getIn(e,t):void 0}has(e){return p(this.contents)?this.contents.has(e):!1}hasIn(e){return A(e)?this.contents!==void 0:p(this.contents)?this.contents.hasIn(e):!1}set(e,t){this.contents==null?this.contents=de(this.schema,[e],t):G(this.contents)&&this.contents.set(e,t)}setIn(e,t){A(e)?this.contents=t:this.contents==null?this.contents=de(this.schema,Array.from(e),t):G(this.contents)&&this.contents.setIn(e,t)}setSchema(e,t={}){typeof e==`number`&&(e=String(e));let n;switch(e){case`1.1`:this.directives?this.directives.yaml.version=`1.1`:this.directives=new T({version:`1.1`}),n={resolveKnownTags:!1,schema:`yaml-1.1`};break;case`1.2`:case`next`:this.directives?this.directives.yaml.version=e:this.directives=new T({version:e}),n={resolveKnownTags:!0,schema:`core`};break;case null:this.directives&&delete this.directives,n=null;break;default:{let t=JSON.stringify(e);throw Error(`Expected '1.1', '1.2' or null as first argument, but found: ${t}`)}}if(t.schema instanceof Object)this.schema=t.schema;else if(n)this.schema=new zt(Object.assign(n,t));else throw Error(`With a null YAML version, the { schema: Schema } option is required`)}toJS({json:e,jsonArg:t,mapAsMap:n,maxAliasCount:r,onAnchor:i,reviver:a}={}){let o={anchors:new Map,doc:this,keep:!e,mapAsMap:n===!0,mapKeyWarned:!1,maxAliasCount:typeof r==`number`?r:100},s=D(this.contents,t??``,o);if(typeof i==`function`)for(let{count:e,res:t}of o.anchors.values())i(t,e);return typeof a==`function`?E(a,{"":s},``,s):s}toJSON(e,t){return this.toJS({json:!0,jsonArg:e,mapAsMap:!1,onAnchor:t})}toString(e={}){if(this.errors.length>0)throw Error(`Document with errors cannot be stringified`);if(`indent`in e&&(!Number.isInteger(e.indent)||Number(e.indent)<=0)){let t=JSON.stringify(e.indent);throw Error(`"indent" option must be a positive integer, not ${t}`)}return Bt(this,e)}};function G(e){if(p(e))return!0;throw Error(`Expected a YAML collection as document contents`)}var Ht=class extends Error{constructor(e,t,n,r){super(),this.name=e,this.code=n,this.message=r,this.pos=t}},K=class extends Ht{constructor(e,t,n){super(`YAMLParseError`,e,t,n)}},Ut=class extends Ht{constructor(e,t,n){super(`YAMLWarning`,e,t,n)}},Wt=(e,t)=>n=>{if(n.pos[0]===-1)return;n.linePos=n.pos.map(e=>t.linePos(e));let{line:r,col:i}=n.linePos[0];n.message+=` at line ${r}, column ${i}`;let a=i-1,o=e.substring(t.lineStarts[r-1],t.lineStarts[r]).replace(/[\n\r]+$/,``);if(a>=60&&o.length>80){let e=Math.min(a-39,o.length-79);o=`…`+o.substring(e),a-=e-1}if(o.length>80&&(o=o.substring(0,79)+`…`),r>1&&/^ *$/.test(o.substring(0,a))){let n=e.substring(t.lineStarts[r-2],t.lineStarts[r-1]);n.length>80&&(n=n.substring(0,79)+`…
42
42
  `),o=n+o}if(/[^ ]/.test(o)){let e=1,t=n.linePos[1];t?.line===r&&t.col>i&&(e=Math.max(1,Math.min(t.col-i,80-a)));let s=` `.repeat(a)+`^`.repeat(e);n.message+=`:\n\n${o}\n${s}\n`}};function q(e,{flow:t,indicator:n,next:r,offset:i,onError:a,parentIndent:o,startOnNewline:s}){let c=!1,l=s,u=s,d=``,f=``,p=!1,m=!1,h=null,g=null,_=null,v=null,y=null,b=null,x=null;for(let i of e)switch(m&&=(i.type!==`space`&&i.type!==`newline`&&i.type!==`comma`&&a(i.offset,`MISSING_CHAR`,`Tags and anchors must be separated from the next token by white space`),!1),h&&=(l&&i.type!==`comment`&&i.type!==`newline`&&a(h,`TAB_AS_INDENT`,`Tabs are not allowed as indentation`),null),i.type){case`space`:!t&&(n!==`doc-start`||r?.type!==`flow-collection`)&&i.source.includes(` `)&&(h=i),u=!0;break;case`comment`:{u||a(i,`MISSING_CHAR`,`Comments must be separated from other tokens by white space characters`);let e=i.source.substring(1)||` `;d?d+=f+e:d=e,f=``,l=!1;break}case`newline`:l?d?d+=i.source:b&&n===`seq-item-ind`||(c=!0):f+=i.source,l=!0,p=!0,(g||_)&&(v=i),u=!0;break;case`anchor`:g&&a(i,`MULTIPLE_ANCHORS`,`A node can have at most one anchor`),i.source.endsWith(`:`)&&a(i.offset+i.source.length-1,`BAD_ALIAS`,`Anchor ending in : is ambiguous`,!0),g=i,x??=i.offset,l=!1,u=!1,m=!0;break;case`tag`:_&&a(i,`MULTIPLE_TAGS`,`A node can have at most one tag`),_=i,x??=i.offset,l=!1,u=!1,m=!0;break;case n:(g||_)&&a(i,`BAD_PROP_ORDER`,`Anchors and tags must be after the ${i.source} indicator`),b&&a(i,`UNEXPECTED_TOKEN`,`Unexpected ${i.source} in ${t??`collection`}`),b=i,l=n===`seq-item-ind`||n===`explicit-key-ind`,u=!1;break;case`comma`:if(t){y&&a(i,`UNEXPECTED_TOKEN`,`Unexpected , in ${t}`),y=i,l=!1,u=!1;break}default:a(i,`UNEXPECTED_TOKEN`,`Unexpected ${i.type} token`),l=!1,u=!1}let S=e[e.length-1],C=S?S.offset+S.source.length:i;return m&&r&&r.type!==`space`&&r.type!==`newline`&&r.type!==`comma`&&(r.type!==`scalar`||r.source!==``)&&a(r.offset,`MISSING_CHAR`,`Tags and anchors must be separated from the next token by white space`),h&&(l&&h.indent<=o||r?.type===`block-map`||r?.type===`block-seq`)&&a(h,`TAB_AS_INDENT`,`Tabs are not allowed as indentation`),{comma:y,found:b,spaceBefore:c,comment:d,hasNewline:p,anchor:g,tag:_,newlineAfterProp:v,end:C,start:x??C}}function J(e){if(!e)return null;switch(e.type){case`alias`:case`scalar`:case`double-quoted-scalar`:case`single-quoted-scalar`:if(e.source.includes(`
43
- `))return!0;if(e.end){for(let t of e.end)if(t.type===`newline`)return!0}return!1;case`flow-collection`:for(let t of e.items){for(let e of t.start)if(e.type===`newline`)return!0;if(t.sep){for(let e of t.sep)if(e.type===`newline`)return!0}if(J(t.key)||J(t.value))return!0}return!1;default:return!0}}function Jt(e,t,n){if(t?.type===`flow-collection`){let r=t.end[0];r.indent===e&&(r.source===`]`||r.source===`}`)&&J(t)&&n(r,`BAD_INDENT`,`Flow end indicator should be more indented than parent`,!0)}}function Yt(e,t,n){let{uniqueKeys:r}=e.options;if(r===!1)return!1;let i=typeof r==`function`?r:(e,t)=>e===t||m(e)&&m(t)&&e.value===t.value;return t.some(e=>i(e.key,n))}var Xt=`All mapping items must start at the same column`;function Zt({composeNode:e,composeEmptyNode:t},n,r,i,a){let o=new((a?.nodeClass)??z)(n.schema);n.atRoot&&=!1;let s=r.offset,c=null;for(let a of r.items){let{start:l,key:u,sep:d,value:f}=a,p=q(l,{indicator:`explicit-key-ind`,next:u??d?.[0],offset:s,onError:i,parentIndent:r.indent,startOnNewline:!0}),m=!p.found;if(m){if(u&&(u.type===`block-seq`?i(s,`BLOCK_AS_IMPLICIT_KEY`,`A block sequence may not be used as an implicit map key`):`indent`in u&&u.indent!==r.indent&&i(s,`BAD_INDENT`,Xt)),!p.anchor&&!p.tag&&!d){c=p.end,p.comment&&(o.comment?o.comment+=`
44
- `+p.comment:o.comment=p.comment);continue}(p.newlineAfterProp||J(u))&&i(u??l[l.length-1],`MULTILINE_IMPLICIT_KEY`,`Implicit keys need to be on a single line`)}else p.found?.indent!==r.indent&&i(s,`BAD_INDENT`,Xt);n.atKey=!0;let h=p.end,g=u?e(n,u,p,i):t(n,h,l,null,p,i);n.schema.compat&&Jt(r.indent,u,i),n.atKey=!1,Yt(n,o.items,g)&&i(h,`DUPLICATE_KEY`,`Map keys must be unique`);let _=q(d??[],{indicator:`map-value-ind`,next:f,offset:g.range[2],onError:i,parentIndent:r.indent,startOnNewline:!u||u.type===`block-scalar`});if(s=_.end,_.found){m&&(f?.type===`block-map`&&!_.hasNewline&&i(s,`BLOCK_AS_IMPLICIT_KEY`,`Nested mappings are not allowed in compact mappings`),n.options.strict&&p.start<_.found.offset-1024&&i(g.range,`KEY_OVER_1024_CHARS`,`The : indicator must be at most 1024 chars after the start of an implicit block mapping key`));let c=f?e(n,f,_,i):t(n,s,d,null,_,i);n.schema.compat&&Jt(r.indent,f,i),s=c.range[2];let l=new L(g,c);n.options.keepSourceTokens&&(l.srcToken=a),o.items.push(l)}else{m&&i(g.range,`MISSING_CHAR`,`Implicit map keys need to be followed by map values`),_.comment&&(g.comment?g.comment+=`
45
- `+_.comment:g.comment=_.comment);let e=new L(g);n.options.keepSourceTokens&&(e.srcToken=a),o.items.push(e)}}return c&&c<s&&i(c,`IMPOSSIBLE`,`Map comment with trailing content`),o.range=[r.offset,s,c??s],o}function Qt({composeNode:e,composeEmptyNode:t},n,r,i,a){let o=new((a?.nodeClass)??V)(n.schema);n.atRoot&&=!1,n.atKey&&=!1;let s=r.offset,c=null;for(let{start:a,value:l}of r.items){let u=q(a,{indicator:`seq-item-ind`,next:l,offset:s,onError:i,parentIndent:r.indent,startOnNewline:!0});if(!u.found){if(u.anchor||u.tag||l)l?.type===`block-seq`?i(u.end,`BAD_INDENT`,`All sequence items must start at the same column`):i(s,`MISSING_CHAR`,`Sequence item without - indicator`);else{c=u.end,u.comment&&(o.comment=u.comment);continue}}let d=l?e(n,l,u,i):t(n,u.end,a,null,u,i);n.schema.compat&&Jt(r.indent,l,i),s=d.range[2],o.items.push(d)}return o.range=[r.offset,s,c??s],o}function $t(e,t,n,r){let i=``;if(e){let a=!1,o=``;for(let s of e){let{source:e,type:c}=s;switch(c){case`space`:a=!0;break;case`comment`:{n&&!a&&r(s,`MISSING_CHAR`,`Comments must be separated from other tokens by white space characters`);let t=e.substring(1)||` `;i?i+=o+t:i=t,o=``;break}case`newline`:i&&(o+=e),a=!0;break;default:r(s,`UNEXPECTED_TOKEN`,`Unexpected ${c} at node end`)}t+=e.length}}return{comment:i,offset:t}}var en=`Block collections are not allowed within flow collections`,tn=e=>e&&(e.type===`block-map`||e.type===`block-seq`);function nn({composeNode:e,composeEmptyNode:t},n,r,i,a){let o=r.start.source===`{`,s=o?`flow map`:`flow sequence`,c=new((a?.nodeClass)??(o?z:V))(n.schema);c.flow=!0;let l=n.atRoot;l&&(n.atRoot=!1),n.atKey&&=!1;let u=r.offset+r.start.source.length;for(let a=0;a<r.items.length;++a){let l=r.items[a],{start:d,key:f,sep:m,value:h}=l,g=q(d,{flow:s,indicator:`explicit-key-ind`,next:f??m?.[0],offset:u,onError:i,parentIndent:r.indent,startOnNewline:!1});if(!g.found){if(!g.anchor&&!g.tag&&!m&&!h){a===0&&g.comma?i(g.comma,`UNEXPECTED_TOKEN`,`Unexpected , in ${s}`):a<r.items.length-1&&i(g.start,`UNEXPECTED_TOKEN`,`Unexpected empty item in ${s}`),g.comment&&(c.comment?c.comment+=`
46
- `+g.comment:c.comment=g.comment),u=g.end;continue}!o&&n.options.strict&&J(f)&&i(f,`MULTILINE_IMPLICIT_KEY`,`Implicit keys of flow sequence pairs need to be on a single line`)}if(a===0)g.comma&&i(g.comma,`UNEXPECTED_TOKEN`,`Unexpected , in ${s}`);else if(g.comma||i(g.start,`MISSING_CHAR`,`Missing , between ${s} items`),g.comment){let e=``;loop:for(let t of d)switch(t.type){case`comma`:case`space`:break;case`comment`:e=t.source.substring(1);break loop;default:break loop}if(e){let t=c.items[c.items.length-1];p(t)&&(t=t.value??t.key),t.comment?t.comment+=`
47
- `+e:t.comment=e,g.comment=g.comment.substring(e.length+1)}}if(!o&&!m&&!g.found){let r=h?e(n,h,g,i):t(n,g.end,m,null,g,i);c.items.push(r),u=r.range[2],tn(h)&&i(r.range,`BLOCK_IN_FLOW`,en)}else{n.atKey=!0;let a=g.end,p=f?e(n,f,g,i):t(n,a,d,null,g,i);tn(f)&&i(p.range,`BLOCK_IN_FLOW`,en),n.atKey=!1;let _=q(m??[],{flow:s,indicator:`map-value-ind`,next:h,offset:p.range[2],onError:i,parentIndent:r.indent,startOnNewline:!1});if(_.found){if(!o&&!g.found&&n.options.strict){if(m)for(let e of m){if(e===_.found)break;if(e.type===`newline`){i(e,`MULTILINE_IMPLICIT_KEY`,`Implicit keys of flow sequence pairs need to be on a single line`);break}}g.start<_.found.offset-1024&&i(_.found,`KEY_OVER_1024_CHARS`,`The : indicator must be at most 1024 chars after the start of an implicit flow sequence key`)}}else h&&(`source`in h&&h.source?.[0]===`:`?i(h,`MISSING_CHAR`,`Missing space after : in ${s}`):i(_.start,`MISSING_CHAR`,`Missing , or : between ${s} items`));let v=h?e(n,h,_,i):_.found?t(n,_.end,m,null,_,i):null;v?tn(h)&&i(v.range,`BLOCK_IN_FLOW`,en):_.comment&&(p.comment?p.comment+=`
48
- `+_.comment:p.comment=_.comment);let y=new L(p,v);if(n.options.keepSourceTokens&&(y.srcToken=l),o){let e=c;Yt(n,e.items,p)&&i(a,`DUPLICATE_KEY`,`Map keys must be unique`),e.items.push(y)}else{let e=new z(n.schema);e.flow=!0,e.items.push(y);let t=(v??p).range;e.range=[p.range[0],t[1],t[2]],c.items.push(e)}u=v?v.range[2]:_.end}}let d=o?`}`:`]`,[f,...m]=r.end,h=u;if(f?.source===d)h=f.offset+f.source.length;else{let e=s[0].toUpperCase()+s.substring(1),t=l?`${e} must end with a ${d}`:`${e} in block collection must be sufficiently indented and end with a ${d}`;i(u,l?`MISSING_CHAR`:`BAD_INDENT`,t),f&&f.source.length!==1&&m.unshift(f)}if(m.length>0){let e=$t(m,h,n.options.strict,i);e.comment&&(c.comment?c.comment+=`
49
- `+e.comment:c.comment=e.comment),c.range=[r.offset,h,e.offset]}else c.range=[r.offset,h,h];return c}function rn(e,t,n,r,i,a){let o=n.type===`block-map`?Zt(e,t,n,r,a):n.type===`block-seq`?Qt(e,t,n,r,a):nn(e,t,n,r,a),s=o.constructor;return i===`!`||i===s.tagName?(o.tag=s.tagName,o):(i&&(o.tag=i),o)}function an(e,t,n,r,i){let a=r.tag,o=a?t.directives.tagName(a.source,e=>i(a,`TAG_RESOLVE_FAILED`,e)):null;if(n.type===`block-seq`){let{anchor:e,newlineAfterProp:t}=r,n=e&&a?e.offset>a.offset?e:a:e??a;n&&(!t||t.offset<n.offset)&&i(n,`MISSING_CHAR`,`Missing newline after block sequence props`)}let s=n.type===`block-map`?`map`:n.type===`block-seq`?`seq`:n.start.source===`{`?`map`:`seq`;if(!a||!o||o===`!`||o===z.tagName&&s===`map`||o===V.tagName&&s===`seq`)return rn(e,t,n,i,o);let c=t.schema.tags.find(e=>e.tag===o&&e.collection===s);if(!c){let r=t.schema.knownTags[o];if(r?.collection===s)t.schema.tags.push(Object.assign({},r,{default:!1})),c=r;else return r?i(a,`BAD_COLLECTION_TYPE`,`${r.tag} used for ${s} collection, but expects ${r.collection??`scalar`}`,!0):i(a,`TAG_RESOLVE_FAILED`,`Unresolved tag: ${o}`,!0),rn(e,t,n,i,o)}let l=rn(e,t,n,i,o,c),u=c.resolve?.(l,e=>i(a,`TAG_RESOLVE_FAILED`,e),t.options)??l,d=_(u)?u:new k(u);return d.range=l.range,d.tag=o,c?.format&&(d.format=c.format),d}function on(e,t,n){let r=t.offset,i=sn(t,e.options.strict,n);if(!i)return{value:``,type:null,comment:``,range:[r,r,r]};let a=i.mode===`>`?k.BLOCK_FOLDED:k.BLOCK_LITERAL,o=t.source?cn(t.source):[],s=o.length;for(let e=o.length-1;e>=0;--e){let t=o[e][1];if(t===``||t===`\r`)s=e;else break}if(s===0){let e=i.chomp===`+`&&o.length>0?`
43
+ `))return!0;if(e.end){for(let t of e.end)if(t.type===`newline`)return!0}return!1;case`flow-collection`:for(let t of e.items){for(let e of t.start)if(e.type===`newline`)return!0;if(t.sep){for(let e of t.sep)if(e.type===`newline`)return!0}if(J(t.key)||J(t.value))return!0}return!1;default:return!0}}function Gt(e,t,n){if(t?.type===`flow-collection`){let r=t.end[0];r.indent===e&&(r.source===`]`||r.source===`}`)&&J(t)&&n(r,`BAD_INDENT`,`Flow end indicator should be more indented than parent`,!0)}}function Kt(e,t,n){let{uniqueKeys:r}=e.options;if(r===!1)return!1;let i=typeof r==`function`?r:(e,t)=>e===t||d(e)&&d(t)&&e.value===t.value;return t.some(e=>i(e.key,n))}var qt=`All mapping items must start at the same column`;function Jt({composeNode:e,composeEmptyNode:t},n,r,i,a){let o=new((a?.nodeClass)??z)(n.schema);n.atRoot&&=!1;let s=r.offset,c=null;for(let a of r.items){let{start:l,key:u,sep:d,value:f}=a,p=q(l,{indicator:`explicit-key-ind`,next:u??d?.[0],offset:s,onError:i,parentIndent:r.indent,startOnNewline:!0}),m=!p.found;if(m){if(u&&(u.type===`block-seq`?i(s,`BLOCK_AS_IMPLICIT_KEY`,`A block sequence may not be used as an implicit map key`):`indent`in u&&u.indent!==r.indent&&i(s,`BAD_INDENT`,qt)),!p.anchor&&!p.tag&&!d){c=p.end,p.comment&&(o.comment?o.comment+=`
44
+ `+p.comment:o.comment=p.comment);continue}(p.newlineAfterProp||J(u))&&i(u??l[l.length-1],`MULTILINE_IMPLICIT_KEY`,`Implicit keys need to be on a single line`)}else p.found?.indent!==r.indent&&i(s,`BAD_INDENT`,qt);n.atKey=!0;let h=p.end,g=u?e(n,u,p,i):t(n,h,l,null,p,i);n.schema.compat&&Gt(r.indent,u,i),n.atKey=!1,Kt(n,o.items,g)&&i(h,`DUPLICATE_KEY`,`Map keys must be unique`);let _=q(d??[],{indicator:`map-value-ind`,next:f,offset:g.range[2],onError:i,parentIndent:r.indent,startOnNewline:!u||u.type===`block-scalar`});if(s=_.end,_.found){m&&(f?.type===`block-map`&&!_.hasNewline&&i(s,`BLOCK_AS_IMPLICIT_KEY`,`Nested mappings are not allowed in compact mappings`),n.options.strict&&p.start<_.found.offset-1024&&i(g.range,`KEY_OVER_1024_CHARS`,`The : indicator must be at most 1024 chars after the start of an implicit block mapping key`));let c=f?e(n,f,_,i):t(n,s,d,null,_,i);n.schema.compat&&Gt(r.indent,f,i),s=c.range[2];let l=new L(g,c);n.options.keepSourceTokens&&(l.srcToken=a),o.items.push(l)}else{m&&i(g.range,`MISSING_CHAR`,`Implicit map keys need to be followed by map values`),_.comment&&(g.comment?g.comment+=`
45
+ `+_.comment:g.comment=_.comment);let e=new L(g);n.options.keepSourceTokens&&(e.srcToken=a),o.items.push(e)}}return c&&c<s&&i(c,`IMPOSSIBLE`,`Map comment with trailing content`),o.range=[r.offset,s,c??s],o}function Yt({composeNode:e,composeEmptyNode:t},n,r,i,a){let o=new((a?.nodeClass)??V)(n.schema);n.atRoot&&=!1,n.atKey&&=!1;let s=r.offset,c=null;for(let{start:a,value:l}of r.items){let u=q(a,{indicator:`seq-item-ind`,next:l,offset:s,onError:i,parentIndent:r.indent,startOnNewline:!0});if(!u.found){if(u.anchor||u.tag||l)l?.type===`block-seq`?i(u.end,`BAD_INDENT`,`All sequence items must start at the same column`):i(s,`MISSING_CHAR`,`Sequence item without - indicator`);else{c=u.end,u.comment&&(o.comment=u.comment);continue}}let d=l?e(n,l,u,i):t(n,u.end,a,null,u,i);n.schema.compat&&Gt(r.indent,l,i),s=d.range[2],o.items.push(d)}return o.range=[r.offset,s,c??s],o}function Y(e,t,n,r){let i=``;if(e){let a=!1,o=``;for(let s of e){let{source:e,type:c}=s;switch(c){case`space`:a=!0;break;case`comment`:{n&&!a&&r(s,`MISSING_CHAR`,`Comments must be separated from other tokens by white space characters`);let t=e.substring(1)||` `;i?i+=o+t:i=t,o=``;break}case`newline`:i&&(o+=e),a=!0;break;default:r(s,`UNEXPECTED_TOKEN`,`Unexpected ${c} at node end`)}t+=e.length}}return{comment:i,offset:t}}var Xt=`Block collections are not allowed within flow collections`,Zt=e=>e&&(e.type===`block-map`||e.type===`block-seq`);function Qt({composeNode:e,composeEmptyNode:t},n,r,i,a){let o=r.start.source===`{`,s=o?`flow map`:`flow sequence`,c=new((a?.nodeClass)??(o?z:V))(n.schema);c.flow=!0;let l=n.atRoot;l&&(n.atRoot=!1),n.atKey&&=!1;let d=r.offset+r.start.source.length;for(let a=0;a<r.items.length;++a){let l=r.items[a],{start:f,key:p,sep:m,value:h}=l,g=q(f,{flow:s,indicator:`explicit-key-ind`,next:p??m?.[0],offset:d,onError:i,parentIndent:r.indent,startOnNewline:!1});if(!g.found){if(!g.anchor&&!g.tag&&!m&&!h){a===0&&g.comma?i(g.comma,`UNEXPECTED_TOKEN`,`Unexpected , in ${s}`):a<r.items.length-1&&i(g.start,`UNEXPECTED_TOKEN`,`Unexpected empty item in ${s}`),g.comment&&(c.comment?c.comment+=`
46
+ `+g.comment:c.comment=g.comment),d=g.end;continue}!o&&n.options.strict&&J(p)&&i(p,`MULTILINE_IMPLICIT_KEY`,`Implicit keys of flow sequence pairs need to be on a single line`)}if(a===0)g.comma&&i(g.comma,`UNEXPECTED_TOKEN`,`Unexpected , in ${s}`);else if(g.comma||i(g.start,`MISSING_CHAR`,`Missing , between ${s} items`),g.comment){let e=``;loop:for(let t of f)switch(t.type){case`comma`:case`space`:break;case`comment`:e=t.source.substring(1);break loop;default:break loop}if(e){let t=c.items[c.items.length-1];u(t)&&(t=t.value??t.key),t.comment?t.comment+=`
47
+ `+e:t.comment=e,g.comment=g.comment.substring(e.length+1)}}if(!o&&!m&&!g.found){let r=h?e(n,h,g,i):t(n,g.end,m,null,g,i);c.items.push(r),d=r.range[2],Zt(h)&&i(r.range,`BLOCK_IN_FLOW`,Xt)}else{n.atKey=!0;let a=g.end,u=p?e(n,p,g,i):t(n,a,f,null,g,i);Zt(p)&&i(u.range,`BLOCK_IN_FLOW`,Xt),n.atKey=!1;let _=q(m??[],{flow:s,indicator:`map-value-ind`,next:h,offset:u.range[2],onError:i,parentIndent:r.indent,startOnNewline:!1});if(_.found){if(!o&&!g.found&&n.options.strict){if(m)for(let e of m){if(e===_.found)break;if(e.type===`newline`){i(e,`MULTILINE_IMPLICIT_KEY`,`Implicit keys of flow sequence pairs need to be on a single line`);break}}g.start<_.found.offset-1024&&i(_.found,`KEY_OVER_1024_CHARS`,`The : indicator must be at most 1024 chars after the start of an implicit flow sequence key`)}}else h&&(`source`in h&&h.source?.[0]===`:`?i(h,`MISSING_CHAR`,`Missing space after : in ${s}`):i(_.start,`MISSING_CHAR`,`Missing , or : between ${s} items`));let v=h?e(n,h,_,i):_.found?t(n,_.end,m,null,_,i):null;v?Zt(h)&&i(v.range,`BLOCK_IN_FLOW`,Xt):_.comment&&(u.comment?u.comment+=`
48
+ `+_.comment:u.comment=_.comment);let y=new L(u,v);if(n.options.keepSourceTokens&&(y.srcToken=l),o){let e=c;Kt(n,e.items,u)&&i(a,`DUPLICATE_KEY`,`Map keys must be unique`),e.items.push(y)}else{let e=new z(n.schema);e.flow=!0,e.items.push(y);let t=(v??u).range;e.range=[u.range[0],t[1],t[2]],c.items.push(e)}d=v?v.range[2]:_.end}}let f=o?`}`:`]`,[p,...m]=r.end,h=d;if(p?.source===f)h=p.offset+p.source.length;else{let e=s[0].toUpperCase()+s.substring(1),t=l?`${e} must end with a ${f}`:`${e} in block collection must be sufficiently indented and end with a ${f}`;i(d,l?`MISSING_CHAR`:`BAD_INDENT`,t),p&&p.source.length!==1&&m.unshift(p)}if(m.length>0){let e=Y(m,h,n.options.strict,i);e.comment&&(c.comment?c.comment+=`
49
+ `+e.comment:c.comment=e.comment),c.range=[r.offset,h,e.offset]}else c.range=[r.offset,h,h];return c}function $t(e,t,n,r,i,a){let o=n.type===`block-map`?Jt(e,t,n,r,a):n.type===`block-seq`?Yt(e,t,n,r,a):Qt(e,t,n,r,a),s=o.constructor;return i===`!`||i===s.tagName?(o.tag=s.tagName,o):(i&&(o.tag=i),o)}function en(e,t,n,r,i){let a=r.tag,o=a?t.directives.tagName(a.source,e=>i(a,`TAG_RESOLVE_FAILED`,e)):null;if(n.type===`block-seq`){let{anchor:e,newlineAfterProp:t}=r,n=e&&a?e.offset>a.offset?e:a:e??a;n&&(!t||t.offset<n.offset)&&i(n,`MISSING_CHAR`,`Missing newline after block sequence props`)}let s=n.type===`block-map`?`map`:n.type===`block-seq`?`seq`:n.start.source===`{`?`map`:`seq`;if(!a||!o||o===`!`||o===z.tagName&&s===`map`||o===V.tagName&&s===`seq`)return $t(e,t,n,i,o);let c=t.schema.tags.find(e=>e.tag===o&&e.collection===s);if(!c){let r=t.schema.knownTags[o];if(r?.collection===s)t.schema.tags.push(Object.assign({},r,{default:!1})),c=r;else return r?i(a,`BAD_COLLECTION_TYPE`,`${r.tag} used for ${s} collection, but expects ${r.collection??`scalar`}`,!0):i(a,`TAG_RESOLVE_FAILED`,`Unresolved tag: ${o}`,!0),$t(e,t,n,i,o)}let l=$t(e,t,n,i,o,c),u=c.resolve?.(l,e=>i(a,`TAG_RESOLVE_FAILED`,e),t.options)??l,d=m(u)?u:new O(u);return d.range=l.range,d.tag=o,c?.format&&(d.format=c.format),d}function tn(e,t,n){let r=t.offset,i=nn(t,e.options.strict,n);if(!i)return{value:``,type:null,comment:``,range:[r,r,r]};let a=i.mode===`>`?O.BLOCK_FOLDED:O.BLOCK_LITERAL,o=t.source?rn(t.source):[],s=o.length;for(let e=o.length-1;e>=0;--e){let t=o[e][1];if(t===``||t===`\r`)s=e;else break}if(s===0){let e=i.chomp===`+`&&o.length>0?`
50
50
  `.repeat(Math.max(1,o.length-1)):``,n=r+i.length;return t.source&&(n+=t.source.length),{value:e,type:a,comment:i.comment,range:[r,n,n]}}let c=t.indent+i.indent,l=t.offset+i.length,u=0;for(let t=0;t<s;++t){let[r,a]=o[t];if(a===``||a===`\r`)i.indent===0&&r.length>c&&(c=r.length);else{r.length<c&&n(l+r.length,`MISSING_CHAR`,`Block scalars with more-indented leading empty lines must use an explicit indentation indicator`),i.indent===0&&(c=r.length),u=t,c===0&&!e.atRoot&&n(l,`BAD_INDENT`,`Block scalar values in collections must be indented`);break}l+=r.length+a.length+1}for(let e=o.length-1;e>=s;--e)o[e][0].length>c&&(s=e+1);let d=``,f=``,p=!1;for(let e=0;e<u;++e)d+=o[e][0].slice(c)+`
51
- `;for(let e=u;e<s;++e){let[t,r]=o[e];l+=t.length+r.length+1;let s=r[r.length-1]===`\r`;if(s&&(r=r.slice(0,-1)),r&&t.length<c){let e=`Block scalar lines must not be less indented than their ${i.indent?`explicit indentation indicator`:`first line`}`;n(l-r.length-(s?2:1),`BAD_INDENT`,e),t=``}a===k.BLOCK_LITERAL?(d+=f+t.slice(c)+r,f=`
51
+ `;for(let e=u;e<s;++e){let[t,r]=o[e];l+=t.length+r.length+1;let s=r[r.length-1]===`\r`;if(s&&(r=r.slice(0,-1)),r&&t.length<c){let e=`Block scalar lines must not be less indented than their ${i.indent?`explicit indentation indicator`:`first line`}`;n(l-r.length-(s?2:1),`BAD_INDENT`,e),t=``}a===O.BLOCK_LITERAL?(d+=f+t.slice(c)+r,f=`
52
52
  `):t.length>c||r[0]===` `?(f===` `?f=`
53
53
  `:!p&&f===`
54
54
  `&&(f=`
@@ -61,45 +61,45 @@ $&`).replace(/(?:^|\n)([\t ].*)(?:([\n\t ]*)\n(?![\n\t ]))?/g,`$1$2`).replace(/\
61
61
  `+o[e][0].slice(c);d[d.length-1]!==`
62
62
  `&&(d+=`
63
63
  `);break;default:d+=`
64
- `}let m=r+i.length+t.source.length;return{value:d,type:a,comment:i.comment,range:[r,m,m]}}function sn({offset:e,props:t},n,r){if(t[0].type!==`block-scalar-header`)return r(t[0],`IMPOSSIBLE`,`Block scalar header not found`),null;let{source:i}=t[0],a=i[0],o=0,s=``,c=-1;for(let t=1;t<i.length;++t){let n=i[t];if(!s&&(n===`-`||n===`+`))s=n;else{let r=Number(n);!o&&r?o=r:c===-1&&(c=e+t)}}c!==-1&&r(c,`UNEXPECTED_TOKEN`,`Block scalar header includes extra characters: ${i}`);let l=!1,u=``,d=i.length;for(let e=1;e<t.length;++e){let i=t[e];switch(i.type){case`space`:l=!0;case`newline`:d+=i.source.length;break;case`comment`:n&&!l&&r(i,`MISSING_CHAR`,`Comments must be separated from other tokens by white space characters`),d+=i.source.length,u=i.source.substring(1);break;case`error`:r(i,`UNEXPECTED_TOKEN`,i.message),d+=i.source.length;break;default:{r(i,`UNEXPECTED_TOKEN`,`Unexpected token in block scalar header: ${i.type}`);let e=i.source;e&&typeof e==`string`&&(d+=e.length)}}}return{mode:a,indent:o,chomp:s,comment:u,length:d}}function cn(e){let t=e.split(/\n( *)/),n=t[0],r=n.match(/^( *)/),i=[r?.[1]?[r[1],n.slice(r[1].length)]:[``,n]];for(let e=1;e<t.length;e+=2)i.push([t[e],t[e+1]]);return i}function ln(e,t,n){let{offset:r,type:i,source:a,end:o}=e,s,c,l=(e,t,i)=>n(r+e,t,i);switch(i){case`scalar`:s=k.PLAIN,c=un(a,l);break;case`single-quoted-scalar`:s=k.QUOTE_SINGLE,c=dn(a,l);break;case`double-quoted-scalar`:s=k.QUOTE_DOUBLE,c=pn(a,l);break;default:return n(e,`UNEXPECTED_TOKEN`,`Expected a flow scalar value, but found: ${i}`),{value:``,type:null,comment:``,range:[r,r+a.length,r+a.length]}}let u=r+a.length,d=$t(o,u,t,n);return{value:c,type:s,comment:d.comment,range:[r,u,d.offset]}}function un(e,t){let n=``;switch(e[0]){case` `:n=`a tab character`;break;case`,`:n=`flow indicator character ,`;break;case`%`:n=`directive indicator character %`;break;case`|`:case`>`:n=`block scalar indicator ${e[0]}`;break;case`@`:case"`":n=`reserved character ${e[0]}`}return n&&t(0,`BAD_SCALAR_START`,`Plain value cannot start with ${n}`),fn(e)}function dn(e,t){return(e[e.length-1]!==`'`||e.length===1)&&t(e.length,`MISSING_CHAR`,`Missing closing 'quote`),fn(e.slice(1,-1)).replace(/''/g,`'`)}function fn(e){let t=/(.*?)\r?\n/sy,n=t.exec(e);if(!n)return e;let r,i;try{r=RegExp(`(?<![ ])[ ]+$`),i=RegExp(`^[ ]+|(?<![ ])[ ]+$`,`g`)}catch{r=/[ \t]+$/,i=/^[ \t]+|[ \t]+$/g}let a=n[1].replace(r,``),o=` `,s=t.lastIndex;for(;n=t.exec(e);){let e=n[1].replace(i,``);e===``?o===`
64
+ `}let m=r+i.length+t.source.length;return{value:d,type:a,comment:i.comment,range:[r,m,m]}}function nn({offset:e,props:t},n,r){if(t[0].type!==`block-scalar-header`)return r(t[0],`IMPOSSIBLE`,`Block scalar header not found`),null;let{source:i}=t[0],a=i[0],o=0,s=``,c=-1;for(let t=1;t<i.length;++t){let n=i[t];if(!s&&(n===`-`||n===`+`))s=n;else{let r=Number(n);!o&&r?o=r:c===-1&&(c=e+t)}}c!==-1&&r(c,`UNEXPECTED_TOKEN`,`Block scalar header includes extra characters: ${i}`);let l=!1,u=``,d=i.length;for(let e=1;e<t.length;++e){let i=t[e];switch(i.type){case`space`:l=!0;case`newline`:d+=i.source.length;break;case`comment`:n&&!l&&r(i,`MISSING_CHAR`,`Comments must be separated from other tokens by white space characters`),d+=i.source.length,u=i.source.substring(1);break;case`error`:r(i,`UNEXPECTED_TOKEN`,i.message),d+=i.source.length;break;default:{r(i,`UNEXPECTED_TOKEN`,`Unexpected token in block scalar header: ${i.type}`);let e=i.source;e&&typeof e==`string`&&(d+=e.length)}}}return{mode:a,indent:o,chomp:s,comment:u,length:d}}function rn(e){let t=e.split(/\n( *)/),n=t[0],r=n.match(/^( *)/),i=[r?.[1]?[r[1],n.slice(r[1].length)]:[``,n]];for(let e=1;e<t.length;e+=2)i.push([t[e],t[e+1]]);return i}function an(e,t,n){let{offset:r,type:i,source:a,end:o}=e,s,c,l=(e,t,i)=>n(r+e,t,i);switch(i){case`scalar`:s=O.PLAIN,c=on(a,l);break;case`single-quoted-scalar`:s=O.QUOTE_SINGLE,c=sn(a,l);break;case`double-quoted-scalar`:s=O.QUOTE_DOUBLE,c=ln(a,l);break;default:return n(e,`UNEXPECTED_TOKEN`,`Expected a flow scalar value, but found: ${i}`),{value:``,type:null,comment:``,range:[r,r+a.length,r+a.length]}}let u=r+a.length,d=Y(o,u,t,n);return{value:c,type:s,comment:d.comment,range:[r,u,d.offset]}}function on(e,t){let n=``;switch(e[0]){case` `:n=`a tab character`;break;case`,`:n=`flow indicator character ,`;break;case`%`:n=`directive indicator character %`;break;case`|`:case`>`:n=`block scalar indicator ${e[0]}`;break;case`@`:case"`":n=`reserved character ${e[0]}`}return n&&t(0,`BAD_SCALAR_START`,`Plain value cannot start with ${n}`),cn(e)}function sn(e,t){return(e[e.length-1]!==`'`||e.length===1)&&t(e.length,`MISSING_CHAR`,`Missing closing 'quote`),cn(e.slice(1,-1)).replace(/''/g,`'`)}function cn(e){let t=/(.*?)\r?\n/sy,n=t.exec(e);if(!n)return e;let r,i;try{r=RegExp(`(?<![ ])[ ]+$`),i=RegExp(`^[ ]+|(?<![ ])[ ]+$`,`g`)}catch{r=/[ \t]+$/,i=/^[ \t]+|[ \t]+$/g}let a=n[1].replace(r,``),o=` `,s=t.lastIndex;for(;n=t.exec(e);){let e=n[1].replace(i,``);e===``?o===`
65
65
  `?a+=o:o=`
66
- `:(a+=o+e,o=` `),s=t.lastIndex}let c=/[ \t]*(.*)/sy;return c.lastIndex=s,n=c.exec(e),a+o+(n?.[1]??``)}function pn(e,t){let n=``;for(let r=1;r<e.length-1;++r){let i=e[r];if(i!==`\r`||e[r+1]!==`
66
+ `:(a+=o+e,o=` `),s=t.lastIndex}let c=/[ \t]*(.*)/sy;return c.lastIndex=s,n=c.exec(e),a+o+(n?.[1]??``)}function ln(e,t){let n=``;for(let r=1;r<e.length-1;++r){let i=e[r];if(i!==`\r`||e[r+1]!==`
67
67
  `){if(i===`
68
- `){let{fold:t,offset:i}=mn(e,r);n+=t,r=i}else if(i===`\\`){let i=e[++r],a=hn[i];if(a)n+=a;else if(i===`
68
+ `){let{fold:t,offset:i}=un(e,r);n+=t,r=i}else if(i===`\\`){let i=e[++r],a=dn[i];if(a)n+=a;else if(i===`
69
69
  `)for(i=e[r+1];i===` `||i===` `;)i=e[++r+1];else if(i===`\r`&&e[r+1]===`
70
- `)for(i=e[++r+1];i===` `||i===` `;)i=e[++r+1];else if(i===`x`||i===`u`||i===`U`){let a=i===`x`?2:i===`u`?4:8;n+=gn(e,r+1,a,t),r+=a}else{let i=e.substr(r-1,2);t(r-1,`BAD_DQ_ESCAPE`,`Invalid escape sequence ${i}`),n+=i}}else if(i===` `||i===` `){let t=r,a=e[r+1];for(;a===` `||a===` `;)a=e[++r+1];a!==`
70
+ `)for(i=e[++r+1];i===` `||i===` `;)i=e[++r+1];else if(i===`x`||i===`u`||i===`U`){let a=i===`x`?2:i===`u`?4:8;n+=fn(e,r+1,a,t),r+=a}else{let i=e.substr(r-1,2);t(r-1,`BAD_DQ_ESCAPE`,`Invalid escape sequence ${i}`),n+=i}}else if(i===` `||i===` `){let t=r,a=e[r+1];for(;a===` `||a===` `;)a=e[++r+1];a!==`
71
71
  `&&(a!==`\r`||e[r+2]!==`
72
- `)&&(n+=r>t?e.slice(t,r+1):i)}else n+=i}}return(e[e.length-1]!==`"`||e.length===1)&&t(e.length,`MISSING_CHAR`,`Missing closing "quote`),n}function mn(e,t){let n=``,r=e[t+1];for(;(r===` `||r===` `||r===`
72
+ `)&&(n+=r>t?e.slice(t,r+1):i)}else n+=i}}return(e[e.length-1]!==`"`||e.length===1)&&t(e.length,`MISSING_CHAR`,`Missing closing "quote`),n}function un(e,t){let n=``,r=e[t+1];for(;(r===` `||r===` `||r===`
73
73
  `||r===`\r`)&&(r!==`\r`||e[t+2]===`
74
74
  `);)r===`
75
75
  `&&(n+=`
76
- `),t+=1,r=e[t+1];return n||=` `,{fold:n,offset:t}}var hn={0:`\0`,a:`\x07`,b:`\b`,e:`\x1B`,f:`\f`,n:`
77
- `,r:`\r`,t:` `,v:`\v`,N:`…`,_:`\xA0`,L:`\u2028`,P:`\u2029`," ":` `,'"':`"`,"/":`/`,"\\":`\\`," ":` `};function gn(e,t,n,r){let i=e.substr(t,n),a=i.length===n&&/^[0-9a-fA-F]+$/.test(i)?parseInt(i,16):NaN;try{return String.fromCodePoint(a)}catch{let i=e.substr(t-2,n+2);return r(t-2,`BAD_DQ_ESCAPE`,`Invalid escape sequence ${i}`),i}}function _n(e,t,n,r){let{value:i,type:a,comment:o,range:c}=t.type===`block-scalar`?on(e,t,r):ln(t,e.options.strict,r),l=n?e.directives.tagName(n.source,e=>r(n,`TAG_RESOLVE_FAILED`,e)):null,u;u=e.options.stringKeys&&e.atKey?e.schema[s]:l?vn(e.schema,i,l,n,r):t.type===`scalar`?yn(e,i,t,r):e.schema[s];let d;try{let a=u.resolve(i,e=>r(n??t,`TAG_RESOLVE_FAILED`,e),e.options);d=m(a)?a:new k(a)}catch(e){let a=e instanceof Error?e.message:String(e);r(n??t,`TAG_RESOLVE_FAILED`,a),d=new k(i)}return d.range=c,d.source=i,a&&(d.type=a),l&&(d.tag=l),u.format&&(d.format=u.format),o&&(d.comment=o),d}function vn(e,t,n,r,i){if(n===`!`)return e[s];let a=[];for(let t of e.tags)if(!t.collection&&t.tag===n){if(t.default&&t.test)a.push(t);else return t}for(let e of a)if(e.test?.test(t))return e;let o=e.knownTags[n];return o&&!o.collection?(e.tags.push(Object.assign({},o,{default:!1,test:void 0})),o):(i(r,`TAG_RESOLVE_FAILED`,`Unresolved tag: ${n}`,n!==`tag:yaml.org,2002:str`),e[s])}function yn({atKey:e,directives:t,schema:n},r,i,a){let o=n.tags.find(t=>(t.default===!0||e&&t.default===`key`)&&t.test?.test(r))||n[s];if(n.compat){let e=n.compat.find(e=>e.default&&e.test?.test(r))??n[s];o.tag!==e.tag&&a(i,`TAG_RESOLVE_FAILED`,`Value may be parsed as either ${t.tagString(o.tag)} or ${t.tagString(e.tag)}`,!0)}return o}function bn(e,t,n){if(t){n??=t.length;for(let r=n-1;r>=0;--r){let n=t[r];switch(n.type){case`space`:case`comment`:case`newline`:e-=n.source.length;continue}for(n=t[++r];n?.type===`space`;)e+=n.source.length,n=t[++r];break}}return e}var xn={composeNode:Sn,composeEmptyNode:Cn};function Sn(e,t,n,r){let i=e.atKey,{spaceBefore:a,comment:o,anchor:s,tag:c}=n,l,u=!0;switch(t.type){case`alias`:l=wn(e,t,r),(s||c)&&r(t,`ALIAS_PROPS`,`An alias node must not specify any properties`);break;case`scalar`:case`single-quoted-scalar`:case`double-quoted-scalar`:case`block-scalar`:l=_n(e,t,c,r),s&&(l.anchor=s.source.substring(1));break;case`block-map`:case`block-seq`:case`flow-collection`:try{l=an(xn,e,t,n,r),s&&(l.anchor=s.source.substring(1))}catch(e){r(t,`RESOURCE_EXHAUSTION`,e instanceof Error?e.message:String(e))}break;default:r(t,`UNEXPECTED_TOKEN`,t.type===`error`?t.message:`Unsupported token (type: ${t.type})`),u=!1}return l??=Cn(e,t.offset,void 0,null,n,r),s&&l.anchor===``&&r(s,`BAD_ALIAS`,`Anchor cannot be an empty string`),i&&e.options.stringKeys&&(!m(l)||typeof l.value!=`string`||l.tag&&l.tag!==`tag:yaml.org,2002:str`)&&r(c??t,`NON_STRING_KEY`,`With stringKeys, all keys must be strings`),a&&(l.spaceBefore=!0),o&&(t.type===`scalar`&&t.source===``?l.comment=o:l.commentBefore=o),e.options.keepSourceTokens&&u&&(l.srcToken=t),l}function Cn(e,t,n,r,{spaceBefore:i,comment:a,anchor:o,tag:s,end:c},l){let u=_n(e,{type:`scalar`,offset:bn(t,n,r),indent:-1,source:``},s,l);return o&&(u.anchor=o.source.substring(1),u.anchor===``&&l(o,`BAD_ALIAS`,`Anchor cannot be an empty string`)),i&&(u.spaceBefore=!0),a&&(u.comment=a,u.range[2]=c),u}function wn({options:e},{offset:t,source:n,end:r},i){let a=new ce(n.substring(1));a.source===``&&i(t,`BAD_ALIAS`,`Alias cannot be an empty string`),a.source.endsWith(`:`)&&i(t+n.length-1,`BAD_ALIAS`,`Alias ending in : is ambiguous`,!0);let o=t+n.length,s=$t(r,o,e.strict,i);return a.range=[t,o,s.offset],s.comment&&(a.comment=s.comment),a}function Tn(e,t,{offset:n,start:r,value:i,end:a},o){let s=new Wt(void 0,Object.assign({_directives:t},e)),c={atKey:!1,atRoot:!0,directives:s.directives,options:s.options,schema:s.schema},l=q(r,{indicator:`doc-start`,next:i??a?.[0],offset:n,onError:o,parentIndent:0,startOnNewline:!0});l.found&&(s.directives.docStart=!0,i&&(i.type===`block-map`||i.type===`block-seq`)&&!l.hasNewline&&o(l.end,`MISSING_CHAR`,`Block collection cannot start on same line with directives-end marker`)),s.contents=i?Sn(c,i,l,o):Cn(c,l.end,r,null,l,o);let u=s.contents.range[2],d=$t(a,u,!1,o);return d.comment&&(s.comment=d.comment),s.range=[n,u,d.offset],s}function Y(e){if(typeof e==`number`)return[e,e+1];if(Array.isArray(e))return e.length===2?e:[e[0],e[1]];let{offset:t,source:n}=e;return[t,t+(typeof n==`string`?n.length:1)]}function En(e){let t=``,n=!1,r=!1;for(let i=0;i<e.length;++i){let a=e[i];switch(a[0]){case`#`:t+=(t===``?``:r?`
76
+ `),t+=1,r=e[t+1];return n||=` `,{fold:n,offset:t}}var dn={0:`\0`,a:`\x07`,b:`\b`,e:`\x1B`,f:`\f`,n:`
77
+ `,r:`\r`,t:` `,v:`\v`,N:`…`,_:`\xA0`,L:`\u2028`,P:`\u2029`," ":` `,'"':`"`,"/":`/`,"\\":`\\`," ":` `};function fn(e,t,n,r){let i=e.substr(t,n),a=i.length===n&&/^[0-9a-fA-F]+$/.test(i)?parseInt(i,16):NaN;try{return String.fromCodePoint(a)}catch{let i=e.substr(t-2,n+2);return r(t-2,`BAD_DQ_ESCAPE`,`Invalid escape sequence ${i}`),i}}function pn(e,t,n,r){let{value:a,type:o,comment:s,range:c}=t.type===`block-scalar`?tn(e,t,r):an(t,e.options.strict,r),l=n?e.directives.tagName(n.source,e=>r(n,`TAG_RESOLVE_FAILED`,e)):null,u;u=e.options.stringKeys&&e.atKey?e.schema[i]:l?mn(e.schema,a,l,n,r):t.type===`scalar`?hn(e,a,t,r):e.schema[i];let f;try{let i=u.resolve(a,e=>r(n??t,`TAG_RESOLVE_FAILED`,e),e.options);f=d(i)?i:new O(i)}catch(e){let i=e instanceof Error?e.message:String(e);r(n??t,`TAG_RESOLVE_FAILED`,i),f=new O(a)}return f.range=c,f.source=a,o&&(f.type=o),l&&(f.tag=l),u.format&&(f.format=u.format),s&&(f.comment=s),f}function mn(e,t,n,r,a){if(n===`!`)return e[i];let o=[];for(let t of e.tags)if(!t.collection&&t.tag===n){if(t.default&&t.test)o.push(t);else return t}for(let e of o)if(e.test?.test(t))return e;let s=e.knownTags[n];return s&&!s.collection?(e.tags.push(Object.assign({},s,{default:!1,test:void 0})),s):(a(r,`TAG_RESOLVE_FAILED`,`Unresolved tag: ${n}`,n!==`tag:yaml.org,2002:str`),e[i])}function hn({atKey:e,directives:t,schema:n},r,a,o){let s=n.tags.find(t=>(t.default===!0||e&&t.default===`key`)&&t.test?.test(r))||n[i];if(n.compat){let e=n.compat.find(e=>e.default&&e.test?.test(r))??n[i];s.tag!==e.tag&&o(a,`TAG_RESOLVE_FAILED`,`Value may be parsed as either ${t.tagString(s.tag)} or ${t.tagString(e.tag)}`,!0)}return s}function gn(e,t,n){if(t){n??=t.length;for(let r=n-1;r>=0;--r){let n=t[r];switch(n.type){case`space`:case`comment`:case`newline`:e-=n.source.length;continue}for(n=t[++r];n?.type===`space`;)e+=n.source.length,n=t[++r];break}}return e}var _n={composeNode:vn,composeEmptyNode:yn};function vn(e,t,n,r){let i=e.atKey,{spaceBefore:a,comment:o,anchor:s,tag:c}=n,l,u=!0;switch(t.type){case`alias`:l=bn(e,t,r),(s||c)&&r(t,`ALIAS_PROPS`,`An alias node must not specify any properties`);break;case`scalar`:case`single-quoted-scalar`:case`double-quoted-scalar`:case`block-scalar`:l=pn(e,t,c,r),s&&(l.anchor=s.source.substring(1));break;case`block-map`:case`block-seq`:case`flow-collection`:try{l=en(_n,e,t,n,r),s&&(l.anchor=s.source.substring(1))}catch(e){r(t,`RESOURCE_EXHAUSTION`,e instanceof Error?e.message:String(e))}break;default:r(t,`UNEXPECTED_TOKEN`,t.type===`error`?t.message:`Unsupported token (type: ${t.type})`),u=!1}return l??=yn(e,t.offset,void 0,null,n,r),s&&l.anchor===``&&r(s,`BAD_ALIAS`,`Anchor cannot be an empty string`),i&&e.options.stringKeys&&(!d(l)||typeof l.value!=`string`||l.tag&&l.tag!==`tag:yaml.org,2002:str`)&&r(c??t,`NON_STRING_KEY`,`With stringKeys, all keys must be strings`),a&&(l.spaceBefore=!0),o&&(t.type===`scalar`&&t.source===``?l.comment=o:l.commentBefore=o),e.options.keepSourceTokens&&u&&(l.srcToken=t),l}function yn(e,t,n,r,{spaceBefore:i,comment:a,anchor:o,tag:s,end:c},l){let u=pn(e,{type:`scalar`,offset:gn(t,n,r),indent:-1,source:``},s,l);return o&&(u.anchor=o.source.substring(1),u.anchor===``&&l(o,`BAD_ALIAS`,`Anchor cannot be an empty string`)),i&&(u.spaceBefore=!0),a&&(u.comment=a,u.range[2]=c),u}function bn({options:e},{offset:t,source:n,end:r},i){let a=new oe(n.substring(1));a.source===``&&i(t,`BAD_ALIAS`,`Alias cannot be an empty string`),a.source.endsWith(`:`)&&i(t+n.length-1,`BAD_ALIAS`,`Alias ending in : is ambiguous`,!0);let o=t+n.length,s=Y(r,o,e.strict,i);return a.range=[t,o,s.offset],s.comment&&(a.comment=s.comment),a}function xn(e,t,{offset:n,start:r,value:i,end:a},o){let s=new Vt(void 0,Object.assign({_directives:t},e)),c={atKey:!1,atRoot:!0,directives:s.directives,options:s.options,schema:s.schema},l=q(r,{indicator:`doc-start`,next:i??a?.[0],offset:n,onError:o,parentIndent:0,startOnNewline:!0});l.found&&(s.directives.docStart=!0,i&&(i.type===`block-map`||i.type===`block-seq`)&&!l.hasNewline&&o(l.end,`MISSING_CHAR`,`Block collection cannot start on same line with directives-end marker`)),s.contents=i?vn(c,i,l,o):yn(c,l.end,r,null,l,o);let u=s.contents.range[2],d=Y(a,u,!1,o);return d.comment&&(s.comment=d.comment),s.range=[n,u,d.offset],s}function Sn(e){if(typeof e==`number`)return[e,e+1];if(Array.isArray(e))return e.length===2?e:[e[0],e[1]];let{offset:t,source:n}=e;return[t,t+(typeof n==`string`?n.length:1)]}function Cn(e){let t=``,n=!1,r=!1;for(let i=0;i<e.length;++i){let a=e[i];switch(a[0]){case`#`:t+=(t===``?``:r?`
78
78
 
79
79
  `:`
80
- `)+(a.substring(1)||` `),n=!0,r=!1;break;case`%`:e[i+1]?.[0]!==`#`&&(i+=1),n=!1;break;default:n||(r=!0),n=!1}}return{comment:t,afterEmptyLine:r}}var Dn=class{constructor(e={}){this.doc=null,this.atDirectives=!1,this.prelude=[],this.errors=[],this.warnings=[],this.onError=(e,t,n,r)=>{let i=Y(e);r?this.warnings.push(new Kt(i,t,n)):this.errors.push(new K(i,t,n))},this.directives=new E({version:e.version||`1.2`}),this.options=e}decorate(e,t){let{comment:n,afterEmptyLine:r}=En(this.prelude);if(n){let i=e.contents;if(t)e.comment=e.comment?`${e.comment}\n${n}`:n;else if(r||e.directives.docStart||!i)e.commentBefore=n;else if(g(i)&&!i.flow&&i.items.length>0){let e=i.items[0];p(e)&&(e=e.key);let t=e.commentBefore;e.commentBefore=t?`${n}\n${t}`:n}else{let e=i.commentBefore;i.commentBefore=e?`${n}\n${e}`:n}}if(t){for(let t=0;t<this.errors.length;++t)e.errors.push(this.errors[t]);for(let t=0;t<this.warnings.length;++t)e.warnings.push(this.warnings[t])}else e.errors=this.errors,e.warnings=this.warnings;this.prelude=[],this.errors=[],this.warnings=[]}streamInfo(){return{comment:En(this.prelude).comment,directives:this.directives,errors:this.errors,warnings:this.warnings}}*compose(e,t=!1,n=-1){for(let t of e)yield*this.next(t);yield*this.end(t,n)}*next(e){switch(e.type){case`directive`:this.directives.add(e.source,(t,n,r)=>{let i=Y(e);i[0]+=t,this.onError(i,`BAD_DIRECTIVE`,n,r)}),this.prelude.push(e.source),this.atDirectives=!0;break;case`document`:{let t=Tn(this.options,this.directives,e,this.onError);this.atDirectives&&!t.directives.docStart&&this.onError(e,`MISSING_CHAR`,`Missing directives-end/doc-start indicator line`),this.decorate(t,!1),this.doc&&(yield this.doc),this.doc=t,this.atDirectives=!1;break}case`byte-order-mark`:case`space`:break;case`comment`:case`newline`:this.prelude.push(e.source);break;case`error`:{let t=e.source?`${e.message}: ${JSON.stringify(e.source)}`:e.message,n=new K(Y(e),`UNEXPECTED_TOKEN`,t);this.atDirectives||!this.doc?this.errors.push(n):this.doc.errors.push(n);break}case`doc-end`:{if(!this.doc){this.errors.push(new K(Y(e),`UNEXPECTED_TOKEN`,`Unexpected doc-end without preceding document`));break}this.doc.directives.docEnd=!0;let t=$t(e.end,e.offset+e.source.length,this.doc.options.strict,this.onError);if(this.decorate(this.doc,!0),t.comment){let e=this.doc.comment;this.doc.comment=e?`${e}\n${t.comment}`:t.comment}this.doc.range[2]=t.offset;break}default:this.errors.push(new K(Y(e),`UNEXPECTED_TOKEN`,`Unsupported token ${e.type}`))}}*end(e=!1,t=-1){if(this.doc)this.decorate(this.doc,!0),yield this.doc,this.doc=null;else if(e){let e=new Wt(void 0,Object.assign({_directives:this.directives},this.options));this.atDirectives&&this.onError(t,`MISSING_CHAR`,`Missing directives-end indicator line`),e.range=[0,t,t],this.decorate(e,!1),yield e}}},On=Symbol(`break visit`),kn=Symbol(`skip children`),An=Symbol(`remove item`);function X(e,t){`type`in e&&e.type===`document`&&(e={start:e.start,value:e.value}),jn(Object.freeze([]),e,t)}X.BREAK=On,X.SKIP=kn,X.REMOVE=An,X.itemAtPath=(e,t)=>{let n=e;for(let[e,r]of t){let t=n?.[e];if(t&&`items`in t)n=t.items[r];else return}return n},X.parentCollection=(e,t)=>{let n=X.itemAtPath(e,t.slice(0,-1)),r=t[t.length-1][0],i=n?.[r];if(i&&`items`in i)return i;throw Error(`Parent collection not found`)};function jn(e,t,n){let r=n(t,e);if(typeof r==`symbol`)return r;for(let i of[`key`,`value`]){let a=t[i];if(a&&`items`in a){for(let t=0;t<a.items.length;++t){let r=jn(Object.freeze(e.concat([[i,t]])),a.items[t],n);if(typeof r==`number`)t=r-1;else if(r===On)return On;else r===An&&(a.items.splice(t,1),--t)}typeof r==`function`&&i===`key`&&(r=r(t,e))}}return typeof r==`function`?r(t,e):r}function Mn(e){switch(e){case``:return`byte-order-mark`;case``:return`doc-mode`;case``:return`flow-error-end`;case``:return`scalar`;case`---`:return`doc-start`;case`...`:return`doc-end`;case``:case`
80
+ `)+(a.substring(1)||` `),n=!0,r=!1;break;case`%`:e[i+1]?.[0]!==`#`&&(i+=1),n=!1;break;default:n||(r=!0),n=!1}}return{comment:t,afterEmptyLine:r}}var wn=class{constructor(e={}){this.doc=null,this.atDirectives=!1,this.prelude=[],this.errors=[],this.warnings=[],this.onError=(e,t,n,r)=>{let i=Sn(e);r?this.warnings.push(new Ut(i,t,n)):this.errors.push(new K(i,t,n))},this.directives=new T({version:e.version||`1.2`}),this.options=e}decorate(e,t){let{comment:n,afterEmptyLine:r}=Cn(this.prelude);if(n){let i=e.contents;if(t)e.comment=e.comment?`${e.comment}\n${n}`:n;else if(r||e.directives.docStart||!i)e.commentBefore=n;else if(p(i)&&!i.flow&&i.items.length>0){let e=i.items[0];u(e)&&(e=e.key);let t=e.commentBefore;e.commentBefore=t?`${n}\n${t}`:n}else{let e=i.commentBefore;i.commentBefore=e?`${n}\n${e}`:n}}if(t){for(let t=0;t<this.errors.length;++t)e.errors.push(this.errors[t]);for(let t=0;t<this.warnings.length;++t)e.warnings.push(this.warnings[t])}else e.errors=this.errors,e.warnings=this.warnings;this.prelude=[],this.errors=[],this.warnings=[]}streamInfo(){return{comment:Cn(this.prelude).comment,directives:this.directives,errors:this.errors,warnings:this.warnings}}*compose(e,t=!1,n=-1){for(let t of e)yield*this.next(t);yield*this.end(t,n)}*next(e){switch(e.type){case`directive`:this.directives.add(e.source,(t,n,r)=>{let i=Sn(e);i[0]+=t,this.onError(i,`BAD_DIRECTIVE`,n,r)}),this.prelude.push(e.source),this.atDirectives=!0;break;case`document`:{let t=xn(this.options,this.directives,e,this.onError);this.atDirectives&&!t.directives.docStart&&this.onError(e,`MISSING_CHAR`,`Missing directives-end/doc-start indicator line`),this.decorate(t,!1),this.doc&&(yield this.doc),this.doc=t,this.atDirectives=!1;break}case`byte-order-mark`:case`space`:break;case`comment`:case`newline`:this.prelude.push(e.source);break;case`error`:{let t=e.source?`${e.message}: ${JSON.stringify(e.source)}`:e.message,n=new K(Sn(e),`UNEXPECTED_TOKEN`,t);this.atDirectives||!this.doc?this.errors.push(n):this.doc.errors.push(n);break}case`doc-end`:{if(!this.doc){this.errors.push(new K(Sn(e),`UNEXPECTED_TOKEN`,`Unexpected doc-end without preceding document`));break}this.doc.directives.docEnd=!0;let t=Y(e.end,e.offset+e.source.length,this.doc.options.strict,this.onError);if(this.decorate(this.doc,!0),t.comment){let e=this.doc.comment;this.doc.comment=e?`${e}\n${t.comment}`:t.comment}this.doc.range[2]=t.offset;break}default:this.errors.push(new K(Sn(e),`UNEXPECTED_TOKEN`,`Unsupported token ${e.type}`))}}*end(e=!1,t=-1){if(this.doc)this.decorate(this.doc,!0),yield this.doc,this.doc=null;else if(e){let e=new Vt(void 0,Object.assign({_directives:this.directives},this.options));this.atDirectives&&this.onError(t,`MISSING_CHAR`,`Missing directives-end indicator line`),e.range=[0,t,t],this.decorate(e,!1),yield e}}},Tn=Symbol(`break visit`),En=Symbol(`skip children`),Dn=Symbol(`remove item`);function X(e,t){`type`in e&&e.type===`document`&&(e={start:e.start,value:e.value}),On(Object.freeze([]),e,t)}X.BREAK=Tn,X.SKIP=En,X.REMOVE=Dn,X.itemAtPath=(e,t)=>{let n=e;for(let[e,r]of t){let t=n?.[e];if(t&&`items`in t)n=t.items[r];else return}return n},X.parentCollection=(e,t)=>{let n=X.itemAtPath(e,t.slice(0,-1)),r=t[t.length-1][0],i=n?.[r];if(i&&`items`in i)return i;throw Error(`Parent collection not found`)};function On(e,t,n){let r=n(t,e);if(typeof r==`symbol`)return r;for(let i of[`key`,`value`]){let a=t[i];if(a&&`items`in a){for(let t=0;t<a.items.length;++t){let r=On(Object.freeze(e.concat([[i,t]])),a.items[t],n);if(typeof r==`number`)t=r-1;else if(r===Tn)return Tn;else r===Dn&&(a.items.splice(t,1),--t)}typeof r==`function`&&i===`key`&&(r=r(t,e))}}return typeof r==`function`?r(t,e):r}function kn(e){switch(e){case``:return`byte-order-mark`;case``:return`doc-mode`;case``:return`flow-error-end`;case``:return`scalar`;case`---`:return`doc-start`;case`...`:return`doc-end`;case``:case`
81
81
  `:case`\r
82
82
  `:return`newline`;case`-`:return`seq-item-ind`;case`?`:return`explicit-key-ind`;case`:`:return`map-value-ind`;case`{`:return`flow-map-start`;case`}`:return`flow-map-end`;case`[`:return`flow-seq-start`;case`]`:return`flow-seq-end`;case`,`:return`comma`}switch(e[0]){case` `:case` `:return`space`;case`#`:return`comment`;case`%`:return`directive-line`;case`*`:return`alias`;case`&`:return`anchor`;case`!`:return`tag`;case`'`:return`single-quoted-scalar`;case`"`:return`double-quoted-scalar`;case`|`:case`>`:return`block-scalar-header`}return null}function Z(e){switch(e){case void 0:case` `:case`
83
- `:case`\r`:case` `:return!0;default:return!1}}var Nn=new Set(`0123456789ABCDEFabcdef`),Pn=new Set(`0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-#;/?:@&=+$_.!~*'()`),Fn=new Set(`,[]{}`),In=new Set(` ,[]{}
84
- \r `),Ln=e=>!e||In.has(e),Rn=class{constructor(){this.atEnd=!1,this.blockScalarIndent=-1,this.blockScalarKeep=!1,this.buffer=``,this.flowKey=!1,this.flowLevel=0,this.indentNext=0,this.indentValue=0,this.lineEndPos=null,this.next=null,this.pos=0}*lex(e,t=!1){if(e){if(typeof e!=`string`)throw TypeError(`source is not a string`);this.buffer=this.buffer?this.buffer+e:e,this.lineEndPos=null}this.atEnd=!t;let n=this.next??`stream`;for(;n&&(t||this.hasChars(1));)n=yield*this.parseNext(n)}atLineEnd(){let e=this.pos,t=this.buffer[e];for(;t===` `||t===` `;)t=this.buffer[++e];return!t||t===`#`||t===`
83
+ `:case`\r`:case` `:return!0;default:return!1}}var An=new Set(`0123456789ABCDEFabcdef`),jn=new Set(`0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-#;/?:@&=+$_.!~*'()`),Mn=new Set(`,[]{}`),Nn=new Set(` ,[]{}
84
+ \r `),Pn=e=>!e||Nn.has(e),Fn=class{constructor(){this.atEnd=!1,this.blockScalarIndent=-1,this.blockScalarKeep=!1,this.buffer=``,this.flowKey=!1,this.flowLevel=0,this.indentNext=0,this.indentValue=0,this.lineEndPos=null,this.next=null,this.pos=0}*lex(e,t=!1){if(e){if(typeof e!=`string`)throw TypeError(`source is not a string`);this.buffer=this.buffer?this.buffer+e:e,this.lineEndPos=null}this.atEnd=!t;let n=this.next??`stream`;for(;n&&(t||this.hasChars(1));)n=yield*this.parseNext(n)}atLineEnd(){let e=this.pos,t=this.buffer[e];for(;t===` `||t===` `;)t=this.buffer[++e];return!t||t===`#`||t===`
85
85
  `||t===`\r`&&this.buffer[e+1]===`
86
86
  `}charAt(e){return this.buffer[this.pos+e]}continueScalar(e){let t=this.buffer[e];if(this.indentNext>0){let n=0;for(;t===` `;)t=this.buffer[++n+e];if(t===`\r`){let t=this.buffer[n+e+1];if(t===`
87
87
  `||!t&&!this.atEnd)return e+n+1}return t===`
88
88
  `||n>=this.indentNext||!t&&!this.atEnd?e+n:-1}if(t===`-`||t===`.`){let t=this.buffer.substr(e,3);if((t===`---`||t===`...`)&&Z(this.buffer[e+3]))return-1}return e}getLine(){let e=this.lineEndPos;return(typeof e!=`number`||e!==-1&&e<this.pos)&&(e=this.buffer.indexOf(`
89
- `,this.pos),this.lineEndPos=e),e===-1?this.atEnd?this.buffer.substring(this.pos):null:(this.buffer[e-1]===`\r`&&--e,this.buffer.substring(this.pos,e))}hasChars(e){return this.pos+e<=this.buffer.length}setNext(e){return this.buffer=this.buffer.substring(this.pos),this.pos=0,this.lineEndPos=null,this.next=e,null}peek(e){return this.buffer.substr(this.pos,e)}*parseNext(e){switch(e){case`stream`:return yield*this.parseStream();case`line-start`:return yield*this.parseLineStart();case`block-start`:return yield*this.parseBlockStart();case`doc`:return yield*this.parseDocument();case`flow`:return yield*this.parseFlowCollection();case`quoted-scalar`:return yield*this.parseQuotedScalar();case`block-scalar`:return yield*this.parseBlockScalar();case`plain-scalar`:return yield*this.parsePlainScalar()}}*parseStream(){let e=this.getLine();if(e===null)return this.setNext(`stream`);if(e[0]===``&&(yield*this.pushCount(1),e=e.substring(1)),e[0]===`%`){let t=e.length,n=e.indexOf(`#`);for(;n!==-1;){let r=e[n-1];if(r===` `||r===` `){t=n-1;break}n=e.indexOf(`#`,n+1)}for(;;){let n=e[t-1];if(n===` `||n===` `)--t;else break}let r=(yield*this.pushCount(t))+(yield*this.pushSpaces(!0));return yield*this.pushCount(e.length-r),this.pushNewline(),`stream`}if(this.atLineEnd()){let t=yield*this.pushSpaces(!0);return yield*this.pushCount(e.length-t),yield*this.pushNewline(),`stream`}return yield``,yield*this.parseLineStart()}*parseLineStart(){let e=this.charAt(0);if(!e&&!this.atEnd)return this.setNext(`line-start`);if(e===`-`||e===`.`){if(!this.atEnd&&!this.hasChars(4))return this.setNext(`line-start`);let e=this.peek(3);if((e===`---`||e===`...`)&&Z(this.charAt(3)))return yield*this.pushCount(3),this.indentValue=0,this.indentNext=0,e===`---`?`doc`:`stream`}return this.indentValue=yield*this.pushSpaces(!1),this.indentNext>this.indentValue&&!Z(this.charAt(1))&&(this.indentNext=this.indentValue),yield*this.parseBlockStart()}*parseBlockStart(){let[e,t]=this.peek(2);if(!t&&!this.atEnd)return this.setNext(`block-start`);if((e===`-`||e===`?`||e===`:`)&&Z(t)){let e=(yield*this.pushCount(1))+(yield*this.pushSpaces(!0));return this.indentNext=this.indentValue+1,this.indentValue+=e,`block-start`}return`doc`}*parseDocument(){yield*this.pushSpaces(!0);let e=this.getLine();if(e===null)return this.setNext(`doc`);let t=yield*this.pushIndicators();switch(e[t]){case`#`:yield*this.pushCount(e.length-t);case void 0:return yield*this.pushNewline(),yield*this.parseLineStart();case`{`:case`[`:return yield*this.pushCount(1),this.flowKey=!1,this.flowLevel=1,`flow`;case`}`:case`]`:return yield*this.pushCount(1),`doc`;case`*`:return yield*this.pushUntil(Ln),`doc`;case`"`:case`'`:return yield*this.parseQuotedScalar();case`|`:case`>`:return t+=yield*this.parseBlockScalarHeader(),t+=yield*this.pushSpaces(!0),yield*this.pushCount(e.length-t),yield*this.pushNewline(),yield*this.parseBlockScalar();default:return yield*this.parsePlainScalar()}}*parseFlowCollection(){let e,t,n=-1;do e=yield*this.pushNewline(),e>0?(t=yield*this.pushSpaces(!1),this.indentValue=n=t):t=0,t+=yield*this.pushSpaces(!0);while(e+t>0);let r=this.getLine();if(r===null)return this.setNext(`flow`);if((n!==-1&&n<this.indentNext&&r[0]!==`#`||n===0&&(r.startsWith(`---`)||r.startsWith(`...`))&&Z(r[3]))&&(n!==this.indentNext-1||this.flowLevel!==1||r[0]!==`]`&&r[0]!==`}`))return this.flowLevel=0,yield``,yield*this.parseLineStart();let i=0;for(;r[i]===`,`;)i+=yield*this.pushCount(1),i+=yield*this.pushSpaces(!0),this.flowKey=!1;switch(i+=yield*this.pushIndicators(),r[i]){case void 0:return`flow`;case`#`:return yield*this.pushCount(r.length-i),`flow`;case`{`:case`[`:return yield*this.pushCount(1),this.flowKey=!1,this.flowLevel+=1,`flow`;case`}`:case`]`:return yield*this.pushCount(1),this.flowKey=!0,--this.flowLevel,this.flowLevel?`flow`:`doc`;case`*`:return yield*this.pushUntil(Ln),`flow`;case`"`:case`'`:return this.flowKey=!0,yield*this.parseQuotedScalar();case`:`:{let e=this.charAt(1);if(this.flowKey||Z(e)||e===`,`)return this.flowKey=!1,yield*this.pushCount(1),yield*this.pushSpaces(!0),`flow`}default:return this.flowKey=!1,yield*this.parsePlainScalar()}}*parseQuotedScalar(){let e=this.charAt(0),t=this.buffer.indexOf(e,this.pos+1);if(e===`'`)for(;t!==-1&&this.buffer[t+1]===`'`;)t=this.buffer.indexOf(`'`,t+2);else for(;t!==-1;){let e=0;for(;this.buffer[t-1-e]===`\\`;)e+=1;if(e%2==0)break;t=this.buffer.indexOf(`"`,t+1)}let n=this.buffer.substring(0,t),r=n.indexOf(`
89
+ `,this.pos),this.lineEndPos=e),e===-1?this.atEnd?this.buffer.substring(this.pos):null:(this.buffer[e-1]===`\r`&&--e,this.buffer.substring(this.pos,e))}hasChars(e){return this.pos+e<=this.buffer.length}setNext(e){return this.buffer=this.buffer.substring(this.pos),this.pos=0,this.lineEndPos=null,this.next=e,null}peek(e){return this.buffer.substr(this.pos,e)}*parseNext(e){switch(e){case`stream`:return yield*this.parseStream();case`line-start`:return yield*this.parseLineStart();case`block-start`:return yield*this.parseBlockStart();case`doc`:return yield*this.parseDocument();case`flow`:return yield*this.parseFlowCollection();case`quoted-scalar`:return yield*this.parseQuotedScalar();case`block-scalar`:return yield*this.parseBlockScalar();case`plain-scalar`:return yield*this.parsePlainScalar()}}*parseStream(){let e=this.getLine();if(e===null)return this.setNext(`stream`);if(e[0]===``&&(yield*this.pushCount(1),e=e.substring(1)),e[0]===`%`){let t=e.length,n=e.indexOf(`#`);for(;n!==-1;){let r=e[n-1];if(r===` `||r===` `){t=n-1;break}n=e.indexOf(`#`,n+1)}for(;;){let n=e[t-1];if(n===` `||n===` `)--t;else break}let r=(yield*this.pushCount(t))+(yield*this.pushSpaces(!0));return yield*this.pushCount(e.length-r),this.pushNewline(),`stream`}if(this.atLineEnd()){let t=yield*this.pushSpaces(!0);return yield*this.pushCount(e.length-t),yield*this.pushNewline(),`stream`}return yield``,yield*this.parseLineStart()}*parseLineStart(){let e=this.charAt(0);if(!e&&!this.atEnd)return this.setNext(`line-start`);if(e===`-`||e===`.`){if(!this.atEnd&&!this.hasChars(4))return this.setNext(`line-start`);let e=this.peek(3);if((e===`---`||e===`...`)&&Z(this.charAt(3)))return yield*this.pushCount(3),this.indentValue=0,this.indentNext=0,e===`---`?`doc`:`stream`}return this.indentValue=yield*this.pushSpaces(!1),this.indentNext>this.indentValue&&!Z(this.charAt(1))&&(this.indentNext=this.indentValue),yield*this.parseBlockStart()}*parseBlockStart(){let[e,t]=this.peek(2);if(!t&&!this.atEnd)return this.setNext(`block-start`);if((e===`-`||e===`?`||e===`:`)&&Z(t)){let e=(yield*this.pushCount(1))+(yield*this.pushSpaces(!0));return this.indentNext=this.indentValue+1,this.indentValue+=e,`block-start`}return`doc`}*parseDocument(){yield*this.pushSpaces(!0);let e=this.getLine();if(e===null)return this.setNext(`doc`);let t=yield*this.pushIndicators();switch(e[t]){case`#`:yield*this.pushCount(e.length-t);case void 0:return yield*this.pushNewline(),yield*this.parseLineStart();case`{`:case`[`:return yield*this.pushCount(1),this.flowKey=!1,this.flowLevel=1,`flow`;case`}`:case`]`:return yield*this.pushCount(1),`doc`;case`*`:return yield*this.pushUntil(Pn),`doc`;case`"`:case`'`:return yield*this.parseQuotedScalar();case`|`:case`>`:return t+=yield*this.parseBlockScalarHeader(),t+=yield*this.pushSpaces(!0),yield*this.pushCount(e.length-t),yield*this.pushNewline(),yield*this.parseBlockScalar();default:return yield*this.parsePlainScalar()}}*parseFlowCollection(){let e,t,n=-1;do e=yield*this.pushNewline(),e>0?(t=yield*this.pushSpaces(!1),this.indentValue=n=t):t=0,t+=yield*this.pushSpaces(!0);while(e+t>0);let r=this.getLine();if(r===null)return this.setNext(`flow`);if((n!==-1&&n<this.indentNext&&r[0]!==`#`||n===0&&(r.startsWith(`---`)||r.startsWith(`...`))&&Z(r[3]))&&(n!==this.indentNext-1||this.flowLevel!==1||r[0]!==`]`&&r[0]!==`}`))return this.flowLevel=0,yield``,yield*this.parseLineStart();let i=0;for(;r[i]===`,`;)i+=yield*this.pushCount(1),i+=yield*this.pushSpaces(!0),this.flowKey=!1;switch(i+=yield*this.pushIndicators(),r[i]){case void 0:return`flow`;case`#`:return yield*this.pushCount(r.length-i),`flow`;case`{`:case`[`:return yield*this.pushCount(1),this.flowKey=!1,this.flowLevel+=1,`flow`;case`}`:case`]`:return yield*this.pushCount(1),this.flowKey=!0,--this.flowLevel,this.flowLevel?`flow`:`doc`;case`*`:return yield*this.pushUntil(Pn),`flow`;case`"`:case`'`:return this.flowKey=!0,yield*this.parseQuotedScalar();case`:`:{let e=this.charAt(1);if(this.flowKey||Z(e)||e===`,`)return this.flowKey=!1,yield*this.pushCount(1),yield*this.pushSpaces(!0),`flow`}default:return this.flowKey=!1,yield*this.parsePlainScalar()}}*parseQuotedScalar(){let e=this.charAt(0),t=this.buffer.indexOf(e,this.pos+1);if(e===`'`)for(;t!==-1&&this.buffer[t+1]===`'`;)t=this.buffer.indexOf(`'`,t+2);else for(;t!==-1;){let e=0;for(;this.buffer[t-1-e]===`\\`;)e+=1;if(e%2==0)break;t=this.buffer.indexOf(`"`,t+1)}let n=this.buffer.substring(0,t),r=n.indexOf(`
90
90
  `,this.pos);if(r!==-1){for(;r!==-1;){let e=this.continueScalar(r+1);if(e===-1)break;r=n.indexOf(`
91
91
  `,e)}r!==-1&&(t=r-(n[r-1]===`\r`?2:1))}if(t===-1){if(!this.atEnd)return this.setNext(`quoted-scalar`);t=this.buffer.length}return yield*this.pushToIndex(t+1,!1),this.flowLevel?`flow`:`doc`}*parseBlockScalarHeader(){this.blockScalarIndent=-1,this.blockScalarKeep=!1;let e=this.pos;for(;;){let t=this.buffer[++e];if(t===`+`)this.blockScalarKeep=!0;else if(t>`0`&&t<=`9`)this.blockScalarIndent=Number(t)-1;else if(t!==`-`)break}return yield*this.pushUntil(e=>Z(e)||e===`#`)}*parseBlockScalar(){let e=this.pos-1,t=0,n;loop:for(let r=this.pos;n=this.buffer[r];++r)switch(n){case` `:t+=1;break;case`
92
92
  `:e=r,t=0;break;case`\r`:{let e=this.buffer[r+1];if(!e&&!this.atEnd)return this.setNext(`block-scalar`);if(e===`
93
93
  `)break}default:break loop}if(!n&&!this.atEnd)return this.setNext(`block-scalar`);if(t>=this.indentNext){this.indentNext=this.blockScalarIndent===-1?t:this.blockScalarIndent+(this.indentNext===0?1:this.indentNext);do{let t=this.continueScalar(e+1);if(t===-1)break;e=this.buffer.indexOf(`
94
94
  `,t)}while(e!==-1);if(e===-1){if(!this.atEnd)return this.setNext(`block-scalar`);e=this.buffer.length}}let r=e+1;for(n=this.buffer[r];n===` `;)n=this.buffer[++r];if(n===` `){for(;n===` `||n===` `||n===`\r`||n===`
95
95
  `;)n=this.buffer[++r];e=r-1}else if(!this.blockScalarKeep)do{let n=e-1,r=this.buffer[n];r===`\r`&&(r=this.buffer[--n]);let i=n;for(;r===` `;)r=this.buffer[--n];if(r===`
96
- `&&n>=this.pos&&n+1+t>i)e=n;else break}while(1);return yield``,yield*this.pushToIndex(e+1,!0),yield*this.parseLineStart()}*parsePlainScalar(){let e=this.flowLevel>0,t=this.pos-1,n=this.pos-1,r;for(;r=this.buffer[++n];)if(r===`:`){let r=this.buffer[n+1];if(Z(r)||e&&Fn.has(r))break;t=n}else if(Z(r)){let i=this.buffer[n+1];if(r===`\r`&&(i===`
96
+ `&&n>=this.pos&&n+1+t>i)e=n;else break}while(1);return yield``,yield*this.pushToIndex(e+1,!0),yield*this.parseLineStart()}*parsePlainScalar(){let e=this.flowLevel>0,t=this.pos-1,n=this.pos-1,r;for(;r=this.buffer[++n];)if(r===`:`){let r=this.buffer[n+1];if(Z(r)||e&&Mn.has(r))break;t=n}else if(Z(r)){let i=this.buffer[n+1];if(r===`\r`&&(i===`
97
97
  `?(n+=1,r=`
98
- `,i=this.buffer[n+1]):t=n),i===`#`||e&&Fn.has(i))break;if(r===`
99
- `){let e=this.continueScalar(n+1);if(e===-1)break;n=Math.max(n,e-2)}}else{if(e&&Fn.has(r))break;t=n}return!r&&!this.atEnd?this.setNext(`plain-scalar`):(yield``,yield*this.pushToIndex(t+1,!0),e?`flow`:`doc`)}*pushCount(e){return e>0?(yield this.buffer.substr(this.pos,e),this.pos+=e,e):0}*pushToIndex(e,t){let n=this.buffer.slice(this.pos,e);return n?(yield n,this.pos+=n.length,n.length):(t&&(yield``),0)}*pushIndicators(){let e=0;loop:for(;;){switch(this.charAt(0)){case`!`:e+=yield*this.pushTag(),e+=yield*this.pushSpaces(!0);continue loop;case`&`:e+=yield*this.pushUntil(Ln),e+=yield*this.pushSpaces(!0);continue loop;case`-`:case`?`:case`:`:{let t=this.flowLevel>0,n=this.charAt(1);if(Z(n)||t&&Fn.has(n)){t?this.flowKey&&=!1:this.indentNext=this.indentValue+1,e+=yield*this.pushCount(1),e+=yield*this.pushSpaces(!0);continue loop}}}break loop}return e}*pushTag(){if(this.charAt(1)===`<`){let e=this.pos+2,t=this.buffer[e];for(;!Z(t)&&t!==`>`;)t=this.buffer[++e];return yield*this.pushToIndex(t===`>`?e+1:e,!1)}{let e=this.pos+1,t=this.buffer[e];for(;t;)if(Pn.has(t))t=this.buffer[++e];else if(t===`%`&&Nn.has(this.buffer[e+1])&&Nn.has(this.buffer[e+2]))t=this.buffer[e+=3];else break;return yield*this.pushToIndex(e,!1)}}*pushNewline(){let e=this.buffer[this.pos];return e===`
98
+ `,i=this.buffer[n+1]):t=n),i===`#`||e&&Mn.has(i))break;if(r===`
99
+ `){let e=this.continueScalar(n+1);if(e===-1)break;n=Math.max(n,e-2)}}else{if(e&&Mn.has(r))break;t=n}return!r&&!this.atEnd?this.setNext(`plain-scalar`):(yield``,yield*this.pushToIndex(t+1,!0),e?`flow`:`doc`)}*pushCount(e){return e>0?(yield this.buffer.substr(this.pos,e),this.pos+=e,e):0}*pushToIndex(e,t){let n=this.buffer.slice(this.pos,e);return n?(yield n,this.pos+=n.length,n.length):(t&&(yield``),0)}*pushIndicators(){let e=0;loop:for(;;){switch(this.charAt(0)){case`!`:e+=yield*this.pushTag(),e+=yield*this.pushSpaces(!0);continue loop;case`&`:e+=yield*this.pushUntil(Pn),e+=yield*this.pushSpaces(!0);continue loop;case`-`:case`?`:case`:`:{let t=this.flowLevel>0,n=this.charAt(1);if(Z(n)||t&&Mn.has(n)){t?this.flowKey&&=!1:this.indentNext=this.indentValue+1,e+=yield*this.pushCount(1),e+=yield*this.pushSpaces(!0);continue loop}}}break loop}return e}*pushTag(){if(this.charAt(1)===`<`){let e=this.pos+2,t=this.buffer[e];for(;!Z(t)&&t!==`>`;)t=this.buffer[++e];return yield*this.pushToIndex(t===`>`?e+1:e,!1)}{let e=this.pos+1,t=this.buffer[e];for(;t;)if(jn.has(t))t=this.buffer[++e];else if(t===`%`&&An.has(this.buffer[e+1])&&An.has(this.buffer[e+2]))t=this.buffer[e+=3];else break;return yield*this.pushToIndex(e,!1)}}*pushNewline(){let e=this.buffer[this.pos];return e===`
100
100
  `?yield*this.pushCount(1):e===`\r`&&this.charAt(1)===`
101
- `?yield*this.pushCount(2):0}*pushSpaces(e){let t=this.pos-1,n;do n=this.buffer[++t];while(n===` `||e&&n===` `);let r=t-this.pos;return r>0&&(yield this.buffer.substr(this.pos,r),this.pos=t),r}*pushUntil(e){let t=this.pos,n=this.buffer[t];for(;!e(n);)n=this.buffer[++t];return yield*this.pushToIndex(t,!1)}},zn=class{constructor(){this.lineStarts=[],this.addNewLine=e=>this.lineStarts.push(e),this.linePos=e=>{let t=0,n=this.lineStarts.length;for(;t<n;){let r=t+n>>1;this.lineStarts[r]<e?t=r+1:n=r}if(this.lineStarts[t]===e)return{line:t+1,col:1};if(t===0)return{line:0,col:e};let r=this.lineStarts[t-1];return{line:t,col:e-r+1}}}};function Q(e,t){for(let n=0;n<e.length;++n)if(e[n].type===t)return!0;return!1}function Bn(e){for(let t=0;t<e.length;++t)switch(e[t].type){case`space`:case`comment`:case`newline`:break;default:return t}return-1}function Vn(e){switch(e?.type){case`alias`:case`scalar`:case`single-quoted-scalar`:case`double-quoted-scalar`:case`flow-collection`:return!0;default:return!1}}function Hn(e){switch(e.type){case`document`:return e.start;case`block-map`:{let t=e.items[e.items.length-1];return t.sep??t.start}case`block-seq`:return e.items[e.items.length-1].start;default:return[]}}function $(e){if(e.length===0)return[];let t=e.length;loop:for(;--t>=0;)switch(e[t].type){case`doc-start`:case`explicit-key-ind`:case`map-value-ind`:case`seq-item-ind`:case`newline`:break loop}for(;e[++t]?.type===`space`;);return e.splice(t,e.length)}function Un(e,t){if(t.length<1e5)Array.prototype.push.apply(e,t);else for(let n=0;n<t.length;++n)e.push(t[n])}function Wn(e){if(e.start.type===`flow-seq-start`)for(let t of e.items)t.sep&&!t.value&&!Q(t.start,`explicit-key-ind`)&&!Q(t.sep,`map-value-ind`)&&(t.key&&(t.value=t.key),delete t.key,Vn(t.value)?t.value.end?Un(t.value.end,t.sep):t.value.end=t.sep:Un(t.start,t.sep),delete t.sep)}var Gn=class{constructor(e){this.atNewLine=!0,this.atScalar=!1,this.indent=0,this.offset=0,this.onKeyLine=!1,this.stack=[],this.source=``,this.type=``,this.lexer=new Rn,this.onNewLine=e}*parse(e,t=!1){this.onNewLine&&this.offset===0&&this.onNewLine(0);for(let n of this.lexer.lex(e,t))yield*this.next(n);t||(yield*this.end())}*next(e){if(this.source=e,this.atScalar){this.atScalar=!1,yield*this.step(),this.offset+=e.length;return}let t=Mn(e);if(!t){let t=`Not a YAML token: ${e}`;yield*this.pop({type:`error`,offset:this.offset,message:t,source:e}),this.offset+=e.length}else if(t===`scalar`)this.atNewLine=!1,this.atScalar=!0,this.type=`scalar`;else{switch(this.type=t,yield*this.step(),t){case`newline`:this.atNewLine=!0,this.indent=0,this.onNewLine&&this.onNewLine(this.offset+e.length);break;case`space`:this.atNewLine&&e[0]===` `&&(this.indent+=e.length);break;case`explicit-key-ind`:case`map-value-ind`:case`seq-item-ind`:this.atNewLine&&(this.indent+=e.length);break;case`doc-mode`:case`flow-error-end`:return;default:this.atNewLine=!1}this.offset+=e.length}}*end(){for(;this.stack.length>0;)yield*this.pop()}get sourceToken(){return{type:this.type,offset:this.offset,indent:this.indent,source:this.source}}*step(){let e=this.peek(1);if(this.type===`doc-end`&&e?.type!==`doc-end`){for(;this.stack.length>0;)yield*this.pop();this.stack.push({type:`doc-end`,offset:this.offset,source:this.source})}else{if(!e)return yield*this.stream();switch(e.type){case`document`:return yield*this.document(e);case`alias`:case`scalar`:case`single-quoted-scalar`:case`double-quoted-scalar`:return yield*this.scalar(e);case`block-scalar`:return yield*this.blockScalar(e);case`block-map`:return yield*this.blockMap(e);case`block-seq`:return yield*this.blockSequence(e);case`flow-collection`:return yield*this.flowCollection(e);case`doc-end`:return yield*this.documentEnd(e)}yield*this.pop()}}peek(e){return this.stack[this.stack.length-e]}*pop(e){let t=e??this.stack.pop();if(!t)yield{type:`error`,offset:this.offset,source:``,message:`Tried to pop an empty stack`};else if(this.stack.length===0)yield t;else{let e=this.peek(1);switch(t.type===`block-scalar`?t.indent=`indent`in e?e.indent:0:t.type===`flow-collection`&&e.type===`document`&&(t.indent=0),t.type===`flow-collection`&&Wn(t),e.type){case`document`:e.value=t;break;case`block-scalar`:e.props.push(t);break;case`block-map`:{let n=e.items[e.items.length-1];if(n.value){e.items.push({start:[],key:t,sep:[]}),this.onKeyLine=!0;return}if(n.sep)n.value=t;else{Object.assign(n,{key:t,sep:[]}),this.onKeyLine=!n.explicitKey;return}break}case`block-seq`:{let n=e.items[e.items.length-1];n.value?e.items.push({start:[],value:t}):n.value=t;break}case`flow-collection`:{let n=e.items[e.items.length-1];!n||n.value?e.items.push({start:[],key:t,sep:[]}):n.sep?n.value=t:Object.assign(n,{key:t,sep:[]});return}default:yield*this.pop(),yield*this.pop(t)}if((e.type===`document`||e.type===`block-map`||e.type===`block-seq`)&&(t.type===`block-map`||t.type===`block-seq`)){let n=t.items[t.items.length-1];n&&!n.sep&&!n.value&&n.start.length>0&&Bn(n.start)===-1&&(t.indent===0||n.start.every(e=>e.type!==`comment`||e.indent<t.indent))&&(e.type===`document`?e.end=n.start:e.items.push({start:n.start}),t.items.splice(-1,1))}}}*stream(){switch(this.type){case`directive-line`:yield{type:`directive`,offset:this.offset,source:this.source};return;case`byte-order-mark`:case`space`:case`comment`:case`newline`:yield this.sourceToken;return;case`doc-mode`:case`doc-start`:{let e={type:`document`,offset:this.offset,start:[]};this.type===`doc-start`&&e.start.push(this.sourceToken),this.stack.push(e);return}}yield{type:`error`,offset:this.offset,message:`Unexpected ${this.type} token in YAML stream`,source:this.source}}*document(e){if(e.value)return yield*this.lineEnd(e);switch(this.type){case`doc-start`:Bn(e.start)===-1?e.start.push(this.sourceToken):(yield*this.pop(),yield*this.step());return;case`anchor`:case`tag`:case`space`:case`comment`:case`newline`:e.start.push(this.sourceToken);return}let t=this.startBlockValue(e);t?this.stack.push(t):yield{type:`error`,offset:this.offset,message:`Unexpected ${this.type} token in YAML document`,source:this.source}}*scalar(e){if(this.type===`map-value-ind`){let t=$(Hn(this.peek(2))),n;e.end?(n=e.end,n.push(this.sourceToken),delete e.end):n=[this.sourceToken];let r={type:`block-map`,offset:e.offset,indent:e.indent,items:[{start:t,key:e,sep:n}]};this.onKeyLine=!0,this.stack[this.stack.length-1]=r}else yield*this.lineEnd(e)}*blockScalar(e){switch(this.type){case`space`:case`comment`:case`newline`:e.props.push(this.sourceToken);return;case`scalar`:if(e.source=this.source,this.atNewLine=!0,this.indent=0,this.onNewLine){let e=this.source.indexOf(`
101
+ `?yield*this.pushCount(2):0}*pushSpaces(e){let t=this.pos-1,n;do n=this.buffer[++t];while(n===` `||e&&n===` `);let r=t-this.pos;return r>0&&(yield this.buffer.substr(this.pos,r),this.pos=t),r}*pushUntil(e){let t=this.pos,n=this.buffer[t];for(;!e(n);)n=this.buffer[++t];return yield*this.pushToIndex(t,!1)}},In=class{constructor(){this.lineStarts=[],this.addNewLine=e=>this.lineStarts.push(e),this.linePos=e=>{let t=0,n=this.lineStarts.length;for(;t<n;){let r=t+n>>1;this.lineStarts[r]<e?t=r+1:n=r}if(this.lineStarts[t]===e)return{line:t+1,col:1};if(t===0)return{line:0,col:e};let r=this.lineStarts[t-1];return{line:t,col:e-r+1}}}};function Q(e,t){for(let n=0;n<e.length;++n)if(e[n].type===t)return!0;return!1}function Ln(e){for(let t=0;t<e.length;++t)switch(e[t].type){case`space`:case`comment`:case`newline`:break;default:return t}return-1}function Rn(e){switch(e?.type){case`alias`:case`scalar`:case`single-quoted-scalar`:case`double-quoted-scalar`:case`flow-collection`:return!0;default:return!1}}function zn(e){switch(e.type){case`document`:return e.start;case`block-map`:{let t=e.items[e.items.length-1];return t.sep??t.start}case`block-seq`:return e.items[e.items.length-1].start;default:return[]}}function $(e){if(e.length===0)return[];let t=e.length;loop:for(;--t>=0;)switch(e[t].type){case`doc-start`:case`explicit-key-ind`:case`map-value-ind`:case`seq-item-ind`:case`newline`:break loop}for(;e[++t]?.type===`space`;);return e.splice(t,e.length)}function Bn(e,t){if(t.length<1e5)Array.prototype.push.apply(e,t);else for(let n=0;n<t.length;++n)e.push(t[n])}function Vn(e){if(e.start.type===`flow-seq-start`)for(let t of e.items)t.sep&&!t.value&&!Q(t.start,`explicit-key-ind`)&&!Q(t.sep,`map-value-ind`)&&(t.key&&(t.value=t.key),delete t.key,Rn(t.value)?t.value.end?Bn(t.value.end,t.sep):t.value.end=t.sep:Bn(t.start,t.sep),delete t.sep)}var Hn=class{constructor(e){this.atNewLine=!0,this.atScalar=!1,this.indent=0,this.offset=0,this.onKeyLine=!1,this.stack=[],this.source=``,this.type=``,this.lexer=new Fn,this.onNewLine=e}*parse(e,t=!1){this.onNewLine&&this.offset===0&&this.onNewLine(0);for(let n of this.lexer.lex(e,t))yield*this.next(n);t||(yield*this.end())}*next(e){if(this.source=e,this.atScalar){this.atScalar=!1,yield*this.step(),this.offset+=e.length;return}let t=kn(e);if(!t){let t=`Not a YAML token: ${e}`;yield*this.pop({type:`error`,offset:this.offset,message:t,source:e}),this.offset+=e.length}else if(t===`scalar`)this.atNewLine=!1,this.atScalar=!0,this.type=`scalar`;else{switch(this.type=t,yield*this.step(),t){case`newline`:this.atNewLine=!0,this.indent=0,this.onNewLine&&this.onNewLine(this.offset+e.length);break;case`space`:this.atNewLine&&e[0]===` `&&(this.indent+=e.length);break;case`explicit-key-ind`:case`map-value-ind`:case`seq-item-ind`:this.atNewLine&&(this.indent+=e.length);break;case`doc-mode`:case`flow-error-end`:return;default:this.atNewLine=!1}this.offset+=e.length}}*end(){for(;this.stack.length>0;)yield*this.pop()}get sourceToken(){return{type:this.type,offset:this.offset,indent:this.indent,source:this.source}}*step(){let e=this.peek(1);if(this.type===`doc-end`&&e?.type!==`doc-end`){for(;this.stack.length>0;)yield*this.pop();this.stack.push({type:`doc-end`,offset:this.offset,source:this.source})}else{if(!e)return yield*this.stream();switch(e.type){case`document`:return yield*this.document(e);case`alias`:case`scalar`:case`single-quoted-scalar`:case`double-quoted-scalar`:return yield*this.scalar(e);case`block-scalar`:return yield*this.blockScalar(e);case`block-map`:return yield*this.blockMap(e);case`block-seq`:return yield*this.blockSequence(e);case`flow-collection`:return yield*this.flowCollection(e);case`doc-end`:return yield*this.documentEnd(e)}yield*this.pop()}}peek(e){return this.stack[this.stack.length-e]}*pop(e){let t=e??this.stack.pop();if(!t)yield{type:`error`,offset:this.offset,source:``,message:`Tried to pop an empty stack`};else if(this.stack.length===0)yield t;else{let e=this.peek(1);switch(t.type===`block-scalar`?t.indent=`indent`in e?e.indent:0:t.type===`flow-collection`&&e.type===`document`&&(t.indent=0),t.type===`flow-collection`&&Vn(t),e.type){case`document`:e.value=t;break;case`block-scalar`:e.props.push(t);break;case`block-map`:{let n=e.items[e.items.length-1];if(n.value){e.items.push({start:[],key:t,sep:[]}),this.onKeyLine=!0;return}if(n.sep)n.value=t;else{Object.assign(n,{key:t,sep:[]}),this.onKeyLine=!n.explicitKey;return}break}case`block-seq`:{let n=e.items[e.items.length-1];n.value?e.items.push({start:[],value:t}):n.value=t;break}case`flow-collection`:{let n=e.items[e.items.length-1];!n||n.value?e.items.push({start:[],key:t,sep:[]}):n.sep?n.value=t:Object.assign(n,{key:t,sep:[]});return}default:yield*this.pop(),yield*this.pop(t)}if((e.type===`document`||e.type===`block-map`||e.type===`block-seq`)&&(t.type===`block-map`||t.type===`block-seq`)){let n=t.items[t.items.length-1];n&&!n.sep&&!n.value&&n.start.length>0&&Ln(n.start)===-1&&(t.indent===0||n.start.every(e=>e.type!==`comment`||e.indent<t.indent))&&(e.type===`document`?e.end=n.start:e.items.push({start:n.start}),t.items.splice(-1,1))}}}*stream(){switch(this.type){case`directive-line`:yield{type:`directive`,offset:this.offset,source:this.source};return;case`byte-order-mark`:case`space`:case`comment`:case`newline`:yield this.sourceToken;return;case`doc-mode`:case`doc-start`:{let e={type:`document`,offset:this.offset,start:[]};this.type===`doc-start`&&e.start.push(this.sourceToken),this.stack.push(e);return}}yield{type:`error`,offset:this.offset,message:`Unexpected ${this.type} token in YAML stream`,source:this.source}}*document(e){if(e.value)return yield*this.lineEnd(e);switch(this.type){case`doc-start`:Ln(e.start)===-1?e.start.push(this.sourceToken):(yield*this.pop(),yield*this.step());return;case`anchor`:case`tag`:case`space`:case`comment`:case`newline`:e.start.push(this.sourceToken);return}let t=this.startBlockValue(e);t?this.stack.push(t):yield{type:`error`,offset:this.offset,message:`Unexpected ${this.type} token in YAML document`,source:this.source}}*scalar(e){if(this.type===`map-value-ind`){let t=$(zn(this.peek(2))),n;e.end?(n=e.end,n.push(this.sourceToken),delete e.end):n=[this.sourceToken];let r={type:`block-map`,offset:e.offset,indent:e.indent,items:[{start:t,key:e,sep:n}]};this.onKeyLine=!0,this.stack[this.stack.length-1]=r}else yield*this.lineEnd(e)}*blockScalar(e){switch(this.type){case`space`:case`comment`:case`newline`:e.props.push(this.sourceToken);return;case`scalar`:if(e.source=this.source,this.atNewLine=!0,this.indent=0,this.onNewLine){let e=this.source.indexOf(`
102
102
  `)+1;for(;e!==0;)this.onNewLine(this.offset+e),e=this.source.indexOf(`
103
- `,e)+1}yield*this.pop();break;default:yield*this.pop(),yield*this.step()}}*blockMap(e){let t=e.items[e.items.length-1];switch(this.type){case`newline`:if(this.onKeyLine=!1,t.value){let n=`end`in t.value?t.value.end:void 0;(Array.isArray(n)?n[n.length-1]:void 0)?.type===`comment`?n?.push(this.sourceToken):e.items.push({start:[this.sourceToken]})}else t.sep?t.sep.push(this.sourceToken):t.start.push(this.sourceToken);return;case`space`:case`comment`:if(t.value)e.items.push({start:[this.sourceToken]});else if(t.sep)t.sep.push(this.sourceToken);else{if(this.atIndentedComment(t.start,e.indent)){let n=e.items[e.items.length-2]?.value?.end;if(Array.isArray(n)){Un(n,t.start),n.push(this.sourceToken),e.items.pop();return}}t.start.push(this.sourceToken)}return}if(this.indent>=e.indent){let n=!this.onKeyLine&&this.indent===e.indent,r=n&&(t.sep||t.explicitKey)&&this.type!==`seq-item-ind`,i=[];if(r&&t.sep&&!t.value){let n=[];for(let r=0;r<t.sep.length;++r){let i=t.sep[r];switch(i.type){case`newline`:n.push(r);break;case`space`:break;case`comment`:i.indent>e.indent&&(n.length=0);break;default:n.length=0}}n.length>=2&&(i=t.sep.splice(n[1]))}switch(this.type){case`anchor`:case`tag`:r||t.value?(i.push(this.sourceToken),e.items.push({start:i}),this.onKeyLine=!0):t.sep?t.sep.push(this.sourceToken):t.start.push(this.sourceToken);return;case`explicit-key-ind`:!t.sep&&!t.explicitKey?(t.start.push(this.sourceToken),t.explicitKey=!0):r||t.value?(i.push(this.sourceToken),e.items.push({start:i,explicitKey:!0})):this.stack.push({type:`block-map`,offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken],explicitKey:!0}]}),this.onKeyLine=!0;return;case`map-value-ind`:if(t.explicitKey){if(!t.sep){if(Q(t.start,`newline`))Object.assign(t,{key:null,sep:[this.sourceToken]});else{let e=$(t.start);this.stack.push({type:`block-map`,offset:this.offset,indent:this.indent,items:[{start:e,key:null,sep:[this.sourceToken]}]})}}else if(t.value)e.items.push({start:[],key:null,sep:[this.sourceToken]});else if(Q(t.sep,`map-value-ind`))this.stack.push({type:`block-map`,offset:this.offset,indent:this.indent,items:[{start:i,key:null,sep:[this.sourceToken]}]});else if(Vn(t.key)&&!Q(t.sep,`newline`)){let e=$(t.start),n=t.key,r=t.sep;r.push(this.sourceToken),delete t.key,delete t.sep,this.stack.push({type:`block-map`,offset:this.offset,indent:this.indent,items:[{start:e,key:n,sep:r}]})}else i.length>0?t.sep=t.sep.concat(i,this.sourceToken):t.sep.push(this.sourceToken)}else t.sep?t.value||r?e.items.push({start:i,key:null,sep:[this.sourceToken]}):Q(t.sep,`map-value-ind`)?this.stack.push({type:`block-map`,offset:this.offset,indent:this.indent,items:[{start:[],key:null,sep:[this.sourceToken]}]}):t.sep.push(this.sourceToken):Object.assign(t,{key:null,sep:[this.sourceToken]});this.onKeyLine=!0;return;case`alias`:case`scalar`:case`single-quoted-scalar`:case`double-quoted-scalar`:{let n=this.flowScalar(this.type);r||t.value?(e.items.push({start:i,key:n,sep:[]}),this.onKeyLine=!0):t.sep?this.stack.push(n):(Object.assign(t,{key:n,sep:[]}),this.onKeyLine=!0);return}default:{let r=this.startBlockValue(e);if(r){if(r.type===`block-seq`){if(!t.explicitKey&&t.sep&&!Q(t.sep,`newline`)){yield*this.pop({type:`error`,offset:this.offset,message:`Unexpected block-seq-ind on same line with key`,source:this.source});return}}else n&&e.items.push({start:i});this.stack.push(r);return}}}}yield*this.pop(),yield*this.step()}*blockSequence(e){let t=e.items[e.items.length-1];switch(this.type){case`newline`:if(t.value){let n=`end`in t.value?t.value.end:void 0;(Array.isArray(n)?n[n.length-1]:void 0)?.type===`comment`?n?.push(this.sourceToken):e.items.push({start:[this.sourceToken]})}else t.start.push(this.sourceToken);return;case`space`:case`comment`:if(t.value)e.items.push({start:[this.sourceToken]});else{if(this.atIndentedComment(t.start,e.indent)){let n=e.items[e.items.length-2]?.value?.end;if(Array.isArray(n)){Un(n,t.start),n.push(this.sourceToken),e.items.pop();return}}t.start.push(this.sourceToken)}return;case`anchor`:case`tag`:if(t.value||this.indent<=e.indent)break;t.start.push(this.sourceToken);return;case`seq-item-ind`:if(this.indent!==e.indent)break;t.value||Q(t.start,`seq-item-ind`)?e.items.push({start:[this.sourceToken]}):t.start.push(this.sourceToken);return}if(this.indent>e.indent){let t=this.startBlockValue(e);if(t){this.stack.push(t);return}}yield*this.pop(),yield*this.step()}*flowCollection(e){let t=e.items[e.items.length-1];if(this.type===`flow-error-end`){let e;do yield*this.pop(),e=this.peek(1);while(e?.type===`flow-collection`)}else if(e.end.length===0){switch(this.type){case`comma`:case`explicit-key-ind`:!t||t.sep?e.items.push({start:[this.sourceToken]}):t.start.push(this.sourceToken);return;case`map-value-ind`:!t||t.value?e.items.push({start:[],key:null,sep:[this.sourceToken]}):t.sep?t.sep.push(this.sourceToken):Object.assign(t,{key:null,sep:[this.sourceToken]});return;case`space`:case`comment`:case`newline`:case`anchor`:case`tag`:!t||t.value?e.items.push({start:[this.sourceToken]}):t.sep?t.sep.push(this.sourceToken):t.start.push(this.sourceToken);return;case`alias`:case`scalar`:case`single-quoted-scalar`:case`double-quoted-scalar`:{let n=this.flowScalar(this.type);!t||t.value?e.items.push({start:[],key:n,sep:[]}):t.sep?this.stack.push(n):Object.assign(t,{key:n,sep:[]});return}case`flow-map-end`:case`flow-seq-end`:e.end.push(this.sourceToken);return}let n=this.startBlockValue(e);n?this.stack.push(n):(yield*this.pop(),yield*this.step())}else{let t=this.peek(2);if(t.type===`block-map`&&(this.type===`map-value-ind`&&t.indent===e.indent||this.type===`newline`&&!t.items[t.items.length-1].sep))yield*this.pop(),yield*this.step();else if(this.type===`map-value-ind`&&t.type!==`flow-collection`){let n=$(Hn(t));Wn(e);let r=e.end.splice(1,e.end.length);r.push(this.sourceToken);let i={type:`block-map`,offset:e.offset,indent:e.indent,items:[{start:n,key:e,sep:r}]};this.onKeyLine=!0,this.stack[this.stack.length-1]=i}else yield*this.lineEnd(e)}}flowScalar(e){if(this.onNewLine){let e=this.source.indexOf(`
103
+ `,e)+1}yield*this.pop();break;default:yield*this.pop(),yield*this.step()}}*blockMap(e){let t=e.items[e.items.length-1];switch(this.type){case`newline`:if(this.onKeyLine=!1,t.value){let n=`end`in t.value?t.value.end:void 0;(Array.isArray(n)?n[n.length-1]:void 0)?.type===`comment`?n?.push(this.sourceToken):e.items.push({start:[this.sourceToken]})}else t.sep?t.sep.push(this.sourceToken):t.start.push(this.sourceToken);return;case`space`:case`comment`:if(t.value)e.items.push({start:[this.sourceToken]});else if(t.sep)t.sep.push(this.sourceToken);else{if(this.atIndentedComment(t.start,e.indent)){let n=e.items[e.items.length-2]?.value?.end;if(Array.isArray(n)){Bn(n,t.start),n.push(this.sourceToken),e.items.pop();return}}t.start.push(this.sourceToken)}return}if(this.indent>=e.indent){let n=!this.onKeyLine&&this.indent===e.indent,r=n&&(t.sep||t.explicitKey)&&this.type!==`seq-item-ind`,i=[];if(r&&t.sep&&!t.value){let n=[];for(let r=0;r<t.sep.length;++r){let i=t.sep[r];switch(i.type){case`newline`:n.push(r);break;case`space`:break;case`comment`:i.indent>e.indent&&(n.length=0);break;default:n.length=0}}n.length>=2&&(i=t.sep.splice(n[1]))}switch(this.type){case`anchor`:case`tag`:r||t.value?(i.push(this.sourceToken),e.items.push({start:i}),this.onKeyLine=!0):t.sep?t.sep.push(this.sourceToken):t.start.push(this.sourceToken);return;case`explicit-key-ind`:!t.sep&&!t.explicitKey?(t.start.push(this.sourceToken),t.explicitKey=!0):r||t.value?(i.push(this.sourceToken),e.items.push({start:i,explicitKey:!0})):this.stack.push({type:`block-map`,offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken],explicitKey:!0}]}),this.onKeyLine=!0;return;case`map-value-ind`:if(t.explicitKey){if(!t.sep){if(Q(t.start,`newline`))Object.assign(t,{key:null,sep:[this.sourceToken]});else{let e=$(t.start);this.stack.push({type:`block-map`,offset:this.offset,indent:this.indent,items:[{start:e,key:null,sep:[this.sourceToken]}]})}}else if(t.value)e.items.push({start:[],key:null,sep:[this.sourceToken]});else if(Q(t.sep,`map-value-ind`))this.stack.push({type:`block-map`,offset:this.offset,indent:this.indent,items:[{start:i,key:null,sep:[this.sourceToken]}]});else if(Rn(t.key)&&!Q(t.sep,`newline`)){let e=$(t.start),n=t.key,r=t.sep;r.push(this.sourceToken),delete t.key,delete t.sep,this.stack.push({type:`block-map`,offset:this.offset,indent:this.indent,items:[{start:e,key:n,sep:r}]})}else i.length>0?t.sep=t.sep.concat(i,this.sourceToken):t.sep.push(this.sourceToken)}else t.sep?t.value||r?e.items.push({start:i,key:null,sep:[this.sourceToken]}):Q(t.sep,`map-value-ind`)?this.stack.push({type:`block-map`,offset:this.offset,indent:this.indent,items:[{start:[],key:null,sep:[this.sourceToken]}]}):t.sep.push(this.sourceToken):Object.assign(t,{key:null,sep:[this.sourceToken]});this.onKeyLine=!0;return;case`alias`:case`scalar`:case`single-quoted-scalar`:case`double-quoted-scalar`:{let n=this.flowScalar(this.type);r||t.value?(e.items.push({start:i,key:n,sep:[]}),this.onKeyLine=!0):t.sep?this.stack.push(n):(Object.assign(t,{key:n,sep:[]}),this.onKeyLine=!0);return}default:{let r=this.startBlockValue(e);if(r){if(r.type===`block-seq`){if(!t.explicitKey&&t.sep&&!Q(t.sep,`newline`)){yield*this.pop({type:`error`,offset:this.offset,message:`Unexpected block-seq-ind on same line with key`,source:this.source});return}}else n&&e.items.push({start:i});this.stack.push(r);return}}}}yield*this.pop(),yield*this.step()}*blockSequence(e){let t=e.items[e.items.length-1];switch(this.type){case`newline`:if(t.value){let n=`end`in t.value?t.value.end:void 0;(Array.isArray(n)?n[n.length-1]:void 0)?.type===`comment`?n?.push(this.sourceToken):e.items.push({start:[this.sourceToken]})}else t.start.push(this.sourceToken);return;case`space`:case`comment`:if(t.value)e.items.push({start:[this.sourceToken]});else{if(this.atIndentedComment(t.start,e.indent)){let n=e.items[e.items.length-2]?.value?.end;if(Array.isArray(n)){Bn(n,t.start),n.push(this.sourceToken),e.items.pop();return}}t.start.push(this.sourceToken)}return;case`anchor`:case`tag`:if(t.value||this.indent<=e.indent)break;t.start.push(this.sourceToken);return;case`seq-item-ind`:if(this.indent!==e.indent)break;t.value||Q(t.start,`seq-item-ind`)?e.items.push({start:[this.sourceToken]}):t.start.push(this.sourceToken);return}if(this.indent>e.indent){let t=this.startBlockValue(e);if(t){this.stack.push(t);return}}yield*this.pop(),yield*this.step()}*flowCollection(e){let t=e.items[e.items.length-1];if(this.type===`flow-error-end`){let e;do yield*this.pop(),e=this.peek(1);while(e?.type===`flow-collection`)}else if(e.end.length===0){switch(this.type){case`comma`:case`explicit-key-ind`:!t||t.sep?e.items.push({start:[this.sourceToken]}):t.start.push(this.sourceToken);return;case`map-value-ind`:!t||t.value?e.items.push({start:[],key:null,sep:[this.sourceToken]}):t.sep?t.sep.push(this.sourceToken):Object.assign(t,{key:null,sep:[this.sourceToken]});return;case`space`:case`comment`:case`newline`:case`anchor`:case`tag`:!t||t.value?e.items.push({start:[this.sourceToken]}):t.sep?t.sep.push(this.sourceToken):t.start.push(this.sourceToken);return;case`alias`:case`scalar`:case`single-quoted-scalar`:case`double-quoted-scalar`:{let n=this.flowScalar(this.type);!t||t.value?e.items.push({start:[],key:n,sep:[]}):t.sep?this.stack.push(n):Object.assign(t,{key:n,sep:[]});return}case`flow-map-end`:case`flow-seq-end`:e.end.push(this.sourceToken);return}let n=this.startBlockValue(e);n?this.stack.push(n):(yield*this.pop(),yield*this.step())}else{let t=this.peek(2);if(t.type===`block-map`&&(this.type===`map-value-ind`&&t.indent===e.indent||this.type===`newline`&&!t.items[t.items.length-1].sep))yield*this.pop(),yield*this.step();else if(this.type===`map-value-ind`&&t.type!==`flow-collection`){let n=$(zn(t));Vn(e);let r=e.end.splice(1,e.end.length);r.push(this.sourceToken);let i={type:`block-map`,offset:e.offset,indent:e.indent,items:[{start:n,key:e,sep:r}]};this.onKeyLine=!0,this.stack[this.stack.length-1]=i}else yield*this.lineEnd(e)}}flowScalar(e){if(this.onNewLine){let e=this.source.indexOf(`
104
104
  `)+1;for(;e!==0;)this.onNewLine(this.offset+e),e=this.source.indexOf(`
105
- `,e)+1}return{type:e,offset:this.offset,indent:this.indent,source:this.source}}startBlockValue(e){switch(this.type){case`alias`:case`scalar`:case`single-quoted-scalar`:case`double-quoted-scalar`:return this.flowScalar(this.type);case`block-scalar-header`:return{type:`block-scalar`,offset:this.offset,indent:this.indent,props:[this.sourceToken],source:``};case`flow-map-start`:case`flow-seq-start`:return{type:`flow-collection`,offset:this.offset,indent:this.indent,start:this.sourceToken,items:[],end:[]};case`seq-item-ind`:return{type:`block-seq`,offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken]}]};case`explicit-key-ind`:{this.onKeyLine=!0;let t=$(Hn(e));return t.push(this.sourceToken),{type:`block-map`,offset:this.offset,indent:this.indent,items:[{start:t,explicitKey:!0}]}}case`map-value-ind`:{this.onKeyLine=!0;let t=$(Hn(e));return{type:`block-map`,offset:this.offset,indent:this.indent,items:[{start:t,key:null,sep:[this.sourceToken]}]}}}return null}atIndentedComment(e,t){return this.type!==`comment`||this.indent<=t?!1:e.every(e=>e.type===`newline`||e.type===`space`)}*documentEnd(e){this.type!==`doc-mode`&&(e.end?e.end.push(this.sourceToken):e.end=[this.sourceToken],this.type===`newline`&&(yield*this.pop()))}*lineEnd(e){switch(this.type){case`comma`:case`doc-start`:case`doc-end`:case`flow-seq-end`:case`flow-map-end`:case`map-value-ind`:yield*this.pop(),yield*this.step();break;case`newline`:this.onKeyLine=!1;default:e.end?e.end.push(this.sourceToken):e.end=[this.sourceToken],this.type===`newline`&&(yield*this.pop())}}};function Kn(e){let t=e.prettyErrors!==!1;return{lineCounter:e.lineCounter||t&&new zn||null,prettyErrors:t}}function qn(e,t={}){let{lineCounter:n,prettyErrors:r}=Kn(t),i=new Gn(n?.addNewLine),a=new Dn(t),o=null;for(let t of a.compose(i.parse(e),!0,e.length))if(!o)o=t;else if(o.options.logLevel!==`silent`){o.errors.push(new K(t.range.slice(0,2),`MULTIPLE_DOCS`,`Source contains multiple documents; please use YAML.parseAllDocuments()`));break}return r&&n&&(o.errors.forEach(qt(e,n)),o.warnings.forEach(qt(e,n))),o}function Jn(e,t,n){let r;typeof t==`function`?r=t:n===void 0&&t&&typeof t==`object`&&(n=t);let i=qn(e,n);if(!i)return null;if(i.warnings.forEach(e=>Pe(i.options.logLevel,e)),i.errors.length>0){if(i.options.logLevel!==`silent`)throw i.errors[0];i.errors=[]}return i.toJS(Object.assign({reviver:r},n))}function Yn(e,t,n){let r=null;if(typeof t==`function`||Array.isArray(t)?r=t:n===void 0&&t&&(n=t),typeof n==`string`&&(n=n.length),typeof n==`number`){let e=Math.round(n);n=e<1?void 0:e>8?{indent:8}:{indent:e}}if(e===void 0){let{keepUndefined:e}=n??t??{};if(!e)return}return d(e)&&!r?e.toString(n):new Wt(e,r,n).toString(n)}var Xn=n();e();function Zn({className:e,...n}){return(0,Xn.jsx)(`textarea`,{"data-slot":`textarea`,className:t(`flex field-sizing-content min-h-16 w-full rounded-md border border-input bg-transparent px-3 py-2 text-base shadow-xs transition-[color,box-shadow] outline-none placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 md:text-sm dark:bg-input/30 dark:aria-invalid:ring-destructive/40`,e),...n})}export{zn as a,k as c,f as d,m as f,Yn as i,S as l,Jn as n,Wt as o,h as p,qn as r,z as s,Zn as t,g as u};
105
+ `,e)+1}return{type:e,offset:this.offset,indent:this.indent,source:this.source}}startBlockValue(e){switch(this.type){case`alias`:case`scalar`:case`single-quoted-scalar`:case`double-quoted-scalar`:return this.flowScalar(this.type);case`block-scalar-header`:return{type:`block-scalar`,offset:this.offset,indent:this.indent,props:[this.sourceToken],source:``};case`flow-map-start`:case`flow-seq-start`:return{type:`flow-collection`,offset:this.offset,indent:this.indent,start:this.sourceToken,items:[],end:[]};case`seq-item-ind`:return{type:`block-seq`,offset:this.offset,indent:this.indent,items:[{start:[this.sourceToken]}]};case`explicit-key-ind`:{this.onKeyLine=!0;let t=$(zn(e));return t.push(this.sourceToken),{type:`block-map`,offset:this.offset,indent:this.indent,items:[{start:t,explicitKey:!0}]}}case`map-value-ind`:{this.onKeyLine=!0;let t=$(zn(e));return{type:`block-map`,offset:this.offset,indent:this.indent,items:[{start:t,key:null,sep:[this.sourceToken]}]}}}return null}atIndentedComment(e,t){return this.type!==`comment`||this.indent<=t?!1:e.every(e=>e.type===`newline`||e.type===`space`)}*documentEnd(e){this.type!==`doc-mode`&&(e.end?e.end.push(this.sourceToken):e.end=[this.sourceToken],this.type===`newline`&&(yield*this.pop()))}*lineEnd(e){switch(this.type){case`comma`:case`doc-start`:case`doc-end`:case`flow-seq-end`:case`flow-map-end`:case`map-value-ind`:yield*this.pop(),yield*this.step();break;case`newline`:this.onKeyLine=!1;default:e.end?e.end.push(this.sourceToken):e.end=[this.sourceToken],this.type===`newline`&&(yield*this.pop())}}};function Un(e){let t=e.prettyErrors!==!1;return{lineCounter:e.lineCounter||t&&new In||null,prettyErrors:t}}function Wn(e,t={}){let{lineCounter:n,prettyErrors:r}=Un(t),i=new Hn(n?.addNewLine),a=new wn(t),o=null;for(let t of a.compose(i.parse(e),!0,e.length))if(!o)o=t;else if(o.options.logLevel!==`silent`){o.errors.push(new K(t.range.slice(0,2),`MULTIPLE_DOCS`,`Source contains multiple documents; please use YAML.parseAllDocuments()`));break}return r&&n&&(o.errors.forEach(Wt(e,n)),o.warnings.forEach(Wt(e,n))),o}function Gn(e,t,n){let r;typeof t==`function`?r=t:n===void 0&&t&&typeof t==`object`&&(n=t);let i=Wn(e,n);if(!i)return null;if(i.warnings.forEach(e=>je(i.options.logLevel,e)),i.errors.length>0){if(i.options.logLevel!==`silent`)throw i.errors[0];i.errors=[]}return i.toJS(Object.assign({reviver:r},n))}function Kn(e,t,n){let r=null;if(typeof t==`function`||Array.isArray(t)?r=t:n===void 0&&t&&(n=t),typeof n==`string`&&(n=n.length),typeof n==`number`){let e=Math.round(n);n=e<1?void 0:e>8?{indent:8}:{indent:e}}if(e===void 0){let{keepUndefined:e}=n??t??{};if(!e)return}return c(e)&&!r?e.toString(n):new Vt(e,r,n).toString(n)}export{Vt as a,y as c,d,f,In as i,p as l,Wn as n,z as o,Kn as r,O as s,Gn as t,l as u};