@feedmepos/mf-report 5.7.4 → 5.7.5-beta.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{App-CKdHPrlw.js → App-CIj6vVKq.js} +42 -42
- package/dist/{DateRangeSelect.vue_vue_type_script_setup_true_lang-Bi_BES93.js → DateRangeSelect.vue_vue_type_script_setup_true_lang-BD2DnN09.js} +2 -2
- package/dist/{Default.vue_vue_type_script_setup_true_lang-MQ0PDHS-.js → Default.vue_vue_type_script_setup_true_lang-CzQsu4PQ.js} +2 -2
- package/dist/{DynamicWidget.vue_vue_type_script_setup_true_lang-DokEr03U.js → DynamicWidget.vue_vue_type_script_setup_true_lang-DfLZrXsr.js} +4 -4
- package/dist/{InsightView-BbEc8H4o.js → InsightView-B98sHmT5.js} +156 -149
- package/dist/{Integration-D61lmDoO.js → Integration-DES_DTg-.js} +3 -3
- package/dist/{Integrations-BiJVCGrp.js → Integrations-DS6q4VX4.js} +3 -3
- package/dist/{Layout-D7KVahWl.js → Layout-DH2D5ulh.js} +1 -1
- package/dist/{MenuTab.vue_vue_type_script_setup_true_lang-3aQidzm3.js → MenuTab.vue_vue_type_script_setup_true_lang-BctJOF4M.js} +3 -3
- package/dist/{NavigationTab.vue_vue_type_script_setup_true_lang-CcHkFVHo.js → NavigationTab.vue_vue_type_script_setup_true_lang-cUCKgLFM.js} +5 -5
- package/dist/{NoData.vue_vue_type_script_setup_true_lang-CdFXBqlX.js → NoData.vue_vue_type_script_setup_true_lang-EVDtMqna.js} +1 -1
- package/dist/{OverviewView-CNGSA27Y.js → OverviewView-C1yXNyvT.js} +5 -5
- package/dist/{Report-Hq2yj8Ox.js → Report-CViV53uf.js} +4 -4
- package/dist/{ReportEditor-BQdseFOk.js → ReportEditor-DFK07SDJ.js} +191 -197
- package/dist/{ReportView-zs3iDfhW.js → ReportView-CZ60he1O.js} +7 -7
- package/dist/{SelectComponent.vue_vue_type_script_setup_true_lang-N2Lg1Vpt.js → SelectComponent.vue_vue_type_script_setup_true_lang-Cpjinmn4.js} +1 -1
- package/dist/{Setting-Ddg3XPiq.js → Setting-C8qg3PnX.js} +4 -4
- package/dist/{TileEditor-BLsGvreq.js → TileEditor-FjYMPDA6.js} +8 -8
- package/dist/{TransitionFade-C7yNEw8X.js → TransitionFade-BdZQPsqs.js} +4 -4
- package/dist/app.js +11 -11
- package/dist/{global-loader-CbmVhJAK.js → global-loader-DqYGIXIo.js} +1 -1
- package/dist/{index-BWqDfeY6.js → index-BChph3k1.js} +1 -1
- package/dist/{report-schema-BnzKoFjx.js → report-schema-CbMyeD7Q.js} +1 -1
- package/dist/{v4-Cbq0RSpY.js → v4-CJhKiNw8.js} +1 -1
- package/package.json +1 -1
|
@@ -2,14 +2,14 @@ var Zo = Object.defineProperty;
|
|
|
2
2
|
var Jo = (i, t, e) => t in i ? Zo(i, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : i[t] = e;
|
|
3
3
|
var k = (i, t, e) => Jo(i, typeof t != "symbol" ? t + "" : t, e);
|
|
4
4
|
import { ref as $t, defineComponent as oe, watch as ri, computed as _t, onMounted as Qo, createElementBlock as U, openBlock as I, createElementVNode as R, renderSlot as Un, toDisplayString as lt, resolveDirective as Xn, createCommentVNode as St, Fragment as Ii, renderList as zi, createBlock as Ht, withDirectives as Ge, resolveDynamicComponent as es, unref as G, withCtx as Yt, createVNode as et, normalizeClass as Ze, resolveComponent as Me, useModel as ta, createTextVNode as ea, isRef as ki, nextTick as ia } from "vue";
|
|
5
|
-
import { _ as sa } from "./Default.vue_vue_type_script_setup_true_lang-
|
|
6
|
-
import { _ as na } from "./DateRangeSelect.vue_vue_type_script_setup_true_lang-
|
|
7
|
-
import { d as Bi, a as Kn, h as qn, F as Gn, u as Zn, b as oa } from "./global-loader-
|
|
5
|
+
import { _ as sa } from "./Default.vue_vue_type_script_setup_true_lang-CzQsu4PQ.js";
|
|
6
|
+
import { _ as na } from "./DateRangeSelect.vue_vue_type_script_setup_true_lang-BD2DnN09.js";
|
|
7
|
+
import { d as Bi, a as Kn, h as qn, F as Gn, u as Zn, b as oa } from "./global-loader-DqYGIXIo.js";
|
|
8
8
|
import { storeToRefs as Jn } from "pinia";
|
|
9
9
|
import { components as is, useSnackbar as aa } from "@feedmepos/ui-library";
|
|
10
|
-
import { c as ys } from "./index-
|
|
11
|
-
import { _ as ra } from "./NoData.vue_vue_type_script_setup_true_lang-
|
|
12
|
-
import { a as la, G as ca } from "./NavigationTab.vue_vue_type_script_setup_true_lang-
|
|
10
|
+
import { c as ys } from "./index-BChph3k1.js";
|
|
11
|
+
import { _ as ra } from "./NoData.vue_vue_type_script_setup_true_lang-EVDtMqna.js";
|
|
12
|
+
import { a as la, G as ca } from "./NavigationTab.vue_vue_type_script_setup_true_lang-cUCKgLFM.js";
|
|
13
13
|
import { useCoreStore as ha } from "@feedmepos/mf-common";
|
|
14
14
|
function da({ start: i, end: t }) {
|
|
15
15
|
return `${Bi(t).format("DD MMM")}, ${Bi(t).format("YYYY")}`;
|
|
@@ -1899,16 +1899,16 @@ function So(i, t, e) {
|
|
|
1899
1899
|
i
|
|
1900
1900
|
];
|
|
1901
1901
|
const { property: s, start: n, end: o } = e, a = t.length, { compare: r, between: l, normalize: c } = Mo(s), { start: h, end: d, loop: u, style: f } = Xr(i, t, e), g = [];
|
|
1902
|
-
let p = !1, m = null, b, x,
|
|
1903
|
-
const v = () => l(n,
|
|
1902
|
+
let p = !1, m = null, b, x, y;
|
|
1903
|
+
const v = () => l(n, y, b) && r(n, y) !== 0, _ = () => r(o, b) === 0 || l(o, y, b), w = () => p || v(), M = () => !p || _();
|
|
1904
1904
|
for (let S = h, P = h; S <= d; ++S)
|
|
1905
|
-
x = t[S % a], !x.skip && (b = c(x[s]), b !==
|
|
1905
|
+
x = t[S % a], !x.skip && (b = c(x[s]), b !== y && (p = l(b, n, o), m === null && w() && (m = r(b, n) === 0 ? S : P), m !== null && M() && (g.push(Ws({
|
|
1906
1906
|
start: m,
|
|
1907
1907
|
end: S,
|
|
1908
1908
|
loop: u,
|
|
1909
1909
|
count: a,
|
|
1910
1910
|
style: f
|
|
1911
|
-
})), m = null), P = S,
|
|
1911
|
+
})), m = null), P = S, y = b));
|
|
1912
1912
|
return m !== null && g.push(Ws({
|
|
1913
1913
|
start: m,
|
|
1914
1914
|
end: d,
|
|
@@ -2944,8 +2944,8 @@ class Je extends dt {
|
|
|
2944
2944
|
width: c ? Math.abs(p.size) : m.size
|
|
2945
2945
|
};
|
|
2946
2946
|
u && (x.options = d || this.resolveDataElementOptions(f, t[f].active ? "active" : n));
|
|
2947
|
-
const
|
|
2948
|
-
yl(x,
|
|
2947
|
+
const y = x.options || t[f].options;
|
|
2948
|
+
yl(x, y, b, a), kl(x, y, h.ratio), this.updateElement(t[f], f, x, n);
|
|
2949
2949
|
}
|
|
2950
2950
|
}
|
|
2951
2951
|
_getStacks(t, e) {
|
|
@@ -2991,8 +2991,8 @@ class Je extends dt {
|
|
|
2991
2991
|
let b = e.getPixelForValue(m);
|
|
2992
2992
|
if (this.chart.getDataVisibility(t) ? g = e.getPixelForValue(u + f) : g = b, p = g - b, Math.abs(p) < a) {
|
|
2993
2993
|
p = xl(p, e, r) * a, d === r && (b -= p / 2);
|
|
2994
|
-
const x = e.getPixelForDecimal(0),
|
|
2995
|
-
b = Math.max(Math.min(b,
|
|
2994
|
+
const x = e.getPixelForDecimal(0), y = e.getPixelForDecimal(1), v = Math.min(x, y), _ = Math.max(x, y);
|
|
2995
|
+
b = Math.max(Math.min(b, _), v), g = b + p, s && !h && (l._stacks[e.axis]._visualValues[n] = e.getValueForPixel(g) - e.getValueForPixel(b));
|
|
2996
2996
|
}
|
|
2997
2997
|
if (b === e.getPixelForValue(r)) {
|
|
2998
2998
|
const x = pt(p) * e.getLineWidthForValue(r) / 2;
|
|
@@ -3148,7 +3148,7 @@ k(Qe, "id", "bubble"), k(Qe, "defaults", {
|
|
|
3148
3148
|
function wl(i, t, e) {
|
|
3149
3149
|
let s = 1, n = 1, o = 0, a = 0;
|
|
3150
3150
|
if (t < B) {
|
|
3151
|
-
const r = i, l = r + t, c = Math.cos(r), h = Math.sin(r), d = Math.cos(l), u = Math.sin(l), f = (
|
|
3151
|
+
const r = i, l = r + t, c = Math.cos(r), h = Math.sin(r), d = Math.cos(l), u = Math.sin(l), f = (y, v, _) => De(y, r, l, !0) ? 1 : Math.max(v, v * e, _, _ * e), g = (y, v, _) => De(y, r, l, !0) ? -1 : Math.min(v, v * e, _, _ * e), p = f(0, c, d), m = f(Y, h, u), b = g(V, c, d), x = g(V + Y, h, u);
|
|
3152
3152
|
s = (p - b) / 2, n = (m - x) / 2, o = -(p + b) / 2, a = -(m + x) / 2;
|
|
3153
3153
|
}
|
|
3154
3154
|
return {
|
|
@@ -3198,8 +3198,8 @@ class jt extends dt {
|
|
|
3198
3198
|
};
|
|
3199
3199
|
}
|
|
3200
3200
|
update(t) {
|
|
3201
|
-
const e = this.chart, { chartArea: s } = e, n = this._cachedMeta, o = n.data, a = this.getMaxBorderWidth() + this.getMaxOffset(o) + this.options.spacing, r = Math.max((Math.min(s.width, s.height) - a) / 2, 0), l = Math.min(za(this.options.cutout, r), 1), c = this._getRingWeight(this.index), { circumference: h, rotation: d } = this._getRotationExtents(), { ratioX: u, ratioY: f, offsetX: g, offsetY: p } = wl(d, h, l), m = (s.width - a) / u, b = (s.height - a) / f, x = Math.max(Math.min(m, b) / 2, 0),
|
|
3202
|
-
this.offsetX = g *
|
|
3201
|
+
const e = this.chart, { chartArea: s } = e, n = this._cachedMeta, o = n.data, a = this.getMaxBorderWidth() + this.getMaxOffset(o) + this.options.spacing, r = Math.max((Math.min(s.width, s.height) - a) / 2, 0), l = Math.min(za(this.options.cutout, r), 1), c = this._getRingWeight(this.index), { circumference: h, rotation: d } = this._getRotationExtents(), { ratioX: u, ratioY: f, offsetX: g, offsetY: p } = wl(d, h, l), m = (s.width - a) / u, b = (s.height - a) / f, x = Math.max(Math.min(m, b) / 2, 0), y = io(this.options.radius, x), v = Math.max(y * l, 0), _ = (y - v) / this._getVisibleDatasetWeightTotal();
|
|
3202
|
+
this.offsetX = g * y, this.offsetY = p * y, n.total = this.calculateTotal(), this.outerRadius = y - _ * this._getRingWeightOffset(this.index), this.innerRadius = Math.max(this.outerRadius - _ * c, 0), this.updateElements(o, 0, o.length, t);
|
|
3203
3203
|
}
|
|
3204
3204
|
_circumference(t, e) {
|
|
3205
3205
|
const s = this.options, n = this._cachedMeta, o = this._getCircumference();
|
|
@@ -3211,16 +3211,16 @@ class jt extends dt {
|
|
|
3211
3211
|
for (x = 0; x < e; ++x)
|
|
3212
3212
|
b += this._circumference(x, o);
|
|
3213
3213
|
for (x = e; x < e + s; ++x) {
|
|
3214
|
-
const
|
|
3214
|
+
const y = this._circumference(x, o), v = t[x], _ = {
|
|
3215
3215
|
x: h + this.offsetX,
|
|
3216
3216
|
y: d + this.offsetY,
|
|
3217
3217
|
startAngle: b,
|
|
3218
|
-
endAngle: b +
|
|
3219
|
-
circumference:
|
|
3218
|
+
endAngle: b + y,
|
|
3219
|
+
circumference: y,
|
|
3220
3220
|
outerRadius: g,
|
|
3221
3221
|
innerRadius: f
|
|
3222
3222
|
};
|
|
3223
|
-
m && (
|
|
3223
|
+
m && (_.options = p || this.resolveDataElementOptions(x, v.active ? "active" : n)), b += y, this.updateElement(v, x, _, n);
|
|
3224
3224
|
}
|
|
3225
3225
|
}
|
|
3226
3226
|
calculateTotal() {
|
|
@@ -3361,16 +3361,16 @@ class ti extends dt {
|
|
|
3361
3361
|
}, t), this.updateElements(n, r, l, t);
|
|
3362
3362
|
}
|
|
3363
3363
|
updateElements(t, e, s, n) {
|
|
3364
|
-
const o = n === "reset", { iScale: a, vScale: r, _stacked: l, _dataset: c } = this._cachedMeta, { sharedOptions: h, includeOptions: d } = this._getSharedOptions(e, n), u = a.axis, f = r.axis, { spanGaps: g, segment: p } = this.options, m = ie(g) ? g : Number.POSITIVE_INFINITY, b = this.chart._animationsDisabled || o || n === "none", x = e + s,
|
|
3364
|
+
const o = n === "reset", { iScale: a, vScale: r, _stacked: l, _dataset: c } = this._cachedMeta, { sharedOptions: h, includeOptions: d } = this._getSharedOptions(e, n), u = a.axis, f = r.axis, { spanGaps: g, segment: p } = this.options, m = ie(g) ? g : Number.POSITIVE_INFINITY, b = this.chart._animationsDisabled || o || n === "none", x = e + s, y = t.length;
|
|
3365
3365
|
let v = e > 0 && this.getParsed(e - 1);
|
|
3366
|
-
for (let
|
|
3367
|
-
const w = t[
|
|
3368
|
-
if (
|
|
3366
|
+
for (let _ = 0; _ < y; ++_) {
|
|
3367
|
+
const w = t[_], M = b ? w : {};
|
|
3368
|
+
if (_ < e || _ >= x) {
|
|
3369
3369
|
M.skip = !0;
|
|
3370
3370
|
continue;
|
|
3371
3371
|
}
|
|
3372
|
-
const S = this.getParsed(
|
|
3373
|
-
M.skip = isNaN(D) || isNaN(A) || P, M.stop =
|
|
3372
|
+
const S = this.getParsed(_), P = L(S[f]), D = M[u] = a.getPixelForValue(S[u], _), A = M[f] = o || P ? r.getBasePixel() : r.getPixelForValue(l ? this.applyStack(r, S, l) : S[f], _);
|
|
3373
|
+
M.skip = isNaN(D) || isNaN(A) || P, M.stop = _ > 0 && Math.abs(S[u] - v[u]) > m, p && (M.parsed = S, M.raw = c.data[_]), d && (M.options = h || this.resolveDataElementOptions(_, w.active ? "active" : n)), b || this.updateElement(w, _, M, n), v = S;
|
|
3374
3374
|
}
|
|
3375
3375
|
}
|
|
3376
3376
|
getMaxOverflow() {
|
|
@@ -3440,13 +3440,13 @@ class we extends dt {
|
|
|
3440
3440
|
f += this._computeAngle(g, n, p);
|
|
3441
3441
|
for (g = e; g < e + s; g++) {
|
|
3442
3442
|
const m = t[g];
|
|
3443
|
-
let b = f, x = f + this._computeAngle(g, n, p),
|
|
3444
|
-
f = x, o && (l.animateScale && (
|
|
3443
|
+
let b = f, x = f + this._computeAngle(g, n, p), y = a.getDataVisibility(g) ? c.getDistanceFromCenterForValue(this.getParsed(g).r) : 0;
|
|
3444
|
+
f = x, o && (l.animateScale && (y = 0), l.animateRotate && (b = x = u));
|
|
3445
3445
|
const v = {
|
|
3446
3446
|
x: h,
|
|
3447
3447
|
y: d,
|
|
3448
3448
|
innerRadius: 0,
|
|
3449
|
-
outerRadius:
|
|
3449
|
+
outerRadius: y,
|
|
3450
3450
|
startAngle: b,
|
|
3451
3451
|
endAngle: x,
|
|
3452
3452
|
options: this.resolveDataElementOptions(g, m.active ? "active" : n)
|
|
@@ -3628,10 +3628,10 @@ class ii extends dt {
|
|
|
3628
3628
|
}
|
|
3629
3629
|
updateElements(t, e, s, n) {
|
|
3630
3630
|
const o = n === "reset", { iScale: a, vScale: r, _stacked: l, _dataset: c } = this._cachedMeta, h = this.resolveDataElementOptions(e, n), d = this.getSharedOptions(h), u = this.includeOptions(n, d), f = a.axis, g = r.axis, { spanGaps: p, segment: m } = this.options, b = ie(p) ? p : Number.POSITIVE_INFINITY, x = this.chart._animationsDisabled || o || n === "none";
|
|
3631
|
-
let
|
|
3631
|
+
let y = e > 0 && this.getParsed(e - 1);
|
|
3632
3632
|
for (let v = e; v < e + s; ++v) {
|
|
3633
|
-
const
|
|
3634
|
-
M.skip = isNaN(P) || isNaN(D) || S, M.stop = v > 0 && Math.abs(w[f] -
|
|
3633
|
+
const _ = t[v], w = this.getParsed(v), M = x ? _ : {}, S = L(w[g]), P = M[f] = a.getPixelForValue(w[f], v), D = M[g] = o || S ? r.getBasePixel() : r.getPixelForValue(l ? this.applyStack(r, w, l) : w[g], v);
|
|
3634
|
+
M.skip = isNaN(P) || isNaN(D) || S, M.stop = v > 0 && Math.abs(w[f] - y[f]) > b, m && (M.parsed = w, M.raw = c.data[v]), u && (M.options = d || this.resolveDataElementOptions(v, _.active ? "active" : n)), x || this.updateElement(_, v, M, n), y = w;
|
|
3635
3635
|
}
|
|
3636
3636
|
this.updateSharedOptions(d, n, h);
|
|
3637
3637
|
}
|
|
@@ -4706,17 +4706,17 @@ class Gt extends ut {
|
|
|
4706
4706
|
}
|
|
4707
4707
|
_computeLabelSizes(t, e, s) {
|
|
4708
4708
|
const { ctx: n, _longestTextCache: o } = this, a = [], r = [], l = Math.floor(e / an(e, s));
|
|
4709
|
-
let c = 0, h = 0, d, u, f, g, p, m, b, x,
|
|
4709
|
+
let c = 0, h = 0, d, u, f, g, p, m, b, x, y, v, _;
|
|
4710
4710
|
for (d = 0; d < e; d += l) {
|
|
4711
4711
|
if (g = t[d].label, p = this._resolveTickFontOptions(d), n.font = m = p.string, b = o[m] = o[m] || {
|
|
4712
4712
|
data: {},
|
|
4713
4713
|
gc: []
|
|
4714
|
-
}, x = p.lineHeight,
|
|
4715
|
-
|
|
4714
|
+
}, x = p.lineHeight, y = v = 0, !L(g) && !N(g))
|
|
4715
|
+
y = di(n, b.data, b.gc, y, g), v = x;
|
|
4716
4716
|
else if (N(g))
|
|
4717
4717
|
for (u = 0, f = g.length; u < f; ++u)
|
|
4718
|
-
|
|
4719
|
-
a.push(
|
|
4718
|
+
_ = g[u], !L(_) && !N(_) && (y = di(n, b.data, b.gc, y, _), v += x);
|
|
4719
|
+
a.push(y), r.push(v), c = Math.max(y, c), h = Math.max(v, h);
|
|
4720
4720
|
}
|
|
4721
4721
|
ac(o, e);
|
|
4722
4722
|
const w = a.indexOf(c), M = r.indexOf(h), S = (P) => ({
|
|
@@ -4780,7 +4780,7 @@ class Gt extends ut {
|
|
|
4780
4780
|
const e = this.axis, s = this.chart, n = this.options, { grid: o, position: a, border: r } = n, l = o.offset, c = this.isHorizontal(), d = this.ticks.length + (l ? 1 : 0), u = de(o), f = [], g = r.setContext(this.getContext()), p = g.display ? g.width : 0, m = p / 2, b = function(W) {
|
|
4781
4781
|
return zt(s, W, p);
|
|
4782
4782
|
};
|
|
4783
|
-
let x,
|
|
4783
|
+
let x, y, v, _, w, M, S, P, D, A, T, q;
|
|
4784
4784
|
if (a === "top")
|
|
4785
4785
|
x = b(this.bottom), M = this.bottom - u, P = x - m, A = b(t.top) + m, q = t.bottom;
|
|
4786
4786
|
else if (a === "bottom")
|
|
@@ -4807,9 +4807,9 @@ class Gt extends ut {
|
|
|
4807
4807
|
w = x - m, S = w - u, D = t.left, T = t.right;
|
|
4808
4808
|
}
|
|
4809
4809
|
const nt = C(n.ticks.maxTicksLimit, d), E = Math.max(1, Math.ceil(d / nt));
|
|
4810
|
-
for (
|
|
4811
|
-
const W = this.getContext(
|
|
4812
|
-
v = oc(this,
|
|
4810
|
+
for (y = 0; y < d; y += E) {
|
|
4811
|
+
const W = this.getContext(y), $ = o.setContext(W), ct = r.setContext(W), Z = $.lineWidth, Zt = $.color, Ee = ct.dash || [], Jt = ct.dashOffset, ae = $.tickWidth, Ft = $.tickColor, re = $.tickBorderDash || [], Et = $.tickBorderDashOffset;
|
|
4812
|
+
v = oc(this, y, l), v !== void 0 && (_ = zt(s, v, Z), c ? w = S = D = T = _ : M = P = A = q = _, f.push({
|
|
4813
4813
|
tx1: w,
|
|
4814
4814
|
ty1: M,
|
|
4815
4815
|
tx2: S,
|
|
@@ -4832,17 +4832,17 @@ class Gt extends ut {
|
|
|
4832
4832
|
}
|
|
4833
4833
|
_computeLabelItems(t) {
|
|
4834
4834
|
const e = this.axis, s = this.options, { position: n, ticks: o } = s, a = this.isHorizontal(), r = this.ticks, { align: l, crossAlign: c, padding: h, mirror: d } = o, u = de(s.grid), f = u + h, g = d ? -h : f, p = -ht(this.labelRotation), m = [];
|
|
4835
|
-
let b, x,
|
|
4835
|
+
let b, x, y, v, _, w, M, S, P, D, A, T, q = "middle";
|
|
4836
4836
|
if (n === "top")
|
|
4837
4837
|
w = this.bottom - g, M = this._getXAxisLabelAlignment();
|
|
4838
4838
|
else if (n === "bottom")
|
|
4839
4839
|
w = this.top + g, M = this._getXAxisLabelAlignment();
|
|
4840
4840
|
else if (n === "left") {
|
|
4841
4841
|
const E = this._getYAxisLabelAlignment(u);
|
|
4842
|
-
M = E.textAlign,
|
|
4842
|
+
M = E.textAlign, _ = E.x;
|
|
4843
4843
|
} else if (n === "right") {
|
|
4844
4844
|
const E = this._getYAxisLabelAlignment(u);
|
|
4845
|
-
M = E.textAlign,
|
|
4845
|
+
M = E.textAlign, _ = E.x;
|
|
4846
4846
|
} else if (e === "x") {
|
|
4847
4847
|
if (n === "center")
|
|
4848
4848
|
w = (t.top + t.bottom) / 2 + f;
|
|
@@ -4853,22 +4853,22 @@ class Gt extends ut {
|
|
|
4853
4853
|
M = this._getXAxisLabelAlignment();
|
|
4854
4854
|
} else if (e === "y") {
|
|
4855
4855
|
if (n === "center")
|
|
4856
|
-
|
|
4856
|
+
_ = (t.left + t.right) / 2 - f;
|
|
4857
4857
|
else if (O(n)) {
|
|
4858
4858
|
const E = Object.keys(n)[0], W = n[E];
|
|
4859
|
-
|
|
4859
|
+
_ = this.chart.scales[E].getPixelForValue(W);
|
|
4860
4860
|
}
|
|
4861
4861
|
M = this._getYAxisLabelAlignment(u).textAlign;
|
|
4862
4862
|
}
|
|
4863
4863
|
e === "y" && (l === "start" ? q = "top" : l === "end" && (q = "bottom"));
|
|
4864
4864
|
const nt = this._getLabelSizes();
|
|
4865
4865
|
for (b = 0, x = r.length; b < x; ++b) {
|
|
4866
|
-
|
|
4866
|
+
y = r[b], v = y.label;
|
|
4867
4867
|
const E = o.setContext(this.getContext(b));
|
|
4868
4868
|
S = this.getPixelForTick(b) + o.labelOffset, P = this._resolveTickFontOptions(b), D = P.lineHeight, A = N(v) ? v.length : 1;
|
|
4869
4869
|
const W = A / 2, $ = E.color, ct = E.textStrokeColor, Z = E.textStrokeWidth;
|
|
4870
4870
|
let Zt = M;
|
|
4871
|
-
a ? (
|
|
4871
|
+
a ? (_ = S, M === "inner" && (b === x - 1 ? Zt = this.options.reverse ? "left" : "right" : b === 0 ? Zt = this.options.reverse ? "right" : "left" : Zt = "center"), n === "top" ? c === "near" || p !== 0 ? T = -A * D + D / 2 : c === "center" ? T = -nt.highest.height / 2 - W * D + D : T = -nt.highest.height + D / 2 : c === "near" || p !== 0 ? T = D / 2 : c === "center" ? T = nt.highest.height / 2 - W * D : T = nt.highest.height - A * D, d && (T *= -1), p !== 0 && !E.showLabelBackdrop && (_ += D / 2 * Math.sin(p))) : (w = S, T = (1 - A) * D / 2);
|
|
4872
4872
|
let Ee;
|
|
4873
4873
|
if (E.showLabelBackdrop) {
|
|
4874
4874
|
const Jt = tt(E.backdropPadding), ae = nt.heights[b], Ft = nt.widths[b];
|
|
@@ -4912,7 +4912,7 @@ class Gt extends ut {
|
|
|
4912
4912
|
textAlign: Zt,
|
|
4913
4913
|
textBaseline: q,
|
|
4914
4914
|
translation: [
|
|
4915
|
-
|
|
4915
|
+
_,
|
|
4916
4916
|
w
|
|
4917
4917
|
],
|
|
4918
4918
|
backdrop: Ee
|
|
@@ -6123,7 +6123,7 @@ function gi(i, t, e, s, n, o) {
|
|
|
6123
6123
|
const E = h > 0 ? h - s : 0, W = d > 0 ? d - s : 0, $ = (E + W) / 2, ct = $ !== 0 ? g * $ / ($ + s) : g;
|
|
6124
6124
|
f = (g - ct) / 2;
|
|
6125
6125
|
}
|
|
6126
|
-
const p = Math.max(1e-3, g * d - e / V) / d, m = (g - p) / 2, b = l + m + f, x = n - m - f, { outerStart:
|
|
6126
|
+
const p = Math.max(1e-3, g * d - e / V) / d, m = (g - p) / 2, b = l + m + f, x = n - m - f, { outerStart: y, outerEnd: v, innerStart: _, innerEnd: w } = zc(t, u, d, x - b), M = d - y, S = d - v, P = b + y / M, D = x - v / S, A = u + _, T = u + w, q = b + _ / A, nt = x - w / T;
|
|
6127
6127
|
if (i.beginPath(), o) {
|
|
6128
6128
|
const E = (P + D) / 2;
|
|
6129
6129
|
if (i.arc(a, r, d, P, E), i.arc(a, r, d, E, D), v > 0) {
|
|
@@ -6135,15 +6135,15 @@ function gi(i, t, e, s, n, o) {
|
|
|
6135
6135
|
const Z = te(T, nt, a, r);
|
|
6136
6136
|
i.arc(Z.x, Z.y, w, x + Y, nt + Math.PI);
|
|
6137
6137
|
}
|
|
6138
|
-
const $ = (x - w / u + (b +
|
|
6139
|
-
if (i.arc(a, r, u, x - w / u, $, !0), i.arc(a, r, u, $, b +
|
|
6138
|
+
const $ = (x - w / u + (b + _ / u)) / 2;
|
|
6139
|
+
if (i.arc(a, r, u, x - w / u, $, !0), i.arc(a, r, u, $, b + _ / u, !0), _ > 0) {
|
|
6140
6140
|
const Z = te(A, q, a, r);
|
|
6141
|
-
i.arc(Z.x, Z.y,
|
|
6141
|
+
i.arc(Z.x, Z.y, _, q + Math.PI, b - Y);
|
|
6142
6142
|
}
|
|
6143
6143
|
const ct = te(M, b, a, r);
|
|
6144
|
-
if (i.lineTo(ct.x, ct.y),
|
|
6144
|
+
if (i.lineTo(ct.x, ct.y), y > 0) {
|
|
6145
6145
|
const Z = te(M, P, a, r);
|
|
6146
|
-
i.arc(Z.x, Z.y,
|
|
6146
|
+
i.arc(Z.x, Z.y, y, b - Y, P);
|
|
6147
6147
|
}
|
|
6148
6148
|
} else {
|
|
6149
6149
|
i.moveTo(a, r);
|
|
@@ -6281,16 +6281,16 @@ function Hc(i, t, e, s) {
|
|
|
6281
6281
|
function jc(i, t, e, s) {
|
|
6282
6282
|
const n = t.points, { count: o, start: a, ilen: r } = Wo(n, e, s), { move: l = !0, reverse: c } = s || {};
|
|
6283
6283
|
let h = 0, d = 0, u, f, g, p, m, b;
|
|
6284
|
-
const x = (v) => (a + (c ? r - v : v)) % o,
|
|
6284
|
+
const x = (v) => (a + (c ? r - v : v)) % o, y = () => {
|
|
6285
6285
|
p !== m && (i.lineTo(h, m), i.lineTo(h, p), i.lineTo(h, b));
|
|
6286
6286
|
};
|
|
6287
6287
|
for (l && (f = n[x(0)], i.moveTo(f.x, f.y)), u = 0; u <= r; ++u) {
|
|
6288
6288
|
if (f = n[x(u)], f.skip)
|
|
6289
6289
|
continue;
|
|
6290
|
-
const v = f.x,
|
|
6291
|
-
w === g ? (
|
|
6290
|
+
const v = f.x, _ = f.y, w = v | 0;
|
|
6291
|
+
w === g ? (_ < p ? p = _ : _ > m && (m = _), h = (d * h + v) / ++d) : (y(), i.lineTo(v, _), g = w, d = 0, p = m = _), b = _;
|
|
6292
6292
|
}
|
|
6293
|
-
|
|
6293
|
+
y();
|
|
6294
6294
|
}
|
|
6295
6295
|
function Ui(i) {
|
|
6296
6296
|
const t = i.options, e = t.borderDash && t.borderDash.length;
|
|
@@ -6677,10 +6677,10 @@ function lh(i, t, e, s, n) {
|
|
|
6677
6677
|
let h = t, d, u, f, g, p;
|
|
6678
6678
|
for (a[l++] = i[h], d = 0; d < o - 2; d++) {
|
|
6679
6679
|
let m = 0, b = 0, x;
|
|
6680
|
-
const
|
|
6681
|
-
for (x =
|
|
6680
|
+
const y = Math.floor((d + 1) * r) + 1 + t, v = Math.min(Math.floor((d + 2) * r) + 1, e) + t, _ = v - y;
|
|
6681
|
+
for (x = y; x < v; x++)
|
|
6682
6682
|
m += i[x].x, b += i[x].y;
|
|
6683
|
-
m /=
|
|
6683
|
+
m /= _, b /= _;
|
|
6684
6684
|
const w = Math.floor(d * r) + 1 + t, M = Math.min(Math.floor((d + 1) * r) + 1, e) + t, { x: S, y: P } = i[h];
|
|
6685
6685
|
for (f = g = -1, x = w; x < M; x++)
|
|
6686
6686
|
g = 0.5 * Math.abs((S - m) * (i[x].y - P) - (S - i[x].x) * (b - P)), g > f && (f = g, u = i[x], p = x);
|
|
@@ -6693,8 +6693,8 @@ function ch(i, t, e, s) {
|
|
|
6693
6693
|
const m = [], b = t + e - 1, x = i[t].x, v = i[b].x - x;
|
|
6694
6694
|
for (a = t; a < t + e; ++a) {
|
|
6695
6695
|
r = i[a], l = (r.x - x) / v * s, c = r.y;
|
|
6696
|
-
const
|
|
6697
|
-
if (
|
|
6696
|
+
const _ = l | 0;
|
|
6697
|
+
if (_ === h)
|
|
6698
6698
|
c < g ? (g = c, d = a) : c > p && (p = c, u = a), n = (o * n + r.x) / ++o;
|
|
6699
6699
|
else {
|
|
6700
6700
|
const w = a - 1;
|
|
@@ -6708,7 +6708,7 @@ function ch(i, t, e, s) {
|
|
|
6708
6708
|
x: n
|
|
6709
6709
|
});
|
|
6710
6710
|
}
|
|
6711
|
-
a > 0 && w !== f && m.push(i[w]), m.push(r), h =
|
|
6711
|
+
a > 0 && w !== f && m.push(i[w]), m.push(r), h = _, o = 0, g = p = c, d = u = f = a;
|
|
6712
6712
|
}
|
|
6713
6713
|
}
|
|
6714
6714
|
return m;
|
|
@@ -7217,8 +7217,8 @@ class Dn extends ut {
|
|
|
7217
7217
|
const { ctx: o, maxHeight: a, options: { labels: { padding: r } } } = this, l = this.legendHitBoxes = [], c = this.columnSizes = [], h = a - t;
|
|
7218
7218
|
let d = r, u = 0, f = 0, g = 0, p = 0;
|
|
7219
7219
|
return this.legendItems.forEach((m, b) => {
|
|
7220
|
-
const { itemWidth: x, itemHeight:
|
|
7221
|
-
b > 0 && f +
|
|
7220
|
+
const { itemWidth: x, itemHeight: y } = Rh(s, e, o, m, n);
|
|
7221
|
+
b > 0 && f + y + 2 * r > h && (d += u + r, c.push({
|
|
7222
7222
|
width: u,
|
|
7223
7223
|
height: f
|
|
7224
7224
|
}), g += u + r, p++, u = f = 0), l[b] = {
|
|
@@ -7226,8 +7226,8 @@ class Dn extends ut {
|
|
|
7226
7226
|
top: f,
|
|
7227
7227
|
col: p,
|
|
7228
7228
|
width: x,
|
|
7229
|
-
height:
|
|
7230
|
-
}, u = Math.max(u, x), f +=
|
|
7229
|
+
height: y
|
|
7230
|
+
}, u = Math.max(u, x), f += y + r;
|
|
7231
7231
|
}), d += u, c.push({
|
|
7232
7232
|
width: u,
|
|
7233
7233
|
height: f
|
|
@@ -7289,8 +7289,8 @@ class Dn extends ut {
|
|
|
7289
7289
|
strikethrough: S.hidden,
|
|
7290
7290
|
textAlign: l.textAlign(S.textAlign)
|
|
7291
7291
|
});
|
|
7292
|
-
},
|
|
7293
|
-
|
|
7292
|
+
}, y = this.isHorizontal(), v = this._computeTitleHeight();
|
|
7293
|
+
y ? f = {
|
|
7294
7294
|
x: J(o, this.left + h, this.right - s[0]),
|
|
7295
7295
|
y: this.top + h + v,
|
|
7296
7296
|
line: 0
|
|
@@ -7299,20 +7299,20 @@ class Dn extends ut {
|
|
|
7299
7299
|
y: J(o, this.top + v + h, this.bottom - e[0].height),
|
|
7300
7300
|
line: 0
|
|
7301
7301
|
}, ko(this.ctx, t.textDirection);
|
|
7302
|
-
const
|
|
7302
|
+
const _ = m + h;
|
|
7303
7303
|
this.legendItems.forEach((w, M) => {
|
|
7304
7304
|
n.strokeStyle = w.fontColor, n.fillStyle = w.fontColor;
|
|
7305
7305
|
const S = n.measureText(w.text).width, P = l.textAlign(w.textAlign || (w.textAlign = a.textAlign)), D = g + u + S;
|
|
7306
7306
|
let A = f.x, T = f.y;
|
|
7307
|
-
l.setWidth(this.width),
|
|
7307
|
+
l.setWidth(this.width), y ? M > 0 && A + D + h > this.right && (T = f.y += _, f.line++, A = f.x = J(o, this.left + h, this.right - s[f.line])) : M > 0 && T + _ > this.bottom && (A = f.x = A + e[f.line].width + h, f.line++, T = f.y = J(o, this.top + v + h, this.bottom - e[f.line].height));
|
|
7308
7308
|
const q = l.x(A);
|
|
7309
|
-
if (b(q, T, w), A = Qa(P, A + g + u,
|
|
7309
|
+
if (b(q, T, w), A = Qa(P, A + g + u, y ? A + D : this.right, t.rtl), x(l.x(A), T, w), y)
|
|
7310
7310
|
f.x += D + h;
|
|
7311
7311
|
else if (typeof w.text != "string") {
|
|
7312
7312
|
const nt = c.lineHeight;
|
|
7313
7313
|
f.y += Xo(w, nt) + h;
|
|
7314
7314
|
} else
|
|
7315
|
-
f.y +=
|
|
7315
|
+
f.y += _;
|
|
7316
7316
|
}), wo(this.ctx, t.textDirection);
|
|
7317
7317
|
}
|
|
7318
7318
|
drawTitle() {
|
|
@@ -7664,19 +7664,19 @@ function Nh(i, t) {
|
|
|
7664
7664
|
}
|
|
7665
7665
|
function An(i, t) {
|
|
7666
7666
|
const e = i.chart.ctx, { body: s, footer: n, title: o } = i, { boxWidth: a, boxHeight: r } = t, l = X(t.bodyFont), c = X(t.titleFont), h = X(t.footerFont), d = o.length, u = n.length, f = s.length, g = tt(t.padding);
|
|
7667
|
-
let p = g.height, m = 0, b = s.reduce((v,
|
|
7667
|
+
let p = g.height, m = 0, b = s.reduce((v, _) => v + _.before.length + _.lines.length + _.after.length, 0);
|
|
7668
7668
|
if (b += i.beforeBody.length + i.afterBody.length, d && (p += d * c.lineHeight + (d - 1) * t.titleSpacing + t.titleMarginBottom), b) {
|
|
7669
7669
|
const v = t.displayColors ? Math.max(r, l.lineHeight) : l.lineHeight;
|
|
7670
7670
|
p += f * v + (b - f) * l.lineHeight + (b - 1) * t.bodySpacing;
|
|
7671
7671
|
}
|
|
7672
7672
|
u && (p += t.footerMarginTop + u * h.lineHeight + (u - 1) * t.footerSpacing);
|
|
7673
7673
|
let x = 0;
|
|
7674
|
-
const
|
|
7674
|
+
const y = function(v) {
|
|
7675
7675
|
m = Math.max(m, e.measureText(v).width + x);
|
|
7676
7676
|
};
|
|
7677
|
-
return e.save(), e.font = c.string, F(i.title,
|
|
7678
|
-
F(v.before,
|
|
7679
|
-
}), x = 0, e.font = h.string, F(i.footer,
|
|
7677
|
+
return e.save(), e.font = c.string, F(i.title, y), e.font = l.string, F(i.beforeBody.concat(i.afterBody), y), x = t.displayColors ? a + 2 + t.boxPadding : 0, F(s, (v) => {
|
|
7678
|
+
F(v.before, y), F(v.lines, y), F(v.after, y);
|
|
7679
|
+
}), x = 0, e.font = h.string, F(i.footer, y), e.restore(), m += g.width, {
|
|
7680
7680
|
width: m,
|
|
7681
7681
|
height: p
|
|
7682
7682
|
};
|
|
@@ -7880,14 +7880,14 @@ class qi extends ut {
|
|
|
7880
7880
|
}
|
|
7881
7881
|
getCaretPosition(t, e, s) {
|
|
7882
7882
|
const { xAlign: n, yAlign: o } = this, { caretSize: a, cornerRadius: r } = s, { topLeft: l, topRight: c, bottomLeft: h, bottomRight: d } = Ut(r), { x: u, y: f } = t, { width: g, height: p } = e;
|
|
7883
|
-
let m, b, x,
|
|
7884
|
-
return o === "center" ? (v = f + p / 2, n === "left" ? (m = u, b = m - a,
|
|
7883
|
+
let m, b, x, y, v, _;
|
|
7884
|
+
return o === "center" ? (v = f + p / 2, n === "left" ? (m = u, b = m - a, y = v + a, _ = v - a) : (m = u + g, b = m + a, y = v - a, _ = v + a), x = m) : (n === "left" ? b = u + Math.max(l, h) + a : n === "right" ? b = u + g - Math.max(c, d) - a : b = this.caretX, o === "top" ? (y = f, v = y - a, m = b - a, x = b + a) : (y = f + p, v = y + a, m = b + a, x = b - a), _ = y), {
|
|
7885
7885
|
x1: m,
|
|
7886
7886
|
x2: b,
|
|
7887
7887
|
x3: x,
|
|
7888
|
-
y1:
|
|
7888
|
+
y1: y,
|
|
7889
7889
|
y2: v,
|
|
7890
|
-
y3:
|
|
7890
|
+
y3: _
|
|
7891
7891
|
};
|
|
7892
7892
|
}
|
|
7893
7893
|
drawTitle(t, e, s) {
|
|
@@ -7934,10 +7934,10 @@ class qi extends ut {
|
|
|
7934
7934
|
const g = ee(s.rtl, this.x, this.width), p = function(S) {
|
|
7935
7935
|
e.fillText(S, g.x(t.x + f), t.y + u / 2), t.y += u + o;
|
|
7936
7936
|
}, m = g.textAlign(a);
|
|
7937
|
-
let b, x,
|
|
7937
|
+
let b, x, y, v, _, w, M;
|
|
7938
7938
|
for (e.textAlign = a, e.textBaseline = "middle", e.font = d.string, t.x = Ke(this, m, s), e.fillStyle = s.bodyColor, F(this.beforeBody, p), f = r && m !== "right" ? a === "center" ? c / 2 + h : c + 2 + h : 0, v = 0, w = n.length; v < w; ++v) {
|
|
7939
|
-
for (b = n[v], x = this.labelTextColors[v], e.fillStyle = x, F(b.before, p),
|
|
7940
|
-
p(_
|
|
7939
|
+
for (b = n[v], x = this.labelTextColors[v], e.fillStyle = x, F(b.before, p), y = b.lines, r && y.length && (this._drawColorBox(e, t, v, g, s), u = Math.max(d.lineHeight, l)), _ = 0, M = y.length; _ < M; ++_)
|
|
7940
|
+
p(y[_]), u = d.lineHeight;
|
|
7941
7941
|
F(b.after, p);
|
|
7942
7942
|
}
|
|
7943
7943
|
f = 0, u = d.lineHeight, F(this.afterBody, p), t.y -= o;
|
|
@@ -8228,9 +8228,9 @@ k(Gi, "id", "category"), k(Gi, "defaults", {
|
|
|
8228
8228
|
}
|
|
8229
8229
|
});
|
|
8230
8230
|
function Qh(i, t) {
|
|
8231
|
-
const e = [], { bounds: n, step: o, min: a, max: r, precision: l, count: c, maxTicks: h, maxDigits: d, includeBounds: u } = i, f = o || 1, g = h - 1, { min: p, max: m } = t, b = !L(a), x = !L(r),
|
|
8232
|
-
let
|
|
8233
|
-
if (
|
|
8231
|
+
const e = [], { bounds: n, step: o, min: a, max: r, precision: l, count: c, maxTicks: h, maxDigits: d, includeBounds: u } = i, f = o || 1, g = h - 1, { min: p, max: m } = t, b = !L(a), x = !L(r), y = !L(c), v = (m - p) / (d + 1);
|
|
8232
|
+
let _ = Ds((m - p) / g / f) * f, w, M, S, P;
|
|
8233
|
+
if (_ < 1e-14 && !b && !x)
|
|
8234
8234
|
return [
|
|
8235
8235
|
{
|
|
8236
8236
|
value: p
|
|
@@ -8239,14 +8239,14 @@ function Qh(i, t) {
|
|
|
8239
8239
|
value: m
|
|
8240
8240
|
}
|
|
8241
8241
|
];
|
|
8242
|
-
P = Math.ceil(m /
|
|
8243
|
-
const D = Math.max(As(
|
|
8242
|
+
P = Math.ceil(m / _) - Math.floor(p / _), P > g && (_ = Ds(P * _ / g / f) * f), L(l) || (w = Math.pow(10, l), _ = Math.ceil(_ * w) / w), n === "ticks" ? (M = Math.floor(p / _) * _, S = Math.ceil(m / _) * _) : (M = p, S = m), b && x && o && Ua((r - a) / o, _ / 1e3) ? (P = Math.round(Math.min((r - a) / _, h)), _ = (r - a) / P, M = a, S = r) : y ? (M = b ? a : M, S = x ? r : S, P = c - 1, _ = (S - M) / P) : (P = (S - M) / _, ye(P, Math.round(P), _ / 1e3) ? P = Math.round(P) : P = Math.ceil(P));
|
|
8243
|
+
const D = Math.max(As(_), As(M));
|
|
8244
8244
|
w = Math.pow(10, L(l) ? D : l), M = Math.round(M * w) / w, S = Math.round(S * w) / w;
|
|
8245
8245
|
let A = 0;
|
|
8246
8246
|
for (b && (u && M !== a ? (e.push({
|
|
8247
8247
|
value: a
|
|
8248
|
-
}), M < a && A++, ye(Math.round((M + A *
|
|
8249
|
-
const T = Math.round((M + A *
|
|
8248
|
+
}), M < a && A++, ye(Math.round((M + A * _) * w) / w, a, En(a, v, i)) && A++) : M < a && A++); A < P; ++A) {
|
|
8249
|
+
const T = Math.round((M + A * _) * w) / w;
|
|
8250
8250
|
if (x && T > r)
|
|
8251
8251
|
break;
|
|
8252
8252
|
e.push({
|
|
@@ -9507,18 +9507,18 @@ const yd = { class: "flex flex-col h-full overflow-hidden" }, vd = { class: "fle
|
|
|
9507
9507
|
i.detail && i.widget.data.isAnomaly < 0 ? (I(), U("div", Gd, [
|
|
9508
9508
|
et($n, {
|
|
9509
9509
|
title: G(e)("report.view.insight.reason"),
|
|
9510
|
-
items: (b = i.widget.data.recommendations) == null ? void 0 : b.map((
|
|
9511
|
-
header:
|
|
9512
|
-
subLabel:
|
|
9513
|
-
defination:
|
|
9510
|
+
items: (b = i.widget.data.recommendations) == null ? void 0 : b.map((y) => ({
|
|
9511
|
+
header: y.label,
|
|
9512
|
+
subLabel: y.reason.replace(y.metric, y.label),
|
|
9513
|
+
defination: y.definition
|
|
9514
9514
|
}))
|
|
9515
9515
|
}, null, 8, ["title", "items"]),
|
|
9516
9516
|
et($n, {
|
|
9517
9517
|
title: G(e)("report.view.insight.recommendation"),
|
|
9518
|
-
items: (x = i.widget.data.recommendations) == null ? void 0 : x.map((
|
|
9519
|
-
header:
|
|
9520
|
-
subLabel:
|
|
9521
|
-
defination:
|
|
9518
|
+
items: (x = i.widget.data.recommendations) == null ? void 0 : x.map((y) => ({
|
|
9519
|
+
header: y.label,
|
|
9520
|
+
subLabel: y.recommendation,
|
|
9521
|
+
defination: y.definition
|
|
9522
9522
|
}))
|
|
9523
9523
|
}, null, 8, ["title", "items"])
|
|
9524
9524
|
])) : St("", !0),
|
|
@@ -9598,66 +9598,73 @@ const yd = { class: "flex flex-col h-full overflow-hidden" }, vd = { class: "fle
|
|
|
9598
9598
|
}, xu = /* @__PURE__ */ oe({
|
|
9599
9599
|
__name: "InsightView",
|
|
9600
9600
|
setup(i) {
|
|
9601
|
-
const { t } = Zn(), e = ha(), {
|
|
9601
|
+
const { t } = Zn(), e = ha(), {
|
|
9602
|
+
dateRange: s,
|
|
9603
|
+
compareDateRange: n,
|
|
9604
|
+
locations: o,
|
|
9605
|
+
selectedLocationIds: a,
|
|
9606
|
+
selectedRestaurantIds: r,
|
|
9607
|
+
business: l
|
|
9608
|
+
} = Jn(oa()), c = $t([]), h = $t(null), d = $t(!1), u = aa();
|
|
9602
9609
|
ri(
|
|
9603
|
-
|
|
9610
|
+
l,
|
|
9604
9611
|
() => {
|
|
9605
|
-
|
|
9612
|
+
l.value && f();
|
|
9606
9613
|
},
|
|
9607
9614
|
{ immediate: !0 }
|
|
9608
9615
|
);
|
|
9609
|
-
async function
|
|
9616
|
+
async function f() {
|
|
9610
9617
|
try {
|
|
9611
|
-
|
|
9618
|
+
d.value = !0, r.value.length === 0 ? c.value = [] : c.value = await ua({
|
|
9612
9619
|
start: s.value.startDate,
|
|
9613
9620
|
end: s.value.endDate,
|
|
9614
|
-
restaurantIds:
|
|
9621
|
+
restaurantIds: r.value
|
|
9615
9622
|
});
|
|
9616
|
-
} catch (
|
|
9617
|
-
|
|
9623
|
+
} catch (m) {
|
|
9624
|
+
u.open({ message: m, type: "error" }), c.value = [];
|
|
9618
9625
|
} finally {
|
|
9619
|
-
|
|
9626
|
+
d.value = !1;
|
|
9620
9627
|
}
|
|
9621
9628
|
}
|
|
9622
|
-
function
|
|
9623
|
-
if (
|
|
9629
|
+
function g(m) {
|
|
9630
|
+
if (m !== null) {
|
|
9624
9631
|
try {
|
|
9625
9632
|
e.pushDataLayer(
|
|
9626
9633
|
{
|
|
9627
9634
|
event: ca.report_insight_click_insight_card,
|
|
9628
|
-
insight: JSON.stringify(
|
|
9635
|
+
insight: JSON.stringify(c.value[m])
|
|
9629
9636
|
},
|
|
9630
9637
|
"insight"
|
|
9631
9638
|
);
|
|
9632
|
-
} catch (
|
|
9633
|
-
console.warn(
|
|
9639
|
+
} catch (b) {
|
|
9640
|
+
console.warn(b);
|
|
9634
9641
|
}
|
|
9635
|
-
|
|
9642
|
+
h.value = null;
|
|
9636
9643
|
}
|
|
9637
9644
|
ia(() => {
|
|
9638
|
-
|
|
9645
|
+
h.value = m;
|
|
9639
9646
|
});
|
|
9640
9647
|
}
|
|
9641
|
-
async function
|
|
9642
|
-
if (
|
|
9648
|
+
async function p(m) {
|
|
9649
|
+
if (h.value !== null)
|
|
9643
9650
|
try {
|
|
9644
|
-
|
|
9645
|
-
const
|
|
9646
|
-
...
|
|
9647
|
-
reaction:
|
|
9651
|
+
d.value = !0;
|
|
9652
|
+
const b = await fa({
|
|
9653
|
+
...c.value[h.value].feedback,
|
|
9654
|
+
reaction: m
|
|
9648
9655
|
});
|
|
9649
|
-
|
|
9650
|
-
} catch (
|
|
9651
|
-
|
|
9656
|
+
c.value[h.value].feedback = b;
|
|
9657
|
+
} catch (b) {
|
|
9658
|
+
u.open({ message: b, type: "error" });
|
|
9652
9659
|
} finally {
|
|
9653
|
-
|
|
9660
|
+
d.value = !1;
|
|
9654
9661
|
}
|
|
9655
9662
|
}
|
|
9656
|
-
return (
|
|
9657
|
-
const
|
|
9663
|
+
return (m, b) => {
|
|
9664
|
+
const x = Me("FmPageHead"), y = Me("FmCircularProgress");
|
|
9658
9665
|
return I(), Ht(sa, null, {
|
|
9659
9666
|
default: Yt(() => [
|
|
9660
|
-
et(
|
|
9667
|
+
et(x, {
|
|
9661
9668
|
title: G(t)("report.view.insight.title")
|
|
9662
9669
|
}, null, 8, ["title"]),
|
|
9663
9670
|
R("div", iu, [
|
|
@@ -9665,44 +9672,44 @@ const yd = { class: "flex flex-col h-full overflow-hidden" }, vd = { class: "fle
|
|
|
9665
9672
|
et(la, {
|
|
9666
9673
|
modelValue: G(a),
|
|
9667
9674
|
"onUpdate:modelValue": [
|
|
9668
|
-
|
|
9669
|
-
|
|
9675
|
+
b[0] || (b[0] = (v) => ki(a) ? a.value = v : null),
|
|
9676
|
+
f
|
|
9670
9677
|
],
|
|
9671
9678
|
options: G(o)
|
|
9672
9679
|
}, null, 8, ["modelValue", "options"]),
|
|
9673
9680
|
et(na, {
|
|
9674
9681
|
"date-range": G(s),
|
|
9675
9682
|
"onUpdate:dateRange": [
|
|
9676
|
-
|
|
9677
|
-
|
|
9683
|
+
b[1] || (b[1] = (v) => ki(s) ? s.value = v : null),
|
|
9684
|
+
f
|
|
9678
9685
|
],
|
|
9679
9686
|
"compare-date-range": G(n),
|
|
9680
|
-
"onUpdate:compareDateRange":
|
|
9687
|
+
"onUpdate:compareDateRange": b[2] || (b[2] = (v) => ki(n) ? n.value = v : null),
|
|
9681
9688
|
compare: !1
|
|
9682
9689
|
}, null, 8, ["date-range", "compare-date-range"])
|
|
9683
9690
|
])
|
|
9684
9691
|
]),
|
|
9685
|
-
|
|
9686
|
-
et(
|
|
9692
|
+
d.value ? (I(), U("div", nu, [
|
|
9693
|
+
et(y, { size: "xl" })
|
|
9687
9694
|
])) : (I(), U("div", ou, [
|
|
9688
|
-
|
|
9689
|
-
(I(!0), U(Ii, null, zi(
|
|
9690
|
-
key:
|
|
9691
|
-
widget:
|
|
9692
|
-
onClick: () =>
|
|
9695
|
+
c.value.length > 0 ? (I(), U("div", au, [
|
|
9696
|
+
(I(!0), U(Ii, null, zi(c.value, (v, _) => (I(), Ht(Yn, {
|
|
9697
|
+
key: _,
|
|
9698
|
+
widget: v,
|
|
9699
|
+
onClick: () => g(_)
|
|
9693
9700
|
}, null, 8, ["widget", "onClick"]))), 128))
|
|
9694
9701
|
])) : (I(), Ht(ra, { key: 1 }))
|
|
9695
9702
|
])),
|
|
9696
9703
|
et(eu, {
|
|
9697
|
-
"model-value":
|
|
9698
|
-
onBack:
|
|
9704
|
+
"model-value": h.value !== null,
|
|
9705
|
+
onBack: b[3] || (b[3] = () => g(null))
|
|
9699
9706
|
}, {
|
|
9700
9707
|
default: Yt(() => [
|
|
9701
|
-
|
|
9708
|
+
h.value !== null ? (I(), Ht(Yn, {
|
|
9702
9709
|
key: 0,
|
|
9703
|
-
widget:
|
|
9710
|
+
widget: c.value[h.value],
|
|
9704
9711
|
detail: "",
|
|
9705
|
-
onClickFeedback:
|
|
9712
|
+
onClickFeedback: p
|
|
9706
9713
|
}, null, 8, ["widget"])) : St("", !0)
|
|
9707
9714
|
]),
|
|
9708
9715
|
_: 1
|