@feedmepos/mf-report 5.27.29 → 5.27.30
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-l8Aceee_.js → App-JSn8-WOL.js} +4 -4
- package/dist/{DateRangeSelect.vue_vue_type_script_setup_true_lang-BkYni0aZ.js → DateRangeSelect.vue_vue_type_script_setup_true_lang-CECvIq-3.js} +1 -1
- package/dist/{Default.vue_vue_type_script_setup_true_lang-jPIgmSCZ.js → Default.vue_vue_type_script_setup_true_lang-CCNr-LfB.js} +1 -1
- package/dist/DynamicWidget.vue_vue_type_script_setup_true_lang-DOmAQ8R-.js +5202 -0
- package/dist/{GlobalFilterSelect.vue_vue_type_script_setup_true_lang-CR2ONrnv.js → GlobalFilterSelect.vue_vue_type_script_setup_true_lang-CsiqgyJ3.js} +1668 -1579
- package/dist/{InsightView-CJfyGUzf.js → InsightView-D2Wg7-D-.js} +4 -4
- package/dist/{Integration-DlcF7Oif.js → Integration-DobHR0Ze.js} +3 -3
- package/dist/{Integrations-OhCa0aQD.js → Integrations-Cg5r8is7.js} +2 -2
- package/dist/{Layout-DNlAstgk.js → Layout-DNoyS3w3.js} +1 -1
- package/dist/{MenuTab.vue_vue_type_script_setup_true_lang-CjLlwzug.js → MenuTab.vue_vue_type_script_setup_true_lang-DJYJVoGs.js} +4 -4
- package/dist/{NavigationTab.vue_vue_type_script_setup_true_lang-aTg8zXAA.js → NavigationTab.vue_vue_type_script_setup_true_lang-BYtqoVXC.js} +3 -3
- package/dist/{OverviewView-BZ0HTUHd.js → OverviewView-D8J5qVAo.js} +4 -4
- package/dist/{Report-DnRk-sIQ.js → Report-BlyDrleN.js} +3 -3
- package/dist/{ReportEditor-BRDvQKC2.js → ReportEditor-7oGk3LwA.js} +6 -6
- package/dist/{ReportView-B0Nqcj3K.js → ReportView-GFX5Kixp.js} +6 -6
- package/dist/{Setting-CeFnRcil.js → Setting-BtEZJlne.js} +3 -3
- package/dist/{Template-B3SzVtg0.js → Template-C3PyEw-X.js} +3 -3
- package/dist/{TileEditor-xPdSEH-m.js → TileEditor-DpfZbID8.js} +898 -883
- package/dist/{TileGrid.vue_vue_type_script_setup_true_lang-Bi7AYMPK.js → TileGrid.vue_vue_type_script_setup_true_lang-1nf-8VJu.js} +1 -1
- package/dist/{TransitionFade-Civd5uxV.js → TransitionFade-C1pF2CT9.js} +79 -72
- package/dist/{app-2AZqzUGz.js → app-C-3cvSLw.js} +12 -12
- package/dist/app.js +1 -1
- package/dist/assets/{formatChartData.worker-D13F_saP.js → formatChartData.worker-DmiQseZ0.js} +47 -47
- package/dist/assets/{processTableData.worker-CklfE7Ff.js → processTableData.worker-CKjQzarL.js} +47 -47
- package/dist/{useRestaurantPermission-BtkJ7Tdr.js → useRestaurantPermission-C_gQOsAi.js} +1 -1
- package/package.json +1 -1
- package/dist/DynamicWidget.vue_vue_type_script_setup_true_lang--vp1Ymn7.js +0 -5119
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import { defineComponent as
|
|
1
|
+
import { defineComponent as de, mergeModels as ve, useModel as ge, computed as F, ref as le, resolveComponent as L, createElementBlock as E, openBlock as f, createVNode as c, createElementVNode as h, unref as l, withCtx as K, toDisplayString as G, Fragment as ue, renderList as Se, withModifiers as we, createTextVNode as Ie, watch as Ce, createCommentVNode as I, createBlock as R, renderSlot as wl, onBeforeUnmount as il, resolveDynamicComponent as Cl, normalizeClass as Fe, withDirectives as ke, vShow as $e, onMounted as xl, withKeys as cl, vModelText as zl, normalizeStyle as ol, isRef as Il } from "vue";
|
|
2
2
|
import { useRoute as Pl, useRouter as El } from "vue-router";
|
|
3
|
-
import { u as sl, f as rl, h as ze, F as
|
|
4
|
-
import { W as q, a as
|
|
5
|
-
import { storeToRefs as
|
|
3
|
+
import { u as sl, f as rl, h as ze, F as je, d as Ke, S as al, a as Wl, W as Xl, T as Hl, c as ql, b as pl } from "./TransitionFade-C1pF2CT9.js";
|
|
4
|
+
import { W as q, a as kl, q as Pe, D as Gl, S as vl, C as Yl, u as Fl, P as fl, b as Jl, c as Kl, i as Ql } from "./GlobalFilterSelect.vue_vue_type_script_setup_true_lang-CsiqgyJ3.js";
|
|
5
|
+
import { storeToRefs as Ne } from "pinia";
|
|
6
6
|
import { u as Vl } from "./message-dialog-UoMWOnil.js";
|
|
7
7
|
import { useSnackbar as Zl, useBreakpoints as Sl, FmButtonColorThemeVariant as Ue } from "@feedmepos/ui-library";
|
|
8
|
-
import { h as et, g as
|
|
8
|
+
import { h as et, g as Ve, R as gl, d as lt, L as Ae, e as el, S as ne, f as fe, j as ll, k as yl, _ as _l } from "./DynamicWidget.vue_vue_type_script_setup_true_lang-DOmAQ8R-.js";
|
|
9
9
|
import { a as be, _ as Tl } from "./SelectComponent.vue_vue_type_script_setup_true_lang-CGbb3b5G.js";
|
|
10
|
-
import { u as
|
|
11
|
-
import { r as
|
|
12
|
-
import { a as Oe, d as qe } from "./DateRangeSelect.vue_vue_type_script_setup_true_lang-
|
|
13
|
-
import { a as tt, d as He } from "./app-
|
|
10
|
+
import { u as pe, _ as $l } from "./_plugin-vue_export-helper-onplcgja.js";
|
|
11
|
+
import { r as re } from "./i18n-CI_sQ5d_.js";
|
|
12
|
+
import { a as Oe, d as qe } from "./DateRangeSelect.vue_vue_type_script_setup_true_lang-CECvIq-3.js";
|
|
13
|
+
import { a as tt, d as He } from "./app-C-3cvSLw.js";
|
|
14
14
|
const Qe = [
|
|
15
15
|
{
|
|
16
16
|
type: q.Circular,
|
|
@@ -165,9 +165,9 @@ const Qe = [
|
|
|
165
165
|
canSearch: !1,
|
|
166
166
|
periodType: null
|
|
167
167
|
}
|
|
168
|
-
], ot = { class: "flex flex-col my-2 gap-8" }, at = { class: "fm-typo-en-body-lg-600" }, nt = { class: "text-sm text-fm-color-neutral-gray-400" }, it = ["onClick"], st = { class: "fm-typo-en-body-lg-400 overflow-hidden text-ellipsis line-clamp-1" }, rt = /* @__PURE__ */
|
|
168
|
+
], ot = { class: "flex flex-col my-2 gap-8" }, at = { class: "fm-typo-en-body-lg-600" }, nt = { class: "text-sm text-fm-color-neutral-gray-400" }, it = ["onClick"], st = { class: "fm-typo-en-body-lg-400 overflow-hidden text-ellipsis line-clamp-1" }, rt = /* @__PURE__ */ de({
|
|
169
169
|
__name: "SchemaSection",
|
|
170
|
-
props: /* @__PURE__ */
|
|
170
|
+
props: /* @__PURE__ */ ve({
|
|
171
171
|
options: {
|
|
172
172
|
type: Array,
|
|
173
173
|
default: () => []
|
|
@@ -182,42 +182,42 @@ const Qe = [
|
|
|
182
182
|
}),
|
|
183
183
|
emits: ["update:modelValue"],
|
|
184
184
|
setup($) {
|
|
185
|
-
const { t: v, te: e } =
|
|
185
|
+
const { t: v, te: e } = pe(), n = ge($, "modelValue"), a = $, { schemas: V } = Ne(kl()), C = F(
|
|
186
186
|
() => V.value.map((p) => ({
|
|
187
187
|
label: p.label,
|
|
188
188
|
value: p.name,
|
|
189
189
|
raw: p
|
|
190
190
|
}))
|
|
191
|
-
), g =
|
|
192
|
-
if (
|
|
193
|
-
return
|
|
191
|
+
), g = F(() => {
|
|
192
|
+
if (n.value.schemaNames.length === 0 || i.value === 0)
|
|
193
|
+
return C.value.filter((p) => !p.raw.isJoinOnly);
|
|
194
194
|
{
|
|
195
|
-
const p =
|
|
196
|
-
return
|
|
195
|
+
const p = n.value.schemaNames[0], r = V.value.find((O) => O.name === p), B = ((r == null ? void 0 : r.joins) || []).map((O) => O);
|
|
196
|
+
return C.value.filter((O) => B.includes(O.raw.name));
|
|
197
197
|
}
|
|
198
198
|
}), _ = le(!1), M = le(""), i = le(), s = Zl();
|
|
199
199
|
function y(p) {
|
|
200
200
|
var r;
|
|
201
|
-
return
|
|
201
|
+
return re(
|
|
202
202
|
v,
|
|
203
203
|
e,
|
|
204
204
|
(r = V.value.find((B) => B.name === p)) == null ? void 0 : r.label,
|
|
205
205
|
"schema"
|
|
206
206
|
);
|
|
207
207
|
}
|
|
208
|
-
function
|
|
209
|
-
i.value = p, _.value = !0, p !== void 0 ? M.value =
|
|
208
|
+
function k(p) {
|
|
209
|
+
i.value = p, _.value = !0, p !== void 0 ? M.value = n.value.schemaNames[p] : M.value = "";
|
|
210
210
|
}
|
|
211
211
|
function U() {
|
|
212
|
-
M.value !== "" ? (i.value !== void 0 ?
|
|
212
|
+
M.value !== "" ? (i.value !== void 0 ? n.value.schemaNames[i.value] = M.value : n.value.schemaNames.push(M.value), _.value = !1) : s.open({ message: v("report.section.schema.nothingSelected"), type: "error" });
|
|
213
213
|
}
|
|
214
214
|
return (p, r) => {
|
|
215
|
-
const B = L("FmForm"), O = L("FmIcon"),
|
|
215
|
+
const B = L("FmForm"), O = L("FmIcon"), w = L("FmField");
|
|
216
216
|
return f(), E("div", ot, [
|
|
217
217
|
c(Pe, {
|
|
218
218
|
modelValue: _.value,
|
|
219
219
|
"onUpdate:modelValue": r[1] || (r[1] = (u) => _.value = u),
|
|
220
|
-
title:
|
|
220
|
+
title: a.label,
|
|
221
221
|
"primary-button-label": l(v)("report.common.confirm"),
|
|
222
222
|
"secondary-button-label": l(v)("report.common.cancel"),
|
|
223
223
|
onConfirm: U
|
|
@@ -229,11 +229,11 @@ const Qe = [
|
|
|
229
229
|
modelValue: M.value,
|
|
230
230
|
"onUpdate:modelValue": r[0] || (r[0] = (u) => M.value = u),
|
|
231
231
|
label: l(v)("report.section.schema.title"),
|
|
232
|
-
items: i.value === 0 ?
|
|
233
|
-
label: l(
|
|
232
|
+
items: i.value === 0 ? C.value.map((u) => ({
|
|
233
|
+
label: l(re)(l(v), l(e), u.label, "schema"),
|
|
234
234
|
value: u.value
|
|
235
235
|
})) : g.value.map((u) => ({
|
|
236
|
-
label: l(
|
|
236
|
+
label: l(re)(l(v), l(e), u.label, "schema"),
|
|
237
237
|
value: u.value
|
|
238
238
|
}))
|
|
239
239
|
}, null, 8, ["modelValue", "label", "items"])
|
|
@@ -247,31 +247,31 @@ const Qe = [
|
|
|
247
247
|
h("p", at, G(l(v)("report.section.schema.title")), 1),
|
|
248
248
|
h("p", nt, G(l(v)("report.section.schema.description")), 1)
|
|
249
249
|
]),
|
|
250
|
-
(f(!0), E(
|
|
251
|
-
key:
|
|
250
|
+
(f(!0), E(ue, null, Se(n.value.schemaNames, (u, j) => (f(), E("div", {
|
|
251
|
+
key: j,
|
|
252
252
|
class: "flex flex-col gap-2 w-full"
|
|
253
253
|
}, [
|
|
254
254
|
h("div", {
|
|
255
255
|
class: "flex items-center gap-2 border rounded-md border-neutral-300 p-2 h-[40px]",
|
|
256
|
-
onClick: (Y) =>
|
|
256
|
+
onClick: (Y) => k(j)
|
|
257
257
|
}, [
|
|
258
258
|
h("p", st, G(y(u)), 1),
|
|
259
259
|
r[3] || (r[3] = h("div", { class: "grow" }, null, -1)),
|
|
260
260
|
c(O, {
|
|
261
261
|
name: "close",
|
|
262
|
-
onClick:
|
|
262
|
+
onClick: we(
|
|
263
263
|
() => {
|
|
264
|
-
|
|
264
|
+
n.value.schemaNames = l(et)(n.value.schemaNames, j);
|
|
265
265
|
},
|
|
266
266
|
["stop"]
|
|
267
267
|
)
|
|
268
268
|
}, null, 8, ["onClick"])
|
|
269
269
|
], 8, it)
|
|
270
270
|
]))), 128)),
|
|
271
|
-
c(
|
|
271
|
+
c(w, {
|
|
272
272
|
class: "text-fm-color-typo-tertiary",
|
|
273
273
|
onClick: r[2] || (r[2] = () => {
|
|
274
|
-
|
|
274
|
+
k();
|
|
275
275
|
})
|
|
276
276
|
}, {
|
|
277
277
|
default: K(() => [
|
|
@@ -285,9 +285,9 @@ const Qe = [
|
|
|
285
285
|
}), ut = {
|
|
286
286
|
key: 0,
|
|
287
287
|
class: "flex flex-col my-2 gap-8"
|
|
288
|
-
}, dt = { class: "fm-typo-en-body-lg-600 text-ellipsis line-clamp-1" }, mt = { class: "fm-typo-en-body-sm-600 text-fm-color-neutral-gray-400" }, ct = { class: "fm-typo-en-body-lg-400 text-ellipsis overflow-hidden line-clamp-1" }, tl = /* @__PURE__ */
|
|
288
|
+
}, dt = { class: "fm-typo-en-body-lg-600 text-ellipsis line-clamp-1" }, mt = { class: "fm-typo-en-body-sm-600 text-fm-color-neutral-gray-400" }, ct = { class: "fm-typo-en-body-lg-400 text-ellipsis overflow-hidden line-clamp-1" }, tl = /* @__PURE__ */ de({
|
|
289
289
|
__name: "DimensionSection",
|
|
290
|
-
props: /* @__PURE__ */
|
|
290
|
+
props: /* @__PURE__ */ ve({
|
|
291
291
|
options: {
|
|
292
292
|
type: Array,
|
|
293
293
|
default: () => []
|
|
@@ -318,53 +318,53 @@ const Qe = [
|
|
|
318
318
|
}),
|
|
319
319
|
emits: ["update:modelValue"],
|
|
320
320
|
setup($) {
|
|
321
|
-
const { t: v, te: e } =
|
|
322
|
-
() =>
|
|
321
|
+
const { t: v, te: e } = pe(), n = ge($, "modelValue"), a = $, V = F(() => v(`report.section.dimension.${a.label}`)), C = le(!1), g = F(
|
|
322
|
+
() => n.value.map((o, b) => ({
|
|
323
323
|
index: b,
|
|
324
324
|
labels: [o.label || o.name],
|
|
325
325
|
value: o
|
|
326
326
|
}))
|
|
327
|
-
), _ = le(
|
|
327
|
+
), _ = le(n.value.length > 0 ? 0 : void 0);
|
|
328
328
|
function M(o) {
|
|
329
|
-
var b,
|
|
330
|
-
|
|
329
|
+
var b, N, oe, se;
|
|
330
|
+
C.value = !0, i.value = o != null && o.value ? JSON.parse(
|
|
331
331
|
JSON.stringify({
|
|
332
332
|
...o.value,
|
|
333
|
-
label:
|
|
334
|
-
moveToColumn: (((
|
|
333
|
+
label: re(v, e, (b = o.value) == null ? void 0 : b.label, "other"),
|
|
334
|
+
moveToColumn: (((N = a.config) == null ? void 0 : N.columnIds) || []).includes(Ve(o.value))
|
|
335
335
|
})
|
|
336
|
-
) : void 0, _.value = o == null ? void 0 : o.index, s.value = !!((
|
|
336
|
+
) : void 0, _.value = o == null ? void 0 : o.index, s.value = !!((oe = i.value) != null && oe.dataFormula || (se = i.value) != null && se.displayFormula), i.value && i.value.formatter === void 0 && o != null && o.value.timeFormatter && i.value.formatter === void 0 && (i.value.formatter = o == null ? void 0 : o.value.timeFormatter, i.value.timeFormatter = void 0);
|
|
337
337
|
}
|
|
338
|
-
const i = le(void 0), s = le(!1), y =
|
|
339
|
-
() =>
|
|
338
|
+
const i = le(void 0), s = le(!1), y = F(
|
|
339
|
+
() => a.options.find(
|
|
340
340
|
(o) => {
|
|
341
|
-
var b,
|
|
342
|
-
return o.schemaName === ((b = i.value) == null ? void 0 : b.schemaName) && o.name === ((
|
|
341
|
+
var b, N;
|
|
342
|
+
return o.schemaName === ((b = i.value) == null ? void 0 : b.schemaName) && o.name === ((N = i.value) == null ? void 0 : N.name);
|
|
343
343
|
}
|
|
344
344
|
) ?? {}
|
|
345
345
|
);
|
|
346
|
-
|
|
346
|
+
Ce(
|
|
347
347
|
() => {
|
|
348
348
|
var o;
|
|
349
349
|
return (o = i.value) == null ? void 0 : o.option;
|
|
350
350
|
},
|
|
351
351
|
() => {
|
|
352
|
-
!
|
|
352
|
+
!k.value && i.value && (i.value.fillGap = !1);
|
|
353
353
|
}
|
|
354
354
|
);
|
|
355
|
-
const
|
|
355
|
+
const k = F(
|
|
356
356
|
() => {
|
|
357
|
-
var o, b,
|
|
358
|
-
return (
|
|
357
|
+
var o, b, N;
|
|
358
|
+
return (N = (o = y.value) == null ? void 0 : o.fillGapDimensionOptions) == null ? void 0 : N.includes(((b = i.value) == null ? void 0 : b.option) || "");
|
|
359
359
|
}
|
|
360
360
|
);
|
|
361
361
|
function U(o) {
|
|
362
|
-
var b,
|
|
363
|
-
(o.schemaName !== ((b = i.value) == null ? void 0 : b.schemaName) || o.name !== ((
|
|
362
|
+
var b, N;
|
|
363
|
+
(o.schemaName !== ((b = i.value) == null ? void 0 : b.schemaName) || o.name !== ((N = i.value) == null ? void 0 : N.name)) && (i.value = {
|
|
364
364
|
schemaName: o.schemaName,
|
|
365
365
|
name: o.name,
|
|
366
366
|
option: o.dimensionOptions[0],
|
|
367
|
-
label:
|
|
367
|
+
label: re(v, e, o.label, "other"),
|
|
368
368
|
decimal: o.isNumericType ? 2 : void 0,
|
|
369
369
|
hide: !1
|
|
370
370
|
}, s.value = !1);
|
|
@@ -375,50 +375,51 @@ const Qe = [
|
|
|
375
375
|
return;
|
|
376
376
|
}
|
|
377
377
|
const o = [...g.value.map((b) => b.value)];
|
|
378
|
-
s.value || (i.value.dataFormula = void 0, i.value.displayFormula = void 0), _.value !== void 0 ? o[_.value] = i.value : o.push(i.value),
|
|
378
|
+
s.value || (i.value.dataFormula = void 0, i.value.displayFormula = void 0), _.value !== void 0 ? o[_.value] = i.value : o.push(i.value), n.value = o, C.value = !1;
|
|
379
379
|
}
|
|
380
380
|
function r(o) {
|
|
381
|
-
const
|
|
382
|
-
|
|
381
|
+
const N = [...g.value.map((oe) => oe.value)].filter((oe, se) => se !== o);
|
|
382
|
+
n.value = N;
|
|
383
383
|
}
|
|
384
384
|
function B(o) {
|
|
385
385
|
i.value && (i.value.decimal = Number(o));
|
|
386
386
|
}
|
|
387
387
|
function O(o) {
|
|
388
388
|
const b = `report.section.filter.${Oe(o)}`;
|
|
389
|
-
return e(b) ? v(b) :
|
|
389
|
+
return e(b) ? v(b) : re(v, e, o, "field");
|
|
390
390
|
}
|
|
391
|
-
function
|
|
391
|
+
function w(o) {
|
|
392
392
|
const b = `report.section.metric.formatterType.${o}`;
|
|
393
393
|
return e(b) ? v(b) : o;
|
|
394
394
|
}
|
|
395
395
|
function u(o) {
|
|
396
396
|
return Array.isArray(o) ? o.length > 0 : o;
|
|
397
397
|
}
|
|
398
|
-
const
|
|
399
|
-
() =>
|
|
398
|
+
const j = F(
|
|
399
|
+
() => a.options.map((o) => ({
|
|
400
400
|
label: o.labels.join(" "),
|
|
401
401
|
value: o
|
|
402
402
|
}))
|
|
403
403
|
);
|
|
404
404
|
function Y(o) {
|
|
405
|
-
return [o.schemaName, o.name,
|
|
405
|
+
return [o.schemaName, o.name, re(v, e, o.label, "other")].join(" ");
|
|
406
406
|
}
|
|
407
407
|
function d(o) {
|
|
408
408
|
return [o.schemaName, o.name, o.option, o.label || ""].join("__");
|
|
409
409
|
}
|
|
410
|
-
const t =
|
|
411
|
-
var
|
|
410
|
+
const t = F(() => {
|
|
411
|
+
var oe, se;
|
|
412
412
|
const o = /* @__PURE__ */ new Map(), b = i.value ? d(i.value) : "";
|
|
413
|
-
for (const
|
|
414
|
-
b && d(
|
|
415
|
-
|
|
413
|
+
for (const me of ((oe = a.config) == null ? void 0 : oe.dimensions) ?? [])
|
|
414
|
+
b && d(me) === b || o.set(Ve(me), me);
|
|
415
|
+
const N = (se = a.config) == null ? void 0 : se.breakdownDimension;
|
|
416
|
+
return N && (!b || d(N) !== b) && o.set(Ve(N), N), i.value && o.set(Ve(i.value), i.value), Array.from(o.values());
|
|
416
417
|
}), { formulaFieldDataList: A, allowedFormulaFields: z } = sl({
|
|
417
|
-
options:
|
|
418
|
+
options: F(() => a.options),
|
|
418
419
|
primaryFields: t,
|
|
419
|
-
secondaryFields:
|
|
420
|
+
secondaryFields: F(() => {
|
|
420
421
|
var o;
|
|
421
|
-
return ((o =
|
|
422
|
+
return ((o = a.config) == null ? void 0 : o.metrics) ?? [];
|
|
422
423
|
}),
|
|
423
424
|
getLabel: Y
|
|
424
425
|
}), { dataValidation: J, displayValidation: ie, isDataValidating: D, isDisplayValidating: m } = rl({
|
|
@@ -434,33 +435,33 @@ const Qe = [
|
|
|
434
435
|
getAllowedFields: () => z.value
|
|
435
436
|
});
|
|
436
437
|
return (o, b) => {
|
|
437
|
-
const
|
|
438
|
+
const N = L("FmTextField"), oe = L("FmStepperField"), se = L("FmCheckbox"), me = L("FmForm"), Q = L("FmIcon"), Re = L("FmButton"), _e = L("FmListItem"), Be = L("FmList"), xe = L("FmField");
|
|
438
439
|
return $.max !== 0 ? (f(), E("div", ut, [
|
|
439
440
|
c(Pe, {
|
|
440
|
-
modelValue:
|
|
441
|
-
"onUpdate:modelValue": b[12] || (b[12] = (ye) =>
|
|
441
|
+
modelValue: C.value,
|
|
442
|
+
"onUpdate:modelValue": b[12] || (b[12] = (ye) => C.value = ye),
|
|
442
443
|
title: V.value,
|
|
443
444
|
"primary-button-label": l(v)("report.common.confirm"),
|
|
444
445
|
"secondary-button-label": l(v)("report.common.cancel"),
|
|
445
446
|
onConfirm: p
|
|
446
447
|
}, {
|
|
447
448
|
content: K(() => [
|
|
448
|
-
c(
|
|
449
|
+
c(me, {
|
|
449
450
|
ref: "form",
|
|
450
451
|
class: "flex flex-col gap-2 w-[490px]"
|
|
451
452
|
}, {
|
|
452
453
|
default: K(() => {
|
|
453
|
-
var ye, he,
|
|
454
|
+
var ye, he, Te, Z, Ee, We, Xe;
|
|
454
455
|
return [
|
|
455
456
|
c(be, {
|
|
456
457
|
"model-value": y.value,
|
|
457
|
-
items:
|
|
458
|
+
items: j.value,
|
|
458
459
|
placeholder: V.value,
|
|
459
460
|
label: V.value,
|
|
460
461
|
"onUpdate:modelValue": b[0] || (b[0] = (ae) => U(ae))
|
|
461
462
|
}, null, 8, ["model-value", "items", "placeholder", "label"]),
|
|
462
|
-
i.value ? (f(), E(
|
|
463
|
-
c(
|
|
463
|
+
i.value ? (f(), E(ue, { key: 0 }, [
|
|
464
|
+
c(N, {
|
|
464
465
|
modelValue: i.value.label,
|
|
465
466
|
"onUpdate:modelValue": b[1] || (b[1] = (ae) => i.value.label = ae),
|
|
466
467
|
label: l(v)("report.section.dimension.label")
|
|
@@ -474,7 +475,7 @@ const Qe = [
|
|
|
474
475
|
value: ae
|
|
475
476
|
}))) ?? []
|
|
476
477
|
}, null, 8, ["modelValue", "items"])) : I("", !0),
|
|
477
|
-
(
|
|
478
|
+
(Te = y.value) != null && Te.isNumericType ? (f(), R(oe, {
|
|
478
479
|
key: 1,
|
|
479
480
|
label: l(v)("report.common.decimal"),
|
|
480
481
|
"model-value": ((Z = i.value) == null ? void 0 : Z.decimal) ?? 2,
|
|
@@ -491,12 +492,12 @@ const Qe = [
|
|
|
491
492
|
items: [
|
|
492
493
|
{ label: l(v)("report.section.metric.formatterType.NONE"), value: null },
|
|
493
494
|
...(((We = y.value) == null ? void 0 : We.formatters) || []).map((ae) => ({
|
|
494
|
-
label:
|
|
495
|
+
label: w(ae),
|
|
495
496
|
value: ae
|
|
496
497
|
}))
|
|
497
498
|
]
|
|
498
499
|
}, null, 8, ["modelValue", "placeholder", "label", "items"])) : I("", !0),
|
|
499
|
-
|
|
500
|
+
k.value ? (f(), R(se, {
|
|
500
501
|
key: 3,
|
|
501
502
|
"model-value": i.value.fillGap ?? !1,
|
|
502
503
|
label: l(v)("report.section.dimension.fillGap"),
|
|
@@ -506,7 +507,7 @@ const Qe = [
|
|
|
506
507
|
i.value && (i.value.fillGap = u(ae));
|
|
507
508
|
})
|
|
508
509
|
}, null, 8, ["model-value", "label"])) : I("", !0),
|
|
509
|
-
((Xe = y.value) == null ? void 0 : Xe.type) === l(Gl).Timestamp ? (f(), R(
|
|
510
|
+
((Xe = y.value) == null ? void 0 : Xe.type) === l(Gl).Timestamp ? (f(), R(se, {
|
|
510
511
|
key: 4,
|
|
511
512
|
"model-value": i.value.dateComparison ?? !1,
|
|
512
513
|
label: l(v)("report.section.dimension.dateComparison"),
|
|
@@ -515,13 +516,13 @@ const Qe = [
|
|
|
515
516
|
i.value && (i.value.dateComparison = u(ae));
|
|
516
517
|
})
|
|
517
518
|
}, null, 8, ["model-value", "label"])) : I("", !0),
|
|
518
|
-
c(
|
|
519
|
+
c(se, {
|
|
519
520
|
modelValue: i.value.hide,
|
|
520
521
|
"onUpdate:modelValue": b[7] || (b[7] = (ae) => i.value.hide = ae),
|
|
521
522
|
label: l(v)("report.section.dimension.hide"),
|
|
522
523
|
value: ""
|
|
523
524
|
}, null, 8, ["modelValue", "label"]),
|
|
524
|
-
|
|
525
|
+
a.hasRowColumn ? (f(), R(se, {
|
|
525
526
|
key: 5,
|
|
526
527
|
"model-value": i.value.moveToColumn ?? !1,
|
|
527
528
|
label: l(v)("report.section.dimension.moveToColumn"),
|
|
@@ -530,7 +531,7 @@ const Qe = [
|
|
|
530
531
|
i.value && (i.value.moveToColumn = u(ae));
|
|
531
532
|
})
|
|
532
533
|
}, null, 8, ["model-value", "label"])) : I("", !0),
|
|
533
|
-
c(
|
|
534
|
+
c(se, {
|
|
534
535
|
modelValue: s.value,
|
|
535
536
|
"onUpdate:modelValue": b[9] || (b[9] = (ae) => s.value = ae),
|
|
536
537
|
label: l(v)("report.section.dimension.advance"),
|
|
@@ -542,7 +543,7 @@ const Qe = [
|
|
|
542
543
|
"onUpdate:modelValue": b[10] || (b[10] = (ae) => i.value.dataFormula = ae),
|
|
543
544
|
placeholder: l(v)("report.section.dimension.dataFormula"),
|
|
544
545
|
"field-data-list": l(A),
|
|
545
|
-
"formula-field": l(
|
|
546
|
+
"formula-field": l(je).Dimension,
|
|
546
547
|
"validation-result": l(J),
|
|
547
548
|
"is-validating": l(D),
|
|
548
549
|
"valid-formula-label": l(v)("report.common.validFormula")
|
|
@@ -553,7 +554,7 @@ const Qe = [
|
|
|
553
554
|
"onUpdate:modelValue": b[11] || (b[11] = (ae) => i.value.displayFormula = ae),
|
|
554
555
|
placeholder: l(v)("report.section.dimension.displayFormula"),
|
|
555
556
|
"field-data-list": l(A),
|
|
556
|
-
"formula-field": l(
|
|
557
|
+
"formula-field": l(je).Dimension,
|
|
557
558
|
"validation-result": l(ie),
|
|
558
559
|
"is-validating": l(m),
|
|
559
560
|
"valid-formula-label": l(v)("report.common.validFormula")
|
|
@@ -573,24 +574,24 @@ const Qe = [
|
|
|
573
574
|
c(Be, null, {
|
|
574
575
|
default: K(() => [
|
|
575
576
|
c(l(Ke), {
|
|
576
|
-
list:
|
|
577
|
-
"item-key": (ye) => l(
|
|
577
|
+
list: n.value,
|
|
578
|
+
"item-key": (ye) => l(Ve)(ye),
|
|
578
579
|
class: "flex flex-col gap-2"
|
|
579
580
|
}, {
|
|
580
581
|
item: K(({ element: ye, index: he }) => [
|
|
581
|
-
c(
|
|
582
|
+
c(_e, {
|
|
582
583
|
class: "!cursor-grab border rounded-md border-neutral-300 h-[40px] !p-[8px]",
|
|
583
|
-
onClick:
|
|
584
|
+
onClick: we((Te) => M(g.value[he]), ["stop"])
|
|
584
585
|
}, {
|
|
585
586
|
default: K(() => [
|
|
586
587
|
c(Q, { name: "drag_handle" }),
|
|
587
|
-
h("p", ct, G(l(
|
|
588
|
+
h("p", ct, G(l(re)(l(v), l(e), ye.label, "other")), 1),
|
|
588
589
|
b[14] || (b[14] = h("div", { class: "grow" }, null, -1)),
|
|
589
590
|
c(Re, {
|
|
590
591
|
icon: "close",
|
|
591
592
|
size: "md",
|
|
592
593
|
variant: "tertiary",
|
|
593
|
-
onClick:
|
|
594
|
+
onClick: we((Te) => r(he), ["stop"])
|
|
594
595
|
}, null, 8, ["onClick"])
|
|
595
596
|
]),
|
|
596
597
|
_: 2
|
|
@@ -632,7 +633,7 @@ function pt($, v, e) {
|
|
|
632
633
|
}
|
|
633
634
|
}
|
|
634
635
|
function nl($) {
|
|
635
|
-
var
|
|
636
|
+
var n;
|
|
636
637
|
if (!$.widget)
|
|
637
638
|
return $.tiles ? { ...$, tiles: $.tiles.map(nl) } : $;
|
|
638
639
|
const { rowIds: v, columnIds: e } = Ye($.widget.config);
|
|
@@ -650,12 +651,12 @@ function nl($) {
|
|
|
650
651
|
$.widget.config.dimensions,
|
|
651
652
|
$.widget.config.isDrillable
|
|
652
653
|
),
|
|
653
|
-
joinDatasources: (
|
|
654
|
-
const { rowIds: V, columnIds:
|
|
654
|
+
joinDatasources: (n = $.widget.config.joinDatasources) == null ? void 0 : n.map((a) => {
|
|
655
|
+
const { rowIds: V, columnIds: C } = Ye(a);
|
|
655
656
|
return {
|
|
656
|
-
...
|
|
657
|
+
...a,
|
|
657
658
|
rowIds: V,
|
|
658
|
-
columnIds:
|
|
659
|
+
columnIds: C
|
|
659
660
|
};
|
|
660
661
|
})
|
|
661
662
|
}
|
|
@@ -663,21 +664,21 @@ function nl($) {
|
|
|
663
664
|
};
|
|
664
665
|
}
|
|
665
666
|
function Ye($) {
|
|
666
|
-
const v = $.dimensions.filter((
|
|
667
|
-
|
|
668
|
-
const
|
|
669
|
-
for (const
|
|
670
|
-
|
|
671
|
-
for (const
|
|
672
|
-
V.push(
|
|
667
|
+
const v = $.dimensions.filter((C) => C.hide !== !0 && !C.moveToColumn).map((C) => Ve(C)), e = $.dimensions.filter((C) => C.hide !== !0 && C.moveToColumn == !0).map((C) => Ve(C)), n = $.metrics.length > 0;
|
|
668
|
+
n && $.metrics.find((C) => C.moveToRow == !0) ? v.push(Ge.value) : n && e.push(Ge.value);
|
|
669
|
+
const a = [], V = [];
|
|
670
|
+
for (const C of v)
|
|
671
|
+
a.push(C);
|
|
672
|
+
for (const C of e)
|
|
673
|
+
V.push(C);
|
|
673
674
|
return {
|
|
674
|
-
rowIds:
|
|
675
|
+
rowIds: a,
|
|
675
676
|
columnIds: V
|
|
676
677
|
};
|
|
677
678
|
}
|
|
678
|
-
const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body-lg-600" }, gt = { class: "fm-typo-en-body-sm-600 text-fm-color-neutral-gray-400" }, yt = { class: "fm-typo-en-body-lg-400 overflow-hidden text-ellipsis line-clamp-1" }, bt = /* @__PURE__ */
|
|
679
|
+
const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body-lg-600" }, gt = { class: "fm-typo-en-body-sm-600 text-fm-color-neutral-gray-400" }, yt = { class: "fm-typo-en-body-lg-400 overflow-hidden text-ellipsis line-clamp-1" }, bt = /* @__PURE__ */ de({
|
|
679
680
|
__name: "MetricSection",
|
|
680
|
-
props: /* @__PURE__ */
|
|
681
|
+
props: /* @__PURE__ */ ve({
|
|
681
682
|
options: {
|
|
682
683
|
type: Array,
|
|
683
684
|
default: () => []
|
|
@@ -711,27 +712,27 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
711
712
|
modelValue: { required: !1, default: [] },
|
|
712
713
|
modelModifiers: {}
|
|
713
714
|
}),
|
|
714
|
-
emits: /* @__PURE__ */
|
|
715
|
+
emits: /* @__PURE__ */ ve(["config"], ["update:modelValue"]),
|
|
715
716
|
setup($, { emit: v }) {
|
|
716
|
-
const { t: e, te:
|
|
717
|
-
|
|
718
|
-
const
|
|
719
|
-
() =>
|
|
717
|
+
const { t: e, te: n } = pe(), a = ge($, "modelValue"), V = $;
|
|
718
|
+
F(() => !!V.max && a.value.length === V.max);
|
|
719
|
+
const C = F(() => e(`report.section.metric.${V.label}`)), g = le(!1), _ = F(
|
|
720
|
+
() => a.value.map((m, o) => ({
|
|
720
721
|
index: o,
|
|
721
722
|
labels: [m.label || m.name],
|
|
722
723
|
value: m
|
|
723
724
|
}))
|
|
724
|
-
), M = le(
|
|
725
|
+
), M = le(a.value.length > 0 ? 0 : void 0);
|
|
725
726
|
function i(m) {
|
|
726
|
-
var o, b,
|
|
727
|
+
var o, b, N;
|
|
727
728
|
g.value = !0, s.value = m != null && m.value ? JSON.parse(
|
|
728
729
|
JSON.stringify({
|
|
729
730
|
...m.value,
|
|
730
|
-
label:
|
|
731
|
+
label: re(e, n, m.value.label, "other")
|
|
731
732
|
})
|
|
732
|
-
) : void 0, M.value = m == null ? void 0 : m.index, y.value = !!((o = s.value) != null && o.dataFormula || (b = s.value) != null && b.displayFormula), s.value && s.value.formatter === void 0 && m != null && m.value.timeFormatter && s.value.formatter === void 0 && (s.value.formatter = m == null ? void 0 : m.value.timeFormatter, s.value.timeFormatter = void 0), V.hasRowColumn && ((
|
|
733
|
+
) : void 0, M.value = m == null ? void 0 : m.index, y.value = !!((o = s.value) != null && o.dataFormula || (b = s.value) != null && b.displayFormula), s.value && s.value.formatter === void 0 && m != null && m.value.timeFormatter && s.value.formatter === void 0 && (s.value.formatter = m == null ? void 0 : m.value.timeFormatter, s.value.timeFormatter = void 0), V.hasRowColumn && ((N = V.config.rowIds) == null ? void 0 : N.includes(Ge.value)) === !0 && s.value && s.value.moveToRow === void 0 && (s.value.moveToRow = !0), s.value && (!V.hasXy || s.value.nullable === void 0) && (s.value.nullable = !1);
|
|
733
734
|
}
|
|
734
|
-
const s = le(void 0), y = le(!1),
|
|
735
|
+
const s = le(void 0), y = le(!1), k = F(
|
|
735
736
|
() => V.options.find(
|
|
736
737
|
(m) => {
|
|
737
738
|
var o, b;
|
|
@@ -745,20 +746,20 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
745
746
|
}
|
|
746
747
|
function p() {
|
|
747
748
|
var m, o;
|
|
748
|
-
if (
|
|
749
|
-
const b = (m =
|
|
749
|
+
if (a.value.length > 0) {
|
|
750
|
+
const b = (m = a.value[0]) == null ? void 0 : m.moveToRow;
|
|
750
751
|
if (typeof b == "boolean")
|
|
751
752
|
return b;
|
|
752
753
|
}
|
|
753
754
|
return ((o = V.config.rowIds) == null ? void 0 : o.includes(Ge.value)) === !0;
|
|
754
755
|
}
|
|
755
|
-
const r =
|
|
756
|
+
const r = F(
|
|
756
757
|
() => {
|
|
757
758
|
var m;
|
|
758
|
-
return U(
|
|
759
|
+
return U(k.value, (m = s.value) == null ? void 0 : m.aggregation);
|
|
759
760
|
}
|
|
760
761
|
);
|
|
761
|
-
|
|
762
|
+
Ce(r, (m) => {
|
|
762
763
|
s.value && (m ? s.value.decimal = typeof s.value.decimal != "number" ? 2 : s.value.decimal : s.value.decimal = void 0);
|
|
763
764
|
});
|
|
764
765
|
function B(m) {
|
|
@@ -767,7 +768,7 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
767
768
|
schemaName: m.schemaName,
|
|
768
769
|
name: m.name,
|
|
769
770
|
aggregation: m.aggregations[0],
|
|
770
|
-
label:
|
|
771
|
+
label: re(e, n, m.label, "other"),
|
|
771
772
|
nullable: !1,
|
|
772
773
|
decimal: U(m, m.aggregations[0]) ? 2 : void 0,
|
|
773
774
|
moveToRow: p(),
|
|
@@ -780,38 +781,41 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
780
781
|
if (s.value && (y.value || (s.value.dataFormula = void 0, s.value.displayFormula = void 0), V.hasXy || (s.value.nullable = !1), M.value !== void 0 ? m[M.value] = s.value : m.push(s.value)), V.hasRowColumn && typeof ((o = s.value) == null ? void 0 : o.moveToRow) == "boolean")
|
|
781
782
|
for (const b of m)
|
|
782
783
|
b.moveToRow = s.value.moveToRow;
|
|
783
|
-
|
|
784
|
+
a.value = m, g.value = !1;
|
|
784
785
|
}
|
|
785
|
-
function
|
|
786
|
+
function w(m) {
|
|
786
787
|
const o = [..._.value.map((b) => b.value)];
|
|
787
|
-
o.splice(m, 1),
|
|
788
|
+
o.splice(m, 1), a.value = o;
|
|
788
789
|
}
|
|
789
|
-
const u =
|
|
790
|
+
const u = F(
|
|
790
791
|
() => V.options.map((m) => ({
|
|
791
792
|
label: m.labels.join(" "),
|
|
792
793
|
value: m
|
|
793
794
|
}))
|
|
794
795
|
);
|
|
795
|
-
function
|
|
796
|
-
return [m.schemaName, m.name,
|
|
796
|
+
function j(m) {
|
|
797
|
+
return [m.schemaName, m.name, re(e, n, m.label, "other")].join(" ");
|
|
797
798
|
}
|
|
798
799
|
function Y(m) {
|
|
799
800
|
return [m.schemaName, m.name, m.aggregation, m.label || ""].join("__");
|
|
800
801
|
}
|
|
801
|
-
const d =
|
|
802
|
+
const d = F(() => {
|
|
802
803
|
var b;
|
|
803
804
|
const m = /* @__PURE__ */ new Map(), o = s.value ? Y(s.value) : "";
|
|
804
|
-
for (const
|
|
805
|
-
o && Y(
|
|
806
|
-
return s.value && m.set(
|
|
805
|
+
for (const N of ((b = V.config) == null ? void 0 : b.metrics) ?? [])
|
|
806
|
+
o && Y(N) === o || m.set(Ve(N), N);
|
|
807
|
+
return s.value && m.set(Ve(s.value), s.value), Array.from(m.values());
|
|
807
808
|
}), { formulaFieldDataList: t, allowedFormulaFields: A } = sl({
|
|
808
|
-
options:
|
|
809
|
-
primaryFields:
|
|
810
|
-
var m;
|
|
811
|
-
return
|
|
809
|
+
options: F(() => V.options),
|
|
810
|
+
primaryFields: F(() => {
|
|
811
|
+
var m, o;
|
|
812
|
+
return [
|
|
813
|
+
...((m = V.config) == null ? void 0 : m.dimensions) ?? [],
|
|
814
|
+
...(o = V.config) != null && o.breakdownDimension ? [V.config.breakdownDimension] : []
|
|
815
|
+
];
|
|
812
816
|
}),
|
|
813
817
|
secondaryFields: d,
|
|
814
|
-
getLabel:
|
|
818
|
+
getLabel: j
|
|
815
819
|
}), { dataValidation: z, displayValidation: J, isDataValidating: ie, isDisplayValidating: D } = rl({
|
|
816
820
|
getDataFormula: () => {
|
|
817
821
|
var m;
|
|
@@ -825,46 +829,46 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
825
829
|
getAllowedFields: () => A.value
|
|
826
830
|
});
|
|
827
831
|
return (m, o) => {
|
|
828
|
-
const b = L("FmTextField"),
|
|
832
|
+
const b = L("FmTextField"), N = L("FmStepperField"), oe = L("FmCheckbox"), se = L("FmForm"), me = L("FmIcon"), Q = L("FmButton"), Re = L("FmListItem"), _e = L("FmList"), Be = L("FmField");
|
|
829
833
|
return f(), E("div", vt, [
|
|
830
834
|
c(Pe, {
|
|
831
835
|
modelValue: g.value,
|
|
832
836
|
"onUpdate:modelValue": o[12] || (o[12] = (xe) => g.value = xe),
|
|
833
|
-
title:
|
|
837
|
+
title: C.value,
|
|
834
838
|
onConfirm: O
|
|
835
839
|
}, {
|
|
836
840
|
content: K(() => [
|
|
837
|
-
c(
|
|
841
|
+
c(se, {
|
|
838
842
|
ref: "form",
|
|
839
843
|
class: "flex flex-col gap-2 w-[490px]"
|
|
840
844
|
}, {
|
|
841
845
|
default: K(() => {
|
|
842
|
-
var xe, ye, he,
|
|
846
|
+
var xe, ye, he, Te;
|
|
843
847
|
return [
|
|
844
848
|
c(be, {
|
|
845
|
-
"model-value":
|
|
849
|
+
"model-value": k.value,
|
|
846
850
|
items: u.value,
|
|
847
|
-
placeholder:
|
|
848
|
-
label:
|
|
851
|
+
placeholder: C.value,
|
|
852
|
+
label: C.value,
|
|
849
853
|
"onUpdate:modelValue": o[0] || (o[0] = (Z) => B(Z))
|
|
850
854
|
}, null, 8, ["model-value", "items", "placeholder", "label"]),
|
|
851
|
-
s.value ? (f(), E(
|
|
855
|
+
s.value ? (f(), E(ue, { key: 0 }, [
|
|
852
856
|
c(b, {
|
|
853
857
|
modelValue: s.value.label,
|
|
854
858
|
"onUpdate:modelValue": o[1] || (o[1] = (Z) => s.value.label = Z),
|
|
855
859
|
label: l(e)("report.section.metric.label")
|
|
856
860
|
}, null, 8, ["modelValue", "label"]),
|
|
857
|
-
(((xe =
|
|
861
|
+
(((xe = k.value) == null ? void 0 : xe.aggregations) || []).length > 0 ? (f(), R(be, {
|
|
858
862
|
key: 0,
|
|
859
863
|
modelValue: s.value.aggregation,
|
|
860
864
|
"onUpdate:modelValue": o[2] || (o[2] = (Z) => s.value.aggregation = Z),
|
|
861
865
|
label: l(e)("report.section.metric.aggregation"),
|
|
862
|
-
items: ((ye =
|
|
863
|
-
label: l(
|
|
866
|
+
items: ((ye = k.value) == null ? void 0 : ye.aggregations.map((Z) => ({
|
|
867
|
+
label: l(n)(`report.section.metric.aggregationType.${Z}`) ? l(e)(`report.section.metric.aggregationType.${Z}`) : l(re)(l(e), l(n), Z, "field"),
|
|
864
868
|
value: Z
|
|
865
869
|
}))) ?? []
|
|
866
870
|
}, null, 8, ["modelValue", "label", "items"])) : I("", !0),
|
|
867
|
-
r.value ? (f(), R(
|
|
871
|
+
r.value ? (f(), R(N, {
|
|
868
872
|
key: 1,
|
|
869
873
|
label: l(e)("report.common.decimal"),
|
|
870
874
|
"model-value": ((he = s.value) == null ? void 0 : he.decimal) ?? 2,
|
|
@@ -880,19 +884,19 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
880
884
|
label: l(e)("report.section.metric.formatter"),
|
|
881
885
|
items: [
|
|
882
886
|
{ label: l(e)("report.section.metric.formatterType.NONE"), value: null },
|
|
883
|
-
...(((
|
|
884
|
-
label: l(
|
|
887
|
+
...(((Te = k.value) == null ? void 0 : Te.formatters) || []).map((Z) => ({
|
|
888
|
+
label: l(n)(`report.section.metric.formatterType.${Z}`) ? l(e)(`report.section.metric.formatterType.${Z}`) : l(re)(l(e), l(n), Z, "field"),
|
|
885
889
|
value: Z
|
|
886
890
|
}))
|
|
887
891
|
]
|
|
888
892
|
}, null, 8, ["modelValue", "placeholder", "label", "items"])) : I("", !0),
|
|
889
|
-
c(
|
|
893
|
+
c(oe, {
|
|
890
894
|
modelValue: s.value.hide,
|
|
891
895
|
"onUpdate:modelValue": o[5] || (o[5] = (Z) => s.value.hide = Z),
|
|
892
896
|
label: l(e)("report.section.metric.hide"),
|
|
893
897
|
value: ""
|
|
894
898
|
}, null, 8, ["modelValue", "label"]),
|
|
895
|
-
V.hasXy ? (f(), R(
|
|
899
|
+
V.hasXy ? (f(), R(oe, {
|
|
896
900
|
key: 3,
|
|
897
901
|
"model-value": s.value.nullable ?? !1,
|
|
898
902
|
label: l(e)("report.section.metric.nullable"),
|
|
@@ -901,7 +905,7 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
901
905
|
s.value && (s.value.nullable = Z);
|
|
902
906
|
})
|
|
903
907
|
}, null, 8, ["model-value", "label"])) : I("", !0),
|
|
904
|
-
V.hasRowColumn ? (f(), R(
|
|
908
|
+
V.hasRowColumn ? (f(), R(oe, {
|
|
905
909
|
key: 4,
|
|
906
910
|
"model-value": s.value.moveToRow ?? !1,
|
|
907
911
|
label: l(e)("report.section.metric.moveToRow"),
|
|
@@ -910,7 +914,7 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
910
914
|
s.value && (s.value.moveToRow = Array.isArray(Z) ? Z.length > 0 : Z);
|
|
911
915
|
})
|
|
912
916
|
}, null, 8, ["model-value", "label"])) : I("", !0),
|
|
913
|
-
V.hasRowColumn && V.hasPercentOfTotal ? (f(), R(
|
|
917
|
+
V.hasRowColumn && V.hasPercentOfTotal ? (f(), R(oe, {
|
|
914
918
|
key: 5,
|
|
915
919
|
"model-value": s.value.percentOfTotal ?? !1,
|
|
916
920
|
label: l(e)("report.section.metric.percentOfTotal"),
|
|
@@ -919,7 +923,7 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
919
923
|
s.value && (s.value.percentOfTotal = Array.isArray(Z) ? Z.length > 0 : Z);
|
|
920
924
|
})
|
|
921
925
|
}, null, 8, ["model-value", "label"])) : I("", !0),
|
|
922
|
-
c(
|
|
926
|
+
c(oe, {
|
|
923
927
|
modelValue: y.value,
|
|
924
928
|
"onUpdate:modelValue": o[9] || (o[9] = (Z) => y.value = Z),
|
|
925
929
|
label: l(e)("report.section.metric.advance"),
|
|
@@ -931,7 +935,7 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
931
935
|
"onUpdate:modelValue": o[10] || (o[10] = (Z) => s.value.dataFormula = Z),
|
|
932
936
|
placeholder: l(e)("report.section.metric.dataFormula"),
|
|
933
937
|
"field-data-list": l(t),
|
|
934
|
-
"formula-field": l(
|
|
938
|
+
"formula-field": l(je).Metric,
|
|
935
939
|
"validation-result": l(z),
|
|
936
940
|
"is-validating": l(ie),
|
|
937
941
|
"valid-formula-label": l(e)("report.common.validFormula")
|
|
@@ -942,7 +946,7 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
942
946
|
"onUpdate:modelValue": o[11] || (o[11] = (Z) => s.value.displayFormula = Z),
|
|
943
947
|
placeholder: l(e)("report.section.metric.displayFormula"),
|
|
944
948
|
"field-data-list": l(t),
|
|
945
|
-
"formula-field": l(
|
|
949
|
+
"formula-field": l(je).Metric,
|
|
946
950
|
"validation-result": l(J),
|
|
947
951
|
"is-validating": l(D),
|
|
948
952
|
"valid-formula-label": l(e)("report.common.validFormula")
|
|
@@ -956,30 +960,30 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
956
960
|
_: 1
|
|
957
961
|
}, 8, ["modelValue", "title"]),
|
|
958
962
|
h("div", null, [
|
|
959
|
-
h("p", ft, G(
|
|
963
|
+
h("p", ft, G(C.value), 1),
|
|
960
964
|
h("p", gt, G(l(e)("report.section.metric.description")), 1)
|
|
961
965
|
]),
|
|
962
|
-
c(
|
|
966
|
+
c(_e, null, {
|
|
963
967
|
default: K(() => [
|
|
964
968
|
c(l(Ke), {
|
|
965
|
-
list:
|
|
969
|
+
list: a.value,
|
|
966
970
|
"item-key": "id",
|
|
967
971
|
class: "flex flex-col gap-2 w-full"
|
|
968
972
|
}, {
|
|
969
973
|
item: K(({ element: xe, index: ye }) => [
|
|
970
974
|
c(Re, {
|
|
971
975
|
class: "!cursor-grab border rounded-md border-neutral-300 h-[40px] !p-[8px]",
|
|
972
|
-
onClick:
|
|
976
|
+
onClick: we((he) => i(_.value[ye]), ["stop"])
|
|
973
977
|
}, {
|
|
974
978
|
default: K(() => [
|
|
975
|
-
c(
|
|
976
|
-
h("p", yt, G(l(
|
|
979
|
+
c(me, { name: "drag_handle" }),
|
|
980
|
+
h("p", yt, G(l(re)(l(e), l(n), xe.label, "other")), 1),
|
|
977
981
|
o[14] || (o[14] = h("div", { class: "grow" }, null, -1)),
|
|
978
982
|
c(Q, {
|
|
979
983
|
icon: "close",
|
|
980
984
|
size: "md",
|
|
981
985
|
variant: "tertiary",
|
|
982
|
-
onClick:
|
|
986
|
+
onClick: we((he) => w(ye), ["stop"])
|
|
983
987
|
}, null, 8, ["onClick"])
|
|
984
988
|
]),
|
|
985
989
|
_: 2
|
|
@@ -1004,9 +1008,9 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1004
1008
|
]);
|
|
1005
1009
|
};
|
|
1006
1010
|
}
|
|
1007
|
-
}), ht = { class: "flex flex-col my-2 gap-8" },
|
|
1011
|
+
}), ht = { class: "flex flex-col my-2 gap-8" }, wt = { class: "fm-typo-en-body-lg-600" }, Ct = { class: "fm-typo-en-body-sm-600 text-fm-color-neutral-gray-400" }, xt = { class: "fm-typo-en-body-lg-400 text-ellipsis overflow-hidden line-clamp-1" }, kt = /* @__PURE__ */ de({
|
|
1008
1012
|
__name: "SortSection",
|
|
1009
|
-
props: /* @__PURE__ */
|
|
1013
|
+
props: /* @__PURE__ */ ve({
|
|
1010
1014
|
options: {
|
|
1011
1015
|
type: Array,
|
|
1012
1016
|
default: () => []
|
|
@@ -1015,6 +1019,10 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1015
1019
|
type: Array,
|
|
1016
1020
|
default: () => []
|
|
1017
1021
|
},
|
|
1022
|
+
breakdownDimension: {
|
|
1023
|
+
type: Object,
|
|
1024
|
+
default: void 0
|
|
1025
|
+
},
|
|
1018
1026
|
metrics: {
|
|
1019
1027
|
type: Array,
|
|
1020
1028
|
default: () => []
|
|
@@ -1029,31 +1037,31 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1029
1037
|
}),
|
|
1030
1038
|
emits: ["update:modelValue"],
|
|
1031
1039
|
setup($) {
|
|
1032
|
-
const { t: v, te: e } =
|
|
1033
|
-
() =>
|
|
1034
|
-
const A =
|
|
1040
|
+
const { t: v, te: e } = pe(), n = ge($, "modelValue"), a = $, V = F(() => v(`report.section.sort.${a.label}`)), C = le(!1), g = F(
|
|
1041
|
+
() => n.value.map((d, t) => {
|
|
1042
|
+
const A = a.options.find(
|
|
1035
1043
|
(J) => J.schemaName === d.schemaName && J.name === d.name
|
|
1036
1044
|
), z = (A == null ? void 0 : A.labels) || [d.schemaName, d.name];
|
|
1037
1045
|
return {
|
|
1038
1046
|
index: t,
|
|
1039
|
-
label: z.map((J) =>
|
|
1047
|
+
label: z.map((J) => re(v, e, J, "other")).join(" "),
|
|
1040
1048
|
value: d
|
|
1041
1049
|
};
|
|
1042
1050
|
})
|
|
1043
|
-
), _ = le(
|
|
1051
|
+
), _ = le(n.value.length > 0 ? 0 : void 0);
|
|
1044
1052
|
function M(d) {
|
|
1045
1053
|
var t;
|
|
1046
|
-
|
|
1054
|
+
C.value = !0, i.value = d != null && d.value ? JSON.parse(JSON.stringify(d.value)) : void 0, _.value = d == null ? void 0 : d.index, s.value = !!((t = i.value) != null && t.dataFormula);
|
|
1047
1055
|
}
|
|
1048
|
-
const i = le(void 0), s = le(!1), y =
|
|
1049
|
-
() =>
|
|
1056
|
+
const i = le(void 0), s = le(!1), y = F(
|
|
1057
|
+
() => a.options.find(
|
|
1050
1058
|
(d) => {
|
|
1051
1059
|
var t, A;
|
|
1052
1060
|
return d.schemaName === ((t = i.value) == null ? void 0 : t.schemaName) && d.name === ((A = i.value) == null ? void 0 : A.name);
|
|
1053
1061
|
}
|
|
1054
1062
|
) ?? {}
|
|
1055
1063
|
);
|
|
1056
|
-
function
|
|
1064
|
+
function k(d) {
|
|
1057
1065
|
var t, A;
|
|
1058
1066
|
(d.schemaName !== ((t = i.value) == null ? void 0 : t.schemaName) || d.name !== ((A = i.value) == null ? void 0 : A.name)) && (i.value = {
|
|
1059
1067
|
schemaName: d.schemaName,
|
|
@@ -1069,31 +1077,34 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1069
1077
|
return;
|
|
1070
1078
|
}
|
|
1071
1079
|
const d = [...g.value.map((t) => t.value)];
|
|
1072
|
-
s.value || (i.value.dataFormula = void 0), _.value !== void 0 ? d[_.value] = i.value : d.push(i.value),
|
|
1080
|
+
s.value || (i.value.dataFormula = void 0), _.value !== void 0 ? d[_.value] = i.value : d.push(i.value), n.value = d, C.value = !1;
|
|
1073
1081
|
}
|
|
1074
1082
|
function p(d) {
|
|
1075
1083
|
const t = [...g.value.map((A) => A.value)];
|
|
1076
|
-
t.splice(d, 1),
|
|
1084
|
+
t.splice(d, 1), n.value = t, C.value = !1;
|
|
1077
1085
|
}
|
|
1078
1086
|
function r(d) {
|
|
1079
1087
|
const t = `report.section.filter.${Oe(d)}`;
|
|
1080
|
-
return e(t) ? v(t) :
|
|
1088
|
+
return e(t) ? v(t) : re(v, e, d, "field");
|
|
1081
1089
|
}
|
|
1082
|
-
const B =
|
|
1083
|
-
() =>
|
|
1090
|
+
const B = F(
|
|
1091
|
+
() => a.options.map((d) => ({
|
|
1084
1092
|
label: d.labels.join(" "),
|
|
1085
1093
|
value: d
|
|
1086
1094
|
}))
|
|
1087
1095
|
);
|
|
1088
1096
|
function O(d) {
|
|
1089
|
-
return [d.schemaName, d.name,
|
|
1090
|
-
}
|
|
1091
|
-
const { formulaFieldDataList:
|
|
1092
|
-
options:
|
|
1093
|
-
primaryFields:
|
|
1094
|
-
|
|
1097
|
+
return [d.schemaName, d.name, re(v, e, d.label, "other")].join(" ");
|
|
1098
|
+
}
|
|
1099
|
+
const { formulaFieldDataList: w, allowedFormulaFields: u } = sl({
|
|
1100
|
+
options: F(() => a.options),
|
|
1101
|
+
primaryFields: F(() => [
|
|
1102
|
+
...a.dimensions,
|
|
1103
|
+
...a.breakdownDimension ? [a.breakdownDimension] : []
|
|
1104
|
+
]),
|
|
1105
|
+
secondaryFields: F(() => a.metrics),
|
|
1095
1106
|
getLabel: O
|
|
1096
|
-
}), { dataValidation:
|
|
1107
|
+
}), { dataValidation: j, isDataValidating: Y } = rl({
|
|
1097
1108
|
getDataFormula: () => {
|
|
1098
1109
|
var d;
|
|
1099
1110
|
return (d = i.value) == null ? void 0 : d.dataFormula;
|
|
@@ -1107,8 +1118,8 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1107
1118
|
const A = L("FmCheckbox"), z = L("FmForm"), J = L("FmIcon"), ie = L("FmButton"), D = L("FmListItem"), m = L("FmList"), o = L("FmField");
|
|
1108
1119
|
return f(), E("div", ht, [
|
|
1109
1120
|
c(Pe, {
|
|
1110
|
-
modelValue:
|
|
1111
|
-
"onUpdate:modelValue": t[6] || (t[6] = (b) =>
|
|
1121
|
+
modelValue: C.value,
|
|
1122
|
+
"onUpdate:modelValue": t[6] || (t[6] = (b) => C.value = b),
|
|
1112
1123
|
title: V.value,
|
|
1113
1124
|
onConfirm: U
|
|
1114
1125
|
}, {
|
|
@@ -1118,32 +1129,32 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1118
1129
|
class: "flex flex-col gap-2 w-[490px]"
|
|
1119
1130
|
}, {
|
|
1120
1131
|
default: K(() => {
|
|
1121
|
-
var b,
|
|
1132
|
+
var b, N, oe, se, me;
|
|
1122
1133
|
return [
|
|
1123
1134
|
c(be, {
|
|
1124
1135
|
"model-value": y.value,
|
|
1125
1136
|
items: B.value,
|
|
1126
1137
|
placeholder: V.value,
|
|
1127
1138
|
label: V.value,
|
|
1128
|
-
"onUpdate:modelValue": t[0] || (t[0] = (Q) =>
|
|
1139
|
+
"onUpdate:modelValue": t[0] || (t[0] = (Q) => k(Q))
|
|
1129
1140
|
}, null, 8, ["model-value", "items", "placeholder", "label"]),
|
|
1130
|
-
i.value ? (f(), E(
|
|
1141
|
+
i.value ? (f(), E(ue, { key: 0 }, [
|
|
1131
1142
|
(((b = y.value) == null ? void 0 : b.dimensionOptions) || []).length > 0 ? (f(), R(be, {
|
|
1132
1143
|
key: 0,
|
|
1133
1144
|
modelValue: i.value.dimensionOption,
|
|
1134
1145
|
"onUpdate:modelValue": t[1] || (t[1] = (Q) => i.value.dimensionOption = Q),
|
|
1135
|
-
items: ((
|
|
1146
|
+
items: ((N = y.value) == null ? void 0 : N.dimensionOptions.map((Q) => ({
|
|
1136
1147
|
label: r(Q),
|
|
1137
1148
|
value: Q
|
|
1138
1149
|
}))) ?? [],
|
|
1139
1150
|
placeholder: l(v)("report.section.sort.format"),
|
|
1140
1151
|
label: l(v)("report.section.sort.format")
|
|
1141
1152
|
}, null, 8, ["modelValue", "items", "placeholder", "label"])) : I("", !0),
|
|
1142
|
-
(((
|
|
1153
|
+
(((oe = y.value) == null ? void 0 : oe.aggregations) || []).length > 0 ? (f(), R(be, {
|
|
1143
1154
|
key: 1,
|
|
1144
1155
|
modelValue: i.value.aggregation,
|
|
1145
1156
|
"onUpdate:modelValue": t[2] || (t[2] = (Q) => i.value.aggregation = Q),
|
|
1146
|
-
items: ((
|
|
1157
|
+
items: ((se = y.value) == null ? void 0 : se.aggregations.map((Q) => ({
|
|
1147
1158
|
label: l(e)(`report.section.metric.aggregationType.${Q}`) ? l(v)(`report.section.metric.aggregationType.${Q}`) : Q,
|
|
1148
1159
|
value: Q
|
|
1149
1160
|
}))) ?? [],
|
|
@@ -1171,9 +1182,9 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1171
1182
|
modelValue: i.value.dataFormula,
|
|
1172
1183
|
"onUpdate:modelValue": t[5] || (t[5] = (Q) => i.value.dataFormula = Q),
|
|
1173
1184
|
placeholder: l(v)("report.section.sort.dataFormula"),
|
|
1174
|
-
"field-data-list": l(
|
|
1175
|
-
"formula-field": ((
|
|
1176
|
-
"validation-result": l(
|
|
1185
|
+
"field-data-list": l(w),
|
|
1186
|
+
"formula-field": ((me = y.value) == null ? void 0 : me.type) === "NUMERIC" ? l(je).Metric : l(je).Dimension,
|
|
1187
|
+
"validation-result": l(j),
|
|
1177
1188
|
"is-validating": l(Y),
|
|
1178
1189
|
"valid-formula-label": l(v)("report.common.validFormula")
|
|
1179
1190
|
}, null, 8, ["modelValue", "placeholder", "field-data-list", "formula-field", "validation-result", "is-validating", "valid-formula-label"])) : I("", !0)
|
|
@@ -1186,30 +1197,30 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1186
1197
|
_: 1
|
|
1187
1198
|
}, 8, ["modelValue", "title"]),
|
|
1188
1199
|
h("div", null, [
|
|
1189
|
-
h("p",
|
|
1190
|
-
h("p",
|
|
1200
|
+
h("p", wt, G(V.value), 1),
|
|
1201
|
+
h("p", Ct, G(l(v)("report.section.sort.description")), 1)
|
|
1191
1202
|
]),
|
|
1192
1203
|
c(m, null, {
|
|
1193
1204
|
default: K(() => [
|
|
1194
1205
|
c(l(Ke), {
|
|
1195
|
-
list:
|
|
1206
|
+
list: n.value,
|
|
1196
1207
|
"item-key": "id",
|
|
1197
1208
|
class: "flex flex-col gap-2 w-full"
|
|
1198
1209
|
}, {
|
|
1199
|
-
item: K(({ element: b, index:
|
|
1210
|
+
item: K(({ element: b, index: N }) => [
|
|
1200
1211
|
c(D, {
|
|
1201
1212
|
class: "!cursor-grab border rounded-md border-neutral-300 h-[40px] !p-[8px]",
|
|
1202
|
-
onClick:
|
|
1213
|
+
onClick: we((oe) => M(g.value[N]), ["stop"])
|
|
1203
1214
|
}, {
|
|
1204
1215
|
default: K(() => [
|
|
1205
1216
|
c(J, { name: "drag_handle" }),
|
|
1206
|
-
h("p", xt, G(g.value[
|
|
1217
|
+
h("p", xt, G(g.value[N].label), 1),
|
|
1207
1218
|
t[8] || (t[8] = h("div", { class: "grow" }, null, -1)),
|
|
1208
1219
|
c(ie, {
|
|
1209
1220
|
icon: "close",
|
|
1210
1221
|
size: "md",
|
|
1211
1222
|
variant: "tertiary",
|
|
1212
|
-
onClick:
|
|
1223
|
+
onClick: we((oe) => p(N), ["stop"])
|
|
1213
1224
|
}, null, 8, ["onClick"])
|
|
1214
1225
|
]),
|
|
1215
1226
|
_: 2
|
|
@@ -1234,7 +1245,7 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1234
1245
|
]);
|
|
1235
1246
|
};
|
|
1236
1247
|
}
|
|
1237
|
-
}),
|
|
1248
|
+
}), Ft = { class: "fm-typo-en-body-lg-600" }, Vt = { class: "fm-typo-en-body-sm-600 text-fm-color-neutral-gray-400" }, St = /* @__PURE__ */ de({
|
|
1238
1249
|
__name: "LimitSection",
|
|
1239
1250
|
props: {
|
|
1240
1251
|
modelValue: { required: !0, default: null },
|
|
@@ -1242,28 +1253,28 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1242
1253
|
},
|
|
1243
1254
|
emits: ["update:modelValue"],
|
|
1244
1255
|
setup($) {
|
|
1245
|
-
const { t: v } =
|
|
1246
|
-
|
|
1256
|
+
const { t: v } = pe(), e = ge($, "modelValue"), n = qe((a) => {
|
|
1257
|
+
a !== "" ? e.value = a : e.value = null;
|
|
1247
1258
|
}, 1e3);
|
|
1248
|
-
return (
|
|
1249
|
-
const
|
|
1250
|
-
return f(), E(
|
|
1259
|
+
return (a, V) => {
|
|
1260
|
+
const C = L("FmTextField");
|
|
1261
|
+
return f(), E(ue, null, [
|
|
1251
1262
|
h("div", null, [
|
|
1252
|
-
h("p",
|
|
1263
|
+
h("p", Ft, G(l(v)("report.section.limit.title")), 1),
|
|
1253
1264
|
h("p", Vt, G(l(v)("report.section.limit.description")), 1)
|
|
1254
1265
|
]),
|
|
1255
|
-
c(
|
|
1266
|
+
c(C, {
|
|
1256
1267
|
"model-value": e.value,
|
|
1257
1268
|
inputmode: "numeric",
|
|
1258
1269
|
placeholder: l(v)("report.section.limit.placeholder"),
|
|
1259
|
-
"onUpdate:modelValue": V[0] || (V[0] = (g) => l(
|
|
1270
|
+
"onUpdate:modelValue": V[0] || (V[0] = (g) => l(n)(g))
|
|
1260
1271
|
}, null, 8, ["model-value", "placeholder"])
|
|
1261
1272
|
], 64);
|
|
1262
1273
|
};
|
|
1263
1274
|
}
|
|
1264
|
-
}), _t = { class: "flex flex-col my-2 gap-8" }, Tt = { class: "fm-typo-en-body-lg-600" }, $t = { class: "fm-typo-en-body-sm-600 text-fm-color-neutral-gray-400" }, Dt = { class: "fm-typo-en-body-lg-400 text-ellipsis overflow-hidden line-clamp-1" }, Ut = /* @__PURE__ */
|
|
1275
|
+
}), _t = { class: "flex flex-col my-2 gap-8" }, Tt = { class: "fm-typo-en-body-lg-600" }, $t = { class: "fm-typo-en-body-sm-600 text-fm-color-neutral-gray-400" }, Dt = { class: "fm-typo-en-body-lg-400 text-ellipsis overflow-hidden line-clamp-1" }, Ut = /* @__PURE__ */ de({
|
|
1265
1276
|
__name: "ConditionSection",
|
|
1266
|
-
props: /* @__PURE__ */
|
|
1277
|
+
props: /* @__PURE__ */ ve({
|
|
1267
1278
|
joinFieldOptions: {
|
|
1268
1279
|
type: Array,
|
|
1269
1280
|
default: () => []
|
|
@@ -1282,73 +1293,73 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1282
1293
|
}),
|
|
1283
1294
|
emits: ["update:modelValue"],
|
|
1284
1295
|
setup($) {
|
|
1285
|
-
const { t: v, te: e } =
|
|
1286
|
-
() =>
|
|
1296
|
+
const { t: v, te: e } = pe(), n = ge($, "modelValue"), a = $, V = F(() => v(`report.section.condition.${a.label}`)), C = le(!1), g = F(
|
|
1297
|
+
() => n.value.map((w, u) => {
|
|
1287
1298
|
var d, t;
|
|
1288
|
-
const
|
|
1299
|
+
const j = a.joinFieldOptions.find(
|
|
1289
1300
|
(A) => {
|
|
1290
1301
|
var z, J;
|
|
1291
|
-
return A.schemaName === ((z =
|
|
1302
|
+
return A.schemaName === ((z = w.joinDimension) == null ? void 0 : z.schemaName) && A.name === ((J = w.joinDimension) == null ? void 0 : J.name);
|
|
1292
1303
|
}
|
|
1293
|
-
), Y = (
|
|
1294
|
-
(d =
|
|
1295
|
-
(t =
|
|
1304
|
+
), Y = (j == null ? void 0 : j.labels) || [
|
|
1305
|
+
(d = w.joinDimension) == null ? void 0 : d.schemaName,
|
|
1306
|
+
(t = w.joinDimension) == null ? void 0 : t.name
|
|
1296
1307
|
];
|
|
1297
1308
|
return {
|
|
1298
1309
|
index: u,
|
|
1299
|
-
label: Y.map((A) =>
|
|
1300
|
-
value:
|
|
1310
|
+
label: Y.map((A) => re(v, e, A, "other")).join(" "),
|
|
1311
|
+
value: w
|
|
1301
1312
|
};
|
|
1302
1313
|
})
|
|
1303
|
-
), _ = le(
|
|
1304
|
-
function M(
|
|
1305
|
-
|
|
1314
|
+
), _ = le(n.value.length > 0 ? 0 : void 0);
|
|
1315
|
+
function M(w) {
|
|
1316
|
+
w ? (i.value = w != null && w.value ? JSON.parse(JSON.stringify(w.value)) : void 0, _.value = w == null ? void 0 : w.index) : (i.value = {
|
|
1306
1317
|
joinDimension: null,
|
|
1307
1318
|
operator: "",
|
|
1308
1319
|
mainDimensions: []
|
|
1309
|
-
}, _.value = void 0),
|
|
1320
|
+
}, _.value = void 0), C.value = !0;
|
|
1310
1321
|
}
|
|
1311
|
-
const i = le(void 0), s =
|
|
1312
|
-
() =>
|
|
1313
|
-
(
|
|
1314
|
-
var u,
|
|
1315
|
-
return
|
|
1322
|
+
const i = le(void 0), s = F(
|
|
1323
|
+
() => a.joinFieldOptions.find(
|
|
1324
|
+
(w) => {
|
|
1325
|
+
var u, j;
|
|
1326
|
+
return w.schemaName === ((j = (u = i.value) == null ? void 0 : u.joinDimension) == null ? void 0 : j.schemaName) && w.name === i.value.joinDimension.name;
|
|
1316
1327
|
}
|
|
1317
1328
|
) ?? {}
|
|
1318
|
-
), y =
|
|
1329
|
+
), y = F(
|
|
1319
1330
|
() => {
|
|
1320
|
-
var
|
|
1321
|
-
return (((
|
|
1322
|
-
(u) =>
|
|
1323
|
-
(
|
|
1331
|
+
var w;
|
|
1332
|
+
return (((w = i.value) == null ? void 0 : w.mainDimensions) || []).map(
|
|
1333
|
+
(u) => a.mainFieldOptions.find(
|
|
1334
|
+
(j) => j.schemaName === (u == null ? void 0 : u.schemaName) && j.name === u.name
|
|
1324
1335
|
) ?? {}
|
|
1325
1336
|
);
|
|
1326
1337
|
}
|
|
1327
|
-
),
|
|
1328
|
-
() =>
|
|
1338
|
+
), k = F(
|
|
1339
|
+
() => a.joinFieldOptions.map((w) => ({ label: w.labels.join(" "), value: w }))
|
|
1329
1340
|
);
|
|
1330
|
-
function U(
|
|
1331
|
-
var u,
|
|
1332
|
-
i.value && (i.value &&
|
|
1341
|
+
function U(w) {
|
|
1342
|
+
var u, j, Y, d;
|
|
1343
|
+
i.value && (i.value && w.schemaName !== ((j = (u = i.value) == null ? void 0 : u.joinDimension) == null ? void 0 : j.schemaName) || w.name !== ((d = (Y = i.value) == null ? void 0 : Y.joinDimension) == null ? void 0 : d.name)) && (i.value = {
|
|
1333
1344
|
...i.value,
|
|
1334
1345
|
joinDimension: {
|
|
1335
|
-
schemaName:
|
|
1336
|
-
name:
|
|
1337
|
-
option:
|
|
1338
|
-
label: `_${
|
|
1346
|
+
schemaName: w.schemaName,
|
|
1347
|
+
name: w.name,
|
|
1348
|
+
option: w.dimensionOptions[0],
|
|
1349
|
+
label: `_${w.label}`,
|
|
1339
1350
|
hide: !0
|
|
1340
1351
|
}
|
|
1341
|
-
},
|
|
1352
|
+
}, w.joinConditionOperators.includes(i.value.operator) || r(w.joinConditionOperators[0]));
|
|
1342
1353
|
}
|
|
1343
|
-
function p(
|
|
1344
|
-
var
|
|
1345
|
-
if (i.value && u >= 0 && (i.value &&
|
|
1354
|
+
function p(w, u) {
|
|
1355
|
+
var j, Y, d, t;
|
|
1356
|
+
if (i.value && u >= 0 && (i.value && w.schemaName !== ((Y = (j = i.value) == null ? void 0 : j.mainDimensions[u]) == null ? void 0 : Y.schemaName) || w.name !== ((t = (d = i.value) == null ? void 0 : d.mainDimensions[u]) == null ? void 0 : t.name))) {
|
|
1346
1357
|
const A = [...i.value.mainDimensions];
|
|
1347
1358
|
A[u] = {
|
|
1348
|
-
schemaName:
|
|
1349
|
-
name:
|
|
1350
|
-
option:
|
|
1351
|
-
label:
|
|
1359
|
+
schemaName: w.schemaName,
|
|
1360
|
+
name: w.name,
|
|
1361
|
+
option: w.dimensionOptions[0],
|
|
1362
|
+
label: w.label,
|
|
1352
1363
|
hide: !0
|
|
1353
1364
|
}, i.value = {
|
|
1354
1365
|
...i.value,
|
|
@@ -1356,41 +1367,41 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1356
1367
|
};
|
|
1357
1368
|
}
|
|
1358
1369
|
}
|
|
1359
|
-
function r(
|
|
1370
|
+
function r(w) {
|
|
1360
1371
|
if (i.value)
|
|
1361
|
-
switch (
|
|
1372
|
+
switch (w) {
|
|
1362
1373
|
case Yl.Between:
|
|
1363
1374
|
i.value = {
|
|
1364
1375
|
...i.value,
|
|
1365
|
-
operator:
|
|
1376
|
+
operator: w,
|
|
1366
1377
|
mainDimensions: [null, null]
|
|
1367
1378
|
};
|
|
1368
1379
|
break;
|
|
1369
1380
|
default:
|
|
1370
1381
|
i.value = {
|
|
1371
1382
|
...i.value,
|
|
1372
|
-
operator:
|
|
1383
|
+
operator: w,
|
|
1373
1384
|
mainDimensions: [null]
|
|
1374
1385
|
};
|
|
1375
1386
|
break;
|
|
1376
1387
|
}
|
|
1377
1388
|
}
|
|
1378
1389
|
function B() {
|
|
1379
|
-
const
|
|
1390
|
+
const w = [...g.value.map((u) => u.value)];
|
|
1380
1391
|
i.value && (i.value.mainDimensions = i.value.mainDimensions.filter(
|
|
1381
1392
|
(u) => u !== "" && u != null
|
|
1382
|
-
), _.value !== void 0 ?
|
|
1393
|
+
), _.value !== void 0 ? w[_.value] = i.value : w.push(i.value)), n.value = w, C.value = !1;
|
|
1383
1394
|
}
|
|
1384
|
-
function O(
|
|
1385
|
-
const u = [...g.value.map((
|
|
1386
|
-
u.splice(
|
|
1395
|
+
function O(w) {
|
|
1396
|
+
const u = [...g.value.map((j) => j.value)];
|
|
1397
|
+
u.splice(w, 1), n.value = u;
|
|
1387
1398
|
}
|
|
1388
|
-
return (
|
|
1389
|
-
const
|
|
1399
|
+
return (w, u) => {
|
|
1400
|
+
const j = L("FmMenuDivider"), Y = L("FmForm"), d = L("FmIcon"), t = L("FmButton"), A = L("FmListItem"), z = L("FmList"), J = L("FmField");
|
|
1390
1401
|
return f(), E("div", _t, [
|
|
1391
1402
|
c(Pe, {
|
|
1392
|
-
modelValue:
|
|
1393
|
-
"onUpdate:modelValue": u[2] || (u[2] = (ie) =>
|
|
1403
|
+
modelValue: C.value,
|
|
1404
|
+
"onUpdate:modelValue": u[2] || (u[2] = (ie) => C.value = ie),
|
|
1394
1405
|
title: V.value,
|
|
1395
1406
|
onConfirm: B
|
|
1396
1407
|
}, {
|
|
@@ -1405,56 +1416,56 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1405
1416
|
c(be, {
|
|
1406
1417
|
label: l(v)("report.section.condition.joinDatasource"),
|
|
1407
1418
|
"model-value": s.value,
|
|
1408
|
-
items:
|
|
1419
|
+
items: k.value,
|
|
1409
1420
|
placeholder: l(v)("report.section.condition.joinDimension"),
|
|
1410
|
-
"onUpdate:modelValue": u[0] || (u[0] = (
|
|
1421
|
+
"onUpdate:modelValue": u[0] || (u[0] = (N) => U(N))
|
|
1411
1422
|
}, null, 8, ["label", "model-value", "items", "placeholder"]),
|
|
1412
|
-
c(
|
|
1423
|
+
c(j),
|
|
1413
1424
|
(ie = i.value) != null && ie.joinDimension && (((D = s.value) == null ? void 0 : D.dimensionOptions) || []).length > 0 ? (f(), R(be, {
|
|
1414
1425
|
key: 0,
|
|
1415
1426
|
modelValue: i.value.joinDimension.option,
|
|
1416
|
-
"onUpdate:modelValue": u[1] || (u[1] = (
|
|
1427
|
+
"onUpdate:modelValue": u[1] || (u[1] = (N) => i.value.joinDimension.option = N),
|
|
1417
1428
|
label: l(v)("report.section.condition.format"),
|
|
1418
|
-
items: ((m = s.value) == null ? void 0 : m.dimensionOptions.map((
|
|
1419
|
-
label: l(e)(`report.section.filter.${l(Oe)(
|
|
1420
|
-
value:
|
|
1429
|
+
items: ((m = s.value) == null ? void 0 : m.dimensionOptions.map((N) => ({
|
|
1430
|
+
label: l(e)(`report.section.filter.${l(Oe)(N)}`) ? l(v)(`report.section.filter.${l(Oe)(N)}`) : N,
|
|
1431
|
+
value: N
|
|
1421
1432
|
}))) ?? []
|
|
1422
1433
|
}, null, 8, ["modelValue", "label", "items"])) : I("", !0),
|
|
1423
1434
|
i.value && (((o = s.value) == null ? void 0 : o.joinConditionOperators) || []).length > 0 ? (f(), R(be, {
|
|
1424
1435
|
key: 1,
|
|
1425
1436
|
"model-value": i.value.operator,
|
|
1426
1437
|
label: l(v)("report.section.condition.operator"),
|
|
1427
|
-
items: s.value.joinConditionOperators.map((
|
|
1428
|
-
label: l(v)("report.section.comparisonOperator." +
|
|
1429
|
-
value:
|
|
1438
|
+
items: s.value.joinConditionOperators.map((N) => ({
|
|
1439
|
+
label: l(v)("report.section.comparisonOperator." + N),
|
|
1440
|
+
value: N
|
|
1430
1441
|
})) ?? [],
|
|
1431
1442
|
"onUpdate:modelValue": r
|
|
1432
1443
|
}, null, 8, ["model-value", "label", "items"])) : I("", !0),
|
|
1433
|
-
(f(!0), E(
|
|
1434
|
-
var
|
|
1444
|
+
(f(!0), E(ue, null, Se(((b = i.value) == null ? void 0 : b.mainDimensions) || [], (N, oe) => {
|
|
1445
|
+
var se, me;
|
|
1435
1446
|
return f(), E("div", {
|
|
1436
|
-
key:
|
|
1447
|
+
key: oe,
|
|
1437
1448
|
class: "flex flex-col gap-2"
|
|
1438
1449
|
}, [
|
|
1439
1450
|
c(be, {
|
|
1440
|
-
"model-value": y.value[
|
|
1441
|
-
label: l(v)("report.section.condition.mainDatasource", { index:
|
|
1442
|
-
items:
|
|
1451
|
+
"model-value": y.value[oe],
|
|
1452
|
+
label: l(v)("report.section.condition.mainDatasource", { index: oe + 1 }),
|
|
1453
|
+
items: a.mainFieldOptions.map((Q) => ({
|
|
1443
1454
|
label: Q.labels.join(" "),
|
|
1444
1455
|
value: Q
|
|
1445
1456
|
})),
|
|
1446
|
-
"onUpdate:modelValue": (Q) => p(Q,
|
|
1457
|
+
"onUpdate:modelValue": (Q) => p(Q, oe)
|
|
1447
1458
|
}, null, 8, ["model-value", "label", "items", "onUpdate:modelValue"]),
|
|
1448
|
-
|
|
1459
|
+
N && (((se = y.value[oe]) == null ? void 0 : se.dimensionOptions) || []).length > 0 && N ? (f(), R(be, {
|
|
1449
1460
|
key: 0,
|
|
1450
|
-
modelValue:
|
|
1451
|
-
"onUpdate:modelValue": (Q) =>
|
|
1452
|
-
items: (
|
|
1461
|
+
modelValue: N.option,
|
|
1462
|
+
"onUpdate:modelValue": (Q) => N.option = Q,
|
|
1463
|
+
items: (me = y.value[oe]) == null ? void 0 : me.dimensionOptions.map((Q) => ({
|
|
1453
1464
|
label: l(e)(`report.section.filter.${l(Oe)(Q)}`) ? l(v)(`report.section.filter.${l(Oe)(Q)}`) : Q,
|
|
1454
1465
|
value: Q
|
|
1455
1466
|
}))
|
|
1456
1467
|
}, null, 8, ["modelValue", "onUpdate:modelValue", "items"])) : I("", !0),
|
|
1457
|
-
c(
|
|
1468
|
+
c(j)
|
|
1458
1469
|
]);
|
|
1459
1470
|
}), 128))
|
|
1460
1471
|
];
|
|
@@ -1471,7 +1482,7 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1471
1482
|
c(z, { class: "flex flex-col gap-2" }, {
|
|
1472
1483
|
default: K(() => [
|
|
1473
1484
|
c(l(Ke), {
|
|
1474
|
-
list:
|
|
1485
|
+
list: n.value,
|
|
1475
1486
|
"item-key": (ie) => {
|
|
1476
1487
|
var D, m;
|
|
1477
1488
|
return `${(D = ie.joinDimension) == null ? void 0 : D.schemaName}:${(m = ie.joinDimension) == null ? void 0 : m.name}`;
|
|
@@ -1484,7 +1495,7 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1484
1495
|
}) => [
|
|
1485
1496
|
c(A, {
|
|
1486
1497
|
class: "!cursor-grab border rounded-md border-neutral-300 h-[40px] !p-[8px]",
|
|
1487
|
-
onClick:
|
|
1498
|
+
onClick: we((m) => M(g.value[D]), ["stop"])
|
|
1488
1499
|
}, {
|
|
1489
1500
|
default: K(() => [
|
|
1490
1501
|
c(d, { name: "drag_handle" }),
|
|
@@ -1494,7 +1505,7 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1494
1505
|
icon: "close",
|
|
1495
1506
|
size: "md",
|
|
1496
1507
|
variant: "tertiary",
|
|
1497
|
-
onClick:
|
|
1508
|
+
onClick: we((m) => O(D), ["stop"])
|
|
1498
1509
|
}, null, 8, ["onClick"])
|
|
1499
1510
|
]),
|
|
1500
1511
|
_: 2
|
|
@@ -1517,9 +1528,9 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1517
1528
|
]);
|
|
1518
1529
|
};
|
|
1519
1530
|
}
|
|
1520
|
-
}), bl = /* @__PURE__ */
|
|
1531
|
+
}), bl = /* @__PURE__ */ de({
|
|
1521
1532
|
__name: "Datasource",
|
|
1522
|
-
props: /* @__PURE__ */
|
|
1533
|
+
props: /* @__PURE__ */ ve({
|
|
1523
1534
|
label: {
|
|
1524
1535
|
type: String,
|
|
1525
1536
|
default: "Label"
|
|
@@ -1546,10 +1557,10 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1546
1557
|
modelValue: { required: !0 },
|
|
1547
1558
|
modelModifiers: {}
|
|
1548
1559
|
}),
|
|
1549
|
-
emits: /* @__PURE__ */
|
|
1560
|
+
emits: /* @__PURE__ */ ve(["click-close"], ["update:modelValue"]),
|
|
1550
1561
|
setup($, { emit: v }) {
|
|
1551
1562
|
const e = ge($, "modelValue");
|
|
1552
|
-
|
|
1563
|
+
Ce(
|
|
1553
1564
|
[() => e.value.dimensions, () => e.value.metrics],
|
|
1554
1565
|
() => {
|
|
1555
1566
|
const { rowIds: d, columnIds: t } = Ye(e.value);
|
|
@@ -1557,15 +1568,15 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1557
1568
|
},
|
|
1558
1569
|
{ deep: !0 }
|
|
1559
1570
|
);
|
|
1560
|
-
const
|
|
1571
|
+
const n = $, a = v, { schemas: V } = Ne(kl()), { editingReport: C } = Ne(Fl()), g = F(() => {
|
|
1561
1572
|
var d;
|
|
1562
|
-
return ((d =
|
|
1563
|
-
}), { t: _, te: M, locale: i } =
|
|
1564
|
-
() => [q.BarChart, q.LineChart, q.Scorecard].includes(
|
|
1565
|
-
),
|
|
1573
|
+
return ((d = C.value) == null ? void 0 : d.queryVersion) === "v2";
|
|
1574
|
+
}), { t: _, te: M, locale: i } = pe(), s = F(() => !n.mainDatasourceConfig), y = F(
|
|
1575
|
+
() => [q.BarChart, q.LineChart, q.Scorecard].includes(n.config.type)
|
|
1576
|
+
), k = F(() => [...e.value.dimensions].filter((d) => !d.hide)), U = F(() => n.config.type === q.Scorecard), p = F(
|
|
1566
1577
|
() => {
|
|
1567
1578
|
var d;
|
|
1568
|
-
return (((d =
|
|
1579
|
+
return (((d = n.mainDatasourceConfig) == null ? void 0 : d.schemaNames) || []).reduce(
|
|
1569
1580
|
(t, A) => {
|
|
1570
1581
|
const z = V.value.find((J) => J.name === A);
|
|
1571
1582
|
return z && (t = [
|
|
@@ -1573,8 +1584,8 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1573
1584
|
...z.fields.map((J) => ({
|
|
1574
1585
|
...J,
|
|
1575
1586
|
labels: [
|
|
1576
|
-
|
|
1577
|
-
|
|
1587
|
+
re(_, M, z.label, "schema"),
|
|
1588
|
+
re(_, M, J.label || J.name, "other")
|
|
1578
1589
|
]
|
|
1579
1590
|
}))
|
|
1580
1591
|
]), t;
|
|
@@ -1582,7 +1593,7 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1582
1593
|
[]
|
|
1583
1594
|
);
|
|
1584
1595
|
}
|
|
1585
|
-
), r =
|
|
1596
|
+
), r = F(
|
|
1586
1597
|
() => e.value.schemaNames.reduce((d, t) => {
|
|
1587
1598
|
const A = V.value.find((z) => z.name === t);
|
|
1588
1599
|
return A && (d = [
|
|
@@ -1590,20 +1601,20 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1590
1601
|
...A.fields.map((z) => ({
|
|
1591
1602
|
...z,
|
|
1592
1603
|
labels: [
|
|
1593
|
-
|
|
1594
|
-
|
|
1604
|
+
re(_, M, A.label, "schema"),
|
|
1605
|
+
re(_, M, z.label || z.name, "other")
|
|
1595
1606
|
]
|
|
1596
1607
|
}))
|
|
1597
1608
|
]), d;
|
|
1598
1609
|
}, [])
|
|
1599
|
-
), B =
|
|
1610
|
+
), B = F(() => [
|
|
1600
1611
|
{ label: _("report.section.datasource.none"), value: null },
|
|
1601
1612
|
{ label: _("report.section.datasource.grandTotal"), value: 0 },
|
|
1602
|
-
...[...
|
|
1603
|
-
label:
|
|
1613
|
+
...[...k.value].slice(0, k.value.length - 1).map((d, t) => ({
|
|
1614
|
+
label: re(_, M, d.label, "other"),
|
|
1604
1615
|
value: t + 1
|
|
1605
1616
|
}))
|
|
1606
|
-
]), O =
|
|
1617
|
+
]), O = F(() => [
|
|
1607
1618
|
{
|
|
1608
1619
|
label: _("report.section.datasource.position.top"),
|
|
1609
1620
|
value: gl.top
|
|
@@ -1612,9 +1623,9 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1612
1623
|
label: _("report.section.datasource.position.bottom"),
|
|
1613
1624
|
value: gl.bottom
|
|
1614
1625
|
}
|
|
1615
|
-
]),
|
|
1616
|
-
() => `rollup-${i.value}-${
|
|
1617
|
-
), u =
|
|
1626
|
+
]), w = F(
|
|
1627
|
+
() => `rollup-${i.value}-${k.value.map((d) => Ve(d)).join("|")}`
|
|
1628
|
+
), u = F(() => [
|
|
1618
1629
|
{
|
|
1619
1630
|
label: _("report.section.datasource.none"),
|
|
1620
1631
|
value: null
|
|
@@ -1623,10 +1634,10 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1623
1634
|
label: M(`report.section.datasource.periodType.${d}`) ? _(`report.section.datasource.periodType.${d}`) : d,
|
|
1624
1635
|
value: fl[d]
|
|
1625
1636
|
}))
|
|
1626
|
-
]),
|
|
1637
|
+
]), j = F(() => [
|
|
1627
1638
|
{ label: _("report.section.datasource.joinType.left"), value: "LEFT" },
|
|
1628
1639
|
{ label: _("report.section.datasource.joinType.fullOuter"), value: "FULL_OUTER" }
|
|
1629
|
-
]), Y =
|
|
1640
|
+
]), Y = F(() => [
|
|
1630
1641
|
{ label: _("report.section.datasource.sparklineType.line"), value: "LINECHART" },
|
|
1631
1642
|
{ label: _("report.section.datasource.sparklineType.bar"), value: "BARCHART" },
|
|
1632
1643
|
{ label: _("report.section.datasource.sparklineType.stackedBar"), value: "STACKBARCHART" }
|
|
@@ -1635,14 +1646,14 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1635
1646
|
const A = L("FmButton"), z = L("FmSwitch"), J = L("FmSelect"), ie = L("FmTextField");
|
|
1636
1647
|
return f(), R(al, null, {
|
|
1637
1648
|
header: K(() => [
|
|
1638
|
-
h("p", null, G(
|
|
1649
|
+
h("p", null, G(n.label), 1),
|
|
1639
1650
|
t[24] || (t[24] = h("div", { class: "grow" }, null, -1)),
|
|
1640
|
-
|
|
1651
|
+
n.closeable ? (f(), R(A, {
|
|
1641
1652
|
key: 0,
|
|
1642
1653
|
icon: "close",
|
|
1643
1654
|
variant: "tertiary",
|
|
1644
1655
|
size: "md",
|
|
1645
|
-
onClick: t[0] || (t[0] =
|
|
1656
|
+
onClick: t[0] || (t[0] = we((D) => a("click-close"), ["stop"]))
|
|
1646
1657
|
})) : I("", !0)
|
|
1647
1658
|
]),
|
|
1648
1659
|
content: K(() => [
|
|
@@ -1656,7 +1667,7 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1656
1667
|
"onUpdate:modelValue": t[2] || (t[2] = (D) => e.value.dimensions = D),
|
|
1657
1668
|
options: r.value,
|
|
1658
1669
|
config: e.value,
|
|
1659
|
-
max:
|
|
1670
|
+
max: n.config.maxDimension,
|
|
1660
1671
|
"has-row-column": !0,
|
|
1661
1672
|
onConfig: t[3] || (t[3] = (D) => {
|
|
1662
1673
|
e.value = D;
|
|
@@ -1679,7 +1690,7 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1679
1690
|
e.value.isCumulative = D;
|
|
1680
1691
|
})
|
|
1681
1692
|
}, null, 8, ["label", "model-value"])) : I("", !0),
|
|
1682
|
-
|
|
1693
|
+
n.config.isDrillConfigurable && s.value ? (f(), R(z, {
|
|
1683
1694
|
key: 1,
|
|
1684
1695
|
label: l(_)("report.section.datasource.drill"),
|
|
1685
1696
|
"label-placement": "right",
|
|
@@ -1695,21 +1706,21 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1695
1706
|
label: l(_)("report.section.datasource.blend"),
|
|
1696
1707
|
"label-placement": "right"
|
|
1697
1708
|
}, null, 8, ["modelValue", "label"])) : I("", !0),
|
|
1698
|
-
|
|
1699
|
-
key:
|
|
1709
|
+
n.config.canRollup && s.value ? (f(), R(J, {
|
|
1710
|
+
key: w.value,
|
|
1700
1711
|
modelValue: e.value.rollup,
|
|
1701
1712
|
"onUpdate:modelValue": t[8] || (t[8] = (D) => e.value.rollup = D),
|
|
1702
1713
|
label: l(_)("report.section.datasource.subTotal"),
|
|
1703
1714
|
items: B.value
|
|
1704
1715
|
}, null, 8, ["modelValue", "label", "items"])) : I("", !0),
|
|
1705
|
-
|
|
1716
|
+
n.config.showRollupPosition && s.value ? (f(), R(J, {
|
|
1706
1717
|
key: `rollup-position-${l(i)}`,
|
|
1707
1718
|
modelValue: e.value.rollupPosition,
|
|
1708
1719
|
"onUpdate:modelValue": t[9] || (t[9] = (D) => e.value.rollupPosition = D),
|
|
1709
1720
|
label: l(_)("report.section.datasource.position.showPosition"),
|
|
1710
1721
|
items: O.value
|
|
1711
1722
|
}, null, 8, ["modelValue", "label", "items"])) : I("", !0),
|
|
1712
|
-
|
|
1723
|
+
n.config.type === l(q).Table && s.value ? (f(), R(ie, {
|
|
1713
1724
|
key: 5,
|
|
1714
1725
|
modelValue: e.value.grandTotalLabel,
|
|
1715
1726
|
"onUpdate:modelValue": t[10] || (t[10] = (D) => e.value.grandTotalLabel = D),
|
|
@@ -1723,33 +1734,35 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1723
1734
|
label: l(_)("report.section.datasource.periodType.label"),
|
|
1724
1735
|
items: u.value
|
|
1725
1736
|
}, null, 8, ["modelValue", "label", "items"])),
|
|
1726
|
-
|
|
1737
|
+
n.config.canTranspose && s.value ? (f(), R(z, {
|
|
1727
1738
|
key: 7,
|
|
1728
1739
|
modelValue: e.value.isTransposed,
|
|
1729
1740
|
"onUpdate:modelValue": t[12] || (t[12] = (D) => e.value.isTransposed = D),
|
|
1730
1741
|
label: l(_)("report.section.datasource.transpose"),
|
|
1731
1742
|
"label-placement": "right"
|
|
1732
1743
|
}, null, 8, ["modelValue", "label"])) : I("", !0),
|
|
1733
|
-
|
|
1744
|
+
n.config.hasBreakdownDimension ? (f(), R(tl, {
|
|
1734
1745
|
key: 8,
|
|
1735
1746
|
"model-value": e.value.breakdownDimension ? [e.value.breakdownDimension] : [],
|
|
1736
1747
|
label: "breakdownDimension",
|
|
1737
1748
|
max: 1,
|
|
1738
1749
|
options: r.value,
|
|
1750
|
+
config: e.value,
|
|
1739
1751
|
"onUpdate:modelValue": t[13] || (t[13] = (D) => {
|
|
1740
1752
|
e.value.breakdownDimension = D[0];
|
|
1741
1753
|
})
|
|
1742
|
-
}, null, 8, ["model-value", "options"])) : I("", !0),
|
|
1754
|
+
}, null, 8, ["model-value", "options", "config"])) : I("", !0),
|
|
1743
1755
|
U.value ? (f(), R(tl, {
|
|
1744
1756
|
key: 9,
|
|
1745
1757
|
"model-value": e.value.sparklineDimension ? [e.value.sparklineDimension] : [],
|
|
1746
1758
|
label: "sparklineDimension",
|
|
1747
1759
|
max: 1,
|
|
1748
1760
|
options: r.value,
|
|
1761
|
+
config: e.value,
|
|
1749
1762
|
"onUpdate:modelValue": t[14] || (t[14] = (D) => {
|
|
1750
1763
|
e.value.sparklineDimension = D[0];
|
|
1751
1764
|
})
|
|
1752
|
-
}, null, 8, ["model-value", "options"])) : I("", !0),
|
|
1765
|
+
}, null, 8, ["model-value", "options", "config"])) : I("", !0),
|
|
1753
1766
|
U.value && g.value && e.value.sparklineDimension ? (f(), R(J, {
|
|
1754
1767
|
key: `sparklineType-${l(i)}`,
|
|
1755
1768
|
"model-value": e.value.sparklineType ?? "LINECHART",
|
|
@@ -1772,11 +1785,11 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1772
1785
|
modelValue: e.value.metrics,
|
|
1773
1786
|
"onUpdate:modelValue": t[17] || (t[17] = (D) => e.value.metrics = D),
|
|
1774
1787
|
options: r.value,
|
|
1775
|
-
max:
|
|
1788
|
+
max: n.config.maxMetric,
|
|
1776
1789
|
config: e.value,
|
|
1777
|
-
"has-row-column":
|
|
1790
|
+
"has-row-column": n.config.type === l(q).Table,
|
|
1778
1791
|
"has-percent-of-total": g.value,
|
|
1779
|
-
"has-xy":
|
|
1792
|
+
"has-xy": n.config.hasXy,
|
|
1780
1793
|
onConfig: t[18] || (t[18] = (D) => {
|
|
1781
1794
|
e.value = D;
|
|
1782
1795
|
})
|
|
@@ -1786,15 +1799,17 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1786
1799
|
"onUpdate:modelValue": t[19] || (t[19] = (D) => e.value.filters = D),
|
|
1787
1800
|
options: r.value,
|
|
1788
1801
|
dimensions: e.value.dimensions,
|
|
1802
|
+
"breakdown-dimension": e.value.breakdownDimension,
|
|
1789
1803
|
metrics: e.value.metrics
|
|
1790
|
-
}, null, 8, ["modelValue", "options", "dimensions", "metrics"]),
|
|
1791
|
-
c(
|
|
1804
|
+
}, null, 8, ["modelValue", "options", "dimensions", "breakdown-dimension", "metrics"]),
|
|
1805
|
+
c(kt, {
|
|
1792
1806
|
modelValue: e.value.sorts,
|
|
1793
1807
|
"onUpdate:modelValue": t[20] || (t[20] = (D) => e.value.sorts = D),
|
|
1794
1808
|
options: r.value,
|
|
1795
1809
|
dimensions: e.value.dimensions,
|
|
1810
|
+
"breakdown-dimension": e.value.breakdownDimension,
|
|
1796
1811
|
metrics: e.value.metrics
|
|
1797
|
-
}, null, 8, ["modelValue", "options", "dimensions", "metrics"]),
|
|
1812
|
+
}, null, 8, ["modelValue", "options", "dimensions", "breakdown-dimension", "metrics"]),
|
|
1798
1813
|
c(St, {
|
|
1799
1814
|
modelValue: e.value.limit,
|
|
1800
1815
|
"onUpdate:modelValue": t[21] || (t[21] = (D) => e.value.limit = D)
|
|
@@ -1803,7 +1818,7 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1803
1818
|
key: 12,
|
|
1804
1819
|
"model-value": e.value.joinType ?? "LEFT",
|
|
1805
1820
|
label: l(_)("report.section.datasource.joinType.label"),
|
|
1806
|
-
items:
|
|
1821
|
+
items: j.value,
|
|
1807
1822
|
"onUpdate:modelValue": t[22] || (t[22] = (D) => {
|
|
1808
1823
|
e.value.joinType = D;
|
|
1809
1824
|
})
|
|
@@ -1820,9 +1835,9 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1820
1835
|
});
|
|
1821
1836
|
};
|
|
1822
1837
|
}
|
|
1823
|
-
}), Bt = { class: "fm-typo-en-title-sm-600" }, Je = /* @__PURE__ */
|
|
1838
|
+
}), Bt = { class: "fm-typo-en-title-sm-600" }, Je = /* @__PURE__ */ de({
|
|
1824
1839
|
__name: "TileEditorTabHeader",
|
|
1825
|
-
props: /* @__PURE__ */
|
|
1840
|
+
props: /* @__PURE__ */ ve({
|
|
1826
1841
|
icon: {
|
|
1827
1842
|
type: String,
|
|
1828
1843
|
required: !0
|
|
@@ -1837,22 +1852,22 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1837
1852
|
}),
|
|
1838
1853
|
emits: ["update:modelValue"],
|
|
1839
1854
|
setup($) {
|
|
1840
|
-
const { t: v } =
|
|
1841
|
-
return (V,
|
|
1855
|
+
const { t: v } = pe(), e = ge($, "modelValue"), n = $, a = F(() => n.title || v("report.tile.setting"));
|
|
1856
|
+
return (V, C) => {
|
|
1842
1857
|
const g = L("FmIcon");
|
|
1843
1858
|
return f(), E("div", {
|
|
1844
1859
|
class: "px-6 py-16 flex items-center gap-2 bg-fm-color-neutral-white border cursor-pointer",
|
|
1845
|
-
onClick:
|
|
1860
|
+
onClick: C[0] || (C[0] = (_) => e.value = !e.value)
|
|
1846
1861
|
}, [
|
|
1847
|
-
h("p", Bt, G(
|
|
1848
|
-
|
|
1862
|
+
h("p", Bt, G(a.value), 1),
|
|
1863
|
+
C[1] || (C[1] = h("div", { class: "grow" }, null, -1)),
|
|
1849
1864
|
c(g, {
|
|
1850
|
-
name:
|
|
1865
|
+
name: n.icon
|
|
1851
1866
|
}, null, 8, ["name"])
|
|
1852
1867
|
]);
|
|
1853
1868
|
};
|
|
1854
1869
|
}
|
|
1855
|
-
}), At = /* @__PURE__ */
|
|
1870
|
+
}), At = /* @__PURE__ */ de({
|
|
1856
1871
|
__name: "TileEditorTabDesktop",
|
|
1857
1872
|
props: {
|
|
1858
1873
|
modelValue: { required: !0, default: !1 },
|
|
@@ -1860,18 +1875,18 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1860
1875
|
},
|
|
1861
1876
|
emits: ["update:modelValue"],
|
|
1862
1877
|
setup($) {
|
|
1863
|
-
const v = ge($, "modelValue"), { t: e } =
|
|
1864
|
-
return (
|
|
1878
|
+
const v = ge($, "modelValue"), { t: e } = pe();
|
|
1879
|
+
return (n, a) => (f(), E(ue, null, [
|
|
1865
1880
|
c(Je, {
|
|
1866
1881
|
modelValue: v.value,
|
|
1867
|
-
"onUpdate:modelValue":
|
|
1882
|
+
"onUpdate:modelValue": a[0] || (a[0] = (V) => v.value = V),
|
|
1868
1883
|
icon: "keyboard_double_arrow_left",
|
|
1869
1884
|
title: l(e)("report.tile.setupSetting")
|
|
1870
1885
|
}, null, 8, ["modelValue", "title"]),
|
|
1871
|
-
|
|
1886
|
+
wl(n.$slots, "default")
|
|
1872
1887
|
], 64));
|
|
1873
1888
|
}
|
|
1874
|
-
}), Lt = { class: "fixed bottom-0 w-full" }, Mt = /* @__PURE__ */
|
|
1889
|
+
}), Lt = { class: "fixed bottom-0 w-full" }, Mt = /* @__PURE__ */ de({
|
|
1875
1890
|
__name: "TileEditorTabMobile",
|
|
1876
1891
|
props: {
|
|
1877
1892
|
modelValue: { required: !0, default: !1 },
|
|
@@ -1880,26 +1895,26 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1880
1895
|
emits: ["update:modelValue"],
|
|
1881
1896
|
setup($) {
|
|
1882
1897
|
const v = ge($, "modelValue");
|
|
1883
|
-
return (e,
|
|
1884
|
-
const
|
|
1898
|
+
return (e, n) => {
|
|
1899
|
+
const a = L("FmTopSheet");
|
|
1885
1900
|
return f(), E("div", Lt, [
|
|
1886
1901
|
c(Je, {
|
|
1887
1902
|
modelValue: v.value,
|
|
1888
|
-
"onUpdate:modelValue":
|
|
1903
|
+
"onUpdate:modelValue": n[0] || (n[0] = (V) => v.value = V),
|
|
1889
1904
|
icon: "keyboard_double_arrow_up"
|
|
1890
1905
|
}, null, 8, ["modelValue"]),
|
|
1891
|
-
c(
|
|
1906
|
+
c(a, {
|
|
1892
1907
|
modelValue: v.value,
|
|
1893
|
-
"onUpdate:modelValue":
|
|
1908
|
+
"onUpdate:modelValue": n[2] || (n[2] = (V) => v.value = V),
|
|
1894
1909
|
"fullscreen-size": "sm"
|
|
1895
1910
|
}, {
|
|
1896
1911
|
default: K(() => [
|
|
1897
1912
|
c(Je, {
|
|
1898
1913
|
modelValue: v.value,
|
|
1899
|
-
"onUpdate:modelValue":
|
|
1914
|
+
"onUpdate:modelValue": n[1] || (n[1] = (V) => v.value = V),
|
|
1900
1915
|
icon: "keyboard_double_arrow_down"
|
|
1901
1916
|
}, null, 8, ["modelValue"]),
|
|
1902
|
-
v.value ?
|
|
1917
|
+
v.value ? wl(e.$slots, "default", { key: 0 }) : I("", !0)
|
|
1903
1918
|
]),
|
|
1904
1919
|
_: 3
|
|
1905
1920
|
}, 8, ["modelValue"])
|
|
@@ -1909,24 +1924,24 @@ const vt = { class: "flex flex-col my-2 gap-8" }, ft = { class: "fm-typo-en-body
|
|
|
1909
1924
|
});
|
|
1910
1925
|
function Dl($, v = 600) {
|
|
1911
1926
|
const e = le(null);
|
|
1912
|
-
function
|
|
1927
|
+
function n() {
|
|
1913
1928
|
$.value = !0, e.value && clearTimeout(e.value), e.value = setTimeout(() => {
|
|
1914
1929
|
$.value = !1, e.value = null;
|
|
1915
1930
|
}, v);
|
|
1916
1931
|
}
|
|
1917
|
-
function
|
|
1932
|
+
function a() {
|
|
1918
1933
|
e.value && (clearTimeout(e.value), e.value = null), $.value = !1;
|
|
1919
1934
|
}
|
|
1920
1935
|
return il(() => {
|
|
1921
|
-
|
|
1936
|
+
a();
|
|
1922
1937
|
}), {
|
|
1923
|
-
markStyleEditing:
|
|
1924
|
-
resetStyleEditing:
|
|
1938
|
+
markStyleEditing: n,
|
|
1939
|
+
resetStyleEditing: a
|
|
1925
1940
|
};
|
|
1926
1941
|
}
|
|
1927
|
-
const Ot = { class: "flex flex-col gap-5" },
|
|
1942
|
+
const Ot = { class: "flex flex-col gap-5" }, jt = { class: "fm-typo-en-body-lg-600" }, Nt = { class: "fm-typo-en-body-md-400 text-fm-color-typo-tertiary" }, Rt = { class: "flex gap-16" }, zt = { class: "flex flex-col gap-8 max-w-[120px]" }, It = { class: "fm-typo-en-body-lg-600" }, Pt = { class: "flex flex-col gap-16" }, Et = { class: "fm-typo-en-body-lg-600" }, Wt = { class: "flex flex-row gap-8" }, Xt = /* @__PURE__ */ de({
|
|
1928
1943
|
__name: "TitleSection",
|
|
1929
|
-
props: /* @__PURE__ */
|
|
1944
|
+
props: /* @__PURE__ */ ve({
|
|
1930
1945
|
title: {},
|
|
1931
1946
|
description: {},
|
|
1932
1947
|
showSearchToggle: { type: Boolean },
|
|
@@ -1935,77 +1950,77 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
1935
1950
|
isEditingStyle: { type: Boolean, required: !1, default: !1 },
|
|
1936
1951
|
isEditingStyleModifiers: {}
|
|
1937
1952
|
}),
|
|
1938
|
-
emits: /* @__PURE__ */
|
|
1953
|
+
emits: /* @__PURE__ */ ve(["update:model", "update:title", "update:description"], ["update:isEditingStyle"]),
|
|
1939
1954
|
setup($, { emit: v }) {
|
|
1940
|
-
const e = ge($, "isEditingStyle"), { markStyleEditing:
|
|
1955
|
+
const e = ge($, "isEditingStyle"), { markStyleEditing: n } = Dl(e), a = $, V = v, { t: C } = pe(), g = qe((r) => {
|
|
1941
1956
|
V("update:title", r);
|
|
1942
|
-
}, 500), _ =
|
|
1943
|
-
get: () =>
|
|
1957
|
+
}, 500), _ = F({
|
|
1958
|
+
get: () => a.title ?? "",
|
|
1944
1959
|
set: (r) => {
|
|
1945
|
-
|
|
1960
|
+
n(), g(r);
|
|
1946
1961
|
}
|
|
1947
|
-
}), M =
|
|
1948
|
-
get: () =>
|
|
1962
|
+
}), M = F({
|
|
1963
|
+
get: () => a.description ?? "",
|
|
1949
1964
|
set: (r) => {
|
|
1950
|
-
|
|
1965
|
+
n(), V("update:description", r);
|
|
1951
1966
|
}
|
|
1952
|
-
}), i =
|
|
1953
|
-
get: () =>
|
|
1967
|
+
}), i = F({
|
|
1968
|
+
get: () => a.model.showTitle ?? !0,
|
|
1954
1969
|
set: (r) => {
|
|
1955
|
-
|
|
1970
|
+
n(), V("update:model", { ...a.model, showTitle: r });
|
|
1956
1971
|
}
|
|
1957
|
-
}), s =
|
|
1958
|
-
get: () =>
|
|
1972
|
+
}), s = F({
|
|
1973
|
+
get: () => a.model.showSearchBar ?? !0,
|
|
1959
1974
|
set: (r) => {
|
|
1960
|
-
|
|
1975
|
+
n(), V("update:model", { ...a.model, showSearchBar: r });
|
|
1961
1976
|
}
|
|
1962
|
-
}), y =
|
|
1963
|
-
get: () =>
|
|
1977
|
+
}), y = F({
|
|
1978
|
+
get: () => a.model.titleFontSize ?? 14,
|
|
1964
1979
|
set: (r) => {
|
|
1965
|
-
|
|
1980
|
+
n(), V("update:model", { ...a.model, titleFontSize: Math.min(Number(r), 24) });
|
|
1966
1981
|
}
|
|
1967
|
-
}),
|
|
1968
|
-
get: () =>
|
|
1982
|
+
}), k = F({
|
|
1983
|
+
get: () => a.model.titleBold ?? !1,
|
|
1969
1984
|
set: (r) => {
|
|
1970
|
-
|
|
1985
|
+
n(), V("update:model", { ...a.model, titleBold: r });
|
|
1971
1986
|
}
|
|
1972
|
-
}), U =
|
|
1973
|
-
get: () =>
|
|
1987
|
+
}), U = F({
|
|
1988
|
+
get: () => a.model.titleItalic ?? !1,
|
|
1974
1989
|
set: (r) => {
|
|
1975
|
-
|
|
1990
|
+
n(), V("update:model", { ...a.model, titleItalic: r });
|
|
1976
1991
|
}
|
|
1977
|
-
}), p =
|
|
1978
|
-
get: () =>
|
|
1992
|
+
}), p = F({
|
|
1993
|
+
get: () => a.model.titleUnderline ?? !1,
|
|
1979
1994
|
set: (r) => {
|
|
1980
|
-
|
|
1995
|
+
n(), V("update:model", { ...a.model, titleUnderline: r });
|
|
1981
1996
|
}
|
|
1982
1997
|
});
|
|
1983
1998
|
return (r, B) => {
|
|
1984
|
-
const O = L("FmTextField"),
|
|
1985
|
-
return f(), E(
|
|
1999
|
+
const O = L("FmTextField"), w = L("FmTextarea"), u = L("FmStepperField"), j = L("FmButton"), Y = L("FmSwitch");
|
|
2000
|
+
return f(), E(ue, null, [
|
|
1986
2001
|
h("div", Ot, [
|
|
1987
2002
|
c(O, {
|
|
1988
2003
|
modelValue: _.value,
|
|
1989
2004
|
"onUpdate:modelValue": B[0] || (B[0] = (d) => _.value = d),
|
|
1990
|
-
label: l(
|
|
1991
|
-
placeholder: l(
|
|
2005
|
+
label: l(C)("report.tile.widget.title"),
|
|
2006
|
+
placeholder: l(C)("report.tile.widget.titlePlaceholder")
|
|
1992
2007
|
}, null, 8, ["modelValue", "label", "placeholder"]),
|
|
1993
|
-
c(
|
|
2008
|
+
c(w, {
|
|
1994
2009
|
modelValue: M.value,
|
|
1995
2010
|
"onUpdate:modelValue": B[1] || (B[1] = (d) => M.value = d),
|
|
1996
2011
|
disabled: _.value === "",
|
|
1997
|
-
placeholder: l(
|
|
1998
|
-
"helper-text": l(
|
|
2012
|
+
placeholder: l(C)("report.tile.widget.descriptionPlaceholder"),
|
|
2013
|
+
"helper-text": l(C)("report.tile.widget.descriptionHelper")
|
|
1999
2014
|
}, {
|
|
2000
2015
|
label: K(() => [
|
|
2001
|
-
h("p",
|
|
2002
|
-
h("p",
|
|
2016
|
+
h("p", jt, G(l(C)("report.tile.widget.widgetDescription")), 1),
|
|
2017
|
+
h("p", Nt, " (" + G(l(C)("report.tile.widget.optional")) + ") ", 1)
|
|
2003
2018
|
]),
|
|
2004
2019
|
_: 1
|
|
2005
2020
|
}, 8, ["modelValue", "disabled", "placeholder", "helper-text"]),
|
|
2006
2021
|
h("div", Rt, [
|
|
2007
2022
|
h("div", zt, [
|
|
2008
|
-
h("p", It, G(l(
|
|
2023
|
+
h("p", It, G(l(C)("report.section.datasource.title.titleFontSize")), 1),
|
|
2009
2024
|
c(u, {
|
|
2010
2025
|
modelValue: y.value,
|
|
2011
2026
|
"onUpdate:modelValue": B[2] || (B[2] = (d) => y.value = d),
|
|
@@ -2015,18 +2030,18 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
2015
2030
|
}, null, 8, ["modelValue"])
|
|
2016
2031
|
]),
|
|
2017
2032
|
h("div", Pt, [
|
|
2018
|
-
h("p", Et, G(l(
|
|
2033
|
+
h("p", Et, G(l(C)("report.section.datasource.title.textStyleFormat")), 1),
|
|
2019
2034
|
h("div", Wt, [
|
|
2020
|
-
c(
|
|
2035
|
+
c(j, {
|
|
2021
2036
|
"append-icon": "format_bold",
|
|
2022
2037
|
"model-value": r.model.titleBold ?? !1,
|
|
2023
2038
|
variant: "tertiary",
|
|
2024
2039
|
"icon-color": r.model.titleBold ? "neutral-gray-400" : "neutral-gray-300",
|
|
2025
2040
|
"bg-color": r.model.titleBold ? "neutral-gray-100" : "neutral-white",
|
|
2026
2041
|
class: "rounded-sm",
|
|
2027
|
-
onClick: B[3] || (B[3] = (d) =>
|
|
2042
|
+
onClick: B[3] || (B[3] = (d) => k.value = !k.value)
|
|
2028
2043
|
}, null, 8, ["model-value", "icon-color", "bg-color"]),
|
|
2029
|
-
c(
|
|
2044
|
+
c(j, {
|
|
2030
2045
|
"append-icon": "format_italic",
|
|
2031
2046
|
"model-value": r.model.titleItalic ?? !1,
|
|
2032
2047
|
"icon-color": r.model.titleItalic ? "neutral-gray-400" : "neutral-gray-300",
|
|
@@ -2034,7 +2049,7 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
2034
2049
|
class: "rounded-sm",
|
|
2035
2050
|
onClick: B[4] || (B[4] = (d) => U.value = !U.value)
|
|
2036
2051
|
}, null, 8, ["model-value", "icon-color", "bg-color"]),
|
|
2037
|
-
c(
|
|
2052
|
+
c(j, {
|
|
2038
2053
|
"append-icon": "format_underlined",
|
|
2039
2054
|
"model-value": r.model.titleUnderline ?? !1,
|
|
2040
2055
|
"icon-color": r.model.titleUnderline ? "neutral-gray-400" : "neutral-gray-300",
|
|
@@ -2049,22 +2064,22 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
2049
2064
|
c(Y, {
|
|
2050
2065
|
modelValue: i.value,
|
|
2051
2066
|
"onUpdate:modelValue": B[6] || (B[6] = (d) => i.value = d),
|
|
2052
|
-
label: l(
|
|
2067
|
+
label: l(C)("report.section.datasource.title.showTitle"),
|
|
2053
2068
|
"label-placement": "right"
|
|
2054
2069
|
}, null, 8, ["modelValue", "label"]),
|
|
2055
|
-
|
|
2070
|
+
a.showSearchToggle ? (f(), R(Y, {
|
|
2056
2071
|
key: 0,
|
|
2057
2072
|
modelValue: s.value,
|
|
2058
2073
|
"onUpdate:modelValue": B[7] || (B[7] = (d) => s.value = d),
|
|
2059
|
-
label: l(
|
|
2074
|
+
label: l(C)("report.section.datasource.title.showSearchBar"),
|
|
2060
2075
|
"label-placement": "right"
|
|
2061
2076
|
}, null, 8, ["modelValue", "label"])) : I("", !0)
|
|
2062
2077
|
], 64);
|
|
2063
2078
|
};
|
|
2064
2079
|
}
|
|
2065
|
-
}), Ht = { class: "flex gap-16 justify-center items-center" }, qt = { class: "fm-typo-en-title-sm-600" }, Gt = { class: "h-[40x]" }, hl = "YYYY-MM-DD", Ul = /* @__PURE__ */
|
|
2080
|
+
}), Ht = { class: "flex gap-16 justify-center items-center" }, qt = { class: "fm-typo-en-title-sm-600" }, Gt = { class: "h-[40x]" }, hl = "YYYY-MM-DD", Ul = /* @__PURE__ */ de({
|
|
2066
2081
|
__name: "TileEditorTab",
|
|
2067
|
-
props: /* @__PURE__ */
|
|
2082
|
+
props: /* @__PURE__ */ ve({
|
|
2068
2083
|
hideConfiguration: {
|
|
2069
2084
|
type: Boolean,
|
|
2070
2085
|
default: !1
|
|
@@ -2077,31 +2092,31 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
2077
2092
|
isEditingStyle: { type: Boolean, required: !1, default: !1 },
|
|
2078
2093
|
isEditingStyleModifiers: {}
|
|
2079
2094
|
}),
|
|
2080
|
-
emits: /* @__PURE__ */
|
|
2095
|
+
emits: /* @__PURE__ */ ve(["hideConfiguration"], ["update:modelValue", "update:isEditingStyle"]),
|
|
2081
2096
|
setup($, { emit: v }) {
|
|
2082
|
-
var
|
|
2083
|
-
const e = tt(), { dateRange:
|
|
2084
|
-
startDate:
|
|
2085
|
-
endDate:
|
|
2086
|
-
},
|
|
2087
|
-
startDate: (
|
|
2088
|
-
endDate: (Y = He(
|
|
2097
|
+
var j, Y;
|
|
2098
|
+
const e = tt(), { dateRange: n, timezone: a } = Ne(e), V = {
|
|
2099
|
+
startDate: n.value.startDate,
|
|
2100
|
+
endDate: n.value.endDate
|
|
2101
|
+
}, C = le({
|
|
2102
|
+
startDate: (j = He(n.value.startDate)) == null ? void 0 : j.tz(a.value).format(hl),
|
|
2103
|
+
endDate: (Y = He(n.value.endDate)) == null ? void 0 : Y.tz(a.value).format(hl)
|
|
2089
2104
|
});
|
|
2090
|
-
|
|
2091
|
-
|
|
2105
|
+
Ce(
|
|
2106
|
+
C,
|
|
2092
2107
|
() => {
|
|
2093
|
-
|
|
2108
|
+
C.value.endDate || (C.value.endDate = C.value.startDate);
|
|
2094
2109
|
const d = {
|
|
2095
|
-
startDate: He.tz(
|
|
2096
|
-
endDate: He.tz(
|
|
2110
|
+
startDate: He.tz(C.value.startDate, a.value).startOf("day").utc().toISOString(),
|
|
2111
|
+
endDate: He.tz(C.value.endDate, a.value).endOf("day").utc().toISOString()
|
|
2097
2112
|
};
|
|
2098
|
-
|
|
2113
|
+
n.value = d;
|
|
2099
2114
|
},
|
|
2100
2115
|
{ deep: !0 }
|
|
2101
2116
|
), il(() => {
|
|
2102
|
-
|
|
2117
|
+
n.value = { ...V };
|
|
2103
2118
|
});
|
|
2104
|
-
const g = ge($, "modelValue"), _ = ge($, "isEditingStyle"), { breakpoints: M } = Sl(), i = $, { promptMessage: s } = Vl(), y = v, { t:
|
|
2119
|
+
const g = ge($, "modelValue"), _ = ge($, "isEditingStyle"), { breakpoints: M } = Sl(), i = $, { promptMessage: s } = Vl(), y = v, { t: k, locale: U } = pe();
|
|
2105
2120
|
function p(d) {
|
|
2106
2121
|
g.value = nl(d);
|
|
2107
2122
|
}
|
|
@@ -2120,8 +2135,8 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
2120
2135
|
}
|
|
2121
2136
|
async function B(d) {
|
|
2122
2137
|
if (!await s({
|
|
2123
|
-
title:
|
|
2124
|
-
message:
|
|
2138
|
+
title: k("report.tile.datasource.remove"),
|
|
2139
|
+
message: k("report.tile.datasource.confirmRemove", { index: d + 1 })
|
|
2125
2140
|
})) return;
|
|
2126
2141
|
const A = [...g.value.widget.config.joinDatasources || []];
|
|
2127
2142
|
A.splice(d, 1), p({
|
|
@@ -2169,22 +2184,22 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
2169
2184
|
type: d
|
|
2170
2185
|
}
|
|
2171
2186
|
};
|
|
2172
|
-
},
|
|
2187
|
+
}, w = F(
|
|
2173
2188
|
() => Qe.find((d) => d.type === g.value.widget.type)
|
|
2174
|
-
), u =
|
|
2175
|
-
return
|
|
2189
|
+
), u = F(() => g.value.widget.config.joinDatasources);
|
|
2190
|
+
return Ce(
|
|
2176
2191
|
() => g.value.size.height,
|
|
2177
2192
|
(d) => {
|
|
2178
2193
|
d < 1 && (g.value.size.height = 1), d > 12 && (g.value.size.height = 12);
|
|
2179
2194
|
}
|
|
2180
|
-
),
|
|
2195
|
+
), Ce(
|
|
2181
2196
|
() => g.value.size.width,
|
|
2182
2197
|
(d) => {
|
|
2183
2198
|
d < 1 && (g.value.size.width = 1), d > 12 && (g.value.size.width = 12);
|
|
2184
2199
|
}
|
|
2185
2200
|
), (d, t) => {
|
|
2186
2201
|
const A = L("FmCircularProgress"), z = L("FmSimpleDateRangePicker"), J = L("FmStepperField"), ie = L("FmButton"), D = L("FmForm");
|
|
2187
|
-
return f(), R(
|
|
2202
|
+
return f(), R(Cl(l(M).lg || l(M).md ? At : Mt), {
|
|
2188
2203
|
"model-value": i.hideConfiguration,
|
|
2189
2204
|
"onUpdate:modelValue": t[10] || (t[10] = (m) => y("hideConfiguration", m))
|
|
2190
2205
|
}, {
|
|
@@ -2198,13 +2213,13 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
2198
2213
|
h("div", Ht, [
|
|
2199
2214
|
(f(), R(z, {
|
|
2200
2215
|
key: `date-picker-${l(U)}`,
|
|
2201
|
-
modelValue:
|
|
2202
|
-
"onUpdate:modelValue": t[0] || (t[0] = (m) =>
|
|
2216
|
+
modelValue: C.value,
|
|
2217
|
+
"onUpdate:modelValue": t[0] || (t[0] = (m) => C.value = m)
|
|
2203
2218
|
}, null, 8, ["modelValue"]))
|
|
2204
2219
|
]),
|
|
2205
2220
|
c(al, null, {
|
|
2206
2221
|
header: K(() => [
|
|
2207
|
-
h("p", qt, G(l(
|
|
2222
|
+
h("p", qt, G(l(k)("report.tile.widget.details")), 1),
|
|
2208
2223
|
t[11] || (t[11] = h("div", { class: "grow" }, null, -1))
|
|
2209
2224
|
]),
|
|
2210
2225
|
content: K(() => [
|
|
@@ -2220,19 +2235,19 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
2220
2235
|
"onUpdate:model": t[4] || (t[4] = (m) => g.value.widget.config = m)
|
|
2221
2236
|
}, null, 8, ["is-editing-style", "title", "description", "model", "show-search-toggle"]),
|
|
2222
2237
|
h("div", {
|
|
2223
|
-
class:
|
|
2238
|
+
class: Fe(["flex flex-row", `${l(M).sm || l(M).xs ? "gap-16" : "gap-2"}`])
|
|
2224
2239
|
}, [
|
|
2225
2240
|
c(J, {
|
|
2226
2241
|
modelValue: g.value.size.width,
|
|
2227
2242
|
"onUpdate:modelValue": t[5] || (t[5] = (m) => g.value.size.width = m),
|
|
2228
|
-
label: l(
|
|
2243
|
+
label: l(k)("report.tile.widget.width"),
|
|
2229
2244
|
min: 1,
|
|
2230
2245
|
max: 12
|
|
2231
2246
|
}, null, 8, ["modelValue", "label"]),
|
|
2232
2247
|
c(J, {
|
|
2233
2248
|
modelValue: g.value.size.height,
|
|
2234
2249
|
"onUpdate:modelValue": t[6] || (t[6] = (m) => g.value.size.height = m),
|
|
2235
|
-
label: l(
|
|
2250
|
+
label: l(k)("report.tile.widget.height"),
|
|
2236
2251
|
min: 1,
|
|
2237
2252
|
max: 12
|
|
2238
2253
|
}, null, 8, ["modelValue", "label"])
|
|
@@ -2242,7 +2257,7 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
2242
2257
|
}),
|
|
2243
2258
|
c(al, null, {
|
|
2244
2259
|
header: K(() => [
|
|
2245
|
-
h("p", null, G(l(
|
|
2260
|
+
h("p", null, G(l(k)("report.tile.widget.type")), 1),
|
|
2246
2261
|
t[12] || (t[12] = h("div", { class: "grow" }, null, -1))
|
|
2247
2262
|
]),
|
|
2248
2263
|
content: K(() => [
|
|
@@ -2260,15 +2275,15 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
2260
2275
|
c(bl, {
|
|
2261
2276
|
modelValue: g.value.widget.config,
|
|
2262
2277
|
"onUpdate:modelValue": t[8] || (t[8] = (m) => g.value.widget.config = m),
|
|
2263
|
-
label: l(
|
|
2264
|
-
config:
|
|
2278
|
+
label: l(k)("report.tile.datasource.main"),
|
|
2279
|
+
config: w.value
|
|
2265
2280
|
}, null, 8, ["modelValue", "label", "config"]),
|
|
2266
|
-
u.value ? (f(!0), E(
|
|
2281
|
+
u.value ? (f(!0), E(ue, { key: 0 }, Se(u.value, (m, o) => (f(), E("div", { key: o }, [
|
|
2267
2282
|
c(bl, {
|
|
2268
2283
|
modelValue: u.value[o],
|
|
2269
2284
|
"onUpdate:modelValue": (b) => u.value[o] = b,
|
|
2270
|
-
label: l(
|
|
2271
|
-
config:
|
|
2285
|
+
label: l(k)("report.tile.datasource.join", { index: o + 1 }),
|
|
2286
|
+
config: w.value,
|
|
2272
2287
|
"main-datasource-config": g.value.widget.config,
|
|
2273
2288
|
closeable: !0,
|
|
2274
2289
|
onClickClose: (b) => B(o)
|
|
@@ -2276,7 +2291,7 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
2276
2291
|
]))), 128)) : I("", !0),
|
|
2277
2292
|
h("div", Gt, [
|
|
2278
2293
|
c(ie, {
|
|
2279
|
-
label: l(
|
|
2294
|
+
label: l(k)("report.tile.datasource.joinButton"),
|
|
2280
2295
|
variant: "secondary",
|
|
2281
2296
|
icon: "add",
|
|
2282
2297
|
"icon-position": "prepend",
|
|
@@ -2294,36 +2309,36 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
2294
2309
|
}, 8, ["model-value"]);
|
|
2295
2310
|
};
|
|
2296
2311
|
}
|
|
2297
|
-
}), Yt = { class: "flex flex-col gap-8" }, Jt = { class: "pl-32 flex flex-col gap-8" }, Kt = { class: "fm-typo-en-body-lg-600" }, Qt = { class: "flex flex-row gap-8" }, Zt = { class: "fm-typo-en-body-lg-600" }, eo = { class: "flex flex-row gap-8" }, lo = /* @__PURE__ */
|
|
2312
|
+
}), Yt = { class: "flex flex-col gap-8" }, Jt = { class: "pl-32 flex flex-col gap-8" }, Kt = { class: "fm-typo-en-body-lg-600" }, Qt = { class: "flex flex-row gap-8" }, Zt = { class: "fm-typo-en-body-lg-600" }, eo = { class: "flex flex-row gap-8" }, lo = /* @__PURE__ */ de({
|
|
2298
2313
|
__name: "LabelSection",
|
|
2299
2314
|
props: {
|
|
2300
2315
|
model: {}
|
|
2301
2316
|
},
|
|
2302
2317
|
emits: ["update:model"],
|
|
2303
2318
|
setup($, { emit: v }) {
|
|
2304
|
-
const e = $,
|
|
2319
|
+
const e = $, n = v, { t: a } = pe(), V = F({
|
|
2305
2320
|
get: () => e.model.showLabel ?? !1,
|
|
2306
|
-
set: (
|
|
2307
|
-
|
|
2321
|
+
set: (k) => {
|
|
2322
|
+
n("update:model", { ...e.model, showLabel: k });
|
|
2308
2323
|
}
|
|
2309
|
-
}),
|
|
2324
|
+
}), C = F({
|
|
2310
2325
|
get: () => e.model.labelRotation ?? 0,
|
|
2311
|
-
set: (
|
|
2312
|
-
}), g =
|
|
2326
|
+
set: (k) => n("update:model", { ...e.model, labelRotation: k })
|
|
2327
|
+
}), g = F({
|
|
2313
2328
|
get: () => e.model.labelOffset ?? 0,
|
|
2314
|
-
set: (
|
|
2315
|
-
}), _ =
|
|
2329
|
+
set: (k) => n("update:model", { ...e.model, labelOffset: k })
|
|
2330
|
+
}), _ = F({
|
|
2316
2331
|
get: () => e.model.labelFontSize ?? 12,
|
|
2317
|
-
set: (
|
|
2318
|
-
}), M = (
|
|
2319
|
-
|
|
2332
|
+
set: (k) => n("update:model", { ...e.model, labelFontSize: k })
|
|
2333
|
+
}), M = (k) => {
|
|
2334
|
+
n("update:model", {
|
|
2320
2335
|
...e.model,
|
|
2321
|
-
labelAlign: e.model.labelAlign ===
|
|
2336
|
+
labelAlign: e.model.labelAlign === k ? void 0 : k
|
|
2322
2337
|
});
|
|
2323
|
-
}, i = (
|
|
2324
|
-
|
|
2338
|
+
}, i = (k) => {
|
|
2339
|
+
n("update:model", {
|
|
2325
2340
|
...e.model,
|
|
2326
|
-
labelAnchor: e.model.labelAnchor ===
|
|
2341
|
+
labelAnchor: e.model.labelAnchor === k ? void 0 : k
|
|
2327
2342
|
});
|
|
2328
2343
|
}, s = [
|
|
2329
2344
|
{ icon: "align_horizontal_left", value: Ae.left, tooltip: "alignLeft" },
|
|
@@ -2338,66 +2353,66 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
2338
2353
|
{ icon: "format_align_center", value: el.center, tooltip: "anchorCenter" },
|
|
2339
2354
|
{ icon: "format_align_right", value: el.end, tooltip: "anchorEnd" }
|
|
2340
2355
|
];
|
|
2341
|
-
return (
|
|
2342
|
-
const p = L("FmCheckbox"), r = L("FmButton"), B = L("FmTooltip"), O = L("FmTextField"),
|
|
2356
|
+
return (k, U) => {
|
|
2357
|
+
const p = L("FmCheckbox"), r = L("FmButton"), B = L("FmTooltip"), O = L("FmTextField"), w = L("FmStepperField");
|
|
2343
2358
|
return f(), E("div", Yt, [
|
|
2344
2359
|
c(p, {
|
|
2345
2360
|
modelValue: V.value,
|
|
2346
2361
|
"onUpdate:modelValue": U[0] || (U[0] = (u) => V.value = u),
|
|
2347
2362
|
value: !1,
|
|
2348
|
-
label: l(
|
|
2363
|
+
label: l(a)("report.section.datasource.label.showLabel"),
|
|
2349
2364
|
"label-placement": "right",
|
|
2350
2365
|
class: "fm-typo-en-body-lg-400"
|
|
2351
2366
|
}, null, 8, ["modelValue", "label"]),
|
|
2352
|
-
|
|
2353
|
-
h("p", Kt, G(l(
|
|
2367
|
+
ke(h("div", Jt, [
|
|
2368
|
+
h("p", Kt, G(l(a)("report.section.datasource.alignment.textAlignment")), 1),
|
|
2354
2369
|
h("div", Qt, [
|
|
2355
|
-
(f(), E(
|
|
2356
|
-
key:
|
|
2370
|
+
(f(), E(ue, null, Se(s, ({ icon: u, value: j, tooltip: Y }) => c(B, {
|
|
2371
|
+
key: j,
|
|
2357
2372
|
variant: "plain",
|
|
2358
2373
|
placement: "top",
|
|
2359
|
-
content: l(
|
|
2374
|
+
content: l(a)(`report.section.datasource.alignment.alignOptions.${Y}`),
|
|
2360
2375
|
"z-index": 50
|
|
2361
2376
|
}, {
|
|
2362
2377
|
default: K(() => [
|
|
2363
2378
|
c(r, {
|
|
2364
2379
|
"append-icon": u,
|
|
2365
2380
|
variant: "tertiary",
|
|
2366
|
-
"icon-color":
|
|
2367
|
-
"bg-color":
|
|
2381
|
+
"icon-color": k.model.labelAlign === j ? "neutral-gray-400" : "neutral-gray-300",
|
|
2382
|
+
"bg-color": k.model.labelAlign === j ? "neutral-gray-100" : "neutral-white",
|
|
2368
2383
|
class: "rounded-sm",
|
|
2369
|
-
onClick: (d) => M(
|
|
2384
|
+
onClick: (d) => M(j)
|
|
2370
2385
|
}, null, 8, ["append-icon", "icon-color", "bg-color", "onClick"])
|
|
2371
2386
|
]),
|
|
2372
2387
|
_: 2
|
|
2373
2388
|
}, 1032, ["content"])), 64))
|
|
2374
2389
|
]),
|
|
2375
|
-
h("p", Zt, G(l(
|
|
2390
|
+
h("p", Zt, G(l(a)("report.section.datasource.alignment.anchor")), 1),
|
|
2376
2391
|
h("div", eo, [
|
|
2377
|
-
(f(), E(
|
|
2378
|
-
key:
|
|
2392
|
+
(f(), E(ue, null, Se(y, ({ icon: u, value: j, tooltip: Y }) => c(B, {
|
|
2393
|
+
key: j,
|
|
2379
2394
|
variant: "plain",
|
|
2380
2395
|
placement: "top",
|
|
2381
|
-
content: l(
|
|
2396
|
+
content: l(a)(`report.section.datasource.alignment.anchorOptions.${Y}`),
|
|
2382
2397
|
"z-index": 50
|
|
2383
2398
|
}, {
|
|
2384
2399
|
default: K(() => [
|
|
2385
2400
|
c(r, {
|
|
2386
2401
|
"append-icon": u,
|
|
2387
2402
|
variant: "tertiary",
|
|
2388
|
-
"icon-color":
|
|
2389
|
-
"bg-color":
|
|
2403
|
+
"icon-color": k.model.labelAnchor === j ? "neutral-gray-400" : "neutral-gray-300",
|
|
2404
|
+
"bg-color": k.model.labelAnchor === j ? "neutral-gray-100" : "neutral-white",
|
|
2390
2405
|
class: "rounded-sm",
|
|
2391
|
-
onClick: (d) => i(
|
|
2406
|
+
onClick: (d) => i(j)
|
|
2392
2407
|
}, null, 8, ["append-icon", "icon-color", "bg-color", "onClick"])
|
|
2393
2408
|
]),
|
|
2394
2409
|
_: 2
|
|
2395
2410
|
}, 1032, ["content"])), 64))
|
|
2396
2411
|
]),
|
|
2397
2412
|
c(O, {
|
|
2398
|
-
modelValue:
|
|
2399
|
-
"onUpdate:modelValue": U[1] || (U[1] = (u) =>
|
|
2400
|
-
label: l(
|
|
2413
|
+
modelValue: C.value,
|
|
2414
|
+
"onUpdate:modelValue": U[1] || (U[1] = (u) => C.value = u),
|
|
2415
|
+
label: l(a)("report.section.datasource.alignment.rotation"),
|
|
2401
2416
|
type: "number",
|
|
2402
2417
|
min: -180,
|
|
2403
2418
|
max: 180,
|
|
@@ -2406,212 +2421,212 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
2406
2421
|
c(O, {
|
|
2407
2422
|
modelValue: g.value,
|
|
2408
2423
|
"onUpdate:modelValue": U[2] || (U[2] = (u) => g.value = u),
|
|
2409
|
-
label: l(
|
|
2424
|
+
label: l(a)("report.section.datasource.alignment.offset"),
|
|
2410
2425
|
type: "number"
|
|
2411
2426
|
}, null, 8, ["modelValue", "label"]),
|
|
2412
|
-
c(
|
|
2427
|
+
c(w, {
|
|
2413
2428
|
modelValue: _.value,
|
|
2414
2429
|
"onUpdate:modelValue": U[3] || (U[3] = (u) => _.value = u),
|
|
2415
|
-
label: l(
|
|
2430
|
+
label: l(a)("report.section.datasource.fontSize"),
|
|
2416
2431
|
type: "number",
|
|
2417
2432
|
min: 1
|
|
2418
2433
|
}, null, 8, ["modelValue", "label"])
|
|
2419
2434
|
], 512), [
|
|
2420
|
-
[
|
|
2435
|
+
[$e, V.value]
|
|
2421
2436
|
])
|
|
2422
2437
|
]);
|
|
2423
2438
|
};
|
|
2424
2439
|
}
|
|
2425
|
-
}), to = { class: "flex flex-col gap-8" }, oo = { class: "pl-32 flex flex-col gap-8" }, ao = { class: "pl-32 flex flex-col gap-8" }, no = { class: "pl-32 flex flex-col gap-8" }, io = { class: "pl-32 flex flex-col gap-8" }, so = { class: "pl-32 flex flex-col gap-8" }, ro = { class: "pl-32 flex flex-col gap-8" }, uo = /* @__PURE__ */
|
|
2440
|
+
}), to = { class: "flex flex-col gap-8" }, oo = { class: "pl-32 flex flex-col gap-8" }, ao = { class: "pl-32 flex flex-col gap-8" }, no = { class: "pl-32 flex flex-col gap-8" }, io = { class: "pl-32 flex flex-col gap-8" }, so = { class: "pl-32 flex flex-col gap-8" }, ro = { class: "pl-32 flex flex-col gap-8" }, uo = /* @__PURE__ */ de({
|
|
2426
2441
|
__name: "XySection",
|
|
2427
2442
|
props: {
|
|
2428
2443
|
model: {}
|
|
2429
2444
|
},
|
|
2430
2445
|
emits: ["update:model"],
|
|
2431
2446
|
setup($, { emit: v }) {
|
|
2432
|
-
const e = $,
|
|
2447
|
+
const e = $, n = v, { t: a } = pe(), V = F({
|
|
2433
2448
|
get: () => e.model.showX ?? !0,
|
|
2434
2449
|
set: (p) => {
|
|
2435
|
-
|
|
2450
|
+
n("update:model", { ...e.model, showX: p });
|
|
2436
2451
|
}
|
|
2437
|
-
}),
|
|
2452
|
+
}), C = F({
|
|
2438
2453
|
get: () => e.model.showXGrid ?? !1,
|
|
2439
2454
|
set: (p) => {
|
|
2440
|
-
|
|
2455
|
+
n("update:model", { ...e.model, showXGrid: p });
|
|
2441
2456
|
}
|
|
2442
|
-
}), g =
|
|
2457
|
+
}), g = F({
|
|
2443
2458
|
get: () => e.model.showXTick ?? !0,
|
|
2444
2459
|
set: (p) => {
|
|
2445
|
-
|
|
2460
|
+
n("update:model", { ...e.model, showXTick: p });
|
|
2446
2461
|
}
|
|
2447
|
-
}), _ =
|
|
2462
|
+
}), _ = F({
|
|
2448
2463
|
get: () => e.model.showY ?? !0,
|
|
2449
2464
|
set: (p) => {
|
|
2450
|
-
|
|
2465
|
+
n("update:model", { ...e.model, showY: p });
|
|
2451
2466
|
}
|
|
2452
|
-
}), M =
|
|
2467
|
+
}), M = F({
|
|
2453
2468
|
get: () => e.model.showYGrid ?? !1,
|
|
2454
2469
|
set: (p) => {
|
|
2455
|
-
|
|
2470
|
+
n("update:model", { ...e.model, showYGrid: p });
|
|
2456
2471
|
}
|
|
2457
|
-
}), i =
|
|
2472
|
+
}), i = F({
|
|
2458
2473
|
get: () => e.model.showYTick ?? !0,
|
|
2459
2474
|
set: (p) => {
|
|
2460
|
-
|
|
2475
|
+
n("update:model", { ...e.model, showYTick: p });
|
|
2461
2476
|
}
|
|
2462
|
-
}), s =
|
|
2477
|
+
}), s = F({
|
|
2463
2478
|
get: () => e.model.showXTitle ?? !1,
|
|
2464
2479
|
set: (p) => {
|
|
2465
|
-
|
|
2480
|
+
n("update:model", { ...e.model, showXTitle: p });
|
|
2466
2481
|
}
|
|
2467
|
-
}), y =
|
|
2482
|
+
}), y = F({
|
|
2468
2483
|
get: () => e.model.showYTitle ?? !1,
|
|
2469
2484
|
set: (p) => {
|
|
2470
|
-
|
|
2485
|
+
n("update:model", { ...e.model, showYTitle: p });
|
|
2471
2486
|
}
|
|
2472
|
-
}),
|
|
2473
|
-
|
|
2487
|
+
}), k = qe((p) => {
|
|
2488
|
+
n("update:model", { ...e.model, xTitle: p });
|
|
2474
2489
|
}, 500), U = qe((p) => {
|
|
2475
|
-
|
|
2490
|
+
n("update:model", { ...e.model, yTitle: p });
|
|
2476
2491
|
}, 500);
|
|
2477
2492
|
return xl(() => {
|
|
2478
2493
|
var p, r, B, O;
|
|
2479
|
-
!e.model.xTitle && ((r = (p = e.model.metrics) == null ? void 0 : p[0]) != null && r.label) &&
|
|
2494
|
+
!e.model.xTitle && ((r = (p = e.model.metrics) == null ? void 0 : p[0]) != null && r.label) && k(e.model.metrics[0].label), !e.model.yTitle && ((O = (B = e.model.dimensions) == null ? void 0 : B[0]) != null && O.label) && U(e.model.dimensions[0].label);
|
|
2480
2495
|
}), (p, r) => {
|
|
2481
|
-
const B = L("FmCheckbox"), O = L("FmStepperField"),
|
|
2496
|
+
const B = L("FmCheckbox"), O = L("FmStepperField"), w = L("FmTextField");
|
|
2482
2497
|
return f(), E("div", to, [
|
|
2483
2498
|
c(B, {
|
|
2484
2499
|
modelValue: V.value,
|
|
2485
2500
|
"onUpdate:modelValue": r[0] || (r[0] = (u) => V.value = u),
|
|
2486
|
-
label: l(
|
|
2501
|
+
label: l(a)("report.section.datasource.axis.showX"),
|
|
2487
2502
|
"label-placement": "right",
|
|
2488
2503
|
value: !0
|
|
2489
2504
|
}, null, 8, ["modelValue", "label"]),
|
|
2490
|
-
|
|
2505
|
+
ke(h("div", oo, [
|
|
2491
2506
|
c(B, {
|
|
2492
|
-
modelValue:
|
|
2493
|
-
"onUpdate:modelValue": r[1] || (r[1] = (u) =>
|
|
2494
|
-
label: l(
|
|
2507
|
+
modelValue: C.value,
|
|
2508
|
+
"onUpdate:modelValue": r[1] || (r[1] = (u) => C.value = u),
|
|
2509
|
+
label: l(a)("report.section.datasource.axis.showGrid"),
|
|
2495
2510
|
"label-placement": "right",
|
|
2496
2511
|
value: !1
|
|
2497
2512
|
}, null, 8, ["modelValue", "label"]),
|
|
2498
2513
|
c(B, {
|
|
2499
2514
|
modelValue: g.value,
|
|
2500
2515
|
"onUpdate:modelValue": r[2] || (r[2] = (u) => g.value = u),
|
|
2501
|
-
label: l(
|
|
2516
|
+
label: l(a)("report.section.datasource.axis.showTick"),
|
|
2502
2517
|
"label-placement": "right",
|
|
2503
2518
|
value: !0
|
|
2504
2519
|
}, null, 8, ["modelValue", "label"]),
|
|
2505
|
-
|
|
2520
|
+
ke(h("div", ao, [
|
|
2506
2521
|
c(O, {
|
|
2507
|
-
label: l(
|
|
2522
|
+
label: l(a)("report.section.datasource.fontSize"),
|
|
2508
2523
|
type: "number",
|
|
2509
2524
|
"model-value": p.model.xTickFontSize ?? 12,
|
|
2510
2525
|
min: 1,
|
|
2511
2526
|
"onUpdate:modelValue": r[3] || (r[3] = (u) => {
|
|
2512
|
-
|
|
2527
|
+
n("update:model", { ...p.model, xTickFontSize: Number(u) });
|
|
2513
2528
|
})
|
|
2514
2529
|
}, null, 8, ["label", "model-value"])
|
|
2515
2530
|
], 512), [
|
|
2516
|
-
[
|
|
2531
|
+
[$e, p.model.showXTick ?? !0]
|
|
2517
2532
|
]),
|
|
2518
2533
|
c(B, {
|
|
2519
2534
|
modelValue: s.value,
|
|
2520
2535
|
"onUpdate:modelValue": r[4] || (r[4] = (u) => s.value = u),
|
|
2521
|
-
label: l(
|
|
2536
|
+
label: l(a)("report.section.datasource.axis.showTitle"),
|
|
2522
2537
|
"label-placement": "right",
|
|
2523
2538
|
value: !0
|
|
2524
2539
|
}, null, 8, ["modelValue", "label"]),
|
|
2525
|
-
|
|
2526
|
-
c(
|
|
2540
|
+
ke(h("div", no, [
|
|
2541
|
+
c(w, {
|
|
2527
2542
|
"model-value": p.model.xTitle,
|
|
2528
|
-
label: l(
|
|
2529
|
-
placeholder: l(
|
|
2530
|
-
"onUpdate:modelValue": l(
|
|
2543
|
+
label: l(a)("report.common.title"),
|
|
2544
|
+
placeholder: l(a)("report.tile.widget.titlePlaceholder"),
|
|
2545
|
+
"onUpdate:modelValue": l(k)
|
|
2531
2546
|
}, null, 8, ["model-value", "label", "placeholder", "onUpdate:modelValue"]),
|
|
2532
2547
|
c(O, {
|
|
2533
|
-
label: l(
|
|
2548
|
+
label: l(a)("report.section.datasource.fontSize"),
|
|
2534
2549
|
type: "number",
|
|
2535
2550
|
"model-value": p.model.xTitleFontSize ?? 12,
|
|
2536
2551
|
min: 1,
|
|
2537
2552
|
"onUpdate:modelValue": r[5] || (r[5] = (u) => {
|
|
2538
|
-
|
|
2553
|
+
n("update:model", { ...p.model, xTitleFontSize: Number(u) });
|
|
2539
2554
|
})
|
|
2540
2555
|
}, null, 8, ["label", "model-value"])
|
|
2541
2556
|
], 512), [
|
|
2542
|
-
[
|
|
2557
|
+
[$e, s.value]
|
|
2543
2558
|
])
|
|
2544
2559
|
], 512), [
|
|
2545
|
-
[
|
|
2560
|
+
[$e, p.model.showX ?? !0]
|
|
2546
2561
|
]),
|
|
2547
2562
|
c(B, {
|
|
2548
2563
|
modelValue: _.value,
|
|
2549
2564
|
"onUpdate:modelValue": r[6] || (r[6] = (u) => _.value = u),
|
|
2550
|
-
label: l(
|
|
2565
|
+
label: l(a)("report.section.datasource.axis.showY"),
|
|
2551
2566
|
"label-placement": "right",
|
|
2552
2567
|
value: !0
|
|
2553
2568
|
}, null, 8, ["modelValue", "label"]),
|
|
2554
|
-
|
|
2569
|
+
ke(h("div", io, [
|
|
2555
2570
|
c(B, {
|
|
2556
2571
|
modelValue: M.value,
|
|
2557
2572
|
"onUpdate:modelValue": r[7] || (r[7] = (u) => M.value = u),
|
|
2558
|
-
label: l(
|
|
2573
|
+
label: l(a)("report.section.datasource.axis.showGrid"),
|
|
2559
2574
|
"label-placement": "right",
|
|
2560
2575
|
value: !1
|
|
2561
2576
|
}, null, 8, ["modelValue", "label"]),
|
|
2562
2577
|
c(B, {
|
|
2563
2578
|
modelValue: i.value,
|
|
2564
2579
|
"onUpdate:modelValue": r[8] || (r[8] = (u) => i.value = u),
|
|
2565
|
-
label: l(
|
|
2580
|
+
label: l(a)("report.section.datasource.axis.showTick"),
|
|
2566
2581
|
"label-placement": "right",
|
|
2567
2582
|
value: !0
|
|
2568
2583
|
}, null, 8, ["modelValue", "label"]),
|
|
2569
|
-
|
|
2584
|
+
ke(h("div", so, [
|
|
2570
2585
|
c(O, {
|
|
2571
|
-
label: l(
|
|
2586
|
+
label: l(a)("report.section.datasource.fontSize"),
|
|
2572
2587
|
type: "number",
|
|
2573
2588
|
"model-value": p.model.yTickFontSize ?? 12,
|
|
2574
2589
|
min: 1,
|
|
2575
2590
|
"onUpdate:modelValue": r[9] || (r[9] = (u) => {
|
|
2576
|
-
|
|
2591
|
+
n("update:model", { ...p.model, yTickFontSize: Number(u) });
|
|
2577
2592
|
})
|
|
2578
2593
|
}, null, 8, ["label", "model-value"])
|
|
2579
2594
|
], 512), [
|
|
2580
|
-
[
|
|
2595
|
+
[$e, p.model.showYTick ?? !0]
|
|
2581
2596
|
]),
|
|
2582
2597
|
c(B, {
|
|
2583
2598
|
modelValue: y.value,
|
|
2584
2599
|
"onUpdate:modelValue": r[10] || (r[10] = (u) => y.value = u),
|
|
2585
|
-
label: l(
|
|
2600
|
+
label: l(a)("report.section.datasource.axis.showTitle"),
|
|
2586
2601
|
"label-placement": "right",
|
|
2587
2602
|
value: !0
|
|
2588
2603
|
}, null, 8, ["modelValue", "label"]),
|
|
2589
|
-
|
|
2590
|
-
c(
|
|
2604
|
+
ke(h("div", ro, [
|
|
2605
|
+
c(w, {
|
|
2591
2606
|
"model-value": p.model.yTitle,
|
|
2592
|
-
label: l(
|
|
2593
|
-
placeholder: l(
|
|
2607
|
+
label: l(a)("report.common.title"),
|
|
2608
|
+
placeholder: l(a)("report.tile.widget.titlePlaceholder"),
|
|
2594
2609
|
"onUpdate:modelValue": l(U)
|
|
2595
2610
|
}, null, 8, ["model-value", "label", "placeholder", "onUpdate:modelValue"]),
|
|
2596
2611
|
c(O, {
|
|
2597
|
-
label: l(
|
|
2612
|
+
label: l(a)("report.section.datasource.fontSize"),
|
|
2598
2613
|
type: "number",
|
|
2599
2614
|
"model-value": p.model.yTitleFontSize ?? 12,
|
|
2600
2615
|
min: 1,
|
|
2601
2616
|
"onUpdate:modelValue": r[11] || (r[11] = (u) => {
|
|
2602
|
-
|
|
2617
|
+
n("update:model", { ...p.model, yTitleFontSize: Number(u) });
|
|
2603
2618
|
})
|
|
2604
2619
|
}, null, 8, ["label", "model-value"])
|
|
2605
2620
|
], 512), [
|
|
2606
|
-
[
|
|
2621
|
+
[$e, y.value]
|
|
2607
2622
|
])
|
|
2608
2623
|
], 512), [
|
|
2609
|
-
[
|
|
2624
|
+
[$e, p.model.showY ?? !0]
|
|
2610
2625
|
])
|
|
2611
2626
|
]);
|
|
2612
2627
|
};
|
|
2613
2628
|
}
|
|
2614
|
-
}), mo = { class: "flex flex-col gap-8" }, co = { class: "pl-32 flex flex-col gap-8" }, po = { class: "text-fm-color-typo-primary fm-typo-en-body-lg-600" }, vo = ["onKeydown"], fo = /* @__PURE__ */
|
|
2629
|
+
}), mo = { class: "flex flex-col gap-8" }, co = { class: "pl-32 flex flex-col gap-8" }, po = { class: "text-fm-color-typo-primary fm-typo-en-body-lg-600" }, vo = ["onKeydown"], fo = /* @__PURE__ */ de({
|
|
2615
2630
|
__name: "LegendSection",
|
|
2616
2631
|
props: {
|
|
2617
2632
|
model: {},
|
|
@@ -2619,88 +2634,88 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
2619
2634
|
},
|
|
2620
2635
|
emits: ["update:model"],
|
|
2621
2636
|
setup($, { emit: v }) {
|
|
2622
|
-
const e = $,
|
|
2623
|
-
{ label:
|
|
2624
|
-
{ label:
|
|
2625
|
-
{ label:
|
|
2626
|
-
{ label:
|
|
2627
|
-
],
|
|
2637
|
+
const e = $, n = v, { t: a } = pe(), V = [
|
|
2638
|
+
{ label: a("report.section.datasource.position.top"), value: "top" },
|
|
2639
|
+
{ label: a("report.section.datasource.position.bottom"), value: "bottom" },
|
|
2640
|
+
{ label: a("report.section.datasource.position.left"), value: "left" },
|
|
2641
|
+
{ label: a("report.section.datasource.position.right"), value: "right" }
|
|
2642
|
+
], C = F({
|
|
2628
2643
|
get: () => e.model.showLegend !== void 0 ? e.model.showLegend : e.isCircularWidget === !0,
|
|
2629
2644
|
set: (U) => {
|
|
2630
|
-
|
|
2645
|
+
n("update:model", { ...e.model, showLegend: U });
|
|
2631
2646
|
}
|
|
2632
|
-
}), g =
|
|
2647
|
+
}), g = F({
|
|
2633
2648
|
get: () => e.model.usePointStyle ?? !0,
|
|
2634
2649
|
set: (U) => {
|
|
2635
|
-
|
|
2650
|
+
n("update:model", { ...e.model, usePointStyle: U });
|
|
2636
2651
|
}
|
|
2637
|
-
}), _ =
|
|
2652
|
+
}), _ = F({
|
|
2638
2653
|
get: () => e.model.legendFontSize ?? null,
|
|
2639
2654
|
set: (U) => {
|
|
2640
2655
|
if (U == null) {
|
|
2641
|
-
|
|
2656
|
+
n("update:model", { ...e.model, legendFontSize: void 0 });
|
|
2642
2657
|
return;
|
|
2643
2658
|
}
|
|
2644
|
-
|
|
2659
|
+
n("update:model", { ...e.model, legendFontSize: Math.min(Number(U), 24) });
|
|
2645
2660
|
}
|
|
2646
|
-
}), M =
|
|
2647
|
-
|
|
2661
|
+
}), M = F(() => e.model.legendColor ?? "#6b6b6b"), i = le(M.value), s = le(null);
|
|
2662
|
+
Ce(
|
|
2648
2663
|
() => e.model.legendColor,
|
|
2649
2664
|
(U) => {
|
|
2650
2665
|
i.value = U ?? "#6b6b6b";
|
|
2651
2666
|
}
|
|
2652
2667
|
);
|
|
2653
2668
|
function y() {
|
|
2654
|
-
|
|
2669
|
+
n("update:model", { ...e.model, legendColor: i.value });
|
|
2655
2670
|
}
|
|
2656
|
-
function
|
|
2671
|
+
function k() {
|
|
2657
2672
|
var U;
|
|
2658
2673
|
(U = s.value) == null || U.click();
|
|
2659
2674
|
}
|
|
2660
2675
|
return (U, p) => {
|
|
2661
|
-
const r = L("FmCheckbox"), B = L("FmSelect"), O = L("FmStepperField"),
|
|
2676
|
+
const r = L("FmCheckbox"), B = L("FmSelect"), O = L("FmStepperField"), w = L("FmButton");
|
|
2662
2677
|
return f(), E("div", mo, [
|
|
2663
2678
|
c(r, {
|
|
2664
|
-
modelValue:
|
|
2665
|
-
"onUpdate:modelValue": p[0] || (p[0] = (u) =>
|
|
2679
|
+
modelValue: C.value,
|
|
2680
|
+
"onUpdate:modelValue": p[0] || (p[0] = (u) => C.value = u),
|
|
2666
2681
|
class: "fm-typo-en-body-lg-400",
|
|
2667
2682
|
value: !1,
|
|
2668
|
-
label: l(
|
|
2683
|
+
label: l(a)("report.section.datasource.legend.showLegend")
|
|
2669
2684
|
}, null, 8, ["modelValue", "label"]),
|
|
2670
|
-
|
|
2685
|
+
ke(h("div", co, [
|
|
2671
2686
|
c(r, {
|
|
2672
2687
|
modelValue: g.value,
|
|
2673
2688
|
"onUpdate:modelValue": p[1] || (p[1] = (u) => g.value = u),
|
|
2674
|
-
label: l(
|
|
2689
|
+
label: l(a)("report.section.datasource.legend.usePointStyle"),
|
|
2675
2690
|
value: !1
|
|
2676
2691
|
}, null, 8, ["modelValue", "label"]),
|
|
2677
2692
|
c(B, {
|
|
2678
|
-
label: l(
|
|
2693
|
+
label: l(a)("report.section.datasource.position.showPosition"),
|
|
2679
2694
|
items: V,
|
|
2680
2695
|
"model-value": U.model.legendPosition ?? "top",
|
|
2681
|
-
"onUpdate:modelValue": p[2] || (p[2] = (u) =>
|
|
2696
|
+
"onUpdate:modelValue": p[2] || (p[2] = (u) => n("update:model", { ...U.model, legendPosition: u }))
|
|
2682
2697
|
}, null, 8, ["label", "model-value"]),
|
|
2683
2698
|
c(O, {
|
|
2684
2699
|
modelValue: _.value,
|
|
2685
2700
|
"onUpdate:modelValue": p[3] || (p[3] = (u) => _.value = u),
|
|
2686
|
-
label: l(
|
|
2701
|
+
label: l(a)("report.section.datasource.legend.fontSize"),
|
|
2687
2702
|
max: 24,
|
|
2688
2703
|
min: 1,
|
|
2689
2704
|
type: "number",
|
|
2690
2705
|
placeholder: "Auto"
|
|
2691
2706
|
}, null, 8, ["modelValue", "label"]),
|
|
2692
|
-
h("p", po, G(l(
|
|
2707
|
+
h("p", po, G(l(a)("report.section.datasource.legend.color")), 1),
|
|
2693
2708
|
h("div", {
|
|
2694
2709
|
class: "fm-field fm-field--sm flex items-center justify-between gap-8 border rounded-md p-2 border-[#c7c7cc] cursor-pointer",
|
|
2695
2710
|
role: "button",
|
|
2696
2711
|
tabindex: "0",
|
|
2697
|
-
onClick:
|
|
2712
|
+
onClick: k,
|
|
2698
2713
|
onKeydown: [
|
|
2699
|
-
cl(
|
|
2700
|
-
cl(
|
|
2714
|
+
cl(we(k, ["prevent"]), ["enter"]),
|
|
2715
|
+
cl(we(k, ["prevent"]), ["space"])
|
|
2701
2716
|
]
|
|
2702
2717
|
}, [
|
|
2703
|
-
|
|
2718
|
+
ke(h("input", {
|
|
2704
2719
|
ref_key: "colorInputRef",
|
|
2705
2720
|
ref: s,
|
|
2706
2721
|
"onUpdate:modelValue": p[4] || (p[4] = (u) => i.value = u),
|
|
@@ -2710,22 +2725,22 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
2710
2725
|
[zl, i.value]
|
|
2711
2726
|
])
|
|
2712
2727
|
], 40, vo),
|
|
2713
|
-
c(
|
|
2728
|
+
c(w, {
|
|
2714
2729
|
size: "md",
|
|
2715
|
-
label: l(
|
|
2730
|
+
label: l(a)("report.common.apply"),
|
|
2716
2731
|
disabled: i.value === M.value,
|
|
2717
2732
|
onClick: y
|
|
2718
2733
|
}, null, 8, ["label", "disabled"])
|
|
2719
2734
|
], 512), [
|
|
2720
|
-
[
|
|
2735
|
+
[$e, C.value]
|
|
2721
2736
|
])
|
|
2722
2737
|
]);
|
|
2723
2738
|
};
|
|
2724
2739
|
}
|
|
2725
|
-
}), go = /* @__PURE__ */ $l(fo, [["__scopeId", "data-v-0e072961"]]), yo = { class: "flex flex-col gap-8" }, bo = { class: "flex flex-col sm:flex-row items-center" }, ho = { class: "flex flex-col gap-8" },
|
|
2740
|
+
}), go = /* @__PURE__ */ $l(fo, [["__scopeId", "data-v-0e072961"]]), yo = { class: "flex flex-col gap-8" }, bo = { class: "flex flex-col sm:flex-row items-center" }, ho = { class: "flex flex-col gap-8" }, wo = { class: "flex w-full gap-8 text-fm-color-system-info-300" }, Co = {
|
|
2726
2741
|
key: 1,
|
|
2727
2742
|
class: "grid grid-cols-1 gap-8 sm:grid-cols-2"
|
|
2728
|
-
}, xo = ["title"],
|
|
2743
|
+
}, xo = ["title"], ko = ["aria-label"], Fo = { class: "min-w-0 truncate text-[12px] uppercase leading-none tracking-[0.02em] text-[#6b6b6b]" }, Vo = ["value", "onInput", "onChange"], So = {
|
|
2729
2744
|
key: 0,
|
|
2730
2745
|
class: "flex items-center gap-8"
|
|
2731
2746
|
}, _o = {
|
|
@@ -2734,7 +2749,7 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
2734
2749
|
}, To = { class: "fm-shadow-light-100 rounded-md border border-fm-color-neutral-gray-100 bg-fm-color-neutral-white p-10" }, $o = { class: "mb-8 flex min-w-0 items-center gap-[8px] pb-8" }, Do = ["title"], Uo = ["title"], Bo = { class: "flex w-full items-center gap-8 sm:w-auto sm:shrink-0" }, Ao = ["aria-label"], Lo = { class: "min-w-0 truncate text-[12px] uppercase leading-none tracking-[0.02em]" }, Mo = ["value", "disabled", "onInput", "onChange"], Oo = {
|
|
2735
2750
|
key: 0,
|
|
2736
2751
|
class: "flex items-center gap-8"
|
|
2737
|
-
}, De = 10,
|
|
2752
|
+
}, De = 10, jo = /* @__PURE__ */ de({
|
|
2738
2753
|
__name: "ChartColorSection",
|
|
2739
2754
|
props: {
|
|
2740
2755
|
model: {},
|
|
@@ -2743,26 +2758,26 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
2743
2758
|
},
|
|
2744
2759
|
emits: ["update:model"],
|
|
2745
2760
|
setup($, { emit: v }) {
|
|
2746
|
-
const e = $,
|
|
2761
|
+
const e = $, n = v, { t: a } = pe(), V = F(() => e.limitToSeriesMode ? [
|
|
2747
2762
|
{
|
|
2748
|
-
label:
|
|
2763
|
+
label: a("report.section.datasource.styleTarget.series"),
|
|
2749
2764
|
value: ne.series
|
|
2750
2765
|
}
|
|
2751
2766
|
] : [
|
|
2752
2767
|
{
|
|
2753
|
-
label:
|
|
2768
|
+
label: a("report.section.datasource.styleTarget.series"),
|
|
2754
2769
|
value: ne.series
|
|
2755
2770
|
},
|
|
2756
2771
|
{
|
|
2757
|
-
label:
|
|
2772
|
+
label: a("report.section.datasource.styleTarget.metric"),
|
|
2758
2773
|
value: ne.metric
|
|
2759
2774
|
},
|
|
2760
2775
|
{
|
|
2761
|
-
label:
|
|
2776
|
+
label: a("report.section.datasource.styleTarget.breakdown"),
|
|
2762
2777
|
value: ne.breakdown
|
|
2763
2778
|
}
|
|
2764
2779
|
]);
|
|
2765
|
-
function
|
|
2780
|
+
function C(x) {
|
|
2766
2781
|
return e.limitToSeriesMode ? ne.series : x === ne.breakdown ? ne.breakdown : x === ne.metric ? ne.metric : ne.series;
|
|
2767
2782
|
}
|
|
2768
2783
|
function g() {
|
|
@@ -2776,7 +2791,7 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
2776
2791
|
}
|
|
2777
2792
|
function _(x, S) {
|
|
2778
2793
|
var P, H;
|
|
2779
|
-
return x ? ((P = x.label) == null ? void 0 : P.trim()) || ((H = x.name) == null ? void 0 : H.trim()) || `${
|
|
2794
|
+
return x ? ((P = x.label) == null ? void 0 : P.trim()) || ((H = x.name) == null ? void 0 : H.trim()) || `${a("report.section.datasource.styleTarget.metric")} ${S + 1}` : `${a("report.section.datasource.styleTarget.metric")} ${S + 1}`;
|
|
2780
2795
|
}
|
|
2781
2796
|
function M(x) {
|
|
2782
2797
|
if (x === ne.breakdown)
|
|
@@ -2786,31 +2801,31 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
2786
2801
|
if (S.length > 0)
|
|
2787
2802
|
return S.map((T, P) => _(T, P));
|
|
2788
2803
|
}
|
|
2789
|
-
return
|
|
2790
|
-
(S, T) => `${
|
|
2804
|
+
return fe.map(
|
|
2805
|
+
(S, T) => `${a("report.section.datasource.chartColor.series")} ${T + 1}`
|
|
2791
2806
|
);
|
|
2792
2807
|
}
|
|
2793
2808
|
function i(x) {
|
|
2794
2809
|
return Array.from({ length: Math.max(1, x) }).map(
|
|
2795
|
-
(S, T) => `${
|
|
2810
|
+
(S, T) => `${a("report.section.datasource.chartColor.series")} ${T + 1}`
|
|
2796
2811
|
);
|
|
2797
2812
|
}
|
|
2798
2813
|
function s(x, S) {
|
|
2799
2814
|
const T = Array.isArray(x) ? x.length : 0, P = Array.isArray(S) ? S.length : 0;
|
|
2800
|
-
return Math.max(
|
|
2815
|
+
return Math.max(fe.length, T, P, 1);
|
|
2801
2816
|
}
|
|
2802
|
-
const y =
|
|
2817
|
+
const y = F(() => {
|
|
2803
2818
|
const x = g();
|
|
2804
|
-
return x.length === 0 ? [
|
|
2805
|
-
}),
|
|
2819
|
+
return x.length === 0 ? [a("report.section.datasource.styleTarget.metric")] : x.map((S, T) => _(S, T));
|
|
2820
|
+
}), k = le(fe.length), U = le(fe.length);
|
|
2806
2821
|
function p(x, S) {
|
|
2807
2822
|
const T = Math.max(1, S), P = Array.isArray(x) ? x.length : 0, H = P > 0 ? Math.ceil(P / T) : 0;
|
|
2808
|
-
return Math.max(
|
|
2823
|
+
return Math.max(fe.length, H, 1);
|
|
2809
2824
|
}
|
|
2810
|
-
const r =
|
|
2825
|
+
const r = F(() => {
|
|
2811
2826
|
const x = Math.max(1, U.value);
|
|
2812
2827
|
return Array.from({ length: x }).map(
|
|
2813
|
-
(S, T) => `${
|
|
2828
|
+
(S, T) => `${a("report.section.datasource.styleTarget.breakdown")} ${T + 1}`
|
|
2814
2829
|
);
|
|
2815
2830
|
});
|
|
2816
2831
|
function B(x, S) {
|
|
@@ -2823,7 +2838,7 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
2823
2838
|
function O(x) {
|
|
2824
2839
|
return Math.min(0.55 + (x - 1) * 0.18, 0.95);
|
|
2825
2840
|
}
|
|
2826
|
-
function
|
|
2841
|
+
function w(x, S, T) {
|
|
2827
2842
|
return x * T + S;
|
|
2828
2843
|
}
|
|
2829
2844
|
function u(x, S, T, P) {
|
|
@@ -2831,20 +2846,20 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
2831
2846
|
if (x.length === 0 || H <= 0)
|
|
2832
2847
|
return [];
|
|
2833
2848
|
const W = ll(x.length);
|
|
2834
|
-
return x.flatMap((X,
|
|
2835
|
-
const ee = W[
|
|
2849
|
+
return x.flatMap((X, te) => {
|
|
2850
|
+
const ee = W[te], ce = T == null ? void 0 : T[w(te, 0, H)], Le = Y(ce) ?? ee;
|
|
2836
2851
|
return S.map((Ze, Me) => {
|
|
2837
|
-
const Rl =
|
|
2852
|
+
const Rl = w(te, Me, H), ml = Me === 0 ? Le : B(Le, O(Me));
|
|
2838
2853
|
return P && Me > 0 ? ml : Y(T == null ? void 0 : T[Rl]) ?? ml;
|
|
2839
2854
|
});
|
|
2840
2855
|
});
|
|
2841
2856
|
}
|
|
2842
|
-
const
|
|
2857
|
+
const j = /^#([0-9a-fA-F]{3}|[0-9a-fA-F]{6})$/;
|
|
2843
2858
|
function Y(x) {
|
|
2844
2859
|
if (!x)
|
|
2845
2860
|
return null;
|
|
2846
2861
|
const S = x.trim();
|
|
2847
|
-
if (!
|
|
2862
|
+
if (!j.test(S))
|
|
2848
2863
|
return null;
|
|
2849
2864
|
if (S.length === 4) {
|
|
2850
2865
|
const T = S.charAt(1), P = S.charAt(2), H = S.charAt(3);
|
|
@@ -2880,13 +2895,13 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
2880
2895
|
}
|
|
2881
2896
|
return T;
|
|
2882
2897
|
}
|
|
2883
|
-
const z =
|
|
2898
|
+
const z = F(() => N.value === ne.series ? i(k.value) : M(N.value)), J = F(
|
|
2884
2899
|
() => Array.from({ length: z.value.length }).map((x, S) => ({
|
|
2885
2900
|
label: `L${S + 1}`,
|
|
2886
2901
|
value: S + 1
|
|
2887
2902
|
}))
|
|
2888
|
-
), ie =
|
|
2889
|
-
|
|
2903
|
+
), ie = F(() => typeof e.showLayerControl == "boolean" ? e.showLayerControl : !!e.model.stackBarOverlap), D = le([]), m = le([]), o = le([]), b = le(!0), N = le(ne.series), oe = le(!0), se = le(!1), me = le(!1);
|
|
2904
|
+
Ce(
|
|
2890
2905
|
[
|
|
2891
2906
|
() => e.model.chartColors,
|
|
2892
2907
|
() => e.model.chartColorBinding,
|
|
@@ -2897,58 +2912,58 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
2897
2912
|
() => e.model.joinDatasources
|
|
2898
2913
|
],
|
|
2899
2914
|
([x, S]) => {
|
|
2900
|
-
|
|
2915
|
+
se.value = !0, N.value = C(S), k.value = s(
|
|
2901
2916
|
x,
|
|
2902
2917
|
e.model.chartColorLayers
|
|
2903
2918
|
), U.value = p(
|
|
2904
2919
|
e.model.chartBreakdownColors,
|
|
2905
2920
|
Math.max(1, y.value.length)
|
|
2906
2921
|
);
|
|
2907
|
-
const T =
|
|
2922
|
+
const T = N.value === ne.series ? k.value : M(N.value).length;
|
|
2908
2923
|
D.value = t(x, T), m.value = A(e.model.chartColorLayers, T), b.value = e.model.chartUseSecondaryMetricShades !== !1, o.value = u(
|
|
2909
2924
|
r.value,
|
|
2910
2925
|
y.value,
|
|
2911
2926
|
e.model.chartBreakdownColors,
|
|
2912
2927
|
b.value
|
|
2913
|
-
),
|
|
2928
|
+
), se.value = !1;
|
|
2914
2929
|
},
|
|
2915
2930
|
{ immediate: !0, deep: !0 }
|
|
2916
2931
|
);
|
|
2917
2932
|
function Q() {
|
|
2918
|
-
const x =
|
|
2919
|
-
Array.from({ length:
|
|
2933
|
+
const x = N.value === ne.series, S = N.value === ne.series ? fe.length : M(N.value).length, T = t(void 0, S), P = A(void 0, S), H = D.value.length === T.length && D.value.every((ee, ce) => ee === T[ce]), W = m.value.length === P.length && m.value.every((ee, ce) => ee === P[ce]), X = u(
|
|
2934
|
+
Array.from({ length: fe.length }, (ee, ce) => `breakdown-${ce + 1}`),
|
|
2920
2935
|
y.value,
|
|
2921
2936
|
void 0,
|
|
2922
2937
|
b.value
|
|
2923
|
-
),
|
|
2938
|
+
), te = o.value.length === X.length && o.value.every((ee, ce) => ee === X[ce]);
|
|
2924
2939
|
return {
|
|
2925
2940
|
...e.model,
|
|
2926
|
-
chartColorBinding: x ? void 0 :
|
|
2941
|
+
chartColorBinding: x ? void 0 : N.value,
|
|
2927
2942
|
chartColors: H ? void 0 : [...D.value],
|
|
2928
2943
|
chartColorLayers: W ? void 0 : [...m.value],
|
|
2929
|
-
chartBreakdownColors:
|
|
2944
|
+
chartBreakdownColors: te ? void 0 : [...o.value],
|
|
2930
2945
|
chartUseSecondaryMetricShades: b.value
|
|
2931
2946
|
};
|
|
2932
2947
|
}
|
|
2933
2948
|
function Re() {
|
|
2934
2949
|
const x = Q();
|
|
2935
|
-
Ml(x) ||
|
|
2950
|
+
Ml(x) || n("update:model", x);
|
|
2936
2951
|
}
|
|
2937
|
-
function
|
|
2938
|
-
|
|
2952
|
+
function _e() {
|
|
2953
|
+
se.value || me.value || Re();
|
|
2939
2954
|
}
|
|
2940
|
-
|
|
2955
|
+
Ce(
|
|
2941
2956
|
[
|
|
2942
2957
|
D,
|
|
2943
2958
|
m,
|
|
2944
2959
|
o,
|
|
2945
2960
|
b,
|
|
2946
|
-
|
|
2947
|
-
|
|
2961
|
+
N,
|
|
2962
|
+
k,
|
|
2948
2963
|
U
|
|
2949
2964
|
],
|
|
2950
2965
|
() => {
|
|
2951
|
-
|
|
2966
|
+
_e();
|
|
2952
2967
|
},
|
|
2953
2968
|
{ deep: !0 }
|
|
2954
2969
|
);
|
|
@@ -2962,11 +2977,11 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
2962
2977
|
function ye(x) {
|
|
2963
2978
|
if (e.limitToSeriesMode)
|
|
2964
2979
|
return;
|
|
2965
|
-
const S =
|
|
2966
|
-
if (S ===
|
|
2980
|
+
const S = C(x);
|
|
2981
|
+
if (S === N.value)
|
|
2967
2982
|
return;
|
|
2968
|
-
const T = S === ne.series ?
|
|
2969
|
-
|
|
2983
|
+
const T = S === ne.series ? k.value : M(S).length;
|
|
2984
|
+
N.value = S, D.value = t(D.value, T), m.value = A(m.value, T), S === ne.breakdown && (o.value = u(
|
|
2970
2985
|
r.value,
|
|
2971
2986
|
y.value,
|
|
2972
2987
|
o.value,
|
|
@@ -2976,20 +2991,20 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
2976
2991
|
function he(x, S) {
|
|
2977
2992
|
return x + 1 === S ? "add" : "remove";
|
|
2978
2993
|
}
|
|
2979
|
-
function
|
|
2980
|
-
const S = Math.max(
|
|
2994
|
+
function Te(x) {
|
|
2995
|
+
const S = Math.max(fe.length, k.value), T = x + 1;
|
|
2981
2996
|
if (T === S) {
|
|
2982
2997
|
const ee = S + De;
|
|
2983
|
-
|
|
2998
|
+
k.value = ee, D.value = t(D.value, ee), m.value = A(m.value, ee);
|
|
2984
2999
|
return;
|
|
2985
3000
|
}
|
|
2986
|
-
if (S <=
|
|
3001
|
+
if (S <= fe.length)
|
|
2987
3002
|
return;
|
|
2988
|
-
const H = T, W = Math.max(
|
|
2989
|
-
X.splice(H, De),
|
|
3003
|
+
const H = T, W = Math.max(fe.length, S - De), X = [...D.value], te = [...m.value];
|
|
3004
|
+
X.splice(H, De), te.splice(H, De), k.value = W, D.value = t(X, W), m.value = A(te, W);
|
|
2990
3005
|
}
|
|
2991
3006
|
function Z(x) {
|
|
2992
|
-
const S = Math.max(
|
|
3007
|
+
const S = Math.max(fe.length, U.value), T = x + 1;
|
|
2993
3008
|
if (T === S) {
|
|
2994
3009
|
const Le = S + De;
|
|
2995
3010
|
U.value = Le, o.value = u(
|
|
@@ -3000,13 +3015,13 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3000
3015
|
);
|
|
3001
3016
|
return;
|
|
3002
3017
|
}
|
|
3003
|
-
if (S <=
|
|
3018
|
+
if (S <= fe.length)
|
|
3004
3019
|
return;
|
|
3005
|
-
const H = Math.max(1, y.value.length), X = T * H,
|
|
3006
|
-
|
|
3020
|
+
const H = Math.max(1, y.value.length), X = T * H, te = De * H, ee = Math.max(fe.length, S - De), ce = [...o.value];
|
|
3021
|
+
ce.splice(X, te), U.value = ee, o.value = u(
|
|
3007
3022
|
Array.from({ length: ee }, (Le, Ze) => `breakdown-${Ze + 1}`),
|
|
3008
3023
|
y.value,
|
|
3009
|
-
|
|
3024
|
+
ce,
|
|
3010
3025
|
b.value
|
|
3011
3026
|
);
|
|
3012
3027
|
}
|
|
@@ -3021,36 +3036,36 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3021
3036
|
if (W === P)
|
|
3022
3037
|
return;
|
|
3023
3038
|
const X = H.findIndex(
|
|
3024
|
-
(
|
|
3039
|
+
(te, ee) => ee !== x && te === P
|
|
3025
3040
|
);
|
|
3026
3041
|
X >= 0 && (H[X] = W), H[x] = P, m.value = H;
|
|
3027
3042
|
}
|
|
3028
3043
|
function We(x, S) {
|
|
3029
3044
|
const T = S.target;
|
|
3030
|
-
T && (
|
|
3045
|
+
T && (me.value = !0, Be(x, T.value));
|
|
3031
3046
|
}
|
|
3032
3047
|
function Xe(x, S) {
|
|
3033
3048
|
const T = S.target;
|
|
3034
|
-
T && (Be(x, T.value),
|
|
3049
|
+
T && (Be(x, T.value), me.value = !1, _e());
|
|
3035
3050
|
}
|
|
3036
3051
|
function ae(x, S, T) {
|
|
3037
3052
|
const P = T.target;
|
|
3038
3053
|
if (!P)
|
|
3039
3054
|
return;
|
|
3040
|
-
|
|
3055
|
+
me.value = !0;
|
|
3041
3056
|
const H = Y(P.value);
|
|
3042
3057
|
if (!H)
|
|
3043
3058
|
return;
|
|
3044
3059
|
const W = y.value.length;
|
|
3045
3060
|
if (W <= 0)
|
|
3046
3061
|
return;
|
|
3047
|
-
const X =
|
|
3048
|
-
if (
|
|
3062
|
+
const X = w(x, S, W), te = [...o.value];
|
|
3063
|
+
if (te[X] = H, b.value && S === 0)
|
|
3049
3064
|
for (let ee = 1; ee < W; ee++) {
|
|
3050
|
-
const
|
|
3051
|
-
|
|
3065
|
+
const ce = w(x, ee, W);
|
|
3066
|
+
te[ce] = B(H, O(ee));
|
|
3052
3067
|
}
|
|
3053
|
-
o.value =
|
|
3068
|
+
o.value = te;
|
|
3054
3069
|
}
|
|
3055
3070
|
function Bl(x, S, T) {
|
|
3056
3071
|
const P = T.target;
|
|
@@ -3058,31 +3073,31 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3058
3073
|
return;
|
|
3059
3074
|
const H = Y(P.value);
|
|
3060
3075
|
if (!H) {
|
|
3061
|
-
|
|
3076
|
+
me.value = !1, _e();
|
|
3062
3077
|
return;
|
|
3063
3078
|
}
|
|
3064
3079
|
const W = y.value.length;
|
|
3065
3080
|
if (W <= 0) {
|
|
3066
|
-
|
|
3081
|
+
me.value = !1, _e();
|
|
3067
3082
|
return;
|
|
3068
3083
|
}
|
|
3069
|
-
const X =
|
|
3070
|
-
if (
|
|
3084
|
+
const X = w(x, S, W), te = [...o.value];
|
|
3085
|
+
if (te[X] = H, b.value && S === 0)
|
|
3071
3086
|
for (let ee = 1; ee < W; ee++) {
|
|
3072
|
-
const
|
|
3073
|
-
|
|
3087
|
+
const ce = w(x, ee, W);
|
|
3088
|
+
te[ce] = B(H, O(ee));
|
|
3074
3089
|
}
|
|
3075
|
-
o.value =
|
|
3090
|
+
o.value = te, me.value = !1, _e();
|
|
3076
3091
|
}
|
|
3077
3092
|
function Al(x, S) {
|
|
3078
3093
|
const T = d(), P = y.value.length;
|
|
3079
3094
|
if (P <= 0)
|
|
3080
3095
|
return;
|
|
3081
|
-
const H =
|
|
3096
|
+
const H = w(x, S, P), W = [...o.value];
|
|
3082
3097
|
if (W[H] = T, b.value && S === 0)
|
|
3083
3098
|
for (let X = 1; X < P; X++) {
|
|
3084
|
-
const
|
|
3085
|
-
W[
|
|
3099
|
+
const te = w(x, X, P);
|
|
3100
|
+
W[te] = B(T, O(X));
|
|
3086
3101
|
}
|
|
3087
3102
|
o.value = W;
|
|
3088
3103
|
}
|
|
@@ -3105,22 +3120,22 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3105
3120
|
b.value
|
|
3106
3121
|
);
|
|
3107
3122
|
}
|
|
3108
|
-
function
|
|
3109
|
-
|
|
3110
|
-
Array.from({ length:
|
|
3123
|
+
function jl() {
|
|
3124
|
+
N.value = ne.series, k.value = fe.length, U.value = fe.length, D.value = t(void 0, fe.length), m.value = A(void 0, fe.length), b.value = !0, o.value = u(
|
|
3125
|
+
Array.from({ length: fe.length }, (x, S) => `breakdown-${S + 1}`),
|
|
3111
3126
|
y.value,
|
|
3112
3127
|
void 0,
|
|
3113
3128
|
!0
|
|
3114
3129
|
);
|
|
3115
3130
|
}
|
|
3116
|
-
function
|
|
3117
|
-
|
|
3131
|
+
function Nl() {
|
|
3132
|
+
oe.value = !oe.value;
|
|
3118
3133
|
}
|
|
3119
3134
|
function dl(x) {
|
|
3120
3135
|
return (x + 1) % De === 0;
|
|
3121
3136
|
}
|
|
3122
3137
|
return il(() => {
|
|
3123
|
-
|
|
3138
|
+
me.value = !1;
|
|
3124
3139
|
}), (x, S) => {
|
|
3125
3140
|
const T = L("FmButton"), P = L("FmSelect"), H = L("FmCheckbox");
|
|
3126
3141
|
return f(), E("div", yo, [
|
|
@@ -3129,55 +3144,55 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3129
3144
|
variant: "tertiary",
|
|
3130
3145
|
size: "md",
|
|
3131
3146
|
class: "min-w-0 w-full sm:flex-1 sm:w-auto !justify-start",
|
|
3132
|
-
label: l(
|
|
3133
|
-
"prepend-icon":
|
|
3134
|
-
"aria-expanded":
|
|
3135
|
-
onClick:
|
|
3147
|
+
label: l(a)("report.section.datasource.chartColor.title"),
|
|
3148
|
+
"prepend-icon": oe.value ? "expand_less" : "expand_more",
|
|
3149
|
+
"aria-expanded": oe.value ? "true" : "false",
|
|
3150
|
+
onClick: Nl
|
|
3136
3151
|
}, null, 8, ["label", "prepend-icon", "aria-expanded"])
|
|
3137
3152
|
]),
|
|
3138
|
-
|
|
3153
|
+
ke(h("div", ho, [
|
|
3139
3154
|
c(P, {
|
|
3140
|
-
"model-value":
|
|
3155
|
+
"model-value": N.value,
|
|
3141
3156
|
items: V.value,
|
|
3142
3157
|
"onUpdate:modelValue": ye
|
|
3143
3158
|
}, null, 8, ["model-value", "items"]),
|
|
3144
|
-
h("div",
|
|
3159
|
+
h("div", wo, [
|
|
3145
3160
|
c(T, {
|
|
3146
3161
|
variant: "tertiary",
|
|
3147
3162
|
"text-color": "text-fm-color-system-info-300",
|
|
3148
3163
|
size: "md",
|
|
3149
3164
|
class: "w-full",
|
|
3150
|
-
label: l(
|
|
3151
|
-
onClick:
|
|
3165
|
+
label: l(a)("report.section.datasource.chartColor.reset"),
|
|
3166
|
+
onClick: jl
|
|
3152
3167
|
}, null, 8, ["label"])
|
|
3153
3168
|
]),
|
|
3154
|
-
|
|
3169
|
+
N.value === l(ne).breakdown ? (f(), R(H, {
|
|
3155
3170
|
key: 0,
|
|
3156
3171
|
"model-value": b.value,
|
|
3157
3172
|
value: !1,
|
|
3158
|
-
label: l(
|
|
3173
|
+
label: l(a)("report.section.datasource.chartColor.secondaryMetricAutoShade"),
|
|
3159
3174
|
"onUpdate:modelValue": S[0] || (S[0] = (W) => Ol(!!W)),
|
|
3160
3175
|
class: "p-4"
|
|
3161
3176
|
}, null, 8, ["model-value", "label"])) : I("", !0),
|
|
3162
|
-
|
|
3163
|
-
(f(!0), E(
|
|
3177
|
+
N.value !== l(ne).breakdown ? (f(), E("div", Co, [
|
|
3178
|
+
(f(!0), E(ue, null, Se(D.value, (W, X) => (f(), E(ue, {
|
|
3164
3179
|
key: `series-color-${X}`
|
|
3165
3180
|
}, [
|
|
3166
3181
|
h("div", {
|
|
3167
|
-
class:
|
|
3182
|
+
class: Fe([
|
|
3168
3183
|
"fm-shadow-light-100 rounded-md border border-fm-color-neutral-gray-100 p-10",
|
|
3169
3184
|
ie.value ? "flex flex-col gap-8" : "flex flex-col gap-8 sm:flex-row sm:items-center sm:justify-between sm:gap-12"
|
|
3170
3185
|
])
|
|
3171
3186
|
}, [
|
|
3172
3187
|
h("span", {
|
|
3173
|
-
class:
|
|
3188
|
+
class: Fe([
|
|
3174
3189
|
"fm-typo-en-body-lg-600 min-w-0",
|
|
3175
3190
|
ie.value ? "line-clamp-2 break-words" : "whitespace-normal break-words sm:flex-1"
|
|
3176
3191
|
]),
|
|
3177
|
-
title: z.value[X] || `${l(
|
|
3178
|
-
}, G(z.value[X] || `${l(
|
|
3192
|
+
title: z.value[X] || `${l(a)("report.section.datasource.chartColor.color")} ${X + 1}`
|
|
3193
|
+
}, G(z.value[X] || `${l(a)("report.section.datasource.chartColor.color")} ${X + 1}`), 11, xo),
|
|
3179
3194
|
h("div", {
|
|
3180
|
-
class:
|
|
3195
|
+
class: Fe([
|
|
3181
3196
|
"flex items-center gap-8",
|
|
3182
3197
|
ie.value ? "justify-between" : "w-full flex-wrap items-center justify-between sm:w-auto sm:flex-nowrap sm:shrink-0"
|
|
3183
3198
|
])
|
|
@@ -3187,7 +3202,7 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3187
3202
|
class: "min-w-[92px]",
|
|
3188
3203
|
"model-value": m.value[X],
|
|
3189
3204
|
items: J.value,
|
|
3190
|
-
"onUpdate:modelValue": (
|
|
3205
|
+
"onUpdate:modelValue": (te) => Ee(X, te)
|
|
3191
3206
|
}, null, 8, ["model-value", "items", "onUpdate:modelValue"])) : I("", !0),
|
|
3192
3207
|
h("label", {
|
|
3193
3208
|
class: "relative inline-flex min-h-[34px] min-w-0 flex-1 cursor-pointer items-center gap-[8px] rounded-[8px] border border-[#d8d8d8] bg-white py-[4px] pl-[4px] pr-[8px] sm:flex-none",
|
|
@@ -3197,20 +3212,20 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3197
3212
|
class: "inline-block h-[20px] w-[28px] rounded-[4px] border border-[#cfcfcf]",
|
|
3198
3213
|
style: ol({ backgroundColor: W })
|
|
3199
3214
|
}, null, 4),
|
|
3200
|
-
h("span",
|
|
3215
|
+
h("span", Fo, G(W), 1),
|
|
3201
3216
|
h("input", {
|
|
3202
3217
|
type: "color",
|
|
3203
3218
|
value: W,
|
|
3204
3219
|
class: "absolute inset-0 cursor-pointer opacity-0",
|
|
3205
|
-
onInput: (
|
|
3206
|
-
onChange: (
|
|
3220
|
+
onInput: (te) => We(X, te),
|
|
3221
|
+
onChange: (te) => Xe(X, te)
|
|
3207
3222
|
}, null, 40, Vo)
|
|
3208
|
-
], 8,
|
|
3223
|
+
], 8, ko),
|
|
3209
3224
|
c(T, {
|
|
3210
3225
|
variant: "tertiary",
|
|
3211
3226
|
size: "md",
|
|
3212
3227
|
icon: "casino",
|
|
3213
|
-
onClick: (
|
|
3228
|
+
onClick: (te) => xe(X)
|
|
3214
3229
|
}, null, 8, ["onClick"])
|
|
3215
3230
|
], 2)
|
|
3216
3231
|
], 2),
|
|
@@ -3218,13 +3233,13 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3218
3233
|
c(T, {
|
|
3219
3234
|
class: "w-full",
|
|
3220
3235
|
size: "md",
|
|
3221
|
-
icon: he(X,
|
|
3222
|
-
onClick: (
|
|
3236
|
+
icon: he(X, k.value),
|
|
3237
|
+
onClick: (te) => Te(X)
|
|
3223
3238
|
}, null, 8, ["icon", "onClick"])
|
|
3224
3239
|
])) : I("", !0)
|
|
3225
3240
|
], 64))), 128))
|
|
3226
3241
|
])) : (f(), E("div", _o, [
|
|
3227
|
-
(f(!0), E(
|
|
3242
|
+
(f(!0), E(ue, null, Se(r.value, (W, X) => (f(), E(ue, {
|
|
3228
3243
|
key: `breakdown-group-${X}`
|
|
3229
3244
|
}, [
|
|
3230
3245
|
h("div", To, [
|
|
@@ -3234,17 +3249,17 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3234
3249
|
title: W
|
|
3235
3250
|
}, G(W), 9, Do)
|
|
3236
3251
|
]),
|
|
3237
|
-
(f(!0), E(
|
|
3238
|
-
key: `${W}-${
|
|
3252
|
+
(f(!0), E(ue, null, Se(y.value, (te, ee) => (f(), E("div", {
|
|
3253
|
+
key: `${W}-${te}-${ee}`,
|
|
3239
3254
|
class: "flex flex-col items-stretch gap-8 py-4 sm:flex-row sm:items-center sm:justify-between"
|
|
3240
3255
|
}, [
|
|
3241
3256
|
h("span", {
|
|
3242
3257
|
class: "fm-typo-en-body-md-400 min-w-0 flex-1 break-words sm:overflow-hidden sm:text-ellipsis sm:whitespace-nowrap",
|
|
3243
|
-
title:
|
|
3244
|
-
}, G(
|
|
3258
|
+
title: te
|
|
3259
|
+
}, G(te), 9, Uo),
|
|
3245
3260
|
h("div", Bo, [
|
|
3246
3261
|
h("label", {
|
|
3247
|
-
class:
|
|
3262
|
+
class: Fe(["relative inline-flex min-h-[34px] min-w-0 flex-1 items-center gap-[8px] rounded-[8px] border border-[#d8d8d8] bg-white py-[4px] pl-[4px] pr-[8px] sm:w-full sm:max-w-[126px]", {
|
|
3248
3263
|
"cursor-not-allowed opacity-[0.55]": b.value && ee > 0,
|
|
3249
3264
|
"cursor-pointer": !(b.value && ee > 0)
|
|
3250
3265
|
}]),
|
|
@@ -3253,20 +3268,20 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3253
3268
|
h("span", {
|
|
3254
3269
|
class: "inline-block h-[20px] w-[28px] rounded-[4px] border border-[#cfcfcf]",
|
|
3255
3270
|
style: ol({
|
|
3256
|
-
backgroundColor: o.value[
|
|
3271
|
+
backgroundColor: o.value[w(X, ee, y.value.length)]
|
|
3257
3272
|
})
|
|
3258
3273
|
}, null, 4),
|
|
3259
|
-
h("span", Lo, G(o.value[
|
|
3274
|
+
h("span", Lo, G(o.value[w(X, ee, y.value.length)]), 1),
|
|
3260
3275
|
h("input", {
|
|
3261
3276
|
type: "color",
|
|
3262
|
-
value: o.value[
|
|
3263
|
-
class:
|
|
3277
|
+
value: o.value[w(X, ee, y.value.length)],
|
|
3278
|
+
class: Fe(["absolute inset-0 opacity-0", {
|
|
3264
3279
|
"cursor-not-allowed": b.value && ee > 0,
|
|
3265
3280
|
"cursor-pointer": !(b.value && ee > 0)
|
|
3266
3281
|
}]),
|
|
3267
3282
|
disabled: b.value && ee > 0,
|
|
3268
|
-
onInput: (
|
|
3269
|
-
onChange: (
|
|
3283
|
+
onInput: (ce) => ae(X, ee, ce),
|
|
3284
|
+
onChange: (ce) => Bl(X, ee, ce)
|
|
3270
3285
|
}, null, 42, Mo)
|
|
3271
3286
|
], 10, Ao),
|
|
3272
3287
|
c(T, {
|
|
@@ -3275,7 +3290,7 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3275
3290
|
icon: "casino",
|
|
3276
3291
|
class: "shrink-0",
|
|
3277
3292
|
disabled: b.value && ee > 0,
|
|
3278
|
-
onClick: (
|
|
3293
|
+
onClick: (ce) => Al(X, ee)
|
|
3279
3294
|
}, null, 8, ["disabled", "onClick"])
|
|
3280
3295
|
])
|
|
3281
3296
|
]))), 128))
|
|
@@ -3285,40 +3300,40 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3285
3300
|
class: "w-full",
|
|
3286
3301
|
size: "md",
|
|
3287
3302
|
icon: he(X, U.value),
|
|
3288
|
-
onClick: (
|
|
3303
|
+
onClick: (te) => Z(X)
|
|
3289
3304
|
}, null, 8, ["icon", "onClick"])
|
|
3290
3305
|
])) : I("", !0)
|
|
3291
3306
|
], 64))), 128))
|
|
3292
3307
|
]))
|
|
3293
3308
|
], 512), [
|
|
3294
|
-
[
|
|
3309
|
+
[$e, oe.value]
|
|
3295
3310
|
])
|
|
3296
3311
|
]);
|
|
3297
3312
|
};
|
|
3298
3313
|
}
|
|
3299
|
-
}),
|
|
3314
|
+
}), No = { class: "flex flex-col gap-8" }, Ro = { class: "flex items-center justify-between" }, zo = { class: "fm-typo-en-body-lg-600" }, Io = { class: "flex items-center gap-8 text-fm-color-system-info-300" }, Po = { class: "grid grid-cols-2 gap-8" }, Eo = { class: "flex items-center gap-8" }, Wo = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, Xo = /* @__PURE__ */ de({
|
|
3300
3315
|
__name: "ChartLineStyleSection",
|
|
3301
3316
|
props: {
|
|
3302
3317
|
model: {}
|
|
3303
3318
|
},
|
|
3304
3319
|
emits: ["update:model"],
|
|
3305
3320
|
setup($, { emit: v }) {
|
|
3306
|
-
const e = $,
|
|
3321
|
+
const e = $, n = v, { t: a } = pe(), V = F(() => [
|
|
3307
3322
|
{
|
|
3308
|
-
label:
|
|
3323
|
+
label: a("report.section.datasource.styleTarget.series"),
|
|
3309
3324
|
value: ne.series
|
|
3310
3325
|
},
|
|
3311
3326
|
{
|
|
3312
|
-
label:
|
|
3327
|
+
label: a("report.section.datasource.styleTarget.metric"),
|
|
3313
3328
|
value: ne.metric
|
|
3314
3329
|
}
|
|
3315
3330
|
]);
|
|
3316
|
-
function
|
|
3317
|
-
return t && typeof t == "object" && "value" in t ?
|
|
3331
|
+
function C(t) {
|
|
3332
|
+
return t && typeof t == "object" && "value" in t ? C(t.value) : t === ne.metric ? ne.metric : ne.series;
|
|
3318
3333
|
}
|
|
3319
3334
|
function g(t, A) {
|
|
3320
3335
|
var J, ie;
|
|
3321
|
-
return t ? ((J = t.label) == null ? void 0 : J.trim()) || ((ie = t.name) == null ? void 0 : ie.trim()) || `${
|
|
3336
|
+
return t ? ((J = t.label) == null ? void 0 : J.trim()) || ((ie = t.name) == null ? void 0 : ie.trim()) || `${a("report.section.datasource.styleTarget.metric")} ${A + 1}` : `${a("report.section.datasource.styleTarget.metric")} ${A + 1}`;
|
|
3322
3337
|
}
|
|
3323
3338
|
function _() {
|
|
3324
3339
|
const t = Array.isArray(e.model.metrics) ? e.model.metrics : [];
|
|
@@ -3335,21 +3350,21 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3335
3350
|
if (A.length > 0)
|
|
3336
3351
|
return A.map((z, J) => g(z, J));
|
|
3337
3352
|
}
|
|
3338
|
-
return
|
|
3339
|
-
(A, z) => `${
|
|
3353
|
+
return fe.map(
|
|
3354
|
+
(A, z) => `${a("report.section.datasource.lineStyle.series")} ${z + 1}`
|
|
3340
3355
|
);
|
|
3341
3356
|
}
|
|
3342
|
-
const i =
|
|
3357
|
+
const i = F(() => [
|
|
3343
3358
|
{
|
|
3344
|
-
label:
|
|
3359
|
+
label: a("report.section.datasource.lineStyle.solid"),
|
|
3345
3360
|
value: "solid"
|
|
3346
3361
|
},
|
|
3347
3362
|
{
|
|
3348
|
-
label:
|
|
3363
|
+
label: a("report.section.datasource.lineStyle.dashed"),
|
|
3349
3364
|
value: "dashed"
|
|
3350
3365
|
},
|
|
3351
3366
|
{
|
|
3352
|
-
label:
|
|
3367
|
+
label: a("report.section.datasource.lineStyle.dotted"),
|
|
3353
3368
|
value: "dotted"
|
|
3354
3369
|
}
|
|
3355
3370
|
]);
|
|
@@ -3359,19 +3374,19 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3359
3374
|
function y(t) {
|
|
3360
3375
|
return t === "dashed" ? "line-style-icon--dashed" : t === "dotted" ? "line-style-icon--dotted" : "line-style-icon--solid";
|
|
3361
3376
|
}
|
|
3362
|
-
function
|
|
3377
|
+
function k(t, A) {
|
|
3363
3378
|
return !Array.isArray(t) || t.length === 0 ? Array.from({ length: A }).map(
|
|
3364
3379
|
(z, J) => yl[J] ?? "solid"
|
|
3365
3380
|
) : Array.from({ length: A }).map(
|
|
3366
3381
|
(z, J) => s(t[J])
|
|
3367
3382
|
);
|
|
3368
3383
|
}
|
|
3369
|
-
const U =
|
|
3370
|
-
() =>
|
|
3371
|
-
), p =
|
|
3372
|
-
() =>
|
|
3384
|
+
const U = F(
|
|
3385
|
+
() => C(e.model.lineStyleBinding)
|
|
3386
|
+
), p = F(() => M(O.value)), r = F(
|
|
3387
|
+
() => k(e.model.lineStyles, M(U.value).length)
|
|
3373
3388
|
), B = le([]), O = le(ne.series);
|
|
3374
|
-
|
|
3389
|
+
Ce(
|
|
3375
3390
|
[
|
|
3376
3391
|
() => e.model.lineStyles,
|
|
3377
3392
|
() => e.model.lineStyleBinding,
|
|
@@ -3380,31 +3395,31 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3380
3395
|
() => e.model.joinDatasources
|
|
3381
3396
|
],
|
|
3382
3397
|
([t, A]) => {
|
|
3383
|
-
O.value =
|
|
3398
|
+
O.value = C(A), B.value = k(
|
|
3384
3399
|
t,
|
|
3385
3400
|
M(O.value).length
|
|
3386
3401
|
);
|
|
3387
3402
|
},
|
|
3388
3403
|
{ immediate: !0, deep: !0 }
|
|
3389
3404
|
);
|
|
3390
|
-
const
|
|
3405
|
+
const w = F(() => O.value !== U.value || B.value.length !== r.value.length ? !0 : B.value.some((t, A) => t !== r.value[A]));
|
|
3391
3406
|
function u(t, A) {
|
|
3392
3407
|
const z = [...B.value];
|
|
3393
3408
|
z[t] = s(A), B.value = z;
|
|
3394
3409
|
}
|
|
3395
|
-
function
|
|
3396
|
-
const A =
|
|
3410
|
+
function j(t) {
|
|
3411
|
+
const A = C(t);
|
|
3397
3412
|
if (A === O.value)
|
|
3398
3413
|
return;
|
|
3399
3414
|
const z = M(A).length;
|
|
3400
|
-
O.value = A, B.value =
|
|
3415
|
+
O.value = A, B.value = k(B.value, z);
|
|
3401
3416
|
}
|
|
3402
3417
|
function Y() {
|
|
3403
3418
|
O.value = ne.series, B.value = [...yl];
|
|
3404
3419
|
}
|
|
3405
3420
|
function d() {
|
|
3406
3421
|
const t = O.value === ne.series, A = B.value.every((z) => z === "solid");
|
|
3407
|
-
|
|
3422
|
+
n("update:model", {
|
|
3408
3423
|
...e.model,
|
|
3409
3424
|
lineStyleBinding: t ? void 0 : O.value,
|
|
3410
3425
|
lineStyles: A ? void 0 : [...B.value]
|
|
@@ -3412,15 +3427,15 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3412
3427
|
}
|
|
3413
3428
|
return (t, A) => {
|
|
3414
3429
|
const z = L("FmButton"), J = L("FmSelect");
|
|
3415
|
-
return f(), E("div",
|
|
3430
|
+
return f(), E("div", No, [
|
|
3416
3431
|
h("div", Ro, [
|
|
3417
|
-
h("p", zo, G(l(
|
|
3432
|
+
h("p", zo, G(l(a)("report.section.datasource.lineStyle.title")), 1),
|
|
3418
3433
|
h("div", Io, [
|
|
3419
3434
|
c(z, {
|
|
3420
3435
|
variant: "tertiary",
|
|
3421
3436
|
"text-color": "text-fm-color-system-info-300",
|
|
3422
3437
|
size: "md",
|
|
3423
|
-
label: l(
|
|
3438
|
+
label: l(a)("report.section.datasource.lineStyle.reset"),
|
|
3424
3439
|
onClick: Y
|
|
3425
3440
|
}, null, 8, ["label"])
|
|
3426
3441
|
])
|
|
@@ -3428,20 +3443,20 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3428
3443
|
c(J, {
|
|
3429
3444
|
"model-value": O.value,
|
|
3430
3445
|
items: V.value,
|
|
3431
|
-
label: l(
|
|
3432
|
-
"onUpdate:modelValue":
|
|
3446
|
+
label: l(a)("report.section.datasource.styleTarget.title"),
|
|
3447
|
+
"onUpdate:modelValue": j
|
|
3433
3448
|
}, null, 8, ["model-value", "items", "label"]),
|
|
3434
3449
|
h("div", Po, [
|
|
3435
|
-
(f(!0), E(
|
|
3450
|
+
(f(!0), E(ue, null, Se(B.value, (ie, D) => (f(), E("div", {
|
|
3436
3451
|
key: D,
|
|
3437
3452
|
class: "flex items-center justify-between gap-8 rounded-md border border-fm-color-neutral-gray-100 px-8 py-6"
|
|
3438
3453
|
}, [
|
|
3439
3454
|
h("div", Eo, [
|
|
3440
3455
|
h("span", {
|
|
3441
|
-
class:
|
|
3456
|
+
class: Fe(["line-style-icon", y(ie)]),
|
|
3442
3457
|
"aria-hidden": "true"
|
|
3443
3458
|
}, null, 2),
|
|
3444
|
-
h("span", Wo, G(p.value[D] || `${l(
|
|
3459
|
+
h("span", Wo, G(p.value[D] || `${l(a)("report.section.datasource.lineStyle.line")} ${D + 1}`), 1)
|
|
3445
3460
|
]),
|
|
3446
3461
|
c(J, {
|
|
3447
3462
|
"model-value": ie,
|
|
@@ -3453,8 +3468,8 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3453
3468
|
]),
|
|
3454
3469
|
c(z, {
|
|
3455
3470
|
size: "md",
|
|
3456
|
-
label: l(
|
|
3457
|
-
disabled: !
|
|
3471
|
+
label: l(a)("report.common.apply"),
|
|
3472
|
+
disabled: !w.value,
|
|
3458
3473
|
onClick: d
|
|
3459
3474
|
}, null, 8, ["label", "disabled"])
|
|
3460
3475
|
]);
|
|
@@ -3463,9 +3478,9 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3463
3478
|
}), Ho = /* @__PURE__ */ $l(Xo, [["__scopeId", "data-v-f1c35513"]]), qo = { class: "flex flex-col gap-16" }, Go = {
|
|
3464
3479
|
key: 1,
|
|
3465
3480
|
class: "h-px w-full bg-fm-color-neutral-gray-100"
|
|
3466
|
-
}, Yo = { class: "flex flex-col gap-8" }, Jo = { class: "fm-typo-en-body-lg-600" }, Ko = { class: "flex flex-col gap-8" }, Qo = /* @__PURE__ */
|
|
3481
|
+
}, Yo = { class: "flex flex-col gap-8" }, Jo = { class: "fm-typo-en-body-lg-600" }, Ko = { class: "flex flex-col gap-8" }, Qo = /* @__PURE__ */ de({
|
|
3467
3482
|
__name: "StyleDatasource",
|
|
3468
|
-
props: /* @__PURE__ */
|
|
3483
|
+
props: /* @__PURE__ */ ve({
|
|
3469
3484
|
label: {
|
|
3470
3485
|
type: String,
|
|
3471
3486
|
default: "Label"
|
|
@@ -3492,10 +3507,10 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3492
3507
|
modelValue: { required: !0 },
|
|
3493
3508
|
modelModifiers: {}
|
|
3494
3509
|
}),
|
|
3495
|
-
emits: /* @__PURE__ */
|
|
3510
|
+
emits: /* @__PURE__ */ ve(["click-close"], ["update:modelValue"]),
|
|
3496
3511
|
setup($, { emit: v }) {
|
|
3497
3512
|
const e = ge($, "modelValue");
|
|
3498
|
-
|
|
3513
|
+
Ce(
|
|
3499
3514
|
[() => e.value.dimensions, () => e.value.metrics],
|
|
3500
3515
|
() => {
|
|
3501
3516
|
const { rowIds: s, columnIds: y } = Ye(e.value);
|
|
@@ -3503,11 +3518,11 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3503
3518
|
},
|
|
3504
3519
|
{ deep: !0 }
|
|
3505
3520
|
);
|
|
3506
|
-
const
|
|
3507
|
-
() =>
|
|
3508
|
-
), _ =
|
|
3509
|
-
() =>
|
|
3510
|
-
), M =
|
|
3521
|
+
const n = $, a = v, { t: V } = pe(), C = F(() => n.config.type === q.Circular), g = F(
|
|
3522
|
+
() => n.config.type === q.StackBarChart || n.config.type === q.ClusteredStackBarChart
|
|
3523
|
+
), _ = F(
|
|
3524
|
+
() => n.config.type === q.LineChart || n.config.type === q.StackLineChart
|
|
3525
|
+
), M = F({
|
|
3511
3526
|
get: () => e.value.maxTooltipItems ?? null,
|
|
3512
3527
|
set: (s) => {
|
|
3513
3528
|
e.value = {
|
|
@@ -3515,7 +3530,7 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3515
3530
|
maxTooltipItems: s ?? void 0
|
|
3516
3531
|
};
|
|
3517
3532
|
}
|
|
3518
|
-
}), i =
|
|
3533
|
+
}), i = F({
|
|
3519
3534
|
get: () => e.value.stackBarOverlap ?? !1,
|
|
3520
3535
|
set: (s) => {
|
|
3521
3536
|
e.value = {
|
|
@@ -3525,26 +3540,26 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3525
3540
|
}
|
|
3526
3541
|
});
|
|
3527
3542
|
return (s, y) => {
|
|
3528
|
-
const
|
|
3529
|
-
return f(), E(
|
|
3543
|
+
const k = L("FmButton"), U = L("FmCheckbox"), p = L("FmStepperField");
|
|
3544
|
+
return f(), E(ue, null, [
|
|
3530
3545
|
y[9] || (y[9] = h("div", { class: "grow" }, null, -1)),
|
|
3531
|
-
|
|
3546
|
+
n.closeable ? (f(), R(k, {
|
|
3532
3547
|
key: 0,
|
|
3533
3548
|
icon: "close",
|
|
3534
3549
|
variant: "tertiary",
|
|
3535
3550
|
size: "md",
|
|
3536
|
-
onClick: y[0] || (y[0] =
|
|
3551
|
+
onClick: y[0] || (y[0] = we((r) => a("click-close"), ["stop"]))
|
|
3537
3552
|
})) : I("", !0),
|
|
3538
3553
|
h("div", qo, [
|
|
3539
|
-
|
|
3554
|
+
n.config.hasChart ? (f(), R(jo, {
|
|
3540
3555
|
key: 0,
|
|
3541
3556
|
model: e.value,
|
|
3542
3557
|
"show-layer-control": g.value && i.value,
|
|
3543
|
-
"limit-to-series-mode":
|
|
3558
|
+
"limit-to-series-mode": C.value,
|
|
3544
3559
|
"onUpdate:model": y[1] || (y[1] = (r) => e.value = r)
|
|
3545
3560
|
}, null, 8, ["model", "show-layer-control", "limit-to-series-mode"])) : I("", !0),
|
|
3546
|
-
|
|
3547
|
-
|
|
3561
|
+
n.config.hasChart && _.value ? (f(), E("div", Go)) : I("", !0),
|
|
3562
|
+
n.config.hasChart && _.value ? (f(), R(Ho, {
|
|
3548
3563
|
key: 2,
|
|
3549
3564
|
model: e.value,
|
|
3550
3565
|
"onUpdate:model": y[2] || (y[2] = (r) => e.value = r)
|
|
@@ -3560,23 +3575,23 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3560
3575
|
class: "fm-typo-en-body-lg-400",
|
|
3561
3576
|
label: l(V)("report.section.datasource.stackBar.overlapBars")
|
|
3562
3577
|
}, null, 8, ["modelValue", "label"])) : I("", !0),
|
|
3563
|
-
|
|
3578
|
+
n.config.hasLabel ? (f(), R(lo, {
|
|
3564
3579
|
key: 1,
|
|
3565
3580
|
model: e.value,
|
|
3566
3581
|
"onUpdate:model": y[4] || (y[4] = (r) => e.value = r)
|
|
3567
3582
|
}, null, 8, ["model"])) : I("", !0),
|
|
3568
|
-
|
|
3583
|
+
n.config.hasLegend ? (f(), R(go, {
|
|
3569
3584
|
key: 2,
|
|
3570
3585
|
model: e.value,
|
|
3571
|
-
"is-circular-widget":
|
|
3586
|
+
"is-circular-widget": C.value,
|
|
3572
3587
|
"onUpdate:model": y[5] || (y[5] = (r) => e.value = r)
|
|
3573
3588
|
}, null, 8, ["model", "is-circular-widget"])) : I("", !0),
|
|
3574
|
-
|
|
3589
|
+
n.config.hasXy ? (f(), R(uo, {
|
|
3575
3590
|
key: 3,
|
|
3576
3591
|
model: e.value,
|
|
3577
3592
|
"onUpdate:model": y[6] || (y[6] = (r) => e.value = r)
|
|
3578
3593
|
}, null, 8, ["model"])) : I("", !0),
|
|
3579
|
-
|
|
3594
|
+
n.config.hasXy ? (f(), R(p, {
|
|
3580
3595
|
key: 4,
|
|
3581
3596
|
modelValue: M.value,
|
|
3582
3597
|
"onUpdate:modelValue": y[7] || (y[7] = (r) => M.value = r),
|
|
@@ -3598,7 +3613,7 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3598
3613
|
}, ua = { class: "fm-typo-en-body-sm-600 text-fm-color-neutral-gray-400" }, da = {
|
|
3599
3614
|
key: 1,
|
|
3600
3615
|
class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary"
|
|
3601
|
-
}, ma = /* @__PURE__ */
|
|
3616
|
+
}, ma = /* @__PURE__ */ de({
|
|
3602
3617
|
__name: "TableResizeSection",
|
|
3603
3618
|
props: {
|
|
3604
3619
|
layout: {},
|
|
@@ -3606,56 +3621,56 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3606
3621
|
},
|
|
3607
3622
|
emits: ["update:layout"],
|
|
3608
3623
|
setup($, { emit: v }) {
|
|
3609
|
-
const { t: e } =
|
|
3624
|
+
const { t: e } = pe(), n = $, a = v, V = F({
|
|
3610
3625
|
get: () => {
|
|
3611
3626
|
var y;
|
|
3612
|
-
return (y =
|
|
3627
|
+
return (y = n.layout) != null && y.rowHeight && n.layout.rowHeight >= 30 ? n.layout.rowHeight : null;
|
|
3613
3628
|
},
|
|
3614
3629
|
set: (y) => {
|
|
3615
|
-
var
|
|
3616
|
-
|
|
3617
|
-
...
|
|
3630
|
+
var k;
|
|
3631
|
+
a("update:layout", {
|
|
3632
|
+
...n.layout,
|
|
3618
3633
|
rowHeight: y && y >= 30 ? y : null,
|
|
3619
|
-
colWidths: g((
|
|
3634
|
+
colWidths: g((k = n.layout) == null ? void 0 : k.colWidths)
|
|
3620
3635
|
});
|
|
3621
3636
|
}
|
|
3622
|
-
}),
|
|
3637
|
+
}), C = F(() => {
|
|
3623
3638
|
var y;
|
|
3624
|
-
return ((y =
|
|
3639
|
+
return ((y = n.columns) == null ? void 0 : y.length) ?? 0;
|
|
3625
3640
|
});
|
|
3626
3641
|
function g(y) {
|
|
3627
3642
|
if (!y) return null;
|
|
3628
|
-
const
|
|
3643
|
+
const k = Object.entries(y).reduce(
|
|
3629
3644
|
(U, p) => {
|
|
3630
3645
|
const [r, B] = p;
|
|
3631
3646
|
return B && B >= 40 ? U[r] = B : U[r] = null, U;
|
|
3632
3647
|
},
|
|
3633
3648
|
{}
|
|
3634
3649
|
);
|
|
3635
|
-
return Object.values(
|
|
3650
|
+
return Object.values(k).some((U) => (U ?? 0) >= 40) ? k : null;
|
|
3636
3651
|
}
|
|
3637
3652
|
function _(y) {
|
|
3638
|
-
var
|
|
3639
|
-
return (
|
|
3653
|
+
var k;
|
|
3654
|
+
return (k = n.columns) == null ? void 0 : k[y];
|
|
3640
3655
|
}
|
|
3641
|
-
function M(y,
|
|
3642
|
-
const U =
|
|
3643
|
-
r != null && r.key && (p[r.key] = U),
|
|
3644
|
-
...
|
|
3656
|
+
function M(y, k) {
|
|
3657
|
+
const U = k && k >= 40 ? k : null, p = { ...n.layout.colWidths ?? {} }, r = _(y);
|
|
3658
|
+
r != null && r.key && (p[r.key] = U), a("update:layout", {
|
|
3659
|
+
...n.layout,
|
|
3645
3660
|
rowHeight: V.value ?? null,
|
|
3646
3661
|
colWidths: g(p)
|
|
3647
3662
|
});
|
|
3648
3663
|
}
|
|
3649
3664
|
function i(y) {
|
|
3650
3665
|
var p, r;
|
|
3651
|
-
const
|
|
3666
|
+
const k = _(y), U = k != null && k.key ? (r = (p = n.layout) == null ? void 0 : p.colWidths) == null ? void 0 : r[k.key] : void 0;
|
|
3652
3667
|
return U && U >= 40 ? U : null;
|
|
3653
3668
|
}
|
|
3654
3669
|
function s(y) {
|
|
3655
|
-
var
|
|
3656
|
-
return ((
|
|
3670
|
+
var k;
|
|
3671
|
+
return ((k = _(y)) == null ? void 0 : k.label) || "Column " + (y + 1);
|
|
3657
3672
|
}
|
|
3658
|
-
return (y,
|
|
3673
|
+
return (y, k) => {
|
|
3659
3674
|
const U = L("FmStepperField");
|
|
3660
3675
|
return f(), E("div", Zo, [
|
|
3661
3676
|
h("div", ea, [
|
|
@@ -3666,7 +3681,7 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3666
3681
|
h("p", aa, G(l(e)("report.section.datasource.rowHeightHelper")), 1),
|
|
3667
3682
|
c(U, {
|
|
3668
3683
|
modelValue: V.value,
|
|
3669
|
-
"onUpdate:modelValue":
|
|
3684
|
+
"onUpdate:modelValue": k[0] || (k[0] = (p) => V.value = p),
|
|
3670
3685
|
type: "number",
|
|
3671
3686
|
suffix: "px",
|
|
3672
3687
|
min: 30,
|
|
@@ -3678,9 +3693,9 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3678
3693
|
h("div", ia, [
|
|
3679
3694
|
h("p", sa, G(l(e)("report.section.datasource.columnWidth")), 1)
|
|
3680
3695
|
]),
|
|
3681
|
-
|
|
3696
|
+
C.value > 0 ? (f(), E("div", ra, [
|
|
3682
3697
|
h("p", ua, G(l(e)("report.section.datasource.columnWidthHelper")), 1),
|
|
3683
|
-
(f(!0), E(
|
|
3698
|
+
(f(!0), E(ue, null, Se(C.value, (p) => (f(), R(U, {
|
|
3684
3699
|
key: s(p - 1),
|
|
3685
3700
|
type: "number",
|
|
3686
3701
|
"model-value": i(p - 1),
|
|
@@ -3701,9 +3716,9 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3701
3716
|
}, pa = {
|
|
3702
3717
|
key: 1,
|
|
3703
3718
|
class: "px-6 py-16 flex flex-col overflow-y-auto overflow-x-hidden"
|
|
3704
|
-
}, va = { class: "text-center" }, fa = /* @__PURE__ */
|
|
3719
|
+
}, va = { class: "text-center" }, fa = /* @__PURE__ */ de({
|
|
3705
3720
|
__name: "StyleEditorTab",
|
|
3706
|
-
props: /* @__PURE__ */
|
|
3721
|
+
props: /* @__PURE__ */ ve({
|
|
3707
3722
|
tableResponse: {}
|
|
3708
3723
|
}, {
|
|
3709
3724
|
modelValue: {
|
|
@@ -3715,56 +3730,56 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3715
3730
|
}),
|
|
3716
3731
|
emits: ["update:modelValue", "update:isEditingStyle"],
|
|
3717
3732
|
setup($) {
|
|
3718
|
-
const { t: v, locale: e } =
|
|
3719
|
-
() => Qe.find((
|
|
3720
|
-
), V = ge($, "isEditingStyle"),
|
|
3733
|
+
const { t: v, locale: e } = pe(), n = ge($, "modelValue"), a = F(
|
|
3734
|
+
() => Qe.find((w) => w.type === n.value.widget.type)
|
|
3735
|
+
), V = ge($, "isEditingStyle"), C = le(!1), { markStyleEditing: g, resetStyleEditing: _ } = Dl(V), M = $, i = [
|
|
3721
3736
|
q.BarChart,
|
|
3722
3737
|
q.StackBarChart,
|
|
3723
3738
|
q.ClusteredStackBarChart,
|
|
3724
3739
|
q.LineChart,
|
|
3725
3740
|
q.StackLineChart,
|
|
3726
3741
|
q.Circular
|
|
3727
|
-
], s =
|
|
3742
|
+
], s = F(() => i.includes(n.value.widget.type)), y = F(() => n.value.widget.type === q.Table), k = F(() => e.value.toLowerCase().startsWith("en")), U = F({
|
|
3728
3743
|
get: () => ({
|
|
3729
|
-
rowHeight:
|
|
3730
|
-
colWidths:
|
|
3744
|
+
rowHeight: n.value.widget.config.rowHeight,
|
|
3745
|
+
colWidths: n.value.widget.config.colWidths
|
|
3731
3746
|
}),
|
|
3732
|
-
set: (
|
|
3733
|
-
g(),
|
|
3747
|
+
set: (w) => {
|
|
3748
|
+
g(), n.value.widget.config.rowHeight = w.rowHeight, n.value.widget.config.colWidths = w.colWidths;
|
|
3734
3749
|
}
|
|
3735
|
-
}), p =
|
|
3736
|
-
get: () =>
|
|
3737
|
-
set: (
|
|
3738
|
-
g(),
|
|
3750
|
+
}), p = F({
|
|
3751
|
+
get: () => n.value.widget.config,
|
|
3752
|
+
set: (w) => {
|
|
3753
|
+
g(), n.value.widget.config = w;
|
|
3739
3754
|
}
|
|
3740
|
-
}), r =
|
|
3741
|
-
var
|
|
3742
|
-
return y.value ? ((u = (
|
|
3743
|
-
key:
|
|
3744
|
-
label:
|
|
3755
|
+
}), r = F(() => {
|
|
3756
|
+
var w, u;
|
|
3757
|
+
return y.value ? ((u = (w = M.tableResponse) == null ? void 0 : w.columns) == null ? void 0 : u.map((j) => ({
|
|
3758
|
+
key: j.key,
|
|
3759
|
+
label: j.label
|
|
3745
3760
|
}))) ?? [] : [];
|
|
3746
3761
|
});
|
|
3747
3762
|
function B() {
|
|
3748
|
-
|
|
3763
|
+
C.value = !0;
|
|
3749
3764
|
}
|
|
3750
3765
|
function O() {
|
|
3751
|
-
|
|
3766
|
+
C.value = !1, _();
|
|
3752
3767
|
}
|
|
3753
|
-
return (
|
|
3754
|
-
const
|
|
3755
|
-
return
|
|
3768
|
+
return (w, u) => {
|
|
3769
|
+
const j = L("FmCircularProgress"), Y = L("FmButton");
|
|
3770
|
+
return C.value ? (f(), E("div", ca, [
|
|
3756
3771
|
c(Je, {
|
|
3757
|
-
"model-value":
|
|
3772
|
+
"model-value": C.value,
|
|
3758
3773
|
icon: "keyboard_double_arrow_right",
|
|
3759
3774
|
title: l(v)("report.section.style.title"),
|
|
3760
3775
|
"onUpdate:modelValue": u[0] || (u[0] = (d) => d ? B() : O())
|
|
3761
3776
|
}, null, 8, ["model-value", "title"]),
|
|
3762
|
-
|
|
3777
|
+
n.value ? (f(), E("div", pa, [
|
|
3763
3778
|
s.value ? (f(), R(Qo, {
|
|
3764
3779
|
key: 0,
|
|
3765
3780
|
modelValue: p.value,
|
|
3766
3781
|
"onUpdate:modelValue": u[1] || (u[1] = (d) => p.value = d),
|
|
3767
|
-
config:
|
|
3782
|
+
config: a.value
|
|
3768
3783
|
}, null, 8, ["modelValue", "config"])) : I("", !0),
|
|
3769
3784
|
y.value ? (f(), R(ma, {
|
|
3770
3785
|
key: 1,
|
|
@@ -3772,15 +3787,15 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3772
3787
|
"onUpdate:layout": u[2] || (u[2] = (d) => U.value = d),
|
|
3773
3788
|
columns: r.value
|
|
3774
3789
|
}, null, 8, ["layout", "columns"])) : I("", !0)
|
|
3775
|
-
])) : (f(), R(
|
|
3790
|
+
])) : (f(), R(j, { key: 0 }))
|
|
3776
3791
|
])) : (f(), E("div", {
|
|
3777
3792
|
key: 1,
|
|
3778
|
-
class:
|
|
3793
|
+
class: Fe([
|
|
3779
3794
|
"bg-fm-color-neutral-white pt-16",
|
|
3780
|
-
|
|
3795
|
+
k.value ? "flex h-full w-[156px] flex-col items-center justify-start gap-12 px-12" : "flex h-full w-[88px] flex-col items-center justify-start gap-16"
|
|
3781
3796
|
])
|
|
3782
3797
|
}, [
|
|
3783
|
-
|
|
3798
|
+
k.value ? (f(), E("button", {
|
|
3784
3799
|
key: 0,
|
|
3785
3800
|
class: "flex flex-col items-center gap-16 fm-typo-en-title-sm-600 text-fm-color-typo-primary",
|
|
3786
3801
|
type: "button",
|
|
@@ -3794,7 +3809,7 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3794
3809
|
size: "md"
|
|
3795
3810
|
}, null, 8, ["border-color", "text-color"]),
|
|
3796
3811
|
h("span", va, G(l(v)("report.section.style.title")), 1)
|
|
3797
|
-
])) : (f(), E(
|
|
3812
|
+
])) : (f(), E(ue, { key: 1 }, [
|
|
3798
3813
|
c(Y, {
|
|
3799
3814
|
variant: "secondary",
|
|
3800
3815
|
icon: "keyboard_double_arrow_left",
|
|
@@ -3815,9 +3830,9 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3815
3830
|
}), ga = { class: "bg-fm-color-neutral-white flex flex-col h-full w-[510px]" }, ya = { class: "text-center" }, ba = { class: "w-full overflow-y-auto" }, ha = {
|
|
3816
3831
|
class: "grid grid-cols-12 w-full p-24",
|
|
3817
3832
|
style: { backgroundColor: "#F6F8FC" }
|
|
3818
|
-
},
|
|
3833
|
+
}, wa = /* @__PURE__ */ de({
|
|
3819
3834
|
__name: "TileEditorDesktop",
|
|
3820
|
-
props: /* @__PURE__ */
|
|
3835
|
+
props: /* @__PURE__ */ ve({
|
|
3821
3836
|
hideConfiguration: { type: Boolean, required: !0, default: !1 },
|
|
3822
3837
|
index: { type: Number, required: !0, default: 0 }
|
|
3823
3838
|
}, {
|
|
@@ -3826,12 +3841,12 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3826
3841
|
},
|
|
3827
3842
|
modelModifiers: {}
|
|
3828
3843
|
}),
|
|
3829
|
-
emits: /* @__PURE__ */
|
|
3844
|
+
emits: /* @__PURE__ */ ve(["hideConfiguration"], ["update:modelValue"]),
|
|
3830
3845
|
setup($, { emit: v }) {
|
|
3831
|
-
const { locale: e, t:
|
|
3846
|
+
const { locale: e, t: n } = pe(), a = ge($, "modelValue"), V = $, C = F(
|
|
3832
3847
|
() => Qe.find((U) => {
|
|
3833
3848
|
var p, r;
|
|
3834
|
-
return U.type === ((r = (p =
|
|
3849
|
+
return U.type === ((r = (p = a.value) == null ? void 0 : p.widget) == null ? void 0 : r.type);
|
|
3835
3850
|
})
|
|
3836
3851
|
), g = v, M = [...[
|
|
3837
3852
|
q.BarChart,
|
|
@@ -3840,22 +3855,22 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3840
3855
|
q.LineChart,
|
|
3841
3856
|
q.StackLineChart,
|
|
3842
3857
|
q.Circular
|
|
3843
|
-
], q.Table], i =
|
|
3858
|
+
], q.Table], i = F(() => M.includes(a.value.widget.type)), s = le(!1), y = le(null), k = F(() => e.value.toLowerCase().startsWith("en"));
|
|
3844
3859
|
return (U, p) => {
|
|
3845
3860
|
const r = L("FmCircularProgress"), B = L("FmButton");
|
|
3846
3861
|
return f(), E("div", null, [
|
|
3847
|
-
|
|
3862
|
+
a.value ? (f(), E(ue, { key: 1 }, [
|
|
3848
3863
|
c(Hl, {
|
|
3849
3864
|
"model-value": !$.hideConfiguration
|
|
3850
3865
|
}, {
|
|
3851
3866
|
right: K(() => [
|
|
3852
3867
|
h("div", ga, [
|
|
3853
3868
|
c(Ul, {
|
|
3854
|
-
modelValue:
|
|
3855
|
-
"onUpdate:modelValue": p[0] || (p[0] = (O) =>
|
|
3869
|
+
modelValue: a.value,
|
|
3870
|
+
"onUpdate:modelValue": p[0] || (p[0] = (O) => a.value = O),
|
|
3856
3871
|
"is-editing-style": s.value,
|
|
3857
3872
|
"onUpdate:isEditingStyle": p[1] || (p[1] = (O) => s.value = O),
|
|
3858
|
-
config:
|
|
3873
|
+
config: C.value,
|
|
3859
3874
|
"hide-configuration": $.hideConfiguration,
|
|
3860
3875
|
onHideConfiguration: p[2] || (p[2] = (O) => {
|
|
3861
3876
|
g("hideConfiguration", O);
|
|
@@ -3865,12 +3880,12 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3865
3880
|
]),
|
|
3866
3881
|
left: K(() => [
|
|
3867
3882
|
h("div", {
|
|
3868
|
-
class:
|
|
3883
|
+
class: Fe([
|
|
3869
3884
|
"bg-fm-color-neutral-white pt-16",
|
|
3870
|
-
|
|
3885
|
+
k.value ? "flex h-full w-[156px] flex-col items-center justify-start gap-12 px-12" : "flex h-full w-[88px] flex-col items-center justify-start gap-16"
|
|
3871
3886
|
])
|
|
3872
3887
|
}, [
|
|
3873
|
-
|
|
3888
|
+
k.value ? (f(), E("button", {
|
|
3874
3889
|
key: 0,
|
|
3875
3890
|
class: "flex flex-col items-center gap-16 fm-typo-en-title-sm-600 text-fm-color-typo-primary",
|
|
3876
3891
|
type: "button",
|
|
@@ -3883,8 +3898,8 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3883
3898
|
"text-color": l(Ue).ColorPrimary,
|
|
3884
3899
|
size: "md"
|
|
3885
3900
|
}, null, 8, ["border-color", "text-color"]),
|
|
3886
|
-
h("span", ya, G(l(
|
|
3887
|
-
])) : (f(), E(
|
|
3901
|
+
h("span", ya, G(l(n)("report.tile.setupSetting")), 1)
|
|
3902
|
+
])) : (f(), E(ue, { key: 1 }, [
|
|
3888
3903
|
c(B, {
|
|
3889
3904
|
variant: "secondary",
|
|
3890
3905
|
icon: "keyboard_double_arrow_right",
|
|
@@ -3897,7 +3912,7 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3897
3912
|
class: "fm-typo-en-title-sm-600 text-fm-color-typo-primary [text-orientation:mixed] [writing-mode:vertical-rl]",
|
|
3898
3913
|
type: "button",
|
|
3899
3914
|
onClick: p[5] || (p[5] = (O) => g("hideConfiguration", !V.hideConfiguration))
|
|
3900
|
-
}, G(l(
|
|
3915
|
+
}, G(l(n)("report.tile.setupSetting")), 1)
|
|
3901
3916
|
], 64))
|
|
3902
3917
|
], 2)
|
|
3903
3918
|
]),
|
|
@@ -3905,9 +3920,9 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3905
3920
|
}, 8, ["model-value"]),
|
|
3906
3921
|
h("div", ba, [
|
|
3907
3922
|
h("div", ha, [
|
|
3908
|
-
|
|
3923
|
+
a.value ? (f(), R(_l, {
|
|
3909
3924
|
key: 0,
|
|
3910
|
-
"model-value":
|
|
3925
|
+
"model-value": a.value,
|
|
3911
3926
|
index: V.index,
|
|
3912
3927
|
"is-tile-editor": !0,
|
|
3913
3928
|
"hide-export": !0,
|
|
@@ -3918,8 +3933,8 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3918
3933
|
]),
|
|
3919
3934
|
i.value ? (f(), R(fa, {
|
|
3920
3935
|
key: 0,
|
|
3921
|
-
modelValue:
|
|
3922
|
-
"onUpdate:modelValue": p[7] || (p[7] = (O) =>
|
|
3936
|
+
modelValue: a.value,
|
|
3937
|
+
"onUpdate:modelValue": p[7] || (p[7] = (O) => a.value = O),
|
|
3923
3938
|
"is-editing-style": s.value,
|
|
3924
3939
|
"onUpdate:isEditingStyle": p[8] || (p[8] = (O) => s.value = O),
|
|
3925
3940
|
"table-response": y.value
|
|
@@ -3928,12 +3943,12 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3928
3943
|
]);
|
|
3929
3944
|
};
|
|
3930
3945
|
}
|
|
3931
|
-
}),
|
|
3946
|
+
}), Ca = {
|
|
3932
3947
|
key: 0,
|
|
3933
3948
|
class: "flex w-full justify-center items-center"
|
|
3934
|
-
}, xa = { class: "w-full grid grid-cols-12 pb-28 pt-5 px-5 h-full" },
|
|
3949
|
+
}, xa = { class: "w-full grid grid-cols-12 pb-28 pt-5 px-5 h-full" }, ka = /* @__PURE__ */ de({
|
|
3935
3950
|
__name: "TileEditorMobile",
|
|
3936
|
-
props: /* @__PURE__ */
|
|
3951
|
+
props: /* @__PURE__ */ ve({
|
|
3937
3952
|
hideConfiguration: { type: Boolean, required: !0, default: !1 },
|
|
3938
3953
|
index: { type: Number, required: !0, default: 0 }
|
|
3939
3954
|
}, {
|
|
@@ -3942,23 +3957,23 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3942
3957
|
},
|
|
3943
3958
|
modelModifiers: {}
|
|
3944
3959
|
}),
|
|
3945
|
-
emits: /* @__PURE__ */
|
|
3960
|
+
emits: /* @__PURE__ */ ve(["hideConfiguration"], ["update:modelValue"]),
|
|
3946
3961
|
setup($, { emit: v }) {
|
|
3947
|
-
const e = ge($, "modelValue"),
|
|
3948
|
-
() => Qe.find((
|
|
3962
|
+
const e = ge($, "modelValue"), n = $, a = F(
|
|
3963
|
+
() => Qe.find((C) => {
|
|
3949
3964
|
var g, _;
|
|
3950
|
-
return
|
|
3965
|
+
return C.type === ((_ = (g = e.value) == null ? void 0 : g.widget) == null ? void 0 : _.type);
|
|
3951
3966
|
})
|
|
3952
3967
|
), V = v;
|
|
3953
|
-
return (
|
|
3968
|
+
return (C, g) => {
|
|
3954
3969
|
const _ = L("FmCircularProgress");
|
|
3955
3970
|
return f(), E("div", null, [
|
|
3956
|
-
e.value ? (f(), E(
|
|
3971
|
+
e.value ? (f(), E(ue, { key: 1 }, [
|
|
3957
3972
|
h("div", xa, [
|
|
3958
3973
|
e.value ? (f(), R(_l, {
|
|
3959
3974
|
key: 0,
|
|
3960
3975
|
"model-value": e.value,
|
|
3961
|
-
index:
|
|
3976
|
+
index: n.index,
|
|
3962
3977
|
"is-tile-editor": !0,
|
|
3963
3978
|
"hide-export": !0
|
|
3964
3979
|
}, null, 8, ["model-value", "index"])) : (f(), R(Tl, { key: 1 }))
|
|
@@ -3966,60 +3981,60 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
3966
3981
|
c(Ul, {
|
|
3967
3982
|
modelValue: e.value,
|
|
3968
3983
|
"onUpdate:modelValue": g[0] || (g[0] = (M) => e.value = M),
|
|
3969
|
-
config:
|
|
3984
|
+
config: a.value,
|
|
3970
3985
|
"hide-configuration": $.hideConfiguration,
|
|
3971
3986
|
onHideConfiguration: g[1] || (g[1] = (M) => {
|
|
3972
3987
|
V("hideConfiguration", M);
|
|
3973
3988
|
})
|
|
3974
3989
|
}, null, 8, ["modelValue", "config", "hide-configuration"])
|
|
3975
|
-
], 64)) : (f(), E("div",
|
|
3990
|
+
], 64)) : (f(), E("div", Ca, [
|
|
3976
3991
|
c(_)
|
|
3977
3992
|
]))
|
|
3978
3993
|
]);
|
|
3979
3994
|
};
|
|
3980
3995
|
}
|
|
3981
|
-
}),
|
|
3996
|
+
}), Fa = {
|
|
3982
3997
|
key: 0,
|
|
3983
3998
|
class: "fm-typo-en-title-md-600"
|
|
3984
3999
|
}, Va = {
|
|
3985
4000
|
key: 0,
|
|
3986
4001
|
class: "flex items-start justify-start px-24 py-12 flex-wrap w-full"
|
|
3987
|
-
}, Ra = /* @__PURE__ */
|
|
4002
|
+
}, Ra = /* @__PURE__ */ de({
|
|
3988
4003
|
__name: "TileEditor",
|
|
3989
4004
|
setup($) {
|
|
3990
|
-
const v = Pl(), e = El(),
|
|
3991
|
-
var u,
|
|
3992
|
-
const O = (
|
|
4005
|
+
const v = Pl(), e = El(), n = Fl(), { globalFilters: a } = Ne(Jl()), { currentSelectWidgetType: V, editingReport: C, editingTile: g, editingTileIndex: _ } = Ne(n), { breakpoints: M } = Sl(), { promptMessage: i } = Vl(), { t: s, te: y } = pe(), k = F(() => {
|
|
4006
|
+
var u, j;
|
|
4007
|
+
const O = (j = (u = g.value) == null ? void 0 : u.widget) == null ? void 0 : j.type;
|
|
3993
4008
|
if (!O)
|
|
3994
4009
|
return s("report.editor.newReport");
|
|
3995
|
-
const
|
|
3996
|
-
return y(
|
|
4010
|
+
const w = `report.widget.types.${O.toLowerCase()}`;
|
|
4011
|
+
return y(w) ? s(w) : O;
|
|
3997
4012
|
}), U = le(!1);
|
|
3998
4013
|
function p() {
|
|
3999
4014
|
V.value = void 0, g.value = void 0, _.value = -1, pl.value = null, e.back();
|
|
4000
4015
|
}
|
|
4001
4016
|
async function r() {
|
|
4002
|
-
var
|
|
4003
|
-
if (!
|
|
4017
|
+
var w, u;
|
|
4018
|
+
if (!C.value) return;
|
|
4004
4019
|
if (await i({
|
|
4005
4020
|
title: s("report.tile.save.title"),
|
|
4006
|
-
message: s("report.tile.save.confirm", { title: ((u = (
|
|
4021
|
+
message: s("report.tile.save.confirm", { title: ((u = (w = g.value) == null ? void 0 : w.widget) == null ? void 0 : u.title) ?? "" })
|
|
4007
4022
|
}) && g.value) {
|
|
4008
|
-
const
|
|
4009
|
-
_.value === -1 ?
|
|
4023
|
+
const j = Ql(C.value.tiles, pl.value);
|
|
4024
|
+
_.value === -1 ? j.push(g.value) : j[_.value] = g.value, p();
|
|
4010
4025
|
}
|
|
4011
4026
|
}
|
|
4012
4027
|
async function B() {
|
|
4013
|
-
var
|
|
4014
|
-
if (!
|
|
4028
|
+
var w, u;
|
|
4029
|
+
if (!C.value) return;
|
|
4015
4030
|
await i({
|
|
4016
4031
|
title: s("report.tile.cancel.title"),
|
|
4017
|
-
message: s("report.tile.cancel.confirm", { title: ((u = (
|
|
4032
|
+
message: s("report.tile.cancel.confirm", { title: ((u = (w = g.value) == null ? void 0 : w.widget) == null ? void 0 : u.title) ?? "" })
|
|
4018
4033
|
}) && p();
|
|
4019
4034
|
}
|
|
4020
4035
|
return xl(() => {
|
|
4021
|
-
|
|
4022
|
-
}), (O,
|
|
4036
|
+
C.value || e.push({ name: "reports" });
|
|
4037
|
+
}), (O, w) => {
|
|
4023
4038
|
const u = L("FmPageHead");
|
|
4024
4039
|
return f(), R(ql, null, {
|
|
4025
4040
|
default: K(() => [
|
|
@@ -4028,30 +4043,30 @@ const Ot = { class: "flex flex-col gap-5" }, Nt = { class: "fm-typo-en-body-lg-6
|
|
|
4028
4043
|
{ label: l(s)("report.common.cancel"), value: "cancel", isPrimary: !1 },
|
|
4029
4044
|
{ label: l(s)("report.common.save"), value: "save", isPrimary: !0 }
|
|
4030
4045
|
],
|
|
4031
|
-
"onClick:action":
|
|
4032
|
-
|
|
4046
|
+
"onClick:action": w[0] || (w[0] = (j) => {
|
|
4047
|
+
j === "cancel" && B(), j === "save" && r();
|
|
4033
4048
|
})
|
|
4034
4049
|
}, {
|
|
4035
4050
|
title: K(() => [
|
|
4036
|
-
l(M).lg || l(M).md ? (f(), E("p",
|
|
4051
|
+
l(M).lg || l(M).md ? (f(), E("p", Fa, G(k.value), 1)) : I("", !0)
|
|
4037
4052
|
]),
|
|
4038
4053
|
_: 1
|
|
4039
4054
|
}, 8, ["actions"]),
|
|
4040
|
-
l(g) && (l(
|
|
4041
|
-
const Y =
|
|
4055
|
+
l(g) && (l(a) || []).some((j) => {
|
|
4056
|
+
const Y = j.tileIds, d = l(g) && l(g).id;
|
|
4042
4057
|
return Array.isArray(Y) && typeof d == "string" && Y.includes(d);
|
|
4043
4058
|
}) ? (f(), E("div", Va, [
|
|
4044
4059
|
c(Kl)
|
|
4045
4060
|
])) : I("", !0),
|
|
4046
|
-
l(g) ? (f(), R(
|
|
4061
|
+
l(g) ? (f(), R(Cl(l(M).lg || l(M).md ? wa : ka), {
|
|
4047
4062
|
key: 1,
|
|
4048
4063
|
modelValue: l(g),
|
|
4049
|
-
"onUpdate:modelValue":
|
|
4050
|
-
class:
|
|
4064
|
+
"onUpdate:modelValue": w[1] || (w[1] = (j) => Il(g) ? g.value = j : null),
|
|
4065
|
+
class: Fe(`${l(M).lg || l(M).md ? "flex" : ""} w-full`),
|
|
4051
4066
|
style: ol({ height: `calc( 100% - ${l(M).lg || l(M).md ? 72 : 64}px)` }),
|
|
4052
4067
|
"hide-configuration": U.value,
|
|
4053
4068
|
index: Number(l(v).params.tileIndex),
|
|
4054
|
-
onHideConfiguration:
|
|
4069
|
+
onHideConfiguration: w[2] || (w[2] = (j) => U.value = j)
|
|
4055
4070
|
}, null, 40, ["modelValue", "class", "style", "hide-configuration", "index"])) : I("", !0)
|
|
4056
4071
|
]),
|
|
4057
4072
|
_: 1
|