@marimo-team/islands 0.19.7-dev2 → 0.19.7-dev21

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 (814) hide show
  1. package/dist/{ConnectedDataExplorerComponent-CDKkNEXK.js → ConnectedDataExplorerComponent-BW-EEUju.js} +12 -12
  2. package/dist/_baseIsEqual-CBSjxu-D.js +225 -0
  3. package/dist/{_baseProperty-zelfx9VI.js → _baseProperty-BVGrW_NZ.js} +2 -2
  4. package/dist/{_baseUniq-BUGws47x.js → _baseUniq-4lqa8rDi.js} +7 -8
  5. package/dist/{any-language-editor-vYraVrwE.js → any-language-editor-jlqKouk6.js} +16 -16
  6. package/dist/apl-BuwKwesW.js +4 -0
  7. package/dist/{arc-DXxE-tFl.js → arc-CEWBr4jc.js} +2 -2
  8. package/dist/architecture-U656AL7Q-COfwZju8.js +6 -0
  9. package/dist/{architectureDiagram-VXUJARFQ-DRLesROp.js → architectureDiagram-VXUJARFQ--NkyBn9Y.js} +18 -19
  10. package/dist/asciiarmor-zAEd_wtn.js +4 -0
  11. package/dist/asn1-DWEA66J4.js +4 -0
  12. package/dist/{blockDiagram-VD42YOAC-ByzG0Vzp.js → blockDiagram-VD42YOAC-DEZZaTW0.js} +13 -14
  13. package/dist/brainfuck-mIPR6Ong.js +4 -0
  14. package/dist/{c4Diagram-YG6GDRKO-Trp4lx6i.js → c4Diagram-YG6GDRKO-Bj7hwWCO.js} +5 -5
  15. package/dist/{channel-CPUfhCMU.js → channel-B_QrFrGg.js} +1 -1
  16. package/dist/{chunk-4BX2VUAB-D-P4ZvWX.js → chunk-4BX2VUAB-DZQibjKA.js} +1 -1
  17. package/dist/{chunk-55IACEB6-DRnX6IuG.js → chunk-55IACEB6-C3BASkh4.js} +1 -1
  18. package/dist/{chunk-OGVTOU66-RMy3tlM6.js → chunk-5FQGJX7Z-D5VFKHmt.js} +5206 -4212
  19. package/dist/{chunk-76Q3JFCE-DaBPIBvG.js → chunk-76Q3JFCE-jPuajZH_.js} +1 -1
  20. package/dist/{chunk-ABZYJK2D-BZDGfEE1.js → chunk-ABZYJK2D-SZPYmRzN.js} +2 -2
  21. package/dist/{chunk-ATLVNIR6-j8AgRnSs.js → chunk-ATLVNIR6-BI_WwH1o.js} +2 -2
  22. package/dist/{chunk-B4BG7PRW-DU1moE9R.js → chunk-B4BG7PRW-BlI9Gm1l.js} +7 -7
  23. package/dist/{chunk-CVBHYZKI-CDc7Jfcj.js → chunk-CVBHYZKI-Dhc_e3rA.js} +1 -1
  24. package/dist/{chunk-DI55MBZ5-BIFn9unR.js → chunk-DI55MBZ5-BXxemMn5.js} +6 -6
  25. package/dist/{chunk-EXTU4WIE-CaHHLmza.js → chunk-EXTU4WIE-CzWtDV99.js} +2 -2
  26. package/dist/{chunk-FMBD7UC4-D8xABqXe.js → chunk-FMBD7UC4-geNUIndh.js} +1 -1
  27. package/dist/{chunk-FPAJGGOC-B7vtXnL8.js → chunk-FPAJGGOC-CduL34ft.js} +7 -7
  28. package/dist/{chunk-FWNWRKHM-CoKqaHV4.js → chunk-FWNWRKHM-C-2TI4gt.js} +1 -1
  29. package/dist/{chunk-HN2XXSSU-DilnBn0B.js → chunk-HN2XXSSU-CqPwpolw.js} +1 -1
  30. package/dist/chunk-JA3XYJ7Z-DQ-2ARfa.js +1838 -0
  31. package/dist/{chunk-JZLCHNYA-DyKV2dUA.js → chunk-JZLCHNYA-CVfjf2vv.js} +6 -6
  32. package/dist/{chunk-LBM3YZW2-CuRptnLo.js → chunk-LBM3YZW2-DWgQiioW.js} +1 -1
  33. package/dist/{chunk-LHMN2FUI-Z6kNjtl5.js → chunk-LHMN2FUI-Dj_AHSvI.js} +1 -1
  34. package/dist/{chunk-MI3HLSF2-uTxL-0zC.js → chunk-MI3HLSF2-DOJkNER1.js} +1 -1
  35. package/dist/{chunk-N4CR4FBY-C_3rxQPk.js → chunk-N4CR4FBY-BCZvQ7Jq.js} +7 -7
  36. package/dist/{chunk-O7ZBX7Z2-N-4UT8hG.js → chunk-O7ZBX7Z2-CRZ8i1rP.js} +1 -1
  37. package/dist/{chunk-QN33PNHL-BcBASegy.js → chunk-QN33PNHL-DY_2Q2zl.js} +2 -2
  38. package/dist/{chunk-QXUST7PY-DMlfsgyq.js → chunk-QXUST7PY-BMCjAVR_.js} +10 -10
  39. package/dist/{chunk-QZHKN3VN-gCo1BI4L.js → chunk-QZHKN3VN-BF_oGUlG.js} +1 -1
  40. package/dist/{chunk-S3R3BYOJ-BhcrQySJ.js → chunk-S3R3BYOJ-Ddu0H4Qa.js} +5 -5
  41. package/dist/{chunk-S6J4BHB3-CbT4tqbg.js → chunk-S6J4BHB3-DNVMr0_v.js} +1 -1
  42. package/dist/{chunk-T53DSG4Q-DjWTd72f.js → chunk-T53DSG4Q-BFWkpOX5.js} +1 -1
  43. package/dist/{chunk-TZMSLE5B-udBrmj8R.js → chunk-TZMSLE5B-C2wVlbMl.js} +3 -3
  44. package/dist/classDiagram-2ON5EDUG-D-g7zbyO.js +30 -0
  45. package/dist/classDiagram-v2-WZHVMYZB-C7v5zNRD.js +30 -0
  46. package/dist/{clike-CLJYUAWw.js → clike-B1zispTy.js} +1 -1
  47. package/dist/clojure-DkhhNHNQ.js +4 -0
  48. package/dist/{clone-BImB0Zxt.js → clone-Cc_6PW77.js} +1 -1
  49. package/dist/cmake-1obPvqtc.js +4 -0
  50. package/dist/cobol-oWNTiXPE.js +4 -0
  51. package/dist/code-block-37QAKDTI-eUgXqGNG.js +107 -0
  52. package/dist/coffeescript-LtYUvf6r.js +4 -0
  53. package/dist/commonlisp-C_06qBYF.js +4 -0
  54. package/dist/{cose-bilkent-S5V4N54A-kv0JiSTh.js → cose-bilkent-S5V4N54A-CO4ORQHF.js} +2 -2
  55. package/dist/crystal-CDJkbx14.js +4 -0
  56. package/dist/css-Bi_Nk0uN.js +4 -0
  57. package/dist/cypher-TrG0NvZ0.js +4 -0
  58. package/dist/d-CFKOrZsi.js +4 -0
  59. package/dist/{dagre-6UL2VRFP-HiV8Yeor.js → dagre-6UL2VRFP-DKIPL74O.js} +14 -15
  60. package/dist/{dagre-Baw82WQV.js → dagre-D2F8UdM6.js} +10 -11
  61. package/dist/{data-grid-overlay-editor-BuHxKF-R.js → data-grid-overlay-editor-COyFwFmE.js} +2 -2
  62. package/dist/{diagram-PSM6KHXK-jDduKZjc.js → diagram-PSM6KHXK-CVTrAZaP.js} +21 -21
  63. package/dist/{diagram-QEK2KX5R-CiQYmuQX.js → diagram-QEK2KX5R-BqHBzu3x.js} +16 -16
  64. package/dist/{diagram-S2PKOQOG-3sE_WnZi.js → diagram-S2PKOQOG-CJD6owcg.js} +16 -16
  65. package/dist/diff-CfnSF48q.js +4 -0
  66. package/dist/{dist-CMZuWSBe.js → dist--Em7gfgX.js} +2 -2
  67. package/dist/{dist-CDxsfpyX.js → dist--JwRU9u5.js} +1 -1
  68. package/dist/dist-2OSzSqy2.js +5 -0
  69. package/dist/dist-B1H2TQGB.js +8 -0
  70. package/dist/{dist-Bs1IvD_X.js → dist-B7NoEgR4.js} +1 -1
  71. package/dist/dist-BNvasp6N.js +5 -0
  72. package/dist/{dist-DRA2Iv4Q.js → dist-BcXuIt-h.js} +1 -1
  73. package/dist/{dist-D7wDmIuC.js → dist-BhBtK2sL.js} +1 -1
  74. package/dist/{dist-HA2BVGuM.js → dist-BlRm4v0e.js} +4 -4
  75. package/dist/{dist-DNVajE3L.js → dist-C6p7UKkB.js} +1 -1
  76. package/dist/{dist-BZXKWoES.js → dist-CBA36Nuy.js} +1 -1
  77. package/dist/{dist-DY8txPM6.js → dist-CFi_P6cs.js} +1 -1
  78. package/dist/dist-CG4LWTPv.js +8 -0
  79. package/dist/{dist-BtPD-BeW.js → dist-CHWVQZ6Z.js} +2 -2
  80. package/dist/{dist-C011r2tf.js → dist-CITQGRtG.js} +3 -3
  81. package/dist/{dist-CZq4mfrw.js → dist-COp5dkis.js} +2 -2
  82. package/dist/dist-C_8-swED.js +5 -0
  83. package/dist/{dist-DW3LjXSw.js → dist-C_Kw_Kc0.js} +1 -1
  84. package/dist/{dist-_FVOHtWJ.js → dist-Co5PD8Fb.js} +1 -1
  85. package/dist/{dist-J6fsaVBE.js → dist-DA1J6LvO.js} +1 -1
  86. package/dist/dist-DIhtur5b.js +5 -0
  87. package/dist/{dist-DI1Bo5Nv.js → dist-DKnxaCRl.js} +1 -1
  88. package/dist/dist-DoQ7RS4e.js +5 -0
  89. package/dist/dist-DsMd-F9h.js +5 -0
  90. package/dist/dist-DurmUshd.js +8 -0
  91. package/dist/{dist-Bv-wYGwr.js → dist-PZgrh2z6.js} +2 -2
  92. package/dist/{dist-BUwAd6_d.js → dist-b7Sc3Tj8.js} +1 -1
  93. package/dist/{dist-DWMcVk1V.js → dist-r6N_0WG-.js} +3 -3
  94. package/dist/{dist--kinAuV0.js → dist-wudNDAiO.js} +1 -1
  95. package/dist/dist-zVskjQcA.js +8 -0
  96. package/dist/{dockerfile-kP2dp4Jc.js → dockerfile-BBT_Ira6.js} +1 -1
  97. package/dist/dtd-Ctw8_JkU.js +4 -0
  98. package/dist/dylan-f7rMBKDP.js +4 -0
  99. package/dist/ecl-C2h3oBMY.js +4 -0
  100. package/dist/eiffel-Ce81wv20.js +4 -0
  101. package/dist/elm-BVV8QQcc.js +4 -0
  102. package/dist/{erDiagram-Q2GNP2WA-DaNawciA.js → erDiagram-Q2GNP2WA-CqOceSf9.js} +14 -15
  103. package/dist/erlang-DjB35ZUh.js +4 -0
  104. package/dist/{error-banner-BhqH4mGj.js → error-banner-uJ4xh94e.js} +1 -1
  105. package/dist/{esm-DOBJQbuy.js → esm-DNwkt4aO.js} +104 -104
  106. package/dist/factor-CIcp3U2B.js +4 -0
  107. package/dist/{factor-Png_OsVt.js → factor-DdqWbSyy.js} +1 -1
  108. package/dist/{flatten-CP4G1KkO.js → flatten-eGRGXrC3.js} +1 -1
  109. package/dist/{flowDiagram-NV44I4VS-Cn7CoW5b.js → flowDiagram-NV44I4VS-K7-DUifo.js} +16 -17
  110. package/dist/forth-CVgjsHhD.js +4 -0
  111. package/dist/fortran-CcTXj0d_.js +4 -0
  112. package/dist/{ganttDiagram-JELNMOA3-D2MZdMJt.js → ganttDiagram-JELNMOA3-BwUFY9Nu.js} +9 -9
  113. package/dist/gas-JWpamkLf.js +4 -0
  114. package/dist/gherkin-BveSCSJV.js +4 -0
  115. package/dist/{gitGraph-F6HP7TQM-DAY7Pizs.js → gitGraph-F6HP7TQM-CDM3aU-T.js} +3 -3
  116. package/dist/{gitGraphDiagram-NY62KEGX-CQ9ts7ZP.js → gitGraphDiagram-NY62KEGX-CjGRtLb1.js} +16 -16
  117. package/dist/{glide-data-editor-CF27qeAl.js → glide-data-editor-QbwryjAp.js} +8 -8
  118. package/dist/{graphlib-C_0PYYJy.js → graphlib-7UgfJadv.js} +5 -6
  119. package/dist/groovy-Np3AZt00.js +4 -0
  120. package/dist/haskell-CVfmFALm.js +4 -0
  121. package/dist/haxe-C10xkMLg.js +5 -0
  122. package/dist/idl-CKBSGnKC.js +4 -0
  123. package/dist/{info-NVLQJR56-CSiFVstv.js → info-NVLQJR56-CoL1x1Fy.js} +3 -3
  124. package/dist/{infoDiagram-WHAUD3N6-CVDTiMub.js → infoDiagram-WHAUD3N6-DNhmDn-6.js} +14 -14
  125. package/dist/{isEmpty-D2-li_vO.js → isEmpty-DQXRKNtW.js} +1 -1
  126. package/dist/javascript-Cur-15Bn.js +4 -0
  127. package/dist/{journeyDiagram-XKPGCS4Q-Dqs3P2CH.js → journeyDiagram-XKPGCS4Q-BOdK47P8.js} +6 -6
  128. package/dist/julia-BZZH2Gnx.js +4 -0
  129. package/dist/{kanban-definition-3W4ZIXB7-BEhej3Aa.js → kanban-definition-3W4ZIXB7-A0JC9d0g.js} +11 -12
  130. package/dist/{katex-DXbA2lyH.js → katex-DJyOeQ91.js} +1 -1
  131. package/dist/{label-B8Ngsa38.js → label-o68OaAQk.js} +2 -2
  132. package/dist/{line-C1k1rG3Z.js → line-LK_5q2B9.js} +3 -3
  133. package/dist/{linear-Dhu2Qlw4.js → linear-vWf1Qj0e.js} +4 -4
  134. package/dist/livescript-D_rTTm_U.js +4 -0
  135. package/dist/{loader-DH7xXi-E.js → loader-WBQoIunJ.js} +1 -1
  136. package/dist/lua-Mf_Of7eV.js +4 -0
  137. package/dist/main.js +18723 -18034
  138. package/dist/mathematica-DCYjugDb.js +4 -0
  139. package/dist/mbox-KBWrT8JD.js +4 -0
  140. package/dist/mermaid-4DMBBIKO-o3xNphpD.js +6 -0
  141. package/dist/{mermaid.core-BzRPXY_i.js → mermaid-CDdsQEyr.js} +186 -108
  142. package/dist/{mermaid-parser.core-BFf_lpn1.js → mermaid-parser.core-D20zFbMa.js} +8 -8
  143. package/dist/{mhchem-D3PZqzP1.js → mhchem-BqdXeZVX.js} +1 -1
  144. package/dist/{min-CzysEoAP.js → min-Bg4bqmiD.js} +1 -1
  145. package/dist/{mindmap-definition-VGOIOE7T-DH1E7psw.js → mindmap-definition-VGOIOE7T-CS6nKN_L.js} +13 -14
  146. package/dist/mirc-JwEQJ8Fb.js +4 -0
  147. package/dist/mllike-C7TxLvh6.js +6 -0
  148. package/dist/modelica-uvNgvUyw.js +4 -0
  149. package/dist/mscgen-CGnokp5x.js +6 -0
  150. package/dist/mumps-Dl9QdOZz.js +4 -0
  151. package/dist/nsis-BbDhbgPN.js +4 -0
  152. package/dist/{nsis-BrAITej_.js → nsis-CunMjZ_n.js} +1 -1
  153. package/dist/ntriples-ChL1mlp7.js +4 -0
  154. package/dist/{number-overlay-editor-DHeLnLyR.js → number-overlay-editor-Bz_bDJQb.js} +1 -1
  155. package/dist/octave-B9ZGG6zv.js +4 -0
  156. package/dist/{once-C-NkXwWJ.js → once-BqS42WgZ.js} +1 -1
  157. package/dist/{ordinal-CUS6_Aqv.js → ordinal-IlASfRja.js} +1 -1
  158. package/dist/oz-XHEu31wr.js +4 -0
  159. package/dist/{packet-BFZMPI3H-DZ3M7UG8.js → packet-BFZMPI3H-C6aZmgV-.js} +3 -3
  160. package/dist/pascal-BxtYw-iH.js +4 -0
  161. package/dist/perl-Br5BgHPb.js +4 -0
  162. package/dist/{pie-7BOR55EZ-BZ7IZsm8.js → pie-7BOR55EZ-NB6xYwcB.js} +3 -3
  163. package/dist/{pieDiagram-ADFJNKIX-Dc8_ZPVD.js → pieDiagram-ADFJNKIX-DSa60Grk.js} +21 -21
  164. package/dist/pig-BByO2hBz.js +4 -0
  165. package/dist/powershell-Cd4Zaef3.js +4 -0
  166. package/dist/{precisionRound-B0z4y-te.js → precisionRound-CGLoV26P.js} +1 -1
  167. package/dist/properties-B-BOCIOl.js +4 -0
  168. package/dist/protobuf-CaLimlho.js +4 -0
  169. package/dist/{pug-CH-17az-.js → pug-Dr-sA_9V.js} +1 -1
  170. package/dist/pug-bonARSG6.js +4 -0
  171. package/dist/puppet-BSlT-3sc.js +4 -0
  172. package/dist/python-BIJhGYYP.js +4 -0
  173. package/dist/q-D9TX8A0B.js +4 -0
  174. package/dist/{quadrantDiagram-AYHSOK5B-Bi2zuCYl.js → quadrantDiagram-AYHSOK5B-CFnMbP2J.js} +4 -4
  175. package/dist/r-BXelX7Rl.js +4 -0
  176. package/dist/{radar-NHE76QYJ-BwZi8I4_.js → radar-NHE76QYJ-RKhErikV.js} +3 -3
  177. package/dist/{range-iDYhZkRw.js → range-LoQMRQIX.js} +2 -2
  178. package/dist/{react-plotly-D-b1AEMh.js → react-plotly-jVjTu07w.js} +1 -1
  179. package/dist/{react-vega-z40f-dXy.js → react-vega-CjiPWyw0.js} +18 -18
  180. package/dist/react-vega-DgHpnZ04.js +9 -0
  181. package/dist/{reduce-1D4AnEer.js → reduce-B9mZDxPo.js} +3 -3
  182. package/dist/{requirementDiagram-UZGBJVZJ-Dx4_kui2.js → requirementDiagram-UZGBJVZJ-ytLQrFTk.js} +13 -14
  183. package/dist/rpm-BxAh9B1A.js +5 -0
  184. package/dist/ruby-BCZLQyhc.js +4 -0
  185. package/dist/{sankeyDiagram-TZEHDZUN-CKYnHkMA.js → sankeyDiagram-TZEHDZUN-KQqXDoky.js} +4 -4
  186. package/dist/sas-Bo7lsyNX.js +4 -0
  187. package/dist/scheme-Brhptkt-.js +4 -0
  188. package/dist/{sequenceDiagram-WL72ISMW-C-p-8Qdz.js → sequenceDiagram-WL72ISMW-ByLI04T5.js} +7 -7
  189. package/dist/shell-fWWb8_qx.js +4 -0
  190. package/dist/sieve-Ba8_hMLn.js +4 -0
  191. package/dist/{slides-component-BHWhzwDN.js → slides-component-BGEYjTca.js} +1 -1
  192. package/dist/smalltalk-7sHxwMDT.js +4 -0
  193. package/dist/sparql-BBFrPJ7z.js +4 -0
  194. package/dist/{spec-KNxDhBEX.js → spec-CuHgWmcK.js} +3 -3
  195. package/dist/{src-CHUphWwL.js → src-szye8OCw.js} +1 -1
  196. package/dist/{stateDiagram-FKZM4ZOC-otiu7nL4.js → stateDiagram-FKZM4ZOC-Dfz8vBbP.js} +18 -19
  197. package/dist/stateDiagram-v2-4FDKWEC3-DRYoLdT5.js +29 -0
  198. package/dist/{step-BbmiiQdf.js → step-1PmBKr2y.js} +1 -1
  199. package/dist/stex-ChDHQs3R.js +4 -0
  200. package/dist/style.css +1 -1
  201. package/dist/stylus-CIB0KT46.js +4 -0
  202. package/dist/swift-CZinekXz.js +4 -0
  203. package/dist/tcl-DCHZJVq_.js +4 -0
  204. package/dist/textile-ThTMxgkN.js +4 -0
  205. package/dist/{time-m5v-VC8K.js → time-DC4qQGmA.js} +4 -4
  206. package/dist/{timeline-definition-IT6M3QCI-DhR16s4q.js → timeline-definition-IT6M3QCI-CO48XU1B.js} +3 -3
  207. package/dist/toml-DK17wlJ7.js +4 -0
  208. package/dist/{treemap-KMMF4GRG-Bp2TNEsG.js → treemap-KMMF4GRG-B37ugcLd.js} +3 -3
  209. package/dist/troff-CuUAOgMy.js +4 -0
  210. package/dist/ttcn-DS2tj6rW.js +4 -0
  211. package/dist/ttcn-cfg-CdZGarnc.js +4 -0
  212. package/dist/turtle-Bkz-FLZ7.js +4 -0
  213. package/dist/{types-B9fL65ao.js → types-BIvEidLq.js} +4 -4
  214. package/dist/{useAsyncData-kqbhbSuf.js → useAsyncData-DFBEii2l.js} +2 -2
  215. package/dist/{useDeepCompareMemoize-B2QEm3jo.js → useDeepCompareMemoize-HKwezUBx.js} +3 -3
  216. package/dist/{useIframeCapabilities-BsIPDupA.js → useIframeCapabilities-wWXCXV88.js} +1 -1
  217. package/dist/{useTheme-CVr6Gb_R.js → useTheme-D0zT6HZe.js} +2 -2
  218. package/dist/vb-ITdOmxvR.js +4 -0
  219. package/dist/vbscript-B7oeGyfL.js +4 -0
  220. package/dist/{vega-component-DAeU1_cV.js → vega-component-2gqZksJH.js} +11 -11
  221. package/dist/{vega-loader.browser-nTy1NZD3.js → vega-loader.browser-BJ1uJidF.js} +3 -3
  222. package/dist/velocity-D__EkuSd.js +4 -0
  223. package/dist/verilog-CPH50gr9.js +4 -0
  224. package/dist/vhdl-CQAwKCk_.js +4 -0
  225. package/dist/webidl-BnEptfVX.js +4 -0
  226. package/dist/xquery-D7eTv-CR.js +4 -0
  227. package/dist/{xychartDiagram-PRI3JC2R-DxKtZBfd.js → xychartDiagram-PRI3JC2R-CUIfjNVD.js} +12 -13
  228. package/dist/yacas-0x1rX89s.js +4 -0
  229. package/dist/z80-B25SJVDf.js +4 -0
  230. package/package.json +8 -7
  231. package/src/components/ai/__tests__/ai-utils.test.ts +20 -20
  232. package/src/components/ai/ai-model-dropdown.tsx +8 -10
  233. package/src/components/ai/ai-utils.ts +11 -9
  234. package/src/components/app-config/__tests__/get-dirty-values.test.ts +47 -1
  235. package/src/components/app-config/ai-config.tsx +20 -54
  236. package/src/components/app-config/state.ts +11 -1
  237. package/src/components/app-config/user-config-form.tsx +73 -3
  238. package/src/components/chat/chat-panel.tsx +5 -1
  239. package/src/components/editor/chrome/panels/dependency-graph-panel.tsx +46 -10
  240. package/src/components/markdown/markdown-renderer.tsx +6 -1
  241. package/src/core/ai/context/providers/cell-output.ts +1 -1
  242. package/src/core/export/__tests__/hooks.test.ts +7 -1
  243. package/src/core/export/hooks.ts +1 -1
  244. package/src/plugins/impl/plotly/PlotlyPlugin.tsx +11 -66
  245. package/src/plugins/impl/plotly/__tests__/usePlotlyLayout.test.ts +113 -0
  246. package/src/plugins/impl/plotly/usePlotlyLayout.ts +163 -0
  247. package/src/utils/__tests__/download.test.tsx +88 -16
  248. package/src/utils/__tests__/iframe.test.ts +139 -0
  249. package/src/utils/download.ts +40 -9
  250. package/src/utils/html-to-image.ts +41 -0
  251. package/src/utils/iframe.ts +142 -0
  252. package/dist/_baseIsEqual-BygTGUZ4.js +0 -198
  253. package/dist/_getTag-C91a-G2j.js +0 -31
  254. package/dist/abap-CKZVRcrP.js +0 -4
  255. package/dist/actionscript-3-CfEeiw8Q.js +0 -4
  256. package/dist/ada-Espzt5xk.js +0 -4
  257. package/dist/andromeeda-Bet9yHpN.js +0 -4
  258. package/dist/angular-html-D6gc6xRJ.js +0 -20
  259. package/dist/angular-html-DE-SuIpI.js +0 -4
  260. package/dist/angular-ts-BjFZRs0x.js +0 -18
  261. package/dist/apache-C-c0stKR.js +0 -4
  262. package/dist/apex-BiJpixJ-.js +0 -4
  263. package/dist/apl-BEQpOla5.js +0 -16
  264. package/dist/apl-lHFVoxx7.js +0 -4
  265. package/dist/applescript-BccZMr3e.js +0 -4
  266. package/dist/ara-DPVHfRJZ.js +0 -4
  267. package/dist/architecture-U656AL7Q-wavOWR6z.js +0 -6
  268. package/dist/asciiarmor-DqCdZUHI.js +0 -4
  269. package/dist/asciidoc-CCrtAKGW.js +0 -4
  270. package/dist/asm-C0GNzPhS.js +0 -4
  271. package/dist/asn1-DEcwtw-q.js +0 -4
  272. package/dist/astro-CxSXfOWT.js +0 -18
  273. package/dist/aurora-x-DBIPmgQb.js +0 -4
  274. package/dist/awk-7-EU_WjX.js +0 -4
  275. package/dist/ayu-dark-BB4DzJ08.js +0 -4
  276. package/dist/ballerina-5MpSVFjo.js +0 -4
  277. package/dist/bat-COtKSp2G.js +0 -4
  278. package/dist/beancount-BTyoFFVI.js +0 -4
  279. package/dist/berry-CNMCaTK_.js +0 -4
  280. package/dist/bibtex-Cti-V2Ia.js +0 -4
  281. package/dist/bicep-f38RkTGW.js +0 -4
  282. package/dist/blade-BKkPPgXV.js +0 -20
  283. package/dist/brainfuck-Bro9Oz5x.js +0 -4
  284. package/dist/bsl-CGq8JMnm.js +0 -5
  285. package/dist/c-BltHt-Ng.js +0 -4
  286. package/dist/c-C2t3MvE0.js +0 -4
  287. package/dist/cadence-m1eiVz08.js +0 -4
  288. package/dist/cairo-scf1ovh9.js +0 -5
  289. package/dist/catppuccin-frappe-C7063pB0.js +0 -4
  290. package/dist/catppuccin-latte-DMkr2vg8.js +0 -4
  291. package/dist/catppuccin-macchiato-BqE_ZXfu.js +0 -4
  292. package/dist/catppuccin-mocha-D7YJQma9.js +0 -4
  293. package/dist/chunk-JA3XYJ7Z-CzGXky2M.js +0 -470
  294. package/dist/clarity-B1pEsGP2.js +0 -4
  295. package/dist/classDiagram-2ON5EDUG-C2nDCJAo.js +0 -31
  296. package/dist/classDiagram-v2-WZHVMYZB-DORr9374.js +0 -31
  297. package/dist/clojure-B2uhdQPa.js +0 -4
  298. package/dist/clojure-BATFX9a2.js +0 -4
  299. package/dist/cmake-B9WXyQcc.js +0 -4
  300. package/dist/cmake-BRQW8t09.js +0 -4
  301. package/dist/cmake-jVu1cyUe.js +0 -4
  302. package/dist/cobol-CPD3EJfO.js +0 -4
  303. package/dist/cobol-D19g8SyZ.js +0 -10
  304. package/dist/code-block-QI2IAROF-CJ80GtCm.js +0 -8572
  305. package/dist/codeowners-DOHu4JsD.js +0 -4
  306. package/dist/codeql-Bv-kyldE.js +0 -4
  307. package/dist/coffee-BSWTbMgj.js +0 -5
  308. package/dist/coffeescript-KD9TnEnS.js +0 -4
  309. package/dist/common-lisp-DuUbiL1M.js +0 -4
  310. package/dist/commonlisp-DNEULz_Q.js +0 -4
  311. package/dist/coq-BLENpWYo.js +0 -4
  312. package/dist/cpp-BFMcsgZ1.js +0 -18
  313. package/dist/cpp-J7hKFkZz.js +0 -4
  314. package/dist/crystal-BoGe6xAc.js +0 -18
  315. package/dist/crystal-DVPNgAPQ.js +0 -4
  316. package/dist/csharp-Bi0R0O8M.js +0 -4
  317. package/dist/csharp-CEsbqhVz.js +0 -4
  318. package/dist/css-Dkaj1ML5.js +0 -4
  319. package/dist/css-fq3a1AH1.js +0 -4
  320. package/dist/css-tx1M2UYO.js +0 -4
  321. package/dist/csv-MeEBatsw.js +0 -4
  322. package/dist/cue-DBMXnBGO.js +0 -4
  323. package/dist/cypher-DiUnNCqR.js +0 -4
  324. package/dist/cypher-Dtzq0BP7.js +0 -4
  325. package/dist/d-CY8xRV-6.js +0 -4
  326. package/dist/d-DcZudIhJ.js +0 -4
  327. package/dist/dark-plus-Bx-XGUdv.js +0 -4
  328. package/dist/dart-DZ5DpAxj.js +0 -4
  329. package/dist/dax-Heo0fec8.js +0 -4
  330. package/dist/desktop-CIXrTzSI.js +0 -4
  331. package/dist/diff-CM1HFG4F.js +0 -4
  332. package/dist/diff-D9BPDC3o.js +0 -4
  333. package/dist/diff-FiILeNDL.js +0 -4
  334. package/dist/dist-8tG5l853.js +0 -5
  335. package/dist/dist-BXvOBlRl.js +0 -5
  336. package/dist/dist-BkSNcgv8.js +0 -5
  337. package/dist/dist-Bu4pyZoX.js +0 -8
  338. package/dist/dist-C1PN9EmN.js +0 -8
  339. package/dist/dist-C5R1jOyp.js +0 -8
  340. package/dist/dist-C7SYDWEd.js +0 -5
  341. package/dist/dist-CLZuU2Bs.js +0 -5
  342. package/dist/dist-Cjy_pAHy.js +0 -8
  343. package/dist/dist-jeJh-w1R.js +0 -5
  344. package/dist/docker-BpLHnOZG.js +0 -4
  345. package/dist/dotenv-B-FeoaI3.js +0 -4
  346. package/dist/dracula-soft-vgd7ckob.js +0 -4
  347. package/dist/dracula-yEIVSENH.js +0 -4
  348. package/dist/dream-maker-j9DfKXJZ.js +0 -4
  349. package/dist/dtd-FhG-tVom.js +0 -4
  350. package/dist/dylan-HWpZOBPw.js +0 -4
  351. package/dist/ecl-B_rcje1I.js +0 -4
  352. package/dist/edge-BvTSoBD4.js +0 -12
  353. package/dist/eiffel-oqHyHs6f.js +0 -4
  354. package/dist/elixir-Dy-Nd45s.js +0 -5
  355. package/dist/elm-B62RQEds.js +0 -4
  356. package/dist/elm-BbBZ4HBJ.js +0 -5
  357. package/dist/emacs-lisp-BlKF8SK8.js +0 -4
  358. package/dist/erb-DfDHVhmE.js +0 -10
  359. package/dist/erlang-CjRjjA-B.js +0 -4
  360. package/dist/erlang-DL9YWH5B.js +0 -5
  361. package/dist/everforest-dark-DTO3RYvZ.js +0 -4
  362. package/dist/everforest-light-BLftNDeA.js +0 -4
  363. package/dist/factor-CGH_TnIV.js +0 -4
  364. package/dist/fennel-CJpQobBl.js +0 -4
  365. package/dist/fish-Dvq3omMv.js +0 -4
  366. package/dist/fluent-_glkAdRk.js +0 -4
  367. package/dist/forth-5N06oHNp.js +0 -4
  368. package/dist/fortran-fixed-form-DvmVLEcO.js +0 -5
  369. package/dist/fortran-free-form-BRZ1-G2x.js +0 -4
  370. package/dist/fortran-free-form-C3kgUwfa.js +0 -4
  371. package/dist/fortran-wZ-sNg3h.js +0 -4
  372. package/dist/fsharp-B7-jsQMl.js +0 -5
  373. package/dist/gas-3H4_FaS8.js +0 -4
  374. package/dist/gdresource-7F-q_Vav.js +0 -10
  375. package/dist/gdscript-B0eENwgc.js +0 -4
  376. package/dist/gdscript-DAHEG9Ry.js +0 -4
  377. package/dist/gdshader-DPYtQQW0.js +0 -4
  378. package/dist/gdshader-o6WS_GvU.js +0 -4
  379. package/dist/genie-Bnhk4Ege.js +0 -4
  380. package/dist/gherkin-N8YTYIme.js +0 -4
  381. package/dist/gherkin-PEA2uy50.js +0 -4
  382. package/dist/git-commit-Cv7QTAeJ.js +0 -5
  383. package/dist/git-rebase-DwX3Nm0e.js +0 -5
  384. package/dist/github-dark-B0rIFWbz.js +0 -4
  385. package/dist/github-dark-default-nWsHqmZA.js +0 -4
  386. package/dist/github-dark-dimmed-CZ-OQfZw.js +0 -4
  387. package/dist/github-dark-high-contrast-C3y_w9do.js +0 -4
  388. package/dist/github-light-CNXzdGuc.js +0 -4
  389. package/dist/github-light-default-C332Nkmd.js +0 -4
  390. package/dist/github-light-high-contrast-5fIb4Zrv.js +0 -4
  391. package/dist/gleam-CXNzRrCZ.js +0 -4
  392. package/dist/glimmer-js-gufzGuES.js +0 -14
  393. package/dist/glimmer-ts-D4X2QK5Z.js +0 -14
  394. package/dist/glsl-CImM3sHk.js +0 -5
  395. package/dist/glsl-DEg5Ez62.js +0 -4
  396. package/dist/gnuplot-CBwhenUK.js +0 -4
  397. package/dist/go-5JnSf2Sn.js +0 -4
  398. package/dist/go-DY_IL4bk.js +0 -4
  399. package/dist/graphql-BaqLgJ_M.js +0 -4
  400. package/dist/graphql-DL2bM2N0.js +0 -14
  401. package/dist/groovy-DZzbvCP1.js +0 -4
  402. package/dist/groovy-bcQsAePx.js +0 -4
  403. package/dist/gruvbox-dark-hard-9eAHcVSP.js +0 -4
  404. package/dist/gruvbox-dark-medium-BcwJobmL.js +0 -4
  405. package/dist/gruvbox-dark-soft-DFhXDq1u.js +0 -4
  406. package/dist/gruvbox-light-hard-CGFqWfyc.js +0 -4
  407. package/dist/gruvbox-light-medium-hf-MZPsQ.js +0 -4
  408. package/dist/gruvbox-light-soft-CEDN8Nz_.js +0 -4
  409. package/dist/hack-B8wSahCf.js +0 -10
  410. package/dist/haml-Bu4NUveo.js +0 -10
  411. package/dist/haml-DIZmvqcW.js +0 -4
  412. package/dist/handlebars-COjOLWnq.js +0 -14
  413. package/dist/haskell-CExLTzho.js +0 -4
  414. package/dist/haskell-DCN6ynrk.js +0 -4
  415. package/dist/haxe-Cop3U-K-.js +0 -4
  416. package/dist/haxe-Dwfa4QhR.js +0 -4
  417. package/dist/haxe-f3pVb8qU.js +0 -5
  418. package/dist/hcl-Db_02Xo4.js +0 -4
  419. package/dist/hjson-ChDlI-VU.js +0 -4
  420. package/dist/hlsl-Cqu4CHBc.js +0 -4
  421. package/dist/hlsl-DEFh66jF.js +0 -4
  422. package/dist/houston-B8kM6xwu.js +0 -4
  423. package/dist/html-derivative-D0ctPnGn.js +0 -4
  424. package/dist/html-derivative-Dtt7T8QF.js +0 -5
  425. package/dist/html-hTZprlyJ.js +0 -10
  426. package/dist/html-lq9Ir_fH.js +0 -4
  427. package/dist/http-csf0B_nN.js +0 -14
  428. package/dist/hxml-BwN3yN1f.js +0 -5
  429. package/dist/hy-BWKVYLAU.js +0 -4
  430. package/dist/idl-BbWlJ0gk.js +0 -4
  431. package/dist/imba-BdgJpELv.js +0 -4
  432. package/dist/ini--03_cr_s.js +0 -4
  433. package/dist/java-DgtnNxg2.js +0 -4
  434. package/dist/java-DxqbIJE2.js +0 -4
  435. package/dist/javascript-BdS4qSDJ.js +0 -4
  436. package/dist/javascript-eMOhp6Aq.js +0 -4
  437. package/dist/javascript-mK9HLbGj.js +0 -4
  438. package/dist/jinja-CDb6qdQt.js +0 -5
  439. package/dist/jison-DyKFip1k.js +0 -5
  440. package/dist/json-DMbsiPEv.js +0 -4
  441. package/dist/json-DeQXWHxY.js +0 -4
  442. package/dist/json5-COCd-fTe.js +0 -4
  443. package/dist/jsonc-B_GrcWIn.js +0 -4
  444. package/dist/jsonl-CI61BqMn.js +0 -4
  445. package/dist/jsonnet-BuWuUqqD.js +0 -4
  446. package/dist/jssm-D7Rh9Uc6.js +0 -4
  447. package/dist/jsx-CI1WNtr2.js +0 -4
  448. package/dist/jsx-Do4BHov2.js +0 -4
  449. package/dist/julia-C6w3Rvqb.js +0 -4
  450. package/dist/julia-D5XWzItl.js +0 -16
  451. package/dist/kanagawa-dragon-hLxsgONk.js +0 -4
  452. package/dist/kanagawa-lotus-BHRbOuiK.js +0 -4
  453. package/dist/kanagawa-wave-CjDPcOcS.js +0 -4
  454. package/dist/kotlin-Do-Dqx9m.js +0 -4
  455. package/dist/kusto-BeQOeA5N.js +0 -4
  456. package/dist/laserwave-ohbp9Jiz.js +0 -4
  457. package/dist/latex-DqJGIiu_.js +0 -5
  458. package/dist/lean-Clg9aEzr.js +0 -4
  459. package/dist/less-C3d7xP2W.js +0 -4
  460. package/dist/less-UHqrKu57.js +0 -4
  461. package/dist/light-plus-CSE8StgD.js +0 -4
  462. package/dist/liquid-Dqcanmhn.js +0 -14
  463. package/dist/livescript-ChQl9lD-.js +0 -4
  464. package/dist/llvm-DWkTGdnM.js +0 -4
  465. package/dist/log-CErlyO_4.js +0 -4
  466. package/dist/logo-Yu9llBXK.js +0 -4
  467. package/dist/lua-BFsKLCaI.js +0 -5
  468. package/dist/lua-CiDvI96j.js +0 -4
  469. package/dist/lua-GfOSGOZ-.js +0 -4
  470. package/dist/luau-JH-VfaDk.js +0 -4
  471. package/dist/make-B4hx8tTG.js +0 -4
  472. package/dist/markdown-BWuRHX75.js +0 -4
  473. package/dist/markdown-D07chUcD.js +0 -4
  474. package/dist/marked.esm-BiQFxVJV.js +0 -1373
  475. package/dist/marko-Bxd2zSuF.js +0 -14
  476. package/dist/material-theme-Caotz7xa.js +0 -4
  477. package/dist/material-theme-darker-DA3xYhnK.js +0 -4
  478. package/dist/material-theme-lighter-Dt5GVhSw.js +0 -4
  479. package/dist/material-theme-ocean-Cn25Md08.js +0 -4
  480. package/dist/material-theme-palenight-BChdM80H.js +0 -4
  481. package/dist/mathematica-ClVO4k7N.js +0 -4
  482. package/dist/matlab-DhbmgJrG.js +0 -4
  483. package/dist/mbox-BEI7DeUg.js +0 -4
  484. package/dist/mdc-6jIdEm7u.js +0 -12
  485. package/dist/mdx-DrOosndL.js +0 -4
  486. package/dist/mermaid-B4Jv70w2.js +0 -4
  487. package/dist/mermaid-D7wtYc6C.js +0 -94
  488. package/dist/mermaid-NA5CF7SZ-BUMY4R2n.js +0 -8
  489. package/dist/mermaid.core-BfgNMETw.js +0 -19
  490. package/dist/min-dark-BtkGP5of.js +0 -4
  491. package/dist/min-light-DVB0pOsq.js +0 -4
  492. package/dist/mipsasm-CbiVgyrL.js +0 -4
  493. package/dist/mirc-DwidJ3iH.js +0 -4
  494. package/dist/mllike-Dspdy0xJ.js +0 -6
  495. package/dist/modelica-CIUejP-L.js +0 -4
  496. package/dist/mojo-oCJmcfe0.js +0 -4
  497. package/dist/monokai-sXaBCV8W.js +0 -4
  498. package/dist/move-uqw57ayE.js +0 -4
  499. package/dist/mscgen-BWXU4Omp.js +0 -6
  500. package/dist/mumps-PHFFoPk5.js +0 -4
  501. package/dist/narrat-D5L3ivBF.js +0 -4
  502. package/dist/nextflow-Dzk2_1yO.js +0 -4
  503. package/dist/nginx-BsYwbveJ.js +0 -5
  504. package/dist/night-owl-bwU2KJrI.js +0 -4
  505. package/dist/nim-B9PRs1V9.js +0 -20
  506. package/dist/nix-CQXQnSxk.js +0 -4
  507. package/dist/nord-BIb_ag00.js +0 -4
  508. package/dist/nsis-B7xooKLf.js +0 -4
  509. package/dist/ntriples-DnOgtCzG.js +0 -4
  510. package/dist/nushell-9HBKTMRY.js +0 -4
  511. package/dist/objective-c-BdQwOoOq.js +0 -4
  512. package/dist/objective-cpp-Dnlxu7P8.js +0 -4
  513. package/dist/ocaml-BPPNJmg4.js +0 -4
  514. package/dist/octave-Cn5kH_QT.js +0 -4
  515. package/dist/one-dark-pro-Cf2MYqoR.js +0 -4
  516. package/dist/one-light-D4J9mH5L.js +0 -4
  517. package/dist/oz-DR-sROpu.js +0 -4
  518. package/dist/pascal-CPKK1zcS.js +0 -4
  519. package/dist/pascal-DZawRZnt.js +0 -4
  520. package/dist/perl-D7FuFdyd.js +0 -4
  521. package/dist/perl-DcaL6DAN.js +0 -16
  522. package/dist/php-C3dNQJ69.js +0 -4
  523. package/dist/php-CQBUGN8t.js +0 -18
  524. package/dist/pig-CEXnOAnI.js +0 -4
  525. package/dist/plastic-Bxetw03u.js +0 -4
  526. package/dist/plsql-Cr9PKKdd.js +0 -4
  527. package/dist/po-Buj9_8uj.js +0 -4
  528. package/dist/poimandres-f5X1KNHY.js +0 -4
  529. package/dist/polar-DaxpU9SY.js +0 -4
  530. package/dist/postcss-D0yHN3os.js +0 -4
  531. package/dist/postcss-_e11hEYq.js +0 -4
  532. package/dist/powerquery-BBrNhg4L.js +0 -4
  533. package/dist/powershell-BKvWab7q.js +0 -4
  534. package/dist/powershell-xOwLOHr7.js +0 -4
  535. package/dist/prisma-B6USmJON.js +0 -4
  536. package/dist/prolog-_-xlpTu3.js +0 -4
  537. package/dist/properties-7jnK_vYx.js +0 -4
  538. package/dist/proto-Fsc93mrf.js +0 -4
  539. package/dist/protobuf-4rslMjEN.js +0 -4
  540. package/dist/pug-BVwdEv4r.js +0 -4
  541. package/dist/pug-DQxLbQkr.js +0 -12
  542. package/dist/puppet-ClkE3Bbh.js +0 -4
  543. package/dist/puppet-iSHg_1Z2.js +0 -4
  544. package/dist/purescript-DBXsSG64.js +0 -4
  545. package/dist/python-Be-hJfoQ.js +0 -4
  546. package/dist/python-D8Qe4P9O.js +0 -4
  547. package/dist/python-tK3wUCn0.js +0 -4
  548. package/dist/q-DP_Dcoox.js +0 -4
  549. package/dist/qml-axZuKIq7.js +0 -5
  550. package/dist/qmldir-U7eiStHf.js +0 -4
  551. package/dist/qss-C6xK3i2A.js +0 -4
  552. package/dist/r-B8xYZSka.js +0 -4
  553. package/dist/r-Bj_pNGwX.js +0 -4
  554. package/dist/r-C32wHLYu.js +0 -4
  555. package/dist/racket-Bplgy3qa.js +0 -4
  556. package/dist/raku-CXfaTnnI.js +0 -4
  557. package/dist/razor-BUotMkk4.js +0 -10
  558. package/dist/react-vega-TDd7xMuh.js +0 -9
  559. package/dist/red-B23zS7fW.js +0 -4
  560. package/dist/reg-BOAFDp6X.js +0 -4
  561. package/dist/regexp-BQX_RqKY.js +0 -4
  562. package/dist/regexp-CgVCPIqt.js +0 -4
  563. package/dist/rel-C94onwJb.js +0 -4
  564. package/dist/riscv-DRS1x6ty.js +0 -4
  565. package/dist/rose-pine-Y3EcMiNE.js +0 -4
  566. package/dist/rose-pine-dawn-CdolLHqO.js +0 -4
  567. package/dist/rose-pine-moon-C_zpj202.js +0 -4
  568. package/dist/rpm-BbDBUfs9.js +0 -5
  569. package/dist/rst-CcbqEUWW.js +0 -22
  570. package/dist/ruby-CFajY3gR.js +0 -30
  571. package/dist/ruby-COfWUiIr.js +0 -4
  572. package/dist/ruby-zIsg3mjP.js +0 -4
  573. package/dist/rust-DBsDzz6s.js +0 -4
  574. package/dist/sas-4hY7456Y.js +0 -5
  575. package/dist/sas-y_Hue2-X.js +0 -4
  576. package/dist/sass-Cp8wMMoM.js +0 -4
  577. package/dist/scala-DYheJtuA.js +0 -4
  578. package/dist/scheme-7jTCqHw8.js +0 -4
  579. package/dist/scheme-CGftW0fR.js +0 -4
  580. package/dist/scss-C847tmc7.js +0 -5
  581. package/dist/scss-COYAhSrh.js +0 -4
  582. package/dist/sdbl-BVPPkqm9.js +0 -4
  583. package/dist/sdbl-LKt9ej7G.js +0 -4
  584. package/dist/shaderlab-D4RJoI87.js +0 -5
  585. package/dist/shell-DAqJWXDk.js +0 -4
  586. package/dist/shellscript-Bt_mtfyS.js +0 -4
  587. package/dist/shellscript-DTwJmk-B.js +0 -4
  588. package/dist/shellsession-BXPPO6fw.js +0 -5
  589. package/dist/sieve-EaqnbCO3.js +0 -4
  590. package/dist/slack-dark-D98uHpYH.js +0 -4
  591. package/dist/slack-ochin-D2JGK2Dx.js +0 -4
  592. package/dist/smalltalk-CJQ4atCz.js +0 -4
  593. package/dist/smalltalk-DL03YKLJ.js +0 -4
  594. package/dist/snazzy-light-BhqH4Tt0.js +0 -4
  595. package/dist/solarized-dark-Cz8Hpdk8.js +0 -4
  596. package/dist/solarized-light-DSXO0VGL.js +0 -4
  597. package/dist/solidity-nZ_5BOHX.js +0 -4
  598. package/dist/soy-C8ioljmY.js +0 -5
  599. package/dist/sparql-DTA-tQ_q.js +0 -4
  600. package/dist/sparql-ntHLy-Z_.js +0 -5
  601. package/dist/splunk-BDj1WtBS.js +0 -4
  602. package/dist/sql-B_CzXDN7.js +0 -4
  603. package/dist/sql-hBa00soP.js +0 -4
  604. package/dist/ssh-config-VL2EBnHI.js +0 -4
  605. package/dist/stata-CAE5q-ng.js +0 -5
  606. package/dist/stateDiagram-v2-4FDKWEC3-B4itMUHi.js +0 -30
  607. package/dist/stex-KfRnSHzF.js +0 -4
  608. package/dist/stylus-BI8hQQzs.js +0 -4
  609. package/dist/stylus-CfjeFry_.js +0 -4
  610. package/dist/stylus-DIZq08hz.js +0 -4
  611. package/dist/svelte-GcilG7nn.js +0 -14
  612. package/dist/swift-CVCEbRPJ.js +0 -4
  613. package/dist/swift-Dl0RRDbH.js +0 -4
  614. package/dist/synthwave-84-Brwqp6Rc.js +0 -4
  615. package/dist/system-verilog-oFNqWct0.js +0 -4
  616. package/dist/systemd-Dk99d5qb.js +0 -4
  617. package/dist/talonscript-oS-JP1qz.js +0 -4
  618. package/dist/tasl-eNb7V7lL.js +0 -4
  619. package/dist/tcl-CQPp2bcg.js +0 -4
  620. package/dist/tcl-wv9O7fLZ.js +0 -4
  621. package/dist/templ-CBxszNIk.js +0 -12
  622. package/dist/terraform-CdD8ZgoG.js +0 -4
  623. package/dist/tex-BDBUrlZ_.js +0 -4
  624. package/dist/tex-Drp1pMRL.js +0 -5
  625. package/dist/textile-DzMRCBcV.js +0 -4
  626. package/dist/tokyo-night-CmOikx9i.js +0 -4
  627. package/dist/toml-CyIWqgbe.js +0 -4
  628. package/dist/toml-oDtxM9oL.js +0 -4
  629. package/dist/troff-_huin_CY.js +0 -4
  630. package/dist/ts-tags-CXewkOF3.js +0 -38
  631. package/dist/tsv-BseyLYQT.js +0 -4
  632. package/dist/tsx-D2LUWtsu.js +0 -4
  633. package/dist/tsx-kHCj4PrF.js +0 -4
  634. package/dist/ttcn-BEiJuYYc.js +0 -4
  635. package/dist/ttcn-cfg-DB6Ksh67.js +0 -4
  636. package/dist/turtle-CzEhuAap.js +0 -4
  637. package/dist/turtle-Dv3esCo-.js +0 -4
  638. package/dist/turtle-DzhzGEum.js +0 -4
  639. package/dist/twig-qB_T-k-S.js +0 -18
  640. package/dist/typescript-BN_vTPvq.js +0 -4
  641. package/dist/typescript-CI5sQpw1.js +0 -4
  642. package/dist/typespec-DHEcpagp.js +0 -4
  643. package/dist/typst-B9HpBJka.js +0 -4
  644. package/dist/v-H2_8AIAM.js +0 -4
  645. package/dist/vala-WHi-ThcB.js +0 -4
  646. package/dist/vb-CS8PoU3R.js +0 -4
  647. package/dist/vb-CngKZQHu.js +0 -4
  648. package/dist/vbscript-BV_8nbeM.js +0 -4
  649. package/dist/velocity-IqE7qYKE.js +0 -4
  650. package/dist/verilog-BGgTS1pK.js +0 -4
  651. package/dist/verilog-xtyaWTnc.js +0 -4
  652. package/dist/vesper-2sgFZerP.js +0 -4
  653. package/dist/vhdl-7aI3JU7f.js +0 -4
  654. package/dist/vhdl-BaqXCtf3.js +0 -4
  655. package/dist/viml-C3IDTTfq.js +0 -4
  656. package/dist/vitesse-black-BvCrVr8N.js +0 -4
  657. package/dist/vitesse-dark-DNi7aZj7.js +0 -4
  658. package/dist/vitesse-light-CXSVQ3oK.js +0 -4
  659. package/dist/vue-CHooyK57.js +0 -4
  660. package/dist/vue-ChlIPquu.js +0 -22
  661. package/dist/vue-html-DPVg93T0.js +0 -10
  662. package/dist/vue-vine-HiBtkWC6.js +0 -20
  663. package/dist/vyper-D18q9xCG.js +0 -4
  664. package/dist/wasm-CRlswj2T.js +0 -6
  665. package/dist/wasm-DZ1eFFdg.js +0 -4
  666. package/dist/webidl-BDB8PTTO.js +0 -4
  667. package/dist/wenyan-D3TBOs3h.js +0 -4
  668. package/dist/wgsl-BCsR2nKB.js +0 -4
  669. package/dist/wikitext-DIh6m2jB.js +0 -4
  670. package/dist/wit-Bz-r96TS.js +0 -4
  671. package/dist/wolfram-VIrnwGuX.js +0 -4
  672. package/dist/xml-CAP1bJV9.js +0 -4
  673. package/dist/xml-HKKjDs8r.js +0 -5
  674. package/dist/xquery-BIC-qj9Z.js +0 -4
  675. package/dist/xsl-HaaO21x0.js +0 -5
  676. package/dist/yacas-ifv5tftd.js +0 -4
  677. package/dist/yaml-BTiN8kgB.js +0 -4
  678. package/dist/yaml-B_O-W3eE.js +0 -4
  679. package/dist/z80-B8zOMVNt.js +0 -4
  680. package/dist/zenscript-BrGwAsAB.js +0 -4
  681. package/dist/zig-Chio8vL6.js +0 -4
  682. /package/dist/{ImageComparisonComponent-DXQrGLfG.js → ImageComparisonComponent-Bijp8beW.js} +0 -0
  683. /package/dist/{_arrayReduce-BoSa0zEn.js → _arrayReduce-DlK7U3Q6.js} +0 -0
  684. /package/dist/{_hasUnicode-zxc9hjSW.js → _hasUnicode-Bz2x6u6r.js} +0 -0
  685. /package/dist/{apl-DRxKiEot.js → apl-D9gTcP3Q.js} +0 -0
  686. /package/dist/{array-D-nrDupM.js → array-D7wW5QoO.js} +0 -0
  687. /package/dist/{asciiarmor-C8HoXFIm.js → asciiarmor-mLyg-Z5h.js} +0 -0
  688. /package/dist/{asn1-9Bo0DYT-.js → asn1-AE7eHomk.js} +0 -0
  689. /package/dist/{asterisk-eIhOKJFP.js → asterisk-Crp-Pien.js} +0 -0
  690. /package/dist/{brainfuck-Db8njC-p.js → brainfuck-Bdd6NcL6.js} +0 -0
  691. /package/dist/{chunk-XAJISQIX-DhEh08v5.js → chunk-XAJISQIX-CZ8Bi1-x.js} +0 -0
  692. /package/dist/{click-outside-container-D90VWx_r.js → click-outside-container-BCN5BtVO.js} +0 -0
  693. /package/dist/{clike-CFhUNtI5.js → clike-D_s3fKg5.js} +0 -0
  694. /package/dist/{clojure-CX7oovsp.js → clojure-zTYBCd80.js} +0 -0
  695. /package/dist/{cmake-C29AR2kk.js → cmake-BnJV90fC.js} +0 -0
  696. /package/dist/{cobol-CNkuRW9i.js → cobol-CH0OZO8A.js} +0 -0
  697. /package/dist/{coffeescript-BJAbfGam.js → coffeescript-CLhc1U6Q.js} +0 -0
  698. /package/dist/{colors-6nB_pSln.js → colors-6DRQ0kEF.js} +0 -0
  699. /package/dist/{common-keywords-DDkFNc6Q.js → common-keywords-NhoiR-2S.js} +0 -0
  700. /package/dist/{commonlisp-BTNhj2l9.js → commonlisp-8K2-IkUD.js} +0 -0
  701. /package/dist/{constants-DuN_eoAL.js → constants-DrOu5vvd.js} +0 -0
  702. /package/dist/{crystal-CZc0nIm9.js → crystal-8to4H-ep.js} +0 -0
  703. /package/dist/{css-L2-0OTXc.js → css-BVo-JOy5.js} +0 -0
  704. /package/dist/{cypher-Dnc6MXl0.js → cypher-BTFaDDd_.js} +0 -0
  705. /package/dist/{cytoscape.esm-Cs5lDB24.js → cytoscape.esm-CgJFiP_E.js} +0 -0
  706. /package/dist/{d-C6X9iIga.js → d-c9bddW2W.js} +0 -0
  707. /package/dist/{defaultLocale-DMZFeDB8.js → defaultLocale-Bxoo2-30.js} +0 -0
  708. /package/dist/{defaultLocale-DZtxSCkJ.js → defaultLocale-qS7DaAmi.js} +0 -0
  709. /package/dist/{diff-ZzKinYqY.js → diff-PA28xMKg.js} +0 -0
  710. /package/dist/{dist-wEzfBIGs.js → dist-9J8_3DZN.js} +0 -0
  711. /package/dist/{dist-GFp3A63i.js → dist-9trj4p6n.js} +0 -0
  712. /package/dist/{dist-DJTgoown.js → dist-BKGWAN8J.js} +0 -0
  713. /package/dist/{dist-XmKjmDjd.js → dist-BSMZYwqW.js} +0 -0
  714. /package/dist/{dist-BjWd_Ei9.js → dist-BYznkC5E.js} +0 -0
  715. /package/dist/{dist-CQ1gja1c.js → dist-BbQ-5HAA.js} +0 -0
  716. /package/dist/{dist-DsOyFflT.js → dist-CPd_adhw.js} +0 -0
  717. /package/dist/{dist-BWkp5r3D.js → dist-Cpj5BHNP.js} +0 -0
  718. /package/dist/{dist-BbaKVjkP.js → dist-CsN7lsea.js} +0 -0
  719. /package/dist/{dist-DMO79xnD.js → dist-DIVeCGlI.js} +0 -0
  720. /package/dist/{dist-Bhe0YLr5.js → dist-DsqQCNKw.js} +0 -0
  721. /package/dist/{dist-BOmxya4k.js → dist-MFzhAmKV.js} +0 -0
  722. /package/dist/{dist-DYUqP2g4.js → dist-l0KayR2-.js} +0 -0
  723. /package/dist/{dtd-CytEpkAo.js → dtd-DRlC7Bx8.js} +0 -0
  724. /package/dist/{duckdb-keywords-q-LipmQC.js → duckdb-keywords-BnNtuiVz.js} +0 -0
  725. /package/dist/{dylan-CZByFBEQ.js → dylan-d5ufc25E.js} +0 -0
  726. /package/dist/{ebnf-DuGDVaIM.js → ebnf-CFKHGc8c.js} +0 -0
  727. /package/dist/{ecl-Cp7L1F5B.js → ecl-Ci3afVKc.js} +0 -0
  728. /package/dist/{eiffel-C66yjnFL.js → eiffel-G6DmeEi3.js} +0 -0
  729. /package/dist/{elm-DtHo-73e.js → elm-ByYWHu8b.js} +0 -0
  730. /package/dist/{emotion-is-prop-valid.esm-_z-EwK5u.js → emotion-is-prop-valid.esm--WpIBtj8.js} +0 -0
  731. /package/dist/{erlang-C_sj44mF.js → erlang-C7_LcVDw.js} +0 -0
  732. /package/dist/{esm-JeWm05ae.js → esm-CAd2HmbR.js} +0 -0
  733. /package/dist/{fcl-DtWOm1i5.js → fcl-DPZwieM9.js} +0 -0
  734. /package/dist/{forth-CIDHh56T.js → forth-BgUerAyz.js} +0 -0
  735. /package/dist/{fortran-BQrDVXRU.js → fortran-BCXxm4xF.js} +0 -0
  736. /package/dist/{gas-D4HQPB0Q.js → gas-CKTQRKLl.js} +0 -0
  737. /package/dist/{gherkin-UB2gJHdT.js → gherkin-ByVP9cY_.js} +0 -0
  738. /package/dist/{groovy-DVz6jkOx.js → groovy-BPbrw0GZ.js} +0 -0
  739. /package/dist/{haskell-CpUdAPCz.js → haskell-B8fq1DW4.js} +0 -0
  740. /package/dist/{haxe-DCV5_cqD.js → haxe-B7SHQmJo.js} +0 -0
  741. /package/dist/{http-Q5Xt0h8Z.js → http-AQJFxSug.js} +0 -0
  742. /package/dist/{idl-D7WCIgHw.js → idl-CeJBDjsl.js} +0 -0
  743. /package/dist/{init-Ci8VD8ZH.js → init-BfRhston.js} +0 -0
  744. /package/dist/{invariant-BW72tHBT.js → invariant-D9QLJ4SZ.js} +0 -0
  745. /package/dist/{isString-B0JuKBai.js → isString-Clqvtgmo.js} +0 -0
  746. /package/dist/{javascript-B2Rn0Lmd.js → javascript-dCv9_Kn8.js} +0 -0
  747. /package/dist/{julia-ApprtEaw.js → julia-CD5lO88_.js} +0 -0
  748. /package/dist/{katex-BTobf3T8.js → katex-Dm9nZf6A.js} +0 -0
  749. /package/dist/{livescript-BMLIlM7C.js → livescript-Cc8RvFBv.js} +0 -0
  750. /package/dist/{lua-DdDaW3tC.js → lua-4nedfnvd.js} +0 -0
  751. /package/dist/{main-DC-71ZOX.js → main-DhFbkwoC.js} +0 -0
  752. /package/dist/{math-HUZifhTs.js → math-BbMyrONz.js} +0 -0
  753. /package/dist/{mathematica-PnNN7c2Z.js → mathematica-BIufdZr2.js} +0 -0
  754. /package/dist/{mbox-B84OtHBK.js → mbox-DQkYSHKe.js} +0 -0
  755. /package/dist/{memoize-BctRJDZ2.js → memoize-Bag7B41I.js} +0 -0
  756. /package/dist/{mirc-BVWXJxIq.js → mirc-CI-RWqUR.js} +0 -0
  757. /package/dist/{mllike-BawXWupH.js → mllike-DQzbf1xo.js} +0 -0
  758. /package/dist/{modelica-C8-X4Hf_.js → modelica-BnF_cDWj.js} +0 -0
  759. /package/dist/{mscgen-BOM6dDj8.js → mscgen-MirFrDhW.js} +0 -0
  760. /package/dist/{mumps-DQOY8n05.js → mumps-eNRTuWOD.js} +0 -0
  761. /package/dist/{nginx-Ynlf_cSR.js → nginx-hpek_Tnq.js} +0 -0
  762. /package/dist/{node-sql-parser-DW04P3RY.js → node-sql-parser-ChQUJk8A.js} +0 -0
  763. /package/dist/{ntriples-DU8VrXdW.js → ntriples-BLneip4i.js} +0 -0
  764. /package/dist/{octave-BzTIBsQ8.js → octave-C0eG-pKq.js} +0 -0
  765. /package/dist/{oz-DKFcZsoi.js → oz-BPMLow2T.js} +0 -0
  766. /package/dist/{pascal-DHBZ15pT.js → pascal-5eb9v5Dl.js} +0 -0
  767. /package/dist/{path-BVI7RNUv.js → path-C_x2ySFi.js} +0 -0
  768. /package/dist/{perl-75NMI3w0.js → perl-DOu6rCkF.js} +0 -0
  769. /package/dist/{pig-B-HY1fo_.js → pig-CRW0kne3.js} +0 -0
  770. /package/dist/{powershell-DEH22U53.js → powershell-CWgJhiiJ.js} +0 -0
  771. /package/dist/{prop-types-DTzjue2h.js → prop-types-C9QZf2SY.js} +0 -0
  772. /package/dist/{properties-B1MzBoJC.js → properties-CHxpmfXW.js} +0 -0
  773. /package/dist/{protobuf-Dr14KV0p.js → protobuf-DGUXb_-T.js} +0 -0
  774. /package/dist/{puppet-C4z38l7v.js → puppet-C7uSiW6_.js} +0 -0
  775. /package/dist/{python-D2L7Nknt.js → python-DAbhVcUr.js} +0 -0
  776. /package/dist/{q-PxipHfgS.js → q-DKjWHias.js} +0 -0
  777. /package/dist/{r-CEMMu_Tf.js → r-KD2KhyeL.js} +0 -0
  778. /package/dist/{range-Bieq5MNc.js → range-BYuZFTbA.js} +0 -0
  779. /package/dist/{rpm-D3xyahkR.js → rpm-GFtnpQ6M.js} +0 -0
  780. /package/dist/{ruby-DwEkwdiu.js → ruby-CBAewzLY.js} +0 -0
  781. /package/dist/{sas-L1W0BRft.js → sas-CCi_AaZi.js} +0 -0
  782. /package/dist/{scheme-CTybTrX0.js → scheme-CGGGD6kR.js} +0 -0
  783. /package/dist/{shell-BSx3LZnu.js → shell-b7vZ8ucI.js} +0 -0
  784. /package/dist/{sieve-BjUfbv-6.js → sieve-ClXOUV85.js} +0 -0
  785. /package/dist/{simple-mode-IPZGFbI6.js → simple-mode-Uad4lEG7.js} +0 -0
  786. /package/dist/{smalltalk-BlzuYrMv.js → smalltalk-_PFt9_gp.js} +0 -0
  787. /package/dist/{solr-B0fQ5Uwe.js → solr-BSTJW269.js} +0 -0
  788. /package/dist/{sparql-BXKjQ0cK.js → sparql-BCF6qcHt.js} +0 -0
  789. /package/dist/{spreadsheet-o1pnCmTO.js → spreadsheet-CiBky1_y.js} +0 -0
  790. /package/dist/{sql-C_tD2xcJ.js → sql-BXZovj-z.js} +0 -0
  791. /package/dist/{stex-BIsgBmK4.js → stex-DrxP7bb3.js} +0 -0
  792. /package/dist/{stylus-CqrLLVnG.js → stylus-DMFZWz-G.js} +0 -0
  793. /package/dist/{swift-DIqvj3_G.js → swift-De2YpSxT.js} +0 -0
  794. /package/dist/{tcl-B8bOIGVK.js → tcl-jV8Xs_1k.js} +0 -0
  795. /package/dist/{textile-DZsjavD_.js → textile-D_zo778l.js} +0 -0
  796. /package/dist/{tiddlywiki-IyzniiDM.js → tiddlywiki-DLTDKQCh.js} +0 -0
  797. /package/dist/{tiki-Dw2XZEnT.js → tiki-tw_kBvbp.js} +0 -0
  798. /package/dist/{timer-CPsmIOdm.js → timer-pEiW44EO.js} +0 -0
  799. /package/dist/{toml-Uc7m08nl.js → toml-_M0gsKn5.js} +0 -0
  800. /package/dist/{treemap-DMn4tIJ7.js → treemap-BzS5cW_6.js} +0 -0
  801. /package/dist/{troff-GEl5wcXR.js → troff-B06gyD33.js} +0 -0
  802. /package/dist/{ttcn-pr4FDOLT.js → ttcn-DoQoQNUM.js} +0 -0
  803. /package/dist/{ttcn-cfg-dZQ_fWTH.js → ttcn-cfg-l_6PksD2.js} +0 -0
  804. /package/dist/{turtle-TPRDOknA.js → turtle-zEnD4bpn.js} +0 -0
  805. /package/dist/{vb-BJUAeTYr.js → vb-fUsnAuzb.js} +0 -0
  806. /package/dist/{vbscript-CcJ6Z3ic.js → vbscript-CVlD7uZQ.js} +0 -0
  807. /package/dist/{velocity-pq4ZMzU3.js → velocity-CHkEIdMC.js} +0 -0
  808. /package/dist/{verilog-timMNjHt.js → verilog-B3ctZTB4.js} +0 -0
  809. /package/dist/{vhdl-DYFbVKNm.js → vhdl-rXdBgR5O.js} +0 -0
  810. /package/dist/{webidl-pue9oqnb.js → webidl-Cv9aQfcc.js} +0 -0
  811. /package/dist/{xquery-DeItGynK.js → xquery-Du0w47aa.js} +0 -0
  812. /package/dist/{yacas-By2Qrjba.js → yacas-Eq4p_g3L.js} +0 -0
  813. /package/dist/{z80-C7iLsyPC.js → z80-Dz4HTTRf.js} +0 -0
  814. /package/dist/{zod-LbXVxiL9.js → zod-DITCj31F.js} +0 -0
@@ -0,0 +1,1838 @@
1
+ var __defProp = Object.defineProperty;
2
+ var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3
+ var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
4
+ var _a;
5
+ import { a as decodeEntities } from "./chunk-S3R3BYOJ-Ddu0H4Qa.js";
6
+ import { i as log, r as __name, t as select_default } from "./src-szye8OCw.js";
7
+ import { I as sanitizeText, N as renderKatexSanitized, O as hasKatex, s as common_default, y as getConfig } from "./chunk-ABZYJK2D-SZPYmRzN.js";
8
+ var defaultIconDimensions = Object.freeze({
9
+ left: 0,
10
+ top: 0,
11
+ width: 16,
12
+ height: 16
13
+ }), defaultIconTransformations = Object.freeze({
14
+ rotate: 0,
15
+ vFlip: false,
16
+ hFlip: false
17
+ }), defaultIconProps = Object.freeze({
18
+ ...defaultIconDimensions,
19
+ ...defaultIconTransformations
20
+ }), defaultExtendedIconProps = Object.freeze({
21
+ ...defaultIconProps,
22
+ body: "",
23
+ hidden: false
24
+ }), defaultIconSizeCustomisations = Object.freeze({
25
+ width: null,
26
+ height: null
27
+ }), defaultIconCustomisations = Object.freeze({
28
+ ...defaultIconSizeCustomisations,
29
+ ...defaultIconTransformations
30
+ }), stringToIcon = (e3, o, s, c = "") => {
31
+ let l = e3.split(":");
32
+ if (e3.slice(0, 1) === "@") {
33
+ if (l.length < 2 || l.length > 3) return null;
34
+ c = l.shift().slice(1);
35
+ }
36
+ if (l.length > 3 || !l.length) return null;
37
+ if (l.length > 1) {
38
+ let e4 = l.pop(), s2 = l.pop(), u2 = {
39
+ provider: l.length > 0 ? l[0] : c,
40
+ prefix: s2,
41
+ name: e4
42
+ };
43
+ return o && !validateIconName(u2) ? null : u2;
44
+ }
45
+ let u = l[0], f = u.split("-");
46
+ if (f.length > 1) {
47
+ let e4 = {
48
+ provider: c,
49
+ prefix: f.shift(),
50
+ name: f.join("-")
51
+ };
52
+ return o && !validateIconName(e4) ? null : e4;
53
+ }
54
+ if (s && c === "") {
55
+ let e4 = {
56
+ provider: c,
57
+ prefix: "",
58
+ name: u
59
+ };
60
+ return o && !validateIconName(e4, s) ? null : e4;
61
+ }
62
+ return null;
63
+ }, validateIconName = (e3, o) => e3 ? !!((o && e3.prefix === "" || e3.prefix) && e3.name) : false;
64
+ function mergeIconTransformations(e3, o) {
65
+ let s = {};
66
+ !e3.hFlip != !o.hFlip && (s.hFlip = true), !e3.vFlip != !o.vFlip && (s.vFlip = true);
67
+ let c = ((e3.rotate || 0) + (o.rotate || 0)) % 4;
68
+ return c && (s.rotate = c), s;
69
+ }
70
+ function mergeIconData(e3, o) {
71
+ let s = mergeIconTransformations(e3, o);
72
+ for (let c in defaultExtendedIconProps) c in defaultIconTransformations ? c in e3 && !(c in s) && (s[c] = defaultIconTransformations[c]) : c in o ? s[c] = o[c] : c in e3 && (s[c] = e3[c]);
73
+ return s;
74
+ }
75
+ function getIconsTree(e3, o) {
76
+ let s = e3.icons, c = e3.aliases || /* @__PURE__ */ Object.create(null), l = /* @__PURE__ */ Object.create(null);
77
+ function u(e4) {
78
+ if (s[e4]) return l[e4] = [];
79
+ if (!(e4 in l)) {
80
+ l[e4] = null;
81
+ let o2 = c[e4] && c[e4].parent, s2 = o2 && u(o2);
82
+ s2 && (l[e4] = [o2].concat(s2));
83
+ }
84
+ return l[e4];
85
+ }
86
+ return (o || Object.keys(s).concat(Object.keys(c))).forEach(u), l;
87
+ }
88
+ function internalGetIconData(e3, o, s) {
89
+ let c = e3.icons, l = e3.aliases || /* @__PURE__ */ Object.create(null), u = {};
90
+ function f(e4) {
91
+ u = mergeIconData(c[e4] || l[e4], u);
92
+ }
93
+ return f(o), s.forEach(f), mergeIconData(e3, u);
94
+ }
95
+ function getIconData(e3, o) {
96
+ if (e3.icons[o]) return internalGetIconData(e3, o, []);
97
+ let s = getIconsTree(e3, [o])[o];
98
+ return s ? internalGetIconData(e3, o, s) : null;
99
+ }
100
+ var unitsSplit = /(-?[0-9.]*[0-9]+[0-9.]*)/g, unitsTest = /^-?[0-9.]*[0-9]+[0-9.]*$/g;
101
+ function calculateSize(e3, o, s) {
102
+ if (o === 1) return e3;
103
+ if (s || (s = 100), typeof e3 == "number") return Math.ceil(e3 * o * s) / s;
104
+ if (typeof e3 != "string") return e3;
105
+ let c = e3.split(unitsSplit);
106
+ if (c === null || !c.length) return e3;
107
+ let l = [], u = c.shift(), f = unitsTest.test(u);
108
+ for (; ; ) {
109
+ if (f) {
110
+ let e4 = parseFloat(u);
111
+ isNaN(e4) ? l.push(u) : l.push(Math.ceil(e4 * o * s) / s);
112
+ } else l.push(u);
113
+ if (u = c.shift(), u === void 0) return l.join("");
114
+ f = !f;
115
+ }
116
+ }
117
+ function splitSVGDefs(e3, o = "defs") {
118
+ let s = "", c = e3.indexOf("<" + o);
119
+ for (; c >= 0; ) {
120
+ let l = e3.indexOf(">", c), u = e3.indexOf("</" + o);
121
+ if (l === -1 || u === -1) break;
122
+ let f = e3.indexOf(">", u);
123
+ if (f === -1) break;
124
+ s += e3.slice(l + 1, u).trim(), e3 = e3.slice(0, c).trim() + e3.slice(f + 1);
125
+ }
126
+ return {
127
+ defs: s,
128
+ content: e3
129
+ };
130
+ }
131
+ function mergeDefsAndContent(e3, o) {
132
+ return e3 ? "<defs>" + e3 + "</defs>" + o : o;
133
+ }
134
+ function wrapSVGContent(e3, o, s) {
135
+ let c = splitSVGDefs(e3);
136
+ return mergeDefsAndContent(c.defs, o + c.content + s);
137
+ }
138
+ var isUnsetKeyword = (e3) => e3 === "unset" || e3 === "undefined" || e3 === "none";
139
+ function iconToSVG(e3, o) {
140
+ let s = {
141
+ ...defaultIconProps,
142
+ ...e3
143
+ }, c = {
144
+ ...defaultIconCustomisations,
145
+ ...o
146
+ }, l = {
147
+ left: s.left,
148
+ top: s.top,
149
+ width: s.width,
150
+ height: s.height
151
+ }, u = s.body;
152
+ [s, c].forEach((e4) => {
153
+ let o2 = [], s2 = e4.hFlip, c2 = e4.vFlip, f2 = e4.rotate;
154
+ s2 ? c2 ? f2 += 2 : (o2.push("translate(" + (l.width + l.left).toString() + " " + (0 - l.top).toString() + ")"), o2.push("scale(-1 1)"), l.top = l.left = 0) : c2 && (o2.push("translate(" + (0 - l.left).toString() + " " + (l.height + l.top).toString() + ")"), o2.push("scale(1 -1)"), l.top = l.left = 0);
155
+ let p2;
156
+ switch (f2 < 0 && (f2 -= Math.floor(f2 / 4) * 4), f2 %= 4, f2) {
157
+ case 1:
158
+ p2 = l.height / 2 + l.top, o2.unshift("rotate(90 " + p2.toString() + " " + p2.toString() + ")");
159
+ break;
160
+ case 2:
161
+ o2.unshift("rotate(180 " + (l.width / 2 + l.left).toString() + " " + (l.height / 2 + l.top).toString() + ")");
162
+ break;
163
+ case 3:
164
+ p2 = l.width / 2 + l.left, o2.unshift("rotate(-90 " + p2.toString() + " " + p2.toString() + ")");
165
+ break;
166
+ }
167
+ f2 % 2 == 1 && (l.left !== l.top && (p2 = l.left, l.left = l.top, l.top = p2), l.width !== l.height && (p2 = l.width, l.width = l.height, l.height = p2)), o2.length && (u = wrapSVGContent(u, '<g transform="' + o2.join(" ") + '">', "</g>"));
168
+ });
169
+ let f = c.width, p = c.height, g = l.width, x = l.height, T, A;
170
+ f === null ? (A = p === null ? "1em" : p === "auto" ? x : p, T = calculateSize(A, g / x)) : (T = f === "auto" ? g : f, A = p === null ? calculateSize(T, x / g) : p === "auto" ? x : p);
171
+ let B = {}, Y = (e4, o2) => {
172
+ isUnsetKeyword(o2) || (B[e4] = o2.toString());
173
+ };
174
+ Y("width", T), Y("height", A);
175
+ let Z = [
176
+ l.left,
177
+ l.top,
178
+ g,
179
+ x
180
+ ];
181
+ return B.viewBox = Z.join(" "), {
182
+ attributes: B,
183
+ viewBox: Z,
184
+ body: u
185
+ };
186
+ }
187
+ var regex = /\sid="(\S+)"/g, randomPrefix = "IconifyId" + Date.now().toString(16) + (Math.random() * 16777216 | 0).toString(16), counter = 0;
188
+ function replaceIDs(e3, o = randomPrefix) {
189
+ let s = [], c;
190
+ for (; c = regex.exec(e3); ) s.push(c[1]);
191
+ if (!s.length) return e3;
192
+ let l = "suffix" + (Math.random() * 16777216 | Date.now()).toString(16);
193
+ return s.forEach((s2) => {
194
+ let c2 = typeof o == "function" ? o(s2) : o + (counter++).toString(), u = s2.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
195
+ e3 = e3.replace(RegExp('([#;"])(' + u + ')([")]|\\.[a-z])', "g"), "$1" + c2 + l + "$3");
196
+ }), e3 = e3.replace(new RegExp(l, "g"), ""), e3;
197
+ }
198
+ function iconToHTML(e3, o) {
199
+ let s = e3.indexOf("xlink:") === -1 ? "" : ' xmlns:xlink="http://www.w3.org/1999/xlink"';
200
+ for (let e4 in o) s += " " + e4 + '="' + o[e4] + '"';
201
+ return '<svg xmlns="http://www.w3.org/2000/svg"' + s + ">" + e3 + "</svg>";
202
+ }
203
+ function L() {
204
+ return {
205
+ async: false,
206
+ breaks: false,
207
+ extensions: null,
208
+ gfm: true,
209
+ hooks: null,
210
+ pedantic: false,
211
+ renderer: null,
212
+ silent: false,
213
+ tokenizer: null,
214
+ walkTokens: null
215
+ };
216
+ }
217
+ var O = L();
218
+ function H(e3) {
219
+ O = e3;
220
+ }
221
+ var E = { exec: () => null };
222
+ function h(e3, o = "") {
223
+ let s = typeof e3 == "string" ? e3 : e3.source, c = {
224
+ replace: (e4, o2) => {
225
+ let l = typeof o2 == "string" ? o2 : o2.source;
226
+ return l = l.replace(m.caret, "$1"), s = s.replace(e4, l), c;
227
+ },
228
+ getRegex: () => new RegExp(s, o)
229
+ };
230
+ return c;
231
+ }
232
+ var m = {
233
+ codeRemoveIndent: /^(?: {1,4}| {0,3}\t)/gm,
234
+ outputLinkReplace: /\\([\[\]])/g,
235
+ indentCodeCompensation: /^(\s+)(?:```)/,
236
+ beginningSpace: /^\s+/,
237
+ endingHash: /#$/,
238
+ startingSpaceChar: /^ /,
239
+ endingSpaceChar: / $/,
240
+ nonSpaceChar: /[^ ]/,
241
+ newLineCharGlobal: /\n/g,
242
+ tabCharGlobal: /\t/g,
243
+ multipleSpaceGlobal: /\s+/g,
244
+ blankLine: /^[ \t]*$/,
245
+ doubleBlankLine: /\n[ \t]*\n[ \t]*$/,
246
+ blockquoteStart: /^ {0,3}>/,
247
+ blockquoteSetextReplace: /\n {0,3}((?:=+|-+) *)(?=\n|$)/g,
248
+ blockquoteSetextReplace2: /^ {0,3}>[ \t]?/gm,
249
+ listReplaceTabs: /^\t+/,
250
+ listReplaceNesting: /^ {1,4}(?=( {4})*[^ ])/g,
251
+ listIsTask: /^\[[ xX]\] /,
252
+ listReplaceTask: /^\[[ xX]\] +/,
253
+ anyLine: /\n.*\n/,
254
+ hrefBrackets: /^<(.*)>$/,
255
+ tableDelimiter: /[:|]/,
256
+ tableAlignChars: /^\||\| *$/g,
257
+ tableRowBlankLine: /\n[ \t]*$/,
258
+ tableAlignRight: /^ *-+: *$/,
259
+ tableAlignCenter: /^ *:-+: *$/,
260
+ tableAlignLeft: /^ *:-+ *$/,
261
+ startATag: /^<a /i,
262
+ endATag: /^<\/a>/i,
263
+ startPreScriptTag: /^<(pre|code|kbd|script)(\s|>)/i,
264
+ endPreScriptTag: /^<\/(pre|code|kbd|script)(\s|>)/i,
265
+ startAngleBracket: /^</,
266
+ endAngleBracket: />$/,
267
+ pedanticHrefTitle: /^([^'"]*[^\s])\s+(['"])(.*)\2/,
268
+ unicodeAlphaNumeric: /[\p{L}\p{N}]/u,
269
+ escapeTest: /[&<>"']/,
270
+ escapeReplace: /[&<>"']/g,
271
+ escapeTestNoEncode: /[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,
272
+ escapeReplaceNoEncode: /[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,
273
+ unescapeTest: /&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/gi,
274
+ caret: /(^|[^\[])\^/g,
275
+ percentDecode: /%25/g,
276
+ findPipe: /\|/g,
277
+ splitPipe: / \|/,
278
+ slashPipe: /\\\|/g,
279
+ carriageReturn: /\r\n|\r/g,
280
+ spaceLine: /^ +$/gm,
281
+ notSpaceStart: /^\S*/,
282
+ endingNewline: /\n$/,
283
+ listItemRegex: (e3) => /* @__PURE__ */ RegExp(`^( {0,3}${e3})((?:[ ][^\\n]*)?(?:\\n|$))`),
284
+ nextBulletRegex: (e3) => /* @__PURE__ */ RegExp(`^ {0,${Math.min(3, e3 - 1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`),
285
+ hrRegex: (e3) => /* @__PURE__ */ RegExp(`^ {0,${Math.min(3, e3 - 1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),
286
+ fencesBeginRegex: (e3) => /* @__PURE__ */ RegExp(`^ {0,${Math.min(3, e3 - 1)}}(?:\`\`\`|~~~)`),
287
+ headingBeginRegex: (e3) => /* @__PURE__ */ RegExp(`^ {0,${Math.min(3, e3 - 1)}}#`),
288
+ htmlBeginRegex: (e3) => RegExp(`^ {0,${Math.min(3, e3 - 1)}}<(?:[a-z].*>|!--)`, "i")
289
+ }, xe = /^(?:[ \t]*(?:\n|$))+/, be = /^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/, Re = /^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/, C = /^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/, Oe = /^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/, j = /(?:[*+-]|\d{1,9}[.)])/, se = /^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/, ie = h(se).replace(/bull/g, j).replace(/blockCode/g, /(?: {4}| {0,3}\t)/).replace(/fences/g, / {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g, / {0,3}>/).replace(/heading/g, / {0,3}#{1,6}/).replace(/html/g, / {0,3}<[^\n>]+>\n/).replace(/\|table/g, "").getRegex(), Te = h(se).replace(/bull/g, j).replace(/blockCode/g, /(?: {4}| {0,3}\t)/).replace(/fences/g, / {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g, / {0,3}>/).replace(/heading/g, / {0,3}#{1,6}/).replace(/html/g, / {0,3}<[^\n>]+>\n/).replace(/table/g, / {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(), F = /^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/, we = /^[^\n]+/, Q = /(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/, ye = h(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label", Q).replace("title", /(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(), Pe = h(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g, j).getRegex(), v = "address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul", U = /<!--(?:-?>|[\s\S]*?(?:-->|$))/, Se = h("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))", "i").replace("comment", U).replace("tag", v).replace("attribute", / +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(), oe = h(F).replace("hr", C).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("|lheading", "").replace("|table", "").replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", v).getRegex(), K = {
290
+ blockquote: h(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph", oe).getRegex(),
291
+ code: be,
292
+ def: ye,
293
+ fences: Re,
294
+ heading: Oe,
295
+ hr: C,
296
+ html: Se,
297
+ lheading: ie,
298
+ list: Pe,
299
+ newline: xe,
300
+ paragraph: oe,
301
+ table: E,
302
+ text: we
303
+ }, re = h("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr", C).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("blockquote", " {0,3}>").replace("code", "(?: {4}| {0,3} )[^\\n]").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", v).getRegex(), _e = {
304
+ ...K,
305
+ lheading: Te,
306
+ table: re,
307
+ paragraph: h(F).replace("hr", C).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("|lheading", "").replace("table", re).replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", v).getRegex()
308
+ }, Le = {
309
+ ...K,
310
+ html: h(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment", U).replace(/tag/g, "(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),
311
+ def: /^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,
312
+ heading: /^(#{1,6})(.*)(?:\n+|$)/,
313
+ fences: E,
314
+ lheading: /^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,
315
+ paragraph: h(F).replace("hr", C).replace("heading", " *#{1,6} *[^\n]").replace("lheading", ie).replace("|table", "").replace("blockquote", " {0,3}>").replace("|fences", "").replace("|list", "").replace("|html", "").replace("|tag", "").getRegex()
316
+ }, Me = /^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/, ze = /^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/, ae = /^( {2,}|\\)\n(?!\s*$)/, Ae = /^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/, D = /[\p{P}\p{S}]/u, W = /[\s\p{P}\p{S}]/u, le = /[^\s\p{P}\p{S}]/u, Ee = h(/^((?![*_])punctSpace)/, "u").replace(/punctSpace/g, W).getRegex(), ue = /(?!~)[\p{P}\p{S}]/u, Ce = /(?!~)[\s\p{P}\p{S}]/u, Ie = /(?:[^\s\p{P}\p{S}]|~)/u, Be = /\[[^\[\]]*?\]\((?:\\[\s\S]|[^\\\(\)]|\((?:\\[\s\S]|[^\\\(\)])*\))*\)|`[^`]*?`|<(?! )[^<>]*?>/g, pe = /^(?:\*+(?:((?!\*)punct)|[^\s*]))|^_+(?:((?!_)punct)|([^\s_]))/, qe = h(pe, "u").replace(/punct/g, D).getRegex(), ve = h(pe, "u").replace(/punct/g, ue).getRegex(), ce = "^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)", De = h(ce, "gu").replace(/notPunctSpace/g, le).replace(/punctSpace/g, W).replace(/punct/g, D).getRegex(), Ze = h(ce, "gu").replace(/notPunctSpace/g, Ie).replace(/punctSpace/g, Ce).replace(/punct/g, ue).getRegex(), Ge = h("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)", "gu").replace(/notPunctSpace/g, le).replace(/punctSpace/g, W).replace(/punct/g, D).getRegex(), He = h(/\\(punct)/, "gu").replace(/punct/g, D).getRegex(), Ne = h(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme", /[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email", /[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(), je = h(U).replace("(?:-->|$)", "-->").getRegex(), Fe = h("^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>").replace("comment", je).replace("attribute", /\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(), q = /(?:\[(?:\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`[^`]*`|[^\[\]\\`])*?/, Qe = h(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]*(?:\n[ \t]*)?)(title))?\s*\)/).replace("label", q).replace("href", /<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace("title", /"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(), he = h(/^!?\[(label)\]\[(ref)\]/).replace("label", q).replace("ref", Q).getRegex(), de = h(/^!?\[(ref)\](?:\[\])?/).replace("ref", Q).getRegex(), X = {
317
+ _backpedal: E,
318
+ anyPunctuation: He,
319
+ autolink: Ne,
320
+ blockSkip: Be,
321
+ br: ae,
322
+ code: ze,
323
+ del: E,
324
+ emStrongLDelim: qe,
325
+ emStrongRDelimAst: De,
326
+ emStrongRDelimUnd: Ge,
327
+ escape: Me,
328
+ link: Qe,
329
+ nolink: de,
330
+ punctuation: Ee,
331
+ reflink: he,
332
+ reflinkSearch: h("reflink|nolink(?!\\()", "g").replace("reflink", he).replace("nolink", de).getRegex(),
333
+ tag: Fe,
334
+ text: Ae,
335
+ url: E
336
+ }, Ke = {
337
+ ...X,
338
+ link: h(/^!?\[(label)\]\((.*?)\)/).replace("label", q).getRegex(),
339
+ reflink: h(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label", q).getRegex()
340
+ }, N = {
341
+ ...X,
342
+ emStrongRDelimAst: Ze,
343
+ emStrongLDelim: ve,
344
+ url: h(/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/, "i").replace("email", /[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),
345
+ _backpedal: /(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,
346
+ del: /^(~~?)(?=[^\s~])((?:\\[\s\S]|[^\\])*?(?:\\[\s\S]|[^\s~\\]))\1(?=[^~]|$)/,
347
+ text: /^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|https?:\/\/|ftp:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/
348
+ }, We = {
349
+ ...N,
350
+ br: h(ae).replace("{2,}", "*").getRegex(),
351
+ text: h(N.text).replace("\\b_", "\\b_| {2,}\\n").replace(/\{2,\}/g, "*").getRegex()
352
+ }, I = {
353
+ normal: K,
354
+ gfm: _e,
355
+ pedantic: Le
356
+ }, M = {
357
+ normal: X,
358
+ gfm: N,
359
+ breaks: We,
360
+ pedantic: Ke
361
+ }, Xe = {
362
+ "&": "&amp;",
363
+ "<": "&lt;",
364
+ ">": "&gt;",
365
+ '"': "&quot;",
366
+ "'": "&#39;"
367
+ }, ke = (e3) => Xe[e3];
368
+ function w(e3, o) {
369
+ if (o) {
370
+ if (m.escapeTest.test(e3)) return e3.replace(m.escapeReplace, ke);
371
+ } else if (m.escapeTestNoEncode.test(e3)) return e3.replace(m.escapeReplaceNoEncode, ke);
372
+ return e3;
373
+ }
374
+ function J(e3) {
375
+ try {
376
+ e3 = encodeURI(e3).replace(m.percentDecode, "%");
377
+ } catch {
378
+ return null;
379
+ }
380
+ return e3;
381
+ }
382
+ function V(e3, o) {
383
+ var _a2;
384
+ let s = e3.replace(m.findPipe, (e4, o2, s2) => {
385
+ let c2 = false, l = o2;
386
+ for (; --l >= 0 && s2[l] === "\\"; ) c2 = !c2;
387
+ return c2 ? "|" : " |";
388
+ }).split(m.splitPipe), c = 0;
389
+ if (s[0].trim() || s.shift(), s.length > 0 && !((_a2 = s.at(-1)) == null ? void 0 : _a2.trim()) && s.pop(), o) if (s.length > o) s.splice(o);
390
+ else for (; s.length < o; ) s.push("");
391
+ for (; c < s.length; c++) s[c] = s[c].trim().replace(m.slashPipe, "|");
392
+ return s;
393
+ }
394
+ function z(e3, o, s) {
395
+ let c = e3.length;
396
+ if (c === 0) return "";
397
+ let l = 0;
398
+ for (; l < c; ) {
399
+ let u = e3.charAt(c - l - 1);
400
+ if (u === o && !s) l++;
401
+ else if (u !== o && s) l++;
402
+ else break;
403
+ }
404
+ return e3.slice(0, c - l);
405
+ }
406
+ function ge(e3, o) {
407
+ if (e3.indexOf(o[1]) === -1) return -1;
408
+ let s = 0;
409
+ for (let c = 0; c < e3.length; c++) if (e3[c] === "\\") c++;
410
+ else if (e3[c] === o[0]) s++;
411
+ else if (e3[c] === o[1] && (s--, s < 0)) return c;
412
+ return s > 0 ? -2 : -1;
413
+ }
414
+ function fe(e3, o, s, c, l) {
415
+ let u = o.href, f = o.title || null, p = e3[1].replace(l.other.outputLinkReplace, "$1");
416
+ c.state.inLink = true;
417
+ let g = {
418
+ type: e3[0].charAt(0) === "!" ? "image" : "link",
419
+ raw: s,
420
+ href: u,
421
+ title: f,
422
+ text: p,
423
+ tokens: c.inlineTokens(p)
424
+ };
425
+ return c.state.inLink = false, g;
426
+ }
427
+ function Je(e3, o, s) {
428
+ let c = e3.match(s.other.indentCodeCompensation);
429
+ if (c === null) return o;
430
+ let l = c[1];
431
+ return o.split("\n").map((e4) => {
432
+ let o2 = e4.match(s.other.beginningSpace);
433
+ if (o2 === null) return e4;
434
+ let [c2] = o2;
435
+ return c2.length >= l.length ? e4.slice(l.length) : e4;
436
+ }).join("\n");
437
+ }
438
+ var y = class {
439
+ constructor(e3) {
440
+ __publicField(this, "options");
441
+ __publicField(this, "rules");
442
+ __publicField(this, "lexer");
443
+ this.options = e3 || O;
444
+ }
445
+ space(e3) {
446
+ let o = this.rules.block.newline.exec(e3);
447
+ if (o && o[0].length > 0) return {
448
+ type: "space",
449
+ raw: o[0]
450
+ };
451
+ }
452
+ code(e3) {
453
+ let o = this.rules.block.code.exec(e3);
454
+ if (o) {
455
+ let e4 = o[0].replace(this.rules.other.codeRemoveIndent, "");
456
+ return {
457
+ type: "code",
458
+ raw: o[0],
459
+ codeBlockStyle: "indented",
460
+ text: this.options.pedantic ? e4 : z(e4, "\n")
461
+ };
462
+ }
463
+ }
464
+ fences(e3) {
465
+ let o = this.rules.block.fences.exec(e3);
466
+ if (o) {
467
+ let e4 = o[0], s = Je(e4, o[3] || "", this.rules);
468
+ return {
469
+ type: "code",
470
+ raw: e4,
471
+ lang: o[2] ? o[2].trim().replace(this.rules.inline.anyPunctuation, "$1") : o[2],
472
+ text: s
473
+ };
474
+ }
475
+ }
476
+ heading(e3) {
477
+ let o = this.rules.block.heading.exec(e3);
478
+ if (o) {
479
+ let e4 = o[2].trim();
480
+ if (this.rules.other.endingHash.test(e4)) {
481
+ let o2 = z(e4, "#");
482
+ (this.options.pedantic || !o2 || this.rules.other.endingSpaceChar.test(o2)) && (e4 = o2.trim());
483
+ }
484
+ return {
485
+ type: "heading",
486
+ raw: o[0],
487
+ depth: o[1].length,
488
+ text: e4,
489
+ tokens: this.lexer.inline(e4)
490
+ };
491
+ }
492
+ }
493
+ hr(e3) {
494
+ let o = this.rules.block.hr.exec(e3);
495
+ if (o) return {
496
+ type: "hr",
497
+ raw: z(o[0], "\n")
498
+ };
499
+ }
500
+ blockquote(e3) {
501
+ let o = this.rules.block.blockquote.exec(e3);
502
+ if (o) {
503
+ let e4 = z(o[0], "\n").split("\n"), s = "", c = "", l = [];
504
+ for (; e4.length > 0; ) {
505
+ let o2 = false, u = [], f;
506
+ for (f = 0; f < e4.length; f++) if (this.rules.other.blockquoteStart.test(e4[f])) u.push(e4[f]), o2 = true;
507
+ else if (!o2) u.push(e4[f]);
508
+ else break;
509
+ e4 = e4.slice(f);
510
+ let p = u.join("\n"), g = p.replace(this.rules.other.blockquoteSetextReplace, "\n $1").replace(this.rules.other.blockquoteSetextReplace2, "");
511
+ s = s ? `${s}
512
+ ${p}` : p, c = c ? `${c}
513
+ ${g}` : g;
514
+ let x = this.lexer.state.top;
515
+ if (this.lexer.state.top = true, this.lexer.blockTokens(g, l, true), this.lexer.state.top = x, e4.length === 0) break;
516
+ let T = l.at(-1);
517
+ if ((T == null ? void 0 : T.type) === "code") break;
518
+ if ((T == null ? void 0 : T.type) === "blockquote") {
519
+ let o3 = T, u2 = o3.raw + "\n" + e4.join("\n"), f2 = this.blockquote(u2);
520
+ l[l.length - 1] = f2, s = s.substring(0, s.length - o3.raw.length) + f2.raw, c = c.substring(0, c.length - o3.text.length) + f2.text;
521
+ break;
522
+ } else if ((T == null ? void 0 : T.type) === "list") {
523
+ let o3 = T, u2 = o3.raw + "\n" + e4.join("\n"), f2 = this.list(u2);
524
+ l[l.length - 1] = f2, s = s.substring(0, s.length - T.raw.length) + f2.raw, c = c.substring(0, c.length - o3.raw.length) + f2.raw, e4 = u2.substring(l.at(-1).raw.length).split("\n");
525
+ continue;
526
+ }
527
+ }
528
+ return {
529
+ type: "blockquote",
530
+ raw: s,
531
+ tokens: l,
532
+ text: c
533
+ };
534
+ }
535
+ }
536
+ list(e3) {
537
+ let o = this.rules.block.list.exec(e3);
538
+ if (o) {
539
+ let s = o[1].trim(), c = s.length > 1, l = {
540
+ type: "list",
541
+ raw: "",
542
+ ordered: c,
543
+ start: c ? +s.slice(0, -1) : "",
544
+ loose: false,
545
+ items: []
546
+ };
547
+ s = c ? `\\d{1,9}\\${s.slice(-1)}` : `\\${s}`, this.options.pedantic && (s = c ? s : "[*+-]");
548
+ let u = this.rules.other.listItemRegex(s), f = false;
549
+ for (; e3; ) {
550
+ let s2 = false, c2 = "", p2 = "";
551
+ if (!(o = u.exec(e3)) || this.rules.block.hr.test(e3)) break;
552
+ c2 = o[0], e3 = e3.substring(c2.length);
553
+ let g = o[2].split("\n", 1)[0].replace(this.rules.other.listReplaceTabs, (e4) => " ".repeat(3 * e4.length)), x = e3.split("\n", 1)[0], T = !g.trim(), k = 0;
554
+ if (this.options.pedantic ? (k = 2, p2 = g.trimStart()) : T ? k = o[1].length + 1 : (k = o[2].search(this.rules.other.nonSpaceChar), k = k > 4 ? 1 : k, p2 = g.slice(k), k += o[1].length), T && this.rules.other.blankLine.test(x) && (c2 += x + "\n", e3 = e3.substring(x.length + 1), s2 = true), !s2) {
555
+ let o2 = this.rules.other.nextBulletRegex(k), s3 = this.rules.other.hrRegex(k), l2 = this.rules.other.fencesBeginRegex(k), u2 = this.rules.other.headingBeginRegex(k), f2 = this.rules.other.htmlBeginRegex(k);
556
+ for (; e3; ) {
557
+ let A2 = e3.split("\n", 1)[0], B2;
558
+ if (x = A2, this.options.pedantic ? (x = x.replace(this.rules.other.listReplaceNesting, " "), B2 = x) : B2 = x.replace(this.rules.other.tabCharGlobal, " "), l2.test(x) || u2.test(x) || f2.test(x) || o2.test(x) || s3.test(x)) break;
559
+ if (B2.search(this.rules.other.nonSpaceChar) >= k || !x.trim()) p2 += "\n" + B2.slice(k);
560
+ else {
561
+ if (T || g.replace(this.rules.other.tabCharGlobal, " ").search(this.rules.other.nonSpaceChar) >= 4 || l2.test(g) || u2.test(g) || s3.test(g)) break;
562
+ p2 += "\n" + x;
563
+ }
564
+ !T && !x.trim() && (T = true), c2 += A2 + "\n", e3 = e3.substring(A2.length + 1), g = B2.slice(k);
565
+ }
566
+ }
567
+ l.loose || (f ? l.loose = true : this.rules.other.doubleBlankLine.test(c2) && (f = true));
568
+ let A = null, B;
569
+ this.options.gfm && (A = this.rules.other.listIsTask.exec(p2), A && (B = A[0] !== "[ ] ", p2 = p2.replace(this.rules.other.listReplaceTask, ""))), l.items.push({
570
+ type: "list_item",
571
+ raw: c2,
572
+ task: !!A,
573
+ checked: B,
574
+ loose: false,
575
+ text: p2,
576
+ tokens: []
577
+ }), l.raw += c2;
578
+ }
579
+ let p = l.items.at(-1);
580
+ if (p) p.raw = p.raw.trimEnd(), p.text = p.text.trimEnd();
581
+ else return;
582
+ l.raw = l.raw.trimEnd();
583
+ for (let e4 = 0; e4 < l.items.length; e4++) if (this.lexer.state.top = false, l.items[e4].tokens = this.lexer.blockTokens(l.items[e4].text, []), !l.loose) {
584
+ let o2 = l.items[e4].tokens.filter((e5) => e5.type === "space");
585
+ l.loose = o2.length > 0 && o2.some((e5) => this.rules.other.anyLine.test(e5.raw));
586
+ }
587
+ if (l.loose) for (let e4 = 0; e4 < l.items.length; e4++) l.items[e4].loose = true;
588
+ return l;
589
+ }
590
+ }
591
+ html(e3) {
592
+ let o = this.rules.block.html.exec(e3);
593
+ if (o) return {
594
+ type: "html",
595
+ block: true,
596
+ raw: o[0],
597
+ pre: o[1] === "pre" || o[1] === "script" || o[1] === "style",
598
+ text: o[0]
599
+ };
600
+ }
601
+ def(e3) {
602
+ let o = this.rules.block.def.exec(e3);
603
+ if (o) {
604
+ let e4 = o[1].toLowerCase().replace(this.rules.other.multipleSpaceGlobal, " "), s = o[2] ? o[2].replace(this.rules.other.hrefBrackets, "$1").replace(this.rules.inline.anyPunctuation, "$1") : "", c = o[3] ? o[3].substring(1, o[3].length - 1).replace(this.rules.inline.anyPunctuation, "$1") : o[3];
605
+ return {
606
+ type: "def",
607
+ tag: e4,
608
+ raw: o[0],
609
+ href: s,
610
+ title: c
611
+ };
612
+ }
613
+ }
614
+ table(e3) {
615
+ var _a2;
616
+ let o = this.rules.block.table.exec(e3);
617
+ if (!o || !this.rules.other.tableDelimiter.test(o[2])) return;
618
+ let s = V(o[1]), c = o[2].replace(this.rules.other.tableAlignChars, "").split("|"), l = ((_a2 = o[3]) == null ? void 0 : _a2.trim()) ? o[3].replace(this.rules.other.tableRowBlankLine, "").split("\n") : [], u = {
619
+ type: "table",
620
+ raw: o[0],
621
+ header: [],
622
+ align: [],
623
+ rows: []
624
+ };
625
+ if (s.length === c.length) {
626
+ for (let e4 of c) this.rules.other.tableAlignRight.test(e4) ? u.align.push("right") : this.rules.other.tableAlignCenter.test(e4) ? u.align.push("center") : this.rules.other.tableAlignLeft.test(e4) ? u.align.push("left") : u.align.push(null);
627
+ for (let e4 = 0; e4 < s.length; e4++) u.header.push({
628
+ text: s[e4],
629
+ tokens: this.lexer.inline(s[e4]),
630
+ header: true,
631
+ align: u.align[e4]
632
+ });
633
+ for (let e4 of l) u.rows.push(V(e4, u.header.length).map((e5, o2) => ({
634
+ text: e5,
635
+ tokens: this.lexer.inline(e5),
636
+ header: false,
637
+ align: u.align[o2]
638
+ })));
639
+ return u;
640
+ }
641
+ }
642
+ lheading(e3) {
643
+ let o = this.rules.block.lheading.exec(e3);
644
+ if (o) return {
645
+ type: "heading",
646
+ raw: o[0],
647
+ depth: o[2].charAt(0) === "=" ? 1 : 2,
648
+ text: o[1],
649
+ tokens: this.lexer.inline(o[1])
650
+ };
651
+ }
652
+ paragraph(e3) {
653
+ let o = this.rules.block.paragraph.exec(e3);
654
+ if (o) {
655
+ let e4 = o[1].charAt(o[1].length - 1) === "\n" ? o[1].slice(0, -1) : o[1];
656
+ return {
657
+ type: "paragraph",
658
+ raw: o[0],
659
+ text: e4,
660
+ tokens: this.lexer.inline(e4)
661
+ };
662
+ }
663
+ }
664
+ text(e3) {
665
+ let o = this.rules.block.text.exec(e3);
666
+ if (o) return {
667
+ type: "text",
668
+ raw: o[0],
669
+ text: o[0],
670
+ tokens: this.lexer.inline(o[0])
671
+ };
672
+ }
673
+ escape(e3) {
674
+ let o = this.rules.inline.escape.exec(e3);
675
+ if (o) return {
676
+ type: "escape",
677
+ raw: o[0],
678
+ text: o[1]
679
+ };
680
+ }
681
+ tag(e3) {
682
+ let o = this.rules.inline.tag.exec(e3);
683
+ if (o) return !this.lexer.state.inLink && this.rules.other.startATag.test(o[0]) ? this.lexer.state.inLink = true : this.lexer.state.inLink && this.rules.other.endATag.test(o[0]) && (this.lexer.state.inLink = false), !this.lexer.state.inRawBlock && this.rules.other.startPreScriptTag.test(o[0]) ? this.lexer.state.inRawBlock = true : this.lexer.state.inRawBlock && this.rules.other.endPreScriptTag.test(o[0]) && (this.lexer.state.inRawBlock = false), {
684
+ type: "html",
685
+ raw: o[0],
686
+ inLink: this.lexer.state.inLink,
687
+ inRawBlock: this.lexer.state.inRawBlock,
688
+ block: false,
689
+ text: o[0]
690
+ };
691
+ }
692
+ link(e3) {
693
+ let o = this.rules.inline.link.exec(e3);
694
+ if (o) {
695
+ let e4 = o[2].trim();
696
+ if (!this.options.pedantic && this.rules.other.startAngleBracket.test(e4)) {
697
+ if (!this.rules.other.endAngleBracket.test(e4)) return;
698
+ let o2 = z(e4.slice(0, -1), "\\");
699
+ if ((e4.length - o2.length) % 2 == 0) return;
700
+ } else {
701
+ let e5 = ge(o[2], "()");
702
+ if (e5 === -2) return;
703
+ if (e5 > -1) {
704
+ let s2 = (o[0].indexOf("!") === 0 ? 5 : 4) + o[1].length + e5;
705
+ o[2] = o[2].substring(0, e5), o[0] = o[0].substring(0, s2).trim(), o[3] = "";
706
+ }
707
+ }
708
+ let s = o[2], c = "";
709
+ if (this.options.pedantic) {
710
+ let e5 = this.rules.other.pedanticHrefTitle.exec(s);
711
+ e5 && (s = e5[1], c = e5[3]);
712
+ } else c = o[3] ? o[3].slice(1, -1) : "";
713
+ return s = s.trim(), this.rules.other.startAngleBracket.test(s) && (s = this.options.pedantic && !this.rules.other.endAngleBracket.test(e4) ? s.slice(1) : s.slice(1, -1)), fe(o, {
714
+ href: s && s.replace(this.rules.inline.anyPunctuation, "$1"),
715
+ title: c && c.replace(this.rules.inline.anyPunctuation, "$1")
716
+ }, o[0], this.lexer, this.rules);
717
+ }
718
+ }
719
+ reflink(e3, o) {
720
+ let s;
721
+ if ((s = this.rules.inline.reflink.exec(e3)) || (s = this.rules.inline.nolink.exec(e3))) {
722
+ let e4 = o[(s[2] || s[1]).replace(this.rules.other.multipleSpaceGlobal, " ").toLowerCase()];
723
+ if (!e4) {
724
+ let e5 = s[0].charAt(0);
725
+ return {
726
+ type: "text",
727
+ raw: e5,
728
+ text: e5
729
+ };
730
+ }
731
+ return fe(s, e4, s[0], this.lexer, this.rules);
732
+ }
733
+ }
734
+ emStrong(e3, o, s = "") {
735
+ let c = this.rules.inline.emStrongLDelim.exec(e3);
736
+ if (!(!c || c[3] && s.match(this.rules.other.unicodeAlphaNumeric)) && (!(c[1] || c[2]) || !s || this.rules.inline.punctuation.exec(s))) {
737
+ let s2 = [...c[0]].length - 1, l, u, f = s2, p = 0, g = c[0][0] === "*" ? this.rules.inline.emStrongRDelimAst : this.rules.inline.emStrongRDelimUnd;
738
+ for (g.lastIndex = 0, o = o.slice(-1 * e3.length + s2); (c = g.exec(o)) != null; ) {
739
+ if (l = c[1] || c[2] || c[3] || c[4] || c[5] || c[6], !l) continue;
740
+ if (u = [...l].length, c[3] || c[4]) {
741
+ f += u;
742
+ continue;
743
+ } else if ((c[5] || c[6]) && s2 % 3 && !((s2 + u) % 3)) {
744
+ p += u;
745
+ continue;
746
+ }
747
+ if (f -= u, f > 0) continue;
748
+ u = Math.min(u, u + f + p);
749
+ let o2 = [...c[0]][0].length, g2 = e3.slice(0, s2 + c.index + o2 + u);
750
+ if (Math.min(s2, u) % 2) {
751
+ let e4 = g2.slice(1, -1);
752
+ return {
753
+ type: "em",
754
+ raw: g2,
755
+ text: e4,
756
+ tokens: this.lexer.inlineTokens(e4)
757
+ };
758
+ }
759
+ let x = g2.slice(2, -2);
760
+ return {
761
+ type: "strong",
762
+ raw: g2,
763
+ text: x,
764
+ tokens: this.lexer.inlineTokens(x)
765
+ };
766
+ }
767
+ }
768
+ }
769
+ codespan(e3) {
770
+ let o = this.rules.inline.code.exec(e3);
771
+ if (o) {
772
+ let e4 = o[2].replace(this.rules.other.newLineCharGlobal, " "), s = this.rules.other.nonSpaceChar.test(e4), c = this.rules.other.startingSpaceChar.test(e4) && this.rules.other.endingSpaceChar.test(e4);
773
+ return s && c && (e4 = e4.substring(1, e4.length - 1)), {
774
+ type: "codespan",
775
+ raw: o[0],
776
+ text: e4
777
+ };
778
+ }
779
+ }
780
+ br(e3) {
781
+ let o = this.rules.inline.br.exec(e3);
782
+ if (o) return {
783
+ type: "br",
784
+ raw: o[0]
785
+ };
786
+ }
787
+ del(e3) {
788
+ let o = this.rules.inline.del.exec(e3);
789
+ if (o) return {
790
+ type: "del",
791
+ raw: o[0],
792
+ text: o[2],
793
+ tokens: this.lexer.inlineTokens(o[2])
794
+ };
795
+ }
796
+ autolink(e3) {
797
+ let o = this.rules.inline.autolink.exec(e3);
798
+ if (o) {
799
+ let e4, s;
800
+ return o[2] === "@" ? (e4 = o[1], s = "mailto:" + e4) : (e4 = o[1], s = e4), {
801
+ type: "link",
802
+ raw: o[0],
803
+ text: e4,
804
+ href: s,
805
+ tokens: [{
806
+ type: "text",
807
+ raw: e4,
808
+ text: e4
809
+ }]
810
+ };
811
+ }
812
+ }
813
+ url(e3) {
814
+ var _a2;
815
+ let o;
816
+ if (o = this.rules.inline.url.exec(e3)) {
817
+ let e4, s;
818
+ if (o[2] === "@") e4 = o[0], s = "mailto:" + e4;
819
+ else {
820
+ let c;
821
+ do
822
+ c = o[0], o[0] = ((_a2 = this.rules.inline._backpedal.exec(o[0])) == null ? void 0 : _a2[0]) ?? "";
823
+ while (c !== o[0]);
824
+ e4 = o[0], s = o[1] === "www." ? "http://" + o[0] : o[0];
825
+ }
826
+ return {
827
+ type: "link",
828
+ raw: o[0],
829
+ text: e4,
830
+ href: s,
831
+ tokens: [{
832
+ type: "text",
833
+ raw: e4,
834
+ text: e4
835
+ }]
836
+ };
837
+ }
838
+ }
839
+ inlineText(e3) {
840
+ let o = this.rules.inline.text.exec(e3);
841
+ if (o) {
842
+ let e4 = this.lexer.state.inRawBlock;
843
+ return {
844
+ type: "text",
845
+ raw: o[0],
846
+ text: o[0],
847
+ escaped: e4
848
+ };
849
+ }
850
+ }
851
+ }, b = class e {
852
+ constructor(e3) {
853
+ __publicField(this, "tokens");
854
+ __publicField(this, "options");
855
+ __publicField(this, "state");
856
+ __publicField(this, "tokenizer");
857
+ __publicField(this, "inlineQueue");
858
+ this.tokens = [], this.tokens.links = /* @__PURE__ */ Object.create(null), this.options = e3 || O, this.options.tokenizer = this.options.tokenizer || new y(), this.tokenizer = this.options.tokenizer, this.tokenizer.options = this.options, this.tokenizer.lexer = this, this.inlineQueue = [], this.state = {
859
+ inLink: false,
860
+ inRawBlock: false,
861
+ top: true
862
+ };
863
+ let o = {
864
+ other: m,
865
+ block: I.normal,
866
+ inline: M.normal
867
+ };
868
+ this.options.pedantic ? (o.block = I.pedantic, o.inline = M.pedantic) : this.options.gfm && (o.block = I.gfm, this.options.breaks ? o.inline = M.breaks : o.inline = M.gfm), this.tokenizer.rules = o;
869
+ }
870
+ static get rules() {
871
+ return {
872
+ block: I,
873
+ inline: M
874
+ };
875
+ }
876
+ static lex(o, s) {
877
+ return new e(s).lex(o);
878
+ }
879
+ static lexInline(o, s) {
880
+ return new e(s).inlineTokens(o);
881
+ }
882
+ lex(e3) {
883
+ e3 = e3.replace(m.carriageReturn, "\n"), this.blockTokens(e3, this.tokens);
884
+ for (let e4 = 0; e4 < this.inlineQueue.length; e4++) {
885
+ let o = this.inlineQueue[e4];
886
+ this.inlineTokens(o.src, o.tokens);
887
+ }
888
+ return this.inlineQueue = [], this.tokens;
889
+ }
890
+ blockTokens(e3, o = [], s = false) {
891
+ var _a2, _b, _c;
892
+ for (this.options.pedantic && (e3 = e3.replace(m.tabCharGlobal, " ").replace(m.spaceLine, "")); e3; ) {
893
+ let c;
894
+ if ((_b = (_a2 = this.options.extensions) == null ? void 0 : _a2.block) == null ? void 0 : _b.some((s2) => (c = s2.call({ lexer: this }, e3, o)) ? (e3 = e3.substring(c.raw.length), o.push(c), true) : false)) continue;
895
+ if (c = this.tokenizer.space(e3)) {
896
+ e3 = e3.substring(c.raw.length);
897
+ let s2 = o.at(-1);
898
+ c.raw.length === 1 && s2 !== void 0 ? s2.raw += "\n" : o.push(c);
899
+ continue;
900
+ }
901
+ if (c = this.tokenizer.code(e3)) {
902
+ e3 = e3.substring(c.raw.length);
903
+ let s2 = o.at(-1);
904
+ (s2 == null ? void 0 : s2.type) === "paragraph" || (s2 == null ? void 0 : s2.type) === "text" ? (s2.raw += (s2.raw.endsWith("\n") ? "" : "\n") + c.raw, s2.text += "\n" + c.text, this.inlineQueue.at(-1).src = s2.text) : o.push(c);
905
+ continue;
906
+ }
907
+ if (c = this.tokenizer.fences(e3)) {
908
+ e3 = e3.substring(c.raw.length), o.push(c);
909
+ continue;
910
+ }
911
+ if (c = this.tokenizer.heading(e3)) {
912
+ e3 = e3.substring(c.raw.length), o.push(c);
913
+ continue;
914
+ }
915
+ if (c = this.tokenizer.hr(e3)) {
916
+ e3 = e3.substring(c.raw.length), o.push(c);
917
+ continue;
918
+ }
919
+ if (c = this.tokenizer.blockquote(e3)) {
920
+ e3 = e3.substring(c.raw.length), o.push(c);
921
+ continue;
922
+ }
923
+ if (c = this.tokenizer.list(e3)) {
924
+ e3 = e3.substring(c.raw.length), o.push(c);
925
+ continue;
926
+ }
927
+ if (c = this.tokenizer.html(e3)) {
928
+ e3 = e3.substring(c.raw.length), o.push(c);
929
+ continue;
930
+ }
931
+ if (c = this.tokenizer.def(e3)) {
932
+ e3 = e3.substring(c.raw.length);
933
+ let s2 = o.at(-1);
934
+ (s2 == null ? void 0 : s2.type) === "paragraph" || (s2 == null ? void 0 : s2.type) === "text" ? (s2.raw += (s2.raw.endsWith("\n") ? "" : "\n") + c.raw, s2.text += "\n" + c.raw, this.inlineQueue.at(-1).src = s2.text) : this.tokens.links[c.tag] || (this.tokens.links[c.tag] = {
935
+ href: c.href,
936
+ title: c.title
937
+ }, o.push(c));
938
+ continue;
939
+ }
940
+ if (c = this.tokenizer.table(e3)) {
941
+ e3 = e3.substring(c.raw.length), o.push(c);
942
+ continue;
943
+ }
944
+ if (c = this.tokenizer.lheading(e3)) {
945
+ e3 = e3.substring(c.raw.length), o.push(c);
946
+ continue;
947
+ }
948
+ let l = e3;
949
+ if ((_c = this.options.extensions) == null ? void 0 : _c.startBlock) {
950
+ let o2 = Infinity, s2 = e3.slice(1), c2;
951
+ this.options.extensions.startBlock.forEach((e4) => {
952
+ c2 = e4.call({ lexer: this }, s2), typeof c2 == "number" && c2 >= 0 && (o2 = Math.min(o2, c2));
953
+ }), o2 < Infinity && o2 >= 0 && (l = e3.substring(0, o2 + 1));
954
+ }
955
+ if (this.state.top && (c = this.tokenizer.paragraph(l))) {
956
+ let u = o.at(-1);
957
+ s && (u == null ? void 0 : u.type) === "paragraph" ? (u.raw += (u.raw.endsWith("\n") ? "" : "\n") + c.raw, u.text += "\n" + c.text, this.inlineQueue.pop(), this.inlineQueue.at(-1).src = u.text) : o.push(c), s = l.length !== e3.length, e3 = e3.substring(c.raw.length);
958
+ continue;
959
+ }
960
+ if (c = this.tokenizer.text(e3)) {
961
+ e3 = e3.substring(c.raw.length);
962
+ let s2 = o.at(-1);
963
+ (s2 == null ? void 0 : s2.type) === "text" ? (s2.raw += (s2.raw.endsWith("\n") ? "" : "\n") + c.raw, s2.text += "\n" + c.text, this.inlineQueue.pop(), this.inlineQueue.at(-1).src = s2.text) : o.push(c);
964
+ continue;
965
+ }
966
+ if (e3) {
967
+ let o2 = "Infinite loop on byte: " + e3.charCodeAt(0);
968
+ if (this.options.silent) {
969
+ console.error(o2);
970
+ break;
971
+ } else throw Error(o2);
972
+ }
973
+ }
974
+ return this.state.top = true, o;
975
+ }
976
+ inline(e3, o = []) {
977
+ return this.inlineQueue.push({
978
+ src: e3,
979
+ tokens: o
980
+ }), o;
981
+ }
982
+ inlineTokens(e3, o = []) {
983
+ var _a2, _b, _c;
984
+ let s = e3, c = null;
985
+ if (this.tokens.links) {
986
+ let e4 = Object.keys(this.tokens.links);
987
+ if (e4.length > 0) for (; (c = this.tokenizer.rules.inline.reflinkSearch.exec(s)) != null; ) e4.includes(c[0].slice(c[0].lastIndexOf("[") + 1, -1)) && (s = s.slice(0, c.index) + "[" + "a".repeat(c[0].length - 2) + "]" + s.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex));
988
+ }
989
+ for (; (c = this.tokenizer.rules.inline.anyPunctuation.exec(s)) != null; ) s = s.slice(0, c.index) + "++" + s.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);
990
+ for (; (c = this.tokenizer.rules.inline.blockSkip.exec(s)) != null; ) s = s.slice(0, c.index) + "[" + "a".repeat(c[0].length - 2) + "]" + s.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);
991
+ let l = false, u = "";
992
+ for (; e3; ) {
993
+ l || (u = ""), l = false;
994
+ let c2;
995
+ if ((_b = (_a2 = this.options.extensions) == null ? void 0 : _a2.inline) == null ? void 0 : _b.some((s2) => (c2 = s2.call({ lexer: this }, e3, o)) ? (e3 = e3.substring(c2.raw.length), o.push(c2), true) : false)) continue;
996
+ if (c2 = this.tokenizer.escape(e3)) {
997
+ e3 = e3.substring(c2.raw.length), o.push(c2);
998
+ continue;
999
+ }
1000
+ if (c2 = this.tokenizer.tag(e3)) {
1001
+ e3 = e3.substring(c2.raw.length), o.push(c2);
1002
+ continue;
1003
+ }
1004
+ if (c2 = this.tokenizer.link(e3)) {
1005
+ e3 = e3.substring(c2.raw.length), o.push(c2);
1006
+ continue;
1007
+ }
1008
+ if (c2 = this.tokenizer.reflink(e3, this.tokens.links)) {
1009
+ e3 = e3.substring(c2.raw.length);
1010
+ let s2 = o.at(-1);
1011
+ c2.type === "text" && (s2 == null ? void 0 : s2.type) === "text" ? (s2.raw += c2.raw, s2.text += c2.text) : o.push(c2);
1012
+ continue;
1013
+ }
1014
+ if (c2 = this.tokenizer.emStrong(e3, s, u)) {
1015
+ e3 = e3.substring(c2.raw.length), o.push(c2);
1016
+ continue;
1017
+ }
1018
+ if (c2 = this.tokenizer.codespan(e3)) {
1019
+ e3 = e3.substring(c2.raw.length), o.push(c2);
1020
+ continue;
1021
+ }
1022
+ if (c2 = this.tokenizer.br(e3)) {
1023
+ e3 = e3.substring(c2.raw.length), o.push(c2);
1024
+ continue;
1025
+ }
1026
+ if (c2 = this.tokenizer.del(e3)) {
1027
+ e3 = e3.substring(c2.raw.length), o.push(c2);
1028
+ continue;
1029
+ }
1030
+ if (c2 = this.tokenizer.autolink(e3)) {
1031
+ e3 = e3.substring(c2.raw.length), o.push(c2);
1032
+ continue;
1033
+ }
1034
+ if (!this.state.inLink && (c2 = this.tokenizer.url(e3))) {
1035
+ e3 = e3.substring(c2.raw.length), o.push(c2);
1036
+ continue;
1037
+ }
1038
+ let f = e3;
1039
+ if ((_c = this.options.extensions) == null ? void 0 : _c.startInline) {
1040
+ let o2 = Infinity, s2 = e3.slice(1), c3;
1041
+ this.options.extensions.startInline.forEach((e4) => {
1042
+ c3 = e4.call({ lexer: this }, s2), typeof c3 == "number" && c3 >= 0 && (o2 = Math.min(o2, c3));
1043
+ }), o2 < Infinity && o2 >= 0 && (f = e3.substring(0, o2 + 1));
1044
+ }
1045
+ if (c2 = this.tokenizer.inlineText(f)) {
1046
+ e3 = e3.substring(c2.raw.length), c2.raw.slice(-1) !== "_" && (u = c2.raw.slice(-1)), l = true;
1047
+ let s2 = o.at(-1);
1048
+ (s2 == null ? void 0 : s2.type) === "text" ? (s2.raw += c2.raw, s2.text += c2.text) : o.push(c2);
1049
+ continue;
1050
+ }
1051
+ if (e3) {
1052
+ let o2 = "Infinite loop on byte: " + e3.charCodeAt(0);
1053
+ if (this.options.silent) {
1054
+ console.error(o2);
1055
+ break;
1056
+ } else throw Error(o2);
1057
+ }
1058
+ }
1059
+ return o;
1060
+ }
1061
+ }, P = class {
1062
+ constructor(e3) {
1063
+ __publicField(this, "options");
1064
+ __publicField(this, "parser");
1065
+ this.options = e3 || O;
1066
+ }
1067
+ space(e3) {
1068
+ return "";
1069
+ }
1070
+ code({ text: e3, lang: o, escaped: s }) {
1071
+ var _a2;
1072
+ let c = (_a2 = (o || "").match(m.notSpaceStart)) == null ? void 0 : _a2[0], l = e3.replace(m.endingNewline, "") + "\n";
1073
+ return c ? '<pre><code class="language-' + w(c) + '">' + (s ? l : w(l, true)) + "</code></pre>\n" : "<pre><code>" + (s ? l : w(l, true)) + "</code></pre>\n";
1074
+ }
1075
+ blockquote({ tokens: e3 }) {
1076
+ return `<blockquote>
1077
+ ${this.parser.parse(e3)}</blockquote>
1078
+ `;
1079
+ }
1080
+ html({ text: e3 }) {
1081
+ return e3;
1082
+ }
1083
+ def(e3) {
1084
+ return "";
1085
+ }
1086
+ heading({ tokens: e3, depth: o }) {
1087
+ return `<h${o}>${this.parser.parseInline(e3)}</h${o}>
1088
+ `;
1089
+ }
1090
+ hr(e3) {
1091
+ return "<hr>\n";
1092
+ }
1093
+ list(e3) {
1094
+ let o = e3.ordered, s = e3.start, c = "";
1095
+ for (let o2 = 0; o2 < e3.items.length; o2++) {
1096
+ let s2 = e3.items[o2];
1097
+ c += this.listitem(s2);
1098
+ }
1099
+ let l = o ? "ol" : "ul", u = o && s !== 1 ? ' start="' + s + '"' : "";
1100
+ return "<" + l + u + ">\n" + c + "</" + l + ">\n";
1101
+ }
1102
+ listitem(e3) {
1103
+ var _a2;
1104
+ let o = "";
1105
+ if (e3.task) {
1106
+ let s = this.checkbox({ checked: !!e3.checked });
1107
+ e3.loose ? ((_a2 = e3.tokens[0]) == null ? void 0 : _a2.type) === "paragraph" ? (e3.tokens[0].text = s + " " + e3.tokens[0].text, e3.tokens[0].tokens && e3.tokens[0].tokens.length > 0 && e3.tokens[0].tokens[0].type === "text" && (e3.tokens[0].tokens[0].text = s + " " + w(e3.tokens[0].tokens[0].text), e3.tokens[0].tokens[0].escaped = true)) : e3.tokens.unshift({
1108
+ type: "text",
1109
+ raw: s + " ",
1110
+ text: s + " ",
1111
+ escaped: true
1112
+ }) : o += s + " ";
1113
+ }
1114
+ return o += this.parser.parse(e3.tokens, !!e3.loose), `<li>${o}</li>
1115
+ `;
1116
+ }
1117
+ checkbox({ checked: e3 }) {
1118
+ return "<input " + (e3 ? 'checked="" ' : "") + 'disabled="" type="checkbox">';
1119
+ }
1120
+ paragraph({ tokens: e3 }) {
1121
+ return `<p>${this.parser.parseInline(e3)}</p>
1122
+ `;
1123
+ }
1124
+ table(e3) {
1125
+ let o = "", s = "";
1126
+ for (let o2 = 0; o2 < e3.header.length; o2++) s += this.tablecell(e3.header[o2]);
1127
+ o += this.tablerow({ text: s });
1128
+ let c = "";
1129
+ for (let o2 = 0; o2 < e3.rows.length; o2++) {
1130
+ let l = e3.rows[o2];
1131
+ s = "";
1132
+ for (let e4 = 0; e4 < l.length; e4++) s += this.tablecell(l[e4]);
1133
+ c += this.tablerow({ text: s });
1134
+ }
1135
+ return c && (c = `<tbody>${c}</tbody>`), "<table>\n<thead>\n" + o + "</thead>\n" + c + "</table>\n";
1136
+ }
1137
+ tablerow({ text: e3 }) {
1138
+ return `<tr>
1139
+ ${e3}</tr>
1140
+ `;
1141
+ }
1142
+ tablecell(e3) {
1143
+ let o = this.parser.parseInline(e3.tokens), s = e3.header ? "th" : "td";
1144
+ return (e3.align ? `<${s} align="${e3.align}">` : `<${s}>`) + o + `</${s}>
1145
+ `;
1146
+ }
1147
+ strong({ tokens: e3 }) {
1148
+ return `<strong>${this.parser.parseInline(e3)}</strong>`;
1149
+ }
1150
+ em({ tokens: e3 }) {
1151
+ return `<em>${this.parser.parseInline(e3)}</em>`;
1152
+ }
1153
+ codespan({ text: e3 }) {
1154
+ return `<code>${w(e3, true)}</code>`;
1155
+ }
1156
+ br(e3) {
1157
+ return "<br>";
1158
+ }
1159
+ del({ tokens: e3 }) {
1160
+ return `<del>${this.parser.parseInline(e3)}</del>`;
1161
+ }
1162
+ link({ href: e3, title: o, tokens: s }) {
1163
+ let c = this.parser.parseInline(s), l = J(e3);
1164
+ if (l === null) return c;
1165
+ e3 = l;
1166
+ let u = '<a href="' + e3 + '"';
1167
+ return o && (u += ' title="' + w(o) + '"'), u += ">" + c + "</a>", u;
1168
+ }
1169
+ image({ href: e3, title: o, text: s, tokens: c }) {
1170
+ c && (s = this.parser.parseInline(c, this.parser.textRenderer));
1171
+ let l = J(e3);
1172
+ if (l === null) return w(s);
1173
+ e3 = l;
1174
+ let u = `<img src="${e3}" alt="${s}"`;
1175
+ return o && (u += ` title="${w(o)}"`), u += ">", u;
1176
+ }
1177
+ text(e3) {
1178
+ return "tokens" in e3 && e3.tokens ? this.parser.parseInline(e3.tokens) : "escaped" in e3 && e3.escaped ? e3.text : w(e3.text);
1179
+ }
1180
+ }, S = class {
1181
+ strong({ text: e3 }) {
1182
+ return e3;
1183
+ }
1184
+ em({ text: e3 }) {
1185
+ return e3;
1186
+ }
1187
+ codespan({ text: e3 }) {
1188
+ return e3;
1189
+ }
1190
+ del({ text: e3 }) {
1191
+ return e3;
1192
+ }
1193
+ html({ text: e3 }) {
1194
+ return e3;
1195
+ }
1196
+ text({ text: e3 }) {
1197
+ return e3;
1198
+ }
1199
+ link({ text: e3 }) {
1200
+ return "" + e3;
1201
+ }
1202
+ image({ text: e3 }) {
1203
+ return "" + e3;
1204
+ }
1205
+ br() {
1206
+ return "";
1207
+ }
1208
+ }, R = class e2 {
1209
+ constructor(e3) {
1210
+ __publicField(this, "options");
1211
+ __publicField(this, "renderer");
1212
+ __publicField(this, "textRenderer");
1213
+ this.options = e3 || O, this.options.renderer = this.options.renderer || new P(), this.renderer = this.options.renderer, this.renderer.options = this.options, this.renderer.parser = this, this.textRenderer = new S();
1214
+ }
1215
+ static parse(o, s) {
1216
+ return new e2(s).parse(o);
1217
+ }
1218
+ static parseInline(o, s) {
1219
+ return new e2(s).parseInline(o);
1220
+ }
1221
+ parse(e3, o = true) {
1222
+ var _a2, _b;
1223
+ let s = "";
1224
+ for (let c = 0; c < e3.length; c++) {
1225
+ let l = e3[c];
1226
+ if ((_b = (_a2 = this.options.extensions) == null ? void 0 : _a2.renderers) == null ? void 0 : _b[l.type]) {
1227
+ let e4 = l, o2 = this.options.extensions.renderers[e4.type].call({ parser: this }, e4);
1228
+ if (o2 !== false || ![
1229
+ "space",
1230
+ "hr",
1231
+ "heading",
1232
+ "code",
1233
+ "table",
1234
+ "blockquote",
1235
+ "list",
1236
+ "html",
1237
+ "def",
1238
+ "paragraph",
1239
+ "text"
1240
+ ].includes(e4.type)) {
1241
+ s += o2 || "";
1242
+ continue;
1243
+ }
1244
+ }
1245
+ let u = l;
1246
+ switch (u.type) {
1247
+ case "space":
1248
+ s += this.renderer.space(u);
1249
+ continue;
1250
+ case "hr":
1251
+ s += this.renderer.hr(u);
1252
+ continue;
1253
+ case "heading":
1254
+ s += this.renderer.heading(u);
1255
+ continue;
1256
+ case "code":
1257
+ s += this.renderer.code(u);
1258
+ continue;
1259
+ case "table":
1260
+ s += this.renderer.table(u);
1261
+ continue;
1262
+ case "blockquote":
1263
+ s += this.renderer.blockquote(u);
1264
+ continue;
1265
+ case "list":
1266
+ s += this.renderer.list(u);
1267
+ continue;
1268
+ case "html":
1269
+ s += this.renderer.html(u);
1270
+ continue;
1271
+ case "def":
1272
+ s += this.renderer.def(u);
1273
+ continue;
1274
+ case "paragraph":
1275
+ s += this.renderer.paragraph(u);
1276
+ continue;
1277
+ case "text": {
1278
+ let l2 = u, f = this.renderer.text(l2);
1279
+ for (; c + 1 < e3.length && e3[c + 1].type === "text"; ) l2 = e3[++c], f += "\n" + this.renderer.text(l2);
1280
+ o ? s += this.renderer.paragraph({
1281
+ type: "paragraph",
1282
+ raw: f,
1283
+ text: f,
1284
+ tokens: [{
1285
+ type: "text",
1286
+ raw: f,
1287
+ text: f,
1288
+ escaped: true
1289
+ }]
1290
+ }) : s += f;
1291
+ continue;
1292
+ }
1293
+ default: {
1294
+ let e4 = 'Token with "' + u.type + '" type was not found.';
1295
+ if (this.options.silent) return console.error(e4), "";
1296
+ throw Error(e4);
1297
+ }
1298
+ }
1299
+ }
1300
+ return s;
1301
+ }
1302
+ parseInline(e3, o = this.renderer) {
1303
+ var _a2, _b;
1304
+ let s = "";
1305
+ for (let c = 0; c < e3.length; c++) {
1306
+ let l = e3[c];
1307
+ if ((_b = (_a2 = this.options.extensions) == null ? void 0 : _a2.renderers) == null ? void 0 : _b[l.type]) {
1308
+ let e4 = this.options.extensions.renderers[l.type].call({ parser: this }, l);
1309
+ if (e4 !== false || ![
1310
+ "escape",
1311
+ "html",
1312
+ "link",
1313
+ "image",
1314
+ "strong",
1315
+ "em",
1316
+ "codespan",
1317
+ "br",
1318
+ "del",
1319
+ "text"
1320
+ ].includes(l.type)) {
1321
+ s += e4 || "";
1322
+ continue;
1323
+ }
1324
+ }
1325
+ let u = l;
1326
+ switch (u.type) {
1327
+ case "escape":
1328
+ s += o.text(u);
1329
+ break;
1330
+ case "html":
1331
+ s += o.html(u);
1332
+ break;
1333
+ case "link":
1334
+ s += o.link(u);
1335
+ break;
1336
+ case "image":
1337
+ s += o.image(u);
1338
+ break;
1339
+ case "strong":
1340
+ s += o.strong(u);
1341
+ break;
1342
+ case "em":
1343
+ s += o.em(u);
1344
+ break;
1345
+ case "codespan":
1346
+ s += o.codespan(u);
1347
+ break;
1348
+ case "br":
1349
+ s += o.br(u);
1350
+ break;
1351
+ case "del":
1352
+ s += o.del(u);
1353
+ break;
1354
+ case "text":
1355
+ s += o.text(u);
1356
+ break;
1357
+ default: {
1358
+ let e4 = 'Token with "' + u.type + '" type was not found.';
1359
+ if (this.options.silent) return console.error(e4), "";
1360
+ throw Error(e4);
1361
+ }
1362
+ }
1363
+ }
1364
+ return s;
1365
+ }
1366
+ }, $ = (_a = class {
1367
+ constructor(e3) {
1368
+ __publicField(this, "options");
1369
+ __publicField(this, "block");
1370
+ this.options = e3 || O;
1371
+ }
1372
+ preprocess(e3) {
1373
+ return e3;
1374
+ }
1375
+ postprocess(e3) {
1376
+ return e3;
1377
+ }
1378
+ processAllTokens(e3) {
1379
+ return e3;
1380
+ }
1381
+ provideLexer() {
1382
+ return this.block ? b.lex : b.lexInline;
1383
+ }
1384
+ provideParser() {
1385
+ return this.block ? R.parse : R.parseInline;
1386
+ }
1387
+ }, __publicField(_a, "passThroughHooks", /* @__PURE__ */ new Set([
1388
+ "preprocess",
1389
+ "postprocess",
1390
+ "processAllTokens"
1391
+ ])), _a), _ = new class {
1392
+ constructor(...e3) {
1393
+ __publicField(this, "defaults", L());
1394
+ __publicField(this, "options", this.setOptions);
1395
+ __publicField(this, "parse", this.parseMarkdown(true));
1396
+ __publicField(this, "parseInline", this.parseMarkdown(false));
1397
+ __publicField(this, "Parser", R);
1398
+ __publicField(this, "Renderer", P);
1399
+ __publicField(this, "TextRenderer", S);
1400
+ __publicField(this, "Lexer", b);
1401
+ __publicField(this, "Tokenizer", y);
1402
+ __publicField(this, "Hooks", $);
1403
+ this.use(...e3);
1404
+ }
1405
+ walkTokens(e3, o) {
1406
+ var _a2, _b;
1407
+ let s = [];
1408
+ for (let c of e3) switch (s = s.concat(o.call(this, c)), c.type) {
1409
+ case "table": {
1410
+ let e4 = c;
1411
+ for (let c2 of e4.header) s = s.concat(this.walkTokens(c2.tokens, o));
1412
+ for (let c2 of e4.rows) for (let e5 of c2) s = s.concat(this.walkTokens(e5.tokens, o));
1413
+ break;
1414
+ }
1415
+ case "list": {
1416
+ let e4 = c;
1417
+ s = s.concat(this.walkTokens(e4.items, o));
1418
+ break;
1419
+ }
1420
+ default: {
1421
+ let e4 = c;
1422
+ ((_b = (_a2 = this.defaults.extensions) == null ? void 0 : _a2.childTokens) == null ? void 0 : _b[e4.type]) ? this.defaults.extensions.childTokens[e4.type].forEach((c2) => {
1423
+ let l = e4[c2].flat(Infinity);
1424
+ s = s.concat(this.walkTokens(l, o));
1425
+ }) : e4.tokens && (s = s.concat(this.walkTokens(e4.tokens, o)));
1426
+ }
1427
+ }
1428
+ return s;
1429
+ }
1430
+ use(...e3) {
1431
+ let o = this.defaults.extensions || {
1432
+ renderers: {},
1433
+ childTokens: {}
1434
+ };
1435
+ return e3.forEach((e4) => {
1436
+ let s = { ...e4 };
1437
+ if (s.async = this.defaults.async || s.async || false, e4.extensions && (e4.extensions.forEach((e5) => {
1438
+ if (!e5.name) throw Error("extension name required");
1439
+ if ("renderer" in e5) {
1440
+ let s2 = o.renderers[e5.name];
1441
+ s2 ? o.renderers[e5.name] = function(...o2) {
1442
+ let c = e5.renderer.apply(this, o2);
1443
+ return c === false && (c = s2.apply(this, o2)), c;
1444
+ } : o.renderers[e5.name] = e5.renderer;
1445
+ }
1446
+ if ("tokenizer" in e5) {
1447
+ if (!e5.level || e5.level !== "block" && e5.level !== "inline") throw Error("extension level must be 'block' or 'inline'");
1448
+ let s2 = o[e5.level];
1449
+ s2 ? s2.unshift(e5.tokenizer) : o[e5.level] = [e5.tokenizer], e5.start && (e5.level === "block" ? o.startBlock ? o.startBlock.push(e5.start) : o.startBlock = [e5.start] : e5.level === "inline" && (o.startInline ? o.startInline.push(e5.start) : o.startInline = [e5.start]));
1450
+ }
1451
+ "childTokens" in e5 && e5.childTokens && (o.childTokens[e5.name] = e5.childTokens);
1452
+ }), s.extensions = o), e4.renderer) {
1453
+ let o2 = this.defaults.renderer || new P(this.defaults);
1454
+ for (let s2 in e4.renderer) {
1455
+ if (!(s2 in o2)) throw Error(`renderer '${s2}' does not exist`);
1456
+ if (["options", "parser"].includes(s2)) continue;
1457
+ let c = s2, l = e4.renderer[c], u = o2[c];
1458
+ o2[c] = (...e5) => {
1459
+ let s3 = l.apply(o2, e5);
1460
+ return s3 === false && (s3 = u.apply(o2, e5)), s3 || "";
1461
+ };
1462
+ }
1463
+ s.renderer = o2;
1464
+ }
1465
+ if (e4.tokenizer) {
1466
+ let o2 = this.defaults.tokenizer || new y(this.defaults);
1467
+ for (let s2 in e4.tokenizer) {
1468
+ if (!(s2 in o2)) throw Error(`tokenizer '${s2}' does not exist`);
1469
+ if ([
1470
+ "options",
1471
+ "rules",
1472
+ "lexer"
1473
+ ].includes(s2)) continue;
1474
+ let c = s2, l = e4.tokenizer[c], u = o2[c];
1475
+ o2[c] = (...e5) => {
1476
+ let s3 = l.apply(o2, e5);
1477
+ return s3 === false && (s3 = u.apply(o2, e5)), s3;
1478
+ };
1479
+ }
1480
+ s.tokenizer = o2;
1481
+ }
1482
+ if (e4.hooks) {
1483
+ let o2 = this.defaults.hooks || new $();
1484
+ for (let s2 in e4.hooks) {
1485
+ if (!(s2 in o2)) throw Error(`hook '${s2}' does not exist`);
1486
+ if (["options", "block"].includes(s2)) continue;
1487
+ let c = s2, l = e4.hooks[c], u = o2[c];
1488
+ $.passThroughHooks.has(s2) ? o2[c] = (e5) => {
1489
+ if (this.defaults.async) return Promise.resolve(l.call(o2, e5)).then((e6) => u.call(o2, e6));
1490
+ let s3 = l.call(o2, e5);
1491
+ return u.call(o2, s3);
1492
+ } : o2[c] = (...e5) => {
1493
+ let s3 = l.apply(o2, e5);
1494
+ return s3 === false && (s3 = u.apply(o2, e5)), s3;
1495
+ };
1496
+ }
1497
+ s.hooks = o2;
1498
+ }
1499
+ if (e4.walkTokens) {
1500
+ let o2 = this.defaults.walkTokens, c = e4.walkTokens;
1501
+ s.walkTokens = function(e5) {
1502
+ let s2 = [];
1503
+ return s2.push(c.call(this, e5)), o2 && (s2 = s2.concat(o2.call(this, e5))), s2;
1504
+ };
1505
+ }
1506
+ this.defaults = {
1507
+ ...this.defaults,
1508
+ ...s
1509
+ };
1510
+ }), this;
1511
+ }
1512
+ setOptions(e3) {
1513
+ return this.defaults = {
1514
+ ...this.defaults,
1515
+ ...e3
1516
+ }, this;
1517
+ }
1518
+ lexer(e3, o) {
1519
+ return b.lex(e3, o ?? this.defaults);
1520
+ }
1521
+ parser(e3, o) {
1522
+ return R.parse(e3, o ?? this.defaults);
1523
+ }
1524
+ parseMarkdown(e3) {
1525
+ return (o, s) => {
1526
+ let c = { ...s }, l = {
1527
+ ...this.defaults,
1528
+ ...c
1529
+ }, u = this.onError(!!l.silent, !!l.async);
1530
+ if (this.defaults.async === true && c.async === false) return u(/* @__PURE__ */ Error("marked(): The async option was set to true by an extension. Remove async: false from the parse options object to return a Promise."));
1531
+ if (typeof o > "u" || o === null) return u(/* @__PURE__ */ Error("marked(): input parameter is undefined or null"));
1532
+ if (typeof o != "string") return u(/* @__PURE__ */ Error("marked(): input parameter is of type " + Object.prototype.toString.call(o) + ", string expected"));
1533
+ l.hooks && (l.hooks.options = l, l.hooks.block = e3);
1534
+ let f = l.hooks ? l.hooks.provideLexer() : e3 ? b.lex : b.lexInline, p = l.hooks ? l.hooks.provideParser() : e3 ? R.parse : R.parseInline;
1535
+ if (l.async) return Promise.resolve(l.hooks ? l.hooks.preprocess(o) : o).then((e4) => f(e4, l)).then((e4) => l.hooks ? l.hooks.processAllTokens(e4) : e4).then((e4) => l.walkTokens ? Promise.all(this.walkTokens(e4, l.walkTokens)).then(() => e4) : e4).then((e4) => p(e4, l)).then((e4) => l.hooks ? l.hooks.postprocess(e4) : e4).catch(u);
1536
+ try {
1537
+ l.hooks && (o = l.hooks.preprocess(o));
1538
+ let e4 = f(o, l);
1539
+ l.hooks && (e4 = l.hooks.processAllTokens(e4)), l.walkTokens && this.walkTokens(e4, l.walkTokens);
1540
+ let s2 = p(e4, l);
1541
+ return l.hooks && (s2 = l.hooks.postprocess(s2)), s2;
1542
+ } catch (e4) {
1543
+ return u(e4);
1544
+ }
1545
+ };
1546
+ }
1547
+ onError(e3, o) {
1548
+ return (s) => {
1549
+ if (s.message += "\nPlease report this to https://github.com/markedjs/marked.", e3) {
1550
+ let e4 = "<p>An error occurred:</p><pre>" + w(s.message + "", true) + "</pre>";
1551
+ return o ? Promise.resolve(e4) : e4;
1552
+ }
1553
+ if (o) return Promise.reject(s);
1554
+ throw s;
1555
+ };
1556
+ }
1557
+ }();
1558
+ function d(e3, o) {
1559
+ return _.parse(e3, o);
1560
+ }
1561
+ d.options = d.setOptions = function(e3) {
1562
+ return _.setOptions(e3), d.defaults = _.defaults, H(d.defaults), d;
1563
+ }, d.getDefaults = L, d.defaults = O, d.use = function(...e3) {
1564
+ return _.use(...e3), d.defaults = _.defaults, H(d.defaults), d;
1565
+ }, d.walkTokens = function(e3, o) {
1566
+ return _.walkTokens(e3, o);
1567
+ }, d.parseInline = _.parseInline, d.Parser = R, d.parser = R.parse, d.Renderer = P, d.TextRenderer = S, d.Lexer = b, d.lexer = b.lex, d.Tokenizer = y, d.Hooks = $, d.parse = d, d.options, d.setOptions, d.use, d.walkTokens, d.parseInline, R.parse, b.lex;
1568
+ function dedent(e3) {
1569
+ var o = [...arguments].slice(1), s = Array.from(typeof e3 == "string" ? [e3] : e3);
1570
+ s[s.length - 1] = s[s.length - 1].replace(/\r?\n([\t ]*)$/, "");
1571
+ var c = s.reduce(function(e4, o2) {
1572
+ var s2 = o2.match(/\n([\t ]+|(?!\s).)/g);
1573
+ return s2 ? e4.concat(s2.map(function(e5) {
1574
+ var _a2;
1575
+ return ((_a2 = e5.match(/[\t ]/g)) == null ? void 0 : _a2.length) ?? 0;
1576
+ })) : e4;
1577
+ }, []);
1578
+ if (c.length) {
1579
+ var l = RegExp("\n[ ]{" + Math.min.apply(Math, c) + "}", "g");
1580
+ s = s.map(function(e4) {
1581
+ return e4.replace(l, "\n");
1582
+ });
1583
+ }
1584
+ s[0] = s[0].replace(/^\r?\n/, "");
1585
+ var u = s[0];
1586
+ return o.forEach(function(e4, o2) {
1587
+ var c2 = u.match(/(?:^|\n)( *)$/), l2 = c2 ? c2[1] : "", f = e4;
1588
+ typeof e4 == "string" && e4.includes("\n") && (f = String(e4).split("\n").map(function(e5, o3) {
1589
+ return o3 === 0 ? e5 : "" + l2 + e5;
1590
+ }).join("\n")), u += f + s[o2 + 1];
1591
+ }), u;
1592
+ }
1593
+ var unknownIcon = {
1594
+ body: '<g><rect width="80" height="80" style="fill: #087ebf; stroke-width: 0px;"/><text transform="translate(21.16 64.67)" style="fill: #fff; font-family: ArialMT, Arial; font-size: 67.75px;"><tspan x="0" y="0">?</tspan></text></g>',
1595
+ height: 80,
1596
+ width: 80
1597
+ }, iconsStore = /* @__PURE__ */ new Map(), loaderStore = /* @__PURE__ */ new Map(), registerIconPacks = /* @__PURE__ */ __name((e3) => {
1598
+ for (let s of e3) {
1599
+ if (!s.name) throw Error('Invalid icon loader. Must have a "name" property with non-empty string value.');
1600
+ if (log.debug("Registering icon pack:", s.name), "loader" in s) loaderStore.set(s.name, s.loader);
1601
+ else if ("icons" in s) iconsStore.set(s.name, s.icons);
1602
+ else throw log.error("Invalid icon loader:", s), Error('Invalid icon loader. Must have either "icons" or "loader" property.');
1603
+ }
1604
+ }, "registerIconPacks"), getRegisteredIconData = /* @__PURE__ */ __name(async (e3, s) => {
1605
+ let c = stringToIcon(e3, true, s !== void 0);
1606
+ if (!c) throw Error(`Invalid icon name: ${e3}`);
1607
+ let l = c.prefix || s;
1608
+ if (!l) throw Error(`Icon name must contain a prefix: ${e3}`);
1609
+ let u = iconsStore.get(l);
1610
+ if (!u) {
1611
+ let e4 = loaderStore.get(l);
1612
+ if (!e4) throw Error(`Icon set not found: ${c.prefix}`);
1613
+ try {
1614
+ u = {
1615
+ ...await e4(),
1616
+ prefix: l
1617
+ }, iconsStore.set(l, u);
1618
+ } catch (e5) {
1619
+ throw log.error(e5), Error(`Failed to load icon set: ${c.prefix}`);
1620
+ }
1621
+ }
1622
+ let f = getIconData(u, c.name);
1623
+ if (!f) throw Error(`Icon not found: ${e3}`);
1624
+ return f;
1625
+ }, "getRegisteredIconData"), isIconAvailable = /* @__PURE__ */ __name(async (e3) => {
1626
+ try {
1627
+ return await getRegisteredIconData(e3), true;
1628
+ } catch {
1629
+ return false;
1630
+ }
1631
+ }, "isIconAvailable"), getIconSVG = /* @__PURE__ */ __name(async (e3, s, c) => {
1632
+ let u;
1633
+ try {
1634
+ u = await getRegisteredIconData(e3, s == null ? void 0 : s.fallbackPrefix);
1635
+ } catch (e4) {
1636
+ log.error(e4), u = unknownIcon;
1637
+ }
1638
+ let f = iconToSVG(u, s);
1639
+ return sanitizeText(iconToHTML(replaceIDs(f.body), {
1640
+ ...f.attributes,
1641
+ ...c
1642
+ }), getConfig());
1643
+ }, "getIconSVG");
1644
+ function preprocessMarkdown(e3, { markdownAutoWrap: o }) {
1645
+ let s = dedent(e3.replace(/<br\/>/g, "\n").replace(/\n{2,}/g, "\n"));
1646
+ return o === false ? s.replace(/ /g, "&nbsp;") : s;
1647
+ }
1648
+ __name(preprocessMarkdown, "preprocessMarkdown");
1649
+ function markdownToLines(e3, o = {}) {
1650
+ let c = preprocessMarkdown(e3, o), l = d.lexer(c), u = [[]], f = 0;
1651
+ function p(e4, o2 = "normal") {
1652
+ e4.type === "text" ? e4.text.split("\n").forEach((e5, s) => {
1653
+ s !== 0 && (f++, u.push([])), e5.split(" ").forEach((e6) => {
1654
+ e6 = e6.replace(/&#39;/g, "'"), e6 && u[f].push({
1655
+ content: e6,
1656
+ type: o2
1657
+ });
1658
+ });
1659
+ }) : e4.type === "strong" || e4.type === "em" ? e4.tokens.forEach((o3) => {
1660
+ p(o3, e4.type);
1661
+ }) : e4.type === "html" && u[f].push({
1662
+ content: e4.text,
1663
+ type: "normal"
1664
+ });
1665
+ }
1666
+ return __name(p, "processNode"), l.forEach((e4) => {
1667
+ var _a2;
1668
+ e4.type === "paragraph" ? (_a2 = e4.tokens) == null ? void 0 : _a2.forEach((e5) => {
1669
+ p(e5);
1670
+ }) : e4.type === "html" ? u[f].push({
1671
+ content: e4.text,
1672
+ type: "normal"
1673
+ }) : u[f].push({
1674
+ content: e4.raw,
1675
+ type: "normal"
1676
+ });
1677
+ }), u;
1678
+ }
1679
+ __name(markdownToLines, "markdownToLines");
1680
+ function markdownToHTML(e3, { markdownAutoWrap: c } = {}) {
1681
+ let l = d.lexer(e3);
1682
+ function u(e4) {
1683
+ var _a2, _b, _c;
1684
+ return e4.type === "text" ? c === false ? e4.text.replace(/\n */g, "<br/>").replace(/ /g, "&nbsp;") : e4.text.replace(/\n */g, "<br/>") : e4.type === "strong" ? `<strong>${(_a2 = e4.tokens) == null ? void 0 : _a2.map(u).join("")}</strong>` : e4.type === "em" ? `<em>${(_b = e4.tokens) == null ? void 0 : _b.map(u).join("")}</em>` : e4.type === "paragraph" ? `<p>${(_c = e4.tokens) == null ? void 0 : _c.map(u).join("")}</p>` : e4.type === "space" ? "" : e4.type === "html" ? `${e4.text}` : e4.type === "escape" ? e4.text : (log.warn(`Unsupported markdown: ${e4.type}`), e4.raw);
1685
+ }
1686
+ return __name(u, "output"), l.map(u).join("");
1687
+ }
1688
+ __name(markdownToHTML, "markdownToHTML");
1689
+ function splitTextToChars(e3) {
1690
+ return Intl.Segmenter ? [...new Intl.Segmenter().segment(e3)].map((e4) => e4.segment) : [...e3];
1691
+ }
1692
+ __name(splitTextToChars, "splitTextToChars");
1693
+ function splitWordToFitWidth(e3, o) {
1694
+ return splitWordToFitWidthRecursion(e3, [], splitTextToChars(o.content), o.type);
1695
+ }
1696
+ __name(splitWordToFitWidth, "splitWordToFitWidth");
1697
+ function splitWordToFitWidthRecursion(e3, o, s, c) {
1698
+ if (s.length === 0) return [{
1699
+ content: o.join(""),
1700
+ type: c
1701
+ }, {
1702
+ content: "",
1703
+ type: c
1704
+ }];
1705
+ let [l, ...u] = s, f = [...o, l];
1706
+ return e3([{
1707
+ content: f.join(""),
1708
+ type: c
1709
+ }]) ? splitWordToFitWidthRecursion(e3, f, u, c) : (o.length === 0 && l && (o.push(l), s.shift()), [{
1710
+ content: o.join(""),
1711
+ type: c
1712
+ }, {
1713
+ content: s.join(""),
1714
+ type: c
1715
+ }]);
1716
+ }
1717
+ __name(splitWordToFitWidthRecursion, "splitWordToFitWidthRecursion");
1718
+ function splitLineToFitWidth(e3, o) {
1719
+ if (e3.some(({ content: e4 }) => e4.includes("\n"))) throw Error("splitLineToFitWidth does not support newlines in the line");
1720
+ return splitLineToFitWidthRecursion(e3, o);
1721
+ }
1722
+ __name(splitLineToFitWidth, "splitLineToFitWidth");
1723
+ function splitLineToFitWidthRecursion(e3, o, s = [], c = []) {
1724
+ if (e3.length === 0) return c.length > 0 && s.push(c), s.length > 0 ? s : [];
1725
+ let l = "";
1726
+ e3[0].content === " " && (l = " ", e3.shift());
1727
+ let u = e3.shift() ?? {
1728
+ content: " ",
1729
+ type: "normal"
1730
+ }, f = [...c];
1731
+ if (l !== "" && f.push({
1732
+ content: l,
1733
+ type: "normal"
1734
+ }), f.push(u), o(f)) return splitLineToFitWidthRecursion(e3, o, s, f);
1735
+ if (c.length > 0) s.push(c), e3.unshift(u);
1736
+ else if (u.content) {
1737
+ let [c2, l2] = splitWordToFitWidth(o, u);
1738
+ s.push([c2]), l2.content && e3.unshift(l2);
1739
+ }
1740
+ return splitLineToFitWidthRecursion(e3, o, s);
1741
+ }
1742
+ __name(splitLineToFitWidthRecursion, "splitLineToFitWidthRecursion");
1743
+ function applyStyle(e3, o) {
1744
+ o && e3.attr("style", o);
1745
+ }
1746
+ __name(applyStyle, "applyStyle");
1747
+ async function addHtmlSpan(e3, o, s, c, x = false, T = getConfig()) {
1748
+ let k = e3.append("foreignObject");
1749
+ k.attr("width", `${10 * s}px`), k.attr("height", `${10 * s}px`);
1750
+ let A = k.append("xhtml:div"), B = hasKatex(o.label) ? await renderKatexSanitized(o.label.replace(common_default.lineBreakRegex, "\n"), T) : sanitizeText(o.label, T), G = o.isNode ? "nodeLabel" : "edgeLabel", Y = A.append("span");
1751
+ Y.html(B), applyStyle(Y, o.labelStyle), Y.attr("class", `${G} ${c}`), applyStyle(A, o.labelStyle), A.style("display", "table-cell"), A.style("white-space", "nowrap"), A.style("line-height", "1.5"), A.style("max-width", s + "px"), A.style("text-align", "center"), A.attr("xmlns", "http://www.w3.org/1999/xhtml"), x && A.attr("class", "labelBkg");
1752
+ let Z = A.node().getBoundingClientRect();
1753
+ return Z.width === s && (A.style("display", "table"), A.style("white-space", "break-spaces"), A.style("width", s + "px"), Z = A.node().getBoundingClientRect()), k.node();
1754
+ }
1755
+ __name(addHtmlSpan, "addHtmlSpan");
1756
+ function createTspan(e3, o, s) {
1757
+ return e3.append("tspan").attr("class", "text-outer-tspan").attr("x", 0).attr("y", o * s - 0.1 + "em").attr("dy", s + "em");
1758
+ }
1759
+ __name(createTspan, "createTspan");
1760
+ function computeWidthOfText(e3, o, s) {
1761
+ let c = e3.append("text"), l = createTspan(c, 1, o);
1762
+ updateTextContentAndStyles(l, s);
1763
+ let u = l.node().getComputedTextLength();
1764
+ return c.remove(), u;
1765
+ }
1766
+ __name(computeWidthOfText, "computeWidthOfText");
1767
+ function computeDimensionOfText(e3, o, s) {
1768
+ var _a2;
1769
+ let c = e3.append("text"), l = createTspan(c, 1, o);
1770
+ updateTextContentAndStyles(l, [{
1771
+ content: s,
1772
+ type: "normal"
1773
+ }]);
1774
+ let u = (_a2 = l.node()) == null ? void 0 : _a2.getBoundingClientRect();
1775
+ return u && c.remove(), u;
1776
+ }
1777
+ __name(computeDimensionOfText, "computeDimensionOfText");
1778
+ function createFormattedText(e3, o, c, l = false) {
1779
+ let u = 1.1, f = o.append("g"), p = f.insert("rect").attr("class", "background").attr("style", "stroke: none"), g = f.append("text").attr("y", "-10.1"), x = 0;
1780
+ for (let o2 of c) {
1781
+ let c2 = /* @__PURE__ */ __name((o3) => computeWidthOfText(f, u, o3) <= e3, "checkWidth"), l2 = c2(o2) ? [o2] : splitLineToFitWidth(o2, c2);
1782
+ for (let e4 of l2) updateTextContentAndStyles(createTspan(g, x, u), e4), x++;
1783
+ }
1784
+ if (l) {
1785
+ let e4 = g.node().getBBox();
1786
+ return p.attr("x", e4.x - 2).attr("y", e4.y - 2).attr("width", e4.width + 4).attr("height", e4.height + 4), f.node();
1787
+ } else return g.node();
1788
+ }
1789
+ __name(createFormattedText, "createFormattedText");
1790
+ function updateTextContentAndStyles(e3, o) {
1791
+ e3.text(""), o.forEach((o2, s) => {
1792
+ let c = e3.append("tspan").attr("font-style", o2.type === "em" ? "italic" : "normal").attr("class", "text-inner-tspan").attr("font-weight", o2.type === "strong" ? "bold" : "normal");
1793
+ s === 0 ? c.text(o2.content) : c.text(" " + o2.content);
1794
+ });
1795
+ }
1796
+ __name(updateTextContentAndStyles, "updateTextContentAndStyles");
1797
+ async function replaceIconSubstring(e3, o = {}) {
1798
+ let s = [];
1799
+ e3.replace(/(fa[bklrs]?):fa-([\w-]+)/g, (e4, c2, u) => (s.push((async () => {
1800
+ let s2 = `${c2}:${u}`;
1801
+ return await isIconAvailable(s2) ? await getIconSVG(s2, void 0, { class: "label-icon" }) : `<i class='${sanitizeText(e4, o).replace(":", " ")}'></i>`;
1802
+ })()), e4));
1803
+ let c = await Promise.all(s);
1804
+ return e3.replace(/(fa[bklrs]?):fa-([\w-]+)/g, () => c.shift() ?? "");
1805
+ }
1806
+ __name(replaceIconSubstring, "replaceIconSubstring");
1807
+ var createText = /* @__PURE__ */ __name(async (s, l = "", { style: u = "", isTitle: p = false, classes: g = "", useHtmlLabels: x = true, isNode: T = true, width: k = 200, addSvgBackground: A = false } = {}, B) => {
1808
+ if (log.debug("XYZ createText", l, u, p, g, x, T, "addSvgBackground: ", A), x) {
1809
+ let o = await replaceIconSubstring(decodeEntities(markdownToHTML(l, B)), B), c = l.replace(/\\\\/g, "\\");
1810
+ return await addHtmlSpan(s, {
1811
+ isNode: T,
1812
+ label: hasKatex(l) ? c : o,
1813
+ labelStyle: u.replace("fill:", "color:")
1814
+ }, k, g, A, B);
1815
+ } else {
1816
+ let e3 = createFormattedText(k, s, markdownToLines(l.replace(/<br\s*\/?>/g, "<br/>").replace("<br>", "<br/>"), B), l ? A : false);
1817
+ if (T) {
1818
+ /stroke:/.exec(u) && (u = u.replace("stroke:", "lineColor:"));
1819
+ let o = u.replace(/stroke:[^;]+;?/g, "").replace(/stroke-width:[^;]+;?/g, "").replace(/fill:[^;]+;?/g, "").replace(/color:/g, "fill:");
1820
+ select_default(e3).attr("style", o);
1821
+ } else {
1822
+ let o = u.replace(/stroke:[^;]+;?/g, "").replace(/stroke-width:[^;]+;?/g, "").replace(/fill:[^;]+;?/g, "").replace(/background:/g, "fill:");
1823
+ select_default(e3).select("rect").attr("style", o.replace(/background:/g, "fill:"));
1824
+ let s2 = u.replace(/stroke:[^;]+;?/g, "").replace(/stroke-width:[^;]+;?/g, "").replace(/fill:[^;]+;?/g, "").replace(/color:/g, "fill:");
1825
+ select_default(e3).select("text").attr("style", s2);
1826
+ }
1827
+ return e3;
1828
+ }
1829
+ }, "createText");
1830
+ export {
1831
+ replaceIconSubstring as a,
1832
+ registerIconPacks as i,
1833
+ createText as n,
1834
+ unknownIcon as o,
1835
+ getIconSVG as r,
1836
+ dedent as s,
1837
+ computeDimensionOfText as t
1838
+ };