@feedmepos/mf-report 5.29.0 → 5.29.1-beta.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-CuBsRwfx.js → App-BRFozj-7.js} +37 -37
- package/dist/{DateRangeSelect-CzjlwjuC.js → DateRangeSelect-CY9lQk9O.js} +1 -1
- package/dist/{Default.vue_vue_type_script_setup_true_lang-Di9_F5Yk.js → Default.vue_vue_type_script_setup_true_lang-DuZTTG1H.js} +1 -1
- package/dist/{DynamicWidget.vue_vue_type_script_setup_true_lang-C73R6Fb9.js → DynamicWidget.vue_vue_type_script_setup_true_lang-bnIG7A2w.js} +4 -4
- package/dist/{GlobalFilterSelect.vue_vue_type_script_setup_true_lang-tLRFdLNs.js → GlobalFilterSelect.vue_vue_type_script_setup_true_lang-BbubkomY.js} +3 -3
- package/dist/{InsightView-BcnmLQ8c.js → InsightView-Cw0d1T2r.js} +5 -5
- package/dist/{Integration-D4VFT1M8.js → Integration-CSTHODqa.js} +3 -3
- package/dist/{Integrations-v8oF1TL7.js → Integrations-Czl-Yv9S.js} +2 -2
- package/dist/{Layout-Ds8RSWmi.js → Layout-CJwCC3Uf.js} +1 -1
- package/dist/{LocationSelect.vue_vue_type_script_setup_true_lang-Dk6u8nUH.js → LocationSelect.vue_vue_type_script_setup_true_lang-8Hv1sIhl.js} +2 -2
- package/dist/{MenuTab.vue_vue_type_script_setup_true_lang-BWt7pqFb.js → MenuTab.vue_vue_type_script_setup_true_lang-BB1JB_pS.js} +5 -5
- package/dist/{NavigationTab.vue_vue_type_script_setup_true_lang-CU00GINo.js → NavigationTab.vue_vue_type_script_setup_true_lang-Bm1uHnfi.js} +5 -5
- package/dist/{OverviewView-1v80g6KX.js → OverviewView-Cvt1TJTy.js} +5 -5
- package/dist/{Report-DcFB4gM6.js → Report-6oNosGZN.js} +3 -3
- package/dist/{ReportCanvasView-BQO6Mywc.js → ReportCanvasView-Cf1dZVLA.js} +1337 -1336
- package/dist/{ReportEditor-Bgcisf1s.js → ReportEditor-VrVEGn2u.js} +7 -7
- package/dist/{ReportView-Q_juD8Kr.js → ReportView-BhdPcwXo.js} +6 -6
- package/dist/{ReportViewRoute-DwStGqyz.js → ReportViewRoute-Bgx2m8bt.js} +2 -2
- package/dist/{Setting-C9rlM23O.js → Setting-zR3WRkGA.js} +3 -3
- package/dist/{Template-BZd0NB5w.js → Template-BkO8QIuN.js} +3 -3
- package/dist/{TileEditor-B2F9r3RS.js → TileEditor-DDAO3Otq.js} +6 -6
- package/dist/{TilePageStack.vue_vue_type_script_setup_true_lang-BmbrJAph.js → TilePageStack.vue_vue_type_script_setup_true_lang-CJryyAHS.js} +2 -2
- package/dist/{TransitionFade-Dkeo9qr0.js → TransitionFade-DTHgx7Zd.js} +5 -5
- package/dist/{app-CoQ_GRKo.js → app-Ww74M1IV.js} +14 -14
- package/dist/app.js +1 -1
- package/dist/{report-Dau_so1j.js → report-DrmmYKVT.js} +1 -1
- package/dist/style.css +1 -1
- package/dist/{useRestaurantPermission-CPoHZTxx.js → useRestaurantPermission-aoS-2LVx.js} +1 -1
- package/package.json +1 -1
|
@@ -1,50 +1,50 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { useRoute as
|
|
3
|
-
import { u as
|
|
4
|
-
import { storeToRefs as
|
|
5
|
-
import { r as
|
|
6
|
-
import { _ as
|
|
7
|
-
import { D as
|
|
8
|
-
import { detectLocale as
|
|
9
|
-
import { v as
|
|
10
|
-
import { r as
|
|
11
|
-
const
|
|
1
|
+
import { defineComponent as je, computed as V, ref as T, createElementBlock as p, createCommentVNode as R, openBlock as c, createElementVNode as w, toDisplayString as k, unref as s, Fragment as ve, renderList as Se, onMounted as Me, watch as de, nextTick as Ee, resolveComponent as Ie, createVNode as Z, createTextVNode as Ft, normalizeClass as Pe, h as Ae, mergeModels as kt, useModel as _t, createBlock as me, withCtx as $e, mergeProps as St, onBeforeUnmount as De, shallowRef as gn, withDirectives as vn, isRef as It, vShow as yn } from "vue";
|
|
2
|
+
import { useRoute as xn, useRouter as wn } from "vue-router";
|
|
3
|
+
import { u as Ve, _ as ut } from "./_plugin-vue_export-helper-C6QDExPN.js";
|
|
4
|
+
import { storeToRefs as Oe } from "pinia";
|
|
5
|
+
import { r as ue, F as pe, u as Ye, a as pt, V as kn, W as _n, h as Sn } from "./app-Ww74M1IV.js";
|
|
6
|
+
import { _ as In } from "./LocationSelect.vue_vue_type_script_setup_true_lang-8Hv1sIhl.js";
|
|
7
|
+
import { D as Cn } from "./DateRangeSelect-CY9lQk9O.js";
|
|
8
|
+
import { detectLocale as An } from "@feedmepos/mf-common";
|
|
9
|
+
import { v as Ct, u as Tn } from "./report-DrmmYKVT.js";
|
|
10
|
+
import { r as En } from "./i18n-DbyciK4x.js";
|
|
11
|
+
const On = {
|
|
12
12
|
key: 0,
|
|
13
13
|
class: "flex flex-col gap-4"
|
|
14
|
-
},
|
|
14
|
+
}, zn = {
|
|
15
15
|
key: 0,
|
|
16
16
|
"data-testid": "report-canvas-activity",
|
|
17
17
|
class: "flex items-start gap-8"
|
|
18
|
-
},
|
|
18
|
+
}, Nn = { class: "min-w-0 grow" }, $n = {
|
|
19
19
|
class: "fm-typo-en-body-md-400",
|
|
20
20
|
role: "status"
|
|
21
|
-
},
|
|
21
|
+
}, Rn = {
|
|
22
22
|
key: 0,
|
|
23
23
|
"data-testid": "report-canvas-prepared",
|
|
24
24
|
class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary"
|
|
25
|
-
},
|
|
25
|
+
}, Ln = {
|
|
26
26
|
key: 1,
|
|
27
27
|
class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary"
|
|
28
|
-
},
|
|
28
|
+
}, Mn = {
|
|
29
29
|
key: 1,
|
|
30
30
|
"data-testid": "report-canvas-interrupted",
|
|
31
31
|
class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary"
|
|
32
|
-
},
|
|
32
|
+
}, Pn = {
|
|
33
33
|
key: 2,
|
|
34
34
|
"data-testid": "report-canvas-stalled",
|
|
35
35
|
class: "flex flex-col items-start gap-4"
|
|
36
|
-
},
|
|
36
|
+
}, Dn = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-error" }, jn = {
|
|
37
37
|
key: 3,
|
|
38
38
|
"data-testid": "report-canvas-failed",
|
|
39
39
|
class: "flex flex-col gap-4"
|
|
40
|
-
},
|
|
40
|
+
}, Vn = { class: "min-w-0 grow" }, Fn = { class: "fm-typo-en-body-sm-600 truncate" }, Bn = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary" }, qn = ["onClick"], Un = {
|
|
41
41
|
key: 4,
|
|
42
42
|
class: "fm-typo-en-body-sm-400 text-fm-color-typo-error"
|
|
43
|
-
},
|
|
43
|
+
}, Hn = { key: 5 }, Wn = ["aria-expanded"], Gn = {
|
|
44
44
|
key: 0,
|
|
45
45
|
"data-testid": "report-canvas-details",
|
|
46
46
|
class: "mt-4 flex flex-col gap-4"
|
|
47
|
-
},
|
|
47
|
+
}, Yn = { class: "min-w-0 grow truncate" }, Kn = { class: "shrink-0" }, At = /* @__PURE__ */ je({
|
|
48
48
|
__name: "ReportCanvasActivity",
|
|
49
49
|
props: {
|
|
50
50
|
active: { type: Boolean },
|
|
@@ -58,85 +58,85 @@ const An = {
|
|
|
58
58
|
},
|
|
59
59
|
emits: ["retry", "checkStatus"],
|
|
60
60
|
setup(o, { emit: e }) {
|
|
61
|
-
const t = o, a = e, { t: r } =
|
|
62
|
-
var
|
|
63
|
-
return ((
|
|
64
|
-
}),
|
|
65
|
-
var
|
|
66
|
-
return !!((
|
|
67
|
-
}),
|
|
68
|
-
return (
|
|
69
|
-
|
|
70
|
-
N[2] || (N[2] =
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
m.value.length ? (c(),
|
|
74
|
-
|
|
61
|
+
const t = o, a = e, { t: r } = Ve(), m = V(() => {
|
|
62
|
+
var x;
|
|
63
|
+
return ((x = t.run) == null ? void 0 : x.sections) ?? [];
|
|
64
|
+
}), h = V(() => m.value.filter((x) => x.status === "ok").length), y = V(() => m.value.filter((x) => x.status === "error")), I = V(() => {
|
|
65
|
+
var x;
|
|
66
|
+
return !!((x = t.run) != null && x.runId) && t.run.status !== "running";
|
|
67
|
+
}), b = T(!1), L = V(() => t.phases.length > 0 || m.value.length > 0);
|
|
68
|
+
return (x, N) => x.active || x.interrupted || x.stale || x.retryError || y.value.length || L.value ? (c(), p("div", On, [
|
|
69
|
+
x.active ? (c(), p("div", zn, [
|
|
70
|
+
N[2] || (N[2] = w("span", { class: "mt-2 h-12 w-12 shrink-0 animate-spin rounded-full border-2 border-fm-color-neutral-gray-200 border-t-fm-color-primary motion-reduce:animate-none" }, null, -1)),
|
|
71
|
+
w("div", Nn, [
|
|
72
|
+
w("p", $n, k(s(r)(`reportV5.reportAi.chat.phase.${x.phase}`)), 1),
|
|
73
|
+
m.value.length ? (c(), p("p", Rn, k(s(r)("reportV5.reportAi.build.prepared", { done: h.value, total: m.value.length })), 1)) : R("", !0),
|
|
74
|
+
x.slow ? (c(), p("p", Ln, k(s(r)("reportV5.reportAi.build.slow")), 1)) : R("", !0)
|
|
75
75
|
])
|
|
76
76
|
])) : R("", !0),
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
77
|
+
x.interrupted ? (c(), p("p", Mn, k(s(r)("reportV5.reportAi.build.interrupted")), 1)) : R("", !0),
|
|
78
|
+
x.stale ? (c(), p("div", Pn, [
|
|
79
|
+
w("p", Dn, k(s(r)("reportV5.reportAi.build.stalled")), 1),
|
|
80
|
+
w("button", {
|
|
81
81
|
class: "fm-typo-en-body-sm-600 text-fm-color-typo-secondary underline",
|
|
82
|
-
onClick: N[0] || (N[0] = (
|
|
83
|
-
},
|
|
82
|
+
onClick: N[0] || (N[0] = (E) => a("checkStatus"))
|
|
83
|
+
}, k(s(r)("reportV5.reportAi.build.checkStatus")), 1)
|
|
84
84
|
])) : R("", !0),
|
|
85
|
-
|
|
86
|
-
(c(!0),
|
|
87
|
-
key:
|
|
85
|
+
y.value.length ? (c(), p("ul", jn, [
|
|
86
|
+
(c(!0), p(ve, null, Se(y.value, (E) => (c(), p("li", {
|
|
87
|
+
key: E.id,
|
|
88
88
|
class: "flex items-start gap-8"
|
|
89
89
|
}, [
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
90
|
+
w("div", Vn, [
|
|
91
|
+
w("p", Fn, k(E.title), 1),
|
|
92
|
+
w("p", Bn, k(s(r)("reportV5.reportAi.build.failedWidget")), 1)
|
|
93
93
|
]),
|
|
94
|
-
I.value ? (c(),
|
|
94
|
+
I.value ? (c(), p("button", {
|
|
95
95
|
key: 0,
|
|
96
96
|
class: "fm-typo-en-body-sm-600 shrink-0 text-fm-color-typo-secondary underline",
|
|
97
|
-
onClick: (W) => a("retry",
|
|
98
|
-
},
|
|
97
|
+
onClick: (W) => a("retry", E.id)
|
|
98
|
+
}, k(s(r)("reportV5.reportAi.build.retry")), 9, qn)) : R("", !0)
|
|
99
99
|
]))), 128))
|
|
100
100
|
])) : R("", !0),
|
|
101
|
-
|
|
102
|
-
L.value ? (c(),
|
|
103
|
-
|
|
101
|
+
x.retryError ? (c(), p("p", Un, k(s(r)("reportV5.reportAi.build.retryFailed")), 1)) : R("", !0),
|
|
102
|
+
L.value ? (c(), p("div", Hn, [
|
|
103
|
+
w("button", {
|
|
104
104
|
"data-testid": "report-canvas-details-toggle",
|
|
105
105
|
class: "fm-typo-en-body-sm-600 text-fm-color-typo-secondary",
|
|
106
|
-
"aria-expanded":
|
|
107
|
-
onClick: N[1] || (N[1] = (
|
|
108
|
-
},
|
|
109
|
-
|
|
110
|
-
(c(!0),
|
|
111
|
-
key:
|
|
106
|
+
"aria-expanded": b.value,
|
|
107
|
+
onClick: N[1] || (N[1] = (E) => b.value = !b.value)
|
|
108
|
+
}, k(b.value ? "▾" : "▸") + " " + k(s(r)("reportV5.reportAi.build.details")), 9, Wn),
|
|
109
|
+
b.value ? (c(), p("div", Gn, [
|
|
110
|
+
(c(!0), p(ve, null, Se(x.phases, (E) => (c(), p("p", {
|
|
111
|
+
key: E,
|
|
112
112
|
class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary"
|
|
113
|
-
},
|
|
114
|
-
(c(!0),
|
|
115
|
-
key:
|
|
113
|
+
}, k(s(r)(`reportV5.reportAi.chat.phase.${E}`)), 1))), 128)),
|
|
114
|
+
(c(!0), p(ve, null, Se(m.value, (E) => (c(), p("p", {
|
|
115
|
+
key: E.id,
|
|
116
116
|
class: "fm-typo-en-body-sm-400 flex gap-8 text-fm-color-typo-secondary"
|
|
117
117
|
}, [
|
|
118
|
-
|
|
119
|
-
|
|
118
|
+
w("span", Yn, k(E.title), 1),
|
|
119
|
+
w("span", Kn, k(s(r)(`reportV5.reportAi.build.state.${E.status}`)), 1)
|
|
120
120
|
]))), 128))
|
|
121
121
|
])) : R("", !0)
|
|
122
122
|
])) : R("", !0)
|
|
123
123
|
])) : R("", !0);
|
|
124
124
|
}
|
|
125
|
-
}),
|
|
125
|
+
}), Jn = { class: "flex flex-col items-stretch gap-8 px-[20px] pb-16 pt-12" }, Xn = {
|
|
126
126
|
key: 0,
|
|
127
127
|
"data-testid": "chat-edit-target-context",
|
|
128
128
|
class: "fm-typo-en-body-sm-400 line-clamp-1 text-fm-color-typo-secondary"
|
|
129
|
-
},
|
|
129
|
+
}, Qn = {
|
|
130
130
|
key: 1,
|
|
131
131
|
role: "alert",
|
|
132
132
|
class: "fm-typo-en-body-sm-400 text-fm-color-typo-error"
|
|
133
|
-
},
|
|
133
|
+
}, Zn = {
|
|
134
134
|
"data-testid": "report-canvas-chat-input",
|
|
135
135
|
class: "rounded-lg border border-fm-color-border-secondary bg-fm-color-neutral-white p-16 focus-within:border-fm-color-primary"
|
|
136
|
-
},
|
|
136
|
+
}, ea = ["value", "placeholder", "aria-label"], ta = { class: "mt-16 flex items-center gap-12" }, na = ["aria-label"], aa = { class: "fm-typo-en-body-sm-400 min-w-0 grow truncate" }, ra = {
|
|
137
137
|
key: 0,
|
|
138
138
|
"data-testid": "chat-edit-target-element"
|
|
139
|
-
},
|
|
139
|
+
}, oa = ["disabled", "aria-label"], ia = ["disabled", "aria-label"], sa = { class: "text-[12px] leading-16 text-fm-color-typo-secondary" }, Tt = 21, la = /* @__PURE__ */ je({
|
|
140
140
|
__name: "ReportCanvasComposer",
|
|
141
141
|
props: {
|
|
142
142
|
draft: {},
|
|
@@ -147,118 +147,118 @@ const An = {
|
|
|
147
147
|
},
|
|
148
148
|
emits: ["update:draft", "submit", "clearTarget"],
|
|
149
149
|
setup(o, { expose: e, emit: t }) {
|
|
150
|
-
const a = o, r = t, { t: m } =
|
|
150
|
+
const a = o, r = t, { t: m } = Ve(), h = Tt * 2, y = Tt * 6, I = T(), b = T(!1);
|
|
151
151
|
function L() {
|
|
152
|
-
const
|
|
153
|
-
|
|
152
|
+
const O = I.value;
|
|
153
|
+
O && (O.style.height = "auto", O.style.height = `${Math.min(Math.max(O.scrollHeight, h), y)}px`);
|
|
154
154
|
}
|
|
155
|
-
|
|
155
|
+
Me(L), de(
|
|
156
156
|
() => a.draft,
|
|
157
|
-
() => void
|
|
157
|
+
() => void Ee(L)
|
|
158
158
|
);
|
|
159
|
-
function
|
|
160
|
-
r("update:draft",
|
|
159
|
+
function x(O) {
|
|
160
|
+
r("update:draft", O.target.value);
|
|
161
161
|
}
|
|
162
|
-
function N(
|
|
163
|
-
|
|
162
|
+
function N(O) {
|
|
163
|
+
O.key !== "Enter" || O.shiftKey || b.value || O.isComposing || (O.preventDefault(), W());
|
|
164
164
|
}
|
|
165
|
-
const
|
|
165
|
+
const E = V(() => !!a.draft.trim() && !a.streaming && !a.targetStale);
|
|
166
166
|
function W() {
|
|
167
|
-
|
|
167
|
+
E.value && r("submit");
|
|
168
168
|
}
|
|
169
|
-
function
|
|
170
|
-
var
|
|
171
|
-
(
|
|
169
|
+
function j() {
|
|
170
|
+
var O;
|
|
171
|
+
(O = I.value) == null || O.focus();
|
|
172
172
|
}
|
|
173
|
-
e({ focus:
|
|
174
|
-
const
|
|
173
|
+
e({ focus: j });
|
|
174
|
+
const Y = V(() => {
|
|
175
175
|
var J;
|
|
176
|
-
const
|
|
177
|
-
if (!
|
|
178
|
-
const G = (
|
|
179
|
-
return G ? G.slice(0, 40) :
|
|
180
|
-
}),
|
|
176
|
+
const O = (J = a.target) == null ? void 0 : J.element;
|
|
177
|
+
if (!O) return "";
|
|
178
|
+
const G = (O.text || "").trim();
|
|
179
|
+
return G ? G.slice(0, 40) : O.part || O.tag;
|
|
180
|
+
}), U = V(
|
|
181
181
|
() => m(
|
|
182
182
|
a.target ? "reportV5.reportAi.chat.commentPlaceholder" : a.blank ? "reportV5.reportAi.chat.placeholderNew" : "reportV5.reportAi.chat.placeholderChange"
|
|
183
183
|
)
|
|
184
184
|
);
|
|
185
|
-
return (
|
|
186
|
-
var
|
|
185
|
+
return (O, G) => {
|
|
186
|
+
var F;
|
|
187
187
|
const J = Ie("FmIcon");
|
|
188
|
-
return c(),
|
|
189
|
-
(
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
188
|
+
return c(), p("div", Jn, [
|
|
189
|
+
(F = O.target) != null && F.elementText ? (c(), p("p", Xn, " “" + k(O.target.elementText) + "” ", 1)) : R("", !0),
|
|
190
|
+
O.targetStale && !O.streaming ? (c(), p("p", Qn, k(s(m)("reportV5.reportAi.chat.staleTarget")), 1)) : R("", !0),
|
|
191
|
+
w("div", Zn, [
|
|
192
|
+
w("textarea", {
|
|
193
193
|
ref_key: "field",
|
|
194
194
|
ref: I,
|
|
195
|
-
value:
|
|
196
|
-
placeholder:
|
|
197
|
-
"aria-label":
|
|
195
|
+
value: O.draft,
|
|
196
|
+
placeholder: U.value,
|
|
197
|
+
"aria-label": U.value,
|
|
198
198
|
rows: "2",
|
|
199
199
|
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",
|
|
200
|
-
onInput:
|
|
200
|
+
onInput: x,
|
|
201
201
|
onKeydown: N,
|
|
202
|
-
onCompositionstart: G[0] || (G[0] = (B) =>
|
|
203
|
-
onCompositionend: G[1] || (G[1] = (B) =>
|
|
204
|
-
}, null, 40,
|
|
205
|
-
|
|
206
|
-
|
|
202
|
+
onCompositionstart: G[0] || (G[0] = (B) => b.value = !0),
|
|
203
|
+
onCompositionend: G[1] || (G[1] = (B) => b.value = !1)
|
|
204
|
+
}, null, 40, ea),
|
|
205
|
+
w("div", ta, [
|
|
206
|
+
w("div", {
|
|
207
207
|
"data-testid": "chat-edit-target",
|
|
208
208
|
role: "status",
|
|
209
|
-
"aria-label":
|
|
210
|
-
widget: (
|
|
209
|
+
"aria-label": O.target ? s(m)("reportV5.reportAi.chat.commentOn", {
|
|
210
|
+
widget: (O.target.label || s(m)("reportV5.reportAi.chat.selectedWidget")) + (Y.value ? " › " + Y.value : "")
|
|
211
211
|
}) : s(m)("reportV5.reportAi.chat.entireReport"),
|
|
212
212
|
class: "flex min-w-0 grow items-center gap-8 text-fm-color-typo-secondary"
|
|
213
213
|
}, [
|
|
214
|
-
|
|
215
|
-
name:
|
|
214
|
+
Z(J, {
|
|
215
|
+
name: O.target ? "mode_comment" : "dashboard",
|
|
216
216
|
size: "sm",
|
|
217
217
|
outline: ""
|
|
218
218
|
}, null, 8, ["name"]),
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
219
|
+
w("p", aa, [
|
|
220
|
+
Ft(k(O.target ? O.target.label || s(m)("reportV5.reportAi.chat.selectedWidget") : s(m)("reportV5.reportAi.chat.entireReport")), 1),
|
|
221
|
+
Y.value ? (c(), p("span", ra, " › " + k(Y.value), 1)) : R("", !0)
|
|
222
222
|
]),
|
|
223
|
-
|
|
223
|
+
O.target ? (c(), p("button", {
|
|
224
224
|
key: 0,
|
|
225
225
|
class: "flex shrink-0 items-center text-fm-color-typo-secondary disabled:opacity-50",
|
|
226
|
-
disabled:
|
|
226
|
+
disabled: O.streaming,
|
|
227
227
|
"aria-label": s(m)(
|
|
228
|
-
|
|
228
|
+
O.target.element ? "reportV5.reportAi.chat.removeElement" : "reportV5.reportAi.chat.removeTarget"
|
|
229
229
|
),
|
|
230
230
|
onClick: G[2] || (G[2] = (B) => r("clearTarget"))
|
|
231
231
|
}, [
|
|
232
|
-
|
|
232
|
+
Z(J, {
|
|
233
233
|
name: "close",
|
|
234
234
|
size: "sm"
|
|
235
235
|
})
|
|
236
|
-
], 8,
|
|
237
|
-
], 8,
|
|
238
|
-
|
|
236
|
+
], 8, oa)) : R("", !0)
|
|
237
|
+
], 8, na),
|
|
238
|
+
w("button", {
|
|
239
239
|
"data-testid": "report-canvas-chat-send",
|
|
240
|
-
class:
|
|
240
|
+
class: Pe([
|
|
241
241
|
"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",
|
|
242
|
-
|
|
242
|
+
E.value ? "bg-fm-color-primary text-fm-color-neutral-white" : "bg-fm-color-neutral-gray-100 text-fm-color-typo-secondary"
|
|
243
243
|
]),
|
|
244
|
-
disabled: !
|
|
244
|
+
disabled: !E.value,
|
|
245
245
|
"aria-label": s(m)("reportV5.reportAi.chat.send"),
|
|
246
246
|
onClick: W
|
|
247
247
|
}, [
|
|
248
|
-
|
|
248
|
+
Z(J, {
|
|
249
249
|
name: "arrow_forward",
|
|
250
250
|
size: "sm"
|
|
251
251
|
})
|
|
252
|
-
], 10,
|
|
252
|
+
], 10, ia)
|
|
253
253
|
])
|
|
254
254
|
]),
|
|
255
|
-
|
|
255
|
+
w("p", sa, k(O.streaming && O.draft.trim() ? s(m)("reportV5.reportAi.chat.waitForUpdate") : s(m)("reportV5.reportAi.chat.newLineHint")), 1)
|
|
256
256
|
]);
|
|
257
257
|
};
|
|
258
258
|
}
|
|
259
|
-
}),
|
|
260
|
-
function
|
|
261
|
-
return o.map((e) => e.type === "strong" ?
|
|
259
|
+
}), fa = "rounded-sm bg-fm-color-neutral-gray-100 px-4 font-mono text-[0.9em]";
|
|
260
|
+
function Et(o) {
|
|
261
|
+
return o.map((e) => e.type === "strong" ? Ae("strong", { class: "font-semibold" }, e.text) : e.type === "em" ? Ae("em", e.text) : e.type === "code" ? Ae("code", { class: fa }, e.text) : e.type === "link" ? Ae(
|
|
262
262
|
"a",
|
|
263
263
|
{
|
|
264
264
|
href: e.href,
|
|
@@ -269,110 +269,110 @@ function Tt(o) {
|
|
|
269
269
|
e.text
|
|
270
270
|
) : e.text);
|
|
271
271
|
}
|
|
272
|
-
const
|
|
272
|
+
const da = (o) => Ae(
|
|
273
273
|
"div",
|
|
274
274
|
{ class: "fm-typo-en-body-md-400 flex flex-col items-stretch gap-8 !leading-[21px]" },
|
|
275
|
-
(o.blocks ?? []).map((e) => e.type === "pre" ?
|
|
275
|
+
(o.blocks ?? []).map((e) => e.type === "pre" ? Ae(
|
|
276
276
|
"pre",
|
|
277
277
|
{
|
|
278
278
|
class: "overflow-x-auto rounded-md bg-fm-color-neutral-gray-100 p-8 font-mono text-xs"
|
|
279
279
|
},
|
|
280
280
|
e.text
|
|
281
|
-
) : e.type === "list" ?
|
|
281
|
+
) : e.type === "list" ? Ae(
|
|
282
282
|
e.ordered ? "ol" : "ul",
|
|
283
283
|
{ class: `flex flex-col gap-4 pl-16 ${e.ordered ? "list-decimal" : "list-disc"}` },
|
|
284
|
-
e.items.map((t) =>
|
|
285
|
-
) :
|
|
284
|
+
e.items.map((t) => Ae("li", Et(t)))
|
|
285
|
+
) : Ae(
|
|
286
286
|
"p",
|
|
287
287
|
{ class: e.heading ? "fm-typo-en-body-md-600" : void 0 },
|
|
288
|
-
|
|
288
|
+
Et(e.inline)
|
|
289
289
|
))
|
|
290
|
-
),
|
|
290
|
+
), ca = ["aria-expanded"], ma = /* @__PURE__ */ je({
|
|
291
291
|
__name: "ReportCanvasMessage",
|
|
292
292
|
props: {
|
|
293
293
|
blocks: {},
|
|
294
294
|
preview: {}
|
|
295
295
|
},
|
|
296
296
|
setup(o) {
|
|
297
|
-
const e = o, { t } =
|
|
298
|
-
|
|
297
|
+
const e = o, { t } = Ve(), a = T(!1);
|
|
298
|
+
de(
|
|
299
299
|
() => e.preview,
|
|
300
300
|
() => a.value = !1
|
|
301
301
|
);
|
|
302
|
-
const r =
|
|
303
|
-
return (m,
|
|
304
|
-
|
|
305
|
-
m.preview ? (c(),
|
|
302
|
+
const r = V(() => e.preview && !a.value ? e.preview : e.blocks);
|
|
303
|
+
return (m, h) => (c(), p("div", null, [
|
|
304
|
+
Z(s(da), { blocks: r.value }, null, 8, ["blocks"]),
|
|
305
|
+
m.preview ? (c(), p("button", {
|
|
306
306
|
key: 0,
|
|
307
307
|
"data-testid": "report-canvas-full-reply",
|
|
308
308
|
class: "fm-typo-en-body-sm-600 mt-4 text-fm-color-typo-secondary underline",
|
|
309
309
|
"aria-expanded": a.value,
|
|
310
|
-
onClick:
|
|
311
|
-
},
|
|
310
|
+
onClick: h[0] || (h[0] = (y) => a.value = !a.value)
|
|
311
|
+
}, k(s(t)(a.value ? "reportV5.reportAi.chat.showLess" : "reportV5.reportAi.chat.showFullReply")), 9, ca)) : R("", !0)
|
|
312
312
|
]));
|
|
313
313
|
}
|
|
314
|
-
}),
|
|
315
|
-
function
|
|
314
|
+
}), ua = /^(?:https?:\/\/|mailto:)[^\s]+$/i, rt = /`([^`]+)`|(!?)\[([^\]]*)\]\(([^)\s]*)\)|\*\*([\s\S]+?)\*\*|\*([^*\n]+)\*/g;
|
|
315
|
+
function ot(o, e) {
|
|
316
316
|
if (!e) return;
|
|
317
317
|
const t = o[o.length - 1];
|
|
318
318
|
(t == null ? void 0 : t.type) === "text" ? t.text += e : o.push({ type: "text", text: e });
|
|
319
319
|
}
|
|
320
|
-
function
|
|
320
|
+
function it(o) {
|
|
321
321
|
const e = [];
|
|
322
322
|
let t = 0;
|
|
323
|
-
|
|
324
|
-
for (let a =
|
|
325
|
-
|
|
326
|
-
const [, r, m,
|
|
327
|
-
r !== void 0 ? e.push({ type: "code", text: r }) :
|
|
323
|
+
rt.lastIndex = 0;
|
|
324
|
+
for (let a = rt.exec(o); a; a = rt.exec(o)) {
|
|
325
|
+
ot(e, o.slice(t, a.index)), t = a.index + a[0].length;
|
|
326
|
+
const [, r, m, h, y, I, b] = a;
|
|
327
|
+
r !== void 0 ? e.push({ type: "code", text: r }) : h !== void 0 ? !m && ua.test(y) ? e.push({ type: "link", text: h || y, href: y }) : ot(e, a[0]) : I !== void 0 ? e.push({ type: "strong", text: I }) : b !== void 0 && e.push({ type: "em", text: b });
|
|
328
328
|
}
|
|
329
|
-
return
|
|
329
|
+
return ot(e, o.slice(t)), e;
|
|
330
330
|
}
|
|
331
|
-
const
|
|
332
|
-
function
|
|
331
|
+
const pa = /^\s*```/, ha = /^\s{0,3}(#{1,6})\s+(.*)$/, ba = /^\s*[-*+]\s+(.*)$/, ga = /^\s*\d{1,3}[.)]\s+(.*)$/;
|
|
332
|
+
function Ot(o) {
|
|
333
333
|
const e = [], t = String(o ?? "").split(/\r?\n/);
|
|
334
334
|
let a = [], r = null, m = null;
|
|
335
|
-
function
|
|
336
|
-
a.length && (e.push({ type: "p", inline:
|
|
335
|
+
function h() {
|
|
336
|
+
a.length && (e.push({ type: "p", inline: it(a.join(" ")) }), a = []);
|
|
337
337
|
}
|
|
338
|
-
function
|
|
338
|
+
function y() {
|
|
339
339
|
r && (e.push({ type: "list", ordered: r.ordered, items: r.items }), r = null);
|
|
340
340
|
}
|
|
341
341
|
function I() {
|
|
342
|
-
|
|
342
|
+
h(), y();
|
|
343
343
|
}
|
|
344
|
-
for (const
|
|
345
|
-
if (
|
|
344
|
+
for (const b of t) {
|
|
345
|
+
if (pa.test(b)) {
|
|
346
346
|
m ? (e.push({ type: "pre", text: m.join(`
|
|
347
347
|
`) }), m = null) : (I(), m = []);
|
|
348
348
|
continue;
|
|
349
349
|
}
|
|
350
350
|
if (m) {
|
|
351
|
-
m.push(
|
|
351
|
+
m.push(b);
|
|
352
352
|
continue;
|
|
353
353
|
}
|
|
354
|
-
const L =
|
|
355
|
-
if (!
|
|
354
|
+
const L = ha.exec(b), x = ba.exec(b), N = ga.exec(b);
|
|
355
|
+
if (!b.trim())
|
|
356
356
|
I();
|
|
357
357
|
else if (L)
|
|
358
|
-
I(), e.push({ type: "p", inline:
|
|
359
|
-
else if (
|
|
360
|
-
|
|
361
|
-
const
|
|
362
|
-
(!r || r.ordered !==
|
|
358
|
+
I(), e.push({ type: "p", inline: it(L[2]), heading: !0 });
|
|
359
|
+
else if (x || N) {
|
|
360
|
+
h();
|
|
361
|
+
const E = !x;
|
|
362
|
+
(!r || r.ordered !== E) && (y(), r = { ordered: E, items: [] }), r.items.push(it((x ?? N)[1]));
|
|
363
363
|
} else
|
|
364
|
-
|
|
364
|
+
y(), a.push(b.trim());
|
|
365
365
|
}
|
|
366
366
|
return m != null && m.length && e.push({ type: "pre", text: m.join(`
|
|
367
367
|
`) }), I(), e;
|
|
368
368
|
}
|
|
369
|
-
function
|
|
369
|
+
function va(o, e) {
|
|
370
370
|
const t = String(o ?? "").trim();
|
|
371
371
|
if (t.length <= e) return t;
|
|
372
372
|
const a = t.slice(0, e), r = a.lastIndexOf(" ");
|
|
373
373
|
return `${(r > e * 0.6 ? a.slice(0, r) : a).trimEnd()}…`;
|
|
374
374
|
}
|
|
375
|
-
const
|
|
375
|
+
const zt = 600, ya = {
|
|
376
376
|
discovery: "reviewing",
|
|
377
377
|
grounding_probe: "reviewing",
|
|
378
378
|
option_probe: "reviewing",
|
|
@@ -409,66 +409,66 @@ const Ot = 600, ba = {
|
|
|
409
409
|
lazy_forced: "updating",
|
|
410
410
|
manifest_unbound: "updating",
|
|
411
411
|
rendered: "loading"
|
|
412
|
-
},
|
|
413
|
-
function
|
|
414
|
-
return o &&
|
|
412
|
+
}, xa = /* @__PURE__ */ new Set(["plan", "edit-target", "error", "turn_stats"]);
|
|
413
|
+
function Bt(o) {
|
|
414
|
+
return o && ya[o] || "working";
|
|
415
415
|
}
|
|
416
|
-
function
|
|
416
|
+
function wa(o) {
|
|
417
417
|
const e = [];
|
|
418
418
|
for (const t of o) {
|
|
419
|
-
const a =
|
|
419
|
+
const a = Bt(t);
|
|
420
420
|
e.includes(a) || e.push(a);
|
|
421
421
|
}
|
|
422
422
|
return e.slice(-4);
|
|
423
423
|
}
|
|
424
|
-
function
|
|
424
|
+
function st(o) {
|
|
425
425
|
return o.filter((e) => e.type === "text").map((e) => String(e.text ?? "").trim()).filter(Boolean).join(`
|
|
426
426
|
|
|
427
427
|
`);
|
|
428
428
|
}
|
|
429
|
-
function
|
|
429
|
+
function ka(o) {
|
|
430
430
|
const e = [];
|
|
431
431
|
for (const t of o) {
|
|
432
432
|
const a = t.type.startsWith("tool-") || t.type.startsWith("data-") ? t.type.slice(5) : "";
|
|
433
|
-
a && !
|
|
433
|
+
a && !xa.has(a) && e.push(a);
|
|
434
434
|
}
|
|
435
435
|
return e;
|
|
436
436
|
}
|
|
437
|
-
function
|
|
437
|
+
function _a(o) {
|
|
438
438
|
var a;
|
|
439
439
|
const e = o.find((r) => r.type === "data-turn_stats"), t = (a = e == null ? void 0 : e.data) == null ? void 0 : a.ms;
|
|
440
440
|
return typeof t == "number" && t >= 0 ? t : void 0;
|
|
441
441
|
}
|
|
442
|
-
function
|
|
442
|
+
function Sa(o) {
|
|
443
443
|
const e = o / 1e3;
|
|
444
444
|
return e < 60 ? `${e.toFixed(1)}s` : `${Math.floor(e / 60)}m ${String(Math.round(e % 60)).padStart(2, "0")}s`;
|
|
445
445
|
}
|
|
446
|
-
function
|
|
446
|
+
function Ia(o) {
|
|
447
447
|
const e = o.find((t) => t.type === "data-edit-target");
|
|
448
448
|
return e ? e.data : void 0;
|
|
449
449
|
}
|
|
450
|
-
function
|
|
450
|
+
function Ca(o) {
|
|
451
451
|
const e = [[]];
|
|
452
452
|
for (const t of o)
|
|
453
453
|
t.type === "step-start" ? e.push([]) : e[e.length - 1].push(t);
|
|
454
454
|
return e.filter((t) => t.length > 0);
|
|
455
455
|
}
|
|
456
|
-
function
|
|
456
|
+
function Nt(o) {
|
|
457
457
|
return o.some((e) => e.type.startsWith("tool-"));
|
|
458
458
|
}
|
|
459
|
-
function
|
|
459
|
+
function Aa(o, e = {}) {
|
|
460
460
|
var a;
|
|
461
461
|
const t = [];
|
|
462
462
|
for (const r of o ?? []) {
|
|
463
|
-
const m = r.parts ?? [],
|
|
463
|
+
const m = r.parts ?? [], h = ka(m), y = Ia(m);
|
|
464
464
|
if (r.role === "user") {
|
|
465
|
-
const
|
|
465
|
+
const j = st(m);
|
|
466
466
|
t.push({
|
|
467
467
|
id: r.id,
|
|
468
468
|
turnId: r.turnId ?? r.id,
|
|
469
469
|
role: "user",
|
|
470
|
-
target:
|
|
471
|
-
answer:
|
|
470
|
+
target: y,
|
|
471
|
+
answer: j,
|
|
472
472
|
blocks: [],
|
|
473
473
|
preview: null,
|
|
474
474
|
signals: [],
|
|
@@ -477,84 +477,84 @@ function Sa(o, e = {}) {
|
|
|
477
477
|
});
|
|
478
478
|
continue;
|
|
479
479
|
}
|
|
480
|
-
const I = !!e.streamingId && r.id === e.streamingId,
|
|
481
|
-
let
|
|
482
|
-
I || (!
|
|
483
|
-
const W = !!
|
|
484
|
-
!
|
|
480
|
+
const I = !!e.streamingId && r.id === e.streamingId, b = Ca(m), L = b[b.length - 1] ?? [], x = b.some(Nt), N = x && !m.some((j) => j.type === "step-start");
|
|
481
|
+
let E = "";
|
|
482
|
+
I || (!x || N ? E = st(m) : Nt(L) || (E = st(L)));
|
|
483
|
+
const W = !!E && (N || E.length > zt);
|
|
484
|
+
!E && !h.length && !I || t.push({
|
|
485
485
|
id: r.id,
|
|
486
486
|
turnId: r.turnId ?? r.id,
|
|
487
487
|
role: "assistant",
|
|
488
|
-
target:
|
|
489
|
-
answer:
|
|
490
|
-
blocks:
|
|
491
|
-
preview: W ?
|
|
492
|
-
signals:
|
|
488
|
+
target: y,
|
|
489
|
+
answer: E,
|
|
490
|
+
blocks: E ? Ot(E) : [],
|
|
491
|
+
preview: W ? Ot(va(E, zt)) : null,
|
|
492
|
+
signals: h,
|
|
493
493
|
pending: I,
|
|
494
|
-
noSummary: !I && !
|
|
495
|
-
ms: I ? void 0 :
|
|
494
|
+
noSummary: !I && !E && x,
|
|
495
|
+
ms: I ? void 0 : _a(m) ?? ((a = r.stats) == null ? void 0 : a.ms)
|
|
496
496
|
});
|
|
497
497
|
}
|
|
498
498
|
return t;
|
|
499
499
|
}
|
|
500
|
-
const
|
|
500
|
+
const Ta = ["aria-label"], Ea = { class: "flex h-64 shrink-0 items-center gap-12 border-b border-fm-color-border-secondary px-[20px]" }, Oa = { class: "min-w-0 grow" }, za = { class: "fm-typo-en-body-md-600" }, Na = {
|
|
501
501
|
key: 0,
|
|
502
502
|
class: "fm-typo-en-body-sm-400 truncate text-fm-color-typo-secondary"
|
|
503
|
-
},
|
|
503
|
+
}, $a = ["disabled", "aria-label"], Ra = ["disabled", "aria-label", "title"], La = ["aria-label"], Ma = ["data-testid", "aria-label"], Pa = {
|
|
504
504
|
key: 0,
|
|
505
505
|
class: "mt-auto flex shrink-0 flex-col gap-24 pb-8 pt-32"
|
|
506
|
-
},
|
|
506
|
+
}, Da = { class: "text-center" }, ja = { class: "text-[24px] font-semibold leading-tight tracking-tight text-fm-color-typo-primary" }, Va = { class: "fm-typo-en-body-sm-400 mt-12 text-fm-color-typo-secondary" }, Fa = {
|
|
507
507
|
key: 0,
|
|
508
508
|
class: "flex flex-col gap-4"
|
|
509
|
-
},
|
|
509
|
+
}, Ba = ["disabled", "title", "onClick"], qa = ["aria-label"], Ua = { class: "fm-typo-en-body-sm-600 mb-12 text-fm-color-typo-secondary" }, Ha = {
|
|
510
510
|
key: 0,
|
|
511
511
|
class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary"
|
|
512
|
-
},
|
|
512
|
+
}, Wa = {
|
|
513
513
|
key: 1,
|
|
514
514
|
"data-testid": "report-canvas-chat-list-error",
|
|
515
515
|
class: "fm-typo-en-body-sm-400 text-fm-color-typo-error"
|
|
516
|
-
},
|
|
516
|
+
}, Ga = {
|
|
517
517
|
key: 2,
|
|
518
518
|
class: "fm-typo-en-body-sm-400 py-12 text-fm-color-typo-secondary"
|
|
519
|
-
},
|
|
519
|
+
}, Ya = {
|
|
520
520
|
key: 0,
|
|
521
521
|
class: "fm-typo-en-body-sm-400 mb-8 text-fm-color-typo-secondary"
|
|
522
|
-
},
|
|
522
|
+
}, Ka = ["disabled", "aria-current", "title", "onClick"], Ja = { class: "fm-typo-en-body-md-400 min-w-0 grow truncate" }, Xa = ["datetime"], Qa = ["disabled"], Za = ["disabled"], er = {
|
|
523
523
|
key: 2,
|
|
524
524
|
"data-testid": "report-canvas-chat-error",
|
|
525
525
|
class: "fm-typo-en-body-sm-400 mt-12 text-fm-color-typo-error"
|
|
526
|
-
},
|
|
526
|
+
}, tr = {
|
|
527
527
|
key: 1,
|
|
528
528
|
class: "relative flex min-h-0 grow flex-col"
|
|
529
|
-
},
|
|
529
|
+
}, nr = {
|
|
530
530
|
key: 0,
|
|
531
531
|
"data-testid": "report-canvas-chat-loading",
|
|
532
532
|
class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary"
|
|
533
|
-
},
|
|
533
|
+
}, ar = ["disabled"], rr = {
|
|
534
534
|
key: 0,
|
|
535
535
|
"data-testid": "chat-message-target",
|
|
536
536
|
class: "fm-typo-en-body-sm-600 mb-4 text-right text-fm-color-typo-secondary"
|
|
537
|
-
},
|
|
537
|
+
}, or = {
|
|
538
538
|
key: 1,
|
|
539
539
|
class: "flex flex-col items-end"
|
|
540
|
-
},
|
|
540
|
+
}, ir = {
|
|
541
541
|
key: 0,
|
|
542
542
|
"data-testid": "chat-message-unsent",
|
|
543
543
|
class: "fm-typo-en-body-sm-400 mt-4 text-fm-color-typo-secondary"
|
|
544
|
-
},
|
|
544
|
+
}, sr = ["disabled", "onClick"], lr = ["disabled", "onClick"], fr = {
|
|
545
545
|
key: 2,
|
|
546
546
|
class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary"
|
|
547
|
-
},
|
|
547
|
+
}, dr = {
|
|
548
548
|
key: 3,
|
|
549
549
|
"data-testid": "report-canvas-answer-duration",
|
|
550
550
|
class: "fm-typo-en-body-sm-400 mt-4 text-fm-color-typo-secondary"
|
|
551
|
-
},
|
|
551
|
+
}, cr = {
|
|
552
552
|
key: 2,
|
|
553
553
|
"data-testid": "report-canvas-chat-error",
|
|
554
554
|
class: "fm-typo-en-body-md-400 text-fm-color-typo-error"
|
|
555
|
-
},
|
|
555
|
+
}, mr = { class: "shrink-0" }, $t = "New chat", ur = 24 * 60 * 60 * 1e3, pr = 80, hr = /* @__PURE__ */ je({
|
|
556
556
|
__name: "ReportCanvasChatPanel",
|
|
557
|
-
props: /* @__PURE__ */
|
|
557
|
+
props: /* @__PURE__ */ kt({
|
|
558
558
|
messages: {},
|
|
559
559
|
draft: {},
|
|
560
560
|
target: {},
|
|
@@ -589,62 +589,62 @@ const Ia = ["aria-label"], Ca = { class: "flex h-64 shrink-0 items-center gap-12
|
|
|
589
589
|
homeDraft: { default: "" },
|
|
590
590
|
homeDraftModifiers: {}
|
|
591
591
|
}),
|
|
592
|
-
emits: /* @__PURE__ */
|
|
592
|
+
emits: /* @__PURE__ */ kt(["update:draft", "submit", "close", "retry", "undo", "resend", "checkStatus", "clearTarget", "newChat", "selectChat", "loadChats", "loadMoreChats", "loadEarlier"], ["update:homeOpen", "update:homeDraft"]),
|
|
593
593
|
setup(o, { emit: e }) {
|
|
594
|
-
const t = o, a = e, { t: r, locale: m } =
|
|
595
|
-
() => !t.chatTitle || t.chatTitle ===
|
|
596
|
-
),
|
|
597
|
-
|
|
594
|
+
const t = o, a = e, { t: r, locale: m } = Ve(), h = _t(o, "homeOpen"), y = T(!1), I = _t(o, "homeDraft"), b = T(!1), L = V(
|
|
595
|
+
() => !t.chatTitle || t.chatTitle === $t ? r("reportV5.reportAi.chat.chats") : t.chatTitle
|
|
596
|
+
), x = T(!1), N = V(() => t.switching || x.value);
|
|
597
|
+
de(
|
|
598
598
|
() => t.messages,
|
|
599
599
|
() => {
|
|
600
|
-
|
|
600
|
+
x.value = !1;
|
|
601
601
|
}
|
|
602
|
-
),
|
|
602
|
+
), de(
|
|
603
603
|
() => t.switching,
|
|
604
604
|
(n) => {
|
|
605
|
-
n || (
|
|
605
|
+
n || (x.value = !1);
|
|
606
606
|
}
|
|
607
607
|
);
|
|
608
|
-
function
|
|
609
|
-
t.busy || (
|
|
608
|
+
function E() {
|
|
609
|
+
t.busy || (h.value = !0, y.value = !1, a("loadChats"));
|
|
610
610
|
}
|
|
611
611
|
function W() {
|
|
612
|
-
|
|
612
|
+
y.value = !0, a("loadChats");
|
|
613
613
|
}
|
|
614
|
-
function
|
|
615
|
-
|
|
614
|
+
function j() {
|
|
615
|
+
y.value ? y.value = !1 : E();
|
|
616
616
|
}
|
|
617
|
-
function
|
|
618
|
-
t.busy || (
|
|
617
|
+
function Y(n) {
|
|
618
|
+
t.busy || (h.value = !1, y.value = !1, n !== t.chatId && (x.value = !0, a("selectChat", n)));
|
|
619
619
|
}
|
|
620
|
-
function
|
|
621
|
-
t.busy || (
|
|
620
|
+
function U() {
|
|
621
|
+
t.busy || (h.value = !1, y.value = !1, x.value = !0, a("newChat"));
|
|
622
622
|
}
|
|
623
|
-
|
|
623
|
+
de(
|
|
624
624
|
() => t.chatId,
|
|
625
625
|
() => {
|
|
626
|
-
|
|
626
|
+
b.value && (I.value = "", b.value = !1, h.value = !1);
|
|
627
627
|
}
|
|
628
|
-
),
|
|
628
|
+
), de(
|
|
629
629
|
() => t.switching,
|
|
630
630
|
(n) => {
|
|
631
|
-
n || (
|
|
631
|
+
n || (b.value = !1);
|
|
632
632
|
}
|
|
633
633
|
);
|
|
634
|
-
function
|
|
635
|
-
if (n.key === "Escape" &&
|
|
636
|
-
n.stopPropagation(),
|
|
634
|
+
function O(n) {
|
|
635
|
+
if (n.key === "Escape" && y.value) {
|
|
636
|
+
n.stopPropagation(), y.value = !1;
|
|
637
637
|
return;
|
|
638
638
|
}
|
|
639
|
-
n.key === "Escape" &&
|
|
639
|
+
n.key === "Escape" && h.value && (n.stopPropagation(), h.value = !1);
|
|
640
640
|
}
|
|
641
|
-
const G =
|
|
641
|
+
const G = V(() => {
|
|
642
642
|
const n = /* @__PURE__ */ new Date();
|
|
643
643
|
n.setHours(0, 0, 0, 0);
|
|
644
644
|
const i = [];
|
|
645
645
|
for (const f of t.chats ?? []) {
|
|
646
|
-
const
|
|
647
|
-
(i.find((
|
|
646
|
+
const A = new Date(f.lastMessageAt).getTime(), P = A >= n.getTime() ? "today" : A >= n.getTime() - ur ? "yesterday" : "earlier";
|
|
647
|
+
(i.find((D) => D.key === P) ?? (i.push({ key: P, label: r(`reportV5.reportAi.chat.group.${P}`), chats: [] }), i[i.length - 1])).chats.push(f);
|
|
648
648
|
}
|
|
649
649
|
return i;
|
|
650
650
|
});
|
|
@@ -654,49 +654,49 @@ const Ia = ["aria-label"], Ca = { class: "flex h-64 shrink-0 items-center gap-12
|
|
|
654
654
|
day: "numeric"
|
|
655
655
|
});
|
|
656
656
|
}
|
|
657
|
-
const
|
|
658
|
-
|
|
657
|
+
const F = V(() => new Set(t.undoableTurnIds ?? [])), B = V(() => new Set(t.unsentIds ?? [])), _ = T();
|
|
658
|
+
de(
|
|
659
659
|
() => t.target,
|
|
660
660
|
async (n) => {
|
|
661
661
|
var i;
|
|
662
|
-
n && (
|
|
662
|
+
n && (y.value = !1, await Ee(), (i = _.value) == null || i.focus());
|
|
663
663
|
},
|
|
664
664
|
{ immediate: !0 }
|
|
665
665
|
);
|
|
666
|
-
const z =
|
|
667
|
-
() =>
|
|
666
|
+
const z = V(
|
|
667
|
+
() => Aa(t.messages ?? [], {
|
|
668
668
|
streamingId: t.streaming ? t.turnId : void 0
|
|
669
669
|
})
|
|
670
|
-
),
|
|
670
|
+
), g = V(
|
|
671
671
|
() => t.streaming ? z.value.findIndex((n) => n.pending) : -1
|
|
672
|
-
),
|
|
673
|
-
() =>
|
|
674
|
-
),
|
|
675
|
-
() =>
|
|
676
|
-
),
|
|
672
|
+
), H = V(() => z.value.findIndex((n) => n.id === t.runAnchorId)), K = V(
|
|
673
|
+
() => g.value < 0 && (t.streaming || t.interrupted) || H.value < 0 && !!t.run
|
|
674
|
+
), ee = V(
|
|
675
|
+
() => h.value || !t.earlier && !N.value && !z.value.length && !K.value
|
|
676
|
+
), X = V(() => (t.chats ?? []).slice(0, 3)), se = V(
|
|
677
677
|
() => {
|
|
678
678
|
var n;
|
|
679
|
-
return !!((n = t.chats) != null && n.length) || !!t.chatsLoading || !!t.chatsError ||
|
|
679
|
+
return !!((n = t.chats) != null && n.length) || !!t.chatsLoading || !!t.chatsError || y.value;
|
|
680
680
|
}
|
|
681
681
|
);
|
|
682
|
-
|
|
683
|
-
[
|
|
682
|
+
de(
|
|
683
|
+
[ee, () => t.chatId],
|
|
684
684
|
([n, i]) => {
|
|
685
|
-
n && i && !
|
|
685
|
+
n && i && !h.value && a("loadChats");
|
|
686
686
|
},
|
|
687
687
|
{ immediate: !0 }
|
|
688
688
|
);
|
|
689
|
-
const
|
|
690
|
-
() =>
|
|
689
|
+
const ce = V(
|
|
690
|
+
() => y.value ? G.value : [{ key: "recent", label: "", chats: X.value }]
|
|
691
691
|
);
|
|
692
|
-
function
|
|
693
|
-
var
|
|
694
|
-
const i = n ===
|
|
692
|
+
function ye(n) {
|
|
693
|
+
var A, P;
|
|
694
|
+
const i = n === g.value, f = n === H.value;
|
|
695
695
|
return {
|
|
696
|
-
active: i && t.streaming || f && ((
|
|
696
|
+
active: i && t.streaming || f && ((A = t.run) == null ? void 0 : A.status) === "running" && !t.runStale,
|
|
697
697
|
// a run card left behind by a newer streaming turn shows its own work, not that turn's phase
|
|
698
698
|
phase: i || !t.streaming ? t.phase : "updating",
|
|
699
|
-
phases:
|
|
699
|
+
phases: wa(((P = z.value[n]) == null ? void 0 : P.signals) ?? []),
|
|
700
700
|
run: f ? t.run : null,
|
|
701
701
|
slow: i && t.slow,
|
|
702
702
|
stale: f && t.runStale,
|
|
@@ -704,371 +704,371 @@ const Ia = ["aria-label"], Ca = { class: "flex h-64 shrink-0 items-center gap-12
|
|
|
704
704
|
retryError: f ? t.retryError : ""
|
|
705
705
|
};
|
|
706
706
|
}
|
|
707
|
-
const
|
|
708
|
-
() => t.blank ?
|
|
707
|
+
const he = ["one", "two", "three"], le = V(
|
|
708
|
+
() => t.blank ? he.map((n) => ({
|
|
709
709
|
label: r(`reportV5.reportAi.chat.suggestNew.${n}.label`),
|
|
710
710
|
prompt: r(`reportV5.reportAi.chat.suggestNew.${n}.prompt`)
|
|
711
711
|
})) : []
|
|
712
712
|
);
|
|
713
|
-
async function
|
|
713
|
+
async function oe(n) {
|
|
714
714
|
var i;
|
|
715
|
-
|
|
715
|
+
te(n), await Ee(), (i = _.value) == null || i.focus();
|
|
716
716
|
}
|
|
717
|
-
function
|
|
718
|
-
|
|
717
|
+
function te(n) {
|
|
718
|
+
h.value ? I.value = n : a("update:draft", n);
|
|
719
719
|
}
|
|
720
|
-
const
|
|
721
|
-
function
|
|
722
|
-
const n =
|
|
723
|
-
n && (
|
|
720
|
+
const xe = T(), C = T(!0), u = T(!1);
|
|
721
|
+
function S() {
|
|
722
|
+
const n = xe.value;
|
|
723
|
+
n && (C.value = n.scrollHeight - n.scrollTop - n.clientHeight <= pr, C.value && (u.value = !1));
|
|
724
724
|
}
|
|
725
725
|
async function M() {
|
|
726
|
-
await
|
|
727
|
-
const n =
|
|
728
|
-
n && (n.scrollTop = n.scrollHeight,
|
|
726
|
+
await Ee();
|
|
727
|
+
const n = xe.value;
|
|
728
|
+
n && (n.scrollTop = n.scrollHeight, C.value = !0, u.value = !1);
|
|
729
729
|
}
|
|
730
|
-
|
|
730
|
+
de(
|
|
731
731
|
() => JSON.stringify(t.messages ?? []).length,
|
|
732
732
|
() => {
|
|
733
|
-
|
|
733
|
+
C.value ? M() : u.value = !0;
|
|
734
734
|
}
|
|
735
735
|
);
|
|
736
736
|
function d() {
|
|
737
|
-
if (
|
|
738
|
-
if (!I.value.trim() || t.busy || t.targetStale ||
|
|
739
|
-
|
|
737
|
+
if (h.value) {
|
|
738
|
+
if (!I.value.trim() || t.busy || t.targetStale || b.value) return;
|
|
739
|
+
b.value = !0, a("newChat", I.value.trim());
|
|
740
740
|
return;
|
|
741
741
|
}
|
|
742
742
|
!t.draft.trim() || t.streaming || t.targetStale || (a("submit"), M());
|
|
743
743
|
}
|
|
744
744
|
return (n, i) => {
|
|
745
|
-
var
|
|
746
|
-
const f = Ie("FmIcon"),
|
|
747
|
-
return c(),
|
|
745
|
+
var P, $;
|
|
746
|
+
const f = Ie("FmIcon"), A = Ie("FmTooltip");
|
|
747
|
+
return c(), p("aside", {
|
|
748
748
|
class: "flex h-full min-h-0 w-full flex-col border-l border-fm-color-border-secondary bg-fm-color-neutral-white",
|
|
749
749
|
"aria-label": s(r)("reportV5.reportAi.chat.title"),
|
|
750
|
-
onKeydown:
|
|
750
|
+
onKeydown: O
|
|
751
751
|
}, [
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
|
|
755
|
-
!
|
|
752
|
+
w("header", Ea, [
|
|
753
|
+
w("div", Oa, [
|
|
754
|
+
w("h2", za, k(s(r)("reportV5.reportAi.chat.title")), 1),
|
|
755
|
+
!ee.value && n.chatTitle && n.chatTitle !== $t ? (c(), p("p", Na, k(n.chatTitle), 1)) : R("", !0)
|
|
756
756
|
]),
|
|
757
|
-
!
|
|
757
|
+
!h.value || y.value ? (c(), me(A, {
|
|
758
758
|
key: 0,
|
|
759
759
|
placement: "bottom",
|
|
760
760
|
content: s(r)("reportV5.reportAi.chat.chats")
|
|
761
761
|
}, {
|
|
762
|
-
default:
|
|
763
|
-
|
|
762
|
+
default: $e(() => [
|
|
763
|
+
w("button", {
|
|
764
764
|
"data-testid": "report-canvas-chat-back",
|
|
765
765
|
class: "chat-icon-button flex h-[36px] w-[36px] shrink-0 items-center justify-center rounded-md text-fm-color-typo-secondary",
|
|
766
766
|
disabled: n.busy,
|
|
767
|
-
"aria-label":
|
|
768
|
-
onClick:
|
|
767
|
+
"aria-label": y.value ? s(r)("reportV5.reportAi.chat.recentChats") : s(r)("reportV5.reportAi.chat.openChats", { title: L.value }),
|
|
768
|
+
onClick: j
|
|
769
769
|
}, [
|
|
770
|
-
|
|
770
|
+
Z(f, {
|
|
771
771
|
name: "chevron_left",
|
|
772
772
|
size: "md"
|
|
773
773
|
})
|
|
774
|
-
], 8,
|
|
774
|
+
], 8, $a)
|
|
775
775
|
]),
|
|
776
776
|
_: 1
|
|
777
777
|
}, 8, ["content"])) : R("", !0),
|
|
778
|
-
|
|
778
|
+
ee.value ? R("", !0) : (c(), me(A, {
|
|
779
779
|
key: 1,
|
|
780
780
|
placement: "bottom",
|
|
781
781
|
content: s(r)("reportV5.reportAi.chat.newChat")
|
|
782
782
|
}, {
|
|
783
|
-
default:
|
|
784
|
-
|
|
783
|
+
default: $e(() => [
|
|
784
|
+
w("button", {
|
|
785
785
|
"data-testid": "report-canvas-new-chat",
|
|
786
786
|
class: "chat-icon-button flex h-[36px] w-[36px] shrink-0 items-center justify-center rounded-md text-fm-color-typo-secondary",
|
|
787
787
|
disabled: n.busy,
|
|
788
788
|
"aria-label": s(r)("reportV5.reportAi.chat.newChat"),
|
|
789
789
|
title: n.busy ? s(r)("reportV5.reportAi.chat.waitForUpdate") : void 0,
|
|
790
|
-
onClick:
|
|
790
|
+
onClick: U
|
|
791
791
|
}, [
|
|
792
|
-
|
|
792
|
+
Z(f, {
|
|
793
793
|
name: "edit_square",
|
|
794
794
|
size: "md",
|
|
795
795
|
outline: ""
|
|
796
796
|
})
|
|
797
|
-
], 8,
|
|
797
|
+
], 8, Ra)
|
|
798
798
|
]),
|
|
799
799
|
_: 1
|
|
800
800
|
}, 8, ["content"])),
|
|
801
|
-
|
|
801
|
+
Z(A, {
|
|
802
802
|
placement: "left",
|
|
803
803
|
content: s(r)("reportV5.reportAi.chat.hide")
|
|
804
804
|
}, {
|
|
805
|
-
default:
|
|
806
|
-
|
|
805
|
+
default: $e(() => [
|
|
806
|
+
w("button", {
|
|
807
807
|
"data-testid": "report-canvas-chat-close",
|
|
808
808
|
class: "chat-icon-button flex h-[36px] w-[36px] shrink-0 items-center justify-center rounded-md text-fm-color-typo-secondary",
|
|
809
809
|
"aria-label": s(r)("reportV5.reportAi.chat.hide"),
|
|
810
|
-
onClick: i[0] || (i[0] = (
|
|
810
|
+
onClick: i[0] || (i[0] = (D) => a("close"))
|
|
811
811
|
}, [
|
|
812
|
-
|
|
812
|
+
Z(f, {
|
|
813
813
|
name: "close",
|
|
814
814
|
size: "md"
|
|
815
815
|
})
|
|
816
|
-
], 8,
|
|
816
|
+
], 8, La)
|
|
817
817
|
]),
|
|
818
818
|
_: 1
|
|
819
819
|
}, 8, ["content"])
|
|
820
820
|
]),
|
|
821
|
-
|
|
821
|
+
ee.value ? (c(), p("div", {
|
|
822
822
|
key: 0,
|
|
823
|
-
"data-testid":
|
|
823
|
+
"data-testid": h.value ? "report-canvas-chat-list" : "report-canvas-chat-home",
|
|
824
824
|
class: "flex min-h-0 grow flex-col overflow-y-auto px-[20px] py-24",
|
|
825
825
|
"aria-label": s(r)("reportV5.reportAi.chat.chats")
|
|
826
826
|
}, [
|
|
827
|
-
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
|
|
827
|
+
y.value ? R("", !0) : (c(), p("div", Pa, [
|
|
828
|
+
w("div", Da, [
|
|
829
|
+
w("h3", ja, k(s(r)("reportV5.reportAi.chat.exploreTitle")), 1),
|
|
830
|
+
w("p", Va, k(s(r)(
|
|
831
831
|
n.blank ? "reportV5.reportAi.chat.placeholderNew" : "reportV5.reportAi.chat.exploreHint"
|
|
832
832
|
)), 1)
|
|
833
833
|
]),
|
|
834
|
-
|
|
835
|
-
(c(!0),
|
|
836
|
-
key:
|
|
834
|
+
le.value.length ? (c(), p("div", Fa, [
|
|
835
|
+
(c(!0), p(ve, null, Se(le.value, (D) => (c(), p("button", {
|
|
836
|
+
key: D.label,
|
|
837
837
|
"data-testid": "report-canvas-suggestion",
|
|
838
838
|
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",
|
|
839
839
|
disabled: n.busy,
|
|
840
|
-
title:
|
|
841
|
-
onClick: (
|
|
840
|
+
title: D.prompt,
|
|
841
|
+
onClick: (re) => oe(D.prompt)
|
|
842
842
|
}, [
|
|
843
|
-
|
|
844
|
-
|
|
843
|
+
w("span", null, k(D.label), 1),
|
|
844
|
+
Z(f, {
|
|
845
845
|
name: "chevron_right",
|
|
846
846
|
size: "sm",
|
|
847
847
|
class: "shrink-0"
|
|
848
848
|
})
|
|
849
|
-
], 8,
|
|
849
|
+
], 8, Ba))), 128))
|
|
850
850
|
])) : R("", !0)
|
|
851
851
|
])),
|
|
852
|
-
|
|
852
|
+
se.value ? (c(), p("section", {
|
|
853
853
|
key: 1,
|
|
854
854
|
class: "shrink-0 pt-24",
|
|
855
855
|
"aria-label": s(r)("reportV5.reportAi.chat.recentChats")
|
|
856
856
|
}, [
|
|
857
|
-
|
|
858
|
-
|
|
857
|
+
w("h3", Ua, k(s(r)(
|
|
858
|
+
y.value ? "reportV5.reportAi.chat.yourChats" : "reportV5.reportAi.chat.recentChats"
|
|
859
859
|
)), 1),
|
|
860
|
-
n.chatsLoading && !((
|
|
861
|
-
key:
|
|
862
|
-
class:
|
|
860
|
+
n.chatsLoading && !((P = n.chats) != null && P.length) ? (c(), p("p", Ha, k(s(r)("reportV5.reportAi.chat.loadingChats")), 1)) : n.chatsError ? (c(), p("p", Wa, k(n.chatsError), 1)) : ($ = n.chats) != null && $.length ? (c(!0), p(ve, { key: 3 }, Se(ce.value, (D) => (c(), p("section", {
|
|
861
|
+
key: D.key,
|
|
862
|
+
class: Pe(y.value ? "mb-16" : "")
|
|
863
863
|
}, [
|
|
864
|
-
|
|
865
|
-
(c(!0),
|
|
866
|
-
key:
|
|
864
|
+
D.label ? (c(), p("p", Ya, k(D.label), 1)) : R("", !0),
|
|
865
|
+
(c(!0), p(ve, null, Se(D.chats, (re) => (c(), p("button", {
|
|
866
|
+
key: re.id,
|
|
867
867
|
"data-testid": "report-canvas-chat-list-item",
|
|
868
868
|
class: "chat-row flex w-full items-center gap-12 rounded-md px-8 py-12 text-left",
|
|
869
869
|
disabled: n.busy,
|
|
870
|
-
"aria-current":
|
|
871
|
-
title:
|
|
872
|
-
onClick: (
|
|
870
|
+
"aria-current": re.id === n.chatId ? "true" : void 0,
|
|
871
|
+
title: re.title,
|
|
872
|
+
onClick: (be) => Y(re.id)
|
|
873
873
|
}, [
|
|
874
|
-
|
|
875
|
-
|
|
876
|
-
datetime:
|
|
874
|
+
w("span", Ja, k(re.title), 1),
|
|
875
|
+
w("time", {
|
|
876
|
+
datetime: re.lastMessageAt,
|
|
877
877
|
class: "fm-typo-en-body-sm-400 shrink-0 text-fm-color-typo-secondary"
|
|
878
|
-
},
|
|
879
|
-
], 8,
|
|
880
|
-
], 2))), 128)) : (c(),
|
|
881
|
-
|
|
878
|
+
}, k(J(re)), 9, Xa)
|
|
879
|
+
], 8, Ka))), 128))
|
|
880
|
+
], 2))), 128)) : (c(), p("p", Ga, k(s(r)("reportV5.reportAi.chat.noChats")), 1)),
|
|
881
|
+
y.value ? n.chatsCursor ? (c(), p("button", {
|
|
882
882
|
key: 5,
|
|
883
883
|
"data-testid": "report-canvas-chat-list-more",
|
|
884
884
|
class: "chat-row fm-typo-en-body-sm-600 rounded-md px-8 py-12 text-fm-color-typo-secondary",
|
|
885
885
|
disabled: n.chatsLoading,
|
|
886
|
-
onClick: i[1] || (i[1] = (
|
|
887
|
-
},
|
|
886
|
+
onClick: i[1] || (i[1] = (D) => a("loadMoreChats"))
|
|
887
|
+
}, k(s(r)("reportV5.reportAi.chat.loadMoreChats")), 9, Za)) : R("", !0) : (c(), p("button", {
|
|
888
888
|
key: 4,
|
|
889
889
|
"data-testid": "report-canvas-chat-see-all",
|
|
890
890
|
class: "chat-row fm-typo-en-body-sm-600 mt-8 rounded-md px-8 py-12 text-fm-color-typo-secondary",
|
|
891
891
|
disabled: n.chatsLoading,
|
|
892
892
|
onClick: W
|
|
893
|
-
},
|
|
894
|
-
], 8,
|
|
895
|
-
n.error ? (c(),
|
|
896
|
-
], 8,
|
|
897
|
-
|
|
893
|
+
}, k(s(r)("reportV5.reportAi.chat.seeAll")), 9, Qa))
|
|
894
|
+
], 8, qa)) : R("", !0),
|
|
895
|
+
n.error ? (c(), p("p", er, k(n.error), 1)) : R("", !0)
|
|
896
|
+
], 8, Ma)) : (c(), p("div", tr, [
|
|
897
|
+
w("div", {
|
|
898
898
|
ref_key: "scroller",
|
|
899
|
-
ref:
|
|
899
|
+
ref: xe,
|
|
900
900
|
class: "min-h-0 grow overflow-y-auto px-[20px] py-16",
|
|
901
|
-
onScroll:
|
|
901
|
+
onScroll: S
|
|
902
902
|
}, [
|
|
903
|
-
N.value ? (c(),
|
|
904
|
-
n.earlier ? (c(),
|
|
903
|
+
N.value ? (c(), p("p", nr, k(s(r)("reportV5.reportAi.chat.loadingChat")), 1)) : (c(), p(ve, { key: 1 }, [
|
|
904
|
+
n.earlier ? (c(), p("button", {
|
|
905
905
|
key: 0,
|
|
906
906
|
"data-testid": "report-canvas-load-earlier",
|
|
907
907
|
class: "fm-typo-en-body-sm-600 mb-16 w-full text-fm-color-typo-secondary disabled:opacity-50",
|
|
908
908
|
disabled: n.loadingEarlier,
|
|
909
|
-
onClick: i[2] || (i[2] = (
|
|
910
|
-
},
|
|
911
|
-
(c(!0),
|
|
912
|
-
key:
|
|
909
|
+
onClick: i[2] || (i[2] = (D) => a("loadEarlier"))
|
|
910
|
+
}, k(s(r)("reportV5.reportAi.chat.loadEarlier")), 9, ar)) : R("", !0),
|
|
911
|
+
(c(!0), p(ve, null, Se(z.value, (D, re) => (c(), p("div", {
|
|
912
|
+
key: D.id,
|
|
913
913
|
class: "mb-16"
|
|
914
914
|
}, [
|
|
915
|
-
|
|
916
|
-
widget:
|
|
915
|
+
D.target ? (c(), p("p", rr, k(s(r)("reportV5.reportAi.chat.commentOn", {
|
|
916
|
+
widget: D.target.label || s(r)("reportV5.reportAi.chat.selectedWidget")
|
|
917
917
|
})), 1)) : R("", !0),
|
|
918
|
-
|
|
919
|
-
|
|
918
|
+
D.role === "user" ? (c(), p("div", or, [
|
|
919
|
+
w("div", {
|
|
920
920
|
"data-testid": "report-canvas-user-message",
|
|
921
|
-
class:
|
|
921
|
+
class: Pe([
|
|
922
922
|
"fm-typo-en-body-md-400 max-w-[90%] whitespace-pre-wrap rounded-md px-12 py-8 !leading-[21px]",
|
|
923
|
-
B.value.has(
|
|
923
|
+
B.value.has(D.id) ? "bg-fm-color-neutral-gray-100 text-fm-color-typo-secondary" : "bg-fm-color-system-info-100"
|
|
924
924
|
])
|
|
925
|
-
},
|
|
926
|
-
B.value.has(
|
|
927
|
-
|
|
928
|
-
|
|
925
|
+
}, k(D.answer), 3),
|
|
926
|
+
B.value.has(D.id) ? (c(), p("p", ir, [
|
|
927
|
+
Ft(k(s(r)("reportV5.reportAi.chat.notSent")) + " ", 1),
|
|
928
|
+
w("button", {
|
|
929
929
|
"data-testid": "chat-message-resend",
|
|
930
930
|
class: "ml-4 underline disabled:opacity-50",
|
|
931
931
|
disabled: n.streaming || n.busy,
|
|
932
|
-
onClick: (
|
|
933
|
-
},
|
|
934
|
-
])) :
|
|
932
|
+
onClick: (be) => a("resend", D.id)
|
|
933
|
+
}, k(s(r)("reportV5.reportAi.chat.resend")), 9, sr)
|
|
934
|
+
])) : F.value.has(D.turnId) ? (c(), p("button", {
|
|
935
935
|
key: 1,
|
|
936
936
|
"data-testid": "chat-turn-undo",
|
|
937
937
|
class: "fm-typo-en-body-sm-400 mt-4 text-fm-color-typo-secondary underline disabled:opacity-50",
|
|
938
938
|
disabled: n.undoing || n.streaming,
|
|
939
|
-
onClick: (
|
|
940
|
-
},
|
|
941
|
-
])) : (c(),
|
|
942
|
-
|
|
939
|
+
onClick: (be) => a("undo", D.turnId)
|
|
940
|
+
}, k(s(r)("reportV5.reportCanvas.draft.undo")), 9, lr)) : R("", !0)
|
|
941
|
+
])) : (c(), p(ve, { key: 2 }, [
|
|
942
|
+
re === g.value || re === H.value ? (c(), me(At, St({
|
|
943
943
|
key: 0,
|
|
944
944
|
class: "mb-8",
|
|
945
945
|
ref_for: !0
|
|
946
|
-
},
|
|
947
|
-
onRetry: i[3] || (i[3] = (
|
|
948
|
-
onCheckStatus: i[4] || (i[4] = (
|
|
946
|
+
}, ye(re), {
|
|
947
|
+
onRetry: i[3] || (i[3] = (be) => a("retry", be)),
|
|
948
|
+
onCheckStatus: i[4] || (i[4] = (be) => a("checkStatus"))
|
|
949
949
|
}), null, 16)) : R("", !0),
|
|
950
|
-
|
|
950
|
+
D.blocks.length ? (c(), me(ma, {
|
|
951
951
|
key: 1,
|
|
952
952
|
"data-testid": "report-canvas-answer",
|
|
953
|
-
blocks:
|
|
954
|
-
preview:
|
|
955
|
-
}, null, 8, ["blocks", "preview"])) :
|
|
956
|
-
|
|
953
|
+
blocks: D.blocks,
|
|
954
|
+
preview: D.preview
|
|
955
|
+
}, null, 8, ["blocks", "preview"])) : D.noSummary ? (c(), p("p", fr, k(s(r)("reportV5.reportAi.chat.noSummary")), 1)) : R("", !0),
|
|
956
|
+
D.ms ? (c(), p("p", dr, k(s(r)("reportV5.reportAi.chat.took", { duration: s(Sa)(D.ms) })), 1)) : R("", !0)
|
|
957
957
|
], 64))
|
|
958
958
|
]))), 128)),
|
|
959
|
-
|
|
959
|
+
K.value ? (c(), me(At, St({
|
|
960
960
|
key: 1,
|
|
961
961
|
class: "mb-16"
|
|
962
|
-
},
|
|
963
|
-
onRetry: i[5] || (i[5] = (
|
|
964
|
-
onCheckStatus: i[6] || (i[6] = (
|
|
962
|
+
}, ye(-1), {
|
|
963
|
+
onRetry: i[5] || (i[5] = (D) => a("retry", D)),
|
|
964
|
+
onCheckStatus: i[6] || (i[6] = (D) => a("checkStatus"))
|
|
965
965
|
}), null, 16)) : R("", !0),
|
|
966
|
-
n.error ? (c(),
|
|
966
|
+
n.error ? (c(), p("p", cr, k(n.error), 1)) : R("", !0)
|
|
967
967
|
], 64))
|
|
968
968
|
], 544),
|
|
969
|
-
u.value ? (c(),
|
|
969
|
+
u.value ? (c(), p("button", {
|
|
970
970
|
key: 0,
|
|
971
971
|
"data-testid": "report-canvas-jump-latest",
|
|
972
972
|
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",
|
|
973
973
|
onClick: M
|
|
974
|
-
},
|
|
974
|
+
}, k(s(r)("reportV5.reportAi.chat.jumpToLatest")), 1)) : R("", !0)
|
|
975
975
|
])),
|
|
976
|
-
|
|
977
|
-
|
|
976
|
+
w("div", mr, [
|
|
977
|
+
Z(la, {
|
|
978
978
|
ref_key: "composer",
|
|
979
|
-
ref:
|
|
980
|
-
draft:
|
|
979
|
+
ref: _,
|
|
980
|
+
draft: h.value ? I.value : n.draft,
|
|
981
981
|
target: n.target,
|
|
982
982
|
"target-stale": n.targetStale,
|
|
983
|
-
streaming: n.streaming || n.switching ||
|
|
983
|
+
streaming: n.streaming || n.switching || b.value || h.value && !!n.busy,
|
|
984
984
|
blank: n.blank,
|
|
985
|
-
"onUpdate:draft":
|
|
985
|
+
"onUpdate:draft": te,
|
|
986
986
|
onSubmit: d,
|
|
987
|
-
onClearTarget: i[7] || (i[7] = (
|
|
987
|
+
onClearTarget: i[7] || (i[7] = (D) => a("clearTarget"))
|
|
988
988
|
}, null, 8, ["draft", "target", "target-stale", "streaming", "blank"])
|
|
989
989
|
])
|
|
990
|
-
], 40,
|
|
990
|
+
], 40, Ta);
|
|
991
991
|
};
|
|
992
992
|
}
|
|
993
|
-
}),
|
|
994
|
-
function
|
|
995
|
-
const { businessId: e } =
|
|
993
|
+
}), br = /* @__PURE__ */ ut(hr, [["__scopeId", "data-v-0840b672"]]);
|
|
994
|
+
function ze(o) {
|
|
995
|
+
const { businessId: e } = Oe(Ye());
|
|
996
996
|
if (!e.value) throw new Error("Business Id is not defined");
|
|
997
997
|
return `/${e.value}/report-canvas/${o}`;
|
|
998
998
|
}
|
|
999
|
-
const
|
|
999
|
+
const Rt = (o) => {
|
|
1000
1000
|
const e = {
|
|
1001
|
-
fetchType:
|
|
1002
|
-
url:
|
|
1001
|
+
fetchType: pe.Get,
|
|
1002
|
+
url: ze(o)
|
|
1003
1003
|
};
|
|
1004
|
-
return
|
|
1005
|
-
},
|
|
1004
|
+
return ue.fetch(e);
|
|
1005
|
+
}, gr = (o, e, t, a, r) => {
|
|
1006
1006
|
const m = {
|
|
1007
|
-
fetchType:
|
|
1008
|
-
url: `${
|
|
1007
|
+
fetchType: pe.Post,
|
|
1008
|
+
url: `${ze(o)}/query/${e}`,
|
|
1009
1009
|
// a draft-only query id does not exist on the published copy, so the state travels with it
|
|
1010
1010
|
data: { params: t, timezone: a, state: r }
|
|
1011
1011
|
};
|
|
1012
|
-
return
|
|
1013
|
-
},
|
|
1012
|
+
return ue.fetch(m);
|
|
1013
|
+
}, vr = (o, e, t, a) => {
|
|
1014
1014
|
const r = {
|
|
1015
|
-
fetchType:
|
|
1016
|
-
url: `${
|
|
1015
|
+
fetchType: pe.Post,
|
|
1016
|
+
url: `${ze(o)}/section/${e}/ack`,
|
|
1017
1017
|
data: { ...t, state: a }
|
|
1018
1018
|
};
|
|
1019
|
-
return
|
|
1020
|
-
},
|
|
1021
|
-
fetchType:
|
|
1022
|
-
url: `${
|
|
1019
|
+
return ue.fetch(r);
|
|
1020
|
+
}, yr = (o) => ue.fetch({
|
|
1021
|
+
fetchType: pe.Post,
|
|
1022
|
+
url: `${ze(o)}/publish`,
|
|
1023
1023
|
data: {}
|
|
1024
|
-
}),
|
|
1025
|
-
fetchType:
|
|
1026
|
-
url: `${
|
|
1027
|
-
}),
|
|
1028
|
-
fetchType:
|
|
1029
|
-
url: `${
|
|
1024
|
+
}), xr = (o) => ue.fetch({
|
|
1025
|
+
fetchType: pe.Delete,
|
|
1026
|
+
url: `${ze(o)}/draft`
|
|
1027
|
+
}), wr = (o, e) => ue.fetch({
|
|
1028
|
+
fetchType: pe.Post,
|
|
1029
|
+
url: `${ze(o)}/draft/undo`,
|
|
1030
1030
|
data: { turnId: e }
|
|
1031
|
-
}),
|
|
1032
|
-
fetchType:
|
|
1033
|
-
url: `${
|
|
1034
|
-
}),
|
|
1035
|
-
fetchType:
|
|
1036
|
-
url: `${
|
|
1031
|
+
}), kr = (o) => ue.fetch({
|
|
1032
|
+
fetchType: pe.Get,
|
|
1033
|
+
url: `${ze(o)}/versions`
|
|
1034
|
+
}), _r = (o, e) => ue.fetch({
|
|
1035
|
+
fetchType: pe.Post,
|
|
1036
|
+
url: `${ze(o)}/restore`,
|
|
1037
1037
|
data: { versionId: e }
|
|
1038
|
-
}),
|
|
1038
|
+
}), Sr = ["aria-label"], Ir = { class: "flex h-64 shrink-0 items-center gap-12 border-b border-fm-color-border-secondary px-[20px]" }, Cr = { class: "fm-typo-en-body-md-600 grow" }, Ar = ["aria-label", "disabled"], Tr = { class: "min-h-0 grow overflow-y-auto px-[20px] py-[20px]" }, Er = { class: "fm-typo-en-body-md-400 mb-[20px] text-fm-color-typo-secondary" }, Or = { class: "mb-24 rounded-[12px] border border-fm-color-border-secondary p-16" }, zr = { class: "mb-8 flex items-center gap-8" }, Nr = { class: "fm-typo-en-body-md-600 grow" }, $r = { class: "fm-typo-en-body-sm-600 rounded-md bg-fm-color-neutral-gray-100 px-8 py-4" }, Rr = {
|
|
1039
1039
|
key: 0,
|
|
1040
1040
|
class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary"
|
|
1041
|
-
},
|
|
1041
|
+
}, Lr = ["aria-label"], Mr = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, Pr = {
|
|
1042
1042
|
key: 1,
|
|
1043
1043
|
role: "alert",
|
|
1044
1044
|
class: "rounded-[12px] border border-fm-color-border-secondary p-[20px]"
|
|
1045
|
-
},
|
|
1045
|
+
}, Dr = { class: "fm-typo-en-body-md-600 mb-8" }, jr = { class: "fm-typo-en-body-md-400 mb-16 text-fm-color-typo-secondary" }, Vr = {
|
|
1046
1046
|
key: 2,
|
|
1047
1047
|
class: "flex flex-col items-center rounded-[12px] bg-fm-color-neutral-gray-50 px-16 py-32 text-center"
|
|
1048
|
-
},
|
|
1048
|
+
}, Fr = { class: "fm-typo-en-body-md-600 mb-8" }, Br = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, qr = { class: "fm-typo-en-body-sm-600 mb-12 text-fm-color-typo-secondary" }, Ur = { class: "ml-4 border-l border-fm-color-border-secondary pl-16" }, Hr = ["aria-expanded", "aria-controls", "aria-current", "disabled", "onClick"], Wr = { class: "mb-4 flex items-center gap-8" }, Gr = ["datetime", "title"], Yr = {
|
|
1049
1049
|
key: 0,
|
|
1050
1050
|
"data-testid": "canvas-version-current",
|
|
1051
1051
|
class: "fm-typo-en-body-sm-600 rounded-md bg-fm-color-neutral-gray-100 px-8 py-4 text-fm-color-typo-secondary"
|
|
1052
|
-
},
|
|
1052
|
+
}, Kr = {
|
|
1053
1053
|
key: 0,
|
|
1054
1054
|
class: "fm-typo-en-body-md-600 block break-words text-fm-color-typo-secondary"
|
|
1055
|
-
},
|
|
1055
|
+
}, Jr = { class: "fm-typo-en-body-md-400 line-clamp-3 block break-words" }, Xr = {
|
|
1056
1056
|
"data-testid": "canvas-version-author",
|
|
1057
1057
|
class: "mt-8 flex items-center gap-8 text-fm-color-typo-secondary"
|
|
1058
|
-
},
|
|
1058
|
+
}, Qr = { class: "fm-typo-en-body-sm-400 line-clamp-1 break-words" }, Zr = { class: "shrink-0 border-t border-fm-color-border-secondary p-[20px]" }, eo = { class: "fm-typo-en-body-sm-400 mb-4 text-fm-color-typo-secondary" }, to = { class: "fm-typo-en-body-md-400 mb-16 max-h-[120px] overflow-y-auto whitespace-pre-wrap break-words" }, no = {
|
|
1059
1059
|
key: 0,
|
|
1060
1060
|
role: "alert",
|
|
1061
1061
|
class: "fm-typo-en-body-md-400 mb-12 text-fm-color-typo-error"
|
|
1062
|
-
},
|
|
1062
|
+
}, ao = {
|
|
1063
1063
|
key: 1,
|
|
1064
1064
|
class: "fm-typo-en-body-md-400 mb-12 text-fm-color-typo-secondary"
|
|
1065
|
-
},
|
|
1065
|
+
}, ro = {
|
|
1066
1066
|
key: 2,
|
|
1067
1067
|
class: "flex items-center justify-end gap-8"
|
|
1068
|
-
},
|
|
1068
|
+
}, oo = ["disabled"], io = {
|
|
1069
1069
|
key: 1,
|
|
1070
1070
|
class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary"
|
|
1071
|
-
},
|
|
1071
|
+
}, so = { class: "fm-typo-en-body-sm-400 mt-12 text-fm-color-typo-secondary" }, lo = /* @__PURE__ */ je({
|
|
1072
1072
|
__name: "ReportCanvasHistory",
|
|
1073
1073
|
props: {
|
|
1074
1074
|
reportId: {},
|
|
@@ -1079,259 +1079,259 @@ const $t = (o) => {
|
|
|
1079
1079
|
},
|
|
1080
1080
|
emits: ["close", "restored", "restoring"],
|
|
1081
1081
|
setup(o, { emit: e }) {
|
|
1082
|
-
const t = o, a = e, { t: r, locale: m } =
|
|
1082
|
+
const t = o, a = e, { t: r, locale: m } = Ve(), h = (C, u = {}) => r(`reportV5.reportCanvas.history.${C}`, u), y = T([]), I = T(!0), b = T(!1), L = T(!1), x = T(!1), N = T(!1), E = T(), W = T(), j = T(), Y = T(), U = V(() => y.value.find((C) => C.id === E.value)), O = V(() => t.hasDraft || t.busy || x.value);
|
|
1083
1083
|
let G = !0, J = null;
|
|
1084
|
-
function
|
|
1085
|
-
const
|
|
1086
|
-
return Number.isFinite(
|
|
1087
|
-
|
|
1088
|
-
) :
|
|
1089
|
-
}
|
|
1090
|
-
const B = (
|
|
1091
|
-
function C
|
|
1092
|
-
return z(
|
|
1093
|
-
}
|
|
1094
|
-
const
|
|
1095
|
-
const
|
|
1096
|
-
for (const u of [...
|
|
1097
|
-
const
|
|
1098
|
-
M ? M.versions.push(u) :
|
|
1084
|
+
function F(C, u) {
|
|
1085
|
+
const S = new Date(C);
|
|
1086
|
+
return Number.isFinite(S.getTime()) ? new Intl.DateTimeFormat(m.value, { ...u, timeZone: t.timezone }).format(
|
|
1087
|
+
S
|
|
1088
|
+
) : h("unknownDate");
|
|
1089
|
+
}
|
|
1090
|
+
const B = (C) => F(C, { dateStyle: "medium", timeStyle: "short" }), _ = (C) => F(C, { hour: "numeric", minute: "2-digit", second: "2-digit" }), z = (C) => F(C, { year: "numeric", month: "2-digit", day: "2-digit" });
|
|
1091
|
+
function g(C) {
|
|
1092
|
+
return z(C) === z((/* @__PURE__ */ new Date()).toISOString()) ? h("today") : F(C, { month: "long", day: "numeric", year: "numeric" });
|
|
1093
|
+
}
|
|
1094
|
+
const H = V(() => {
|
|
1095
|
+
const C = [];
|
|
1096
|
+
for (const u of [...y.value].sort((S, M) => Date.parse(M.at) - Date.parse(S.at))) {
|
|
1097
|
+
const S = z(u.at), M = C.find((d) => d.key === S);
|
|
1098
|
+
M ? M.versions.push(u) : C.push({ key: S, label: g(u.at), versions: [u] });
|
|
1099
1099
|
}
|
|
1100
|
-
return
|
|
1101
|
-
}),
|
|
1100
|
+
return C;
|
|
1101
|
+
}), K = (C) => {
|
|
1102
1102
|
var u;
|
|
1103
|
-
return
|
|
1104
|
-
},
|
|
1105
|
-
var u,
|
|
1106
|
-
return ((u =
|
|
1103
|
+
return C.id === ((u = y.value[0]) == null ? void 0 : u.id);
|
|
1104
|
+
}, ee = (C) => C.prompt.trim() || h("noPrompt"), X = (C) => C.restoredFrom ? h("restoredFrom", { at: B(C.restoredFrom) }) : "", se = (C) => [X(C), ee(C)].filter(Boolean).join(" "), ce = (C) => {
|
|
1105
|
+
var u, S;
|
|
1106
|
+
return ((u = C.author) == null ? void 0 : u.name) || ((S = C.author) == null ? void 0 : S.email) || h("unknownUser");
|
|
1107
1107
|
};
|
|
1108
|
-
async function
|
|
1109
|
-
I.value = !0,
|
|
1108
|
+
async function ye() {
|
|
1109
|
+
I.value = !0, b.value = !1;
|
|
1110
1110
|
try {
|
|
1111
|
-
const
|
|
1112
|
-
G && (
|
|
1111
|
+
const C = await kr(t.reportId);
|
|
1112
|
+
G && (y.value = C);
|
|
1113
1113
|
} catch {
|
|
1114
|
-
G && (
|
|
1114
|
+
G && (b.value = !0);
|
|
1115
1115
|
} finally {
|
|
1116
1116
|
G && (I.value = !1);
|
|
1117
1117
|
}
|
|
1118
1118
|
}
|
|
1119
|
-
function
|
|
1120
|
-
|
|
1119
|
+
function he(C) {
|
|
1120
|
+
x.value || K(C) || (E.value = E.value === C.id ? void 0 : C.id, N.value = !1, L.value = !1);
|
|
1121
1121
|
}
|
|
1122
|
-
async function
|
|
1123
|
-
var
|
|
1124
|
-
!
|
|
1122
|
+
async function le() {
|
|
1123
|
+
var C;
|
|
1124
|
+
!U.value || O.value || (N.value = !0, await Ee(), (C = j.value) == null || C.focus());
|
|
1125
1125
|
}
|
|
1126
|
-
async function
|
|
1127
|
-
var
|
|
1128
|
-
N.value = !1, L.value = !1, await
|
|
1126
|
+
async function oe() {
|
|
1127
|
+
var C;
|
|
1128
|
+
N.value = !1, L.value = !1, await Ee(), (C = Y.value) == null || C.focus();
|
|
1129
1129
|
}
|
|
1130
|
-
async function
|
|
1131
|
-
if (!(!
|
|
1132
|
-
|
|
1130
|
+
async function te() {
|
|
1131
|
+
if (!(!U.value || O.value || !N.value)) {
|
|
1132
|
+
x.value = !0, a("restoring", !0), L.value = !1;
|
|
1133
1133
|
try {
|
|
1134
|
-
const
|
|
1135
|
-
G && a("restored",
|
|
1134
|
+
const C = await _r(t.reportId, U.value.id);
|
|
1135
|
+
G && a("restored", C);
|
|
1136
1136
|
} catch {
|
|
1137
1137
|
G && (L.value = !0);
|
|
1138
1138
|
} finally {
|
|
1139
|
-
|
|
1139
|
+
x.value = !1, a("restoring", !1);
|
|
1140
1140
|
}
|
|
1141
1141
|
}
|
|
1142
1142
|
}
|
|
1143
|
-
function
|
|
1144
|
-
|
|
1143
|
+
function xe(C) {
|
|
1144
|
+
C.key === "Escape" && (C.stopPropagation(), !x.value && (N.value ? oe() : a("close")));
|
|
1145
1145
|
}
|
|
1146
|
-
return
|
|
1147
|
-
|
|
1148
|
-
}),
|
|
1149
|
-
var
|
|
1150
|
-
J = document.activeElement, (
|
|
1151
|
-
}),
|
|
1146
|
+
return de(O, (C) => {
|
|
1147
|
+
C && !x.value && (N.value = !1);
|
|
1148
|
+
}), Me(() => {
|
|
1149
|
+
var C;
|
|
1150
|
+
J = document.activeElement, (C = W.value) == null || C.focus(), ye();
|
|
1151
|
+
}), De(() => {
|
|
1152
1152
|
G = !1, J == null || J.focus();
|
|
1153
|
-
}), (
|
|
1154
|
-
const
|
|
1155
|
-
return c(),
|
|
1153
|
+
}), (C, u) => {
|
|
1154
|
+
const S = Ie("FmIcon"), M = Ie("FmButton"), d = Ie("FmAvatar");
|
|
1155
|
+
return c(), p("aside", {
|
|
1156
1156
|
"data-testid": "canvas-versions",
|
|
1157
1157
|
class: "flex h-full min-h-0 flex-col border-l border-fm-color-border-secondary bg-fm-color-neutral-white text-fm-color-typo-primary",
|
|
1158
|
-
"aria-label":
|
|
1159
|
-
onKeydown:
|
|
1158
|
+
"aria-label": h("title"),
|
|
1159
|
+
onKeydown: xe
|
|
1160
1160
|
}, [
|
|
1161
|
-
|
|
1162
|
-
|
|
1161
|
+
w("header", Ir, [
|
|
1162
|
+
Z(S, {
|
|
1163
1163
|
name: "history",
|
|
1164
1164
|
size: "md",
|
|
1165
1165
|
class: "text-fm-color-typo-secondary"
|
|
1166
1166
|
}),
|
|
1167
|
-
|
|
1168
|
-
|
|
1167
|
+
w("h2", Cr, k(h("title")), 1),
|
|
1168
|
+
w("button", {
|
|
1169
1169
|
ref_key: "closeButton",
|
|
1170
1170
|
ref: W,
|
|
1171
1171
|
"data-testid": "canvas-versions-close",
|
|
1172
1172
|
class: "history-button flex h-[36px] w-[36px] items-center justify-center rounded-md text-fm-color-typo-secondary",
|
|
1173
|
-
"aria-label":
|
|
1174
|
-
disabled:
|
|
1173
|
+
"aria-label": h("close"),
|
|
1174
|
+
disabled: x.value,
|
|
1175
1175
|
onClick: u[0] || (u[0] = (n) => a("close"))
|
|
1176
1176
|
}, [
|
|
1177
|
-
|
|
1177
|
+
Z(S, {
|
|
1178
1178
|
name: "close",
|
|
1179
1179
|
size: "md"
|
|
1180
1180
|
})
|
|
1181
|
-
], 8,
|
|
1181
|
+
], 8, Ar)
|
|
1182
1182
|
]),
|
|
1183
|
-
|
|
1184
|
-
|
|
1185
|
-
|
|
1186
|
-
|
|
1187
|
-
u[1] || (u[1] =
|
|
1183
|
+
w("div", Tr, [
|
|
1184
|
+
w("p", Er, k(h("intro")), 1),
|
|
1185
|
+
w("div", Or, [
|
|
1186
|
+
w("div", zr, [
|
|
1187
|
+
u[1] || (u[1] = w("span", {
|
|
1188
1188
|
class: "h-8 w-8 rounded-full bg-fm-color-primary",
|
|
1189
1189
|
"aria-hidden": "true"
|
|
1190
1190
|
}, null, -1)),
|
|
1191
|
-
|
|
1192
|
-
|
|
1191
|
+
w("span", Nr, k(h("current")), 1),
|
|
1192
|
+
w("span", $r, k(h("published")), 1)
|
|
1193
1193
|
]),
|
|
1194
|
-
|
|
1194
|
+
C.publishedAt ? (c(), p("p", Rr, k(B(C.publishedAt)), 1)) : R("", !0)
|
|
1195
1195
|
]),
|
|
1196
|
-
I.value ? (c(),
|
|
1196
|
+
I.value ? (c(), p("div", {
|
|
1197
1197
|
key: 0,
|
|
1198
1198
|
role: "status",
|
|
1199
1199
|
class: "space-y-16",
|
|
1200
|
-
"aria-label":
|
|
1200
|
+
"aria-label": h("loading")
|
|
1201
1201
|
}, [
|
|
1202
|
-
|
|
1203
|
-
(c(),
|
|
1202
|
+
w("p", Mr, k(h("loading")), 1),
|
|
1203
|
+
(c(), p(ve, null, Se(3, (n) => w("div", {
|
|
1204
1204
|
key: n,
|
|
1205
1205
|
class: "rounded-lg border border-fm-color-border-secondary p-16",
|
|
1206
1206
|
"aria-hidden": "true"
|
|
1207
1207
|
}, u[2] || (u[2] = [
|
|
1208
|
-
|
|
1209
|
-
|
|
1208
|
+
w("div", { class: "mb-12 h-12 w-1/3 rounded bg-fm-color-neutral-gray-100" }, null, -1),
|
|
1209
|
+
w("div", { class: "h-12 w-3/4 rounded bg-fm-color-neutral-gray-100" }, null, -1)
|
|
1210
1210
|
]))), 64))
|
|
1211
|
-
], 8,
|
|
1212
|
-
|
|
1213
|
-
|
|
1214
|
-
|
|
1211
|
+
], 8, Lr)) : b.value ? (c(), p("div", Pr, [
|
|
1212
|
+
w("p", Dr, k(h("loadFailed")), 1),
|
|
1213
|
+
w("p", jr, k(h("loadFailedHint")), 1),
|
|
1214
|
+
Z(M, {
|
|
1215
1215
|
variant: "secondary",
|
|
1216
|
-
label:
|
|
1217
|
-
onClick:
|
|
1216
|
+
label: h("retry"),
|
|
1217
|
+
onClick: ye
|
|
1218
1218
|
}, null, 8, ["label"])
|
|
1219
|
-
])) :
|
|
1220
|
-
|
|
1219
|
+
])) : y.value.length ? R("", !0) : (c(), p("div", Vr, [
|
|
1220
|
+
Z(S, {
|
|
1221
1221
|
name: "history",
|
|
1222
1222
|
size: "lg",
|
|
1223
1223
|
class: "mb-12 text-fm-color-typo-secondary"
|
|
1224
1224
|
}),
|
|
1225
|
-
|
|
1226
|
-
|
|
1225
|
+
w("p", Fr, k(h("empty")), 1),
|
|
1226
|
+
w("p", Br, k(h("emptyHint")), 1)
|
|
1227
1227
|
])),
|
|
1228
|
-
(c(!0),
|
|
1228
|
+
(c(!0), p(ve, null, Se(I.value || b.value ? [] : H.value, (n) => (c(), p("section", {
|
|
1229
1229
|
key: n.key,
|
|
1230
1230
|
class: "mb-[20px]"
|
|
1231
1231
|
}, [
|
|
1232
|
-
|
|
1233
|
-
|
|
1234
|
-
(c(!0),
|
|
1235
|
-
var f,
|
|
1236
|
-
return c(),
|
|
1232
|
+
w("h3", qr, k(n.label), 1),
|
|
1233
|
+
w("ul", Ur, [
|
|
1234
|
+
(c(!0), p(ve, null, Se(n.versions, (i) => {
|
|
1235
|
+
var f, A, P;
|
|
1236
|
+
return c(), p("li", {
|
|
1237
1237
|
key: i.id,
|
|
1238
1238
|
"data-testid": "canvas-version-row",
|
|
1239
1239
|
class: "relative mb-8"
|
|
1240
1240
|
}, [
|
|
1241
|
-
u[3] || (u[3] =
|
|
1241
|
+
u[3] || (u[3] = w("span", {
|
|
1242
1242
|
class: "history-dot absolute top-[20px] h-8 w-8 rounded-full border border-fm-color-border-secondary bg-fm-color-neutral-white",
|
|
1243
1243
|
"aria-hidden": "true"
|
|
1244
1244
|
}, null, -1)),
|
|
1245
|
-
|
|
1246
|
-
class:
|
|
1245
|
+
w("button", {
|
|
1246
|
+
class: Pe([
|
|
1247
1247
|
"history-button w-full rounded-lg border p-12 text-left",
|
|
1248
|
-
|
|
1248
|
+
E.value === i.id ? "border-fm-color-primary bg-fm-color-primary-50" : "border-transparent"
|
|
1249
1249
|
]),
|
|
1250
|
-
"aria-expanded":
|
|
1251
|
-
"aria-controls":
|
|
1252
|
-
"aria-current":
|
|
1253
|
-
disabled:
|
|
1254
|
-
onClick: (
|
|
1250
|
+
"aria-expanded": E.value === i.id,
|
|
1251
|
+
"aria-controls": E.value === i.id ? "canvas-version-details" : void 0,
|
|
1252
|
+
"aria-current": K(i) ? "true" : void 0,
|
|
1253
|
+
disabled: x.value || K(i),
|
|
1254
|
+
onClick: ($) => he(i)
|
|
1255
1255
|
}, [
|
|
1256
|
-
|
|
1257
|
-
|
|
1256
|
+
w("span", Wr, [
|
|
1257
|
+
w("time", {
|
|
1258
1258
|
datetime: i.at,
|
|
1259
1259
|
title: B(i.at),
|
|
1260
1260
|
class: "fm-typo-en-body-sm-400 grow text-fm-color-typo-secondary"
|
|
1261
|
-
},
|
|
1262
|
-
|
|
1261
|
+
}, k(_(i.at)), 9, Gr),
|
|
1262
|
+
K(i) ? (c(), p("span", Yr, k(h("currentBadge")), 1)) : E.value === i.id ? (c(), me(S, {
|
|
1263
1263
|
key: 1,
|
|
1264
1264
|
name: "check",
|
|
1265
1265
|
size: "sm",
|
|
1266
1266
|
class: "text-fm-color-primary"
|
|
1267
1267
|
})) : R("", !0)
|
|
1268
1268
|
]),
|
|
1269
|
-
|
|
1270
|
-
|
|
1271
|
-
|
|
1272
|
-
|
|
1269
|
+
X(i) ? (c(), p("span", Kr, k(X(i)), 1)) : R("", !0),
|
|
1270
|
+
w("span", Jr, k(ee(i)), 1),
|
|
1271
|
+
w("span", Xr, [
|
|
1272
|
+
Z(d, {
|
|
1273
1273
|
size: "sm",
|
|
1274
|
-
name: ((f = i.author) == null ? void 0 : f.name) || ((
|
|
1275
|
-
src: (
|
|
1274
|
+
name: ((f = i.author) == null ? void 0 : f.name) || ((A = i.author) == null ? void 0 : A.email) || "?",
|
|
1275
|
+
src: (P = i.author) == null ? void 0 : P.photoUrl
|
|
1276
1276
|
}, null, 8, ["name", "src"]),
|
|
1277
|
-
|
|
1277
|
+
w("span", Qr, k(ce(i)), 1)
|
|
1278
1278
|
])
|
|
1279
|
-
], 10,
|
|
1279
|
+
], 10, Hr)
|
|
1280
1280
|
]);
|
|
1281
1281
|
}), 128))
|
|
1282
1282
|
])
|
|
1283
1283
|
]))), 128))
|
|
1284
1284
|
]),
|
|
1285
|
-
|
|
1286
|
-
|
|
1285
|
+
w("footer", Zr, [
|
|
1286
|
+
U.value ? (c(), p("div", {
|
|
1287
1287
|
key: 0,
|
|
1288
1288
|
id: "canvas-version-details",
|
|
1289
1289
|
ref_key: "details",
|
|
1290
|
-
ref:
|
|
1290
|
+
ref: Y,
|
|
1291
1291
|
tabindex: "-1",
|
|
1292
1292
|
class: "history-details"
|
|
1293
1293
|
}, [
|
|
1294
|
-
|
|
1295
|
-
|
|
1296
|
-
L.value ? (c(),
|
|
1297
|
-
|
|
1298
|
-
N.value ? (c(),
|
|
1299
|
-
|
|
1294
|
+
w("p", eo, k(h("savedBy", { user: ce(U.value), at: B(U.value.at) })), 1),
|
|
1295
|
+
w("p", to, k(N.value ? h("confirmHint") : se(U.value)), 1),
|
|
1296
|
+
L.value ? (c(), p("p", no, k(h("restoreFailed")), 1)) : R("", !0),
|
|
1297
|
+
C.hasDraft || C.busy ? (c(), p("p", ao, k(h(C.hasDraft ? "draftHint" : "busyHint")), 1)) : R("", !0),
|
|
1298
|
+
N.value ? (c(), p("div", ro, [
|
|
1299
|
+
w("button", {
|
|
1300
1300
|
ref_key: "cancelButton",
|
|
1301
|
-
ref:
|
|
1301
|
+
ref: j,
|
|
1302
1302
|
class: "history-button fm-typo-en-body-md-600 rounded-lg px-16 py-12",
|
|
1303
|
-
disabled:
|
|
1304
|
-
onClick:
|
|
1305
|
-
},
|
|
1306
|
-
|
|
1303
|
+
disabled: x.value,
|
|
1304
|
+
onClick: oe
|
|
1305
|
+
}, k(h("cancel")), 9, oo),
|
|
1306
|
+
Z(M, {
|
|
1307
1307
|
"data-testid": "canvas-version-confirm",
|
|
1308
1308
|
variant: "primary",
|
|
1309
|
-
label:
|
|
1310
|
-
disabled:
|
|
1311
|
-
onClick:
|
|
1309
|
+
label: h(x.value ? "restoring" : "confirm"),
|
|
1310
|
+
disabled: O.value,
|
|
1311
|
+
onClick: te
|
|
1312
1312
|
}, null, 8, ["label", "disabled"])
|
|
1313
|
-
])) : (c(),
|
|
1313
|
+
])) : (c(), me(M, {
|
|
1314
1314
|
key: 3,
|
|
1315
1315
|
"data-testid": "canvas-version-restore",
|
|
1316
1316
|
class: "w-full",
|
|
1317
1317
|
variant: "primary",
|
|
1318
1318
|
"prepend-icon": "restore",
|
|
1319
|
-
label:
|
|
1320
|
-
disabled:
|
|
1321
|
-
onClick:
|
|
1319
|
+
label: h("restore"),
|
|
1320
|
+
disabled: O.value,
|
|
1321
|
+
onClick: le
|
|
1322
1322
|
}, null, 8, ["label", "disabled"]))
|
|
1323
|
-
], 512)) : (c(),
|
|
1324
|
-
|
|
1323
|
+
], 512)) : (c(), p("p", io, k(h("selectHint")), 1)),
|
|
1324
|
+
w("p", so, k(h("timezone", { timezone: C.timezone })), 1)
|
|
1325
1325
|
])
|
|
1326
|
-
], 40,
|
|
1326
|
+
], 40, Sr);
|
|
1327
1327
|
};
|
|
1328
1328
|
}
|
|
1329
|
-
}),
|
|
1330
|
-
function
|
|
1331
|
-
if (!(!(o instanceof
|
|
1332
|
-
return Math.min(Math.max(o.retryAfterMs ??
|
|
1329
|
+
}), fo = /* @__PURE__ */ ut(lo, [["__scopeId", "data-v-7df5ac71"]]), co = ["@from", "@to", "@locationIds", "@timezone"], lt = ["@from", "@to", "@locationIds"], mo = ["@timezone"], uo = ["@locationIds"], po = 1, ho = 1500;
|
|
1330
|
+
function bo(o) {
|
|
1331
|
+
if (!(!(o instanceof kn) || o.status !== 429))
|
|
1332
|
+
return Math.min(Math.max(o.retryAfterMs ?? ho, 500), 5e3);
|
|
1333
1333
|
}
|
|
1334
|
-
const
|
|
1334
|
+
const go = {
|
|
1335
1335
|
MY: "MYR",
|
|
1336
1336
|
SG: "SGD",
|
|
1337
1337
|
TH: "THB",
|
|
@@ -1349,66 +1349,66 @@ const po = {
|
|
|
1349
1349
|
TW: "TWD",
|
|
1350
1350
|
HK: "HKD"
|
|
1351
1351
|
};
|
|
1352
|
-
function
|
|
1352
|
+
function Lt(o) {
|
|
1353
1353
|
return o == null ? !0 : Array.isArray(o) ? o.length === 0 : o === "";
|
|
1354
1354
|
}
|
|
1355
|
-
function
|
|
1356
|
-
const e =
|
|
1357
|
-
let
|
|
1358
|
-
const
|
|
1355
|
+
function vo(o) {
|
|
1356
|
+
const e = pt(), { dateRange: t, selectedLocationIds: a, locations: r, timezone: m } = Oe(e), { country: h } = Oe(Ye()), y = T({}), I = T([]), b = T({}), L = gn({}), x = T(), N = T([]), E = [], W = [], j = { ids: "[]", date: "" };
|
|
1357
|
+
let Y = !1;
|
|
1358
|
+
const U = {}, O = {};
|
|
1359
1359
|
function G(u) {
|
|
1360
|
-
|
|
1360
|
+
E.push(u);
|
|
1361
1361
|
}
|
|
1362
1362
|
function J(u) {
|
|
1363
1363
|
W.push(u);
|
|
1364
1364
|
}
|
|
1365
|
-
function
|
|
1366
|
-
L.value = { ...L.value, [u.queryId]: u },
|
|
1365
|
+
function F(u) {
|
|
1366
|
+
L.value = { ...L.value, [u.queryId]: u }, E.forEach((S) => S(u));
|
|
1367
1367
|
}
|
|
1368
1368
|
function B(u) {
|
|
1369
|
-
const
|
|
1369
|
+
const S = {};
|
|
1370
1370
|
for (const M of u.params)
|
|
1371
|
-
|
|
1372
|
-
|
|
1371
|
+
S[M.name] = M.default ?? null;
|
|
1372
|
+
S["@from"] = t.value.startDate ?? null, S["@to"] = t.value.endDate ?? null, S["@timezone"] = m.value, S["@locationIds"] = [...a.value], y.value = S, b.value = {}, g();
|
|
1373
1373
|
}
|
|
1374
|
-
function
|
|
1374
|
+
function _() {
|
|
1375
1375
|
return r.value.map((u) => u.id);
|
|
1376
1376
|
}
|
|
1377
1377
|
function z() {
|
|
1378
1378
|
return { startDate: t.value.startDate, endDate: t.value.endDate };
|
|
1379
1379
|
}
|
|
1380
|
-
function
|
|
1381
|
-
|
|
1380
|
+
function g() {
|
|
1381
|
+
j.ids = JSON.stringify([...a.value]), j.date = JSON.stringify(z());
|
|
1382
1382
|
}
|
|
1383
|
-
function
|
|
1384
|
-
const u =
|
|
1385
|
-
if (typeof u == "string" || typeof
|
|
1383
|
+
function H() {
|
|
1384
|
+
const u = y.value["@from"], S = y.value["@to"];
|
|
1385
|
+
if (typeof u == "string" || typeof S == "string") {
|
|
1386
1386
|
const d = {
|
|
1387
1387
|
startDate: typeof u == "string" ? u : void 0,
|
|
1388
|
-
endDate: typeof
|
|
1388
|
+
endDate: typeof S == "string" ? S : void 0
|
|
1389
1389
|
};
|
|
1390
1390
|
JSON.stringify(d) !== JSON.stringify(z()) && (t.value = d);
|
|
1391
1391
|
}
|
|
1392
|
-
const M =
|
|
1392
|
+
const M = y.value["@locationIds"];
|
|
1393
1393
|
if (Array.isArray(M)) {
|
|
1394
1394
|
const d = M.map(String);
|
|
1395
1395
|
JSON.stringify(d) !== JSON.stringify(a.value) && (a.value = d);
|
|
1396
1396
|
}
|
|
1397
|
-
|
|
1397
|
+
g();
|
|
1398
1398
|
}
|
|
1399
|
-
function
|
|
1400
|
-
const u = [...a.value],
|
|
1401
|
-
JSON.stringify(z()) !==
|
|
1399
|
+
function K() {
|
|
1400
|
+
const u = [...a.value], S = {}, M = { ...b.value };
|
|
1401
|
+
JSON.stringify(z()) !== j.date && (S["@from"] = t.value.startDate ?? null, S["@to"] = t.value.endDate ?? null), JSON.stringify(u) !== j.ids ? (S["@locationIds"] = u, delete M["@locationIds"]) : M["@locationIds"] === "all" && (S["@locationIds"] = _()), Object.keys(S).length && te(S, M);
|
|
1402
1402
|
}
|
|
1403
|
-
function
|
|
1404
|
-
|
|
1405
|
-
|
|
1403
|
+
function ee() {
|
|
1404
|
+
de([t, a, r], () => {
|
|
1405
|
+
Y && K();
|
|
1406
1406
|
});
|
|
1407
1407
|
}
|
|
1408
|
-
function
|
|
1409
|
-
return { values:
|
|
1408
|
+
function X() {
|
|
1409
|
+
return { values: y.value, decls: I.value, intent: b.value };
|
|
1410
1410
|
}
|
|
1411
|
-
function
|
|
1411
|
+
function se() {
|
|
1412
1412
|
return {
|
|
1413
1413
|
locations: r.value.map((u) => ({
|
|
1414
1414
|
id: u.id,
|
|
@@ -1418,26 +1418,26 @@ function ho(o) {
|
|
|
1418
1418
|
timezone: m.value,
|
|
1419
1419
|
// The portal's locale, not the browser's: the frame sets documentElement.lang from this,
|
|
1420
1420
|
// and Rebus switches its line-height metrics on :lang(zh) / :lang(th).
|
|
1421
|
-
locale:
|
|
1422
|
-
currency:
|
|
1421
|
+
locale: An() || "en-US",
|
|
1422
|
+
currency: go[(h.value || "").toUpperCase()] ?? ""
|
|
1423
1423
|
};
|
|
1424
1424
|
}
|
|
1425
|
-
function
|
|
1426
|
-
return JSON.stringify(u.dependsOn.map((M) =>
|
|
1425
|
+
function ce(u, S) {
|
|
1426
|
+
return JSON.stringify(u.dependsOn.map((M) => S[M] ?? null));
|
|
1427
1427
|
}
|
|
1428
|
-
function
|
|
1428
|
+
function ye(u, S) {
|
|
1429
1429
|
return u.lazy ? u.dependsOn.some((M) => {
|
|
1430
1430
|
const d = I.value.find((n) => n.name === M);
|
|
1431
|
-
return ((d == null ? void 0 : d.default) ?? null) === null &&
|
|
1431
|
+
return ((d == null ? void 0 : d.default) ?? null) === null && Lt(S[M] ?? null);
|
|
1432
1432
|
}) : !1;
|
|
1433
1433
|
}
|
|
1434
|
-
function
|
|
1435
|
-
return !
|
|
1434
|
+
function he(u) {
|
|
1435
|
+
return !lt.some((S) => S in u && Lt(u[S] ?? null));
|
|
1436
1436
|
}
|
|
1437
|
-
async function
|
|
1437
|
+
async function le(u, S) {
|
|
1438
1438
|
var d;
|
|
1439
|
-
const M = (
|
|
1440
|
-
|
|
1439
|
+
const M = (U[u.id] ?? 0) + 1;
|
|
1440
|
+
U[u.id] = M, F({
|
|
1441
1441
|
queryId: u.id,
|
|
1442
1442
|
runId: M,
|
|
1443
1443
|
status: "loading",
|
|
@@ -1446,15 +1446,15 @@ function ho(o) {
|
|
|
1446
1446
|
});
|
|
1447
1447
|
for (let n = 0; ; n++)
|
|
1448
1448
|
try {
|
|
1449
|
-
const i = await
|
|
1449
|
+
const i = await gr(
|
|
1450
1450
|
o,
|
|
1451
1451
|
u.id,
|
|
1452
|
-
|
|
1452
|
+
S,
|
|
1453
1453
|
m.value,
|
|
1454
|
-
|
|
1454
|
+
x.value
|
|
1455
1455
|
);
|
|
1456
|
-
if (
|
|
1457
|
-
|
|
1456
|
+
if (U[u.id] !== M) return;
|
|
1457
|
+
F({
|
|
1458
1458
|
queryId: u.id,
|
|
1459
1459
|
runId: M,
|
|
1460
1460
|
status: "ok",
|
|
@@ -1463,13 +1463,13 @@ function ho(o) {
|
|
|
1463
1463
|
});
|
|
1464
1464
|
return;
|
|
1465
1465
|
} catch (i) {
|
|
1466
|
-
if (
|
|
1467
|
-
const f =
|
|
1468
|
-
if (f !== void 0 && n <
|
|
1469
|
-
if (await new Promise((
|
|
1466
|
+
if (U[u.id] !== M) return;
|
|
1467
|
+
const f = bo(i);
|
|
1468
|
+
if (f !== void 0 && n < po) {
|
|
1469
|
+
if (await new Promise((A) => setTimeout(A, f)), U[u.id] !== M) return;
|
|
1470
1470
|
continue;
|
|
1471
1471
|
}
|
|
1472
|
-
|
|
1472
|
+
F({
|
|
1473
1473
|
queryId: u.id,
|
|
1474
1474
|
runId: M,
|
|
1475
1475
|
status: "error",
|
|
@@ -1480,90 +1480,90 @@ function ho(o) {
|
|
|
1480
1480
|
return;
|
|
1481
1481
|
}
|
|
1482
1482
|
}
|
|
1483
|
-
function
|
|
1483
|
+
function oe(u = {}) {
|
|
1484
1484
|
var d, n, i;
|
|
1485
|
-
const
|
|
1485
|
+
const S = { ...y.value }, M = !he(S);
|
|
1486
1486
|
for (const f of N.value) {
|
|
1487
|
-
const
|
|
1488
|
-
if (
|
|
1489
|
-
delete
|
|
1487
|
+
const A = M && f.dependsOn.some(($) => lt.includes($));
|
|
1488
|
+
if (ye(f, S)) {
|
|
1489
|
+
delete O[f.id], ((d = L.value[f.id]) == null ? void 0 : d.status) !== "idle" && F({
|
|
1490
1490
|
queryId: f.id,
|
|
1491
|
-
runId:
|
|
1491
|
+
runId: U[f.id] ?? 0,
|
|
1492
1492
|
status: "idle",
|
|
1493
1493
|
rows: [],
|
|
1494
1494
|
truncated: !1
|
|
1495
1495
|
});
|
|
1496
1496
|
continue;
|
|
1497
1497
|
}
|
|
1498
|
-
if (
|
|
1499
|
-
((n = L.value[f.id]) == null ? void 0 : n.status) !== "loading" &&
|
|
1498
|
+
if (A) {
|
|
1499
|
+
((n = L.value[f.id]) == null ? void 0 : n.status) !== "loading" && F({
|
|
1500
1500
|
queryId: f.id,
|
|
1501
|
-
runId:
|
|
1501
|
+
runId: U[f.id] ?? 0,
|
|
1502
1502
|
status: "loading",
|
|
1503
1503
|
rows: ((i = L.value[f.id]) == null ? void 0 : i.rows) ?? [],
|
|
1504
1504
|
truncated: !1
|
|
1505
1505
|
});
|
|
1506
1506
|
continue;
|
|
1507
1507
|
}
|
|
1508
|
-
const
|
|
1509
|
-
!u.force &&
|
|
1508
|
+
const P = ce(f, S);
|
|
1509
|
+
!u.force && O[f.id] === P || (O[f.id] = P, le(f, S));
|
|
1510
1510
|
}
|
|
1511
1511
|
}
|
|
1512
|
-
function
|
|
1513
|
-
const M = { ...
|
|
1512
|
+
function te(u, S) {
|
|
1513
|
+
const M = { ...y.value }, d = { ...b.value };
|
|
1514
1514
|
let n = !1;
|
|
1515
1515
|
for (const [i, f] of Object.entries(u)) {
|
|
1516
|
-
if (!(i in M) ||
|
|
1517
|
-
const
|
|
1518
|
-
d[i] !==
|
|
1516
|
+
if (!(i in M) || mo.includes(i)) continue;
|
|
1517
|
+
const A = uo.includes(i) ? S == null ? void 0 : S[i] : void 0;
|
|
1518
|
+
d[i] !== A && (A ? d[i] = A : delete d[i], n = !0), JSON.stringify(M[i] ?? null) !== JSON.stringify(f ?? null) && (M[i] = f, n = !0);
|
|
1519
1519
|
}
|
|
1520
|
-
return n ? (
|
|
1520
|
+
return n ? (y.value = M, b.value = d, Object.keys(u).some((i) => lt.includes(i)) && H(), oe(), W.forEach((i) => i()), !0) : !1;
|
|
1521
1521
|
}
|
|
1522
|
-
function
|
|
1523
|
-
|
|
1524
|
-
for (const
|
|
1525
|
-
for (const
|
|
1526
|
-
B(u),
|
|
1522
|
+
function xe(u) {
|
|
1523
|
+
x.value = u.state, N.value = u.queries, I.value = u.params, L.value = {};
|
|
1524
|
+
for (const S of Object.keys(U)) delete U[S];
|
|
1525
|
+
for (const S of Object.keys(O)) delete O[S];
|
|
1526
|
+
B(u), Y = !0, oe();
|
|
1527
1527
|
}
|
|
1528
|
-
function
|
|
1529
|
-
|
|
1530
|
-
const M = JSON.stringify(
|
|
1528
|
+
function C(u, S = []) {
|
|
1529
|
+
x.value = u.state, N.value = u.queries, I.value = u.params;
|
|
1530
|
+
const M = JSON.stringify(y.value), d = {};
|
|
1531
1531
|
for (const f of u.params)
|
|
1532
|
-
d[f.name] = f.name in
|
|
1533
|
-
|
|
1532
|
+
d[f.name] = f.name in y.value ? y.value[f.name] : f.default ?? null;
|
|
1533
|
+
y.value = d;
|
|
1534
1534
|
const n = new Set(u.queries.map((f) => f.id));
|
|
1535
|
-
for (const f of Object.keys(
|
|
1536
|
-
for (const f of Object.keys(
|
|
1535
|
+
for (const f of Object.keys(U)) n.has(f) || delete U[f];
|
|
1536
|
+
for (const f of Object.keys(O)) n.has(f) || delete O[f];
|
|
1537
1537
|
const i = Object.keys(L.value).filter((f) => !n.has(f));
|
|
1538
1538
|
if (i.length) {
|
|
1539
1539
|
const f = { ...L.value };
|
|
1540
|
-
for (const
|
|
1540
|
+
for (const A of i) delete f[A];
|
|
1541
1541
|
L.value = f;
|
|
1542
1542
|
}
|
|
1543
|
-
for (const f of
|
|
1544
|
-
return
|
|
1543
|
+
for (const f of S) delete O[f];
|
|
1544
|
+
return oe(), JSON.stringify(y.value) !== M;
|
|
1545
1545
|
}
|
|
1546
1546
|
return {
|
|
1547
|
-
params:
|
|
1548
|
-
intent:
|
|
1547
|
+
params: y,
|
|
1548
|
+
intent: b,
|
|
1549
1549
|
results: L,
|
|
1550
1550
|
queries: N,
|
|
1551
|
-
state:
|
|
1552
|
-
paramState:
|
|
1553
|
-
env:
|
|
1554
|
-
load:
|
|
1555
|
-
bindStore:
|
|
1556
|
-
applyCanvas:
|
|
1557
|
-
run:
|
|
1558
|
-
setParams:
|
|
1551
|
+
state: x,
|
|
1552
|
+
paramState: X,
|
|
1553
|
+
env: se,
|
|
1554
|
+
load: xe,
|
|
1555
|
+
bindStore: ee,
|
|
1556
|
+
applyCanvas: C,
|
|
1557
|
+
run: oe,
|
|
1558
|
+
setParams: te,
|
|
1559
1559
|
onResult: G,
|
|
1560
1560
|
onParamsChanged: J,
|
|
1561
|
-
RESERVED:
|
|
1561
|
+
RESERVED: co
|
|
1562
1562
|
};
|
|
1563
1563
|
}
|
|
1564
|
-
const bo = `: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}
|
|
1564
|
+
const yo = `: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}
|
|
1565
1565
|
/*$vite$:1*/`;
|
|
1566
|
-
function
|
|
1566
|
+
function xo(o) {
|
|
1567
1567
|
const e = o.replace(/^\//, "");
|
|
1568
1568
|
try {
|
|
1569
1569
|
const t = new URL(import.meta.url);
|
|
@@ -1573,47 +1573,47 @@ function go(o) {
|
|
|
1573
1573
|
}
|
|
1574
1574
|
return `${"/".replace(/\/$/, "")}/${e}`;
|
|
1575
1575
|
}
|
|
1576
|
-
const
|
|
1576
|
+
const qt = {
|
|
1577
1577
|
"chart.js@4": "chart.js-4.js",
|
|
1578
1578
|
"fm-ui@1": "fm-ui-1.js",
|
|
1579
1579
|
"components@1": "components-1.js"
|
|
1580
|
-
},
|
|
1581
|
-
function
|
|
1582
|
-
return
|
|
1580
|
+
}, ft = /* @__PURE__ */ new Map();
|
|
1581
|
+
function wo(o) {
|
|
1582
|
+
return xo(`report-canvas-libs/${qt[o]}`);
|
|
1583
1583
|
}
|
|
1584
|
-
async function
|
|
1585
|
-
const e = [...new Set(o)].filter((a) =>
|
|
1584
|
+
async function Mt(o) {
|
|
1585
|
+
const e = [...new Set(o)].filter((a) => qt[a]), t = {};
|
|
1586
1586
|
return await Promise.all(
|
|
1587
1587
|
e.map(async (a) => {
|
|
1588
|
-
if (!
|
|
1589
|
-
const m = await fetch(
|
|
1588
|
+
if (!ft.has(a)) {
|
|
1589
|
+
const m = await fetch(wo(a));
|
|
1590
1590
|
if (!m.ok) return;
|
|
1591
|
-
|
|
1591
|
+
ft.set(a, await m.text());
|
|
1592
1592
|
}
|
|
1593
|
-
const r =
|
|
1593
|
+
const r = ft.get(a);
|
|
1594
1594
|
r && (t[a] = r);
|
|
1595
1595
|
})
|
|
1596
1596
|
), t;
|
|
1597
1597
|
}
|
|
1598
|
-
const
|
|
1599
|
-
function
|
|
1598
|
+
const Ut = /url\(\s*(['"]?)\s*([^)'"]*?)\s*\1\s*\)/gi, ko = /@font-face\s*\{[^}]*\}/gi;
|
|
1599
|
+
function Ht(o) {
|
|
1600
1600
|
return /^(data:|blob:|#)/i.test(o);
|
|
1601
1601
|
}
|
|
1602
|
-
function
|
|
1603
|
-
for (const e of o.matchAll(
|
|
1604
|
-
if (!
|
|
1602
|
+
function _o(o) {
|
|
1603
|
+
for (const e of o.matchAll(Ut))
|
|
1604
|
+
if (!Ht(e[2])) return !0;
|
|
1605
1605
|
return !1;
|
|
1606
1606
|
}
|
|
1607
|
-
function
|
|
1607
|
+
function So(o) {
|
|
1608
1608
|
var t;
|
|
1609
1609
|
return `@font-face ${((t = /font-family\s*:\s*([^;}]+)/i.exec(o)) == null ? void 0 : t[1].trim()) || "(unnamed)"}`;
|
|
1610
1610
|
}
|
|
1611
|
-
function
|
|
1611
|
+
function Io(o) {
|
|
1612
1612
|
const e = [];
|
|
1613
|
-
let t = o.replace(
|
|
1614
|
-
return t = t.replace(
|
|
1613
|
+
let t = o.replace(ko, (a) => _o(a) ? (e.push(So(a)), "") : a);
|
|
1614
|
+
return t = t.replace(Ut, (a, r, m) => Ht(m) ? a : (e.push(`url(${m})`), "url(about:invalid)")), { css: t, stripped: e };
|
|
1615
1615
|
}
|
|
1616
|
-
const
|
|
1616
|
+
const Wt = `<meta charset="utf-8" />
|
|
1617
1617
|
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
1618
1618
|
<!--
|
|
1619
1619
|
Runtime shell for AI-written report sections. Loaded into ONE iframe per report with
|
|
@@ -3989,16 +3989,16 @@ const Ht = `<meta charset="utf-8" />
|
|
|
3989
3989
|
post({ type: "ready", nonce: NONCE })
|
|
3990
3990
|
})()
|
|
3991
3991
|
<\/script>
|
|
3992
|
-
`,
|
|
3993
|
-
if (!
|
|
3992
|
+
`, Gt = "/* __FM_UI_LIBRARY_V2_STYLES__ */";
|
|
3993
|
+
if (!Wt.includes(Gt))
|
|
3994
3994
|
throw new Error("report canvas frame is missing the UI library style placeholder");
|
|
3995
|
-
const
|
|
3996
|
-
|
|
3995
|
+
const Co = Io(yo).css, Ao = Wt.replace(
|
|
3996
|
+
Gt,
|
|
3997
3997
|
// A replacer function, not the string: a literal replacement would let `$&`, `$'` or `$1`
|
|
3998
3998
|
// inside the stylesheet rewrite themselves against the match.
|
|
3999
|
-
() =>
|
|
4000
|
-
),
|
|
4001
|
-
function
|
|
3999
|
+
() => Co
|
|
4000
|
+
), Pt = 8e3;
|
|
4001
|
+
function To(o) {
|
|
4002
4002
|
const e = o;
|
|
4003
4003
|
if (!e || typeof e != "object") return;
|
|
4004
4004
|
const t = (r) => Number.isSafeInteger(r) && r >= 0 && r <= 1e4;
|
|
@@ -4012,10 +4012,10 @@ function Io(o) {
|
|
|
4012
4012
|
...a === null || typeof a == "number" && Number.isFinite(a) ? { value: a } : typeof a == "string" ? { value: a.slice(0, 64) } : {}
|
|
4013
4013
|
};
|
|
4014
4014
|
}
|
|
4015
|
-
function
|
|
4015
|
+
function Dt(o) {
|
|
4016
4016
|
const e = o;
|
|
4017
4017
|
if (!e || typeof e != "object" || typeof e.tag != "string") return;
|
|
4018
|
-
const t = Array.isArray(e.path) ? e.path.filter((r) => Number.isSafeInteger(r) && r >= 0).slice(0, 32) : [], a =
|
|
4018
|
+
const t = Array.isArray(e.path) ? e.path.filter((r) => Number.isSafeInteger(r) && r >= 0).slice(0, 32) : [], a = To(e.datum);
|
|
4019
4019
|
return {
|
|
4020
4020
|
tag: e.tag.slice(0, 32),
|
|
4021
4021
|
...typeof e.part == "string" ? { part: e.part.slice(0, 128) } : {},
|
|
@@ -4025,173 +4025,173 @@ function Pt(o) {
|
|
|
4025
4025
|
...a ? { datum: a } : {}
|
|
4026
4026
|
};
|
|
4027
4027
|
}
|
|
4028
|
-
function
|
|
4029
|
-
const t =
|
|
4028
|
+
function Eo(o, e) {
|
|
4029
|
+
const t = T(!1);
|
|
4030
4030
|
let a = null;
|
|
4031
4031
|
const r = /* @__PURE__ */ new Map();
|
|
4032
4032
|
let m;
|
|
4033
|
-
const
|
|
4034
|
-
function
|
|
4035
|
-
var
|
|
4036
|
-
return ((
|
|
4033
|
+
const h = /* @__PURE__ */ new Map();
|
|
4034
|
+
function y() {
|
|
4035
|
+
var _;
|
|
4036
|
+
return ((_ = o.value) == null ? void 0 : _.contentWindow) ?? null;
|
|
4037
4037
|
}
|
|
4038
|
-
function I(
|
|
4038
|
+
function I(_) {
|
|
4039
4039
|
var z;
|
|
4040
|
-
(z =
|
|
4041
|
-
}
|
|
4042
|
-
function
|
|
4043
|
-
var
|
|
4044
|
-
const z =
|
|
4045
|
-
if (!z ||
|
|
4046
|
-
const
|
|
4047
|
-
if (!(!
|
|
4048
|
-
switch (
|
|
4040
|
+
(z = y()) == null || z.postMessage(JSON.parse(JSON.stringify(_)), "*");
|
|
4041
|
+
}
|
|
4042
|
+
function b(_) {
|
|
4043
|
+
var H, K;
|
|
4044
|
+
const z = y();
|
|
4045
|
+
if (!z || _.source !== z) return;
|
|
4046
|
+
const g = _.data;
|
|
4047
|
+
if (!(!g || typeof g != "object"))
|
|
4048
|
+
switch (g.type) {
|
|
4049
4049
|
case "ready":
|
|
4050
4050
|
if (t.value) return;
|
|
4051
|
-
m =
|
|
4051
|
+
m = g.nonce, t.value = !0, a == null || a(), a = null, G();
|
|
4052
4052
|
break;
|
|
4053
4053
|
case "sectionSelected":
|
|
4054
|
-
if (!m ||
|
|
4054
|
+
if (!m || g.nonce !== m || typeof g.sectionId != "string" || !Number.isSafeInteger(g.version))
|
|
4055
4055
|
return;
|
|
4056
|
-
const
|
|
4057
|
-
(
|
|
4056
|
+
const ee = Dt(g.element), X = Array.isArray(g.widen) ? g.widen.slice(0, 4).map(Dt).filter((se) => !!se) : [];
|
|
4057
|
+
(H = e.onSelectSection) == null || H.call(
|
|
4058
4058
|
e,
|
|
4059
4059
|
{
|
|
4060
|
-
sectionId:
|
|
4061
|
-
version:
|
|
4062
|
-
label: String(
|
|
4063
|
-
elementText: String(
|
|
4064
|
-
elementTag: String(
|
|
4065
|
-
...
|
|
4060
|
+
sectionId: g.sectionId,
|
|
4061
|
+
version: g.version,
|
|
4062
|
+
label: String(g.label ?? "").slice(0, 120),
|
|
4063
|
+
elementText: String(g.elementText ?? "").slice(0, 300),
|
|
4064
|
+
elementTag: String(g.elementTag ?? "").slice(0, 32),
|
|
4065
|
+
...ee ? { element: ee } : {}
|
|
4066
4066
|
},
|
|
4067
|
-
|
|
4067
|
+
X
|
|
4068
4068
|
);
|
|
4069
4069
|
break;
|
|
4070
4070
|
case "selectionCancelled":
|
|
4071
|
-
m &&
|
|
4071
|
+
m && g.nonce === m && ((K = e.onCancelSelection) == null || K.call(e));
|
|
4072
4072
|
break;
|
|
4073
4073
|
case "setParams":
|
|
4074
|
-
e.onSetParams(
|
|
4074
|
+
e.onSetParams(g.values ?? {}, g.intent);
|
|
4075
4075
|
break;
|
|
4076
4076
|
case "rendered":
|
|
4077
|
-
if (!L(
|
|
4078
|
-
N(
|
|
4079
|
-
|
|
4080
|
-
|
|
4081
|
-
String(
|
|
4077
|
+
if (!L(g)) return;
|
|
4078
|
+
N(g.sectionId, g.version), e.onSectionRendered(
|
|
4079
|
+
g.sectionId,
|
|
4080
|
+
g.version,
|
|
4081
|
+
String(g.label ?? "").slice(0, 120)
|
|
4082
4082
|
);
|
|
4083
4083
|
break;
|
|
4084
4084
|
case "error":
|
|
4085
|
-
if (!L(
|
|
4086
|
-
N(
|
|
4085
|
+
if (!L(g)) return;
|
|
4086
|
+
N(g.sectionId, g.version), e.onSectionError(g.sectionId, g.version, g.message);
|
|
4087
4087
|
break;
|
|
4088
4088
|
case "layout":
|
|
4089
|
-
if (!L(
|
|
4089
|
+
if (!L(g)) return;
|
|
4090
4090
|
e.onSectionLayout(
|
|
4091
|
-
|
|
4092
|
-
|
|
4093
|
-
(Array.isArray(
|
|
4091
|
+
g.sectionId,
|
|
4092
|
+
g.version,
|
|
4093
|
+
(Array.isArray(g.warnings) ? g.warnings : []).slice(0, 12).map((se) => String(se).slice(0, 200))
|
|
4094
4094
|
);
|
|
4095
4095
|
break;
|
|
4096
4096
|
}
|
|
4097
4097
|
}
|
|
4098
|
-
function L(
|
|
4099
|
-
return !m ||
|
|
4098
|
+
function L(_) {
|
|
4099
|
+
return !m || _.nonce === m ? !0 : (console.warn("[report-canvas] dropped a render outcome without the shell nonce"), !1);
|
|
4100
4100
|
}
|
|
4101
|
-
function
|
|
4102
|
-
return `${
|
|
4101
|
+
function x(_, z) {
|
|
4102
|
+
return `${_}@${z}`;
|
|
4103
4103
|
}
|
|
4104
|
-
function N(
|
|
4104
|
+
function N(_, z) {
|
|
4105
4105
|
if (z === void 0) return;
|
|
4106
|
-
const
|
|
4107
|
-
|
|
4106
|
+
const g = x(_, z), H = h.get(g);
|
|
4107
|
+
H !== void 0 && (clearTimeout(H), h.delete(g));
|
|
4108
4108
|
}
|
|
4109
|
-
function
|
|
4110
|
-
|
|
4109
|
+
function E() {
|
|
4110
|
+
h.forEach((_) => clearTimeout(_)), h.clear();
|
|
4111
4111
|
}
|
|
4112
|
-
function W(
|
|
4113
|
-
for (const z of
|
|
4114
|
-
const
|
|
4115
|
-
|
|
4116
|
-
|
|
4112
|
+
function W(_) {
|
|
4113
|
+
for (const z of _) {
|
|
4114
|
+
const g = x(z.id, z.version);
|
|
4115
|
+
h.has(g) || h.set(
|
|
4116
|
+
g,
|
|
4117
4117
|
setTimeout(() => {
|
|
4118
|
-
|
|
4118
|
+
h.delete(g), e.onSectionError(
|
|
4119
4119
|
z.id,
|
|
4120
4120
|
z.version,
|
|
4121
|
-
`the section did not report a render within ${
|
|
4121
|
+
`the section did not report a render within ${Pt}ms`
|
|
4122
4122
|
);
|
|
4123
|
-
},
|
|
4123
|
+
}, Pt)
|
|
4124
4124
|
);
|
|
4125
4125
|
}
|
|
4126
4126
|
}
|
|
4127
|
-
async function
|
|
4128
|
-
const
|
|
4127
|
+
async function j(_, z, g) {
|
|
4128
|
+
const H = await Mt(_.flatMap((ee) => ee.libs ?? [])), K = () => {
|
|
4129
4129
|
I({
|
|
4130
4130
|
type: "init",
|
|
4131
|
-
sections:
|
|
4131
|
+
sections: _,
|
|
4132
4132
|
params: z.values,
|
|
4133
4133
|
paramDecls: z.decls,
|
|
4134
4134
|
intent: z.intent,
|
|
4135
|
-
libs:
|
|
4136
|
-
env:
|
|
4137
|
-
}),
|
|
4135
|
+
libs: H,
|
|
4136
|
+
env: g
|
|
4137
|
+
}), E(), W(_);
|
|
4138
4138
|
};
|
|
4139
|
-
t.value ?
|
|
4139
|
+
t.value ? K() : a = K;
|
|
4140
4140
|
}
|
|
4141
|
-
async function
|
|
4142
|
-
const z = await
|
|
4143
|
-
I({ type: "sections", sections:
|
|
4141
|
+
async function Y(_) {
|
|
4142
|
+
const z = await Mt(_.flatMap((g) => g.libs ?? []));
|
|
4143
|
+
I({ type: "sections", sections: _, libs: z }), W(_);
|
|
4144
4144
|
}
|
|
4145
|
-
function
|
|
4145
|
+
function U(_) {
|
|
4146
4146
|
I({
|
|
4147
4147
|
type: "params",
|
|
4148
|
-
values:
|
|
4149
|
-
paramDecls:
|
|
4150
|
-
intent:
|
|
4148
|
+
values: _.values,
|
|
4149
|
+
paramDecls: _.decls,
|
|
4150
|
+
intent: _.intent
|
|
4151
4151
|
});
|
|
4152
4152
|
}
|
|
4153
|
-
function
|
|
4154
|
-
I({ type: "env", env:
|
|
4153
|
+
function O(_) {
|
|
4154
|
+
I({ type: "env", env: _ });
|
|
4155
4155
|
}
|
|
4156
4156
|
function G() {
|
|
4157
|
-
const
|
|
4158
|
-
r.clear(),
|
|
4157
|
+
const _ = [...r.values()];
|
|
4158
|
+
r.clear(), _.forEach(J);
|
|
4159
4159
|
}
|
|
4160
|
-
function J(
|
|
4160
|
+
function J(_) {
|
|
4161
4161
|
I({
|
|
4162
4162
|
type: "rows",
|
|
4163
|
-
queryId:
|
|
4164
|
-
runId:
|
|
4165
|
-
rows:
|
|
4166
|
-
status:
|
|
4167
|
-
truncated:
|
|
4168
|
-
error:
|
|
4163
|
+
queryId: _.queryId,
|
|
4164
|
+
runId: _.runId,
|
|
4165
|
+
rows: _.rows,
|
|
4166
|
+
status: _.status,
|
|
4167
|
+
truncated: _.truncated,
|
|
4168
|
+
error: _.error
|
|
4169
4169
|
});
|
|
4170
4170
|
}
|
|
4171
|
-
function
|
|
4171
|
+
function F(_) {
|
|
4172
4172
|
if (!t.value) {
|
|
4173
|
-
r.set(
|
|
4173
|
+
r.set(_.queryId, _);
|
|
4174
4174
|
return;
|
|
4175
4175
|
}
|
|
4176
|
-
J(
|
|
4176
|
+
J(_);
|
|
4177
4177
|
}
|
|
4178
|
-
|
|
4179
|
-
window.removeEventListener("message",
|
|
4178
|
+
Me(() => window.addEventListener("message", b)), De(() => {
|
|
4179
|
+
window.removeEventListener("message", b), E();
|
|
4180
4180
|
});
|
|
4181
4181
|
function B() {
|
|
4182
|
-
t.value = !1, a = null, m = void 0, r.clear(),
|
|
4182
|
+
t.value = !1, a = null, m = void 0, r.clear(), E();
|
|
4183
4183
|
}
|
|
4184
4184
|
return {
|
|
4185
|
-
setCommentMode: (
|
|
4186
|
-
var
|
|
4185
|
+
setCommentMode: (_, z) => {
|
|
4186
|
+
var g, H, K;
|
|
4187
4187
|
return I({
|
|
4188
4188
|
type: "commentMode",
|
|
4189
|
-
enabled:
|
|
4189
|
+
enabled: _,
|
|
4190
4190
|
selected: z ? {
|
|
4191
4191
|
sectionId: z.sectionId,
|
|
4192
|
-
part: (
|
|
4193
|
-
path: ((
|
|
4194
|
-
datum: ((
|
|
4192
|
+
part: (g = z.element) == null ? void 0 : g.part,
|
|
4193
|
+
path: ((H = z.element) == null ? void 0 : H.path) ?? [],
|
|
4194
|
+
datum: ((K = z.element) == null ? void 0 : K.datum) && {
|
|
4195
4195
|
datasetIndex: z.element.datum.datasetIndex,
|
|
4196
4196
|
index: z.element.datum.index
|
|
4197
4197
|
}
|
|
@@ -4199,277 +4199,277 @@ function Co(o, e) {
|
|
|
4199
4199
|
});
|
|
4200
4200
|
},
|
|
4201
4201
|
ready: t,
|
|
4202
|
-
init:
|
|
4203
|
-
swapSections:
|
|
4204
|
-
pushParams:
|
|
4205
|
-
pushEnv:
|
|
4206
|
-
pushRows:
|
|
4202
|
+
init: j,
|
|
4203
|
+
swapSections: Y,
|
|
4204
|
+
pushParams: U,
|
|
4205
|
+
pushEnv: O,
|
|
4206
|
+
pushRows: F,
|
|
4207
4207
|
reset: B
|
|
4208
4208
|
};
|
|
4209
4209
|
}
|
|
4210
|
-
function
|
|
4211
|
-
const { businessId: e } =
|
|
4210
|
+
function He(o) {
|
|
4211
|
+
const { businessId: e } = Oe(Ye());
|
|
4212
4212
|
if (!e.value) throw new Error("Business Id is not defined");
|
|
4213
4213
|
return `/${e.value}/report-ai/${o}`;
|
|
4214
4214
|
}
|
|
4215
|
-
const
|
|
4215
|
+
const dt = (o, e = {}) => {
|
|
4216
4216
|
const t = new URLSearchParams();
|
|
4217
4217
|
e.sessionId && t.set("sessionId", e.sessionId), e.before && t.set("before", e.before);
|
|
4218
4218
|
const a = t.toString(), r = {
|
|
4219
|
-
fetchType:
|
|
4220
|
-
url: `${
|
|
4219
|
+
fetchType: pe.Get,
|
|
4220
|
+
url: `${He(o)}/chat${a ? `?${a}` : ""}`
|
|
4221
4221
|
};
|
|
4222
|
-
return
|
|
4223
|
-
},
|
|
4222
|
+
return ue.fetch(r);
|
|
4223
|
+
}, Oo = (o, e) => {
|
|
4224
4224
|
const t = {
|
|
4225
|
-
fetchType:
|
|
4226
|
-
url: `${
|
|
4225
|
+
fetchType: pe.Get,
|
|
4226
|
+
url: `${He(o)}/chats${e ? `?cursor=${encodeURIComponent(e)}` : ""}`
|
|
4227
4227
|
};
|
|
4228
|
-
return
|
|
4229
|
-
},
|
|
4228
|
+
return ue.fetch(t);
|
|
4229
|
+
}, zo = (o) => {
|
|
4230
4230
|
const e = {
|
|
4231
|
-
fetchType:
|
|
4232
|
-
url: `${
|
|
4231
|
+
fetchType: pe.Post,
|
|
4232
|
+
url: `${He(o)}/chats`,
|
|
4233
4233
|
data: {}
|
|
4234
4234
|
};
|
|
4235
|
-
return
|
|
4236
|
-
},
|
|
4235
|
+
return ue.fetch(e);
|
|
4236
|
+
}, No = (o, e) => {
|
|
4237
4237
|
const t = {
|
|
4238
|
-
fetchType:
|
|
4239
|
-
url: `${
|
|
4238
|
+
fetchType: pe.Get,
|
|
4239
|
+
url: `${He(o)}/runs/latest${e ? `?sessionId=${e}` : ""}`
|
|
4240
4240
|
};
|
|
4241
|
-
return
|
|
4242
|
-
},
|
|
4241
|
+
return ue.fetch(t);
|
|
4242
|
+
}, $o = (o, e, t, a) => {
|
|
4243
4243
|
const r = {
|
|
4244
|
-
fetchType:
|
|
4245
|
-
url: `${
|
|
4244
|
+
fetchType: pe.Post,
|
|
4245
|
+
url: `${He(o)}/runs/${e}/sections/${t}/retry`,
|
|
4246
4246
|
data: { timezone: a }
|
|
4247
4247
|
};
|
|
4248
|
-
return
|
|
4249
|
-
},
|
|
4250
|
-
function
|
|
4248
|
+
return ue.fetch(r);
|
|
4249
|
+
}, Ro = (o, e) => `/${o}/report-ai/${e}/chat`, Lo = 3e4, Mo = "New chat", jt = 80;
|
|
4250
|
+
function ct(o, e) {
|
|
4251
4251
|
return `report-canvas:chat:${o}:${e}`;
|
|
4252
4252
|
}
|
|
4253
|
-
function
|
|
4253
|
+
function Po(o) {
|
|
4254
4254
|
try {
|
|
4255
4255
|
return window.localStorage.getItem(o) ?? void 0;
|
|
4256
4256
|
} catch {
|
|
4257
4257
|
return;
|
|
4258
4258
|
}
|
|
4259
4259
|
}
|
|
4260
|
-
function
|
|
4260
|
+
function mt(o, e) {
|
|
4261
4261
|
try {
|
|
4262
4262
|
e ? window.localStorage.setItem(o, e) : window.localStorage.removeItem(o);
|
|
4263
4263
|
} catch {
|
|
4264
4264
|
}
|
|
4265
4265
|
}
|
|
4266
|
-
function
|
|
4267
|
-
const { businessId: e, token: t } =
|
|
4268
|
-
function
|
|
4266
|
+
function Do(o) {
|
|
4267
|
+
const { businessId: e, token: t } = Oe(Ye()), a = T([]), r = T(), m = T(""), h = T(null), y = T(!1), I = T([]), b = T(null), L = T(!1), x = T(""), N = T(!1), E = T(!1), W = T(""), j = T(""), Y = T(""), U = T(!1), O = T([]), G = T(!1), J = [];
|
|
4268
|
+
function F(d) {
|
|
4269
4269
|
J.push(d);
|
|
4270
4270
|
}
|
|
4271
4271
|
const B = [];
|
|
4272
|
-
function
|
|
4272
|
+
function _(d) {
|
|
4273
4273
|
B.push(d);
|
|
4274
4274
|
}
|
|
4275
4275
|
let z = 0;
|
|
4276
|
-
async function
|
|
4277
|
-
const n =
|
|
4276
|
+
async function g(d) {
|
|
4277
|
+
const n = ct(s(e.value), o), i = d ?? Po(n), f = z += 1;
|
|
4278
4278
|
N.value = !0;
|
|
4279
4279
|
try {
|
|
4280
|
-
let
|
|
4280
|
+
let A;
|
|
4281
4281
|
try {
|
|
4282
|
-
|
|
4283
|
-
} catch (
|
|
4284
|
-
if (!i) throw
|
|
4285
|
-
|
|
4282
|
+
A = await dt(o, { sessionId: i });
|
|
4283
|
+
} catch (P) {
|
|
4284
|
+
if (!i) throw P;
|
|
4285
|
+
mt(n, void 0), A = await dt(o);
|
|
4286
4286
|
}
|
|
4287
|
-
return f !== z ? null : (
|
|
4288
|
-
} catch (
|
|
4289
|
-
return f === z && (
|
|
4287
|
+
return f !== z ? null : (H(A), A.latestRun ?? null);
|
|
4288
|
+
} catch (A) {
|
|
4289
|
+
return f === z && (Y.value = A instanceof Error ? A.message : String(A)), null;
|
|
4290
4290
|
} finally {
|
|
4291
4291
|
f === z && (N.value = !1);
|
|
4292
4292
|
}
|
|
4293
4293
|
}
|
|
4294
|
-
function
|
|
4295
|
-
r.value = d.sessionId ?? void 0, m.value = d.title ?? "", a.value = d.messages,
|
|
4294
|
+
function H(d) {
|
|
4295
|
+
r.value = d.sessionId ?? void 0, m.value = d.title ?? "", a.value = d.messages, h.value = d.earlier ?? null, O.value = [], Y.value = "", mt(ct(s(e.value), o), d.sessionId);
|
|
4296
4296
|
}
|
|
4297
|
-
async function
|
|
4298
|
-
return d === r.value ||
|
|
4297
|
+
async function K(d) {
|
|
4298
|
+
return d === r.value || E.value ? null : g(d);
|
|
4299
4299
|
}
|
|
4300
|
-
async function
|
|
4301
|
-
if (
|
|
4300
|
+
async function ee() {
|
|
4301
|
+
if (E.value) return !1;
|
|
4302
4302
|
const d = z += 1;
|
|
4303
4303
|
N.value = !0;
|
|
4304
4304
|
try {
|
|
4305
|
-
const { chat: n } = await
|
|
4306
|
-
return d !== z ? !1 : (
|
|
4305
|
+
const { chat: n } = await zo(o);
|
|
4306
|
+
return d !== z ? !1 : (H({ sessionId: n.id, title: n.title, earlier: null, messages: [], latestRun: null }), I.value = [n, ...I.value.filter((i) => i.id !== n.id)], !0);
|
|
4307
4307
|
} catch (n) {
|
|
4308
|
-
return d === z && (
|
|
4308
|
+
return d === z && (Y.value = n instanceof Error ? n.message : String(n)), !1;
|
|
4309
4309
|
} finally {
|
|
4310
4310
|
d === z && (N.value = !1);
|
|
4311
4311
|
}
|
|
4312
4312
|
}
|
|
4313
|
-
async function
|
|
4314
|
-
L.value = !0,
|
|
4313
|
+
async function X(d) {
|
|
4314
|
+
L.value = !0, x.value = "";
|
|
4315
4315
|
try {
|
|
4316
|
-
const n = await
|
|
4317
|
-
I.value = d ? [...I.value, ...n.chats] : n.chats,
|
|
4316
|
+
const n = await Oo(o, d);
|
|
4317
|
+
I.value = d ? [...I.value, ...n.chats] : n.chats, b.value = n.cursor;
|
|
4318
4318
|
} catch (n) {
|
|
4319
|
-
|
|
4319
|
+
x.value = n instanceof Error ? n.message : String(n);
|
|
4320
4320
|
} finally {
|
|
4321
4321
|
L.value = !1;
|
|
4322
4322
|
}
|
|
4323
4323
|
}
|
|
4324
|
-
async function
|
|
4325
|
-
if (!
|
|
4326
|
-
const d =
|
|
4327
|
-
|
|
4324
|
+
async function se() {
|
|
4325
|
+
if (!h.value || y.value) return;
|
|
4326
|
+
const d = h.value, n = r.value;
|
|
4327
|
+
y.value = !0;
|
|
4328
4328
|
try {
|
|
4329
|
-
const i = await
|
|
4329
|
+
const i = await dt(o, { sessionId: n, before: d });
|
|
4330
4330
|
if (n !== r.value) return;
|
|
4331
|
-
a.value = [...i.messages, ...a.value],
|
|
4331
|
+
a.value = [...i.messages, ...a.value], h.value = i.earlier ?? null;
|
|
4332
4332
|
} catch (i) {
|
|
4333
|
-
|
|
4333
|
+
Y.value = i instanceof Error ? i.message : String(i);
|
|
4334
4334
|
} finally {
|
|
4335
|
-
|
|
4335
|
+
y.value = !1;
|
|
4336
4336
|
}
|
|
4337
4337
|
}
|
|
4338
|
-
const
|
|
4339
|
-
function
|
|
4340
|
-
r.value &&
|
|
4338
|
+
const ce = /* @__PURE__ */ new Map();
|
|
4339
|
+
function ye(d, n) {
|
|
4340
|
+
r.value && ce.set(r.value, { text: d, target: n });
|
|
4341
4341
|
}
|
|
4342
|
-
function
|
|
4343
|
-
return r.value &&
|
|
4342
|
+
function he() {
|
|
4343
|
+
return r.value && ce.get(r.value) || { text: "" };
|
|
4344
4344
|
}
|
|
4345
|
-
function
|
|
4346
|
-
|
|
4345
|
+
function le(d) {
|
|
4346
|
+
O.value.includes(d) || (O.value = [...O.value, d]);
|
|
4347
4347
|
}
|
|
4348
|
-
function
|
|
4348
|
+
function oe(d) {
|
|
4349
4349
|
var i;
|
|
4350
4350
|
const n = a.value.find((f) => f.id === d);
|
|
4351
|
-
return !n || !
|
|
4351
|
+
return !n || !O.value.includes(d) ? null : (a.value = a.value.filter((f) => f.id !== d), O.value = O.value.filter((f) => f !== d), {
|
|
4352
4352
|
text: n.parts.filter((f) => f.type === "text").map((f) => String(f.text ?? "")).join(`
|
|
4353
4353
|
`),
|
|
4354
4354
|
target: (i = n.parts.find((f) => f.type === "data-edit-target")) == null ? void 0 : i.data
|
|
4355
4355
|
});
|
|
4356
4356
|
}
|
|
4357
|
-
function
|
|
4357
|
+
function te(d, n) {
|
|
4358
4358
|
const i = a.value[a.value.length - 1];
|
|
4359
4359
|
if (i && i.role === "assistant" && i.id === d) {
|
|
4360
|
-
const
|
|
4361
|
-
n(
|
|
4360
|
+
const A = [...i.parts];
|
|
4361
|
+
n(A), a.value = [...a.value.slice(0, -1), { ...i, parts: A }];
|
|
4362
4362
|
return;
|
|
4363
4363
|
}
|
|
4364
4364
|
const f = [];
|
|
4365
4365
|
n(f), a.value = [...a.value, { id: d, role: "assistant", parts: f }];
|
|
4366
4366
|
}
|
|
4367
|
-
function
|
|
4367
|
+
function xe(d, n, i) {
|
|
4368
4368
|
for (let f = d.length - 1; f >= 0; f -= 1) {
|
|
4369
|
-
const
|
|
4370
|
-
if (
|
|
4371
|
-
d[f] = { ...
|
|
4369
|
+
const A = d[f];
|
|
4370
|
+
if (A.type === "text" && A.id === n) {
|
|
4371
|
+
d[f] = { ...A, text: String(A.text ?? "") + i };
|
|
4372
4372
|
return;
|
|
4373
4373
|
}
|
|
4374
4374
|
}
|
|
4375
4375
|
d.push({ type: "text", id: n, text: i, state: "streaming" });
|
|
4376
4376
|
}
|
|
4377
|
-
function
|
|
4377
|
+
function C(d, n, i) {
|
|
4378
4378
|
for (let f = d.length - 1; f >= 0; f -= 1) {
|
|
4379
|
-
const
|
|
4380
|
-
if (
|
|
4381
|
-
return d[f] = { ...
|
|
4379
|
+
const A = d[f];
|
|
4380
|
+
if (A.type.startsWith("tool-") && A.toolCallId === n)
|
|
4381
|
+
return d[f] = { ...A, ...i }, !0;
|
|
4382
4382
|
}
|
|
4383
4383
|
return !1;
|
|
4384
4384
|
}
|
|
4385
4385
|
function u(d, n) {
|
|
4386
4386
|
const i = String(d.type ?? ""), f = n.id;
|
|
4387
4387
|
if (i === "start-step") {
|
|
4388
|
-
|
|
4388
|
+
te(f, (A) => A.push({ type: "step-start" }));
|
|
4389
4389
|
return;
|
|
4390
4390
|
}
|
|
4391
4391
|
if (i === "text-start") {
|
|
4392
|
-
const
|
|
4393
|
-
|
|
4392
|
+
const A = String(d.id ?? "text");
|
|
4393
|
+
te(
|
|
4394
4394
|
f,
|
|
4395
|
-
(
|
|
4395
|
+
(P) => P.push({ type: "text", id: A, text: "", state: "streaming" })
|
|
4396
4396
|
);
|
|
4397
4397
|
return;
|
|
4398
4398
|
}
|
|
4399
4399
|
if (i === "text-delta") {
|
|
4400
|
-
const
|
|
4401
|
-
|
|
4400
|
+
const A = String(d.id ?? "text");
|
|
4401
|
+
te(f, (P) => xe(P, A, String(d.delta ?? "")));
|
|
4402
4402
|
return;
|
|
4403
4403
|
}
|
|
4404
4404
|
if (i === "text-end") {
|
|
4405
|
-
const
|
|
4406
|
-
|
|
4407
|
-
for (let
|
|
4408
|
-
if ($
|
|
4409
|
-
$
|
|
4405
|
+
const A = String(d.id ?? "text");
|
|
4406
|
+
te(f, (P) => {
|
|
4407
|
+
for (let $ = P.length - 1; $ >= 0; $ -= 1)
|
|
4408
|
+
if (P[$].type === "text" && P[$].id === A) {
|
|
4409
|
+
P[$] = { ...P[$], state: "done" };
|
|
4410
4410
|
return;
|
|
4411
4411
|
}
|
|
4412
4412
|
});
|
|
4413
4413
|
return;
|
|
4414
4414
|
}
|
|
4415
4415
|
if (i === "tool-input-start") {
|
|
4416
|
-
const
|
|
4417
|
-
|
|
4416
|
+
const A = String(d.toolName ?? ""), P = String(d.toolCallId ?? Ct());
|
|
4417
|
+
j.value = A, te(
|
|
4418
4418
|
f,
|
|
4419
|
-
(
|
|
4419
|
+
($) => $.push({ type: `tool-${A}`, toolCallId: P, state: "input-streaming" })
|
|
4420
4420
|
);
|
|
4421
4421
|
return;
|
|
4422
4422
|
}
|
|
4423
4423
|
if (i === "tool-input-available" || i === "tool-output-available") {
|
|
4424
|
-
const
|
|
4425
|
-
|
|
4426
|
-
!
|
|
4427
|
-
}), typeof d.toolName == "string" && (
|
|
4424
|
+
const A = String(d.toolCallId ?? ""), P = i === "tool-input-available" ? "input-available" : "output-available";
|
|
4425
|
+
te(f, ($) => {
|
|
4426
|
+
!C($, A, { state: P }) && typeof d.toolName == "string" && $.push({ type: `tool-${d.toolName}`, toolCallId: A, state: P });
|
|
4427
|
+
}), typeof d.toolName == "string" && (j.value = d.toolName);
|
|
4428
4428
|
return;
|
|
4429
4429
|
}
|
|
4430
4430
|
if (i === "tool-output-error") {
|
|
4431
|
-
const
|
|
4432
|
-
|
|
4431
|
+
const A = String(d.toolCallId ?? "");
|
|
4432
|
+
te(f, (P) => C(P, A, { state: "output-error" }));
|
|
4433
4433
|
return;
|
|
4434
4434
|
}
|
|
4435
4435
|
if (i === "error") {
|
|
4436
|
-
const
|
|
4437
|
-
|
|
4438
|
-
|
|
4436
|
+
const A = String(d.errorText ?? "stream error");
|
|
4437
|
+
te(f, (P) => {
|
|
4438
|
+
P.push({ type: "step-start" }), P.push({ type: "text", id: "turn-error", text: A, state: "done" });
|
|
4439
4439
|
});
|
|
4440
4440
|
return;
|
|
4441
4441
|
}
|
|
4442
4442
|
if (i.startsWith("data-")) {
|
|
4443
|
-
const
|
|
4444
|
-
|
|
4443
|
+
const A = i.slice(5), P = d.data ?? {};
|
|
4444
|
+
A === "plan" && typeof P.sessionId == "string" && (n.acked = !0, r.value = P.sessionId, mt(ct(s(e.value), o), P.sessionId)), A !== "turn_stats" && (j.value = A), te(f, ($) => $.push({ type: i, data: P })), J.forEach(($) => $({ name: A, data: P }));
|
|
4445
4445
|
}
|
|
4446
4446
|
}
|
|
4447
|
-
function
|
|
4448
|
-
if (m.value && m.value !==
|
|
4449
|
-
const n = d.length >
|
|
4447
|
+
function S(d) {
|
|
4448
|
+
if (m.value && m.value !== Mo) return;
|
|
4449
|
+
const n = d.length > jt ? `${d.slice(0, jt - 1)}…` : d;
|
|
4450
4450
|
m.value = n, I.value = I.value.map(
|
|
4451
4451
|
(i) => i.id === r.value ? { ...i, title: n } : i
|
|
4452
4452
|
);
|
|
4453
4453
|
}
|
|
4454
4454
|
async function M(d, n) {
|
|
4455
4455
|
const i = d.trim();
|
|
4456
|
-
if (!i ||
|
|
4457
|
-
|
|
4456
|
+
if (!i || E.value) return;
|
|
4457
|
+
Y.value = "", U.value = !1;
|
|
4458
4458
|
const f = {
|
|
4459
|
-
id:
|
|
4459
|
+
id: Ct(),
|
|
4460
4460
|
role: "user",
|
|
4461
4461
|
parts: [{ type: "text", text: i }]
|
|
4462
4462
|
};
|
|
4463
4463
|
a.value = [
|
|
4464
4464
|
...a.value,
|
|
4465
4465
|
n ? { ...f, parts: [...f.parts, { type: "data-edit-target", data: n }] } : f
|
|
4466
|
-
],
|
|
4467
|
-
const
|
|
4466
|
+
], S(i), E.value = !0, j.value = "", G.value = !1, W.value = `assistant-${Date.now()}`;
|
|
4467
|
+
const A = { id: W.value, acked: !1 }, P = setTimeout(() => {
|
|
4468
4468
|
G.value = !0;
|
|
4469
|
-
},
|
|
4469
|
+
}, Lo);
|
|
4470
4470
|
try {
|
|
4471
|
-
const
|
|
4472
|
-
|
|
4471
|
+
const $ = await fetch(
|
|
4472
|
+
_n(Ro(e.value, o)),
|
|
4473
4473
|
{
|
|
4474
4474
|
method: "POST",
|
|
4475
4475
|
headers: {
|
|
@@ -4483,114 +4483,114 @@ function Lo(o) {
|
|
|
4483
4483
|
})
|
|
4484
4484
|
}
|
|
4485
4485
|
);
|
|
4486
|
-
if (
|
|
4487
|
-
const
|
|
4488
|
-
if (typeof (
|
|
4489
|
-
|
|
4486
|
+
if (!$.ok || !$.body) {
|
|
4487
|
+
const Te = await $.json().catch(() => null);
|
|
4488
|
+
if (typeof (Te == null ? void 0 : Te.message) == "string") {
|
|
4489
|
+
Y.value = Te.message, a.value = a.value.filter((Fe) => Fe.id !== f.id);
|
|
4490
4490
|
return;
|
|
4491
4491
|
}
|
|
4492
|
-
console.warn("[report-canvas] chat rejected", { reportId: o, status:
|
|
4492
|
+
console.warn("[report-canvas] chat rejected", { reportId: o, status: $.status }), le(f.id);
|
|
4493
4493
|
return;
|
|
4494
4494
|
}
|
|
4495
|
-
const
|
|
4496
|
-
let
|
|
4495
|
+
const D = $.body.getReader(), re = new TextDecoder();
|
|
4496
|
+
let be = "";
|
|
4497
4497
|
for (; ; ) {
|
|
4498
|
-
const { done:
|
|
4499
|
-
if (
|
|
4500
|
-
|
|
4501
|
-
const
|
|
4498
|
+
const { done: Te, value: Fe } = await D.read();
|
|
4499
|
+
if (Te) break;
|
|
4500
|
+
be += re.decode(Fe, { stream: !0 });
|
|
4501
|
+
const Be = be.split(`
|
|
4502
4502
|
|
|
4503
4503
|
`);
|
|
4504
|
-
|
|
4505
|
-
for (const
|
|
4506
|
-
for (const
|
|
4504
|
+
be = Be.pop() ?? "";
|
|
4505
|
+
for (const Ke of Be)
|
|
4506
|
+
for (const We of Ke.split(`
|
|
4507
4507
|
`)) {
|
|
4508
|
-
if (!
|
|
4509
|
-
const
|
|
4510
|
-
if (!(!
|
|
4508
|
+
if (!We.startsWith("data:")) continue;
|
|
4509
|
+
const Re = We.slice(5).trim();
|
|
4510
|
+
if (!(!Re || Re === "[DONE]"))
|
|
4511
4511
|
try {
|
|
4512
|
-
u(JSON.parse(
|
|
4512
|
+
u(JSON.parse(Re), A);
|
|
4513
4513
|
} catch {
|
|
4514
4514
|
}
|
|
4515
4515
|
}
|
|
4516
4516
|
}
|
|
4517
|
-
} catch (
|
|
4518
|
-
console.warn("[report-canvas] chat stream failed", { reportId: o, err:
|
|
4517
|
+
} catch ($) {
|
|
4518
|
+
console.warn("[report-canvas] chat stream failed", { reportId: o, err: $ }), A.acked ? U.value = !0 : le(f.id);
|
|
4519
4519
|
} finally {
|
|
4520
|
-
clearTimeout(
|
|
4520
|
+
clearTimeout(P), E.value = !1, j.value = "", G.value = !1, B.forEach(($) => $());
|
|
4521
4521
|
}
|
|
4522
4522
|
}
|
|
4523
4523
|
return {
|
|
4524
4524
|
messages: a,
|
|
4525
4525
|
sessionId: r,
|
|
4526
4526
|
title: m,
|
|
4527
|
-
earlier:
|
|
4528
|
-
loadingEarlier:
|
|
4527
|
+
earlier: h,
|
|
4528
|
+
loadingEarlier: y,
|
|
4529
4529
|
chats: I,
|
|
4530
|
-
chatsCursor:
|
|
4530
|
+
chatsCursor: b,
|
|
4531
4531
|
chatsLoading: L,
|
|
4532
|
-
chatsError:
|
|
4532
|
+
chatsError: x,
|
|
4533
4533
|
switching: N,
|
|
4534
|
-
streaming:
|
|
4534
|
+
streaming: E,
|
|
4535
4535
|
turnId: W,
|
|
4536
|
-
activity:
|
|
4537
|
-
error:
|
|
4538
|
-
interrupted:
|
|
4539
|
-
unsent:
|
|
4536
|
+
activity: j,
|
|
4537
|
+
error: Y,
|
|
4538
|
+
interrupted: U,
|
|
4539
|
+
unsent: O,
|
|
4540
4540
|
slow: G,
|
|
4541
|
-
load:
|
|
4542
|
-
select:
|
|
4543
|
-
startChat:
|
|
4544
|
-
loadChats:
|
|
4545
|
-
loadEarlier:
|
|
4546
|
-
stashDraft:
|
|
4547
|
-
recallDraft:
|
|
4548
|
-
takeUnsent:
|
|
4541
|
+
load: g,
|
|
4542
|
+
select: K,
|
|
4543
|
+
startChat: ee,
|
|
4544
|
+
loadChats: X,
|
|
4545
|
+
loadEarlier: se,
|
|
4546
|
+
stashDraft: ye,
|
|
4547
|
+
recallDraft: he,
|
|
4548
|
+
takeUnsent: oe,
|
|
4549
4549
|
send: M,
|
|
4550
|
-
onLifecycle:
|
|
4551
|
-
onSettled:
|
|
4550
|
+
onLifecycle: F,
|
|
4551
|
+
onSettled: _
|
|
4552
4552
|
};
|
|
4553
4553
|
}
|
|
4554
|
-
const
|
|
4555
|
-
function
|
|
4556
|
-
const { timezone: r } =
|
|
4557
|
-
function L(
|
|
4558
|
-
|
|
4554
|
+
const jo = 2e3, Vo = 10 * 6e4;
|
|
4555
|
+
function Fo(o, e, t, a) {
|
|
4556
|
+
const { timezone: r } = Oe(pt()), m = T(null), h = T(null), y = T(!1), I = T(""), b = [];
|
|
4557
|
+
function L(F) {
|
|
4558
|
+
b.push(F);
|
|
4559
4559
|
}
|
|
4560
|
-
let
|
|
4560
|
+
let x;
|
|
4561
4561
|
function N() {
|
|
4562
|
-
|
|
4562
|
+
x !== void 0 && (window.clearInterval(x), x = void 0);
|
|
4563
4563
|
}
|
|
4564
|
-
function
|
|
4565
|
-
var
|
|
4566
|
-
|
|
4564
|
+
function E() {
|
|
4565
|
+
var F;
|
|
4566
|
+
x !== void 0 || e.value || ((F = m.value) == null ? void 0 : F.status) === "running" && (x = window.setInterval(() => void W(), jo));
|
|
4567
4567
|
}
|
|
4568
4568
|
async function W() {
|
|
4569
|
-
var
|
|
4569
|
+
var F;
|
|
4570
4570
|
if (e.value) {
|
|
4571
4571
|
N();
|
|
4572
4572
|
return;
|
|
4573
4573
|
}
|
|
4574
4574
|
try {
|
|
4575
|
-
const { run: B } = await
|
|
4576
|
-
B &&
|
|
4575
|
+
const { run: B } = await No(o, a == null ? void 0 : a.value);
|
|
4576
|
+
B && j(B), ((F = m.value) == null ? void 0 : F.status) !== "running" ? N() : m.value.updatedAt && Date.now() - new Date(m.value.updatedAt).getTime() > Vo && (y.value = !0, N());
|
|
4577
4577
|
} catch {
|
|
4578
4578
|
}
|
|
4579
4579
|
}
|
|
4580
|
-
function
|
|
4581
|
-
B !== void 0 && (
|
|
4582
|
-
const
|
|
4583
|
-
var
|
|
4584
|
-
const
|
|
4585
|
-
return z.status === "ok" && (
|
|
4580
|
+
function j(F, B) {
|
|
4581
|
+
B !== void 0 && (h.value = B);
|
|
4582
|
+
const _ = F.sections.some((z) => {
|
|
4583
|
+
var H;
|
|
4584
|
+
const g = (H = m.value) == null ? void 0 : H.sections.find((K) => K.id === z.id);
|
|
4585
|
+
return z.status === "ok" && (g == null ? void 0 : g.status) !== "ok";
|
|
4586
4586
|
});
|
|
4587
|
-
m.value =
|
|
4587
|
+
m.value = F, y.value = !1, _ && b.forEach((z) => z()), E();
|
|
4588
4588
|
}
|
|
4589
|
-
function
|
|
4590
|
-
var
|
|
4591
|
-
if (
|
|
4592
|
-
const B =
|
|
4593
|
-
Array.isArray(B.sections) &&
|
|
4589
|
+
function Y(F) {
|
|
4590
|
+
var _;
|
|
4591
|
+
if (F.name !== "build_run") return;
|
|
4592
|
+
const B = F.data;
|
|
4593
|
+
Array.isArray(B.sections) && j(
|
|
4594
4594
|
{
|
|
4595
4595
|
runId: B.runId ? String(B.runId) : void 0,
|
|
4596
4596
|
status: B.status ?? "running",
|
|
@@ -4598,442 +4598,443 @@ function Do(o, e, t, a) {
|
|
|
4598
4598
|
updatedAt: (/* @__PURE__ */ new Date()).toISOString()
|
|
4599
4599
|
},
|
|
4600
4600
|
// first snapshot of this turn claims the anchor; later ones keep it
|
|
4601
|
-
(
|
|
4601
|
+
(_ = m.value) != null && _.runId && m.value.runId === B.runId ? void 0 : (t == null ? void 0 : t.value) ?? null
|
|
4602
4602
|
);
|
|
4603
4603
|
}
|
|
4604
|
-
function
|
|
4605
|
-
N(), m.value = null,
|
|
4604
|
+
function U() {
|
|
4605
|
+
N(), m.value = null, h.value = null, y.value = !1, I.value = "";
|
|
4606
4606
|
}
|
|
4607
|
-
function
|
|
4608
|
-
|
|
4607
|
+
function O(F) {
|
|
4608
|
+
F && F.status !== "ok" && j(F, null);
|
|
4609
4609
|
}
|
|
4610
|
-
async function G(
|
|
4610
|
+
async function G(F) {
|
|
4611
4611
|
var B;
|
|
4612
4612
|
if (!(!((B = m.value) != null && B.runId) || m.value.status === "running")) {
|
|
4613
4613
|
I.value = "";
|
|
4614
4614
|
try {
|
|
4615
|
-
const { run:
|
|
4615
|
+
const { run: _ } = await $o(
|
|
4616
4616
|
o,
|
|
4617
4617
|
m.value.runId,
|
|
4618
|
-
|
|
4618
|
+
F,
|
|
4619
4619
|
s(r.value)
|
|
4620
4620
|
);
|
|
4621
|
-
|
|
4622
|
-
} catch (
|
|
4623
|
-
I.value =
|
|
4621
|
+
j(_);
|
|
4622
|
+
} catch (_) {
|
|
4623
|
+
I.value = _ instanceof Error ? _.message : String(_);
|
|
4624
4624
|
}
|
|
4625
4625
|
}
|
|
4626
4626
|
}
|
|
4627
4627
|
async function J() {
|
|
4628
|
-
|
|
4628
|
+
y.value = !1, await W();
|
|
4629
4629
|
}
|
|
4630
|
-
return
|
|
4630
|
+
return De(N), { run: m, anchorId: h, stale: y, retryError: I, seed: O, clear: U, noteEvent: Y, retry: G, refresh: J, onLanded: L };
|
|
4631
4631
|
}
|
|
4632
|
-
const
|
|
4633
|
-
function
|
|
4634
|
-
const t =
|
|
4635
|
-
let m,
|
|
4636
|
-
|
|
4637
|
-
!t.value || typeof ResizeObserver > "u" || (m = new ResizeObserver(([
|
|
4638
|
-
r.value =
|
|
4632
|
+
const Bo = 380, qo = 600, Vt = 'button:not([disabled]),textarea:not([disabled]),select:not([disabled]),a[href],[tabindex]:not([tabindex="-1"])';
|
|
4633
|
+
function Uo(o, e) {
|
|
4634
|
+
const t = T(), a = T(), r = T(0);
|
|
4635
|
+
let m, h = !1;
|
|
4636
|
+
Me(() => {
|
|
4637
|
+
!t.value || typeof ResizeObserver > "u" || (m = new ResizeObserver(([x]) => {
|
|
4638
|
+
r.value = x.contentRect.width, !h && (h = !0, y.value || (o.value = !1));
|
|
4639
4639
|
}), m.observe(t.value));
|
|
4640
|
-
}),
|
|
4641
|
-
const
|
|
4642
|
-
() => !r.value || r.value >=
|
|
4643
|
-
), I =
|
|
4644
|
-
let
|
|
4645
|
-
|
|
4646
|
-
var N,
|
|
4647
|
-
if (
|
|
4648
|
-
|
|
4640
|
+
}), De(() => m == null ? void 0 : m.disconnect());
|
|
4641
|
+
const y = V(
|
|
4642
|
+
() => !r.value || r.value >= Bo + qo
|
|
4643
|
+
), I = V(() => o.value && !y.value && !e.value);
|
|
4644
|
+
let b = null;
|
|
4645
|
+
de(I, async (x) => {
|
|
4646
|
+
var N, E, W;
|
|
4647
|
+
if (x) {
|
|
4648
|
+
b = document.activeElement, await Ee(), (E = (N = a.value) == null ? void 0 : N.querySelector(Vt)) == null || E.focus();
|
|
4649
4649
|
return;
|
|
4650
4650
|
}
|
|
4651
|
-
(W =
|
|
4651
|
+
(W = b == null ? void 0 : b.focus) == null || W.call(b), b = null;
|
|
4652
4652
|
});
|
|
4653
|
-
function L(
|
|
4654
|
-
if (
|
|
4655
|
-
const N = [...a.value.querySelectorAll(
|
|
4653
|
+
function L(x) {
|
|
4654
|
+
if (x.key !== "Tab" || !I.value || !a.value) return;
|
|
4655
|
+
const N = [...a.value.querySelectorAll(Vt)];
|
|
4656
4656
|
if (!N.length) return;
|
|
4657
|
-
const
|
|
4658
|
-
document.activeElement ===
|
|
4657
|
+
const E = x.shiftKey ? N[0] : N[N.length - 1];
|
|
4658
|
+
document.activeElement === E && (x.preventDefault(), (x.shiftKey ? N[N.length - 1] : N[0]).focus());
|
|
4659
4659
|
}
|
|
4660
|
-
return
|
|
4660
|
+
return Me(() => window.addEventListener("keydown", L, !0)), De(() => window.removeEventListener("keydown", L, !0)), { root: t, drawer: a, docked: y, modal: I };
|
|
4661
4661
|
}
|
|
4662
|
-
const
|
|
4662
|
+
const Ho = "page_filters", Wo = { class: "flex min-w-0 grow flex-col" }, Go = { class: "fm-typo-en-title-md-600 block min-w-0 max-w-full overflow-hidden text-ellipsis whitespace-nowrap" }, Yo = { class: "relative shrink-0" }, Ko = {
|
|
4663
4663
|
key: 0,
|
|
4664
4664
|
class: "flex items-center gap-8 border-b border-fm-color-border-secondary px-16 py-8"
|
|
4665
|
-
},
|
|
4665
|
+
}, Jo = {
|
|
4666
4666
|
key: 0,
|
|
4667
4667
|
class: "flex min-w-0 grow items-start overflow-x-auto scrollbar-hide"
|
|
4668
|
-
},
|
|
4668
|
+
}, Xo = {
|
|
4669
4669
|
key: 1,
|
|
4670
4670
|
class: "grow"
|
|
4671
|
-
},
|
|
4671
|
+
}, Qo = {
|
|
4672
4672
|
key: 2,
|
|
4673
4673
|
class: "flex shrink-0 items-center gap-4"
|
|
4674
|
-
},
|
|
4674
|
+
}, Zo = ["aria-pressed", "aria-label", "disabled"], ei = {
|
|
4675
4675
|
key: 1,
|
|
4676
4676
|
"data-testid": "canvas-draft-bar",
|
|
4677
4677
|
class: "flex items-center gap-12 border-b border-fm-color-border-secondary bg-fm-color-system-info-100 px-16 py-8"
|
|
4678
|
-
},
|
|
4678
|
+
}, ti = { class: "fm-typo-en-body-sm-500 text-fm-color-typo-primary" }, ni = { class: "fm-typo-en-body-sm-400 grow text-fm-color-typo-secondary" }, ai = {
|
|
4679
4679
|
key: 0,
|
|
4680
4680
|
class: "fm-typo-en-body-sm-400 text-fm-color-typo-error"
|
|
4681
|
-
},
|
|
4681
|
+
}, ri = {
|
|
4682
4682
|
key: 2,
|
|
4683
4683
|
role: "status",
|
|
4684
4684
|
class: "fm-typo-en-body-sm-400 flex items-center gap-8 border-b border-fm-color-border-secondary px-16 py-8"
|
|
4685
|
-
},
|
|
4685
|
+
}, oi = { class: "grow" }, ii = ["aria-label"], si = {
|
|
4686
4686
|
key: 3,
|
|
4687
4687
|
class: "fm-typo-en-body-sm-400 border-b border-fm-color-border-secondary bg-fm-color-system-warning-100 px-16 py-8"
|
|
4688
|
-
},
|
|
4688
|
+
}, li = {
|
|
4689
4689
|
key: 4,
|
|
4690
4690
|
class: "fm-typo-en-body-sm-400 p-16 text-fm-color-typo-error"
|
|
4691
|
-
},
|
|
4691
|
+
}, fi = ["srcdoc", "title"], di = ["role", "aria-modal", "aria-label"], ci = /* @__PURE__ */ je({
|
|
4692
4692
|
__name: "ReportCanvasView",
|
|
4693
4693
|
props: {
|
|
4694
4694
|
reportId: {},
|
|
4695
4695
|
viewOnly: { type: Boolean }
|
|
4696
4696
|
},
|
|
4697
4697
|
setup(o) {
|
|
4698
|
-
const e = o, t =
|
|
4698
|
+
const e = o, t = xn(), a = wn(), { t: r, te: m } = Ve(), { currentReport: h } = Oe(Tn()), y = V(() => {
|
|
4699
4699
|
var l;
|
|
4700
|
-
return
|
|
4701
|
-
}), I = e.reportId || String(t.query.reportId ?? ""),
|
|
4700
|
+
return En(r, m, (l = h.value) == null ? void 0 : l.name, "other");
|
|
4701
|
+
}), I = e.reportId || String(t.query.reportId ?? ""), b = T(), L = T(""), x = V(() => {
|
|
4702
4702
|
var l;
|
|
4703
|
-
return ((l =
|
|
4704
|
-
}), N =
|
|
4705
|
-
var l,
|
|
4706
|
-
return ((
|
|
4707
|
-
}),
|
|
4708
|
-
function
|
|
4709
|
-
|
|
4703
|
+
return ((l = b.value) == null ? void 0 : l.state) === "draft";
|
|
4704
|
+
}), N = V(() => {
|
|
4705
|
+
var l, v;
|
|
4706
|
+
return ((v = (l = b.value) == null ? void 0 : l.unpublishedTurnIds) == null ? void 0 : v.length) ?? 0;
|
|
4707
|
+
}), E = T(!1), W = T(""), j = T(!1), Y = T(!1), U = T(!1);
|
|
4708
|
+
function O() {
|
|
4709
|
+
j.value = !0, g.value = !1;
|
|
4710
4710
|
}
|
|
4711
4711
|
function G() {
|
|
4712
|
-
|
|
4712
|
+
U.value || (j.value ? j.value = !1 : _.value = !1);
|
|
4713
4713
|
}
|
|
4714
4714
|
async function J(l) {
|
|
4715
|
-
await
|
|
4715
|
+
await Ge(() => Promise.resolve(l)), j.value = !1, Y.value = !0;
|
|
4716
4716
|
}
|
|
4717
|
-
const
|
|
4718
|
-
get: () =>
|
|
4717
|
+
const { isAdmin: F } = Sn(), B = V(() => !e.viewOnly && F.value), _ = T(!1), z = T(), g = T(!1), H = T(!1), K = T(), ee = T(), X = V({
|
|
4718
|
+
get: () => H.value ? K.value : ee.value,
|
|
4719
4719
|
set: (l) => {
|
|
4720
|
-
|
|
4720
|
+
H.value ? K.value = l : ee.value = l;
|
|
4721
4721
|
}
|
|
4722
|
-
}),
|
|
4722
|
+
}), se = V(
|
|
4723
4723
|
() => {
|
|
4724
4724
|
var l;
|
|
4725
|
-
return !!
|
|
4726
|
-
(
|
|
4727
|
-
var
|
|
4728
|
-
return
|
|
4725
|
+
return !!X.value && !((l = b.value) != null && l.sections.some(
|
|
4726
|
+
(v) => {
|
|
4727
|
+
var q, Q;
|
|
4728
|
+
return v.id === ((q = X.value) == null ? void 0 : q.sectionId) && v.version === ((Q = X.value) == null ? void 0 : Q.version);
|
|
4729
4729
|
}
|
|
4730
4730
|
));
|
|
4731
4731
|
}
|
|
4732
|
-
),
|
|
4733
|
-
function
|
|
4734
|
-
var
|
|
4732
|
+
), ce = T({});
|
|
4733
|
+
function ye(l, v) {
|
|
4734
|
+
var q;
|
|
4735
4735
|
return String(
|
|
4736
|
-
((
|
|
4736
|
+
((q = l.config) == null ? void 0 : q.title) || ce.value[l.id] || r("reportV5.reportAi.chat.widgetNumber", { number: v + 1 })
|
|
4737
4737
|
);
|
|
4738
4738
|
}
|
|
4739
|
-
const
|
|
4740
|
-
get: () =>
|
|
4739
|
+
const he = T([]), le = T([]), oe = V({
|
|
4740
|
+
get: () => H.value ? he.value : le.value,
|
|
4741
4741
|
set: (l) => {
|
|
4742
|
-
|
|
4742
|
+
H.value ? he.value = l : le.value = l;
|
|
4743
4743
|
}
|
|
4744
4744
|
});
|
|
4745
|
-
function
|
|
4746
|
-
|
|
4745
|
+
function te() {
|
|
4746
|
+
X.value = void 0, oe.value = [], g.value = !1;
|
|
4747
4747
|
}
|
|
4748
|
-
function
|
|
4749
|
-
const l =
|
|
4750
|
-
if (!(l != null && l.element)) return
|
|
4751
|
-
const { element:
|
|
4752
|
-
|
|
4748
|
+
function xe() {
|
|
4749
|
+
const l = X.value;
|
|
4750
|
+
if (!(l != null && l.element)) return te();
|
|
4751
|
+
const { element: v, ...q } = l, Q = oe.value.shift();
|
|
4752
|
+
X.value = Q ? { ...q, element: Q, elementText: Q.text ?? "", elementTag: Q.tag } : q;
|
|
4753
4753
|
}
|
|
4754
|
-
function
|
|
4754
|
+
function C(l) {
|
|
4755
4755
|
l.key === "Escape" && (g.value = !1);
|
|
4756
4756
|
}
|
|
4757
|
-
function
|
|
4757
|
+
function u(l, v = []) {
|
|
4758
4758
|
var Q;
|
|
4759
4759
|
if (!g.value || we.value) return;
|
|
4760
|
-
const
|
|
4761
|
-
!
|
|
4760
|
+
const q = (Q = b.value) == null ? void 0 : Q.sections.find((fe) => fe.id === l.sectionId);
|
|
4761
|
+
!q || q.version !== l.version || (X.value = {
|
|
4762
4762
|
...l,
|
|
4763
|
-
viewParams: JSON.parse(JSON.stringify(
|
|
4764
|
-
viewIntent: JSON.parse(JSON.stringify(
|
|
4765
|
-
label: l.label ||
|
|
4766
|
-
},
|
|
4767
|
-
}
|
|
4768
|
-
const
|
|
4769
|
-
function
|
|
4770
|
-
return
|
|
4771
|
-
const
|
|
4772
|
-
|
|
4763
|
+
viewParams: JSON.parse(JSON.stringify($.params.value)),
|
|
4764
|
+
viewIntent: JSON.parse(JSON.stringify($.intent.value)),
|
|
4765
|
+
label: l.label || ye(q, b.value.sections.indexOf(q))
|
|
4766
|
+
}, oe.value = v, g.value = !1, _.value = !0);
|
|
4767
|
+
}
|
|
4768
|
+
const S = T(""), M = T(""), d = T("");
|
|
4769
|
+
function n(l) {
|
|
4770
|
+
return D.stashDraft(S.value, ee.value), ge.clear(), l().then(() => {
|
|
4771
|
+
const v = D.recallDraft();
|
|
4772
|
+
S.value = v.text, ee.value = v.target, le.value = [], g.value = !1;
|
|
4773
4773
|
});
|
|
4774
4774
|
}
|
|
4775
|
-
async function
|
|
4776
|
-
if (
|
|
4777
|
-
const
|
|
4775
|
+
async function i(l) {
|
|
4776
|
+
if (vt.value) return;
|
|
4777
|
+
const v = l ? K.value : void 0, q = l ? [...he.value] : [];
|
|
4778
4778
|
let Q = !1;
|
|
4779
|
-
await
|
|
4780
|
-
Q = await
|
|
4781
|
-
}), Q && l && (
|
|
4779
|
+
await n(async () => {
|
|
4780
|
+
Q = await D.startChat();
|
|
4781
|
+
}), Q && l && (H.value = !1, ee.value = v, le.value = q, K.value = void 0, he.value = [], S.value = l, await A());
|
|
4782
4782
|
}
|
|
4783
|
-
const
|
|
4784
|
-
const
|
|
4785
|
-
|
|
4783
|
+
const f = (l) => n(async () => {
|
|
4784
|
+
const v = await D.select(l);
|
|
4785
|
+
ge.seed(v);
|
|
4786
4786
|
});
|
|
4787
|
-
async function
|
|
4788
|
-
const l =
|
|
4789
|
-
if (!(!l ||
|
|
4790
|
-
if (
|
|
4791
|
-
|
|
4787
|
+
async function A() {
|
|
4788
|
+
const l = S.value.trim();
|
|
4789
|
+
if (!(!l || se.value || we.value)) {
|
|
4790
|
+
if (d.value = l, S.value = "", await tn(l, X.value), bt.value) {
|
|
4791
|
+
S.value || (S.value = d.value);
|
|
4792
4792
|
return;
|
|
4793
4793
|
}
|
|
4794
|
-
|
|
4794
|
+
te();
|
|
4795
4795
|
}
|
|
4796
4796
|
}
|
|
4797
|
-
function
|
|
4798
|
-
const
|
|
4799
|
-
if (
|
|
4800
|
-
return
|
|
4801
|
-
}
|
|
4802
|
-
const
|
|
4803
|
-
messages:
|
|
4804
|
-
sessionId:
|
|
4805
|
-
title:
|
|
4806
|
-
chats:
|
|
4807
|
-
chatsCursor:
|
|
4808
|
-
chatsLoading:
|
|
4809
|
-
chatsError:
|
|
4810
|
-
switching:
|
|
4811
|
-
earlier:
|
|
4812
|
-
loadingEarlier:
|
|
4797
|
+
function P(l) {
|
|
4798
|
+
const v = D.takeUnsent(l);
|
|
4799
|
+
if (v)
|
|
4800
|
+
return S.value = v.text, X.value = v.target, A();
|
|
4801
|
+
}
|
|
4802
|
+
const $ = vo(I), D = Do(I), {
|
|
4803
|
+
messages: re,
|
|
4804
|
+
sessionId: be,
|
|
4805
|
+
title: Te,
|
|
4806
|
+
chats: Fe,
|
|
4807
|
+
chatsCursor: Be,
|
|
4808
|
+
chatsLoading: Ke,
|
|
4809
|
+
chatsError: We,
|
|
4810
|
+
switching: Re,
|
|
4811
|
+
earlier: Yt,
|
|
4812
|
+
loadingEarlier: Kt,
|
|
4813
4813
|
streaming: we,
|
|
4814
|
-
turnId:
|
|
4815
|
-
activity:
|
|
4816
|
-
error:
|
|
4817
|
-
interrupted:
|
|
4818
|
-
unsent:
|
|
4819
|
-
slow:
|
|
4820
|
-
load:
|
|
4821
|
-
send:
|
|
4822
|
-
onLifecycle:
|
|
4823
|
-
onSettled:
|
|
4824
|
-
} =
|
|
4814
|
+
turnId: ht,
|
|
4815
|
+
activity: Jt,
|
|
4816
|
+
error: bt,
|
|
4817
|
+
interrupted: Xt,
|
|
4818
|
+
unsent: Qt,
|
|
4819
|
+
slow: Zt,
|
|
4820
|
+
load: en,
|
|
4821
|
+
send: tn,
|
|
4822
|
+
onLifecycle: nn,
|
|
4823
|
+
onSettled: an
|
|
4824
|
+
} = D, { dateRange: Je, selectedLocationIds: Xe, locations: gt, timezone: rn } = Oe(pt()), ge = Fo(I, we, ht, be), vt = V(
|
|
4825
4825
|
() => {
|
|
4826
4826
|
var l;
|
|
4827
|
-
return we.value ||
|
|
4827
|
+
return we.value || Re.value || ((l = ge.run.value) == null ? void 0 : l.status) === "running";
|
|
4828
4828
|
}
|
|
4829
|
-
),
|
|
4829
|
+
), yt = V(
|
|
4830
4830
|
() => {
|
|
4831
4831
|
var l;
|
|
4832
|
-
return ((l =
|
|
4832
|
+
return ((l = b.value) == null ? void 0 : l.sections.filter((v) => v.id !== Ho)) ?? [];
|
|
4833
4833
|
}
|
|
4834
|
-
),
|
|
4835
|
-
get: () =>
|
|
4834
|
+
), xt = V(() => yt.value.length === 0), wt = V({
|
|
4835
|
+
get: () => B.value && _.value || j.value,
|
|
4836
4836
|
set: (l) => {
|
|
4837
|
-
|
|
4837
|
+
_.value = l, l || (j.value = !1);
|
|
4838
4838
|
}
|
|
4839
|
-
}), { root:
|
|
4839
|
+
}), { root: on, drawer: sn, docked: Qe, modal: Ze } = Uo(wt, g), ln = V(
|
|
4840
4840
|
() => {
|
|
4841
4841
|
var l;
|
|
4842
|
-
return ((l =
|
|
4842
|
+
return ((l = b.value) == null ? void 0 : l.sections.some((v) => v.status === "pending")) ?? !1;
|
|
4843
4843
|
}
|
|
4844
|
-
),
|
|
4845
|
-
onSelectSection:
|
|
4844
|
+
), fn = V(() => we.value ? Bt(Jt.value) : ln.value ? "loading" : "updating"), ke = Eo(z, {
|
|
4845
|
+
onSelectSection: u,
|
|
4846
4846
|
onCancelSelection: () => {
|
|
4847
4847
|
g.value = !1;
|
|
4848
4848
|
},
|
|
4849
|
-
onSetParams: (l,
|
|
4850
|
-
|
|
4849
|
+
onSetParams: (l, v) => {
|
|
4850
|
+
$.setParams(l, v);
|
|
4851
4851
|
},
|
|
4852
|
-
onSectionRendered: (l,
|
|
4853
|
-
|
|
4852
|
+
onSectionRendered: (l, v, q) => {
|
|
4853
|
+
q && (ce.value = { ...ce.value, [l]: q }), et(l, v, "ok");
|
|
4854
4854
|
},
|
|
4855
|
-
onSectionError: (l,
|
|
4856
|
-
console.warn("[report-canvas] section failed", { reportId: I, sectionId: l, message:
|
|
4855
|
+
onSectionError: (l, v, q) => {
|
|
4856
|
+
console.warn("[report-canvas] section failed", { reportId: I, sectionId: l, message: q }), et(l, v, "error", q);
|
|
4857
4857
|
},
|
|
4858
|
-
onSectionLayout: (l,
|
|
4859
|
-
var
|
|
4860
|
-
const Q = (
|
|
4861
|
-
(Q == null ? void 0 : Q.status) === "ok" &&
|
|
4858
|
+
onSectionLayout: (l, v, q) => {
|
|
4859
|
+
var fe;
|
|
4860
|
+
const Q = (fe = b.value) == null ? void 0 : fe.sections.find((ae) => ae.id === l);
|
|
4861
|
+
(Q == null ? void 0 : Q.status) === "ok" && et(l, v, "ok", void 0, q);
|
|
4862
4862
|
}
|
|
4863
4863
|
});
|
|
4864
|
-
|
|
4865
|
-
ke.setCommentMode(g.value && !we.value,
|
|
4864
|
+
$.onResult((l) => ke.pushRows(l)), $.onParamsChanged(() => ke.pushParams($.paramState())), $.bindStore(), de([g, X, ke.ready, we], () => {
|
|
4865
|
+
ke.setCommentMode(g.value && !we.value, X.value);
|
|
4866
4866
|
});
|
|
4867
|
-
async function
|
|
4868
|
-
var
|
|
4869
|
-
const
|
|
4870
|
-
if (!
|
|
4871
|
-
const
|
|
4872
|
-
if (!(
|
|
4867
|
+
async function et(l, v, q, Q, fe) {
|
|
4868
|
+
var Ne, Ue;
|
|
4869
|
+
const ae = (Ne = b.value) == null ? void 0 : Ne.sections.find((Le) => Le.id === l);
|
|
4870
|
+
if (!ae || v !== ae.version) return;
|
|
4871
|
+
const Ce = q === "error" ? Q ?? "the section failed to render" : void 0, _e = fe ?? ae.warnings ?? [];
|
|
4872
|
+
if (!(ae.status === q && ae.error === Ce && (ae.warnings ?? []).join(`
|
|
4873
4873
|
`) === _e.join(`
|
|
4874
4874
|
`))) {
|
|
4875
|
-
|
|
4875
|
+
ae.status = q, ae.error = Ce, ae.warnings = _e.length ? _e : void 0;
|
|
4876
4876
|
try {
|
|
4877
|
-
await
|
|
4877
|
+
await vr(
|
|
4878
4878
|
I,
|
|
4879
4879
|
l,
|
|
4880
|
-
{ version:
|
|
4881
|
-
(
|
|
4880
|
+
{ version: v, status: q, error: Ce, warnings: _e },
|
|
4881
|
+
(Ue = b.value) == null ? void 0 : Ue.state
|
|
4882
4882
|
);
|
|
4883
|
-
} catch (
|
|
4884
|
-
console.warn("[report-canvas] ack failed", { reportId: I, sectionId: l, err:
|
|
4883
|
+
} catch (Le) {
|
|
4884
|
+
console.warn("[report-canvas] ack failed", { reportId: I, sectionId: l, err: Le });
|
|
4885
4885
|
}
|
|
4886
4886
|
}
|
|
4887
4887
|
}
|
|
4888
|
-
async function
|
|
4889
|
-
if (!
|
|
4890
|
-
|
|
4888
|
+
async function Ge(l) {
|
|
4889
|
+
if (!E.value) {
|
|
4890
|
+
E.value = !0, W.value = "";
|
|
4891
4891
|
try {
|
|
4892
|
-
const
|
|
4893
|
-
|
|
4894
|
-
} catch (
|
|
4895
|
-
W.value =
|
|
4892
|
+
const v = await l();
|
|
4893
|
+
b.value = v, $.load(v), await ke.init(v.sections, $.paramState(), $.env());
|
|
4894
|
+
} catch (v) {
|
|
4895
|
+
W.value = v instanceof Error ? v.message : String(v);
|
|
4896
4896
|
} finally {
|
|
4897
|
-
|
|
4897
|
+
E.value = !1;
|
|
4898
4898
|
}
|
|
4899
4899
|
}
|
|
4900
4900
|
}
|
|
4901
|
-
const
|
|
4902
|
-
async function
|
|
4901
|
+
const dn = () => Ge(() => yr(I)), cn = () => Ge(() => xr(I)), mn = (l) => Ge(() => wr(I, l));
|
|
4902
|
+
async function un() {
|
|
4903
4903
|
try {
|
|
4904
4904
|
L.value = "";
|
|
4905
|
-
const l = await
|
|
4906
|
-
|
|
4905
|
+
const l = await Rt(I);
|
|
4906
|
+
b.value = l, $.load(l), B.value && xt.value && Qe.value && (_.value = !0), await Ee(), await ke.init(l.sections, $.paramState(), $.env());
|
|
4907
4907
|
} catch (l) {
|
|
4908
4908
|
L.value = l instanceof Error ? l.message : String(l);
|
|
4909
4909
|
}
|
|
4910
4910
|
}
|
|
4911
|
-
const
|
|
4912
|
-
let
|
|
4913
|
-
function
|
|
4914
|
-
return
|
|
4911
|
+
const tt = /* @__PURE__ */ new Set();
|
|
4912
|
+
let qe = null, nt = !1;
|
|
4913
|
+
function at() {
|
|
4914
|
+
return qe ? (nt = !0, qe) : (qe = (async () => {
|
|
4915
4915
|
do {
|
|
4916
|
-
|
|
4916
|
+
nt = !1;
|
|
4917
4917
|
try {
|
|
4918
|
-
await
|
|
4918
|
+
await pn();
|
|
4919
4919
|
} catch (l) {
|
|
4920
4920
|
console.warn("[report-canvas] refresh failed", { reportId: I, err: l });
|
|
4921
4921
|
}
|
|
4922
|
-
} while (
|
|
4922
|
+
} while (nt);
|
|
4923
4923
|
})().finally(() => {
|
|
4924
|
-
|
|
4925
|
-
}),
|
|
4926
|
-
}
|
|
4927
|
-
async function
|
|
4928
|
-
var
|
|
4929
|
-
const l = (((
|
|
4930
|
-
(((_e =
|
|
4931
|
-
),
|
|
4932
|
-
|
|
4933
|
-
const Q = [...
|
|
4934
|
-
|
|
4935
|
-
const
|
|
4936
|
-
if (
|
|
4937
|
-
await ke.init(
|
|
4924
|
+
qe = null;
|
|
4925
|
+
}), qe);
|
|
4926
|
+
}
|
|
4927
|
+
async function pn() {
|
|
4928
|
+
var Ce, _e;
|
|
4929
|
+
const l = (((Ce = b.value) == null ? void 0 : Ce.sections) ?? []).map((ie) => ie.id), v = new Map(
|
|
4930
|
+
(((_e = b.value) == null ? void 0 : _e.sections) ?? []).map((ie) => [ie.id, ie.version])
|
|
4931
|
+
), q = await Rt(I);
|
|
4932
|
+
b.value = q;
|
|
4933
|
+
const Q = [...tt];
|
|
4934
|
+
tt.clear(), $.applyCanvas(q, Q) && ke.pushParams($.paramState());
|
|
4935
|
+
const fe = q.sections.map((ie) => ie.id);
|
|
4936
|
+
if (fe.length !== l.length || fe.some((ie, Ne) => ie !== l[Ne])) {
|
|
4937
|
+
await ke.init(q.sections, $.paramState(), $.env());
|
|
4938
4938
|
return;
|
|
4939
4939
|
}
|
|
4940
|
-
const
|
|
4941
|
-
(
|
|
4940
|
+
const ae = q.sections.filter(
|
|
4941
|
+
(ie) => v.get(ie.id) !== ie.version
|
|
4942
4942
|
);
|
|
4943
|
-
|
|
4943
|
+
ae.length && await ke.swapSections(ae);
|
|
4944
4944
|
}
|
|
4945
|
-
const
|
|
4946
|
-
|
|
4947
|
-
l.name === "sql_written" && typeof l.data.queryId == "string" &&
|
|
4948
|
-
}),
|
|
4949
|
-
|
|
4945
|
+
const hn = ["param_written", "sql_written", "section_written", "deleted", "reordered"];
|
|
4946
|
+
nn((l) => {
|
|
4947
|
+
l.name === "sql_written" && typeof l.data.queryId == "string" && tt.add(l.data.queryId), hn.includes(l.name) && at(), ge.noteEvent(l);
|
|
4948
|
+
}), an(() => void at()), ge.onLanded(() => void at()), de([gt, rn], () => {
|
|
4949
|
+
b.value && ke.pushEnv($.env());
|
|
4950
4950
|
});
|
|
4951
|
-
const
|
|
4952
|
-
() => Object.values(
|
|
4951
|
+
const bn = V(
|
|
4952
|
+
() => Object.values($.results.value).some((l) => l.truncated)
|
|
4953
4953
|
);
|
|
4954
|
-
return
|
|
4955
|
-
window.addEventListener("keydown",
|
|
4956
|
-
}),
|
|
4957
|
-
var
|
|
4958
|
-
const
|
|
4959
|
-
return c(),
|
|
4954
|
+
return Me(async () => {
|
|
4955
|
+
window.addEventListener("keydown", C), await un(), B.value && ge.seed(await en());
|
|
4956
|
+
}), De(() => window.removeEventListener("keydown", C)), (l, v) => {
|
|
4957
|
+
var Ce, _e, ie, Ne, Ue, Le;
|
|
4958
|
+
const q = Ie("FmTooltip"), Q = Ie("FmPageHead"), fe = Ie("FmButton"), ae = Ie("FmIcon");
|
|
4959
|
+
return c(), p("div", {
|
|
4960
4960
|
ref_key: "root",
|
|
4961
|
-
ref:
|
|
4961
|
+
ref: on,
|
|
4962
4962
|
class: "relative flex h-full min-h-0 w-full"
|
|
4963
4963
|
}, [
|
|
4964
|
-
|
|
4965
|
-
l.viewOnly ? R("", !0) : (c(),
|
|
4964
|
+
w("div", Wo, [
|
|
4965
|
+
l.viewOnly ? R("", !0) : (c(), me(Q, {
|
|
4966
4966
|
key: 0,
|
|
4967
4967
|
class: "remove-line-clamping shrink-0",
|
|
4968
|
-
title:
|
|
4968
|
+
title: y.value,
|
|
4969
4969
|
"back-button": !0,
|
|
4970
|
-
"onClick:back":
|
|
4970
|
+
"onClick:back": v[0] || (v[0] = (ne) => s(a).push({ name: "reports", query: s(t).query }))
|
|
4971
4971
|
}, {
|
|
4972
|
-
title:
|
|
4973
|
-
|
|
4974
|
-
content:
|
|
4972
|
+
title: $e(() => [
|
|
4973
|
+
Z(q, {
|
|
4974
|
+
content: y.value,
|
|
4975
4975
|
placement: "bottom",
|
|
4976
4976
|
"z-index": 2e3,
|
|
4977
4977
|
class: "flex min-w-0 max-w-full justify-start"
|
|
4978
4978
|
}, {
|
|
4979
|
-
default:
|
|
4980
|
-
|
|
4979
|
+
default: $e(() => [
|
|
4980
|
+
w("p", Go, k(y.value), 1)
|
|
4981
4981
|
]),
|
|
4982
4982
|
_: 1
|
|
4983
4983
|
}, 8, ["content"])
|
|
4984
4984
|
]),
|
|
4985
4985
|
_: 1
|
|
4986
4986
|
}, 8, ["title"])),
|
|
4987
|
-
|
|
4988
|
-
!l.viewOnly || ((
|
|
4989
|
-
((_e =
|
|
4990
|
-
|
|
4987
|
+
w("div", Yo, [
|
|
4988
|
+
!l.viewOnly || ((Ce = b.value) == null ? void 0 : Ce.hostFilters) !== !1 ? (c(), p("div", Ko, [
|
|
4989
|
+
((_e = b.value) == null ? void 0 : _e.hostFilters) !== !1 ? (c(), p("div", Jo, [
|
|
4990
|
+
Z(In, {
|
|
4991
4991
|
modelValue: s(Xe),
|
|
4992
|
-
"onUpdate:modelValue":
|
|
4993
|
-
options: s(
|
|
4992
|
+
"onUpdate:modelValue": v[2] || (v[2] = (ne) => It(Xe) ? Xe.value = ne : null),
|
|
4993
|
+
options: s(gt)
|
|
4994
4994
|
}, {
|
|
4995
|
-
default:
|
|
4996
|
-
|
|
4995
|
+
default: $e(() => [
|
|
4996
|
+
Z(Cn, {
|
|
4997
4997
|
"date-range": s(Je),
|
|
4998
|
-
"onUpdate:dateRange":
|
|
4998
|
+
"onUpdate:dateRange": v[1] || (v[1] = (ne) => It(Je) ? Je.value = ne : null)
|
|
4999
4999
|
}, null, 8, ["date-range"])
|
|
5000
5000
|
]),
|
|
5001
5001
|
_: 1
|
|
5002
5002
|
}, 8, ["modelValue", "options"])
|
|
5003
|
-
])) : (c(),
|
|
5004
|
-
|
|
5005
|
-
(
|
|
5003
|
+
])) : (c(), p("div", Xo)),
|
|
5004
|
+
yt.value.length && !l.viewOnly ? (c(), p("div", Qo, [
|
|
5005
|
+
(ie = b.value) != null && ie.canEdit && ((Ne = b.value) != null && Ne.publishedAt) ? (c(), me(fe, {
|
|
5006
5006
|
key: 0,
|
|
5007
5007
|
"data-testid": "canvas-versions-open",
|
|
5008
5008
|
variant: "tertiary",
|
|
5009
5009
|
"prepend-icon": "history",
|
|
5010
5010
|
label: s(r)("reportV5.reportCanvas.draft.history"),
|
|
5011
|
-
"aria-expanded":
|
|
5012
|
-
onClick:
|
|
5011
|
+
"aria-expanded": j.value,
|
|
5012
|
+
onClick: O
|
|
5013
5013
|
}, null, 8, ["label", "aria-expanded"])) : R("", !0),
|
|
5014
|
-
|
|
5014
|
+
B.value ? (c(), me(q, {
|
|
5015
|
+
key: 1,
|
|
5015
5016
|
placement: "bottom",
|
|
5016
5017
|
content: s(r)(
|
|
5017
5018
|
g.value ? "reportV5.reportAi.chat.cancelSelection" : "reportV5.reportAi.chat.commentWidget"
|
|
5018
5019
|
)
|
|
5019
5020
|
}, {
|
|
5020
|
-
default:
|
|
5021
|
-
|
|
5021
|
+
default: $e(() => [
|
|
5022
|
+
w("button", {
|
|
5022
5023
|
"data-testid": "canvas-comment-toggle",
|
|
5023
|
-
class:
|
|
5024
|
+
class: Pe(["canvas-comment-target flex h-32 w-32 items-center justify-center rounded-md text-fm-color-typo-secondary disabled:opacity-50", g.value && "bg-fm-color-neutral-gray-100 text-fm-color-primary"]),
|
|
5024
5025
|
"aria-pressed": g.value,
|
|
5025
5026
|
"aria-label": s(r)("reportV5.reportAi.chat.commentWidget"),
|
|
5026
|
-
disabled: s(we) ||
|
|
5027
|
-
onClick:
|
|
5028
|
-
},
|
|
5029
|
-
|
|
5027
|
+
disabled: s(we) || j.value,
|
|
5028
|
+
onClick: v[3] || (v[3] = (ne) => g.value = !g.value)
|
|
5029
|
+
}, v[15] || (v[15] = [
|
|
5030
|
+
w("svg", {
|
|
5030
5031
|
width: "20",
|
|
5031
5032
|
height: "20",
|
|
5032
5033
|
viewBox: "0 0 20 20",
|
|
5033
5034
|
fill: "none",
|
|
5034
5035
|
"aria-hidden": "true"
|
|
5035
5036
|
}, [
|
|
5036
|
-
|
|
5037
|
+
w("path", {
|
|
5037
5038
|
d: "M5 3.5h5a6.5 6.5 0 1 1-6.5 6.5V5A1.5 1.5 0 0 1 5 3.5Z",
|
|
5038
5039
|
stroke: "currentColor",
|
|
5039
5040
|
"stroke-width": "1.5",
|
|
@@ -5041,150 +5042,150 @@ const Bo = "page_filters", qo = { class: "flex min-w-0 grow flex-col" }, Uo = {
|
|
|
5041
5042
|
"stroke-linejoin": "round"
|
|
5042
5043
|
})
|
|
5043
5044
|
], -1)
|
|
5044
|
-
]), 10,
|
|
5045
|
+
]), 10, Zo)
|
|
5045
5046
|
]),
|
|
5046
5047
|
_: 1
|
|
5047
|
-
}, 8, ["content"]),
|
|
5048
|
-
!
|
|
5049
|
-
key:
|
|
5048
|
+
}, 8, ["content"])) : R("", !0),
|
|
5049
|
+
B.value && !_.value && !j.value ? (c(), me(fe, {
|
|
5050
|
+
key: 2,
|
|
5050
5051
|
"data-testid": "report-canvas-chat-open",
|
|
5051
5052
|
variant: "tertiary",
|
|
5052
5053
|
"prepend-icon": "auto_awesome",
|
|
5053
5054
|
label: s(r)("reportV5.reportAi.chat.open"),
|
|
5054
|
-
onClick:
|
|
5055
|
+
onClick: v[4] || (v[4] = (ne) => _.value = !0)
|
|
5055
5056
|
}, null, 8, ["label"])) : R("", !0)
|
|
5056
5057
|
])) : R("", !0)
|
|
5057
5058
|
])) : R("", !0)
|
|
5058
5059
|
]),
|
|
5059
|
-
|
|
5060
|
-
|
|
5061
|
-
|
|
5062
|
-
W.value ? (c(),
|
|
5063
|
-
|
|
5060
|
+
x.value && !l.viewOnly ? (c(), p("div", ei, [
|
|
5061
|
+
w("span", ti, k(s(r)("reportV5.reportCanvas.draft.pending", { count: N.value })), 1),
|
|
5062
|
+
w("span", ni, k(s(r)("reportV5.reportCanvas.draft.hint")), 1),
|
|
5063
|
+
W.value ? (c(), p("span", ai, k(W.value), 1)) : R("", !0),
|
|
5064
|
+
Z(fe, {
|
|
5064
5065
|
"data-testid": "canvas-draft-discard",
|
|
5065
5066
|
variant: "tertiary",
|
|
5066
5067
|
label: s(r)("reportV5.reportCanvas.draft.discard"),
|
|
5067
|
-
disabled:
|
|
5068
|
-
onClick:
|
|
5068
|
+
disabled: E.value,
|
|
5069
|
+
onClick: cn
|
|
5069
5070
|
}, null, 8, ["label", "disabled"]),
|
|
5070
|
-
|
|
5071
|
+
Z(fe, {
|
|
5071
5072
|
"data-testid": "canvas-draft-publish",
|
|
5072
5073
|
variant: "primary",
|
|
5073
5074
|
label: s(r)("reportV5.reportCanvas.draft.publish"),
|
|
5074
|
-
disabled:
|
|
5075
|
-
onClick:
|
|
5075
|
+
disabled: E.value,
|
|
5076
|
+
onClick: dn
|
|
5076
5077
|
}, null, 8, ["label", "disabled"])
|
|
5077
5078
|
])) : R("", !0),
|
|
5078
|
-
|
|
5079
|
-
|
|
5079
|
+
Y.value ? (c(), p("div", ri, [
|
|
5080
|
+
Z(ae, {
|
|
5080
5081
|
name: "check_circle",
|
|
5081
5082
|
size: "sm"
|
|
5082
5083
|
}),
|
|
5083
|
-
|
|
5084
|
-
|
|
5084
|
+
w("span", oi, k(s(r)("reportV5.reportCanvas.history.restored")), 1),
|
|
5085
|
+
w("button", {
|
|
5085
5086
|
class: "flex h-32 w-32 items-center justify-center rounded-md",
|
|
5086
5087
|
"aria-label": s(r)("reportV5.reportCanvas.draft.close"),
|
|
5087
|
-
onClick:
|
|
5088
|
+
onClick: v[5] || (v[5] = (ne) => Y.value = !1)
|
|
5088
5089
|
}, [
|
|
5089
|
-
|
|
5090
|
+
Z(ae, {
|
|
5090
5091
|
name: "close",
|
|
5091
5092
|
size: "sm"
|
|
5092
5093
|
})
|
|
5093
|
-
], 8,
|
|
5094
|
+
], 8, ii)
|
|
5094
5095
|
])) : R("", !0),
|
|
5095
|
-
|
|
5096
|
-
L.value ? (c(),
|
|
5097
|
-
|
|
5096
|
+
bn.value ? (c(), p("div", si, k(s(r)("reportV5.reportCanvas.canvas.truncated")), 1)) : R("", !0),
|
|
5097
|
+
L.value ? (c(), p("p", li, k(L.value), 1)) : R("", !0),
|
|
5098
|
+
vn(w("iframe", {
|
|
5098
5099
|
ref_key: "frame",
|
|
5099
|
-
ref:
|
|
5100
|
+
ref: z,
|
|
5100
5101
|
"data-testid": "report-canvas-frame",
|
|
5101
5102
|
class: "min-h-0 grow border-0",
|
|
5102
|
-
srcdoc: s(
|
|
5103
|
+
srcdoc: s(Ao),
|
|
5103
5104
|
sandbox: "allow-scripts",
|
|
5104
5105
|
title: s(r)("reportV5.reportCanvas.canvas.title")
|
|
5105
|
-
}, null, 8,
|
|
5106
|
-
[
|
|
5106
|
+
}, null, 8, fi), [
|
|
5107
|
+
[yn, !L.value]
|
|
5107
5108
|
])
|
|
5108
5109
|
]),
|
|
5109
|
-
s(
|
|
5110
|
+
s(Ze) ? (c(), p("div", {
|
|
5110
5111
|
key: 0,
|
|
5111
5112
|
class: "canvas-scrim absolute inset-0 z-20",
|
|
5112
5113
|
onClick: G
|
|
5113
5114
|
})) : R("", !0),
|
|
5114
|
-
!l.viewOnly &&
|
|
5115
|
+
!l.viewOnly && wt.value && (s(Qe) || !g.value) ? (c(), p("div", {
|
|
5115
5116
|
key: 1,
|
|
5116
5117
|
ref_key: "drawer",
|
|
5117
|
-
ref:
|
|
5118
|
-
class:
|
|
5119
|
-
s(
|
|
5118
|
+
ref: sn,
|
|
5119
|
+
class: Pe(
|
|
5120
|
+
s(Qe) ? "w-[380px] shrink-0" : "absolute inset-y-0 right-0 z-30 w-full max-w-[380px] shadow-lg"
|
|
5120
5121
|
),
|
|
5121
|
-
role: s(
|
|
5122
|
-
"aria-modal": s(
|
|
5123
|
-
"aria-label": s(r)(
|
|
5122
|
+
role: s(Ze) ? "dialog" : void 0,
|
|
5123
|
+
"aria-modal": s(Ze) ? "true" : void 0,
|
|
5124
|
+
"aria-label": s(r)(j.value ? "reportV5.reportCanvas.draft.history" : "reportV5.reportAi.chat.title")
|
|
5124
5125
|
}, [
|
|
5125
|
-
|
|
5126
|
+
j.value ? (c(), me(fo, {
|
|
5126
5127
|
key: 0,
|
|
5127
5128
|
"report-id": s(I),
|
|
5128
|
-
"published-at": (
|
|
5129
|
-
timezone: s(
|
|
5130
|
-
"has-draft":
|
|
5131
|
-
busy: s(we) ||
|
|
5132
|
-
onClose:
|
|
5129
|
+
"published-at": (Ue = b.value) == null ? void 0 : Ue.publishedAt,
|
|
5130
|
+
timezone: s($).env().timezone,
|
|
5131
|
+
"has-draft": x.value,
|
|
5132
|
+
busy: s(we) || E.value,
|
|
5133
|
+
onClose: v[6] || (v[6] = (ne) => j.value = !1),
|
|
5133
5134
|
onRestored: J,
|
|
5134
|
-
onRestoring:
|
|
5135
|
-
}, null, 8, ["report-id", "published-at", "timezone", "has-draft", "busy"])) : (c(),
|
|
5135
|
+
onRestoring: v[7] || (v[7] = (ne) => U.value = ne)
|
|
5136
|
+
}, null, 8, ["report-id", "published-at", "timezone", "has-draft", "busy"])) : (c(), me(br, {
|
|
5136
5137
|
key: 1,
|
|
5137
|
-
"home-draft":
|
|
5138
|
-
"onUpdate:homeDraft":
|
|
5139
|
-
"home-open":
|
|
5140
|
-
"onUpdate:homeOpen":
|
|
5141
|
-
messages: s(
|
|
5142
|
-
draft:
|
|
5143
|
-
target:
|
|
5144
|
-
"target-stale":
|
|
5138
|
+
"home-draft": M.value,
|
|
5139
|
+
"onUpdate:homeDraft": v[8] || (v[8] = (ne) => M.value = ne),
|
|
5140
|
+
"home-open": H.value,
|
|
5141
|
+
"onUpdate:homeOpen": v[9] || (v[9] = (ne) => H.value = ne),
|
|
5142
|
+
messages: s(re),
|
|
5143
|
+
draft: S.value,
|
|
5144
|
+
target: X.value,
|
|
5145
|
+
"target-stale": se.value,
|
|
5145
5146
|
streaming: s(we),
|
|
5146
|
-
"turn-id": s(
|
|
5147
|
-
phase:
|
|
5148
|
-
slow: s(
|
|
5149
|
-
error: s(
|
|
5150
|
-
interrupted: s(
|
|
5151
|
-
blank:
|
|
5152
|
-
run: s(
|
|
5153
|
-
"run-anchor-id": s(
|
|
5154
|
-
"run-stale": s(
|
|
5155
|
-
"retry-error": s(
|
|
5156
|
-
"undoable-turn-ids": ((
|
|
5157
|
-
undoing:
|
|
5158
|
-
"unsent-ids": s(
|
|
5159
|
-
"chat-id": s(
|
|
5160
|
-
"chat-title": s(
|
|
5161
|
-
chats: s(
|
|
5162
|
-
"chats-cursor": s(
|
|
5163
|
-
"chats-loading": s(
|
|
5164
|
-
"chats-error": s(
|
|
5165
|
-
switching: s(
|
|
5166
|
-
busy:
|
|
5167
|
-
earlier: s(
|
|
5168
|
-
"loading-earlier": s(
|
|
5169
|
-
"onUpdate:draft":
|
|
5170
|
-
onClearTarget:
|
|
5171
|
-
onSubmit:
|
|
5172
|
-
onClose:
|
|
5173
|
-
onRetry: s(
|
|
5174
|
-
onUndo:
|
|
5175
|
-
onResend:
|
|
5176
|
-
onCheckStatus: s(
|
|
5177
|
-
onNewChat:
|
|
5178
|
-
onSelectChat:
|
|
5179
|
-
onLoadChats:
|
|
5180
|
-
onLoadMoreChats:
|
|
5181
|
-
onLoadEarlier:
|
|
5147
|
+
"turn-id": s(ht),
|
|
5148
|
+
phase: fn.value,
|
|
5149
|
+
slow: s(Zt),
|
|
5150
|
+
error: s(bt),
|
|
5151
|
+
interrupted: s(Xt),
|
|
5152
|
+
blank: xt.value,
|
|
5153
|
+
run: s(ge).run.value,
|
|
5154
|
+
"run-anchor-id": s(ge).anchorId.value,
|
|
5155
|
+
"run-stale": s(ge).stale.value,
|
|
5156
|
+
"retry-error": s(ge).retryError.value,
|
|
5157
|
+
"undoable-turn-ids": ((Le = b.value) == null ? void 0 : Le.unpublishedTurnIds) ?? [],
|
|
5158
|
+
undoing: E.value,
|
|
5159
|
+
"unsent-ids": s(Qt),
|
|
5160
|
+
"chat-id": s(be),
|
|
5161
|
+
"chat-title": s(Te),
|
|
5162
|
+
chats: s(Fe),
|
|
5163
|
+
"chats-cursor": s(Be),
|
|
5164
|
+
"chats-loading": s(Ke),
|
|
5165
|
+
"chats-error": s(We),
|
|
5166
|
+
switching: s(Re),
|
|
5167
|
+
busy: vt.value,
|
|
5168
|
+
earlier: s(Yt),
|
|
5169
|
+
"loading-earlier": s(Kt),
|
|
5170
|
+
"onUpdate:draft": v[10] || (v[10] = (ne) => S.value = ne),
|
|
5171
|
+
onClearTarget: xe,
|
|
5172
|
+
onSubmit: A,
|
|
5173
|
+
onClose: v[11] || (v[11] = (ne) => _.value = !1),
|
|
5174
|
+
onRetry: s(ge).retry,
|
|
5175
|
+
onUndo: mn,
|
|
5176
|
+
onResend: P,
|
|
5177
|
+
onCheckStatus: s(ge).refresh,
|
|
5178
|
+
onNewChat: i,
|
|
5179
|
+
onSelectChat: f,
|
|
5180
|
+
onLoadChats: v[12] || (v[12] = (ne) => s(D).loadChats()),
|
|
5181
|
+
onLoadMoreChats: v[13] || (v[13] = (ne) => s(D).loadChats(s(Be) ?? void 0)),
|
|
5182
|
+
onLoadEarlier: v[14] || (v[14] = (ne) => s(D).loadEarlier())
|
|
5182
5183
|
}, null, 8, ["home-draft", "home-open", "messages", "draft", "target", "target-stale", "streaming", "turn-id", "phase", "slow", "error", "interrupted", "blank", "run", "run-anchor-id", "run-stale", "retry-error", "undoable-turn-ids", "undoing", "unsent-ids", "chat-id", "chat-title", "chats", "chats-cursor", "chats-loading", "chats-error", "switching", "busy", "earlier", "loading-earlier", "onRetry", "onCheckStatus"]))
|
|
5183
|
-
], 10,
|
|
5184
|
+
], 10, di)) : R("", !0)
|
|
5184
5185
|
], 512);
|
|
5185
5186
|
};
|
|
5186
5187
|
}
|
|
5187
|
-
}),
|
|
5188
|
+
}), ki = /* @__PURE__ */ ut(ci, [["__scopeId", "data-v-14b7e3fc"]]);
|
|
5188
5189
|
export {
|
|
5189
|
-
|
|
5190
|
+
ki as default
|
|
5190
5191
|
};
|