@eternalheart/vue-file-preview 1.6.13 → 1.7.1

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 (128) hide show
  1. package/README.md +4 -0
  2. package/README.zh-CN.md +4 -0
  3. package/lib/FilePreviewContent.vue.d.ts +25 -6
  4. package/lib/FilePreviewEmbed.vue.d.ts +19 -6
  5. package/lib/FilePreviewModal.vue.d.ts +19 -6
  6. package/lib/chunks/{EmptyState.vue_vue_type_script_setup_true_lang-C7qk6wj0.mjs → EmptyState.vue_vue_type_script_setup_true_lang-DSQp7H-K.mjs} +1 -1
  7. package/lib/chunks/{avifLoader-CAUzjn-d-C0KRpetN.mjs → avifLoader-CAUzjn-d-Cf00sjt2.mjs} +1 -1
  8. package/lib/chunks/{heicLoader-D_9PukkA-Czof_5FJ.mjs → heicLoader-D_9PukkA-cn1P7b2x.mjs} +1 -1
  9. package/lib/chunks/{index-BASg1cr4.mjs → index-0VXtKKev.mjs} +1018 -1018
  10. package/lib/chunks/index-0fXL30y0.mjs +333 -0
  11. package/lib/chunks/{index-C9mAajbD.mjs → index-B1AwVHWI.mjs} +191 -191
  12. package/lib/chunks/{index-BvBqDq3O.mjs → index-B77rFiau.mjs} +2023 -2023
  13. package/lib/chunks/index-BB10as16.mjs +108 -0
  14. package/lib/chunks/index-BBIn-k4u.mjs +359 -0
  15. package/lib/chunks/index-BSzaI9ea.mjs +122 -0
  16. package/lib/chunks/index-BZvy39tn.mjs +117 -0
  17. package/lib/chunks/index-BlJEM2Lb.mjs +383 -0
  18. package/lib/chunks/{index-CxKZKUJj.mjs → index-CZlnxQFA.mjs} +1385 -1385
  19. package/lib/chunks/index-ClhTPqDI.mjs +137 -0
  20. package/lib/chunks/{index-8Vpbg2kS.mjs → index-D690gnNu.mjs} +118 -117
  21. package/lib/chunks/index-D7WykPYL.mjs +51 -0
  22. package/lib/chunks/{index-DZZN3kYi.mjs → index-DBzyeU0G.mjs} +1609 -1375
  23. package/lib/chunks/{index-Dkro_8Fy.mjs → index-DKFX5ToE.mjs} +33 -33
  24. package/lib/chunks/index-DRmKaFXK.mjs +157 -0
  25. package/lib/chunks/index-DXf3wXT5.mjs +155 -0
  26. package/lib/chunks/{index-BuqPb5mP.mjs → index-Dp7QQjNH.mjs} +114 -114
  27. package/lib/chunks/index-FzI__DHC.mjs +104 -0
  28. package/lib/chunks/index-PWjCziZG.mjs +90 -0
  29. package/lib/chunks/index-bT6XWKO_.mjs +52 -0
  30. package/lib/chunks/{index-DN4Ui0Gh.mjs → index-tX9VR6Vo.mjs} +122 -122
  31. package/lib/chunks/{jp2Loader-Dig19xyo-CKUaGhPl.mjs → jp2Loader-Dig19xyo-D-OEDL3n.mjs} +1 -1
  32. package/lib/chunks/{psdLoader-C0tKUXXl-CYWoQis5.mjs → psdLoader-C0tKUXXl-CVN06LUc.mjs} +1 -1
  33. package/lib/chunks/{rawLoader-C-tPeFAB-C35zC8nZ.mjs → rawLoader-C-tPeFAB-DBqcJPFK.mjs} +5 -5
  34. package/lib/chunks/{tiffLoader-BlhByX8w-BOxg_Du5.mjs → tiffLoader-BlhByX8w-8-0icdyL.mjs} +1 -1
  35. package/lib/chunks/{useShikiHighlight-BPmcxA-h.mjs → useShikiHighlight-a_GUszuU.mjs} +1 -1
  36. package/lib/composables/useAudioPlayer.d.ts +1 -1
  37. package/lib/composables/usePreviewEvents.d.ts +27 -0
  38. package/lib/composables/useRequest.d.ts +16 -4
  39. package/lib/composables/useThemeMode.d.ts +1 -1
  40. package/lib/composables/useTranslator.d.ts +2 -2
  41. package/lib/core/events.d.ts +69 -0
  42. package/lib/core/i18n/index.d.ts +29 -0
  43. package/lib/core/i18n/messages/en-US.d.ts +5 -0
  44. package/lib/core/i18n/messages/index.d.ts +9 -0
  45. package/lib/core/i18n/messages/zh-CN.d.ts +5 -0
  46. package/lib/core/i18n/types.d.ts +23 -0
  47. package/lib/core/index.d.ts +34 -0
  48. package/lib/core/loaders/avifLoader.d.ts +22 -0
  49. package/lib/core/loaders/heicLoader.d.ts +21 -0
  50. package/lib/core/loaders/jp2Loader.d.ts +16 -0
  51. package/lib/core/loaders/jp2Worker.d.ts +1 -0
  52. package/lib/core/loaders/psdLoader.d.ts +14 -0
  53. package/lib/core/loaders/rawLoader.d.ts +14 -0
  54. package/lib/core/loaders/registry.d.ts +32 -0
  55. package/lib/core/loaders/tiffLoader.d.ts +28 -0
  56. package/lib/core/loaders/types.d.ts +56 -0
  57. package/lib/core/types.d.ts +89 -0
  58. package/lib/core/utils/csvParser.d.ts +31 -0
  59. package/lib/core/utils/emptyState.d.ts +28 -0
  60. package/lib/core/utils/excelDataConverter.d.ts +61 -0
  61. package/lib/core/utils/fileNormalizer.d.ts +21 -0
  62. package/lib/core/utils/fileType.d.ts +21 -0
  63. package/lib/core/utils/legacy-office/doc.d.ts +25 -0
  64. package/lib/core/utils/legacy-office/index.d.ts +8 -0
  65. package/lib/core/utils/legacy-office/ole.d.ts +8 -0
  66. package/lib/core/utils/legacy-office/ppt.d.ts +79 -0
  67. package/lib/core/utils/legacy-office/xls.d.ts +28 -0
  68. package/lib/core/utils/mimeTypes.d.ts +29 -0
  69. package/lib/core/utils/ooxml/docx.d.ts +17 -0
  70. package/lib/core/utils/ooxml/index.d.ts +4 -0
  71. package/lib/core/utils/ooxml/pptx.d.ts +7 -0
  72. package/lib/core/utils/ooxml/xml.d.ts +15 -0
  73. package/lib/core/utils/ooxml/zip.d.ts +3 -0
  74. package/lib/core/utils/pdfWorker.d.ts +61 -0
  75. package/lib/core/utils/previewMode.d.ts +7 -0
  76. package/lib/core/utils/request.d.ts +49 -0
  77. package/lib/core/utils/subtitleParser.d.ts +44 -0
  78. package/lib/core/utils/textDecoder.d.ts +30 -0
  79. package/lib/core/utils/uint8ArrayPolyfill.d.ts +18 -0
  80. package/lib/core/utils/zipReader.d.ts +51 -0
  81. package/lib/core/workers/imageDecoder.worker.d.ts +31 -0
  82. package/lib/core/workers/workerClient.d.ts +14 -0
  83. package/lib/i18n/localeKey.d.ts +1 -1
  84. package/lib/index.cjs +60 -60
  85. package/lib/index.css +1 -1
  86. package/lib/index.d.ts +11 -9
  87. package/lib/index.mjs +15 -12
  88. package/lib/renderers/Audio/index.vue.d.ts +1 -1
  89. package/lib/renderers/Cad/index.vue.d.ts +1 -1
  90. package/lib/renderers/Cad/toolbar.d.ts +2 -2
  91. package/lib/renderers/Csv/index.vue.d.ts +1 -1
  92. package/lib/renderers/Doc/index.vue.d.ts +1 -1
  93. package/lib/renderers/Docx/index.vue.d.ts +1 -1
  94. package/lib/renderers/Epub/index.vue.d.ts +1 -1
  95. package/lib/renderers/Font/index.vue.d.ts +1 -1
  96. package/lib/renderers/Image/index.vue.d.ts +2 -2
  97. package/lib/renderers/Json/index.vue.d.ts +2 -2
  98. package/lib/renderers/Markdown/index.vue.d.ts +1 -1
  99. package/lib/renderers/Mobi/index.vue.d.ts +1 -1
  100. package/lib/renderers/Msg/index.vue.d.ts +1 -1
  101. package/lib/renderers/Pdf/index.vue.d.ts +1 -1
  102. package/lib/renderers/Ppt/index.vue.d.ts +1 -1
  103. package/lib/renderers/Pptx/index.vue.d.ts +2 -2
  104. package/lib/renderers/Subtitle/index.vue.d.ts +1 -1
  105. package/lib/renderers/Text/index.vue.d.ts +2 -2
  106. package/lib/renderers/Unsupported/index.vue.d.ts +1 -1
  107. package/lib/renderers/Video/index.vue.d.ts +1 -1
  108. package/lib/renderers/Xlsx/index.vue.d.ts +2 -2
  109. package/lib/renderers/Xml/index.vue.d.ts +1 -1
  110. package/lib/renderers/Zip/TreeItem.vue.d.ts +1 -1
  111. package/lib/renderers/Zip/index.vue.d.ts +1 -1
  112. package/lib/renderers/base.types.d.ts +1 -1
  113. package/lib/renderers/registry.d.ts +1 -1
  114. package/lib/types.d.ts +3 -3
  115. package/package.json +2 -2
  116. package/lib/chunks/index--612Smof.mjs +0 -383
  117. package/lib/chunks/index-B21EAyWz.mjs +0 -137
  118. package/lib/chunks/index-BB0i4QqI.mjs +0 -117
  119. package/lib/chunks/index-BVdrGK3Q.mjs +0 -356
  120. package/lib/chunks/index-BlrFFeqc.mjs +0 -330
  121. package/lib/chunks/index-Bp9CuvMZ.mjs +0 -157
  122. package/lib/chunks/index-Bxpf9v5j.mjs +0 -104
  123. package/lib/chunks/index-CDg6vIbT.mjs +0 -51
  124. package/lib/chunks/index-CWE-hKSs.mjs +0 -90
  125. package/lib/chunks/index-CY3xzGgt.mjs +0 -108
  126. package/lib/chunks/index-D30L8tm9.mjs +0 -155
  127. package/lib/chunks/index-VdzIFJJW.mjs +0 -118
  128. package/lib/chunks/index-aoXgVLBb.mjs +0 -52
@@ -1,60 +1,60 @@
1
- import { ref as f, watch as q, onUnmounted as W, defineComponent as X, toRef as J, computed as B, onMounted as K, onBeforeUnmount as Q, unref as e, openBlock as _, createBlock as V, createElementBlock as H, createElementVNode as a, normalizeClass as D, createVNode as E, toDisplayString as N, normalizeStyle as O, resolveDynamicComponent as Y, Transition as Z, withCtx as ee, createCommentVNode as te } from "vue";
1
+ import { ref as f, watch as G, onUnmounted as O, defineComponent as W, toRef as X, computed as B, onMounted as K, onBeforeUnmount as Q, unref as e, openBlock as _, createBlock as N, createElementBlock as H, createElementVNode as a, normalizeClass as I, createVNode as T, toDisplayString as j, normalizeStyle as J, resolveDynamicComponent as Y, Transition as Z, withCtx as ee, createCommentVNode as te } from "vue";
2
2
  import { VolumeX as ae, Volume1 as oe, Volume2 as ne, AudioLines as le, Pause as se, Play as re, SkipBack as ie, SkipForward as fe, Repeat as ve } from "lucide-vue-next";
3
- import { S as ue, u as pe } from "./index-DZZN3kYi.mjs";
4
- import { _ as de } from "./RendererError.vue_vue_type_script_setup_true_lang-FmkMQHB8.mjs";
5
- function ce(L) {
6
- const v = f(null), y = f(!1), p = f(!0), n = f(0), T = f(0), g = f(1), x = f(!1), h = f(!1), u = f(null);
3
+ import { b as ue, D as pe, J as de, u as ce } from "./index-DBzyeU0G.mjs";
4
+ import { _ as me } from "./RendererError.vue_vue_type_script_setup_true_lang-FmkMQHB8.mjs";
5
+ function ge(x) {
6
+ const v = f(null), y = f(!1), d = f(!0), n = f(0), P = f(0), m = f(1), g = f(!1), h = f(!1), u = f(null), p = ue();
7
7
  let r = null;
8
- const d = () => {
8
+ const L = () => {
9
9
  const t = v.value;
10
10
  if (!t) return;
11
- p.value = !0, u.value = null;
11
+ p.begin(x.value), d.value = !0, u.value = null;
12
12
  const l = () => {
13
13
  isNaN(t.currentTime) || (n.value = t.currentTime);
14
14
  }, s = () => {
15
- !isNaN(t.duration) && isFinite(t.duration) && (T.value = t.duration);
16
- }, c = () => {
17
- p.value = !1, s();
15
+ !isNaN(t.duration) && isFinite(t.duration) && (P.value = t.duration);
18
16
  }, b = () => {
19
- p.value = !0;
17
+ d.value = !1, s(), p.ready();
20
18
  }, w = () => {
21
- p.value = !1, y.value = !0;
22
- }, m = () => {
23
- y.value = !0;
19
+ d.value = !0;
20
+ }, c = () => {
21
+ d.value = !1, y.value = !0;
24
22
  }, k = () => {
25
- y.value = !1;
23
+ y.value = !0;
26
24
  }, M = () => {
27
25
  y.value = !1;
28
- }, P = () => {
29
- u.value = "audio.load_failed", p.value = !1;
26
+ }, C = () => {
27
+ y.value = !1;
28
+ }, E = () => {
29
+ u.value = "audio.load_failed", d.value = !1, p.error(new de("audio.load_failed"), "request");
30
30
  };
31
- t.addEventListener("timeupdate", l), t.addEventListener("loadedmetadata", s), t.addEventListener("durationchange", s), t.addEventListener("canplay", c), t.addEventListener("waiting", b), t.addEventListener("playing", w), t.addEventListener("play", m), t.addEventListener("pause", k), t.addEventListener("ended", M), t.addEventListener("error", P), t.readyState >= 3 ? (p.value = !1, s()) : t.readyState >= 1 && s(), r = () => {
32
- t.removeEventListener("timeupdate", l), t.removeEventListener("loadedmetadata", s), t.removeEventListener("durationchange", s), t.removeEventListener("canplay", c), t.removeEventListener("waiting", b), t.removeEventListener("playing", w), t.removeEventListener("play", m), t.removeEventListener("pause", k), t.removeEventListener("ended", M), t.removeEventListener("error", P);
31
+ t.addEventListener("timeupdate", l), t.addEventListener("loadedmetadata", s), t.addEventListener("durationchange", s), t.addEventListener("canplay", b), t.addEventListener("waiting", w), t.addEventListener("playing", c), t.addEventListener("play", k), t.addEventListener("pause", M), t.addEventListener("ended", C), t.addEventListener("error", E), t.readyState >= 3 ? (d.value = !1, s(), p.ready()) : t.readyState >= 1 && s(), r = () => {
32
+ t.removeEventListener("timeupdate", l), t.removeEventListener("loadedmetadata", s), t.removeEventListener("durationchange", s), t.removeEventListener("canplay", b), t.removeEventListener("waiting", w), t.removeEventListener("playing", c), t.removeEventListener("play", k), t.removeEventListener("pause", M), t.removeEventListener("ended", C), t.removeEventListener("error", E);
33
33
  };
34
34
  };
35
- return q(
36
- L,
35
+ return G(
36
+ x,
37
37
  () => {
38
- r == null || r(), r = null, requestAnimationFrame(() => d());
38
+ r == null || r(), r = null, requestAnimationFrame(() => L());
39
39
  },
40
40
  { flush: "post" }
41
- ), q(
41
+ ), G(
42
42
  v,
43
43
  (t) => {
44
- t && d();
44
+ t && L();
45
45
  },
46
46
  { flush: "post" }
47
- ), W(() => {
47
+ ), O(() => {
48
48
  r == null || r(), r = null;
49
49
  }), {
50
50
  audioRef: v,
51
51
  isPlaying: y,
52
- isLoading: p,
52
+ isLoading: d,
53
53
  isLoop: h,
54
54
  currentTime: n,
55
- duration: T,
56
- volume: g,
57
- isMuted: x,
55
+ duration: P,
56
+ volume: m,
57
+ isMuted: g,
58
58
  error: u,
59
59
  togglePlay: () => {
60
60
  const t = v.value;
@@ -76,11 +76,11 @@ function ce(L) {
76
76
  const l = v.value;
77
77
  if (!l) return;
78
78
  const s = Math.max(0, Math.min(1, t));
79
- l.volume = s, g.value = s, s > 0 && (l.muted = !1, x.value = !1);
79
+ l.volume = s, m.value = s, s > 0 && (l.muted = !1, g.value = !1);
80
80
  },
81
81
  toggleMute: () => {
82
82
  const t = v.value;
83
- t && (t.muted = !t.muted, x.value = t.muted);
83
+ t && (t.muted = !t.muted, g.value = t.muted);
84
84
  },
85
85
  toggleLoop: () => {
86
86
  const t = v.value;
@@ -88,87 +88,87 @@ function ce(L) {
88
88
  const l = !t.loop;
89
89
  t.loop = l, h.value = l;
90
90
  },
91
- formatTime: ue
91
+ formatTime: pe
92
92
  };
93
93
  }
94
- const me = {
94
+ const xe = {
95
95
  key: 1,
96
96
  class: "vfp-flex vfp-items-center vfp-justify-center vfp-w-full vfp-h-full vfp-p-4 vfp-select-none vfp-overflow-auto"
97
- }, ge = { class: "vfp-w-full vfp-max-w-xl vfp-flex-shrink-0 vfp-rounded-lg vfp-border vfp-border-line-weak vfp-bg-surface-1 vfp-p-4" }, xe = { class: "vfp-flex vfp-items-center vfp-gap-3 vfp-mb-4" }, ye = { class: "vfp-min-w-0 vfp-flex-1 vfp-truncate vfp-text-sm vfp-font-medium vfp-text-fg-primary" }, he = { class: "vfp-flex vfp-items-center vfp-gap-3 vfp-mb-4" }, be = { class: "vfp-w-9 vfp-flex-shrink-0 vfp-text-right vfp-text-[11px] vfp-text-fg-tertiary vfp-tabular-nums" }, we = { class: "vfp-relative vfp-h-4 vfp-flex vfp-flex-1 vfp-items-center" }, ke = { class: "vfp-absolute vfp-left-[6px] vfp-right-[6px] vfp-h-[3px] vfp-rounded-full vfp-bg-surface-3" }, _e = ["max", "value", "disabled", "aria-label"], Le = { class: "vfp-w-9 vfp-flex-shrink-0 vfp-text-[11px] vfp-text-fg-tertiary vfp-tabular-nums" }, Ee = { class: "vfp-flex vfp-items-center vfp-gap-1" }, Te = ["title", "aria-label"], Me = ["title", "aria-label"], Pe = ["title", "aria-label"], Ce = ["title", "aria-label"], Ve = ["title", "aria-label"], Ne = {
97
+ }, ye = { class: "vfp-w-full vfp-max-w-xl vfp-flex-shrink-0 vfp-rounded-lg vfp-border vfp-border-line-weak vfp-bg-surface-1 vfp-p-4" }, he = { class: "vfp-flex vfp-items-center vfp-gap-3 vfp-mb-4" }, be = { class: "vfp-min-w-0 vfp-flex-1 vfp-truncate vfp-text-sm vfp-font-medium vfp-text-fg-primary" }, we = { class: "vfp-flex vfp-items-center vfp-gap-3 vfp-mb-4" }, ke = { class: "vfp-w-9 vfp-flex-shrink-0 vfp-text-right vfp-text-[11px] vfp-text-fg-tertiary vfp-tabular-nums" }, _e = { class: "vfp-relative vfp-h-4 vfp-flex vfp-flex-1 vfp-items-center" }, Le = { class: "vfp-absolute vfp-left-[6px] vfp-right-[6px] vfp-h-[3px] vfp-rounded-full vfp-bg-surface-3" }, Ee = ["max", "value", "disabled", "aria-label"], Te = { class: "vfp-w-9 vfp-flex-shrink-0 vfp-text-[11px] vfp-text-fg-tertiary vfp-tabular-nums" }, Pe = { class: "vfp-flex vfp-items-center vfp-gap-1" }, Me = ["title", "aria-label"], Ce = ["title", "aria-label"], Ve = ["title", "aria-label"], Ne = ["title", "aria-label"], je = ["title", "aria-label"], Re = {
98
98
  class: "vfp-flex vfp-flex-col vfp-items-center vfp-gap-2",
99
99
  style: { height: "100px" }
100
- }, je = {
100
+ }, De = {
101
101
  class: "vfp-relative vfp-flex vfp-items-center vfp-justify-center",
102
102
  style: { width: "24px", height: "80px" }
103
- }, Re = ["value", "aria-label"], Se = { class: "vfp-text-[10px] vfp-tabular-nums vfp-text-fg-tertiary" }, Fe = ["src"], Ue = /* @__PURE__ */ X({
103
+ }, Fe = ["value", "aria-label"], Se = { class: "vfp-text-[10px] vfp-tabular-nums vfp-text-fg-tertiary" }, $e = ["src"], ze = /* @__PURE__ */ W({
104
104
  __name: "index",
105
105
  props: {
106
106
  url: {},
107
107
  fileName: {}
108
108
  },
109
- setup(L, { expose: v }) {
110
- const p = J(L, "url"), { t: n } = pe(), {
111
- audioRef: T,
112
- isPlaying: g,
113
- isLoop: x,
109
+ setup(x, { expose: v }) {
110
+ const d = X(x, "url"), { t: n } = ce(), {
111
+ audioRef: P,
112
+ isPlaying: m,
113
+ isLoop: g,
114
114
  currentTime: h,
115
115
  duration: u,
116
- volume: r,
117
- isMuted: d,
118
- error: j,
116
+ volume: p,
117
+ isMuted: r,
118
+ error: L,
119
119
  togglePlay: R,
120
- seek: S,
120
+ seek: D,
121
121
  skip: F,
122
- setVolume: I,
123
- toggleMute: $,
124
- toggleLoop: t,
125
- formatTime: l
126
- } = ce(p), s = f(!1), c = f(!1), b = f(0), w = f(null);
127
- let m = null;
128
- const k = B(() => c.value ? b.value : h.value), M = B(() => u.value > 0 ? k.value / u.value : 0), P = B(() => d.value || r.value === 0 ? ae : r.value < 0.5 ? oe : ne), A = (G) => {
129
- w.value && !w.value.contains(G.target) && (s.value = !1);
122
+ setVolume: A,
123
+ toggleMute: S,
124
+ toggleLoop: $,
125
+ formatTime: t
126
+ } = ge(d), l = f(!1), s = f(!1), b = f(0), w = f(null);
127
+ let c = null;
128
+ const k = B(() => s.value ? b.value : h.value), M = B(() => u.value > 0 ? k.value / u.value : 0), C = B(() => r.value || p.value === 0 ? ae : p.value < 0.5 ? oe : ne), E = (z) => {
129
+ w.value && !w.value.contains(z.target) && (l.value = !1);
130
130
  };
131
131
  K(() => {
132
- document.addEventListener("mousedown", A);
132
+ document.addEventListener("mousedown", E);
133
133
  }), Q(() => {
134
- document.removeEventListener("mousedown", A), m !== null && clearTimeout(m);
134
+ document.removeEventListener("mousedown", E), c !== null && clearTimeout(c);
135
135
  });
136
136
  const U = () => {
137
- m !== null && clearTimeout(m), s.value = !0;
138
- }, z = () => {
139
- m = window.setTimeout(() => {
140
- s.value = !1;
137
+ c !== null && clearTimeout(c), l.value = !0;
138
+ }, q = () => {
139
+ c = window.setTimeout(() => {
140
+ l.value = !1;
141
141
  }, 300);
142
142
  };
143
143
  return v({
144
144
  getToolbarGroups: () => []
145
- }), (G, o) => e(j) ? (_(), V(de, {
145
+ }), (z, o) => e(L) ? (_(), N(me, {
146
146
  key: 0,
147
- message: e(n)(e(j))
148
- }, null, 8, ["message"])) : (_(), H("div", me, [
149
- a("div", ge, [
150
- a("div", xe, [
147
+ message: e(n)(e(L))
148
+ }, null, 8, ["message"])) : (_(), H("div", xe, [
149
+ a("div", ye, [
150
+ a("div", he, [
151
151
  a("div", {
152
152
  "aria-hidden": "true",
153
- class: D([
153
+ class: I([
154
154
  "vfp-audio-mark vfp-w-10 vfp-h-10 vfp-flex vfp-items-center vfp-justify-center vfp-rounded-md vfp-flex-shrink-0",
155
- e(g) ? "vfp-audio-mark-playing" : ""
155
+ e(m) ? "vfp-audio-mark-playing" : ""
156
156
  ])
157
157
  }, [
158
- E(e(le), { class: "vfp-w-5 vfp-h-5" })
158
+ T(e(le), { class: "vfp-w-5 vfp-h-5" })
159
159
  ], 2),
160
- a("div", ye, N(L.fileName), 1)
160
+ a("div", be, j(x.fileName), 1)
161
161
  ]),
162
- a("div", he, [
163
- a("span", be, N(e(l)(k.value)), 1),
164
- a("div", we, [
165
- a("div", ke, [
162
+ a("div", we, [
163
+ a("span", ke, j(e(t)(k.value)), 1),
164
+ a("div", _e, [
165
+ a("div", Le, [
166
166
  a("div", {
167
167
  class: "vfp-h-full vfp-rounded-full vfp-pointer-events-none",
168
- style: O({
168
+ style: J({
169
169
  width: `${M.value * 100}%`,
170
170
  background: "var(--fp-player-progress)",
171
- transition: c.value ? "none" : "width 0.1s linear"
171
+ transition: s.value ? "none" : "width 0.1s linear"
172
172
  })
173
173
  }, null, 4)
174
174
  ]),
@@ -182,22 +182,22 @@ const me = {
182
182
  "aria-label": e(n)("audio.aria.progress"),
183
183
  class: "audio-slider vfp-absolute vfp-w-full",
184
184
  onPointerdown: o[0] || (o[0] = () => {
185
- b.value = e(h), c.value = !0;
185
+ b.value = e(h), s.value = !0;
186
186
  }),
187
187
  onInput: o[1] || (o[1] = (i) => {
188
- const C = parseFloat(i.target.value);
189
- c.value ? b.value = C : e(S)(C);
188
+ const V = parseFloat(i.target.value);
189
+ s.value ? b.value = V : e(D)(V);
190
190
  }),
191
191
  onPointerup: o[2] || (o[2] = (i) => {
192
- const C = parseFloat(i.target.value);
193
- e(S)(C), c.value = !1;
192
+ const V = parseFloat(i.target.value);
193
+ e(D)(V), s.value = !1;
194
194
  }),
195
- onPointercancel: o[3] || (o[3] = (i) => c.value = !1)
196
- }, null, 40, _e)
195
+ onPointercancel: o[3] || (o[3] = (i) => s.value = !1)
196
+ }, null, 40, Ee)
197
197
  ]),
198
- a("span", Le, N(e(u) > 0 ? e(l)(e(u)) : "--:--"), 1)
198
+ a("span", Te, j(e(u) > 0 ? e(t)(e(u)) : "--:--"), 1)
199
199
  ]),
200
- a("div", Ee, [
200
+ a("div", Pe, [
201
201
  a("button", {
202
202
  type: "button",
203
203
  class: "vfp-audio-control vfp-w-10 vfp-h-10 vfp-rounded-md vfp-flex vfp-items-center vfp-justify-center vfp-flex-shrink-0",
@@ -205,19 +205,19 @@ const me = {
205
205
  background: "var(--fp-player-progress)",
206
206
  color: "var(--fp-fg-inverse)"
207
207
  },
208
- title: e(g) ? e(n)("audio.aria.pause") : e(n)("audio.aria.play"),
209
- "aria-label": e(g) ? e(n)("audio.aria.pause") : e(n)("audio.aria.play"),
208
+ title: e(m) ? e(n)("audio.aria.pause") : e(n)("audio.aria.play"),
209
+ "aria-label": e(m) ? e(n)("audio.aria.pause") : e(n)("audio.aria.play"),
210
210
  onClick: o[4] || (o[4] = //@ts-ignore
211
211
  (...i) => e(R) && e(R)(...i))
212
212
  }, [
213
- e(g) ? (_(), V(e(se), {
213
+ e(m) ? (_(), N(e(se), {
214
214
  key: 0,
215
215
  class: "vfp-w-5 vfp-h-5"
216
- })) : (_(), V(e(re), {
216
+ })) : (_(), N(e(re), {
217
217
  key: 1,
218
218
  class: "vfp-w-5 vfp-h-5 vfp-ml-0.5"
219
219
  }))
220
- ], 8, Te),
220
+ ], 8, Me),
221
221
  a("button", {
222
222
  type: "button",
223
223
  class: "vfp-audio-control vfp-w-9 vfp-h-9 vfp-rounded-md vfp-flex vfp-items-center vfp-justify-center vfp-transition-colors vfp-text-fg-secondary hover:vfp-bg-surface-3 vfp-flex-shrink-0",
@@ -225,8 +225,8 @@ const me = {
225
225
  "aria-label": e(n)("audio.aria.backward_10"),
226
226
  onClick: o[5] || (o[5] = (i) => e(F)(-10))
227
227
  }, [
228
- E(e(ie), { class: "vfp-w-[18px] vfp-h-[18px]" })
229
- ], 8, Me),
228
+ T(e(ie), { class: "vfp-w-[18px] vfp-h-[18px]" })
229
+ ], 8, Ce),
230
230
  a("button", {
231
231
  type: "button",
232
232
  class: "vfp-audio-control vfp-w-9 vfp-h-9 vfp-rounded-md vfp-flex vfp-items-center vfp-justify-center vfp-transition-colors vfp-text-fg-secondary hover:vfp-bg-surface-3 vfp-flex-shrink-0",
@@ -234,62 +234,62 @@ const me = {
234
234
  "aria-label": e(n)("audio.aria.forward_10"),
235
235
  onClick: o[6] || (o[6] = (i) => e(F)(10))
236
236
  }, [
237
- E(e(fe), { class: "vfp-w-[18px] vfp-h-[18px]" })
238
- ], 8, Pe),
237
+ T(e(fe), { class: "vfp-w-[18px] vfp-h-[18px]" })
238
+ ], 8, Ve),
239
239
  o[11] || (o[11] = a("div", { class: "vfp-w-px vfp-h-5 vfp-mx-1 vfp-bg-divide" }, null, -1)),
240
240
  a("button", {
241
241
  type: "button",
242
- class: D([
242
+ class: I([
243
243
  "vfp-audio-control vfp-w-9 vfp-h-9 vfp-rounded-md vfp-flex vfp-items-center vfp-justify-center vfp-transition-colors vfp-flex-shrink-0",
244
- e(x) ? "vfp-bg-surface-3 vfp-text-fg-primary" : "vfp-text-fg-tertiary hover:vfp-bg-surface-3"
244
+ e(g) ? "vfp-bg-surface-3 vfp-text-fg-primary" : "vfp-text-fg-tertiary hover:vfp-bg-surface-3"
245
245
  ]),
246
- title: e(x) ? e(n)("audio.aria.loop_off") : e(n)("audio.aria.loop_on"),
247
- "aria-label": e(x) ? e(n)("audio.aria.loop_off") : e(n)("audio.aria.loop_on"),
246
+ title: e(g) ? e(n)("audio.aria.loop_off") : e(n)("audio.aria.loop_on"),
247
+ "aria-label": e(g) ? e(n)("audio.aria.loop_off") : e(n)("audio.aria.loop_on"),
248
248
  onClick: o[7] || (o[7] = //@ts-ignore
249
- (...i) => e(t) && e(t)(...i))
249
+ (...i) => e($) && e($)(...i))
250
250
  }, [
251
- E(e(ve), { class: "vfp-w-4 vfp-h-4" })
252
- ], 10, Ce),
251
+ T(e(ve), { class: "vfp-w-4 vfp-h-4" })
252
+ ], 10, Ne),
253
253
  o[12] || (o[12] = a("div", { class: "vfp-flex-1" }, null, -1)),
254
254
  a("div", {
255
255
  ref_key: "volumeRef",
256
256
  ref: w,
257
257
  class: "vfp-relative",
258
258
  onMouseenter: U,
259
- onMouseleave: z
259
+ onMouseleave: q
260
260
  }, [
261
261
  a("button", {
262
262
  type: "button",
263
- class: D([
263
+ class: I([
264
264
  "vfp-audio-control vfp-w-9 vfp-h-9 vfp-rounded-md vfp-flex vfp-items-center vfp-justify-center vfp-transition-colors vfp-flex-shrink-0",
265
- s.value ? "vfp-bg-surface-3 vfp-text-fg-primary" : "vfp-text-fg-secondary hover:vfp-bg-surface-3"
265
+ l.value ? "vfp-bg-surface-3 vfp-text-fg-primary" : "vfp-text-fg-secondary hover:vfp-bg-surface-3"
266
266
  ]),
267
- title: e(d) ? e(n)("audio.aria.unmute") : e(n)("audio.aria.mute"),
268
- "aria-label": e(d) ? e(n)("audio.aria.unmute") : e(n)("audio.aria.mute"),
267
+ title: e(r) ? e(n)("audio.aria.unmute") : e(n)("audio.aria.mute"),
268
+ "aria-label": e(r) ? e(n)("audio.aria.unmute") : e(n)("audio.aria.mute"),
269
269
  onClick: o[8] || (o[8] = //@ts-ignore
270
- (...i) => e($) && e($)(...i))
270
+ (...i) => e(S) && e(S)(...i))
271
271
  }, [
272
- (_(), V(Y(P.value), { class: "vfp-w-4 vfp-h-4" }))
273
- ], 10, Ve),
274
- E(Z, { name: "vfp-fade" }, {
272
+ (_(), N(Y(C.value), { class: "vfp-w-4 vfp-h-4" }))
273
+ ], 10, je),
274
+ T(Z, { name: "vfp-fade" }, {
275
275
  default: ee(() => [
276
- s.value ? (_(), H("div", {
276
+ l.value ? (_(), H("div", {
277
277
  key: 0,
278
278
  class: "vfp-absolute vfp-right-0 vfp-bottom-full vfp-mb-2 vfp-w-[54px] vfp-rounded-md vfp-p-3 vfp-border vfp-bg-surface-toolbar vfp-border-line",
279
279
  onMouseenter: U,
280
- onMouseleave: z
280
+ onMouseleave: q
281
281
  }, [
282
- a("div", Ne, [
283
- a("div", je, [
282
+ a("div", Re, [
283
+ a("div", De, [
284
284
  o[10] || (o[10] = a("div", {
285
285
  class: "vfp-absolute vfp-rounded-full vfp-bg-surface-2",
286
286
  style: { width: "3px", height: "100%" }
287
287
  }, null, -1)),
288
288
  a("div", {
289
289
  class: "vfp-absolute vfp-bottom-0 vfp-rounded-full vfp-pointer-events-none",
290
- style: O({
290
+ style: J({
291
291
  width: "3px",
292
- height: `${(e(d) ? 0 : e(r)) * 100}%`,
292
+ height: `${(e(r) ? 0 : e(p)) * 100}%`,
293
293
  background: "var(--fp-player-progress)",
294
294
  transition: "height 0.1s linear"
295
295
  })
@@ -299,14 +299,14 @@ const me = {
299
299
  min: "0",
300
300
  max: "1",
301
301
  step: "0.01",
302
- value: e(d) ? 0 : e(r),
302
+ value: e(r) ? 0 : e(p),
303
303
  "aria-label": e(n)("audio.aria.volume"),
304
304
  class: "volume-slider-vertical vfp-absolute",
305
305
  style: { width: "80px", height: "24px", transform: "rotate(-90deg)", "transform-origin": "center center" },
306
- onInput: o[9] || (o[9] = (i) => e(I)(parseFloat(i.target.value)))
307
- }, null, 40, Re)
306
+ onInput: o[9] || (o[9] = (i) => e(A)(parseFloat(i.target.value)))
307
+ }, null, 40, Fe)
308
308
  ]),
309
- a("span", Se, N(Math.round((e(d) ? 0 : e(r)) * 100)), 1)
309
+ a("span", Se, j(Math.round((e(r) ? 0 : e(p)) * 100)), 1)
310
310
  ])
311
311
  ], 32)) : te("", !0)
312
312
  ]),
@@ -317,13 +317,13 @@ const me = {
317
317
  ]),
318
318
  a("audio", {
319
319
  ref_key: "audioRef",
320
- ref: T,
321
- src: L.url,
320
+ ref: P,
321
+ src: x.url,
322
322
  class: "vfp-hidden"
323
- }, null, 8, Fe)
323
+ }, null, 8, $e)
324
324
  ]));
325
325
  }
326
326
  });
327
327
  export {
328
- Ue as default
328
+ ze as default
329
329
  };