@feedmepos/mf-connect 0.0.16-beta.6 → 0.0.16-beta.7

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 (31) hide show
  1. package/dist/{Analytic-BVuGbTwv.js → Analytic-DYrMRM6L.js} +2 -2
  2. package/dist/App-CpRsAaL3.js +171 -0
  3. package/dist/{CampaignTypeDialog.vue_vue_type_script_setup_true_lang-Bxpa-_mm.js → CampaignTypeDialog.vue_vue_type_script_setup_true_lang-9uWy_niq.js} +1 -1
  4. package/dist/{Card-CQ01Sbmr.js → Card-DVDsR-Mf.js} +69 -69
  5. package/dist/Collections-FJVEY-VS.js +4 -0
  6. package/dist/{Credit-DKpU-Fqh.js → Credit-B1PKsr0v.js} +17 -17
  7. package/dist/{Experience-0HYPKxNA.js → Experience-CX0YudA8.js} +10 -10
  8. package/dist/{Game-OZt6lQvh.js → Game-C-oHoUG2.js} +23 -23
  9. package/dist/MainLayout-DWCxz8zb.js +4 -0
  10. package/dist/{Marketing-ClFlJj2D.js → Marketing-D67z1v-_.js} +29 -29
  11. package/dist/{Member-DbEQtYdP.js → Member-BmZeyiYW.js} +1 -1
  12. package/dist/{MemberList-Be6Wa9FX.js → MemberList-DyBSrFOX.js} +142 -142
  13. package/dist/{MemberTransactions-D9N_q5uD.js → MemberTransactions-D-kYUOiA.js} +1 -1
  14. package/dist/{Mission-Bb7Gxhaj.js → Mission-D0ZNC1D2.js} +14 -14
  15. package/dist/{Point-DIriPN8u.js → Point-Ckp4mFDE.js} +35 -35
  16. package/dist/{Segment-CVwjT9aw.js → Segment-CPZpv9jT.js} +22 -22
  17. package/dist/{Setting-BfG3uUSL.js → Setting-CRZ6Iaq3.js} +1 -1
  18. package/dist/{Store-h7b04ajj.js → Store-BmDKzaZQ.js} +136 -136
  19. package/dist/{StoreRewards-C3x6MUkN.js → StoreRewards-Ba8CNwe9.js} +33 -33
  20. package/dist/{StoreTransactions.vue_vue_type_script_setup_true_lang-DPoTHNZc.js → StoreTransactions.vue_vue_type_script_setup_true_lang-CVcp8UZe.js} +17 -17
  21. package/dist/{Tier-cBKbacUy.js → Tier-6WE69YM9.js} +2 -2
  22. package/dist/{Title-BHpfJlxy.js → Title-BS9kRmv1.js} +2 -2
  23. package/dist/{Transaction-BdZUSSVK.js → Transaction-B_ntYO80.js} +2 -2
  24. package/dist/{app-BQZLUAQT.js → app-DVhYnwY5.js} +710 -872
  25. package/dist/app.js +1 -1
  26. package/dist/{export-BaUeQ3Pf.js → export-D3PUmaEM.js} +6 -6
  27. package/dist/{money-D4rDwYP5.js → money-C4TDRKZw.js} +1 -1
  28. package/dist/{number-DPytq9Vv.js → number-DN4byW-c.js} +1 -1
  29. package/package.json +1 -1
  30. package/dist/Collections-BtIEMfxI.js +0 -4
  31. package/dist/MainLayout-DO1g-EN4.js +0 -4
@@ -1,6 +1,6 @@
1
1
  import { defineComponent as D, openBlock as r, createElementBlock as R, Fragment as w, renderList as C, createElementVNode as e, toDisplayString as z, createCommentVNode as k, resolveComponent as X, createBlock as j, withCtx as g, createVNode as l, unref as o, ref as v, computed as O, onMounted as Z, watch as eo, isRef as Q, createSlots as io, createTextVNode as to, reactive as ao, onBeforeMount as ro, normalizeClass as G } from "vue";
2
- import { C as no, c as N, J as Ko, u as Ao, F as Uo, g as lo, a as so, Z as Fo, b as co, d as po, e as Ro, f as uo, h as mo, i as fo, j as Vo, m as qo } from "./app-BQZLUAQT.js";
3
- import { f as vo } from "./number-DPytq9Vv.js";
2
+ import { C as no, c as N, J as Ko, a as Ao, F as Uo, g as lo, d as so, Z as Fo, e as co, f as po, u as Ro, h as uo, i as mo, j as fo, k as Vo, m as qo } from "./app-DVhYnwY5.js";
3
+ import { f as vo } from "./number-DN4byW-c.js";
4
4
  import { useRouter as $ } from "vue-router";
5
5
  import { useSnackbar as Po } from "@feedmepos/ui-library";
6
6
  const Xo = { class: "divide-x flex flex-wrap" }, yo = { class: "fm-typo-en-body-md-400 mb-2 text-fm-color-typo-secondary" }, So = { class: "fm-typo-en-title-sm-800" }, ho = /* @__PURE__ */ D({
@@ -0,0 +1,171 @@
1
+ import { defineComponent as M, ref as p, h as d, watch as N, resolveComponent as S, openBlock as g, createBlock as O, unref as l, computed as C, onMounted as B, createElementBlock as P, Fragment as G, createCommentVNode as $, createVNode as L, createElementVNode as w, nextTick as F } from "vue";
2
+ import { useRouter as V, useRoute as k, RouterView as Y } from "vue-router";
3
+ import { useCoreStore as E } from "@feedmepos/mf-common";
4
+ import { u as U, R as n, a as H, b as x, S as y, J as D } from "./app-DVhYnwY5.js";
5
+ import { components as v, useSnackbar as X, useDialog as q } from "@feedmepos/ui-library";
6
+ const j = /* @__PURE__ */ M({
7
+ __name: "NavigationTab",
8
+ setup(I) {
9
+ const { t: e } = U(), m = p(), i = [
10
+ {
11
+ label: e("connect.navigation.analytic"),
12
+ value: n["$connect-ANALYTIC"]
13
+ },
14
+ {
15
+ label: e("connect.navigation.campaign"),
16
+ value: n["$connect-CAMPAIGN"],
17
+ children: [
18
+ {
19
+ label: e("connect.navigation.promotion"),
20
+ value: n["$connect-CAMPAIGN_PROMOTION"]
21
+ },
22
+ {
23
+ label: e("connect.navigation.voucher"),
24
+ value: n["$connect-CAMPAIGN_VOUCHER"]
25
+ },
26
+ {
27
+ label: e("connect.navigation.broadcast"),
28
+ value: n["$connect-CAMPAIGN_BROADCAST"]
29
+ }
30
+ ]
31
+ },
32
+ {
33
+ label: e("connect.navigation.program"),
34
+ value: n["$connect-PROGRAM"],
35
+ children: [
36
+ {
37
+ label: e("connect.navigation.tier"),
38
+ value: n["$connect-PROGRAM_TIER"]
39
+ },
40
+ {
41
+ label: e("connect.navigation.title"),
42
+ value: n["$connect-PROGRAM_TITLE"]
43
+ },
44
+ {
45
+ label: e("connect.navigation.experience"),
46
+ value: n["$connect-PROGRAM_EXPERIENCE"]
47
+ },
48
+ {
49
+ label: e("connect.navigation.point"),
50
+ value: n["$connect-PROGRAM_POINT"],
51
+ badge: () => d(v.FmPill, { variant: "premium" })
52
+ },
53
+ {
54
+ label: e("connect.navigation.credit"),
55
+ value: n["$connect-PROGRAM_CREDIT"]
56
+ },
57
+ {
58
+ label: e("connect.navigation.game"),
59
+ value: n["$connect-PROGRAM_GAME"],
60
+ badge: () => d(v.FmPill, { variant: "premium" })
61
+ },
62
+ {
63
+ label: "Mission",
64
+ value: n["$connect-PROGRAM_MISSION"]
65
+ }
66
+ ]
67
+ },
68
+ {
69
+ label: e("connect.navigation.loyalty"),
70
+ value: n["$connect-LOYALTY"],
71
+ children: [
72
+ {
73
+ label: e("connect.navigation.member"),
74
+ value: n["$connect-LOYALTY_MEMBER_LIST"]
75
+ },
76
+ {
77
+ label: e("connect.navigation.segments"),
78
+ value: n["$connect-LOYALTY_SEGMENT"],
79
+ badge: () => d(v.FmPill, { variant: "premium" })
80
+ },
81
+ {
82
+ label: e("connect.navigation.card"),
83
+ value: n["$connect-LOYALTY_CARD"],
84
+ badge: () => d(v.FmPill, { variant: "premium" })
85
+ }
86
+ ]
87
+ },
88
+ {
89
+ label: e("connect.navigation.store"),
90
+ value: n["$connect-STORE"]
91
+ },
92
+ {
93
+ label: e("connect.navigation.transaction"),
94
+ value: n["$connect-TRANSACTION"]
95
+ },
96
+ // {
97
+ // label: 'Marketing material',
98
+ // value: ROUTE_NAME['$connect-MARKETING'],
99
+ // },
100
+ {
101
+ label: e("connect.navigation.setting"),
102
+ value: n["$connect-SETTING"]
103
+ }
104
+ ], b = V(), _ = k(), f = i.reduce((t, o) => [...(o.children ?? []).map((a) => a.value), ...t, o.value], []);
105
+ N(
106
+ () => _,
107
+ (t) => {
108
+ const o = t.matched.map((a) => a.name).reverse();
109
+ m.value = o.find((a) => f.includes(a));
110
+ },
111
+ { immediate: !0 }
112
+ );
113
+ async function R(t) {
114
+ await b.push({ name: t });
115
+ }
116
+ return (t, o) => {
117
+ var r;
118
+ const a = S("FmCollapsibleTabs");
119
+ return g(), O(a, {
120
+ class: "border-fm-color-neutral-gray-100 border-r py-16 px-4",
121
+ "model-value": (r = l(m)) == null ? void 0 : r.toString(),
122
+ items: i,
123
+ "onUpdate:modelValue": R
124
+ }, null, 8, ["model-value"]);
125
+ };
126
+ }
127
+ });
128
+ var J = { authUrl: "https://portal-v2-dev.feedmeapi.com/", slackWebhookUrl: "https://hooks.slack.com/services/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", appUrl: "member.feedmedev.cc", crmUrl: "crm.feedmedev.cc", paymentPortalUrl: "https://portal.feedmedev.cc/payment/payout-account", marketingV1Portal: "https://marketing-v1.feedmedev.cc" };
129
+ const z = {
130
+ key: 1,
131
+ class: "h-full w-full"
132
+ }, K = ["src"], ae = /* @__PURE__ */ M({
133
+ __name: "App",
134
+ setup(I) {
135
+ const e = E(), m = H(), i = x(), b = X(), _ = q(), f = k(), R = p(f.query.showHeader !== "false"), t = p(!1), { currentBusiness: o } = E(), a = p(!1), r = C(() => i.version), h = C(() => {
136
+ const c = e.currentCountry.value || "MY", s = y.getIdToken(), u = o.value._id;
137
+ return `${J.marketingV1Portal}/b/${u}/marketing/overview?showHeader=false&country=${c}&token=${s}`;
138
+ }), A = async () => {
139
+ a.value = !1, await F(), console.log("forceRerender"), y.setBusinessId(o.value._id), await i.readPremium(), !t.value && r.value === "v2" ? e.registerSidebarComponent(j) : e.hideSidebarToggle(!0), t.value = !0, a.value = !0;
140
+ };
141
+ return B(() => {
142
+ if (m.initProvider(b, _), !R.value) {
143
+ const c = document.getElementsByClassName("app-header")[0], s = document.getElementsByClassName("app-sidebar")[0], u = document.getElementsByClassName("app-container")[0], T = document.getElementsByTagName("main")[0];
144
+ c == null || c.classList.add("!hidden"), s == null || s.classList.add("!pt-0"), u == null || u.classList.add("!pt-0"), T == null || T.classList.add("!pt-0"), e.hideSidebarToggle(!0);
145
+ }
146
+ o.value != null && A();
147
+ }), N(
148
+ () => e.currentBusiness.value,
149
+ async (c) => {
150
+ c != null && A();
151
+ }
152
+ ), (c, s) => (g(), P(G, null, [
153
+ l(a) && l(r) === "v2" ? (g(), O(l(Y), { key: 0 })) : $("", !0),
154
+ l(a) && l(r) !== "v2" ? (g(), P("div", z, [
155
+ L(D, {
156
+ json: { url: l(h) }
157
+ }, null, 8, ["json"]),
158
+ w("iframe", {
159
+ allow: "clipboard-read; clipboard-write",
160
+ frameBorder: "0",
161
+ height: "100%",
162
+ width: "100%",
163
+ src: l(h)
164
+ }, null, 8, K)
165
+ ])) : $("", !0)
166
+ ], 64));
167
+ }
168
+ });
169
+ export {
170
+ ae as default
171
+ };
@@ -1,4 +1,4 @@
1
- import { I as RuleOperator, y as isRuleGroup, K as _, D as F_RUNNABLE_CAMPAIGN_TYPE } from "./app-BQZLUAQT.js";
1
+ import { L as RuleOperator, A as isRuleGroup, M as _, G as F_RUNNABLE_CAMPAIGN_TYPE } from "./app-DVhYnwY5.js";
2
2
  import { defineComponent, resolveComponent, openBlock, createBlock, withCtx, createElementVNode, createElementBlock, Fragment, renderList, createVNode, toDisplayString } from "vue";
3
3
  import { useDialog } from "@feedmepos/ui-library";
4
4
  function validateRule(data, r, date) {