vue-stream-markdown 0.1.5 → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (199) hide show
  1. package/README.md +1 -0
  2. package/dist/{blockquote-bkADuiGm.js → blockquote-C68fU4lp.js} +4 -3
  3. package/dist/{button-BQhuT7wh.js → button-BDO3n0n_.js} +36 -28
  4. package/dist/button-CdUyT8T_.js +6 -0
  5. package/dist/{code-DF8PTNol.js → code-2Dd0EGfm.js} +12 -11
  6. package/dist/code-block-Co2UoPPS.js +10 -0
  7. package/dist/{code-block-Dm2wl0cb.js → code-block-hQLDeAmP.js} +68 -80
  8. package/dist/{composables-yny5gJo3.js → composables-DuQ72m6O.js} +1163 -1115
  9. package/dist/corner-down-left-B77X84F8.js +24 -0
  10. package/dist/{delete-D17YBeI-.js → delete-CB-OS2WZ.js} +4 -3
  11. package/dist/dist-CYkm26BF.js +119 -0
  12. package/dist/dropdown-BB3nyts8.js +6 -0
  13. package/dist/{emphasis-B-2R_0Q5.js → emphasis-BmUoyBRK.js} +4 -3
  14. package/dist/{en-US-Kw2LYAMk.js → en-US-Cw-sFSiZ.js} +2 -1
  15. package/dist/{error-component-Bb0gIZsx.js → error-component-CtZr0_st.js} +10 -4
  16. package/dist/error-component-biOT0E-h.js +5 -0
  17. package/dist/footnote-definition-55TjXXwa.js +104 -0
  18. package/dist/footnote-reference-lk2rvC4Q.js +86 -0
  19. package/dist/{heading-DyJIwNrN.js → heading-BlOK3uk2.js} +4 -3
  20. package/dist/{html-DXNqMvt_.js → html-D7bGx0Cz.js} +2 -2
  21. package/dist/icon-PEivHbuv.js +67 -0
  22. package/dist/icon-mUoYnA6R.js +4 -0
  23. package/dist/image-B6Pw2YBI.js +9 -0
  24. package/dist/{image-BPhFn1xp.js → image-Bqn98dDB.js} +18 -15
  25. package/dist/image-VMGQj_VU.js +258 -0
  26. package/dist/{index.css → index.css/index.css} +31 -4
  27. package/dist/index.d.ts +297 -196
  28. package/dist/index.js +2511 -74
  29. package/dist/{inline-code-C44UJ2TH.js → inline-code-BZNE1ALQ.js} +2 -2
  30. package/dist/{inline-math-wO1rMt9T.js → inline-math--lfq9WCW.js} +5 -4
  31. package/dist/{link-sGo7CEll.js → link-DAOjAX6n.js} +7 -6
  32. package/dist/{list-C0I1ysSI.js → list-EOEqkWEi.js} +4 -3
  33. package/dist/{list-item-BoC2wKBL.js → list-item-ZG4eadLp.js} +4 -3
  34. package/dist/{math-BlqtUf2r.js → math-3zyrsc0O.js} +5 -4
  35. package/dist/{mermaid-Ka1jnXrR.js → mermaid-VkvXdOuQ.js} +32 -18
  36. package/dist/modal-BKzT1TQI.js +4 -0
  37. package/dist/{modal-Rc_RoeYA.js → modal-DrPdD2g1.js} +4 -4
  38. package/dist/{node-list-YhpHXdM_.js → node-list-D7eKaZGS.js} +19 -10
  39. package/dist/node-list-DtNGUnnI.js +4 -0
  40. package/dist/{paragraph-BN-4-Dn7.js → paragraph-DEyWEFYY.js} +4 -3
  41. package/dist/previewers-DYnyVv4Y.js +10 -0
  42. package/dist/segmented-6Ch-Ees3.js +7 -0
  43. package/dist/{segmented-CaC54iz_.js → segmented-CeLXMLZa.js} +1 -1
  44. package/dist/{shiki-sJNZTn1K.js → shiki-Dgoch7Q6.js} +5 -5
  45. package/dist/spin-DElj7VPm.js +3 -0
  46. package/dist/{strong-NdAS3VjP.js → strong-CFjQLk1h.js} +4 -3
  47. package/dist/table-20vwclBI.js +3 -0
  48. package/dist/{table-CWX5B2i1.js → table-DI25RphX.js} +21 -25
  49. package/dist/{text-DpleLvNh.js → text-DP2IAZrc.js} +2 -2
  50. package/dist/{thematic-break-D5GvzU5S.js → thematic-break-DIO-A8eY.js} +2 -2
  51. package/dist/tooltip-CAyfm3_l.js +4 -0
  52. package/dist/{tooltip-Bgbzbk4Q.js → tooltip-CnO7OPL1.js} +1 -1
  53. package/dist/vanilla-BZ1fQWZQ.js +4 -0
  54. package/dist/{vanilla-BTOVqKl7.js → vanilla-YFxsSfhA.js} +1 -1
  55. package/dist/{yaml-y0snrPRx.js → yaml-eOuEqAWX.js} +3 -3
  56. package/dist/{zh-CN-Dfow4Yn2.js → zh-CN-B9lWRP8O.js} +3 -2
  57. package/dist/{zoom-container-B1qbA-7z.js → zoom-container-CrKx_BbS.js} +32 -32
  58. package/dist/zoom-container-j4kY9qX_.js +7 -0
  59. package/package.json +19 -12
  60. package/dist/button-JYC8d-B-.js +0 -5
  61. package/dist/code-block-BhMDz2ZL.js +0 -9
  62. package/dist/dropdown-Y5_Z4a_u.js +0 -5
  63. package/dist/error-component-DEIWb6kB.js +0 -4
  64. package/dist/image-DXBD47sF.js +0 -8
  65. package/dist/image-DvOGBhi-.js +0 -327
  66. package/dist/modal-Duhc-vVa.js +0 -4
  67. package/dist/node-list-C1je2nLd.js +0 -3
  68. package/dist/previewers-D0VVcdjL.js +0 -10
  69. package/dist/segmented-XdoLnuuq.js +0 -6
  70. package/dist/spin-wM2KE8mO.js +0 -3
  71. package/dist/table-R9gmCXm_.js +0 -3
  72. package/dist/tooltip-BJDs-A8d.js +0 -4
  73. package/dist/vanilla-DA5bwIkr.js +0 -4
  74. package/dist/zoom-container-KztuE4ri.js +0 -6
  75. /package/dist/{angular-Mip1mspI.js → angular-CJL7ngrz.js} +0 -0
  76. /package/dist/{angular-component-Cq5UbX7R.js → angular-component-COlDvuNE.js} +0 -0
  77. /package/dist/{apache-BSq7fX32.js → apache-CVvmKdUn.js} +0 -0
  78. /package/dist/{arrow-left-C5s0Sn8o.js → arrow-left-Dqeb1_Um.js} +0 -0
  79. /package/dist/{asciidoc-DS-PMOLv.js → asciidoc-DOmevTVz.js} +0 -0
  80. /package/dist/{assembly-BPatlOM7.js → assembly-Bj0yQVcL.js} +0 -0
  81. /package/dist/{astro-CSD_ZjXp.js → astro-DUti0QFn.js} +0 -0
  82. /package/dist/{bash-RITislE1.js → bash-BfyNXzLO.js} +0 -0
  83. /package/dist/{batch-DWPShYhN.js → batch-Dp6N3cFQ.js} +0 -0
  84. /package/dist/{bicep-C6BEHfP6.js → bicep-CEkCHedl.js} +0 -0
  85. /package/dist/{c-DNo3tsNy.js → c-CTmG9vr2.js} +0 -0
  86. /package/dist/{check-BfpxIITS.js → check-C6XCJVPi.js} +0 -0
  87. /package/dist/{chevron-down-LeNeemjn.js → chevron-down-aK8OlmM2.js} +0 -0
  88. /package/dist/{circle-alert-BjDuIzgc.js → circle-alert-C5r2kfnc.js} +0 -0
  89. /package/dist/{clojure-C1DEYHW0.js → clojure-CHjliXb8.js} +0 -0
  90. /package/dist/{cmake-B69mdXcH.js → cmake-BsKz8Gt4.js} +0 -0
  91. /package/dist/{cobol-qmL-zIWi.js → cobol-BvWYwPFU.js} +0 -0
  92. /package/dist/{code-D9CiymEK.js → code-Bwlpb4mV.js} +0 -0
  93. /package/dist/{codeowners-Crklt5nF.js → codeowners-CfTM6yvs.js} +0 -0
  94. /package/dist/{coffeescript-k3huSp23.js → coffeescript-BDiFe_B2.js} +0 -0
  95. /package/dist/{copy-C4580J93.js → copy-VpvA-5VS.js} +0 -0
  96. /package/dist/{cpp-Cn3MB35e.js → cpp-BfV_KWzp.js} +0 -0
  97. /package/dist/{crystal-D5aGETSx.js → crystal-BXT0x2i3.js} +0 -0
  98. /package/dist/{csharp-CgkTkbPx.js → csharp-C6rkxA6x.js} +0 -0
  99. /package/dist/{css-DRH4n_IV.js → css-Drxb2cuf.js} +0 -0
  100. /package/dist/{csv-D5nNTIzO.js → csv-CHKRaQ9l.js} +0 -0
  101. /package/dist/{cue-B5mC88-N.js → cue-DksiF2mE.js} +0 -0
  102. /package/dist/{d-BdQRMgma.js → d-C8JgmiVc.js} +0 -0
  103. /package/dist/{dart-BGnfn0NN.js → dart-BX3GppmW.js} +0 -0
  104. /package/dist/{database-Ca1VGX7u.js → database-Lmva5T5u.js} +0 -0
  105. /package/dist/{diff-DVaTsnqu.js → diff-C61xHcnV.js} +0 -0
  106. /package/dist/{docker-E47qYlmL.js → docker-Dws0Euuu.js} +0 -0
  107. /package/dist/{download-DytrK56a.js → download-BB76SD0m.js} +0 -0
  108. /package/dist/{elixir-C-jqqu6q.js → elixir-CtaCeLkf.js} +0 -0
  109. /package/dist/{elm-CmeHvaWl.js → elm-CFvSvo-7.js} +0 -0
  110. /package/dist/{env-Ck1BHoxR.js → env-BwMmmmE5.js} +0 -0
  111. /package/dist/{erlang-CIP8kpGJ.js → erlang-DJRbvPSq.js} +0 -0
  112. /package/dist/{eye-TaEwQS2Z.js → eye-VjweBQoW.js} +0 -0
  113. /package/dist/{flip-horizontal-BFWjqDbQ.js → flip-horizontal-D4IxaKDu.js} +0 -0
  114. /package/dist/{fortran-DJVP2s7V.js → fortran-D3Vf5GTV.js} +0 -0
  115. /package/dist/{fsharp-Bp6mUcG0.js → fsharp-C2iQH5b1.js} +0 -0
  116. /package/dist/{git-BDcqJ1Gp.js → git-DN4z97-P.js} +0 -0
  117. /package/dist/{gleam-JLiZVlev.js → gleam-PhX3VC_5.js} +0 -0
  118. /package/dist/{go-ClcCiS7e.js → go-xPznl0oK.js} +0 -0
  119. /package/dist/{graphql-D2RDo-DF.js → graphql-sVzb1_rA.js} +0 -0
  120. /package/dist/{groovy-DLZBw8xE.js → groovy-Bvkrc3eE.js} +0 -0
  121. /package/dist/{haml-Da74jRwZ.js → haml-Y_qa35Lk.js} +0 -0
  122. /package/dist/{handlebars-CNgS57Sz.js → handlebars-Bo6cxn4k.js} +0 -0
  123. /package/dist/{haskell-DCvfD6VB.js → haskell-D8t1pxAr.js} +0 -0
  124. /package/dist/{haxe-CHVK1TId.js → haxe-C-sdXVB9.js} +0 -0
  125. /package/dist/{html-Du4235Z-.js → html-I3JKB_2G.js} +0 -0
  126. /package/dist/{http-B8VAFeQ5.js → http-Dj2NVTPO.js} +0 -0
  127. /package/dist/{image-D8MZj4W5.js → image-DzKVFSaY.js} +0 -0
  128. /package/dist/{java-CoSdnK1N.js → java-BulcCUaV.js} +0 -0
  129. /package/dist/{javascript-BCDeVll0.js → javascript-DQlby440.js} +0 -0
  130. /package/dist/{jinja-DYbiqZy0.js → jinja-HRQZM5oZ.js} +0 -0
  131. /package/dist/{json-CdzCyWJA.js → json-wUPUX2x-.js} +0 -0
  132. /package/dist/{julia-pswJGtpP.js → julia-DjHYSWzj.js} +0 -0
  133. /package/dist/{kdl-M8rfQ85l.js → kdl-CGLuct22.js} +0 -0
  134. /package/dist/{kotlin-CfCV33oB.js → kotlin-CnR9eg7m.js} +0 -0
  135. /package/dist/{latex-DK8DFhTm.js → latex-CesDKd8G.js} +0 -0
  136. /package/dist/{less-BFnNZiIs.js → less-215r2nUv.js} +0 -0
  137. /package/dist/{link-C7eU_yi-.js → link-4JB1WqYS.js} +0 -0
  138. /package/dist/{liquid-C8h46DoX.js → liquid-FFTnvZwx.js} +0 -0
  139. /package/dist/{lisp-C3FbGuD1.js → lisp-BNWIo3S3.js} +0 -0
  140. /package/dist/{log-D-O3FXf2.js → log-C3BhnPjM.js} +0 -0
  141. /package/dist/{lua-BC_aR1_i.js → lua-jBHQD7Fh.js} +0 -0
  142. /package/dist/{luau-DFUOrNN7.js → luau-CJKAqC3L.js} +0 -0
  143. /package/dist/{makefile-Ck67veVV.js → makefile-DZmoFYpF.js} +0 -0
  144. /package/dist/{markdown-BX13X3kd.js → markdown-BEABBw2C.js} +0 -0
  145. /package/dist/{marko-CQE8YTCc.js → marko-DE7d51Q2.js} +0 -0
  146. /package/dist/{matlab-Bd9O2Ml3.js → matlab-n99nEoGl.js} +0 -0
  147. /package/dist/{maximize-CDZ9rnYF.js → maximize-VRncBaHe.js} +0 -0
  148. /package/dist/{mermaid-Dv-Pr0W-.js → mermaid-Dv9_1JlU.js} +0 -0
  149. /package/dist/{minimize-B9ER7p2X.js → minimize-k8aU78V4.js} +0 -0
  150. /package/dist/{nextflow-D3lDq1Yi.js → nextflow-DjdDVx1j.js} +0 -0
  151. /package/dist/{nginx-CgsqCL4l.js → nginx-DH4jOOdC.js} +0 -0
  152. /package/dist/{nim-BJdSu3c6.js → nim-Cb0hPGv5.js} +0 -0
  153. /package/dist/{nix-B7K_D6CN.js → nix-Bf4Vwv5v.js} +0 -0
  154. /package/dist/{ocaml-gYS1Y45s.js → ocaml-BwJ1z9S7.js} +0 -0
  155. /package/dist/{perl-DXFhFWhI.js → perl-P6bAYvN9.js} +0 -0
  156. /package/dist/{php-We35bF4E.js → php-BGTGPBW1.js} +0 -0
  157. /package/dist/{postcss-BWovY_YV.js → postcss-D8a2Jx1D.js} +0 -0
  158. /package/dist/{powershell-C6teiBsq.js → powershell-DNOnus4K.js} +0 -0
  159. /package/dist/{prisma-UyJEg0_X.js → prisma-DquVk_GR.js} +0 -0
  160. /package/dist/{prolog-YZsPgdnw.js → prolog-BxJJGnOg.js} +0 -0
  161. /package/dist/{properties-DaPbL0e2.js → properties-DjauSeDE.js} +0 -0
  162. /package/dist/{proto-1LIwu2O1.js → proto-3aU1SxxY.js} +0 -0
  163. /package/dist/{pug-CzkUK-Ec.js → pug-OiYFRnMd.js} +0 -0
  164. /package/dist/{puppet-CNhB1MHb.js → puppet-8Sq4QIbE.js} +0 -0
  165. /package/dist/{python-B_hgEobv.js → python-CBYVyhMm.js} +0 -0
  166. /package/dist/{r-CVeKYmPK.js → r-DfzMNaiK.js} +0 -0
  167. /package/dist/{racket-D5UfvXuw.js → racket-EkEmTJtD.js} +0 -0
  168. /package/dist/{razor-RIKaANTN.js → razor-BSd-q379.js} +0 -0
  169. /package/dist/{rotate-ccw-square-C2KVFUF3.js → rotate-ccw-square-Dy0doneR.js} +0 -0
  170. /package/dist/{ruby-C8wV0pMO.js → ruby-CNn-W_DF.js} +0 -0
  171. /package/dist/{rust-75Gei1mP.js → rust-BW9y4Ksf.js} +0 -0
  172. /package/dist/{sass-Cq68xmQ4.js → sass-Cyleqehh.js} +0 -0
  173. /package/dist/{scala-C_E5rjSc.js → scala-2YqaI_aG.js} +0 -0
  174. /package/dist/{scheme-Bm-q-nLL.js → scheme-CWx6sQlk.js} +0 -0
  175. /package/dist/{shader-DPaRkMCs.js → shader-CLzSKNOz.js} +0 -0
  176. /package/dist/{shiki-token-renderer-CLmUjKa3.js → shiki-token-renderer-BjxmGfXH.js} +0 -0
  177. /package/dist/{solidity-DvHG_0CD.js → solidity-CgjJUETv.js} +0 -0
  178. /package/dist/{spin--f5jNjBn.js → spin-DzERwGWy.js} +0 -0
  179. /package/dist/{stata-DoVloJLm.js → stata-CI3W9UFN.js} +0 -0
  180. /package/dist/{svelte-tlbA11de.js → svelte-D-OV6frL.js} +0 -0
  181. /package/dist/{swift-BZn5eRnK.js → swift-CcBwS4X5.js} +0 -0
  182. /package/dist/{table-CaUMjs4M.js → table-BMlD4JhL.js} +0 -0
  183. /package/dist/{terraform-c5-k7yB1.js → terraform-BwM_GPTy.js} +0 -0
  184. /package/dist/{text-DPCGWvDK.js → text-hIzRUiKs.js} +0 -0
  185. /package/dist/{theme.css → theme.css/theme.css} +0 -0
  186. /package/dist/{toml-DdLGBe1A.js → toml-CXJ7B-C1.js} +0 -0
  187. /package/dist/{twig-D_jzZxh6.js → twig-CXQNsdEx.js} +0 -0
  188. /package/dist/{typescript-B95hq2ns.js → typescript-0uiFYOof.js} +0 -0
  189. /package/dist/{typst-CSAEQ4yK.js → typst-gIi5b52E.js} +0 -0
  190. /package/dist/{v-BAhebuOB.js → v-Ct-HfSu0.js} +0 -0
  191. /package/dist/{vala-RAu83-lp.js → vala-BZbAZj2w.js} +0 -0
  192. /package/dist/{verilog-BgmTn52U.js → verilog-NzFyyNP_.js} +0 -0
  193. /package/dist/{vim-c8oTCLkH.js → vim-CN-tRagW.js} +0 -0
  194. /package/dist/{vue-TGT6HTBA.js → vue-BmLzKAao.js} +0 -0
  195. /package/dist/{xml-C1HDr874.js → xml-CBzkooc-.js} +0 -0
  196. /package/dist/{yaml-BO7FjFQZ.js → yaml-CT7I_lPM.js} +0 -0
  197. /package/dist/{zig-qANBp1SU.js → zig-B7F-QzJD.js} +0 -0
  198. /package/dist/{zoomIn-iVMAUxIz.js → zoomIn-DlPeXZbT.js} +0 -0
  199. /package/dist/{zoomOut-Cxq1_dIQ.js → zoomOut-Lvyw8SOW.js} +0 -0
@@ -0,0 +1,258 @@
1
+ import { B as saveImage, U as useControls, W as useContext, m as useMediumZoom, y as useI18n } from "./composables-DuQ72m6O.js";
2
+ import { n as treeFlatFilter } from "./dist-CYkm26BF.js";
3
+ import { t as button_default } from "./button-BDO3n0n_.js";
4
+ import { t as modal_default } from "./modal-DrPdD2g1.js";
5
+ import { t as zoom_container_default } from "./zoom-container-CrKx_BbS.js";
6
+ import { Fragment, computed, createBlock, createElementBlock, createElementVNode, createVNode, defineComponent, mergeProps, normalizeStyle, openBlock, ref, renderList, toRefs, unref, watch, withCtx } from "vue";
7
+ import { useCycleList } from "@vueuse/core";
8
+
9
+ //#region src/components/image.vue?vue&type=script&setup=true&lang.ts
10
+ const _hoisted_1 = [
11
+ "src",
12
+ "alt",
13
+ "title"
14
+ ];
15
+ const _hoisted_2 = [
16
+ "src",
17
+ "alt",
18
+ "title"
19
+ ];
20
+ var image_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineComponent({
21
+ __name: "image",
22
+ props: {
23
+ src: {
24
+ type: String,
25
+ required: false
26
+ },
27
+ alt: {
28
+ type: String,
29
+ required: false
30
+ },
31
+ title: {
32
+ type: String,
33
+ required: false
34
+ },
35
+ preview: {
36
+ type: Boolean,
37
+ required: false,
38
+ default: true
39
+ },
40
+ margin: {
41
+ type: Number,
42
+ required: false,
43
+ default: 16
44
+ },
45
+ controls: {
46
+ type: [Boolean, Object],
47
+ required: false,
48
+ default: true
49
+ },
50
+ transformHardenUrl: {
51
+ type: Function,
52
+ required: false
53
+ },
54
+ nodeProps: {
55
+ type: Object,
56
+ required: true
57
+ }
58
+ },
59
+ emits: ["load", "error"],
60
+ setup(__props, { emit: __emit }) {
61
+ const props = __props;
62
+ const emits = __emit;
63
+ const { margin, controls } = toRefs(props);
64
+ const { t } = useI18n();
65
+ const { icons, parsedNodes } = useContext();
66
+ const { isControlEnabled, getControlValue, resolveControls } = useControls({ controls });
67
+ const imageNodes = computed(() => treeFlatFilter(parsedNodes.value, (node) => node.type === "image" && !node.loading));
68
+ const imageList = computed(() => {
69
+ return [...new Set(imageNodes.value.map((node) => node.url))].filter((url) => props.transformHardenUrl ? props.transformHardenUrl(url) : url).filter(Boolean);
70
+ });
71
+ const { state: imageSrc, prev, next } = useCycleList(imageList, {
72
+ initialValue: props.src,
73
+ fallbackIndex: 0
74
+ });
75
+ const enableDownload = computed(() => isControlEnabled("image.download"));
76
+ const enableCarousel = computed(() => isControlEnabled("image.carousel"));
77
+ const enableFlip = computed(() => isControlEnabled("image.flip"));
78
+ const enableRotate = computed(() => isControlEnabled("image.rotate"));
79
+ const controlPosition = computed(() => {
80
+ const position = getControlValue("image.controlPosition");
81
+ if (typeof position === "boolean") return "bottom-center";
82
+ return position || "bottom-center";
83
+ });
84
+ const loaded = ref(false);
85
+ const open = ref(false);
86
+ const scaleX = ref(1);
87
+ const scaleY = ref(1);
88
+ const rotate = ref(0);
89
+ const { isAnimating, elementRef, zoomElementRef: _zoomElementRef, elementStyle, zoomIn, zoomOut } = useMediumZoom({
90
+ margin,
91
+ open: () => open.value = true,
92
+ close: () => open.value = false
93
+ });
94
+ const imageStyle = computed(() => ({
95
+ transform: `
96
+ scaleX(${scaleX.value})
97
+ scaleY(${scaleY.value})
98
+ rotate(${rotate.value}deg)
99
+ `,
100
+ transition: "transform 0.3s ease",
101
+ ...elementStyle.value
102
+ }));
103
+ const builtinControls = computed(() => [
104
+ {
105
+ key: "download",
106
+ icon: "download",
107
+ name: t("button.download"),
108
+ onClick: download,
109
+ visible: () => !!imageSrc.value && enableDownload.value
110
+ },
111
+ {
112
+ key: "previous",
113
+ icon: "arrowLeft",
114
+ name: t("button.previous"),
115
+ onClick: () => prev(),
116
+ visible: () => imageList.value.length > 1 && enableCarousel.value
117
+ },
118
+ {
119
+ key: "next",
120
+ icon: icons.value.arrowRight ? "arrowRight" : "arrowLeft",
121
+ name: t("button.next"),
122
+ onClick: () => next(),
123
+ buttonStyle: icons.value.arrowRight ? void 0 : { transform: "scaleX(-1)" },
124
+ visible: () => imageList.value.length > 1 && enableCarousel.value
125
+ },
126
+ {
127
+ key: "flipX",
128
+ icon: "flipHorizontal",
129
+ name: t("button.flipX"),
130
+ onClick: flipHorizontal,
131
+ visible: () => enableFlip.value
132
+ },
133
+ {
134
+ key: "flipY",
135
+ icon: icons.value.flipVertical ? "flipVertical" : "flipHorizontal",
136
+ name: t("button.flipY"),
137
+ onClick: flipVertical,
138
+ buttonStyle: icons.value.flipVertical ? void 0 : { rotate: "90deg" },
139
+ visible: () => enableFlip.value
140
+ },
141
+ {
142
+ key: "rotateLeft",
143
+ icon: "rotateLeft",
144
+ name: t("button.rotateLeft"),
145
+ onClick: rotateLeft,
146
+ visible: () => enableRotate.value
147
+ },
148
+ {
149
+ key: "rotateRight",
150
+ icon: icons.value.rotateRight ? "rotateRight" : "rotateLeft",
151
+ name: t("button.rotateRight"),
152
+ onClick: rotateRight,
153
+ buttonStyle: icons.value.rotateRight ? void 0 : { transform: "scaleX(-1)" },
154
+ visible: () => enableRotate.value
155
+ }
156
+ ]);
157
+ const zoomControls = computed(() => resolveControls("image", builtinControls.value, props.nodeProps));
158
+ function handleLoad(event) {
159
+ loaded.value = true;
160
+ emits("load", event);
161
+ }
162
+ function handleError(event) {
163
+ emits("error", event);
164
+ }
165
+ function handleOpen() {
166
+ if (!props.preview || !elementRef.value || !loaded.value) return;
167
+ zoomIn();
168
+ }
169
+ function handleClose() {
170
+ if (isAnimating.value) return;
171
+ zoomOut();
172
+ }
173
+ function download() {
174
+ if (!imageSrc.value) return;
175
+ saveImage(imageSrc.value, props.alt);
176
+ }
177
+ function flipHorizontal() {
178
+ scaleX.value *= -1;
179
+ }
180
+ function flipVertical() {
181
+ scaleY.value *= -1;
182
+ }
183
+ function rotateLeft() {
184
+ rotate.value -= 90;
185
+ }
186
+ function rotateRight() {
187
+ rotate.value += 90;
188
+ }
189
+ watch(open, (data) => {
190
+ if (!data) {
191
+ scaleX.value = 1;
192
+ scaleY.value = 1;
193
+ rotate.value = 0;
194
+ if (props.src) imageSrc.value = props.src;
195
+ }
196
+ });
197
+ return (_ctx, _cache) => {
198
+ return openBlock(), createElementBlock(Fragment, null, [createElementVNode("img", {
199
+ ref_key: "elementRef",
200
+ ref: elementRef,
201
+ "data-stream-markdown": "image",
202
+ src: __props.src,
203
+ alt: __props.alt,
204
+ title: __props.title,
205
+ style: { transition: "transform 300ms cubic-bezier(0.2, 0, 0.2, 1)" },
206
+ loading: "lazy",
207
+ decoding: "async",
208
+ onLoad: handleLoad,
209
+ onError: handleError,
210
+ onClick: handleOpen
211
+ }, null, 40, _hoisted_1), createVNode(modal_default, {
212
+ open: open.value,
213
+ "onUpdate:open": _cache[0] || (_cache[0] = ($event) => open.value = $event),
214
+ transition: "",
215
+ "modal-style": { backgroundColor: "rgba(0, 0, 0, 0.45)" },
216
+ close: handleClose
217
+ }, {
218
+ default: withCtx(() => [createVNode(zoom_container_default, {
219
+ "control-size": "large",
220
+ position: controlPosition.value,
221
+ "container-style": {
222
+ width: "auto",
223
+ maxWidth: `calc(100% - ${props.margin * 2}px)`,
224
+ cursor: "grab"
225
+ },
226
+ onClick: handleClose
227
+ }, {
228
+ controls: withCtx((buttonProps) => [(openBlock(true), createElementBlock(Fragment, null, renderList(zoomControls.value, (item) => {
229
+ return openBlock(), createBlock(button_default, mergeProps({ ref_for: true }, {
230
+ ...buttonProps,
231
+ ...item
232
+ }, {
233
+ key: item.key,
234
+ onClick: item.onClick
235
+ }), null, 16, ["onClick"]);
236
+ }), 128))]),
237
+ default: withCtx(() => [createElementVNode("img", {
238
+ ref_key: "_zoomElementRef",
239
+ ref: _zoomElementRef,
240
+ src: unref(imageSrc),
241
+ alt: __props.alt,
242
+ title: __props.title,
243
+ style: normalizeStyle(imageStyle.value)
244
+ }, null, 12, _hoisted_2)]),
245
+ _: 1
246
+ }, 8, ["position", "container-style"])]),
247
+ _: 1
248
+ }, 8, ["open"])], 64);
249
+ };
250
+ }
251
+ });
252
+
253
+ //#endregion
254
+ //#region src/components/image.vue
255
+ var image_default = image_vue_vue_type_script_setup_true_lang_default;
256
+
257
+ //#endregion
258
+ export { image_default as t };
@@ -48,7 +48,7 @@
48
48
  color: var(--popover-foreground);
49
49
  border: 1px solid var(--border);
50
50
  border-radius: 0.5rem;
51
- z-index: 100;
51
+ z-index: 110;
52
52
  }
53
53
 
54
54
  .stream-markdown [data-stream-markdown='tooltip-overlay'] {
@@ -250,7 +250,7 @@
250
250
 
251
251
  .stream-markdown [data-stream-markdown='zoom-controls'] {
252
252
  position: absolute;
253
- z-index: 10;
253
+ z-index: 1;
254
254
  display: flex;
255
255
  align-items: center;
256
256
  gap: 0.25rem;
@@ -270,7 +270,7 @@
270
270
  margin-block: 1rem;
271
271
  border-radius: 0.75rem;
272
272
  border: 1px solid var(--border);
273
- overflow: hidden;
273
+ overflow: clip;
274
274
  }
275
275
 
276
276
  .stream-markdown [data-stream-markdown='code-block'][data-collapsed='true'] [data-stream-markdown='code-block-header'] {
@@ -278,7 +278,9 @@
278
278
  }
279
279
 
280
280
  .stream-markdown [data-stream-markdown='code-block-header'] {
281
- position: relative;
281
+ position: sticky;
282
+ top: 0;
283
+ z-index: 5;
282
284
  display: flex;
283
285
  justify-content: space-between;
284
286
  align-items: center;
@@ -591,6 +593,31 @@
591
593
  padding: 1rem;
592
594
  }
593
595
 
596
+ .stream-markdown [data-stream-markdown='footnote-reference'] {
597
+ color: var(--primary);
598
+ cursor: pointer;
599
+ }
600
+
601
+ .stream-markdown [data-stream-markdown='footnote-definition'] {
602
+ color: var(--muted-foreground);
603
+ }
604
+
605
+ .stream-markdown [data-stream-markdown='footnote-definition'] [data-stream-markdown='footnote-definition-label'] {
606
+ display: inline-block;
607
+ vertical-align: middle;
608
+ margin-right: 0.25rem;
609
+ }
610
+
611
+ .stream-markdown [data-stream-markdown='footnote-definition'] [data-stream-markdown='footnote-definition-button'] {
612
+ display: inline-block;
613
+ vertical-align: middle;
614
+ margin-left: 0.25rem;
615
+ }
616
+
617
+ .stream-markdown [data-stream-markdown='footnote-definition'] p {
618
+ display: inline;
619
+ }
620
+
594
621
  @media (max-width: 1024px) {
595
622
  .stream-markdown [data-stream-markdown='code-block-header'] {
596
623
  padding-inline: 0.75rem;