@organizaone/o1-code 0.9.0 → 0.10.4

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 (354) hide show
  1. package/bundled/qc-helper/docs/configuration/settings.md +34 -7
  2. package/bundled/qc-helper/docs/features/commands.md +4 -4
  3. package/chunks/{MaxSizedBox-YRO4IP7D.js → MaxSizedBox-VHZXGVLW.js} +46 -45
  4. package/chunks/{StandaloneSessionPicker-HM6FRRNB.js → StandaloneSessionPicker-3EROWATU.js} +62 -61
  5. package/chunks/{acp-subagent-executor-GKUWPZ3X.js → acp-subagent-executor-GWQKAEPB.js} +47 -46
  6. package/chunks/{acpAgent-NM2GJZPA.js → acpAgent-AL6KTCSY.js} +94 -93
  7. package/chunks/{agent-VI6IBJKP.js → agent-RU7E6G34.js} +32 -31
  8. package/chunks/{agent-headless-RG2RANBY.js → agent-headless-M4PN25BD.js} +32 -31
  9. package/chunks/{anthropicContentGenerator-OUXKGYR3.js → anthropicContentGenerator-6TKL2GXG.js} +8 -8
  10. package/chunks/{bridge-ASDRIBGU.js → bridge-SEYIHH6G.js} +47 -46
  11. package/chunks/{build-HLEIVF4Y.js → build-QRER4J4E.js} +2 -1
  12. package/chunks/{bwrap-execution-QFG5RQSP.js → bwrap-execution-UZAMPG6F.js} +3 -3
  13. package/chunks/{chunk-KAW6TQNC.js → chunk-2VE7AXYY.js} +11 -11
  14. package/chunks/{chunk-CMZHL55Y.js → chunk-3KUQCZUE.js} +2 -2
  15. package/chunks/{chunk-LBT6PT4Z.js → chunk-3PVG3FQN.js} +7 -7
  16. package/chunks/{chunk-3T5ZVERP.js → chunk-43427ZT3.js} +1 -1
  17. package/chunks/{chunk-OBPGYMIV.js → chunk-4ESI3MQ5.js} +43 -22
  18. package/chunks/{chunk-PCCUFQHX.js → chunk-4EYPKVHD.js} +5 -5
  19. package/chunks/{chunk-ZFZB6WC5.js → chunk-4LCUE7BN.js} +3 -198
  20. package/chunks/{chunk-XJPQ7YBB.js → chunk-4XS46ASJ.js} +2 -2
  21. package/chunks/{chunk-CVAGYXMP.js → chunk-545ROI6V.js} +1 -1
  22. package/chunks/{chunk-UKUAUI76.js → chunk-5CB4U6DS.js} +2 -2
  23. package/chunks/{chunk-JVFO6PPS.js → chunk-5E373J3N.js} +1 -1
  24. package/chunks/{chunk-Q7ZF32SN.js → chunk-5Y44KHOU.js} +1 -1
  25. package/chunks/{chunk-GLKPKVRO.js → chunk-67LZSGOU.js} +1 -1
  26. package/chunks/{chunk-YBIK7JBH.js → chunk-6NXC4BI5.js} +3 -3
  27. package/chunks/{chunk-K5SPVYI4.js → chunk-7DQWDZUQ.js} +1 -1
  28. package/chunks/{chunk-LU2Z7WRX.js → chunk-7GSPYBET.js} +1 -1
  29. package/chunks/{chunk-GNUA6XPQ.js → chunk-7H3GWNGJ.js} +1 -1
  30. package/chunks/{chunk-YB735VNN.js → chunk-7JG3HELJ.js} +4 -4
  31. package/chunks/{chunk-TCME6IG6.js → chunk-7LFCBMVX.js} +1 -1
  32. package/chunks/{chunk-ZQPD7WDS.js → chunk-7M4NSLWM.js} +2 -2
  33. package/chunks/{chunk-2TURUYOS.js → chunk-7ODOX4UM.js} +2 -1
  34. package/chunks/{chunk-BMWNSOKM.js → chunk-7PYXIRCE.js} +2 -2
  35. package/chunks/{chunk-WUKHAI4J.js → chunk-7USF7X6U.js} +1 -1
  36. package/chunks/{chunk-L6HTWOTF.js → chunk-ADBL3IRA.js} +5 -5
  37. package/chunks/{chunk-CPQGFFDW.js → chunk-AGMYBSIU.js} +8 -5
  38. package/chunks/{chunk-U2A23HJU.js → chunk-AIGLVHBV.js} +3 -3
  39. package/chunks/{chunk-ZHTRFFVQ.js → chunk-ALIO4STD.js} +1 -1
  40. package/chunks/{chunk-ZXMW3YT5.js → chunk-BAGPD67C.js} +1 -1
  41. package/chunks/{chunk-RZQASTZP.js → chunk-BEI5P3M7.js} +7 -7
  42. package/chunks/{chunk-7QFVAEBE.js → chunk-BKKZR7X4.js} +2 -2
  43. package/chunks/{chunk-CS7C2L7J.js → chunk-CF5SF4G5.js} +6 -6
  44. package/chunks/{chunk-SYR2YWGQ.js → chunk-CKKPLKIP.js} +1 -1
  45. package/chunks/{chunk-ZT4BSBY4.js → chunk-CNOWGY7D.js} +6 -6
  46. package/chunks/{chunk-6CNTKWVU.js → chunk-CPWPD6SR.js} +5 -5
  47. package/chunks/{chunk-JVJT5UI7.js → chunk-CS4CELQI.js} +2 -2
  48. package/chunks/{chunk-WWRYYBOB.js → chunk-DHPOSTBT.js} +24 -5
  49. package/chunks/{chunk-PL7VG3H5.js → chunk-DVJZ2C55.js} +2 -2
  50. package/chunks/{chunk-6TWJYLJE.js → chunk-DVRWYOU6.js} +1 -1
  51. package/chunks/{chunk-FIIOIJX6.js → chunk-EHYUNTVE.js} +7 -7
  52. package/chunks/{chunk-TQI6ULGQ.js → chunk-ER3EHNTV.js} +1 -1
  53. package/chunks/{chunk-GTNYSOQ2.js → chunk-EZCJ26MU.js} +4 -4
  54. package/chunks/{chunk-Z32ZO4N2.js → chunk-FHXZKNON.js} +2 -2
  55. package/chunks/{chunk-SB7HLYND.js → chunk-FII3ST7W.js} +3 -3
  56. package/chunks/{chunk-QDZTSZTF.js → chunk-FJHDFJVI.js} +1 -1
  57. package/chunks/{chunk-R4FAETL7.js → chunk-GGUL6GZ5.js} +1 -1
  58. package/chunks/{chunk-JGEPZYTM.js → chunk-H2DCMLIK.js} +4 -4
  59. package/chunks/{chunk-CLYICZHJ.js → chunk-H75LW27M.js} +4 -4
  60. package/chunks/{chunk-QP3UCTAH.js → chunk-H7LYSOSQ.js} +1 -1
  61. package/chunks/{chunk-POHJY7RJ.js → chunk-HCE5HUQG.js} +1 -1
  62. package/chunks/{chunk-CK53F45C.js → chunk-HD3KYIZP.js} +3 -3
  63. package/chunks/{chunk-PLWOHBC7.js → chunk-HDGYCLNB.js} +1 -1
  64. package/chunks/{chunk-ZEVIKHNQ.js → chunk-HDVJIXPT.js} +3 -3
  65. package/chunks/{chunk-SRJTWTB2.js → chunk-HFXEXI4S.js} +49 -40
  66. package/chunks/{chunk-LTQLCF23.js → chunk-HOLP2BCW.js} +1 -1
  67. package/chunks/{chunk-DEULKIEJ.js → chunk-HWIVKRK4.js} +1 -1
  68. package/chunks/{chunk-YLMKYLNH.js → chunk-IK7Y64IL.js} +2 -2
  69. package/chunks/{chunk-V23Q4GBY.js → chunk-J5UW3SF4.js} +1 -1
  70. package/chunks/{chunk-DZPGLX7M.js → chunk-JQPMOOCH.js} +1 -1
  71. package/chunks/{chunk-LIM5RBA5.js → chunk-KGDJZNQC.js} +3 -3
  72. package/chunks/{chunk-656G544G.js → chunk-KMTAGPIN.js} +2 -2
  73. package/chunks/{chunk-IPTVBAQ5.js → chunk-KPRPJMSP.js} +1 -1
  74. package/chunks/{chunk-J2OKRT7N.js → chunk-L4XP2BXW.js} +13 -13
  75. package/chunks/{chunk-RCVRWBNS.js → chunk-LIAMHIGS.js} +2 -2
  76. package/chunks/{chunk-VCKGH2UF.js → chunk-ME5CDTOQ.js} +3 -3
  77. package/chunks/{chunk-NGE3GHMN.js → chunk-MWFHMYVA.js} +1 -1
  78. package/chunks/{chunk-SVMEPMAZ.js → chunk-N5MLNIET.js} +44 -44
  79. package/chunks/{chunk-XKOGHPWS.js → chunk-N7NBYHMJ.js} +1 -1
  80. package/chunks/{chunk-HFW4YMBT.js → chunk-NAKKROMI.js} +2 -2
  81. package/chunks/{chunk-3HBUBIMD.js → chunk-NDK2PD5Y.js} +1 -1
  82. package/chunks/{chunk-2R42INUX.js → chunk-NHRB3THC.js} +2 -2
  83. package/chunks/{chunk-L66MHJW7.js → chunk-NKHM3QSK.js} +5 -5
  84. package/chunks/{chunk-CWSGGQLH.js → chunk-NSH5JHZH.js} +1 -1
  85. package/chunks/{chunk-D4GF3Z3J.js → chunk-OCTSNICG.js} +2 -2
  86. package/chunks/{chunk-4FEIAOCC.js → chunk-ODYKSVON.js} +1 -1
  87. package/chunks/{chunk-NGPEFWU4.js → chunk-OJSW65PQ.js} +1 -1
  88. package/chunks/{chunk-IUHFMWMV.js → chunk-OVTUMTW6.js} +4 -4
  89. package/chunks/{chunk-LQELD265.js → chunk-P35MCCDH.js} +2 -2
  90. package/chunks/{chunk-QBCC6DDB.js → chunk-PF7G5TYG.js} +17 -17
  91. package/chunks/{chunk-QG6AA2EE.js → chunk-PYIWZPBY.js} +6 -6
  92. package/chunks/{chunk-YQP3ETMA.js → chunk-QATTWMLJ.js} +8 -8
  93. package/chunks/{chunk-FZUEC7ES.js → chunk-QCONHGJR.js} +1 -1
  94. package/chunks/{chunk-UUPZUWG5.js → chunk-QFPNGX7U.js} +1 -1
  95. package/chunks/{chunk-KM2K4ERE.js → chunk-QLP5B3HQ.js} +1 -1
  96. package/chunks/{chunk-G2I75T4C.js → chunk-QYUMJTBP.js} +2 -2
  97. package/chunks/{chunk-DVDWT5I5.js → chunk-R7SPXY4A.js} +1 -1
  98. package/chunks/{chunk-KDS2IANW.js → chunk-RCBGIDZU.js} +1 -1
  99. package/chunks/chunk-RIN7SNJN.js +212 -0
  100. package/chunks/{chunk-KAF4RHGK.js → chunk-RJUVWCC5.js} +1 -1
  101. package/chunks/{chunk-OZ2OT5BC.js → chunk-RMWEXCAN.js} +3 -3
  102. package/chunks/{chunk-SX5AXFZV.js → chunk-RUPTHAC7.js} +3 -3
  103. package/chunks/{chunk-EIPBVTYB.js → chunk-RX5J7HHZ.js} +2 -2
  104. package/chunks/{chunk-QLXCD56R.js → chunk-SKU7JRIS.js} +2 -2
  105. package/chunks/{chunk-GKCZEQC7.js → chunk-SOWXEFJH.js} +489 -240
  106. package/chunks/{chunk-7QM44EGU.js → chunk-SPLQKNEP.js} +1 -1
  107. package/chunks/{chunk-2S3QOYP4.js → chunk-SWJZH7BK.js} +6 -6
  108. package/chunks/{chunk-W3T7KUBS.js → chunk-T7M2HD7D.js} +1 -1
  109. package/chunks/{chunk-R5ILEKY4.js → chunk-TAFMMFLK.js} +3 -3
  110. package/chunks/{chunk-OU5QAYET.js → chunk-TBSUV4QV.js} +2 -2
  111. package/chunks/{chunk-3LIB2FAU.js → chunk-TI76PXY3.js} +3 -3
  112. package/chunks/{chunk-F477I5JN.js → chunk-TUTCCLI7.js} +3 -3
  113. package/chunks/{chunk-IBPY5AJI.js → chunk-U5KZBWKF.js} +4 -397
  114. package/chunks/{chunk-7UK4SIHI.js → chunk-UFXAWOXR.js} +1 -1
  115. package/chunks/{chunk-OOLEXGWB.js → chunk-UX6ZDNDO.js} +2 -2
  116. package/chunks/{chunk-XLMO7VIH.js → chunk-V7NIAOMT.js} +5 -5
  117. package/chunks/{chunk-MFSMNYXY.js → chunk-VCNQFVKJ.js} +9 -9
  118. package/chunks/{chunk-MUX4EKXE.js → chunk-VHIYZGUD.js} +2 -2
  119. package/chunks/{chunk-SQX3PXHY.js → chunk-VIAJ74X3.js} +2 -2
  120. package/chunks/{chunk-33RS64W5.js → chunk-VLALIFPR.js} +13 -13
  121. package/chunks/{chunk-N335XRGH.js → chunk-VOETOZWN.js} +1 -1
  122. package/chunks/{chunk-ELVKWFRK.js → chunk-VVF2QVSN.js} +2 -2
  123. package/chunks/{chunk-XAVVXBNC.js → chunk-VVRQLG57.js} +1 -1
  124. package/chunks/{chunk-UFUFCLDL.js → chunk-W2SFVYBK.js} +7 -7
  125. package/chunks/{chunk-AC75ZC3R.js → chunk-WCWPITU4.js} +2 -2
  126. package/chunks/{chunk-YNFJLMGL.js → chunk-WQBWL6YE.js} +10 -10
  127. package/chunks/{chunk-LQWYK66V.js → chunk-WS3L2RKL.js} +5 -5
  128. package/chunks/{chunk-FRRKENS6.js → chunk-WUP5273H.js} +3 -3
  129. package/chunks/{chunk-4IDJJ4KI.js → chunk-WWNTQFH7.js} +2 -2
  130. package/chunks/{chunk-HLWXBJCH.js → chunk-WZCKDUBO.js} +131 -15
  131. package/chunks/{chunk-Y37FNMS7.js → chunk-X427DWFD.js} +1 -1
  132. package/chunks/{chunk-35RKSP4A.js → chunk-XHYWPHWN.js} +1 -1
  133. package/chunks/{chunk-OMJU4YIQ.js → chunk-XOVXSDNN.js} +1 -1
  134. package/chunks/{chunk-W5NM2DOQ.js → chunk-XRY6XLJD.js} +16 -0
  135. package/chunks/{chunk-Q2SEZDMU.js → chunk-Y6AFQKTE.js} +3 -3
  136. package/chunks/{chunk-HQ5DN5W7.js → chunk-Y75AMWDB.js} +1 -1
  137. package/chunks/{chunk-RQ2LQ5RB.js → chunk-YHWOPL2T.js} +100 -29
  138. package/chunks/{chunk-3ODGANQH.js → chunk-YXR7EEJO.js} +2 -2
  139. package/chunks/{chunk-XCO4NKA5.js → chunk-ZDBDDHSP.js} +1 -1
  140. package/chunks/{chunk-5W2RZUTF.js → chunk-ZHMOCPV6.js} +3 -3
  141. package/chunks/{chunk-EQQUC6HX.js → chunk-ZSP6FDZ2.js} +5 -5
  142. package/chunks/{codex-subagent-executor-RHTAEFXD.js → codex-subagent-executor-UGS4BKXM.js} +47 -46
  143. package/chunks/{container-execution-environment-PO7I26HR.js → container-execution-environment-INYC74GN.js} +1 -1
  144. package/chunks/{contextCommand-CQFH75BZ.js → contextCommand-ADTFEKEK.js} +46 -45
  145. package/chunks/{core-runtime-5SGS3SVD.js → core-runtime-QIWPENIC.js} +44 -43
  146. package/chunks/{create-sub-session-G7VWSOXC.js → create-sub-session-IU3OMOYV.js} +45 -44
  147. package/chunks/{daemon-git-worktree-guard-IUFLX2O4.js → daemon-git-worktree-guard-BLBIBY4P.js} +44 -43
  148. package/chunks/{daemon-status-provider-6ZTLYNNK.js → daemon-status-provider-QQYQA54F.js} +53 -52
  149. package/chunks/{daemon-trust-policy-254OGOCS.js → daemon-trust-policy-RL42K32W.js} +50 -49
  150. package/chunks/{daemon-trust-policy-monitor-LGXXCQEP.js → daemon-trust-policy-monitor-W6A2KI3R.js} +50 -49
  151. package/chunks/{deferred-core-runtime-7OORZHNH.js → deferred-core-runtime-7IMZJYKO.js} +44 -43
  152. package/chunks/dist-ID6B4BSH.js +3901 -0
  153. package/chunks/{edit-V46XHSY7.js → edit-XEHFRLTK.js} +34 -33
  154. package/chunks/{en-VJBVNTY4.js → en-2EMGSVEU.js} +100 -0
  155. package/chunks/{enter-worktree-53CUMISV.js → enter-worktree-A2WD27HQ.js} +4 -4
  156. package/chunks/{enterPlanMode-ZPTXYQMB.js → enterPlanMode-TJNAVH6W.js} +32 -31
  157. package/chunks/{environment-4JNOLQYX.js → environment-EINU6SZC.js} +46 -45
  158. package/chunks/{errors-XFCASXKU.js → errors-2IFCUYY5.js} +46 -45
  159. package/chunks/{execution-sandbox-config-7UDTKDKF.js → execution-sandbox-config-YE2XOT56.js} +4 -4
  160. package/chunks/{execution-tool-45FRLDNU.js → execution-tool-SZ4AURPN.js} +34 -33
  161. package/chunks/{execution-worker-YUQGSB2E.js → execution-worker-WHSC3ZGX.js} +39 -38
  162. package/chunks/{exit-worktree-CZUYCPZ3.js → exit-worktree-S7KUQ4HO.js} +4 -4
  163. package/chunks/{exitPlanMode-IVJH3OXX.js → exitPlanMode-PAZMVUS6.js} +32 -31
  164. package/chunks/{fast-path-XN7NK4CH.js → fast-path-W6DEVJVB.js} +2 -2
  165. package/chunks/{glob-NHZYR52J.js → glob-WJQOKIRP.js} +33 -32
  166. package/chunks/{goal-tools-GKFYH6GK.js → goal-tools-CDMDPDOI.js} +32 -31
  167. package/chunks/{grep-ENZEP6KL.js → grep-VO76ZOXG.js} +4 -4
  168. package/chunks/{handleAutoUpdate-SLCHZHWT.js → handleAutoUpdate-JRPITHAS.js} +48 -47
  169. package/chunks/{i18n-4AFHUMG2.js → i18n-4PMXKRMM.js} +45 -44
  170. package/chunks/{image-gen-72F4XQEU.js → image-gen-GRJ73O3N.js} +6 -6
  171. package/chunks/{initializer-CDFNNZPN.js → initializer-NHTBAZUN.js} +50 -49
  172. package/chunks/{installationInfo-WUQTTZHB.js → installationInfo-OTUBAVXR.js} +44 -43
  173. package/chunks/{list-K2EIWBPE.js → list-OIRYDK5J.js} +52 -51
  174. package/chunks/{llm-TLNZYLXJ.js → llm-CWNQ7Z4U.js} +81 -80
  175. package/chunks/{llm-content-generator-OXL4S7KY.js → llm-content-generator-5662XHRK.js} +4 -4
  176. package/chunks/{loadedSettingsAdapter-AUILEI5N.js → loadedSettingsAdapter-E7AA2YEL.js} +50 -49
  177. package/chunks/{local-execution-environment-OSK4IEYP.js → local-execution-environment-HRGLGYYE.js} +39 -38
  178. package/chunks/{loggingContentGenerator-FINQP2Y4.js → loggingContentGenerator-S434PEH5.js} +33 -32
  179. package/chunks/{managed-npm-update-5DFVQ475.js → managed-npm-update-OLKKN32W.js} +44 -43
  180. package/chunks/{mcp-ZFQGAZRK.js → mcp-HHJNHR4Y.js} +50 -49
  181. package/chunks/{model-call-collection-3WVMJQ5M.js → model-call-collection-CQDJ77VA.js} +1 -1
  182. package/chunks/{model-configuration-TCLVVCJS.js → model-configuration-K26C67NU.js} +51 -50
  183. package/chunks/{modelConfigUtils-LNDNXLJV.js → modelConfigUtils-OME5BXU4.js} +46 -45
  184. package/chunks/{monitor-DVKR4R64.js → monitor-YAWMJU7P.js} +32 -31
  185. package/chunks/{nonInteractiveCli-JNH7PLWY.js → nonInteractiveCli-MPZIO64Q.js} +84 -83
  186. package/chunks/{nonInteractiveToolExecutor-L2K4LU2P.js → nonInteractiveToolExecutor-AIM44M2P.js} +33 -32
  187. package/chunks/{notebook-edit-LLJZI52V.js → notebook-edit-FTYD3OR2.js} +33 -32
  188. package/chunks/{omni-4T23JD65.js → omni-RULYOVJP.js} +14 -14
  189. package/chunks/{openaiContentGenerator-Y5AW2S3K.js → openaiContentGenerator-HYNXDAHQ.js} +11 -11
  190. package/chunks/{openaiResponsesContentGenerator-VHLQZH36.js → openaiResponsesContentGenerator-TK2Y64AP.js} +5 -5
  191. package/chunks/{processUtils-OGQTTYVO.js → processUtils-VKDQXNAC.js} +2 -2
  192. package/chunks/{prompt-terminal-ledger-M23SMYZS.js → prompt-terminal-ledger-BAOIS32T.js} +45 -44
  193. package/chunks/{proper-lockfile-YMJYGVGR.js → proper-lockfile-IRPL2CNM.js} +2 -1
  194. package/chunks/{pt-7ZZUXID3.js → pt-BM6ETOUU.js} +281 -4
  195. package/chunks/{reactive-degrade-CQ7ALF7Z.js → reactive-degrade-L6W5KNGV.js} +9 -9
  196. package/chunks/{read-file-TGXV7LRJ.js → read-file-G4G5LOGO.js} +4 -4
  197. package/chunks/{read-package-up-BNFTU7FA.js → read-package-up-MAONTKXW.js} +1 -1
  198. package/chunks/{record-source-PHBQTGL4.js → record-source-ANENC5K7.js} +3 -3
  199. package/chunks/{request-shutdown-OMWHNC3R.js → request-shutdown-LRWCJOEG.js} +2 -2
  200. package/chunks/{resumeHistoryUtils-5UTZ2RZE.js → resumeHistoryUtils-ECDR2CS2.js} +49 -48
  201. package/chunks/{ripGrep-MJXCIT62.js → ripGrep-2MEBBDSU.js} +8 -8
  202. package/chunks/{run-o1-code-serve-NFPIVOYJ.js → run-o1-code-serve-PH2GYSP2.js} +37 -36
  203. package/chunks/{runtime-shell-policy-QXWSET5W.js → runtime-shell-policy-Y3TGAQLT.js} +1 -1
  204. package/chunks/{sandboxConfig-UOAIYSNY.js → sandboxConfig-ZA5EE5YP.js} +46 -45
  205. package/chunks/{scheduled-tasks-4MX5JTOU.js → scheduled-tasks-MU2VVZZA.js} +50 -49
  206. package/chunks/{scheduler-ZZCLKFWM.js → scheduler-3GBVAF3D.js} +46 -45
  207. package/chunks/{sdk-exporters-grpc-Q2GND2QR.js → sdk-exporters-grpc-J2ILXEUS.js} +377 -127
  208. package/chunks/{sdk-exporters-http-ALEY7IPF.js → sdk-exporters-http-HGBOA62S.js} +1 -1
  209. package/chunks/{sdk-impl-CFBASVEM.js → sdk-impl-G2NWB5MF.js} +4 -4
  210. package/chunks/{send-message-NATKTKQZ.js → send-message-QOWWQKZJ.js} +2 -2
  211. package/chunks/{serve-DGO6JMBA.js → serve-2AICGZTS.js} +50 -49
  212. package/chunks/{server-N6BPWDPD.js → server-2TVKATWR.js} +92 -84
  213. package/chunks/{session-4YPHCRFC.js → session-NQKO6WQB.js} +85 -84
  214. package/chunks/{session-attachments-root-RSL2YSFZ.js → session-attachments-root-SSB5ARJJ.js} +44 -43
  215. package/chunks/{session-pr-refresh-RPM3VLUQ.js → session-pr-refresh-YMET6WC7.js} +49 -48
  216. package/chunks/{settings-GSPRMMOT.js → settings-L3QP6XRJ.js} +49 -48
  217. package/chunks/{shell-HWIE3YJY.js → shell-BUXOKE4X.js} +32 -31
  218. package/chunks/{skill-PAU4TRSD.js → skill-Y4TKTJS7.js} +8 -7
  219. package/chunks/{skill-settings-UFOTSN37.js → skill-settings-MRFNTHGU.js} +50 -49
  220. package/chunks/{spawnChannel-7IQPYOPP.js → spawnChannel-6YZABREF.js} +46 -45
  221. package/chunks/{standalone-update-U7HGJB2O.js → standalone-update-NPL3226O.js} +47 -46
  222. package/chunks/{startInteractiveUI-N7XQZNFX.js → startInteractiveUI-SK5FABV5.js} +4059 -3183
  223. package/chunks/{task-create-A3FAT34J.js → task-create-2BHPJUF3.js} +6 -5
  224. package/chunks/{task-list-FGRDSMJZ.js → task-list-6LPOL5UB.js} +3 -2
  225. package/chunks/{task-update-BE27HYCU.js → task-update-NGKKBFU5.js} +6 -5
  226. package/chunks/{team-create-4QRHJTSV.js → team-create-2M2ZEJK3.js} +32 -31
  227. package/chunks/{team-delete-6T2NMHDV.js → team-delete-WBSKRFVF.js} +3 -2
  228. package/chunks/{team-plan-approval-U6QCZ3I7.js → team-plan-approval-AHSBAARB.js} +32 -31
  229. package/chunks/{terminal-image-renderer-QRYTSBBI.js → terminal-image-renderer-6DD2LV7J.js} +44 -43
  230. package/chunks/{theme-manager-VFNWDS5X.js → theme-manager-IDMOY52V.js} +44 -43
  231. package/chunks/{tool-call-7HZFNB7J.js → tool-call-GVZHLCX6.js} +3 -3
  232. package/chunks/{tool-result-media-NLHN7JZU.js → tool-result-media-5BM7EQS2.js} +14 -14
  233. package/chunks/{tool-search-QGTV2ON5.js → tool-search-MCB74V2Z.js} +6 -6
  234. package/chunks/{total-session-admission-PUJHR6FR.js → total-session-admission-65EGYQPO.js} +47 -46
  235. package/chunks/{trustedFolders-CLVE6DRI.js → trustedFolders-B2SE4YQI.js} +45 -44
  236. package/chunks/{undici-5EUQ6VID.js → undici-I7LHD7IT.js} +457 -166
  237. package/chunks/{update-relaunch-IPSN33OR.js → update-relaunch-BI3KOPOU.js} +5 -5
  238. package/chunks/{updateCheck-REWSU2AC.js → updateCheck-KVUQB3UY.js} +47 -46
  239. package/chunks/{upload-config-W3AEV3WP.js → upload-config-EALPYJRO.js} +7 -7
  240. package/chunks/{useAutoAcceptIndicator-2JODXT2R.js → useAutoAcceptIndicator-Z2DHJUGG.js} +53 -52
  241. package/chunks/{validateNonInterActiveAuth-P5P5SI6T.js → validateNonInterActiveAuth-6TSH6F5D.js} +81 -80
  242. package/chunks/{version-KCTVVQ6T.js → version-T3ODOQJ3.js} +2 -2
  243. package/chunks/{web-fetch-3Z32TKL7.js → web-fetch-B4MFZK5W.js} +8 -8
  244. package/chunks/{web-search-T7R5BOOJ.js → web-search-R3JBN6A5.js} +11 -11
  245. package/chunks/{web-shell-static-3BG3MTI5.js → web-shell-static-OOIIII74.js} +2 -2
  246. package/chunks/{workflow-XFMT6MFA.js → workflow-WUNSCM5D.js} +33 -32
  247. package/chunks/{workspace-providers-status-E2DKABEG.js → workspace-providers-status-LSYGM3QX.js} +56 -55
  248. package/chunks/{workspace-registration-store-FWU3W65M.js → workspace-registration-store-XF5KJWQP.js} +3 -2
  249. package/chunks/{workspace-registry-EX6Q35BY.js → workspace-registry-JPCXXXJR.js} +47 -46
  250. package/chunks/{workspace-runtime-coordinator-RIA3VIAY.js → workspace-runtime-coordinator-VEVP44OL.js} +48 -47
  251. package/chunks/{workspace-service-DDCBDEWZ.js → workspace-service-VCWHIBVD.js} +55 -54
  252. package/chunks/{workspace-skills-status-B4J7CHRJ.js → workspace-skills-status-TVSCRWXV.js} +53 -52
  253. package/chunks/{workspace-trust-reconciler-HMJYGYMS.js → workspace-trust-reconciler-FP7NYY7Z.js} +53 -52
  254. package/chunks/{write-file-HVNSGPXF.js → write-file-6FNRAYPO.js} +34 -33
  255. package/chunks/{zoom-image-WLBUTVWK.js → zoom-image-UOWJTYWI.js} +4 -4
  256. package/cli.js +12 -12
  257. package/execution-worker.js +1 -1
  258. package/export-transcript-document.css +1 -1
  259. package/export-transcript-document.js +3 -3
  260. package/locales/en.js +108 -0
  261. package/locales/pt.js +378 -4
  262. package/package.json +3 -3
  263. package/release-notes.json +21 -0
  264. package/web-shell/assets/{abnfDiagram-VCTEODGH-x0S71JE3.js → abnfDiagram-VCTEODGH-hPR_hq_-.js} +1 -1
  265. package/web-shell/assets/{arc-Cz75q_IV.js → arc-DBIKDXMV.js} +1 -1
  266. package/web-shell/assets/architectureDiagram-5GKGNRK7-DF6ToCyK.js +36 -0
  267. package/web-shell/assets/{blockDiagram-NRAW4CY4-Vs4QVgsM.js → blockDiagram-NRAW4CY4-D-3ZOodq.js} +3 -3
  268. package/web-shell/assets/c4Diagram-UCG6FXSJ-Dlgo5UYL.js +38 -0
  269. package/web-shell/assets/channel-aWi28RPH.js +1 -0
  270. package/web-shell/assets/{chunk-2Q5K7J3B-6wq4aY1J.js → chunk-2Q5K7J3B-BupVKi2M.js} +1 -1
  271. package/web-shell/assets/{chunk-5VM5RSS4-Bo9m0SiQ.js → chunk-5VM5RSS4-I7UXEM7J.js} +1 -1
  272. package/web-shell/assets/chunk-F27PBJKO-HQNLQQK-.js +1 -0
  273. package/web-shell/assets/chunk-G27WJ6UU-1o4xDSX9.js +231 -0
  274. package/web-shell/assets/{chunk-JWPE2WC7-DT5_JHb_.js → chunk-JWPE2WC7-AkJIcBLE.js} +1 -1
  275. package/web-shell/assets/chunk-LCL6LL3I-nfbDS7iE.js +206 -0
  276. package/web-shell/assets/{chunk-POPQ4Y6H-CryAaWS9.js → chunk-POPQ4Y6H-DtEE_OdH.js} +1 -1
  277. package/web-shell/assets/{chunk-SVP7TREG-D0mJDzI7.js → chunk-SVP7TREG-Cj9Lw3Gx.js} +1 -1
  278. package/web-shell/assets/{chunk-XXDRQBXY-C5ffwsCM.js → chunk-XXDRQBXY-CUDuWpdQ.js} +1 -1
  279. package/web-shell/assets/classDiagram-DTDB5LWJ-fHMqSd3A.js +1 -0
  280. package/web-shell/assets/classDiagram-v2-JRS7N3AN-fHMqSd3A.js +1 -0
  281. package/web-shell/assets/cose-bilkent-JH36ORCC-DQx9CBLc.js +1 -0
  282. package/web-shell/assets/{cynefin-OW5HDTMX-BnL4xySG.js → cynefin-OW5HDTMX-B3kEpThT.js} +8 -8
  283. package/web-shell/assets/{cynefinDiagram-5FMLGOSQ-C_Vfdoz6.js → cynefinDiagram-5FMLGOSQ-Sv-FRvME.js} +1 -1
  284. package/web-shell/assets/cytoscape.esm-OyMbaexL.js +331 -0
  285. package/web-shell/assets/{dagre-3AP2YEHR-DYpnUd3X.js → dagre-3AP2YEHR-CH_Z8-Kk.js} +1 -1
  286. package/web-shell/assets/{diagram-S7CK7UJ4-Oar04chd.js → diagram-S7CK7UJ4-C0oToNP-.js} +1 -1
  287. package/web-shell/assets/{diagram-UQ7AKVKN-CdWEMvLi.js → diagram-UQ7AKVKN-BrSK_nkR.js} +1 -1
  288. package/web-shell/assets/{diagram-VSXAHHWV-Bir5CZNv.js → diagram-VSXAHHWV-Dqa3JxKx.js} +1 -1
  289. package/web-shell/assets/diagram-VX7I27RA-CMxI_svo.js +24 -0
  290. package/web-shell/assets/{diagram-Z3DM3KII-r1AOVQ0e.js → diagram-Z3DM3KII-ms16iRjT.js} +1 -1
  291. package/web-shell/assets/{ebnfDiagram-PWID7BFC-DevtH3i5.js → ebnfDiagram-PWID7BFC-DlnqAdIV.js} +1 -1
  292. package/web-shell/assets/erDiagram-SSCWMZ5O-DLsbP_rs.js +99 -0
  293. package/web-shell/assets/{flowDiagram-A5DVABFB-DgJ1KxI-.js → flowDiagram-A5DVABFB-CUi1Sjog.js} +4 -4
  294. package/web-shell/assets/ganttDiagram-EL5Y4UJY-CE_JUTUJ.js +292 -0
  295. package/web-shell/assets/{gitGraphDiagram-WWUBYQGX-vCX1mSs_.js → gitGraphDiagram-WWUBYQGX-B5AAvDsM.js} +1 -1
  296. package/web-shell/assets/index-70D1m6Hg.js +2276 -0
  297. package/web-shell/assets/{index-BEFE9XEw.js → index-BHiSoADm.js} +1 -1
  298. package/web-shell/assets/index-CL4z8Fsq.js +74 -0
  299. package/web-shell/assets/index-CNsJ4Mpd.css +36 -0
  300. package/web-shell/assets/{infoDiagram-RXCK75RN-_NepfAGI.js → infoDiagram-RXCK75RN-pBmlQkcV.js} +1 -1
  301. package/web-shell/assets/ishikawaDiagram-5VMMS53U-BauoqPoz.js +70 -0
  302. package/web-shell/assets/journeyDiagram-EYS64GPL-2bt-6t-1.js +139 -0
  303. package/web-shell/assets/{kanban-definition-3QL26DDD-BYaNwMqV.js → kanban-definition-3QL26DDD-BxxoBXaj.js} +3 -3
  304. package/web-shell/assets/layout-CHPDwyF0.js +1 -0
  305. package/web-shell/assets/{linear-BEpGEQC7.js → linear-DNvAHeqC.js} +1 -1
  306. package/web-shell/assets/mermaid.core-fypPA9cT.js +312 -0
  307. package/web-shell/assets/{mindmap-definition-FBJOCRG2-Ci7nWQV9.js → mindmap-definition-FBJOCRG2-6QjAwCGs.js} +3 -3
  308. package/web-shell/assets/{pegDiagram-XKGWAZYB-CgNvWMe-.js → pegDiagram-XKGWAZYB-CVntv99C.js} +1 -1
  309. package/web-shell/assets/{pieDiagram-E7YTZNPT-4V5XLQqW.js → pieDiagram-E7YTZNPT-BfhvtHAE.js} +1 -1
  310. package/web-shell/assets/quadrantDiagram-AXDQQJYC-MiVxa2Zt.js +7 -0
  311. package/web-shell/assets/{railroadDiagram-O6MQD6OU-BjXTf6pU.js → railroadDiagram-O6MQD6OU-BwHFJs0H.js} +1 -1
  312. package/web-shell/assets/requirementDiagram-EFPCY7ZU-CEJ6r2cM.js +84 -0
  313. package/web-shell/assets/{sankeyDiagram-P5KCCOFB-D75QSw7n.js → sankeyDiagram-P5KCCOFB-D7uTdG-j.js} +3 -3
  314. package/web-shell/assets/sequenceDiagram-WJ2MYXX4-CyW16H7w.js +162 -0
  315. package/web-shell/assets/{sizeCapture-X5ZJPWSS-fFMG4DvB.js → sizeCapture-X5ZJPWSS-zoBxvlxI.js} +1 -1
  316. package/web-shell/assets/{stateDiagram-HBIQ2CUA-B1p5bjb3.js → stateDiagram-HBIQ2CUA-BceIC-cJ.js} +1 -1
  317. package/web-shell/assets/stateDiagram-v2-4QOOHH4V-BsJAvg6i.js +1 -0
  318. package/web-shell/assets/swimlanes-XN3QIQJK-QgaLP8Xo.js +1 -0
  319. package/web-shell/assets/swimlanesDiagram-VK2B7HYN-DdMnIIJX.js +8 -0
  320. package/web-shell/assets/timeline-definition-24CTP7MA-pz8DGpLO.js +120 -0
  321. package/web-shell/assets/{vennDiagram-4TSXK5OY-CFmjd4GT.js → vennDiagram-4TSXK5OY-BoMnG3o9.js} +4 -4
  322. package/web-shell/assets/{wardleyDiagram-VM6X3IG4-DXyVTjgN.js → wardleyDiagram-VM6X3IG4-Bkr9hvxi.js} +2 -2
  323. package/web-shell/assets/xychartDiagram-S5SC5T6Z-Ca7YvQrU.js +7 -0
  324. package/web-shell/index.html +2 -2
  325. package/web-shell/sw.js +1 -1
  326. package/chunks/esm-QGHTLT3P.js +0 -5549
  327. package/web-shell/assets/architectureDiagram-5GKGNRK7-C_dL06R0.js +0 -36
  328. package/web-shell/assets/c4Diagram-UCG6FXSJ-CgRK6Jz0.js +0 -38
  329. package/web-shell/assets/channel-pE79vspw.js +0 -1
  330. package/web-shell/assets/chunk-F27PBJKO-C4L0MjFe.js +0 -1
  331. package/web-shell/assets/chunk-G27WJ6UU-BDQDTWF7.js +0 -231
  332. package/web-shell/assets/chunk-LCL6LL3I-1yVri9gU.js +0 -206
  333. package/web-shell/assets/classDiagram-DTDB5LWJ-0QITOU6l.js +0 -1
  334. package/web-shell/assets/classDiagram-v2-JRS7N3AN-0QITOU6l.js +0 -1
  335. package/web-shell/assets/cose-bilkent-JH36ORCC-DHE8Zr-F.js +0 -1
  336. package/web-shell/assets/cytoscape.esm-DJK6lGiH.js +0 -331
  337. package/web-shell/assets/diagram-VX7I27RA-Bm1O69Id.js +0 -24
  338. package/web-shell/assets/erDiagram-SSCWMZ5O-SFNjhQIj.js +0 -99
  339. package/web-shell/assets/ganttDiagram-EL5Y4UJY-oAT0EGwX.js +0 -292
  340. package/web-shell/assets/index-Cqj9WNLr.js +0 -2276
  341. package/web-shell/assets/index-DfyXIq26.css +0 -36
  342. package/web-shell/assets/index-DohPy72Z.js +0 -74
  343. package/web-shell/assets/ishikawaDiagram-5VMMS53U-Bk3wYLfy.js +0 -70
  344. package/web-shell/assets/journeyDiagram-EYS64GPL-DUUHuAKD.js +0 -139
  345. package/web-shell/assets/layout-CH_OWxT7.js +0 -1
  346. package/web-shell/assets/mermaid.core-DhaXOJnx.js +0 -312
  347. package/web-shell/assets/quadrantDiagram-AXDQQJYC-DPdypjO1.js +0 -7
  348. package/web-shell/assets/requirementDiagram-EFPCY7ZU-DJss5V5T.js +0 -84
  349. package/web-shell/assets/sequenceDiagram-WJ2MYXX4-BDhXaEt_.js +0 -162
  350. package/web-shell/assets/stateDiagram-v2-4QOOHH4V-CSbHD2Wn.js +0 -1
  351. package/web-shell/assets/swimlanes-XN3QIQJK-bPx7cEqz.js +0 -1
  352. package/web-shell/assets/swimlanesDiagram-VK2B7HYN-DTnMbaNo.js +0 -8
  353. package/web-shell/assets/timeline-definition-24CTP7MA-B3LCneiU.js +0 -120
  354. package/web-shell/assets/xychartDiagram-S5SC5T6Z-y2w_UoEl.js +0 -7
@@ -1,12 +1,12 @@
1
- var dk=Object.defineProperty;var pk=(t,e,r)=>e in t?dk(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r;var Br=(t,e,r)=>pk(t,typeof e!="symbol"?e+"":e,r);import{_ as ut}from"./index-Cqj9WNLr.js";var mk=Object.create,Du=Object.defineProperty,hk=Object.getOwnPropertyDescriptor,Th=Object.getOwnPropertyNames,yk=Object.getPrototypeOf,gk=Object.prototype.hasOwnProperty,s=(t,e)=>Du(t,"name",{value:e,configurable:!0}),vk=(t,e)=>function(){return t&&(e=(0,t[Th(t)[0]])(t=0)),e},X=(t,e)=>function(){return e||(0,t[Th(t)[0]])((e={exports:{}}).exports,e),e.exports},tn=(t,e)=>{for(var r in e)Du(t,r,{get:e[r],enumerable:!0})},$h=(t,e,r,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let a of Th(e))!gk.call(t,a)&&a!==r&&Du(t,a,{get:()=>e[a],enumerable:!(n=hk(e,a))||n.enumerable});return t},Of=(t,e,r)=>($h(t,e,"default"),r),Rh=(t,e,r)=>(r=t!=null?mk(yk(t)):{},$h(Du(r,"default",{value:t,enumerable:!0}),t)),Ah=t=>$h(Du({},"__esModule",{value:!0}),t),Lf={};tn(Lf,{AnnotatedTextEdit:()=>Ar,ChangeAnnotation:()=>mn,ChangeAnnotationIdentifier:()=>et,CodeAction:()=>Qp,CodeActionContext:()=>Zp,CodeActionKind:()=>Jp,CodeActionTriggerKind:()=>Xl,CodeDescription:()=>Ip,CodeLens:()=>em,Color:()=>Ec,ColorInformation:()=>Ep,ColorPresentation:()=>Cp,Command:()=>pn,CompletionItem:()=>Fp,CompletionItemKind:()=>Op,CompletionItemLabelDetails:()=>Gp,CompletionItemTag:()=>Dp,CompletionList:()=>zp,CreateFile:()=>_a,DeleteFile:()=>wa,Diagnostic:()=>Vl,DiagnosticRelatedInformation:()=>Cc,DiagnosticSeverity:()=>Sp,DiagnosticTag:()=>wp,DocumentHighlight:()=>Wp,DocumentHighlightKind:()=>Kp,DocumentLink:()=>rm,DocumentSymbol:()=>Xp,DocumentUri:()=>$p,EOL:()=>M$,FoldingRange:()=>_p,FoldingRangeKind:()=>bp,FormattingOptions:()=>tm,Hover:()=>jp,InlayHint:()=>fm,InlayHintKind:()=>Sc,InlayHintLabelPart:()=>wc,InlineCompletionContext:()=>gm,InlineCompletionItem:()=>pm,InlineCompletionList:()=>mm,InlineCompletionTriggerKind:()=>hm,InlineValueContext:()=>cm,InlineValueEvaluatableExpression:()=>um,InlineValueText:()=>om,InlineValueVariableLookup:()=>lm,InsertReplaceEdit:()=>xp,InsertTextFormat:()=>Lp,InsertTextMode:()=>Mp,Location:()=>Wl,LocationLink:()=>Ap,MarkedString:()=>Yl,MarkupContent:()=>Ia,MarkupKind:()=>_c,OptionalVersionedTextDocumentIdentifier:()=>Hl,ParameterInformation:()=>Bp,Position:()=>oe,Range:()=>te,RenameFile:()=>Sa,SelectedCompletionInfo:()=>ym,SelectionRange:()=>nm,SemanticTokenModifiers:()=>im,SemanticTokenTypes:()=>am,SemanticTokens:()=>sm,SignatureInformation:()=>Up,StringValue:()=>dm,SymbolInformation:()=>Hp,SymbolKind:()=>Vp,SymbolTag:()=>qp,TextDocument:()=>Tm,TextDocumentEdit:()=>ql,TextDocumentIdentifier:()=>Np,TextDocumentItem:()=>kp,TextEdit:()=>ar,URI:()=>Ac,VersionedTextDocumentIdentifier:()=>Pp,WorkspaceChange:()=>x$,WorkspaceEdit:()=>bc,WorkspaceFolder:()=>vm,WorkspaceSymbol:()=>Yp,integer:()=>Rp,uinteger:()=>Kl});var $p,Ac,Rp,Kl,oe,te,Wl,Ap,Ec,Ep,Cp,bp,_p,Cc,Sp,wp,Ip,Vl,pn,ar,mn,et,Ar,ql,_a,Sa,wa,bc,kl,Ud,x$,Np,Pp,Hl,kp,_c,Ia,Op,Lp,Dp,xp,Mp,Gp,Fp,zp,Yl,jp,Bp,Up,Kp,Wp,Vp,qp,Hp,Yp,Xp,Jp,Xl,Zp,Qp,em,tm,rm,nm,am,im,sm,om,lm,um,cm,Sc,wc,fm,dm,pm,mm,hm,ym,gm,vm,M$,Tm,iv,E,xu=vk({"../../node_modules/.pnpm/vscode-languageserver-types@3.17.5/node_modules/vscode-languageserver-types/lib/esm/main.js"(){var t,e,r,n;(function(a){function i(o){return typeof o=="string"}s(i,"is"),a.is=i})($p||($p={})),function(a){function i(o){return typeof o=="string"}s(i,"is"),a.is=i}(Ac||(Ac={})),function(a){a.MIN_VALUE=-2147483648,a.MAX_VALUE=2147483647;function i(o){return typeof o=="number"&&a.MIN_VALUE<=o&&o<=a.MAX_VALUE}s(i,"is"),a.is=i}(Rp||(Rp={})),function(a){a.MIN_VALUE=0,a.MAX_VALUE=2147483647;function i(o){return typeof o=="number"&&a.MIN_VALUE<=o&&o<=a.MAX_VALUE}s(i,"is"),a.is=i}(Kl||(Kl={})),function(a){function i(u,l){return u===Number.MAX_VALUE&&(u=Kl.MAX_VALUE),l===Number.MAX_VALUE&&(l=Kl.MAX_VALUE),{line:u,character:l}}s(i,"create"),a.create=i;function o(u){let l=u;return E.objectLiteral(l)&&E.uinteger(l.line)&&E.uinteger(l.character)}s(o,"is"),a.is=o}(oe||(oe={})),function(a){function i(u,l,c,f){if(E.uinteger(u)&&E.uinteger(l)&&E.uinteger(c)&&E.uinteger(f))return{start:oe.create(u,l),end:oe.create(c,f)};if(oe.is(u)&&oe.is(l))return{start:u,end:l};throw new Error(`Range#create called with invalid arguments[${u}, ${l}, ${c}, ${f}]`)}s(i,"create"),a.create=i;function o(u){let l=u;return E.objectLiteral(l)&&oe.is(l.start)&&oe.is(l.end)}s(o,"is"),a.is=o}(te||(te={})),function(a){function i(u,l){return{uri:u,range:l}}s(i,"create"),a.create=i;function o(u){let l=u;return E.objectLiteral(l)&&te.is(l.range)&&(E.string(l.uri)||E.undefined(l.uri))}s(o,"is"),a.is=o}(Wl||(Wl={})),function(a){function i(u,l,c,f){return{targetUri:u,targetRange:l,targetSelectionRange:c,originSelectionRange:f}}s(i,"create"),a.create=i;function o(u){let l=u;return E.objectLiteral(l)&&te.is(l.targetRange)&&E.string(l.targetUri)&&te.is(l.targetSelectionRange)&&(te.is(l.originSelectionRange)||E.undefined(l.originSelectionRange))}s(o,"is"),a.is=o}(Ap||(Ap={})),function(a){function i(u,l,c,f){return{red:u,green:l,blue:c,alpha:f}}s(i,"create"),a.create=i;function o(u){const l=u;return E.objectLiteral(l)&&E.numberRange(l.red,0,1)&&E.numberRange(l.green,0,1)&&E.numberRange(l.blue,0,1)&&E.numberRange(l.alpha,0,1)}s(o,"is"),a.is=o}(Ec||(Ec={})),function(a){function i(u,l){return{range:u,color:l}}s(i,"create"),a.create=i;function o(u){const l=u;return E.objectLiteral(l)&&te.is(l.range)&&Ec.is(l.color)}s(o,"is"),a.is=o}(Ep||(Ep={})),function(a){function i(u,l,c){return{label:u,textEdit:l,additionalTextEdits:c}}s(i,"create"),a.create=i;function o(u){const l=u;return E.objectLiteral(l)&&E.string(l.label)&&(E.undefined(l.textEdit)||ar.is(l))&&(E.undefined(l.additionalTextEdits)||E.typedArray(l.additionalTextEdits,ar.is))}s(o,"is"),a.is=o}(Cp||(Cp={})),function(a){a.Comment="comment",a.Imports="imports",a.Region="region"}(bp||(bp={})),function(a){function i(u,l,c,f,d,p){const y={startLine:u,endLine:l};return E.defined(c)&&(y.startCharacter=c),E.defined(f)&&(y.endCharacter=f),E.defined(d)&&(y.kind=d),E.defined(p)&&(y.collapsedText=p),y}s(i,"create"),a.create=i;function o(u){const l=u;return E.objectLiteral(l)&&E.uinteger(l.startLine)&&E.uinteger(l.startLine)&&(E.undefined(l.startCharacter)||E.uinteger(l.startCharacter))&&(E.undefined(l.endCharacter)||E.uinteger(l.endCharacter))&&(E.undefined(l.kind)||E.string(l.kind))}s(o,"is"),a.is=o}(_p||(_p={})),function(a){function i(u,l){return{location:u,message:l}}s(i,"create"),a.create=i;function o(u){let l=u;return E.defined(l)&&Wl.is(l.location)&&E.string(l.message)}s(o,"is"),a.is=o}(Cc||(Cc={})),function(a){a.Error=1,a.Warning=2,a.Information=3,a.Hint=4}(Sp||(Sp={})),function(a){a.Unnecessary=1,a.Deprecated=2}(wp||(wp={})),function(a){function i(o){const u=o;return E.objectLiteral(u)&&E.string(u.href)}s(i,"is"),a.is=i}(Ip||(Ip={})),function(a){function i(u,l,c,f,d,p){let y={range:u,message:l};return E.defined(c)&&(y.severity=c),E.defined(f)&&(y.code=f),E.defined(d)&&(y.source=d),E.defined(p)&&(y.relatedInformation=p),y}s(i,"create"),a.create=i;function o(u){var l;let c=u;return E.defined(c)&&te.is(c.range)&&E.string(c.message)&&(E.number(c.severity)||E.undefined(c.severity))&&(E.integer(c.code)||E.string(c.code)||E.undefined(c.code))&&(E.undefined(c.codeDescription)||E.string((l=c.codeDescription)===null||l===void 0?void 0:l.href))&&(E.string(c.source)||E.undefined(c.source))&&(E.undefined(c.relatedInformation)||E.typedArray(c.relatedInformation,Cc.is))}s(o,"is"),a.is=o}(Vl||(Vl={})),function(a){function i(u,l,...c){let f={title:u,command:l};return E.defined(c)&&c.length>0&&(f.arguments=c),f}s(i,"create"),a.create=i;function o(u){let l=u;return E.defined(l)&&E.string(l.title)&&E.string(l.command)}s(o,"is"),a.is=o}(pn||(pn={})),function(a){function i(c,f){return{range:c,newText:f}}s(i,"replace"),a.replace=i;function o(c,f){return{range:{start:c,end:c},newText:f}}s(o,"insert"),a.insert=o;function u(c){return{range:c,newText:""}}s(u,"del"),a.del=u;function l(c){const f=c;return E.objectLiteral(f)&&E.string(f.newText)&&te.is(f.range)}s(l,"is"),a.is=l}(ar||(ar={})),function(a){function i(u,l,c){const f={label:u};return l!==void 0&&(f.needsConfirmation=l),c!==void 0&&(f.description=c),f}s(i,"create"),a.create=i;function o(u){const l=u;return E.objectLiteral(l)&&E.string(l.label)&&(E.boolean(l.needsConfirmation)||l.needsConfirmation===void 0)&&(E.string(l.description)||l.description===void 0)}s(o,"is"),a.is=o}(mn||(mn={})),function(a){function i(o){const u=o;return E.string(u)}s(i,"is"),a.is=i}(et||(et={})),function(a){function i(c,f,d){return{range:c,newText:f,annotationId:d}}s(i,"replace"),a.replace=i;function o(c,f,d){return{range:{start:c,end:c},newText:f,annotationId:d}}s(o,"insert"),a.insert=o;function u(c,f){return{range:c,newText:"",annotationId:f}}s(u,"del"),a.del=u;function l(c){const f=c;return ar.is(f)&&(mn.is(f.annotationId)||et.is(f.annotationId))}s(l,"is"),a.is=l}(Ar||(Ar={})),function(a){function i(u,l){return{textDocument:u,edits:l}}s(i,"create"),a.create=i;function o(u){let l=u;return E.defined(l)&&Hl.is(l.textDocument)&&Array.isArray(l.edits)}s(o,"is"),a.is=o}(ql||(ql={})),function(a){function i(u,l,c){let f={kind:"create",uri:u};return l!==void 0&&(l.overwrite!==void 0||l.ignoreIfExists!==void 0)&&(f.options=l),c!==void 0&&(f.annotationId=c),f}s(i,"create"),a.create=i;function o(u){let l=u;return l&&l.kind==="create"&&E.string(l.uri)&&(l.options===void 0||(l.options.overwrite===void 0||E.boolean(l.options.overwrite))&&(l.options.ignoreIfExists===void 0||E.boolean(l.options.ignoreIfExists)))&&(l.annotationId===void 0||et.is(l.annotationId))}s(o,"is"),a.is=o}(_a||(_a={})),function(a){function i(u,l,c,f){let d={kind:"rename",oldUri:u,newUri:l};return c!==void 0&&(c.overwrite!==void 0||c.ignoreIfExists!==void 0)&&(d.options=c),f!==void 0&&(d.annotationId=f),d}s(i,"create"),a.create=i;function o(u){let l=u;return l&&l.kind==="rename"&&E.string(l.oldUri)&&E.string(l.newUri)&&(l.options===void 0||(l.options.overwrite===void 0||E.boolean(l.options.overwrite))&&(l.options.ignoreIfExists===void 0||E.boolean(l.options.ignoreIfExists)))&&(l.annotationId===void 0||et.is(l.annotationId))}s(o,"is"),a.is=o}(Sa||(Sa={})),function(a){function i(u,l,c){let f={kind:"delete",uri:u};return l!==void 0&&(l.recursive!==void 0||l.ignoreIfNotExists!==void 0)&&(f.options=l),c!==void 0&&(f.annotationId=c),f}s(i,"create"),a.create=i;function o(u){let l=u;return l&&l.kind==="delete"&&E.string(l.uri)&&(l.options===void 0||(l.options.recursive===void 0||E.boolean(l.options.recursive))&&(l.options.ignoreIfNotExists===void 0||E.boolean(l.options.ignoreIfNotExists)))&&(l.annotationId===void 0||et.is(l.annotationId))}s(o,"is"),a.is=o}(wa||(wa={})),function(a){function i(o){let u=o;return u&&(u.changes!==void 0||u.documentChanges!==void 0)&&(u.documentChanges===void 0||u.documentChanges.every(l=>E.string(l.kind)?_a.is(l)||Sa.is(l)||wa.is(l):ql.is(l)))}s(i,"is"),a.is=i}(bc||(bc={})),kl=(t=class{constructor(i,o){this.edits=i,this.changeAnnotations=o}insert(i,o,u){let l,c;if(u===void 0?l=ar.insert(i,o):et.is(u)?(c=u,l=Ar.insert(i,o,u)):(this.assertChangeAnnotations(this.changeAnnotations),c=this.changeAnnotations.manage(u),l=Ar.insert(i,o,c)),this.edits.push(l),c!==void 0)return c}replace(i,o,u){let l,c;if(u===void 0?l=ar.replace(i,o):et.is(u)?(c=u,l=Ar.replace(i,o,u)):(this.assertChangeAnnotations(this.changeAnnotations),c=this.changeAnnotations.manage(u),l=Ar.replace(i,o,c)),this.edits.push(l),c!==void 0)return c}delete(i,o){let u,l;if(o===void 0?u=ar.del(i):et.is(o)?(l=o,u=Ar.del(i,o)):(this.assertChangeAnnotations(this.changeAnnotations),l=this.changeAnnotations.manage(o),u=Ar.del(i,l)),this.edits.push(u),l!==void 0)return l}add(i){this.edits.push(i)}all(){return this.edits}clear(){this.edits.splice(0,this.edits.length)}assertChangeAnnotations(i){if(i===void 0)throw new Error("Text edit change is not configured to manage change annotations.")}},s(t,"TextEditChangeImpl"),t),Ud=(e=class{constructor(i){this._annotations=i===void 0?Object.create(null):i,this._counter=0,this._size=0}all(){return this._annotations}get size(){return this._size}manage(i,o){let u;if(et.is(i)?u=i:(u=this.nextId(),o=i),this._annotations[u]!==void 0)throw new Error(`Id ${u} is already in use.`);if(o===void 0)throw new Error(`No annotation provided for id ${u}`);return this._annotations[u]=o,this._size++,u}nextId(){return this._counter++,this._counter.toString()}},s(e,"ChangeAnnotations"),e),x$=(r=class{constructor(i){this._textEditChanges=Object.create(null),i!==void 0?(this._workspaceEdit=i,i.documentChanges?(this._changeAnnotations=new Ud(i.changeAnnotations),i.changeAnnotations=this._changeAnnotations.all(),i.documentChanges.forEach(o=>{if(ql.is(o)){const u=new kl(o.edits,this._changeAnnotations);this._textEditChanges[o.textDocument.uri]=u}})):i.changes&&Object.keys(i.changes).forEach(o=>{const u=new kl(i.changes[o]);this._textEditChanges[o]=u})):this._workspaceEdit={}}get edit(){return this.initDocumentChanges(),this._changeAnnotations!==void 0&&(this._changeAnnotations.size===0?this._workspaceEdit.changeAnnotations=void 0:this._workspaceEdit.changeAnnotations=this._changeAnnotations.all()),this._workspaceEdit}getTextEditChange(i){if(Hl.is(i)){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw new Error("Workspace edit is not configured for document changes.");const o={uri:i.uri,version:i.version};let u=this._textEditChanges[o.uri];if(!u){const l=[],c={textDocument:o,edits:l};this._workspaceEdit.documentChanges.push(c),u=new kl(l,this._changeAnnotations),this._textEditChanges[o.uri]=u}return u}else{if(this.initChanges(),this._workspaceEdit.changes===void 0)throw new Error("Workspace edit is not configured for normal text edit changes.");let o=this._textEditChanges[i];if(!o){let u=[];this._workspaceEdit.changes[i]=u,o=new kl(u),this._textEditChanges[i]=o}return o}}initDocumentChanges(){this._workspaceEdit.documentChanges===void 0&&this._workspaceEdit.changes===void 0&&(this._changeAnnotations=new Ud,this._workspaceEdit.documentChanges=[],this._workspaceEdit.changeAnnotations=this._changeAnnotations.all())}initChanges(){this._workspaceEdit.documentChanges===void 0&&this._workspaceEdit.changes===void 0&&(this._workspaceEdit.changes=Object.create(null))}createFile(i,o,u){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw new Error("Workspace edit is not configured for document changes.");let l;mn.is(o)||et.is(o)?l=o:u=o;let c,f;if(l===void 0?c=_a.create(i,u):(f=et.is(l)?l:this._changeAnnotations.manage(l),c=_a.create(i,u,f)),this._workspaceEdit.documentChanges.push(c),f!==void 0)return f}renameFile(i,o,u,l){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw new Error("Workspace edit is not configured for document changes.");let c;mn.is(u)||et.is(u)?c=u:l=u;let f,d;if(c===void 0?f=Sa.create(i,o,l):(d=et.is(c)?c:this._changeAnnotations.manage(c),f=Sa.create(i,o,l,d)),this._workspaceEdit.documentChanges.push(f),d!==void 0)return d}deleteFile(i,o,u){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw new Error("Workspace edit is not configured for document changes.");let l;mn.is(o)||et.is(o)?l=o:u=o;let c,f;if(l===void 0?c=wa.create(i,u):(f=et.is(l)?l:this._changeAnnotations.manage(l),c=wa.create(i,u,f)),this._workspaceEdit.documentChanges.push(c),f!==void 0)return f}},s(r,"WorkspaceChange"),r),function(a){function i(u){return{uri:u}}s(i,"create"),a.create=i;function o(u){let l=u;return E.defined(l)&&E.string(l.uri)}s(o,"is"),a.is=o}(Np||(Np={})),function(a){function i(u,l){return{uri:u,version:l}}s(i,"create"),a.create=i;function o(u){let l=u;return E.defined(l)&&E.string(l.uri)&&E.integer(l.version)}s(o,"is"),a.is=o}(Pp||(Pp={})),function(a){function i(u,l){return{uri:u,version:l}}s(i,"create"),a.create=i;function o(u){let l=u;return E.defined(l)&&E.string(l.uri)&&(l.version===null||E.integer(l.version))}s(o,"is"),a.is=o}(Hl||(Hl={})),function(a){function i(u,l,c,f){return{uri:u,languageId:l,version:c,text:f}}s(i,"create"),a.create=i;function o(u){let l=u;return E.defined(l)&&E.string(l.uri)&&E.string(l.languageId)&&E.integer(l.version)&&E.string(l.text)}s(o,"is"),a.is=o}(kp||(kp={})),function(a){a.PlainText="plaintext",a.Markdown="markdown";function i(o){const u=o;return u===a.PlainText||u===a.Markdown}s(i,"is"),a.is=i}(_c||(_c={})),function(a){function i(o){const u=o;return E.objectLiteral(o)&&_c.is(u.kind)&&E.string(u.value)}s(i,"is"),a.is=i}(Ia||(Ia={})),function(a){a.Text=1,a.Method=2,a.Function=3,a.Constructor=4,a.Field=5,a.Variable=6,a.Class=7,a.Interface=8,a.Module=9,a.Property=10,a.Unit=11,a.Value=12,a.Enum=13,a.Keyword=14,a.Snippet=15,a.Color=16,a.File=17,a.Reference=18,a.Folder=19,a.EnumMember=20,a.Constant=21,a.Struct=22,a.Event=23,a.Operator=24,a.TypeParameter=25}(Op||(Op={})),function(a){a.PlainText=1,a.Snippet=2}(Lp||(Lp={})),function(a){a.Deprecated=1}(Dp||(Dp={})),function(a){function i(u,l,c){return{newText:u,insert:l,replace:c}}s(i,"create"),a.create=i;function o(u){const l=u;return l&&E.string(l.newText)&&te.is(l.insert)&&te.is(l.replace)}s(o,"is"),a.is=o}(xp||(xp={})),function(a){a.asIs=1,a.adjustIndentation=2}(Mp||(Mp={})),function(a){function i(o){const u=o;return u&&(E.string(u.detail)||u.detail===void 0)&&(E.string(u.description)||u.description===void 0)}s(i,"is"),a.is=i}(Gp||(Gp={})),function(a){function i(o){return{label:o}}s(i,"create"),a.create=i}(Fp||(Fp={})),function(a){function i(o,u){return{items:o||[],isIncomplete:!!u}}s(i,"create"),a.create=i}(zp||(zp={})),function(a){function i(u){return u.replace(/[\\`*_{}[\]()#+\-.!]/g,"\\$&")}s(i,"fromPlainText"),a.fromPlainText=i;function o(u){const l=u;return E.string(l)||E.objectLiteral(l)&&E.string(l.language)&&E.string(l.value)}s(o,"is"),a.is=o}(Yl||(Yl={})),function(a){function i(o){let u=o;return!!u&&E.objectLiteral(u)&&(Ia.is(u.contents)||Yl.is(u.contents)||E.typedArray(u.contents,Yl.is))&&(o.range===void 0||te.is(o.range))}s(i,"is"),a.is=i}(jp||(jp={})),function(a){function i(o,u){return u?{label:o,documentation:u}:{label:o}}s(i,"create"),a.create=i}(Bp||(Bp={})),function(a){function i(o,u,...l){let c={label:o};return E.defined(u)&&(c.documentation=u),E.defined(l)?c.parameters=l:c.parameters=[],c}s(i,"create"),a.create=i}(Up||(Up={})),function(a){a.Text=1,a.Read=2,a.Write=3}(Kp||(Kp={})),function(a){function i(o,u){let l={range:o};return E.number(u)&&(l.kind=u),l}s(i,"create"),a.create=i}(Wp||(Wp={})),function(a){a.File=1,a.Module=2,a.Namespace=3,a.Package=4,a.Class=5,a.Method=6,a.Property=7,a.Field=8,a.Constructor=9,a.Enum=10,a.Interface=11,a.Function=12,a.Variable=13,a.Constant=14,a.String=15,a.Number=16,a.Boolean=17,a.Array=18,a.Object=19,a.Key=20,a.Null=21,a.EnumMember=22,a.Struct=23,a.Event=24,a.Operator=25,a.TypeParameter=26}(Vp||(Vp={})),function(a){a.Deprecated=1}(qp||(qp={})),function(a){function i(o,u,l,c,f){let d={name:o,kind:u,location:{uri:c,range:l}};return f&&(d.containerName=f),d}s(i,"create"),a.create=i}(Hp||(Hp={})),function(a){function i(o,u,l,c){return c!==void 0?{name:o,kind:u,location:{uri:l,range:c}}:{name:o,kind:u,location:{uri:l}}}s(i,"create"),a.create=i}(Yp||(Yp={})),function(a){function i(u,l,c,f,d,p){let y={name:u,detail:l,kind:c,range:f,selectionRange:d};return p!==void 0&&(y.children=p),y}s(i,"create"),a.create=i;function o(u){let l=u;return l&&E.string(l.name)&&E.number(l.kind)&&te.is(l.range)&&te.is(l.selectionRange)&&(l.detail===void 0||E.string(l.detail))&&(l.deprecated===void 0||E.boolean(l.deprecated))&&(l.children===void 0||Array.isArray(l.children))&&(l.tags===void 0||Array.isArray(l.tags))}s(o,"is"),a.is=o}(Xp||(Xp={})),function(a){a.Empty="",a.QuickFix="quickfix",a.Refactor="refactor",a.RefactorExtract="refactor.extract",a.RefactorInline="refactor.inline",a.RefactorRewrite="refactor.rewrite",a.Source="source",a.SourceOrganizeImports="source.organizeImports",a.SourceFixAll="source.fixAll"}(Jp||(Jp={})),function(a){a.Invoked=1,a.Automatic=2}(Xl||(Xl={})),function(a){function i(u,l,c){let f={diagnostics:u};return l!=null&&(f.only=l),c!=null&&(f.triggerKind=c),f}s(i,"create"),a.create=i;function o(u){let l=u;return E.defined(l)&&E.typedArray(l.diagnostics,Vl.is)&&(l.only===void 0||E.typedArray(l.only,E.string))&&(l.triggerKind===void 0||l.triggerKind===Xl.Invoked||l.triggerKind===Xl.Automatic)}s(o,"is"),a.is=o}(Zp||(Zp={})),function(a){function i(u,l,c){let f={title:u},d=!0;return typeof l=="string"?(d=!1,f.kind=l):pn.is(l)?f.command=l:f.edit=l,d&&c!==void 0&&(f.kind=c),f}s(i,"create"),a.create=i;function o(u){let l=u;return l&&E.string(l.title)&&(l.diagnostics===void 0||E.typedArray(l.diagnostics,Vl.is))&&(l.kind===void 0||E.string(l.kind))&&(l.edit!==void 0||l.command!==void 0)&&(l.command===void 0||pn.is(l.command))&&(l.isPreferred===void 0||E.boolean(l.isPreferred))&&(l.edit===void 0||bc.is(l.edit))}s(o,"is"),a.is=o}(Qp||(Qp={})),function(a){function i(u,l){let c={range:u};return E.defined(l)&&(c.data=l),c}s(i,"create"),a.create=i;function o(u){let l=u;return E.defined(l)&&te.is(l.range)&&(E.undefined(l.command)||pn.is(l.command))}s(o,"is"),a.is=o}(em||(em={})),function(a){function i(u,l){return{tabSize:u,insertSpaces:l}}s(i,"create"),a.create=i;function o(u){let l=u;return E.defined(l)&&E.uinteger(l.tabSize)&&E.boolean(l.insertSpaces)}s(o,"is"),a.is=o}(tm||(tm={})),function(a){function i(u,l,c){return{range:u,target:l,data:c}}s(i,"create"),a.create=i;function o(u){let l=u;return E.defined(l)&&te.is(l.range)&&(E.undefined(l.target)||E.string(l.target))}s(o,"is"),a.is=o}(rm||(rm={})),function(a){function i(u,l){return{range:u,parent:l}}s(i,"create"),a.create=i;function o(u){let l=u;return E.objectLiteral(l)&&te.is(l.range)&&(l.parent===void 0||a.is(l.parent))}s(o,"is"),a.is=o}(nm||(nm={})),function(a){a.namespace="namespace",a.type="type",a.class="class",a.enum="enum",a.interface="interface",a.struct="struct",a.typeParameter="typeParameter",a.parameter="parameter",a.variable="variable",a.property="property",a.enumMember="enumMember",a.event="event",a.function="function",a.method="method",a.macro="macro",a.keyword="keyword",a.modifier="modifier",a.comment="comment",a.string="string",a.number="number",a.regexp="regexp",a.operator="operator",a.decorator="decorator"}(am||(am={})),function(a){a.declaration="declaration",a.definition="definition",a.readonly="readonly",a.static="static",a.deprecated="deprecated",a.abstract="abstract",a.async="async",a.modification="modification",a.documentation="documentation",a.defaultLibrary="defaultLibrary"}(im||(im={})),function(a){function i(o){const u=o;return E.objectLiteral(u)&&(u.resultId===void 0||typeof u.resultId=="string")&&Array.isArray(u.data)&&(u.data.length===0||typeof u.data[0]=="number")}s(i,"is"),a.is=i}(sm||(sm={})),function(a){function i(u,l){return{range:u,text:l}}s(i,"create"),a.create=i;function o(u){const l=u;return l!=null&&te.is(l.range)&&E.string(l.text)}s(o,"is"),a.is=o}(om||(om={})),function(a){function i(u,l,c){return{range:u,variableName:l,caseSensitiveLookup:c}}s(i,"create"),a.create=i;function o(u){const l=u;return l!=null&&te.is(l.range)&&E.boolean(l.caseSensitiveLookup)&&(E.string(l.variableName)||l.variableName===void 0)}s(o,"is"),a.is=o}(lm||(lm={})),function(a){function i(u,l){return{range:u,expression:l}}s(i,"create"),a.create=i;function o(u){const l=u;return l!=null&&te.is(l.range)&&(E.string(l.expression)||l.expression===void 0)}s(o,"is"),a.is=o}(um||(um={})),function(a){function i(u,l){return{frameId:u,stoppedLocation:l}}s(i,"create"),a.create=i;function o(u){const l=u;return E.defined(l)&&te.is(u.stoppedLocation)}s(o,"is"),a.is=o}(cm||(cm={})),function(a){a.Type=1,a.Parameter=2;function i(o){return o===1||o===2}s(i,"is"),a.is=i}(Sc||(Sc={})),function(a){function i(u){return{value:u}}s(i,"create"),a.create=i;function o(u){const l=u;return E.objectLiteral(l)&&(l.tooltip===void 0||E.string(l.tooltip)||Ia.is(l.tooltip))&&(l.location===void 0||Wl.is(l.location))&&(l.command===void 0||pn.is(l.command))}s(o,"is"),a.is=o}(wc||(wc={})),function(a){function i(u,l,c){const f={position:u,label:l};return c!==void 0&&(f.kind=c),f}s(i,"create"),a.create=i;function o(u){const l=u;return E.objectLiteral(l)&&oe.is(l.position)&&(E.string(l.label)||E.typedArray(l.label,wc.is))&&(l.kind===void 0||Sc.is(l.kind))&&l.textEdits===void 0||E.typedArray(l.textEdits,ar.is)&&(l.tooltip===void 0||E.string(l.tooltip)||Ia.is(l.tooltip))&&(l.paddingLeft===void 0||E.boolean(l.paddingLeft))&&(l.paddingRight===void 0||E.boolean(l.paddingRight))}s(o,"is"),a.is=o}(fm||(fm={})),function(a){function i(o){return{kind:"snippet",value:o}}s(i,"createSnippet"),a.createSnippet=i}(dm||(dm={})),function(a){function i(o,u,l,c){return{insertText:o,filterText:u,range:l,command:c}}s(i,"create"),a.create=i}(pm||(pm={})),function(a){function i(o){return{items:o}}s(i,"create"),a.create=i}(mm||(mm={})),function(a){a.Invoked=0,a.Automatic=1}(hm||(hm={})),function(a){function i(o,u){return{range:o,text:u}}s(i,"create"),a.create=i}(ym||(ym={})),function(a){function i(o,u){return{triggerKind:o,selectedCompletionInfo:u}}s(i,"create"),a.create=i}(gm||(gm={})),function(a){function i(o){const u=o;return E.objectLiteral(u)&&Ac.is(u.uri)&&E.string(u.name)}s(i,"is"),a.is=i}(vm||(vm={})),M$=[`
1
+ var dk=Object.defineProperty;var pk=(t,e,r)=>e in t?dk(t,e,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[e]=r;var Br=(t,e,r)=>pk(t,typeof e!="symbol"?e+"":e,r);import{_ as ut}from"./index-70D1m6Hg.js";var mk=Object.create,Du=Object.defineProperty,hk=Object.getOwnPropertyDescriptor,Th=Object.getOwnPropertyNames,yk=Object.getPrototypeOf,gk=Object.prototype.hasOwnProperty,s=(t,e)=>Du(t,"name",{value:e,configurable:!0}),vk=(t,e)=>function(){return t&&(e=(0,t[Th(t)[0]])(t=0)),e},X=(t,e)=>function(){return e||(0,t[Th(t)[0]])((e={exports:{}}).exports,e),e.exports},tn=(t,e)=>{for(var r in e)Du(t,r,{get:e[r],enumerable:!0})},$h=(t,e,r,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let a of Th(e))!gk.call(t,a)&&a!==r&&Du(t,a,{get:()=>e[a],enumerable:!(n=hk(e,a))||n.enumerable});return t},Of=(t,e,r)=>($h(t,e,"default"),r),Rh=(t,e,r)=>(r=t!=null?mk(yk(t)):{},$h(Du(r,"default",{value:t,enumerable:!0}),t)),Ah=t=>$h(Du({},"__esModule",{value:!0}),t),Lf={};tn(Lf,{AnnotatedTextEdit:()=>Ar,ChangeAnnotation:()=>mn,ChangeAnnotationIdentifier:()=>et,CodeAction:()=>Qp,CodeActionContext:()=>Zp,CodeActionKind:()=>Jp,CodeActionTriggerKind:()=>Xl,CodeDescription:()=>Ip,CodeLens:()=>em,Color:()=>Ec,ColorInformation:()=>Ep,ColorPresentation:()=>Cp,Command:()=>pn,CompletionItem:()=>Fp,CompletionItemKind:()=>Op,CompletionItemLabelDetails:()=>Gp,CompletionItemTag:()=>Dp,CompletionList:()=>zp,CreateFile:()=>_a,DeleteFile:()=>wa,Diagnostic:()=>Vl,DiagnosticRelatedInformation:()=>Cc,DiagnosticSeverity:()=>Sp,DiagnosticTag:()=>wp,DocumentHighlight:()=>Wp,DocumentHighlightKind:()=>Kp,DocumentLink:()=>rm,DocumentSymbol:()=>Xp,DocumentUri:()=>$p,EOL:()=>M$,FoldingRange:()=>_p,FoldingRangeKind:()=>bp,FormattingOptions:()=>tm,Hover:()=>jp,InlayHint:()=>fm,InlayHintKind:()=>Sc,InlayHintLabelPart:()=>wc,InlineCompletionContext:()=>gm,InlineCompletionItem:()=>pm,InlineCompletionList:()=>mm,InlineCompletionTriggerKind:()=>hm,InlineValueContext:()=>cm,InlineValueEvaluatableExpression:()=>um,InlineValueText:()=>om,InlineValueVariableLookup:()=>lm,InsertReplaceEdit:()=>xp,InsertTextFormat:()=>Lp,InsertTextMode:()=>Mp,Location:()=>Wl,LocationLink:()=>Ap,MarkedString:()=>Yl,MarkupContent:()=>Ia,MarkupKind:()=>_c,OptionalVersionedTextDocumentIdentifier:()=>Hl,ParameterInformation:()=>Bp,Position:()=>oe,Range:()=>te,RenameFile:()=>Sa,SelectedCompletionInfo:()=>ym,SelectionRange:()=>nm,SemanticTokenModifiers:()=>im,SemanticTokenTypes:()=>am,SemanticTokens:()=>sm,SignatureInformation:()=>Up,StringValue:()=>dm,SymbolInformation:()=>Hp,SymbolKind:()=>Vp,SymbolTag:()=>qp,TextDocument:()=>Tm,TextDocumentEdit:()=>ql,TextDocumentIdentifier:()=>Np,TextDocumentItem:()=>kp,TextEdit:()=>ar,URI:()=>Ac,VersionedTextDocumentIdentifier:()=>Pp,WorkspaceChange:()=>x$,WorkspaceEdit:()=>bc,WorkspaceFolder:()=>vm,WorkspaceSymbol:()=>Yp,integer:()=>Rp,uinteger:()=>Kl});var $p,Ac,Rp,Kl,oe,te,Wl,Ap,Ec,Ep,Cp,bp,_p,Cc,Sp,wp,Ip,Vl,pn,ar,mn,et,Ar,ql,_a,Sa,wa,bc,kl,Ud,x$,Np,Pp,Hl,kp,_c,Ia,Op,Lp,Dp,xp,Mp,Gp,Fp,zp,Yl,jp,Bp,Up,Kp,Wp,Vp,qp,Hp,Yp,Xp,Jp,Xl,Zp,Qp,em,tm,rm,nm,am,im,sm,om,lm,um,cm,Sc,wc,fm,dm,pm,mm,hm,ym,gm,vm,M$,Tm,iv,E,xu=vk({"../../node_modules/.pnpm/vscode-languageserver-types@3.17.5/node_modules/vscode-languageserver-types/lib/esm/main.js"(){var t,e,r,n;(function(a){function i(o){return typeof o=="string"}s(i,"is"),a.is=i})($p||($p={})),(function(a){function i(o){return typeof o=="string"}s(i,"is"),a.is=i})(Ac||(Ac={})),(function(a){a.MIN_VALUE=-2147483648,a.MAX_VALUE=2147483647;function i(o){return typeof o=="number"&&a.MIN_VALUE<=o&&o<=a.MAX_VALUE}s(i,"is"),a.is=i})(Rp||(Rp={})),(function(a){a.MIN_VALUE=0,a.MAX_VALUE=2147483647;function i(o){return typeof o=="number"&&a.MIN_VALUE<=o&&o<=a.MAX_VALUE}s(i,"is"),a.is=i})(Kl||(Kl={})),(function(a){function i(u,l){return u===Number.MAX_VALUE&&(u=Kl.MAX_VALUE),l===Number.MAX_VALUE&&(l=Kl.MAX_VALUE),{line:u,character:l}}s(i,"create"),a.create=i;function o(u){let l=u;return E.objectLiteral(l)&&E.uinteger(l.line)&&E.uinteger(l.character)}s(o,"is"),a.is=o})(oe||(oe={})),(function(a){function i(u,l,c,f){if(E.uinteger(u)&&E.uinteger(l)&&E.uinteger(c)&&E.uinteger(f))return{start:oe.create(u,l),end:oe.create(c,f)};if(oe.is(u)&&oe.is(l))return{start:u,end:l};throw new Error(`Range#create called with invalid arguments[${u}, ${l}, ${c}, ${f}]`)}s(i,"create"),a.create=i;function o(u){let l=u;return E.objectLiteral(l)&&oe.is(l.start)&&oe.is(l.end)}s(o,"is"),a.is=o})(te||(te={})),(function(a){function i(u,l){return{uri:u,range:l}}s(i,"create"),a.create=i;function o(u){let l=u;return E.objectLiteral(l)&&te.is(l.range)&&(E.string(l.uri)||E.undefined(l.uri))}s(o,"is"),a.is=o})(Wl||(Wl={})),(function(a){function i(u,l,c,f){return{targetUri:u,targetRange:l,targetSelectionRange:c,originSelectionRange:f}}s(i,"create"),a.create=i;function o(u){let l=u;return E.objectLiteral(l)&&te.is(l.targetRange)&&E.string(l.targetUri)&&te.is(l.targetSelectionRange)&&(te.is(l.originSelectionRange)||E.undefined(l.originSelectionRange))}s(o,"is"),a.is=o})(Ap||(Ap={})),(function(a){function i(u,l,c,f){return{red:u,green:l,blue:c,alpha:f}}s(i,"create"),a.create=i;function o(u){const l=u;return E.objectLiteral(l)&&E.numberRange(l.red,0,1)&&E.numberRange(l.green,0,1)&&E.numberRange(l.blue,0,1)&&E.numberRange(l.alpha,0,1)}s(o,"is"),a.is=o})(Ec||(Ec={})),(function(a){function i(u,l){return{range:u,color:l}}s(i,"create"),a.create=i;function o(u){const l=u;return E.objectLiteral(l)&&te.is(l.range)&&Ec.is(l.color)}s(o,"is"),a.is=o})(Ep||(Ep={})),(function(a){function i(u,l,c){return{label:u,textEdit:l,additionalTextEdits:c}}s(i,"create"),a.create=i;function o(u){const l=u;return E.objectLiteral(l)&&E.string(l.label)&&(E.undefined(l.textEdit)||ar.is(l))&&(E.undefined(l.additionalTextEdits)||E.typedArray(l.additionalTextEdits,ar.is))}s(o,"is"),a.is=o})(Cp||(Cp={})),(function(a){a.Comment="comment",a.Imports="imports",a.Region="region"})(bp||(bp={})),(function(a){function i(u,l,c,f,d,p){const y={startLine:u,endLine:l};return E.defined(c)&&(y.startCharacter=c),E.defined(f)&&(y.endCharacter=f),E.defined(d)&&(y.kind=d),E.defined(p)&&(y.collapsedText=p),y}s(i,"create"),a.create=i;function o(u){const l=u;return E.objectLiteral(l)&&E.uinteger(l.startLine)&&E.uinteger(l.startLine)&&(E.undefined(l.startCharacter)||E.uinteger(l.startCharacter))&&(E.undefined(l.endCharacter)||E.uinteger(l.endCharacter))&&(E.undefined(l.kind)||E.string(l.kind))}s(o,"is"),a.is=o})(_p||(_p={})),(function(a){function i(u,l){return{location:u,message:l}}s(i,"create"),a.create=i;function o(u){let l=u;return E.defined(l)&&Wl.is(l.location)&&E.string(l.message)}s(o,"is"),a.is=o})(Cc||(Cc={})),(function(a){a.Error=1,a.Warning=2,a.Information=3,a.Hint=4})(Sp||(Sp={})),(function(a){a.Unnecessary=1,a.Deprecated=2})(wp||(wp={})),(function(a){function i(o){const u=o;return E.objectLiteral(u)&&E.string(u.href)}s(i,"is"),a.is=i})(Ip||(Ip={})),(function(a){function i(u,l,c,f,d,p){let y={range:u,message:l};return E.defined(c)&&(y.severity=c),E.defined(f)&&(y.code=f),E.defined(d)&&(y.source=d),E.defined(p)&&(y.relatedInformation=p),y}s(i,"create"),a.create=i;function o(u){var l;let c=u;return E.defined(c)&&te.is(c.range)&&E.string(c.message)&&(E.number(c.severity)||E.undefined(c.severity))&&(E.integer(c.code)||E.string(c.code)||E.undefined(c.code))&&(E.undefined(c.codeDescription)||E.string((l=c.codeDescription)===null||l===void 0?void 0:l.href))&&(E.string(c.source)||E.undefined(c.source))&&(E.undefined(c.relatedInformation)||E.typedArray(c.relatedInformation,Cc.is))}s(o,"is"),a.is=o})(Vl||(Vl={})),(function(a){function i(u,l,...c){let f={title:u,command:l};return E.defined(c)&&c.length>0&&(f.arguments=c),f}s(i,"create"),a.create=i;function o(u){let l=u;return E.defined(l)&&E.string(l.title)&&E.string(l.command)}s(o,"is"),a.is=o})(pn||(pn={})),(function(a){function i(c,f){return{range:c,newText:f}}s(i,"replace"),a.replace=i;function o(c,f){return{range:{start:c,end:c},newText:f}}s(o,"insert"),a.insert=o;function u(c){return{range:c,newText:""}}s(u,"del"),a.del=u;function l(c){const f=c;return E.objectLiteral(f)&&E.string(f.newText)&&te.is(f.range)}s(l,"is"),a.is=l})(ar||(ar={})),(function(a){function i(u,l,c){const f={label:u};return l!==void 0&&(f.needsConfirmation=l),c!==void 0&&(f.description=c),f}s(i,"create"),a.create=i;function o(u){const l=u;return E.objectLiteral(l)&&E.string(l.label)&&(E.boolean(l.needsConfirmation)||l.needsConfirmation===void 0)&&(E.string(l.description)||l.description===void 0)}s(o,"is"),a.is=o})(mn||(mn={})),(function(a){function i(o){const u=o;return E.string(u)}s(i,"is"),a.is=i})(et||(et={})),(function(a){function i(c,f,d){return{range:c,newText:f,annotationId:d}}s(i,"replace"),a.replace=i;function o(c,f,d){return{range:{start:c,end:c},newText:f,annotationId:d}}s(o,"insert"),a.insert=o;function u(c,f){return{range:c,newText:"",annotationId:f}}s(u,"del"),a.del=u;function l(c){const f=c;return ar.is(f)&&(mn.is(f.annotationId)||et.is(f.annotationId))}s(l,"is"),a.is=l})(Ar||(Ar={})),(function(a){function i(u,l){return{textDocument:u,edits:l}}s(i,"create"),a.create=i;function o(u){let l=u;return E.defined(l)&&Hl.is(l.textDocument)&&Array.isArray(l.edits)}s(o,"is"),a.is=o})(ql||(ql={})),(function(a){function i(u,l,c){let f={kind:"create",uri:u};return l!==void 0&&(l.overwrite!==void 0||l.ignoreIfExists!==void 0)&&(f.options=l),c!==void 0&&(f.annotationId=c),f}s(i,"create"),a.create=i;function o(u){let l=u;return l&&l.kind==="create"&&E.string(l.uri)&&(l.options===void 0||(l.options.overwrite===void 0||E.boolean(l.options.overwrite))&&(l.options.ignoreIfExists===void 0||E.boolean(l.options.ignoreIfExists)))&&(l.annotationId===void 0||et.is(l.annotationId))}s(o,"is"),a.is=o})(_a||(_a={})),(function(a){function i(u,l,c,f){let d={kind:"rename",oldUri:u,newUri:l};return c!==void 0&&(c.overwrite!==void 0||c.ignoreIfExists!==void 0)&&(d.options=c),f!==void 0&&(d.annotationId=f),d}s(i,"create"),a.create=i;function o(u){let l=u;return l&&l.kind==="rename"&&E.string(l.oldUri)&&E.string(l.newUri)&&(l.options===void 0||(l.options.overwrite===void 0||E.boolean(l.options.overwrite))&&(l.options.ignoreIfExists===void 0||E.boolean(l.options.ignoreIfExists)))&&(l.annotationId===void 0||et.is(l.annotationId))}s(o,"is"),a.is=o})(Sa||(Sa={})),(function(a){function i(u,l,c){let f={kind:"delete",uri:u};return l!==void 0&&(l.recursive!==void 0||l.ignoreIfNotExists!==void 0)&&(f.options=l),c!==void 0&&(f.annotationId=c),f}s(i,"create"),a.create=i;function o(u){let l=u;return l&&l.kind==="delete"&&E.string(l.uri)&&(l.options===void 0||(l.options.recursive===void 0||E.boolean(l.options.recursive))&&(l.options.ignoreIfNotExists===void 0||E.boolean(l.options.ignoreIfNotExists)))&&(l.annotationId===void 0||et.is(l.annotationId))}s(o,"is"),a.is=o})(wa||(wa={})),(function(a){function i(o){let u=o;return u&&(u.changes!==void 0||u.documentChanges!==void 0)&&(u.documentChanges===void 0||u.documentChanges.every(l=>E.string(l.kind)?_a.is(l)||Sa.is(l)||wa.is(l):ql.is(l)))}s(i,"is"),a.is=i})(bc||(bc={})),kl=(t=class{constructor(i,o){this.edits=i,this.changeAnnotations=o}insert(i,o,u){let l,c;if(u===void 0?l=ar.insert(i,o):et.is(u)?(c=u,l=Ar.insert(i,o,u)):(this.assertChangeAnnotations(this.changeAnnotations),c=this.changeAnnotations.manage(u),l=Ar.insert(i,o,c)),this.edits.push(l),c!==void 0)return c}replace(i,o,u){let l,c;if(u===void 0?l=ar.replace(i,o):et.is(u)?(c=u,l=Ar.replace(i,o,u)):(this.assertChangeAnnotations(this.changeAnnotations),c=this.changeAnnotations.manage(u),l=Ar.replace(i,o,c)),this.edits.push(l),c!==void 0)return c}delete(i,o){let u,l;if(o===void 0?u=ar.del(i):et.is(o)?(l=o,u=Ar.del(i,o)):(this.assertChangeAnnotations(this.changeAnnotations),l=this.changeAnnotations.manage(o),u=Ar.del(i,l)),this.edits.push(u),l!==void 0)return l}add(i){this.edits.push(i)}all(){return this.edits}clear(){this.edits.splice(0,this.edits.length)}assertChangeAnnotations(i){if(i===void 0)throw new Error("Text edit change is not configured to manage change annotations.")}},s(t,"TextEditChangeImpl"),t),Ud=(e=class{constructor(i){this._annotations=i===void 0?Object.create(null):i,this._counter=0,this._size=0}all(){return this._annotations}get size(){return this._size}manage(i,o){let u;if(et.is(i)?u=i:(u=this.nextId(),o=i),this._annotations[u]!==void 0)throw new Error(`Id ${u} is already in use.`);if(o===void 0)throw new Error(`No annotation provided for id ${u}`);return this._annotations[u]=o,this._size++,u}nextId(){return this._counter++,this._counter.toString()}},s(e,"ChangeAnnotations"),e),x$=(r=class{constructor(i){this._textEditChanges=Object.create(null),i!==void 0?(this._workspaceEdit=i,i.documentChanges?(this._changeAnnotations=new Ud(i.changeAnnotations),i.changeAnnotations=this._changeAnnotations.all(),i.documentChanges.forEach(o=>{if(ql.is(o)){const u=new kl(o.edits,this._changeAnnotations);this._textEditChanges[o.textDocument.uri]=u}})):i.changes&&Object.keys(i.changes).forEach(o=>{const u=new kl(i.changes[o]);this._textEditChanges[o]=u})):this._workspaceEdit={}}get edit(){return this.initDocumentChanges(),this._changeAnnotations!==void 0&&(this._changeAnnotations.size===0?this._workspaceEdit.changeAnnotations=void 0:this._workspaceEdit.changeAnnotations=this._changeAnnotations.all()),this._workspaceEdit}getTextEditChange(i){if(Hl.is(i)){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw new Error("Workspace edit is not configured for document changes.");const o={uri:i.uri,version:i.version};let u=this._textEditChanges[o.uri];if(!u){const l=[],c={textDocument:o,edits:l};this._workspaceEdit.documentChanges.push(c),u=new kl(l,this._changeAnnotations),this._textEditChanges[o.uri]=u}return u}else{if(this.initChanges(),this._workspaceEdit.changes===void 0)throw new Error("Workspace edit is not configured for normal text edit changes.");let o=this._textEditChanges[i];if(!o){let u=[];this._workspaceEdit.changes[i]=u,o=new kl(u),this._textEditChanges[i]=o}return o}}initDocumentChanges(){this._workspaceEdit.documentChanges===void 0&&this._workspaceEdit.changes===void 0&&(this._changeAnnotations=new Ud,this._workspaceEdit.documentChanges=[],this._workspaceEdit.changeAnnotations=this._changeAnnotations.all())}initChanges(){this._workspaceEdit.documentChanges===void 0&&this._workspaceEdit.changes===void 0&&(this._workspaceEdit.changes=Object.create(null))}createFile(i,o,u){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw new Error("Workspace edit is not configured for document changes.");let l;mn.is(o)||et.is(o)?l=o:u=o;let c,f;if(l===void 0?c=_a.create(i,u):(f=et.is(l)?l:this._changeAnnotations.manage(l),c=_a.create(i,u,f)),this._workspaceEdit.documentChanges.push(c),f!==void 0)return f}renameFile(i,o,u,l){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw new Error("Workspace edit is not configured for document changes.");let c;mn.is(u)||et.is(u)?c=u:l=u;let f,d;if(c===void 0?f=Sa.create(i,o,l):(d=et.is(c)?c:this._changeAnnotations.manage(c),f=Sa.create(i,o,l,d)),this._workspaceEdit.documentChanges.push(f),d!==void 0)return d}deleteFile(i,o,u){if(this.initDocumentChanges(),this._workspaceEdit.documentChanges===void 0)throw new Error("Workspace edit is not configured for document changes.");let l;mn.is(o)||et.is(o)?l=o:u=o;let c,f;if(l===void 0?c=wa.create(i,u):(f=et.is(l)?l:this._changeAnnotations.manage(l),c=wa.create(i,u,f)),this._workspaceEdit.documentChanges.push(c),f!==void 0)return f}},s(r,"WorkspaceChange"),r),(function(a){function i(u){return{uri:u}}s(i,"create"),a.create=i;function o(u){let l=u;return E.defined(l)&&E.string(l.uri)}s(o,"is"),a.is=o})(Np||(Np={})),(function(a){function i(u,l){return{uri:u,version:l}}s(i,"create"),a.create=i;function o(u){let l=u;return E.defined(l)&&E.string(l.uri)&&E.integer(l.version)}s(o,"is"),a.is=o})(Pp||(Pp={})),(function(a){function i(u,l){return{uri:u,version:l}}s(i,"create"),a.create=i;function o(u){let l=u;return E.defined(l)&&E.string(l.uri)&&(l.version===null||E.integer(l.version))}s(o,"is"),a.is=o})(Hl||(Hl={})),(function(a){function i(u,l,c,f){return{uri:u,languageId:l,version:c,text:f}}s(i,"create"),a.create=i;function o(u){let l=u;return E.defined(l)&&E.string(l.uri)&&E.string(l.languageId)&&E.integer(l.version)&&E.string(l.text)}s(o,"is"),a.is=o})(kp||(kp={})),(function(a){a.PlainText="plaintext",a.Markdown="markdown";function i(o){const u=o;return u===a.PlainText||u===a.Markdown}s(i,"is"),a.is=i})(_c||(_c={})),(function(a){function i(o){const u=o;return E.objectLiteral(o)&&_c.is(u.kind)&&E.string(u.value)}s(i,"is"),a.is=i})(Ia||(Ia={})),(function(a){a.Text=1,a.Method=2,a.Function=3,a.Constructor=4,a.Field=5,a.Variable=6,a.Class=7,a.Interface=8,a.Module=9,a.Property=10,a.Unit=11,a.Value=12,a.Enum=13,a.Keyword=14,a.Snippet=15,a.Color=16,a.File=17,a.Reference=18,a.Folder=19,a.EnumMember=20,a.Constant=21,a.Struct=22,a.Event=23,a.Operator=24,a.TypeParameter=25})(Op||(Op={})),(function(a){a.PlainText=1,a.Snippet=2})(Lp||(Lp={})),(function(a){a.Deprecated=1})(Dp||(Dp={})),(function(a){function i(u,l,c){return{newText:u,insert:l,replace:c}}s(i,"create"),a.create=i;function o(u){const l=u;return l&&E.string(l.newText)&&te.is(l.insert)&&te.is(l.replace)}s(o,"is"),a.is=o})(xp||(xp={})),(function(a){a.asIs=1,a.adjustIndentation=2})(Mp||(Mp={})),(function(a){function i(o){const u=o;return u&&(E.string(u.detail)||u.detail===void 0)&&(E.string(u.description)||u.description===void 0)}s(i,"is"),a.is=i})(Gp||(Gp={})),(function(a){function i(o){return{label:o}}s(i,"create"),a.create=i})(Fp||(Fp={})),(function(a){function i(o,u){return{items:o||[],isIncomplete:!!u}}s(i,"create"),a.create=i})(zp||(zp={})),(function(a){function i(u){return u.replace(/[\\`*_{}[\]()#+\-.!]/g,"\\$&")}s(i,"fromPlainText"),a.fromPlainText=i;function o(u){const l=u;return E.string(l)||E.objectLiteral(l)&&E.string(l.language)&&E.string(l.value)}s(o,"is"),a.is=o})(Yl||(Yl={})),(function(a){function i(o){let u=o;return!!u&&E.objectLiteral(u)&&(Ia.is(u.contents)||Yl.is(u.contents)||E.typedArray(u.contents,Yl.is))&&(o.range===void 0||te.is(o.range))}s(i,"is"),a.is=i})(jp||(jp={})),(function(a){function i(o,u){return u?{label:o,documentation:u}:{label:o}}s(i,"create"),a.create=i})(Bp||(Bp={})),(function(a){function i(o,u,...l){let c={label:o};return E.defined(u)&&(c.documentation=u),E.defined(l)?c.parameters=l:c.parameters=[],c}s(i,"create"),a.create=i})(Up||(Up={})),(function(a){a.Text=1,a.Read=2,a.Write=3})(Kp||(Kp={})),(function(a){function i(o,u){let l={range:o};return E.number(u)&&(l.kind=u),l}s(i,"create"),a.create=i})(Wp||(Wp={})),(function(a){a.File=1,a.Module=2,a.Namespace=3,a.Package=4,a.Class=5,a.Method=6,a.Property=7,a.Field=8,a.Constructor=9,a.Enum=10,a.Interface=11,a.Function=12,a.Variable=13,a.Constant=14,a.String=15,a.Number=16,a.Boolean=17,a.Array=18,a.Object=19,a.Key=20,a.Null=21,a.EnumMember=22,a.Struct=23,a.Event=24,a.Operator=25,a.TypeParameter=26})(Vp||(Vp={})),(function(a){a.Deprecated=1})(qp||(qp={})),(function(a){function i(o,u,l,c,f){let d={name:o,kind:u,location:{uri:c,range:l}};return f&&(d.containerName=f),d}s(i,"create"),a.create=i})(Hp||(Hp={})),(function(a){function i(o,u,l,c){return c!==void 0?{name:o,kind:u,location:{uri:l,range:c}}:{name:o,kind:u,location:{uri:l}}}s(i,"create"),a.create=i})(Yp||(Yp={})),(function(a){function i(u,l,c,f,d,p){let y={name:u,detail:l,kind:c,range:f,selectionRange:d};return p!==void 0&&(y.children=p),y}s(i,"create"),a.create=i;function o(u){let l=u;return l&&E.string(l.name)&&E.number(l.kind)&&te.is(l.range)&&te.is(l.selectionRange)&&(l.detail===void 0||E.string(l.detail))&&(l.deprecated===void 0||E.boolean(l.deprecated))&&(l.children===void 0||Array.isArray(l.children))&&(l.tags===void 0||Array.isArray(l.tags))}s(o,"is"),a.is=o})(Xp||(Xp={})),(function(a){a.Empty="",a.QuickFix="quickfix",a.Refactor="refactor",a.RefactorExtract="refactor.extract",a.RefactorInline="refactor.inline",a.RefactorRewrite="refactor.rewrite",a.Source="source",a.SourceOrganizeImports="source.organizeImports",a.SourceFixAll="source.fixAll"})(Jp||(Jp={})),(function(a){a.Invoked=1,a.Automatic=2})(Xl||(Xl={})),(function(a){function i(u,l,c){let f={diagnostics:u};return l!=null&&(f.only=l),c!=null&&(f.triggerKind=c),f}s(i,"create"),a.create=i;function o(u){let l=u;return E.defined(l)&&E.typedArray(l.diagnostics,Vl.is)&&(l.only===void 0||E.typedArray(l.only,E.string))&&(l.triggerKind===void 0||l.triggerKind===Xl.Invoked||l.triggerKind===Xl.Automatic)}s(o,"is"),a.is=o})(Zp||(Zp={})),(function(a){function i(u,l,c){let f={title:u},d=!0;return typeof l=="string"?(d=!1,f.kind=l):pn.is(l)?f.command=l:f.edit=l,d&&c!==void 0&&(f.kind=c),f}s(i,"create"),a.create=i;function o(u){let l=u;return l&&E.string(l.title)&&(l.diagnostics===void 0||E.typedArray(l.diagnostics,Vl.is))&&(l.kind===void 0||E.string(l.kind))&&(l.edit!==void 0||l.command!==void 0)&&(l.command===void 0||pn.is(l.command))&&(l.isPreferred===void 0||E.boolean(l.isPreferred))&&(l.edit===void 0||bc.is(l.edit))}s(o,"is"),a.is=o})(Qp||(Qp={})),(function(a){function i(u,l){let c={range:u};return E.defined(l)&&(c.data=l),c}s(i,"create"),a.create=i;function o(u){let l=u;return E.defined(l)&&te.is(l.range)&&(E.undefined(l.command)||pn.is(l.command))}s(o,"is"),a.is=o})(em||(em={})),(function(a){function i(u,l){return{tabSize:u,insertSpaces:l}}s(i,"create"),a.create=i;function o(u){let l=u;return E.defined(l)&&E.uinteger(l.tabSize)&&E.boolean(l.insertSpaces)}s(o,"is"),a.is=o})(tm||(tm={})),(function(a){function i(u,l,c){return{range:u,target:l,data:c}}s(i,"create"),a.create=i;function o(u){let l=u;return E.defined(l)&&te.is(l.range)&&(E.undefined(l.target)||E.string(l.target))}s(o,"is"),a.is=o})(rm||(rm={})),(function(a){function i(u,l){return{range:u,parent:l}}s(i,"create"),a.create=i;function o(u){let l=u;return E.objectLiteral(l)&&te.is(l.range)&&(l.parent===void 0||a.is(l.parent))}s(o,"is"),a.is=o})(nm||(nm={})),(function(a){a.namespace="namespace",a.type="type",a.class="class",a.enum="enum",a.interface="interface",a.struct="struct",a.typeParameter="typeParameter",a.parameter="parameter",a.variable="variable",a.property="property",a.enumMember="enumMember",a.event="event",a.function="function",a.method="method",a.macro="macro",a.keyword="keyword",a.modifier="modifier",a.comment="comment",a.string="string",a.number="number",a.regexp="regexp",a.operator="operator",a.decorator="decorator"})(am||(am={})),(function(a){a.declaration="declaration",a.definition="definition",a.readonly="readonly",a.static="static",a.deprecated="deprecated",a.abstract="abstract",a.async="async",a.modification="modification",a.documentation="documentation",a.defaultLibrary="defaultLibrary"})(im||(im={})),(function(a){function i(o){const u=o;return E.objectLiteral(u)&&(u.resultId===void 0||typeof u.resultId=="string")&&Array.isArray(u.data)&&(u.data.length===0||typeof u.data[0]=="number")}s(i,"is"),a.is=i})(sm||(sm={})),(function(a){function i(u,l){return{range:u,text:l}}s(i,"create"),a.create=i;function o(u){const l=u;return l!=null&&te.is(l.range)&&E.string(l.text)}s(o,"is"),a.is=o})(om||(om={})),(function(a){function i(u,l,c){return{range:u,variableName:l,caseSensitiveLookup:c}}s(i,"create"),a.create=i;function o(u){const l=u;return l!=null&&te.is(l.range)&&E.boolean(l.caseSensitiveLookup)&&(E.string(l.variableName)||l.variableName===void 0)}s(o,"is"),a.is=o})(lm||(lm={})),(function(a){function i(u,l){return{range:u,expression:l}}s(i,"create"),a.create=i;function o(u){const l=u;return l!=null&&te.is(l.range)&&(E.string(l.expression)||l.expression===void 0)}s(o,"is"),a.is=o})(um||(um={})),(function(a){function i(u,l){return{frameId:u,stoppedLocation:l}}s(i,"create"),a.create=i;function o(u){const l=u;return E.defined(l)&&te.is(u.stoppedLocation)}s(o,"is"),a.is=o})(cm||(cm={})),(function(a){a.Type=1,a.Parameter=2;function i(o){return o===1||o===2}s(i,"is"),a.is=i})(Sc||(Sc={})),(function(a){function i(u){return{value:u}}s(i,"create"),a.create=i;function o(u){const l=u;return E.objectLiteral(l)&&(l.tooltip===void 0||E.string(l.tooltip)||Ia.is(l.tooltip))&&(l.location===void 0||Wl.is(l.location))&&(l.command===void 0||pn.is(l.command))}s(o,"is"),a.is=o})(wc||(wc={})),(function(a){function i(u,l,c){const f={position:u,label:l};return c!==void 0&&(f.kind=c),f}s(i,"create"),a.create=i;function o(u){const l=u;return E.objectLiteral(l)&&oe.is(l.position)&&(E.string(l.label)||E.typedArray(l.label,wc.is))&&(l.kind===void 0||Sc.is(l.kind))&&l.textEdits===void 0||E.typedArray(l.textEdits,ar.is)&&(l.tooltip===void 0||E.string(l.tooltip)||Ia.is(l.tooltip))&&(l.paddingLeft===void 0||E.boolean(l.paddingLeft))&&(l.paddingRight===void 0||E.boolean(l.paddingRight))}s(o,"is"),a.is=o})(fm||(fm={})),(function(a){function i(o){return{kind:"snippet",value:o}}s(i,"createSnippet"),a.createSnippet=i})(dm||(dm={})),(function(a){function i(o,u,l,c){return{insertText:o,filterText:u,range:l,command:c}}s(i,"create"),a.create=i})(pm||(pm={})),(function(a){function i(o){return{items:o}}s(i,"create"),a.create=i})(mm||(mm={})),(function(a){a.Invoked=0,a.Automatic=1})(hm||(hm={})),(function(a){function i(o,u){return{range:o,text:u}}s(i,"create"),a.create=i})(ym||(ym={})),(function(a){function i(o,u){return{triggerKind:o,selectedCompletionInfo:u}}s(i,"create"),a.create=i})(gm||(gm={})),(function(a){function i(o){const u=o;return E.objectLiteral(u)&&Ac.is(u.uri)&&E.string(u.name)}s(i,"is"),a.is=i})(vm||(vm={})),M$=[`
2
2
  `,`\r
3
- `,"\r"],function(a){function i(c,f,d,p){return new iv(c,f,d,p)}s(i,"create"),a.create=i;function o(c){let f=c;return!!(E.defined(f)&&E.string(f.uri)&&(E.undefined(f.languageId)||E.string(f.languageId))&&E.uinteger(f.lineCount)&&E.func(f.getText)&&E.func(f.positionAt)&&E.func(f.offsetAt))}s(o,"is"),a.is=o;function u(c,f){let d=c.getText(),p=l(f,(h,$)=>{let C=h.range.start.line-$.range.start.line;return C===0?h.range.start.character-$.range.start.character:C}),y=d.length;for(let h=p.length-1;h>=0;h--){let $=p[h],C=c.offsetAt($.range.start),T=c.offsetAt($.range.end);if(T<=y)d=d.substring(0,C)+$.newText+d.substring(T,d.length);else throw new Error("Overlapping edit");y=C}return d}s(u,"applyEdits"),a.applyEdits=u;function l(c,f){if(c.length<=1)return c;const d=c.length/2|0,p=c.slice(0,d),y=c.slice(d);l(p,f),l(y,f);let h=0,$=0,C=0;for(;h<p.length&&$<y.length;)f(p[h],y[$])<=0?c[C++]=p[h++]:c[C++]=y[$++];for(;h<p.length;)c[C++]=p[h++];for(;$<y.length;)c[C++]=y[$++];return c}s(l,"mergeSort")}(Tm||(Tm={})),iv=(n=class{constructor(i,o,u,l){this._uri=i,this._languageId=o,this._version=u,this._content=l,this._lineOffsets=void 0}get uri(){return this._uri}get languageId(){return this._languageId}get version(){return this._version}getText(i){if(i){let o=this.offsetAt(i.start),u=this.offsetAt(i.end);return this._content.substring(o,u)}return this._content}update(i,o){this._content=i.text,this._version=o,this._lineOffsets=void 0}getLineOffsets(){if(this._lineOffsets===void 0){let i=[],o=this._content,u=!0;for(let l=0;l<o.length;l++){u&&(i.push(l),u=!1);let c=o.charAt(l);u=c==="\r"||c===`
3
+ `,"\r"],(function(a){function i(c,f,d,p){return new iv(c,f,d,p)}s(i,"create"),a.create=i;function o(c){let f=c;return!!(E.defined(f)&&E.string(f.uri)&&(E.undefined(f.languageId)||E.string(f.languageId))&&E.uinteger(f.lineCount)&&E.func(f.getText)&&E.func(f.positionAt)&&E.func(f.offsetAt))}s(o,"is"),a.is=o;function u(c,f){let d=c.getText(),p=l(f,(h,$)=>{let C=h.range.start.line-$.range.start.line;return C===0?h.range.start.character-$.range.start.character:C}),y=d.length;for(let h=p.length-1;h>=0;h--){let $=p[h],C=c.offsetAt($.range.start),T=c.offsetAt($.range.end);if(T<=y)d=d.substring(0,C)+$.newText+d.substring(T,d.length);else throw new Error("Overlapping edit");y=C}return d}s(u,"applyEdits"),a.applyEdits=u;function l(c,f){if(c.length<=1)return c;const d=c.length/2|0,p=c.slice(0,d),y=c.slice(d);l(p,f),l(y,f);let h=0,$=0,C=0;for(;h<p.length&&$<y.length;)f(p[h],y[$])<=0?c[C++]=p[h++]:c[C++]=y[$++];for(;h<p.length;)c[C++]=p[h++];for(;$<y.length;)c[C++]=y[$++];return c}s(l,"mergeSort")})(Tm||(Tm={})),iv=(n=class{constructor(i,o,u,l){this._uri=i,this._languageId=o,this._version=u,this._content=l,this._lineOffsets=void 0}get uri(){return this._uri}get languageId(){return this._languageId}get version(){return this._version}getText(i){if(i){let o=this.offsetAt(i.start),u=this.offsetAt(i.end);return this._content.substring(o,u)}return this._content}update(i,o){this._content=i.text,this._version=o,this._lineOffsets=void 0}getLineOffsets(){if(this._lineOffsets===void 0){let i=[],o=this._content,u=!0;for(let l=0;l<o.length;l++){u&&(i.push(l),u=!1);let c=o.charAt(l);u=c==="\r"||c===`
4
4
  `,c==="\r"&&l+1<o.length&&o.charAt(l+1)===`
5
- `&&l++}u&&o.length>0&&i.push(o.length),this._lineOffsets=i}return this._lineOffsets}positionAt(i){i=Math.max(Math.min(i,this._content.length),0);let o=this.getLineOffsets(),u=0,l=o.length;if(l===0)return oe.create(0,i);for(;u<l;){let f=Math.floor((u+l)/2);o[f]>i?l=f:u=f+1}let c=u-1;return oe.create(c,i-o[c])}offsetAt(i){let o=this.getLineOffsets();if(i.line>=o.length)return this._content.length;if(i.line<0)return 0;let u=o[i.line],l=i.line+1<o.length?o[i.line+1]:this._content.length;return Math.max(Math.min(u+i.character,l),u)}get lineCount(){return this.getLineOffsets().length}},s(n,"FullTextDocument"),n),function(a){const i=Object.prototype.toString;function o(T){return typeof T<"u"}s(o,"defined"),a.defined=o;function u(T){return typeof T>"u"}s(u,"undefined"),a.undefined=u;function l(T){return T===!0||T===!1}s(l,"boolean"),a.boolean=l;function c(T){return i.call(T)==="[object String]"}s(c,"string"),a.string=c;function f(T){return i.call(T)==="[object Number]"}s(f,"number"),a.number=f;function d(T,w,b){return i.call(T)==="[object Number]"&&w<=T&&T<=b}s(d,"numberRange"),a.numberRange=d;function p(T){return i.call(T)==="[object Number]"&&-2147483648<=T&&T<=2147483647}s(p,"integer"),a.integer=p;function y(T){return i.call(T)==="[object Number]"&&0<=T&&T<=2147483647}s(y,"uinteger"),a.uinteger=y;function h(T){return i.call(T)==="[object Function]"}s(h,"func"),a.func=h;function $(T){return T!==null&&typeof T=="object"}s($,"objectLiteral"),a.objectLiteral=$;function C(T,w){return Array.isArray(T)&&T.every(w)}s(C,"typedArray"),a.typedArray=C}(E||(E={}))}}),Vn=X({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/ral.js"(t){Object.defineProperty(t,"__esModule",{value:!0});var e;function r(){if(e===void 0)throw new Error("No runtime abstraction layer installed");return e}s(r,"RAL"),function(n){function a(i){if(i===void 0)throw new Error("No runtime abstraction layer provided");e=i}s(a,"install"),n.install=a}(r||(r={})),t.default=r}}),Mu=X({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/is.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.stringArray=t.array=t.func=t.error=t.number=t.string=t.boolean=void 0;function e(l){return l===!0||l===!1}s(e,"boolean"),t.boolean=e;function r(l){return typeof l=="string"||l instanceof String}s(r,"string"),t.string=r;function n(l){return typeof l=="number"||l instanceof Number}s(n,"number"),t.number=n;function a(l){return l instanceof Error}s(a,"error"),t.error=a;function i(l){return typeof l=="function"}s(i,"func"),t.func=i;function o(l){return Array.isArray(l)}s(o,"array"),t.array=o;function u(l){return o(l)&&l.every(c=>r(c))}s(u,"stringArray"),t.stringArray=u}}),al=X({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/events.js"(t){var i,o;Object.defineProperty(t,"__esModule",{value:!0}),t.Emitter=t.Event=void 0;var e=Vn(),r;(function(u){const l={dispose(){}};u.None=function(){return l}})(r||(t.Event=r={}));var n=(i=class{add(l,c=null,f){this._callbacks||(this._callbacks=[],this._contexts=[]),this._callbacks.push(l),this._contexts.push(c),Array.isArray(f)&&f.push({dispose:s(()=>this.remove(l,c),"dispose")})}remove(l,c=null){if(!this._callbacks)return;let f=!1;for(let d=0,p=this._callbacks.length;d<p;d++)if(this._callbacks[d]===l)if(this._contexts[d]===c){this._callbacks.splice(d,1),this._contexts.splice(d,1);return}else f=!0;if(f)throw new Error("When adding a listener with a context, you should remove it with the same context")}invoke(...l){if(!this._callbacks)return[];const c=[],f=this._callbacks.slice(0),d=this._contexts.slice(0);for(let p=0,y=f.length;p<y;p++)try{c.push(f[p].apply(d[p],l))}catch(h){(0,e.default)().console.error(h)}return c}isEmpty(){return!this._callbacks||this._callbacks.length===0}dispose(){this._callbacks=void 0,this._contexts=void 0}},s(i,"CallbackList"),i),a=(o=class{constructor(l){this._options=l}get event(){return this._event||(this._event=(l,c,f)=>{this._callbacks||(this._callbacks=new n),this._options&&this._options.onFirstListenerAdd&&this._callbacks.isEmpty()&&this._options.onFirstListenerAdd(this),this._callbacks.add(l,c);const d={dispose:s(()=>{this._callbacks&&(this._callbacks.remove(l,c),d.dispose=o._noop,this._options&&this._options.onLastListenerRemove&&this._callbacks.isEmpty()&&this._options.onLastListenerRemove(this))},"dispose")};return Array.isArray(f)&&f.push(d),d}),this._event}fire(l){this._callbacks&&this._callbacks.invoke.call(this._callbacks,l)}dispose(){this._callbacks&&(this._callbacks.dispose(),this._callbacks=void 0)}},s(o,"Emitter"),o);t.Emitter=a,a._noop=function(){}}}),Df=X({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/cancellation.js"(t){var l,c;Object.defineProperty(t,"__esModule",{value:!0}),t.CancellationTokenSource=t.CancellationToken=void 0;var e=Vn(),r=Mu(),n=al(),a;(function(f){f.None=Object.freeze({isCancellationRequested:!1,onCancellationRequested:n.Event.None}),f.Cancelled=Object.freeze({isCancellationRequested:!0,onCancellationRequested:n.Event.None});function d(p){const y=p;return y&&(y===f.None||y===f.Cancelled||r.boolean(y.isCancellationRequested)&&!!y.onCancellationRequested)}s(d,"is"),f.is=d})(a||(t.CancellationToken=a={}));var i=Object.freeze(function(f,d){const p=(0,e.default)().timer.setTimeout(f.bind(d),0);return{dispose(){p.dispose()}}}),o=(l=class{constructor(){this._isCancelled=!1}cancel(){this._isCancelled||(this._isCancelled=!0,this._emitter&&(this._emitter.fire(void 0),this.dispose()))}get isCancellationRequested(){return this._isCancelled}get onCancellationRequested(){return this._isCancelled?i:(this._emitter||(this._emitter=new n.Emitter),this._emitter.event)}dispose(){this._emitter&&(this._emitter.dispose(),this._emitter=void 0)}},s(l,"MutableToken"),l),u=(c=class{get token(){return this._token||(this._token=new o),this._token}cancel(){this._token?this._token.cancel():this._token=a.Cancelled}dispose(){this._token?this._token instanceof o&&this._token.dispose():this._token=a.None}},s(c,"CancellationTokenSource"),c);t.CancellationTokenSource=u}}),G$=X({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/messages.js"(t){var k,_,v,I,R,A,S,L,x,O,z,M,Y,q,Z,ae,Oe,pe,Ee,Ve,Le,ee,Qe,ce,qe;Object.defineProperty(t,"__esModule",{value:!0}),t.Message=t.NotificationType9=t.NotificationType8=t.NotificationType7=t.NotificationType6=t.NotificationType5=t.NotificationType4=t.NotificationType3=t.NotificationType2=t.NotificationType1=t.NotificationType0=t.NotificationType=t.RequestType9=t.RequestType8=t.RequestType7=t.RequestType6=t.RequestType5=t.RequestType4=t.RequestType3=t.RequestType2=t.RequestType1=t.RequestType=t.RequestType0=t.AbstractMessageSignature=t.ParameterStructures=t.ResponseError=t.ErrorCodes=void 0;var e=Mu(),r;(function(ge){ge.ParseError=-32700,ge.InvalidRequest=-32600,ge.MethodNotFound=-32601,ge.InvalidParams=-32602,ge.InternalError=-32603,ge.jsonrpcReservedErrorRangeStart=-32099,ge.serverErrorStart=-32099,ge.MessageWriteError=-32099,ge.MessageReadError=-32098,ge.PendingResponseRejected=-32097,ge.ConnectionInactive=-32096,ge.ServerNotInitialized=-32002,ge.UnknownErrorCode=-32001,ge.jsonrpcReservedErrorRangeEnd=-32e3,ge.serverErrorEnd=-32e3})(r||(t.ErrorCodes=r={}));var n=(k=class extends Error{constructor(G,je,Qt){super(je),this.code=e.number(G)?G:r.UnknownErrorCode,this.data=Qt,Object.setPrototypeOf(this,k.prototype)}toJson(){const G={code:this.code,message:this.message};return this.data!==void 0&&(G.data=this.data),G}},s(k,"ResponseError"),k);t.ResponseError=n;var a=(_=class{constructor(G){this.kind=G}static is(G){return G===_.auto||G===_.byName||G===_.byPosition}toString(){return this.kind}},s(_,"ParameterStructures"),_);t.ParameterStructures=a,a.auto=new a("auto"),a.byPosition=new a("byPosition"),a.byName=new a("byName");var i=(v=class{constructor(G,je){this.method=G,this.numberOfParams=je}get parameterStructures(){return a.auto}},s(v,"AbstractMessageSignature"),v);t.AbstractMessageSignature=i;var o=(I=class extends i{constructor(G){super(G,0)}},s(I,"RequestType0"),I);t.RequestType0=o;var u=(R=class extends i{constructor(G,je=a.auto){super(G,1),this._parameterStructures=je}get parameterStructures(){return this._parameterStructures}},s(R,"RequestType"),R);t.RequestType=u;var l=(A=class extends i{constructor(G,je=a.auto){super(G,1),this._parameterStructures=je}get parameterStructures(){return this._parameterStructures}},s(A,"RequestType1"),A);t.RequestType1=l;var c=(S=class extends i{constructor(G){super(G,2)}},s(S,"RequestType2"),S);t.RequestType2=c;var f=(L=class extends i{constructor(G){super(G,3)}},s(L,"RequestType3"),L);t.RequestType3=f;var d=(x=class extends i{constructor(G){super(G,4)}},s(x,"RequestType4"),x);t.RequestType4=d;var p=(O=class extends i{constructor(G){super(G,5)}},s(O,"RequestType5"),O);t.RequestType5=p;var y=(z=class extends i{constructor(G){super(G,6)}},s(z,"RequestType6"),z);t.RequestType6=y;var h=(M=class extends i{constructor(G){super(G,7)}},s(M,"RequestType7"),M);t.RequestType7=h;var $=(Y=class extends i{constructor(G){super(G,8)}},s(Y,"RequestType8"),Y);t.RequestType8=$;var C=(q=class extends i{constructor(G){super(G,9)}},s(q,"RequestType9"),q);t.RequestType9=C;var T=(Z=class extends i{constructor(G,je=a.auto){super(G,1),this._parameterStructures=je}get parameterStructures(){return this._parameterStructures}},s(Z,"NotificationType"),Z);t.NotificationType=T;var w=(ae=class extends i{constructor(G){super(G,0)}},s(ae,"NotificationType0"),ae);t.NotificationType0=w;var b=(Oe=class extends i{constructor(G,je=a.auto){super(G,1),this._parameterStructures=je}get parameterStructures(){return this._parameterStructures}},s(Oe,"NotificationType1"),Oe);t.NotificationType1=b;var N=(pe=class extends i{constructor(G){super(G,2)}},s(pe,"NotificationType2"),pe);t.NotificationType2=N;var B=(Ee=class extends i{constructor(G){super(G,3)}},s(Ee,"NotificationType3"),Ee);t.NotificationType3=B;var ne=(Ve=class extends i{constructor(G){super(G,4)}},s(Ve,"NotificationType4"),Ve);t.NotificationType4=ne;var J=(Le=class extends i{constructor(G){super(G,5)}},s(Le,"NotificationType5"),Le);t.NotificationType5=J;var he=(ee=class extends i{constructor(G){super(G,6)}},s(ee,"NotificationType6"),ee);t.NotificationType6=he;var Ae=(Qe=class extends i{constructor(G){super(G,7)}},s(Qe,"NotificationType7"),Qe);t.NotificationType7=Ae;var ye=(ce=class extends i{constructor(G){super(G,8)}},s(ce,"NotificationType8"),ce);t.NotificationType8=ye;var ue=(qe=class extends i{constructor(G){super(G,9)}},s(qe,"NotificationType9"),qe);t.NotificationType9=ue;var ot;(function(ge){function G(Dt){const ve=Dt;return ve&&e.string(ve.method)&&(e.string(ve.id)||e.number(ve.id))}s(G,"isRequest"),ge.isRequest=G;function je(Dt){const ve=Dt;return ve&&e.string(ve.method)&&Dt.id===void 0}s(je,"isNotification"),ge.isNotification=je;function Qt(Dt){const ve=Dt;return ve&&(ve.result!==void 0||!!ve.error)&&(e.string(ve.id)||e.number(ve.id)||ve.id===null)}s(Qt,"isResponse"),ge.isResponse=Qt})(ot||(t.Message=ot={}))}}),F$=X({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/linkedMap.js"(t){var i,o;var e;Object.defineProperty(t,"__esModule",{value:!0}),t.LRUCache=t.LinkedMap=t.Touch=void 0;var r;(function(u){u.None=0,u.First=1,u.AsOld=u.First,u.Last=2,u.AsNew=u.Last})(r||(t.Touch=r={}));var n=(i=class{constructor(){this[e]="LinkedMap",this._map=new Map,this._head=void 0,this._tail=void 0,this._size=0,this._state=0}clear(){this._map.clear(),this._head=void 0,this._tail=void 0,this._size=0,this._state++}isEmpty(){return!this._head&&!this._tail}get size(){return this._size}get first(){return this._head?.value}get last(){return this._tail?.value}has(l){return this._map.has(l)}get(l,c=r.None){const f=this._map.get(l);if(f)return c!==r.None&&this.touch(f,c),f.value}set(l,c,f=r.None){let d=this._map.get(l);if(d)d.value=c,f!==r.None&&this.touch(d,f);else{switch(d={key:l,value:c,next:void 0,previous:void 0},f){case r.None:this.addItemLast(d);break;case r.First:this.addItemFirst(d);break;case r.Last:this.addItemLast(d);break;default:this.addItemLast(d);break}this._map.set(l,d),this._size++}return this}delete(l){return!!this.remove(l)}remove(l){const c=this._map.get(l);if(c)return this._map.delete(l),this.removeItem(c),this._size--,c.value}shift(){if(!this._head&&!this._tail)return;if(!this._head||!this._tail)throw new Error("Invalid list");const l=this._head;return this._map.delete(l.key),this.removeItem(l),this._size--,l.value}forEach(l,c){const f=this._state;let d=this._head;for(;d;){if(c?l.bind(c)(d.value,d.key,this):l(d.value,d.key,this),this._state!==f)throw new Error("LinkedMap got modified during iteration.");d=d.next}}keys(){const l=this._state;let c=this._head;const f={[Symbol.iterator]:()=>f,next:s(()=>{if(this._state!==l)throw new Error("LinkedMap got modified during iteration.");if(c){const d={value:c.key,done:!1};return c=c.next,d}else return{value:void 0,done:!0}},"next")};return f}values(){const l=this._state;let c=this._head;const f={[Symbol.iterator]:()=>f,next:s(()=>{if(this._state!==l)throw new Error("LinkedMap got modified during iteration.");if(c){const d={value:c.value,done:!1};return c=c.next,d}else return{value:void 0,done:!0}},"next")};return f}entries(){const l=this._state;let c=this._head;const f={[Symbol.iterator]:()=>f,next:s(()=>{if(this._state!==l)throw new Error("LinkedMap got modified during iteration.");if(c){const d={value:[c.key,c.value],done:!1};return c=c.next,d}else return{value:void 0,done:!0}},"next")};return f}[(e=Symbol.toStringTag,Symbol.iterator)](){return this.entries()}trimOld(l){if(l>=this.size)return;if(l===0){this.clear();return}let c=this._head,f=this.size;for(;c&&f>l;)this._map.delete(c.key),c=c.next,f--;this._head=c,this._size=f,c&&(c.previous=void 0),this._state++}addItemFirst(l){if(!this._head&&!this._tail)this._tail=l;else if(this._head)l.next=this._head,this._head.previous=l;else throw new Error("Invalid list");this._head=l,this._state++}addItemLast(l){if(!this._head&&!this._tail)this._head=l;else if(this._tail)l.previous=this._tail,this._tail.next=l;else throw new Error("Invalid list");this._tail=l,this._state++}removeItem(l){if(l===this._head&&l===this._tail)this._head=void 0,this._tail=void 0;else if(l===this._head){if(!l.next)throw new Error("Invalid list");l.next.previous=void 0,this._head=l.next}else if(l===this._tail){if(!l.previous)throw new Error("Invalid list");l.previous.next=void 0,this._tail=l.previous}else{const c=l.next,f=l.previous;if(!c||!f)throw new Error("Invalid list");c.previous=f,f.next=c}l.next=void 0,l.previous=void 0,this._state++}touch(l,c){if(!this._head||!this._tail)throw new Error("Invalid list");if(!(c!==r.First&&c!==r.Last)){if(c===r.First){if(l===this._head)return;const f=l.next,d=l.previous;l===this._tail?(d.next=void 0,this._tail=d):(f.previous=d,d.next=f),l.previous=void 0,l.next=this._head,this._head.previous=l,this._head=l,this._state++}else if(c===r.Last){if(l===this._tail)return;const f=l.next,d=l.previous;l===this._head?(f.previous=void 0,this._head=f):(f.previous=d,d.next=f),l.next=void 0,l.previous=this._tail,this._tail.next=l,this._tail=l,this._state++}}}toJSON(){const l=[];return this.forEach((c,f)=>{l.push([f,c])}),l}fromJSON(l){this.clear();for(const[c,f]of l)this.set(c,f)}},s(i,"LinkedMap"),i);t.LinkedMap=n;var a=(o=class extends n{constructor(l,c=1){super(),this._limit=l,this._ratio=Math.min(Math.max(0,c),1)}get limit(){return this._limit}set limit(l){this._limit=l,this.checkTrim()}get ratio(){return this._ratio}set ratio(l){this._ratio=Math.min(Math.max(0,l),1),this.checkTrim()}get(l,c=r.AsNew){return super.get(l,c)}peek(l){return super.get(l,r.None)}set(l,c){return super.set(l,c,r.Last),this.checkTrim(),this}checkTrim(){this.size>this._limit&&this.trimOld(Math.round(this._limit*this._ratio))}},s(o,"LRUCache"),o);t.LRUCache=a}}),Tk=X({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/disposable.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.Disposable=void 0;var e;(function(r){function n(a){return{dispose:a}}s(n,"create"),r.create=n})(e||(t.Disposable=e={}))}}),$k=X({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/sharedArrayCancellation.js"(t){var u,l,c,f;Object.defineProperty(t,"__esModule",{value:!0}),t.SharedArrayReceiverStrategy=t.SharedArraySenderStrategy=void 0;var e=Df(),r;(function(d){d.Continue=0,d.Cancelled=1})(r||(r={}));var n=(u=class{constructor(){this.buffers=new Map}enableCancellation(p){if(p.id===null)return;const y=new SharedArrayBuffer(4),h=new Int32Array(y,0,1);h[0]=r.Continue,this.buffers.set(p.id,y),p.$cancellationData=y}async sendCancellation(p,y){const h=this.buffers.get(y);if(h===void 0)return;const $=new Int32Array(h,0,1);Atomics.store($,0,r.Cancelled)}cleanup(p){this.buffers.delete(p)}dispose(){this.buffers.clear()}},s(u,"SharedArraySenderStrategy"),u);t.SharedArraySenderStrategy=n;var a=(l=class{constructor(p){this.data=new Int32Array(p,0,1)}get isCancellationRequested(){return Atomics.load(this.data,0)===r.Cancelled}get onCancellationRequested(){throw new Error("Cancellation over SharedArrayBuffer doesn't support cancellation events")}},s(l,"SharedArrayBufferCancellationToken"),l),i=(c=class{constructor(p){this.token=new a(p)}cancel(){}dispose(){}},s(c,"SharedArrayBufferCancellationTokenSource"),c),o=(f=class{constructor(){this.kind="request"}createCancellationTokenSource(p){const y=p.$cancellationData;return y===void 0?new e.CancellationTokenSource:new i(y)}},s(f,"SharedArrayReceiverStrategy"),f);t.SharedArrayReceiverStrategy=o}}),z$=X({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/semaphore.js"(t){var n;Object.defineProperty(t,"__esModule",{value:!0}),t.Semaphore=void 0;var e=Vn(),r=(n=class{constructor(i=1){if(i<=0)throw new Error("Capacity must be greater than 0");this._capacity=i,this._active=0,this._waiting=[]}lock(i){return new Promise((o,u)=>{this._waiting.push({thunk:i,resolve:o,reject:u}),this.runNext()})}get active(){return this._active}runNext(){this._waiting.length===0||this._active===this._capacity||(0,e.default)().timer.setImmediate(()=>this.doRunNext())}doRunNext(){if(this._waiting.length===0||this._active===this._capacity)return;const i=this._waiting.shift();if(this._active++,this._active>this._capacity)throw new Error("To many thunks active");try{const o=i.thunk();o instanceof Promise?o.then(u=>{this._active--,i.resolve(u),this.runNext()},u=>{this._active--,i.reject(u),this.runNext()}):(this._active--,i.resolve(o),this.runNext())}catch(o){this._active--,i.reject(o),this.runNext()}}},s(n,"Semaphore"),n);t.Semaphore=r}}),Rk=X({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/messageReader.js"(t){var c,f;Object.defineProperty(t,"__esModule",{value:!0}),t.ReadableStreamMessageReader=t.AbstractMessageReader=t.MessageReader=void 0;var e=Vn(),r=Mu(),n=al(),a=z$(),i;(function(d){function p(y){let h=y;return h&&r.func(h.listen)&&r.func(h.dispose)&&r.func(h.onError)&&r.func(h.onClose)&&r.func(h.onPartialMessage)}s(p,"is"),d.is=p})(i||(t.MessageReader=i={}));var o=(c=class{constructor(){this.errorEmitter=new n.Emitter,this.closeEmitter=new n.Emitter,this.partialMessageEmitter=new n.Emitter}dispose(){this.errorEmitter.dispose(),this.closeEmitter.dispose()}get onError(){return this.errorEmitter.event}fireError(p){this.errorEmitter.fire(this.asError(p))}get onClose(){return this.closeEmitter.event}fireClose(){this.closeEmitter.fire(void 0)}get onPartialMessage(){return this.partialMessageEmitter.event}firePartialMessage(p){this.partialMessageEmitter.fire(p)}asError(p){return p instanceof Error?p:new Error(`Reader received error. Reason: ${r.string(p.message)?p.message:"unknown"}`)}},s(c,"AbstractMessageReader"),c);t.AbstractMessageReader=o;var u;(function(d){function p(y){let h,$;const C=new Map;let T;const w=new Map;if(y===void 0||typeof y=="string")h=y??"utf-8";else{if(h=y.charset??"utf-8",y.contentDecoder!==void 0&&($=y.contentDecoder,C.set($.name,$)),y.contentDecoders!==void 0)for(const b of y.contentDecoders)C.set(b.name,b);if(y.contentTypeDecoder!==void 0&&(T=y.contentTypeDecoder,w.set(T.name,T)),y.contentTypeDecoders!==void 0)for(const b of y.contentTypeDecoders)w.set(b.name,b)}return T===void 0&&(T=(0,e.default)().applicationJson.decoder,w.set(T.name,T)),{charset:h,contentDecoder:$,contentDecoders:C,contentTypeDecoder:T,contentTypeDecoders:w}}s(p,"fromOptions"),d.fromOptions=p})(u||(u={}));var l=(f=class extends o{constructor(p,y){super(),this.readable=p,this.options=u.fromOptions(y),this.buffer=(0,e.default)().messageBuffer.create(this.options.charset),this._partialMessageTimeout=1e4,this.nextMessageLength=-1,this.messageToken=0,this.readSemaphore=new a.Semaphore(1)}set partialMessageTimeout(p){this._partialMessageTimeout=p}get partialMessageTimeout(){return this._partialMessageTimeout}listen(p){this.nextMessageLength=-1,this.messageToken=0,this.partialMessageTimer=void 0,this.callback=p;const y=this.readable.onData(h=>{this.onData(h)});return this.readable.onError(h=>this.fireError(h)),this.readable.onClose(()=>this.fireClose()),y}onData(p){try{for(this.buffer.append(p);;){if(this.nextMessageLength===-1){const h=this.buffer.tryReadHeaders(!0);if(!h)return;const $=h.get("content-length");if(!$){this.fireError(new Error(`Header must provide a Content-Length property.
5
+ `&&l++}u&&o.length>0&&i.push(o.length),this._lineOffsets=i}return this._lineOffsets}positionAt(i){i=Math.max(Math.min(i,this._content.length),0);let o=this.getLineOffsets(),u=0,l=o.length;if(l===0)return oe.create(0,i);for(;u<l;){let f=Math.floor((u+l)/2);o[f]>i?l=f:u=f+1}let c=u-1;return oe.create(c,i-o[c])}offsetAt(i){let o=this.getLineOffsets();if(i.line>=o.length)return this._content.length;if(i.line<0)return 0;let u=o[i.line],l=i.line+1<o.length?o[i.line+1]:this._content.length;return Math.max(Math.min(u+i.character,l),u)}get lineCount(){return this.getLineOffsets().length}},s(n,"FullTextDocument"),n),(function(a){const i=Object.prototype.toString;function o(T){return typeof T<"u"}s(o,"defined"),a.defined=o;function u(T){return typeof T>"u"}s(u,"undefined"),a.undefined=u;function l(T){return T===!0||T===!1}s(l,"boolean"),a.boolean=l;function c(T){return i.call(T)==="[object String]"}s(c,"string"),a.string=c;function f(T){return i.call(T)==="[object Number]"}s(f,"number"),a.number=f;function d(T,w,b){return i.call(T)==="[object Number]"&&w<=T&&T<=b}s(d,"numberRange"),a.numberRange=d;function p(T){return i.call(T)==="[object Number]"&&-2147483648<=T&&T<=2147483647}s(p,"integer"),a.integer=p;function y(T){return i.call(T)==="[object Number]"&&0<=T&&T<=2147483647}s(y,"uinteger"),a.uinteger=y;function h(T){return i.call(T)==="[object Function]"}s(h,"func"),a.func=h;function $(T){return T!==null&&typeof T=="object"}s($,"objectLiteral"),a.objectLiteral=$;function C(T,w){return Array.isArray(T)&&T.every(w)}s(C,"typedArray"),a.typedArray=C})(E||(E={}))}}),Vn=X({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/ral.js"(t){Object.defineProperty(t,"__esModule",{value:!0});var e;function r(){if(e===void 0)throw new Error("No runtime abstraction layer installed");return e}s(r,"RAL"),(function(n){function a(i){if(i===void 0)throw new Error("No runtime abstraction layer provided");e=i}s(a,"install"),n.install=a})(r||(r={})),t.default=r}}),Mu=X({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/is.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.stringArray=t.array=t.func=t.error=t.number=t.string=t.boolean=void 0;function e(l){return l===!0||l===!1}s(e,"boolean"),t.boolean=e;function r(l){return typeof l=="string"||l instanceof String}s(r,"string"),t.string=r;function n(l){return typeof l=="number"||l instanceof Number}s(n,"number"),t.number=n;function a(l){return l instanceof Error}s(a,"error"),t.error=a;function i(l){return typeof l=="function"}s(i,"func"),t.func=i;function o(l){return Array.isArray(l)}s(o,"array"),t.array=o;function u(l){return o(l)&&l.every(c=>r(c))}s(u,"stringArray"),t.stringArray=u}}),al=X({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/events.js"(t){var i,o;Object.defineProperty(t,"__esModule",{value:!0}),t.Emitter=t.Event=void 0;var e=Vn(),r;(function(u){const l={dispose(){}};u.None=function(){return l}})(r||(t.Event=r={}));var n=(i=class{add(l,c=null,f){this._callbacks||(this._callbacks=[],this._contexts=[]),this._callbacks.push(l),this._contexts.push(c),Array.isArray(f)&&f.push({dispose:s(()=>this.remove(l,c),"dispose")})}remove(l,c=null){if(!this._callbacks)return;let f=!1;for(let d=0,p=this._callbacks.length;d<p;d++)if(this._callbacks[d]===l)if(this._contexts[d]===c){this._callbacks.splice(d,1),this._contexts.splice(d,1);return}else f=!0;if(f)throw new Error("When adding a listener with a context, you should remove it with the same context")}invoke(...l){if(!this._callbacks)return[];const c=[],f=this._callbacks.slice(0),d=this._contexts.slice(0);for(let p=0,y=f.length;p<y;p++)try{c.push(f[p].apply(d[p],l))}catch(h){(0,e.default)().console.error(h)}return c}isEmpty(){return!this._callbacks||this._callbacks.length===0}dispose(){this._callbacks=void 0,this._contexts=void 0}},s(i,"CallbackList"),i),a=(o=class{constructor(l){this._options=l}get event(){return this._event||(this._event=(l,c,f)=>{this._callbacks||(this._callbacks=new n),this._options&&this._options.onFirstListenerAdd&&this._callbacks.isEmpty()&&this._options.onFirstListenerAdd(this),this._callbacks.add(l,c);const d={dispose:s(()=>{this._callbacks&&(this._callbacks.remove(l,c),d.dispose=o._noop,this._options&&this._options.onLastListenerRemove&&this._callbacks.isEmpty()&&this._options.onLastListenerRemove(this))},"dispose")};return Array.isArray(f)&&f.push(d),d}),this._event}fire(l){this._callbacks&&this._callbacks.invoke.call(this._callbacks,l)}dispose(){this._callbacks&&(this._callbacks.dispose(),this._callbacks=void 0)}},s(o,"Emitter"),o);t.Emitter=a,a._noop=function(){}}}),Df=X({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/cancellation.js"(t){var l,c;Object.defineProperty(t,"__esModule",{value:!0}),t.CancellationTokenSource=t.CancellationToken=void 0;var e=Vn(),r=Mu(),n=al(),a;(function(f){f.None=Object.freeze({isCancellationRequested:!1,onCancellationRequested:n.Event.None}),f.Cancelled=Object.freeze({isCancellationRequested:!0,onCancellationRequested:n.Event.None});function d(p){const y=p;return y&&(y===f.None||y===f.Cancelled||r.boolean(y.isCancellationRequested)&&!!y.onCancellationRequested)}s(d,"is"),f.is=d})(a||(t.CancellationToken=a={}));var i=Object.freeze(function(f,d){const p=(0,e.default)().timer.setTimeout(f.bind(d),0);return{dispose(){p.dispose()}}}),o=(l=class{constructor(){this._isCancelled=!1}cancel(){this._isCancelled||(this._isCancelled=!0,this._emitter&&(this._emitter.fire(void 0),this.dispose()))}get isCancellationRequested(){return this._isCancelled}get onCancellationRequested(){return this._isCancelled?i:(this._emitter||(this._emitter=new n.Emitter),this._emitter.event)}dispose(){this._emitter&&(this._emitter.dispose(),this._emitter=void 0)}},s(l,"MutableToken"),l),u=(c=class{get token(){return this._token||(this._token=new o),this._token}cancel(){this._token?this._token.cancel():this._token=a.Cancelled}dispose(){this._token?this._token instanceof o&&this._token.dispose():this._token=a.None}},s(c,"CancellationTokenSource"),c);t.CancellationTokenSource=u}}),G$=X({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/messages.js"(t){var k,_,v,I,R,A,S,L,x,O,z,M,Y,q,Z,ae,Oe,pe,Ee,Ve,Le,ee,Qe,ce,qe;Object.defineProperty(t,"__esModule",{value:!0}),t.Message=t.NotificationType9=t.NotificationType8=t.NotificationType7=t.NotificationType6=t.NotificationType5=t.NotificationType4=t.NotificationType3=t.NotificationType2=t.NotificationType1=t.NotificationType0=t.NotificationType=t.RequestType9=t.RequestType8=t.RequestType7=t.RequestType6=t.RequestType5=t.RequestType4=t.RequestType3=t.RequestType2=t.RequestType1=t.RequestType=t.RequestType0=t.AbstractMessageSignature=t.ParameterStructures=t.ResponseError=t.ErrorCodes=void 0;var e=Mu(),r;(function(ge){ge.ParseError=-32700,ge.InvalidRequest=-32600,ge.MethodNotFound=-32601,ge.InvalidParams=-32602,ge.InternalError=-32603,ge.jsonrpcReservedErrorRangeStart=-32099,ge.serverErrorStart=-32099,ge.MessageWriteError=-32099,ge.MessageReadError=-32098,ge.PendingResponseRejected=-32097,ge.ConnectionInactive=-32096,ge.ServerNotInitialized=-32002,ge.UnknownErrorCode=-32001,ge.jsonrpcReservedErrorRangeEnd=-32e3,ge.serverErrorEnd=-32e3})(r||(t.ErrorCodes=r={}));var n=(k=class extends Error{constructor(G,je,Qt){super(je),this.code=e.number(G)?G:r.UnknownErrorCode,this.data=Qt,Object.setPrototypeOf(this,k.prototype)}toJson(){const G={code:this.code,message:this.message};return this.data!==void 0&&(G.data=this.data),G}},s(k,"ResponseError"),k);t.ResponseError=n;var a=(_=class{constructor(G){this.kind=G}static is(G){return G===_.auto||G===_.byName||G===_.byPosition}toString(){return this.kind}},s(_,"ParameterStructures"),_);t.ParameterStructures=a,a.auto=new a("auto"),a.byPosition=new a("byPosition"),a.byName=new a("byName");var i=(v=class{constructor(G,je){this.method=G,this.numberOfParams=je}get parameterStructures(){return a.auto}},s(v,"AbstractMessageSignature"),v);t.AbstractMessageSignature=i;var o=(I=class extends i{constructor(G){super(G,0)}},s(I,"RequestType0"),I);t.RequestType0=o;var u=(R=class extends i{constructor(G,je=a.auto){super(G,1),this._parameterStructures=je}get parameterStructures(){return this._parameterStructures}},s(R,"RequestType"),R);t.RequestType=u;var l=(A=class extends i{constructor(G,je=a.auto){super(G,1),this._parameterStructures=je}get parameterStructures(){return this._parameterStructures}},s(A,"RequestType1"),A);t.RequestType1=l;var c=(S=class extends i{constructor(G){super(G,2)}},s(S,"RequestType2"),S);t.RequestType2=c;var f=(L=class extends i{constructor(G){super(G,3)}},s(L,"RequestType3"),L);t.RequestType3=f;var d=(x=class extends i{constructor(G){super(G,4)}},s(x,"RequestType4"),x);t.RequestType4=d;var p=(O=class extends i{constructor(G){super(G,5)}},s(O,"RequestType5"),O);t.RequestType5=p;var y=(z=class extends i{constructor(G){super(G,6)}},s(z,"RequestType6"),z);t.RequestType6=y;var h=(M=class extends i{constructor(G){super(G,7)}},s(M,"RequestType7"),M);t.RequestType7=h;var $=(Y=class extends i{constructor(G){super(G,8)}},s(Y,"RequestType8"),Y);t.RequestType8=$;var C=(q=class extends i{constructor(G){super(G,9)}},s(q,"RequestType9"),q);t.RequestType9=C;var T=(Z=class extends i{constructor(G,je=a.auto){super(G,1),this._parameterStructures=je}get parameterStructures(){return this._parameterStructures}},s(Z,"NotificationType"),Z);t.NotificationType=T;var w=(ae=class extends i{constructor(G){super(G,0)}},s(ae,"NotificationType0"),ae);t.NotificationType0=w;var b=(Oe=class extends i{constructor(G,je=a.auto){super(G,1),this._parameterStructures=je}get parameterStructures(){return this._parameterStructures}},s(Oe,"NotificationType1"),Oe);t.NotificationType1=b;var N=(pe=class extends i{constructor(G){super(G,2)}},s(pe,"NotificationType2"),pe);t.NotificationType2=N;var B=(Ee=class extends i{constructor(G){super(G,3)}},s(Ee,"NotificationType3"),Ee);t.NotificationType3=B;var ne=(Ve=class extends i{constructor(G){super(G,4)}},s(Ve,"NotificationType4"),Ve);t.NotificationType4=ne;var J=(Le=class extends i{constructor(G){super(G,5)}},s(Le,"NotificationType5"),Le);t.NotificationType5=J;var he=(ee=class extends i{constructor(G){super(G,6)}},s(ee,"NotificationType6"),ee);t.NotificationType6=he;var Ae=(Qe=class extends i{constructor(G){super(G,7)}},s(Qe,"NotificationType7"),Qe);t.NotificationType7=Ae;var ye=(ce=class extends i{constructor(G){super(G,8)}},s(ce,"NotificationType8"),ce);t.NotificationType8=ye;var ue=(qe=class extends i{constructor(G){super(G,9)}},s(qe,"NotificationType9"),qe);t.NotificationType9=ue;var ot;(function(ge){function G(Dt){const ve=Dt;return ve&&e.string(ve.method)&&(e.string(ve.id)||e.number(ve.id))}s(G,"isRequest"),ge.isRequest=G;function je(Dt){const ve=Dt;return ve&&e.string(ve.method)&&Dt.id===void 0}s(je,"isNotification"),ge.isNotification=je;function Qt(Dt){const ve=Dt;return ve&&(ve.result!==void 0||!!ve.error)&&(e.string(ve.id)||e.number(ve.id)||ve.id===null)}s(Qt,"isResponse"),ge.isResponse=Qt})(ot||(t.Message=ot={}))}}),F$=X({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/linkedMap.js"(t){var i,o;var e;Object.defineProperty(t,"__esModule",{value:!0}),t.LRUCache=t.LinkedMap=t.Touch=void 0;var r;(function(u){u.None=0,u.First=1,u.AsOld=u.First,u.Last=2,u.AsNew=u.Last})(r||(t.Touch=r={}));var n=(i=class{constructor(){this[e]="LinkedMap",this._map=new Map,this._head=void 0,this._tail=void 0,this._size=0,this._state=0}clear(){this._map.clear(),this._head=void 0,this._tail=void 0,this._size=0,this._state++}isEmpty(){return!this._head&&!this._tail}get size(){return this._size}get first(){return this._head?.value}get last(){return this._tail?.value}has(l){return this._map.has(l)}get(l,c=r.None){const f=this._map.get(l);if(f)return c!==r.None&&this.touch(f,c),f.value}set(l,c,f=r.None){let d=this._map.get(l);if(d)d.value=c,f!==r.None&&this.touch(d,f);else{switch(d={key:l,value:c,next:void 0,previous:void 0},f){case r.None:this.addItemLast(d);break;case r.First:this.addItemFirst(d);break;case r.Last:this.addItemLast(d);break;default:this.addItemLast(d);break}this._map.set(l,d),this._size++}return this}delete(l){return!!this.remove(l)}remove(l){const c=this._map.get(l);if(c)return this._map.delete(l),this.removeItem(c),this._size--,c.value}shift(){if(!this._head&&!this._tail)return;if(!this._head||!this._tail)throw new Error("Invalid list");const l=this._head;return this._map.delete(l.key),this.removeItem(l),this._size--,l.value}forEach(l,c){const f=this._state;let d=this._head;for(;d;){if(c?l.bind(c)(d.value,d.key,this):l(d.value,d.key,this),this._state!==f)throw new Error("LinkedMap got modified during iteration.");d=d.next}}keys(){const l=this._state;let c=this._head;const f={[Symbol.iterator]:()=>f,next:s(()=>{if(this._state!==l)throw new Error("LinkedMap got modified during iteration.");if(c){const d={value:c.key,done:!1};return c=c.next,d}else return{value:void 0,done:!0}},"next")};return f}values(){const l=this._state;let c=this._head;const f={[Symbol.iterator]:()=>f,next:s(()=>{if(this._state!==l)throw new Error("LinkedMap got modified during iteration.");if(c){const d={value:c.value,done:!1};return c=c.next,d}else return{value:void 0,done:!0}},"next")};return f}entries(){const l=this._state;let c=this._head;const f={[Symbol.iterator]:()=>f,next:s(()=>{if(this._state!==l)throw new Error("LinkedMap got modified during iteration.");if(c){const d={value:[c.key,c.value],done:!1};return c=c.next,d}else return{value:void 0,done:!0}},"next")};return f}[(e=Symbol.toStringTag,Symbol.iterator)](){return this.entries()}trimOld(l){if(l>=this.size)return;if(l===0){this.clear();return}let c=this._head,f=this.size;for(;c&&f>l;)this._map.delete(c.key),c=c.next,f--;this._head=c,this._size=f,c&&(c.previous=void 0),this._state++}addItemFirst(l){if(!this._head&&!this._tail)this._tail=l;else if(this._head)l.next=this._head,this._head.previous=l;else throw new Error("Invalid list");this._head=l,this._state++}addItemLast(l){if(!this._head&&!this._tail)this._head=l;else if(this._tail)l.previous=this._tail,this._tail.next=l;else throw new Error("Invalid list");this._tail=l,this._state++}removeItem(l){if(l===this._head&&l===this._tail)this._head=void 0,this._tail=void 0;else if(l===this._head){if(!l.next)throw new Error("Invalid list");l.next.previous=void 0,this._head=l.next}else if(l===this._tail){if(!l.previous)throw new Error("Invalid list");l.previous.next=void 0,this._tail=l.previous}else{const c=l.next,f=l.previous;if(!c||!f)throw new Error("Invalid list");c.previous=f,f.next=c}l.next=void 0,l.previous=void 0,this._state++}touch(l,c){if(!this._head||!this._tail)throw new Error("Invalid list");if(!(c!==r.First&&c!==r.Last)){if(c===r.First){if(l===this._head)return;const f=l.next,d=l.previous;l===this._tail?(d.next=void 0,this._tail=d):(f.previous=d,d.next=f),l.previous=void 0,l.next=this._head,this._head.previous=l,this._head=l,this._state++}else if(c===r.Last){if(l===this._tail)return;const f=l.next,d=l.previous;l===this._head?(f.previous=void 0,this._head=f):(f.previous=d,d.next=f),l.next=void 0,l.previous=this._tail,this._tail.next=l,this._tail=l,this._state++}}}toJSON(){const l=[];return this.forEach((c,f)=>{l.push([f,c])}),l}fromJSON(l){this.clear();for(const[c,f]of l)this.set(c,f)}},s(i,"LinkedMap"),i);t.LinkedMap=n;var a=(o=class extends n{constructor(l,c=1){super(),this._limit=l,this._ratio=Math.min(Math.max(0,c),1)}get limit(){return this._limit}set limit(l){this._limit=l,this.checkTrim()}get ratio(){return this._ratio}set ratio(l){this._ratio=Math.min(Math.max(0,l),1),this.checkTrim()}get(l,c=r.AsNew){return super.get(l,c)}peek(l){return super.get(l,r.None)}set(l,c){return super.set(l,c,r.Last),this.checkTrim(),this}checkTrim(){this.size>this._limit&&this.trimOld(Math.round(this._limit*this._ratio))}},s(o,"LRUCache"),o);t.LRUCache=a}}),Tk=X({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/disposable.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.Disposable=void 0;var e;(function(r){function n(a){return{dispose:a}}s(n,"create"),r.create=n})(e||(t.Disposable=e={}))}}),$k=X({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/sharedArrayCancellation.js"(t){var u,l,c,f;Object.defineProperty(t,"__esModule",{value:!0}),t.SharedArrayReceiverStrategy=t.SharedArraySenderStrategy=void 0;var e=Df(),r;(function(d){d.Continue=0,d.Cancelled=1})(r||(r={}));var n=(u=class{constructor(){this.buffers=new Map}enableCancellation(p){if(p.id===null)return;const y=new SharedArrayBuffer(4),h=new Int32Array(y,0,1);h[0]=r.Continue,this.buffers.set(p.id,y),p.$cancellationData=y}async sendCancellation(p,y){const h=this.buffers.get(y);if(h===void 0)return;const $=new Int32Array(h,0,1);Atomics.store($,0,r.Cancelled)}cleanup(p){this.buffers.delete(p)}dispose(){this.buffers.clear()}},s(u,"SharedArraySenderStrategy"),u);t.SharedArraySenderStrategy=n;var a=(l=class{constructor(p){this.data=new Int32Array(p,0,1)}get isCancellationRequested(){return Atomics.load(this.data,0)===r.Cancelled}get onCancellationRequested(){throw new Error("Cancellation over SharedArrayBuffer doesn't support cancellation events")}},s(l,"SharedArrayBufferCancellationToken"),l),i=(c=class{constructor(p){this.token=new a(p)}cancel(){}dispose(){}},s(c,"SharedArrayBufferCancellationTokenSource"),c),o=(f=class{constructor(){this.kind="request"}createCancellationTokenSource(p){const y=p.$cancellationData;return y===void 0?new e.CancellationTokenSource:new i(y)}},s(f,"SharedArrayReceiverStrategy"),f);t.SharedArrayReceiverStrategy=o}}),z$=X({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/semaphore.js"(t){var n;Object.defineProperty(t,"__esModule",{value:!0}),t.Semaphore=void 0;var e=Vn(),r=(n=class{constructor(i=1){if(i<=0)throw new Error("Capacity must be greater than 0");this._capacity=i,this._active=0,this._waiting=[]}lock(i){return new Promise((o,u)=>{this._waiting.push({thunk:i,resolve:o,reject:u}),this.runNext()})}get active(){return this._active}runNext(){this._waiting.length===0||this._active===this._capacity||(0,e.default)().timer.setImmediate(()=>this.doRunNext())}doRunNext(){if(this._waiting.length===0||this._active===this._capacity)return;const i=this._waiting.shift();if(this._active++,this._active>this._capacity)throw new Error("To many thunks active");try{const o=i.thunk();o instanceof Promise?o.then(u=>{this._active--,i.resolve(u),this.runNext()},u=>{this._active--,i.reject(u),this.runNext()}):(this._active--,i.resolve(o),this.runNext())}catch(o){this._active--,i.reject(o),this.runNext()}}},s(n,"Semaphore"),n);t.Semaphore=r}}),Rk=X({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/messageReader.js"(t){var c,f;Object.defineProperty(t,"__esModule",{value:!0}),t.ReadableStreamMessageReader=t.AbstractMessageReader=t.MessageReader=void 0;var e=Vn(),r=Mu(),n=al(),a=z$(),i;(function(d){function p(y){let h=y;return h&&r.func(h.listen)&&r.func(h.dispose)&&r.func(h.onError)&&r.func(h.onClose)&&r.func(h.onPartialMessage)}s(p,"is"),d.is=p})(i||(t.MessageReader=i={}));var o=(c=class{constructor(){this.errorEmitter=new n.Emitter,this.closeEmitter=new n.Emitter,this.partialMessageEmitter=new n.Emitter}dispose(){this.errorEmitter.dispose(),this.closeEmitter.dispose()}get onError(){return this.errorEmitter.event}fireError(p){this.errorEmitter.fire(this.asError(p))}get onClose(){return this.closeEmitter.event}fireClose(){this.closeEmitter.fire(void 0)}get onPartialMessage(){return this.partialMessageEmitter.event}firePartialMessage(p){this.partialMessageEmitter.fire(p)}asError(p){return p instanceof Error?p:new Error(`Reader received error. Reason: ${r.string(p.message)?p.message:"unknown"}`)}},s(c,"AbstractMessageReader"),c);t.AbstractMessageReader=o;var u;(function(d){function p(y){let h,$;const C=new Map;let T;const w=new Map;if(y===void 0||typeof y=="string")h=y??"utf-8";else{if(h=y.charset??"utf-8",y.contentDecoder!==void 0&&($=y.contentDecoder,C.set($.name,$)),y.contentDecoders!==void 0)for(const b of y.contentDecoders)C.set(b.name,b);if(y.contentTypeDecoder!==void 0&&(T=y.contentTypeDecoder,w.set(T.name,T)),y.contentTypeDecoders!==void 0)for(const b of y.contentTypeDecoders)w.set(b.name,b)}return T===void 0&&(T=(0,e.default)().applicationJson.decoder,w.set(T.name,T)),{charset:h,contentDecoder:$,contentDecoders:C,contentTypeDecoder:T,contentTypeDecoders:w}}s(p,"fromOptions"),d.fromOptions=p})(u||(u={}));var l=(f=class extends o{constructor(p,y){super(),this.readable=p,this.options=u.fromOptions(y),this.buffer=(0,e.default)().messageBuffer.create(this.options.charset),this._partialMessageTimeout=1e4,this.nextMessageLength=-1,this.messageToken=0,this.readSemaphore=new a.Semaphore(1)}set partialMessageTimeout(p){this._partialMessageTimeout=p}get partialMessageTimeout(){return this._partialMessageTimeout}listen(p){this.nextMessageLength=-1,this.messageToken=0,this.partialMessageTimer=void 0,this.callback=p;const y=this.readable.onData(h=>{this.onData(h)});return this.readable.onError(h=>this.fireError(h)),this.readable.onClose(()=>this.fireClose()),y}onData(p){try{for(this.buffer.append(p);;){if(this.nextMessageLength===-1){const h=this.buffer.tryReadHeaders(!0);if(!h)return;const $=h.get("content-length");if(!$){this.fireError(new Error(`Header must provide a Content-Length property.
6
6
  ${JSON.stringify(Object.fromEntries(h))}`));return}const C=parseInt($);if(isNaN(C)){this.fireError(new Error(`Content-Length value must be a number. Got ${$}`));return}this.nextMessageLength=C}const y=this.buffer.tryReadBody(this.nextMessageLength);if(y===void 0){this.setPartialMessageTimer();return}this.clearPartialMessageTimer(),this.nextMessageLength=-1,this.readSemaphore.lock(async()=>{const h=this.options.contentDecoder!==void 0?await this.options.contentDecoder.decode(y):y,$=await this.options.contentTypeDecoder.decode(h,this.options);this.callback($)}).catch(h=>{this.fireError(h)})}}catch(y){this.fireError(y)}}clearPartialMessageTimer(){this.partialMessageTimer&&(this.partialMessageTimer.dispose(),this.partialMessageTimer=void 0)}setPartialMessageTimer(){this.clearPartialMessageTimer(),!(this._partialMessageTimeout<=0)&&(this.partialMessageTimer=(0,e.default)().timer.setTimeout((p,y)=>{this.partialMessageTimer=void 0,p===this.messageToken&&(this.firePartialMessage({messageToken:p,waitingTime:y}),this.setPartialMessageTimer())},this._partialMessageTimeout,this.messageToken,this._partialMessageTimeout))}},s(f,"ReadableStreamMessageReader"),f);t.ReadableStreamMessageReader=l}}),Ak=X({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/messageWriter.js"(t){var d,p;Object.defineProperty(t,"__esModule",{value:!0}),t.WriteableStreamMessageWriter=t.AbstractMessageWriter=t.MessageWriter=void 0;var e=Vn(),r=Mu(),n=z$(),a=al(),i="Content-Length: ",o=`\r
7
7
  `,u;(function(y){function h($){let C=$;return C&&r.func(C.dispose)&&r.func(C.onClose)&&r.func(C.onError)&&r.func(C.write)}s(h,"is"),y.is=h})(u||(t.MessageWriter=u={}));var l=(d=class{constructor(){this.errorEmitter=new a.Emitter,this.closeEmitter=new a.Emitter}dispose(){this.errorEmitter.dispose(),this.closeEmitter.dispose()}get onError(){return this.errorEmitter.event}fireError(h,$,C){this.errorEmitter.fire([this.asError(h),$,C])}get onClose(){return this.closeEmitter.event}fireClose(){this.closeEmitter.fire(void 0)}asError(h){return h instanceof Error?h:new Error(`Writer received error. Reason: ${r.string(h.message)?h.message:"unknown"}`)}},s(d,"AbstractMessageWriter"),d);t.AbstractMessageWriter=l;var c;(function(y){function h($){return $===void 0||typeof $=="string"?{charset:$??"utf-8",contentTypeEncoder:(0,e.default)().applicationJson.encoder}:{charset:$.charset??"utf-8",contentEncoder:$.contentEncoder,contentTypeEncoder:$.contentTypeEncoder??(0,e.default)().applicationJson.encoder}}s(h,"fromOptions"),y.fromOptions=h})(c||(c={}));var f=(p=class extends l{constructor(h,$){super(),this.writable=h,this.options=c.fromOptions($),this.errorCount=0,this.writeSemaphore=new n.Semaphore(1),this.writable.onError(C=>this.fireError(C)),this.writable.onClose(()=>this.fireClose())}async write(h){return this.writeSemaphore.lock(async()=>this.options.contentTypeEncoder.encode(h,this.options).then(C=>this.options.contentEncoder!==void 0?this.options.contentEncoder.encode(C):C).then(C=>{const T=[];return T.push(i,C.byteLength.toString(),o),T.push(o),this.doWrite(h,T,C)},C=>{throw this.fireError(C),C}))}async doWrite(h,$,C){try{return await this.writable.write($.join(""),"ascii"),this.writable.write(C)}catch(T){return this.handleError(T,h),Promise.reject(T)}}handleError(h,$){this.errorCount++,this.fireError(h,$,this.errorCount)}end(){this.writable.end()}},s(p,"WriteableStreamMessageWriter"),p);t.WriteableStreamMessageWriter=f}}),Ek=X({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/messageBuffer.js"(t){var i;Object.defineProperty(t,"__esModule",{value:!0}),t.AbstractMessageBuffer=void 0;var e=13,r=10,n=`\r
8
8
  `,a=(i=class{constructor(u="utf-8"){this._encoding=u,this._chunks=[],this._totalLength=0}get encoding(){return this._encoding}append(u){const l=typeof u=="string"?this.fromString(u,this._encoding):u;this._chunks.push(l),this._totalLength+=l.byteLength}tryReadHeaders(u=!1){if(this._chunks.length===0)return;let l=0,c=0,f=0,d=0;e:for(;c<this._chunks.length;){const $=this._chunks[c];for(f=0;f<$.length;){switch($[f]){case e:switch(l){case 0:l=1;break;case 2:l=3;break;default:l=0}break;case r:switch(l){case 1:l=2;break;case 3:l=4,f++;break e;default:l=0}break;default:l=0}f++}d+=$.byteLength,c++}if(l!==4)return;const p=this._read(d+f),y=new Map,h=this.toString(p,"ascii").split(n);if(h.length<2)return y;for(let $=0;$<h.length-2;$++){const C=h[$],T=C.indexOf(":");if(T===-1)throw new Error(`Message header must separate key and value using ':'
9
- ${C}`);const w=C.substr(0,T),b=C.substr(T+1).trim();y.set(u?w.toLowerCase():w,b)}return y}tryReadBody(u){if(!(this._totalLength<u))return this._read(u)}get numberOfBytes(){return this._totalLength}_read(u){if(u===0)return this.emptyBuffer();if(u>this._totalLength)throw new Error("Cannot read so many bytes!");if(this._chunks[0].byteLength===u){const d=this._chunks[0];return this._chunks.shift(),this._totalLength-=u,this.asNative(d)}if(this._chunks[0].byteLength>u){const d=this._chunks[0],p=this.asNative(d,u);return this._chunks[0]=d.slice(u),this._totalLength-=u,p}const l=this.allocNative(u);let c=0,f=0;for(;u>0;){const d=this._chunks[f];if(d.byteLength>u){const p=d.slice(0,u);l.set(p,c),c+=u,this._chunks[f]=d.slice(u),this._totalLength-=u,u-=u}else l.set(d,c),c+=d.byteLength,this._chunks.shift(),this._totalLength-=d.byteLength,u-=d.byteLength}return l}},s(i,"AbstractMessageBuffer"),i);t.AbstractMessageBuffer=a}}),Ck=X({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/connection.js"(t){var k,_;Object.defineProperty(t,"__esModule",{value:!0}),t.createMessageConnection=t.ConnectionOptions=t.MessageStrategy=t.CancellationStrategy=t.CancellationSenderStrategy=t.CancellationReceiverStrategy=t.RequestCancellationReceiverStrategy=t.IdCancellationReceiverStrategy=t.ConnectionStrategy=t.ConnectionError=t.ConnectionErrors=t.LogTraceNotification=t.SetTraceNotification=t.TraceFormat=t.TraceValues=t.Trace=t.NullLogger=t.ProgressType=t.ProgressToken=void 0;var e=Vn(),r=Mu(),n=G$(),a=F$(),i=al(),o=Df(),u;(function(v){v.type=new n.NotificationType("$/cancelRequest")})(u||(u={}));var l;(function(v){function I(R){return typeof R=="string"||typeof R=="number"}s(I,"is"),v.is=I})(l||(t.ProgressToken=l={}));var c;(function(v){v.type=new n.NotificationType("$/progress")})(c||(c={}));var f=(k=class{constructor(){}},s(k,"ProgressType"),k);t.ProgressType=f;var d;(function(v){function I(R){return r.func(R)}s(I,"is"),v.is=I})(d||(d={})),t.NullLogger=Object.freeze({error:s(()=>{},"error"),warn:s(()=>{},"warn"),info:s(()=>{},"info"),log:s(()=>{},"log")});var p;(function(v){v[v.Off=0]="Off",v[v.Messages=1]="Messages",v[v.Compact=2]="Compact",v[v.Verbose=3]="Verbose"})(p||(t.Trace=p={}));var y;(function(v){v.Off="off",v.Messages="messages",v.Compact="compact",v.Verbose="verbose"})(y||(t.TraceValues=y={})),function(v){function I(A){if(!r.string(A))return v.Off;switch(A=A.toLowerCase(),A){case"off":return v.Off;case"messages":return v.Messages;case"compact":return v.Compact;case"verbose":return v.Verbose;default:return v.Off}}s(I,"fromString"),v.fromString=I;function R(A){switch(A){case v.Off:return"off";case v.Messages:return"messages";case v.Compact:return"compact";case v.Verbose:return"verbose";default:return"off"}}s(R,"toString"),v.toString=R}(p||(t.Trace=p={}));var h;(function(v){v.Text="text",v.JSON="json"})(h||(t.TraceFormat=h={})),function(v){function I(R){return r.string(R)?(R=R.toLowerCase(),R==="json"?v.JSON:v.Text):v.Text}s(I,"fromString"),v.fromString=I}(h||(t.TraceFormat=h={}));var $;(function(v){v.type=new n.NotificationType("$/setTrace")})($||(t.SetTraceNotification=$={}));var C;(function(v){v.type=new n.NotificationType("$/logTrace")})(C||(t.LogTraceNotification=C={}));var T;(function(v){v[v.Closed=1]="Closed",v[v.Disposed=2]="Disposed",v[v.AlreadyListening=3]="AlreadyListening"})(T||(t.ConnectionErrors=T={}));var w=(_=class extends Error{constructor(I,R){super(R),this.code=I,Object.setPrototypeOf(this,_.prototype)}},s(_,"ConnectionError"),_);t.ConnectionError=w;var b;(function(v){function I(R){const A=R;return A&&r.func(A.cancelUndispatched)}s(I,"is"),v.is=I})(b||(t.ConnectionStrategy=b={}));var N;(function(v){function I(R){const A=R;return A&&(A.kind===void 0||A.kind==="id")&&r.func(A.createCancellationTokenSource)&&(A.dispose===void 0||r.func(A.dispose))}s(I,"is"),v.is=I})(N||(t.IdCancellationReceiverStrategy=N={}));var B;(function(v){function I(R){const A=R;return A&&A.kind==="request"&&r.func(A.createCancellationTokenSource)&&(A.dispose===void 0||r.func(A.dispose))}s(I,"is"),v.is=I})(B||(t.RequestCancellationReceiverStrategy=B={}));var ne;(function(v){v.Message=Object.freeze({createCancellationTokenSource(R){return new o.CancellationTokenSource}});function I(R){return N.is(R)||B.is(R)}s(I,"is"),v.is=I})(ne||(t.CancellationReceiverStrategy=ne={}));var J;(function(v){v.Message=Object.freeze({sendCancellation(R,A){return R.sendNotification(u.type,{id:A})},cleanup(R){}});function I(R){const A=R;return A&&r.func(A.sendCancellation)&&r.func(A.cleanup)}s(I,"is"),v.is=I})(J||(t.CancellationSenderStrategy=J={}));var he;(function(v){v.Message=Object.freeze({receiver:ne.Message,sender:J.Message});function I(R){const A=R;return A&&ne.is(A.receiver)&&J.is(A.sender)}s(I,"is"),v.is=I})(he||(t.CancellationStrategy=he={}));var Ae;(function(v){function I(R){const A=R;return A&&r.func(A.handleMessage)}s(I,"is"),v.is=I})(Ae||(t.MessageStrategy=Ae={}));var ye;(function(v){function I(R){const A=R;return A&&(he.is(A.cancellationStrategy)||b.is(A.connectionStrategy)||Ae.is(A.messageStrategy))}s(I,"is"),v.is=I})(ye||(t.ConnectionOptions=ye={}));var ue;(function(v){v[v.New=1]="New",v[v.Listening=2]="Listening",v[v.Closed=3]="Closed",v[v.Disposed=4]="Disposed"})(ue||(ue={}));function ot(v,I,R,A){const S=R!==void 0?R:t.NullLogger;let L=0,x=0,O=0;const z="2.0";let M;const Y=new Map;let q;const Z=new Map,ae=new Map;let Oe,pe=new a.LinkedMap,Ee=new Map,Ve=new Set,Le=new Map,ee=p.Off,Qe=h.Text,ce,qe=ue.New;const ge=new i.Emitter,G=new i.Emitter,je=new i.Emitter,Qt=new i.Emitter,Dt=new i.Emitter,ve=A&&A.cancellationStrategy?A.cancellationStrategy:he.Message;function pa(g){if(g===null)throw new Error("Can't send requests with id null since the response can't be correlated.");return"req-"+g.toString()}s(pa,"createRequestQueueKey");function hl(g){return g===null?"res-unknown-"+(++O).toString():"res-"+g.toString()}s(hl,"createResponseQueueKey");function yl(){return"not-"+(++x).toString()}s(yl,"createNotificationQueueKey");function gl(g,P){n.Message.isRequest(P)?g.set(pa(P.id),P):n.Message.isResponse(P)?g.set(hl(P.id),P):g.set(yl(),P)}s(gl,"addMessageToQueue");function vl(g){}s(vl,"cancelUndispatched");function ma(){return qe===ue.Listening}s(ma,"isListening");function ha(){return qe===ue.Closed}s(ha,"isClosed");function er(){return qe===ue.Disposed}s(er,"isDisposed");function ya(){(qe===ue.New||qe===ue.Listening)&&(qe=ue.Closed,G.fire(void 0))}s(ya,"closeHandler");function Tl(g){ge.fire([g,void 0,void 0])}s(Tl,"readErrorHandler");function $l(g){ge.fire(g)}s($l,"writeErrorHandler"),v.onClose(ya),v.onError(Tl),I.onClose(ya),I.onError($l);function ga(){Oe||pe.size===0||(Oe=(0,e.default)().timer.setImmediate(()=>{Oe=void 0,Rl()}))}s(ga,"triggerMessageQueue");function va(g){n.Message.isRequest(g)?Al(g):n.Message.isNotification(g)?Cl(g):n.Message.isResponse(g)?El(g):bl(g)}s(va,"handleMessage");function Rl(){if(pe.size===0)return;const g=pe.shift();try{const P=A?.messageStrategy;Ae.is(P)?P.handleMessage(g,va):va(g)}finally{ga()}}s(Rl,"processMessageQueue");const nc=s(g=>{try{if(n.Message.isNotification(g)&&g.method===u.type.method){const P=g.params.id,D=pa(P),F=pe.get(D);if(n.Message.isRequest(F)){const me=A?.connectionStrategy,De=me&&me.cancelUndispatched?me.cancelUndispatched(F,vl):void 0;if(De&&(De.error!==void 0||De.result!==void 0)){pe.delete(D),Le.delete(P),De.id=F.id,jr(De,g.method,Date.now()),I.write(De).catch(()=>S.error("Sending response for canceled message failed."));return}}const Ce=Le.get(P);if(Ce!==void 0){Ce.cancel(),on(g);return}else Ve.add(P)}gl(pe,g)}finally{ga()}},"callback");function Al(g){if(er())return;function P(ie,Ne,fe){const Ue={jsonrpc:z,id:g.id};ie instanceof n.ResponseError?Ue.error=ie.toJson():Ue.result=ie===void 0?null:ie,jr(Ue,Ne,fe),I.write(Ue).catch(()=>S.error("Sending response failed."))}s(P,"reply");function D(ie,Ne,fe){const Ue={jsonrpc:z,id:g.id,error:ie.toJson()};jr(Ue,Ne,fe),I.write(Ue).catch(()=>S.error("Sending response failed."))}s(D,"replyError");function F(ie,Ne,fe){ie===void 0&&(ie=null);const Ue={jsonrpc:z,id:g.id,result:ie};jr(Ue,Ne,fe),I.write(Ue).catch(()=>S.error("Sending response failed."))}s(F,"replySuccess"),wl(g);const Ce=Y.get(g.method);let me,De;Ce&&(me=Ce.type,De=Ce.handler);const Ge=Date.now();if(De||M){const ie=g.id??String(Date.now()),Ne=N.is(ve.receiver)?ve.receiver.createCancellationTokenSource(ie):ve.receiver.createCancellationTokenSource(g);g.id!==null&&Ve.has(g.id)&&Ne.cancel(),g.id!==null&&Le.set(ie,Ne);try{let fe;if(De)if(g.params===void 0){if(me!==void 0&&me.numberOfParams!==0){D(new n.ResponseError(n.ErrorCodes.InvalidParams,`Request ${g.method} defines ${me.numberOfParams} params but received none.`),g.method,Ge);return}fe=De(Ne.token)}else if(Array.isArray(g.params)){if(me!==void 0&&me.parameterStructures===n.ParameterStructures.byName){D(new n.ResponseError(n.ErrorCodes.InvalidParams,`Request ${g.method} defines parameters by name but received parameters by position`),g.method,Ge);return}fe=De(...g.params,Ne.token)}else{if(me!==void 0&&me.parameterStructures===n.ParameterStructures.byPosition){D(new n.ResponseError(n.ErrorCodes.InvalidParams,`Request ${g.method} defines parameters by position but received parameters by name`),g.method,Ge);return}fe=De(g.params,Ne.token)}else M&&(fe=M(g.method,g.params,Ne.token));const Ue=fe;fe?Ue.then?Ue.then(lt=>{Le.delete(ie),P(lt,g.method,Ge)},lt=>{Le.delete(ie),lt instanceof n.ResponseError?D(lt,g.method,Ge):lt&&r.string(lt.message)?D(new n.ResponseError(n.ErrorCodes.InternalError,`Request ${g.method} failed with message: ${lt.message}`),g.method,Ge):D(new n.ResponseError(n.ErrorCodes.InternalError,`Request ${g.method} failed unexpectedly without providing any details.`),g.method,Ge)}):(Le.delete(ie),P(fe,g.method,Ge)):(Le.delete(ie),F(fe,g.method,Ge))}catch(fe){Le.delete(ie),fe instanceof n.ResponseError?P(fe,g.method,Ge):fe&&r.string(fe.message)?D(new n.ResponseError(n.ErrorCodes.InternalError,`Request ${g.method} failed with message: ${fe.message}`),g.method,Ge):D(new n.ResponseError(n.ErrorCodes.InternalError,`Request ${g.method} failed unexpectedly without providing any details.`),g.method,Ge)}}else D(new n.ResponseError(n.ErrorCodes.MethodNotFound,`Unhandled method ${g.method}`),g.method,Ge)}s(Al,"handleRequest");function El(g){if(!er())if(g.id===null)g.error?S.error(`Received response message without id: Error is:
9
+ ${C}`);const w=C.substr(0,T),b=C.substr(T+1).trim();y.set(u?w.toLowerCase():w,b)}return y}tryReadBody(u){if(!(this._totalLength<u))return this._read(u)}get numberOfBytes(){return this._totalLength}_read(u){if(u===0)return this.emptyBuffer();if(u>this._totalLength)throw new Error("Cannot read so many bytes!");if(this._chunks[0].byteLength===u){const d=this._chunks[0];return this._chunks.shift(),this._totalLength-=u,this.asNative(d)}if(this._chunks[0].byteLength>u){const d=this._chunks[0],p=this.asNative(d,u);return this._chunks[0]=d.slice(u),this._totalLength-=u,p}const l=this.allocNative(u);let c=0,f=0;for(;u>0;){const d=this._chunks[f];if(d.byteLength>u){const p=d.slice(0,u);l.set(p,c),c+=u,this._chunks[f]=d.slice(u),this._totalLength-=u,u-=u}else l.set(d,c),c+=d.byteLength,this._chunks.shift(),this._totalLength-=d.byteLength,u-=d.byteLength}return l}},s(i,"AbstractMessageBuffer"),i);t.AbstractMessageBuffer=a}}),Ck=X({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/connection.js"(t){var k,_;Object.defineProperty(t,"__esModule",{value:!0}),t.createMessageConnection=t.ConnectionOptions=t.MessageStrategy=t.CancellationStrategy=t.CancellationSenderStrategy=t.CancellationReceiverStrategy=t.RequestCancellationReceiverStrategy=t.IdCancellationReceiverStrategy=t.ConnectionStrategy=t.ConnectionError=t.ConnectionErrors=t.LogTraceNotification=t.SetTraceNotification=t.TraceFormat=t.TraceValues=t.Trace=t.NullLogger=t.ProgressType=t.ProgressToken=void 0;var e=Vn(),r=Mu(),n=G$(),a=F$(),i=al(),o=Df(),u;(function(v){v.type=new n.NotificationType("$/cancelRequest")})(u||(u={}));var l;(function(v){function I(R){return typeof R=="string"||typeof R=="number"}s(I,"is"),v.is=I})(l||(t.ProgressToken=l={}));var c;(function(v){v.type=new n.NotificationType("$/progress")})(c||(c={}));var f=(k=class{constructor(){}},s(k,"ProgressType"),k);t.ProgressType=f;var d;(function(v){function I(R){return r.func(R)}s(I,"is"),v.is=I})(d||(d={})),t.NullLogger=Object.freeze({error:s(()=>{},"error"),warn:s(()=>{},"warn"),info:s(()=>{},"info"),log:s(()=>{},"log")});var p;(function(v){v[v.Off=0]="Off",v[v.Messages=1]="Messages",v[v.Compact=2]="Compact",v[v.Verbose=3]="Verbose"})(p||(t.Trace=p={}));var y;(function(v){v.Off="off",v.Messages="messages",v.Compact="compact",v.Verbose="verbose"})(y||(t.TraceValues=y={})),(function(v){function I(A){if(!r.string(A))return v.Off;switch(A=A.toLowerCase(),A){case"off":return v.Off;case"messages":return v.Messages;case"compact":return v.Compact;case"verbose":return v.Verbose;default:return v.Off}}s(I,"fromString"),v.fromString=I;function R(A){switch(A){case v.Off:return"off";case v.Messages:return"messages";case v.Compact:return"compact";case v.Verbose:return"verbose";default:return"off"}}s(R,"toString"),v.toString=R})(p||(t.Trace=p={}));var h;(function(v){v.Text="text",v.JSON="json"})(h||(t.TraceFormat=h={})),(function(v){function I(R){return r.string(R)?(R=R.toLowerCase(),R==="json"?v.JSON:v.Text):v.Text}s(I,"fromString"),v.fromString=I})(h||(t.TraceFormat=h={}));var $;(function(v){v.type=new n.NotificationType("$/setTrace")})($||(t.SetTraceNotification=$={}));var C;(function(v){v.type=new n.NotificationType("$/logTrace")})(C||(t.LogTraceNotification=C={}));var T;(function(v){v[v.Closed=1]="Closed",v[v.Disposed=2]="Disposed",v[v.AlreadyListening=3]="AlreadyListening"})(T||(t.ConnectionErrors=T={}));var w=(_=class extends Error{constructor(I,R){super(R),this.code=I,Object.setPrototypeOf(this,_.prototype)}},s(_,"ConnectionError"),_);t.ConnectionError=w;var b;(function(v){function I(R){const A=R;return A&&r.func(A.cancelUndispatched)}s(I,"is"),v.is=I})(b||(t.ConnectionStrategy=b={}));var N;(function(v){function I(R){const A=R;return A&&(A.kind===void 0||A.kind==="id")&&r.func(A.createCancellationTokenSource)&&(A.dispose===void 0||r.func(A.dispose))}s(I,"is"),v.is=I})(N||(t.IdCancellationReceiverStrategy=N={}));var B;(function(v){function I(R){const A=R;return A&&A.kind==="request"&&r.func(A.createCancellationTokenSource)&&(A.dispose===void 0||r.func(A.dispose))}s(I,"is"),v.is=I})(B||(t.RequestCancellationReceiverStrategy=B={}));var ne;(function(v){v.Message=Object.freeze({createCancellationTokenSource(R){return new o.CancellationTokenSource}});function I(R){return N.is(R)||B.is(R)}s(I,"is"),v.is=I})(ne||(t.CancellationReceiverStrategy=ne={}));var J;(function(v){v.Message=Object.freeze({sendCancellation(R,A){return R.sendNotification(u.type,{id:A})},cleanup(R){}});function I(R){const A=R;return A&&r.func(A.sendCancellation)&&r.func(A.cleanup)}s(I,"is"),v.is=I})(J||(t.CancellationSenderStrategy=J={}));var he;(function(v){v.Message=Object.freeze({receiver:ne.Message,sender:J.Message});function I(R){const A=R;return A&&ne.is(A.receiver)&&J.is(A.sender)}s(I,"is"),v.is=I})(he||(t.CancellationStrategy=he={}));var Ae;(function(v){function I(R){const A=R;return A&&r.func(A.handleMessage)}s(I,"is"),v.is=I})(Ae||(t.MessageStrategy=Ae={}));var ye;(function(v){function I(R){const A=R;return A&&(he.is(A.cancellationStrategy)||b.is(A.connectionStrategy)||Ae.is(A.messageStrategy))}s(I,"is"),v.is=I})(ye||(t.ConnectionOptions=ye={}));var ue;(function(v){v[v.New=1]="New",v[v.Listening=2]="Listening",v[v.Closed=3]="Closed",v[v.Disposed=4]="Disposed"})(ue||(ue={}));function ot(v,I,R,A){const S=R!==void 0?R:t.NullLogger;let L=0,x=0,O=0;const z="2.0";let M;const Y=new Map;let q;const Z=new Map,ae=new Map;let Oe,pe=new a.LinkedMap,Ee=new Map,Ve=new Set,Le=new Map,ee=p.Off,Qe=h.Text,ce,qe=ue.New;const ge=new i.Emitter,G=new i.Emitter,je=new i.Emitter,Qt=new i.Emitter,Dt=new i.Emitter,ve=A&&A.cancellationStrategy?A.cancellationStrategy:he.Message;function pa(g){if(g===null)throw new Error("Can't send requests with id null since the response can't be correlated.");return"req-"+g.toString()}s(pa,"createRequestQueueKey");function hl(g){return g===null?"res-unknown-"+(++O).toString():"res-"+g.toString()}s(hl,"createResponseQueueKey");function yl(){return"not-"+(++x).toString()}s(yl,"createNotificationQueueKey");function gl(g,P){n.Message.isRequest(P)?g.set(pa(P.id),P):n.Message.isResponse(P)?g.set(hl(P.id),P):g.set(yl(),P)}s(gl,"addMessageToQueue");function vl(g){}s(vl,"cancelUndispatched");function ma(){return qe===ue.Listening}s(ma,"isListening");function ha(){return qe===ue.Closed}s(ha,"isClosed");function er(){return qe===ue.Disposed}s(er,"isDisposed");function ya(){(qe===ue.New||qe===ue.Listening)&&(qe=ue.Closed,G.fire(void 0))}s(ya,"closeHandler");function Tl(g){ge.fire([g,void 0,void 0])}s(Tl,"readErrorHandler");function $l(g){ge.fire(g)}s($l,"writeErrorHandler"),v.onClose(ya),v.onError(Tl),I.onClose(ya),I.onError($l);function ga(){Oe||pe.size===0||(Oe=(0,e.default)().timer.setImmediate(()=>{Oe=void 0,Rl()}))}s(ga,"triggerMessageQueue");function va(g){n.Message.isRequest(g)?Al(g):n.Message.isNotification(g)?Cl(g):n.Message.isResponse(g)?El(g):bl(g)}s(va,"handleMessage");function Rl(){if(pe.size===0)return;const g=pe.shift();try{const P=A?.messageStrategy;Ae.is(P)?P.handleMessage(g,va):va(g)}finally{ga()}}s(Rl,"processMessageQueue");const nc=s(g=>{try{if(n.Message.isNotification(g)&&g.method===u.type.method){const P=g.params.id,D=pa(P),F=pe.get(D);if(n.Message.isRequest(F)){const me=A?.connectionStrategy,De=me&&me.cancelUndispatched?me.cancelUndispatched(F,vl):void 0;if(De&&(De.error!==void 0||De.result!==void 0)){pe.delete(D),Le.delete(P),De.id=F.id,jr(De,g.method,Date.now()),I.write(De).catch(()=>S.error("Sending response for canceled message failed."));return}}const Ce=Le.get(P);if(Ce!==void 0){Ce.cancel(),on(g);return}else Ve.add(P)}gl(pe,g)}finally{ga()}},"callback");function Al(g){if(er())return;function P(ie,Ne,fe){const Ue={jsonrpc:z,id:g.id};ie instanceof n.ResponseError?Ue.error=ie.toJson():Ue.result=ie===void 0?null:ie,jr(Ue,Ne,fe),I.write(Ue).catch(()=>S.error("Sending response failed."))}s(P,"reply");function D(ie,Ne,fe){const Ue={jsonrpc:z,id:g.id,error:ie.toJson()};jr(Ue,Ne,fe),I.write(Ue).catch(()=>S.error("Sending response failed."))}s(D,"replyError");function F(ie,Ne,fe){ie===void 0&&(ie=null);const Ue={jsonrpc:z,id:g.id,result:ie};jr(Ue,Ne,fe),I.write(Ue).catch(()=>S.error("Sending response failed."))}s(F,"replySuccess"),wl(g);const Ce=Y.get(g.method);let me,De;Ce&&(me=Ce.type,De=Ce.handler);const Ge=Date.now();if(De||M){const ie=g.id??String(Date.now()),Ne=N.is(ve.receiver)?ve.receiver.createCancellationTokenSource(ie):ve.receiver.createCancellationTokenSource(g);g.id!==null&&Ve.has(g.id)&&Ne.cancel(),g.id!==null&&Le.set(ie,Ne);try{let fe;if(De)if(g.params===void 0){if(me!==void 0&&me.numberOfParams!==0){D(new n.ResponseError(n.ErrorCodes.InvalidParams,`Request ${g.method} defines ${me.numberOfParams} params but received none.`),g.method,Ge);return}fe=De(Ne.token)}else if(Array.isArray(g.params)){if(me!==void 0&&me.parameterStructures===n.ParameterStructures.byName){D(new n.ResponseError(n.ErrorCodes.InvalidParams,`Request ${g.method} defines parameters by name but received parameters by position`),g.method,Ge);return}fe=De(...g.params,Ne.token)}else{if(me!==void 0&&me.parameterStructures===n.ParameterStructures.byPosition){D(new n.ResponseError(n.ErrorCodes.InvalidParams,`Request ${g.method} defines parameters by position but received parameters by name`),g.method,Ge);return}fe=De(g.params,Ne.token)}else M&&(fe=M(g.method,g.params,Ne.token));const Ue=fe;fe?Ue.then?Ue.then(lt=>{Le.delete(ie),P(lt,g.method,Ge)},lt=>{Le.delete(ie),lt instanceof n.ResponseError?D(lt,g.method,Ge):lt&&r.string(lt.message)?D(new n.ResponseError(n.ErrorCodes.InternalError,`Request ${g.method} failed with message: ${lt.message}`),g.method,Ge):D(new n.ResponseError(n.ErrorCodes.InternalError,`Request ${g.method} failed unexpectedly without providing any details.`),g.method,Ge)}):(Le.delete(ie),P(fe,g.method,Ge)):(Le.delete(ie),F(fe,g.method,Ge))}catch(fe){Le.delete(ie),fe instanceof n.ResponseError?P(fe,g.method,Ge):fe&&r.string(fe.message)?D(new n.ResponseError(n.ErrorCodes.InternalError,`Request ${g.method} failed with message: ${fe.message}`),g.method,Ge):D(new n.ResponseError(n.ErrorCodes.InternalError,`Request ${g.method} failed unexpectedly without providing any details.`),g.method,Ge)}}else D(new n.ResponseError(n.ErrorCodes.MethodNotFound,`Unhandled method ${g.method}`),g.method,Ge)}s(Al,"handleRequest");function El(g){if(!er())if(g.id===null)g.error?S.error(`Received response message without id: Error is:
10
10
  ${JSON.stringify(g.error,void 0,4)}`):S.error("Received response message without id. No further error information provided.");else{const P=g.id,D=Ee.get(P);if(Il(g,D),D!==void 0){Ee.delete(P);try{if(g.error){const F=g.error;D.reject(new n.ResponseError(F.code,F.message,F.data))}else if(g.result!==void 0)D.resolve(g.result);else throw new Error("Should never happen.")}catch(F){F.message?S.error(`Response handler '${D.method}' failed with message: ${F.message}`):S.error(`Response handler '${D.method}' failed unexpectedly.`)}}}}s(El,"handleResponse");function Cl(g){if(er())return;let P,D;if(g.method===u.type.method){const F=g.params.id;Ve.delete(F),on(g);return}else{const F=Z.get(g.method);F&&(D=F.handler,P=F.type)}if(D||q)try{if(on(g),D)if(g.params===void 0)P!==void 0&&P.numberOfParams!==0&&P.parameterStructures!==n.ParameterStructures.byName&&S.error(`Notification ${g.method} defines ${P.numberOfParams} params but received none.`),D();else if(Array.isArray(g.params)){const F=g.params;g.method===c.type.method&&F.length===2&&l.is(F[0])?D({token:F[0],value:F[1]}):(P!==void 0&&(P.parameterStructures===n.ParameterStructures.byName&&S.error(`Notification ${g.method} defines parameters by name but received parameters by position`),P.numberOfParams!==g.params.length&&S.error(`Notification ${g.method} defines ${P.numberOfParams} params but received ${F.length} arguments`)),D(...F))}else P!==void 0&&P.parameterStructures===n.ParameterStructures.byPosition&&S.error(`Notification ${g.method} defines parameters by position but received parameters by name`),D(g.params);else q&&q(g.method,g.params)}catch(F){F.message?S.error(`Notification handler '${g.method}' failed with message: ${F.message}`):S.error(`Notification handler '${g.method}' failed unexpectedly.`)}else je.fire(g)}s(Cl,"handleNotification");function bl(g){if(!g){S.error("Received empty message.");return}S.error(`Received message which is neither a response nor a notification message:
11
11
  ${JSON.stringify(g,null,4)}`);const P=g;if(r.string(P.id)||r.number(P.id)){const D=P.id,F=Ee.get(D);F&&F.reject(new Error("The received response has neither a result nor an error property."))}}s(bl,"handleInvalidMessage");function xt(g){if(g!=null)switch(ee){case p.Verbose:return JSON.stringify(g,null,4);case p.Compact:return JSON.stringify(g);default:return}}s(xt,"stringifyTrace");function _l(g){if(!(ee===p.Off||!ce))if(Qe===h.Text){let P;(ee===p.Verbose||ee===p.Compact)&&g.params&&(P=`Params: ${xt(g.params)}
12
12
 
@@ -32,7 +32,7 @@ ${JSON.stringify(g,null,4)}`);const P=g;if(r.string(P.id)||r.number(P.id)){const
32
32
 
33
33
  `:g.error===void 0&&(D=`No result returned.
34
34
 
35
- `)),P){const F=g.error?` Request failed: ${g.error.message} (${g.error.code}).`:"";ce.log(`Received response '${P.method} - (${g.id})' in ${Date.now()-P.timerStart}ms.${F}`,D)}else ce.log(`Received response ${g.id} without active response promise.`,D)}else tr("receive-response",g)}s(Il,"traceReceivedResponse");function tr(g,P){if(!ce||ee===p.Off)return;const D={isLSPMessage:!0,type:g,message:P,timestamp:Date.now()};ce.log(D)}s(tr,"logLSPMessage");function Tr(){if(ha())throw new w(T.Closed,"Connection is closed.");if(er())throw new w(T.Disposed,"Connection is disposed.")}s(Tr,"throwIfClosedOrDisposed");function Nl(){if(ma())throw new w(T.AlreadyListening,"Connection is already listening")}s(Nl,"throwIfListening");function Pl(){if(!ma())throw new Error("Call listen() first.")}s(Pl,"throwIfNotListening");function m(g){return g===void 0?null:g}s(m,"undefinedToNull");function le(g){if(g!==null)return g}s(le,"nullToUndefined");function we(g){return g!=null&&!Array.isArray(g)&&typeof g=="object"}s(we,"isNamedParam");function H(g,P){switch(g){case n.ParameterStructures.auto:return we(P)?le(P):[m(P)];case n.ParameterStructures.byName:if(!we(P))throw new Error("Received parameters by name but param is not an object literal.");return le(P);case n.ParameterStructures.byPosition:return[m(P)];default:throw new Error(`Unknown parameter structure ${g.toString()}`)}}s(H,"computeSingleParam");function Ie(g,P){let D;const F=g.numberOfParams;switch(F){case 0:D=void 0;break;case 1:D=H(g.parameterStructures,P[0]);break;default:D=[];for(let Ce=0;Ce<P.length&&Ce<F;Ce++)D.push(m(P[Ce]));if(P.length<F)for(let Ce=P.length;Ce<F;Ce++)D.push(null);break}return D}s(Ie,"computeMessageParams");const Ta={sendNotification:s((g,...P)=>{Tr();let D,F;if(r.string(g)){D=g;const me=P[0];let De=0,Ge=n.ParameterStructures.auto;n.ParameterStructures.is(me)&&(De=1,Ge=me);let ie=P.length;const Ne=ie-De;switch(Ne){case 0:F=void 0;break;case 1:F=H(Ge,P[De]);break;default:if(Ge===n.ParameterStructures.byName)throw new Error(`Received ${Ne} parameters for 'by Name' notification parameter structure.`);F=P.slice(De,ie).map(fe=>m(fe));break}}else{const me=P;D=g.method,F=Ie(g,me)}const Ce={jsonrpc:z,method:D,params:F};return Sl(Ce),I.write(Ce).catch(me=>{throw S.error("Sending notification failed."),me})},"sendNotification"),onNotification:s((g,P)=>{Tr();let D;return r.func(g)?q=g:P&&(r.string(g)?(D=g,Z.set(g,{type:void 0,handler:P})):(D=g.method,Z.set(g.method,{type:g,handler:P}))),{dispose:s(()=>{D!==void 0?Z.delete(D):q=void 0},"dispose")}},"onNotification"),onProgress:s((g,P,D)=>{if(ae.has(P))throw new Error(`Progress handler for token ${P} already registered`);return ae.set(P,D),{dispose:s(()=>{ae.delete(P)},"dispose")}},"onProgress"),sendProgress:s((g,P,D)=>Ta.sendNotification(c.type,{token:P,value:D}),"sendProgress"),onUnhandledProgress:Qt.event,sendRequest:s((g,...P)=>{Tr(),Pl();let D,F,Ce;if(r.string(g)){D=g;const ie=P[0],Ne=P[P.length-1];let fe=0,Ue=n.ParameterStructures.auto;n.ParameterStructures.is(ie)&&(fe=1,Ue=ie);let lt=P.length;o.CancellationToken.is(Ne)&&(lt=lt-1,Ce=Ne);const rr=lt-fe;switch(rr){case 0:F=void 0;break;case 1:F=H(Ue,P[fe]);break;default:if(Ue===n.ParameterStructures.byName)throw new Error(`Received ${rr} parameters for 'by Name' request parameter structure.`);F=P.slice(fe,lt).map(fk=>m(fk));break}}else{const ie=P;D=g.method,F=Ie(g,ie);const Ne=g.numberOfParams;Ce=o.CancellationToken.is(ie[Ne])?ie[Ne]:void 0}const me=L++;let De;Ce&&(De=Ce.onCancellationRequested(()=>{const ie=ve.sender.sendCancellation(Ta,me);return ie===void 0?(S.log(`Received no promise from cancellation strategy when cancelling id ${me}`),Promise.resolve()):ie.catch(()=>{S.log(`Sending cancellation messages for id ${me} failed`)})}));const Ge={jsonrpc:z,id:me,method:D,params:F};return _l(Ge),typeof ve.sender.enableCancellation=="function"&&ve.sender.enableCancellation(Ge),new Promise(async(ie,Ne)=>{const fe=s(rr=>{ie(rr),ve.sender.cleanup(me),De?.dispose()},"resolveWithCleanup"),Ue=s(rr=>{Ne(rr),ve.sender.cleanup(me),De?.dispose()},"rejectWithCleanup"),lt={method:D,timerStart:Date.now(),resolve:fe,reject:Ue};try{await I.write(Ge),Ee.set(me,lt)}catch(rr){throw S.error("Sending request failed."),lt.reject(new n.ResponseError(n.ErrorCodes.MessageWriteError,rr.message?rr.message:"Unknown reason")),rr}})},"sendRequest"),onRequest:s((g,P)=>{Tr();let D=null;return d.is(g)?(D=void 0,M=g):r.string(g)?(D=null,P!==void 0&&(D=g,Y.set(g,{handler:P,type:void 0}))):P!==void 0&&(D=g.method,Y.set(g.method,{type:g,handler:P})),{dispose:s(()=>{D!==null&&(D!==void 0?Y.delete(D):M=void 0)},"dispose")}},"onRequest"),hasPendingResponse:s(()=>Ee.size>0,"hasPendingResponse"),trace:s(async(g,P,D)=>{let F=!1,Ce=h.Text;D!==void 0&&(r.boolean(D)?F=D:(F=D.sendNotification||!1,Ce=D.traceFormat||h.Text)),ee=g,Qe=Ce,ee===p.Off?ce=void 0:ce=P,F&&!ha()&&!er()&&await Ta.sendNotification($.type,{value:p.toString(g)})},"trace"),onError:ge.event,onClose:G.event,onUnhandledNotification:je.event,onDispose:Dt.event,end:s(()=>{I.end()},"end"),dispose:s(()=>{if(er())return;qe=ue.Disposed,Dt.fire(void 0);const g=new n.ResponseError(n.ErrorCodes.PendingResponseRejected,"Pending response rejected since connection got disposed");for(const P of Ee.values())P.reject(g);Ee=new Map,Le=new Map,Ve=new Set,pe=new a.LinkedMap,r.func(I.dispose)&&I.dispose(),r.func(v.dispose)&&v.dispose()},"dispose"),listen:s(()=>{Tr(),Nl(),qe=ue.Listening,v.listen(nc)},"listen"),inspect:s(()=>{(0,e.default)().console.log("inspect")},"inspect")};return Ta.onNotification(C.type,g=>{if(ee===p.Off||!ce)return;const P=ee===p.Verbose||ee===p.Compact;ce.log(g.message,P?g.verbose:void 0)}),Ta.onNotification(c.type,g=>{const P=ae.get(g.token);P?P(g.value):Qt.fire(g)}),Ta}s(ot,"createMessageConnection"),t.createMessageConnection=ot}}),$m=X({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/api.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.ProgressType=t.ProgressToken=t.createMessageConnection=t.NullLogger=t.ConnectionOptions=t.ConnectionStrategy=t.AbstractMessageBuffer=t.WriteableStreamMessageWriter=t.AbstractMessageWriter=t.MessageWriter=t.ReadableStreamMessageReader=t.AbstractMessageReader=t.MessageReader=t.SharedArrayReceiverStrategy=t.SharedArraySenderStrategy=t.CancellationToken=t.CancellationTokenSource=t.Emitter=t.Event=t.Disposable=t.LRUCache=t.Touch=t.LinkedMap=t.ParameterStructures=t.NotificationType9=t.NotificationType8=t.NotificationType7=t.NotificationType6=t.NotificationType5=t.NotificationType4=t.NotificationType3=t.NotificationType2=t.NotificationType1=t.NotificationType0=t.NotificationType=t.ErrorCodes=t.ResponseError=t.RequestType9=t.RequestType8=t.RequestType7=t.RequestType6=t.RequestType5=t.RequestType4=t.RequestType3=t.RequestType2=t.RequestType1=t.RequestType0=t.RequestType=t.Message=t.RAL=void 0,t.MessageStrategy=t.CancellationStrategy=t.CancellationSenderStrategy=t.CancellationReceiverStrategy=t.ConnectionError=t.ConnectionErrors=t.LogTraceNotification=t.SetTraceNotification=t.TraceFormat=t.TraceValues=t.Trace=void 0;var e=G$();Object.defineProperty(t,"Message",{enumerable:!0,get:s(function(){return e.Message},"get")}),Object.defineProperty(t,"RequestType",{enumerable:!0,get:s(function(){return e.RequestType},"get")}),Object.defineProperty(t,"RequestType0",{enumerable:!0,get:s(function(){return e.RequestType0},"get")}),Object.defineProperty(t,"RequestType1",{enumerable:!0,get:s(function(){return e.RequestType1},"get")}),Object.defineProperty(t,"RequestType2",{enumerable:!0,get:s(function(){return e.RequestType2},"get")}),Object.defineProperty(t,"RequestType3",{enumerable:!0,get:s(function(){return e.RequestType3},"get")}),Object.defineProperty(t,"RequestType4",{enumerable:!0,get:s(function(){return e.RequestType4},"get")}),Object.defineProperty(t,"RequestType5",{enumerable:!0,get:s(function(){return e.RequestType5},"get")}),Object.defineProperty(t,"RequestType6",{enumerable:!0,get:s(function(){return e.RequestType6},"get")}),Object.defineProperty(t,"RequestType7",{enumerable:!0,get:s(function(){return e.RequestType7},"get")}),Object.defineProperty(t,"RequestType8",{enumerable:!0,get:s(function(){return e.RequestType8},"get")}),Object.defineProperty(t,"RequestType9",{enumerable:!0,get:s(function(){return e.RequestType9},"get")}),Object.defineProperty(t,"ResponseError",{enumerable:!0,get:s(function(){return e.ResponseError},"get")}),Object.defineProperty(t,"ErrorCodes",{enumerable:!0,get:s(function(){return e.ErrorCodes},"get")}),Object.defineProperty(t,"NotificationType",{enumerable:!0,get:s(function(){return e.NotificationType},"get")}),Object.defineProperty(t,"NotificationType0",{enumerable:!0,get:s(function(){return e.NotificationType0},"get")}),Object.defineProperty(t,"NotificationType1",{enumerable:!0,get:s(function(){return e.NotificationType1},"get")}),Object.defineProperty(t,"NotificationType2",{enumerable:!0,get:s(function(){return e.NotificationType2},"get")}),Object.defineProperty(t,"NotificationType3",{enumerable:!0,get:s(function(){return e.NotificationType3},"get")}),Object.defineProperty(t,"NotificationType4",{enumerable:!0,get:s(function(){return e.NotificationType4},"get")}),Object.defineProperty(t,"NotificationType5",{enumerable:!0,get:s(function(){return e.NotificationType5},"get")}),Object.defineProperty(t,"NotificationType6",{enumerable:!0,get:s(function(){return e.NotificationType6},"get")}),Object.defineProperty(t,"NotificationType7",{enumerable:!0,get:s(function(){return e.NotificationType7},"get")}),Object.defineProperty(t,"NotificationType8",{enumerable:!0,get:s(function(){return e.NotificationType8},"get")}),Object.defineProperty(t,"NotificationType9",{enumerable:!0,get:s(function(){return e.NotificationType9},"get")}),Object.defineProperty(t,"ParameterStructures",{enumerable:!0,get:s(function(){return e.ParameterStructures},"get")});var r=F$();Object.defineProperty(t,"LinkedMap",{enumerable:!0,get:s(function(){return r.LinkedMap},"get")}),Object.defineProperty(t,"LRUCache",{enumerable:!0,get:s(function(){return r.LRUCache},"get")}),Object.defineProperty(t,"Touch",{enumerable:!0,get:s(function(){return r.Touch},"get")});var n=Tk();Object.defineProperty(t,"Disposable",{enumerable:!0,get:s(function(){return n.Disposable},"get")});var a=al();Object.defineProperty(t,"Event",{enumerable:!0,get:s(function(){return a.Event},"get")}),Object.defineProperty(t,"Emitter",{enumerable:!0,get:s(function(){return a.Emitter},"get")});var i=Df();Object.defineProperty(t,"CancellationTokenSource",{enumerable:!0,get:s(function(){return i.CancellationTokenSource},"get")}),Object.defineProperty(t,"CancellationToken",{enumerable:!0,get:s(function(){return i.CancellationToken},"get")});var o=$k();Object.defineProperty(t,"SharedArraySenderStrategy",{enumerable:!0,get:s(function(){return o.SharedArraySenderStrategy},"get")}),Object.defineProperty(t,"SharedArrayReceiverStrategy",{enumerable:!0,get:s(function(){return o.SharedArrayReceiverStrategy},"get")});var u=Rk();Object.defineProperty(t,"MessageReader",{enumerable:!0,get:s(function(){return u.MessageReader},"get")}),Object.defineProperty(t,"AbstractMessageReader",{enumerable:!0,get:s(function(){return u.AbstractMessageReader},"get")}),Object.defineProperty(t,"ReadableStreamMessageReader",{enumerable:!0,get:s(function(){return u.ReadableStreamMessageReader},"get")});var l=Ak();Object.defineProperty(t,"MessageWriter",{enumerable:!0,get:s(function(){return l.MessageWriter},"get")}),Object.defineProperty(t,"AbstractMessageWriter",{enumerable:!0,get:s(function(){return l.AbstractMessageWriter},"get")}),Object.defineProperty(t,"WriteableStreamMessageWriter",{enumerable:!0,get:s(function(){return l.WriteableStreamMessageWriter},"get")});var c=Ek();Object.defineProperty(t,"AbstractMessageBuffer",{enumerable:!0,get:s(function(){return c.AbstractMessageBuffer},"get")});var f=Ck();Object.defineProperty(t,"ConnectionStrategy",{enumerable:!0,get:s(function(){return f.ConnectionStrategy},"get")}),Object.defineProperty(t,"ConnectionOptions",{enumerable:!0,get:s(function(){return f.ConnectionOptions},"get")}),Object.defineProperty(t,"NullLogger",{enumerable:!0,get:s(function(){return f.NullLogger},"get")}),Object.defineProperty(t,"createMessageConnection",{enumerable:!0,get:s(function(){return f.createMessageConnection},"get")}),Object.defineProperty(t,"ProgressToken",{enumerable:!0,get:s(function(){return f.ProgressToken},"get")}),Object.defineProperty(t,"ProgressType",{enumerable:!0,get:s(function(){return f.ProgressType},"get")}),Object.defineProperty(t,"Trace",{enumerable:!0,get:s(function(){return f.Trace},"get")}),Object.defineProperty(t,"TraceValues",{enumerable:!0,get:s(function(){return f.TraceValues},"get")}),Object.defineProperty(t,"TraceFormat",{enumerable:!0,get:s(function(){return f.TraceFormat},"get")}),Object.defineProperty(t,"SetTraceNotification",{enumerable:!0,get:s(function(){return f.SetTraceNotification},"get")}),Object.defineProperty(t,"LogTraceNotification",{enumerable:!0,get:s(function(){return f.LogTraceNotification},"get")}),Object.defineProperty(t,"ConnectionErrors",{enumerable:!0,get:s(function(){return f.ConnectionErrors},"get")}),Object.defineProperty(t,"ConnectionError",{enumerable:!0,get:s(function(){return f.ConnectionError},"get")}),Object.defineProperty(t,"CancellationReceiverStrategy",{enumerable:!0,get:s(function(){return f.CancellationReceiverStrategy},"get")}),Object.defineProperty(t,"CancellationSenderStrategy",{enumerable:!0,get:s(function(){return f.CancellationSenderStrategy},"get")}),Object.defineProperty(t,"CancellationStrategy",{enumerable:!0,get:s(function(){return f.CancellationStrategy},"get")}),Object.defineProperty(t,"MessageStrategy",{enumerable:!0,get:s(function(){return f.MessageStrategy},"get")});var d=Vn();t.RAL=d.default}}),bk=X({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/browser/ril.js"(t){var l,c,f;Object.defineProperty(t,"__esModule",{value:!0});var e=$m(),r=(l=class extends e.AbstractMessageBuffer{constructor(p="utf-8"){super(p),this.asciiDecoder=new TextDecoder("ascii")}emptyBuffer(){return l.emptyBuffer}fromString(p,y){return new TextEncoder().encode(p)}toString(p,y){return y==="ascii"?this.asciiDecoder.decode(p):new TextDecoder(y).decode(p)}asNative(p,y){return y===void 0?p:p.slice(0,y)}allocNative(p){return new Uint8Array(p)}},s(l,"MessageBuffer"),l);r.emptyBuffer=new Uint8Array(0);var n=(c=class{constructor(p){this.socket=p,this._onData=new e.Emitter,this._messageListener=y=>{y.data.arrayBuffer().then($=>{this._onData.fire(new Uint8Array($))},()=>{(0,e.RAL)().console.error("Converting blob to array buffer failed.")})},this.socket.addEventListener("message",this._messageListener)}onClose(p){return this.socket.addEventListener("close",p),e.Disposable.create(()=>this.socket.removeEventListener("close",p))}onError(p){return this.socket.addEventListener("error",p),e.Disposable.create(()=>this.socket.removeEventListener("error",p))}onEnd(p){return this.socket.addEventListener("end",p),e.Disposable.create(()=>this.socket.removeEventListener("end",p))}onData(p){return this._onData.event(p)}},s(c,"ReadableStreamWrapper"),c),a=(f=class{constructor(p){this.socket=p}onClose(p){return this.socket.addEventListener("close",p),e.Disposable.create(()=>this.socket.removeEventListener("close",p))}onError(p){return this.socket.addEventListener("error",p),e.Disposable.create(()=>this.socket.removeEventListener("error",p))}onEnd(p){return this.socket.addEventListener("end",p),e.Disposable.create(()=>this.socket.removeEventListener("end",p))}write(p,y){if(typeof p=="string"){if(y!==void 0&&y!=="utf-8")throw new Error(`In a Browser environments only utf-8 text encoding is supported. But got encoding: ${y}`);this.socket.send(p)}else this.socket.send(p);return Promise.resolve()}end(){this.socket.close()}},s(f,"WritableStreamWrapper"),f),i=new TextEncoder,o=Object.freeze({messageBuffer:Object.freeze({create:s(d=>new r(d),"create")}),applicationJson:Object.freeze({encoder:Object.freeze({name:"application/json",encode:s((d,p)=>{if(p.charset!=="utf-8")throw new Error(`In a Browser environments only utf-8 text encoding is supported. But got encoding: ${p.charset}`);return Promise.resolve(i.encode(JSON.stringify(d,void 0,0)))},"encode")}),decoder:Object.freeze({name:"application/json",decode:s((d,p)=>{if(!(d instanceof Uint8Array))throw new Error("In a Browser environments only Uint8Arrays are supported.");return Promise.resolve(JSON.parse(new TextDecoder(p.charset).decode(d)))},"decode")})}),stream:Object.freeze({asReadableStream:s(d=>new n(d),"asReadableStream"),asWritableStream:s(d=>new a(d),"asWritableStream")}),console,timer:Object.freeze({setTimeout(d,p,...y){const h=setTimeout(d,p,...y);return{dispose:s(()=>clearTimeout(h),"dispose")}},setImmediate(d,...p){const y=setTimeout(d,0,...p);return{dispose:s(()=>clearTimeout(y),"dispose")}},setInterval(d,p,...y){const h=setInterval(d,p,...y);return{dispose:s(()=>clearInterval(h),"dispose")}}})});function u(){return o}s(u,"RIL"),function(d){function p(){e.RAL.install(o)}s(p,"install"),d.install=p}(u||(u={})),t.default=u}}),il=X({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/browser/main.js"(t){var l,c;var e=t&&t.__createBinding||(Object.create?function(f,d,p,y){y===void 0&&(y=p);var h=Object.getOwnPropertyDescriptor(d,p);(!h||("get"in h?!d.__esModule:h.writable||h.configurable))&&(h={enumerable:!0,get:s(function(){return d[p]},"get")}),Object.defineProperty(f,y,h)}:function(f,d,p,y){y===void 0&&(y=p),f[y]=d[p]}),r=t&&t.__exportStar||function(f,d){for(var p in f)p!=="default"&&!Object.prototype.hasOwnProperty.call(d,p)&&e(d,f,p)};Object.defineProperty(t,"__esModule",{value:!0}),t.createMessageConnection=t.BrowserMessageWriter=t.BrowserMessageReader=void 0;var n=bk();n.default.install();var a=$m();r($m(),t);var i=(l=class extends a.AbstractMessageReader{constructor(d){super(),this._onData=new a.Emitter,this._messageListener=p=>{this._onData.fire(p.data)},d.addEventListener("error",p=>this.fireError(p)),d.onmessage=this._messageListener}listen(d){return this._onData.event(d)}},s(l,"BrowserMessageReader"),l);t.BrowserMessageReader=i;var o=(c=class extends a.AbstractMessageWriter{constructor(d){super(),this.port=d,this.errorCount=0,d.addEventListener("error",p=>this.fireError(p))}write(d){try{return this.port.postMessage(d),Promise.resolve()}catch(p){return this.handleError(p,d),Promise.reject(p)}}handleError(d,p){this.errorCount++,this.fireError(d,p,this.errorCount)}end(){}},s(c,"BrowserMessageWriter"),c);t.BrowserMessageWriter=o;function u(f,d,p,y){return p===void 0&&(p=a.NullLogger),a.ConnectionStrategy.is(y)&&(y={connectionStrategy:y}),(0,a.createMessageConnection)(f,d,p,y)}s(u,"createMessageConnection"),t.createMessageConnection=u}}),sv=X({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/browser.js"(t,e){e.exports=il()}}),ke=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/messages.js"(t){var l,c,f,d,p;Object.defineProperty(t,"__esModule",{value:!0}),t.ProtocolNotificationType=t.ProtocolNotificationType0=t.ProtocolRequestType=t.ProtocolRequestType0=t.RegistrationType=t.MessageDirection=void 0;var e=il(),r;(function(y){y.clientToServer="clientToServer",y.serverToClient="serverToClient",y.both="both"})(r||(t.MessageDirection=r={}));var n=(l=class{constructor(h){this.method=h}},s(l,"RegistrationType"),l);t.RegistrationType=n;var a=(c=class extends e.RequestType0{constructor(h){super(h)}},s(c,"ProtocolRequestType0"),c);t.ProtocolRequestType0=a;var i=(f=class extends e.RequestType{constructor(h){super(h,e.ParameterStructures.byName)}},s(f,"ProtocolRequestType"),f);t.ProtocolRequestType=i;var o=(d=class extends e.NotificationType0{constructor(h){super(h)}},s(d,"ProtocolNotificationType0"),d);t.ProtocolNotificationType0=o;var u=(p=class extends e.NotificationType{constructor(h){super(h,e.ParameterStructures.byName)}},s(p,"ProtocolNotificationType"),p);t.ProtocolNotificationType=u}}),Eh=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/utils/is.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.objectLiteral=t.typedArray=t.stringArray=t.array=t.func=t.error=t.number=t.string=t.boolean=void 0;function e(f){return f===!0||f===!1}s(e,"boolean"),t.boolean=e;function r(f){return typeof f=="string"||f instanceof String}s(r,"string"),t.string=r;function n(f){return typeof f=="number"||f instanceof Number}s(n,"number"),t.number=n;function a(f){return f instanceof Error}s(a,"error"),t.error=a;function i(f){return typeof f=="function"}s(i,"func"),t.func=i;function o(f){return Array.isArray(f)}s(o,"array"),t.array=o;function u(f){return o(f)&&f.every(d=>r(d))}s(u,"stringArray"),t.stringArray=u;function l(f,d){return Array.isArray(f)&&f.every(d)}s(l,"typedArray"),t.typedArray=l;function c(f){return f!==null&&typeof f=="object"}s(c,"objectLiteral"),t.objectLiteral=c}}),_k=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.implementation.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.ImplementationRequest=void 0;var e=ke(),r;(function(n){n.method="textDocument/implementation",n.messageDirection=e.MessageDirection.clientToServer,n.type=new e.ProtocolRequestType(n.method)})(r||(t.ImplementationRequest=r={}))}}),Sk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.typeDefinition.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.TypeDefinitionRequest=void 0;var e=ke(),r;(function(n){n.method="textDocument/typeDefinition",n.messageDirection=e.MessageDirection.clientToServer,n.type=new e.ProtocolRequestType(n.method)})(r||(t.TypeDefinitionRequest=r={}))}}),wk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.workspaceFolder.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.DidChangeWorkspaceFoldersNotification=t.WorkspaceFoldersRequest=void 0;var e=ke(),r;(function(a){a.method="workspace/workspaceFolders",a.messageDirection=e.MessageDirection.serverToClient,a.type=new e.ProtocolRequestType0(a.method)})(r||(t.WorkspaceFoldersRequest=r={}));var n;(function(a){a.method="workspace/didChangeWorkspaceFolders",a.messageDirection=e.MessageDirection.clientToServer,a.type=new e.ProtocolNotificationType(a.method)})(n||(t.DidChangeWorkspaceFoldersNotification=n={}))}}),Ik=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.configuration.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.ConfigurationRequest=void 0;var e=ke(),r;(function(n){n.method="workspace/configuration",n.messageDirection=e.MessageDirection.serverToClient,n.type=new e.ProtocolRequestType(n.method)})(r||(t.ConfigurationRequest=r={}))}}),Nk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.colorProvider.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.ColorPresentationRequest=t.DocumentColorRequest=void 0;var e=ke(),r;(function(a){a.method="textDocument/documentColor",a.messageDirection=e.MessageDirection.clientToServer,a.type=new e.ProtocolRequestType(a.method)})(r||(t.DocumentColorRequest=r={}));var n;(function(a){a.method="textDocument/colorPresentation",a.messageDirection=e.MessageDirection.clientToServer,a.type=new e.ProtocolRequestType(a.method)})(n||(t.ColorPresentationRequest=n={}))}}),Pk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.foldingRange.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.FoldingRangeRefreshRequest=t.FoldingRangeRequest=void 0;var e=ke(),r;(function(a){a.method="textDocument/foldingRange",a.messageDirection=e.MessageDirection.clientToServer,a.type=new e.ProtocolRequestType(a.method)})(r||(t.FoldingRangeRequest=r={}));var n;(function(a){a.method="workspace/foldingRange/refresh",a.messageDirection=e.MessageDirection.serverToClient,a.type=new e.ProtocolRequestType0(a.method)})(n||(t.FoldingRangeRefreshRequest=n={}))}}),kk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.declaration.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.DeclarationRequest=void 0;var e=ke(),r;(function(n){n.method="textDocument/declaration",n.messageDirection=e.MessageDirection.clientToServer,n.type=new e.ProtocolRequestType(n.method)})(r||(t.DeclarationRequest=r={}))}}),Ok=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.selectionRange.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.SelectionRangeRequest=void 0;var e=ke(),r;(function(n){n.method="textDocument/selectionRange",n.messageDirection=e.MessageDirection.clientToServer,n.type=new e.ProtocolRequestType(n.method)})(r||(t.SelectionRangeRequest=r={}))}}),Lk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.progress.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.WorkDoneProgressCancelNotification=t.WorkDoneProgressCreateRequest=t.WorkDoneProgress=void 0;var e=il(),r=ke(),n;(function(o){o.type=new e.ProgressType;function u(l){return l===o.type}s(u,"is"),o.is=u})(n||(t.WorkDoneProgress=n={}));var a;(function(o){o.method="window/workDoneProgress/create",o.messageDirection=r.MessageDirection.serverToClient,o.type=new r.ProtocolRequestType(o.method)})(a||(t.WorkDoneProgressCreateRequest=a={}));var i;(function(o){o.method="window/workDoneProgress/cancel",o.messageDirection=r.MessageDirection.clientToServer,o.type=new r.ProtocolNotificationType(o.method)})(i||(t.WorkDoneProgressCancelNotification=i={}))}}),Dk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.callHierarchy.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.CallHierarchyOutgoingCallsRequest=t.CallHierarchyIncomingCallsRequest=t.CallHierarchyPrepareRequest=void 0;var e=ke(),r;(function(i){i.method="textDocument/prepareCallHierarchy",i.messageDirection=e.MessageDirection.clientToServer,i.type=new e.ProtocolRequestType(i.method)})(r||(t.CallHierarchyPrepareRequest=r={}));var n;(function(i){i.method="callHierarchy/incomingCalls",i.messageDirection=e.MessageDirection.clientToServer,i.type=new e.ProtocolRequestType(i.method)})(n||(t.CallHierarchyIncomingCallsRequest=n={}));var a;(function(i){i.method="callHierarchy/outgoingCalls",i.messageDirection=e.MessageDirection.clientToServer,i.type=new e.ProtocolRequestType(i.method)})(a||(t.CallHierarchyOutgoingCallsRequest=a={}))}}),xk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.semanticTokens.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.SemanticTokensRefreshRequest=t.SemanticTokensRangeRequest=t.SemanticTokensDeltaRequest=t.SemanticTokensRequest=t.SemanticTokensRegistrationType=t.TokenFormat=void 0;var e=ke(),r;(function(l){l.Relative="relative"})(r||(t.TokenFormat=r={}));var n;(function(l){l.method="textDocument/semanticTokens",l.type=new e.RegistrationType(l.method)})(n||(t.SemanticTokensRegistrationType=n={}));var a;(function(l){l.method="textDocument/semanticTokens/full",l.messageDirection=e.MessageDirection.clientToServer,l.type=new e.ProtocolRequestType(l.method),l.registrationMethod=n.method})(a||(t.SemanticTokensRequest=a={}));var i;(function(l){l.method="textDocument/semanticTokens/full/delta",l.messageDirection=e.MessageDirection.clientToServer,l.type=new e.ProtocolRequestType(l.method),l.registrationMethod=n.method})(i||(t.SemanticTokensDeltaRequest=i={}));var o;(function(l){l.method="textDocument/semanticTokens/range",l.messageDirection=e.MessageDirection.clientToServer,l.type=new e.ProtocolRequestType(l.method),l.registrationMethod=n.method})(o||(t.SemanticTokensRangeRequest=o={}));var u;(function(l){l.method="workspace/semanticTokens/refresh",l.messageDirection=e.MessageDirection.serverToClient,l.type=new e.ProtocolRequestType0(l.method)})(u||(t.SemanticTokensRefreshRequest=u={}))}}),Mk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.showDocument.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.ShowDocumentRequest=void 0;var e=ke(),r;(function(n){n.method="window/showDocument",n.messageDirection=e.MessageDirection.serverToClient,n.type=new e.ProtocolRequestType(n.method)})(r||(t.ShowDocumentRequest=r={}))}}),Gk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.linkedEditingRange.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.LinkedEditingRangeRequest=void 0;var e=ke(),r;(function(n){n.method="textDocument/linkedEditingRange",n.messageDirection=e.MessageDirection.clientToServer,n.type=new e.ProtocolRequestType(n.method)})(r||(t.LinkedEditingRangeRequest=r={}))}}),Fk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.fileOperations.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.WillDeleteFilesRequest=t.DidDeleteFilesNotification=t.DidRenameFilesNotification=t.WillRenameFilesRequest=t.DidCreateFilesNotification=t.WillCreateFilesRequest=t.FileOperationPatternKind=void 0;var e=ke(),r;(function(c){c.file="file",c.folder="folder"})(r||(t.FileOperationPatternKind=r={}));var n;(function(c){c.method="workspace/willCreateFiles",c.messageDirection=e.MessageDirection.clientToServer,c.type=new e.ProtocolRequestType(c.method)})(n||(t.WillCreateFilesRequest=n={}));var a;(function(c){c.method="workspace/didCreateFiles",c.messageDirection=e.MessageDirection.clientToServer,c.type=new e.ProtocolNotificationType(c.method)})(a||(t.DidCreateFilesNotification=a={}));var i;(function(c){c.method="workspace/willRenameFiles",c.messageDirection=e.MessageDirection.clientToServer,c.type=new e.ProtocolRequestType(c.method)})(i||(t.WillRenameFilesRequest=i={}));var o;(function(c){c.method="workspace/didRenameFiles",c.messageDirection=e.MessageDirection.clientToServer,c.type=new e.ProtocolNotificationType(c.method)})(o||(t.DidRenameFilesNotification=o={}));var u;(function(c){c.method="workspace/didDeleteFiles",c.messageDirection=e.MessageDirection.clientToServer,c.type=new e.ProtocolNotificationType(c.method)})(u||(t.DidDeleteFilesNotification=u={}));var l;(function(c){c.method="workspace/willDeleteFiles",c.messageDirection=e.MessageDirection.clientToServer,c.type=new e.ProtocolRequestType(c.method)})(l||(t.WillDeleteFilesRequest=l={}))}}),zk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.moniker.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.MonikerRequest=t.MonikerKind=t.UniquenessLevel=void 0;var e=ke(),r;(function(i){i.document="document",i.project="project",i.group="group",i.scheme="scheme",i.global="global"})(r||(t.UniquenessLevel=r={}));var n;(function(i){i.$import="import",i.$export="export",i.local="local"})(n||(t.MonikerKind=n={}));var a;(function(i){i.method="textDocument/moniker",i.messageDirection=e.MessageDirection.clientToServer,i.type=new e.ProtocolRequestType(i.method)})(a||(t.MonikerRequest=a={}))}}),jk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.typeHierarchy.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.TypeHierarchySubtypesRequest=t.TypeHierarchySupertypesRequest=t.TypeHierarchyPrepareRequest=void 0;var e=ke(),r;(function(i){i.method="textDocument/prepareTypeHierarchy",i.messageDirection=e.MessageDirection.clientToServer,i.type=new e.ProtocolRequestType(i.method)})(r||(t.TypeHierarchyPrepareRequest=r={}));var n;(function(i){i.method="typeHierarchy/supertypes",i.messageDirection=e.MessageDirection.clientToServer,i.type=new e.ProtocolRequestType(i.method)})(n||(t.TypeHierarchySupertypesRequest=n={}));var a;(function(i){i.method="typeHierarchy/subtypes",i.messageDirection=e.MessageDirection.clientToServer,i.type=new e.ProtocolRequestType(i.method)})(a||(t.TypeHierarchySubtypesRequest=a={}))}}),Bk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.inlineValue.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.InlineValueRefreshRequest=t.InlineValueRequest=void 0;var e=ke(),r;(function(a){a.method="textDocument/inlineValue",a.messageDirection=e.MessageDirection.clientToServer,a.type=new e.ProtocolRequestType(a.method)})(r||(t.InlineValueRequest=r={}));var n;(function(a){a.method="workspace/inlineValue/refresh",a.messageDirection=e.MessageDirection.serverToClient,a.type=new e.ProtocolRequestType0(a.method)})(n||(t.InlineValueRefreshRequest=n={}))}}),Uk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.inlayHint.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.InlayHintRefreshRequest=t.InlayHintResolveRequest=t.InlayHintRequest=void 0;var e=ke(),r;(function(i){i.method="textDocument/inlayHint",i.messageDirection=e.MessageDirection.clientToServer,i.type=new e.ProtocolRequestType(i.method)})(r||(t.InlayHintRequest=r={}));var n;(function(i){i.method="inlayHint/resolve",i.messageDirection=e.MessageDirection.clientToServer,i.type=new e.ProtocolRequestType(i.method)})(n||(t.InlayHintResolveRequest=n={}));var a;(function(i){i.method="workspace/inlayHint/refresh",i.messageDirection=e.MessageDirection.serverToClient,i.type=new e.ProtocolRequestType0(i.method)})(a||(t.InlayHintRefreshRequest=a={}))}}),Kk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.diagnostic.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.DiagnosticRefreshRequest=t.WorkspaceDiagnosticRequest=t.DocumentDiagnosticRequest=t.DocumentDiagnosticReportKind=t.DiagnosticServerCancellationData=void 0;var e=il(),r=Eh(),n=ke(),a;(function(c){function f(d){const p=d;return p&&r.boolean(p.retriggerRequest)}s(f,"is"),c.is=f})(a||(t.DiagnosticServerCancellationData=a={}));var i;(function(c){c.Full="full",c.Unchanged="unchanged"})(i||(t.DocumentDiagnosticReportKind=i={}));var o;(function(c){c.method="textDocument/diagnostic",c.messageDirection=n.MessageDirection.clientToServer,c.type=new n.ProtocolRequestType(c.method),c.partialResult=new e.ProgressType})(o||(t.DocumentDiagnosticRequest=o={}));var u;(function(c){c.method="workspace/diagnostic",c.messageDirection=n.MessageDirection.clientToServer,c.type=new n.ProtocolRequestType(c.method),c.partialResult=new e.ProgressType})(u||(t.WorkspaceDiagnosticRequest=u={}));var l;(function(c){c.method="workspace/diagnostic/refresh",c.messageDirection=n.MessageDirection.serverToClient,c.type=new n.ProtocolRequestType0(c.method)})(l||(t.DiagnosticRefreshRequest=l={}))}}),Wk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.notebook.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.DidCloseNotebookDocumentNotification=t.DidSaveNotebookDocumentNotification=t.DidChangeNotebookDocumentNotification=t.NotebookCellArrayChange=t.DidOpenNotebookDocumentNotification=t.NotebookDocumentSyncRegistrationType=t.NotebookDocument=t.NotebookCell=t.ExecutionSummary=t.NotebookCellKind=void 0;var e=(xu(),Ah(Lf)),r=Eh(),n=ke(),a;(function(h){h.Markup=1,h.Code=2;function $(C){return C===1||C===2}s($,"is"),h.is=$})(a||(t.NotebookCellKind=a={}));var i;(function(h){function $(w,b){const N={executionOrder:w};return(b===!0||b===!1)&&(N.success=b),N}s($,"create"),h.create=$;function C(w){const b=w;return r.objectLiteral(b)&&e.uinteger.is(b.executionOrder)&&(b.success===void 0||r.boolean(b.success))}s(C,"is"),h.is=C;function T(w,b){return w===b?!0:w==null||b===null||b===void 0?!1:w.executionOrder===b.executionOrder&&w.success===b.success}s(T,"equals"),h.equals=T})(i||(t.ExecutionSummary=i={}));var o;(function(h){function $(b,N){return{kind:b,document:N}}s($,"create"),h.create=$;function C(b){const N=b;return r.objectLiteral(N)&&a.is(N.kind)&&e.DocumentUri.is(N.document)&&(N.metadata===void 0||r.objectLiteral(N.metadata))}s(C,"is"),h.is=C;function T(b,N){const B=new Set;return b.document!==N.document&&B.add("document"),b.kind!==N.kind&&B.add("kind"),b.executionSummary!==N.executionSummary&&B.add("executionSummary"),(b.metadata!==void 0||N.metadata!==void 0)&&!w(b.metadata,N.metadata)&&B.add("metadata"),(b.executionSummary!==void 0||N.executionSummary!==void 0)&&!i.equals(b.executionSummary,N.executionSummary)&&B.add("executionSummary"),B}s(T,"diff"),h.diff=T;function w(b,N){if(b===N)return!0;if(b==null||N===null||N===void 0||typeof b!=typeof N||typeof b!="object")return!1;const B=Array.isArray(b),ne=Array.isArray(N);if(B!==ne)return!1;if(B&&ne){if(b.length!==N.length)return!1;for(let J=0;J<b.length;J++)if(!w(b[J],N[J]))return!1}if(r.objectLiteral(b)&&r.objectLiteral(N)){const J=Object.keys(b),he=Object.keys(N);if(J.length!==he.length||(J.sort(),he.sort(),!w(J,he)))return!1;for(let Ae=0;Ae<J.length;Ae++){const ye=J[Ae];if(!w(b[ye],N[ye]))return!1}}return!0}s(w,"equalsMetadata")})(o||(t.NotebookCell=o={}));var u;(function(h){function $(T,w,b,N){return{uri:T,notebookType:w,version:b,cells:N}}s($,"create"),h.create=$;function C(T){const w=T;return r.objectLiteral(w)&&r.string(w.uri)&&e.integer.is(w.version)&&r.typedArray(w.cells,o.is)}s(C,"is"),h.is=C})(u||(t.NotebookDocument=u={}));var l;(function(h){h.method="notebookDocument/sync",h.messageDirection=n.MessageDirection.clientToServer,h.type=new n.RegistrationType(h.method)})(l||(t.NotebookDocumentSyncRegistrationType=l={}));var c;(function(h){h.method="notebookDocument/didOpen",h.messageDirection=n.MessageDirection.clientToServer,h.type=new n.ProtocolNotificationType(h.method),h.registrationMethod=l.method})(c||(t.DidOpenNotebookDocumentNotification=c={}));var f;(function(h){function $(T){const w=T;return r.objectLiteral(w)&&e.uinteger.is(w.start)&&e.uinteger.is(w.deleteCount)&&(w.cells===void 0||r.typedArray(w.cells,o.is))}s($,"is"),h.is=$;function C(T,w,b){const N={start:T,deleteCount:w};return b!==void 0&&(N.cells=b),N}s(C,"create"),h.create=C})(f||(t.NotebookCellArrayChange=f={}));var d;(function(h){h.method="notebookDocument/didChange",h.messageDirection=n.MessageDirection.clientToServer,h.type=new n.ProtocolNotificationType(h.method),h.registrationMethod=l.method})(d||(t.DidChangeNotebookDocumentNotification=d={}));var p;(function(h){h.method="notebookDocument/didSave",h.messageDirection=n.MessageDirection.clientToServer,h.type=new n.ProtocolNotificationType(h.method),h.registrationMethod=l.method})(p||(t.DidSaveNotebookDocumentNotification=p={}));var y;(function(h){h.method="notebookDocument/didClose",h.messageDirection=n.MessageDirection.clientToServer,h.type=new n.ProtocolNotificationType(h.method),h.registrationMethod=l.method})(y||(t.DidCloseNotebookDocumentNotification=y={}))}}),Vk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.inlineCompletion.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.InlineCompletionRequest=void 0;var e=ke(),r;(function(n){n.method="textDocument/inlineCompletion",n.messageDirection=e.MessageDirection.clientToServer,n.type=new e.ProtocolRequestType(n.method)})(r||(t.InlineCompletionRequest=r={}))}}),qk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.WorkspaceSymbolRequest=t.CodeActionResolveRequest=t.CodeActionRequest=t.DocumentSymbolRequest=t.DocumentHighlightRequest=t.ReferencesRequest=t.DefinitionRequest=t.SignatureHelpRequest=t.SignatureHelpTriggerKind=t.HoverRequest=t.CompletionResolveRequest=t.CompletionRequest=t.CompletionTriggerKind=t.PublishDiagnosticsNotification=t.WatchKind=t.RelativePattern=t.FileChangeType=t.DidChangeWatchedFilesNotification=t.WillSaveTextDocumentWaitUntilRequest=t.WillSaveTextDocumentNotification=t.TextDocumentSaveReason=t.DidSaveTextDocumentNotification=t.DidCloseTextDocumentNotification=t.DidChangeTextDocumentNotification=t.TextDocumentContentChangeEvent=t.DidOpenTextDocumentNotification=t.TextDocumentSyncKind=t.TelemetryEventNotification=t.LogMessageNotification=t.ShowMessageRequest=t.ShowMessageNotification=t.MessageType=t.DidChangeConfigurationNotification=t.ExitNotification=t.ShutdownRequest=t.InitializedNotification=t.InitializeErrorCodes=t.InitializeRequest=t.WorkDoneProgressOptions=t.TextDocumentRegistrationOptions=t.StaticRegistrationOptions=t.PositionEncodingKind=t.FailureHandlingKind=t.ResourceOperationKind=t.UnregistrationRequest=t.RegistrationRequest=t.DocumentSelector=t.NotebookCellTextDocumentFilter=t.NotebookDocumentFilter=t.TextDocumentFilter=void 0,t.MonikerRequest=t.MonikerKind=t.UniquenessLevel=t.WillDeleteFilesRequest=t.DidDeleteFilesNotification=t.WillRenameFilesRequest=t.DidRenameFilesNotification=t.WillCreateFilesRequest=t.DidCreateFilesNotification=t.FileOperationPatternKind=t.LinkedEditingRangeRequest=t.ShowDocumentRequest=t.SemanticTokensRegistrationType=t.SemanticTokensRefreshRequest=t.SemanticTokensRangeRequest=t.SemanticTokensDeltaRequest=t.SemanticTokensRequest=t.TokenFormat=t.CallHierarchyPrepareRequest=t.CallHierarchyOutgoingCallsRequest=t.CallHierarchyIncomingCallsRequest=t.WorkDoneProgressCancelNotification=t.WorkDoneProgressCreateRequest=t.WorkDoneProgress=t.SelectionRangeRequest=t.DeclarationRequest=t.FoldingRangeRefreshRequest=t.FoldingRangeRequest=t.ColorPresentationRequest=t.DocumentColorRequest=t.ConfigurationRequest=t.DidChangeWorkspaceFoldersNotification=t.WorkspaceFoldersRequest=t.TypeDefinitionRequest=t.ImplementationRequest=t.ApplyWorkspaceEditRequest=t.ExecuteCommandRequest=t.PrepareRenameRequest=t.RenameRequest=t.PrepareSupportDefaultBehavior=t.DocumentOnTypeFormattingRequest=t.DocumentRangesFormattingRequest=t.DocumentRangeFormattingRequest=t.DocumentFormattingRequest=t.DocumentLinkResolveRequest=t.DocumentLinkRequest=t.CodeLensRefreshRequest=t.CodeLensResolveRequest=t.CodeLensRequest=t.WorkspaceSymbolResolveRequest=void 0,t.InlineCompletionRequest=t.DidCloseNotebookDocumentNotification=t.DidSaveNotebookDocumentNotification=t.DidChangeNotebookDocumentNotification=t.NotebookCellArrayChange=t.DidOpenNotebookDocumentNotification=t.NotebookDocumentSyncRegistrationType=t.NotebookDocument=t.NotebookCell=t.ExecutionSummary=t.NotebookCellKind=t.DiagnosticRefreshRequest=t.WorkspaceDiagnosticRequest=t.DocumentDiagnosticRequest=t.DocumentDiagnosticReportKind=t.DiagnosticServerCancellationData=t.InlayHintRefreshRequest=t.InlayHintResolveRequest=t.InlayHintRequest=t.InlineValueRefreshRequest=t.InlineValueRequest=t.TypeHierarchySupertypesRequest=t.TypeHierarchySubtypesRequest=t.TypeHierarchyPrepareRequest=void 0;var e=ke(),r=(xu(),Ah(Lf)),n=Eh(),a=_k();Object.defineProperty(t,"ImplementationRequest",{enumerable:!0,get:s(function(){return a.ImplementationRequest},"get")});var i=Sk();Object.defineProperty(t,"TypeDefinitionRequest",{enumerable:!0,get:s(function(){return i.TypeDefinitionRequest},"get")});var o=wk();Object.defineProperty(t,"WorkspaceFoldersRequest",{enumerable:!0,get:s(function(){return o.WorkspaceFoldersRequest},"get")}),Object.defineProperty(t,"DidChangeWorkspaceFoldersNotification",{enumerable:!0,get:s(function(){return o.DidChangeWorkspaceFoldersNotification},"get")});var u=Ik();Object.defineProperty(t,"ConfigurationRequest",{enumerable:!0,get:s(function(){return u.ConfigurationRequest},"get")});var l=Nk();Object.defineProperty(t,"DocumentColorRequest",{enumerable:!0,get:s(function(){return l.DocumentColorRequest},"get")}),Object.defineProperty(t,"ColorPresentationRequest",{enumerable:!0,get:s(function(){return l.ColorPresentationRequest},"get")});var c=Pk();Object.defineProperty(t,"FoldingRangeRequest",{enumerable:!0,get:s(function(){return c.FoldingRangeRequest},"get")}),Object.defineProperty(t,"FoldingRangeRefreshRequest",{enumerable:!0,get:s(function(){return c.FoldingRangeRefreshRequest},"get")});var f=kk();Object.defineProperty(t,"DeclarationRequest",{enumerable:!0,get:s(function(){return f.DeclarationRequest},"get")});var d=Ok();Object.defineProperty(t,"SelectionRangeRequest",{enumerable:!0,get:s(function(){return d.SelectionRangeRequest},"get")});var p=Lk();Object.defineProperty(t,"WorkDoneProgress",{enumerable:!0,get:s(function(){return p.WorkDoneProgress},"get")}),Object.defineProperty(t,"WorkDoneProgressCreateRequest",{enumerable:!0,get:s(function(){return p.WorkDoneProgressCreateRequest},"get")}),Object.defineProperty(t,"WorkDoneProgressCancelNotification",{enumerable:!0,get:s(function(){return p.WorkDoneProgressCancelNotification},"get")});var y=Dk();Object.defineProperty(t,"CallHierarchyIncomingCallsRequest",{enumerable:!0,get:s(function(){return y.CallHierarchyIncomingCallsRequest},"get")}),Object.defineProperty(t,"CallHierarchyOutgoingCallsRequest",{enumerable:!0,get:s(function(){return y.CallHierarchyOutgoingCallsRequest},"get")}),Object.defineProperty(t,"CallHierarchyPrepareRequest",{enumerable:!0,get:s(function(){return y.CallHierarchyPrepareRequest},"get")});var h=xk();Object.defineProperty(t,"TokenFormat",{enumerable:!0,get:s(function(){return h.TokenFormat},"get")}),Object.defineProperty(t,"SemanticTokensRequest",{enumerable:!0,get:s(function(){return h.SemanticTokensRequest},"get")}),Object.defineProperty(t,"SemanticTokensDeltaRequest",{enumerable:!0,get:s(function(){return h.SemanticTokensDeltaRequest},"get")}),Object.defineProperty(t,"SemanticTokensRangeRequest",{enumerable:!0,get:s(function(){return h.SemanticTokensRangeRequest},"get")}),Object.defineProperty(t,"SemanticTokensRefreshRequest",{enumerable:!0,get:s(function(){return h.SemanticTokensRefreshRequest},"get")}),Object.defineProperty(t,"SemanticTokensRegistrationType",{enumerable:!0,get:s(function(){return h.SemanticTokensRegistrationType},"get")});var $=Mk();Object.defineProperty(t,"ShowDocumentRequest",{enumerable:!0,get:s(function(){return $.ShowDocumentRequest},"get")});var C=Gk();Object.defineProperty(t,"LinkedEditingRangeRequest",{enumerable:!0,get:s(function(){return C.LinkedEditingRangeRequest},"get")});var T=Fk();Object.defineProperty(t,"FileOperationPatternKind",{enumerable:!0,get:s(function(){return T.FileOperationPatternKind},"get")}),Object.defineProperty(t,"DidCreateFilesNotification",{enumerable:!0,get:s(function(){return T.DidCreateFilesNotification},"get")}),Object.defineProperty(t,"WillCreateFilesRequest",{enumerable:!0,get:s(function(){return T.WillCreateFilesRequest},"get")}),Object.defineProperty(t,"DidRenameFilesNotification",{enumerable:!0,get:s(function(){return T.DidRenameFilesNotification},"get")}),Object.defineProperty(t,"WillRenameFilesRequest",{enumerable:!0,get:s(function(){return T.WillRenameFilesRequest},"get")}),Object.defineProperty(t,"DidDeleteFilesNotification",{enumerable:!0,get:s(function(){return T.DidDeleteFilesNotification},"get")}),Object.defineProperty(t,"WillDeleteFilesRequest",{enumerable:!0,get:s(function(){return T.WillDeleteFilesRequest},"get")});var w=zk();Object.defineProperty(t,"UniquenessLevel",{enumerable:!0,get:s(function(){return w.UniquenessLevel},"get")}),Object.defineProperty(t,"MonikerKind",{enumerable:!0,get:s(function(){return w.MonikerKind},"get")}),Object.defineProperty(t,"MonikerRequest",{enumerable:!0,get:s(function(){return w.MonikerRequest},"get")});var b=jk();Object.defineProperty(t,"TypeHierarchyPrepareRequest",{enumerable:!0,get:s(function(){return b.TypeHierarchyPrepareRequest},"get")}),Object.defineProperty(t,"TypeHierarchySubtypesRequest",{enumerable:!0,get:s(function(){return b.TypeHierarchySubtypesRequest},"get")}),Object.defineProperty(t,"TypeHierarchySupertypesRequest",{enumerable:!0,get:s(function(){return b.TypeHierarchySupertypesRequest},"get")});var N=Bk();Object.defineProperty(t,"InlineValueRequest",{enumerable:!0,get:s(function(){return N.InlineValueRequest},"get")}),Object.defineProperty(t,"InlineValueRefreshRequest",{enumerable:!0,get:s(function(){return N.InlineValueRefreshRequest},"get")});var B=Uk();Object.defineProperty(t,"InlayHintRequest",{enumerable:!0,get:s(function(){return B.InlayHintRequest},"get")}),Object.defineProperty(t,"InlayHintResolveRequest",{enumerable:!0,get:s(function(){return B.InlayHintResolveRequest},"get")}),Object.defineProperty(t,"InlayHintRefreshRequest",{enumerable:!0,get:s(function(){return B.InlayHintRefreshRequest},"get")});var ne=Kk();Object.defineProperty(t,"DiagnosticServerCancellationData",{enumerable:!0,get:s(function(){return ne.DiagnosticServerCancellationData},"get")}),Object.defineProperty(t,"DocumentDiagnosticReportKind",{enumerable:!0,get:s(function(){return ne.DocumentDiagnosticReportKind},"get")}),Object.defineProperty(t,"DocumentDiagnosticRequest",{enumerable:!0,get:s(function(){return ne.DocumentDiagnosticRequest},"get")}),Object.defineProperty(t,"WorkspaceDiagnosticRequest",{enumerable:!0,get:s(function(){return ne.WorkspaceDiagnosticRequest},"get")}),Object.defineProperty(t,"DiagnosticRefreshRequest",{enumerable:!0,get:s(function(){return ne.DiagnosticRefreshRequest},"get")});var J=Wk();Object.defineProperty(t,"NotebookCellKind",{enumerable:!0,get:s(function(){return J.NotebookCellKind},"get")}),Object.defineProperty(t,"ExecutionSummary",{enumerable:!0,get:s(function(){return J.ExecutionSummary},"get")}),Object.defineProperty(t,"NotebookCell",{enumerable:!0,get:s(function(){return J.NotebookCell},"get")}),Object.defineProperty(t,"NotebookDocument",{enumerable:!0,get:s(function(){return J.NotebookDocument},"get")}),Object.defineProperty(t,"NotebookDocumentSyncRegistrationType",{enumerable:!0,get:s(function(){return J.NotebookDocumentSyncRegistrationType},"get")}),Object.defineProperty(t,"DidOpenNotebookDocumentNotification",{enumerable:!0,get:s(function(){return J.DidOpenNotebookDocumentNotification},"get")}),Object.defineProperty(t,"NotebookCellArrayChange",{enumerable:!0,get:s(function(){return J.NotebookCellArrayChange},"get")}),Object.defineProperty(t,"DidChangeNotebookDocumentNotification",{enumerable:!0,get:s(function(){return J.DidChangeNotebookDocumentNotification},"get")}),Object.defineProperty(t,"DidSaveNotebookDocumentNotification",{enumerable:!0,get:s(function(){return J.DidSaveNotebookDocumentNotification},"get")}),Object.defineProperty(t,"DidCloseNotebookDocumentNotification",{enumerable:!0,get:s(function(){return J.DidCloseNotebookDocumentNotification},"get")});var he=Vk();Object.defineProperty(t,"InlineCompletionRequest",{enumerable:!0,get:s(function(){return he.InlineCompletionRequest},"get")});var Ae;(function(m){function le(we){const H=we;return n.string(H)||n.string(H.language)||n.string(H.scheme)||n.string(H.pattern)}s(le,"is"),m.is=le})(Ae||(t.TextDocumentFilter=Ae={}));var ye;(function(m){function le(we){const H=we;return n.objectLiteral(H)&&(n.string(H.notebookType)||n.string(H.scheme)||n.string(H.pattern))}s(le,"is"),m.is=le})(ye||(t.NotebookDocumentFilter=ye={}));var ue;(function(m){function le(we){const H=we;return n.objectLiteral(H)&&(n.string(H.notebook)||ye.is(H.notebook))&&(H.language===void 0||n.string(H.language))}s(le,"is"),m.is=le})(ue||(t.NotebookCellTextDocumentFilter=ue={}));var ot;(function(m){function le(we){if(!Array.isArray(we))return!1;for(let H of we)if(!n.string(H)&&!Ae.is(H)&&!ue.is(H))return!1;return!0}s(le,"is"),m.is=le})(ot||(t.DocumentSelector=ot={}));var k;(function(m){m.method="client/registerCapability",m.messageDirection=e.MessageDirection.serverToClient,m.type=new e.ProtocolRequestType(m.method)})(k||(t.RegistrationRequest=k={}));var _;(function(m){m.method="client/unregisterCapability",m.messageDirection=e.MessageDirection.serverToClient,m.type=new e.ProtocolRequestType(m.method)})(_||(t.UnregistrationRequest=_={}));var v;(function(m){m.Create="create",m.Rename="rename",m.Delete="delete"})(v||(t.ResourceOperationKind=v={}));var I;(function(m){m.Abort="abort",m.Transactional="transactional",m.TextOnlyTransactional="textOnlyTransactional",m.Undo="undo"})(I||(t.FailureHandlingKind=I={}));var R;(function(m){m.UTF8="utf-8",m.UTF16="utf-16",m.UTF32="utf-32"})(R||(t.PositionEncodingKind=R={}));var A;(function(m){function le(we){const H=we;return H&&n.string(H.id)&&H.id.length>0}s(le,"hasId"),m.hasId=le})(A||(t.StaticRegistrationOptions=A={}));var S;(function(m){function le(we){const H=we;return H&&(H.documentSelector===null||ot.is(H.documentSelector))}s(le,"is"),m.is=le})(S||(t.TextDocumentRegistrationOptions=S={}));var L;(function(m){function le(H){const Ie=H;return n.objectLiteral(Ie)&&(Ie.workDoneProgress===void 0||n.boolean(Ie.workDoneProgress))}s(le,"is"),m.is=le;function we(H){const Ie=H;return Ie&&n.boolean(Ie.workDoneProgress)}s(we,"hasWorkDoneProgress"),m.hasWorkDoneProgress=we})(L||(t.WorkDoneProgressOptions=L={}));var x;(function(m){m.method="initialize",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(x||(t.InitializeRequest=x={}));var O;(function(m){m.unknownProtocolVersion=1})(O||(t.InitializeErrorCodes=O={}));var z;(function(m){m.method="initialized",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolNotificationType(m.method)})(z||(t.InitializedNotification=z={}));var M;(function(m){m.method="shutdown",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType0(m.method)})(M||(t.ShutdownRequest=M={}));var Y;(function(m){m.method="exit",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolNotificationType0(m.method)})(Y||(t.ExitNotification=Y={}));var q;(function(m){m.method="workspace/didChangeConfiguration",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolNotificationType(m.method)})(q||(t.DidChangeConfigurationNotification=q={}));var Z;(function(m){m.Error=1,m.Warning=2,m.Info=3,m.Log=4,m.Debug=5})(Z||(t.MessageType=Z={}));var ae;(function(m){m.method="window/showMessage",m.messageDirection=e.MessageDirection.serverToClient,m.type=new e.ProtocolNotificationType(m.method)})(ae||(t.ShowMessageNotification=ae={}));var Oe;(function(m){m.method="window/showMessageRequest",m.messageDirection=e.MessageDirection.serverToClient,m.type=new e.ProtocolRequestType(m.method)})(Oe||(t.ShowMessageRequest=Oe={}));var pe;(function(m){m.method="window/logMessage",m.messageDirection=e.MessageDirection.serverToClient,m.type=new e.ProtocolNotificationType(m.method)})(pe||(t.LogMessageNotification=pe={}));var Ee;(function(m){m.method="telemetry/event",m.messageDirection=e.MessageDirection.serverToClient,m.type=new e.ProtocolNotificationType(m.method)})(Ee||(t.TelemetryEventNotification=Ee={}));var Ve;(function(m){m.None=0,m.Full=1,m.Incremental=2})(Ve||(t.TextDocumentSyncKind=Ve={}));var Le;(function(m){m.method="textDocument/didOpen",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolNotificationType(m.method)})(Le||(t.DidOpenTextDocumentNotification=Le={}));var ee;(function(m){function le(H){let Ie=H;return Ie!=null&&typeof Ie.text=="string"&&Ie.range!==void 0&&(Ie.rangeLength===void 0||typeof Ie.rangeLength=="number")}s(le,"isIncremental"),m.isIncremental=le;function we(H){let Ie=H;return Ie!=null&&typeof Ie.text=="string"&&Ie.range===void 0&&Ie.rangeLength===void 0}s(we,"isFull"),m.isFull=we})(ee||(t.TextDocumentContentChangeEvent=ee={}));var Qe;(function(m){m.method="textDocument/didChange",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolNotificationType(m.method)})(Qe||(t.DidChangeTextDocumentNotification=Qe={}));var ce;(function(m){m.method="textDocument/didClose",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolNotificationType(m.method)})(ce||(t.DidCloseTextDocumentNotification=ce={}));var qe;(function(m){m.method="textDocument/didSave",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolNotificationType(m.method)})(qe||(t.DidSaveTextDocumentNotification=qe={}));var ge;(function(m){m.Manual=1,m.AfterDelay=2,m.FocusOut=3})(ge||(t.TextDocumentSaveReason=ge={}));var G;(function(m){m.method="textDocument/willSave",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolNotificationType(m.method)})(G||(t.WillSaveTextDocumentNotification=G={}));var je;(function(m){m.method="textDocument/willSaveWaitUntil",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(je||(t.WillSaveTextDocumentWaitUntilRequest=je={}));var Qt;(function(m){m.method="workspace/didChangeWatchedFiles",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolNotificationType(m.method)})(Qt||(t.DidChangeWatchedFilesNotification=Qt={}));var Dt;(function(m){m.Created=1,m.Changed=2,m.Deleted=3})(Dt||(t.FileChangeType=Dt={}));var ve;(function(m){function le(we){const H=we;return n.objectLiteral(H)&&(r.URI.is(H.baseUri)||r.WorkspaceFolder.is(H.baseUri))&&n.string(H.pattern)}s(le,"is"),m.is=le})(ve||(t.RelativePattern=ve={}));var pa;(function(m){m.Create=1,m.Change=2,m.Delete=4})(pa||(t.WatchKind=pa={}));var hl;(function(m){m.method="textDocument/publishDiagnostics",m.messageDirection=e.MessageDirection.serverToClient,m.type=new e.ProtocolNotificationType(m.method)})(hl||(t.PublishDiagnosticsNotification=hl={}));var yl;(function(m){m.Invoked=1,m.TriggerCharacter=2,m.TriggerForIncompleteCompletions=3})(yl||(t.CompletionTriggerKind=yl={}));var gl;(function(m){m.method="textDocument/completion",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(gl||(t.CompletionRequest=gl={}));var vl;(function(m){m.method="completionItem/resolve",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(vl||(t.CompletionResolveRequest=vl={}));var ma;(function(m){m.method="textDocument/hover",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(ma||(t.HoverRequest=ma={}));var ha;(function(m){m.Invoked=1,m.TriggerCharacter=2,m.ContentChange=3})(ha||(t.SignatureHelpTriggerKind=ha={}));var er;(function(m){m.method="textDocument/signatureHelp",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(er||(t.SignatureHelpRequest=er={}));var ya;(function(m){m.method="textDocument/definition",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(ya||(t.DefinitionRequest=ya={}));var Tl;(function(m){m.method="textDocument/references",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(Tl||(t.ReferencesRequest=Tl={}));var $l;(function(m){m.method="textDocument/documentHighlight",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})($l||(t.DocumentHighlightRequest=$l={}));var ga;(function(m){m.method="textDocument/documentSymbol",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(ga||(t.DocumentSymbolRequest=ga={}));var va;(function(m){m.method="textDocument/codeAction",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(va||(t.CodeActionRequest=va={}));var Rl;(function(m){m.method="codeAction/resolve",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(Rl||(t.CodeActionResolveRequest=Rl={}));var nc;(function(m){m.method="workspace/symbol",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(nc||(t.WorkspaceSymbolRequest=nc={}));var Al;(function(m){m.method="workspaceSymbol/resolve",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(Al||(t.WorkspaceSymbolResolveRequest=Al={}));var El;(function(m){m.method="textDocument/codeLens",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(El||(t.CodeLensRequest=El={}));var Cl;(function(m){m.method="codeLens/resolve",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(Cl||(t.CodeLensResolveRequest=Cl={}));var bl;(function(m){m.method="workspace/codeLens/refresh",m.messageDirection=e.MessageDirection.serverToClient,m.type=new e.ProtocolRequestType0(m.method)})(bl||(t.CodeLensRefreshRequest=bl={}));var xt;(function(m){m.method="textDocument/documentLink",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(xt||(t.DocumentLinkRequest=xt={}));var _l;(function(m){m.method="documentLink/resolve",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(_l||(t.DocumentLinkResolveRequest=_l={}));var Sl;(function(m){m.method="textDocument/formatting",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(Sl||(t.DocumentFormattingRequest=Sl={}));var jr;(function(m){m.method="textDocument/rangeFormatting",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(jr||(t.DocumentRangeFormattingRequest=jr={}));var wl;(function(m){m.method="textDocument/rangesFormatting",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(wl||(t.DocumentRangesFormattingRequest=wl={}));var on;(function(m){m.method="textDocument/onTypeFormatting",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(on||(t.DocumentOnTypeFormattingRequest=on={}));var Il;(function(m){m.Identifier=1})(Il||(t.PrepareSupportDefaultBehavior=Il={}));var tr;(function(m){m.method="textDocument/rename",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(tr||(t.RenameRequest=tr={}));var Tr;(function(m){m.method="textDocument/prepareRename",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(Tr||(t.PrepareRenameRequest=Tr={}));var Nl;(function(m){m.method="workspace/executeCommand",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(Nl||(t.ExecuteCommandRequest=Nl={}));var Pl;(function(m){m.method="workspace/applyEdit",m.messageDirection=e.MessageDirection.serverToClient,m.type=new e.ProtocolRequestType("workspace/applyEdit")})(Pl||(t.ApplyWorkspaceEditRequest=Pl={}))}}),Hk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/connection.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.createProtocolConnection=void 0;var e=il();function r(n,a,i,o){return e.ConnectionStrategy.is(o)&&(o={connectionStrategy:o}),(0,e.createMessageConnection)(n,a,i,o)}s(r,"createProtocolConnection"),t.createProtocolConnection=r}}),Yk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/api.js"(t){var e=t&&t.__createBinding||(Object.create?function(i,o,u,l){l===void 0&&(l=u);var c=Object.getOwnPropertyDescriptor(o,u);(!c||("get"in c?!o.__esModule:c.writable||c.configurable))&&(c={enumerable:!0,get:s(function(){return o[u]},"get")}),Object.defineProperty(i,l,c)}:function(i,o,u,l){l===void 0&&(l=u),i[l]=o[u]}),r=t&&t.__exportStar||function(i,o){for(var u in i)u!=="default"&&!Object.prototype.hasOwnProperty.call(o,u)&&e(o,i,u)};Object.defineProperty(t,"__esModule",{value:!0}),t.LSPErrorCodes=t.createProtocolConnection=void 0,r(il(),t),r((xu(),Ah(Lf)),t),r(ke(),t),r(qk(),t);var n=Hk();Object.defineProperty(t,"createProtocolConnection",{enumerable:!0,get:s(function(){return n.createProtocolConnection},"get")});var a;(function(i){i.lspReservedErrorRangeStart=-32899,i.RequestFailed=-32803,i.ServerCancelled=-32802,i.ContentModified=-32801,i.RequestCancelled=-32800,i.lspReservedErrorRangeEnd=-32800})(a||(t.LSPErrorCodes=a={}))}}),Xk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/browser/main.js"(t){var e=t&&t.__createBinding||(Object.create?function(i,o,u,l){l===void 0&&(l=u);var c=Object.getOwnPropertyDescriptor(o,u);(!c||("get"in c?!o.__esModule:c.writable||c.configurable))&&(c={enumerable:!0,get:s(function(){return o[u]},"get")}),Object.defineProperty(i,l,c)}:function(i,o,u,l){l===void 0&&(l=u),i[l]=o[u]}),r=t&&t.__exportStar||function(i,o){for(var u in i)u!=="default"&&!Object.prototype.hasOwnProperty.call(o,u)&&e(o,i,u)};Object.defineProperty(t,"__esModule",{value:!0}),t.createProtocolConnection=void 0;var n=sv();r(sv(),t),r(Yk(),t);function a(i,o,u,l){return(0,n.createMessageConnection)(i,o,u,l)}s(a,"createProtocolConnection"),t.createProtocolConnection=a}}),j$={};tn(j$,{AbstractAstReflection:()=>_h,AbstractCstNode:()=>wg,AbstractLangiumParser:()=>Ng,AbstractParserErrorMessageProvider:()=>wN,AbstractThreadedAsyncParser:()=>$B,AstUtils:()=>Sh,BiMap:()=>If,Cancellation:()=>$e,CompositeCstNodeImpl:()=>Pd,ContextCache:()=>Gd,CstNodeBuilder:()=>bN,CstUtils:()=>Ch,DEFAULT_TOKENIZE_OPTIONS:()=>Hg,DONE_RESULT:()=>ct,DatatypeSymbol:()=>bf,DefaultAstNodeDescriptionProvider:()=>aP,DefaultAstNodeLocator:()=>sP,DefaultAsyncParser:()=>CP,DefaultCommentProvider:()=>EP,DefaultConfigurationProvider:()=>oP,DefaultDocumentBuilder:()=>lP,DefaultDocumentValidator:()=>nP,DefaultHydrator:()=>_P,DefaultIndexManager:()=>uP,DefaultJsonSerializer:()=>QN,DefaultLangiumDocumentFactory:()=>KN,DefaultLangiumDocuments:()=>WN,DefaultLangiumProfiler:()=>bB,DefaultLexer:()=>Yg,DefaultLexerErrorMessageProvider:()=>fP,DefaultLinker:()=>VN,DefaultNameProvider:()=>qN,DefaultReferenceDescriptionProvider:()=>iP,DefaultReferences:()=>HN,DefaultScopeComputation:()=>YN,DefaultScopeProvider:()=>ZN,DefaultServiceRegistry:()=>eP,DefaultTokenBuilder:()=>Ld,DefaultValueConverter:()=>Mg,DefaultWorkspaceLock:()=>bP,DefaultWorkspaceManager:()=>cP,Deferred:()=>Dr,Disposable:()=>Fn,DisposableCache:()=>Md,DocumentCache:()=>JN,DocumentState:()=>Q,DocumentValidator:()=>Mt,EMPTY_SCOPE:()=>yB,EMPTY_STREAM:()=>qo,EmptyFileSystem:()=>st,EmptyFileSystemProvider:()=>IP,ErrorWithLocation:()=>Kf,GrammarAST:()=>K$,GrammarUtils:()=>ny,IndentationAwareLexer:()=>AB,IndentationAwareTokenBuilder:()=>wP,JSDocDocumentationProvider:()=>AP,LangiumCompletionParser:()=>IN,LangiumParser:()=>SN,LangiumParserErrorMessageProvider:()=>Pg,LeafCstNodeImpl:()=>Cf,LexingMode:()=>Mn,MapScope:()=>hB,Module:()=>eh,MultiMap:()=>xr,MultiMapScope:()=>XN,OperationCancelled:()=>cr,ParserWorker:()=>RB,ProfilingTask:()=>PP,Reduction:()=>Tu,RefResolving:()=>vn,RegExpUtils:()=>iy,RootCstNodeImpl:()=>Ig,SimpleCache:()=>Ug,StreamImpl:()=>ur,StreamScope:()=>Xm,TextDocument:()=>Sf,TreeStreamImpl:()=>Ho,URI:()=>It,UriTrie:()=>jg,UriUtils:()=>dt,VALIDATE_EACH_NODE:()=>rP,ValidationCategory:()=>Nf,ValidationRegistry:()=>tP,ValueConverter:()=>or,WorkspaceCache:()=>Kg,assertCondition:()=>ay,assertUnreachable:()=>rn,createCompletionParser:()=>Lg,createDefaultCoreModule:()=>Xe,createDefaultSharedCoreModule:()=>Je,createGrammarConfig:()=>Ey,createLangiumParser:()=>Dg,createParser:()=>kd,delayNextTick:()=>Dd,diagnosticData:()=>xn,eagerLoad:()=>rv,getDiagnosticRange:()=>Vg,indentationBuilderDefaultOptions:()=>rh,inject:()=>re,interruptAndCheck:()=>Ye,isAstNode:()=>Be,isAstNodeDescription:()=>bh,isAstNodeWithComment:()=>Wg,isCompositeCstNode:()=>Sr,isIMultiModeLexerDefinition:()=>jd,isJSDoc:()=>Jg,isLeafCstNode:()=>qn,isLinkingError:()=>An,isMultiReference:()=>fr,isNamed:()=>Bg,isOperationCancelled:()=>da,isReference:()=>ft,isRootCstNode:()=>xf,isTokenTypeArray:()=>zd,isTokenTypeDictionary:()=>Pf,loadGrammarFromJson:()=>Ze,parseJSDoc:()=>Xg,prepareLangiumParser:()=>xg,setInterruptionPeriod:()=>Gg,startCancelableOperation:()=>xd,stream:()=>de,toDiagnosticData:()=>qg,toDiagnosticSeverity:()=>gu});var Ch={};tn(Ch,{DefaultNameRegexp:()=>Zh,RangeComparison:()=>lr,compareRange:()=>Xh,findCommentNode:()=>Qh,findDeclarationNodeAtOffset:()=>uR,findLeafNodeAtOffset:()=>Uf,findLeafNodeBeforeOffset:()=>ey,flattenCst:()=>lR,getDatatypeNode:()=>oR,getInteriorNodes:()=>dR,getNextNode:()=>cR,getPreviousNode:()=>ry,getStartlineNode:()=>fR,inRange:()=>Jh,isChildNode:()=>Yh,isCommentNode:()=>lf,streamCst:()=>Zo,toDocumentSegment:()=>Qo,tokenToRange:()=>$u});function Be(t){return typeof t=="object"&&t!==null&&typeof t.$type=="string"}s(Be,"isAstNode");function ft(t){return typeof t=="object"&&t!==null&&typeof t.$refText=="string"&&"ref"in t}s(ft,"isReference");function fr(t){return typeof t=="object"&&t!==null&&typeof t.$refText=="string"&&"items"in t}s(fr,"isMultiReference");function bh(t){return typeof t=="object"&&t!==null&&typeof t.name=="string"&&typeof t.type=="string"&&typeof t.path=="string"}s(bh,"isAstNodeDescription");function An(t){return typeof t=="object"&&t!==null&&typeof t.info=="object"&&typeof t.message=="string"}s(An,"isLinkingError");var Qa,_h=(Qa=class{constructor(){this.subtypes={},this.allSubtypes={}}getAllTypes(){return Object.keys(this.types)}getReferenceType(e){const r=this.types[e.container.$type];if(!r)throw new Error(`Type ${e.container.$type||"undefined"} not found.`);const n=r.properties[e.property]?.referenceType;if(!n)throw new Error(`Property ${e.property||"undefined"} of type ${e.container.$type} is not a reference.`);return n}getTypeMetaData(e){const r=this.types[e];return r||{name:e,properties:{},superTypes:[]}}isInstance(e,r){return Be(e)&&this.isSubtype(e.$type,r)}isSubtype(e,r){if(e===r)return!0;let n=this.subtypes[e];n||(n=this.subtypes[e]={});const a=n[r];if(a!==void 0)return a;{const i=this.types[e],o=i?i.superTypes.some(u=>this.isSubtype(u,r)):!1;return n[r]=o,o}}getAllSubTypes(e){const r=this.allSubtypes[e];if(r)return r;{const n=this.getAllTypes(),a=[];for(const i of n)this.isSubtype(i,e)&&a.push(i);return this.allSubtypes[e]=a,a}}},s(Qa,"AbstractAstReflection"),Qa);function Sr(t){return typeof t=="object"&&t!==null&&Array.isArray(t.content)}s(Sr,"isCompositeCstNode");function qn(t){return typeof t=="object"&&t!==null&&typeof t.tokenType=="object"}s(qn,"isLeafCstNode");function xf(t){return Sr(t)&&typeof t.fullText=="string"}s(xf,"isRootCstNode");var Et,ur=(Et=class{constructor(e,r){this.startFn=e,this.nextFn=r}iterator(){const e={state:this.startFn(),next:s(()=>this.nextFn(e.state),"next"),[Symbol.iterator]:()=>e};return e}[Symbol.iterator](){return this.iterator()}isEmpty(){return!!this.iterator().next().done}count(){const e=this.iterator();let r=0,n=e.next();for(;!n.done;)r++,n=e.next();return r}toArray(){const e=[],r=this.iterator();let n;do n=r.next(),n.value!==void 0&&e.push(n.value);while(!n.done);return e}toSet(){return new Set(this)}toMap(e,r){const n=this.map(a=>[e?e(a):a,r?r(a):a]);return new Map(n)}toString(){return this.join()}concat(e){return new Et(()=>({first:this.startFn(),firstDone:!1,iterator:e[Symbol.iterator]()}),r=>{let n;if(!r.firstDone){do if(n=this.nextFn(r.first),!n.done)return n;while(!n.done);r.firstDone=!0}do if(n=r.iterator.next(),!n.done)return n;while(!n.done);return ct})}join(e=","){const r=this.iterator();let n="",a,i=!1;do a=r.next(),a.done||(i&&(n+=e),n+=B$(a.value)),i=!0;while(!a.done);return n}indexOf(e,r=0){const n=this.iterator();let a=0,i=n.next();for(;!i.done;){if(a>=r&&i.value===e)return a;i=n.next(),a++}return-1}every(e){const r=this.iterator();let n=r.next();for(;!n.done;){if(!e(n.value))return!1;n=r.next()}return!0}some(e){const r=this.iterator();let n=r.next();for(;!n.done;){if(e(n.value))return!0;n=r.next()}return!1}forEach(e){const r=this.iterator();let n=0,a=r.next();for(;!a.done;)e(a.value,n),a=r.next(),n++}map(e){return new Et(this.startFn,r=>{const{done:n,value:a}=this.nextFn(r);return n?ct:{done:!1,value:e(a)}})}filter(e){return new Et(this.startFn,r=>{let n;do if(n=this.nextFn(r),!n.done&&e(n.value))return n;while(!n.done);return ct})}nonNullable(){return this.filter(e=>e!=null)}reduce(e,r){const n=this.iterator();let a=r,i=n.next();for(;!i.done;)a===void 0?a=i.value:a=e(a,i.value),i=n.next();return a}reduceRight(e,r){return this.recursiveReduce(this.iterator(),e,r)}recursiveReduce(e,r,n){const a=e.next();if(a.done)return n;const i=this.recursiveReduce(e,r,n);return i===void 0?a.value:r(i,a.value)}find(e){const r=this.iterator();let n=r.next();for(;!n.done;){if(e(n.value))return n.value;n=r.next()}}findIndex(e){const r=this.iterator();let n=0,a=r.next();for(;!a.done;){if(e(a.value))return n;a=r.next(),n++}return-1}includes(e){const r=this.iterator();let n=r.next();for(;!n.done;){if(n.value===e)return!0;n=r.next()}return!1}flatMap(e){return new Et(()=>({this:this.startFn()}),r=>{do{if(r.iterator){const i=r.iterator.next();if(i.done)r.iterator=void 0;else return i}const{done:n,value:a}=this.nextFn(r.this);if(!n){const i=e(a);if(vu(i))r.iterator=i[Symbol.iterator]();else return{done:!1,value:i}}}while(r.iterator);return ct})}flat(e){if(e===void 0&&(e=1),e<=0)return this;const r=e>1?this.flat(e-1):this;return new Et(()=>({this:r.startFn()}),n=>{do{if(n.iterator){const o=n.iterator.next();if(o.done)n.iterator=void 0;else return o}const{done:a,value:i}=r.nextFn(n.this);if(!a)if(vu(i))n.iterator=i[Symbol.iterator]();else return{done:!1,value:i}}while(n.iterator);return ct})}head(){const r=this.iterator().next();if(!r.done)return r.value}tail(e=1){return new Et(()=>{const r=this.startFn();for(let n=0;n<e;n++)if(this.nextFn(r).done)return r;return r},this.nextFn)}limit(e){return new Et(()=>({size:0,state:this.startFn()}),r=>(r.size++,r.size>e?ct:this.nextFn(r.state)))}distinct(e){return new Et(()=>({set:new Set,internalState:this.startFn()}),r=>{let n;do if(n=this.nextFn(r.internalState),!n.done){const a=e?e(n.value):n.value;if(!r.set.has(a))return r.set.add(a),n}while(!n.done);return ct})}exclude(e,r){const n=new Set;for(const a of e){const i=r?r(a):a;n.add(i)}return this.filter(a=>{const i=r?r(a):a;return!n.has(i)})}},s(Et,"StreamImpl"),Et);function B$(t){return typeof t=="string"?t:typeof t>"u"?"undefined":typeof t.toString=="function"?t.toString():Object.prototype.toString.call(t)}s(B$,"toString");function vu(t){return!!t&&typeof t[Symbol.iterator]=="function"}s(vu,"isIterable");var qo=new ur(()=>{},()=>ct),ct=Object.freeze({done:!0,value:void 0});function de(...t){if(t.length===1){const e=t[0];if(e instanceof ur)return e;if(vu(e))return new ur(()=>e[Symbol.iterator](),r=>r.next());if(typeof e.length=="number")return new ur(()=>({index:0}),r=>r.index<e.length?{done:!1,value:e[r.index++]}:ct)}return t.length>1?new ur(()=>({collIndex:0,arrIndex:0}),e=>{do{if(e.iterator){const r=e.iterator.next();if(!r.done)return r;e.iterator=void 0}if(e.array){if(e.arrIndex<e.array.length)return{done:!1,value:e.array[e.arrIndex++]};e.array=void 0,e.arrIndex=0}if(e.collIndex<t.length){const r=t[e.collIndex++];vu(r)?e.iterator=r[Symbol.iterator]():r&&typeof r.length=="number"&&(e.array=r)}}while(e.iterator||e.array||e.collIndex<t.length);return ct}):qo}s(de,"stream");var ei,Ho=(ei=class extends ur{constructor(e,r,n){super(()=>({iterators:n?.includeRoot?[[e][Symbol.iterator]()]:[r(e)[Symbol.iterator]()],pruned:!1}),a=>{for(a.pruned&&(a.iterators.pop(),a.pruned=!1);a.iterators.length>0;){const o=a.iterators[a.iterators.length-1].next();if(o.done)a.iterators.pop();else return a.iterators.push(r(o.value)[Symbol.iterator]()),o}return ct})}iterator(){const e={state:this.startFn(),next:s(()=>this.nextFn(e.state),"next"),prune:s(()=>{e.state.pruned=!0},"prune"),[Symbol.iterator]:()=>e};return e}},s(ei,"TreeStreamImpl"),ei),Tu;(function(t){function e(i){return i.reduce((o,u)=>o+u,0)}s(e,"sum"),t.sum=e;function r(i){return i.reduce((o,u)=>o*u,0)}s(r,"product"),t.product=r;function n(i){return i.reduce((o,u)=>Math.min(o,u))}s(n,"min"),t.min=n;function a(i){return i.reduce((o,u)=>Math.max(o,u))}s(a,"max"),t.max=a})(Tu||(Tu={}));var Sh={};tn(Sh,{assignMandatoryProperties:()=>wh,copyAstNode:()=>qc,findRootNode:()=>Ya,getContainerOfType:()=>Hn,getDocument:()=>Vt,getReferenceNodes:()=>Wc,hasContainerOfType:()=>U$,linkContentToContainer:()=>Yo,streamAllContents:()=>Mr,streamAst:()=>qt,streamContents:()=>Gu,streamReferences:()=>Xo});function Yo(t,e={}){for(const[r,n]of Object.entries(t))r.startsWith("$")||(Array.isArray(n)?n.forEach((a,i)=>{Be(a)&&(a.$container=t,a.$containerProperty=r,a.$containerIndex=i,e.deep&&Yo(a,e))}):Be(n)&&(n.$container=t,n.$containerProperty=r,e.deep&&Yo(n,e)))}s(Yo,"linkContentToContainer");function Hn(t,e){let r=t;for(;r;){if(e(r))return r;r=r.$container}}s(Hn,"getContainerOfType");function U$(t,e){let r=t;for(;r;){if(e(r))return!0;r=r.$container}return!1}s(U$,"hasContainerOfType");function Vt(t){const r=Ya(t).$document;if(!r)throw new Error("AST node has no document.");return r}s(Vt,"getDocument");function Ya(t){for(;t.$container;)t=t.$container;return t}s(Ya,"findRootNode");function Wc(t){return ft(t)?t.ref?[t.ref]:[]:fr(t)?t.items.map(e=>e.ref):[]}s(Wc,"getReferenceNodes");function Gu(t,e){if(!t)throw new Error("Node must be an AstNode.");const r=e?.range;return new ur(()=>({keys:Object.keys(t),keyIndex:0,arrayIndex:0}),n=>{for(;n.keyIndex<n.keys.length;){const a=n.keys[n.keyIndex];if(!a.startsWith("$")){const i=t[a];if(Be(i)){if(n.keyIndex++,Vc(i,r))return{done:!1,value:i}}else if(Array.isArray(i)){for(;n.arrayIndex<i.length;){const o=n.arrayIndex++,u=i[o];if(Be(u)&&Vc(u,r))return{done:!1,value:u}}n.arrayIndex=0}}n.keyIndex++}return ct})}s(Gu,"streamContents");function Mr(t,e){if(!t)throw new Error("Root node must be an AstNode.");return new Ho(t,r=>Gu(r,e))}s(Mr,"streamAllContents");function qt(t,e){if(t){if(e?.range&&!Vc(t,e.range))return new Ho(t,()=>[])}else throw new Error("Root node must be an AstNode.");return new Ho(t,r=>Gu(r,e),{includeRoot:!0})}s(qt,"streamAst");function Vc(t,e){if(!e)return!0;const r=t.$cstNode?.range;return r?Jh(r,e):!1}s(Vc,"isAstNodeInRange");function Xo(t){return new ur(()=>({keys:Object.keys(t),keyIndex:0,arrayIndex:0}),e=>{for(;e.keyIndex<e.keys.length;){const r=e.keys[e.keyIndex];if(!r.startsWith("$")){const n=t[r];if(ft(n)||fr(n))return e.keyIndex++,{done:!1,value:{reference:n,container:t,property:r}};if(Array.isArray(n)){for(;e.arrayIndex<n.length;){const a=e.arrayIndex++,i=n[a];if(ft(i)||fr(n))return{done:!1,value:{reference:i,container:t,property:r,index:a}}}e.arrayIndex=0}}e.keyIndex++}return ct})}s(Xo,"streamReferences");function wh(t,e){const r=t.getTypeMetaData(e.$type),n=e;for(const a of Object.values(r.properties))a.defaultValue!==void 0&&n[a.name]===void 0&&(n[a.name]=Ih(a.defaultValue))}s(wh,"assignMandatoryProperties");function Ih(t){return Array.isArray(t)?[...t.map(Ih)]:t}s(Ih,"copyDefaultValue");function qc(t,e,r){const n={$type:t.$type};r&&(r.set(t,n),r.set(n,t));for(const[a,i]of Object.entries(t))if(!a.startsWith("$"))if(Be(i))n[a]=qc(i,e,r);else if(ft(i))n[a]=e(n,a,i.$refNode,i.$refText,i);else if(Array.isArray(i)){const o=[];for(const u of i)Be(u)?o.push(qc(u,e,r)):ft(u)?o.push(e(n,a,u.$refNode,u.$refText,u)):o.push(u);n[a]=o}else n[a]=i;return Yo(n,{deep:!0}),n}s(qc,"copyAstNode");var K$={};tn(K$,{AbstractElement:()=>Rt,AbstractParserRule:()=>nu,AbstractRule:()=>ja,AbstractType:()=>wt,Action:()=>Kr,Alternatives:()=>au,ArrayLiteral:()=>Hc,ArrayType:()=>Yc,Assignment:()=>Wr,BooleanLiteral:()=>Xc,CharacterRange:()=>Vr,Condition:()=>qr,Conjunction:()=>iu,CrossReference:()=>Hr,Disjunction:()=>su,EndOfFile:()=>Jc,Grammar:()=>Cr,GrammarImport:()=>Zc,Group:()=>En,InferredType:()=>Qc,InfixRule:()=>sr,InfixRuleOperatorList:()=>ou,InfixRuleOperators:()=>ef,Interface:()=>Ba,Keyword:()=>Ua,LangiumGrammarAstReflection:()=>Hh,LangiumGrammarTerminals:()=>Jk,NamedArgument:()=>Ka,NegatedToken:()=>Cn,Negation:()=>tf,NumberLiteral:()=>rf,Parameter:()=>Wa,ParameterReference:()=>nf,ParserRule:()=>Ut,ReferenceType:()=>lu,RegexToken:()=>bn,ReturnType:()=>af,RuleCall:()=>_n,SimpleType:()=>Va,StringLiteral:()=>sf,TerminalAlternatives:()=>Sn,TerminalElement:()=>At,TerminalGroup:()=>wn,TerminalRule:()=>br,TerminalRuleCall:()=>In,Type:()=>uu,TypeAttribute:()=>Nn,TypeDefinition:()=>Pn,UnionType:()=>of,UnorderedGroup:()=>cu,UntilToken:()=>kn,ValueLiteral:()=>On,Wildcard:()=>qa,isAbstractElement:()=>Mf,isAbstractParserRule:()=>Yn,isAbstractRule:()=>W$,isAbstractType:()=>V$,isAction:()=>Xr,isAlternatives:()=>Gf,isArrayLiteral:()=>q$,isArrayType:()=>Nh,isAssignment:()=>wr,isBooleanLiteral:()=>Ph,isCharacterRange:()=>kh,isCondition:()=>H$,isConjunction:()=>Oh,isCrossReference:()=>Xn,isDisjunction:()=>Lh,isEndOfFile:()=>Dh,isGrammar:()=>Y$,isGrammarImport:()=>X$,isGroup:()=>Jn,isInferredType:()=>Fu,isInfixRule:()=>Jo,isInfixRuleOperatorList:()=>J$,isInfixRuleOperators:()=>Z$,isInterface:()=>xh,isKeyword:()=>Ir,isNamedArgument:()=>Q$,isNegatedToken:()=>Mh,isNegation:()=>Gh,isNumberLiteral:()=>eR,isParameter:()=>tR,isParameterReference:()=>Fh,isParserRule:()=>mt,isReferenceType:()=>zh,isRegexToken:()=>jh,isReturnType:()=>Bh,isRuleCall:()=>Nr,isSimpleType:()=>Ff,isStringLiteral:()=>rR,isTerminalAlternatives:()=>Uh,isTerminalElement:()=>nR,isTerminalGroup:()=>Kh,isTerminalRule:()=>jt,isTerminalRuleCall:()=>zf,isType:()=>jf,isTypeAttribute:()=>aR,isTypeDefinition:()=>iR,isUnionType:()=>Wh,isUnorderedGroup:()=>Bf,isUntilToken:()=>Vh,isValueLiteral:()=>sR,isWildcard:()=>qh,reflection:()=>U});var Jk={ID:/\^?[_a-zA-Z][\w_]*/,STRING:/"(\\.|[^"\\])*"|'(\\.|[^'\\])*'/,NUMBER:/NaN|-?((\d*\.\d+|\d+)([Ee][+-]?\d+)?|Infinity)/,RegexLiteral:/\/(?![*+?])(?:[^\r\n\[/\\]|\\.|\[(?:[^\r\n\]\\]|\\.)*\])+\/[a-z]*/,WS:/\s+/,ML_COMMENT:/\/\*[\s\S]*?\*\//,SL_COMMENT:/\/\/[^\n\r]*/},Rt={$type:"AbstractElement",cardinality:"cardinality"};function Mf(t){return U.isInstance(t,Rt.$type)}s(Mf,"isAbstractElement");var nu={$type:"AbstractParserRule"};function Yn(t){return U.isInstance(t,nu.$type)}s(Yn,"isAbstractParserRule");var ja={$type:"AbstractRule"};function W$(t){return U.isInstance(t,ja.$type)}s(W$,"isAbstractRule");var wt={$type:"AbstractType"};function V$(t){return U.isInstance(t,wt.$type)}s(V$,"isAbstractType");var Kr={$type:"Action",cardinality:"cardinality",feature:"feature",inferredType:"inferredType",operator:"operator",type:"type"};function Xr(t){return U.isInstance(t,Kr.$type)}s(Xr,"isAction");var au={$type:"Alternatives",cardinality:"cardinality",elements:"elements"};function Gf(t){return U.isInstance(t,au.$type)}s(Gf,"isAlternatives");var Hc={$type:"ArrayLiteral",elements:"elements"};function q$(t){return U.isInstance(t,Hc.$type)}s(q$,"isArrayLiteral");var Yc={$type:"ArrayType",elementType:"elementType"};function Nh(t){return U.isInstance(t,Yc.$type)}s(Nh,"isArrayType");var Wr={$type:"Assignment",cardinality:"cardinality",feature:"feature",operator:"operator",predicate:"predicate",terminal:"terminal"};function wr(t){return U.isInstance(t,Wr.$type)}s(wr,"isAssignment");var Xc={$type:"BooleanLiteral",true:"true"};function Ph(t){return U.isInstance(t,Xc.$type)}s(Ph,"isBooleanLiteral");var Vr={$type:"CharacterRange",cardinality:"cardinality",left:"left",lookahead:"lookahead",parenthesized:"parenthesized",right:"right"};function kh(t){return U.isInstance(t,Vr.$type)}s(kh,"isCharacterRange");var qr={$type:"Condition"};function H$(t){return U.isInstance(t,qr.$type)}s(H$,"isCondition");var iu={$type:"Conjunction",left:"left",right:"right"};function Oh(t){return U.isInstance(t,iu.$type)}s(Oh,"isConjunction");var Hr={$type:"CrossReference",cardinality:"cardinality",deprecatedSyntax:"deprecatedSyntax",isMulti:"isMulti",terminal:"terminal",type:"type"};function Xn(t){return U.isInstance(t,Hr.$type)}s(Xn,"isCrossReference");var su={$type:"Disjunction",left:"left",right:"right"};function Lh(t){return U.isInstance(t,su.$type)}s(Lh,"isDisjunction");var Jc={$type:"EndOfFile",cardinality:"cardinality"};function Dh(t){return U.isInstance(t,Jc.$type)}s(Dh,"isEndOfFile");var Cr={$type:"Grammar",imports:"imports",interfaces:"interfaces",isDeclared:"isDeclared",name:"name",rules:"rules",types:"types"};function Y$(t){return U.isInstance(t,Cr.$type)}s(Y$,"isGrammar");var Zc={$type:"GrammarImport",path:"path"};function X$(t){return U.isInstance(t,Zc.$type)}s(X$,"isGrammarImport");var En={$type:"Group",cardinality:"cardinality",elements:"elements",guardCondition:"guardCondition",predicate:"predicate"};function Jn(t){return U.isInstance(t,En.$type)}s(Jn,"isGroup");var Qc={$type:"InferredType",name:"name"};function Fu(t){return U.isInstance(t,Qc.$type)}s(Fu,"isInferredType");var sr={$type:"InfixRule",call:"call",dataType:"dataType",inferredType:"inferredType",name:"name",operators:"operators",parameters:"parameters",returnType:"returnType"};function Jo(t){return U.isInstance(t,sr.$type)}s(Jo,"isInfixRule");var ou={$type:"InfixRuleOperatorList",associativity:"associativity",operators:"operators"};function J$(t){return U.isInstance(t,ou.$type)}s(J$,"isInfixRuleOperatorList");var ef={$type:"InfixRuleOperators",precedences:"precedences"};function Z$(t){return U.isInstance(t,ef.$type)}s(Z$,"isInfixRuleOperators");var Ba={$type:"Interface",attributes:"attributes",name:"name",superTypes:"superTypes"};function xh(t){return U.isInstance(t,Ba.$type)}s(xh,"isInterface");var Ua={$type:"Keyword",cardinality:"cardinality",predicate:"predicate",value:"value"};function Ir(t){return U.isInstance(t,Ua.$type)}s(Ir,"isKeyword");var Ka={$type:"NamedArgument",calledByName:"calledByName",parameter:"parameter",value:"value"};function Q$(t){return U.isInstance(t,Ka.$type)}s(Q$,"isNamedArgument");var Cn={$type:"NegatedToken",cardinality:"cardinality",lookahead:"lookahead",parenthesized:"parenthesized",terminal:"terminal"};function Mh(t){return U.isInstance(t,Cn.$type)}s(Mh,"isNegatedToken");var tf={$type:"Negation",value:"value"};function Gh(t){return U.isInstance(t,tf.$type)}s(Gh,"isNegation");var rf={$type:"NumberLiteral",value:"value"};function eR(t){return U.isInstance(t,rf.$type)}s(eR,"isNumberLiteral");var Wa={$type:"Parameter",name:"name"};function tR(t){return U.isInstance(t,Wa.$type)}s(tR,"isParameter");var nf={$type:"ParameterReference",parameter:"parameter"};function Fh(t){return U.isInstance(t,nf.$type)}s(Fh,"isParameterReference");var Ut={$type:"ParserRule",dataType:"dataType",definition:"definition",entry:"entry",fragment:"fragment",inferredType:"inferredType",name:"name",parameters:"parameters",returnType:"returnType"};function mt(t){return U.isInstance(t,Ut.$type)}s(mt,"isParserRule");var lu={$type:"ReferenceType",isMulti:"isMulti",referenceType:"referenceType"};function zh(t){return U.isInstance(t,lu.$type)}s(zh,"isReferenceType");var bn={$type:"RegexToken",cardinality:"cardinality",lookahead:"lookahead",parenthesized:"parenthesized",regex:"regex"};function jh(t){return U.isInstance(t,bn.$type)}s(jh,"isRegexToken");var af={$type:"ReturnType",name:"name"};function Bh(t){return U.isInstance(t,af.$type)}s(Bh,"isReturnType");var _n={$type:"RuleCall",arguments:"arguments",cardinality:"cardinality",predicate:"predicate",rule:"rule"};function Nr(t){return U.isInstance(t,_n.$type)}s(Nr,"isRuleCall");var Va={$type:"SimpleType",primitiveType:"primitiveType",stringType:"stringType",typeRef:"typeRef"};function Ff(t){return U.isInstance(t,Va.$type)}s(Ff,"isSimpleType");var sf={$type:"StringLiteral",value:"value"};function rR(t){return U.isInstance(t,sf.$type)}s(rR,"isStringLiteral");var Sn={$type:"TerminalAlternatives",cardinality:"cardinality",elements:"elements",lookahead:"lookahead",parenthesized:"parenthesized"};function Uh(t){return U.isInstance(t,Sn.$type)}s(Uh,"isTerminalAlternatives");var At={$type:"TerminalElement",cardinality:"cardinality",lookahead:"lookahead",parenthesized:"parenthesized"};function nR(t){return U.isInstance(t,At.$type)}s(nR,"isTerminalElement");var wn={$type:"TerminalGroup",cardinality:"cardinality",elements:"elements",lookahead:"lookahead",parenthesized:"parenthesized"};function Kh(t){return U.isInstance(t,wn.$type)}s(Kh,"isTerminalGroup");var br={$type:"TerminalRule",definition:"definition",fragment:"fragment",hidden:"hidden",name:"name",type:"type"};function jt(t){return U.isInstance(t,br.$type)}s(jt,"isTerminalRule");var In={$type:"TerminalRuleCall",cardinality:"cardinality",lookahead:"lookahead",parenthesized:"parenthesized",rule:"rule"};function zf(t){return U.isInstance(t,In.$type)}s(zf,"isTerminalRuleCall");var uu={$type:"Type",name:"name",type:"type"};function jf(t){return U.isInstance(t,uu.$type)}s(jf,"isType");var Nn={$type:"TypeAttribute",defaultValue:"defaultValue",isOptional:"isOptional",name:"name",type:"type"};function aR(t){return U.isInstance(t,Nn.$type)}s(aR,"isTypeAttribute");var Pn={$type:"TypeDefinition"};function iR(t){return U.isInstance(t,Pn.$type)}s(iR,"isTypeDefinition");var of={$type:"UnionType",types:"types"};function Wh(t){return U.isInstance(t,of.$type)}s(Wh,"isUnionType");var cu={$type:"UnorderedGroup",cardinality:"cardinality",elements:"elements"};function Bf(t){return U.isInstance(t,cu.$type)}s(Bf,"isUnorderedGroup");var kn={$type:"UntilToken",cardinality:"cardinality",lookahead:"lookahead",parenthesized:"parenthesized",terminal:"terminal"};function Vh(t){return U.isInstance(t,kn.$type)}s(Vh,"isUntilToken");var On={$type:"ValueLiteral"};function sR(t){return U.isInstance(t,On.$type)}s(sR,"isValueLiteral");var qa={$type:"Wildcard",cardinality:"cardinality",lookahead:"lookahead",parenthesized:"parenthesized"};function qh(t){return U.isInstance(t,qa.$type)}s(qh,"isWildcard");var ti,Hh=(ti=class extends _h{constructor(){super(...arguments),this.types={AbstractElement:{name:Rt.$type,properties:{cardinality:{name:Rt.cardinality}},superTypes:[]},AbstractParserRule:{name:nu.$type,properties:{},superTypes:[ja.$type,wt.$type]},AbstractRule:{name:ja.$type,properties:{},superTypes:[]},AbstractType:{name:wt.$type,properties:{},superTypes:[]},Action:{name:Kr.$type,properties:{cardinality:{name:Kr.cardinality},feature:{name:Kr.feature},inferredType:{name:Kr.inferredType},operator:{name:Kr.operator},type:{name:Kr.type,referenceType:wt.$type}},superTypes:[Rt.$type]},Alternatives:{name:au.$type,properties:{cardinality:{name:au.cardinality},elements:{name:au.elements,defaultValue:[]}},superTypes:[Rt.$type]},ArrayLiteral:{name:Hc.$type,properties:{elements:{name:Hc.elements,defaultValue:[]}},superTypes:[On.$type]},ArrayType:{name:Yc.$type,properties:{elementType:{name:Yc.elementType}},superTypes:[Pn.$type]},Assignment:{name:Wr.$type,properties:{cardinality:{name:Wr.cardinality},feature:{name:Wr.feature},operator:{name:Wr.operator},predicate:{name:Wr.predicate},terminal:{name:Wr.terminal}},superTypes:[Rt.$type]},BooleanLiteral:{name:Xc.$type,properties:{true:{name:Xc.true,defaultValue:!1}},superTypes:[qr.$type,On.$type]},CharacterRange:{name:Vr.$type,properties:{cardinality:{name:Vr.cardinality},left:{name:Vr.left},lookahead:{name:Vr.lookahead},parenthesized:{name:Vr.parenthesized,defaultValue:!1},right:{name:Vr.right}},superTypes:[At.$type]},Condition:{name:qr.$type,properties:{},superTypes:[]},Conjunction:{name:iu.$type,properties:{left:{name:iu.left},right:{name:iu.right}},superTypes:[qr.$type]},CrossReference:{name:Hr.$type,properties:{cardinality:{name:Hr.cardinality},deprecatedSyntax:{name:Hr.deprecatedSyntax,defaultValue:!1},isMulti:{name:Hr.isMulti,defaultValue:!1},terminal:{name:Hr.terminal},type:{name:Hr.type,referenceType:wt.$type}},superTypes:[Rt.$type]},Disjunction:{name:su.$type,properties:{left:{name:su.left},right:{name:su.right}},superTypes:[qr.$type]},EndOfFile:{name:Jc.$type,properties:{cardinality:{name:Jc.cardinality}},superTypes:[Rt.$type]},Grammar:{name:Cr.$type,properties:{imports:{name:Cr.imports,defaultValue:[]},interfaces:{name:Cr.interfaces,defaultValue:[]},isDeclared:{name:Cr.isDeclared,defaultValue:!1},name:{name:Cr.name},rules:{name:Cr.rules,defaultValue:[]},types:{name:Cr.types,defaultValue:[]}},superTypes:[]},GrammarImport:{name:Zc.$type,properties:{path:{name:Zc.path}},superTypes:[]},Group:{name:En.$type,properties:{cardinality:{name:En.cardinality},elements:{name:En.elements,defaultValue:[]},guardCondition:{name:En.guardCondition},predicate:{name:En.predicate}},superTypes:[Rt.$type]},InferredType:{name:Qc.$type,properties:{name:{name:Qc.name}},superTypes:[wt.$type]},InfixRule:{name:sr.$type,properties:{call:{name:sr.call},dataType:{name:sr.dataType},inferredType:{name:sr.inferredType},name:{name:sr.name},operators:{name:sr.operators},parameters:{name:sr.parameters,defaultValue:[]},returnType:{name:sr.returnType,referenceType:wt.$type}},superTypes:[nu.$type]},InfixRuleOperatorList:{name:ou.$type,properties:{associativity:{name:ou.associativity},operators:{name:ou.operators,defaultValue:[]}},superTypes:[]},InfixRuleOperators:{name:ef.$type,properties:{precedences:{name:ef.precedences,defaultValue:[]}},superTypes:[]},Interface:{name:Ba.$type,properties:{attributes:{name:Ba.attributes,defaultValue:[]},name:{name:Ba.name},superTypes:{name:Ba.superTypes,defaultValue:[],referenceType:wt.$type}},superTypes:[wt.$type]},Keyword:{name:Ua.$type,properties:{cardinality:{name:Ua.cardinality},predicate:{name:Ua.predicate},value:{name:Ua.value}},superTypes:[Rt.$type]},NamedArgument:{name:Ka.$type,properties:{calledByName:{name:Ka.calledByName,defaultValue:!1},parameter:{name:Ka.parameter,referenceType:Wa.$type},value:{name:Ka.value}},superTypes:[]},NegatedToken:{name:Cn.$type,properties:{cardinality:{name:Cn.cardinality},lookahead:{name:Cn.lookahead},parenthesized:{name:Cn.parenthesized,defaultValue:!1},terminal:{name:Cn.terminal}},superTypes:[At.$type]},Negation:{name:tf.$type,properties:{value:{name:tf.value}},superTypes:[qr.$type]},NumberLiteral:{name:rf.$type,properties:{value:{name:rf.value}},superTypes:[On.$type]},Parameter:{name:Wa.$type,properties:{name:{name:Wa.name}},superTypes:[]},ParameterReference:{name:nf.$type,properties:{parameter:{name:nf.parameter,referenceType:Wa.$type}},superTypes:[qr.$type]},ParserRule:{name:Ut.$type,properties:{dataType:{name:Ut.dataType},definition:{name:Ut.definition},entry:{name:Ut.entry,defaultValue:!1},fragment:{name:Ut.fragment,defaultValue:!1},inferredType:{name:Ut.inferredType},name:{name:Ut.name},parameters:{name:Ut.parameters,defaultValue:[]},returnType:{name:Ut.returnType,referenceType:wt.$type}},superTypes:[nu.$type]},ReferenceType:{name:lu.$type,properties:{isMulti:{name:lu.isMulti,defaultValue:!1},referenceType:{name:lu.referenceType}},superTypes:[Pn.$type]},RegexToken:{name:bn.$type,properties:{cardinality:{name:bn.cardinality},lookahead:{name:bn.lookahead},parenthesized:{name:bn.parenthesized,defaultValue:!1},regex:{name:bn.regex}},superTypes:[At.$type]},ReturnType:{name:af.$type,properties:{name:{name:af.name}},superTypes:[]},RuleCall:{name:_n.$type,properties:{arguments:{name:_n.arguments,defaultValue:[]},cardinality:{name:_n.cardinality},predicate:{name:_n.predicate},rule:{name:_n.rule,referenceType:ja.$type}},superTypes:[Rt.$type]},SimpleType:{name:Va.$type,properties:{primitiveType:{name:Va.primitiveType},stringType:{name:Va.stringType},typeRef:{name:Va.typeRef,referenceType:wt.$type}},superTypes:[Pn.$type]},StringLiteral:{name:sf.$type,properties:{value:{name:sf.value}},superTypes:[On.$type]},TerminalAlternatives:{name:Sn.$type,properties:{cardinality:{name:Sn.cardinality},elements:{name:Sn.elements,defaultValue:[]},lookahead:{name:Sn.lookahead},parenthesized:{name:Sn.parenthesized,defaultValue:!1}},superTypes:[At.$type]},TerminalElement:{name:At.$type,properties:{cardinality:{name:At.cardinality},lookahead:{name:At.lookahead},parenthesized:{name:At.parenthesized,defaultValue:!1}},superTypes:[Rt.$type]},TerminalGroup:{name:wn.$type,properties:{cardinality:{name:wn.cardinality},elements:{name:wn.elements,defaultValue:[]},lookahead:{name:wn.lookahead},parenthesized:{name:wn.parenthesized,defaultValue:!1}},superTypes:[At.$type]},TerminalRule:{name:br.$type,properties:{definition:{name:br.definition},fragment:{name:br.fragment,defaultValue:!1},hidden:{name:br.hidden,defaultValue:!1},name:{name:br.name},type:{name:br.type}},superTypes:[ja.$type]},TerminalRuleCall:{name:In.$type,properties:{cardinality:{name:In.cardinality},lookahead:{name:In.lookahead},parenthesized:{name:In.parenthesized,defaultValue:!1},rule:{name:In.rule,referenceType:br.$type}},superTypes:[At.$type]},Type:{name:uu.$type,properties:{name:{name:uu.name},type:{name:uu.type}},superTypes:[wt.$type]},TypeAttribute:{name:Nn.$type,properties:{defaultValue:{name:Nn.defaultValue},isOptional:{name:Nn.isOptional,defaultValue:!1},name:{name:Nn.name},type:{name:Nn.type}},superTypes:[]},TypeDefinition:{name:Pn.$type,properties:{},superTypes:[]},UnionType:{name:of.$type,properties:{types:{name:of.types,defaultValue:[]}},superTypes:[Pn.$type]},UnorderedGroup:{name:cu.$type,properties:{cardinality:{name:cu.cardinality},elements:{name:cu.elements,defaultValue:[]}},superTypes:[Rt.$type]},UntilToken:{name:kn.$type,properties:{cardinality:{name:kn.cardinality},lookahead:{name:kn.lookahead},parenthesized:{name:kn.parenthesized,defaultValue:!1},terminal:{name:kn.terminal}},superTypes:[At.$type]},ValueLiteral:{name:On.$type,properties:{},superTypes:[]},Wildcard:{name:qa.$type,properties:{cardinality:{name:qa.cardinality},lookahead:{name:qa.lookahead},parenthesized:{name:qa.parenthesized,defaultValue:!1}},superTypes:[At.$type]}}}},s(ti,"LangiumGrammarAstReflection"),ti),U=new Hh;function oR(t){let e=t,r=!1;for(;e;){const n=Hn(e.grammarSource,mt);if(n&&n.dataType)e=e.container,r=!0;else return r?e:void 0}}s(oR,"getDatatypeNode");function Zo(t){return new Ho(t,e=>Sr(e)?e.content:[],{includeRoot:!0})}s(Zo,"streamCst");function lR(t){return Zo(t).filter(qn)}s(lR,"flattenCst");function Yh(t,e){for(;t.container;)if(t=t.container,t===e)return!0;return!1}s(Yh,"isChildNode");function $u(t){return{start:{character:t.startColumn-1,line:t.startLine-1},end:{character:t.endColumn,line:t.endLine-1}}}s($u,"tokenToRange");function Qo(t){if(!t)return;const{offset:e,end:r,range:n}=t;return{range:n,offset:e,end:r,length:r-e}}s(Qo,"toDocumentSegment");var lr;(function(t){t[t.Before=0]="Before",t[t.After=1]="After",t[t.OverlapFront=2]="OverlapFront",t[t.OverlapBack=3]="OverlapBack",t[t.Inside=4]="Inside",t[t.Outside=5]="Outside"})(lr||(lr={}));function Xh(t,e){if(t.end.line<e.start.line||t.end.line===e.start.line&&t.end.character<=e.start.character)return lr.Before;if(t.start.line>e.end.line||t.start.line===e.end.line&&t.start.character>=e.end.character)return lr.After;const r=t.start.line>e.start.line||t.start.line===e.start.line&&t.start.character>=e.start.character,n=t.end.line<e.end.line||t.end.line===e.end.line&&t.end.character<=e.end.character;return r&&n?lr.Inside:r?lr.OverlapBack:n?lr.OverlapFront:lr.Outside}s(Xh,"compareRange");function Jh(t,e){return Xh(t,e)>lr.After}s(Jh,"inRange");var Zh=/^[\w\p{L}]$/u;function uR(t,e,r=Zh){if(t){if(e>0){const n=e-t.offset,a=t.text.charAt(n);r.test(a)||e--}return Uf(t,e)}}s(uR,"findDeclarationNodeAtOffset");function Qh(t,e){if(t){const r=ry(t,!0);if(r&&lf(r,e))return r;if(xf(t)){const n=t.content.findIndex(a=>!a.hidden);for(let a=n-1;a>=0;a--){const i=t.content[a];if(lf(i,e))return i}}}}s(Qh,"findCommentNode");function lf(t,e){return qn(t)&&e.includes(t.tokenType.name)}s(lf,"isCommentNode");function Uf(t,e){if(qn(t))return t;if(Sr(t)){const r=ty(t,e,!1);if(r)return Uf(r,e)}}s(Uf,"findLeafNodeAtOffset");function ey(t,e){if(qn(t))return t;if(Sr(t)){const r=ty(t,e,!0);if(r)return ey(r,e)}}s(ey,"findLeafNodeBeforeOffset");function ty(t,e,r){let n=0,a=t.content.length-1,i;for(;n<=a;){const o=Math.floor((n+a)/2),u=t.content[o];if(u.offset<=e&&u.end>e)return u;u.end<=e?(i=r?u:void 0,n=o+1):a=o-1}return i}s(ty,"binarySearch");function ry(t,e=!0){for(;t.container;){const r=t.container;let n=r.content.indexOf(t);for(;n>0;){n--;const a=r.content[n];if(e||!a.hidden)return a}t=r}}s(ry,"getPreviousNode");function cR(t,e=!0){for(;t.container;){const r=t.container;let n=r.content.indexOf(t);const a=r.content.length-1;for(;n<a;){n++;const i=r.content[n];if(e||!i.hidden)return i}t=r}}s(cR,"getNextNode");function fR(t){if(t.range.start.character===0)return t;const e=t.range.start.line;let r=t,n;for(;t.container;){const a=t.container,i=n??a.content.indexOf(t);if(i===0?(t=a,n=void 0):(n=i-1,t=a.content[n]),t.range.start.line!==e)break;r=t}return r}s(fR,"getStartlineNode");function dR(t,e){const r=pR(t,e);return r?r.parent.content.slice(r.a+1,r.b):[]}s(dR,"getInteriorNodes");function pR(t,e){const r=Rm(t),n=Rm(e);let a;for(let i=0;i<r.length&&i<n.length;i++){const o=r[i],u=n[i];if(o.parent===u.parent)a={parent:o.parent,a:o.index,b:u.index};else break}return a}s(pR,"getCommonParent");function Rm(t){const e=[];for(;t.container;){const r=t.container,n=r.content.indexOf(t);e.push({parent:r,index:n}),t=r}return e.reverse()}s(Rm,"getParentChain");var ny={};tn(ny,{findAssignment:()=>yy,findNameAssignment:()=>Jf,findNodeForKeyword:()=>hy,findNodeForProperty:()=>Hf,findNodesForKeyword:()=>RR,findNodesForKeywordInternal:()=>Xf,findNodesForProperty:()=>my,getActionAtElement:()=>vy,getActionType:()=>$y,getAllReachableRules:()=>qf,getAllRulesUsedForCrossReferences:()=>$R,getCrossReferenceTerminal:()=>dy,getEntryRule:()=>uy,getExplicitRuleType:()=>ju,getHiddenRules:()=>cy,getRuleType:()=>Ry,getRuleTypeName:()=>_R,getTypeName:()=>Bn,isArrayCardinality:()=>ER,isArrayOperator:()=>CR,isCommentTerminal:()=>py,isDataType:()=>bR,isDataTypeRule:()=>zu,isOptionalCardinality:()=>AR,terminalRegex:()=>Bu});var ri,Kf=(ri=class extends Error{constructor(e,r){super(e?`${r} at ${e.range.start.line}:${e.range.start.character}`:r)}},s(ri,"ErrorWithLocation"),ri);function rn(t,e="Error: Got unexpected value."){throw new Error(e)}s(rn,"assertUnreachable");function ay(t,e="Error: Condition is violated."){if(!t)throw new Error(e)}s(ay,"assertCondition");var iy={};tn(iy,{NEWLINE_REGEXP:()=>yR,escapeRegExp:()=>sl,getTerminalParts:()=>vR,isMultilineComment:()=>sy,isWhitespace:()=>Vf,partialMatches:()=>oy,partialRegExp:()=>ly,whitespaceCharacters:()=>TR});function W(t){return t.charCodeAt(0)}s(W,"cc");function Ic(t,e){Array.isArray(t)?t.forEach(function(r){e.push(r)}):e.push(t)}s(Ic,"insertToSet");function Na(t,e){if(t[e]===!0)throw"duplicate flag "+e;t[e],t[e]=!0}s(Na,"addFlag");function hn(t){if(t===void 0)throw Error("Internal Error - Should never get here!");return!0}s(hn,"ASSERT_EXISTS");function mR(){throw Error("Internal Error - Should never get here!")}s(mR,"ASSERT_NEVER_REACH_HERE");function Am(t){return t.type==="Character"}s(Am,"isCharacter");var uf=[];for(let t=W("0");t<=W("9");t++)uf.push(t);var cf=[W("_")].concat(uf);for(let t=W("a");t<=W("z");t++)cf.push(t);for(let t=W("A");t<=W("Z");t++)cf.push(t);var ov=[W(" "),W("\f"),W(`
35
+ `)),P){const F=g.error?` Request failed: ${g.error.message} (${g.error.code}).`:"";ce.log(`Received response '${P.method} - (${g.id})' in ${Date.now()-P.timerStart}ms.${F}`,D)}else ce.log(`Received response ${g.id} without active response promise.`,D)}else tr("receive-response",g)}s(Il,"traceReceivedResponse");function tr(g,P){if(!ce||ee===p.Off)return;const D={isLSPMessage:!0,type:g,message:P,timestamp:Date.now()};ce.log(D)}s(tr,"logLSPMessage");function Tr(){if(ha())throw new w(T.Closed,"Connection is closed.");if(er())throw new w(T.Disposed,"Connection is disposed.")}s(Tr,"throwIfClosedOrDisposed");function Nl(){if(ma())throw new w(T.AlreadyListening,"Connection is already listening")}s(Nl,"throwIfListening");function Pl(){if(!ma())throw new Error("Call listen() first.")}s(Pl,"throwIfNotListening");function m(g){return g===void 0?null:g}s(m,"undefinedToNull");function le(g){if(g!==null)return g}s(le,"nullToUndefined");function we(g){return g!=null&&!Array.isArray(g)&&typeof g=="object"}s(we,"isNamedParam");function H(g,P){switch(g){case n.ParameterStructures.auto:return we(P)?le(P):[m(P)];case n.ParameterStructures.byName:if(!we(P))throw new Error("Received parameters by name but param is not an object literal.");return le(P);case n.ParameterStructures.byPosition:return[m(P)];default:throw new Error(`Unknown parameter structure ${g.toString()}`)}}s(H,"computeSingleParam");function Ie(g,P){let D;const F=g.numberOfParams;switch(F){case 0:D=void 0;break;case 1:D=H(g.parameterStructures,P[0]);break;default:D=[];for(let Ce=0;Ce<P.length&&Ce<F;Ce++)D.push(m(P[Ce]));if(P.length<F)for(let Ce=P.length;Ce<F;Ce++)D.push(null);break}return D}s(Ie,"computeMessageParams");const Ta={sendNotification:s((g,...P)=>{Tr();let D,F;if(r.string(g)){D=g;const me=P[0];let De=0,Ge=n.ParameterStructures.auto;n.ParameterStructures.is(me)&&(De=1,Ge=me);let ie=P.length;const Ne=ie-De;switch(Ne){case 0:F=void 0;break;case 1:F=H(Ge,P[De]);break;default:if(Ge===n.ParameterStructures.byName)throw new Error(`Received ${Ne} parameters for 'by Name' notification parameter structure.`);F=P.slice(De,ie).map(fe=>m(fe));break}}else{const me=P;D=g.method,F=Ie(g,me)}const Ce={jsonrpc:z,method:D,params:F};return Sl(Ce),I.write(Ce).catch(me=>{throw S.error("Sending notification failed."),me})},"sendNotification"),onNotification:s((g,P)=>{Tr();let D;return r.func(g)?q=g:P&&(r.string(g)?(D=g,Z.set(g,{type:void 0,handler:P})):(D=g.method,Z.set(g.method,{type:g,handler:P}))),{dispose:s(()=>{D!==void 0?Z.delete(D):q=void 0},"dispose")}},"onNotification"),onProgress:s((g,P,D)=>{if(ae.has(P))throw new Error(`Progress handler for token ${P} already registered`);return ae.set(P,D),{dispose:s(()=>{ae.delete(P)},"dispose")}},"onProgress"),sendProgress:s((g,P,D)=>Ta.sendNotification(c.type,{token:P,value:D}),"sendProgress"),onUnhandledProgress:Qt.event,sendRequest:s((g,...P)=>{Tr(),Pl();let D,F,Ce;if(r.string(g)){D=g;const ie=P[0],Ne=P[P.length-1];let fe=0,Ue=n.ParameterStructures.auto;n.ParameterStructures.is(ie)&&(fe=1,Ue=ie);let lt=P.length;o.CancellationToken.is(Ne)&&(lt=lt-1,Ce=Ne);const rr=lt-fe;switch(rr){case 0:F=void 0;break;case 1:F=H(Ue,P[fe]);break;default:if(Ue===n.ParameterStructures.byName)throw new Error(`Received ${rr} parameters for 'by Name' request parameter structure.`);F=P.slice(fe,lt).map(fk=>m(fk));break}}else{const ie=P;D=g.method,F=Ie(g,ie);const Ne=g.numberOfParams;Ce=o.CancellationToken.is(ie[Ne])?ie[Ne]:void 0}const me=L++;let De;Ce&&(De=Ce.onCancellationRequested(()=>{const ie=ve.sender.sendCancellation(Ta,me);return ie===void 0?(S.log(`Received no promise from cancellation strategy when cancelling id ${me}`),Promise.resolve()):ie.catch(()=>{S.log(`Sending cancellation messages for id ${me} failed`)})}));const Ge={jsonrpc:z,id:me,method:D,params:F};return _l(Ge),typeof ve.sender.enableCancellation=="function"&&ve.sender.enableCancellation(Ge),new Promise(async(ie,Ne)=>{const fe=s(rr=>{ie(rr),ve.sender.cleanup(me),De?.dispose()},"resolveWithCleanup"),Ue=s(rr=>{Ne(rr),ve.sender.cleanup(me),De?.dispose()},"rejectWithCleanup"),lt={method:D,timerStart:Date.now(),resolve:fe,reject:Ue};try{await I.write(Ge),Ee.set(me,lt)}catch(rr){throw S.error("Sending request failed."),lt.reject(new n.ResponseError(n.ErrorCodes.MessageWriteError,rr.message?rr.message:"Unknown reason")),rr}})},"sendRequest"),onRequest:s((g,P)=>{Tr();let D=null;return d.is(g)?(D=void 0,M=g):r.string(g)?(D=null,P!==void 0&&(D=g,Y.set(g,{handler:P,type:void 0}))):P!==void 0&&(D=g.method,Y.set(g.method,{type:g,handler:P})),{dispose:s(()=>{D!==null&&(D!==void 0?Y.delete(D):M=void 0)},"dispose")}},"onRequest"),hasPendingResponse:s(()=>Ee.size>0,"hasPendingResponse"),trace:s(async(g,P,D)=>{let F=!1,Ce=h.Text;D!==void 0&&(r.boolean(D)?F=D:(F=D.sendNotification||!1,Ce=D.traceFormat||h.Text)),ee=g,Qe=Ce,ee===p.Off?ce=void 0:ce=P,F&&!ha()&&!er()&&await Ta.sendNotification($.type,{value:p.toString(g)})},"trace"),onError:ge.event,onClose:G.event,onUnhandledNotification:je.event,onDispose:Dt.event,end:s(()=>{I.end()},"end"),dispose:s(()=>{if(er())return;qe=ue.Disposed,Dt.fire(void 0);const g=new n.ResponseError(n.ErrorCodes.PendingResponseRejected,"Pending response rejected since connection got disposed");for(const P of Ee.values())P.reject(g);Ee=new Map,Le=new Map,Ve=new Set,pe=new a.LinkedMap,r.func(I.dispose)&&I.dispose(),r.func(v.dispose)&&v.dispose()},"dispose"),listen:s(()=>{Tr(),Nl(),qe=ue.Listening,v.listen(nc)},"listen"),inspect:s(()=>{(0,e.default)().console.log("inspect")},"inspect")};return Ta.onNotification(C.type,g=>{if(ee===p.Off||!ce)return;const P=ee===p.Verbose||ee===p.Compact;ce.log(g.message,P?g.verbose:void 0)}),Ta.onNotification(c.type,g=>{const P=ae.get(g.token);P?P(g.value):Qt.fire(g)}),Ta}s(ot,"createMessageConnection"),t.createMessageConnection=ot}}),$m=X({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/common/api.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.ProgressType=t.ProgressToken=t.createMessageConnection=t.NullLogger=t.ConnectionOptions=t.ConnectionStrategy=t.AbstractMessageBuffer=t.WriteableStreamMessageWriter=t.AbstractMessageWriter=t.MessageWriter=t.ReadableStreamMessageReader=t.AbstractMessageReader=t.MessageReader=t.SharedArrayReceiverStrategy=t.SharedArraySenderStrategy=t.CancellationToken=t.CancellationTokenSource=t.Emitter=t.Event=t.Disposable=t.LRUCache=t.Touch=t.LinkedMap=t.ParameterStructures=t.NotificationType9=t.NotificationType8=t.NotificationType7=t.NotificationType6=t.NotificationType5=t.NotificationType4=t.NotificationType3=t.NotificationType2=t.NotificationType1=t.NotificationType0=t.NotificationType=t.ErrorCodes=t.ResponseError=t.RequestType9=t.RequestType8=t.RequestType7=t.RequestType6=t.RequestType5=t.RequestType4=t.RequestType3=t.RequestType2=t.RequestType1=t.RequestType0=t.RequestType=t.Message=t.RAL=void 0,t.MessageStrategy=t.CancellationStrategy=t.CancellationSenderStrategy=t.CancellationReceiverStrategy=t.ConnectionError=t.ConnectionErrors=t.LogTraceNotification=t.SetTraceNotification=t.TraceFormat=t.TraceValues=t.Trace=void 0;var e=G$();Object.defineProperty(t,"Message",{enumerable:!0,get:s(function(){return e.Message},"get")}),Object.defineProperty(t,"RequestType",{enumerable:!0,get:s(function(){return e.RequestType},"get")}),Object.defineProperty(t,"RequestType0",{enumerable:!0,get:s(function(){return e.RequestType0},"get")}),Object.defineProperty(t,"RequestType1",{enumerable:!0,get:s(function(){return e.RequestType1},"get")}),Object.defineProperty(t,"RequestType2",{enumerable:!0,get:s(function(){return e.RequestType2},"get")}),Object.defineProperty(t,"RequestType3",{enumerable:!0,get:s(function(){return e.RequestType3},"get")}),Object.defineProperty(t,"RequestType4",{enumerable:!0,get:s(function(){return e.RequestType4},"get")}),Object.defineProperty(t,"RequestType5",{enumerable:!0,get:s(function(){return e.RequestType5},"get")}),Object.defineProperty(t,"RequestType6",{enumerable:!0,get:s(function(){return e.RequestType6},"get")}),Object.defineProperty(t,"RequestType7",{enumerable:!0,get:s(function(){return e.RequestType7},"get")}),Object.defineProperty(t,"RequestType8",{enumerable:!0,get:s(function(){return e.RequestType8},"get")}),Object.defineProperty(t,"RequestType9",{enumerable:!0,get:s(function(){return e.RequestType9},"get")}),Object.defineProperty(t,"ResponseError",{enumerable:!0,get:s(function(){return e.ResponseError},"get")}),Object.defineProperty(t,"ErrorCodes",{enumerable:!0,get:s(function(){return e.ErrorCodes},"get")}),Object.defineProperty(t,"NotificationType",{enumerable:!0,get:s(function(){return e.NotificationType},"get")}),Object.defineProperty(t,"NotificationType0",{enumerable:!0,get:s(function(){return e.NotificationType0},"get")}),Object.defineProperty(t,"NotificationType1",{enumerable:!0,get:s(function(){return e.NotificationType1},"get")}),Object.defineProperty(t,"NotificationType2",{enumerable:!0,get:s(function(){return e.NotificationType2},"get")}),Object.defineProperty(t,"NotificationType3",{enumerable:!0,get:s(function(){return e.NotificationType3},"get")}),Object.defineProperty(t,"NotificationType4",{enumerable:!0,get:s(function(){return e.NotificationType4},"get")}),Object.defineProperty(t,"NotificationType5",{enumerable:!0,get:s(function(){return e.NotificationType5},"get")}),Object.defineProperty(t,"NotificationType6",{enumerable:!0,get:s(function(){return e.NotificationType6},"get")}),Object.defineProperty(t,"NotificationType7",{enumerable:!0,get:s(function(){return e.NotificationType7},"get")}),Object.defineProperty(t,"NotificationType8",{enumerable:!0,get:s(function(){return e.NotificationType8},"get")}),Object.defineProperty(t,"NotificationType9",{enumerable:!0,get:s(function(){return e.NotificationType9},"get")}),Object.defineProperty(t,"ParameterStructures",{enumerable:!0,get:s(function(){return e.ParameterStructures},"get")});var r=F$();Object.defineProperty(t,"LinkedMap",{enumerable:!0,get:s(function(){return r.LinkedMap},"get")}),Object.defineProperty(t,"LRUCache",{enumerable:!0,get:s(function(){return r.LRUCache},"get")}),Object.defineProperty(t,"Touch",{enumerable:!0,get:s(function(){return r.Touch},"get")});var n=Tk();Object.defineProperty(t,"Disposable",{enumerable:!0,get:s(function(){return n.Disposable},"get")});var a=al();Object.defineProperty(t,"Event",{enumerable:!0,get:s(function(){return a.Event},"get")}),Object.defineProperty(t,"Emitter",{enumerable:!0,get:s(function(){return a.Emitter},"get")});var i=Df();Object.defineProperty(t,"CancellationTokenSource",{enumerable:!0,get:s(function(){return i.CancellationTokenSource},"get")}),Object.defineProperty(t,"CancellationToken",{enumerable:!0,get:s(function(){return i.CancellationToken},"get")});var o=$k();Object.defineProperty(t,"SharedArraySenderStrategy",{enumerable:!0,get:s(function(){return o.SharedArraySenderStrategy},"get")}),Object.defineProperty(t,"SharedArrayReceiverStrategy",{enumerable:!0,get:s(function(){return o.SharedArrayReceiverStrategy},"get")});var u=Rk();Object.defineProperty(t,"MessageReader",{enumerable:!0,get:s(function(){return u.MessageReader},"get")}),Object.defineProperty(t,"AbstractMessageReader",{enumerable:!0,get:s(function(){return u.AbstractMessageReader},"get")}),Object.defineProperty(t,"ReadableStreamMessageReader",{enumerable:!0,get:s(function(){return u.ReadableStreamMessageReader},"get")});var l=Ak();Object.defineProperty(t,"MessageWriter",{enumerable:!0,get:s(function(){return l.MessageWriter},"get")}),Object.defineProperty(t,"AbstractMessageWriter",{enumerable:!0,get:s(function(){return l.AbstractMessageWriter},"get")}),Object.defineProperty(t,"WriteableStreamMessageWriter",{enumerable:!0,get:s(function(){return l.WriteableStreamMessageWriter},"get")});var c=Ek();Object.defineProperty(t,"AbstractMessageBuffer",{enumerable:!0,get:s(function(){return c.AbstractMessageBuffer},"get")});var f=Ck();Object.defineProperty(t,"ConnectionStrategy",{enumerable:!0,get:s(function(){return f.ConnectionStrategy},"get")}),Object.defineProperty(t,"ConnectionOptions",{enumerable:!0,get:s(function(){return f.ConnectionOptions},"get")}),Object.defineProperty(t,"NullLogger",{enumerable:!0,get:s(function(){return f.NullLogger},"get")}),Object.defineProperty(t,"createMessageConnection",{enumerable:!0,get:s(function(){return f.createMessageConnection},"get")}),Object.defineProperty(t,"ProgressToken",{enumerable:!0,get:s(function(){return f.ProgressToken},"get")}),Object.defineProperty(t,"ProgressType",{enumerable:!0,get:s(function(){return f.ProgressType},"get")}),Object.defineProperty(t,"Trace",{enumerable:!0,get:s(function(){return f.Trace},"get")}),Object.defineProperty(t,"TraceValues",{enumerable:!0,get:s(function(){return f.TraceValues},"get")}),Object.defineProperty(t,"TraceFormat",{enumerable:!0,get:s(function(){return f.TraceFormat},"get")}),Object.defineProperty(t,"SetTraceNotification",{enumerable:!0,get:s(function(){return f.SetTraceNotification},"get")}),Object.defineProperty(t,"LogTraceNotification",{enumerable:!0,get:s(function(){return f.LogTraceNotification},"get")}),Object.defineProperty(t,"ConnectionErrors",{enumerable:!0,get:s(function(){return f.ConnectionErrors},"get")}),Object.defineProperty(t,"ConnectionError",{enumerable:!0,get:s(function(){return f.ConnectionError},"get")}),Object.defineProperty(t,"CancellationReceiverStrategy",{enumerable:!0,get:s(function(){return f.CancellationReceiverStrategy},"get")}),Object.defineProperty(t,"CancellationSenderStrategy",{enumerable:!0,get:s(function(){return f.CancellationSenderStrategy},"get")}),Object.defineProperty(t,"CancellationStrategy",{enumerable:!0,get:s(function(){return f.CancellationStrategy},"get")}),Object.defineProperty(t,"MessageStrategy",{enumerable:!0,get:s(function(){return f.MessageStrategy},"get")});var d=Vn();t.RAL=d.default}}),bk=X({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/browser/ril.js"(t){var l,c,f;Object.defineProperty(t,"__esModule",{value:!0});var e=$m(),r=(l=class extends e.AbstractMessageBuffer{constructor(p="utf-8"){super(p),this.asciiDecoder=new TextDecoder("ascii")}emptyBuffer(){return l.emptyBuffer}fromString(p,y){return new TextEncoder().encode(p)}toString(p,y){return y==="ascii"?this.asciiDecoder.decode(p):new TextDecoder(y).decode(p)}asNative(p,y){return y===void 0?p:p.slice(0,y)}allocNative(p){return new Uint8Array(p)}},s(l,"MessageBuffer"),l);r.emptyBuffer=new Uint8Array(0);var n=(c=class{constructor(p){this.socket=p,this._onData=new e.Emitter,this._messageListener=y=>{y.data.arrayBuffer().then($=>{this._onData.fire(new Uint8Array($))},()=>{(0,e.RAL)().console.error("Converting blob to array buffer failed.")})},this.socket.addEventListener("message",this._messageListener)}onClose(p){return this.socket.addEventListener("close",p),e.Disposable.create(()=>this.socket.removeEventListener("close",p))}onError(p){return this.socket.addEventListener("error",p),e.Disposable.create(()=>this.socket.removeEventListener("error",p))}onEnd(p){return this.socket.addEventListener("end",p),e.Disposable.create(()=>this.socket.removeEventListener("end",p))}onData(p){return this._onData.event(p)}},s(c,"ReadableStreamWrapper"),c),a=(f=class{constructor(p){this.socket=p}onClose(p){return this.socket.addEventListener("close",p),e.Disposable.create(()=>this.socket.removeEventListener("close",p))}onError(p){return this.socket.addEventListener("error",p),e.Disposable.create(()=>this.socket.removeEventListener("error",p))}onEnd(p){return this.socket.addEventListener("end",p),e.Disposable.create(()=>this.socket.removeEventListener("end",p))}write(p,y){if(typeof p=="string"){if(y!==void 0&&y!=="utf-8")throw new Error(`In a Browser environments only utf-8 text encoding is supported. But got encoding: ${y}`);this.socket.send(p)}else this.socket.send(p);return Promise.resolve()}end(){this.socket.close()}},s(f,"WritableStreamWrapper"),f),i=new TextEncoder,o=Object.freeze({messageBuffer:Object.freeze({create:s(d=>new r(d),"create")}),applicationJson:Object.freeze({encoder:Object.freeze({name:"application/json",encode:s((d,p)=>{if(p.charset!=="utf-8")throw new Error(`In a Browser environments only utf-8 text encoding is supported. But got encoding: ${p.charset}`);return Promise.resolve(i.encode(JSON.stringify(d,void 0,0)))},"encode")}),decoder:Object.freeze({name:"application/json",decode:s((d,p)=>{if(!(d instanceof Uint8Array))throw new Error("In a Browser environments only Uint8Arrays are supported.");return Promise.resolve(JSON.parse(new TextDecoder(p.charset).decode(d)))},"decode")})}),stream:Object.freeze({asReadableStream:s(d=>new n(d),"asReadableStream"),asWritableStream:s(d=>new a(d),"asWritableStream")}),console,timer:Object.freeze({setTimeout(d,p,...y){const h=setTimeout(d,p,...y);return{dispose:s(()=>clearTimeout(h),"dispose")}},setImmediate(d,...p){const y=setTimeout(d,0,...p);return{dispose:s(()=>clearTimeout(y),"dispose")}},setInterval(d,p,...y){const h=setInterval(d,p,...y);return{dispose:s(()=>clearInterval(h),"dispose")}}})});function u(){return o}s(u,"RIL"),(function(d){function p(){e.RAL.install(o)}s(p,"install"),d.install=p})(u||(u={})),t.default=u}}),il=X({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/lib/browser/main.js"(t){var l,c;var e=t&&t.__createBinding||(Object.create?(function(f,d,p,y){y===void 0&&(y=p);var h=Object.getOwnPropertyDescriptor(d,p);(!h||("get"in h?!d.__esModule:h.writable||h.configurable))&&(h={enumerable:!0,get:s(function(){return d[p]},"get")}),Object.defineProperty(f,y,h)}):(function(f,d,p,y){y===void 0&&(y=p),f[y]=d[p]})),r=t&&t.__exportStar||function(f,d){for(var p in f)p!=="default"&&!Object.prototype.hasOwnProperty.call(d,p)&&e(d,f,p)};Object.defineProperty(t,"__esModule",{value:!0}),t.createMessageConnection=t.BrowserMessageWriter=t.BrowserMessageReader=void 0;var n=bk();n.default.install();var a=$m();r($m(),t);var i=(l=class extends a.AbstractMessageReader{constructor(d){super(),this._onData=new a.Emitter,this._messageListener=p=>{this._onData.fire(p.data)},d.addEventListener("error",p=>this.fireError(p)),d.onmessage=this._messageListener}listen(d){return this._onData.event(d)}},s(l,"BrowserMessageReader"),l);t.BrowserMessageReader=i;var o=(c=class extends a.AbstractMessageWriter{constructor(d){super(),this.port=d,this.errorCount=0,d.addEventListener("error",p=>this.fireError(p))}write(d){try{return this.port.postMessage(d),Promise.resolve()}catch(p){return this.handleError(p,d),Promise.reject(p)}}handleError(d,p){this.errorCount++,this.fireError(d,p,this.errorCount)}end(){}},s(c,"BrowserMessageWriter"),c);t.BrowserMessageWriter=o;function u(f,d,p,y){return p===void 0&&(p=a.NullLogger),a.ConnectionStrategy.is(y)&&(y={connectionStrategy:y}),(0,a.createMessageConnection)(f,d,p,y)}s(u,"createMessageConnection"),t.createMessageConnection=u}}),sv=X({"../../node_modules/.pnpm/vscode-jsonrpc@8.2.0/node_modules/vscode-jsonrpc/browser.js"(t,e){e.exports=il()}}),ke=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/messages.js"(t){var l,c,f,d,p;Object.defineProperty(t,"__esModule",{value:!0}),t.ProtocolNotificationType=t.ProtocolNotificationType0=t.ProtocolRequestType=t.ProtocolRequestType0=t.RegistrationType=t.MessageDirection=void 0;var e=il(),r;(function(y){y.clientToServer="clientToServer",y.serverToClient="serverToClient",y.both="both"})(r||(t.MessageDirection=r={}));var n=(l=class{constructor(h){this.method=h}},s(l,"RegistrationType"),l);t.RegistrationType=n;var a=(c=class extends e.RequestType0{constructor(h){super(h)}},s(c,"ProtocolRequestType0"),c);t.ProtocolRequestType0=a;var i=(f=class extends e.RequestType{constructor(h){super(h,e.ParameterStructures.byName)}},s(f,"ProtocolRequestType"),f);t.ProtocolRequestType=i;var o=(d=class extends e.NotificationType0{constructor(h){super(h)}},s(d,"ProtocolNotificationType0"),d);t.ProtocolNotificationType0=o;var u=(p=class extends e.NotificationType{constructor(h){super(h,e.ParameterStructures.byName)}},s(p,"ProtocolNotificationType"),p);t.ProtocolNotificationType=u}}),Eh=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/utils/is.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.objectLiteral=t.typedArray=t.stringArray=t.array=t.func=t.error=t.number=t.string=t.boolean=void 0;function e(f){return f===!0||f===!1}s(e,"boolean"),t.boolean=e;function r(f){return typeof f=="string"||f instanceof String}s(r,"string"),t.string=r;function n(f){return typeof f=="number"||f instanceof Number}s(n,"number"),t.number=n;function a(f){return f instanceof Error}s(a,"error"),t.error=a;function i(f){return typeof f=="function"}s(i,"func"),t.func=i;function o(f){return Array.isArray(f)}s(o,"array"),t.array=o;function u(f){return o(f)&&f.every(d=>r(d))}s(u,"stringArray"),t.stringArray=u;function l(f,d){return Array.isArray(f)&&f.every(d)}s(l,"typedArray"),t.typedArray=l;function c(f){return f!==null&&typeof f=="object"}s(c,"objectLiteral"),t.objectLiteral=c}}),_k=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.implementation.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.ImplementationRequest=void 0;var e=ke(),r;(function(n){n.method="textDocument/implementation",n.messageDirection=e.MessageDirection.clientToServer,n.type=new e.ProtocolRequestType(n.method)})(r||(t.ImplementationRequest=r={}))}}),Sk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.typeDefinition.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.TypeDefinitionRequest=void 0;var e=ke(),r;(function(n){n.method="textDocument/typeDefinition",n.messageDirection=e.MessageDirection.clientToServer,n.type=new e.ProtocolRequestType(n.method)})(r||(t.TypeDefinitionRequest=r={}))}}),wk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.workspaceFolder.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.DidChangeWorkspaceFoldersNotification=t.WorkspaceFoldersRequest=void 0;var e=ke(),r;(function(a){a.method="workspace/workspaceFolders",a.messageDirection=e.MessageDirection.serverToClient,a.type=new e.ProtocolRequestType0(a.method)})(r||(t.WorkspaceFoldersRequest=r={}));var n;(function(a){a.method="workspace/didChangeWorkspaceFolders",a.messageDirection=e.MessageDirection.clientToServer,a.type=new e.ProtocolNotificationType(a.method)})(n||(t.DidChangeWorkspaceFoldersNotification=n={}))}}),Ik=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.configuration.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.ConfigurationRequest=void 0;var e=ke(),r;(function(n){n.method="workspace/configuration",n.messageDirection=e.MessageDirection.serverToClient,n.type=new e.ProtocolRequestType(n.method)})(r||(t.ConfigurationRequest=r={}))}}),Nk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.colorProvider.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.ColorPresentationRequest=t.DocumentColorRequest=void 0;var e=ke(),r;(function(a){a.method="textDocument/documentColor",a.messageDirection=e.MessageDirection.clientToServer,a.type=new e.ProtocolRequestType(a.method)})(r||(t.DocumentColorRequest=r={}));var n;(function(a){a.method="textDocument/colorPresentation",a.messageDirection=e.MessageDirection.clientToServer,a.type=new e.ProtocolRequestType(a.method)})(n||(t.ColorPresentationRequest=n={}))}}),Pk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.foldingRange.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.FoldingRangeRefreshRequest=t.FoldingRangeRequest=void 0;var e=ke(),r;(function(a){a.method="textDocument/foldingRange",a.messageDirection=e.MessageDirection.clientToServer,a.type=new e.ProtocolRequestType(a.method)})(r||(t.FoldingRangeRequest=r={}));var n;(function(a){a.method="workspace/foldingRange/refresh",a.messageDirection=e.MessageDirection.serverToClient,a.type=new e.ProtocolRequestType0(a.method)})(n||(t.FoldingRangeRefreshRequest=n={}))}}),kk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.declaration.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.DeclarationRequest=void 0;var e=ke(),r;(function(n){n.method="textDocument/declaration",n.messageDirection=e.MessageDirection.clientToServer,n.type=new e.ProtocolRequestType(n.method)})(r||(t.DeclarationRequest=r={}))}}),Ok=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.selectionRange.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.SelectionRangeRequest=void 0;var e=ke(),r;(function(n){n.method="textDocument/selectionRange",n.messageDirection=e.MessageDirection.clientToServer,n.type=new e.ProtocolRequestType(n.method)})(r||(t.SelectionRangeRequest=r={}))}}),Lk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.progress.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.WorkDoneProgressCancelNotification=t.WorkDoneProgressCreateRequest=t.WorkDoneProgress=void 0;var e=il(),r=ke(),n;(function(o){o.type=new e.ProgressType;function u(l){return l===o.type}s(u,"is"),o.is=u})(n||(t.WorkDoneProgress=n={}));var a;(function(o){o.method="window/workDoneProgress/create",o.messageDirection=r.MessageDirection.serverToClient,o.type=new r.ProtocolRequestType(o.method)})(a||(t.WorkDoneProgressCreateRequest=a={}));var i;(function(o){o.method="window/workDoneProgress/cancel",o.messageDirection=r.MessageDirection.clientToServer,o.type=new r.ProtocolNotificationType(o.method)})(i||(t.WorkDoneProgressCancelNotification=i={}))}}),Dk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.callHierarchy.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.CallHierarchyOutgoingCallsRequest=t.CallHierarchyIncomingCallsRequest=t.CallHierarchyPrepareRequest=void 0;var e=ke(),r;(function(i){i.method="textDocument/prepareCallHierarchy",i.messageDirection=e.MessageDirection.clientToServer,i.type=new e.ProtocolRequestType(i.method)})(r||(t.CallHierarchyPrepareRequest=r={}));var n;(function(i){i.method="callHierarchy/incomingCalls",i.messageDirection=e.MessageDirection.clientToServer,i.type=new e.ProtocolRequestType(i.method)})(n||(t.CallHierarchyIncomingCallsRequest=n={}));var a;(function(i){i.method="callHierarchy/outgoingCalls",i.messageDirection=e.MessageDirection.clientToServer,i.type=new e.ProtocolRequestType(i.method)})(a||(t.CallHierarchyOutgoingCallsRequest=a={}))}}),xk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.semanticTokens.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.SemanticTokensRefreshRequest=t.SemanticTokensRangeRequest=t.SemanticTokensDeltaRequest=t.SemanticTokensRequest=t.SemanticTokensRegistrationType=t.TokenFormat=void 0;var e=ke(),r;(function(l){l.Relative="relative"})(r||(t.TokenFormat=r={}));var n;(function(l){l.method="textDocument/semanticTokens",l.type=new e.RegistrationType(l.method)})(n||(t.SemanticTokensRegistrationType=n={}));var a;(function(l){l.method="textDocument/semanticTokens/full",l.messageDirection=e.MessageDirection.clientToServer,l.type=new e.ProtocolRequestType(l.method),l.registrationMethod=n.method})(a||(t.SemanticTokensRequest=a={}));var i;(function(l){l.method="textDocument/semanticTokens/full/delta",l.messageDirection=e.MessageDirection.clientToServer,l.type=new e.ProtocolRequestType(l.method),l.registrationMethod=n.method})(i||(t.SemanticTokensDeltaRequest=i={}));var o;(function(l){l.method="textDocument/semanticTokens/range",l.messageDirection=e.MessageDirection.clientToServer,l.type=new e.ProtocolRequestType(l.method),l.registrationMethod=n.method})(o||(t.SemanticTokensRangeRequest=o={}));var u;(function(l){l.method="workspace/semanticTokens/refresh",l.messageDirection=e.MessageDirection.serverToClient,l.type=new e.ProtocolRequestType0(l.method)})(u||(t.SemanticTokensRefreshRequest=u={}))}}),Mk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.showDocument.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.ShowDocumentRequest=void 0;var e=ke(),r;(function(n){n.method="window/showDocument",n.messageDirection=e.MessageDirection.serverToClient,n.type=new e.ProtocolRequestType(n.method)})(r||(t.ShowDocumentRequest=r={}))}}),Gk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.linkedEditingRange.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.LinkedEditingRangeRequest=void 0;var e=ke(),r;(function(n){n.method="textDocument/linkedEditingRange",n.messageDirection=e.MessageDirection.clientToServer,n.type=new e.ProtocolRequestType(n.method)})(r||(t.LinkedEditingRangeRequest=r={}))}}),Fk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.fileOperations.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.WillDeleteFilesRequest=t.DidDeleteFilesNotification=t.DidRenameFilesNotification=t.WillRenameFilesRequest=t.DidCreateFilesNotification=t.WillCreateFilesRequest=t.FileOperationPatternKind=void 0;var e=ke(),r;(function(c){c.file="file",c.folder="folder"})(r||(t.FileOperationPatternKind=r={}));var n;(function(c){c.method="workspace/willCreateFiles",c.messageDirection=e.MessageDirection.clientToServer,c.type=new e.ProtocolRequestType(c.method)})(n||(t.WillCreateFilesRequest=n={}));var a;(function(c){c.method="workspace/didCreateFiles",c.messageDirection=e.MessageDirection.clientToServer,c.type=new e.ProtocolNotificationType(c.method)})(a||(t.DidCreateFilesNotification=a={}));var i;(function(c){c.method="workspace/willRenameFiles",c.messageDirection=e.MessageDirection.clientToServer,c.type=new e.ProtocolRequestType(c.method)})(i||(t.WillRenameFilesRequest=i={}));var o;(function(c){c.method="workspace/didRenameFiles",c.messageDirection=e.MessageDirection.clientToServer,c.type=new e.ProtocolNotificationType(c.method)})(o||(t.DidRenameFilesNotification=o={}));var u;(function(c){c.method="workspace/didDeleteFiles",c.messageDirection=e.MessageDirection.clientToServer,c.type=new e.ProtocolNotificationType(c.method)})(u||(t.DidDeleteFilesNotification=u={}));var l;(function(c){c.method="workspace/willDeleteFiles",c.messageDirection=e.MessageDirection.clientToServer,c.type=new e.ProtocolRequestType(c.method)})(l||(t.WillDeleteFilesRequest=l={}))}}),zk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.moniker.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.MonikerRequest=t.MonikerKind=t.UniquenessLevel=void 0;var e=ke(),r;(function(i){i.document="document",i.project="project",i.group="group",i.scheme="scheme",i.global="global"})(r||(t.UniquenessLevel=r={}));var n;(function(i){i.$import="import",i.$export="export",i.local="local"})(n||(t.MonikerKind=n={}));var a;(function(i){i.method="textDocument/moniker",i.messageDirection=e.MessageDirection.clientToServer,i.type=new e.ProtocolRequestType(i.method)})(a||(t.MonikerRequest=a={}))}}),jk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.typeHierarchy.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.TypeHierarchySubtypesRequest=t.TypeHierarchySupertypesRequest=t.TypeHierarchyPrepareRequest=void 0;var e=ke(),r;(function(i){i.method="textDocument/prepareTypeHierarchy",i.messageDirection=e.MessageDirection.clientToServer,i.type=new e.ProtocolRequestType(i.method)})(r||(t.TypeHierarchyPrepareRequest=r={}));var n;(function(i){i.method="typeHierarchy/supertypes",i.messageDirection=e.MessageDirection.clientToServer,i.type=new e.ProtocolRequestType(i.method)})(n||(t.TypeHierarchySupertypesRequest=n={}));var a;(function(i){i.method="typeHierarchy/subtypes",i.messageDirection=e.MessageDirection.clientToServer,i.type=new e.ProtocolRequestType(i.method)})(a||(t.TypeHierarchySubtypesRequest=a={}))}}),Bk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.inlineValue.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.InlineValueRefreshRequest=t.InlineValueRequest=void 0;var e=ke(),r;(function(a){a.method="textDocument/inlineValue",a.messageDirection=e.MessageDirection.clientToServer,a.type=new e.ProtocolRequestType(a.method)})(r||(t.InlineValueRequest=r={}));var n;(function(a){a.method="workspace/inlineValue/refresh",a.messageDirection=e.MessageDirection.serverToClient,a.type=new e.ProtocolRequestType0(a.method)})(n||(t.InlineValueRefreshRequest=n={}))}}),Uk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.inlayHint.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.InlayHintRefreshRequest=t.InlayHintResolveRequest=t.InlayHintRequest=void 0;var e=ke(),r;(function(i){i.method="textDocument/inlayHint",i.messageDirection=e.MessageDirection.clientToServer,i.type=new e.ProtocolRequestType(i.method)})(r||(t.InlayHintRequest=r={}));var n;(function(i){i.method="inlayHint/resolve",i.messageDirection=e.MessageDirection.clientToServer,i.type=new e.ProtocolRequestType(i.method)})(n||(t.InlayHintResolveRequest=n={}));var a;(function(i){i.method="workspace/inlayHint/refresh",i.messageDirection=e.MessageDirection.serverToClient,i.type=new e.ProtocolRequestType0(i.method)})(a||(t.InlayHintRefreshRequest=a={}))}}),Kk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.diagnostic.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.DiagnosticRefreshRequest=t.WorkspaceDiagnosticRequest=t.DocumentDiagnosticRequest=t.DocumentDiagnosticReportKind=t.DiagnosticServerCancellationData=void 0;var e=il(),r=Eh(),n=ke(),a;(function(c){function f(d){const p=d;return p&&r.boolean(p.retriggerRequest)}s(f,"is"),c.is=f})(a||(t.DiagnosticServerCancellationData=a={}));var i;(function(c){c.Full="full",c.Unchanged="unchanged"})(i||(t.DocumentDiagnosticReportKind=i={}));var o;(function(c){c.method="textDocument/diagnostic",c.messageDirection=n.MessageDirection.clientToServer,c.type=new n.ProtocolRequestType(c.method),c.partialResult=new e.ProgressType})(o||(t.DocumentDiagnosticRequest=o={}));var u;(function(c){c.method="workspace/diagnostic",c.messageDirection=n.MessageDirection.clientToServer,c.type=new n.ProtocolRequestType(c.method),c.partialResult=new e.ProgressType})(u||(t.WorkspaceDiagnosticRequest=u={}));var l;(function(c){c.method="workspace/diagnostic/refresh",c.messageDirection=n.MessageDirection.serverToClient,c.type=new n.ProtocolRequestType0(c.method)})(l||(t.DiagnosticRefreshRequest=l={}))}}),Wk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.notebook.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.DidCloseNotebookDocumentNotification=t.DidSaveNotebookDocumentNotification=t.DidChangeNotebookDocumentNotification=t.NotebookCellArrayChange=t.DidOpenNotebookDocumentNotification=t.NotebookDocumentSyncRegistrationType=t.NotebookDocument=t.NotebookCell=t.ExecutionSummary=t.NotebookCellKind=void 0;var e=(xu(),Ah(Lf)),r=Eh(),n=ke(),a;(function(h){h.Markup=1,h.Code=2;function $(C){return C===1||C===2}s($,"is"),h.is=$})(a||(t.NotebookCellKind=a={}));var i;(function(h){function $(w,b){const N={executionOrder:w};return(b===!0||b===!1)&&(N.success=b),N}s($,"create"),h.create=$;function C(w){const b=w;return r.objectLiteral(b)&&e.uinteger.is(b.executionOrder)&&(b.success===void 0||r.boolean(b.success))}s(C,"is"),h.is=C;function T(w,b){return w===b?!0:w==null||b===null||b===void 0?!1:w.executionOrder===b.executionOrder&&w.success===b.success}s(T,"equals"),h.equals=T})(i||(t.ExecutionSummary=i={}));var o;(function(h){function $(b,N){return{kind:b,document:N}}s($,"create"),h.create=$;function C(b){const N=b;return r.objectLiteral(N)&&a.is(N.kind)&&e.DocumentUri.is(N.document)&&(N.metadata===void 0||r.objectLiteral(N.metadata))}s(C,"is"),h.is=C;function T(b,N){const B=new Set;return b.document!==N.document&&B.add("document"),b.kind!==N.kind&&B.add("kind"),b.executionSummary!==N.executionSummary&&B.add("executionSummary"),(b.metadata!==void 0||N.metadata!==void 0)&&!w(b.metadata,N.metadata)&&B.add("metadata"),(b.executionSummary!==void 0||N.executionSummary!==void 0)&&!i.equals(b.executionSummary,N.executionSummary)&&B.add("executionSummary"),B}s(T,"diff"),h.diff=T;function w(b,N){if(b===N)return!0;if(b==null||N===null||N===void 0||typeof b!=typeof N||typeof b!="object")return!1;const B=Array.isArray(b),ne=Array.isArray(N);if(B!==ne)return!1;if(B&&ne){if(b.length!==N.length)return!1;for(let J=0;J<b.length;J++)if(!w(b[J],N[J]))return!1}if(r.objectLiteral(b)&&r.objectLiteral(N)){const J=Object.keys(b),he=Object.keys(N);if(J.length!==he.length||(J.sort(),he.sort(),!w(J,he)))return!1;for(let Ae=0;Ae<J.length;Ae++){const ye=J[Ae];if(!w(b[ye],N[ye]))return!1}}return!0}s(w,"equalsMetadata")})(o||(t.NotebookCell=o={}));var u;(function(h){function $(T,w,b,N){return{uri:T,notebookType:w,version:b,cells:N}}s($,"create"),h.create=$;function C(T){const w=T;return r.objectLiteral(w)&&r.string(w.uri)&&e.integer.is(w.version)&&r.typedArray(w.cells,o.is)}s(C,"is"),h.is=C})(u||(t.NotebookDocument=u={}));var l;(function(h){h.method="notebookDocument/sync",h.messageDirection=n.MessageDirection.clientToServer,h.type=new n.RegistrationType(h.method)})(l||(t.NotebookDocumentSyncRegistrationType=l={}));var c;(function(h){h.method="notebookDocument/didOpen",h.messageDirection=n.MessageDirection.clientToServer,h.type=new n.ProtocolNotificationType(h.method),h.registrationMethod=l.method})(c||(t.DidOpenNotebookDocumentNotification=c={}));var f;(function(h){function $(T){const w=T;return r.objectLiteral(w)&&e.uinteger.is(w.start)&&e.uinteger.is(w.deleteCount)&&(w.cells===void 0||r.typedArray(w.cells,o.is))}s($,"is"),h.is=$;function C(T,w,b){const N={start:T,deleteCount:w};return b!==void 0&&(N.cells=b),N}s(C,"create"),h.create=C})(f||(t.NotebookCellArrayChange=f={}));var d;(function(h){h.method="notebookDocument/didChange",h.messageDirection=n.MessageDirection.clientToServer,h.type=new n.ProtocolNotificationType(h.method),h.registrationMethod=l.method})(d||(t.DidChangeNotebookDocumentNotification=d={}));var p;(function(h){h.method="notebookDocument/didSave",h.messageDirection=n.MessageDirection.clientToServer,h.type=new n.ProtocolNotificationType(h.method),h.registrationMethod=l.method})(p||(t.DidSaveNotebookDocumentNotification=p={}));var y;(function(h){h.method="notebookDocument/didClose",h.messageDirection=n.MessageDirection.clientToServer,h.type=new n.ProtocolNotificationType(h.method),h.registrationMethod=l.method})(y||(t.DidCloseNotebookDocumentNotification=y={}))}}),Vk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.inlineCompletion.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.InlineCompletionRequest=void 0;var e=ke(),r;(function(n){n.method="textDocument/inlineCompletion",n.messageDirection=e.MessageDirection.clientToServer,n.type=new e.ProtocolRequestType(n.method)})(r||(t.InlineCompletionRequest=r={}))}}),qk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/protocol.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.WorkspaceSymbolRequest=t.CodeActionResolveRequest=t.CodeActionRequest=t.DocumentSymbolRequest=t.DocumentHighlightRequest=t.ReferencesRequest=t.DefinitionRequest=t.SignatureHelpRequest=t.SignatureHelpTriggerKind=t.HoverRequest=t.CompletionResolveRequest=t.CompletionRequest=t.CompletionTriggerKind=t.PublishDiagnosticsNotification=t.WatchKind=t.RelativePattern=t.FileChangeType=t.DidChangeWatchedFilesNotification=t.WillSaveTextDocumentWaitUntilRequest=t.WillSaveTextDocumentNotification=t.TextDocumentSaveReason=t.DidSaveTextDocumentNotification=t.DidCloseTextDocumentNotification=t.DidChangeTextDocumentNotification=t.TextDocumentContentChangeEvent=t.DidOpenTextDocumentNotification=t.TextDocumentSyncKind=t.TelemetryEventNotification=t.LogMessageNotification=t.ShowMessageRequest=t.ShowMessageNotification=t.MessageType=t.DidChangeConfigurationNotification=t.ExitNotification=t.ShutdownRequest=t.InitializedNotification=t.InitializeErrorCodes=t.InitializeRequest=t.WorkDoneProgressOptions=t.TextDocumentRegistrationOptions=t.StaticRegistrationOptions=t.PositionEncodingKind=t.FailureHandlingKind=t.ResourceOperationKind=t.UnregistrationRequest=t.RegistrationRequest=t.DocumentSelector=t.NotebookCellTextDocumentFilter=t.NotebookDocumentFilter=t.TextDocumentFilter=void 0,t.MonikerRequest=t.MonikerKind=t.UniquenessLevel=t.WillDeleteFilesRequest=t.DidDeleteFilesNotification=t.WillRenameFilesRequest=t.DidRenameFilesNotification=t.WillCreateFilesRequest=t.DidCreateFilesNotification=t.FileOperationPatternKind=t.LinkedEditingRangeRequest=t.ShowDocumentRequest=t.SemanticTokensRegistrationType=t.SemanticTokensRefreshRequest=t.SemanticTokensRangeRequest=t.SemanticTokensDeltaRequest=t.SemanticTokensRequest=t.TokenFormat=t.CallHierarchyPrepareRequest=t.CallHierarchyOutgoingCallsRequest=t.CallHierarchyIncomingCallsRequest=t.WorkDoneProgressCancelNotification=t.WorkDoneProgressCreateRequest=t.WorkDoneProgress=t.SelectionRangeRequest=t.DeclarationRequest=t.FoldingRangeRefreshRequest=t.FoldingRangeRequest=t.ColorPresentationRequest=t.DocumentColorRequest=t.ConfigurationRequest=t.DidChangeWorkspaceFoldersNotification=t.WorkspaceFoldersRequest=t.TypeDefinitionRequest=t.ImplementationRequest=t.ApplyWorkspaceEditRequest=t.ExecuteCommandRequest=t.PrepareRenameRequest=t.RenameRequest=t.PrepareSupportDefaultBehavior=t.DocumentOnTypeFormattingRequest=t.DocumentRangesFormattingRequest=t.DocumentRangeFormattingRequest=t.DocumentFormattingRequest=t.DocumentLinkResolveRequest=t.DocumentLinkRequest=t.CodeLensRefreshRequest=t.CodeLensResolveRequest=t.CodeLensRequest=t.WorkspaceSymbolResolveRequest=void 0,t.InlineCompletionRequest=t.DidCloseNotebookDocumentNotification=t.DidSaveNotebookDocumentNotification=t.DidChangeNotebookDocumentNotification=t.NotebookCellArrayChange=t.DidOpenNotebookDocumentNotification=t.NotebookDocumentSyncRegistrationType=t.NotebookDocument=t.NotebookCell=t.ExecutionSummary=t.NotebookCellKind=t.DiagnosticRefreshRequest=t.WorkspaceDiagnosticRequest=t.DocumentDiagnosticRequest=t.DocumentDiagnosticReportKind=t.DiagnosticServerCancellationData=t.InlayHintRefreshRequest=t.InlayHintResolveRequest=t.InlayHintRequest=t.InlineValueRefreshRequest=t.InlineValueRequest=t.TypeHierarchySupertypesRequest=t.TypeHierarchySubtypesRequest=t.TypeHierarchyPrepareRequest=void 0;var e=ke(),r=(xu(),Ah(Lf)),n=Eh(),a=_k();Object.defineProperty(t,"ImplementationRequest",{enumerable:!0,get:s(function(){return a.ImplementationRequest},"get")});var i=Sk();Object.defineProperty(t,"TypeDefinitionRequest",{enumerable:!0,get:s(function(){return i.TypeDefinitionRequest},"get")});var o=wk();Object.defineProperty(t,"WorkspaceFoldersRequest",{enumerable:!0,get:s(function(){return o.WorkspaceFoldersRequest},"get")}),Object.defineProperty(t,"DidChangeWorkspaceFoldersNotification",{enumerable:!0,get:s(function(){return o.DidChangeWorkspaceFoldersNotification},"get")});var u=Ik();Object.defineProperty(t,"ConfigurationRequest",{enumerable:!0,get:s(function(){return u.ConfigurationRequest},"get")});var l=Nk();Object.defineProperty(t,"DocumentColorRequest",{enumerable:!0,get:s(function(){return l.DocumentColorRequest},"get")}),Object.defineProperty(t,"ColorPresentationRequest",{enumerable:!0,get:s(function(){return l.ColorPresentationRequest},"get")});var c=Pk();Object.defineProperty(t,"FoldingRangeRequest",{enumerable:!0,get:s(function(){return c.FoldingRangeRequest},"get")}),Object.defineProperty(t,"FoldingRangeRefreshRequest",{enumerable:!0,get:s(function(){return c.FoldingRangeRefreshRequest},"get")});var f=kk();Object.defineProperty(t,"DeclarationRequest",{enumerable:!0,get:s(function(){return f.DeclarationRequest},"get")});var d=Ok();Object.defineProperty(t,"SelectionRangeRequest",{enumerable:!0,get:s(function(){return d.SelectionRangeRequest},"get")});var p=Lk();Object.defineProperty(t,"WorkDoneProgress",{enumerable:!0,get:s(function(){return p.WorkDoneProgress},"get")}),Object.defineProperty(t,"WorkDoneProgressCreateRequest",{enumerable:!0,get:s(function(){return p.WorkDoneProgressCreateRequest},"get")}),Object.defineProperty(t,"WorkDoneProgressCancelNotification",{enumerable:!0,get:s(function(){return p.WorkDoneProgressCancelNotification},"get")});var y=Dk();Object.defineProperty(t,"CallHierarchyIncomingCallsRequest",{enumerable:!0,get:s(function(){return y.CallHierarchyIncomingCallsRequest},"get")}),Object.defineProperty(t,"CallHierarchyOutgoingCallsRequest",{enumerable:!0,get:s(function(){return y.CallHierarchyOutgoingCallsRequest},"get")}),Object.defineProperty(t,"CallHierarchyPrepareRequest",{enumerable:!0,get:s(function(){return y.CallHierarchyPrepareRequest},"get")});var h=xk();Object.defineProperty(t,"TokenFormat",{enumerable:!0,get:s(function(){return h.TokenFormat},"get")}),Object.defineProperty(t,"SemanticTokensRequest",{enumerable:!0,get:s(function(){return h.SemanticTokensRequest},"get")}),Object.defineProperty(t,"SemanticTokensDeltaRequest",{enumerable:!0,get:s(function(){return h.SemanticTokensDeltaRequest},"get")}),Object.defineProperty(t,"SemanticTokensRangeRequest",{enumerable:!0,get:s(function(){return h.SemanticTokensRangeRequest},"get")}),Object.defineProperty(t,"SemanticTokensRefreshRequest",{enumerable:!0,get:s(function(){return h.SemanticTokensRefreshRequest},"get")}),Object.defineProperty(t,"SemanticTokensRegistrationType",{enumerable:!0,get:s(function(){return h.SemanticTokensRegistrationType},"get")});var $=Mk();Object.defineProperty(t,"ShowDocumentRequest",{enumerable:!0,get:s(function(){return $.ShowDocumentRequest},"get")});var C=Gk();Object.defineProperty(t,"LinkedEditingRangeRequest",{enumerable:!0,get:s(function(){return C.LinkedEditingRangeRequest},"get")});var T=Fk();Object.defineProperty(t,"FileOperationPatternKind",{enumerable:!0,get:s(function(){return T.FileOperationPatternKind},"get")}),Object.defineProperty(t,"DidCreateFilesNotification",{enumerable:!0,get:s(function(){return T.DidCreateFilesNotification},"get")}),Object.defineProperty(t,"WillCreateFilesRequest",{enumerable:!0,get:s(function(){return T.WillCreateFilesRequest},"get")}),Object.defineProperty(t,"DidRenameFilesNotification",{enumerable:!0,get:s(function(){return T.DidRenameFilesNotification},"get")}),Object.defineProperty(t,"WillRenameFilesRequest",{enumerable:!0,get:s(function(){return T.WillRenameFilesRequest},"get")}),Object.defineProperty(t,"DidDeleteFilesNotification",{enumerable:!0,get:s(function(){return T.DidDeleteFilesNotification},"get")}),Object.defineProperty(t,"WillDeleteFilesRequest",{enumerable:!0,get:s(function(){return T.WillDeleteFilesRequest},"get")});var w=zk();Object.defineProperty(t,"UniquenessLevel",{enumerable:!0,get:s(function(){return w.UniquenessLevel},"get")}),Object.defineProperty(t,"MonikerKind",{enumerable:!0,get:s(function(){return w.MonikerKind},"get")}),Object.defineProperty(t,"MonikerRequest",{enumerable:!0,get:s(function(){return w.MonikerRequest},"get")});var b=jk();Object.defineProperty(t,"TypeHierarchyPrepareRequest",{enumerable:!0,get:s(function(){return b.TypeHierarchyPrepareRequest},"get")}),Object.defineProperty(t,"TypeHierarchySubtypesRequest",{enumerable:!0,get:s(function(){return b.TypeHierarchySubtypesRequest},"get")}),Object.defineProperty(t,"TypeHierarchySupertypesRequest",{enumerable:!0,get:s(function(){return b.TypeHierarchySupertypesRequest},"get")});var N=Bk();Object.defineProperty(t,"InlineValueRequest",{enumerable:!0,get:s(function(){return N.InlineValueRequest},"get")}),Object.defineProperty(t,"InlineValueRefreshRequest",{enumerable:!0,get:s(function(){return N.InlineValueRefreshRequest},"get")});var B=Uk();Object.defineProperty(t,"InlayHintRequest",{enumerable:!0,get:s(function(){return B.InlayHintRequest},"get")}),Object.defineProperty(t,"InlayHintResolveRequest",{enumerable:!0,get:s(function(){return B.InlayHintResolveRequest},"get")}),Object.defineProperty(t,"InlayHintRefreshRequest",{enumerable:!0,get:s(function(){return B.InlayHintRefreshRequest},"get")});var ne=Kk();Object.defineProperty(t,"DiagnosticServerCancellationData",{enumerable:!0,get:s(function(){return ne.DiagnosticServerCancellationData},"get")}),Object.defineProperty(t,"DocumentDiagnosticReportKind",{enumerable:!0,get:s(function(){return ne.DocumentDiagnosticReportKind},"get")}),Object.defineProperty(t,"DocumentDiagnosticRequest",{enumerable:!0,get:s(function(){return ne.DocumentDiagnosticRequest},"get")}),Object.defineProperty(t,"WorkspaceDiagnosticRequest",{enumerable:!0,get:s(function(){return ne.WorkspaceDiagnosticRequest},"get")}),Object.defineProperty(t,"DiagnosticRefreshRequest",{enumerable:!0,get:s(function(){return ne.DiagnosticRefreshRequest},"get")});var J=Wk();Object.defineProperty(t,"NotebookCellKind",{enumerable:!0,get:s(function(){return J.NotebookCellKind},"get")}),Object.defineProperty(t,"ExecutionSummary",{enumerable:!0,get:s(function(){return J.ExecutionSummary},"get")}),Object.defineProperty(t,"NotebookCell",{enumerable:!0,get:s(function(){return J.NotebookCell},"get")}),Object.defineProperty(t,"NotebookDocument",{enumerable:!0,get:s(function(){return J.NotebookDocument},"get")}),Object.defineProperty(t,"NotebookDocumentSyncRegistrationType",{enumerable:!0,get:s(function(){return J.NotebookDocumentSyncRegistrationType},"get")}),Object.defineProperty(t,"DidOpenNotebookDocumentNotification",{enumerable:!0,get:s(function(){return J.DidOpenNotebookDocumentNotification},"get")}),Object.defineProperty(t,"NotebookCellArrayChange",{enumerable:!0,get:s(function(){return J.NotebookCellArrayChange},"get")}),Object.defineProperty(t,"DidChangeNotebookDocumentNotification",{enumerable:!0,get:s(function(){return J.DidChangeNotebookDocumentNotification},"get")}),Object.defineProperty(t,"DidSaveNotebookDocumentNotification",{enumerable:!0,get:s(function(){return J.DidSaveNotebookDocumentNotification},"get")}),Object.defineProperty(t,"DidCloseNotebookDocumentNotification",{enumerable:!0,get:s(function(){return J.DidCloseNotebookDocumentNotification},"get")});var he=Vk();Object.defineProperty(t,"InlineCompletionRequest",{enumerable:!0,get:s(function(){return he.InlineCompletionRequest},"get")});var Ae;(function(m){function le(we){const H=we;return n.string(H)||n.string(H.language)||n.string(H.scheme)||n.string(H.pattern)}s(le,"is"),m.is=le})(Ae||(t.TextDocumentFilter=Ae={}));var ye;(function(m){function le(we){const H=we;return n.objectLiteral(H)&&(n.string(H.notebookType)||n.string(H.scheme)||n.string(H.pattern))}s(le,"is"),m.is=le})(ye||(t.NotebookDocumentFilter=ye={}));var ue;(function(m){function le(we){const H=we;return n.objectLiteral(H)&&(n.string(H.notebook)||ye.is(H.notebook))&&(H.language===void 0||n.string(H.language))}s(le,"is"),m.is=le})(ue||(t.NotebookCellTextDocumentFilter=ue={}));var ot;(function(m){function le(we){if(!Array.isArray(we))return!1;for(let H of we)if(!n.string(H)&&!Ae.is(H)&&!ue.is(H))return!1;return!0}s(le,"is"),m.is=le})(ot||(t.DocumentSelector=ot={}));var k;(function(m){m.method="client/registerCapability",m.messageDirection=e.MessageDirection.serverToClient,m.type=new e.ProtocolRequestType(m.method)})(k||(t.RegistrationRequest=k={}));var _;(function(m){m.method="client/unregisterCapability",m.messageDirection=e.MessageDirection.serverToClient,m.type=new e.ProtocolRequestType(m.method)})(_||(t.UnregistrationRequest=_={}));var v;(function(m){m.Create="create",m.Rename="rename",m.Delete="delete"})(v||(t.ResourceOperationKind=v={}));var I;(function(m){m.Abort="abort",m.Transactional="transactional",m.TextOnlyTransactional="textOnlyTransactional",m.Undo="undo"})(I||(t.FailureHandlingKind=I={}));var R;(function(m){m.UTF8="utf-8",m.UTF16="utf-16",m.UTF32="utf-32"})(R||(t.PositionEncodingKind=R={}));var A;(function(m){function le(we){const H=we;return H&&n.string(H.id)&&H.id.length>0}s(le,"hasId"),m.hasId=le})(A||(t.StaticRegistrationOptions=A={}));var S;(function(m){function le(we){const H=we;return H&&(H.documentSelector===null||ot.is(H.documentSelector))}s(le,"is"),m.is=le})(S||(t.TextDocumentRegistrationOptions=S={}));var L;(function(m){function le(H){const Ie=H;return n.objectLiteral(Ie)&&(Ie.workDoneProgress===void 0||n.boolean(Ie.workDoneProgress))}s(le,"is"),m.is=le;function we(H){const Ie=H;return Ie&&n.boolean(Ie.workDoneProgress)}s(we,"hasWorkDoneProgress"),m.hasWorkDoneProgress=we})(L||(t.WorkDoneProgressOptions=L={}));var x;(function(m){m.method="initialize",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(x||(t.InitializeRequest=x={}));var O;(function(m){m.unknownProtocolVersion=1})(O||(t.InitializeErrorCodes=O={}));var z;(function(m){m.method="initialized",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolNotificationType(m.method)})(z||(t.InitializedNotification=z={}));var M;(function(m){m.method="shutdown",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType0(m.method)})(M||(t.ShutdownRequest=M={}));var Y;(function(m){m.method="exit",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolNotificationType0(m.method)})(Y||(t.ExitNotification=Y={}));var q;(function(m){m.method="workspace/didChangeConfiguration",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolNotificationType(m.method)})(q||(t.DidChangeConfigurationNotification=q={}));var Z;(function(m){m.Error=1,m.Warning=2,m.Info=3,m.Log=4,m.Debug=5})(Z||(t.MessageType=Z={}));var ae;(function(m){m.method="window/showMessage",m.messageDirection=e.MessageDirection.serverToClient,m.type=new e.ProtocolNotificationType(m.method)})(ae||(t.ShowMessageNotification=ae={}));var Oe;(function(m){m.method="window/showMessageRequest",m.messageDirection=e.MessageDirection.serverToClient,m.type=new e.ProtocolRequestType(m.method)})(Oe||(t.ShowMessageRequest=Oe={}));var pe;(function(m){m.method="window/logMessage",m.messageDirection=e.MessageDirection.serverToClient,m.type=new e.ProtocolNotificationType(m.method)})(pe||(t.LogMessageNotification=pe={}));var Ee;(function(m){m.method="telemetry/event",m.messageDirection=e.MessageDirection.serverToClient,m.type=new e.ProtocolNotificationType(m.method)})(Ee||(t.TelemetryEventNotification=Ee={}));var Ve;(function(m){m.None=0,m.Full=1,m.Incremental=2})(Ve||(t.TextDocumentSyncKind=Ve={}));var Le;(function(m){m.method="textDocument/didOpen",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolNotificationType(m.method)})(Le||(t.DidOpenTextDocumentNotification=Le={}));var ee;(function(m){function le(H){let Ie=H;return Ie!=null&&typeof Ie.text=="string"&&Ie.range!==void 0&&(Ie.rangeLength===void 0||typeof Ie.rangeLength=="number")}s(le,"isIncremental"),m.isIncremental=le;function we(H){let Ie=H;return Ie!=null&&typeof Ie.text=="string"&&Ie.range===void 0&&Ie.rangeLength===void 0}s(we,"isFull"),m.isFull=we})(ee||(t.TextDocumentContentChangeEvent=ee={}));var Qe;(function(m){m.method="textDocument/didChange",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolNotificationType(m.method)})(Qe||(t.DidChangeTextDocumentNotification=Qe={}));var ce;(function(m){m.method="textDocument/didClose",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolNotificationType(m.method)})(ce||(t.DidCloseTextDocumentNotification=ce={}));var qe;(function(m){m.method="textDocument/didSave",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolNotificationType(m.method)})(qe||(t.DidSaveTextDocumentNotification=qe={}));var ge;(function(m){m.Manual=1,m.AfterDelay=2,m.FocusOut=3})(ge||(t.TextDocumentSaveReason=ge={}));var G;(function(m){m.method="textDocument/willSave",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolNotificationType(m.method)})(G||(t.WillSaveTextDocumentNotification=G={}));var je;(function(m){m.method="textDocument/willSaveWaitUntil",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(je||(t.WillSaveTextDocumentWaitUntilRequest=je={}));var Qt;(function(m){m.method="workspace/didChangeWatchedFiles",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolNotificationType(m.method)})(Qt||(t.DidChangeWatchedFilesNotification=Qt={}));var Dt;(function(m){m.Created=1,m.Changed=2,m.Deleted=3})(Dt||(t.FileChangeType=Dt={}));var ve;(function(m){function le(we){const H=we;return n.objectLiteral(H)&&(r.URI.is(H.baseUri)||r.WorkspaceFolder.is(H.baseUri))&&n.string(H.pattern)}s(le,"is"),m.is=le})(ve||(t.RelativePattern=ve={}));var pa;(function(m){m.Create=1,m.Change=2,m.Delete=4})(pa||(t.WatchKind=pa={}));var hl;(function(m){m.method="textDocument/publishDiagnostics",m.messageDirection=e.MessageDirection.serverToClient,m.type=new e.ProtocolNotificationType(m.method)})(hl||(t.PublishDiagnosticsNotification=hl={}));var yl;(function(m){m.Invoked=1,m.TriggerCharacter=2,m.TriggerForIncompleteCompletions=3})(yl||(t.CompletionTriggerKind=yl={}));var gl;(function(m){m.method="textDocument/completion",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(gl||(t.CompletionRequest=gl={}));var vl;(function(m){m.method="completionItem/resolve",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(vl||(t.CompletionResolveRequest=vl={}));var ma;(function(m){m.method="textDocument/hover",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(ma||(t.HoverRequest=ma={}));var ha;(function(m){m.Invoked=1,m.TriggerCharacter=2,m.ContentChange=3})(ha||(t.SignatureHelpTriggerKind=ha={}));var er;(function(m){m.method="textDocument/signatureHelp",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(er||(t.SignatureHelpRequest=er={}));var ya;(function(m){m.method="textDocument/definition",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(ya||(t.DefinitionRequest=ya={}));var Tl;(function(m){m.method="textDocument/references",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(Tl||(t.ReferencesRequest=Tl={}));var $l;(function(m){m.method="textDocument/documentHighlight",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})($l||(t.DocumentHighlightRequest=$l={}));var ga;(function(m){m.method="textDocument/documentSymbol",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(ga||(t.DocumentSymbolRequest=ga={}));var va;(function(m){m.method="textDocument/codeAction",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(va||(t.CodeActionRequest=va={}));var Rl;(function(m){m.method="codeAction/resolve",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(Rl||(t.CodeActionResolveRequest=Rl={}));var nc;(function(m){m.method="workspace/symbol",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(nc||(t.WorkspaceSymbolRequest=nc={}));var Al;(function(m){m.method="workspaceSymbol/resolve",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(Al||(t.WorkspaceSymbolResolveRequest=Al={}));var El;(function(m){m.method="textDocument/codeLens",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(El||(t.CodeLensRequest=El={}));var Cl;(function(m){m.method="codeLens/resolve",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(Cl||(t.CodeLensResolveRequest=Cl={}));var bl;(function(m){m.method="workspace/codeLens/refresh",m.messageDirection=e.MessageDirection.serverToClient,m.type=new e.ProtocolRequestType0(m.method)})(bl||(t.CodeLensRefreshRequest=bl={}));var xt;(function(m){m.method="textDocument/documentLink",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(xt||(t.DocumentLinkRequest=xt={}));var _l;(function(m){m.method="documentLink/resolve",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(_l||(t.DocumentLinkResolveRequest=_l={}));var Sl;(function(m){m.method="textDocument/formatting",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(Sl||(t.DocumentFormattingRequest=Sl={}));var jr;(function(m){m.method="textDocument/rangeFormatting",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(jr||(t.DocumentRangeFormattingRequest=jr={}));var wl;(function(m){m.method="textDocument/rangesFormatting",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(wl||(t.DocumentRangesFormattingRequest=wl={}));var on;(function(m){m.method="textDocument/onTypeFormatting",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(on||(t.DocumentOnTypeFormattingRequest=on={}));var Il;(function(m){m.Identifier=1})(Il||(t.PrepareSupportDefaultBehavior=Il={}));var tr;(function(m){m.method="textDocument/rename",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(tr||(t.RenameRequest=tr={}));var Tr;(function(m){m.method="textDocument/prepareRename",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(Tr||(t.PrepareRenameRequest=Tr={}));var Nl;(function(m){m.method="workspace/executeCommand",m.messageDirection=e.MessageDirection.clientToServer,m.type=new e.ProtocolRequestType(m.method)})(Nl||(t.ExecuteCommandRequest=Nl={}));var Pl;(function(m){m.method="workspace/applyEdit",m.messageDirection=e.MessageDirection.serverToClient,m.type=new e.ProtocolRequestType("workspace/applyEdit")})(Pl||(t.ApplyWorkspaceEditRequest=Pl={}))}}),Hk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/connection.js"(t){Object.defineProperty(t,"__esModule",{value:!0}),t.createProtocolConnection=void 0;var e=il();function r(n,a,i,o){return e.ConnectionStrategy.is(o)&&(o={connectionStrategy:o}),(0,e.createMessageConnection)(n,a,i,o)}s(r,"createProtocolConnection"),t.createProtocolConnection=r}}),Yk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/common/api.js"(t){var e=t&&t.__createBinding||(Object.create?(function(i,o,u,l){l===void 0&&(l=u);var c=Object.getOwnPropertyDescriptor(o,u);(!c||("get"in c?!o.__esModule:c.writable||c.configurable))&&(c={enumerable:!0,get:s(function(){return o[u]},"get")}),Object.defineProperty(i,l,c)}):(function(i,o,u,l){l===void 0&&(l=u),i[l]=o[u]})),r=t&&t.__exportStar||function(i,o){for(var u in i)u!=="default"&&!Object.prototype.hasOwnProperty.call(o,u)&&e(o,i,u)};Object.defineProperty(t,"__esModule",{value:!0}),t.LSPErrorCodes=t.createProtocolConnection=void 0,r(il(),t),r((xu(),Ah(Lf)),t),r(ke(),t),r(qk(),t);var n=Hk();Object.defineProperty(t,"createProtocolConnection",{enumerable:!0,get:s(function(){return n.createProtocolConnection},"get")});var a;(function(i){i.lspReservedErrorRangeStart=-32899,i.RequestFailed=-32803,i.ServerCancelled=-32802,i.ContentModified=-32801,i.RequestCancelled=-32800,i.lspReservedErrorRangeEnd=-32800})(a||(t.LSPErrorCodes=a={}))}}),Xk=X({"../../node_modules/.pnpm/vscode-languageserver-protocol@3.17.5/node_modules/vscode-languageserver-protocol/lib/browser/main.js"(t){var e=t&&t.__createBinding||(Object.create?(function(i,o,u,l){l===void 0&&(l=u);var c=Object.getOwnPropertyDescriptor(o,u);(!c||("get"in c?!o.__esModule:c.writable||c.configurable))&&(c={enumerable:!0,get:s(function(){return o[u]},"get")}),Object.defineProperty(i,l,c)}):(function(i,o,u,l){l===void 0&&(l=u),i[l]=o[u]})),r=t&&t.__exportStar||function(i,o){for(var u in i)u!=="default"&&!Object.prototype.hasOwnProperty.call(o,u)&&e(o,i,u)};Object.defineProperty(t,"__esModule",{value:!0}),t.createProtocolConnection=void 0;var n=sv();r(sv(),t),r(Yk(),t);function a(i,o,u,l){return(0,n.createMessageConnection)(i,o,u,l)}s(a,"createProtocolConnection"),t.createProtocolConnection=a}}),j$={};tn(j$,{AbstractAstReflection:()=>_h,AbstractCstNode:()=>wg,AbstractLangiumParser:()=>Ng,AbstractParserErrorMessageProvider:()=>wN,AbstractThreadedAsyncParser:()=>$B,AstUtils:()=>Sh,BiMap:()=>If,Cancellation:()=>$e,CompositeCstNodeImpl:()=>Pd,ContextCache:()=>Gd,CstNodeBuilder:()=>bN,CstUtils:()=>Ch,DEFAULT_TOKENIZE_OPTIONS:()=>Hg,DONE_RESULT:()=>ct,DatatypeSymbol:()=>bf,DefaultAstNodeDescriptionProvider:()=>aP,DefaultAstNodeLocator:()=>sP,DefaultAsyncParser:()=>CP,DefaultCommentProvider:()=>EP,DefaultConfigurationProvider:()=>oP,DefaultDocumentBuilder:()=>lP,DefaultDocumentValidator:()=>nP,DefaultHydrator:()=>_P,DefaultIndexManager:()=>uP,DefaultJsonSerializer:()=>QN,DefaultLangiumDocumentFactory:()=>KN,DefaultLangiumDocuments:()=>WN,DefaultLangiumProfiler:()=>bB,DefaultLexer:()=>Yg,DefaultLexerErrorMessageProvider:()=>fP,DefaultLinker:()=>VN,DefaultNameProvider:()=>qN,DefaultReferenceDescriptionProvider:()=>iP,DefaultReferences:()=>HN,DefaultScopeComputation:()=>YN,DefaultScopeProvider:()=>ZN,DefaultServiceRegistry:()=>eP,DefaultTokenBuilder:()=>Ld,DefaultValueConverter:()=>Mg,DefaultWorkspaceLock:()=>bP,DefaultWorkspaceManager:()=>cP,Deferred:()=>Dr,Disposable:()=>Fn,DisposableCache:()=>Md,DocumentCache:()=>JN,DocumentState:()=>Q,DocumentValidator:()=>Mt,EMPTY_SCOPE:()=>yB,EMPTY_STREAM:()=>qo,EmptyFileSystem:()=>st,EmptyFileSystemProvider:()=>IP,ErrorWithLocation:()=>Kf,GrammarAST:()=>K$,GrammarUtils:()=>ny,IndentationAwareLexer:()=>AB,IndentationAwareTokenBuilder:()=>wP,JSDocDocumentationProvider:()=>AP,LangiumCompletionParser:()=>IN,LangiumParser:()=>SN,LangiumParserErrorMessageProvider:()=>Pg,LeafCstNodeImpl:()=>Cf,LexingMode:()=>Mn,MapScope:()=>hB,Module:()=>eh,MultiMap:()=>xr,MultiMapScope:()=>XN,OperationCancelled:()=>cr,ParserWorker:()=>RB,ProfilingTask:()=>PP,Reduction:()=>Tu,RefResolving:()=>vn,RegExpUtils:()=>iy,RootCstNodeImpl:()=>Ig,SimpleCache:()=>Ug,StreamImpl:()=>ur,StreamScope:()=>Xm,TextDocument:()=>Sf,TreeStreamImpl:()=>Ho,URI:()=>It,UriTrie:()=>jg,UriUtils:()=>dt,VALIDATE_EACH_NODE:()=>rP,ValidationCategory:()=>Nf,ValidationRegistry:()=>tP,ValueConverter:()=>or,WorkspaceCache:()=>Kg,assertCondition:()=>ay,assertUnreachable:()=>rn,createCompletionParser:()=>Lg,createDefaultCoreModule:()=>Xe,createDefaultSharedCoreModule:()=>Je,createGrammarConfig:()=>Ey,createLangiumParser:()=>Dg,createParser:()=>kd,delayNextTick:()=>Dd,diagnosticData:()=>xn,eagerLoad:()=>rv,getDiagnosticRange:()=>Vg,indentationBuilderDefaultOptions:()=>rh,inject:()=>re,interruptAndCheck:()=>Ye,isAstNode:()=>Be,isAstNodeDescription:()=>bh,isAstNodeWithComment:()=>Wg,isCompositeCstNode:()=>Sr,isIMultiModeLexerDefinition:()=>jd,isJSDoc:()=>Jg,isLeafCstNode:()=>qn,isLinkingError:()=>An,isMultiReference:()=>fr,isNamed:()=>Bg,isOperationCancelled:()=>da,isReference:()=>ft,isRootCstNode:()=>xf,isTokenTypeArray:()=>zd,isTokenTypeDictionary:()=>Pf,loadGrammarFromJson:()=>Ze,parseJSDoc:()=>Xg,prepareLangiumParser:()=>xg,setInterruptionPeriod:()=>Gg,startCancelableOperation:()=>xd,stream:()=>de,toDiagnosticData:()=>qg,toDiagnosticSeverity:()=>gu});var Ch={};tn(Ch,{DefaultNameRegexp:()=>Zh,RangeComparison:()=>lr,compareRange:()=>Xh,findCommentNode:()=>Qh,findDeclarationNodeAtOffset:()=>uR,findLeafNodeAtOffset:()=>Uf,findLeafNodeBeforeOffset:()=>ey,flattenCst:()=>lR,getDatatypeNode:()=>oR,getInteriorNodes:()=>dR,getNextNode:()=>cR,getPreviousNode:()=>ry,getStartlineNode:()=>fR,inRange:()=>Jh,isChildNode:()=>Yh,isCommentNode:()=>lf,streamCst:()=>Zo,toDocumentSegment:()=>Qo,tokenToRange:()=>$u});function Be(t){return typeof t=="object"&&t!==null&&typeof t.$type=="string"}s(Be,"isAstNode");function ft(t){return typeof t=="object"&&t!==null&&typeof t.$refText=="string"&&"ref"in t}s(ft,"isReference");function fr(t){return typeof t=="object"&&t!==null&&typeof t.$refText=="string"&&"items"in t}s(fr,"isMultiReference");function bh(t){return typeof t=="object"&&t!==null&&typeof t.name=="string"&&typeof t.type=="string"&&typeof t.path=="string"}s(bh,"isAstNodeDescription");function An(t){return typeof t=="object"&&t!==null&&typeof t.info=="object"&&typeof t.message=="string"}s(An,"isLinkingError");var Qa,_h=(Qa=class{constructor(){this.subtypes={},this.allSubtypes={}}getAllTypes(){return Object.keys(this.types)}getReferenceType(e){const r=this.types[e.container.$type];if(!r)throw new Error(`Type ${e.container.$type||"undefined"} not found.`);const n=r.properties[e.property]?.referenceType;if(!n)throw new Error(`Property ${e.property||"undefined"} of type ${e.container.$type} is not a reference.`);return n}getTypeMetaData(e){const r=this.types[e];return r||{name:e,properties:{},superTypes:[]}}isInstance(e,r){return Be(e)&&this.isSubtype(e.$type,r)}isSubtype(e,r){if(e===r)return!0;let n=this.subtypes[e];n||(n=this.subtypes[e]={});const a=n[r];if(a!==void 0)return a;{const i=this.types[e],o=i?i.superTypes.some(u=>this.isSubtype(u,r)):!1;return n[r]=o,o}}getAllSubTypes(e){const r=this.allSubtypes[e];if(r)return r;{const n=this.getAllTypes(),a=[];for(const i of n)this.isSubtype(i,e)&&a.push(i);return this.allSubtypes[e]=a,a}}},s(Qa,"AbstractAstReflection"),Qa);function Sr(t){return typeof t=="object"&&t!==null&&Array.isArray(t.content)}s(Sr,"isCompositeCstNode");function qn(t){return typeof t=="object"&&t!==null&&typeof t.tokenType=="object"}s(qn,"isLeafCstNode");function xf(t){return Sr(t)&&typeof t.fullText=="string"}s(xf,"isRootCstNode");var Et,ur=(Et=class{constructor(e,r){this.startFn=e,this.nextFn=r}iterator(){const e={state:this.startFn(),next:s(()=>this.nextFn(e.state),"next"),[Symbol.iterator]:()=>e};return e}[Symbol.iterator](){return this.iterator()}isEmpty(){return!!this.iterator().next().done}count(){const e=this.iterator();let r=0,n=e.next();for(;!n.done;)r++,n=e.next();return r}toArray(){const e=[],r=this.iterator();let n;do n=r.next(),n.value!==void 0&&e.push(n.value);while(!n.done);return e}toSet(){return new Set(this)}toMap(e,r){const n=this.map(a=>[e?e(a):a,r?r(a):a]);return new Map(n)}toString(){return this.join()}concat(e){return new Et(()=>({first:this.startFn(),firstDone:!1,iterator:e[Symbol.iterator]()}),r=>{let n;if(!r.firstDone){do if(n=this.nextFn(r.first),!n.done)return n;while(!n.done);r.firstDone=!0}do if(n=r.iterator.next(),!n.done)return n;while(!n.done);return ct})}join(e=","){const r=this.iterator();let n="",a,i=!1;do a=r.next(),a.done||(i&&(n+=e),n+=B$(a.value)),i=!0;while(!a.done);return n}indexOf(e,r=0){const n=this.iterator();let a=0,i=n.next();for(;!i.done;){if(a>=r&&i.value===e)return a;i=n.next(),a++}return-1}every(e){const r=this.iterator();let n=r.next();for(;!n.done;){if(!e(n.value))return!1;n=r.next()}return!0}some(e){const r=this.iterator();let n=r.next();for(;!n.done;){if(e(n.value))return!0;n=r.next()}return!1}forEach(e){const r=this.iterator();let n=0,a=r.next();for(;!a.done;)e(a.value,n),a=r.next(),n++}map(e){return new Et(this.startFn,r=>{const{done:n,value:a}=this.nextFn(r);return n?ct:{done:!1,value:e(a)}})}filter(e){return new Et(this.startFn,r=>{let n;do if(n=this.nextFn(r),!n.done&&e(n.value))return n;while(!n.done);return ct})}nonNullable(){return this.filter(e=>e!=null)}reduce(e,r){const n=this.iterator();let a=r,i=n.next();for(;!i.done;)a===void 0?a=i.value:a=e(a,i.value),i=n.next();return a}reduceRight(e,r){return this.recursiveReduce(this.iterator(),e,r)}recursiveReduce(e,r,n){const a=e.next();if(a.done)return n;const i=this.recursiveReduce(e,r,n);return i===void 0?a.value:r(i,a.value)}find(e){const r=this.iterator();let n=r.next();for(;!n.done;){if(e(n.value))return n.value;n=r.next()}}findIndex(e){const r=this.iterator();let n=0,a=r.next();for(;!a.done;){if(e(a.value))return n;a=r.next(),n++}return-1}includes(e){const r=this.iterator();let n=r.next();for(;!n.done;){if(n.value===e)return!0;n=r.next()}return!1}flatMap(e){return new Et(()=>({this:this.startFn()}),r=>{do{if(r.iterator){const i=r.iterator.next();if(i.done)r.iterator=void 0;else return i}const{done:n,value:a}=this.nextFn(r.this);if(!n){const i=e(a);if(vu(i))r.iterator=i[Symbol.iterator]();else return{done:!1,value:i}}}while(r.iterator);return ct})}flat(e){if(e===void 0&&(e=1),e<=0)return this;const r=e>1?this.flat(e-1):this;return new Et(()=>({this:r.startFn()}),n=>{do{if(n.iterator){const o=n.iterator.next();if(o.done)n.iterator=void 0;else return o}const{done:a,value:i}=r.nextFn(n.this);if(!a)if(vu(i))n.iterator=i[Symbol.iterator]();else return{done:!1,value:i}}while(n.iterator);return ct})}head(){const r=this.iterator().next();if(!r.done)return r.value}tail(e=1){return new Et(()=>{const r=this.startFn();for(let n=0;n<e;n++)if(this.nextFn(r).done)return r;return r},this.nextFn)}limit(e){return new Et(()=>({size:0,state:this.startFn()}),r=>(r.size++,r.size>e?ct:this.nextFn(r.state)))}distinct(e){return new Et(()=>({set:new Set,internalState:this.startFn()}),r=>{let n;do if(n=this.nextFn(r.internalState),!n.done){const a=e?e(n.value):n.value;if(!r.set.has(a))return r.set.add(a),n}while(!n.done);return ct})}exclude(e,r){const n=new Set;for(const a of e){const i=r?r(a):a;n.add(i)}return this.filter(a=>{const i=r?r(a):a;return!n.has(i)})}},s(Et,"StreamImpl"),Et);function B$(t){return typeof t=="string"?t:typeof t>"u"?"undefined":typeof t.toString=="function"?t.toString():Object.prototype.toString.call(t)}s(B$,"toString");function vu(t){return!!t&&typeof t[Symbol.iterator]=="function"}s(vu,"isIterable");var qo=new ur(()=>{},()=>ct),ct=Object.freeze({done:!0,value:void 0});function de(...t){if(t.length===1){const e=t[0];if(e instanceof ur)return e;if(vu(e))return new ur(()=>e[Symbol.iterator](),r=>r.next());if(typeof e.length=="number")return new ur(()=>({index:0}),r=>r.index<e.length?{done:!1,value:e[r.index++]}:ct)}return t.length>1?new ur(()=>({collIndex:0,arrIndex:0}),e=>{do{if(e.iterator){const r=e.iterator.next();if(!r.done)return r;e.iterator=void 0}if(e.array){if(e.arrIndex<e.array.length)return{done:!1,value:e.array[e.arrIndex++]};e.array=void 0,e.arrIndex=0}if(e.collIndex<t.length){const r=t[e.collIndex++];vu(r)?e.iterator=r[Symbol.iterator]():r&&typeof r.length=="number"&&(e.array=r)}}while(e.iterator||e.array||e.collIndex<t.length);return ct}):qo}s(de,"stream");var ei,Ho=(ei=class extends ur{constructor(e,r,n){super(()=>({iterators:n?.includeRoot?[[e][Symbol.iterator]()]:[r(e)[Symbol.iterator]()],pruned:!1}),a=>{for(a.pruned&&(a.iterators.pop(),a.pruned=!1);a.iterators.length>0;){const o=a.iterators[a.iterators.length-1].next();if(o.done)a.iterators.pop();else return a.iterators.push(r(o.value)[Symbol.iterator]()),o}return ct})}iterator(){const e={state:this.startFn(),next:s(()=>this.nextFn(e.state),"next"),prune:s(()=>{e.state.pruned=!0},"prune"),[Symbol.iterator]:()=>e};return e}},s(ei,"TreeStreamImpl"),ei),Tu;(function(t){function e(i){return i.reduce((o,u)=>o+u,0)}s(e,"sum"),t.sum=e;function r(i){return i.reduce((o,u)=>o*u,0)}s(r,"product"),t.product=r;function n(i){return i.reduce((o,u)=>Math.min(o,u))}s(n,"min"),t.min=n;function a(i){return i.reduce((o,u)=>Math.max(o,u))}s(a,"max"),t.max=a})(Tu||(Tu={}));var Sh={};tn(Sh,{assignMandatoryProperties:()=>wh,copyAstNode:()=>qc,findRootNode:()=>Ya,getContainerOfType:()=>Hn,getDocument:()=>Vt,getReferenceNodes:()=>Wc,hasContainerOfType:()=>U$,linkContentToContainer:()=>Yo,streamAllContents:()=>Mr,streamAst:()=>qt,streamContents:()=>Gu,streamReferences:()=>Xo});function Yo(t,e={}){for(const[r,n]of Object.entries(t))r.startsWith("$")||(Array.isArray(n)?n.forEach((a,i)=>{Be(a)&&(a.$container=t,a.$containerProperty=r,a.$containerIndex=i,e.deep&&Yo(a,e))}):Be(n)&&(n.$container=t,n.$containerProperty=r,e.deep&&Yo(n,e)))}s(Yo,"linkContentToContainer");function Hn(t,e){let r=t;for(;r;){if(e(r))return r;r=r.$container}}s(Hn,"getContainerOfType");function U$(t,e){let r=t;for(;r;){if(e(r))return!0;r=r.$container}return!1}s(U$,"hasContainerOfType");function Vt(t){const r=Ya(t).$document;if(!r)throw new Error("AST node has no document.");return r}s(Vt,"getDocument");function Ya(t){for(;t.$container;)t=t.$container;return t}s(Ya,"findRootNode");function Wc(t){return ft(t)?t.ref?[t.ref]:[]:fr(t)?t.items.map(e=>e.ref):[]}s(Wc,"getReferenceNodes");function Gu(t,e){if(!t)throw new Error("Node must be an AstNode.");const r=e?.range;return new ur(()=>({keys:Object.keys(t),keyIndex:0,arrayIndex:0}),n=>{for(;n.keyIndex<n.keys.length;){const a=n.keys[n.keyIndex];if(!a.startsWith("$")){const i=t[a];if(Be(i)){if(n.keyIndex++,Vc(i,r))return{done:!1,value:i}}else if(Array.isArray(i)){for(;n.arrayIndex<i.length;){const o=n.arrayIndex++,u=i[o];if(Be(u)&&Vc(u,r))return{done:!1,value:u}}n.arrayIndex=0}}n.keyIndex++}return ct})}s(Gu,"streamContents");function Mr(t,e){if(!t)throw new Error("Root node must be an AstNode.");return new Ho(t,r=>Gu(r,e))}s(Mr,"streamAllContents");function qt(t,e){if(t){if(e?.range&&!Vc(t,e.range))return new Ho(t,()=>[])}else throw new Error("Root node must be an AstNode.");return new Ho(t,r=>Gu(r,e),{includeRoot:!0})}s(qt,"streamAst");function Vc(t,e){if(!e)return!0;const r=t.$cstNode?.range;return r?Jh(r,e):!1}s(Vc,"isAstNodeInRange");function Xo(t){return new ur(()=>({keys:Object.keys(t),keyIndex:0,arrayIndex:0}),e=>{for(;e.keyIndex<e.keys.length;){const r=e.keys[e.keyIndex];if(!r.startsWith("$")){const n=t[r];if(ft(n)||fr(n))return e.keyIndex++,{done:!1,value:{reference:n,container:t,property:r}};if(Array.isArray(n)){for(;e.arrayIndex<n.length;){const a=e.arrayIndex++,i=n[a];if(ft(i)||fr(n))return{done:!1,value:{reference:i,container:t,property:r,index:a}}}e.arrayIndex=0}}e.keyIndex++}return ct})}s(Xo,"streamReferences");function wh(t,e){const r=t.getTypeMetaData(e.$type),n=e;for(const a of Object.values(r.properties))a.defaultValue!==void 0&&n[a.name]===void 0&&(n[a.name]=Ih(a.defaultValue))}s(wh,"assignMandatoryProperties");function Ih(t){return Array.isArray(t)?[...t.map(Ih)]:t}s(Ih,"copyDefaultValue");function qc(t,e,r){const n={$type:t.$type};r&&(r.set(t,n),r.set(n,t));for(const[a,i]of Object.entries(t))if(!a.startsWith("$"))if(Be(i))n[a]=qc(i,e,r);else if(ft(i))n[a]=e(n,a,i.$refNode,i.$refText,i);else if(Array.isArray(i)){const o=[];for(const u of i)Be(u)?o.push(qc(u,e,r)):ft(u)?o.push(e(n,a,u.$refNode,u.$refText,u)):o.push(u);n[a]=o}else n[a]=i;return Yo(n,{deep:!0}),n}s(qc,"copyAstNode");var K$={};tn(K$,{AbstractElement:()=>Rt,AbstractParserRule:()=>nu,AbstractRule:()=>ja,AbstractType:()=>wt,Action:()=>Kr,Alternatives:()=>au,ArrayLiteral:()=>Hc,ArrayType:()=>Yc,Assignment:()=>Wr,BooleanLiteral:()=>Xc,CharacterRange:()=>Vr,Condition:()=>qr,Conjunction:()=>iu,CrossReference:()=>Hr,Disjunction:()=>su,EndOfFile:()=>Jc,Grammar:()=>Cr,GrammarImport:()=>Zc,Group:()=>En,InferredType:()=>Qc,InfixRule:()=>sr,InfixRuleOperatorList:()=>ou,InfixRuleOperators:()=>ef,Interface:()=>Ba,Keyword:()=>Ua,LangiumGrammarAstReflection:()=>Hh,LangiumGrammarTerminals:()=>Jk,NamedArgument:()=>Ka,NegatedToken:()=>Cn,Negation:()=>tf,NumberLiteral:()=>rf,Parameter:()=>Wa,ParameterReference:()=>nf,ParserRule:()=>Ut,ReferenceType:()=>lu,RegexToken:()=>bn,ReturnType:()=>af,RuleCall:()=>_n,SimpleType:()=>Va,StringLiteral:()=>sf,TerminalAlternatives:()=>Sn,TerminalElement:()=>At,TerminalGroup:()=>wn,TerminalRule:()=>br,TerminalRuleCall:()=>In,Type:()=>uu,TypeAttribute:()=>Nn,TypeDefinition:()=>Pn,UnionType:()=>of,UnorderedGroup:()=>cu,UntilToken:()=>kn,ValueLiteral:()=>On,Wildcard:()=>qa,isAbstractElement:()=>Mf,isAbstractParserRule:()=>Yn,isAbstractRule:()=>W$,isAbstractType:()=>V$,isAction:()=>Xr,isAlternatives:()=>Gf,isArrayLiteral:()=>q$,isArrayType:()=>Nh,isAssignment:()=>wr,isBooleanLiteral:()=>Ph,isCharacterRange:()=>kh,isCondition:()=>H$,isConjunction:()=>Oh,isCrossReference:()=>Xn,isDisjunction:()=>Lh,isEndOfFile:()=>Dh,isGrammar:()=>Y$,isGrammarImport:()=>X$,isGroup:()=>Jn,isInferredType:()=>Fu,isInfixRule:()=>Jo,isInfixRuleOperatorList:()=>J$,isInfixRuleOperators:()=>Z$,isInterface:()=>xh,isKeyword:()=>Ir,isNamedArgument:()=>Q$,isNegatedToken:()=>Mh,isNegation:()=>Gh,isNumberLiteral:()=>eR,isParameter:()=>tR,isParameterReference:()=>Fh,isParserRule:()=>mt,isReferenceType:()=>zh,isRegexToken:()=>jh,isReturnType:()=>Bh,isRuleCall:()=>Nr,isSimpleType:()=>Ff,isStringLiteral:()=>rR,isTerminalAlternatives:()=>Uh,isTerminalElement:()=>nR,isTerminalGroup:()=>Kh,isTerminalRule:()=>jt,isTerminalRuleCall:()=>zf,isType:()=>jf,isTypeAttribute:()=>aR,isTypeDefinition:()=>iR,isUnionType:()=>Wh,isUnorderedGroup:()=>Bf,isUntilToken:()=>Vh,isValueLiteral:()=>sR,isWildcard:()=>qh,reflection:()=>U});var Jk={ID:/\^?[_a-zA-Z][\w_]*/,STRING:/"(\\.|[^"\\])*"|'(\\.|[^'\\])*'/,NUMBER:/NaN|-?((\d*\.\d+|\d+)([Ee][+-]?\d+)?|Infinity)/,RegexLiteral:/\/(?![*+?])(?:[^\r\n\[/\\]|\\.|\[(?:[^\r\n\]\\]|\\.)*\])+\/[a-z]*/,WS:/\s+/,ML_COMMENT:/\/\*[\s\S]*?\*\//,SL_COMMENT:/\/\/[^\n\r]*/},Rt={$type:"AbstractElement",cardinality:"cardinality"};function Mf(t){return U.isInstance(t,Rt.$type)}s(Mf,"isAbstractElement");var nu={$type:"AbstractParserRule"};function Yn(t){return U.isInstance(t,nu.$type)}s(Yn,"isAbstractParserRule");var ja={$type:"AbstractRule"};function W$(t){return U.isInstance(t,ja.$type)}s(W$,"isAbstractRule");var wt={$type:"AbstractType"};function V$(t){return U.isInstance(t,wt.$type)}s(V$,"isAbstractType");var Kr={$type:"Action",cardinality:"cardinality",feature:"feature",inferredType:"inferredType",operator:"operator",type:"type"};function Xr(t){return U.isInstance(t,Kr.$type)}s(Xr,"isAction");var au={$type:"Alternatives",cardinality:"cardinality",elements:"elements"};function Gf(t){return U.isInstance(t,au.$type)}s(Gf,"isAlternatives");var Hc={$type:"ArrayLiteral",elements:"elements"};function q$(t){return U.isInstance(t,Hc.$type)}s(q$,"isArrayLiteral");var Yc={$type:"ArrayType",elementType:"elementType"};function Nh(t){return U.isInstance(t,Yc.$type)}s(Nh,"isArrayType");var Wr={$type:"Assignment",cardinality:"cardinality",feature:"feature",operator:"operator",predicate:"predicate",terminal:"terminal"};function wr(t){return U.isInstance(t,Wr.$type)}s(wr,"isAssignment");var Xc={$type:"BooleanLiteral",true:"true"};function Ph(t){return U.isInstance(t,Xc.$type)}s(Ph,"isBooleanLiteral");var Vr={$type:"CharacterRange",cardinality:"cardinality",left:"left",lookahead:"lookahead",parenthesized:"parenthesized",right:"right"};function kh(t){return U.isInstance(t,Vr.$type)}s(kh,"isCharacterRange");var qr={$type:"Condition"};function H$(t){return U.isInstance(t,qr.$type)}s(H$,"isCondition");var iu={$type:"Conjunction",left:"left",right:"right"};function Oh(t){return U.isInstance(t,iu.$type)}s(Oh,"isConjunction");var Hr={$type:"CrossReference",cardinality:"cardinality",deprecatedSyntax:"deprecatedSyntax",isMulti:"isMulti",terminal:"terminal",type:"type"};function Xn(t){return U.isInstance(t,Hr.$type)}s(Xn,"isCrossReference");var su={$type:"Disjunction",left:"left",right:"right"};function Lh(t){return U.isInstance(t,su.$type)}s(Lh,"isDisjunction");var Jc={$type:"EndOfFile",cardinality:"cardinality"};function Dh(t){return U.isInstance(t,Jc.$type)}s(Dh,"isEndOfFile");var Cr={$type:"Grammar",imports:"imports",interfaces:"interfaces",isDeclared:"isDeclared",name:"name",rules:"rules",types:"types"};function Y$(t){return U.isInstance(t,Cr.$type)}s(Y$,"isGrammar");var Zc={$type:"GrammarImport",path:"path"};function X$(t){return U.isInstance(t,Zc.$type)}s(X$,"isGrammarImport");var En={$type:"Group",cardinality:"cardinality",elements:"elements",guardCondition:"guardCondition",predicate:"predicate"};function Jn(t){return U.isInstance(t,En.$type)}s(Jn,"isGroup");var Qc={$type:"InferredType",name:"name"};function Fu(t){return U.isInstance(t,Qc.$type)}s(Fu,"isInferredType");var sr={$type:"InfixRule",call:"call",dataType:"dataType",inferredType:"inferredType",name:"name",operators:"operators",parameters:"parameters",returnType:"returnType"};function Jo(t){return U.isInstance(t,sr.$type)}s(Jo,"isInfixRule");var ou={$type:"InfixRuleOperatorList",associativity:"associativity",operators:"operators"};function J$(t){return U.isInstance(t,ou.$type)}s(J$,"isInfixRuleOperatorList");var ef={$type:"InfixRuleOperators",precedences:"precedences"};function Z$(t){return U.isInstance(t,ef.$type)}s(Z$,"isInfixRuleOperators");var Ba={$type:"Interface",attributes:"attributes",name:"name",superTypes:"superTypes"};function xh(t){return U.isInstance(t,Ba.$type)}s(xh,"isInterface");var Ua={$type:"Keyword",cardinality:"cardinality",predicate:"predicate",value:"value"};function Ir(t){return U.isInstance(t,Ua.$type)}s(Ir,"isKeyword");var Ka={$type:"NamedArgument",calledByName:"calledByName",parameter:"parameter",value:"value"};function Q$(t){return U.isInstance(t,Ka.$type)}s(Q$,"isNamedArgument");var Cn={$type:"NegatedToken",cardinality:"cardinality",lookahead:"lookahead",parenthesized:"parenthesized",terminal:"terminal"};function Mh(t){return U.isInstance(t,Cn.$type)}s(Mh,"isNegatedToken");var tf={$type:"Negation",value:"value"};function Gh(t){return U.isInstance(t,tf.$type)}s(Gh,"isNegation");var rf={$type:"NumberLiteral",value:"value"};function eR(t){return U.isInstance(t,rf.$type)}s(eR,"isNumberLiteral");var Wa={$type:"Parameter",name:"name"};function tR(t){return U.isInstance(t,Wa.$type)}s(tR,"isParameter");var nf={$type:"ParameterReference",parameter:"parameter"};function Fh(t){return U.isInstance(t,nf.$type)}s(Fh,"isParameterReference");var Ut={$type:"ParserRule",dataType:"dataType",definition:"definition",entry:"entry",fragment:"fragment",inferredType:"inferredType",name:"name",parameters:"parameters",returnType:"returnType"};function mt(t){return U.isInstance(t,Ut.$type)}s(mt,"isParserRule");var lu={$type:"ReferenceType",isMulti:"isMulti",referenceType:"referenceType"};function zh(t){return U.isInstance(t,lu.$type)}s(zh,"isReferenceType");var bn={$type:"RegexToken",cardinality:"cardinality",lookahead:"lookahead",parenthesized:"parenthesized",regex:"regex"};function jh(t){return U.isInstance(t,bn.$type)}s(jh,"isRegexToken");var af={$type:"ReturnType",name:"name"};function Bh(t){return U.isInstance(t,af.$type)}s(Bh,"isReturnType");var _n={$type:"RuleCall",arguments:"arguments",cardinality:"cardinality",predicate:"predicate",rule:"rule"};function Nr(t){return U.isInstance(t,_n.$type)}s(Nr,"isRuleCall");var Va={$type:"SimpleType",primitiveType:"primitiveType",stringType:"stringType",typeRef:"typeRef"};function Ff(t){return U.isInstance(t,Va.$type)}s(Ff,"isSimpleType");var sf={$type:"StringLiteral",value:"value"};function rR(t){return U.isInstance(t,sf.$type)}s(rR,"isStringLiteral");var Sn={$type:"TerminalAlternatives",cardinality:"cardinality",elements:"elements",lookahead:"lookahead",parenthesized:"parenthesized"};function Uh(t){return U.isInstance(t,Sn.$type)}s(Uh,"isTerminalAlternatives");var At={$type:"TerminalElement",cardinality:"cardinality",lookahead:"lookahead",parenthesized:"parenthesized"};function nR(t){return U.isInstance(t,At.$type)}s(nR,"isTerminalElement");var wn={$type:"TerminalGroup",cardinality:"cardinality",elements:"elements",lookahead:"lookahead",parenthesized:"parenthesized"};function Kh(t){return U.isInstance(t,wn.$type)}s(Kh,"isTerminalGroup");var br={$type:"TerminalRule",definition:"definition",fragment:"fragment",hidden:"hidden",name:"name",type:"type"};function jt(t){return U.isInstance(t,br.$type)}s(jt,"isTerminalRule");var In={$type:"TerminalRuleCall",cardinality:"cardinality",lookahead:"lookahead",parenthesized:"parenthesized",rule:"rule"};function zf(t){return U.isInstance(t,In.$type)}s(zf,"isTerminalRuleCall");var uu={$type:"Type",name:"name",type:"type"};function jf(t){return U.isInstance(t,uu.$type)}s(jf,"isType");var Nn={$type:"TypeAttribute",defaultValue:"defaultValue",isOptional:"isOptional",name:"name",type:"type"};function aR(t){return U.isInstance(t,Nn.$type)}s(aR,"isTypeAttribute");var Pn={$type:"TypeDefinition"};function iR(t){return U.isInstance(t,Pn.$type)}s(iR,"isTypeDefinition");var of={$type:"UnionType",types:"types"};function Wh(t){return U.isInstance(t,of.$type)}s(Wh,"isUnionType");var cu={$type:"UnorderedGroup",cardinality:"cardinality",elements:"elements"};function Bf(t){return U.isInstance(t,cu.$type)}s(Bf,"isUnorderedGroup");var kn={$type:"UntilToken",cardinality:"cardinality",lookahead:"lookahead",parenthesized:"parenthesized",terminal:"terminal"};function Vh(t){return U.isInstance(t,kn.$type)}s(Vh,"isUntilToken");var On={$type:"ValueLiteral"};function sR(t){return U.isInstance(t,On.$type)}s(sR,"isValueLiteral");var qa={$type:"Wildcard",cardinality:"cardinality",lookahead:"lookahead",parenthesized:"parenthesized"};function qh(t){return U.isInstance(t,qa.$type)}s(qh,"isWildcard");var ti,Hh=(ti=class extends _h{constructor(){super(...arguments),this.types={AbstractElement:{name:Rt.$type,properties:{cardinality:{name:Rt.cardinality}},superTypes:[]},AbstractParserRule:{name:nu.$type,properties:{},superTypes:[ja.$type,wt.$type]},AbstractRule:{name:ja.$type,properties:{},superTypes:[]},AbstractType:{name:wt.$type,properties:{},superTypes:[]},Action:{name:Kr.$type,properties:{cardinality:{name:Kr.cardinality},feature:{name:Kr.feature},inferredType:{name:Kr.inferredType},operator:{name:Kr.operator},type:{name:Kr.type,referenceType:wt.$type}},superTypes:[Rt.$type]},Alternatives:{name:au.$type,properties:{cardinality:{name:au.cardinality},elements:{name:au.elements,defaultValue:[]}},superTypes:[Rt.$type]},ArrayLiteral:{name:Hc.$type,properties:{elements:{name:Hc.elements,defaultValue:[]}},superTypes:[On.$type]},ArrayType:{name:Yc.$type,properties:{elementType:{name:Yc.elementType}},superTypes:[Pn.$type]},Assignment:{name:Wr.$type,properties:{cardinality:{name:Wr.cardinality},feature:{name:Wr.feature},operator:{name:Wr.operator},predicate:{name:Wr.predicate},terminal:{name:Wr.terminal}},superTypes:[Rt.$type]},BooleanLiteral:{name:Xc.$type,properties:{true:{name:Xc.true,defaultValue:!1}},superTypes:[qr.$type,On.$type]},CharacterRange:{name:Vr.$type,properties:{cardinality:{name:Vr.cardinality},left:{name:Vr.left},lookahead:{name:Vr.lookahead},parenthesized:{name:Vr.parenthesized,defaultValue:!1},right:{name:Vr.right}},superTypes:[At.$type]},Condition:{name:qr.$type,properties:{},superTypes:[]},Conjunction:{name:iu.$type,properties:{left:{name:iu.left},right:{name:iu.right}},superTypes:[qr.$type]},CrossReference:{name:Hr.$type,properties:{cardinality:{name:Hr.cardinality},deprecatedSyntax:{name:Hr.deprecatedSyntax,defaultValue:!1},isMulti:{name:Hr.isMulti,defaultValue:!1},terminal:{name:Hr.terminal},type:{name:Hr.type,referenceType:wt.$type}},superTypes:[Rt.$type]},Disjunction:{name:su.$type,properties:{left:{name:su.left},right:{name:su.right}},superTypes:[qr.$type]},EndOfFile:{name:Jc.$type,properties:{cardinality:{name:Jc.cardinality}},superTypes:[Rt.$type]},Grammar:{name:Cr.$type,properties:{imports:{name:Cr.imports,defaultValue:[]},interfaces:{name:Cr.interfaces,defaultValue:[]},isDeclared:{name:Cr.isDeclared,defaultValue:!1},name:{name:Cr.name},rules:{name:Cr.rules,defaultValue:[]},types:{name:Cr.types,defaultValue:[]}},superTypes:[]},GrammarImport:{name:Zc.$type,properties:{path:{name:Zc.path}},superTypes:[]},Group:{name:En.$type,properties:{cardinality:{name:En.cardinality},elements:{name:En.elements,defaultValue:[]},guardCondition:{name:En.guardCondition},predicate:{name:En.predicate}},superTypes:[Rt.$type]},InferredType:{name:Qc.$type,properties:{name:{name:Qc.name}},superTypes:[wt.$type]},InfixRule:{name:sr.$type,properties:{call:{name:sr.call},dataType:{name:sr.dataType},inferredType:{name:sr.inferredType},name:{name:sr.name},operators:{name:sr.operators},parameters:{name:sr.parameters,defaultValue:[]},returnType:{name:sr.returnType,referenceType:wt.$type}},superTypes:[nu.$type]},InfixRuleOperatorList:{name:ou.$type,properties:{associativity:{name:ou.associativity},operators:{name:ou.operators,defaultValue:[]}},superTypes:[]},InfixRuleOperators:{name:ef.$type,properties:{precedences:{name:ef.precedences,defaultValue:[]}},superTypes:[]},Interface:{name:Ba.$type,properties:{attributes:{name:Ba.attributes,defaultValue:[]},name:{name:Ba.name},superTypes:{name:Ba.superTypes,defaultValue:[],referenceType:wt.$type}},superTypes:[wt.$type]},Keyword:{name:Ua.$type,properties:{cardinality:{name:Ua.cardinality},predicate:{name:Ua.predicate},value:{name:Ua.value}},superTypes:[Rt.$type]},NamedArgument:{name:Ka.$type,properties:{calledByName:{name:Ka.calledByName,defaultValue:!1},parameter:{name:Ka.parameter,referenceType:Wa.$type},value:{name:Ka.value}},superTypes:[]},NegatedToken:{name:Cn.$type,properties:{cardinality:{name:Cn.cardinality},lookahead:{name:Cn.lookahead},parenthesized:{name:Cn.parenthesized,defaultValue:!1},terminal:{name:Cn.terminal}},superTypes:[At.$type]},Negation:{name:tf.$type,properties:{value:{name:tf.value}},superTypes:[qr.$type]},NumberLiteral:{name:rf.$type,properties:{value:{name:rf.value}},superTypes:[On.$type]},Parameter:{name:Wa.$type,properties:{name:{name:Wa.name}},superTypes:[]},ParameterReference:{name:nf.$type,properties:{parameter:{name:nf.parameter,referenceType:Wa.$type}},superTypes:[qr.$type]},ParserRule:{name:Ut.$type,properties:{dataType:{name:Ut.dataType},definition:{name:Ut.definition},entry:{name:Ut.entry,defaultValue:!1},fragment:{name:Ut.fragment,defaultValue:!1},inferredType:{name:Ut.inferredType},name:{name:Ut.name},parameters:{name:Ut.parameters,defaultValue:[]},returnType:{name:Ut.returnType,referenceType:wt.$type}},superTypes:[nu.$type]},ReferenceType:{name:lu.$type,properties:{isMulti:{name:lu.isMulti,defaultValue:!1},referenceType:{name:lu.referenceType}},superTypes:[Pn.$type]},RegexToken:{name:bn.$type,properties:{cardinality:{name:bn.cardinality},lookahead:{name:bn.lookahead},parenthesized:{name:bn.parenthesized,defaultValue:!1},regex:{name:bn.regex}},superTypes:[At.$type]},ReturnType:{name:af.$type,properties:{name:{name:af.name}},superTypes:[]},RuleCall:{name:_n.$type,properties:{arguments:{name:_n.arguments,defaultValue:[]},cardinality:{name:_n.cardinality},predicate:{name:_n.predicate},rule:{name:_n.rule,referenceType:ja.$type}},superTypes:[Rt.$type]},SimpleType:{name:Va.$type,properties:{primitiveType:{name:Va.primitiveType},stringType:{name:Va.stringType},typeRef:{name:Va.typeRef,referenceType:wt.$type}},superTypes:[Pn.$type]},StringLiteral:{name:sf.$type,properties:{value:{name:sf.value}},superTypes:[On.$type]},TerminalAlternatives:{name:Sn.$type,properties:{cardinality:{name:Sn.cardinality},elements:{name:Sn.elements,defaultValue:[]},lookahead:{name:Sn.lookahead},parenthesized:{name:Sn.parenthesized,defaultValue:!1}},superTypes:[At.$type]},TerminalElement:{name:At.$type,properties:{cardinality:{name:At.cardinality},lookahead:{name:At.lookahead},parenthesized:{name:At.parenthesized,defaultValue:!1}},superTypes:[Rt.$type]},TerminalGroup:{name:wn.$type,properties:{cardinality:{name:wn.cardinality},elements:{name:wn.elements,defaultValue:[]},lookahead:{name:wn.lookahead},parenthesized:{name:wn.parenthesized,defaultValue:!1}},superTypes:[At.$type]},TerminalRule:{name:br.$type,properties:{definition:{name:br.definition},fragment:{name:br.fragment,defaultValue:!1},hidden:{name:br.hidden,defaultValue:!1},name:{name:br.name},type:{name:br.type}},superTypes:[ja.$type]},TerminalRuleCall:{name:In.$type,properties:{cardinality:{name:In.cardinality},lookahead:{name:In.lookahead},parenthesized:{name:In.parenthesized,defaultValue:!1},rule:{name:In.rule,referenceType:br.$type}},superTypes:[At.$type]},Type:{name:uu.$type,properties:{name:{name:uu.name},type:{name:uu.type}},superTypes:[wt.$type]},TypeAttribute:{name:Nn.$type,properties:{defaultValue:{name:Nn.defaultValue},isOptional:{name:Nn.isOptional,defaultValue:!1},name:{name:Nn.name},type:{name:Nn.type}},superTypes:[]},TypeDefinition:{name:Pn.$type,properties:{},superTypes:[]},UnionType:{name:of.$type,properties:{types:{name:of.types,defaultValue:[]}},superTypes:[Pn.$type]},UnorderedGroup:{name:cu.$type,properties:{cardinality:{name:cu.cardinality},elements:{name:cu.elements,defaultValue:[]}},superTypes:[Rt.$type]},UntilToken:{name:kn.$type,properties:{cardinality:{name:kn.cardinality},lookahead:{name:kn.lookahead},parenthesized:{name:kn.parenthesized,defaultValue:!1},terminal:{name:kn.terminal}},superTypes:[At.$type]},ValueLiteral:{name:On.$type,properties:{},superTypes:[]},Wildcard:{name:qa.$type,properties:{cardinality:{name:qa.cardinality},lookahead:{name:qa.lookahead},parenthesized:{name:qa.parenthesized,defaultValue:!1}},superTypes:[At.$type]}}}},s(ti,"LangiumGrammarAstReflection"),ti),U=new Hh;function oR(t){let e=t,r=!1;for(;e;){const n=Hn(e.grammarSource,mt);if(n&&n.dataType)e=e.container,r=!0;else return r?e:void 0}}s(oR,"getDatatypeNode");function Zo(t){return new Ho(t,e=>Sr(e)?e.content:[],{includeRoot:!0})}s(Zo,"streamCst");function lR(t){return Zo(t).filter(qn)}s(lR,"flattenCst");function Yh(t,e){for(;t.container;)if(t=t.container,t===e)return!0;return!1}s(Yh,"isChildNode");function $u(t){return{start:{character:t.startColumn-1,line:t.startLine-1},end:{character:t.endColumn,line:t.endLine-1}}}s($u,"tokenToRange");function Qo(t){if(!t)return;const{offset:e,end:r,range:n}=t;return{range:n,offset:e,end:r,length:r-e}}s(Qo,"toDocumentSegment");var lr;(function(t){t[t.Before=0]="Before",t[t.After=1]="After",t[t.OverlapFront=2]="OverlapFront",t[t.OverlapBack=3]="OverlapBack",t[t.Inside=4]="Inside",t[t.Outside=5]="Outside"})(lr||(lr={}));function Xh(t,e){if(t.end.line<e.start.line||t.end.line===e.start.line&&t.end.character<=e.start.character)return lr.Before;if(t.start.line>e.end.line||t.start.line===e.end.line&&t.start.character>=e.end.character)return lr.After;const r=t.start.line>e.start.line||t.start.line===e.start.line&&t.start.character>=e.start.character,n=t.end.line<e.end.line||t.end.line===e.end.line&&t.end.character<=e.end.character;return r&&n?lr.Inside:r?lr.OverlapBack:n?lr.OverlapFront:lr.Outside}s(Xh,"compareRange");function Jh(t,e){return Xh(t,e)>lr.After}s(Jh,"inRange");var Zh=/^[\w\p{L}]$/u;function uR(t,e,r=Zh){if(t){if(e>0){const n=e-t.offset,a=t.text.charAt(n);r.test(a)||e--}return Uf(t,e)}}s(uR,"findDeclarationNodeAtOffset");function Qh(t,e){if(t){const r=ry(t,!0);if(r&&lf(r,e))return r;if(xf(t)){const n=t.content.findIndex(a=>!a.hidden);for(let a=n-1;a>=0;a--){const i=t.content[a];if(lf(i,e))return i}}}}s(Qh,"findCommentNode");function lf(t,e){return qn(t)&&e.includes(t.tokenType.name)}s(lf,"isCommentNode");function Uf(t,e){if(qn(t))return t;if(Sr(t)){const r=ty(t,e,!1);if(r)return Uf(r,e)}}s(Uf,"findLeafNodeAtOffset");function ey(t,e){if(qn(t))return t;if(Sr(t)){const r=ty(t,e,!0);if(r)return ey(r,e)}}s(ey,"findLeafNodeBeforeOffset");function ty(t,e,r){let n=0,a=t.content.length-1,i;for(;n<=a;){const o=Math.floor((n+a)/2),u=t.content[o];if(u.offset<=e&&u.end>e)return u;u.end<=e?(i=r?u:void 0,n=o+1):a=o-1}return i}s(ty,"binarySearch");function ry(t,e=!0){for(;t.container;){const r=t.container;let n=r.content.indexOf(t);for(;n>0;){n--;const a=r.content[n];if(e||!a.hidden)return a}t=r}}s(ry,"getPreviousNode");function cR(t,e=!0){for(;t.container;){const r=t.container;let n=r.content.indexOf(t);const a=r.content.length-1;for(;n<a;){n++;const i=r.content[n];if(e||!i.hidden)return i}t=r}}s(cR,"getNextNode");function fR(t){if(t.range.start.character===0)return t;const e=t.range.start.line;let r=t,n;for(;t.container;){const a=t.container,i=n??a.content.indexOf(t);if(i===0?(t=a,n=void 0):(n=i-1,t=a.content[n]),t.range.start.line!==e)break;r=t}return r}s(fR,"getStartlineNode");function dR(t,e){const r=pR(t,e);return r?r.parent.content.slice(r.a+1,r.b):[]}s(dR,"getInteriorNodes");function pR(t,e){const r=Rm(t),n=Rm(e);let a;for(let i=0;i<r.length&&i<n.length;i++){const o=r[i],u=n[i];if(o.parent===u.parent)a={parent:o.parent,a:o.index,b:u.index};else break}return a}s(pR,"getCommonParent");function Rm(t){const e=[];for(;t.container;){const r=t.container,n=r.content.indexOf(t);e.push({parent:r,index:n}),t=r}return e.reverse()}s(Rm,"getParentChain");var ny={};tn(ny,{findAssignment:()=>yy,findNameAssignment:()=>Jf,findNodeForKeyword:()=>hy,findNodeForProperty:()=>Hf,findNodesForKeyword:()=>RR,findNodesForKeywordInternal:()=>Xf,findNodesForProperty:()=>my,getActionAtElement:()=>vy,getActionType:()=>$y,getAllReachableRules:()=>qf,getAllRulesUsedForCrossReferences:()=>$R,getCrossReferenceTerminal:()=>dy,getEntryRule:()=>uy,getExplicitRuleType:()=>ju,getHiddenRules:()=>cy,getRuleType:()=>Ry,getRuleTypeName:()=>_R,getTypeName:()=>Bn,isArrayCardinality:()=>ER,isArrayOperator:()=>CR,isCommentTerminal:()=>py,isDataType:()=>bR,isDataTypeRule:()=>zu,isOptionalCardinality:()=>AR,terminalRegex:()=>Bu});var ri,Kf=(ri=class extends Error{constructor(e,r){super(e?`${r} at ${e.range.start.line}:${e.range.start.character}`:r)}},s(ri,"ErrorWithLocation"),ri);function rn(t,e="Error: Got unexpected value."){throw new Error(e)}s(rn,"assertUnreachable");function ay(t,e="Error: Condition is violated."){if(!t)throw new Error(e)}s(ay,"assertCondition");var iy={};tn(iy,{NEWLINE_REGEXP:()=>yR,escapeRegExp:()=>sl,getTerminalParts:()=>vR,isMultilineComment:()=>sy,isWhitespace:()=>Vf,partialMatches:()=>oy,partialRegExp:()=>ly,whitespaceCharacters:()=>TR});function W(t){return t.charCodeAt(0)}s(W,"cc");function Ic(t,e){Array.isArray(t)?t.forEach(function(r){e.push(r)}):e.push(t)}s(Ic,"insertToSet");function Na(t,e){if(t[e]===!0)throw"duplicate flag "+e;t[e],t[e]=!0}s(Na,"addFlag");function hn(t){if(t===void 0)throw Error("Internal Error - Should never get here!");return!0}s(hn,"ASSERT_EXISTS");function mR(){throw Error("Internal Error - Should never get here!")}s(mR,"ASSERT_NEVER_REACH_HERE");function Am(t){return t.type==="Character"}s(Am,"isCharacter");var uf=[];for(let t=W("0");t<=W("9");t++)uf.push(t);var cf=[W("_")].concat(uf);for(let t=W("a");t<=W("z");t++)cf.push(t);for(let t=W("A");t<=W("Z");t++)cf.push(t);var ov=[W(" "),W("\f"),W(`
36
36
  `),W("\r"),W(" "),W("\v"),W(" "),W(" "),W(" "),W(" "),W(" "),W(" "),W(" "),W(" "),W(" "),W(" "),W(" "),W(" "),W(" "),W(" "),W("\u2028"),W("\u2029"),W(" "),W(" "),W(" "),W("\uFEFF")],Zk=/[0-9a-fA-F]/,ac=/[0-9]/,Qk=/[1-9]/,ni,hR=(ni=class{constructor(){this.idx=0,this.input="",this.groupIdx=0}saveState(){return{idx:this.idx,input:this.input,groupIdx:this.groupIdx}}restoreState(e){this.idx=e.idx,this.input=e.input,this.groupIdx=e.groupIdx}pattern(e){this.idx=0,this.input=e,this.groupIdx=0,this.consumeChar("/");const r=this.disjunction();this.consumeChar("/");const n={type:"Flags",loc:{begin:this.idx,end:e.length},global:!1,ignoreCase:!1,multiLine:!1,unicode:!1,sticky:!1};for(;this.isRegExpFlag();)switch(this.popChar()){case"g":Na(n,"global");break;case"i":Na(n,"ignoreCase");break;case"m":Na(n,"multiLine");break;case"u":Na(n,"unicode");break;case"y":Na(n,"sticky");break}if(this.idx!==this.input.length)throw Error("Redundant input: "+this.input.substring(this.idx));return{type:"Pattern",flags:n,value:r,loc:this.loc(0)}}disjunction(){const e=[],r=this.idx;for(e.push(this.alternative());this.peekChar()==="|";)this.consumeChar("|"),e.push(this.alternative());return{type:"Disjunction",value:e,loc:this.loc(r)}}alternative(){const e=[],r=this.idx;for(;this.isTerm();)e.push(this.term());return{type:"Alternative",value:e,loc:this.loc(r)}}term(){return this.isAssertion()?this.assertion():this.atom()}assertion(){const e=this.idx;switch(this.popChar()){case"^":return{type:"StartAnchor",loc:this.loc(e)};case"$":return{type:"EndAnchor",loc:this.loc(e)};case"\\":switch(this.popChar()){case"b":return{type:"WordBoundary",loc:this.loc(e)};case"B":return{type:"NonWordBoundary",loc:this.loc(e)}}throw Error("Invalid Assertion Escape");case"(":this.consumeChar("?");let r;switch(this.popChar()){case"=":r="Lookahead";break;case"!":r="NegativeLookahead";break;case"<":{switch(this.popChar()){case"=":r="Lookbehind";break;case"!":r="NegativeLookbehind"}break}}hn(r);const n=this.disjunction();return this.consumeChar(")"),{type:r,value:n,loc:this.loc(e)}}return mR()}quantifier(e=!1){let r;const n=this.idx;switch(this.popChar()){case"*":r={atLeast:0,atMost:1/0};break;case"+":r={atLeast:1,atMost:1/0};break;case"?":r={atLeast:0,atMost:1};break;case"{":const a=this.integerIncludingZero();switch(this.popChar()){case"}":r={atLeast:a,atMost:a};break;case",":let i;this.isDigit()?(i=this.integerIncludingZero(),r={atLeast:a,atMost:i}):r={atLeast:a,atMost:1/0},this.consumeChar("}");break}if(e===!0&&r===void 0)return;hn(r);break}if(!(e===!0&&r===void 0)&&hn(r))return this.peekChar(0)==="?"?(this.consumeChar("?"),r.greedy=!1):r.greedy=!0,r.type="Quantifier",r.loc=this.loc(n),r}atom(){let e;const r=this.idx;switch(this.peekChar()){case".":e=this.dotAll();break;case"\\":e=this.atomEscape();break;case"[":e=this.characterClass();break;case"(":e=this.group();break}if(e===void 0&&this.isPatternCharacter()&&(e=this.patternCharacter()),hn(e))return e.loc=this.loc(r),this.isQuantifier()&&(e.quantifier=this.quantifier()),e}dotAll(){return this.consumeChar("."),{type:"Set",complement:!0,value:[W(`
37
37
  `),W("\r"),W("\u2028"),W("\u2029")]}}atomEscape(){switch(this.consumeChar("\\"),this.peekChar()){case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":return this.decimalEscapeAtom();case"d":case"D":case"s":case"S":case"w":case"W":return this.characterClassEscape();case"f":case"n":case"r":case"t":case"v":return this.controlEscapeAtom();case"c":return this.controlLetterEscapeAtom();case"0":return this.nulCharacterAtom();case"x":return this.hexEscapeSequenceAtom();case"u":return this.regExpUnicodeEscapeSequenceAtom();default:return this.identityEscapeAtom()}}decimalEscapeAtom(){return{type:"GroupBackReference",value:this.positiveInteger()}}characterClassEscape(){let e,r=!1;switch(this.popChar()){case"d":e=uf;break;case"D":e=uf,r=!0;break;case"s":e=ov;break;case"S":e=ov,r=!0;break;case"w":e=cf;break;case"W":e=cf,r=!0;break}if(hn(e))return{type:"Set",value:e,complement:r}}controlEscapeAtom(){let e;switch(this.popChar()){case"f":e=W("\f");break;case"n":e=W(`
38
38
  `);break;case"r":e=W("\r");break;case"t":e=W(" ");break;case"v":e=W("\v");break}if(hn(e))return{type:"Character",value:e}}controlLetterEscapeAtom(){this.consumeChar("c");const e=this.popChar();if(/[a-zA-Z]/.test(e)===!1)throw Error("Invalid ");return{type:"Character",value:e.toUpperCase().charCodeAt(0)-64}}nulCharacterAtom(){return this.consumeChar("0"),{type:"Character",value:W("\0")}}hexEscapeSequenceAtom(){return this.consumeChar("x"),this.parseHexDigits(2)}regExpUnicodeEscapeSequenceAtom(){return this.consumeChar("u"),this.parseHexDigits(4)}identityEscapeAtom(){const e=this.popChar();return{type:"Character",value:W(e)}}classPatternCharacterAtom(){switch(this.peekChar()){case`
@@ -43,7 +43,7 @@ ${JSON.stringify(g,null,4)}`);const P=g;if(r.string(P.id)||r.number(P.id)){const
43
43
  `:case"\r":case"\u2028":case"\u2029":return!1;default:return!0}}parseHexDigits(e){let r="";for(let a=0;a<e;a++){const i=this.popChar();if(Zk.test(i)===!1)throw Error("Expecting a HexDecimal digits");r+=i}return{type:"Character",value:parseInt(r,16)}}peekChar(e=0){return this.input[this.idx+e]}popChar(){const e=this.peekChar(0);return this.consumeChar(void 0),e}consumeChar(e){if(e!==void 0&&this.input[this.idx]!==e)throw Error("Expected: '"+e+"' but found: '"+this.input[this.idx]+"' at offset: "+this.idx);if(this.idx>=this.input.length)throw Error("Unexpected end of input");this.idx++}loc(e){return{begin:e,end:this.idx}}},s(ni,"RegExpParser"),ni),ai,Wf=(ai=class{visitChildren(e){for(const r in e){const n=e[r];e.hasOwnProperty(r)&&(n.type!==void 0?this.visit(n):Array.isArray(n)&&n.forEach(a=>{this.visit(a)},this))}}visit(e){switch(e.type){case"Pattern":this.visitPattern(e);break;case"Flags":this.visitFlags(e);break;case"Disjunction":this.visitDisjunction(e);break;case"Alternative":this.visitAlternative(e);break;case"StartAnchor":this.visitStartAnchor(e);break;case"EndAnchor":this.visitEndAnchor(e);break;case"WordBoundary":this.visitWordBoundary(e);break;case"NonWordBoundary":this.visitNonWordBoundary(e);break;case"Lookahead":this.visitLookahead(e);break;case"NegativeLookahead":this.visitNegativeLookahead(e);break;case"Lookbehind":this.visitLookbehind(e);break;case"NegativeLookbehind":this.visitNegativeLookbehind(e);break;case"Character":this.visitCharacter(e);break;case"Set":this.visitSet(e);break;case"Group":this.visitGroup(e);break;case"GroupBackReference":this.visitGroupBackReference(e);break;case"Quantifier":this.visitQuantifier(e);break}this.visitChildren(e)}visitPattern(e){}visitFlags(e){}visitDisjunction(e){}visitAlternative(e){}visitStartAnchor(e){}visitEndAnchor(e){}visitWordBoundary(e){}visitNonWordBoundary(e){}visitLookahead(e){}visitNegativeLookahead(e){}visitLookbehind(e){}visitNegativeLookbehind(e){}visitCharacter(e){}visitSet(e){}visitGroup(e){}visitGroupBackReference(e){}visitQuantifier(e){}},s(ai,"BaseRegExpVisitor"),ai),yR=/\r?\n/gm,gR=new hR,ii,eO=(ii=class extends Wf{constructor(){super(...arguments),this.isStarting=!0,this.endRegexpStack=[],this.multiline=!1}get endRegex(){return this.endRegexpStack.join("")}reset(e){this.multiline=!1,this.regex=e,this.startRegexp="",this.isStarting=!0,this.endRegexpStack=[]}visitGroup(e){e.quantifier&&(this.isStarting=!1,this.endRegexpStack=[])}visitCharacter(e){const r=String.fromCharCode(e.value);if(!this.multiline&&r===`
44
44
  `&&(this.multiline=!0),e.quantifier)this.isStarting=!1,this.endRegexpStack=[];else{const n=sl(r);this.endRegexpStack.push(n),this.isStarting&&(this.startRegexp+=n)}}visitSet(e){if(!this.multiline){const r=this.regex.substring(e.loc.begin,e.loc.end),n=new RegExp(r);this.multiline=!!`
45
45
  `.match(n)}if(e.quantifier)this.isStarting=!1,this.endRegexpStack=[];else{const r=this.regex.substring(e.loc.begin,e.loc.end);this.endRegexpStack.push(r),this.isStarting&&(this.startRegexp+=r)}}visitChildren(e){e.type==="Group"&&e.quantifier||super.visitChildren(e)}},s(ii,"TerminalRegExpVisitor"),ii),Ln=new eO;function vR(t){try{typeof t!="string"&&(t=t.source),t=`/${t}/`;const e=gR.pattern(t),r=[];for(const n of e.value.value)Ln.reset(t),Ln.visit(n),r.push({start:Ln.startRegexp,end:Ln.endRegex});return r}catch{return[]}}s(vR,"getTerminalParts");function sy(t){try{return typeof t=="string"&&(t=new RegExp(t)),t=t.toString(),Ln.reset(t),Ln.visit(gR.pattern(t)),Ln.multiline}catch{return!1}}s(sy,"isMultilineComment");var TR=`\f
46
- \r \v              \u2028\u2029   \uFEFF`.split("");function Vf(t){const e=typeof t=="string"?new RegExp(t):t;return TR.some(r=>e.test(r))}s(Vf,"isWhitespace");function sl(t){return t.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}s(sl,"escapeRegExp");function oy(t,e){const r=ly(t),n=e.match(r);return!!n&&n[0].length>0}s(oy,"partialMatches");function ly(t){typeof t=="string"&&(t=new RegExp(t));const e=t,r=t.source;let n=0;function a(){let i="",o;function u(c){i+=r.substr(n,c),n+=c}s(u,"appendRaw");function l(c){i+="(?:"+r.substr(n,c)+"|$)",n+=c}for(s(l,"appendOptional");n<r.length;)switch(r[n]){case"\\":switch(r[n+1]){case"c":l(3);break;case"x":l(4);break;case"u":e.unicode?r[n+2]==="{"?l(r.indexOf("}",n)-n+1):l(6):l(2);break;case"p":case"P":e.unicode?l(r.indexOf("}",n)-n+1):l(2);break;case"k":l(r.indexOf(">",n)-n+1);break;default:l(2);break}break;case"[":o=/\[(?:\\.|.)*?\]/g,o.lastIndex=n,o=o.exec(r)||[],l(o[0].length);break;case"|":case"^":case"$":case"*":case"+":case"?":u(1);break;case"{":o=/\{\d+,?\d*\}/g,o.lastIndex=n,o=o.exec(r),o?u(o[0].length):l(1);break;case"(":if(r[n+1]==="?")switch(r[n+2]){case":":i+="(?:",n+=3,i+=a()+"|$)";break;case"=":i+="(?=",n+=3,i+=a()+")";break;case"!":o=n,n+=3,a(),i+=r.substr(o,n-o);break;case"<":switch(r[n+3]){case"=":case"!":o=n,n+=4,a(),i+=r.substr(o,n-o);break;default:u(r.indexOf(">",n)-n+1),i+=a()+"|$)";break}break}else u(1),i+=a()+"|$)";break;case")":return++n,i;default:l(1);break}return i}return s(a,"process"),new RegExp(a(),t.flags)}s(ly,"partialRegExp");function uy(t){return t.rules.find(e=>mt(e)&&e.entry)}s(uy,"getEntryRule");function cy(t){return t.rules.filter(e=>jt(e)&&e.hidden)}s(cy,"getHiddenRules");function qf(t,e){const r=new Set,n=uy(t);if(!n)return new Set(t.rules);const a=[n].concat(cy(t));for(const o of a)fy(o,r,e);const i=new Set;for(const o of t.rules)(r.has(o.name)||jt(o)&&o.hidden)&&i.add(o);return i}s(qf,"getAllReachableRules");function fy(t,e,r){e.add(t.name),Mr(t).forEach(n=>{if(Nr(n)||r&&zf(n)){const a=n.rule.ref;a&&!e.has(a.name)&&fy(a,e,r)}})}s(fy,"ruleDfs");function $R(t){const e=new Set;return Mr(t).forEach(r=>{Xn(r)&&(mt(r.type.ref)&&e.add(r.type.ref),Fu(r.type.ref)&&mt(r.type.ref.$container)&&e.add(r.type.ref.$container))}),e}s($R,"getAllRulesUsedForCrossReferences");function dy(t){if(t.terminal)return t.terminal;if(t.type.ref)return Jf(t.type.ref)?.terminal}s(dy,"getCrossReferenceTerminal");function py(t){return t.hidden&&!Vf(Bu(t))}s(py,"isCommentTerminal");function my(t,e){return!t||!e?[]:Yf(t,e,t.astNode,!0)}s(my,"findNodesForProperty");function Hf(t,e,r){if(!t||!e)return;const n=Yf(t,e,t.astNode,!0);if(n.length!==0)return r!==void 0?r=Math.max(0,Math.min(r,n.length-1)):r=0,n[r]}s(Hf,"findNodeForProperty");function Yf(t,e,r,n){if(!n){const a=Hn(t.grammarSource,wr);if(a&&a.feature===e)return[t]}return Sr(t)&&t.astNode===r?t.content.flatMap(a=>Yf(a,e,r,!1)):[]}s(Yf,"findNodesForPropertyInternal");function RR(t,e){return t?Xf(t,e,t?.astNode):[]}s(RR,"findNodesForKeyword");function hy(t,e,r){if(!t)return;const n=Xf(t,e,t?.astNode);if(n.length!==0)return r!==void 0?r=Math.max(0,Math.min(r,n.length-1)):r=0,n[r]}s(hy,"findNodeForKeyword");function Xf(t,e,r){if(t.astNode!==r)return[];if(Ir(t.grammarSource)&&t.grammarSource.value===e)return[t];const n=Zo(t).iterator();let a;const i=[];do if(a=n.next(),!a.done){const o=a.value;o.astNode===r?Ir(o.grammarSource)&&o.grammarSource.value===e&&i.push(o):n.prune()}while(!a.done);return i}s(Xf,"findNodesForKeywordInternal");function yy(t){const e=t.astNode;for(;e===t.container?.astNode;){const r=Hn(t.grammarSource,wr);if(r)return r;t=t.container}}s(yy,"findAssignment");function Jf(t){let e=t;return Fu(e)&&(Xr(e.$container)?e=e.$container.$container:Yn(e.$container)?e=e.$container:rn(e.$container)),gy(t,e,new Map)}s(Jf,"findNameAssignment");function gy(t,e,r){function n(a,i){let o;return Hn(a,wr)||(o=gy(i,i,r)),r.set(t,o),o}if(s(n,"go"),r.has(t))return r.get(t);r.set(t,void 0);for(const a of Mr(e)){if(wr(a)&&a.feature.toLowerCase()==="name")return r.set(t,a),a;if(Nr(a)&&mt(a.rule.ref))return n(a,a.rule.ref);if(Ff(a)&&a.typeRef?.ref)return n(a,a.typeRef.ref)}}s(gy,"findNameAssignmentInternal");function vy(t){const e=t.$container;if(Jn(e)){const r=e.elements,n=r.indexOf(t);for(let a=n-1;a>=0;a--){const i=r[a];if(Xr(i))return i;{const o=Mr(r[a]).find(Xr);if(o)return o}}}if(Mf(e))return vy(e)}s(vy,"getActionAtElement");function AR(t,e){return t==="?"||t==="*"||Jn(e)&&!!e.guardCondition}s(AR,"isOptionalCardinality");function ER(t){return t==="*"||t==="+"}s(ER,"isArrayCardinality");function CR(t){return t==="+="}s(CR,"isArrayOperator");function zu(t){return Ty(t,new Set)}s(zu,"isDataTypeRule");function Ty(t,e){if(e.has(t))return!0;e.add(t);for(const r of Mr(t))if(Nr(r)){if(!r.rule.ref||mt(r.rule.ref)&&!Ty(r.rule.ref,e)||Jo(r.rule.ref))return!1}else{if(wr(r))return!1;if(Xr(r))return!1}return!!t.definition}s(Ty,"isDataTypeRuleInternal");function bR(t){return ff(t.type,new Set)}s(bR,"isDataType");function ff(t,e){if(e.has(t))return!0;if(e.add(t),Nh(t))return!1;if(zh(t))return!1;if(Wh(t))return t.types.every(r=>ff(r,e));if(Ff(t)){if(t.primitiveType!==void 0)return!0;if(t.stringType!==void 0)return!0;if(t.typeRef!==void 0){const r=t.typeRef.ref;return jf(r)?ff(r.type,e):!1}else return!1}else return!1}s(ff,"isDataTypeInternal");function ju(t){if(!jt(t)){if(t.inferredType)return t.inferredType.name;if(t.dataType)return t.dataType;if(t.returnType){const e=t.returnType.ref;if(e)return e.name}}}s(ju,"getExplicitRuleType");function Bn(t){if(Yn(t))return mt(t)&&zu(t)?t.name:ju(t)??t.name;if(xh(t)||jf(t)||Bh(t))return t.name;if(Xr(t)){const e=$y(t);if(e)return e}else if(Fu(t))return t.name;throw new Error("Cannot get name of Unknown Type")}s(Bn,"getTypeName");function $y(t){if(t.inferredType)return t.inferredType.name;if(t.type?.ref)return Bn(t.type.ref)}s($y,"getActionType");function _R(t){return jt(t)?t.type?.name??"string":mt(t)&&zu(t)?t.name:ju(t)??t.name}s(_R,"getRuleTypeName");function Ry(t){return jt(t)?t.type?.name??"string":ju(t)??t.name}s(Ry,"getRuleType");function Bu(t){const e={s:!1,i:!1,u:!1},r=Zn(t.definition,e),n=Object.entries(e).filter(([,a])=>a).map(([a])=>a).join("");return new RegExp(r,n)}s(Bu,"terminalRegex");var Ay=/[\s\S]/.source;function Zn(t,e){if(Uh(t))return SR(t);if(Kh(t))return wR(t);if(kh(t))return PR(t);if(zf(t)){const r=t.rule.ref;if(!r)throw new Error("Missing rule reference.");return dr(Zn(r.definition),{cardinality:t.cardinality,lookahead:t.lookahead,parenthesized:t.parenthesized})}else{if(Mh(t))return NR(t);if(Vh(t))return IR(t);if(jh(t)){const r=t.regex.lastIndexOf("/"),n=t.regex.substring(1,r),a=t.regex.substring(r+1);return e&&(e.i=a.includes("i"),e.s=a.includes("s"),e.u=a.includes("u")),dr(n,{cardinality:t.cardinality,lookahead:t.lookahead,parenthesized:t.parenthesized,wrap:!1})}else{if(qh(t))return dr(Ay,{cardinality:t.cardinality,lookahead:t.lookahead,parenthesized:t.parenthesized});throw new Error(`Invalid terminal element: ${t?.$type}, ${t?.$cstNode?.text}`)}}}s(Zn,"abstractElementToRegex");function SR(t){return dr(t.elements.map(e=>Zn(e)).join("|"),{cardinality:t.cardinality,lookahead:t.lookahead,parenthesized:t.parenthesized,wrap:!1})}s(SR,"terminalAlternativesToRegex");function wR(t){return dr(t.elements.map(e=>Zn(e)).join(""),{cardinality:t.cardinality,lookahead:t.lookahead,parenthesized:t.parenthesized,wrap:!1})}s(wR,"terminalGroupToRegex");function IR(t){return dr(`${Ay}*?${Zn(t.terminal)}`,{cardinality:t.cardinality,lookahead:t.lookahead,parenthesized:t.parenthesized})}s(IR,"untilTokenToRegex");function NR(t){return dr(`(?!${Zn(t.terminal)})${Ay}*?`,{cardinality:t.cardinality,lookahead:t.lookahead,parenthesized:t.parenthesized})}s(NR,"negateTokenToRegex");function PR(t){return t.right?dr(`[${Nc(t.left)}-${Nc(t.right)}]`,{cardinality:t.cardinality,lookahead:t.lookahead,parenthesized:t.parenthesized,wrap:!1}):dr(Nc(t.left),{cardinality:t.cardinality,lookahead:t.lookahead,parenthesized:t.parenthesized,wrap:!1})}s(PR,"characterRangeToRegex");function Nc(t){return sl(t.value)}s(Nc,"keywordToRegex");function dr(t,e){return(e.parenthesized||e.lookahead||e.wrap!==!1)&&(t=`(${e.lookahead??(e.parenthesized?"":"?:")}${t})`),e.cardinality?`${t}${e.cardinality}`:t}s(dr,"withCardinality");function Ey(t){const e=[],r=t.Grammar;for(const n of r.rules)jt(n)&&py(n)&&sy(Bu(n))&&e.push(n.name);return{multilineCommentRules:e,nameRegexp:Zh}}s(Ey,"createGrammarConfig");var tO=typeof global=="object"&&global&&global.Object===Object&&global,kR=tO,rO=typeof self=="object"&&self&&self.Object===Object&&self,nO=kR||rO||Function("return this")(),mr=nO,aO=mr.Symbol,Ft=aO,OR=Object.prototype,iO=OR.hasOwnProperty,sO=OR.toString,Ol=Ft?Ft.toStringTag:void 0;function LR(t){var e=iO.call(t,Ol),r=t[Ol];try{t[Ol]=void 0;var n=!0}catch{}var a=sO.call(t);return n&&(e?t[Ol]=r:delete t[Ol]),a}s(LR,"getRawTag");var oO=LR,lO=Object.prototype,uO=lO.toString;function DR(t){return uO.call(t)}s(DR,"objectToString");var cO=DR,fO="[object Null]",dO="[object Undefined]",lv=Ft?Ft.toStringTag:void 0;function xR(t){return t==null?t===void 0?dO:fO:lv&&lv in Object(t)?oO(t):cO(t)}s(xR,"baseGetTag");var nn=xR;function MR(t){return t!=null&&typeof t=="object"}s(MR,"isObjectLike");var Xt=MR,pO="[object Symbol]";function GR(t){return typeof t=="symbol"||Xt(t)&&nn(t)==pO}s(GR,"isSymbol");var Zf=GR;function FR(t,e){for(var r=-1,n=t==null?0:t.length,a=Array(n);++r<n;)a[r]=e(t[r],r,t);return a}s(FR,"arrayMap");var Uu=FR,mO=Array.isArray,se=mO,uv=Ft?Ft.prototype:void 0,cv=uv?uv.toString:void 0;function Cy(t){if(typeof t=="string")return t;if(se(t))return Uu(t,Cy)+"";if(Zf(t))return cv?cv.call(t):"";var e=t+"";return e=="0"&&1/t==-1/0?"-0":e}s(Cy,"baseToString");var hO=Cy,yO=/\s/;function zR(t){for(var e=t.length;e--&&yO.test(t.charAt(e)););return e}s(zR,"trimmedEndIndex");var gO=zR,vO=/^\s+/;function jR(t){return t&&t.slice(0,gO(t)+1).replace(vO,"")}s(jR,"baseTrim");var TO=jR;function BR(t){var e=typeof t;return t!=null&&(e=="object"||e=="function")}s(BR,"isObject");var zt=BR,fv=NaN,$O=/^[-+]0x[0-9a-f]+$/i,RO=/^0b[01]+$/i,AO=/^0o[0-7]+$/i,EO=parseInt;function UR(t){if(typeof t=="number")return t;if(Zf(t))return fv;if(zt(t)){var e=typeof t.valueOf=="function"?t.valueOf():t;t=zt(e)?e+"":e}if(typeof t!="string")return t===0?t:+t;t=TO(t);var r=RO.test(t);return r||AO.test(t)?EO(t.slice(2),r?2:8):$O.test(t)?fv:+t}s(UR,"toNumber");var CO=UR,dv=1/0,bO=17976931348623157e292;function KR(t){if(!t)return t===0?t:0;if(t=CO(t),t===dv||t===-dv){var e=t<0?-1:1;return e*bO}return t===t?t:0}s(KR,"toFinite");var _O=KR;function WR(t){var e=_O(t),r=e%1;return e===e?r?e-r:e:0}s(WR,"toInteger");var Ku=WR;function VR(t){return t}s(VR,"identity");var Wu=VR,SO="[object AsyncFunction]",wO="[object Function]",IO="[object GeneratorFunction]",NO="[object Proxy]";function qR(t){if(!zt(t))return!1;var e=nn(t);return e==wO||e==IO||e==SO||e==NO}s(qR,"isFunction");var Gr=qR,PO=mr["__core-js_shared__"],Kd=PO,pv=function(){var t=/[^.]+$/.exec(Kd&&Kd.keys&&Kd.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""}();function HR(t){return!!pv&&pv in t}s(HR,"isMasked");var kO=HR,OO=Function.prototype,LO=OO.toString;function YR(t){if(t!=null){try{return LO.call(t)}catch{}try{return t+""}catch{}}return""}s(YR,"toSource");var Qn=YR,DO=/[\\^$.*+?()[\]{}|]/g,xO=/^\[object .+?Constructor\]$/,MO=Function.prototype,GO=Object.prototype,FO=MO.toString,zO=GO.hasOwnProperty,jO=RegExp("^"+FO.call(zO).replace(DO,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function XR(t){if(!zt(t)||kO(t))return!1;var e=Gr(t)?jO:xO;return e.test(Qn(t))}s(XR,"baseIsNative");var BO=XR;function JR(t,e){return t?.[e]}s(JR,"getValue");var UO=JR;function ZR(t,e){var r=UO(t,e);return BO(r)?r:void 0}s(ZR,"getNative");var ea=ZR,KO=ea(mr,"WeakMap"),Em=KO,mv=Object.create,WO=function(){function t(){}return s(t,"object"),function(e){if(!zt(e))return{};if(mv)return mv(e);t.prototype=e;var r=new t;return t.prototype=void 0,r}}(),VO=WO;function QR(t,e,r){switch(r.length){case 0:return t.call(e);case 1:return t.call(e,r[0]);case 2:return t.call(e,r[0],r[1]);case 3:return t.call(e,r[0],r[1],r[2])}return t.apply(e,r)}s(QR,"apply");var qO=QR;function eA(){}s(eA,"noop");var He=eA;function tA(t,e){var r=-1,n=t.length;for(e||(e=Array(n));++r<n;)e[r]=t[r];return e}s(tA,"copyArray");var HO=tA,YO=800,XO=16,JO=Date.now;function rA(t){var e=0,r=0;return function(){var n=JO(),a=XO-(n-r);if(r=n,a>0){if(++e>=YO)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}s(rA,"shortOut");var ZO=rA;function nA(t){return function(){return t}}s(nA,"constant");var QO=nA,e0=function(){try{var t=ea(Object,"defineProperty");return t({},"",{}),t}catch{}}(),df=e0,t0=df?function(t,e){return df(t,"toString",{configurable:!0,enumerable:!1,value:QO(e),writable:!0})}:Wu,r0=t0,n0=ZO(r0),a0=n0;function aA(t,e){for(var r=-1,n=t==null?0:t.length;++r<n&&e(t[r],r,t)!==!1;);return t}s(aA,"arrayEach");var iA=aA;function sA(t,e,r,n){for(var a=t.length,i=r+(n?1:-1);n?i--:++i<a;)if(e(t[i],i,t))return i;return-1}s(sA,"baseFindIndex");var oA=sA;function lA(t){return t!==t}s(lA,"baseIsNaN");var i0=lA;function uA(t,e,r){for(var n=r-1,a=t.length;++n<a;)if(t[n]===e)return n;return-1}s(uA,"strictIndexOf");var s0=uA;function cA(t,e,r){return e===e?s0(t,e,r):oA(t,i0,r)}s(cA,"baseIndexOf");var by=cA;function fA(t,e){var r=t==null?0:t.length;return!!r&&by(t,e,0)>-1}s(fA,"arrayIncludes");var dA=fA,o0=9007199254740991,l0=/^(?:0|[1-9]\d*)$/;function pA(t,e){var r=typeof t;return e=e??o0,!!e&&(r=="number"||r!="symbol"&&l0.test(t))&&t>-1&&t%1==0&&t<e}s(pA,"isIndex");var Qf=pA;function mA(t,e,r){e=="__proto__"&&df?df(t,e,{configurable:!0,enumerable:!0,value:r,writable:!0}):t[e]=r}s(mA,"baseAssignValue");var _y=mA;function hA(t,e){return t===e||t!==t&&e!==e}s(hA,"eq");var Vu=hA,u0=Object.prototype,c0=u0.hasOwnProperty;function yA(t,e,r){var n=t[e];(!(c0.call(t,e)&&Vu(n,r))||r===void 0&&!(e in t))&&_y(t,e,r)}s(yA,"assignValue");var ed=yA;function gA(t,e,r,n){var a=!r;r||(r={});for(var i=-1,o=e.length;++i<o;){var u=e[i],l=n?n(r[u],t[u],u,r,t):void 0;l===void 0&&(l=t[u]),a?_y(r,u,l):ed(r,u,l)}return r}s(gA,"copyObject");var qu=gA,hv=Math.max;function vA(t,e,r){return e=hv(e===void 0?t.length-1:e,0),function(){for(var n=arguments,a=-1,i=hv(n.length-e,0),o=Array(i);++a<i;)o[a]=n[e+a];a=-1;for(var u=Array(e+1);++a<e;)u[a]=n[a];return u[e]=r(o),qO(t,this,u)}}s(vA,"overRest");var f0=vA;function TA(t,e){return a0(f0(t,e,Wu),t+"")}s(TA,"baseRest");var Sy=TA,d0=9007199254740991;function $A(t){return typeof t=="number"&&t>-1&&t%1==0&&t<=d0}s($A,"isLength");var wy=$A;function RA(t){return t!=null&&wy(t.length)&&!Gr(t)}s(RA,"isArrayLike");var hr=RA;function AA(t,e,r){if(!zt(r))return!1;var n=typeof e;return(n=="number"?hr(r)&&Qf(e,r.length):n=="string"&&e in r)?Vu(r[e],t):!1}s(AA,"isIterateeCall");var td=AA;function EA(t){return Sy(function(e,r){var n=-1,a=r.length,i=a>1?r[a-1]:void 0,o=a>2?r[2]:void 0;for(i=t.length>3&&typeof i=="function"?(a--,i):void 0,o&&td(r[0],r[1],o)&&(i=a<3?void 0:i,a=1),e=Object(e);++n<a;){var u=r[n];u&&t(e,u,n,i)}return e})}s(EA,"createAssigner");var p0=EA,m0=Object.prototype;function CA(t){var e=t&&t.constructor,r=typeof e=="function"&&e.prototype||m0;return t===r}s(CA,"isPrototype");var Hu=CA;function bA(t,e){for(var r=-1,n=Array(t);++r<t;)n[r]=e(r);return n}s(bA,"baseTimes");var h0=bA,y0="[object Arguments]";function _A(t){return Xt(t)&&nn(t)==y0}s(_A,"baseIsArguments");var yv=_A,SA=Object.prototype,g0=SA.hasOwnProperty,v0=SA.propertyIsEnumerable,T0=yv(function(){return arguments}())?yv:function(t){return Xt(t)&&g0.call(t,"callee")&&!v0.call(t,"callee")},rd=T0;function wA(){return!1}s(wA,"stubFalse");var $0=wA,IA=typeof exports=="object"&&exports&&!exports.nodeType&&exports,gv=IA&&typeof module=="object"&&module&&!module.nodeType&&module,R0=gv&&gv.exports===IA,vv=R0?mr.Buffer:void 0,A0=vv?vv.isBuffer:void 0,E0=A0||$0,Ru=E0,C0="[object Arguments]",b0="[object Array]",_0="[object Boolean]",S0="[object Date]",w0="[object Error]",I0="[object Function]",N0="[object Map]",P0="[object Number]",k0="[object Object]",O0="[object RegExp]",L0="[object Set]",D0="[object String]",x0="[object WeakMap]",M0="[object ArrayBuffer]",G0="[object DataView]",F0="[object Float32Array]",z0="[object Float64Array]",j0="[object Int8Array]",B0="[object Int16Array]",U0="[object Int32Array]",K0="[object Uint8Array]",W0="[object Uint8ClampedArray]",V0="[object Uint16Array]",q0="[object Uint32Array]",be={};be[F0]=be[z0]=be[j0]=be[B0]=be[U0]=be[K0]=be[W0]=be[V0]=be[q0]=!0;be[C0]=be[b0]=be[M0]=be[_0]=be[G0]=be[S0]=be[w0]=be[I0]=be[N0]=be[P0]=be[k0]=be[O0]=be[L0]=be[D0]=be[x0]=!1;function NA(t){return Xt(t)&&wy(t.length)&&!!be[nn(t)]}s(NA,"baseIsTypedArray");var H0=NA;function PA(t){return function(e){return t(e)}}s(PA,"baseUnary");var Yu=PA,kA=typeof exports=="object"&&exports&&!exports.nodeType&&exports,fu=kA&&typeof module=="object"&&module&&!module.nodeType&&module,Y0=fu&&fu.exports===kA,Wd=Y0&&kR.process,X0=function(){try{var t=fu&&fu.require&&fu.require("util").types;return t||Wd&&Wd.binding&&Wd.binding("util")}catch{}}(),Jr=X0,Tv=Jr&&Jr.isTypedArray,J0=Tv?Yu(Tv):H0,Iy=J0,Z0=Object.prototype,Q0=Z0.hasOwnProperty;function OA(t,e){var r=se(t),n=!r&&rd(t),a=!r&&!n&&Ru(t),i=!r&&!n&&!a&&Iy(t),o=r||n||a||i,u=o?h0(t.length,String):[],l=u.length;for(var c in t)(e||Q0.call(t,c))&&!(o&&(c=="length"||a&&(c=="offset"||c=="parent")||i&&(c=="buffer"||c=="byteLength"||c=="byteOffset")||Qf(c,l)))&&u.push(c);return u}s(OA,"arrayLikeKeys");var LA=OA;function DA(t,e){return function(r){return t(e(r))}}s(DA,"overArg");var xA=DA,eL=xA(Object.keys,Object),tL=eL,rL=Object.prototype,nL=rL.hasOwnProperty;function MA(t){if(!Hu(t))return tL(t);var e=[];for(var r in Object(t))nL.call(t,r)&&r!="constructor"&&e.push(r);return e}s(MA,"baseKeys");var GA=MA;function FA(t){return hr(t)?LA(t):GA(t)}s(FA,"keys");var Nt=FA,aL=Object.prototype,iL=aL.hasOwnProperty,sL=p0(function(t,e){if(Hu(e)||hr(e)){qu(e,Nt(e),t);return}for(var r in e)iL.call(e,r)&&ed(t,r,e[r])}),Pt=sL;function zA(t){var e=[];if(t!=null)for(var r in Object(t))e.push(r);return e}s(zA,"nativeKeysIn");var oL=zA,lL=Object.prototype,uL=lL.hasOwnProperty;function jA(t){if(!zt(t))return oL(t);var e=Hu(t),r=[];for(var n in t)n=="constructor"&&(e||!uL.call(t,n))||r.push(n);return r}s(jA,"baseKeysIn");var cL=jA;function BA(t){return hr(t)?LA(t,!0):cL(t)}s(BA,"keysIn");var nd=BA,fL=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,dL=/^\w*$/;function UA(t,e){if(se(t))return!1;var r=typeof t;return r=="number"||r=="symbol"||r=="boolean"||t==null||Zf(t)?!0:dL.test(t)||!fL.test(t)||e!=null&&t in Object(e)}s(UA,"isKey");var Ny=UA,pL=ea(Object,"create"),Au=pL;function KA(){this.__data__=Au?Au(null):{},this.size=0}s(KA,"hashClear");var mL=KA;function WA(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}s(WA,"hashDelete");var hL=WA,yL="__lodash_hash_undefined__",gL=Object.prototype,vL=gL.hasOwnProperty;function VA(t){var e=this.__data__;if(Au){var r=e[t];return r===yL?void 0:r}return vL.call(e,t)?e[t]:void 0}s(VA,"hashGet");var TL=VA,$L=Object.prototype,RL=$L.hasOwnProperty;function qA(t){var e=this.__data__;return Au?e[t]!==void 0:RL.call(e,t)}s(qA,"hashHas");var AL=qA,EL="__lodash_hash_undefined__";function HA(t,e){var r=this.__data__;return this.size+=this.has(t)?0:1,r[t]=Au&&e===void 0?EL:e,this}s(HA,"hashSet");var CL=HA;function ta(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}s(ta,"Hash");ta.prototype.clear=mL;ta.prototype.delete=hL;ta.prototype.get=TL;ta.prototype.has=AL;ta.prototype.set=CL;var $v=ta;function YA(){this.__data__=[],this.size=0}s(YA,"listCacheClear");var bL=YA;function XA(t,e){for(var r=t.length;r--;)if(Vu(t[r][0],e))return r;return-1}s(XA,"assocIndexOf");var ad=XA,_L=Array.prototype,SL=_L.splice;function JA(t){var e=this.__data__,r=ad(e,t);if(r<0)return!1;var n=e.length-1;return r==n?e.pop():SL.call(e,r,1),--this.size,!0}s(JA,"listCacheDelete");var wL=JA;function ZA(t){var e=this.__data__,r=ad(e,t);return r<0?void 0:e[r][1]}s(ZA,"listCacheGet");var IL=ZA;function QA(t){return ad(this.__data__,t)>-1}s(QA,"listCacheHas");var NL=QA;function eE(t,e){var r=this.__data__,n=ad(r,t);return n<0?(++this.size,r.push([t,e])):r[n][1]=e,this}s(eE,"listCacheSet");var PL=eE;function ra(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}s(ra,"ListCache");ra.prototype.clear=bL;ra.prototype.delete=wL;ra.prototype.get=IL;ra.prototype.has=NL;ra.prototype.set=PL;var id=ra,kL=ea(mr,"Map"),Eu=kL;function tE(){this.size=0,this.__data__={hash:new $v,map:new(Eu||id),string:new $v}}s(tE,"mapCacheClear");var OL=tE;function rE(t){var e=typeof t;return e=="string"||e=="number"||e=="symbol"||e=="boolean"?t!=="__proto__":t===null}s(rE,"isKeyable");var LL=rE;function nE(t,e){var r=t.__data__;return LL(e)?r[typeof e=="string"?"string":"hash"]:r.map}s(nE,"getMapData");var sd=nE;function aE(t){var e=sd(this,t).delete(t);return this.size-=e?1:0,e}s(aE,"mapCacheDelete");var DL=aE;function iE(t){return sd(this,t).get(t)}s(iE,"mapCacheGet");var xL=iE;function sE(t){return sd(this,t).has(t)}s(sE,"mapCacheHas");var ML=sE;function oE(t,e){var r=sd(this,t),n=r.size;return r.set(t,e),this.size+=r.size==n?0:1,this}s(oE,"mapCacheSet");var GL=oE;function na(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}s(na,"MapCache");na.prototype.clear=OL;na.prototype.delete=DL;na.prototype.get=xL;na.prototype.has=ML;na.prototype.set=GL;var od=na,FL="Expected a function";function ld(t,e){if(typeof t!="function"||e!=null&&typeof e!="function")throw new TypeError(FL);var r=s(function(){var n=arguments,a=e?e.apply(this,n):n[0],i=r.cache;if(i.has(a))return i.get(a);var o=t.apply(this,n);return r.cache=i.set(a,o)||i,o},"memoized");return r.cache=new(ld.Cache||od),r}s(ld,"memoize");ld.Cache=od;var zL=ld,jL=500;function lE(t){var e=zL(t,function(n){return r.size===jL&&r.clear(),n}),r=e.cache;return e}s(lE,"memoizeCapped");var BL=lE,UL=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,KL=/\\(\\)?/g,WL=BL(function(t){var e=[];return t.charCodeAt(0)===46&&e.push(""),t.replace(UL,function(r,n,a,i){e.push(a?i.replace(KL,"$1"):n||r)}),e}),VL=WL;function uE(t){return t==null?"":hO(t)}s(uE,"toString");var qL=uE;function cE(t,e){return se(t)?t:Ny(t,e)?[t]:VL(qL(t))}s(cE,"castPath");var ud=cE;function fE(t){if(typeof t=="string"||Zf(t))return t;var e=t+"";return e=="0"&&1/t==-1/0?"-0":e}s(fE,"toKey");var Xu=fE;function dE(t,e){e=ud(e,t);for(var r=0,n=e.length;t!=null&&r<n;)t=t[Xu(e[r++])];return r&&r==n?t:void 0}s(dE,"baseGet");var Py=dE;function pE(t,e,r){var n=t==null?void 0:Py(t,e);return n===void 0?r:n}s(pE,"get");var HL=pE;function mE(t,e){for(var r=-1,n=e.length,a=t.length;++r<n;)t[a+r]=e[r];return t}s(mE,"arrayPush");var ky=mE,Rv=Ft?Ft.isConcatSpreadable:void 0;function hE(t){return se(t)||rd(t)||!!(Rv&&t&&t[Rv])}s(hE,"isFlattenable");var YL=hE;function Oy(t,e,r,n,a){var i=-1,o=t.length;for(r||(r=YL),a||(a=[]);++i<o;){var u=t[i];e>0&&r(u)?e>1?Oy(u,e-1,r,n,a):ky(a,u):n||(a[a.length]=u)}return a}s(Oy,"baseFlatten");var Ly=Oy;function yE(t){var e=t==null?0:t.length;return e?Ly(t,1):[]}s(yE,"flatten");var Ht=yE,XL=xA(Object.getPrototypeOf,Object),gE=XL;function vE(t,e,r){var n=-1,a=t.length;e<0&&(e=-e>a?0:a+e),r=r>a?a:r,r<0&&(r+=a),a=e>r?0:r-e>>>0,e>>>=0;for(var i=Array(a);++n<a;)i[n]=t[n+e];return i}s(vE,"baseSlice");var TE=vE;function $E(t,e,r,n){var a=-1,i=t==null?0:t.length;for(n&&i&&(r=t[++a]);++a<i;)r=e(r,t[a],a,t);return r}s($E,"arrayReduce");var JL=$E;function RE(){this.__data__=new id,this.size=0}s(RE,"stackClear");var ZL=RE;function AE(t){var e=this.__data__,r=e.delete(t);return this.size=e.size,r}s(AE,"stackDelete");var QL=AE;function EE(t){return this.__data__.get(t)}s(EE,"stackGet");var eD=EE;function CE(t){return this.__data__.has(t)}s(CE,"stackHas");var tD=CE,rD=200;function bE(t,e){var r=this.__data__;if(r instanceof id){var n=r.__data__;if(!Eu||n.length<rD-1)return n.push([t,e]),this.size=++r.size,this;r=this.__data__=new od(n)}return r.set(t,e),this.size=r.size,this}s(bE,"stackSet");var nD=bE;function aa(t){var e=this.__data__=new id(t);this.size=e.size}s(aa,"Stack");aa.prototype.clear=ZL;aa.prototype.delete=QL;aa.prototype.get=eD;aa.prototype.has=tD;aa.prototype.set=nD;var du=aa;function _E(t,e){return t&&qu(e,Nt(e),t)}s(_E,"baseAssign");var aD=_E;function SE(t,e){return t&&qu(e,nd(e),t)}s(SE,"baseAssignIn");var iD=SE,wE=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Av=wE&&typeof module=="object"&&module&&!module.nodeType&&module,sD=Av&&Av.exports===wE,Ev=sD?mr.Buffer:void 0,Cv=Ev?Ev.allocUnsafe:void 0;function IE(t,e){if(e)return t.slice();var r=t.length,n=Cv?Cv(r):new t.constructor(r);return t.copy(n),n}s(IE,"cloneBuffer");var oD=IE;function NE(t,e){for(var r=-1,n=t==null?0:t.length,a=0,i=[];++r<n;){var o=t[r];e(o,r,t)&&(i[a++]=o)}return i}s(NE,"arrayFilter");var Dy=NE;function PE(){return[]}s(PE,"stubArray");var kE=PE,lD=Object.prototype,uD=lD.propertyIsEnumerable,bv=Object.getOwnPropertySymbols,cD=bv?function(t){return t==null?[]:(t=Object(t),Dy(bv(t),function(e){return uD.call(t,e)}))}:kE,xy=cD;function OE(t,e){return qu(t,xy(t),e)}s(OE,"copySymbols");var fD=OE,dD=Object.getOwnPropertySymbols,pD=dD?function(t){for(var e=[];t;)ky(e,xy(t)),t=gE(t);return e}:kE,LE=pD;function DE(t,e){return qu(t,LE(t),e)}s(DE,"copySymbolsIn");var mD=DE;function xE(t,e,r){var n=e(t);return se(t)?n:ky(n,r(t))}s(xE,"baseGetAllKeys");var ME=xE;function GE(t){return ME(t,Nt,xy)}s(GE,"getAllKeys");var Cm=GE;function FE(t){return ME(t,nd,LE)}s(FE,"getAllKeysIn");var zE=FE,hD=ea(mr,"DataView"),bm=hD,yD=ea(mr,"Promise"),_m=yD,gD=ea(mr,"Set"),Xa=gD,_v="[object Map]",vD="[object Object]",Sv="[object Promise]",wv="[object Set]",Iv="[object WeakMap]",Nv="[object DataView]",TD=Qn(bm),$D=Qn(Eu),RD=Qn(_m),AD=Qn(Xa),ED=Qn(Em),yn=nn;(bm&&yn(new bm(new ArrayBuffer(1)))!=Nv||Eu&&yn(new Eu)!=_v||_m&&yn(_m.resolve())!=Sv||Xa&&yn(new Xa)!=wv||Em&&yn(new Em)!=Iv)&&(yn=s(function(t){var e=nn(t),r=e==vD?t.constructor:void 0,n=r?Qn(r):"";if(n)switch(n){case TD:return Nv;case $D:return _v;case RD:return Sv;case AD:return wv;case ED:return Iv}return e},"getTag"));var el=yn,CD=Object.prototype,bD=CD.hasOwnProperty;function jE(t){var e=t.length,r=new t.constructor(e);return e&&typeof t[0]=="string"&&bD.call(t,"index")&&(r.index=t.index,r.input=t.input),r}s(jE,"initCloneArray");var _D=jE,SD=mr.Uint8Array,pf=SD;function BE(t){var e=new t.constructor(t.byteLength);return new pf(e).set(new pf(t)),e}s(BE,"cloneArrayBuffer");var My=BE;function UE(t,e){var r=e?My(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.byteLength)}s(UE,"cloneDataView");var wD=UE,ID=/\w*$/;function KE(t){var e=new t.constructor(t.source,ID.exec(t));return e.lastIndex=t.lastIndex,e}s(KE,"cloneRegExp");var ND=KE,Pv=Ft?Ft.prototype:void 0,kv=Pv?Pv.valueOf:void 0;function WE(t){return kv?Object(kv.call(t)):{}}s(WE,"cloneSymbol");var PD=WE;function VE(t,e){var r=e?My(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.length)}s(VE,"cloneTypedArray");var kD=VE,OD="[object Boolean]",LD="[object Date]",DD="[object Map]",xD="[object Number]",MD="[object RegExp]",GD="[object Set]",FD="[object String]",zD="[object Symbol]",jD="[object ArrayBuffer]",BD="[object DataView]",UD="[object Float32Array]",KD="[object Float64Array]",WD="[object Int8Array]",VD="[object Int16Array]",qD="[object Int32Array]",HD="[object Uint8Array]",YD="[object Uint8ClampedArray]",XD="[object Uint16Array]",JD="[object Uint32Array]";function qE(t,e,r){var n=t.constructor;switch(e){case jD:return My(t);case OD:case LD:return new n(+t);case BD:return wD(t,r);case UD:case KD:case WD:case VD:case qD:case HD:case YD:case XD:case JD:return kD(t,r);case DD:return new n;case xD:case FD:return new n(t);case MD:return ND(t);case GD:return new n;case zD:return PD(t)}}s(qE,"initCloneByTag");var ZD=qE;function HE(t){return typeof t.constructor=="function"&&!Hu(t)?VO(gE(t)):{}}s(HE,"initCloneObject");var QD=HE,ex="[object Map]";function YE(t){return Xt(t)&&el(t)==ex}s(YE,"baseIsMap");var tx=YE,Ov=Jr&&Jr.isMap,rx=Ov?Yu(Ov):tx,nx=rx,ax="[object Set]";function XE(t){return Xt(t)&&el(t)==ax}s(XE,"baseIsSet");var ix=XE,Lv=Jr&&Jr.isSet,sx=Lv?Yu(Lv):ix,ox=sx,lx=1,ux=2,cx=4,JE="[object Arguments]",fx="[object Array]",dx="[object Boolean]",px="[object Date]",mx="[object Error]",ZE="[object Function]",hx="[object GeneratorFunction]",yx="[object Map]",gx="[object Number]",QE="[object Object]",vx="[object RegExp]",Tx="[object Set]",$x="[object String]",Rx="[object Symbol]",Ax="[object WeakMap]",Ex="[object ArrayBuffer]",Cx="[object DataView]",bx="[object Float32Array]",_x="[object Float64Array]",Sx="[object Int8Array]",wx="[object Int16Array]",Ix="[object Int32Array]",Nx="[object Uint8Array]",Px="[object Uint8ClampedArray]",kx="[object Uint16Array]",Ox="[object Uint32Array]",Te={};Te[JE]=Te[fx]=Te[Ex]=Te[Cx]=Te[dx]=Te[px]=Te[bx]=Te[_x]=Te[Sx]=Te[wx]=Te[Ix]=Te[yx]=Te[gx]=Te[QE]=Te[vx]=Te[Tx]=Te[$x]=Te[Rx]=Te[Nx]=Te[Px]=Te[kx]=Te[Ox]=!0;Te[mx]=Te[ZE]=Te[Ax]=!1;function pu(t,e,r,n,a,i){var o,u=e&lx,l=e&ux,c=e&cx;if(r&&(o=a?r(t,n,a,i):r(t)),o!==void 0)return o;if(!zt(t))return t;var f=se(t);if(f){if(o=_D(t),!u)return HO(t,o)}else{var d=el(t),p=d==ZE||d==hx;if(Ru(t))return oD(t,u);if(d==QE||d==JE||p&&!a){if(o=l||p?{}:QD(t),!u)return l?mD(t,iD(o,t)):fD(t,aD(o,t))}else{if(!Te[d])return a?t:{};o=ZD(t,d,u)}}i||(i=new du);var y=i.get(t);if(y)return y;i.set(t,o),ox(t)?t.forEach(function(C){o.add(pu(C,e,r,C,t,i))}):nx(t)&&t.forEach(function(C,T){o.set(T,pu(C,e,r,T,t,i))});var h=c?l?zE:Cm:l?nd:Nt,$=f?void 0:h(t);return iA($||t,function(C,T){$&&(T=C,C=t[T]),ed(o,T,pu(C,e,r,T,t,i))}),o}s(pu,"baseClone");var Lx=pu,Dx=4;function eC(t){return Lx(t,Dx)}s(eC,"clone");var it=eC;function tC(t){for(var e=-1,r=t==null?0:t.length,n=0,a=[];++e<r;){var i=t[e];i&&(a[n++]=i)}return a}s(tC,"compact");var Ju=tC,xx="__lodash_hash_undefined__";function rC(t){return this.__data__.set(t,xx),this}s(rC,"setCacheAdd");var Mx=rC;function nC(t){return this.__data__.has(t)}s(nC,"setCacheHas");var Gx=nC;function Cu(t){var e=-1,r=t==null?0:t.length;for(this.__data__=new od;++e<r;)this.add(t[e])}s(Cu,"SetCache");Cu.prototype.add=Cu.prototype.push=Mx;Cu.prototype.has=Gx;var Gy=Cu;function aC(t,e){for(var r=-1,n=t==null?0:t.length;++r<n;)if(e(t[r],r,t))return!0;return!1}s(aC,"arraySome");var iC=aC;function sC(t,e){return t.has(e)}s(sC,"cacheHas");var Fy=sC,Fx=1,zx=2;function oC(t,e,r,n,a,i){var o=r&Fx,u=t.length,l=e.length;if(u!=l&&!(o&&l>u))return!1;var c=i.get(t),f=i.get(e);if(c&&f)return c==e&&f==t;var d=-1,p=!0,y=r&zx?new Gy:void 0;for(i.set(t,e),i.set(e,t);++d<u;){var h=t[d],$=e[d];if(n)var C=o?n($,h,d,e,t,i):n(h,$,d,t,e,i);if(C!==void 0){if(C)continue;p=!1;break}if(y){if(!iC(e,function(T,w){if(!Fy(y,w)&&(h===T||a(h,T,r,n,i)))return y.push(w)})){p=!1;break}}else if(!(h===$||a(h,$,r,n,i))){p=!1;break}}return i.delete(t),i.delete(e),p}s(oC,"equalArrays");var lC=oC;function uC(t){var e=-1,r=Array(t.size);return t.forEach(function(n,a){r[++e]=[a,n]}),r}s(uC,"mapToArray");var jx=uC;function cC(t){var e=-1,r=Array(t.size);return t.forEach(function(n){r[++e]=n}),r}s(cC,"setToArray");var zy=cC,Bx=1,Ux=2,Kx="[object Boolean]",Wx="[object Date]",Vx="[object Error]",qx="[object Map]",Hx="[object Number]",Yx="[object RegExp]",Xx="[object Set]",Jx="[object String]",Zx="[object Symbol]",Qx="[object ArrayBuffer]",eM="[object DataView]",Dv=Ft?Ft.prototype:void 0,Vd=Dv?Dv.valueOf:void 0;function fC(t,e,r,n,a,i,o){switch(r){case eM:if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case Qx:return!(t.byteLength!=e.byteLength||!i(new pf(t),new pf(e)));case Kx:case Wx:case Hx:return Vu(+t,+e);case Vx:return t.name==e.name&&t.message==e.message;case Yx:case Jx:return t==e+"";case qx:var u=jx;case Xx:var l=n&Bx;if(u||(u=zy),t.size!=e.size&&!l)return!1;var c=o.get(t);if(c)return c==e;n|=Ux,o.set(t,e);var f=lC(u(t),u(e),n,a,i,o);return o.delete(t),f;case Zx:if(Vd)return Vd.call(t)==Vd.call(e)}return!1}s(fC,"equalByTag");var tM=fC,rM=1,nM=Object.prototype,aM=nM.hasOwnProperty;function dC(t,e,r,n,a,i){var o=r&rM,u=Cm(t),l=u.length,c=Cm(e),f=c.length;if(l!=f&&!o)return!1;for(var d=l;d--;){var p=u[d];if(!(o?p in e:aM.call(e,p)))return!1}var y=i.get(t),h=i.get(e);if(y&&h)return y==e&&h==t;var $=!0;i.set(t,e),i.set(e,t);for(var C=o;++d<l;){p=u[d];var T=t[p],w=e[p];if(n)var b=o?n(w,T,p,e,t,i):n(T,w,p,t,e,i);if(!(b===void 0?T===w||a(T,w,r,n,i):b)){$=!1;break}C||(C=p=="constructor")}if($&&!C){var N=t.constructor,B=e.constructor;N!=B&&"constructor"in t&&"constructor"in e&&!(typeof N=="function"&&N instanceof N&&typeof B=="function"&&B instanceof B)&&($=!1)}return i.delete(t),i.delete(e),$}s(dC,"equalObjects");var iM=dC,sM=1,xv="[object Arguments]",Mv="[object Array]",ic="[object Object]",oM=Object.prototype,Gv=oM.hasOwnProperty;function pC(t,e,r,n,a,i){var o=se(t),u=se(e),l=o?Mv:el(t),c=u?Mv:el(e);l=l==xv?ic:l,c=c==xv?ic:c;var f=l==ic,d=c==ic,p=l==c;if(p&&Ru(t)){if(!Ru(e))return!1;o=!0,f=!1}if(p&&!f)return i||(i=new du),o||Iy(t)?lC(t,e,r,n,a,i):tM(t,e,l,r,n,a,i);if(!(r&sM)){var y=f&&Gv.call(t,"__wrapped__"),h=d&&Gv.call(e,"__wrapped__");if(y||h){var $=y?t.value():t,C=h?e.value():e;return i||(i=new du),a($,C,r,n,i)}}return p?(i||(i=new du),iM(t,e,r,n,a,i)):!1}s(pC,"baseIsEqualDeep");var lM=pC;function jy(t,e,r,n,a){return t===e?!0:t==null||e==null||!Xt(t)&&!Xt(e)?t!==t&&e!==e:lM(t,e,r,n,jy,a)}s(jy,"baseIsEqual");var mC=jy,uM=1,cM=2;function hC(t,e,r,n){var a=r.length,i=a,o=!n;if(t==null)return!i;for(t=Object(t);a--;){var u=r[a];if(o&&u[2]?u[1]!==t[u[0]]:!(u[0]in t))return!1}for(;++a<i;){u=r[a];var l=u[0],c=t[l],f=u[1];if(o&&u[2]){if(c===void 0&&!(l in t))return!1}else{var d=new du;if(n)var p=n(c,f,l,t,e,d);if(!(p===void 0?mC(f,c,uM|cM,n,d):p))return!1}}return!0}s(hC,"baseIsMatch");var fM=hC;function yC(t){return t===t&&!zt(t)}s(yC,"isStrictComparable");var gC=yC;function vC(t){for(var e=Nt(t),r=e.length;r--;){var n=e[r],a=t[n];e[r]=[n,a,gC(a)]}return e}s(vC,"getMatchData");var dM=vC;function TC(t,e){return function(r){return r==null?!1:r[t]===e&&(e!==void 0||t in Object(r))}}s(TC,"matchesStrictComparable");var $C=TC;function RC(t){var e=dM(t);return e.length==1&&e[0][2]?$C(e[0][0],e[0][1]):function(r){return r===t||fM(r,t,e)}}s(RC,"baseMatches");var pM=RC;function AC(t,e){return t!=null&&e in Object(t)}s(AC,"baseHasIn");var mM=AC;function EC(t,e,r){e=ud(e,t);for(var n=-1,a=e.length,i=!1;++n<a;){var o=Xu(e[n]);if(!(i=t!=null&&r(t,o)))break;t=t[o]}return i||++n!=a?i:(a=t==null?0:t.length,!!a&&wy(a)&&Qf(o,a)&&(se(t)||rd(t)))}s(EC,"hasPath");var CC=EC;function bC(t,e){return t!=null&&CC(t,e,mM)}s(bC,"hasIn");var hM=bC,yM=1,gM=2;function _C(t,e){return Ny(t)&&gC(e)?$C(Xu(t),e):function(r){var n=HL(r,t);return n===void 0&&n===e?hM(r,t):mC(e,n,yM|gM)}}s(_C,"baseMatchesProperty");var vM=_C;function SC(t){return function(e){return e?.[t]}}s(SC,"baseProperty");var TM=SC;function wC(t){return function(e){return Py(e,t)}}s(wC,"basePropertyDeep");var $M=wC;function IC(t){return Ny(t)?TM(Xu(t)):$M(t)}s(IC,"property");var RM=IC;function NC(t){return typeof t=="function"?t:t==null?Wu:typeof t=="object"?se(t)?vM(t[0],t[1]):pM(t):RM(t)}s(NC,"baseIteratee");var yr=NC;function PC(t,e,r,n){for(var a=-1,i=t==null?0:t.length;++a<i;){var o=t[a];e(n,o,r(o),t)}return n}s(PC,"arrayAggregator");var AM=PC;function kC(t){return function(e,r,n){for(var a=-1,i=Object(e),o=n(e),u=o.length;u--;){var l=o[t?u:++a];if(r(i[l],l,i)===!1)break}return e}}s(kC,"createBaseFor");var EM=kC,CM=EM(),bM=CM;function OC(t,e){return t&&bM(t,e,Nt)}s(OC,"baseForOwn");var _M=OC;function LC(t,e){return function(r,n){if(r==null)return r;if(!hr(r))return t(r,n);for(var a=r.length,i=e?a:-1,o=Object(r);(e?i--:++i<a)&&n(o[i],i,o)!==!1;);return r}}s(LC,"createBaseEach");var SM=LC,wM=SM(_M),ia=wM;function DC(t,e,r,n){return ia(t,function(a,i,o){e(n,a,r(a),o)}),n}s(DC,"baseAggregator");var IM=DC;function xC(t,e){return function(r,n){var a=se(r)?AM:IM,i=e?e():{};return a(r,t,yr(n),i)}}s(xC,"createAggregator");var NM=xC,MC=Object.prototype,PM=MC.hasOwnProperty,kM=Sy(function(t,e){t=Object(t);var r=-1,n=e.length,a=n>2?e[2]:void 0;for(a&&td(e[0],e[1],a)&&(n=1);++r<n;)for(var i=e[r],o=nd(i),u=-1,l=o.length;++u<l;){var c=o[u],f=t[c];(f===void 0||Vu(f,MC[c])&&!PM.call(t,c))&&(t[c]=i[c])}return t}),By=kM;function GC(t){return Xt(t)&&hr(t)}s(GC,"isArrayLikeObject");var Fv=GC;function FC(t,e,r){for(var n=-1,a=t==null?0:t.length;++n<a;)if(r(e,t[n]))return!0;return!1}s(FC,"arrayIncludesWith");var zC=FC,OM=200;function jC(t,e,r,n){var a=-1,i=dA,o=!0,u=t.length,l=[],c=e.length;if(!u)return l;r&&(e=Uu(e,Yu(r))),n?(i=zC,o=!1):e.length>=OM&&(i=Fy,o=!1,e=new Gy(e));e:for(;++a<u;){var f=t[a],d=r==null?f:r(f);if(f=n||f!==0?f:0,o&&d===d){for(var p=c;p--;)if(e[p]===d)continue e;l.push(f)}else i(e,d,n)||l.push(f)}return l}s(jC,"baseDifference");var LM=jC,DM=Sy(function(t,e){return Fv(t)?LM(t,Ly(e,1,Fv,!0)):[]}),cd=DM;function BC(t){var e=t==null?0:t.length;return e?t[e-1]:void 0}s(BC,"last");var Un=BC;function UC(t,e,r){var n=t==null?0:t.length;return n?(e=r||e===void 0?1:Ku(e),TE(t,e<0?0:e,n)):[]}s(UC,"drop");var nt=UC;function KC(t,e,r){var n=t==null?0:t.length;return n?(e=r||e===void 0?1:Ku(e),e=n-e,TE(t,0,e<0?0:e)):[]}s(KC,"dropRight");var bu=KC;function WC(t){return typeof t=="function"?t:Wu}s(WC,"castFunction");var xM=WC;function VC(t,e){var r=se(t)?iA:ia;return r(t,xM(e))}s(VC,"forEach");var V=VC;function qC(t,e){for(var r=-1,n=t==null?0:t.length;++r<n;)if(!e(t[r],r,t))return!1;return!0}s(qC,"arrayEvery");var MM=qC;function HC(t,e){var r=!0;return ia(t,function(n,a,i){return r=!!e(n,a,i),r}),r}s(HC,"baseEvery");var GM=HC;function YC(t,e,r){var n=se(t)?MM:GM;return r&&td(t,e,r)&&(e=void 0),n(t,yr(e))}s(YC,"every");var Yt=YC;function XC(t,e){var r=[];return ia(t,function(n,a,i){e(n,a,i)&&r.push(n)}),r}s(XC,"baseFilter");var JC=XC;function ZC(t,e){var r=se(t)?Dy:JC;return r(t,yr(e))}s(ZC,"filter");var Bt=ZC;function QC(t){return function(e,r,n){var a=Object(e);if(!hr(e)){var i=yr(r);e=Nt(e),r=s(function(u){return i(a[u],u,a)},"predicate")}var o=t(e,r,n);return o>-1?a[i?e[o]:o]:void 0}}s(QC,"createFind");var FM=QC,zM=Math.max;function eb(t,e,r){var n=t==null?0:t.length;if(!n)return-1;var a=r==null?0:Ku(r);return a<0&&(a=zM(n+a,0)),oA(t,yr(e),a)}s(eb,"findIndex");var jM=eb,BM=FM(jM),tl=BM;function tb(t){return t&&t.length?t[0]:void 0}s(tb,"head");var Jt=tb;function rb(t,e){var r=-1,n=hr(t)?Array(t.length):[];return ia(t,function(a,i,o){n[++r]=e(a,i,o)}),n}s(rb,"baseMap");var UM=rb;function nb(t,e){var r=se(t)?Uu:UM;return r(t,yr(e))}s(nb,"map");var j=nb;function ab(t,e){return Ly(j(t,e),1)}s(ab,"flatMap");var Gt=ab,KM=Object.prototype,WM=KM.hasOwnProperty,VM=NM(function(t,e,r){WM.call(t,r)?t[r].push(e):_y(t,r,[e])}),qM=VM,HM=Object.prototype,YM=HM.hasOwnProperty;function ib(t,e){return t!=null&&YM.call(t,e)}s(ib,"baseHas");var XM=ib;function sb(t,e){return t!=null&&CC(t,e,XM)}s(sb,"has");var K=sb,JM="[object String]";function ob(t){return typeof t=="string"||!se(t)&&Xt(t)&&nn(t)==JM}s(ob,"isString");var Ct=ob;function lb(t,e){return Uu(e,function(r){return t[r]})}s(lb,"baseValues");var ZM=lb;function ub(t){return t==null?[]:ZM(t,Nt(t))}s(ub,"values");var Ke=ub,QM=Math.max;function cb(t,e,r,n){t=hr(t)?t:Ke(t),r=r&&!n?Ku(r):0;var a=t.length;return r<0&&(r=QM(a+r,0)),Ct(t)?r<=a&&t.indexOf(e,r)>-1:!!a&&by(t,e,r)>-1}s(cb,"includes");var vt=cb,e1=Math.max;function fb(t,e,r){var n=t==null?0:t.length;if(!n)return-1;var a=r==null?0:Ku(r);return a<0&&(a=e1(n+a,0)),by(t,e,a)}s(fb,"indexOf");var zv=fb,t1="[object Map]",r1="[object Set]",n1=Object.prototype,a1=n1.hasOwnProperty;function db(t){if(t==null)return!0;if(hr(t)&&(se(t)||typeof t=="string"||typeof t.splice=="function"||Ru(t)||Iy(t)||rd(t)))return!t.length;var e=el(t);if(e==t1||e==r1)return!t.size;if(Hu(t))return!GA(t).length;for(var r in t)if(a1.call(t,r))return!1;return!0}s(db,"isEmpty");var Re=db,i1="[object RegExp]";function pb(t){return Xt(t)&&nn(t)==i1}s(pb,"baseIsRegExp");var s1=pb,jv=Jr&&Jr.isRegExp,o1=jv?Yu(jv):s1,Pr=o1;function mb(t){return t===void 0}s(mb,"isUndefined");var kr=mb,l1="Expected a function";function hb(t){if(typeof t!="function")throw new TypeError(l1);return function(){var e=arguments;switch(e.length){case 0:return!t.call(this);case 1:return!t.call(this,e[0]);case 2:return!t.call(this,e[0],e[1]);case 3:return!t.call(this,e[0],e[1],e[2])}return!t.apply(this,e)}}s(hb,"negate");var u1=hb;function yb(t,e,r,n){if(!zt(t))return t;e=ud(e,t);for(var a=-1,i=e.length,o=i-1,u=t;u!=null&&++a<i;){var l=Xu(e[a]),c=r;if(l==="__proto__"||l==="constructor"||l==="prototype")return t;if(a!=o){var f=u[l];c=n?n(f,l,u):void 0,c===void 0&&(c=zt(f)?f:Qf(e[a+1])?[]:{})}ed(u,l,c),u=u[l]}return t}s(yb,"baseSet");var c1=yb;function gb(t,e,r){for(var n=-1,a=e.length,i={};++n<a;){var o=e[n],u=Py(t,o);r(u,o)&&c1(i,ud(o,t),u)}return i}s(gb,"basePickBy");var f1=gb;function vb(t,e){if(t==null)return{};var r=Uu(zE(t),function(n){return[n]});return e=yr(e),f1(t,r,function(n,a){return e(n,a[0])})}s(vb,"pickBy");var Zt=vb;function Tb(t,e,r,n,a){return a(t,function(i,o,u){r=n?(n=!1,i):e(r,i,o,u)}),r}s(Tb,"baseReduce");var d1=Tb;function $b(t,e,r){var n=se(t)?JL:d1,a=arguments.length<3;return n(t,yr(e),r,a,ia)}s($b,"reduce");var kt=$b;function Rb(t,e){var r=se(t)?Dy:JC;return r(t,u1(yr(e)))}s(Rb,"reject");var fd=Rb;function Ab(t,e){var r;return ia(t,function(n,a,i){return r=e(n,a,i),!r}),!!r}s(Ab,"baseSome");var p1=Ab;function Eb(t,e,r){var n=se(t)?iC:p1;return r&&td(t,e,r)&&(e=void 0),n(t,yr(e))}s(Eb,"some");var Cb=Eb,m1=1/0,h1=Xa&&1/zy(new Xa([,-0]))[1]==m1?function(t){return new Xa(t)}:He,y1=h1,g1=200;function bb(t,e,r){var n=-1,a=dA,i=t.length,o=!0,u=[],l=u;if(r)o=!1,a=zC;else if(i>=g1){var c=e?null:y1(t);if(c)return zy(c);o=!1,a=Fy,l=new Gy}else l=e?[]:u;e:for(;++n<i;){var f=t[n],d=e?e(f):f;if(f=r||f!==0?f:0,o&&d===d){for(var p=l.length;p--;)if(l[p]===d)continue e;e&&l.push(d),u.push(f)}else a(l,d,r)||(l!==u&&l.push(d),u.push(f))}return u}s(bb,"baseUniq");var v1=bb;function _b(t){return t&&t.length?v1(t):[]}s(_b,"uniq");var Uy=_b;function mf(t){console&&console.error&&console.error(`Error: ${t}`)}s(mf,"PRINT_ERROR");function Ky(t){console&&console.warn&&console.warn(`Warning: ${t}`)}s(Ky,"PRINT_WARNING");function Wy(t){const e=new Date().getTime(),r=t();return{time:new Date().getTime()-e,value:r}}s(Wy,"timer");function Vy(t){function e(){}s(e,"FakeConstructor"),e.prototype=t;const r=new e;function n(){return typeof r.bar}return s(n,"fakeAccess"),n(),n(),t}s(Vy,"toFastProperties");function Sb(t){return wb(t)?t.LABEL:t.name}s(Sb,"tokenLabel");function wb(t){return Ct(t.LABEL)&&t.LABEL!==""}s(wb,"hasTokenLabel");var si,gr=(si=class{get definition(){return this._definition}set definition(e){this._definition=e}constructor(e){this._definition=e}accept(e){e.visit(this),V(this.definition,r=>{r.accept(e)})}},s(si,"AbstractProduction"),si),oi,ht=(oi=class extends gr{constructor(e){super([]),this.idx=1,Pt(this,Zt(e,r=>r!==void 0))}set definition(e){}get definition(){return this.referencedRule!==void 0?this.referencedRule.definition:[]}accept(e){e.visit(this)}},s(oi,"NonTerminal"),oi),li,ol=(li=class extends gr{constructor(e){super(e.definition),this.orgText="",Pt(this,Zt(e,r=>r!==void 0))}},s(li,"Rule"),li),ui,bt=(ui=class extends gr{constructor(e){super(e.definition),this.ignoreAmbiguities=!1,Pt(this,Zt(e,r=>r!==void 0))}},s(ui,"Alternative"),ui),ci,at=(ci=class extends gr{constructor(e){super(e.definition),this.idx=1,Pt(this,Zt(e,r=>r!==void 0))}},s(ci,"Option"),ci),fi,Ot=(fi=class extends gr{constructor(e){super(e.definition),this.idx=1,Pt(this,Zt(e,r=>r!==void 0))}},s(fi,"RepetitionMandatory"),fi),di,Lt=(di=class extends gr{constructor(e){super(e.definition),this.idx=1,Pt(this,Zt(e,r=>r!==void 0))}},s(di,"RepetitionMandatoryWithSeparator"),di),pi,xe=(pi=class extends gr{constructor(e){super(e.definition),this.idx=1,Pt(this,Zt(e,r=>r!==void 0))}},s(pi,"Repetition"),pi),mi,_t=(mi=class extends gr{constructor(e){super(e.definition),this.idx=1,Pt(this,Zt(e,r=>r!==void 0))}},s(mi,"RepetitionWithSeparator"),mi),hi,St=(hi=class extends gr{get definition(){return this._definition}set definition(e){this._definition=e}constructor(e){super(e.definition),this.idx=1,this.ignoreAmbiguities=!1,this.hasPredicates=!1,Pt(this,Zt(e,r=>r!==void 0))}},s(hi,"Alternation"),hi),yi,Se=(yi=class{constructor(e){this.idx=1,Pt(this,Zt(e,r=>r!==void 0))}accept(e){e.visit(this)}},s(yi,"Terminal"),yi);function Ib(t){return j(t,mu)}s(Ib,"serializeGrammar");function mu(t){function e(r){return j(r,mu)}if(s(e,"convertDefinition"),t instanceof ht){const r={type:"NonTerminal",name:t.nonTerminalName,idx:t.idx};return Ct(t.label)&&(r.label=t.label),r}else{if(t instanceof bt)return{type:"Alternative",definition:e(t.definition)};if(t instanceof at)return{type:"Option",idx:t.idx,definition:e(t.definition)};if(t instanceof Ot)return{type:"RepetitionMandatory",idx:t.idx,definition:e(t.definition)};if(t instanceof Lt)return{type:"RepetitionMandatoryWithSeparator",idx:t.idx,separator:mu(new Se({terminalType:t.separator})),definition:e(t.definition)};if(t instanceof _t)return{type:"RepetitionWithSeparator",idx:t.idx,separator:mu(new Se({terminalType:t.separator})),definition:e(t.definition)};if(t instanceof xe)return{type:"Repetition",idx:t.idx,definition:e(t.definition)};if(t instanceof St)return{type:"Alternation",idx:t.idx,definition:e(t.definition)};if(t instanceof Se){const r={type:"Terminal",name:t.terminalType.name,label:Sb(t.terminalType),idx:t.idx};Ct(t.label)&&(r.terminalLabel=t.label);const n=t.terminalType.PATTERN;return t.terminalType.PATTERN&&(r.pattern=Pr(n)?n.source:n),r}else{if(t instanceof ol)return{type:"Rule",name:t.name,orgText:t.orgText,definition:e(t.definition)};throw Error("non exhaustive match")}}}s(mu,"serializeProduction");var gi,ll=(gi=class{visit(e){const r=e;switch(r.constructor){case ht:return this.visitNonTerminal(r);case bt:return this.visitAlternative(r);case at:return this.visitOption(r);case Ot:return this.visitRepetitionMandatory(r);case Lt:return this.visitRepetitionMandatoryWithSeparator(r);case _t:return this.visitRepetitionWithSeparator(r);case xe:return this.visitRepetition(r);case St:return this.visitAlternation(r);case Se:return this.visitTerminal(r);case ol:return this.visitRule(r);default:throw Error("non exhaustive match")}}visitNonTerminal(e){}visitAlternative(e){}visitOption(e){}visitRepetition(e){}visitRepetitionMandatory(e){}visitRepetitionMandatoryWithSeparator(e){}visitRepetitionWithSeparator(e){}visitAlternation(e){}visitTerminal(e){}visitRule(e){}},s(gi,"GAstVisitor"),gi);function Nb(t){return t instanceof bt||t instanceof at||t instanceof xe||t instanceof Ot||t instanceof Lt||t instanceof _t||t instanceof Se||t instanceof ol}s(Nb,"isSequenceProd");function _u(t,e=[]){return t instanceof at||t instanceof xe||t instanceof _t?!0:t instanceof St?Cb(t.definition,n=>_u(n,e)):t instanceof ht&&vt(e,t)?!1:t instanceof gr?(t instanceof ht&&e.push(t),Yt(t.definition,n=>_u(n,e))):!1}s(_u,"isOptionalProd");function Pb(t){return t instanceof St}s(Pb,"isBranchingProd");function Kt(t){if(t instanceof ht)return"SUBRULE";if(t instanceof at)return"OPTION";if(t instanceof St)return"OR";if(t instanceof Ot)return"AT_LEAST_ONE";if(t instanceof Lt)return"AT_LEAST_ONE_SEP";if(t instanceof _t)return"MANY_SEP";if(t instanceof xe)return"MANY";if(t instanceof Se)return"CONSUME";throw Error("non exhaustive match")}s(Kt,"getProductionDslName");var vi,dd=(vi=class{walk(e,r=[]){V(e.definition,(n,a)=>{const i=nt(e.definition,a+1);if(n instanceof ht)this.walkProdRef(n,i,r);else if(n instanceof Se)this.walkTerminal(n,i,r);else if(n instanceof bt)this.walkFlat(n,i,r);else if(n instanceof at)this.walkOption(n,i,r);else if(n instanceof Ot)this.walkAtLeastOne(n,i,r);else if(n instanceof Lt)this.walkAtLeastOneSep(n,i,r);else if(n instanceof _t)this.walkManySep(n,i,r);else if(n instanceof xe)this.walkMany(n,i,r);else if(n instanceof St)this.walkOr(n,i,r);else throw Error("non exhaustive match")})}walkTerminal(e,r,n){}walkProdRef(e,r,n){}walkFlat(e,r,n){const a=r.concat(n);this.walk(e,a)}walkOption(e,r,n){const a=r.concat(n);this.walk(e,a)}walkAtLeastOne(e,r,n){const a=[new at({definition:e.definition})].concat(r,n);this.walk(e,a)}walkAtLeastOneSep(e,r,n){const a=Sm(e,r,n);this.walk(e,a)}walkMany(e,r,n){const a=[new at({definition:e.definition})].concat(r,n);this.walk(e,a)}walkManySep(e,r,n){const a=Sm(e,r,n);this.walk(e,a)}walkOr(e,r,n){const a=r.concat(n);V(e.definition,i=>{const o=new bt({definition:[i]});this.walk(o,a)})}},s(vi,"RestWalker"),vi);function Sm(t,e,r){return[new at({definition:[new Se({terminalType:t.separator})].concat(t.definition)})].concat(e,r)}s(Sm,"restForRepetitionWithSeparator");function ul(t){if(t instanceof ht)return ul(t.referencedRule);if(t instanceof Se)return Lb(t);if(Nb(t))return kb(t);if(Pb(t))return Ob(t);throw Error("non exhaustive match")}s(ul,"first");function kb(t){let e=[];const r=t.definition;let n=0,a=r.length>n,i,o=!0;for(;a&&o;)i=r[n],o=_u(i),e=e.concat(ul(i)),n=n+1,a=r.length>n;return Uy(e)}s(kb,"firstForSequence");function Ob(t){const e=j(t.definition,r=>ul(r));return Uy(Ht(e))}s(Ob,"firstForBranching");function Lb(t){return[t.terminalType]}s(Lb,"firstForTerminal");var Db="_~IN~_",Ti,T1=(Ti=class extends dd{constructor(e){super(),this.topProd=e,this.follows={}}startWalking(){return this.walk(this.topProd),this.follows}walkTerminal(e,r,n){}walkProdRef(e,r,n){const a=Mb(e.referencedRule,e.idx)+this.topProd.name,i=r.concat(n),o=new bt({definition:i}),u=ul(o);this.follows[a]=u}},s(Ti,"ResyncFollowsWalker"),Ti);function xb(t){const e={};return V(t,r=>{const n=new T1(r).startWalking();Pt(e,n)}),e}s(xb,"computeAllProdsFollows");function Mb(t,e){return t.name+e+Db}s(Mb,"buildBetweenProdsFollowPrefix");var Pc={},$1=new hR;function Zu(t){const e=t.toString();if(Pc.hasOwnProperty(e))return Pc[e];{const r=$1.pattern(e);return Pc[e]=r,r}}s(Zu,"getRegExpAst");function Gb(){Pc={}}s(Gb,"clearRegExpParserCache");var Fb="Complement Sets are not supported for first char optimization",hf=`Unable to use "first char" lexer optimizations:
46
+ \r \v              \u2028\u2029   \uFEFF`.split("");function Vf(t){const e=typeof t=="string"?new RegExp(t):t;return TR.some(r=>e.test(r))}s(Vf,"isWhitespace");function sl(t){return t.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}s(sl,"escapeRegExp");function oy(t,e){const r=ly(t),n=e.match(r);return!!n&&n[0].length>0}s(oy,"partialMatches");function ly(t){typeof t=="string"&&(t=new RegExp(t));const e=t,r=t.source;let n=0;function a(){let i="",o;function u(c){i+=r.substr(n,c),n+=c}s(u,"appendRaw");function l(c){i+="(?:"+r.substr(n,c)+"|$)",n+=c}for(s(l,"appendOptional");n<r.length;)switch(r[n]){case"\\":switch(r[n+1]){case"c":l(3);break;case"x":l(4);break;case"u":e.unicode?r[n+2]==="{"?l(r.indexOf("}",n)-n+1):l(6):l(2);break;case"p":case"P":e.unicode?l(r.indexOf("}",n)-n+1):l(2);break;case"k":l(r.indexOf(">",n)-n+1);break;default:l(2);break}break;case"[":o=/\[(?:\\.|.)*?\]/g,o.lastIndex=n,o=o.exec(r)||[],l(o[0].length);break;case"|":case"^":case"$":case"*":case"+":case"?":u(1);break;case"{":o=/\{\d+,?\d*\}/g,o.lastIndex=n,o=o.exec(r),o?u(o[0].length):l(1);break;case"(":if(r[n+1]==="?")switch(r[n+2]){case":":i+="(?:",n+=3,i+=a()+"|$)";break;case"=":i+="(?=",n+=3,i+=a()+")";break;case"!":o=n,n+=3,a(),i+=r.substr(o,n-o);break;case"<":switch(r[n+3]){case"=":case"!":o=n,n+=4,a(),i+=r.substr(o,n-o);break;default:u(r.indexOf(">",n)-n+1),i+=a()+"|$)";break}break}else u(1),i+=a()+"|$)";break;case")":return++n,i;default:l(1);break}return i}return s(a,"process"),new RegExp(a(),t.flags)}s(ly,"partialRegExp");function uy(t){return t.rules.find(e=>mt(e)&&e.entry)}s(uy,"getEntryRule");function cy(t){return t.rules.filter(e=>jt(e)&&e.hidden)}s(cy,"getHiddenRules");function qf(t,e){const r=new Set,n=uy(t);if(!n)return new Set(t.rules);const a=[n].concat(cy(t));for(const o of a)fy(o,r,e);const i=new Set;for(const o of t.rules)(r.has(o.name)||jt(o)&&o.hidden)&&i.add(o);return i}s(qf,"getAllReachableRules");function fy(t,e,r){e.add(t.name),Mr(t).forEach(n=>{if(Nr(n)||r&&zf(n)){const a=n.rule.ref;a&&!e.has(a.name)&&fy(a,e,r)}})}s(fy,"ruleDfs");function $R(t){const e=new Set;return Mr(t).forEach(r=>{Xn(r)&&(mt(r.type.ref)&&e.add(r.type.ref),Fu(r.type.ref)&&mt(r.type.ref.$container)&&e.add(r.type.ref.$container))}),e}s($R,"getAllRulesUsedForCrossReferences");function dy(t){if(t.terminal)return t.terminal;if(t.type.ref)return Jf(t.type.ref)?.terminal}s(dy,"getCrossReferenceTerminal");function py(t){return t.hidden&&!Vf(Bu(t))}s(py,"isCommentTerminal");function my(t,e){return!t||!e?[]:Yf(t,e,t.astNode,!0)}s(my,"findNodesForProperty");function Hf(t,e,r){if(!t||!e)return;const n=Yf(t,e,t.astNode,!0);if(n.length!==0)return r!==void 0?r=Math.max(0,Math.min(r,n.length-1)):r=0,n[r]}s(Hf,"findNodeForProperty");function Yf(t,e,r,n){if(!n){const a=Hn(t.grammarSource,wr);if(a&&a.feature===e)return[t]}return Sr(t)&&t.astNode===r?t.content.flatMap(a=>Yf(a,e,r,!1)):[]}s(Yf,"findNodesForPropertyInternal");function RR(t,e){return t?Xf(t,e,t?.astNode):[]}s(RR,"findNodesForKeyword");function hy(t,e,r){if(!t)return;const n=Xf(t,e,t?.astNode);if(n.length!==0)return r!==void 0?r=Math.max(0,Math.min(r,n.length-1)):r=0,n[r]}s(hy,"findNodeForKeyword");function Xf(t,e,r){if(t.astNode!==r)return[];if(Ir(t.grammarSource)&&t.grammarSource.value===e)return[t];const n=Zo(t).iterator();let a;const i=[];do if(a=n.next(),!a.done){const o=a.value;o.astNode===r?Ir(o.grammarSource)&&o.grammarSource.value===e&&i.push(o):n.prune()}while(!a.done);return i}s(Xf,"findNodesForKeywordInternal");function yy(t){const e=t.astNode;for(;e===t.container?.astNode;){const r=Hn(t.grammarSource,wr);if(r)return r;t=t.container}}s(yy,"findAssignment");function Jf(t){let e=t;return Fu(e)&&(Xr(e.$container)?e=e.$container.$container:Yn(e.$container)?e=e.$container:rn(e.$container)),gy(t,e,new Map)}s(Jf,"findNameAssignment");function gy(t,e,r){function n(a,i){let o;return Hn(a,wr)||(o=gy(i,i,r)),r.set(t,o),o}if(s(n,"go"),r.has(t))return r.get(t);r.set(t,void 0);for(const a of Mr(e)){if(wr(a)&&a.feature.toLowerCase()==="name")return r.set(t,a),a;if(Nr(a)&&mt(a.rule.ref))return n(a,a.rule.ref);if(Ff(a)&&a.typeRef?.ref)return n(a,a.typeRef.ref)}}s(gy,"findNameAssignmentInternal");function vy(t){const e=t.$container;if(Jn(e)){const r=e.elements,n=r.indexOf(t);for(let a=n-1;a>=0;a--){const i=r[a];if(Xr(i))return i;{const o=Mr(r[a]).find(Xr);if(o)return o}}}if(Mf(e))return vy(e)}s(vy,"getActionAtElement");function AR(t,e){return t==="?"||t==="*"||Jn(e)&&!!e.guardCondition}s(AR,"isOptionalCardinality");function ER(t){return t==="*"||t==="+"}s(ER,"isArrayCardinality");function CR(t){return t==="+="}s(CR,"isArrayOperator");function zu(t){return Ty(t,new Set)}s(zu,"isDataTypeRule");function Ty(t,e){if(e.has(t))return!0;e.add(t);for(const r of Mr(t))if(Nr(r)){if(!r.rule.ref||mt(r.rule.ref)&&!Ty(r.rule.ref,e)||Jo(r.rule.ref))return!1}else{if(wr(r))return!1;if(Xr(r))return!1}return!!t.definition}s(Ty,"isDataTypeRuleInternal");function bR(t){return ff(t.type,new Set)}s(bR,"isDataType");function ff(t,e){if(e.has(t))return!0;if(e.add(t),Nh(t))return!1;if(zh(t))return!1;if(Wh(t))return t.types.every(r=>ff(r,e));if(Ff(t)){if(t.primitiveType!==void 0)return!0;if(t.stringType!==void 0)return!0;if(t.typeRef!==void 0){const r=t.typeRef.ref;return jf(r)?ff(r.type,e):!1}else return!1}else return!1}s(ff,"isDataTypeInternal");function ju(t){if(!jt(t)){if(t.inferredType)return t.inferredType.name;if(t.dataType)return t.dataType;if(t.returnType){const e=t.returnType.ref;if(e)return e.name}}}s(ju,"getExplicitRuleType");function Bn(t){if(Yn(t))return mt(t)&&zu(t)?t.name:ju(t)??t.name;if(xh(t)||jf(t)||Bh(t))return t.name;if(Xr(t)){const e=$y(t);if(e)return e}else if(Fu(t))return t.name;throw new Error("Cannot get name of Unknown Type")}s(Bn,"getTypeName");function $y(t){if(t.inferredType)return t.inferredType.name;if(t.type?.ref)return Bn(t.type.ref)}s($y,"getActionType");function _R(t){return jt(t)?t.type?.name??"string":mt(t)&&zu(t)?t.name:ju(t)??t.name}s(_R,"getRuleTypeName");function Ry(t){return jt(t)?t.type?.name??"string":ju(t)??t.name}s(Ry,"getRuleType");function Bu(t){const e={s:!1,i:!1,u:!1},r=Zn(t.definition,e),n=Object.entries(e).filter(([,a])=>a).map(([a])=>a).join("");return new RegExp(r,n)}s(Bu,"terminalRegex");var Ay=/[\s\S]/.source;function Zn(t,e){if(Uh(t))return SR(t);if(Kh(t))return wR(t);if(kh(t))return PR(t);if(zf(t)){const r=t.rule.ref;if(!r)throw new Error("Missing rule reference.");return dr(Zn(r.definition),{cardinality:t.cardinality,lookahead:t.lookahead,parenthesized:t.parenthesized})}else{if(Mh(t))return NR(t);if(Vh(t))return IR(t);if(jh(t)){const r=t.regex.lastIndexOf("/"),n=t.regex.substring(1,r),a=t.regex.substring(r+1);return e&&(e.i=a.includes("i"),e.s=a.includes("s"),e.u=a.includes("u")),dr(n,{cardinality:t.cardinality,lookahead:t.lookahead,parenthesized:t.parenthesized,wrap:!1})}else{if(qh(t))return dr(Ay,{cardinality:t.cardinality,lookahead:t.lookahead,parenthesized:t.parenthesized});throw new Error(`Invalid terminal element: ${t?.$type}, ${t?.$cstNode?.text}`)}}}s(Zn,"abstractElementToRegex");function SR(t){return dr(t.elements.map(e=>Zn(e)).join("|"),{cardinality:t.cardinality,lookahead:t.lookahead,parenthesized:t.parenthesized,wrap:!1})}s(SR,"terminalAlternativesToRegex");function wR(t){return dr(t.elements.map(e=>Zn(e)).join(""),{cardinality:t.cardinality,lookahead:t.lookahead,parenthesized:t.parenthesized,wrap:!1})}s(wR,"terminalGroupToRegex");function IR(t){return dr(`${Ay}*?${Zn(t.terminal)}`,{cardinality:t.cardinality,lookahead:t.lookahead,parenthesized:t.parenthesized})}s(IR,"untilTokenToRegex");function NR(t){return dr(`(?!${Zn(t.terminal)})${Ay}*?`,{cardinality:t.cardinality,lookahead:t.lookahead,parenthesized:t.parenthesized})}s(NR,"negateTokenToRegex");function PR(t){return t.right?dr(`[${Nc(t.left)}-${Nc(t.right)}]`,{cardinality:t.cardinality,lookahead:t.lookahead,parenthesized:t.parenthesized,wrap:!1}):dr(Nc(t.left),{cardinality:t.cardinality,lookahead:t.lookahead,parenthesized:t.parenthesized,wrap:!1})}s(PR,"characterRangeToRegex");function Nc(t){return sl(t.value)}s(Nc,"keywordToRegex");function dr(t,e){return(e.parenthesized||e.lookahead||e.wrap!==!1)&&(t=`(${e.lookahead??(e.parenthesized?"":"?:")}${t})`),e.cardinality?`${t}${e.cardinality}`:t}s(dr,"withCardinality");function Ey(t){const e=[],r=t.Grammar;for(const n of r.rules)jt(n)&&py(n)&&sy(Bu(n))&&e.push(n.name);return{multilineCommentRules:e,nameRegexp:Zh}}s(Ey,"createGrammarConfig");var tO=typeof global=="object"&&global&&global.Object===Object&&global,kR=tO,rO=typeof self=="object"&&self&&self.Object===Object&&self,nO=kR||rO||Function("return this")(),mr=nO,aO=mr.Symbol,Ft=aO,OR=Object.prototype,iO=OR.hasOwnProperty,sO=OR.toString,Ol=Ft?Ft.toStringTag:void 0;function LR(t){var e=iO.call(t,Ol),r=t[Ol];try{t[Ol]=void 0;var n=!0}catch{}var a=sO.call(t);return n&&(e?t[Ol]=r:delete t[Ol]),a}s(LR,"getRawTag");var oO=LR,lO=Object.prototype,uO=lO.toString;function DR(t){return uO.call(t)}s(DR,"objectToString");var cO=DR,fO="[object Null]",dO="[object Undefined]",lv=Ft?Ft.toStringTag:void 0;function xR(t){return t==null?t===void 0?dO:fO:lv&&lv in Object(t)?oO(t):cO(t)}s(xR,"baseGetTag");var nn=xR;function MR(t){return t!=null&&typeof t=="object"}s(MR,"isObjectLike");var Xt=MR,pO="[object Symbol]";function GR(t){return typeof t=="symbol"||Xt(t)&&nn(t)==pO}s(GR,"isSymbol");var Zf=GR;function FR(t,e){for(var r=-1,n=t==null?0:t.length,a=Array(n);++r<n;)a[r]=e(t[r],r,t);return a}s(FR,"arrayMap");var Uu=FR,mO=Array.isArray,se=mO,uv=Ft?Ft.prototype:void 0,cv=uv?uv.toString:void 0;function Cy(t){if(typeof t=="string")return t;if(se(t))return Uu(t,Cy)+"";if(Zf(t))return cv?cv.call(t):"";var e=t+"";return e=="0"&&1/t==-1/0?"-0":e}s(Cy,"baseToString");var hO=Cy,yO=/\s/;function zR(t){for(var e=t.length;e--&&yO.test(t.charAt(e)););return e}s(zR,"trimmedEndIndex");var gO=zR,vO=/^\s+/;function jR(t){return t&&t.slice(0,gO(t)+1).replace(vO,"")}s(jR,"baseTrim");var TO=jR;function BR(t){var e=typeof t;return t!=null&&(e=="object"||e=="function")}s(BR,"isObject");var zt=BR,fv=NaN,$O=/^[-+]0x[0-9a-f]+$/i,RO=/^0b[01]+$/i,AO=/^0o[0-7]+$/i,EO=parseInt;function UR(t){if(typeof t=="number")return t;if(Zf(t))return fv;if(zt(t)){var e=typeof t.valueOf=="function"?t.valueOf():t;t=zt(e)?e+"":e}if(typeof t!="string")return t===0?t:+t;t=TO(t);var r=RO.test(t);return r||AO.test(t)?EO(t.slice(2),r?2:8):$O.test(t)?fv:+t}s(UR,"toNumber");var CO=UR,dv=1/0,bO=17976931348623157e292;function KR(t){if(!t)return t===0?t:0;if(t=CO(t),t===dv||t===-dv){var e=t<0?-1:1;return e*bO}return t===t?t:0}s(KR,"toFinite");var _O=KR;function WR(t){var e=_O(t),r=e%1;return e===e?r?e-r:e:0}s(WR,"toInteger");var Ku=WR;function VR(t){return t}s(VR,"identity");var Wu=VR,SO="[object AsyncFunction]",wO="[object Function]",IO="[object GeneratorFunction]",NO="[object Proxy]";function qR(t){if(!zt(t))return!1;var e=nn(t);return e==wO||e==IO||e==SO||e==NO}s(qR,"isFunction");var Gr=qR,PO=mr["__core-js_shared__"],Kd=PO,pv=(function(){var t=/[^.]+$/.exec(Kd&&Kd.keys&&Kd.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""})();function HR(t){return!!pv&&pv in t}s(HR,"isMasked");var kO=HR,OO=Function.prototype,LO=OO.toString;function YR(t){if(t!=null){try{return LO.call(t)}catch{}try{return t+""}catch{}}return""}s(YR,"toSource");var Qn=YR,DO=/[\\^$.*+?()[\]{}|]/g,xO=/^\[object .+?Constructor\]$/,MO=Function.prototype,GO=Object.prototype,FO=MO.toString,zO=GO.hasOwnProperty,jO=RegExp("^"+FO.call(zO).replace(DO,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function XR(t){if(!zt(t)||kO(t))return!1;var e=Gr(t)?jO:xO;return e.test(Qn(t))}s(XR,"baseIsNative");var BO=XR;function JR(t,e){return t?.[e]}s(JR,"getValue");var UO=JR;function ZR(t,e){var r=UO(t,e);return BO(r)?r:void 0}s(ZR,"getNative");var ea=ZR,KO=ea(mr,"WeakMap"),Em=KO,mv=Object.create,WO=(function(){function t(){}return s(t,"object"),function(e){if(!zt(e))return{};if(mv)return mv(e);t.prototype=e;var r=new t;return t.prototype=void 0,r}})(),VO=WO;function QR(t,e,r){switch(r.length){case 0:return t.call(e);case 1:return t.call(e,r[0]);case 2:return t.call(e,r[0],r[1]);case 3:return t.call(e,r[0],r[1],r[2])}return t.apply(e,r)}s(QR,"apply");var qO=QR;function eA(){}s(eA,"noop");var He=eA;function tA(t,e){var r=-1,n=t.length;for(e||(e=Array(n));++r<n;)e[r]=t[r];return e}s(tA,"copyArray");var HO=tA,YO=800,XO=16,JO=Date.now;function rA(t){var e=0,r=0;return function(){var n=JO(),a=XO-(n-r);if(r=n,a>0){if(++e>=YO)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}s(rA,"shortOut");var ZO=rA;function nA(t){return function(){return t}}s(nA,"constant");var QO=nA,e0=(function(){try{var t=ea(Object,"defineProperty");return t({},"",{}),t}catch{}})(),df=e0,t0=df?function(t,e){return df(t,"toString",{configurable:!0,enumerable:!1,value:QO(e),writable:!0})}:Wu,r0=t0,n0=ZO(r0),a0=n0;function aA(t,e){for(var r=-1,n=t==null?0:t.length;++r<n&&e(t[r],r,t)!==!1;);return t}s(aA,"arrayEach");var iA=aA;function sA(t,e,r,n){for(var a=t.length,i=r+(n?1:-1);n?i--:++i<a;)if(e(t[i],i,t))return i;return-1}s(sA,"baseFindIndex");var oA=sA;function lA(t){return t!==t}s(lA,"baseIsNaN");var i0=lA;function uA(t,e,r){for(var n=r-1,a=t.length;++n<a;)if(t[n]===e)return n;return-1}s(uA,"strictIndexOf");var s0=uA;function cA(t,e,r){return e===e?s0(t,e,r):oA(t,i0,r)}s(cA,"baseIndexOf");var by=cA;function fA(t,e){var r=t==null?0:t.length;return!!r&&by(t,e,0)>-1}s(fA,"arrayIncludes");var dA=fA,o0=9007199254740991,l0=/^(?:0|[1-9]\d*)$/;function pA(t,e){var r=typeof t;return e=e??o0,!!e&&(r=="number"||r!="symbol"&&l0.test(t))&&t>-1&&t%1==0&&t<e}s(pA,"isIndex");var Qf=pA;function mA(t,e,r){e=="__proto__"&&df?df(t,e,{configurable:!0,enumerable:!0,value:r,writable:!0}):t[e]=r}s(mA,"baseAssignValue");var _y=mA;function hA(t,e){return t===e||t!==t&&e!==e}s(hA,"eq");var Vu=hA,u0=Object.prototype,c0=u0.hasOwnProperty;function yA(t,e,r){var n=t[e];(!(c0.call(t,e)&&Vu(n,r))||r===void 0&&!(e in t))&&_y(t,e,r)}s(yA,"assignValue");var ed=yA;function gA(t,e,r,n){var a=!r;r||(r={});for(var i=-1,o=e.length;++i<o;){var u=e[i],l=n?n(r[u],t[u],u,r,t):void 0;l===void 0&&(l=t[u]),a?_y(r,u,l):ed(r,u,l)}return r}s(gA,"copyObject");var qu=gA,hv=Math.max;function vA(t,e,r){return e=hv(e===void 0?t.length-1:e,0),function(){for(var n=arguments,a=-1,i=hv(n.length-e,0),o=Array(i);++a<i;)o[a]=n[e+a];a=-1;for(var u=Array(e+1);++a<e;)u[a]=n[a];return u[e]=r(o),qO(t,this,u)}}s(vA,"overRest");var f0=vA;function TA(t,e){return a0(f0(t,e,Wu),t+"")}s(TA,"baseRest");var Sy=TA,d0=9007199254740991;function $A(t){return typeof t=="number"&&t>-1&&t%1==0&&t<=d0}s($A,"isLength");var wy=$A;function RA(t){return t!=null&&wy(t.length)&&!Gr(t)}s(RA,"isArrayLike");var hr=RA;function AA(t,e,r){if(!zt(r))return!1;var n=typeof e;return(n=="number"?hr(r)&&Qf(e,r.length):n=="string"&&e in r)?Vu(r[e],t):!1}s(AA,"isIterateeCall");var td=AA;function EA(t){return Sy(function(e,r){var n=-1,a=r.length,i=a>1?r[a-1]:void 0,o=a>2?r[2]:void 0;for(i=t.length>3&&typeof i=="function"?(a--,i):void 0,o&&td(r[0],r[1],o)&&(i=a<3?void 0:i,a=1),e=Object(e);++n<a;){var u=r[n];u&&t(e,u,n,i)}return e})}s(EA,"createAssigner");var p0=EA,m0=Object.prototype;function CA(t){var e=t&&t.constructor,r=typeof e=="function"&&e.prototype||m0;return t===r}s(CA,"isPrototype");var Hu=CA;function bA(t,e){for(var r=-1,n=Array(t);++r<t;)n[r]=e(r);return n}s(bA,"baseTimes");var h0=bA,y0="[object Arguments]";function _A(t){return Xt(t)&&nn(t)==y0}s(_A,"baseIsArguments");var yv=_A,SA=Object.prototype,g0=SA.hasOwnProperty,v0=SA.propertyIsEnumerable,T0=yv((function(){return arguments})())?yv:function(t){return Xt(t)&&g0.call(t,"callee")&&!v0.call(t,"callee")},rd=T0;function wA(){return!1}s(wA,"stubFalse");var $0=wA,IA=typeof exports=="object"&&exports&&!exports.nodeType&&exports,gv=IA&&typeof module=="object"&&module&&!module.nodeType&&module,R0=gv&&gv.exports===IA,vv=R0?mr.Buffer:void 0,A0=vv?vv.isBuffer:void 0,E0=A0||$0,Ru=E0,C0="[object Arguments]",b0="[object Array]",_0="[object Boolean]",S0="[object Date]",w0="[object Error]",I0="[object Function]",N0="[object Map]",P0="[object Number]",k0="[object Object]",O0="[object RegExp]",L0="[object Set]",D0="[object String]",x0="[object WeakMap]",M0="[object ArrayBuffer]",G0="[object DataView]",F0="[object Float32Array]",z0="[object Float64Array]",j0="[object Int8Array]",B0="[object Int16Array]",U0="[object Int32Array]",K0="[object Uint8Array]",W0="[object Uint8ClampedArray]",V0="[object Uint16Array]",q0="[object Uint32Array]",be={};be[F0]=be[z0]=be[j0]=be[B0]=be[U0]=be[K0]=be[W0]=be[V0]=be[q0]=!0;be[C0]=be[b0]=be[M0]=be[_0]=be[G0]=be[S0]=be[w0]=be[I0]=be[N0]=be[P0]=be[k0]=be[O0]=be[L0]=be[D0]=be[x0]=!1;function NA(t){return Xt(t)&&wy(t.length)&&!!be[nn(t)]}s(NA,"baseIsTypedArray");var H0=NA;function PA(t){return function(e){return t(e)}}s(PA,"baseUnary");var Yu=PA,kA=typeof exports=="object"&&exports&&!exports.nodeType&&exports,fu=kA&&typeof module=="object"&&module&&!module.nodeType&&module,Y0=fu&&fu.exports===kA,Wd=Y0&&kR.process,X0=(function(){try{var t=fu&&fu.require&&fu.require("util").types;return t||Wd&&Wd.binding&&Wd.binding("util")}catch{}})(),Jr=X0,Tv=Jr&&Jr.isTypedArray,J0=Tv?Yu(Tv):H0,Iy=J0,Z0=Object.prototype,Q0=Z0.hasOwnProperty;function OA(t,e){var r=se(t),n=!r&&rd(t),a=!r&&!n&&Ru(t),i=!r&&!n&&!a&&Iy(t),o=r||n||a||i,u=o?h0(t.length,String):[],l=u.length;for(var c in t)(e||Q0.call(t,c))&&!(o&&(c=="length"||a&&(c=="offset"||c=="parent")||i&&(c=="buffer"||c=="byteLength"||c=="byteOffset")||Qf(c,l)))&&u.push(c);return u}s(OA,"arrayLikeKeys");var LA=OA;function DA(t,e){return function(r){return t(e(r))}}s(DA,"overArg");var xA=DA,eL=xA(Object.keys,Object),tL=eL,rL=Object.prototype,nL=rL.hasOwnProperty;function MA(t){if(!Hu(t))return tL(t);var e=[];for(var r in Object(t))nL.call(t,r)&&r!="constructor"&&e.push(r);return e}s(MA,"baseKeys");var GA=MA;function FA(t){return hr(t)?LA(t):GA(t)}s(FA,"keys");var Nt=FA,aL=Object.prototype,iL=aL.hasOwnProperty,sL=p0(function(t,e){if(Hu(e)||hr(e)){qu(e,Nt(e),t);return}for(var r in e)iL.call(e,r)&&ed(t,r,e[r])}),Pt=sL;function zA(t){var e=[];if(t!=null)for(var r in Object(t))e.push(r);return e}s(zA,"nativeKeysIn");var oL=zA,lL=Object.prototype,uL=lL.hasOwnProperty;function jA(t){if(!zt(t))return oL(t);var e=Hu(t),r=[];for(var n in t)n=="constructor"&&(e||!uL.call(t,n))||r.push(n);return r}s(jA,"baseKeysIn");var cL=jA;function BA(t){return hr(t)?LA(t,!0):cL(t)}s(BA,"keysIn");var nd=BA,fL=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,dL=/^\w*$/;function UA(t,e){if(se(t))return!1;var r=typeof t;return r=="number"||r=="symbol"||r=="boolean"||t==null||Zf(t)?!0:dL.test(t)||!fL.test(t)||e!=null&&t in Object(e)}s(UA,"isKey");var Ny=UA,pL=ea(Object,"create"),Au=pL;function KA(){this.__data__=Au?Au(null):{},this.size=0}s(KA,"hashClear");var mL=KA;function WA(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}s(WA,"hashDelete");var hL=WA,yL="__lodash_hash_undefined__",gL=Object.prototype,vL=gL.hasOwnProperty;function VA(t){var e=this.__data__;if(Au){var r=e[t];return r===yL?void 0:r}return vL.call(e,t)?e[t]:void 0}s(VA,"hashGet");var TL=VA,$L=Object.prototype,RL=$L.hasOwnProperty;function qA(t){var e=this.__data__;return Au?e[t]!==void 0:RL.call(e,t)}s(qA,"hashHas");var AL=qA,EL="__lodash_hash_undefined__";function HA(t,e){var r=this.__data__;return this.size+=this.has(t)?0:1,r[t]=Au&&e===void 0?EL:e,this}s(HA,"hashSet");var CL=HA;function ta(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}s(ta,"Hash");ta.prototype.clear=mL;ta.prototype.delete=hL;ta.prototype.get=TL;ta.prototype.has=AL;ta.prototype.set=CL;var $v=ta;function YA(){this.__data__=[],this.size=0}s(YA,"listCacheClear");var bL=YA;function XA(t,e){for(var r=t.length;r--;)if(Vu(t[r][0],e))return r;return-1}s(XA,"assocIndexOf");var ad=XA,_L=Array.prototype,SL=_L.splice;function JA(t){var e=this.__data__,r=ad(e,t);if(r<0)return!1;var n=e.length-1;return r==n?e.pop():SL.call(e,r,1),--this.size,!0}s(JA,"listCacheDelete");var wL=JA;function ZA(t){var e=this.__data__,r=ad(e,t);return r<0?void 0:e[r][1]}s(ZA,"listCacheGet");var IL=ZA;function QA(t){return ad(this.__data__,t)>-1}s(QA,"listCacheHas");var NL=QA;function eE(t,e){var r=this.__data__,n=ad(r,t);return n<0?(++this.size,r.push([t,e])):r[n][1]=e,this}s(eE,"listCacheSet");var PL=eE;function ra(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}s(ra,"ListCache");ra.prototype.clear=bL;ra.prototype.delete=wL;ra.prototype.get=IL;ra.prototype.has=NL;ra.prototype.set=PL;var id=ra,kL=ea(mr,"Map"),Eu=kL;function tE(){this.size=0,this.__data__={hash:new $v,map:new(Eu||id),string:new $v}}s(tE,"mapCacheClear");var OL=tE;function rE(t){var e=typeof t;return e=="string"||e=="number"||e=="symbol"||e=="boolean"?t!=="__proto__":t===null}s(rE,"isKeyable");var LL=rE;function nE(t,e){var r=t.__data__;return LL(e)?r[typeof e=="string"?"string":"hash"]:r.map}s(nE,"getMapData");var sd=nE;function aE(t){var e=sd(this,t).delete(t);return this.size-=e?1:0,e}s(aE,"mapCacheDelete");var DL=aE;function iE(t){return sd(this,t).get(t)}s(iE,"mapCacheGet");var xL=iE;function sE(t){return sd(this,t).has(t)}s(sE,"mapCacheHas");var ML=sE;function oE(t,e){var r=sd(this,t),n=r.size;return r.set(t,e),this.size+=r.size==n?0:1,this}s(oE,"mapCacheSet");var GL=oE;function na(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}s(na,"MapCache");na.prototype.clear=OL;na.prototype.delete=DL;na.prototype.get=xL;na.prototype.has=ML;na.prototype.set=GL;var od=na,FL="Expected a function";function ld(t,e){if(typeof t!="function"||e!=null&&typeof e!="function")throw new TypeError(FL);var r=s(function(){var n=arguments,a=e?e.apply(this,n):n[0],i=r.cache;if(i.has(a))return i.get(a);var o=t.apply(this,n);return r.cache=i.set(a,o)||i,o},"memoized");return r.cache=new(ld.Cache||od),r}s(ld,"memoize");ld.Cache=od;var zL=ld,jL=500;function lE(t){var e=zL(t,function(n){return r.size===jL&&r.clear(),n}),r=e.cache;return e}s(lE,"memoizeCapped");var BL=lE,UL=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,KL=/\\(\\)?/g,WL=BL(function(t){var e=[];return t.charCodeAt(0)===46&&e.push(""),t.replace(UL,function(r,n,a,i){e.push(a?i.replace(KL,"$1"):n||r)}),e}),VL=WL;function uE(t){return t==null?"":hO(t)}s(uE,"toString");var qL=uE;function cE(t,e){return se(t)?t:Ny(t,e)?[t]:VL(qL(t))}s(cE,"castPath");var ud=cE;function fE(t){if(typeof t=="string"||Zf(t))return t;var e=t+"";return e=="0"&&1/t==-1/0?"-0":e}s(fE,"toKey");var Xu=fE;function dE(t,e){e=ud(e,t);for(var r=0,n=e.length;t!=null&&r<n;)t=t[Xu(e[r++])];return r&&r==n?t:void 0}s(dE,"baseGet");var Py=dE;function pE(t,e,r){var n=t==null?void 0:Py(t,e);return n===void 0?r:n}s(pE,"get");var HL=pE;function mE(t,e){for(var r=-1,n=e.length,a=t.length;++r<n;)t[a+r]=e[r];return t}s(mE,"arrayPush");var ky=mE,Rv=Ft?Ft.isConcatSpreadable:void 0;function hE(t){return se(t)||rd(t)||!!(Rv&&t&&t[Rv])}s(hE,"isFlattenable");var YL=hE;function Oy(t,e,r,n,a){var i=-1,o=t.length;for(r||(r=YL),a||(a=[]);++i<o;){var u=t[i];e>0&&r(u)?e>1?Oy(u,e-1,r,n,a):ky(a,u):n||(a[a.length]=u)}return a}s(Oy,"baseFlatten");var Ly=Oy;function yE(t){var e=t==null?0:t.length;return e?Ly(t,1):[]}s(yE,"flatten");var Ht=yE,XL=xA(Object.getPrototypeOf,Object),gE=XL;function vE(t,e,r){var n=-1,a=t.length;e<0&&(e=-e>a?0:a+e),r=r>a?a:r,r<0&&(r+=a),a=e>r?0:r-e>>>0,e>>>=0;for(var i=Array(a);++n<a;)i[n]=t[n+e];return i}s(vE,"baseSlice");var TE=vE;function $E(t,e,r,n){var a=-1,i=t==null?0:t.length;for(n&&i&&(r=t[++a]);++a<i;)r=e(r,t[a],a,t);return r}s($E,"arrayReduce");var JL=$E;function RE(){this.__data__=new id,this.size=0}s(RE,"stackClear");var ZL=RE;function AE(t){var e=this.__data__,r=e.delete(t);return this.size=e.size,r}s(AE,"stackDelete");var QL=AE;function EE(t){return this.__data__.get(t)}s(EE,"stackGet");var eD=EE;function CE(t){return this.__data__.has(t)}s(CE,"stackHas");var tD=CE,rD=200;function bE(t,e){var r=this.__data__;if(r instanceof id){var n=r.__data__;if(!Eu||n.length<rD-1)return n.push([t,e]),this.size=++r.size,this;r=this.__data__=new od(n)}return r.set(t,e),this.size=r.size,this}s(bE,"stackSet");var nD=bE;function aa(t){var e=this.__data__=new id(t);this.size=e.size}s(aa,"Stack");aa.prototype.clear=ZL;aa.prototype.delete=QL;aa.prototype.get=eD;aa.prototype.has=tD;aa.prototype.set=nD;var du=aa;function _E(t,e){return t&&qu(e,Nt(e),t)}s(_E,"baseAssign");var aD=_E;function SE(t,e){return t&&qu(e,nd(e),t)}s(SE,"baseAssignIn");var iD=SE,wE=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Av=wE&&typeof module=="object"&&module&&!module.nodeType&&module,sD=Av&&Av.exports===wE,Ev=sD?mr.Buffer:void 0,Cv=Ev?Ev.allocUnsafe:void 0;function IE(t,e){if(e)return t.slice();var r=t.length,n=Cv?Cv(r):new t.constructor(r);return t.copy(n),n}s(IE,"cloneBuffer");var oD=IE;function NE(t,e){for(var r=-1,n=t==null?0:t.length,a=0,i=[];++r<n;){var o=t[r];e(o,r,t)&&(i[a++]=o)}return i}s(NE,"arrayFilter");var Dy=NE;function PE(){return[]}s(PE,"stubArray");var kE=PE,lD=Object.prototype,uD=lD.propertyIsEnumerable,bv=Object.getOwnPropertySymbols,cD=bv?function(t){return t==null?[]:(t=Object(t),Dy(bv(t),function(e){return uD.call(t,e)}))}:kE,xy=cD;function OE(t,e){return qu(t,xy(t),e)}s(OE,"copySymbols");var fD=OE,dD=Object.getOwnPropertySymbols,pD=dD?function(t){for(var e=[];t;)ky(e,xy(t)),t=gE(t);return e}:kE,LE=pD;function DE(t,e){return qu(t,LE(t),e)}s(DE,"copySymbolsIn");var mD=DE;function xE(t,e,r){var n=e(t);return se(t)?n:ky(n,r(t))}s(xE,"baseGetAllKeys");var ME=xE;function GE(t){return ME(t,Nt,xy)}s(GE,"getAllKeys");var Cm=GE;function FE(t){return ME(t,nd,LE)}s(FE,"getAllKeysIn");var zE=FE,hD=ea(mr,"DataView"),bm=hD,yD=ea(mr,"Promise"),_m=yD,gD=ea(mr,"Set"),Xa=gD,_v="[object Map]",vD="[object Object]",Sv="[object Promise]",wv="[object Set]",Iv="[object WeakMap]",Nv="[object DataView]",TD=Qn(bm),$D=Qn(Eu),RD=Qn(_m),AD=Qn(Xa),ED=Qn(Em),yn=nn;(bm&&yn(new bm(new ArrayBuffer(1)))!=Nv||Eu&&yn(new Eu)!=_v||_m&&yn(_m.resolve())!=Sv||Xa&&yn(new Xa)!=wv||Em&&yn(new Em)!=Iv)&&(yn=s(function(t){var e=nn(t),r=e==vD?t.constructor:void 0,n=r?Qn(r):"";if(n)switch(n){case TD:return Nv;case $D:return _v;case RD:return Sv;case AD:return wv;case ED:return Iv}return e},"getTag"));var el=yn,CD=Object.prototype,bD=CD.hasOwnProperty;function jE(t){var e=t.length,r=new t.constructor(e);return e&&typeof t[0]=="string"&&bD.call(t,"index")&&(r.index=t.index,r.input=t.input),r}s(jE,"initCloneArray");var _D=jE,SD=mr.Uint8Array,pf=SD;function BE(t){var e=new t.constructor(t.byteLength);return new pf(e).set(new pf(t)),e}s(BE,"cloneArrayBuffer");var My=BE;function UE(t,e){var r=e?My(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.byteLength)}s(UE,"cloneDataView");var wD=UE,ID=/\w*$/;function KE(t){var e=new t.constructor(t.source,ID.exec(t));return e.lastIndex=t.lastIndex,e}s(KE,"cloneRegExp");var ND=KE,Pv=Ft?Ft.prototype:void 0,kv=Pv?Pv.valueOf:void 0;function WE(t){return kv?Object(kv.call(t)):{}}s(WE,"cloneSymbol");var PD=WE;function VE(t,e){var r=e?My(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.length)}s(VE,"cloneTypedArray");var kD=VE,OD="[object Boolean]",LD="[object Date]",DD="[object Map]",xD="[object Number]",MD="[object RegExp]",GD="[object Set]",FD="[object String]",zD="[object Symbol]",jD="[object ArrayBuffer]",BD="[object DataView]",UD="[object Float32Array]",KD="[object Float64Array]",WD="[object Int8Array]",VD="[object Int16Array]",qD="[object Int32Array]",HD="[object Uint8Array]",YD="[object Uint8ClampedArray]",XD="[object Uint16Array]",JD="[object Uint32Array]";function qE(t,e,r){var n=t.constructor;switch(e){case jD:return My(t);case OD:case LD:return new n(+t);case BD:return wD(t,r);case UD:case KD:case WD:case VD:case qD:case HD:case YD:case XD:case JD:return kD(t,r);case DD:return new n;case xD:case FD:return new n(t);case MD:return ND(t);case GD:return new n;case zD:return PD(t)}}s(qE,"initCloneByTag");var ZD=qE;function HE(t){return typeof t.constructor=="function"&&!Hu(t)?VO(gE(t)):{}}s(HE,"initCloneObject");var QD=HE,ex="[object Map]";function YE(t){return Xt(t)&&el(t)==ex}s(YE,"baseIsMap");var tx=YE,Ov=Jr&&Jr.isMap,rx=Ov?Yu(Ov):tx,nx=rx,ax="[object Set]";function XE(t){return Xt(t)&&el(t)==ax}s(XE,"baseIsSet");var ix=XE,Lv=Jr&&Jr.isSet,sx=Lv?Yu(Lv):ix,ox=sx,lx=1,ux=2,cx=4,JE="[object Arguments]",fx="[object Array]",dx="[object Boolean]",px="[object Date]",mx="[object Error]",ZE="[object Function]",hx="[object GeneratorFunction]",yx="[object Map]",gx="[object Number]",QE="[object Object]",vx="[object RegExp]",Tx="[object Set]",$x="[object String]",Rx="[object Symbol]",Ax="[object WeakMap]",Ex="[object ArrayBuffer]",Cx="[object DataView]",bx="[object Float32Array]",_x="[object Float64Array]",Sx="[object Int8Array]",wx="[object Int16Array]",Ix="[object Int32Array]",Nx="[object Uint8Array]",Px="[object Uint8ClampedArray]",kx="[object Uint16Array]",Ox="[object Uint32Array]",Te={};Te[JE]=Te[fx]=Te[Ex]=Te[Cx]=Te[dx]=Te[px]=Te[bx]=Te[_x]=Te[Sx]=Te[wx]=Te[Ix]=Te[yx]=Te[gx]=Te[QE]=Te[vx]=Te[Tx]=Te[$x]=Te[Rx]=Te[Nx]=Te[Px]=Te[kx]=Te[Ox]=!0;Te[mx]=Te[ZE]=Te[Ax]=!1;function pu(t,e,r,n,a,i){var o,u=e&lx,l=e&ux,c=e&cx;if(r&&(o=a?r(t,n,a,i):r(t)),o!==void 0)return o;if(!zt(t))return t;var f=se(t);if(f){if(o=_D(t),!u)return HO(t,o)}else{var d=el(t),p=d==ZE||d==hx;if(Ru(t))return oD(t,u);if(d==QE||d==JE||p&&!a){if(o=l||p?{}:QD(t),!u)return l?mD(t,iD(o,t)):fD(t,aD(o,t))}else{if(!Te[d])return a?t:{};o=ZD(t,d,u)}}i||(i=new du);var y=i.get(t);if(y)return y;i.set(t,o),ox(t)?t.forEach(function(C){o.add(pu(C,e,r,C,t,i))}):nx(t)&&t.forEach(function(C,T){o.set(T,pu(C,e,r,T,t,i))});var h=c?l?zE:Cm:l?nd:Nt,$=f?void 0:h(t);return iA($||t,function(C,T){$&&(T=C,C=t[T]),ed(o,T,pu(C,e,r,T,t,i))}),o}s(pu,"baseClone");var Lx=pu,Dx=4;function eC(t){return Lx(t,Dx)}s(eC,"clone");var it=eC;function tC(t){for(var e=-1,r=t==null?0:t.length,n=0,a=[];++e<r;){var i=t[e];i&&(a[n++]=i)}return a}s(tC,"compact");var Ju=tC,xx="__lodash_hash_undefined__";function rC(t){return this.__data__.set(t,xx),this}s(rC,"setCacheAdd");var Mx=rC;function nC(t){return this.__data__.has(t)}s(nC,"setCacheHas");var Gx=nC;function Cu(t){var e=-1,r=t==null?0:t.length;for(this.__data__=new od;++e<r;)this.add(t[e])}s(Cu,"SetCache");Cu.prototype.add=Cu.prototype.push=Mx;Cu.prototype.has=Gx;var Gy=Cu;function aC(t,e){for(var r=-1,n=t==null?0:t.length;++r<n;)if(e(t[r],r,t))return!0;return!1}s(aC,"arraySome");var iC=aC;function sC(t,e){return t.has(e)}s(sC,"cacheHas");var Fy=sC,Fx=1,zx=2;function oC(t,e,r,n,a,i){var o=r&Fx,u=t.length,l=e.length;if(u!=l&&!(o&&l>u))return!1;var c=i.get(t),f=i.get(e);if(c&&f)return c==e&&f==t;var d=-1,p=!0,y=r&zx?new Gy:void 0;for(i.set(t,e),i.set(e,t);++d<u;){var h=t[d],$=e[d];if(n)var C=o?n($,h,d,e,t,i):n(h,$,d,t,e,i);if(C!==void 0){if(C)continue;p=!1;break}if(y){if(!iC(e,function(T,w){if(!Fy(y,w)&&(h===T||a(h,T,r,n,i)))return y.push(w)})){p=!1;break}}else if(!(h===$||a(h,$,r,n,i))){p=!1;break}}return i.delete(t),i.delete(e),p}s(oC,"equalArrays");var lC=oC;function uC(t){var e=-1,r=Array(t.size);return t.forEach(function(n,a){r[++e]=[a,n]}),r}s(uC,"mapToArray");var jx=uC;function cC(t){var e=-1,r=Array(t.size);return t.forEach(function(n){r[++e]=n}),r}s(cC,"setToArray");var zy=cC,Bx=1,Ux=2,Kx="[object Boolean]",Wx="[object Date]",Vx="[object Error]",qx="[object Map]",Hx="[object Number]",Yx="[object RegExp]",Xx="[object Set]",Jx="[object String]",Zx="[object Symbol]",Qx="[object ArrayBuffer]",eM="[object DataView]",Dv=Ft?Ft.prototype:void 0,Vd=Dv?Dv.valueOf:void 0;function fC(t,e,r,n,a,i,o){switch(r){case eM:if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case Qx:return!(t.byteLength!=e.byteLength||!i(new pf(t),new pf(e)));case Kx:case Wx:case Hx:return Vu(+t,+e);case Vx:return t.name==e.name&&t.message==e.message;case Yx:case Jx:return t==e+"";case qx:var u=jx;case Xx:var l=n&Bx;if(u||(u=zy),t.size!=e.size&&!l)return!1;var c=o.get(t);if(c)return c==e;n|=Ux,o.set(t,e);var f=lC(u(t),u(e),n,a,i,o);return o.delete(t),f;case Zx:if(Vd)return Vd.call(t)==Vd.call(e)}return!1}s(fC,"equalByTag");var tM=fC,rM=1,nM=Object.prototype,aM=nM.hasOwnProperty;function dC(t,e,r,n,a,i){var o=r&rM,u=Cm(t),l=u.length,c=Cm(e),f=c.length;if(l!=f&&!o)return!1;for(var d=l;d--;){var p=u[d];if(!(o?p in e:aM.call(e,p)))return!1}var y=i.get(t),h=i.get(e);if(y&&h)return y==e&&h==t;var $=!0;i.set(t,e),i.set(e,t);for(var C=o;++d<l;){p=u[d];var T=t[p],w=e[p];if(n)var b=o?n(w,T,p,e,t,i):n(T,w,p,t,e,i);if(!(b===void 0?T===w||a(T,w,r,n,i):b)){$=!1;break}C||(C=p=="constructor")}if($&&!C){var N=t.constructor,B=e.constructor;N!=B&&"constructor"in t&&"constructor"in e&&!(typeof N=="function"&&N instanceof N&&typeof B=="function"&&B instanceof B)&&($=!1)}return i.delete(t),i.delete(e),$}s(dC,"equalObjects");var iM=dC,sM=1,xv="[object Arguments]",Mv="[object Array]",ic="[object Object]",oM=Object.prototype,Gv=oM.hasOwnProperty;function pC(t,e,r,n,a,i){var o=se(t),u=se(e),l=o?Mv:el(t),c=u?Mv:el(e);l=l==xv?ic:l,c=c==xv?ic:c;var f=l==ic,d=c==ic,p=l==c;if(p&&Ru(t)){if(!Ru(e))return!1;o=!0,f=!1}if(p&&!f)return i||(i=new du),o||Iy(t)?lC(t,e,r,n,a,i):tM(t,e,l,r,n,a,i);if(!(r&sM)){var y=f&&Gv.call(t,"__wrapped__"),h=d&&Gv.call(e,"__wrapped__");if(y||h){var $=y?t.value():t,C=h?e.value():e;return i||(i=new du),a($,C,r,n,i)}}return p?(i||(i=new du),iM(t,e,r,n,a,i)):!1}s(pC,"baseIsEqualDeep");var lM=pC;function jy(t,e,r,n,a){return t===e?!0:t==null||e==null||!Xt(t)&&!Xt(e)?t!==t&&e!==e:lM(t,e,r,n,jy,a)}s(jy,"baseIsEqual");var mC=jy,uM=1,cM=2;function hC(t,e,r,n){var a=r.length,i=a,o=!n;if(t==null)return!i;for(t=Object(t);a--;){var u=r[a];if(o&&u[2]?u[1]!==t[u[0]]:!(u[0]in t))return!1}for(;++a<i;){u=r[a];var l=u[0],c=t[l],f=u[1];if(o&&u[2]){if(c===void 0&&!(l in t))return!1}else{var d=new du;if(n)var p=n(c,f,l,t,e,d);if(!(p===void 0?mC(f,c,uM|cM,n,d):p))return!1}}return!0}s(hC,"baseIsMatch");var fM=hC;function yC(t){return t===t&&!zt(t)}s(yC,"isStrictComparable");var gC=yC;function vC(t){for(var e=Nt(t),r=e.length;r--;){var n=e[r],a=t[n];e[r]=[n,a,gC(a)]}return e}s(vC,"getMatchData");var dM=vC;function TC(t,e){return function(r){return r==null?!1:r[t]===e&&(e!==void 0||t in Object(r))}}s(TC,"matchesStrictComparable");var $C=TC;function RC(t){var e=dM(t);return e.length==1&&e[0][2]?$C(e[0][0],e[0][1]):function(r){return r===t||fM(r,t,e)}}s(RC,"baseMatches");var pM=RC;function AC(t,e){return t!=null&&e in Object(t)}s(AC,"baseHasIn");var mM=AC;function EC(t,e,r){e=ud(e,t);for(var n=-1,a=e.length,i=!1;++n<a;){var o=Xu(e[n]);if(!(i=t!=null&&r(t,o)))break;t=t[o]}return i||++n!=a?i:(a=t==null?0:t.length,!!a&&wy(a)&&Qf(o,a)&&(se(t)||rd(t)))}s(EC,"hasPath");var CC=EC;function bC(t,e){return t!=null&&CC(t,e,mM)}s(bC,"hasIn");var hM=bC,yM=1,gM=2;function _C(t,e){return Ny(t)&&gC(e)?$C(Xu(t),e):function(r){var n=HL(r,t);return n===void 0&&n===e?hM(r,t):mC(e,n,yM|gM)}}s(_C,"baseMatchesProperty");var vM=_C;function SC(t){return function(e){return e?.[t]}}s(SC,"baseProperty");var TM=SC;function wC(t){return function(e){return Py(e,t)}}s(wC,"basePropertyDeep");var $M=wC;function IC(t){return Ny(t)?TM(Xu(t)):$M(t)}s(IC,"property");var RM=IC;function NC(t){return typeof t=="function"?t:t==null?Wu:typeof t=="object"?se(t)?vM(t[0],t[1]):pM(t):RM(t)}s(NC,"baseIteratee");var yr=NC;function PC(t,e,r,n){for(var a=-1,i=t==null?0:t.length;++a<i;){var o=t[a];e(n,o,r(o),t)}return n}s(PC,"arrayAggregator");var AM=PC;function kC(t){return function(e,r,n){for(var a=-1,i=Object(e),o=n(e),u=o.length;u--;){var l=o[t?u:++a];if(r(i[l],l,i)===!1)break}return e}}s(kC,"createBaseFor");var EM=kC,CM=EM(),bM=CM;function OC(t,e){return t&&bM(t,e,Nt)}s(OC,"baseForOwn");var _M=OC;function LC(t,e){return function(r,n){if(r==null)return r;if(!hr(r))return t(r,n);for(var a=r.length,i=e?a:-1,o=Object(r);(e?i--:++i<a)&&n(o[i],i,o)!==!1;);return r}}s(LC,"createBaseEach");var SM=LC,wM=SM(_M),ia=wM;function DC(t,e,r,n){return ia(t,function(a,i,o){e(n,a,r(a),o)}),n}s(DC,"baseAggregator");var IM=DC;function xC(t,e){return function(r,n){var a=se(r)?AM:IM,i=e?e():{};return a(r,t,yr(n),i)}}s(xC,"createAggregator");var NM=xC,MC=Object.prototype,PM=MC.hasOwnProperty,kM=Sy(function(t,e){t=Object(t);var r=-1,n=e.length,a=n>2?e[2]:void 0;for(a&&td(e[0],e[1],a)&&(n=1);++r<n;)for(var i=e[r],o=nd(i),u=-1,l=o.length;++u<l;){var c=o[u],f=t[c];(f===void 0||Vu(f,MC[c])&&!PM.call(t,c))&&(t[c]=i[c])}return t}),By=kM;function GC(t){return Xt(t)&&hr(t)}s(GC,"isArrayLikeObject");var Fv=GC;function FC(t,e,r){for(var n=-1,a=t==null?0:t.length;++n<a;)if(r(e,t[n]))return!0;return!1}s(FC,"arrayIncludesWith");var zC=FC,OM=200;function jC(t,e,r,n){var a=-1,i=dA,o=!0,u=t.length,l=[],c=e.length;if(!u)return l;r&&(e=Uu(e,Yu(r))),n?(i=zC,o=!1):e.length>=OM&&(i=Fy,o=!1,e=new Gy(e));e:for(;++a<u;){var f=t[a],d=r==null?f:r(f);if(f=n||f!==0?f:0,o&&d===d){for(var p=c;p--;)if(e[p]===d)continue e;l.push(f)}else i(e,d,n)||l.push(f)}return l}s(jC,"baseDifference");var LM=jC,DM=Sy(function(t,e){return Fv(t)?LM(t,Ly(e,1,Fv,!0)):[]}),cd=DM;function BC(t){var e=t==null?0:t.length;return e?t[e-1]:void 0}s(BC,"last");var Un=BC;function UC(t,e,r){var n=t==null?0:t.length;return n?(e=r||e===void 0?1:Ku(e),TE(t,e<0?0:e,n)):[]}s(UC,"drop");var nt=UC;function KC(t,e,r){var n=t==null?0:t.length;return n?(e=r||e===void 0?1:Ku(e),e=n-e,TE(t,0,e<0?0:e)):[]}s(KC,"dropRight");var bu=KC;function WC(t){return typeof t=="function"?t:Wu}s(WC,"castFunction");var xM=WC;function VC(t,e){var r=se(t)?iA:ia;return r(t,xM(e))}s(VC,"forEach");var V=VC;function qC(t,e){for(var r=-1,n=t==null?0:t.length;++r<n;)if(!e(t[r],r,t))return!1;return!0}s(qC,"arrayEvery");var MM=qC;function HC(t,e){var r=!0;return ia(t,function(n,a,i){return r=!!e(n,a,i),r}),r}s(HC,"baseEvery");var GM=HC;function YC(t,e,r){var n=se(t)?MM:GM;return r&&td(t,e,r)&&(e=void 0),n(t,yr(e))}s(YC,"every");var Yt=YC;function XC(t,e){var r=[];return ia(t,function(n,a,i){e(n,a,i)&&r.push(n)}),r}s(XC,"baseFilter");var JC=XC;function ZC(t,e){var r=se(t)?Dy:JC;return r(t,yr(e))}s(ZC,"filter");var Bt=ZC;function QC(t){return function(e,r,n){var a=Object(e);if(!hr(e)){var i=yr(r);e=Nt(e),r=s(function(u){return i(a[u],u,a)},"predicate")}var o=t(e,r,n);return o>-1?a[i?e[o]:o]:void 0}}s(QC,"createFind");var FM=QC,zM=Math.max;function eb(t,e,r){var n=t==null?0:t.length;if(!n)return-1;var a=r==null?0:Ku(r);return a<0&&(a=zM(n+a,0)),oA(t,yr(e),a)}s(eb,"findIndex");var jM=eb,BM=FM(jM),tl=BM;function tb(t){return t&&t.length?t[0]:void 0}s(tb,"head");var Jt=tb;function rb(t,e){var r=-1,n=hr(t)?Array(t.length):[];return ia(t,function(a,i,o){n[++r]=e(a,i,o)}),n}s(rb,"baseMap");var UM=rb;function nb(t,e){var r=se(t)?Uu:UM;return r(t,yr(e))}s(nb,"map");var j=nb;function ab(t,e){return Ly(j(t,e),1)}s(ab,"flatMap");var Gt=ab,KM=Object.prototype,WM=KM.hasOwnProperty,VM=NM(function(t,e,r){WM.call(t,r)?t[r].push(e):_y(t,r,[e])}),qM=VM,HM=Object.prototype,YM=HM.hasOwnProperty;function ib(t,e){return t!=null&&YM.call(t,e)}s(ib,"baseHas");var XM=ib;function sb(t,e){return t!=null&&CC(t,e,XM)}s(sb,"has");var K=sb,JM="[object String]";function ob(t){return typeof t=="string"||!se(t)&&Xt(t)&&nn(t)==JM}s(ob,"isString");var Ct=ob;function lb(t,e){return Uu(e,function(r){return t[r]})}s(lb,"baseValues");var ZM=lb;function ub(t){return t==null?[]:ZM(t,Nt(t))}s(ub,"values");var Ke=ub,QM=Math.max;function cb(t,e,r,n){t=hr(t)?t:Ke(t),r=r&&!n?Ku(r):0;var a=t.length;return r<0&&(r=QM(a+r,0)),Ct(t)?r<=a&&t.indexOf(e,r)>-1:!!a&&by(t,e,r)>-1}s(cb,"includes");var vt=cb,e1=Math.max;function fb(t,e,r){var n=t==null?0:t.length;if(!n)return-1;var a=r==null?0:Ku(r);return a<0&&(a=e1(n+a,0)),by(t,e,a)}s(fb,"indexOf");var zv=fb,t1="[object Map]",r1="[object Set]",n1=Object.prototype,a1=n1.hasOwnProperty;function db(t){if(t==null)return!0;if(hr(t)&&(se(t)||typeof t=="string"||typeof t.splice=="function"||Ru(t)||Iy(t)||rd(t)))return!t.length;var e=el(t);if(e==t1||e==r1)return!t.size;if(Hu(t))return!GA(t).length;for(var r in t)if(a1.call(t,r))return!1;return!0}s(db,"isEmpty");var Re=db,i1="[object RegExp]";function pb(t){return Xt(t)&&nn(t)==i1}s(pb,"baseIsRegExp");var s1=pb,jv=Jr&&Jr.isRegExp,o1=jv?Yu(jv):s1,Pr=o1;function mb(t){return t===void 0}s(mb,"isUndefined");var kr=mb,l1="Expected a function";function hb(t){if(typeof t!="function")throw new TypeError(l1);return function(){var e=arguments;switch(e.length){case 0:return!t.call(this);case 1:return!t.call(this,e[0]);case 2:return!t.call(this,e[0],e[1]);case 3:return!t.call(this,e[0],e[1],e[2])}return!t.apply(this,e)}}s(hb,"negate");var u1=hb;function yb(t,e,r,n){if(!zt(t))return t;e=ud(e,t);for(var a=-1,i=e.length,o=i-1,u=t;u!=null&&++a<i;){var l=Xu(e[a]),c=r;if(l==="__proto__"||l==="constructor"||l==="prototype")return t;if(a!=o){var f=u[l];c=n?n(f,l,u):void 0,c===void 0&&(c=zt(f)?f:Qf(e[a+1])?[]:{})}ed(u,l,c),u=u[l]}return t}s(yb,"baseSet");var c1=yb;function gb(t,e,r){for(var n=-1,a=e.length,i={};++n<a;){var o=e[n],u=Py(t,o);r(u,o)&&c1(i,ud(o,t),u)}return i}s(gb,"basePickBy");var f1=gb;function vb(t,e){if(t==null)return{};var r=Uu(zE(t),function(n){return[n]});return e=yr(e),f1(t,r,function(n,a){return e(n,a[0])})}s(vb,"pickBy");var Zt=vb;function Tb(t,e,r,n,a){return a(t,function(i,o,u){r=n?(n=!1,i):e(r,i,o,u)}),r}s(Tb,"baseReduce");var d1=Tb;function $b(t,e,r){var n=se(t)?JL:d1,a=arguments.length<3;return n(t,yr(e),r,a,ia)}s($b,"reduce");var kt=$b;function Rb(t,e){var r=se(t)?Dy:JC;return r(t,u1(yr(e)))}s(Rb,"reject");var fd=Rb;function Ab(t,e){var r;return ia(t,function(n,a,i){return r=e(n,a,i),!r}),!!r}s(Ab,"baseSome");var p1=Ab;function Eb(t,e,r){var n=se(t)?iC:p1;return r&&td(t,e,r)&&(e=void 0),n(t,yr(e))}s(Eb,"some");var Cb=Eb,m1=1/0,h1=Xa&&1/zy(new Xa([,-0]))[1]==m1?function(t){return new Xa(t)}:He,y1=h1,g1=200;function bb(t,e,r){var n=-1,a=dA,i=t.length,o=!0,u=[],l=u;if(r)o=!1,a=zC;else if(i>=g1){var c=e?null:y1(t);if(c)return zy(c);o=!1,a=Fy,l=new Gy}else l=e?[]:u;e:for(;++n<i;){var f=t[n],d=e?e(f):f;if(f=r||f!==0?f:0,o&&d===d){for(var p=l.length;p--;)if(l[p]===d)continue e;e&&l.push(d),u.push(f)}else a(l,d,r)||(l!==u&&l.push(d),u.push(f))}return u}s(bb,"baseUniq");var v1=bb;function _b(t){return t&&t.length?v1(t):[]}s(_b,"uniq");var Uy=_b;function mf(t){console&&console.error&&console.error(`Error: ${t}`)}s(mf,"PRINT_ERROR");function Ky(t){console&&console.warn&&console.warn(`Warning: ${t}`)}s(Ky,"PRINT_WARNING");function Wy(t){const e=new Date().getTime(),r=t();return{time:new Date().getTime()-e,value:r}}s(Wy,"timer");function Vy(t){function e(){}s(e,"FakeConstructor"),e.prototype=t;const r=new e;function n(){return typeof r.bar}return s(n,"fakeAccess"),n(),n(),t}s(Vy,"toFastProperties");function Sb(t){return wb(t)?t.LABEL:t.name}s(Sb,"tokenLabel");function wb(t){return Ct(t.LABEL)&&t.LABEL!==""}s(wb,"hasTokenLabel");var si,gr=(si=class{get definition(){return this._definition}set definition(e){this._definition=e}constructor(e){this._definition=e}accept(e){e.visit(this),V(this.definition,r=>{r.accept(e)})}},s(si,"AbstractProduction"),si),oi,ht=(oi=class extends gr{constructor(e){super([]),this.idx=1,Pt(this,Zt(e,r=>r!==void 0))}set definition(e){}get definition(){return this.referencedRule!==void 0?this.referencedRule.definition:[]}accept(e){e.visit(this)}},s(oi,"NonTerminal"),oi),li,ol=(li=class extends gr{constructor(e){super(e.definition),this.orgText="",Pt(this,Zt(e,r=>r!==void 0))}},s(li,"Rule"),li),ui,bt=(ui=class extends gr{constructor(e){super(e.definition),this.ignoreAmbiguities=!1,Pt(this,Zt(e,r=>r!==void 0))}},s(ui,"Alternative"),ui),ci,at=(ci=class extends gr{constructor(e){super(e.definition),this.idx=1,Pt(this,Zt(e,r=>r!==void 0))}},s(ci,"Option"),ci),fi,Ot=(fi=class extends gr{constructor(e){super(e.definition),this.idx=1,Pt(this,Zt(e,r=>r!==void 0))}},s(fi,"RepetitionMandatory"),fi),di,Lt=(di=class extends gr{constructor(e){super(e.definition),this.idx=1,Pt(this,Zt(e,r=>r!==void 0))}},s(di,"RepetitionMandatoryWithSeparator"),di),pi,xe=(pi=class extends gr{constructor(e){super(e.definition),this.idx=1,Pt(this,Zt(e,r=>r!==void 0))}},s(pi,"Repetition"),pi),mi,_t=(mi=class extends gr{constructor(e){super(e.definition),this.idx=1,Pt(this,Zt(e,r=>r!==void 0))}},s(mi,"RepetitionWithSeparator"),mi),hi,St=(hi=class extends gr{get definition(){return this._definition}set definition(e){this._definition=e}constructor(e){super(e.definition),this.idx=1,this.ignoreAmbiguities=!1,this.hasPredicates=!1,Pt(this,Zt(e,r=>r!==void 0))}},s(hi,"Alternation"),hi),yi,Se=(yi=class{constructor(e){this.idx=1,Pt(this,Zt(e,r=>r!==void 0))}accept(e){e.visit(this)}},s(yi,"Terminal"),yi);function Ib(t){return j(t,mu)}s(Ib,"serializeGrammar");function mu(t){function e(r){return j(r,mu)}if(s(e,"convertDefinition"),t instanceof ht){const r={type:"NonTerminal",name:t.nonTerminalName,idx:t.idx};return Ct(t.label)&&(r.label=t.label),r}else{if(t instanceof bt)return{type:"Alternative",definition:e(t.definition)};if(t instanceof at)return{type:"Option",idx:t.idx,definition:e(t.definition)};if(t instanceof Ot)return{type:"RepetitionMandatory",idx:t.idx,definition:e(t.definition)};if(t instanceof Lt)return{type:"RepetitionMandatoryWithSeparator",idx:t.idx,separator:mu(new Se({terminalType:t.separator})),definition:e(t.definition)};if(t instanceof _t)return{type:"RepetitionWithSeparator",idx:t.idx,separator:mu(new Se({terminalType:t.separator})),definition:e(t.definition)};if(t instanceof xe)return{type:"Repetition",idx:t.idx,definition:e(t.definition)};if(t instanceof St)return{type:"Alternation",idx:t.idx,definition:e(t.definition)};if(t instanceof Se){const r={type:"Terminal",name:t.terminalType.name,label:Sb(t.terminalType),idx:t.idx};Ct(t.label)&&(r.terminalLabel=t.label);const n=t.terminalType.PATTERN;return t.terminalType.PATTERN&&(r.pattern=Pr(n)?n.source:n),r}else{if(t instanceof ol)return{type:"Rule",name:t.name,orgText:t.orgText,definition:e(t.definition)};throw Error("non exhaustive match")}}}s(mu,"serializeProduction");var gi,ll=(gi=class{visit(e){const r=e;switch(r.constructor){case ht:return this.visitNonTerminal(r);case bt:return this.visitAlternative(r);case at:return this.visitOption(r);case Ot:return this.visitRepetitionMandatory(r);case Lt:return this.visitRepetitionMandatoryWithSeparator(r);case _t:return this.visitRepetitionWithSeparator(r);case xe:return this.visitRepetition(r);case St:return this.visitAlternation(r);case Se:return this.visitTerminal(r);case ol:return this.visitRule(r);default:throw Error("non exhaustive match")}}visitNonTerminal(e){}visitAlternative(e){}visitOption(e){}visitRepetition(e){}visitRepetitionMandatory(e){}visitRepetitionMandatoryWithSeparator(e){}visitRepetitionWithSeparator(e){}visitAlternation(e){}visitTerminal(e){}visitRule(e){}},s(gi,"GAstVisitor"),gi);function Nb(t){return t instanceof bt||t instanceof at||t instanceof xe||t instanceof Ot||t instanceof Lt||t instanceof _t||t instanceof Se||t instanceof ol}s(Nb,"isSequenceProd");function _u(t,e=[]){return t instanceof at||t instanceof xe||t instanceof _t?!0:t instanceof St?Cb(t.definition,n=>_u(n,e)):t instanceof ht&&vt(e,t)?!1:t instanceof gr?(t instanceof ht&&e.push(t),Yt(t.definition,n=>_u(n,e))):!1}s(_u,"isOptionalProd");function Pb(t){return t instanceof St}s(Pb,"isBranchingProd");function Kt(t){if(t instanceof ht)return"SUBRULE";if(t instanceof at)return"OPTION";if(t instanceof St)return"OR";if(t instanceof Ot)return"AT_LEAST_ONE";if(t instanceof Lt)return"AT_LEAST_ONE_SEP";if(t instanceof _t)return"MANY_SEP";if(t instanceof xe)return"MANY";if(t instanceof Se)return"CONSUME";throw Error("non exhaustive match")}s(Kt,"getProductionDslName");var vi,dd=(vi=class{walk(e,r=[]){V(e.definition,(n,a)=>{const i=nt(e.definition,a+1);if(n instanceof ht)this.walkProdRef(n,i,r);else if(n instanceof Se)this.walkTerminal(n,i,r);else if(n instanceof bt)this.walkFlat(n,i,r);else if(n instanceof at)this.walkOption(n,i,r);else if(n instanceof Ot)this.walkAtLeastOne(n,i,r);else if(n instanceof Lt)this.walkAtLeastOneSep(n,i,r);else if(n instanceof _t)this.walkManySep(n,i,r);else if(n instanceof xe)this.walkMany(n,i,r);else if(n instanceof St)this.walkOr(n,i,r);else throw Error("non exhaustive match")})}walkTerminal(e,r,n){}walkProdRef(e,r,n){}walkFlat(e,r,n){const a=r.concat(n);this.walk(e,a)}walkOption(e,r,n){const a=r.concat(n);this.walk(e,a)}walkAtLeastOne(e,r,n){const a=[new at({definition:e.definition})].concat(r,n);this.walk(e,a)}walkAtLeastOneSep(e,r,n){const a=Sm(e,r,n);this.walk(e,a)}walkMany(e,r,n){const a=[new at({definition:e.definition})].concat(r,n);this.walk(e,a)}walkManySep(e,r,n){const a=Sm(e,r,n);this.walk(e,a)}walkOr(e,r,n){const a=r.concat(n);V(e.definition,i=>{const o=new bt({definition:[i]});this.walk(o,a)})}},s(vi,"RestWalker"),vi);function Sm(t,e,r){return[new at({definition:[new Se({terminalType:t.separator})].concat(t.definition)})].concat(e,r)}s(Sm,"restForRepetitionWithSeparator");function ul(t){if(t instanceof ht)return ul(t.referencedRule);if(t instanceof Se)return Lb(t);if(Nb(t))return kb(t);if(Pb(t))return Ob(t);throw Error("non exhaustive match")}s(ul,"first");function kb(t){let e=[];const r=t.definition;let n=0,a=r.length>n,i,o=!0;for(;a&&o;)i=r[n],o=_u(i),e=e.concat(ul(i)),n=n+1,a=r.length>n;return Uy(e)}s(kb,"firstForSequence");function Ob(t){const e=j(t.definition,r=>ul(r));return Uy(Ht(e))}s(Ob,"firstForBranching");function Lb(t){return[t.terminalType]}s(Lb,"firstForTerminal");var Db="_~IN~_",Ti,T1=(Ti=class extends dd{constructor(e){super(),this.topProd=e,this.follows={}}startWalking(){return this.walk(this.topProd),this.follows}walkTerminal(e,r,n){}walkProdRef(e,r,n){const a=Mb(e.referencedRule,e.idx)+this.topProd.name,i=r.concat(n),o=new bt({definition:i}),u=ul(o);this.follows[a]=u}},s(Ti,"ResyncFollowsWalker"),Ti);function xb(t){const e={};return V(t,r=>{const n=new T1(r).startWalking();Pt(e,n)}),e}s(xb,"computeAllProdsFollows");function Mb(t,e){return t.name+e+Db}s(Mb,"buildBetweenProdsFollowPrefix");var Pc={},$1=new hR;function Zu(t){const e=t.toString();if(Pc.hasOwnProperty(e))return Pc[e];{const r=$1.pattern(e);return Pc[e]=r,r}}s(Zu,"getRegExpAst");function Gb(){Pc={}}s(Gb,"clearRegExpParserCache");var Fb="Complement Sets are not supported for first char optimization",hf=`Unable to use "first char" lexer optimizations:
47
47
  `;function zb(t,e=!1){try{const r=Zu(t);return yf(r.value,{},r.flags.ignoreCase)}catch(r){if(r.message===Fb)e&&Ky(`${hf} Unable to optimize: < ${t.toString()} >
48
48
  Complement Sets cannot be automatically optimized.
49
49
  This will disable the lexer's first char optimizations.
@@ -144,11 +144,11 @@ Make sure that all grammar rule definitions are done before 'performSelfAnalysis
144
144
  `)}`)})}constructor(e,r){this.definitionErrors=[],this.selfAnalysisDone=!1;const n=this;if(n.initErrorHandler(r),n.initLexerAdapter(),n.initLooksAhead(r),n.initRecognizerEngine(e,r),n.initRecoverable(r),n.initTreeBuilder(r),n.initContentAssist(),n.initGastRecorder(r),n.initPerformanceTracer(r),K(r,"ignoredIssues"))throw new Error(`The <ignoredIssues> IParserConfig property has been deprecated.
145
145
  Please use the <IGNORE_AMBIGUITIES> flag on the relevant DSL method instead.
146
146
  See: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#IGNORING_AMBIGUITIES
147
- For further details.`);this.skipValidations=K(r,"skipValidations")?r.skipValidations:Lr.skipValidations}},s(zn,"Parser"),zn);lg.DEFER_DEFINITION_ERRORS_HANDLING=!1;cS(lg,[F1,j1,K1,W1,q1,V1,H1,Y1,J1,Z1]);var Qi,Q1=(Qi=class extends lg{constructor(e,r=Lr){const n=it(r);n.outputCst=!1,super(e,n)}},s(Qi,"EmbeddedActionsParser"),Qi);function fS(t,e){for(var r=-1,n=t==null?0:t.length,a=Array(n);++r<n;)a[r]=e(t[r],r,t);return a}s(fS,"arrayMap");var dS=fS;function pS(){this.__data__=[],this.size=0}s(pS,"listCacheClear");var eG=pS;function mS(t,e){return t===e||t!==t&&e!==e}s(mS,"eq");var hS=mS;function yS(t,e){for(var r=t.length;r--;)if(hS(t[r][0],e))return r;return-1}s(yS,"assocIndexOf");var vd=yS,tG=Array.prototype,rG=tG.splice;function gS(t){var e=this.__data__,r=vd(e,t);if(r<0)return!1;var n=e.length-1;return r==n?e.pop():rG.call(e,r,1),--this.size,!0}s(gS,"listCacheDelete");var nG=gS;function vS(t){var e=this.__data__,r=vd(e,t);return r<0?void 0:e[r][1]}s(vS,"listCacheGet");var aG=vS;function TS(t){return vd(this.__data__,t)>-1}s(TS,"listCacheHas");var iG=TS;function $S(t,e){var r=this.__data__,n=vd(r,t);return n<0?(++this.size,r.push([t,e])):r[n][1]=e,this}s($S,"listCacheSet");var sG=$S;function sa(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}s(sa,"ListCache");sa.prototype.clear=eG;sa.prototype.delete=nG;sa.prototype.get=aG;sa.prototype.has=iG;sa.prototype.set=sG;var Td=sa;function RS(){this.__data__=new Td,this.size=0}s(RS,"stackClear");var oG=RS;function AS(t){var e=this.__data__,r=e.delete(t);return this.size=e.size,r}s(AS,"stackDelete");var lG=AS;function ES(t){return this.__data__.get(t)}s(ES,"stackGet");var uG=ES;function CS(t){return this.__data__.has(t)}s(CS,"stackHas");var cG=CS,fG=typeof global=="object"&&global&&global.Object===Object&&global,bS=fG,dG=typeof self=="object"&&self&&self.Object===Object&&self,pG=bS||dG||Function("return this")(),Fr=pG,mG=Fr.Symbol,pr=mG,_S=Object.prototype,hG=_S.hasOwnProperty,yG=_S.toString,Ll=pr?pr.toStringTag:void 0;function SS(t){var e=hG.call(t,Ll),r=t[Ll];try{t[Ll]=void 0;var n=!0}catch{}var a=yG.call(t);return n&&(e?t[Ll]=r:delete t[Ll]),a}s(SS,"getRawTag");var gG=SS,vG=Object.prototype,TG=vG.toString;function wS(t){return TG.call(t)}s(wS,"objectToString");var $G=wS,RG="[object Null]",AG="[object Undefined]",tT=pr?pr.toStringTag:void 0;function IS(t){return t==null?t===void 0?AG:RG:tT&&tT in Object(t)?gG(t):$G(t)}s(IS,"baseGetTag");var dl=IS;function NS(t){var e=typeof t;return t!=null&&(e=="object"||e=="function")}s(NS,"isObject");var ug=NS,EG="[object AsyncFunction]",CG="[object Function]",bG="[object GeneratorFunction]",_G="[object Proxy]";function PS(t){if(!ug(t))return!1;var e=dl(t);return e==CG||e==bG||e==EG||e==_G}s(PS,"isFunction");var kS=PS,SG=Fr["__core-js_shared__"],Hd=SG,rT=function(){var t=/[^.]+$/.exec(Hd&&Hd.keys&&Hd.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""}();function OS(t){return!!rT&&rT in t}s(OS,"isMasked");var wG=OS,IG=Function.prototype,NG=IG.toString;function LS(t){if(t!=null){try{return NG.call(t)}catch{}try{return t+""}catch{}}return""}s(LS,"toSource");var oa=LS,PG=/[\\^$.*+?()[\]{}|]/g,kG=/^\[object .+?Constructor\]$/,OG=Function.prototype,LG=Object.prototype,DG=OG.toString,xG=LG.hasOwnProperty,MG=RegExp("^"+DG.call(xG).replace(PG,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function DS(t){if(!ug(t)||wG(t))return!1;var e=kS(t)?MG:kG;return e.test(oa(t))}s(DS,"baseIsNative");var GG=DS;function xS(t,e){return t?.[e]}s(xS,"getValue");var FG=xS;function MS(t,e){var r=FG(t,e);return GG(r)?r:void 0}s(MS,"getNative");var pl=MS,zG=pl(Fr,"Map"),Nu=zG,jG=pl(Object,"create"),Pu=jG;function GS(){this.__data__=Pu?Pu(null):{},this.size=0}s(GS,"hashClear");var BG=GS;function FS(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}s(FS,"hashDelete");var UG=FS,KG="__lodash_hash_undefined__",WG=Object.prototype,VG=WG.hasOwnProperty;function zS(t){var e=this.__data__;if(Pu){var r=e[t];return r===KG?void 0:r}return VG.call(e,t)?e[t]:void 0}s(zS,"hashGet");var qG=zS,HG=Object.prototype,YG=HG.hasOwnProperty;function jS(t){var e=this.__data__;return Pu?e[t]!==void 0:YG.call(e,t)}s(jS,"hashHas");var XG=jS,JG="__lodash_hash_undefined__";function BS(t,e){var r=this.__data__;return this.size+=this.has(t)?0:1,r[t]=Pu&&e===void 0?JG:e,this}s(BS,"hashSet");var ZG=BS;function la(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}s(la,"Hash");la.prototype.clear=BG;la.prototype.delete=UG;la.prototype.get=qG;la.prototype.has=XG;la.prototype.set=ZG;var nT=la;function US(){this.size=0,this.__data__={hash:new nT,map:new(Nu||Td),string:new nT}}s(US,"mapCacheClear");var QG=US;function KS(t){var e=typeof t;return e=="string"||e=="number"||e=="symbol"||e=="boolean"?t!=="__proto__":t===null}s(KS,"isKeyable");var eF=KS;function WS(t,e){var r=t.__data__;return eF(e)?r[typeof e=="string"?"string":"hash"]:r.map}s(WS,"getMapData");var $d=WS;function VS(t){var e=$d(this,t).delete(t);return this.size-=e?1:0,e}s(VS,"mapCacheDelete");var tF=VS;function qS(t){return $d(this,t).get(t)}s(qS,"mapCacheGet");var rF=qS;function HS(t){return $d(this,t).has(t)}s(HS,"mapCacheHas");var nF=HS;function YS(t,e){var r=$d(this,t),n=r.size;return r.set(t,e),this.size+=r.size==n?0:1,this}s(YS,"mapCacheSet");var aF=YS;function ua(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}s(ua,"MapCache");ua.prototype.clear=QG;ua.prototype.delete=tF;ua.prototype.get=rF;ua.prototype.has=nF;ua.prototype.set=aF;var Rd=ua,iF=200;function XS(t,e){var r=this.__data__;if(r instanceof Td){var n=r.__data__;if(!Nu||n.length<iF-1)return n.push([t,e]),this.size=++r.size,this;r=this.__data__=new Rd(n)}return r.set(t,e),this.size=r.size,this}s(XS,"stackSet");var sF=XS;function ca(t){var e=this.__data__=new Td(t);this.size=e.size}s(ca,"Stack");ca.prototype.clear=oG;ca.prototype.delete=lG;ca.prototype.get=uG;ca.prototype.has=cG;ca.prototype.set=sF;var Mc=ca,oF="__lodash_hash_undefined__";function JS(t){return this.__data__.set(t,oF),this}s(JS,"setCacheAdd");var lF=JS;function ZS(t){return this.__data__.has(t)}s(ZS,"setCacheHas");var uF=ZS;function ku(t){var e=-1,r=t==null?0:t.length;for(this.__data__=new Rd;++e<r;)this.add(t[e])}s(ku,"SetCache");ku.prototype.add=ku.prototype.push=lF;ku.prototype.has=uF;var QS=ku;function ew(t,e){for(var r=-1,n=t==null?0:t.length;++r<n;)if(e(t[r],r,t))return!0;return!1}s(ew,"arraySome");var cF=ew;function tw(t,e){return t.has(e)}s(tw,"cacheHas");var rw=tw,fF=1,dF=2;function nw(t,e,r,n,a,i){var o=r&fF,u=t.length,l=e.length;if(u!=l&&!(o&&l>u))return!1;var c=i.get(t),f=i.get(e);if(c&&f)return c==e&&f==t;var d=-1,p=!0,y=r&dF?new QS:void 0;for(i.set(t,e),i.set(e,t);++d<u;){var h=t[d],$=e[d];if(n)var C=o?n($,h,d,e,t,i):n(h,$,d,t,e,i);if(C!==void 0){if(C)continue;p=!1;break}if(y){if(!cF(e,function(T,w){if(!rw(y,w)&&(h===T||a(h,T,r,n,i)))return y.push(w)})){p=!1;break}}else if(!(h===$||a(h,$,r,n,i))){p=!1;break}}return i.delete(t),i.delete(e),p}s(nw,"equalArrays");var aw=nw,pF=Fr.Uint8Array,aT=pF;function iw(t){var e=-1,r=Array(t.size);return t.forEach(function(n,a){r[++e]=[a,n]}),r}s(iw,"mapToArray");var mF=iw;function sw(t){var e=-1,r=Array(t.size);return t.forEach(function(n){r[++e]=n}),r}s(sw,"setToArray");var cg=sw,hF=1,yF=2,gF="[object Boolean]",vF="[object Date]",TF="[object Error]",$F="[object Map]",RF="[object Number]",AF="[object RegExp]",EF="[object Set]",CF="[object String]",bF="[object Symbol]",_F="[object ArrayBuffer]",SF="[object DataView]",iT=pr?pr.prototype:void 0,Yd=iT?iT.valueOf:void 0;function ow(t,e,r,n,a,i,o){switch(r){case SF:if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case _F:return!(t.byteLength!=e.byteLength||!i(new aT(t),new aT(e)));case gF:case vF:case RF:return hS(+t,+e);case TF:return t.name==e.name&&t.message==e.message;case AF:case CF:return t==e+"";case $F:var u=mF;case EF:var l=n&hF;if(u||(u=cg),t.size!=e.size&&!l)return!1;var c=o.get(t);if(c)return c==e;n|=yF,o.set(t,e);var f=aw(u(t),u(e),n,a,i,o);return o.delete(t),f;case bF:if(Yd)return Yd.call(t)==Yd.call(e)}return!1}s(ow,"equalByTag");var wF=ow;function lw(t,e){for(var r=-1,n=e.length,a=t.length;++r<n;)t[a+r]=e[r];return t}s(lw,"arrayPush");var uw=lw,IF=Array.isArray,gt=IF;function cw(t,e,r){var n=e(t);return gt(t)?n:uw(n,r(t))}s(cw,"baseGetAllKeys");var NF=cw;function fw(t,e){for(var r=-1,n=t==null?0:t.length,a=0,i=[];++r<n;){var o=t[r];e(o,r,t)&&(i[a++]=o)}return i}s(fw,"arrayFilter");var dw=fw;function pw(){return[]}s(pw,"stubArray");var PF=pw,kF=Object.prototype,OF=kF.propertyIsEnumerable,sT=Object.getOwnPropertySymbols,LF=sT?function(t){return t==null?[]:(t=Object(t),dw(sT(t),function(e){return OF.call(t,e)}))}:PF,DF=LF;function mw(t,e){for(var r=-1,n=Array(t);++r<t;)n[r]=e(r);return n}s(mw,"baseTimes");var xF=mw;function hw(t){return t!=null&&typeof t=="object"}s(hw,"isObjectLike");var rl=hw,MF="[object Arguments]";function yw(t){return rl(t)&&dl(t)==MF}s(yw,"baseIsArguments");var oT=yw,gw=Object.prototype,GF=gw.hasOwnProperty,FF=gw.propertyIsEnumerable,zF=oT(function(){return arguments}())?oT:function(t){return rl(t)&&GF.call(t,"callee")&&!FF.call(t,"callee")},Ad=zF;function vw(){return!1}s(vw,"stubFalse");var jF=vw,Tw=typeof exports=="object"&&exports&&!exports.nodeType&&exports,lT=Tw&&typeof module=="object"&&module&&!module.nodeType&&module,BF=lT&&lT.exports===Tw,uT=BF?Fr.Buffer:void 0,UF=uT?uT.isBuffer:void 0,KF=UF||jF,Af=KF,WF=9007199254740991,VF=/^(?:0|[1-9]\d*)$/;function $w(t,e){var r=typeof t;return e=e??WF,!!e&&(r=="number"||r!="symbol"&&VF.test(t))&&t>-1&&t%1==0&&t<e}s($w,"isIndex");var Rw=$w,qF=9007199254740991;function Aw(t){return typeof t=="number"&&t>-1&&t%1==0&&t<=qF}s(Aw,"isLength");var fg=Aw,HF="[object Arguments]",YF="[object Array]",XF="[object Boolean]",JF="[object Date]",ZF="[object Error]",QF="[object Function]",ez="[object Map]",tz="[object Number]",rz="[object Object]",nz="[object RegExp]",az="[object Set]",iz="[object String]",sz="[object WeakMap]",oz="[object ArrayBuffer]",lz="[object DataView]",uz="[object Float32Array]",cz="[object Float64Array]",fz="[object Int8Array]",dz="[object Int16Array]",pz="[object Int32Array]",mz="[object Uint8Array]",hz="[object Uint8ClampedArray]",yz="[object Uint16Array]",gz="[object Uint32Array]",_e={};_e[uz]=_e[cz]=_e[fz]=_e[dz]=_e[pz]=_e[mz]=_e[hz]=_e[yz]=_e[gz]=!0;_e[HF]=_e[YF]=_e[oz]=_e[XF]=_e[lz]=_e[JF]=_e[ZF]=_e[QF]=_e[ez]=_e[tz]=_e[rz]=_e[nz]=_e[az]=_e[iz]=_e[sz]=!1;function Ew(t){return rl(t)&&fg(t.length)&&!!_e[dl(t)]}s(Ew,"baseIsTypedArray");var vz=Ew;function Cw(t){return function(e){return t(e)}}s(Cw,"baseUnary");var Tz=Cw,bw=typeof exports=="object"&&exports&&!exports.nodeType&&exports,yu=bw&&typeof module=="object"&&module&&!module.nodeType&&module,$z=yu&&yu.exports===bw,Xd=$z&&bS.process,Rz=function(){try{var t=yu&&yu.require&&yu.require("util").types;return t||Xd&&Xd.binding&&Xd.binding("util")}catch{}}(),cT=Rz,fT=cT&&cT.isTypedArray,Az=fT?Tz(fT):vz,dg=Az,Ez=Object.prototype,Cz=Ez.hasOwnProperty;function _w(t,e){var r=gt(t),n=!r&&Ad(t),a=!r&&!n&&Af(t),i=!r&&!n&&!a&&dg(t),o=r||n||a||i,u=o?xF(t.length,String):[],l=u.length;for(var c in t)(e||Cz.call(t,c))&&!(o&&(c=="length"||a&&(c=="offset"||c=="parent")||i&&(c=="buffer"||c=="byteLength"||c=="byteOffset")||Rw(c,l)))&&u.push(c);return u}s(_w,"arrayLikeKeys");var bz=_w,_z=Object.prototype;function Sw(t){var e=t&&t.constructor,r=typeof e=="function"&&e.prototype||_z;return t===r}s(Sw,"isPrototype");var ww=Sw;function Iw(t,e){return function(r){return t(e(r))}}s(Iw,"overArg");var Sz=Iw,wz=Sz(Object.keys,Object),Iz=wz,Nz=Object.prototype,Pz=Nz.hasOwnProperty;function Nw(t){if(!ww(t))return Iz(t);var e=[];for(var r in Object(t))Pz.call(t,r)&&r!="constructor"&&e.push(r);return e}s(Nw,"baseKeys");var Pw=Nw;function kw(t){return t!=null&&fg(t.length)&&!kS(t)}s(kw,"isArrayLike");var Ed=kw;function Ow(t){return Ed(t)?bz(t):Pw(t)}s(Ow,"keys");var pg=Ow;function Lw(t){return NF(t,pg,DF)}s(Lw,"getAllKeys");var dT=Lw,kz=1,Oz=Object.prototype,Lz=Oz.hasOwnProperty;function Dw(t,e,r,n,a,i){var o=r&kz,u=dT(t),l=u.length,c=dT(e),f=c.length;if(l!=f&&!o)return!1;for(var d=l;d--;){var p=u[d];if(!(o?p in e:Lz.call(e,p)))return!1}var y=i.get(t),h=i.get(e);if(y&&h)return y==e&&h==t;var $=!0;i.set(t,e),i.set(e,t);for(var C=o;++d<l;){p=u[d];var T=t[p],w=e[p];if(n)var b=o?n(w,T,p,e,t,i):n(T,w,p,t,e,i);if(!(b===void 0?T===w||a(T,w,r,n,i):b)){$=!1;break}C||(C=p=="constructor")}if($&&!C){var N=t.constructor,B=e.constructor;N!=B&&"constructor"in t&&"constructor"in e&&!(typeof N=="function"&&N instanceof N&&typeof B=="function"&&B instanceof B)&&($=!1)}return i.delete(t),i.delete(e),$}s(Dw,"equalObjects");var Dz=Dw,xz=pl(Fr,"DataView"),Bm=xz,Mz=pl(Fr,"Promise"),Um=Mz,Gz=pl(Fr,"Set"),Za=Gz,Fz=pl(Fr,"WeakMap"),Km=Fz,pT="[object Map]",zz="[object Object]",mT="[object Promise]",hT="[object Set]",yT="[object WeakMap]",gT="[object DataView]",jz=oa(Bm),Bz=oa(Nu),Uz=oa(Um),Kz=oa(Za),Wz=oa(Km),gn=dl;(Bm&&gn(new Bm(new ArrayBuffer(1)))!=gT||Nu&&gn(new Nu)!=pT||Um&&gn(Um.resolve())!=mT||Za&&gn(new Za)!=hT||Km&&gn(new Km)!=yT)&&(gn=s(function(t){var e=dl(t),r=e==zz?t.constructor:void 0,n=r?oa(r):"";if(n)switch(n){case jz:return gT;case Bz:return pT;case Uz:return mT;case Kz:return hT;case Wz:return yT}return e},"getTag"));var Wm=gn,Vz=1,vT="[object Arguments]",TT="[object Array]",lc="[object Object]",qz=Object.prototype,$T=qz.hasOwnProperty;function xw(t,e,r,n,a,i){var o=gt(t),u=gt(e),l=o?TT:Wm(t),c=u?TT:Wm(e);l=l==vT?lc:l,c=c==vT?lc:c;var f=l==lc,d=c==lc,p=l==c;if(p&&Af(t)){if(!Af(e))return!1;o=!0,f=!1}if(p&&!f)return i||(i=new Mc),o||dg(t)?aw(t,e,r,n,a,i):wF(t,e,l,r,n,a,i);if(!(r&Vz)){var y=f&&$T.call(t,"__wrapped__"),h=d&&$T.call(e,"__wrapped__");if(y||h){var $=y?t.value():t,C=h?e.value():e;return i||(i=new Mc),a($,C,r,n,i)}}return p?(i||(i=new Mc),Dz(t,e,r,n,a,i)):!1}s(xw,"baseIsEqualDeep");var Hz=xw;function mg(t,e,r,n,a){return t===e?!0:t==null||e==null||!rl(t)&&!rl(e)?t!==t&&e!==e:Hz(t,e,r,n,mg,a)}s(mg,"baseIsEqual");var Mw=mg,Yz=1,Xz=2;function Gw(t,e,r,n){var a=r.length,i=a,o=!n;if(t==null)return!i;for(t=Object(t);a--;){var u=r[a];if(o&&u[2]?u[1]!==t[u[0]]:!(u[0]in t))return!1}for(;++a<i;){u=r[a];var l=u[0],c=t[l],f=u[1];if(o&&u[2]){if(c===void 0&&!(l in t))return!1}else{var d=new Mc;if(n)var p=n(c,f,l,t,e,d);if(!(p===void 0?Mw(f,c,Yz|Xz,n,d):p))return!1}}return!0}s(Gw,"baseIsMatch");var Jz=Gw;function Fw(t){return t===t&&!ug(t)}s(Fw,"isStrictComparable");var zw=Fw;function jw(t){for(var e=pg(t),r=e.length;r--;){var n=e[r],a=t[n];e[r]=[n,a,zw(a)]}return e}s(jw,"getMatchData");var Zz=jw;function Bw(t,e){return function(r){return r==null?!1:r[t]===e&&(e!==void 0||t in Object(r))}}s(Bw,"matchesStrictComparable");var Uw=Bw;function Kw(t){var e=Zz(t);return e.length==1&&e[0][2]?Uw(e[0][0],e[0][1]):function(r){return r===t||Jz(r,t,e)}}s(Kw,"baseMatches");var Qz=Kw,ej="[object Symbol]";function Ww(t){return typeof t=="symbol"||rl(t)&&dl(t)==ej}s(Ww,"isSymbol");var Cd=Ww,tj=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,rj=/^\w*$/;function Vw(t,e){if(gt(t))return!1;var r=typeof t;return r=="number"||r=="symbol"||r=="boolean"||t==null||Cd(t)?!0:rj.test(t)||!tj.test(t)||e!=null&&t in Object(e)}s(Vw,"isKey");var hg=Vw,nj="Expected a function";function bd(t,e){if(typeof t!="function"||e!=null&&typeof e!="function")throw new TypeError(nj);var r=s(function(){var n=arguments,a=e?e.apply(this,n):n[0],i=r.cache;if(i.has(a))return i.get(a);var o=t.apply(this,n);return r.cache=i.set(a,o)||i,o},"memoized");return r.cache=new(bd.Cache||Rd),r}s(bd,"memoize");bd.Cache=Rd;var aj=bd,ij=500;function qw(t){var e=aj(t,function(n){return r.size===ij&&r.clear(),n}),r=e.cache;return e}s(qw,"memoizeCapped");var sj=qw,oj=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,lj=/\\(\\)?/g,uj=sj(function(t){var e=[];return t.charCodeAt(0)===46&&e.push(""),t.replace(oj,function(r,n,a,i){e.push(a?i.replace(lj,"$1"):n||r)}),e}),cj=uj,RT=pr?pr.prototype:void 0,AT=RT?RT.toString:void 0;function yg(t){if(typeof t=="string")return t;if(gt(t))return dS(t,yg)+"";if(Cd(t))return AT?AT.call(t):"";var e=t+"";return e=="0"&&1/t==-1/0?"-0":e}s(yg,"baseToString");var fj=yg;function Hw(t){return t==null?"":fj(t)}s(Hw,"toString");var dj=Hw;function Yw(t,e){return gt(t)?t:hg(t,e)?[t]:cj(dj(t))}s(Yw,"castPath");var Xw=Yw;function Jw(t){if(typeof t=="string"||Cd(t))return t;var e=t+"";return e=="0"&&1/t==-1/0?"-0":e}s(Jw,"toKey");var _d=Jw;function Zw(t,e){e=Xw(e,t);for(var r=0,n=e.length;t!=null&&r<n;)t=t[_d(e[r++])];return r&&r==n?t:void 0}s(Zw,"baseGet");var Qw=Zw;function eI(t,e,r){var n=t==null?void 0:Qw(t,e);return n===void 0?r:n}s(eI,"get");var pj=eI;function tI(t,e){return t!=null&&e in Object(t)}s(tI,"baseHasIn");var mj=tI;function rI(t,e,r){e=Xw(e,t);for(var n=-1,a=e.length,i=!1;++n<a;){var o=_d(e[n]);if(!(i=t!=null&&r(t,o)))break;t=t[o]}return i||++n!=a?i:(a=t==null?0:t.length,!!a&&fg(a)&&Rw(o,a)&&(gt(t)||Ad(t)))}s(rI,"hasPath");var hj=rI;function nI(t,e){return t!=null&&hj(t,e,mj)}s(nI,"hasIn");var yj=nI,gj=1,vj=2;function aI(t,e){return hg(t)&&zw(e)?Uw(_d(t),e):function(r){var n=pj(r,t);return n===void 0&&n===e?yj(r,t):Mw(e,n,gj|vj)}}s(aI,"baseMatchesProperty");var Tj=aI;function iI(t){return t}s(iI,"identity");var gg=iI;function sI(t){return function(e){return e?.[t]}}s(sI,"baseProperty");var $j=sI;function oI(t){return function(e){return Qw(e,t)}}s(oI,"basePropertyDeep");var Rj=oI;function lI(t){return hg(t)?$j(_d(t)):Rj(t)}s(lI,"property");var Aj=lI;function uI(t){return typeof t=="function"?t:t==null?gg:typeof t=="object"?gt(t)?Tj(t[0],t[1]):Qz(t):Aj(t)}s(uI,"baseIteratee");var Sd=uI;function cI(t){return function(e,r,n){for(var a=-1,i=Object(e),o=n(e),u=o.length;u--;){var l=o[t?u:++a];if(r(i[l],l,i)===!1)break}return e}}s(cI,"createBaseFor");var Ej=cI,Cj=Ej(),bj=Cj;function fI(t,e){return t&&bj(t,e,pg)}s(fI,"baseForOwn");var _j=fI;function dI(t,e){return function(r,n){if(r==null)return r;if(!Ed(r))return t(r,n);for(var a=r.length,i=e?a:-1,o=Object(r);(e?i--:++i<a)&&n(o[i],i,o)!==!1;);return r}}s(dI,"createBaseEach");var Sj=dI,wj=Sj(_j),wd=wj;function pI(t,e){var r=-1,n=Ed(t)?Array(t.length):[];return wd(t,function(a,i,o){n[++r]=e(a,i,o)}),n}s(pI,"baseMap");var Ij=pI;function mI(t,e){var r=gt(t)?dS:Ij;return r(t,Sd(e))}s(mI,"map");var _r=mI;function hI(t,e){var r=[];return wd(t,function(n,a,i){e(n,a,i)&&r.push(n)}),r}s(hI,"baseFilter");var Nj=hI;function yI(t,e){var r=gt(t)?dw:Nj;return r(t,Sd(e))}s(yI,"filter");var Pj=yI;function Wn(t,e,r){return`${t.name}_${e}_${r}`}s(Wn,"buildATNKey");var Qr=1,kj=2,gI=4,vI=5,rc=7,Oj=8,Lj=9,Dj=10,xj=11,TI=12,es,vg=(es=class{constructor(e){this.target=e}isEpsilon(){return!1}},s(es,"AbstractTransition"),es),ts,Tg=(ts=class extends vg{constructor(e,r){super(e),this.tokenType=r}},s(ts,"AtomTransition"),ts),rs,$I=(rs=class extends vg{constructor(e){super(e)}isEpsilon(){return!0}},s(rs,"EpsilonTransition"),rs),ns,$g=(ns=class extends vg{constructor(e,r,n){super(e),this.rule=r,this.followState=n}isEpsilon(){return!0}},s(ns,"RuleTransition"),ns);function RI(t){const e={decisionMap:{},decisionStates:[],ruleToStartState:new Map,ruleToStopState:new Map,states:[]};AI(e,t);const r=t.length;for(let n=0;n<r;n++){const a=t[n],i=sn(e,a,a);i!==void 0&&OI(e,a,i)}return e}s(RI,"createATN");function AI(t,e){const r=e.length;for(let n=0;n<r;n++){const a=e[n],i=We(t,a,void 0,{type:kj}),o=We(t,a,void 0,{type:rc});i.stop=o,t.ruleToStartState.set(a,i),t.ruleToStopState.set(a,o)}}s(AI,"createRuleStartAndStopATNStates");function Rg(t,e,r){return r instanceof Se?Id(t,e,r.terminalType,r):r instanceof ht?kI(t,e,r):r instanceof St?SI(t,e,r):r instanceof at?wI(t,e,r):r instanceof xe?EI(t,e,r):r instanceof _t?CI(t,e,r):r instanceof Ot?bI(t,e,r):r instanceof Lt?_I(t,e,r):sn(t,e,r)}s(Rg,"atom");function EI(t,e,r){const n=We(t,e,r,{type:vI});zr(t,n);const a=fa(t,e,n,r,sn(t,e,r));return Eg(t,e,r,a)}s(EI,"repetition");function CI(t,e,r){const n=We(t,e,r,{type:vI});zr(t,n);const a=fa(t,e,n,r,sn(t,e,r)),i=Id(t,e,r.separator,r);return Eg(t,e,r,a,i)}s(CI,"repetitionSep");function bI(t,e,r){const n=We(t,e,r,{type:gI});zr(t,n);const a=fa(t,e,n,r,sn(t,e,r));return Ag(t,e,r,a)}s(bI,"repetitionMandatory");function _I(t,e,r){const n=We(t,e,r,{type:gI});zr(t,n);const a=fa(t,e,n,r,sn(t,e,r)),i=Id(t,e,r.separator,r);return Ag(t,e,r,a,i)}s(_I,"repetitionMandatorySep");function SI(t,e,r){const n=We(t,e,r,{type:Qr});zr(t,n);const a=_r(r.definition,o=>Rg(t,e,o));return fa(t,e,n,r,...a)}s(SI,"alternation");function wI(t,e,r){const n=We(t,e,r,{type:Qr});zr(t,n);const a=fa(t,e,n,r,sn(t,e,r));return II(t,e,r,a)}s(wI,"option");function sn(t,e,r){const n=Pj(_r(r.definition,a=>Rg(t,e,a)),a=>a!==void 0);return n.length===1?n[0]:n.length===0?void 0:PI(t,n)}s(sn,"block");function Ag(t,e,r,n,a){const i=n.left,o=n.right,u=We(t,e,r,{type:xj});zr(t,u);const l=We(t,e,r,{type:TI});return i.loopback=u,l.loopback=u,t.decisionMap[Wn(e,a?"RepetitionMandatoryWithSeparator":"RepetitionMandatory",r.idx)]=u,Fe(o,u),a===void 0?(Fe(u,i),Fe(u,l)):(Fe(u,l),Fe(u,a.left),Fe(a.right,i)),{left:i,right:l}}s(Ag,"plus");function Eg(t,e,r,n,a){const i=n.left,o=n.right,u=We(t,e,r,{type:Dj});zr(t,u);const l=We(t,e,r,{type:TI}),c=We(t,e,r,{type:Lj});return u.loopback=c,l.loopback=c,Fe(u,i),Fe(u,l),Fe(o,c),a!==void 0?(Fe(c,l),Fe(c,a.left),Fe(a.right,i)):Fe(c,u),t.decisionMap[Wn(e,a?"RepetitionWithSeparator":"Repetition",r.idx)]=u,{left:u,right:l}}s(Eg,"star");function II(t,e,r,n){const a=n.left,i=n.right;return Fe(a,i),t.decisionMap[Wn(e,"Option",r.idx)]=a,n}s(II,"optional");function zr(t,e){return t.decisionStates.push(e),e.decision=t.decisionStates.length-1,e.decision}s(zr,"defineDecisionState");function fa(t,e,r,n,...a){const i=We(t,e,n,{type:Oj,start:r});r.end=i;for(const u of a)u!==void 0?(Fe(r,u.left),Fe(u.right,i)):Fe(r,i);const o={left:r,right:i};return t.decisionMap[Wn(e,NI(n),n.idx)]=r,o}s(fa,"makeAlts");function NI(t){if(t instanceof St)return"Alternation";if(t instanceof at)return"Option";if(t instanceof xe)return"Repetition";if(t instanceof _t)return"RepetitionWithSeparator";if(t instanceof Ot)return"RepetitionMandatory";if(t instanceof Lt)return"RepetitionMandatoryWithSeparator";throw new Error("Invalid production type encountered")}s(NI,"getProdType");function PI(t,e){const r=e.length;for(let i=0;i<r-1;i++){const o=e[i];let u;o.left.transitions.length===1&&(u=o.left.transitions[0]);const l=u instanceof $g,c=u,f=e[i+1].left;o.left.type===Qr&&o.right.type===Qr&&u!==void 0&&(l&&c.followState===o.right||u.target===o.right)?(l?c.followState=f:u.target=f,LI(t,o.right)):Fe(o.right,f)}const n=e[0],a=e[r-1];return{left:n.left,right:a.right}}s(PI,"makeBlock");function Id(t,e,r,n){const a=We(t,e,n,{type:Qr}),i=We(t,e,n,{type:Qr});return Nd(a,new Tg(i,r)),{left:a,right:i}}s(Id,"tokenRef");function kI(t,e,r){const n=r.referencedRule,a=t.ruleToStartState.get(n),i=We(t,e,r,{type:Qr}),o=We(t,e,r,{type:Qr}),u=new $g(a,n,o);return Nd(i,u),{left:i,right:o}}s(kI,"ruleRef");function OI(t,e,r){const n=t.ruleToStartState.get(e);Fe(n,r.left);const a=t.ruleToStopState.get(e);return Fe(r.right,a),{left:n,right:a}}s(OI,"buildRuleHandle");function Fe(t,e){const r=new $I(e);Nd(t,r)}s(Fe,"epsilon");function We(t,e,r,n){const a=Object.assign({atn:t,production:r,epsilonOnlyTransitions:!1,rule:e,transitions:[],nextTokenWithinRule:[],stateNumber:t.states.length},n);return t.states.push(a),a}s(We,"newState");function Nd(t,e){t.transitions.length===0&&(t.epsilonOnlyTransitions=e.isEpsilon()),t.transitions.push(e)}s(Nd,"addTransition");function LI(t,e){t.states.splice(t.states.indexOf(e),1)}s(LI,"removeState");var Ef={},as,Vm=(as=class{constructor(){this.map={},this.configs=[]}get size(){return this.configs.length}finalize(){this.map={}}add(e){const r=Cg(e);r in this.map||(this.map[r]=this.configs.length,this.configs.push(e))}get elements(){return this.configs}get alts(){return _r(this.configs,e=>e.alt)}get key(){let e="";for(const r in this.map)e+=r+":";return e}},s(as,"ATNConfigSet"),as);function Cg(t,e=!0){return`${e?`a${t.alt}`:""}s${t.state.stateNumber}:${t.stack.map(r=>r.stateNumber.toString()).join("_")}`}s(Cg,"getATNConfigKey");function DI(t,e,r){for(var n=-1,a=t.length;++n<a;){var i=t[n],o=e(i);if(o!=null&&(u===void 0?o===o&&!Cd(o):r(o,u)))var u=o,l=i}return l}s(DI,"baseExtremum");var Mj=DI;function xI(t,e){return t<e}s(xI,"baseLt");var Gj=xI;function MI(t){return t&&t.length?Mj(t,gg,Gj):void 0}s(MI,"min");var Fj=MI,ET=pr?pr.isConcatSpreadable:void 0;function GI(t){return gt(t)||Ad(t)||!!(ET&&t&&t[ET])}s(GI,"isFlattenable");var zj=GI;function bg(t,e,r,n,a){var i=-1,o=t.length;for(r||(r=zj),a||(a=[]);++i<o;){var u=t[i];e>0&&r(u)?e>1?bg(u,e-1,r,n,a):uw(a,u):n||(a[a.length]=u)}return a}s(bg,"baseFlatten");var FI=bg;function zI(t,e){return FI(_r(t,e),1)}s(zI,"flatMap");var jj=zI;function jI(t,e,r,n){for(var a=t.length,i=r+(n?1:-1);n?i--:++i<a;)if(e(t[i],i,t))return i;return-1}s(jI,"baseFindIndex");var Bj=jI;function BI(t){return t!==t}s(BI,"baseIsNaN");var Uj=BI;function UI(t,e,r){for(var n=r-1,a=t.length;++n<a;)if(t[n]===e)return n;return-1}s(UI,"strictIndexOf");var Kj=UI;function KI(t,e,r){return e===e?Kj(t,e,r):Bj(t,Uj,r)}s(KI,"baseIndexOf");var Wj=KI;function WI(t,e){var r=t==null?0:t.length;return!!r&&Wj(t,e,0)>-1}s(WI,"arrayIncludes");var Vj=WI;function VI(t,e,r){for(var n=-1,a=t==null?0:t.length;++n<a;)if(r(e,t[n]))return!0;return!1}s(VI,"arrayIncludesWith");var qj=VI;function qI(){}s(qI,"noop");var Hj=qI,Yj=1/0,Xj=Za&&1/cg(new Za([,-0]))[1]==Yj?function(t){return new Za(t)}:Hj,Jj=Xj,Zj=200;function HI(t,e,r){var n=-1,a=Vj,i=t.length,o=!0,u=[],l=u;if(r)o=!1,a=qj;else if(i>=Zj){var c=e?null:Jj(t);if(c)return cg(c);o=!1,a=rw,l=new QS}else l=e?[]:u;e:for(;++n<i;){var f=t[n],d=e?e(f):f;if(f=r||f!==0?f:0,o&&d===d){for(var p=l.length;p--;)if(l[p]===d)continue e;e&&l.push(d),u.push(f)}else a(l,d,r)||(l!==u&&l.push(d),u.push(f))}return u}s(HI,"baseUniq");var Qj=HI;function YI(t,e){return t&&t.length?Qj(t,Sd(e)):[]}s(YI,"uniqBy");var eB=YI;function XI(t){var e=t==null?0:t.length;return e?FI(t,1):[]}s(XI,"flatten");var tB=XI;function JI(t,e){for(var r=-1,n=t==null?0:t.length;++r<n&&e(t[r],r,t)!==!1;);return t}s(JI,"arrayEach");var rB=JI;function ZI(t){return typeof t=="function"?t:gg}s(ZI,"castFunction");var nB=ZI;function QI(t,e){var r=gt(t)?rB:wd;return r(t,nB(e))}s(QI,"forEach");var Jd=QI,aB="[object Map]",iB="[object Set]",sB=Object.prototype,oB=sB.hasOwnProperty;function eN(t){if(t==null)return!0;if(Ed(t)&&(gt(t)||typeof t=="string"||typeof t.splice=="function"||Af(t)||dg(t)||Ad(t)))return!t.length;var e=Wm(t);if(e==aB||e==iB)return!t.size;if(ww(t))return!Pw(t).length;for(var r in t)if(oB.call(t,r))return!1;return!0}s(eN,"isEmpty");var lB=eN;function tN(t,e,r,n){var a=-1,i=t==null?0:t.length;for(n&&i&&(r=t[++a]);++a<i;)r=e(r,t[a],a,t);return r}s(tN,"arrayReduce");var uB=tN;function rN(t,e,r,n,a){return a(t,function(i,o,u){r=n?(n=!1,i):e(r,i,o,u)}),r}s(rN,"baseReduce");var cB=rN;function nN(t,e,r){var n=gt(t)?uB:cB,a=arguments.length<3;return n(t,Sd(e),r,a,wd)}s(nN,"reduce");var CT=nN;function aN(t,e){const r={};return n=>{const a=n.toString();let i=r[a];return i!==void 0||(i={atnStartState:t,decision:e,states:{}},r[a]=i),i}}s(aN,"createDFACache");var is,iN=(is=class{constructor(){this.predicates=[]}is(e){return e>=this.predicates.length||this.predicates[e]}set(e,r){this.predicates[e]=r}toString(){let e="";const r=this.predicates.length;for(let n=0;n<r;n++)e+=this.predicates[n]===!0?"1":"0";return e}},s(is,"PredicateSet"),is),bT=new iN,ss,fB=(ss=class extends sg{constructor(e){var r;super(),this.logging=(r=e?.logging)!==null&&r!==void 0?r:n=>console.log(n)}initialize(e){this.atn=RI(e.rules),this.dfas=sN(this.atn)}validateAmbiguousAlternationAlternatives(){return[]}validateEmptyOrAlternatives(){return[]}buildLookaheadForAlternation(e){const{prodOccurrence:r,rule:n,hasPredicates:a,dynamicTokensEnabled:i}=e,o=this.dfas,u=this.logging,l=Wn(n,"Alternation",r),f=this.atn.decisionMap[l].decision,d=_r(km({maxLookahead:1,occurrence:r,prodType:"Alternation",rule:n}),p=>_r(p,y=>y[0]));if(qm(d,!1)&&!i){const p=CT(d,(y,h,$)=>(Jd(h,C=>{C&&(y[C.tokenTypeIdx]=$,Jd(C.categoryMatches,T=>{y[T]=$}))}),y),{});return a?function(y){var h;const $=this.LA(1),C=p[$.tokenTypeIdx];if(y!==void 0&&C!==void 0){const T=(h=y[C])===null||h===void 0?void 0:h.GATE;if(T!==void 0&&T.call(this)===!1)return}return C}:function(){const y=this.LA(1);return p[y.tokenTypeIdx]}}else return a?function(p){const y=new iN,h=p===void 0?0:p.length;for(let C=0;C<h;C++){const T=p?.[C].GATE;y.set(C,T===void 0||T.call(this))}const $=Gc.call(this,o,f,y,u);return typeof $=="number"?$:void 0}:function(){const p=Gc.call(this,o,f,bT,u);return typeof p=="number"?p:void 0}}buildLookaheadForOptional(e){const{prodOccurrence:r,rule:n,prodType:a,dynamicTokensEnabled:i}=e,o=this.dfas,u=this.logging,l=Wn(n,a,r),f=this.atn.decisionMap[l].decision,d=_r(km({maxLookahead:1,occurrence:r,prodType:a,rule:n}),p=>_r(p,y=>y[0]));if(qm(d)&&d[0][0]&&!i){const p=d[0],y=tB(p);if(y.length===1&&lB(y[0].categoryMatches)){const $=y[0].tokenTypeIdx;return function(){return this.LA(1).tokenTypeIdx===$}}else{const h=CT(y,($,C)=>(C!==void 0&&($[C.tokenTypeIdx]=!0,Jd(C.categoryMatches,T=>{$[T]=!0})),$),{});return function(){const $=this.LA(1);return h[$.tokenTypeIdx]===!0}}}return function(){const p=Gc.call(this,o,f,bT,u);return typeof p=="object"?!1:p===0}}},s(ss,"LLStarLookaheadStrategy"),ss);function qm(t,e=!0){const r=new Set;for(const n of t){const a=new Set;for(const i of n){if(i===void 0){if(e)break;return!1}const o=[i.tokenTypeIdx].concat(i.categoryMatches);for(const u of o)if(r.has(u)){if(!a.has(u))return!1}else r.add(u),a.add(u)}}return!0}s(qm,"isLL1Sequence");function sN(t){const e=t.decisionStates.length,r=Array(e);for(let n=0;n<e;n++)r[n]=aN(t.decisionStates[n],n);return r}s(sN,"initATNSimulator");function Gc(t,e,r,n){const a=t[e](r);let i=a.start;if(i===void 0){const u=gN(a.atnStartState);i=Sg(a,_g(u)),a.start=i}return oN.apply(this,[a,i,r,n])}s(Gc,"adaptivePredict");function oN(t,e,r,n){let a=e,i=1;const o=[];let u=this.LA(i++);for(;;){let l=pN(a,u);if(l===void 0&&(l=lN.apply(this,[t,a,u,i,r,n])),l===Ef)return dN(o,a,u);if(l.isAcceptState===!0)return l.prediction;a=l,o.push(u),u=this.LA(i++)}}s(oN,"performLookahead");function lN(t,e,r,n,a,i){const o=mN(e.configs,r,a);if(o.size===0)return Hm(t,e,r,Ef),Ef;let u=_g(o);const l=yN(o,a);if(l!==void 0)u.isAcceptState=!0,u.prediction=l,u.configs.uniqueAlt=l;else if(RN(o)){const c=Fj(o.alts);u.isAcceptState=!0,u.prediction=c,u.configs.uniqueAlt=c,uN.apply(this,[t,n,o.alts,i])}return u=Hm(t,e,r,u),u}s(lN,"computeLookaheadTarget");function uN(t,e,r,n){const a=[];for(let c=1;c<=e;c++)a.push(this.LA(c).tokenType);const i=t.atnStartState,o=i.rule,u=i.production,l=cN({topLevelRule:o,ambiguityIndices:r,production:u,prefixPath:a});n(l)}s(uN,"reportLookaheadAmbiguity");function cN(t){const e=_r(t.prefixPath,a=>Gn(a)).join(", "),r=t.production.idx===0?"":t.production.idx;let n=`Ambiguous Alternatives Detected: <${t.ambiguityIndices.join(", ")}> in <${fN(t.production)}${r}> inside <${t.topLevelRule.name}> Rule,
147
+ For further details.`);this.skipValidations=K(r,"skipValidations")?r.skipValidations:Lr.skipValidations}},s(zn,"Parser"),zn);lg.DEFER_DEFINITION_ERRORS_HANDLING=!1;cS(lg,[F1,j1,K1,W1,q1,V1,H1,Y1,J1,Z1]);var Qi,Q1=(Qi=class extends lg{constructor(e,r=Lr){const n=it(r);n.outputCst=!1,super(e,n)}},s(Qi,"EmbeddedActionsParser"),Qi);function fS(t,e){for(var r=-1,n=t==null?0:t.length,a=Array(n);++r<n;)a[r]=e(t[r],r,t);return a}s(fS,"arrayMap");var dS=fS;function pS(){this.__data__=[],this.size=0}s(pS,"listCacheClear");var eG=pS;function mS(t,e){return t===e||t!==t&&e!==e}s(mS,"eq");var hS=mS;function yS(t,e){for(var r=t.length;r--;)if(hS(t[r][0],e))return r;return-1}s(yS,"assocIndexOf");var vd=yS,tG=Array.prototype,rG=tG.splice;function gS(t){var e=this.__data__,r=vd(e,t);if(r<0)return!1;var n=e.length-1;return r==n?e.pop():rG.call(e,r,1),--this.size,!0}s(gS,"listCacheDelete");var nG=gS;function vS(t){var e=this.__data__,r=vd(e,t);return r<0?void 0:e[r][1]}s(vS,"listCacheGet");var aG=vS;function TS(t){return vd(this.__data__,t)>-1}s(TS,"listCacheHas");var iG=TS;function $S(t,e){var r=this.__data__,n=vd(r,t);return n<0?(++this.size,r.push([t,e])):r[n][1]=e,this}s($S,"listCacheSet");var sG=$S;function sa(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}s(sa,"ListCache");sa.prototype.clear=eG;sa.prototype.delete=nG;sa.prototype.get=aG;sa.prototype.has=iG;sa.prototype.set=sG;var Td=sa;function RS(){this.__data__=new Td,this.size=0}s(RS,"stackClear");var oG=RS;function AS(t){var e=this.__data__,r=e.delete(t);return this.size=e.size,r}s(AS,"stackDelete");var lG=AS;function ES(t){return this.__data__.get(t)}s(ES,"stackGet");var uG=ES;function CS(t){return this.__data__.has(t)}s(CS,"stackHas");var cG=CS,fG=typeof global=="object"&&global&&global.Object===Object&&global,bS=fG,dG=typeof self=="object"&&self&&self.Object===Object&&self,pG=bS||dG||Function("return this")(),Fr=pG,mG=Fr.Symbol,pr=mG,_S=Object.prototype,hG=_S.hasOwnProperty,yG=_S.toString,Ll=pr?pr.toStringTag:void 0;function SS(t){var e=hG.call(t,Ll),r=t[Ll];try{t[Ll]=void 0;var n=!0}catch{}var a=yG.call(t);return n&&(e?t[Ll]=r:delete t[Ll]),a}s(SS,"getRawTag");var gG=SS,vG=Object.prototype,TG=vG.toString;function wS(t){return TG.call(t)}s(wS,"objectToString");var $G=wS,RG="[object Null]",AG="[object Undefined]",tT=pr?pr.toStringTag:void 0;function IS(t){return t==null?t===void 0?AG:RG:tT&&tT in Object(t)?gG(t):$G(t)}s(IS,"baseGetTag");var dl=IS;function NS(t){var e=typeof t;return t!=null&&(e=="object"||e=="function")}s(NS,"isObject");var ug=NS,EG="[object AsyncFunction]",CG="[object Function]",bG="[object GeneratorFunction]",_G="[object Proxy]";function PS(t){if(!ug(t))return!1;var e=dl(t);return e==CG||e==bG||e==EG||e==_G}s(PS,"isFunction");var kS=PS,SG=Fr["__core-js_shared__"],Hd=SG,rT=(function(){var t=/[^.]+$/.exec(Hd&&Hd.keys&&Hd.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""})();function OS(t){return!!rT&&rT in t}s(OS,"isMasked");var wG=OS,IG=Function.prototype,NG=IG.toString;function LS(t){if(t!=null){try{return NG.call(t)}catch{}try{return t+""}catch{}}return""}s(LS,"toSource");var oa=LS,PG=/[\\^$.*+?()[\]{}|]/g,kG=/^\[object .+?Constructor\]$/,OG=Function.prototype,LG=Object.prototype,DG=OG.toString,xG=LG.hasOwnProperty,MG=RegExp("^"+DG.call(xG).replace(PG,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function DS(t){if(!ug(t)||wG(t))return!1;var e=kS(t)?MG:kG;return e.test(oa(t))}s(DS,"baseIsNative");var GG=DS;function xS(t,e){return t?.[e]}s(xS,"getValue");var FG=xS;function MS(t,e){var r=FG(t,e);return GG(r)?r:void 0}s(MS,"getNative");var pl=MS,zG=pl(Fr,"Map"),Nu=zG,jG=pl(Object,"create"),Pu=jG;function GS(){this.__data__=Pu?Pu(null):{},this.size=0}s(GS,"hashClear");var BG=GS;function FS(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}s(FS,"hashDelete");var UG=FS,KG="__lodash_hash_undefined__",WG=Object.prototype,VG=WG.hasOwnProperty;function zS(t){var e=this.__data__;if(Pu){var r=e[t];return r===KG?void 0:r}return VG.call(e,t)?e[t]:void 0}s(zS,"hashGet");var qG=zS,HG=Object.prototype,YG=HG.hasOwnProperty;function jS(t){var e=this.__data__;return Pu?e[t]!==void 0:YG.call(e,t)}s(jS,"hashHas");var XG=jS,JG="__lodash_hash_undefined__";function BS(t,e){var r=this.__data__;return this.size+=this.has(t)?0:1,r[t]=Pu&&e===void 0?JG:e,this}s(BS,"hashSet");var ZG=BS;function la(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}s(la,"Hash");la.prototype.clear=BG;la.prototype.delete=UG;la.prototype.get=qG;la.prototype.has=XG;la.prototype.set=ZG;var nT=la;function US(){this.size=0,this.__data__={hash:new nT,map:new(Nu||Td),string:new nT}}s(US,"mapCacheClear");var QG=US;function KS(t){var e=typeof t;return e=="string"||e=="number"||e=="symbol"||e=="boolean"?t!=="__proto__":t===null}s(KS,"isKeyable");var eF=KS;function WS(t,e){var r=t.__data__;return eF(e)?r[typeof e=="string"?"string":"hash"]:r.map}s(WS,"getMapData");var $d=WS;function VS(t){var e=$d(this,t).delete(t);return this.size-=e?1:0,e}s(VS,"mapCacheDelete");var tF=VS;function qS(t){return $d(this,t).get(t)}s(qS,"mapCacheGet");var rF=qS;function HS(t){return $d(this,t).has(t)}s(HS,"mapCacheHas");var nF=HS;function YS(t,e){var r=$d(this,t),n=r.size;return r.set(t,e),this.size+=r.size==n?0:1,this}s(YS,"mapCacheSet");var aF=YS;function ua(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e<r;){var n=t[e];this.set(n[0],n[1])}}s(ua,"MapCache");ua.prototype.clear=QG;ua.prototype.delete=tF;ua.prototype.get=rF;ua.prototype.has=nF;ua.prototype.set=aF;var Rd=ua,iF=200;function XS(t,e){var r=this.__data__;if(r instanceof Td){var n=r.__data__;if(!Nu||n.length<iF-1)return n.push([t,e]),this.size=++r.size,this;r=this.__data__=new Rd(n)}return r.set(t,e),this.size=r.size,this}s(XS,"stackSet");var sF=XS;function ca(t){var e=this.__data__=new Td(t);this.size=e.size}s(ca,"Stack");ca.prototype.clear=oG;ca.prototype.delete=lG;ca.prototype.get=uG;ca.prototype.has=cG;ca.prototype.set=sF;var Mc=ca,oF="__lodash_hash_undefined__";function JS(t){return this.__data__.set(t,oF),this}s(JS,"setCacheAdd");var lF=JS;function ZS(t){return this.__data__.has(t)}s(ZS,"setCacheHas");var uF=ZS;function ku(t){var e=-1,r=t==null?0:t.length;for(this.__data__=new Rd;++e<r;)this.add(t[e])}s(ku,"SetCache");ku.prototype.add=ku.prototype.push=lF;ku.prototype.has=uF;var QS=ku;function ew(t,e){for(var r=-1,n=t==null?0:t.length;++r<n;)if(e(t[r],r,t))return!0;return!1}s(ew,"arraySome");var cF=ew;function tw(t,e){return t.has(e)}s(tw,"cacheHas");var rw=tw,fF=1,dF=2;function nw(t,e,r,n,a,i){var o=r&fF,u=t.length,l=e.length;if(u!=l&&!(o&&l>u))return!1;var c=i.get(t),f=i.get(e);if(c&&f)return c==e&&f==t;var d=-1,p=!0,y=r&dF?new QS:void 0;for(i.set(t,e),i.set(e,t);++d<u;){var h=t[d],$=e[d];if(n)var C=o?n($,h,d,e,t,i):n(h,$,d,t,e,i);if(C!==void 0){if(C)continue;p=!1;break}if(y){if(!cF(e,function(T,w){if(!rw(y,w)&&(h===T||a(h,T,r,n,i)))return y.push(w)})){p=!1;break}}else if(!(h===$||a(h,$,r,n,i))){p=!1;break}}return i.delete(t),i.delete(e),p}s(nw,"equalArrays");var aw=nw,pF=Fr.Uint8Array,aT=pF;function iw(t){var e=-1,r=Array(t.size);return t.forEach(function(n,a){r[++e]=[a,n]}),r}s(iw,"mapToArray");var mF=iw;function sw(t){var e=-1,r=Array(t.size);return t.forEach(function(n){r[++e]=n}),r}s(sw,"setToArray");var cg=sw,hF=1,yF=2,gF="[object Boolean]",vF="[object Date]",TF="[object Error]",$F="[object Map]",RF="[object Number]",AF="[object RegExp]",EF="[object Set]",CF="[object String]",bF="[object Symbol]",_F="[object ArrayBuffer]",SF="[object DataView]",iT=pr?pr.prototype:void 0,Yd=iT?iT.valueOf:void 0;function ow(t,e,r,n,a,i,o){switch(r){case SF:if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case _F:return!(t.byteLength!=e.byteLength||!i(new aT(t),new aT(e)));case gF:case vF:case RF:return hS(+t,+e);case TF:return t.name==e.name&&t.message==e.message;case AF:case CF:return t==e+"";case $F:var u=mF;case EF:var l=n&hF;if(u||(u=cg),t.size!=e.size&&!l)return!1;var c=o.get(t);if(c)return c==e;n|=yF,o.set(t,e);var f=aw(u(t),u(e),n,a,i,o);return o.delete(t),f;case bF:if(Yd)return Yd.call(t)==Yd.call(e)}return!1}s(ow,"equalByTag");var wF=ow;function lw(t,e){for(var r=-1,n=e.length,a=t.length;++r<n;)t[a+r]=e[r];return t}s(lw,"arrayPush");var uw=lw,IF=Array.isArray,gt=IF;function cw(t,e,r){var n=e(t);return gt(t)?n:uw(n,r(t))}s(cw,"baseGetAllKeys");var NF=cw;function fw(t,e){for(var r=-1,n=t==null?0:t.length,a=0,i=[];++r<n;){var o=t[r];e(o,r,t)&&(i[a++]=o)}return i}s(fw,"arrayFilter");var dw=fw;function pw(){return[]}s(pw,"stubArray");var PF=pw,kF=Object.prototype,OF=kF.propertyIsEnumerable,sT=Object.getOwnPropertySymbols,LF=sT?function(t){return t==null?[]:(t=Object(t),dw(sT(t),function(e){return OF.call(t,e)}))}:PF,DF=LF;function mw(t,e){for(var r=-1,n=Array(t);++r<t;)n[r]=e(r);return n}s(mw,"baseTimes");var xF=mw;function hw(t){return t!=null&&typeof t=="object"}s(hw,"isObjectLike");var rl=hw,MF="[object Arguments]";function yw(t){return rl(t)&&dl(t)==MF}s(yw,"baseIsArguments");var oT=yw,gw=Object.prototype,GF=gw.hasOwnProperty,FF=gw.propertyIsEnumerable,zF=oT((function(){return arguments})())?oT:function(t){return rl(t)&&GF.call(t,"callee")&&!FF.call(t,"callee")},Ad=zF;function vw(){return!1}s(vw,"stubFalse");var jF=vw,Tw=typeof exports=="object"&&exports&&!exports.nodeType&&exports,lT=Tw&&typeof module=="object"&&module&&!module.nodeType&&module,BF=lT&&lT.exports===Tw,uT=BF?Fr.Buffer:void 0,UF=uT?uT.isBuffer:void 0,KF=UF||jF,Af=KF,WF=9007199254740991,VF=/^(?:0|[1-9]\d*)$/;function $w(t,e){var r=typeof t;return e=e??WF,!!e&&(r=="number"||r!="symbol"&&VF.test(t))&&t>-1&&t%1==0&&t<e}s($w,"isIndex");var Rw=$w,qF=9007199254740991;function Aw(t){return typeof t=="number"&&t>-1&&t%1==0&&t<=qF}s(Aw,"isLength");var fg=Aw,HF="[object Arguments]",YF="[object Array]",XF="[object Boolean]",JF="[object Date]",ZF="[object Error]",QF="[object Function]",ez="[object Map]",tz="[object Number]",rz="[object Object]",nz="[object RegExp]",az="[object Set]",iz="[object String]",sz="[object WeakMap]",oz="[object ArrayBuffer]",lz="[object DataView]",uz="[object Float32Array]",cz="[object Float64Array]",fz="[object Int8Array]",dz="[object Int16Array]",pz="[object Int32Array]",mz="[object Uint8Array]",hz="[object Uint8ClampedArray]",yz="[object Uint16Array]",gz="[object Uint32Array]",_e={};_e[uz]=_e[cz]=_e[fz]=_e[dz]=_e[pz]=_e[mz]=_e[hz]=_e[yz]=_e[gz]=!0;_e[HF]=_e[YF]=_e[oz]=_e[XF]=_e[lz]=_e[JF]=_e[ZF]=_e[QF]=_e[ez]=_e[tz]=_e[rz]=_e[nz]=_e[az]=_e[iz]=_e[sz]=!1;function Ew(t){return rl(t)&&fg(t.length)&&!!_e[dl(t)]}s(Ew,"baseIsTypedArray");var vz=Ew;function Cw(t){return function(e){return t(e)}}s(Cw,"baseUnary");var Tz=Cw,bw=typeof exports=="object"&&exports&&!exports.nodeType&&exports,yu=bw&&typeof module=="object"&&module&&!module.nodeType&&module,$z=yu&&yu.exports===bw,Xd=$z&&bS.process,Rz=(function(){try{var t=yu&&yu.require&&yu.require("util").types;return t||Xd&&Xd.binding&&Xd.binding("util")}catch{}})(),cT=Rz,fT=cT&&cT.isTypedArray,Az=fT?Tz(fT):vz,dg=Az,Ez=Object.prototype,Cz=Ez.hasOwnProperty;function _w(t,e){var r=gt(t),n=!r&&Ad(t),a=!r&&!n&&Af(t),i=!r&&!n&&!a&&dg(t),o=r||n||a||i,u=o?xF(t.length,String):[],l=u.length;for(var c in t)(e||Cz.call(t,c))&&!(o&&(c=="length"||a&&(c=="offset"||c=="parent")||i&&(c=="buffer"||c=="byteLength"||c=="byteOffset")||Rw(c,l)))&&u.push(c);return u}s(_w,"arrayLikeKeys");var bz=_w,_z=Object.prototype;function Sw(t){var e=t&&t.constructor,r=typeof e=="function"&&e.prototype||_z;return t===r}s(Sw,"isPrototype");var ww=Sw;function Iw(t,e){return function(r){return t(e(r))}}s(Iw,"overArg");var Sz=Iw,wz=Sz(Object.keys,Object),Iz=wz,Nz=Object.prototype,Pz=Nz.hasOwnProperty;function Nw(t){if(!ww(t))return Iz(t);var e=[];for(var r in Object(t))Pz.call(t,r)&&r!="constructor"&&e.push(r);return e}s(Nw,"baseKeys");var Pw=Nw;function kw(t){return t!=null&&fg(t.length)&&!kS(t)}s(kw,"isArrayLike");var Ed=kw;function Ow(t){return Ed(t)?bz(t):Pw(t)}s(Ow,"keys");var pg=Ow;function Lw(t){return NF(t,pg,DF)}s(Lw,"getAllKeys");var dT=Lw,kz=1,Oz=Object.prototype,Lz=Oz.hasOwnProperty;function Dw(t,e,r,n,a,i){var o=r&kz,u=dT(t),l=u.length,c=dT(e),f=c.length;if(l!=f&&!o)return!1;for(var d=l;d--;){var p=u[d];if(!(o?p in e:Lz.call(e,p)))return!1}var y=i.get(t),h=i.get(e);if(y&&h)return y==e&&h==t;var $=!0;i.set(t,e),i.set(e,t);for(var C=o;++d<l;){p=u[d];var T=t[p],w=e[p];if(n)var b=o?n(w,T,p,e,t,i):n(T,w,p,t,e,i);if(!(b===void 0?T===w||a(T,w,r,n,i):b)){$=!1;break}C||(C=p=="constructor")}if($&&!C){var N=t.constructor,B=e.constructor;N!=B&&"constructor"in t&&"constructor"in e&&!(typeof N=="function"&&N instanceof N&&typeof B=="function"&&B instanceof B)&&($=!1)}return i.delete(t),i.delete(e),$}s(Dw,"equalObjects");var Dz=Dw,xz=pl(Fr,"DataView"),Bm=xz,Mz=pl(Fr,"Promise"),Um=Mz,Gz=pl(Fr,"Set"),Za=Gz,Fz=pl(Fr,"WeakMap"),Km=Fz,pT="[object Map]",zz="[object Object]",mT="[object Promise]",hT="[object Set]",yT="[object WeakMap]",gT="[object DataView]",jz=oa(Bm),Bz=oa(Nu),Uz=oa(Um),Kz=oa(Za),Wz=oa(Km),gn=dl;(Bm&&gn(new Bm(new ArrayBuffer(1)))!=gT||Nu&&gn(new Nu)!=pT||Um&&gn(Um.resolve())!=mT||Za&&gn(new Za)!=hT||Km&&gn(new Km)!=yT)&&(gn=s(function(t){var e=dl(t),r=e==zz?t.constructor:void 0,n=r?oa(r):"";if(n)switch(n){case jz:return gT;case Bz:return pT;case Uz:return mT;case Kz:return hT;case Wz:return yT}return e},"getTag"));var Wm=gn,Vz=1,vT="[object Arguments]",TT="[object Array]",lc="[object Object]",qz=Object.prototype,$T=qz.hasOwnProperty;function xw(t,e,r,n,a,i){var o=gt(t),u=gt(e),l=o?TT:Wm(t),c=u?TT:Wm(e);l=l==vT?lc:l,c=c==vT?lc:c;var f=l==lc,d=c==lc,p=l==c;if(p&&Af(t)){if(!Af(e))return!1;o=!0,f=!1}if(p&&!f)return i||(i=new Mc),o||dg(t)?aw(t,e,r,n,a,i):wF(t,e,l,r,n,a,i);if(!(r&Vz)){var y=f&&$T.call(t,"__wrapped__"),h=d&&$T.call(e,"__wrapped__");if(y||h){var $=y?t.value():t,C=h?e.value():e;return i||(i=new Mc),a($,C,r,n,i)}}return p?(i||(i=new Mc),Dz(t,e,r,n,a,i)):!1}s(xw,"baseIsEqualDeep");var Hz=xw;function mg(t,e,r,n,a){return t===e?!0:t==null||e==null||!rl(t)&&!rl(e)?t!==t&&e!==e:Hz(t,e,r,n,mg,a)}s(mg,"baseIsEqual");var Mw=mg,Yz=1,Xz=2;function Gw(t,e,r,n){var a=r.length,i=a,o=!n;if(t==null)return!i;for(t=Object(t);a--;){var u=r[a];if(o&&u[2]?u[1]!==t[u[0]]:!(u[0]in t))return!1}for(;++a<i;){u=r[a];var l=u[0],c=t[l],f=u[1];if(o&&u[2]){if(c===void 0&&!(l in t))return!1}else{var d=new Mc;if(n)var p=n(c,f,l,t,e,d);if(!(p===void 0?Mw(f,c,Yz|Xz,n,d):p))return!1}}return!0}s(Gw,"baseIsMatch");var Jz=Gw;function Fw(t){return t===t&&!ug(t)}s(Fw,"isStrictComparable");var zw=Fw;function jw(t){for(var e=pg(t),r=e.length;r--;){var n=e[r],a=t[n];e[r]=[n,a,zw(a)]}return e}s(jw,"getMatchData");var Zz=jw;function Bw(t,e){return function(r){return r==null?!1:r[t]===e&&(e!==void 0||t in Object(r))}}s(Bw,"matchesStrictComparable");var Uw=Bw;function Kw(t){var e=Zz(t);return e.length==1&&e[0][2]?Uw(e[0][0],e[0][1]):function(r){return r===t||Jz(r,t,e)}}s(Kw,"baseMatches");var Qz=Kw,ej="[object Symbol]";function Ww(t){return typeof t=="symbol"||rl(t)&&dl(t)==ej}s(Ww,"isSymbol");var Cd=Ww,tj=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,rj=/^\w*$/;function Vw(t,e){if(gt(t))return!1;var r=typeof t;return r=="number"||r=="symbol"||r=="boolean"||t==null||Cd(t)?!0:rj.test(t)||!tj.test(t)||e!=null&&t in Object(e)}s(Vw,"isKey");var hg=Vw,nj="Expected a function";function bd(t,e){if(typeof t!="function"||e!=null&&typeof e!="function")throw new TypeError(nj);var r=s(function(){var n=arguments,a=e?e.apply(this,n):n[0],i=r.cache;if(i.has(a))return i.get(a);var o=t.apply(this,n);return r.cache=i.set(a,o)||i,o},"memoized");return r.cache=new(bd.Cache||Rd),r}s(bd,"memoize");bd.Cache=Rd;var aj=bd,ij=500;function qw(t){var e=aj(t,function(n){return r.size===ij&&r.clear(),n}),r=e.cache;return e}s(qw,"memoizeCapped");var sj=qw,oj=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,lj=/\\(\\)?/g,uj=sj(function(t){var e=[];return t.charCodeAt(0)===46&&e.push(""),t.replace(oj,function(r,n,a,i){e.push(a?i.replace(lj,"$1"):n||r)}),e}),cj=uj,RT=pr?pr.prototype:void 0,AT=RT?RT.toString:void 0;function yg(t){if(typeof t=="string")return t;if(gt(t))return dS(t,yg)+"";if(Cd(t))return AT?AT.call(t):"";var e=t+"";return e=="0"&&1/t==-1/0?"-0":e}s(yg,"baseToString");var fj=yg;function Hw(t){return t==null?"":fj(t)}s(Hw,"toString");var dj=Hw;function Yw(t,e){return gt(t)?t:hg(t,e)?[t]:cj(dj(t))}s(Yw,"castPath");var Xw=Yw;function Jw(t){if(typeof t=="string"||Cd(t))return t;var e=t+"";return e=="0"&&1/t==-1/0?"-0":e}s(Jw,"toKey");var _d=Jw;function Zw(t,e){e=Xw(e,t);for(var r=0,n=e.length;t!=null&&r<n;)t=t[_d(e[r++])];return r&&r==n?t:void 0}s(Zw,"baseGet");var Qw=Zw;function eI(t,e,r){var n=t==null?void 0:Qw(t,e);return n===void 0?r:n}s(eI,"get");var pj=eI;function tI(t,e){return t!=null&&e in Object(t)}s(tI,"baseHasIn");var mj=tI;function rI(t,e,r){e=Xw(e,t);for(var n=-1,a=e.length,i=!1;++n<a;){var o=_d(e[n]);if(!(i=t!=null&&r(t,o)))break;t=t[o]}return i||++n!=a?i:(a=t==null?0:t.length,!!a&&fg(a)&&Rw(o,a)&&(gt(t)||Ad(t)))}s(rI,"hasPath");var hj=rI;function nI(t,e){return t!=null&&hj(t,e,mj)}s(nI,"hasIn");var yj=nI,gj=1,vj=2;function aI(t,e){return hg(t)&&zw(e)?Uw(_d(t),e):function(r){var n=pj(r,t);return n===void 0&&n===e?yj(r,t):Mw(e,n,gj|vj)}}s(aI,"baseMatchesProperty");var Tj=aI;function iI(t){return t}s(iI,"identity");var gg=iI;function sI(t){return function(e){return e?.[t]}}s(sI,"baseProperty");var $j=sI;function oI(t){return function(e){return Qw(e,t)}}s(oI,"basePropertyDeep");var Rj=oI;function lI(t){return hg(t)?$j(_d(t)):Rj(t)}s(lI,"property");var Aj=lI;function uI(t){return typeof t=="function"?t:t==null?gg:typeof t=="object"?gt(t)?Tj(t[0],t[1]):Qz(t):Aj(t)}s(uI,"baseIteratee");var Sd=uI;function cI(t){return function(e,r,n){for(var a=-1,i=Object(e),o=n(e),u=o.length;u--;){var l=o[t?u:++a];if(r(i[l],l,i)===!1)break}return e}}s(cI,"createBaseFor");var Ej=cI,Cj=Ej(),bj=Cj;function fI(t,e){return t&&bj(t,e,pg)}s(fI,"baseForOwn");var _j=fI;function dI(t,e){return function(r,n){if(r==null)return r;if(!Ed(r))return t(r,n);for(var a=r.length,i=e?a:-1,o=Object(r);(e?i--:++i<a)&&n(o[i],i,o)!==!1;);return r}}s(dI,"createBaseEach");var Sj=dI,wj=Sj(_j),wd=wj;function pI(t,e){var r=-1,n=Ed(t)?Array(t.length):[];return wd(t,function(a,i,o){n[++r]=e(a,i,o)}),n}s(pI,"baseMap");var Ij=pI;function mI(t,e){var r=gt(t)?dS:Ij;return r(t,Sd(e))}s(mI,"map");var _r=mI;function hI(t,e){var r=[];return wd(t,function(n,a,i){e(n,a,i)&&r.push(n)}),r}s(hI,"baseFilter");var Nj=hI;function yI(t,e){var r=gt(t)?dw:Nj;return r(t,Sd(e))}s(yI,"filter");var Pj=yI;function Wn(t,e,r){return`${t.name}_${e}_${r}`}s(Wn,"buildATNKey");var Qr=1,kj=2,gI=4,vI=5,rc=7,Oj=8,Lj=9,Dj=10,xj=11,TI=12,es,vg=(es=class{constructor(e){this.target=e}isEpsilon(){return!1}},s(es,"AbstractTransition"),es),ts,Tg=(ts=class extends vg{constructor(e,r){super(e),this.tokenType=r}},s(ts,"AtomTransition"),ts),rs,$I=(rs=class extends vg{constructor(e){super(e)}isEpsilon(){return!0}},s(rs,"EpsilonTransition"),rs),ns,$g=(ns=class extends vg{constructor(e,r,n){super(e),this.rule=r,this.followState=n}isEpsilon(){return!0}},s(ns,"RuleTransition"),ns);function RI(t){const e={decisionMap:{},decisionStates:[],ruleToStartState:new Map,ruleToStopState:new Map,states:[]};AI(e,t);const r=t.length;for(let n=0;n<r;n++){const a=t[n],i=sn(e,a,a);i!==void 0&&OI(e,a,i)}return e}s(RI,"createATN");function AI(t,e){const r=e.length;for(let n=0;n<r;n++){const a=e[n],i=We(t,a,void 0,{type:kj}),o=We(t,a,void 0,{type:rc});i.stop=o,t.ruleToStartState.set(a,i),t.ruleToStopState.set(a,o)}}s(AI,"createRuleStartAndStopATNStates");function Rg(t,e,r){return r instanceof Se?Id(t,e,r.terminalType,r):r instanceof ht?kI(t,e,r):r instanceof St?SI(t,e,r):r instanceof at?wI(t,e,r):r instanceof xe?EI(t,e,r):r instanceof _t?CI(t,e,r):r instanceof Ot?bI(t,e,r):r instanceof Lt?_I(t,e,r):sn(t,e,r)}s(Rg,"atom");function EI(t,e,r){const n=We(t,e,r,{type:vI});zr(t,n);const a=fa(t,e,n,r,sn(t,e,r));return Eg(t,e,r,a)}s(EI,"repetition");function CI(t,e,r){const n=We(t,e,r,{type:vI});zr(t,n);const a=fa(t,e,n,r,sn(t,e,r)),i=Id(t,e,r.separator,r);return Eg(t,e,r,a,i)}s(CI,"repetitionSep");function bI(t,e,r){const n=We(t,e,r,{type:gI});zr(t,n);const a=fa(t,e,n,r,sn(t,e,r));return Ag(t,e,r,a)}s(bI,"repetitionMandatory");function _I(t,e,r){const n=We(t,e,r,{type:gI});zr(t,n);const a=fa(t,e,n,r,sn(t,e,r)),i=Id(t,e,r.separator,r);return Ag(t,e,r,a,i)}s(_I,"repetitionMandatorySep");function SI(t,e,r){const n=We(t,e,r,{type:Qr});zr(t,n);const a=_r(r.definition,o=>Rg(t,e,o));return fa(t,e,n,r,...a)}s(SI,"alternation");function wI(t,e,r){const n=We(t,e,r,{type:Qr});zr(t,n);const a=fa(t,e,n,r,sn(t,e,r));return II(t,e,r,a)}s(wI,"option");function sn(t,e,r){const n=Pj(_r(r.definition,a=>Rg(t,e,a)),a=>a!==void 0);return n.length===1?n[0]:n.length===0?void 0:PI(t,n)}s(sn,"block");function Ag(t,e,r,n,a){const i=n.left,o=n.right,u=We(t,e,r,{type:xj});zr(t,u);const l=We(t,e,r,{type:TI});return i.loopback=u,l.loopback=u,t.decisionMap[Wn(e,a?"RepetitionMandatoryWithSeparator":"RepetitionMandatory",r.idx)]=u,Fe(o,u),a===void 0?(Fe(u,i),Fe(u,l)):(Fe(u,l),Fe(u,a.left),Fe(a.right,i)),{left:i,right:l}}s(Ag,"plus");function Eg(t,e,r,n,a){const i=n.left,o=n.right,u=We(t,e,r,{type:Dj});zr(t,u);const l=We(t,e,r,{type:TI}),c=We(t,e,r,{type:Lj});return u.loopback=c,l.loopback=c,Fe(u,i),Fe(u,l),Fe(o,c),a!==void 0?(Fe(c,l),Fe(c,a.left),Fe(a.right,i)):Fe(c,u),t.decisionMap[Wn(e,a?"RepetitionWithSeparator":"Repetition",r.idx)]=u,{left:u,right:l}}s(Eg,"star");function II(t,e,r,n){const a=n.left,i=n.right;return Fe(a,i),t.decisionMap[Wn(e,"Option",r.idx)]=a,n}s(II,"optional");function zr(t,e){return t.decisionStates.push(e),e.decision=t.decisionStates.length-1,e.decision}s(zr,"defineDecisionState");function fa(t,e,r,n,...a){const i=We(t,e,n,{type:Oj,start:r});r.end=i;for(const u of a)u!==void 0?(Fe(r,u.left),Fe(u.right,i)):Fe(r,i);const o={left:r,right:i};return t.decisionMap[Wn(e,NI(n),n.idx)]=r,o}s(fa,"makeAlts");function NI(t){if(t instanceof St)return"Alternation";if(t instanceof at)return"Option";if(t instanceof xe)return"Repetition";if(t instanceof _t)return"RepetitionWithSeparator";if(t instanceof Ot)return"RepetitionMandatory";if(t instanceof Lt)return"RepetitionMandatoryWithSeparator";throw new Error("Invalid production type encountered")}s(NI,"getProdType");function PI(t,e){const r=e.length;for(let i=0;i<r-1;i++){const o=e[i];let u;o.left.transitions.length===1&&(u=o.left.transitions[0]);const l=u instanceof $g,c=u,f=e[i+1].left;o.left.type===Qr&&o.right.type===Qr&&u!==void 0&&(l&&c.followState===o.right||u.target===o.right)?(l?c.followState=f:u.target=f,LI(t,o.right)):Fe(o.right,f)}const n=e[0],a=e[r-1];return{left:n.left,right:a.right}}s(PI,"makeBlock");function Id(t,e,r,n){const a=We(t,e,n,{type:Qr}),i=We(t,e,n,{type:Qr});return Nd(a,new Tg(i,r)),{left:a,right:i}}s(Id,"tokenRef");function kI(t,e,r){const n=r.referencedRule,a=t.ruleToStartState.get(n),i=We(t,e,r,{type:Qr}),o=We(t,e,r,{type:Qr}),u=new $g(a,n,o);return Nd(i,u),{left:i,right:o}}s(kI,"ruleRef");function OI(t,e,r){const n=t.ruleToStartState.get(e);Fe(n,r.left);const a=t.ruleToStopState.get(e);return Fe(r.right,a),{left:n,right:a}}s(OI,"buildRuleHandle");function Fe(t,e){const r=new $I(e);Nd(t,r)}s(Fe,"epsilon");function We(t,e,r,n){const a=Object.assign({atn:t,production:r,epsilonOnlyTransitions:!1,rule:e,transitions:[],nextTokenWithinRule:[],stateNumber:t.states.length},n);return t.states.push(a),a}s(We,"newState");function Nd(t,e){t.transitions.length===0&&(t.epsilonOnlyTransitions=e.isEpsilon()),t.transitions.push(e)}s(Nd,"addTransition");function LI(t,e){t.states.splice(t.states.indexOf(e),1)}s(LI,"removeState");var Ef={},as,Vm=(as=class{constructor(){this.map={},this.configs=[]}get size(){return this.configs.length}finalize(){this.map={}}add(e){const r=Cg(e);r in this.map||(this.map[r]=this.configs.length,this.configs.push(e))}get elements(){return this.configs}get alts(){return _r(this.configs,e=>e.alt)}get key(){let e="";for(const r in this.map)e+=r+":";return e}},s(as,"ATNConfigSet"),as);function Cg(t,e=!0){return`${e?`a${t.alt}`:""}s${t.state.stateNumber}:${t.stack.map(r=>r.stateNumber.toString()).join("_")}`}s(Cg,"getATNConfigKey");function DI(t,e,r){for(var n=-1,a=t.length;++n<a;){var i=t[n],o=e(i);if(o!=null&&(u===void 0?o===o&&!Cd(o):r(o,u)))var u=o,l=i}return l}s(DI,"baseExtremum");var Mj=DI;function xI(t,e){return t<e}s(xI,"baseLt");var Gj=xI;function MI(t){return t&&t.length?Mj(t,gg,Gj):void 0}s(MI,"min");var Fj=MI,ET=pr?pr.isConcatSpreadable:void 0;function GI(t){return gt(t)||Ad(t)||!!(ET&&t&&t[ET])}s(GI,"isFlattenable");var zj=GI;function bg(t,e,r,n,a){var i=-1,o=t.length;for(r||(r=zj),a||(a=[]);++i<o;){var u=t[i];e>0&&r(u)?e>1?bg(u,e-1,r,n,a):uw(a,u):n||(a[a.length]=u)}return a}s(bg,"baseFlatten");var FI=bg;function zI(t,e){return FI(_r(t,e),1)}s(zI,"flatMap");var jj=zI;function jI(t,e,r,n){for(var a=t.length,i=r+(n?1:-1);n?i--:++i<a;)if(e(t[i],i,t))return i;return-1}s(jI,"baseFindIndex");var Bj=jI;function BI(t){return t!==t}s(BI,"baseIsNaN");var Uj=BI;function UI(t,e,r){for(var n=r-1,a=t.length;++n<a;)if(t[n]===e)return n;return-1}s(UI,"strictIndexOf");var Kj=UI;function KI(t,e,r){return e===e?Kj(t,e,r):Bj(t,Uj,r)}s(KI,"baseIndexOf");var Wj=KI;function WI(t,e){var r=t==null?0:t.length;return!!r&&Wj(t,e,0)>-1}s(WI,"arrayIncludes");var Vj=WI;function VI(t,e,r){for(var n=-1,a=t==null?0:t.length;++n<a;)if(r(e,t[n]))return!0;return!1}s(VI,"arrayIncludesWith");var qj=VI;function qI(){}s(qI,"noop");var Hj=qI,Yj=1/0,Xj=Za&&1/cg(new Za([,-0]))[1]==Yj?function(t){return new Za(t)}:Hj,Jj=Xj,Zj=200;function HI(t,e,r){var n=-1,a=Vj,i=t.length,o=!0,u=[],l=u;if(r)o=!1,a=qj;else if(i>=Zj){var c=e?null:Jj(t);if(c)return cg(c);o=!1,a=rw,l=new QS}else l=e?[]:u;e:for(;++n<i;){var f=t[n],d=e?e(f):f;if(f=r||f!==0?f:0,o&&d===d){for(var p=l.length;p--;)if(l[p]===d)continue e;e&&l.push(d),u.push(f)}else a(l,d,r)||(l!==u&&l.push(d),u.push(f))}return u}s(HI,"baseUniq");var Qj=HI;function YI(t,e){return t&&t.length?Qj(t,Sd(e)):[]}s(YI,"uniqBy");var eB=YI;function XI(t){var e=t==null?0:t.length;return e?FI(t,1):[]}s(XI,"flatten");var tB=XI;function JI(t,e){for(var r=-1,n=t==null?0:t.length;++r<n&&e(t[r],r,t)!==!1;);return t}s(JI,"arrayEach");var rB=JI;function ZI(t){return typeof t=="function"?t:gg}s(ZI,"castFunction");var nB=ZI;function QI(t,e){var r=gt(t)?rB:wd;return r(t,nB(e))}s(QI,"forEach");var Jd=QI,aB="[object Map]",iB="[object Set]",sB=Object.prototype,oB=sB.hasOwnProperty;function eN(t){if(t==null)return!0;if(Ed(t)&&(gt(t)||typeof t=="string"||typeof t.splice=="function"||Af(t)||dg(t)||Ad(t)))return!t.length;var e=Wm(t);if(e==aB||e==iB)return!t.size;if(ww(t))return!Pw(t).length;for(var r in t)if(oB.call(t,r))return!1;return!0}s(eN,"isEmpty");var lB=eN;function tN(t,e,r,n){var a=-1,i=t==null?0:t.length;for(n&&i&&(r=t[++a]);++a<i;)r=e(r,t[a],a,t);return r}s(tN,"arrayReduce");var uB=tN;function rN(t,e,r,n,a){return a(t,function(i,o,u){r=n?(n=!1,i):e(r,i,o,u)}),r}s(rN,"baseReduce");var cB=rN;function nN(t,e,r){var n=gt(t)?uB:cB,a=arguments.length<3;return n(t,Sd(e),r,a,wd)}s(nN,"reduce");var CT=nN;function aN(t,e){const r={};return n=>{const a=n.toString();let i=r[a];return i!==void 0||(i={atnStartState:t,decision:e,states:{}},r[a]=i),i}}s(aN,"createDFACache");var is,iN=(is=class{constructor(){this.predicates=[]}is(e){return e>=this.predicates.length||this.predicates[e]}set(e,r){this.predicates[e]=r}toString(){let e="";const r=this.predicates.length;for(let n=0;n<r;n++)e+=this.predicates[n]===!0?"1":"0";return e}},s(is,"PredicateSet"),is),bT=new iN,ss,fB=(ss=class extends sg{constructor(e){var r;super(),this.logging=(r=e?.logging)!==null&&r!==void 0?r:(n=>console.log(n))}initialize(e){this.atn=RI(e.rules),this.dfas=sN(this.atn)}validateAmbiguousAlternationAlternatives(){return[]}validateEmptyOrAlternatives(){return[]}buildLookaheadForAlternation(e){const{prodOccurrence:r,rule:n,hasPredicates:a,dynamicTokensEnabled:i}=e,o=this.dfas,u=this.logging,l=Wn(n,"Alternation",r),f=this.atn.decisionMap[l].decision,d=_r(km({maxLookahead:1,occurrence:r,prodType:"Alternation",rule:n}),p=>_r(p,y=>y[0]));if(qm(d,!1)&&!i){const p=CT(d,(y,h,$)=>(Jd(h,C=>{C&&(y[C.tokenTypeIdx]=$,Jd(C.categoryMatches,T=>{y[T]=$}))}),y),{});return a?function(y){var h;const $=this.LA(1),C=p[$.tokenTypeIdx];if(y!==void 0&&C!==void 0){const T=(h=y[C])===null||h===void 0?void 0:h.GATE;if(T!==void 0&&T.call(this)===!1)return}return C}:function(){const y=this.LA(1);return p[y.tokenTypeIdx]}}else return a?function(p){const y=new iN,h=p===void 0?0:p.length;for(let C=0;C<h;C++){const T=p?.[C].GATE;y.set(C,T===void 0||T.call(this))}const $=Gc.call(this,o,f,y,u);return typeof $=="number"?$:void 0}:function(){const p=Gc.call(this,o,f,bT,u);return typeof p=="number"?p:void 0}}buildLookaheadForOptional(e){const{prodOccurrence:r,rule:n,prodType:a,dynamicTokensEnabled:i}=e,o=this.dfas,u=this.logging,l=Wn(n,a,r),f=this.atn.decisionMap[l].decision,d=_r(km({maxLookahead:1,occurrence:r,prodType:a,rule:n}),p=>_r(p,y=>y[0]));if(qm(d)&&d[0][0]&&!i){const p=d[0],y=tB(p);if(y.length===1&&lB(y[0].categoryMatches)){const $=y[0].tokenTypeIdx;return function(){return this.LA(1).tokenTypeIdx===$}}else{const h=CT(y,($,C)=>(C!==void 0&&($[C.tokenTypeIdx]=!0,Jd(C.categoryMatches,T=>{$[T]=!0})),$),{});return function(){const $=this.LA(1);return h[$.tokenTypeIdx]===!0}}}return function(){const p=Gc.call(this,o,f,bT,u);return typeof p=="object"?!1:p===0}}},s(ss,"LLStarLookaheadStrategy"),ss);function qm(t,e=!0){const r=new Set;for(const n of t){const a=new Set;for(const i of n){if(i===void 0){if(e)break;return!1}const o=[i.tokenTypeIdx].concat(i.categoryMatches);for(const u of o)if(r.has(u)){if(!a.has(u))return!1}else r.add(u),a.add(u)}}return!0}s(qm,"isLL1Sequence");function sN(t){const e=t.decisionStates.length,r=Array(e);for(let n=0;n<e;n++)r[n]=aN(t.decisionStates[n],n);return r}s(sN,"initATNSimulator");function Gc(t,e,r,n){const a=t[e](r);let i=a.start;if(i===void 0){const u=gN(a.atnStartState);i=Sg(a,_g(u)),a.start=i}return oN.apply(this,[a,i,r,n])}s(Gc,"adaptivePredict");function oN(t,e,r,n){let a=e,i=1;const o=[];let u=this.LA(i++);for(;;){let l=pN(a,u);if(l===void 0&&(l=lN.apply(this,[t,a,u,i,r,n])),l===Ef)return dN(o,a,u);if(l.isAcceptState===!0)return l.prediction;a=l,o.push(u),u=this.LA(i++)}}s(oN,"performLookahead");function lN(t,e,r,n,a,i){const o=mN(e.configs,r,a);if(o.size===0)return Hm(t,e,r,Ef),Ef;let u=_g(o);const l=yN(o,a);if(l!==void 0)u.isAcceptState=!0,u.prediction=l,u.configs.uniqueAlt=l;else if(RN(o)){const c=Fj(o.alts);u.isAcceptState=!0,u.prediction=c,u.configs.uniqueAlt=c,uN.apply(this,[t,n,o.alts,i])}return u=Hm(t,e,r,u),u}s(lN,"computeLookaheadTarget");function uN(t,e,r,n){const a=[];for(let c=1;c<=e;c++)a.push(this.LA(c).tokenType);const i=t.atnStartState,o=i.rule,u=i.production,l=cN({topLevelRule:o,ambiguityIndices:r,production:u,prefixPath:a});n(l)}s(uN,"reportLookaheadAmbiguity");function cN(t){const e=_r(t.prefixPath,a=>Gn(a)).join(", "),r=t.production.idx===0?"":t.production.idx;let n=`Ambiguous Alternatives Detected: <${t.ambiguityIndices.join(", ")}> in <${fN(t.production)}${r}> inside <${t.topLevelRule.name}> Rule,
148
148
  <${e}> may appears as a prefix path in all these alternatives.
149
149
  `;return n=n+`See: https://chevrotain.io/docs/guide/resolving_grammar_errors.html#AMBIGUOUS_ALTERNATIVES
150
150
  For Further details.`,n}s(cN,"buildAmbiguityError");function fN(t){if(t instanceof ht)return"SUBRULE";if(t instanceof at)return"OPTION";if(t instanceof St)return"OR";if(t instanceof Ot)return"AT_LEAST_ONE";if(t instanceof Lt)return"AT_LEAST_ONE_SEP";if(t instanceof _t)return"MANY_SEP";if(t instanceof xe)return"MANY";if(t instanceof Se)return"CONSUME";throw Error("non exhaustive match")}s(fN,"getProductionDslName");function dN(t,e,r){const n=jj(e.configs.elements,i=>i.state.transitions),a=eB(n.filter(i=>i instanceof Tg).map(i=>i.tokenType),i=>i.tokenTypeIdx);return{actualToken:r,possibleTokenTypes:a,tokenPath:t}}s(dN,"buildAdaptivePredictError");function pN(t,e){return t.edges[e.tokenTypeIdx]}s(pN,"getExistingTargetState");function mN(t,e,r){const n=new Vm,a=[];for(const o of t.elements){if(r.is(o.alt)===!1)continue;if(o.state.type===rc){a.push(o);continue}const u=o.state.transitions.length;for(let l=0;l<u;l++){const c=o.state.transitions[l],f=hN(c,e);f!==void 0&&n.add({state:f,alt:o.alt,stack:o.stack})}}let i;if(a.length===0&&n.size===1&&(i=n),i===void 0){i=new Vm;for(const o of n.elements)Ou(o,i)}if(a.length>0&&!TN(i))for(const o of a)i.add(o);return i}s(mN,"computeReachSet");function hN(t,e){if(t instanceof Tg&&Qy(e,t.tokenType))return t.target}s(hN,"getReachableTarget");function yN(t,e){let r;for(const n of t.elements)if(e.is(n.alt)===!0){if(r===void 0)r=n.alt;else if(r!==n.alt)return}return r}s(yN,"getUniqueAlt");function _g(t){return{configs:t,edges:{},isAcceptState:!1,prediction:-1}}s(_g,"newDFAState");function Hm(t,e,r,n){return n=Sg(t,n),e.edges[r.tokenTypeIdx]=n,n}s(Hm,"addDFAEdge");function Sg(t,e){if(e===Ef)return e;const r=e.configs.key,n=t.states[r];return n!==void 0?n:(e.configs.finalize(),t.states[r]=e,e)}s(Sg,"addDFAState");function gN(t){const e=new Vm,r=t.transitions.length;for(let n=0;n<r;n++){const i={state:t.transitions[n].target,alt:n,stack:[]};Ou(i,e)}return e}s(gN,"computeStartState");function Ou(t,e){const r=t.state;if(r.type===rc){if(t.stack.length>0){const a=[...t.stack],o={state:a.pop(),alt:t.alt,stack:a};Ou(o,e)}else e.add(t);return}r.epsilonOnlyTransitions||e.add(t);const n=r.transitions.length;for(let a=0;a<n;a++){const i=r.transitions[a],o=vN(t,i);o!==void 0&&Ou(o,e)}}s(Ou,"closure");function vN(t,e){if(e instanceof $I)return{state:e.target,alt:t.alt,stack:t.stack};if(e instanceof $g){const r=[...t.stack,e.followState];return{state:e.target,alt:t.alt,stack:r}}}s(vN,"getEpsilonTarget");function TN(t){for(const e of t.elements)if(e.state.type===rc)return!0;return!1}s(TN,"hasConfigInRuleStopState");function $N(t){for(const e of t.elements)if(e.state.type!==rc)return!1;return!0}s($N,"allConfigsInRuleStopStates");function RN(t){if($N(t))return!0;const e=AN(t.elements);return EN(e)&&!CN(e)}s(RN,"hasConflictTerminatingPrediction");function AN(t){const e=new Map;for(const r of t){const n=Cg(r,!1);let a=e.get(n);a===void 0&&(a={},e.set(n,a)),a[r.alt]=!0}return e}s(AN,"getConflictingAltSets");function EN(t){for(const e of Array.from(t.values()))if(Object.keys(e).length>1)return!0;return!1}s(EN,"hasConflictingAltSet");function CN(t){for(const e of Array.from(t.values()))if(Object.keys(e).length===1)return!0;return!1}s(CN,"hasStateAssociatedWithOneAlt");xu();var os,bN=(os=class{constructor(){this.nodeStack=[]}get current(){return this.nodeStack[this.nodeStack.length-1]??this.rootNode}buildRootNode(e){return this.rootNode=new Ig(e),this.rootNode.root=this.rootNode,this.nodeStack=[this.rootNode],this.rootNode}buildCompositeNode(e){const r=new Pd;return r.grammarSource=e,r.root=this.rootNode,this.current.content.push(r),this.nodeStack.push(r),r}buildLeafNode(e,r){const n=new Cf(e.startOffset,e.image.length,$u(e),e.tokenType,!r);return n.grammarSource=r,n.root=this.rootNode,this.current.content.push(n),n}removeNode(e){const r=e.container;if(r){const n=r.content.indexOf(e);n>=0&&r.content.splice(n,1)}}addHiddenNodes(e){const r=[];for(const i of e){const o=new Cf(i.startOffset,i.image.length,$u(i),i.tokenType,!0);o.root=this.rootNode,r.push(o)}let n=this.current,a=!1;if(n.content.length>0){n.content.push(...r);return}for(;n.container;){const i=n.container.content.indexOf(n);if(i>0){n.container.content.splice(i,0,...r),a=!0;break}n=n.container}a||this.rootNode.content.unshift(...r)}construct(e){const r=this.current;typeof e.$type=="string"&&!e.$infixName&&(this.current.astNode=e),e.$cstNode=r;const n=this.nodeStack.pop();n?.content.length===0&&this.removeNode(n)}},s(os,"CstNodeBuilder"),os),ls,wg=(ls=class{get hidden(){return!1}get astNode(){const e=typeof this._astNode?.$type=="string"?this._astNode:this.container?.astNode;if(!e)throw new Error("This node has no associated AST element");return e}set astNode(e){this._astNode=e}get text(){return this.root.fullText.substring(this.offset,this.end)}},s(ls,"AbstractCstNode"),ls),us,Cf=(us=class extends wg{get offset(){return this._offset}get length(){return this._length}get end(){return this._offset+this._length}get hidden(){return this._hidden}get tokenType(){return this._tokenType}get range(){return this._range}constructor(e,r,n,a,i=!1){super(),this._hidden=i,this._offset=e,this._tokenType=a,this._length=r,this._range=n}},s(us,"LeafCstNodeImpl"),us),cs,Pd=(cs=class extends wg{constructor(){super(...arguments),this.content=new dB(this)}get offset(){return this.firstNonHiddenNode?.offset??0}get length(){return this.end-this.offset}get end(){return this.lastNonHiddenNode?.end??0}get range(){const e=this.firstNonHiddenNode,r=this.lastNonHiddenNode;if(e&&r){if(this._rangeCache===void 0){const{range:n}=e,{range:a}=r;this._rangeCache={start:n.start,end:a.end.line<n.start.line?n.start:a.end}}return this._rangeCache}else return{start:oe.create(0,0),end:oe.create(0,0)}}get firstNonHiddenNode(){for(const e of this.content)if(!e.hidden)return e;return this.content[0]}get lastNonHiddenNode(){for(let e=this.content.length-1;e>=0;e--){const r=this.content[e];if(!r.hidden)return r}return this.content[this.content.length-1]}},s(cs,"CompositeCstNodeImpl"),cs),jn,dB=(jn=class extends Array{constructor(e){super(),this.parent=e,Object.setPrototypeOf(this,jn.prototype)}push(...e){return this.addParents(e),super.push(...e)}unshift(...e){return this.addParents(e),super.unshift(...e)}splice(e,r,...n){return this.addParents(n),super.splice(e,r,...n)}addParents(e){for(const r of e)r.container=this.parent}},s(jn,"CstNodeContainer"),jn),fs,Ig=(fs=class extends Pd{get text(){return this._text.substring(this.offset,this.end)}get fullText(){return this._text}constructor(e){super(),this._text="",this._text=e??""}},s(fs,"RootCstNodeImpl"),fs),bf=Symbol("Datatype");function Fc(t){return t.$type===bf}s(Fc,"isDataTypeNode");var _T="​",_N=s(t=>t.endsWith(_T)?t:t+_T,"withRuleSuffix"),ds,Ng=(ds=class{constructor(e){this._unorderedGroups=new Map,this.allRules=new Map,this.lexer=e.parser.Lexer;const r=this.lexer.definition,n=e.LanguageMetaData.mode==="production";e.shared.profilers.LangiumProfiler?.isActive("parsing")?this.wrapper=new mB(r,{...e.parser.ParserConfig,skipValidations:n,errorMessageProvider:e.parser.ParserErrorMessageProvider},e.shared.profilers.LangiumProfiler.createTask("parsing",e.LanguageMetaData.languageId)):this.wrapper=new NN(r,{...e.parser.ParserConfig,skipValidations:n,errorMessageProvider:e.parser.ParserErrorMessageProvider})}alternatives(e,r){this.wrapper.wrapOr(e,r)}optional(e,r){this.wrapper.wrapOption(e,r)}many(e,r){this.wrapper.wrapMany(e,r)}atLeastOne(e,r){this.wrapper.wrapAtLeastOne(e,r)}getRule(e){return this.allRules.get(e)}isRecording(){return this.wrapper.IS_RECORDING}get unorderedGroups(){return this._unorderedGroups}getRuleStack(){return this.wrapper.RULE_STACK}finalize(){this.wrapper.wrapSelfAnalysis()}},s(ds,"AbstractLangiumParser"),ds),ps,SN=(ps=class extends Ng{get current(){return this.stack[this.stack.length-1]}constructor(e){super(e),this.nodeBuilder=new bN,this.stack=[],this.assignmentMap=new Map,this.operatorPrecedence=new Map,this.linker=e.references.Linker,this.converter=e.parser.ValueConverter,this.astReflection=e.shared.AstReflection}rule(e,r){const n=this.computeRuleType(e);let a;Jo(e)&&(a=e.name,this.registerPrecedenceMap(e));const i=this.wrapper.DEFINE_RULE(_N(e.name),this.startImplementation(n,a,r).bind(this));return this.allRules.set(e.name,i),mt(e)&&e.entry&&(this.mainRule=i),i}registerPrecedenceMap(e){const r=e.name,n=new Map;for(let a=0;a<e.operators.precedences.length;a++){const i=e.operators.precedences[a];for(const o of i.operators)n.set(o.value,{precedence:a,rightAssoc:i.associativity==="right"})}this.operatorPrecedence.set(r,n)}computeRuleType(e){return Jo(e)?Bn(e):e.fragment?void 0:zu(e)?bf:Bn(e)}parse(e,r={}){this.nodeBuilder.buildRootNode(e);const n=this.lexerResult=this.lexer.tokenize(e);this.wrapper.input=n.tokens;const a=r.rule?this.allRules.get(r.rule):this.mainRule;if(!a)throw new Error(r.rule?`No rule found with name '${r.rule}'`:"No main rule available.");const i=this.doParse(a);return this.nodeBuilder.addHiddenNodes(n.hidden),this.unorderedGroups.clear(),this.lexerResult=void 0,Yo(i,{deep:!0}),{value:i,lexerErrors:n.errors,lexerReport:n.report,parserErrors:this.wrapper.errors}}doParse(e){let r=this.wrapper.rule(e);if(this.stack.length>0&&(r=this.construct()),r===void 0)throw new Error("No result from parser");if(this.stack.length>0)throw new Error("Parser stack is not empty after parsing");return r}startImplementation(e,r,n){return a=>{const i=!this.isRecording()&&e!==void 0;if(i){const o={$type:e};this.stack.push(o),e===bf?o.value="":r!==void 0&&(o.$infixName=r)}return n(a),i?this.construct():void 0}}extractHiddenTokens(e){const r=this.lexerResult.hidden;if(!r.length)return[];const n=e.startOffset;for(let a=0;a<r.length;a++)if(r[a].startOffset>n)return r.splice(0,a);return r.splice(0,r.length)}consume(e,r,n){const a=this.wrapper.wrapConsume(e,r);if(!this.isRecording()&&this.isValidToken(a)){const i=this.extractHiddenTokens(a);this.nodeBuilder.addHiddenNodes(i);const o=this.nodeBuilder.buildLeafNode(a,n),{assignment:u,crossRef:l}=this.getAssignment(n),c=this.current;if(u){const f=Ir(n)?a.image:this.converter.convert(a.image,o);this.assign(u.operator,u.feature,f,o,l)}else if(Fc(c)){let f=a.image;Ir(n)||(f=this.converter.convert(f,o).toString()),c.value+=f}}}isValidToken(e){return!e.isInsertedInRecovery&&!isNaN(e.startOffset)&&typeof e.endOffset=="number"&&!isNaN(e.endOffset)}subrule(e,r,n,a,i){let o;!this.isRecording()&&!n&&(o=this.nodeBuilder.buildCompositeNode(a));let u;try{u=this.wrapper.wrapSubrule(e,r,i)}finally{this.isRecording()||(u===void 0&&!n&&(u=this.construct()),u!==void 0&&o&&o.length>0&&this.performSubruleAssignment(u,a,o))}}performSubruleAssignment(e,r,n){const{assignment:a,crossRef:i}=this.getAssignment(r);if(a)this.assign(a.operator,a.feature,e,n,i);else if(!a){const o=this.current;if(Fc(o))o.value+=e.toString();else if(typeof e=="object"&&e){const l=this.assignWithoutOverride(e,o);this.stack.pop(),this.stack.push(l)}}}action(e,r){if(!this.isRecording()){let n=this.current;if(r.feature&&r.operator){n=this.construct(),this.nodeBuilder.removeNode(n.$cstNode),this.nodeBuilder.buildCompositeNode(r).content.push(n.$cstNode);const i={$type:e};this.stack.push(i),this.assign(r.operator,r.feature,n,n.$cstNode)}else n.$type=e}}construct(){if(this.isRecording())return;const e=this.stack.pop();return this.nodeBuilder.construct(e),"$infixName"in e?this.constructInfix(e,this.operatorPrecedence.get(e.$infixName)):Fc(e)?this.converter.convert(e.value,e.$cstNode):(wh(this.astReflection,e),e)}constructInfix(e,r){const n=e.parts;if(!Array.isArray(n)||n.length===0)return;const a=e.operators;if(!Array.isArray(a)||n.length<2)return n[0];let i=0,o=-1;for(let $=0;$<a.length;$++){const C=a[$],T=r.get(C)??{precedence:1/0,rightAssoc:!1};T.precedence>o?(o=T.precedence,i=$):T.precedence===o&&(T.rightAssoc||(i=$))}const u=a.slice(0,i),l=a.slice(i+1),c=n.slice(0,i+1),f=n.slice(i+1),d={$infixName:e.$infixName,$type:e.$type,$cstNode:e.$cstNode,parts:c,operators:u},p={$infixName:e.$infixName,$type:e.$type,$cstNode:e.$cstNode,parts:f,operators:l},y=this.constructInfix(d,r),h=this.constructInfix(p,r);return{$type:e.$type,$cstNode:e.$cstNode,left:y,operator:a[i],right:h}}getAssignment(e){if(!this.assignmentMap.has(e)){const r=Hn(e,wr);this.assignmentMap.set(e,{assignment:r,crossRef:r&&Xn(r.terminal)?r.terminal.isMulti?"multi":"single":void 0})}return this.assignmentMap.get(e)}assign(e,r,n,a,i){const o=this.current;let u;switch(i==="single"&&typeof n=="string"?u=this.linker.buildReference(o,r,a,n):i==="multi"&&typeof n=="string"?u=this.linker.buildMultiReference(o,r,a,n):u=n,e){case"=":{o[r]=u;break}case"?=":{o[r]=!0;break}case"+=":Array.isArray(o[r])||(o[r]=[]),o[r].push(u)}}assignWithoutOverride(e,r){for(const[a,i]of Object.entries(r)){const o=e[a];o===void 0?e[a]=i:Array.isArray(o)&&Array.isArray(i)&&(i.push(...o),e[a]=i)}const n=e.$cstNode;return n&&(n.astNode=void 0,e.$cstNode=void 0),e}get definitionErrors(){return this.wrapper.definitionErrors}},s(ps,"LangiumParser"),ps),ms,wN=(ms=class{buildMismatchTokenMessage(e){return Ha.buildMismatchTokenMessage(e)}buildNotAllInputParsedMessage(e){return Ha.buildNotAllInputParsedMessage(e)}buildNoViableAltMessage(e){return Ha.buildNoViableAltMessage(e)}buildEarlyExitMessage(e){return Ha.buildEarlyExitMessage(e)}},s(ms,"AbstractParserErrorMessageProvider"),ms),hs,Pg=(hs=class extends wN{buildMismatchTokenMessage({expected:e,actual:r}){return`Expecting ${e.LABEL?"`"+e.LABEL+"`":e.name.endsWith(":KW")?`keyword '${e.name.substring(0,e.name.length-3)}'`:`token of type '${e.name}'`} but found \`${r.image}\`.`}buildNotAllInputParsedMessage({firstRedundant:e}){return`Expecting end of file but found \`${e.image}\`.`}},s(hs,"LangiumParserErrorMessageProvider"),hs),ys,IN=(ys=class extends Ng{constructor(){super(...arguments),this.tokens=[],this.elementStack=[],this.lastElementStack=[],this.nextTokenIndex=0,this.stackSize=0}action(){}construct(){}parse(e){this.resetState();const r=this.lexer.tokenize(e,{mode:"partial"});return this.tokens=r.tokens,this.wrapper.input=[...this.tokens],this.mainRule.call(this.wrapper,{}),this.unorderedGroups.clear(),{tokens:this.tokens,elementStack:[...this.lastElementStack],tokenIndex:this.nextTokenIndex}}rule(e,r){const n=this.wrapper.DEFINE_RULE(_N(e.name),this.startImplementation(r).bind(this));return this.allRules.set(e.name,n),e.entry&&(this.mainRule=n),n}resetState(){this.elementStack=[],this.lastElementStack=[],this.nextTokenIndex=0,this.stackSize=0}startImplementation(e){return r=>{const n=this.keepStackSize();try{e(r)}finally{this.resetStackSize(n)}}}removeUnexpectedElements(){this.elementStack.splice(this.stackSize)}keepStackSize(){const e=this.elementStack.length;return this.stackSize=e,e}resetStackSize(e){this.removeUnexpectedElements(),this.stackSize=e}consume(e,r,n){this.wrapper.wrapConsume(e,r),this.isRecording()||(this.lastElementStack=[...this.elementStack,n],this.nextTokenIndex=this.currIdx+1)}subrule(e,r,n,a,i){this.before(a),this.wrapper.wrapSubrule(e,r,i),this.after(a)}before(e){this.isRecording()||this.elementStack.push(e)}after(e){if(!this.isRecording()){const r=this.elementStack.lastIndexOf(e);r>=0&&this.elementStack.splice(r)}}get currIdx(){return this.wrapper.currIdx}},s(ys,"LangiumCompletionParser"),ys),pB={recoveryEnabled:!0,nodeLocationTracking:"full",skipValidations:!0,errorMessageProvider:new Pg},gs,NN=(gs=class extends Q1{constructor(e,r){const n=r&&"maxLookahead"in r;super(e,{...pB,lookaheadStrategy:n?new sg({maxLookahead:r.maxLookahead}):new fB({logging:r.skipValidations?()=>{}:void 0}),...r})}get IS_RECORDING(){return this.RECORDING_PHASE}DEFINE_RULE(e,r,n){return this.RULE(e,r,n)}wrapSelfAnalysis(){this.performSelfAnalysis()}wrapConsume(e,r){return this.consume(e,r,void 0)}wrapSubrule(e,r,n){return this.subrule(e,r,{ARGS:[n]})}wrapOr(e,r){this.or(e,r)}wrapOption(e,r){this.option(e,r)}wrapMany(e,r){this.many(e,r)}wrapAtLeastOne(e,r){this.atLeastOne(e,r)}rule(e){return e.call(this,{})}},s(gs,"ChevrotainWrapper"),gs),vs,mB=(vs=class extends NN{constructor(e,r,n){super(e,r),this.task=n}rule(e){this.task.start(),this.task.startSubTask(this.ruleName(e));try{return super.rule(e)}finally{this.task.stopSubTask(this.ruleName(e)),this.task.stop()}}ruleName(e){return e.ruleName}subrule(e,r,n){this.task.startSubTask(this.ruleName(r));try{return super.subrule(e,r,n)}finally{this.task.stopSubTask(this.ruleName(r))}}},s(vs,"ProfilerWrapper"),vs);function kd(t,e,r){return PN({parser:e,tokens:r,ruleNames:new Map},t),e}s(kd,"createParser");function PN(t,e){const r=qf(e,!1),n=de(e.rules).filter(mt).filter(i=>r.has(i));for(const i of n){const o={...t,consume:1,optional:1,subrule:1,many:1,or:1};t.parser.rule(i,en(o,i.definition))}const a=de(e.rules).filter(Jo).filter(i=>r.has(i));for(const i of a)t.parser.rule(i,kN(t,i))}s(PN,"buildRules");function kN(t,e){const r=e.call.rule.ref;if(!r)throw new Error("Could not resolve reference to infix operator rule: "+e.call.rule.$refText);if(jt(r))throw new Error("Cannot use terminal rule in infix expression");const n=e.operators.precedences.flatMap(y=>y.operators),a={$type:"Group",elements:[]},i={$container:a,$type:"Assignment",feature:"parts",operator:"+=",terminal:e.call},o={$container:a,$type:"Group",elements:[],cardinality:"*"};a.elements.push(i,o);const l={$container:o,$type:"Assignment",feature:"operators",operator:"+=",terminal:{$type:"Alternatives",elements:n}},c={...i,$container:o};o.elements.push(l,c);const d=n.map(y=>t.tokens[y.value]).map((y,h)=>({ALT:s(()=>t.parser.consume(h,y,l),"ALT")}));let p;return y=>{p??(p=Od(t,r)),t.parser.subrule(0,p,!1,i,y),t.parser.many(0,{DEF:s(()=>{t.parser.alternatives(0,d),t.parser.subrule(1,p,!1,c,y)},"DEF")})}}s(kN,"buildInfixRule");function en(t,e,r=!1){let n;if(Ir(e))n=FN(t,e);else if(Xr(e))n=ON(t,e);else if(wr(e))n=en(t,e.terminal);else if(Xn(e))n=kg(t,e);else if(Nr(e))n=LN(t,e);else if(Gf(e))n=xN(t,e);else if(Bf(e))n=MN(t,e);else if(Jn(e))n=GN(t,e);else if(Dh(e)){const a=t.consume++;n=s(()=>t.parser.consume(a,Zr,e),"method")}else throw new Kf(e.$cstNode,`Unexpected element type: ${e.$type}`);return Og(t,r?void 0:Lu(e),n,e.cardinality)}s(en,"buildElement");function ON(t,e){const r=Bn(e);return()=>t.parser.action(r,e)}s(ON,"buildAction");function LN(t,e){const r=e.rule.ref;if(Yn(r)){const n=t.subrule++,a=mt(r)&&r.fragment,i=e.arguments.length>0?DN(r,e.arguments):()=>({});let o;return u=>{o??(o=Od(t,r)),t.parser.subrule(n,o,a,e,i(u))}}else if(jt(r)){const n=t.consume++,a=_f(t,r.name);return()=>t.parser.consume(n,a,e)}else if(r)rn();else throw new Kf(e.$cstNode,`Undefined rule: ${e.rule.$refText}`)}s(LN,"buildRuleCall");function DN(t,e){if(e.some(n=>n.calledByName)){const n=e.map(a=>({parameterName:a.parameter?.ref?.name,predicate:Wt(a.value)}));return a=>{const i={};for(const{parameterName:o,predicate:u}of n)o&&(i[o]=u(a));return i}}else{const n=e.map(a=>Wt(a.value));return a=>{const i={};for(let o=0;o<n.length;o++)if(o<t.parameters.length){const u=t.parameters[o].name,l=n[o];i[u]=l(a)}return i}}}s(DN,"buildRuleCallPredicate");function Wt(t){if(Lh(t)){const e=Wt(t.left),r=Wt(t.right);return n=>e(n)||r(n)}else if(Oh(t)){const e=Wt(t.left),r=Wt(t.right);return n=>e(n)&&r(n)}else if(Gh(t)){const e=Wt(t.value);return r=>!e(r)}else if(Fh(t)){const e=t.parameter.ref.name;return r=>r!==void 0&&r[e]===!0}else if(Ph(t)){const e=!!t.true;return()=>e}rn()}s(Wt,"buildPredicate");function xN(t,e){if(e.elements.length===1)return en(t,e.elements[0]);{const r=[];for(const a of e.elements){const i={ALT:en(t,a,!0)},o=Lu(a);o&&(i.GATE=Wt(o)),r.push(i)}const n=t.or++;return a=>t.parser.alternatives(n,r.map(i=>{const o={ALT:s(()=>i.ALT(a),"ALT")},u=i.GATE;return u&&(o.GATE=()=>u(a)),o}))}}s(xN,"buildAlternatives");function MN(t,e){if(e.elements.length===1)return en(t,e.elements[0]);const r=[];for(const u of e.elements){const l={ALT:en(t,u,!0)},c=Lu(u);c&&(l.GATE=Wt(c)),r.push(l)}const n=t.or++,a=s((u,l)=>{const c=l.getRuleStack().join("-");return`uGroup_${u}_${c}`},"idFunc"),i=s(u=>t.parser.alternatives(n,r.map((l,c)=>{const f={ALT:s(()=>!0,"ALT")},d=t.parser;f.ALT=()=>{if(l.ALT(u),!d.isRecording()){const y=a(n,d);d.unorderedGroups.get(y)||d.unorderedGroups.set(y,[]);const h=d.unorderedGroups.get(y);typeof h?.[c]>"u"&&(h[c]=!0)}};const p=l.GATE;return p?f.GATE=()=>p(u):f.GATE=()=>!d.unorderedGroups.get(a(n,d))?.[c],f})),"alternatives"),o=Og(t,Lu(e),i,"*");return u=>{o(u),t.parser.isRecording()||t.parser.unorderedGroups.delete(a(n,t.parser))}}s(MN,"buildUnorderedGroup");function GN(t,e){const r=e.elements.map(n=>en(t,n));return n=>r.forEach(a=>a(n))}s(GN,"buildGroup");function Lu(t){if(Jn(t))return t.guardCondition}s(Lu,"getGuardCondition");function kg(t,e,r=e.terminal){if(r)if(Nr(r)&&mt(r.rule.ref)){const n=r.rule.ref,a=t.subrule++;let i;return o=>{i??(i=Od(t,n)),t.parser.subrule(a,i,!1,e,o)}}else if(Nr(r)&&jt(r.rule.ref)){const n=t.consume++,a=_f(t,r.rule.ref.name);return()=>t.parser.consume(n,a,e)}else if(Ir(r)){const n=t.consume++,a=_f(t,r.value);return()=>t.parser.consume(n,a,e)}else throw new Error("Could not build cross reference parser");else{if(!e.type.ref)throw new Error("Could not resolve reference to type: "+e.type.$refText);const a=Jf(e.type.ref)?.terminal;if(!a)throw new Error("Could not find name assignment for type: "+Bn(e.type.ref));return kg(t,e,a)}}s(kg,"buildCrossReference");function FN(t,e){const r=t.consume++,n=t.tokens[e.value];if(!n)throw new Error("Could not find token for keyword: "+e.value);return()=>t.parser.consume(r,n,e)}s(FN,"buildKeyword");function Og(t,e,r,n){const a=e&&Wt(e);if(!n)if(a){const i=t.or++;return o=>t.parser.alternatives(i,[{ALT:s(()=>r(o),"ALT"),GATE:s(()=>a(o),"GATE")},{ALT:jm(),GATE:s(()=>!a(o),"GATE")}])}else return r;if(n==="*"){const i=t.many++;return o=>t.parser.many(i,{DEF:s(()=>r(o),"DEF"),GATE:a?()=>a(o):void 0})}else if(n==="+"){const i=t.many++;if(a){const o=t.or++;return u=>t.parser.alternatives(o,[{ALT:s(()=>t.parser.atLeastOne(i,{DEF:s(()=>r(u),"DEF")}),"ALT"),GATE:s(()=>a(u),"GATE")},{ALT:jm(),GATE:s(()=>!a(u),"GATE")}])}else return o=>t.parser.atLeastOne(i,{DEF:s(()=>r(o),"DEF")})}else if(n==="?"){const i=t.optional++;return o=>t.parser.optional(i,{DEF:s(()=>r(o),"DEF"),GATE:a?()=>a(o):void 0})}else rn()}s(Og,"wrap");function Od(t,e){const r=zN(t,e),n=t.parser.getRule(r);if(!n)throw new Error(`Rule "${r}" not found."`);return n}s(Od,"getRule");function zN(t,e){if(Yn(e))return e.name;if(t.ruleNames.has(e))return t.ruleNames.get(e);{let r=e,n=r.$container,a=e.$type;for(;!mt(n);)(Jn(n)||Gf(n)||Bf(n))&&(a=n.elements.indexOf(r).toString()+":"+a),r=n,n=n.$container;return a=n.name+":"+a,t.ruleNames.set(e,a),a}}s(zN,"getRuleName");function _f(t,e){const r=t.tokens[e];if(!r)throw new Error(`Token "${e}" not found."`);return r}s(_f,"getToken");function Lg(t){const e=t.Grammar,r=t.parser.Lexer,n=new IN(t);return kd(e,n,r.definition),n.finalize(),n}s(Lg,"createCompletionParser");function Dg(t){const e=xg(t);return e.finalize(),e}s(Dg,"createLangiumParser");function xg(t){const e=t.Grammar,r=t.parser.Lexer,n=new SN(t);return kd(e,n,r.definition)}s(xg,"prepareLangiumParser");var Ts,Ld=(Ts=class{constructor(){this.diagnostics=[]}buildTokens(e,r){const n=de(qf(e,!1)),a=this.buildTerminalTokens(n),i=this.buildKeywordTokens(n,a,r);return i.push(...a),i}flushLexingReport(e){return{diagnostics:this.popDiagnostics()}}popDiagnostics(){const e=[...this.diagnostics];return this.diagnostics=[],e}buildTerminalTokens(e){return e.filter(jt).filter(r=>!r.fragment).map(r=>this.buildTerminalToken(r)).toArray()}buildTerminalToken(e){const r=Bu(e),n=this.requiresCustomPattern(r)?this.regexPatternFunction(r):r,a={name:e.name,PATTERN:n};return typeof n=="function"&&(a.LINE_BREAKS=!0),e.hidden&&(a.GROUP=Vf(r)?pt.SKIPPED:"hidden"),a}requiresCustomPattern(e){return!!(e.flags.includes("u")||e.flags.includes("s"))}regexPatternFunction(e){const r=new RegExp(e,e.flags+"y");return(n,a)=>(r.lastIndex=a,r.exec(n))}buildKeywordTokens(e,r,n){return e.filter(Yn).flatMap(a=>Mr(a).filter(Ir)).distinct(a=>a.value).toArray().sort((a,i)=>i.value.length-a.value.length).map(a=>this.buildKeywordToken(a,r,!!n?.caseInsensitive))}buildKeywordToken(e,r,n){const a=this.buildKeywordPattern(e,n),i={name:e.value,PATTERN:a,LONGER_ALT:this.findLongerAlt(e,r)};return typeof a=="function"&&(i.LINE_BREAKS=!0),i}buildKeywordPattern(e,r){return r?new RegExp(sl(e.value),"i"):e.value}findLongerAlt(e,r){return r.reduce((n,a)=>{const i=a?.PATTERN;return i?.source&&oy("^"+i.source+"$",e.value)&&n.push(a),n},[])}},s(Ts,"DefaultTokenBuilder"),Ts),$s,Mg=($s=class{convert(e,r){let n=r.grammarSource;if(Xn(n)&&(n=dy(n)),Nr(n)){const a=n.rule.ref;if(!a)throw new Error("This cst node was not parsed by a rule.");return this.runConverter(a,e,r)}return e}runConverter(e,r,n){switch(e.name.toUpperCase()){case"INT":return or.convertInt(r);case"STRING":return or.convertString(r);case"ID":return or.convertID(r)}switch(Ry(e)?.toLowerCase()){case"number":return or.convertNumber(r);case"boolean":return or.convertBoolean(r);case"bigint":return or.convertBigint(r);case"date":return or.convertDate(r);default:return r}}},s($s,"DefaultValueConverter"),$s),or;(function(t){function e(c){let f="";for(let d=1;d<c.length-1;d++){const p=c.charAt(d);if(p==="\\"){const y=c.charAt(++d);f+=r(y)}else f+=p}return f}s(e,"convertString"),t.convertString=e;function r(c){switch(c){case"b":return"\b";case"f":return"\f";case"n":return`
151
- `;case"r":return"\r";case"t":return" ";case"v":return"\v";case"0":return"\0";default:return c}}s(r,"convertEscapeCharacter");function n(c){return c.charAt(0)==="^"?c.substring(1):c}s(n,"convertID"),t.convertID=n;function a(c){return parseInt(c)}s(a,"convertInt"),t.convertInt=a;function i(c){return BigInt(c)}s(i,"convertBigint"),t.convertBigint=i;function o(c){return new Date(c)}s(o,"convertDate"),t.convertDate=o;function u(c){return Number(c)}s(u,"convertNumber"),t.convertNumber=u;function l(c){return c.toLowerCase()==="true"}s(l,"convertBoolean"),t.convertBoolean=l})(or||(or={}));var $e={};Of($e,Rh(Df()));function Dd(){return new Promise(t=>{typeof setImmediate>"u"?setTimeout(t,0):setImmediate(t)})}s(Dd,"delayNextTick");var zc=0,jN=10;function xd(){return zc=performance.now(),new $e.CancellationTokenSource}s(xd,"startCancelableOperation");function Gg(t){jN=t}s(Gg,"setInterruptionPeriod");var cr=Symbol("OperationCancelled");function da(t){return t===cr}s(da,"isOperationCancelled");async function Ye(t){if(t===$e.CancellationToken.None)return;const e=performance.now();if(e-zc>=jN&&(zc=e,await Dd(),zc=performance.now()),t.isCancellationRequested)throw cr}s(Ye,"interruptAndCheck");var Rs,Dr=(Rs=class{constructor(){this.promise=new Promise((e,r)=>{this.resolve=n=>(e(n),this),this.reject=n=>(r(n),this)})}},s(Rs,"Deferred"),Rs),Yr,ST=(Yr=class{constructor(e,r,n,a){this._uri=e,this._languageId=r,this._version=n,this._content=a,this._lineOffsets=void 0}get uri(){return this._uri}get languageId(){return this._languageId}get version(){return this._version}getText(e){if(e){const r=this.offsetAt(e.start),n=this.offsetAt(e.end);return this._content.substring(r,n)}return this._content}update(e,r){for(const n of e)if(Yr.isIncremental(n)){const a=zg(n.range),i=this.offsetAt(a.start),o=this.offsetAt(a.end);this._content=this._content.substring(0,i)+n.text+this._content.substring(o,this._content.length);const u=Math.max(a.start.line,0),l=Math.max(a.end.line,0);let c=this._lineOffsets;const f=Ym(n.text,!1,i);if(l-u===f.length)for(let p=0,y=f.length;p<y;p++)c[p+u+1]=f[p];else f.length<1e4?c.splice(u+1,l-u,...f):this._lineOffsets=c=c.slice(0,u+1).concat(f,c.slice(l+1));const d=n.text.length-(o-i);if(d!==0)for(let p=u+1+f.length,y=c.length;p<y;p++)c[p]=c[p]+d}else if(Yr.isFull(n))this._content=n.text,this._lineOffsets=void 0;else throw new Error("Unknown change event received");this._version=r}getLineOffsets(){return this._lineOffsets===void 0&&(this._lineOffsets=Ym(this._content,!0)),this._lineOffsets}positionAt(e){e=Math.max(Math.min(e,this._content.length),0);const r=this.getLineOffsets();let n=0,a=r.length;if(a===0)return{line:0,character:e};for(;n<a;){const o=Math.floor((n+a)/2);r[o]>e?a=o:n=o+1}const i=n-1;return e=this.ensureBeforeEOL(e,r[i]),{line:i,character:e-r[i]}}offsetAt(e){const r=this.getLineOffsets();if(e.line>=r.length)return this._content.length;if(e.line<0)return 0;const n=r[e.line];if(e.character<=0)return n;const a=e.line+1<r.length?r[e.line+1]:this._content.length,i=Math.min(n+e.character,a);return this.ensureBeforeEOL(i,n)}ensureBeforeEOL(e,r){for(;e>r&&Fg(this._content.charCodeAt(e-1));)e--;return e}get lineCount(){return this.getLineOffsets().length}static isIncremental(e){const r=e;return r!=null&&typeof r.text=="string"&&r.range!==void 0&&(r.rangeLength===void 0||typeof r.rangeLength=="number")}static isFull(e){const r=e;return r!=null&&typeof r.text=="string"&&r.range===void 0&&r.rangeLength===void 0}},s(Yr,"FullTextDocument"),Yr),Sf;(function(t){function e(a,i,o,u){return new ST(a,i,o,u)}s(e,"create"),t.create=e;function r(a,i,o){if(a instanceof ST)return a.update(i,o),a;throw new Error("TextDocument.update: document must be created by TextDocument.create")}s(r,"update"),t.update=r;function n(a,i){const o=a.getText(),u=wf(i.map(BN),(f,d)=>{const p=f.range.start.line-d.range.start.line;return p===0?f.range.start.character-d.range.start.character:p});let l=0;const c=[];for(const f of u){const d=a.offsetAt(f.range.start);if(d<l)throw new Error("Overlapping edit");d>l&&c.push(o.substring(l,d)),f.newText.length&&c.push(f.newText),l=a.offsetAt(f.range.end)}return c.push(o.substr(l)),c.join("")}s(n,"applyEdits"),t.applyEdits=n})(Sf||(Sf={}));function wf(t,e){if(t.length<=1)return t;const r=t.length/2|0,n=t.slice(0,r),a=t.slice(r);wf(n,e),wf(a,e);let i=0,o=0,u=0;for(;i<n.length&&o<a.length;)e(n[i],a[o])<=0?t[u++]=n[i++]:t[u++]=a[o++];for(;i<n.length;)t[u++]=n[i++];for(;o<a.length;)t[u++]=a[o++];return t}s(wf,"mergeSort");function Ym(t,e,r=0){const n=e?[r]:[];for(let a=0;a<t.length;a++){const i=t.charCodeAt(a);Fg(i)&&(i===13&&a+1<t.length&&t.charCodeAt(a+1)===10&&a++,n.push(r+a+1))}return n}s(Ym,"computeLineOffsets");function Fg(t){return t===13||t===10}s(Fg,"isEOL");function zg(t){const e=t.start,r=t.end;return e.line>r.line||e.line===r.line&&e.character>r.character?{start:r,end:e}:t}s(zg,"getWellformedRange");function BN(t){const e=zg(t.range);return e!==t.range?{newText:t.newText,range:e}:t}s(BN,"getWellformedEdit");var UN;(()=>{var t={975:k=>{function _(R){if(typeof R!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(R))}s(_,"e");function v(R,A){for(var S,L="",x=0,O=-1,z=0,M=0;M<=R.length;++M){if(M<R.length)S=R.charCodeAt(M);else{if(S===47)break;S=47}if(S===47){if(!(O===M-1||z===1))if(O!==M-1&&z===2){if(L.length<2||x!==2||L.charCodeAt(L.length-1)!==46||L.charCodeAt(L.length-2)!==46){if(L.length>2){var Y=L.lastIndexOf("/");if(Y!==L.length-1){Y===-1?(L="",x=0):x=(L=L.slice(0,Y)).length-1-L.lastIndexOf("/"),O=M,z=0;continue}}else if(L.length===2||L.length===1){L="",x=0,O=M,z=0;continue}}A&&(L.length>0?L+="/..":L="..",x=2)}else L.length>0?L+="/"+R.slice(O+1,M):L=R.slice(O+1,M),x=M-O-1;O=M,z=0}else S===46&&z!==-1?++z:z=-1}return L}s(v,"r");var I={resolve:s(function(){for(var R,A="",S=!1,L=arguments.length-1;L>=-1&&!S;L--){var x;L>=0?x=arguments[L]:(R===void 0&&(R=process.cwd()),x=R),_(x),x.length!==0&&(A=x+"/"+A,S=x.charCodeAt(0)===47)}return A=v(A,!S),S?A.length>0?"/"+A:"/":A.length>0?A:"."},"resolve"),normalize:s(function(R){if(_(R),R.length===0)return".";var A=R.charCodeAt(0)===47,S=R.charCodeAt(R.length-1)===47;return(R=v(R,!A)).length!==0||A||(R="."),R.length>0&&S&&(R+="/"),A?"/"+R:R},"normalize"),isAbsolute:s(function(R){return _(R),R.length>0&&R.charCodeAt(0)===47},"isAbsolute"),join:s(function(){if(arguments.length===0)return".";for(var R,A=0;A<arguments.length;++A){var S=arguments[A];_(S),S.length>0&&(R===void 0?R=S:R+="/"+S)}return R===void 0?".":I.normalize(R)},"join"),relative:s(function(R,A){if(_(R),_(A),R===A||(R=I.resolve(R))===(A=I.resolve(A)))return"";for(var S=1;S<R.length&&R.charCodeAt(S)===47;++S);for(var L=R.length,x=L-S,O=1;O<A.length&&A.charCodeAt(O)===47;++O);for(var z=A.length-O,M=x<z?x:z,Y=-1,q=0;q<=M;++q){if(q===M){if(z>M){if(A.charCodeAt(O+q)===47)return A.slice(O+q+1);if(q===0)return A.slice(O+q)}else x>M&&(R.charCodeAt(S+q)===47?Y=q:q===0&&(Y=0));break}var Z=R.charCodeAt(S+q);if(Z!==A.charCodeAt(O+q))break;Z===47&&(Y=q)}var ae="";for(q=S+Y+1;q<=L;++q)q!==L&&R.charCodeAt(q)!==47||(ae.length===0?ae+="..":ae+="/..");return ae.length>0?ae+A.slice(O+Y):(O+=Y,A.charCodeAt(O)===47&&++O,A.slice(O))},"relative"),_makeLong:s(function(R){return R},"_makeLong"),dirname:s(function(R){if(_(R),R.length===0)return".";for(var A=R.charCodeAt(0),S=A===47,L=-1,x=!0,O=R.length-1;O>=1;--O)if((A=R.charCodeAt(O))===47){if(!x){L=O;break}}else x=!1;return L===-1?S?"/":".":S&&L===1?"//":R.slice(0,L)},"dirname"),basename:s(function(R,A){if(A!==void 0&&typeof A!="string")throw new TypeError('"ext" argument must be a string');_(R);var S,L=0,x=-1,O=!0;if(A!==void 0&&A.length>0&&A.length<=R.length){if(A.length===R.length&&A===R)return"";var z=A.length-1,M=-1;for(S=R.length-1;S>=0;--S){var Y=R.charCodeAt(S);if(Y===47){if(!O){L=S+1;break}}else M===-1&&(O=!1,M=S+1),z>=0&&(Y===A.charCodeAt(z)?--z==-1&&(x=S):(z=-1,x=M))}return L===x?x=M:x===-1&&(x=R.length),R.slice(L,x)}for(S=R.length-1;S>=0;--S)if(R.charCodeAt(S)===47){if(!O){L=S+1;break}}else x===-1&&(O=!1,x=S+1);return x===-1?"":R.slice(L,x)},"basename"),extname:s(function(R){_(R);for(var A=-1,S=0,L=-1,x=!0,O=0,z=R.length-1;z>=0;--z){var M=R.charCodeAt(z);if(M!==47)L===-1&&(x=!1,L=z+1),M===46?A===-1?A=z:O!==1&&(O=1):A!==-1&&(O=-1);else if(!x){S=z+1;break}}return A===-1||L===-1||O===0||O===1&&A===L-1&&A===S+1?"":R.slice(A,L)},"extname"),format:s(function(R){if(R===null||typeof R!="object")throw new TypeError('The "pathObject" argument must be of type Object. Received type '+typeof R);return function(A,S){var L=S.dir||S.root,x=S.base||(S.name||"")+(S.ext||"");return L?L===S.root?L+x:L+"/"+x:x}(0,R)},"format"),parse:s(function(R){_(R);var A={root:"",dir:"",base:"",ext:"",name:""};if(R.length===0)return A;var S,L=R.charCodeAt(0),x=L===47;x?(A.root="/",S=1):S=0;for(var O=-1,z=0,M=-1,Y=!0,q=R.length-1,Z=0;q>=S;--q)if((L=R.charCodeAt(q))!==47)M===-1&&(Y=!1,M=q+1),L===46?O===-1?O=q:Z!==1&&(Z=1):O!==-1&&(Z=-1);else if(!Y){z=q+1;break}return O===-1||M===-1||Z===0||Z===1&&O===M-1&&O===z+1?M!==-1&&(A.base=A.name=z===0&&x?R.slice(1,M):R.slice(z,M)):(z===0&&x?(A.name=R.slice(1,O),A.base=R.slice(1,M)):(A.name=R.slice(z,O),A.base=R.slice(z,M)),A.ext=R.slice(O,M)),z>0?A.dir=R.slice(0,z-1):x&&(A.dir="/"),A},"parse"),sep:"/",delimiter:":",win32:null,posix:null};I.posix=I,k.exports=I}},e={};function r(k){var _=e[k];if(_!==void 0)return _.exports;var v=e[k]={exports:{}};return t[k](v,v.exports,r),v.exports}s(r,"r"),r.d=(k,_)=>{for(var v in _)r.o(_,v)&&!r.o(k,v)&&Object.defineProperty(k,v,{enumerable:!0,get:_[v]})},r.o=(k,_)=>Object.prototype.hasOwnProperty.call(k,_),r.r=k=>{typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(k,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(k,"__esModule",{value:!0})};var n={};let a;r.r(n),r.d(n,{URI:s(()=>p,"URI"),Utils:s(()=>ye,"Utils")}),typeof process=="object"?a=process.platform==="win32":typeof navigator=="object"&&(a=navigator.userAgent.indexOf("Windows")>=0);const i=/^\w[\w\d+.-]*$/,o=/^\//,u=/^\/\//;function l(k,_){if(!k.scheme&&_)throw new Error(`[UriError]: Scheme is missing: {scheme: "", authority: "${k.authority}", path: "${k.path}", query: "${k.query}", fragment: "${k.fragment}"}`);if(k.scheme&&!i.test(k.scheme))throw new Error("[UriError]: Scheme contains illegal characters.");if(k.path){if(k.authority){if(!o.test(k.path))throw new Error('[UriError]: If a URI contains an authority component, then the path component must either be empty or begin with a slash ("/") character')}else if(u.test(k.path))throw new Error('[UriError]: If a URI does not contain an authority component, then the path cannot begin with two slash characters ("//")')}}s(l,"a");const c="",f="/",d=/^(([^:/?#]+?):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?/,ue=class ue{constructor(_,v,I,R,A,S=!1){Br(this,"scheme");Br(this,"authority");Br(this,"path");Br(this,"query");Br(this,"fragment");typeof _=="object"?(this.scheme=_.scheme||c,this.authority=_.authority||c,this.path=_.path||c,this.query=_.query||c,this.fragment=_.fragment||c):(this.scheme=function(L,x){return L||x?L:"file"}(_,S),this.authority=v||c,this.path=function(L,x){switch(L){case"https":case"http":case"file":x?x[0]!==f&&(x=f+x):x=f}return x}(this.scheme,I||c),this.query=R||c,this.fragment=A||c,l(this,S))}static isUri(_){return _ instanceof ue||!!_&&typeof _.authority=="string"&&typeof _.fragment=="string"&&typeof _.path=="string"&&typeof _.query=="string"&&typeof _.scheme=="string"&&typeof _.fsPath=="string"&&typeof _.with=="function"&&typeof _.toString=="function"}get fsPath(){return w(this,!1)}with(_){if(!_)return this;let{scheme:v,authority:I,path:R,query:A,fragment:S}=_;return v===void 0?v=this.scheme:v===null&&(v=c),I===void 0?I=this.authority:I===null&&(I=c),R===void 0?R=this.path:R===null&&(R=c),A===void 0?A=this.query:A===null&&(A=c),S===void 0?S=this.fragment:S===null&&(S=c),v===this.scheme&&I===this.authority&&R===this.path&&A===this.query&&S===this.fragment?this:new h(v,I,R,A,S)}static parse(_,v=!1){const I=d.exec(_);return I?new h(I[2]||c,ne(I[4]||c),ne(I[5]||c),ne(I[7]||c),ne(I[9]||c),v):new h(c,c,c,c,c)}static file(_){let v=c;if(a&&(_=_.replace(/\\/g,f)),_[0]===f&&_[1]===f){const I=_.indexOf(f,2);I===-1?(v=_.substring(2),_=f):(v=_.substring(2,I),_=_.substring(I)||f)}return new h("file",v,_,c,c)}static from(_){const v=new h(_.scheme,_.authority,_.path,_.query,_.fragment);return l(v,!0),v}toString(_=!1){return b(this,_)}toJSON(){return this}static revive(_){if(_){if(_ instanceof ue)return _;{const v=new h(_);return v._formatted=_.external,v._fsPath=_._sep===y?_.fsPath:null,v}}return _}};s(ue,"l");let p=ue;const y=a?1:void 0,ot=class ot extends p{constructor(){super(...arguments);Br(this,"_formatted",null);Br(this,"_fsPath",null)}get fsPath(){return this._fsPath||(this._fsPath=w(this,!1)),this._fsPath}toString(v=!1){return v?b(this,!0):(this._formatted||(this._formatted=b(this,!1)),this._formatted)}toJSON(){const v={$mid:1};return this._fsPath&&(v.fsPath=this._fsPath,v._sep=y),this._formatted&&(v.external=this._formatted),this.path&&(v.path=this.path),this.scheme&&(v.scheme=this.scheme),this.authority&&(v.authority=this.authority),this.query&&(v.query=this.query),this.fragment&&(v.fragment=this.fragment),v}};s(ot,"d");let h=ot;const $={58:"%3A",47:"%2F",63:"%3F",35:"%23",91:"%5B",93:"%5D",64:"%40",33:"%21",36:"%24",38:"%26",39:"%27",40:"%28",41:"%29",42:"%2A",43:"%2B",44:"%2C",59:"%3B",61:"%3D",32:"%20"};function C(k,_,v){let I,R=-1;for(let A=0;A<k.length;A++){const S=k.charCodeAt(A);if(S>=97&&S<=122||S>=65&&S<=90||S>=48&&S<=57||S===45||S===46||S===95||S===126||_&&S===47||v&&S===91||v&&S===93||v&&S===58)R!==-1&&(I+=encodeURIComponent(k.substring(R,A)),R=-1),I!==void 0&&(I+=k.charAt(A));else{I===void 0&&(I=k.substr(0,A));const L=$[S];L!==void 0?(R!==-1&&(I+=encodeURIComponent(k.substring(R,A)),R=-1),I+=L):R===-1&&(R=A)}}return R!==-1&&(I+=encodeURIComponent(k.substring(R))),I!==void 0?I:k}s(C,"m");function T(k){let _;for(let v=0;v<k.length;v++){const I=k.charCodeAt(v);I===35||I===63?(_===void 0&&(_=k.substr(0,v)),_+=$[I]):_!==void 0&&(_+=k[v])}return _!==void 0?_:k}s(T,"y");function w(k,_){let v;return v=k.authority&&k.path.length>1&&k.scheme==="file"?`//${k.authority}${k.path}`:k.path.charCodeAt(0)===47&&(k.path.charCodeAt(1)>=65&&k.path.charCodeAt(1)<=90||k.path.charCodeAt(1)>=97&&k.path.charCodeAt(1)<=122)&&k.path.charCodeAt(2)===58?_?k.path.substr(1):k.path[1].toLowerCase()+k.path.substr(2):k.path,a&&(v=v.replace(/\//g,"\\")),v}s(w,"v");function b(k,_){const v=_?T:C;let I="",{scheme:R,authority:A,path:S,query:L,fragment:x}=k;if(R&&(I+=R,I+=":"),(A||R==="file")&&(I+=f,I+=f),A){let O=A.indexOf("@");if(O!==-1){const z=A.substr(0,O);A=A.substr(O+1),O=z.lastIndexOf(":"),O===-1?I+=v(z,!1,!1):(I+=v(z.substr(0,O),!1,!1),I+=":",I+=v(z.substr(O+1),!1,!0)),I+="@"}A=A.toLowerCase(),O=A.lastIndexOf(":"),O===-1?I+=v(A,!1,!0):(I+=v(A.substr(0,O),!1,!0),I+=A.substr(O))}if(S){if(S.length>=3&&S.charCodeAt(0)===47&&S.charCodeAt(2)===58){const O=S.charCodeAt(1);O>=65&&O<=90&&(S=`/${String.fromCharCode(O+32)}:${S.substr(3)}`)}else if(S.length>=2&&S.charCodeAt(1)===58){const O=S.charCodeAt(0);O>=65&&O<=90&&(S=`${String.fromCharCode(O+32)}:${S.substr(2)}`)}I+=v(S,!0,!1)}return L&&(I+="?",I+=v(L,!1,!1)),x&&(I+="#",I+=_?x:C(x,!1,!1)),I}s(b,"b");function N(k){try{return decodeURIComponent(k)}catch{return k.length>3?k.substr(0,3)+N(k.substr(3)):k}}s(N,"C");const B=/(%[0-9A-Za-z][0-9A-Za-z])+/g;function ne(k){return k.match(B)?k.replace(B,_=>N(_)):k}s(ne,"w");var J=r(975);const he=J.posix||J,Ae="/";var ye;(function(k){k.joinPath=function(_,...v){return _.with({path:he.join(_.path,...v)})},k.resolvePath=function(_,...v){let I=_.path,R=!1;I[0]!==Ae&&(I=Ae+I,R=!0);let A=he.resolve(I,...v);return R&&A[0]===Ae&&!_.authority&&(A=A.substring(1)),_.with({path:A})},k.dirname=function(_){if(_.path.length===0||_.path===Ae)return _;let v=he.dirname(_.path);return v.length===1&&v.charCodeAt(0)===46&&(v=""),_.with({path:v})},k.basename=function(_){return he.basename(_.path)},k.extname=function(_){return he.extname(_.path)}})(ye||(ye={})),UN=n})();var{URI:It,Utils:Dl}=UN,dt;(function(t){t.basename=Dl.basename,t.dirname=Dl.dirname,t.extname=Dl.extname,t.joinPath=Dl.joinPath,t.resolvePath=Dl.resolvePath;const e=typeof process=="object"&&process?.platform==="win32";function r(o,u){return o?.toString()===u?.toString()}s(r,"equals"),t.equals=r;function n(o,u){const l=typeof o=="string"?It.parse(o).path:o.path,c=typeof u=="string"?It.parse(u).path:u.path,f=l.split("/").filter($=>$.length>0),d=c.split("/").filter($=>$.length>0);if(e){const $=/^[A-Z]:$/;if(f[0]&&$.test(f[0])&&(f[0]=f[0].toLowerCase()),d[0]&&$.test(d[0])&&(d[0]=d[0].toLowerCase()),f[0]!==d[0])return c.substring(1)}let p=0;for(;p<f.length&&f[p]===d[p];p++);const y="../".repeat(f.length-p),h=d.slice(p).join("/");return y+h}s(n,"relative"),t.relative=n;function a(o){return It.parse(o.toString()).toString()}s(a,"normalize"),t.normalize=a;function i(o,u){let l=typeof o=="string"?o:o.path,c=typeof u=="string"?u:u.path;return c.charAt(c.length-1)==="/"&&(c=c.slice(0,-1)),l.charAt(l.length-1)==="/"&&(l=l.slice(0,-1)),c===l?!0:c.length<l.length||c.charAt(l.length)!=="/"?!1:c.startsWith(l)}s(i,"contains"),t.contains=i})(dt||(dt={}));var As,jg=(As=class{constructor(){this.root={name:"",children:new Map}}normalizeUri(e){return dt.normalize(e)}clear(){this.root.children.clear()}insert(e,r){const n=this.getNode(this.normalizeUri(e),!0);n.element=r}delete(e){const r=this.getNode(this.normalizeUri(e),!1);r?.parent&&r.parent.children.delete(r.name)}has(e){return this.getNode(this.normalizeUri(e),!1)?.element!==void 0}hasNode(e){return this.getNode(this.normalizeUri(e),!1)!==void 0}find(e){return this.getNode(this.normalizeUri(e),!1)?.element}findNode(e){const r=this.normalizeUri(e),n=this.getNode(r,!1);if(n)return{name:n.name,uri:dt.joinPath(It.parse(r),n.name).toString(),element:n.element}}findChildren(e){const r=this.normalizeUri(e),n=this.getNode(r,!1);return n?Array.from(n.children.values()).map(a=>({name:a.name,uri:dt.joinPath(It.parse(r),a.name).toString(),element:a.element})):[]}all(){return this.collectValues(this.root)}findAll(e){const r=this.getNode(dt.normalize(e),!1);return r?this.collectValues(r):[]}getNode(e,r){const n=e.split("/");e.charAt(e.length-1)==="/"&&n.pop();let a=this.root;for(const i of n){let o=a.children.get(i);if(!o)if(r)o={name:i,children:new Map,parent:a},a.children.set(i,o);else return;a=o}return a}collectValues(e){const r=[];e.element&&r.push(e.element);for(const n of e.children.values())r.push(...this.collectValues(n));return r}},s(As,"UriTrie"),As),Q;(function(t){t[t.Changed=0]="Changed",t[t.Parsed=1]="Parsed",t[t.IndexedContent=2]="IndexedContent",t[t.ComputedScopes=3]="ComputedScopes",t[t.Linked=4]="Linked",t[t.IndexedReferences=5]="IndexedReferences",t[t.Validated=6]="Validated"})(Q||(Q={}));var Es,KN=(Es=class{constructor(e){this.serviceRegistry=e.ServiceRegistry,this.textDocuments=e.workspace.TextDocuments,this.fileSystemProvider=e.workspace.FileSystemProvider}async fromUri(e,r=$e.CancellationToken.None){const n=await this.fileSystemProvider.readFile(e);return this.createAsync(e,n,r)}fromTextDocument(e,r,n){return r=r??It.parse(e.uri),$e.CancellationToken.is(n)?this.createAsync(r,e,n):this.create(r,e,n)}fromString(e,r,n){return $e.CancellationToken.is(n)?this.createAsync(r,e,n):this.create(r,e,n)}fromModel(e,r){return this.create(r,{$model:e})}create(e,r,n){if(typeof r=="string"){const a=this.parse(e,r,n);return this.createLangiumDocument(a,e,void 0,r)}else if("$model"in r){const a={value:r.$model,parserErrors:[],lexerErrors:[]};return this.createLangiumDocument(a,e)}else{const a=this.parse(e,r.getText(),n);return this.createLangiumDocument(a,e,r)}}async createAsync(e,r,n){if(typeof r=="string"){const a=await this.parseAsync(e,r,n);return this.createLangiumDocument(a,e,void 0,r)}else{const a=await this.parseAsync(e,r.getText(),n);return this.createLangiumDocument(a,e,r)}}createLangiumDocument(e,r,n,a){let i;if(n)i={parseResult:e,uri:r,state:Q.Parsed,references:[],textDocument:n};else{const o=this.createTextDocumentGetter(r,a);i={parseResult:e,uri:r,state:Q.Parsed,references:[],get textDocument(){return o()}}}return e.value.$document=i,i}async update(e,r){const n=e.parseResult.value.$cstNode?.root.fullText,a=this.textDocuments?.get(e.uri.toString()),i=a?a.getText():await this.fileSystemProvider.readFile(e.uri);if(a)Object.defineProperty(e,"textDocument",{value:a});else{const o=this.createTextDocumentGetter(e.uri,i);Object.defineProperty(e,"textDocument",{get:o})}return n!==i&&(e.parseResult=await this.parseAsync(e.uri,i,r),e.parseResult.value.$document=e),e.state=Q.Parsed,e}parse(e,r,n){return this.serviceRegistry.getServices(e).parser.LangiumParser.parse(r,n)}parseAsync(e,r,n){return this.serviceRegistry.getServices(e).parser.AsyncParser.parse(r,n)}createTextDocumentGetter(e,r){const n=this.serviceRegistry;let a;return()=>a??(a=Sf.create(e.toString(),n.getServices(e).LanguageMetaData.languageId,0,r??""))}},s(Es,"DefaultLangiumDocumentFactory"),Es),Cs,WN=(Cs=class{constructor(e){this.documentTrie=new jg,this.services=e,this.langiumDocumentFactory=e.workspace.LangiumDocumentFactory,this.documentBuilder=()=>e.workspace.DocumentBuilder}get all(){return de(this.documentTrie.all())}addDocument(e){const r=e.uri.toString();if(this.documentTrie.has(r))throw new Error(`A document with the URI '${r}' is already present.`);this.documentTrie.insert(r,e)}getDocument(e){const r=e.toString();return this.documentTrie.find(r)}getDocuments(e){const r=e.toString();return this.documentTrie.findAll(r)}async getOrCreateDocument(e,r){let n=this.getDocument(e);return n||(n=await this.langiumDocumentFactory.fromUri(e,r),this.addDocument(n),n)}createDocument(e,r,n){if(n)return this.langiumDocumentFactory.fromString(r,e,n).then(a=>(this.addDocument(a),a));{const a=this.langiumDocumentFactory.fromString(r,e);return this.addDocument(a),a}}hasDocument(e){return this.documentTrie.has(e.toString())}invalidateDocument(e){const r=e.toString(),n=this.documentTrie.find(r);return n&&this.documentBuilder().resetToState(n,Q.Changed),n}deleteDocument(e){const r=e.toString(),n=this.documentTrie.find(r);return n&&(n.state=Q.Changed,this.documentTrie.delete(r)),n}deleteDocuments(e){const r=e.toString(),n=this.documentTrie.findAll(r);for(const a of n)a.state=Q.Changed;return this.documentTrie.delete(r),n}},s(Cs,"DefaultLangiumDocuments"),Cs),vn=Symbol("RefResolving"),bs,VN=(bs=class{constructor(e){this.reflection=e.shared.AstReflection,this.langiumDocuments=()=>e.shared.workspace.LangiumDocuments,this.scopeProvider=e.references.ScopeProvider,this.astNodeLocator=e.workspace.AstNodeLocator,this.profiler=e.shared.profilers.LangiumProfiler,this.languageId=e.LanguageMetaData.languageId}async link(e,r=$e.CancellationToken.None){if(this.profiler?.isActive("linking")){const n=this.profiler.createTask("linking",this.languageId);n.start();try{for(const a of qt(e.parseResult.value))await Ye(r),Xo(a).forEach(i=>{const o=`${a.$type}:${i.property}`;n.startSubTask(o);try{this.doLink(i,e)}finally{n.stopSubTask(o)}})}finally{n.stop()}}else for(const n of qt(e.parseResult.value))await Ye(r),Xo(n).forEach(a=>this.doLink(a,e))}doLink(e,r){const n=e.reference;if("_ref"in n&&n._ref===void 0){n._ref=vn;try{const a=this.getCandidate(e);if(An(a))n._ref=a;else{n._nodeDescription=a;const i=this.loadAstNode(a);n._ref=i??this.createLinkingError(e,a)}}catch(a){console.error(`An error occurred while resolving reference to '${n.$refText}':`,a);const i=a.message??String(a);n._ref={info:e,message:`An error occurred while resolving reference to '${n.$refText}': ${i}`}}r.references.push(n)}else if("_items"in n&&n._items===void 0){n._items=vn;try{const a=this.getCandidates(e),i=[];if(An(a))n._linkingError=a;else for(const o of a){const u=this.loadAstNode(o);u&&i.push({ref:u,$nodeDescription:o})}n._items=i}catch(a){n._linkingError={info:e,message:`An error occurred while resolving reference to '${n.$refText}': ${a}`},n._items=[]}r.references.push(n)}}unlink(e){for(const r of e.references)"_ref"in r?(r._ref=void 0,delete r._nodeDescription):"_items"in r&&(r._items=void 0,delete r._linkingError);e.references=[]}getCandidate(e){return this.scopeProvider.getScope(e).getElement(e.reference.$refText)??this.createLinkingError(e)}getCandidates(e){const n=this.scopeProvider.getScope(e).getElements(e.reference.$refText).distinct(a=>`${a.documentUri}#${a.path}`).toArray();return n.length>0?n:this.createLinkingError(e)}buildReference(e,r,n,a){const i=this,o={$refNode:n,$refText:a,_ref:void 0,get ref(){if(Be(this._ref))return this._ref;if(bh(this._nodeDescription)){const u=i.loadAstNode(this._nodeDescription);this._ref=u??i.createLinkingError({reference:o,container:e,property:r},this._nodeDescription)}else if(this._ref===void 0){this._ref=vn;const u=Ya(e).$document,l=i.getLinkedNode({reference:o,container:e,property:r});if(l.error&&u&&u.state<Q.ComputedScopes)return this._ref=void 0;this._ref=l.node??l.error,this._nodeDescription=l.descr,u?.references.push(this)}else this._ref===vn&&i.throwCyclicReferenceError(e,r,a);return Be(this._ref)?this._ref:void 0},get $nodeDescription(){return this._nodeDescription},get error(){return An(this._ref)?this._ref:void 0}};return o}buildMultiReference(e,r,n,a){const i=this,o={$refNode:n,$refText:a,_items:void 0,get items(){if(Array.isArray(this._items))return this._items;if(this._items===void 0){this._items=vn;const u=Ya(e).$document,l=i.getCandidates({reference:o,container:e,property:r}),c=[];if(An(l))this._linkingError=l;else for(const f of l){const d=i.loadAstNode(f);d&&c.push({ref:d,$nodeDescription:f})}this._items=c,u?.references.push(this)}else this._items===vn&&i.throwCyclicReferenceError(e,r,a);return Array.isArray(this._items)?this._items:[]},get error(){if(this._linkingError)return this._linkingError;if(!(this.items.length>0))return this._linkingError=i.createLinkingError({reference:o,container:e,property:r})}};return o}throwCyclicReferenceError(e,r,n){throw new Error(`Cyclic reference resolution detected: ${this.astNodeLocator.getAstNodePath(e)}/${r} (symbol '${n}')`)}getLinkedNode(e){try{const r=this.getCandidate(e);if(An(r))return{error:r};const n=this.loadAstNode(r);return n?{node:n,descr:r}:{descr:r,error:this.createLinkingError(e,r)}}catch(r){console.error(`An error occurred while resolving reference to '${e.reference.$refText}':`,r);const n=r.message??String(r);return{error:{info:e,message:`An error occurred while resolving reference to '${e.reference.$refText}': ${n}`}}}}loadAstNode(e){if(e.node)return e.node;const r=this.langiumDocuments().getDocument(e.documentUri);if(r)return this.astNodeLocator.getAstNode(r.parseResult.value,e.path)}createLinkingError(e,r){const n=Ya(e.container).$document;n&&n.state<Q.ComputedScopes&&console.warn(`Attempted reference resolution before document reached ComputedScopes state (${n.uri}).`);const a=this.reflection.getReferenceType(e);return{info:e,message:`Could not resolve reference to ${a} named '${e.reference.$refText}'.`,targetDescription:r}}},s(bs,"DefaultLinker"),bs);function Bg(t){return typeof t.name=="string"}s(Bg,"isNamed");var _s,qN=(_s=class{getName(e){if(Bg(e))return e.name}getNameNode(e){return Hf(e.$cstNode,"name")}},s(_s,"DefaultNameProvider"),_s),Ss,HN=(Ss=class{constructor(e){this.nameProvider=e.references.NameProvider,this.index=e.shared.workspace.IndexManager,this.nodeLocator=e.workspace.AstNodeLocator,this.documents=e.shared.workspace.LangiumDocuments,this.hasMultiReference=qt(e.Grammar).some(r=>Xn(r)&&r.isMulti)}findDeclarations(e){if(e){const r=yy(e),n=e.astNode;if(r&&n){const a=n[r.feature];if(ft(a)||fr(a))return Wc(a);if(Array.isArray(a)){for(const i of a)if((ft(i)||fr(i))&&i.$refNode&&i.$refNode.offset<=e.offset&&i.$refNode.end>=e.end)return Wc(i)}}if(n){const a=this.nameProvider.getNameNode(n);if(a&&(a===e||Yh(e,a)))return this.getSelfNodes(n)}}return[]}getSelfNodes(e){if(this.hasMultiReference){const r=this.index.findAllReferences(e,this.nodeLocator.getAstNodePath(e)),n=this.getNodeFromReferenceDescription(r.head());if(n){for(const a of Xo(n))if(fr(a.reference)&&a.reference.items.some(i=>i.ref===e))return a.reference.items.map(i=>i.ref)}return[e]}else return[e]}getNodeFromReferenceDescription(e){if(!e)return;const r=this.documents.getDocument(e.sourceUri);if(r)return this.nodeLocator.getAstNode(r.parseResult.value,e.sourcePath)}findDeclarationNodes(e){const r=this.findDeclarations(e),n=[];for(const a of r){const i=this.nameProvider.getNameNode(a)??a.$cstNode;i&&n.push(i)}return n}findReferences(e,r){const n=[];r.includeDeclaration&&n.push(...this.getSelfReferences(e));let a=this.index.findAllReferences(e,this.nodeLocator.getAstNodePath(e));return r.documentUri&&(a=a.filter(i=>dt.equals(i.sourceUri,r.documentUri))),n.push(...a),de(n)}getSelfReferences(e){const r=this.getSelfNodes(e),n=[];for(const a of r){const i=this.nameProvider.getNameNode(a);if(i){const o=Vt(a),u=this.nodeLocator.getAstNodePath(a);n.push({sourceUri:o.uri,sourcePath:u,targetUri:o.uri,targetPath:u,segment:Qo(i),local:!0})}}return n}},s(Ss,"DefaultReferences"),Ss),ws,xr=(ws=class{constructor(e){if(this.map=new Map,e)for(const[r,n]of e)this.add(r,n)}get size(){return Tu.sum(de(this.map.values()).map(e=>e.length))}clear(){this.map.clear()}delete(e,r){if(r===void 0)return this.map.delete(e);{const n=this.map.get(e);if(n){const a=n.indexOf(r);if(a>=0)return n.length===1?this.map.delete(e):n.splice(a,1),!0}return!1}}get(e){return this.map.get(e)??[]}getStream(e){const r=this.map.get(e);return r?de(r):qo}has(e,r){if(r===void 0)return this.map.has(e);{const n=this.map.get(e);return n?n.indexOf(r)>=0:!1}}add(e,r){return this.map.has(e)?this.map.get(e).push(r):this.map.set(e,[r]),this}addAll(e,r){return this.map.has(e)?this.map.get(e).push(...r):this.map.set(e,Array.from(r)),this}forEach(e){this.map.forEach((r,n)=>r.forEach(a=>e(a,n,this)))}[Symbol.iterator](){return this.entries().iterator()}entries(){return de(this.map.entries()).flatMap(([e,r])=>r.map(n=>[e,n]))}keys(){return de(this.map.keys())}values(){return de(this.map.values()).flat()}entriesGroupedByKey(){return de(this.map.entries())}},s(ws,"MultiMap"),ws),Is,If=(Is=class{get size(){return this.map.size}constructor(e){if(this.map=new Map,this.inverse=new Map,e)for(const[r,n]of e)this.set(r,n)}clear(){this.map.clear(),this.inverse.clear()}set(e,r){return this.map.set(e,r),this.inverse.set(r,e),this}get(e){return this.map.get(e)}getKey(e){return this.inverse.get(e)}delete(e){const r=this.map.get(e);return r!==void 0?(this.map.delete(e),this.inverse.delete(r),!0):!1}},s(Is,"BiMap"),Is),Ns,YN=(Ns=class{constructor(e){this.nameProvider=e.references.NameProvider,this.descriptions=e.workspace.AstNodeDescriptionProvider}async collectExportedSymbols(e,r=$e.CancellationToken.None){return this.collectExportedSymbolsForNode(e.parseResult.value,e,void 0,r)}async collectExportedSymbolsForNode(e,r,n=Gu,a=$e.CancellationToken.None){const i=[];this.addExportedSymbol(e,i,r);for(const o of n(e))await Ye(a),this.addExportedSymbol(o,i,r);return i}addExportedSymbol(e,r,n){const a=this.nameProvider.getName(e);a&&r.push(this.descriptions.createDescription(e,a,n))}async collectLocalSymbols(e,r=$e.CancellationToken.None){const n=e.parseResult.value,a=new xr;for(const i of Mr(n))await Ye(r),this.addLocalSymbol(i,e,a);return a}addLocalSymbol(e,r,n){const a=e.$container;if(a){const i=this.nameProvider.getName(e);i&&n.add(a,this.descriptions.createDescription(e,i,r))}}},s(Ns,"DefaultScopeComputation"),Ns),Ps,Xm=(Ps=class{constructor(e,r,n){this.elements=e,this.outerScope=r,this.caseInsensitive=n?.caseInsensitive??!1,this.concatOuterScope=n?.concatOuterScope??!0}getAllElements(){return this.outerScope?this.elements.concat(this.outerScope.getAllElements()):this.elements}getElement(e){const r=this.caseInsensitive?e.toLowerCase():e,n=this.caseInsensitive?this.elements.find(a=>a.name.toLowerCase()===r):this.elements.find(a=>a.name===e);if(n)return n;if(this.outerScope)return this.outerScope.getElement(e)}getElements(e){const r=this.caseInsensitive?e.toLowerCase():e,n=this.caseInsensitive?this.elements.filter(a=>a.name.toLowerCase()===r):this.elements.filter(a=>a.name===e);return(this.concatOuterScope||n.isEmpty())&&this.outerScope?n.concat(this.outerScope.getElements(e)):n}},s(Ps,"StreamScope"),Ps),ks,hB=(ks=class{constructor(e,r,n){this.elements=new Map,this.caseInsensitive=n?.caseInsensitive??!1,this.concatOuterScope=n?.concatOuterScope??!0;for(const a of e){const i=this.caseInsensitive?a.name.toLowerCase():a.name;this.elements.set(i,a)}this.outerScope=r}getElement(e){const r=this.caseInsensitive?e.toLowerCase():e,n=this.elements.get(r);if(n)return n;if(this.outerScope)return this.outerScope.getElement(e)}getElements(e){const r=this.caseInsensitive?e.toLowerCase():e,n=this.elements.get(r),a=n?[n]:[];return(this.concatOuterScope||a.length>0)&&this.outerScope?de(a).concat(this.outerScope.getElements(e)):de(a)}getAllElements(){let e=de(this.elements.values());return this.outerScope&&(e=e.concat(this.outerScope.getAllElements())),e}},s(ks,"MapScope"),ks),Os,XN=(Os=class{constructor(e,r,n){this.elements=new xr,this.caseInsensitive=n?.caseInsensitive??!1,this.concatOuterScope=n?.concatOuterScope??!0;for(const a of e){const i=this.caseInsensitive?a.name.toLowerCase():a.name;this.elements.add(i,a)}this.outerScope=r}getElement(e){const r=this.caseInsensitive?e.toLowerCase():e,n=this.elements.get(r)[0];if(n)return n;if(this.outerScope)return this.outerScope.getElement(e)}getElements(e){const r=this.caseInsensitive?e.toLowerCase():e,n=this.elements.get(r);return(this.concatOuterScope||n.length===0)&&this.outerScope?de(n).concat(this.outerScope.getElements(e)):de(n)}getAllElements(){let e=de(this.elements.values());return this.outerScope&&(e=e.concat(this.outerScope.getAllElements())),e}},s(Os,"MultiMapScope"),Os),yB={getElement(){},getElements(){return qo},getAllElements(){return qo}},Ls,Md=(Ls=class{constructor(){this.toDispose=[],this.isDisposed=!1}onDispose(e){this.toDispose.push(e)}dispose(){this.throwIfDisposed(),this.clear(),this.isDisposed=!0,this.toDispose.forEach(e=>e.dispose())}throwIfDisposed(){if(this.isDisposed)throw new Error("This cache has already been disposed")}},s(Ls,"DisposableCache"),Ls),Ds,Ug=(Ds=class extends Md{constructor(){super(...arguments),this.cache=new Map}has(e){return this.throwIfDisposed(),this.cache.has(e)}set(e,r){this.throwIfDisposed(),this.cache.set(e,r)}get(e,r){if(this.throwIfDisposed(),this.cache.has(e))return this.cache.get(e);if(r){const n=r();return this.cache.set(e,n),n}else return}delete(e){return this.throwIfDisposed(),this.cache.delete(e)}clear(){this.throwIfDisposed(),this.cache.clear()}},s(Ds,"SimpleCache"),Ds),xs,Gd=(xs=class extends Md{constructor(e){super(),this.cache=new Map,this.converter=e??(r=>r)}has(e,r){return this.throwIfDisposed(),this.cacheForContext(e).has(r)}set(e,r,n){this.throwIfDisposed(),this.cacheForContext(e).set(r,n)}get(e,r,n){this.throwIfDisposed();const a=this.cacheForContext(e);if(a.has(r))return a.get(r);if(n){const i=n();return a.set(r,i),i}else return}delete(e,r){return this.throwIfDisposed(),this.cacheForContext(e).delete(r)}clear(e){if(this.throwIfDisposed(),e){const r=this.converter(e);this.cache.delete(r)}else this.cache.clear()}cacheForContext(e){const r=this.converter(e);let n=this.cache.get(r);return n||(n=new Map,this.cache.set(r,n)),n}},s(xs,"ContextCache"),xs),Ms,JN=(Ms=class extends Gd{constructor(e,r){super(n=>n.toString()),r?(this.toDispose.push(e.workspace.DocumentBuilder.onDocumentPhase(r,n=>{this.clear(n.uri.toString())})),this.toDispose.push(e.workspace.DocumentBuilder.onUpdate((n,a)=>{for(const i of a)this.clear(i)}))):this.toDispose.push(e.workspace.DocumentBuilder.onUpdate((n,a)=>{const i=n.concat(a);for(const o of i)this.clear(o)}))}},s(Ms,"DocumentCache"),Ms),Gs,Kg=(Gs=class extends Ug{constructor(e,r){super(),r?(this.toDispose.push(e.workspace.DocumentBuilder.onBuildPhase(r,()=>{this.clear()})),this.toDispose.push(e.workspace.DocumentBuilder.onUpdate((n,a)=>{a.length>0&&this.clear()}))):this.toDispose.push(e.workspace.DocumentBuilder.onUpdate(()=>{this.clear()}))}},s(Gs,"WorkspaceCache"),Gs),Fs,ZN=(Fs=class{constructor(e){this.reflection=e.shared.AstReflection,this.nameProvider=e.references.NameProvider,this.descriptions=e.workspace.AstNodeDescriptionProvider,this.indexManager=e.shared.workspace.IndexManager,this.globalScopeCache=new Kg(e.shared)}getScope(e){const r=[],n=this.reflection.getReferenceType(e),a=Vt(e.container).localSymbols;if(a){let o=e.container;do a.has(o)&&r.push(a.getStream(o).filter(u=>this.reflection.isSubtype(u.type,n))),o=o.$container;while(o)}let i=this.getGlobalScope(n,e);for(let o=r.length-1;o>=0;o--)i=this.createScope(r[o],i);return i}createScope(e,r,n){return new Xm(de(e),r,n)}createScopeForNodes(e,r,n){const a=de(e).map(i=>{const o=this.nameProvider.getName(i);if(o)return this.descriptions.createDescription(i,o)}).nonNullable();return new Xm(a,r,n)}getGlobalScope(e,r){return this.globalScopeCache.get(e,()=>new XN(this.indexManager.allElements(e)))}},s(Fs,"DefaultScopeProvider"),Fs);function Wg(t){return typeof t.$comment=="string"}s(Wg,"isAstNodeWithComment");function Jm(t){return typeof t=="object"&&!!t&&("$ref"in t||"$error"in t)}s(Jm,"isIntermediateReference");var zs,QN=(zs=class{constructor(e){this.ignoreProperties=new Set(["$container","$containerProperty","$containerIndex","$document","$cstNode"]),this.langiumDocuments=e.shared.workspace.LangiumDocuments,this.astNodeLocator=e.workspace.AstNodeLocator,this.nameProvider=e.references.NameProvider,this.commentProvider=e.documentation.CommentProvider}serialize(e,r){const n=r??{},a=r?.replacer,i=s((u,l)=>this.replacer(u,l,n),"defaultReplacer"),o=a?(u,l)=>a(u,l,i):i;try{return this.currentDocument=Vt(e),JSON.stringify(e,o,r?.space)}finally{this.currentDocument=void 0}}deserialize(e,r){const n=r??{},a=JSON.parse(e);return this.linkNode(a,a,n),a}replacer(e,r,{refText:n,sourceText:a,textRegions:i,comments:o,uriConverter:u}){if(!this.ignoreProperties.has(e))if(ft(r)){const l=r.ref,c=n?r.$refText:void 0;if(l){const f=Vt(l);let d="";this.currentDocument&&this.currentDocument!==f&&(u?d=u(f.uri,l):d=f.uri.toString());const p=this.astNodeLocator.getAstNodePath(l);return{$ref:`${d}#${p}`,$refText:c}}else return{$error:r.error?.message??"Could not resolve reference",$refText:c}}else if(fr(r)){const l=n?r.$refText:void 0,c=[];for(const f of r.items){const d=f.ref,p=Vt(f.ref);let y="";this.currentDocument&&this.currentDocument!==p&&(u?y=u(p.uri,d):y=p.uri.toString());const h=this.astNodeLocator.getAstNodePath(d);c.push(`${y}#${h}`)}return{$refs:c,$refText:l}}else if(Be(r)){let l;if(i&&(l=this.addAstNodeRegionWithAssignmentsTo({...r}),(!e||r.$document)&&l?.$textRegion&&(l.$textRegion.documentURI=this.currentDocument?.uri.toString())),a&&!e&&(l??(l={...r}),l.$sourceText=r.$cstNode?.text),o){l??(l={...r});const c=this.commentProvider.getComment(r);c&&(l.$comment=c.replace(/\r/g,""))}return l??r}else return r}addAstNodeRegionWithAssignmentsTo(e){const r=s(n=>({offset:n.offset,end:n.end,length:n.length,range:n.range}),"createDocumentSegment");if(e.$cstNode){const n=e.$textRegion=r(e.$cstNode),a=n.assignments={};return Object.keys(e).filter(i=>!i.startsWith("$")).forEach(i=>{const o=my(e.$cstNode,i).map(r);o.length!==0&&(a[i]=o)}),e}}linkNode(e,r,n,a,i,o){for(const[l,c]of Object.entries(e))if(Array.isArray(c))for(let f=0;f<c.length;f++){const d=c[f];Jm(d)?c[f]=this.reviveReference(e,l,r,d,n):Be(d)&&this.linkNode(d,r,n,e,l,f)}else Jm(c)?e[l]=this.reviveReference(e,l,r,c,n):Be(c)&&this.linkNode(c,r,n,e,l);const u=e;u.$container=a,u.$containerProperty=i,u.$containerIndex=o}reviveReference(e,r,n,a,i){let o=a.$refText,u=a.$error,l;if(a.$ref){const c=this.getRefNode(n,a.$ref,i.uriConverter);if(Be(c))return o||(o=this.nameProvider.getName(c)),{$refText:o??"",ref:c};u=c}else if(a.$refs){const c=[];for(const f of a.$refs){const d=this.getRefNode(n,f,i.uriConverter);Be(d)&&c.push({ref:d})}if(c.length===0)l={$refText:o??"",items:c},u??(u="Could not resolve multi-reference");else return{$refText:o??"",items:c}}if(u)return l??(l={$refText:o??"",ref:void 0}),l.error={info:{container:e,property:r,reference:l},message:u},l}getRefNode(e,r,n){try{const a=r.indexOf("#");if(a===0){const l=this.astNodeLocator.getAstNode(e,r.substring(1));return l||"Could not resolve path: "+r}if(a<0){const l=n?n(r):It.parse(r),c=this.langiumDocuments.getDocument(l);return c?c.parseResult.value:"Could not find document for URI: "+r}const i=n?n(r.substring(0,a)):It.parse(r.substring(0,a)),o=this.langiumDocuments.getDocument(i);if(!o)return"Could not find document for URI: "+r;if(a===r.length-1)return o.parseResult.value;const u=this.astNodeLocator.getAstNode(o.parseResult.value,r.substring(a+1));return u||"Could not resolve URI: "+r}catch(a){return String(a)}}},s(zs,"DefaultJsonSerializer"),zs),js,eP=(js=class{get map(){return this.fileExtensionMap}constructor(e){this.languageIdMap=new Map,this.fileExtensionMap=new Map,this.fileNameMap=new Map,this.textDocuments=e?.workspace.TextDocuments}register(e){const r=e.LanguageMetaData;for(const n of r.fileExtensions)this.fileExtensionMap.has(n)&&console.warn(`The file extension ${n} is used by multiple languages. It is now assigned to '${r.languageId}'.`),this.fileExtensionMap.set(n,e);if(r.fileNames)for(const n of r.fileNames)this.fileNameMap.has(n)&&console.warn(`The file name ${n} is used by multiple languages. It is now assigned to '${r.languageId}'.`),this.fileNameMap.set(n,e);this.languageIdMap.set(r.languageId,e)}getServices(e){if(this.languageIdMap.size===0)throw new Error("The service registry is empty. Use `register` to register the services of a language.");const r=this.textDocuments?.get(e)?.languageId;if(r!==void 0){const o=this.languageIdMap.get(r);if(o)return o}const n=dt.extname(e),a=dt.basename(e),i=this.fileNameMap.get(a)??this.fileExtensionMap.get(n);if(!i)throw r?new Error(`The service registry contains no services for the extension '${n}' for language '${r}'.`):new Error(`The service registry contains no services for the extension '${n}'.`);return i}hasServices(e){try{return this.getServices(e),!0}catch{return!1}}get all(){return Array.from(this.languageIdMap.values())}},s(js,"DefaultServiceRegistry"),js);function xn(t){return{code:t}}s(xn,"diagnosticData");var Nf;(function(t){t.defaults=["fast","slow","built-in"],t.all=t.defaults})(Nf||(Nf={}));var Bs,tP=(Bs=class{constructor(e){this.entries=new xr,this.knownCategories=new Set(Nf.defaults),this.entriesBefore=[],this.entriesAfter=[],this.reflection=e.shared.AstReflection}register(e,r=this,n="fast"){if(n==="built-in")throw new Error("The 'built-in' category is reserved for lexer, parser, and linker errors.");this.knownCategories.add(n);for(const[a,i]of Object.entries(e)){const o=i;if(Array.isArray(o))for(const u of o){const l={check:this.wrapValidationException(u,r),category:n};this.addEntry(a,l)}else if(typeof o=="function"){const u={check:this.wrapValidationException(o,r),category:n};this.addEntry(a,u)}else rn()}}wrapValidationException(e,r){return async(n,a,i)=>{await this.handleException(()=>e.call(r,n,a,i),"An error occurred during validation",a,n)}}async handleException(e,r,n,a){try{await e()}catch(i){if(da(i))throw i;console.error(`${r}:`,i),i instanceof Error&&i.stack&&console.error(i.stack);const o=i instanceof Error?i.message:String(i);n("error",`${r}: ${o}`,{node:a})}}addEntry(e,r){if(e==="AstNode"){this.entries.add("AstNode",r);return}for(const n of this.reflection.getAllSubTypes(e))this.entries.add(n,r)}getChecks(e,r){let n=de(this.entries.get(e)).concat(this.entries.get("AstNode"));return r&&(n=n.filter(a=>r.includes(a.category))),n.map(a=>a.check)}registerBeforeDocument(e,r=this){this.entriesBefore.push(this.wrapPreparationException(e,"An error occurred during set-up of the validation",r))}registerAfterDocument(e,r=this){this.entriesAfter.push(this.wrapPreparationException(e,"An error occurred during tear-down of the validation",r))}wrapPreparationException(e,r,n){return async(a,i,o,u)=>{await this.handleException(()=>e.call(n,a,i,o,u),r,i,a)}}get checksBefore(){return this.entriesBefore}get checksAfter(){return this.entriesAfter}getAllValidationCategories(e){return this.knownCategories}},s(Bs,"ValidationRegistry"),Bs),rP=Object.freeze({validateNode:!0,validateChildren:!0}),Us,nP=(Us=class{constructor(e){this.validationRegistry=e.validation.ValidationRegistry,this.metadata=e.LanguageMetaData,this.profiler=e.shared.profilers.LangiumProfiler,this.languageId=e.LanguageMetaData.languageId}async validateDocument(e,r={},n=$e.CancellationToken.None){const a=e.parseResult,i=[];if(await Ye(n),(!r.categories||r.categories.includes("built-in"))&&(this.processLexingErrors(a,i,r),r.stopAfterLexingErrors&&i.some(o=>o.data?.code===Mt.LexingError)||(this.processParsingErrors(a,i,r),r.stopAfterParsingErrors&&i.some(o=>o.data?.code===Mt.ParsingError))||(this.processLinkingErrors(e,i,r),r.stopAfterLinkingErrors&&i.some(o=>o.data?.code===Mt.LinkingError))))return i;try{i.push(...await this.validateAst(a.value,r,n))}catch(o){if(da(o))throw o;console.error("An error occurred during validation:",o)}return await Ye(n),i}processLexingErrors(e,r,n){const a=[...e.lexerErrors,...e.lexerReport?.diagnostics??[]];for(const i of a){const o=i.severity??"error",u={severity:gu(o),range:{start:{line:i.line-1,character:i.column-1},end:{line:i.line-1,character:i.column+i.length-1}},message:i.message,data:qg(o),source:this.getSource()};r.push(u)}}processParsingErrors(e,r,n){for(const a of e.parserErrors){let i;if(isNaN(a.token.startOffset)){if("previousToken"in a){const o=a.previousToken;if(isNaN(o.startOffset)){const u={line:0,character:0};i={start:u,end:u}}else{const u={line:o.endLine-1,character:o.endColumn};i={start:u,end:u}}}}else i=$u(a.token);if(i){const o={severity:gu("error"),range:i,message:a.message,data:xn(Mt.ParsingError),source:this.getSource()};r.push(o)}}}processLinkingErrors(e,r,n){for(const a of e.references){const i=a.error;if(i){const o={node:i.info.container,range:a.$refNode?.range,property:i.info.property,index:i.info.index,data:{code:Mt.LinkingError,containerType:i.info.container.$type,property:i.info.property,refText:i.info.reference.$refText}};r.push(this.toDiagnostic("error",i.message,o))}}}async validateAst(e,r,n=$e.CancellationToken.None){const a=[],i=s((o,u,l)=>{a.push(this.toDiagnostic(o,u,l))},"acceptor");return await this.validateAstBefore(e,r,i,n),await this.validateAstNodes(e,r,i,n),await this.validateAstAfter(e,r,i,n),a}async validateAstBefore(e,r,n,a=$e.CancellationToken.None){const i=this.validationRegistry.checksBefore;for(const o of i)await Ye(a),await o(e,n,r.categories??[],a)}async validateAstNodes(e,r,n,a=$e.CancellationToken.None){if(this.profiler?.isActive("validating")){const i=this.profiler.createTask("validating",this.languageId);i.start();try{const o=qt(e).iterator();for(const u of o){i.startSubTask(u.$type);const l=this.validateSingleNodeOptions(u,r);if(l.validateNode)try{const c=this.validationRegistry.getChecks(u.$type,r.categories);for(const f of c)await f(u,n,a)}finally{i.stopSubTask(u.$type)}l.validateChildren||o.prune()}}finally{i.stop()}}else{const i=qt(e).iterator();for(const o of i){await Ye(a);const u=this.validateSingleNodeOptions(o,r);if(u.validateNode){const l=this.validationRegistry.getChecks(o.$type,r.categories);for(const c of l)await c(o,n,a)}u.validateChildren||i.prune()}}}validateSingleNodeOptions(e,r){return rP}async validateAstAfter(e,r,n,a=$e.CancellationToken.None){const i=this.validationRegistry.checksAfter;for(const o of i)await Ye(a),await o(e,n,r.categories??[],a)}toDiagnostic(e,r,n){return{message:r,range:Vg(n),severity:gu(e),code:n.code,codeDescription:n.codeDescription,tags:n.tags,relatedInformation:n.relatedInformation,data:n.data,source:this.getSource()}}getSource(){return this.metadata.languageId}},s(Us,"DefaultDocumentValidator"),Us);function Vg(t){if(t.range)return t.range;let e;return typeof t.property=="string"?e=Hf(t.node.$cstNode,t.property,t.index):typeof t.keyword=="string"&&(e=hy(t.node.$cstNode,t.keyword,t.index)),e??(e=t.node.$cstNode),e?e.range:{start:{line:0,character:0},end:{line:0,character:0}}}s(Vg,"getDiagnosticRange");function gu(t){switch(t){case"error":return 1;case"warning":return 2;case"info":return 3;case"hint":return 4;default:throw new Error("Invalid diagnostic severity: "+t)}}s(gu,"toDiagnosticSeverity");function qg(t){switch(t){case"error":return xn(Mt.LexingError);case"warning":return xn(Mt.LexingWarning);case"info":return xn(Mt.LexingInfo);case"hint":return xn(Mt.LexingHint);default:throw new Error("Invalid diagnostic severity: "+t)}}s(qg,"toDiagnosticData");var Mt;(function(t){t.LexingError="lexing-error",t.LexingWarning="lexing-warning",t.LexingInfo="lexing-info",t.LexingHint="lexing-hint",t.ParsingError="parsing-error",t.LinkingError="linking-error"})(Mt||(Mt={}));var Ks,aP=(Ks=class{constructor(e){this.astNodeLocator=e.workspace.AstNodeLocator,this.nameProvider=e.references.NameProvider}createDescription(e,r,n){const a=n??Vt(e);r??(r=this.nameProvider.getName(e));const i=this.astNodeLocator.getAstNodePath(e);if(!r)throw new Error(`Node at path ${i} has no name.`);let o;const u=s(()=>o??(o=Qo(this.nameProvider.getNameNode(e)??e.$cstNode)),"nameSegmentGetter");return{node:e,name:r,get nameSegment(){return u()},selectionSegment:Qo(e.$cstNode),type:e.$type,documentUri:a.uri,path:i}}},s(Ks,"DefaultAstNodeDescriptionProvider"),Ks),Ws,iP=(Ws=class{constructor(e){this.nodeLocator=e.workspace.AstNodeLocator}async createDescriptions(e,r=$e.CancellationToken.None){const n=[],a=e.parseResult.value;for(const i of qt(a))await Ye(r),Xo(i).forEach(o=>{o.reference.error||n.push(...this.createInfoDescriptions(o))});return n}createInfoDescriptions(e){const r=e.reference;if(r.error||!r.$refNode)return[];let n=[];ft(r)&&r.$nodeDescription?n=[r.$nodeDescription]:fr(r)&&(n=r.items.map(l=>l.$nodeDescription).filter(l=>l!==void 0));const a=Vt(e.container).uri,i=this.nodeLocator.getAstNodePath(e.container),o=[],u=Qo(r.$refNode);for(const l of n)o.push({sourceUri:a,sourcePath:i,targetUri:l.documentUri,targetPath:l.path,segment:u,local:dt.equals(l.documentUri,a)});return o}},s(Ws,"DefaultReferenceDescriptionProvider"),Ws),Vs,sP=(Vs=class{constructor(){this.segmentSeparator="/",this.indexSeparator="@"}getAstNodePath(e){if(e.$container){const r=this.getAstNodePath(e.$container),n=this.getPathSegment(e);return r+this.segmentSeparator+n}return""}getPathSegment({$containerProperty:e,$containerIndex:r}){if(!e)throw new Error("Missing '$containerProperty' in AST node.");return r!==void 0?e+this.indexSeparator+r:e}getAstNode(e,r){return r.split(this.segmentSeparator).reduce((a,i)=>{if(!a||i.length===0)return a;const o=i.indexOf(this.indexSeparator);if(o>0){const u=i.substring(0,o),l=parseInt(i.substring(o+1));return a[u]?.[l]}return a[i]},e)}},s(Vs,"DefaultAstNodeLocator"),Vs),Fd={};Of(Fd,Rh(al()));var qs,oP=(qs=class{constructor(e){this._ready=new Dr,this.onConfigurationSectionUpdateEmitter=new Fd.Emitter,this.settings={},this.workspaceConfig=!1,this.serviceRegistry=e.ServiceRegistry}get ready(){return this._ready.promise}initialize(e){this.workspaceConfig=e.capabilities.workspace?.configuration??!1}async initialized(e){if(this.workspaceConfig){if(e.register){const r=this.serviceRegistry.all;e.register({section:r.map(n=>this.toSectionName(n.LanguageMetaData.languageId))})}if(e.fetchConfiguration){const r=this.serviceRegistry.all.map(a=>({section:this.toSectionName(a.LanguageMetaData.languageId)})),n=await e.fetchConfiguration(r);r.forEach((a,i)=>{this.updateSectionConfiguration(a.section,n[i])})}}this._ready.resolve()}updateConfiguration(e){typeof e.settings!="object"||e.settings===null||Object.entries(e.settings).forEach(([r,n])=>{this.updateSectionConfiguration(r,n),this.onConfigurationSectionUpdateEmitter.fire({section:r,configuration:n})})}updateSectionConfiguration(e,r){this.settings[e]=r}async getConfiguration(e,r){await this.ready;const n=this.toSectionName(e);if(this.settings[n])return this.settings[n][r]}toSectionName(e){return`${e}`}get onConfigurationSectionUpdate(){return this.onConfigurationSectionUpdateEmitter.event}},s(qs,"DefaultConfigurationProvider"),qs),uc=Rh(Xk()),Fn;(function(t){function e(r){return{dispose:s(async()=>await r(),"dispose")}}s(e,"create"),t.create=e})(Fn||(Fn={}));var Hs,lP=(Hs=class{constructor(e){this.updateBuildOptions={validation:{categories:["built-in","fast"]}},this.updateListeners=[],this.buildPhaseListeners=new xr,this.documentPhaseListeners=new xr,this.buildState=new Map,this.documentBuildWaiters=new Map,this.currentState=Q.Changed,this.langiumDocuments=e.workspace.LangiumDocuments,this.langiumDocumentFactory=e.workspace.LangiumDocumentFactory,this.textDocuments=e.workspace.TextDocuments,this.indexManager=e.workspace.IndexManager,this.fileSystemProvider=e.workspace.FileSystemProvider,this.workspaceManager=()=>e.workspace.WorkspaceManager,this.serviceRegistry=e.ServiceRegistry}async build(e,r={},n=$e.CancellationToken.None){for(const a of e){const i=a.uri.toString();if(a.state===Q.Validated){if(typeof r.validation=="boolean"&&r.validation)this.resetToState(a,Q.IndexedReferences);else if(typeof r.validation=="object"){const o=this.findMissingValidationCategories(a,r);o.length>0&&(this.buildState.set(i,{completed:!1,options:{validation:{categories:o}},result:this.buildState.get(i)?.result}),a.state=Q.IndexedReferences)}}else this.buildState.delete(i)}this.currentState=Q.Changed,await this.emitUpdate(e.map(a=>a.uri),[]),await this.buildDocuments(e,r,n)}async update(e,r,n=$e.CancellationToken.None){this.currentState=Q.Changed;const a=[];for(const l of r){const c=this.langiumDocuments.deleteDocuments(l);for(const f of c)a.push(f.uri),this.cleanUpDeleted(f)}const i=(await Promise.all(e.map(l=>this.findChangedUris(l)))).flat();for(const l of i){let c=this.langiumDocuments.getDocument(l);c===void 0&&(c=this.langiumDocumentFactory.fromModel({$type:"INVALID"},l),c.state=Q.Changed,this.langiumDocuments.addDocument(c)),this.resetToState(c,Q.Changed)}const o=de(i).concat(a).map(l=>l.toString()).toSet();this.langiumDocuments.all.filter(l=>!o.has(l.uri.toString())&&this.shouldRelink(l,o)).forEach(l=>this.resetToState(l,Q.ComputedScopes)),await this.emitUpdate(i,a),await Ye(n);const u=this.sortDocuments(this.langiumDocuments.all.filter(l=>l.state<Q.Validated||!this.buildState.get(l.uri.toString())?.completed||this.resultsAreIncomplete(l,this.updateBuildOptions)).toArray());await this.buildDocuments(u,this.updateBuildOptions,n)}resultsAreIncomplete(e,r){return this.findMissingValidationCategories(e,r).length>=1}findMissingValidationCategories(e,r){const n=this.buildState.get(e.uri.toString()),a=this.serviceRegistry.getServices(e.uri).validation.ValidationRegistry.getAllValidationCategories(e),i=n?.result?.validationChecks?new Set(n?.result?.validationChecks):n?.completed?a:new Set,o=r===void 0||r.validation===!0?a:typeof r.validation=="object"?r.validation.categories??a:[];return de(o).filter(u=>!i.has(u)).toArray()}async findChangedUris(e){if(this.langiumDocuments.getDocument(e)??this.textDocuments?.get(e))return[e];try{const n=await this.fileSystemProvider.stat(e);if(n.isDirectory)return await this.workspaceManager().searchFolder(e);if(this.workspaceManager().shouldIncludeEntry(n))return[e]}catch{}return[]}async emitUpdate(e,r){await Promise.all(this.updateListeners.map(n=>n(e,r)))}sortDocuments(e){let r=0,n=e.length-1;for(;r<n;){for(;r<e.length&&this.hasTextDocument(e[r]);)r++;for(;n>=0&&!this.hasTextDocument(e[n]);)n--;r<n&&([e[r],e[n]]=[e[n],e[r]])}return e}hasTextDocument(e){return!!this.textDocuments?.get(e.uri)}shouldRelink(e,r){return e.references.some(n=>n.error!==void 0)?!0:this.indexManager.isAffected(e,r)}onUpdate(e){return this.updateListeners.push(e),Fn.create(()=>{const r=this.updateListeners.indexOf(e);r>=0&&this.updateListeners.splice(r,1)})}resetToState(e,r){switch(r){case Q.Changed:case Q.Parsed:this.indexManager.removeContent(e.uri);case Q.IndexedContent:e.localSymbols=void 0;case Q.ComputedScopes:this.serviceRegistry.getServices(e.uri).references.Linker.unlink(e);case Q.Linked:this.indexManager.removeReferences(e.uri);case Q.IndexedReferences:e.diagnostics=void 0,this.buildState.delete(e.uri.toString());case Q.Validated:}e.state>r&&(e.state=r)}cleanUpDeleted(e){this.buildState.delete(e.uri.toString()),this.indexManager.remove(e.uri),e.state=Q.Changed}async buildDocuments(e,r,n){this.prepareBuild(e,r),await this.runCancelable(e,Q.Parsed,n,o=>this.langiumDocumentFactory.update(o,n)),await this.runCancelable(e,Q.IndexedContent,n,o=>this.indexManager.updateContent(o,n)),await this.runCancelable(e,Q.ComputedScopes,n,async o=>{const u=this.serviceRegistry.getServices(o.uri).references.ScopeComputation;o.localSymbols=await u.collectLocalSymbols(o,n)});const a=e.filter(o=>this.shouldLink(o));await this.runCancelable(a,Q.Linked,n,o=>this.serviceRegistry.getServices(o.uri).references.Linker.link(o,n)),await this.runCancelable(a,Q.IndexedReferences,n,o=>this.indexManager.updateReferences(o,n));const i=e.filter(o=>this.shouldValidate(o)?!0:(this.markAsCompleted(o),!1));await this.runCancelable(i,Q.Validated,n,async o=>{await this.validate(o,n),this.markAsCompleted(o)})}markAsCompleted(e){const r=this.buildState.get(e.uri.toString());r&&(r.completed=!0)}prepareBuild(e,r){for(const n of e){const a=n.uri.toString(),i=this.buildState.get(a);(!i||i.completed)&&this.buildState.set(a,{completed:!1,options:r,result:i?.result})}}async runCancelable(e,r,n,a){for(const o of e)o.state<r&&(await Ye(n),await a(o),o.state=r,await this.notifyDocumentPhase(o,r,n));const i=e.filter(o=>o.state===r);await this.notifyBuildPhase(i,r,n),this.currentState=r}onBuildPhase(e,r){return this.buildPhaseListeners.add(e,r),Fn.create(()=>{this.buildPhaseListeners.delete(e,r)})}onDocumentPhase(e,r){return this.documentPhaseListeners.add(e,r),Fn.create(()=>{this.documentPhaseListeners.delete(e,r)})}waitUntil(e,r,n){let a;return r&&"path"in r?a=r:n=r,n??(n=$e.CancellationToken.None),a?this.awaitDocumentState(e,a,n):this.awaitBuilderState(e,n)}awaitDocumentState(e,r,n){const a=this.langiumDocuments.getDocument(r);if(a){if(a.state>=e)return Promise.resolve(r);if(n.isCancellationRequested)return Promise.reject(cr);if(this.currentState>=e&&e>a.state)return Promise.reject(new uc.ResponseError(uc.LSPErrorCodes.RequestFailed,`Document state of ${r.toString()} is ${Q[a.state]}, requiring ${Q[e]}, but workspace state is already ${Q[this.currentState]}. Returning undefined.`))}else return Promise.reject(new uc.ResponseError(uc.LSPErrorCodes.ServerCancelled,`No document found for URI: ${r.toString()}`));return new Promise((i,o)=>{const u=this.onDocumentPhase(e,c=>{dt.equals(c.uri,r)&&(u.dispose(),l.dispose(),i(c.uri))}),l=n.onCancellationRequested(()=>{u.dispose(),l.dispose(),o(cr)})})}awaitBuilderState(e,r){return this.currentState>=e?Promise.resolve():r.isCancellationRequested?Promise.reject(cr):new Promise((n,a)=>{const i=this.onBuildPhase(e,()=>{i.dispose(),o.dispose(),n()}),o=r.onCancellationRequested(()=>{i.dispose(),o.dispose(),a(cr)})})}async notifyDocumentPhase(e,r,n){const i=this.documentPhaseListeners.get(r).slice();for(const o of i)try{await Ye(n),await o(e,n)}catch(u){if(!da(u))throw u}}async notifyBuildPhase(e,r,n){if(e.length===0)return;const i=this.buildPhaseListeners.get(r).slice();for(const o of i)await Ye(n),await o(e,n)}shouldLink(e){return this.getBuildOptions(e).eagerLinking??!0}shouldValidate(e){return!!this.getBuildOptions(e).validation}async validate(e,r){const n=this.serviceRegistry.getServices(e.uri).validation.DocumentValidator,a=this.getBuildOptions(e),i=typeof a.validation=="object"?{...a.validation}:{};i.categories=this.findMissingValidationCategories(e,a);const o=await n.validateDocument(e,i,r);e.diagnostics?e.diagnostics.push(...o):e.diagnostics=o;const u=this.buildState.get(e.uri.toString());u&&(u.result??(u.result={}),u.result.validationChecks?u.result.validationChecks=de(u.result.validationChecks).concat(i.categories).distinct().toArray():u.result.validationChecks=[...i.categories])}getBuildOptions(e){return this.buildState.get(e.uri.toString())?.options??{}}},s(Hs,"DefaultDocumentBuilder"),Hs),Ys,uP=(Ys=class{constructor(e){this.symbolIndex=new Map,this.symbolByTypeIndex=new Gd,this.referenceIndex=new Map,this.documents=e.workspace.LangiumDocuments,this.serviceRegistry=e.ServiceRegistry,this.astReflection=e.AstReflection}findAllReferences(e,r){const n=Vt(e).uri,a=[];return this.referenceIndex.forEach(i=>{i.forEach(o=>{dt.equals(o.targetUri,n)&&o.targetPath===r&&a.push(o)})}),de(a)}allElements(e,r){let n=de(this.symbolIndex.keys());return r&&(n=n.filter(a=>!r||r.has(a))),n.map(a=>this.getFileDescriptions(a,e)).flat()}getFileDescriptions(e,r){return r?this.symbolByTypeIndex.get(e,r,()=>(this.symbolIndex.get(e)??[]).filter(i=>this.astReflection.isSubtype(i.type,r))):this.symbolIndex.get(e)??[]}remove(e){this.removeContent(e),this.removeReferences(e)}removeContent(e){const r=e.toString();this.symbolIndex.delete(r),this.symbolByTypeIndex.clear(r)}removeReferences(e){const r=e.toString();this.referenceIndex.delete(r)}async updateContent(e,r=$e.CancellationToken.None){const a=await this.serviceRegistry.getServices(e.uri).references.ScopeComputation.collectExportedSymbols(e,r),i=e.uri.toString();this.symbolIndex.set(i,a),this.symbolByTypeIndex.clear(i)}async updateReferences(e,r=$e.CancellationToken.None){const a=await this.serviceRegistry.getServices(e.uri).workspace.ReferenceDescriptionProvider.createDescriptions(e,r);this.referenceIndex.set(e.uri.toString(),a)}isAffected(e,r){const n=this.referenceIndex.get(e.uri.toString());return n?n.some(a=>!a.local&&r.has(a.targetUri.toString())):!1}},s(Ys,"DefaultIndexManager"),Ys),Xs,cP=(Xs=class{constructor(e){this.initialBuildOptions={},this._ready=new Dr,this.serviceRegistry=e.ServiceRegistry,this.langiumDocuments=e.workspace.LangiumDocuments,this.documentBuilder=e.workspace.DocumentBuilder,this.fileSystemProvider=e.workspace.FileSystemProvider,this.mutex=e.workspace.WorkspaceLock}get ready(){return this._ready.promise}get workspaceFolders(){return this.folders}initialize(e){this.folders=e.workspaceFolders??void 0}initialized(e){return this.mutex.write(r=>this.initializeWorkspace(this.folders??[],r))}async initializeWorkspace(e,r=$e.CancellationToken.None){const n=await this.performStartup(e);await Ye(r),await this.documentBuilder.build(n,this.initialBuildOptions,r)}async performStartup(e){const r=[],n=s(o=>{r.push(o),this.langiumDocuments.hasDocument(o.uri)||this.langiumDocuments.addDocument(o)},"collector");await this.loadAdditionalDocuments(e,n);const a=[];await Promise.all(e.map(o=>this.getRootFolder(o)).map(async o=>this.traverseFolder(o,a)));const i=de(a).distinct(o=>o.toString()).filter(o=>!this.langiumDocuments.hasDocument(o));return await this.loadWorkspaceDocuments(i,n),this._ready.resolve(),r}async loadWorkspaceDocuments(e,r){await Promise.all(e.map(async n=>{const a=await this.langiumDocuments.getOrCreateDocument(n);r(a)}))}loadAdditionalDocuments(e,r){return Promise.resolve()}getRootFolder(e){return It.parse(e.uri)}async traverseFolder(e,r){try{const n=await this.fileSystemProvider.readDirectory(e);await Promise.all(n.map(async a=>{this.shouldIncludeEntry(a)&&(a.isDirectory?await this.traverseFolder(a.uri,r):a.isFile&&r.push(a.uri))}))}catch(n){console.error("Failure to read directory content of "+e.toString(!0),n)}}async searchFolder(e){const r=[];return await this.traverseFolder(e,r),r}shouldIncludeEntry(e){const r=dt.basename(e.uri);return r.startsWith(".")?!1:e.isDirectory?r!=="node_modules"&&r!=="out":e.isFile?this.serviceRegistry.hasServices(e.uri):!1}},s(Xs,"DefaultWorkspaceManager"),Xs),Js,fP=(Js=class{buildUnexpectedCharactersMessage(e,r,n,a,i){return Pm.buildUnexpectedCharactersMessage(e,r,n,a,i)}buildUnableToPopLexerModeMessage(e){return Pm.buildUnableToPopLexerModeMessage(e)}},s(Js,"DefaultLexerErrorMessageProvider"),Js),Hg={mode:"full"},Zs,Yg=(Zs=class{constructor(e){this.errorMessageProvider=e.parser.LexerErrorMessageProvider,this.tokenBuilder=e.parser.TokenBuilder;const r=this.tokenBuilder.buildTokens(e.Grammar,{caseInsensitive:e.LanguageMetaData.caseInsensitive});this.tokenTypes=this.toTokenTypeDictionary(r);const n=Pf(r)?Object.values(r):r,a=e.LanguageMetaData.mode==="production";this.chevrotainLexer=new pt(n,{positionTracking:"full",skipValidations:a,errorMessageProvider:this.errorMessageProvider})}get definition(){return this.tokenTypes}tokenize(e,r=Hg){const n=this.chevrotainLexer.tokenize(e);return{tokens:n.tokens,errors:n.errors,hidden:n.groups.hidden??[],report:this.tokenBuilder.flushLexingReport?.(e)}}toTokenTypeDictionary(e){if(Pf(e))return e;const r=jd(e)?Object.values(e.modes).flat():e,n={};return r.forEach(a=>n[a.name]=a),n}},s(Zs,"DefaultLexer"),Zs);function zd(t){return Array.isArray(t)&&(t.length===0||"name"in t[0])}s(zd,"isTokenTypeArray");function jd(t){return t&&"modes"in t&&"defaultMode"in t}s(jd,"isIMultiModeLexerDefinition");function Pf(t){return!zd(t)&&!jd(t)}s(Pf,"isTokenTypeDictionary");xu();function Xg(t,e,r){let n,a;typeof t=="string"?(a=e,n=r):(a=t.range.start,n=e),a||(a=oe.create(0,0));const i=Zg(t),o=Bd(n),u=dP({lines:i,position:a,options:o});return hP({index:0,tokens:u,position:a})}s(Xg,"parseJSDoc");function Jg(t,e){const r=Bd(e),n=Zg(t);if(n.length===0)return!1;const a=n[0],i=n[n.length-1],o=r.start,u=r.end;return!!o?.exec(a)&&!!u?.exec(i)}s(Jg,"isJSDoc");function Zg(t){let e="";return typeof t=="string"?e=t:e=t.text,e.split(yR)}s(Zg,"getLines");var wT=/\s*(@([\p{L}][\p{L}\p{N}]*)?)/uy,gB=/\{(@[\p{L}][\p{L}\p{N}]*)(\s*)([^\r\n}]+)?\}/gu;function dP(t){const e=[];let r=t.position.line,n=t.position.character;for(let a=0;a<t.lines.length;a++){const i=a===0,o=a===t.lines.length-1;let u=t.lines[a],l=0;if(i&&t.options.start){const f=t.options.start?.exec(u);f&&(l=f.index+f[0].length)}else{const f=t.options.line?.exec(u);f&&(l=f.index+f[0].length)}if(o){const f=t.options.end?.exec(u);f&&(u=u.substring(0,f.index))}if(u=u.substring(0,mP(u)),kf(u,l)>=u.length){if(e.length>0){const f=oe.create(r,n);e.push({type:"break",content:"",range:te.create(f,f)})}}else{wT.lastIndex=l;const f=wT.exec(u);if(f){const d=f[0],p=f[1],y=oe.create(r,n+l),h=oe.create(r,n+l+d.length);e.push({type:"tag",content:p,range:te.create(y,h)}),l+=d.length,l=kf(u,l)}if(l<u.length){const d=u.substring(l),p=Array.from(d.matchAll(gB));e.push(...pP(p,d,r,n+l))}}r++,n=0}return e.length>0&&e[e.length-1].type==="break"?e.slice(0,-1):e}s(dP,"tokenize");function pP(t,e,r,n){const a=[];if(t.length===0){const i=oe.create(r,n),o=oe.create(r,n+e.length);a.push({type:"text",content:e,range:te.create(i,o)})}else{let i=0;for(const u of t){const l=u.index,c=e.substring(i,l);c.length>0&&a.push({type:"text",content:e.substring(i,l),range:te.create(oe.create(r,i+n),oe.create(r,l+n))});let f=c.length+1;const d=u[1];if(a.push({type:"inline-tag",content:d,range:te.create(oe.create(r,i+f+n),oe.create(r,i+f+d.length+n))}),f+=d.length,u.length===4){f+=u[2].length;const p=u[3];a.push({type:"text",content:p,range:te.create(oe.create(r,i+f+n),oe.create(r,i+f+p.length+n))})}else a.push({type:"text",content:"",range:te.create(oe.create(r,i+f+n),oe.create(r,i+f+n))});i=l+u[0].length}const o=e.substring(i);o.length>0&&a.push({type:"text",content:o,range:te.create(oe.create(r,i+n),oe.create(r,i+n+o.length))})}return a}s(pP,"buildInlineTokens");var vB=/\S/,TB=/\s*$/;function kf(t,e){const r=t.substring(e).match(vB);return r?e+r.index:t.length}s(kf,"skipWhitespace");function mP(t){const e=t.match(TB);if(e&&typeof e.index=="number")return e.index}s(mP,"lastCharacter");function hP(t){const e=oe.create(t.position.line,t.position.character);if(t.tokens.length===0)return new IT([],te.create(e,e));const r=[];for(;t.index<t.tokens.length;){const i=yP(t,r[r.length-1]);i&&r.push(i)}const n=r[0]?.range.start??e,a=r[r.length-1]?.range.end??e;return new IT(r,te.create(n,a))}s(hP,"parseJSDocComment");function yP(t,e){const r=t.tokens[t.index];if(r.type==="tag")return ev(t,!1);if(r.type==="text"||r.type==="inline-tag")return Qg(t);gP(r,e),t.index++}s(yP,"parseJSDocElement");function gP(t,e){if(e){const r=new RP("",t.range);"inlines"in e?e.inlines.push(r):e.content.inlines.push(r)}}s(gP,"appendEmptyLine");function Qg(t){let e=t.tokens[t.index];const r=e;let n=e;const a=[];for(;e&&e.type!=="break"&&e.type!=="tag";)a.push(vP(t)),n=e,e=t.tokens[t.index];return new Zm(a,te.create(r.range.start,n.range.end))}s(Qg,"parseJSDocText");function vP(t){return t.tokens[t.index].type==="inline-tag"?ev(t,!0):tv(t)}s(vP,"parseJSDocInline");function ev(t,e){const r=t.tokens[t.index++],n=r.content.substring(1);if(t.tokens[t.index]?.type==="text")if(e){const i=tv(t);return new Zd(n,new Zm([i],i.range),e,te.create(r.range.start,i.range.end))}else{const i=Qg(t);return new Zd(n,i,e,te.create(r.range.start,i.range.end))}else{const i=r.range;return new Zd(n,new Zm([],i),e,i)}}s(ev,"parseJSDocTag");function tv(t){const e=t.tokens[t.index++];return new RP(e.content,e.range)}s(tv,"parseJSDocLine");function Bd(t){if(!t)return Bd({start:"/**",end:"*/",line:"*"});const{start:e,end:r,line:n}=t;return{start:jc(e,!0),end:jc(r,!1),line:jc(n,!0)}}s(Bd,"normalizeOptions");function jc(t,e){if(typeof t=="string"||typeof t=="object"){const r=typeof t=="string"?sl(t):t.source;return e?new RegExp(`^\\s*${r}`):new RegExp(`\\s*${r}\\s*$`)}else return t}s(jc,"normalizeOption");var Qs,IT=(Qs=class{constructor(e,r){this.elements=e,this.range=r}getTag(e){return this.getAllTags().find(r=>r.name===e)}getTags(e){return this.getAllTags().filter(r=>r.name===e)}getAllTags(){return this.elements.filter(e=>"name"in e)}toString(){let e="";for(const r of this.elements)if(e.length===0)e=r.toString();else{const n=r.toString();e+=Qm(e)+n}return e.trim()}toMarkdown(e){let r="";for(const n of this.elements)if(r.length===0)r=n.toMarkdown(e);else{const a=n.toMarkdown(e);r+=Qm(r)+a}return r.trim()}},s(Qs,"JSDocCommentImpl"),Qs),eo,Zd=(eo=class{constructor(e,r,n,a){this.name=e,this.content=r,this.inline=n,this.range=a}toString(){let e=`@${this.name}`;const r=this.content.toString();return this.content.inlines.length===1?e=`${e} ${r}`:this.content.inlines.length>1&&(e=`${e}
151
+ `;case"r":return"\r";case"t":return" ";case"v":return"\v";case"0":return"\0";default:return c}}s(r,"convertEscapeCharacter");function n(c){return c.charAt(0)==="^"?c.substring(1):c}s(n,"convertID"),t.convertID=n;function a(c){return parseInt(c)}s(a,"convertInt"),t.convertInt=a;function i(c){return BigInt(c)}s(i,"convertBigint"),t.convertBigint=i;function o(c){return new Date(c)}s(o,"convertDate"),t.convertDate=o;function u(c){return Number(c)}s(u,"convertNumber"),t.convertNumber=u;function l(c){return c.toLowerCase()==="true"}s(l,"convertBoolean"),t.convertBoolean=l})(or||(or={}));var $e={};Of($e,Rh(Df()));function Dd(){return new Promise(t=>{typeof setImmediate>"u"?setTimeout(t,0):setImmediate(t)})}s(Dd,"delayNextTick");var zc=0,jN=10;function xd(){return zc=performance.now(),new $e.CancellationTokenSource}s(xd,"startCancelableOperation");function Gg(t){jN=t}s(Gg,"setInterruptionPeriod");var cr=Symbol("OperationCancelled");function da(t){return t===cr}s(da,"isOperationCancelled");async function Ye(t){if(t===$e.CancellationToken.None)return;const e=performance.now();if(e-zc>=jN&&(zc=e,await Dd(),zc=performance.now()),t.isCancellationRequested)throw cr}s(Ye,"interruptAndCheck");var Rs,Dr=(Rs=class{constructor(){this.promise=new Promise((e,r)=>{this.resolve=n=>(e(n),this),this.reject=n=>(r(n),this)})}},s(Rs,"Deferred"),Rs),Yr,ST=(Yr=class{constructor(e,r,n,a){this._uri=e,this._languageId=r,this._version=n,this._content=a,this._lineOffsets=void 0}get uri(){return this._uri}get languageId(){return this._languageId}get version(){return this._version}getText(e){if(e){const r=this.offsetAt(e.start),n=this.offsetAt(e.end);return this._content.substring(r,n)}return this._content}update(e,r){for(const n of e)if(Yr.isIncremental(n)){const a=zg(n.range),i=this.offsetAt(a.start),o=this.offsetAt(a.end);this._content=this._content.substring(0,i)+n.text+this._content.substring(o,this._content.length);const u=Math.max(a.start.line,0),l=Math.max(a.end.line,0);let c=this._lineOffsets;const f=Ym(n.text,!1,i);if(l-u===f.length)for(let p=0,y=f.length;p<y;p++)c[p+u+1]=f[p];else f.length<1e4?c.splice(u+1,l-u,...f):this._lineOffsets=c=c.slice(0,u+1).concat(f,c.slice(l+1));const d=n.text.length-(o-i);if(d!==0)for(let p=u+1+f.length,y=c.length;p<y;p++)c[p]=c[p]+d}else if(Yr.isFull(n))this._content=n.text,this._lineOffsets=void 0;else throw new Error("Unknown change event received");this._version=r}getLineOffsets(){return this._lineOffsets===void 0&&(this._lineOffsets=Ym(this._content,!0)),this._lineOffsets}positionAt(e){e=Math.max(Math.min(e,this._content.length),0);const r=this.getLineOffsets();let n=0,a=r.length;if(a===0)return{line:0,character:e};for(;n<a;){const o=Math.floor((n+a)/2);r[o]>e?a=o:n=o+1}const i=n-1;return e=this.ensureBeforeEOL(e,r[i]),{line:i,character:e-r[i]}}offsetAt(e){const r=this.getLineOffsets();if(e.line>=r.length)return this._content.length;if(e.line<0)return 0;const n=r[e.line];if(e.character<=0)return n;const a=e.line+1<r.length?r[e.line+1]:this._content.length,i=Math.min(n+e.character,a);return this.ensureBeforeEOL(i,n)}ensureBeforeEOL(e,r){for(;e>r&&Fg(this._content.charCodeAt(e-1));)e--;return e}get lineCount(){return this.getLineOffsets().length}static isIncremental(e){const r=e;return r!=null&&typeof r.text=="string"&&r.range!==void 0&&(r.rangeLength===void 0||typeof r.rangeLength=="number")}static isFull(e){const r=e;return r!=null&&typeof r.text=="string"&&r.range===void 0&&r.rangeLength===void 0}},s(Yr,"FullTextDocument"),Yr),Sf;(function(t){function e(a,i,o,u){return new ST(a,i,o,u)}s(e,"create"),t.create=e;function r(a,i,o){if(a instanceof ST)return a.update(i,o),a;throw new Error("TextDocument.update: document must be created by TextDocument.create")}s(r,"update"),t.update=r;function n(a,i){const o=a.getText(),u=wf(i.map(BN),(f,d)=>{const p=f.range.start.line-d.range.start.line;return p===0?f.range.start.character-d.range.start.character:p});let l=0;const c=[];for(const f of u){const d=a.offsetAt(f.range.start);if(d<l)throw new Error("Overlapping edit");d>l&&c.push(o.substring(l,d)),f.newText.length&&c.push(f.newText),l=a.offsetAt(f.range.end)}return c.push(o.substr(l)),c.join("")}s(n,"applyEdits"),t.applyEdits=n})(Sf||(Sf={}));function wf(t,e){if(t.length<=1)return t;const r=t.length/2|0,n=t.slice(0,r),a=t.slice(r);wf(n,e),wf(a,e);let i=0,o=0,u=0;for(;i<n.length&&o<a.length;)e(n[i],a[o])<=0?t[u++]=n[i++]:t[u++]=a[o++];for(;i<n.length;)t[u++]=n[i++];for(;o<a.length;)t[u++]=a[o++];return t}s(wf,"mergeSort");function Ym(t,e,r=0){const n=e?[r]:[];for(let a=0;a<t.length;a++){const i=t.charCodeAt(a);Fg(i)&&(i===13&&a+1<t.length&&t.charCodeAt(a+1)===10&&a++,n.push(r+a+1))}return n}s(Ym,"computeLineOffsets");function Fg(t){return t===13||t===10}s(Fg,"isEOL");function zg(t){const e=t.start,r=t.end;return e.line>r.line||e.line===r.line&&e.character>r.character?{start:r,end:e}:t}s(zg,"getWellformedRange");function BN(t){const e=zg(t.range);return e!==t.range?{newText:t.newText,range:e}:t}s(BN,"getWellformedEdit");var UN;(()=>{var t={975:k=>{function _(R){if(typeof R!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(R))}s(_,"e");function v(R,A){for(var S,L="",x=0,O=-1,z=0,M=0;M<=R.length;++M){if(M<R.length)S=R.charCodeAt(M);else{if(S===47)break;S=47}if(S===47){if(!(O===M-1||z===1))if(O!==M-1&&z===2){if(L.length<2||x!==2||L.charCodeAt(L.length-1)!==46||L.charCodeAt(L.length-2)!==46){if(L.length>2){var Y=L.lastIndexOf("/");if(Y!==L.length-1){Y===-1?(L="",x=0):x=(L=L.slice(0,Y)).length-1-L.lastIndexOf("/"),O=M,z=0;continue}}else if(L.length===2||L.length===1){L="",x=0,O=M,z=0;continue}}A&&(L.length>0?L+="/..":L="..",x=2)}else L.length>0?L+="/"+R.slice(O+1,M):L=R.slice(O+1,M),x=M-O-1;O=M,z=0}else S===46&&z!==-1?++z:z=-1}return L}s(v,"r");var I={resolve:s(function(){for(var R,A="",S=!1,L=arguments.length-1;L>=-1&&!S;L--){var x;L>=0?x=arguments[L]:(R===void 0&&(R=process.cwd()),x=R),_(x),x.length!==0&&(A=x+"/"+A,S=x.charCodeAt(0)===47)}return A=v(A,!S),S?A.length>0?"/"+A:"/":A.length>0?A:"."},"resolve"),normalize:s(function(R){if(_(R),R.length===0)return".";var A=R.charCodeAt(0)===47,S=R.charCodeAt(R.length-1)===47;return(R=v(R,!A)).length!==0||A||(R="."),R.length>0&&S&&(R+="/"),A?"/"+R:R},"normalize"),isAbsolute:s(function(R){return _(R),R.length>0&&R.charCodeAt(0)===47},"isAbsolute"),join:s(function(){if(arguments.length===0)return".";for(var R,A=0;A<arguments.length;++A){var S=arguments[A];_(S),S.length>0&&(R===void 0?R=S:R+="/"+S)}return R===void 0?".":I.normalize(R)},"join"),relative:s(function(R,A){if(_(R),_(A),R===A||(R=I.resolve(R))===(A=I.resolve(A)))return"";for(var S=1;S<R.length&&R.charCodeAt(S)===47;++S);for(var L=R.length,x=L-S,O=1;O<A.length&&A.charCodeAt(O)===47;++O);for(var z=A.length-O,M=x<z?x:z,Y=-1,q=0;q<=M;++q){if(q===M){if(z>M){if(A.charCodeAt(O+q)===47)return A.slice(O+q+1);if(q===0)return A.slice(O+q)}else x>M&&(R.charCodeAt(S+q)===47?Y=q:q===0&&(Y=0));break}var Z=R.charCodeAt(S+q);if(Z!==A.charCodeAt(O+q))break;Z===47&&(Y=q)}var ae="";for(q=S+Y+1;q<=L;++q)q!==L&&R.charCodeAt(q)!==47||(ae.length===0?ae+="..":ae+="/..");return ae.length>0?ae+A.slice(O+Y):(O+=Y,A.charCodeAt(O)===47&&++O,A.slice(O))},"relative"),_makeLong:s(function(R){return R},"_makeLong"),dirname:s(function(R){if(_(R),R.length===0)return".";for(var A=R.charCodeAt(0),S=A===47,L=-1,x=!0,O=R.length-1;O>=1;--O)if((A=R.charCodeAt(O))===47){if(!x){L=O;break}}else x=!1;return L===-1?S?"/":".":S&&L===1?"//":R.slice(0,L)},"dirname"),basename:s(function(R,A){if(A!==void 0&&typeof A!="string")throw new TypeError('"ext" argument must be a string');_(R);var S,L=0,x=-1,O=!0;if(A!==void 0&&A.length>0&&A.length<=R.length){if(A.length===R.length&&A===R)return"";var z=A.length-1,M=-1;for(S=R.length-1;S>=0;--S){var Y=R.charCodeAt(S);if(Y===47){if(!O){L=S+1;break}}else M===-1&&(O=!1,M=S+1),z>=0&&(Y===A.charCodeAt(z)?--z==-1&&(x=S):(z=-1,x=M))}return L===x?x=M:x===-1&&(x=R.length),R.slice(L,x)}for(S=R.length-1;S>=0;--S)if(R.charCodeAt(S)===47){if(!O){L=S+1;break}}else x===-1&&(O=!1,x=S+1);return x===-1?"":R.slice(L,x)},"basename"),extname:s(function(R){_(R);for(var A=-1,S=0,L=-1,x=!0,O=0,z=R.length-1;z>=0;--z){var M=R.charCodeAt(z);if(M!==47)L===-1&&(x=!1,L=z+1),M===46?A===-1?A=z:O!==1&&(O=1):A!==-1&&(O=-1);else if(!x){S=z+1;break}}return A===-1||L===-1||O===0||O===1&&A===L-1&&A===S+1?"":R.slice(A,L)},"extname"),format:s(function(R){if(R===null||typeof R!="object")throw new TypeError('The "pathObject" argument must be of type Object. Received type '+typeof R);return(function(A,S){var L=S.dir||S.root,x=S.base||(S.name||"")+(S.ext||"");return L?L===S.root?L+x:L+"/"+x:x})(0,R)},"format"),parse:s(function(R){_(R);var A={root:"",dir:"",base:"",ext:"",name:""};if(R.length===0)return A;var S,L=R.charCodeAt(0),x=L===47;x?(A.root="/",S=1):S=0;for(var O=-1,z=0,M=-1,Y=!0,q=R.length-1,Z=0;q>=S;--q)if((L=R.charCodeAt(q))!==47)M===-1&&(Y=!1,M=q+1),L===46?O===-1?O=q:Z!==1&&(Z=1):O!==-1&&(Z=-1);else if(!Y){z=q+1;break}return O===-1||M===-1||Z===0||Z===1&&O===M-1&&O===z+1?M!==-1&&(A.base=A.name=z===0&&x?R.slice(1,M):R.slice(z,M)):(z===0&&x?(A.name=R.slice(1,O),A.base=R.slice(1,M)):(A.name=R.slice(z,O),A.base=R.slice(z,M)),A.ext=R.slice(O,M)),z>0?A.dir=R.slice(0,z-1):x&&(A.dir="/"),A},"parse"),sep:"/",delimiter:":",win32:null,posix:null};I.posix=I,k.exports=I}},e={};function r(k){var _=e[k];if(_!==void 0)return _.exports;var v=e[k]={exports:{}};return t[k](v,v.exports,r),v.exports}s(r,"r"),r.d=(k,_)=>{for(var v in _)r.o(_,v)&&!r.o(k,v)&&Object.defineProperty(k,v,{enumerable:!0,get:_[v]})},r.o=(k,_)=>Object.prototype.hasOwnProperty.call(k,_),r.r=k=>{typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(k,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(k,"__esModule",{value:!0})};var n={};let a;r.r(n),r.d(n,{URI:s(()=>p,"URI"),Utils:s(()=>ye,"Utils")}),typeof process=="object"?a=process.platform==="win32":typeof navigator=="object"&&(a=navigator.userAgent.indexOf("Windows")>=0);const i=/^\w[\w\d+.-]*$/,o=/^\//,u=/^\/\//;function l(k,_){if(!k.scheme&&_)throw new Error(`[UriError]: Scheme is missing: {scheme: "", authority: "${k.authority}", path: "${k.path}", query: "${k.query}", fragment: "${k.fragment}"}`);if(k.scheme&&!i.test(k.scheme))throw new Error("[UriError]: Scheme contains illegal characters.");if(k.path){if(k.authority){if(!o.test(k.path))throw new Error('[UriError]: If a URI contains an authority component, then the path component must either be empty or begin with a slash ("/") character')}else if(u.test(k.path))throw new Error('[UriError]: If a URI does not contain an authority component, then the path cannot begin with two slash characters ("//")')}}s(l,"a");const c="",f="/",d=/^(([^:/?#]+?):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?/,ue=class ue{constructor(_,v,I,R,A,S=!1){Br(this,"scheme");Br(this,"authority");Br(this,"path");Br(this,"query");Br(this,"fragment");typeof _=="object"?(this.scheme=_.scheme||c,this.authority=_.authority||c,this.path=_.path||c,this.query=_.query||c,this.fragment=_.fragment||c):(this.scheme=(function(L,x){return L||x?L:"file"})(_,S),this.authority=v||c,this.path=(function(L,x){switch(L){case"https":case"http":case"file":x?x[0]!==f&&(x=f+x):x=f}return x})(this.scheme,I||c),this.query=R||c,this.fragment=A||c,l(this,S))}static isUri(_){return _ instanceof ue||!!_&&typeof _.authority=="string"&&typeof _.fragment=="string"&&typeof _.path=="string"&&typeof _.query=="string"&&typeof _.scheme=="string"&&typeof _.fsPath=="string"&&typeof _.with=="function"&&typeof _.toString=="function"}get fsPath(){return w(this,!1)}with(_){if(!_)return this;let{scheme:v,authority:I,path:R,query:A,fragment:S}=_;return v===void 0?v=this.scheme:v===null&&(v=c),I===void 0?I=this.authority:I===null&&(I=c),R===void 0?R=this.path:R===null&&(R=c),A===void 0?A=this.query:A===null&&(A=c),S===void 0?S=this.fragment:S===null&&(S=c),v===this.scheme&&I===this.authority&&R===this.path&&A===this.query&&S===this.fragment?this:new h(v,I,R,A,S)}static parse(_,v=!1){const I=d.exec(_);return I?new h(I[2]||c,ne(I[4]||c),ne(I[5]||c),ne(I[7]||c),ne(I[9]||c),v):new h(c,c,c,c,c)}static file(_){let v=c;if(a&&(_=_.replace(/\\/g,f)),_[0]===f&&_[1]===f){const I=_.indexOf(f,2);I===-1?(v=_.substring(2),_=f):(v=_.substring(2,I),_=_.substring(I)||f)}return new h("file",v,_,c,c)}static from(_){const v=new h(_.scheme,_.authority,_.path,_.query,_.fragment);return l(v,!0),v}toString(_=!1){return b(this,_)}toJSON(){return this}static revive(_){if(_){if(_ instanceof ue)return _;{const v=new h(_);return v._formatted=_.external,v._fsPath=_._sep===y?_.fsPath:null,v}}return _}};s(ue,"l");let p=ue;const y=a?1:void 0,ot=class ot extends p{constructor(){super(...arguments);Br(this,"_formatted",null);Br(this,"_fsPath",null)}get fsPath(){return this._fsPath||(this._fsPath=w(this,!1)),this._fsPath}toString(v=!1){return v?b(this,!0):(this._formatted||(this._formatted=b(this,!1)),this._formatted)}toJSON(){const v={$mid:1};return this._fsPath&&(v.fsPath=this._fsPath,v._sep=y),this._formatted&&(v.external=this._formatted),this.path&&(v.path=this.path),this.scheme&&(v.scheme=this.scheme),this.authority&&(v.authority=this.authority),this.query&&(v.query=this.query),this.fragment&&(v.fragment=this.fragment),v}};s(ot,"d");let h=ot;const $={58:"%3A",47:"%2F",63:"%3F",35:"%23",91:"%5B",93:"%5D",64:"%40",33:"%21",36:"%24",38:"%26",39:"%27",40:"%28",41:"%29",42:"%2A",43:"%2B",44:"%2C",59:"%3B",61:"%3D",32:"%20"};function C(k,_,v){let I,R=-1;for(let A=0;A<k.length;A++){const S=k.charCodeAt(A);if(S>=97&&S<=122||S>=65&&S<=90||S>=48&&S<=57||S===45||S===46||S===95||S===126||_&&S===47||v&&S===91||v&&S===93||v&&S===58)R!==-1&&(I+=encodeURIComponent(k.substring(R,A)),R=-1),I!==void 0&&(I+=k.charAt(A));else{I===void 0&&(I=k.substr(0,A));const L=$[S];L!==void 0?(R!==-1&&(I+=encodeURIComponent(k.substring(R,A)),R=-1),I+=L):R===-1&&(R=A)}}return R!==-1&&(I+=encodeURIComponent(k.substring(R))),I!==void 0?I:k}s(C,"m");function T(k){let _;for(let v=0;v<k.length;v++){const I=k.charCodeAt(v);I===35||I===63?(_===void 0&&(_=k.substr(0,v)),_+=$[I]):_!==void 0&&(_+=k[v])}return _!==void 0?_:k}s(T,"y");function w(k,_){let v;return v=k.authority&&k.path.length>1&&k.scheme==="file"?`//${k.authority}${k.path}`:k.path.charCodeAt(0)===47&&(k.path.charCodeAt(1)>=65&&k.path.charCodeAt(1)<=90||k.path.charCodeAt(1)>=97&&k.path.charCodeAt(1)<=122)&&k.path.charCodeAt(2)===58?_?k.path.substr(1):k.path[1].toLowerCase()+k.path.substr(2):k.path,a&&(v=v.replace(/\//g,"\\")),v}s(w,"v");function b(k,_){const v=_?T:C;let I="",{scheme:R,authority:A,path:S,query:L,fragment:x}=k;if(R&&(I+=R,I+=":"),(A||R==="file")&&(I+=f,I+=f),A){let O=A.indexOf("@");if(O!==-1){const z=A.substr(0,O);A=A.substr(O+1),O=z.lastIndexOf(":"),O===-1?I+=v(z,!1,!1):(I+=v(z.substr(0,O),!1,!1),I+=":",I+=v(z.substr(O+1),!1,!0)),I+="@"}A=A.toLowerCase(),O=A.lastIndexOf(":"),O===-1?I+=v(A,!1,!0):(I+=v(A.substr(0,O),!1,!0),I+=A.substr(O))}if(S){if(S.length>=3&&S.charCodeAt(0)===47&&S.charCodeAt(2)===58){const O=S.charCodeAt(1);O>=65&&O<=90&&(S=`/${String.fromCharCode(O+32)}:${S.substr(3)}`)}else if(S.length>=2&&S.charCodeAt(1)===58){const O=S.charCodeAt(0);O>=65&&O<=90&&(S=`${String.fromCharCode(O+32)}:${S.substr(2)}`)}I+=v(S,!0,!1)}return L&&(I+="?",I+=v(L,!1,!1)),x&&(I+="#",I+=_?x:C(x,!1,!1)),I}s(b,"b");function N(k){try{return decodeURIComponent(k)}catch{return k.length>3?k.substr(0,3)+N(k.substr(3)):k}}s(N,"C");const B=/(%[0-9A-Za-z][0-9A-Za-z])+/g;function ne(k){return k.match(B)?k.replace(B,(_=>N(_))):k}s(ne,"w");var J=r(975);const he=J.posix||J,Ae="/";var ye;(function(k){k.joinPath=function(_,...v){return _.with({path:he.join(_.path,...v)})},k.resolvePath=function(_,...v){let I=_.path,R=!1;I[0]!==Ae&&(I=Ae+I,R=!0);let A=he.resolve(I,...v);return R&&A[0]===Ae&&!_.authority&&(A=A.substring(1)),_.with({path:A})},k.dirname=function(_){if(_.path.length===0||_.path===Ae)return _;let v=he.dirname(_.path);return v.length===1&&v.charCodeAt(0)===46&&(v=""),_.with({path:v})},k.basename=function(_){return he.basename(_.path)},k.extname=function(_){return he.extname(_.path)}})(ye||(ye={})),UN=n})();var{URI:It,Utils:Dl}=UN,dt;(function(t){t.basename=Dl.basename,t.dirname=Dl.dirname,t.extname=Dl.extname,t.joinPath=Dl.joinPath,t.resolvePath=Dl.resolvePath;const e=typeof process=="object"&&process?.platform==="win32";function r(o,u){return o?.toString()===u?.toString()}s(r,"equals"),t.equals=r;function n(o,u){const l=typeof o=="string"?It.parse(o).path:o.path,c=typeof u=="string"?It.parse(u).path:u.path,f=l.split("/").filter($=>$.length>0),d=c.split("/").filter($=>$.length>0);if(e){const $=/^[A-Z]:$/;if(f[0]&&$.test(f[0])&&(f[0]=f[0].toLowerCase()),d[0]&&$.test(d[0])&&(d[0]=d[0].toLowerCase()),f[0]!==d[0])return c.substring(1)}let p=0;for(;p<f.length&&f[p]===d[p];p++);const y="../".repeat(f.length-p),h=d.slice(p).join("/");return y+h}s(n,"relative"),t.relative=n;function a(o){return It.parse(o.toString()).toString()}s(a,"normalize"),t.normalize=a;function i(o,u){let l=typeof o=="string"?o:o.path,c=typeof u=="string"?u:u.path;return c.charAt(c.length-1)==="/"&&(c=c.slice(0,-1)),l.charAt(l.length-1)==="/"&&(l=l.slice(0,-1)),c===l?!0:c.length<l.length||c.charAt(l.length)!=="/"?!1:c.startsWith(l)}s(i,"contains"),t.contains=i})(dt||(dt={}));var As,jg=(As=class{constructor(){this.root={name:"",children:new Map}}normalizeUri(e){return dt.normalize(e)}clear(){this.root.children.clear()}insert(e,r){const n=this.getNode(this.normalizeUri(e),!0);n.element=r}delete(e){const r=this.getNode(this.normalizeUri(e),!1);r?.parent&&r.parent.children.delete(r.name)}has(e){return this.getNode(this.normalizeUri(e),!1)?.element!==void 0}hasNode(e){return this.getNode(this.normalizeUri(e),!1)!==void 0}find(e){return this.getNode(this.normalizeUri(e),!1)?.element}findNode(e){const r=this.normalizeUri(e),n=this.getNode(r,!1);if(n)return{name:n.name,uri:dt.joinPath(It.parse(r),n.name).toString(),element:n.element}}findChildren(e){const r=this.normalizeUri(e),n=this.getNode(r,!1);return n?Array.from(n.children.values()).map(a=>({name:a.name,uri:dt.joinPath(It.parse(r),a.name).toString(),element:a.element})):[]}all(){return this.collectValues(this.root)}findAll(e){const r=this.getNode(dt.normalize(e),!1);return r?this.collectValues(r):[]}getNode(e,r){const n=e.split("/");e.charAt(e.length-1)==="/"&&n.pop();let a=this.root;for(const i of n){let o=a.children.get(i);if(!o)if(r)o={name:i,children:new Map,parent:a},a.children.set(i,o);else return;a=o}return a}collectValues(e){const r=[];e.element&&r.push(e.element);for(const n of e.children.values())r.push(...this.collectValues(n));return r}},s(As,"UriTrie"),As),Q;(function(t){t[t.Changed=0]="Changed",t[t.Parsed=1]="Parsed",t[t.IndexedContent=2]="IndexedContent",t[t.ComputedScopes=3]="ComputedScopes",t[t.Linked=4]="Linked",t[t.IndexedReferences=5]="IndexedReferences",t[t.Validated=6]="Validated"})(Q||(Q={}));var Es,KN=(Es=class{constructor(e){this.serviceRegistry=e.ServiceRegistry,this.textDocuments=e.workspace.TextDocuments,this.fileSystemProvider=e.workspace.FileSystemProvider}async fromUri(e,r=$e.CancellationToken.None){const n=await this.fileSystemProvider.readFile(e);return this.createAsync(e,n,r)}fromTextDocument(e,r,n){return r=r??It.parse(e.uri),$e.CancellationToken.is(n)?this.createAsync(r,e,n):this.create(r,e,n)}fromString(e,r,n){return $e.CancellationToken.is(n)?this.createAsync(r,e,n):this.create(r,e,n)}fromModel(e,r){return this.create(r,{$model:e})}create(e,r,n){if(typeof r=="string"){const a=this.parse(e,r,n);return this.createLangiumDocument(a,e,void 0,r)}else if("$model"in r){const a={value:r.$model,parserErrors:[],lexerErrors:[]};return this.createLangiumDocument(a,e)}else{const a=this.parse(e,r.getText(),n);return this.createLangiumDocument(a,e,r)}}async createAsync(e,r,n){if(typeof r=="string"){const a=await this.parseAsync(e,r,n);return this.createLangiumDocument(a,e,void 0,r)}else{const a=await this.parseAsync(e,r.getText(),n);return this.createLangiumDocument(a,e,r)}}createLangiumDocument(e,r,n,a){let i;if(n)i={parseResult:e,uri:r,state:Q.Parsed,references:[],textDocument:n};else{const o=this.createTextDocumentGetter(r,a);i={parseResult:e,uri:r,state:Q.Parsed,references:[],get textDocument(){return o()}}}return e.value.$document=i,i}async update(e,r){const n=e.parseResult.value.$cstNode?.root.fullText,a=this.textDocuments?.get(e.uri.toString()),i=a?a.getText():await this.fileSystemProvider.readFile(e.uri);if(a)Object.defineProperty(e,"textDocument",{value:a});else{const o=this.createTextDocumentGetter(e.uri,i);Object.defineProperty(e,"textDocument",{get:o})}return n!==i&&(e.parseResult=await this.parseAsync(e.uri,i,r),e.parseResult.value.$document=e),e.state=Q.Parsed,e}parse(e,r,n){return this.serviceRegistry.getServices(e).parser.LangiumParser.parse(r,n)}parseAsync(e,r,n){return this.serviceRegistry.getServices(e).parser.AsyncParser.parse(r,n)}createTextDocumentGetter(e,r){const n=this.serviceRegistry;let a;return()=>a??(a=Sf.create(e.toString(),n.getServices(e).LanguageMetaData.languageId,0,r??""))}},s(Es,"DefaultLangiumDocumentFactory"),Es),Cs,WN=(Cs=class{constructor(e){this.documentTrie=new jg,this.services=e,this.langiumDocumentFactory=e.workspace.LangiumDocumentFactory,this.documentBuilder=()=>e.workspace.DocumentBuilder}get all(){return de(this.documentTrie.all())}addDocument(e){const r=e.uri.toString();if(this.documentTrie.has(r))throw new Error(`A document with the URI '${r}' is already present.`);this.documentTrie.insert(r,e)}getDocument(e){const r=e.toString();return this.documentTrie.find(r)}getDocuments(e){const r=e.toString();return this.documentTrie.findAll(r)}async getOrCreateDocument(e,r){let n=this.getDocument(e);return n||(n=await this.langiumDocumentFactory.fromUri(e,r),this.addDocument(n),n)}createDocument(e,r,n){if(n)return this.langiumDocumentFactory.fromString(r,e,n).then(a=>(this.addDocument(a),a));{const a=this.langiumDocumentFactory.fromString(r,e);return this.addDocument(a),a}}hasDocument(e){return this.documentTrie.has(e.toString())}invalidateDocument(e){const r=e.toString(),n=this.documentTrie.find(r);return n&&this.documentBuilder().resetToState(n,Q.Changed),n}deleteDocument(e){const r=e.toString(),n=this.documentTrie.find(r);return n&&(n.state=Q.Changed,this.documentTrie.delete(r)),n}deleteDocuments(e){const r=e.toString(),n=this.documentTrie.findAll(r);for(const a of n)a.state=Q.Changed;return this.documentTrie.delete(r),n}},s(Cs,"DefaultLangiumDocuments"),Cs),vn=Symbol("RefResolving"),bs,VN=(bs=class{constructor(e){this.reflection=e.shared.AstReflection,this.langiumDocuments=()=>e.shared.workspace.LangiumDocuments,this.scopeProvider=e.references.ScopeProvider,this.astNodeLocator=e.workspace.AstNodeLocator,this.profiler=e.shared.profilers.LangiumProfiler,this.languageId=e.LanguageMetaData.languageId}async link(e,r=$e.CancellationToken.None){if(this.profiler?.isActive("linking")){const n=this.profiler.createTask("linking",this.languageId);n.start();try{for(const a of qt(e.parseResult.value))await Ye(r),Xo(a).forEach(i=>{const o=`${a.$type}:${i.property}`;n.startSubTask(o);try{this.doLink(i,e)}finally{n.stopSubTask(o)}})}finally{n.stop()}}else for(const n of qt(e.parseResult.value))await Ye(r),Xo(n).forEach(a=>this.doLink(a,e))}doLink(e,r){const n=e.reference;if("_ref"in n&&n._ref===void 0){n._ref=vn;try{const a=this.getCandidate(e);if(An(a))n._ref=a;else{n._nodeDescription=a;const i=this.loadAstNode(a);n._ref=i??this.createLinkingError(e,a)}}catch(a){console.error(`An error occurred while resolving reference to '${n.$refText}':`,a);const i=a.message??String(a);n._ref={info:e,message:`An error occurred while resolving reference to '${n.$refText}': ${i}`}}r.references.push(n)}else if("_items"in n&&n._items===void 0){n._items=vn;try{const a=this.getCandidates(e),i=[];if(An(a))n._linkingError=a;else for(const o of a){const u=this.loadAstNode(o);u&&i.push({ref:u,$nodeDescription:o})}n._items=i}catch(a){n._linkingError={info:e,message:`An error occurred while resolving reference to '${n.$refText}': ${a}`},n._items=[]}r.references.push(n)}}unlink(e){for(const r of e.references)"_ref"in r?(r._ref=void 0,delete r._nodeDescription):"_items"in r&&(r._items=void 0,delete r._linkingError);e.references=[]}getCandidate(e){return this.scopeProvider.getScope(e).getElement(e.reference.$refText)??this.createLinkingError(e)}getCandidates(e){const n=this.scopeProvider.getScope(e).getElements(e.reference.$refText).distinct(a=>`${a.documentUri}#${a.path}`).toArray();return n.length>0?n:this.createLinkingError(e)}buildReference(e,r,n,a){const i=this,o={$refNode:n,$refText:a,_ref:void 0,get ref(){if(Be(this._ref))return this._ref;if(bh(this._nodeDescription)){const u=i.loadAstNode(this._nodeDescription);this._ref=u??i.createLinkingError({reference:o,container:e,property:r},this._nodeDescription)}else if(this._ref===void 0){this._ref=vn;const u=Ya(e).$document,l=i.getLinkedNode({reference:o,container:e,property:r});if(l.error&&u&&u.state<Q.ComputedScopes)return this._ref=void 0;this._ref=l.node??l.error,this._nodeDescription=l.descr,u?.references.push(this)}else this._ref===vn&&i.throwCyclicReferenceError(e,r,a);return Be(this._ref)?this._ref:void 0},get $nodeDescription(){return this._nodeDescription},get error(){return An(this._ref)?this._ref:void 0}};return o}buildMultiReference(e,r,n,a){const i=this,o={$refNode:n,$refText:a,_items:void 0,get items(){if(Array.isArray(this._items))return this._items;if(this._items===void 0){this._items=vn;const u=Ya(e).$document,l=i.getCandidates({reference:o,container:e,property:r}),c=[];if(An(l))this._linkingError=l;else for(const f of l){const d=i.loadAstNode(f);d&&c.push({ref:d,$nodeDescription:f})}this._items=c,u?.references.push(this)}else this._items===vn&&i.throwCyclicReferenceError(e,r,a);return Array.isArray(this._items)?this._items:[]},get error(){if(this._linkingError)return this._linkingError;if(!(this.items.length>0))return this._linkingError=i.createLinkingError({reference:o,container:e,property:r})}};return o}throwCyclicReferenceError(e,r,n){throw new Error(`Cyclic reference resolution detected: ${this.astNodeLocator.getAstNodePath(e)}/${r} (symbol '${n}')`)}getLinkedNode(e){try{const r=this.getCandidate(e);if(An(r))return{error:r};const n=this.loadAstNode(r);return n?{node:n,descr:r}:{descr:r,error:this.createLinkingError(e,r)}}catch(r){console.error(`An error occurred while resolving reference to '${e.reference.$refText}':`,r);const n=r.message??String(r);return{error:{info:e,message:`An error occurred while resolving reference to '${e.reference.$refText}': ${n}`}}}}loadAstNode(e){if(e.node)return e.node;const r=this.langiumDocuments().getDocument(e.documentUri);if(r)return this.astNodeLocator.getAstNode(r.parseResult.value,e.path)}createLinkingError(e,r){const n=Ya(e.container).$document;n&&n.state<Q.ComputedScopes&&console.warn(`Attempted reference resolution before document reached ComputedScopes state (${n.uri}).`);const a=this.reflection.getReferenceType(e);return{info:e,message:`Could not resolve reference to ${a} named '${e.reference.$refText}'.`,targetDescription:r}}},s(bs,"DefaultLinker"),bs);function Bg(t){return typeof t.name=="string"}s(Bg,"isNamed");var _s,qN=(_s=class{getName(e){if(Bg(e))return e.name}getNameNode(e){return Hf(e.$cstNode,"name")}},s(_s,"DefaultNameProvider"),_s),Ss,HN=(Ss=class{constructor(e){this.nameProvider=e.references.NameProvider,this.index=e.shared.workspace.IndexManager,this.nodeLocator=e.workspace.AstNodeLocator,this.documents=e.shared.workspace.LangiumDocuments,this.hasMultiReference=qt(e.Grammar).some(r=>Xn(r)&&r.isMulti)}findDeclarations(e){if(e){const r=yy(e),n=e.astNode;if(r&&n){const a=n[r.feature];if(ft(a)||fr(a))return Wc(a);if(Array.isArray(a)){for(const i of a)if((ft(i)||fr(i))&&i.$refNode&&i.$refNode.offset<=e.offset&&i.$refNode.end>=e.end)return Wc(i)}}if(n){const a=this.nameProvider.getNameNode(n);if(a&&(a===e||Yh(e,a)))return this.getSelfNodes(n)}}return[]}getSelfNodes(e){if(this.hasMultiReference){const r=this.index.findAllReferences(e,this.nodeLocator.getAstNodePath(e)),n=this.getNodeFromReferenceDescription(r.head());if(n){for(const a of Xo(n))if(fr(a.reference)&&a.reference.items.some(i=>i.ref===e))return a.reference.items.map(i=>i.ref)}return[e]}else return[e]}getNodeFromReferenceDescription(e){if(!e)return;const r=this.documents.getDocument(e.sourceUri);if(r)return this.nodeLocator.getAstNode(r.parseResult.value,e.sourcePath)}findDeclarationNodes(e){const r=this.findDeclarations(e),n=[];for(const a of r){const i=this.nameProvider.getNameNode(a)??a.$cstNode;i&&n.push(i)}return n}findReferences(e,r){const n=[];r.includeDeclaration&&n.push(...this.getSelfReferences(e));let a=this.index.findAllReferences(e,this.nodeLocator.getAstNodePath(e));return r.documentUri&&(a=a.filter(i=>dt.equals(i.sourceUri,r.documentUri))),n.push(...a),de(n)}getSelfReferences(e){const r=this.getSelfNodes(e),n=[];for(const a of r){const i=this.nameProvider.getNameNode(a);if(i){const o=Vt(a),u=this.nodeLocator.getAstNodePath(a);n.push({sourceUri:o.uri,sourcePath:u,targetUri:o.uri,targetPath:u,segment:Qo(i),local:!0})}}return n}},s(Ss,"DefaultReferences"),Ss),ws,xr=(ws=class{constructor(e){if(this.map=new Map,e)for(const[r,n]of e)this.add(r,n)}get size(){return Tu.sum(de(this.map.values()).map(e=>e.length))}clear(){this.map.clear()}delete(e,r){if(r===void 0)return this.map.delete(e);{const n=this.map.get(e);if(n){const a=n.indexOf(r);if(a>=0)return n.length===1?this.map.delete(e):n.splice(a,1),!0}return!1}}get(e){return this.map.get(e)??[]}getStream(e){const r=this.map.get(e);return r?de(r):qo}has(e,r){if(r===void 0)return this.map.has(e);{const n=this.map.get(e);return n?n.indexOf(r)>=0:!1}}add(e,r){return this.map.has(e)?this.map.get(e).push(r):this.map.set(e,[r]),this}addAll(e,r){return this.map.has(e)?this.map.get(e).push(...r):this.map.set(e,Array.from(r)),this}forEach(e){this.map.forEach((r,n)=>r.forEach(a=>e(a,n,this)))}[Symbol.iterator](){return this.entries().iterator()}entries(){return de(this.map.entries()).flatMap(([e,r])=>r.map(n=>[e,n]))}keys(){return de(this.map.keys())}values(){return de(this.map.values()).flat()}entriesGroupedByKey(){return de(this.map.entries())}},s(ws,"MultiMap"),ws),Is,If=(Is=class{get size(){return this.map.size}constructor(e){if(this.map=new Map,this.inverse=new Map,e)for(const[r,n]of e)this.set(r,n)}clear(){this.map.clear(),this.inverse.clear()}set(e,r){return this.map.set(e,r),this.inverse.set(r,e),this}get(e){return this.map.get(e)}getKey(e){return this.inverse.get(e)}delete(e){const r=this.map.get(e);return r!==void 0?(this.map.delete(e),this.inverse.delete(r),!0):!1}},s(Is,"BiMap"),Is),Ns,YN=(Ns=class{constructor(e){this.nameProvider=e.references.NameProvider,this.descriptions=e.workspace.AstNodeDescriptionProvider}async collectExportedSymbols(e,r=$e.CancellationToken.None){return this.collectExportedSymbolsForNode(e.parseResult.value,e,void 0,r)}async collectExportedSymbolsForNode(e,r,n=Gu,a=$e.CancellationToken.None){const i=[];this.addExportedSymbol(e,i,r);for(const o of n(e))await Ye(a),this.addExportedSymbol(o,i,r);return i}addExportedSymbol(e,r,n){const a=this.nameProvider.getName(e);a&&r.push(this.descriptions.createDescription(e,a,n))}async collectLocalSymbols(e,r=$e.CancellationToken.None){const n=e.parseResult.value,a=new xr;for(const i of Mr(n))await Ye(r),this.addLocalSymbol(i,e,a);return a}addLocalSymbol(e,r,n){const a=e.$container;if(a){const i=this.nameProvider.getName(e);i&&n.add(a,this.descriptions.createDescription(e,i,r))}}},s(Ns,"DefaultScopeComputation"),Ns),Ps,Xm=(Ps=class{constructor(e,r,n){this.elements=e,this.outerScope=r,this.caseInsensitive=n?.caseInsensitive??!1,this.concatOuterScope=n?.concatOuterScope??!0}getAllElements(){return this.outerScope?this.elements.concat(this.outerScope.getAllElements()):this.elements}getElement(e){const r=this.caseInsensitive?e.toLowerCase():e,n=this.caseInsensitive?this.elements.find(a=>a.name.toLowerCase()===r):this.elements.find(a=>a.name===e);if(n)return n;if(this.outerScope)return this.outerScope.getElement(e)}getElements(e){const r=this.caseInsensitive?e.toLowerCase():e,n=this.caseInsensitive?this.elements.filter(a=>a.name.toLowerCase()===r):this.elements.filter(a=>a.name===e);return(this.concatOuterScope||n.isEmpty())&&this.outerScope?n.concat(this.outerScope.getElements(e)):n}},s(Ps,"StreamScope"),Ps),ks,hB=(ks=class{constructor(e,r,n){this.elements=new Map,this.caseInsensitive=n?.caseInsensitive??!1,this.concatOuterScope=n?.concatOuterScope??!0;for(const a of e){const i=this.caseInsensitive?a.name.toLowerCase():a.name;this.elements.set(i,a)}this.outerScope=r}getElement(e){const r=this.caseInsensitive?e.toLowerCase():e,n=this.elements.get(r);if(n)return n;if(this.outerScope)return this.outerScope.getElement(e)}getElements(e){const r=this.caseInsensitive?e.toLowerCase():e,n=this.elements.get(r),a=n?[n]:[];return(this.concatOuterScope||a.length>0)&&this.outerScope?de(a).concat(this.outerScope.getElements(e)):de(a)}getAllElements(){let e=de(this.elements.values());return this.outerScope&&(e=e.concat(this.outerScope.getAllElements())),e}},s(ks,"MapScope"),ks),Os,XN=(Os=class{constructor(e,r,n){this.elements=new xr,this.caseInsensitive=n?.caseInsensitive??!1,this.concatOuterScope=n?.concatOuterScope??!0;for(const a of e){const i=this.caseInsensitive?a.name.toLowerCase():a.name;this.elements.add(i,a)}this.outerScope=r}getElement(e){const r=this.caseInsensitive?e.toLowerCase():e,n=this.elements.get(r)[0];if(n)return n;if(this.outerScope)return this.outerScope.getElement(e)}getElements(e){const r=this.caseInsensitive?e.toLowerCase():e,n=this.elements.get(r);return(this.concatOuterScope||n.length===0)&&this.outerScope?de(n).concat(this.outerScope.getElements(e)):de(n)}getAllElements(){let e=de(this.elements.values());return this.outerScope&&(e=e.concat(this.outerScope.getAllElements())),e}},s(Os,"MultiMapScope"),Os),yB={getElement(){},getElements(){return qo},getAllElements(){return qo}},Ls,Md=(Ls=class{constructor(){this.toDispose=[],this.isDisposed=!1}onDispose(e){this.toDispose.push(e)}dispose(){this.throwIfDisposed(),this.clear(),this.isDisposed=!0,this.toDispose.forEach(e=>e.dispose())}throwIfDisposed(){if(this.isDisposed)throw new Error("This cache has already been disposed")}},s(Ls,"DisposableCache"),Ls),Ds,Ug=(Ds=class extends Md{constructor(){super(...arguments),this.cache=new Map}has(e){return this.throwIfDisposed(),this.cache.has(e)}set(e,r){this.throwIfDisposed(),this.cache.set(e,r)}get(e,r){if(this.throwIfDisposed(),this.cache.has(e))return this.cache.get(e);if(r){const n=r();return this.cache.set(e,n),n}else return}delete(e){return this.throwIfDisposed(),this.cache.delete(e)}clear(){this.throwIfDisposed(),this.cache.clear()}},s(Ds,"SimpleCache"),Ds),xs,Gd=(xs=class extends Md{constructor(e){super(),this.cache=new Map,this.converter=e??(r=>r)}has(e,r){return this.throwIfDisposed(),this.cacheForContext(e).has(r)}set(e,r,n){this.throwIfDisposed(),this.cacheForContext(e).set(r,n)}get(e,r,n){this.throwIfDisposed();const a=this.cacheForContext(e);if(a.has(r))return a.get(r);if(n){const i=n();return a.set(r,i),i}else return}delete(e,r){return this.throwIfDisposed(),this.cacheForContext(e).delete(r)}clear(e){if(this.throwIfDisposed(),e){const r=this.converter(e);this.cache.delete(r)}else this.cache.clear()}cacheForContext(e){const r=this.converter(e);let n=this.cache.get(r);return n||(n=new Map,this.cache.set(r,n)),n}},s(xs,"ContextCache"),xs),Ms,JN=(Ms=class extends Gd{constructor(e,r){super(n=>n.toString()),r?(this.toDispose.push(e.workspace.DocumentBuilder.onDocumentPhase(r,n=>{this.clear(n.uri.toString())})),this.toDispose.push(e.workspace.DocumentBuilder.onUpdate((n,a)=>{for(const i of a)this.clear(i)}))):this.toDispose.push(e.workspace.DocumentBuilder.onUpdate((n,a)=>{const i=n.concat(a);for(const o of i)this.clear(o)}))}},s(Ms,"DocumentCache"),Ms),Gs,Kg=(Gs=class extends Ug{constructor(e,r){super(),r?(this.toDispose.push(e.workspace.DocumentBuilder.onBuildPhase(r,()=>{this.clear()})),this.toDispose.push(e.workspace.DocumentBuilder.onUpdate((n,a)=>{a.length>0&&this.clear()}))):this.toDispose.push(e.workspace.DocumentBuilder.onUpdate(()=>{this.clear()}))}},s(Gs,"WorkspaceCache"),Gs),Fs,ZN=(Fs=class{constructor(e){this.reflection=e.shared.AstReflection,this.nameProvider=e.references.NameProvider,this.descriptions=e.workspace.AstNodeDescriptionProvider,this.indexManager=e.shared.workspace.IndexManager,this.globalScopeCache=new Kg(e.shared)}getScope(e){const r=[],n=this.reflection.getReferenceType(e),a=Vt(e.container).localSymbols;if(a){let o=e.container;do a.has(o)&&r.push(a.getStream(o).filter(u=>this.reflection.isSubtype(u.type,n))),o=o.$container;while(o)}let i=this.getGlobalScope(n,e);for(let o=r.length-1;o>=0;o--)i=this.createScope(r[o],i);return i}createScope(e,r,n){return new Xm(de(e),r,n)}createScopeForNodes(e,r,n){const a=de(e).map(i=>{const o=this.nameProvider.getName(i);if(o)return this.descriptions.createDescription(i,o)}).nonNullable();return new Xm(a,r,n)}getGlobalScope(e,r){return this.globalScopeCache.get(e,()=>new XN(this.indexManager.allElements(e)))}},s(Fs,"DefaultScopeProvider"),Fs);function Wg(t){return typeof t.$comment=="string"}s(Wg,"isAstNodeWithComment");function Jm(t){return typeof t=="object"&&!!t&&("$ref"in t||"$error"in t)}s(Jm,"isIntermediateReference");var zs,QN=(zs=class{constructor(e){this.ignoreProperties=new Set(["$container","$containerProperty","$containerIndex","$document","$cstNode"]),this.langiumDocuments=e.shared.workspace.LangiumDocuments,this.astNodeLocator=e.workspace.AstNodeLocator,this.nameProvider=e.references.NameProvider,this.commentProvider=e.documentation.CommentProvider}serialize(e,r){const n=r??{},a=r?.replacer,i=s((u,l)=>this.replacer(u,l,n),"defaultReplacer"),o=a?(u,l)=>a(u,l,i):i;try{return this.currentDocument=Vt(e),JSON.stringify(e,o,r?.space)}finally{this.currentDocument=void 0}}deserialize(e,r){const n=r??{},a=JSON.parse(e);return this.linkNode(a,a,n),a}replacer(e,r,{refText:n,sourceText:a,textRegions:i,comments:o,uriConverter:u}){if(!this.ignoreProperties.has(e))if(ft(r)){const l=r.ref,c=n?r.$refText:void 0;if(l){const f=Vt(l);let d="";this.currentDocument&&this.currentDocument!==f&&(u?d=u(f.uri,l):d=f.uri.toString());const p=this.astNodeLocator.getAstNodePath(l);return{$ref:`${d}#${p}`,$refText:c}}else return{$error:r.error?.message??"Could not resolve reference",$refText:c}}else if(fr(r)){const l=n?r.$refText:void 0,c=[];for(const f of r.items){const d=f.ref,p=Vt(f.ref);let y="";this.currentDocument&&this.currentDocument!==p&&(u?y=u(p.uri,d):y=p.uri.toString());const h=this.astNodeLocator.getAstNodePath(d);c.push(`${y}#${h}`)}return{$refs:c,$refText:l}}else if(Be(r)){let l;if(i&&(l=this.addAstNodeRegionWithAssignmentsTo({...r}),(!e||r.$document)&&l?.$textRegion&&(l.$textRegion.documentURI=this.currentDocument?.uri.toString())),a&&!e&&(l??(l={...r}),l.$sourceText=r.$cstNode?.text),o){l??(l={...r});const c=this.commentProvider.getComment(r);c&&(l.$comment=c.replace(/\r/g,""))}return l??r}else return r}addAstNodeRegionWithAssignmentsTo(e){const r=s(n=>({offset:n.offset,end:n.end,length:n.length,range:n.range}),"createDocumentSegment");if(e.$cstNode){const n=e.$textRegion=r(e.$cstNode),a=n.assignments={};return Object.keys(e).filter(i=>!i.startsWith("$")).forEach(i=>{const o=my(e.$cstNode,i).map(r);o.length!==0&&(a[i]=o)}),e}}linkNode(e,r,n,a,i,o){for(const[l,c]of Object.entries(e))if(Array.isArray(c))for(let f=0;f<c.length;f++){const d=c[f];Jm(d)?c[f]=this.reviveReference(e,l,r,d,n):Be(d)&&this.linkNode(d,r,n,e,l,f)}else Jm(c)?e[l]=this.reviveReference(e,l,r,c,n):Be(c)&&this.linkNode(c,r,n,e,l);const u=e;u.$container=a,u.$containerProperty=i,u.$containerIndex=o}reviveReference(e,r,n,a,i){let o=a.$refText,u=a.$error,l;if(a.$ref){const c=this.getRefNode(n,a.$ref,i.uriConverter);if(Be(c))return o||(o=this.nameProvider.getName(c)),{$refText:o??"",ref:c};u=c}else if(a.$refs){const c=[];for(const f of a.$refs){const d=this.getRefNode(n,f,i.uriConverter);Be(d)&&c.push({ref:d})}if(c.length===0)l={$refText:o??"",items:c},u??(u="Could not resolve multi-reference");else return{$refText:o??"",items:c}}if(u)return l??(l={$refText:o??"",ref:void 0}),l.error={info:{container:e,property:r,reference:l},message:u},l}getRefNode(e,r,n){try{const a=r.indexOf("#");if(a===0){const l=this.astNodeLocator.getAstNode(e,r.substring(1));return l||"Could not resolve path: "+r}if(a<0){const l=n?n(r):It.parse(r),c=this.langiumDocuments.getDocument(l);return c?c.parseResult.value:"Could not find document for URI: "+r}const i=n?n(r.substring(0,a)):It.parse(r.substring(0,a)),o=this.langiumDocuments.getDocument(i);if(!o)return"Could not find document for URI: "+r;if(a===r.length-1)return o.parseResult.value;const u=this.astNodeLocator.getAstNode(o.parseResult.value,r.substring(a+1));return u||"Could not resolve URI: "+r}catch(a){return String(a)}}},s(zs,"DefaultJsonSerializer"),zs),js,eP=(js=class{get map(){return this.fileExtensionMap}constructor(e){this.languageIdMap=new Map,this.fileExtensionMap=new Map,this.fileNameMap=new Map,this.textDocuments=e?.workspace.TextDocuments}register(e){const r=e.LanguageMetaData;for(const n of r.fileExtensions)this.fileExtensionMap.has(n)&&console.warn(`The file extension ${n} is used by multiple languages. It is now assigned to '${r.languageId}'.`),this.fileExtensionMap.set(n,e);if(r.fileNames)for(const n of r.fileNames)this.fileNameMap.has(n)&&console.warn(`The file name ${n} is used by multiple languages. It is now assigned to '${r.languageId}'.`),this.fileNameMap.set(n,e);this.languageIdMap.set(r.languageId,e)}getServices(e){if(this.languageIdMap.size===0)throw new Error("The service registry is empty. Use `register` to register the services of a language.");const r=this.textDocuments?.get(e)?.languageId;if(r!==void 0){const o=this.languageIdMap.get(r);if(o)return o}const n=dt.extname(e),a=dt.basename(e),i=this.fileNameMap.get(a)??this.fileExtensionMap.get(n);if(!i)throw r?new Error(`The service registry contains no services for the extension '${n}' for language '${r}'.`):new Error(`The service registry contains no services for the extension '${n}'.`);return i}hasServices(e){try{return this.getServices(e),!0}catch{return!1}}get all(){return Array.from(this.languageIdMap.values())}},s(js,"DefaultServiceRegistry"),js);function xn(t){return{code:t}}s(xn,"diagnosticData");var Nf;(function(t){t.defaults=["fast","slow","built-in"],t.all=t.defaults})(Nf||(Nf={}));var Bs,tP=(Bs=class{constructor(e){this.entries=new xr,this.knownCategories=new Set(Nf.defaults),this.entriesBefore=[],this.entriesAfter=[],this.reflection=e.shared.AstReflection}register(e,r=this,n="fast"){if(n==="built-in")throw new Error("The 'built-in' category is reserved for lexer, parser, and linker errors.");this.knownCategories.add(n);for(const[a,i]of Object.entries(e)){const o=i;if(Array.isArray(o))for(const u of o){const l={check:this.wrapValidationException(u,r),category:n};this.addEntry(a,l)}else if(typeof o=="function"){const u={check:this.wrapValidationException(o,r),category:n};this.addEntry(a,u)}else rn()}}wrapValidationException(e,r){return async(n,a,i)=>{await this.handleException(()=>e.call(r,n,a,i),"An error occurred during validation",a,n)}}async handleException(e,r,n,a){try{await e()}catch(i){if(da(i))throw i;console.error(`${r}:`,i),i instanceof Error&&i.stack&&console.error(i.stack);const o=i instanceof Error?i.message:String(i);n("error",`${r}: ${o}`,{node:a})}}addEntry(e,r){if(e==="AstNode"){this.entries.add("AstNode",r);return}for(const n of this.reflection.getAllSubTypes(e))this.entries.add(n,r)}getChecks(e,r){let n=de(this.entries.get(e)).concat(this.entries.get("AstNode"));return r&&(n=n.filter(a=>r.includes(a.category))),n.map(a=>a.check)}registerBeforeDocument(e,r=this){this.entriesBefore.push(this.wrapPreparationException(e,"An error occurred during set-up of the validation",r))}registerAfterDocument(e,r=this){this.entriesAfter.push(this.wrapPreparationException(e,"An error occurred during tear-down of the validation",r))}wrapPreparationException(e,r,n){return async(a,i,o,u)=>{await this.handleException(()=>e.call(n,a,i,o,u),r,i,a)}}get checksBefore(){return this.entriesBefore}get checksAfter(){return this.entriesAfter}getAllValidationCategories(e){return this.knownCategories}},s(Bs,"ValidationRegistry"),Bs),rP=Object.freeze({validateNode:!0,validateChildren:!0}),Us,nP=(Us=class{constructor(e){this.validationRegistry=e.validation.ValidationRegistry,this.metadata=e.LanguageMetaData,this.profiler=e.shared.profilers.LangiumProfiler,this.languageId=e.LanguageMetaData.languageId}async validateDocument(e,r={},n=$e.CancellationToken.None){const a=e.parseResult,i=[];if(await Ye(n),(!r.categories||r.categories.includes("built-in"))&&(this.processLexingErrors(a,i,r),r.stopAfterLexingErrors&&i.some(o=>o.data?.code===Mt.LexingError)||(this.processParsingErrors(a,i,r),r.stopAfterParsingErrors&&i.some(o=>o.data?.code===Mt.ParsingError))||(this.processLinkingErrors(e,i,r),r.stopAfterLinkingErrors&&i.some(o=>o.data?.code===Mt.LinkingError))))return i;try{i.push(...await this.validateAst(a.value,r,n))}catch(o){if(da(o))throw o;console.error("An error occurred during validation:",o)}return await Ye(n),i}processLexingErrors(e,r,n){const a=[...e.lexerErrors,...e.lexerReport?.diagnostics??[]];for(const i of a){const o=i.severity??"error",u={severity:gu(o),range:{start:{line:i.line-1,character:i.column-1},end:{line:i.line-1,character:i.column+i.length-1}},message:i.message,data:qg(o),source:this.getSource()};r.push(u)}}processParsingErrors(e,r,n){for(const a of e.parserErrors){let i;if(isNaN(a.token.startOffset)){if("previousToken"in a){const o=a.previousToken;if(isNaN(o.startOffset)){const u={line:0,character:0};i={start:u,end:u}}else{const u={line:o.endLine-1,character:o.endColumn};i={start:u,end:u}}}}else i=$u(a.token);if(i){const o={severity:gu("error"),range:i,message:a.message,data:xn(Mt.ParsingError),source:this.getSource()};r.push(o)}}}processLinkingErrors(e,r,n){for(const a of e.references){const i=a.error;if(i){const o={node:i.info.container,range:a.$refNode?.range,property:i.info.property,index:i.info.index,data:{code:Mt.LinkingError,containerType:i.info.container.$type,property:i.info.property,refText:i.info.reference.$refText}};r.push(this.toDiagnostic("error",i.message,o))}}}async validateAst(e,r,n=$e.CancellationToken.None){const a=[],i=s((o,u,l)=>{a.push(this.toDiagnostic(o,u,l))},"acceptor");return await this.validateAstBefore(e,r,i,n),await this.validateAstNodes(e,r,i,n),await this.validateAstAfter(e,r,i,n),a}async validateAstBefore(e,r,n,a=$e.CancellationToken.None){const i=this.validationRegistry.checksBefore;for(const o of i)await Ye(a),await o(e,n,r.categories??[],a)}async validateAstNodes(e,r,n,a=$e.CancellationToken.None){if(this.profiler?.isActive("validating")){const i=this.profiler.createTask("validating",this.languageId);i.start();try{const o=qt(e).iterator();for(const u of o){i.startSubTask(u.$type);const l=this.validateSingleNodeOptions(u,r);if(l.validateNode)try{const c=this.validationRegistry.getChecks(u.$type,r.categories);for(const f of c)await f(u,n,a)}finally{i.stopSubTask(u.$type)}l.validateChildren||o.prune()}}finally{i.stop()}}else{const i=qt(e).iterator();for(const o of i){await Ye(a);const u=this.validateSingleNodeOptions(o,r);if(u.validateNode){const l=this.validationRegistry.getChecks(o.$type,r.categories);for(const c of l)await c(o,n,a)}u.validateChildren||i.prune()}}}validateSingleNodeOptions(e,r){return rP}async validateAstAfter(e,r,n,a=$e.CancellationToken.None){const i=this.validationRegistry.checksAfter;for(const o of i)await Ye(a),await o(e,n,r.categories??[],a)}toDiagnostic(e,r,n){return{message:r,range:Vg(n),severity:gu(e),code:n.code,codeDescription:n.codeDescription,tags:n.tags,relatedInformation:n.relatedInformation,data:n.data,source:this.getSource()}}getSource(){return this.metadata.languageId}},s(Us,"DefaultDocumentValidator"),Us);function Vg(t){if(t.range)return t.range;let e;return typeof t.property=="string"?e=Hf(t.node.$cstNode,t.property,t.index):typeof t.keyword=="string"&&(e=hy(t.node.$cstNode,t.keyword,t.index)),e??(e=t.node.$cstNode),e?e.range:{start:{line:0,character:0},end:{line:0,character:0}}}s(Vg,"getDiagnosticRange");function gu(t){switch(t){case"error":return 1;case"warning":return 2;case"info":return 3;case"hint":return 4;default:throw new Error("Invalid diagnostic severity: "+t)}}s(gu,"toDiagnosticSeverity");function qg(t){switch(t){case"error":return xn(Mt.LexingError);case"warning":return xn(Mt.LexingWarning);case"info":return xn(Mt.LexingInfo);case"hint":return xn(Mt.LexingHint);default:throw new Error("Invalid diagnostic severity: "+t)}}s(qg,"toDiagnosticData");var Mt;(function(t){t.LexingError="lexing-error",t.LexingWarning="lexing-warning",t.LexingInfo="lexing-info",t.LexingHint="lexing-hint",t.ParsingError="parsing-error",t.LinkingError="linking-error"})(Mt||(Mt={}));var Ks,aP=(Ks=class{constructor(e){this.astNodeLocator=e.workspace.AstNodeLocator,this.nameProvider=e.references.NameProvider}createDescription(e,r,n){const a=n??Vt(e);r??(r=this.nameProvider.getName(e));const i=this.astNodeLocator.getAstNodePath(e);if(!r)throw new Error(`Node at path ${i} has no name.`);let o;const u=s(()=>o??(o=Qo(this.nameProvider.getNameNode(e)??e.$cstNode)),"nameSegmentGetter");return{node:e,name:r,get nameSegment(){return u()},selectionSegment:Qo(e.$cstNode),type:e.$type,documentUri:a.uri,path:i}}},s(Ks,"DefaultAstNodeDescriptionProvider"),Ks),Ws,iP=(Ws=class{constructor(e){this.nodeLocator=e.workspace.AstNodeLocator}async createDescriptions(e,r=$e.CancellationToken.None){const n=[],a=e.parseResult.value;for(const i of qt(a))await Ye(r),Xo(i).forEach(o=>{o.reference.error||n.push(...this.createInfoDescriptions(o))});return n}createInfoDescriptions(e){const r=e.reference;if(r.error||!r.$refNode)return[];let n=[];ft(r)&&r.$nodeDescription?n=[r.$nodeDescription]:fr(r)&&(n=r.items.map(l=>l.$nodeDescription).filter(l=>l!==void 0));const a=Vt(e.container).uri,i=this.nodeLocator.getAstNodePath(e.container),o=[],u=Qo(r.$refNode);for(const l of n)o.push({sourceUri:a,sourcePath:i,targetUri:l.documentUri,targetPath:l.path,segment:u,local:dt.equals(l.documentUri,a)});return o}},s(Ws,"DefaultReferenceDescriptionProvider"),Ws),Vs,sP=(Vs=class{constructor(){this.segmentSeparator="/",this.indexSeparator="@"}getAstNodePath(e){if(e.$container){const r=this.getAstNodePath(e.$container),n=this.getPathSegment(e);return r+this.segmentSeparator+n}return""}getPathSegment({$containerProperty:e,$containerIndex:r}){if(!e)throw new Error("Missing '$containerProperty' in AST node.");return r!==void 0?e+this.indexSeparator+r:e}getAstNode(e,r){return r.split(this.segmentSeparator).reduce((a,i)=>{if(!a||i.length===0)return a;const o=i.indexOf(this.indexSeparator);if(o>0){const u=i.substring(0,o),l=parseInt(i.substring(o+1));return a[u]?.[l]}return a[i]},e)}},s(Vs,"DefaultAstNodeLocator"),Vs),Fd={};Of(Fd,Rh(al()));var qs,oP=(qs=class{constructor(e){this._ready=new Dr,this.onConfigurationSectionUpdateEmitter=new Fd.Emitter,this.settings={},this.workspaceConfig=!1,this.serviceRegistry=e.ServiceRegistry}get ready(){return this._ready.promise}initialize(e){this.workspaceConfig=e.capabilities.workspace?.configuration??!1}async initialized(e){if(this.workspaceConfig){if(e.register){const r=this.serviceRegistry.all;e.register({section:r.map(n=>this.toSectionName(n.LanguageMetaData.languageId))})}if(e.fetchConfiguration){const r=this.serviceRegistry.all.map(a=>({section:this.toSectionName(a.LanguageMetaData.languageId)})),n=await e.fetchConfiguration(r);r.forEach((a,i)=>{this.updateSectionConfiguration(a.section,n[i])})}}this._ready.resolve()}updateConfiguration(e){typeof e.settings!="object"||e.settings===null||Object.entries(e.settings).forEach(([r,n])=>{this.updateSectionConfiguration(r,n),this.onConfigurationSectionUpdateEmitter.fire({section:r,configuration:n})})}updateSectionConfiguration(e,r){this.settings[e]=r}async getConfiguration(e,r){await this.ready;const n=this.toSectionName(e);if(this.settings[n])return this.settings[n][r]}toSectionName(e){return`${e}`}get onConfigurationSectionUpdate(){return this.onConfigurationSectionUpdateEmitter.event}},s(qs,"DefaultConfigurationProvider"),qs),uc=Rh(Xk()),Fn;(function(t){function e(r){return{dispose:s(async()=>await r(),"dispose")}}s(e,"create"),t.create=e})(Fn||(Fn={}));var Hs,lP=(Hs=class{constructor(e){this.updateBuildOptions={validation:{categories:["built-in","fast"]}},this.updateListeners=[],this.buildPhaseListeners=new xr,this.documentPhaseListeners=new xr,this.buildState=new Map,this.documentBuildWaiters=new Map,this.currentState=Q.Changed,this.langiumDocuments=e.workspace.LangiumDocuments,this.langiumDocumentFactory=e.workspace.LangiumDocumentFactory,this.textDocuments=e.workspace.TextDocuments,this.indexManager=e.workspace.IndexManager,this.fileSystemProvider=e.workspace.FileSystemProvider,this.workspaceManager=()=>e.workspace.WorkspaceManager,this.serviceRegistry=e.ServiceRegistry}async build(e,r={},n=$e.CancellationToken.None){for(const a of e){const i=a.uri.toString();if(a.state===Q.Validated){if(typeof r.validation=="boolean"&&r.validation)this.resetToState(a,Q.IndexedReferences);else if(typeof r.validation=="object"){const o=this.findMissingValidationCategories(a,r);o.length>0&&(this.buildState.set(i,{completed:!1,options:{validation:{categories:o}},result:this.buildState.get(i)?.result}),a.state=Q.IndexedReferences)}}else this.buildState.delete(i)}this.currentState=Q.Changed,await this.emitUpdate(e.map(a=>a.uri),[]),await this.buildDocuments(e,r,n)}async update(e,r,n=$e.CancellationToken.None){this.currentState=Q.Changed;const a=[];for(const l of r){const c=this.langiumDocuments.deleteDocuments(l);for(const f of c)a.push(f.uri),this.cleanUpDeleted(f)}const i=(await Promise.all(e.map(l=>this.findChangedUris(l)))).flat();for(const l of i){let c=this.langiumDocuments.getDocument(l);c===void 0&&(c=this.langiumDocumentFactory.fromModel({$type:"INVALID"},l),c.state=Q.Changed,this.langiumDocuments.addDocument(c)),this.resetToState(c,Q.Changed)}const o=de(i).concat(a).map(l=>l.toString()).toSet();this.langiumDocuments.all.filter(l=>!o.has(l.uri.toString())&&this.shouldRelink(l,o)).forEach(l=>this.resetToState(l,Q.ComputedScopes)),await this.emitUpdate(i,a),await Ye(n);const u=this.sortDocuments(this.langiumDocuments.all.filter(l=>l.state<Q.Validated||!this.buildState.get(l.uri.toString())?.completed||this.resultsAreIncomplete(l,this.updateBuildOptions)).toArray());await this.buildDocuments(u,this.updateBuildOptions,n)}resultsAreIncomplete(e,r){return this.findMissingValidationCategories(e,r).length>=1}findMissingValidationCategories(e,r){const n=this.buildState.get(e.uri.toString()),a=this.serviceRegistry.getServices(e.uri).validation.ValidationRegistry.getAllValidationCategories(e),i=n?.result?.validationChecks?new Set(n?.result?.validationChecks):n?.completed?a:new Set,o=r===void 0||r.validation===!0?a:typeof r.validation=="object"?r.validation.categories??a:[];return de(o).filter(u=>!i.has(u)).toArray()}async findChangedUris(e){if(this.langiumDocuments.getDocument(e)??this.textDocuments?.get(e))return[e];try{const n=await this.fileSystemProvider.stat(e);if(n.isDirectory)return await this.workspaceManager().searchFolder(e);if(this.workspaceManager().shouldIncludeEntry(n))return[e]}catch{}return[]}async emitUpdate(e,r){await Promise.all(this.updateListeners.map(n=>n(e,r)))}sortDocuments(e){let r=0,n=e.length-1;for(;r<n;){for(;r<e.length&&this.hasTextDocument(e[r]);)r++;for(;n>=0&&!this.hasTextDocument(e[n]);)n--;r<n&&([e[r],e[n]]=[e[n],e[r]])}return e}hasTextDocument(e){return!!this.textDocuments?.get(e.uri)}shouldRelink(e,r){return e.references.some(n=>n.error!==void 0)?!0:this.indexManager.isAffected(e,r)}onUpdate(e){return this.updateListeners.push(e),Fn.create(()=>{const r=this.updateListeners.indexOf(e);r>=0&&this.updateListeners.splice(r,1)})}resetToState(e,r){switch(r){case Q.Changed:case Q.Parsed:this.indexManager.removeContent(e.uri);case Q.IndexedContent:e.localSymbols=void 0;case Q.ComputedScopes:this.serviceRegistry.getServices(e.uri).references.Linker.unlink(e);case Q.Linked:this.indexManager.removeReferences(e.uri);case Q.IndexedReferences:e.diagnostics=void 0,this.buildState.delete(e.uri.toString());case Q.Validated:}e.state>r&&(e.state=r)}cleanUpDeleted(e){this.buildState.delete(e.uri.toString()),this.indexManager.remove(e.uri),e.state=Q.Changed}async buildDocuments(e,r,n){this.prepareBuild(e,r),await this.runCancelable(e,Q.Parsed,n,o=>this.langiumDocumentFactory.update(o,n)),await this.runCancelable(e,Q.IndexedContent,n,o=>this.indexManager.updateContent(o,n)),await this.runCancelable(e,Q.ComputedScopes,n,async o=>{const u=this.serviceRegistry.getServices(o.uri).references.ScopeComputation;o.localSymbols=await u.collectLocalSymbols(o,n)});const a=e.filter(o=>this.shouldLink(o));await this.runCancelable(a,Q.Linked,n,o=>this.serviceRegistry.getServices(o.uri).references.Linker.link(o,n)),await this.runCancelable(a,Q.IndexedReferences,n,o=>this.indexManager.updateReferences(o,n));const i=e.filter(o=>this.shouldValidate(o)?!0:(this.markAsCompleted(o),!1));await this.runCancelable(i,Q.Validated,n,async o=>{await this.validate(o,n),this.markAsCompleted(o)})}markAsCompleted(e){const r=this.buildState.get(e.uri.toString());r&&(r.completed=!0)}prepareBuild(e,r){for(const n of e){const a=n.uri.toString(),i=this.buildState.get(a);(!i||i.completed)&&this.buildState.set(a,{completed:!1,options:r,result:i?.result})}}async runCancelable(e,r,n,a){for(const o of e)o.state<r&&(await Ye(n),await a(o),o.state=r,await this.notifyDocumentPhase(o,r,n));const i=e.filter(o=>o.state===r);await this.notifyBuildPhase(i,r,n),this.currentState=r}onBuildPhase(e,r){return this.buildPhaseListeners.add(e,r),Fn.create(()=>{this.buildPhaseListeners.delete(e,r)})}onDocumentPhase(e,r){return this.documentPhaseListeners.add(e,r),Fn.create(()=>{this.documentPhaseListeners.delete(e,r)})}waitUntil(e,r,n){let a;return r&&"path"in r?a=r:n=r,n??(n=$e.CancellationToken.None),a?this.awaitDocumentState(e,a,n):this.awaitBuilderState(e,n)}awaitDocumentState(e,r,n){const a=this.langiumDocuments.getDocument(r);if(a){if(a.state>=e)return Promise.resolve(r);if(n.isCancellationRequested)return Promise.reject(cr);if(this.currentState>=e&&e>a.state)return Promise.reject(new uc.ResponseError(uc.LSPErrorCodes.RequestFailed,`Document state of ${r.toString()} is ${Q[a.state]}, requiring ${Q[e]}, but workspace state is already ${Q[this.currentState]}. Returning undefined.`))}else return Promise.reject(new uc.ResponseError(uc.LSPErrorCodes.ServerCancelled,`No document found for URI: ${r.toString()}`));return new Promise((i,o)=>{const u=this.onDocumentPhase(e,c=>{dt.equals(c.uri,r)&&(u.dispose(),l.dispose(),i(c.uri))}),l=n.onCancellationRequested(()=>{u.dispose(),l.dispose(),o(cr)})})}awaitBuilderState(e,r){return this.currentState>=e?Promise.resolve():r.isCancellationRequested?Promise.reject(cr):new Promise((n,a)=>{const i=this.onBuildPhase(e,()=>{i.dispose(),o.dispose(),n()}),o=r.onCancellationRequested(()=>{i.dispose(),o.dispose(),a(cr)})})}async notifyDocumentPhase(e,r,n){const i=this.documentPhaseListeners.get(r).slice();for(const o of i)try{await Ye(n),await o(e,n)}catch(u){if(!da(u))throw u}}async notifyBuildPhase(e,r,n){if(e.length===0)return;const i=this.buildPhaseListeners.get(r).slice();for(const o of i)await Ye(n),await o(e,n)}shouldLink(e){return this.getBuildOptions(e).eagerLinking??!0}shouldValidate(e){return!!this.getBuildOptions(e).validation}async validate(e,r){const n=this.serviceRegistry.getServices(e.uri).validation.DocumentValidator,a=this.getBuildOptions(e),i=typeof a.validation=="object"?{...a.validation}:{};i.categories=this.findMissingValidationCategories(e,a);const o=await n.validateDocument(e,i,r);e.diagnostics?e.diagnostics.push(...o):e.diagnostics=o;const u=this.buildState.get(e.uri.toString());u&&(u.result??(u.result={}),u.result.validationChecks?u.result.validationChecks=de(u.result.validationChecks).concat(i.categories).distinct().toArray():u.result.validationChecks=[...i.categories])}getBuildOptions(e){return this.buildState.get(e.uri.toString())?.options??{}}},s(Hs,"DefaultDocumentBuilder"),Hs),Ys,uP=(Ys=class{constructor(e){this.symbolIndex=new Map,this.symbolByTypeIndex=new Gd,this.referenceIndex=new Map,this.documents=e.workspace.LangiumDocuments,this.serviceRegistry=e.ServiceRegistry,this.astReflection=e.AstReflection}findAllReferences(e,r){const n=Vt(e).uri,a=[];return this.referenceIndex.forEach(i=>{i.forEach(o=>{dt.equals(o.targetUri,n)&&o.targetPath===r&&a.push(o)})}),de(a)}allElements(e,r){let n=de(this.symbolIndex.keys());return r&&(n=n.filter(a=>!r||r.has(a))),n.map(a=>this.getFileDescriptions(a,e)).flat()}getFileDescriptions(e,r){return r?this.symbolByTypeIndex.get(e,r,()=>(this.symbolIndex.get(e)??[]).filter(i=>this.astReflection.isSubtype(i.type,r))):this.symbolIndex.get(e)??[]}remove(e){this.removeContent(e),this.removeReferences(e)}removeContent(e){const r=e.toString();this.symbolIndex.delete(r),this.symbolByTypeIndex.clear(r)}removeReferences(e){const r=e.toString();this.referenceIndex.delete(r)}async updateContent(e,r=$e.CancellationToken.None){const a=await this.serviceRegistry.getServices(e.uri).references.ScopeComputation.collectExportedSymbols(e,r),i=e.uri.toString();this.symbolIndex.set(i,a),this.symbolByTypeIndex.clear(i)}async updateReferences(e,r=$e.CancellationToken.None){const a=await this.serviceRegistry.getServices(e.uri).workspace.ReferenceDescriptionProvider.createDescriptions(e,r);this.referenceIndex.set(e.uri.toString(),a)}isAffected(e,r){const n=this.referenceIndex.get(e.uri.toString());return n?n.some(a=>!a.local&&r.has(a.targetUri.toString())):!1}},s(Ys,"DefaultIndexManager"),Ys),Xs,cP=(Xs=class{constructor(e){this.initialBuildOptions={},this._ready=new Dr,this.serviceRegistry=e.ServiceRegistry,this.langiumDocuments=e.workspace.LangiumDocuments,this.documentBuilder=e.workspace.DocumentBuilder,this.fileSystemProvider=e.workspace.FileSystemProvider,this.mutex=e.workspace.WorkspaceLock}get ready(){return this._ready.promise}get workspaceFolders(){return this.folders}initialize(e){this.folders=e.workspaceFolders??void 0}initialized(e){return this.mutex.write(r=>this.initializeWorkspace(this.folders??[],r))}async initializeWorkspace(e,r=$e.CancellationToken.None){const n=await this.performStartup(e);await Ye(r),await this.documentBuilder.build(n,this.initialBuildOptions,r)}async performStartup(e){const r=[],n=s(o=>{r.push(o),this.langiumDocuments.hasDocument(o.uri)||this.langiumDocuments.addDocument(o)},"collector");await this.loadAdditionalDocuments(e,n);const a=[];await Promise.all(e.map(o=>this.getRootFolder(o)).map(async o=>this.traverseFolder(o,a)));const i=de(a).distinct(o=>o.toString()).filter(o=>!this.langiumDocuments.hasDocument(o));return await this.loadWorkspaceDocuments(i,n),this._ready.resolve(),r}async loadWorkspaceDocuments(e,r){await Promise.all(e.map(async n=>{const a=await this.langiumDocuments.getOrCreateDocument(n);r(a)}))}loadAdditionalDocuments(e,r){return Promise.resolve()}getRootFolder(e){return It.parse(e.uri)}async traverseFolder(e,r){try{const n=await this.fileSystemProvider.readDirectory(e);await Promise.all(n.map(async a=>{this.shouldIncludeEntry(a)&&(a.isDirectory?await this.traverseFolder(a.uri,r):a.isFile&&r.push(a.uri))}))}catch(n){console.error("Failure to read directory content of "+e.toString(!0),n)}}async searchFolder(e){const r=[];return await this.traverseFolder(e,r),r}shouldIncludeEntry(e){const r=dt.basename(e.uri);return r.startsWith(".")?!1:e.isDirectory?r!=="node_modules"&&r!=="out":e.isFile?this.serviceRegistry.hasServices(e.uri):!1}},s(Xs,"DefaultWorkspaceManager"),Xs),Js,fP=(Js=class{buildUnexpectedCharactersMessage(e,r,n,a,i){return Pm.buildUnexpectedCharactersMessage(e,r,n,a,i)}buildUnableToPopLexerModeMessage(e){return Pm.buildUnableToPopLexerModeMessage(e)}},s(Js,"DefaultLexerErrorMessageProvider"),Js),Hg={mode:"full"},Zs,Yg=(Zs=class{constructor(e){this.errorMessageProvider=e.parser.LexerErrorMessageProvider,this.tokenBuilder=e.parser.TokenBuilder;const r=this.tokenBuilder.buildTokens(e.Grammar,{caseInsensitive:e.LanguageMetaData.caseInsensitive});this.tokenTypes=this.toTokenTypeDictionary(r);const n=Pf(r)?Object.values(r):r,a=e.LanguageMetaData.mode==="production";this.chevrotainLexer=new pt(n,{positionTracking:"full",skipValidations:a,errorMessageProvider:this.errorMessageProvider})}get definition(){return this.tokenTypes}tokenize(e,r=Hg){const n=this.chevrotainLexer.tokenize(e);return{tokens:n.tokens,errors:n.errors,hidden:n.groups.hidden??[],report:this.tokenBuilder.flushLexingReport?.(e)}}toTokenTypeDictionary(e){if(Pf(e))return e;const r=jd(e)?Object.values(e.modes).flat():e,n={};return r.forEach(a=>n[a.name]=a),n}},s(Zs,"DefaultLexer"),Zs);function zd(t){return Array.isArray(t)&&(t.length===0||"name"in t[0])}s(zd,"isTokenTypeArray");function jd(t){return t&&"modes"in t&&"defaultMode"in t}s(jd,"isIMultiModeLexerDefinition");function Pf(t){return!zd(t)&&!jd(t)}s(Pf,"isTokenTypeDictionary");xu();function Xg(t,e,r){let n,a;typeof t=="string"?(a=e,n=r):(a=t.range.start,n=e),a||(a=oe.create(0,0));const i=Zg(t),o=Bd(n),u=dP({lines:i,position:a,options:o});return hP({index:0,tokens:u,position:a})}s(Xg,"parseJSDoc");function Jg(t,e){const r=Bd(e),n=Zg(t);if(n.length===0)return!1;const a=n[0],i=n[n.length-1],o=r.start,u=r.end;return!!o?.exec(a)&&!!u?.exec(i)}s(Jg,"isJSDoc");function Zg(t){let e="";return typeof t=="string"?e=t:e=t.text,e.split(yR)}s(Zg,"getLines");var wT=/\s*(@([\p{L}][\p{L}\p{N}]*)?)/uy,gB=/\{(@[\p{L}][\p{L}\p{N}]*)(\s*)([^\r\n}]+)?\}/gu;function dP(t){const e=[];let r=t.position.line,n=t.position.character;for(let a=0;a<t.lines.length;a++){const i=a===0,o=a===t.lines.length-1;let u=t.lines[a],l=0;if(i&&t.options.start){const f=t.options.start?.exec(u);f&&(l=f.index+f[0].length)}else{const f=t.options.line?.exec(u);f&&(l=f.index+f[0].length)}if(o){const f=t.options.end?.exec(u);f&&(u=u.substring(0,f.index))}if(u=u.substring(0,mP(u)),kf(u,l)>=u.length){if(e.length>0){const f=oe.create(r,n);e.push({type:"break",content:"",range:te.create(f,f)})}}else{wT.lastIndex=l;const f=wT.exec(u);if(f){const d=f[0],p=f[1],y=oe.create(r,n+l),h=oe.create(r,n+l+d.length);e.push({type:"tag",content:p,range:te.create(y,h)}),l+=d.length,l=kf(u,l)}if(l<u.length){const d=u.substring(l),p=Array.from(d.matchAll(gB));e.push(...pP(p,d,r,n+l))}}r++,n=0}return e.length>0&&e[e.length-1].type==="break"?e.slice(0,-1):e}s(dP,"tokenize");function pP(t,e,r,n){const a=[];if(t.length===0){const i=oe.create(r,n),o=oe.create(r,n+e.length);a.push({type:"text",content:e,range:te.create(i,o)})}else{let i=0;for(const u of t){const l=u.index,c=e.substring(i,l);c.length>0&&a.push({type:"text",content:e.substring(i,l),range:te.create(oe.create(r,i+n),oe.create(r,l+n))});let f=c.length+1;const d=u[1];if(a.push({type:"inline-tag",content:d,range:te.create(oe.create(r,i+f+n),oe.create(r,i+f+d.length+n))}),f+=d.length,u.length===4){f+=u[2].length;const p=u[3];a.push({type:"text",content:p,range:te.create(oe.create(r,i+f+n),oe.create(r,i+f+p.length+n))})}else a.push({type:"text",content:"",range:te.create(oe.create(r,i+f+n),oe.create(r,i+f+n))});i=l+u[0].length}const o=e.substring(i);o.length>0&&a.push({type:"text",content:o,range:te.create(oe.create(r,i+n),oe.create(r,i+n+o.length))})}return a}s(pP,"buildInlineTokens");var vB=/\S/,TB=/\s*$/;function kf(t,e){const r=t.substring(e).match(vB);return r?e+r.index:t.length}s(kf,"skipWhitespace");function mP(t){const e=t.match(TB);if(e&&typeof e.index=="number")return e.index}s(mP,"lastCharacter");function hP(t){const e=oe.create(t.position.line,t.position.character);if(t.tokens.length===0)return new IT([],te.create(e,e));const r=[];for(;t.index<t.tokens.length;){const i=yP(t,r[r.length-1]);i&&r.push(i)}const n=r[0]?.range.start??e,a=r[r.length-1]?.range.end??e;return new IT(r,te.create(n,a))}s(hP,"parseJSDocComment");function yP(t,e){const r=t.tokens[t.index];if(r.type==="tag")return ev(t,!1);if(r.type==="text"||r.type==="inline-tag")return Qg(t);gP(r,e),t.index++}s(yP,"parseJSDocElement");function gP(t,e){if(e){const r=new RP("",t.range);"inlines"in e?e.inlines.push(r):e.content.inlines.push(r)}}s(gP,"appendEmptyLine");function Qg(t){let e=t.tokens[t.index];const r=e;let n=e;const a=[];for(;e&&e.type!=="break"&&e.type!=="tag";)a.push(vP(t)),n=e,e=t.tokens[t.index];return new Zm(a,te.create(r.range.start,n.range.end))}s(Qg,"parseJSDocText");function vP(t){return t.tokens[t.index].type==="inline-tag"?ev(t,!0):tv(t)}s(vP,"parseJSDocInline");function ev(t,e){const r=t.tokens[t.index++],n=r.content.substring(1);if(t.tokens[t.index]?.type==="text")if(e){const i=tv(t);return new Zd(n,new Zm([i],i.range),e,te.create(r.range.start,i.range.end))}else{const i=Qg(t);return new Zd(n,i,e,te.create(r.range.start,i.range.end))}else{const i=r.range;return new Zd(n,new Zm([],i),e,i)}}s(ev,"parseJSDocTag");function tv(t){const e=t.tokens[t.index++];return new RP(e.content,e.range)}s(tv,"parseJSDocLine");function Bd(t){if(!t)return Bd({start:"/**",end:"*/",line:"*"});const{start:e,end:r,line:n}=t;return{start:jc(e,!0),end:jc(r,!1),line:jc(n,!0)}}s(Bd,"normalizeOptions");function jc(t,e){if(typeof t=="string"||typeof t=="object"){const r=typeof t=="string"?sl(t):t.source;return e?new RegExp(`^\\s*${r}`):new RegExp(`\\s*${r}\\s*$`)}else return t}s(jc,"normalizeOption");var Qs,IT=(Qs=class{constructor(e,r){this.elements=e,this.range=r}getTag(e){return this.getAllTags().find(r=>r.name===e)}getTags(e){return this.getAllTags().filter(r=>r.name===e)}getAllTags(){return this.elements.filter(e=>"name"in e)}toString(){let e="";for(const r of this.elements)if(e.length===0)e=r.toString();else{const n=r.toString();e+=Qm(e)+n}return e.trim()}toMarkdown(e){let r="";for(const n of this.elements)if(r.length===0)r=n.toMarkdown(e);else{const a=n.toMarkdown(e);r+=Qm(r)+a}return r.trim()}},s(Qs,"JSDocCommentImpl"),Qs),eo,Zd=(eo=class{constructor(e,r,n,a){this.name=e,this.content=r,this.inline=n,this.range=a}toString(){let e=`@${this.name}`;const r=this.content.toString();return this.content.inlines.length===1?e=`${e} ${r}`:this.content.inlines.length>1&&(e=`${e}
152
152
  ${r}`),this.inline?`{${e}}`:e}toMarkdown(e){return e?.renderTag?.(this)??this.toMarkdownDefault(e)}toMarkdownDefault(e){const r=this.content.toMarkdown(e);if(this.inline){const i=TP(this.name,r,e??{});if(typeof i=="string")return i}let n="";e?.tag==="italic"||e?.tag===void 0?n="*":e?.tag==="bold"?n="**":e?.tag==="bold-italic"&&(n="***");let a=`${n}@${this.name}${n}`;return this.content.inlines.length===1?a=`${a} — ${r}`:this.content.inlines.length>1&&(a=`${a}
153
153
  ${r}`),this.inline?`{${a}}`:a}},s(eo,"JSDocTagImpl"),eo);function TP(t,e,r){if(t==="linkplain"||t==="linkcode"||t==="link"){const n=e.indexOf(" ");let a=e;if(n>0){const o=kf(e,n);a=e.substring(o),e=e.substring(0,n)}return(t==="linkcode"||t==="link"&&r.link==="code")&&(a=`\`${a}\``),r.renderLink?.(e,a)??$P(e,a)}}s(TP,"renderInlineTag");function $P(t,e){try{return It.parse(t,!0),`[${e}](${t})`}catch{return t}}s($P,"renderLinkDefault");var to,Zm=(to=class{constructor(e,r){this.inlines=e,this.range=r}toString(){let e="";for(let r=0;r<this.inlines.length;r++){const n=this.inlines[r],a=this.inlines[r+1];e+=n.toString(),a&&a.range.start.line>n.range.start.line&&(e+=`
154
154
  `)}return e}toMarkdown(e){let r="";for(let n=0;n<this.inlines.length;n++){const a=this.inlines[n],i=this.inlines[n+1];r+=a.toMarkdown(e),i&&i.range.start.line>a.range.start.line&&(r+=`