@feedmepos/mf-connect 0.1.92-prod → 0.1.93-prod

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 (100) hide show
  1. package/dist/{Analytic-CpBxKgs9.js → Analytic-CF3P53vZ.js} +11 -11
  2. package/dist/{App-B7AQKHNG.js → App-Dbibh5dj.js} +11 -11
  3. package/dist/{Bin-fMP89RQu.js → Bin-B2fl-fdo.js} +8 -8
  4. package/dist/{Broadcast-CzakSN6g.js → Broadcast-Bdd60JEW.js} +8 -8
  5. package/dist/{CampaignTypeDialog.vue_vue_type_script_setup_true_lang-mpvpNP4k.js → CampaignTypeDialog.vue_vue_type_script_setup_true_lang-BkXOSFhp.js} +6 -7
  6. package/dist/{Card-CBl-FP75.js → Card-BsfpC3iw.js} +20 -21
  7. package/dist/{Collections-CSE9blWI.js → Collections-b35P-S0E.js} +8 -8
  8. package/dist/{Credit-Ys2hpuhy.js → Credit-D52WVEI2.js} +8 -8
  9. package/dist/{EditCampaignSheet.vue_vue_type_script_setup_true_lang-8xKxU19h.js → EditCampaignSheet.vue_vue_type_script_setup_true_lang-CCUOC17_.js} +32 -33
  10. package/dist/{EffectSheet.vue_vue_type_style_index_0_lang-CCmIV0PO.js → EffectSheet.vue_vue_type_style_index_0_lang-Bt7uoapk.js} +6 -6
  11. package/dist/{Experience-ldXxT64B.js → Experience-_zsgF0a8.js} +8 -8
  12. package/dist/{FileSaver.min-ChbDZYru.js → FileSaver.min-B7bT7uZB.js} +1 -1
  13. package/dist/{Game-CzNAKcbn.js → Game-RJSHKHn3.js} +9 -9
  14. package/dist/{ImageInput.vue_vue_type_script_setup_true_lang-BWSlxKAt.js → ImageInput.vue_vue_type_script_setup_true_lang-SEhYAL8G.js} +1 -1
  15. package/dist/{Index-BTg5_VLv.js → Index-D3ezuXa9.js} +10 -10
  16. package/dist/{LottieAnimation.vue_vue_type_script_setup_true_lang-CEX4A8Vu.js → LottieAnimation.vue_vue_type_script_setup_true_lang-BrE_KuQ8.js} +1 -1
  17. package/dist/{MainLayout-DTnxYJL-.js → MainLayout-CVV2DhUe.js} +1 -1
  18. package/dist/Marketing-DEuThlZJ.js +235 -0
  19. package/dist/MarketingMaterialEdit-CUTvpMNA.js +1032 -0
  20. package/dist/{Member-BFfuRNc3.js → Member-VETbkHa9.js} +13 -14
  21. package/dist/{MemberList-BIOv6v6t.js → MemberList-Zf4a_QPT.js} +33 -33
  22. package/dist/{MemberTransactions-BeFVDHAh.js → MemberTransactions-CKkhiXHs.js} +1 -1
  23. package/dist/{MessageInput.vue_vue_type_script_setup_true_lang-BtiTqHlT.js → MessageInput.vue_vue_type_script_setup_true_lang-CWFhJcf_.js} +9 -9
  24. package/dist/{Mission-D7-WUd8e.js → Mission-ebr00gRa.js} +30 -30
  25. package/dist/{Overview-wPnRJWSF.js → Overview-DAVsiqOi.js} +30 -30
  26. package/dist/{Point-B6K7s305.js → Point-MVRhs_TV.js} +8 -8
  27. package/dist/{Promotion-V9HF_-4a.js → Promotion-gY4_IDdN.js} +20 -19
  28. package/dist/{Queue-GxWELL-8.js → Queue-DYG5qt5V.js} +19 -19
  29. package/dist/{Record-D6xoFcc_.js → Record-DJQbIHO-.js} +14 -13
  30. package/dist/{Reward-ChrJx3TQ.js → Reward-Cl9Q83Ic.js} +16 -16
  31. package/dist/{RewardGroup.vue_vue_type_script_setup_true_lang-BzxTwBV9.js → RewardGroup.vue_vue_type_script_setup_true_lang-B9oA4sF8.js} +13 -14
  32. package/dist/{RuleGroup.vue_vue_type_script_setup_true_lang-aDa4GkmZ.js → RuleGroup.vue_vue_type_script_setup_true_lang-4xWx1fZP.js} +16 -17
  33. package/dist/{Segment-rI73g2Pf.js → Segment-DmgI9KPo.js} +26 -27
  34. package/dist/{SelectItems.vue_vue_type_script_setup_true_lang-DqhqodSA.js → SelectItems.vue_vue_type_script_setup_true_lang-DySwa7Ny.js} +2 -2
  35. package/dist/{SendCollectionSheet.vue_vue_type_script_setup_true_lang-DmG2wWp8.js → SendCollectionSheet.vue_vue_type_script_setup_true_lang-DD-KfnJK.js} +30 -31
  36. package/dist/{SendVoucherSheet.vue_vue_type_script_setup_true_lang-nqcXkNuh.js → SendVoucherSheet.vue_vue_type_script_setup_true_lang-D8hgPIT2.js} +4 -4
  37. package/dist/{Setting-BTBy21Dh.js → Setting-Czy9M6ce.js} +14 -14
  38. package/dist/{SettingAdvertisements-DpQSHRt5.js → SettingAdvertisements-BMnfsHLy.js} +12 -12
  39. package/dist/{Store-CDeDk5j3.js → Store-C-ys_2QK.js} +23 -24
  40. package/dist/{StoreRewards-B_sIvED1.js → StoreRewards-DK7IUkUO.js} +15 -15
  41. package/dist/{StoreTransactions.vue_vue_type_script_setup_true_lang-C_jYgOxV.js → StoreTransactions.vue_vue_type_script_setup_true_lang-kaIV3mqE.js} +29 -29
  42. package/dist/{TargetLocationInput.vue_vue_type_script_setup_true_lang-CZgImaiL.js → TargetLocationInput.vue_vue_type_script_setup_true_lang-DnRJPsED.js} +2 -2
  43. package/dist/{Tier-BqPORpVi.js → Tier-B7bsxmsf.js} +22 -22
  44. package/dist/{Title-DZFyfOvY.js → Title-D4KW30Ks.js} +22 -23
  45. package/dist/{Transaction-BicSfNsV.js → Transaction-CKyWN0zZ.js} +2 -2
  46. package/dist/{UserRuleGroup.vue_vue_type_script_setup_true_lang-Bj7F_2lN.js → UserRuleGroup.vue_vue_type_script_setup_true_lang-tqshXO3D.js} +6 -6
  47. package/dist/{Voucher-D5xZbzfU.js → Voucher-DLw9lMUt.js} +12 -12
  48. package/dist/{VoucherEditor.vue_vue_type_script_setup_true_lang-DQlzbuAg.js → VoucherEditor.vue_vue_type_script_setup_true_lang-D5QC7oDC.js} +12 -12
  49. package/dist/{ZodTextField.vue_vue_type_script_setup_true_lang-DAsm-iDs.js → ZodTextField.vue_vue_type_script_setup_true_lang-DpfeD9sJ.js} +2 -2
  50. package/dist/{app-D427_gmU.js → app-AQ3uPcGw.js} +9480 -9256
  51. package/dist/app.js +1 -1
  52. package/dist/{business-DVT9-z7e.js → business-C-SeKOpM.js} +1 -1
  53. package/dist/{campaign-BxeCSYow.js → campaign-Dk0dzJrv.js} +21 -20
  54. package/dist/{campaign-Cd2S6J2Z.js → campaign-Jnfn3VT0.js} +1 -1
  55. package/dist/{campaign.enum-BWx2XJCj.js → campaign.enum-jrT7BDfx.js} +1 -1
  56. package/dist/{campaign.fn-C6_ucHrl.js → campaign.fn-v9Ckc2hW.js} +39 -39
  57. package/dist/{collectible.enum-CMr5OBDH.js → collectible.enum-DFWdMC2z.js} +1 -1
  58. package/dist/{collection.fn-QKLnoDfT.js → collection.fn-BDtuxdF8.js} +2 -2
  59. package/dist/{dto-DGMbacfr.js → dto-zWYoDEwd.js} +16 -16
  60. package/dist/{effect-BGkSRKmY.js → effect-DOecbCOM.js} +1 -1
  61. package/dist/{email-addresses-BAv5RfxW.js → email-addresses-DSr_tXqu.js} +2 -2
  62. package/dist/{export-1X3xd2lm.js → export-CZkFZ1ql.js} +3 -3
  63. package/dist/{helper-CjJd9YN0.js → helper-Qh6msr0l.js} +1 -1
  64. package/dist/{index-DVEBKqPp.js → index--gM0b_9n.js} +1 -1
  65. package/dist/{index-yOug8IQK.js → index-9VFfiC3i.js} +1 -1
  66. package/dist/{index-C-5iRXaD.js → index-B1rzQD1z.js} +3 -3
  67. package/dist/{index-CeC11VY5.js → index-BlK42Hsj.js} +17 -17
  68. package/dist/{index-ueyNfpGe.js → index-BnY_w7sd.js} +3 -3
  69. package/dist/{index-CI3LvsAN.js → index-BoC2dMV5.js} +2 -2
  70. package/dist/{index-DkEmFIqa.js → index-CRiRSGK0.js} +1 -1
  71. package/dist/{index-8FtsTHd_.js → index-D0n4WOl2.js} +3 -3
  72. package/dist/{index-yF2I6Xtv.js → index-DFw3Bb9V.js} +91 -68
  73. package/dist/{index-CTTeS30R.js → index-DObqZ6KJ.js} +1 -1
  74. package/dist/{index-DxbpoYQX.js → index-YUpYN8aL.js} +1 -1
  75. package/dist/{index-CqoU5D_S.js → index-tv01Kl2W.js} +18 -18
  76. package/dist/{index.esm2017-DBFENth9.js → index.esm2017-B-Gv-i1i.js} +1 -1
  77. package/dist/{loading-X5Dle07s.js → loading-CCrn-MJR.js} +4 -3
  78. package/dist/{lodash-CJtUEnSL.js → lodash-CtOTzbaj.js} +1 -1
  79. package/dist/{membership-CKuQtReq.js → membership-EQqU26uC.js} +3 -3
  80. package/dist/{money-C99PNkQ0.js → money-BKkxOcfp.js} +1 -1
  81. package/dist/{number-C42NY90L.js → number-CB4PaVTY.js} +1 -1
  82. package/dist/{objectid-B5SRENL3.js → objectid-DZkH2UHF.js} +6 -6
  83. package/dist/{plugins-0yAaVVcL.js → plugins-DY6km6IL.js} +297 -326
  84. package/dist/{reward-eIVX1EnX.js → reward-CtjrIJKv.js} +1 -1
  85. package/dist/{rule-BsTx8uRy.js → rule-CZ3RGeiy.js} +3 -3
  86. package/dist/{rule-builder-DxJBecU0.js → rule-builder-UZUhhSdz.js} +1 -1
  87. package/dist/string-Gcy5IM_H.js +32 -0
  88. package/dist/style.css +1 -1
  89. package/dist/{template-vPfeVxs-.js → template-D5j-p60O.js} +7 -7
  90. package/dist/{timezone-CzWr1nhO.js → timezone-D6XtPLkX.js} +2 -2
  91. package/dist/{trigger-BSEdMaKu.js → trigger-D899b9LT.js} +7 -7
  92. package/dist/useMarketingMaterialActions-CacZ3qjm.js +107 -0
  93. package/dist/{usePagination-BnISBBlq.js → usePagination-bOOb_012.js} +1 -1
  94. package/dist/{user-CUOEkvb1.js → user-CH5kl3DX.js} +19 -19
  95. package/dist/{vue-i18n-CdwtjeYd.js → vue-i18n-zOam3pfw.js} +201 -201
  96. package/dist/{xlsx-DOd1PS56.js → xlsx-DF35RkrA.js} +1 -1
  97. package/dist/{zod-_h5DNk2u.js → zod-CmBShukP.js} +1 -1
  98. package/package.json +3 -2
  99. package/dist/Marketing-CaFEmsay.js +0 -319
  100. package/dist/index-BtOj2rTq.js +0 -38
@@ -1,13 +1,13 @@
1
- import { p as B, i as w } from "./plugins-0yAaVVcL.js";
2
- import { _ as O } from "./lodash-CJtUEnSL.js";
1
+ import { p as B, i as w } from "./plugins-DY6km6IL.js";
2
+ import { _ as O } from "./lodash-CtOTzbaj.js";
3
3
  import { defineComponent as I, openBlock as d, createBlock as b, resolveDynamicComponent as $, unref as o, ref as z, computed as M, onMounted as Y, resolveComponent as f, withCtx as _, createElementVNode as s, createElementBlock as D, createVNode as r, normalizeClass as T, createTextVNode as F, toDisplayString as g, Fragment as R, renderList as L, createCommentVNode as j } from "vue";
4
- import { u as W } from "./campaign-Cd2S6J2Z.js";
4
+ import { u as W } from "./campaign-Jnfn3VT0.js";
5
5
  import { useDialog as q } from "@feedmepos/ui-library";
6
- import { F as G } from "./index-yF2I6Xtv.js";
7
- import { C as H } from "./campaign-BxeCSYow.js";
6
+ import { F as G } from "./index-DFw3Bb9V.js";
7
+ import { C as H } from "./campaign-Dk0dzJrv.js";
8
8
  import { J } from "./JsonViewer-v8_C7l5N.js";
9
- import { u as U } from "./vue-i18n-CdwtjeYd.js";
10
- import { u as K } from "./EditCampaignSheet.vue_vue_type_script_setup_true_lang-8xKxU19h.js";
9
+ import { u as U } from "./vue-i18n-zOam3pfw.js";
10
+ import { u as K } from "./EditCampaignSheet.vue_vue_type_script_setup_true_lang-CCUOC17_.js";
11
11
  function Se(e) {
12
12
  return B.confirm(
13
13
  w.global.t("connect.common.duplicate.confirmMessage", { name: e }),
@@ -1,6 +1,6 @@
1
- import { a as q0, c as o0, g as W0 } from "./app-D427_gmU.js";
1
+ import { a as q0, c as o0, g as W0 } from "./app-AQ3uPcGw.js";
2
2
  import { m as d0 } from "./moment-D7p2TMB-.js";
3
- import { e as n } from "./index-CI3LvsAN.js";
3
+ import { e as n } from "./index-BoC2dMV5.js";
4
4
  var _ = { exports: {} }, j = { exports: {} };
5
5
  const R0 = /* @__PURE__ */ q0(d0);
6
6
  (function(S) {
@@ -1,9 +1,9 @@
1
1
  import { defineComponent as c, openBlock as u, createBlock as p, unref as r } from "vue";
2
- import "./index-CeC11VY5.js";
3
- import { R as i } from "./rule-builder-DxJBecU0.js";
4
- import { _ as E } from "./RuleGroup.vue_vue_type_script_setup_true_lang-aDa4GkmZ.js";
5
- import { m as e, C as d } from "./index-CqoU5D_S.js";
6
- import { i as n } from "./plugins-0yAaVVcL.js";
2
+ import "./index-BlK42Hsj.js";
3
+ import { R as i } from "./rule-builder-UZUhhSdz.js";
4
+ import { _ as E } from "./RuleGroup.vue_vue_type_script_setup_true_lang-4xWx1fZP.js";
5
+ import { m as e, I as d } from "./index-tv01Kl2W.js";
6
+ import { i as n } from "./plugins-DY6km6IL.js";
7
7
  const L = /* @__PURE__ */ c({
8
8
  __name: "BillRuleGroup",
9
9
  props: {
@@ -185,7 +185,7 @@ const L = /* @__PURE__ */ c({
185
185
  value: e.enum.ISSUE_REWARD,
186
186
  hidden: !0
187
187
  }
188
- }, C = Object.fromEntries(
188
+ }, b = Object.fromEntries(
189
189
  [
190
190
  "VOUCHER",
191
191
  "PROMOTION",
@@ -206,7 +206,7 @@ const L = /* @__PURE__ */ c({
206
206
  })
207
207
  );
208
208
  export {
209
- C as T,
209
+ b as T,
210
210
  L as _,
211
211
  _ as a,
212
212
  O as b
@@ -0,0 +1,107 @@
1
+ import { S as o, g as c, b as w } from "./index-BoC2dMV5.js";
2
+ import { useAppStore as h, initializeRemyChat as y } from "@feedmepos/mf-remy-panel";
3
+ import { onMounted as k } from "vue";
4
+ import { u as I } from "./vue-i18n-zOam3pfw.js";
5
+ import { useSnackbar as M } from "@feedmepos/ui-library";
6
+ import { c as v } from "./plugins-DY6km6IL.js";
7
+ const l = (e) => w(`businesses/${e}/marketing-materials`), j = {
8
+ async createMarketingMaterial(e) {
9
+ const t = o.getBusinessId();
10
+ if (!t) throw new Error("Invalid business ID");
11
+ return c(
12
+ await l(t).post("", e)
13
+ );
14
+ },
15
+ async getMarketingMaterial(e) {
16
+ const t = o.getBusinessId();
17
+ if (!t) throw new Error("Invalid business ID");
18
+ return c(
19
+ await l(t).get(`/${e}`)
20
+ );
21
+ },
22
+ async listMarketingMaterials(e = null, t = 20) {
23
+ const r = o.getBusinessId();
24
+ if (!r) throw new Error("Invalid business ID");
25
+ return c(
26
+ await l(r).get("", {
27
+ params: { ...e ? { cursor: e } : {}, limit: t }
28
+ })
29
+ );
30
+ },
31
+ async updateMarketingMaterial(e, t) {
32
+ const r = o.getBusinessId();
33
+ if (!r) throw new Error("Invalid business ID");
34
+ return c(
35
+ await l(r).patch(`/${e}`, t)
36
+ );
37
+ }
38
+ };
39
+ let g = null;
40
+ function B() {
41
+ const e = h();
42
+ async function t() {
43
+ g || (g = y()), await g;
44
+ }
45
+ return k(t), Object.assign(e);
46
+ }
47
+ function F() {
48
+ const { t: e } = I(), t = M();
49
+ async function r(n) {
50
+ if (!(n != null && n.imageUrl)) return;
51
+ const { headline: i, caption: u, imageUrl: s } = n;
52
+ if (!navigator.share) {
53
+ t.open({
54
+ message: e("connect.marketing.actions.webShareNotSupported"),
55
+ type: "error"
56
+ });
57
+ return;
58
+ }
59
+ try {
60
+ const a = {
61
+ title: i ?? void 0,
62
+ text: u ?? void 0
63
+ };
64
+ if (navigator.canShare)
65
+ try {
66
+ const f = await (await fetch(s, { mode: "cors", cache: "no-store" })).blob(), p = [new File([f], "marketing-material.jpg", {
67
+ type: f.type || "image/jpeg"
68
+ })];
69
+ navigator.canShare({ files: p }) ? a.files = p : a.url = s;
70
+ } catch (m) {
71
+ console.error("Failed to fetch image for sharing:", m), a.url = s;
72
+ }
73
+ else
74
+ a.url = s;
75
+ await navigator.share(a);
76
+ } catch (a) {
77
+ a.name !== "AbortError" && t.open({
78
+ message: e("connect.marketing.actions.failedToShare", { message: a.message }),
79
+ type: "error"
80
+ });
81
+ }
82
+ }
83
+ async function d(n) {
84
+ if (n)
85
+ try {
86
+ const u = await (await fetch(n, { mode: "cors", cache: "no-store" })).blob(), s = URL.createObjectURL(u), a = document.createElement("a");
87
+ a.href = s, a.download = "marketing-material", a.click(), URL.revokeObjectURL(s);
88
+ } catch (i) {
89
+ console.error("Failed to download image:", i), window.open(n, "_blank");
90
+ }
91
+ }
92
+ async function b(n) {
93
+ n && await v(n, {
94
+ successMessage: e("connect.marketing.actions.imageLinkCopied")
95
+ });
96
+ }
97
+ return {
98
+ shareMaterial: r,
99
+ downloadMaterialImage: d,
100
+ copyMaterialLink: b
101
+ };
102
+ }
103
+ export {
104
+ F as a,
105
+ j as m,
106
+ B as u
107
+ };
@@ -1,6 +1,6 @@
1
1
  import { defineComponent as P, computed as v, ref as w, onMounted as $, watch as M, resolveComponent as D, openBlock as u, createElementBlock as p, createVNode as r, unref as n, createElementVNode as s, createCommentVNode as N, toDisplayString as b } from "vue";
2
2
  import { _ as S } from "./FmTableSelection.vue_vue_type_script_setup_true_lang-DzcUc0_w.js";
3
- import { l as E } from "./lodash-CJtUEnSL.js";
3
+ import { l as E } from "./lodash-CtOTzbaj.js";
4
4
  const R = { class: "" }, A = {
5
5
  key: 0,
6
6
  class: "w-full flex flex-col gap-16 items-center py-16"
@@ -1,20 +1,20 @@
1
1
  import { components as p } from "@feedmepos/ui-library";
2
- import { a as f } from "./plugins-0yAaVVcL.js";
3
- import { h as i } from "vue";
4
- function g(o, a = !1) {
5
- var t;
6
- return i(
2
+ import { c as f } from "./plugins-DY6km6IL.js";
3
+ import { h as c } from "vue";
4
+ function g(o, t = !1) {
5
+ var a;
6
+ return c(
7
7
  "div",
8
8
  {
9
9
  class: "flex items-center gap-x-8"
10
10
  },
11
11
  [
12
- i(p.FmAvatar, {
13
- name: o != null && o.photoUrl ? "-" : (t = o == null ? void 0 : o.name) == null ? void 0 : t.trim(),
12
+ c(p.FmAvatar, {
13
+ name: o != null && o.photoUrl ? "-" : (a = o == null ? void 0 : o.name) == null ? void 0 : a.trim(),
14
14
  src: (o == null ? void 0 : o.photoUrl) ?? void 0,
15
15
  size: "sm"
16
16
  }),
17
- i(
17
+ c(
18
18
  "div",
19
19
  {
20
20
  class: "flex flex-col",
@@ -23,8 +23,8 @@ function g(o, a = !1) {
23
23
  }
24
24
  },
25
25
  [
26
- i("span", o == null ? void 0 : o.name),
27
- a && i(
26
+ c("span", o == null ? void 0 : o.name),
27
+ t && c(
28
28
  "span",
29
29
  { class: "text-xs text-fm-color-typo-secondary" },
30
30
  (o == null ? void 0 : o.phoneNumber) || "-"
@@ -34,19 +34,19 @@ function g(o, a = !1) {
34
34
  ]
35
35
  );
36
36
  }
37
- function b(o, a) {
38
- var t, n;
39
- return ((n = (t = o.collection) == null ? void 0 : t.TITLE) == null ? void 0 : n.map(
40
- (c) => {
37
+ function b(o, t) {
38
+ var a, n;
39
+ return ((n = (a = o.collection) == null ? void 0 : a.TITLE) == null ? void 0 : n.map(
40
+ (i) => {
41
41
  var l;
42
- return (l = a == null ? void 0 : a.find((m) => m._id === c.collectible)) == null ? void 0 : l.name;
42
+ return (l = t == null ? void 0 : t.find((m) => m._id === i.collectible)) == null ? void 0 : l.name;
43
43
  }
44
44
  ).join(", ")) || "-";
45
45
  }
46
- function v(o, a) {
47
- var n, c, l, m;
48
- const t = (((l = (c = (n = o.collection) == null ? void 0 : n.TIER) == null ? void 0 : c[0]) == null ? void 0 : l.balance) || 0) - 1;
49
- return ((m = a[t]) == null ? void 0 : m.name) || "-";
46
+ function v(o, t) {
47
+ var n, i, l, m;
48
+ const a = (((l = (i = (n = o.collection) == null ? void 0 : n.TIER) == null ? void 0 : i[0]) == null ? void 0 : l.balance) || 0) - 1;
49
+ return ((m = t[a]) == null ? void 0 : m.name) || "-";
50
50
  }
51
51
  export {
52
52
  v as a,