vue-stream-markdown 0.1.4 → 0.1.6

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 (196) hide show
  1. package/README.md +3 -1
  2. package/dist/arrow-left-DiHYz8df.js +25 -0
  3. package/dist/{blockquote-DdEg2gww.js → blockquote-CxA1dQZe.js} +4 -11
  4. package/dist/{button-jFTF378X.js → button-B2ebQt7R.js} +2 -3
  5. package/dist/button-C6zIegam.js +5 -0
  6. package/dist/{code-BxWvKFxG.js → code-CPG6B2Cw.js} +12 -20
  7. package/dist/code-block--1wFjtmu.js +9 -0
  8. package/dist/{code-block-uZcUI59D.js → code-block-I_Yd1Flg.js} +62 -67
  9. package/dist/{composables-Cx0nvyHl.js → composables-DWipZHuF.js} +1119 -840
  10. package/dist/corner-down-left-jxlwq3ox.js +24 -0
  11. package/dist/{delete-BdWzKJCy.js → delete-DQ21z5-F.js} +4 -11
  12. package/dist/dist-CYkm26BF.js +119 -0
  13. package/dist/dropdown-CtWjJiAf.js +5 -0
  14. package/dist/{emphasis-CTuGt1Ok.js → emphasis-BjLkIDQB.js} +4 -11
  15. package/dist/{en-US-Bfc50l3I.js → en-US-K7SXR3gy.js} +8 -1
  16. package/dist/{error-component-Bhl770lu.js → error-component-DSOVrE5J.js} +1 -1
  17. package/dist/error-component-DtcRn_0A.js +4 -0
  18. package/dist/flip-horizontal-CEf7aAdM.js +25 -0
  19. package/dist/footnote-definition-BmS8hchP.js +103 -0
  20. package/dist/footnote-reference-Z2tITeCE.js +86 -0
  21. package/dist/{heading-2vpQQtTH.js → heading-BwBFJB_E.js} +4 -11
  22. package/dist/{html-DL0PcUXX.js → html-DFU0myJP.js} +2 -10
  23. package/dist/image-BLlap3ce.js +242 -0
  24. package/dist/{image-BDtPwitR.js → image-IKvFWz2r.js} +43 -78
  25. package/dist/image-aT9xxnwh.js +8 -0
  26. package/dist/index.css +69 -64
  27. package/dist/index.d.ts +192 -82
  28. package/dist/index.js +291 -65
  29. package/dist/{inline-code-CBoqhfz7.js → inline-code-Bqu84Yyu.js} +2 -10
  30. package/dist/{inline-math-CAqboT7h.js → inline-math-C2Ryxm-K.js} +4 -12
  31. package/dist/{link-C8BSlPhZ.js → link-BXl7E_6o.js} +6 -14
  32. package/dist/{list-BCiFKGaz.js → list-DLcwTZns.js} +4 -11
  33. package/dist/{list-item-p-OLUR_9.js → list-item-H0eYeIdB.js} +4 -11
  34. package/dist/{math-CT1TB2pK.js → math-C-0d5PaJ.js} +4 -12
  35. package/dist/{mermaid-CYrA8rCl.js → mermaid-0x6C2MY5.js} +12 -18
  36. package/dist/modal-BDgfKnFl.js +4 -0
  37. package/dist/modal-CEqU9Ubu.js +94 -0
  38. package/dist/{node-list-CGr_EVtn.js → node-list--v2wbxOo.js} +19 -26
  39. package/dist/node-list-CHvX62Zh.js +4 -0
  40. package/dist/{paragraph-DYjqr_Sa.js → paragraph-DRPfp6DV.js} +4 -11
  41. package/dist/previewers-DsN-cTwd.js +10 -0
  42. package/dist/rotate-ccw-square-5sO65BY9.js +24 -0
  43. package/dist/segmented-DIVDGfR5.js +6 -0
  44. package/dist/{segmented-DBW9ignu.js → segmented-Drf8EBQD.js} +1 -1
  45. package/dist/{shiki-bQYWLdW3.js → shiki-CkwRD3TS.js} +6 -14
  46. package/dist/spin-DWkKEP0G.js +3 -0
  47. package/dist/{strong-CvOjLZiq.js → strong-D6V4fCRG.js} +4 -11
  48. package/dist/table-B2mghd3l.js +3 -0
  49. package/dist/{table-l_3z210v.js → table-DLUgGL5Q.js} +13 -18
  50. package/dist/{text-DuONUqRA.js → text-DoY1TIw3.js} +2 -10
  51. package/dist/{thematic-break-CcNPEI9Y.js → thematic-break-DXDZ5dcO.js} +2 -10
  52. package/dist/tooltip-Bdt9-aQx.js +68 -0
  53. package/dist/tooltip-DQ1-yPia.js +4 -0
  54. package/dist/{vanilla-CFWVwBvD.js → vanilla-BSgZTIo9.js} +1 -1
  55. package/dist/vanilla-DUbuBied.js +4 -0
  56. package/dist/{yaml-DJHrmzSe.js → yaml-3cd5rdJj.js} +3 -11
  57. package/dist/{zh-CN-CL1XGe0H.js → zh-CN-CykTNqF_.js} +9 -2
  58. package/dist/zoom-container-D2DxS8V5.js +6 -0
  59. package/dist/{zoom-container-gjQ0EMyk.js → zoom-container-f44XxzOI.js} +52 -23
  60. package/package.json +9 -10
  61. package/dist/button-D6ccVxGm.js +0 -5
  62. package/dist/code-block-B72JfFy-.js +0 -9
  63. package/dist/dropdown-oiCw8QVq.js +0 -5
  64. package/dist/error-component-8y13-fYG.js +0 -4
  65. package/dist/modal-CuQR21UD.js +0 -71
  66. package/dist/modal-DcpxxDDX.js +0 -3
  67. package/dist/node-list-lgY1wbfQ.js +0 -3
  68. package/dist/previewers-ByaS2Ksa.js +0 -10
  69. package/dist/segmented-B4IEw3wg.js +0 -6
  70. package/dist/spin-Bz4zGBEo.js +0 -3
  71. package/dist/table-CZLbUHiJ.js +0 -3
  72. package/dist/tooltip-3UDC9mw-.js +0 -71
  73. package/dist/tooltip-CAoc_U1X.js +0 -4
  74. package/dist/vanilla-De7W3PpS.js +0 -4
  75. package/dist/zoom-container-DBgGdbJS.js +0 -6
  76. /package/dist/{angular-Chs-UKBr.js → angular-CEQtRU3N.js} +0 -0
  77. /package/dist/{angular-component-Cc_FANXU.js → angular-component-QEWXDi5W.js} +0 -0
  78. /package/dist/{apache-COYnc6xR.js → apache-D1WYHuA2.js} +0 -0
  79. /package/dist/{asciidoc-BabXBDAL.js → asciidoc-BbV_Tvaj.js} +0 -0
  80. /package/dist/{assembly-CDqKhexW.js → assembly-DOdgqSeT.js} +0 -0
  81. /package/dist/{astro-C9kftzFG.js → astro-I7-Zr25r.js} +0 -0
  82. /package/dist/{bash-Ce4pNIkV.js → bash-BC7HOdMh.js} +0 -0
  83. /package/dist/{batch-CHQBRjFL.js → batch-XAv7F3kV.js} +0 -0
  84. /package/dist/{bicep-8jxWtuBF.js → bicep-B9IAZzHb.js} +0 -0
  85. /package/dist/{c-FBUef746.js → c-B3pMu4KG.js} +0 -0
  86. /package/dist/{check-C4xOk8um.js → check-BjAiKMbo.js} +0 -0
  87. /package/dist/{chevron-down-cnOJ4h1g.js → chevron-down-B4lkjpIC.js} +0 -0
  88. /package/dist/{circle-alert-CLX-h5rZ.js → circle-alert-DlAafH7h.js} +0 -0
  89. /package/dist/{clojure-BulUroSy.js → clojure-DwxK-YDX.js} +0 -0
  90. /package/dist/{cmake-CW3vz1Mo.js → cmake-DtnmI6Z6.js} +0 -0
  91. /package/dist/{cobol-CIn3oFju.js → cobol--wWeXL_f.js} +0 -0
  92. /package/dist/{code-D8LSp8rK.js → code-lfRPXNJI.js} +0 -0
  93. /package/dist/{codeowners-CJggXF_b.js → codeowners-Dtwyh-5g.js} +0 -0
  94. /package/dist/{coffeescript-CBrVvzGY.js → coffeescript-BlF7y2QG.js} +0 -0
  95. /package/dist/{copy-Cabve0xf.js → copy-BTFPPhff.js} +0 -0
  96. /package/dist/{cpp-BTKeuyd-.js → cpp-D_TbJeEH.js} +0 -0
  97. /package/dist/{crystal-DyIYvZbm.js → crystal-lJ2ZzJQu.js} +0 -0
  98. /package/dist/{csharp-NqZ1vyF9.js → csharp-D-5hlCJT.js} +0 -0
  99. /package/dist/{css-BpR5Lajb.js → css-Drykp8uH.js} +0 -0
  100. /package/dist/{csv-eCMFnKKK.js → csv-oLjD_o9N.js} +0 -0
  101. /package/dist/{cue-TY97dGOQ.js → cue-BBe_9OA4.js} +0 -0
  102. /package/dist/{d-NftUsdTd.js → d-CPNK2-3G.js} +0 -0
  103. /package/dist/{dart-DJpwZZbk.js → dart-BNaQZJdJ.js} +0 -0
  104. /package/dist/{database-aZwE71Px.js → database-DRAhifbf.js} +0 -0
  105. /package/dist/{diff-CYRzypaU.js → diff-D_vIvULL.js} +0 -0
  106. /package/dist/{docker-CxHBuukH.js → docker-BgJkkqCD.js} +0 -0
  107. /package/dist/{download-Bnn7rtYw.js → download-Bk2mYZyf.js} +0 -0
  108. /package/dist/{elixir-BKSxVc1h.js → elixir-CTx5aScS.js} +0 -0
  109. /package/dist/{elm-DScuAf3X.js → elm-nHy9iRuu.js} +0 -0
  110. /package/dist/{env-CDAKsodl.js → env-CrWzDcwP.js} +0 -0
  111. /package/dist/{erlang-D2M1ZL3m.js → erlang-CxR4-Qdt.js} +0 -0
  112. /package/dist/{eye-CdeX8PhP.js → eye-DpAj1af-.js} +0 -0
  113. /package/dist/{fortran-CORyQ0wt.js → fortran-DhUZYzo3.js} +0 -0
  114. /package/dist/{fsharp-BJz_Jgpl.js → fsharp-DyIvnsyH.js} +0 -0
  115. /package/dist/{git-DgrlTr1E.js → git-D4qjCZtd.js} +0 -0
  116. /package/dist/{gleam-t_xad9Kw.js → gleam-D-ovCBt_.js} +0 -0
  117. /package/dist/{go-Cvlh1xtL.js → go-CEH2y3pJ.js} +0 -0
  118. /package/dist/{graphql-ApIm0mDD.js → graphql-DbV-8_AJ.js} +0 -0
  119. /package/dist/{groovy-CaLnK8PV.js → groovy-B-_VVp4c.js} +0 -0
  120. /package/dist/{haml-MwijEO_6.js → haml-Cnm_v56B.js} +0 -0
  121. /package/dist/{handlebars-CKdUPI9h.js → handlebars-8EEQS0El.js} +0 -0
  122. /package/dist/{haskell-NPOXEnck.js → haskell-cLvKQFrd.js} +0 -0
  123. /package/dist/{haxe-DyKBMsDE.js → haxe-DtCGwrr1.js} +0 -0
  124. /package/dist/{html-CMgES1dE.js → html-C2NHp3i4.js} +0 -0
  125. /package/dist/{http-B9FFNmUr.js → http-DYO1Ugj7.js} +0 -0
  126. /package/dist/{image-CMZAakWu.js → image-DDiNDOKJ.js} +0 -0
  127. /package/dist/{java-iU-L9wJz.js → java-it6UCC5M.js} +0 -0
  128. /package/dist/{javascript-DtnWdTFC.js → javascript-DVxfoa-a.js} +0 -0
  129. /package/dist/{jinja-CoWszo_D.js → jinja-CUKX2CXM.js} +0 -0
  130. /package/dist/{json-C80qKCnh.js → json-O68iFOiu.js} +0 -0
  131. /package/dist/{julia-DG2BCBLx.js → julia-Dq3BwHeZ.js} +0 -0
  132. /package/dist/{kdl-7twRfIlJ.js → kdl-CFVZba8u.js} +0 -0
  133. /package/dist/{kotlin-BjrOgP7R.js → kotlin-BKhxhG0q.js} +0 -0
  134. /package/dist/{latex-DIQfUvG8.js → latex-B3hQqfJO.js} +0 -0
  135. /package/dist/{less-BJ1yEAWt.js → less-Bw2JZJkw.js} +0 -0
  136. /package/dist/{link-DeV4CQOB.js → link-DCaSecEI.js} +0 -0
  137. /package/dist/{liquid-BqKFZ1wQ.js → liquid-BsGDMxjJ.js} +0 -0
  138. /package/dist/{lisp-oekhB2ti.js → lisp-CnrazyOe.js} +0 -0
  139. /package/dist/{log-D1XEqR9q.js → log-BuRjhdbZ.js} +0 -0
  140. /package/dist/{lua-C5Q97-1D.js → lua-CA97s0xX.js} +0 -0
  141. /package/dist/{luau-BT8KwqZ2.js → luau-hq6gk9_N.js} +0 -0
  142. /package/dist/{makefile-B4a0ciG4.js → makefile-mNhrnPWo.js} +0 -0
  143. /package/dist/{markdown-DvNyKsiJ.js → markdown-El6B7b99.js} +0 -0
  144. /package/dist/{marko-BzsIf6bg.js → marko-8nTOMumd.js} +0 -0
  145. /package/dist/{matlab-cMBkmDhQ.js → matlab-DuqengFv.js} +0 -0
  146. /package/dist/{maximize-4PIqBONS.js → maximize-B1-N6kOL.js} +0 -0
  147. /package/dist/{mermaid-8JIH2gkQ.js → mermaid-Byu8TsQE.js} +0 -0
  148. /package/dist/{minimize-BJ8htyDF.js → minimize-CVVLdf2H.js} +0 -0
  149. /package/dist/{nextflow-DNmqU1xg.js → nextflow-DRCOPmGT.js} +0 -0
  150. /package/dist/{nginx-DDfYF_rj.js → nginx-DTgW--wm.js} +0 -0
  151. /package/dist/{nim-D9xEmy4k.js → nim-r-ftp-xj.js} +0 -0
  152. /package/dist/{nix-BV1Deshw.js → nix-BdWPBS1Z.js} +0 -0
  153. /package/dist/{ocaml-BkFn4LL3.js → ocaml-vXi6ujuu.js} +0 -0
  154. /package/dist/{perl-BytUHDE7.js → perl-C_g5vs30.js} +0 -0
  155. /package/dist/{php-BImJJtNM.js → php-C_b0sjdl.js} +0 -0
  156. /package/dist/{postcss-CrZ9_0sT.js → postcss-Bsz3PPjI.js} +0 -0
  157. /package/dist/{powershell-DYSGu7TM.js → powershell-D0kxdwKl.js} +0 -0
  158. /package/dist/{prisma-BhRvcOFY.js → prisma-BocqbK7a.js} +0 -0
  159. /package/dist/{prolog-DuaCKek_.js → prolog-D-zd1rzT.js} +0 -0
  160. /package/dist/{properties-BbIJwuP-.js → properties-Dds-063G.js} +0 -0
  161. /package/dist/{proto-CE0aVW11.js → proto-CzD9trm_.js} +0 -0
  162. /package/dist/{pug-B1-IC-Tc.js → pug-B1V2RxQS.js} +0 -0
  163. /package/dist/{puppet-8nYquiMG.js → puppet-BcnVd0q5.js} +0 -0
  164. /package/dist/{python-DhRyfBrD.js → python-BcZnB7mH.js} +0 -0
  165. /package/dist/{r-Cjje17IA.js → r-CxSFFuvL.js} +0 -0
  166. /package/dist/{racket-Dx0gMnpg.js → racket-DJ_82PRG.js} +0 -0
  167. /package/dist/{razor-DPht_bdD.js → razor-D7IkXHVQ.js} +0 -0
  168. /package/dist/{ruby-B8RxtCzI.js → ruby-Cidk52Rl.js} +0 -0
  169. /package/dist/{rust-Cjtli6yf.js → rust-DJvcpkbm.js} +0 -0
  170. /package/dist/{sass-Dv3DMzjs.js → sass-DTFDeixE.js} +0 -0
  171. /package/dist/{scala-B7bZGKXq.js → scala-GlHhGi5O.js} +0 -0
  172. /package/dist/{scheme-B2PsEdVN.js → scheme-rNcj5mL9.js} +0 -0
  173. /package/dist/{shader-BZzu3zGr.js → shader-Df9eByRK.js} +0 -0
  174. /package/dist/{shiki-token-renderer-D164wC7Y.js → shiki-token-renderer-BMveKuYt.js} +0 -0
  175. /package/dist/{solidity-CLieFYpL.js → solidity-CfuYjRuT.js} +0 -0
  176. /package/dist/{spin-Ds5W7qC_.js → spin-D4Oi_m7j.js} +0 -0
  177. /package/dist/{stata-C0yUiO47.js → stata-BB5c_hbh.js} +0 -0
  178. /package/dist/{svelte-rtF4yNGL.js → svelte-2ISqxu6B.js} +0 -0
  179. /package/dist/{swift-CzvYoIM0.js → swift-wpybyudn.js} +0 -0
  180. /package/dist/{table-4ec9FVB_.js → table-iNA4la0w.js} +0 -0
  181. /package/dist/{terraform-CD_BZGb-.js → terraform-CLzhaCaX.js} +0 -0
  182. /package/dist/{text-D1-vbZ7l.js → text-C0mKr3tC.js} +0 -0
  183. /package/dist/{toml-C6jUF0Xd.js → toml-DImd1uev.js} +0 -0
  184. /package/dist/{twig-C4dfP84J.js → twig-DEBVmtOq.js} +0 -0
  185. /package/dist/{typescript-Bk-pp-cK.js → typescript-Xo5tgeOd.js} +0 -0
  186. /package/dist/{typst-DPCpaVSH.js → typst-_Ui0vNYP.js} +0 -0
  187. /package/dist/{v-nRGMJ2Ki.js → v-Ch6vEAHG.js} +0 -0
  188. /package/dist/{vala-B78bKcY0.js → vala-Ds_Ad1cC.js} +0 -0
  189. /package/dist/{verilog-CRpkl76S.js → verilog-CUqRomTC.js} +0 -0
  190. /package/dist/{vim-DpKnut7b.js → vim-BFUPh6oM.js} +0 -0
  191. /package/dist/{vue-D5eadhjo.js → vue-DzgIlbJ2.js} +0 -0
  192. /package/dist/{xml-Dvx5F-hl.js → xml-CmbQxaqc.js} +0 -0
  193. /package/dist/{yaml-n1S8nAOh.js → yaml-BhwCoLnZ.js} +0 -0
  194. /package/dist/{zig-R-iFzxfW.js → zig-Bmrmp8vo.js} +0 -0
  195. /package/dist/{zoomIn-CEukuh3x.js → zoomIn-CCKcyIEv.js} +0 -0
  196. /package/dist/{zoomOut-qlzQyQli.js → zoomOut-BrSwLQZ_.js} +0 -0
@@ -1,10 +1,10 @@
1
- import { a as useMermaid, s as throttle, z as useControls } from "./composables-Cx0nvyHl.js";
2
- import "./tooltip-3UDC9mw-.js";
3
- import "./button-jFTF378X.js";
4
- import { t as error_component_default } from "./error-component-Bhl770lu.js";
5
- import { t as spin_default } from "./spin-Ds5W7qC_.js";
6
- import { t as zoom_container_default } from "./zoom-container-gjQ0EMyk.js";
7
- import { Fragment, computed, createBlock, createCommentVNode, createElementBlock, createElementVNode, createVNode, defineComponent, mergeProps, normalizeStyle, openBlock, ref, resolveDynamicComponent, toRefs, watch, withCtx } from "vue";
1
+ import { V as useControls, g as throttle, p as useMermaid } from "./composables-DWipZHuF.js";
2
+ import "./tooltip-Bdt9-aQx.js";
3
+ import "./button-B2ebQt7R.js";
4
+ import { t as error_component_default } from "./error-component-DSOVrE5J.js";
5
+ import { t as zoom_container_default } from "./zoom-container-f44XxzOI.js";
6
+ import { t as spin_default } from "./spin-D4Oi_m7j.js";
7
+ import { Fragment, computed, createBlock, createCommentVNode, createElementBlock, createElementVNode, createVNode, defineComponent, mergeProps, nextTick, normalizeStyle, openBlock, ref, resolveDynamicComponent, toRefs, watch, withCtx } from "vue";
8
8
  import { useResizeObserver } from "@vueuse/core";
9
9
 
10
10
  //#region src/components/previewers/mermaid.vue?vue&type=script&setup=true&lang.ts
@@ -24,16 +24,8 @@ var mermaid_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ define
24
24
  type: Object,
25
25
  required: true
26
26
  },
27
- mediumZoom: {
28
- type: Object,
29
- required: true
30
- },
31
- indexKey: {
32
- type: [Number, String],
33
- required: true
34
- },
35
- getContainer: {
36
- type: Function,
27
+ nodeKey: {
28
+ type: String,
37
29
  required: true
38
30
  },
39
31
  controls: {
@@ -164,7 +156,9 @@ var mermaid_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ define
164
156
  const data = await renderMermaid(code.value);
165
157
  if (data) {
166
158
  svg.value = data;
167
- updateHeight();
159
+ nextTick(() => {
160
+ updateHeight();
161
+ });
168
162
  }
169
163
  renderFlag.value = true;
170
164
  }), { immediate: true });
@@ -0,0 +1,4 @@
1
+ import "./composables-DWipZHuF.js";
2
+ import { t as modal_default } from "./modal-CEqU9Ubu.js";
3
+
4
+ export { modal_default as default };
@@ -0,0 +1,94 @@
1
+ import { H as useContext } from "./composables-DWipZHuF.js";
2
+ import { Fragment, Teleport, Transition, computed, createBlock, createCommentVNode, createElementBlock, createElementVNode, createTextVNode, createVNode, defineComponent, mergeModels, normalizeStyle, openBlock, renderSlot, toDisplayString, unref, useModel, useSlots, withCtx } from "vue";
3
+ import { createReusableTemplate, useEventListener } from "@vueuse/core";
4
+
5
+ //#region src/components/modal.vue?vue&type=script&setup=true&lang.ts
6
+ const _hoisted_1 = { "data-stream-markdown": "modal-body" };
7
+ var modal_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineComponent({
8
+ __name: "modal",
9
+ props: /* @__PURE__ */ mergeModels({
10
+ title: {
11
+ type: String,
12
+ required: false
13
+ },
14
+ zIndex: {
15
+ type: Number,
16
+ required: false,
17
+ default: 1e3
18
+ },
19
+ modalStyle: {
20
+ type: Object,
21
+ required: false
22
+ },
23
+ headerStyle: {
24
+ type: Object,
25
+ required: false
26
+ },
27
+ transition: {
28
+ type: String,
29
+ required: false,
30
+ default: "modal"
31
+ },
32
+ close: {
33
+ type: Function,
34
+ required: false
35
+ }
36
+ }, {
37
+ "open": {
38
+ type: Boolean,
39
+ required: false,
40
+ default: false
41
+ },
42
+ "openModifiers": {}
43
+ }),
44
+ emits: ["update:open"],
45
+ setup(__props) {
46
+ const props = __props;
47
+ const slots = useSlots();
48
+ const open = useModel(__props, "open");
49
+ const [DefineTemplate, ReuseTemplate] = createReusableTemplate();
50
+ const { getContainer } = useContext();
51
+ const container = computed(() => getContainer() || "body");
52
+ const modalStyle = computed(() => ({
53
+ ...props.modalStyle,
54
+ zIndex: props.zIndex
55
+ }));
56
+ const showHeader = computed(() => !!props.title || !!slots.title || !!slots.extra);
57
+ useEventListener(document, "keyup", (event) => {
58
+ if (event.key === "Escape" || event.key === "Esc") if (props.close) props.close();
59
+ else open.value = false;
60
+ });
61
+ return (_ctx, _cache) => {
62
+ return openBlock(), createElementBlock(Fragment, null, [createVNode(unref(DefineTemplate), null, {
63
+ default: withCtx(() => [open.value ? (openBlock(), createElementBlock("div", {
64
+ key: 0,
65
+ "data-stream-markdown": "modal",
66
+ style: normalizeStyle(modalStyle.value)
67
+ }, [showHeader.value ? (openBlock(), createElementBlock("header", {
68
+ key: 0,
69
+ "data-stream-markdown": "modal-header",
70
+ style: normalizeStyle(__props.headerStyle)
71
+ }, [
72
+ renderSlot(_ctx.$slots, "title", {}, () => [createTextVNode(toDisplayString(__props.title), 1)]),
73
+ renderSlot(_ctx.$slots, "header-center", {}, () => [_cache[0] || (_cache[0] = createElementVNode("div", null, null, -1))]),
74
+ renderSlot(_ctx.$slots, "actions")
75
+ ], 4)) : createCommentVNode("v-if", true), createElementVNode("main", _hoisted_1, [renderSlot(_ctx.$slots, "default")])], 4)) : createCommentVNode("v-if", true)]),
76
+ _: 3
77
+ }), (openBlock(), createBlock(Teleport, { to: container.value }, [__props.transition ? (openBlock(), createBlock(Transition, {
78
+ key: 0,
79
+ name: __props.transition,
80
+ appear: ""
81
+ }, {
82
+ default: withCtx(() => [createVNode(unref(ReuseTemplate))]),
83
+ _: 1
84
+ }, 8, ["name"])) : (openBlock(), createBlock(unref(ReuseTemplate), { key: 1 }))], 8, ["to"]))], 64);
85
+ };
86
+ }
87
+ });
88
+
89
+ //#endregion
90
+ //#region src/components/modal.vue
91
+ var modal_default = modal_vue_vue_type_script_setup_true_lang_default;
92
+
93
+ //#endregion
94
+ export { modal_default as t };
@@ -1,3 +1,4 @@
1
+ import { H as useContext } from "./composables-DWipZHuF.js";
1
2
  import { Fragment, Transition, computed, createBlock, createCommentVNode, createElementBlock, defineComponent, mergeProps, openBlock, renderList, resolveDynamicComponent, withCtx } from "vue";
2
3
 
3
4
  //#region src/components/markdown.vue?vue&type=script&setup=true&lang.ts
@@ -17,16 +18,8 @@ var markdown_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defin
17
18
  type: Object,
18
19
  required: true
19
20
  },
20
- mediumZoom: {
21
- type: Object,
22
- required: true
23
- },
24
- indexKey: {
25
- type: [Number, String],
26
- required: true
27
- },
28
- getContainer: {
29
- type: Function,
21
+ nodeKey: {
22
+ type: String,
30
23
  required: true
31
24
  },
32
25
  controls: {
@@ -93,8 +86,8 @@ var node_list_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defi
93
86
  required: false,
94
87
  default: () => []
95
88
  },
96
- indexKey: {
97
- type: [Number, String],
89
+ nodeKey: {
90
+ type: String,
98
91
  required: false
99
92
  },
100
93
  markdownParser: {
@@ -105,14 +98,6 @@ var node_list_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defi
105
98
  type: Object,
106
99
  required: true
107
100
  },
108
- mediumZoom: {
109
- type: Object,
110
- required: true
111
- },
112
- getContainer: {
113
- type: Function,
114
- required: true
115
- },
116
101
  controls: {
117
102
  type: [Boolean, Object],
118
103
  required: false
@@ -152,11 +137,17 @@ var node_list_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defi
152
137
  },
153
138
  setup(__props) {
154
139
  const props = __props;
140
+ const { mode, enableAnimate } = useContext();
141
+ const enableTransition = computed(() => {
142
+ if (typeof enableAnimate.value === "boolean") return enableAnimate.value;
143
+ return mode.value === "streaming";
144
+ });
155
145
  const nodes = computed(() => {
156
146
  var _props$nodes;
157
147
  return (_props$nodes = props.nodes) === null || _props$nodes === void 0 ? void 0 : _props$nodes.map((node, index) => ({
158
148
  node,
159
- index
149
+ index,
150
+ key: getNodeKey(node, index)
160
151
  }));
161
152
  });
162
153
  const excludeTransition = ["code"];
@@ -170,22 +161,24 @@ var node_list_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defi
170
161
  nodes: void 0
171
162
  };
172
163
  }
173
- function getNodeIndexKey(index) {
174
- return `${props.indexKey || "stream-markdown"}-${index}`;
164
+ function getNodeKey(node, index) {
165
+ const nodeKey = `${props.nodeKey || "stream-markdown"}-${node.type}`;
166
+ if (node.type === "footnoteReference" || node.type === "footnoteDefinition") return `${nodeKey}-${node.identifier}`;
167
+ return `${nodeKey}-${index}`;
175
168
  }
176
169
  return (_ctx, _cache) => {
177
170
  return openBlock(true), createElementBlock(Fragment, null, renderList(nodes.value, (item) => {
178
- return openBlock(), createElementBlock(Fragment, { key: item.index }, [!excludeTransition.includes(item.node.type) ? (openBlock(), createBlock(Transition, {
171
+ return openBlock(), createElementBlock(Fragment, { key: item.key }, [enableTransition.value && !excludeTransition.includes(item.node.type) ? (openBlock(), createBlock(Transition, {
179
172
  key: 0,
180
173
  name: "typewriter",
181
174
  appear: ""
182
175
  }, {
183
- default: withCtx(() => [(openBlock(), createBlock(resolveDynamicComponent(getNodeComponent(item.node)), mergeProps({ ref_for: true }, getNodeBindings(item.node), { "index-key": getNodeIndexKey(item.index) }), null, 16, ["index-key"]))]),
176
+ default: withCtx(() => [(openBlock(), createBlock(resolveDynamicComponent(getNodeComponent(item.node)), mergeProps({ ref_for: true }, getNodeBindings(item.node), { "node-key": item.key }), null, 16, ["node-key"]))]),
184
177
  _: 2
185
178
  }, 1024)) : (openBlock(), createBlock(resolveDynamicComponent(getNodeComponent(item.node)), mergeProps({
186
179
  key: 1,
187
180
  ref_for: true
188
- }, getNodeBindings(item.node), { "index-key": getNodeIndexKey(item.index) }), null, 16, ["index-key"]))], 64);
181
+ }, getNodeBindings(item.node), { "node-key": item.key }), null, 16, ["node-key"]))], 64);
189
182
  }), 128);
190
183
  };
191
184
  }
@@ -0,0 +1,4 @@
1
+ import "./composables-DWipZHuF.js";
2
+ import { t as node_list_default } from "./node-list--v2wbxOo.js";
3
+
4
+ export { node_list_default as default };
@@ -1,4 +1,5 @@
1
- import { t as node_list_default } from "./node-list-CGr_EVtn.js";
1
+ import "./composables-DWipZHuF.js";
2
+ import { t as node_list_default } from "./node-list--v2wbxOo.js";
2
3
  import { createElementBlock, createVNode, defineComponent, mergeProps, openBlock } from "vue";
3
4
 
4
5
  //#region src/components/renderers/paragraph.vue?vue&type=script&setup=true&lang.ts
@@ -18,16 +19,8 @@ var paragraph_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defi
18
19
  type: Object,
19
20
  required: true
20
21
  },
21
- mediumZoom: {
22
- type: Object,
23
- required: true
24
- },
25
- indexKey: {
26
- type: [Number, String],
27
- required: true
28
- },
29
- getContainer: {
30
- type: Function,
22
+ nodeKey: {
23
+ type: String,
31
24
  required: true
32
25
  },
33
26
  controls: {
@@ -0,0 +1,10 @@
1
+ import { defineAsyncComponent } from "vue";
2
+
3
+ //#region src/components/previewers/index.ts
4
+ const CODE_PREVIEWERS = {
5
+ html: defineAsyncComponent(() => import("./html-DFU0myJP.js")),
6
+ mermaid: defineAsyncComponent(() => import("./mermaid-0x6C2MY5.js"))
7
+ };
8
+
9
+ //#endregion
10
+ export { CODE_PREVIEWERS as t };
@@ -0,0 +1,24 @@
1
+ import { createElementBlock, createElementVNode, markRaw, openBlock } from "vue";
2
+
3
+ //#region ~icons/lucide/rotate-ccw-square
4
+ const _hoisted_1 = {
5
+ viewBox: "0 0 24 24",
6
+ width: "1.2em",
7
+ height: "1.2em"
8
+ };
9
+ function render(_ctx, _cache) {
10
+ return openBlock(), createElementBlock("svg", _hoisted_1, [..._cache[0] || (_cache[0] = [createElementVNode("g", {
11
+ fill: "none",
12
+ stroke: "currentColor",
13
+ "stroke-linecap": "round",
14
+ "stroke-linejoin": "round",
15
+ "stroke-width": "2"
16
+ }, [createElementVNode("path", { d: "M20 9V7a2 2 0 0 0-2-2h-6" }), createElementVNode("path", { d: "m15 2l-3 3l3 3m5 5v5a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V7a2 2 0 0 1 2-2h2" })], -1)])]);
17
+ }
18
+ var rotate_ccw_square_default = markRaw({
19
+ name: "lucide-rotate-ccw-square",
20
+ render
21
+ });
22
+
23
+ //#endregion
24
+ export { rotate_ccw_square_default as default };
@@ -0,0 +1,6 @@
1
+ import "./composables-DWipZHuF.js";
2
+ import "./tooltip-Bdt9-aQx.js";
3
+ import "./button-B2ebQt7R.js";
4
+ import { t as segmented_default } from "./segmented-Drf8EBQD.js";
5
+
6
+ export { segmented_default as default };
@@ -1,4 +1,4 @@
1
- import { t as button_default } from "./button-jFTF378X.js";
1
+ import { t as button_default } from "./button-B2ebQt7R.js";
2
2
  import { Fragment, createBlock, createElementBlock, defineComponent, mergeModels, openBlock, renderList, useModel } from "vue";
3
3
 
4
4
  //#region src/components/segmented.vue?vue&type=script&setup=true&lang.ts
@@ -1,6 +1,6 @@
1
- import { V as useCodeOptions, i as useShiki } from "./composables-Cx0nvyHl.js";
2
- import { t as vanilla_default } from "./vanilla-CFWVwBvD.js";
3
- import { computed, createBlock, createCommentVNode, defineAsyncComponent, defineComponent, mergeProps, normalizeProps, openBlock, ref, toRefs, unref, watch } from "vue";
1
+ import { U as useCodeOptions, r as useShiki } from "./composables-DWipZHuF.js";
2
+ import { t as vanilla_default } from "./vanilla-BSgZTIo9.js";
3
+ import { computed, createBlock, createCommentVNode, defineAsyncComponent, defineComponent, guardReactiveProps, mergeProps, normalizeProps, openBlock, ref, toRefs, unref, watch } from "vue";
4
4
 
5
5
  //#region src/components/renderers/code/shiki.vue?vue&type=script&setup=true&lang.ts
6
6
  var shiki_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineComponent({
@@ -18,16 +18,8 @@ var shiki_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineCo
18
18
  type: Object,
19
19
  required: true
20
20
  },
21
- mediumZoom: {
22
- type: Object,
23
- required: true
24
- },
25
- indexKey: {
26
- type: [Number, String],
27
- required: true
28
- },
29
- getContainer: {
30
- type: Function,
21
+ nodeKey: {
22
+ type: String,
31
23
  required: true
32
24
  },
33
25
  controls: {
@@ -70,7 +62,7 @@ var shiki_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineCo
70
62
  setup(__props) {
71
63
  const props = __props;
72
64
  const { shikiOptions, codeOptions, isDark } = toRefs(props);
73
- const ShikiTokensRenderer = defineAsyncComponent(() => import("./shiki-token-renderer-D164wC7Y.js"));
65
+ const ShikiTokensRenderer = defineAsyncComponent(() => import("./shiki-token-renderer-BMveKuYt.js"));
74
66
  const code = computed(() => props.node.value.trim());
75
67
  const lang = computed(() => props.node.lang || "");
76
68
  const { showLineNumbers } = useCodeOptions({
@@ -0,0 +1,3 @@
1
+ import { t as spin_default } from "./spin-D4Oi_m7j.js";
2
+
3
+ export { spin_default as default };
@@ -1,4 +1,5 @@
1
- import { t as node_list_default } from "./node-list-CGr_EVtn.js";
1
+ import "./composables-DWipZHuF.js";
2
+ import { t as node_list_default } from "./node-list--v2wbxOo.js";
2
3
  import { createElementBlock, createVNode, defineComponent, mergeProps, openBlock } from "vue";
3
4
 
4
5
  //#region src/components/renderers/strong.vue?vue&type=script&setup=true&lang.ts
@@ -18,16 +19,8 @@ var strong_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineC
18
19
  type: Object,
19
20
  required: true
20
21
  },
21
- mediumZoom: {
22
- type: Object,
23
- required: true
24
- },
25
- indexKey: {
26
- type: [Number, String],
27
- required: true
28
- },
29
- getContainer: {
30
- type: Function,
22
+ nodeKey: {
23
+ type: String,
31
24
  required: true
32
25
  },
33
26
  controls: {
@@ -0,0 +1,3 @@
1
+ import { t as table_default } from "./table-iNA4la0w.js";
2
+
3
+ export { table_default as default };
@@ -1,9 +1,9 @@
1
- import { B as useContext, O as save, b as tableDataToMarkdown, u as useI18n, v as extractTableDataFromElement, x as tableDataToTSV, y as tableDataToCSV, z as useControls } from "./composables-Cx0nvyHl.js";
2
- import { t as node_list_default } from "./node-list-CGr_EVtn.js";
3
- import "./tooltip-3UDC9mw-.js";
4
- import { t as button_default } from "./button-jFTF378X.js";
5
- import { t as spin_default } from "./spin-Ds5W7qC_.js";
6
- import { t as table_default$1 } from "./table-4ec9FVB_.js";
1
+ import { A as save, C as tableDataToTSV, H as useContext, P as useI18n, S as tableDataToMarkdown, V as useControls, b as extractTableDataFromElement, x as tableDataToCSV } from "./composables-DWipZHuF.js";
2
+ import { t as node_list_default } from "./node-list--v2wbxOo.js";
3
+ import "./tooltip-Bdt9-aQx.js";
4
+ import { t as button_default } from "./button-B2ebQt7R.js";
5
+ import { t as spin_default } from "./spin-D4Oi_m7j.js";
6
+ import { t as table_default$1 } from "./table-iNA4la0w.js";
7
7
  import { Fragment, computed, createBlock, createCommentVNode, createElementBlock, createElementVNode, createVNode, defineComponent, mergeProps, openBlock, ref, renderList, withCtx } from "vue";
8
8
  import { useClipboard } from "@vueuse/core";
9
9
 
@@ -26,16 +26,8 @@ var table_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineCo
26
26
  type: Object,
27
27
  required: true
28
28
  },
29
- mediumZoom: {
30
- type: Object,
31
- required: true
32
- },
33
- indexKey: {
34
- type: [Number, String],
35
- required: true
36
- },
37
- getContainer: {
38
- type: Function,
29
+ nodeKey: {
30
+ type: String,
39
31
  required: true
40
32
  },
41
33
  controls: {
@@ -93,8 +85,9 @@ var table_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineCo
93
85
  return align.value[index] || "left";
94
86
  }
95
87
  function getTableContent(format) {
96
- if (!tableRef.value) return null;
97
- const tableData = extractTableDataFromElement(tableRef.value);
88
+ var _tableRef$value;
89
+ if (!((_tableRef$value = tableRef.value) === null || _tableRef$value === void 0 ? void 0 : _tableRef$value.$el)) return null;
90
+ const tableData = extractTableDataFromElement(tableRef.value.$el);
98
91
  switch (format) {
99
92
  case "markdown": return {
100
93
  content: tableDataToMarkdown(tableData),
@@ -172,6 +165,8 @@ var table_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineCo
172
165
  ]);
173
166
  }), 128))]),
174
167
  createElementVNode("div", _hoisted_3, [createVNode(table_default$1, {
168
+ ref_key: "tableRef",
169
+ ref: tableRef,
175
170
  headers: headerCells.value,
176
171
  rows: bodyRows.value,
177
172
  "get-align": getAlign
@@ -17,16 +17,8 @@ var text_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineCom
17
17
  type: Object,
18
18
  required: true
19
19
  },
20
- mediumZoom: {
21
- type: Object,
22
- required: true
23
- },
24
- indexKey: {
25
- type: [Number, String],
26
- required: true
27
- },
28
- getContainer: {
29
- type: Function,
20
+ nodeKey: {
21
+ type: String,
30
22
  required: true
31
23
  },
32
24
  controls: {
@@ -17,16 +17,8 @@ var thematic_break_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */
17
17
  type: Object,
18
18
  required: true
19
19
  },
20
- mediumZoom: {
21
- type: Object,
22
- required: true
23
- },
24
- indexKey: {
25
- type: [Number, String],
26
- required: true
27
- },
28
- getContainer: {
29
- type: Function,
20
+ nodeKey: {
21
+ type: String,
30
22
  required: true
31
23
  },
32
24
  controls: {
@@ -0,0 +1,68 @@
1
+ import { B as useFloatingElement, H as useContext } from "./composables-DWipZHuF.js";
2
+ import { Fragment, Teleport, createBlock, createCommentVNode, createElementBlock, createElementVNode, defineComponent, mergeProps, normalizeStyle, openBlock, renderSlot, toDisplayString, toRefs, unref } from "vue";
3
+
4
+ //#region src/components/tooltip.vue?vue&type=script&setup=true&lang.ts
5
+ const _hoisted_1 = { "data-stream-markdown": "tooltip-overlay" };
6
+ var tooltip_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineComponent({
7
+ inheritAttrs: false,
8
+ __name: "tooltip",
9
+ props: {
10
+ content: {
11
+ type: String,
12
+ required: false
13
+ },
14
+ trigger: {
15
+ type: String,
16
+ required: false,
17
+ default: "hover"
18
+ },
19
+ placement: {
20
+ type: [String, Object],
21
+ required: false,
22
+ default: "top"
23
+ },
24
+ delay: {
25
+ type: [Number, Array],
26
+ required: false,
27
+ default: () => [100, 100]
28
+ }
29
+ },
30
+ setup(__props, { expose: __expose }) {
31
+ const { placement, delay, trigger } = toRefs(__props);
32
+ const { getContainer } = useContext();
33
+ const { referenceEl: _referenceEl, floatingEl: _floatingEl, open, appendTo, floatingStyle, show, hide, onMouseEnter, onMouseLeave, onClick, onFloatingEnter, onFloatingLeave } = useFloatingElement({
34
+ placement,
35
+ delay,
36
+ trigger,
37
+ getContainer
38
+ });
39
+ __expose({
40
+ show,
41
+ hide
42
+ });
43
+ return (_ctx, _cache) => {
44
+ return openBlock(), createElementBlock(Fragment, null, [createElementVNode("span", mergeProps(_ctx.$attrs, {
45
+ ref_key: "_referenceEl",
46
+ ref: _referenceEl,
47
+ onMouseenter: _cache[0] || (_cache[0] = (...args) => unref(onMouseEnter) && unref(onMouseEnter)(...args)),
48
+ onMouseleave: _cache[1] || (_cache[1] = (...args) => unref(onMouseLeave) && unref(onMouseLeave)(...args)),
49
+ onClick: _cache[2] || (_cache[2] = (...args) => unref(onClick) && unref(onClick)(...args))
50
+ }), [renderSlot(_ctx.$slots, "default")], 16), (openBlock(), createBlock(Teleport, { to: unref(appendTo) }, [unref(open) ? (openBlock(), createElementBlock("div", {
51
+ key: 0,
52
+ ref_key: "_floatingEl",
53
+ ref: _floatingEl,
54
+ style: normalizeStyle(unref(floatingStyle)),
55
+ "data-stream-markdown": "tooltip",
56
+ onMouseenter: _cache[3] || (_cache[3] = (...args) => unref(onFloatingEnter) && unref(onFloatingEnter)(...args)),
57
+ onMouseleave: _cache[4] || (_cache[4] = (...args) => unref(onFloatingLeave) && unref(onFloatingLeave)(...args))
58
+ }, [renderSlot(_ctx.$slots, "content", {}, () => [createElementVNode("pre", _hoisted_1, toDisplayString(__props.content), 1)])], 36)) : createCommentVNode("v-if", true)], 8, ["to"]))], 64);
59
+ };
60
+ }
61
+ });
62
+
63
+ //#endregion
64
+ //#region src/components/tooltip.vue
65
+ var tooltip_default = tooltip_vue_vue_type_script_setup_true_lang_default;
66
+
67
+ //#endregion
68
+ export { tooltip_default as t };
@@ -0,0 +1,4 @@
1
+ import "./composables-DWipZHuF.js";
2
+ import { t as tooltip_default } from "./tooltip-Bdt9-aQx.js";
3
+
4
+ export { tooltip_default as default };
@@ -1,4 +1,4 @@
1
- import { V as useCodeOptions } from "./composables-Cx0nvyHl.js";
1
+ import { U as useCodeOptions } from "./composables-DWipZHuF.js";
2
2
  import { computed, defineComponent, h, renderList, toRefs } from "vue";
3
3
 
4
4
  //#region src/components/renderers/code/vanilla.ts
@@ -0,0 +1,4 @@
1
+ import "./composables-DWipZHuF.js";
2
+ import { t as vanilla_default } from "./vanilla-BSgZTIo9.js";
3
+
4
+ export { vanilla_default as default };
@@ -1,4 +1,4 @@
1
- import { t as table_default } from "./table-4ec9FVB_.js";
1
+ import { t as table_default } from "./table-iNA4la0w.js";
2
2
  import { computed, createElementBlock, createTextVNode, createVNode, defineComponent, openBlock, toDisplayString, withCtx } from "vue";
3
3
 
4
4
  //#region src/components/renderers/yaml.vue?vue&type=script&setup=true&lang.ts
@@ -18,16 +18,8 @@ var yaml_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineCom
18
18
  type: Object,
19
19
  required: true
20
20
  },
21
- mediumZoom: {
22
- type: Object,
23
- required: true
24
- },
25
- indexKey: {
26
- type: [Number, String],
27
- required: true
28
- },
29
- getContainer: {
30
- type: Function,
21
+ nodeKey: {
22
+ type: String,
31
23
  required: true
32
24
  },
33
25
  controls: {
@@ -4,12 +4,19 @@ var button = {
4
4
  "zoomOut": "缩小",
5
5
  "resetZoom": "重置缩放",
6
6
  "preview": "预览",
7
- "source": "源代码",
7
+ "source": "代码",
8
8
  "collapse": "折叠",
9
9
  "copy": "复制",
10
10
  "download": "下载",
11
11
  "minimize": "最小化",
12
- "maximize": "最大化"
12
+ "maximize": "最大化",
13
+ "flipY": "翻转 Y",
14
+ "flipX": "翻转 X",
15
+ "rotateLeft": "左转",
16
+ "rotateRight": "右转",
17
+ "previous": "上个",
18
+ "next": "下个",
19
+ "back": "返回"
13
20
  };
14
21
  var error = {
15
22
  "vanilla": "错误",
@@ -0,0 +1,6 @@
1
+ import "./composables-DWipZHuF.js";
2
+ import "./tooltip-Bdt9-aQx.js";
3
+ import "./button-B2ebQt7R.js";
4
+ import { t as zoom_container_default } from "./zoom-container-f44XxzOI.js";
5
+
6
+ export { zoom_container_default as default };