@feedmepos/mf-report 5.22.5 → 5.22.6
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-DqzpHAiQ.js → App-BK6lTdxs.js} +5 -5
- package/dist/{BaseDialog.vue_vue_type_script_setup_true_lang-CAhR1y29.js → BaseDialog.vue_vue_type_script_setup_true_lang-CC1P9RLf.js} +3 -5
- package/dist/{DateRangeSelect.vue_vue_type_script_setup_true_lang-ZHteCUaN.js → DateRangeSelect.vue_vue_type_script_setup_true_lang-BBedOQ43.js} +2 -2
- package/dist/{Default.vue_vue_type_script_setup_true_lang-BBgTqWTo.js → Default.vue_vue_type_script_setup_true_lang-CJt0-cSK.js} +2 -2
- package/dist/FilterSelector.vue_vue_type_script_setup_true_lang-isj584yX.js +5398 -0
- package/dist/{InsightView-E0rGZz7N.js → InsightView--p8zCrAh.js} +6 -6
- package/dist/{Integration-B5m6Dh2k.js → Integration-BFT-uzH0.js} +3 -3
- package/dist/{Integrations-DHiZuGhv.js → Integrations-BLazSIlW.js} +3 -3
- package/dist/{Layout-DD7d2-r3.js → Layout-Uj38xhOC.js} +1 -1
- package/dist/{MenuTab.vue_vue_type_script_setup_true_lang-Cttz3iWc.js → MenuTab.vue_vue_type_script_setup_true_lang-C1HbXgtd.js} +5 -5
- package/dist/{NavigationTab.vue_vue_type_script_setup_true_lang-3q8huUMP.js → NavigationTab.vue_vue_type_script_setup_true_lang-HBFqB2Et.js} +5 -5
- package/dist/{NoData.vue_vue_type_script_setup_true_lang-Szs2H-rQ.js → NoData.vue_vue_type_script_setup_true_lang-Cku36gXg.js} +1 -1
- package/dist/{OverviewView-CZUa8VyF.js → OverviewView-CQkKWb9-.js} +5 -5
- package/dist/{Report-CUGrtZzb.js → Report-CTeO6fUU.js} +4 -4
- package/dist/{ReportEditor-3QxjUH5Z.js → ReportEditor-C1AFC8FP.js} +6 -6
- package/dist/{ReportView-1W7-LhBd.js → ReportView-s7XsPNzL.js} +8 -8
- package/dist/{SelectComponent.vue_vue_type_script_setup_true_lang-bF-kKXY_.js → SelectComponent.vue_vue_type_script_setup_true_lang-BqiOAJNd.js} +1 -1
- package/dist/{Setting-DThrSMOl.js → Setting-w7WTROp6.js} +5 -5
- package/dist/{TileEditor-BssHPCKT.js → TileEditor-Dsc2SU89.js} +1477 -1440
- package/dist/{TransitionFade-ILPlWnhN.js → TransitionFade-DmXeUxOB.js} +6 -6
- package/dist/{app-ucvGix4c.js → app-P57-jpNL.js} +64 -52
- package/dist/app.js +1 -1
- package/dist/style.css +1 -1
- package/dist/{vue-i18n-DUy7xb0y.js → vue-i18n-D4RR492v.js} +1 -1
- package/package.json +1 -1
- package/dist/FilterSelector.vue_vue_type_script_setup_true_lang-D7wmsJqO.js +0 -4318
|
@@ -1,20 +1,20 @@
|
|
|
1
|
-
import { defineComponent as ae, mergeModels as
|
|
2
|
-
import { useRoute as
|
|
3
|
-
import { h as
|
|
4
|
-
import { W as
|
|
1
|
+
import { defineComponent as ae, mergeModels as ue, useModel as ce, computed as S, ref as ee, resolveComponent as $, createElementBlock as A, openBlock as g, createVNode as r, createElementVNode as h, unref as l, withCtx as R, toDisplayString as P, Fragment as re, renderList as we, withModifiers as ge, createTextVNode as Se, watch as ye, createCommentVNode as O, createBlock as N, onUnmounted as pl, renderSlot as el, onMounted as We, onBeforeUnmount as fl, resolveDynamicComponent as ll, normalizeClass as _e, withDirectives as be, vShow as he, withKeys as Ye, vModelText as vl, normalizeStyle as Re, isRef as gl } from "vue";
|
|
2
|
+
import { useRoute as bl, useRouter as yl } from "vue-router";
|
|
3
|
+
import { h as hl, d as ze, S as Pe, _ as wl, W as Cl, b as Vl, T as xl, a as Fl } from "./TransitionFade-DmXeUxOB.js";
|
|
4
|
+
import { W as I, b as ol, d as Te, D as kl, S as He, C as _l, P as Je, a as Sl } from "./BaseDialog.vue_vue_type_script_setup_true_lang-CC1P9RLf.js";
|
|
5
5
|
import { storeToRefs as Ve } from "pinia";
|
|
6
6
|
import { u as tl } from "./message-dialog-UoMWOnil.js";
|
|
7
|
-
import { useSnackbar as
|
|
8
|
-
import { a as
|
|
9
|
-
import { u as
|
|
10
|
-
import { r as
|
|
11
|
-
import { g as
|
|
12
|
-
import { d as
|
|
13
|
-
import { d as
|
|
14
|
-
import { _ as rl } from "./NoData.vue_vue_type_script_setup_true_lang-
|
|
15
|
-
const
|
|
7
|
+
import { useSnackbar as Tl, useBreakpoints as al, FmButtonColorThemeVariant as Ge } from "@feedmepos/ui-library";
|
|
8
|
+
import { a as me, _ as nl } from "./SelectComponent.vue_vue_type_script_setup_true_lang-BqiOAJNd.js";
|
|
9
|
+
import { u as se, i as ke, b as il } from "./vue-i18n-D4RR492v.js";
|
|
10
|
+
import { r as ie } from "./i18n-CI_sQ5d_.js";
|
|
11
|
+
import { g as xe, u as Ne, L as Ce, b as Me, S as oe, d as fe, c as Ke, e as $l, Y as Dl, X as Bl, _ as sl, a as Ul } from "./FilterSelector.vue_vue_type_script_setup_true_lang-isj584yX.js";
|
|
12
|
+
import { d as Oe } from "./DateRangeSelect.vue_vue_type_script_setup_true_lang-BBedOQ43.js";
|
|
13
|
+
import { d as Le } from "./app-P57-jpNL.js";
|
|
14
|
+
import { _ as rl } from "./NoData.vue_vue_type_script_setup_true_lang-Cku36gXg.js";
|
|
15
|
+
const Ie = [
|
|
16
16
|
{
|
|
17
|
-
type:
|
|
17
|
+
type: I.Circular,
|
|
18
18
|
maxDimension: null,
|
|
19
19
|
maxMetric: 1,
|
|
20
20
|
hasBreakdownDimension: !1,
|
|
@@ -31,7 +31,7 @@ const je = [
|
|
|
31
31
|
periodType: null
|
|
32
32
|
},
|
|
33
33
|
{
|
|
34
|
-
type:
|
|
34
|
+
type: I.Table,
|
|
35
35
|
maxDimension: null,
|
|
36
36
|
maxMetric: null,
|
|
37
37
|
hasBreakdownDimension: !1,
|
|
@@ -48,7 +48,7 @@ const je = [
|
|
|
48
48
|
periodType: null
|
|
49
49
|
},
|
|
50
50
|
{
|
|
51
|
-
type:
|
|
51
|
+
type: I.BarChart,
|
|
52
52
|
maxDimension: null,
|
|
53
53
|
maxMetric: 1,
|
|
54
54
|
hasBreakdownDimension: !0,
|
|
@@ -65,7 +65,7 @@ const je = [
|
|
|
65
65
|
periodType: null
|
|
66
66
|
},
|
|
67
67
|
{
|
|
68
|
-
type:
|
|
68
|
+
type: I.LineChart,
|
|
69
69
|
maxDimension: null,
|
|
70
70
|
maxMetric: 1,
|
|
71
71
|
hasBreakdownDimension: !0,
|
|
@@ -82,7 +82,7 @@ const je = [
|
|
|
82
82
|
periodType: null
|
|
83
83
|
},
|
|
84
84
|
{
|
|
85
|
-
type:
|
|
85
|
+
type: I.StackBarChart,
|
|
86
86
|
maxDimension: null,
|
|
87
87
|
maxMetric: 1,
|
|
88
88
|
hasBreakdownDimension: !0,
|
|
@@ -99,7 +99,7 @@ const je = [
|
|
|
99
99
|
periodType: null
|
|
100
100
|
},
|
|
101
101
|
{
|
|
102
|
-
type:
|
|
102
|
+
type: I.ClusteredStackBarChart,
|
|
103
103
|
maxDimension: null,
|
|
104
104
|
maxMetric: 1,
|
|
105
105
|
hasBreakdownDimension: !0,
|
|
@@ -116,7 +116,7 @@ const je = [
|
|
|
116
116
|
periodType: null
|
|
117
117
|
},
|
|
118
118
|
{
|
|
119
|
-
type:
|
|
119
|
+
type: I.StackLineChart,
|
|
120
120
|
maxDimension: null,
|
|
121
121
|
maxMetric: 1,
|
|
122
122
|
hasBreakdownDimension: !0,
|
|
@@ -133,7 +133,7 @@ const je = [
|
|
|
133
133
|
periodType: null
|
|
134
134
|
},
|
|
135
135
|
{
|
|
136
|
-
type:
|
|
136
|
+
type: I.Scorecard,
|
|
137
137
|
maxDimension: null,
|
|
138
138
|
maxMetric: 1,
|
|
139
139
|
hasBreakdownDimension: !1,
|
|
@@ -150,7 +150,7 @@ const je = [
|
|
|
150
150
|
periodType: null
|
|
151
151
|
},
|
|
152
152
|
{
|
|
153
|
-
type:
|
|
153
|
+
type: I.Spacer,
|
|
154
154
|
maxDimension: 0,
|
|
155
155
|
maxMetric: 0,
|
|
156
156
|
hasBreakdownDimension: !1,
|
|
@@ -166,9 +166,9 @@ const je = [
|
|
|
166
166
|
canSearch: !1,
|
|
167
167
|
periodType: null
|
|
168
168
|
}
|
|
169
|
-
],
|
|
169
|
+
], Ll = { class: "flex flex-col my-2 gap-8" }, Ml = { class: "fm-typo-en-body-lg-600" }, Nl = { class: "text-sm text-fm-color-neutral-gray-400" }, Ol = ["onClick"], jl = { class: "fm-typo-en-body-lg-400 overflow-hidden text-ellipsis line-clamp-1" }, zl = /* @__PURE__ */ ae({
|
|
170
170
|
__name: "SchemaSection",
|
|
171
|
-
props: /* @__PURE__ */
|
|
171
|
+
props: /* @__PURE__ */ ue({
|
|
172
172
|
options: {
|
|
173
173
|
type: Array,
|
|
174
174
|
default: () => []
|
|
@@ -183,58 +183,58 @@ const je = [
|
|
|
183
183
|
}),
|
|
184
184
|
emits: ["update:modelValue"],
|
|
185
185
|
setup(D) {
|
|
186
|
-
const { t: d, te: e } =
|
|
187
|
-
() =>
|
|
188
|
-
label:
|
|
189
|
-
value:
|
|
190
|
-
raw:
|
|
186
|
+
const { t: d, te: e } = se(), s = ce(D, "modelValue"), a = D, { schemas: w } = Ve(ol()), x = S(
|
|
187
|
+
() => w.value.map((f) => ({
|
|
188
|
+
label: f.label,
|
|
189
|
+
value: f.name,
|
|
190
|
+
raw: f
|
|
191
191
|
}))
|
|
192
|
-
),
|
|
192
|
+
), v = S(() => {
|
|
193
193
|
if (s.value.schemaNames.length === 0 || t.value === 0)
|
|
194
|
-
return
|
|
194
|
+
return x.value.filter((f) => !f.raw.isJoinOnly);
|
|
195
195
|
{
|
|
196
|
-
const
|
|
197
|
-
return
|
|
196
|
+
const f = s.value.schemaNames[0], V = w.value.find((_) => _.name === f), M = ((V == null ? void 0 : V.joins) || []).map((_) => _);
|
|
197
|
+
return x.value.filter((_) => M.includes(_.raw.name));
|
|
198
198
|
}
|
|
199
|
-
}),
|
|
200
|
-
function b(
|
|
201
|
-
var
|
|
202
|
-
return
|
|
199
|
+
}), C = ee(!1), k = ee(""), t = ee(), i = Tl();
|
|
200
|
+
function b(f) {
|
|
201
|
+
var V;
|
|
202
|
+
return ie(
|
|
203
203
|
d,
|
|
204
204
|
e,
|
|
205
|
-
(
|
|
205
|
+
(V = w.value.find((M) => M.name === f)) == null ? void 0 : V.label,
|
|
206
206
|
"schema"
|
|
207
207
|
);
|
|
208
208
|
}
|
|
209
|
-
function
|
|
210
|
-
t.value =
|
|
209
|
+
function F(f) {
|
|
210
|
+
t.value = f, C.value = !0, f !== void 0 ? k.value = s.value.schemaNames[f] : k.value = "";
|
|
211
211
|
}
|
|
212
|
-
function
|
|
213
|
-
|
|
212
|
+
function T() {
|
|
213
|
+
k.value !== "" ? (t.value !== void 0 ? s.value.schemaNames[t.value] = k.value : s.value.schemaNames.push(k.value), C.value = !1) : i.open({ message: d("report.section.schema.nothingSelected"), type: "error" });
|
|
214
214
|
}
|
|
215
|
-
return (
|
|
216
|
-
const
|
|
217
|
-
return
|
|
218
|
-
r(
|
|
219
|
-
modelValue:
|
|
220
|
-
"onUpdate:modelValue":
|
|
215
|
+
return (f, V) => {
|
|
216
|
+
const M = $("FmForm"), _ = $("FmIcon"), p = $("FmField");
|
|
217
|
+
return g(), A("div", Ll, [
|
|
218
|
+
r(Te, {
|
|
219
|
+
modelValue: C.value,
|
|
220
|
+
"onUpdate:modelValue": V[1] || (V[1] = (o) => C.value = o),
|
|
221
221
|
title: a.label,
|
|
222
222
|
"primary-button-label": l(d)("report.common.confirm"),
|
|
223
223
|
"secondary-button-label": l(d)("report.common.cancel"),
|
|
224
|
-
onConfirm:
|
|
224
|
+
onConfirm: T
|
|
225
225
|
}, {
|
|
226
226
|
content: R(() => [
|
|
227
|
-
r(
|
|
227
|
+
r(M, { ref: "form" }, {
|
|
228
228
|
default: R(() => [
|
|
229
|
-
r(
|
|
230
|
-
modelValue:
|
|
231
|
-
"onUpdate:modelValue":
|
|
229
|
+
r(me, {
|
|
230
|
+
modelValue: k.value,
|
|
231
|
+
"onUpdate:modelValue": V[0] || (V[0] = (o) => k.value = o),
|
|
232
232
|
label: l(d)("report.section.schema.title"),
|
|
233
|
-
items: t.value === 0 ?
|
|
234
|
-
label: l(
|
|
233
|
+
items: t.value === 0 ? x.value.map((o) => ({
|
|
234
|
+
label: l(ie)(l(d), l(e), o.label, "schema"),
|
|
235
235
|
value: o.value
|
|
236
|
-
})) :
|
|
237
|
-
label: l(
|
|
236
|
+
})) : v.value.map((o) => ({
|
|
237
|
+
label: l(ie)(l(d), l(e), o.label, "schema"),
|
|
238
238
|
value: o.value
|
|
239
239
|
}))
|
|
240
240
|
}, null, 8, ["modelValue", "label", "items"])
|
|
@@ -244,35 +244,35 @@ const je = [
|
|
|
244
244
|
]),
|
|
245
245
|
_: 1
|
|
246
246
|
}, 8, ["modelValue", "title", "primary-button-label", "secondary-button-label"]),
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
247
|
+
h("div", null, [
|
|
248
|
+
h("p", Ml, P(l(d)("report.section.schema.title")), 1),
|
|
249
|
+
h("p", Nl, P(l(d)("report.section.schema.description")), 1)
|
|
250
250
|
]),
|
|
251
|
-
(
|
|
251
|
+
(g(!0), A(re, null, we(s.value.schemaNames, (o, n) => (g(), A("div", {
|
|
252
252
|
key: n,
|
|
253
253
|
class: "flex flex-col gap-2 w-full"
|
|
254
254
|
}, [
|
|
255
|
-
|
|
255
|
+
h("div", {
|
|
256
256
|
class: "flex items-center gap-2 border rounded-md border-neutral-300 p-2 h-[40px]",
|
|
257
|
-
onClick: (
|
|
257
|
+
onClick: (c) => F(n)
|
|
258
258
|
}, [
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
r(
|
|
259
|
+
h("p", jl, P(b(o)), 1),
|
|
260
|
+
V[3] || (V[3] = h("div", { class: "grow" }, null, -1)),
|
|
261
|
+
r(_, {
|
|
262
262
|
name: "close",
|
|
263
|
-
onClick:
|
|
263
|
+
onClick: ge(
|
|
264
264
|
() => {
|
|
265
|
-
s.value.schemaNames = l(
|
|
265
|
+
s.value.schemaNames = l(hl)(s.value.schemaNames, n);
|
|
266
266
|
},
|
|
267
267
|
["stop"]
|
|
268
268
|
)
|
|
269
269
|
}, null, 8, ["onClick"])
|
|
270
|
-
], 8,
|
|
270
|
+
], 8, Ol)
|
|
271
271
|
]))), 128)),
|
|
272
|
-
r(
|
|
272
|
+
r(p, {
|
|
273
273
|
class: "text-fm-color-typo-tertiary",
|
|
274
|
-
onClick:
|
|
275
|
-
|
|
274
|
+
onClick: V[2] || (V[2] = () => {
|
|
275
|
+
F();
|
|
276
276
|
})
|
|
277
277
|
}, {
|
|
278
278
|
default: R(() => [
|
|
@@ -286,9 +286,9 @@ const je = [
|
|
|
286
286
|
}), Il = {
|
|
287
287
|
key: 0,
|
|
288
288
|
class: "flex flex-col my-2 gap-8"
|
|
289
|
-
},
|
|
289
|
+
}, Al = { class: "fm-typo-en-body-lg-600 text-ellipsis line-clamp-1" }, Rl = { class: "fm-typo-en-body-sm-600 text-fm-color-neutral-gray-400" }, Pl = { class: "fm-typo-en-body-lg-400 text-ellipsis overflow-hidden line-clamp-1" }, Ae = /* @__PURE__ */ ae({
|
|
290
290
|
__name: "DimensionSection",
|
|
291
|
-
props: /* @__PURE__ */
|
|
291
|
+
props: /* @__PURE__ */ ue({
|
|
292
292
|
options: {
|
|
293
293
|
type: Array,
|
|
294
294
|
default: () => []
|
|
@@ -319,207 +319,207 @@ const je = [
|
|
|
319
319
|
}),
|
|
320
320
|
emits: ["update:modelValue"],
|
|
321
321
|
setup(D) {
|
|
322
|
-
const { t: d, te: e } =
|
|
323
|
-
() => s.value.map((
|
|
322
|
+
const { t: d, te: e } = se(), s = ce(D, "modelValue"), a = D, w = S(() => d(`report.section.dimension.${a.label}`)), x = ee(!1), v = S(
|
|
323
|
+
() => s.value.map((c, u) => ({
|
|
324
324
|
index: u,
|
|
325
|
-
labels: [
|
|
326
|
-
value:
|
|
325
|
+
labels: [c.label || c.name],
|
|
326
|
+
value: c
|
|
327
327
|
}))
|
|
328
|
-
),
|
|
329
|
-
function
|
|
330
|
-
var u, m, y,
|
|
331
|
-
|
|
328
|
+
), C = ee(s.value.length > 0 ? 0 : void 0);
|
|
329
|
+
function k(c) {
|
|
330
|
+
var u, m, y, j;
|
|
331
|
+
x.value = !0, t.value = c != null && c.value ? JSON.parse(
|
|
332
332
|
JSON.stringify({
|
|
333
|
-
...
|
|
334
|
-
label:
|
|
335
|
-
moveToColumn: (((m = a.config) == null ? void 0 : m.columnIds) || []).includes(
|
|
333
|
+
...c.value,
|
|
334
|
+
label: ie(d, e, (u = c.value) == null ? void 0 : u.label, "other"),
|
|
335
|
+
moveToColumn: (((m = a.config) == null ? void 0 : m.columnIds) || []).includes(xe(c.value))
|
|
336
336
|
})
|
|
337
|
-
) : void 0,
|
|
338
|
-
(
|
|
339
|
-
var
|
|
340
|
-
return
|
|
337
|
+
) : void 0, C.value = c == null ? void 0 : c.index, i.value = !!((y = t.value) != null && y.dataFormula || (j = t.value) != null && j.displayFormula), t.value && t.value.formatter === void 0 && (a.options.find(
|
|
338
|
+
(Q) => {
|
|
339
|
+
var E, X;
|
|
340
|
+
return Q.schemaName === ((E = t.value) == null ? void 0 : E.schemaName) && Q.name === ((X = t.value) == null ? void 0 : X.name);
|
|
341
341
|
}
|
|
342
|
-
),
|
|
342
|
+
), c != null && c.value.timeFormatter && t.value.formatter === void 0 && (t.value.formatter = c == null ? void 0 : c.value.timeFormatter, t.value.timeFormatter = void 0));
|
|
343
343
|
}
|
|
344
|
-
const t = ee(void 0), i = ee(!1), b =
|
|
344
|
+
const t = ee(void 0), i = ee(!1), b = S(
|
|
345
345
|
() => a.options.find(
|
|
346
|
-
(
|
|
346
|
+
(c) => {
|
|
347
347
|
var u, m;
|
|
348
|
-
return
|
|
348
|
+
return c.schemaName === ((u = t.value) == null ? void 0 : u.schemaName) && c.name === ((m = t.value) == null ? void 0 : m.name);
|
|
349
349
|
}
|
|
350
350
|
) ?? {}
|
|
351
351
|
);
|
|
352
352
|
ye(
|
|
353
353
|
() => {
|
|
354
|
-
var
|
|
355
|
-
return (
|
|
354
|
+
var c;
|
|
355
|
+
return (c = t.value) == null ? void 0 : c.option;
|
|
356
356
|
},
|
|
357
357
|
() => {
|
|
358
|
-
!
|
|
358
|
+
!F.value && t.value && (t.value.fillGap = !1);
|
|
359
359
|
}
|
|
360
360
|
);
|
|
361
|
-
const
|
|
361
|
+
const F = S(
|
|
362
362
|
() => {
|
|
363
|
-
var
|
|
364
|
-
return (m = (
|
|
363
|
+
var c, u, m;
|
|
364
|
+
return (m = (c = b.value) == null ? void 0 : c.fillGapDimensionOptions) == null ? void 0 : m.includes(((u = t.value) == null ? void 0 : u.option) || "");
|
|
365
365
|
}
|
|
366
366
|
);
|
|
367
|
-
function
|
|
367
|
+
function T(c) {
|
|
368
368
|
var u, m;
|
|
369
|
-
(
|
|
370
|
-
schemaName:
|
|
371
|
-
name:
|
|
372
|
-
option:
|
|
373
|
-
label:
|
|
374
|
-
decimal:
|
|
369
|
+
(c.schemaName !== ((u = t.value) == null ? void 0 : u.schemaName) || c.name !== ((m = t.value) == null ? void 0 : m.name)) && (t.value = {
|
|
370
|
+
schemaName: c.schemaName,
|
|
371
|
+
name: c.name,
|
|
372
|
+
option: c.dimensionOptions[0],
|
|
373
|
+
label: ie(d, e, c.label, "other"),
|
|
374
|
+
decimal: c.isNumericType ? 2 : void 0,
|
|
375
375
|
hide: !1
|
|
376
376
|
}, i.value = !1);
|
|
377
377
|
}
|
|
378
|
-
function
|
|
378
|
+
function f() {
|
|
379
379
|
if (!t.value) {
|
|
380
380
|
console.error("new field is undefined");
|
|
381
381
|
return;
|
|
382
382
|
}
|
|
383
|
-
const
|
|
384
|
-
i.value || (t.value.dataFormula = void 0),
|
|
383
|
+
const c = [...v.value.map((u) => u.value)];
|
|
384
|
+
i.value || (t.value.dataFormula = void 0), C.value !== void 0 ? c[C.value] = t.value : c.push(t.value), s.value = c, x.value = !1;
|
|
385
385
|
}
|
|
386
|
-
function
|
|
387
|
-
const m = [...
|
|
386
|
+
function V(c) {
|
|
387
|
+
const m = [...v.value.map((y) => y.value)].filter((y, j) => j !== c);
|
|
388
388
|
s.value = m;
|
|
389
389
|
}
|
|
390
|
-
function
|
|
391
|
-
t.value && (t.value.decimal = Number(
|
|
390
|
+
function M(c) {
|
|
391
|
+
t.value && (t.value.decimal = Number(c));
|
|
392
392
|
}
|
|
393
|
-
function
|
|
394
|
-
const u = `report.section.filter.${
|
|
395
|
-
return e(u) ? d(u) :
|
|
393
|
+
function _(c) {
|
|
394
|
+
const u = `report.section.filter.${ke(c)}`;
|
|
395
|
+
return e(u) ? d(u) : ie(d, e, c, "field");
|
|
396
396
|
}
|
|
397
|
-
function
|
|
398
|
-
const u = `report.section.metric.formatterType.${
|
|
399
|
-
return e(u) ? d(u) :
|
|
397
|
+
function p(c) {
|
|
398
|
+
const u = `report.section.metric.formatterType.${c}`;
|
|
399
|
+
return e(u) ? d(u) : c;
|
|
400
400
|
}
|
|
401
|
-
function o(
|
|
402
|
-
return Array.isArray(
|
|
401
|
+
function o(c) {
|
|
402
|
+
return Array.isArray(c) ? c.length > 0 : c;
|
|
403
403
|
}
|
|
404
|
-
const n =
|
|
405
|
-
() => a.options.map((
|
|
406
|
-
label:
|
|
407
|
-
value:
|
|
404
|
+
const n = S(
|
|
405
|
+
() => a.options.map((c) => ({
|
|
406
|
+
label: c.labels.join(" "),
|
|
407
|
+
value: c
|
|
408
408
|
}))
|
|
409
409
|
);
|
|
410
|
-
return (
|
|
411
|
-
const m = $("FmTextField"), y = $("FmStepperField"),
|
|
412
|
-
return D.max !== 0 ? (
|
|
413
|
-
r(
|
|
414
|
-
modelValue:
|
|
415
|
-
"onUpdate:modelValue": u[12] || (u[12] = (
|
|
416
|
-
title:
|
|
410
|
+
return (c, u) => {
|
|
411
|
+
const m = $("FmTextField"), y = $("FmStepperField"), j = $("FmCheckbox"), Q = $("FmTextarea"), E = $("FmForm"), X = $("FmIcon"), J = $("FmButton"), le = $("FmListItem"), B = $("FmList"), G = $("FmField");
|
|
412
|
+
return D.max !== 0 ? (g(), A("div", Il, [
|
|
413
|
+
r(Te, {
|
|
414
|
+
modelValue: x.value,
|
|
415
|
+
"onUpdate:modelValue": u[12] || (u[12] = (te) => x.value = te),
|
|
416
|
+
title: w.value,
|
|
417
417
|
"primary-button-label": l(d)("report.common.confirm"),
|
|
418
418
|
"secondary-button-label": l(d)("report.common.cancel"),
|
|
419
|
-
onConfirm:
|
|
419
|
+
onConfirm: f
|
|
420
420
|
}, {
|
|
421
421
|
content: R(() => [
|
|
422
|
-
r(
|
|
422
|
+
r(E, {
|
|
423
423
|
ref: "form",
|
|
424
424
|
class: "flex flex-col gap-2 w-[490px]"
|
|
425
425
|
}, {
|
|
426
426
|
default: R(() => {
|
|
427
|
-
var
|
|
427
|
+
var te, ve, W, de, $e, De, Be;
|
|
428
428
|
return [
|
|
429
|
-
r(
|
|
429
|
+
r(me, {
|
|
430
430
|
"model-value": b.value,
|
|
431
431
|
items: n.value,
|
|
432
|
-
placeholder:
|
|
433
|
-
label:
|
|
434
|
-
"onUpdate:modelValue": u[0] || (u[0] = (
|
|
432
|
+
placeholder: w.value,
|
|
433
|
+
label: w.value,
|
|
434
|
+
"onUpdate:modelValue": u[0] || (u[0] = (Z) => T(Z))
|
|
435
435
|
}, null, 8, ["model-value", "items", "placeholder", "label"]),
|
|
436
|
-
t.value ? (
|
|
436
|
+
t.value ? (g(), A(re, { key: 0 }, [
|
|
437
437
|
r(m, {
|
|
438
438
|
modelValue: t.value.label,
|
|
439
|
-
"onUpdate:modelValue": u[1] || (u[1] = (
|
|
439
|
+
"onUpdate:modelValue": u[1] || (u[1] = (Z) => t.value.label = Z),
|
|
440
440
|
label: l(d)("report.section.dimension.label")
|
|
441
441
|
}, null, 8, ["modelValue", "label"]),
|
|
442
|
-
(((
|
|
442
|
+
(((te = b.value) == null ? void 0 : te.dimensionOptions) || []).length > 0 ? (g(), N(me, {
|
|
443
443
|
key: 0,
|
|
444
444
|
modelValue: t.value.option,
|
|
445
|
-
"onUpdate:modelValue": u[2] || (u[2] = (
|
|
446
|
-
items: ((
|
|
447
|
-
label:
|
|
448
|
-
value:
|
|
445
|
+
"onUpdate:modelValue": u[2] || (u[2] = (Z) => t.value.option = Z),
|
|
446
|
+
items: ((ve = b.value) == null ? void 0 : ve.dimensionOptions.map((Z) => ({
|
|
447
|
+
label: _(Z),
|
|
448
|
+
value: Z
|
|
449
449
|
}))) ?? []
|
|
450
450
|
}, null, 8, ["modelValue", "items"])) : O("", !0),
|
|
451
|
-
(
|
|
451
|
+
(W = b.value) != null && W.isNumericType ? (g(), N(y, {
|
|
452
452
|
key: 1,
|
|
453
453
|
label: l(d)("report.common.decimal"),
|
|
454
|
-
"model-value": ((
|
|
455
|
-
"onUpdate:modelValue": u[3] || (u[3] = (
|
|
456
|
-
|
|
454
|
+
"model-value": ((de = t.value) == null ? void 0 : de.decimal) ?? 2,
|
|
455
|
+
"onUpdate:modelValue": u[3] || (u[3] = (Z) => {
|
|
456
|
+
M(Z);
|
|
457
457
|
})
|
|
458
458
|
}, null, 8, ["label", "model-value"])) : O("", !0),
|
|
459
|
-
(
|
|
459
|
+
($e = b.value) != null && $e.isNumericType ? (g(), N(me, {
|
|
460
460
|
key: 2,
|
|
461
461
|
modelValue: t.value.formatter,
|
|
462
|
-
"onUpdate:modelValue": u[4] || (u[4] = (
|
|
462
|
+
"onUpdate:modelValue": u[4] || (u[4] = (Z) => t.value.formatter = Z),
|
|
463
463
|
placeholder: l(d)("report.section.dimension.formatter"),
|
|
464
464
|
label: l(d)("report.section.dimension.formatter"),
|
|
465
465
|
items: [
|
|
466
466
|
{ label: l(d)("report.section.metric.formatterType.NONE"), value: null },
|
|
467
|
-
...(((
|
|
468
|
-
label:
|
|
469
|
-
value:
|
|
467
|
+
...(((De = b.value) == null ? void 0 : De.formatters) || []).map((Z) => ({
|
|
468
|
+
label: p(Z),
|
|
469
|
+
value: Z
|
|
470
470
|
}))
|
|
471
471
|
]
|
|
472
472
|
}, null, 8, ["modelValue", "placeholder", "label", "items"])) : O("", !0),
|
|
473
|
-
|
|
473
|
+
F.value ? (g(), N(j, {
|
|
474
474
|
key: 3,
|
|
475
475
|
"model-value": t.value.fillGap ?? !1,
|
|
476
476
|
label: l(d)("report.section.dimension.fillGap"),
|
|
477
477
|
value: "",
|
|
478
478
|
placeholder: "Fill gap",
|
|
479
|
-
"onUpdate:modelValue": u[5] || (u[5] = (
|
|
480
|
-
t.value && (t.value.fillGap = o(
|
|
479
|
+
"onUpdate:modelValue": u[5] || (u[5] = (Z) => {
|
|
480
|
+
t.value && (t.value.fillGap = o(Z));
|
|
481
481
|
})
|
|
482
482
|
}, null, 8, ["model-value", "label"])) : O("", !0),
|
|
483
|
-
((
|
|
483
|
+
((Be = b.value) == null ? void 0 : Be.type) === l(kl).Timestamp ? (g(), N(j, {
|
|
484
484
|
key: 4,
|
|
485
485
|
"model-value": t.value.dateComparison ?? !1,
|
|
486
486
|
label: l(d)("report.section.dimension.dateComparison"),
|
|
487
487
|
value: "",
|
|
488
|
-
"onUpdate:modelValue": u[6] || (u[6] = (
|
|
489
|
-
t.value && (t.value.dateComparison = o(
|
|
488
|
+
"onUpdate:modelValue": u[6] || (u[6] = (Z) => {
|
|
489
|
+
t.value && (t.value.dateComparison = o(Z));
|
|
490
490
|
})
|
|
491
491
|
}, null, 8, ["model-value", "label"])) : O("", !0),
|
|
492
|
-
r(
|
|
492
|
+
r(j, {
|
|
493
493
|
modelValue: t.value.hide,
|
|
494
|
-
"onUpdate:modelValue": u[7] || (u[7] = (
|
|
494
|
+
"onUpdate:modelValue": u[7] || (u[7] = (Z) => t.value.hide = Z),
|
|
495
495
|
label: l(d)("report.section.dimension.hide"),
|
|
496
496
|
value: ""
|
|
497
497
|
}, null, 8, ["modelValue", "label"]),
|
|
498
|
-
a.hasRowColumn ? (
|
|
498
|
+
a.hasRowColumn ? (g(), N(j, {
|
|
499
499
|
key: 5,
|
|
500
500
|
"model-value": t.value.moveToColumn ?? !1,
|
|
501
501
|
label: l(d)("report.section.dimension.moveToColumn"),
|
|
502
502
|
value: "",
|
|
503
|
-
"onUpdate:modelValue": u[8] || (u[8] = (
|
|
504
|
-
t.value && (t.value.moveToColumn = o(
|
|
503
|
+
"onUpdate:modelValue": u[8] || (u[8] = (Z) => {
|
|
504
|
+
t.value && (t.value.moveToColumn = o(Z));
|
|
505
505
|
})
|
|
506
506
|
}, null, 8, ["model-value", "label"])) : O("", !0),
|
|
507
|
-
r(
|
|
507
|
+
r(j, {
|
|
508
508
|
modelValue: i.value,
|
|
509
|
-
"onUpdate:modelValue": u[9] || (u[9] = (
|
|
509
|
+
"onUpdate:modelValue": u[9] || (u[9] = (Z) => i.value = Z),
|
|
510
510
|
label: l(d)("report.section.dimension.advance"),
|
|
511
511
|
value: !0
|
|
512
512
|
}, null, 8, ["modelValue", "label"]),
|
|
513
|
-
i.value ? (
|
|
513
|
+
i.value ? (g(), N(Q, {
|
|
514
514
|
key: 6,
|
|
515
515
|
modelValue: t.value.dataFormula,
|
|
516
|
-
"onUpdate:modelValue": u[10] || (u[10] = (
|
|
516
|
+
"onUpdate:modelValue": u[10] || (u[10] = (Z) => t.value.dataFormula = Z),
|
|
517
517
|
placeholder: l(d)("report.section.dimension.dataFormula")
|
|
518
518
|
}, null, 8, ["modelValue", "placeholder"])) : O("", !0),
|
|
519
|
-
i.value ? (
|
|
519
|
+
i.value ? (g(), N(Q, {
|
|
520
520
|
key: 7,
|
|
521
521
|
modelValue: t.value.displayFormula,
|
|
522
|
-
"onUpdate:modelValue": u[11] || (u[11] = (
|
|
522
|
+
"onUpdate:modelValue": u[11] || (u[11] = (Z) => t.value.displayFormula = Z),
|
|
523
523
|
placeholder: l(d)("report.section.dimension.displayFormula")
|
|
524
524
|
}, null, 8, ["modelValue", "placeholder"])) : O("", !0)
|
|
525
525
|
], 64)) : O("", !0)
|
|
@@ -530,31 +530,31 @@ const je = [
|
|
|
530
530
|
]),
|
|
531
531
|
_: 1
|
|
532
532
|
}, 8, ["modelValue", "title", "primary-button-label", "secondary-button-label"]),
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
533
|
+
h("div", null, [
|
|
534
|
+
h("p", Al, P(w.value), 1),
|
|
535
|
+
h("p", Rl, P(l(d)("report.section.dimension.description")), 1)
|
|
536
536
|
]),
|
|
537
537
|
r(B, null, {
|
|
538
538
|
default: R(() => [
|
|
539
|
-
r(l(
|
|
539
|
+
r(l(ze), {
|
|
540
540
|
list: s.value,
|
|
541
|
-
"item-key": (
|
|
541
|
+
"item-key": (te) => l(xe)(te),
|
|
542
542
|
class: "flex flex-col gap-2"
|
|
543
543
|
}, {
|
|
544
|
-
item: R(({ element:
|
|
545
|
-
r(
|
|
544
|
+
item: R(({ element: te, index: ve }) => [
|
|
545
|
+
r(le, {
|
|
546
546
|
class: "!cursor-grab border rounded-md border-neutral-300 h-[40px] !p-[8px]",
|
|
547
|
-
onClick:
|
|
547
|
+
onClick: ge((W) => k(v.value[ve]), ["stop"])
|
|
548
548
|
}, {
|
|
549
549
|
default: R(() => [
|
|
550
550
|
r(X, { name: "drag_handle" }),
|
|
551
|
-
|
|
552
|
-
u[14] || (u[14] =
|
|
553
|
-
r(
|
|
551
|
+
h("p", Pl, P(l(ie)(l(d), l(e), te.label, "other")), 1),
|
|
552
|
+
u[14] || (u[14] = h("div", { class: "grow" }, null, -1)),
|
|
553
|
+
r(J, {
|
|
554
554
|
icon: "close",
|
|
555
555
|
size: "md",
|
|
556
556
|
variant: "tertiary",
|
|
557
|
-
onClick:
|
|
557
|
+
onClick: ge((W) => V(ve), ["stop"])
|
|
558
558
|
}, null, 8, ["onClick"])
|
|
559
559
|
]),
|
|
560
560
|
_: 2
|
|
@@ -568,7 +568,7 @@ const je = [
|
|
|
568
568
|
r(G, {
|
|
569
569
|
class: "text-fm-color-typo-tertiary",
|
|
570
570
|
onClick: u[13] || (u[13] = () => {
|
|
571
|
-
|
|
571
|
+
k();
|
|
572
572
|
})
|
|
573
573
|
}, {
|
|
574
574
|
default: R(() => [
|
|
@@ -579,25 +579,25 @@ const je = [
|
|
|
579
579
|
])) : O("", !0);
|
|
580
580
|
};
|
|
581
581
|
}
|
|
582
|
-
}),
|
|
582
|
+
}), Xe = {
|
|
583
583
|
value: "_metric_name"
|
|
584
584
|
};
|
|
585
|
-
function
|
|
585
|
+
function Xl(D, d, e) {
|
|
586
586
|
switch (D) {
|
|
587
|
-
case
|
|
588
|
-
case
|
|
589
|
-
case
|
|
590
|
-
case
|
|
591
|
-
case
|
|
592
|
-
case
|
|
587
|
+
case I.BarChart:
|
|
588
|
+
case I.StackBarChart:
|
|
589
|
+
case I.ClusteredStackBarChart:
|
|
590
|
+
case I.LineChart:
|
|
591
|
+
case I.StackLineChart:
|
|
592
|
+
case I.Circular:
|
|
593
593
|
return d.length > 1;
|
|
594
594
|
default:
|
|
595
595
|
return e;
|
|
596
596
|
}
|
|
597
597
|
}
|
|
598
|
-
function
|
|
598
|
+
function El(D) {
|
|
599
599
|
var s;
|
|
600
|
-
const { rowIds: d, columnIds: e } =
|
|
600
|
+
const { rowIds: d, columnIds: e } = je(D.widget.config);
|
|
601
601
|
return {
|
|
602
602
|
...D,
|
|
603
603
|
widget: {
|
|
@@ -606,39 +606,39 @@ function Pl(D) {
|
|
|
606
606
|
...D.widget.config,
|
|
607
607
|
rowIds: d,
|
|
608
608
|
columnIds: e,
|
|
609
|
-
isDrillable:
|
|
609
|
+
isDrillable: Xl(
|
|
610
610
|
D.widget.type,
|
|
611
611
|
D.widget.config.dimensions,
|
|
612
612
|
D.widget.config.isDrillable
|
|
613
613
|
),
|
|
614
614
|
joinDatasources: (s = D.widget.config.joinDatasources) == null ? void 0 : s.map((a) => {
|
|
615
|
-
const { rowIds:
|
|
615
|
+
const { rowIds: w, columnIds: x } = je(a);
|
|
616
616
|
return {
|
|
617
617
|
...a,
|
|
618
|
-
rowIds:
|
|
619
|
-
columnIds:
|
|
618
|
+
rowIds: w,
|
|
619
|
+
columnIds: x
|
|
620
620
|
};
|
|
621
621
|
})
|
|
622
622
|
}
|
|
623
623
|
}
|
|
624
624
|
};
|
|
625
625
|
}
|
|
626
|
-
function
|
|
627
|
-
const d = D.dimensions.filter((
|
|
628
|
-
s && D.metrics.find((
|
|
629
|
-
const a = [],
|
|
630
|
-
for (const
|
|
631
|
-
a.push(
|
|
632
|
-
for (const
|
|
633
|
-
|
|
626
|
+
function je(D) {
|
|
627
|
+
const d = D.dimensions.filter((x) => x.hide !== !0 && !x.moveToColumn).map((x) => xe(x)), e = D.dimensions.filter((x) => x.hide !== !0 && x.moveToColumn == !0).map((x) => xe(x)), s = D.metrics.length > 0;
|
|
628
|
+
s && D.metrics.find((x) => x.moveToRow == !0) ? d.push(Xe.value) : s && e.push(Xe.value);
|
|
629
|
+
const a = [], w = [];
|
|
630
|
+
for (const x of d)
|
|
631
|
+
a.push(x);
|
|
632
|
+
for (const x of e)
|
|
633
|
+
w.push(x);
|
|
634
634
|
return {
|
|
635
635
|
rowIds: a,
|
|
636
|
-
columnIds:
|
|
636
|
+
columnIds: w
|
|
637
637
|
};
|
|
638
638
|
}
|
|
639
|
-
const
|
|
639
|
+
const Wl = { class: "flex flex-col my-2 gap-8" }, ql = { class: "fm-typo-en-body-lg-600" }, Yl = { class: "fm-typo-en-body-sm-600 text-fm-color-neutral-gray-400" }, Hl = { class: "fm-typo-en-body-lg-400 overflow-hidden text-ellipsis line-clamp-1" }, Jl = /* @__PURE__ */ ae({
|
|
640
640
|
__name: "MetricSection",
|
|
641
|
-
props: /* @__PURE__ */
|
|
641
|
+
props: /* @__PURE__ */ ue({
|
|
642
642
|
options: {
|
|
643
643
|
type: Array,
|
|
644
644
|
default: () => []
|
|
@@ -668,179 +668,179 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
668
668
|
modelValue: { required: !1, default: [] },
|
|
669
669
|
modelModifiers: {}
|
|
670
670
|
}),
|
|
671
|
-
emits: /* @__PURE__ */
|
|
671
|
+
emits: /* @__PURE__ */ ue(["config"], ["update:modelValue"]),
|
|
672
672
|
setup(D, { emit: d }) {
|
|
673
|
-
const { t: e, te: s } =
|
|
674
|
-
|
|
675
|
-
const
|
|
673
|
+
const { t: e, te: s } = se(), a = ce(D, "modelValue"), w = D;
|
|
674
|
+
S(() => !!w.max && a.value.length === w.max);
|
|
675
|
+
const x = S(() => e(`report.section.metric.${w.label}`)), v = ee(!1), C = S(
|
|
676
676
|
() => a.value.map((o, n) => ({
|
|
677
677
|
index: n,
|
|
678
678
|
labels: [o.label || o.name],
|
|
679
679
|
value: o
|
|
680
680
|
}))
|
|
681
|
-
),
|
|
681
|
+
), k = ee(a.value.length > 0 ? 0 : void 0);
|
|
682
682
|
function t(o) {
|
|
683
|
-
var n,
|
|
684
|
-
|
|
683
|
+
var n, c, u;
|
|
684
|
+
v.value = !0, i.value = o != null && o.value ? JSON.parse(
|
|
685
685
|
JSON.stringify({
|
|
686
686
|
...o.value,
|
|
687
|
-
label:
|
|
687
|
+
label: ie(e, s, o.value.label, "other")
|
|
688
688
|
})
|
|
689
|
-
) : void 0,
|
|
689
|
+
) : void 0, k.value = o == null ? void 0 : o.index, b.value = !!((n = i.value) != null && n.dataFormula || (c = i.value) != null && c.displayFormula), i.value && i.value.formatter === void 0 && (w.options.find(
|
|
690
690
|
(m) => {
|
|
691
|
-
var y,
|
|
692
|
-
return m.schemaName === ((y = i.value) == null ? void 0 : y.schemaName) && m.name === ((
|
|
691
|
+
var y, j;
|
|
692
|
+
return m.schemaName === ((y = i.value) == null ? void 0 : y.schemaName) && m.name === ((j = i.value) == null ? void 0 : j.name);
|
|
693
693
|
}
|
|
694
|
-
), 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)), ((u =
|
|
694
|
+
), 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)), ((u = w.config.rowIds) == null ? void 0 : u.findIndex((m) => m === Xe.value)) !== -1 && i.value && (i.value.moveToRow = !0), i.value && (!w.hasXy || i.value.nullable === void 0) && (i.value.nullable = !1);
|
|
695
695
|
}
|
|
696
|
-
const i = ee(void 0), b = ee(!1),
|
|
697
|
-
() =>
|
|
696
|
+
const i = ee(void 0), b = ee(!1), F = S(
|
|
697
|
+
() => w.options.find(
|
|
698
698
|
(o) => {
|
|
699
|
-
var n,
|
|
700
|
-
return o.schemaName === ((n = i.value) == null ? void 0 : n.schemaName) && o.name === ((
|
|
699
|
+
var n, c;
|
|
700
|
+
return o.schemaName === ((n = i.value) == null ? void 0 : n.schemaName) && o.name === ((c = i.value) == null ? void 0 : c.name);
|
|
701
701
|
}
|
|
702
702
|
) ?? {}
|
|
703
703
|
);
|
|
704
|
-
function
|
|
705
|
-
var
|
|
706
|
-
return (o == null ? void 0 : o.isNumericType) || ((
|
|
704
|
+
function T(o, n) {
|
|
705
|
+
var c;
|
|
706
|
+
return (o == null ? void 0 : o.isNumericType) || ((c = o == null ? void 0 : o.isNumericAggregations) == null ? void 0 : c.includes(n || ""));
|
|
707
707
|
}
|
|
708
|
-
const
|
|
708
|
+
const f = S(
|
|
709
709
|
() => {
|
|
710
710
|
var o;
|
|
711
|
-
return
|
|
711
|
+
return T(F.value, (o = i.value) == null ? void 0 : o.aggregation);
|
|
712
712
|
}
|
|
713
713
|
);
|
|
714
|
-
ye(
|
|
714
|
+
ye(f, (o) => {
|
|
715
715
|
i.value && (o ? i.value.decimal = typeof i.value.decimal != "number" ? 2 : i.value.decimal : i.value.decimal = void 0);
|
|
716
716
|
});
|
|
717
|
-
function
|
|
718
|
-
var n,
|
|
719
|
-
(o.schemaName !== ((n = i.value) == null ? void 0 : n.schemaName) || o.name !== ((
|
|
717
|
+
function V(o) {
|
|
718
|
+
var n, c;
|
|
719
|
+
(o.schemaName !== ((n = i.value) == null ? void 0 : n.schemaName) || o.name !== ((c = i.value) == null ? void 0 : c.name)) && (i.value = {
|
|
720
720
|
schemaName: o.schemaName,
|
|
721
721
|
name: o.name,
|
|
722
722
|
aggregation: o.aggregations[0],
|
|
723
|
-
label:
|
|
723
|
+
label: ie(e, s, o.label, "other"),
|
|
724
724
|
nullable: !1,
|
|
725
|
-
decimal:
|
|
725
|
+
decimal: T(o, o.aggregations[0]) ? 2 : void 0,
|
|
726
726
|
moveToRow: !1,
|
|
727
727
|
hide: !1
|
|
728
728
|
}, b.value = !1);
|
|
729
729
|
}
|
|
730
|
-
function
|
|
731
|
-
const o = [...
|
|
732
|
-
i.value && (b.value || (i.value.dataFormula = void 0),
|
|
730
|
+
function M() {
|
|
731
|
+
const o = [...C.value.map((n) => n.value)];
|
|
732
|
+
i.value && (b.value || (i.value.dataFormula = void 0), w.hasXy || (i.value.nullable = !1), k.value !== void 0 ? o[k.value] = i.value : o.push(i.value)), a.value = o, v.value = !1;
|
|
733
733
|
}
|
|
734
|
-
function
|
|
735
|
-
const n = [...
|
|
734
|
+
function _(o) {
|
|
735
|
+
const n = [...C.value.map((c) => c.value)];
|
|
736
736
|
n.splice(o, 1), a.value = n;
|
|
737
737
|
}
|
|
738
|
-
const
|
|
739
|
-
() =>
|
|
738
|
+
const p = S(
|
|
739
|
+
() => w.options.map((o) => ({
|
|
740
740
|
label: o.labels.join(" "),
|
|
741
741
|
value: o
|
|
742
742
|
}))
|
|
743
743
|
);
|
|
744
744
|
return (o, n) => {
|
|
745
|
-
const
|
|
746
|
-
return
|
|
747
|
-
r(
|
|
748
|
-
modelValue:
|
|
749
|
-
"onUpdate:modelValue": n[11] || (n[11] = (B) =>
|
|
750
|
-
title:
|
|
751
|
-
onConfirm:
|
|
745
|
+
const c = $("FmTextField"), u = $("FmStepperField"), m = $("FmCheckbox"), y = $("FmTextarea"), j = $("FmForm"), Q = $("FmIcon"), E = $("FmButton"), X = $("FmListItem"), J = $("FmList"), le = $("FmField");
|
|
746
|
+
return g(), A("div", Wl, [
|
|
747
|
+
r(Te, {
|
|
748
|
+
modelValue: v.value,
|
|
749
|
+
"onUpdate:modelValue": n[11] || (n[11] = (B) => v.value = B),
|
|
750
|
+
title: x.value,
|
|
751
|
+
onConfirm: M
|
|
752
752
|
}, {
|
|
753
753
|
content: R(() => [
|
|
754
|
-
r(
|
|
754
|
+
r(j, {
|
|
755
755
|
ref: "form",
|
|
756
756
|
class: "flex flex-col gap-2 w-[490px]"
|
|
757
757
|
}, {
|
|
758
758
|
default: R(() => {
|
|
759
|
-
var B, G,
|
|
759
|
+
var B, G, te, ve;
|
|
760
760
|
return [
|
|
761
|
-
r(
|
|
762
|
-
"model-value":
|
|
763
|
-
items:
|
|
764
|
-
placeholder:
|
|
765
|
-
label:
|
|
766
|
-
"onUpdate:modelValue": n[0] || (n[0] = (
|
|
761
|
+
r(me, {
|
|
762
|
+
"model-value": F.value,
|
|
763
|
+
items: p.value,
|
|
764
|
+
placeholder: x.value,
|
|
765
|
+
label: x.value,
|
|
766
|
+
"onUpdate:modelValue": n[0] || (n[0] = (W) => V(W))
|
|
767
767
|
}, null, 8, ["model-value", "items", "placeholder", "label"]),
|
|
768
|
-
i.value ? (
|
|
769
|
-
r(
|
|
768
|
+
i.value ? (g(), A(re, { key: 0 }, [
|
|
769
|
+
r(c, {
|
|
770
770
|
modelValue: i.value.label,
|
|
771
|
-
"onUpdate:modelValue": n[1] || (n[1] = (
|
|
771
|
+
"onUpdate:modelValue": n[1] || (n[1] = (W) => i.value.label = W),
|
|
772
772
|
label: l(e)("report.section.metric.label")
|
|
773
773
|
}, null, 8, ["modelValue", "label"]),
|
|
774
|
-
(((B =
|
|
774
|
+
(((B = F.value) == null ? void 0 : B.aggregations) || []).length > 0 ? (g(), N(me, {
|
|
775
775
|
key: 0,
|
|
776
776
|
modelValue: i.value.aggregation,
|
|
777
|
-
"onUpdate:modelValue": n[2] || (n[2] = (
|
|
777
|
+
"onUpdate:modelValue": n[2] || (n[2] = (W) => i.value.aggregation = W),
|
|
778
778
|
label: l(e)("report.section.metric.aggregation"),
|
|
779
|
-
items: ((G =
|
|
780
|
-
label: l(s)(`report.section.metric.aggregationType.${
|
|
781
|
-
value:
|
|
779
|
+
items: ((G = F.value) == null ? void 0 : G.aggregations.map((W) => ({
|
|
780
|
+
label: l(s)(`report.section.metric.aggregationType.${W}`) ? l(e)(`report.section.metric.aggregationType.${W}`) : l(ie)(l(e), l(s), W, "field"),
|
|
781
|
+
value: W
|
|
782
782
|
}))) ?? []
|
|
783
783
|
}, null, 8, ["modelValue", "label", "items"])) : O("", !0),
|
|
784
|
-
|
|
784
|
+
f.value ? (g(), N(u, {
|
|
785
785
|
key: 1,
|
|
786
786
|
label: l(e)("report.common.decimal"),
|
|
787
|
-
"model-value": ((
|
|
788
|
-
"onUpdate:modelValue": n[3] || (n[3] = (
|
|
789
|
-
i.value && (i.value.decimal =
|
|
787
|
+
"model-value": ((te = i.value) == null ? void 0 : te.decimal) ?? 2,
|
|
788
|
+
"onUpdate:modelValue": n[3] || (n[3] = (W) => {
|
|
789
|
+
i.value && (i.value.decimal = W);
|
|
790
790
|
})
|
|
791
791
|
}, null, 8, ["label", "model-value"])) : O("", !0),
|
|
792
|
-
|
|
792
|
+
f.value ? (g(), N(me, {
|
|
793
793
|
key: 2,
|
|
794
794
|
modelValue: i.value.formatter,
|
|
795
|
-
"onUpdate:modelValue": n[4] || (n[4] = (
|
|
795
|
+
"onUpdate:modelValue": n[4] || (n[4] = (W) => i.value.formatter = W),
|
|
796
796
|
placeholder: l(e)("report.section.metric.formatter"),
|
|
797
797
|
label: l(e)("report.section.metric.formatter"),
|
|
798
798
|
items: [
|
|
799
799
|
{ label: l(e)("report.section.metric.formatterType.NONE"), value: null },
|
|
800
|
-
...(((
|
|
801
|
-
label: l(s)(`report.section.metric.formatterType.${
|
|
802
|
-
value:
|
|
800
|
+
...(((ve = F.value) == null ? void 0 : ve.formatters) || []).map((W) => ({
|
|
801
|
+
label: l(s)(`report.section.metric.formatterType.${W}`) ? l(e)(`report.section.metric.formatterType.${W}`) : l(ie)(l(e), l(s), W, "field"),
|
|
802
|
+
value: W
|
|
803
803
|
}))
|
|
804
804
|
]
|
|
805
805
|
}, null, 8, ["modelValue", "placeholder", "label", "items"])) : O("", !0),
|
|
806
806
|
r(m, {
|
|
807
807
|
modelValue: i.value.hide,
|
|
808
|
-
"onUpdate:modelValue": n[5] || (n[5] = (
|
|
808
|
+
"onUpdate:modelValue": n[5] || (n[5] = (W) => i.value.hide = W),
|
|
809
809
|
label: l(e)("report.section.metric.hide"),
|
|
810
810
|
value: ""
|
|
811
811
|
}, null, 8, ["modelValue", "label"]),
|
|
812
|
-
|
|
812
|
+
w.hasXy ? (g(), N(m, {
|
|
813
813
|
key: 3,
|
|
814
814
|
"model-value": i.value.nullable ?? !1,
|
|
815
815
|
label: l(e)("report.section.metric.nullable"),
|
|
816
816
|
value: !0,
|
|
817
|
-
"onUpdate:modelValue": n[6] || (n[6] = (
|
|
818
|
-
i.value && (i.value.nullable =
|
|
817
|
+
"onUpdate:modelValue": n[6] || (n[6] = (W) => {
|
|
818
|
+
i.value && (i.value.nullable = W);
|
|
819
819
|
})
|
|
820
820
|
}, null, 8, ["model-value", "label"])) : O("", !0),
|
|
821
|
-
|
|
821
|
+
w.hasRowColumn ? (g(), N(m, {
|
|
822
822
|
key: 4,
|
|
823
823
|
modelValue: i.value.moveToRow,
|
|
824
|
-
"onUpdate:modelValue": n[7] || (n[7] = (
|
|
824
|
+
"onUpdate:modelValue": n[7] || (n[7] = (W) => i.value.moveToRow = W),
|
|
825
825
|
label: l(e)("report.section.metric.moveToRow"),
|
|
826
826
|
value: ""
|
|
827
827
|
}, null, 8, ["modelValue", "label"])) : O("", !0),
|
|
828
828
|
r(m, {
|
|
829
829
|
modelValue: b.value,
|
|
830
|
-
"onUpdate:modelValue": n[8] || (n[8] = (
|
|
830
|
+
"onUpdate:modelValue": n[8] || (n[8] = (W) => b.value = W),
|
|
831
831
|
label: l(e)("report.section.metric.advance"),
|
|
832
832
|
value: !0
|
|
833
833
|
}, null, 8, ["modelValue", "label"]),
|
|
834
|
-
b.value ? (
|
|
834
|
+
b.value ? (g(), N(y, {
|
|
835
835
|
key: 5,
|
|
836
836
|
modelValue: i.value.dataFormula,
|
|
837
|
-
"onUpdate:modelValue": n[9] || (n[9] = (
|
|
837
|
+
"onUpdate:modelValue": n[9] || (n[9] = (W) => i.value.dataFormula = W),
|
|
838
838
|
placeholder: l(e)("report.section.metric.dataFormula")
|
|
839
839
|
}, null, 8, ["modelValue", "placeholder"])) : O("", !0),
|
|
840
|
-
b.value ? (
|
|
840
|
+
b.value ? (g(), N(y, {
|
|
841
841
|
key: 6,
|
|
842
842
|
modelValue: i.value.displayFormula,
|
|
843
|
-
"onUpdate:modelValue": n[10] || (n[10] = (
|
|
843
|
+
"onUpdate:modelValue": n[10] || (n[10] = (W) => i.value.displayFormula = W),
|
|
844
844
|
placeholder: l(e)("report.section.metric.displayFormula")
|
|
845
845
|
}, null, 8, ["modelValue", "placeholder"])) : O("", !0)
|
|
846
846
|
], 64)) : O("", !0)
|
|
@@ -851,13 +851,13 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
851
851
|
]),
|
|
852
852
|
_: 1
|
|
853
853
|
}, 8, ["modelValue", "title"]),
|
|
854
|
-
|
|
855
|
-
|
|
856
|
-
|
|
854
|
+
h("div", null, [
|
|
855
|
+
h("p", ql, P(x.value), 1),
|
|
856
|
+
h("p", Yl, P(l(e)("report.section.metric.description")), 1)
|
|
857
857
|
]),
|
|
858
|
-
r(
|
|
858
|
+
r(J, null, {
|
|
859
859
|
default: R(() => [
|
|
860
|
-
r(l(
|
|
860
|
+
r(l(ze), {
|
|
861
861
|
list: a.value,
|
|
862
862
|
"item-key": "id",
|
|
863
863
|
class: "flex flex-col gap-2 w-full"
|
|
@@ -865,17 +865,17 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
865
865
|
item: R(({ element: B, index: G }) => [
|
|
866
866
|
r(X, {
|
|
867
867
|
class: "!cursor-grab border rounded-md border-neutral-300 h-[40px] !p-[8px]",
|
|
868
|
-
onClick:
|
|
868
|
+
onClick: ge((te) => t(C.value[G]), ["stop"])
|
|
869
869
|
}, {
|
|
870
870
|
default: R(() => [
|
|
871
|
-
r(
|
|
872
|
-
|
|
873
|
-
n[13] || (n[13] =
|
|
874
|
-
r(
|
|
871
|
+
r(Q, { name: "drag_handle" }),
|
|
872
|
+
h("p", Hl, P(l(ie)(l(e), l(s), B.label, "other")), 1),
|
|
873
|
+
n[13] || (n[13] = h("div", { class: "grow" }, null, -1)),
|
|
874
|
+
r(E, {
|
|
875
875
|
icon: "close",
|
|
876
876
|
size: "md",
|
|
877
877
|
variant: "tertiary",
|
|
878
|
-
onClick:
|
|
878
|
+
onClick: ge((te) => _(G), ["stop"])
|
|
879
879
|
}, null, 8, ["onClick"])
|
|
880
880
|
]),
|
|
881
881
|
_: 2
|
|
@@ -886,7 +886,7 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
886
886
|
]),
|
|
887
887
|
_: 1
|
|
888
888
|
}),
|
|
889
|
-
r(
|
|
889
|
+
r(le, {
|
|
890
890
|
class: "text-fm-color-typo-tertiary",
|
|
891
891
|
onClick: n[12] || (n[12] = () => {
|
|
892
892
|
t();
|
|
@@ -900,9 +900,9 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
900
900
|
]);
|
|
901
901
|
};
|
|
902
902
|
}
|
|
903
|
-
}),
|
|
903
|
+
}), Gl = { class: "flex flex-col my-2 gap-8" }, Kl = { class: "fm-typo-en-body-lg-600" }, Ql = { class: "fm-typo-en-body-sm-600 text-fm-color-neutral-gray-400" }, Zl = { class: "fm-typo-en-body-lg-400 text-ellipsis overflow-hidden line-clamp-1" }, eo = /* @__PURE__ */ ae({
|
|
904
904
|
__name: "SortSection",
|
|
905
|
-
props: /* @__PURE__ */
|
|
905
|
+
props: /* @__PURE__ */ ue({
|
|
906
906
|
options: {
|
|
907
907
|
type: Array,
|
|
908
908
|
default: () => []
|
|
@@ -917,113 +917,113 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
917
917
|
}),
|
|
918
918
|
emits: ["update:modelValue"],
|
|
919
919
|
setup(D) {
|
|
920
|
-
const { t: d, te: e } =
|
|
921
|
-
() => s.value.map((
|
|
920
|
+
const { t: d, te: e } = se(), s = ce(D, "modelValue"), a = D, w = S(() => d(`report.section.sort.${a.label}`)), x = ee(!1), v = S(
|
|
921
|
+
() => s.value.map((_, p) => {
|
|
922
922
|
const o = a.options.find(
|
|
923
|
-
(
|
|
924
|
-
), n = (o == null ? void 0 : o.labels) || [
|
|
923
|
+
(c) => c.schemaName === _.schemaName && c.name === _.name
|
|
924
|
+
), n = (o == null ? void 0 : o.labels) || [_.schemaName, _.name];
|
|
925
925
|
return {
|
|
926
|
-
index:
|
|
927
|
-
label: n.map((
|
|
928
|
-
value:
|
|
926
|
+
index: p,
|
|
927
|
+
label: n.map((c) => ie(d, e, c, "other")).join(" "),
|
|
928
|
+
value: _
|
|
929
929
|
};
|
|
930
930
|
})
|
|
931
|
-
),
|
|
932
|
-
function _
|
|
933
|
-
var
|
|
934
|
-
|
|
931
|
+
), C = ee(s.value.length > 0 ? 0 : void 0);
|
|
932
|
+
function k(_) {
|
|
933
|
+
var p;
|
|
934
|
+
x.value = !0, t.value = _ != null && _.value ? JSON.parse(JSON.stringify(_.value)) : void 0, C.value = _ == null ? void 0 : _.index, i.value = !!((p = t.value) != null && p.dataFormula);
|
|
935
935
|
}
|
|
936
|
-
const t = ee(void 0), i = ee(!1), b =
|
|
936
|
+
const t = ee(void 0), i = ee(!1), b = S(
|
|
937
937
|
() => a.options.find(
|
|
938
|
-
(
|
|
939
|
-
var
|
|
940
|
-
return
|
|
938
|
+
(_) => {
|
|
939
|
+
var p, o;
|
|
940
|
+
return _.schemaName === ((p = t.value) == null ? void 0 : p.schemaName) && _.name === ((o = t.value) == null ? void 0 : o.name);
|
|
941
941
|
}
|
|
942
942
|
) ?? {}
|
|
943
943
|
);
|
|
944
|
-
function
|
|
945
|
-
var
|
|
946
|
-
(
|
|
947
|
-
schemaName:
|
|
948
|
-
name:
|
|
949
|
-
dimensionOption:
|
|
944
|
+
function F(_) {
|
|
945
|
+
var p, o;
|
|
946
|
+
(_.schemaName !== ((p = t.value) == null ? void 0 : p.schemaName) || _.name !== ((o = t.value) == null ? void 0 : o.name)) && (t.value = {
|
|
947
|
+
schemaName: _.schemaName,
|
|
948
|
+
name: _.name,
|
|
949
|
+
dimensionOption: _.dimensionOptions[0],
|
|
950
950
|
aggregation: null,
|
|
951
|
-
type:
|
|
951
|
+
type: He.Asc
|
|
952
952
|
});
|
|
953
953
|
}
|
|
954
|
-
function
|
|
954
|
+
function T() {
|
|
955
955
|
if (!t.value) {
|
|
956
956
|
console.log("new sort is undefined");
|
|
957
957
|
return;
|
|
958
958
|
}
|
|
959
|
-
const
|
|
960
|
-
i.value || (t.value.dataFormula = void 0),
|
|
959
|
+
const _ = [...v.value.map((p) => p.value)];
|
|
960
|
+
i.value || (t.value.dataFormula = void 0), C.value !== void 0 ? _[C.value] = t.value : _.push(t.value), s.value = _, x.value = !1;
|
|
961
961
|
}
|
|
962
|
-
function
|
|
963
|
-
const
|
|
964
|
-
|
|
962
|
+
function f(_) {
|
|
963
|
+
const p = [...v.value.map((o) => o.value)];
|
|
964
|
+
p.splice(_, 1), s.value = p, x.value = !1;
|
|
965
965
|
}
|
|
966
|
-
function
|
|
967
|
-
const
|
|
968
|
-
return e(
|
|
966
|
+
function V(_) {
|
|
967
|
+
const p = `report.section.filter.${ke(_)}`;
|
|
968
|
+
return e(p) ? d(p) : ie(d, e, _, "field");
|
|
969
969
|
}
|
|
970
|
-
const
|
|
971
|
-
() => a.options.map((
|
|
972
|
-
label:
|
|
973
|
-
value:
|
|
970
|
+
const M = S(
|
|
971
|
+
() => a.options.map((_) => ({
|
|
972
|
+
label: _.labels.join(" "),
|
|
973
|
+
value: _
|
|
974
974
|
}))
|
|
975
975
|
);
|
|
976
|
-
return (
|
|
977
|
-
const o = $("FmCheckbox"), n = $("FmTextarea"),
|
|
978
|
-
return
|
|
979
|
-
r(
|
|
980
|
-
modelValue:
|
|
981
|
-
"onUpdate:modelValue":
|
|
982
|
-
title:
|
|
983
|
-
onConfirm:
|
|
976
|
+
return (_, p) => {
|
|
977
|
+
const o = $("FmCheckbox"), n = $("FmTextarea"), c = $("FmForm"), u = $("FmIcon"), m = $("FmButton"), y = $("FmListItem"), j = $("FmList"), Q = $("FmField");
|
|
978
|
+
return g(), A("div", Gl, [
|
|
979
|
+
r(Te, {
|
|
980
|
+
modelValue: x.value,
|
|
981
|
+
"onUpdate:modelValue": p[6] || (p[6] = (E) => x.value = E),
|
|
982
|
+
title: w.value,
|
|
983
|
+
onConfirm: T
|
|
984
984
|
}, {
|
|
985
985
|
content: R(() => [
|
|
986
|
-
r(
|
|
986
|
+
r(c, {
|
|
987
987
|
ref: "form",
|
|
988
988
|
class: "flex flex-col gap-2 w-[490px]"
|
|
989
989
|
}, {
|
|
990
990
|
default: R(() => {
|
|
991
|
-
var
|
|
991
|
+
var E, X, J, le;
|
|
992
992
|
return [
|
|
993
|
-
r(
|
|
993
|
+
r(me, {
|
|
994
994
|
"model-value": b.value,
|
|
995
|
-
items:
|
|
996
|
-
placeholder:
|
|
997
|
-
label:
|
|
998
|
-
"onUpdate:modelValue":
|
|
995
|
+
items: M.value,
|
|
996
|
+
placeholder: w.value,
|
|
997
|
+
label: w.value,
|
|
998
|
+
"onUpdate:modelValue": p[0] || (p[0] = (B) => F(B))
|
|
999
999
|
}, null, 8, ["model-value", "items", "placeholder", "label"]),
|
|
1000
|
-
t.value ? (
|
|
1001
|
-
(((
|
|
1000
|
+
t.value ? (g(), A(re, { key: 0 }, [
|
|
1001
|
+
(((E = b.value) == null ? void 0 : E.dimensionOptions) || []).length > 0 ? (g(), N(me, {
|
|
1002
1002
|
key: 0,
|
|
1003
1003
|
modelValue: t.value.dimensionOption,
|
|
1004
|
-
"onUpdate:modelValue":
|
|
1004
|
+
"onUpdate:modelValue": p[1] || (p[1] = (B) => t.value.dimensionOption = B),
|
|
1005
1005
|
items: ((X = b.value) == null ? void 0 : X.dimensionOptions.map((B) => ({
|
|
1006
|
-
label:
|
|
1006
|
+
label: V(B),
|
|
1007
1007
|
value: B
|
|
1008
1008
|
}))) ?? [],
|
|
1009
1009
|
placeholder: l(d)("report.section.sort.format"),
|
|
1010
1010
|
label: l(d)("report.section.sort.format")
|
|
1011
1011
|
}, null, 8, ["modelValue", "items", "placeholder", "label"])) : O("", !0),
|
|
1012
|
-
(((
|
|
1012
|
+
(((J = b.value) == null ? void 0 : J.aggregations) || []).length > 0 ? (g(), N(me, {
|
|
1013
1013
|
key: 1,
|
|
1014
1014
|
modelValue: t.value.aggregation,
|
|
1015
|
-
"onUpdate:modelValue":
|
|
1016
|
-
items: ((
|
|
1015
|
+
"onUpdate:modelValue": p[2] || (p[2] = (B) => t.value.aggregation = B),
|
|
1016
|
+
items: ((le = b.value) == null ? void 0 : le.aggregations.map((B) => ({
|
|
1017
1017
|
label: l(e)(`report.section.metric.aggregationType.${B}`) ? l(d)(`report.section.metric.aggregationType.${B}`) : B,
|
|
1018
1018
|
value: B
|
|
1019
1019
|
}))) ?? [],
|
|
1020
1020
|
label: l(d)("report.section.sort.aggregation"),
|
|
1021
1021
|
placeholder: l(d)("report.section.sort.aggregation")
|
|
1022
1022
|
}, null, 8, ["modelValue", "items", "label", "placeholder"])) : O("", !0),
|
|
1023
|
-
r(
|
|
1023
|
+
r(me, {
|
|
1024
1024
|
modelValue: t.value.type,
|
|
1025
|
-
"onUpdate:modelValue":
|
|
1026
|
-
items: Object.values(l(
|
|
1025
|
+
"onUpdate:modelValue": p[3] || (p[3] = (B) => t.value.type = B),
|
|
1026
|
+
items: Object.values(l(He)).map((B) => ({
|
|
1027
1027
|
label: l(e)(`report.section.sort.sortType.${B}`) ? l(d)(`report.section.sort.sortType.${B}`) : B,
|
|
1028
1028
|
value: B
|
|
1029
1029
|
})),
|
|
@@ -1032,14 +1032,14 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
1032
1032
|
}, null, 8, ["modelValue", "items", "placeholder", "label"]),
|
|
1033
1033
|
r(o, {
|
|
1034
1034
|
modelValue: i.value,
|
|
1035
|
-
"onUpdate:modelValue":
|
|
1035
|
+
"onUpdate:modelValue": p[4] || (p[4] = (B) => i.value = B),
|
|
1036
1036
|
label: l(d)("report.section.sort.advance"),
|
|
1037
1037
|
value: !0
|
|
1038
1038
|
}, null, 8, ["modelValue", "label"]),
|
|
1039
|
-
i.value ? (
|
|
1039
|
+
i.value ? (g(), N(n, {
|
|
1040
1040
|
key: 2,
|
|
1041
1041
|
modelValue: t.value.dataFormula,
|
|
1042
|
-
"onUpdate:modelValue":
|
|
1042
|
+
"onUpdate:modelValue": p[5] || (p[5] = (B) => t.value.dataFormula = B),
|
|
1043
1043
|
placeholder: l(d)("report.section.sort.dataFormula")
|
|
1044
1044
|
}, null, 8, ["modelValue", "placeholder"])) : O("", !0)
|
|
1045
1045
|
], 64)) : O("", !0)
|
|
@@ -1050,31 +1050,31 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
1050
1050
|
]),
|
|
1051
1051
|
_: 1
|
|
1052
1052
|
}, 8, ["modelValue", "title"]),
|
|
1053
|
-
|
|
1054
|
-
|
|
1055
|
-
|
|
1053
|
+
h("div", null, [
|
|
1054
|
+
h("p", Kl, P(w.value), 1),
|
|
1055
|
+
h("p", Ql, P(l(d)("report.section.sort.description")), 1)
|
|
1056
1056
|
]),
|
|
1057
|
-
r(
|
|
1057
|
+
r(j, null, {
|
|
1058
1058
|
default: R(() => [
|
|
1059
|
-
r(l(
|
|
1059
|
+
r(l(ze), {
|
|
1060
1060
|
list: s.value,
|
|
1061
1061
|
"item-key": "id",
|
|
1062
1062
|
class: "flex flex-col gap-2 w-full"
|
|
1063
1063
|
}, {
|
|
1064
|
-
item: R(({ element:
|
|
1064
|
+
item: R(({ element: E, index: X }) => [
|
|
1065
1065
|
r(y, {
|
|
1066
1066
|
class: "!cursor-grab border rounded-md border-neutral-300 h-[40px] !p-[8px]",
|
|
1067
|
-
onClick:
|
|
1067
|
+
onClick: ge((J) => k(v.value[X]), ["stop"])
|
|
1068
1068
|
}, {
|
|
1069
1069
|
default: R(() => [
|
|
1070
1070
|
r(u, { name: "drag_handle" }),
|
|
1071
|
-
|
|
1072
|
-
|
|
1071
|
+
h("p", Zl, P(v.value[X].label), 1),
|
|
1072
|
+
p[8] || (p[8] = h("div", { class: "grow" }, null, -1)),
|
|
1073
1073
|
r(m, {
|
|
1074
1074
|
icon: "close",
|
|
1075
1075
|
size: "md",
|
|
1076
1076
|
variant: "tertiary",
|
|
1077
|
-
onClick:
|
|
1077
|
+
onClick: ge((J) => f(X), ["stop"])
|
|
1078
1078
|
}, null, 8, ["onClick"])
|
|
1079
1079
|
]),
|
|
1080
1080
|
_: 2
|
|
@@ -1085,10 +1085,10 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
1085
1085
|
]),
|
|
1086
1086
|
_: 1
|
|
1087
1087
|
}),
|
|
1088
|
-
r(
|
|
1088
|
+
r(Q, {
|
|
1089
1089
|
class: "text-fm-color-typo-tertiary",
|
|
1090
|
-
onClick:
|
|
1091
|
-
|
|
1090
|
+
onClick: p[7] || (p[7] = () => {
|
|
1091
|
+
k();
|
|
1092
1092
|
})
|
|
1093
1093
|
}, {
|
|
1094
1094
|
default: R(() => [
|
|
@@ -1099,7 +1099,7 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
1099
1099
|
]);
|
|
1100
1100
|
};
|
|
1101
1101
|
}
|
|
1102
|
-
}),
|
|
1102
|
+
}), lo = { class: "fm-typo-en-body-lg-600" }, oo = { class: "fm-typo-en-body-sm-600 text-fm-color-neutral-gray-400" }, to = /* @__PURE__ */ ae({
|
|
1103
1103
|
__name: "LimitSection",
|
|
1104
1104
|
props: {
|
|
1105
1105
|
modelValue: { required: !0, default: null },
|
|
@@ -1107,28 +1107,28 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
1107
1107
|
},
|
|
1108
1108
|
emits: ["update:modelValue"],
|
|
1109
1109
|
setup(D) {
|
|
1110
|
-
const { t: d } =
|
|
1110
|
+
const { t: d } = se(), e = ce(D, "modelValue"), s = Oe((a) => {
|
|
1111
1111
|
a !== "" ? e.value = a : e.value = null;
|
|
1112
1112
|
}, 1e3);
|
|
1113
|
-
return (a,
|
|
1114
|
-
const
|
|
1115
|
-
return
|
|
1116
|
-
|
|
1117
|
-
|
|
1118
|
-
|
|
1113
|
+
return (a, w) => {
|
|
1114
|
+
const x = $("FmTextField");
|
|
1115
|
+
return g(), A(re, null, [
|
|
1116
|
+
h("div", null, [
|
|
1117
|
+
h("p", lo, P(l(d)("report.section.limit.title")), 1),
|
|
1118
|
+
h("p", oo, P(l(d)("report.section.limit.description")), 1)
|
|
1119
1119
|
]),
|
|
1120
|
-
r(
|
|
1120
|
+
r(x, {
|
|
1121
1121
|
"model-value": e.value,
|
|
1122
1122
|
inputmode: "numeric",
|
|
1123
1123
|
placeholder: l(d)("report.section.limit.placeholder"),
|
|
1124
|
-
"onUpdate:modelValue":
|
|
1124
|
+
"onUpdate:modelValue": w[0] || (w[0] = (v) => l(s)(v))
|
|
1125
1125
|
}, null, 8, ["model-value", "placeholder"])
|
|
1126
1126
|
], 64);
|
|
1127
1127
|
};
|
|
1128
1128
|
}
|
|
1129
|
-
}),
|
|
1129
|
+
}), ao = { class: "flex flex-col my-2 gap-8" }, no = { class: "fm-typo-en-body-lg-600" }, io = { class: "fm-typo-en-body-sm-600 text-fm-color-neutral-gray-400" }, so = { class: "fm-typo-en-body-lg-400 text-ellipsis overflow-hidden line-clamp-1" }, ro = /* @__PURE__ */ ae({
|
|
1130
1130
|
__name: "ConditionSection",
|
|
1131
|
-
props: /* @__PURE__ */
|
|
1131
|
+
props: /* @__PURE__ */ ue({
|
|
1132
1132
|
joinFieldOptions: {
|
|
1133
1133
|
type: Array,
|
|
1134
1134
|
default: () => []
|
|
@@ -1147,73 +1147,73 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
1147
1147
|
}),
|
|
1148
1148
|
emits: ["update:modelValue"],
|
|
1149
1149
|
setup(D) {
|
|
1150
|
-
const { t: d, te: e } =
|
|
1151
|
-
() => s.value.map((
|
|
1150
|
+
const { t: d, te: e } = se(), s = ce(D, "modelValue"), a = D, w = S(() => d(`report.section.condition.${a.label}`)), x = ee(!1), v = S(
|
|
1151
|
+
() => s.value.map((p, o) => {
|
|
1152
1152
|
var u, m;
|
|
1153
1153
|
const n = a.joinFieldOptions.find(
|
|
1154
1154
|
(y) => {
|
|
1155
|
-
var
|
|
1156
|
-
return y.schemaName === ((
|
|
1155
|
+
var j, Q;
|
|
1156
|
+
return y.schemaName === ((j = p.joinDimension) == null ? void 0 : j.schemaName) && y.name === ((Q = p.joinDimension) == null ? void 0 : Q.name);
|
|
1157
1157
|
}
|
|
1158
|
-
),
|
|
1159
|
-
(u =
|
|
1160
|
-
(m =
|
|
1158
|
+
), c = (n == null ? void 0 : n.labels) || [
|
|
1159
|
+
(u = p.joinDimension) == null ? void 0 : u.schemaName,
|
|
1160
|
+
(m = p.joinDimension) == null ? void 0 : m.name
|
|
1161
1161
|
];
|
|
1162
1162
|
return {
|
|
1163
1163
|
index: o,
|
|
1164
|
-
label:
|
|
1165
|
-
value:
|
|
1164
|
+
label: c.map((y) => ie(d, e, y, "other")).join(" "),
|
|
1165
|
+
value: p
|
|
1166
1166
|
};
|
|
1167
1167
|
})
|
|
1168
|
-
),
|
|
1169
|
-
function
|
|
1170
|
-
|
|
1168
|
+
), C = ee(s.value.length > 0 ? 0 : void 0);
|
|
1169
|
+
function k(p) {
|
|
1170
|
+
p ? (t.value = p != null && p.value ? JSON.parse(JSON.stringify(p.value)) : void 0, C.value = p == null ? void 0 : p.index) : (t.value = {
|
|
1171
1171
|
joinDimension: null,
|
|
1172
1172
|
operator: "",
|
|
1173
1173
|
mainDimensions: []
|
|
1174
|
-
},
|
|
1174
|
+
}, C.value = void 0), x.value = !0;
|
|
1175
1175
|
}
|
|
1176
|
-
const t = ee(void 0), i =
|
|
1176
|
+
const t = ee(void 0), i = S(
|
|
1177
1177
|
() => a.joinFieldOptions.find(
|
|
1178
|
-
(
|
|
1178
|
+
(p) => {
|
|
1179
1179
|
var o, n;
|
|
1180
|
-
return
|
|
1180
|
+
return p.schemaName === ((n = (o = t.value) == null ? void 0 : o.joinDimension) == null ? void 0 : n.schemaName) && p.name === t.value.joinDimension.name;
|
|
1181
1181
|
}
|
|
1182
1182
|
) ?? {}
|
|
1183
|
-
), b =
|
|
1183
|
+
), b = S(
|
|
1184
1184
|
() => {
|
|
1185
|
-
var
|
|
1186
|
-
return (((
|
|
1185
|
+
var p;
|
|
1186
|
+
return (((p = t.value) == null ? void 0 : p.mainDimensions) || []).map(
|
|
1187
1187
|
(o) => a.mainFieldOptions.find(
|
|
1188
1188
|
(n) => n.schemaName === (o == null ? void 0 : o.schemaName) && n.name === o.name
|
|
1189
1189
|
) ?? {}
|
|
1190
1190
|
);
|
|
1191
1191
|
}
|
|
1192
|
-
),
|
|
1193
|
-
() => a.joinFieldOptions.map((
|
|
1192
|
+
), F = S(
|
|
1193
|
+
() => a.joinFieldOptions.map((p) => ({ label: p.labels.join(" "), value: p }))
|
|
1194
1194
|
);
|
|
1195
|
-
function
|
|
1196
|
-
var o, n,
|
|
1197
|
-
t.value && (t.value &&
|
|
1195
|
+
function T(p) {
|
|
1196
|
+
var o, n, c, u;
|
|
1197
|
+
t.value && (t.value && p.schemaName !== ((n = (o = t.value) == null ? void 0 : o.joinDimension) == null ? void 0 : n.schemaName) || p.name !== ((u = (c = t.value) == null ? void 0 : c.joinDimension) == null ? void 0 : u.name)) && (t.value = {
|
|
1198
1198
|
...t.value,
|
|
1199
1199
|
joinDimension: {
|
|
1200
|
-
schemaName:
|
|
1201
|
-
name:
|
|
1202
|
-
option:
|
|
1203
|
-
label: `_${
|
|
1200
|
+
schemaName: p.schemaName,
|
|
1201
|
+
name: p.name,
|
|
1202
|
+
option: p.dimensionOptions[0],
|
|
1203
|
+
label: `_${p.label}`,
|
|
1204
1204
|
hide: !0
|
|
1205
1205
|
}
|
|
1206
|
-
},
|
|
1206
|
+
}, p.joinConditionOperators.includes(t.value.operator) || V(p.joinConditionOperators[0]));
|
|
1207
1207
|
}
|
|
1208
|
-
function
|
|
1209
|
-
var n,
|
|
1210
|
-
if (t.value && o >= 0 && (t.value &&
|
|
1208
|
+
function f(p, o) {
|
|
1209
|
+
var n, c, u, m;
|
|
1210
|
+
if (t.value && o >= 0 && (t.value && p.schemaName !== ((c = (n = t.value) == null ? void 0 : n.mainDimensions[o]) == null ? void 0 : c.schemaName) || p.name !== ((m = (u = t.value) == null ? void 0 : u.mainDimensions[o]) == null ? void 0 : m.name))) {
|
|
1211
1211
|
const y = [...t.value.mainDimensions];
|
|
1212
1212
|
y[o] = {
|
|
1213
|
-
schemaName:
|
|
1214
|
-
name:
|
|
1215
|
-
option:
|
|
1216
|
-
label:
|
|
1213
|
+
schemaName: p.schemaName,
|
|
1214
|
+
name: p.name,
|
|
1215
|
+
option: p.dimensionOptions[0],
|
|
1216
|
+
label: p.label,
|
|
1217
1217
|
hide: !0
|
|
1218
1218
|
}, t.value = {
|
|
1219
1219
|
...t.value,
|
|
@@ -1221,71 +1221,71 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
1221
1221
|
};
|
|
1222
1222
|
}
|
|
1223
1223
|
}
|
|
1224
|
-
function
|
|
1224
|
+
function V(p) {
|
|
1225
1225
|
if (t.value)
|
|
1226
|
-
switch (
|
|
1227
|
-
case
|
|
1226
|
+
switch (p) {
|
|
1227
|
+
case _l.Between:
|
|
1228
1228
|
t.value = {
|
|
1229
1229
|
...t.value,
|
|
1230
|
-
operator:
|
|
1230
|
+
operator: p,
|
|
1231
1231
|
mainDimensions: [null, null]
|
|
1232
1232
|
};
|
|
1233
1233
|
break;
|
|
1234
1234
|
default:
|
|
1235
1235
|
t.value = {
|
|
1236
1236
|
...t.value,
|
|
1237
|
-
operator:
|
|
1237
|
+
operator: p,
|
|
1238
1238
|
mainDimensions: [null]
|
|
1239
1239
|
};
|
|
1240
1240
|
break;
|
|
1241
1241
|
}
|
|
1242
1242
|
}
|
|
1243
|
-
function
|
|
1244
|
-
const
|
|
1243
|
+
function M() {
|
|
1244
|
+
const p = [...v.value.map((o) => o.value)];
|
|
1245
1245
|
t.value && (t.value.mainDimensions = t.value.mainDimensions.filter(
|
|
1246
1246
|
(o) => o !== "" && o != null
|
|
1247
|
-
),
|
|
1248
|
-
}
|
|
1249
|
-
function
|
|
1250
|
-
const o = [...
|
|
1251
|
-
o.splice(
|
|
1252
|
-
}
|
|
1253
|
-
return (
|
|
1254
|
-
const n = $("FmMenuDivider"),
|
|
1255
|
-
return
|
|
1256
|
-
r(
|
|
1257
|
-
modelValue:
|
|
1258
|
-
"onUpdate:modelValue": o[2] || (o[2] = (
|
|
1259
|
-
title:
|
|
1260
|
-
onConfirm:
|
|
1247
|
+
), C.value !== void 0 ? p[C.value] = t.value : p.push(t.value)), s.value = p, x.value = !1;
|
|
1248
|
+
}
|
|
1249
|
+
function _(p) {
|
|
1250
|
+
const o = [...v.value.map((n) => n.value)];
|
|
1251
|
+
o.splice(p, 1), s.value = o;
|
|
1252
|
+
}
|
|
1253
|
+
return (p, o) => {
|
|
1254
|
+
const n = $("FmMenuDivider"), c = $("FmForm"), u = $("FmIcon"), m = $("FmButton"), y = $("FmListItem"), j = $("FmList"), Q = $("FmField");
|
|
1255
|
+
return g(), A("div", ao, [
|
|
1256
|
+
r(Te, {
|
|
1257
|
+
modelValue: x.value,
|
|
1258
|
+
"onUpdate:modelValue": o[2] || (o[2] = (E) => x.value = E),
|
|
1259
|
+
title: w.value,
|
|
1260
|
+
onConfirm: M
|
|
1261
1261
|
}, {
|
|
1262
1262
|
content: R(() => [
|
|
1263
|
-
r(
|
|
1263
|
+
r(c, {
|
|
1264
1264
|
ref: "form",
|
|
1265
1265
|
class: "flex flex-col gap-2 w-[490px]"
|
|
1266
1266
|
}, {
|
|
1267
1267
|
default: R(() => {
|
|
1268
|
-
var
|
|
1268
|
+
var E, X, J, le, B;
|
|
1269
1269
|
return [
|
|
1270
|
-
r(
|
|
1270
|
+
r(me, {
|
|
1271
1271
|
label: l(d)("report.section.condition.joinDatasource"),
|
|
1272
1272
|
"model-value": i.value,
|
|
1273
|
-
items:
|
|
1273
|
+
items: F.value,
|
|
1274
1274
|
placeholder: l(d)("report.section.condition.joinDimension"),
|
|
1275
|
-
"onUpdate:modelValue": o[0] || (o[0] = (G) =>
|
|
1275
|
+
"onUpdate:modelValue": o[0] || (o[0] = (G) => T(G))
|
|
1276
1276
|
}, null, 8, ["label", "model-value", "items", "placeholder"]),
|
|
1277
1277
|
r(n),
|
|
1278
|
-
(
|
|
1278
|
+
(E = t.value) != null && E.joinDimension && (((X = i.value) == null ? void 0 : X.dimensionOptions) || []).length > 0 ? (g(), N(me, {
|
|
1279
1279
|
key: 0,
|
|
1280
1280
|
modelValue: t.value.joinDimension.option,
|
|
1281
1281
|
"onUpdate:modelValue": o[1] || (o[1] = (G) => t.value.joinDimension.option = G),
|
|
1282
1282
|
label: l(d)("report.section.condition.format"),
|
|
1283
|
-
items: ((
|
|
1284
|
-
label: l(e)(`report.section.filter.${l(
|
|
1283
|
+
items: ((J = i.value) == null ? void 0 : J.dimensionOptions.map((G) => ({
|
|
1284
|
+
label: l(e)(`report.section.filter.${l(ke)(G)}`) ? l(d)(`report.section.filter.${l(ke)(G)}`) : G,
|
|
1285
1285
|
value: G
|
|
1286
1286
|
}))) ?? []
|
|
1287
1287
|
}, null, 8, ["modelValue", "label", "items"])) : O("", !0),
|
|
1288
|
-
t.value && (((
|
|
1288
|
+
t.value && (((le = i.value) == null ? void 0 : le.joinConditionOperators) || []).length > 0 ? (g(), N(me, {
|
|
1289
1289
|
key: 1,
|
|
1290
1290
|
"model-value": t.value.operator,
|
|
1291
1291
|
label: l(d)("report.section.condition.operator"),
|
|
@@ -1293,30 +1293,30 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
1293
1293
|
label: l(d)("report.section.comparisonOperator." + G),
|
|
1294
1294
|
value: G
|
|
1295
1295
|
})) ?? [],
|
|
1296
|
-
"onUpdate:modelValue":
|
|
1296
|
+
"onUpdate:modelValue": V
|
|
1297
1297
|
}, null, 8, ["model-value", "label", "items"])) : O("", !0),
|
|
1298
|
-
(
|
|
1299
|
-
var
|
|
1300
|
-
return
|
|
1301
|
-
key:
|
|
1298
|
+
(g(!0), A(re, null, we(((B = t.value) == null ? void 0 : B.mainDimensions) || [], (G, te) => {
|
|
1299
|
+
var ve, W;
|
|
1300
|
+
return g(), A("div", {
|
|
1301
|
+
key: te,
|
|
1302
1302
|
class: "flex flex-col gap-2"
|
|
1303
1303
|
}, [
|
|
1304
|
-
r(
|
|
1305
|
-
"model-value": b.value[
|
|
1306
|
-
label: l(d)("report.section.condition.mainDatasource", { index:
|
|
1307
|
-
items: a.mainFieldOptions.map((
|
|
1308
|
-
label:
|
|
1309
|
-
value:
|
|
1304
|
+
r(me, {
|
|
1305
|
+
"model-value": b.value[te],
|
|
1306
|
+
label: l(d)("report.section.condition.mainDatasource", { index: te + 1 }),
|
|
1307
|
+
items: a.mainFieldOptions.map((de) => ({
|
|
1308
|
+
label: de.labels.join(" "),
|
|
1309
|
+
value: de
|
|
1310
1310
|
})),
|
|
1311
|
-
"onUpdate:modelValue": (
|
|
1311
|
+
"onUpdate:modelValue": (de) => f(de, te)
|
|
1312
1312
|
}, null, 8, ["model-value", "label", "items", "onUpdate:modelValue"]),
|
|
1313
|
-
G && (((
|
|
1313
|
+
G && (((ve = b.value[te]) == null ? void 0 : ve.dimensionOptions) || []).length > 0 && G ? (g(), N(me, {
|
|
1314
1314
|
key: 0,
|
|
1315
1315
|
modelValue: G.option,
|
|
1316
|
-
"onUpdate:modelValue": (
|
|
1317
|
-
items: (
|
|
1318
|
-
label: l(e)(`report.section.filter.${l(
|
|
1319
|
-
value:
|
|
1316
|
+
"onUpdate:modelValue": (de) => G.option = de,
|
|
1317
|
+
items: (W = b.value[te]) == null ? void 0 : W.dimensionOptions.map((de) => ({
|
|
1318
|
+
label: l(e)(`report.section.filter.${l(ke)(de)}`) ? l(d)(`report.section.filter.${l(ke)(de)}`) : de,
|
|
1319
|
+
value: de
|
|
1320
1320
|
}))
|
|
1321
1321
|
}, null, 8, ["modelValue", "onUpdate:modelValue", "items"])) : O("", !0),
|
|
1322
1322
|
r(n)
|
|
@@ -1329,34 +1329,34 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
1329
1329
|
]),
|
|
1330
1330
|
_: 1
|
|
1331
1331
|
}, 8, ["modelValue", "title"]),
|
|
1332
|
-
|
|
1333
|
-
|
|
1334
|
-
|
|
1332
|
+
h("div", null, [
|
|
1333
|
+
h("p", no, P(w.value), 1),
|
|
1334
|
+
h("p", io, P(l(d)("report.section.condition.description")), 1)
|
|
1335
1335
|
]),
|
|
1336
|
-
r(
|
|
1336
|
+
r(j, { class: "flex flex-col gap-2" }, {
|
|
1337
1337
|
default: R(() => [
|
|
1338
|
-
r(l(
|
|
1338
|
+
r(l(ze), {
|
|
1339
1339
|
list: s.value,
|
|
1340
|
-
"item-key": (
|
|
1341
|
-
var X,
|
|
1342
|
-
return `${(X =
|
|
1340
|
+
"item-key": (E) => {
|
|
1341
|
+
var X, J;
|
|
1342
|
+
return `${(X = E.joinDimension) == null ? void 0 : X.schemaName}:${(J = E.joinDimension) == null ? void 0 : J.name}`;
|
|
1343
1343
|
},
|
|
1344
1344
|
class: "flex flex-col gap-2 w-full"
|
|
1345
1345
|
}, {
|
|
1346
|
-
item: R(({ element:
|
|
1346
|
+
item: R(({ element: E, index: X }) => [
|
|
1347
1347
|
r(y, {
|
|
1348
1348
|
class: "!cursor-grab border rounded-md border-neutral-300 h-[40px] !p-[8px]",
|
|
1349
|
-
onClick:
|
|
1349
|
+
onClick: ge((J) => k(v.value[X]), ["stop"])
|
|
1350
1350
|
}, {
|
|
1351
1351
|
default: R(() => [
|
|
1352
1352
|
r(u, { name: "drag_handle" }),
|
|
1353
|
-
|
|
1354
|
-
o[4] || (o[4] =
|
|
1353
|
+
h("p", so, P(v.value[X].label), 1),
|
|
1354
|
+
o[4] || (o[4] = h("div", { class: "grow" }, null, -1)),
|
|
1355
1355
|
r(m, {
|
|
1356
1356
|
icon: "close",
|
|
1357
1357
|
size: "md",
|
|
1358
1358
|
variant: "tertiary",
|
|
1359
|
-
onClick:
|
|
1359
|
+
onClick: ge((J) => _(X), ["stop"])
|
|
1360
1360
|
}, null, 8, ["onClick"])
|
|
1361
1361
|
]),
|
|
1362
1362
|
_: 2
|
|
@@ -1367,9 +1367,9 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
1367
1367
|
]),
|
|
1368
1368
|
_: 1
|
|
1369
1369
|
}),
|
|
1370
|
-
r(
|
|
1370
|
+
r(Q, {
|
|
1371
1371
|
class: "text-fm-color-typo-tertiary cursor-pointer",
|
|
1372
|
-
onClick: o[3] || (o[3] = (
|
|
1372
|
+
onClick: o[3] || (o[3] = (E) => k())
|
|
1373
1373
|
}, {
|
|
1374
1374
|
default: R(() => [
|
|
1375
1375
|
Se(P(l(d)("report.section.condition.add")), 1)
|
|
@@ -1381,7 +1381,7 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
1381
1381
|
}
|
|
1382
1382
|
}), Qe = /* @__PURE__ */ ae({
|
|
1383
1383
|
__name: "Datasource",
|
|
1384
|
-
props: /* @__PURE__ */
|
|
1384
|
+
props: /* @__PURE__ */ ue({
|
|
1385
1385
|
label: {
|
|
1386
1386
|
type: String,
|
|
1387
1387
|
default: "Label"
|
|
@@ -1408,41 +1408,41 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
1408
1408
|
modelValue: { required: !0 },
|
|
1409
1409
|
modelModifiers: {}
|
|
1410
1410
|
}),
|
|
1411
|
-
emits: /* @__PURE__ */
|
|
1411
|
+
emits: /* @__PURE__ */ ue(["click-close"], ["update:modelValue"]),
|
|
1412
1412
|
setup(D, { emit: d }) {
|
|
1413
|
-
const { disableEditMode: e, resetStore: s } =
|
|
1413
|
+
const { disableEditMode: e, resetStore: s } = Ne(), a = ce(D, "modelValue");
|
|
1414
1414
|
ye(
|
|
1415
1415
|
[() => a.value.dimensions, () => a.value.metrics],
|
|
1416
1416
|
() => {
|
|
1417
|
-
const { rowIds: o, columnIds: n } =
|
|
1417
|
+
const { rowIds: o, columnIds: n } = je(a.value);
|
|
1418
1418
|
a.value.rowIds = o, a.value.columnIds = n;
|
|
1419
1419
|
},
|
|
1420
1420
|
{ deep: !0 }
|
|
1421
1421
|
);
|
|
1422
|
-
const
|
|
1423
|
-
|
|
1422
|
+
const w = D, x = d, { schemas: v } = Ve(ol());
|
|
1423
|
+
pl(() => {
|
|
1424
1424
|
e(), s();
|
|
1425
1425
|
});
|
|
1426
|
-
const { t:
|
|
1427
|
-
() => [
|
|
1428
|
-
),
|
|
1426
|
+
const { t: C, te: k, locale: t } = se(), i = S(() => !w.mainDatasourceConfig), b = S(
|
|
1427
|
+
() => [I.BarChart, I.LineChart, I.Scorecard].includes(w.config.type)
|
|
1428
|
+
), F = S(() => {
|
|
1429
1429
|
const o = [...a.value.dimensions].filter((n) => !n.hide);
|
|
1430
1430
|
return o.sort(
|
|
1431
|
-
(n,
|
|
1431
|
+
(n, c) => (a.value.rowIds || []).indexOf(xe(n)) - (a.value.rowIds || []).indexOf(xe(c))
|
|
1432
1432
|
), o;
|
|
1433
|
-
}),
|
|
1433
|
+
}), T = S(() => w.config.type === I.Scorecard), f = S(
|
|
1434
1434
|
() => {
|
|
1435
1435
|
var o;
|
|
1436
|
-
return (((o =
|
|
1437
|
-
(n,
|
|
1438
|
-
const u =
|
|
1436
|
+
return (((o = w.mainDatasourceConfig) == null ? void 0 : o.schemaNames) || []).reduce(
|
|
1437
|
+
(n, c) => {
|
|
1438
|
+
const u = v.value.find((m) => m.name === c);
|
|
1439
1439
|
return u && (n = [
|
|
1440
1440
|
...n,
|
|
1441
1441
|
...u.fields.map((m) => ({
|
|
1442
1442
|
...m,
|
|
1443
1443
|
labels: [
|
|
1444
|
-
|
|
1445
|
-
|
|
1444
|
+
ie(C, k, u.label, "schema"),
|
|
1445
|
+
ie(C, k, m.label || m.name, "other")
|
|
1446
1446
|
]
|
|
1447
1447
|
}))
|
|
1448
1448
|
]), n;
|
|
@@ -1450,65 +1450,65 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
1450
1450
|
[]
|
|
1451
1451
|
);
|
|
1452
1452
|
}
|
|
1453
|
-
),
|
|
1453
|
+
), V = S(
|
|
1454
1454
|
() => a.value.schemaNames.reduce((o, n) => {
|
|
1455
|
-
const
|
|
1456
|
-
return
|
|
1455
|
+
const c = v.value.find((u) => u.name === n);
|
|
1456
|
+
return c && (o = [
|
|
1457
1457
|
...o,
|
|
1458
|
-
...
|
|
1458
|
+
...c.fields.map((u) => ({
|
|
1459
1459
|
...u,
|
|
1460
1460
|
labels: [
|
|
1461
|
-
|
|
1462
|
-
|
|
1461
|
+
ie(C, k, c.label, "schema"),
|
|
1462
|
+
ie(C, k, u.label || u.name, "other")
|
|
1463
1463
|
]
|
|
1464
1464
|
}))
|
|
1465
1465
|
]), o;
|
|
1466
1466
|
}, [])
|
|
1467
|
-
),
|
|
1468
|
-
{ label:
|
|
1469
|
-
{ label:
|
|
1470
|
-
...[...
|
|
1471
|
-
label:
|
|
1467
|
+
), M = S(() => [
|
|
1468
|
+
{ label: C("report.section.datasource.none"), value: null },
|
|
1469
|
+
{ label: C("report.section.datasource.grandTotal"), value: 0 },
|
|
1470
|
+
...[...F.value].slice(0, F.value.length - 1).map((o, n) => ({
|
|
1471
|
+
label: ie(C, k, o.label, "other"),
|
|
1472
1472
|
value: n + 1
|
|
1473
1473
|
}))
|
|
1474
|
-
]),
|
|
1475
|
-
() => `rollup-${t.value}-${
|
|
1476
|
-
),
|
|
1474
|
+
]), _ = S(
|
|
1475
|
+
() => `rollup-${t.value}-${F.value.map((o) => xe(o)).join("|")}`
|
|
1476
|
+
), p = S(() => [
|
|
1477
1477
|
{
|
|
1478
|
-
label:
|
|
1478
|
+
label: C("report.section.datasource.none"),
|
|
1479
1479
|
value: null
|
|
1480
1480
|
},
|
|
1481
1481
|
...Object.keys(Je).map((o) => ({
|
|
1482
|
-
label:
|
|
1482
|
+
label: k(`report.section.datasource.periodType.${o}`) ? C(`report.section.datasource.periodType.${o}`) : o,
|
|
1483
1483
|
value: Je[o]
|
|
1484
1484
|
}))
|
|
1485
1485
|
]);
|
|
1486
1486
|
return (o, n) => {
|
|
1487
|
-
const
|
|
1488
|
-
return
|
|
1487
|
+
const c = $("FmButton"), u = $("FmSwitch"), m = $("FmSelect");
|
|
1488
|
+
return g(), N(Pe, null, {
|
|
1489
1489
|
header: R(() => [
|
|
1490
|
-
|
|
1491
|
-
n[19] || (n[19] =
|
|
1492
|
-
|
|
1490
|
+
h("p", null, P(w.label), 1),
|
|
1491
|
+
n[19] || (n[19] = h("div", { class: "grow" }, null, -1)),
|
|
1492
|
+
w.closeable ? (g(), N(c, {
|
|
1493
1493
|
key: 0,
|
|
1494
1494
|
icon: "close",
|
|
1495
1495
|
variant: "tertiary",
|
|
1496
1496
|
size: "md",
|
|
1497
|
-
onClick: n[0] || (n[0] =
|
|
1497
|
+
onClick: n[0] || (n[0] = ge((y) => x("click-close"), ["stop"]))
|
|
1498
1498
|
})) : O("", !0)
|
|
1499
1499
|
]),
|
|
1500
1500
|
content: R(() => [
|
|
1501
|
-
r(
|
|
1501
|
+
r(zl, {
|
|
1502
1502
|
modelValue: a.value,
|
|
1503
1503
|
"onUpdate:modelValue": n[1] || (n[1] = (y) => a.value = y),
|
|
1504
|
-
label: l(
|
|
1504
|
+
label: l(C)("report.section.schema.title")
|
|
1505
1505
|
}, null, 8, ["modelValue", "label"]),
|
|
1506
|
-
r(
|
|
1506
|
+
r(Ae, {
|
|
1507
1507
|
modelValue: a.value.dimensions,
|
|
1508
1508
|
"onUpdate:modelValue": n[2] || (n[2] = (y) => a.value.dimensions = y),
|
|
1509
|
-
options:
|
|
1509
|
+
options: V.value,
|
|
1510
1510
|
config: a.value,
|
|
1511
|
-
max:
|
|
1511
|
+
max: w.config.maxDimension,
|
|
1512
1512
|
"has-row-column": !0,
|
|
1513
1513
|
onConfig: n[3] || (n[3] = (y) => {
|
|
1514
1514
|
a.value = y;
|
|
@@ -1516,119 +1516,119 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
1516
1516
|
}, null, 8, ["modelValue", "options", "config", "max"]),
|
|
1517
1517
|
r(u, {
|
|
1518
1518
|
"label-placement": "right",
|
|
1519
|
-
label: l(
|
|
1519
|
+
label: l(C)("report.section.datasource.comparable"),
|
|
1520
1520
|
"model-value": a.value.isComparable ?? !1,
|
|
1521
1521
|
"onUpdate:modelValue": n[4] || (n[4] = (y) => {
|
|
1522
1522
|
a.value.isComparable = y;
|
|
1523
1523
|
})
|
|
1524
1524
|
}, null, 8, ["label", "model-value"]),
|
|
1525
|
-
b.value ? (
|
|
1525
|
+
b.value ? (g(), N(u, {
|
|
1526
1526
|
key: 0,
|
|
1527
1527
|
"label-placement": "right",
|
|
1528
|
-
label: l(
|
|
1528
|
+
label: l(C)("report.section.datasource.cumulative"),
|
|
1529
1529
|
"model-value": a.value.isCumulative ?? !1,
|
|
1530
1530
|
"onUpdate:modelValue": n[5] || (n[5] = (y) => {
|
|
1531
1531
|
a.value.isCumulative = y;
|
|
1532
1532
|
})
|
|
1533
1533
|
}, null, 8, ["label", "model-value"])) : O("", !0),
|
|
1534
|
-
|
|
1534
|
+
w.config.isDrillConfigurable && i.value ? (g(), N(u, {
|
|
1535
1535
|
key: 1,
|
|
1536
|
-
label: l(
|
|
1536
|
+
label: l(C)("report.section.datasource.drill"),
|
|
1537
1537
|
"label-placement": "right",
|
|
1538
1538
|
"model-value": a.value.isDrillable ?? !1,
|
|
1539
1539
|
"onUpdate:modelValue": n[6] || (n[6] = (y) => {
|
|
1540
1540
|
a.value.isDrillable = y;
|
|
1541
1541
|
})
|
|
1542
1542
|
}, null, 8, ["label", "model-value"])) : O("", !0),
|
|
1543
|
-
i.value ? (
|
|
1543
|
+
i.value ? (g(), N(u, {
|
|
1544
1544
|
key: 2,
|
|
1545
1545
|
modelValue: a.value.isBlend,
|
|
1546
1546
|
"onUpdate:modelValue": n[7] || (n[7] = (y) => a.value.isBlend = y),
|
|
1547
|
-
label: l(
|
|
1547
|
+
label: l(C)("report.section.datasource.blend"),
|
|
1548
1548
|
"label-placement": "right"
|
|
1549
1549
|
}, null, 8, ["modelValue", "label"])) : O("", !0),
|
|
1550
|
-
|
|
1551
|
-
key:
|
|
1550
|
+
w.config.canRollup && i.value ? (g(), N(m, {
|
|
1551
|
+
key: _.value,
|
|
1552
1552
|
modelValue: a.value.rollup,
|
|
1553
1553
|
"onUpdate:modelValue": n[8] || (n[8] = (y) => a.value.rollup = y),
|
|
1554
|
-
label: l(
|
|
1555
|
-
items:
|
|
1554
|
+
label: l(C)("report.section.datasource.subTotal"),
|
|
1555
|
+
items: M.value
|
|
1556
1556
|
}, null, 8, ["modelValue", "label", "items"])) : O("", !0),
|
|
1557
|
-
i.value ? O("", !0) : (
|
|
1557
|
+
i.value ? O("", !0) : (g(), N(m, {
|
|
1558
1558
|
key: `periodType-${l(t)}`,
|
|
1559
1559
|
modelValue: a.value.periodType,
|
|
1560
1560
|
"onUpdate:modelValue": n[9] || (n[9] = (y) => a.value.periodType = y),
|
|
1561
|
-
label: l(
|
|
1562
|
-
items:
|
|
1561
|
+
label: l(C)("report.section.datasource.periodType.label"),
|
|
1562
|
+
items: p.value
|
|
1563
1563
|
}, null, 8, ["modelValue", "label", "items"])),
|
|
1564
|
-
|
|
1564
|
+
w.config.canTranspose && i.value ? (g(), N(u, {
|
|
1565
1565
|
key: 5,
|
|
1566
1566
|
modelValue: a.value.isTransposed,
|
|
1567
1567
|
"onUpdate:modelValue": n[10] || (n[10] = (y) => a.value.isTransposed = y),
|
|
1568
|
-
label: l(
|
|
1568
|
+
label: l(C)("report.section.datasource.transpose"),
|
|
1569
1569
|
"label-placement": "right"
|
|
1570
1570
|
}, null, 8, ["modelValue", "label"])) : O("", !0),
|
|
1571
|
-
|
|
1571
|
+
w.config.hasBreakdownDimension ? (g(), N(Ae, {
|
|
1572
1572
|
key: 6,
|
|
1573
1573
|
"model-value": a.value.breakdownDimension ? [a.value.breakdownDimension] : [],
|
|
1574
1574
|
label: "breakdownDimension",
|
|
1575
1575
|
max: 1,
|
|
1576
|
-
options:
|
|
1576
|
+
options: V.value,
|
|
1577
1577
|
"onUpdate:modelValue": n[11] || (n[11] = (y) => {
|
|
1578
1578
|
a.value.breakdownDimension = y[0];
|
|
1579
1579
|
})
|
|
1580
1580
|
}, null, 8, ["model-value", "options"])) : O("", !0),
|
|
1581
|
-
|
|
1581
|
+
T.value ? (g(), N(Ae, {
|
|
1582
1582
|
key: 7,
|
|
1583
1583
|
"model-value": a.value.sparklineDimension ? [a.value.sparklineDimension] : [],
|
|
1584
1584
|
label: "sparklineDimension",
|
|
1585
1585
|
max: 1,
|
|
1586
|
-
options:
|
|
1586
|
+
options: V.value,
|
|
1587
1587
|
"onUpdate:modelValue": n[12] || (n[12] = (y) => {
|
|
1588
1588
|
a.value.sparklineDimension = y[0];
|
|
1589
1589
|
})
|
|
1590
1590
|
}, null, 8, ["model-value", "options"])) : O("", !0),
|
|
1591
|
-
r(
|
|
1591
|
+
r(Jl, {
|
|
1592
1592
|
modelValue: a.value.metrics,
|
|
1593
1593
|
"onUpdate:modelValue": n[13] || (n[13] = (y) => a.value.metrics = y),
|
|
1594
|
-
options:
|
|
1595
|
-
max:
|
|
1594
|
+
options: V.value,
|
|
1595
|
+
max: w.config.maxMetric,
|
|
1596
1596
|
config: a.value,
|
|
1597
|
-
"has-row-column":
|
|
1598
|
-
"has-xy":
|
|
1597
|
+
"has-row-column": w.config.type === l(I).Table,
|
|
1598
|
+
"has-xy": w.config.hasXy,
|
|
1599
1599
|
onConfig: n[14] || (n[14] = (y) => {
|
|
1600
1600
|
a.value = y;
|
|
1601
1601
|
})
|
|
1602
1602
|
}, null, 8, ["modelValue", "options", "max", "config", "has-row-column", "has-xy"]),
|
|
1603
|
-
r(
|
|
1603
|
+
r(wl, {
|
|
1604
1604
|
modelValue: a.value.filters,
|
|
1605
1605
|
"onUpdate:modelValue": n[15] || (n[15] = (y) => a.value.filters = y),
|
|
1606
|
-
options:
|
|
1606
|
+
options: V.value
|
|
1607
1607
|
}, null, 8, ["modelValue", "options"]),
|
|
1608
|
-
r(
|
|
1608
|
+
r(eo, {
|
|
1609
1609
|
modelValue: a.value.sorts,
|
|
1610
1610
|
"onUpdate:modelValue": n[16] || (n[16] = (y) => a.value.sorts = y),
|
|
1611
|
-
options:
|
|
1611
|
+
options: V.value
|
|
1612
1612
|
}, null, 8, ["modelValue", "options"]),
|
|
1613
|
-
r(
|
|
1613
|
+
r(to, {
|
|
1614
1614
|
modelValue: a.value.limit,
|
|
1615
1615
|
"onUpdate:modelValue": n[17] || (n[17] = (y) => a.value.limit = y)
|
|
1616
1616
|
}, null, 8, ["modelValue"]),
|
|
1617
|
-
a.value.conditions ? (
|
|
1617
|
+
a.value.conditions ? (g(), N(ro, {
|
|
1618
1618
|
key: 8,
|
|
1619
1619
|
modelValue: a.value.conditions,
|
|
1620
1620
|
"onUpdate:modelValue": n[18] || (n[18] = (y) => a.value.conditions = y),
|
|
1621
|
-
"join-field-options":
|
|
1622
|
-
"main-field-options":
|
|
1621
|
+
"join-field-options": V.value,
|
|
1622
|
+
"main-field-options": f.value
|
|
1623
1623
|
}, null, 8, ["modelValue", "join-field-options", "main-field-options"])) : O("", !0)
|
|
1624
1624
|
]),
|
|
1625
1625
|
_: 1
|
|
1626
1626
|
});
|
|
1627
1627
|
};
|
|
1628
1628
|
}
|
|
1629
|
-
}),
|
|
1629
|
+
}), uo = { class: "fm-typo-en-title-sm-600" }, Ee = /* @__PURE__ */ ae({
|
|
1630
1630
|
__name: "TileEditorTabHeader",
|
|
1631
|
-
props: /* @__PURE__ */
|
|
1631
|
+
props: /* @__PURE__ */ ue({
|
|
1632
1632
|
icon: {
|
|
1633
1633
|
type: String,
|
|
1634
1634
|
required: !0
|
|
@@ -1639,22 +1639,22 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
1639
1639
|
}),
|
|
1640
1640
|
emits: ["update:modelValue"],
|
|
1641
1641
|
setup(D) {
|
|
1642
|
-
const { t: d } =
|
|
1643
|
-
return (a,
|
|
1644
|
-
const
|
|
1645
|
-
return
|
|
1642
|
+
const { t: d } = se(), e = ce(D, "modelValue"), s = D;
|
|
1643
|
+
return (a, w) => {
|
|
1644
|
+
const x = $("FmIcon");
|
|
1645
|
+
return g(), A("div", {
|
|
1646
1646
|
class: "px-6 py-16 flex items-center gap-2 bg-fm-color-neutral-white border cursor-pointer",
|
|
1647
|
-
onClick:
|
|
1647
|
+
onClick: w[0] || (w[0] = (v) => e.value = !e.value)
|
|
1648
1648
|
}, [
|
|
1649
|
-
|
|
1650
|
-
|
|
1651
|
-
r(
|
|
1649
|
+
h("p", uo, P(l(d)("report.tile.setting")), 1),
|
|
1650
|
+
w[1] || (w[1] = h("div", { class: "grow" }, null, -1)),
|
|
1651
|
+
r(x, {
|
|
1652
1652
|
name: s.icon
|
|
1653
1653
|
}, null, 8, ["name"])
|
|
1654
1654
|
]);
|
|
1655
1655
|
};
|
|
1656
1656
|
}
|
|
1657
|
-
}),
|
|
1657
|
+
}), mo = /* @__PURE__ */ ae({
|
|
1658
1658
|
__name: "TileEditorTabDesktop",
|
|
1659
1659
|
props: {
|
|
1660
1660
|
modelValue: { required: !0, default: !1 },
|
|
@@ -1662,9 +1662,9 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
1662
1662
|
},
|
|
1663
1663
|
emits: ["update:modelValue"],
|
|
1664
1664
|
setup(D) {
|
|
1665
|
-
const d =
|
|
1666
|
-
return (e, s) => (
|
|
1667
|
-
r(
|
|
1665
|
+
const d = ce(D, "modelValue");
|
|
1666
|
+
return (e, s) => (g(), A(re, null, [
|
|
1667
|
+
r(Ee, {
|
|
1668
1668
|
modelValue: d.value,
|
|
1669
1669
|
"onUpdate:modelValue": s[0] || (s[0] = (a) => d.value = a),
|
|
1670
1670
|
icon: "keyboard_double_arrow_left"
|
|
@@ -1672,7 +1672,7 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
1672
1672
|
el(e.$slots, "default")
|
|
1673
1673
|
], 64));
|
|
1674
1674
|
}
|
|
1675
|
-
}),
|
|
1675
|
+
}), co = { class: "fixed bottom-0 w-full" }, po = /* @__PURE__ */ ae({
|
|
1676
1676
|
__name: "TileEditorTabMobile",
|
|
1677
1677
|
props: {
|
|
1678
1678
|
modelValue: { required: !0, default: !1 },
|
|
@@ -1680,24 +1680,24 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
1680
1680
|
},
|
|
1681
1681
|
emits: ["update:modelValue"],
|
|
1682
1682
|
setup(D) {
|
|
1683
|
-
const d =
|
|
1683
|
+
const d = ce(D, "modelValue");
|
|
1684
1684
|
return (e, s) => {
|
|
1685
1685
|
const a = $("FmTopSheet");
|
|
1686
|
-
return
|
|
1687
|
-
r(
|
|
1686
|
+
return g(), A("div", co, [
|
|
1687
|
+
r(Ee, {
|
|
1688
1688
|
modelValue: d.value,
|
|
1689
|
-
"onUpdate:modelValue": s[0] || (s[0] = (
|
|
1689
|
+
"onUpdate:modelValue": s[0] || (s[0] = (w) => d.value = w),
|
|
1690
1690
|
icon: "keyboard_double_arrow_up"
|
|
1691
1691
|
}, null, 8, ["modelValue"]),
|
|
1692
1692
|
r(a, {
|
|
1693
1693
|
modelValue: d.value,
|
|
1694
|
-
"onUpdate:modelValue": s[2] || (s[2] = (
|
|
1694
|
+
"onUpdate:modelValue": s[2] || (s[2] = (w) => d.value = w),
|
|
1695
1695
|
"fullscreen-size": "sm"
|
|
1696
1696
|
}, {
|
|
1697
1697
|
default: R(() => [
|
|
1698
|
-
r(
|
|
1698
|
+
r(Ee, {
|
|
1699
1699
|
modelValue: d.value,
|
|
1700
|
-
"onUpdate:modelValue": s[1] || (s[1] = (
|
|
1700
|
+
"onUpdate:modelValue": s[1] || (s[1] = (w) => d.value = w),
|
|
1701
1701
|
icon: "keyboard_double_arrow_down"
|
|
1702
1702
|
}, null, 8, ["modelValue"]),
|
|
1703
1703
|
d.value ? el(e.$slots, "default", { key: 0 }) : O("", !0)
|
|
@@ -1707,100 +1707,100 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
1707
1707
|
]);
|
|
1708
1708
|
};
|
|
1709
1709
|
}
|
|
1710
|
-
}),
|
|
1710
|
+
}), fo = { class: "flex gap-16" }, vo = { class: "flex flex-col gap-8 max-w-[120px]" }, go = { class: "fm-typo-en-body-lg-600" }, bo = { class: "flex flex-col gap-16" }, yo = { class: "fm-typo-en-body-lg-600" }, ho = { class: "flex flex-row gap-8" }, wo = /* @__PURE__ */ ae({
|
|
1711
1711
|
__name: "TitleSection",
|
|
1712
1712
|
props: {
|
|
1713
1713
|
model: {}
|
|
1714
1714
|
},
|
|
1715
1715
|
emits: ["update:model"],
|
|
1716
1716
|
setup(D, { emit: d }) {
|
|
1717
|
-
const e = D, s = d, { t: a } =
|
|
1717
|
+
const e = D, s = d, { t: a } = se(), w = S({
|
|
1718
1718
|
get: () => e.model.showTitle ?? !1,
|
|
1719
1719
|
set: (t) => s("update:model", { ...e.model, showTitle: t })
|
|
1720
|
-
}),
|
|
1720
|
+
}), x = S({
|
|
1721
1721
|
get: () => e.model.titleFontSize ?? 14,
|
|
1722
1722
|
set: (t) => s("update:model", { ...e.model, titleFontSize: Math.min(Number(t), 24) })
|
|
1723
|
-
}),
|
|
1723
|
+
}), v = S({
|
|
1724
1724
|
get: () => e.model.titleBold ?? !1,
|
|
1725
1725
|
set: (t) => s("update:model", { ...e.model, titleBold: t })
|
|
1726
|
-
}),
|
|
1726
|
+
}), C = S({
|
|
1727
1727
|
get: () => e.model.titleItalic ?? !1,
|
|
1728
1728
|
set: (t) => s("update:model", { ...e.model, titleItalic: t })
|
|
1729
|
-
}),
|
|
1729
|
+
}), k = S({
|
|
1730
1730
|
get: () => e.model.titleUnderline ?? !1,
|
|
1731
1731
|
set: (t) => s("update:model", { ...e.model, titleUnderline: t })
|
|
1732
1732
|
});
|
|
1733
1733
|
return (t, i) => {
|
|
1734
|
-
const b = $("FmStepperField"),
|
|
1735
|
-
return
|
|
1736
|
-
|
|
1737
|
-
|
|
1738
|
-
|
|
1739
|
-
|
|
1734
|
+
const b = $("FmStepperField"), F = $("FmButton"), T = $("FmSwitch");
|
|
1735
|
+
return g(), A(re, null, [
|
|
1736
|
+
h("div", null, [
|
|
1737
|
+
h("div", fo, [
|
|
1738
|
+
h("div", vo, [
|
|
1739
|
+
h("p", go, P(l(a)("report.section.datasource.title.titleFontSize")), 1),
|
|
1740
1740
|
r(b, {
|
|
1741
|
-
modelValue:
|
|
1742
|
-
"onUpdate:modelValue": i[0] || (i[0] = (
|
|
1741
|
+
modelValue: x.value,
|
|
1742
|
+
"onUpdate:modelValue": i[0] || (i[0] = (f) => x.value = f),
|
|
1743
1743
|
max: 24,
|
|
1744
1744
|
min: 1,
|
|
1745
1745
|
type: "number"
|
|
1746
1746
|
}, null, 8, ["modelValue"])
|
|
1747
1747
|
]),
|
|
1748
|
-
|
|
1749
|
-
|
|
1750
|
-
|
|
1751
|
-
r(
|
|
1748
|
+
h("div", bo, [
|
|
1749
|
+
h("p", yo, P(l(a)("report.section.datasource.title.textStyleFormat")), 1),
|
|
1750
|
+
h("div", ho, [
|
|
1751
|
+
r(F, {
|
|
1752
1752
|
"append-icon": "format_bold",
|
|
1753
1753
|
"model-value": t.model.titleBold ?? !1,
|
|
1754
1754
|
variant: "tertiary",
|
|
1755
1755
|
"icon-color": t.model.titleBold ? "neutral-gray-400" : "neutral-gray-300",
|
|
1756
1756
|
"bg-color": t.model.titleBold ? "neutral-gray-100" : "neutral-white",
|
|
1757
1757
|
class: "rounded-sm",
|
|
1758
|
-
onClick: i[1] || (i[1] = (
|
|
1758
|
+
onClick: i[1] || (i[1] = (f) => v.value = !v.value)
|
|
1759
1759
|
}, null, 8, ["model-value", "icon-color", "bg-color"]),
|
|
1760
|
-
r(
|
|
1760
|
+
r(F, {
|
|
1761
1761
|
"append-icon": "format_italic",
|
|
1762
1762
|
"model-value": t.model.titleItalic ?? !1,
|
|
1763
1763
|
"icon-color": t.model.titleItalic ? "neutral-gray-400" : "neutral-gray-300",
|
|
1764
1764
|
"bg-color": t.model.titleItalic ? "neutral-gray-100" : "neutral-white",
|
|
1765
1765
|
class: "rounded-sm",
|
|
1766
|
-
onClick: i[2] || (i[2] = (
|
|
1766
|
+
onClick: i[2] || (i[2] = (f) => C.value = !C.value)
|
|
1767
1767
|
}, null, 8, ["model-value", "icon-color", "bg-color"]),
|
|
1768
|
-
r(
|
|
1768
|
+
r(F, {
|
|
1769
1769
|
"append-icon": "format_underlined",
|
|
1770
1770
|
"model-value": t.model.titleUnderline ?? !1,
|
|
1771
1771
|
"icon-color": t.model.titleUnderline ? "neutral-gray-400" : "neutral-gray-300",
|
|
1772
1772
|
"bg-color": t.model.titleUnderline ? "neutral-gray-100" : "neutral-white",
|
|
1773
1773
|
class: "rounded-sm",
|
|
1774
|
-
onClick: i[3] || (i[3] = (
|
|
1774
|
+
onClick: i[3] || (i[3] = (f) => k.value = !k.value)
|
|
1775
1775
|
}, null, 8, ["model-value", "icon-color", "bg-color"])
|
|
1776
1776
|
])
|
|
1777
1777
|
])
|
|
1778
1778
|
])
|
|
1779
1779
|
]),
|
|
1780
|
-
r(
|
|
1781
|
-
modelValue:
|
|
1782
|
-
"onUpdate:modelValue": i[4] || (i[4] = (
|
|
1780
|
+
r(T, {
|
|
1781
|
+
modelValue: w.value,
|
|
1782
|
+
"onUpdate:modelValue": i[4] || (i[4] = (f) => w.value = f),
|
|
1783
1783
|
label: l(a)("report.section.datasource.title.showTitle"),
|
|
1784
1784
|
"label-placement": "right"
|
|
1785
1785
|
}, null, 8, ["modelValue", "label"])
|
|
1786
1786
|
], 64);
|
|
1787
1787
|
};
|
|
1788
1788
|
}
|
|
1789
|
-
}),
|
|
1789
|
+
}), Co = { class: "flex flex-col gap-8" }, Vo = { class: "text-fm-color-typo-primary fm-typo-en-body-lg-600" }, xo = { class: "flex flex-row gap-2" }, Fo = {
|
|
1790
1790
|
key: 0,
|
|
1791
1791
|
class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary"
|
|
1792
|
-
},
|
|
1792
|
+
}, ko = /* @__PURE__ */ ae({
|
|
1793
1793
|
__name: "TableResizeSection",
|
|
1794
1794
|
props: {
|
|
1795
1795
|
layout: {}
|
|
1796
1796
|
},
|
|
1797
1797
|
emits: ["update:layout"],
|
|
1798
1798
|
setup(D, { emit: d }) {
|
|
1799
|
-
const { t: e } =
|
|
1800
|
-
|
|
1799
|
+
const { t: e } = se(), s = D, a = d, { isEditing: w, colWidths: x, rowHeight: v } = Ve(Ne()), { enableCellResizing: C, cancelResizingChanges: k, resetStore: t, disableEditMode: i } = Ne();
|
|
1800
|
+
S(
|
|
1801
1801
|
() => {
|
|
1802
|
-
var
|
|
1803
|
-
return (((
|
|
1802
|
+
var F, T, f;
|
|
1803
|
+
return (((T = (F = s.layout) == null ? void 0 : F.colWidths) == null ? void 0 : T.length) ?? 0) > 0 || x.value.length > 0 || (((f = s.layout) == null ? void 0 : f.rowHeight) ?? 0) > 0 || v.value > 0;
|
|
1804
1804
|
}
|
|
1805
1805
|
);
|
|
1806
1806
|
function b() {
|
|
@@ -1809,46 +1809,46 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
1809
1809
|
rowHeight: void 0,
|
|
1810
1810
|
colWidths: void 0
|
|
1811
1811
|
});
|
|
1812
|
-
const
|
|
1813
|
-
if (
|
|
1814
|
-
|
|
1815
|
-
const
|
|
1816
|
-
|
|
1817
|
-
|
|
1818
|
-
}),
|
|
1819
|
-
|
|
1820
|
-
}),
|
|
1821
|
-
|
|
1812
|
+
const F = document.querySelector("table");
|
|
1813
|
+
if (F) {
|
|
1814
|
+
F.classList.remove("table-fixed"), F.classList.add("table-auto"), F.style.width = "";
|
|
1815
|
+
const T = F.querySelectorAll("th"), f = F.querySelectorAll("td"), V = F.querySelectorAll("tr");
|
|
1816
|
+
T.forEach((M) => {
|
|
1817
|
+
M.style.width = "";
|
|
1818
|
+
}), f.forEach((M) => {
|
|
1819
|
+
M.style.width = "";
|
|
1820
|
+
}), V.forEach((M) => {
|
|
1821
|
+
M.style.height = "";
|
|
1822
1822
|
});
|
|
1823
1823
|
}
|
|
1824
1824
|
}
|
|
1825
1825
|
return We(() => {
|
|
1826
|
-
var
|
|
1827
|
-
((
|
|
1828
|
-
}), (
|
|
1829
|
-
const
|
|
1830
|
-
return
|
|
1831
|
-
|
|
1832
|
-
|
|
1833
|
-
l(
|
|
1826
|
+
var F, T;
|
|
1827
|
+
((F = s.layout) == null ? void 0 : F.rowHeight) !== void 0 && (v.value = s.layout.rowHeight), (T = s.layout) != null && T.colWidths && (x.value = [...s.layout.colWidths]);
|
|
1828
|
+
}), (F, T) => {
|
|
1829
|
+
const f = $("FmButton");
|
|
1830
|
+
return g(), A("div", Co, [
|
|
1831
|
+
h("p", Vo, P(l(e)("report.section.datasource.tableLayout")), 1),
|
|
1832
|
+
h("div", xo, [
|
|
1833
|
+
l(w) ? O("", !0) : (g(), N(f, {
|
|
1834
1834
|
key: 0,
|
|
1835
1835
|
label: l(e)("report.section.datasource.resizeTable"),
|
|
1836
1836
|
variant: "secondary",
|
|
1837
1837
|
icon: "resize",
|
|
1838
1838
|
"icon-position": "prepend",
|
|
1839
1839
|
class: "[&_.label]:line-clamp-none w-full",
|
|
1840
|
-
onClick: l(
|
|
1840
|
+
onClick: l(C)
|
|
1841
1841
|
}, null, 8, ["label", "onClick"])),
|
|
1842
|
-
l(
|
|
1842
|
+
l(w) ? (g(), N(f, {
|
|
1843
1843
|
key: 1,
|
|
1844
1844
|
label: l(e)("report.common.cancel"),
|
|
1845
1845
|
variant: "primary",
|
|
1846
1846
|
icon: "close",
|
|
1847
1847
|
"icon-position": "prepend",
|
|
1848
1848
|
class: "[&_.label]:line-clamp-none w-full",
|
|
1849
|
-
onClick: l(
|
|
1849
|
+
onClick: l(k)
|
|
1850
1850
|
}, null, 8, ["label", "onClick"])) : O("", !0),
|
|
1851
|
-
r(
|
|
1851
|
+
r(f, {
|
|
1852
1852
|
label: l(e)("report.section.datasource.resetSize"),
|
|
1853
1853
|
variant: "secondary",
|
|
1854
1854
|
icon: "restore",
|
|
@@ -1857,13 +1857,13 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
1857
1857
|
onClick: b
|
|
1858
1858
|
}, null, 8, ["label"])
|
|
1859
1859
|
]),
|
|
1860
|
-
l(
|
|
1860
|
+
l(w) ? (g(), A("p", Fo, P(l(e)("report.section.datasource.resizeTableHelper")), 1)) : O("", !0)
|
|
1861
1861
|
]);
|
|
1862
1862
|
};
|
|
1863
1863
|
}
|
|
1864
|
-
}),
|
|
1864
|
+
}), _o = { class: "flex gap-16 justify-center items-center" }, So = { class: "fm-typo-en-title-sm-600" }, To = { class: "fm-typo-en-body-lg-600" }, $o = { class: "fm-typo-en-body-md-400 text-fm-color-typo-tertiary" }, Do = { class: "h-[40x]" }, Ze = "YYYY-MM-DD", ul = /* @__PURE__ */ ae({
|
|
1865
1865
|
__name: "TileEditorTab",
|
|
1866
|
-
props: /* @__PURE__ */
|
|
1866
|
+
props: /* @__PURE__ */ ue({
|
|
1867
1867
|
hideConfiguration: {
|
|
1868
1868
|
type: Boolean,
|
|
1869
1869
|
default: !1
|
|
@@ -1874,225 +1874,225 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
1874
1874
|
},
|
|
1875
1875
|
modelModifiers: {}
|
|
1876
1876
|
}),
|
|
1877
|
-
emits: /* @__PURE__ */
|
|
1877
|
+
emits: /* @__PURE__ */ ue(["hideConfiguration"], ["update:modelValue"]),
|
|
1878
1878
|
setup(D, { emit: d }) {
|
|
1879
|
-
var n,
|
|
1880
|
-
const e = il(), { dateRange: s, timezone: a } = Ve(e),
|
|
1879
|
+
var n, c;
|
|
1880
|
+
const e = il(), { dateRange: s, timezone: a } = Ve(e), w = {
|
|
1881
1881
|
startDate: s.value.startDate,
|
|
1882
1882
|
endDate: s.value.endDate
|
|
1883
|
-
},
|
|
1884
|
-
startDate: (n =
|
|
1885
|
-
endDate: (
|
|
1883
|
+
}, x = ee({
|
|
1884
|
+
startDate: (n = Le(s.value.startDate)) == null ? void 0 : n.tz(a.value).format(Ze),
|
|
1885
|
+
endDate: (c = Le(s.value.endDate)) == null ? void 0 : c.tz(a.value).format(Ze)
|
|
1886
1886
|
});
|
|
1887
1887
|
ye(
|
|
1888
|
-
|
|
1888
|
+
x,
|
|
1889
1889
|
() => {
|
|
1890
|
-
|
|
1890
|
+
x.value.endDate || (x.value.endDate = x.value.startDate);
|
|
1891
1891
|
const u = {
|
|
1892
|
-
startDate:
|
|
1893
|
-
endDate:
|
|
1892
|
+
startDate: Le.tz(x.value.startDate, a.value).startOf("day").utc().toISOString(),
|
|
1893
|
+
endDate: Le.tz(x.value.endDate, a.value).endOf("day").utc().toISOString()
|
|
1894
1894
|
};
|
|
1895
1895
|
s.value = u;
|
|
1896
1896
|
},
|
|
1897
1897
|
{ deep: !0 }
|
|
1898
|
-
),
|
|
1899
|
-
s.value = { ...
|
|
1898
|
+
), fl(() => {
|
|
1899
|
+
s.value = { ...w };
|
|
1900
1900
|
});
|
|
1901
|
-
const
|
|
1902
|
-
function
|
|
1903
|
-
|
|
1904
|
-
}
|
|
1905
|
-
function
|
|
1906
|
-
const u = [...
|
|
1907
|
-
u.push({ ...
|
|
1908
|
-
...
|
|
1901
|
+
const v = ce(D, "modelValue"), { breakpoints: C } = al(), k = D, { promptMessage: t } = tl(), i = d, { t: b, locale: F } = se();
|
|
1902
|
+
function T(u) {
|
|
1903
|
+
v.value = El(u);
|
|
1904
|
+
}
|
|
1905
|
+
function f() {
|
|
1906
|
+
const u = [...v.value.widget.config.joinDatasources || []];
|
|
1907
|
+
u.push({ ...Vl(v.value.widget.type), conditions: [] }), T({
|
|
1908
|
+
...v.value,
|
|
1909
1909
|
widget: {
|
|
1910
|
-
...
|
|
1910
|
+
...v.value.widget,
|
|
1911
1911
|
config: {
|
|
1912
|
-
...
|
|
1912
|
+
...v.value.widget.config,
|
|
1913
1913
|
joinDatasources: u
|
|
1914
1914
|
}
|
|
1915
1915
|
}
|
|
1916
1916
|
});
|
|
1917
1917
|
}
|
|
1918
|
-
async function
|
|
1918
|
+
async function V(u) {
|
|
1919
1919
|
if (!await t({
|
|
1920
1920
|
title: b("report.tile.datasource.remove"),
|
|
1921
1921
|
message: b("report.tile.datasource.confirmRemove", { index: u + 1 })
|
|
1922
1922
|
})) return;
|
|
1923
|
-
const y = [...
|
|
1924
|
-
y.splice(u, 1),
|
|
1925
|
-
...
|
|
1923
|
+
const y = [...v.value.widget.config.joinDatasources || []];
|
|
1924
|
+
y.splice(u, 1), T({
|
|
1925
|
+
...v.value,
|
|
1926
1926
|
widget: {
|
|
1927
|
-
...
|
|
1927
|
+
...v.value.widget,
|
|
1928
1928
|
config: {
|
|
1929
|
-
...
|
|
1929
|
+
...v.value.widget.config,
|
|
1930
1930
|
joinDatasources: y
|
|
1931
1931
|
}
|
|
1932
1932
|
}
|
|
1933
1933
|
});
|
|
1934
1934
|
}
|
|
1935
|
-
const
|
|
1936
|
-
let y = 1,
|
|
1935
|
+
const M = (u, m) => {
|
|
1936
|
+
let y = 1, j = 1;
|
|
1937
1937
|
switch (u) {
|
|
1938
|
-
case
|
|
1939
|
-
y = 1,
|
|
1938
|
+
case I.Scorecard:
|
|
1939
|
+
y = 1, j = 2;
|
|
1940
1940
|
break;
|
|
1941
|
-
case
|
|
1942
|
-
case
|
|
1943
|
-
case
|
|
1944
|
-
case
|
|
1945
|
-
case
|
|
1946
|
-
y = 4,
|
|
1941
|
+
case I.BarChart:
|
|
1942
|
+
case I.StackBarChart:
|
|
1943
|
+
case I.ClusteredStackBarChart:
|
|
1944
|
+
case I.LineChart:
|
|
1945
|
+
case I.StackLineChart:
|
|
1946
|
+
y = 4, j = 6;
|
|
1947
1947
|
break;
|
|
1948
|
-
case
|
|
1949
|
-
y = 4,
|
|
1948
|
+
case I.Table:
|
|
1949
|
+
y = 4, j = 12;
|
|
1950
1950
|
break;
|
|
1951
|
-
case
|
|
1952
|
-
y = 4,
|
|
1951
|
+
case I.Circular:
|
|
1952
|
+
y = 4, j = 4;
|
|
1953
1953
|
break;
|
|
1954
|
-
case
|
|
1955
|
-
y = 0,
|
|
1954
|
+
case I.Spacer:
|
|
1955
|
+
y = 0, j = 12;
|
|
1956
1956
|
break;
|
|
1957
1957
|
}
|
|
1958
1958
|
return {
|
|
1959
1959
|
id: m.id,
|
|
1960
1960
|
size: {
|
|
1961
1961
|
height: y,
|
|
1962
|
-
width:
|
|
1962
|
+
width: j
|
|
1963
1963
|
},
|
|
1964
1964
|
widget: {
|
|
1965
1965
|
...m.widget,
|
|
1966
1966
|
type: u
|
|
1967
1967
|
}
|
|
1968
1968
|
};
|
|
1969
|
-
},
|
|
1970
|
-
() =>
|
|
1971
|
-
),
|
|
1972
|
-
|
|
1969
|
+
}, _ = S(
|
|
1970
|
+
() => Ie.find((u) => u.type === v.value.widget.type)
|
|
1971
|
+
), p = S(() => v.value.widget.config.joinDatasources), o = Oe((u) => {
|
|
1972
|
+
v.value.widget.title = u;
|
|
1973
1973
|
}, 500);
|
|
1974
1974
|
return ye(
|
|
1975
|
-
() =>
|
|
1975
|
+
() => v.value.size.height,
|
|
1976
1976
|
(u) => {
|
|
1977
|
-
u < 1 && (
|
|
1977
|
+
u < 1 && (v.value.size.height = 1), u > 12 && (v.value.size.height = 12);
|
|
1978
1978
|
}
|
|
1979
1979
|
), ye(
|
|
1980
|
-
() =>
|
|
1980
|
+
() => v.value.size.width,
|
|
1981
1981
|
(u) => {
|
|
1982
|
-
u < 1 && (
|
|
1982
|
+
u < 1 && (v.value.size.width = 1), u > 12 && (v.value.size.width = 12);
|
|
1983
1983
|
}
|
|
1984
1984
|
), (u, m) => {
|
|
1985
|
-
const y = $("FmCircularProgress"),
|
|
1986
|
-
return
|
|
1987
|
-
"model-value":
|
|
1985
|
+
const y = $("FmCircularProgress"), j = $("FmSimpleDateRangePicker"), Q = $("FmTextField"), E = $("FmTextarea"), X = $("FmStepperField"), J = $("FmButton"), le = $("FmForm");
|
|
1986
|
+
return g(), N(ll(l(C).lg || l(C).md ? mo : po), {
|
|
1987
|
+
"model-value": k.hideConfiguration,
|
|
1988
1988
|
"onUpdate:modelValue": m[9] || (m[9] = (B) => i("hideConfiguration", B))
|
|
1989
1989
|
}, {
|
|
1990
1990
|
default: R(() => [
|
|
1991
|
-
|
|
1991
|
+
v.value ? (g(), N(le, {
|
|
1992
1992
|
key: 1,
|
|
1993
1993
|
ref: "form",
|
|
1994
1994
|
class: "px-6 py-16 flex flex-col gap-24 overflow-y-auto overflow-x-hidden"
|
|
1995
1995
|
}, {
|
|
1996
1996
|
default: R(() => [
|
|
1997
|
-
|
|
1998
|
-
(
|
|
1999
|
-
key: `date-picker-${l(
|
|
2000
|
-
modelValue:
|
|
2001
|
-
"onUpdate:modelValue": m[0] || (m[0] = (B) =>
|
|
1997
|
+
h("div", _o, [
|
|
1998
|
+
(g(), N(j, {
|
|
1999
|
+
key: `date-picker-${l(F)}`,
|
|
2000
|
+
modelValue: x.value,
|
|
2001
|
+
"onUpdate:modelValue": m[0] || (m[0] = (B) => x.value = B)
|
|
2002
2002
|
}, null, 8, ["modelValue"]))
|
|
2003
2003
|
]),
|
|
2004
|
-
r(
|
|
2004
|
+
r(Pe, null, {
|
|
2005
2005
|
header: R(() => [
|
|
2006
|
-
|
|
2007
|
-
m[10] || (m[10] =
|
|
2006
|
+
h("p", So, P(l(b)("report.tile.widget.details")), 1),
|
|
2007
|
+
m[10] || (m[10] = h("div", { class: "grow" }, null, -1))
|
|
2008
2008
|
]),
|
|
2009
2009
|
content: R(() => [
|
|
2010
|
-
r(
|
|
2011
|
-
"model-value":
|
|
2010
|
+
r(Q, {
|
|
2011
|
+
"model-value": v.value.widget.title,
|
|
2012
2012
|
label: l(b)("report.tile.widget.title"),
|
|
2013
2013
|
placeholder: l(b)("report.tile.widget.titlePlaceholder"),
|
|
2014
2014
|
"onUpdate:modelValue": l(o)
|
|
2015
2015
|
}, null, 8, ["model-value", "label", "placeholder", "onUpdate:modelValue"]),
|
|
2016
|
-
r(
|
|
2017
|
-
modelValue:
|
|
2018
|
-
"onUpdate:modelValue": m[1] || (m[1] = (B) =>
|
|
2019
|
-
disabled:
|
|
2016
|
+
r(E, {
|
|
2017
|
+
modelValue: v.value.widget.description,
|
|
2018
|
+
"onUpdate:modelValue": m[1] || (m[1] = (B) => v.value.widget.description = B),
|
|
2019
|
+
disabled: v.value.widget.title === "",
|
|
2020
2020
|
placeholder: l(b)("report.tile.widget.descriptionPlaceholder"),
|
|
2021
2021
|
"helper-text": l(b)("report.tile.widget.descriptionHelper")
|
|
2022
2022
|
}, {
|
|
2023
2023
|
label: R(() => [
|
|
2024
|
-
|
|
2025
|
-
|
|
2024
|
+
h("p", To, P(l(b)("report.tile.widget.widgetDescription")), 1),
|
|
2025
|
+
h("p", $o, " (" + P(l(b)("report.tile.widget.optional")) + ") ", 1)
|
|
2026
2026
|
]),
|
|
2027
2027
|
_: 1
|
|
2028
2028
|
}, 8, ["modelValue", "disabled", "placeholder", "helper-text"]),
|
|
2029
|
-
r(
|
|
2030
|
-
model:
|
|
2031
|
-
"onUpdate:model": m[2] || (m[2] = (B) =>
|
|
2029
|
+
r(wo, {
|
|
2030
|
+
model: v.value.widget.config,
|
|
2031
|
+
"onUpdate:model": m[2] || (m[2] = (B) => v.value.widget.config = B)
|
|
2032
2032
|
}, null, 8, ["model"]),
|
|
2033
|
-
|
|
2034
|
-
class:
|
|
2033
|
+
h("div", {
|
|
2034
|
+
class: _e(["flex flex-row", `${l(C).sm || l(C).xs ? "gap-16" : "gap-2"}`])
|
|
2035
2035
|
}, [
|
|
2036
2036
|
r(X, {
|
|
2037
|
-
modelValue:
|
|
2038
|
-
"onUpdate:modelValue": m[3] || (m[3] = (B) =>
|
|
2037
|
+
modelValue: v.value.size.width,
|
|
2038
|
+
"onUpdate:modelValue": m[3] || (m[3] = (B) => v.value.size.width = B),
|
|
2039
2039
|
label: l(b)("report.tile.widget.width"),
|
|
2040
2040
|
min: 1,
|
|
2041
2041
|
max: 12
|
|
2042
2042
|
}, null, 8, ["modelValue", "label"]),
|
|
2043
2043
|
r(X, {
|
|
2044
|
-
modelValue:
|
|
2045
|
-
"onUpdate:modelValue": m[4] || (m[4] = (B) =>
|
|
2044
|
+
modelValue: v.value.size.height,
|
|
2045
|
+
"onUpdate:modelValue": m[4] || (m[4] = (B) => v.value.size.height = B),
|
|
2046
2046
|
label: l(b)("report.tile.widget.height"),
|
|
2047
2047
|
min: 1,
|
|
2048
2048
|
max: 12,
|
|
2049
|
-
disabled:
|
|
2049
|
+
disabled: v.value.widget.type === l(I).Scorecard
|
|
2050
2050
|
}, null, 8, ["modelValue", "label", "disabled"])
|
|
2051
2051
|
], 2),
|
|
2052
|
-
|
|
2052
|
+
v.value.widget.type === l(I).Table ? (g(), N(ko, {
|
|
2053
2053
|
key: 0,
|
|
2054
|
-
layout:
|
|
2055
|
-
"onUpdate:layout": m[5] || (m[5] = (B) =>
|
|
2054
|
+
layout: v.value.widget.config,
|
|
2055
|
+
"onUpdate:layout": m[5] || (m[5] = (B) => v.value.widget.config = B)
|
|
2056
2056
|
}, null, 8, ["layout"])) : O("", !0)
|
|
2057
2057
|
]),
|
|
2058
2058
|
_: 1
|
|
2059
2059
|
}),
|
|
2060
|
-
r(
|
|
2060
|
+
r(Pe, null, {
|
|
2061
2061
|
header: R(() => [
|
|
2062
|
-
|
|
2063
|
-
m[11] || (m[11] =
|
|
2062
|
+
h("p", null, P(l(b)("report.tile.widget.type")), 1),
|
|
2063
|
+
m[11] || (m[11] = h("div", { class: "grow" }, null, -1))
|
|
2064
2064
|
]),
|
|
2065
2065
|
content: R(() => [
|
|
2066
|
-
r(
|
|
2066
|
+
r(Cl, {
|
|
2067
2067
|
"is-list": !0,
|
|
2068
|
-
"model-value":
|
|
2068
|
+
"model-value": v.value.widget.type,
|
|
2069
2069
|
class: "grid grid-cols-1 gap-2",
|
|
2070
2070
|
"child-class": "flex flex-row p-[8px] gap-2",
|
|
2071
|
-
"exclude-widge-type": [l(
|
|
2072
|
-
"onUpdate:modelValue": m[6] || (m[6] = (B) =>
|
|
2071
|
+
"exclude-widge-type": [l(I).Spacer],
|
|
2072
|
+
"onUpdate:modelValue": m[6] || (m[6] = (B) => v.value = M(B, v.value))
|
|
2073
2073
|
}, null, 8, ["model-value", "exclude-widge-type"])
|
|
2074
2074
|
]),
|
|
2075
2075
|
_: 1
|
|
2076
2076
|
}),
|
|
2077
2077
|
r(Qe, {
|
|
2078
|
-
modelValue:
|
|
2079
|
-
"onUpdate:modelValue": m[7] || (m[7] = (B) =>
|
|
2078
|
+
modelValue: v.value.widget.config,
|
|
2079
|
+
"onUpdate:modelValue": m[7] || (m[7] = (B) => v.value.widget.config = B),
|
|
2080
2080
|
label: l(b)("report.tile.datasource.main"),
|
|
2081
|
-
config:
|
|
2081
|
+
config: _.value
|
|
2082
2082
|
}, null, 8, ["modelValue", "label", "config"]),
|
|
2083
|
-
|
|
2083
|
+
p.value ? (g(!0), A(re, { key: 0 }, we(p.value, (B, G) => (g(), A("div", { key: G }, [
|
|
2084
2084
|
r(Qe, {
|
|
2085
|
-
modelValue:
|
|
2086
|
-
"onUpdate:modelValue": (
|
|
2085
|
+
modelValue: p.value[G],
|
|
2086
|
+
"onUpdate:modelValue": (te) => p.value[G] = te,
|
|
2087
2087
|
label: l(b)("report.tile.datasource.join", { index: G + 1 }),
|
|
2088
|
-
config:
|
|
2089
|
-
"main-datasource-config":
|
|
2088
|
+
config: _.value,
|
|
2089
|
+
"main-datasource-config": v.value.widget.config,
|
|
2090
2090
|
closeable: !0,
|
|
2091
|
-
onClickClose: (
|
|
2091
|
+
onClickClose: (te) => V(G)
|
|
2092
2092
|
}, null, 8, ["modelValue", "onUpdate:modelValue", "label", "config", "main-datasource-config", "onClickClose"])
|
|
2093
2093
|
]))), 128)) : O("", !0),
|
|
2094
|
-
|
|
2095
|
-
r(
|
|
2094
|
+
h("div", Do, [
|
|
2095
|
+
r(J, {
|
|
2096
2096
|
label: l(b)("report.tile.datasource.joinButton"),
|
|
2097
2097
|
variant: "secondary",
|
|
2098
2098
|
icon: "add",
|
|
@@ -2100,110 +2100,110 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
2100
2100
|
"border-color": "primary",
|
|
2101
2101
|
"text-color": "primary",
|
|
2102
2102
|
class: "w-full",
|
|
2103
|
-
onClick: m[8] || (m[8] = (B) =>
|
|
2103
|
+
onClick: m[8] || (m[8] = (B) => f())
|
|
2104
2104
|
}, null, 8, ["label"])
|
|
2105
2105
|
])
|
|
2106
2106
|
]),
|
|
2107
2107
|
_: 1
|
|
2108
|
-
}, 512)) : (
|
|
2108
|
+
}, 512)) : (g(), N(y, { key: 0 }))
|
|
2109
2109
|
]),
|
|
2110
2110
|
_: 1
|
|
2111
2111
|
}, 8, ["model-value"]);
|
|
2112
2112
|
};
|
|
2113
2113
|
}
|
|
2114
|
-
}),
|
|
2114
|
+
}), Bo = { class: "flex flex-col gap-8" }, Uo = { class: "pl-32 flex flex-col gap-8" }, Lo = { class: "fm-typo-en-body-lg-600" }, Mo = { class: "flex flex-row gap-8" }, No = { class: "fm-typo-en-body-lg-600" }, Oo = { class: "flex flex-row gap-8" }, jo = /* @__PURE__ */ ae({
|
|
2115
2115
|
__name: "LabelSection",
|
|
2116
2116
|
props: {
|
|
2117
2117
|
model: {}
|
|
2118
2118
|
},
|
|
2119
2119
|
emits: ["update:model"],
|
|
2120
2120
|
setup(D, { emit: d }) {
|
|
2121
|
-
const e = D, s = d, { t: a } =
|
|
2121
|
+
const e = D, s = d, { t: a } = se(), w = S({
|
|
2122
2122
|
get: () => e.model.showLabel ?? !1,
|
|
2123
|
-
set: (
|
|
2124
|
-
s("update:model", { ...e.model, showLabel:
|
|
2123
|
+
set: (F) => {
|
|
2124
|
+
s("update:model", { ...e.model, showLabel: F });
|
|
2125
2125
|
}
|
|
2126
|
-
}),
|
|
2126
|
+
}), x = S({
|
|
2127
2127
|
get: () => e.model.labelRotation ?? 0,
|
|
2128
|
-
set: (
|
|
2129
|
-
}),
|
|
2128
|
+
set: (F) => s("update:model", { ...e.model, labelRotation: F })
|
|
2129
|
+
}), v = S({
|
|
2130
2130
|
get: () => e.model.labelOffset ?? 0,
|
|
2131
|
-
set: (
|
|
2132
|
-
}),
|
|
2131
|
+
set: (F) => s("update:model", { ...e.model, labelOffset: F })
|
|
2132
|
+
}), C = S({
|
|
2133
2133
|
get: () => e.model.labelFontSize ?? 12,
|
|
2134
|
-
set: (
|
|
2135
|
-
}),
|
|
2134
|
+
set: (F) => s("update:model", { ...e.model, labelFontSize: F })
|
|
2135
|
+
}), k = (F) => {
|
|
2136
2136
|
s("update:model", {
|
|
2137
2137
|
...e.model,
|
|
2138
|
-
labelAlign: e.model.labelAlign ===
|
|
2138
|
+
labelAlign: e.model.labelAlign === F ? void 0 : F
|
|
2139
2139
|
});
|
|
2140
|
-
}, t = (
|
|
2140
|
+
}, t = (F) => {
|
|
2141
2141
|
s("update:model", {
|
|
2142
2142
|
...e.model,
|
|
2143
|
-
labelAnchor: e.model.labelAnchor ===
|
|
2143
|
+
labelAnchor: e.model.labelAnchor === F ? void 0 : F
|
|
2144
2144
|
});
|
|
2145
2145
|
}, i = [
|
|
2146
|
-
{ icon: "align_horizontal_left", value:
|
|
2147
|
-
{ icon: "align_justify_center", value:
|
|
2148
|
-
{ icon: "align_horizontal_right", value:
|
|
2149
|
-
{ icon: "align_justify_flex_start", value:
|
|
2150
|
-
{ icon: "align_justify_flex_end", value:
|
|
2151
|
-
{ icon: "align_flex_start", value:
|
|
2152
|
-
{ icon: "align_flex_end", value:
|
|
2146
|
+
{ icon: "align_horizontal_left", value: Ce.left, tooltip: "alignLeft" },
|
|
2147
|
+
{ icon: "align_justify_center", value: Ce.center, tooltip: "alignCenter" },
|
|
2148
|
+
{ icon: "align_horizontal_right", value: Ce.right, tooltip: "alignRight" },
|
|
2149
|
+
{ icon: "align_justify_flex_start", value: Ce.start, tooltip: "alignStart" },
|
|
2150
|
+
{ icon: "align_justify_flex_end", value: Ce.end, tooltip: "alignEnd" },
|
|
2151
|
+
{ icon: "align_flex_start", value: Ce.top, tooltip: "alignTop" },
|
|
2152
|
+
{ icon: "align_flex_end", value: Ce.bottom, tooltip: "alignBottom" }
|
|
2153
2153
|
], b = [
|
|
2154
|
-
{ icon: "format_align_left", value:
|
|
2155
|
-
{ icon: "format_align_center", value:
|
|
2156
|
-
{ icon: "format_align_right", value:
|
|
2154
|
+
{ icon: "format_align_left", value: Me.start, tooltip: "anchorStart" },
|
|
2155
|
+
{ icon: "format_align_center", value: Me.center, tooltip: "anchorCenter" },
|
|
2156
|
+
{ icon: "format_align_right", value: Me.end, tooltip: "anchorEnd" }
|
|
2157
2157
|
];
|
|
2158
|
-
return (
|
|
2159
|
-
const
|
|
2160
|
-
return
|
|
2161
|
-
r(
|
|
2162
|
-
modelValue:
|
|
2163
|
-
"onUpdate:modelValue":
|
|
2158
|
+
return (F, T) => {
|
|
2159
|
+
const f = $("FmCheckbox"), V = $("FmButton"), M = $("FmTooltip"), _ = $("FmTextField"), p = $("FmStepperField");
|
|
2160
|
+
return g(), A("div", Bo, [
|
|
2161
|
+
r(f, {
|
|
2162
|
+
modelValue: w.value,
|
|
2163
|
+
"onUpdate:modelValue": T[0] || (T[0] = (o) => w.value = o),
|
|
2164
2164
|
value: !1,
|
|
2165
2165
|
label: l(a)("report.section.datasource.label.showLabel"),
|
|
2166
2166
|
"label-placement": "right",
|
|
2167
2167
|
class: "fm-typo-en-body-lg-400"
|
|
2168
2168
|
}, null, 8, ["modelValue", "label"]),
|
|
2169
|
-
|
|
2170
|
-
|
|
2171
|
-
|
|
2172
|
-
(
|
|
2169
|
+
be(h("div", Uo, [
|
|
2170
|
+
h("p", Lo, P(l(a)("report.section.datasource.alignment.textAlignment")), 1),
|
|
2171
|
+
h("div", Mo, [
|
|
2172
|
+
(g(), A(re, null, we(i, ({ icon: o, value: n, tooltip: c }) => r(M, {
|
|
2173
2173
|
key: n,
|
|
2174
2174
|
variant: "plain",
|
|
2175
2175
|
placement: "top",
|
|
2176
|
-
content: l(a)(`report.section.datasource.alignment.alignOptions.${
|
|
2176
|
+
content: l(a)(`report.section.datasource.alignment.alignOptions.${c}`),
|
|
2177
2177
|
"z-index": 50
|
|
2178
2178
|
}, {
|
|
2179
2179
|
default: R(() => [
|
|
2180
|
-
r(
|
|
2180
|
+
r(V, {
|
|
2181
2181
|
"append-icon": o,
|
|
2182
2182
|
variant: "tertiary",
|
|
2183
|
-
"icon-color":
|
|
2184
|
-
"bg-color":
|
|
2183
|
+
"icon-color": F.model.labelAlign === n ? "neutral-gray-400" : "neutral-gray-300",
|
|
2184
|
+
"bg-color": F.model.labelAlign === n ? "neutral-gray-100" : "neutral-white",
|
|
2185
2185
|
class: "rounded-sm",
|
|
2186
|
-
onClick: (u) =>
|
|
2186
|
+
onClick: (u) => k(n)
|
|
2187
2187
|
}, null, 8, ["append-icon", "icon-color", "bg-color", "onClick"])
|
|
2188
2188
|
]),
|
|
2189
2189
|
_: 2
|
|
2190
2190
|
}, 1032, ["content"])), 64))
|
|
2191
2191
|
]),
|
|
2192
|
-
|
|
2193
|
-
|
|
2194
|
-
(
|
|
2192
|
+
h("p", No, P(l(a)("report.section.datasource.alignment.anchor")), 1),
|
|
2193
|
+
h("div", Oo, [
|
|
2194
|
+
(g(), A(re, null, we(b, ({ icon: o, value: n, tooltip: c }) => r(M, {
|
|
2195
2195
|
key: n,
|
|
2196
2196
|
variant: "plain",
|
|
2197
2197
|
placement: "top",
|
|
2198
|
-
content: l(a)(`report.section.datasource.alignment.anchorOptions.${
|
|
2198
|
+
content: l(a)(`report.section.datasource.alignment.anchorOptions.${c}`),
|
|
2199
2199
|
"z-index": 50
|
|
2200
2200
|
}, {
|
|
2201
2201
|
default: R(() => [
|
|
2202
|
-
r(
|
|
2202
|
+
r(V, {
|
|
2203
2203
|
"append-icon": o,
|
|
2204
2204
|
variant: "tertiary",
|
|
2205
|
-
"icon-color":
|
|
2206
|
-
"bg-color":
|
|
2205
|
+
"icon-color": F.model.labelAnchor === n ? "neutral-gray-400" : "neutral-gray-300",
|
|
2206
|
+
"bg-color": F.model.labelAnchor === n ? "neutral-gray-100" : "neutral-white",
|
|
2207
2207
|
class: "rounded-sm",
|
|
2208
2208
|
onClick: (u) => t(n)
|
|
2209
2209
|
}, null, 8, ["append-icon", "icon-color", "bg-color", "onClick"])
|
|
@@ -2211,224 +2211,224 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
2211
2211
|
_: 2
|
|
2212
2212
|
}, 1032, ["content"])), 64))
|
|
2213
2213
|
]),
|
|
2214
|
-
r(
|
|
2215
|
-
modelValue:
|
|
2216
|
-
"onUpdate:modelValue":
|
|
2214
|
+
r(_, {
|
|
2215
|
+
modelValue: x.value,
|
|
2216
|
+
"onUpdate:modelValue": T[1] || (T[1] = (o) => x.value = o),
|
|
2217
2217
|
label: l(a)("report.section.datasource.alignment.rotation"),
|
|
2218
2218
|
type: "number",
|
|
2219
2219
|
min: -180,
|
|
2220
2220
|
max: 180,
|
|
2221
2221
|
step: 1
|
|
2222
2222
|
}, null, 8, ["modelValue", "label"]),
|
|
2223
|
-
r(
|
|
2224
|
-
modelValue:
|
|
2225
|
-
"onUpdate:modelValue":
|
|
2223
|
+
r(_, {
|
|
2224
|
+
modelValue: v.value,
|
|
2225
|
+
"onUpdate:modelValue": T[2] || (T[2] = (o) => v.value = o),
|
|
2226
2226
|
label: l(a)("report.section.datasource.alignment.offset"),
|
|
2227
2227
|
type: "number"
|
|
2228
2228
|
}, null, 8, ["modelValue", "label"]),
|
|
2229
|
-
r(
|
|
2230
|
-
modelValue:
|
|
2231
|
-
"onUpdate:modelValue":
|
|
2229
|
+
r(p, {
|
|
2230
|
+
modelValue: C.value,
|
|
2231
|
+
"onUpdate:modelValue": T[3] || (T[3] = (o) => C.value = o),
|
|
2232
2232
|
label: l(a)("report.section.datasource.fontSize"),
|
|
2233
2233
|
type: "number",
|
|
2234
2234
|
min: 1
|
|
2235
2235
|
}, null, 8, ["modelValue", "label"])
|
|
2236
2236
|
], 512), [
|
|
2237
|
-
[
|
|
2237
|
+
[he, w.value]
|
|
2238
2238
|
])
|
|
2239
2239
|
]);
|
|
2240
2240
|
};
|
|
2241
2241
|
}
|
|
2242
|
-
}),
|
|
2242
|
+
}), zo = { class: "flex flex-col gap-8" }, Io = { class: "pl-32 flex flex-col gap-8" }, Ao = { class: "pl-32 flex flex-col gap-8" }, Ro = { class: "pl-32 flex flex-col gap-8" }, Po = { class: "pl-32 flex flex-col gap-8" }, Xo = { class: "pl-32 flex flex-col gap-8" }, Eo = { class: "pl-32 flex flex-col gap-8" }, Wo = /* @__PURE__ */ ae({
|
|
2243
2243
|
__name: "XySection",
|
|
2244
2244
|
props: {
|
|
2245
2245
|
model: {}
|
|
2246
2246
|
},
|
|
2247
2247
|
emits: ["update:model"],
|
|
2248
2248
|
setup(D, { emit: d }) {
|
|
2249
|
-
const e = D, s = d, { t: a } =
|
|
2249
|
+
const e = D, s = d, { t: a } = se(), w = S({
|
|
2250
2250
|
get: () => e.model.showX ?? !0,
|
|
2251
|
-
set: (
|
|
2252
|
-
s("update:model", { ...e.model, showX:
|
|
2251
|
+
set: (f) => {
|
|
2252
|
+
s("update:model", { ...e.model, showX: f });
|
|
2253
2253
|
}
|
|
2254
|
-
}),
|
|
2254
|
+
}), x = S({
|
|
2255
2255
|
get: () => e.model.showXGrid ?? !1,
|
|
2256
|
-
set: (
|
|
2257
|
-
s("update:model", { ...e.model, showXGrid:
|
|
2256
|
+
set: (f) => {
|
|
2257
|
+
s("update:model", { ...e.model, showXGrid: f });
|
|
2258
2258
|
}
|
|
2259
|
-
}),
|
|
2259
|
+
}), v = S({
|
|
2260
2260
|
get: () => e.model.showXTick ?? !0,
|
|
2261
|
-
set: (
|
|
2262
|
-
s("update:model", { ...e.model, showXTick:
|
|
2261
|
+
set: (f) => {
|
|
2262
|
+
s("update:model", { ...e.model, showXTick: f });
|
|
2263
2263
|
}
|
|
2264
|
-
}),
|
|
2264
|
+
}), C = S({
|
|
2265
2265
|
get: () => e.model.showY ?? !0,
|
|
2266
|
-
set: (
|
|
2267
|
-
s("update:model", { ...e.model, showY:
|
|
2266
|
+
set: (f) => {
|
|
2267
|
+
s("update:model", { ...e.model, showY: f });
|
|
2268
2268
|
}
|
|
2269
|
-
}),
|
|
2269
|
+
}), k = S({
|
|
2270
2270
|
get: () => e.model.showYGrid ?? !0,
|
|
2271
|
-
set: (
|
|
2272
|
-
s("update:model", { ...e.model, showYGrid:
|
|
2271
|
+
set: (f) => {
|
|
2272
|
+
s("update:model", { ...e.model, showYGrid: f });
|
|
2273
2273
|
}
|
|
2274
|
-
}), t =
|
|
2274
|
+
}), t = S({
|
|
2275
2275
|
get: () => e.model.showYTick ?? !0,
|
|
2276
|
-
set: (
|
|
2277
|
-
s("update:model", { ...e.model, showYTick:
|
|
2276
|
+
set: (f) => {
|
|
2277
|
+
s("update:model", { ...e.model, showYTick: f });
|
|
2278
2278
|
}
|
|
2279
|
-
}), i =
|
|
2279
|
+
}), i = S({
|
|
2280
2280
|
get: () => e.model.showXTitle ?? !1,
|
|
2281
|
-
set: (
|
|
2282
|
-
s("update:model", { ...e.model, showXTitle:
|
|
2281
|
+
set: (f) => {
|
|
2282
|
+
s("update:model", { ...e.model, showXTitle: f });
|
|
2283
2283
|
}
|
|
2284
|
-
}), b =
|
|
2284
|
+
}), b = S({
|
|
2285
2285
|
get: () => e.model.showYTitle ?? !1,
|
|
2286
|
-
set: (
|
|
2287
|
-
s("update:model", { ...e.model, showYTitle:
|
|
2286
|
+
set: (f) => {
|
|
2287
|
+
s("update:model", { ...e.model, showYTitle: f });
|
|
2288
2288
|
}
|
|
2289
|
-
}),
|
|
2290
|
-
s("update:model", { ...e.model, xTitle:
|
|
2291
|
-
}, 500),
|
|
2292
|
-
s("update:model", { ...e.model, yTitle:
|
|
2289
|
+
}), F = Oe((f) => {
|
|
2290
|
+
s("update:model", { ...e.model, xTitle: f });
|
|
2291
|
+
}, 500), T = Oe((f) => {
|
|
2292
|
+
s("update:model", { ...e.model, yTitle: f });
|
|
2293
2293
|
}, 500);
|
|
2294
2294
|
return We(() => {
|
|
2295
|
-
var
|
|
2296
|
-
!e.model.xTitle && ((
|
|
2297
|
-
}), (
|
|
2298
|
-
const
|
|
2299
|
-
return
|
|
2300
|
-
r(
|
|
2301
|
-
modelValue:
|
|
2302
|
-
"onUpdate:modelValue":
|
|
2295
|
+
var f, V, M, _;
|
|
2296
|
+
!e.model.xTitle && ((V = (f = e.model.metrics) == null ? void 0 : f[0]) != null && V.label) && F(e.model.metrics[0].label), !e.model.yTitle && ((_ = (M = e.model.dimensions) == null ? void 0 : M[0]) != null && _.label) && T(e.model.dimensions[0].label);
|
|
2297
|
+
}), (f, V) => {
|
|
2298
|
+
const M = $("FmCheckbox"), _ = $("FmStepperField"), p = $("FmTextField");
|
|
2299
|
+
return g(), A("div", zo, [
|
|
2300
|
+
r(M, {
|
|
2301
|
+
modelValue: w.value,
|
|
2302
|
+
"onUpdate:modelValue": V[0] || (V[0] = (o) => w.value = o),
|
|
2303
2303
|
label: l(a)("report.section.datasource.axis.showX"),
|
|
2304
2304
|
"label-placement": "right",
|
|
2305
2305
|
value: !0
|
|
2306
2306
|
}, null, 8, ["modelValue", "label"]),
|
|
2307
|
-
|
|
2308
|
-
r(
|
|
2309
|
-
modelValue:
|
|
2310
|
-
"onUpdate:modelValue":
|
|
2307
|
+
be(h("div", Io, [
|
|
2308
|
+
r(M, {
|
|
2309
|
+
modelValue: x.value,
|
|
2310
|
+
"onUpdate:modelValue": V[1] || (V[1] = (o) => x.value = o),
|
|
2311
2311
|
label: l(a)("report.section.datasource.axis.showGrid"),
|
|
2312
2312
|
"label-placement": "right",
|
|
2313
2313
|
value: !1
|
|
2314
2314
|
}, null, 8, ["modelValue", "label"]),
|
|
2315
|
-
r(
|
|
2316
|
-
modelValue:
|
|
2317
|
-
"onUpdate:modelValue":
|
|
2315
|
+
r(M, {
|
|
2316
|
+
modelValue: v.value,
|
|
2317
|
+
"onUpdate:modelValue": V[2] || (V[2] = (o) => v.value = o),
|
|
2318
2318
|
label: l(a)("report.section.datasource.axis.showTick"),
|
|
2319
2319
|
"label-placement": "right",
|
|
2320
2320
|
value: !0
|
|
2321
2321
|
}, null, 8, ["modelValue", "label"]),
|
|
2322
|
-
|
|
2323
|
-
r(
|
|
2322
|
+
be(h("div", Ao, [
|
|
2323
|
+
r(_, {
|
|
2324
2324
|
label: l(a)("report.section.datasource.fontSize"),
|
|
2325
2325
|
type: "number",
|
|
2326
|
-
"model-value":
|
|
2326
|
+
"model-value": f.model.xTickFontSize ?? 12,
|
|
2327
2327
|
min: 1,
|
|
2328
|
-
"onUpdate:modelValue":
|
|
2329
|
-
s("update:model", { ...
|
|
2328
|
+
"onUpdate:modelValue": V[3] || (V[3] = (o) => {
|
|
2329
|
+
s("update:model", { ...f.model, xTickFontSize: Number(o) });
|
|
2330
2330
|
})
|
|
2331
2331
|
}, null, 8, ["label", "model-value"])
|
|
2332
2332
|
], 512), [
|
|
2333
|
-
[
|
|
2333
|
+
[he, f.model.showXTick ?? !0]
|
|
2334
2334
|
]),
|
|
2335
|
-
r(
|
|
2335
|
+
r(M, {
|
|
2336
2336
|
modelValue: i.value,
|
|
2337
|
-
"onUpdate:modelValue":
|
|
2337
|
+
"onUpdate:modelValue": V[4] || (V[4] = (o) => i.value = o),
|
|
2338
2338
|
label: l(a)("report.section.datasource.axis.showTitle"),
|
|
2339
2339
|
"label-placement": "right",
|
|
2340
2340
|
value: !0
|
|
2341
2341
|
}, null, 8, ["modelValue", "label"]),
|
|
2342
|
-
|
|
2343
|
-
r(
|
|
2344
|
-
"model-value":
|
|
2342
|
+
be(h("div", Ro, [
|
|
2343
|
+
r(p, {
|
|
2344
|
+
"model-value": f.model.xTitle,
|
|
2345
2345
|
label: l(a)("report.common.title"),
|
|
2346
2346
|
placeholder: l(a)("report.tile.widget.titlePlaceholder"),
|
|
2347
|
-
"onUpdate:modelValue": l(
|
|
2347
|
+
"onUpdate:modelValue": l(F)
|
|
2348
2348
|
}, null, 8, ["model-value", "label", "placeholder", "onUpdate:modelValue"]),
|
|
2349
|
-
r(
|
|
2349
|
+
r(_, {
|
|
2350
2350
|
label: l(a)("report.section.datasource.fontSize"),
|
|
2351
2351
|
type: "number",
|
|
2352
|
-
"model-value":
|
|
2352
|
+
"model-value": f.model.xTitleFontSize ?? 12,
|
|
2353
2353
|
min: 1,
|
|
2354
|
-
"onUpdate:modelValue":
|
|
2355
|
-
s("update:model", { ...
|
|
2354
|
+
"onUpdate:modelValue": V[5] || (V[5] = (o) => {
|
|
2355
|
+
s("update:model", { ...f.model, xTitleFontSize: Number(o) });
|
|
2356
2356
|
})
|
|
2357
2357
|
}, null, 8, ["label", "model-value"])
|
|
2358
2358
|
], 512), [
|
|
2359
|
-
[
|
|
2359
|
+
[he, i.value]
|
|
2360
2360
|
])
|
|
2361
2361
|
], 512), [
|
|
2362
|
-
[
|
|
2362
|
+
[he, f.model.showX ?? !0]
|
|
2363
2363
|
]),
|
|
2364
|
-
r(
|
|
2365
|
-
modelValue:
|
|
2366
|
-
"onUpdate:modelValue":
|
|
2364
|
+
r(M, {
|
|
2365
|
+
modelValue: C.value,
|
|
2366
|
+
"onUpdate:modelValue": V[6] || (V[6] = (o) => C.value = o),
|
|
2367
2367
|
label: l(a)("report.section.datasource.axis.showY"),
|
|
2368
2368
|
"label-placement": "right",
|
|
2369
2369
|
value: !0
|
|
2370
2370
|
}, null, 8, ["modelValue", "label"]),
|
|
2371
|
-
|
|
2372
|
-
r(
|
|
2373
|
-
modelValue:
|
|
2374
|
-
"onUpdate:modelValue":
|
|
2371
|
+
be(h("div", Po, [
|
|
2372
|
+
r(M, {
|
|
2373
|
+
modelValue: k.value,
|
|
2374
|
+
"onUpdate:modelValue": V[7] || (V[7] = (o) => k.value = o),
|
|
2375
2375
|
label: l(a)("report.section.datasource.axis.showGrid"),
|
|
2376
2376
|
"label-placement": "right",
|
|
2377
2377
|
value: !1
|
|
2378
2378
|
}, null, 8, ["modelValue", "label"]),
|
|
2379
|
-
r(
|
|
2379
|
+
r(M, {
|
|
2380
2380
|
modelValue: t.value,
|
|
2381
|
-
"onUpdate:modelValue":
|
|
2381
|
+
"onUpdate:modelValue": V[8] || (V[8] = (o) => t.value = o),
|
|
2382
2382
|
label: l(a)("report.section.datasource.axis.showTick"),
|
|
2383
2383
|
"label-placement": "right",
|
|
2384
2384
|
value: !0
|
|
2385
2385
|
}, null, 8, ["modelValue", "label"]),
|
|
2386
|
-
|
|
2387
|
-
r(
|
|
2386
|
+
be(h("div", Xo, [
|
|
2387
|
+
r(_, {
|
|
2388
2388
|
label: l(a)("report.section.datasource.fontSize"),
|
|
2389
2389
|
type: "number",
|
|
2390
|
-
"model-value":
|
|
2390
|
+
"model-value": f.model.yTickFontSize ?? 12,
|
|
2391
2391
|
min: 1,
|
|
2392
|
-
"onUpdate:modelValue":
|
|
2393
|
-
s("update:model", { ...
|
|
2392
|
+
"onUpdate:modelValue": V[9] || (V[9] = (o) => {
|
|
2393
|
+
s("update:model", { ...f.model, yTickFontSize: Number(o) });
|
|
2394
2394
|
})
|
|
2395
2395
|
}, null, 8, ["label", "model-value"])
|
|
2396
2396
|
], 512), [
|
|
2397
|
-
[
|
|
2397
|
+
[he, f.model.showYTick ?? !0]
|
|
2398
2398
|
]),
|
|
2399
|
-
r(
|
|
2399
|
+
r(M, {
|
|
2400
2400
|
modelValue: b.value,
|
|
2401
|
-
"onUpdate:modelValue":
|
|
2401
|
+
"onUpdate:modelValue": V[10] || (V[10] = (o) => b.value = o),
|
|
2402
2402
|
label: l(a)("report.section.datasource.axis.showTitle"),
|
|
2403
2403
|
"label-placement": "right",
|
|
2404
2404
|
value: !0
|
|
2405
2405
|
}, null, 8, ["modelValue", "label"]),
|
|
2406
|
-
|
|
2407
|
-
r(
|
|
2408
|
-
"model-value":
|
|
2406
|
+
be(h("div", Eo, [
|
|
2407
|
+
r(p, {
|
|
2408
|
+
"model-value": f.model.yTitle,
|
|
2409
2409
|
label: l(a)("report.common.title"),
|
|
2410
2410
|
placeholder: l(a)("report.tile.widget.titlePlaceholder"),
|
|
2411
|
-
"onUpdate:modelValue": l(
|
|
2411
|
+
"onUpdate:modelValue": l(T)
|
|
2412
2412
|
}, null, 8, ["model-value", "label", "placeholder", "onUpdate:modelValue"]),
|
|
2413
|
-
r(
|
|
2413
|
+
r(_, {
|
|
2414
2414
|
label: l(a)("report.section.datasource.fontSize"),
|
|
2415
2415
|
type: "number",
|
|
2416
|
-
"model-value":
|
|
2416
|
+
"model-value": f.model.yTitleFontSize ?? 12,
|
|
2417
2417
|
min: 1,
|
|
2418
|
-
"onUpdate:modelValue":
|
|
2419
|
-
s("update:model", { ...
|
|
2418
|
+
"onUpdate:modelValue": V[11] || (V[11] = (o) => {
|
|
2419
|
+
s("update:model", { ...f.model, yTitleFontSize: Number(o) });
|
|
2420
2420
|
})
|
|
2421
2421
|
}, null, 8, ["label", "model-value"])
|
|
2422
2422
|
], 512), [
|
|
2423
|
-
[
|
|
2423
|
+
[he, b.value]
|
|
2424
2424
|
])
|
|
2425
2425
|
], 512), [
|
|
2426
|
-
[
|
|
2426
|
+
[he, f.model.showY ?? !0]
|
|
2427
2427
|
])
|
|
2428
2428
|
]);
|
|
2429
2429
|
};
|
|
2430
2430
|
}
|
|
2431
|
-
}),
|
|
2431
|
+
}), qo = { class: "flex flex-col gap-8" }, Yo = { class: "pl-32 flex flex-col gap-8" }, Ho = { class: "text-fm-color-typo-primary fm-typo-en-body-lg-600" }, Jo = ["onKeydown"], Go = /* @__PURE__ */ ae({
|
|
2432
2432
|
__name: "LegendSection",
|
|
2433
2433
|
props: {
|
|
2434
2434
|
model: {},
|
|
@@ -2436,165 +2436,149 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
2436
2436
|
},
|
|
2437
2437
|
emits: ["update:model"],
|
|
2438
2438
|
setup(D, { emit: d }) {
|
|
2439
|
-
const e = D, s = d, { t: a } =
|
|
2439
|
+
const e = D, s = d, { t: a } = se(), w = [
|
|
2440
2440
|
{ label: a("report.section.datasource.position.top"), value: "top" },
|
|
2441
2441
|
{ label: a("report.section.datasource.position.bottom"), value: "bottom" },
|
|
2442
2442
|
{ label: a("report.section.datasource.position.left"), value: "left" },
|
|
2443
2443
|
{ label: a("report.section.datasource.position.right"), value: "right" }
|
|
2444
|
-
],
|
|
2444
|
+
], x = S({
|
|
2445
2445
|
get: () => e.model.showLegend !== void 0 ? e.model.showLegend : e.isCircularWidget === !0,
|
|
2446
|
-
set: (
|
|
2447
|
-
s("update:model", { ...e.model, showLegend:
|
|
2446
|
+
set: (T) => {
|
|
2447
|
+
s("update:model", { ...e.model, showLegend: T });
|
|
2448
2448
|
}
|
|
2449
|
-
}),
|
|
2449
|
+
}), v = S({
|
|
2450
2450
|
get: () => e.model.usePointStyle ?? !0,
|
|
2451
|
-
set: (
|
|
2452
|
-
s("update:model", { ...e.model, usePointStyle:
|
|
2451
|
+
set: (T) => {
|
|
2452
|
+
s("update:model", { ...e.model, usePointStyle: T });
|
|
2453
2453
|
}
|
|
2454
|
-
}),
|
|
2454
|
+
}), C = S({
|
|
2455
2455
|
get: () => e.model.legendFontSize ?? null,
|
|
2456
|
-
set: (
|
|
2457
|
-
if (
|
|
2456
|
+
set: (T) => {
|
|
2457
|
+
if (T == null) {
|
|
2458
2458
|
s("update:model", { ...e.model, legendFontSize: void 0 });
|
|
2459
2459
|
return;
|
|
2460
2460
|
}
|
|
2461
|
-
s("update:model", { ...e.model, legendFontSize: Math.min(Number(
|
|
2461
|
+
s("update:model", { ...e.model, legendFontSize: Math.min(Number(T), 24) });
|
|
2462
2462
|
}
|
|
2463
|
-
}),
|
|
2463
|
+
}), k = S(() => e.model.legendColor ?? "#6b6b6b"), t = ee(k.value), i = ee(null);
|
|
2464
2464
|
ye(
|
|
2465
2465
|
() => e.model.legendColor,
|
|
2466
|
-
(
|
|
2467
|
-
t.value =
|
|
2466
|
+
(T) => {
|
|
2467
|
+
t.value = T ?? "#6b6b6b";
|
|
2468
2468
|
}
|
|
2469
2469
|
);
|
|
2470
2470
|
function b() {
|
|
2471
2471
|
s("update:model", { ...e.model, legendColor: t.value });
|
|
2472
2472
|
}
|
|
2473
|
-
function
|
|
2474
|
-
var
|
|
2475
|
-
(
|
|
2476
|
-
}
|
|
2477
|
-
return (
|
|
2478
|
-
const
|
|
2479
|
-
return
|
|
2480
|
-
r(
|
|
2481
|
-
modelValue:
|
|
2482
|
-
"onUpdate:modelValue":
|
|
2473
|
+
function F() {
|
|
2474
|
+
var T;
|
|
2475
|
+
(T = i.value) == null || T.click();
|
|
2476
|
+
}
|
|
2477
|
+
return (T, f) => {
|
|
2478
|
+
const V = $("FmCheckbox"), M = $("FmSelect"), _ = $("FmStepperField"), p = $("FmButton");
|
|
2479
|
+
return g(), A("div", qo, [
|
|
2480
|
+
r(V, {
|
|
2481
|
+
modelValue: x.value,
|
|
2482
|
+
"onUpdate:modelValue": f[0] || (f[0] = (o) => x.value = o),
|
|
2483
2483
|
class: "fm-typo-en-body-lg-400",
|
|
2484
2484
|
value: !1,
|
|
2485
2485
|
label: l(a)("report.section.datasource.legend.showLegend")
|
|
2486
2486
|
}, null, 8, ["modelValue", "label"]),
|
|
2487
|
-
|
|
2488
|
-
r(
|
|
2489
|
-
modelValue:
|
|
2490
|
-
"onUpdate:modelValue":
|
|
2487
|
+
be(h("div", Yo, [
|
|
2488
|
+
r(V, {
|
|
2489
|
+
modelValue: v.value,
|
|
2490
|
+
"onUpdate:modelValue": f[1] || (f[1] = (o) => v.value = o),
|
|
2491
2491
|
label: l(a)("report.section.datasource.legend.usePointStyle"),
|
|
2492
2492
|
value: !1
|
|
2493
2493
|
}, null, 8, ["modelValue", "label"]),
|
|
2494
|
-
r(
|
|
2494
|
+
r(M, {
|
|
2495
2495
|
label: l(a)("report.section.datasource.position.showPosition"),
|
|
2496
|
-
items:
|
|
2497
|
-
"model-value":
|
|
2498
|
-
"onUpdate:modelValue":
|
|
2496
|
+
items: w,
|
|
2497
|
+
"model-value": T.model.legendPosition ?? "top",
|
|
2498
|
+
"onUpdate:modelValue": f[2] || (f[2] = (o) => s("update:model", { ...T.model, legendPosition: o }))
|
|
2499
2499
|
}, null, 8, ["label", "model-value"]),
|
|
2500
|
-
r(
|
|
2501
|
-
modelValue:
|
|
2502
|
-
"onUpdate:modelValue":
|
|
2500
|
+
r(_, {
|
|
2501
|
+
modelValue: C.value,
|
|
2502
|
+
"onUpdate:modelValue": f[3] || (f[3] = (o) => C.value = o),
|
|
2503
2503
|
label: l(a)("report.section.datasource.legend.fontSize"),
|
|
2504
2504
|
max: 24,
|
|
2505
2505
|
min: 1,
|
|
2506
2506
|
type: "number",
|
|
2507
2507
|
placeholder: "Auto"
|
|
2508
2508
|
}, null, 8, ["modelValue", "label"]),
|
|
2509
|
-
|
|
2510
|
-
|
|
2509
|
+
h("p", Ho, P(l(a)("report.section.datasource.legend.color")), 1),
|
|
2510
|
+
h("div", {
|
|
2511
2511
|
class: "fm-field fm-field--sm flex items-center justify-between gap-8 border rounded-md p-2 border-[#c7c7cc] cursor-pointer",
|
|
2512
2512
|
role: "button",
|
|
2513
2513
|
tabindex: "0",
|
|
2514
|
-
onClick:
|
|
2514
|
+
onClick: F,
|
|
2515
2515
|
onKeydown: [
|
|
2516
|
-
|
|
2517
|
-
|
|
2516
|
+
Ye(ge(F, ["prevent"]), ["enter"]),
|
|
2517
|
+
Ye(ge(F, ["prevent"]), ["space"])
|
|
2518
2518
|
]
|
|
2519
2519
|
}, [
|
|
2520
|
-
|
|
2520
|
+
be(h("input", {
|
|
2521
2521
|
ref_key: "colorInputRef",
|
|
2522
2522
|
ref: i,
|
|
2523
|
-
"onUpdate:modelValue":
|
|
2523
|
+
"onUpdate:modelValue": f[4] || (f[4] = (o) => t.value = o),
|
|
2524
2524
|
type: "color",
|
|
2525
2525
|
class: "legend-color-input cursor-pointer"
|
|
2526
2526
|
}, null, 512), [
|
|
2527
|
-
[
|
|
2527
|
+
[vl, t.value]
|
|
2528
2528
|
])
|
|
2529
|
-
], 40,
|
|
2530
|
-
r(
|
|
2529
|
+
], 40, Jo),
|
|
2530
|
+
r(p, {
|
|
2531
2531
|
size: "md",
|
|
2532
2532
|
label: l(a)("report.common.apply"),
|
|
2533
|
-
disabled: t.value ===
|
|
2533
|
+
disabled: t.value === k.value,
|
|
2534
2534
|
onClick: b
|
|
2535
2535
|
}, null, 8, ["label", "disabled"]),
|
|
2536
|
-
|
|
2536
|
+
T.model.legendPosition === "left" || T.model.legendPosition === "right" ? (g(), N(_, {
|
|
2537
2537
|
key: 0,
|
|
2538
|
-
label: l(a)("report.section.datasource.legend.maxLines"),
|
|
2539
|
-
"model-value": k.model.legendMaxLines ?? null,
|
|
2540
|
-
"onUpdate:modelValue": c[5] || (c[5] = (o) => s("update:model", { ...k.model, legendMaxLines: o ?? void 0 })),
|
|
2541
|
-
min: 1,
|
|
2542
|
-
type: "number",
|
|
2543
|
-
placeholder: "Auto"
|
|
2544
|
-
}, null, 8, ["label", "model-value"])) : O("", !0),
|
|
2545
|
-
k.model.legendPosition === "top" || k.model.legendPosition === "bottom" || !k.model.legendPosition ? (v(), M(S, {
|
|
2546
|
-
key: 1,
|
|
2547
|
-
label: l(a)("report.section.datasource.legend.maxHeight"),
|
|
2548
|
-
"model-value": k.model.legendMaxHeight ?? null,
|
|
2549
|
-
"onUpdate:modelValue": c[6] || (c[6] = (o) => s("update:model", { ...k.model, legendMaxHeight: o ?? void 0 })),
|
|
2550
|
-
placeholder: "Auto"
|
|
2551
|
-
}, null, 8, ["label", "model-value"])) : O("", !0),
|
|
2552
|
-
k.model.legendPosition === "left" || k.model.legendPosition === "right" ? (v(), M(S, {
|
|
2553
|
-
key: 2,
|
|
2554
2538
|
label: l(a)("report.section.datasource.legend.maxWidth"),
|
|
2555
|
-
"model-value":
|
|
2556
|
-
"onUpdate:modelValue":
|
|
2539
|
+
"model-value": T.model.legendMaxWidth ?? null,
|
|
2540
|
+
"onUpdate:modelValue": f[5] || (f[5] = (o) => s("update:model", { ...T.model, legendMaxWidth: o ?? void 0 })),
|
|
2557
2541
|
placeholder: "Auto"
|
|
2558
2542
|
}, null, 8, ["label", "model-value"])) : O("", !0)
|
|
2559
2543
|
], 512), [
|
|
2560
|
-
[
|
|
2544
|
+
[he, x.value]
|
|
2561
2545
|
])
|
|
2562
2546
|
]);
|
|
2563
2547
|
};
|
|
2564
2548
|
}
|
|
2565
|
-
}),
|
|
2549
|
+
}), Ko = /* @__PURE__ */ nl(Go, [["__scopeId", "data-v-0f6af12a"]]), Qo = { class: "flex flex-row gap-16" }, Zo = /* @__PURE__ */ ae({
|
|
2566
2550
|
__name: "ChartSizeSection",
|
|
2567
2551
|
props: {
|
|
2568
2552
|
model: {}
|
|
2569
2553
|
},
|
|
2570
2554
|
emits: ["update:model"],
|
|
2571
2555
|
setup(D, { emit: d }) {
|
|
2572
|
-
const e = D, s = d, { t: a } =
|
|
2556
|
+
const e = D, s = d, { t: a } = se(), w = S({
|
|
2573
2557
|
get: () => e.model.chartHeight ?? null,
|
|
2574
|
-
set: (
|
|
2575
|
-
s("update:model", { ...e.model, chartHeight:
|
|
2558
|
+
set: (v) => {
|
|
2559
|
+
s("update:model", { ...e.model, chartHeight: v ?? void 0 });
|
|
2576
2560
|
}
|
|
2577
|
-
}),
|
|
2561
|
+
}), x = S({
|
|
2578
2562
|
get: () => e.model.chartWidth ?? null,
|
|
2579
|
-
set: (
|
|
2580
|
-
s("update:model", { ...e.model, chartWidth:
|
|
2563
|
+
set: (v) => {
|
|
2564
|
+
s("update:model", { ...e.model, chartWidth: v ?? void 0 });
|
|
2581
2565
|
}
|
|
2582
2566
|
});
|
|
2583
|
-
return (
|
|
2584
|
-
const
|
|
2585
|
-
return
|
|
2586
|
-
r(
|
|
2587
|
-
modelValue:
|
|
2588
|
-
"onUpdate:modelValue":
|
|
2567
|
+
return (v, C) => {
|
|
2568
|
+
const k = $("FmStepperField");
|
|
2569
|
+
return g(), A("div", Qo, [
|
|
2570
|
+
r(k, {
|
|
2571
|
+
modelValue: w.value,
|
|
2572
|
+
"onUpdate:modelValue": C[0] || (C[0] = (t) => w.value = t),
|
|
2589
2573
|
type: "number",
|
|
2590
2574
|
label: l(a)("report.section.datasource.chartHeight"),
|
|
2591
2575
|
suffix: "px",
|
|
2592
2576
|
min: 1,
|
|
2593
2577
|
placeholder: "Auto"
|
|
2594
2578
|
}, null, 8, ["modelValue", "label"]),
|
|
2595
|
-
r(
|
|
2596
|
-
modelValue:
|
|
2597
|
-
"onUpdate:modelValue":
|
|
2579
|
+
r(k, {
|
|
2580
|
+
modelValue: x.value,
|
|
2581
|
+
"onUpdate:modelValue": C[1] || (C[1] = (t) => x.value = t),
|
|
2598
2582
|
type: "number",
|
|
2599
2583
|
label: l(a)("report.section.datasource.chartWidth"),
|
|
2600
2584
|
suffix: "px",
|
|
@@ -2604,13 +2588,16 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
2604
2588
|
]);
|
|
2605
2589
|
};
|
|
2606
2590
|
}
|
|
2607
|
-
}),
|
|
2591
|
+
}), et = { class: "flex flex-col gap-8" }, lt = { class: "flex gap-8" }, ot = {
|
|
2592
|
+
key: 0,
|
|
2593
|
+
class: "flex items-center gap-8 text-fm-color-system-info-300"
|
|
2594
|
+
}, tt = { class: "flex flex-col gap-8" }, at = {
|
|
2608
2595
|
key: 1,
|
|
2609
|
-
class: "grid grid-cols-
|
|
2610
|
-
},
|
|
2596
|
+
class: "grid grid-cols-1 gap-8 sm:grid-cols-2"
|
|
2597
|
+
}, nt = ["title"], it = { class: "flex items-center justify-between gap-8" }, st = ["aria-label"], rt = { class: "text-[12px] uppercase leading-none tracking-[0.02em] text-[#6b6b6b]" }, ut = ["value", "onInput"], dt = {
|
|
2611
2598
|
key: 2,
|
|
2612
|
-
class: "
|
|
2613
|
-
},
|
|
2599
|
+
class: "flex flex-col gap-8"
|
|
2600
|
+
}, mt = { class: "mb-8 flex min-w-0 items-center gap-[8px] pb-8" }, ct = { class: "inline-flex h-[22px] min-w-[22px] items-center justify-center rounded-full bg-fm-color-neutral-gray-100 px-[6px] text-[11px] leading-none" }, pt = ["title"], ft = ["title"], vt = ["aria-label"], gt = { class: "text-[12px] uppercase leading-none tracking-[0.02em]" }, bt = ["value", "disabled", "onInput"], yt = /* @__PURE__ */ ae({
|
|
2614
2601
|
__name: "ChartColorSection",
|
|
2615
2602
|
props: {
|
|
2616
2603
|
model: {},
|
|
@@ -2619,144 +2606,146 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
2619
2606
|
},
|
|
2620
2607
|
emits: ["update:model"],
|
|
2621
2608
|
setup(D, { emit: d }) {
|
|
2622
|
-
const e = D, s = d, { t: a } =
|
|
2609
|
+
const e = D, s = d, { t: a } = se(), w = S(() => e.limitToSeriesMode ? [
|
|
2623
2610
|
{
|
|
2624
2611
|
label: a("report.section.datasource.styleTarget.series"),
|
|
2625
|
-
value:
|
|
2612
|
+
value: oe.series
|
|
2626
2613
|
}
|
|
2627
2614
|
] : [
|
|
2628
2615
|
{
|
|
2629
2616
|
label: a("report.section.datasource.styleTarget.series"),
|
|
2630
|
-
value:
|
|
2617
|
+
value: oe.series
|
|
2631
2618
|
},
|
|
2632
2619
|
{
|
|
2633
2620
|
label: a("report.section.datasource.styleTarget.metric"),
|
|
2634
|
-
value:
|
|
2621
|
+
value: oe.metric
|
|
2635
2622
|
},
|
|
2636
2623
|
...i.value.length > 0 ? [
|
|
2637
2624
|
{
|
|
2638
2625
|
label: a("report.section.datasource.styleTarget.breakdown"),
|
|
2639
|
-
value:
|
|
2626
|
+
value: oe.breakdown
|
|
2640
2627
|
}
|
|
2641
2628
|
] : []
|
|
2642
2629
|
]);
|
|
2643
|
-
function
|
|
2644
|
-
return e.limitToSeriesMode ?
|
|
2630
|
+
function x(U) {
|
|
2631
|
+
return e.limitToSeriesMode ? oe.series : U === oe.breakdown ? oe.breakdown : U === oe.metric ? oe.metric : oe.series;
|
|
2645
2632
|
}
|
|
2646
|
-
function
|
|
2633
|
+
function v() {
|
|
2647
2634
|
const U = Array.isArray(e.model.metrics) ? e.model.metrics : [];
|
|
2648
2635
|
if (!e.model.isBlend)
|
|
2649
2636
|
return U;
|
|
2650
2637
|
const L = Array.isArray(e.model.joinDatasources) ? e.model.joinDatasources.flatMap(
|
|
2651
|
-
(
|
|
2638
|
+
(z) => Array.isArray(z == null ? void 0 : z.metrics) ? z.metrics : []
|
|
2652
2639
|
) : [];
|
|
2653
2640
|
return [...U, ...L];
|
|
2654
2641
|
}
|
|
2655
|
-
function
|
|
2656
|
-
var
|
|
2657
|
-
return U ? ((
|
|
2642
|
+
function C(U, L) {
|
|
2643
|
+
var q, K;
|
|
2644
|
+
return U ? ((q = U.label) == null ? void 0 : q.trim()) || ((K = U.name) == null ? void 0 : K.trim()) || `${a("report.section.datasource.styleTarget.metric")} ${L + 1}` : `${a("report.section.datasource.styleTarget.metric")} ${L + 1}`;
|
|
2658
2645
|
}
|
|
2659
|
-
function
|
|
2660
|
-
if (U ===
|
|
2646
|
+
function k(U) {
|
|
2647
|
+
if (U === oe.breakdown)
|
|
2661
2648
|
return [];
|
|
2662
|
-
if (U ===
|
|
2663
|
-
const L =
|
|
2649
|
+
if (U === oe.metric) {
|
|
2650
|
+
const L = v();
|
|
2664
2651
|
if (L.length > 0)
|
|
2665
|
-
return L.map((
|
|
2652
|
+
return L.map((z, q) => C(z, q));
|
|
2666
2653
|
}
|
|
2667
|
-
return
|
|
2668
|
-
(L,
|
|
2654
|
+
return fe.map(
|
|
2655
|
+
(L, z) => `${a("report.section.datasource.chartColor.series")} ${z + 1}`
|
|
2669
2656
|
);
|
|
2670
2657
|
}
|
|
2671
|
-
const t =
|
|
2672
|
-
const U =
|
|
2673
|
-
return U.length === 0 ? [a("report.section.datasource.styleTarget.metric")] : U.map((L,
|
|
2674
|
-
}), i =
|
|
2658
|
+
const t = S(() => {
|
|
2659
|
+
const U = v();
|
|
2660
|
+
return U.length === 0 ? [a("report.section.datasource.styleTarget.metric")] : U.map((L, z) => C(L, z));
|
|
2661
|
+
}), i = S(
|
|
2675
2662
|
() => Array.isArray(e.model.chartBreakdownDimensionValues) ? e.model.chartBreakdownDimensionValues.filter((U) => !!U) : []
|
|
2676
2663
|
);
|
|
2677
2664
|
function b(U, L) {
|
|
2678
|
-
const
|
|
2679
|
-
const
|
|
2680
|
-
return Math.round(
|
|
2665
|
+
const z = M(U) ?? "#000000", q = (K) => {
|
|
2666
|
+
const Y = Number.parseInt(z.slice(K, K + 2), 16);
|
|
2667
|
+
return Math.round(Y + (255 - Y) * L).toString(16).padStart(2, "0").toUpperCase();
|
|
2681
2668
|
};
|
|
2682
|
-
return `#${
|
|
2669
|
+
return `#${q(1)}${q(3)}${q(5)}`;
|
|
2683
2670
|
}
|
|
2684
|
-
function
|
|
2671
|
+
function F(U) {
|
|
2685
2672
|
return Math.min(0.55 + (U - 1) * 0.18, 0.95);
|
|
2686
2673
|
}
|
|
2687
|
-
function
|
|
2688
|
-
return U *
|
|
2674
|
+
function T(U, L, z) {
|
|
2675
|
+
return U * z + L;
|
|
2689
2676
|
}
|
|
2690
|
-
function
|
|
2691
|
-
const
|
|
2692
|
-
return U.length === 0 ||
|
|
2693
|
-
const
|
|
2694
|
-
return L.map((
|
|
2695
|
-
const
|
|
2696
|
-
return
|
|
2677
|
+
function f(U, L, z, q) {
|
|
2678
|
+
const K = L.length;
|
|
2679
|
+
return U.length === 0 || K <= 0 ? [] : U.flatMap((Y, H) => {
|
|
2680
|
+
const pe = fe[H % fe.length], ne = z == null ? void 0 : z[T(H, 0, K)], Fe = M(ne) ?? pe;
|
|
2681
|
+
return L.map((Jt, Ue) => {
|
|
2682
|
+
const cl = T(H, Ue, K), qe = Ue === 0 ? Fe : b(Fe, F(Ue));
|
|
2683
|
+
return q && Ue > 0 ? qe : M(z == null ? void 0 : z[cl]) ?? qe;
|
|
2697
2684
|
});
|
|
2698
2685
|
});
|
|
2699
2686
|
}
|
|
2700
|
-
const
|
|
2701
|
-
function
|
|
2687
|
+
const V = /^#([0-9a-fA-F]{3}|[0-9a-fA-F]{6})$/;
|
|
2688
|
+
function M(U) {
|
|
2702
2689
|
if (!U)
|
|
2703
2690
|
return null;
|
|
2704
2691
|
const L = U.trim();
|
|
2705
|
-
if (!
|
|
2692
|
+
if (!V.test(L))
|
|
2706
2693
|
return null;
|
|
2707
2694
|
if (L.length === 4) {
|
|
2708
|
-
const
|
|
2709
|
-
return `#${
|
|
2695
|
+
const z = L.charAt(1), q = L.charAt(2), K = L.charAt(3);
|
|
2696
|
+
return `#${z}${z}${q}${q}${K}${K}`.toUpperCase();
|
|
2710
2697
|
}
|
|
2711
2698
|
return L.toUpperCase();
|
|
2712
2699
|
}
|
|
2713
|
-
function
|
|
2700
|
+
function _(U, L) {
|
|
2714
2701
|
return !Array.isArray(U) || U.length === 0 ? Array.from({ length: L }).map(
|
|
2715
|
-
(
|
|
2716
|
-
) : Array.from({ length: L }).map((
|
|
2717
|
-
const
|
|
2718
|
-
return
|
|
2702
|
+
(z, q) => fe[q % fe.length]
|
|
2703
|
+
) : Array.from({ length: L }).map((z, q) => {
|
|
2704
|
+
const K = fe[q % fe.length];
|
|
2705
|
+
return M(U[q]) ?? K;
|
|
2719
2706
|
});
|
|
2720
2707
|
}
|
|
2721
|
-
function
|
|
2708
|
+
function p(U, L) {
|
|
2722
2709
|
if (L <= 0)
|
|
2723
2710
|
return [];
|
|
2724
|
-
const
|
|
2725
|
-
for (let
|
|
2726
|
-
const
|
|
2727
|
-
Number.isInteger(
|
|
2711
|
+
const z = Array.from({ length: L }, () => 0), q = /* @__PURE__ */ new Set();
|
|
2712
|
+
for (let Y = 0; Y < L; Y++) {
|
|
2713
|
+
const H = Number(U == null ? void 0 : U[Y]);
|
|
2714
|
+
Number.isInteger(H) && H >= 1 && H <= L && !q.has(H) && (z[Y] = H, q.add(H));
|
|
2728
2715
|
}
|
|
2729
|
-
let
|
|
2730
|
-
for (let
|
|
2731
|
-
if (
|
|
2732
|
-
for (;
|
|
2733
|
-
|
|
2734
|
-
|
|
2716
|
+
let K = 1;
|
|
2717
|
+
for (let Y = 0; Y < L; Y++)
|
|
2718
|
+
if (z[Y] === 0) {
|
|
2719
|
+
for (; q.has(K) && K <= L; )
|
|
2720
|
+
K++;
|
|
2721
|
+
z[Y] = Math.min(K, L), q.add(z[Y]);
|
|
2735
2722
|
}
|
|
2736
|
-
return
|
|
2723
|
+
return z;
|
|
2737
2724
|
}
|
|
2738
|
-
const o =
|
|
2739
|
-
() =>
|
|
2740
|
-
), n =
|
|
2725
|
+
const o = S(
|
|
2726
|
+
() => x(e.model.chartColorBinding)
|
|
2727
|
+
), n = S(() => k(B.value)), c = S(
|
|
2741
2728
|
() => Array.from({ length: n.value.length }).map((U, L) => ({
|
|
2742
2729
|
label: `L${L + 1}`,
|
|
2743
2730
|
value: L + 1
|
|
2744
2731
|
}))
|
|
2745
|
-
), u =
|
|
2746
|
-
() =>
|
|
2747
|
-
), y =
|
|
2748
|
-
() =>
|
|
2732
|
+
), u = S(() => typeof e.showLayerControl == "boolean" ? e.showLayerControl : !!e.model.stackBarOverlap), m = S(
|
|
2733
|
+
() => _(e.model.chartColors, k(o.value).length)
|
|
2734
|
+
), y = S(
|
|
2735
|
+
() => p(
|
|
2749
2736
|
e.model.chartColorLayers,
|
|
2750
|
-
|
|
2737
|
+
k(o.value).length
|
|
2751
2738
|
)
|
|
2752
|
-
),
|
|
2753
|
-
() =>
|
|
2739
|
+
), j = S(
|
|
2740
|
+
() => e.model.chartUseSecondaryMetricShades !== !1
|
|
2741
|
+
), Q = S(
|
|
2742
|
+
() => f(
|
|
2754
2743
|
i.value,
|
|
2755
2744
|
t.value,
|
|
2756
2745
|
e.model.chartBreakdownColors,
|
|
2757
|
-
|
|
2746
|
+
j.value
|
|
2758
2747
|
)
|
|
2759
|
-
),
|
|
2748
|
+
), E = ee([]), X = ee([]), J = ee([]), le = ee(!0), B = ee(oe.series), G = ee(!0);
|
|
2760
2749
|
ye(
|
|
2761
2750
|
[
|
|
2762
2751
|
() => e.model.chartColors,
|
|
@@ -2769,240 +2758,287 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
2769
2758
|
() => e.model.joinDatasources
|
|
2770
2759
|
],
|
|
2771
2760
|
([U, L]) => {
|
|
2772
|
-
B.value =
|
|
2773
|
-
const
|
|
2774
|
-
|
|
2775
|
-
U,
|
|
2776
|
-
j
|
|
2777
|
-
), X.value = f(e.model.chartColorLayers, j), te.value = e.model.chartUseSecondaryMetricShades !== !1, Y.value = c(
|
|
2761
|
+
B.value = x(L);
|
|
2762
|
+
const z = k(B.value).length;
|
|
2763
|
+
E.value = _(U, z), X.value = p(e.model.chartColorLayers, z), le.value = e.model.chartUseSecondaryMetricShades !== !1, J.value = f(
|
|
2778
2764
|
i.value,
|
|
2779
2765
|
t.value,
|
|
2780
2766
|
e.model.chartBreakdownColors,
|
|
2781
|
-
|
|
2767
|
+
le.value
|
|
2782
2768
|
);
|
|
2783
2769
|
},
|
|
2784
2770
|
{ immediate: !0, deep: !0 }
|
|
2785
2771
|
);
|
|
2786
|
-
const
|
|
2787
|
-
function
|
|
2788
|
-
const
|
|
2789
|
-
|
|
2772
|
+
const te = S(() => B.value !== o.value || E.value.length !== m.value.length || X.value.length !== y.value.length || X.value.some((U, L) => U !== y.value[L]) || le.value !== j.value || J.value.length !== Q.value.length || J.value.some((U, L) => U !== Q.value[L]) ? !0 : E.value.some((U, L) => U !== m.value[L]));
|
|
2773
|
+
function ve(U, L) {
|
|
2774
|
+
const z = [...E.value], q = fe[U % fe.length];
|
|
2775
|
+
z[U] = M(L) ?? q, E.value = z;
|
|
2790
2776
|
}
|
|
2791
|
-
function
|
|
2777
|
+
function W(U) {
|
|
2792
2778
|
if (e.limitToSeriesMode)
|
|
2793
2779
|
return;
|
|
2794
|
-
const L =
|
|
2780
|
+
const L = x(U);
|
|
2795
2781
|
if (L === B.value)
|
|
2796
2782
|
return;
|
|
2797
|
-
const
|
|
2798
|
-
B.value = L,
|
|
2783
|
+
const z = k(L).length;
|
|
2784
|
+
B.value = L, E.value = _(E.value, z), X.value = p(X.value, z), L === oe.breakdown && (J.value = f(
|
|
2799
2785
|
i.value,
|
|
2800
2786
|
t.value,
|
|
2801
|
-
|
|
2802
|
-
|
|
2787
|
+
J.value,
|
|
2788
|
+
le.value
|
|
2803
2789
|
));
|
|
2804
2790
|
}
|
|
2805
|
-
function
|
|
2806
|
-
const
|
|
2807
|
-
if (
|
|
2791
|
+
function de(U, L) {
|
|
2792
|
+
const z = X.value.length;
|
|
2793
|
+
if (z <= 0)
|
|
2808
2794
|
return;
|
|
2809
|
-
const
|
|
2810
|
-
if (!Number.isInteger(
|
|
2795
|
+
const q = Number(L);
|
|
2796
|
+
if (!Number.isInteger(q) || q < 1 || q > z)
|
|
2811
2797
|
return;
|
|
2812
|
-
const
|
|
2813
|
-
if (
|
|
2798
|
+
const K = [...X.value], Y = K[U];
|
|
2799
|
+
if (Y === q)
|
|
2814
2800
|
return;
|
|
2815
|
-
const
|
|
2816
|
-
(
|
|
2801
|
+
const H = K.findIndex(
|
|
2802
|
+
(pe, ne) => ne !== U && pe === q
|
|
2817
2803
|
);
|
|
2818
|
-
|
|
2804
|
+
H >= 0 && (K[H] = Y), K[U] = q, X.value = K;
|
|
2819
2805
|
}
|
|
2820
|
-
function
|
|
2821
|
-
const
|
|
2822
|
-
|
|
2806
|
+
function $e(U, L) {
|
|
2807
|
+
const z = L.target;
|
|
2808
|
+
z && ve(U, z.value);
|
|
2823
2809
|
}
|
|
2824
|
-
function
|
|
2825
|
-
const
|
|
2826
|
-
if (!
|
|
2810
|
+
function De(U, L, z) {
|
|
2811
|
+
const q = z.target;
|
|
2812
|
+
if (!q)
|
|
2827
2813
|
return;
|
|
2828
|
-
const
|
|
2829
|
-
if (!
|
|
2814
|
+
const K = M(q.value);
|
|
2815
|
+
if (!K)
|
|
2830
2816
|
return;
|
|
2831
|
-
const
|
|
2832
|
-
if (
|
|
2817
|
+
const Y = t.value.length;
|
|
2818
|
+
if (Y <= 0)
|
|
2833
2819
|
return;
|
|
2834
|
-
const
|
|
2835
|
-
if (
|
|
2836
|
-
for (let
|
|
2837
|
-
const
|
|
2838
|
-
|
|
2820
|
+
const H = T(U, L, Y), pe = [...J.value];
|
|
2821
|
+
if (pe[H] = K, le.value && L === 0)
|
|
2822
|
+
for (let ne = 1; ne < Y; ne++) {
|
|
2823
|
+
const Fe = T(U, ne, Y);
|
|
2824
|
+
pe[Fe] = b(K, F(ne));
|
|
2839
2825
|
}
|
|
2840
|
-
|
|
2826
|
+
J.value = pe;
|
|
2841
2827
|
}
|
|
2842
|
-
function
|
|
2843
|
-
|
|
2828
|
+
function Be(U) {
|
|
2829
|
+
le.value = U, J.value = f(
|
|
2844
2830
|
i.value,
|
|
2845
2831
|
t.value,
|
|
2846
|
-
|
|
2847
|
-
|
|
2832
|
+
J.value,
|
|
2833
|
+
le.value
|
|
2848
2834
|
);
|
|
2849
2835
|
}
|
|
2850
|
-
function
|
|
2851
|
-
B.value =
|
|
2836
|
+
function Z() {
|
|
2837
|
+
B.value = oe.series, E.value = _(void 0, fe.length), X.value = p(void 0, fe.length), le.value = !0, J.value = f(
|
|
2852
2838
|
i.value,
|
|
2853
2839
|
t.value,
|
|
2854
2840
|
void 0,
|
|
2855
2841
|
!0
|
|
2856
2842
|
);
|
|
2857
2843
|
}
|
|
2858
|
-
function
|
|
2859
|
-
const U = B.value ===
|
|
2860
|
-
(
|
|
2861
|
-
),
|
|
2844
|
+
function dl() {
|
|
2845
|
+
const U = B.value === oe.series, L = E.value.every(
|
|
2846
|
+
(Y, H) => Y === fe[H % fe.length]
|
|
2847
|
+
), z = X.value.every((Y, H) => Y === H + 1), q = f(
|
|
2862
2848
|
i.value,
|
|
2863
2849
|
t.value,
|
|
2864
2850
|
void 0,
|
|
2865
|
-
|
|
2866
|
-
),
|
|
2851
|
+
le.value
|
|
2852
|
+
), K = J.value.length === q.length && J.value.every((Y, H) => Y === q[H]);
|
|
2867
2853
|
s("update:model", {
|
|
2868
2854
|
...e.model,
|
|
2869
2855
|
chartColorBinding: U ? void 0 : B.value,
|
|
2870
|
-
chartColors: L ? void 0 : [...
|
|
2871
|
-
chartColorLayers:
|
|
2872
|
-
chartBreakdownColors:
|
|
2873
|
-
chartUseSecondaryMetricShades:
|
|
2856
|
+
chartColors: L ? void 0 : [...E.value],
|
|
2857
|
+
chartColorLayers: z ? void 0 : [...X.value],
|
|
2858
|
+
chartBreakdownColors: K ? void 0 : [...J.value],
|
|
2859
|
+
chartUseSecondaryMetricShades: le.value
|
|
2874
2860
|
});
|
|
2875
2861
|
}
|
|
2862
|
+
function ml() {
|
|
2863
|
+
G.value = !G.value;
|
|
2864
|
+
}
|
|
2876
2865
|
return (U, L) => {
|
|
2877
|
-
const
|
|
2878
|
-
return
|
|
2879
|
-
|
|
2880
|
-
|
|
2881
|
-
|
|
2882
|
-
|
|
2866
|
+
const z = $("FmButton"), q = $("FmSelect"), K = $("FmCheckbox");
|
|
2867
|
+
return g(), A("div", et, [
|
|
2868
|
+
h("div", lt, [
|
|
2869
|
+
r(z, {
|
|
2870
|
+
variant: "tertiary",
|
|
2871
|
+
size: "md",
|
|
2872
|
+
class: "min-w-0 flex-1 !justify-start",
|
|
2873
|
+
label: l(a)("report.section.datasource.chartColor.title"),
|
|
2874
|
+
"prepend-icon": G.value ? "expand_less" : "expand_more",
|
|
2875
|
+
"aria-expanded": G.value ? "true" : "false",
|
|
2876
|
+
onClick: ml
|
|
2877
|
+
}, null, 8, ["label", "prepend-icon", "aria-expanded"]),
|
|
2878
|
+
G.value ? (g(), A("div", ot, [
|
|
2879
|
+
r(z, {
|
|
2883
2880
|
variant: "tertiary",
|
|
2884
2881
|
"text-color": "text-fm-color-system-info-300",
|
|
2885
2882
|
size: "md",
|
|
2886
2883
|
label: l(a)("report.section.datasource.chartColor.reset"),
|
|
2887
|
-
onClick:
|
|
2884
|
+
onClick: Z
|
|
2888
2885
|
}, null, 8, ["label"])
|
|
2889
|
-
])
|
|
2886
|
+
])) : O("", !0)
|
|
2890
2887
|
]),
|
|
2891
|
-
|
|
2892
|
-
|
|
2893
|
-
|
|
2894
|
-
|
|
2895
|
-
|
|
2896
|
-
|
|
2897
|
-
|
|
2898
|
-
|
|
2899
|
-
|
|
2900
|
-
|
|
2901
|
-
|
|
2902
|
-
|
|
2903
|
-
|
|
2904
|
-
|
|
2905
|
-
(
|
|
2906
|
-
|
|
2907
|
-
class: "
|
|
2908
|
-
|
|
2909
|
-
|
|
2910
|
-
|
|
2911
|
-
|
|
2912
|
-
|
|
2913
|
-
|
|
2914
|
-
|
|
2915
|
-
|
|
2916
|
-
|
|
2917
|
-
|
|
2918
|
-
|
|
2919
|
-
|
|
2920
|
-
|
|
2921
|
-
|
|
2922
|
-
|
|
2923
|
-
|
|
2924
|
-
|
|
2925
|
-
|
|
2926
|
-
|
|
2927
|
-
|
|
2928
|
-
|
|
2929
|
-
|
|
2930
|
-
|
|
2931
|
-
|
|
2932
|
-
|
|
2933
|
-
|
|
2934
|
-
|
|
2935
|
-
|
|
2936
|
-
|
|
2937
|
-
|
|
2938
|
-
|
|
2939
|
-
|
|
2940
|
-
|
|
2941
|
-
|
|
2942
|
-
|
|
2943
|
-
|
|
2944
|
-
|
|
2945
|
-
|
|
2946
|
-
|
|
2947
|
-
|
|
2948
|
-
|
|
2949
|
-
|
|
2950
|
-
|
|
2951
|
-
|
|
2952
|
-
|
|
2953
|
-
|
|
2954
|
-
|
|
2955
|
-
|
|
2956
|
-
|
|
2957
|
-
|
|
2958
|
-
|
|
2888
|
+
be(h("div", tt, [
|
|
2889
|
+
r(q, {
|
|
2890
|
+
"model-value": B.value,
|
|
2891
|
+
items: w.value,
|
|
2892
|
+
"onUpdate:modelValue": W
|
|
2893
|
+
}, null, 8, ["model-value", "items"]),
|
|
2894
|
+
B.value === l(oe).breakdown ? (g(), N(K, {
|
|
2895
|
+
key: 0,
|
|
2896
|
+
"model-value": le.value,
|
|
2897
|
+
value: !1,
|
|
2898
|
+
label: l(a)("report.section.datasource.chartColor.secondaryMetricAutoShade"),
|
|
2899
|
+
"onUpdate:modelValue": L[0] || (L[0] = (Y) => Be(!!Y)),
|
|
2900
|
+
class: "p-4"
|
|
2901
|
+
}, null, 8, ["model-value", "label"])) : O("", !0),
|
|
2902
|
+
r(z, {
|
|
2903
|
+
size: "md",
|
|
2904
|
+
class: "mt-2",
|
|
2905
|
+
label: l(a)("report.common.apply"),
|
|
2906
|
+
disabled: !te.value,
|
|
2907
|
+
onClick: dl
|
|
2908
|
+
}, null, 8, ["label", "disabled"]),
|
|
2909
|
+
B.value !== l(oe).breakdown ? (g(), A("div", at, [
|
|
2910
|
+
(g(!0), A(re, null, we(E.value, (Y, H) => (g(), A("div", {
|
|
2911
|
+
key: H,
|
|
2912
|
+
class: "fm-shadow-light-100 flex flex-col gap-8 rounded-md border border-fm-color-neutral-gray-100 p-10"
|
|
2913
|
+
}, [
|
|
2914
|
+
h("span", {
|
|
2915
|
+
class: "fm-typo-en-body-md-400 line-clamp-2 break-words",
|
|
2916
|
+
title: n.value[H] || `${l(a)("report.section.datasource.chartColor.color")} ${H + 1}`
|
|
2917
|
+
}, P(n.value[H] || `${l(a)("report.section.datasource.chartColor.color")} ${H + 1}`), 9, nt),
|
|
2918
|
+
h("div", it, [
|
|
2919
|
+
u.value ? (g(), N(q, {
|
|
2920
|
+
key: 0,
|
|
2921
|
+
class: "min-w-[92px]",
|
|
2922
|
+
"model-value": X.value[H],
|
|
2923
|
+
items: c.value,
|
|
2924
|
+
"onUpdate:modelValue": (pe) => de(H, pe)
|
|
2925
|
+
}, null, 8, ["model-value", "items", "onUpdate:modelValue"])) : O("", !0),
|
|
2926
|
+
h("label", {
|
|
2927
|
+
class: "relative inline-flex min-h-[34px] cursor-pointer items-center gap-[8px] rounded-[8px] border border-[#d8d8d8] bg-white py-[4px] pl-[4px] pr-[8px]",
|
|
2928
|
+
"aria-label": `Color ${H + 1}`
|
|
2929
|
+
}, [
|
|
2930
|
+
h("span", {
|
|
2931
|
+
class: "inline-block h-[20px] w-[28px] rounded-[4px] border border-[#cfcfcf]",
|
|
2932
|
+
style: Re({ backgroundColor: Y })
|
|
2933
|
+
}, null, 4),
|
|
2934
|
+
h("span", rt, P(Y), 1),
|
|
2935
|
+
h("input", {
|
|
2936
|
+
type: "color",
|
|
2937
|
+
value: Y,
|
|
2938
|
+
class: "absolute inset-0 cursor-pointer opacity-0",
|
|
2939
|
+
onInput: (pe) => $e(H, pe)
|
|
2940
|
+
}, null, 40, ut)
|
|
2941
|
+
], 8, st)
|
|
2942
|
+
])
|
|
2943
|
+
]))), 128))
|
|
2944
|
+
])) : (g(), A("div", dt, [
|
|
2945
|
+
(g(!0), A(re, null, we(i.value, (Y, H) => (g(), A("div", {
|
|
2946
|
+
key: Y,
|
|
2947
|
+
class: "fm-shadow-light-100 rounded-md border border-fm-color-neutral-gray-100 bg-fm-color-neutral-white p-10"
|
|
2948
|
+
}, [
|
|
2949
|
+
h("div", mt, [
|
|
2950
|
+
h("span", ct, P(H + 1), 1),
|
|
2951
|
+
h("span", {
|
|
2952
|
+
class: "fm-typo-en-body-md-400 min-w-0 overflow-hidden text-ellipsis whitespace-nowrap",
|
|
2953
|
+
title: Y
|
|
2954
|
+
}, P(Y), 9, pt)
|
|
2955
|
+
]),
|
|
2956
|
+
(g(!0), A(re, null, we(t.value, (pe, ne) => (g(), A("div", {
|
|
2957
|
+
key: `${Y}-${pe}-${ne}`,
|
|
2958
|
+
class: "flex items-center justify-between gap-8 py-4"
|
|
2959
|
+
}, [
|
|
2960
|
+
h("span", {
|
|
2961
|
+
class: "fm-typo-en-body-md-400 min-w-0 flex-1 overflow-hidden text-ellipsis whitespace-nowrap",
|
|
2962
|
+
title: pe
|
|
2963
|
+
}, P(pe), 9, ft),
|
|
2964
|
+
h("label", {
|
|
2965
|
+
class: _e(["relative inline-flex min-h-[34px] w-full max-w-[126px] items-center gap-[8px] rounded-[8px] border border-[#d8d8d8] bg-white py-[4px] pl-[4px] pr-[8px]", {
|
|
2966
|
+
"cursor-not-allowed opacity-[0.55]": le.value && ne > 0,
|
|
2967
|
+
"cursor-pointer": !(le.value && ne > 0)
|
|
2968
|
+
}]),
|
|
2969
|
+
"aria-label": `Breakdown color ${H + 1}-${ne + 1}`
|
|
2970
|
+
}, [
|
|
2971
|
+
h("span", {
|
|
2972
|
+
class: "inline-block h-[20px] w-[28px] rounded-[4px] border border-[#cfcfcf]",
|
|
2973
|
+
style: Re({
|
|
2974
|
+
backgroundColor: J.value[T(H, ne, t.value.length)]
|
|
2975
|
+
})
|
|
2976
|
+
}, null, 4),
|
|
2977
|
+
h("span", gt, P(J.value[T(H, ne, t.value.length)]), 1),
|
|
2978
|
+
h("input", {
|
|
2979
|
+
type: "color",
|
|
2980
|
+
value: J.value[T(H, ne, t.value.length)],
|
|
2981
|
+
class: _e(["absolute inset-0 opacity-0", {
|
|
2982
|
+
"cursor-not-allowed": le.value && ne > 0,
|
|
2983
|
+
"cursor-pointer": !(le.value && ne > 0)
|
|
2984
|
+
}]),
|
|
2985
|
+
disabled: le.value && ne > 0,
|
|
2986
|
+
onInput: (Fe) => De(H, ne, Fe)
|
|
2987
|
+
}, null, 42, bt)
|
|
2988
|
+
], 10, vt)
|
|
2989
|
+
]))), 128))
|
|
2990
|
+
]))), 128))
|
|
2991
|
+
]))
|
|
2992
|
+
], 512), [
|
|
2993
|
+
[he, G.value]
|
|
2994
|
+
])
|
|
2959
2995
|
]);
|
|
2960
2996
|
};
|
|
2961
2997
|
}
|
|
2962
|
-
}),
|
|
2998
|
+
}), ht = { class: "flex flex-col gap-8" }, wt = { class: "flex items-center justify-between" }, Ct = { class: "fm-typo-en-body-lg-600" }, Vt = { class: "flex items-center gap-8 text-fm-color-system-info-300" }, xt = { class: "grid grid-cols-2 gap-8" }, Ft = { class: "flex items-center gap-8" }, kt = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, _t = /* @__PURE__ */ ae({
|
|
2963
2999
|
__name: "ChartLineStyleSection",
|
|
2964
3000
|
props: {
|
|
2965
3001
|
model: {}
|
|
2966
3002
|
},
|
|
2967
3003
|
emits: ["update:model"],
|
|
2968
3004
|
setup(D, { emit: d }) {
|
|
2969
|
-
const e = D, s = d, { t: a } =
|
|
3005
|
+
const e = D, s = d, { t: a } = se(), w = S(() => [
|
|
2970
3006
|
{
|
|
2971
3007
|
label: a("report.section.datasource.styleTarget.series"),
|
|
2972
|
-
value:
|
|
3008
|
+
value: oe.series
|
|
2973
3009
|
},
|
|
2974
3010
|
{
|
|
2975
3011
|
label: a("report.section.datasource.styleTarget.metric"),
|
|
2976
|
-
value:
|
|
3012
|
+
value: oe.metric
|
|
2977
3013
|
}
|
|
2978
3014
|
]);
|
|
2979
|
-
function
|
|
2980
|
-
return m && typeof m == "object" && "value" in m ?
|
|
3015
|
+
function x(m) {
|
|
3016
|
+
return m && typeof m == "object" && "value" in m ? x(m.value) : m === oe.metric ? oe.metric : oe.series;
|
|
2981
3017
|
}
|
|
2982
|
-
function
|
|
2983
|
-
var
|
|
2984
|
-
return m ? ((
|
|
3018
|
+
function v(m, y) {
|
|
3019
|
+
var Q, E;
|
|
3020
|
+
return m ? ((Q = m.label) == null ? void 0 : Q.trim()) || ((E = m.name) == null ? void 0 : E.trim()) || `${a("report.section.datasource.styleTarget.metric")} ${y + 1}` : `${a("report.section.datasource.styleTarget.metric")} ${y + 1}`;
|
|
2985
3021
|
}
|
|
2986
|
-
function
|
|
3022
|
+
function C() {
|
|
2987
3023
|
const m = Array.isArray(e.model.metrics) ? e.model.metrics : [];
|
|
2988
3024
|
if (!e.model.isBlend)
|
|
2989
3025
|
return m;
|
|
2990
3026
|
const y = Array.isArray(e.model.joinDatasources) ? e.model.joinDatasources.flatMap(
|
|
2991
|
-
(
|
|
3027
|
+
(j) => Array.isArray(j == null ? void 0 : j.metrics) ? j.metrics : []
|
|
2992
3028
|
) : [];
|
|
2993
3029
|
return [...m, ...y];
|
|
2994
3030
|
}
|
|
2995
|
-
function
|
|
2996
|
-
if (m ===
|
|
2997
|
-
const y =
|
|
3031
|
+
function k(m) {
|
|
3032
|
+
if (m === oe.metric) {
|
|
3033
|
+
const y = C();
|
|
2998
3034
|
if (y.length > 0)
|
|
2999
|
-
return y.map((
|
|
3035
|
+
return y.map((j, Q) => v(j, Q));
|
|
3000
3036
|
}
|
|
3001
|
-
return
|
|
3002
|
-
(y,
|
|
3037
|
+
return fe.map(
|
|
3038
|
+
(y, j) => `${a("report.section.datasource.lineStyle.series")} ${j + 1}`
|
|
3003
3039
|
);
|
|
3004
3040
|
}
|
|
3005
|
-
const t =
|
|
3041
|
+
const t = S(() => [
|
|
3006
3042
|
{
|
|
3007
3043
|
label: a("report.section.datasource.lineStyle.solid"),
|
|
3008
3044
|
value: "solid"
|
|
@@ -3022,16 +3058,18 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
3022
3058
|
function b(m) {
|
|
3023
3059
|
return m === "dashed" ? "line-style-icon--dashed" : m === "dotted" ? "line-style-icon--dotted" : "line-style-icon--solid";
|
|
3024
3060
|
}
|
|
3025
|
-
function
|
|
3061
|
+
function F(m, y) {
|
|
3026
3062
|
return !Array.isArray(m) || m.length === 0 ? Array.from({ length: y }).map(
|
|
3027
|
-
(
|
|
3028
|
-
) : Array.from({ length: y }).map(
|
|
3029
|
-
|
|
3030
|
-
|
|
3031
|
-
|
|
3032
|
-
|
|
3033
|
-
() => x(e.model.
|
|
3034
|
-
),
|
|
3063
|
+
(j, Q) => Ke[Q] ?? "solid"
|
|
3064
|
+
) : Array.from({ length: y }).map(
|
|
3065
|
+
(j, Q) => i(m[Q])
|
|
3066
|
+
);
|
|
3067
|
+
}
|
|
3068
|
+
const T = S(
|
|
3069
|
+
() => x(e.model.lineStyleBinding)
|
|
3070
|
+
), f = S(() => k(_.value)), V = S(
|
|
3071
|
+
() => F(e.model.lineStyles, k(T.value).length)
|
|
3072
|
+
), M = ee([]), _ = ee(oe.series);
|
|
3035
3073
|
ye(
|
|
3036
3074
|
[
|
|
3037
3075
|
() => e.model.lineStyles,
|
|
@@ -3041,92 +3079,92 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
3041
3079
|
() => e.model.joinDatasources
|
|
3042
3080
|
],
|
|
3043
3081
|
([m, y]) => {
|
|
3044
|
-
|
|
3082
|
+
_.value = x(y), M.value = F(
|
|
3045
3083
|
m,
|
|
3046
|
-
_
|
|
3084
|
+
k(_.value).length
|
|
3047
3085
|
);
|
|
3048
3086
|
},
|
|
3049
3087
|
{ immediate: !0, deep: !0 }
|
|
3050
3088
|
);
|
|
3051
|
-
const
|
|
3089
|
+
const p = S(() => _.value !== T.value || M.value.length !== V.value.length ? !0 : M.value.some((m, y) => m !== V.value[y]));
|
|
3052
3090
|
function o(m, y) {
|
|
3053
|
-
const
|
|
3054
|
-
|
|
3091
|
+
const j = [...M.value];
|
|
3092
|
+
j[m] = i(y), M.value = j;
|
|
3055
3093
|
}
|
|
3056
3094
|
function n(m) {
|
|
3057
|
-
const y =
|
|
3058
|
-
if (y ===
|
|
3095
|
+
const y = x(m);
|
|
3096
|
+
if (y === _.value)
|
|
3059
3097
|
return;
|
|
3060
|
-
const
|
|
3061
|
-
|
|
3098
|
+
const j = k(y).length;
|
|
3099
|
+
_.value = y, M.value = F(M.value, j);
|
|
3062
3100
|
}
|
|
3063
|
-
function
|
|
3064
|
-
|
|
3101
|
+
function c() {
|
|
3102
|
+
_.value = oe.series, M.value = [...Ke];
|
|
3065
3103
|
}
|
|
3066
3104
|
function u() {
|
|
3067
|
-
const m =
|
|
3105
|
+
const m = _.value === oe.series, y = M.value.every((j) => j === "solid");
|
|
3068
3106
|
s("update:model", {
|
|
3069
3107
|
...e.model,
|
|
3070
|
-
lineStyleBinding: m ? void 0 :
|
|
3071
|
-
lineStyles: y ? void 0 : [...
|
|
3108
|
+
lineStyleBinding: m ? void 0 : _.value,
|
|
3109
|
+
lineStyles: y ? void 0 : [...M.value]
|
|
3072
3110
|
});
|
|
3073
3111
|
}
|
|
3074
3112
|
return (m, y) => {
|
|
3075
|
-
const
|
|
3076
|
-
return
|
|
3077
|
-
|
|
3078
|
-
|
|
3079
|
-
|
|
3080
|
-
r(
|
|
3113
|
+
const j = $("FmButton"), Q = $("FmSelect");
|
|
3114
|
+
return g(), A("div", ht, [
|
|
3115
|
+
h("div", wt, [
|
|
3116
|
+
h("p", Ct, P(l(a)("report.section.datasource.lineStyle.title")), 1),
|
|
3117
|
+
h("div", Vt, [
|
|
3118
|
+
r(j, {
|
|
3081
3119
|
variant: "tertiary",
|
|
3082
3120
|
"text-color": "text-fm-color-system-info-300",
|
|
3083
3121
|
size: "md",
|
|
3084
3122
|
label: l(a)("report.section.datasource.lineStyle.reset"),
|
|
3085
|
-
onClick:
|
|
3123
|
+
onClick: c
|
|
3086
3124
|
}, null, 8, ["label"])
|
|
3087
3125
|
])
|
|
3088
3126
|
]),
|
|
3089
|
-
r(
|
|
3090
|
-
"model-value":
|
|
3091
|
-
items:
|
|
3127
|
+
r(Q, {
|
|
3128
|
+
"model-value": _.value,
|
|
3129
|
+
items: w.value,
|
|
3092
3130
|
label: l(a)("report.section.datasource.styleTarget.title"),
|
|
3093
3131
|
"onUpdate:modelValue": n
|
|
3094
3132
|
}, null, 8, ["model-value", "items", "label"]),
|
|
3095
|
-
|
|
3096
|
-
(
|
|
3133
|
+
h("div", xt, [
|
|
3134
|
+
(g(!0), A(re, null, we(M.value, (E, X) => (g(), A("div", {
|
|
3097
3135
|
key: X,
|
|
3098
3136
|
class: "flex items-center justify-between gap-8 rounded-md border border-fm-color-neutral-gray-100 px-8 py-6"
|
|
3099
3137
|
}, [
|
|
3100
|
-
|
|
3101
|
-
|
|
3102
|
-
class:
|
|
3138
|
+
h("div", Ft, [
|
|
3139
|
+
h("span", {
|
|
3140
|
+
class: _e(["line-style-icon", b(E)]),
|
|
3103
3141
|
"aria-hidden": "true"
|
|
3104
3142
|
}, null, 2),
|
|
3105
|
-
|
|
3143
|
+
h("span", kt, P(f.value[X] || `${l(a)("report.section.datasource.lineStyle.line")} ${X + 1}`), 1)
|
|
3106
3144
|
]),
|
|
3107
|
-
r(
|
|
3108
|
-
"model-value":
|
|
3145
|
+
r(Q, {
|
|
3146
|
+
"model-value": E,
|
|
3109
3147
|
items: t.value,
|
|
3110
3148
|
class: "w-[130px]",
|
|
3111
|
-
"onUpdate:modelValue": (
|
|
3149
|
+
"onUpdate:modelValue": (J) => o(X, J)
|
|
3112
3150
|
}, null, 8, ["model-value", "items", "onUpdate:modelValue"])
|
|
3113
3151
|
]))), 128))
|
|
3114
3152
|
]),
|
|
3115
|
-
r(
|
|
3153
|
+
r(j, {
|
|
3116
3154
|
size: "md",
|
|
3117
3155
|
label: l(a)("report.common.apply"),
|
|
3118
|
-
disabled: !
|
|
3156
|
+
disabled: !p.value,
|
|
3119
3157
|
onClick: u
|
|
3120
3158
|
}, null, 8, ["label", "disabled"])
|
|
3121
3159
|
]);
|
|
3122
3160
|
};
|
|
3123
3161
|
}
|
|
3124
|
-
}),
|
|
3162
|
+
}), St = /* @__PURE__ */ nl(_t, [["__scopeId", "data-v-f1c35513"]]), Tt = { class: "flex flex-col gap-16" }, $t = {
|
|
3125
3163
|
key: 2,
|
|
3126
3164
|
class: "h-px w-full bg-fm-color-neutral-gray-100"
|
|
3127
|
-
},
|
|
3165
|
+
}, Dt = { class: "flex flex-col gap-8" }, Bt = { class: "fm-typo-en-body-lg-600" }, Ut = { class: "flex flex-col gap-8" }, Lt = /* @__PURE__ */ ae({
|
|
3128
3166
|
__name: "StyleDatasource",
|
|
3129
|
-
props: /* @__PURE__ */
|
|
3167
|
+
props: /* @__PURE__ */ ue({
|
|
3130
3168
|
label: {
|
|
3131
3169
|
type: String,
|
|
3132
3170
|
default: "Label"
|
|
@@ -3153,20 +3191,20 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
3153
3191
|
modelValue: { required: !0 },
|
|
3154
3192
|
modelModifiers: {}
|
|
3155
3193
|
}),
|
|
3156
|
-
emits: /* @__PURE__ */
|
|
3194
|
+
emits: /* @__PURE__ */ ue(["click-close"], ["update:modelValue"]),
|
|
3157
3195
|
setup(D, { emit: d }) {
|
|
3158
|
-
const e =
|
|
3196
|
+
const e = ce(D, "modelValue");
|
|
3159
3197
|
ye(
|
|
3160
3198
|
[() => e.value.dimensions, () => e.value.metrics],
|
|
3161
3199
|
() => {
|
|
3162
|
-
const { rowIds: i, columnIds: b } =
|
|
3200
|
+
const { rowIds: i, columnIds: b } = je(e.value);
|
|
3163
3201
|
e.value.rowIds = i, e.value.columnIds = b;
|
|
3164
3202
|
},
|
|
3165
3203
|
{ deep: !0 }
|
|
3166
3204
|
);
|
|
3167
|
-
const s = D, a = d, { t:
|
|
3168
|
-
() => s.config.type ===
|
|
3169
|
-
),
|
|
3205
|
+
const s = D, a = d, { t: w } = se(), x = S(() => s.config.type === I.Circular), v = S(() => s.config.type === I.StackBarChart || s.config.type === I.ClusteredStackBarChart), C = S(
|
|
3206
|
+
() => s.config.type === I.LineChart || s.config.type === I.StackLineChart
|
|
3207
|
+
), k = S({
|
|
3170
3208
|
get: () => e.value.maxTooltipItems ?? null,
|
|
3171
3209
|
set: (i) => {
|
|
3172
3210
|
e.value = {
|
|
@@ -3174,7 +3212,7 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
3174
3212
|
maxTooltipItems: i ?? void 0
|
|
3175
3213
|
};
|
|
3176
3214
|
}
|
|
3177
|
-
}), t =
|
|
3215
|
+
}), t = S({
|
|
3178
3216
|
get: () => e.value.stackBarOverlap ?? !1,
|
|
3179
3217
|
set: (i) => {
|
|
3180
3218
|
e.value = {
|
|
@@ -3184,69 +3222,70 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
3184
3222
|
}
|
|
3185
3223
|
});
|
|
3186
3224
|
return (i, b) => {
|
|
3187
|
-
const
|
|
3188
|
-
return
|
|
3189
|
-
b[10] || (b[10] =
|
|
3190
|
-
s.closeable ? (
|
|
3225
|
+
const F = $("FmButton"), T = $("FmCheckbox"), f = $("FmStepperField");
|
|
3226
|
+
return g(), A(re, null, [
|
|
3227
|
+
b[10] || (b[10] = h("div", { class: "grow" }, null, -1)),
|
|
3228
|
+
s.closeable ? (g(), N(F, {
|
|
3191
3229
|
key: 0,
|
|
3192
3230
|
icon: "close",
|
|
3193
3231
|
variant: "tertiary",
|
|
3194
3232
|
size: "md",
|
|
3195
|
-
onClick: b[0] || (b[0] =
|
|
3233
|
+
onClick: b[0] || (b[0] = ge((V) => a("click-close"), ["stop"]))
|
|
3196
3234
|
})) : O("", !0),
|
|
3197
|
-
|
|
3198
|
-
s.config.hasChart ? (
|
|
3235
|
+
h("div", Tt, [
|
|
3236
|
+
s.config.hasChart ? (g(), N(Zo, {
|
|
3199
3237
|
key: 0,
|
|
3200
3238
|
model: e.value,
|
|
3201
|
-
"onUpdate:model": b[1] || (b[1] = (
|
|
3239
|
+
"onUpdate:model": b[1] || (b[1] = (V) => e.value = V)
|
|
3202
3240
|
}, null, 8, ["model"])) : O("", !0),
|
|
3203
|
-
s.config.hasChart ? (
|
|
3241
|
+
s.config.hasChart ? (g(), N(yt, {
|
|
3204
3242
|
key: 1,
|
|
3205
3243
|
model: e.value,
|
|
3206
|
-
"show-layer-control":
|
|
3207
|
-
"limit-to-series-mode":
|
|
3208
|
-
"onUpdate:model": b[2] || (b[2] = (
|
|
3244
|
+
"show-layer-control": v.value && t.value,
|
|
3245
|
+
"limit-to-series-mode": x.value,
|
|
3246
|
+
"onUpdate:model": b[2] || (b[2] = (V) => e.value = V)
|
|
3209
3247
|
}, null, 8, ["model", "show-layer-control", "limit-to-series-mode"])) : O("", !0),
|
|
3210
|
-
s.config.hasChart &&
|
|
3211
|
-
s.config.hasChart &&
|
|
3248
|
+
s.config.hasChart && C.value ? (g(), A("div", $t)) : O("", !0),
|
|
3249
|
+
s.config.hasChart && C.value ? (g(), N(St, {
|
|
3212
3250
|
key: 3,
|
|
3213
3251
|
model: e.value,
|
|
3214
|
-
"onUpdate:model": b[3] || (b[3] = (
|
|
3252
|
+
"onUpdate:model": b[3] || (b[3] = (V) => e.value = V)
|
|
3215
3253
|
}, null, 8, ["model"])) : O("", !0),
|
|
3216
|
-
b[9] || (b[9] =
|
|
3217
|
-
|
|
3218
|
-
|
|
3219
|
-
|
|
3220
|
-
|
|
3254
|
+
b[9] || (b[9] = h("div", { class: "h-px w-full bg-fm-color-neutral-gray-100" }, null, -1)),
|
|
3255
|
+
h("div", Dt, [
|
|
3256
|
+
h("p", Bt, P(l(w)("report.section.style.configuration")), 1),
|
|
3257
|
+
h("div", Ut, [
|
|
3258
|
+
v.value ? (g(), N(T, {
|
|
3221
3259
|
key: 0,
|
|
3222
3260
|
modelValue: t.value,
|
|
3223
|
-
"onUpdate:modelValue": b[4] || (b[4] = (
|
|
3261
|
+
"onUpdate:modelValue": b[4] || (b[4] = (V) => t.value = V),
|
|
3224
3262
|
class: "fm-typo-en-body-lg-400",
|
|
3225
|
-
label: l(
|
|
3263
|
+
label: l(w)("report.section.datasource.stackBar.overlapBars")
|
|
3226
3264
|
}, null, 8, ["modelValue", "label"])) : O("", !0),
|
|
3227
|
-
s.config.hasLabel ? (
|
|
3265
|
+
s.config.hasLabel ? (g(), N(jo, {
|
|
3228
3266
|
key: 1,
|
|
3229
3267
|
model: e.value,
|
|
3230
|
-
"onUpdate:model": b[5] || (b[5] = (
|
|
3268
|
+
"onUpdate:model": b[5] || (b[5] = (V) => e.value = V)
|
|
3231
3269
|
}, null, 8, ["model"])) : O("", !0),
|
|
3232
|
-
s.config.hasLegend ? (
|
|
3270
|
+
s.config.hasLegend ? (g(), N(Ko, {
|
|
3233
3271
|
key: 2,
|
|
3234
3272
|
model: e.value,
|
|
3235
|
-
"is-circular-widget":
|
|
3236
|
-
"onUpdate:model": b[6] || (b[6] = (
|
|
3273
|
+
"is-circular-widget": x.value,
|
|
3274
|
+
"onUpdate:model": b[6] || (b[6] = (V) => e.value = V)
|
|
3237
3275
|
}, null, 8, ["model", "is-circular-widget"])) : O("", !0),
|
|
3238
|
-
s.config.hasXy ? (
|
|
3276
|
+
s.config.hasXy ? (g(), N(Wo, {
|
|
3239
3277
|
key: 3,
|
|
3240
3278
|
model: e.value,
|
|
3241
|
-
"onUpdate:model": b[7] || (b[7] = (
|
|
3279
|
+
"onUpdate:model": b[7] || (b[7] = (V) => e.value = V)
|
|
3242
3280
|
}, null, 8, ["model"])) : O("", !0),
|
|
3243
|
-
s.config.hasXy ? (
|
|
3281
|
+
s.config.hasXy ? (g(), N(f, {
|
|
3244
3282
|
key: 4,
|
|
3245
|
-
modelValue:
|
|
3246
|
-
"onUpdate:modelValue": b[8] || (b[8] = (
|
|
3283
|
+
modelValue: k.value,
|
|
3284
|
+
"onUpdate:modelValue": b[8] || (b[8] = (V) => k.value = V),
|
|
3247
3285
|
type: "number",
|
|
3248
|
-
label: l(
|
|
3286
|
+
label: l(w)("report.section.datasource.tooltip.maxTooltipItems"),
|
|
3249
3287
|
min: 2,
|
|
3288
|
+
max: 20,
|
|
3250
3289
|
placeholder: "Auto"
|
|
3251
3290
|
}, null, 8, ["modelValue", "label"])) : O("", !0)
|
|
3252
3291
|
])
|
|
@@ -3255,7 +3294,7 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
3255
3294
|
], 64);
|
|
3256
3295
|
};
|
|
3257
3296
|
}
|
|
3258
|
-
}),
|
|
3297
|
+
}), Mt = { class: "fixed bottom-6 right-6" }, Nt = { class: "flex w-full items-center gap-8" }, Ot = { class: "fm-typo-en-title-sm-600" }, jt = { class: "ml-auto text-fm-color-system-info-300" }, zt = /* @__PURE__ */ ae({
|
|
3259
3298
|
__name: "StyleEditorTab",
|
|
3260
3299
|
props: {
|
|
3261
3300
|
modelValue: {
|
|
@@ -3267,10 +3306,10 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
3267
3306
|
},
|
|
3268
3307
|
emits: ["update:modelValue", "update:isStyleEditing"],
|
|
3269
3308
|
setup(D) {
|
|
3270
|
-
const { t: d } =
|
|
3271
|
-
() =>
|
|
3272
|
-
), a =
|
|
3273
|
-
var
|
|
3309
|
+
const { t: d } = se(), e = ce(D, "modelValue"), s = S(
|
|
3310
|
+
() => Ie.find((v) => v.type === e.value.widget.type)
|
|
3311
|
+
), a = ce(D, "isStyleEditing"), w = S(() => {
|
|
3312
|
+
var v;
|
|
3274
3313
|
return {
|
|
3275
3314
|
chartHeight: void 0,
|
|
3276
3315
|
chartWidth: void 0,
|
|
@@ -3283,13 +3322,13 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
3283
3322
|
lineStyles: void 0,
|
|
3284
3323
|
lineStyleBinding: void 0,
|
|
3285
3324
|
showLabel: !1,
|
|
3286
|
-
labelAlign:
|
|
3287
|
-
labelAnchor:
|
|
3325
|
+
labelAlign: Ce.center,
|
|
3326
|
+
labelAnchor: Me.center,
|
|
3288
3327
|
labelRotation: 0,
|
|
3289
3328
|
labelOffset: 0,
|
|
3290
3329
|
labelFontSize: 12,
|
|
3291
3330
|
showX: !0,
|
|
3292
|
-
xPosition:
|
|
3331
|
+
xPosition: Bl.bottom,
|
|
3293
3332
|
showXGrid: !1,
|
|
3294
3333
|
showXTick: !0,
|
|
3295
3334
|
xTickFontSize: 12,
|
|
@@ -3297,43 +3336,41 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
3297
3336
|
xTitle: "",
|
|
3298
3337
|
xTitleFontSize: 12,
|
|
3299
3338
|
showY: !0,
|
|
3300
|
-
yPosition:
|
|
3339
|
+
yPosition: Dl.left,
|
|
3301
3340
|
showYGrid: !1,
|
|
3302
3341
|
showYTick: !0,
|
|
3303
3342
|
yTickFontSize: 12,
|
|
3304
3343
|
showYTitle: !1,
|
|
3305
3344
|
yTitle: "",
|
|
3306
3345
|
yTitleFontSize: 12,
|
|
3307
|
-
showLegend: ((
|
|
3308
|
-
legendPosition:
|
|
3346
|
+
showLegend: ((v = s.value) == null ? void 0 : v.type) === I.Circular,
|
|
3347
|
+
legendPosition: $l.top,
|
|
3309
3348
|
usePointStyle: !0,
|
|
3310
3349
|
legendFontSize: void 0,
|
|
3311
3350
|
legendColor: "#6b6b6b",
|
|
3312
|
-
legendMaxLines: void 0,
|
|
3313
|
-
legendMaxHeight: void 0,
|
|
3314
3351
|
legendMaxWidth: void 0,
|
|
3315
3352
|
maxTooltipItems: void 0,
|
|
3316
3353
|
stackBarOverlap: !1
|
|
3317
3354
|
};
|
|
3318
3355
|
});
|
|
3319
|
-
function
|
|
3356
|
+
function x() {
|
|
3320
3357
|
e.value && (e.value.widget.config = {
|
|
3321
3358
|
...e.value.widget.config,
|
|
3322
|
-
...
|
|
3359
|
+
...w.value
|
|
3323
3360
|
});
|
|
3324
3361
|
}
|
|
3325
|
-
return (
|
|
3326
|
-
const
|
|
3327
|
-
return
|
|
3362
|
+
return (v, C) => {
|
|
3363
|
+
const k = $("FmCircularProgress"), t = $("FmButton"), i = $("FmSideSheet");
|
|
3364
|
+
return g(), N(i, {
|
|
3328
3365
|
modelValue: a.value,
|
|
3329
|
-
"onUpdate:modelValue":
|
|
3366
|
+
"onUpdate:modelValue": C[2] || (C[2] = (b) => a.value = b),
|
|
3330
3367
|
"close-button": !1,
|
|
3331
3368
|
"no-overlay": "",
|
|
3332
3369
|
"dismiss-away": !0,
|
|
3333
3370
|
"max-width": 500
|
|
3334
3371
|
}, {
|
|
3335
3372
|
"side-sheet-button": R(() => [
|
|
3336
|
-
|
|
3373
|
+
h("div", Mt, [
|
|
3337
3374
|
r(t, {
|
|
3338
3375
|
label: l(d)("report.section.style.button"),
|
|
3339
3376
|
icon: "edit",
|
|
@@ -3343,30 +3380,30 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
3343
3380
|
])
|
|
3344
3381
|
]),
|
|
3345
3382
|
"side-sheet-header": R(() => [
|
|
3346
|
-
|
|
3383
|
+
h("div", Nt, [
|
|
3347
3384
|
r(t, {
|
|
3348
3385
|
"prepend-icon": "arrow_back",
|
|
3349
3386
|
variant: "tertiary",
|
|
3350
3387
|
class: "fm-icon--rounded fm-icon--md text-fm-color-black",
|
|
3351
|
-
onClick:
|
|
3388
|
+
onClick: C[0] || (C[0] = (b) => a.value = !1)
|
|
3352
3389
|
}),
|
|
3353
|
-
|
|
3354
|
-
|
|
3390
|
+
h("p", Ot, P(l(d)("report.section.style.title")), 1),
|
|
3391
|
+
h("div", jt, [
|
|
3355
3392
|
r(t, {
|
|
3356
3393
|
label: l(d)("report.section.style.reset"),
|
|
3357
3394
|
variant: "tertiary",
|
|
3358
3395
|
size: "md",
|
|
3359
|
-
onClick:
|
|
3396
|
+
onClick: x,
|
|
3360
3397
|
"text-color": "text-fm-color-system-info-300"
|
|
3361
3398
|
}, null, 8, ["label"])
|
|
3362
3399
|
])
|
|
3363
3400
|
])
|
|
3364
3401
|
]),
|
|
3365
3402
|
default: R(() => [
|
|
3366
|
-
e.value ? O("", !0) : (
|
|
3367
|
-
r(
|
|
3403
|
+
e.value ? O("", !0) : (g(), N(k, { key: 0 })),
|
|
3404
|
+
r(Lt, {
|
|
3368
3405
|
modelValue: e.value.widget.config,
|
|
3369
|
-
"onUpdate:modelValue":
|
|
3406
|
+
"onUpdate:modelValue": C[1] || (C[1] = (b) => e.value.widget.config = b),
|
|
3370
3407
|
config: s.value
|
|
3371
3408
|
}, null, 8, ["modelValue", "config"])
|
|
3372
3409
|
]),
|
|
@@ -3374,12 +3411,12 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
3374
3411
|
}, 8, ["modelValue"]);
|
|
3375
3412
|
};
|
|
3376
3413
|
}
|
|
3377
|
-
}),
|
|
3414
|
+
}), It = { class: "bg-fm-color-neutral-white flex flex-col h-full w-[510px]" }, At = { class: "flex bg-fm-color-neutral-white w-[88px]" }, Rt = { class: "w-full overflow-y-auto" }, Pt = {
|
|
3378
3415
|
class: "grid grid-cols-12 w-full p-24",
|
|
3379
3416
|
style: { backgroundColor: "#F6F8FC" }
|
|
3380
|
-
},
|
|
3417
|
+
}, Xt = /* @__PURE__ */ ae({
|
|
3381
3418
|
__name: "TileEditorDesktop",
|
|
3382
|
-
props: /* @__PURE__ */
|
|
3419
|
+
props: /* @__PURE__ */ ue({
|
|
3383
3420
|
hideConfiguration: { type: Boolean, required: !0, default: !1 },
|
|
3384
3421
|
index: { type: Number, required: !0, default: 0 }
|
|
3385
3422
|
}, {
|
|
@@ -3388,104 +3425,104 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
3388
3425
|
},
|
|
3389
3426
|
modelModifiers: {}
|
|
3390
3427
|
}),
|
|
3391
|
-
emits: /* @__PURE__ */
|
|
3428
|
+
emits: /* @__PURE__ */ ue(["hideConfiguration"], ["update:modelValue"]),
|
|
3392
3429
|
setup(D, { emit: d }) {
|
|
3393
|
-
const e =
|
|
3394
|
-
() =>
|
|
3430
|
+
const e = ce(D, "modelValue"), s = D, a = S(
|
|
3431
|
+
() => Ie.find((t) => {
|
|
3395
3432
|
var i;
|
|
3396
3433
|
return t.type === ((i = e.value) == null ? void 0 : i.widget.type);
|
|
3397
3434
|
})
|
|
3398
|
-
),
|
|
3399
|
-
|
|
3400
|
-
|
|
3401
|
-
|
|
3402
|
-
|
|
3403
|
-
|
|
3404
|
-
|
|
3405
|
-
],
|
|
3406
|
-
function
|
|
3435
|
+
), w = d, x = [
|
|
3436
|
+
I.BarChart,
|
|
3437
|
+
I.StackBarChart,
|
|
3438
|
+
I.ClusteredStackBarChart,
|
|
3439
|
+
I.LineChart,
|
|
3440
|
+
I.StackLineChart,
|
|
3441
|
+
I.Circular
|
|
3442
|
+
], v = S(() => x.includes(e.value.widget.type)), C = ee(!1);
|
|
3443
|
+
function k(t) {
|
|
3407
3444
|
if (![
|
|
3408
|
-
|
|
3409
|
-
|
|
3410
|
-
|
|
3411
|
-
|
|
3412
|
-
|
|
3445
|
+
I.BarChart,
|
|
3446
|
+
I.StackBarChart,
|
|
3447
|
+
I.ClusteredStackBarChart,
|
|
3448
|
+
I.LineChart,
|
|
3449
|
+
I.StackLineChart
|
|
3413
3450
|
].includes(e.value.widget.type))
|
|
3414
3451
|
return;
|
|
3415
|
-
const b = t.filter((
|
|
3416
|
-
|
|
3452
|
+
const b = t.filter((f) => !!f), F = e.value.widget.config.chartBreakdownDimensionValues ?? [];
|
|
3453
|
+
F.length === b.length && F.every((f, V) => f === b[V]) || (e.value.widget.config = {
|
|
3417
3454
|
...e.value.widget.config,
|
|
3418
3455
|
chartBreakdownDimensionValues: b.length > 0 ? [...b] : void 0
|
|
3419
3456
|
});
|
|
3420
3457
|
}
|
|
3421
3458
|
return (t, i) => {
|
|
3422
|
-
const b = $("FmCircularProgress"),
|
|
3423
|
-
return
|
|
3424
|
-
e.value ? (
|
|
3425
|
-
r(
|
|
3459
|
+
const b = $("FmCircularProgress"), F = $("FmButton");
|
|
3460
|
+
return g(), A("div", null, [
|
|
3461
|
+
e.value ? (g(), A(re, { key: 1 }, [
|
|
3462
|
+
r(xl, {
|
|
3426
3463
|
"model-value": !D.hideConfiguration
|
|
3427
3464
|
}, {
|
|
3428
3465
|
right: R(() => [
|
|
3429
|
-
|
|
3466
|
+
h("div", It, [
|
|
3430
3467
|
r(ul, {
|
|
3431
3468
|
modelValue: e.value,
|
|
3432
|
-
"onUpdate:modelValue": i[0] || (i[0] = (
|
|
3469
|
+
"onUpdate:modelValue": i[0] || (i[0] = (T) => e.value = T),
|
|
3433
3470
|
config: a.value,
|
|
3434
3471
|
"hide-configuration": D.hideConfiguration,
|
|
3435
|
-
onHideConfiguration: i[1] || (i[1] = (
|
|
3436
|
-
|
|
3472
|
+
onHideConfiguration: i[1] || (i[1] = (T) => {
|
|
3473
|
+
w("hideConfiguration", T);
|
|
3437
3474
|
})
|
|
3438
3475
|
}, null, 8, ["modelValue", "config", "hide-configuration"])
|
|
3439
3476
|
])
|
|
3440
3477
|
]),
|
|
3441
3478
|
left: R(() => [
|
|
3442
|
-
|
|
3443
|
-
r(
|
|
3479
|
+
h("div", At, [
|
|
3480
|
+
r(F, {
|
|
3444
3481
|
variant: "secondary",
|
|
3445
3482
|
icon: "keyboard_double_arrow_right",
|
|
3446
3483
|
"border-color": l(Ge).ColorPrimary,
|
|
3447
3484
|
"text-color": l(Ge).ColorPrimary,
|
|
3448
3485
|
class: "m-24 my-16",
|
|
3449
3486
|
size: "md",
|
|
3450
|
-
onClick: i[2] || (i[2] = (
|
|
3487
|
+
onClick: i[2] || (i[2] = (T) => w("hideConfiguration", !s.hideConfiguration))
|
|
3451
3488
|
}, null, 8, ["border-color", "text-color"])
|
|
3452
3489
|
])
|
|
3453
3490
|
]),
|
|
3454
3491
|
_: 1
|
|
3455
3492
|
}, 8, ["model-value"]),
|
|
3456
|
-
|
|
3457
|
-
|
|
3458
|
-
e.value ? (
|
|
3493
|
+
h("div", Rt, [
|
|
3494
|
+
h("div", Pt, [
|
|
3495
|
+
e.value ? (g(), N(sl, {
|
|
3459
3496
|
key: 0,
|
|
3460
3497
|
"model-value": e.value,
|
|
3461
3498
|
index: s.index,
|
|
3462
3499
|
"hide-export": !0,
|
|
3463
|
-
"is-style-editing":
|
|
3464
|
-
"onUpdate:breakdownDimensionValues":
|
|
3465
|
-
}, null, 8, ["model-value", "index", "is-style-editing"])) : (
|
|
3500
|
+
"is-style-editing": C.value,
|
|
3501
|
+
"onUpdate:breakdownDimensionValues": k
|
|
3502
|
+
}, null, 8, ["model-value", "index", "is-style-editing"])) : (g(), N(rl, { key: 1 }))
|
|
3466
3503
|
])
|
|
3467
3504
|
]),
|
|
3468
|
-
|
|
3505
|
+
v.value ? (g(), N(zt, {
|
|
3469
3506
|
key: 0,
|
|
3470
3507
|
modelValue: e.value,
|
|
3471
|
-
"onUpdate:modelValue": i[3] || (i[3] = (
|
|
3472
|
-
"is-style-editing":
|
|
3473
|
-
"onUpdate:isStyleEditing": i[4] || (i[4] = (
|
|
3508
|
+
"onUpdate:modelValue": i[3] || (i[3] = (T) => e.value = T),
|
|
3509
|
+
"is-style-editing": C.value,
|
|
3510
|
+
"onUpdate:isStyleEditing": i[4] || (i[4] = (T) => C.value = T),
|
|
3474
3511
|
"hide-configuration": D.hideConfiguration,
|
|
3475
|
-
onHideConfiguration: i[5] || (i[5] = (
|
|
3476
|
-
|
|
3512
|
+
onHideConfiguration: i[5] || (i[5] = (T) => {
|
|
3513
|
+
w("hideConfiguration", T);
|
|
3477
3514
|
})
|
|
3478
3515
|
}, null, 8, ["modelValue", "is-style-editing", "hide-configuration"])) : O("", !0)
|
|
3479
|
-
], 64)) : (
|
|
3516
|
+
], 64)) : (g(), N(b, { key: 0 }))
|
|
3480
3517
|
]);
|
|
3481
3518
|
};
|
|
3482
3519
|
}
|
|
3483
|
-
}),
|
|
3520
|
+
}), Et = {
|
|
3484
3521
|
key: 0,
|
|
3485
3522
|
class: "flex w-full justify-center items-center"
|
|
3486
|
-
},
|
|
3523
|
+
}, Wt = { class: "w-full grid grid-cols-12 pb-28 pt-5 px-5 h-full" }, qt = /* @__PURE__ */ ae({
|
|
3487
3524
|
__name: "TileEditorMobile",
|
|
3488
|
-
props: /* @__PURE__ */
|
|
3525
|
+
props: /* @__PURE__ */ ue({
|
|
3489
3526
|
hideConfiguration: { type: Boolean, required: !0, default: !1 },
|
|
3490
3527
|
index: { type: Number, required: !0, default: 0 }
|
|
3491
3528
|
}, {
|
|
@@ -3494,132 +3531,132 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
3494
3531
|
},
|
|
3495
3532
|
modelModifiers: {}
|
|
3496
3533
|
}),
|
|
3497
|
-
emits: /* @__PURE__ */
|
|
3534
|
+
emits: /* @__PURE__ */ ue(["hideConfiguration"], ["update:modelValue"]),
|
|
3498
3535
|
setup(D, { emit: d }) {
|
|
3499
|
-
const e =
|
|
3500
|
-
() =>
|
|
3501
|
-
var
|
|
3502
|
-
return
|
|
3536
|
+
const e = ce(D, "modelValue"), s = D, a = S(
|
|
3537
|
+
() => Ie.find((v) => {
|
|
3538
|
+
var C;
|
|
3539
|
+
return v.type === ((C = e.value) == null ? void 0 : C.widget.type);
|
|
3503
3540
|
})
|
|
3504
|
-
),
|
|
3505
|
-
function
|
|
3541
|
+
), w = d;
|
|
3542
|
+
function x(v) {
|
|
3506
3543
|
if (![
|
|
3507
|
-
|
|
3508
|
-
|
|
3509
|
-
|
|
3510
|
-
|
|
3511
|
-
|
|
3544
|
+
I.BarChart,
|
|
3545
|
+
I.StackBarChart,
|
|
3546
|
+
I.ClusteredStackBarChart,
|
|
3547
|
+
I.LineChart,
|
|
3548
|
+
I.StackLineChart
|
|
3512
3549
|
].includes(e.value.widget.type))
|
|
3513
3550
|
return;
|
|
3514
|
-
const
|
|
3515
|
-
t.length ===
|
|
3551
|
+
const k = v.filter((b) => !!b), t = e.value.widget.config.chartBreakdownDimensionValues ?? [];
|
|
3552
|
+
t.length === k.length && t.every((b, F) => b === k[F]) || (e.value.widget.config = {
|
|
3516
3553
|
...e.value.widget.config,
|
|
3517
|
-
chartBreakdownDimensionValues:
|
|
3554
|
+
chartBreakdownDimensionValues: k.length > 0 ? [...k] : void 0
|
|
3518
3555
|
});
|
|
3519
3556
|
}
|
|
3520
|
-
return (
|
|
3521
|
-
const
|
|
3522
|
-
return
|
|
3523
|
-
e.value ? (
|
|
3524
|
-
|
|
3525
|
-
e.value ? (
|
|
3557
|
+
return (v, C) => {
|
|
3558
|
+
const k = $("FmCircularProgress");
|
|
3559
|
+
return g(), A("div", null, [
|
|
3560
|
+
e.value ? (g(), A(re, { key: 1 }, [
|
|
3561
|
+
h("div", Wt, [
|
|
3562
|
+
e.value ? (g(), N(sl, {
|
|
3526
3563
|
key: 0,
|
|
3527
3564
|
"model-value": e.value,
|
|
3528
3565
|
index: s.index,
|
|
3529
3566
|
"hide-export": !0,
|
|
3530
|
-
"onUpdate:breakdownDimensionValues":
|
|
3531
|
-
}, null, 8, ["model-value", "index"])) : (
|
|
3567
|
+
"onUpdate:breakdownDimensionValues": x
|
|
3568
|
+
}, null, 8, ["model-value", "index"])) : (g(), N(rl, { key: 1 }))
|
|
3532
3569
|
]),
|
|
3533
3570
|
r(ul, {
|
|
3534
3571
|
modelValue: e.value,
|
|
3535
|
-
"onUpdate:modelValue":
|
|
3572
|
+
"onUpdate:modelValue": C[0] || (C[0] = (t) => e.value = t),
|
|
3536
3573
|
config: a.value,
|
|
3537
3574
|
"hide-configuration": D.hideConfiguration,
|
|
3538
|
-
onHideConfiguration:
|
|
3539
|
-
|
|
3575
|
+
onHideConfiguration: C[1] || (C[1] = (t) => {
|
|
3576
|
+
w("hideConfiguration", t);
|
|
3540
3577
|
})
|
|
3541
3578
|
}, null, 8, ["modelValue", "config", "hide-configuration"])
|
|
3542
|
-
], 64)) : (
|
|
3543
|
-
r(
|
|
3579
|
+
], 64)) : (g(), A("div", Et, [
|
|
3580
|
+
r(k)
|
|
3544
3581
|
]))
|
|
3545
3582
|
]);
|
|
3546
3583
|
};
|
|
3547
3584
|
}
|
|
3548
|
-
}),
|
|
3585
|
+
}), Yt = {
|
|
3549
3586
|
key: 0,
|
|
3550
3587
|
class: "fm-typo-en-title-md-600"
|
|
3551
|
-
},
|
|
3588
|
+
}, Ht = {
|
|
3552
3589
|
key: 0,
|
|
3553
3590
|
class: "flex items-start justify-start px-24 py-12 flex-wrap w-full"
|
|
3554
|
-
},
|
|
3591
|
+
}, da = /* @__PURE__ */ ae({
|
|
3555
3592
|
__name: "TileEditor",
|
|
3556
3593
|
setup(D) {
|
|
3557
|
-
const { rowHeight: d, colWidths: e } = Ve(
|
|
3558
|
-
var
|
|
3559
|
-
const o = (
|
|
3594
|
+
const { rowHeight: d, colWidths: e } = Ve(Ne()), s = bl(), a = yl(), w = Sl(), { globalFilters: x } = Ve(il()), { currentSelectWidgetType: v, editingReport: C, editingTile: k, editingTileIndex: t } = Ve(w), { breakpoints: i } = al(), { promptMessage: b } = tl(), { t: F, te: T } = se(), f = S(() => {
|
|
3595
|
+
var c;
|
|
3596
|
+
const o = (c = k.value) == null ? void 0 : c.widget.type;
|
|
3560
3597
|
if (!o)
|
|
3561
|
-
return
|
|
3598
|
+
return F("report.editor.newReport");
|
|
3562
3599
|
const n = `report.widget.types.${o.toLowerCase()}`;
|
|
3563
|
-
return
|
|
3564
|
-
}),
|
|
3565
|
-
function
|
|
3566
|
-
|
|
3600
|
+
return T(n) ? F(n) : o;
|
|
3601
|
+
}), V = ee(!1);
|
|
3602
|
+
function M() {
|
|
3603
|
+
v.value = void 0, k.value = void 0, t.value = -1, a.back();
|
|
3567
3604
|
}
|
|
3568
|
-
async function
|
|
3605
|
+
async function _() {
|
|
3569
3606
|
var n;
|
|
3570
|
-
if (!
|
|
3607
|
+
if (!C.value) return;
|
|
3571
3608
|
await b({
|
|
3572
|
-
title:
|
|
3573
|
-
message:
|
|
3574
|
-
}) &&
|
|
3575
|
-
...
|
|
3609
|
+
title: F("report.tile.save.title"),
|
|
3610
|
+
message: F("report.tile.save.confirm", { title: (n = k.value) == null ? void 0 : n.widget.title })
|
|
3611
|
+
}) && k.value && (k.value.widget.config = {
|
|
3612
|
+
...k.value.widget.config,
|
|
3576
3613
|
rowHeight: d.value,
|
|
3577
3614
|
colWidths: [...e.value]
|
|
3578
|
-
}, t.value === -1 ?
|
|
3615
|
+
}, t.value === -1 ? C.value.tiles.push(k.value) : C.value.tiles[t.value] = k.value, M());
|
|
3579
3616
|
}
|
|
3580
|
-
async function
|
|
3617
|
+
async function p() {
|
|
3581
3618
|
var n;
|
|
3582
|
-
if (!
|
|
3619
|
+
if (!C.value) return;
|
|
3583
3620
|
await b({
|
|
3584
|
-
title:
|
|
3585
|
-
message:
|
|
3586
|
-
}) &&
|
|
3621
|
+
title: F("report.tile.cancel.title"),
|
|
3622
|
+
message: F("report.tile.cancel.confirm", { title: (n = k.value) == null ? void 0 : n.widget.title })
|
|
3623
|
+
}) && M();
|
|
3587
3624
|
}
|
|
3588
3625
|
return We(() => {
|
|
3589
|
-
|
|
3626
|
+
C.value || a.push({ name: "reports" });
|
|
3590
3627
|
}), (o, n) => {
|
|
3591
|
-
const
|
|
3592
|
-
return
|
|
3628
|
+
const c = $("FmPageHead");
|
|
3629
|
+
return g(), N(Fl, null, {
|
|
3593
3630
|
default: R(() => [
|
|
3594
|
-
r(
|
|
3631
|
+
r(c, {
|
|
3595
3632
|
actions: [
|
|
3596
|
-
{ label: l(
|
|
3597
|
-
{ label: l(
|
|
3633
|
+
{ label: l(F)("report.common.cancel"), value: "cancel", isPrimary: !1 },
|
|
3634
|
+
{ label: l(F)("report.common.save"), value: "save", isPrimary: !0 }
|
|
3598
3635
|
],
|
|
3599
3636
|
"onClick:action": n[0] || (n[0] = (u) => {
|
|
3600
|
-
u === "cancel" &&
|
|
3637
|
+
u === "cancel" && p(), u === "save" && _();
|
|
3601
3638
|
})
|
|
3602
3639
|
}, {
|
|
3603
3640
|
title: R(() => [
|
|
3604
|
-
l(i).lg || l(i).md ? (
|
|
3641
|
+
l(i).lg || l(i).md ? (g(), A("p", Yt, P(f.value), 1)) : O("", !0)
|
|
3605
3642
|
]),
|
|
3606
3643
|
_: 1
|
|
3607
3644
|
}, 8, ["actions"]),
|
|
3608
|
-
l(
|
|
3609
|
-
const m = u.tileIds, y = l(
|
|
3645
|
+
l(k) && (l(x) || []).some((u) => {
|
|
3646
|
+
const m = u.tileIds, y = l(k) && l(k).id;
|
|
3610
3647
|
return Array.isArray(m) && typeof y == "string" && m.includes(y);
|
|
3611
|
-
}) ? (
|
|
3612
|
-
r(
|
|
3648
|
+
}) ? (g(), A("div", Ht, [
|
|
3649
|
+
r(Ul)
|
|
3613
3650
|
])) : O("", !0),
|
|
3614
|
-
l(
|
|
3651
|
+
l(k) ? (g(), N(ll(l(i).lg || l(i).md ? Xt : qt), {
|
|
3615
3652
|
key: 1,
|
|
3616
|
-
modelValue: l(
|
|
3617
|
-
"onUpdate:modelValue": n[1] || (n[1] = (u) =>
|
|
3618
|
-
class:
|
|
3619
|
-
style:
|
|
3620
|
-
"hide-configuration":
|
|
3653
|
+
modelValue: l(k),
|
|
3654
|
+
"onUpdate:modelValue": n[1] || (n[1] = (u) => gl(k) ? k.value = u : null),
|
|
3655
|
+
class: _e(`${l(i).lg || l(i).md ? "flex" : ""} w-full`),
|
|
3656
|
+
style: Re({ height: `calc( 100% - ${l(i).lg || l(i).md ? 72 : 64}px)` }),
|
|
3657
|
+
"hide-configuration": V.value,
|
|
3621
3658
|
index: Number(l(s).params.tileIndex),
|
|
3622
|
-
onHideConfiguration: n[2] || (n[2] = (u) =>
|
|
3659
|
+
onHideConfiguration: n[2] || (n[2] = (u) => V.value = u)
|
|
3623
3660
|
}, null, 40, ["modelValue", "class", "style", "hide-configuration", "index"])) : O("", !0)
|
|
3624
3661
|
]),
|
|
3625
3662
|
_: 1
|
|
@@ -3628,5 +3665,5 @@ const Xl = { class: "flex flex-col my-2 gap-8" }, Wl = { class: "fm-typo-en-body
|
|
|
3628
3665
|
}
|
|
3629
3666
|
});
|
|
3630
3667
|
export {
|
|
3631
|
-
|
|
3668
|
+
da as default
|
|
3632
3669
|
};
|