@feedmepos/mf-report 5.34.2 → 5.35.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{App-D-YQ3yMW.js → App-Dv36-JBr.js} +4 -4
- package/dist/{DateRangeSelect-OTyc3v5_.js → DateRangeSelect-CSuWTBDR.js} +1 -1
- package/dist/{Default.vue_vue_type_script_setup_true_lang-CxIN_bfu.js → Default.vue_vue_type_script_setup_true_lang-BFuav3fL.js} +1 -1
- package/dist/{DigestListView-DCpIQY1v.js → DigestListView-lWXR-Yqe.js} +3 -3
- package/dist/DigestReaderView-cKRrj4qw.js +489 -0
- package/dist/{DynamicWidget.vue_vue_type_script_setup_true_lang-iRcCryhy.js → DynamicWidget.vue_vue_type_script_setup_true_lang-D0OTyDep.js} +173 -173
- package/dist/{GlobalFilterSelect.vue_vue_type_script_setup_true_lang-VTI9bq-3.js → GlobalFilterSelect.vue_vue_type_script_setup_true_lang-lFm4G3pA.js} +175 -175
- package/dist/{InsightView-WQ3IXr2b.js → InsightView-BO2y0s6E.js} +5 -5
- package/dist/{Integration-Bx6Xt8rm.js → Integration-DZR0sg3Y.js} +3 -3
- package/dist/{Integrations-BSsJGc4e.js → Integrations-C8IJSs8_.js} +2 -2
- package/dist/{Layout-CmTYhuDW.js → Layout-DKE_UPyV.js} +1 -1
- package/dist/{LocationSelect.vue_vue_type_script_setup_true_lang-SjaEdhpI.js → LocationSelect.vue_vue_type_script_setup_true_lang-pKBQdsry.js} +1553 -1547
- package/dist/{MenuTab.vue_vue_type_script_setup_true_lang-CtJRTkuw.js → MenuTab.vue_vue_type_script_setup_true_lang-DsTCV4je.js} +5 -5
- package/dist/{NavigationTab.vue_vue_type_script_setup_true_lang-DERX_GCc.js → NavigationTab.vue_vue_type_script_setup_true_lang-uFKb4Unh.js} +5 -5
- package/dist/{OverviewView-BXuqus0r.js → OverviewView--6juk8Ny.js} +5 -5
- package/dist/{Report-Cj7xHOMI.js → Report-B7tYzV-u.js} +3 -3
- package/dist/ReportCanvasView-DJZItxK4.js +1066 -0
- package/dist/{ReportEditor-v3CRHflb.js → ReportEditor-lP1wy7eF.js} +7 -7
- package/dist/{ReportView-IbQC8Qf1.js → ReportView-BFdf3j2m.js} +6 -6
- package/dist/{ReportViewRoute-NwvXWZDf.js → ReportViewRoute-D5tZcb3A.js} +2 -2
- package/dist/{Setting-GyFSTgFs.js → Setting-CdOGOX1H.js} +94 -94
- package/dist/{Template-DLVGn41O.js → Template-CcNz2aVR.js} +3 -3
- package/dist/{TileEditor-DT4ayXKN.js → TileEditor-D8QsUytE.js} +6 -6
- package/dist/{TilePageStack.vue_vue_type_script_setup_true_lang-Bh0NcO-n.js → TilePageStack.vue_vue_type_script_setup_true_lang-D2Tz0EW3.js} +2 -2
- package/dist/{TransitionFade-DIDahT3W.js → TransitionFade-qKsTOksI.js} +5 -5
- package/dist/{app-X-tKojve.js → app-D9WJwZyu.js} +19 -19
- package/dist/app.js +1 -1
- package/dist/assets/{formatChartData.worker-Cpgnh20a.js → formatChartData.worker-Bt8turfo.js} +22 -22
- package/dist/assets/{processTableData.worker-B7I6PElJ.js → processTableData.worker-MGb36f8J.js} +22 -22
- package/dist/{currency-Cebf4JT_.js → currency-Dx3wVA1Q.js} +1 -1
- package/dist/{index-Brvkpnxl.js → index-c2QQydke.js} +503 -473
- package/dist/{report-CoK9Yl1E.js → report-tffVXl4d.js} +1 -1
- package/dist/style.css +1 -1
- package/dist/{useDigestFont-DUUhWR6u.js → useDigestFont-DfORxCFz.js} +1 -1
- package/dist/{useReportCanvasPanel-B8qruqY0.js → useReportCanvasPicks-D1IdA31H.js} +1353 -1264
- package/dist/{useRestaurantPermission-BTBg_goI.js → useRestaurantPermission-CrqMkVed.js} +1 -1
- package/package.json +2 -2
- package/dist/DigestReaderView-W6sW8h9Q.js +0 -526
- package/dist/ReportCanvasView-CGt4ayU2.js +0 -1035
|
@@ -1,342 +1,362 @@
|
|
|
1
|
-
import { ref as
|
|
1
|
+
import { ref as O, shallowRef as Bt, getCurrentScope as Ct, onScopeDispose as Tt, watch as ie, onMounted as Pe, onBeforeUnmount as Le, defineComponent as $e, computed as $, resolveComponent as Oe, openBlock as c, createElementBlock as p, Fragment as fe, renderList as me, createElementVNode as N, createVNode as Z, toDisplayString as A, unref as v, createCommentVNode as j, createTextVNode as Ce, createBlock as ge, nextTick as we, normalizeClass as Ze, h as ce, useModel as rt, withCtx as Ue, mergeProps as ot, mergeModels as it } from "vue";
|
|
2
2
|
import { storeToRefs as ze } from "pinia";
|
|
3
|
-
import { detectLocale as
|
|
4
|
-
import { w as
|
|
5
|
-
import { c as
|
|
3
|
+
import { detectLocale as qt } from "@feedmepos/mf-common";
|
|
4
|
+
import { w as re, F as oe, u as De, a as Vt, a6 as Ft, a7 as Ut, a8 as Ht, a9 as Wt, A as Gt, aa as Yt, ab as Xt, ac as Kt, ad as Jt, ae as Qt, af as Zt } from "./app-D9WJwZyu.js";
|
|
5
|
+
import { c as en } from "./currency-Dx3wVA1Q.js";
|
|
6
6
|
import { l as st } from "./report-canvas-libs-CNx4fuqd.js";
|
|
7
|
-
import { u as Be, _ as
|
|
8
|
-
import { v as lt } from "./report-
|
|
9
|
-
function
|
|
7
|
+
import { u as Be, _ as Et } from "./_plugin-vue_export-helper-Bx7s49ra.js";
|
|
8
|
+
import { v as lt } from "./report-tffVXl4d.js";
|
|
9
|
+
function be(e) {
|
|
10
10
|
const { businessId: t } = ze(De());
|
|
11
11
|
if (!t.value) throw new Error("Business Id is not defined");
|
|
12
12
|
return `/${t.value}/report-canvas/${e}`;
|
|
13
13
|
}
|
|
14
|
-
const
|
|
14
|
+
const io = (e) => {
|
|
15
15
|
const t = {
|
|
16
|
-
fetchType:
|
|
17
|
-
url:
|
|
16
|
+
fetchType: oe.Get,
|
|
17
|
+
url: be(e)
|
|
18
18
|
};
|
|
19
|
-
return
|
|
20
|
-
},
|
|
21
|
-
const
|
|
22
|
-
fetchType:
|
|
23
|
-
url: `${
|
|
19
|
+
return re.fetch(t);
|
|
20
|
+
}, tn = (e, t, n, r, a, o) => {
|
|
21
|
+
const y = {
|
|
22
|
+
fetchType: oe.Post,
|
|
23
|
+
url: `${be(e)}/query/${t}`,
|
|
24
24
|
// a draft-only query id does not exist on the published copy, so the state travels with it
|
|
25
25
|
data: { params: n, timezone: r, state: a },
|
|
26
|
-
requestConfig: { signal:
|
|
26
|
+
requestConfig: { signal: o }
|
|
27
27
|
};
|
|
28
|
-
return
|
|
29
|
-
},
|
|
28
|
+
return re.fetch(y);
|
|
29
|
+
}, so = (e, t, n, r) => {
|
|
30
30
|
const a = {
|
|
31
|
-
fetchType:
|
|
32
|
-
url: `${
|
|
31
|
+
fetchType: oe.Post,
|
|
32
|
+
url: `${be(e)}/section/${t}/ack`,
|
|
33
33
|
data: { ...n, state: r }
|
|
34
34
|
};
|
|
35
|
-
return
|
|
36
|
-
},
|
|
37
|
-
fetchType:
|
|
38
|
-
url: `${
|
|
35
|
+
return re.fetch(a);
|
|
36
|
+
}, lo = (e) => re.fetch({
|
|
37
|
+
fetchType: oe.Post,
|
|
38
|
+
url: `${be(e)}/publish`,
|
|
39
39
|
data: {}
|
|
40
|
-
}),
|
|
41
|
-
fetchType:
|
|
42
|
-
url: `${
|
|
43
|
-
}),
|
|
44
|
-
fetchType:
|
|
45
|
-
url: `${
|
|
40
|
+
}), fo = (e) => re.fetch({
|
|
41
|
+
fetchType: oe.Delete,
|
|
42
|
+
url: `${be(e)}/draft`
|
|
43
|
+
}), co = (e, t) => re.fetch({
|
|
44
|
+
fetchType: oe.Post,
|
|
45
|
+
url: `${be(e)}/draft/undo`,
|
|
46
46
|
data: { turnId: t }
|
|
47
|
-
}),
|
|
48
|
-
fetchType:
|
|
49
|
-
url: `${
|
|
50
|
-
}),
|
|
51
|
-
fetchType:
|
|
52
|
-
url: `${
|
|
47
|
+
}), mo = (e) => re.fetch({
|
|
48
|
+
fetchType: oe.Get,
|
|
49
|
+
url: `${be(e)}/versions`
|
|
50
|
+
}), uo = (e, t) => re.fetch({
|
|
51
|
+
fetchType: oe.Post,
|
|
52
|
+
url: `${be(e)}/restore`,
|
|
53
53
|
data: { versionId: t }
|
|
54
|
-
}),
|
|
55
|
-
function
|
|
56
|
-
if (!(!(e instanceof
|
|
57
|
-
return Math.min(Math.max(e.retryAfterMs ??
|
|
54
|
+
}), nn = ["@from", "@to", "@locationIds", "@timezone"], et = ["@from", "@to", "@locationIds"], an = ["@timezone"], rn = ["@locationIds"], on = 1, sn = 1500;
|
|
55
|
+
function ln(e) {
|
|
56
|
+
if (!(!(e instanceof Gt) || e.status !== 429))
|
|
57
|
+
return Math.min(Math.max(e.retryAfterMs ?? sn, 500), 5e3);
|
|
58
58
|
}
|
|
59
59
|
const ft = {
|
|
60
|
-
"en-US":
|
|
61
|
-
"th-TH":
|
|
62
|
-
"zh-CN":
|
|
63
|
-
"zh-Hant":
|
|
60
|
+
"en-US": Wt,
|
|
61
|
+
"th-TH": Ht,
|
|
62
|
+
"zh-CN": Ut,
|
|
63
|
+
"zh-Hant": Ft
|
|
64
64
|
};
|
|
65
|
-
function
|
|
66
|
-
var a,
|
|
67
|
-
const t = ft[e] ?? ft["en-US"], n = {}, r = (
|
|
68
|
-
for (const [
|
|
69
|
-
typeof u == "string" ? n[`${
|
|
65
|
+
function fn(e) {
|
|
66
|
+
var a, o;
|
|
67
|
+
const t = ft[e] ?? ft["en-US"], n = {}, r = (y, x) => {
|
|
68
|
+
for (const [w, u] of Object.entries(y ?? {}))
|
|
69
|
+
typeof u == "string" ? n[`${x}${w}`] = u : u && typeof u == "object" && r(u, `${x}${w}.`);
|
|
70
70
|
};
|
|
71
|
-
return r(((
|
|
71
|
+
return r(((o = (a = t == null ? void 0 : t.reportV5) == null ? void 0 : a.reportCanvas) == null ? void 0 : o.frame) ?? {}, ""), n;
|
|
72
72
|
}
|
|
73
|
-
function
|
|
73
|
+
function Ot(e) {
|
|
74
74
|
return e == null ? !0 : Array.isArray(e) ? e.length === 0 : e === "";
|
|
75
75
|
}
|
|
76
|
-
function
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
const
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
76
|
+
function dn(e) {
|
|
77
|
+
return !et.some((t) => t in e && Ot(e[t] ?? null));
|
|
78
|
+
}
|
|
79
|
+
function cn(e, t) {
|
|
80
|
+
var r;
|
|
81
|
+
const n = typeof e == "string" || typeof e == "number" || typeof e == "boolean";
|
|
82
|
+
return (r = t == null ? void 0 : t.type) != null && r.endsWith("[]") && n ? [e] : e;
|
|
83
|
+
}
|
|
84
|
+
function mn(e, t) {
|
|
85
|
+
return rn.includes(e) ? t == null ? void 0 : t[e] : void 0;
|
|
86
|
+
}
|
|
87
|
+
function un(e, t, n) {
|
|
88
|
+
return e[t] === n ? !1 : (n ? e[t] = n : delete e[t], !0);
|
|
89
|
+
}
|
|
90
|
+
function pn(e, t, n) {
|
|
91
|
+
const r = e[t];
|
|
92
|
+
return r ? { queryId: t, runId: n, status: "ok", rows: r.rows, truncated: r.truncated } : { queryId: t, runId: n, status: "error", rows: [], truncated: !1, error: `no saved rows for ${t}` };
|
|
93
|
+
}
|
|
94
|
+
function hn(e, t, n) {
|
|
95
|
+
return {
|
|
96
|
+
queryId: e,
|
|
97
|
+
runId: t,
|
|
98
|
+
status: "ok",
|
|
99
|
+
rows: n.rows ?? [],
|
|
100
|
+
truncated: !!n.truncated,
|
|
101
|
+
...typeof n.total == "number" ? { total: n.total } : {}
|
|
102
|
+
};
|
|
103
|
+
}
|
|
104
|
+
function gn(e, t, n) {
|
|
105
|
+
return {
|
|
106
|
+
queryId: e,
|
|
107
|
+
runId: t,
|
|
108
|
+
status: "error",
|
|
109
|
+
rows: [],
|
|
110
|
+
truncated: !1,
|
|
111
|
+
error: n instanceof Error ? n.message : String(n)
|
|
112
|
+
};
|
|
113
|
+
}
|
|
114
|
+
function po(e, t = {}) {
|
|
115
|
+
const n = t.frozen, r = Vt(), { dateRange: a, selectedLocationIds: o, locations: y, timezone: x } = ze(r), { country: w } = ze(De()), u = O({}), M = O([]), z = O({}), h = Bt({}), _ = O(), I = O([]), L = [], R = [], E = { ids: "[]", date: "" };
|
|
116
|
+
let P = !1;
|
|
117
|
+
const F = {}, G = {};
|
|
118
|
+
Ct() && Tt(() => Object.values(G).forEach((b) => b.abort()));
|
|
119
|
+
const Y = {};
|
|
120
|
+
function Q(b) {
|
|
121
|
+
L.push(b);
|
|
122
|
+
}
|
|
123
|
+
function m(b) {
|
|
124
|
+
R.push(b);
|
|
125
|
+
}
|
|
126
|
+
function k(b) {
|
|
127
|
+
h.value = { ...h.value, [b.queryId]: b }, L.forEach((C) => C(b));
|
|
128
|
+
}
|
|
129
|
+
function g(b) {
|
|
130
|
+
const C = {};
|
|
131
|
+
for (const D of b.params)
|
|
132
|
+
C[D.name] = D.default ?? null;
|
|
95
133
|
if (n) {
|
|
96
|
-
u.value =
|
|
134
|
+
u.value = C, z.value = {};
|
|
97
135
|
return;
|
|
98
136
|
}
|
|
99
|
-
|
|
137
|
+
C["@from"] = a.value.startDate ?? null, C["@to"] = a.value.endDate ?? null, C["@timezone"] = x.value, C["@locationIds"] = [...o.value], u.value = C, z.value = {}, K();
|
|
100
138
|
}
|
|
101
|
-
function
|
|
102
|
-
return
|
|
139
|
+
function H() {
|
|
140
|
+
return y.value.map((b) => b.id);
|
|
103
141
|
}
|
|
104
|
-
function
|
|
142
|
+
function V() {
|
|
105
143
|
return { startDate: a.value.startDate, endDate: a.value.endDate };
|
|
106
144
|
}
|
|
107
145
|
function K() {
|
|
108
|
-
|
|
146
|
+
E.ids = JSON.stringify([...o.value]), E.date = JSON.stringify(V());
|
|
109
147
|
}
|
|
110
|
-
function
|
|
148
|
+
function ne() {
|
|
111
149
|
if (n) return;
|
|
112
|
-
const
|
|
113
|
-
if (typeof
|
|
114
|
-
const
|
|
115
|
-
startDate: typeof
|
|
116
|
-
endDate: typeof
|
|
150
|
+
const b = u.value["@from"], C = u.value["@to"];
|
|
151
|
+
if (typeof b == "string" || typeof C == "string") {
|
|
152
|
+
const q = {
|
|
153
|
+
startDate: typeof b == "string" ? b : void 0,
|
|
154
|
+
endDate: typeof C == "string" ? C : void 0
|
|
117
155
|
};
|
|
118
|
-
JSON.stringify(
|
|
156
|
+
JSON.stringify(q) !== JSON.stringify(V()) && (a.value = q);
|
|
119
157
|
}
|
|
120
|
-
const
|
|
121
|
-
if (Array.isArray(
|
|
122
|
-
const
|
|
123
|
-
JSON.stringify(
|
|
158
|
+
const D = u.value["@locationIds"];
|
|
159
|
+
if (Array.isArray(D)) {
|
|
160
|
+
const q = D.map(String);
|
|
161
|
+
JSON.stringify(q) !== JSON.stringify(o.value) && (o.value = q);
|
|
124
162
|
}
|
|
125
163
|
K();
|
|
126
164
|
}
|
|
127
|
-
function
|
|
128
|
-
const
|
|
129
|
-
JSON.stringify(
|
|
165
|
+
function ae() {
|
|
166
|
+
const b = [...o.value], C = {}, D = { ...z.value };
|
|
167
|
+
JSON.stringify(V()) !== E.date && (C["@from"] = a.value.startDate ?? null, C["@to"] = a.value.endDate ?? null), JSON.stringify(b) !== E.ids ? (C["@locationIds"] = b, delete D["@locationIds"]) : D["@locationIds"] === "all" && (C["@locationIds"] = H()), Object.keys(C).length && _e(C, D);
|
|
130
168
|
}
|
|
131
|
-
function
|
|
132
|
-
n ||
|
|
133
|
-
|
|
169
|
+
function ee() {
|
|
170
|
+
n || ie([a, o, y], () => {
|
|
171
|
+
P && ae();
|
|
134
172
|
});
|
|
135
173
|
}
|
|
136
|
-
function
|
|
137
|
-
return { values: u.value, decls:
|
|
174
|
+
function ve() {
|
|
175
|
+
return { values: u.value, decls: M.value, intent: z.value };
|
|
138
176
|
}
|
|
139
177
|
function ue() {
|
|
140
|
-
const
|
|
178
|
+
const b = qt() || "en-US";
|
|
141
179
|
return {
|
|
142
|
-
locations:
|
|
143
|
-
id:
|
|
144
|
-
name:
|
|
145
|
-
code:
|
|
180
|
+
locations: y.value.map((C) => ({
|
|
181
|
+
id: C.id,
|
|
182
|
+
name: C.name || C.id,
|
|
183
|
+
code: C.code
|
|
146
184
|
})),
|
|
147
|
-
timezone: n && typeof u.value["@timezone"] == "string" ? u.value["@timezone"] :
|
|
148
|
-
locale:
|
|
149
|
-
currency:
|
|
150
|
-
strings:
|
|
185
|
+
timezone: n && typeof u.value["@timezone"] == "string" ? u.value["@timezone"] : x.value,
|
|
186
|
+
locale: b,
|
|
187
|
+
currency: en(w.value),
|
|
188
|
+
strings: fn(b)
|
|
151
189
|
};
|
|
152
190
|
}
|
|
153
|
-
function
|
|
154
|
-
return JSON.stringify(
|
|
191
|
+
function ye(b, C) {
|
|
192
|
+
return JSON.stringify(b.dependsOn.map((D) => C[D] ?? null));
|
|
155
193
|
}
|
|
156
|
-
function
|
|
157
|
-
return
|
|
158
|
-
const
|
|
159
|
-
return ((
|
|
194
|
+
function te(b, C) {
|
|
195
|
+
return b.lazy ? b.dependsOn.some((D) => {
|
|
196
|
+
const q = M.value.find((X) => X.name === D);
|
|
197
|
+
return ((q == null ? void 0 : q.default) ?? null) === null && Ot(C[D] ?? null);
|
|
160
198
|
}) : !1;
|
|
161
199
|
}
|
|
162
|
-
function
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
const O = (V[h.id] ?? 0) + 1;
|
|
168
|
-
if (V[h.id] = O, n) {
|
|
169
|
-
const o = n[h.id];
|
|
170
|
-
y(
|
|
171
|
-
o ? { queryId: h.id, runId: O, status: "ok", rows: o.rows, truncated: o.truncated } : { queryId: h.id, runId: O, status: "error", rows: [], truncated: !1, error: `no saved rows for ${h.id}` }
|
|
172
|
-
);
|
|
200
|
+
async function ke(b, C) {
|
|
201
|
+
var l, s;
|
|
202
|
+
const D = (F[b.id] ?? 0) + 1;
|
|
203
|
+
if (F[b.id] = D, n) {
|
|
204
|
+
k(pn(n, b.id, D));
|
|
173
205
|
return;
|
|
174
206
|
}
|
|
175
|
-
(
|
|
176
|
-
const
|
|
177
|
-
|
|
178
|
-
queryId:
|
|
179
|
-
runId:
|
|
207
|
+
(l = G[b.id]) == null || l.abort();
|
|
208
|
+
const q = new AbortController();
|
|
209
|
+
G[b.id] = q, k({
|
|
210
|
+
queryId: b.id,
|
|
211
|
+
runId: D,
|
|
180
212
|
status: "loading",
|
|
181
|
-
rows: ((
|
|
213
|
+
rows: ((s = h.value[b.id]) == null ? void 0 : s.rows) ?? [],
|
|
182
214
|
truncated: !1
|
|
183
215
|
});
|
|
184
|
-
|
|
216
|
+
const X = await Ee(b.id, C, q, D);
|
|
217
|
+
X && k(X);
|
|
218
|
+
}
|
|
219
|
+
function pe(b, C) {
|
|
220
|
+
G[b] === C && delete G[b];
|
|
221
|
+
}
|
|
222
|
+
async function Ee(b, C, D, q) {
|
|
223
|
+
const X = () => F[b] === q;
|
|
224
|
+
for (let l = 0; ; l++)
|
|
185
225
|
try {
|
|
186
|
-
const
|
|
226
|
+
const s = await tn(
|
|
187
227
|
e,
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
228
|
+
b,
|
|
229
|
+
C,
|
|
230
|
+
x.value,
|
|
231
|
+
_.value,
|
|
232
|
+
D.signal
|
|
193
233
|
);
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
truncated: !!p.truncated,
|
|
201
|
-
...typeof p.total == "number" ? { total: p.total } : {}
|
|
202
|
-
});
|
|
203
|
-
return;
|
|
204
|
-
} catch (p) {
|
|
205
|
-
if (F.signal.aborted || V[h.id] !== O) return;
|
|
206
|
-
const G = sn(p);
|
|
207
|
-
if (G !== void 0 && o < rn) {
|
|
208
|
-
if (await new Promise((W) => setTimeout(W, G)), V[h.id] !== O) return;
|
|
209
|
-
continue;
|
|
210
|
-
}
|
|
211
|
-
y({
|
|
212
|
-
queryId: h.id,
|
|
213
|
-
runId: O,
|
|
214
|
-
status: "error",
|
|
215
|
-
rows: [],
|
|
216
|
-
truncated: !1,
|
|
217
|
-
error: p instanceof Error ? p.message : String(p)
|
|
218
|
-
});
|
|
219
|
-
return;
|
|
234
|
+
return pe(b, D), X() ? hn(b, q, s) : void 0;
|
|
235
|
+
} catch (s) {
|
|
236
|
+
if (D.signal.aborted || !X()) return;
|
|
237
|
+
const W = ln(s);
|
|
238
|
+
if (W === void 0 || l >= on) return gn(b, q, s);
|
|
239
|
+
if (await new Promise((U) => setTimeout(U, W)), !X()) return;
|
|
220
240
|
}
|
|
221
241
|
}
|
|
222
|
-
function
|
|
223
|
-
var
|
|
224
|
-
const
|
|
225
|
-
for (const
|
|
226
|
-
const
|
|
227
|
-
if (
|
|
228
|
-
delete
|
|
229
|
-
queryId:
|
|
230
|
-
runId:
|
|
242
|
+
function se(b = {}) {
|
|
243
|
+
var q, X, l;
|
|
244
|
+
const C = { ...u.value }, D = !dn(C);
|
|
245
|
+
for (const s of I.value) {
|
|
246
|
+
const W = D && s.dependsOn.some((de) => et.includes(de));
|
|
247
|
+
if (te(s, C)) {
|
|
248
|
+
delete Y[s.id], ((q = h.value[s.id]) == null ? void 0 : q.status) !== "idle" && k({
|
|
249
|
+
queryId: s.id,
|
|
250
|
+
runId: F[s.id] ?? 0,
|
|
231
251
|
status: "idle",
|
|
232
252
|
rows: [],
|
|
233
253
|
truncated: !1
|
|
234
254
|
});
|
|
235
255
|
continue;
|
|
236
256
|
}
|
|
237
|
-
if (
|
|
238
|
-
((
|
|
239
|
-
queryId:
|
|
240
|
-
runId:
|
|
257
|
+
if (W) {
|
|
258
|
+
((X = h.value[s.id]) == null ? void 0 : X.status) !== "loading" && k({
|
|
259
|
+
queryId: s.id,
|
|
260
|
+
runId: F[s.id] ?? 0,
|
|
241
261
|
status: "loading",
|
|
242
|
-
rows: ((
|
|
262
|
+
rows: ((l = h.value[s.id]) == null ? void 0 : l.rows) ?? [],
|
|
243
263
|
truncated: !1
|
|
244
264
|
});
|
|
245
265
|
continue;
|
|
246
266
|
}
|
|
247
|
-
const
|
|
248
|
-
!
|
|
249
|
-
}
|
|
250
|
-
}
|
|
251
|
-
function
|
|
252
|
-
const
|
|
253
|
-
let
|
|
254
|
-
for (const [
|
|
255
|
-
if (!(
|
|
256
|
-
const
|
|
257
|
-
|
|
258
|
-
}
|
|
259
|
-
return
|
|
260
|
-
}
|
|
261
|
-
function
|
|
262
|
-
|
|
263
|
-
for (const
|
|
264
|
-
for (const
|
|
265
|
-
g(
|
|
266
|
-
}
|
|
267
|
-
function
|
|
268
|
-
|
|
269
|
-
const
|
|
270
|
-
for (const
|
|
271
|
-
|
|
272
|
-
u.value =
|
|
273
|
-
const
|
|
274
|
-
for (const
|
|
275
|
-
for (const
|
|
276
|
-
const
|
|
277
|
-
if (
|
|
278
|
-
const
|
|
279
|
-
for (const
|
|
280
|
-
|
|
281
|
-
}
|
|
282
|
-
for (const
|
|
283
|
-
return
|
|
267
|
+
const U = ye(s, C);
|
|
268
|
+
!b.force && Y[s.id] === U || (Y[s.id] = U, ke(s, C));
|
|
269
|
+
}
|
|
270
|
+
}
|
|
271
|
+
function _e(b, C) {
|
|
272
|
+
const D = { ...u.value }, q = { ...z.value };
|
|
273
|
+
let X = !1;
|
|
274
|
+
for (const [l, s] of Object.entries(b)) {
|
|
275
|
+
if (!(l in D) || an.includes(l)) continue;
|
|
276
|
+
const W = cn(s, M.value.find((U) => U.name === l));
|
|
277
|
+
un(q, l, mn(l, C)) && (X = !0), JSON.stringify(D[l] ?? null) !== JSON.stringify(W ?? null) && (D[l] = W, X = !0);
|
|
278
|
+
}
|
|
279
|
+
return X ? (u.value = D, z.value = q, Object.keys(b).some((l) => et.includes(l)) && ne(), se(), R.forEach((l) => l()), !0) : !1;
|
|
280
|
+
}
|
|
281
|
+
function Se(b) {
|
|
282
|
+
_.value = b.state, I.value = b.queries, M.value = b.params, h.value = {};
|
|
283
|
+
for (const C of Object.keys(F)) delete F[C];
|
|
284
|
+
for (const C of Object.keys(Y)) delete Y[C];
|
|
285
|
+
g(b), P = !0, se();
|
|
286
|
+
}
|
|
287
|
+
function xe(b, C = []) {
|
|
288
|
+
_.value = b.state, I.value = b.queries, M.value = b.params;
|
|
289
|
+
const D = JSON.stringify(u.value), q = {};
|
|
290
|
+
for (const s of b.params)
|
|
291
|
+
q[s.name] = s.name in u.value ? u.value[s.name] : s.default ?? null;
|
|
292
|
+
u.value = q;
|
|
293
|
+
const X = new Set(b.queries.map((s) => s.id));
|
|
294
|
+
for (const s of Object.keys(F)) X.has(s) || delete F[s];
|
|
295
|
+
for (const s of Object.keys(Y)) X.has(s) || delete Y[s];
|
|
296
|
+
const l = Object.keys(h.value).filter((s) => !X.has(s));
|
|
297
|
+
if (l.length) {
|
|
298
|
+
const s = { ...h.value };
|
|
299
|
+
for (const W of l) delete s[W];
|
|
300
|
+
h.value = s;
|
|
301
|
+
}
|
|
302
|
+
for (const s of C) delete Y[s];
|
|
303
|
+
return se(), JSON.stringify(u.value) !== D;
|
|
284
304
|
}
|
|
285
305
|
return {
|
|
286
306
|
params: u,
|
|
287
|
-
intent:
|
|
288
|
-
results:
|
|
289
|
-
queries:
|
|
290
|
-
state:
|
|
291
|
-
paramState:
|
|
307
|
+
intent: z,
|
|
308
|
+
results: h,
|
|
309
|
+
queries: I,
|
|
310
|
+
state: _,
|
|
311
|
+
paramState: ve,
|
|
292
312
|
env: ue,
|
|
293
|
-
load:
|
|
294
|
-
bindStore:
|
|
295
|
-
applyCanvas:
|
|
296
|
-
run:
|
|
297
|
-
setParams:
|
|
298
|
-
onResult:
|
|
299
|
-
onParamsChanged:
|
|
300
|
-
RESERVED:
|
|
313
|
+
load: Se,
|
|
314
|
+
bindStore: ee,
|
|
315
|
+
applyCanvas: xe,
|
|
316
|
+
run: se,
|
|
317
|
+
setParams: _e,
|
|
318
|
+
onResult: Q,
|
|
319
|
+
onParamsChanged: m,
|
|
320
|
+
RESERVED: nn
|
|
301
321
|
};
|
|
302
322
|
}
|
|
303
|
-
const fn = `:root{--fm-palette-brand-fm-100:#fff3e6;--fm-palette-brand-fm-200:#ff9455;--fm-palette-brand-fm-300:#ff7823;--fm-palette-brand-fm-400:#b25300;--fm-palette-brand-fm-500:#6b3100;--fm-palette-aqua-100:#b7e2ff;--fm-palette-aqua-300:#3ab0ff;--fm-palette-aqua-500:#0a5384;--fm-palette-berry-100:#fee4dc;--fm-palette-berry-300:#e94850;--fm-palette-berry-500:#5f090a;--fm-palette-blossom-100:#fff7fc;--fm-palette-blossom-300:#ffc4c3;--fm-palette-blossom-500:#8c146a;--fm-palette-lime-100:#f4fde6;--fm-palette-lime-300:#aeef4b;--fm-palette-lime-500:#306a01;--fm-palette-mustard-100:#fef5ea;--fm-palette-mustard-300:#ffc746;--fm-palette-mustard-500:#903e1f;--fm-palette-stone-100:#f6f8fc;--fm-palette-stone-300:#b2b3b6;--fm-palette-stone-500:#2e2e2e;--fm-palette-grape-100:#eddfff;--fm-palette-grape-300:#8f61e8;--fm-palette-grape-500:#512191;--fm-palette-neurastone-0:#fff;--fm-palette-neurastone-100:#f6f6f8;--fm-palette-neurastone-200:#f0f0f0;--fm-palette-neurastone-300:#b2b3b6;--fm-palette-neurastone-400:#6b6c70;--fm-palette-neurastone-500:#4b4b4b;--fm-palette-neurastone-600:#2e2e2e;--fm-palette-neurastone-700:#262628;--fm-palette-neurastone-800:#1c1c1e;--fm-palette-neurastone-900:#121212;--fm-palette-blue-100:#e6f2ff;--fm-palette-blue-200:#66afff;--fm-palette-blue-300:#007aff;--fm-palette-blue-400:#004999;--fm-palette-blue-500:#002c5c;--fm-palette-orange-100:#fff4e6;--fm-palette-orange-200:#ffbf66;--fm-palette-orange-300:#ff9500;--fm-palette-orange-400:#995900;--fm-palette-orange-500:#5c3500;--fm-palette-green-100:#ebf9ee;--fm-palette-green-200:#85dd9b;--fm-palette-green-300:#34c759;--fm-palette-green-400:#1f7735;--fm-palette-green-500:#134720;--fm-palette-red-100:#ffebea;--fm-palette-red-200:#ff8983;--fm-palette-red-300:#ff3b30;--fm-palette-red-400:#99231d;--fm-palette-red-500:#5c1511;--fm-palette-overlay-black-alpha-4:#1212120a;--fm-palette-overlay-black-alpha-8:#12121214;--fm-palette-overlay-black-alpha-12:#1212121f;--fm-palette-overlay-black-alpha-16:#12121229;--fm-palette-overlay-black-alpha-24:#1212123d;--fm-palette-overlay-black-alpha-32:#12121252;--fm-palette-overlay-black-alpha-48:#1212127a;--fm-palette-overlay-black-alpha-64:#121212a3;--fm-palette-overlay-black-alpha-72:#121212b8;--fm-palette-overlay-black-alpha-80:#121212cc;--fm-palette-overlay-white-alpha-4:#ffffff0a;--fm-palette-overlay-white-alpha-8:#ffffff14;--fm-palette-overlay-white-alpha-12:#ffffff1f;--fm-palette-overlay-white-alpha-16:#ffffff29;--fm-palette-overlay-white-alpha-24:#ffffff3d;--fm-palette-overlay-white-alpha-32:#ffffff52;--fm-palette-overlay-white-alpha-48:#ffffff7a;--fm-palette-overlay-white-alpha-64:#ffffffa3;--fm-palette-overlay-white-alpha-72:#ffffffb8;--fm-palette-overlay-white-alpha-80:#fffc;--fm-spacing-0:0;--fm-spacing-1:1px;--fm-spacing-2:2px;--fm-spacing-4:4px;--fm-spacing-6:6px;--fm-spacing-8:8px;--fm-spacing-10:10px;--fm-spacing-12:12px;--fm-spacing-14:14px;--fm-spacing-16:16px;--fm-spacing-18:18px;--fm-spacing-20:20px;--fm-spacing-24:24px;--fm-spacing-28:28px;--fm-spacing-32:32px;--fm-spacing-40:40px;--fm-spacing-48:48px;--fm-spacing-56:56px;--fm-spacing-64:64px;--fm-spacing-72:72px;--fm-spacing-80:80px;--fm-spacing-88:88px;--fm-spacing-96:96px;--fm-spacing-104:104px;--fm-spacing-112:112px;--fm-spacing-120:120px;--fm-spacing-128:128px;--fm-spacing-160:160px;--fm-spacing-192:192px;--fm-radius-none:0;--fm-radius-xs:4px;--fm-radius-sm:8px;--fm-radius-md:12px;--fm-radius-lg:16px;--fm-radius-xl:24px;--fm-radius-2xl:32px;--fm-radius-3xl:64px;--fm-radius-full:99999px;--fm-border-width-none:0;--fm-border-width-hairline:.5px;--fm-border-width-thin:1px;--fm-border-width-regular:1.5px;--fm-border-width-medium:2px;--fm-border-width-thick:4px;--fm-opacity-0:0;--fm-opacity-8:.08;--fm-opacity-12:.12;--fm-opacity-16:.16;--fm-opacity-24:.24;--fm-opacity-32:.32;--fm-opacity-40:.4;--fm-opacity-48:.48;--fm-opacity-56:.56;--fm-opacity-64:.64;--fm-opacity-80:.8;--fm-opacity-100:1;--fm-shadow-blur-none:0;--fm-shadow-blur-xs:2px;--fm-shadow-blur-sm:4px;--fm-shadow-blur-md:6px;--fm-shadow-blur-lg:10px;--fm-shadow-blur-xl:16px;--fm-shadow-blur-2xl:24px;--fm-blur-sm:8px;--fm-blur-md:16px;--fm-blur-lg:24px;--fm-blur-xl:40px;--fm-z-index-base:0;--fm-z-index-raised:100;--fm-z-index-dropdown:200;--fm-z-index-sticky:300;--fm-z-index-overlay:400;--fm-z-index-modal:500;--fm-z-index-toast:600;--fm-z-index-tooltip:700;--fm-duration-instant:0s;--fm-duration-fast:.1s;--fm-duration-normal:.2s;--fm-duration-slow:.3s;--fm-duration-slower:.5s;--fm-easing-standard:cubic-bezier(.4, 0, .2, 1);--fm-easing-decelerate:cubic-bezier(0, 0, .2, 1);--fm-easing-accelerate:cubic-bezier(.4, 0, 1, 1);--fm-easing-spring:cubic-bezier(.34, 1.56, .64, 1);--fm-shadow-color:#1c1c1e;--fm-breakpoint-sm:0;--fm-breakpoint-md:768px;--fm-breakpoint-lg:1024px;--fm-breakpoint-xl:1440px;--fm-breakpoint-xxl:1920px}:root,[data-fm-theme=light]{--fm-bg-canvas:#f6f6f8;--fm-bg-default:#fff;--fm-bg-subtle:#f6f6f8;--fm-bg-muted:#f0f0f0;--fm-bg-elevated:#fff;--fm-bg-inverse:#1c1c1e;--fm-bg-brand:#fff3e6;--fm-bg-success:#ebf9ee;--fm-bg-warning:#fff4e6;--fm-bg-error:#ffebea;--fm-bg-info:#e6f2ff;--fm-surface-default:#fff;--fm-surface-sunken:#f0f0f0;--fm-surface-inset:#b2b3b6;--fm-surface-raised:#fff;--fm-surface-floating:#fff;--fm-text-primary:#1c1c1e;--fm-text-secondary:#4b4b4b;--fm-text-muted:#6b6c70;--fm-text-disabled:#b2b3b6;--fm-text-inverse:#fff;--fm-text-on-inset:#fff;--fm-text-link:#007aff;--fm-text-brand:#ff7823;--fm-text-success:#1f7735;--fm-text-warning:#995900;--fm-text-error:#99231d;--fm-icon-primary:#1c1c1e;--fm-icon-secondary:#4b4b4b;--fm-icon-muted:#6b6c70;--fm-icon-disabled:#b2b3b6;--fm-icon-inverse:#fff;--fm-icon-link:#007aff;--fm-icon-brand:#ff7823;--fm-icon-success:#1f7735;--fm-icon-warning:#995900;--fm-icon-error:#99231d;--fm-icon-info:#004999;--fm-icon-on-brand:#b25300;--fm-icon-on-success:#1f7735;--fm-icon-on-warning:#995900;--fm-icon-on-error:#99231d;--fm-icon-on-info:#004999;--fm-text-info:#004999;--fm-border-default:#f0f0f0;--fm-border-subtle:#f6f6f8;--fm-border-medium:#b2b3b6;--fm-border-strong:#6b6c70;--fm-border-inverse:#fff;--fm-border-brand:#ff7823;--fm-border-success:#1f7735;--fm-border-warning:#995900;--fm-border-error:#99231d;--fm-border-info:#004999;--fm-overlay-scrim-1:#12121252;--fm-overlay-scrim-2:#1212127a;--fm-overlay-scrim-3:#121212a3;--fm-overlay-scrim-4:#121212b8;--fm-action-primary-bg:#ff7823;--fm-feature-aqua-bg:#b7e2ff;--fm-feature-aqua-accent:#3ab0ff;--fm-feature-aqua-fg:#0a5384;--fm-feature-berry-bg:#fee4dc;--fm-feature-berry-accent:#e94850;--fm-feature-berry-fg:#5f090a;--fm-feature-blossom-bg:#fff7fc;--fm-feature-blossom-accent:#ffc4c3;--fm-feature-blossom-fg:#8c146a;--fm-feature-lime-bg:#f4fde6;--fm-feature-lime-accent:#aeef4b;--fm-feature-lime-fg:#306a01;--fm-feature-mustard-bg:#fef5ea;--fm-feature-mustard-accent:#ffc746;--fm-feature-mustard-fg:#903e1f;--fm-feature-stone-bg:#f6f8fc;--fm-feature-stone-accent:#b2b3b6;--fm-feature-stone-fg:#2e2e2e;--fm-feature-grape-bg:#eddfff;--fm-feature-grape-accent:#8f61e8;--fm-feature-grape-fg:#512191;--fm-state-subtle:#1212120a;--fm-state-hover:#12121214;--fm-state-pressed:#1212121f;--fm-state-selected:#12121229;--fm-state-dragged:#1212123d;--fm-action-primary-bg-hover:#b25300;--fm-action-primary-bg-subtle:#fff3e6;--fm-action-primary-fg:#1c1c1e;--fm-action-secondary-bg:#fff;--fm-action-secondary-bg-hover:#f6f6f8;--fm-action-secondary-fg:#1c1c1e;--fm-action-ghost-bg-hover:#f6f6f8;--fm-action-ghost-bg-active:#f0f0f0;--fm-action-danger-bg:#ff3b30;--fm-action-danger-bg-hover:#99231d;--fm-action-danger-bg-subtle:#ffebea;--fm-action-danger-fg:#1c1c1e;--fm-action-disabled-bg:#f0f0f0;--fm-action-disabled-fg:#6b6c70;--fm-text-on-brand:#b25300;--fm-text-on-success:#1f7735;--fm-text-on-warning:#995900;--fm-text-on-error:#99231d;--fm-text-on-info:#004999;--fm-badge-bg-aqua:#b7e2ff;--fm-badge-text-on-aqua:#0a5384;--fm-badge-icon-on-aqua:#0a5384;--fm-badge-border-aqua:#0a5384;--fm-badge-bg-berry:#fee4dc;--fm-badge-bg-blossom:#fff7fc;--fm-badge-bg-lime:#f4fde6;--fm-badge-bg-mustard:#fef5ea;--fm-badge-bg-stone:#f6f8fc;--fm-badge-bg-grape:#eddfff;--fm-badge-border-blossom:#8c146a;--fm-badge-text-on-blossom:#8c146a;--fm-badge-icon-on-blossom:#8c146a;--fm-badge-border-berry:#5f090a;--fm-badge-text-on-berry:#5f090a;--fm-badge-icon-on-berry:#5f090a;--fm-badge-border-lime:#306a01;--fm-badge-text-on-lime:#306a01;--fm-badge-icon-on-lime:#306a01;--fm-badge-border-mustard:#903e1f;--fm-badge-text-on-mustard:#903e1f;--fm-badge-icon-on-mustard:#903e1f;--fm-badge-border-stone:#2e2e2e;--fm-badge-text-on-stone:#2e2e2e;--fm-badge-icon-on-stone:#2e2e2e;--fm-badge-border-grape:#512191;--fm-badge-text-on-grape:#512191;--fm-badge-icon-on-grape:#512191;--fm-badge-bg-brand:#fff3e6;--fm-badge-border-brand:#ff7823;--fm-badge-text-on-brand:#ff7823;--fm-badge-icon-on-brand:#ff7823}[data-fm-theme=dark]{--fm-bg-canvas:#121212;--fm-bg-default:#1c1c1e;--fm-bg-subtle:#262628;--fm-bg-muted:#2e2e2e;--fm-bg-elevated:#262628;--fm-bg-inverse:#fff;--fm-bg-brand:#b25300;--fm-bg-success:#1f7735;--fm-bg-warning:#995900;--fm-bg-error:#99231d;--fm-bg-info:#004999;--fm-surface-default:#262628;--fm-surface-sunken:#121212;--fm-surface-inset:#1c1c1e;--fm-surface-raised:#2e2e2e;--fm-surface-floating:#4b4b4b;--fm-text-primary:#fff;--fm-text-secondary:#b2b3b6;--fm-text-muted:#6b6c70;--fm-text-disabled:#4b4b4b;--fm-text-inverse:#1c1c1e;--fm-text-on-inset:#fff;--fm-text-link:#66afff;--fm-text-brand:#fff3e6;--fm-text-success:#85dd9b;--fm-text-warning:#ffbf66;--fm-text-error:#ff8983;--fm-icon-primary:#fff;--fm-icon-secondary:#b2b3b6;--fm-icon-muted:#6b6c70;--fm-icon-disabled:#4b4b4b;--fm-icon-inverse:#1c1c1e;--fm-icon-link:#66afff;--fm-icon-brand:#fff3e6;--fm-icon-success:#85dd9b;--fm-icon-warning:#ffbf66;--fm-icon-error:#ff8983;--fm-icon-info:#66afff;--fm-icon-on-brand:#fff3e6;--fm-icon-on-success:#ebf9ee;--fm-icon-on-warning:#fff4e6;--fm-icon-on-error:#ffebea;--fm-icon-on-info:#e6f2ff;--fm-text-info:#66afff;--fm-border-default:#2e2e2e;--fm-border-subtle:#262628;--fm-border-medium:#b2b3b6;--fm-border-strong:#f6f6f8;--fm-border-inverse:#1c1c1e;--fm-border-brand:#fff3e6;--fm-border-success:#85dd9b;--fm-border-warning:#ffbf66;--fm-border-error:#ff8983;--fm-border-info:#66afff;--fm-overlay-scrim-1:#1212127a;--fm-overlay-scrim-2:#121212a3;--fm-overlay-scrim-3:#121212b8;--fm-overlay-scrim-4:#121212cc;--fm-action-primary-bg:#ff7823;--fm-feature-aqua-bg:#0a5384;--fm-feature-aqua-accent:#3ab0ff;--fm-feature-aqua-fg:#b7e2ff;--fm-feature-berry-bg:#5f090a;--fm-feature-berry-accent:#e94850;--fm-feature-berry-fg:#fee4dc;--fm-feature-blossom-bg:#8c146a;--fm-feature-blossom-accent:#ffc4c3;--fm-feature-blossom-fg:#fff7fc;--fm-feature-lime-bg:#306a01;--fm-feature-lime-accent:#aeef4b;--fm-feature-lime-fg:#f4fde6;--fm-feature-mustard-bg:#903e1f;--fm-feature-mustard-accent:#ffc746;--fm-feature-mustard-fg:#fef5ea;--fm-feature-stone-bg:#2e2e2e;--fm-feature-stone-accent:#b2b3b6;--fm-feature-stone-fg:#f6f8fc;--fm-feature-grape-bg:#512191;--fm-feature-grape-accent:#8f61e8;--fm-feature-grape-fg:#eddfff;--fm-state-subtle:#ffffff0a;--fm-state-hover:#ffffff14;--fm-state-pressed:#ffffff1f;--fm-state-selected:#ffffff29;--fm-state-dragged:#ffffff3d;--fm-action-primary-bg-hover:#b25300;--fm-action-primary-bg-subtle:#6b3100;--fm-action-primary-fg:#1c1c1e;--fm-action-secondary-bg:#262628;--fm-action-secondary-bg-hover:#2e2e2e;--fm-action-secondary-fg:#fff;--fm-action-ghost-bg-hover:#262628;--fm-action-ghost-bg-active:#2e2e2e;--fm-action-danger-bg:#ff3b30;--fm-action-danger-bg-hover:#99231d;--fm-action-danger-bg-subtle:#5c1511;--fm-action-danger-fg:#1c1c1e;--fm-action-disabled-bg:#2e2e2e;--fm-action-disabled-fg:#6b6c70;--fm-text-on-brand:#fff3e6;--fm-text-on-success:#ebf9ee;--fm-text-on-warning:#fff4e6;--fm-text-on-error:#ffebea;--fm-text-on-info:#e6f2ff;--fm-badge-bg-aqua:#0a5384;--fm-badge-text-on-aqua:#b7e2ff;--fm-badge-icon-on-aqua:#b7e2ff;--fm-badge-border-aqua:#3ab0ff;--fm-badge-bg-berry:#5f090a;--fm-badge-bg-blossom:#8c146a;--fm-badge-bg-lime:#306a01;--fm-badge-bg-mustard:#903e1f;--fm-badge-bg-stone:#2e2e2e;--fm-badge-bg-grape:#512191;--fm-badge-border-blossom:#ffc4c3;--fm-badge-text-on-blossom:#fff7fc;--fm-badge-icon-on-blossom:#fff7fc;--fm-badge-border-berry:#e94850;--fm-badge-text-on-berry:#fee4dc;--fm-badge-icon-on-berry:#fee4dc;--fm-badge-border-lime:#aeef4b;--fm-badge-text-on-lime:#f4fde6;--fm-badge-icon-on-lime:#f4fde6;--fm-badge-border-mustard:#ffc746;--fm-badge-text-on-mustard:#fef5ea;--fm-badge-icon-on-mustard:#fef5ea;--fm-badge-border-stone:#b2b3b6;--fm-badge-text-on-stone:#f6f8fc;--fm-badge-icon-on-stone:#f6f8fc;--fm-badge-border-grape:#8f61e8;--fm-badge-text-on-grape:#eddfff;--fm-badge-icon-on-grape:#eddfff;--fm-badge-bg-brand:#6b3100;--fm-badge-border-brand:#ff7823;--fm-badge-text-on-brand:#fff3e6;--fm-badge-icon-on-brand:#fff3e6}:root{--fm-font-size-8:8px;--fm-font-size-10:10px;--fm-font-size-12:12px;--fm-font-size-14:14px;--fm-font-size-16:16px;--fm-font-size-18:18px;--fm-font-size-22:22px;--fm-font-size-26:26px;--fm-font-size-32:32px;--fm-font-size-36:36px;--fm-font-size-48:48px;--fm-font-size-60:60px;--fm-font-size-72:72px;--fm-font-family-heading:"Cabinet Grotesk";--fm-font-family-body:"Inter";--fm-font-weight-regular:400;--fm-font-weight-medium:500;--fm-font-weight-semi-bold:600;--fm-font-weight-extra-bold:800;--fm-font-weight-black:900;--fm-line-height-8:12px;--fm-line-height-10:14px;--fm-line-height-12:16px;--fm-line-height-14:20px;--fm-line-height-16:24px;--fm-line-height-18:26px;--fm-line-height-22:30px;--fm-line-height-26:36px;--fm-line-height-32:40px;--fm-line-height-36:44px;--fm-line-height-48:56px;--fm-line-height-60:72px;--fm-line-height-72:80px}:root:lang(zh),[lang=zh]{--fm-font-family-heading:"Noto Sans SC";--fm-font-family-body:"Noto Sans SC";--fm-font-weight-regular:400;--fm-font-weight-medium:500;--fm-font-weight-semi-bold:600;--fm-font-weight-extra-bold:800;--fm-font-weight-black:900;--fm-line-height-8:12px;--fm-line-height-10:14px;--fm-line-height-12:18px;--fm-line-height-14:20px;--fm-line-height-16:26px;--fm-line-height-18:26px;--fm-line-height-22:30px;--fm-line-height-26:36px;--fm-line-height-32:44px;--fm-line-height-36:46px;--fm-line-height-48:60px;--fm-line-height-60:76px;--fm-line-height-72:90px}:root:lang(th),[lang=th]{--fm-font-family-heading:"Noto Sans Thai";--fm-font-family-body:"Noto Sans Thai";--fm-font-weight-regular:400;--fm-font-weight-medium:500;--fm-font-weight-semi-bold:600;--fm-font-weight-extra-bold:800;--fm-font-weight-black:900;--fm-line-height-8:14px;--fm-line-height-10:16px;--fm-line-height-12:20px;--fm-line-height-14:24px;--fm-line-height-16:28px;--fm-line-height-18:28px;--fm-line-height-22:32px;--fm-line-height-26:38px;--fm-line-height-32:46px;--fm-line-height-36:50px;--fm-line-height-48:64px;--fm-line-height-60:80px;--fm-line-height-72:96px}.fm-text-display-xl{letter-spacing:.015em;font-family:Cabinet Grotesk,sans-serif;font-size:72px;font-weight:900;line-height:80px}.fm-text-display-lg{letter-spacing:.015em;font-family:Cabinet Grotesk,sans-serif;font-size:60px;font-weight:900;line-height:72px}.fm-text-display-md{letter-spacing:.015em;font-family:Cabinet Grotesk,sans-serif;font-size:48px;font-weight:900;line-height:56px}.fm-text-display-sm{letter-spacing:.015em;font-family:Cabinet Grotesk,sans-serif;font-size:36px;font-weight:900;line-height:44px}.fm-text-title-xl{letter-spacing:.01em;font-family:Cabinet Grotesk,sans-serif;font-size:32px;font-weight:800;line-height:40px}.fm-text-title-lg{letter-spacing:.01em;font-family:Cabinet Grotesk,sans-serif;font-size:26px;font-weight:800;line-height:36px}.fm-text-title-md{letter-spacing:.01em;font-family:Cabinet Grotesk,sans-serif;font-size:22px;font-weight:800;line-height:30px}.fm-text-title-sm{letter-spacing:.01em;font-family:Cabinet Grotesk,sans-serif;font-size:18px;font-weight:800;line-height:26px}.fm-text-body-lg-600{letter-spacing:.0025em;font-family:Inter,sans-serif;font-size:16px;font-weight:600;line-height:24px}.fm-text-body-md-600{letter-spacing:.01em;font-family:Inter,sans-serif;font-size:14px;font-weight:600;line-height:20px}.fm-text-body-sm-600{letter-spacing:.02em;font-family:Inter,sans-serif;font-size:12px;font-weight:600;line-height:16px}.fm-text-body-xs-600{letter-spacing:.02em;font-family:Inter,sans-serif;font-size:10px;font-weight:600;line-height:14px}.fm-text-body-overline-xs-600{letter-spacing:.1em;font-family:Inter,sans-serif;font-size:10px;font-weight:600;line-height:14px}.fm-text-body-overline-2xs-600{letter-spacing:.1em;font-family:Inter,sans-serif;font-size:8px;font-weight:600;line-height:12px}.fm-text-body-lg-500{letter-spacing:.0025em;font-family:Inter,sans-serif;font-size:16px;font-weight:500;line-height:24px}.fm-text-body-md-500{letter-spacing:.01em;font-family:Inter,sans-serif;font-size:14px;font-weight:500;line-height:20px}.fm-text-body-sm-500{letter-spacing:.02em;font-family:Inter,sans-serif;font-size:12px;font-weight:500;line-height:16px}.fm-text-body-xs-500{letter-spacing:.02em;font-family:Inter,sans-serif;font-size:10px;font-weight:500;line-height:14px}.fm-text-body-lg-400{letter-spacing:.0025em;font-family:Inter,sans-serif;font-size:16px;font-weight:400;line-height:24px}.fm-text-body-md-400{letter-spacing:.01em;font-family:Inter,sans-serif;font-size:14px;font-weight:400;line-height:20px}.fm-text-body-sm-400{letter-spacing:.02em;font-family:Inter,sans-serif;font-size:12px;font-weight:400;line-height:16px}.fm-text-body-xs-400{letter-spacing:.02em;font-family:Inter,sans-serif;font-size:10px;font-weight:400;line-height:14px}:root{--fm-shadow-light-xs:0 1px 2px 0 #1c1c1e0a;--fm-shadow-light-sm:0 2px 4px 0 #1c1c1e0f;--fm-shadow-light-md:0 4px 6px 0 #1c1c1e14;--fm-shadow-light-lg:0 6px 10px 0 #1c1c1e1a;--fm-shadow-light-xl:0 8px 16px 0 #1c1c1e1f;--fm-shadow-light-2xl:0 12px 24px 0 #1c1c1e24;--fm-shadow-light-top-sm:0 -2px 4px 0 #1c1c1e0f;--fm-shadow-light-top-md:0 -4px 6px 0 #1c1c1e14;--fm-shadow-light-side-left-md:-4px 0 6px 0 #1c1c1e14;--fm-shadow-light-side-right-md:4px 0 6px 0 #1c1c1e14;--fm-shadow-light-text-sm:0 1px 1px 0 #1c1c1e0d;--fm-shadow-light-text-md:0 1px 2px 0 #1c1c1e1a;--fm-shadow-light-text-lg:0 2px 4px 0 #1c1c1e26;--fm-shadow-light-text-xl:0 3px 6px 0 #1c1c1e33;--fm-shadow-dark-xs:0 1px 2px 0 #ffffff0a;--fm-shadow-dark-sm:0 2px 4px 0 #ffffff0f;--fm-shadow-dark-md:0 4px 6px 0 #ffffff14;--fm-shadow-dark-lg:0 6px 10px 0 #ffffff1a;--fm-shadow-dark-xl:0 8px 16px 0 #ffffff1f;--fm-shadow-dark-2xl:0 12px 24px 0 #ffffff24;--fm-shadow-dark-top-sm:0 -2px 4px 0 #ffffff0f;--fm-shadow-dark-top-md:0 -4px 6px 0 #ffffff14;--fm-shadow-dark-side-left-md:-4px 0 6px 0 #ffffff14;--fm-shadow-dark-side-right-md:4px 0 6px 0 #ffffff14;--fm-shadow-dark-text-sm:0 1px 1px 0 #ffffff0d;--fm-shadow-dark-text-md:0 1px 2px 0 #ffffff1a;--fm-shadow-dark-text-lg:0 2px 4px 0 #ffffff26;--fm-shadow-dark-text-xl:0 3px 6px 0 #fff3;--fm-outer-shadow-light-brand:0 0 0 4px #ff782352;--fm-outer-shadow-light-error:0 0 0 4px #ff3b3052;--fm-outer-shadow-dark-brand:0 0 0 4px #ff782366;--fm-outer-shadow-dark-error:0 0 0 4px #ff3b3066;--fm-inner-shadow-light-sm:inset 0 1px 2px 0 #1c1c1e0f;--fm-inner-shadow-light-md:inset 0 2px 4px 0 #1c1c1e1a;--fm-inner-shadow-light-brand:0 2px 4px 0 #1c1c1e14, inset 0 0 0 1.25px #1c1c1e1f;--fm-inner-shadow-dark-sm:inset 0 1px 2px 0 #ffffff0f;--fm-inner-shadow-dark-md:inset 0 2px 4px 0 #ffffff1a;--fm-inner-shadow-dark-brand:0 2px 4px 0 #ffffff14, inset 0 0 0 1.25px #ffffff1f;--fm-blur-sm:8px;--fm-blur-md:16px;--fm-blur-lg:24px;--fm-blur-xl:40px}:root,[data-fm-theme=light]{--fm-shadow-xs:var(--fm-shadow-light-xs);--fm-shadow-sm:var(--fm-shadow-light-sm);--fm-shadow-md:var(--fm-shadow-light-md);--fm-shadow-lg:var(--fm-shadow-light-lg);--fm-shadow-xl:var(--fm-shadow-light-xl);--fm-shadow-2xl:var(--fm-shadow-light-2xl);--fm-shadow-top-sm:var(--fm-shadow-light-top-sm);--fm-shadow-top-md:var(--fm-shadow-light-top-md);--fm-shadow-side-left-md:var(--fm-shadow-light-side-left-md);--fm-shadow-side-right-md:var(--fm-shadow-light-side-right-md);--fm-shadow-text-sm:var(--fm-shadow-light-text-sm);--fm-shadow-text-md:var(--fm-shadow-light-text-md);--fm-shadow-text-lg:var(--fm-shadow-light-text-lg);--fm-shadow-text-xl:var(--fm-shadow-light-text-xl);--fm-outer-shadow-brand:var(--fm-outer-shadow-light-brand);--fm-outer-shadow-error:var(--fm-outer-shadow-light-error);--fm-inner-shadow-sm:var(--fm-inner-shadow-light-sm);--fm-inner-shadow-md:var(--fm-inner-shadow-light-md);--fm-inner-shadow-brand:var(--fm-inner-shadow-light-brand)}[data-fm-theme=dark]{--fm-shadow-xs:var(--fm-shadow-dark-xs);--fm-shadow-sm:var(--fm-shadow-dark-sm);--fm-shadow-md:var(--fm-shadow-dark-md);--fm-shadow-lg:var(--fm-shadow-dark-lg);--fm-shadow-xl:var(--fm-shadow-dark-xl);--fm-shadow-2xl:var(--fm-shadow-dark-2xl);--fm-shadow-top-sm:var(--fm-shadow-dark-top-sm);--fm-shadow-top-md:var(--fm-shadow-dark-top-md);--fm-shadow-side-left-md:var(--fm-shadow-dark-side-left-md);--fm-shadow-side-right-md:var(--fm-shadow-dark-side-right-md);--fm-shadow-text-sm:var(--fm-shadow-dark-text-sm);--fm-shadow-text-md:var(--fm-shadow-dark-text-md);--fm-shadow-text-lg:var(--fm-shadow-dark-text-lg);--fm-shadow-text-xl:var(--fm-shadow-dark-text-xl);--fm-outer-shadow-brand:var(--fm-outer-shadow-dark-brand);--fm-outer-shadow-error:var(--fm-outer-shadow-dark-error);--fm-inner-shadow-sm:var(--fm-inner-shadow-dark-sm);--fm-inner-shadow-md:var(--fm-inner-shadow-dark-md);--fm-inner-shadow-brand:var(--fm-inner-shadow-dark-brand)}[data-fm-theme]{color:var(--fm-text-primary)}.fm-icon{width:var(--fm-icon-size,24px);height:var(--fm-icon-size,24px);font-size:var(--fm-icon-size,24px);vertical-align:middle;-webkit-user-select:none;user-select:none;flex:none;justify-content:center;align-items:center;line-height:1;display:inline-flex}.fm-icon__svg{fill:none;width:100%;height:100%;display:block}.fm-icon--rounded,.fm-icon--outlined{text-transform:none;letter-spacing:normal;word-wrap:normal;white-space:nowrap;font-feature-settings:"liga";-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:antialiased;text-rendering:optimizelegibility;direction:ltr;font-style:normal;font-weight:400}.fm-icon--rounded{font-family:Material Symbols Filled}.fm-icon--outlined{font-family:Material Symbols Outlined}.fm-alert{--fm-alert-surface:var(--fm-bg-inverse);--fm-alert-fg:var(--fm-text-inverse);--fm-alert-icon:var(--fm-icon-inverse);--fm-alert-progress:var(--fm-bg-default);--fm-alert-pad-x:var(--fm-spacing-16);--fm-alert-pad-y:var(--fm-spacing-12);box-sizing:border-box;border-radius:var(--fm-radius-lg);background-color:var(--fm-alert-surface);color:var(--fm-alert-fg);box-shadow:var(--fm-shadow-sm);flex-direction:column;display:flex;overflow:hidden}@media (width>=768px){.fm-alert{--fm-alert-pad-x:var(--fm-spacing-24);--fm-alert-pad-y:var(--fm-spacing-16)}}.fm-alert__body{align-items:center;gap:var(--fm-spacing-12);padding:var(--fm-alert-pad-y) var(--fm-alert-pad-x);display:flex}.fm-alert__icon{--fm-icon-size:32px;width:32px;height:32px;color:var(--fm-alert-icon);flex:none;justify-content:center;align-items:center;display:inline-flex}.fm-alert__danger-mark{width:var(--fm-spacing-24);height:var(--fm-spacing-24);border-radius:var(--fm-radius-full);background-color:var(--fm-alert-icon);justify-content:center;align-items:center;display:inline-flex}.fm-alert__danger-bar{width:var(--fm-spacing-12);height:var(--fm-border-width-medium);border-radius:var(--fm-radius-full);background-color:var(--fm-icon-inverse)}.fm-alert__text{flex-direction:column;flex:auto;min-width:0;display:flex}.fm-alert__close{--fm-icon-size:var(--fm-spacing-20);width:var(--fm-spacing-40);height:var(--fm-spacing-40);border-radius:var(--fm-radius-sm);color:var(--fm-alert-fg);cursor:pointer;background:0 0;border:none;flex:none;justify-content:center;align-items:center;padding:0;display:inline-flex}.fm-alert__progress{border-radius:var(--fm-radius-full);background-color:var(--fm-alert-progress);height:2px}.fm-alert__progress--animated{transform-origin:0;animation:fm-alert-drain var(--fm-alert-duration,3s) linear forwards}@keyframes fm-alert-drain{0%{transform:scaleX(1)}to{transform:scaleX(0)}}.fm-alert--info{--fm-alert-surface:var(--fm-bg-info);--fm-alert-fg:var(--fm-text-on-info);--fm-alert-icon:var(--fm-icon-on-info);--fm-alert-progress:var(--fm-icon-on-info)}.fm-alert--success{--fm-alert-surface:var(--fm-bg-success);--fm-alert-fg:var(--fm-text-on-success);--fm-alert-icon:var(--fm-icon-on-success);--fm-alert-progress:var(--fm-icon-on-success)}.fm-alert--warning{--fm-alert-surface:var(--fm-bg-warning);--fm-alert-fg:var(--fm-text-on-warning);--fm-alert-icon:var(--fm-icon-on-warning);--fm-alert-progress:var(--fm-icon-on-warning)}.fm-alert--danger{--fm-alert-surface:var(--fm-bg-error);--fm-alert-fg:var(--fm-text-on-error);--fm-alert-icon:var(--fm-icon-on-error);--fm-alert-progress:var(--fm-icon-on-error)}.fm-badge{--fm-badge-gap:var(--fm-spacing-2);justify-content:center;align-items:center;gap:var(--fm-badge-gap);box-sizing:border-box;border-radius:var(--fm-radius-xs);background-color:var(--fm-badge-surface);color:var(--fm-badge-fg);padding:var(--fm-badge-pad-y) var(--fm-badge-pad-x);-webkit-user-select:none;user-select:none;display:inline-flex}.fm-badge__label{text-overflow:ellipsis;white-space:nowrap;text-align:center;min-width:0;overflow:hidden}.fm-badge__icon{color:var(--fm-badge-icon,var(--fm-badge-fg));flex:none;display:inline-flex}.fm-badge--sm{--fm-badge-pad-x:var(--fm-spacing-4);--fm-badge-pad-y:var(--fm-spacing-2);--fm-badge-count-size:16px}.fm-badge--md{--fm-badge-pad-x:var(--fm-spacing-6);--fm-badge-pad-y:var(--fm-spacing-4);--fm-badge-count-size:24px}.fm-badge--lg{--fm-badge-pad-x:var(--fm-spacing-8);--fm-badge-pad-y:var(--fm-spacing-4);--fm-badge-count-size:32px}.fm-badge--filled{--fm-badge-surface:var(--fm-badge-bg)}.fm-badge--outlined{--fm-badge-surface:transparent;box-shadow:inset 0 0 0 var(--fm-border-width-thin) var(--fm-badge-border)}.fm-badge--count{--fm-badge-surface:var(--fm-action-primary-bg-subtle);--fm-badge-fg:var(--fm-text-brand);width:var(--fm-badge-count-size);height:var(--fm-badge-count-size);border-radius:calc(var(--fm-badge-count-size) / 2);padding:0}.fm-badge__count{line-height:1}.fm-badge--count-overflow{width:auto;min-width:var(--fm-badge-count-size);padding:0 calc(var(--fm-badge-count-size) * .375)}.fm-badge--brand{--fm-badge-bg:var(--fm-badge-bg-brand);--fm-badge-fg:var(--fm-badge-text-on-brand);--fm-badge-icon:var(--fm-badge-icon-on-brand);--fm-badge-border:var(--fm-badge-border-brand)}.fm-badge--info{--fm-badge-bg:var(--fm-bg-info);--fm-badge-fg:var(--fm-text-on-info);--fm-badge-icon:var(--fm-text-on-info);--fm-badge-border:var(--fm-border-info)}.fm-badge--success{--fm-badge-bg:var(--fm-bg-success);--fm-badge-fg:var(--fm-text-on-success);--fm-badge-icon:var(--fm-text-on-success);--fm-badge-border:var(--fm-border-success)}.fm-badge--warning{--fm-badge-bg:var(--fm-bg-warning);--fm-badge-fg:var(--fm-text-on-warning);--fm-badge-icon:var(--fm-text-on-warning);--fm-badge-border:var(--fm-border-warning)}.fm-badge--error{--fm-badge-bg:var(--fm-bg-error);--fm-badge-fg:var(--fm-text-on-error);--fm-badge-icon:var(--fm-text-on-error);--fm-badge-border:var(--fm-border-error)}.fm-badge--aqua{--fm-badge-bg:var(--fm-badge-bg-aqua);--fm-badge-fg:var(--fm-badge-text-on-aqua);--fm-badge-icon:var(--fm-badge-icon-on-aqua);--fm-badge-border:var(--fm-badge-border-aqua)}.fm-badge--berry{--fm-badge-bg:var(--fm-badge-bg-berry);--fm-badge-fg:var(--fm-badge-text-on-berry);--fm-badge-icon:var(--fm-badge-icon-on-berry);--fm-badge-border:var(--fm-badge-border-berry)}.fm-badge--blossom{--fm-badge-bg:var(--fm-badge-bg-blossom);--fm-badge-fg:var(--fm-badge-text-on-blossom);--fm-badge-icon:var(--fm-badge-icon-on-blossom);--fm-badge-border:var(--fm-badge-border-blossom)}.fm-badge--lime{--fm-badge-bg:var(--fm-badge-bg-lime);--fm-badge-fg:var(--fm-badge-text-on-lime);--fm-badge-icon:var(--fm-badge-icon-on-lime);--fm-badge-border:var(--fm-badge-border-lime)}.fm-badge--mustard{--fm-badge-bg:var(--fm-badge-bg-mustard);--fm-badge-fg:var(--fm-badge-text-on-mustard);--fm-badge-icon:var(--fm-badge-icon-on-mustard);--fm-badge-border:var(--fm-badge-border-mustard)}.fm-badge--stone{--fm-badge-bg:var(--fm-badge-bg-stone);--fm-badge-fg:var(--fm-badge-text-on-stone);--fm-badge-icon:var(--fm-badge-icon-on-stone);--fm-badge-border:var(--fm-badge-border-stone)}.fm-badge--grape{--fm-badge-bg:var(--fm-badge-bg-grape);--fm-badge-fg:var(--fm-badge-text-on-grape);--fm-badge-icon:var(--fm-badge-icon-on-grape);--fm-badge-border:var(--fm-badge-border-grape)}.fm-badge-anchor{align-items:center;gap:var(--fm-spacing-8);-webkit-user-select:none;user-select:none;display:inline-flex;position:relative}.fm-badge--overlay{--fm-badge-surface:var(--fm-text-primary);--fm-badge-fg:var(--fm-text-inverse);border-radius:var(--fm-radius-full);padding:0}.fm-badge--overlay-pinned{position:absolute;top:-2px;right:-4px}.fm-badge--overlay:not(.fm-badge--dot){min-width:16px;height:16px;padding:0 var(--fm-spacing-4)}.fm-badge--dot{width:6px;min-width:0;height:6px;padding:0}.fm-badge--overlay-pinned.fm-badge--dot{top:0;right:0}.fm-badge--v1-info{--fm-badge-surface:var(--fm-feature-aqua-accent);--fm-badge-fg:var(--fm-text-inverse)}.fm-badge--v1-success{--fm-badge-surface:var(--fm-feature-lime-accent);--fm-badge-fg:var(--fm-text-inverse)}.fm-badge--v1-warning{--fm-badge-surface:var(--fm-feature-mustard-accent);--fm-badge-fg:var(--fm-text-primary)}.fm-badge--v1-critical{--fm-badge-surface:var(--fm-feature-berry-accent);--fm-badge-fg:var(--fm-text-inverse)}.fm-badge--v1-neutral{--fm-badge-surface:var(--fm-text-primary);--fm-badge-fg:var(--fm-text-inverse)}.fm-badge--v1-numeric{--fm-badge-surface:var(--fm-text-error);--fm-badge-fg:var(--fm-text-inverse)}.fm-button{--fm-button-height:44px;--fm-button-padding-x:var(--fm-spacing-16);--fm-button-gap:var(--fm-spacing-8);--fm-button-icon-size:var(--fm-spacing-20);--fm-button-radius:var(--fm-radius-sm);--fm-button-border-width:var(--fm-border-width-none);--fm-button-border-color:transparent;--fm-button-bg:transparent;--fm-button-bg-hover:var(--fm-button-bg);--fm-button-bg-active:var(--fm-button-bg-hover);--fm-button-fg:var(--fm-text-primary);--fm-button-effects:0 0 #0000;--fm-button-effects-pressed:var(--fm-button-effects);--fm-button-glow:0 0 #0000;--fm-button-focus-ring:0 0 #0000;box-sizing:border-box;justify-content:center;align-items:center;gap:var(--fm-button-gap);height:var(--fm-button-height);padding:0 var(--fm-button-padding-x);border:var(--fm-button-border-width) solid var(--fm-button-border-color);border-radius:var(--fm-button-radius);background-color:var(--fm-button-bg);color:var(--fm-button-fg);box-shadow:var(--fm-button-focus-ring), var(--fm-button-effects);font-family:var(--fm-font-family-body), sans-serif;font-size:var(--fm-font-size-14);font-weight:var(--fm-font-weight-semi-bold);line-height:var(--fm-line-height-14);letter-spacing:.01em;text-align:center;cursor:pointer;-webkit-user-select:none;user-select:none;appearance:none;-webkit-tap-highlight-color:transparent;background-image:none;text-decoration:none;display:inline-flex}.fm-button:focus{outline:none}.fm-button--xs{--fm-button-height:32px}.fm-button--sm{--fm-button-height:40px}.fm-button--md{--fm-button-height:44px}.fm-button--lg{--fm-button-height:52px}@media (width>=768px){.fm-button--xs{--fm-button-height:28px}.fm-button--sm{--fm-button-height:36px}.fm-button--md{--fm-button-height:40px}.fm-button--lg{--fm-button-height:48px}.fm-button:not(.fm-button--xs){font-size:var(--fm-font-size-16);line-height:var(--fm-line-height-16);letter-spacing:.0025em}}@media (width>=1024px){.fm-button--xs{--fm-button-height:24px}.fm-button--sm{--fm-button-height:32px}.fm-button--md{--fm-button-height:36px}.fm-button--lg{--fm-button-height:44px}}.fm-button--primary{--fm-button-bg:var(--fm-action-primary-bg);--fm-button-bg-hover:var(--fm-action-primary-bg-hover);--fm-button-fg:var(--fm-text-inverse);--fm-button-effects:var(--fm-inner-shadow-brand);--fm-button-glow:var(--fm-outer-shadow-brand)}.fm-button--secondary{--fm-button-bg:var(--fm-action-secondary-bg);--fm-button-bg-hover:var(--fm-action-secondary-bg-hover);--fm-button-fg:var(--fm-text-primary);--fm-button-effects:var(--fm-inner-shadow-brand);--fm-button-effects-pressed:0 0 #0000;--fm-button-glow:var(--fm-outer-shadow-brand)}.fm-button--danger{--fm-button-bg:var(--fm-action-danger-bg);--fm-button-bg-hover:var(--fm-action-danger-bg-hover);--fm-button-fg:var(--fm-text-inverse);--fm-button-effects:var(--fm-inner-shadow-brand);--fm-button-glow:var(--fm-outer-shadow-error)}.fm-button--ghost{--fm-button-bg:transparent;--fm-button-bg-hover:var(--fm-action-ghost-bg-hover);--fm-button-bg-active:var(--fm-action-ghost-bg-active);--fm-button-fg:var(--fm-text-primary);--fm-button-glow:var(--fm-outer-shadow-brand)}.fm-button--legacy-plain{--fm-button-fg:var(--fm-text-brand)}.fm-button--legacy-fab{--fm-button-height:var(--fm-spacing-56);--fm-button-radius:var(--fm-radius-full);min-width:var(--fm-spacing-56);padding:0 var(--fm-spacing-16)}.fm-button:enabled:hover{background-color:var(--fm-button-bg-hover)}.fm-button:enabled:focus-visible{background-color:var(--fm-button-bg-hover);box-shadow:var(--fm-button-focus-ring), var(--fm-button-effects), var(--fm-button-glow)}.fm-button--secondary:enabled:focus-visible{--fm-button-focus-ring:inset 0 0 0 1px var(--fm-border-brand)}.fm-button:enabled:active{background-color:var(--fm-button-bg-active);background-image:linear-gradient(var(--fm-state-pressed), var(--fm-state-pressed));box-shadow:var(--fm-button-focus-ring), var(--fm-button-effects-pressed), var(--fm-button-glow)}.fm-button--ghost:enabled:active{background-image:none}.fm-button:disabled{--fm-button-bg:var(--fm-action-disabled-bg);--fm-button-fg:var(--fm-text-disabled);cursor:not-allowed}.fm-button--ghost:disabled{--fm-button-bg:transparent}.fm-button--loading{pointer-events:none}.fm-button__labels{display:contents}.fm-button__label,.fm-button__sub-label{overflow-wrap:anywhere;min-width:0}.fm-button__icon{width:var(--fm-button-icon-size);height:var(--fm-button-icon-size);flex:none;justify-content:center;align-items:center;display:inline-flex}.fm-button__icon>svg{width:100%;height:100%}.fm-button__icon--legacy{width:var(--fm-spacing-24);height:var(--fm-spacing-24)}@font-face{font-family:Material Symbols Outlined;font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/materialsymbolsoutlined/v232/kJF1BvYX7BgnkSrUwT8OhrdQw4oELdPIeeII9v6oDMzByHX9rA6RzaxHMPdY43zj-jCxv3fzvRNU22ZXGJpEpjC_1v-p_4MrImHCIJIZrDCvHOelbd5zrDAt.woff)format("woff");font-display:block}@font-face{font-family:Material Symbols Filled;font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/materialsymbolsoutlined/v232/kJF1BvYX7BgnkSrUwT8OhrdQw4oELdPIeeII9v6oDMzByHX9rA6RzazHD_dY43zj-jCxv3fzvRNU22ZXGJpEpjC_1v-p_4MrImHCIJIZrDCvHOelbd5zrDAt.woff)format("woff");font-display:block}.fm-button__legacy-icon{font-size:var(--fm-spacing-24);letter-spacing:normal;text-transform:none;white-space:nowrap;word-wrap:normal;-webkit-user-select:none;user-select:none;-webkit-font-smoothing:antialiased;text-rendering:optimizelegibility;font-feature-settings:"liga";-moz-osx-font-smoothing:grayscale;direction:ltr;font-style:normal;font-weight:400;line-height:1;display:inline-block}.fm-button__legacy-icon--outline{font-family:Material Symbols Outlined,sans-serif}.fm-button__legacy-icon--filled{font-family:Material Symbols Filled,sans-serif}.fm-button--icon-only{width:var(--fm-button-height);padding:0}.fm-button--layout-dotted,.fm-button--layout-spaced{width:100%}.fm-button--layout-dotted .fm-button__labels,.fm-button--layout-spaced .fm-button__labels{flex:auto;justify-content:space-between;align-items:center;min-width:0;display:flex}.fm-button__dot{background-color:#ffffff52;border-radius:50%;flex:none;width:4px;height:4px}.fm-button__spinner{--fm-button-spinner-size:18px;box-sizing:border-box;width:var(--fm-button-spinner-size);height:var(--fm-button-spinner-size);animation:fm-button-spin var(--fm-duration-slower,.6s) linear infinite;border:2px solid;border-top-color:#0000;border-radius:50%;flex:none}.fm-button--lg .fm-button__spinner{--fm-button-spinner-size:20px}.fm-button--md .fm-button__spinner{--fm-button-spinner-size:18px}.fm-button--sm .fm-button__spinner,.fm-button--xs .fm-button__spinner{--fm-button-spinner-size:16px}@keyframes fm-button-spin{to{transform:rotate(360deg)}}@media (prefers-reduced-motion:reduce){.fm-button__spinner{animation-duration:2s}}.fm-checkbox{--fm-checkbox-size:24px;--fm-checkbox-surface:var(--fm-action-secondary-bg);--fm-checkbox-border:var(--fm-border-default);--fm-checkbox-glyph:var(--fm-icon-inverse);--fm-checkbox-glow:0 0 #0000;cursor:pointer;color:var(--fm-text-primary);align-items:center;gap:12px;display:inline-flex}.fm-checkbox--disabled{cursor:not-allowed}.fm-checkbox__box{box-sizing:border-box;width:var(--fm-checkbox-size);height:var(--fm-checkbox-size);border-radius:var(--fm-radius-sm);background-color:var(--fm-checkbox-surface);box-shadow:inset 0 0 0 var(--fm-border-width-thin) var(--fm-checkbox-border), var(--fm-shadow-xs);flex:none;justify-content:center;align-items:center;display:inline-flex;position:relative}.fm-checkbox__input{opacity:0;cursor:inherit;margin:0;position:absolute;inset:0}.fm-checkbox__glyph{--fm-icon-size:calc(var(--fm-checkbox-size) * 5 / 6);color:var(--fm-checkbox-glyph);pointer-events:none;position:relative}.fm-checkbox__labels{gap:var(--fm-spacing-4);flex-direction:column;min-width:0;display:inline-flex}.fm-checkbox__sublabel{color:var(--fm-text-secondary)}.fm-checkbox--sm{--fm-checkbox-size:24px}.fm-checkbox--md{--fm-checkbox-size:28px}.fm-checkbox--lg{--fm-checkbox-size:32px}@media (width>=1024px){.fm-checkbox--sm{--fm-checkbox-size:20px}.fm-checkbox--md{--fm-checkbox-size:24px}.fm-checkbox--lg{--fm-checkbox-size:28px}}.fm-checkbox:hover:not(.fm-checkbox--disabled):not(.fm-checkbox--selected){--fm-checkbox-border:var(--fm-border-medium)}.fm-checkbox--pressed:not(.fm-checkbox--disabled):not(.fm-checkbox--selected){--fm-checkbox-border:var(--fm-border-strong)}.fm-checkbox--error:not(.fm-checkbox--disabled){--fm-checkbox-surface:var(--fm-action-danger-bg-subtle);--fm-checkbox-border:var(--fm-border-error);--fm-checkbox-glyph:var(--fm-icon-error)}.fm-checkbox--error.fm-checkbox--pressed:not(.fm-checkbox--selected):not(.fm-checkbox--disabled){--fm-checkbox-glow:var(--fm-outer-shadow-error)}.fm-checkbox--selected:not(.fm-checkbox--disabled){--fm-checkbox-surface:var(--fm-action-primary-bg);--fm-checkbox-border:transparent;--fm-checkbox-glyph:var(--fm-icon-inverse)}.fm-checkbox--selected.fm-checkbox--pressed:not(.fm-checkbox--disabled){--fm-checkbox-surface:var(--fm-action-primary-bg-hover)}.fm-checkbox--selected.fm-checkbox--error:not(.fm-checkbox--disabled){--fm-checkbox-surface:var(--fm-action-danger-bg-subtle);--fm-checkbox-glyph:var(--fm-icon-error)}.fm-checkbox--selected.fm-checkbox--error.fm-checkbox--pressed:not(.fm-checkbox--disabled){--fm-checkbox-surface:var(--fm-action-danger-bg-hover);--fm-checkbox-glyph:var(--fm-icon-inverse)}.fm-checkbox:has(.fm-checkbox__input:focus-visible):not(.fm-checkbox--disabled){--fm-checkbox-surface:var(--fm-action-secondary-bg);--fm-checkbox-border:var(--fm-border-brand);--fm-checkbox-glyph:var(--fm-action-primary-bg);--fm-checkbox-glow:var(--fm-outer-shadow-brand)}.fm-checkbox--error:has(.fm-checkbox__input:focus-visible):not(.fm-checkbox--disabled){--fm-checkbox-surface:var(--fm-action-danger-bg-subtle);--fm-checkbox-border:var(--fm-border-error);--fm-checkbox-glyph:var(--fm-icon-error);--fm-checkbox-glow:var(--fm-outer-shadow-error)}.fm-checkbox--disabled{--fm-checkbox-surface:var(--fm-action-disabled-bg);--fm-checkbox-border:var(--fm-border-default);--fm-checkbox-glyph:var(--fm-icon-disabled)}.fm-checkbox--error.fm-checkbox--pressed:not(.fm-checkbox--selected) .fm-checkbox__box{box-shadow:inset 0 0 0 var(--fm-border-width-thin) var(--fm-checkbox-border), var(--fm-checkbox-glow)}.fm-checkbox:has(.fm-checkbox__input:focus-visible) .fm-checkbox__box{box-shadow:inset 0 0 0 var(--fm-border-width-thin) var(--fm-checkbox-border), var(--fm-checkbox-glow)}.fm-chip{--fm-chip-height:36px;--fm-chip-surface:var(--fm-surface-default);--fm-chip-overlay:transparent;--fm-chip-border:var(--fm-border-default);--fm-chip-border-width:var(--fm-border-width-thin);--fm-chip-fg:var(--fm-text-primary);--fm-chip-icon:var(--fm-icon-primary);--fm-chip-accent:var(--fm-icon-brand);--fm-chip-glow:0 0 #0000;justify-content:center;align-items:center;gap:var(--fm-spacing-4);box-sizing:border-box;height:var(--fm-chip-height);padding:0 var(--fm-spacing-12);border-radius:var(--fm-radius-sm);background-color:var(--fm-chip-surface);background-image:linear-gradient(var(--fm-chip-overlay), var(--fm-chip-overlay));color:var(--fm-chip-fg);cursor:pointer;box-shadow:inset 0 0 0 var(--fm-chip-border-width) var(--fm-chip-border), var(--fm-shadow-xs);border:none;display:inline-flex}.fm-chip:disabled{cursor:not-allowed}.fm-chip__label{white-space:nowrap;text-overflow:ellipsis;overflow:hidden}.fm-chip__icon{--fm-icon-size:var(--fm-spacing-20);color:var(--fm-chip-icon);flex:none;display:inline-flex}.fm-chip__indicator-slot{width:var(--fm-spacing-20);height:var(--fm-spacing-20);flex:none;justify-content:center;align-items:center;display:inline-flex}.fm-chip__indicator{width:var(--fm-spacing-12);height:var(--fm-spacing-12);border-radius:var(--fm-radius-full);background-color:var(--fm-chip-accent)}.fm-chip__count{box-sizing:border-box;min-width:var(--fm-spacing-20);height:var(--fm-spacing-20);padding:0 var(--fm-spacing-4);border-radius:var(--fm-radius-full);background-color:var(--fm-chip-accent);color:var(--fm-text-inverse);flex:none;justify-content:center;align-items:center;display:inline-flex}.fm-chip__remove{--fm-icon-size:var(--fm-spacing-16);color:var(--fm-chip-icon);cursor:pointer;flex:none;display:inline-flex}.fm-chip:hover:not(:disabled){--fm-chip-overlay:var(--fm-state-hover)}.fm-chip--pressed:not(:disabled){--fm-chip-overlay:var(--fm-state-pressed)}.fm-chip:hover:not(:disabled):not(.fm-chip--selected),.fm-chip--pressed:not(:disabled):not(.fm-chip--selected){--fm-chip-border:var(--fm-border-medium)}.fm-chip--selected:not(:disabled){--fm-chip-border:var(--fm-border-brand);--fm-chip-border-width:var(--fm-border-width-regular)}.fm-chip:disabled{--fm-chip-surface:var(--fm-surface-sunken);--fm-chip-overlay:transparent;--fm-chip-border:var(--fm-border-medium);--fm-chip-fg:var(--fm-text-disabled);--fm-chip-icon:var(--fm-icon-disabled);--fm-chip-accent:var(--fm-border-medium)}.fm-chip:focus-visible{--fm-chip-border:var(--fm-border-brand);--fm-chip-border-width:var(--fm-border-width-regular);--fm-chip-glow:var(--fm-outer-shadow-brand);box-shadow:inset 0 0 0 var(--fm-chip-border-width) var(--fm-chip-border), var(--fm-chip-glow);outline:none}.fm-chip--compact{--fm-chip-height:22px;padding:0 var(--fm-spacing-8)}.fm-chip--v1-plain{--fm-chip-surface:var(--fm-bg-subtle);--fm-chip-border:transparent}.fm-chip--v1-plain.fm-chip--v1-selected{--fm-chip-surface:var(--fm-text-primary);--fm-chip-fg:var(--fm-text-inverse);--fm-chip-icon:var(--fm-text-inverse)}.fm-chip--v1-neutral{--fm-chip-surface:var(--fm-text-primary);--fm-chip-fg:var(--fm-text-inverse);--fm-chip-icon:var(--fm-text-inverse);--fm-chip-border:transparent}.fm-chip--v1-info{--fm-chip-surface:var(--fm-feature-aqua-accent);--fm-chip-fg:var(--fm-text-inverse);--fm-chip-icon:var(--fm-text-inverse);--fm-chip-border:transparent}.fm-chip--v1-success{--fm-chip-surface:var(--fm-feature-lime-accent);--fm-chip-fg:var(--fm-text-inverse);--fm-chip-icon:var(--fm-text-inverse);--fm-chip-border:transparent}.fm-chip--v1-critical{--fm-chip-surface:var(--fm-feature-berry-accent);--fm-chip-fg:var(--fm-text-inverse);--fm-chip-icon:var(--fm-text-inverse);--fm-chip-border:transparent}.fm-chip--v1-warning{--fm-chip-surface:var(--fm-feature-mustard-accent);--fm-chip-fg:var(--fm-text-primary);--fm-chip-icon:var(--fm-text-primary);--fm-chip-border:transparent}.fm-radio{--fm-radio-size:24px;--fm-radio-ring-width:var(--fm-border-width-thin);--fm-radio-surface:var(--fm-action-secondary-bg);--fm-radio-ring:var(--fm-border-default);--fm-radio-dot:var(--fm-action-primary-bg);--fm-radio-glow:0 0 #0000;align-items:center;gap:var(--fm-spacing-16);cursor:pointer;color:var(--fm-text-primary);display:inline-flex}.fm-radio--disabled{cursor:not-allowed}.fm-radio__circle{box-sizing:border-box;width:var(--fm-radio-size);height:var(--fm-radio-size);border-radius:var(--fm-radius-full);background-color:var(--fm-radio-surface);box-shadow:inset 0 0 0 var(--fm-radio-ring-width) var(--fm-radio-ring), var(--fm-shadow-xs);flex:none;justify-content:center;align-items:center;display:inline-flex;position:relative}.fm-radio__input{opacity:0;cursor:inherit;margin:0;position:absolute;inset:0}.fm-radio__dot{width:calc(var(--fm-radio-size) * 10 / 24);height:calc(var(--fm-radio-size) * 10 / 24);border-radius:var(--fm-radius-full);background-color:var(--fm-radio-dot);pointer-events:none}.fm-radio__labels{gap:var(--fm-spacing-4);flex-direction:column;min-width:0;display:inline-flex}.fm-radio__sublabel{color:var(--fm-text-secondary)}.fm-radio--sm{--fm-radio-size:24px;--fm-radio-selected-ring:1px}.fm-radio--md{--fm-radio-size:28px;--fm-radio-selected-ring:1.5px}.fm-radio--lg{--fm-radio-size:32px;--fm-radio-selected-ring:2.5px}@media (width>=1024px){.fm-radio--sm{--fm-radio-size:20px;--fm-radio-selected-ring:1px}.fm-radio--md{--fm-radio-size:24px;--fm-radio-selected-ring:1px}.fm-radio--lg{--fm-radio-size:28px;--fm-radio-selected-ring:1.5px}}.fm-radio--selected:not(.fm-radio--disabled){--fm-radio-ring:var(--fm-border-brand);--fm-radio-ring-width:var(--fm-radio-selected-ring)}.fm-radio:hover:not(.fm-radio--disabled):not(.fm-radio--selected){--fm-radio-ring:var(--fm-border-medium)}.fm-radio--pressed:not(.fm-radio--disabled):not(.fm-radio--selected){--fm-radio-ring:var(--fm-border-strong)}.fm-radio--selected.fm-radio--pressed:not(.fm-radio--disabled){--fm-radio-surface:var(--fm-action-primary-bg-hover);--fm-radio-ring:transparent;--fm-radio-dot:#fff9}.fm-radio--error:not(.fm-radio--disabled){--fm-radio-surface:var(--fm-action-danger-bg-subtle);--fm-radio-ring:var(--fm-border-error);--fm-radio-dot:var(--fm-border-error)}.fm-radio--error.fm-radio--selected.fm-radio--pressed:not(.fm-radio--disabled){--fm-radio-surface:var(--fm-action-danger-bg-hover);--fm-radio-ring:transparent;--fm-radio-dot:#fff9}.fm-radio:has(.fm-radio__input:focus-visible):not(.fm-radio--disabled){--fm-radio-surface:var(--fm-action-secondary-bg);--fm-radio-ring:var(--fm-border-brand);--fm-radio-glow:var(--fm-outer-shadow-brand)}.fm-radio--error:has(.fm-radio__input:focus-visible):not(.fm-radio--disabled){--fm-radio-surface:var(--fm-action-danger-bg-subtle);--fm-radio-ring:var(--fm-border-error);--fm-radio-glow:var(--fm-outer-shadow-error)}.fm-radio--disabled{--fm-radio-surface:var(--fm-action-disabled-bg);--fm-radio-ring:transparent;--fm-radio-dot:var(--fm-icon-disabled)}.fm-radio:has(.fm-radio__input:focus-visible) .fm-radio__circle{box-shadow:inset 0 0 0 var(--fm-radio-ring-width) var(--fm-radio-ring), var(--fm-radio-glow)}.fm-radio-group{gap:var(--fm-spacing-8);flex-direction:column;display:flex}.fm-radio-group__label{color:var(--fm-text-primary)}.fm-radio-group__items{gap:var(--fm-spacing-8);flex-direction:column;display:flex}.fm-radio-group--inline>.fm-radio-group__items{align-items:center;gap:var(--fm-spacing-16);flex-direction:row}.fm-search-bar{--fm-search-height:44px;--fm-search-surface:var(--fm-surface-raised);--fm-search-border:var(--fm-border-default);--fm-search-fg:var(--fm-text-primary);--fm-search-placeholder:var(--fm-text-muted);--fm-search-icon:var(--fm-icon-primary);--fm-search-glow:0 0 #0000;--fm-search-shadow:var(--fm-shadow-text-sm);align-items:center;gap:var(--fm-spacing-12);box-sizing:border-box;width:100%;height:var(--fm-search-height);padding:0 var(--fm-spacing-8);border-radius:var(--fm-radius-md);background-color:var(--fm-search-surface);box-shadow:inset 0 0 0 var(--fm-border-width-thin) var(--fm-search-border), var(--fm-search-shadow), var(--fm-search-glow);display:flex}.fm-search-bar__leading{--fm-icon-size:var(--fm-spacing-16);color:var(--fm-search-icon);flex:none;align-items:center;display:inline-flex}.fm-search-bar__control{min-width:0;height:20px;color:var(--fm-search-fg);appearance:none;background:0 0;border:none;outline:none;flex:auto;margin:0;padding:0}.fm-search-bar__control::placeholder{color:var(--fm-search-placeholder);opacity:1}.fm-search-bar__control::-webkit-search-cancel-button{appearance:none;display:none}.fm-search-bar__control::-webkit-search-decoration{appearance:none;display:none}.fm-search-bar__clear{--fm-icon-size:var(--fm-spacing-20);width:var(--fm-spacing-20);height:var(--fm-spacing-20);color:var(--fm-icon-muted);cursor:pointer;background:0 0;border:none;flex:none;justify-content:center;align-items:center;padding:0;display:inline-flex}.fm-search-bar--sm{--fm-search-height:40px}.fm-search-bar--md{--fm-search-height:44px}.fm-search-bar--lg{--fm-search-height:52px}@media (width>=768px){.fm-search-bar--sm{--fm-search-height:36px}.fm-search-bar--md{--fm-search-height:40px}.fm-search-bar--lg{--fm-search-height:48px}}@media (width>=1024px){.fm-search-bar--sm{--fm-search-height:32px}.fm-search-bar--md{--fm-search-height:36px}.fm-search-bar--lg{--fm-search-height:44px}}.fm-search-bar:not(.fm-search-bar--disabled):hover{--fm-search-border:var(--fm-border-medium)}.fm-search-bar:not(.fm-search-bar--disabled):focus-within{--fm-search-border:var(--fm-border-brand);--fm-search-shadow:0 0 #0000;--fm-search-glow:var(--fm-outer-shadow-brand)}.fm-search-bar--error,.fm-search-bar--error:hover,.fm-search-bar--error:focus-within{--fm-search-border:var(--fm-border-error);--fm-search-fg:var(--fm-text-error);--fm-search-placeholder:var(--fm-text-error);--fm-search-icon:var(--fm-icon-error);--fm-search-shadow:0 0 #0000;--fm-search-glow:var(--fm-outer-shadow-error)}.fm-search-bar--disabled{--fm-search-surface:var(--fm-surface-sunken);--fm-search-border:var(--fm-border-default);--fm-search-fg:var(--fm-text-disabled);--fm-search-placeholder:var(--fm-text-disabled);--fm-search-icon:var(--fm-icon-disabled);--fm-search-shadow:0 0 #0000}.fm-search-bar--disabled .fm-search-bar__control{cursor:not-allowed}.fm-switch{--fm-switch-track-w:52px;--fm-switch-track-h:28px;--fm-switch-inset:2px;--fm-switch-thumb:calc(var(--fm-switch-track-h) - var(--fm-switch-inset) * 2);--fm-switch-travel:calc(var(--fm-switch-track-w) - var(--fm-switch-thumb) - var(--fm-switch-inset) * 2);--fm-switch-surface:var(--fm-action-disabled-bg);--fm-switch-thumb-color:var(--fm-border-medium);--fm-switch-icon:var(--fm-action-disabled-fg);--fm-switch-glow:0 0 #0000;align-items:center;gap:var(--fm-spacing-8);cursor:pointer;color:var(--fm-text-primary);display:inline-flex}.fm-switch--label-right{flex-direction:row-reverse}.fm-switch--disabled{cursor:not-allowed;opacity:.32}.fm-switch__track{box-sizing:border-box;width:var(--fm-switch-track-w);height:var(--fm-switch-track-h);border-radius:var(--fm-radius-full);background-color:var(--fm-switch-surface);box-shadow:var(--fm-shadow-sm);flex:none;display:inline-block;position:relative}.fm-switch__input{opacity:0;cursor:inherit;margin:0;position:absolute;inset:0}.fm-switch__thumb{top:var(--fm-switch-inset);left:var(--fm-switch-inset);width:var(--fm-switch-thumb);height:var(--fm-switch-thumb);border-radius:var(--fm-radius-full);background-color:var(--fm-switch-thumb-color);box-shadow:var(--fm-shadow-sm);transition:transform var(--fm-duration-fast,.15s) ease-in-out;pointer-events:none;justify-content:center;align-items:center;display:flex;position:absolute}.fm-switch__thumb-icon{--fm-icon-size:max(8px, calc(var(--fm-switch-thumb) - 8px));color:var(--fm-switch-icon)}.fm-switch__labels{gap:var(--fm-spacing-4);flex-direction:column;min-width:0;display:inline-flex}.fm-switch__sublabel{color:var(--fm-text-secondary)}.fm-switch--sm{--fm-switch-track-w:40px;--fm-switch-track-h:22px}.fm-switch--md{--fm-switch-track-w:52px;--fm-switch-track-h:28px}.fm-switch--lg{--fm-switch-track-w:60px;--fm-switch-track-h:32px}@media (width>=768px){.fm-switch--sm{--fm-switch-track-w:44px;--fm-switch-track-h:24px}}@media (width>=1024px){.fm-switch--sm{--fm-switch-track-w:32px;--fm-switch-track-h:18px}.fm-switch--md{--fm-switch-track-w:44px;--fm-switch-track-h:24px}.fm-switch--lg{--fm-switch-track-w:52px;--fm-switch-track-h:28px}}.fm-switch--on{--fm-switch-surface:var(--fm-action-primary-bg);--fm-switch-thumb-color:var(--fm-surface-raised);--fm-switch-icon:var(--fm-action-primary-bg)}.fm-switch--on .fm-switch__thumb{transform:translateX(var(--fm-switch-travel))}.fm-switch--on.fm-switch--pressed{--fm-switch-surface:var(--fm-action-primary-bg-hover)}.fm-switch--pressed:not(.fm-switch--on){--fm-switch-surface:var(--fm-action-disabled-fg)}.fm-switch:not(.fm-switch--on):has(.fm-switch__thumb-icon){--fm-switch-thumb-color:var(--fm-surface-raised)}.fm-switch:has(.fm-switch__input:focus-visible):not(.fm-switch--disabled){--fm-switch-glow:var(--fm-outer-shadow-brand)}.fm-switch:has(.fm-switch__input:focus-visible) .fm-switch__track{box-shadow:var(--fm-switch-glow)}.fm-field{--fm-field-pad-x:var(--fm-spacing-8);--fm-field-pad-y:var(--fm-spacing-12);--fm-field-radius:var(--fm-radius-md);--fm-field-surface:var(--fm-surface-raised);--fm-field-border:var(--fm-border-default);--fm-field-fg:var(--fm-text-primary);--fm-field-placeholder:var(--fm-text-muted);--fm-field-affix:var(--fm-icon-secondary);--fm-field-label:var(--fm-text-primary);--fm-field-helper:var(--fm-text-secondary);--fm-field-glow:0 0 #0000;--fm-field-shadow:var(--fm-shadow-xs);gap:var(--fm-spacing-4);flex-direction:column;width:100%;display:flex}.fm-field__label{align-items:baseline;gap:var(--fm-spacing-4);color:var(--fm-field-label);display:flex}.fm-field__mark{color:var(--fm-text-error)}.fm-field__box{align-items:center;gap:var(--fm-spacing-4);box-sizing:border-box;width:100%;padding:var(--fm-field-pad-y) var(--fm-field-pad-x);border-radius:var(--fm-field-radius);background-color:var(--fm-field-surface);box-shadow:inset 0 0 0 var(--fm-border-width-thin) var(--fm-field-border), var(--fm-field-shadow), var(--fm-field-glow);display:flex}.fm-field__control{min-width:0;height:20px;color:var(--fm-field-fg);background:0 0;border:none;outline:none;flex:auto;margin:0;padding:0}.fm-field__control::placeholder{color:var(--fm-field-placeholder);opacity:1}.fm-field__affix{--fm-icon-size:var(--fm-spacing-20);color:var(--fm-field-affix);flex:none;align-items:center;display:inline-flex}.fm-field__footer{justify-content:space-between;gap:var(--fm-spacing-8);color:var(--fm-field-helper);display:flex}.fm-field__counter{margin-left:auto}.fm-field--single.fm-field--sm{--fm-field-pad-y:var(--fm-spacing-10)}.fm-field--single.fm-field--md{--fm-field-pad-y:var(--fm-spacing-12)}.fm-field--single.fm-field--lg{--fm-field-pad-y:var(--fm-spacing-16);--fm-field-radius:var(--fm-radius-lg)}.fm-field--multiline{--fm-field-pad-x:var(--fm-spacing-8);--fm-field-pad-y:var(--fm-spacing-8);--fm-field-radius:var(--fm-radius-md);--fm-field-height:128px}.fm-field--multiline>.fm-field__box{height:var(--fm-field-height);align-items:stretch}.fm-field--multiline .fm-field__control{resize:none;height:100%}.fm-field--multiline .fm-field__box{align-items:stretch}.fm-field--multiline.fm-field--sm{--fm-field-height:96px}.fm-field--multiline.fm-field--md{--fm-field-height:128px}.fm-field--multiline.fm-field--lg{--fm-field-height:160px}@media (width>=768px){.fm-field--multiline.fm-field--sm{--fm-field-height:128px}.fm-field--multiline.fm-field--md{--fm-field-height:160px}.fm-field--multiline.fm-field--lg{--fm-field-height:192px}}@media (width>=1024px){.fm-field--multiline.fm-field--sm{--fm-field-height:164px}.fm-field--multiline.fm-field--md{--fm-field-height:196px}.fm-field--multiline.fm-field--lg{--fm-field-height:228px}}.fm-field:not(.fm-field--disabled)>.fm-field__box:hover{--fm-field-border:var(--fm-border-medium)}.fm-field:not(.fm-field--disabled)>.fm-field__box:focus-within{--fm-field-border:var(--fm-border-brand);--fm-field-shadow:0 0 #0000;--fm-field-glow:var(--fm-outer-shadow-brand)}.fm-field--error:not(.fm-field--disabled){--fm-field-fg:var(--fm-text-error);--fm-field-placeholder:var(--fm-text-error);--fm-field-affix:var(--fm-text-error);--fm-field-label:var(--fm-text-error);--fm-field-helper:var(--fm-text-error)}.fm-field--error:not(.fm-field--disabled)>.fm-field__box,.fm-field--error:not(.fm-field--disabled)>.fm-field__box:hover,.fm-field--error:not(.fm-field--disabled)>.fm-field__box:focus-within{--fm-field-border:var(--fm-border-error);--fm-field-shadow:0 0 #0000;--fm-field-glow:var(--fm-outer-shadow-error)}.fm-field--multiline.fm-field--error:not(.fm-field--disabled)>.fm-field__box,.fm-field--multiline.fm-field--error:not(.fm-field--disabled)>.fm-field__box:hover,.fm-field--multiline.fm-field--error:not(.fm-field--disabled)>.fm-field__box:focus-within{--fm-field-border:var(--fm-border-warning)}.fm-field--disabled{--fm-field-surface:var(--fm-surface-sunken);--fm-field-border:var(--fm-border-default);--fm-field-fg:var(--fm-text-disabled);--fm-field-placeholder:var(--fm-text-disabled);--fm-field-affix:var(--fm-icon-disabled);--fm-field-label:var(--fm-text-disabled);--fm-field-helper:var(--fm-text-disabled)}.fm-field--disabled .fm-field__control{cursor:not-allowed}
|
|
304
|
-
/*$vite$:1*/`,
|
|
305
|
-
function
|
|
323
|
+
const bn = `:root{--fm-palette-brand-fm-100:#fff3e6;--fm-palette-brand-fm-200:#ff9455;--fm-palette-brand-fm-300:#ff7823;--fm-palette-brand-fm-400:#b25300;--fm-palette-brand-fm-500:#6b3100;--fm-palette-aqua-100:#b7e2ff;--fm-palette-aqua-300:#3ab0ff;--fm-palette-aqua-500:#0a5384;--fm-palette-berry-100:#fee4dc;--fm-palette-berry-300:#e94850;--fm-palette-berry-500:#5f090a;--fm-palette-blossom-100:#fff7fc;--fm-palette-blossom-300:#ffc4c3;--fm-palette-blossom-500:#8c146a;--fm-palette-lime-100:#f4fde6;--fm-palette-lime-300:#aeef4b;--fm-palette-lime-500:#306a01;--fm-palette-mustard-100:#fef5ea;--fm-palette-mustard-300:#ffc746;--fm-palette-mustard-500:#903e1f;--fm-palette-stone-100:#f6f8fc;--fm-palette-stone-300:#b2b3b6;--fm-palette-stone-500:#2e2e2e;--fm-palette-grape-100:#eddfff;--fm-palette-grape-300:#8f61e8;--fm-palette-grape-500:#512191;--fm-palette-neurastone-0:#fff;--fm-palette-neurastone-100:#f6f6f8;--fm-palette-neurastone-200:#f0f0f0;--fm-palette-neurastone-300:#b2b3b6;--fm-palette-neurastone-400:#6b6c70;--fm-palette-neurastone-500:#4b4b4b;--fm-palette-neurastone-600:#2e2e2e;--fm-palette-neurastone-700:#262628;--fm-palette-neurastone-800:#1c1c1e;--fm-palette-neurastone-900:#121212;--fm-palette-blue-100:#e6f2ff;--fm-palette-blue-200:#66afff;--fm-palette-blue-300:#007aff;--fm-palette-blue-400:#004999;--fm-palette-blue-500:#002c5c;--fm-palette-orange-100:#fff4e6;--fm-palette-orange-200:#ffbf66;--fm-palette-orange-300:#ff9500;--fm-palette-orange-400:#995900;--fm-palette-orange-500:#5c3500;--fm-palette-green-100:#ebf9ee;--fm-palette-green-200:#85dd9b;--fm-palette-green-300:#34c759;--fm-palette-green-400:#1f7735;--fm-palette-green-500:#134720;--fm-palette-red-100:#ffebea;--fm-palette-red-200:#ff8983;--fm-palette-red-300:#ff3b30;--fm-palette-red-400:#99231d;--fm-palette-red-500:#5c1511;--fm-palette-overlay-black-alpha-4:#1212120a;--fm-palette-overlay-black-alpha-8:#12121214;--fm-palette-overlay-black-alpha-12:#1212121f;--fm-palette-overlay-black-alpha-16:#12121229;--fm-palette-overlay-black-alpha-24:#1212123d;--fm-palette-overlay-black-alpha-32:#12121252;--fm-palette-overlay-black-alpha-48:#1212127a;--fm-palette-overlay-black-alpha-64:#121212a3;--fm-palette-overlay-black-alpha-72:#121212b8;--fm-palette-overlay-black-alpha-80:#121212cc;--fm-palette-overlay-white-alpha-4:#ffffff0a;--fm-palette-overlay-white-alpha-8:#ffffff14;--fm-palette-overlay-white-alpha-12:#ffffff1f;--fm-palette-overlay-white-alpha-16:#ffffff29;--fm-palette-overlay-white-alpha-24:#ffffff3d;--fm-palette-overlay-white-alpha-32:#ffffff52;--fm-palette-overlay-white-alpha-48:#ffffff7a;--fm-palette-overlay-white-alpha-64:#ffffffa3;--fm-palette-overlay-white-alpha-72:#ffffffb8;--fm-palette-overlay-white-alpha-80:#fffc;--fm-spacing-0:0;--fm-spacing-1:1px;--fm-spacing-2:2px;--fm-spacing-4:4px;--fm-spacing-6:6px;--fm-spacing-8:8px;--fm-spacing-10:10px;--fm-spacing-12:12px;--fm-spacing-14:14px;--fm-spacing-16:16px;--fm-spacing-18:18px;--fm-spacing-20:20px;--fm-spacing-24:24px;--fm-spacing-28:28px;--fm-spacing-32:32px;--fm-spacing-40:40px;--fm-spacing-48:48px;--fm-spacing-56:56px;--fm-spacing-64:64px;--fm-spacing-72:72px;--fm-spacing-80:80px;--fm-spacing-88:88px;--fm-spacing-96:96px;--fm-spacing-104:104px;--fm-spacing-112:112px;--fm-spacing-120:120px;--fm-spacing-128:128px;--fm-spacing-160:160px;--fm-spacing-192:192px;--fm-radius-none:0;--fm-radius-xs:4px;--fm-radius-sm:8px;--fm-radius-md:12px;--fm-radius-lg:16px;--fm-radius-xl:24px;--fm-radius-2xl:32px;--fm-radius-3xl:64px;--fm-radius-full:99999px;--fm-border-width-none:0;--fm-border-width-hairline:.5px;--fm-border-width-thin:1px;--fm-border-width-regular:1.5px;--fm-border-width-medium:2px;--fm-border-width-thick:4px;--fm-opacity-0:0;--fm-opacity-8:.08;--fm-opacity-12:.12;--fm-opacity-16:.16;--fm-opacity-24:.24;--fm-opacity-32:.32;--fm-opacity-40:.4;--fm-opacity-48:.48;--fm-opacity-56:.56;--fm-opacity-64:.64;--fm-opacity-80:.8;--fm-opacity-100:1;--fm-shadow-blur-none:0;--fm-shadow-blur-xs:2px;--fm-shadow-blur-sm:4px;--fm-shadow-blur-md:6px;--fm-shadow-blur-lg:10px;--fm-shadow-blur-xl:16px;--fm-shadow-blur-2xl:24px;--fm-blur-sm:8px;--fm-blur-md:16px;--fm-blur-lg:24px;--fm-blur-xl:40px;--fm-z-index-base:0;--fm-z-index-raised:100;--fm-z-index-dropdown:200;--fm-z-index-sticky:300;--fm-z-index-overlay:400;--fm-z-index-modal:500;--fm-z-index-toast:600;--fm-z-index-tooltip:700;--fm-duration-instant:0s;--fm-duration-fast:.1s;--fm-duration-normal:.2s;--fm-duration-slow:.3s;--fm-duration-slower:.5s;--fm-easing-standard:cubic-bezier(.4, 0, .2, 1);--fm-easing-decelerate:cubic-bezier(0, 0, .2, 1);--fm-easing-accelerate:cubic-bezier(.4, 0, 1, 1);--fm-easing-spring:cubic-bezier(.34, 1.56, .64, 1);--fm-shadow-color:#1c1c1e;--fm-breakpoint-sm:0;--fm-breakpoint-md:768px;--fm-breakpoint-lg:1024px;--fm-breakpoint-xl:1440px;--fm-breakpoint-xxl:1920px}:root,[data-fm-theme=light]{--fm-bg-canvas:#f6f6f8;--fm-bg-default:#fff;--fm-bg-subtle:#f6f6f8;--fm-bg-muted:#f0f0f0;--fm-bg-elevated:#fff;--fm-bg-inverse:#1c1c1e;--fm-bg-brand:#fff3e6;--fm-bg-success:#ebf9ee;--fm-bg-warning:#fff4e6;--fm-bg-error:#ffebea;--fm-bg-info:#e6f2ff;--fm-surface-default:#fff;--fm-surface-sunken:#f0f0f0;--fm-surface-inset:#b2b3b6;--fm-surface-raised:#fff;--fm-surface-floating:#fff;--fm-text-primary:#1c1c1e;--fm-text-secondary:#4b4b4b;--fm-text-muted:#6b6c70;--fm-text-disabled:#b2b3b6;--fm-text-inverse:#fff;--fm-text-on-inset:#fff;--fm-text-link:#007aff;--fm-text-brand:#ff7823;--fm-text-success:#1f7735;--fm-text-warning:#995900;--fm-text-error:#99231d;--fm-icon-primary:#1c1c1e;--fm-icon-secondary:#4b4b4b;--fm-icon-muted:#6b6c70;--fm-icon-disabled:#b2b3b6;--fm-icon-inverse:#fff;--fm-icon-link:#007aff;--fm-icon-brand:#ff7823;--fm-icon-success:#1f7735;--fm-icon-warning:#995900;--fm-icon-error:#99231d;--fm-icon-info:#004999;--fm-icon-on-brand:#b25300;--fm-icon-on-success:#1f7735;--fm-icon-on-warning:#995900;--fm-icon-on-error:#99231d;--fm-icon-on-info:#004999;--fm-text-info:#004999;--fm-border-default:#f0f0f0;--fm-border-subtle:#f6f6f8;--fm-border-medium:#b2b3b6;--fm-border-strong:#6b6c70;--fm-border-inverse:#fff;--fm-border-brand:#ff7823;--fm-border-success:#1f7735;--fm-border-warning:#995900;--fm-border-error:#99231d;--fm-border-info:#004999;--fm-overlay-scrim-1:#12121252;--fm-overlay-scrim-2:#1212127a;--fm-overlay-scrim-3:#121212a3;--fm-overlay-scrim-4:#121212b8;--fm-action-primary-bg:#ff7823;--fm-feature-aqua-bg:#b7e2ff;--fm-feature-aqua-accent:#3ab0ff;--fm-feature-aqua-fg:#0a5384;--fm-feature-berry-bg:#fee4dc;--fm-feature-berry-accent:#e94850;--fm-feature-berry-fg:#5f090a;--fm-feature-blossom-bg:#fff7fc;--fm-feature-blossom-accent:#ffc4c3;--fm-feature-blossom-fg:#8c146a;--fm-feature-lime-bg:#f4fde6;--fm-feature-lime-accent:#aeef4b;--fm-feature-lime-fg:#306a01;--fm-feature-mustard-bg:#fef5ea;--fm-feature-mustard-accent:#ffc746;--fm-feature-mustard-fg:#903e1f;--fm-feature-stone-bg:#f6f8fc;--fm-feature-stone-accent:#b2b3b6;--fm-feature-stone-fg:#2e2e2e;--fm-feature-grape-bg:#eddfff;--fm-feature-grape-accent:#8f61e8;--fm-feature-grape-fg:#512191;--fm-state-subtle:#1212120a;--fm-state-hover:#12121214;--fm-state-pressed:#1212121f;--fm-state-selected:#12121229;--fm-state-dragged:#1212123d;--fm-action-primary-bg-hover:#b25300;--fm-action-primary-bg-subtle:#fff3e6;--fm-action-primary-fg:#1c1c1e;--fm-action-secondary-bg:#fff;--fm-action-secondary-bg-hover:#f6f6f8;--fm-action-secondary-fg:#1c1c1e;--fm-action-ghost-bg-hover:#f6f6f8;--fm-action-ghost-bg-active:#f0f0f0;--fm-action-danger-bg:#ff3b30;--fm-action-danger-bg-hover:#99231d;--fm-action-danger-bg-subtle:#ffebea;--fm-action-danger-fg:#1c1c1e;--fm-action-disabled-bg:#f0f0f0;--fm-action-disabled-fg:#6b6c70;--fm-text-on-brand:#b25300;--fm-text-on-success:#1f7735;--fm-text-on-warning:#995900;--fm-text-on-error:#99231d;--fm-text-on-info:#004999;--fm-badge-bg-aqua:#b7e2ff;--fm-badge-text-on-aqua:#0a5384;--fm-badge-icon-on-aqua:#0a5384;--fm-badge-border-aqua:#0a5384;--fm-badge-bg-berry:#fee4dc;--fm-badge-bg-blossom:#fff7fc;--fm-badge-bg-lime:#f4fde6;--fm-badge-bg-mustard:#fef5ea;--fm-badge-bg-stone:#f6f8fc;--fm-badge-bg-grape:#eddfff;--fm-badge-border-blossom:#8c146a;--fm-badge-text-on-blossom:#8c146a;--fm-badge-icon-on-blossom:#8c146a;--fm-badge-border-berry:#5f090a;--fm-badge-text-on-berry:#5f090a;--fm-badge-icon-on-berry:#5f090a;--fm-badge-border-lime:#306a01;--fm-badge-text-on-lime:#306a01;--fm-badge-icon-on-lime:#306a01;--fm-badge-border-mustard:#903e1f;--fm-badge-text-on-mustard:#903e1f;--fm-badge-icon-on-mustard:#903e1f;--fm-badge-border-stone:#2e2e2e;--fm-badge-text-on-stone:#2e2e2e;--fm-badge-icon-on-stone:#2e2e2e;--fm-badge-border-grape:#512191;--fm-badge-text-on-grape:#512191;--fm-badge-icon-on-grape:#512191;--fm-badge-bg-brand:#fff3e6;--fm-badge-border-brand:#ff7823;--fm-badge-text-on-brand:#ff7823;--fm-badge-icon-on-brand:#ff7823}[data-fm-theme=dark]{--fm-bg-canvas:#121212;--fm-bg-default:#1c1c1e;--fm-bg-subtle:#262628;--fm-bg-muted:#2e2e2e;--fm-bg-elevated:#262628;--fm-bg-inverse:#fff;--fm-bg-brand:#b25300;--fm-bg-success:#1f7735;--fm-bg-warning:#995900;--fm-bg-error:#99231d;--fm-bg-info:#004999;--fm-surface-default:#262628;--fm-surface-sunken:#121212;--fm-surface-inset:#1c1c1e;--fm-surface-raised:#2e2e2e;--fm-surface-floating:#4b4b4b;--fm-text-primary:#fff;--fm-text-secondary:#b2b3b6;--fm-text-muted:#6b6c70;--fm-text-disabled:#4b4b4b;--fm-text-inverse:#1c1c1e;--fm-text-on-inset:#fff;--fm-text-link:#66afff;--fm-text-brand:#fff3e6;--fm-text-success:#85dd9b;--fm-text-warning:#ffbf66;--fm-text-error:#ff8983;--fm-icon-primary:#fff;--fm-icon-secondary:#b2b3b6;--fm-icon-muted:#6b6c70;--fm-icon-disabled:#4b4b4b;--fm-icon-inverse:#1c1c1e;--fm-icon-link:#66afff;--fm-icon-brand:#fff3e6;--fm-icon-success:#85dd9b;--fm-icon-warning:#ffbf66;--fm-icon-error:#ff8983;--fm-icon-info:#66afff;--fm-icon-on-brand:#fff3e6;--fm-icon-on-success:#ebf9ee;--fm-icon-on-warning:#fff4e6;--fm-icon-on-error:#ffebea;--fm-icon-on-info:#e6f2ff;--fm-text-info:#66afff;--fm-border-default:#2e2e2e;--fm-border-subtle:#262628;--fm-border-medium:#b2b3b6;--fm-border-strong:#f6f6f8;--fm-border-inverse:#1c1c1e;--fm-border-brand:#fff3e6;--fm-border-success:#85dd9b;--fm-border-warning:#ffbf66;--fm-border-error:#ff8983;--fm-border-info:#66afff;--fm-overlay-scrim-1:#1212127a;--fm-overlay-scrim-2:#121212a3;--fm-overlay-scrim-3:#121212b8;--fm-overlay-scrim-4:#121212cc;--fm-action-primary-bg:#ff7823;--fm-feature-aqua-bg:#0a5384;--fm-feature-aqua-accent:#3ab0ff;--fm-feature-aqua-fg:#b7e2ff;--fm-feature-berry-bg:#5f090a;--fm-feature-berry-accent:#e94850;--fm-feature-berry-fg:#fee4dc;--fm-feature-blossom-bg:#8c146a;--fm-feature-blossom-accent:#ffc4c3;--fm-feature-blossom-fg:#fff7fc;--fm-feature-lime-bg:#306a01;--fm-feature-lime-accent:#aeef4b;--fm-feature-lime-fg:#f4fde6;--fm-feature-mustard-bg:#903e1f;--fm-feature-mustard-accent:#ffc746;--fm-feature-mustard-fg:#fef5ea;--fm-feature-stone-bg:#2e2e2e;--fm-feature-stone-accent:#b2b3b6;--fm-feature-stone-fg:#f6f8fc;--fm-feature-grape-bg:#512191;--fm-feature-grape-accent:#8f61e8;--fm-feature-grape-fg:#eddfff;--fm-state-subtle:#ffffff0a;--fm-state-hover:#ffffff14;--fm-state-pressed:#ffffff1f;--fm-state-selected:#ffffff29;--fm-state-dragged:#ffffff3d;--fm-action-primary-bg-hover:#b25300;--fm-action-primary-bg-subtle:#6b3100;--fm-action-primary-fg:#1c1c1e;--fm-action-secondary-bg:#262628;--fm-action-secondary-bg-hover:#2e2e2e;--fm-action-secondary-fg:#fff;--fm-action-ghost-bg-hover:#262628;--fm-action-ghost-bg-active:#2e2e2e;--fm-action-danger-bg:#ff3b30;--fm-action-danger-bg-hover:#99231d;--fm-action-danger-bg-subtle:#5c1511;--fm-action-danger-fg:#1c1c1e;--fm-action-disabled-bg:#2e2e2e;--fm-action-disabled-fg:#6b6c70;--fm-text-on-brand:#fff3e6;--fm-text-on-success:#ebf9ee;--fm-text-on-warning:#fff4e6;--fm-text-on-error:#ffebea;--fm-text-on-info:#e6f2ff;--fm-badge-bg-aqua:#0a5384;--fm-badge-text-on-aqua:#b7e2ff;--fm-badge-icon-on-aqua:#b7e2ff;--fm-badge-border-aqua:#3ab0ff;--fm-badge-bg-berry:#5f090a;--fm-badge-bg-blossom:#8c146a;--fm-badge-bg-lime:#306a01;--fm-badge-bg-mustard:#903e1f;--fm-badge-bg-stone:#2e2e2e;--fm-badge-bg-grape:#512191;--fm-badge-border-blossom:#ffc4c3;--fm-badge-text-on-blossom:#fff7fc;--fm-badge-icon-on-blossom:#fff7fc;--fm-badge-border-berry:#e94850;--fm-badge-text-on-berry:#fee4dc;--fm-badge-icon-on-berry:#fee4dc;--fm-badge-border-lime:#aeef4b;--fm-badge-text-on-lime:#f4fde6;--fm-badge-icon-on-lime:#f4fde6;--fm-badge-border-mustard:#ffc746;--fm-badge-text-on-mustard:#fef5ea;--fm-badge-icon-on-mustard:#fef5ea;--fm-badge-border-stone:#b2b3b6;--fm-badge-text-on-stone:#f6f8fc;--fm-badge-icon-on-stone:#f6f8fc;--fm-badge-border-grape:#8f61e8;--fm-badge-text-on-grape:#eddfff;--fm-badge-icon-on-grape:#eddfff;--fm-badge-bg-brand:#6b3100;--fm-badge-border-brand:#ff7823;--fm-badge-text-on-brand:#fff3e6;--fm-badge-icon-on-brand:#fff3e6}:root{--fm-font-size-8:8px;--fm-font-size-10:10px;--fm-font-size-12:12px;--fm-font-size-14:14px;--fm-font-size-16:16px;--fm-font-size-18:18px;--fm-font-size-22:22px;--fm-font-size-26:26px;--fm-font-size-32:32px;--fm-font-size-36:36px;--fm-font-size-48:48px;--fm-font-size-60:60px;--fm-font-size-72:72px;--fm-font-family-heading:"Cabinet Grotesk";--fm-font-family-body:"Inter";--fm-font-weight-regular:400;--fm-font-weight-medium:500;--fm-font-weight-semi-bold:600;--fm-font-weight-extra-bold:800;--fm-font-weight-black:900;--fm-line-height-8:12px;--fm-line-height-10:14px;--fm-line-height-12:16px;--fm-line-height-14:20px;--fm-line-height-16:24px;--fm-line-height-18:26px;--fm-line-height-22:30px;--fm-line-height-26:36px;--fm-line-height-32:40px;--fm-line-height-36:44px;--fm-line-height-48:56px;--fm-line-height-60:72px;--fm-line-height-72:80px}:root:lang(zh),[lang=zh]{--fm-font-family-heading:"Noto Sans SC";--fm-font-family-body:"Noto Sans SC";--fm-font-weight-regular:400;--fm-font-weight-medium:500;--fm-font-weight-semi-bold:600;--fm-font-weight-extra-bold:800;--fm-font-weight-black:900;--fm-line-height-8:12px;--fm-line-height-10:14px;--fm-line-height-12:18px;--fm-line-height-14:20px;--fm-line-height-16:26px;--fm-line-height-18:26px;--fm-line-height-22:30px;--fm-line-height-26:36px;--fm-line-height-32:44px;--fm-line-height-36:46px;--fm-line-height-48:60px;--fm-line-height-60:76px;--fm-line-height-72:90px}:root:lang(th),[lang=th]{--fm-font-family-heading:"Noto Sans Thai";--fm-font-family-body:"Noto Sans Thai";--fm-font-weight-regular:400;--fm-font-weight-medium:500;--fm-font-weight-semi-bold:600;--fm-font-weight-extra-bold:800;--fm-font-weight-black:900;--fm-line-height-8:14px;--fm-line-height-10:16px;--fm-line-height-12:20px;--fm-line-height-14:24px;--fm-line-height-16:28px;--fm-line-height-18:28px;--fm-line-height-22:32px;--fm-line-height-26:38px;--fm-line-height-32:46px;--fm-line-height-36:50px;--fm-line-height-48:64px;--fm-line-height-60:80px;--fm-line-height-72:96px}.fm-text-display-xl{letter-spacing:.015em;font-family:Cabinet Grotesk,sans-serif;font-size:72px;font-weight:900;line-height:80px}.fm-text-display-lg{letter-spacing:.015em;font-family:Cabinet Grotesk,sans-serif;font-size:60px;font-weight:900;line-height:72px}.fm-text-display-md{letter-spacing:.015em;font-family:Cabinet Grotesk,sans-serif;font-size:48px;font-weight:900;line-height:56px}.fm-text-display-sm{letter-spacing:.015em;font-family:Cabinet Grotesk,sans-serif;font-size:36px;font-weight:900;line-height:44px}.fm-text-title-xl{letter-spacing:.01em;font-family:Cabinet Grotesk,sans-serif;font-size:32px;font-weight:800;line-height:40px}.fm-text-title-lg{letter-spacing:.01em;font-family:Cabinet Grotesk,sans-serif;font-size:26px;font-weight:800;line-height:36px}.fm-text-title-md{letter-spacing:.01em;font-family:Cabinet Grotesk,sans-serif;font-size:22px;font-weight:800;line-height:30px}.fm-text-title-sm{letter-spacing:.01em;font-family:Cabinet Grotesk,sans-serif;font-size:18px;font-weight:800;line-height:26px}.fm-text-body-lg-600{letter-spacing:.0025em;font-family:Inter,sans-serif;font-size:16px;font-weight:600;line-height:24px}.fm-text-body-md-600{letter-spacing:.01em;font-family:Inter,sans-serif;font-size:14px;font-weight:600;line-height:20px}.fm-text-body-sm-600{letter-spacing:.02em;font-family:Inter,sans-serif;font-size:12px;font-weight:600;line-height:16px}.fm-text-body-xs-600{letter-spacing:.02em;font-family:Inter,sans-serif;font-size:10px;font-weight:600;line-height:14px}.fm-text-body-overline-xs-600{letter-spacing:.1em;font-family:Inter,sans-serif;font-size:10px;font-weight:600;line-height:14px}.fm-text-body-overline-2xs-600{letter-spacing:.1em;font-family:Inter,sans-serif;font-size:8px;font-weight:600;line-height:12px}.fm-text-body-lg-500{letter-spacing:.0025em;font-family:Inter,sans-serif;font-size:16px;font-weight:500;line-height:24px}.fm-text-body-md-500{letter-spacing:.01em;font-family:Inter,sans-serif;font-size:14px;font-weight:500;line-height:20px}.fm-text-body-sm-500{letter-spacing:.02em;font-family:Inter,sans-serif;font-size:12px;font-weight:500;line-height:16px}.fm-text-body-xs-500{letter-spacing:.02em;font-family:Inter,sans-serif;font-size:10px;font-weight:500;line-height:14px}.fm-text-body-lg-400{letter-spacing:.0025em;font-family:Inter,sans-serif;font-size:16px;font-weight:400;line-height:24px}.fm-text-body-md-400{letter-spacing:.01em;font-family:Inter,sans-serif;font-size:14px;font-weight:400;line-height:20px}.fm-text-body-sm-400{letter-spacing:.02em;font-family:Inter,sans-serif;font-size:12px;font-weight:400;line-height:16px}.fm-text-body-xs-400{letter-spacing:.02em;font-family:Inter,sans-serif;font-size:10px;font-weight:400;line-height:14px}:root{--fm-shadow-light-xs:0 1px 2px 0 #1c1c1e0a;--fm-shadow-light-sm:0 2px 4px 0 #1c1c1e0f;--fm-shadow-light-md:0 4px 6px 0 #1c1c1e14;--fm-shadow-light-lg:0 6px 10px 0 #1c1c1e1a;--fm-shadow-light-xl:0 8px 16px 0 #1c1c1e1f;--fm-shadow-light-2xl:0 12px 24px 0 #1c1c1e24;--fm-shadow-light-top-sm:0 -2px 4px 0 #1c1c1e0f;--fm-shadow-light-top-md:0 -4px 6px 0 #1c1c1e14;--fm-shadow-light-side-left-md:-4px 0 6px 0 #1c1c1e14;--fm-shadow-light-side-right-md:4px 0 6px 0 #1c1c1e14;--fm-shadow-light-text-sm:0 1px 1px 0 #1c1c1e0d;--fm-shadow-light-text-md:0 1px 2px 0 #1c1c1e1a;--fm-shadow-light-text-lg:0 2px 4px 0 #1c1c1e26;--fm-shadow-light-text-xl:0 3px 6px 0 #1c1c1e33;--fm-shadow-dark-xs:0 1px 2px 0 #ffffff0a;--fm-shadow-dark-sm:0 2px 4px 0 #ffffff0f;--fm-shadow-dark-md:0 4px 6px 0 #ffffff14;--fm-shadow-dark-lg:0 6px 10px 0 #ffffff1a;--fm-shadow-dark-xl:0 8px 16px 0 #ffffff1f;--fm-shadow-dark-2xl:0 12px 24px 0 #ffffff24;--fm-shadow-dark-top-sm:0 -2px 4px 0 #ffffff0f;--fm-shadow-dark-top-md:0 -4px 6px 0 #ffffff14;--fm-shadow-dark-side-left-md:-4px 0 6px 0 #ffffff14;--fm-shadow-dark-side-right-md:4px 0 6px 0 #ffffff14;--fm-shadow-dark-text-sm:0 1px 1px 0 #ffffff0d;--fm-shadow-dark-text-md:0 1px 2px 0 #ffffff1a;--fm-shadow-dark-text-lg:0 2px 4px 0 #ffffff26;--fm-shadow-dark-text-xl:0 3px 6px 0 #fff3;--fm-outer-shadow-light-brand:0 0 0 4px #ff782352;--fm-outer-shadow-light-error:0 0 0 4px #ff3b3052;--fm-outer-shadow-dark-brand:0 0 0 4px #ff782366;--fm-outer-shadow-dark-error:0 0 0 4px #ff3b3066;--fm-inner-shadow-light-sm:inset 0 1px 2px 0 #1c1c1e0f;--fm-inner-shadow-light-md:inset 0 2px 4px 0 #1c1c1e1a;--fm-inner-shadow-light-brand:0 2px 4px 0 #1c1c1e14, inset 0 0 0 1.25px #1c1c1e1f;--fm-inner-shadow-dark-sm:inset 0 1px 2px 0 #ffffff0f;--fm-inner-shadow-dark-md:inset 0 2px 4px 0 #ffffff1a;--fm-inner-shadow-dark-brand:0 2px 4px 0 #ffffff14, inset 0 0 0 1.25px #ffffff1f;--fm-blur-sm:8px;--fm-blur-md:16px;--fm-blur-lg:24px;--fm-blur-xl:40px}:root,[data-fm-theme=light]{--fm-shadow-xs:var(--fm-shadow-light-xs);--fm-shadow-sm:var(--fm-shadow-light-sm);--fm-shadow-md:var(--fm-shadow-light-md);--fm-shadow-lg:var(--fm-shadow-light-lg);--fm-shadow-xl:var(--fm-shadow-light-xl);--fm-shadow-2xl:var(--fm-shadow-light-2xl);--fm-shadow-top-sm:var(--fm-shadow-light-top-sm);--fm-shadow-top-md:var(--fm-shadow-light-top-md);--fm-shadow-side-left-md:var(--fm-shadow-light-side-left-md);--fm-shadow-side-right-md:var(--fm-shadow-light-side-right-md);--fm-shadow-text-sm:var(--fm-shadow-light-text-sm);--fm-shadow-text-md:var(--fm-shadow-light-text-md);--fm-shadow-text-lg:var(--fm-shadow-light-text-lg);--fm-shadow-text-xl:var(--fm-shadow-light-text-xl);--fm-outer-shadow-brand:var(--fm-outer-shadow-light-brand);--fm-outer-shadow-error:var(--fm-outer-shadow-light-error);--fm-inner-shadow-sm:var(--fm-inner-shadow-light-sm);--fm-inner-shadow-md:var(--fm-inner-shadow-light-md);--fm-inner-shadow-brand:var(--fm-inner-shadow-light-brand)}[data-fm-theme=dark]{--fm-shadow-xs:var(--fm-shadow-dark-xs);--fm-shadow-sm:var(--fm-shadow-dark-sm);--fm-shadow-md:var(--fm-shadow-dark-md);--fm-shadow-lg:var(--fm-shadow-dark-lg);--fm-shadow-xl:var(--fm-shadow-dark-xl);--fm-shadow-2xl:var(--fm-shadow-dark-2xl);--fm-shadow-top-sm:var(--fm-shadow-dark-top-sm);--fm-shadow-top-md:var(--fm-shadow-dark-top-md);--fm-shadow-side-left-md:var(--fm-shadow-dark-side-left-md);--fm-shadow-side-right-md:var(--fm-shadow-dark-side-right-md);--fm-shadow-text-sm:var(--fm-shadow-dark-text-sm);--fm-shadow-text-md:var(--fm-shadow-dark-text-md);--fm-shadow-text-lg:var(--fm-shadow-dark-text-lg);--fm-shadow-text-xl:var(--fm-shadow-dark-text-xl);--fm-outer-shadow-brand:var(--fm-outer-shadow-dark-brand);--fm-outer-shadow-error:var(--fm-outer-shadow-dark-error);--fm-inner-shadow-sm:var(--fm-inner-shadow-dark-sm);--fm-inner-shadow-md:var(--fm-inner-shadow-dark-md);--fm-inner-shadow-brand:var(--fm-inner-shadow-dark-brand)}[data-fm-theme]{color:var(--fm-text-primary)}.fm-icon{width:var(--fm-icon-size,24px);height:var(--fm-icon-size,24px);font-size:var(--fm-icon-size,24px);vertical-align:middle;-webkit-user-select:none;user-select:none;flex:none;justify-content:center;align-items:center;line-height:1;display:inline-flex}.fm-icon__svg{fill:none;width:100%;height:100%;display:block}.fm-icon--rounded,.fm-icon--outlined{text-transform:none;letter-spacing:normal;word-wrap:normal;white-space:nowrap;font-feature-settings:"liga";-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:antialiased;text-rendering:optimizelegibility;direction:ltr;font-style:normal;font-weight:400}.fm-icon--rounded{font-family:Material Symbols Filled}.fm-icon--outlined{font-family:Material Symbols Outlined}.fm-alert{--fm-alert-surface:var(--fm-bg-inverse);--fm-alert-fg:var(--fm-text-inverse);--fm-alert-icon:var(--fm-icon-inverse);--fm-alert-progress:var(--fm-bg-default);--fm-alert-pad-x:var(--fm-spacing-16);--fm-alert-pad-y:var(--fm-spacing-12);box-sizing:border-box;border-radius:var(--fm-radius-lg);background-color:var(--fm-alert-surface);color:var(--fm-alert-fg);box-shadow:var(--fm-shadow-sm);flex-direction:column;display:flex;overflow:hidden}@media (width>=768px){.fm-alert{--fm-alert-pad-x:var(--fm-spacing-24);--fm-alert-pad-y:var(--fm-spacing-16)}}.fm-alert__body{align-items:center;gap:var(--fm-spacing-12);padding:var(--fm-alert-pad-y) var(--fm-alert-pad-x);display:flex}.fm-alert__icon{--fm-icon-size:32px;width:32px;height:32px;color:var(--fm-alert-icon);flex:none;justify-content:center;align-items:center;display:inline-flex}.fm-alert__danger-mark{width:var(--fm-spacing-24);height:var(--fm-spacing-24);border-radius:var(--fm-radius-full);background-color:var(--fm-alert-icon);justify-content:center;align-items:center;display:inline-flex}.fm-alert__danger-bar{width:var(--fm-spacing-12);height:var(--fm-border-width-medium);border-radius:var(--fm-radius-full);background-color:var(--fm-icon-inverse)}.fm-alert__text{flex-direction:column;flex:auto;min-width:0;display:flex}.fm-alert__close{--fm-icon-size:var(--fm-spacing-20);width:var(--fm-spacing-40);height:var(--fm-spacing-40);border-radius:var(--fm-radius-sm);color:var(--fm-alert-fg);cursor:pointer;background:0 0;border:none;flex:none;justify-content:center;align-items:center;padding:0;display:inline-flex}.fm-alert__progress{border-radius:var(--fm-radius-full);background-color:var(--fm-alert-progress);height:2px}.fm-alert__progress--animated{transform-origin:0;animation:fm-alert-drain var(--fm-alert-duration,3s) linear forwards}@keyframes fm-alert-drain{0%{transform:scaleX(1)}to{transform:scaleX(0)}}.fm-alert--info{--fm-alert-surface:var(--fm-bg-info);--fm-alert-fg:var(--fm-text-on-info);--fm-alert-icon:var(--fm-icon-on-info);--fm-alert-progress:var(--fm-icon-on-info)}.fm-alert--success{--fm-alert-surface:var(--fm-bg-success);--fm-alert-fg:var(--fm-text-on-success);--fm-alert-icon:var(--fm-icon-on-success);--fm-alert-progress:var(--fm-icon-on-success)}.fm-alert--warning{--fm-alert-surface:var(--fm-bg-warning);--fm-alert-fg:var(--fm-text-on-warning);--fm-alert-icon:var(--fm-icon-on-warning);--fm-alert-progress:var(--fm-icon-on-warning)}.fm-alert--danger{--fm-alert-surface:var(--fm-bg-error);--fm-alert-fg:var(--fm-text-on-error);--fm-alert-icon:var(--fm-icon-on-error);--fm-alert-progress:var(--fm-icon-on-error)}.fm-badge{--fm-badge-gap:var(--fm-spacing-2);justify-content:center;align-items:center;gap:var(--fm-badge-gap);box-sizing:border-box;border-radius:var(--fm-radius-xs);background-color:var(--fm-badge-surface);color:var(--fm-badge-fg);padding:var(--fm-badge-pad-y) var(--fm-badge-pad-x);-webkit-user-select:none;user-select:none;display:inline-flex}.fm-badge__label{text-overflow:ellipsis;white-space:nowrap;text-align:center;min-width:0;overflow:hidden}.fm-badge__icon{color:var(--fm-badge-icon,var(--fm-badge-fg));flex:none;display:inline-flex}.fm-badge--sm{--fm-badge-pad-x:var(--fm-spacing-4);--fm-badge-pad-y:var(--fm-spacing-2);--fm-badge-count-size:16px}.fm-badge--md{--fm-badge-pad-x:var(--fm-spacing-6);--fm-badge-pad-y:var(--fm-spacing-4);--fm-badge-count-size:24px}.fm-badge--lg{--fm-badge-pad-x:var(--fm-spacing-8);--fm-badge-pad-y:var(--fm-spacing-4);--fm-badge-count-size:32px}.fm-badge--filled{--fm-badge-surface:var(--fm-badge-bg)}.fm-badge--outlined{--fm-badge-surface:transparent;box-shadow:inset 0 0 0 var(--fm-border-width-thin) var(--fm-badge-border)}.fm-badge--count{--fm-badge-surface:var(--fm-action-primary-bg-subtle);--fm-badge-fg:var(--fm-text-brand);width:var(--fm-badge-count-size);height:var(--fm-badge-count-size);border-radius:calc(var(--fm-badge-count-size) / 2);padding:0}.fm-badge__count{line-height:1}.fm-badge--count-overflow{width:auto;min-width:var(--fm-badge-count-size);padding:0 calc(var(--fm-badge-count-size) * .375)}.fm-badge--brand{--fm-badge-bg:var(--fm-badge-bg-brand);--fm-badge-fg:var(--fm-badge-text-on-brand);--fm-badge-icon:var(--fm-badge-icon-on-brand);--fm-badge-border:var(--fm-badge-border-brand)}.fm-badge--info{--fm-badge-bg:var(--fm-bg-info);--fm-badge-fg:var(--fm-text-on-info);--fm-badge-icon:var(--fm-text-on-info);--fm-badge-border:var(--fm-border-info)}.fm-badge--success{--fm-badge-bg:var(--fm-bg-success);--fm-badge-fg:var(--fm-text-on-success);--fm-badge-icon:var(--fm-text-on-success);--fm-badge-border:var(--fm-border-success)}.fm-badge--warning{--fm-badge-bg:var(--fm-bg-warning);--fm-badge-fg:var(--fm-text-on-warning);--fm-badge-icon:var(--fm-text-on-warning);--fm-badge-border:var(--fm-border-warning)}.fm-badge--error{--fm-badge-bg:var(--fm-bg-error);--fm-badge-fg:var(--fm-text-on-error);--fm-badge-icon:var(--fm-text-on-error);--fm-badge-border:var(--fm-border-error)}.fm-badge--aqua{--fm-badge-bg:var(--fm-badge-bg-aqua);--fm-badge-fg:var(--fm-badge-text-on-aqua);--fm-badge-icon:var(--fm-badge-icon-on-aqua);--fm-badge-border:var(--fm-badge-border-aqua)}.fm-badge--berry{--fm-badge-bg:var(--fm-badge-bg-berry);--fm-badge-fg:var(--fm-badge-text-on-berry);--fm-badge-icon:var(--fm-badge-icon-on-berry);--fm-badge-border:var(--fm-badge-border-berry)}.fm-badge--blossom{--fm-badge-bg:var(--fm-badge-bg-blossom);--fm-badge-fg:var(--fm-badge-text-on-blossom);--fm-badge-icon:var(--fm-badge-icon-on-blossom);--fm-badge-border:var(--fm-badge-border-blossom)}.fm-badge--lime{--fm-badge-bg:var(--fm-badge-bg-lime);--fm-badge-fg:var(--fm-badge-text-on-lime);--fm-badge-icon:var(--fm-badge-icon-on-lime);--fm-badge-border:var(--fm-badge-border-lime)}.fm-badge--mustard{--fm-badge-bg:var(--fm-badge-bg-mustard);--fm-badge-fg:var(--fm-badge-text-on-mustard);--fm-badge-icon:var(--fm-badge-icon-on-mustard);--fm-badge-border:var(--fm-badge-border-mustard)}.fm-badge--stone{--fm-badge-bg:var(--fm-badge-bg-stone);--fm-badge-fg:var(--fm-badge-text-on-stone);--fm-badge-icon:var(--fm-badge-icon-on-stone);--fm-badge-border:var(--fm-badge-border-stone)}.fm-badge--grape{--fm-badge-bg:var(--fm-badge-bg-grape);--fm-badge-fg:var(--fm-badge-text-on-grape);--fm-badge-icon:var(--fm-badge-icon-on-grape);--fm-badge-border:var(--fm-badge-border-grape)}.fm-badge-anchor{align-items:center;gap:var(--fm-spacing-8);-webkit-user-select:none;user-select:none;display:inline-flex;position:relative}.fm-badge--overlay{--fm-badge-surface:var(--fm-text-primary);--fm-badge-fg:var(--fm-text-inverse);border-radius:var(--fm-radius-full);padding:0}.fm-badge--overlay-pinned{position:absolute;top:-2px;right:-4px}.fm-badge--overlay:not(.fm-badge--dot){min-width:16px;height:16px;padding:0 var(--fm-spacing-4)}.fm-badge--dot{width:6px;min-width:0;height:6px;padding:0}.fm-badge--overlay-pinned.fm-badge--dot{top:0;right:0}.fm-badge--v1-info{--fm-badge-surface:var(--fm-feature-aqua-accent);--fm-badge-fg:var(--fm-text-inverse)}.fm-badge--v1-success{--fm-badge-surface:var(--fm-feature-lime-accent);--fm-badge-fg:var(--fm-text-inverse)}.fm-badge--v1-warning{--fm-badge-surface:var(--fm-feature-mustard-accent);--fm-badge-fg:var(--fm-text-primary)}.fm-badge--v1-critical{--fm-badge-surface:var(--fm-feature-berry-accent);--fm-badge-fg:var(--fm-text-inverse)}.fm-badge--v1-neutral{--fm-badge-surface:var(--fm-text-primary);--fm-badge-fg:var(--fm-text-inverse)}.fm-badge--v1-numeric{--fm-badge-surface:var(--fm-text-error);--fm-badge-fg:var(--fm-text-inverse)}.fm-button{--fm-button-height:44px;--fm-button-padding-x:var(--fm-spacing-16);--fm-button-gap:var(--fm-spacing-8);--fm-button-icon-size:var(--fm-spacing-20);--fm-button-radius:var(--fm-radius-sm);--fm-button-border-width:var(--fm-border-width-none);--fm-button-border-color:transparent;--fm-button-bg:transparent;--fm-button-bg-hover:var(--fm-button-bg);--fm-button-bg-active:var(--fm-button-bg-hover);--fm-button-fg:var(--fm-text-primary);--fm-button-effects:0 0 #0000;--fm-button-effects-pressed:var(--fm-button-effects);--fm-button-glow:0 0 #0000;--fm-button-focus-ring:0 0 #0000;box-sizing:border-box;justify-content:center;align-items:center;gap:var(--fm-button-gap);height:var(--fm-button-height);padding:0 var(--fm-button-padding-x);border:var(--fm-button-border-width) solid var(--fm-button-border-color);border-radius:var(--fm-button-radius);background-color:var(--fm-button-bg);color:var(--fm-button-fg);box-shadow:var(--fm-button-focus-ring), var(--fm-button-effects);font-family:var(--fm-font-family-body), sans-serif;font-size:var(--fm-font-size-14);font-weight:var(--fm-font-weight-semi-bold);line-height:var(--fm-line-height-14);letter-spacing:.01em;text-align:center;cursor:pointer;-webkit-user-select:none;user-select:none;appearance:none;-webkit-tap-highlight-color:transparent;background-image:none;text-decoration:none;display:inline-flex}.fm-button:focus{outline:none}.fm-button--xs{--fm-button-height:32px}.fm-button--sm{--fm-button-height:40px}.fm-button--md{--fm-button-height:44px}.fm-button--lg{--fm-button-height:52px}@media (width>=768px){.fm-button--xs{--fm-button-height:28px}.fm-button--sm{--fm-button-height:36px}.fm-button--md{--fm-button-height:40px}.fm-button--lg{--fm-button-height:48px}.fm-button:not(.fm-button--xs){font-size:var(--fm-font-size-16);line-height:var(--fm-line-height-16);letter-spacing:.0025em}}@media (width>=1024px){.fm-button--xs{--fm-button-height:24px}.fm-button--sm{--fm-button-height:32px}.fm-button--md{--fm-button-height:36px}.fm-button--lg{--fm-button-height:44px}}.fm-button--primary{--fm-button-bg:var(--fm-action-primary-bg);--fm-button-bg-hover:var(--fm-action-primary-bg-hover);--fm-button-fg:var(--fm-text-inverse);--fm-button-effects:var(--fm-inner-shadow-brand);--fm-button-glow:var(--fm-outer-shadow-brand)}.fm-button--secondary{--fm-button-bg:var(--fm-action-secondary-bg);--fm-button-bg-hover:var(--fm-action-secondary-bg-hover);--fm-button-fg:var(--fm-text-primary);--fm-button-effects:var(--fm-inner-shadow-brand);--fm-button-effects-pressed:0 0 #0000;--fm-button-glow:var(--fm-outer-shadow-brand)}.fm-button--danger{--fm-button-bg:var(--fm-action-danger-bg);--fm-button-bg-hover:var(--fm-action-danger-bg-hover);--fm-button-fg:var(--fm-text-inverse);--fm-button-effects:var(--fm-inner-shadow-brand);--fm-button-glow:var(--fm-outer-shadow-error)}.fm-button--ghost{--fm-button-bg:transparent;--fm-button-bg-hover:var(--fm-action-ghost-bg-hover);--fm-button-bg-active:var(--fm-action-ghost-bg-active);--fm-button-fg:var(--fm-text-primary);--fm-button-glow:var(--fm-outer-shadow-brand)}.fm-button--legacy-plain{--fm-button-fg:var(--fm-text-brand)}.fm-button--legacy-fab{--fm-button-height:var(--fm-spacing-56);--fm-button-radius:var(--fm-radius-full);min-width:var(--fm-spacing-56);padding:0 var(--fm-spacing-16)}.fm-button:enabled:hover{background-color:var(--fm-button-bg-hover)}.fm-button:enabled:focus-visible{background-color:var(--fm-button-bg-hover);box-shadow:var(--fm-button-focus-ring), var(--fm-button-effects), var(--fm-button-glow)}.fm-button--secondary:enabled:focus-visible{--fm-button-focus-ring:inset 0 0 0 1px var(--fm-border-brand)}.fm-button:enabled:active{background-color:var(--fm-button-bg-active);background-image:linear-gradient(var(--fm-state-pressed), var(--fm-state-pressed));box-shadow:var(--fm-button-focus-ring), var(--fm-button-effects-pressed), var(--fm-button-glow)}.fm-button--ghost:enabled:active{background-image:none}.fm-button:disabled{--fm-button-bg:var(--fm-action-disabled-bg);--fm-button-fg:var(--fm-text-disabled);cursor:not-allowed}.fm-button--ghost:disabled{--fm-button-bg:transparent}.fm-button--loading{pointer-events:none}.fm-button__labels{display:contents}.fm-button__label,.fm-button__sub-label{overflow-wrap:anywhere;min-width:0}.fm-button__icon{width:var(--fm-button-icon-size);height:var(--fm-button-icon-size);flex:none;justify-content:center;align-items:center;display:inline-flex}.fm-button__icon>svg{width:100%;height:100%}.fm-button__icon--legacy{width:var(--fm-spacing-24);height:var(--fm-spacing-24)}@font-face{font-family:Material Symbols Outlined;font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/materialsymbolsoutlined/v232/kJF1BvYX7BgnkSrUwT8OhrdQw4oELdPIeeII9v6oDMzByHX9rA6RzaxHMPdY43zj-jCxv3fzvRNU22ZXGJpEpjC_1v-p_4MrImHCIJIZrDCvHOelbd5zrDAt.woff)format("woff");font-display:block}@font-face{font-family:Material Symbols Filled;font-style:normal;font-weight:400;src:url(https://fonts.gstatic.com/s/materialsymbolsoutlined/v232/kJF1BvYX7BgnkSrUwT8OhrdQw4oELdPIeeII9v6oDMzByHX9rA6RzazHD_dY43zj-jCxv3fzvRNU22ZXGJpEpjC_1v-p_4MrImHCIJIZrDCvHOelbd5zrDAt.woff)format("woff");font-display:block}.fm-button__legacy-icon{font-size:var(--fm-spacing-24);letter-spacing:normal;text-transform:none;white-space:nowrap;word-wrap:normal;-webkit-user-select:none;user-select:none;-webkit-font-smoothing:antialiased;text-rendering:optimizelegibility;font-feature-settings:"liga";-moz-osx-font-smoothing:grayscale;direction:ltr;font-style:normal;font-weight:400;line-height:1;display:inline-block}.fm-button__legacy-icon--outline{font-family:Material Symbols Outlined,sans-serif}.fm-button__legacy-icon--filled{font-family:Material Symbols Filled,sans-serif}.fm-button--icon-only{width:var(--fm-button-height);padding:0}.fm-button--layout-dotted,.fm-button--layout-spaced{width:100%}.fm-button--layout-dotted .fm-button__labels,.fm-button--layout-spaced .fm-button__labels{flex:auto;justify-content:space-between;align-items:center;min-width:0;display:flex}.fm-button__dot{background-color:#ffffff52;border-radius:50%;flex:none;width:4px;height:4px}.fm-button__spinner{--fm-button-spinner-size:18px;box-sizing:border-box;width:var(--fm-button-spinner-size);height:var(--fm-button-spinner-size);animation:fm-button-spin var(--fm-duration-slower,.6s) linear infinite;border:2px solid;border-top-color:#0000;border-radius:50%;flex:none}.fm-button--lg .fm-button__spinner{--fm-button-spinner-size:20px}.fm-button--md .fm-button__spinner{--fm-button-spinner-size:18px}.fm-button--sm .fm-button__spinner,.fm-button--xs .fm-button__spinner{--fm-button-spinner-size:16px}@keyframes fm-button-spin{to{transform:rotate(360deg)}}@media (prefers-reduced-motion:reduce){.fm-button__spinner{animation-duration:2s}}.fm-checkbox{--fm-checkbox-size:24px;--fm-checkbox-surface:var(--fm-action-secondary-bg);--fm-checkbox-border:var(--fm-border-default);--fm-checkbox-glyph:var(--fm-icon-inverse);--fm-checkbox-glow:0 0 #0000;cursor:pointer;color:var(--fm-text-primary);align-items:center;gap:12px;display:inline-flex}.fm-checkbox--disabled{cursor:not-allowed}.fm-checkbox__box{box-sizing:border-box;width:var(--fm-checkbox-size);height:var(--fm-checkbox-size);border-radius:var(--fm-radius-sm);background-color:var(--fm-checkbox-surface);box-shadow:inset 0 0 0 var(--fm-border-width-thin) var(--fm-checkbox-border), var(--fm-shadow-xs);flex:none;justify-content:center;align-items:center;display:inline-flex;position:relative}.fm-checkbox__input{opacity:0;cursor:inherit;margin:0;position:absolute;inset:0}.fm-checkbox__glyph{--fm-icon-size:calc(var(--fm-checkbox-size) * 5 / 6);color:var(--fm-checkbox-glyph);pointer-events:none;position:relative}.fm-checkbox__labels{gap:var(--fm-spacing-4);flex-direction:column;min-width:0;display:inline-flex}.fm-checkbox__sublabel{color:var(--fm-text-secondary)}.fm-checkbox--sm{--fm-checkbox-size:24px}.fm-checkbox--md{--fm-checkbox-size:28px}.fm-checkbox--lg{--fm-checkbox-size:32px}@media (width>=1024px){.fm-checkbox--sm{--fm-checkbox-size:20px}.fm-checkbox--md{--fm-checkbox-size:24px}.fm-checkbox--lg{--fm-checkbox-size:28px}}.fm-checkbox:hover:not(.fm-checkbox--disabled):not(.fm-checkbox--selected){--fm-checkbox-border:var(--fm-border-medium)}.fm-checkbox--pressed:not(.fm-checkbox--disabled):not(.fm-checkbox--selected){--fm-checkbox-border:var(--fm-border-strong)}.fm-checkbox--error:not(.fm-checkbox--disabled){--fm-checkbox-surface:var(--fm-action-danger-bg-subtle);--fm-checkbox-border:var(--fm-border-error);--fm-checkbox-glyph:var(--fm-icon-error)}.fm-checkbox--error.fm-checkbox--pressed:not(.fm-checkbox--selected):not(.fm-checkbox--disabled){--fm-checkbox-glow:var(--fm-outer-shadow-error)}.fm-checkbox--selected:not(.fm-checkbox--disabled){--fm-checkbox-surface:var(--fm-action-primary-bg);--fm-checkbox-border:transparent;--fm-checkbox-glyph:var(--fm-icon-inverse)}.fm-checkbox--selected.fm-checkbox--pressed:not(.fm-checkbox--disabled){--fm-checkbox-surface:var(--fm-action-primary-bg-hover)}.fm-checkbox--selected.fm-checkbox--error:not(.fm-checkbox--disabled){--fm-checkbox-surface:var(--fm-action-danger-bg-subtle);--fm-checkbox-glyph:var(--fm-icon-error)}.fm-checkbox--selected.fm-checkbox--error.fm-checkbox--pressed:not(.fm-checkbox--disabled){--fm-checkbox-surface:var(--fm-action-danger-bg-hover);--fm-checkbox-glyph:var(--fm-icon-inverse)}.fm-checkbox:has(.fm-checkbox__input:focus-visible):not(.fm-checkbox--disabled){--fm-checkbox-surface:var(--fm-action-secondary-bg);--fm-checkbox-border:var(--fm-border-brand);--fm-checkbox-glyph:var(--fm-action-primary-bg);--fm-checkbox-glow:var(--fm-outer-shadow-brand)}.fm-checkbox--error:has(.fm-checkbox__input:focus-visible):not(.fm-checkbox--disabled){--fm-checkbox-surface:var(--fm-action-danger-bg-subtle);--fm-checkbox-border:var(--fm-border-error);--fm-checkbox-glyph:var(--fm-icon-error);--fm-checkbox-glow:var(--fm-outer-shadow-error)}.fm-checkbox--disabled{--fm-checkbox-surface:var(--fm-action-disabled-bg);--fm-checkbox-border:var(--fm-border-default);--fm-checkbox-glyph:var(--fm-icon-disabled)}.fm-checkbox--error.fm-checkbox--pressed:not(.fm-checkbox--selected) .fm-checkbox__box{box-shadow:inset 0 0 0 var(--fm-border-width-thin) var(--fm-checkbox-border), var(--fm-checkbox-glow)}.fm-checkbox:has(.fm-checkbox__input:focus-visible) .fm-checkbox__box{box-shadow:inset 0 0 0 var(--fm-border-width-thin) var(--fm-checkbox-border), var(--fm-checkbox-glow)}.fm-chip{--fm-chip-height:36px;--fm-chip-surface:var(--fm-surface-default);--fm-chip-overlay:transparent;--fm-chip-border:var(--fm-border-default);--fm-chip-border-width:var(--fm-border-width-thin);--fm-chip-fg:var(--fm-text-primary);--fm-chip-icon:var(--fm-icon-primary);--fm-chip-accent:var(--fm-icon-brand);--fm-chip-glow:0 0 #0000;justify-content:center;align-items:center;gap:var(--fm-spacing-4);box-sizing:border-box;height:var(--fm-chip-height);padding:0 var(--fm-spacing-12);border-radius:var(--fm-radius-sm);background-color:var(--fm-chip-surface);background-image:linear-gradient(var(--fm-chip-overlay), var(--fm-chip-overlay));color:var(--fm-chip-fg);cursor:pointer;box-shadow:inset 0 0 0 var(--fm-chip-border-width) var(--fm-chip-border), var(--fm-shadow-xs);border:none;display:inline-flex}.fm-chip:disabled{cursor:not-allowed}.fm-chip__label{white-space:nowrap;text-overflow:ellipsis;overflow:hidden}.fm-chip__icon{--fm-icon-size:var(--fm-spacing-20);color:var(--fm-chip-icon);flex:none;display:inline-flex}.fm-chip__indicator-slot{width:var(--fm-spacing-20);height:var(--fm-spacing-20);flex:none;justify-content:center;align-items:center;display:inline-flex}.fm-chip__indicator{width:var(--fm-spacing-12);height:var(--fm-spacing-12);border-radius:var(--fm-radius-full);background-color:var(--fm-chip-accent)}.fm-chip__count{box-sizing:border-box;min-width:var(--fm-spacing-20);height:var(--fm-spacing-20);padding:0 var(--fm-spacing-4);border-radius:var(--fm-radius-full);background-color:var(--fm-chip-accent);color:var(--fm-text-inverse);flex:none;justify-content:center;align-items:center;display:inline-flex}.fm-chip__remove{--fm-icon-size:var(--fm-spacing-16);color:var(--fm-chip-icon);cursor:pointer;flex:none;display:inline-flex}.fm-chip:hover:not(:disabled){--fm-chip-overlay:var(--fm-state-hover)}.fm-chip--pressed:not(:disabled){--fm-chip-overlay:var(--fm-state-pressed)}.fm-chip:hover:not(:disabled):not(.fm-chip--selected),.fm-chip--pressed:not(:disabled):not(.fm-chip--selected){--fm-chip-border:var(--fm-border-medium)}.fm-chip--selected:not(:disabled){--fm-chip-border:var(--fm-border-brand);--fm-chip-border-width:var(--fm-border-width-regular)}.fm-chip:disabled{--fm-chip-surface:var(--fm-surface-sunken);--fm-chip-overlay:transparent;--fm-chip-border:var(--fm-border-medium);--fm-chip-fg:var(--fm-text-disabled);--fm-chip-icon:var(--fm-icon-disabled);--fm-chip-accent:var(--fm-border-medium)}.fm-chip:focus-visible{--fm-chip-border:var(--fm-border-brand);--fm-chip-border-width:var(--fm-border-width-regular);--fm-chip-glow:var(--fm-outer-shadow-brand);box-shadow:inset 0 0 0 var(--fm-chip-border-width) var(--fm-chip-border), var(--fm-chip-glow);outline:none}.fm-chip--compact{--fm-chip-height:22px;padding:0 var(--fm-spacing-8)}.fm-chip--v1-plain{--fm-chip-surface:var(--fm-bg-subtle);--fm-chip-border:transparent}.fm-chip--v1-plain.fm-chip--v1-selected{--fm-chip-surface:var(--fm-text-primary);--fm-chip-fg:var(--fm-text-inverse);--fm-chip-icon:var(--fm-text-inverse)}.fm-chip--v1-neutral{--fm-chip-surface:var(--fm-text-primary);--fm-chip-fg:var(--fm-text-inverse);--fm-chip-icon:var(--fm-text-inverse);--fm-chip-border:transparent}.fm-chip--v1-info{--fm-chip-surface:var(--fm-feature-aqua-accent);--fm-chip-fg:var(--fm-text-inverse);--fm-chip-icon:var(--fm-text-inverse);--fm-chip-border:transparent}.fm-chip--v1-success{--fm-chip-surface:var(--fm-feature-lime-accent);--fm-chip-fg:var(--fm-text-inverse);--fm-chip-icon:var(--fm-text-inverse);--fm-chip-border:transparent}.fm-chip--v1-critical{--fm-chip-surface:var(--fm-feature-berry-accent);--fm-chip-fg:var(--fm-text-inverse);--fm-chip-icon:var(--fm-text-inverse);--fm-chip-border:transparent}.fm-chip--v1-warning{--fm-chip-surface:var(--fm-feature-mustard-accent);--fm-chip-fg:var(--fm-text-primary);--fm-chip-icon:var(--fm-text-primary);--fm-chip-border:transparent}.fm-radio{--fm-radio-size:24px;--fm-radio-ring-width:var(--fm-border-width-thin);--fm-radio-surface:var(--fm-action-secondary-bg);--fm-radio-ring:var(--fm-border-default);--fm-radio-dot:var(--fm-action-primary-bg);--fm-radio-glow:0 0 #0000;align-items:center;gap:var(--fm-spacing-16);cursor:pointer;color:var(--fm-text-primary);display:inline-flex}.fm-radio--disabled{cursor:not-allowed}.fm-radio__circle{box-sizing:border-box;width:var(--fm-radio-size);height:var(--fm-radio-size);border-radius:var(--fm-radius-full);background-color:var(--fm-radio-surface);box-shadow:inset 0 0 0 var(--fm-radio-ring-width) var(--fm-radio-ring), var(--fm-shadow-xs);flex:none;justify-content:center;align-items:center;display:inline-flex;position:relative}.fm-radio__input{opacity:0;cursor:inherit;margin:0;position:absolute;inset:0}.fm-radio__dot{width:calc(var(--fm-radio-size) * 10 / 24);height:calc(var(--fm-radio-size) * 10 / 24);border-radius:var(--fm-radius-full);background-color:var(--fm-radio-dot);pointer-events:none}.fm-radio__labels{gap:var(--fm-spacing-4);flex-direction:column;min-width:0;display:inline-flex}.fm-radio__sublabel{color:var(--fm-text-secondary)}.fm-radio--sm{--fm-radio-size:24px;--fm-radio-selected-ring:1px}.fm-radio--md{--fm-radio-size:28px;--fm-radio-selected-ring:1.5px}.fm-radio--lg{--fm-radio-size:32px;--fm-radio-selected-ring:2.5px}@media (width>=1024px){.fm-radio--sm{--fm-radio-size:20px;--fm-radio-selected-ring:1px}.fm-radio--md{--fm-radio-size:24px;--fm-radio-selected-ring:1px}.fm-radio--lg{--fm-radio-size:28px;--fm-radio-selected-ring:1.5px}}.fm-radio--selected:not(.fm-radio--disabled){--fm-radio-ring:var(--fm-border-brand);--fm-radio-ring-width:var(--fm-radio-selected-ring)}.fm-radio:hover:not(.fm-radio--disabled):not(.fm-radio--selected){--fm-radio-ring:var(--fm-border-medium)}.fm-radio--pressed:not(.fm-radio--disabled):not(.fm-radio--selected){--fm-radio-ring:var(--fm-border-strong)}.fm-radio--selected.fm-radio--pressed:not(.fm-radio--disabled){--fm-radio-surface:var(--fm-action-primary-bg-hover);--fm-radio-ring:transparent;--fm-radio-dot:#fff9}.fm-radio--error:not(.fm-radio--disabled){--fm-radio-surface:var(--fm-action-danger-bg-subtle);--fm-radio-ring:var(--fm-border-error);--fm-radio-dot:var(--fm-border-error)}.fm-radio--error.fm-radio--selected.fm-radio--pressed:not(.fm-radio--disabled){--fm-radio-surface:var(--fm-action-danger-bg-hover);--fm-radio-ring:transparent;--fm-radio-dot:#fff9}.fm-radio:has(.fm-radio__input:focus-visible):not(.fm-radio--disabled){--fm-radio-surface:var(--fm-action-secondary-bg);--fm-radio-ring:var(--fm-border-brand);--fm-radio-glow:var(--fm-outer-shadow-brand)}.fm-radio--error:has(.fm-radio__input:focus-visible):not(.fm-radio--disabled){--fm-radio-surface:var(--fm-action-danger-bg-subtle);--fm-radio-ring:var(--fm-border-error);--fm-radio-glow:var(--fm-outer-shadow-error)}.fm-radio--disabled{--fm-radio-surface:var(--fm-action-disabled-bg);--fm-radio-ring:transparent;--fm-radio-dot:var(--fm-icon-disabled)}.fm-radio:has(.fm-radio__input:focus-visible) .fm-radio__circle{box-shadow:inset 0 0 0 var(--fm-radio-ring-width) var(--fm-radio-ring), var(--fm-radio-glow)}.fm-radio-group{gap:var(--fm-spacing-8);flex-direction:column;display:flex}.fm-radio-group__label{color:var(--fm-text-primary)}.fm-radio-group__items{gap:var(--fm-spacing-8);flex-direction:column;display:flex}.fm-radio-group--inline>.fm-radio-group__items{align-items:center;gap:var(--fm-spacing-16);flex-direction:row}.fm-search-bar{--fm-search-height:44px;--fm-search-surface:var(--fm-surface-raised);--fm-search-border:var(--fm-border-default);--fm-search-fg:var(--fm-text-primary);--fm-search-placeholder:var(--fm-text-muted);--fm-search-icon:var(--fm-icon-primary);--fm-search-glow:0 0 #0000;--fm-search-shadow:var(--fm-shadow-text-sm);align-items:center;gap:var(--fm-spacing-12);box-sizing:border-box;width:100%;height:var(--fm-search-height);padding:0 var(--fm-spacing-8);border-radius:var(--fm-radius-md);background-color:var(--fm-search-surface);box-shadow:inset 0 0 0 var(--fm-border-width-thin) var(--fm-search-border), var(--fm-search-shadow), var(--fm-search-glow);display:flex}.fm-search-bar__leading{--fm-icon-size:var(--fm-spacing-16);color:var(--fm-search-icon);flex:none;align-items:center;display:inline-flex}.fm-search-bar__control{min-width:0;height:20px;color:var(--fm-search-fg);appearance:none;background:0 0;border:none;outline:none;flex:auto;margin:0;padding:0}.fm-search-bar__control::placeholder{color:var(--fm-search-placeholder);opacity:1}.fm-search-bar__control::-webkit-search-cancel-button{appearance:none;display:none}.fm-search-bar__control::-webkit-search-decoration{appearance:none;display:none}.fm-search-bar__clear{--fm-icon-size:var(--fm-spacing-20);width:var(--fm-spacing-20);height:var(--fm-spacing-20);color:var(--fm-icon-muted);cursor:pointer;background:0 0;border:none;flex:none;justify-content:center;align-items:center;padding:0;display:inline-flex}.fm-search-bar--sm{--fm-search-height:40px}.fm-search-bar--md{--fm-search-height:44px}.fm-search-bar--lg{--fm-search-height:52px}@media (width>=768px){.fm-search-bar--sm{--fm-search-height:36px}.fm-search-bar--md{--fm-search-height:40px}.fm-search-bar--lg{--fm-search-height:48px}}@media (width>=1024px){.fm-search-bar--sm{--fm-search-height:32px}.fm-search-bar--md{--fm-search-height:36px}.fm-search-bar--lg{--fm-search-height:44px}}.fm-search-bar:not(.fm-search-bar--disabled):hover{--fm-search-border:var(--fm-border-medium)}.fm-search-bar:not(.fm-search-bar--disabled):focus-within{--fm-search-border:var(--fm-border-brand);--fm-search-shadow:0 0 #0000;--fm-search-glow:var(--fm-outer-shadow-brand)}.fm-search-bar--error,.fm-search-bar--error:hover,.fm-search-bar--error:focus-within{--fm-search-border:var(--fm-border-error);--fm-search-fg:var(--fm-text-error);--fm-search-placeholder:var(--fm-text-error);--fm-search-icon:var(--fm-icon-error);--fm-search-shadow:0 0 #0000;--fm-search-glow:var(--fm-outer-shadow-error)}.fm-search-bar--disabled{--fm-search-surface:var(--fm-surface-sunken);--fm-search-border:var(--fm-border-default);--fm-search-fg:var(--fm-text-disabled);--fm-search-placeholder:var(--fm-text-disabled);--fm-search-icon:var(--fm-icon-disabled);--fm-search-shadow:0 0 #0000}.fm-search-bar--disabled .fm-search-bar__control{cursor:not-allowed}.fm-switch{--fm-switch-track-w:52px;--fm-switch-track-h:28px;--fm-switch-inset:2px;--fm-switch-thumb:calc(var(--fm-switch-track-h) - var(--fm-switch-inset) * 2);--fm-switch-travel:calc(var(--fm-switch-track-w) - var(--fm-switch-thumb) - var(--fm-switch-inset) * 2);--fm-switch-surface:var(--fm-action-disabled-bg);--fm-switch-thumb-color:var(--fm-border-medium);--fm-switch-icon:var(--fm-action-disabled-fg);--fm-switch-glow:0 0 #0000;align-items:center;gap:var(--fm-spacing-8);cursor:pointer;color:var(--fm-text-primary);display:inline-flex}.fm-switch--label-right{flex-direction:row-reverse}.fm-switch--disabled{cursor:not-allowed;opacity:.32}.fm-switch__track{box-sizing:border-box;width:var(--fm-switch-track-w);height:var(--fm-switch-track-h);border-radius:var(--fm-radius-full);background-color:var(--fm-switch-surface);box-shadow:var(--fm-shadow-sm);flex:none;display:inline-block;position:relative}.fm-switch__input{opacity:0;cursor:inherit;margin:0;position:absolute;inset:0}.fm-switch__thumb{top:var(--fm-switch-inset);left:var(--fm-switch-inset);width:var(--fm-switch-thumb);height:var(--fm-switch-thumb);border-radius:var(--fm-radius-full);background-color:var(--fm-switch-thumb-color);box-shadow:var(--fm-shadow-sm);transition:transform var(--fm-duration-fast,.15s) ease-in-out;pointer-events:none;justify-content:center;align-items:center;display:flex;position:absolute}.fm-switch__thumb-icon{--fm-icon-size:max(8px, calc(var(--fm-switch-thumb) - 8px));color:var(--fm-switch-icon)}.fm-switch__labels{gap:var(--fm-spacing-4);flex-direction:column;min-width:0;display:inline-flex}.fm-switch__sublabel{color:var(--fm-text-secondary)}.fm-switch--sm{--fm-switch-track-w:40px;--fm-switch-track-h:22px}.fm-switch--md{--fm-switch-track-w:52px;--fm-switch-track-h:28px}.fm-switch--lg{--fm-switch-track-w:60px;--fm-switch-track-h:32px}@media (width>=768px){.fm-switch--sm{--fm-switch-track-w:44px;--fm-switch-track-h:24px}}@media (width>=1024px){.fm-switch--sm{--fm-switch-track-w:32px;--fm-switch-track-h:18px}.fm-switch--md{--fm-switch-track-w:44px;--fm-switch-track-h:24px}.fm-switch--lg{--fm-switch-track-w:52px;--fm-switch-track-h:28px}}.fm-switch--on{--fm-switch-surface:var(--fm-action-primary-bg);--fm-switch-thumb-color:var(--fm-surface-raised);--fm-switch-icon:var(--fm-action-primary-bg)}.fm-switch--on .fm-switch__thumb{transform:translateX(var(--fm-switch-travel))}.fm-switch--on.fm-switch--pressed{--fm-switch-surface:var(--fm-action-primary-bg-hover)}.fm-switch--pressed:not(.fm-switch--on){--fm-switch-surface:var(--fm-action-disabled-fg)}.fm-switch:not(.fm-switch--on):has(.fm-switch__thumb-icon){--fm-switch-thumb-color:var(--fm-surface-raised)}.fm-switch:has(.fm-switch__input:focus-visible):not(.fm-switch--disabled){--fm-switch-glow:var(--fm-outer-shadow-brand)}.fm-switch:has(.fm-switch__input:focus-visible) .fm-switch__track{box-shadow:var(--fm-switch-glow)}.fm-field{--fm-field-pad-x:var(--fm-spacing-8);--fm-field-pad-y:var(--fm-spacing-12);--fm-field-radius:var(--fm-radius-md);--fm-field-surface:var(--fm-surface-raised);--fm-field-border:var(--fm-border-default);--fm-field-fg:var(--fm-text-primary);--fm-field-placeholder:var(--fm-text-muted);--fm-field-affix:var(--fm-icon-secondary);--fm-field-label:var(--fm-text-primary);--fm-field-helper:var(--fm-text-secondary);--fm-field-glow:0 0 #0000;--fm-field-shadow:var(--fm-shadow-xs);gap:var(--fm-spacing-4);flex-direction:column;width:100%;display:flex}.fm-field__label{align-items:baseline;gap:var(--fm-spacing-4);color:var(--fm-field-label);display:flex}.fm-field__mark{color:var(--fm-text-error)}.fm-field__box{align-items:center;gap:var(--fm-spacing-4);box-sizing:border-box;width:100%;padding:var(--fm-field-pad-y) var(--fm-field-pad-x);border-radius:var(--fm-field-radius);background-color:var(--fm-field-surface);box-shadow:inset 0 0 0 var(--fm-border-width-thin) var(--fm-field-border), var(--fm-field-shadow), var(--fm-field-glow);display:flex}.fm-field__control{min-width:0;height:20px;color:var(--fm-field-fg);background:0 0;border:none;outline:none;flex:auto;margin:0;padding:0}.fm-field__control::placeholder{color:var(--fm-field-placeholder);opacity:1}.fm-field__affix{--fm-icon-size:var(--fm-spacing-20);color:var(--fm-field-affix);flex:none;align-items:center;display:inline-flex}.fm-field__footer{justify-content:space-between;gap:var(--fm-spacing-8);color:var(--fm-field-helper);display:flex}.fm-field__counter{margin-left:auto}.fm-field--single.fm-field--sm{--fm-field-pad-y:var(--fm-spacing-10)}.fm-field--single.fm-field--md{--fm-field-pad-y:var(--fm-spacing-12)}.fm-field--single.fm-field--lg{--fm-field-pad-y:var(--fm-spacing-16);--fm-field-radius:var(--fm-radius-lg)}.fm-field--multiline{--fm-field-pad-x:var(--fm-spacing-8);--fm-field-pad-y:var(--fm-spacing-8);--fm-field-radius:var(--fm-radius-md);--fm-field-height:128px}.fm-field--multiline>.fm-field__box{height:var(--fm-field-height);align-items:stretch}.fm-field--multiline .fm-field__control{resize:none;height:100%}.fm-field--multiline .fm-field__box{align-items:stretch}.fm-field--multiline.fm-field--sm{--fm-field-height:96px}.fm-field--multiline.fm-field--md{--fm-field-height:128px}.fm-field--multiline.fm-field--lg{--fm-field-height:160px}@media (width>=768px){.fm-field--multiline.fm-field--sm{--fm-field-height:128px}.fm-field--multiline.fm-field--md{--fm-field-height:160px}.fm-field--multiline.fm-field--lg{--fm-field-height:192px}}@media (width>=1024px){.fm-field--multiline.fm-field--sm{--fm-field-height:164px}.fm-field--multiline.fm-field--md{--fm-field-height:196px}.fm-field--multiline.fm-field--lg{--fm-field-height:228px}}.fm-field:not(.fm-field--disabled)>.fm-field__box:hover{--fm-field-border:var(--fm-border-medium)}.fm-field:not(.fm-field--disabled)>.fm-field__box:focus-within{--fm-field-border:var(--fm-border-brand);--fm-field-shadow:0 0 #0000;--fm-field-glow:var(--fm-outer-shadow-brand)}.fm-field--error:not(.fm-field--disabled){--fm-field-fg:var(--fm-text-error);--fm-field-placeholder:var(--fm-text-error);--fm-field-affix:var(--fm-text-error);--fm-field-label:var(--fm-text-error);--fm-field-helper:var(--fm-text-error)}.fm-field--error:not(.fm-field--disabled)>.fm-field__box,.fm-field--error:not(.fm-field--disabled)>.fm-field__box:hover,.fm-field--error:not(.fm-field--disabled)>.fm-field__box:focus-within{--fm-field-border:var(--fm-border-error);--fm-field-shadow:0 0 #0000;--fm-field-glow:var(--fm-outer-shadow-error)}.fm-field--multiline.fm-field--error:not(.fm-field--disabled)>.fm-field__box,.fm-field--multiline.fm-field--error:not(.fm-field--disabled)>.fm-field__box:hover,.fm-field--multiline.fm-field--error:not(.fm-field--disabled)>.fm-field__box:focus-within{--fm-field-border:var(--fm-border-warning)}.fm-field--disabled{--fm-field-surface:var(--fm-surface-sunken);--fm-field-border:var(--fm-border-default);--fm-field-fg:var(--fm-text-disabled);--fm-field-placeholder:var(--fm-text-disabled);--fm-field-affix:var(--fm-icon-disabled);--fm-field-label:var(--fm-text-disabled);--fm-field-helper:var(--fm-text-disabled)}.fm-field--disabled .fm-field__control{cursor:not-allowed}
|
|
324
|
+
/*$vite$:1*/`, zt = /url\(\s*(['"]?)\s*([^)'"]*?)\s*\1\s*\)/gi, vn = /@font-face\s*\{[^}]*\}/gi;
|
|
325
|
+
function Nt(e) {
|
|
306
326
|
return /^(data:|blob:|#)/i.test(e);
|
|
307
327
|
}
|
|
308
|
-
function
|
|
309
|
-
for (const t of e.matchAll(
|
|
310
|
-
if (!
|
|
328
|
+
function yn(e) {
|
|
329
|
+
for (const t of e.matchAll(zt))
|
|
330
|
+
if (!Nt(t[2])) return !0;
|
|
311
331
|
return !1;
|
|
312
332
|
}
|
|
313
|
-
function
|
|
333
|
+
function xn(e) {
|
|
314
334
|
var n;
|
|
315
335
|
return `@font-face ${((n = /font-family\s*:\s*([^;}]+)/i.exec(e)) == null ? void 0 : n[1].trim()) || "(unnamed)"}`;
|
|
316
336
|
}
|
|
317
|
-
function
|
|
337
|
+
function wn(e) {
|
|
318
338
|
const t = [];
|
|
319
|
-
let n = e.replace(
|
|
320
|
-
return n = n.replace(
|
|
339
|
+
let n = e.replace(vn, (r) => yn(r) ? (t.push(xn(r)), "") : r);
|
|
340
|
+
return n = n.replace(zt, (r, a, o) => Nt(o) ? r : (t.push(`url(${o})`), "url(about:invalid)")), { css: n, stripped: t };
|
|
321
341
|
}
|
|
322
|
-
const
|
|
342
|
+
const He = "/* __FM_UI_LIBRARY_V2_STYLES__ */", kn = [
|
|
323
343
|
"--fm-text-primary",
|
|
324
344
|
"--fm-bg-default",
|
|
325
345
|
"--fm-border-default",
|
|
326
346
|
"--fm-action-primary-bg"
|
|
327
347
|
];
|
|
328
|
-
function
|
|
329
|
-
if (!e.includes(
|
|
348
|
+
function _n(e, t) {
|
|
349
|
+
if (!e.includes(He))
|
|
330
350
|
throw new Error("report canvas frame is missing the UI library style placeholder");
|
|
331
|
-
const { css: n, stripped: r } =
|
|
351
|
+
const { css: n, stripped: r } = wn(t), a = kn.filter((y) => !n.includes(y));
|
|
332
352
|
if (a.length)
|
|
333
353
|
throw new Error(`the UI library stylesheet defines none of ${a.join(", ")}`);
|
|
334
|
-
const
|
|
335
|
-
if (
|
|
354
|
+
const o = e.replace(He, () => n);
|
|
355
|
+
if (o.includes(He))
|
|
336
356
|
throw new Error("the frame declares the UI library style placeholder more than once");
|
|
337
|
-
return { html:
|
|
357
|
+
return { html: o, stripped: r };
|
|
338
358
|
}
|
|
339
|
-
const
|
|
359
|
+
const Sn = `<meta charset="utf-8" />
|
|
340
360
|
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
341
361
|
<!--
|
|
342
362
|
Runtime shell for AI-written report sections. Loaded into ONE iframe per report with
|
|
@@ -3202,8 +3222,8 @@ const gn = `<meta charset="utf-8" />
|
|
|
3202
3222
|
post({ type: "ready", nonce: NONCE })
|
|
3203
3223
|
})()
|
|
3204
3224
|
<\/script>
|
|
3205
|
-
`,
|
|
3206
|
-
function
|
|
3225
|
+
`, ho = _n(Sn, bn).html, dt = 8e3;
|
|
3226
|
+
function ct(e) {
|
|
3207
3227
|
const t = e;
|
|
3208
3228
|
if (!t || typeof t != "object") return;
|
|
3209
3229
|
const n = (a) => Number.isSafeInteger(a) && a >= 0 && a <= 1e4;
|
|
@@ -3217,10 +3237,10 @@ function mt(e) {
|
|
|
3217
3237
|
...r === null || typeof r == "number" && Number.isFinite(r) ? { value: r } : typeof r == "string" ? { value: r.slice(0, 64) } : {}
|
|
3218
3238
|
};
|
|
3219
3239
|
}
|
|
3220
|
-
function
|
|
3240
|
+
function Rt(e) {
|
|
3221
3241
|
const t = e;
|
|
3222
3242
|
if (!t || typeof t != "object" || typeof t.tag != "string") return;
|
|
3223
|
-
const n = Array.isArray(t.path) ? t.path.filter((
|
|
3243
|
+
const n = Array.isArray(t.path) ? t.path.filter((o) => Number.isSafeInteger(o) && o >= 0).slice(0, 32) : [], r = ct(t.datum), a = Array.isArray(t.points) ? t.points.slice(0, 64).map(ct).filter((o) => !!o) : [];
|
|
3224
3244
|
return {
|
|
3225
3245
|
tag: t.tag.slice(0, 32),
|
|
3226
3246
|
...typeof t.part == "string" ? { part: t.part.slice(0, 128) } : {},
|
|
@@ -3231,15 +3251,15 @@ function Nt(e) {
|
|
|
3231
3251
|
...a.length ? { points: a } : {}
|
|
3232
3252
|
};
|
|
3233
3253
|
}
|
|
3234
|
-
function
|
|
3254
|
+
function In(e) {
|
|
3235
3255
|
const t = e;
|
|
3236
3256
|
if (!t || typeof t != "object") return;
|
|
3237
|
-
const [n, r, a,
|
|
3238
|
-
return
|
|
3257
|
+
const [n, r, a, o] = [t.left, t.top, t.width, t.height], y = (x) => typeof x == "number" && Number.isFinite(x);
|
|
3258
|
+
return y(n) && y(r) && y(a) && y(o) && a > 0 && o > 0 ? { left: n, top: r, width: a, height: o } : void 0;
|
|
3239
3259
|
}
|
|
3240
|
-
function
|
|
3260
|
+
function mt(e) {
|
|
3241
3261
|
if (typeof e.sectionId != "string" || !Number.isSafeInteger(e.version)) return;
|
|
3242
|
-
const t =
|
|
3262
|
+
const t = Rt(e.element), n = In(e.area);
|
|
3243
3263
|
return {
|
|
3244
3264
|
sectionId: e.sectionId,
|
|
3245
3265
|
version: e.version,
|
|
@@ -3250,261 +3270,261 @@ function ut(e) {
|
|
|
3250
3270
|
...n ? { area: n } : {}
|
|
3251
3271
|
};
|
|
3252
3272
|
}
|
|
3253
|
-
function
|
|
3254
|
-
const n =
|
|
3273
|
+
function go(e, t) {
|
|
3274
|
+
const n = O(!1);
|
|
3255
3275
|
let r = null;
|
|
3256
3276
|
const a = /* @__PURE__ */ new Map();
|
|
3257
|
-
let
|
|
3258
|
-
const
|
|
3259
|
-
function
|
|
3260
|
-
var
|
|
3261
|
-
return ((
|
|
3262
|
-
}
|
|
3263
|
-
function
|
|
3264
|
-
var
|
|
3265
|
-
(
|
|
3266
|
-
}
|
|
3267
|
-
function u(
|
|
3268
|
-
var
|
|
3269
|
-
const
|
|
3270
|
-
if (!
|
|
3271
|
-
const g =
|
|
3277
|
+
let o;
|
|
3278
|
+
const y = /* @__PURE__ */ new Map();
|
|
3279
|
+
function x() {
|
|
3280
|
+
var m;
|
|
3281
|
+
return ((m = e.value) == null ? void 0 : m.contentWindow) ?? null;
|
|
3282
|
+
}
|
|
3283
|
+
function w(m) {
|
|
3284
|
+
var k;
|
|
3285
|
+
(k = x()) == null || k.postMessage(JSON.parse(JSON.stringify(m)), "*");
|
|
3286
|
+
}
|
|
3287
|
+
function u(m) {
|
|
3288
|
+
var H, V, K, ne;
|
|
3289
|
+
const k = x();
|
|
3290
|
+
if (!k || m.source !== k) return;
|
|
3291
|
+
const g = m.data;
|
|
3272
3292
|
if (!(!g || typeof g != "object"))
|
|
3273
3293
|
switch (g.type) {
|
|
3274
3294
|
case "ready":
|
|
3275
3295
|
if (n.value) return;
|
|
3276
|
-
|
|
3296
|
+
o = g.nonce, n.value = !0, r == null || r(), r = null, F();
|
|
3277
3297
|
break;
|
|
3278
3298
|
case "sectionSelected": {
|
|
3279
|
-
if (!
|
|
3280
|
-
const
|
|
3281
|
-
if (!
|
|
3282
|
-
const { area:
|
|
3283
|
-
(
|
|
3299
|
+
if (!o || g.nonce !== o) return;
|
|
3300
|
+
const ae = mt(g);
|
|
3301
|
+
if (!ae) return;
|
|
3302
|
+
const { area: ee, ...ve } = ae, ue = Array.isArray(g.widen) ? g.widen.slice(0, 4).map(Rt).filter((ye) => !!ye) : [];
|
|
3303
|
+
(H = t.onSelectSection) == null || H.call(t, ve, ue);
|
|
3284
3304
|
break;
|
|
3285
3305
|
}
|
|
3286
3306
|
case "areaSelected": {
|
|
3287
|
-
if (!
|
|
3288
|
-
const
|
|
3289
|
-
|
|
3307
|
+
if (!o || g.nonce !== o || !Array.isArray(g.picks)) return;
|
|
3308
|
+
const ae = g.picks.slice(0, 64).map((ee) => ee && typeof ee == "object" ? mt(ee) : void 0).filter((ee) => !!ee);
|
|
3309
|
+
ae.length && ((V = t.onSelectArea) == null || V.call(t, ae));
|
|
3290
3310
|
break;
|
|
3291
3311
|
}
|
|
3292
3312
|
case "selectionCancelled":
|
|
3293
|
-
|
|
3313
|
+
o && g.nonce === o && ((K = t.onCancelSelection) == null || K.call(t));
|
|
3294
3314
|
break;
|
|
3295
3315
|
case "setParams":
|
|
3296
3316
|
t.onSetParams(g.values ?? {}, g.intent);
|
|
3297
3317
|
break;
|
|
3298
3318
|
case "openLink":
|
|
3299
|
-
typeof g.href == "string" && ((
|
|
3319
|
+
typeof g.href == "string" && ((ne = t.onOpenLink) == null || ne.call(t, g.href));
|
|
3300
3320
|
break;
|
|
3301
3321
|
case "rendered":
|
|
3302
|
-
if (
|
|
3303
|
-
|
|
3322
|
+
if (!M(g)) return;
|
|
3323
|
+
h(g.sectionId, g.version), t.onSectionRendered(
|
|
3304
3324
|
g.sectionId,
|
|
3305
3325
|
g.version,
|
|
3306
3326
|
String(g.label ?? "").slice(0, 120)
|
|
3307
3327
|
);
|
|
3308
3328
|
break;
|
|
3309
3329
|
case "error":
|
|
3310
|
-
if (
|
|
3311
|
-
|
|
3330
|
+
if (!M(g)) return;
|
|
3331
|
+
h(g.sectionId, g.version), t.onSectionError(g.sectionId, g.version, g.message);
|
|
3312
3332
|
break;
|
|
3313
3333
|
case "layout":
|
|
3314
|
-
if (
|
|
3334
|
+
if (!M(g)) return;
|
|
3315
3335
|
t.onSectionLayout(
|
|
3316
3336
|
g.sectionId,
|
|
3317
3337
|
g.version,
|
|
3318
|
-
(Array.isArray(g.warnings) ? g.warnings : []).slice(0, 12).map((
|
|
3338
|
+
(Array.isArray(g.warnings) ? g.warnings : []).slice(0, 12).map((ae) => String(ae).slice(0, 200))
|
|
3319
3339
|
);
|
|
3320
3340
|
break;
|
|
3321
3341
|
}
|
|
3322
3342
|
}
|
|
3323
|
-
function
|
|
3324
|
-
return !
|
|
3343
|
+
function M(m) {
|
|
3344
|
+
return !o || m.nonce === o ? !0 : (console.warn("[report-canvas] dropped a render outcome without the shell nonce"), !1);
|
|
3325
3345
|
}
|
|
3326
|
-
function
|
|
3327
|
-
return `${
|
|
3346
|
+
function z(m, k) {
|
|
3347
|
+
return `${m}@${k}`;
|
|
3328
3348
|
}
|
|
3329
|
-
function
|
|
3330
|
-
if (
|
|
3331
|
-
const g =
|
|
3332
|
-
|
|
3349
|
+
function h(m, k) {
|
|
3350
|
+
if (k === void 0) return;
|
|
3351
|
+
const g = z(m, k), H = y.get(g);
|
|
3352
|
+
H !== void 0 && (clearTimeout(H), y.delete(g));
|
|
3333
3353
|
}
|
|
3334
|
-
function
|
|
3335
|
-
|
|
3354
|
+
function _() {
|
|
3355
|
+
y.forEach((m) => clearTimeout(m)), y.clear();
|
|
3336
3356
|
}
|
|
3337
|
-
function
|
|
3338
|
-
for (const
|
|
3339
|
-
const g =
|
|
3340
|
-
|
|
3357
|
+
function I(m) {
|
|
3358
|
+
for (const k of m) {
|
|
3359
|
+
const g = z(k.id, k.version);
|
|
3360
|
+
y.has(g) || y.set(
|
|
3341
3361
|
g,
|
|
3342
3362
|
setTimeout(() => {
|
|
3343
|
-
|
|
3344
|
-
|
|
3345
|
-
|
|
3346
|
-
`the section did not report a render within ${
|
|
3363
|
+
y.delete(g), t.onSectionError(
|
|
3364
|
+
k.id,
|
|
3365
|
+
k.version,
|
|
3366
|
+
`the section did not report a render within ${dt}ms`
|
|
3347
3367
|
);
|
|
3348
|
-
},
|
|
3368
|
+
}, dt)
|
|
3349
3369
|
);
|
|
3350
3370
|
}
|
|
3351
3371
|
}
|
|
3352
|
-
async function
|
|
3353
|
-
const
|
|
3354
|
-
|
|
3372
|
+
async function L(m, k, g) {
|
|
3373
|
+
const H = await st(m.flatMap((K) => K.libs ?? [])), V = () => {
|
|
3374
|
+
w({
|
|
3355
3375
|
type: "init",
|
|
3356
|
-
sections:
|
|
3357
|
-
params:
|
|
3358
|
-
paramDecls:
|
|
3359
|
-
intent:
|
|
3360
|
-
libs:
|
|
3376
|
+
sections: m,
|
|
3377
|
+
params: k.values,
|
|
3378
|
+
paramDecls: k.decls,
|
|
3379
|
+
intent: k.intent,
|
|
3380
|
+
libs: H,
|
|
3361
3381
|
env: g
|
|
3362
|
-
}),
|
|
3382
|
+
}), _(), I(m);
|
|
3363
3383
|
};
|
|
3364
|
-
n.value ?
|
|
3384
|
+
n.value ? V() : r = V;
|
|
3365
3385
|
}
|
|
3366
|
-
async function
|
|
3367
|
-
const
|
|
3368
|
-
|
|
3386
|
+
async function R(m) {
|
|
3387
|
+
const k = await st(m.flatMap((g) => g.libs ?? []));
|
|
3388
|
+
w({ type: "sections", sections: m, libs: k }), I(m);
|
|
3369
3389
|
}
|
|
3370
|
-
function
|
|
3371
|
-
|
|
3390
|
+
function E(m) {
|
|
3391
|
+
w({
|
|
3372
3392
|
type: "params",
|
|
3373
|
-
values:
|
|
3374
|
-
paramDecls:
|
|
3375
|
-
intent:
|
|
3393
|
+
values: m.values,
|
|
3394
|
+
paramDecls: m.decls,
|
|
3395
|
+
intent: m.intent
|
|
3376
3396
|
});
|
|
3377
3397
|
}
|
|
3378
|
-
function
|
|
3379
|
-
|
|
3398
|
+
function P(m) {
|
|
3399
|
+
w({ type: "env", env: m });
|
|
3380
3400
|
}
|
|
3381
|
-
function
|
|
3382
|
-
const
|
|
3383
|
-
a.clear(),
|
|
3401
|
+
function F() {
|
|
3402
|
+
const m = [...a.values()];
|
|
3403
|
+
a.clear(), m.forEach(G);
|
|
3384
3404
|
}
|
|
3385
|
-
function
|
|
3386
|
-
|
|
3405
|
+
function G(m) {
|
|
3406
|
+
w({
|
|
3387
3407
|
type: "rows",
|
|
3388
|
-
queryId:
|
|
3389
|
-
runId:
|
|
3390
|
-
rows:
|
|
3391
|
-
status:
|
|
3392
|
-
truncated:
|
|
3393
|
-
total:
|
|
3394
|
-
error:
|
|
3408
|
+
queryId: m.queryId,
|
|
3409
|
+
runId: m.runId,
|
|
3410
|
+
rows: m.rows,
|
|
3411
|
+
status: m.status,
|
|
3412
|
+
truncated: m.truncated,
|
|
3413
|
+
total: m.total,
|
|
3414
|
+
error: m.error
|
|
3395
3415
|
});
|
|
3396
3416
|
}
|
|
3397
|
-
function
|
|
3417
|
+
function Y(m) {
|
|
3398
3418
|
if (!n.value) {
|
|
3399
|
-
a.set(
|
|
3419
|
+
a.set(m.queryId, m);
|
|
3400
3420
|
return;
|
|
3401
3421
|
}
|
|
3402
|
-
|
|
3422
|
+
G(m);
|
|
3403
3423
|
}
|
|
3404
|
-
|
|
3405
|
-
window.removeEventListener("message", u),
|
|
3424
|
+
Pe(() => window.addEventListener("message", u)), Le(() => {
|
|
3425
|
+
window.removeEventListener("message", u), _();
|
|
3406
3426
|
});
|
|
3407
|
-
function
|
|
3408
|
-
n.value = !1, r = null,
|
|
3427
|
+
function Q() {
|
|
3428
|
+
n.value = !1, r = null, o = void 0, a.clear(), _();
|
|
3409
3429
|
}
|
|
3410
3430
|
return {
|
|
3411
3431
|
/** `multiple`: a click adds a part and picking goes on, and a drag draws an area. */
|
|
3412
|
-
setCommentMode: (
|
|
3432
|
+
setCommentMode: (m, k, g = !1) => w({
|
|
3413
3433
|
type: "commentMode",
|
|
3414
|
-
enabled:
|
|
3434
|
+
enabled: m,
|
|
3415
3435
|
multiple: g,
|
|
3416
|
-
picks: (Array.isArray(
|
|
3417
|
-
var
|
|
3436
|
+
picks: (Array.isArray(k) ? k : k ? [k] : []).map((H) => {
|
|
3437
|
+
var V, K, ne;
|
|
3418
3438
|
return {
|
|
3419
|
-
sectionId:
|
|
3420
|
-
part: (
|
|
3421
|
-
path: ((K =
|
|
3422
|
-
datum: ((
|
|
3423
|
-
datasetIndex:
|
|
3424
|
-
index:
|
|
3439
|
+
sectionId: H.sectionId,
|
|
3440
|
+
part: (V = H.element) == null ? void 0 : V.part,
|
|
3441
|
+
path: ((K = H.element) == null ? void 0 : K.path) ?? [],
|
|
3442
|
+
datum: ((ne = H.element) == null ? void 0 : ne.datum) && {
|
|
3443
|
+
datasetIndex: H.element.datum.datasetIndex,
|
|
3444
|
+
index: H.element.datum.index
|
|
3425
3445
|
},
|
|
3426
|
-
area:
|
|
3446
|
+
area: H.area
|
|
3427
3447
|
};
|
|
3428
3448
|
})
|
|
3429
3449
|
}),
|
|
3430
3450
|
ready: n,
|
|
3431
|
-
init:
|
|
3432
|
-
swapSections:
|
|
3433
|
-
pushParams:
|
|
3434
|
-
pushEnv:
|
|
3435
|
-
pushRows:
|
|
3436
|
-
reset:
|
|
3451
|
+
init: L,
|
|
3452
|
+
swapSections: R,
|
|
3453
|
+
pushParams: E,
|
|
3454
|
+
pushEnv: P,
|
|
3455
|
+
pushRows: Y,
|
|
3456
|
+
reset: Q
|
|
3437
3457
|
};
|
|
3438
3458
|
}
|
|
3439
|
-
const
|
|
3440
|
-
function
|
|
3459
|
+
const An = /^(?:https?:\/\/|mailto:)[^\s]+$/i, We = /`([^`]+)`|(!?)\[([^\]]*)\]\(([^)\s]*)\)|\*\*([\s\S]+?)\*\*|\*([^*\n]+)\*/g;
|
|
3460
|
+
function Ge(e, t) {
|
|
3441
3461
|
if (!t) return;
|
|
3442
3462
|
const n = e[e.length - 1];
|
|
3443
3463
|
(n == null ? void 0 : n.type) === "text" ? n.text += t : e.push({ type: "text", text: t });
|
|
3444
3464
|
}
|
|
3445
|
-
function
|
|
3465
|
+
function Ye(e) {
|
|
3446
3466
|
const t = [];
|
|
3447
3467
|
let n = 0;
|
|
3448
|
-
|
|
3449
|
-
for (let r =
|
|
3450
|
-
|
|
3451
|
-
const [, a,
|
|
3452
|
-
a !== void 0 ? t.push({ type: "code", text: a }) :
|
|
3468
|
+
We.lastIndex = 0;
|
|
3469
|
+
for (let r = We.exec(e); r; r = We.exec(e)) {
|
|
3470
|
+
Ge(t, e.slice(n, r.index)), n = r.index + r[0].length;
|
|
3471
|
+
const [, a, o, y, x, w, u] = r;
|
|
3472
|
+
a !== void 0 ? t.push({ type: "code", text: a }) : y !== void 0 ? !o && An.test(x) ? t.push({ type: "link", text: y || x, href: x }) : Ge(t, r[0]) : w !== void 0 ? t.push({ type: "strong", text: w }) : u !== void 0 && t.push({ type: "em", text: u });
|
|
3453
3473
|
}
|
|
3454
|
-
return
|
|
3474
|
+
return Ge(t, e.slice(n)), t;
|
|
3455
3475
|
}
|
|
3456
|
-
const
|
|
3457
|
-
function
|
|
3476
|
+
const Cn = /^\s*```/, Tn = /^\s{0,3}(#{1,6})\s+(.*)$/, En = /^\s*[-*+]\s+(.*)$/, On = /^\s*\d{1,3}[.)]\s+(.*)$/;
|
|
3477
|
+
function ut(e) {
|
|
3458
3478
|
const t = [], n = String(e ?? "").split(/\r?\n/);
|
|
3459
|
-
let r = [], a = null,
|
|
3460
|
-
function
|
|
3461
|
-
r.length && (t.push({ type: "p", inline:
|
|
3479
|
+
let r = [], a = null, o = null;
|
|
3480
|
+
function y() {
|
|
3481
|
+
r.length && (t.push({ type: "p", inline: Ye(r.join(" ")) }), r = []);
|
|
3462
3482
|
}
|
|
3463
|
-
function
|
|
3483
|
+
function x() {
|
|
3464
3484
|
a && (t.push({ type: "list", ordered: a.ordered, items: a.items }), a = null);
|
|
3465
3485
|
}
|
|
3466
|
-
function
|
|
3467
|
-
|
|
3486
|
+
function w() {
|
|
3487
|
+
y(), x();
|
|
3468
3488
|
}
|
|
3469
3489
|
for (const u of n) {
|
|
3470
|
-
if (
|
|
3471
|
-
|
|
3472
|
-
`) }),
|
|
3490
|
+
if (Cn.test(u)) {
|
|
3491
|
+
o ? (t.push({ type: "pre", text: o.join(`
|
|
3492
|
+
`) }), o = null) : (w(), o = []);
|
|
3473
3493
|
continue;
|
|
3474
3494
|
}
|
|
3475
|
-
if (
|
|
3476
|
-
|
|
3495
|
+
if (o) {
|
|
3496
|
+
o.push(u);
|
|
3477
3497
|
continue;
|
|
3478
3498
|
}
|
|
3479
|
-
const
|
|
3499
|
+
const M = Tn.exec(u), z = En.exec(u), h = On.exec(u);
|
|
3480
3500
|
if (!u.trim())
|
|
3481
|
-
|
|
3482
|
-
else if (
|
|
3483
|
-
|
|
3484
|
-
else if (
|
|
3485
|
-
|
|
3486
|
-
const
|
|
3487
|
-
(!a || a.ordered !==
|
|
3501
|
+
w();
|
|
3502
|
+
else if (M)
|
|
3503
|
+
w(), t.push({ type: "p", inline: Ye(M[2]), heading: !0 });
|
|
3504
|
+
else if (z || h) {
|
|
3505
|
+
y();
|
|
3506
|
+
const _ = !z;
|
|
3507
|
+
(!a || a.ordered !== _) && (x(), a = { ordered: _, items: [] }), a.items.push(Ye((z ?? h)[1]));
|
|
3488
3508
|
} else
|
|
3489
|
-
|
|
3509
|
+
x(), r.push(u.trim());
|
|
3490
3510
|
}
|
|
3491
|
-
return
|
|
3492
|
-
`) }),
|
|
3511
|
+
return o != null && o.length && t.push({ type: "pre", text: o.join(`
|
|
3512
|
+
`) }), w(), t;
|
|
3493
3513
|
}
|
|
3494
|
-
function
|
|
3514
|
+
function zn(e, t) {
|
|
3495
3515
|
const n = String(e ?? "").trim();
|
|
3496
3516
|
if (n.length <= t) return n;
|
|
3497
3517
|
const r = n.slice(0, t), a = r.lastIndexOf(" ");
|
|
3498
3518
|
return `${(a > t * 0.6 ? r.slice(0, a) : r).trimEnd()}…`;
|
|
3499
3519
|
}
|
|
3500
|
-
const
|
|
3520
|
+
const pt = 600, je = [
|
|
3501
3521
|
"reviewing",
|
|
3502
3522
|
"checking",
|
|
3503
3523
|
"updating",
|
|
3504
3524
|
"verifying",
|
|
3505
3525
|
"writing",
|
|
3506
3526
|
"loading"
|
|
3507
|
-
],
|
|
3527
|
+
], Nn = {
|
|
3508
3528
|
discovery: "reviewing",
|
|
3509
3529
|
grounding_probe: "reviewing",
|
|
3510
3530
|
option_probe: "reviewing",
|
|
@@ -3542,7 +3562,7 @@ const ht = 600, je = [
|
|
|
3542
3562
|
lazy_forced: "updating",
|
|
3543
3563
|
manifest_unbound: "updating",
|
|
3544
3564
|
rendered: "loading"
|
|
3545
|
-
},
|
|
3565
|
+
}, Rn = /* @__PURE__ */ new Set([
|
|
3546
3566
|
"plan",
|
|
3547
3567
|
"edit-target",
|
|
3548
3568
|
"error",
|
|
@@ -3553,64 +3573,64 @@ const ht = 600, je = [
|
|
|
3553
3573
|
"step",
|
|
3554
3574
|
"answer"
|
|
3555
3575
|
]);
|
|
3556
|
-
function
|
|
3557
|
-
return e &&
|
|
3576
|
+
function Mt(e) {
|
|
3577
|
+
return e && Nn[e] || "working";
|
|
3558
3578
|
}
|
|
3559
|
-
function
|
|
3579
|
+
function ht(e, t) {
|
|
3560
3580
|
const n = je.indexOf(t);
|
|
3561
3581
|
return n < 0 || e && je.indexOf(e) >= n ? e : t;
|
|
3562
3582
|
}
|
|
3563
|
-
function
|
|
3564
|
-
const t = new Set(e.map(
|
|
3583
|
+
function Mn(e) {
|
|
3584
|
+
const t = new Set(e.map(Mt));
|
|
3565
3585
|
return je.filter((n) => t.has(n));
|
|
3566
3586
|
}
|
|
3567
|
-
function
|
|
3587
|
+
function Pt(e) {
|
|
3568
3588
|
var n;
|
|
3569
3589
|
const t = [];
|
|
3570
3590
|
for (const r of e) {
|
|
3571
3591
|
const a = (n = r.data) == null ? void 0 : n.step;
|
|
3572
3592
|
if (r.type !== "data-step" || typeof a != "string") continue;
|
|
3573
|
-
const
|
|
3574
|
-
|
|
3593
|
+
const o = je.find((y) => y === a);
|
|
3594
|
+
o && !t.includes(o) && t.push(o);
|
|
3575
3595
|
}
|
|
3576
3596
|
return t;
|
|
3577
3597
|
}
|
|
3578
|
-
function
|
|
3579
|
-
return e ? e.steps.length ? e.steps :
|
|
3598
|
+
function Pn(e) {
|
|
3599
|
+
return e ? e.steps.length ? e.steps : Mn(e.signals) : [];
|
|
3580
3600
|
}
|
|
3581
|
-
function
|
|
3582
|
-
return
|
|
3601
|
+
function Ln(e) {
|
|
3602
|
+
return Pt((e == null ? void 0 : e.parts) ?? []).pop() ?? null;
|
|
3583
3603
|
}
|
|
3584
|
-
function
|
|
3604
|
+
function Xe(e) {
|
|
3585
3605
|
return e.filter((t) => t.type === "text").map((t) => String(t.text ?? "").trim()).filter(Boolean).join(`
|
|
3586
3606
|
|
|
3587
3607
|
`);
|
|
3588
3608
|
}
|
|
3589
|
-
function
|
|
3609
|
+
function jn(e) {
|
|
3590
3610
|
const t = [];
|
|
3591
3611
|
for (const n of e) {
|
|
3592
3612
|
const r = n.type.startsWith("tool-") || n.type.startsWith("data-") ? n.type.slice(5) : "";
|
|
3593
|
-
r && !
|
|
3613
|
+
r && !Rn.has(r) && t.push(r);
|
|
3594
3614
|
}
|
|
3595
3615
|
return t;
|
|
3596
3616
|
}
|
|
3597
|
-
function
|
|
3617
|
+
function $n(e) {
|
|
3598
3618
|
var r;
|
|
3599
3619
|
const t = e.find((a) => a.type === "data-turn_stats"), n = (r = t == null ? void 0 : t.data) == null ? void 0 : r.ms;
|
|
3600
3620
|
return typeof n == "number" && n >= 0 ? n : void 0;
|
|
3601
3621
|
}
|
|
3602
|
-
function
|
|
3622
|
+
function Dn(e) {
|
|
3603
3623
|
const t = Math.max(0, Math.floor(e / 1e3));
|
|
3604
3624
|
return t < 60 ? `${t}s` : `${Math.floor(t / 60)}m ${String(t % 60).padStart(2, "0")}s`;
|
|
3605
3625
|
}
|
|
3606
|
-
function
|
|
3626
|
+
function Bn(e) {
|
|
3607
3627
|
const t = e / 1e3;
|
|
3608
3628
|
return t < 60 ? `${t.toFixed(1)}s` : `${Math.floor(t / 60)}m ${String(Math.round(t % 60)).padStart(2, "0")}s`;
|
|
3609
3629
|
}
|
|
3610
|
-
function
|
|
3630
|
+
function qn(e) {
|
|
3611
3631
|
return e === "too_costly" || e === "timeout" ? "tooLarge" : e === "deadline" ? "outOfTime" : "ours";
|
|
3612
3632
|
}
|
|
3613
|
-
function
|
|
3633
|
+
function Vn(e) {
|
|
3614
3634
|
var n;
|
|
3615
3635
|
const t = (n = e.find((r) => r.type === "data-turn_failed")) == null ? void 0 : n.data;
|
|
3616
3636
|
if (t)
|
|
@@ -3619,36 +3639,36 @@ function Mn(e) {
|
|
|
3619
3639
|
...typeof t.ref == "string" ? { ref: t.ref } : {}
|
|
3620
3640
|
};
|
|
3621
3641
|
}
|
|
3622
|
-
function
|
|
3642
|
+
function Fn(e) {
|
|
3623
3643
|
return e.filter((t) => t.type === "data-edit-target").map((t) => t.data);
|
|
3624
3644
|
}
|
|
3625
|
-
function
|
|
3645
|
+
function Un(e) {
|
|
3626
3646
|
const t = [[]];
|
|
3627
3647
|
for (const n of e)
|
|
3628
3648
|
n.type === "step-start" ? t.push([]) : t[t.length - 1].push(n);
|
|
3629
3649
|
return t.filter((n) => n.length > 0);
|
|
3630
3650
|
}
|
|
3631
|
-
function
|
|
3651
|
+
function gt(e) {
|
|
3632
3652
|
return e.some((t) => t.type.startsWith("tool-"));
|
|
3633
3653
|
}
|
|
3634
|
-
function
|
|
3654
|
+
function Hn(e) {
|
|
3635
3655
|
var n;
|
|
3636
3656
|
const t = (n = e.find((r) => r.type === "data-answer")) == null ? void 0 : n.data;
|
|
3637
3657
|
return typeof (t == null ? void 0 : t.outcome) == "string" ? t.outcome : void 0;
|
|
3638
3658
|
}
|
|
3639
|
-
function
|
|
3659
|
+
function Wn(e, t = {}) {
|
|
3640
3660
|
var r, a;
|
|
3641
3661
|
const n = [];
|
|
3642
|
-
for (const
|
|
3643
|
-
const
|
|
3644
|
-
if (
|
|
3645
|
-
const
|
|
3662
|
+
for (const o of e ?? []) {
|
|
3663
|
+
const y = o.parts ?? [], x = jn(y), w = Fn(y);
|
|
3664
|
+
if (o.role === "user") {
|
|
3665
|
+
const E = Xe(y);
|
|
3646
3666
|
n.push({
|
|
3647
|
-
id:
|
|
3648
|
-
turnId:
|
|
3667
|
+
id: o.id,
|
|
3668
|
+
turnId: o.turnId ?? o.id,
|
|
3649
3669
|
role: "user",
|
|
3650
|
-
targets:
|
|
3651
|
-
answer:
|
|
3670
|
+
targets: w,
|
|
3671
|
+
answer: E,
|
|
3652
3672
|
blocks: [],
|
|
3653
3673
|
preview: null,
|
|
3654
3674
|
signals: [],
|
|
@@ -3658,88 +3678,88 @@ function $n(e, t = {}) {
|
|
|
3658
3678
|
});
|
|
3659
3679
|
continue;
|
|
3660
3680
|
}
|
|
3661
|
-
const u = !!t.streamingId &&
|
|
3662
|
-
if (
|
|
3663
|
-
const
|
|
3664
|
-
let
|
|
3681
|
+
const u = !!t.streamingId && o.id === t.streamingId;
|
|
3682
|
+
if (o.inProgress && !u) continue;
|
|
3683
|
+
const M = Un(y), z = M[M.length - 1] ?? [], h = M.some(gt), _ = h && !y.some((E) => E.type === "step-start");
|
|
3684
|
+
let I = "";
|
|
3665
3685
|
if (!u) {
|
|
3666
|
-
!
|
|
3667
|
-
const
|
|
3668
|
-
|
|
3669
|
-
}
|
|
3670
|
-
const
|
|
3671
|
-
!
|
|
3672
|
-
id:
|
|
3673
|
-
turnId:
|
|
3686
|
+
!h || _ ? I = Xe(y) : gt(z) || (I = Xe(z));
|
|
3687
|
+
const E = I ? void 0 : Hn(y);
|
|
3688
|
+
E && (I = ((r = t.outcomes) == null ? void 0 : r[E]) ?? "");
|
|
3689
|
+
}
|
|
3690
|
+
const L = !!I && (_ || I.length > pt), R = u ? void 0 : Vn(y);
|
|
3691
|
+
!I && !x.length && !u || n.push({
|
|
3692
|
+
id: o.id,
|
|
3693
|
+
turnId: o.turnId ?? o.id,
|
|
3674
3694
|
role: "assistant",
|
|
3675
|
-
targets:
|
|
3676
|
-
answer:
|
|
3677
|
-
blocks:
|
|
3678
|
-
preview:
|
|
3679
|
-
signals:
|
|
3680
|
-
steps:
|
|
3695
|
+
targets: w,
|
|
3696
|
+
answer: I,
|
|
3697
|
+
blocks: I ? ut(I) : [],
|
|
3698
|
+
preview: L ? ut(zn(I, pt)) : null,
|
|
3699
|
+
signals: x,
|
|
3700
|
+
steps: Pt(y),
|
|
3681
3701
|
pending: u,
|
|
3682
|
-
noSummary: !u && !
|
|
3683
|
-
ms: u ? void 0 :
|
|
3684
|
-
...
|
|
3702
|
+
noSummary: !u && !I && h,
|
|
3703
|
+
ms: u ? void 0 : $n(y) ?? ((a = o.stats) == null ? void 0 : a.ms),
|
|
3704
|
+
...R ? { failure: R } : {}
|
|
3685
3705
|
});
|
|
3686
3706
|
}
|
|
3687
3707
|
return n;
|
|
3688
3708
|
}
|
|
3689
|
-
const
|
|
3709
|
+
const Gn = {
|
|
3690
3710
|
key: 0,
|
|
3691
3711
|
class: "flex flex-col gap-4"
|
|
3692
|
-
},
|
|
3712
|
+
}, Yn = {
|
|
3693
3713
|
key: 0,
|
|
3694
3714
|
"data-testid": "report-canvas-activity",
|
|
3695
3715
|
class: "flex flex-col gap-4"
|
|
3696
|
-
},
|
|
3716
|
+
}, Xn = { class: "flex w-16 shrink-0 justify-center text-fm-color-system-success-300" }, Kn = { class: "min-w-0 truncate" }, Jn = { class: "flex items-start gap-8" }, Qn = { class: "min-w-0 grow" }, Zn = { class: "flex items-baseline gap-8" }, ea = {
|
|
3697
3717
|
class: "activity-shimmer fm-typo-en-body-md-400 min-w-0 grow",
|
|
3698
3718
|
role: "status"
|
|
3699
|
-
},
|
|
3719
|
+
}, ta = {
|
|
3700
3720
|
key: 0,
|
|
3701
3721
|
"data-testid": "report-canvas-elapsed",
|
|
3702
3722
|
class: "fm-typo-en-body-sm-400 shrink-0 tabular-nums text-fm-color-typo-secondary"
|
|
3703
|
-
},
|
|
3723
|
+
}, na = {
|
|
3704
3724
|
key: 0,
|
|
3705
3725
|
"data-testid": "report-canvas-prepared",
|
|
3706
3726
|
class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary"
|
|
3707
|
-
},
|
|
3727
|
+
}, aa = {
|
|
3708
3728
|
key: 1,
|
|
3709
3729
|
"data-testid": "report-canvas-slow",
|
|
3710
3730
|
class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary"
|
|
3711
|
-
},
|
|
3731
|
+
}, ra = {
|
|
3712
3732
|
key: 1,
|
|
3713
3733
|
"data-testid": "report-canvas-interrupted",
|
|
3714
3734
|
class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary"
|
|
3715
|
-
},
|
|
3735
|
+
}, oa = {
|
|
3716
3736
|
key: 2,
|
|
3717
3737
|
"data-testid": "report-canvas-stalled",
|
|
3718
3738
|
class: "flex flex-col items-start gap-4"
|
|
3719
|
-
},
|
|
3739
|
+
}, ia = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-error" }, sa = {
|
|
3720
3740
|
key: 3,
|
|
3721
3741
|
"data-testid": "report-canvas-failed",
|
|
3722
3742
|
class: "flex flex-col gap-4"
|
|
3723
|
-
},
|
|
3743
|
+
}, la = { class: "min-w-0 grow" }, fa = { class: "fm-typo-en-body-sm-600 truncate" }, da = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary" }, ca = ["onClick"], ma = ["onClick"], ua = {
|
|
3724
3744
|
key: 4,
|
|
3725
3745
|
class: "fm-typo-en-body-sm-400 text-fm-color-typo-error"
|
|
3726
|
-
},
|
|
3746
|
+
}, pa = { key: 5 }, ha = ["aria-expanded"], ga = {
|
|
3727
3747
|
key: 0,
|
|
3728
3748
|
"data-testid": "report-canvas-details",
|
|
3729
3749
|
class: "mt-4 flex flex-col gap-4"
|
|
3730
|
-
},
|
|
3750
|
+
}, ba = { class: "flex w-16 shrink-0 justify-center text-fm-color-system-success-300" }, va = ["title"], ya = {
|
|
3731
3751
|
class: "flex w-16 shrink-0 justify-center",
|
|
3732
3752
|
"aria-hidden": "true"
|
|
3733
|
-
},
|
|
3753
|
+
}, xa = {
|
|
3734
3754
|
key: 2,
|
|
3735
3755
|
class: "h-12 w-12 animate-spin rounded-full border-2 border-fm-color-neutral-gray-200 border-t-fm-color-primary motion-reduce:animate-none"
|
|
3736
|
-
},
|
|
3756
|
+
}, wa = { class: "min-w-0 grow truncate" }, ka = {
|
|
3737
3757
|
key: 0,
|
|
3738
3758
|
class: "shrink-0 text-fm-color-typo-error"
|
|
3739
|
-
},
|
|
3759
|
+
}, _a = {
|
|
3740
3760
|
key: 1,
|
|
3741
3761
|
class: "sr-only"
|
|
3742
|
-
},
|
|
3762
|
+
}, Sa = /* @__PURE__ */ $e({
|
|
3743
3763
|
__name: "ReportCanvasActivity",
|
|
3744
3764
|
props: {
|
|
3745
3765
|
active: { type: Boolean },
|
|
@@ -3754,174 +3774,174 @@ const Dn = {
|
|
|
3754
3774
|
},
|
|
3755
3775
|
emits: ["retry", "askBuilder", "checkStatus"],
|
|
3756
3776
|
setup(e, { emit: t }) {
|
|
3757
|
-
const n = e, r = t, { t: a } = Be(),
|
|
3758
|
-
var
|
|
3759
|
-
return ((
|
|
3760
|
-
}),
|
|
3761
|
-
var
|
|
3762
|
-
return !!((
|
|
3763
|
-
}), u =
|
|
3764
|
-
const
|
|
3765
|
-
return
|
|
3766
|
-
}),
|
|
3767
|
-
let
|
|
3768
|
-
|
|
3777
|
+
const n = e, r = t, { t: a } = Be(), o = $(() => {
|
|
3778
|
+
var L;
|
|
3779
|
+
return ((L = n.run) == null ? void 0 : L.sections) ?? [];
|
|
3780
|
+
}), y = $(() => o.value.filter((L) => L.status === "ok").length), x = $(() => o.value.filter((L) => L.status === "error")), w = $(() => {
|
|
3781
|
+
var L;
|
|
3782
|
+
return !!((L = n.run) != null && L.runId) && n.run.status !== "running";
|
|
3783
|
+
}), u = $(() => {
|
|
3784
|
+
const L = n.phases.indexOf(n.phase);
|
|
3785
|
+
return L >= 0 ? n.phases.slice(0, L) : n.phases;
|
|
3786
|
+
}), M = O(Date.now());
|
|
3787
|
+
let z;
|
|
3788
|
+
ie(
|
|
3769
3789
|
() => n.active && n.startedAt != null,
|
|
3770
|
-
(
|
|
3771
|
-
window.clearInterval(
|
|
3772
|
-
|
|
3790
|
+
(L) => {
|
|
3791
|
+
window.clearInterval(z), z = void 0, L && (M.value = Date.now(), z = window.setInterval(() => {
|
|
3792
|
+
M.value = Date.now();
|
|
3773
3793
|
}, 1e3));
|
|
3774
3794
|
},
|
|
3775
3795
|
{ immediate: !0 }
|
|
3776
|
-
),
|
|
3777
|
-
const
|
|
3778
|
-
() => n.active && n.startedAt != null ?
|
|
3779
|
-
),
|
|
3780
|
-
() =>
|
|
3796
|
+
), Le(() => window.clearInterval(z));
|
|
3797
|
+
const h = $(
|
|
3798
|
+
() => n.active && n.startedAt != null ? Dn(M.value - n.startedAt) : ""
|
|
3799
|
+
), _ = O(!1), I = $(
|
|
3800
|
+
() => o.value.length > 0 || !n.active && n.phases.length > 0
|
|
3781
3801
|
);
|
|
3782
|
-
return (
|
|
3783
|
-
const
|
|
3784
|
-
return e.active || e.interrupted || e.stale || e.retryError ||
|
|
3785
|
-
e.active ? (
|
|
3786
|
-
(
|
|
3787
|
-
key:
|
|
3802
|
+
return (L, R) => {
|
|
3803
|
+
const E = Oe("FmIcon");
|
|
3804
|
+
return e.active || e.interrupted || e.stale || e.retryError || x.value.length || I.value ? (c(), p("div", Gn, [
|
|
3805
|
+
e.active ? (c(), p("ol", Yn, [
|
|
3806
|
+
(c(!0), p(fe, null, me(u.value, (P) => (c(), p("li", {
|
|
3807
|
+
key: P,
|
|
3788
3808
|
"data-testid": "report-canvas-step-done",
|
|
3789
3809
|
class: "fm-typo-en-body-sm-400 flex items-center gap-8 text-fm-color-typo-secondary"
|
|
3790
3810
|
}, [
|
|
3791
|
-
|
|
3792
|
-
|
|
3811
|
+
N("span", Xn, [
|
|
3812
|
+
Z(E, {
|
|
3793
3813
|
name: "check",
|
|
3794
3814
|
size: "sm"
|
|
3795
3815
|
})
|
|
3796
3816
|
]),
|
|
3797
|
-
|
|
3817
|
+
N("span", Kn, A(v(a)(`reportV5.reportAi.chat.phaseDone.${P}`)), 1)
|
|
3798
3818
|
]))), 128)),
|
|
3799
|
-
|
|
3800
|
-
|
|
3801
|
-
|
|
3819
|
+
N("li", Jn, [
|
|
3820
|
+
R[2] || (R[2] = N("span", { class: "flex h-[21px] w-16 shrink-0 items-center justify-center" }, [
|
|
3821
|
+
N("span", { class: "h-12 w-12 animate-spin rounded-full border-2 border-fm-color-neutral-gray-200 border-t-fm-color-primary motion-reduce:animate-none" })
|
|
3802
3822
|
], -1)),
|
|
3803
|
-
|
|
3804
|
-
|
|
3805
|
-
|
|
3806
|
-
|
|
3823
|
+
N("div", Qn, [
|
|
3824
|
+
N("div", Zn, [
|
|
3825
|
+
N("p", ea, A(v(a)(`reportV5.reportAi.chat.phase.${e.phase}`)), 1),
|
|
3826
|
+
h.value ? (c(), p("span", ta, A(h.value), 1)) : j("", !0)
|
|
3807
3827
|
]),
|
|
3808
|
-
|
|
3809
|
-
e.slow ? (
|
|
3828
|
+
o.value.length ? (c(), p("p", na, A(v(a)("reportV5.reportAi.build.prepared", { done: y.value, total: o.value.length })), 1)) : j("", !0),
|
|
3829
|
+
e.slow ? (c(), p("p", aa, A(v(a)("reportV5.reportAi.build.slow")) + " " + A(v(a)("reportV5.reportAi.build.safeToLeave")), 1)) : j("", !0)
|
|
3810
3830
|
])
|
|
3811
3831
|
])
|
|
3812
|
-
])) :
|
|
3813
|
-
e.interrupted ? (
|
|
3814
|
-
e.stale ? (
|
|
3815
|
-
|
|
3816
|
-
|
|
3832
|
+
])) : j("", !0),
|
|
3833
|
+
e.interrupted ? (c(), p("p", ra, A(v(a)("reportV5.reportAi.build.interrupted")), 1)) : j("", !0),
|
|
3834
|
+
e.stale ? (c(), p("div", oa, [
|
|
3835
|
+
N("p", ia, A(v(a)("reportV5.reportAi.build.stalled")), 1),
|
|
3836
|
+
N("button", {
|
|
3817
3837
|
class: "fm-typo-en-body-sm-600 text-fm-color-typo-secondary underline",
|
|
3818
|
-
onClick:
|
|
3819
|
-
},
|
|
3820
|
-
])) :
|
|
3821
|
-
|
|
3822
|
-
(
|
|
3823
|
-
key:
|
|
3838
|
+
onClick: R[0] || (R[0] = (P) => r("checkStatus"))
|
|
3839
|
+
}, A(v(a)("reportV5.reportAi.build.checkStatus")), 1)
|
|
3840
|
+
])) : j("", !0),
|
|
3841
|
+
x.value.length ? (c(), p("ul", sa, [
|
|
3842
|
+
(c(!0), p(fe, null, me(x.value, (P) => (c(), p("li", {
|
|
3843
|
+
key: P.id,
|
|
3824
3844
|
class: "flex items-start gap-8"
|
|
3825
3845
|
}, [
|
|
3826
|
-
|
|
3827
|
-
|
|
3828
|
-
|
|
3829
|
-
|
|
3846
|
+
N("div", la, [
|
|
3847
|
+
N("p", fa, A(P.title), 1),
|
|
3848
|
+
N("p", da, A(v(a)(
|
|
3849
|
+
P.retries ? "reportV5.reportAi.build.retriedWidget" : "reportV5.reportAi.build.failedWidget"
|
|
3830
3850
|
)), 1)
|
|
3831
3851
|
]),
|
|
3832
|
-
|
|
3852
|
+
w.value && !P.retries ? (c(), p("button", {
|
|
3833
3853
|
key: 0,
|
|
3834
3854
|
"data-testid": "report-canvas-retry",
|
|
3835
3855
|
class: "fm-typo-en-body-sm-600 shrink-0 text-fm-color-typo-secondary underline",
|
|
3836
|
-
onClick: (
|
|
3837
|
-
},
|
|
3856
|
+
onClick: (F) => r("retry", P.id)
|
|
3857
|
+
}, A(v(a)("reportV5.reportAi.build.retry")), 9, ca)) : w.value ? (c(), p("button", {
|
|
3838
3858
|
key: 1,
|
|
3839
3859
|
"data-testid": "report-canvas-ask-builder",
|
|
3840
3860
|
class: "fm-typo-en-body-sm-600 shrink-0 text-fm-color-typo-secondary underline",
|
|
3841
|
-
onClick: (
|
|
3842
|
-
},
|
|
3861
|
+
onClick: (F) => r("askBuilder", P.title)
|
|
3862
|
+
}, A(v(a)("reportV5.reportAi.build.askBuilder")), 9, ma)) : j("", !0)
|
|
3843
3863
|
]))), 128))
|
|
3844
|
-
])) :
|
|
3845
|
-
e.retryError ? (
|
|
3846
|
-
|
|
3847
|
-
|
|
3864
|
+
])) : j("", !0),
|
|
3865
|
+
e.retryError ? (c(), p("p", ua, A(v(a)("reportV5.reportAi.build.retryFailed")), 1)) : j("", !0),
|
|
3866
|
+
I.value ? (c(), p("div", pa, [
|
|
3867
|
+
N("button", {
|
|
3848
3868
|
"data-testid": "report-canvas-details-toggle",
|
|
3849
3869
|
class: "details-toggle fm-typo-en-body-sm-600 -ml-4 flex items-center gap-4 rounded-md py-2 pl-4 pr-8 text-fm-color-typo-secondary",
|
|
3850
|
-
"aria-expanded":
|
|
3851
|
-
onClick:
|
|
3870
|
+
"aria-expanded": _.value,
|
|
3871
|
+
onClick: R[1] || (R[1] = (P) => _.value = !_.value)
|
|
3852
3872
|
}, [
|
|
3853
|
-
|
|
3854
|
-
name:
|
|
3873
|
+
Z(E, {
|
|
3874
|
+
name: _.value ? "expand_more" : "chevron_right",
|
|
3855
3875
|
size: "sm"
|
|
3856
3876
|
}, null, 8, ["name"]),
|
|
3857
|
-
Ce(" " +
|
|
3858
|
-
], 8,
|
|
3859
|
-
|
|
3860
|
-
e.active ?
|
|
3861
|
-
key:
|
|
3877
|
+
Ce(" " + A(v(a)("reportV5.reportAi.build.details")), 1)
|
|
3878
|
+
], 8, ha),
|
|
3879
|
+
_.value ? (c(), p("div", ga, [
|
|
3880
|
+
e.active ? j("", !0) : (c(!0), p(fe, { key: 0 }, me(e.phases, (P) => (c(), p("p", {
|
|
3881
|
+
key: P,
|
|
3862
3882
|
class: "fm-typo-en-body-sm-400 flex items-center gap-8 text-fm-color-typo-secondary"
|
|
3863
3883
|
}, [
|
|
3864
|
-
|
|
3865
|
-
|
|
3884
|
+
N("span", ba, [
|
|
3885
|
+
Z(E, {
|
|
3866
3886
|
name: "check",
|
|
3867
3887
|
size: "sm"
|
|
3868
3888
|
})
|
|
3869
3889
|
]),
|
|
3870
|
-
Ce(" " +
|
|
3890
|
+
Ce(" " + A(v(a)(`reportV5.reportAi.chat.phaseDone.${P}`)), 1)
|
|
3871
3891
|
]))), 128)),
|
|
3872
|
-
(
|
|
3873
|
-
key:
|
|
3892
|
+
(c(!0), p(fe, null, me(o.value, (P) => (c(), p("p", {
|
|
3893
|
+
key: P.id,
|
|
3874
3894
|
"data-testid": "report-canvas-widget-state",
|
|
3875
3895
|
class: "fm-typo-en-body-sm-400 flex items-center gap-8 pl-24 text-fm-color-typo-secondary",
|
|
3876
|
-
title:
|
|
3896
|
+
title: v(a)(`reportV5.reportAi.build.state.${P.status}`)
|
|
3877
3897
|
}, [
|
|
3878
|
-
|
|
3879
|
-
|
|
3898
|
+
N("span", ya, [
|
|
3899
|
+
P.status === "ok" ? (c(), ge(E, {
|
|
3880
3900
|
key: 0,
|
|
3881
3901
|
name: "check",
|
|
3882
3902
|
size: "sm",
|
|
3883
3903
|
class: "text-fm-color-system-success-300"
|
|
3884
|
-
})) :
|
|
3904
|
+
})) : P.status === "error" ? (c(), ge(E, {
|
|
3885
3905
|
key: 1,
|
|
3886
3906
|
name: "close",
|
|
3887
3907
|
size: "sm",
|
|
3888
3908
|
class: "text-fm-color-typo-error"
|
|
3889
|
-
})) :
|
|
3909
|
+
})) : P.status === "building" ? (c(), p("span", xa)) : (c(), ge(E, {
|
|
3890
3910
|
key: 3,
|
|
3891
3911
|
name: "radio_button_unchecked",
|
|
3892
3912
|
size: "sm",
|
|
3893
3913
|
class: "text-fm-color-typo-tertiary"
|
|
3894
3914
|
}))
|
|
3895
3915
|
]),
|
|
3896
|
-
|
|
3897
|
-
|
|
3898
|
-
], 8,
|
|
3899
|
-
])) :
|
|
3900
|
-
])) :
|
|
3901
|
-
])) :
|
|
3916
|
+
N("span", wa, A(P.title), 1),
|
|
3917
|
+
P.status === "error" ? (c(), p("span", ka, A(v(a)("reportV5.reportAi.build.state.error")), 1)) : (c(), p("span", _a, A(v(a)(`reportV5.reportAi.build.state.${P.status}`)), 1))
|
|
3918
|
+
], 8, va))), 128))
|
|
3919
|
+
])) : j("", !0)
|
|
3920
|
+
])) : j("", !0)
|
|
3921
|
+
])) : j("", !0);
|
|
3902
3922
|
};
|
|
3903
3923
|
}
|
|
3904
|
-
}),
|
|
3924
|
+
}), bt = /* @__PURE__ */ Et(Sa, [["__scopeId", "data-v-d9511bdd"]]), Ia = { class: "flex flex-col items-stretch gap-8 px-[20px] pb-16 pt-12" }, Aa = {
|
|
3905
3925
|
key: 0,
|
|
3906
3926
|
"data-testid": "chat-edit-target-context",
|
|
3907
3927
|
class: "fm-typo-en-body-sm-400 line-clamp-1 text-fm-color-typo-secondary"
|
|
3908
|
-
},
|
|
3928
|
+
}, Ca = {
|
|
3909
3929
|
key: 1,
|
|
3910
3930
|
role: "alert",
|
|
3911
3931
|
class: "fm-typo-en-body-sm-400 text-fm-color-typo-error"
|
|
3912
|
-
},
|
|
3932
|
+
}, Ta = {
|
|
3913
3933
|
"data-testid": "report-canvas-chat-input",
|
|
3914
3934
|
class: "rounded-lg border border-fm-color-border-secondary bg-fm-color-neutral-white p-16 focus-within:border-fm-color-primary"
|
|
3915
|
-
},
|
|
3935
|
+
}, Ea = ["value", "placeholder", "aria-label"], Oa = { class: "mt-16 flex items-center gap-12" }, za = ["aria-label"], Na = {
|
|
3916
3936
|
key: 0,
|
|
3917
3937
|
class: "flex max-h-[96px] min-w-0 grow flex-wrap gap-4 overflow-y-auto"
|
|
3918
|
-
},
|
|
3938
|
+
}, Ra = { class: "fm-typo-en-body-sm-400 min-w-0 truncate" }, Ma = ["disabled", "aria-label", "onClick"], Pa = {
|
|
3919
3939
|
key: 1,
|
|
3920
3940
|
class: "fm-typo-en-body-sm-400 min-w-0 grow truncate"
|
|
3921
|
-
},
|
|
3941
|
+
}, La = {
|
|
3922
3942
|
key: 0,
|
|
3923
3943
|
"data-testid": "chat-edit-target-element"
|
|
3924
|
-
},
|
|
3944
|
+
}, ja = ["disabled", "aria-label"], $a = ["disabled", "aria-label", "title"], Da = ["disabled", "aria-label"], Ba = { class: "text-[12px] leading-16 text-fm-color-typo-secondary" }, vt = 21, qa = /* @__PURE__ */ $e({
|
|
3925
3945
|
__name: "ReportCanvasComposer",
|
|
3926
3946
|
props: {
|
|
3927
3947
|
draft: {},
|
|
@@ -3937,158 +3957,158 @@ const Dn = {
|
|
|
3937
3957
|
},
|
|
3938
3958
|
emits: ["update:draft", "submit", "clearTarget", "stop"],
|
|
3939
3959
|
setup(e, { expose: t, emit: n }) {
|
|
3940
|
-
const r = e, a = n, { t:
|
|
3941
|
-
function
|
|
3942
|
-
const
|
|
3943
|
-
|
|
3960
|
+
const r = e, a = n, { t: o } = Be(), y = vt * 2, x = vt * 6, w = O(), u = O(!1);
|
|
3961
|
+
function M() {
|
|
3962
|
+
const m = w.value;
|
|
3963
|
+
m && (m.style.height = "auto", m.style.height = `${Math.min(Math.max(m.scrollHeight, y), x)}px`);
|
|
3944
3964
|
}
|
|
3945
|
-
|
|
3965
|
+
Pe(M), ie(
|
|
3946
3966
|
() => r.draft,
|
|
3947
|
-
() => void
|
|
3967
|
+
() => void we(M)
|
|
3948
3968
|
);
|
|
3949
|
-
function
|
|
3950
|
-
a("update:draft",
|
|
3951
|
-
}
|
|
3952
|
-
function
|
|
3953
|
-
|
|
3954
|
-
}
|
|
3955
|
-
const
|
|
3956
|
-
function
|
|
3957
|
-
|
|
3958
|
-
}
|
|
3959
|
-
function
|
|
3960
|
-
var
|
|
3961
|
-
(
|
|
3962
|
-
}
|
|
3963
|
-
t({ focus:
|
|
3964
|
-
const
|
|
3965
|
-
function
|
|
3966
|
-
const
|
|
3967
|
-
if (!
|
|
3968
|
-
const g = (
|
|
3969
|
-
return g ? g.slice(0, 40) :
|
|
3970
|
-
}
|
|
3971
|
-
const
|
|
3972
|
-
function
|
|
3973
|
-
const
|
|
3974
|
-
return (
|
|
3975
|
-
}
|
|
3976
|
-
const
|
|
3977
|
-
() => !
|
|
3978
|
-
|
|
3969
|
+
function z(m) {
|
|
3970
|
+
a("update:draft", m.target.value);
|
|
3971
|
+
}
|
|
3972
|
+
function h(m) {
|
|
3973
|
+
m.key !== "Enter" || m.shiftKey || u.value || m.isComposing || (m.preventDefault(), I());
|
|
3974
|
+
}
|
|
3975
|
+
const _ = $(() => !!r.draft.trim() && !r.streaming && !r.targetStale);
|
|
3976
|
+
function I() {
|
|
3977
|
+
_.value && a("submit");
|
|
3978
|
+
}
|
|
3979
|
+
function L() {
|
|
3980
|
+
var m;
|
|
3981
|
+
(m = w.value) == null || m.focus();
|
|
3982
|
+
}
|
|
3983
|
+
t({ focus: L });
|
|
3984
|
+
const R = $(() => r.targets ?? (r.target ? [r.target] : [])), E = $(() => R.value.length === 1 ? R.value[0] : void 0);
|
|
3985
|
+
function P(m) {
|
|
3986
|
+
const k = m == null ? void 0 : m.element;
|
|
3987
|
+
if (!k) return "";
|
|
3988
|
+
const g = (k.text || "").trim();
|
|
3989
|
+
return g ? g.slice(0, 40) : k.part || k.tag;
|
|
3990
|
+
}
|
|
3991
|
+
const F = $(() => P(E.value));
|
|
3992
|
+
function G(m) {
|
|
3993
|
+
const k = P(m);
|
|
3994
|
+
return (m.label || o("reportV5.reportAi.chat.selectedWidget")) + (k ? " › " + k : "");
|
|
3995
|
+
}
|
|
3996
|
+
const Y = $(
|
|
3997
|
+
() => !R.value.length && r.placeholder || o(
|
|
3998
|
+
R.value.length ? "reportV5.reportAi.chat.commentPlaceholder" : r.blank ? "reportV5.reportAi.chat.placeholderNew" : "reportV5.reportAi.chat.placeholderChange"
|
|
3979
3999
|
)
|
|
3980
|
-
),
|
|
3981
|
-
return (
|
|
3982
|
-
var
|
|
4000
|
+
), Q = $(() => r.targetLabel ?? o("reportV5.reportAi.chat.entireReport"));
|
|
4001
|
+
return (m, k) => {
|
|
4002
|
+
var H;
|
|
3983
4003
|
const g = Oe("FmIcon");
|
|
3984
|
-
return
|
|
3985
|
-
(
|
|
3986
|
-
e.targetStale && !e.streaming ? (
|
|
3987
|
-
|
|
3988
|
-
|
|
4004
|
+
return c(), p("div", Ia, [
|
|
4005
|
+
(H = E.value) != null && H.elementText ? (c(), p("p", Aa, " “" + A(E.value.elementText) + "” ", 1)) : j("", !0),
|
|
4006
|
+
e.targetStale && !e.streaming ? (c(), p("p", Ca, A(v(o)("reportV5.reportAi.chat.staleTarget")), 1)) : j("", !0),
|
|
4007
|
+
N("div", Ta, [
|
|
4008
|
+
N("textarea", {
|
|
3989
4009
|
ref_key: "field",
|
|
3990
|
-
ref:
|
|
4010
|
+
ref: w,
|
|
3991
4011
|
value: e.draft,
|
|
3992
|
-
placeholder:
|
|
3993
|
-
"aria-label":
|
|
4012
|
+
placeholder: Y.value,
|
|
4013
|
+
"aria-label": Y.value,
|
|
3994
4014
|
rows: "2",
|
|
3995
4015
|
class: "fm-typo-en-body-md-400 block w-full resize-none border-0 bg-transparent !leading-[21px] outline-none placeholder:text-fm-color-typo-secondary",
|
|
3996
|
-
onInput:
|
|
3997
|
-
onKeydown:
|
|
3998
|
-
onCompositionstart:
|
|
3999
|
-
onCompositionend:
|
|
4000
|
-
}, null, 40,
|
|
4001
|
-
|
|
4002
|
-
|
|
4016
|
+
onInput: z,
|
|
4017
|
+
onKeydown: h,
|
|
4018
|
+
onCompositionstart: k[0] || (k[0] = (V) => u.value = !0),
|
|
4019
|
+
onCompositionend: k[1] || (k[1] = (V) => u.value = !1)
|
|
4020
|
+
}, null, 40, Ea),
|
|
4021
|
+
N("div", Oa, [
|
|
4022
|
+
N("div", {
|
|
4003
4023
|
"data-testid": "chat-edit-target",
|
|
4004
4024
|
role: "status",
|
|
4005
|
-
"aria-label":
|
|
4025
|
+
"aria-label": R.value.length ? v(o)("reportV5.reportAi.chat.commentOn", { widget: R.value.map(G).join(", ") }) : Q.value,
|
|
4006
4026
|
class: "flex min-w-0 grow items-center gap-8 text-fm-color-typo-secondary"
|
|
4007
4027
|
}, [
|
|
4008
|
-
|
|
4009
|
-
name:
|
|
4028
|
+
Z(g, {
|
|
4029
|
+
name: R.value.length ? "mode_comment" : "dashboard",
|
|
4010
4030
|
size: "sm",
|
|
4011
4031
|
outline: ""
|
|
4012
4032
|
}, null, 8, ["name"]),
|
|
4013
|
-
|
|
4014
|
-
(
|
|
4033
|
+
R.value.length > 1 ? (c(), p("ul", Na, [
|
|
4034
|
+
(c(!0), p(fe, null, me(R.value, (V, K) => (c(), p("li", {
|
|
4015
4035
|
key: K,
|
|
4016
4036
|
"data-testid": "chat-edit-target-part",
|
|
4017
4037
|
class: "flex min-w-0 max-w-full items-center gap-4 rounded-sm bg-fm-color-neutral-gray-100 py-2 pl-8 pr-4"
|
|
4018
4038
|
}, [
|
|
4019
|
-
|
|
4020
|
-
|
|
4039
|
+
N("span", Ra, A(G(V)), 1),
|
|
4040
|
+
N("button", {
|
|
4021
4041
|
class: "flex shrink-0 items-center text-fm-color-typo-secondary disabled:opacity-50",
|
|
4022
4042
|
disabled: e.streaming,
|
|
4023
|
-
"aria-label":
|
|
4024
|
-
|
|
4043
|
+
"aria-label": v(o)(
|
|
4044
|
+
V.element && !V.area ? "reportV5.reportAi.chat.removeElement" : "reportV5.reportAi.chat.removeTarget"
|
|
4025
4045
|
),
|
|
4026
|
-
onClick: (
|
|
4046
|
+
onClick: (ne) => a("clearTarget", K)
|
|
4027
4047
|
}, [
|
|
4028
|
-
|
|
4048
|
+
Z(g, {
|
|
4029
4049
|
name: "close",
|
|
4030
4050
|
size: "sm"
|
|
4031
4051
|
})
|
|
4032
|
-
], 8,
|
|
4052
|
+
], 8, Ma)
|
|
4033
4053
|
]))), 128))
|
|
4034
|
-
])) : (
|
|
4035
|
-
Ce(
|
|
4036
|
-
|
|
4054
|
+
])) : (c(), p("p", Pa, [
|
|
4055
|
+
Ce(A(E.value ? E.value.label || v(o)("reportV5.reportAi.chat.selectedWidget") : Q.value), 1),
|
|
4056
|
+
F.value ? (c(), p("span", La, " › " + A(F.value), 1)) : j("", !0)
|
|
4037
4057
|
])),
|
|
4038
|
-
|
|
4058
|
+
E.value ? (c(), p("button", {
|
|
4039
4059
|
key: 2,
|
|
4040
4060
|
class: "flex shrink-0 items-center text-fm-color-typo-secondary disabled:opacity-50",
|
|
4041
4061
|
disabled: e.streaming,
|
|
4042
|
-
"aria-label":
|
|
4043
|
-
|
|
4062
|
+
"aria-label": v(o)(
|
|
4063
|
+
E.value.element && !E.value.area ? "reportV5.reportAi.chat.removeElement" : "reportV5.reportAi.chat.removeTarget"
|
|
4044
4064
|
),
|
|
4045
|
-
onClick:
|
|
4065
|
+
onClick: k[2] || (k[2] = (V) => a("clearTarget", 0))
|
|
4046
4066
|
}, [
|
|
4047
|
-
|
|
4067
|
+
Z(g, {
|
|
4048
4068
|
name: "close",
|
|
4049
4069
|
size: "sm"
|
|
4050
4070
|
})
|
|
4051
|
-
], 8,
|
|
4052
|
-
], 8,
|
|
4053
|
-
e.stoppable ? (
|
|
4071
|
+
], 8, ja)) : j("", !0)
|
|
4072
|
+
], 8, za),
|
|
4073
|
+
e.stoppable ? (c(), p("button", {
|
|
4054
4074
|
key: 0,
|
|
4055
4075
|
"data-testid": "report-canvas-chat-stop",
|
|
4056
4076
|
type: "button",
|
|
4057
4077
|
class: "flex h-[36px] w-[36px] shrink-0 items-center justify-center rounded-full bg-fm-color-primary text-fm-color-neutral-white transition-colors focus-visible:outline focus-visible:outline-2 focus-visible:outline-fm-color-primary disabled:cursor-not-allowed disabled:opacity-50",
|
|
4058
4078
|
disabled: e.stopping,
|
|
4059
|
-
"aria-label":
|
|
4060
|
-
title:
|
|
4061
|
-
onClick:
|
|
4079
|
+
"aria-label": v(o)(e.stopping ? "reportV5.reportAi.chat.stopping" : "reportV5.reportAi.chat.stop"),
|
|
4080
|
+
title: v(o)(e.stopping ? "reportV5.reportAi.chat.stopping" : "reportV5.reportAi.chat.stop"),
|
|
4081
|
+
onClick: k[3] || (k[3] = (V) => a("stop"))
|
|
4062
4082
|
}, [
|
|
4063
|
-
|
|
4083
|
+
Z(g, {
|
|
4064
4084
|
name: "stop",
|
|
4065
4085
|
size: "sm"
|
|
4066
4086
|
})
|
|
4067
|
-
], 8,
|
|
4087
|
+
], 8, $a)) : (c(), p("button", {
|
|
4068
4088
|
key: 1,
|
|
4069
4089
|
"data-testid": "report-canvas-chat-send",
|
|
4070
|
-
class:
|
|
4090
|
+
class: Ze([
|
|
4071
4091
|
"flex h-[36px] w-[36px] shrink-0 items-center justify-center rounded-full transition-colors focus-visible:outline focus-visible:outline-2 focus-visible:outline-fm-color-primary disabled:cursor-not-allowed",
|
|
4072
|
-
|
|
4092
|
+
_.value ? "bg-fm-color-primary text-fm-color-neutral-white" : "bg-fm-color-neutral-gray-100 text-fm-color-typo-secondary"
|
|
4073
4093
|
]),
|
|
4074
|
-
disabled: !
|
|
4075
|
-
"aria-label":
|
|
4076
|
-
onClick:
|
|
4094
|
+
disabled: !_.value,
|
|
4095
|
+
"aria-label": v(o)("reportV5.reportAi.chat.send"),
|
|
4096
|
+
onClick: I
|
|
4077
4097
|
}, [
|
|
4078
|
-
|
|
4098
|
+
Z(g, {
|
|
4079
4099
|
name: "arrow_forward",
|
|
4080
4100
|
size: "sm"
|
|
4081
4101
|
})
|
|
4082
|
-
], 10,
|
|
4102
|
+
], 10, Da))
|
|
4083
4103
|
])
|
|
4084
4104
|
]),
|
|
4085
|
-
|
|
4105
|
+
N("p", Ba, A(e.streaming && e.draft.trim() ? v(o)("reportV5.reportAi.chat.waitForUpdate") : v(o)("reportV5.reportAi.chat.newLineHint")), 1)
|
|
4086
4106
|
]);
|
|
4087
4107
|
};
|
|
4088
4108
|
}
|
|
4089
|
-
}),
|
|
4090
|
-
function
|
|
4091
|
-
return e.map((t) => t.type === "strong" ? ce("strong", { class: "font-semibold" }, t.text) : t.type === "em" ? ce("em", t.text) : t.type === "code" ? ce("code", { class:
|
|
4109
|
+
}), Va = "rounded-sm bg-fm-color-neutral-gray-100 px-4 font-mono text-[0.9em]";
|
|
4110
|
+
function yt(e) {
|
|
4111
|
+
return e.map((t) => t.type === "strong" ? ce("strong", { class: "font-semibold" }, t.text) : t.type === "em" ? ce("em", t.text) : t.type === "code" ? ce("code", { class: Va }, t.text) : t.type === "link" ? ce(
|
|
4092
4112
|
"a",
|
|
4093
4113
|
{
|
|
4094
4114
|
href: t.href,
|
|
@@ -4099,7 +4119,7 @@ function xt(e) {
|
|
|
4099
4119
|
t.text
|
|
4100
4120
|
) : t.text);
|
|
4101
4121
|
}
|
|
4102
|
-
const
|
|
4122
|
+
const Fa = (e) => ce(
|
|
4103
4123
|
"div",
|
|
4104
4124
|
{ class: "fm-typo-en-body-md-400 flex flex-col items-stretch gap-8 !leading-[21px]" },
|
|
4105
4125
|
(e.blocks ?? []).map((t) => t.type === "pre" ? ce(
|
|
@@ -4111,102 +4131,102 @@ const La = (e) => ce(
|
|
|
4111
4131
|
) : t.type === "list" ? ce(
|
|
4112
4132
|
t.ordered ? "ol" : "ul",
|
|
4113
4133
|
{ class: `flex flex-col gap-4 pl-16 ${t.ordered ? "list-decimal" : "list-disc"}` },
|
|
4114
|
-
t.items.map((n) => ce("li",
|
|
4134
|
+
t.items.map((n) => ce("li", yt(n)))
|
|
4115
4135
|
) : ce(
|
|
4116
4136
|
"p",
|
|
4117
4137
|
{ class: t.heading ? "fm-typo-en-body-md-600" : void 0 },
|
|
4118
|
-
|
|
4138
|
+
yt(t.inline)
|
|
4119
4139
|
))
|
|
4120
|
-
),
|
|
4140
|
+
), Ua = ["aria-expanded"], Ha = /* @__PURE__ */ $e({
|
|
4121
4141
|
__name: "ReportCanvasMessage",
|
|
4122
4142
|
props: {
|
|
4123
4143
|
blocks: {},
|
|
4124
4144
|
preview: {}
|
|
4125
4145
|
},
|
|
4126
4146
|
setup(e) {
|
|
4127
|
-
const t = e, { t: n } = Be(), r =
|
|
4128
|
-
return (
|
|
4129
|
-
|
|
4130
|
-
e.preview ? (
|
|
4147
|
+
const t = e, { t: n } = Be(), r = O(!0), a = $(() => t.preview && !r.value ? t.preview : t.blocks);
|
|
4148
|
+
return (o, y) => (c(), p("div", null, [
|
|
4149
|
+
Z(v(Fa), { blocks: a.value }, null, 8, ["blocks"]),
|
|
4150
|
+
e.preview ? (c(), p("button", {
|
|
4131
4151
|
key: 0,
|
|
4132
4152
|
"data-testid": "report-canvas-full-reply",
|
|
4133
4153
|
class: "fm-typo-en-body-sm-600 mt-4 text-fm-color-typo-secondary underline",
|
|
4134
4154
|
"aria-expanded": r.value,
|
|
4135
|
-
onClick:
|
|
4136
|
-
},
|
|
4155
|
+
onClick: y[0] || (y[0] = (x) => r.value = !r.value)
|
|
4156
|
+
}, A(v(n)(r.value ? "reportV5.reportAi.chat.showLess" : "reportV5.reportAi.chat.showFullReply")), 9, Ua)) : j("", !0)
|
|
4137
4157
|
]));
|
|
4138
4158
|
}
|
|
4139
|
-
}),
|
|
4159
|
+
}), Wa = ["aria-label"], Ga = { class: "flex h-64 shrink-0 items-center gap-12 border-b border-fm-color-border-secondary px-[20px]" }, Ya = { class: "min-w-0 grow" }, Xa = { class: "fm-typo-en-body-md-600" }, Ka = {
|
|
4140
4160
|
key: 0,
|
|
4141
4161
|
class: "fm-typo-en-body-sm-400 truncate text-fm-color-typo-secondary"
|
|
4142
|
-
},
|
|
4162
|
+
}, Ja = ["disabled", "aria-label"], Qa = ["disabled", "aria-label", "title"], Za = ["aria-label"], er = ["data-testid", "aria-label"], tr = {
|
|
4143
4163
|
key: 0,
|
|
4144
4164
|
class: "mt-auto flex shrink-0 flex-col gap-24 pb-8 pt-32"
|
|
4145
|
-
},
|
|
4165
|
+
}, nr = { class: "text-center" }, ar = { class: "text-[24px] font-semibold leading-tight tracking-tight text-fm-color-typo-primary" }, rr = { class: "fm-typo-en-body-sm-400 mt-12 text-fm-color-typo-secondary" }, or = {
|
|
4146
4166
|
key: 0,
|
|
4147
4167
|
class: "flex flex-col gap-4"
|
|
4148
|
-
},
|
|
4168
|
+
}, ir = ["disabled", "title", "onClick"], sr = ["aria-label"], lr = { class: "fm-typo-en-body-sm-600 mb-12 text-fm-color-typo-secondary" }, fr = {
|
|
4149
4169
|
key: 0,
|
|
4150
4170
|
class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary"
|
|
4151
|
-
},
|
|
4171
|
+
}, dr = {
|
|
4152
4172
|
key: 1,
|
|
4153
4173
|
"data-testid": "report-canvas-chat-list-error",
|
|
4154
4174
|
class: "fm-typo-en-body-sm-400 text-fm-color-typo-error"
|
|
4155
|
-
},
|
|
4175
|
+
}, cr = {
|
|
4156
4176
|
key: 2,
|
|
4157
4177
|
class: "fm-typo-en-body-sm-400 py-12 text-fm-color-typo-secondary"
|
|
4158
|
-
},
|
|
4178
|
+
}, mr = {
|
|
4159
4179
|
key: 0,
|
|
4160
4180
|
class: "fm-typo-en-body-sm-400 mb-8 text-fm-color-typo-secondary"
|
|
4161
|
-
},
|
|
4181
|
+
}, ur = ["disabled", "aria-current", "title", "onClick"], pr = { class: "fm-typo-en-body-md-400 min-w-0 grow truncate" }, hr = ["datetime"], gr = ["disabled"], br = ["disabled"], vr = {
|
|
4162
4182
|
key: 2,
|
|
4163
4183
|
"data-testid": "report-canvas-chat-error",
|
|
4164
4184
|
class: "fm-typo-en-body-sm-400 mt-12 text-fm-color-typo-error"
|
|
4165
|
-
},
|
|
4185
|
+
}, yr = {
|
|
4166
4186
|
key: 1,
|
|
4167
4187
|
class: "relative flex min-h-0 grow flex-col"
|
|
4168
|
-
},
|
|
4188
|
+
}, xr = {
|
|
4169
4189
|
key: 0,
|
|
4170
4190
|
"data-testid": "report-canvas-chat-loading",
|
|
4171
4191
|
class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary"
|
|
4172
|
-
},
|
|
4192
|
+
}, wr = ["disabled"], kr = {
|
|
4173
4193
|
key: 0,
|
|
4174
4194
|
"data-testid": "chat-message-target",
|
|
4175
4195
|
class: "fm-typo-en-body-sm-600 mb-4 text-right text-fm-color-typo-secondary"
|
|
4176
|
-
},
|
|
4196
|
+
}, _r = {
|
|
4177
4197
|
key: 1,
|
|
4178
4198
|
class: "flex flex-col items-end"
|
|
4179
|
-
},
|
|
4199
|
+
}, Sr = {
|
|
4180
4200
|
key: 0,
|
|
4181
4201
|
"data-testid": "chat-message-unsent",
|
|
4182
4202
|
class: "fm-typo-en-body-sm-400 mt-4 text-fm-color-typo-secondary"
|
|
4183
|
-
},
|
|
4203
|
+
}, Ir = ["disabled", "onClick"], Ar = {
|
|
4184
4204
|
key: 1,
|
|
4185
4205
|
"data-testid": "chat-message-no-reply",
|
|
4186
4206
|
class: "fm-typo-en-body-sm-400 mt-4 max-w-[90%] text-right text-fm-color-typo-secondary"
|
|
4187
|
-
},
|
|
4207
|
+
}, Cr = ["disabled", "onClick"], Tr = ["disabled", "onClick"], Er = {
|
|
4188
4208
|
key: 1,
|
|
4189
4209
|
"data-testid": "report-canvas-failure",
|
|
4190
4210
|
class: "rounded-md border border-fm-color-border-secondary px-12 py-12"
|
|
4191
|
-
},
|
|
4211
|
+
}, Or = { class: "fm-typo-en-body-md-600 flex items-center gap-8" }, zr = { class: "fm-typo-en-body-sm-400 mt-4 text-fm-color-typo-secondary" }, Nr = {
|
|
4192
4212
|
key: 0,
|
|
4193
4213
|
class: "mt-12 flex flex-wrap gap-8"
|
|
4194
|
-
},
|
|
4214
|
+
}, Rr = {
|
|
4195
4215
|
key: 1,
|
|
4196
4216
|
"data-testid": "report-canvas-failure-ref",
|
|
4197
4217
|
class: "fm-typo-en-body-sm-400 mt-8 text-fm-color-typo-tertiary"
|
|
4198
|
-
},
|
|
4218
|
+
}, Mr = {
|
|
4199
4219
|
key: 3,
|
|
4200
4220
|
class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary"
|
|
4201
|
-
},
|
|
4221
|
+
}, Pr = {
|
|
4202
4222
|
key: 4,
|
|
4203
4223
|
"data-testid": "report-canvas-answer-duration",
|
|
4204
4224
|
class: "fm-typo-en-body-sm-400 mt-4 text-fm-color-typo-secondary"
|
|
4205
|
-
},
|
|
4225
|
+
}, Lr = {
|
|
4206
4226
|
key: 2,
|
|
4207
4227
|
"data-testid": "report-canvas-chat-error",
|
|
4208
4228
|
class: "fm-typo-en-body-md-400 text-fm-color-typo-error"
|
|
4209
|
-
},
|
|
4229
|
+
}, jr = { class: "shrink-0" }, xt = "New chat", $r = 1440 * 60 * 1e3, Dr = 80, Br = /* @__PURE__ */ $e({
|
|
4210
4230
|
__name: "ReportCanvasChatPanel",
|
|
4211
4231
|
props: /* @__PURE__ */ it({
|
|
4212
4232
|
messages: {},
|
|
@@ -4252,559 +4272,559 @@ const La = (e) => ce(
|
|
|
4252
4272
|
}),
|
|
4253
4273
|
emits: /* @__PURE__ */ it(["update:draft", "submit", "close", "retry", "undo", "resend", "askAgain", "editRequest", "askBuilder", "checkStatus", "clearTarget", "newChat", "selectChat", "loadChats", "loadMoreChats", "loadEarlier", "stop"], ["update:homeOpen", "update:homeDraft"]),
|
|
4254
4274
|
setup(e, { emit: t }) {
|
|
4255
|
-
const n = e, r = t, { t: a, locale:
|
|
4256
|
-
var
|
|
4257
|
-
return ((
|
|
4258
|
-
}),
|
|
4259
|
-
() => !n.chatTitle || n.chatTitle ===
|
|
4260
|
-
),
|
|
4261
|
-
|
|
4275
|
+
const n = e, r = t, { t: a, locale: o } = Be(), y = $(() => {
|
|
4276
|
+
var l;
|
|
4277
|
+
return ((l = n.copy) == null ? void 0 : l.title) ?? a("reportV5.reportAi.chat.title");
|
|
4278
|
+
}), x = rt(e, "homeOpen"), w = O(!1), u = rt(e, "homeDraft"), M = O(!1), z = $(
|
|
4279
|
+
() => !n.chatTitle || n.chatTitle === xt ? a("reportV5.reportAi.chat.chats") : n.chatTitle
|
|
4280
|
+
), h = O(!1), _ = $(() => n.switching || h.value);
|
|
4281
|
+
ie(
|
|
4262
4282
|
() => n.messages,
|
|
4263
4283
|
() => {
|
|
4264
|
-
|
|
4284
|
+
h.value = !1;
|
|
4265
4285
|
}
|
|
4266
|
-
),
|
|
4286
|
+
), ie(
|
|
4267
4287
|
() => n.switching,
|
|
4268
|
-
(
|
|
4269
|
-
|
|
4288
|
+
(l) => {
|
|
4289
|
+
l || (h.value = !1);
|
|
4270
4290
|
}
|
|
4271
4291
|
);
|
|
4272
|
-
function
|
|
4273
|
-
n.busy || (
|
|
4292
|
+
function I() {
|
|
4293
|
+
n.busy || (x.value = !0, w.value = !1, r("loadChats"));
|
|
4274
4294
|
}
|
|
4275
|
-
function
|
|
4276
|
-
|
|
4295
|
+
function L() {
|
|
4296
|
+
w.value = !0, r("loadChats");
|
|
4277
4297
|
}
|
|
4278
|
-
function
|
|
4279
|
-
|
|
4298
|
+
function R() {
|
|
4299
|
+
w.value ? w.value = !1 : I();
|
|
4280
4300
|
}
|
|
4281
|
-
function
|
|
4282
|
-
n.busy || (
|
|
4301
|
+
function E(l) {
|
|
4302
|
+
n.busy || (x.value = !1, w.value = !1, l !== n.chatId && (h.value = !0, r("selectChat", l)));
|
|
4283
4303
|
}
|
|
4284
|
-
function
|
|
4285
|
-
n.busy || (
|
|
4304
|
+
function P() {
|
|
4305
|
+
n.busy || (x.value = !1, w.value = !1, h.value = !0, r("newChat"));
|
|
4286
4306
|
}
|
|
4287
|
-
|
|
4307
|
+
ie(
|
|
4288
4308
|
() => n.chatId,
|
|
4289
4309
|
() => {
|
|
4290
|
-
|
|
4310
|
+
M.value && (u.value = "", M.value = !1, x.value = !1);
|
|
4291
4311
|
}
|
|
4292
|
-
),
|
|
4312
|
+
), ie(
|
|
4293
4313
|
() => n.switching,
|
|
4294
|
-
(
|
|
4295
|
-
|
|
4314
|
+
(l) => {
|
|
4315
|
+
l || (M.value = !1);
|
|
4296
4316
|
}
|
|
4297
4317
|
);
|
|
4298
|
-
function
|
|
4299
|
-
if (
|
|
4300
|
-
|
|
4318
|
+
function F(l) {
|
|
4319
|
+
if (l.key === "Escape" && w.value) {
|
|
4320
|
+
l.stopPropagation(), w.value = !1;
|
|
4301
4321
|
return;
|
|
4302
4322
|
}
|
|
4303
|
-
|
|
4304
|
-
}
|
|
4305
|
-
const
|
|
4306
|
-
const
|
|
4307
|
-
|
|
4308
|
-
const
|
|
4309
|
-
for (const
|
|
4310
|
-
const
|
|
4311
|
-
(
|
|
4323
|
+
l.key === "Escape" && x.value && (l.stopPropagation(), x.value = !1);
|
|
4324
|
+
}
|
|
4325
|
+
const G = $(() => {
|
|
4326
|
+
const l = /* @__PURE__ */ new Date();
|
|
4327
|
+
l.setHours(0, 0, 0, 0);
|
|
4328
|
+
const s = [];
|
|
4329
|
+
for (const W of n.chats ?? []) {
|
|
4330
|
+
const U = new Date(W.lastMessageAt).getTime(), de = U >= l.getTime() ? "today" : U >= l.getTime() - $r ? "yesterday" : "earlier";
|
|
4331
|
+
(s.find((he) => he.key === de) ?? (s.push({ key: de, label: a(`reportV5.reportAi.chat.group.${de}`), chats: [] }), s[s.length - 1])).chats.push(W);
|
|
4312
4332
|
}
|
|
4313
|
-
return
|
|
4333
|
+
return s;
|
|
4314
4334
|
});
|
|
4315
|
-
function
|
|
4316
|
-
return new Date(
|
|
4335
|
+
function Y(l) {
|
|
4336
|
+
return new Date(l.lastMessageAt).toLocaleString(o.value, {
|
|
4317
4337
|
month: "short",
|
|
4318
4338
|
day: "numeric"
|
|
4319
4339
|
});
|
|
4320
4340
|
}
|
|
4321
|
-
const
|
|
4322
|
-
|
|
4341
|
+
const Q = $(() => new Set(n.undoableTurnIds ?? [])), m = $(() => new Set(n.unsentIds ?? [])), k = O();
|
|
4342
|
+
ie(
|
|
4323
4343
|
() => n.targets ?? n.target,
|
|
4324
|
-
async (
|
|
4325
|
-
var
|
|
4326
|
-
(Array.isArray(
|
|
4344
|
+
async (l) => {
|
|
4345
|
+
var s;
|
|
4346
|
+
(Array.isArray(l) ? !l.length : !l) || (w.value = !1, await we(), (s = k.value) == null || s.focus());
|
|
4327
4347
|
},
|
|
4328
4348
|
{ immediate: !0 }
|
|
4329
4349
|
);
|
|
4330
|
-
const g =
|
|
4350
|
+
const g = $(
|
|
4331
4351
|
() => {
|
|
4332
|
-
var
|
|
4333
|
-
return
|
|
4352
|
+
var l;
|
|
4353
|
+
return Wn(n.messages ?? [], {
|
|
4334
4354
|
streamingId: n.streaming ? n.turnId : void 0,
|
|
4335
|
-
outcomes: (
|
|
4355
|
+
outcomes: (l = n.copy) == null ? void 0 : l.outcomes
|
|
4336
4356
|
});
|
|
4337
4357
|
}
|
|
4338
|
-
),
|
|
4339
|
-
const
|
|
4340
|
-
return g.value.forEach((
|
|
4341
|
-
var
|
|
4342
|
-
|
|
4343
|
-
}),
|
|
4358
|
+
), H = $(() => {
|
|
4359
|
+
const l = new Set(n.noReplyId ? [n.noReplyId] : []);
|
|
4360
|
+
return g.value.forEach((s, W) => {
|
|
4361
|
+
var U;
|
|
4362
|
+
s.role === "user" && ((U = g.value[W + 1]) == null ? void 0 : U.role) === "user" && l.add(s.id);
|
|
4363
|
+
}), l;
|
|
4344
4364
|
});
|
|
4345
|
-
function
|
|
4346
|
-
for (let
|
|
4347
|
-
if (g.value[
|
|
4348
|
-
}
|
|
4349
|
-
const K =
|
|
4350
|
-
() => n.streaming ? g.value.findIndex((
|
|
4351
|
-
),
|
|
4352
|
-
() => K.value < 0 && (n.streaming || n.interrupted) ||
|
|
4353
|
-
),
|
|
4354
|
-
() =>
|
|
4355
|
-
),
|
|
4365
|
+
function V(l) {
|
|
4366
|
+
for (let s = l - 1; s >= 0; s -= 1)
|
|
4367
|
+
if (g.value[s].role === "user") return g.value[s].id;
|
|
4368
|
+
}
|
|
4369
|
+
const K = $(
|
|
4370
|
+
() => n.streaming ? g.value.findIndex((l) => l.pending) : -1
|
|
4371
|
+
), ne = $(() => g.value.findIndex((l) => l.id === n.runAnchorId)), ae = $(
|
|
4372
|
+
() => K.value < 0 && (n.streaming || n.interrupted) || ne.value < 0 && !!n.run
|
|
4373
|
+
), ee = $(
|
|
4374
|
+
() => x.value || !n.earlier && !_.value && !g.value.length && !ae.value
|
|
4375
|
+
), ve = $(() => (n.chats ?? []).slice(0, 3)), ue = $(
|
|
4356
4376
|
() => {
|
|
4357
|
-
var
|
|
4358
|
-
return !!((
|
|
4377
|
+
var l;
|
|
4378
|
+
return !!((l = n.chats) != null && l.length) || !!n.chatsLoading || !!n.chatsError || w.value;
|
|
4359
4379
|
}
|
|
4360
4380
|
);
|
|
4361
|
-
|
|
4362
|
-
[
|
|
4363
|
-
([
|
|
4364
|
-
|
|
4381
|
+
ie(
|
|
4382
|
+
[ee, () => n.chatId],
|
|
4383
|
+
([l, s]) => {
|
|
4384
|
+
l && s && !x.value && r("loadChats");
|
|
4365
4385
|
},
|
|
4366
4386
|
{ immediate: !0 }
|
|
4367
4387
|
);
|
|
4368
|
-
const
|
|
4369
|
-
() =>
|
|
4388
|
+
const ye = $(
|
|
4389
|
+
() => w.value ? G.value : [{ key: "recent", label: "", chats: ve.value }]
|
|
4370
4390
|
);
|
|
4371
|
-
function
|
|
4372
|
-
var
|
|
4373
|
-
const
|
|
4391
|
+
function te(l) {
|
|
4392
|
+
var U;
|
|
4393
|
+
const s = l === K.value, W = l === ne.value;
|
|
4374
4394
|
return {
|
|
4375
|
-
active:
|
|
4395
|
+
active: s && n.streaming || W && ((U = n.run) == null ? void 0 : U.status) === "running" && !n.runStale,
|
|
4376
4396
|
// a run card left behind by a newer streaming turn shows its own work, not that turn's phase
|
|
4377
|
-
phase:
|
|
4378
|
-
phases:
|
|
4379
|
-
run:
|
|
4380
|
-
slow:
|
|
4381
|
-
startedAt:
|
|
4382
|
-
stale:
|
|
4383
|
-
interrupted:
|
|
4384
|
-
retryError:
|
|
4397
|
+
phase: s || !n.streaming ? n.phase : "updating",
|
|
4398
|
+
phases: Pn(g.value[l]),
|
|
4399
|
+
run: W ? n.run : null,
|
|
4400
|
+
slow: s && n.slow,
|
|
4401
|
+
startedAt: s && n.streaming ? n.startedAt ?? null : null,
|
|
4402
|
+
stale: W && n.runStale,
|
|
4403
|
+
interrupted: s && n.interrupted,
|
|
4404
|
+
retryError: W ? n.retryError : ""
|
|
4385
4405
|
};
|
|
4386
4406
|
}
|
|
4387
|
-
const
|
|
4388
|
-
() => n.starters ?? (n.blank ?
|
|
4389
|
-
label: a(`reportV5.reportAi.chat.suggestNew.${
|
|
4390
|
-
prompt: a(`reportV5.reportAi.chat.suggestNew.${
|
|
4407
|
+
const ke = ["one", "two", "three"], pe = $(
|
|
4408
|
+
() => n.starters ?? (n.blank ? ke.map((l) => ({
|
|
4409
|
+
label: a(`reportV5.reportAi.chat.suggestNew.${l}.label`),
|
|
4410
|
+
prompt: a(`reportV5.reportAi.chat.suggestNew.${l}.prompt`)
|
|
4391
4411
|
})) : [])
|
|
4392
4412
|
);
|
|
4393
|
-
async function
|
|
4394
|
-
var
|
|
4395
|
-
r("editRequest",
|
|
4413
|
+
async function Ee(l) {
|
|
4414
|
+
var s;
|
|
4415
|
+
r("editRequest", l), await we(), (s = k.value) == null || s.focus();
|
|
4396
4416
|
}
|
|
4397
|
-
async function
|
|
4398
|
-
var
|
|
4399
|
-
r("askBuilder",
|
|
4417
|
+
async function se(l) {
|
|
4418
|
+
var s;
|
|
4419
|
+
r("askBuilder", l), await we(), (s = k.value) == null || s.focus();
|
|
4400
4420
|
}
|
|
4401
|
-
async function
|
|
4402
|
-
var
|
|
4403
|
-
|
|
4421
|
+
async function _e(l) {
|
|
4422
|
+
var s;
|
|
4423
|
+
Se(l), await we(), (s = k.value) == null || s.focus();
|
|
4404
4424
|
}
|
|
4405
|
-
function
|
|
4406
|
-
|
|
4425
|
+
function Se(l) {
|
|
4426
|
+
x.value ? u.value = l : r("update:draft", l);
|
|
4407
4427
|
}
|
|
4408
|
-
const
|
|
4409
|
-
function
|
|
4410
|
-
const
|
|
4411
|
-
|
|
4428
|
+
const xe = O(), b = O(!0), C = O(!1);
|
|
4429
|
+
function D() {
|
|
4430
|
+
const l = xe.value;
|
|
4431
|
+
l && (b.value = l.scrollHeight - l.scrollTop - l.clientHeight <= Dr, b.value && (C.value = !1));
|
|
4412
4432
|
}
|
|
4413
|
-
async function
|
|
4414
|
-
await
|
|
4415
|
-
const
|
|
4416
|
-
|
|
4433
|
+
async function q() {
|
|
4434
|
+
await we();
|
|
4435
|
+
const l = xe.value;
|
|
4436
|
+
l && (l.scrollTop = l.scrollHeight, b.value = !0, C.value = !1);
|
|
4417
4437
|
}
|
|
4418
|
-
|
|
4438
|
+
ie(
|
|
4419
4439
|
() => JSON.stringify(n.messages ?? []).length,
|
|
4420
4440
|
() => {
|
|
4421
|
-
|
|
4441
|
+
b.value ? q() : C.value = !0;
|
|
4422
4442
|
}
|
|
4423
4443
|
);
|
|
4424
|
-
function
|
|
4425
|
-
if (
|
|
4426
|
-
if (!u.value.trim() || n.busy || n.targetStale ||
|
|
4427
|
-
|
|
4444
|
+
function X() {
|
|
4445
|
+
if (x.value) {
|
|
4446
|
+
if (!u.value.trim() || n.busy || n.targetStale || M.value) return;
|
|
4447
|
+
M.value = !0, r("newChat", u.value.trim());
|
|
4428
4448
|
return;
|
|
4429
4449
|
}
|
|
4430
|
-
!n.draft.trim() || n.streaming || n.targetStale || (r("submit"),
|
|
4450
|
+
!n.draft.trim() || n.streaming || n.targetStale || (r("submit"), q());
|
|
4431
4451
|
}
|
|
4432
|
-
return (
|
|
4433
|
-
var
|
|
4434
|
-
const
|
|
4435
|
-
return
|
|
4452
|
+
return (l, s) => {
|
|
4453
|
+
var Ie, he, Ne, Re, Me, f;
|
|
4454
|
+
const W = Oe("FmIcon"), U = Oe("FmTooltip"), de = Oe("FmButton");
|
|
4455
|
+
return c(), p("aside", {
|
|
4436
4456
|
class: "flex h-full min-h-0 w-full flex-col border-l border-fm-color-border-secondary bg-fm-color-neutral-white",
|
|
4437
|
-
"aria-label":
|
|
4438
|
-
onKeydown:
|
|
4457
|
+
"aria-label": y.value,
|
|
4458
|
+
onKeydown: F
|
|
4439
4459
|
}, [
|
|
4440
|
-
|
|
4441
|
-
|
|
4442
|
-
|
|
4443
|
-
!
|
|
4460
|
+
N("header", Ga, [
|
|
4461
|
+
N("div", Ya, [
|
|
4462
|
+
N("h2", Xa, A(y.value), 1),
|
|
4463
|
+
!ee.value && e.chatTitle && e.chatTitle !== xt ? (c(), p("p", Ka, A(e.chatTitle), 1)) : j("", !0)
|
|
4444
4464
|
]),
|
|
4445
|
-
!
|
|
4465
|
+
!x.value || w.value ? (c(), ge(U, {
|
|
4446
4466
|
key: 0,
|
|
4447
4467
|
placement: "bottom",
|
|
4448
|
-
content:
|
|
4468
|
+
content: v(a)("reportV5.reportAi.chat.chats")
|
|
4449
4469
|
}, {
|
|
4450
4470
|
default: Ue(() => [
|
|
4451
|
-
|
|
4471
|
+
N("button", {
|
|
4452
4472
|
"data-testid": "report-canvas-chat-back",
|
|
4453
4473
|
class: "chat-icon-button flex h-[36px] w-[36px] shrink-0 items-center justify-center rounded-md text-fm-color-typo-secondary",
|
|
4454
4474
|
disabled: e.busy,
|
|
4455
|
-
"aria-label":
|
|
4456
|
-
onClick:
|
|
4475
|
+
"aria-label": w.value ? v(a)("reportV5.reportAi.chat.recentChats") : v(a)("reportV5.reportAi.chat.openChats", { title: z.value }),
|
|
4476
|
+
onClick: R
|
|
4457
4477
|
}, [
|
|
4458
|
-
|
|
4478
|
+
Z(W, {
|
|
4459
4479
|
name: "chevron_left",
|
|
4460
4480
|
size: "md"
|
|
4461
4481
|
})
|
|
4462
|
-
], 8,
|
|
4482
|
+
], 8, Ja)
|
|
4463
4483
|
]),
|
|
4464
4484
|
_: 1
|
|
4465
|
-
}, 8, ["content"])) :
|
|
4466
|
-
|
|
4485
|
+
}, 8, ["content"])) : j("", !0),
|
|
4486
|
+
ee.value ? j("", !0) : (c(), ge(U, {
|
|
4467
4487
|
key: 1,
|
|
4468
4488
|
placement: "bottom",
|
|
4469
|
-
content:
|
|
4489
|
+
content: v(a)("reportV5.reportAi.chat.newChat")
|
|
4470
4490
|
}, {
|
|
4471
4491
|
default: Ue(() => [
|
|
4472
|
-
|
|
4492
|
+
N("button", {
|
|
4473
4493
|
"data-testid": "report-canvas-new-chat",
|
|
4474
4494
|
class: "chat-icon-button flex h-[36px] w-[36px] shrink-0 items-center justify-center rounded-md text-fm-color-typo-secondary",
|
|
4475
4495
|
disabled: e.busy,
|
|
4476
|
-
"aria-label":
|
|
4477
|
-
title: e.busy ?
|
|
4478
|
-
onClick:
|
|
4496
|
+
"aria-label": v(a)("reportV5.reportAi.chat.newChat"),
|
|
4497
|
+
title: e.busy ? v(a)("reportV5.reportAi.chat.waitForUpdate") : void 0,
|
|
4498
|
+
onClick: P
|
|
4479
4499
|
}, [
|
|
4480
|
-
|
|
4500
|
+
Z(W, {
|
|
4481
4501
|
name: "edit_square",
|
|
4482
4502
|
size: "md",
|
|
4483
4503
|
outline: ""
|
|
4484
4504
|
})
|
|
4485
|
-
], 8,
|
|
4505
|
+
], 8, Qa)
|
|
4486
4506
|
]),
|
|
4487
4507
|
_: 1
|
|
4488
4508
|
}, 8, ["content"])),
|
|
4489
|
-
|
|
4509
|
+
Z(U, {
|
|
4490
4510
|
placement: "left",
|
|
4491
|
-
content:
|
|
4511
|
+
content: v(a)("reportV5.reportAi.chat.hide")
|
|
4492
4512
|
}, {
|
|
4493
4513
|
default: Ue(() => [
|
|
4494
|
-
|
|
4514
|
+
N("button", {
|
|
4495
4515
|
"data-testid": "report-canvas-chat-close",
|
|
4496
4516
|
class: "chat-icon-button flex h-[36px] w-[36px] shrink-0 items-center justify-center rounded-md text-fm-color-typo-secondary",
|
|
4497
|
-
"aria-label":
|
|
4498
|
-
onClick:
|
|
4517
|
+
"aria-label": v(a)("reportV5.reportAi.chat.hide"),
|
|
4518
|
+
onClick: s[0] || (s[0] = (i) => r("close"))
|
|
4499
4519
|
}, [
|
|
4500
|
-
|
|
4520
|
+
Z(W, {
|
|
4501
4521
|
name: "close",
|
|
4502
4522
|
size: "md"
|
|
4503
4523
|
})
|
|
4504
|
-
], 8,
|
|
4524
|
+
], 8, Za)
|
|
4505
4525
|
]),
|
|
4506
4526
|
_: 1
|
|
4507
4527
|
}, 8, ["content"])
|
|
4508
4528
|
]),
|
|
4509
|
-
|
|
4529
|
+
ee.value ? (c(), p("div", {
|
|
4510
4530
|
key: 0,
|
|
4511
|
-
"data-testid":
|
|
4531
|
+
"data-testid": x.value ? "report-canvas-chat-list" : "report-canvas-chat-home",
|
|
4512
4532
|
class: "flex min-h-0 grow flex-col overflow-y-auto px-[20px] py-24",
|
|
4513
|
-
"aria-label":
|
|
4533
|
+
"aria-label": v(a)("reportV5.reportAi.chat.chats")
|
|
4514
4534
|
}, [
|
|
4515
|
-
|
|
4516
|
-
|
|
4517
|
-
|
|
4518
|
-
|
|
4535
|
+
w.value ? j("", !0) : (c(), p("div", tr, [
|
|
4536
|
+
N("div", nr, [
|
|
4537
|
+
N("h3", ar, A(((Ie = e.copy) == null ? void 0 : Ie.welcome) ?? v(a)("reportV5.reportAi.chat.exploreTitle")), 1),
|
|
4538
|
+
N("p", rr, A(((he = e.copy) == null ? void 0 : he.hint) ?? v(a)(
|
|
4519
4539
|
e.blank ? "reportV5.reportAi.chat.placeholderNew" : "reportV5.reportAi.chat.exploreHint"
|
|
4520
4540
|
)), 1)
|
|
4521
4541
|
]),
|
|
4522
|
-
pe.value.length ? (
|
|
4523
|
-
(
|
|
4524
|
-
key:
|
|
4542
|
+
pe.value.length ? (c(), p("div", or, [
|
|
4543
|
+
(c(!0), p(fe, null, me(pe.value, (i) => (c(), p("button", {
|
|
4544
|
+
key: i.label,
|
|
4525
4545
|
"data-testid": "report-canvas-suggestion",
|
|
4526
4546
|
class: "chat-row fm-typo-en-body-md-600 flex w-full items-center justify-between gap-12 rounded-md px-8 py-12 text-left text-fm-color-primary",
|
|
4527
4547
|
disabled: e.busy,
|
|
4528
|
-
title:
|
|
4529
|
-
onClick: (
|
|
4548
|
+
title: i.prompt,
|
|
4549
|
+
onClick: (d) => _e(i.prompt)
|
|
4530
4550
|
}, [
|
|
4531
|
-
|
|
4532
|
-
|
|
4551
|
+
N("span", null, A(i.label), 1),
|
|
4552
|
+
Z(W, {
|
|
4533
4553
|
name: "chevron_right",
|
|
4534
4554
|
size: "sm",
|
|
4535
4555
|
class: "shrink-0"
|
|
4536
4556
|
})
|
|
4537
|
-
], 8,
|
|
4538
|
-
])) :
|
|
4557
|
+
], 8, ir))), 128))
|
|
4558
|
+
])) : j("", !0)
|
|
4539
4559
|
])),
|
|
4540
|
-
ue.value ? (
|
|
4560
|
+
ue.value ? (c(), p("section", {
|
|
4541
4561
|
key: 1,
|
|
4542
4562
|
class: "shrink-0 pt-24",
|
|
4543
|
-
"aria-label":
|
|
4563
|
+
"aria-label": v(a)("reportV5.reportAi.chat.recentChats")
|
|
4544
4564
|
}, [
|
|
4545
|
-
|
|
4546
|
-
|
|
4565
|
+
N("h3", lr, A(v(a)(
|
|
4566
|
+
w.value ? "reportV5.reportAi.chat.yourChats" : "reportV5.reportAi.chat.recentChats"
|
|
4547
4567
|
)), 1),
|
|
4548
|
-
e.chatsLoading && !((Ne = e.chats) != null && Ne.length) ? (
|
|
4549
|
-
key:
|
|
4550
|
-
class:
|
|
4568
|
+
e.chatsLoading && !((Ne = e.chats) != null && Ne.length) ? (c(), p("p", fr, A(v(a)("reportV5.reportAi.chat.loadingChats")), 1)) : e.chatsError ? (c(), p("p", dr, A(e.chatsError), 1)) : (Re = e.chats) != null && Re.length ? (c(!0), p(fe, { key: 3 }, me(ye.value, (i) => (c(), p("section", {
|
|
4569
|
+
key: i.key,
|
|
4570
|
+
class: Ze(w.value ? "mb-16" : "")
|
|
4551
4571
|
}, [
|
|
4552
|
-
|
|
4553
|
-
(
|
|
4554
|
-
key:
|
|
4572
|
+
i.label ? (c(), p("p", mr, A(i.label), 1)) : j("", !0),
|
|
4573
|
+
(c(!0), p(fe, null, me(i.chats, (d) => (c(), p("button", {
|
|
4574
|
+
key: d.id,
|
|
4555
4575
|
"data-testid": "report-canvas-chat-list-item",
|
|
4556
4576
|
class: "chat-row flex w-full items-center gap-12 rounded-md px-8 py-12 text-left",
|
|
4557
4577
|
disabled: e.busy,
|
|
4558
|
-
"aria-current":
|
|
4559
|
-
title:
|
|
4560
|
-
onClick: (
|
|
4578
|
+
"aria-current": d.id === e.chatId ? "true" : void 0,
|
|
4579
|
+
title: d.title,
|
|
4580
|
+
onClick: (T) => E(d.id)
|
|
4561
4581
|
}, [
|
|
4562
|
-
|
|
4563
|
-
|
|
4564
|
-
datetime:
|
|
4582
|
+
N("span", pr, A(d.title), 1),
|
|
4583
|
+
N("time", {
|
|
4584
|
+
datetime: d.lastMessageAt,
|
|
4565
4585
|
class: "fm-typo-en-body-sm-400 shrink-0 text-fm-color-typo-secondary"
|
|
4566
|
-
},
|
|
4567
|
-
], 8,
|
|
4568
|
-
], 2))), 128)) : (
|
|
4569
|
-
|
|
4586
|
+
}, A(Y(d)), 9, hr)
|
|
4587
|
+
], 8, ur))), 128))
|
|
4588
|
+
], 2))), 128)) : (c(), p("p", cr, A(v(a)("reportV5.reportAi.chat.noChats")), 1)),
|
|
4589
|
+
w.value ? e.chatsCursor ? (c(), p("button", {
|
|
4570
4590
|
key: 5,
|
|
4571
4591
|
"data-testid": "report-canvas-chat-list-more",
|
|
4572
4592
|
class: "chat-row fm-typo-en-body-sm-600 rounded-md px-8 py-12 text-fm-color-typo-secondary",
|
|
4573
4593
|
disabled: e.chatsLoading,
|
|
4574
|
-
onClick:
|
|
4575
|
-
},
|
|
4594
|
+
onClick: s[1] || (s[1] = (i) => r("loadMoreChats"))
|
|
4595
|
+
}, A(v(a)("reportV5.reportAi.chat.loadMoreChats")), 9, br)) : j("", !0) : (c(), p("button", {
|
|
4576
4596
|
key: 4,
|
|
4577
4597
|
"data-testid": "report-canvas-chat-see-all",
|
|
4578
4598
|
class: "chat-row fm-typo-en-body-sm-600 mt-8 rounded-md px-8 py-12 text-fm-color-typo-secondary",
|
|
4579
4599
|
disabled: e.chatsLoading,
|
|
4580
|
-
onClick:
|
|
4581
|
-
},
|
|
4582
|
-
], 8,
|
|
4583
|
-
e.error ? (
|
|
4584
|
-
], 8,
|
|
4585
|
-
|
|
4600
|
+
onClick: L
|
|
4601
|
+
}, A(v(a)("reportV5.reportAi.chat.seeAll")), 9, gr))
|
|
4602
|
+
], 8, sr)) : j("", !0),
|
|
4603
|
+
e.error ? (c(), p("p", vr, A(e.error), 1)) : j("", !0)
|
|
4604
|
+
], 8, er)) : (c(), p("div", yr, [
|
|
4605
|
+
N("div", {
|
|
4586
4606
|
ref_key: "scroller",
|
|
4587
|
-
ref:
|
|
4607
|
+
ref: xe,
|
|
4588
4608
|
class: "min-h-0 grow overflow-y-auto px-[20px] py-16",
|
|
4589
|
-
onScroll:
|
|
4609
|
+
onScroll: D
|
|
4590
4610
|
}, [
|
|
4591
|
-
|
|
4592
|
-
e.earlier ? (
|
|
4611
|
+
_.value ? (c(), p("p", xr, A(v(a)("reportV5.reportAi.chat.loadingChat")), 1)) : (c(), p(fe, { key: 1 }, [
|
|
4612
|
+
e.earlier ? (c(), p("button", {
|
|
4593
4613
|
key: 0,
|
|
4594
4614
|
"data-testid": "report-canvas-load-earlier",
|
|
4595
4615
|
class: "fm-typo-en-body-sm-600 mb-16 w-full text-fm-color-typo-secondary disabled:opacity-50",
|
|
4596
4616
|
disabled: e.loadingEarlier,
|
|
4597
|
-
onClick:
|
|
4598
|
-
},
|
|
4599
|
-
(
|
|
4600
|
-
key:
|
|
4617
|
+
onClick: s[2] || (s[2] = (i) => r("loadEarlier"))
|
|
4618
|
+
}, A(v(a)("reportV5.reportAi.chat.loadEarlier")), 9, wr)) : j("", !0),
|
|
4619
|
+
(c(!0), p(fe, null, me(g.value, (i, d) => (c(), p("div", {
|
|
4620
|
+
key: i.id,
|
|
4601
4621
|
class: "mb-16"
|
|
4602
4622
|
}, [
|
|
4603
|
-
|
|
4623
|
+
i.targets.length ? (c(), p("p", kr, A(v(a)("reportV5.reportAi.chat.commentOn", {
|
|
4604
4624
|
widget: [
|
|
4605
4625
|
...new Set(
|
|
4606
|
-
|
|
4607
|
-
(
|
|
4626
|
+
i.targets.map(
|
|
4627
|
+
(T) => T.label || v(a)("reportV5.reportAi.chat.selectedWidget")
|
|
4608
4628
|
)
|
|
4609
4629
|
)
|
|
4610
4630
|
].join(", ")
|
|
4611
|
-
})), 1)) :
|
|
4612
|
-
|
|
4613
|
-
|
|
4631
|
+
})), 1)) : j("", !0),
|
|
4632
|
+
i.role === "user" ? (c(), p("div", _r, [
|
|
4633
|
+
N("div", {
|
|
4614
4634
|
"data-testid": "report-canvas-user-message",
|
|
4615
|
-
class:
|
|
4635
|
+
class: Ze([
|
|
4616
4636
|
"fm-typo-en-body-md-400 max-w-[90%] whitespace-pre-wrap rounded-md px-12 py-8 !leading-[21px]",
|
|
4617
|
-
|
|
4637
|
+
m.value.has(i.id) ? "bg-fm-color-neutral-gray-100 text-fm-color-typo-secondary" : "bg-fm-color-system-info-100"
|
|
4618
4638
|
])
|
|
4619
|
-
},
|
|
4620
|
-
|
|
4621
|
-
Ce(
|
|
4622
|
-
|
|
4639
|
+
}, A(i.answer), 3),
|
|
4640
|
+
m.value.has(i.id) ? (c(), p("p", Sr, [
|
|
4641
|
+
Ce(A(v(a)("reportV5.reportAi.chat.notSent")) + " ", 1),
|
|
4642
|
+
N("button", {
|
|
4623
4643
|
"data-testid": "chat-message-resend",
|
|
4624
4644
|
class: "ml-4 underline disabled:opacity-50",
|
|
4625
4645
|
disabled: e.streaming || e.busy,
|
|
4626
|
-
onClick: (
|
|
4627
|
-
},
|
|
4628
|
-
])) :
|
|
4629
|
-
Ce(
|
|
4630
|
-
|
|
4646
|
+
onClick: (T) => r("resend", i.id)
|
|
4647
|
+
}, A(v(a)("reportV5.reportAi.chat.resend")), 9, Ir)
|
|
4648
|
+
])) : H.value.has(i.id) ? (c(), p("p", Ar, [
|
|
4649
|
+
Ce(A(v(a)("reportV5.reportAi.chat.noReply")) + " ", 1),
|
|
4650
|
+
N("button", {
|
|
4631
4651
|
"data-testid": "chat-message-ask-again",
|
|
4632
4652
|
class: "ml-4 underline disabled:opacity-50",
|
|
4633
4653
|
disabled: e.streaming || e.busy,
|
|
4634
|
-
onClick: (
|
|
4635
|
-
},
|
|
4636
|
-
])) :
|
|
4654
|
+
onClick: (T) => r("askAgain", i.id)
|
|
4655
|
+
}, A(v(a)("reportV5.reportAi.chat.resend")), 9, Cr)
|
|
4656
|
+
])) : Q.value.has(i.turnId) ? (c(), p("button", {
|
|
4637
4657
|
key: 2,
|
|
4638
4658
|
"data-testid": "chat-turn-undo",
|
|
4639
4659
|
class: "fm-typo-en-body-sm-400 mt-4 text-fm-color-typo-secondary underline disabled:opacity-50",
|
|
4640
4660
|
disabled: e.undoing || e.streaming,
|
|
4641
|
-
onClick: (
|
|
4642
|
-
},
|
|
4643
|
-
])) : (
|
|
4644
|
-
|
|
4661
|
+
onClick: (T) => r("undo", i.turnId)
|
|
4662
|
+
}, A(v(a)("reportV5.reportCanvas.draft.undo")), 9, Tr)) : j("", !0)
|
|
4663
|
+
])) : (c(), p(fe, { key: 2 }, [
|
|
4664
|
+
d === K.value || d === ne.value ? (c(), ge(bt, ot({
|
|
4645
4665
|
key: 0,
|
|
4646
4666
|
class: "mb-8"
|
|
4647
|
-
}, { ref_for: !0 },
|
|
4648
|
-
onRetry:
|
|
4649
|
-
onAskBuilder:
|
|
4650
|
-
onCheckStatus:
|
|
4651
|
-
}), null, 16)) :
|
|
4652
|
-
|
|
4653
|
-
|
|
4654
|
-
|
|
4667
|
+
}, { ref_for: !0 }, te(d), {
|
|
4668
|
+
onRetry: s[3] || (s[3] = (T) => r("retry", T)),
|
|
4669
|
+
onAskBuilder: se,
|
|
4670
|
+
onCheckStatus: s[4] || (s[4] = (T) => r("checkStatus"))
|
|
4671
|
+
}), null, 16)) : j("", !0),
|
|
4672
|
+
i.failure ? (c(), p("div", Er, [
|
|
4673
|
+
N("p", Or, [
|
|
4674
|
+
Z(W, {
|
|
4655
4675
|
name: "error",
|
|
4656
4676
|
size: "sm",
|
|
4657
4677
|
class: "shrink-0 text-fm-color-typo-error"
|
|
4658
4678
|
}),
|
|
4659
|
-
Ce(" " +
|
|
4679
|
+
Ce(" " + A(v(a)("reportV5.reportAi.build.failed.title")), 1)
|
|
4660
4680
|
]),
|
|
4661
|
-
|
|
4662
|
-
|
|
4663
|
-
|
|
4681
|
+
N("p", zr, A(v(a)(`reportV5.reportAi.build.failed.${v(qn)(i.failure.code)}`)), 1),
|
|
4682
|
+
d === g.value.length - 1 && V(d) ? (c(), p("div", Nr, [
|
|
4683
|
+
Z(de, {
|
|
4664
4684
|
"data-testid": "report-canvas-try-again",
|
|
4665
4685
|
variant: "primary",
|
|
4666
|
-
label:
|
|
4686
|
+
label: v(a)("reportV5.reportAi.build.failed.tryAgain"),
|
|
4667
4687
|
disabled: e.streaming || e.busy,
|
|
4668
|
-
onClick: (
|
|
4688
|
+
onClick: (T) => r("askAgain", V(d))
|
|
4669
4689
|
}, null, 8, ["label", "disabled", "onClick"]),
|
|
4670
|
-
|
|
4690
|
+
Z(de, {
|
|
4671
4691
|
"data-testid": "report-canvas-edit-request",
|
|
4672
4692
|
variant: "secondary",
|
|
4673
|
-
label:
|
|
4693
|
+
label: v(a)("reportV5.reportAi.build.failed.editRequest"),
|
|
4674
4694
|
disabled: e.streaming || e.busy,
|
|
4675
|
-
onClick: (
|
|
4695
|
+
onClick: (T) => Ee(V(d))
|
|
4676
4696
|
}, null, 8, ["label", "disabled", "onClick"])
|
|
4677
|
-
])) :
|
|
4678
|
-
|
|
4679
|
-
])) :
|
|
4697
|
+
])) : j("", !0),
|
|
4698
|
+
i.failure.ref ? (c(), p("p", Rr, A(v(a)("reportV5.reportAi.build.failed.ref", { ref: i.failure.ref })), 1)) : j("", !0)
|
|
4699
|
+
])) : i.blocks.length ? (c(), ge(Ha, {
|
|
4680
4700
|
key: 2,
|
|
4681
4701
|
"data-testid": "report-canvas-answer",
|
|
4682
|
-
blocks:
|
|
4683
|
-
preview:
|
|
4684
|
-
}, null, 8, ["blocks", "preview"])) :
|
|
4685
|
-
|
|
4702
|
+
blocks: i.blocks,
|
|
4703
|
+
preview: i.preview
|
|
4704
|
+
}, null, 8, ["blocks", "preview"])) : i.noSummary ? (c(), p("p", Mr, A(v(a)("reportV5.reportAi.chat.noSummary")), 1)) : j("", !0),
|
|
4705
|
+
i.ms ? (c(), p("p", Pr, A(v(a)("reportV5.reportAi.chat.took", { duration: v(Bn)(i.ms) })), 1)) : j("", !0)
|
|
4686
4706
|
], 64))
|
|
4687
4707
|
]))), 128)),
|
|
4688
|
-
|
|
4708
|
+
ae.value ? (c(), ge(bt, ot({
|
|
4689
4709
|
key: 1,
|
|
4690
4710
|
class: "mb-16"
|
|
4691
|
-
},
|
|
4692
|
-
onRetry:
|
|
4693
|
-
onAskBuilder:
|
|
4694
|
-
onCheckStatus:
|
|
4695
|
-
}), null, 16)) :
|
|
4696
|
-
e.error ? (
|
|
4711
|
+
}, te(-1), {
|
|
4712
|
+
onRetry: s[5] || (s[5] = (i) => r("retry", i)),
|
|
4713
|
+
onAskBuilder: se,
|
|
4714
|
+
onCheckStatus: s[6] || (s[6] = (i) => r("checkStatus"))
|
|
4715
|
+
}), null, 16)) : j("", !0),
|
|
4716
|
+
e.error ? (c(), p("p", Lr, A(e.error), 1)) : j("", !0)
|
|
4697
4717
|
], 64))
|
|
4698
4718
|
], 544),
|
|
4699
|
-
|
|
4719
|
+
C.value ? (c(), p("button", {
|
|
4700
4720
|
key: 0,
|
|
4701
4721
|
"data-testid": "report-canvas-jump-latest",
|
|
4702
4722
|
class: "fm-typo-en-body-sm-600 absolute bottom-12 left-1/2 -translate-x-1/2 rounded-full border border-fm-color-border-secondary bg-fm-color-neutral-white px-12 py-4 shadow-sm",
|
|
4703
|
-
onClick:
|
|
4704
|
-
},
|
|
4723
|
+
onClick: q
|
|
4724
|
+
}, A(v(a)("reportV5.reportAi.chat.jumpToLatest")), 1)) : j("", !0)
|
|
4705
4725
|
])),
|
|
4706
|
-
|
|
4707
|
-
|
|
4726
|
+
N("div", jr, [
|
|
4727
|
+
Z(qa, {
|
|
4708
4728
|
ref_key: "composer",
|
|
4709
|
-
ref:
|
|
4710
|
-
draft:
|
|
4729
|
+
ref: k,
|
|
4730
|
+
draft: x.value ? u.value : e.draft,
|
|
4711
4731
|
target: e.target,
|
|
4712
4732
|
targets: e.targets,
|
|
4713
4733
|
"target-stale": e.targetStale,
|
|
4714
|
-
streaming: e.streaming || e.switching ||
|
|
4734
|
+
streaming: e.streaming || e.switching || M.value || x.value && !!e.busy,
|
|
4715
4735
|
blank: e.blank,
|
|
4716
|
-
stoppable: !!e.stoppable && !
|
|
4736
|
+
stoppable: !!e.stoppable && !x.value,
|
|
4717
4737
|
stopping: e.stopping,
|
|
4718
4738
|
"target-label": (Me = e.copy) == null ? void 0 : Me.target,
|
|
4719
|
-
placeholder: (
|
|
4720
|
-
"onUpdate:draft":
|
|
4721
|
-
onSubmit:
|
|
4722
|
-
onClearTarget:
|
|
4723
|
-
onStop:
|
|
4739
|
+
placeholder: (f = e.copy) == null ? void 0 : f.placeholder,
|
|
4740
|
+
"onUpdate:draft": Se,
|
|
4741
|
+
onSubmit: X,
|
|
4742
|
+
onClearTarget: s[7] || (s[7] = (i) => r("clearTarget", i)),
|
|
4743
|
+
onStop: s[8] || (s[8] = (i) => r("stop"))
|
|
4724
4744
|
}, null, 8, ["draft", "target", "targets", "target-stale", "streaming", "blank", "stoppable", "stopping", "target-label", "placeholder"])
|
|
4725
4745
|
])
|
|
4726
|
-
], 40,
|
|
4746
|
+
], 40, Wa);
|
|
4727
4747
|
};
|
|
4728
4748
|
}
|
|
4729
|
-
}),
|
|
4730
|
-
function
|
|
4749
|
+
}), bo = /* @__PURE__ */ Et(Br, [["__scopeId", "data-v-cbe24113"]]);
|
|
4750
|
+
function Te(e) {
|
|
4731
4751
|
const { businessId: t } = ze(De());
|
|
4732
4752
|
if (!t.value) throw new Error("Business Id is not defined");
|
|
4733
4753
|
return `/${t.value}/report-ai/${e}`;
|
|
4734
4754
|
}
|
|
4735
|
-
const
|
|
4755
|
+
const qr = (e, t = {}) => {
|
|
4736
4756
|
const n = new URLSearchParams();
|
|
4737
4757
|
t.sessionId && n.set("sessionId", t.sessionId), t.before && n.set("before", t.before);
|
|
4738
4758
|
const r = n.toString(), a = {
|
|
4739
|
-
fetchType:
|
|
4740
|
-
url: `${
|
|
4759
|
+
fetchType: oe.Get,
|
|
4760
|
+
url: `${Te(e)}/chat${r ? `?${r}` : ""}`
|
|
4741
4761
|
};
|
|
4742
|
-
return
|
|
4743
|
-
},
|
|
4762
|
+
return re.fetch(a);
|
|
4763
|
+
}, Vr = (e, t) => {
|
|
4744
4764
|
const n = {
|
|
4745
|
-
fetchType:
|
|
4746
|
-
url: `${
|
|
4765
|
+
fetchType: oe.Get,
|
|
4766
|
+
url: `${Te(e)}/chats${t ? `?cursor=${encodeURIComponent(t)}` : ""}`
|
|
4747
4767
|
};
|
|
4748
|
-
return
|
|
4749
|
-
},
|
|
4768
|
+
return re.fetch(n);
|
|
4769
|
+
}, Fr = (e) => {
|
|
4750
4770
|
const t = {
|
|
4751
|
-
fetchType:
|
|
4752
|
-
url: `${
|
|
4771
|
+
fetchType: oe.Post,
|
|
4772
|
+
url: `${Te(e)}/chats`,
|
|
4753
4773
|
data: {}
|
|
4754
4774
|
};
|
|
4755
|
-
return
|
|
4756
|
-
},
|
|
4775
|
+
return re.fetch(t);
|
|
4776
|
+
}, vo = (e, t) => {
|
|
4757
4777
|
const n = {
|
|
4758
|
-
fetchType:
|
|
4759
|
-
url: `${
|
|
4778
|
+
fetchType: oe.Get,
|
|
4779
|
+
url: `${Te(e)}/runs/latest${t ? `?sessionId=${t}` : ""}`
|
|
4760
4780
|
};
|
|
4761
|
-
return
|
|
4762
|
-
},
|
|
4781
|
+
return re.fetch(n);
|
|
4782
|
+
}, yo = (e, t, n, r) => {
|
|
4763
4783
|
const a = {
|
|
4764
|
-
fetchType:
|
|
4765
|
-
url: `${
|
|
4784
|
+
fetchType: oe.Post,
|
|
4785
|
+
url: `${Te(e)}/runs/${t}/sections/${n}/retry`,
|
|
4766
4786
|
data: { timezone: r }
|
|
4767
4787
|
};
|
|
4768
|
-
return
|
|
4769
|
-
},
|
|
4788
|
+
return re.fetch(a);
|
|
4789
|
+
}, Ur = (e, t) => {
|
|
4770
4790
|
const n = {
|
|
4771
|
-
fetchType:
|
|
4772
|
-
url: `${
|
|
4791
|
+
fetchType: oe.Post,
|
|
4792
|
+
url: `${Te(e)}/chat/stop`,
|
|
4773
4793
|
data: { sessionId: t }
|
|
4774
4794
|
};
|
|
4775
|
-
return
|
|
4776
|
-
},
|
|
4795
|
+
return re.fetch(n);
|
|
4796
|
+
}, Hr = (e, t) => `/${e}/report-ai/${t}/chat`, Ke = 3e4, wt = 3e3, Wr = "New chat", kt = 80, Gr = (e) => ({
|
|
4777
4797
|
key: e,
|
|
4778
|
-
getChat: (t) =>
|
|
4779
|
-
listChats: (t) =>
|
|
4780
|
-
createChat: () =>
|
|
4781
|
-
stopChat: (t) =>
|
|
4782
|
-
chatPath: (t) =>
|
|
4783
|
-
}),
|
|
4798
|
+
getChat: (t) => qr(e, t),
|
|
4799
|
+
listChats: (t) => Vr(e, t),
|
|
4800
|
+
createChat: () => Fr(e),
|
|
4801
|
+
stopChat: (t) => Ur(e, t),
|
|
4802
|
+
chatPath: (t) => Hr(t, e)
|
|
4803
|
+
}), xo = (e) => ({
|
|
4784
4804
|
key: `digest:${e}`,
|
|
4785
|
-
getChat: (t) =>
|
|
4786
|
-
listChats: (t) =>
|
|
4787
|
-
createChat: () =>
|
|
4788
|
-
stopChat: (t) =>
|
|
4789
|
-
chatPath: (t) =>
|
|
4805
|
+
getChat: (t) => Zt(e, t),
|
|
4806
|
+
listChats: (t) => Qt(e, t),
|
|
4807
|
+
createChat: () => Jt(e),
|
|
4808
|
+
stopChat: (t) => Kt(e, t),
|
|
4809
|
+
chatPath: (t) => Xt(t, e)
|
|
4790
4810
|
});
|
|
4791
|
-
function
|
|
4811
|
+
function Je(e, t) {
|
|
4792
4812
|
return `report-canvas:chat:${e}:${t}`;
|
|
4793
4813
|
}
|
|
4794
|
-
function
|
|
4814
|
+
function Yr(e) {
|
|
4795
4815
|
try {
|
|
4796
4816
|
return window.localStorage.getItem(e) ?? void 0;
|
|
4797
4817
|
} catch {
|
|
4798
4818
|
return;
|
|
4799
4819
|
}
|
|
4800
4820
|
}
|
|
4801
|
-
function
|
|
4821
|
+
function Qe(e, t) {
|
|
4802
4822
|
try {
|
|
4803
4823
|
t ? window.localStorage.setItem(e, t) : window.localStorage.removeItem(e);
|
|
4804
4824
|
} catch {
|
|
4805
4825
|
}
|
|
4806
4826
|
}
|
|
4807
|
-
const
|
|
4827
|
+
const _t = (e) => Array.isArray(e) ? e : e ? [e] : [], Lt = (e, t) => ({
|
|
4808
4828
|
text: e,
|
|
4809
4829
|
...t.length ? { target: t[0] } : {},
|
|
4810
4830
|
targets: t
|
|
@@ -4816,270 +4836,270 @@ function St(e) {
|
|
|
4816
4836
|
e.parts.filter((t) => t.type === "data-edit-target").map((t) => t.data)
|
|
4817
4837
|
);
|
|
4818
4838
|
}
|
|
4819
|
-
function
|
|
4820
|
-
const { businessId: t, token: n } = ze(De()), r = typeof e == "string" ?
|
|
4821
|
-
|
|
4822
|
-
!
|
|
4839
|
+
function wo(e) {
|
|
4840
|
+
const { businessId: t, token: n } = ze(De()), r = typeof e == "string" ? Gr(e) : e, a = O([]), o = O(), y = O(""), x = O(null), w = O(!1), u = O([]), M = O(null), z = O(!1), h = O(""), _ = O(!1), I = O(!1), L = O(""), R = O(null), E = O(""), P = O(!1), F = O([]), G = O(!1), Y = O(null), Q = O(!1), m = O(null), k = O(!1), g = $(() => Q.value || I.value && k.value), H = O(!1);
|
|
4841
|
+
ie([I, Q], ([f, i]) => {
|
|
4842
|
+
!f && !i && (H.value = !1);
|
|
4823
4843
|
});
|
|
4824
|
-
let
|
|
4825
|
-
const
|
|
4826
|
-
function
|
|
4827
|
-
|
|
4844
|
+
let V, K;
|
|
4845
|
+
const ne = [];
|
|
4846
|
+
function ae(f) {
|
|
4847
|
+
ne.push(f);
|
|
4828
4848
|
}
|
|
4829
|
-
const
|
|
4830
|
-
function
|
|
4831
|
-
|
|
4849
|
+
const ee = [];
|
|
4850
|
+
function ve(f) {
|
|
4851
|
+
ee.push(f);
|
|
4832
4852
|
}
|
|
4833
4853
|
const ue = [];
|
|
4834
|
-
function
|
|
4835
|
-
ue.push(
|
|
4854
|
+
function ye(f) {
|
|
4855
|
+
ue.push(f);
|
|
4836
4856
|
}
|
|
4837
|
-
let
|
|
4838
|
-
Ct() &&
|
|
4839
|
-
|
|
4857
|
+
let te = 0;
|
|
4858
|
+
Ct() && Tt(() => {
|
|
4859
|
+
te += 1, clearTimeout(V), clearTimeout(K);
|
|
4840
4860
|
});
|
|
4841
|
-
async function
|
|
4842
|
-
const
|
|
4843
|
-
clearTimeout(
|
|
4861
|
+
async function ke(f) {
|
|
4862
|
+
const i = Je(v(t.value), r.key), d = f ?? Yr(i), T = te += 1;
|
|
4863
|
+
clearTimeout(V), _.value = !0;
|
|
4844
4864
|
try {
|
|
4845
|
-
let
|
|
4865
|
+
let S;
|
|
4846
4866
|
try {
|
|
4847
|
-
|
|
4848
|
-
} catch (
|
|
4849
|
-
if (!
|
|
4850
|
-
|
|
4867
|
+
S = await r.getChat({ sessionId: d });
|
|
4868
|
+
} catch (B) {
|
|
4869
|
+
if (!d) throw B;
|
|
4870
|
+
Qe(i, void 0), S = await r.getChat();
|
|
4851
4871
|
}
|
|
4852
|
-
return
|
|
4853
|
-
} catch (
|
|
4854
|
-
return
|
|
4872
|
+
return T !== te ? null : (pe(S), S.latestRun ?? null);
|
|
4873
|
+
} catch (S) {
|
|
4874
|
+
return T === te && (E.value = S instanceof Error ? S.message : String(S)), null;
|
|
4855
4875
|
} finally {
|
|
4856
|
-
|
|
4876
|
+
T === te && (_.value = !1);
|
|
4857
4877
|
}
|
|
4858
4878
|
}
|
|
4859
|
-
function pe(
|
|
4860
|
-
|
|
4879
|
+
function pe(f) {
|
|
4880
|
+
o.value = f.sessionId ?? void 0, y.value = f.title ?? "", a.value = f.messages, x.value = f.earlier ?? null, F.value = [], E.value = "", Qe(Je(v(t.value), r.key), f.sessionId), Ee(f);
|
|
4861
4881
|
}
|
|
4862
|
-
function
|
|
4863
|
-
clearTimeout(
|
|
4864
|
-
const
|
|
4865
|
-
if (
|
|
4866
|
-
|
|
4882
|
+
function Ee(f) {
|
|
4883
|
+
clearTimeout(V), clearTimeout(K);
|
|
4884
|
+
const i = f.pending, d = f.messages[f.messages.length - 1], T = [...f.messages].reverse().find((J) => J.role === "user");
|
|
4885
|
+
if (m.value = i != null && i.stopped && T ? T.id : null, P.value = !1, !i || i.stopped) {
|
|
4886
|
+
Q.value = !1, I.value || (Y.value = null, R.value = null, G.value = !1);
|
|
4867
4887
|
return;
|
|
4868
4888
|
}
|
|
4869
|
-
|
|
4870
|
-
const
|
|
4871
|
-
|
|
4872
|
-
const
|
|
4873
|
-
|
|
4889
|
+
Q.value = !0;
|
|
4890
|
+
const S = Date.parse(i.now) - Date.parse(i.since);
|
|
4891
|
+
Y.value = Date.now() - S;
|
|
4892
|
+
const B = (d == null ? void 0 : d.role) === "assistant" && d.inProgress ? d : void 0;
|
|
4893
|
+
B && (L.value = B.id), R.value = Ln(B), G.value = S >= Ke, G.value || (K = setTimeout(() => G.value = !0, Ke - S)), V = setTimeout(() => void se(), wt);
|
|
4874
4894
|
}
|
|
4875
|
-
async function
|
|
4876
|
-
const
|
|
4895
|
+
async function se(f = !1) {
|
|
4896
|
+
const i = te, d = o.value;
|
|
4877
4897
|
try {
|
|
4878
|
-
const
|
|
4879
|
-
if (
|
|
4880
|
-
pe(
|
|
4898
|
+
const T = await r.getChat({ sessionId: d });
|
|
4899
|
+
if (i !== te || I.value || d !== o.value) return;
|
|
4900
|
+
pe(T), (!T.pending || T.pending.stopped) && (ee.forEach((S) => S()), ue.forEach((S) => S(T.latestRun ?? null)));
|
|
4881
4901
|
} catch {
|
|
4882
|
-
|
|
4902
|
+
i === te && (Q.value || f) && (V = setTimeout(() => void se(f), wt));
|
|
4883
4903
|
}
|
|
4884
4904
|
}
|
|
4885
|
-
async function
|
|
4886
|
-
return
|
|
4905
|
+
async function _e(f) {
|
|
4906
|
+
return f === o.value || I.value || Q.value ? null : ke(f);
|
|
4887
4907
|
}
|
|
4888
|
-
async function
|
|
4889
|
-
if (
|
|
4890
|
-
const
|
|
4891
|
-
|
|
4908
|
+
async function Se() {
|
|
4909
|
+
if (I.value || Q.value) return !1;
|
|
4910
|
+
const f = te += 1;
|
|
4911
|
+
_.value = !0;
|
|
4892
4912
|
try {
|
|
4893
|
-
const { chat:
|
|
4894
|
-
return
|
|
4895
|
-
} catch (
|
|
4896
|
-
return
|
|
4913
|
+
const { chat: i } = await r.createChat();
|
|
4914
|
+
return f !== te ? !1 : (pe({ sessionId: i.id, title: i.title, earlier: null, messages: [], latestRun: null }), u.value = [i, ...u.value.filter((d) => d.id !== i.id)], !0);
|
|
4915
|
+
} catch (i) {
|
|
4916
|
+
return f === te && (E.value = i instanceof Error ? i.message : String(i)), !1;
|
|
4897
4917
|
} finally {
|
|
4898
|
-
|
|
4918
|
+
f === te && (_.value = !1);
|
|
4899
4919
|
}
|
|
4900
4920
|
}
|
|
4901
|
-
async function
|
|
4902
|
-
|
|
4921
|
+
async function xe(f) {
|
|
4922
|
+
z.value = !0, h.value = "";
|
|
4903
4923
|
try {
|
|
4904
|
-
const
|
|
4905
|
-
u.value =
|
|
4906
|
-
} catch (
|
|
4907
|
-
|
|
4924
|
+
const i = await r.listChats(f);
|
|
4925
|
+
u.value = f ? [...u.value, ...i.chats] : i.chats, M.value = i.cursor;
|
|
4926
|
+
} catch (i) {
|
|
4927
|
+
h.value = i instanceof Error ? i.message : String(i);
|
|
4908
4928
|
} finally {
|
|
4909
|
-
|
|
4929
|
+
z.value = !1;
|
|
4910
4930
|
}
|
|
4911
4931
|
}
|
|
4912
|
-
async function
|
|
4913
|
-
if (!
|
|
4914
|
-
const
|
|
4915
|
-
|
|
4932
|
+
async function b() {
|
|
4933
|
+
if (!x.value || w.value) return;
|
|
4934
|
+
const f = x.value, i = o.value;
|
|
4935
|
+
w.value = !0;
|
|
4916
4936
|
try {
|
|
4917
|
-
const
|
|
4918
|
-
if (
|
|
4919
|
-
a.value = [...
|
|
4920
|
-
} catch (
|
|
4921
|
-
|
|
4937
|
+
const d = await r.getChat({ sessionId: i, before: f });
|
|
4938
|
+
if (i !== o.value) return;
|
|
4939
|
+
a.value = [...d.messages, ...a.value], x.value = d.earlier ?? null;
|
|
4940
|
+
} catch (d) {
|
|
4941
|
+
E.value = d instanceof Error ? d.message : String(d);
|
|
4922
4942
|
} finally {
|
|
4923
|
-
|
|
4943
|
+
w.value = !1;
|
|
4924
4944
|
}
|
|
4925
4945
|
}
|
|
4926
|
-
const
|
|
4927
|
-
function
|
|
4928
|
-
|
|
4946
|
+
const C = /* @__PURE__ */ new Map();
|
|
4947
|
+
function D(f, i) {
|
|
4948
|
+
o.value && C.set(o.value, Lt(f, _t(i)));
|
|
4929
4949
|
}
|
|
4930
|
-
function
|
|
4931
|
-
return
|
|
4950
|
+
function q() {
|
|
4951
|
+
return o.value && C.get(o.value) || { text: "", targets: [] };
|
|
4932
4952
|
}
|
|
4933
|
-
function
|
|
4934
|
-
|
|
4953
|
+
function X(f) {
|
|
4954
|
+
F.value.includes(f) || (F.value = [...F.value, f]);
|
|
4935
4955
|
}
|
|
4936
|
-
async function
|
|
4937
|
-
const
|
|
4938
|
-
if (!g.value ||
|
|
4939
|
-
|
|
4956
|
+
async function l() {
|
|
4957
|
+
const f = o.value;
|
|
4958
|
+
if (!g.value || H.value || !f) return null;
|
|
4959
|
+
H.value = !0;
|
|
4940
4960
|
try {
|
|
4941
|
-
await r.stopChat(
|
|
4942
|
-
} catch (
|
|
4943
|
-
return
|
|
4944
|
-
}
|
|
4945
|
-
const
|
|
4946
|
-
return
|
|
4947
|
-
}
|
|
4948
|
-
function
|
|
4949
|
-
const
|
|
4950
|
-
return
|
|
4951
|
-
}
|
|
4952
|
-
function
|
|
4953
|
-
const
|
|
4954
|
-
return !
|
|
4955
|
-
}
|
|
4956
|
-
function
|
|
4957
|
-
const
|
|
4958
|
-
if (
|
|
4959
|
-
const
|
|
4960
|
-
|
|
4961
|
+
await r.stopChat(f);
|
|
4962
|
+
} catch (d) {
|
|
4963
|
+
return H.value = !1, E.value = d instanceof Error ? d.message : String(d), null;
|
|
4964
|
+
}
|
|
4965
|
+
const i = [...a.value].reverse().find((d) => d.role === "user");
|
|
4966
|
+
return i ? s(i.id) : null;
|
|
4967
|
+
}
|
|
4968
|
+
function s(f) {
|
|
4969
|
+
const i = a.value.find((d) => d.id === f && d.role === "user");
|
|
4970
|
+
return i ? St(i) : null;
|
|
4971
|
+
}
|
|
4972
|
+
function W(f) {
|
|
4973
|
+
const i = a.value.find((d) => d.id === f);
|
|
4974
|
+
return !i || !F.value.includes(f) ? null : (a.value = a.value.filter((d) => d.id !== f), F.value = F.value.filter((d) => d !== f), St(i));
|
|
4975
|
+
}
|
|
4976
|
+
function U(f, i) {
|
|
4977
|
+
const d = a.value[a.value.length - 1];
|
|
4978
|
+
if (d && d.role === "assistant" && d.id === f) {
|
|
4979
|
+
const S = [...d.parts];
|
|
4980
|
+
i(S), a.value = [...a.value.slice(0, -1), { ...d, parts: S }];
|
|
4961
4981
|
return;
|
|
4962
4982
|
}
|
|
4963
|
-
const
|
|
4964
|
-
|
|
4983
|
+
const T = [];
|
|
4984
|
+
i(T), a.value = [...a.value, { id: f, role: "assistant", parts: T }];
|
|
4965
4985
|
}
|
|
4966
|
-
function
|
|
4967
|
-
for (let
|
|
4968
|
-
const
|
|
4969
|
-
if (
|
|
4970
|
-
|
|
4986
|
+
function de(f, i, d) {
|
|
4987
|
+
for (let T = f.length - 1; T >= 0; T -= 1) {
|
|
4988
|
+
const S = f[T];
|
|
4989
|
+
if (S.type === "text" && S.id === i) {
|
|
4990
|
+
f[T] = { ...S, text: String(S.text ?? "") + d };
|
|
4971
4991
|
return;
|
|
4972
4992
|
}
|
|
4973
4993
|
}
|
|
4974
|
-
|
|
4994
|
+
f.push({ type: "text", id: i, text: d, state: "streaming" });
|
|
4975
4995
|
}
|
|
4976
|
-
function
|
|
4977
|
-
for (let
|
|
4978
|
-
const
|
|
4979
|
-
if (
|
|
4980
|
-
return
|
|
4996
|
+
function Ie(f, i, d) {
|
|
4997
|
+
for (let T = f.length - 1; T >= 0; T -= 1) {
|
|
4998
|
+
const S = f[T];
|
|
4999
|
+
if (S.type.startsWith("tool-") && S.toolCallId === i)
|
|
5000
|
+
return f[T] = { ...S, ...d }, !0;
|
|
4981
5001
|
}
|
|
4982
5002
|
return !1;
|
|
4983
5003
|
}
|
|
4984
|
-
function
|
|
4985
|
-
|
|
5004
|
+
function he(f, i) {
|
|
5005
|
+
f.named || (R.value = ht(R.value, Mt(i)));
|
|
4986
5006
|
}
|
|
4987
|
-
function Ne(
|
|
4988
|
-
const
|
|
4989
|
-
if (
|
|
4990
|
-
|
|
5007
|
+
function Ne(f, i) {
|
|
5008
|
+
const d = String(f.type ?? ""), T = i.id;
|
|
5009
|
+
if (d === "start-step") {
|
|
5010
|
+
U(T, (S) => S.push({ type: "step-start" }));
|
|
4991
5011
|
return;
|
|
4992
5012
|
}
|
|
4993
|
-
if (
|
|
4994
|
-
const
|
|
4995
|
-
|
|
4996
|
-
|
|
4997
|
-
(
|
|
5013
|
+
if (d === "text-start") {
|
|
5014
|
+
const S = String(f.id ?? "text");
|
|
5015
|
+
U(
|
|
5016
|
+
T,
|
|
5017
|
+
(B) => B.push({ type: "text", id: S, text: "", state: "streaming" })
|
|
4998
5018
|
);
|
|
4999
5019
|
return;
|
|
5000
5020
|
}
|
|
5001
|
-
if (
|
|
5002
|
-
const
|
|
5003
|
-
|
|
5021
|
+
if (d === "text-delta") {
|
|
5022
|
+
const S = String(f.id ?? "text");
|
|
5023
|
+
U(T, (B) => de(B, S, String(f.delta ?? "")));
|
|
5004
5024
|
return;
|
|
5005
5025
|
}
|
|
5006
|
-
if (
|
|
5007
|
-
const
|
|
5008
|
-
|
|
5009
|
-
for (let
|
|
5010
|
-
if (
|
|
5011
|
-
|
|
5026
|
+
if (d === "text-end") {
|
|
5027
|
+
const S = String(f.id ?? "text");
|
|
5028
|
+
U(T, (B) => {
|
|
5029
|
+
for (let J = B.length - 1; J >= 0; J -= 1)
|
|
5030
|
+
if (B[J].type === "text" && B[J].id === S) {
|
|
5031
|
+
B[J] = { ...B[J], state: "done" };
|
|
5012
5032
|
return;
|
|
5013
5033
|
}
|
|
5014
5034
|
});
|
|
5015
5035
|
return;
|
|
5016
5036
|
}
|
|
5017
|
-
if (
|
|
5018
|
-
const
|
|
5019
|
-
|
|
5020
|
-
|
|
5021
|
-
(
|
|
5037
|
+
if (d === "tool-input-start") {
|
|
5038
|
+
const S = String(f.toolName ?? ""), B = String(f.toolCallId ?? lt());
|
|
5039
|
+
he(i, S), U(
|
|
5040
|
+
T,
|
|
5041
|
+
(J) => J.push({ type: `tool-${S}`, toolCallId: B, state: "input-streaming" })
|
|
5022
5042
|
);
|
|
5023
5043
|
return;
|
|
5024
5044
|
}
|
|
5025
|
-
if (
|
|
5026
|
-
const
|
|
5027
|
-
|
|
5028
|
-
!
|
|
5029
|
-
}), typeof
|
|
5045
|
+
if (d === "tool-input-available" || d === "tool-output-available") {
|
|
5046
|
+
const S = String(f.toolCallId ?? ""), B = d === "tool-input-available" ? "input-available" : "output-available";
|
|
5047
|
+
U(T, (J) => {
|
|
5048
|
+
!Ie(J, S, { state: B }) && typeof f.toolName == "string" && J.push({ type: `tool-${f.toolName}`, toolCallId: S, state: B });
|
|
5049
|
+
}), typeof f.toolName == "string" && he(i, f.toolName);
|
|
5030
5050
|
return;
|
|
5031
5051
|
}
|
|
5032
|
-
if (
|
|
5033
|
-
const
|
|
5034
|
-
|
|
5052
|
+
if (d === "tool-output-error") {
|
|
5053
|
+
const S = String(f.toolCallId ?? "");
|
|
5054
|
+
U(T, (B) => Ie(B, S, { state: "output-error" }));
|
|
5035
5055
|
return;
|
|
5036
5056
|
}
|
|
5037
|
-
if (
|
|
5038
|
-
const
|
|
5039
|
-
|
|
5040
|
-
|
|
5057
|
+
if (d === "error") {
|
|
5058
|
+
const S = String(f.errorText ?? "stream error");
|
|
5059
|
+
U(T, (B) => {
|
|
5060
|
+
B.push({ type: "step-start" }), B.push({ type: "text", id: "turn-error", text: S, state: "done" });
|
|
5041
5061
|
});
|
|
5042
5062
|
return;
|
|
5043
5063
|
}
|
|
5044
|
-
if (
|
|
5045
|
-
const
|
|
5046
|
-
|
|
5064
|
+
if (d.startsWith("data-")) {
|
|
5065
|
+
const S = d.slice(5), B = f.data ?? {};
|
|
5066
|
+
S === "plan" && typeof B.sessionId == "string" && (i.acked = !0, k.value = !0, o.value = B.sessionId, Qe(Je(v(t.value), r.key), B.sessionId)), S === "step" && typeof B.step == "string" ? (i.named = !0, R.value = ht(R.value, B.step)) : he(i, S), U(T, (J) => J.push({ type: d, data: B })), ne.forEach((J) => J({ name: S, data: B }));
|
|
5047
5067
|
}
|
|
5048
5068
|
}
|
|
5049
|
-
function Re(
|
|
5050
|
-
if (
|
|
5051
|
-
const
|
|
5052
|
-
|
|
5053
|
-
(
|
|
5069
|
+
function Re(f) {
|
|
5070
|
+
if (y.value && y.value !== Wr) return;
|
|
5071
|
+
const i = f.length > kt ? `${f.slice(0, kt - 1)}…` : f;
|
|
5072
|
+
y.value = i, u.value = u.value.map(
|
|
5073
|
+
(d) => d.id === o.value ? { ...d, title: i } : d
|
|
5054
5074
|
);
|
|
5055
5075
|
}
|
|
5056
|
-
async function Me(
|
|
5057
|
-
const
|
|
5058
|
-
if (!
|
|
5059
|
-
const
|
|
5060
|
-
|
|
5061
|
-
const
|
|
5076
|
+
async function Me(f, i) {
|
|
5077
|
+
const d = f.trim();
|
|
5078
|
+
if (!d || I.value || Q.value) return;
|
|
5079
|
+
const T = _t(i);
|
|
5080
|
+
E.value = "", P.value = !1;
|
|
5081
|
+
const S = {
|
|
5062
5082
|
id: lt(),
|
|
5063
5083
|
role: "user",
|
|
5064
|
-
parts: [{ type: "text", text:
|
|
5084
|
+
parts: [{ type: "text", text: d }]
|
|
5065
5085
|
};
|
|
5066
5086
|
a.value = [
|
|
5067
5087
|
...a.value,
|
|
5068
5088
|
{
|
|
5069
|
-
...
|
|
5089
|
+
...S,
|
|
5070
5090
|
parts: [
|
|
5071
|
-
...
|
|
5072
|
-
...
|
|
5091
|
+
...S.parts,
|
|
5092
|
+
...T.map((le) => ({ type: "data-edit-target", data: le }))
|
|
5073
5093
|
]
|
|
5074
5094
|
}
|
|
5075
|
-
], Re(
|
|
5076
|
-
const
|
|
5077
|
-
|
|
5078
|
-
},
|
|
5095
|
+
], Re(d), k.value = !1, I.value = !0, R.value = null, G.value = !1, m.value = null, Y.value = Date.now(), L.value = `assistant-${Date.now()}`;
|
|
5096
|
+
const B = { id: L.value, acked: !1 }, J = setTimeout(() => {
|
|
5097
|
+
G.value = !0;
|
|
5098
|
+
}, Ke);
|
|
5079
5099
|
let tt = !1;
|
|
5080
5100
|
try {
|
|
5081
5101
|
const le = await fetch(
|
|
5082
|
-
|
|
5102
|
+
Yt(r.chatPath(t.value)),
|
|
5083
5103
|
{
|
|
5084
5104
|
method: "POST",
|
|
5085
5105
|
headers: {
|
|
@@ -5088,134 +5108,203 @@ function mo(e) {
|
|
|
5088
5108
|
},
|
|
5089
5109
|
// `target` alone is a one-part message, and all a server reading one part reads
|
|
5090
5110
|
body: JSON.stringify({
|
|
5091
|
-
sessionId:
|
|
5092
|
-
target:
|
|
5093
|
-
...
|
|
5094
|
-
message:
|
|
5111
|
+
sessionId: o.value,
|
|
5112
|
+
target: T[0],
|
|
5113
|
+
...T.length > 1 ? { targets: T } : {},
|
|
5114
|
+
message: S
|
|
5095
5115
|
})
|
|
5096
5116
|
}
|
|
5097
5117
|
);
|
|
5098
5118
|
if (!le.ok || !le.body) {
|
|
5099
5119
|
const Ae = await le.json().catch(() => null);
|
|
5100
5120
|
if (typeof (Ae == null ? void 0 : Ae.message) == "string") {
|
|
5101
|
-
|
|
5121
|
+
E.value = Ae.message, a.value = a.value.filter((Ve) => Ve.id !== S.id);
|
|
5102
5122
|
return;
|
|
5103
5123
|
}
|
|
5104
|
-
console.warn("[report-canvas] chat rejected", { subject: r.key, status: le.status }),
|
|
5124
|
+
console.warn("[report-canvas] chat rejected", { subject: r.key, status: le.status }), X(S.id);
|
|
5105
5125
|
return;
|
|
5106
5126
|
}
|
|
5107
|
-
const
|
|
5127
|
+
const jt = le.body.getReader(), $t = new TextDecoder();
|
|
5108
5128
|
let qe = "";
|
|
5109
5129
|
for (; ; ) {
|
|
5110
|
-
const { done: Ae, value: Ve } = await
|
|
5130
|
+
const { done: Ae, value: Ve } = await jt.read();
|
|
5111
5131
|
if (Ae) break;
|
|
5112
|
-
qe +=
|
|
5132
|
+
qe += $t.decode(Ve, { stream: !0 });
|
|
5113
5133
|
const nt = qe.split(`
|
|
5114
5134
|
|
|
5115
5135
|
`);
|
|
5116
5136
|
qe = nt.pop() ?? "";
|
|
5117
|
-
for (const
|
|
5118
|
-
for (const at of
|
|
5137
|
+
for (const Dt of nt)
|
|
5138
|
+
for (const at of Dt.split(`
|
|
5119
5139
|
`)) {
|
|
5120
5140
|
if (!at.startsWith("data:")) continue;
|
|
5121
5141
|
const Fe = at.slice(5).trim();
|
|
5122
5142
|
if (!(!Fe || Fe === "[DONE]"))
|
|
5123
5143
|
try {
|
|
5124
|
-
Ne(JSON.parse(Fe),
|
|
5144
|
+
Ne(JSON.parse(Fe), B);
|
|
5125
5145
|
} catch {
|
|
5126
5146
|
}
|
|
5127
5147
|
}
|
|
5128
5148
|
}
|
|
5129
5149
|
} catch (le) {
|
|
5130
|
-
console.warn("[report-canvas] chat stream failed", { subject: r.key, err: le }),
|
|
5150
|
+
console.warn("[report-canvas] chat stream failed", { subject: r.key, err: le }), B.acked ? (P.value = !0, tt = !0) : X(S.id);
|
|
5131
5151
|
} finally {
|
|
5132
|
-
clearTimeout(
|
|
5152
|
+
clearTimeout(J), I.value = !1, R.value = null, G.value = !1, Y.value = null, ee.forEach((le) => le()), tt && se(!0);
|
|
5133
5153
|
}
|
|
5134
5154
|
}
|
|
5135
5155
|
return {
|
|
5136
5156
|
messages: a,
|
|
5137
|
-
sessionId:
|
|
5138
|
-
title:
|
|
5139
|
-
earlier:
|
|
5140
|
-
loadingEarlier:
|
|
5157
|
+
sessionId: o,
|
|
5158
|
+
title: y,
|
|
5159
|
+
earlier: x,
|
|
5160
|
+
loadingEarlier: w,
|
|
5141
5161
|
chats: u,
|
|
5142
|
-
chatsCursor:
|
|
5143
|
-
chatsLoading:
|
|
5144
|
-
chatsError:
|
|
5145
|
-
switching:
|
|
5146
|
-
streaming:
|
|
5147
|
-
turnId:
|
|
5148
|
-
step:
|
|
5149
|
-
error:
|
|
5150
|
-
interrupted:
|
|
5151
|
-
unsent:
|
|
5152
|
-
slow:
|
|
5153
|
-
startedAt:
|
|
5154
|
-
awaiting:
|
|
5155
|
-
noReplyId:
|
|
5162
|
+
chatsCursor: M,
|
|
5163
|
+
chatsLoading: z,
|
|
5164
|
+
chatsError: h,
|
|
5165
|
+
switching: _,
|
|
5166
|
+
streaming: I,
|
|
5167
|
+
turnId: L,
|
|
5168
|
+
step: R,
|
|
5169
|
+
error: E,
|
|
5170
|
+
interrupted: P,
|
|
5171
|
+
unsent: F,
|
|
5172
|
+
slow: G,
|
|
5173
|
+
startedAt: Y,
|
|
5174
|
+
awaiting: Q,
|
|
5175
|
+
noReplyId: m,
|
|
5156
5176
|
stoppable: g,
|
|
5157
|
-
stopping:
|
|
5158
|
-
stop:
|
|
5159
|
-
load:
|
|
5160
|
-
select:
|
|
5161
|
-
startChat:
|
|
5162
|
-
loadChats:
|
|
5163
|
-
loadEarlier:
|
|
5164
|
-
stashDraft:
|
|
5165
|
-
recallDraft:
|
|
5166
|
-
takeUnsent:
|
|
5167
|
-
requestOf:
|
|
5177
|
+
stopping: H,
|
|
5178
|
+
stop: l,
|
|
5179
|
+
load: ke,
|
|
5180
|
+
select: _e,
|
|
5181
|
+
startChat: Se,
|
|
5182
|
+
loadChats: xe,
|
|
5183
|
+
loadEarlier: b,
|
|
5184
|
+
stashDraft: D,
|
|
5185
|
+
recallDraft: q,
|
|
5186
|
+
takeUnsent: W,
|
|
5187
|
+
requestOf: s,
|
|
5168
5188
|
send: Me,
|
|
5169
|
-
onLifecycle:
|
|
5170
|
-
onSettled:
|
|
5171
|
-
onResumed:
|
|
5189
|
+
onLifecycle: ae,
|
|
5190
|
+
onSettled: ve,
|
|
5191
|
+
onResumed: ye
|
|
5172
5192
|
};
|
|
5173
5193
|
}
|
|
5174
|
-
const
|
|
5175
|
-
function
|
|
5176
|
-
const n =
|
|
5177
|
-
let
|
|
5178
|
-
|
|
5179
|
-
!n.value || typeof ResizeObserver > "u" || (
|
|
5180
|
-
a.value =
|
|
5181
|
-
}),
|
|
5182
|
-
}),
|
|
5183
|
-
const
|
|
5184
|
-
() => !a.value || a.value >=
|
|
5185
|
-
),
|
|
5194
|
+
const Xr = 380, Kr = 600, It = 'button:not([disabled]),textarea:not([disabled]),select:not([disabled]),a[href],[tabindex]:not([tabindex="-1"])';
|
|
5195
|
+
function ko(e, t) {
|
|
5196
|
+
const n = O(), r = O(), a = O(0);
|
|
5197
|
+
let o, y = !1;
|
|
5198
|
+
Pe(() => {
|
|
5199
|
+
!n.value || typeof ResizeObserver > "u" || (o = new ResizeObserver(([z]) => {
|
|
5200
|
+
a.value = z.contentRect.width, !y && (y = !0, x.value || (e.value = !1));
|
|
5201
|
+
}), o.observe(n.value));
|
|
5202
|
+
}), Le(() => o == null ? void 0 : o.disconnect());
|
|
5203
|
+
const x = $(
|
|
5204
|
+
() => !a.value || a.value >= Xr + Kr
|
|
5205
|
+
), w = $(() => e.value && !x.value && !t.value);
|
|
5186
5206
|
let u = null;
|
|
5187
|
-
|
|
5188
|
-
var
|
|
5189
|
-
if (
|
|
5190
|
-
u = document.activeElement, await
|
|
5207
|
+
ie(w, async (z) => {
|
|
5208
|
+
var h, _, I;
|
|
5209
|
+
if (z) {
|
|
5210
|
+
u = document.activeElement, await we(), (_ = (h = r.value) == null ? void 0 : h.querySelector(It)) == null || _.focus();
|
|
5191
5211
|
return;
|
|
5192
5212
|
}
|
|
5193
|
-
(
|
|
5213
|
+
(I = u == null ? void 0 : u.focus) == null || I.call(u), u = null;
|
|
5194
5214
|
});
|
|
5195
|
-
function
|
|
5196
|
-
if (
|
|
5197
|
-
const
|
|
5198
|
-
if (!
|
|
5199
|
-
const
|
|
5200
|
-
document.activeElement ===
|
|
5201
|
-
}
|
|
5202
|
-
return
|
|
5215
|
+
function M(z) {
|
|
5216
|
+
if (z.key !== "Tab" || !w.value || !r.value) return;
|
|
5217
|
+
const h = [...r.value.querySelectorAll(It)];
|
|
5218
|
+
if (!h.length) return;
|
|
5219
|
+
const _ = z.shiftKey ? h[0] : h[h.length - 1];
|
|
5220
|
+
document.activeElement === _ && (z.preventDefault(), (z.shiftKey ? h[h.length - 1] : h[0]).focus());
|
|
5221
|
+
}
|
|
5222
|
+
return Pe(() => window.addEventListener("keydown", M, !0)), Le(() => window.removeEventListener("keydown", M, !0)), { root: n, drawer: r, docked: x, modal: w };
|
|
5223
|
+
}
|
|
5224
|
+
const At = 24;
|
|
5225
|
+
function Jr(e, t) {
|
|
5226
|
+
var n, r, a, o, y, x, w, u, M, z, h, _;
|
|
5227
|
+
return e.sectionId === t.sectionId && ((n = e.element) == null ? void 0 : n.part) === ((r = t.element) == null ? void 0 : r.part) && (((a = e.element) == null ? void 0 : a.path) ?? []).join(".") === (((o = t.element) == null ? void 0 : o.path) ?? []).join(".") && ((x = (y = e.element) == null ? void 0 : y.datum) == null ? void 0 : x.datasetIndex) === ((u = (w = t.element) == null ? void 0 : w.datum) == null ? void 0 : u.datasetIndex) && ((z = (M = e.element) == null ? void 0 : M.datum) == null ? void 0 : z.index) === ((_ = (h = t.element) == null ? void 0 : h.datum) == null ? void 0 : _.index);
|
|
5228
|
+
}
|
|
5229
|
+
const _o = (e) => e.map((t) => ({ targets: [t], widen: [] }));
|
|
5230
|
+
function So(e, t) {
|
|
5231
|
+
const n = O([]), r = O([]), a = $({
|
|
5232
|
+
get: () => e.value ? n.value : r.value,
|
|
5233
|
+
set: (h) => {
|
|
5234
|
+
e.value ? n.value = h : r.value = h;
|
|
5235
|
+
}
|
|
5236
|
+
}), o = $(() => a.value.flatMap((h) => h.targets)), y = $(() => a.value.map((h) => h.targets[0])), x = $(
|
|
5237
|
+
() => a.value.map(({ targets: [h, ..._] }) => {
|
|
5238
|
+
if (!_.length) return h;
|
|
5239
|
+
const I = [h, ..._];
|
|
5240
|
+
return {
|
|
5241
|
+
sectionId: h.sectionId,
|
|
5242
|
+
version: h.version,
|
|
5243
|
+
label: [...new Set(I.map((L) => L.label).filter(Boolean))].join(", "),
|
|
5244
|
+
elementText: I.map((L) => L.elementText).filter(Boolean).join(" · "),
|
|
5245
|
+
area: h.area
|
|
5246
|
+
};
|
|
5247
|
+
})
|
|
5248
|
+
), w = $(
|
|
5249
|
+
() => o.value.some(
|
|
5250
|
+
(h) => !t.sections().some((_) => _.id === h.sectionId && _.version === h.version)
|
|
5251
|
+
)
|
|
5252
|
+
);
|
|
5253
|
+
function u(h, _) {
|
|
5254
|
+
const I = t.named(h);
|
|
5255
|
+
if (!I) return !1;
|
|
5256
|
+
const L = a.value.findIndex(
|
|
5257
|
+
(R) => !R.targets[0].area && Jr(R.targets[0], I)
|
|
5258
|
+
);
|
|
5259
|
+
return L >= 0 ? a.value = a.value.filter((R, E) => E !== L) : o.value.length < At && (a.value = [...a.value, { targets: [I], widen: _ }]), !0;
|
|
5260
|
+
}
|
|
5261
|
+
function M(h) {
|
|
5262
|
+
const _ = h.map((I) => t.named(I));
|
|
5263
|
+
return !_.length || !_.every((I) => !!I) || o.value.length + _.length > At ? !1 : (a.value = [...a.value, { targets: _, widen: [] }], !0);
|
|
5264
|
+
}
|
|
5265
|
+
function z(h) {
|
|
5266
|
+
const _ = a.value[h];
|
|
5267
|
+
if (!_) return;
|
|
5268
|
+
const [I] = _.targets;
|
|
5269
|
+
if (!I.element || I.area) {
|
|
5270
|
+
a.value = a.value.filter((G, Y) => Y !== h);
|
|
5271
|
+
return;
|
|
5272
|
+
}
|
|
5273
|
+
const { element: L, ...R } = I, [E, ...P] = _.widen, F = E ? { ...R, element: E, elementText: E.text ?? "", elementTag: E.tag } : R;
|
|
5274
|
+
a.value = a.value.map(
|
|
5275
|
+
(G, Y) => Y === h ? { targets: [F], widen: P } : G
|
|
5276
|
+
);
|
|
5277
|
+
}
|
|
5278
|
+
return {
|
|
5279
|
+
homePicks: n,
|
|
5280
|
+
threadPicks: r,
|
|
5281
|
+
picks: a,
|
|
5282
|
+
targets: o,
|
|
5283
|
+
outlines: y,
|
|
5284
|
+
chips: x,
|
|
5285
|
+
stale: w,
|
|
5286
|
+
toggle: u,
|
|
5287
|
+
addArea: M,
|
|
5288
|
+
widen: z
|
|
5289
|
+
};
|
|
5203
5290
|
}
|
|
5204
5291
|
export {
|
|
5205
|
-
|
|
5206
|
-
|
|
5207
|
-
|
|
5208
|
-
|
|
5209
|
-
|
|
5210
|
-
|
|
5211
|
-
|
|
5212
|
-
|
|
5213
|
-
|
|
5214
|
-
|
|
5215
|
-
|
|
5216
|
-
|
|
5217
|
-
|
|
5218
|
-
|
|
5219
|
-
|
|
5220
|
-
|
|
5292
|
+
ho as R,
|
|
5293
|
+
go as a,
|
|
5294
|
+
ko as b,
|
|
5295
|
+
So as c,
|
|
5296
|
+
wo as d,
|
|
5297
|
+
xo as e,
|
|
5298
|
+
bo as f,
|
|
5299
|
+
_o as g,
|
|
5300
|
+
mo as h,
|
|
5301
|
+
yo as i,
|
|
5302
|
+
vo as j,
|
|
5303
|
+
fo as k,
|
|
5304
|
+
co as l,
|
|
5305
|
+
io as m,
|
|
5306
|
+
so as n,
|
|
5307
|
+
lo as p,
|
|
5308
|
+
uo as r,
|
|
5309
|
+
po as u
|
|
5221
5310
|
};
|