@vocalstack/player 0.1.0-alpha.26 → 0.1.0-alpha.27

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.
package/dist/index.js CHANGED
@@ -2,7 +2,7 @@ var da = Object.defineProperty;
2
2
  var ha = (t, e, n) => e in t ? da(t, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[e] = n;
3
3
  var Me = (t, e, n) => ha(t, typeof e != "symbol" ? e + "" : e, n);
4
4
  import { jsx as i, jsxs as h, Fragment as xe } from "react/jsx-runtime";
5
- import { useState as I, useRef as v, useEffect as U, useLayoutEffect as Bt, createContext as ni, useMemo as Ie, useContext as Ma, useCallback as Ke, Fragment as ga, forwardRef as fa, useImperativeHandle as pa } from "react";
5
+ import { useState as z, useRef as v, useEffect as U, useLayoutEffect as Bt, createContext as ni, useMemo as Ie, useContext as Ma, useCallback as Ke, Fragment as ga, forwardRef as fa, useImperativeHandle as pa } from "react";
6
6
  import { createPortal as Na } from "react-dom";
7
7
  import { VocalStackError as ri, VocalStack as si } from "@vocalstack/js-sdk";
8
8
  const ii = "https://vocalstack.com", ma = "data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxMDUxLjY5MDciIGhlaWdodD0iMTU1LjMwNjQxIiB2aWV3Qm94PSIwIDAgMTA1MS42OTA2IDE1NS4zMDY0MSI+PGcgdHJhbnNmb3JtPSJtYXRyaXgoMC44ODczNDc3MSwwLDAsMC44OTExODY4MiwtNDIuNzE2NjMsLTEyMy44NTM4OCkiPjxwYXRoIHN0eWxlPSJmaWxsOiM1NWFiZTU7ZmlsbC1vcGFjaXR5OjE7c3Ryb2tlLXdpZHRoOjAuMzcyOTYyIiBkPSJtIDE2NS43NDM2OSwzMTIuMzQ1MTQgYyAtMy42NTkwNCwtMC45NTg2MSAtNi44OTEzMSwtMy4zNTM0OCAtOS4yMTQ5NCwtNi44Mjc1O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Tc2MjIiIHg9IjExOS43ODkyNCIgeT0iMTc2LjI1OTA5IiByeT0iNS42MTA0OTYiLz48L2c+PC9nPjwvc3ZnPg==";
@@ -55,7 +55,7 @@ const X = {
55
55
  function oe({ d: t, ...e }) {
56
56
  return /* @__PURE__ */ i(La, { ...e, children: (Array.isArray(t) ? t : [t]).map((n) => /* @__PURE__ */ i("path", { d: n }, n)) });
57
57
  }
58
- function ka({ size: t = 15 }) {
58
+ function va({ size: t = 15 }) {
59
59
  return /* @__PURE__ */ i("svg", { viewBox: "0 0 24 24", width: t, height: t, fill: "currentColor", "aria-hidden": "true", children: /* @__PURE__ */ i("rect", { x: "6", y: "6", width: "12", height: "12", rx: "2.5" }) });
60
60
  }
61
61
  function jr({ size: t = 13 }) {
@@ -80,7 +80,7 @@ function at({ size: t = 15, color: e = "currentColor", track: n = "rgba(127,127,
80
80
  }
81
81
  );
82
82
  }
83
- function va({ size: t = 12 }) {
83
+ function ka({ size: t = 12 }) {
84
84
  return /* @__PURE__ */ h("svg", { viewBox: "0 0 24 24", width: t, height: t, fill: "currentColor", "aria-hidden": "true", children: [
85
85
  /* @__PURE__ */ i("rect", { x: "6.5", y: "5", width: "3.75", height: "14", rx: "1.2" }),
86
86
  /* @__PURE__ */ i("rect", { x: "13.75", y: "5", width: "3.75", height: "14", rx: "1.2" })
@@ -100,20 +100,20 @@ function Nt({ checked: t, onChange: e, label: n, disabled: r }) {
100
100
  return /* @__PURE__ */ i("button", { type: "button", role: "switch", "aria-checked": t, "aria-label": n, className: "vs-toggle", disabled: r, onClick: () => e(!t), children: /* @__PURE__ */ i("span", { className: "vs-toggle__knob" }) });
101
101
  }
102
102
  function hr({ value: t, onChange: e, options: n, size: r, bordered: s = !0, fill: a }) {
103
- const o = v(null), [l, c] = I(null), u = Math.max(0, n.findIndex((d) => d.value === t));
103
+ const o = v(null), [l, c] = z(null), u = Math.max(0, n.findIndex((d) => d.value === t));
104
104
  return Bt(() => {
105
105
  const d = o.current;
106
106
  if (!d) return;
107
- const g = d.querySelectorAll(".vs-switch__opt")[u];
108
- g && c({ left: g.offsetLeft, width: g.offsetWidth });
107
+ const M = d.querySelectorAll(".vs-switch__opt")[u];
108
+ M && c({ left: M.offsetLeft, width: M.offsetWidth });
109
109
  }, [u, n.length]), U(() => {
110
110
  const d = o.current;
111
111
  if (!d || typeof ResizeObserver > "u") return;
112
- const g = new ResizeObserver(() => {
113
- const M = d.querySelectorAll(".vs-switch__opt")[u];
114
- M && c({ left: M.offsetLeft, width: M.offsetWidth });
112
+ const M = new ResizeObserver(() => {
113
+ const g = d.querySelectorAll(".vs-switch__opt")[u];
114
+ g && c({ left: g.offsetLeft, width: g.offsetWidth });
115
115
  });
116
- return g.observe(d), () => g.disconnect();
116
+ return M.observe(d), () => M.disconnect();
117
117
  }, [u]), /* @__PURE__ */ h("div", { ref: o, role: "tablist", className: `vs-switch${r === "sm" ? " vs-switch--sm" : ""}${s ? "" : " vs-switch--borderless"}${a ? " vs-switch--fill" : ""}`, children: [
118
118
  l && /* @__PURE__ */ i("span", { className: "vs-switch__thumb", style: { left: l.left, width: l.width }, "aria-hidden": "true" }),
119
119
  n.map((d) => /* @__PURE__ */ h("button", { type: "button", role: "tab", "aria-selected": d.value === t, className: "vs-switch__opt", onClick: () => e(d.value), children: [
@@ -136,7 +136,7 @@ function zn({ flag: t, code: e, label: n, onClick: r, variant: s, block: a, bord
136
136
  ] });
137
137
  }
138
138
  function za({ value: t, label: e = "Copy", onCopied: n }) {
139
- const [r, s] = I(!1), a = async () => {
139
+ const [r, s] = z(!1), a = async () => {
140
140
  try {
141
141
  await navigator.clipboard.writeText(t), s(!0), n == null || n(), setTimeout(() => s(!1), 1400);
142
142
  } catch {
@@ -178,34 +178,34 @@ function Ia(t, e) {
178
178
  }, [t, e]);
179
179
  }
180
180
  function Mr({ children: t, ms: e = 220 }) {
181
- const n = v(null), r = v(null), [s, a] = I(null);
181
+ const n = v(null), r = v(null), [s, a] = z(null);
182
182
  return Bt(() => {
183
183
  const o = r.current, l = n.current;
184
184
  if (!o || !l) return;
185
185
  let c;
186
186
  const u = () => {
187
- const M = l.closest(".vs-sheet"), N = M ? parseFloat(getComputedStyle(M).maxHeight) : NaN;
188
- return !M || !Number.isFinite(N) ? 1 / 0 : Math.max(0, N - (M.offsetHeight - l.offsetHeight));
187
+ const g = l.closest(".vs-sheet"), N = g ? parseFloat(getComputedStyle(g).maxHeight) : NaN;
188
+ return !g || !Number.isFinite(N) ? 1 / 0 : Math.max(0, N - (g.offsetHeight - l.offsetHeight));
189
189
  }, d = () => {
190
- const M = o.offsetHeight;
191
- clearTimeout(c), a(Math.min(M, u())), M > u() && (c = setTimeout(() => a(M), e));
190
+ const g = o.offsetHeight;
191
+ clearTimeout(c), a(Math.min(g, u())), g > u() && (c = setTimeout(() => a(g), e));
192
192
  };
193
193
  if (d(), typeof ResizeObserver > "u") return () => clearTimeout(c);
194
- const g = new ResizeObserver(d);
195
- return g.observe(o), () => {
196
- g.disconnect(), clearTimeout(c);
194
+ const M = new ResizeObserver(d);
195
+ return M.observe(o), () => {
196
+ M.disconnect(), clearTimeout(c);
197
197
  };
198
198
  }, [e]), /* @__PURE__ */ i("div", { ref: n, style: { height: s ?? void 0, overflow: "clip", transition: s == null ? void 0 : `height ${e}ms cubic-bezier(.32,.72,0,1)` }, children: /* @__PURE__ */ i("div", { ref: r, children: t }) });
199
199
  }
200
200
  function Vt({ open: t, onClose: e, title: n, titleNode: r, note: s, doneLabel: a = "Done", children: o, drawer: l = !1, header: c, kind: u, sticky: d = !1 }) {
201
- const g = v(null);
202
- return Ia(g, t), U(() => {
201
+ const M = v(null);
202
+ return Ia(M, t), U(() => {
203
203
  if (!t) return;
204
- const M = (N) => {
204
+ const g = (N) => {
205
205
  N.key === "Escape" && e();
206
206
  };
207
- return window.addEventListener("keydown", M), () => window.removeEventListener("keydown", M);
208
- }, [t, e]), t ? /* @__PURE__ */ i("div", { ref: g, className: `vs-sheet-scrim${l ? " drawer" : ""}${d ? " vs-sheet-scrim--sticky" : ""}`, onClick: d ? void 0 : e, children: /* @__PURE__ */ h("div", { className: `vs-sheet${u ? ` vs-sheet--${u}` : ""}`, role: "dialog", "aria-modal": "true", "aria-label": n, onClick: (M) => M.stopPropagation(), children: [
207
+ return window.addEventListener("keydown", g), () => window.removeEventListener("keydown", g);
208
+ }, [t, e]), t ? /* @__PURE__ */ i("div", { ref: M, className: `vs-sheet-scrim${l ? " drawer" : ""}${d ? " vs-sheet-scrim--sticky" : ""}`, onClick: d ? void 0 : e, children: /* @__PURE__ */ h("div", { className: `vs-sheet${u ? ` vs-sheet--${u}` : ""}`, role: "dialog", "aria-modal": "true", "aria-label": n, onClick: (g) => g.stopPropagation(), children: [
209
209
  /* @__PURE__ */ i("div", { className: "vs-sheet__grip" }),
210
210
  /* @__PURE__ */ h("div", { className: "vs-sheet__head", children: [
211
211
  r ?? /* @__PURE__ */ i("span", { className: "vs-sheet__title", children: n }),
@@ -697,16 +697,16 @@ const nt = class nt {
697
697
  let o = 0;
698
698
  if (a)
699
699
  if (this.within = null, r.total > 1) {
700
- const c = Array.from({ length: r.total }, (d, g) => {
701
- var M;
702
- return ((M = r.got.get(g)) == null ? void 0 : M.durationS) ?? 0;
703
- }), u = c.reduce((d, g) => d + g, 0);
700
+ const c = Array.from({ length: r.total }, (d, M) => {
701
+ var g;
702
+ return ((g = r.got.get(M)) == null ? void 0 : g.durationS) ?? 0;
703
+ }), u = c.reduce((d, M) => d + M, 0);
704
704
  if (u > 0 && c.every((d) => d > 0)) {
705
705
  const d = a.frac * u;
706
- let g = 0, M = 0;
707
- for (; g < c.length - 1 && M + c[g] <= d; ) M += c[g++];
708
- if (o = -(d - M), g !== n) {
709
- this.partBase = M, this.startPartAt(e, g, d - M);
706
+ let M = 0, g = 0;
707
+ for (; M < c.length - 1 && g + c[M] <= d; ) g += c[M++];
708
+ if (o = -(d - g), M !== n) {
709
+ this.partBase = g, this.startPartAt(e, M, d - g);
710
710
  return;
711
711
  }
712
712
  }
@@ -739,9 +739,9 @@ const nt = class nt {
739
739
  if (this.rank(c) <= l || !this.speakable(c)) continue;
740
740
  const u = this.clips.get(c);
741
741
  if (u)
742
- for (const d of [...u.got.keys()].sort((g, M) => g - M)) {
743
- const g = u.got.get(d);
744
- r.push(g), s += g.durationS || 0;
742
+ for (const d of [...u.got.keys()].sort((M, g) => M - g)) {
743
+ const M = u.got.get(d);
744
+ r.push(M), s += M.durationS || 0;
745
745
  }
746
746
  }
747
747
  return r;
@@ -881,19 +881,19 @@ function Ya(t, e, n, r = {}, s) {
881
881
  if (!(a != null && a.length)) return [];
882
882
  const o = Oa(r), l = o ? `&${o}` : "", c = t.voiceKey ? `&voice=${encodeURIComponent(t.voiceKey)}` : "";
883
883
  return a.flatMap((u) => {
884
- var M, N;
885
- const d = (M = t.clipRev) == null ? void 0 : M[String(u)], g = Math.max(1, ((N = t.clipParts) == null ? void 0 : N[String(u)]) ?? 1);
886
- return Array.from({ length: g }, (p, y) => {
884
+ var g, N;
885
+ const d = (g = t.clipRev) == null ? void 0 : g[String(u)], M = Math.max(1, ((N = t.clipParts) == null ? void 0 : N[String(u)]) ?? 1);
886
+ return Array.from({ length: M }, (p, y) => {
887
887
  var L;
888
888
  return {
889
889
  sentenceId: u,
890
890
  lang: t.lang,
891
891
  src: `${n}/v1/recordings/${e}/voice/${u}?lang=${encodeURIComponent(t.lang)}${c}&format=${xn()}${y > 0 ? `&part=${y}` : ""}${d ? `&v=${encodeURIComponent(d)}` : ""}${l}`,
892
- durationS: g === 1 ? ((L = t.clipDur) == null ? void 0 : L[String(u)]) ?? 0 : 0,
892
+ durationS: M === 1 ? ((L = t.clipDur) == null ? void 0 : L[String(u)]) ?? 0 : 0,
893
893
  voice: t.voice ?? null,
894
894
  cloned: !1,
895
895
  part: y,
896
- parts: g
896
+ parts: M
897
897
  };
898
898
  });
899
899
  });
@@ -933,7 +933,7 @@ function Mi(t, e) {
933
933
  for (const n of Nr) n();
934
934
  }
935
935
  function Ir(t, e) {
936
- const [n, r] = I(() => mr(t, e));
936
+ const [n, r] = z(() => mr(t, e));
937
937
  return U(() => {
938
938
  const s = () => r(mr(t, e));
939
939
  return Nr.add(s), window.addEventListener("storage", s), () => {
@@ -967,21 +967,21 @@ function Qa(t) {
967
967
  const [e, n] = Ir(t === "ga" ? "vs.colW.ga" : "vs.colW", null);
968
968
  return [typeof e == "number" && e > 0 ? e : t === "ga" ? 560 : Pa, n];
969
969
  }
970
- function Or({ open: t, onClose: e, value: n, onSelect: r, languages: s, searchPlaceholder: a = "Search languages", none: o, pinned: l = [], recent: c = [], requireVoice: u, keepOpen: d, busy: g }) {
971
- const [M, N] = I(""), [p, y] = I(!1), [L, m] = I(null);
970
+ function Or({ open: t, onClose: e, value: n, onSelect: r, languages: s, searchPlaceholder: a = "Search languages", none: o, pinned: l = [], recent: c = [], requireVoice: u, keepOpen: d, busy: M }) {
971
+ const [g, N] = z(""), [p, y] = z(!1), [L, m] = z(null);
972
972
  U(() => {
973
973
  t && (N(""), y(!1), m(null));
974
974
  }, [t]);
975
975
  const f = Ie(() => {
976
- const E = M.trim().toLowerCase();
976
+ const E = g.trim().toLowerCase();
977
977
  return [...E ? s.filter((O) => O.label.toLowerCase().includes(E) || O.native.toLowerCase().includes(E) || O.code.toLowerCase().includes(E)) : s].sort((O, S) => {
978
978
  const re = l.indexOf(O.code), K = l.indexOf(S.code);
979
979
  return re !== -1 || K !== -1 ? (re === -1 ? 999 : re) - (K === -1 ? 999 : K) : O.label.localeCompare(S.label);
980
980
  });
981
- }, [s, M, l]), z = Ie(
982
- () => M ? [] : c.map((E) => f.find((Q) => Q.code === E)).filter((E) => !!E).sort((E, Q) => E.label.localeCompare(Q.label)),
983
- [c, f, M]
984
- ), C = Ie(() => z.length ? f.filter((E) => !z.some((Q) => Q.code === E.code)) : f, [f, z]), D = p || M ? C : C.slice(0, 12), V = C.length - D.length, _ = (E, Q = !1) => {
981
+ }, [s, g, l]), I = Ie(
982
+ () => g ? [] : c.map((E) => f.find((Q) => Q.code === E)).filter((E) => !!E).sort((E, Q) => E.label.localeCompare(Q.label)),
983
+ [c, f, g]
984
+ ), C = Ie(() => I.length ? f.filter((E) => !I.some((Q) => Q.code === E.code)) : f, [f, I]), D = p || g ? C : C.slice(0, 12), V = C.length - D.length, _ = (E, Q = !1) => {
985
985
  const T = !!u && !E.voice;
986
986
  return /* @__PURE__ */ h(
987
987
  "button",
@@ -1008,16 +1008,16 @@ function Or({ open: t, onClose: e, value: n, onSelect: r, languages: s, searchPl
1008
1008
  (O.key === "Enter" || O.key === " ") && (O.preventDefault(), O.stopPropagation(), Ys(E.code));
1009
1009
  }, children: /* @__PURE__ */ i(oe, { d: X.close, size: 16 }) }) }),
1010
1010
  /* @__PURE__ */ i("span", { className: `vs-picker__slot${T ? " vs-picker__slot--wide" : ""}`, title: E.voice ? "Voice available" : T ? "No voice speaks this language yet" : void 0, children: T ? L === E.code && /* @__PURE__ */ i("span", { className: "vs-picker__off", children: "UNAVAILABLE" }) : E.voice && /* @__PURE__ */ i(oe, { d: X.headphones, size: 16 }) }),
1011
- /* @__PURE__ */ i("span", { className: "vs-picker__check", children: n === E.code && (g === E.code ? /* @__PURE__ */ i(at, { size: 15, color: "var(--vs-link-hover)", track: "var(--vs-border)" }) : /* @__PURE__ */ i(oe, { d: X.check, size: 16, sw: 2.2 })) })
1011
+ /* @__PURE__ */ i("span", { className: "vs-picker__check", children: n === E.code && (M === E.code ? /* @__PURE__ */ i(at, { size: 15, color: "var(--vs-link-hover)", track: "var(--vs-border)" }) : /* @__PURE__ */ i(oe, { d: X.check, size: 16, sw: 2.2 })) })
1012
1012
  ]
1013
1013
  },
1014
1014
  E.code
1015
1015
  );
1016
1016
  }, ee = /* @__PURE__ */ h("div", { className: "vs-picker__search", children: [
1017
1017
  /* @__PURE__ */ i(oe, { d: X.search, size: 16, sw: 1.7, style: { color: "var(--vs-text-muted)" } }),
1018
- /* @__PURE__ */ i("input", { value: M, onChange: (E) => N(E.target.value), placeholder: a, "aria-label": a })
1018
+ /* @__PURE__ */ i("input", { value: g, onChange: (E) => N(E.target.value), placeholder: a, "aria-label": a })
1019
1019
  ] }), j = /* @__PURE__ */ h("div", { className: "vs-picker__list", children: [
1020
- o && !M && /* @__PURE__ */ h("button", { type: "button", className: "vs-picker__row", "data-vs-original": "", "aria-selected": n === null, onClick: () => {
1020
+ o && !g && /* @__PURE__ */ h("button", { type: "button", className: "vs-picker__row", "data-vs-original": "", "aria-selected": n === null, onClick: () => {
1021
1021
  r(null), d || e();
1022
1022
  }, children: [
1023
1023
  /* @__PURE__ */ i("span", { className: "vs-picker__flag", children: /* @__PURE__ */ i(oe, { d: X.mic, size: 19, sw: 1.6, style: { color: "var(--vs-text-muted)" } }) }),
@@ -1029,9 +1029,9 @@ function Or({ open: t, onClose: e, value: n, onSelect: r, languages: s, searchPl
1029
1029
  /* @__PURE__ */ i("span", { className: "vs-picker__slot" }),
1030
1030
  /* @__PURE__ */ i("span", { className: "vs-picker__check", children: n === null && /* @__PURE__ */ i(oe, { d: X.check, size: 16, sw: 2.2 }) })
1031
1031
  ] }),
1032
- z.length > 0 && /* @__PURE__ */ h(xe, { children: [
1032
+ I.length > 0 && /* @__PURE__ */ h(xe, { children: [
1033
1033
  /* @__PURE__ */ i("div", { className: "vs-picker__head", children: "RECENT" }),
1034
- z.map((E) => _(E, !0)),
1034
+ I.map((E) => _(E, !0)),
1035
1035
  /* @__PURE__ */ i("div", { className: "vs-picker__rule" })
1036
1036
  ] }),
1037
1037
  D.map((E) => _(E)),
@@ -1042,7 +1042,7 @@ function Or({ open: t, onClose: e, value: n, onSelect: r, languages: s, searchPl
1042
1042
  ] }),
1043
1043
  f.length === 0 && /* @__PURE__ */ h("div", { className: "vs-picker__more", children: [
1044
1044
  "No match for “",
1045
- M,
1045
+ g,
1046
1046
  "”"
1047
1047
  ] })
1048
1048
  ] });
@@ -1119,22 +1119,22 @@ function rr(t) {
1119
1119
  t && (t.pause(), t.removeAttribute("src"), t.load());
1120
1120
  }
1121
1121
  function pi(t, e) {
1122
- const [n, r] = I("off"), [s, a] = I([]), [o, l] = I(!1), c = v(null), u = v([null, null]), d = v([NaN, NaN]), g = v(0);
1122
+ const [n, r] = z("off"), [s, a] = z([]), [o, l] = z(!1), c = v(null), u = v([null, null]), d = v([NaN, NaN]), M = v(0);
1123
1123
  return U(() => {
1124
1124
  if (a([]), l(!1), !t) {
1125
1125
  r("off");
1126
1126
  return;
1127
1127
  }
1128
- let M = !1, N;
1128
+ let g = !1, N;
1129
1129
  r("making");
1130
1130
  const p = () => {
1131
1131
  to(t).then((y) => {
1132
- if (!M) {
1132
+ if (!g) {
1133
1133
  if (y.ready) {
1134
1134
  const L = new Audio();
1135
1135
  L.preload = "auto";
1136
1136
  const m = () => {
1137
- !M && c.current === L && r("ready");
1137
+ !g && c.current === L && r("ready");
1138
1138
  };
1139
1139
  L.addEventListener("canplay", m, { once: !0 }), L.addEventListener("error", m, { once: !0 }), L.src = t, c.current = L;
1140
1140
  return;
@@ -1146,31 +1146,31 @@ function pi(t, e) {
1146
1146
  a((L) => L.length === y.parts.length && L.every((m, f) => m.startS === y.parts[f].startS) ? L : y.parts), N = setTimeout(p, y.retryS * 1e3);
1147
1147
  }
1148
1148
  }).catch(() => {
1149
- M || (N = setTimeout(p, 5e3));
1149
+ g || (N = setTimeout(p, 5e3));
1150
1150
  });
1151
1151
  };
1152
1152
  return p(), () => {
1153
- M = !0, N && clearTimeout(N), rr(c.current), c.current = null, rr(u.current[0]), rr(u.current[1]), u.current = [null, null], d.current = [NaN, NaN];
1153
+ g = !0, N && clearTimeout(N), rr(c.current), c.current = null, rr(u.current[0]), rr(u.current[1]), u.current = [null, null], d.current = [NaN, NaN];
1154
1154
  };
1155
1155
  }, [t]), U(() => {
1156
- const M = () => {
1156
+ const g = () => {
1157
1157
  for (const m of u.current) m && !m.paused && m.pause();
1158
1158
  };
1159
1159
  if (n === "ready" && c.current) {
1160
- M(), Us(c.current, e), l(!0);
1160
+ g(), Us(c.current, e), l(!0);
1161
1161
  return;
1162
1162
  }
1163
1163
  const N = n === "making" ? Xa(s, e.t) : -1;
1164
1164
  if (N < 0) {
1165
- M(), l(!1);
1165
+ g(), l(!1);
1166
1166
  return;
1167
1167
  }
1168
- const p = eo(s, N, d.current, g.current);
1168
+ const p = eo(s, N, d.current, M.current);
1169
1169
  for (const [m, f] of p.load) {
1170
- let z = u.current[m];
1171
- z || (z = new Audio(), z.preload = "auto", u.current[m] = z), z.pause(), z.src = s[f].url, d.current[m] = s[f].startS;
1170
+ let I = u.current[m];
1171
+ I || (I = new Audio(), I.preload = "auto", u.current[m] = I), I.pause(), I.src = s[f].url, d.current[m] = s[f].startS;
1172
1172
  }
1173
- g.current = p.play;
1173
+ M.current = p.play;
1174
1174
  const y = u.current[p.play], L = u.current[1 - p.play];
1175
1175
  L && !L.paused && L.pause(), Us(y, { ...e, t: e.t - s[N].startS }), l(!e.playing || y.readyState >= 3);
1176
1176
  }, [n, s, e.t, e.playing, e.muted]), { state: n, on: o, untilS: n === "ready" ? 1 / 0 : s.length ? s[s.length - 1].endS : 0 };
@@ -1194,7 +1194,7 @@ function io(t, e, n) {
1194
1194
  const o = Math.max(1, ...a.map((c) => c.parts));
1195
1195
  let l = Math.max(0, n - s.start);
1196
1196
  for (let c = 0; c < o; c++) {
1197
- const u = a.find((g) => g.part === c);
1197
+ const u = a.find((M) => M.part === c);
1198
1198
  if (!u) return { kind: "missing", sid: s.sid };
1199
1199
  const d = u.durationS && u.durationS > 0 ? u.durationS : 1 / 0;
1200
1200
  if (l < d) return { kind: "play", sid: s.sid, src: u.src, offset: l };
@@ -1222,7 +1222,7 @@ function lo(t) {
1222
1222
  const c = /* @__PURE__ */ new Map();
1223
1223
  for (const u of t.clips) c.set(u.sentenceId, [...c.get(u.sentenceId) ?? [], u]);
1224
1224
  return c;
1225
- }, [t.clips]), n = v(/* @__PURE__ */ new Map()), r = v(null), [s, a] = I({ missing: null, sid: null }), o = (c) => {
1225
+ }, [t.clips]), n = v(/* @__PURE__ */ new Map()), r = v(null), [s, a] = z({ missing: null, sid: null }), o = (c) => {
1226
1226
  let u = n.current.get(c);
1227
1227
  return u || (u = new Audio(), u.preload = "auto", u.src = c, n.current.set(c, u)), u;
1228
1228
  }, l = () => {
@@ -1240,31 +1240,31 @@ function lo(t) {
1240
1240
  }
1241
1241
  const c = io(t.lines, e, t.t), u = c.kind === "missing" ? c.sid : null, d = c.kind === "none" ? null : c.sid;
1242
1242
  a((p) => p.missing === u && p.sid === d ? p : { missing: u, sid: d });
1243
- const g = new Set(oo(t.lines, e, t.t));
1244
- for (const p of g) o(p);
1245
- const M = r.current;
1246
- M && g.add(M.src);
1247
- for (const [p, y] of n.current) !g.has(p) && (!M || M.el !== y) && (y.pause(), n.current.delete(p));
1243
+ const M = new Set(oo(t.lines, e, t.t));
1244
+ for (const p of M) o(p);
1245
+ const g = r.current;
1246
+ g && M.add(g.src);
1247
+ for (const [p, y] of n.current) !M.has(p) && (!g || g.el !== y) && (y.pause(), n.current.delete(p));
1248
1248
  if (!t.playing) {
1249
- M == null || M.el.pause();
1249
+ g == null || g.el.pause();
1250
1250
  return;
1251
1251
  }
1252
1252
  if (c.kind !== "play") {
1253
- if (M && !M.el.paused && !M.el.ended && ao(t.lines, t.t, M.sid)) return;
1254
- M && M.el.pause(), r.current = null;
1253
+ if (g && !g.el.paused && !g.el.ended && ao(t.lines, t.t, g.sid)) return;
1254
+ g && g.el.pause(), r.current = null;
1255
1255
  return;
1256
1256
  }
1257
- if (M && M.src === c.src) {
1258
- if (M.el.muted = t.muted, !M.el.ended && Math.abs(M.el.currentTime - c.offset) > ro)
1257
+ if (g && g.src === c.src) {
1258
+ if (g.el.muted = t.muted, !g.el.ended && Math.abs(g.el.currentTime - c.offset) > ro)
1259
1259
  try {
1260
- M.el.currentTime = c.offset;
1260
+ g.el.currentTime = c.offset;
1261
1261
  } catch {
1262
1262
  }
1263
- M.el.paused && !M.el.ended && M.el.play().catch(() => {
1263
+ g.el.paused && !g.el.ended && g.el.play().catch(() => {
1264
1264
  });
1265
1265
  return;
1266
1266
  }
1267
- M == null || M.el.pause();
1267
+ g == null || g.el.pause();
1268
1268
  const N = o(c.src);
1269
1269
  N.muted = t.muted;
1270
1270
  try {
@@ -1497,7 +1497,7 @@ function fo(t, e) {
1497
1497
  if ((n = e.scriptWords) != null && n.length) {
1498
1498
  const a = (c) => c.toLowerCase().replace(/[^\p{L}\p{N}]/gu, ""), o = (e.fixes ?? []).filter((c) => String(c.kind ?? "").endsWith("script") && String(c.orig ?? "").trim()), l = (c) => {
1499
1499
  var u, d;
1500
- return c.recognized ?? ((d = (u = o.find((g) => String(g.repl ?? "").split(/\s+/).map(a).includes(a(c.text)))) == null ? void 0 : u.orig) == null ? void 0 : d.trim());
1500
+ return c.recognized ?? ((d = (u = o.find((M) => String(M.repl ?? "").split(/\s+/).map(a).includes(a(c.text)))) == null ? void 0 : u.orig) == null ? void 0 : d.trim());
1501
1501
  };
1502
1502
  r.words = r.words.map((c, u) => {
1503
1503
  if (!e.scriptWords.includes(u)) return c;
@@ -1627,7 +1627,7 @@ const Tn = ["a", "b", "c", "d", "e", "f", "g", "h"];
1627
1627
  function Lo(t) {
1628
1628
  return Tn[(t % Tn.length + Tn.length) % Tn.length];
1629
1629
  }
1630
- function ko(t) {
1630
+ function vo(t) {
1631
1631
  if (t.numbers) return t.numbers;
1632
1632
  const e = /* @__PURE__ */ new Map(), n = (a, o) => {
1633
1633
  if (a < 0) return;
@@ -1643,12 +1643,12 @@ function ko(t) {
1643
1643
  }
1644
1644
  function On(t, e) {
1645
1645
  if (e < 0) return 0;
1646
- const n = ko(t);
1646
+ const n = vo(t);
1647
1647
  return n.get(e) ?? n.size + 1 + e;
1648
1648
  }
1649
- const vo = /^\s*speaker\s+\d+\s*$/i;
1649
+ const ko = /^\s*speaker\s+\d+\s*$/i;
1650
1650
  function Qs(t) {
1651
- return t && t.trim() && !vo.test(t) ? t : void 0;
1651
+ return t && t.trim() && !ko.test(t) ? t : void 0;
1652
1652
  }
1653
1653
  function Ni(t, e) {
1654
1654
  var n;
@@ -1786,22 +1786,22 @@ async function So(t, e) {
1786
1786
  };
1787
1787
  }
1788
1788
  function Ao(t, e) {
1789
- const [n, r] = I(null), [s, a] = I(!1), [o, l] = I(null), [c, u] = I(0);
1789
+ const [n, r] = z(null), [s, a] = z(!1), [o, l] = z(null), [c, u] = z(0);
1790
1790
  return U(() => {
1791
1791
  let d = !0;
1792
- return So(t, e).then((g) => {
1793
- d && (r(g), a(!1), l(null));
1794
- }).catch((g) => {
1792
+ return So(t, e).then((M) => {
1793
+ d && (r(M), a(!1), l(null));
1794
+ }).catch((M) => {
1795
1795
  if (!d) return;
1796
- const M = Tt(g);
1797
- M.code === "not_found" || M.status === 404 ? a(!0) : l(M);
1796
+ const g = Tt(M);
1797
+ g.code === "not_found" || g.status === 404 ? a(!0) : l(g);
1798
1798
  }), () => {
1799
1799
  d = !1;
1800
1800
  };
1801
1801
  }, [t, e, c]), { source: n, gone: s, error: o, reload: () => u((d) => d + 1) };
1802
1802
  }
1803
1803
  function Eo(t, e) {
1804
- const [n, r] = I(null);
1804
+ const [n, r] = z(null);
1805
1805
  return U(() => {
1806
1806
  if (!t.owner || !e) {
1807
1807
  r(null);
@@ -1835,7 +1835,7 @@ async function Bs(t, e, n = {}) {
1835
1835
  }
1836
1836
  const ar = /* @__PURE__ */ new Map();
1837
1837
  function Li() {
1838
- const t = Et(), [e, n] = I(ar.get(t.origin) ?? null);
1838
+ const t = Et(), [e, n] = z(ar.get(t.origin) ?? null);
1839
1839
  return U(() => {
1840
1840
  ar.has(t.origin) || t.client.languages.list().then((r) => {
1841
1841
  ar.set(t.origin, r), n(r);
@@ -1843,8 +1843,8 @@ function Li() {
1843
1843
  });
1844
1844
  }, [t]), e;
1845
1845
  }
1846
- function ki(t, e) {
1847
- const [n, r] = I(null), [s, a] = I(null), [o, l] = I(0);
1846
+ function vi(t, e) {
1847
+ const [n, r] = z(null), [s, a] = z(null), [o, l] = z(0);
1848
1848
  return U(() => {
1849
1849
  let c = !0;
1850
1850
  return t().then((u) => c && r(u)).catch((u) => c && a(Tt(u))), () => {
@@ -1856,7 +1856,7 @@ const _o = (t) => new Promise((e) => setTimeout(e, t)), Yo = 2500, Uo = 72;
1856
1856
  function Ro(t, e) {
1857
1857
  const n = Et(), r = v(n);
1858
1858
  r.current = n;
1859
- const [s, a] = I($t), o = v($t()), l = v(null), c = v(e.lang ?? null), [u, d] = I(!1), [g, M] = I(null), [N, p] = I(!1), y = Ke(() => {
1859
+ const [s, a] = z($t), o = v($t()), l = v(null), c = v(e.lang ?? null), [u, d] = z(!1), [M, g] = z(null), [N, p] = z(!1), y = Ke(() => {
1860
1860
  const Q = o.current;
1861
1861
  a({ ...Q });
1862
1862
  }, []), L = v(e);
@@ -1881,7 +1881,7 @@ function Ro(t, e) {
1881
1881
  G.close();
1882
1882
  return;
1883
1883
  }
1884
- T = 0, l.current = G, c.current !== pe && G.setLanguage(c.current), d(!0), M(null), o.current = sr(G.snapshot, o.current), y(), re();
1884
+ T = 0, l.current = G, c.current !== pe && G.setLanguage(c.current), d(!0), g(null), o.current = sr(G.snapshot, o.current), y(), re();
1885
1885
  for await (const le of G) {
1886
1886
  if (!Q) break;
1887
1887
  if (le.type === "snapshot")
@@ -1896,7 +1896,7 @@ function Ro(t, e) {
1896
1896
  if (!Q) return;
1897
1897
  const le = Tt(pe);
1898
1898
  if (le.code === "not_found" || le.status === 404) {
1899
- p(!0), M(le);
1899
+ p(!0), g(le);
1900
1900
  return;
1901
1901
  }
1902
1902
  try {
@@ -1904,19 +1904,19 @@ function Ro(t, e) {
1904
1904
  } catch (Te) {
1905
1905
  const je = Tt(Te);
1906
1906
  if (je.code === "not_found" || je.status === 404) {
1907
- p(!0), M(je);
1907
+ p(!0), g(je);
1908
1908
  return;
1909
1909
  }
1910
1910
  if (je.code === "forbidden" || je.code === "invalid_token" || je.code === "password_required" || je.status === 401 || je.status === 403) {
1911
- M(je);
1911
+ g(je);
1912
1912
  return;
1913
1913
  }
1914
1914
  }
1915
1915
  if (le.code === "forbidden" || le.code === "invalid_token" || le.code === "password_required" || le.status === 401 || le.status === 403) {
1916
- M(le);
1916
+ g(le);
1917
1917
  return;
1918
1918
  }
1919
- M(le);
1919
+ g(le);
1920
1920
  } finally {
1921
1921
  l.current === G && (l.current = null), d(!1);
1922
1922
  }
@@ -1929,7 +1929,7 @@ function Ro(t, e) {
1929
1929
  Q = !1, (K = l.current) == null || K.close(), l.current = null, d(!1);
1930
1930
  };
1931
1931
  }, [t, n, e.voice]);
1932
- const [m, f] = I(!1), [z, C] = I(null), D = v(0), [V, _] = I(null), ee = Ke((Q) => {
1932
+ const [m, f] = z(!1), [I, C] = z(null), D = v(0), [V, _] = z(null), ee = Ke((Q) => {
1933
1933
  var re;
1934
1934
  if (c.current = Q, (re = l.current) == null || re.setLanguage(Q), !t) return;
1935
1935
  const T = r.current.client, O = ++D.current;
@@ -1953,8 +1953,8 @@ function Ro(t, e) {
1953
1953
  k && (k.translations = { ...k.translations, [Q]: K }, S = !0);
1954
1954
  }
1955
1955
  S && y();
1956
- }, [y]), E = Ke(() => M(null), []);
1957
- return { model: s, connected: u, error: g, notFound: N, clearError: E, setLanguage: ee, mergeTranslations: j, translating: m, translateFailed: z, shownLang: V };
1956
+ }, [y]), E = Ke(() => g(null), []);
1957
+ return { model: s, connected: u, error: M, notFound: N, clearError: E, setLanguage: ee, mergeTranslations: j, translating: m, translateFailed: I, shownLang: V };
1958
1958
  }
1959
1959
  const Vs = {
1960
1960
  English: { vcFor: "Voice for", vcMute: "Mute", vcUnmute: "Unmute", vcMuted: "MUTED", vcShared: "Also used by", vcUsedBy: "Used by", vcUnknownSpk: "Unknown", vcUse: "Use this voice", vcGetting: "Downloading…", vcSample: "Here’s how it sounds.", vcPreview: "PREVIEW", vcMale: "Male", vcFemale: "Female", vcSynth: "SYNTHETIC", origAudio: "ORIGINAL AUDIO", vcCloned: "VOICES", vcBadge: "CLONED", vcNone: "TEXT ONLY", vcNoVoice: "No voice for ", vcSheet: "VOICE", vcNeutral: "SYNTHETIC VOICE", vcWarm: "SYNTHETIC VOICE", searchPlaceholder: "Search this broadcast", noise: "Audio unclear", newLines: "new", live: "LIVE", ended: "ENDED", waiting: "WAITING", corrected: "CORRECTED", hostLine: "Hosted by Marcus Reed · 4 speakers", langLabel: "LANGUAGE", langCount: "100+ languages", read: "Read", listen: "Listen", watch: "Watch", waitTitle: "The broadcast hasn’t started yet", waitBody: "The transcript appears here as soon as the host starts speaking.", english: "ENGLISH", playing: "Playing the live audio", ready: "Tap to start audio", readyNote: "Set your volume first", voiceMeta: "ORIGINAL AUDIO", voice: "Voice", sheetTitle: "APP LANGUAGE", done: "Done", search: "Search 100+ languages", sheetNote: "Follow along in your language.", moreLangs: "more", confTitle: "Some words weren't heard clearly", confBody: "The transcript marks words the model is unsure about with a dashed underline. The words keep their colour, so only the underline tells you where to look.", confMid: "Slightly unsure — probably right", confHigh: "Low confidence — may be wrong", settings: "BROADCAST", setOrig: "Show original language", setTheme: "Appearance", light: "Light", dark: "Dark", setConf: "Show uncertain words", setConfHint1: "Colours words the model is unsure about — ", setConfMid: "amber", setConfSep: " or ", setConfLow: "red", setConfHint2: "", behindLive: "TRANSLATION LATENCY", behindNote: "How far the translation trails the speaker right now.", shareLabel: "LIVE TRANSLATION LINK", copy: "Copy", copied: "Copied" },
@@ -1964,7 +1964,7 @@ const Vs = {
1964
1964
  Romanian: { vcFor: "Vocea pentru", vcMute: "Oprește", vcUnmute: "Pornește", vcMuted: "OPRIT", vcShared: "Folosită și de", vcUsedBy: "Folosită de", vcUnknownSpk: "Necunoscut", vcUse: "Folosește această voce", vcGetting: "Se descarcă…", vcSample: "Așa sună această voce.", vcPreview: "MOSTRĂ", vcMale: "Bărbat", vcFemale: "Femeie", vcSynth: "SINTETICĂ", origAudio: "AUDIO ORIGINAL", vcCloned: "VOCI", vcBadge: "CLONATĂ", vcNone: "DOAR TEXT", vcNoVoice: "Nicio voce pentru ", vcSheet: "VOCE", vcNeutral: "VOCE SINTETICĂ", vcWarm: "VOCE SINTETICĂ", searchPlaceholder: "Caută în transmisiune", noise: "Sunet neclar", newLines: "noi", live: "ÎN DIRECT", ended: "ÎNCHEIAT", waiting: "ÎN AȘTEPTARE", corrected: "CORECTAT", hostLine: "Prezentat de Marcus Reed · 4 vorbitori", langLabel: "LIMBĂ", langCount: "100+ de limbi", read: "Citește", listen: "Ascultă", watch: "Vizionează", waitTitle: "Transmisiunea nu a început încă", waitBody: "Transcrierea va apărea aici imediat ce gazda începe să vorbească.", english: "ENGLEZĂ", playing: "Se redă traducerea în română", ready: "Atinge pentru a porni audio", readyNote: "Reglează întâi volumul", voiceMeta: "VOCE NEUTRĂ", voice: "Voce", sheetTitle: "LIMBA APLICAȚIEI", done: "Gata", search: "Caută printre 100+ de limbi", sheetNote: "Urmărește transmisiunea în limba ta.", moreLangs: "în plus", confTitle: "Unele cuvinte nu s-au auzit clar", confBody: "Transcrierea marchează cuvintele incerte cu o subliniere întreruptă. Cuvintele își păstrează culoarea, doar sublinierea îți arată unde să te uiți.", confMid: "Ușoară nesiguranță — probabil corect", confHigh: "Încredere scăzută — poate fi greșit", settings: "TRANSMISIUNE", setOrig: "Arată limba originală", setTheme: "Aspect", light: "Luminos", dark: "Întunecat", setConf: "Arată cuvintele incerte", setConfHint1: "Colorează cuvintele incerte — ", setConfMid: "galben", setConfSep: " sau ", setConfLow: "roșu", setConfHint2: "", behindLive: "LATENȚA TRADUCERII", behindNote: "Cu cât urmează traducerea vorbitorul în acest moment.", shareLabel: "LINK DE URMĂRIRE", copy: "Copiază", copied: "Copiat" },
1965
1965
  Portuguese: { vcFor: "Voz de", vcMute: "Silenciar", vcUnmute: "Ativar", vcMuted: "SILENCIADO", vcShared: "Também usada por", vcUsedBy: "Usada por", vcUnknownSpk: "Desconhecido", vcUse: "Usar esta voz", vcGetting: "Baixando…", vcSample: "É assim que soa.", vcPreview: "AMOSTRA", vcMale: "Homem", vcFemale: "Mulher", vcSynth: "SINTÉTICA", origAudio: "ÁUDIO ORIGINAL", vcCloned: "VOZES", vcBadge: "CLONADA", vcNone: "SÓ TEXTO", vcNoVoice: "Sem voz para ", vcSheet: "VOZ", vcNeutral: "VOZ SINTÉTICA", vcWarm: "VOZ SINTÉTICA", searchPlaceholder: "Pesquisar nesta transmissão", noise: "Áudio pouco claro", newLines: "novas", live: "AO VIVO", ended: "ENCERRADA", waiting: "AGUARDANDO", corrected: "CORRIGIDO", hostLine: "Apresentado por Marcus Reed · 4 falantes", langLabel: "IDIOMA", langCount: "100+ idiomas", read: "Ler", listen: "Ouvir", watch: "Assistir", waitTitle: "A transmissão ainda não começou", waitBody: "A transcrição aparece aqui assim que o apresentador começar a falar.", english: "INGLÊS", playing: "Reproduzindo a tradução em português", ready: "Toque para iniciar o áudio", readyNote: "Ajuste o volume primeiro", voiceMeta: "VOZ NEUTRA", voice: "Voz", sheetTitle: "IDIOMA DO APP", done: "Concluído", search: "Pesquisar entre 100+ idiomas", sheetNote: "Acompanhe a transmissão no seu idioma.", moreLangs: "mais", confTitle: "Algumas palavras não foram bem ouvidas", confBody: "A transcrição marca as palavras duvidosas com um sublinhado tracejado. As palavras mantêm a sua cor, por isso só o sublinhado indica onde olhar.", confMid: "Pouca dúvida — provavelmente certa", confHigh: "Baixa confiança — pode estar errada", settings: "TRANSMISSÃO", setOrig: "Mostrar idioma original", setTheme: "Aparência", light: "Claro", dark: "Escuro", setConf: "Mostrar palavras duvidosas", setConfHint1: "Colore as palavras duvidosas: ", setConfMid: "âmbar", setConfSep: " ou ", setConfLow: "vermelho", setConfHint2: "", behindLive: "LATÊNCIA DE TRADUÇÃO", behindNote: "Quanto a tradução está atrás de quem fala agora.", shareLabel: "LINK PARA ACOMPANHAR", copy: "Copiar", copied: "Copiado" }
1966
1966
  };
1967
- function vi(t) {
1967
+ function ki(t) {
1968
1968
  return t && Vs[t] || Vs.English;
1969
1969
  }
1970
1970
  async function ji(t) {
@@ -2020,14 +2020,14 @@ async function Bo(t) {
2020
2020
  Sr(t);
2021
2021
  }
2022
2022
  async function Vo(t, e, n, r = {}) {
2023
- var M, N;
2023
+ var g, N;
2024
2024
  const s = await t.client.recordings.export(e, n, { lang: r.lang ?? void 0, ...t.readAs });
2025
2025
  if (!s.ok) throw await ji(s);
2026
- const a = await s.blob(), o = s.headers.get("content-disposition") ?? "", l = (M = /filename\*=UTF-8''([^;]+)/i.exec(o)) == null ? void 0 : M[1], c = (N = /filename="([^"]+)"/i.exec(o)) == null ? void 0 : N[1], u = l ? decodeURIComponent(l) : c ?? `transcript.${n}`, d = URL.createObjectURL(a), g = document.createElement("a");
2027
- g.href = d, g.download = u, g.style.display = "none", document.body.appendChild(g), g.click(), g.remove(), window.setTimeout(() => URL.revokeObjectURL(d), 6e4);
2026
+ const a = await s.blob(), o = s.headers.get("content-disposition") ?? "", l = (g = /filename\*=UTF-8''([^;]+)/i.exec(o)) == null ? void 0 : g[1], c = (N = /filename="([^"]+)"/i.exec(o)) == null ? void 0 : N[1], u = l ? decodeURIComponent(l) : c ?? `transcript.${n}`, d = URL.createObjectURL(a), M = document.createElement("a");
2027
+ M.href = d, M.download = u, M.style.display = "none", document.body.appendChild(M), M.click(), M.remove(), window.setTimeout(() => URL.revokeObjectURL(d), 6e4);
2028
2028
  }
2029
2029
  async function Ho(t, e) {
2030
- const { recordingId: n, lang: r, voiceKey: s, cred: a } = e, o = async () => (await t.client.recordings.voice(n, r, t.readAs)).filter((g) => g.lang === r), l = (d) => di(d, s);
2030
+ const { recordingId: n, lang: r, voiceKey: s, cred: a } = e, o = async () => (await t.client.recordings.voice(n, r, t.readAs)).filter((M) => M.lang === r), l = (d) => di(d, s);
2031
2031
  let c = l(await o());
2032
2032
  (!c || c.state === "clips" || c.state === "failed") && await e.request();
2033
2033
  const u = Date.now() + (e.timeoutMs ?? 10 * 6e4);
@@ -2089,7 +2089,7 @@ function qo(t, e, n = 0) {
2089
2089
  const _ = o(), ee = _ ? _.offsetHeight : 0, j = s.clientHeight - ee - 36, E = s.scrollHeight - s.clientHeight, Q = j > 0 ? Math.max(30, Math.round(j * (s.clientHeight - ee) / s.scrollHeight)) : 0;
2090
2090
  return { vis: j, max: E, size: Q };
2091
2091
  };
2092
- let c = -1, u = null, d = !1, g = 0, M = 0;
2092
+ let c = -1, u = null, d = !1, M = 0, g = 0;
2093
2093
  const N = () => {
2094
2094
  const _ = o();
2095
2095
  if (!_) return;
@@ -2116,19 +2116,19 @@ function qo(t, e, n = 0) {
2116
2116
  a.style.pointerEvents = "auto", a.style.height = j.size + "px", a.style.transform = "translateY(" + Math.round(s.scrollTop / j.max * (j.vis - j.size)) + "px)", _ && p();
2117
2117
  }, f = parseFloat(getComputedStyle(s).paddingRight) || 0;
2118
2118
  a.style.right = (f >= 12 ? -(f - 6) : 2) + "px";
2119
- const z = () => m(!0), C = (_) => {
2119
+ const I = () => m(!0), C = (_) => {
2120
2120
  const ee = l();
2121
- ee.vis - ee.size <= 0 || (_.preventDefault(), _.stopPropagation(), a.setPointerCapture(_.pointerId), d = !0, g = _.clientY, M = s.scrollTop, a.style.cursor = "grabbing", p());
2121
+ ee.vis - ee.size <= 0 || (_.preventDefault(), _.stopPropagation(), a.setPointerCapture(_.pointerId), d = !0, M = _.clientY, g = s.scrollTop, a.style.cursor = "grabbing", p());
2122
2122
  }, D = (_) => {
2123
2123
  if (!d) return;
2124
2124
  const ee = l();
2125
- s.scrollTop = M + (_.clientY - g) / (ee.vis - ee.size) * ee.max, p();
2125
+ s.scrollTop = g + (_.clientY - M) / (ee.vis - ee.size) * ee.max, p();
2126
2126
  }, V = () => {
2127
2127
  d && (d = !1, a.style.cursor = "grab", p());
2128
2128
  };
2129
- return s.addEventListener("scroll", z, { passive: !0 }), a.addEventListener("pointerdown", C), a.addEventListener("pointermove", D), a.addEventListener("pointerup", V), a.addEventListener("pointercancel", V), typeof ResizeObserver < "u" && (y = new ResizeObserver(() => m()), y.observe(s)), r.current = () => m(), m(), () => {
2129
+ return s.addEventListener("scroll", I, { passive: !0 }), a.addEventListener("pointerdown", C), a.addEventListener("pointermove", D), a.addEventListener("pointerup", V), a.addEventListener("pointercancel", V), typeof ResizeObserver < "u" && (y = new ResizeObserver(() => m()), y.observe(s)), r.current = () => m(), m(), () => {
2130
2130
  r.current = () => {
2131
- }, s.removeEventListener("scroll", z), a.removeEventListener("pointerdown", C), a.removeEventListener("pointermove", D), a.removeEventListener("pointerup", V), a.removeEventListener("pointercancel", V), y == null || y.disconnect(), clearTimeout(u);
2131
+ }, s.removeEventListener("scroll", I), a.removeEventListener("pointerdown", C), a.removeEventListener("pointermove", D), a.removeEventListener("pointerup", V), a.removeEventListener("pointercancel", V), y == null || y.disconnect(), clearTimeout(u);
2132
2132
  };
2133
2133
  }, []);
2134
2134
  }
@@ -2176,9 +2176,9 @@ function Zc({ chip: t, note: e, scrub: n, mute: r, voice: s, prev: a, play: o, n
2176
2176
  ] });
2177
2177
  }
2178
2178
  function Xo({ index: t, total: e, atLabel: n, durLabel: r, stepLabel: s, onSeek: a, onSeekFrac: o, onScrubStart: l, onScrubEnd: c, frac: u, glideMs: d = 260 }) {
2179
- const g = v(null), M = v(!1), [N, p] = I(null), y = Math.max(1, e), L = N ?? u, m = L != null ? Math.min(100, Math.max(0, L * 100)) : t / Math.max(1, y - 1) * 100, f = u != null && d > 0 && N == null ? `width ${d}ms linear, left ${d}ms linear` : "none", z = (D) => {
2179
+ const M = v(null), g = v(!1), [N, p] = z(null), y = Math.max(1, e), L = N ?? u, m = L != null ? Math.min(100, Math.max(0, L * 100)) : t / Math.max(1, y - 1) * 100, f = u != null && d > 0 && N == null ? `width ${d}ms linear, left ${d}ms linear` : "none", I = (D) => {
2180
2180
  var j;
2181
- const V = (j = g.current) == null ? void 0 : j.getBoundingClientRect();
2181
+ const V = (j = M.current) == null ? void 0 : j.getBoundingClientRect();
2182
2182
  if (!V) return;
2183
2183
  const _ = Math.min(1, Math.max(0, (D.clientX - V.left) / Math.max(1, V.width)));
2184
2184
  if (o) {
@@ -2188,20 +2188,20 @@ function Xo({ index: t, total: e, atLabel: n, durLabel: r, stepLabel: s, onSeek:
2188
2188
  const ee = Math.round(_ * (y - 1));
2189
2189
  ee !== t && a(ee);
2190
2190
  }, C = () => {
2191
- M.current && (M.current = !1, p(null), c == null || c());
2191
+ g.current && (g.current = !1, p(null), c == null || c());
2192
2192
  };
2193
2193
  return /* @__PURE__ */ h("div", { className: "rscrub", children: [
2194
2194
  /* @__PURE__ */ h(
2195
2195
  "div",
2196
2196
  {
2197
- ref: g,
2197
+ ref: M,
2198
2198
  className: "rscrub__track",
2199
2199
  onPointerDown: (D) => {
2200
2200
  var V;
2201
- M.current = !0, (V = g.current) == null || V.setPointerCapture(D.pointerId), l == null || l(), z(D), D.preventDefault();
2201
+ g.current = !0, (V = M.current) == null || V.setPointerCapture(D.pointerId), l == null || l(), I(D), D.preventDefault();
2202
2202
  },
2203
2203
  onPointerMove: (D) => {
2204
- M.current && z(D);
2204
+ g.current && I(D);
2205
2205
  },
2206
2206
  onPointerUp: C,
2207
2207
  onPointerCancel: C,
@@ -2241,7 +2241,7 @@ function tl({ f: t, desk: e, onOpen: n }) {
2241
2241
  ] });
2242
2242
  }
2243
2243
  function nl({ onOpen: t, alone: e }) {
2244
- const [n, r] = I(!1);
2244
+ const [n, r] = z(!1);
2245
2245
  return /* @__PURE__ */ h("span", { role: "button", title: "Fix this line", className: `badge badge--pen${n ? " is-over" : ""}`, style: { marginLeft: e ? "auto" : 0 }, onMouseEnter: () => r(!0), onMouseLeave: () => r(!1), onClick: (s) => {
2246
2246
  s.stopPropagation(), t();
2247
2247
  }, children: [
@@ -2250,15 +2250,15 @@ function nl({ onOpen: t, alone: e }) {
2250
2250
  ] });
2251
2251
  }
2252
2252
  function rl(t, e, n, r) {
2253
- const s = Et(), [a, o] = I([]), [l, c] = I(0), u = v(/* @__PURE__ */ new Set()), d = v(!1), g = Ie(() => new Map(n.filter((N) => N.sentenceId != null).map((N) => [N.sentenceId, N])), [n]);
2253
+ const s = Et(), [a, o] = z([]), [l, c] = z(0), u = v(/* @__PURE__ */ new Set()), d = v(!1), M = Ie(() => new Map(n.filter((N) => N.sentenceId != null).map((N) => [N.sentenceId, N])), [n]);
2254
2254
  U(() => {
2255
2255
  u.current = /* @__PURE__ */ new Set();
2256
2256
  }, [t, e]);
2257
- const M = Ke((N) => o(N), []);
2257
+ const g = Ke((N) => o(N), []);
2258
2258
  return U(() => {
2259
2259
  if (!t || !e || !a.length || d.current) return;
2260
2260
  const N = a.filter((p) => {
2261
- const y = g.get(p);
2261
+ const y = M.get(p);
2262
2262
  return !y || !y.text.trim() || !y.settled || y.translations[e] || y.language && y.language.slice(0, 2).toLowerCase() === e.slice(0, 2).toLowerCase() ? !1 : !u.current.has(`${e}:${p}`);
2263
2263
  }).slice(0, 40);
2264
2264
  if (N.length) {
@@ -2274,7 +2274,7 @@ function rl(t, e, n, r) {
2274
2274
  d.current = !1, c((p) => p + 1);
2275
2275
  });
2276
2276
  }
2277
- }, [t, e, a, l, g, r]), M;
2277
+ }, [t, e, a, l, M, r]), g;
2278
2278
  }
2279
2279
  function sl(t) {
2280
2280
  return t.live || t.auto ? "From this session" : t.cloned ? t.library === !1 ? "This transcription only" : "Saved in Voices" : "";
@@ -2333,28 +2333,28 @@ function Fs(t) {
2333
2333
  function Gs(t, e, n = !0) {
2334
2334
  const r = e.filter((o) => !o.cloned), s = /* @__PURE__ */ new Set(), a = /* @__PURE__ */ new Map();
2335
2335
  for (const o of t) {
2336
- const c = (o.voiceId ? e.find((M) => M.cloned && !M.auto && M.consent !== "pending" && M.id === `clone:${o.voiceId}`) : void 0) ?? (n ? (o.voiceId ? e.find((M) => M.cloned && M.consent !== "pending" && M.id === `clone:${o.voiceId}`) : void 0) ?? (o.key >= 0 ? e.find((M) => M.cloned && M.auto && M.consent !== "pending" && M.speaker === o.key) : void 0) : void 0);
2336
+ const c = (o.voiceId ? e.find((g) => g.cloned && !g.auto && g.consent !== "pending" && g.id === `clone:${o.voiceId}`) : void 0) ?? (n ? (o.voiceId ? e.find((g) => g.cloned && g.consent !== "pending" && g.id === `clone:${o.voiceId}`) : void 0) ?? (o.key >= 0 ? e.find((g) => g.cloned && g.auto && g.consent !== "pending" && g.speaker === o.key) : void 0) : void 0);
2337
2337
  if (c) {
2338
2338
  a.set(o.key, c.id), s.add(c.id);
2339
2339
  continue;
2340
2340
  }
2341
- const u = r.filter((M) => !s.has(M.id)), g = (o.sex ? u.filter((M) => M.gender === o.sex) : [])[0] ?? u[0] ?? r[0];
2342
- g && (a.set(o.key, g.id), s.add(g.id));
2341
+ const u = r.filter((g) => !s.has(g.id)), M = (o.sex ? u.filter((g) => g.gender === o.sex) : [])[0] ?? u[0] ?? r[0];
2342
+ M && (a.set(o.key, M.id), s.add(M.id));
2343
2343
  }
2344
2344
  return a;
2345
2345
  }
2346
2346
  function ol({ roster: t, selected: e, onSelect: n, noClone: r, building: s, short: a, warn: o, sexOf: l, t: c }) {
2347
2347
  const u = t.find((d) => d.key === e) ?? t[0] ?? null;
2348
2348
  return u ? /* @__PURE__ */ i("div", { style: { display: "flex", flexWrap: "wrap", gap: 6, padding: "0 2px 9px", margin: "0 -2px" }, children: t.map((d) => {
2349
- const g = d.key === u.key, M = d.key >= 0 ? (o == null ? void 0 : o(d)) ?? null : null, N = d.key >= 0 && !M && !!(s != null && s(d)), p = d.key >= 0 && !M && !N && r(d), y = d.key >= 0 && !M && !N && !p && !d.hasVoice && !!(a != null && a(d));
2349
+ const M = d.key === u.key, g = d.key >= 0 ? (o == null ? void 0 : o(d)) ?? null : null, N = d.key >= 0 && !g && !!(s != null && s(d)), p = d.key >= 0 && !g && !N && r(d), y = d.key >= 0 && !g && !N && !p && !d.hasVoice && !!(a != null && a(d));
2350
2350
  return /* @__PURE__ */ h(
2351
2351
  "button",
2352
2352
  {
2353
2353
  type: "button",
2354
- "aria-selected": g,
2354
+ "aria-selected": M,
2355
2355
  onClick: () => n(d.key),
2356
2356
  title: d.name,
2357
- style: { flex: "none", boxSizing: "border-box", display: "flex", alignItems: "center", gap: 7, minHeight: 34, padding: "5px 11px", borderRadius: 9, font: "inherit", background: g ? "var(--brand-tint)" : "var(--fill-05)", border: `1px solid ${g ? "var(--brand-line)" : "transparent"}`, cursor: "pointer" },
2357
+ style: { flex: "none", boxSizing: "border-box", display: "flex", alignItems: "center", gap: 7, minHeight: 34, padding: "5px 11px", borderRadius: 9, font: "inherit", background: M ? "var(--brand-tint)" : "var(--fill-05)", border: `1px solid ${M ? "var(--brand-line)" : "transparent"}`, cursor: "pointer" },
2358
2358
  children: [
2359
2359
  /* @__PURE__ */ i(
2360
2360
  "span",
@@ -2364,10 +2364,10 @@ function ol({ roster: t, selected: e, onSelect: n, noClone: r, building: s, shor
2364
2364
  children: d.initial
2365
2365
  }
2366
2366
  ),
2367
- /* @__PURE__ */ i("span", { style: { fontSize: 12.5, fontWeight: 500, color: g ? "var(--ink-96)" : "var(--ink-62)", whiteSpace: "nowrap" }, children: d.name }),
2368
- d.hasVoice && !M && /* @__PURE__ */ i(Oi, { color: d.fg ?? (g ? "var(--ink-62)" : "var(--ink-45)") }),
2369
- M && /* @__PURE__ */ i("span", { title: M, "aria-label": M, style: { flex: "none", width: 15, height: 15, marginRight: -2, borderRadius: "50%", background: "#c27c00", color: "#fff", font: "900 10.5px/1 system-ui, sans-serif", display: "flex", alignItems: "center", justifyContent: "center" }, children: "!" }),
2370
- y && /* @__PURE__ */ i("span", { title: "Not enough audio to clone", "aria-label": "Not enough audio to clone", style: { flex: "none", display: "flex", marginRight: -2, color: g ? "var(--ink-45)" : "var(--ink-35)" }, children: /* @__PURE__ */ i(oe, { d: X.micOff, size: 13, sw: 1.7 }) }),
2367
+ /* @__PURE__ */ i("span", { style: { fontSize: 12.5, fontWeight: 500, color: M ? "var(--ink-96)" : "var(--ink-62)", whiteSpace: "nowrap" }, children: d.name }),
2368
+ d.hasVoice && !g && /* @__PURE__ */ i(Oi, { color: d.fg ?? (M ? "var(--ink-62)" : "var(--ink-45)") }),
2369
+ g && /* @__PURE__ */ i("span", { title: g, "aria-label": g, style: { flex: "none", width: 15, height: 15, marginRight: -2, borderRadius: "50%", background: "#c27c00", color: "#fff", font: "900 10.5px/1 system-ui, sans-serif", display: "flex", alignItems: "center", justifyContent: "center" }, children: "!" }),
2370
+ y && /* @__PURE__ */ i("span", { title: "Not enough audio to clone", "aria-label": "Not enough audio to clone", style: { flex: "none", display: "flex", marginRight: -2, color: M ? "var(--ink-45)" : "var(--ink-35)" }, children: /* @__PURE__ */ i(oe, { d: X.micOff, size: 13, sw: 1.7 }) }),
2371
2371
  (p || N) && /* @__PURE__ */ i("span", { title: N ? "Cloning this voice…" : "No voice clone yet", "aria-label": N ? "Cloning this voice" : "No voice clone yet", style: { flex: "none", width: 10, height: 10, marginRight: -2, display: "flex", alignItems: "center", justifyContent: "center" }, children: N ? /* @__PURE__ */ i(at, { size: 10, color: "var(--brand)", track: "var(--fill-10)", sw: 1.6 }) : /* @__PURE__ */ i("span", { style: { width: 7, height: 7, borderRadius: "50%", background: "var(--brand)" } }) })
2372
2372
  ]
2373
2373
  },
@@ -2375,21 +2375,21 @@ function ol({ roster: t, selected: e, onSelect: n, noClone: r, building: s, shor
2375
2375
  );
2376
2376
  }) }) : null;
2377
2377
  }
2378
- function ll({ cast: t, voices: e, currentId: n, armedId: r = null, sampleId: s = null, dlId: a = null, onPick: o, onAdd: l, onUse: c, usedBy: u, foldKey: d, foldFor: g = null, problem: M, noClone: N = null, t: p }) {
2379
- const y = Ie(() => il(e, p), [e, p]), [L, m] = I({});
2378
+ function ll({ cast: t, voices: e, currentId: n, armedId: r = null, sampleId: s = null, dlId: a = null, onPick: o, onAdd: l, onUse: c, usedBy: u, foldKey: d, foldFor: M = null, problem: g, noClone: N = null, t: p }) {
2379
+ const y = Ie(() => il(e, p), [e, p]), [L, m] = z({});
2380
2380
  U(() => {
2381
2381
  m({});
2382
- }, [d, g]);
2383
- const f = (D) => D === p.vcMale.toUpperCase() || D === p.vcFemale.toUpperCase(), z = (D) => {
2382
+ }, [d, M]);
2383
+ const f = (D) => D === p.vcMale.toUpperCase() || D === p.vcFemale.toUpperCase(), I = (D) => {
2384
2384
  if (D === p.vcSheet) return !0;
2385
2385
  const V = L[D];
2386
- return V != null ? !V : !g || !f(D) ? !0 : D === (g === "female" ? p.vcFemale : p.vcMale).toUpperCase();
2386
+ return V != null ? !V : !M || !f(D) ? !0 : D === (M === "female" ? p.vcFemale : p.vcMale).toUpperCase();
2387
2387
  }, C = !!r && r !== n;
2388
2388
  return /* @__PURE__ */ h("div", { style: { display: "flex", flexDirection: "column" }, children: [
2389
- M && /* @__PURE__ */ h("div", { style: { display: "flex", alignItems: "flex-start", gap: 9, padding: "10px 11px", marginBottom: 10, borderRadius: 11, background: "var(--conf-low-soft)" }, children: [
2389
+ g && /* @__PURE__ */ h("div", { style: { display: "flex", alignItems: "flex-start", gap: 9, padding: "10px 11px", marginBottom: 10, borderRadius: 11, background: "var(--conf-low-soft)" }, children: [
2390
2390
  /* @__PURE__ */ i(oe, { d: X.warnTri, size: 15, sw: 1.7, style: { flex: "none", marginTop: 1, color: "var(--conf-low)" } }),
2391
- /* @__PURE__ */ i("span", { style: { flex: 1, minWidth: 0, fontSize: 12.5, fontWeight: 300, lineHeight: 1.45, color: "var(--ink-80)", textWrap: "pretty" }, children: M }),
2392
- /* @__PURE__ */ i("span", { style: { flex: "none", marginTop: -1 }, children: /* @__PURE__ */ i(za, { value: M, label: "Copy this error" }) })
2391
+ /* @__PURE__ */ i("span", { style: { flex: 1, minWidth: 0, fontSize: 12.5, fontWeight: 300, lineHeight: 1.45, color: "var(--ink-80)", textWrap: "pretty" }, children: g }),
2392
+ /* @__PURE__ */ i("span", { style: { flex: "none", marginTop: -1 }, children: /* @__PURE__ */ i(za, { value: g, label: "Copy this error" }) })
2393
2393
  ] }),
2394
2394
  t,
2395
2395
  N && /* @__PURE__ */ h(xe, { children: [
@@ -2405,7 +2405,7 @@ function ll({ cast: t, voices: e, currentId: n, armedId: r = null, sampleId: s =
2405
2405
  ] })
2406
2406
  ] }),
2407
2407
  y.map(({ v: D, headOn: V, head: _, headCount: ee, rule: j }, E) => {
2408
- const Q = sl(D), T = a === D.id, O = z(_), S = (u == null ? void 0 : u(D)) ?? null;
2408
+ const Q = sl(D), T = a === D.id, O = I(_), S = (u == null ? void 0 : u(D)) ?? null;
2409
2409
  return /* @__PURE__ */ h(ga, { children: [
2410
2410
  V && _ === p.vcSheet && /* @__PURE__ */ i("div", { style: { display: "flex", alignItems: "center", padding: "14px 2px 6px", borderTop: E === 0 && !N ? "0" : "1px solid var(--hair)", userSelect: "none" }, children: /* @__PURE__ */ i("span", { style: { font: "600 9px var(--vs-font-mono)", letterSpacing: ".13em", color: "var(--ink-62)" }, children: _ }) }),
2411
2411
  V && _ !== p.vcSheet && /* @__PURE__ */ h(
@@ -2413,7 +2413,7 @@ function ll({ cast: t, voices: e, currentId: n, armedId: r = null, sampleId: s =
2413
2413
  {
2414
2414
  type: "button",
2415
2415
  onClick: (re) => {
2416
- re.stopPropagation(), m((K) => ({ ...K, [_]: z(_) }));
2416
+ re.stopPropagation(), m((K) => ({ ...K, [_]: I(_) }));
2417
2417
  },
2418
2418
  title: `${O ? "Hide " : "Show "}${_.toLowerCase()} voices`,
2419
2419
  "aria-expanded": O,
@@ -2437,7 +2437,7 @@ function ll({ cast: t, voices: e, currentId: n, armedId: r = null, sampleId: s =
2437
2437
  children: [
2438
2438
  /* @__PURE__ */ i("span", { title: T ? "Downloading this voice" : void 0, style: { flex: "none", width: 32, height: 32, borderRadius: "50%", background: T ? "transparent" : D.cloned ? "var(--brand-soft)" : "var(--fill-06)", display: "flex", alignItems: "center", justifyContent: "center" }, children: T ? /* @__PURE__ */ i("span", { style: { width: 16, height: 16, borderRadius: "50%", border: "2px solid var(--fill-10)", borderTopColor: "var(--brand)", animation: "vs-spin .7s linear infinite" } }) : s === D.id ? /* @__PURE__ */ h("span", { className: "vcplay", children: [
2439
2439
  /* @__PURE__ */ i("span", { className: "vcplay__eq", children: /* @__PURE__ */ i(cl, { height: 13, width: 2.5 }) }),
2440
- /* @__PURE__ */ i("span", { className: "vcplay__stop", children: /* @__PURE__ */ i(ka, { size: 11 }) })
2440
+ /* @__PURE__ */ i("span", { className: "vcplay__stop", children: /* @__PURE__ */ i(va, { size: 11 }) })
2441
2441
  ] }) : /* @__PURE__ */ i(oe, { d: D.cloned ? X.voiceClone : D.gender === "female" ? X.venus : D.gender === "male" ? X.mars : X.mic, size: 15, sw: 1.6, style: { color: D.cloned ? "var(--brand)" : "var(--ink-55)" } }) }),
2442
2442
  /* @__PURE__ */ h("div", { style: { flex: 1, minWidth: 0 }, children: [
2443
2443
  /* @__PURE__ */ i("div", { style: { display: "flex", alignItems: "center", gap: 7, minWidth: 0 }, children: /* @__PURE__ */ i("span", { style: { minWidth: 0, fontSize: 14.5, fontWeight: D.id === n ? 600 : 400, color: "var(--ink-96)", whiteSpace: "nowrap", overflow: "hidden", textOverflow: "ellipsis" }, children: D.name }) }),
@@ -2482,7 +2482,7 @@ function wr(t, e) {
2482
2482
  return { flag: e ? (n == null ? void 0 : n.flag) ?? "🌐" : ul, code: e ? e.toUpperCase() : "", label: (n == null ? void 0 : n.native) ?? "As spoken", name: (n == null ? void 0 : n.name) ?? "Original" };
2483
2483
  }
2484
2484
  function dl(t, e, n = 0, r) {
2485
- const s = (r == null ? void 0 : r.id) ?? null, a = (r == null ? void 0 : r.token) ?? null, o = (r == null ? void 0 : r.shareCode) ?? null, l = Et(), { data: c } = ki(async () => {
2485
+ const s = (r == null ? void 0 : r.id) ?? null, a = (r == null ? void 0 : r.token) ?? null, o = (r == null ? void 0 : r.shareCode) ?? null, l = Et(), { data: c } = vi(async () => {
2486
2486
  if (!t || !e) return null;
2487
2487
  try {
2488
2488
  return await l.client.voices.available(t, { recording: s ?? void 0, shareCode: s ? o ?? void 0 : void 0, asOwner: l.owner });
@@ -2496,14 +2496,14 @@ function hl(t) {
2496
2496
  return (/* @__PURE__ */ new Set([...Object.keys(t.speakers), ...Object.keys(t.speakerIds)])).size;
2497
2497
  }
2498
2498
  function Ml({ recordingId: t, lang: e, ended: n, cred: r, pickedVoice: s, sentenceIds: a }) {
2499
- const o = Et(), { data: l, reload: c } = ki(async () => {
2499
+ const o = Et(), { data: l, reload: c } = vi(async () => {
2500
2500
  if (!t || !e) return null;
2501
2501
  const K = await o.client.recordings.voice(t, e, o.readAs).catch(() => []);
2502
2502
  return { recordingId: t, lang: e, rows: K.filter((k) => k.lang === e) };
2503
2503
  }, [t, e, o, n]), u = Ie(
2504
2504
  () => l && l.lang === e && l.recordingId === t ? l.rows : [],
2505
2505
  [l, e, t]
2506
- ), d = Ie(() => di(u, s), [u, s]), g = d ? d.voiceKey || null : s, [M, N] = I(null), [p, y] = I(null), L = v(/* @__PURE__ */ new Set()), m = `${t ?? ""}|${e ?? ""}|${g ?? ""}`, f = Ke(async (K, k) => {
2506
+ ), d = Ie(() => di(u, s), [u, s]), M = d ? d.voiceKey || null : s, [g, N] = z(null), [p, y] = z(null), L = v(/* @__PURE__ */ new Set()), m = `${t ?? ""}|${e ?? ""}|${M ?? ""}`, f = Ke(async (K, k) => {
2507
2507
  if (!t || !e || !n) return;
2508
2508
  const ae = k != null && k.size ? null : Fs(K), te = k != null && k.size ? k : ae, G = te && te.size ? Object.fromEntries([...te].map(([Te, je]) => [String(Te), je])) : null, J = `${t}|${e}|${G ? JSON.stringify(G) : K ?? ""}`;
2509
2509
  if (L.current.has(J)) return;
@@ -2518,23 +2518,23 @@ function Ml({ recordingId: t, lang: e, ended: n, cred: r, pickedVoice: s, senten
2518
2518
  return;
2519
2519
  }
2520
2520
  c();
2521
- }, [t, e, n, o, c]), z = Ke(() => {
2521
+ }, [t, e, n, o, c]), I = Ke(() => {
2522
2522
  const K = `${t ?? ""}|${e ?? ""}|`;
2523
2523
  for (const k of [...L.current]) k.startsWith(K) && L.current.delete(k);
2524
2524
  y(null);
2525
- }, [t, e]), C = !!d && (d.state === "queued" || d.state === "running") || M === m, D = (d == null ? void 0 : d.state) === "failed" ? d.error || "the render failed" : p, V = (a == null ? void 0 : a.join(",")) ?? "", [_, ee] = I(null), j = Ie(() => new Set((d == null ? void 0 : d.clips) ?? []), [d]), E = Ie(() => n && V ? V.split(",").map(Number).filter((K) => !j.has(K)) : [], [n, V, j]), Q = v(null);
2525
+ }, [t, e]), C = !!d && (d.state === "queued" || d.state === "running") || g === m, D = (d == null ? void 0 : d.state) === "failed" ? d.error || "the render failed" : p, V = (a == null ? void 0 : a.join(",")) ?? "", [_, ee] = z(null), j = Ie(() => new Set((d == null ? void 0 : d.clips) ?? []), [d]), E = Ie(() => n && V ? V.split(",").map(Number).filter((K) => !j.has(K)) : [], [n, V, j]), Q = v(null);
2526
2526
  U(() => {
2527
2527
  if (!n || !t || !e || !E.length) return;
2528
- const K = _ ?? E[0], k = E.find((pe) => pe >= K) ?? E[0], ae = `${t}|${e}|${g ?? ""}`, te = Q.current;
2528
+ const K = _ ?? E[0], k = E.find((pe) => pe >= K) ?? E[0], ae = `${t}|${e}|${M ?? ""}`, te = Q.current;
2529
2529
  if (te && te.key === ae && Math.abs(te.near - k) < 12 && Date.now() - te.at < 6e4) return;
2530
2530
  Q.current = { key: ae, near: k, at: Date.now() };
2531
- const G = Fs(g), J = { langs: [e], near: k };
2532
- G && G.size ? J.voiceBySpeaker = Object.fromEntries([...G].map(([pe, le]) => [String(pe), le])) : g && (J.voice = g), Bs(o, `/v1/recordings/${t}/voice`, { method: "POST", body: J }).then((pe) => {
2531
+ const G = Fs(M), J = { langs: [e], near: k };
2532
+ G && G.size ? J.voiceBySpeaker = Object.fromEntries([...G].map(([pe, le]) => [String(pe), le])) : M && (J.voice = M), Bs(o, `/v1/recordings/${t}/voice`, { method: "POST", body: J }).then((pe) => {
2533
2533
  pe.ok || (Q.current = null);
2534
2534
  }).catch(() => {
2535
2535
  Q.current = null;
2536
2536
  });
2537
- }, [n, t, e, g, _, E, o]);
2537
+ }, [n, t, e, M, _, E, o]);
2538
2538
  const T = E.length > 0, O = v({ n: -1, at: 0 });
2539
2539
  U(() => {
2540
2540
  if (!T) return;
@@ -2549,13 +2549,13 @@ function Ml({ recordingId: t, lang: e, ended: n, cred: r, pickedVoice: s, senten
2549
2549
  const K = V ? V.split(",").map(Number).filter((ae) => !n || j.has(ae)) : void 0, k = d ?? (K != null && K.length && e ? { lang: e, voiceKey: s ?? "", clips: [], voice: null } : null);
2550
2550
  return Ya(k, t, o.origin, r, K);
2551
2551
  }, [d, t, o, r, V, e, s, n, j]), re = Ie(() => new Set(E), [E]);
2552
- return { listed: l, rows: u, track: d, renderVoiceId: g, rendering: C, failed: D, clips: S, requestRender: f, forget: z, reload: c, setNear: ee, missing: E.length, coming: re };
2552
+ return { listed: l, rows: u, track: d, renderVoiceId: M, rendering: C, failed: D, clips: S, requestRender: f, forget: I, reload: c, setNear: ee, missing: E.length, coming: re };
2553
2553
  }
2554
2554
  const gl = { share: X.share, delay: X.tabGauge, video: X.video, source: X.tabSources, script: X.tabScript, fix: X.tabFix, ending: X.tabEnding, summary: X.tabSummary, export: X.tabExport, settings: X.tabSettings, sources: X.tabSources, recs: X.mic };
2555
2555
  function Ci({ tabs: t, current: e, onPick: n, gap: r, fold: s = !0, side: a = !s }) {
2556
- const o = s && t.length <= 3, l = t.some((L) => L.key === e), [c, u] = I(null), d = v(null), [g, M] = I(0);
2556
+ const o = s && t.length <= 3, l = t.some((L) => L.key === e), [c, u] = z(null), d = v(null), [M, g] = z(0);
2557
2557
  U(() => {
2558
- d.current && M(d.current.offsetWidth);
2558
+ d.current && g(d.current.offsetWidth);
2559
2559
  }, [c == null ? void 0 : c.k]);
2560
2560
  const N = (L, m) => {
2561
2561
  const f = L.currentTarget.querySelector(".tabbar__label");
@@ -2564,12 +2564,12 @@ function Ci({ tabs: t, current: e, onPick: n, gap: r, fold: s = !0, side: a = !s
2564
2564
  return;
2565
2565
  }
2566
2566
  if ((c == null ? void 0 : c.k) === m.key) return;
2567
- const z = L.currentTarget.getBoundingClientRect(), C = L.currentTarget.parentElement.getBoundingClientRect();
2568
- u({ k: m.key, label: m.label, x: z.left + z.width / 2, y: C.top });
2567
+ const I = L.currentTarget.getBoundingClientRect(), C = L.currentTarget.parentElement.getBoundingClientRect();
2568
+ u({ k: m.key, label: m.label, x: I.left + I.width / 2, y: C.top });
2569
2569
  }, p = () => u(null);
2570
2570
  let y = null;
2571
2571
  if (c) {
2572
- const L = { l: 0, r: typeof window < "u" ? window.innerWidth : 0 }, m = g || 80, f = Math.max(L.l + 8, Math.min(L.r - m - 8, c.x - m / 2));
2572
+ const L = { l: 0, r: typeof window < "u" ? window.innerWidth : 0 }, m = M || 80, f = Math.max(L.l + 8, Math.min(L.r - m - 8, c.x - m / 2));
2573
2573
  y = Na(
2574
2574
  /* @__PURE__ */ i("div", { className: "vsp vsp-portal", "data-theme": "dark", children: /* @__PURE__ */ h("div", { ref: d, "data-theme": "dark", className: "vs-tip__bubble vs-tip__bubble--top tabtip", style: { position: "fixed", left: f, top: c.y - 8, bottom: "auto", width: "auto", whiteSpace: "nowrap", transform: "translateY(-100%)", zIndex: 2147483e3, pointerEvents: "none" }, children: [
2575
2575
  /* @__PURE__ */ i("span", { className: "vs-tip__row", children: /* @__PURE__ */ i("span", { className: "vs-tip__copy", children: c.label }) }),
@@ -2580,13 +2580,13 @@ function Ci({ tabs: t, current: e, onPick: n, gap: r, fold: s = !0, side: a = !s
2580
2580
  }
2581
2581
  return /* @__PURE__ */ h("div", { role: "tablist", className: `tabbar tabbar--icons${s ? "" : " tabbar--desk"}`, "data-desk-tabs": a ? "" : void 0, "data-tab-n": a ? t.length : void 0, style: { marginBottom: r ? 12 : 0 }, onMouseLeave: p, children: [
2582
2582
  t.map((L) => {
2583
- const m = e === L.key, f = o || m, z = o ? "1 1 0" : m ? "1 1 auto" : s && !l ? "1 1 0" : "0 0 auto", C = L.icon ?? gl[L.key], D = () => {
2583
+ const m = e === L.key, f = o || m, I = o ? "1 1 0" : m ? "1 1 auto" : s && !l ? "1 1 0" : "0 0 auto", C = L.icon ?? gl[L.key], D = () => {
2584
2584
  p(), n(s && m ? "none" : L.key);
2585
2585
  };
2586
- return s ? /* @__PURE__ */ h("button", { type: "button", role: "tab", "aria-selected": m, title: L.label, className: `tabbar__tab${m ? " is-on" : ""}`, style: { flex: z }, onClick: D, children: [
2586
+ return s ? /* @__PURE__ */ h("button", { type: "button", role: "tab", "aria-selected": m, title: L.label, className: `tabbar__tab${m ? " is-on" : ""}`, style: { flex: I }, onClick: D, children: [
2587
2587
  C && /* @__PURE__ */ i(oe, { d: C, size: 15, sw: L.sw ?? 2, style: { flex: "none" } }),
2588
2588
  f && /* @__PURE__ */ i("span", { className: "tabbar__label", children: L.label })
2589
- ] }, L.key) : /* @__PURE__ */ i("div", { className: "tabbar__slot", "data-tab-cell": "", style: { flex: z }, onMouseEnter: (V) => N(V, L), onMouseMove: (V) => N(V, L), onClick: D, children: /* @__PURE__ */ h("button", { type: "button", role: "tab", "aria-selected": m, "aria-label": L.label, className: `tabbar__tab${m ? " is-on" : ""}${(c == null ? void 0 : c.k) === L.key ? " is-tip" : ""}`, children: [
2589
+ ] }, L.key) : /* @__PURE__ */ i("div", { className: "tabbar__slot", "data-tab-cell": "", style: { flex: I }, onMouseEnter: (V) => N(V, L), onMouseMove: (V) => N(V, L), onClick: D, children: /* @__PURE__ */ h("button", { type: "button", role: "tab", "aria-selected": m, "aria-label": L.label, className: `tabbar__tab${m ? " is-on" : ""}${(c == null ? void 0 : c.k) === L.key ? " is-tip" : ""}`, children: [
2590
2590
  C && /* @__PURE__ */ i(oe, { d: C, size: 15, sw: L.sw ?? 2, className: "tabbar__icon", style: { flex: "none", transform: m && !o ? "scale(1.12)" : "none" } }),
2591
2591
  /* @__PURE__ */ i("span", { className: "tabbar__grow", "data-tab-lw": "", style: { gridTemplateColumns: f ? "1fr" : "0fr", marginLeft: f && C ? 6 : 0 }, children: /* @__PURE__ */ i("span", { className: "tabbar__label", "data-tab-l": "", style: { opacity: f ? 1 : 0, transform: f ? "none" : "translateX(-6px)" }, children: L.label }) })
2592
2592
  ] }) }, L.key);
@@ -2596,20 +2596,20 @@ function Ci({ tabs: t, current: e, onPick: n, gap: r, fold: s = !0, side: a = !s
2596
2596
  }
2597
2597
  const fl = "M3 16.5v2.25A2.25 2.25 0 0 0 5.25 21h13.5A2.25 2.25 0 0 0 21 18.75V16.5M16.5 12 12 16.5m0 0L7.5 12m4.5 4.5V3", pl = "m9 9 10.5-3m0 6.553v3.75a2.25 2.25 0 0 1-1.632 2.163l-1.32.377a1.803 1.803 0 1 1-.99-3.467l2.31-.66a2.25 2.25 0 0 0 1.632-2.163Zm0 0V2.25L9 5.25v10.303m0 0v3.75a2.25 2.25 0 0 1-1.632 2.163l-1.32.377a1.803 1.803 0 0 1-.99-3.467l2.31-.66A2.25 2.25 0 0 0 9 15.553Z";
2598
2598
  function Nl({ audio: t, video: e, formats: n, onExport: r }) {
2599
- const [s, a] = I(null), [o, l] = I(null), c = v(void 0), u = v(!0);
2599
+ const [s, a] = z(null), [o, l] = z(null), c = v(void 0), u = v(!0);
2600
2600
  U(() => (u.current = !0, () => {
2601
2601
  u.current = !1, window.clearTimeout(c.current);
2602
2602
  }), []);
2603
2603
  const d = (p) => {
2604
2604
  window.clearTimeout(c.current), a(p), c.current = window.setTimeout(() => a(null), 1600);
2605
- }, g = (p) => {
2605
+ }, M = (p) => {
2606
2606
  o || (l(p), Promise.resolve().then(() => r(p)).then(() => {
2607
2607
  u.current && d(p);
2608
2608
  }).catch(() => {
2609
2609
  }).finally(() => {
2610
2610
  u.current && l(null);
2611
2611
  }));
2612
- }, M = (p, y) => {
2612
+ }, g = (p, y) => {
2613
2613
  o || (l(p), Promise.resolve().then(() => y.onClick()).then(() => {
2614
2614
  u.current && d(p);
2615
2615
  }).catch(() => {
@@ -2618,7 +2618,7 @@ function Nl({ audio: t, video: e, formats: n, onExport: r }) {
2618
2618
  }));
2619
2619
  }, N = (p, y, L, m) => /* @__PURE__ */ h(xe, { children: [
2620
2620
  /* @__PURE__ */ i(gr, { style: { letterSpacing: ".12em", color: "var(--ink-35)" }, children: m }),
2621
- /* @__PURE__ */ h("button", { type: "button", className: "dlrow", disabled: o != null, "aria-busy": o === p || void 0, onClick: () => M(p, y), style: o && o !== p ? { opacity: 0.45 } : void 0, children: [
2621
+ /* @__PURE__ */ h("button", { type: "button", className: "dlrow", disabled: o != null, "aria-busy": o === p || void 0, onClick: () => g(p, y), style: o && o !== p ? { opacity: 0.45 } : void 0, children: [
2622
2622
  o === p ? /* @__PURE__ */ i(at, { size: 17, color: "var(--brand)", track: "var(--fill-12)" }) : /* @__PURE__ */ i(oe, { d: L, size: 17, sw: 1.5, style: { flex: "none", color: "var(--ink-70)" } }),
2623
2623
  /* @__PURE__ */ h("span", { style: { flex: 1, minWidth: 0, display: "flex", flexDirection: "column", gap: 1, textAlign: "left" }, children: [
2624
2624
  /* @__PURE__ */ i("span", { style: { fontSize: 13, fontWeight: 500, color: "var(--ink-96)", whiteSpace: "nowrap", overflow: "hidden", textOverflow: "ellipsis" }, children: y.name }),
@@ -2632,7 +2632,7 @@ function Nl({ audio: t, video: e, formats: n, onExport: r }) {
2632
2632
  e && N("video", e, X.video, "DOWNLOAD VIDEO"),
2633
2633
  n !== !1 && /* @__PURE__ */ h(xe, { children: [
2634
2634
  /* @__PURE__ */ i(gr, { style: { letterSpacing: ".12em", color: "var(--ink-35)" }, children: "EXPORT AS" }),
2635
- /* @__PURE__ */ i("div", { className: "fmtgrid", children: Tr.map((p) => /* @__PURE__ */ h("button", { type: "button", className: "fmtgrid__cell", title: o === p.key ? `Building the ${p.name}…` : p.note, disabled: o != null, "aria-busy": o === p.key || void 0, onClick: () => g(p.key), style: o && o !== p.key ? { opacity: 0.45 } : void 0, children: [
2635
+ /* @__PURE__ */ i("div", { className: "fmtgrid", children: Tr.map((p) => /* @__PURE__ */ h("button", { type: "button", className: "fmtgrid__cell", title: o === p.key ? `Building the ${p.name}…` : p.note, disabled: o != null, "aria-busy": o === p.key || void 0, onClick: () => M(p.key), style: o && o !== p.key ? { opacity: 0.45 } : void 0, children: [
2636
2636
  o === p.key ? /* @__PURE__ */ i(at, { size: 16, color: "var(--brand)", track: "var(--fill-12)" }) : /* @__PURE__ */ i(oe, { d: s === p.key ? X.check : p.icon, size: 16, sw: 1.6, style: { color: s === p.key ? "var(--brand)" : "var(--ink-62)" } }),
2637
2637
  /* @__PURE__ */ i("span", { children: p.name })
2638
2638
  ] }, p.key)) })
@@ -2654,7 +2654,7 @@ function Ar(t, e, n) {
2654
2654
  r();
2655
2655
  }
2656
2656
  function ml(t, e, n) {
2657
- const [r, s] = I(null), a = t.state === "ready", o = `${e ?? ""}|${n ?? ""}|${a ? `${t.title}
2657
+ const [r, s] = z(null), a = t.state === "ready", o = `${e ?? ""}|${n ?? ""}|${a ? `${t.title}
2658
2658
  ${t.summary}` : ""}`, l = Et();
2659
2659
  return U(() => {
2660
2660
  if (!e || !n || !a) return;
@@ -2676,7 +2676,7 @@ function yl(t) {
2676
2676
  } };
2677
2677
  }
2678
2678
  function Tl({ s: t }) {
2679
- const [e, n] = I(!1), r = v(void 0);
2679
+ const [e, n] = z(!1), r = v(void 0);
2680
2680
  U(() => () => window.clearTimeout(r.current), []);
2681
2681
  const s = t.title ?? "", a = t.summary ?? "", o = () => {
2682
2682
  var c;
@@ -2692,7 +2692,7 @@ ${a}`).catch(() => {
2692
2692
  /* @__PURE__ */ h("div", { style: { display: "flex", alignItems: "center", justifyContent: "space-between", gap: 8, minHeight: 24 }, children: [
2693
2693
  /* @__PURE__ */ i(gr, { style: { letterSpacing: ".12em", color: "var(--ink-35)" }, children: "SUMMARY" }),
2694
2694
  t.state === "ready" && /* @__PURE__ */ h("button", { type: "button", className: "sumcopy", title: "Copy title and summary", style: { color: e ? "var(--brand)" : "var(--ink-70)" }, onClick: o, children: [
2695
- /* @__PURE__ */ i(oe, { d: e ? X.check : kl, size: 13, sw: 1.6 }),
2695
+ /* @__PURE__ */ i(oe, { d: e ? X.check : vl, size: 13, sw: 1.6 }),
2696
2696
  e ? "Copied" : "Copy"
2697
2697
  ] })
2698
2698
  ] }),
@@ -2719,13 +2719,13 @@ function Ll(t = !0, e) {
2719
2719
  const s = r.current;
2720
2720
  if (!s || !t) return;
2721
2721
  let a = 0, o = 0, l = !1;
2722
- const c = (g) => {
2723
- g.button !== 0 || g.target.closest("button,a,input,textarea,select") || (l = !0, a = g.clientY, o = s.scrollTop, s.classList.add("is-dragging"));
2724
- }, u = (g) => {
2722
+ const c = (M) => {
2723
+ M.button !== 0 || M.target.closest("button,a,input,textarea,select") || (l = !0, a = M.clientY, o = s.scrollTop, s.classList.add("is-dragging"));
2724
+ }, u = (M) => {
2725
2725
  var N;
2726
2726
  if (!l) return;
2727
- const M = g.clientY - a;
2728
- Math.abs(M) > 2 && ((N = s.setPointerCapture) == null || N.call(s, g.pointerId)), s.scrollTop = o - M;
2727
+ const g = M.clientY - a;
2728
+ Math.abs(g) > 2 && ((N = s.setPointerCapture) == null || N.call(s, M.pointerId)), s.scrollTop = o - g;
2729
2729
  }, d = () => {
2730
2730
  l = !1, s.classList.remove("is-dragging");
2731
2731
  };
@@ -2734,8 +2734,8 @@ function Ll(t = !0, e) {
2734
2734
  };
2735
2735
  }, [t]), r;
2736
2736
  }
2737
- const kl = "M15.75 17.25v3.375c0 .621-.504 1.125-1.125 1.125h-9.75a1.125 1.125 0 0 1-1.125-1.125V7.875c0-.621.504-1.125 1.125-1.125H6.75a9.06 9.06 0 0 1 1.5.124m7.5 10.376h3.375c.621 0 1.125-.504 1.125-1.125V11.25c0-4.46-3.243-8.161-7.5-8.876a9.06 9.06 0 0 0-1.5-.124H9.375c-.621 0-1.125.504-1.125 1.125v3.5m7.5 10.375H9.375a1.125 1.125 0 0 1-1.125-1.125v-9.25m12 6.625v-1.875a3.375 3.375 0 0 0-3.375-3.375h-1.5a1.125 1.125 0 0 1-1.125-1.125v-1.5a3.375 3.375 0 0 0-3.375-3.375H9.75";
2738
- function vl(t, e) {
2737
+ const vl = "M15.75 17.25v3.375c0 .621-.504 1.125-1.125 1.125h-9.75a1.125 1.125 0 0 1-1.125-1.125V7.875c0-.621.504-1.125 1.125-1.125H6.75a9.06 9.06 0 0 1 1.5.124m7.5 10.376h3.375c.621 0 1.125-.504 1.125-1.125V11.25c0-4.46-3.243-8.161-7.5-8.876a9.06 9.06 0 0 0-1.5-.124H9.375c-.621 0-1.125.504-1.125 1.125v3.5m7.5 10.375H9.375a1.125 1.125 0 0 1-1.125-1.125v-9.25m12 6.625v-1.875a3.375 3.375 0 0 0-3.375-3.375h-1.5a1.125 1.125 0 0 1-1.125-1.125v-1.5a3.375 3.375 0 0 0-3.375-3.375H9.75";
2738
+ function kl(t, e) {
2739
2739
  const [n, r] = Ra(t), s = e.tabs.map((f) => f.key), a = e.tabbed !== !1, o = e.pinnable ?? s;
2740
2740
  let l = n;
2741
2741
  [...e.autoPin ?? []].reverse().forEach((f) => {
@@ -2743,36 +2743,36 @@ function vl(t, e) {
2743
2743
  });
2744
2744
  const c = l;
2745
2745
  (e.forcePin ?? []).forEach((f) => {
2746
- l = l.filter((z) => z !== `!${f}`), s.includes(f) && !l.includes(f) && (l = [f, ...l]);
2746
+ l = l.filter((I) => I !== `!${f}`), s.includes(f) && !l.includes(f) && (l = [f, ...l]);
2747
2747
  });
2748
- const u = (f) => (e.forcePin ?? []).includes(f) && !c.includes(f), d = a ? l.filter((f) => s.includes(f) && o.includes(f)) : [], g = s.filter((f) => !d.includes(f)), M = e.cur && e.cur !== "none" && g.includes(e.cur) ? e.cur : e.pref && g.includes(e.pref) ? e.pref : g[0] ?? null, N = (f) => {
2749
- const z = g.filter((C) => C !== f);
2750
- return z[g.indexOf(f)] ?? z[z.length - 1] ?? null;
2751
- }, p = (f, z) => {
2748
+ const u = (f) => (e.forcePin ?? []).includes(f) && !c.includes(f), d = a ? l.filter((f) => s.includes(f) && o.includes(f)) : [], M = s.filter((f) => !d.includes(f)), g = e.cur && e.cur !== "none" && M.includes(e.cur) ? e.cur : e.pref && M.includes(e.pref) ? e.pref : M[0] ?? null, N = (f) => {
2749
+ const I = M.filter((C) => C !== f);
2750
+ return I[M.indexOf(f)] ?? I[I.length - 1] ?? null;
2751
+ }, p = (f, I) => {
2752
2752
  if (!o.includes(f)) return;
2753
2753
  const C = d.filter((D) => D !== f);
2754
- if (C.splice(z ?? C.length, 0, f), M === f) {
2754
+ if (C.splice(I ?? C.length, 0, f), g === f) {
2755
2755
  const D = N(f);
2756
2756
  D && e.onPick(D);
2757
2757
  }
2758
2758
  r([...C.filter((D) => !u(D) || D === f), ...c.filter((D) => !C.includes(D) && D !== `!${f}`)]);
2759
2759
  }, y = (f) => {
2760
- r([...c.filter((z) => z !== f && z !== `!${f}`), ...(e.autoPin ?? []).includes(f) ? [`!${f}`] : []]), e.onPick(f);
2760
+ r([...c.filter((I) => I !== f && I !== `!${f}`), ...(e.autoPin ?? []).includes(f) ? [`!${f}`] : []]), e.onPick(f);
2761
2761
  }, L = (f) => {
2762
- var z;
2763
- return ((z = e.tabs.find((C) => C.key === f)) == null ? void 0 : z.label) ?? f;
2762
+ var I;
2763
+ return ((I = e.tabs.find((C) => C.key === f)) == null ? void 0 : I.label) ?? f;
2764
2764
  }, m = (f) => {
2765
- const z = d.includes(f), C = s.includes(f);
2765
+ const I = d.includes(f), C = s.includes(f);
2766
2766
  return {
2767
- show: C && (!a || z || M === f),
2768
- pinned: z,
2769
- order: z ? d.indexOf(f) + 1 : 1e3,
2770
- pill: a && C && o.includes(f) && g.length > 0 && (z || g.length > 1),
2771
- title: z ? `Unpin — return ${L(f)} to the tabs` : `Pin ${L(f)} open above the tabs`,
2772
- toggle: () => z ? y(f) : p(f)
2767
+ show: C && (!a || I || g === f),
2768
+ pinned: I,
2769
+ order: I ? d.indexOf(f) + 1 : 1e3,
2770
+ pill: a && C && o.includes(f) && M.length > 0 && (I || M.length > 1),
2771
+ title: I ? `Unpin — return ${L(f)} to the tabs` : `Pin ${L(f)} open above the tabs`,
2772
+ toggle: () => I ? y(f) : p(f)
2773
2773
  };
2774
2774
  };
2775
- return { id: t, tabbed: a && g.length > 1, cur: M, seq: d, pinnable: o, tabKeys: g, stripTabs: e.tabs.filter((f) => g.includes(f.key)), panel: m, pin: p, unpin: y };
2775
+ return { id: t, tabbed: a && M.length > 1, cur: g, seq: d, pinnable: o, tabKeys: M, stripTabs: e.tabs.filter((f) => M.includes(f.key)), panel: m, pin: p, unpin: y };
2776
2776
  }
2777
2777
  function jl({ col: t, order: e, render: n, grip: r, onPick: s, wrapClass: a }) {
2778
2778
  return zl(t), /* @__PURE__ */ h(xe, { children: [
@@ -2801,46 +2801,46 @@ function zl(t) {
2801
2801
  r !== m && (r && r.removeAttribute("data-grip-hot"), r = m, m && m.setAttribute("data-grip-hot", ""));
2802
2802
  }, o = (m) => m.col.querySelector("[data-desk-tabs]"), l = (m) => {
2803
2803
  var ee;
2804
- const f = m.el.getBoundingClientRect(), z = m.el.cloneNode(!0);
2805
- z.querySelectorAll("*").forEach((j) => {
2804
+ const f = m.el.getBoundingClientRect(), I = m.el.cloneNode(!0);
2805
+ I.querySelectorAll("*").forEach((j) => {
2806
2806
  j.style.animation = "none", j.style.transition = "none";
2807
- }), z.querySelectorAll("iframe,video").forEach((j) => {
2807
+ }), I.querySelectorAll("iframe,video").forEach((j) => {
2808
2808
  const E = document.createElement("div");
2809
2809
  E.style.cssText = "width:100%;height:100%;background:#000", j.replaceWith(E);
2810
- }), z.removeAttribute("data-panel-key"), z.querySelectorAll("[data-panel-key],[data-pin-pill]").forEach((j) => j.hasAttribute("data-pin-pill") ? j.remove() : j.removeAttribute("data-panel-key")), Object.assign(z.style, { position: "fixed", left: `${f.left}px`, top: `${f.top}px`, width: `${f.width}px`, height: `${f.height}px`, margin: "0", zIndex: "1000", pointerEvents: "none", opacity: ".95", borderRadius: "14px", boxShadow: "0 14px 36px rgba(0,0,0,.3)", animation: "none", transition: "none", cursor: "move", willChange: "transform", contain: "layout paint", overflow: "hidden" });
2810
+ }), I.removeAttribute("data-panel-key"), I.querySelectorAll("[data-panel-key],[data-pin-pill]").forEach((j) => j.hasAttribute("data-pin-pill") ? j.remove() : j.removeAttribute("data-panel-key")), Object.assign(I.style, { position: "fixed", left: `${f.left}px`, top: `${f.top}px`, width: `${f.width}px`, height: `${f.height}px`, margin: "0", zIndex: "1000", pointerEvents: "none", opacity: ".95", borderRadius: "14px", boxShadow: "0 14px 36px rgba(0,0,0,.3)", animation: "none", transition: "none", cursor: "move", willChange: "transform", contain: "layout paint", overflow: "hidden" });
2811
2811
  const C = getComputedStyle(m.el);
2812
2812
  for (let j = 0; j < C.length; j++) {
2813
2813
  const E = C[j];
2814
- E.startsWith("--") && z.style.setProperty(E, C.getPropertyValue(E));
2814
+ E.startsWith("--") && I.style.setProperty(E, C.getPropertyValue(E));
2815
2815
  }
2816
- z.style.fontFamily = C.fontFamily, z.style.color = C.color;
2816
+ I.style.fontFamily = C.fontFamily, I.style.color = C.color;
2817
2817
  let D = m.el.parentElement, V = "";
2818
2818
  for (; D && !V; ) {
2819
2819
  const j = getComputedStyle(D).backgroundColor;
2820
2820
  j && !/rgba?\(0, 0, 0, 0\)|transparent/.test(j) && !/\/ 0\.|, 0\.\d+\)$/.test(j) && (V = j), D = D.parentElement;
2821
2821
  }
2822
- z.style.background = V || getComputedStyle(document.body).backgroundColor, document.body.appendChild(z), m.orig = [...m.col.querySelectorAll("[data-panel-key]")].map((j) => [j, j.style.order]), m.snap = {}, m.orig.forEach(([j]) => {
2822
+ I.style.background = V || getComputedStyle(document.body).backgroundColor, document.body.appendChild(I), m.orig = [...m.col.querySelectorAll("[data-panel-key]")].map((j) => [j, j.style.order]), m.snap = {}, m.orig.forEach(([j]) => {
2823
2823
  m.snap[j.getAttribute("data-panel-key")] = j.getBoundingClientRect();
2824
2824
  }), m.tabsSnap = ((ee = o(m)) == null ? void 0 : ee.getBoundingClientRect()) ?? null;
2825
2825
  const _ = m.col.querySelector("[data-panel-grid]");
2826
- m.grid = !!_ && getComputedStyle(_).display === "grid", m.el.classList.add("is-dragging"), document.documentElement.style.cursor = "move", document.body.style.userSelect = "none", document.body.style.webkitUserSelect = "none", Object.assign(m, { on: !0, clone: z }), a(null);
2826
+ m.grid = !!_ && getComputedStyle(_).display === "grid", m.el.classList.add("is-dragging"), document.documentElement.style.cursor = "move", document.body.style.userSelect = "none", document.body.style.webkitUserSelect = "none", Object.assign(m, { on: !0, clone: I }), a(null);
2827
2827
  }, c = () => {
2828
2828
  const m = s;
2829
2829
  if (!m || !m.on || m.px == null || m.py == null) return;
2830
2830
  m.raf = 0, m.clone.style.transform = `translate3d(${m.px - m.x0}px,${m.py - m.y0}px,0)`;
2831
- const f = e.current, z = m.key, C = o(m), D = f.seq.includes(z), V = D || f.tabKeys.length > 1, _ = C && m.tabsSnap, ee = !_ || m.py < _.top + _.height / 2 ? V ? "pin" : null : "tabs";
2831
+ const f = e.current, I = m.key, C = o(m), D = f.seq.includes(I), V = D || f.tabKeys.length > 1, _ = C && m.tabsSnap, ee = !_ || m.py < _.top + _.height / 2 ? V ? "pin" : null : "tabs";
2832
2832
  let j = null;
2833
2833
  if (ee === "pin") {
2834
- const Q = f.seq.filter((O) => O !== z).map((O) => m.snap[O]).filter(Boolean), T = m.grid ? Q.filter((O) => O.bottom < m.py || O.top <= m.py && O.left + O.width / 2 < m.px).length : Q.filter((O) => O.top + O.height / 2 < m.py).length;
2835
- D && f.seq.indexOf(z) === T || (j = { zone: ee, idx: T });
2834
+ const Q = f.seq.filter((O) => O !== I).map((O) => m.snap[O]).filter(Boolean), T = m.grid ? Q.filter((O) => O.bottom < m.py || O.top <= m.py && O.left + O.width / 2 < m.px).length : Q.filter((O) => O.top + O.height / 2 < m.py).length;
2835
+ D && f.seq.indexOf(I) === T || (j = { zone: ee, idx: T });
2836
2836
  } else ee === "tabs" && D && (j = { zone: ee });
2837
2837
  const E = j ? j.zone + (j.idx ?? "") : "";
2838
2838
  if (E !== m.sig) {
2839
2839
  if (m.sig = E, m.target = j, m.orig.forEach(([Q, T]) => {
2840
2840
  Q.style.order = T;
2841
2841
  }), (j == null ? void 0 : j.zone) === "pin") {
2842
- const Q = f.seq.filter((T) => T !== z);
2843
- Q.splice(j.idx, 0, z), Q.forEach((T, O) => {
2842
+ const Q = f.seq.filter((T) => T !== I);
2843
+ Q.splice(j.idx, 0, I), Q.forEach((T, O) => {
2844
2844
  const S = m.col.querySelector(`[data-panel-key="${T}"]`);
2845
2845
  S && (S.style.order = String(O + 1));
2846
2846
  });
@@ -2848,18 +2848,18 @@ function zl(t) {
2848
2848
  C && ((j == null ? void 0 : j.zone) === "tabs" ? C.setAttribute("data-drop-hot", "") : C.removeAttribute("data-drop-hot"));
2849
2849
  }
2850
2850
  }, u = (m) => {
2851
- var z;
2851
+ var I;
2852
2852
  const f = s;
2853
2853
  if (s = null, !(!f || !f.on) && (f.raf && cancelAnimationFrame(f.raf), f.clone.remove(), f.orig.forEach(([C, D]) => {
2854
2854
  C.style.order = D;
2855
- }), f.el.classList.remove("is-dragging"), document.documentElement.style.cursor = "", document.body.style.userSelect = "", document.body.style.webkitUserSelect = "", (z = o(f)) == null || z.removeAttribute("data-drop-hot"), m && f.target)) {
2855
+ }), f.el.classList.remove("is-dragging"), document.documentElement.style.cursor = "", document.body.style.userSelect = "", document.body.style.webkitUserSelect = "", (I = o(f)) == null || I.removeAttribute("data-drop-hot"), m && f.target)) {
2856
2856
  const C = e.current;
2857
2857
  f.target.zone === "tabs" ? C.seq.includes(f.key) && C.unpin(f.key) : C.pin(f.key, f.target.idx);
2858
2858
  }
2859
2859
  }, d = (m) => {
2860
2860
  const f = m instanceof Element ? m.closest("[data-tab-col]") : null;
2861
2861
  return f && f.getAttribute("data-tab-col") === n ? f : null;
2862
- }, g = (m) => {
2862
+ }, M = (m) => {
2863
2863
  var _;
2864
2864
  if (s) {
2865
2865
  if (!s.on) {
@@ -2874,11 +2874,11 @@ function zl(t) {
2874
2874
  r && ((_ = r.closest("[data-tab-col]")) == null ? void 0 : _.getAttribute("data-tab-col")) === n && a(null);
2875
2875
  return;
2876
2876
  }
2877
- const z = f.closest("[data-panel-key]"), C = z == null ? void 0 : z.firstElementChild;
2878
- if (!z || !C || !e.current.tabbed || !e.current.pinnable.includes(z.getAttribute("data-panel-key")) || f.closest("[role=button],[role=tab],button,a,input,textarea,select,iframe,[data-pin-pill],[contenteditable=true]")) return a(null);
2879
- const D = C.getBoundingClientRect(), V = parseFloat(getComputedStyle(z).getPropertyValue("--grip-h")) || 30;
2880
- a(m.clientY >= D.top && m.clientY <= D.top + V ? z : null);
2881
- }, M = (m) => {
2877
+ const I = f.closest("[data-panel-key]"), C = I == null ? void 0 : I.firstElementChild;
2878
+ if (!I || !C || !e.current.tabbed || !e.current.pinnable.includes(I.getAttribute("data-panel-key")) || f.closest("[role=button],[role=tab],button,a,input,textarea,select,iframe,[data-pin-pill],[contenteditable=true]")) return a(null);
2879
+ const D = C.getBoundingClientRect(), V = parseFloat(getComputedStyle(I).getPropertyValue("--grip-h")) || 30;
2880
+ a(m.clientY >= D.top && m.clientY <= D.top + V ? I : null);
2881
+ }, g = (m) => {
2882
2882
  if (!r || m.button !== 0) return;
2883
2883
  const f = d(r);
2884
2884
  f && (m.preventDefault(), m.stopImmediatePropagation(), s = { el: r, col: f, key: r.getAttribute("data-panel-key"), x0: m.clientX, y0: m.clientY, on: !1 });
@@ -2887,8 +2887,8 @@ function zl(t) {
2887
2887
  }, L = () => {
2888
2888
  s || a(null);
2889
2889
  };
2890
- return document.addEventListener("pointermove", g, !0), document.addEventListener("pointerdown", M, !0), window.addEventListener("pointerup", N), window.addEventListener("pointercancel", p), window.addEventListener("keydown", y, !0), document.addEventListener("pointerleave", L), () => {
2891
- u(!1), a(null), document.removeEventListener("pointermove", g, !0), document.removeEventListener("pointerdown", M, !0), window.removeEventListener("pointerup", N), window.removeEventListener("pointercancel", p), window.removeEventListener("keydown", y, !0), document.removeEventListener("pointerleave", L);
2890
+ return document.addEventListener("pointermove", M, !0), document.addEventListener("pointerdown", g, !0), window.addEventListener("pointerup", N), window.addEventListener("pointercancel", p), window.addEventListener("keydown", y, !0), document.addEventListener("pointerleave", L), () => {
2891
+ u(!1), a(null), document.removeEventListener("pointermove", M, !0), document.removeEventListener("pointerdown", g, !0), window.removeEventListener("pointerup", N), window.removeEventListener("pointercancel", p), window.removeEventListener("keydown", y, !0), document.removeEventListener("pointerleave", L);
2892
2892
  };
2893
2893
  }, [n]);
2894
2894
  }
@@ -2897,11 +2897,11 @@ function Il({ id: t, className: e, gap: n, hidden: r, plain: s, children: a }) {
2897
2897
  Ol(u), U(() => {
2898
2898
  document.documentElement.style.setProperty("--colw", `${o}px`);
2899
2899
  }, [o]);
2900
- const d = (M) => {
2900
+ const d = (g) => {
2901
2901
  const N = c.current, p = N == null ? void 0 : N.parentElement;
2902
- if (M.button !== 0 || !N || !p) return;
2903
- M.preventDefault();
2904
- const y = M.currentTarget, L = getComputedStyle(p), m = p.clientWidth - parseFloat(L.paddingLeft) - parseFloat(L.paddingRight) - (parseFloat(L.columnGap) || 0), f = 320, z = 320, C = Math.max(f, m - z), D = M.clientX, V = N.getBoundingClientRect().width;
2902
+ if (g.button !== 0 || !N || !p) return;
2903
+ g.preventDefault();
2904
+ const y = g.currentTarget, L = getComputedStyle(p), m = p.clientWidth - parseFloat(L.paddingLeft) - parseFloat(L.paddingRight) - (parseFloat(L.columnGap) || 0), f = 320, I = 320, C = Math.max(f, m - I), D = g.clientX, V = N.getBoundingClientRect().width;
2905
2905
  let _ = V;
2906
2906
  y.classList.add("is-on");
2907
2907
  const ee = { cur: document.body.style.cursor, sel: document.body.style.userSelect };
@@ -2912,10 +2912,10 @@ function Il({ id: t, className: e, gap: n, hidden: r, plain: s, children: a }) {
2912
2912
  window.removeEventListener("pointermove", j), window.removeEventListener("pointerup", E), window.removeEventListener("pointercancel", E), document.body.style.cursor = ee.cur, document.body.style.userSelect = ee.sel, y.classList.remove("is-on"), l(_);
2913
2913
  };
2914
2914
  window.addEventListener("pointermove", j), window.addEventListener("pointerup", E), window.addEventListener("pointercancel", E);
2915
- }, g = r ? { display: "none" } : void 0;
2915
+ }, M = r ? { display: "none" } : void 0;
2916
2916
  return /* @__PURE__ */ h(xe, { children: [
2917
- /* @__PURE__ */ i("div", { "aria-hidden": "true", className: "colgrip", style: { marginRight: -n, ...g }, children: /* @__PURE__ */ i("div", { className: "colgrip__bar", style: { left: -(n / 2 + 6) }, title: "Drag to resize · double-click to reset", onPointerDown: d, onDoubleClick: () => l(null) }) }),
2918
- /* @__PURE__ */ i("div", { ref: c, "data-tab-col": t, className: `${e} sidecol`, style: { flex: `0 0 ${o}px`, ...g }, children: s ? a : /* @__PURE__ */ i("div", { ref: u, "data-panel-grid": "", className: "panelgrid", children: a }) })
2917
+ /* @__PURE__ */ i("div", { "aria-hidden": "true", className: "colgrip", style: { marginRight: -n, ...M }, children: /* @__PURE__ */ i("div", { className: "colgrip__bar", style: { left: -(n / 2 + 6) }, title: "Drag to resize · double-click to reset", onPointerDown: d, onDoubleClick: () => l(null) }) }),
2918
+ /* @__PURE__ */ i("div", { ref: c, "data-tab-col": t, className: `${e} sidecol`, style: { flex: `0 0 ${o}px`, ...M }, children: s ? a : /* @__PURE__ */ i("div", { ref: u, "data-panel-grid": "", className: "panelgrid", children: a }) })
2919
2919
  ] });
2920
2920
  }
2921
2921
  function Ol(t) {
@@ -2928,13 +2928,13 @@ function Ol(t) {
2928
2928
  r = 0;
2929
2929
  const u = getComputedStyle(e).display === "grid";
2930
2930
  [...e.children].forEach((d) => {
2931
- const g = d;
2931
+ const M = d;
2932
2932
  if (!u) {
2933
- g.style.gridRowEnd && (g.style.gridRowEnd = "");
2933
+ M.style.gridRowEnd && (M.style.gridRowEnd = "");
2934
2934
  return;
2935
2935
  }
2936
- const M = g.getBoundingClientRect().height, N = M > 0 ? `span ${Math.ceil(M + n)}` : "span 1";
2937
- g.style.gridRowEnd !== N && (g.style.gridRowEnd = N);
2936
+ const g = M.getBoundingClientRect().height, N = g > 0 ? `span ${Math.ceil(g + n)}` : "span 1";
2937
+ M.style.gridRowEnd !== N && (M.style.gridRowEnd = N);
2938
2938
  });
2939
2939
  }, a = () => {
2940
2940
  r || (r = requestAnimationFrame(s));
@@ -2951,8 +2951,8 @@ function Cl(t) {
2951
2951
  }
2952
2952
  const bl = 1500, xl = 3e5;
2953
2953
  function Dl(t) {
2954
- const e = Et(), [n, r] = I(null), [s, a] = I(null), [o, l] = I(null), [c, u] = I(null), d = v(null), g = v(null), M = v(null), N = v(0), p = Ke(() => {
2955
- M.current && (clearTimeout(M.current), M.current = null), d.current && (d.current.pause(), d.current.removeAttribute("src"), d.current.load(), d.current = null), g.current && (URL.revokeObjectURL(g.current), g.current = null);
2954
+ const e = Et(), [n, r] = z(null), [s, a] = z(null), [o, l] = z(null), [c, u] = z(null), d = v(null), M = v(null), g = v(null), N = v(0), p = Ke(() => {
2955
+ g.current && (clearTimeout(g.current), g.current = null), d.current && (d.current.pause(), d.current.removeAttribute("src"), d.current.load(), d.current = null), M.current && (URL.revokeObjectURL(M.current), M.current = null);
2956
2956
  }, []), y = Ke(() => {
2957
2957
  N.current += 1, p(), a(null), l(null);
2958
2958
  }, [p]), L = Ke(() => {
@@ -2963,30 +2963,30 @@ function Dl(t) {
2963
2963
  }, [p]);
2964
2964
  const m = Ke((f) => {
2965
2965
  N.current += 1;
2966
- const z = N.current;
2966
+ const I = N.current;
2967
2967
  if (p(), r(f.id), a(null), l(null), u(null), !t) return;
2968
2968
  let C = f.previewUrl ? `${e.origin}${f.previewUrl}` : `${e.origin}/v1/voices/preview?voice=${encodeURIComponent(f.id)}&lang=${encodeURIComponent(t)}`;
2969
2969
  xn() === "caf" && (C += `${C.includes("?") ? "&" : "?"}format=caf`);
2970
2970
  const D = Date.now();
2971
2971
  e.shareCode && C.includes("recording=") && (C += `&shareCode=${encodeURIComponent(e.shareCode)}`);
2972
2972
  const V = async () => {
2973
- if (N.current !== z) return;
2973
+ if (N.current !== I) return;
2974
2974
  let _;
2975
2975
  try {
2976
2976
  const Q = e.owner ? await e.bearer() : void 0;
2977
2977
  _ = await fetch(C, { headers: Q ? { Authorization: `Bearer ${Q}` } : {} });
2978
2978
  } catch (Q) {
2979
- if (N.current !== z) return;
2979
+ if (N.current !== I) return;
2980
2980
  l(null), u(Tt(Q));
2981
2981
  return;
2982
2982
  }
2983
- if (N.current !== z) return;
2983
+ if (N.current !== I) return;
2984
2984
  if (_.status === 202 || _.status === 503) {
2985
2985
  if (Date.now() - D > xl) {
2986
2986
  l(null), u({ message: "This voice is still being fetched. Try it again in a moment." });
2987
2987
  return;
2988
2988
  }
2989
- l(f.id), M.current = setTimeout(() => {
2989
+ l(f.id), g.current = setTimeout(() => {
2990
2990
  V();
2991
2991
  }, bl);
2992
2992
  return;
@@ -2998,15 +2998,15 @@ function Dl(t) {
2998
2998
  return;
2999
2999
  }
3000
3000
  const ee = await _.blob();
3001
- if (N.current !== z) return;
3002
- l(null), g.current = URL.createObjectURL(ee);
3003
- const j = new Audio(g.current);
3001
+ if (N.current !== I) return;
3002
+ l(null), M.current = URL.createObjectURL(ee);
3003
+ const j = new Audio(M.current);
3004
3004
  j.playsInline = !0;
3005
3005
  const E = () => {
3006
- N.current === z && (p(), a(null));
3006
+ N.current === I && (p(), a(null));
3007
3007
  };
3008
3008
  j.onended = E, j.onerror = E, d.current = j, j.play().then(() => {
3009
- N.current === z && a(f.id);
3009
+ N.current === I && a(f.id);
3010
3010
  }).catch(E);
3011
3011
  };
3012
3012
  V();
@@ -3063,21 +3063,21 @@ function At(t, e, n) {
3063
3063
  const r = (s = t == null ? void 0 : t.words[t.words.length - 1]) == null ? void 0 : s.end;
3064
3064
  return r != null && r > e ? r : (t == null ? void 0 : t.end) != null && t.end > e ? t.end : n > e ? n : e + 4;
3065
3065
  }
3066
- function Al({ ytId: t, title: e, t: n, playing: r, seekN: s, onToggle: a, onAd: o, endT: l, onGone: c, onKnown: u, lead: d, onTime: g, waiting: M = !1 }) {
3067
- const N = v(null), [p, y] = I(!1);
3066
+ function Al({ ytId: t, title: e, t: n, playing: r, seekN: s, onToggle: a, onAd: o, endT: l, onGone: c, onKnown: u, lead: d, onTime: M, waiting: g = !1 }) {
3067
+ const N = v(null), [p, y] = z(!1);
3068
3068
  U(() => {
3069
- if (!M) {
3069
+ if (!g) {
3070
3070
  y(!1);
3071
3071
  return;
3072
3072
  }
3073
3073
  const F = setTimeout(() => y(!0), 300);
3074
3074
  return () => clearTimeout(F);
3075
- }, [M]);
3076
- const L = r && !p, m = v(!1), [f, z] = I(!1), C = (F, me = []) => {
3077
- var Z, ke;
3075
+ }, [g]);
3076
+ const L = r && !p, m = v(!1), [f, I] = z(!1), C = (F, me = []) => {
3077
+ var Z, ve;
3078
3078
  if (!(m.current && (F === "pauseVideo" || F === "seekTo" || F === "setPlaybackRate")))
3079
3079
  try {
3080
- (ke = (Z = N.current) == null ? void 0 : Z.contentWindow) == null || ke.postMessage(JSON.stringify({ event: "command", func: F, args: me }), "*");
3080
+ (ve = (Z = N.current) == null ? void 0 : Z.contentWindow) == null || ve.postMessage(JSON.stringify({ event: "command", func: F, args: me }), "*");
3081
3081
  } catch {
3082
3082
  }
3083
3083
  }, D = v(null), V = v(!1), _ = v(!1), ee = v(!1), j = v(a);
@@ -3090,15 +3090,15 @@ function Al({ ytId: t, title: e, t: n, playing: r, seekN: s, onToggle: a, onAd:
3090
3090
  var me, Z;
3091
3091
  const F = _.current || ee.current;
3092
3092
  if (F !== m.current)
3093
- if (m.current = F, z(F), (me = Q.current) == null || me.call(Q, F), F) {
3093
+ if (m.current = F, I(F), (me = Q.current) == null || me.call(Q, F), F) {
3094
3094
  if (C("playVideo"), E.current) return;
3095
3095
  we.current && j.current && (T.current = !0, j.current());
3096
3096
  } else T.current && !E.current && (T.current = !1, we.current || (Z = j.current) == null || Z.call(j));
3097
3097
  }, S = v(n);
3098
3098
  S.current = n;
3099
- const re = v(g);
3100
- re.current = g;
3101
- const K = v(null), k = v(null), [ae, te] = I(!0), [G, J] = I(!1), pe = () => {
3099
+ const re = v(M);
3100
+ re.current = M;
3101
+ const K = v(null), k = v(null), [ae, te] = z(!0), [G, J] = z(!1), pe = () => {
3102
3102
  C("unloadModule", ["captions"]), C("unloadModule", ["cc"]);
3103
3103
  }, le = v([]), Te = () => {
3104
3104
  pe(), le.current.forEach(clearTimeout), le.current = [400, 1200, 2500, 5e3].map((F) => window.setTimeout(pe, F));
@@ -3123,7 +3123,7 @@ function Al({ ytId: t, title: e, t: n, playing: r, seekN: s, onToggle: a, onAd:
3123
3123
  Pe.current = c;
3124
3124
  const Se = v(u);
3125
3125
  Se.current = u;
3126
- const B = v(!1), [W, A] = I(!1), b = (F) => {
3126
+ const B = v(!1), [W, A] = z(!1), b = (F) => {
3127
3127
  const me = Ee.current;
3128
3128
  return !!me && (F < me.start - 1 || F > me.end + 5);
3129
3129
  }, H = () => {
@@ -3140,8 +3140,8 @@ function Al({ ytId: t, title: e, t: n, playing: r, seekN: s, onToggle: a, onAd:
3140
3140
  return;
3141
3141
  }
3142
3142
  (ge = (Ae = Z == null ? void 0 : Z.info) == null ? void 0 : Ae.videoData) != null && ge.isLive && (V.current = !0);
3143
- const ke = (Ye = Z == null ? void 0 : Z.info) == null ? void 0 : Ye.duration;
3144
- typeof ke == "number" && ke > 0 && !V.current && (D.current == null ? D.current = ke : (_.current = Math.abs(ke - D.current) > 1.5, O())), (Z == null ? void 0 : Z.event) === "onReady" && ((!E.current || E.current.muted) && C("mute"), Te(), (Ve = E.current) == null || Ve.onInfo({ ready: !0 })), typeof (($ = Z == null ? void 0 : Z.info) == null ? void 0 : $.playerState) == "number" && (Z.info.playerState !== k.current && (Z.info.playerState === 1 || Z.info.playerState === 2) && Te(), k.current = Z.info.playerState, te(Z.info.playerState !== 1 && Z.info.playerState !== 3), (he = E.current) == null || he.onInfo({ state: Z.info.playerState }));
3143
+ const ve = (Ye = Z == null ? void 0 : Z.info) == null ? void 0 : Ye.duration;
3144
+ typeof ve == "number" && ve > 0 && !V.current && (D.current == null ? D.current = ve : (_.current = Math.abs(ve - D.current) > 1.5, O())), (Z == null ? void 0 : Z.event) === "onReady" && ((!E.current || E.current.muted) && C("mute"), Te(), (Ve = E.current) == null || Ve.onInfo({ ready: !0 })), typeof (($ = Z == null ? void 0 : Z.info) == null ? void 0 : $.playerState) == "number" && (Z.info.playerState !== k.current && (Z.info.playerState === 1 || Z.info.playerState === 2) && Te(), k.current = Z.info.playerState, te(Z.info.playerState !== 1 && Z.info.playerState !== 3), (he = E.current) == null || he.onInfo({ state: Z.info.playerState }));
3145
3145
  const ze = (ue = Z == null ? void 0 : Z.info) == null ? void 0 : ue.progressState;
3146
3146
  if (ze && typeof ze.seekableStart == "number" && typeof ze.seekableEnd == "number" && ze.seekableEnd > ze.seekableStart) {
3147
3147
  const Oe = Ee.current == null;
@@ -3174,8 +3174,8 @@ function Al({ ytId: t, title: e, t: n, playing: r, seekN: s, onToggle: a, onAd:
3174
3174
  if (!G) return;
3175
3175
  let F = null, me = 0;
3176
3176
  const Z = setInterval(() => {
3177
- const ke = K.current;
3178
- me = k.current === 1 && ke != null && F != null && Math.abs(ke - F) < 0.05 ? me + 1 : 0, F = ke;
3177
+ const ve = K.current;
3178
+ me = k.current === 1 && ve != null && F != null && Math.abs(ve - F) < 0.05 ? me + 1 : 0, F = ve;
3179
3179
  const ze = me >= 3;
3180
3180
  ze !== ee.current && (ee.current = ze, O());
3181
3181
  }, 1e3);
@@ -3200,7 +3200,7 @@ function Yl({ player: t, size: e }) {
3200
3200
  return /* @__PURE__ */ i("button", { type: "button", className: `mutebtn${e < 36 ? " mutebtn--sm" : e > 36 ? " mutebtn--lg" : ""}`, "aria-label": n, title: n, "aria-pressed": t.muted, onClick: t.toggleMute, children: /* @__PURE__ */ i(oe, { d: t.muted ? X.volumeOff : X.volume, size: 17, sw: 1.6, style: { color: t.muted ? "var(--ink-38)" : "var(--ink-70)" } }) });
3201
3201
  }
3202
3202
  function Ul() {
3203
- const [t, e] = I(""), n = v(null), r = Ke((s) => {
3203
+ const [t, e] = z(""), n = v(null), r = Ke((s) => {
3204
3204
  clearTimeout(n.current), e(s), n.current = setTimeout(() => e(""), 3e3);
3205
3205
  }, []);
3206
3206
  return U(() => () => clearTimeout(n.current), []), [t, r];
@@ -3212,10 +3212,10 @@ function $l(t, e) {
3212
3212
  const r = v(0), s = v(1), a = Ke((o, l) => {
3213
3213
  cancelAnimationFrame(r.current);
3214
3214
  const c = s.current, u = performance.now(), d = () => {
3215
- const g = l > 0 ? Math.min(1, (performance.now() - u) / l) : 1;
3216
- s.current = c + (o - c) * g;
3217
- for (const M of n.current) M.setVolume(s.current);
3218
- g < 1 && (r.current = requestAnimationFrame(d));
3215
+ const M = l > 0 ? Math.min(1, (performance.now() - u) / l) : 1;
3216
+ s.current = c + (o - c) * M;
3217
+ for (const g of n.current) g.setVolume(s.current);
3218
+ M < 1 && (r.current = requestAnimationFrame(d));
3219
3219
  };
3220
3220
  d();
3221
3221
  }, []);
@@ -3228,13 +3228,13 @@ function $l(t, e) {
3228
3228
  }
3229
3229
  function Bl(t, e, n, r) {
3230
3230
  var Se;
3231
- const s = v(null), a = v(!1), o = v(!1), [l, c] = I(null), [u, d] = I(!0), g = v(!0), M = v(!1), [N, p] = I(0), y = v(0);
3231
+ const s = v(null), a = v(!1), o = v(!1), [l, c] = z(null), [u, d] = z(!0), M = v(!0), g = v(!1), [N, p] = z(0), y = v(0);
3232
3232
  y.current = N;
3233
3233
  const L = v({ t: 0, at: 0 }), m = v(n);
3234
3234
  m.current = n;
3235
3235
  const f = v(r);
3236
3236
  f.current = r;
3237
- const [z, C] = I(!1), D = v(!1), V = (B) => {
3237
+ const [I, C] = z(!1), D = v(!1), V = (B) => {
3238
3238
  D.current = B, C(B);
3239
3239
  }, _ = (B, W) => {
3240
3240
  var A;
@@ -3251,7 +3251,7 @@ function Bl(t, e, n, r) {
3251
3251
  }
3252
3252
  }
3253
3253
  }), []);
3254
- Q.muted = g.current || M.current, U(() => {
3254
+ Q.muted = M.current || g.current, U(() => {
3255
3255
  if (l !== 1) return;
3256
3256
  let B = 0;
3257
3257
  const W = () => {
@@ -3264,8 +3264,8 @@ function Bl(t, e, n, r) {
3264
3264
  };
3265
3265
  return B = requestAnimationFrame(W), () => cancelAnimationFrame(B);
3266
3266
  }, [l]), U(() => {
3267
- !z || r == null || r < N + 1.5 || (V(!1), _("playVideo"));
3268
- }, [z, r, N]), U(() => {
3267
+ !I || r == null || r < N + 1.5 || (V(!1), _("playVideo"));
3268
+ }, [I, r, N]), U(() => {
3269
3269
  r == null && D.current && (V(!1), _("playVideo"));
3270
3270
  }, [r]);
3271
3271
  const T = t.length ? ((Se = t[t.length - 1].words[t[t.length - 1].words.length - 1]) == null ? void 0 : Se.end) ?? t[t.length - 1].start + 4 : 0, O = e || T || 1, S = Ie(() => {
@@ -3273,7 +3273,7 @@ function Bl(t, e, n, r) {
3273
3273
  let B = 0;
3274
3274
  for (let W = 0; W < t.length; W++) t[W].start <= N + 0.05 && (B = W);
3275
3275
  return B;
3276
- }, [t, N]), [re, K] = I(0), k = (B) => {
3276
+ }, [t, N]), [re, K] = z(0), k = (B) => {
3277
3277
  const W = Math.max(0, f.current != null ? Math.min(B, Math.max(0, f.current - 0.5)) : B);
3278
3278
  _("seekTo", [W + m.current, !0]), L.current = { t: W, at: performance.now() }, p(W), K((A) => A + 1);
3279
3279
  }, ae = v(!1), te = v(void 0), G = (B) => {
@@ -3308,12 +3308,12 @@ function Bl(t, e, n, r) {
3308
3308
  const W = t[Math.max(0, Math.min(t.length - 1, B))];
3309
3309
  W && k(W.start);
3310
3310
  }, je = v(!1), Ee = () => {
3311
- const B = g.current || M.current;
3311
+ const B = M.current || g.current;
3312
3312
  Q.muted = B, _(B ? "mute" : "unMute");
3313
3313
  }, Le = (B) => {
3314
- g.current = B, d(B), Ee();
3314
+ M.current = B, d(B), Ee();
3315
3315
  }, we = (B) => {
3316
- M.current !== !B && (M.current = !B, Ee());
3316
+ g.current !== !B && (g.current = !B, Ee());
3317
3317
  };
3318
3318
  return { player: {
3319
3319
  autoplay: async () => {
@@ -3325,7 +3325,7 @@ function Bl(t, e, n, r) {
3325
3325
  Le(!0);
3326
3326
  for (let A = 0; A < 5 && j.current !== 1; A++)
3327
3327
  _("playVideo"), await W(() => j.current === 1, 1500);
3328
- return j.current !== 1 ? null : M.current ? (Le(!0), !1) : (Le(!1), await B(1200), j.current === 1 && E.current === !1 ? !0 : (Le(!0), _("playVideo"), !1));
3328
+ return j.current !== 1 ? null : g.current ? (Le(!0), !1) : (Le(!1), await B(1200), j.current === 1 && E.current === !1 ? !0 : (Le(!0), _("playVideo"), !1));
3329
3329
  },
3330
3330
  playing: ee,
3331
3331
  ended: l === 0,
@@ -3337,9 +3337,9 @@ function Bl(t, e, n, r) {
3337
3337
  toggle: le,
3338
3338
  seekRow: Te,
3339
3339
  toggleMute: () => {
3340
- const B = !g.current;
3341
- Le(B), !B && !M.current && j.current === 1 && setTimeout(() => {
3342
- j.current === 2 && !g.current && (Le(!0), _("playVideo"));
3340
+ const B = !M.current;
3341
+ Le(B), !B && !g.current && j.current === 1 && setTimeout(() => {
3342
+ j.current === 2 && !M.current && (Le(!0), _("playVideo"));
3343
3343
  }, 900);
3344
3344
  },
3345
3345
  seekFrac: (B) => k(Math.max(0, Math.min(1, B)) * O),
@@ -3363,7 +3363,7 @@ function Bl(t, e, n, r) {
3363
3363
  clearError: () => {
3364
3364
  },
3365
3365
  has: !0,
3366
- edgeWait: z,
3366
+ edgeWait: I,
3367
3367
  wordSync: !0,
3368
3368
  pause: pe,
3369
3369
  setVolume: (B) => _("setVolume", [Math.round(B * 100)])
@@ -3371,11 +3371,11 @@ function Bl(t, e, n, r) {
3371
3371
  }
3372
3372
  function Vl(t, e, n, r, s = 0, a = null) {
3373
3373
  var A;
3374
- const o = v(null), [l, c] = I(!1), [u, d] = I(0), [g, M] = I(!1), N = v(g);
3375
- N.current = g;
3376
- const p = v(!1), [y, L] = I(null), [m, f] = I(!1), z = v(s);
3377
- z.current = s;
3378
- const C = v(null), [D, V] = I(0);
3374
+ const o = v(null), [l, c] = z(!1), [u, d] = z(0), [M, g] = z(!1), N = v(M);
3375
+ N.current = M;
3376
+ const p = v(!1), [y, L] = z(null), [m, f] = z(!1), I = v(s);
3377
+ I.current = s;
3378
+ const C = v(null), [D, V] = z(0);
3379
3379
  U(() => {
3380
3380
  f(!1);
3381
3381
  const b = C.current;
@@ -3383,7 +3383,7 @@ function Vl(t, e, n, r, s = 0, a = null) {
3383
3383
  c(!1), o.current = null;
3384
3384
  return;
3385
3385
  }
3386
- const H = ci(t), ce = z.current;
3386
+ const H = ci(t), ce = I.current;
3387
3387
  return H.preload = "metadata", H.muted = N.current || p.current, H.onplay = () => c(!0), H.onpause = () => c(!1), H.onended = () => c(!1), H.onloadedmetadata = () => {
3388
3388
  f(!0), H.currentTime = ((b == null ? void 0 : b.t) ?? 0) + ce, b != null && b.playing && H.play().catch((F) => {
3389
3389
  b.asked && (F == null ? void 0 : F.name) === "NotAllowedError" || L(Tt(F));
@@ -3406,7 +3406,7 @@ function Vl(t, e, n, r, s = 0, a = null) {
3406
3406
  Q.current = ee;
3407
3407
  const T = v(a);
3408
3408
  T.current = a;
3409
- const [O, S] = I(!1), re = v(!1), K = (b) => {
3409
+ const [O, S] = z(!1), re = v(!1), K = (b) => {
3410
3410
  re.current = b, S(b);
3411
3411
  };
3412
3412
  U(() => {
@@ -3423,7 +3423,7 @@ function Vl(t, e, n, r, s = 0, a = null) {
3423
3423
  const H = () => {
3424
3424
  const ce = o.current;
3425
3425
  if (ce) {
3426
- const F = ce.currentTime - z.current;
3426
+ const F = ce.currentTime - I.current;
3427
3427
  if (Q.current && F >= E.current) {
3428
3428
  ce.pause(), d(E.current);
3429
3429
  return;
@@ -3443,9 +3443,9 @@ function Vl(t, e, n, r, s = 0, a = null) {
3443
3443
  let b = 0;
3444
3444
  for (let H = 0; H < n.length; H++) n[H].start <= u + 0.05 && (b = H);
3445
3445
  return b;
3446
- }, [n, u]), [ae, te] = I(0), G = (b) => {
3446
+ }, [n, u]), [ae, te] = z(0), G = (b) => {
3447
3447
  const H = T.current != null ? Math.min(b, Math.max(0, T.current - 0.5)) : b, ce = o.current;
3448
- d(H), ce && (ce.currentTime = H + z.current), te((F) => F + 1);
3448
+ d(H), ce && (ce.currentTime = H + I.current), te((F) => F + 1);
3449
3449
  }, J = (b) => {
3450
3450
  (b == null ? void 0 : b.name) !== "AbortError" && L(Tt(b));
3451
3451
  }, pe = () => {
@@ -3467,7 +3467,7 @@ function Vl(t, e, n, r, s = 0, a = null) {
3467
3467
  K(!1);
3468
3468
  return;
3469
3469
  }
3470
- b.currentTime < z.current && (b.currentTime = z.current), u >= j - 0.25 && G(0), b.play().catch(J);
3470
+ b.currentTime < I.current && (b.currentTime = I.current), u >= j - 0.25 && G(0), b.play().catch(J);
3471
3471
  }, le = (b) => {
3472
3472
  const H = n[Math.max(0, Math.min(n.length - 1, b))];
3473
3473
  H && G(H.start);
@@ -3497,9 +3497,9 @@ function Vl(t, e, n, r, s = 0, a = null) {
3497
3497
  autoplay: async () => {
3498
3498
  const b = o.current;
3499
3499
  if (!b) return null;
3500
- b.currentTime < z.current && (b.currentTime = z.current);
3500
+ b.currentTime < I.current && (b.currentTime = I.current);
3501
3501
  const H = (ce) => {
3502
- N.current = ce, b.muted = ce || p.current, M(ce);
3502
+ N.current = ce, b.muted = ce || p.current, g(ce);
3503
3503
  };
3504
3504
  try {
3505
3505
  return H(!1), await b.play(), !0;
@@ -3517,10 +3517,10 @@ function Vl(t, e, n, r, s = 0, a = null) {
3517
3517
  t: u,
3518
3518
  idx: k,
3519
3519
  dur: j,
3520
- muted: g,
3520
+ muted: M,
3521
3521
  toggleMute: () => {
3522
3522
  const b = !N.current;
3523
- N.current = b, o.current && (o.current.muted = b || p.current), M(b);
3523
+ N.current = b, o.current && (o.current.muted = b || p.current), g(b);
3524
3524
  },
3525
3525
  toggle: pe,
3526
3526
  seekRow: le,
@@ -3531,12 +3531,12 @@ function Vl(t, e, n, r, s = 0, a = null) {
3531
3531
  seekN: ae,
3532
3532
  stop: () => {
3533
3533
  const b = o.current;
3534
- b && (b.pause(), b.currentTime = z.current), d(0);
3534
+ b && (b.pause(), b.currentTime = I.current), d(0);
3535
3535
  },
3536
3536
  videoAt: (b) => {
3537
3537
  const H = o.current;
3538
3538
  if (!H || H.paused || H.ended || we.current || Date.now() - _e.current < 3e3) return;
3539
- const ce = b + z.current;
3539
+ const ce = b + I.current;
3540
3540
  Math.abs(H.currentTime - ce) <= 0.2 || (_e.current = Date.now(), H.currentTime = ce);
3541
3541
  },
3542
3542
  engaged: l || u > 0,
@@ -3564,11 +3564,11 @@ function Vl(t, e, n, r, s = 0, a = null) {
3564
3564
  function Hl(t, e, n, r, s, a, o = !1, l) {
3565
3565
  const c = v(/* @__PURE__ */ new Set());
3566
3566
  c.current = l ?? c.current;
3567
- const u = v(null), [d, g] = I(!1), [M, N] = I(0), [p, y] = I(0), [L, m] = I(!1), f = v(L);
3567
+ const u = v(null), [d, M] = z(!1), [g, N] = z(0), [p, y] = z(0), [L, m] = z(!1), f = v(L);
3568
3568
  f.current = L;
3569
- const [z, C] = I(null), [D, V] = I(null), [_, ee] = I(null), [j, E] = I(null), Q = v(j);
3569
+ const [I, C] = z(null), [D, V] = z(null), [_, ee] = z(null), [j, E] = z(null), Q = v(j);
3570
3570
  Q.current = j;
3571
- const [T, O] = I(null), [S, re] = I(null), [K, k] = I(null), [ae, te] = I(!1), G = v(e);
3571
+ const [T, O] = z(null), [S, re] = z(null), [K, k] = z(null), [ae, te] = z(!1), G = v(e);
3572
3572
  G.current = e;
3573
3573
  const J = v(o), pe = v([]);
3574
3574
  J.current = o, u.current && (u.current.flow = o);
@@ -3578,24 +3578,24 @@ function Hl(t, e, n, r, s, a, o = !1, l) {
3578
3578
  je.current = a;
3579
3579
  const Ee = Ke((Y) => {
3580
3580
  Y.finite = !0, Y.coming = (R) => c.current.has(R), Y.readAhead = 6, Y.readAheadS = 45, Y.onWaiting = (R) => V(R), Y.onStarting = (R) => ee(R), Y.onSentence = (R) => {
3581
- if (g(Y.playing), R == null) return;
3581
+ if (M(Y.playing), R == null) return;
3582
3582
  const q = G.current.findIndex((ne) => ne.sentenceId === R);
3583
3583
  q >= 0 && N(q);
3584
3584
  }, Y.onError = (R) => {
3585
- g(Y.playing), C(R instanceof ui ? { message: "The voice could not be started. Press Play to try again.", code: "voice_not_started" } : { message: "A line of this reading could not be played." });
3585
+ M(Y.playing), C(R instanceof ui ? { message: "The voice could not be started. Press Play to try again.", code: "voice_not_started" } : { message: "A line of this reading could not be played." });
3586
3586
  }, Y.gapBefore = (R, q) => {
3587
3587
  if (!J.current) return 0;
3588
3588
  const ne = G.current, de = ne.find((Ce) => Ce.sentenceId === R), Oe = ne.find((Ce) => Ce.sentenceId === q);
3589
3589
  if (!Oe) return 0;
3590
3590
  const ye = Q.current;
3591
3591
  if (R == null) return ye && ye.sid === q ? Math.max(0, Oe.start - ye.t) : 0;
3592
- const ve = le.current;
3593
- return ve && Date.now() - ve.at < 2e3 ? Math.max(0, Oe.start - (ve.t + (Date.now() - ve.at) / 1e3 * Y.rate)) : !de || Oe.start <= de.start ? 0 : Math.max(0, Oe.start - At(de, de.start, de.start + 4));
3592
+ const ke = le.current;
3593
+ return ke && Date.now() - ke.at < 2e3 ? Math.max(0, Oe.start - (ke.t + (Date.now() - ke.at) / 1e3 * Y.rate)) : !de || Oe.start <= de.start ? 0 : Math.max(0, Oe.start - At(de, de.start, de.start + 4));
3594
3594
  }, Y.flow = J.current, Y.silentSpan = (R) => {
3595
3595
  var $e;
3596
3596
  const q = G.current, ne = q.findIndex((ot) => ot.sentenceId === R), de = q[ne];
3597
3597
  if (!de) return null;
3598
- const Oe = (($e = q[ne + 1]) == null ? void 0 : $e.start) ?? At(de, de.start, de.start + 4), ye = Math.max(0, Oe - de.start), ve = le.current, Ce = ve && Date.now() - ve.at < 2e3 ? ve.t + (Date.now() - ve.at) / 1e3 * (Y.rate || 1) : de.start, Ze = Math.max(0, Math.min(ye, Ce - de.start));
3598
+ const Oe = (($e = q[ne + 1]) == null ? void 0 : $e.start) ?? At(de, de.start, de.start + 4), ye = Math.max(0, Oe - de.start), ke = le.current, Ce = ke && Date.now() - ke.at < 2e3 ? ke.t + (Date.now() - ke.at) / 1e3 * (Y.rate || 1) : de.start, Ze = Math.max(0, Math.min(ye, Ce - de.start));
3599
3599
  return { fromS: Ze, ms: (ye - Ze) * 1e3 / (Y.rate || 1) };
3600
3600
  }, Y.speakable = (R) => {
3601
3601
  const q = Te.current;
@@ -3603,7 +3603,7 @@ function Hl(t, e, n, r, s, a, o = !1, l) {
3603
3603
  const ne = G.current.find((de) => de.sentenceId === R);
3604
3604
  return !ne || !q.has(ne.speaker);
3605
3605
  };
3606
- }, []), Le = v(null), we = v(null), _e = v(null), [Pe, Se] = I(!1), B = v(() => {
3606
+ }, []), Le = v(null), we = v(null), _e = v(null), [Pe, Se] = z(!1), B = v(() => {
3607
3607
  }), W = (Y) => {
3608
3608
  if (_e.current = Y, Se(!!(Y != null && Y.playing)), !Y) return;
3609
3609
  const R = Ln(Y, G.current, ze).index;
@@ -3615,7 +3615,7 @@ function Hl(t, e, n, r, s, a, o = !1, l) {
3615
3615
  var q;
3616
3616
  if (Le.current !== r) {
3617
3617
  const ne = Le.current != null ? we.current : null;
3618
- Le.current = r, (q = u.current) == null || q.stop(), u.current = new fr(), Ee(u.current), u.current.setSequence(pe.current), g(!1), N(0), C(null), ee(null), E(null), W(ne && (ne.playing || ne.t > 0) ? ne : null);
3618
+ Le.current = r, (q = u.current) == null || q.stop(), u.current = new fr(), Ee(u.current), u.current.setSequence(pe.current), M(!1), N(0), C(null), ee(null), E(null), W(ne && (ne.playing || ne.t > 0) ? ne : null);
3619
3619
  }
3620
3620
  const Y = u.current;
3621
3621
  Y.setMuted(f.current);
@@ -3638,12 +3638,12 @@ function Hl(t, e, n, r, s, a, o = !1, l) {
3638
3638
  return;
3639
3639
  }
3640
3640
  const Y = () => {
3641
- var ye, ve;
3641
+ var ye, ke;
3642
3642
  const q = ((ye = u.current) == null ? void 0 : ye.resting()) ?? null;
3643
3643
  te(!!(q != null && q.silent)), q != null && q.silent && Q.current && (Q.current = null, E(null)), re((Ce) => q == null ? null : Ce != null && Math.abs(Ce - q.s) < 0.05 ? Ce : q.s);
3644
3644
  const ne = Q.current;
3645
3645
  q == null ? k(null) : ne && ne.sid === q.sentenceId && (k(ne.t), Q.current = null, E(null));
3646
- const de = ((ve = u.current) == null ? void 0 : ve.position()) ?? null, Oe = de && je.current ? je.current[String(de.sentenceId)] ?? null : null;
3646
+ const de = ((ke = u.current) == null ? void 0 : ke.position()) ?? null, Oe = de && je.current ? je.current[String(de.sentenceId)] ?? null : null;
3647
3647
  ne && de && de.sentenceId === ne.sid && de.t > 0.1 && E(null), O((Ce) => de ? Ce && Math.abs(Ce.t - de.t) < 0.05 && Ce.dur === de.dur && Ce.words === Oe ? Ce : { t: de.t, dur: de.dur, words: Oe } : Ce == null ? Ce : null);
3648
3648
  };
3649
3649
  Y();
@@ -3657,15 +3657,15 @@ function Hl(t, e, n, r, s, a, o = !1, l) {
3657
3657
  }, me = (Y, R) => {
3658
3658
  for (let q = Y; q >= 0 && q < e.length; q += R) if (F(q)) return q;
3659
3659
  return null;
3660
- }, Z = Math.max(0, Math.min(M, Math.max(0, e.length - 1))), ke = e.length ? e[e.length - 1].start + 4 : 0, ze = n || ke || 1, Ge = v(!1), Ae = v(M);
3661
- Ae.current = M;
3660
+ }, Z = Math.max(0, Math.min(g, Math.max(0, e.length - 1))), ve = e.length ? e[e.length - 1].start + 4 : 0, ze = n || ve || 1, Ge = v(!1), Ae = v(g);
3661
+ Ae.current = g;
3662
3662
  const ge = (Y) => {
3663
3663
  var R, q, ne;
3664
- (q = u.current) == null || q.play(((R = e[Y]) == null ? void 0 : R.sentenceId) ?? null), g(!!((ne = u.current) != null && ne.playing));
3664
+ (q = u.current) == null || q.play(((R = e[Y]) == null ? void 0 : R.sentenceId) ?? null), M(!!((ne = u.current) != null && ne.playing));
3665
3665
  }, Ye = (Y) => {
3666
3666
  var q, ne, de;
3667
3667
  const R = Math.max(0, Math.min(Math.max(0, e.length - 1), Y));
3668
- N(R), Ae.current = R, y((Oe) => Oe + 1), (ne = u.current) == null || ne.seek(((q = e[R]) == null ? void 0 : q.sentenceId) ?? null), g(!!((de = u.current) != null && de.playing));
3668
+ N(R), Ae.current = R, y((Oe) => Oe + 1), (ne = u.current) == null || ne.seek(((q = e[R]) == null ? void 0 : q.sentenceId) ?? null), M(!!((de = u.current) != null && de.playing));
3669
3669
  }, Ve = (Y) => {
3670
3670
  var R;
3671
3671
  A(), E(null), (R = u.current) == null || R.startWithin(-1, 0), Ye(Y);
@@ -3694,7 +3694,7 @@ function Hl(t, e, n, r, s, a, o = !1, l) {
3694
3694
  preparing: D != null || Pe,
3695
3695
  silent: d && ae,
3696
3696
  starting: _,
3697
- error: z,
3697
+ error: I,
3698
3698
  seekN: p,
3699
3699
  toggleMute: () => {
3700
3700
  var R;
@@ -3708,24 +3708,24 @@ function Hl(t, e, n, r, s, a, o = !1, l) {
3708
3708
  return;
3709
3709
  }
3710
3710
  if (A(), d) {
3711
- (R = u.current) == null || R.pause(), g(!1);
3711
+ (R = u.current) == null || R.pause(), M(!1);
3712
3712
  return;
3713
3713
  }
3714
3714
  C(null);
3715
3715
  const Y = Ae.current;
3716
3716
  if (!Q.current && ((ne = u.current) != null && ne.resume(((q = e[Y]) == null ? void 0 : q.sentenceId) ?? null))) {
3717
- g(!0);
3717
+ M(!0);
3718
3718
  return;
3719
3719
  }
3720
3720
  ge(Y);
3721
3721
  },
3722
3722
  pause: () => {
3723
3723
  var Y;
3724
- A(), (Y = u.current) == null || Y.pause(), g(!1);
3724
+ A(), (Y = u.current) == null || Y.pause(), M(!1);
3725
3725
  },
3726
3726
  stop: () => {
3727
3727
  var Y, R, q;
3728
- A(), (Y = u.current) == null || Y.pause(), g(!1), N(0), O(null), (q = u.current) == null || q.seek(((R = e[0]) == null ? void 0 : R.sentenceId) ?? null);
3728
+ A(), (Y = u.current) == null || Y.pause(), M(!1), N(0), O(null), (q = u.current) == null || q.seek(((R = e[0]) == null ? void 0 : R.sentenceId) ?? null);
3729
3729
  },
3730
3730
  seekRow: Ve,
3731
3731
  resumeAt: (Y) => {
@@ -3745,8 +3745,8 @@ function Hl(t, e, n, r, s, a, o = !1, l) {
3745
3745
  Q.current = He, E(He), Ye(be);
3746
3746
  return;
3747
3747
  }
3748
- const Oe = (ne == null ? void 0 : ne.sentenceId) ?? null, { from: ye, span: ve } = $(q);
3749
- let Ce = ve > 0 ? Math.max(0, Math.min(1, (R - ye) / ve)) : 0;
3748
+ const Oe = (ne == null ? void 0 : ne.sentenceId) ?? null, { from: ye, span: ke } = $(q);
3749
+ let Ce = ke > 0 ? Math.max(0, Math.min(1, (R - ye) / ke)) : 0;
3750
3750
  const Ze = Oe != null ? (rt = je.current) == null ? void 0 : rt[String(Oe)] : void 0, $e = Ze != null && Ze.length ? Ze[Ze.length - 1][1] : 0;
3751
3751
  if (ne && Ze && Ze.length === ne.words.length && $e > 0) {
3752
3752
  let be = 0;
@@ -3757,11 +3757,11 @@ function Hl(t, e, n, r, s, a, o = !1, l) {
3757
3757
  Oe != null && ((gt = u.current) == null || gt.startWithin(Oe, Ce)), E(Ce > 0.01 ? { t: R, sid: Oe } : null), Ye(q);
3758
3758
  },
3759
3759
  seekWord: a ? (Y) => {
3760
- var de, Oe, ye, ve;
3760
+ var de, Oe, ye, ke;
3761
3761
  const R = e[Z];
3762
3762
  if (!R || R.sentenceId == null) return;
3763
3763
  const q = R.words.findIndex((Ce) => Ce.seq === Y.seq && Ce.idx === Y.idx), ne = q >= 0 ? (ye = (Oe = (de = je.current) == null ? void 0 : de[String(R.sentenceId)]) == null ? void 0 : Oe[q]) == null ? void 0 : ye[0] : void 0;
3764
- ne != null && ((ve = u.current) == null || ve.seekWithin(ne));
3764
+ ne != null && ((ke = u.current) == null || ke.seekWithin(ne));
3765
3765
  } : void 0,
3766
3766
  playRow: (Y) => {
3767
3767
  var q;
@@ -3796,7 +3796,7 @@ function Hl(t, e, n, r, s, a, o = !1, l) {
3796
3796
  if (R == null) return;
3797
3797
  N(Y), Ae.current = Y, E(null), Q.current = null, (de = u.current) == null || de.joinSilently(R);
3798
3798
  const q = ((Oe = u.current) == null ? void 0 : Oe.resting()) ?? null;
3799
- re((q == null ? void 0 : q.s) ?? null), te(!!(q != null && q.silent)), g(!!((ye = u.current) != null && ye.playing));
3799
+ re((q == null ? void 0 : q.s) ?? null), te(!!(q != null && q.silent)), M(!!((ye = u.current) != null && ye.playing));
3800
3800
  }
3801
3801
  return fe.joinAt = o ? (Y) => {
3802
3802
  A(), Ue(Ln({ t: Y, playing: !0, sentenceId: null, offset: 0, ended: !1 }, e, ze).index);
@@ -3812,23 +3812,23 @@ function Hl(t, e, n, r, s, a, o = !1, l) {
3812
3812
  }
3813
3813
  const Wl = () => {
3814
3814
  }, Fl = "The language this recording is read aloud in.", Gl = { title: "READ IN", note: "The transcript and its voice switch to this language." };
3815
- function Zl({ recordingId: t, model: e, rows: n, lenS: r, ended: s, cred: a, langs: o, srcLang: l, canTranslate: c, pickedLang: u, setPickedLang: d, side: g, hearOriginal: M = !1, timed: N = !1, stockVoices: p = !1, stickyPicker: y = !1, pickerBusy: L = null, voiceSheet: m, forcedVoice: f = null }) {
3815
+ function Zl({ recordingId: t, model: e, rows: n, lenS: r, ended: s, cred: a, langs: o, srcLang: l, canTranslate: c, pickedLang: u, setPickedLang: d, side: M, hearOriginal: g = !1, timed: N = !1, stockVoices: p = !1, stickyPicker: y = !1, pickerBusy: L = null, voiceSheet: m, forcedVoice: f = null }) {
3816
3816
  var on, Gt, Zt, qt;
3817
- const { onAddVoice: z, onPickVoice: C, onSelectSpeaker: D, noCloneFor: V, castNoClone: _, castShort: ee, castBuilding: j, castWarn: E, badge: Q, titleNode: T } = m ?? {}, O = !!m, S = !!(m != null && m.pendingClones), [re, K] = gi(), [k, ae] = I(null), [te, G] = I(!1), [J, pe] = I(!1), [le, Te] = I(!1), [je, Ee] = I(!1), Le = u ?? l, we = u === null, _e = u != null || k != null, Se = ((P) => !!P && !!(o != null && o.voice.includes(P)))(we ? l : Le) ? we ? l : Le : "en", B = Dl(Se), W = (m == null ? void 0 : m.cloneOn) ?? !0, [A, b] = I(0), H = v(W);
3817
+ const { onAddVoice: I, onPickVoice: C, onSelectSpeaker: D, noCloneFor: V, castNoClone: _, castShort: ee, castBuilding: j, castWarn: E, badge: Q, titleNode: T } = m ?? {}, O = !!m, S = !!(m != null && m.pendingClones), [re, K] = gi(), [k, ae] = z(null), [te, G] = z(!1), [J, pe] = z(!1), [le, Te] = z(!1), [je, Ee] = z(!1), Le = u ?? l, we = u === null, _e = u != null || k != null, Se = ((P) => !!P && !!(o != null && o.voice.includes(P)))(we ? l : Le) ? we ? l : Le : "en", B = Dl(Se), W = (m == null ? void 0 : m.cloneOn) ?? !0, [A, b] = z(0), H = v(W);
3818
3818
  U(() => {
3819
3819
  H.current !== W && (H.current = W, b((P) => P + 1));
3820
3820
  }, [W]);
3821
- const ce = dl(Se, _e || s || J, hl(e) * 1e3 + A, { id: t ?? null, shareCode: a.shareCode ?? null }), F = Ie(() => ((ce == null ? void 0 : ce.voices) ?? []).filter((P) => O || !P.cloned || P.speaker != null), [ce, O]), me = F.length > 1, Z = wr(o, Le), ke = vi(), ze = Ie(() => fi(o, "translation"), [o]), [Ge, Ae] = I(null), [ge] = I(() => /* @__PURE__ */ new Set()), [Ye, Ve] = I({}), $ = Ie(() => al(n, e, ke.vcUnknownSpk), [n, e, ke]), he = me && $.filter((P) => P.key >= 0).length > 1, ue = Ge != null && $.some((P) => P.key === Ge) ? Ge : ((on = $[0]) == null ? void 0 : on.key) ?? null, ie = Ie(() => {
3821
+ const ce = dl(Se, _e || s || J, hl(e) * 1e3 + A, { id: t ?? null, shareCode: a.shareCode ?? null }), F = Ie(() => ((ce == null ? void 0 : ce.voices) ?? []).filter((P) => O || !P.cloned || P.speaker != null), [ce, O]), me = F.length > 1, Z = wr(o, Le), ve = ki(), ze = Ie(() => fi(o, "translation"), [o]), [Ge, Ae] = z(null), [ge] = z(() => /* @__PURE__ */ new Set()), [Ye, Ve] = z({}), $ = Ie(() => al(n, e, ve.vcUnknownSpk), [n, e, ve]), he = me && $.filter((P) => P.key >= 0).length > 1, ue = Ge != null && $.some((P) => P.key === Ge) ? Ge : ((on = $[0]) == null ? void 0 : on.key) ?? null, ie = Ie(() => {
3822
3822
  const P = Gs($, F, W);
3823
3823
  for (const [De, Be] of Object.entries(Ye[Se ?? ""] ?? {})) P.set(Number(De), Be);
3824
3824
  return P;
3825
- }, [$, F, Ye, Se, W]), fe = he && Object.keys(Ye[Se ?? ""] ?? {}).length > 0, Ue = Ie(() => p && !fe ? Gs($, F, !1) : null, [p, fe, $, F]), Y = Ie(() => fe ? Ws(ie) || null : Ue && Ws(Ue) || null, [fe, ie, Ue]), R = fe ? ie : Ue, q = F.some((P) => P.cloned && P.consent !== "pending"), ne = !!Le && !!(o != null && o.voice.includes(Le)), de = ne && !M, Oe = Ie(
3825
+ }, [$, F, Ye, Se, W]), fe = he && Object.keys(Ye[Se ?? ""] ?? {}).length > 0, Ue = Ie(() => p && !fe ? Gs($, F, !1) : null, [p, fe, $, F]), Y = Ie(() => fe ? Ws(ie) || null : Ue && Ws(Ue) || null, [fe, ie, Ue]), R = fe ? ie : Ue, q = F.some((P) => P.cloned && P.consent !== "pending"), ne = !!Le && !!(o != null && o.voice.includes(Le)), de = ne && !g, Oe = Ie(
3826
3826
  () => n.filter((P) => !P.suppressed && !P.unclear).map((P) => P.sentenceId).filter((P) => P != null),
3827
3827
  [n]
3828
- ), ye = Ml({ recordingId: t, lang: Le, ended: s, cred: a, pickedVoice: f || (Y ?? k), sentenceIds: s && de ? Oe : void 0 }), ve = F.find((P) => P.id === k) ?? F.find((P) => {
3828
+ ), ye = Ml({ recordingId: t, lang: Le, ended: s, cred: a, pickedVoice: f || (Y ?? k), sentenceIds: s && de ? Oe : void 0 }), ke = F.find((P) => P.id === k) ?? F.find((P) => {
3829
3829
  var De;
3830
3830
  return P.id === ((De = ye.track) == null ? void 0 : De.voice);
3831
- }) ?? F.find((P) => P.default) ?? F[0] ?? null, Ce = (ve == null ? void 0 : ve.id) ?? null;
3831
+ }) ?? F.find((P) => P.default) ?? F[0] ?? null, Ce = (ke == null ? void 0 : ke.id) ?? null;
3832
3832
  U(() => {
3833
3833
  if (!ye.rendering) return;
3834
3834
  const P = setInterval(ye.reload, 4e3);
@@ -3855,7 +3855,7 @@ function Zl({ recordingId: t, model: e, rows: n, lenS: r, ended: s, cred: a, lan
3855
3855
  }, it = () => G(!0), lt = () => {
3856
3856
  G(!1), pe(le), Te(!1);
3857
3857
  }, Ht = (P) => {
3858
- if (d(P), K(P), !((g || y) && !le)) {
3858
+ if (d(P), K(P), !((M || y) && !le)) {
3859
3859
  if (P != null) {
3860
3860
  lt();
3861
3861
  return;
@@ -3885,7 +3885,7 @@ function Zl({ recordingId: t, model: e, rows: n, lenS: r, ended: s, cred: a, lan
3885
3885
  return;
3886
3886
  }
3887
3887
  ae(P);
3888
- }, ct = we ? { ...wr(o, null), flag: /* @__PURE__ */ i(oe, { d: X.langAuto, size: 21, sw: 1.7, style: { color: "currentColor", display: "block" } }) } : Z, nn = c ? g ? /* @__PURE__ */ i("span", { className: "barchip", style: x ? { background: "var(--brand-tint)", boxShadow: "0 0 0 1.5px var(--brand)" } : void 0, children: /* @__PURE__ */ i(zn, { flag: ct.flag, code: ct.code, bordered: !1, onClick: Lt, flagOnly: !0, label: ct.label }) }) : /* @__PURE__ */ i(zn, { flag: ct.flag, code: ct.code, bordered: !1, onClick: it, flagOnly: !0, label: ct.label }) : null, Je = X.voiceClone, ut = _e && (!!ye.track || ot), Ft = rt ? "var(--conf-low)" : ut || g && wt ? "var(--brand)" : "var(--ink-55)", dt = ot || !!$e.preparing && _e, kt = $e.preparing ? `Speaking this line in ${(ve == null ? void 0 : ve.name) ?? "this voice"}…` : ot ? `Preparing this recording in ${(ve == null ? void 0 : ve.name) ?? "this voice"} — it will play as soon as it is ready` : rt ? `This voice could not be prepared: ${rt}` : ne ? me ? "Choose a voice" : ve ? ve.name : ke.vcNoVoice + Z.label : `${ke.vcNoVoice}${Z.label}`, rn = /* @__PURE__ */ i($a, { open: te, onClose: lt, keepOpen: (!!g || y) && !le, value: we ? null : Le, onSelect: Ht, languages: ze, title: (g == null ? void 0 : g.title) ?? "SPOKEN LANGUAGE", note: (g == null ? void 0 : g.note) ?? Fl, searchPlaceholder: ke.search, none: "Original", pinned: (we ? l : Le) ? [we ? l : Le] : [], recent: re, requireVoice: le, sticky: y, busy: L }), bt = Ie(() => F.filter((P) => P.cloned && !P.auto), [F]), _t = (P) => P.voiceId ? bt.find((De) => De.id === `clone:${P.voiceId}`) ?? null : null, ht = Ie(() => $.filter((P) => P.key >= 0), [$]), Yt = Ie(() => {
3888
+ }, ct = we ? { ...wr(o, null), flag: /* @__PURE__ */ i(oe, { d: X.langAuto, size: 21, sw: 1.7, style: { color: "currentColor", display: "block" } }) } : Z, nn = c ? M ? /* @__PURE__ */ i("span", { className: "barchip", style: x ? { background: "var(--brand-tint)", boxShadow: "0 0 0 1.5px var(--brand)" } : void 0, children: /* @__PURE__ */ i(zn, { flag: ct.flag, code: ct.code, bordered: !1, onClick: Lt, flagOnly: !0, label: ct.label }) }) : /* @__PURE__ */ i(zn, { flag: ct.flag, code: ct.code, bordered: !1, onClick: it, flagOnly: !0, label: ct.label }) : null, Je = X.voiceClone, ut = _e && (!!ye.track || ot), Ft = rt ? "var(--conf-low)" : ut || M && wt ? "var(--brand)" : "var(--ink-55)", dt = ot || !!$e.preparing && _e, vt = $e.preparing ? `Speaking this line in ${(ke == null ? void 0 : ke.name) ?? "this voice"}…` : ot ? `Preparing this recording in ${(ke == null ? void 0 : ke.name) ?? "this voice"} — it will play as soon as it is ready` : rt ? `This voice could not be prepared: ${rt}` : ne ? me ? "Choose a voice" : ke ? ke.name : ve.vcNoVoice + Z.label : `${ve.vcNoVoice}${Z.label}`, rn = /* @__PURE__ */ i($a, { open: te, onClose: lt, keepOpen: (!!M || y) && !le, value: we ? null : Le, onSelect: Ht, languages: ze, title: (M == null ? void 0 : M.title) ?? "SPOKEN LANGUAGE", note: (M == null ? void 0 : M.note) ?? Fl, searchPlaceholder: ve.search, none: "Original", pinned: (we ? l : Le) ? [we ? l : Le] : [], recent: re, requireVoice: le, sticky: y, busy: L }), bt = Ie(() => F.filter((P) => P.cloned && !P.auto), [F]), _t = (P) => P.voiceId ? bt.find((De) => De.id === `clone:${P.voiceId}`) ?? null : null, ht = Ie(() => $.filter((P) => P.key >= 0), [$]), Yt = Ie(() => {
3889
3889
  const P = F.filter((Be) => !Be.cloned);
3890
3890
  if (!he) return [...P, ...s && ht.length === 1 ? bt.filter((Be) => Be.id === `clone:${ht[0].voiceId}`) : []];
3891
3891
  const De = [];
@@ -3898,17 +3898,17 @@ function Zl({ recordingId: t, model: e, rows: n, lenS: r, ended: s, cred: a, lan
3898
3898
  }, [F, bt, he, ht, S, s]), Xe = he ? ht.find((P) => P.key === ue) ?? null : null, qe = (P) => {
3899
3899
  var De;
3900
3900
  return P ? ((De = F.find((Be) => Be.id === P)) == null ? void 0 : De.gender) ?? null : null;
3901
- }, Ut = Xe ? Xe.sex ?? qe(ie.get(Xe.key)) : null, sn = Ie(() => Xe ? Yt.filter((P) => P.cloned ? P.live ? P.speaker === Xe.key : P.id === `clone:${Xe.voiceId}` : !0) : Yt, [Yt, Xe, Ut, ht]), Rt = (P) => F.find((De) => De.cloned && De.auto && De.speaker === P) ?? null, We = { people: ht, gvList: F, autoOf: Rt, savedFor: _t }, xt = (Q == null ? void 0 : Q(We)) ?? 0, vt = E ? ht.map((P) => E(P, We)).filter((P) => !!P) : [], Dn = /* @__PURE__ */ h("button", { type: "button", className: "txvoice", "aria-label": "Voice", "aria-pressed": g ? wt : void 0, title: dt || rt ? kt : void 0, style: { cursor: "pointer", background: ut || dt || g && wt ? "var(--brand-tint)" : "var(--fill-06)", boxShadow: g && wt ? "inset 0 0 0 1.5px var(--brand)" : void 0 }, onClick: g ? Ot : se, children: [
3901
+ }, Ut = Xe ? Xe.sex ?? qe(ie.get(Xe.key)) : null, sn = Ie(() => Xe ? Yt.filter((P) => P.cloned ? P.live ? P.speaker === Xe.key : P.id === `clone:${Xe.voiceId}` : !0) : Yt, [Yt, Xe, Ut, ht]), Rt = (P) => F.find((De) => De.cloned && De.auto && De.speaker === P) ?? null, We = { people: ht, gvList: F, autoOf: Rt, savedFor: _t }, xt = (Q == null ? void 0 : Q(We)) ?? 0, kt = E ? ht.map((P) => E(P, We)).filter((P) => !!P) : [], Dn = /* @__PURE__ */ h("button", { type: "button", className: "txvoice", "aria-label": "Voice", "aria-pressed": M ? wt : void 0, title: dt || rt ? vt : void 0, style: { cursor: "pointer", background: ut || dt || M && wt ? "var(--brand-tint)" : "var(--fill-06)", boxShadow: M && wt ? "inset 0 0 0 1.5px var(--brand)" : void 0 }, onClick: M ? Ot : se, children: [
3902
3902
  dt ? /* @__PURE__ */ i("span", { style: { width: 16, height: 16, borderRadius: "50%", border: "2px solid var(--fill-10)", borderTopColor: "var(--brand)", animation: "vs-spin .7s linear infinite" } }) : /* @__PURE__ */ i(oe, { d: Je, size: 17, sw: 1.6, style: { color: Ft } }),
3903
- vt.length > 0 ? /* @__PURE__ */ i("span", { className: "txvoice__warn", title: vt.join(" · "), children: "!" }) : !!xt && /* @__PURE__ */ i("span", { className: "txvoice__n", title: `${xt} speaker${xt === 1 ? "" : "s"} can get a cloned voice`, children: xt })
3904
- ] }), an = /* @__PURE__ */ i(Vt, { open: J, onClose: Wt, title: ke.vcSheet, titleNode: T, doneLabel: ke.done, children: /* @__PURE__ */ i(
3903
+ kt.length > 0 ? /* @__PURE__ */ i("span", { className: "txvoice__warn", title: kt.join(" · "), children: "!" }) : !!xt && /* @__PURE__ */ i("span", { className: "txvoice__n", title: `${xt} speaker${xt === 1 ? "" : "s"} can get a cloned voice`, children: xt })
3904
+ ] }), an = /* @__PURE__ */ i(Vt, { open: J, onClose: Wt, title: ve.vcSheet, titleNode: T, doneLabel: ve.done, children: /* @__PURE__ */ i(
3905
3905
  ll,
3906
3906
  {
3907
- t: ke,
3907
+ t: ve,
3908
3908
  cast: he && /* @__PURE__ */ i(
3909
3909
  ol,
3910
3910
  {
3911
- t: ke,
3911
+ t: ve,
3912
3912
  roster: $,
3913
3913
  selected: ue,
3914
3914
  onSelect: (P) => {
@@ -3923,7 +3923,7 @@ function Zl({ recordingId: t, model: e, rows: n, lenS: r, ended: s, cred: a, lan
3923
3923
  ),
3924
3924
  voices: sn,
3925
3925
  onAdd: (P) => {
3926
- B.reset(), z == null || z(P);
3926
+ B.reset(), I == null || I(P);
3927
3927
  },
3928
3928
  noClone: Xe && !sn.some((P) => P.cloned) ? (V == null ? void 0 : V(Xe, Rt(Xe.key), We)) ?? null : null,
3929
3929
  usedBy: he && ue != null ? (P) => {
@@ -3949,12 +3949,12 @@ function Zl({ recordingId: t, model: e, rows: n, lenS: r, ended: s, cred: a, lan
3949
3949
  },
3950
3950
  onUse: Ct
3951
3951
  }
3952
- ) }), jt = g ? null : /* @__PURE__ */ h(xe, { children: [
3952
+ ) }), jt = M ? null : /* @__PURE__ */ h(xe, { children: [
3953
3953
  rn,
3954
3954
  an
3955
- ] }), Sn = g && (te || J) ? /* @__PURE__ */ i("div", { className: "vs-side", children: te ? rn : an }) : null, An = be && rt ? `This voice could not be prepared: ${rt}` : null, En = gt;
3955
+ ] }), Sn = M && (te || J) ? /* @__PURE__ */ i("div", { className: "vs-side", children: te ? rn : an }) : null, An = be && rt ? `This voice could not be prepared: ${rt}` : null, En = gt;
3956
3956
  return {
3957
- barChip: { flag: ct.flag, code: ct.code, label: ct.label, onClick: g || y ? Lt : it, active: !!((g || y) && x), can: c },
3957
+ barChip: { flag: ct.flag, code: ct.code, label: ct.label, onClick: M || y ? Lt : it, active: !!((M || y) && x), can: c },
3958
3958
  sheetsOpen: te || J,
3959
3959
  on: be,
3960
3960
  player: He,
@@ -3991,7 +3991,7 @@ function Zl({ recordingId: t, model: e, rows: n, lenS: r, ended: s, cred: a, lan
3991
3991
  readLang: typeof u == "string" && u !== l ? u : null,
3992
3992
  readVoiceKey: f || (Y ?? k ?? ((qt = ye.track) == null ? void 0 : qt.voiceKey) ?? ""),
3993
3993
  pickedVoiceKey: Y ?? k ?? null,
3994
- readVoiceName: (ve == null ? void 0 : ve.name) ?? null,
3994
+ readVoiceName: (ke == null ? void 0 : ke.name) ?? null,
3995
3995
  canSpeak: ne,
3996
3996
  requestTrack: () => ye.requestRender(Y ?? k, Y ? R : null),
3997
3997
  hasClone: q,
@@ -4000,15 +4000,15 @@ function Zl({ recordingId: t, model: e, rows: n, lenS: r, ended: s, cred: a, lan
4000
4000
  closePicker: () => {
4001
4001
  x && lt();
4002
4002
  },
4003
- langList: { value: we ? null : Le, onSelect: Ht, languages: ze, searchPlaceholder: ke.search, none: "Original", pinned: (we ? l : Le) ? [we ? l : Le] : [], recent: re }
4003
+ langList: { value: we ? null : Le, onSelect: Ht, languages: ze, searchPlaceholder: ve.search, none: "Original", pinned: (we ? l : Le) ? [we ? l : Le] : [], recent: re }
4004
4004
  };
4005
4005
  }
4006
- function ql({ model: t, rows: e, player: n, fixed: r, applied: s, onFixOpen: a, onWord: o, onFix: l, fixMode: c, fixingId: u, marks: d = !0, fixBadges: g = !0, tail: M, tailFg: N, running: p, desk: y, feedRef: L, listener: m, showLabels: f, find: z, findOpen: C, lang: D, warm: V, onVisible: _, wordHl: ee = !0 }) {
4006
+ function ql({ model: t, rows: e, player: n, fixed: r, applied: s, onFixOpen: a, onWord: o, onFix: l, fixMode: c, fixingId: u, marks: d = !0, fixBadges: M = !0, tail: g, tailFg: N, running: p, desk: y, feedRef: L, listener: m, showLabels: f, find: I, findOpen: C, lang: D, warm: V, onVisible: _, wordHl: ee = !0 }) {
4007
4007
  const { playing: j, engaged: E, t: Q, idx: T, seekN: O, wordSync: S, clipPos: re } = n;
4008
4008
  Ll(!0, L);
4009
4009
  const K = v(null);
4010
4010
  qo(L, K);
4011
- const [k, ae] = I(null), te = (z ?? "").trim().toLowerCase(), [G, J] = I(0), pe = v(0), le = v(null), Te = v(T), je = (W) => {
4011
+ const [k, ae] = z(null), te = (I ?? "").trim().toLowerCase(), [G, J] = z(0), pe = v(0), le = v(null), Te = v(T), je = (W) => {
4012
4012
  var A;
4013
4013
  return ((A = L.current) == null ? void 0 : A.querySelector(`[data-tx-row="${W}"]`)) ?? null;
4014
4014
  }, Ee = v("");
@@ -4017,9 +4017,9 @@ function ql({ model: t, rows: e, player: n, fixed: r, applied: s, onFixOpen: a,
4017
4017
  if (!W || !_) return;
4018
4018
  const A = () => {
4019
4019
  const F = W.getBoundingClientRect(), me = [];
4020
- for (const ke of Array.from(W.querySelectorAll("[data-sentence]"))) {
4021
- const ze = ke.getBoundingClientRect();
4022
- ze.bottom > F.top && ze.top < F.bottom && me.push(Number(ke.dataset.sentence));
4020
+ for (const ve of Array.from(W.querySelectorAll("[data-sentence]"))) {
4021
+ const ze = ve.getBoundingClientRect();
4022
+ ze.bottom > F.top && ze.top < F.bottom && me.push(Number(ve.dataset.sentence));
4023
4023
  }
4024
4024
  const Z = me.join(",");
4025
4025
  Z !== Ee.current && (Ee.current = Z, _(me));
@@ -4046,7 +4046,7 @@ function ql({ model: t, rows: e, player: n, fixed: r, applied: s, onFixOpen: a,
4046
4046
  pe.current = performance.now() + 420;
4047
4047
  const A = L.current, b = je(W);
4048
4048
  if (!A || !A.clientHeight || !b) return;
4049
- const H = b.getBoundingClientRect(), ce = A.getBoundingClientRect(), F = A.scrollHeight - A.clientHeight, me = A.scrollTop, Z = lr(A), ke = Math.max(80, A.clientHeight - Z.top - Z.bottom), ze = H.height > ke ? 8 : (ke - H.height) / 2, Ge = Math.max(0, Math.min(F, me + (H.top - ce.top) - Z.top - ze));
4049
+ const H = b.getBoundingClientRect(), ce = A.getBoundingClientRect(), F = A.scrollHeight - A.clientHeight, me = A.scrollTop, Z = lr(A), ve = Math.max(80, A.clientHeight - Z.top - Z.bottom), ze = H.height > ve ? 8 : (ve - H.height) / 2, Ge = Math.max(0, Math.min(F, me + (H.top - ce.top) - Z.top - ze));
4050
4050
  if (le.current && cancelAnimationFrame(le.current), Math.abs(Ge - me) < 2) {
4051
4051
  A.scrollTop = Ge, le.current = null;
4052
4052
  return;
@@ -4091,7 +4091,7 @@ function ql({ model: t, rows: e, player: n, fixed: r, applied: s, onFixOpen: a,
4091
4091
  var he;
4092
4092
  const b = j && A === T, H = E && A === T, ce = !!u && u === W.id, F = te && !W.text.toLowerCase().includes(te) && !(D && ((he = W.translations[D]) != null && he.toLowerCase().includes(te))) ? 0.22 : !E || A <= T || ce ? 1 : 0.38, me = m ? () => n.playRow(A) : c && l ? () => {
4093
4093
  j && !b && n.seekRow(A), l(W);
4094
- } : j && b ? void 0 : () => n.playRow(A), Z = m ? null : el(W, s, r), ke = !!Z && (Z.script > 0 || Z.manual), ze = y && !!a && k === W.id && !!Z && !ke, Ge = br(t, W.speaker), Ae = xr(t, W.speaker), ge = Ae.lane, Ye = D && W.translations[D] && W.language !== D ? W.translations[D] : null, Ve = xi(e, A, D), $ = H && !S && re ? hi(Ve.map((ue) => ({ t: ue.text, sp: " " })), re) : null;
4094
+ } : j && b ? void 0 : () => n.playRow(A), Z = m ? null : el(W, s, r), ve = !!Z && (Z.script > 0 || Z.manual), ze = y && !!a && k === W.id && !!Z && !ve, Ge = br(t, W.speaker), Ae = xr(t, W.speaker), ge = Ae.lane, Ye = D && W.translations[D] && W.language !== D ? W.translations[D] : null, Ve = xi(e, A, D), $ = H && !S && re ? hi(Ve.map((ue) => ({ t: ue.text, sp: " " })), re) : null;
4095
4095
  return /* @__PURE__ */ h("div", { "data-tx-row": A, "data-sentence": W.sentenceId, className: `txline${V ? " txline--warm" : ""}${ce ? " txline--fixing" : ""}`, "aria-current": ce || void 0, style: { opacity: F }, onClick: me, onMouseEnter: y && a ? () => ae(W.id) : void 0, onMouseLeave: y && a ? () => ae(null) : void 0, children: [
4096
4096
  /* @__PURE__ */ h("div", { className: "txline__meta", children: [
4097
4097
  /* @__PURE__ */ i("span", { className: "txline__at", children: yt(W.start) }),
@@ -4101,7 +4101,7 @@ function ql({ model: t, rows: e, player: n, fixed: r, applied: s, onFixOpen: a,
4101
4101
  Ae.hasVoice && /* @__PURE__ */ i(Oi, { color: Ae.fg ?? `var(--lane-${ge})` })
4102
4102
  ] }),
4103
4103
  b && /* @__PURE__ */ i("span", { title: "Playing", style: { flex: "none", display: "inline-flex", alignItems: "center" }, children: /* @__PURE__ */ i(oe, { d: X.headphones, size: y ? 15 : 14, sw: 1.6, stroke: f && W.speaker >= 0 ? Ae.fg ?? `var(--lane-${ge})` : "var(--ink-45)" }) }),
4104
- Z && g && /* @__PURE__ */ i(tl, { f: Z, desk: y, onOpen: a ? () => a(W, !0) : void 0 }),
4104
+ Z && M && /* @__PURE__ */ i(tl, { f: Z, desk: y, onOpen: a ? () => a(W, !0) : void 0 }),
4105
4105
  ze && /* @__PURE__ */ i(nl, { alone: !0, onOpen: () => a == null ? void 0 : a(W, !1) })
4106
4106
  ] }),
4107
4107
  /* @__PURE__ */ i("div", { className: "txline__text", children: Ve.map((ue, ie) => {
@@ -4112,9 +4112,9 @@ function ql({ model: t, rows: e, player: n, fixed: r, applied: s, onFixOpen: a,
4112
4112
  {
4113
4113
  className: "txw",
4114
4114
  title: o && !Ye ? c ? "Correct this word" : b && j && n.seekWord ? "Play from this word" : "Play from this line" : b ? "" : "Play from this line",
4115
- onClick: o && !Ye ? (ve) => {
4115
+ onClick: o && !Ye ? (ke) => {
4116
4116
  var Ce;
4117
- if (ve.stopPropagation(), c) {
4117
+ if (ke.stopPropagation(), c) {
4118
4118
  o(W, ue);
4119
4119
  return;
4120
4120
  }
@@ -4137,7 +4137,7 @@ function ql({ model: t, rows: e, player: n, fixed: r, applied: s, onFixOpen: a,
4137
4137
  /* @__PURE__ */ i("span", {}),
4138
4138
  /* @__PURE__ */ i("span", {}),
4139
4139
  /* @__PURE__ */ i("span", {})
4140
- ] }) }) : /* @__PURE__ */ i("div", { className: "txtail", style: { color: N }, children: M }),
4140
+ ] }) }) : /* @__PURE__ */ i("div", { className: "txtail", style: { color: N }, children: g }),
4141
4141
  j && G === 1 && B("down")
4142
4142
  ] });
4143
4143
  }
@@ -4160,24 +4160,24 @@ function Jl(t, e, n, r, s) {
4160
4160
  a.current = n;
4161
4161
  const o = v(r);
4162
4162
  o.current = r;
4163
- const [l, c] = I(0), u = r.trim().toLowerCase();
4163
+ const [l, c] = z(0), u = r.trim().toLowerCase();
4164
4164
  return U(() => {
4165
4165
  c(u ? e.filter((d) => d.text.toLowerCase().includes(u)).length : 0);
4166
4166
  }, [e, u]), U(() => {
4167
4167
  const d = t.current;
4168
4168
  if (!d) return;
4169
- let g = d.scrollTop, M = 0, N = 0;
4169
+ let M = d.scrollTop, g = 0, N = 0;
4170
4170
  const p = () => {
4171
4171
  N = Date.now() + 1500;
4172
4172
  }, y = (m) => {
4173
4173
  m.buttons && p();
4174
4174
  }, L = () => {
4175
- const m = d.scrollTop, f = m - g;
4176
- if (g = m, Date.now() > N) {
4177
- M = 0;
4175
+ const m = d.scrollTop, f = m - M;
4176
+ if (M = m, Date.now() > N) {
4177
+ g = 0;
4178
4178
  return;
4179
4179
  }
4180
- M = f < 0 == M < 0 ? M + f : f, M < -14 && !a.current ? (M = 0, s(!0)) : M > 56 && a.current && !o.current.trim() && (M = 0, s(!1));
4180
+ g = f < 0 == g < 0 ? g + f : f, g < -14 && !a.current ? (g = 0, s(!0)) : g > 56 && a.current && !o.current.trim() && (g = 0, s(!1));
4181
4181
  };
4182
4182
  return d.addEventListener("wheel", p, { passive: !0 }), d.addEventListener("touchmove", p, { passive: !0 }), d.addEventListener("pointermove", y), d.addEventListener("scroll", L, { passive: !0 }), () => {
4183
4183
  d.removeEventListener("wheel", p), d.removeEventListener("touchmove", p), d.removeEventListener("pointermove", y), d.removeEventListener("scroll", L);
@@ -4194,7 +4194,7 @@ function Di(t) {
4194
4194
  return e;
4195
4195
  }
4196
4196
  const qs = (t) => Math.floor(Di(t) / 8) - tn.perBlock[t] * tn.blocks[t];
4197
- function kr(t, e) {
4197
+ function vr(t, e) {
4198
4198
  let n = 0;
4199
4199
  for (let r = 7; r >= 0; r--)
4200
4200
  n = n << 1 ^ (n >>> 7) * 285, n ^= (e >>> r & 1) * t;
@@ -4205,8 +4205,8 @@ function Xl(t) {
4205
4205
  e[t - 1] = 1;
4206
4206
  let n = 1;
4207
4207
  for (let r = 0; r < t; r++) {
4208
- for (let s = 0; s < t; s++) e[s] = kr(e[s], n) ^ (s + 1 < t ? e[s + 1] : 0);
4209
- n = kr(n, 2);
4208
+ for (let s = 0; s < t; s++) e[s] = vr(e[s], n) ^ (s + 1 < t ? e[s + 1] : 0);
4209
+ n = vr(n, 2);
4210
4210
  }
4211
4211
  return e;
4212
4212
  }
@@ -4215,7 +4215,7 @@ function ec(t, e) {
4215
4215
  for (const r of t) {
4216
4216
  const s = r ^ n.shift();
4217
4217
  n.push(0), e.forEach((a, o) => {
4218
- n[o] ^= kr(a, s);
4218
+ n[o] ^= vr(a, s);
4219
4219
  });
4220
4220
  }
4221
4221
  return n;
@@ -4241,29 +4241,29 @@ function nc(t) {
4241
4241
  for (let T = 236; a.length < s; T ^= 253) o(T, 8);
4242
4242
  const l = [];
4243
4243
  for (let T = 0; T < a.length; T += 8) l.push(a.slice(T, T + 8).reduce((O, S) => O << 1 | S, 0));
4244
- const c = tn.blocks[n], u = tn.perBlock[n], d = Math.floor(Di(n) / 8), g = c - d % c, M = Math.floor(d / c), N = [], p = Xl(u);
4244
+ const c = tn.blocks[n], u = tn.perBlock[n], d = Math.floor(Di(n) / 8), M = c - d % c, g = Math.floor(d / c), N = [], p = Xl(u);
4245
4245
  for (let T = 0, O = 0; T < c; T++) {
4246
- const S = l.slice(O, O + M - u + (T < g ? 0 : 1));
4246
+ const S = l.slice(O, O + g - u + (T < M ? 0 : 1));
4247
4247
  O += S.length;
4248
4248
  const re = ec(S, p);
4249
- T < g && S.push(0), N.push(S.concat(re));
4249
+ T < M && S.push(0), N.push(S.concat(re));
4250
4250
  }
4251
4251
  const y = [];
4252
4252
  for (let T = 0; T < N[0].length; T++) N.forEach((O, S) => {
4253
- (T !== M - u || S >= g) && y.push(O[T]);
4253
+ (T !== g - u || S >= M) && y.push(O[T]);
4254
4254
  });
4255
4255
  const L = Array.from({ length: r }, () => new Array(r).fill(!1)), m = Array.from({ length: r }, () => new Array(r).fill(!1)), f = (T, O, S) => {
4256
4256
  L[O][T] = S, m[O][T] = !0;
4257
4257
  };
4258
4258
  for (let T = 0; T < r; T++)
4259
4259
  f(6, T, T % 2 === 0), f(T, 6, T % 2 === 0);
4260
- const z = (T, O) => {
4260
+ const I = (T, O) => {
4261
4261
  for (let S = -4; S <= 4; S++) for (let re = -4; re <= 4; re++) {
4262
4262
  const K = Math.max(Math.abs(re), Math.abs(S)), k = T + re, ae = O + S;
4263
4263
  k >= 0 && k < r && ae >= 0 && ae < r && f(k, ae, K !== 2 && K !== 4);
4264
4264
  }
4265
4265
  };
4266
- z(3, 3), z(r - 4, 3), z(3, r - 4);
4266
+ I(3, 3), I(r - 4, 3), I(3, r - 4);
4267
4267
  const C = tc(n);
4268
4268
  for (let T = 0; T < C.length; T++) for (let O = 0; O < C.length; O++)
4269
4269
  if (!(T === 0 && O === 0 || T === 0 && O === C.length - 1 || T === C.length - 1 && O === 0))
@@ -4379,9 +4379,9 @@ function ic() {
4379
4379
  }
4380
4380
  function Xt(t) {
4381
4381
  var e;
4382
- typeof document > "u" || !((e = window.matchMedia) != null && e.call(window, "(pointer: coarse)").matches) || kn(t);
4382
+ typeof document > "u" || !((e = window.matchMedia) != null && e.call(window, "(pointer: coarse)").matches) || vn(t);
4383
4383
  }
4384
- function kn(t) {
4384
+ function vn(t) {
4385
4385
  var s, a, o, l;
4386
4386
  if (typeof document > "u") return;
4387
4387
  const e = document, n = Er ?? document.documentElement, r = e.fullscreenElement ?? e.webkitFullscreenElement;
@@ -4393,7 +4393,7 @@ function kn(t) {
4393
4393
  }
4394
4394
  }
4395
4395
  function ac(t) {
4396
- const [e, n] = I(() => {
4396
+ const [e, n] = z(() => {
4397
4397
  var r;
4398
4398
  return typeof window < "u" && !!((r = window.matchMedia) != null && r.call(window, t).matches);
4399
4399
  });
@@ -4405,8 +4405,8 @@ function ac(t) {
4405
4405
  return s(), r.addEventListener("change", s), () => r.removeEventListener("change", s);
4406
4406
  }, [t]), e;
4407
4407
  }
4408
- function vn({ pos: t, interactive: e, axis: n = "x" }) {
4409
- const [r, s] = I(null), a = (c) => {
4408
+ function kn({ pos: t, interactive: e, axis: n = "x" }) {
4409
+ const [r, s] = z(null), a = (c) => {
4410
4410
  const u = c.currentTarget.getBoundingClientRect(), d = n === "y" ? (c.clientY - u.top) / Math.max(1, u.height) : (c.clientX - u.left) / Math.max(1, u.width);
4411
4411
  return Math.min(1, Math.max(0, d));
4412
4412
  }, o = (c) => {
@@ -4445,7 +4445,7 @@ function vn({ pos: t, interactive: e, axis: n = "x" }) {
4445
4445
  ] });
4446
4446
  }
4447
4447
  function qc({ pos: t }) {
4448
- const [e, n] = I(null), r = (l) => {
4448
+ const [e, n] = z(null), r = (l) => {
4449
4449
  const c = l.currentTarget.getBoundingClientRect();
4450
4450
  return Math.min(1, Math.max(0, (l.clientX - c.left) / Math.max(1, c.width)));
4451
4451
  }, s = (l) => {
@@ -4498,13 +4498,13 @@ function jn({ t, mini: e }) {
4498
4498
  disabled: !t.playable,
4499
4499
  style: { background: t.playable ? t.playing ? "rgba(238,240,248,.92)" : "var(--brand)" : "rgba(5,6,21,.42)", color: t.playable ? t.playing ? "#131326" : "var(--brand-ink)" : "rgba(234,236,250,.5)", cursor: t.playable ? "pointer" : "default" },
4500
4500
  onClick: t.onPlay,
4501
- children: t.busy ? /* @__PURE__ */ i("span", { className: "gfull__spin", "aria-hidden": "true" }) : t.playing ? /* @__PURE__ */ i(va, { size: e ? 14 : 18 }) : /* @__PURE__ */ i(jr, { size: e ? 15 : 19 })
4501
+ children: t.busy ? /* @__PURE__ */ i("span", { className: "gfull__spin", "aria-hidden": "true" }) : t.playing ? /* @__PURE__ */ i(ka, { size: e ? 14 : 18 }) : /* @__PURE__ */ i(jr, { size: e ? 15 : 19 })
4502
4502
  }
4503
4503
  ),
4504
4504
  /* @__PURE__ */ i("button", { type: "button", className: "gfull__step", "aria-label": "Next line", title: "Next line", style: { opacity: t.nextOn ? 1 : 0.3 }, onClick: t.onNext, children: /* @__PURE__ */ i(oe, { d: X.chevronRight, size: e ? 13 : 16, sw: e ? 1.8 : 1.9 }) })
4505
4505
  ] });
4506
4506
  }
4507
- function vr({ live: t, mini: e, desk: n, pct: r, mark: s }) {
4507
+ function kr({ live: t, mini: e, desk: n, pct: r, mark: s }) {
4508
4508
  return /* @__PURE__ */ h("div", { className: `gfull__brand${s ? " gfull__brand--mark" : ""}`, children: [
4509
4509
  /* @__PURE__ */ i("a", { href: ii, target: "_blank", rel: "noopener", style: { display: "block", lineHeight: 0 }, "aria-label": "VocalStack", title: "VocalStack", children: s ? /* @__PURE__ */ i(zr, { dark: !0, size: 22 }) : /* @__PURE__ */ i(bn, { dark: !0, link: !1, height: e ? 11 : n ? 18 : 15 }) }),
4510
4510
  t && /* @__PURE__ */ h("span", { className: "gfull__live", children: [
@@ -4520,9 +4520,9 @@ function Ai({ v: t, size: e }) {
4520
4520
  function oc({ pos: t, transport: e, chip: n, voices: r, onShare: s, onFull: a, copied: o }) {
4521
4521
  return /* @__PURE__ */ h("div", { className: "gmini", "data-theme": "dark", children: [
4522
4522
  /* @__PURE__ */ i("div", { className: "gmini__shade", "aria-hidden": "true" }),
4523
- /* @__PURE__ */ i("div", { className: "gmini__top", children: /* @__PURE__ */ i(vr, { live: t.live, mini: !0 }) }),
4523
+ /* @__PURE__ */ i("div", { className: "gmini__top", children: /* @__PURE__ */ i(kr, { live: t.live, mini: !0 }) }),
4524
4524
  /* @__PURE__ */ h("div", { className: "gmini__foot", children: [
4525
- /* @__PURE__ */ i("div", { className: "gmini__row", children: /* @__PURE__ */ i(vn, { pos: t, interactive: !0 }) }),
4525
+ /* @__PURE__ */ i("div", { className: "gmini__row", children: /* @__PURE__ */ i(kn, { pos: t, interactive: !0 }) }),
4526
4526
  /* @__PURE__ */ h("div", { className: "gmini__row gmini__row--ctl", children: [
4527
4527
  /* @__PURE__ */ i(jn, { t: e, mini: !0 }),
4528
4528
  /* @__PURE__ */ i("span", { style: { flex: 1 } }),
@@ -4538,8 +4538,8 @@ function oc({ pos: t, transport: e, chip: n, voices: r, onShare: s, onFull: a, c
4538
4538
  ] });
4539
4539
  }
4540
4540
  const lc = { color: "rgba(255,255,255,.4)" };
4541
- function Ei({ compact: t = !1, noFull: e = !1, page: n = !0, picture: r, title: s, desk: a, pos: o, sub: l, wait: c, pct: u, mute: d, cc: g, ad: M, chip: N, transport: p, picker: y, sheet: L, voices: m, voicesBtn: f, sheetOpen: z, onShare: C, onSettings: D, paused: V, copied: _, onTouch: ee, onClose: j }) {
4542
- const [E, Q] = I(() => !!ur());
4541
+ function Ei({ compact: t = !1, noFull: e = !1, page: n = !0, picture: r, title: s, desk: a, pos: o, sub: l, wait: c, pct: u, mute: d, cc: M, ad: g, chip: N, transport: p, picker: y, sheet: L, voices: m, voicesBtn: f, sheetOpen: I, onShare: C, onSettings: D, paused: V, copied: _, onTouch: ee, onClose: j }) {
4542
+ const [E, Q] = z(() => !!ur());
4543
4543
  U(() => {
4544
4544
  const $ = () => Q(!!ur());
4545
4545
  return document.addEventListener("fullscreenchange", $), document.addEventListener("webkitfullscreenchange", $), () => {
@@ -4550,8 +4550,8 @@ function Ei({ compact: t = !1, noFull: e = !1, page: n = !0, picture: r, title:
4550
4550
  T.current = j;
4551
4551
  const O = v(p.playable ? p.onPlay : void 0);
4552
4552
  O.current = p.playable ? p.onPlay : void 0;
4553
- const [S, re] = I(!1), [K, k] = I(0), ae = v(!1);
4554
- U(() => () => kn(!1), []), U(() => {
4553
+ const [S, re] = z(!1), [K, k] = z(0), ae = v(!1);
4554
+ U(() => () => vn(!1), []), U(() => {
4555
4555
  if (!n) return;
4556
4556
  const $ = [document.documentElement, document.body], he = $.map((fe) => fe.style.background);
4557
4557
  $.forEach((fe) => {
@@ -4564,7 +4564,7 @@ function Ei({ compact: t = !1, noFull: e = !1, page: n = !0, picture: r, title:
4564
4564
  }), ue && ie && (ue.content = ie);
4565
4565
  };
4566
4566
  }, []);
4567
- const te = Ie(() => n && ic(), [n]), [G, J] = I(te);
4567
+ const te = Ie(() => n && ic(), [n]), [G, J] = z(te);
4568
4568
  U(() => {
4569
4569
  if (!n) return;
4570
4570
  const $ = [document.documentElement, document.body], he = $.map((fe) => [fe.style.overflow, fe.style.overscrollBehavior]);
@@ -4583,11 +4583,11 @@ function Ei({ compact: t = !1, noFull: e = !1, page: n = !0, picture: r, title:
4583
4583
  window.removeEventListener("scroll", ie), ue.remove(), document.documentElement.style.overscrollBehavior = he[0][1], window.scrollTo(0, 0);
4584
4584
  };
4585
4585
  }, [te, n]);
4586
- const pe = v(z);
4587
- pe.current = z, U(() => {
4586
+ const pe = v(I);
4587
+ pe.current = I, U(() => {
4588
4588
  const $ = (ie) => ie instanceof HTMLElement && (ie.isContentEditable || /^(INPUT|TEXTAREA|SELECT)$/.test(ie.tagName)), he = (ie) => {
4589
4589
  var fe;
4590
- ie.key === "Escape" && !pe.current && T.current && (ie.stopPropagation(), T.current()), ie.key === " " && !pe.current && !$(ie.target) && (ie.preventDefault(), ie.stopPropagation(), ie.repeat || (fe = O.current) == null || fe.call(O)), (ie.key === "f" || ie.key === "F") && !ie.metaKey && !ie.ctrlKey && !ie.altKey && !pe.current && !$(ie.target) && Js() && (ie.preventDefault(), ie.repeat || kn(!ur()));
4590
+ ie.key === "Escape" && !pe.current && T.current && (ie.stopPropagation(), T.current()), ie.key === " " && !pe.current && !$(ie.target) && (ie.preventDefault(), ie.stopPropagation(), ie.repeat || (fe = O.current) == null || fe.call(O)), (ie.key === "f" || ie.key === "F") && !ie.metaKey && !ie.ctrlKey && !ie.altKey && !pe.current && !$(ie.target) && Js() && (ie.preventDefault(), ie.repeat || vn(!ur()));
4591
4591
  }, ue = (ie) => {
4592
4592
  ie.key === " " && !pe.current && !$(ie.target) && ie.preventDefault();
4593
4593
  };
@@ -4595,7 +4595,7 @@ function Ei({ compact: t = !1, noFull: e = !1, page: n = !0, picture: r, title:
4595
4595
  window.removeEventListener("keydown", he, !0), window.removeEventListener("keyup", ue, !0);
4596
4596
  };
4597
4597
  }, []);
4598
- const le = ac("(orientation: landscape) and (max-height: 540px)"), Te = v(null), [je, Ee] = I(null);
4598
+ const le = ac("(orientation: landscape) and (max-height: 540px)"), Te = v(null), [je, Ee] = z(null);
4599
4599
  Bt(() => {
4600
4600
  const $ = Te.current;
4601
4601
  if (!$ || (Ee($.getBoundingClientRect().width), typeof ResizeObserver > "u")) return;
@@ -4604,10 +4604,10 @@ function Ei({ compact: t = !1, noFull: e = !1, page: n = !0, picture: r, title:
4604
4604
  }, []);
4605
4605
  const Le = t && !E, we = !Le && a && !le && (je == null || je >= 880), _e = !we;
4606
4606
  U(() => {
4607
- if (re(!1), !p.playing || z) return;
4607
+ if (re(!1), !p.playing || I) return;
4608
4608
  const $ = setTimeout(() => re(!0), 3e3);
4609
4609
  return () => clearTimeout($);
4610
- }, [p.playing, z, K]);
4610
+ }, [p.playing, I, K]);
4611
4611
  const Pe = v(S);
4612
4612
  Pe.current = S;
4613
4613
  const Se = v(0), B = ($) => {
@@ -4626,11 +4626,11 @@ function Ei({ compact: t = !1, noFull: e = !1, page: n = !0, picture: r, title:
4626
4626
  const Y = (de) => Math.round((de.getBoundingClientRect().top - $.getBoundingClientRect().top + $.scrollTop) / ie), R = Math.max(1, Math.round($.clientHeight / ie)), q = he ? ue.length ? Math.floor(Y(ue[ue.length - 1]) / R) * R * ie : 0 : Ue, ne = Math.max(0, Math.min(Ue, q));
4627
4627
  Math.abs(ne - $.scrollTop) > 1 && ($.scrollTop = ne);
4628
4628
  }, [b, W]);
4629
- const [H, ce] = I(!0), [F, me] = I(!1), Z = v(void 0);
4629
+ const [H, ce] = z(!0), [F, me] = z(!1), Z = v(void 0);
4630
4630
  U(() => () => window.clearTimeout(Z.current), []);
4631
- const ke = V != null && V.share ? V.share.url(H && V.share.at >= 1 ? Math.floor(V.share.at) : null) : "", ze = Ie(() => we && ke && !p.playing ? rc(ke) : "", [we, ke, p.playing]), Ge = () => {
4631
+ const ve = V != null && V.share ? V.share.url(H && V.share.at >= 1 ? Math.floor(V.share.at) : null) : "", ze = Ie(() => we && ve && !p.playing ? rc(ve) : "", [we, ve, p.playing]), Ge = () => {
4632
4632
  var $;
4633
- ($ = navigator.clipboard) == null || $.writeText(ke).then(() => {
4633
+ ($ = navigator.clipboard) == null || $.writeText(ve).then(() => {
4634
4634
  me(!0), window.clearTimeout(Z.current), Z.current = window.setTimeout(() => me(!1), 1800);
4635
4635
  }, () => {
4636
4636
  });
@@ -4643,13 +4643,13 @@ function Ei({ compact: t = !1, noFull: e = !1, page: n = !0, picture: r, title:
4643
4643
  "Start at ",
4644
4644
  yt(Math.floor(V.share.at))
4645
4645
  ] }),
4646
- /* @__PURE__ */ i("div", { className: "gfull__shareurl", children: /* @__PURE__ */ i("span", { children: ke.replace(/^https?:\/\//, "") }) }),
4646
+ /* @__PURE__ */ i("div", { className: "gfull__shareurl", children: /* @__PURE__ */ i("span", { children: ve.replace(/^https?:\/\//, "") }) }),
4647
4647
  /* @__PURE__ */ h("div", { className: "gfull__shareacts", children: [
4648
4648
  /* @__PURE__ */ h("button", { type: "button", className: "gfull__sharebtn gfull__sharebtn--main", onClick: Ge, children: [
4649
4649
  /* @__PURE__ */ i(oe, { d: F ? X.check : X.copy, size: 14, sw: 1.8 }),
4650
4650
  F ? "Copied" : "Copy link"
4651
4651
  ] }),
4652
- /* @__PURE__ */ h("button", { type: "button", className: "gfull__sharebtn", onClick: () => Ar(ke, s), children: [
4652
+ /* @__PURE__ */ h("button", { type: "button", className: "gfull__sharebtn", onClick: () => Ar(ve, s), children: [
4653
4653
  /* @__PURE__ */ i(oe, { d: X.share, size: 14, sw: 1.6 }),
4654
4654
  "Share"
4655
4655
  ] })
@@ -4658,18 +4658,18 @@ function Ei({ compact: t = !1, noFull: e = !1, page: n = !0, picture: r, title:
4658
4658
  ] }), ge = ($, he, ue, ie, fe, Ue = 0) => /* @__PURE__ */ i("button", { type: "button", className: "gfull__btn", title: $, "aria-label": $, onClick: ie, children: /* @__PURE__ */ i(oe, { d: he, size: (we ? 20 : _e ? 15 : 18) + Ue, sw: ue, style: fe }) }), Ye = /* @__PURE__ */ h("div", { className: "gfull__acts", children: [
4659
4659
  f && /* @__PURE__ */ i(Ai, { v: f, size: we ? 20 : _e ? 15 : 18 }),
4660
4660
  C && ge("Share", X.share, 1.6, C),
4661
- Js() && !e && ge(E ? "Exit full screen" : "Full screen", E ? sc : Si, 1.7, () => kn(!E)),
4661
+ Js() && !e && ge(E ? "Exit full screen" : "Full screen", E ? sc : Si, 1.7, () => vn(!E)),
4662
4662
  j && ge("Close player", X.close, 1.7, j)
4663
- ] }), Ve = (d || g || D) && /* @__PURE__ */ h("div", { className: "gfull__top", children: [
4663
+ ] }), Ve = (d || M || D) && /* @__PURE__ */ h("div", { className: "gfull__top", children: [
4664
4664
  d && ge(d.muted ? "Unmute" : "Mute", d.muted ? X.volumeOff : X.volume, 1.6, d.onToggle),
4665
- g && ge(g.on ? "Hide subtitles" : "Show subtitles", g.on ? X.cc : X.ccOff, 1.7, g.onToggle, void 0, 4),
4665
+ M && ge(M.on ? "Hide subtitles" : "Show subtitles", M.on ? X.cc : X.ccOff, 1.7, M.onToggle, void 0, 4),
4666
4666
  D && ge("Settings", X.cog, 1.6, D)
4667
4667
  ] });
4668
4668
  return /* @__PURE__ */ h(
4669
4669
  "div",
4670
4670
  {
4671
4671
  ref: Te,
4672
- className: `gfull${we ? " gfull--desk" : ""}${_e ? " gfull--mini" : ""}${Le ? " gfull--small" : ""}${te ? " gfull--swipe" : ""}${M ? " gfull--ad" : ""}${S ? " gfull--calm" : ""}`,
4672
+ className: `gfull${we ? " gfull--desk" : ""}${_e ? " gfull--mini" : ""}${Le ? " gfull--small" : ""}${te ? " gfull--swipe" : ""}${g ? " gfull--ad" : ""}${S ? " gfull--calm" : ""}`,
4673
4673
  "data-theme": "dark",
4674
4674
  role: "dialog",
4675
4675
  "aria-label": s,
@@ -4689,7 +4689,7 @@ function Ei({ compact: t = !1, noFull: e = !1, page: n = !0, picture: r, title:
4689
4689
  /* @__PURE__ */ h("div", { className: `gfull__frame${W ? " gfull__frame--land" : ""}`, children: [
4690
4690
  r,
4691
4691
  /* @__PURE__ */ i("div", { className: "gfull__shade", "aria-hidden": "true" }),
4692
- V && !M && /* @__PURE__ */ h("div", { className: `gfull__pausedinfo${p.playing ? "" : " gfull__pausedinfo--on"}`, "aria-hidden": p.playing, children: [
4692
+ V && !g && /* @__PURE__ */ h("div", { className: `gfull__pausedinfo${p.playing ? "" : " gfull__pausedinfo--on"}`, "aria-hidden": p.playing, children: [
4693
4693
  /* @__PURE__ */ h("div", { className: "gfull__pausedtext", children: [
4694
4694
  /* @__PURE__ */ h("div", { className: "gfull__pausedhead", children: [
4695
4695
  (_e || Le) && /* @__PURE__ */ i("span", { className: "gfull__pausedmark", "aria-hidden": "true", children: /* @__PURE__ */ i(zr, { dark: !0, size: 20 }) }),
@@ -4730,20 +4730,20 @@ function Ei({ compact: t = !1, noFull: e = !1, page: n = !0, picture: r, title:
4730
4730
  ] })
4731
4731
  ] }) }),
4732
4732
  /* @__PURE__ */ i("div", { className: `gfull__prog${we ? "" : " gfull__prog--two"}`, children: we ? /* @__PURE__ */ h(xe, { children: [
4733
- /* @__PURE__ */ i(vr, { live: o.live, desk: !0, pct: u }),
4733
+ /* @__PURE__ */ i(kr, { live: o.live, desk: !0, pct: u }),
4734
4734
  /* @__PURE__ */ i(jn, { t: p }),
4735
- /* @__PURE__ */ i(vn, { pos: o, interactive: !0 }),
4735
+ /* @__PURE__ */ i(kn, { pos: o, interactive: !0 }),
4736
4736
  /* @__PURE__ */ i("div", { className: "gfull__chip", children: N }),
4737
4737
  Ye
4738
4738
  ] }) : _e ? /* @__PURE__ */ h("div", { className: "gfull__row", children: [
4739
4739
  /* @__PURE__ */ i(jn, { t: p, mini: !0 }),
4740
- /* @__PURE__ */ i(vn, { pos: o, interactive: !0 }),
4740
+ /* @__PURE__ */ i(kn, { pos: o, interactive: !0 }),
4741
4741
  /* @__PURE__ */ i("div", { className: "gfull__chip", children: N }),
4742
4742
  Ye
4743
4743
  ] }) : /* @__PURE__ */ h(xe, { children: [
4744
4744
  /* @__PURE__ */ h("div", { className: "gfull__row", children: [
4745
- /* @__PURE__ */ i(vr, { live: o.live, pct: u, mark: !0 }),
4746
- /* @__PURE__ */ i(vn, { pos: o, interactive: !0 })
4745
+ /* @__PURE__ */ i(kr, { live: o.live, pct: u, mark: !0 }),
4746
+ /* @__PURE__ */ i(kn, { pos: o, interactive: !0 })
4747
4747
  ] }),
4748
4748
  /* @__PURE__ */ h("div", { className: "gfull__row", children: [
4749
4749
  /* @__PURE__ */ i(jn, { t: p }),
@@ -4785,7 +4785,7 @@ function hc(t) {
4785
4785
  return t.translateFailed === t.lang ? { kind: "translateFailed", lang: e } : t.voiceFailed ? { kind: "voiceFailed", lang: e } : t.translating ? { kind: "translating", lang: e } : t.starting != null ? { kind: "starting", lang: e, since: t.starting } : t.relang || t.slowLine ? { kind: "voice", lang: e, since: t.lineSince } : null;
4786
4786
  }
4787
4787
  function Mc(t, e) {
4788
- const [n, r] = I(null), [s, a] = I(!1);
4788
+ const [n, r] = z(null), [s, a] = z(!1);
4789
4789
  return U(() => {
4790
4790
  if (!t) {
4791
4791
  r(null), a(!1);
@@ -4799,7 +4799,7 @@ function Mc(t, e) {
4799
4799
  }
4800
4800
  const gc = (t) => `${Math.floor(t / 60)}:${String(t % 60).padStart(2, "0")}`;
4801
4801
  function fc({ state: t, line: e, onRetry: n, onOriginal: r }) {
4802
- const [s, a] = I(() => Date.now());
4802
+ const [s, a] = z(() => Date.now());
4803
4803
  U(() => {
4804
4804
  if (t.since == null) return;
4805
4805
  const d = setInterval(() => a(Date.now()), 1e3);
@@ -4853,7 +4853,7 @@ function _i(t, e, n) {
4853
4853
  const r = new URL(t ?? _r), s = Nc(), a = new URL(pc, r);
4854
4854
  e.url && a.searchParams.set("url", e.url), e.transcription && a.searchParams.set("transcription", e.transcription), e.ask && a.searchParams.set("ask", "1"), e.connect && a.searchParams.set("connect", "1"), a.searchParams.set("origin", window.location.origin), a.searchParams.set("nonce", s);
4855
4855
  const o = 480, l = 640, c = Math.max(0, (window.screenX ?? 0) + ((window.outerWidth ?? o) - o) / 2), u = Math.max(0, (window.screenY ?? 0) + ((window.outerHeight ?? l) - l) / 2), d = window.open(a.toString(), "vocalstack-connect", `popup=yes,width=${o},height=${l},left=${Math.round(c)},top=${Math.round(u)}`);
4856
- return d ? new Promise((g, M) => {
4856
+ return d ? new Promise((M, g) => {
4857
4857
  let N = !1;
4858
4858
  const p = (m) => {
4859
4859
  N || (N = !0, window.removeEventListener("message", y), clearInterval(L), m());
@@ -4870,23 +4870,23 @@ function _i(t, e, n) {
4870
4870
  return;
4871
4871
  }
4872
4872
  if (f.type === "vocalstack:started" || f.type === "vocalstack:token" || f.type === "vocalstack:found") {
4873
- p(() => g({ transcriptionId: String(f.transcriptionId), recordingId: String(f.recordingId), token: String(f.token), expiresAt: f.expiresAt ?? null }));
4873
+ p(() => M({ transcriptionId: String(f.transcriptionId), recordingId: String(f.recordingId), token: String(f.token), expiresAt: f.expiresAt ?? null }));
4874
4874
  return;
4875
4875
  }
4876
4876
  if (f.type === "vocalstack:connected") {
4877
- p(() => g("connected"));
4877
+ p(() => M("connected"));
4878
4878
  return;
4879
4879
  }
4880
4880
  if (f.type === "vocalstack:declined") {
4881
- p(() => g(null));
4881
+ p(() => M(null));
4882
4882
  return;
4883
4883
  }
4884
- f.type === "vocalstack:error" && p(() => M(new Error(typeof f.message == "string" && f.message ? f.message : "VocalStack could not start this transcription.")));
4884
+ f.type === "vocalstack:error" && p(() => g(new Error(typeof f.message == "string" && f.message ? f.message : "VocalStack could not start this transcription.")));
4885
4885
  }
4886
4886
  };
4887
4887
  window.addEventListener("message", y);
4888
4888
  const L = setInterval(() => {
4889
- d.closed && p(() => g(null));
4889
+ d.closed && p(() => M(null));
4890
4890
  }, 500);
4891
4891
  }) : Promise.reject(new Error("Your browser blocked the VocalStack window. Allow pop-ups for this site and try again."));
4892
4892
  }
@@ -4916,24 +4916,24 @@ const wc = {
4916
4916
  checking: "Checking the link…",
4917
4917
  starting: "Starting the transcription…"
4918
4918
  }, Lc = /^(https?:\/\/)?([\w-]+\.)+[a-z]{2,}(\/\S*)?$/i;
4919
- function kc({ options: t, onStarted: e, onReplay: n, onClose: r }) {
4920
- const [s, a] = I(""), [o, l] = I(!1), [c, u] = I(null), [d, g] = I(null);
4919
+ function vc({ options: t, onStarted: e, onReplay: n, onClose: r }) {
4920
+ const [s, a] = z(""), [o, l] = z(!1), [c, u] = z(null), [d, M] = z(null);
4921
4921
  U(() => {
4922
4922
  const y = (L) => {
4923
4923
  L.key === "Escape" && r();
4924
4924
  };
4925
4925
  return window.addEventListener("keydown", y), () => window.removeEventListener("keydown", y);
4926
4926
  }, [r]);
4927
- const M = s.trim(), N = Lc.test(M), p = async () => {
4927
+ const g = s.trim(), N = Lc.test(g), p = async () => {
4928
4928
  if (!(!N || o)) {
4929
4929
  l(!0), u(null);
4930
4930
  try {
4931
- const y = await mc(t.appUrl, /^https?:\/\//i.test(M) ? M : `https://${M}`, g);
4931
+ const y = await mc(t.appUrl, /^https?:\/\//i.test(g) ? g : `https://${g}`, M);
4932
4932
  y && e(y);
4933
4933
  } catch (y) {
4934
4934
  u(y instanceof Error ? y.message : "Something went wrong. Please try again.");
4935
4935
  } finally {
4936
- l(!1), g(null);
4936
+ l(!1), M(null);
4937
4937
  }
4938
4938
  }
4939
4939
  };
@@ -4964,18 +4964,18 @@ function kc({ options: t, onStarted: e, onReplay: n, onClose: r }) {
4964
4964
  ] }) });
4965
4965
  }
4966
4966
  function Ui(t) {
4967
- const [e, n] = I(() => typeof window > "u" ? !0 : window.innerWidth >= 880);
4967
+ const [e, n] = z(() => typeof window > "u" ? !0 : window.innerWidth >= 880);
4968
4968
  return U(() => {
4969
4969
  if (t != null) return;
4970
4970
  const r = () => n(window.innerWidth >= 880);
4971
4971
  return window.addEventListener("resize", r), () => window.removeEventListener("resize", r);
4972
4972
  }, [t]), t ?? e;
4973
4973
  }
4974
- const vc = { lang: null, subtitles: !0, speakerLabels: !1, wordHighlight: !0, translateAudio: !0, voices: "cloned", removeBackground: !1, muted: !1 };
4974
+ const kc = { lang: null, subtitles: !0, speakerLabels: !1, wordHighlight: !0, translateAudio: !0, voices: "cloned", removeBackground: !1, muted: !1 };
4975
4975
  function jc(t, e) {
4976
- const n = Li(), [r, s] = gi(), [a, o] = I(null), [l, c] = I("main"), u = wr(n, t.lang), d = Ie(() => fi(n, "translation"), [n]), g = (_) => {
4976
+ const n = Li(), [r, s] = gi(), [a, o] = z(null), [l, c] = z("main"), u = wr(n, t.lang), d = Ie(() => fi(n, "translation"), [n]), M = (_) => {
4977
4977
  e({ lang: _ }), s(_);
4978
- }, M = Or({ open: a === "lang" || a === "settings" && l === "lang", onClose: () => a === "lang" ? o(null) : c("main"), value: t.lang, onSelect: g, languages: d, none: "As spoken", pinned: t.lang ? [t.lang] : [], recent: r, keepOpen: !0 }), N = () => {
4978
+ }, g = Or({ open: a === "lang" || a === "settings" && l === "lang", onClose: () => a === "lang" ? o(null) : c("main"), value: t.lang, onSelect: M, languages: d, none: "As spoken", pinned: t.lang ? [t.lang] : [], recent: r, keepOpen: !0 }), N = () => {
4979
4979
  o(null), c("main");
4980
4980
  }, p = t.lang ? /* @__PURE__ */ i("span", { style: { fontSize: 19, lineHeight: 1 }, children: u.flag }) : /* @__PURE__ */ i(oe, { d: X.langAuto, size: 19, sw: 1.7 }), y = /* @__PURE__ */ i("button", { type: "button", className: "gfull__btn", "aria-label": `Language: ${t.lang ? u.label : "As spoken"}`, title: t.lang ? u.label : "As spoken", onClick: (_) => {
4981
4981
  _.stopPropagation(), c("main"), o((ee) => ee === "lang" ? null : "lang");
@@ -4985,23 +4985,23 @@ function jc(t, e) {
4985
4985
  /* @__PURE__ */ i(oe, { d: X.chevronLeft, size: 18, sw: 1.8 }),
4986
4986
  "Back"
4987
4987
  ] })
4988
- ] }), f = { display: "flex", flexDirection: "column", gap: 2, paddingBottom: 14 }, z = (_, ee, j) => /* @__PURE__ */ h("div", { className: "srow", children: [
4988
+ ] }), f = { display: "flex", flexDirection: "column", gap: 2, paddingBottom: 14 }, I = (_, ee, j) => /* @__PURE__ */ h("div", { className: "srow", children: [
4989
4989
  /* @__PURE__ */ h("div", { style: { flex: 1, minWidth: 0 }, children: [
4990
4990
  /* @__PURE__ */ i("div", { className: "srow__t", children: _ }),
4991
4991
  /* @__PURE__ */ i("div", { className: "srow__s", children: ee })
4992
4992
  ] }),
4993
4993
  j
4994
4994
  ] }), C = /* @__PURE__ */ h("div", { style: { display: "flex", flexDirection: "column" }, children: [
4995
- /* @__PURE__ */ i("div", { style: { position: "sticky", top: 0, zIndex: 1, padding: "4px 14px 10px", background: "var(--vs-surface-raised)" }, children: M.search }),
4996
- M.list
4995
+ /* @__PURE__ */ i("div", { style: { position: "sticky", top: 0, zIndex: 1, padding: "4px 14px 10px", background: "var(--vs-surface-raised)" }, children: g.search }),
4996
+ g.list
4997
4997
  ] }), D = l === "lang" ? C : l === "subs" ? /* @__PURE__ */ h("div", { style: f, children: [
4998
- z("Show subtitles", "Captions over the video", /* @__PURE__ */ i(Nt, { checked: t.subtitles, onChange: (_) => e({ subtitles: _ }), label: "Show subtitles" })),
4999
- z("Show speaker labels", "Who is speaking, before each line", /* @__PURE__ */ i(Nt, { checked: t.speakerLabels, onChange: (_) => e({ speakerLabels: _ }), label: "Show speaker labels" })),
5000
- z("Highlight words", "Follow each word as it is spoken", /* @__PURE__ */ i(Nt, { checked: t.wordHighlight, onChange: (_) => e({ wordHighlight: _ }), label: "Highlight words" }))
4998
+ I("Show subtitles", "Captions over the video", /* @__PURE__ */ i(Nt, { checked: t.subtitles, onChange: (_) => e({ subtitles: _ }), label: "Show subtitles" })),
4999
+ I("Show speaker labels", "Who is speaking, before each line", /* @__PURE__ */ i(Nt, { checked: t.speakerLabels, onChange: (_) => e({ speakerLabels: _ }), label: "Show speaker labels" })),
5000
+ I("Highlight words", "Follow each word as it is spoken", /* @__PURE__ */ i(Nt, { checked: t.wordHighlight, onChange: (_) => e({ wordHighlight: _ }), label: "Highlight words" }))
5001
5001
  ] }) : l === "audio" ? /* @__PURE__ */ h("div", { style: f, children: [
5002
- z("Translate audio", t.lang ? "Hear the translation read aloud instead of the original speech" : "Pick a language to hear the translation read aloud", /* @__PURE__ */ i(Nt, { checked: t.translateAudio && !!t.lang, onChange: (_) => e({ translateAudio: _ }), label: "Translate audio", disabled: !t.lang })),
5003
- z("Voices", t.voices === "cloned" ? "Each speaker in their own cloned voice, where they agreed to it" : "Synthetic voices matched to each speaker", /* @__PURE__ */ i(hr, { value: t.voices, onChange: (_) => e({ voices: _ }), size: "sm", options: [{ value: "synthetic", label: "Synthetic" }, { value: "cloned", label: "Cloned" }] })),
5004
- z(In, "Takes out everything that isn't speech: music, ambience and noise.", /* @__PURE__ */ i(Nt, { checked: t.removeBackground, onChange: (_) => e({ removeBackground: _ }), label: In }))
5002
+ I("Translate audio", t.lang ? "Hear the translation read aloud instead of the original speech" : "Pick a language to hear the translation read aloud", /* @__PURE__ */ i(Nt, { checked: t.translateAudio && !!t.lang, onChange: (_) => e({ translateAudio: _ }), label: "Translate audio", disabled: !t.lang })),
5003
+ I("Voices", t.voices === "cloned" ? "Each speaker in their own cloned voice, where they agreed to it" : "Synthetic voices matched to each speaker", /* @__PURE__ */ i(hr, { value: t.voices, onChange: (_) => e({ voices: _ }), size: "sm", options: [{ value: "synthetic", label: "Synthetic" }, { value: "cloned", label: "Cloned" }] })),
5004
+ I(In, "Takes out everything that isn't speech: music, ambience and noise.", /* @__PURE__ */ i(Nt, { checked: t.removeBackground, onChange: (_) => e({ removeBackground: _ }), label: In }))
5005
5005
  ] }) : /* @__PURE__ */ h("div", { style: f, children: [
5006
5006
  /* @__PURE__ */ h("div", { className: "srow srow--tap", role: "button", onClick: () => c("lang"), children: [
5007
5007
  /* @__PURE__ */ h("div", { style: { flex: 1, minWidth: 0 }, children: [
@@ -5103,9 +5103,18 @@ function Cc({ t }) {
5103
5103
  ] });
5104
5104
  }
5105
5105
  function bc() {
5106
- return /* @__PURE__ */ i("div", { className: "vsp-prov", "aria-hidden": "true", children: /* @__PURE__ */ i("div", { className: "vsp-prov__plane", children: Array.from({ length: zc }, (t, e) => {
5107
- const n = Oc(e);
5108
- return /* @__PURE__ */ i("div", { className: `vsp-prov__row${e % 2 ? " vsp-prov__row--rev" : ""}`, style: { animationDuration: `${80 + e * 11}s`, animationDelay: `-${e * 17}s` }, children: Array.from({ length: Ic }, (r, s) => n.map((a, o) => /* @__PURE__ */ i(Cc, { t: a }, `${s}-${o}`))) }, e);
5106
+ const t = v(null), [e, n] = z(!0), [r, s] = z(() => typeof document > "u" || !document.hidden);
5107
+ return U(() => {
5108
+ const a = () => s(!document.hidden);
5109
+ document.addEventListener("visibilitychange", a);
5110
+ const o = t.current;
5111
+ let l = null;
5112
+ return o && typeof IntersectionObserver < "u" && (l = new IntersectionObserver(([c]) => n(c.isIntersecting)), l.observe(o)), () => {
5113
+ document.removeEventListener("visibilitychange", a), l == null || l.disconnect();
5114
+ };
5115
+ }, []), /* @__PURE__ */ i("div", { ref: t, className: `vsp-prov${e && r ? "" : " vsp-prov--still"}`, "aria-hidden": "true", children: /* @__PURE__ */ i("div", { className: "vsp-prov__plane", children: Array.from({ length: zc }, (a, o) => {
5116
+ const l = Oc(o);
5117
+ return /* @__PURE__ */ i("div", { className: `vsp-prov__row${o % 2 ? " vsp-prov__row--rev" : ""}`, style: { animationDuration: `${80 + o * 11}s`, animationDelay: `-${o * 17}s` }, children: Array.from({ length: Ic }, (c, u) => l.map((d, M) => /* @__PURE__ */ i(Cc, { t: d }, `${u}-${M}`))) }, o);
5109
5118
  }) }) });
5110
5119
  }
5111
5120
  const Ri = {
@@ -5124,7 +5133,7 @@ function dr(t) {
5124
5133
  }
5125
5134
  }
5126
5135
  function xc(t, e) {
5127
- const [n, r] = I(!1), [s, a] = I(null), [o, l] = I(null), [c, u] = I(() => yc(t)), d = Ke((N) => {
5136
+ const [n, r] = z(!1), [s, a] = z(null), [o, l] = z(null), [c, u] = z(() => yc(t)), d = Ke((N) => {
5128
5137
  if (n) return;
5129
5138
  r(!0), l(null);
5130
5139
  let p;
@@ -5138,8 +5147,8 @@ function xc(t, e) {
5138
5147
  }).catch((y) => l(y instanceof Error ? y.message : "Something went wrong. Please try again.")).finally(() => {
5139
5148
  r(!1), a(null);
5140
5149
  });
5141
- }, [t, n, e]), g = Ke(() => d({ connect: !0 }), [d]), M = Ke((N, p) => d({ url: N, ask: p }), [d]);
5142
- return { busy: n, status: s, err: o, connected: c, connect: g, start: M };
5150
+ }, [t, n, e]), M = Ke(() => d({ connect: !0 }), [d]), g = Ke((N, p) => d({ url: N, ask: p }), [d]);
5151
+ return { busy: n, status: s, err: o, connected: c, connect: M, start: g };
5143
5152
  }
5144
5153
  function Dc(t) {
5145
5154
  return /\.(mp4|webm|mov|m4v|ogv|mkv)(\?|#|$)/i.test(t);
@@ -5154,21 +5163,21 @@ function Sc({ poster: t, src: e }) {
5154
5163
  const Ac = { live: !1, atEdge: !1, edgeFrac: null, pct: 0, atLabel: "0:00", labelAt: () => "0:00", endLabel: "0:00", onSeek: () => {
5155
5164
  } };
5156
5165
  function Cn({ idle: t, poster: e, src: n, title: r, page: s, onAct: a, children: o }) {
5157
- const l = jc(t.prefs, t.set), c = Ui(), u = v(null), [d, g] = I(!1);
5166
+ const l = jc(t.prefs, t.set), c = Ui(), u = v(null), [d, M] = z(!1);
5158
5167
  Bt(() => {
5159
5168
  var L;
5160
5169
  const N = (L = u.current) == null ? void 0 : L.parentElement;
5161
5170
  if (!N) return;
5162
- const p = () => g(N.getBoundingClientRect().width < 560);
5171
+ const p = () => M(N.getBoundingClientRect().width < 560);
5163
5172
  if (p(), typeof ResizeObserver > "u") return;
5164
5173
  const y = new ResizeObserver(p);
5165
5174
  return y.observe(N), () => y.disconnect();
5166
5175
  }, []);
5167
- const M = { prevOn: !1, nextOn: !1, onPrev: () => {
5176
+ const g = { prevOn: !1, nextOn: !1, onPrev: () => {
5168
5177
  }, onNext: () => {
5169
5178
  }, playing: !1, playable: !0, playTitle: "Connect to play", onPlay: a };
5170
5179
  return /* @__PURE__ */ h("div", { ref: u, className: `vsp-idleroot${d ? " vsp-idleroot--small" : ""}`, children: [
5171
- /* @__PURE__ */ i(Ei, { page: s, picture: /* @__PURE__ */ i(Sc, { poster: e, src: n }), title: r, desk: c, pos: Ac, sub: null, mute: { muted: t.prefs.muted, onToggle: () => t.set({ muted: !t.prefs.muted }) }, cc: { on: t.prefs.subtitles, onToggle: () => t.set({ subtitles: !t.prefs.subtitles }) }, chip: l.chip, transport: M, picker: l.sheets, sheet: null, voices: null, voicesBtn: null, sheetOpen: l.sheetOpen, onSettings: l.openSettings, onShare: () => Ar(t.shareUrl ?? window.location.href, r), copied: null, onTouch: () => {
5180
+ /* @__PURE__ */ i(Ei, { page: s, picture: /* @__PURE__ */ i(Sc, { poster: e, src: n }), title: r, desk: c, pos: Ac, sub: null, mute: { muted: t.prefs.muted, onToggle: () => t.set({ muted: !t.prefs.muted }) }, cc: { on: t.prefs.subtitles, onToggle: () => t.set({ subtitles: !t.prefs.subtitles }) }, chip: l.chip, transport: g, picker: l.sheets, sheet: null, voices: null, voicesBtn: null, sheetOpen: l.sheetOpen, onSettings: l.openSettings, onShare: () => Ar(t.shareUrl ?? window.location.href, r), copied: null, onTouch: () => {
5172
5181
  } }),
5173
5182
  !l.sheetOpen && /* @__PURE__ */ i("div", { className: "vsp-idle", "data-theme": "dark", children: /* @__PURE__ */ i("div", { className: "vsp-idle__box", children: o }) })
5174
5183
  ] });
@@ -5192,7 +5201,7 @@ function Ec({ idle: t, src: e, ask: n, connect: r, page: s, poster: a = null, on
5192
5201
  ] });
5193
5202
  }
5194
5203
  function _c({ idle: t, connect: e, page: n, poster: r = null, onPick: s }) {
5195
- const [a, o] = I(""), l = v(null), c = v(null), u = a.trim(), d = ei.test(u), g = () => {
5204
+ const [a, o] = z(""), l = v(null), c = v(null), u = a.trim(), d = ei.test(u), M = () => {
5196
5205
  if (!d || e.busy) return;
5197
5206
  const p = /^https?:\/\//i.test(u) ? u : `https://${u}`;
5198
5207
  s(p), e.start(p, !1);
@@ -5202,9 +5211,9 @@ function _c({ idle: t, connect: e, page: n, poster: r = null, onPick: s }) {
5202
5211
  /* @__PURE__ */ i(Pi, { connect: e, onClick: e.connect, label: "Connect to VocalStack" }),
5203
5212
  !e.busy && /* @__PURE__ */ i("div", { className: "vsp-idle__note", children: "Connect your VocalStack account to watch any video with subtitles and spoken translations." })
5204
5213
  ] });
5205
- const M = () => {
5214
+ const g = () => {
5206
5215
  var p;
5207
- d ? g() : (p = l.current) == null || p.focus();
5216
+ d ? M() : (p = l.current) == null || p.focus();
5208
5217
  }, N = (p) => {
5209
5218
  const y = p.trim();
5210
5219
  if (!ei.test(y) || e.busy || y === c.current) return;
@@ -5212,9 +5221,9 @@ function _c({ idle: t, connect: e, page: n, poster: r = null, onPick: s }) {
5212
5221
  const L = /^https?:\/\//i.test(y) ? y : `https://${y}`;
5213
5222
  s(L), e.start(L, !1);
5214
5223
  };
5215
- return /* @__PURE__ */ h(Cn, { idle: t, poster: r, src: null, title: "VocalStack", page: n, onAct: M, children: [
5224
+ return /* @__PURE__ */ h(Cn, { idle: t, poster: r, src: null, title: "VocalStack", page: n, onAct: g, children: [
5216
5225
  /* @__PURE__ */ i("form", { className: "vsp-idle__form", onSubmit: (p) => {
5217
- p.preventDefault(), g();
5226
+ p.preventDefault(), M();
5218
5227
  }, children: /* @__PURE__ */ h("span", { className: "vsp-idle__field", children: [
5219
5228
  /* @__PURE__ */ i(oe, { d: X.link, size: 16, sw: 1.8 }),
5220
5229
  /* @__PURE__ */ i("input", { ref: l, className: "vsp-idle__input", type: "url", inputMode: "url", enterKeyHint: "go", autoComplete: "off", spellCheck: !1, placeholder: "Paste a video link", value: a, onChange: (p) => o(p.target.value), onPaste: (p) => {
@@ -5240,7 +5249,7 @@ function Yc({ idle: t, message: e, onRetry: n, page: r }) {
5240
5249
  ] });
5241
5250
  }
5242
5251
  function Uc(t, e, n) {
5243
- const [r, s] = I(t && e ? void 0 : null);
5252
+ const [r, s] = z(t && e ? void 0 : null);
5244
5253
  return U(() => {
5245
5254
  if (!t) {
5246
5255
  s(null);
@@ -5305,7 +5314,7 @@ const Kc = fa(function(e, n) {
5305
5314
  return (k = r.current) == null ? void 0 : k.toggle();
5306
5315
  }
5307
5316
  }), []);
5308
- const [s, a] = I({ id: e.id ?? "", token: e.token });
5317
+ const [s, a] = z({ id: e.id ?? "", token: e.token });
5309
5318
  U(() => {
5310
5319
  a({ id: e.id ?? "", token: e.token });
5311
5320
  }, [e.id, e.token, e.src]);
@@ -5313,13 +5322,13 @@ const Kc = fa(function(e, n) {
5313
5322
  U(() => {
5314
5323
  o != null && o.id && a({ id: o.id, token: e.token });
5315
5324
  }, [o == null ? void 0 : o.id]);
5316
- const [l, c] = I(null), [u, d] = I(() => ({ ...vc, ...Object.fromEntries(Object.entries({ ...e.initial ?? {}, ...e.settings ?? {} }).filter(([, k]) => k !== void 0)) })), [g, M] = I({}), N = { prefs: u, set: (k) => {
5317
- d((ae) => ({ ...ae, ...k })), M((ae) => ({ ...ae, ...k }));
5318
- }, shareUrl: (K = e.shareUrl) == null ? void 0 : K.call(e, null) }, { muted: p, ...y } = g;
5325
+ const [l, c] = z(null), [u, d] = z(() => ({ ...kc, ...Object.fromEntries(Object.entries({ ...e.initial ?? {}, ...e.settings ?? {} }).filter(([, k]) => k !== void 0)) })), [M, g] = z({}), N = { prefs: u, set: (k) => {
5326
+ d((ae) => ({ ...ae, ...k })), g((ae) => ({ ...ae, ...k }));
5327
+ }, shareUrl: (K = e.shareUrl) == null ? void 0 : K.call(e, null) }, { muted: p, ...y } = M;
5319
5328
  U(() => {
5320
5329
  c(null);
5321
5330
  }, [e.id, e.src]);
5322
- const L = e.src ?? l, m = !s.id && !!L && (l != null || o !== void 0), f = !s.id && !e.src && !l, z = wi({ id: s.id, token: s.token, baseUrl: e.baseUrl, listen: s.listen }), { source: C, gone: D, error: V, reload: _ } = Ao(z, s.id), ee = Eo(z, (C == null ? void 0 : C.recording.id) ?? null), j = Ie(() => Do(z, ee), [z, ee]);
5331
+ const L = e.src ?? l, m = !s.id && !!L && (l != null || o !== void 0), f = !s.id && !e.src && !l, I = wi({ id: s.id, token: s.token, baseUrl: e.baseUrl, listen: s.listen }), { source: C, gone: D, error: V, reload: _ } = Ao(I, s.id), ee = Eo(I, (C == null ? void 0 : C.recording.id) ?? null), j = Ie(() => Do(I, ee), [I, ee]);
5323
5332
  U(() => {
5324
5333
  var k;
5325
5334
  C && ((k = e.onSource) == null || k.call(e, C));
@@ -5331,19 +5340,19 @@ const Kc = fa(function(e, n) {
5331
5340
  return U(() => (Ks(Q ? re.current : null), () => Ks(null)), [Q]), /* @__PURE__ */ i(Oo, { value: j, children: /* @__PURE__ */ i("div", { ref: re, className: `vsp${Q ? " vsp--embed" : ""}${e.className ? ` ${e.className}` : ""}`, "data-theme": (e.mode ?? "video") === "video" || e.dark ? "dark" : "light", "data-mode": (e.mode ?? "video") === "video" ? "video" : "transcript", children: f ? /* @__PURE__ */ i(_c, { idle: N, connect: S, page: !Q, poster: e.poster ?? null, onPick: c }) : m ? /* @__PURE__ */ i(Ec, { idle: N, src: L, ask: !l, connect: S, page: !Q, poster: e.poster ?? null, onClear: l ? () => c(null) : void 0 }) : s.id ? V && !C ? /* @__PURE__ */ i(Yc, { idle: N, message: V.message, onRetry: _, page: !Q }) : /* @__PURE__ */ i(Qc, { ...e, initial: { ...e.initial ?? {}, ...y }, startMuted: p === !0, handle: r, id: s.id, api: j, shared: C, gone: D, loadError: V, reread: _, desk: E, dark: (e.mode ?? "video") === "video" || !!e.dark, onStarted: (k) => a({ id: k.transcriptionId, token: null, listen: { transcriptionId: k.transcriptionId, recordingId: k.recordingId, token: k.token } }) }, s.id) : /* @__PURE__ */ i("div", { className: "vsp-gate", "data-theme": "dark", children: /* @__PURE__ */ i("span", { className: "gfull__spin gfull__holdspin", "aria-label": "Loading" }) }) }) });
5332
5341
  });
5333
5342
  function Qc(t) {
5334
- var Ms, gs, fs, ps, Ns, ms, ys, Ts, ws, Ls, ks, vs, js, zs, Is, Os, Cs, bs, xs, Ds, Ss, As;
5335
- const { api: e, shared: n, gone: r, desk: s, dark: a } = t, o = t.id ?? "", l = Ie(() => Pc(t), []), u = (t.mode ?? "video") === "video", [d, g] = I(t.loadError);
5343
+ var Ms, gs, fs, ps, Ns, ms, ys, Ts, ws, Ls, vs, ks, js, zs, Is, Os, Cs, bs, xs, Ds, Ss, As;
5344
+ const { api: e, shared: n, gone: r, desk: s, dark: a } = t, o = t.id ?? "", l = Ie(() => Pc(t), []), u = (t.mode ?? "video") === "video", [d, M] = z(t.loadError);
5336
5345
  U(() => {
5337
- t.loadError && g(t.loadError);
5346
+ t.loadError && M(t.loadError);
5338
5347
  }, [t.loadError]);
5339
- const [M, N] = I("none"), [p, y] = I(!1), [L, m] = I(""), [f, z] = Ul(), [C, D] = I(null), [V, _] = I(u ? "listen" : "read"), [ee, j] = I(!1), E = v(null), Q = v(/* @__PURE__ */ new Map()), [T, O] = I("main"), S = (w) => {
5348
+ const [g, N] = z("none"), [p, y] = z(!1), [L, m] = z(""), [f, I] = Ul(), [C, D] = z(null), [V, _] = z(u ? "listen" : "read"), [ee, j] = z(!1), E = v(null), Q = v(/* @__PURE__ */ new Map()), [T, O] = z("main"), S = (w) => {
5340
5349
  const Ne = document.querySelector(".vs-sheet--settings"), Qe = Ne == null ? void 0 : Ne.parentElement;
5341
5350
  Ne && Qe && T === "main" && w !== "main" && Qe.style.setProperty("--vs-sheet-top", `${Math.round(Ne.getBoundingClientRect().top - Qe.getBoundingClientRect().top)}px`), O(w);
5342
5351
  };
5343
5352
  U(() => {
5344
5353
  ee || S("main");
5345
5354
  }, [ee]);
5346
- const [re, K] = I(u), k = (n == null ? void 0 : n.recording) ?? null, ae = (k == null ? void 0 : k.id) ?? null, [te, G] = I(l.lang), J = typeof te == "string" ? te : null, [pe, le] = I(l.labels), [Te, je] = I(l.words), [Ee, Le] = I(l.cc), [we, _e] = I(l.translateAudio), [Pe, Se] = I(l.clonedVoices), [B, W] = I(l.removeBackground), A = t.settings;
5355
+ const [re, K] = z(u), k = (n == null ? void 0 : n.recording) ?? null, ae = (k == null ? void 0 : k.id) ?? null, [te, G] = z(l.lang), J = typeof te == "string" ? te : null, [pe, le] = z(l.labels), [Te, je] = z(l.words), [Ee, Le] = z(l.cc), [we, _e] = z(l.translateAudio), [Pe, Se] = z(l.clonedVoices), [B, W] = z(l.removeBackground), A = t.settings;
5347
5356
  U(() => {
5348
5357
  (A == null ? void 0 : A.lang) !== void 0 && G(A.lang);
5349
5358
  }, [A == null ? void 0 : A.lang]), U(() => {
@@ -5367,7 +5376,7 @@ function Qc(t) {
5367
5376
  }, [J, pe, Te, Ee, we, Pe, B]), U(() => {
5368
5377
  n && !n.allowTranslate && J && G(null);
5369
5378
  }, [n, J]);
5370
- const { model: ce, error: F, clearError: me, setLanguage: Z, mergeTranslations: ke, translating: ze, translateFailed: Ge, shownLang: Ae } = Ro(ae, {
5379
+ const { model: ce, error: F, clearError: me, setLanguage: Z, mergeTranslations: ve, translating: ze, translateFailed: Ge, shownLang: Ae } = Ro(ae, {
5371
5380
  lang: null,
5372
5381
  onFrame: (w) => {
5373
5382
  w.type === "job.progress" && D({ state: w.state, processedS: w.processedS ?? 0, totalS: w.totalS ?? null, segmentsDone: w.segmentsDone ?? 0, segmentsTotal: w.segmentsTotal ?? null, pct: w.pct ?? 0, error: w.error ?? null });
@@ -5376,7 +5385,7 @@ function Qc(t) {
5376
5385
  U(() => {
5377
5386
  !Ve || !he || Date.now() - ue.current < 1e4 || (ue.current = Date.now(), t.reread());
5378
5387
  }, [Ve, he, C == null ? void 0 : C.state, C == null ? void 0 : C.processedS, o]);
5379
- const ie = or(($ == null ? void 0 : $.state) ?? ((gs = n == null ? void 0 : n.job) == null ? void 0 : gs.state)), fe = !!ae && (ie === "transcribing" || ie === "queued"), Ue = u && !r && (!n || (fe || ie === "cropping") && ge.length === 0), Y = fe ? ($ == null ? void 0 : $.pct) ?? 0 : 100, R = $o(n == null ? void 0 : n.job, $) ?? (k == null ? void 0 : k.mediaDurationS) ?? null, q = ((fs = ce.segments.values().next().value) == null ? void 0 : fs.language) ?? (k == null ? void 0 : k.spokenLanguage) ?? null, ne = n != null && n.sharedBy ? `Shared by ${n.sharedBy}` : "", de = ((ms = (Ns = (ps = n == null ? void 0 : n.job) == null ? void 0 : ps.source) == null ? void 0 : Ns.name) == null ? void 0 : ms.trim()) || null, Oe = n ? ((ys = n.name) == null ? void 0 : ys.trim()) || de : null, ye = !!((Ts = n == null ? void 0 : n.job) != null && Ts.hasAudio), ve = (ws = n == null ? void 0 : n.job) == null ? void 0 : ws.source, Ce = !ye && !!ve && (ve.kind !== "url" || ve.bytes != null) && (ie === "transcribing" || ie === "queued" || ie === "done"), Ze = ae && (n != null && n.allowDownload) && ye ? ba(e.origin, ae, e.cred) : ae && (n != null && n.allowDownload) && Ce ? nr(e.origin, ae, "source", e.cred) : null, $e = ge[ge.length - 1], ot = $e ? ((Ls = $e.words[$e.words.length - 1]) == null ? void 0 : Ls.end) ?? $e.start : 0, rt = u && fe ? Math.max(ot, ($ == null ? void 0 : $.processedS) ?? 0) : null, gt = Vl(Ze, (ye || Ce) && !!(n != null && n.allowDownload), ge, R, Ce ? ((vs = (ks = n == null ? void 0 : n.job) == null ? void 0 : ks.crop) == null ? void 0 : vs.startS) ?? 0 : 0, rt), be = ((zs = (js = n == null ? void 0 : n.job) == null ? void 0 : js.source) == null ? void 0 : zs.kind) === "url" ? zi(n.job.source.url) : null, st = Bl(ge, R, ((Os = (Is = n == null ? void 0 : n.job) == null ? void 0 : Is.crop) == null ? void 0 : Os.startS) ?? 0, rt), He = !!be, it = He ? st.player : gt, lt = Li(), Ht = v(null), se = Zl({ forcedVoice: t.voice ?? null, recordingId: ae, model: ce, rows: ge, lenS: R, ended: !!ae && !fe, cred: e.cred, langs: lt, srcLang: q, canTranslate: !!(n != null && n.allowTranslate), pickedLang: te, setPickedLang: G, side: s && !re ? Gl : void 0, hearOriginal: H, timed: !!be, stockVoices: u && !Pe, stickyPicker: u, pickerBusy: Ht.current }), Wt = v(null);
5388
+ const ie = or(($ == null ? void 0 : $.state) ?? ((gs = n == null ? void 0 : n.job) == null ? void 0 : gs.state)), fe = !!ae && (ie === "transcribing" || ie === "queued"), Ue = u && !r && (!n || (fe || ie === "cropping") && ge.length === 0), Y = fe ? ($ == null ? void 0 : $.pct) ?? 0 : 100, R = $o(n == null ? void 0 : n.job, $) ?? (k == null ? void 0 : k.mediaDurationS) ?? null, q = ((fs = ce.segments.values().next().value) == null ? void 0 : fs.language) ?? (k == null ? void 0 : k.spokenLanguage) ?? null, ne = n != null && n.sharedBy ? `Shared by ${n.sharedBy}` : "", de = ((ms = (Ns = (ps = n == null ? void 0 : n.job) == null ? void 0 : ps.source) == null ? void 0 : Ns.name) == null ? void 0 : ms.trim()) || null, Oe = n ? ((ys = n.name) == null ? void 0 : ys.trim()) || de : null, ye = !!((Ts = n == null ? void 0 : n.job) != null && Ts.hasAudio), ke = (ws = n == null ? void 0 : n.job) == null ? void 0 : ws.source, Ce = !ye && !!ke && (ke.kind !== "url" || ke.bytes != null) && (ie === "transcribing" || ie === "queued" || ie === "done"), Ze = ae && (n != null && n.allowDownload) && ye ? ba(e.origin, ae, e.cred) : ae && (n != null && n.allowDownload) && Ce ? nr(e.origin, ae, "source", e.cred) : null, $e = ge[ge.length - 1], ot = $e ? ((Ls = $e.words[$e.words.length - 1]) == null ? void 0 : Ls.end) ?? $e.start : 0, rt = u && fe ? Math.max(ot, ($ == null ? void 0 : $.processedS) ?? 0) : null, gt = Vl(Ze, (ye || Ce) && !!(n != null && n.allowDownload), ge, R, Ce ? ((ks = (vs = n == null ? void 0 : n.job) == null ? void 0 : vs.crop) == null ? void 0 : ks.startS) ?? 0 : 0, rt), be = ((zs = (js = n == null ? void 0 : n.job) == null ? void 0 : js.source) == null ? void 0 : zs.kind) === "url" ? zi(n.job.source.url) : null, st = Bl(ge, R, ((Os = (Is = n == null ? void 0 : n.job) == null ? void 0 : Is.crop) == null ? void 0 : Os.startS) ?? 0, rt), He = !!be, it = He ? st.player : gt, lt = Li(), Ht = v(null), se = Zl({ forcedVoice: t.voice ?? null, recordingId: ae, model: ce, rows: ge, lenS: R, ended: !!ae && !fe, cred: e.cred, langs: lt, srcLang: q, canTranslate: !!(n != null && n.allowTranslate), pickedLang: te, setPickedLang: G, side: s && !re ? Gl : void 0, hearOriginal: H, timed: !!be, stockVoices: u && !Pe, stickyPicker: u, pickerBusy: Ht.current }), Wt = v(null);
5380
5389
  U(() => {
5381
5390
  !ae || Wt.current === J || (Wt.current = J, Z(J));
5382
5391
  }, [J, ae]);
@@ -5399,26 +5408,26 @@ function Qc(t) {
5399
5408
  U(() => {
5400
5409
  fe && !x.playing && Ct.current && (Ct.current.scrollTop = Ct.current.scrollHeight);
5401
5410
  }, [fe, ge.length]);
5402
- const ct = Jl(Ct, ge, p, L, y), nn = /* @__PURE__ */ i(Kl, { open: p, q: L, onQ: m, onClose: () => y(!1), hits: ct, desk: s, inline: s }), Je = (n == null ? void 0 : n.name) || t.src || o, ut = !!(n != null && n.allowDownload), Ft = !!(n != null && n.allowExport), dt = se.readLang, kt = dt ? ((Cs = lt == null ? void 0 : lt.languages.find((w) => w.code === dt)) == null ? void 0 : Cs.name) ?? dt.toUpperCase() : null, rn = async () => {
5411
+ const ct = Jl(Ct, ge, p, L, y), nn = /* @__PURE__ */ i(Kl, { open: p, q: L, onQ: m, onClose: () => y(!1), hits: ct, desk: s, inline: s }), Je = (n == null ? void 0 : n.name) || t.src || o, ut = !!(n != null && n.allowDownload), Ft = !!(n != null && n.allowExport), dt = se.readLang, vt = dt ? ((Cs = lt == null ? void 0 : lt.languages.find((w) => w.code === dt)) == null ? void 0 : Cs.name) ?? dt.toUpperCase() : null, rn = async () => {
5403
5412
  if (ae)
5404
5413
  try {
5405
5414
  if (dt && se.canSpeak) {
5406
- z(`Preparing ${Je} in ${kt}${se.readVoiceName ? `, read by ${se.readVoiceName}` : ""} — the download starts when it is ready.`), await Ho(e, { recordingId: ae, lang: dt, voiceKey: se.readVoiceKey, cred: e.cred, request: se.requestTrack }), z(`Downloading ${Je} in ${kt}.`);
5415
+ I(`Preparing ${Je} in ${vt}${se.readVoiceName ? `, read by ${se.readVoiceName}` : ""} — the download starts when it is ready.`), await Ho(e, { recordingId: ae, lang: dt, voiceKey: se.readVoiceKey, cred: e.cred, request: se.requestTrack }), I(`Downloading ${Je} in ${vt}.`);
5407
5416
  return;
5408
5417
  }
5409
5418
  if (ye) {
5410
- z(`Preparing ${Je} as MP3 — the download starts when it is ready.`), await Bo(nr(e.origin, ae, "delivery", e.cred)), z(`Downloading ${Je}.`);
5419
+ I(`Preparing ${Je} as MP3 — the download starts when it is ready.`), await Bo(nr(e.origin, ae, "delivery", e.cred)), I(`Downloading ${Je}.`);
5411
5420
  return;
5412
5421
  }
5413
- Sr(nr(e.origin, ae, "source", e.cred)), z(`Downloading ${Je} — the full audio, since the transcript is still being written.`);
5422
+ Sr(nr(e.origin, ae, "source", e.cred)), I(`Downloading ${Je} — the full audio, since the transcript is still being written.`);
5414
5423
  } catch (w) {
5415
- throw g(Tt(w)), w;
5424
+ throw M(Tt(w)), w;
5416
5425
  }
5417
5426
  }, bt = (w) => {
5418
5427
  if (!ae) return;
5419
- const Ne = Tr.find((Fe) => Fe.key === w).name, Qe = kt ? ` in ${kt}` : "";
5420
- return Vo(e, ae, w, { lang: dt }).then(() => z(fe ? `${Ne} exported${Qe} for the first ${ge.length} segments — the rest is still transcribing.` : `${Ne} exported${Qe}.`)).catch((Fe) => {
5421
- throw g(Tt(Fe)), Fe;
5428
+ const Ne = Tr.find((Fe) => Fe.key === w).name, Qe = vt ? ` in ${vt}` : "";
5429
+ return Vo(e, ae, w, { lang: dt }).then(() => I(fe ? `${Ne} exported${Qe} for the first ${ge.length} segments — the rest is still transcribing.` : `${Ne} exported${Qe}.`)).catch((Fe) => {
5430
+ throw M(Tt(Fe)), Fe;
5422
5431
  });
5423
5432
  }, _t = fe ? "MORE TO COME…" : "END OF TRANSCRIPT", ht = fe ? "var(--brand)" : "var(--ink-28)", Yt = Qo($, ge.length), Xe = x.has && (!se.relang || !!be), qe = v(x);
5424
5433
  qe.current = x;
@@ -5439,25 +5448,25 @@ function Qc(t) {
5439
5448
  });
5440
5449
  const Rt = v(!1), We = v(!1);
5441
5450
  u && (li.video = !0);
5442
- const [xt, vt] = I(!1), [Dn, an] = I(!1);
5451
+ const [xt, kt] = z(!1), [Dn, an] = z(!1);
5443
5452
  U(() => {
5444
5453
  if (!u || Rt.current || !Xe || !re || Ue || t.autoplay === !1) return;
5445
5454
  Rt.current = !0;
5446
5455
  const w = (Fe) => {
5447
5456
  qe.current.playing || We.current || (qe.current.toggle(), Fe > 0 && setTimeout(() => w(Fe - 1), 1500));
5448
5457
  }, Ne = () => {
5449
- qe.current.muted || qe.current.toggleMute(), vt(!0), w(3);
5458
+ qe.current.muted || qe.current.toggleMute(), kt(!0), w(3);
5450
5459
  }, Qe = qe.current;
5451
5460
  if (!Qe.autoplay || t.startMuted) {
5452
5461
  Ne();
5453
5462
  return;
5454
5463
  }
5455
5464
  Qe.autoplay().then((Fe) => {
5456
- Fe === !1 ? vt(!0) : Fe == null && !We.current && Ne();
5465
+ Fe === !1 ? kt(!0) : Fe == null && !We.current && Ne();
5457
5466
  });
5458
5467
  }, [u, Xe, re, Ue]);
5459
5468
  const jt = v(!1), Sn = () => {
5460
- xt && (vt(!1), jt.current = !0, setTimeout(() => {
5469
+ xt && (kt(!1), jt.current = !0, setTimeout(() => {
5461
5470
  jt.current = !1;
5462
5471
  }, 500), qe.current.muted && qe.current.toggleMute());
5463
5472
  }, An = () => {
@@ -5465,14 +5474,14 @@ function Qc(t) {
5465
5474
  jt.current = !1;
5466
5475
  return;
5467
5476
  }
5468
- vt(!1), qe.current.toggleMute();
5477
+ kt(!1), qe.current.toggleMute();
5469
5478
  }, En = () => {
5470
5479
  if (jt.current) {
5471
5480
  jt.current = !1;
5472
5481
  return;
5473
5482
  }
5474
5483
  We.current = !0, qe.current.toggle();
5475
- }, on = (w) => /* @__PURE__ */ i(Yl, { player: x, size: w }), Gt = !!ae && !fe, [Zt, qt] = I(!1);
5484
+ }, on = (w) => /* @__PURE__ */ i(Yl, { player: x, size: w }), Gt = !!ae && !fe, [Zt, qt] = z(!1);
5476
5485
  U(() => {
5477
5486
  if (!ze) {
5478
5487
  qt(!1);
@@ -5481,9 +5490,9 @@ function Qc(t) {
5481
5490
  const w = setTimeout(() => qt(!0), 180);
5482
5491
  return () => clearTimeout(w);
5483
5492
  }, [ze]);
5484
- const P = Zt ? Ae : J, De = rl(ae, J, ge, ke), Be = ml(yl(k), ae, se.readLang), zt = ut || Ft, Kt = (((xs = (bs = n == null ? void 0 : n.job) == null ? void 0 : bs.crop) == null ? void 0 : xs.startS) ?? 0) + cr(x, ge), _n = V === "listen", Dt = _n && (!!be || u), Qi = (w) => {
5493
+ const P = Zt ? Ae : J, De = rl(ae, J, ge, ve), Be = ml(yl(k), ae, se.readLang), zt = ut || Ft, Kt = (((xs = (bs = n == null ? void 0 : n.job) == null ? void 0 : bs.crop) == null ? void 0 : xs.startS) ?? 0) + cr(x, ge), _n = V === "listen", Dt = _n && (!!be || u), Qi = (w) => {
5485
5494
  it.pause(), se.player.pause(), _(w), w === "read" && re && (Xt(!1), K(!1));
5486
- }, Re = se.barChip, Pt = vi(Re.label), Yr = /* @__PURE__ */ i(hr, { value: V, onChange: Qi, bordered: !1, options: dc(Pt, !!be) }), Qt = [...Gt ? [{ key: "summary", label: "Summary" }] : [], ...zt ? [{ key: "export", label: "Export" }] : []], Ur = (w) => /* @__PURE__ */ h(xe, { children: [
5495
+ }, Re = se.barChip, Pt = ki(Re.label), Yr = /* @__PURE__ */ i(hr, { value: V, onChange: Qi, bordered: !1, options: dc(Pt, !!be) }), Qt = [...Gt ? [{ key: "summary", label: "Summary" }] : [], ...zt ? [{ key: "export", label: "Export" }] : []], Ur = (w) => /* @__PURE__ */ h(xe, { children: [
5487
5496
  w === "summary" && Gt && /* @__PURE__ */ i(Tl, { s: Be }),
5488
5497
  w === "export" && /* @__PURE__ */ i(Nl, { audio: ut ? { name: Je, meta: dt && se.canSpeak || ye ? `MP3${R ? ` · ${yt(R)}` : ""}` : "ORIGINAL AUDIO", onClick: rn } : null, formats: Ft, onExport: bt })
5489
5498
  ] }), $i = (w) => /* @__PURE__ */ i(Xo, { index: x.idx, total: Math.max(1, ge.length), frac: x.dur > 0 ? Math.min(1, x.t / x.dur) : 0, glideMs: x.wordSync ? 0 : 220, atLabel: yt(x.t), durLabel: yt(x.dur), stepLabel: w ? `${x.idx + 1} / ${ge.length}` : "", onSeek: se.relang ? Wl : x.seekRow, onSeekFrac: se.relang ? void 0 : x.seekFrac, onScrubStart: x.hold, onScrubEnd: x.release }), Rr = {
@@ -5525,7 +5534,7 @@ function Qc(t) {
5525
5534
  /* @__PURE__ */ i("span", { style: { fontSize: Ne === "sm" ? 17 : 21, lineHeight: 1 }, children: Re.flag }),
5526
5535
  Ot && /* @__PURE__ */ i("span", { style: { position: "absolute", right: 2, bottom: 2, display: "flex", borderRadius: 999, background: "rgba(5,6,21,.7)", padding: 1 }, children: /* @__PURE__ */ i(at, { size: 11, color: "#eef0f8", track: "rgba(255,255,255,.25)" }) })
5527
5536
  ] }) : /* @__PURE__ */ i(zn, { flag: Re.flag, code: Re.code, label: Re.label, bordered: !1, size: Ne, onClick: Re.onClick, style: w }), Hr = { on: !1, title: "Voices", onClick: () => {
5528
- } }, [qi, Ki] = I(!1);
5537
+ } }, [qi, Ki] = z(!1);
5529
5538
  U(() => {
5530
5539
  x.t > 0.3 && Ki(!0);
5531
5540
  }, [x.t]);
@@ -5549,7 +5558,7 @@ function Qc(t) {
5549
5558
  var w;
5550
5559
  (w = Mn.current) == null || w.call(Mn, Jr);
5551
5560
  }, [Xi]);
5552
- const gn = et && et.speaker >= 0 && hn ? xr(ce, et.speaker) : null, [ea, Xr] = I(!1), [Fn, es] = I(null), [ta, ts] = I(null), Gn = v(void 0);
5561
+ const gn = et && et.speaker >= 0 && hn ? xr(ce, et.speaker) : null, [ea, Xr] = z(!1), [Fn, es] = z(null), [ta, ts] = z(null), Gn = v(void 0);
5553
5562
  U(() => () => window.clearTimeout(Gn.current), []);
5554
5563
  const Zn = v(void 0);
5555
5564
  U(() => () => window.clearTimeout(Zn.current), []);
@@ -5588,7 +5597,7 @@ function Qc(t) {
5588
5597
  We.current = !0, qe.current.toggle();
5589
5598
  },
5590
5599
  toggleMute: () => {
5591
- vt(!1), qe.current.toggleMute();
5600
+ kt(!1), qe.current.toggleMute();
5592
5601
  }
5593
5602
  }, U(() => () => {
5594
5603
  t.handle.current = null;
@@ -5708,7 +5717,7 @@ function Qc(t) {
5708
5717
  /* @__PURE__ */ h("div", { style: { flex: 1, minWidth: 0 }, children: [
5709
5718
  /* @__PURE__ */ h("div", { className: "srow__t", children: [
5710
5719
  "Export",
5711
- kt ? ` in ${kt}` : ""
5720
+ vt ? ` in ${vt}` : ""
5712
5721
  ] }),
5713
5722
  /* @__PURE__ */ i("div", { className: "srow__s", children: "Subtitles (SRT / VTT) or a PDF of the transcript" })
5714
5723
  ] }),
@@ -5791,7 +5800,7 @@ function Qc(t) {
5791
5800
  ] }),
5792
5801
  !s && /* @__PURE__ */ i("div", { className: "pubprog__bar", style: { marginTop: 8 }, children: /* @__PURE__ */ i("div", { style: { width: `${Y}%` } }) })
5793
5802
  ] }), Jn = r && /* @__PURE__ */ i("div", { className: "hint", style: { padding: "30px 20px", textAlign: "center", fontSize: 13 }, children: "This link is no longer shared. Ask the person who sent it for a new one." }), ls = /* @__PURE__ */ i(ql, { model: ce, rows: ge, player: x, tail: _t, tailFg: ht, running: fe, desk: s, feedRef: Ct, listener: !0, showLabels: hn, find: L, findOpen: !s && p, lang: P, warm: Zt, onVisible: De, wordHl: dn }), Xn = /* @__PURE__ */ i(Jo, { error: d ?? F ?? (Yn && re ? null : x.error) ?? se.error, onClose: () => {
5794
- g(null), me(), x.clearError(), se.clearError();
5803
+ M(null), me(), x.clearError(), se.clearError();
5795
5804
  } }), cs = [R ? yt(R) : null, q ? q.toUpperCase() : null, ne || "Read-only copy"].filter(Boolean).join(" · "), us = (w) => /* @__PURE__ */ i("div", { className: "ctrans", children: se.noVoice ? se.noVoiceNote : /* @__PURE__ */ h(xe, { children: [
5796
5805
  /* @__PURE__ */ h("div", { className: "ctrans__row", children: [
5797
5806
  /* @__PURE__ */ i("span", { className: "ctrans__sp", "aria-hidden": "true" }),
@@ -5803,7 +5812,7 @@ function Qc(t) {
5803
5812
  /* @__PURE__ */ i("span", { className: "ctrans__mute", children: on(36) })
5804
5813
  ] }),
5805
5814
  /* @__PURE__ */ i("div", { className: "ctrans__scrub", children: $i(w) })
5806
- ] }) }), aa = vl("ga", { tabs: Qt, cur: M, pref: (As = Qt[0]) == null ? void 0 : As.key, onPick: N }), ds = Math.max(0, Math.min(100, Math.round(Y))), oa = Ue && /* @__PURE__ */ h("div", { className: "gfull gfull--hold", "data-theme": "dark", role: "status", "aria-live": "polite", children: [
5815
+ ] }) }), aa = kl("ga", { tabs: Qt, cur: g, pref: (As = Qt[0]) == null ? void 0 : As.key, onPick: N }), ds = Math.max(0, Math.min(100, Math.round(Y))), oa = Ue && /* @__PURE__ */ h("div", { className: "gfull gfull--hold", "data-theme": "dark", role: "status", "aria-live": "polite", children: [
5807
5816
  be && /* @__PURE__ */ i("div", { className: "gfull__holdbg", style: { backgroundImage: `url(https://i.ytimg.com/vi/${be}/hqdefault.jpg)` } }),
5808
5817
  /* @__PURE__ */ i("div", { className: "gfull__hold", children: n ? /* @__PURE__ */ h(xe, { children: [
5809
5818
  Je && /* @__PURE__ */ i("div", { className: "gfull__holdt", children: Je }),
@@ -5820,11 +5829,11 @@ function Qc(t) {
5820
5829
  var w;
5821
5830
  (w = mn.current) == null || w.call(mn, hs);
5822
5831
  }, [hs]);
5823
- const [la, er] = I(!1), tr = !!It && !Ue && (He ? !!x.ended : !x.playing && x.dur > 0 && x.t >= x.dur - 0.5);
5832
+ const [la, er] = z(!1), tr = !!It && !Ue && (He ? !!x.ended : !x.playing && x.dur > 0 && x.t >= x.dur - 0.5);
5824
5833
  U(() => {
5825
5834
  tr || er(!1);
5826
5835
  }, [tr]);
5827
- const ca = t.endCard !== !1 && tr && !la && /* @__PURE__ */ i(kc, { options: { appUrl: t.appUrl, ...t.endCard || {} }, onStarted: t.onStarted, onClose: () => er(!0), onReplay: () => {
5836
+ const ca = t.endCard !== !1 && tr && !la && /* @__PURE__ */ i(vc, { options: { appUrl: t.appUrl, ...t.endCard || {} }, onStarted: t.onStarted, onClose: () => er(!0), onReplay: () => {
5828
5837
  er(!0), We.current = !0, x.seekFrac ? x.seekFrac(0) : x.seekRow(0), x.playing || x.toggle();
5829
5838
  } });
5830
5839
  if (u) return /* @__PURE__ */ h(xe, { children: [
@@ -5871,8 +5880,8 @@ function Qc(t) {
5871
5880
  ] });
5872
5881
  }
5873
5882
  const ua = Qt.length > 0 && !p && /* @__PURE__ */ i("div", { className: "txwidget", children: /* @__PURE__ */ h(Es, { panel: !0, children: [
5874
- /* @__PURE__ */ i(Ci, { tabs: Qt, current: M, onPick: N, gap: M !== "none" }),
5875
- M !== "none" && Ur(M)
5883
+ /* @__PURE__ */ i(Ci, { tabs: Qt, current: g, onPick: N, gap: g !== "none" }),
5884
+ g !== "none" && Ur(g)
5876
5885
  ] }) });
5877
5886
  return /* @__PURE__ */ h(xe, { children: [
5878
5887
  /* @__PURE__ */ i(cc, { dark: a, title: n ? Je : "", subline: n ? cs : "", onOptions: () => j(!0), optionsActive: ee }),
@@ -5926,7 +5935,7 @@ export {
5926
5935
  xi as lineWords,
5927
5936
  cr as pictureT,
5928
5937
  Ln as placePosition,
5929
- kn as realFull,
5938
+ vn as realFull,
5930
5939
  Gc as setErrorReporter,
5931
5940
  Ks as setFullTarget,
5932
5941
  Sl as snapPosition,