@feedmepos/mf-report 5.26.7 → 5.26.8-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.
Files changed (23) hide show
  1. package/dist/{App-C94O_vo_.js → App-DE_KEBIH.js} +60 -60
  2. package/dist/{DateRangeSelect.vue_vue_type_script_setup_true_lang-Dn157Zx3.js → DateRangeSelect.vue_vue_type_script_setup_true_lang-D-OrSEoQ.js} +86 -87
  3. package/dist/{Default.vue_vue_type_script_setup_true_lang-nt4P42ea.js → Default.vue_vue_type_script_setup_true_lang-CLAOb_IH.js} +1 -1
  4. package/dist/{DynamicWidget.vue_vue_type_script_setup_true_lang-AQDQW9GO.js → DynamicWidget.vue_vue_type_script_setup_true_lang-Ce64O86J.js} +517 -519
  5. package/dist/{GlobalFilterSelect.vue_vue_type_script_setup_true_lang-C426Aob-.js → GlobalFilterSelect.vue_vue_type_script_setup_true_lang-C-VMmoAn.js} +2 -2
  6. package/dist/{InsightView-Basufi0o.js → InsightView-CrtPd5NK.js} +4 -4
  7. package/dist/{Integration-B920vZDz.js → Integration-BgeaRR7r.js} +3 -3
  8. package/dist/{Integrations-_VxUzyV_.js → Integrations-DN6xsH_b.js} +2 -2
  9. package/dist/{Layout-C3EdQj0a.js → Layout-0YuYHsP9.js} +1 -1
  10. package/dist/{MenuTab.vue_vue_type_script_setup_true_lang-cx9Ls4VN.js → MenuTab.vue_vue_type_script_setup_true_lang-DGVKRwJG.js} +4 -4
  11. package/dist/{NavigationTab.vue_vue_type_script_setup_true_lang-BZdj0yom.js → NavigationTab.vue_vue_type_script_setup_true_lang-DF_ew8-o.js} +3 -3
  12. package/dist/{OverviewView-5SW5eV5d.js → OverviewView-C9OhZlDm.js} +4 -4
  13. package/dist/{Report-D7QE2m9x.js → Report-jrADalOt.js} +3 -3
  14. package/dist/{ReportEditor-CRGL55-B.js → ReportEditor-CC_RuLmB.js} +5 -5
  15. package/dist/{ReportView-DPTA33K1.js → ReportView-Bd0SdK9d.js} +6 -6
  16. package/dist/{Setting-Dc9348RB.js → Setting-C-D6wGwY.js} +3 -3
  17. package/dist/{Template-DaeFfFJD.js → Template-Br43MDsi.js} +3 -3
  18. package/dist/{TileEditor-C4157Jus.js → TileEditor-By4srlF6.js} +778 -783
  19. package/dist/{TransitionFade-B0iVN3no.js → TransitionFade-B7Q98m7o.js} +4 -4
  20. package/dist/{app-CtnYfBf0.js → app-BIczSq7p.js} +13 -13
  21. package/dist/app.js +1 -1
  22. package/dist/{useRestaurantPermission-dtgeWEXZ.js → useRestaurantPermission-B8mLE1Px.js} +1 -1
  23. package/package.json +1 -1
@@ -1,41 +1,41 @@
1
- import { defineComponent as ue, resolveComponent as H, createBlock as le, openBlock as C, unref as l, isRef as ke, withCtx as P, createElementVNode as ne, createVNode as X, toDisplayString as ae, createTextVNode as Te, onMounted as de, watch as E, ref as Q, computed as oe, onBeforeMount as Fe, onBeforeUnmount as Ne, createElementBlock as G, Fragment as $e } from "vue";
2
- import { detectLocale as U, useCoreStore as K } from "@feedmepos/mf-common";
3
- import { d as u, u as qe, a as re, b as Be, c as se, e as xe, f as Je, s as Qe, t as W } from "./app-CtnYfBf0.js";
1
+ import { defineComponent as ue, resolveComponent as H, createBlock as de, openBlock as E, unref as d, isRef as ke, withCtx as W, createElementVNode as ne, createVNode as X, toDisplayString as ae, createTextVNode as Te, onMounted as le, watch as C, ref as Q, computed as oe, onBeforeMount as Ne, onBeforeUnmount as qe, createElementBlock as K, Fragment as Fe } from "vue";
2
+ import { detectLocale as U, useCoreStore as P } from "@feedmepos/mf-common";
3
+ import { d as u, u as $e, a as re, b as Be, c as se, e as xe, f as Je, s as Qe, t as G } from "./app-BIczSq7p.js";
4
4
  import { storeToRefs as k } from "pinia";
5
5
  import { u as Ue, a as ze } from "./vue-i18n-DVWuTfed.js";
6
- import { u as je, a as Ve } from "./GlobalFilterSelect.vue_vue_type_script_setup_true_lang-C426Aob-.js";
7
- import { u as Pe, _ as Ge } from "./NavigationTab.vue_vue_type_script_setup_true_lang-BZdj0yom.js";
6
+ import { u as je, a as Ve } from "./GlobalFilterSelect.vue_vue_type_script_setup_true_lang-C-VMmoAn.js";
7
+ import { u as We, _ as Ke } from "./NavigationTab.vue_vue_type_script_setup_true_lang-DF_ew8-o.js";
8
8
  import { u as ie } from "./message-dialog-UoMWOnil.js";
9
- import { useRoute as Ke, useRouter as We } from "vue-router";
9
+ import { useRoute as Pe, useRouter as Ge } from "vue-router";
10
10
  const He = { class: "fm-typo-en-body-md-400 text-ellipsis overflow-hidden" }, Xe = /* @__PURE__ */ ue({
11
11
  __name: "Dialog",
12
12
  setup(T) {
13
13
  const { t: c } = Ue(), p = ie(), { isOpened: g, message: _, title: L } = k(ie());
14
14
  return (O, I) => {
15
- const F = H("FmButton"), z = H("FmDialog");
16
- return C(), le(z, {
17
- modelValue: l(g),
15
+ const N = H("FmButton"), z = H("FmDialog");
16
+ return E(), de(z, {
17
+ modelValue: d(g),
18
18
  "onUpdate:modelValue": I[0] || (I[0] = (j) => ke(g) ? g.value = j : null),
19
19
  overlay: "",
20
20
  "close-button": !1,
21
21
  "z-index": 3e3
22
22
  }, {
23
- "dialog-header": P(() => [
24
- Te(ae(l(L)), 1)
23
+ "dialog-header": W(() => [
24
+ Te(ae(d(L)), 1)
25
25
  ]),
26
- default: P(() => [
27
- ne("p", He, ae(l(_)), 1)
26
+ default: W(() => [
27
+ ne("p", He, ae(d(_)), 1)
28
28
  ]),
29
- "dialog-footer": P(() => [
29
+ "dialog-footer": W(() => [
30
30
  I[1] || (I[1] = ne("div", { class: "grow" }, null, -1)),
31
- X(F, {
32
- label: l(c)("report.common.cancel"),
31
+ X(N, {
32
+ label: d(c)("report.common.cancel"),
33
33
  variant: "tertiary",
34
- onClick: l(p).dismiss
34
+ onClick: d(p).dismiss
35
35
  }, null, 8, ["label", "onClick"]),
36
- X(F, {
37
- label: l(c)("report.common.confirm"),
38
- onClick: l(p).confirm
36
+ X(N, {
37
+ label: d(c)("report.common.confirm"),
38
+ onClick: d(p).confirm
39
39
  }, null, 8, ["label", "onClick"])
40
40
  ]),
41
41
  _: 1
@@ -54,9 +54,9 @@ function Ye() {
54
54
  break;
55
55
  }
56
56
  };
57
- return de(() => {
57
+ return le(() => {
58
58
  T(U());
59
- }), E(() => U(), T, { deep: !0, immediate: !0 }), {
59
+ }), C(() => U(), T, { deep: !0, immediate: !0 }), {
60
60
  currentLocale: ce
61
61
  };
62
62
  }
@@ -64,8 +64,8 @@ u.locale(U() === "zh-CN" ? "zh-cn" : "en");
64
64
  const Ze = ["src"], Me = ["src"], ft = /* @__PURE__ */ ue({
65
65
  __name: "App",
66
66
  setup(T) {
67
- const { businessId: c, token: p, country: g } = k(qe()), { sessionUser: _, currentBusiness: L, currentCountry: O, registerSidebarComponent: I } = K(), { getRestaurantAndWarehouse: F, getBusinessSetting: z, beginBusinessLoad: j, completeBusinessLoad: fe } = re(), me = Be(), { getFeatureFlags: pe } = me, { version: v } = k(se()), { getSettings: ge } = xe(), { promptLoader: ve } = ze(), a = Ke(), N = We(), w = je(), Y = Pe(), s = re(), b = se(), { suppressReportRouteSync: $ } = k(b), { getReports: ye, getOverviewReport: Se, getReportConfig: De, currentReportId: Z } = w, { currentReportId: Ie, reports: he } = k(w), { getSchema: Re } = Ve(), { fetchSchedules: _e } = Y, { init: Le } = Je(), V = Q("v5"), q = Q(!1), B = Q(!0), Oe = oe(() => `https://portal-v1.feedme.cc/b/${c.value}/report/CLOSE_UP?showHeader=false&country=${g.value.toUpperCase()}&menuOption=business-report&token=${p.value}&v2=true&reportV5Button=true`), we = oe(() => `https://report-v4.feedme.cc?businessId=${c.value}&country=${g.value}&token=${p.value}&reportV3Button=true`);
68
- E(
67
+ const { businessId: c, token: p, country: g } = k($e()), { sessionUser: _, currentBusiness: L, currentCountry: O, registerSidebarComponent: I } = P(), { getRestaurantAndWarehouse: N, getBusinessSetting: z, beginBusinessLoad: j, completeBusinessLoad: fe } = re(), me = Be(), { getFeatureFlags: pe } = me, { version: v } = k(se()), { getSettings: ge } = xe(), { promptLoader: ve } = ze(), a = Pe(), q = Ge(), w = je(), Y = We(), s = re(), b = se(), { suppressReportRouteSync: F } = k(b), { getReports: ye, getOverviewReport: Se, getReportConfig: De, currentReportId: Z } = w, { currentReportId: Ie, reports: he } = k(w), { getSchema: Re } = Ve(), { fetchSchedules: _e } = Y, { init: Le } = Je(), V = Q("v5"), $ = Q(!1), B = Q(!0), Oe = oe(() => `https://portal-v1.feedmedev.cc/b/${c.value}/report/CLOSE_UP?showHeader=false&country=${g.value.toUpperCase()}&menuOption=business-report&token=${p.value}&v2=true&reportV5Button=true`), we = oe(() => `https://report-v4.feedmedev.cc?businessId=${c.value}&country=${g.value}&token=${p.value}&reportV3Button=true`);
68
+ C(
69
69
  [() => L.value, () => _.value, () => O.value],
70
70
  () => {
71
71
  var e, n;
@@ -92,13 +92,13 @@ const Ze = ["src"], Me = ["src"], ft = /* @__PURE__ */ ue({
92
92
  console.error(e);
93
93
  }
94
94
  }
95
- E(v, () => {
96
- ["v3", "v4"].includes(v.value) ? K().hideSidebarToggle(!0) : K().hideSidebarToggle(!1);
97
- }), Fe(() => {
98
- I(Ge);
99
- }), de(() => {
100
- console.log("5.26.7", !0), window.addEventListener("message", M), window.addEventListener("message", ee);
95
+ C(v, () => {
96
+ ["v3", "v4"].includes(v.value) ? P().hideSidebarToggle(!0) : P().hideSidebarToggle(!1);
101
97
  }), Ne(() => {
98
+ I(Ke);
99
+ }), le(() => {
100
+ console.log("5.26.8-beta.0", !0), window.addEventListener("message", M), window.addEventListener("message", ee);
101
+ }), qe(() => {
102
102
  window.removeEventListener("message", M), window.removeEventListener("message", ee), w.$dispose(), Y.$dispose();
103
103
  });
104
104
  function be(t) {
@@ -130,7 +130,7 @@ const Ze = ["src"], Me = ["src"], ft = /* @__PURE__ */ ue({
130
130
  return typeof e.hour == "number" && typeof e.minute == "number";
131
131
  }
132
132
  function Ae(t = a.query) {
133
- const e = t, n = e.startDate ? u(e.startDate).startOf("day").toISOString() : void 0, o = e.endDate ? u(e.endDate).endOf("day").toISOString() : void 0, d = typeof e.timeStart == "string", i = typeof e.timeEnd == "string", f = x(e.timeStart), y = x(e.timeEnd), m = te(f) ? f : null, J = te(y) ? y : null, A = e.compareStartDate ? u(e.compareStartDate).startOf("day").toISOString() : void 0, S = e.compareEndDate ? u(e.compareEndDate).endOf("day").toISOString() : void 0, h = e.isAllLocation === "true" || e.isAllLocation === void 0;
133
+ const e = t, n = e.startDate ? u(e.startDate).startOf("day").toISOString() : void 0, o = e.endDate ? u(e.endDate).endOf("day").toISOString() : void 0, l = typeof e.timeStart == "string", i = typeof e.timeEnd == "string", f = x(e.timeStart), y = x(e.timeEnd), m = te(f) ? f : null, J = te(y) ? y : null, A = e.compareStartDate ? u(e.compareStartDate).startOf("day").toISOString() : void 0, S = e.compareEndDate ? u(e.compareEndDate).endOf("day").toISOString() : void 0, h = e.isAllLocation === "true" || e.isAllLocation === void 0;
134
134
  let D = [];
135
135
  if (h)
136
136
  D = s.selectedLocationIds ?? [];
@@ -143,7 +143,7 @@ const Ze = ["src"], Me = ["src"], ft = /* @__PURE__ */ ue({
143
143
  const r = s.dateRange;
144
144
  (r.startDate !== n || r.endDate !== o) && s.setDateRange({ startDate: n, endDate: o });
145
145
  }
146
- if (d || i) {
146
+ if (l || i) {
147
147
  const r = s.timeRange;
148
148
  (r.start !== m || r.end !== J) && s.setTimeRange({ start: m, end: J });
149
149
  }
@@ -156,7 +156,7 @@ const Ze = ["src"], Me = ["src"], ft = /* @__PURE__ */ ue({
156
156
  }
157
157
  if (!h) {
158
158
  const r = s.selectedLocationIds;
159
- r.length === D.length && r.every((Ce, Ee) => Ce === D[Ee]) || s.setSelectedLocationIds(D);
159
+ r.length === D.length && r.every((Ee, Ce) => Ee === D[Ce]) || s.setSelectedLocationIds(D);
160
160
  }
161
161
  return {
162
162
  // TODO: this returned value can used for getBusinessSetting
@@ -171,54 +171,54 @@ const Ze = ["src"], Me = ["src"], ft = /* @__PURE__ */ ue({
171
171
  isAllLocation: e.isAllLocation
172
172
  };
173
173
  }
174
- return E(
174
+ return C(
175
175
  () => c.value,
176
176
  async (t, e) => {
177
177
  if (t !== "") {
178
- q.value = !1, j(t);
178
+ $.value = !1, j(t);
179
179
  const n = "mf-report-prev-business-id", o = (() => {
180
180
  try {
181
181
  return sessionStorage.getItem(n);
182
182
  } catch {
183
183
  return null;
184
184
  }
185
- })(), d = !!o && o !== t;
185
+ })(), l = !!o && o !== t;
186
186
  let i = { ...a.query }, f = !1;
187
- if (!B.value || e !== void 0 || d) {
187
+ if (!B.value || e !== void 0 || l) {
188
188
  s.setSelectedLocationIds([]);
189
189
  const { locationIds: y, ...m } = a.query;
190
190
  i = {
191
191
  ...m,
192
192
  isAllLocation: "true"
193
- }, f = !0, await N.replace({
193
+ }, f = !0, await q.replace({
194
194
  name: a.name,
195
195
  params: a.params,
196
196
  query: i
197
197
  });
198
198
  }
199
- $.value !== void 0 && ($.value = !0), await ve(async () => {
199
+ F.value !== void 0 && (F.value = !0), await ve(async () => {
200
200
  await Le({
201
- apiKey: "6GhcttsJ9Rj9cTevcdrpin",
201
+ apiKey: "MaGoXrEWuEJNpWgKTqseee",
202
202
  url: "https://flag.feedme.farm/api/v1/",
203
203
  enableAnalytics: !1,
204
204
  cacheFlags: !1
205
205
  });
206
206
  const y = await De();
207
- V.value = y.version, v.value = V.value, await pe(), a.name === "template" && !b.canAccessTemplate() && await N.replace({
207
+ V.value = y.version, v.value = V.value, await pe(), a.name === "template" && !b.canAccessTemplate() && await q.replace({
208
208
  name: "reports",
209
209
  query: a.query
210
210
  });
211
211
  const m = b.canAccess(
212
- W.report_accessOverview
212
+ G.report_accessOverview
213
213
  ), J = b.canAccess(
214
- W.report_accessSetting
214
+ G.report_accessSetting
215
215
  ), A = b.canAccess(
216
- W.report_accessIntegration
216
+ G.report_accessIntegration
217
217
  ), S = [
218
218
  Re(),
219
219
  _e(),
220
220
  ye(),
221
- F(
221
+ N(
222
222
  (() => {
223
223
  const h = x(i.locationIds);
224
224
  return Array.isArray(h) ? h : void 0;
@@ -227,7 +227,7 @@ const Ze = ["src"], Me = ["src"], ft = /* @__PURE__ */ ue({
227
227
  ];
228
228
  if (m && S.push(Se()), A && S.push(ge()), await Promise.all(S), J && await z(), Ae(i), f) {
229
229
  const { locationIds: h, ...D } = a.query;
230
- (a.query.locationIds !== void 0 || a.query.isAllLocation !== "true") && await N.replace({
230
+ (a.query.locationIds !== void 0 || a.query.isAllLocation !== "true") && await q.replace({
231
231
  name: a.name,
232
232
  params: a.params,
233
233
  query: {
@@ -241,14 +241,14 @@ const Ze = ["src"], Me = ["src"], ft = /* @__PURE__ */ ue({
241
241
  sessionStorage.setItem(n, t);
242
242
  } catch {
243
243
  }
244
- }), q.value = !0, B.value && (B.value = !1);
244
+ }), $.value = !0, B.value && (B.value = !1);
245
245
  }
246
246
  },
247
247
  {
248
248
  immediate: !0
249
249
  }
250
- ), E(
251
- () => (q.value, {
250
+ ), C(
251
+ () => ($.value, {
252
252
  reportId: Ie.value,
253
253
  selectedLocationIds: s.selectedLocationIds,
254
254
  dateRange: s.dateRange,
@@ -256,24 +256,24 @@ const Ze = ["src"], Me = ["src"], ft = /* @__PURE__ */ ue({
256
256
  compareDateRange: s.compareDateRange
257
257
  }),
258
258
  (t) => {
259
- if (!q.value || !t.reportId || B.value) return;
260
- if ($.value) {
261
- $.value = !1;
259
+ if (!$.value || !t.reportId || B.value) return;
260
+ if (F.value) {
261
+ F.value = !1;
262
262
  return;
263
263
  }
264
- const e = t.selectedLocationIds, n = t.dateRange, o = t.timeRange, d = t.compareDateRange, i = {
264
+ const e = t.selectedLocationIds, n = t.dateRange, o = t.timeRange, l = t.compareDateRange, i = {
265
265
  ...a.query,
266
266
  reportId: t.reportId,
267
267
  startDate: n.startDate ? u(n.startDate).startOf("day").toISOString() : void 0,
268
268
  endDate: n.endDate ? u(n.endDate).endOf("day").toISOString() : void 0,
269
- compareStartDate: d.startDate ? u(d.startDate).startOf("day").toISOString() : void 0,
270
- compareEndDate: d.endDate ? u(d.endDate).endOf("day").toISOString() : void 0,
269
+ compareStartDate: l.startDate ? u(l.startDate).startOf("day").toISOString() : void 0,
270
+ compareEndDate: l.endDate ? u(l.endDate).endOf("day").toISOString() : void 0,
271
271
  timeStart: o.start ? JSON.stringify(o.start) : void 0,
272
272
  timeEnd: o.end ? JSON.stringify(o.end) : void 0
273
273
  }, f = e.length === s.locations.length;
274
274
  i.isAllLocation = String(f), f ? delete i.locationIds : e.length > 0 ? i.locationIds = JSON.stringify(e) : delete i.locationIds;
275
275
  const y = JSON.stringify(a.query), m = JSON.stringify(i);
276
- y !== m && N.replace({
276
+ y !== m && q.replace({
277
277
  name: a.name,
278
278
  params: a.params,
279
279
  query: i
@@ -282,17 +282,17 @@ const Ze = ["src"], Me = ["src"], ft = /* @__PURE__ */ ue({
282
282
  { deep: !0 }
283
283
  ), Ye(), (t, e) => {
284
284
  const n = H("router-view");
285
- return C(), G($e, null, [
285
+ return E(), K(Fe, null, [
286
286
  X(Xe),
287
- l(v) === "v3" ? (C(), G("iframe", {
287
+ d(v) === "v3" ? (E(), K("iframe", {
288
288
  key: 0,
289
289
  class: "bg-white h-full w-full",
290
290
  src: Oe.value
291
- }, null, 8, Ze)) : l(v) === "v4" ? (C(), G("iframe", {
291
+ }, null, 8, Ze)) : d(v) === "v4" ? (E(), K("iframe", {
292
292
  key: 1,
293
293
  class: "bg-white h-full w-full",
294
294
  src: we.value
295
- }, null, 8, Me)) : (C(), le(n, { key: 2 }))
295
+ }, null, 8, Me)) : (E(), de(n, { key: 2 }))
296
296
  ], 64);
297
297
  };
298
298
  }
@@ -1,12 +1,12 @@
1
- import { defineComponent as V, resolveComponent as C, createBlock as h, openBlock as D, normalizeClass as G, withCtx as I, createCommentVNode as x, createElementVNode as w, toDisplayString as H, renderSlot as K, mergeModels as L, useModel as E, ref as z, watch as F, createElementBlock as J, unref as y, createVNode as k } from "vue";
2
- import { d as u, a as Q, U as Z, C as ee } from "./app-CtnYfBf0.js";
3
- import { detectLocale as _ } from "@feedmepos/mf-common";
4
- import { u as ae } from "./vue-i18n-DVWuTfed.js";
5
- import { storeToRefs as te } from "pinia";
6
- const re = new RegExp("([\\p{Ll}\\d])(\\p{Lu})", "gu"), le = new RegExp("(\\p{Lu})([\\p{Lu}][\\p{Ll}])", "gu"), ne = new RegExp("(\\d)\\p{Ll}|(\\p{L})\\d", "u"), ce = /[^\p{L}\d]+/giu, O = "$1\0$2", U = "";
7
- function B(a) {
1
+ import { defineComponent as O, resolveComponent as C, createBlock as h, openBlock as D, normalizeClass as B, withCtx as I, createCommentVNode as x, createElementVNode as w, toDisplayString as W, renderSlot as X, mergeModels as M, useModel as E, ref as P, watch as $, createElementBlock as q, unref as y, createVNode as A } from "vue";
2
+ import { d as u, a as G, U as H, C as K } from "./app-BIczSq7p.js";
3
+ import { detectLocale as L } from "@feedmepos/mf-common";
4
+ import { u as J } from "./vue-i18n-DVWuTfed.js";
5
+ import { storeToRefs as Q } from "pinia";
6
+ const Z = new RegExp("([\\p{Ll}\\d])(\\p{Lu})", "gu"), ee = new RegExp("(\\p{Lu})([\\p{Lu}][\\p{Ll}])", "gu"), ae = new RegExp("(\\d)\\p{Ll}|(\\p{L})\\d", "u"), te = /[^\p{L}\d]+/giu, F = "$1\0$2", k = "";
7
+ function U(a) {
8
8
  let e = a.trim();
9
- e = e.replace(re, O).replace(le, O), e = e.replace(ce, "\0");
9
+ e = e.replace(Z, F).replace(ee, F), e = e.replace(te, "\0");
10
10
  let t = 0, r = e.length;
11
11
  for (; e.charAt(t) === "\0"; )
12
12
  t++;
@@ -16,10 +16,10 @@ function B(a) {
16
16
  r--;
17
17
  return e.slice(t, r).split(/\0/g);
18
18
  }
19
- function ue(a) {
20
- const e = B(a);
19
+ function re(a) {
20
+ const e = U(a);
21
21
  for (let t = 0; t < e.length; t++) {
22
- const r = e[t], n = ne.exec(r);
22
+ const r = e[t], n = ae.exec(r);
23
23
  if (n) {
24
24
  const l = n.index + (n[1] ?? n[2]).length;
25
25
  e.splice(t, 1, r.slice(0, l), r.slice(l));
@@ -27,21 +27,21 @@ function ue(a) {
27
27
  }
28
28
  return e;
29
29
  }
30
- function Re(a, e) {
31
- const [t, r, n] = T(a, e), l = S(e == null ? void 0 : e.locale), c = b(e == null ? void 0 : e.locale), s = e != null && e.mergeAmbiguousCharacters ? Y(l, c) : W(l, c);
32
- return t + r.map((d, m) => m === 0 ? l(d) : s(d, m)).join((e == null ? void 0 : e.delimiter) ?? "") + n;
30
+ function De(a, e) {
31
+ const [t, r, n] = T(a, e), l = S(e == null ? void 0 : e.locale), c = b(e == null ? void 0 : e.locale), s = e != null && e.mergeAmbiguousCharacters ? Y(l, c) : j(l, c);
32
+ return t + r.map((o, d) => d === 0 ? l(o) : s(o, d)).join((e == null ? void 0 : e.delimiter) ?? "") + n;
33
33
  }
34
- function pe(a, e) {
35
- const [t, r, n] = T(a, e), l = S(e == null ? void 0 : e.locale), c = b(e == null ? void 0 : e.locale), s = e != null && e.mergeAmbiguousCharacters ? Y(l, c) : W(l, c);
34
+ function ge(a, e) {
35
+ const [t, r, n] = T(a, e), l = S(e == null ? void 0 : e.locale), c = b(e == null ? void 0 : e.locale), s = e != null && e.mergeAmbiguousCharacters ? Y(l, c) : j(l, c);
36
36
  return t + r.map(s).join((e == null ? void 0 : e.delimiter) ?? "") + n;
37
37
  }
38
- function Ce(a, e) {
38
+ function he(a, e) {
39
39
  const [t, r, n] = T(a, e), l = S(e == null ? void 0 : e.locale), c = b(e == null ? void 0 : e.locale);
40
40
  return t + r.map(Y(l, c)).join((e == null ? void 0 : e.delimiter) ?? " ") + n;
41
41
  }
42
- function xe(a, e) {
42
+ function ve(a, e) {
43
43
  const [t, r, n] = T(a, e), l = S(e == null ? void 0 : e.locale), c = b(e == null ? void 0 : e.locale), s = Y(l, c);
44
- return t + r.map((d, m) => m === 0 ? s(d) : l(d)).join((e == null ? void 0 : e.delimiter) ?? " ") + n;
44
+ return t + r.map((o, d) => d === 0 ? s(o) : l(o)).join((e == null ? void 0 : e.delimiter) ?? " ") + n;
45
45
  }
46
46
  function S(a) {
47
47
  return a === !1 ? (e) => e.toLowerCase() : (e) => e.toLocaleLowerCase(a);
@@ -52,14 +52,14 @@ function b(a) {
52
52
  function Y(a, e) {
53
53
  return (t) => `${e(t[0])}${a(t.slice(1))}`;
54
54
  }
55
- function W(a, e) {
55
+ function j(a, e) {
56
56
  return (t, r) => {
57
57
  const n = t[0];
58
58
  return (r > 0 && n >= "0" && n <= "9" ? "_" + n : e(n)) + a(t.slice(1));
59
59
  };
60
60
  }
61
61
  function T(a, e = {}) {
62
- const t = e.split ?? (e.separateNumbers ? ue : B), r = e.prefixCharacters ?? U, n = e.suffixCharacters ?? U;
62
+ const t = e.split ?? (e.separateNumbers ? re : U), r = e.prefixCharacters ?? k, n = e.suffixCharacters ?? k;
63
63
  let l = 0, c = a.length;
64
64
  for (; l < a.length; ) {
65
65
  const s = a.charAt(l);
@@ -68,8 +68,8 @@ function T(a, e = {}) {
68
68
  l++;
69
69
  }
70
70
  for (; c > l; ) {
71
- const s = c - 1, d = a.charAt(s);
72
- if (!n.includes(d))
71
+ const s = c - 1, o = a.charAt(s);
72
+ if (!n.includes(o))
73
73
  break;
74
74
  c = s;
75
75
  }
@@ -79,8 +79,8 @@ function T(a, e = {}) {
79
79
  a.slice(c)
80
80
  ];
81
81
  }
82
- var v = /* @__PURE__ */ ((a) => (a.Year = "YEAR", a.Month = "MONTH", a.Week = "WEEK", a.Day = "DAY", a))(v || {}), se = /* @__PURE__ */ ((a) => (a.Yesterday = "YESTERDAY", a.Today = "TODAY", a))(se || {});
83
- function Se(a, e = 100) {
82
+ var v = /* @__PURE__ */ ((a) => (a.Year = "YEAR", a.Month = "MONTH", a.Week = "WEEK", a.Day = "DAY", a))(v || {}), le = /* @__PURE__ */ ((a) => (a.Yesterday = "YESTERDAY", a.Today = "TODAY", a))(le || {});
83
+ function Re(a, e = 100) {
84
84
  let t = null;
85
85
  const r = function(...n) {
86
86
  return t && clearTimeout(t), new Promise((l) => {
@@ -95,10 +95,10 @@ function Se(a, e = 100) {
95
95
  t && (clearTimeout(t), t = null);
96
96
  }, r;
97
97
  }
98
- function de() {
98
+ function ne() {
99
99
  return [...Array(12).keys()].map((a) => u().month(a).format("MMM"));
100
100
  }
101
- function be(a, e, t = "") {
101
+ function pe(a, e, t = "") {
102
102
  switch (a.type) {
103
103
  case v.Day:
104
104
  return e("report.schedule.everyDay");
@@ -127,7 +127,7 @@ function be(a, e, t = "") {
127
127
  return e("report.schedule.customDate");
128
128
  let r = `${e("report.schedule.everyYear")} `;
129
129
  if (a.months) {
130
- const n = de();
130
+ const n = ne();
131
131
  r = r + a.months.map((l) => n[l - 1]).join(",");
132
132
  }
133
133
  return a.months && a.days && (r = r + ` ${e("report.common.and")} `), a.days && (r = r + a.days.join(",")), r;
@@ -136,7 +136,7 @@ function be(a, e, t = "") {
136
136
  return t;
137
137
  }
138
138
  }
139
- function j(a = {
139
+ function _(a = {
140
140
  startDate: null,
141
141
  endDate: null,
142
142
  locale: "en-US",
@@ -147,7 +147,7 @@ function j(a = {
147
147
  let e = u().subtract(1, "day").endOf("day"), t = u().endOf("day");
148
148
  return a.startDate && (e = a.timezone ? u(a.startDate).tz(a.timezone).locale(a.locale) : u(a.startDate).locale(a.locale)), a.endDate && (t = a.timezone ? u(a.endDate).tz(a.timezone).locale(a.locale) : u(a.endDate).locale(a.locale)), e.format("YYYY") !== t.format("YYYY") ? `${e.format("DD MMM YYYY")} - ${t.format("DD MMM YYYY")}` : `${e.format("DD MMM")} - ${t.format("DD MMM YYYY")}`;
149
149
  }
150
- function Ye(a = {
150
+ function Ce(a = {
151
151
  startTime: null,
152
152
  endTime: null,
153
153
  locale: "en-US"
@@ -157,7 +157,7 @@ function Ye(a = {
157
157
  const l = u().set("hour", t.hour).set("minute", t.minute).locale(n), c = u().set("hour", r.hour).set("minute", r.minute).locale(n);
158
158
  return `${l.format(e)}-${c.format(e)}`;
159
159
  }
160
- const me = { class: "fm-typo-en-body-md-600 flex items-center gap-1 flex-1 min-w-0" }, oe = { class: "text-ellipsis overflow-hidden whitespace-nowrap flex-1 min-w-0" }, fe = { class: "whitespace-nowrap flex-none" }, N = /* @__PURE__ */ V({
160
+ const ce = { class: "fm-typo-en-body-md-600 flex items-center gap-1 flex-1 min-w-0" }, ue = { class: "text-ellipsis overflow-hidden whitespace-nowrap flex-1 min-w-0" }, se = { class: "whitespace-nowrap flex-none" }, z = /* @__PURE__ */ O({
161
161
  __name: "FilterChip",
162
162
  props: {
163
163
  label: {
@@ -187,7 +187,7 @@ const me = { class: "fm-typo-en-body-md-600 flex items-center gap-1 flex-1 min-w
187
187
  const n = C("FmIcon"), l = C("FmCircularProgress"), c = C("FmChip");
188
188
  return D(), h(c, {
189
189
  "aria-busy": e.loading,
190
- class: G([
190
+ class: B([
191
191
  "bg-fm-color-neutral-gray-100 text-fm-color-neutral-gray-400 max-w-[400px] flex items-center gap-1 transition-opacity",
192
192
  e.loading && "opacity-80"
193
193
  ])
@@ -200,8 +200,8 @@ const me = { class: "fm-typo-en-body-md-600 flex items-center gap-1 flex-1 min-w
200
200
  outline: "",
201
201
  class: "flex-none"
202
202
  }, null, 8, ["name"])) : x("", !0),
203
- w("div", me, [
204
- w("span", oe, H(e.label), 1),
203
+ w("div", ce, [
204
+ w("span", ue, W(e.label), 1),
205
205
  a.rightIcon ? (D(), h(n, {
206
206
  key: 0,
207
207
  name: a.rightIcon,
@@ -209,8 +209,8 @@ const me = { class: "fm-typo-en-body-md-600 flex items-center gap-1 flex-1 min-w
209
209
  outline: "",
210
210
  class: "flex-none"
211
211
  }, null, 8, ["name"])) : x("", !0),
212
- w("span", fe, [
213
- K(t.$slots, "default")
212
+ w("span", se, [
213
+ X(t.$slots, "default")
214
214
  ]),
215
215
  e.loading ? (D(), h(l, {
216
216
  key: 1,
@@ -229,16 +229,16 @@ const me = { class: "fm-typo-en-body-md-600 flex items-center gap-1 flex-1 min-w
229
229
  }, 8, ["aria-busy", "class"]);
230
230
  };
231
231
  }
232
- }), ie = { class: "flex gap-2 items-center" }, p = "YYYY-MM-DD", Te = /* @__PURE__ */ V({
232
+ }), de = { class: "flex gap-2 items-center" }, p = "YYYY-MM-DD", xe = /* @__PURE__ */ O({
233
233
  __name: "DateRangeSelect",
234
- props: /* @__PURE__ */ L({
234
+ props: /* @__PURE__ */ M({
235
235
  compare: {
236
236
  type: Boolean,
237
237
  default: !1
238
238
  },
239
239
  datePredefinedRanges: {
240
240
  type: Array,
241
- default: () => Z()
241
+ default: () => H()
242
242
  },
243
243
  label: {
244
244
  type: String,
@@ -253,7 +253,7 @@ const me = { class: "fm-typo-en-body-md-600 flex items-center gap-1 flex-1 min-w
253
253
  }, {
254
254
  compareType: {
255
255
  type: String,
256
- default: ee.PRECEDING_PERIOD
256
+ default: K.PRECEDING_PERIOD
257
257
  },
258
258
  compareTypeModifiers: {},
259
259
  dateRange: {
@@ -273,49 +273,48 @@ const me = { class: "fm-typo-en-body-md-600 flex items-center gap-1 flex-1 min-w
273
273
  },
274
274
  compareDateRangeModifiers: {}
275
275
  }),
276
- emits: /* @__PURE__ */ L(["update", "chip-closed"], ["update:compareType", "update:dateRange", "update:compareDateRange"]),
276
+ emits: /* @__PURE__ */ M(["update", "chip-closed"], ["update:compareType", "update:dateRange", "update:compareDateRange"]),
277
277
  setup(a, { emit: e }) {
278
- var M, P, $, A;
279
- const { t, locale: r } = ae(), n = e, l = E(a, "compareType"), c = E(a, "dateRange"), s = E(a, "compareDateRange"), { timezone: d } = te(Q()), m = z({
280
- startDate: c.value.startDate ? (M = u(c.value.startDate)) == null ? void 0 : M.tz(d.value).format(p) : null,
281
- endDate: c.value.endDate ? (P = u(c.value.endDate)) == null ? void 0 : P.tz(d.value).format(p) : null
282
- }), g = z({
283
- startDate: s.value.startDate ? ($ = u(s.value.startDate)) == null ? void 0 : $.tz(d.value).format(p) : null,
284
- endDate: s.value.endDate ? (A = u(s.value.endDate)) == null ? void 0 : A.tz(d.value).format(p) : null
278
+ const { t, locale: r } = J(), n = e, l = E(a, "compareType"), c = E(a, "dateRange"), s = E(a, "compareDateRange"), { timezone: o } = Q(G()), d = P({
279
+ startDate: c.value.startDate ? u(c.value.startDate).format(p) : null,
280
+ endDate: c.value.endDate ? u(c.value.endDate).format(p) : null
281
+ }), g = P({
282
+ startDate: s.value.startDate ? u(s.value.startDate).format(p) : null,
283
+ endDate: s.value.endDate ? u(s.value.endDate).format(p) : null
285
284
  });
286
- F(
287
- [() => m.value],
285
+ $(
286
+ [() => d.value],
288
287
  () => {
289
- m.value.endDate || (m.value.endDate = m.value.startDate);
288
+ d.value.endDate || (d.value.endDate = d.value.startDate);
290
289
  const f = {
291
- startDate: u.tz(m.value.startDate, d.value).startOf("day").utc().toISOString(),
292
- endDate: u.tz(m.value.endDate, d.value).endOf("day").utc().toISOString()
290
+ startDate: u.tz(d.value.startDate, o.value).startOf("day").utc().toISOString(),
291
+ endDate: u.tz(d.value.endDate, o.value).endOf("day").utc().toISOString()
293
292
  };
294
293
  c.value = f, n("update", f);
295
294
  },
296
295
  { deep: !0 }
297
- ), F([() => g.value], () => {
298
- const f = g.value.startDate, o = g.value.endDate, R = f ? u(
296
+ ), $([() => g.value], () => {
297
+ const f = g.value.startDate, m = g.value.endDate, R = f ? u(
299
298
  f instanceof Date ? f : u(f).toDate()
300
- ).startOf("day").tz(d.value, !0).toISOString() : void 0, i = o ? u(o instanceof Date ? o : u(o).toDate()).tz(d.value, !0).endOf("day").toISOString() : void 0;
299
+ ).startOf("day").tz(o.value, !0).toISOString() : void 0, i = m ? u(m instanceof Date ? m : u(m).toDate()).tz(o.value, !0).endOf("day").toISOString() : void 0;
301
300
  s.value = {
302
301
  startDate: R,
303
302
  endDate: i
304
303
  };
305
304
  });
306
- function X(f) {
305
+ function N(f) {
307
306
  l.value = f;
308
307
  }
309
- function q(f) {
308
+ function V(f) {
310
309
  n("chip-closed", f);
311
310
  }
312
- return (f, o) => {
311
+ return (f, m) => {
313
312
  const R = C("FmSimpleDateRangePicker");
314
- return D(), J("div", ie, [
313
+ return D(), q("div", de, [
315
314
  (D(), h(R, {
316
315
  key: `date-picker-${y(r)}`,
317
- modelValue: m.value,
318
- "onUpdate:modelValue": o[1] || (o[1] = (i) => m.value = i),
316
+ modelValue: d.value,
317
+ "onUpdate:modelValue": m[1] || (m[1] = (i) => d.value = i),
319
318
  "show-predefined-range": "",
320
319
  "predefined-range": a.datePredefinedRanges.map((i) => ({
321
320
  ...i,
@@ -324,15 +323,15 @@ const me = { class: "fm-typo-en-body-md-600 flex items-center gap-1 flex-1 min-w
324
323
  class: "w-2/6"
325
324
  }, {
326
325
  "trigger-button": I(() => [
327
- k(N, {
326
+ A(z, {
328
327
  "left-icon": a.label ? "filter_alt" : "calendar_month",
329
- label: a.label ?? y(j)({
330
- startDate: m.value.startDate ?? "",
331
- endDate: m.value.endDate ?? "",
332
- locale: y(_)()
328
+ label: a.label ?? y(_)({
329
+ startDate: d.value.startDate ?? "",
330
+ endDate: d.value.endDate ?? "",
331
+ locale: y(L)()
333
332
  }),
334
333
  removable: a.removable,
335
- onChipClosed: o[0] || (o[0] = (i) => q(!0))
334
+ onChipClosed: m[0] || (m[0] = (i) => V(!0))
336
335
  }, null, 8, ["left-icon", "label", "removable"])
337
336
  ]),
338
337
  _: 1
@@ -340,20 +339,20 @@ const me = { class: "fm-typo-en-body-md-600 flex items-center gap-1 flex-1 min-w
340
339
  a.compare ? (D(), h(R, {
341
340
  key: `compare-date-picker-${y(r)}`,
342
341
  modelValue: g.value,
343
- "onUpdate:modelValue": o[2] || (o[2] = (i) => g.value = i),
342
+ "onUpdate:modelValue": m[2] || (m[2] = (i) => g.value = i),
344
343
  "compare-type": l.value,
345
- "onUpdate:compareType": o[3] || (o[3] = (i) => l.value = i),
344
+ "onUpdate:compareType": m[3] || (m[3] = (i) => l.value = i),
346
345
  "show-predefined-range": "",
347
- "compare-target": m.value,
346
+ "compare-target": d.value,
348
347
  "default-compare-type": l.value,
349
- onSelectComparison: X
348
+ onSelectComparison: N
350
349
  }, {
351
350
  "trigger-button": I(() => [
352
- k(N, {
353
- label: `${y(t)("report.common.compare")}: ${y(j)({
351
+ A(z, {
352
+ label: `${y(t)("report.common.compare")}: ${y(_)({
354
353
  startDate: g.value.startDate ?? null,
355
354
  endDate: g.value.endDate ?? null,
356
- locale: y(_)()
355
+ locale: y(L)()
357
356
  })}`
358
357
  }, null, 8, ["label"])
359
358
  ]),
@@ -365,16 +364,16 @@ const me = { class: "fm-typo-en-body-md-600 flex items-center gap-1 flex-1 min-w
365
364
  });
366
365
  export {
367
366
  v as C,
368
- Te as _,
369
- Re as a,
370
- se as b,
371
- Ce as c,
372
- Se as d,
373
- be as e,
374
- N as f,
375
- de as g,
376
- Ye as h,
377
- j as i,
378
- pe as p,
379
- xe as s
367
+ xe as _,
368
+ De as a,
369
+ le as b,
370
+ he as c,
371
+ Re as d,
372
+ pe as e,
373
+ z as f,
374
+ ne as g,
375
+ Ce as h,
376
+ _ as i,
377
+ ge as p,
378
+ ve as s
380
379
  };
@@ -1,5 +1,5 @@
1
1
  import { defineComponent as u, computed as p, resolveComponent as f, createElementBlock as s, openBlock as t, normalizeStyle as n, normalizeClass as d, unref as e, createBlock as y, createCommentVNode as _, createVNode as h, createElementVNode as k, toDisplayString as g, renderSlot as x } from "vue";
2
- import { _ as v } from "./NavigationTab.vue_vue_type_script_setup_true_lang-BZdj0yom.js";
2
+ import { _ as v } from "./NavigationTab.vue_vue_type_script_setup_true_lang-DF_ew8-o.js";
3
3
  import { useBreakpoints as b } from "@feedmepos/ui-library";
4
4
  import { storeToRefs as C } from "pinia";
5
5
  import { u as q, a as w } from "./vue-i18n-DVWuTfed.js";