@feedmepos/mf-report 5.22.12 → 5.22.13-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (30) hide show
  1. package/dist/{App-DDzVhXL7.js → App-pXGWlg3l.js} +40 -40
  2. package/dist/{BaseDialog.vue_vue_type_script_setup_true_lang-BZlvMBPW.js → BaseDialog.vue_vue_type_script_setup_true_lang-CzbeFyTt.js} +3 -3
  3. package/dist/{DateRangeSelect.vue_vue_type_script_setup_true_lang-BM-li0d3.js → DateRangeSelect.vue_vue_type_script_setup_true_lang-B06jDFgJ.js} +2 -2
  4. package/dist/{Default.vue_vue_type_script_setup_true_lang-BuFLfame.js → Default.vue_vue_type_script_setup_true_lang-BTCBYTaC.js} +2 -2
  5. package/dist/{FilterSelector.vue_vue_type_script_setup_true_lang-BoX6fRDT.js → FilterSelector.vue_vue_type_script_setup_true_lang-Ccr5PmzE.js} +6 -6
  6. package/dist/{InsightView-DBmUbSlP.js → InsightView-C0TwLCJv.js} +6 -6
  7. package/dist/{Integration-BDC13WLh.js → Integration-BFEaM0Wz.js} +36 -35
  8. package/dist/{Integrations-C6gWnyhy.js → Integrations-CG-ygqKI.js} +7 -6
  9. package/dist/{Layout-DbHEONpc.js → Layout-D6kcGEx6.js} +1 -1
  10. package/dist/{MenuTab.vue_vue_type_script_setup_true_lang-G9CiV2LK.js → MenuTab.vue_vue_type_script_setup_true_lang-D3EZc4Vp.js} +5 -5
  11. package/dist/{NavigationTab.vue_vue_type_script_setup_true_lang-D9-002wn.js → NavigationTab.vue_vue_type_script_setup_true_lang-CpMCe0cN.js} +1718 -1697
  12. package/dist/{NoData.vue_vue_type_script_setup_true_lang-CdGpZdFx.js → NoData.vue_vue_type_script_setup_true_lang-DdX25Qgn.js} +1 -1
  13. package/dist/{OverviewView-B0dWJYNP.js → OverviewView-ATC5S46N.js} +5 -5
  14. package/dist/{Report-QeJVzX13.js → Report-CVNA4oKn.js} +202 -177
  15. package/dist/ReportEditor-ZXjzIVWj.js +1104 -0
  16. package/dist/ReportView-C0vzCbYY.js +265 -0
  17. package/dist/{SelectComponent.vue_vue_type_script_setup_true_lang-DMMP43KF.js → SelectComponent.vue_vue_type_script_setup_true_lang-BHVPbR3l.js} +1 -1
  18. package/dist/{Setting-Dv-Eo5IX.js → Setting-BfR6T0tE.js} +5 -5
  19. package/dist/{TileEditor-ZqOV5_Le.js → TileEditor-BQDzUwav.js} +8 -8
  20. package/dist/{TransitionFade-CsoI1XtQ.js → TransitionFade-DlAa1-mg.js} +6 -6
  21. package/dist/{useRestaurantPermission-8zTUt56b.js → access-Dw5cDt65-DpLiFTpm.js} +386 -388
  22. package/dist/{app-Du0ALyx7.js → app-tS9-0m0b.js} +56 -36
  23. package/dist/app.js +1 -1
  24. package/dist/style.css +1 -1
  25. package/dist/useReportPermission-DEI1PTJT.js +60 -0
  26. package/dist/useRestaurantPermission-DTzkzgml.js +65 -0
  27. package/dist/{vue-i18n-kHBFKu4C.js → vue-i18n-BxRs360O.js} +7 -7
  28. package/package.json +2 -2
  29. package/dist/ReportEditor-LupGO1_l.js +0 -1103
  30. package/dist/ReportView-BMgXES5v.js +0 -250
@@ -1,1103 +0,0 @@
1
- import { defineComponent as A, mergeModels as G, useModel as K, ref as R, computed as N, resolveComponent as v, createBlock as k, openBlock as u, withCtx as m, createElementVNode as h, createVNode as a, unref as l, normalizeClass as de, createTextVNode as xe, toDisplayString as E, createElementBlock as O, Fragment as H, renderSlot as Me, createCommentVNode as P, watch as fe, renderList as Z, resolveDynamicComponent as qe, isRef as Ue, normalizeStyle as ke, onMounted as Ee } from "vue";
2
- import { W as Pe, g as ze, _ as Je, i as Le, S as Se, d as $e, T as He, a as je } from "./TransitionFade-CsoI1XtQ.js";
3
- import { D as L, c as ve, C as he, a as De, b as Ge, v as ue } from "./BaseDialog.vue_vue_type_script_setup_true_lang-BZlvMBPW.js";
4
- import { storeToRefs as ge } from "pinia";
5
- import { useRouter as Be, useRoute as Ie } from "vue-router";
6
- import { useBreakpoints as be, useSnackbar as Re, FmButtonColorThemeVariant as ne } from "@feedmepos/ui-library";
7
- import { u as We } from "./message-dialog-UoMWOnil.js";
8
- import { u as ce, b as Ke, h as we, e as Ae } from "./vue-i18n-kHBFKu4C.js";
9
- import { r as me } from "./i18n-CI_sQ5d_.js";
10
- import { a as Te, _ as _e } from "./FilterSelector.vue_vue_type_script_setup_true_lang-BoX6fRDT.js";
11
- import { _ as Fe } from "./NoData.vue_vue_type_script_setup_true_lang-CdGpZdFx.js";
12
- import { a as Oe } from "./SelectComponent.vue_vue_type_script_setup_true_lang-DMMP43KF.js";
13
- const Qe = /* @__PURE__ */ A({
14
- __name: "WidgetDialog",
15
- props: /* @__PURE__ */ G({
16
- isOpen: { type: Boolean }
17
- }, {
18
- modelValue: {},
19
- modelModifiers: {}
20
- }),
21
- emits: /* @__PURE__ */ G(["update:isOpen"], ["update:modelValue"]),
22
- setup(C, { emit: s }) {
23
- const { t: n } = ce(), { breakpoints: r } = be(), w = K(C, "modelValue"), c = C, x = s;
24
- function D() {
25
- x("update:isOpen", !1);
26
- }
27
- function g() {
28
- d.value && (w.value = d.value, d.value = void 0, x("update:isOpen", !1));
29
- }
30
- const d = R(), W = N(() => !d.value);
31
- return (q, $) => {
32
- const B = v("FmButton"), f = v("FmDialog");
33
- return u(), k(f, {
34
- "model-value": c.isOpen
35
- }, {
36
- "dialog-header": m(() => [
37
- xe(E(l(n)("report.widget.type")), 1)
38
- ]),
39
- default: m(() => [
40
- a(Pe, {
41
- modelValue: d.value,
42
- "onUpdate:modelValue": $[0] || ($[0] = (M) => d.value = M),
43
- class: de(`grid ${l(r).lg || l(r).md ? "grid-cols-3 gap-3" : "grid-cols-2 gap-3"}`),
44
- "child-class": "p-[8px] flex flex-col"
45
- }, null, 8, ["modelValue", "class"])
46
- ]),
47
- "dialog-footer": m(() => [
48
- $[1] || ($[1] = h("div", { class: "grow" }, null, -1)),
49
- a(B, {
50
- label: l(n)("report.common.cancel"),
51
- variant: "tertiary",
52
- onClick: D
53
- }, null, 8, ["label"]),
54
- a(B, {
55
- label: l(n)("report.common.confirm"),
56
- disabled: W.value,
57
- onClick: g
58
- }, null, 8, ["label", "disabled"])
59
- ]),
60
- _: 1
61
- }, 8, ["model-value"]);
62
- };
63
- }
64
- }), Xe = { class: "fm-typo-en-body-lg-600" }, Ve = /* @__PURE__ */ A({
65
- __name: "ReportEditorTabHeader",
66
- props: /* @__PURE__ */ G({
67
- icon: {
68
- type: String,
69
- required: !0
70
- }
71
- }, {
72
- modelValue: { type: Boolean, required: !0, default: !1 },
73
- modelModifiers: {}
74
- }),
75
- emits: ["update:modelValue"],
76
- setup(C) {
77
- const { t: s } = ce(), n = K(C, "modelValue"), r = C;
78
- return (w, c) => {
79
- const x = v("FmIcon");
80
- return u(), O("div", {
81
- class: "px-6 py-16 flex items-center gap-2 bg-fm-color-neutral-white border cursor-pointer",
82
- onClick: c[0] || (c[0] = (D) => n.value = !n.value)
83
- }, [
84
- h("p", Xe, E(l(s)("report.editor.customizeReport")), 1),
85
- c[1] || (c[1] = h("div", { class: "grow" }, null, -1)),
86
- a(x, {
87
- name: r.icon
88
- }, null, 8, ["name"])
89
- ]);
90
- };
91
- }
92
- }), Ye = /* @__PURE__ */ A({
93
- __name: "ReportEditorTabDesktop",
94
- props: {
95
- modelValue: { required: !0, default: !1 },
96
- modelModifiers: {}
97
- },
98
- emits: ["update:modelValue"],
99
- setup(C) {
100
- const s = K(C, "modelValue");
101
- return (n, r) => (u(), O(H, null, [
102
- a(Ve, {
103
- modelValue: s.value,
104
- "onUpdate:modelValue": r[0] || (r[0] = (w) => s.value = w),
105
- icon: "keyboard_double_arrow_left"
106
- }, null, 8, ["modelValue"]),
107
- Me(n.$slots, "default")
108
- ], 64));
109
- }
110
- }), Ze = /* @__PURE__ */ A({
111
- __name: "ReportEditorTabMobile",
112
- props: {
113
- modelValue: { required: !0, default: !1 },
114
- modelModifiers: {}
115
- },
116
- emits: ["update:modelValue"],
117
- setup(C) {
118
- const s = K(C, "modelValue");
119
- return (n, r) => {
120
- const w = v("FmTopSheet"), c = v("FmCard");
121
- return u(), k(c, { class: "fixed bottom-0 w-full" }, {
122
- default: m(() => [
123
- a(Ve, {
124
- modelValue: s.value,
125
- "onUpdate:modelValue": r[0] || (r[0] = (x) => s.value = x),
126
- icon: "keyboard_double_arrow_up"
127
- }, null, 8, ["modelValue"]),
128
- a(w, {
129
- modelValue: s.value,
130
- "onUpdate:modelValue": r[2] || (r[2] = (x) => s.value = x),
131
- "fullscreen-size": "sm"
132
- }, {
133
- default: m(() => [
134
- a(Ve, {
135
- modelValue: s.value,
136
- "onUpdate:modelValue": r[1] || (r[1] = (x) => s.value = x),
137
- icon: "keyboard_double_arrow_down"
138
- }, null, 8, ["modelValue"]),
139
- s.value ? Me(n.$slots, "default", { key: 0 }) : P("", !0)
140
- ]),
141
- _: 3
142
- }, 8, ["modelValue"])
143
- ]),
144
- _: 3
145
- });
146
- };
147
- }
148
- }), el = {
149
- key: 2,
150
- class: "flex flex-col gap-2"
151
- }, ll = /* @__PURE__ */ A({
152
- __name: "GlobalFilterDialog",
153
- props: /* @__PURE__ */ G({
154
- schemas: {
155
- type: Array,
156
- default: () => []
157
- },
158
- tiles: {
159
- type: Array,
160
- required: !0
161
- }
162
- }, {
163
- globalFilter: {
164
- default: () => null
165
- },
166
- globalFilterModifiers: {},
167
- isOpen: { type: Boolean, default: () => !1, required: !0 },
168
- isOpenModifiers: {}
169
- }),
170
- emits: ["update:globalFilter", "update:isOpen"],
171
- setup(C) {
172
- const { t: s, te: n } = ce(), r = K(C, "globalFilter"), w = K(C, "isOpen"), c = Re(), x = C, D = R(), g = R(), d = R(), W = R(), q = R([]), $ = R([]), B = R(""), f = R(!1);
173
- fe(w, (o) => {
174
- var e, V, i, t, p, _, F;
175
- o && (D.value = ((e = r.value) == null ? void 0 : e.label) || "", g.value = x.schemas.find(
176
- (U) => {
177
- var T;
178
- return U.name === ((T = r.value) == null ? void 0 : T.schemaName);
179
- }
180
- ), d.value = (V = ee.value.find(
181
- (U) => {
182
- var T;
183
- return U.value.name === ((T = r.value) == null ? void 0 : T.name);
184
- }
185
- )) == null ? void 0 : V.value, W.value = (i = r.value) == null ? void 0 : i.option, q.value = ((t = r.value) == null ? void 0 : t.tileIds) || [], $.value = ((p = r.value) == null ? void 0 : p.filters) || [], f.value = !!((_ = r.value) != null && _.dataFormula), B.value = ((F = r.value) == null ? void 0 : F.dataFormula) || "");
186
- });
187
- const M = N(
188
- () => x.schemas.map((o) => ({
189
- label: o.label || o.name,
190
- value: o
191
- }))
192
- ), ee = N(() => {
193
- var o;
194
- return (((o = g.value) == null ? void 0 : o.fields) || []).map((e) => ({
195
- label: e.label || e.name,
196
- value: e
197
- }));
198
- }), le = N(() => {
199
- var o;
200
- return ((o = d.value) == null ? void 0 : o.type) !== L.Timestamp ? [] : ze(s);
201
- }), z = N(() => x.tiles.reduce((o, e, V) => {
202
- var p, _;
203
- const i = e.widget.config.schemaNames ?? [], t = (e.widget.config.joinDatasources ?? []).flatMap(
204
- (F) => F.schemaNames ?? []
205
- );
206
- return [...i, ...t].includes(((p = g.value) == null ? void 0 : p.name) || "") && o.push({
207
- label: (_ = e == null ? void 0 : e.widget.title) != null && _.trim() ? e.widget.title : `Widget ${V + 1}`,
208
- value: e.id
209
- }), o;
210
- }, [])), I = N(
211
- () => x.schemas.flatMap(
212
- (o) => (o.fields ?? []).map((e) => ({
213
- ...e,
214
- labels: [
215
- me(s, n, o.label, "schema"),
216
- me(s, n, e.label || e.name, "other")
217
- ]
218
- }))
219
- )
220
- );
221
- function b(o) {
222
- var e;
223
- o.name !== ((e = g.value) == null ? void 0 : e.name) && (g.value = o, d.value = void 0);
224
- }
225
- function J(o) {
226
- d.value = o, W.value = o.type === L.Timestamp ? ve.DateTime : void 0;
227
- }
228
- function j(o, e) {
229
- switch (o) {
230
- case L.Timestamp:
231
- return e === ve.DateTime || e === ve.TimeOfDay ? he.Between : he.Equal;
232
- case L.Bool:
233
- case L.String:
234
- case L.Numeric:
235
- return he.Equal;
236
- default:
237
- throw new Error(`Unsupported data type: ${o}`);
238
- }
239
- }
240
- function Q() {
241
- if (!g.value) {
242
- c.open({ message: "Invalid schema", type: "error" });
243
- return;
244
- }
245
- if (!d.value) {
246
- c.open({ message: "Invalid dimension", type: "error" });
247
- return;
248
- }
249
- const o = $.value.filter((e) => e ? !M.value.some((i) => i.value.name === e.schemaName) : !0);
250
- if (o.length > 0) {
251
- c.open({
252
- message: `Invalid filter(s): ${o.filter((e) => !!e).map((e) => e.schemaName).join(
253
- ", "
254
- )}${o.some((e) => !e) ? ", unknown filter(s)" : ""} - schema not found`,
255
- type: "error"
256
- });
257
- return;
258
- }
259
- r.value = {
260
- schemaName: g.value.name,
261
- name: d.value.name,
262
- label: D.value,
263
- operator: j(
264
- d.value.type,
265
- d.value.type === L.Timestamp ? W.value ?? ve.DateTime : null
266
- ),
267
- option: d.value.type === L.Timestamp ? W.value : null,
268
- values: [],
269
- tileIds: [...q.value],
270
- filters: JSON.parse(JSON.stringify($.value)),
271
- dataFormula: f.value ? B.value : void 0
272
- }, w.value = !1;
273
- }
274
- function te() {
275
- w.value = !1;
276
- }
277
- const oe = N(() => {
278
- var o;
279
- return [
280
- (o = g.value) == null ? void 0 : o.name,
281
- ...$.value.map((e) => e.schemaName)
282
- ];
283
- });
284
- function re(o) {
285
- var p, _, F, U;
286
- const e = x.tiles.find((T) => T.id === o.value), V = ((_ = (p = e == null ? void 0 : e.widget) == null ? void 0 : p.config) == null ? void 0 : _.schemaNames) ?? [], i = (((U = (F = e == null ? void 0 : e.widget) == null ? void 0 : F.config) == null ? void 0 : U.joinDatasources) ?? []).flatMap(
287
- (T) => T.schemaNames ?? []
288
- ), t = [...V, ...i];
289
- return oe.value.filter((T) => !!T).some((T) => !t.includes(T));
290
- }
291
- return (o, e) => {
292
- const V = v("FmTextField"), i = v("FmSelect"), t = v("FmCheckbox"), p = v("FmTextarea"), _ = v("FmLabel"), F = v("FmIcon"), U = v("FmTooltip"), T = v("FmForm"), ie = v("FmButton"), pe = v("FmDialog");
293
- return u(), k(pe, {
294
- modelValue: w.value,
295
- "onUpdate:modelValue": e[8] || (e[8] = (X) => w.value = X),
296
- overlay: !0,
297
- "z-index": 10
298
- }, {
299
- "dialog-header": m(() => [
300
- xe(E(l(s)("report.section.filter.globalFilter")), 1)
301
- ]),
302
- default: m(() => [
303
- a(T, {
304
- ref: "form",
305
- class: "flex flex-col gap-2 w-[490px]"
306
- }, {
307
- default: m(() => {
308
- var X;
309
- return [
310
- a(V, {
311
- modelValue: D.value,
312
- "onUpdate:modelValue": e[0] || (e[0] = (S) => D.value = S),
313
- placeholder: l(s)("report.section.filter.displayName"),
314
- label: l(s)("report.section.filter.displayName"),
315
- class: "mb-2"
316
- }, null, 8, ["modelValue", "placeholder", "label"]),
317
- a(Oe, {
318
- "model-value": g.value,
319
- items: M.value,
320
- placeholder: l(s)("report.section.schema.title"),
321
- label: l(s)("report.section.schema.title"),
322
- "onUpdate:modelValue": e[1] || (e[1] = (S) => b(S))
323
- }, null, 8, ["model-value", "items", "placeholder", "label"]),
324
- a(Oe, {
325
- "model-value": d.value,
326
- items: ee.value,
327
- placeholder: l(s)("report.section.dimension.title"),
328
- label: l(s)("report.section.dimension.title"),
329
- "onUpdate:modelValue": e[2] || (e[2] = (S) => J(S))
330
- }, null, 8, ["model-value", "items", "placeholder", "label"]),
331
- ((X = d.value) == null ? void 0 : X.type) === l(L).Timestamp ? (u(), k(i, {
332
- key: 0,
333
- modelValue: W.value,
334
- "onUpdate:modelValue": e[3] || (e[3] = (S) => W.value = S),
335
- items: le.value,
336
- placeholder: l(s)("report.section.filter.timeFormatter"),
337
- label: l(s)("report.section.filter.timeFormatter")
338
- }, null, 8, ["modelValue", "items", "placeholder", "label"])) : P("", !0),
339
- a(t, {
340
- modelValue: f.value,
341
- "onUpdate:modelValue": e[4] || (e[4] = (S) => f.value = S),
342
- label: l(s)("report.section.filter.advance"),
343
- value: !0
344
- }, null, 8, ["modelValue", "label"]),
345
- f.value ? (u(), k(p, {
346
- key: 1,
347
- modelValue: B.value,
348
- "onUpdate:modelValue": e[5] || (e[5] = (S) => B.value = S),
349
- placeholder: l(s)("report.section.filter.dataFormula")
350
- }, null, 8, ["modelValue", "placeholder"])) : P("", !0),
351
- a(Je, {
352
- modelValue: $.value,
353
- "onUpdate:modelValue": e[6] || (e[6] = (S) => $.value = S),
354
- options: I.value
355
- }, null, 8, ["modelValue", "options"]),
356
- a(_, { class: "mt-2 fm-typo-en-body-lg-600" }, {
357
- default: m(() => [
358
- xe(E(l(s)("report.section.filter.applyWidget")), 1)
359
- ]),
360
- _: 1
361
- }),
362
- C.tiles.length > 0 ? (u(), O("div", el, [
363
- (u(!0), O(H, null, Z(z.value, (S) => (u(), O("div", {
364
- key: S.value,
365
- class: "flex items-center"
366
- }, [
367
- a(t, {
368
- modelValue: q.value,
369
- "onUpdate:modelValue": e[7] || (e[7] = (ye) => q.value = ye),
370
- label: S.label,
371
- value: S.value
372
- }, null, 8, ["modelValue", "label", "value"]),
373
- re(S) ? (u(), k(U, {
374
- key: 0,
375
- content: l(s)("report.section.filter.missingFilterSchema"),
376
- "z-index": 99,
377
- class: "ml-2"
378
- }, {
379
- default: m(() => [
380
- a(F, {
381
- name: "warning",
382
- class: "text-fm-color-system-error-300"
383
- })
384
- ]),
385
- _: 1
386
- }, 8, ["content"])) : P("", !0)
387
- ]))), 128))
388
- ])) : (u(), k(_, {
389
- key: 3,
390
- class: "fm-typo-en-body-lg-400",
391
- label: l(s)("report.section.filter.noWidget")
392
- }, null, 8, ["label"]))
393
- ];
394
- }),
395
- _: 1
396
- }, 512)
397
- ]),
398
- "dialog-footer": m(() => [
399
- e[9] || (e[9] = h("div", { class: "grow" }, null, -1)),
400
- a(ie, {
401
- label: l(s)("report.common.cancel"),
402
- variant: "tertiary",
403
- onClick: te
404
- }, null, 8, ["label"]),
405
- a(ie, {
406
- label: l(s)("report.common.confirm"),
407
- onClick: Q
408
- }, null, 8, ["label"])
409
- ]),
410
- _: 1
411
- }, 8, ["modelValue"]);
412
- };
413
- }
414
- }), tl = { class: "flex flex-col gap-24 top-0 bg-fm-color-neutral-white z-10" }, ol = { class: "flex flex-col gap-24 top-0 bg-fm-color-neutral-white z-10" }, al = { class: "flex items-center gap-1 max-w-[195px] w-[195px]" }, nl = { class: "line-clamp-2 overflow-hidden max-w-[195px] w-[195px]" }, rl = { class: "flex flex-col gap-24" }, il = { class: "line-clamp-2 overflow-hidden max-w-[195px] w-[195px]" }, Ne = /* @__PURE__ */ A({
415
- __name: "ReportEditorTab",
416
- props: /* @__PURE__ */ G({
417
- hideConfiguration: {
418
- type: Boolean,
419
- default: !1
420
- }
421
- }, {
422
- modelValue: { required: !0 },
423
- modelModifiers: {}
424
- }),
425
- emits: /* @__PURE__ */ G(["hideConfiguration"], ["update:modelValue"]),
426
- setup(C, { emit: s }) {
427
- const n = K(C, "modelValue"), { breakpoints: r } = be(), w = C, c = s, x = Be(), D = Ie(), g = R(), {
428
- currentSelectWidgetType: d,
429
- categories: W,
430
- editingTile: q,
431
- editingTileIndex: $,
432
- editingGlobalFilter: B,
433
- editingGlobalFilterIndex: f
434
- } = ge(De()), { schemas: M } = ge(Ge()), { globalFilters: ee } = ge(Ke()), { promptMessage: le } = We(), z = R(!1), I = R(!1), { t: b, te: J, locale: j } = ce(), Q = R(void 0), te = N(() => {
435
- const i = n.value.tiles.flatMap((t) => {
436
- var F;
437
- const p = t.widget.config.schemaNames ?? [], _ = ((F = t.widget.config.joinDatasources) == null ? void 0 : F.flatMap((U) => U.schemaNames ?? [])) ?? [];
438
- return [...p, ..._];
439
- });
440
- return [...new Set(i)].reduce((t, p) => {
441
- const _ = M.value.find((F) => F.name === p);
442
- return _ && t.push(_), t;
443
- }, []);
444
- });
445
- function oe(i) {
446
- if (!i) return "";
447
- const t = `report.widget.types.${i.toLowerCase()}`;
448
- return J(t) ? b(t) : me(b, J, i, "other");
449
- }
450
- fe(
451
- () => d.value,
452
- () => {
453
- d.value !== void 0 && (Q.value = Le(d.value), q.value = Q.value, $.value = -1, x.push({
454
- name: "tileEditor",
455
- query: D.query
456
- }));
457
- },
458
- { immediate: !0 }
459
- ), fe(
460
- () => n.value.tiles,
461
- (i) => {
462
- i.forEach((t) => {
463
- t.id || (t.id = ue());
464
- });
465
- },
466
- { immediate: !0, deep: !0 }
467
- );
468
- const re = [
469
- {
470
- label: "report.common.edit",
471
- selected: !1,
472
- variant: "tertiary",
473
- onClick: (i) => {
474
- $.value = i, q.value = JSON.parse(JSON.stringify(n.value.tiles[i])), x.push({
475
- name: "tileEditor",
476
- query: D.query
477
- });
478
- }
479
- },
480
- {
481
- label: "report.common.duplicate",
482
- selected: !1,
483
- variant: "tertiary",
484
- onClick: (i) => {
485
- const t = {
486
- ...JSON.parse(JSON.stringify(n.value.tiles[i])),
487
- id: ue()
488
- };
489
- n.value.tiles.push(t);
490
- }
491
- },
492
- {
493
- label: "report.common.remove",
494
- selected: !1,
495
- variant: "destructive",
496
- onClick: async (i) => {
497
- if (await le({
498
- title: b("report.editor.deleteWidget"),
499
- message: b("report.editor.deleteWidgetConfirm", {
500
- title: n.value.tiles[i].widget.title
501
- })
502
- })) {
503
- const p = n.value.tiles[i].id;
504
- n.value.tiles.splice(i, 1), n.value.globalFilters && n.value.globalFilters.forEach((_) => {
505
- var F;
506
- _.tileIds = (F = _.tileIds) == null ? void 0 : F.filter((U) => U !== p);
507
- });
508
- }
509
- }
510
- }
511
- ], o = [
512
- {
513
- label: "report.common.edit",
514
- selected: !1,
515
- variant: "tertiary",
516
- onClick: (i) => {
517
- var t;
518
- f.value = i, B.value = JSON.parse(JSON.stringify((t = n.value.globalFilters) == null ? void 0 : t[i])), z.value = !0;
519
- }
520
- },
521
- {
522
- label: "report.common.remove",
523
- selected: !1,
524
- variant: "destructive",
525
- onClick: async (i) => {
526
- var _, F;
527
- const t = (_ = n.value.globalFilters) == null ? void 0 : _[i];
528
- if (!t) return;
529
- await le({
530
- title: b("report.editor.deleteWidget"),
531
- message: b("report.editor.deleteWidgetConfirm", {
532
- title: we(t)
533
- })
534
- }) && ((F = n.value.globalFilters) == null || F.splice(i, 1));
535
- }
536
- }
537
- ], e = N(() => W.value.map((i) => ({
538
- label: b(`report.category.${i.name}`),
539
- value: i.id
540
- }))), V = N({
541
- get: () => me(b, J, n.value.name, "other"),
542
- set: (i) => {
543
- n.value.name = i;
544
- }
545
- });
546
- return fe(
547
- () => n.value.globalFilters,
548
- (i) => {
549
- ee.value = JSON.parse(JSON.stringify(i || []));
550
- },
551
- { deep: !0, immediate: !0 }
552
- ), (i, t) => {
553
- const p = v("FmTextField"), _ = v("FmSelect"), F = v("FmButton"), U = v("FmIcon"), T = v("FmTooltip"), ie = v("FmMenuItem"), pe = v("FmMenu"), X = v("FmListItem"), S = v("FmList"), ye = v("FmForm");
554
- return u(), k(qe(l(r).lg || l(r).md ? Ye : Ze), {
555
- "model-value": w.hideConfiguration,
556
- "onUpdate:modelValue": t[9] || (t[9] = (y) => c("hideConfiguration", y))
557
- }, {
558
- default: m(() => [
559
- a(ll, {
560
- "is-open": z.value,
561
- "onUpdate:isOpen": t[0] || (t[0] = (y) => z.value = y),
562
- "global-filter": l(B),
563
- tiles: n.value.tiles,
564
- schemas: te.value,
565
- "onUpdate:globalFilter": t[1] || (t[1] = (y) => {
566
- y && (n.value.globalFilters || (n.value.globalFilters = []), typeof l(f) == "number" && l(f) >= 0 ? n.value.globalFilters[l(f)] = y : n.value.globalFilters.push(y));
567
- })
568
- }, null, 8, ["is-open", "global-filter", "tiles", "schemas"]),
569
- a(Qe, {
570
- modelValue: l(d),
571
- "onUpdate:modelValue": t[2] || (t[2] = (y) => Ue(d) ? d.value = y : null),
572
- "is-open": I.value,
573
- "onUpdate:isOpen": t[3] || (t[3] = (y) => I.value = y)
574
- }, null, 8, ["modelValue", "is-open"]),
575
- a(ye, {
576
- ref_key: "form",
577
- ref: g,
578
- class: "px-6 py-16 flex flex-col gap-24 overflow-y-auto overflow-x-hidden"
579
- }, {
580
- default: m(() => [
581
- a(Se, { class: "border-solid" }, {
582
- header: m(() => [
583
- h("p", null, E(l(b)("report.editor.reportInfo")), 1),
584
- t[10] || (t[10] = h("div", { class: "grow" }, null, -1))
585
- ]),
586
- content: m(() => [
587
- h("div", tl, [
588
- a(p, {
589
- modelValue: V.value,
590
- "onUpdate:modelValue": t[4] || (t[4] = (y) => V.value = y),
591
- label: l(b)("report.common.name"),
592
- placeholder: l(b)("report.common.name")
593
- }, null, 8, ["modelValue", "label", "placeholder"]),
594
- (u(), k(_, {
595
- modelValue: n.value.category,
596
- "onUpdate:modelValue": t[5] || (t[5] = (y) => n.value.category = y),
597
- label: l(b)("report.common.category"),
598
- items: e.value,
599
- key: `category-${l(j)}`
600
- }, null, 8, ["modelValue", "label", "items"])),
601
- a(p, {
602
- modelValue: n.value.description,
603
- "onUpdate:modelValue": t[6] || (t[6] = (y) => n.value.description = y),
604
- label: l(b)("report.common.description"),
605
- placeholder: l(b)("report.common.description")
606
- }, null, 8, ["modelValue", "label", "placeholder"])
607
- ])
608
- ]),
609
- _: 1
610
- }),
611
- a(Se, {
612
- class: "border-solid",
613
- "is-open": !1
614
- }, {
615
- header: m(() => [
616
- h("p", null, E(l(b)("report.section.filter.globalFilter")), 1),
617
- t[11] || (t[11] = h("div", { class: "grow" }, null, -1))
618
- ]),
619
- content: m(() => [
620
- h("div", ol, [
621
- a(F, {
622
- label: l(b)("report.section.filter.addGlobalFilter"),
623
- variant: "secondary",
624
- icon: "add",
625
- "icon-position": "prepend",
626
- "border-color": l(ne).ColorPrimary,
627
- "text-color": l(ne).ColorPrimary,
628
- onClick: t[7] || (t[7] = () => {
629
- f.value = null, B.value = null, z.value = !0;
630
- })
631
- }, null, 8, ["label", "border-color", "text-color"]),
632
- a(S, null, {
633
- default: m(() => [
634
- a(l($e), {
635
- list: n.value.globalFilters,
636
- "item-key": "`${element.schemaName}-${element.name}`",
637
- class: "flex flex-col gap-2 cursor-grab",
638
- handle: ".handle"
639
- }, {
640
- item: m(({ element: y, index: se }) => [
641
- a(X, { class: "!cursor-grab border rounded-md border-neutral-300" }, {
642
- default: m(() => {
643
- var ae;
644
- return [
645
- a(U, {
646
- name: "drag_handle",
647
- class: "handle"
648
- }),
649
- h("div", al, [
650
- a(T, {
651
- "z-index": 99,
652
- content: l(we)(y),
653
- class: "handle"
654
- }, {
655
- default: m(() => [
656
- h("p", nl, E(l(we)(y)), 1)
657
- ]),
658
- _: 2
659
- }, 1032, ["content"]),
660
- te.value.find(
661
- (Y) => Y.name === y.schemaName
662
- ) ? P("", !0) : (u(), k(T, {
663
- key: 0,
664
- content: l(b)("report.section.filter.missingSchema"),
665
- "z-index": 99
666
- }, {
667
- default: m(() => [
668
- a(U, {
669
- name: "warning",
670
- class: "text-fm-color-system-error-300"
671
- })
672
- ]),
673
- _: 1
674
- }, 8, ["content"])),
675
- (ae = y.tileIds) != null && ae.length ? P("", !0) : (u(), k(T, {
676
- key: 1,
677
- content: l(b)("report.section.filter.missingTileIds"),
678
- "z-index": 99
679
- }, {
680
- default: m(() => [
681
- a(U, {
682
- name: "warning",
683
- class: "text-fm-color-system-warning-300"
684
- })
685
- ]),
686
- _: 1
687
- }, 8, ["content"]))
688
- ]),
689
- t[12] || (t[12] = h("div", { class: "grow" }, null, -1)),
690
- a(pe, {
691
- trigger: "click",
692
- shift: !0,
693
- "stop-click-propagation": !0
694
- }, {
695
- "menu-button": m(() => [
696
- a(F, {
697
- "append-icon": "more_vert",
698
- variant: "tertiary"
699
- })
700
- ]),
701
- default: m(() => [
702
- (u(), O(H, null, Z(o, (Y, Ce) => a(ie, {
703
- key: Ce,
704
- onClick: (xl) => Y.onClick(se)
705
- }, {
706
- label: m(() => [
707
- h("p", {
708
- class: de(
709
- Y.variant === "destructive" ? " text-fm-color-system-error-300" : ""
710
- )
711
- }, E(l(b)(Y.label)), 3)
712
- ]),
713
- _: 2
714
- }, 1032, ["onClick"])), 64))
715
- ]),
716
- _: 2
717
- }, 1024)
718
- ];
719
- }),
720
- _: 2
721
- }, 1024)
722
- ]),
723
- _: 1
724
- }, 8, ["list"])
725
- ]),
726
- _: 1
727
- })
728
- ])
729
- ]),
730
- _: 1
731
- }),
732
- h("div", rl, [
733
- a(F, {
734
- label: l(b)("report.editor.addWidget"),
735
- variant: "secondary",
736
- icon: "add",
737
- "icon-position": "prepend",
738
- "border-color": l(ne).ColorPrimary,
739
- "text-color": l(ne).ColorPrimary,
740
- onClick: t[8] || (t[8] = (y) => I.value = !0)
741
- }, null, 8, ["label", "border-color", "text-color"]),
742
- a(S, null, {
743
- default: m(() => [
744
- a(l($e), {
745
- list: n.value.tiles,
746
- "item-key": "id",
747
- class: "flex flex-col gap-2 cursor-grab",
748
- handle: ".handle"
749
- }, {
750
- item: m(({ element: y, index: se }) => [
751
- a(X, { class: "!cursor-grab border rounded-md border-neutral-300" }, {
752
- default: m(() => [
753
- a(U, {
754
- name: "drag_handle",
755
- class: "handle"
756
- }),
757
- a(T, {
758
- content: y.widget.title ? oe(y.widget.title) : l(b)("report.editor.widget", { index: se + 1 }),
759
- class: "handle"
760
- }, {
761
- default: m(() => [
762
- h("p", il, E(y.widget.title ? oe(y.widget.title) : l(b)("report.editor.widget", { index: se + 1 })), 1)
763
- ]),
764
- _: 2
765
- }, 1032, ["content"]),
766
- t[13] || (t[13] = h("div", { class: "grow" }, null, -1)),
767
- a(pe, {
768
- trigger: "click",
769
- shift: !0,
770
- "stop-click-propagation": !0
771
- }, {
772
- "menu-button": m(() => [
773
- a(F, {
774
- "append-icon": "more_vert",
775
- variant: "tertiary"
776
- })
777
- ]),
778
- default: m(() => [
779
- (u(), O(H, null, Z(re, (ae, Y) => a(ie, {
780
- key: Y,
781
- onClick: (Ce) => ae.onClick(se)
782
- }, {
783
- label: m(() => [
784
- h("p", {
785
- class: de(
786
- ae.variant === "destructive" ? " text-fm-color-system-error-300" : ""
787
- )
788
- }, E(l(b)(ae.label)), 3)
789
- ]),
790
- _: 2
791
- }, 1032, ["onClick"])), 64))
792
- ]),
793
- _: 2
794
- }, 1024)
795
- ]),
796
- _: 2
797
- }, 1024)
798
- ]),
799
- _: 1
800
- }, 8, ["list"])
801
- ]),
802
- _: 1
803
- })
804
- ])
805
- ]),
806
- _: 1
807
- }, 512)
808
- ]),
809
- _: 1
810
- }, 8, ["model-value"]);
811
- };
812
- }
813
- }), sl = { class: "h-full w-full overflow-x-hidden" }, ul = { class: "flex flex-col bg-fm-color-neutral-white w-[400px]" }, dl = { class: "flex bg-fm-color-neutral-white w-[88px]" }, ml = {
814
- key: 1,
815
- class: "w-full overflow-y-auto"
816
- }, cl = {
817
- key: 0,
818
- class: "w-full grid grid-cols-12 gap-[24px] p-24"
819
- }, pl = { class: "col-span-12 mb-4 flex flex-wrap gap-2 pb-2" }, vl = { key: 2 }, fl = {
820
- key: 0,
821
- class: "grid grid-cols-12 gap-[16px]"
822
- }, gl = { class: "col-span-12 mb-4 flex flex-wrap gap-2 pb-2" }, bl = {
823
- key: 3,
824
- class: "h-full w-full flex items-start justify-center bg-fm-color-neutral-white py-24",
825
- style: { backgroundColor: "#F6F8FC" }
826
- }, yl = {
827
- key: 0,
828
- class: "w-full grid grid-cols-12 gap-[24px] p-24"
829
- }, hl = /* @__PURE__ */ A({
830
- __name: "ReportEditorViewport",
831
- props: /* @__PURE__ */ G({
832
- hideConfiguration: { type: Boolean, required: !1, default: !1 },
833
- previewWidth: { type: Number, required: !0 },
834
- previewHeight: { type: Number, required: !0 },
835
- previewScale: { type: Number, required: !0 }
836
- }, {
837
- modelValue: { required: !0, default: () => {
838
- } },
839
- modelModifiers: {}
840
- }),
841
- emits: /* @__PURE__ */ G(["hideConfiguration"], ["update:modelValue"]),
842
- setup(C, { emit: s }) {
843
- const { breakpoints: n } = be(), r = K(C, "modelValue"), w = C, c = N(() => w.previewWidth > 0 && w.previewHeight > 0), x = N(() => n.value.sm || n.value.xs), D = s;
844
- return (g, d) => {
845
- const W = v("FmCircularProgress"), q = v("FmButton"), $ = v("FmMenuDivider"), B = v("FmCard");
846
- return u(), O("div", sl, [
847
- r.value ? (u(), O(H, { key: 1 }, [
848
- c.value ? P("", !0) : (u(), k(He, {
849
- key: 0,
850
- "model-value": !w.hideConfiguration
851
- }, {
852
- right: m(() => [
853
- h("div", ul, [
854
- r.value ? (u(), k(Ne, {
855
- key: 0,
856
- modelValue: r.value,
857
- "onUpdate:modelValue": d[0] || (d[0] = (f) => r.value = f),
858
- "hide-configuration": w.hideConfiguration,
859
- onHideConfiguration: d[1] || (d[1] = (f) => D("hideConfiguration", f))
860
- }, null, 8, ["modelValue", "hide-configuration"])) : P("", !0)
861
- ])
862
- ]),
863
- left: m(() => [
864
- h("div", dl, [
865
- a(q, {
866
- variant: "secondary",
867
- icon: "keyboard_double_arrow_right",
868
- "border-color": l(ne).ColorPrimary,
869
- "text-color": l(ne).ColorPrimary,
870
- class: "m-24 my-16",
871
- size: "md",
872
- onClick: d[2] || (d[2] = (f) => D("hideConfiguration", !w.hideConfiguration))
873
- }, null, 8, ["border-color", "text-color"])
874
- ])
875
- ]),
876
- _: 1
877
- }, 8, ["model-value"])),
878
- a($, {
879
- vertical: "",
880
- style: { margin: "0px" }
881
- }),
882
- !x.value && !c.value ? (u(), O("div", ml, [
883
- r.value.tiles.length > 0 ? (u(), O("div", cl, [
884
- h("div", pl, [
885
- a(Te)
886
- ]),
887
- (u(!0), O(H, null, Z(r.value.tiles, (f, M) => (u(), k(_e, {
888
- key: `${l(ue)()}_${M}`,
889
- "model-value": f,
890
- index: M,
891
- "hide-export": !0
892
- }, null, 8, ["model-value", "index"]))), 128))
893
- ])) : (u(), k(Fe, { key: 1 }))
894
- ])) : x.value && !c.value ? (u(), O("div", vl, [
895
- a(B, { class: "px-5 pb-28" }, {
896
- default: m(() => [
897
- r.value.tiles.length > 0 ? (u(), O("div", fl, [
898
- h("div", gl, [
899
- a(Te)
900
- ]),
901
- (u(!0), O(H, null, Z(r.value.tiles, (f, M) => (u(), k(_e, {
902
- key: `${l(ue)()}_${M}`,
903
- "model-value": f,
904
- index: M,
905
- "hide-export": !0
906
- }, null, 8, ["model-value", "index"]))), 128))
907
- ])) : (u(), k(Fe, { key: 1 }))
908
- ]),
909
- _: 1
910
- }),
911
- r.value ? (u(), k(Ne, {
912
- key: 0,
913
- modelValue: r.value,
914
- "onUpdate:modelValue": d[3] || (d[3] = (f) => r.value = f),
915
- "hide-configuration": w.hideConfiguration,
916
- onHideConfiguration: d[4] || (d[4] = (f) => {
917
- D("hideConfiguration", f);
918
- })
919
- }, null, 8, ["modelValue", "hide-configuration"])) : P("", !0)
920
- ])) : (u(), O("div", bl, [
921
- h("div", {
922
- style: ke({
923
- transformOrigin: "top center",
924
- transform: `scale(${w.previewScale})`
925
- })
926
- }, [
927
- h("div", {
928
- class: "overflow-y-auto bg-white rounded-lg",
929
- style: ke({
930
- width: w.previewWidth + "px",
931
- height: w.previewHeight + "px"
932
- })
933
- }, [
934
- r.value.tiles.length > 0 ? (u(), O("div", yl, [
935
- (u(!0), O(H, null, Z(r.value.tiles, (f, M) => (u(), k(_e, {
936
- key: `${l(ue)()}_${M}`,
937
- "model-value": f,
938
- index: M,
939
- "hide-export": !0,
940
- "custom-screen-width": w.previewWidth
941
- }, null, 8, ["model-value", "index", "custom-screen-width"]))), 128))
942
- ])) : (u(), k(Fe, { key: 1 }))
943
- ], 4)
944
- ], 4)
945
- ]))
946
- ], 64)) : (u(), k(W, { key: 0 }))
947
- ]);
948
- };
949
- }
950
- }), wl = { class: "flex items-center gap-4" }, _l = { class: "flex justify-center items-center gap-2 w-full" }, Fl = { class: "flex gap-4" }, Il = /* @__PURE__ */ A({
951
- __name: "ReportEditor",
952
- setup(C) {
953
- const s = Be(), n = Ie(), r = De(), { promptLoader: w } = Ae(), { t: c, te: x } = ce(), { currentReport: D, editingReport: g } = ge(r), { breakpoints: d } = be(), W = N(() => {
954
- var o;
955
- return !((o = g.value) != null && o.editable);
956
- }), q = N(() => {
957
- var o;
958
- return ((o = g.value) == null ? void 0 : o.name) ?? c("report.editor.newReport");
959
- }), $ = N(() => me(c, x, q.value, "other")), B = Re(), { promptMessage: f } = We(), M = R(!1);
960
- async function ee() {
961
- if (!g.value || g.value.tiles.length === 0) {
962
- B.open({ message: c("report.messages.noWidget"), type: "error" });
963
- return;
964
- }
965
- const o = W.value ? c("report.common.clone") : c("report.common.save");
966
- if (await f({
967
- title: `${c("report.messages.saveReport")}`,
968
- message: c("report.messages.confirmAction", { action: o, name: $.value })
969
- }))
970
- try {
971
- await w(async () => {
972
- if (W.value) {
973
- const V = JSON.parse(JSON.stringify(g.value));
974
- V.editable = !0, V.id = "", V.name = `${V.name} ${c("report.common.duplicate")}`, await r.createOrUpdateReport(V);
975
- } else
976
- g.value && await r.createOrUpdateReport(g.value);
977
- s.push({
978
- name: "reportView",
979
- query: n.query
980
- });
981
- });
982
- } catch (V) {
983
- console.log(V), B.open({
984
- message: c("report.messages.failedToAction", { action: o }),
985
- type: "error"
986
- });
987
- }
988
- }
989
- async function le() {
990
- var e;
991
- if (!g.value) return;
992
- await f({
993
- title: c("report.common.report", 1),
994
- message: c("report.editor.notSaved", { name: (e = g.value) == null ? void 0 : e.name })
995
- }) && (g.value = JSON.parse(JSON.stringify(D.value)), s.back());
996
- }
997
- Ee(() => {
998
- g.value || s.push({ name: "reports" });
999
- });
1000
- const z = [
1001
- {
1002
- labelKey: "report.common.default",
1003
- width: void 0,
1004
- height: void 0
1005
- },
1006
- {
1007
- labelKey: "report.editor.devices.desktop",
1008
- width: 1920,
1009
- height: 1080
1010
- },
1011
- {
1012
- labelKey: "report.editor.devices.tablet",
1013
- width: 820,
1014
- height: 1180
1015
- },
1016
- {
1017
- labelKey: "report.editor.devices.phone",
1018
- width: 390,
1019
- height: 859
1020
- }
1021
- ], I = R(z[0]), b = R(!1), J = N(() => b.value ? Math.max(I.value.width || 0, I.value.height || 0) : Math.min(I.value.width || 0, I.value.height || 0)), j = N(() => b.value ? Math.min(I.value.width || 0, I.value.height || 0) : Math.max(I.value.width || 0, I.value.height || 0)), Q = N(() => window.innerHeight - 72 - 56), te = N(() => {
1022
- if (!J.value) return 1;
1023
- let o = (Q.value - 48) / J.value, e = j.value * o;
1024
- return e > window.innerWidth && (o = window.innerWidth / j.value, e = j.value * o), o > 1 ? 1 : o;
1025
- });
1026
- function oe(o) {
1027
- I.value = o;
1028
- }
1029
- function re() {
1030
- b.value = !b.value;
1031
- }
1032
- return (o, e) => {
1033
- const V = v("FmTooltip"), i = v("FmButton"), t = v("FmPageHead");
1034
- return u(), k(je, null, {
1035
- default: m(() => [
1036
- a(t, {
1037
- actions: [
1038
- { label: l(c)("report.common.cancel"), value: "cancel", isPrimary: !1 },
1039
- { label: l(c)("report.common.saveReport"), value: "save", isPrimary: !0, prependIcon: "download" }
1040
- ],
1041
- "onClick:action": e[0] || (e[0] = (p) => {
1042
- p === "cancel" && le(), p === "save" && ee();
1043
- })
1044
- }, {
1045
- title: m(() => [
1046
- h("div", wl, [
1047
- a(V, {
1048
- content: $.value,
1049
- placement: "bottom"
1050
- }, {
1051
- default: m(() => [
1052
- h("p", {
1053
- class: de(`${l(d).sm || l(d).xs ? "hidden" : ""} text-ellipsis overflow-hidden text-nowrap fm-typo-en-title-md-600 w-[250px]`)
1054
- }, E($.value), 3)
1055
- ]),
1056
- _: 1
1057
- }, 8, ["content"]),
1058
- h("div", _l, [
1059
- h("div", Fl, [
1060
- (u(), O(H, null, Z(z, (p) => {
1061
- var _;
1062
- return a(i, {
1063
- key: p.labelKey,
1064
- label: l(c)(p.labelKey),
1065
- variant: ((_ = I.value) == null ? void 0 : _.labelKey) === p.labelKey ? "primary" : "secondary",
1066
- size: "md",
1067
- onClick: (F) => oe(p)
1068
- }, null, 8, ["label", "variant", "onClick"]);
1069
- }), 64))
1070
- ]),
1071
- a(i, {
1072
- icon: "screen_rotation",
1073
- variant: "tertiary",
1074
- size: "md",
1075
- class: "text-fm-color-typo-primary",
1076
- onClick: re
1077
- })
1078
- ])
1079
- ])
1080
- ]),
1081
- _: 1
1082
- }, 8, ["actions"]),
1083
- l(g) ? (u(), k(hl, {
1084
- key: 0,
1085
- modelValue: l(g),
1086
- "onUpdate:modelValue": e[1] || (e[1] = (p) => Ue(g) ? g.value = p : null),
1087
- style: ke({ height: Q.value + "px" }),
1088
- class: de(l(d).lg || l(d).md ? "flex" : ""),
1089
- "hide-configuration": M.value,
1090
- "preview-width": j.value,
1091
- "preview-height": J.value,
1092
- "preview-scale": te.value,
1093
- onHideConfiguration: e[2] || (e[2] = (p) => M.value = p)
1094
- }, null, 8, ["modelValue", "style", "class", "hide-configuration", "preview-width", "preview-height", "preview-scale"])) : P("", !0)
1095
- ]),
1096
- _: 1
1097
- });
1098
- };
1099
- }
1100
- });
1101
- export {
1102
- Il as default
1103
- };