@camstack/addon-benchmark 1.2.128 → 1.2.129
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/_stub.js +322 -310
- package/dist/{_virtual_mf-localSharedImportMap___mfe_internal__addon_benchmark_page-DV43V9yL.mjs → _virtual_mf-localSharedImportMap___mfe_internal__addon_benchmark_page-C1j3ttfh.mjs} +2 -2
- package/dist/addon-benchmark.css +1 -1
- package/dist/{hostInit-C6hHUFq4.mjs → hostInit-wVyVjMEo.mjs} +1 -1
- package/dist/remoteEntry.js +1 -1
- package/dist/{virtual_mf-REMOTE_ENTRY_ID___mfe_internal__addon_benchmark_page__remoteEntry_js-DqOULGlw.mjs → virtual_mf-REMOTE_ENTRY_ID___mfe_internal__addon_benchmark_page__remoteEntry_js-BbhR4oyD.mjs} +1 -1
- package/package.json +1 -1
package/dist/_stub.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import "./virtualExposes-erbhyesj.mjs";
|
|
2
|
-
import { a as e, i as t, o as n, r } from "./virtual_mf-REMOTE_ENTRY_ID___mfe_internal__addon_benchmark_page__remoteEntry_js-
|
|
2
|
+
import { a as e, i as t, o as n, r } from "./virtual_mf-REMOTE_ENTRY_ID___mfe_internal__addon_benchmark_page__remoteEntry_js-BbhR4oyD.mjs";
|
|
3
3
|
import { _ as i, b as a, c as o, d as s, f as c, g as l, h as u, i as d, l as f, m as p, n as m, p as h, r as g, t as _, u as v, v as y, x as b, y as x } from "./_virtual_mf___mfe_internal__addon_benchmark_page__loadShare__react__loadShare__.js-GeuxDuzQ.mjs";
|
|
4
4
|
import { a as S, c as C, i as w, n as T, o as E, r as D, s as O } from "./responsive-D15MdAGx.mjs";
|
|
5
|
-
import { c as k, d as
|
|
5
|
+
import { c as k, d as ee, f as te, l as A, s as j, u as M } from "./scene-monitor-copy-m9raf7Ss.mjs";
|
|
6
6
|
import { a as N, i as P, n as F, o as I, r as ne } from "./player-overlays-CfLCPxS9.mjs";
|
|
7
7
|
import { n as L, r as R, t as z } from "./square-BD0VnQoW.mjs";
|
|
8
8
|
import { t as re } from "./grid-2x2-DvZmsUbM.mjs";
|
|
@@ -3077,7 +3077,7 @@ var gi = (e, t) => {
|
|
|
3077
3077
|
"fr",
|
|
3078
3078
|
X,
|
|
3079
3079
|
Y
|
|
3080
|
-
],
|
|
3080
|
+
], ee = () => [
|
|
3081
3081
|
"start",
|
|
3082
3082
|
"end",
|
|
3083
3083
|
"center",
|
|
@@ -3088,14 +3088,14 @@ var gi = (e, t) => {
|
|
|
3088
3088
|
"baseline",
|
|
3089
3089
|
"center-safe",
|
|
3090
3090
|
"end-safe"
|
|
3091
|
-
],
|
|
3091
|
+
], te = () => [
|
|
3092
3092
|
"start",
|
|
3093
3093
|
"end",
|
|
3094
3094
|
"center",
|
|
3095
3095
|
"stretch",
|
|
3096
3096
|
"center-safe",
|
|
3097
3097
|
"end-safe"
|
|
3098
|
-
],
|
|
3098
|
+
], A = () => ["auto", ...w()], j = () => [
|
|
3099
3099
|
ia,
|
|
3100
3100
|
"auto",
|
|
3101
3101
|
"full",
|
|
@@ -3474,19 +3474,19 @@ var gi = (e, t) => {
|
|
|
3474
3474
|
gap: [{ gap: w() }],
|
|
3475
3475
|
"gap-x": [{ "gap-x": w() }],
|
|
3476
3476
|
"gap-y": [{ "gap-y": w() }],
|
|
3477
|
-
"justify-content": [{ justify: [...
|
|
3478
|
-
"justify-items": [{ "justify-items": [...
|
|
3479
|
-
"justify-self": [{ "justify-self": ["auto", ...
|
|
3480
|
-
"align-content": [{ content: ["normal", ...
|
|
3481
|
-
"align-items": [{ items: [...
|
|
3477
|
+
"justify-content": [{ justify: [...ee(), "normal"] }],
|
|
3478
|
+
"justify-items": [{ "justify-items": [...te(), "normal"] }],
|
|
3479
|
+
"justify-self": [{ "justify-self": ["auto", ...te()] }],
|
|
3480
|
+
"align-content": [{ content: ["normal", ...ee()] }],
|
|
3481
|
+
"align-items": [{ items: [...te(), { baseline: ["", "last"] }] }],
|
|
3482
3482
|
"align-self": [{ self: [
|
|
3483
3483
|
"auto",
|
|
3484
|
-
...
|
|
3484
|
+
...te(),
|
|
3485
3485
|
{ baseline: ["", "last"] }
|
|
3486
3486
|
] }],
|
|
3487
|
-
"place-content": [{ "place-content":
|
|
3488
|
-
"place-items": [{ "place-items": [...
|
|
3489
|
-
"place-self": [{ "place-self": ["auto", ...
|
|
3487
|
+
"place-content": [{ "place-content": ee() }],
|
|
3488
|
+
"place-items": [{ "place-items": [...te(), "baseline"] }],
|
|
3489
|
+
"place-self": [{ "place-self": ["auto", ...te()] }],
|
|
3490
3490
|
p: [{ p: w() }],
|
|
3491
3491
|
px: [{ px: w() }],
|
|
3492
3492
|
py: [{ py: w() }],
|
|
@@ -3498,22 +3498,22 @@ var gi = (e, t) => {
|
|
|
3498
3498
|
pr: [{ pr: w() }],
|
|
3499
3499
|
pb: [{ pb: w() }],
|
|
3500
3500
|
pl: [{ pl: w() }],
|
|
3501
|
-
m: [{ m:
|
|
3502
|
-
mx: [{ mx:
|
|
3503
|
-
my: [{ my:
|
|
3504
|
-
ms: [{ ms:
|
|
3505
|
-
me: [{ me:
|
|
3506
|
-
mbs: [{ mbs:
|
|
3507
|
-
mbe: [{ mbe:
|
|
3508
|
-
mt: [{ mt:
|
|
3509
|
-
mr: [{ mr:
|
|
3510
|
-
mb: [{ mb:
|
|
3511
|
-
ml: [{ ml:
|
|
3501
|
+
m: [{ m: A() }],
|
|
3502
|
+
mx: [{ mx: A() }],
|
|
3503
|
+
my: [{ my: A() }],
|
|
3504
|
+
ms: [{ ms: A() }],
|
|
3505
|
+
me: [{ me: A() }],
|
|
3506
|
+
mbs: [{ mbs: A() }],
|
|
3507
|
+
mbe: [{ mbe: A() }],
|
|
3508
|
+
mt: [{ mt: A() }],
|
|
3509
|
+
mr: [{ mr: A() }],
|
|
3510
|
+
mb: [{ mb: A() }],
|
|
3511
|
+
ml: [{ ml: A() }],
|
|
3512
3512
|
"space-x": [{ "space-x": w() }],
|
|
3513
3513
|
"space-x-reverse": ["space-x-reverse"],
|
|
3514
3514
|
"space-y": [{ "space-y": w() }],
|
|
3515
3515
|
"space-y-reverse": ["space-y-reverse"],
|
|
3516
|
-
size: [{ size:
|
|
3516
|
+
size: [{ size: j() }],
|
|
3517
3517
|
"inline-size": [{ inline: ["auto", ...M()] }],
|
|
3518
3518
|
"min-inline-size": [{ "min-inline": ["auto", ...M()] }],
|
|
3519
3519
|
"max-inline-size": [{ "max-inline": ["none", ...M()] }],
|
|
@@ -3523,13 +3523,13 @@ var gi = (e, t) => {
|
|
|
3523
3523
|
w: [{ w: [
|
|
3524
3524
|
s,
|
|
3525
3525
|
"screen",
|
|
3526
|
-
...
|
|
3526
|
+
...j()
|
|
3527
3527
|
] }],
|
|
3528
3528
|
"min-w": [{ "min-w": [
|
|
3529
3529
|
s,
|
|
3530
3530
|
"screen",
|
|
3531
3531
|
"none",
|
|
3532
|
-
...
|
|
3532
|
+
...j()
|
|
3533
3533
|
] }],
|
|
3534
3534
|
"max-w": [{ "max-w": [
|
|
3535
3535
|
s,
|
|
@@ -3537,23 +3537,23 @@ var gi = (e, t) => {
|
|
|
3537
3537
|
"none",
|
|
3538
3538
|
"prose",
|
|
3539
3539
|
{ screen: [o] },
|
|
3540
|
-
...
|
|
3540
|
+
...j()
|
|
3541
3541
|
] }],
|
|
3542
3542
|
h: [{ h: [
|
|
3543
3543
|
"screen",
|
|
3544
3544
|
"lh",
|
|
3545
|
-
...
|
|
3545
|
+
...j()
|
|
3546
3546
|
] }],
|
|
3547
3547
|
"min-h": [{ "min-h": [
|
|
3548
3548
|
"screen",
|
|
3549
3549
|
"lh",
|
|
3550
3550
|
"none",
|
|
3551
|
-
...
|
|
3551
|
+
...j()
|
|
3552
3552
|
] }],
|
|
3553
3553
|
"max-h": [{ "max-h": [
|
|
3554
3554
|
"screen",
|
|
3555
3555
|
"lh",
|
|
3556
|
-
...
|
|
3556
|
+
...j()
|
|
3557
3557
|
] }],
|
|
3558
3558
|
"font-size": [{ text: [
|
|
3559
3559
|
"base",
|
|
@@ -4773,27 +4773,27 @@ function go({ field: e, value: t, onChange: n, disabled: r, translationFn: i })
|
|
|
4773
4773
|
O,
|
|
4774
4774
|
o,
|
|
4775
4775
|
e.suggestLocation
|
|
4776
|
-
]),
|
|
4776
|
+
]), ee = h(() => [...k.suggested, ...k.others], [k]), te = (t) => {
|
|
4777
4777
|
if (!_) if (g.includes(t)) n(g.filter((e) => e !== t));
|
|
4778
4778
|
else {
|
|
4779
4779
|
if (e.maxItems !== void 0 && g.length >= e.maxItems) return;
|
|
4780
4780
|
n([...g, t]);
|
|
4781
4781
|
}
|
|
4782
|
-
},
|
|
4783
|
-
if (e.key === "ArrowDown") e.preventDefault(), S(!0), w((e) =>
|
|
4784
|
-
else if (e.key === "ArrowUp") e.preventDefault(), S(!0), w((e) =>
|
|
4782
|
+
}, A = (e) => {
|
|
4783
|
+
if (e.key === "ArrowDown") e.preventDefault(), S(!0), w((e) => ee.length === 0 ? 0 : (e + 1) % ee.length);
|
|
4784
|
+
else if (e.key === "ArrowUp") e.preventDefault(), S(!0), w((e) => ee.length === 0 ? 0 : (e - 1 + ee.length) % ee.length);
|
|
4785
4785
|
else if (e.key === "Enter") {
|
|
4786
4786
|
e.preventDefault();
|
|
4787
|
-
let t =
|
|
4788
|
-
t &&
|
|
4787
|
+
let t = ee[C];
|
|
4788
|
+
t && te(t.value);
|
|
4789
4789
|
} else e.key === "Escape" ? S(!1) : e.key === "Backspace" && y === "" && g.length > 0 && n(g.slice(0, -1));
|
|
4790
|
-
},
|
|
4790
|
+
}, j = Bu(e.label, i), M = Bu(e.description, i);
|
|
4791
4791
|
return /* @__PURE__ */ H("div", {
|
|
4792
4792
|
className: "min-w-0",
|
|
4793
4793
|
children: [
|
|
4794
|
-
|
|
4794
|
+
j !== void 0 && j !== "" && /* @__PURE__ */ V("label", {
|
|
4795
4795
|
className: oo,
|
|
4796
|
-
children:
|
|
4796
|
+
children: j
|
|
4797
4797
|
}),
|
|
4798
4798
|
D.length > 0 && /* @__PURE__ */ V("div", {
|
|
4799
4799
|
className: "flex flex-wrap gap-1 mb-1.5",
|
|
@@ -4806,7 +4806,7 @@ function go({ field: e, value: t, onChange: n, disabled: r, translationFn: i })
|
|
|
4806
4806
|
type: "button",
|
|
4807
4807
|
className: "shrink-0 hover:text-danger",
|
|
4808
4808
|
"aria-label": `Remove ${e.label}`,
|
|
4809
|
-
onClick: () =>
|
|
4809
|
+
onClick: () => te(e.value),
|
|
4810
4810
|
children: /* @__PURE__ */ V(Vr, { className: "h-2.5 w-2.5" })
|
|
4811
4811
|
})]
|
|
4812
4812
|
}, e.value))
|
|
@@ -4853,7 +4853,7 @@ function go({ field: e, value: t, onChange: n, disabled: r, translationFn: i })
|
|
|
4853
4853
|
onBlur: () => {
|
|
4854
4854
|
E.current = setTimeout(() => S(!1), 120);
|
|
4855
4855
|
},
|
|
4856
|
-
onKeyDown:
|
|
4856
|
+
onKeyDown: A
|
|
4857
4857
|
}),
|
|
4858
4858
|
/* @__PURE__ */ V(I, {
|
|
4859
4859
|
className: "h-3.5 w-3.5 shrink-0 cursor-pointer text-foreground-subtle",
|
|
@@ -4870,10 +4870,10 @@ function go({ field: e, value: t, onChange: n, disabled: r, translationFn: i })
|
|
|
4870
4870
|
onMouseDown: (e) => {
|
|
4871
4871
|
e.preventDefault();
|
|
4872
4872
|
},
|
|
4873
|
-
children:
|
|
4873
|
+
children: ee.length === 0 ? /* @__PURE__ */ V("div", {
|
|
4874
4874
|
className: "px-2.5 py-2 text-[11px] text-foreground-subtle italic",
|
|
4875
4875
|
children: m.length === 0 ? "No matching devices" : `No matches for “${y}”`
|
|
4876
|
-
}) :
|
|
4876
|
+
}) : ee.map((t, n) => {
|
|
4877
4877
|
let r = g.includes(t.value), i = !r && v, a = k.suggested.length, s = o ? n === 0 && a > 0 ? `Suggested · ${e.suggestLocation ?? ""}` : n === a && a > 0 ? "Other devices" : null : null;
|
|
4878
4878
|
return /* @__PURE__ */ H("div", { children: [s !== null && /* @__PURE__ */ V("div", {
|
|
4879
4879
|
className: lo,
|
|
@@ -4889,7 +4889,7 @@ function go({ field: e, value: t, onChange: n, disabled: r, translationFn: i })
|
|
|
4889
4889
|
i ? "opacity-40 cursor-not-allowed" : "cursor-pointer"
|
|
4890
4890
|
].join(" "),
|
|
4891
4891
|
onMouseEnter: () => w(n),
|
|
4892
|
-
onClick: () =>
|
|
4892
|
+
onClick: () => te(t.value),
|
|
4893
4893
|
children: [/* @__PURE__ */ V("span", {
|
|
4894
4894
|
className: ["flex h-3.5 w-3.5 shrink-0 items-center justify-center rounded border", r ? "border-primary bg-primary text-white" : "border-border"].join(" "),
|
|
4895
4895
|
children: r && /* @__PURE__ */ V(mt, { className: "h-2.5 w-2.5" })
|
|
@@ -5113,7 +5113,7 @@ async function Uo(t, r, i) {
|
|
|
5113
5113
|
if (s) return s;
|
|
5114
5114
|
zo.has(t) || (Fo(), n([{
|
|
5115
5115
|
name: t,
|
|
5116
|
-
entry:
|
|
5116
|
+
entry: A(i),
|
|
5117
5117
|
type: "module"
|
|
5118
5118
|
}], { force: !1 }), zo.add(t));
|
|
5119
5119
|
let c = e(`${t}/${r.startsWith("./") ? r.slice(2) : r}`).then((e) => {
|
|
@@ -5775,7 +5775,7 @@ function ys({ offers: e, cameras: t, onToggle: n }) {
|
|
|
5775
5775
|
});
|
|
5776
5776
|
}
|
|
5777
5777
|
function bs({ cell: e, selected: t, onSelect: n, onDragStart: r }) {
|
|
5778
|
-
let { src: i } =
|
|
5778
|
+
let { src: i } = j(e.deviceId, { width: 640 }), a = `${String(100 / e.source.width)}% ${String(100 / e.source.height)}%`, o = e.source.width >= 1 && e.source.height >= 1 ? "center" : `${String(e.source.x / Math.max(1e-6, 1 - e.source.width) * 100)}% ${String(e.source.y / Math.max(1e-6, 1 - e.source.height) * 100)}%`;
|
|
5779
5779
|
return /* @__PURE__ */ V("div", {
|
|
5780
5780
|
role: "presentation",
|
|
5781
5781
|
onPointerDown: (e) => {
|
|
@@ -5866,7 +5866,7 @@ function xs({ cell: e, index: t, cameras: n, onChange: r, onRemove: i }) {
|
|
|
5866
5866
|
});
|
|
5867
5867
|
}
|
|
5868
5868
|
function Ss({ deviceId: e, source: t, onChange: n }) {
|
|
5869
|
-
let { src: r } =
|
|
5869
|
+
let { src: r } = j(e, { width: 640 }), [i, a] = l(null), [o, s] = l(null), c = (e) => {
|
|
5870
5870
|
if (i === null) return;
|
|
5871
5871
|
let t = e.currentTarget.getBoundingClientRect();
|
|
5872
5872
|
t.width === 0 || t.height === 0 || n(_s({
|
|
@@ -6198,10 +6198,10 @@ function Ps(e, t, n) {
|
|
|
6198
6198
|
v(() => () => {
|
|
6199
6199
|
b.current !== null && (clearInterval(b.current), b.current = null, i?.stop({}).catch(() => void 0));
|
|
6200
6200
|
}, [i]);
|
|
6201
|
-
let E = o((e) => x(async () => i?.runAction({ actionId: e })), [i, x]), O = o((e) => x(async () => i?.playSound({ soundId: e })), [i, x]), k = o((e) => x(async () => i?.setLightOn({ on: e })), [i, x]),
|
|
6201
|
+
let E = o((e) => x(async () => i?.runAction({ actionId: e })), [i, x]), O = o((e) => x(async () => i?.playSound({ soundId: e })), [i, x]), k = o((e) => x(async () => i?.setLightOn({ on: e })), [i, x]), ee = o((e, t) => x(async () => i?.setLightMode(t === void 0 ? { mode: e } : {
|
|
6202
6202
|
mode: e,
|
|
6203
6203
|
level: t
|
|
6204
|
-
})), [i, x]),
|
|
6204
|
+
})), [i, x]), te = o((e) => x(async () => i?.setLightLevel({ level: e })), [i, x]);
|
|
6205
6205
|
return {
|
|
6206
6206
|
features: s,
|
|
6207
6207
|
actions: d,
|
|
@@ -6211,8 +6211,8 @@ function Ps(e, t, n) {
|
|
|
6211
6211
|
runAction: E,
|
|
6212
6212
|
playSound: O,
|
|
6213
6213
|
setLightOn: k,
|
|
6214
|
-
setLightMode:
|
|
6215
|
-
setLightLevel:
|
|
6214
|
+
setLightMode: ee,
|
|
6215
|
+
setLightLevel: te,
|
|
6216
6216
|
busy: p,
|
|
6217
6217
|
error: h,
|
|
6218
6218
|
driving: _
|
|
@@ -6767,7 +6767,7 @@ function Ks({ direction: e, icon: t, disabled: n, className: r, variant: i, onMo
|
|
|
6767
6767
|
});
|
|
6768
6768
|
}
|
|
6769
6769
|
function qs({ controls: e, mode: t = "overlay", showPresets: n, showZoom: r = !0, showHome: i = !0, className: a }) {
|
|
6770
|
-
let { move: s, startContinuous: d, stopContinuous: f, zoom: p, goHome: m, homePreset: h, goToPreset: g, savePreset: _, updatePreset: y, deletePreset: b, presets: x, options: S, busy: C, error: w } = e, T = wo(), [E, D] = l(!1), [O, k] = l(""),
|
|
6770
|
+
let { move: s, startContinuous: d, stopContinuous: f, zoom: p, goHome: m, homePreset: h, goToPreset: g, savePreset: _, updatePreset: y, deletePreset: b, presets: x, options: S, busy: C, error: w } = e, T = wo(), [E, D] = l(!1), [O, k] = l(""), ee = u(null), te = u(null), [A, j] = l(null), M = t === "panel", N = r && (S?.hasZoom ?? !0), P = S?.supportsPresets ?? x.length > 0, F = (n ?? P) && P, ne = M && (S?.supportsPresets ?? !1), L = S?.maxPresets !== void 0 && x.length >= S.maxPresets, R = o(async () => {
|
|
6771
6771
|
let e = O.trim();
|
|
6772
6772
|
!e || C || L || await _(e) !== void 0 && k("");
|
|
6773
6773
|
}, [
|
|
@@ -6791,12 +6791,12 @@ function qs({ controls: e, mode: t = "overlay", showPresets: n, showZoom: r = !0
|
|
|
6791
6791
|
}, [T, y]);
|
|
6792
6792
|
c(() => {
|
|
6793
6793
|
if (!E) {
|
|
6794
|
-
|
|
6794
|
+
j(null);
|
|
6795
6795
|
return;
|
|
6796
6796
|
}
|
|
6797
6797
|
let e = () => {
|
|
6798
|
-
let e =
|
|
6799
|
-
e &&
|
|
6798
|
+
let e = ee.current?.getBoundingClientRect();
|
|
6799
|
+
e && j({
|
|
6800
6800
|
top: e.bottom + 4,
|
|
6801
6801
|
right: window.innerWidth - e.right
|
|
6802
6802
|
});
|
|
@@ -6808,7 +6808,7 @@ function qs({ controls: e, mode: t = "overlay", showPresets: n, showZoom: r = !0
|
|
|
6808
6808
|
if (!E) return;
|
|
6809
6809
|
let e = (e) => {
|
|
6810
6810
|
let t = e.target;
|
|
6811
|
-
|
|
6811
|
+
te.current?.contains(t) || ee.current?.contains(t) || D(!1);
|
|
6812
6812
|
}, t = (e) => {
|
|
6813
6813
|
e.key === "Escape" && D(!1);
|
|
6814
6814
|
};
|
|
@@ -6911,19 +6911,19 @@ function qs({ controls: e, mode: t = "overlay", showPresets: n, showZoom: r = !0
|
|
|
6911
6911
|
F && /* @__PURE__ */ H("div", {
|
|
6912
6912
|
className: "relative",
|
|
6913
6913
|
children: [/* @__PURE__ */ H("button", {
|
|
6914
|
-
ref:
|
|
6914
|
+
ref: ee,
|
|
6915
6915
|
type: "button",
|
|
6916
6916
|
onClick: () => D((e) => !e),
|
|
6917
6917
|
disabled: C,
|
|
6918
6918
|
className: Z("flex items-center gap-1 rounded px-2 text-[10px] disabled:opacity-40", M ? "h-9 text-foreground hover:bg-surface-hover" : "h-7 text-white hover:bg-white/15"),
|
|
6919
6919
|
title: "Presets",
|
|
6920
6920
|
children: ["Presets", /* @__PURE__ */ V(I, { className: Z("h-3 w-3 transition-transform", E && "rotate-180") })]
|
|
6921
|
-
}), E &&
|
|
6922
|
-
ref:
|
|
6921
|
+
}), E && A && ce(/* @__PURE__ */ H("div", {
|
|
6922
|
+
ref: te,
|
|
6923
6923
|
style: {
|
|
6924
6924
|
position: "fixed",
|
|
6925
|
-
top:
|
|
6926
|
-
right:
|
|
6925
|
+
top: A.top,
|
|
6926
|
+
right: A.right,
|
|
6927
6927
|
zIndex: 60
|
|
6928
6928
|
},
|
|
6929
6929
|
className: Z("rounded-lg shadow-xl py-1", ne ? "min-w-[220px]" : "min-w-[140px]", M ? "bg-surface border border-border" : "border border-white/30 bg-zinc-900/95 backdrop-blur-md"),
|
|
@@ -8260,19 +8260,19 @@ function ol({ deviceId: e }) {
|
|
|
8260
8260
|
}
|
|
8261
8261
|
}), [g]), T = u(_);
|
|
8262
8262
|
T.current = _;
|
|
8263
|
-
let { state: D, beginScrub: O, updateScrub: k, endScrub:
|
|
8263
|
+
let { state: D, beginScrub: O, updateScrub: k, endScrub: ee, seek: te, setPlayhead: A, reset: j } = Cc(w, o(() => T.current === "live", []));
|
|
8264
8264
|
v(() => {
|
|
8265
|
-
y !== null &&
|
|
8266
|
-
}, [y,
|
|
8267
|
-
(!m.channelOpen || _ === "live") &&
|
|
8265
|
+
y !== null && A(y);
|
|
8266
|
+
}, [y, A]), v(() => {
|
|
8267
|
+
(!m.channelOpen || _ === "live") && j();
|
|
8268
8268
|
}, [
|
|
8269
8269
|
m.channelOpen,
|
|
8270
8270
|
_,
|
|
8271
|
-
|
|
8271
|
+
j
|
|
8272
8272
|
]);
|
|
8273
8273
|
let M = o(() => {
|
|
8274
|
-
g({ t: "goLive" }),
|
|
8275
|
-
}, [g,
|
|
8274
|
+
g({ t: "goLive" }), j();
|
|
8275
|
+
}, [g, j]), N = o(() => {
|
|
8276
8276
|
g({
|
|
8277
8277
|
t: "setRate",
|
|
8278
8278
|
rate: +(T.current === "paused")
|
|
@@ -8391,7 +8391,7 @@ function ol({ deviceId: e }) {
|
|
|
8391
8391
|
let t = Mc(e, pe);
|
|
8392
8392
|
if (!t) return;
|
|
8393
8393
|
if (C.current) {
|
|
8394
|
-
|
|
8394
|
+
te(t.fromMs, "timeline");
|
|
8395
8395
|
return;
|
|
8396
8396
|
}
|
|
8397
8397
|
let n = `Recording · ${new Date(t.fromMs).toLocaleString(void 0, {
|
|
@@ -8404,16 +8404,16 @@ function ol({ deviceId: e }) {
|
|
|
8404
8404
|
}, [
|
|
8405
8405
|
pe,
|
|
8406
8406
|
Se,
|
|
8407
|
-
|
|
8407
|
+
te
|
|
8408
8408
|
]), we = o(() => {
|
|
8409
8409
|
O("timeline");
|
|
8410
8410
|
}, [O]), Te = o((e) => {
|
|
8411
8411
|
k(e, "timeline");
|
|
8412
8412
|
}, [k]), Ee = o((e) => {
|
|
8413
|
-
|
|
8414
|
-
}, [pe,
|
|
8413
|
+
ee(Mc(e, pe)?.fromMs ?? e, "timeline");
|
|
8414
|
+
}, [pe, ee]), De = o((e) => {
|
|
8415
8415
|
if (C.current) {
|
|
8416
|
-
|
|
8416
|
+
te(e.timestamp - nl, "timeline");
|
|
8417
8417
|
return;
|
|
8418
8418
|
}
|
|
8419
8419
|
let t = `${e.label} · ${new Date(e.timestamp).toLocaleTimeString(void 0, {
|
|
@@ -8421,7 +8421,7 @@ function ol({ deviceId: e }) {
|
|
|
8421
8421
|
minute: "2-digit"
|
|
8422
8422
|
})}`;
|
|
8423
8423
|
Se(`${e.kind}:${e.id}`, e.timestamp - nl, e.timestamp + rl, t, e.timestamp);
|
|
8424
|
-
}, [Se,
|
|
8424
|
+
}, [Se, te]), Oe = o((e) => {
|
|
8425
8425
|
i((t) => t === e ? null : e);
|
|
8426
8426
|
}, []), ke = ue.isLoading, Ae = de.isLoading, je = (ve.isLoading || ye.isLoading || G.isLoading) && he, Me = h(() => Bc(ie.fromMs, ie.toMs, 5), [ie.fromMs, ie.toMs]), Ne = S ? D.scrubbing ? D.scrubEpoch : D.playheadEpoch : a, Pe = S && (_ === "playing" || _ === "paused");
|
|
8427
8427
|
return /* @__PURE__ */ H("div", {
|
|
@@ -11409,7 +11409,7 @@ function Ku({ trpc: e, addonId: t, nodeId: n, title: r, disabled: i, onAfterChan
|
|
|
11409
11409
|
f,
|
|
11410
11410
|
JSON.stringify(T)
|
|
11411
11411
|
]);
|
|
11412
|
-
let k = h(() => Wu(p), [p]),
|
|
11412
|
+
let k = h(() => Wu(p), [p]), ee = h(() => p ? Gu(p) : null, [p]), te = async (r) => {
|
|
11413
11413
|
if (f === "override") {
|
|
11414
11414
|
let e = D ?? k, t = {};
|
|
11415
11415
|
for (let n of Object.keys(r)) r[n] !== e[n] && (t[n] = r[n]);
|
|
@@ -11458,7 +11458,7 @@ function Ku({ trpc: e, addonId: t, nodeId: n, title: r, disabled: i, onAfterChan
|
|
|
11458
11458
|
y
|
|
11459
11459
|
]
|
|
11460
11460
|
});
|
|
11461
|
-
if (!p || !
|
|
11461
|
+
if (!p || !ee) return /* @__PURE__ */ H("div", {
|
|
11462
11462
|
className: "text-xs text-foreground-subtle",
|
|
11463
11463
|
children: [
|
|
11464
11464
|
r ?? t,
|
|
@@ -11467,16 +11467,16 @@ function Ku({ trpc: e, addonId: t, nodeId: n, title: r, disabled: i, onAfterChan
|
|
|
11467
11467
|
"."
|
|
11468
11468
|
]
|
|
11469
11469
|
});
|
|
11470
|
-
let
|
|
11470
|
+
let A = f === "override" ? {
|
|
11471
11471
|
...k,
|
|
11472
11472
|
...T
|
|
11473
|
-
} : k,
|
|
11473
|
+
} : k, j = /* @__PURE__ */ H(U, { children: [f === "override" ? /* @__PURE__ */ V("div", {
|
|
11474
11474
|
className: "mb-2 text-[11px] text-foreground-subtle",
|
|
11475
11475
|
children: "Benchmark override — applies to this run only. The addon's saved settings are not changed."
|
|
11476
11476
|
}) : null, /* @__PURE__ */ V(Hu, {
|
|
11477
|
-
schema:
|
|
11478
|
-
values:
|
|
11479
|
-
onChange:
|
|
11477
|
+
schema: ee,
|
|
11478
|
+
values: A,
|
|
11479
|
+
onChange: te,
|
|
11480
11480
|
disabled: i === !0 || x
|
|
11481
11481
|
})] });
|
|
11482
11482
|
return s === !0 ? /* @__PURE__ */ H("section", {
|
|
@@ -11499,7 +11499,7 @@ function Ku({ trpc: e, addonId: t, nodeId: n, title: r, disabled: i, onAfterChan
|
|
|
11499
11499
|
]
|
|
11500
11500
|
}), C ? /* @__PURE__ */ V("div", {
|
|
11501
11501
|
className: "border-t border-border px-4 py-3",
|
|
11502
|
-
children:
|
|
11502
|
+
children: j
|
|
11503
11503
|
}) : null]
|
|
11504
11504
|
}) : r ? /* @__PURE__ */ H("section", {
|
|
11505
11505
|
className: "rounded-lg border border-border bg-surface overflow-hidden",
|
|
@@ -11511,9 +11511,9 @@ function Ku({ trpc: e, addonId: t, nodeId: n, title: r, disabled: i, onAfterChan
|
|
|
11511
11511
|
})
|
|
11512
11512
|
}), /* @__PURE__ */ V("div", {
|
|
11513
11513
|
className: "px-4 py-3",
|
|
11514
|
-
children:
|
|
11514
|
+
children: j
|
|
11515
11515
|
})]
|
|
11516
|
-
}) : /* @__PURE__ */ V("div", { children:
|
|
11516
|
+
}) : /* @__PURE__ */ V("div", { children: j });
|
|
11517
11517
|
}
|
|
11518
11518
|
//#endregion
|
|
11519
11519
|
//#region ../ui-library/src/primitives/collapsible-card.tsx
|
|
@@ -13295,9 +13295,16 @@ function Mf(e) {
|
|
|
13295
13295
|
}) : /* @__PURE__ */ V("div", {
|
|
13296
13296
|
className: "text-rose-300 leading-tight py-0.5 break-words",
|
|
13297
13297
|
children: r
|
|
13298
|
-
}) : /* @__PURE__ */
|
|
13299
|
-
className: "text-
|
|
13300
|
-
children:
|
|
13298
|
+
}) : /* @__PURE__ */ H("div", {
|
|
13299
|
+
className: "text-amber-300/90 leading-tight py-0.5",
|
|
13300
|
+
children: [
|
|
13301
|
+
"not wired on this surface — this player was mounted without",
|
|
13302
|
+
/* @__PURE__ */ V("span", {
|
|
13303
|
+
className: "text-white/80",
|
|
13304
|
+
children: " getSessionDebug"
|
|
13305
|
+
}),
|
|
13306
|
+
", so the server half cannot be asked"
|
|
13307
|
+
]
|
|
13301
13308
|
}),
|
|
13302
13309
|
o !== null && /* @__PURE__ */ V("div", {
|
|
13303
13310
|
className: "mt-1 pt-0.5 border-t border-white/15 text-white/40 break-all leading-tight",
|
|
@@ -13380,13 +13387,13 @@ function Vf(e, t, n, r) {
|
|
|
13380
13387
|
return r ? Zd(i) : i;
|
|
13381
13388
|
}
|
|
13382
13389
|
var Hf = 8e3;
|
|
13383
|
-
function Uf({ serverUrl: e, streamKey: t, label: n, autoPlay: r = !0, muted: i = !0, showControls: a = !0, showStats: s = !1, onPlaybackStats: c, onClientNetworkSample: d, onConnectTiming: f, className: p = "", onStateChange: m, onError: h, onReconnectAttempt: g, overlay: _, createSession: y, sendAnswer: b, handleOffer: x, getIceServers: S, addIceCandidate: C, getIceCandidates: w, closeSession: T, getSessionState: E, getSessionDebug: D, reoffer: O, posterUrl: k, hintsOverride:
|
|
13384
|
-
let N = u(null), P = u(null), F = u(null), I = u(/* @__PURE__ */ new Set()), ne = u(null), L = u(null), R = u(0), z = u(!0), re = u(
|
|
13385
|
-
re.current =
|
|
13390
|
+
function Uf({ serverUrl: e, streamKey: t, label: n, autoPlay: r = !0, muted: i = !0, showControls: a = !0, showStats: s = !1, onPlaybackStats: c, onClientNetworkSample: d, onConnectTiming: f, className: p = "", onStateChange: m, onError: h, onReconnectAttempt: g, overlay: _, createSession: y, sendAnswer: b, handleOffer: x, getIceServers: S, addIceCandidate: C, getIceCandidates: w, closeSession: T, getSessionState: E, getSessionDebug: D, reoffer: O, posterUrl: k, hintsOverride: ee, onAdaptiveHints: te, reconnectSignal: A, onControlChannel: j, onVideoElement: M }) {
|
|
13391
|
+
let N = u(null), P = u(null), F = u(null), I = u(/* @__PURE__ */ new Set()), ne = u(null), L = u(null), R = u(0), z = u(!0), re = u(j);
|
|
13392
|
+
re.current = j;
|
|
13386
13393
|
let ie = u(M);
|
|
13387
13394
|
ie.current = M, v(() => (ie.current?.(N.current), () => ie.current?.(null)), []);
|
|
13388
|
-
let B = u(
|
|
13389
|
-
B.current =
|
|
13395
|
+
let B = u(te);
|
|
13396
|
+
B.current = te;
|
|
13390
13397
|
let ae = u(null), oe = o((e, t, n) => {
|
|
13391
13398
|
let r = B.current;
|
|
13392
13399
|
if (!r) return;
|
|
@@ -13447,7 +13454,7 @@ function Uf({ serverUrl: e, streamKey: t, label: n, autoPlay: r = !0, muted: i =
|
|
|
13447
13454
|
let a = new AbortController();
|
|
13448
13455
|
ne.current = a;
|
|
13449
13456
|
try {
|
|
13450
|
-
let o = n ? void 0 : Bf(e), s = Vf(If(P.current),
|
|
13457
|
+
let o = n ? void 0 : Bf(e), s = Vf(If(P.current), ee, n ? await Bf(e) : void 0, !n);
|
|
13451
13458
|
oe(n ? "probe-climb" : "cold-start", s, zf(e));
|
|
13452
13459
|
let { sessionId: c, sdpOffer: l, iceServers: u } = await y(s);
|
|
13453
13460
|
if (I.current.add(c), o !== void 0 && o.then((e) => {
|
|
@@ -13517,7 +13524,7 @@ function Uf({ serverUrl: e, streamKey: t, label: n, autoPlay: r = !0, muted: i =
|
|
|
13517
13524
|
T,
|
|
13518
13525
|
Le,
|
|
13519
13526
|
h,
|
|
13520
|
-
|
|
13527
|
+
ee,
|
|
13521
13528
|
oe
|
|
13522
13529
|
]), q = o(async () => {
|
|
13523
13530
|
if (z.current) {
|
|
@@ -13629,7 +13636,7 @@ function Uf({ serverUrl: e, streamKey: t, label: n, autoPlay: r = !0, muted: i =
|
|
|
13629
13636
|
}
|
|
13630
13637
|
let y = await d.createOffer();
|
|
13631
13638
|
if (l.offerCreatedMs = c(), await d.setLocalDescription(y), l.localSetMs = c(), !z.current || o.signal.aborted) return;
|
|
13632
|
-
let b = r ? await Bf(e) : void 0, E = Vf(If(P.current),
|
|
13639
|
+
let b = r ? await Bf(e) : void 0, E = Vf(If(P.current), ee, b, !r);
|
|
13633
13640
|
oe(r ? "probe-climb" : "cold-start", E, zf(e));
|
|
13634
13641
|
let D = c(), { sessionId: O, sdpAnswer: k } = await x(d.localDescription?.sdp ?? y.sdp ?? "", void 0, E);
|
|
13635
13642
|
if (l.signalingRttMs = c() - D, _ = O, I.current.add(O), s !== void 0 && s.then((e) => {
|
|
@@ -13679,7 +13686,7 @@ function Uf({ serverUrl: e, streamKey: t, label: n, autoPlay: r = !0, muted: i =
|
|
|
13679
13686
|
Le,
|
|
13680
13687
|
h,
|
|
13681
13688
|
Be,
|
|
13682
|
-
|
|
13689
|
+
ee,
|
|
13683
13690
|
oe
|
|
13684
13691
|
]);
|
|
13685
13692
|
de.current = o(async (t, n) => {
|
|
@@ -13741,7 +13748,7 @@ function Uf({ serverUrl: e, streamKey: t, label: n, autoPlay: r = !0, muted: i =
|
|
|
13741
13748
|
let y = await Bf(e), b = {
|
|
13742
13749
|
...If(P.current),
|
|
13743
13750
|
...y === void 0 ? {} : { downlinkMbps: y },
|
|
13744
|
-
...
|
|
13751
|
+
...ee
|
|
13745
13752
|
};
|
|
13746
13753
|
oe("renegotiate", b, zf(e));
|
|
13747
13754
|
let { sessionId: x, sdpAnswer: T } = await r(t, o.localDescription?.sdp ?? v.sdp ?? "", n, b);
|
|
@@ -13786,7 +13793,7 @@ function Uf({ serverUrl: e, streamKey: t, label: n, autoPlay: r = !0, muted: i =
|
|
|
13786
13793
|
w,
|
|
13787
13794
|
Le,
|
|
13788
13795
|
Be,
|
|
13789
|
-
|
|
13796
|
+
ee,
|
|
13790
13797
|
oe
|
|
13791
13798
|
]);
|
|
13792
13799
|
let Ue = Oe ? He : Ee ? Ve : q, We = u(() => {}), Ge = u(g);
|
|
@@ -13854,10 +13861,10 @@ function Uf({ serverUrl: e, streamKey: t, label: n, autoPlay: r = !0, muted: i =
|
|
|
13854
13861
|
Xe();
|
|
13855
13862
|
}
|
|
13856
13863
|
}, [e, t]);
|
|
13857
|
-
let $e = u(
|
|
13864
|
+
let $e = u(A);
|
|
13858
13865
|
v(() => {
|
|
13859
|
-
$e.current !==
|
|
13860
|
-
}, [
|
|
13866
|
+
$e.current !== A && ($e.current = A, z.current && Xe());
|
|
13867
|
+
}, [A]);
|
|
13861
13868
|
let et = () => {
|
|
13862
13869
|
if (N.current) {
|
|
13863
13870
|
let e = !N.current.muted;
|
|
@@ -13949,7 +13956,11 @@ function Uf({ serverUrl: e, streamKey: t, label: n, autoPlay: r = !0, muted: i =
|
|
|
13949
13956
|
}
|
|
13950
13957
|
let e = !1, t = async () => {
|
|
13951
13958
|
let t = U.current;
|
|
13952
|
-
if (t
|
|
13959
|
+
if (t === null) {
|
|
13960
|
+
lt("no session id on this player yet — nothing to ask the server about");
|
|
13961
|
+
return;
|
|
13962
|
+
}
|
|
13963
|
+
try {
|
|
13953
13964
|
let n = await D(t);
|
|
13954
13965
|
if (e) return;
|
|
13955
13966
|
st(n), lt(null);
|
|
@@ -15465,25 +15476,25 @@ function Nm(e, t) {
|
|
|
15465
15476
|
return t ? (Am[e] ?? 0) >= (Am[t] ?? 0) : !0;
|
|
15466
15477
|
}
|
|
15467
15478
|
function Pm({ agentId: e, addonId: t, deviceId: n, containerDeviceId: r, integrationId: i, requestId: a, level: s, maxHeight: d = "max-h-96", showScope: f = !1, showDeviceChip: p = !1, showFilters: m = !0, limit: g = 100, liveBuffer: _, onClose: y, className: b }) {
|
|
15468
|
-
let [x, S] = l(""), [C, w] = l(""), [T, E] = l(s ?? "info"), D = e, O = t ?? (x || void 0), k = n ?? (C ? Number(C) : void 0),
|
|
15479
|
+
let [x, S] = l(""), [C, w] = l(""), [T, E] = l(s ?? "info"), D = e, O = t ?? (x || void 0), k = n ?? (C ? Number(C) : void 0), ee = i, te = a, A = h(() => {
|
|
15469
15480
|
let e = {};
|
|
15470
|
-
return D && (e.agentId = D), O && (e.addonId = O), r !== void 0 && Number.isFinite(r) ? e.containerDeviceId = r : k !== void 0 && Number.isFinite(k) && (e.deviceId = k),
|
|
15481
|
+
return D && (e.agentId = D), O && (e.addonId = O), r !== void 0 && Number.isFinite(r) ? e.containerDeviceId = r : k !== void 0 && Number.isFinite(k) && (e.deviceId = k), ee && (e.integrationId = ee), te && (e.requestId = te), Object.keys(e).length > 0 ? e : void 0;
|
|
15471
15482
|
}, [
|
|
15472
15483
|
D,
|
|
15473
15484
|
O,
|
|
15474
15485
|
k,
|
|
15475
15486
|
r,
|
|
15476
|
-
|
|
15477
|
-
|
|
15478
|
-
]),
|
|
15487
|
+
ee,
|
|
15488
|
+
te
|
|
15489
|
+
]), j = Em(Mm), M = _ ?? j, P = M.entries, [F, ne] = l(0), [L, R] = l(!0), z = u(!1), [re, B] = l(!1), [ae, oe] = l(!1), [U, se] = l(/* @__PURE__ */ new Set()), [ce, le] = l(""), ue = u(null), de = `${D ?? ""}:${O ?? ""}:${String(k ?? "")}:${String(r ?? "")}:${ee ?? ""}:${te ?? ""}`, fe = u(de);
|
|
15479
15490
|
v(() => {
|
|
15480
15491
|
fe.current !== de && (fe.current = de, M.reset(), ne(0), se(/* @__PURE__ */ new Set()), B(!1));
|
|
15481
15492
|
}, [de, M]);
|
|
15482
15493
|
let { data: pe, isLoading: me } = J.logs.query.useQuery({
|
|
15483
|
-
...
|
|
15494
|
+
...A ? { tags: A } : {},
|
|
15484
15495
|
limit: g
|
|
15485
15496
|
}, { staleTime: 3e4 });
|
|
15486
|
-
J.logs.subscribe.useSubscription(
|
|
15497
|
+
J.logs.subscribe.useSubscription(A ? { tags: A } : {}, { onData: (e) => {
|
|
15487
15498
|
M.append(e);
|
|
15488
15499
|
} });
|
|
15489
15500
|
let W = h(() => {
|
|
@@ -15553,11 +15564,11 @@ function Pm({ agentId: e, addonId: t, deviceId: n, containerDeviceId: r, integra
|
|
|
15553
15564
|
oe(!0), setTimeout(() => oe(!1), 1500);
|
|
15554
15565
|
});
|
|
15555
15566
|
}, [W]), Ce = J.logs.clear.useMutation(), we = o(() => {
|
|
15556
|
-
ne(Date.now()), M.reset(), Ce.mutate(
|
|
15567
|
+
ne(Date.now()), M.reset(), Ce.mutate(A ? { tags: A } : {});
|
|
15557
15568
|
}, [
|
|
15558
15569
|
M,
|
|
15559
15570
|
Ce,
|
|
15560
|
-
|
|
15571
|
+
A
|
|
15561
15572
|
]), Te = o((e) => {
|
|
15562
15573
|
se((t) => {
|
|
15563
15574
|
let n = new Set(t);
|
|
@@ -16069,19 +16080,19 @@ function Ym({ agentId: e, addonId: t, deviceId: n, defaultCategories: r, categor
|
|
|
16069
16080
|
v(() => {
|
|
16070
16081
|
S.current !== y && (S.current = y, x(new Set(_)));
|
|
16071
16082
|
}, [y, _]);
|
|
16072
|
-
let C = Em(Jm), w = p ?? C, T = w.entries, [E, D] = l(!0), [O, k] = l(/* @__PURE__ */ new Set()), [
|
|
16083
|
+
let C = Em(Jm), w = p ?? C, T = w.entries, [E, D] = l(!0), [O, k] = l(/* @__PURE__ */ new Set()), [ee, te] = l(""), [A, j] = l(!1), [P, F] = l(""), [ne, L] = l(0), R = u(null), z = u(null), re = `${e ?? ""}:${t ?? ""}:${String(n ?? "")}:${a ?? ""}`, B = u(re);
|
|
16073
16084
|
v(() => {
|
|
16074
16085
|
B.current !== re && (B.current = re, w.reset(), k(/* @__PURE__ */ new Set()), L(0));
|
|
16075
16086
|
}, [re, w]), v(() => {
|
|
16076
|
-
if (!
|
|
16087
|
+
if (!A) return;
|
|
16077
16088
|
let e = (e) => {
|
|
16078
16089
|
let t = z.current;
|
|
16079
|
-
t && e.target instanceof Node && !t.contains(e.target) &&
|
|
16090
|
+
t && e.target instanceof Node && !t.contains(e.target) && j(!1);
|
|
16080
16091
|
};
|
|
16081
16092
|
return document.addEventListener("mousedown", e), () => {
|
|
16082
16093
|
document.removeEventListener("mousedown", e);
|
|
16083
16094
|
};
|
|
16084
|
-
}, [
|
|
16095
|
+
}, [A]);
|
|
16085
16096
|
let ae = h(() => {
|
|
16086
16097
|
let r = {};
|
|
16087
16098
|
return e && (r.agentId = e), t && (r.addonId = t), n !== void 0 && (r.deviceId = n), a && (r.category = a), r;
|
|
@@ -16132,7 +16143,7 @@ function Ym({ agentId: e, addonId: t, deviceId: n, defaultCategories: r, categor
|
|
|
16132
16143
|
for (let t of T) e.set(t.id, t);
|
|
16133
16144
|
let t = [...e.values()].filter((e) => b.has(e.category)).filter(qm);
|
|
16134
16145
|
ne > 0 && (t = t.filter((e) => new Date(e.timestamp).getTime() > ne));
|
|
16135
|
-
let n =
|
|
16146
|
+
let n = ee.trim().toLowerCase();
|
|
16136
16147
|
return n && (t = t.filter((e) => {
|
|
16137
16148
|
if (e.category.toLowerCase().includes(n) || Vm(e.category, e.data).label.toLowerCase().includes(n)) return !0;
|
|
16138
16149
|
let t = Km(e.category, e.data);
|
|
@@ -16149,7 +16160,7 @@ function Ym({ agentId: e, addonId: t, deviceId: n, defaultCategories: r, categor
|
|
|
16149
16160
|
se,
|
|
16150
16161
|
T,
|
|
16151
16162
|
b,
|
|
16152
|
-
|
|
16163
|
+
ee,
|
|
16153
16164
|
ne
|
|
16154
16165
|
]), pe = o((e) => {
|
|
16155
16166
|
k((t) => {
|
|
@@ -16162,7 +16173,7 @@ function Ym({ agentId: e, addonId: t, deviceId: n, defaultCategories: r, categor
|
|
|
16162
16173
|
return n.has(e) ? n.delete(e) : n.add(e), n;
|
|
16163
16174
|
});
|
|
16164
16175
|
}, []), W = o(() => {
|
|
16165
|
-
x(new Set(_)),
|
|
16176
|
+
x(new Set(_)), te(""), L(0);
|
|
16166
16177
|
}, [_]), he = o(() => {
|
|
16167
16178
|
L(Date.now()), w.reset();
|
|
16168
16179
|
}, [w]), [ge, _e] = l(!1), [ve, ye] = l(null), G = o((e) => {
|
|
@@ -16229,7 +16240,7 @@ function Ym({ agentId: e, addonId: t, deviceId: n, defaultCategories: r, categor
|
|
|
16229
16240
|
ref: z,
|
|
16230
16241
|
children: [/* @__PURE__ */ H("button", {
|
|
16231
16242
|
type: "button",
|
|
16232
|
-
onClick: () =>
|
|
16243
|
+
onClick: () => j((e) => !e),
|
|
16233
16244
|
className: Z("inline-flex items-center gap-1 text-[9px] px-1.5 py-0.5 rounded border transition-colors", De ? "border-border text-foreground-subtle hover:text-foreground" : "border-violet-500/30 bg-violet-500/10 text-violet-400"),
|
|
16234
16245
|
title: "Pick events to track",
|
|
16235
16246
|
children: [
|
|
@@ -16238,7 +16249,7 @@ function Ym({ agentId: e, addonId: t, deviceId: n, defaultCategories: r, categor
|
|
|
16238
16249
|
Oe,
|
|
16239
16250
|
")"
|
|
16240
16251
|
]
|
|
16241
|
-
}),
|
|
16252
|
+
}), A && /* @__PURE__ */ V(Xm, {
|
|
16242
16253
|
search: P,
|
|
16243
16254
|
onSearchChange: F,
|
|
16244
16255
|
categories: we,
|
|
@@ -16275,13 +16286,13 @@ function Ym({ agentId: e, addonId: t, deviceId: n, defaultCategories: r, categor
|
|
|
16275
16286
|
className: "relative",
|
|
16276
16287
|
children: [/* @__PURE__ */ V("input", {
|
|
16277
16288
|
type: "text",
|
|
16278
|
-
value:
|
|
16279
|
-
onChange: (e) =>
|
|
16289
|
+
value: ee,
|
|
16290
|
+
onChange: (e) => te(e.target.value),
|
|
16280
16291
|
placeholder: "Search…",
|
|
16281
16292
|
className: "w-32 pl-1.5 pr-5 py-0.5 rounded border border-border bg-background text-foreground text-[10px] focus:outline-none focus:border-primary/50"
|
|
16282
|
-
}),
|
|
16293
|
+
}), ee && /* @__PURE__ */ V("button", {
|
|
16283
16294
|
type: "button",
|
|
16284
|
-
onClick: () =>
|
|
16295
|
+
onClick: () => te(""),
|
|
16285
16296
|
className: "absolute right-1 top-1/2 -translate-y-1/2 text-foreground-subtle hover:text-foreground",
|
|
16286
16297
|
title: "Clear search",
|
|
16287
16298
|
children: /* @__PURE__ */ V(Vr, { className: "h-2.5 w-2.5" })
|
|
@@ -16826,7 +16837,7 @@ function bh({ trpc: e, deviceId: t, layout: n, optimistic: r, features: i }) {
|
|
|
16826
16837
|
m(!1);
|
|
16827
16838
|
}
|
|
16828
16839
|
}
|
|
16829
|
-
}, O = _ ? "Unlock" : "Lock", k = d === "open" ? "Open door?" : "Unlock device?",
|
|
16840
|
+
}, O = _ ? "Unlock" : "Lock", k = d === "open" ? "Open door?" : "Unlock device?", ee = d === "open" ? "This will release the latch and open the door." : "This will unlock the device.", te = d === "open" ? "Confirm open" : "Confirm unlock", A = V(d === "open" ? zt : _n, { className: "h-4 w-4 text-amber-400" });
|
|
16830
16841
|
return /* @__PURE__ */ H("div", {
|
|
16831
16842
|
className: Z("inline-flex items-center", n === "full" ? "gap-2" : "gap-1"),
|
|
16832
16843
|
children: [
|
|
@@ -16863,8 +16874,8 @@ function bh({ trpc: e, deviceId: t, layout: n, optimistic: r, features: i }) {
|
|
|
16863
16874
|
children: [
|
|
16864
16875
|
/* @__PURE__ */ H(Md, { children: [/* @__PURE__ */ H(Pd, {
|
|
16865
16876
|
className: "flex items-center gap-2",
|
|
16866
|
-
children: [
|
|
16867
|
-
}), /* @__PURE__ */ V(Fd, { children:
|
|
16877
|
+
children: [A, k]
|
|
16878
|
+
}), /* @__PURE__ */ V(Fd, { children: ee })] }),
|
|
16868
16879
|
h !== null && /* @__PURE__ */ V("div", {
|
|
16869
16880
|
className: "mt-2 px-3 py-2 rounded border border-danger/40 bg-danger/10 text-xs text-danger",
|
|
16870
16881
|
children: h
|
|
@@ -16880,12 +16891,12 @@ function bh({ trpc: e, deviceId: t, layout: n, optimistic: r, features: i }) {
|
|
|
16880
16891
|
type: "button",
|
|
16881
16892
|
variant: "danger",
|
|
16882
16893
|
size: "sm",
|
|
16883
|
-
"aria-label":
|
|
16894
|
+
"aria-label": te,
|
|
16884
16895
|
disabled: p,
|
|
16885
16896
|
onClick: () => {
|
|
16886
16897
|
D();
|
|
16887
16898
|
},
|
|
16888
|
-
children: [p && /* @__PURE__ */ V(gn, { className: "h-3.5 w-3.5 animate-spin" }),
|
|
16899
|
+
children: [p && /* @__PURE__ */ V(gn, { className: "h-3.5 w-3.5 animate-spin" }), te]
|
|
16889
16900
|
})] })
|
|
16890
16901
|
]
|
|
16891
16902
|
})
|
|
@@ -21023,7 +21034,7 @@ function K_({ trpc: e, deviceId: t }) {
|
|
|
21023
21034
|
return a === null ? /* @__PURE__ */ V("span", {
|
|
21024
21035
|
className: "inline-flex h-7 w-7 items-center justify-center rounded bg-surface-hover text-foreground-subtle",
|
|
21025
21036
|
title: "No image",
|
|
21026
|
-
children: /* @__PURE__ */ V(
|
|
21037
|
+
children: /* @__PURE__ */ V(ee, {
|
|
21027
21038
|
className: "h-4 w-4",
|
|
21028
21039
|
"aria-hidden": "true"
|
|
21029
21040
|
})
|
|
@@ -21068,7 +21079,7 @@ function q_({ trpc: e, deviceId: t, deviceName: n }) {
|
|
|
21068
21079
|
}) : /* @__PURE__ */ H("div", {
|
|
21069
21080
|
"data-testid": "image-placeholder",
|
|
21070
21081
|
className: "flex h-48 w-full flex-col items-center justify-center gap-2 text-foreground-subtle",
|
|
21071
|
-
children: [/* @__PURE__ */ V(
|
|
21082
|
+
children: [/* @__PURE__ */ V(ee, {
|
|
21072
21083
|
className: "h-8 w-8",
|
|
21073
21084
|
"aria-hidden": "true"
|
|
21074
21085
|
}), /* @__PURE__ */ V("span", {
|
|
@@ -26488,7 +26499,7 @@ b(), b();
|
|
|
26488
26499
|
//#region ../ui-library/src/composites/device-meta.ts
|
|
26489
26500
|
var TE = {
|
|
26490
26501
|
[q.Camera]: {
|
|
26491
|
-
icon:
|
|
26502
|
+
icon: te,
|
|
26492
26503
|
label: "Camera"
|
|
26493
26504
|
},
|
|
26494
26505
|
[q.Hub]: {
|
|
@@ -27096,19 +27107,19 @@ function VE({ schema: e, steps: t, onChange: n, templates: r, selectedTemplateId
|
|
|
27096
27107
|
function k() {
|
|
27097
27108
|
i && s(i, t);
|
|
27098
27109
|
}
|
|
27099
|
-
function
|
|
27110
|
+
function ee() {
|
|
27100
27111
|
let e = window.prompt("Template name:");
|
|
27101
27112
|
e?.trim() && o(e.trim(), t);
|
|
27102
27113
|
}
|
|
27103
|
-
function
|
|
27114
|
+
function te() {
|
|
27104
27115
|
if (!i) return;
|
|
27105
27116
|
let e = r.find((e) => e.id === i);
|
|
27106
27117
|
e && window.confirm(`Delete template "${e.name}"?`) && c(i);
|
|
27107
27118
|
}
|
|
27108
|
-
function
|
|
27109
|
-
n(t.map((t) => t.addonId === e.addonId ?
|
|
27119
|
+
function A(e) {
|
|
27120
|
+
n(t.map((t) => t.addonId === e.addonId ? j(e) : t));
|
|
27110
27121
|
}
|
|
27111
|
-
function
|
|
27122
|
+
function j(e) {
|
|
27112
27123
|
let t = e.children.some((e) => e.enabled || e.children.some((e) => e.enabled));
|
|
27113
27124
|
return {
|
|
27114
27125
|
...e,
|
|
@@ -27165,7 +27176,7 @@ function VE({ schema: e, steps: t, onChange: n, templates: r, selectedTemplateId
|
|
|
27165
27176
|
step: r,
|
|
27166
27177
|
schema: w.get(r.addonId) ?? null,
|
|
27167
27178
|
allSchemas: w,
|
|
27168
|
-
onChange:
|
|
27179
|
+
onChange: A,
|
|
27169
27180
|
onDelete: u ? void 0 : (e) => n(t.filter((t) => t.addonId !== e)),
|
|
27170
27181
|
readOnly: u,
|
|
27171
27182
|
...S(r.addonId)
|
|
@@ -27186,13 +27197,13 @@ function VE({ schema: e, steps: t, onChange: n, templates: r, selectedTemplateId
|
|
|
27186
27197
|
allSchemas: w,
|
|
27187
27198
|
depth: 1,
|
|
27188
27199
|
onChange: (e) => {
|
|
27189
|
-
|
|
27200
|
+
A({
|
|
27190
27201
|
...r,
|
|
27191
27202
|
children: r.children.map((t) => t.addonId === e.addonId ? e : t)
|
|
27192
27203
|
});
|
|
27193
27204
|
},
|
|
27194
27205
|
onDelete: u ? void 0 : (e) => {
|
|
27195
|
-
|
|
27206
|
+
A({
|
|
27196
27207
|
...r,
|
|
27197
27208
|
children: r.children.filter((t) => t.addonId !== e)
|
|
27198
27209
|
});
|
|
@@ -27212,7 +27223,7 @@ function VE({ schema: e, steps: t, onChange: n, templates: r, selectedTemplateId
|
|
|
27212
27223
|
allSchemas: w,
|
|
27213
27224
|
depth: 2,
|
|
27214
27225
|
onChange: (t) => {
|
|
27215
|
-
|
|
27226
|
+
A({
|
|
27216
27227
|
...r,
|
|
27217
27228
|
children: r.children.map((n) => n.addonId === e.addonId ? {
|
|
27218
27229
|
...n,
|
|
@@ -27221,7 +27232,7 @@ function VE({ schema: e, steps: t, onChange: n, templates: r, selectedTemplateId
|
|
|
27221
27232
|
});
|
|
27222
27233
|
},
|
|
27223
27234
|
onDelete: u ? void 0 : (t) => {
|
|
27224
|
-
|
|
27235
|
+
A({
|
|
27225
27236
|
...r,
|
|
27226
27237
|
children: r.children.map((n) => n.addonId === e.addonId ? {
|
|
27227
27238
|
...n,
|
|
@@ -27236,7 +27247,7 @@ function VE({ schema: e, steps: t, onChange: n, templates: r, selectedTemplateId
|
|
|
27236
27247
|
addon: t,
|
|
27237
27248
|
onClick: () => {
|
|
27238
27249
|
let n = zE(t);
|
|
27239
|
-
|
|
27250
|
+
A({
|
|
27240
27251
|
...r,
|
|
27241
27252
|
children: r.children.map((t) => t.addonId === e.addonId ? {
|
|
27242
27253
|
...t,
|
|
@@ -27290,14 +27301,14 @@ function VE({ schema: e, steps: t, onChange: n, templates: r, selectedTemplateId
|
|
|
27290
27301
|
children: /* @__PURE__ */ V(Yn, { className: "h-4 w-4" })
|
|
27291
27302
|
}),
|
|
27292
27303
|
/* @__PURE__ */ V("button", {
|
|
27293
|
-
onClick:
|
|
27304
|
+
onClick: ee,
|
|
27294
27305
|
disabled: u,
|
|
27295
27306
|
title: "Save As",
|
|
27296
27307
|
className: Z("p-2 rounded-lg border border-border transition-colors", u ? "text-foreground-subtle/30 cursor-not-allowed" : "text-foreground-subtle hover:bg-surface-hover"),
|
|
27297
27308
|
children: /* @__PURE__ */ V(Nt, { className: "h-4 w-4" })
|
|
27298
27309
|
}),
|
|
27299
27310
|
/* @__PURE__ */ V("button", {
|
|
27300
|
-
onClick:
|
|
27311
|
+
onClick: te,
|
|
27301
27312
|
disabled: !i || u,
|
|
27302
27313
|
title: "Delete",
|
|
27303
27314
|
className: Z("p-2 rounded-lg border border-border transition-colors", i && !u ? "text-foreground-subtle hover:text-danger" : "text-foreground-subtle/30 cursor-not-allowed"),
|
|
@@ -27581,55 +27592,55 @@ function $E({ className: e }) {
|
|
|
27581
27592
|
]
|
|
27582
27593
|
});
|
|
27583
27594
|
}
|
|
27584
|
-
function eD({ serverUrl: e, createSession: t, sendAnswer: n, handleOffer: r, getIceServers: i, addIceCandidate: a, getIceCandidates: s, closeSession: c, getSessionState: d,
|
|
27585
|
-
let
|
|
27595
|
+
function eD({ serverUrl: e, createSession: t, sendAnswer: n, handleOffer: r, getIceServers: i, addIceCandidate: a, getIceCandidates: s, closeSession: c, getSessionState: d, getSessionDebug: f, playbackUrl: p, playbackAuthToken: m, onExitPlayback: g, posterUrl: _, streams: y, activeStreamId: b, onStreamChange: x, deviceName: S, phase: C, pipelineMetrics: w, detections: T, stationaryObjects: E, defaultShowDetections: D = !0, defaultShowMotion: O = !1, streamStats: k, autoPlay: ee = !1, showPlayStop: te = !1, snapshotSrc: A, snapshotLoading: j = !1, onRefreshSnapshot: M, showStreamStats: N = !1, children: P, extraOverlay: I, ptzAvailable: ne = !1, ptzShown: L = !1, ptzOverlay: R, onPtzToggle: z, intercomAvailable: re = !1, intercomShown: ie = !1, onIntercomToggle: B, chromeless: ae = !1, className: oe }) {
|
|
27596
|
+
let se = F(), ce = gc(), [le, ue] = l(ee), [de, fe] = l(D), [pe, me] = l(!0), [W, he] = l(!0), [ge, _e] = l(O), [ve, ye] = l(null), [G, be] = l([]), [xe, Se] = l(-1), [Ce, we] = l(!1), Te = u(null);
|
|
27586
27597
|
v(() => {
|
|
27587
|
-
if (!
|
|
27598
|
+
if (!Ce) return;
|
|
27588
27599
|
function e(e) {
|
|
27589
|
-
|
|
27600
|
+
Te.current && !Te.current.contains(e.target) && we(!1);
|
|
27590
27601
|
}
|
|
27591
27602
|
return document.addEventListener("mousedown", e), () => document.removeEventListener("mousedown", e);
|
|
27592
|
-
}, [
|
|
27593
|
-
|
|
27594
|
-
}, [
|
|
27595
|
-
let
|
|
27596
|
-
|
|
27597
|
-
}, []),
|
|
27598
|
-
status:
|
|
27599
|
-
inputFps:
|
|
27600
|
-
bitrateKbps:
|
|
27601
|
-
},
|
|
27602
|
-
|
|
27603
|
-
},
|
|
27604
|
-
let e =
|
|
27603
|
+
}, [Ce]), v(() => {
|
|
27604
|
+
Se(-1);
|
|
27605
|
+
}, [p]);
|
|
27606
|
+
let Ee = o((e) => {
|
|
27607
|
+
be(e);
|
|
27608
|
+
}, []), De = b ?? ve ?? y?.[0]?.id ?? "", Oe = y?.find((e) => e.id === De) ?? y?.[0], ke = Oe?.inputFps == null ? null : {
|
|
27609
|
+
status: Oe.status ?? "unknown",
|
|
27610
|
+
inputFps: Oe.inputFps,
|
|
27611
|
+
bitrateKbps: Oe.bitrateKbps ?? 0
|
|
27612
|
+
}, Ae = (e) => {
|
|
27613
|
+
ye(e), x?.(e), le && te && (ue(!1), setTimeout(() => ue(!0), 50));
|
|
27614
|
+
}, je = h(() => {
|
|
27615
|
+
let e = Oe?.target;
|
|
27605
27616
|
if (!(!e || !t)) return (n) => t(e, n);
|
|
27606
|
-
}, [t,
|
|
27607
|
-
let e =
|
|
27617
|
+
}, [t, Oe]), Me = h(() => {
|
|
27618
|
+
let e = Oe?.target;
|
|
27608
27619
|
if (!(!e || !r)) return (t, n) => r(e, t, n);
|
|
27609
|
-
}, [r,
|
|
27620
|
+
}, [r, Oe]), Ne = h(() => {
|
|
27610
27621
|
if (r) return (e, t, n) => r(n, t, e);
|
|
27611
|
-
}, [r]),
|
|
27622
|
+
}, [r]), Pe = y, Fe = () => ue(!0), Ie = () => ue(!1), Le = w?.phase ?? C, Re = Le === "active", ze = !!T, K = ze && (de || ge), Be = ne && L && !!R, Ve = !!p, q = Ve || (te ? le : !0);
|
|
27612
27623
|
return /* @__PURE__ */ H("div", {
|
|
27613
|
-
className: `overflow-hidden ${
|
|
27624
|
+
className: `overflow-hidden ${ae ? "" : "rounded-xl border border-border bg-surface"} ${oe ?? ""}`,
|
|
27614
27625
|
children: [
|
|
27615
27626
|
/* @__PURE__ */ H("div", {
|
|
27616
27627
|
className: "flex flex-wrap items-center justify-between gap-2 px-3 py-2 border-b border-border",
|
|
27617
27628
|
children: [/* @__PURE__ */ H("div", {
|
|
27618
27629
|
className: "flex items-center gap-2 min-w-0",
|
|
27619
27630
|
children: [
|
|
27620
|
-
(
|
|
27621
|
-
|
|
27631
|
+
(k ?? ke) && /* @__PURE__ */ V("span", { className: `shrink-0 w-2 h-2 rounded-full ${WE((k ?? ke).status)}` }),
|
|
27632
|
+
S && /* @__PURE__ */ V("span", {
|
|
27622
27633
|
className: "text-xs font-medium text-foreground truncate",
|
|
27623
|
-
children:
|
|
27634
|
+
children: S
|
|
27624
27635
|
}),
|
|
27625
|
-
!
|
|
27636
|
+
!Ve && Pe && Pe.length > 1 && /* @__PURE__ */ H("div", {
|
|
27626
27637
|
className: "relative",
|
|
27627
27638
|
children: [/* @__PURE__ */ V("select", {
|
|
27628
27639
|
"data-testid": "stream-profile-select",
|
|
27629
|
-
value:
|
|
27630
|
-
onChange: (e) =>
|
|
27640
|
+
value: De,
|
|
27641
|
+
onChange: (e) => Ae(e.target.value),
|
|
27631
27642
|
className: "appearance-none cursor-pointer rounded-md border border-border bg-surface-hover hover:bg-surface text-foreground text-[11px] font-medium pl-2 pr-6 py-1 focus:outline-none focus:ring-1 focus:ring-primary transition-colors",
|
|
27632
|
-
children:
|
|
27643
|
+
children: Pe.map((e) => /* @__PURE__ */ V("option", {
|
|
27633
27644
|
value: e.id,
|
|
27634
27645
|
children: e.label
|
|
27635
27646
|
}, e.id))
|
|
@@ -27647,14 +27658,14 @@ function eD({ serverUrl: e, createSession: t, sendAnswer: n, handleOffer: r, get
|
|
|
27647
27658
|
})
|
|
27648
27659
|
})]
|
|
27649
27660
|
}),
|
|
27650
|
-
|
|
27661
|
+
Ve && G.length > 1 && /* @__PURE__ */ H("div", {
|
|
27651
27662
|
className: "relative",
|
|
27652
27663
|
children: [/* @__PURE__ */ V("select", {
|
|
27653
27664
|
"data-testid": "vod-quality-select",
|
|
27654
|
-
value:
|
|
27655
|
-
onChange: (e) =>
|
|
27665
|
+
value: xe,
|
|
27666
|
+
onChange: (e) => Se(Number(e.target.value)),
|
|
27656
27667
|
className: "appearance-none cursor-pointer rounded-md border border-border bg-surface-hover hover:bg-surface text-foreground text-[11px] font-medium pl-2 pr-6 py-1 focus:outline-none focus:ring-1 focus:ring-primary transition-colors",
|
|
27657
|
-
children:
|
|
27668
|
+
children: G.map((e) => /* @__PURE__ */ V("option", {
|
|
27658
27669
|
value: e.value,
|
|
27659
27670
|
children: e.label
|
|
27660
27671
|
}, e.value))
|
|
@@ -27676,18 +27687,18 @@ function eD({ serverUrl: e, createSession: t, sendAnswer: n, handleOffer: r, get
|
|
|
27676
27687
|
}), /* @__PURE__ */ H("div", {
|
|
27677
27688
|
className: "flex items-center gap-1.5 shrink-0 ml-auto",
|
|
27678
27689
|
children: [
|
|
27679
|
-
|
|
27690
|
+
re && !Ve && /* @__PURE__ */ H("button", {
|
|
27680
27691
|
"data-testid": "stream-intercom-toggle",
|
|
27681
|
-
"data-intercom-shown":
|
|
27682
|
-
onClick:
|
|
27683
|
-
className: `inline-flex items-center gap-1 rounded-md px-2 py-1 text-xs font-medium transition-colors ${
|
|
27684
|
-
title:
|
|
27692
|
+
"data-intercom-shown": ie ? "true" : "false",
|
|
27693
|
+
onClick: B,
|
|
27694
|
+
className: `inline-flex items-center gap-1 rounded-md px-2 py-1 text-xs font-medium transition-colors ${ie ? "bg-primary/15 text-primary" : "text-foreground-subtle hover:text-foreground hover:bg-surface-hover"}`,
|
|
27695
|
+
title: ie ? "Close intercom" : "Open intercom",
|
|
27685
27696
|
children: [/* @__PURE__ */ V(JE, { className: "h-3 w-3" }), /* @__PURE__ */ V("span", {
|
|
27686
27697
|
className: "hidden xl:inline",
|
|
27687
27698
|
children: "Intercom"
|
|
27688
27699
|
})]
|
|
27689
27700
|
}),
|
|
27690
|
-
|
|
27701
|
+
se.map((e) => {
|
|
27691
27702
|
let t = e.tone === "primary" ? "bg-primary text-primary-foreground" : "bg-primary/15 text-primary";
|
|
27692
27703
|
return /* @__PURE__ */ H("button", {
|
|
27693
27704
|
type: "button",
|
|
@@ -27703,21 +27714,21 @@ function eD({ serverUrl: e, createSession: t, sendAnswer: n, handleOffer: r, get
|
|
|
27703
27714
|
})]
|
|
27704
27715
|
}, e.id);
|
|
27705
27716
|
}),
|
|
27706
|
-
|
|
27717
|
+
te && /* @__PURE__ */ H("button", {
|
|
27707
27718
|
"data-testid": "stream-play-toggle",
|
|
27708
|
-
"data-stream-playing":
|
|
27709
|
-
"data-vod":
|
|
27710
|
-
onClick:
|
|
27711
|
-
className: `inline-flex items-center gap-1 rounded-md px-2 py-1 text-xs font-medium transition-colors ${
|
|
27712
|
-
title:
|
|
27713
|
-
children: [V(
|
|
27719
|
+
"data-stream-playing": q ? "true" : "false",
|
|
27720
|
+
"data-vod": Ve ? "true" : "false",
|
|
27721
|
+
onClick: Ve ? g : q ? Ie : Fe,
|
|
27722
|
+
className: `inline-flex items-center gap-1 rounded-md px-2 py-1 text-xs font-medium transition-colors ${Ve ? "bg-primary/10 text-primary hover:bg-primary/20" : q ? "bg-danger/10 text-danger hover:bg-danger/20" : "bg-primary/10 text-primary hover:bg-primary/20"}`,
|
|
27723
|
+
title: Ve ? "Return to live" : q ? "Stop stream" : "Start stream",
|
|
27724
|
+
children: [V(Ve ? ZE : q ? qE : KE, { className: "h-3 w-3" }), /* @__PURE__ */ V("span", {
|
|
27714
27725
|
className: "hidden xl:inline",
|
|
27715
|
-
children:
|
|
27726
|
+
children: Ve ? "Live" : q ? "Stop" : "Play"
|
|
27716
27727
|
})]
|
|
27717
27728
|
}),
|
|
27718
|
-
|
|
27729
|
+
M && !Ve && /* @__PURE__ */ H("button", {
|
|
27719
27730
|
"data-testid": "stream-snapshot-refresh",
|
|
27720
|
-
onClick:
|
|
27731
|
+
onClick: M,
|
|
27721
27732
|
disabled: j,
|
|
27722
27733
|
className: "inline-flex items-center gap-1 rounded-md px-2 py-1 text-xs font-medium text-foreground-subtle hover:text-foreground hover:bg-surface-hover transition-colors disabled:opacity-50",
|
|
27723
27734
|
title: "Force snapshot refresh",
|
|
@@ -27726,111 +27737,111 @@ function eD({ serverUrl: e, createSession: t, sendAnswer: n, handleOffer: r, get
|
|
|
27726
27737
|
children: "Snapshot"
|
|
27727
27738
|
})]
|
|
27728
27739
|
}),
|
|
27729
|
-
(
|
|
27730
|
-
ref:
|
|
27740
|
+
(ze || ne || w || Le || k || ke && ke.inputFps > 0) && /* @__PURE__ */ H("div", {
|
|
27741
|
+
ref: Te,
|
|
27731
27742
|
className: "relative",
|
|
27732
27743
|
children: [/* @__PURE__ */ V("button", {
|
|
27733
|
-
onClick: () =>
|
|
27744
|
+
onClick: () => we((e) => !e),
|
|
27734
27745
|
title: "More controls",
|
|
27735
27746
|
className: "inline-flex items-center justify-center rounded-md p-1 text-foreground-subtle hover:text-foreground hover:bg-surface-hover transition-colors",
|
|
27736
27747
|
children: /* @__PURE__ */ V(YE, { className: "h-3.5 w-3.5" })
|
|
27737
|
-
}),
|
|
27748
|
+
}), Ce && /* @__PURE__ */ H("div", {
|
|
27738
27749
|
className: "absolute right-0 top-full mt-1 z-30 min-w-[200px] rounded-lg border border-border bg-surface shadow-xl py-1.5",
|
|
27739
27750
|
children: [
|
|
27740
|
-
|
|
27751
|
+
N && k && /* @__PURE__ */ H("div", {
|
|
27741
27752
|
className: "px-3 py-1.5 text-[10px] text-foreground-subtle border-b border-border-subtle",
|
|
27742
27753
|
children: [
|
|
27743
27754
|
/* @__PURE__ */ H("div", {
|
|
27744
27755
|
className: "flex justify-between gap-3",
|
|
27745
27756
|
children: [/* @__PURE__ */ V("span", { children: "Input" }), /* @__PURE__ */ H("span", {
|
|
27746
27757
|
className: "tabular-nums text-foreground",
|
|
27747
|
-
children: [
|
|
27758
|
+
children: [k.inputFps.toFixed(1), " fps"]
|
|
27748
27759
|
})]
|
|
27749
27760
|
}),
|
|
27750
27761
|
/* @__PURE__ */ H("div", {
|
|
27751
27762
|
className: "flex justify-between gap-3",
|
|
27752
27763
|
children: [/* @__PURE__ */ V("span", { children: "Decode" }), /* @__PURE__ */ H("span", {
|
|
27753
27764
|
className: "tabular-nums text-foreground",
|
|
27754
|
-
children: [
|
|
27765
|
+
children: [k.decodeFps.toFixed(1), " fps"]
|
|
27755
27766
|
})]
|
|
27756
27767
|
}),
|
|
27757
27768
|
/* @__PURE__ */ H("div", {
|
|
27758
27769
|
className: "flex justify-between gap-3",
|
|
27759
27770
|
children: [/* @__PURE__ */ V("span", { children: "Uptime" }), /* @__PURE__ */ V("span", {
|
|
27760
27771
|
className: "tabular-nums text-foreground",
|
|
27761
|
-
children: GE(
|
|
27772
|
+
children: GE(k.uptimeMs)
|
|
27762
27773
|
})]
|
|
27763
27774
|
})
|
|
27764
27775
|
]
|
|
27765
27776
|
}),
|
|
27766
|
-
!
|
|
27777
|
+
!N && ke && ke.inputFps > 0 && /* @__PURE__ */ H("div", {
|
|
27767
27778
|
className: "px-3 py-1.5 text-[10px] text-foreground-subtle border-b border-border-subtle",
|
|
27768
27779
|
children: [/* @__PURE__ */ H("div", {
|
|
27769
27780
|
className: "flex justify-between gap-3",
|
|
27770
27781
|
children: [/* @__PURE__ */ V("span", { children: "Input" }), /* @__PURE__ */ H("span", {
|
|
27771
27782
|
className: "tabular-nums text-foreground",
|
|
27772
|
-
children: [
|
|
27783
|
+
children: [ke.inputFps.toFixed(1), " fps"]
|
|
27773
27784
|
})]
|
|
27774
|
-
}),
|
|
27785
|
+
}), ke.bitrateKbps > 0 && /* @__PURE__ */ H("div", {
|
|
27775
27786
|
className: "flex justify-between gap-3",
|
|
27776
27787
|
children: [/* @__PURE__ */ V("span", { children: "Bitrate" }), /* @__PURE__ */ H("span", {
|
|
27777
27788
|
className: "tabular-nums text-foreground",
|
|
27778
|
-
children: [
|
|
27789
|
+
children: [ke.bitrateKbps, " kbps"]
|
|
27779
27790
|
})]
|
|
27780
27791
|
})]
|
|
27781
27792
|
}),
|
|
27782
|
-
(
|
|
27793
|
+
(w || ze && Le) && /* @__PURE__ */ H("div", {
|
|
27783
27794
|
className: "px-3 py-1.5 text-[10px] text-foreground-subtle border-b border-border-subtle",
|
|
27784
27795
|
children: [
|
|
27785
27796
|
/* @__PURE__ */ H("div", {
|
|
27786
27797
|
className: "flex justify-between gap-3 items-center",
|
|
27787
27798
|
children: [/* @__PURE__ */ V("span", { children: "Phase" }), /* @__PURE__ */ H("span", {
|
|
27788
|
-
className: `flex items-center gap-1 font-semibold uppercase tracking-wider ${
|
|
27789
|
-
children: [/* @__PURE__ */ V("span", { className: `w-1.5 h-1.5 rounded-full ${
|
|
27799
|
+
className: `flex items-center gap-1 font-semibold uppercase tracking-wider ${Re ? "text-red-400" : "text-emerald-400"}`,
|
|
27800
|
+
children: [/* @__PURE__ */ V("span", { className: `w-1.5 h-1.5 rounded-full ${Re ? "bg-red-500 animate-pulse" : "bg-emerald-500"}` }), Re ? "Active" : "Watching"]
|
|
27790
27801
|
})]
|
|
27791
27802
|
}),
|
|
27792
|
-
|
|
27803
|
+
w && w.detectionFps > 0 && /* @__PURE__ */ H("div", {
|
|
27793
27804
|
className: "flex justify-between gap-3",
|
|
27794
27805
|
children: [/* @__PURE__ */ V("span", { children: "Detection" }), /* @__PURE__ */ H("span", {
|
|
27795
27806
|
className: "tabular-nums text-foreground",
|
|
27796
|
-
children: [
|
|
27807
|
+
children: [w.detectionFps.toFixed(1), " det/s"]
|
|
27797
27808
|
})]
|
|
27798
27809
|
}),
|
|
27799
|
-
|
|
27810
|
+
w && w.avgInferenceMs > 0 && /* @__PURE__ */ H("div", {
|
|
27800
27811
|
className: "flex justify-between gap-3",
|
|
27801
27812
|
children: [/* @__PURE__ */ V("span", { children: "Inference" }), /* @__PURE__ */ H("span", {
|
|
27802
27813
|
className: "tabular-nums text-foreground",
|
|
27803
|
-
children: [
|
|
27814
|
+
children: [w.avgInferenceMs.toFixed(0), " ms"]
|
|
27804
27815
|
})]
|
|
27805
27816
|
})
|
|
27806
27817
|
]
|
|
27807
27818
|
}),
|
|
27808
|
-
|
|
27819
|
+
ze && /* @__PURE__ */ H(U, { children: [
|
|
27809
27820
|
/* @__PURE__ */ V(XE, {
|
|
27810
27821
|
label: "Show detections",
|
|
27811
|
-
active:
|
|
27812
|
-
onClick: () =>
|
|
27822
|
+
active: de,
|
|
27823
|
+
onClick: () => fe((e) => !e)
|
|
27813
27824
|
}),
|
|
27814
|
-
|
|
27825
|
+
de && /* @__PURE__ */ H(U, { children: [/* @__PURE__ */ V(XE, {
|
|
27815
27826
|
label: "…moving",
|
|
27816
|
-
active:
|
|
27817
|
-
onClick: () =>
|
|
27827
|
+
active: pe,
|
|
27828
|
+
onClick: () => me((e) => !e)
|
|
27818
27829
|
}), /* @__PURE__ */ V(XE, {
|
|
27819
27830
|
label: "…stationary",
|
|
27820
|
-
active:
|
|
27821
|
-
onClick: () =>
|
|
27831
|
+
active: W,
|
|
27832
|
+
onClick: () => he((e) => !e)
|
|
27822
27833
|
})] }),
|
|
27823
27834
|
/* @__PURE__ */ V(XE, {
|
|
27824
27835
|
label: "Show motion",
|
|
27825
|
-
active:
|
|
27826
|
-
onClick: () =>
|
|
27836
|
+
active: ge,
|
|
27837
|
+
onClick: () => _e((e) => !e)
|
|
27827
27838
|
})
|
|
27828
27839
|
] }),
|
|
27829
|
-
|
|
27840
|
+
ne && /* @__PURE__ */ V(XE, {
|
|
27830
27841
|
label: "PTZ controls",
|
|
27831
|
-
active:
|
|
27842
|
+
active: L,
|
|
27832
27843
|
onClick: () => {
|
|
27833
|
-
|
|
27844
|
+
z?.(), we(!1);
|
|
27834
27845
|
}
|
|
27835
27846
|
})
|
|
27836
27847
|
]
|
|
@@ -27839,57 +27850,58 @@ function eD({ serverUrl: e, createSession: t, sendAnswer: n, handleOffer: r, get
|
|
|
27839
27850
|
]
|
|
27840
27851
|
})]
|
|
27841
27852
|
}),
|
|
27842
|
-
|
|
27853
|
+
p ? /* @__PURE__ */ H("div", {
|
|
27843
27854
|
className: "aspect-video relative",
|
|
27844
27855
|
children: [/* @__PURE__ */ V(PE, {
|
|
27845
|
-
url:
|
|
27846
|
-
authToken:
|
|
27847
|
-
onQualityOptions:
|
|
27848
|
-
selectedLevel:
|
|
27849
|
-
...
|
|
27850
|
-
}),
|
|
27851
|
-
}) :
|
|
27856
|
+
url: p,
|
|
27857
|
+
authToken: m ?? null,
|
|
27858
|
+
onQualityOptions: Ee,
|
|
27859
|
+
selectedLevel: xe,
|
|
27860
|
+
..._ ? { posterUrl: _ } : {}
|
|
27861
|
+
}), I || Be ? /* @__PURE__ */ H(U, { children: [I, Be && R] }) : null]
|
|
27862
|
+
}) : q && e ? /* @__PURE__ */ V("div", {
|
|
27852
27863
|
className: "aspect-video relative",
|
|
27853
27864
|
children: /* @__PURE__ */ V(Uf, {
|
|
27854
27865
|
serverUrl: e,
|
|
27855
|
-
streamKey:
|
|
27866
|
+
streamKey: De,
|
|
27856
27867
|
autoPlay: !0,
|
|
27857
27868
|
className: "w-full h-full",
|
|
27858
|
-
createSession:
|
|
27869
|
+
createSession: je,
|
|
27859
27870
|
sendAnswer: n,
|
|
27860
|
-
handleOffer:
|
|
27861
|
-
reoffer:
|
|
27871
|
+
handleOffer: Me,
|
|
27872
|
+
reoffer: Ne,
|
|
27862
27873
|
getSessionState: d,
|
|
27874
|
+
...f ? { getSessionDebug: f } : {},
|
|
27863
27875
|
getIceServers: i,
|
|
27864
27876
|
addIceCandidate: a,
|
|
27865
27877
|
getIceCandidates: s,
|
|
27866
27878
|
closeSession: c,
|
|
27867
|
-
...
|
|
27868
|
-
...
|
|
27869
|
-
overlay:
|
|
27870
|
-
|
|
27871
|
-
detections:
|
|
27879
|
+
...ce.bindControlChannel ? { onControlChannel: ce.bindControlChannel } : {},
|
|
27880
|
+
..._ ? { posterUrl: _ } : {},
|
|
27881
|
+
overlay: K || I || Be ? /* @__PURE__ */ H(U, { children: [
|
|
27882
|
+
K && /* @__PURE__ */ V(ap, {
|
|
27883
|
+
detections: T,
|
|
27872
27884
|
showPhaseIndicator: !1,
|
|
27873
|
-
showMotionZones:
|
|
27874
|
-
showMotionRaw:
|
|
27875
|
-
showDetections:
|
|
27876
|
-
showMoving:
|
|
27877
|
-
showStationary:
|
|
27878
|
-
...
|
|
27885
|
+
showMotionZones: ge,
|
|
27886
|
+
showMotionRaw: ge,
|
|
27887
|
+
showDetections: de,
|
|
27888
|
+
showMoving: pe,
|
|
27889
|
+
showStationary: W,
|
|
27890
|
+
...E === void 0 ? {} : { stationaryObjects: E }
|
|
27879
27891
|
}),
|
|
27880
|
-
|
|
27881
|
-
|
|
27892
|
+
I,
|
|
27893
|
+
Be && R
|
|
27882
27894
|
] }) : void 0
|
|
27883
27895
|
})
|
|
27884
27896
|
}) : /* @__PURE__ */ V(tD, {
|
|
27885
|
-
src:
|
|
27897
|
+
src: A ?? null,
|
|
27886
27898
|
isLoading: j,
|
|
27887
|
-
onPlay:
|
|
27888
|
-
onRetry:
|
|
27889
|
-
extraOverlay:
|
|
27890
|
-
suppressPlayHover: !!
|
|
27899
|
+
onPlay: Fe,
|
|
27900
|
+
onRetry: M,
|
|
27901
|
+
extraOverlay: I || Be ? /* @__PURE__ */ H(U, { children: [I, Be && R] }) : null,
|
|
27902
|
+
suppressPlayHover: !!I || Be
|
|
27891
27903
|
}),
|
|
27892
|
-
|
|
27904
|
+
P
|
|
27893
27905
|
]
|
|
27894
27906
|
});
|
|
27895
27907
|
}
|
|
@@ -28358,7 +28370,7 @@ function bD({ trpc: e, nodeId: t }) {
|
|
|
28358
28370
|
e.pipelineExecutor.getReferenceAudioFiles.query().then(async (e) => {
|
|
28359
28371
|
if (r(e), e.length > 0) {
|
|
28360
28372
|
let t = e[0].filename;
|
|
28361
|
-
a(t), await
|
|
28373
|
+
a(t), await ee(t);
|
|
28362
28374
|
}
|
|
28363
28375
|
}).catch((e) => {
|
|
28364
28376
|
console.warn("[benchmark:audio] Failed to load audio files:", e);
|
|
@@ -28387,18 +28399,18 @@ function bD({ trpc: e, nodeId: t }) {
|
|
|
28387
28399
|
for (let t of k) "key" in t && "default" in t && t.default !== void 0 && (e[t.key] = t.default);
|
|
28388
28400
|
T((t) => Object.keys(t).length === 0 ? e : t);
|
|
28389
28401
|
}, [k]);
|
|
28390
|
-
let
|
|
28402
|
+
let ee = o(async (t) => {
|
|
28391
28403
|
try {
|
|
28392
28404
|
let n = await e.pipelineExecutor.getReferenceAudio.query({ filename: t });
|
|
28393
28405
|
n?.base64 && c(yD(n.base64));
|
|
28394
28406
|
} catch (e) {
|
|
28395
28407
|
console.warn("[benchmark:audio] Failed to load audio:", e), c(null);
|
|
28396
28408
|
}
|
|
28397
|
-
}, [e, t]),
|
|
28398
|
-
a(e), g(null), p(""), await
|
|
28399
|
-
},
|
|
28409
|
+
}, [e, t]), te = async (e) => {
|
|
28410
|
+
a(e), g(null), p(""), await ee(e);
|
|
28411
|
+
}, A = (e, t) => {
|
|
28400
28412
|
p(`Upload is not supported for audio: runAudioTest has no payload field for an uploaded file, so "${t}" cannot be classified. Pick a reference WAV above.`), c(yD(e));
|
|
28401
|
-
},
|
|
28413
|
+
}, j = async () => {
|
|
28402
28414
|
d(!0), p(""), g(null);
|
|
28403
28415
|
try {
|
|
28404
28416
|
let n = await e.pipelineExecutor.runAudioTest.mutate({ ..._D({
|
|
@@ -28528,9 +28540,9 @@ function bD({ trpc: e, nodeId: t }) {
|
|
|
28528
28540
|
})),
|
|
28529
28541
|
selectedFilename: i,
|
|
28530
28542
|
onSelect: (e) => {
|
|
28531
|
-
|
|
28543
|
+
te(e);
|
|
28532
28544
|
},
|
|
28533
|
-
onUpload: (e, t) =>
|
|
28545
|
+
onUpload: (e, t) => A(e, t),
|
|
28534
28546
|
accept: ".wav,audio/wav",
|
|
28535
28547
|
uploadLabel: "Upload WAV (preview only)"
|
|
28536
28548
|
}),
|
|
@@ -28801,7 +28813,7 @@ function bD({ trpc: e, nodeId: t }) {
|
|
|
28801
28813
|
})]
|
|
28802
28814
|
}),
|
|
28803
28815
|
/* @__PURE__ */ V("button", {
|
|
28804
|
-
onClick:
|
|
28816
|
+
onClick: j,
|
|
28805
28817
|
disabled: u || !i,
|
|
28806
28818
|
className: `w-full px-4 py-2.5 text-sm font-medium rounded-lg transition-colors sticky bottom-4 ${u ? "bg-primary text-primary-foreground animate-pulse" : "bg-primary text-primary-foreground hover:bg-primary/90 disabled:opacity-50"}`,
|
|
28807
28819
|
children: u ? "Classifying..." : "Classify Audio"
|
|
@@ -29642,7 +29654,7 @@ function lO({ label: e, hint: t, value: n, min: r, max: i, step: a, disabled: o,
|
|
|
29642
29654
|
});
|
|
29643
29655
|
}
|
|
29644
29656
|
function uO({ trpc: e, nodeId: t, onNodeChange: n }) {
|
|
29645
|
-
let [r, i] = l([]), [a, s] = l(""), [c, d] = l(null), [f, p] = l(null), [m, g] = l(null), [_, y] = l(null), [b, x] = l(wD), [S, C] = l(null), [w, T] = l(null), [E, D] = l(null), [O, k] = l(!1), [
|
|
29657
|
+
let [r, i] = l([]), [a, s] = l(""), [c, d] = l(null), [f, p] = l(null), [m, g] = l(null), [_, y] = l(null), [b, x] = l(wD), [S, C] = l(null), [w, T] = l(null), [E, D] = l(null), [O, k] = l(!1), [ee, te] = l(!1), [A, j] = l(""), [M, N] = l([]), [P, F] = l([]), I = u(null), ne = u(null), L = o((e) => {
|
|
29646
29658
|
x((t) => ({
|
|
29647
29659
|
...t,
|
|
29648
29660
|
...e
|
|
@@ -29652,13 +29664,13 @@ function uO({ trpc: e, nodeId: t, onNodeChange: n }) {
|
|
|
29652
29664
|
e.pipelineExecutor.listReferenceImages.query().then((e) => {
|
|
29653
29665
|
i(e), e.length > 0 && e[0] && s(e[0].filename);
|
|
29654
29666
|
}).catch((e) => {
|
|
29655
|
-
|
|
29667
|
+
j(e instanceof Error ? e.message : String(e));
|
|
29656
29668
|
});
|
|
29657
29669
|
}, [e]), v(() => {
|
|
29658
29670
|
a && e.pipelineExecutor.getReferenceImage.query({ filename: a }).then((e) => {
|
|
29659
29671
|
e && d(e.base64);
|
|
29660
29672
|
}).catch((e) => {
|
|
29661
|
-
|
|
29673
|
+
j(e instanceof Error ? e.message : String(e));
|
|
29662
29674
|
});
|
|
29663
29675
|
}, [e, a]);
|
|
29664
29676
|
let R = o(async () => {
|
|
@@ -29670,7 +29682,7 @@ function uO({ trpc: e, nodeId: t, onNodeChange: n }) {
|
|
|
29670
29682
|
}));
|
|
29671
29683
|
return t && C(t), t;
|
|
29672
29684
|
} catch (e) {
|
|
29673
|
-
return
|
|
29685
|
+
return j(e instanceof Error ? e.message : String(e)), null;
|
|
29674
29686
|
}
|
|
29675
29687
|
}, [e]);
|
|
29676
29688
|
v(() => {
|
|
@@ -29700,7 +29712,7 @@ function uO({ trpc: e, nodeId: t, onNodeChange: n }) {
|
|
|
29700
29712
|
let r = WD(n);
|
|
29701
29713
|
r && D(r), r && r.state !== "running" && (I.current = null, z(), R());
|
|
29702
29714
|
} catch (e) {
|
|
29703
|
-
t ||
|
|
29715
|
+
t || j(e instanceof Error ? e.message : String(e));
|
|
29704
29716
|
}
|
|
29705
29717
|
};
|
|
29706
29718
|
n();
|
|
@@ -29738,7 +29750,7 @@ function uO({ trpc: e, nodeId: t, onNodeChange: n }) {
|
|
|
29738
29750
|
};
|
|
29739
29751
|
}, [e]);
|
|
29740
29752
|
let re = S?.nodeId ?? null, ie = re !== null && re !== t, B = E?.state === "running", ae = h(() => OD(b.rampText), [b.rampText]), oe = h(() => _ ? AD(SD(_.steps)) : null, [_]), se = oe?.steps ?? [], ce = E?.result ?? null, le = ce ? QD(ce) : null, ue = ce ? KD(ce) : [], de = $D(E), fe = ae.ramp.length > 0 ? Math.round(ae.ramp.length * (b.settleSec + b.measureSec) / 60) : 0, pe = async () => {
|
|
29741
|
-
if (
|
|
29753
|
+
if (j(""), N([]), F([]), D(null), !c) {
|
|
29742
29754
|
N(["No reference image loaded — the ramp needs a frame to pin."]);
|
|
29743
29755
|
return;
|
|
29744
29756
|
}
|
|
@@ -29802,13 +29814,13 @@ function uO({ trpc: e, nodeId: t, onNodeChange: n }) {
|
|
|
29802
29814
|
state: "running"
|
|
29803
29815
|
});
|
|
29804
29816
|
} catch (e) {
|
|
29805
|
-
|
|
29817
|
+
j(e instanceof Error ? e.message : String(e)), z();
|
|
29806
29818
|
} finally {
|
|
29807
29819
|
k(!1);
|
|
29808
29820
|
}
|
|
29809
29821
|
}, me = async () => {
|
|
29810
29822
|
if (w) {
|
|
29811
|
-
|
|
29823
|
+
te(!0);
|
|
29812
29824
|
try {
|
|
29813
29825
|
await e.addons.custom.mutate({
|
|
29814
29826
|
addonId: cO,
|
|
@@ -29816,9 +29828,9 @@ function uO({ trpc: e, nodeId: t, onNodeChange: n }) {
|
|
|
29816
29828
|
input: { sessionId: w }
|
|
29817
29829
|
}), F((e) => [...e, "abort requested — the current step drains, then stops"]);
|
|
29818
29830
|
} catch (e) {
|
|
29819
|
-
|
|
29831
|
+
j(e instanceof Error ? e.message : String(e));
|
|
29820
29832
|
} finally {
|
|
29821
|
-
|
|
29833
|
+
te(!1);
|
|
29822
29834
|
}
|
|
29823
29835
|
}
|
|
29824
29836
|
}, W = O || B;
|
|
@@ -30094,9 +30106,9 @@ function uO({ trpc: e, nodeId: t, onNodeChange: n }) {
|
|
|
30094
30106
|
/* @__PURE__ */ V("button", {
|
|
30095
30107
|
type: "button",
|
|
30096
30108
|
onClick: () => void me(),
|
|
30097
|
-
disabled: !B ||
|
|
30109
|
+
disabled: !B || ee,
|
|
30098
30110
|
className: "px-4 py-2 text-sm rounded-md border border-border text-foreground disabled:opacity-40",
|
|
30099
|
-
children:
|
|
30111
|
+
children: ee ? "aborting…" : "Abort"
|
|
30100
30112
|
}),
|
|
30101
30113
|
w && /* @__PURE__ */ H("span", {
|
|
30102
30114
|
className: "text-[11px] font-mono text-foreground-subtle",
|
|
@@ -30112,9 +30124,9 @@ function uO({ trpc: e, nodeId: t, onNodeChange: n }) {
|
|
|
30112
30124
|
className: "rounded-md bg-danger/10 border border-danger/20 px-3 py-2 text-xs text-danger space-y-1",
|
|
30113
30125
|
children: M.map((e) => /* @__PURE__ */ V("div", { children: e }, e))
|
|
30114
30126
|
}),
|
|
30115
|
-
|
|
30127
|
+
A && /* @__PURE__ */ V("div", {
|
|
30116
30128
|
className: "rounded-md bg-danger/10 border border-danger/20 px-3 py-2 text-xs text-danger",
|
|
30117
|
-
children:
|
|
30129
|
+
children: A
|
|
30118
30130
|
}),
|
|
30119
30131
|
E?.state === "failed" && E.error && /* @__PURE__ */ H("div", {
|
|
30120
30132
|
className: "rounded-md bg-danger/10 border border-danger/20 px-3 py-2 text-xs text-danger",
|
|
@@ -30287,7 +30299,7 @@ function dO(e, t) {
|
|
|
30287
30299
|
}
|
|
30288
30300
|
}
|
|
30289
30301
|
function fO({ trpc: e, nodeId: t }) {
|
|
30290
|
-
let [n, r] = l([]), [i, a] = l(""), [o, s] = l(3), [c, d] = l(25), [f, p] = l("jpeg"), [m, h] = l("duration"), [g, _] = l(60), [y, b] = l(1e3), [x, S] = l(15), [C, w] = l(2e3), [T, E] = l(5), [D, O] = l(20), [k] = l("decoder-nodeav"), [
|
|
30302
|
+
let [n, r] = l([]), [i, a] = l(""), [o, s] = l(3), [c, d] = l(25), [f, p] = l("jpeg"), [m, h] = l("duration"), [g, _] = l(60), [y, b] = l(1e3), [x, S] = l(15), [C, w] = l(2e3), [T, E] = l(5), [D, O] = l(20), [k] = l("decoder-nodeav"), [ee, te] = l(""), [A, j] = l(""), [M] = l(0), [N, P] = l(null), [F, I] = l(!1), [ne, L] = l(""), [R, z] = l(null), [re, ie] = l("idle"), [B, ae] = l(null), [oe, U] = l(!0), se = u(null);
|
|
30291
30303
|
return v(() => {
|
|
30292
30304
|
e.addons.custom.mutate({
|
|
30293
30305
|
addonId: "benchmark",
|
|
@@ -30305,9 +30317,9 @@ function fO({ trpc: e, nodeId: t }) {
|
|
|
30305
30317
|
nodeId: t
|
|
30306
30318
|
}).then((e) => {
|
|
30307
30319
|
let t = e;
|
|
30308
|
-
|
|
30320
|
+
te(String(dO(t, "hwaccel") ?? "")), j(String(dO(t, "probedBestHwaccel") ?? ""));
|
|
30309
30321
|
}).catch((e) => {
|
|
30310
|
-
console.warn("[benchmark:decoder] addon-settings fetch failed:", e),
|
|
30322
|
+
console.warn("[benchmark:decoder] addon-settings fetch failed:", e), te(""), j("");
|
|
30311
30323
|
});
|
|
30312
30324
|
}, [
|
|
30313
30325
|
e,
|
|
@@ -30372,7 +30384,7 @@ function fO({ trpc: e, nodeId: t }) {
|
|
|
30372
30384
|
" ",
|
|
30373
30385
|
/* @__PURE__ */ V("span", {
|
|
30374
30386
|
className: "font-mono text-foreground",
|
|
30375
|
-
children: N ||
|
|
30387
|
+
children: N || ee || A || "none"
|
|
30376
30388
|
}),
|
|
30377
30389
|
" ",
|
|
30378
30390
|
"for this run."
|
|
@@ -30578,7 +30590,7 @@ function fO({ trpc: e, nodeId: t }) {
|
|
|
30578
30590
|
L(""), ae(null), z(null), ie("init");
|
|
30579
30591
|
let r = `decoder-${Date.now()}-${Math.random().toString(36).slice(2, 10)}`;
|
|
30580
30592
|
se.current = r, I(!0);
|
|
30581
|
-
let a = N ||
|
|
30593
|
+
let a = N || ee || A || "none", s = {
|
|
30582
30594
|
sessionId: r,
|
|
30583
30595
|
nodeId: t,
|
|
30584
30596
|
cameras: o,
|
|
@@ -31342,7 +31354,7 @@ function kO({ trpc: e, nodeId: t, onNodeChange: n }) {
|
|
|
31342
31354
|
let [r, i] = l(null), [a, s] = l([]), [c, d] = l(null), [f, p] = l([]), [m, h] = l(""), [g, _] = l(null), [y, b] = l(""), [x, S] = l(null), [C, w] = l({
|
|
31343
31355
|
w: 640,
|
|
31344
31356
|
h: 480
|
|
31345
|
-
}), [T, E] = l([]), [D, O] = l(null), [k,
|
|
31357
|
+
}), [T, E] = l([]), [D, O] = l(null), [k, ee] = l(null), [te, A] = l(null), [j, M] = l(!1), [N, P] = l(""), [F, I] = l(null), [ne, L] = l(!0), [R, z] = l([]), [re, ie] = l(200), [B, ae] = l(4), [oe, U] = l(1), [se, ce] = l(!1), [le, ue] = l(null), [de, fe] = l(null), [pe, me] = l(null), [W, he] = l(null), ge = u(null), [_e, ve] = l(/* @__PURE__ */ new Set()), ye = o((e, t) => {
|
|
31346
31358
|
ve((n) => {
|
|
31347
31359
|
let r = new Set(n);
|
|
31348
31360
|
return t ? r.delete(e) : r.add(e), r;
|
|
@@ -31430,7 +31442,7 @@ function kO({ trpc: e, nodeId: t, onNodeChange: n }) {
|
|
|
31430
31442
|
} catch (e) {
|
|
31431
31443
|
console.warn("[benchmark:image] Failed to load image:", e);
|
|
31432
31444
|
}
|
|
31433
|
-
}, xe =
|
|
31445
|
+
}, xe = te ? SD(te.steps) : T.map((e) => OO(e)), Se = async () => {
|
|
31434
31446
|
M(!0), P(""), I(null), z([]);
|
|
31435
31447
|
let n = `ui-${Date.now()}-${Math.random().toString(36).slice(2, 10)}`;
|
|
31436
31448
|
ge.current = n;
|
|
@@ -31542,11 +31554,11 @@ function kO({ trpc: e, nodeId: t, onNodeChange: n }) {
|
|
|
31542
31554
|
nodeId: t,
|
|
31543
31555
|
onNodeChange: n,
|
|
31544
31556
|
deviceKey: k,
|
|
31545
|
-
onDeviceKeyChange:
|
|
31557
|
+
onDeviceKeyChange: ee,
|
|
31546
31558
|
selectedDeviceId: D,
|
|
31547
31559
|
onSelectCamera: O,
|
|
31548
|
-
onResolved:
|
|
31549
|
-
disabled:
|
|
31560
|
+
onResolved: A,
|
|
31561
|
+
disabled: j || se
|
|
31550
31562
|
}),
|
|
31551
31563
|
/* @__PURE__ */ V(FE, {
|
|
31552
31564
|
images: f,
|
|
@@ -31568,9 +31580,9 @@ function kO({ trpc: e, nodeId: t, onNodeChange: n }) {
|
|
|
31568
31580
|
children: [
|
|
31569
31581
|
/* @__PURE__ */ V("button", {
|
|
31570
31582
|
onClick: Se,
|
|
31571
|
-
disabled: !
|
|
31572
|
-
className: `w-full px-4 py-2.5 text-sm font-medium rounded-lg transition-colors ${
|
|
31573
|
-
children:
|
|
31583
|
+
disabled: !j && !m && !g,
|
|
31584
|
+
className: `w-full px-4 py-2.5 text-sm font-medium rounded-lg transition-colors ${j ? "bg-primary text-primary-foreground animate-pulse" : "bg-primary text-primary-foreground hover:bg-primary/90 disabled:opacity-50"}`,
|
|
31585
|
+
children: j ? R.length > 0 ? R[R.length - 1] : "Processing..." : "Run Pipeline"
|
|
31574
31586
|
}),
|
|
31575
31587
|
/* @__PURE__ */ H("div", {
|
|
31576
31588
|
className: "rounded-md border border-border bg-surface p-2 space-y-2",
|
|
@@ -31673,7 +31685,7 @@ function kO({ trpc: e, nodeId: t, onNodeChange: n }) {
|
|
|
31673
31685
|
t,
|
|
31674
31686
|
" · ",
|
|
31675
31687
|
k ?? "node default pool",
|
|
31676
|
-
|
|
31688
|
+
te ? ` · camera #${te.deviceId} (resolved tree)` : " · custom tree"
|
|
31677
31689
|
]
|
|
31678
31690
|
})
|
|
31679
31691
|
]
|
|
@@ -33083,7 +33095,7 @@ function ZO(e) {
|
|
|
33083
33095
|
return t;
|
|
33084
33096
|
}
|
|
33085
33097
|
function QO({ trpc: e }) {
|
|
33086
|
-
let [t, n] = l([]), [r, i] = l(""), [a, s] = l(null), [c, u] = l(""), [d, f] = l([]), [p, m] = l(/* @__PURE__ */ new Set()), [g, _] = l({}), [y, b] = l({}), [x, S] = l({}), [C, w] = l({}), [T, E] = l({}), [D, O] = l(15), [k,
|
|
33098
|
+
let [t, n] = l([]), [r, i] = l(""), [a, s] = l(null), [c, u] = l(""), [d, f] = l([]), [p, m] = l(/* @__PURE__ */ new Set()), [g, _] = l({}), [y, b] = l({}), [x, S] = l({}), [C, w] = l({}), [T, E] = l({}), [D, O] = l(15), [k, ee] = l(4), [te, A] = l(2), [j, M] = l(640), [N, P] = l(!1), [F, I] = l(null), [ne, L] = l(null), [R, z] = l(""), [re, ie] = l(null);
|
|
33087
33099
|
v(() => {
|
|
33088
33100
|
e.pipelineExecutor.listReferenceImages.query().then((e) => {
|
|
33089
33101
|
n(e), e.length > 0 && e[0] && (i(e[0].filename), u(e[0].filename));
|
|
@@ -33216,15 +33228,15 @@ function QO({ trpc: e }) {
|
|
|
33216
33228
|
};
|
|
33217
33229
|
});
|
|
33218
33230
|
});
|
|
33219
|
-
L(`running ${D}s · batch ${k} · concurrency ${
|
|
33231
|
+
L(`running ${D}s · batch ${k} · concurrency ${te} · ${r.length} node(s)`), ie(await e.addons.custom.mutate({
|
|
33220
33232
|
addonId: "benchmark",
|
|
33221
33233
|
action: "runSustainedThroughput",
|
|
33222
33234
|
input: {
|
|
33223
33235
|
frameId: n,
|
|
33224
33236
|
durationSec: D,
|
|
33225
33237
|
batchSize: k,
|
|
33226
|
-
concurrency:
|
|
33227
|
-
targetSize:
|
|
33238
|
+
concurrency: te,
|
|
33239
|
+
targetSize: j,
|
|
33228
33240
|
sessionId: t,
|
|
33229
33241
|
nodes: r
|
|
33230
33242
|
}
|
|
@@ -33249,8 +33261,8 @@ function QO({ trpc: e }) {
|
|
|
33249
33261
|
C,
|
|
33250
33262
|
D,
|
|
33251
33263
|
k,
|
|
33252
|
-
|
|
33253
|
-
|
|
33264
|
+
te,
|
|
33265
|
+
j
|
|
33254
33266
|
]), le = "w-24 px-2 py-1.5 text-sm rounded-md border border-border bg-surface text-foreground", ue = "rounded-lg border border-border bg-surface p-4 space-y-3";
|
|
33255
33267
|
return /* @__PURE__ */ H("div", {
|
|
33256
33268
|
className: "space-y-4",
|
|
@@ -33332,7 +33344,7 @@ function QO({ trpc: e }) {
|
|
|
33332
33344
|
min: 1,
|
|
33333
33345
|
max: 255,
|
|
33334
33346
|
value: k,
|
|
33335
|
-
onChange: (e) =>
|
|
33347
|
+
onChange: (e) => ee(Math.max(1, Number(e.target.value) || 1)),
|
|
33336
33348
|
className: le
|
|
33337
33349
|
})]
|
|
33338
33350
|
}),
|
|
@@ -33345,8 +33357,8 @@ function QO({ trpc: e }) {
|
|
|
33345
33357
|
type: "number",
|
|
33346
33358
|
min: 1,
|
|
33347
33359
|
max: 64,
|
|
33348
|
-
value:
|
|
33349
|
-
onChange: (e) =>
|
|
33360
|
+
value: te,
|
|
33361
|
+
onChange: (e) => A(Math.max(1, Number(e.target.value) || 1)),
|
|
33350
33362
|
className: le
|
|
33351
33363
|
})]
|
|
33352
33364
|
}),
|
|
@@ -33360,7 +33372,7 @@ function QO({ trpc: e }) {
|
|
|
33360
33372
|
min: 64,
|
|
33361
33373
|
max: 2048,
|
|
33362
33374
|
step: 32,
|
|
33363
|
-
value:
|
|
33375
|
+
value: j,
|
|
33364
33376
|
onChange: (e) => M(Math.max(64, Number(e.target.value) || 640)),
|
|
33365
33377
|
className: le
|
|
33366
33378
|
})]
|
|
@@ -33774,14 +33786,14 @@ function ck({ trpc: e }) {
|
|
|
33774
33786
|
} finally {
|
|
33775
33787
|
m(!1);
|
|
33776
33788
|
}
|
|
33777
|
-
}, [E, a]),
|
|
33789
|
+
}, [E, a]), ee = o(async () => {
|
|
33778
33790
|
m(!0), y(null);
|
|
33779
33791
|
try {
|
|
33780
33792
|
y(await ak(E, a));
|
|
33781
33793
|
} finally {
|
|
33782
33794
|
m(!1);
|
|
33783
33795
|
}
|
|
33784
|
-
}, [E, a]),
|
|
33796
|
+
}, [E, a]), te = o(async () => {
|
|
33785
33797
|
m(!0), x([]);
|
|
33786
33798
|
let e = [];
|
|
33787
33799
|
for (let t of T) {
|
|
@@ -33924,13 +33936,13 @@ function ck({ trpc: e }) {
|
|
|
33924
33936
|
}),
|
|
33925
33937
|
/* @__PURE__ */ V(uk, {
|
|
33926
33938
|
label: "Connectivity",
|
|
33927
|
-
onClick: () => void
|
|
33939
|
+
onClick: () => void ee(),
|
|
33928
33940
|
disabled: p || T.length === 0,
|
|
33929
33941
|
running: p
|
|
33930
33942
|
}),
|
|
33931
33943
|
/* @__PURE__ */ V(uk, {
|
|
33932
33944
|
label: "Test each endpoint",
|
|
33933
|
-
onClick: () => void
|
|
33945
|
+
onClick: () => void te(),
|
|
33934
33946
|
disabled: p || T.length === 0,
|
|
33935
33947
|
running: p
|
|
33936
33948
|
})
|