@feedmepos/mf-connect 0.1.98-beta.71 → 0.1.98-beta.72

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 (117) hide show
  1. package/dist/{App-B-Onur9k.js → App-DpYceiwG.js} +8 -8
  2. package/dist/{AuditLogs-BnEeKG1C.js → AuditLogs-CG98b2qE.js} +11 -11
  3. package/dist/{Bin-BH9_nATR.js → Bin-vdipv2fF.js} +8 -8
  4. package/dist/{Broadcast-Gt2ZLLpZ.js → Broadcast-ChwVqheE.js} +91 -90
  5. package/dist/{CampaignAnalytic-BT6zTgNk.js → CampaignAnalytic-4PHO849x.js} +7 -7
  6. package/dist/{CampaignTypeDialog.vue_vue_type_script_setup_true_lang-nNLLEzii.js → CampaignTypeDialog.vue_vue_type_script_setup_true_lang-DmnN4pjm.js} +6 -6
  7. package/dist/{Card-dD52oor7.js → Card-B6ol3PQw.js} +21 -21
  8. package/dist/{Collections-7bwYNl3M.js → Collections-DodNIUr1.js} +8 -8
  9. package/dist/{Credit-qZdlqXqR.js → Credit-CJQyAZYw.js} +12 -12
  10. package/dist/{DateRangeChip.vue_vue_type_script_setup_true_lang-DeNn_k19.js → DateRangeChip.vue_vue_type_script_setup_true_lang--FqHJ7Ez.js} +1 -1
  11. package/dist/{EditCampaignSheet.vue_vue_type_script_setup_true_lang-C09W9Qja.js → EditCampaignSheet.vue_vue_type_script_setup_true_lang-CA31QP-A.js} +723 -659
  12. package/dist/{EffectSheet.vue_vue_type_style_index_0_lang-Bz1HRBMa.js → EffectSheet.vue_vue_type_style_index_0_lang-DkKhdp7G.js} +6 -6
  13. package/dist/{Experience-CAaWgWXP.js → Experience-iLAKddx_.js} +12 -12
  14. package/dist/{FileSaver.min-BpfY6VnX.js → FileSaver.min-w_ExQ0py.js} +1 -1
  15. package/dist/{Game-fhrbFb_5.js → Game-DWdUbsAg.js} +13 -13
  16. package/dist/{GiftCardSetup-CTwmNKim.js → GiftCardSetup-DnQ5vwxu.js} +10 -10
  17. package/dist/{Grab-BnPfb92x.js → Grab-CFLRHs5w.js} +9 -9
  18. package/dist/{ImageInput.vue_vue_type_script_setup_true_lang-BySju1oT.js → ImageInput.vue_vue_type_script_setup_true_lang-uQJvjvTe.js} +1 -1
  19. package/dist/{Index-DRwvmm_j.js → Index-CUy4z2tS.js} +10 -10
  20. package/dist/{LocationPicker.vue_vue_type_script_setup_true_lang-Ya4r9NNE.js → LocationPicker.vue_vue_type_script_setup_true_lang-hKJ41Fe_.js} +1 -1
  21. package/dist/{LottieAnimation.vue_vue_type_script_setup_true_lang-CDwtqqLQ.js → LottieAnimation.vue_vue_type_script_setup_true_lang-BDmtqTVC.js} +1 -1
  22. package/dist/{LoyaltyDashboard-8jn6SIWo.js → LoyaltyDashboard-C5o7KriA.js} +13 -13
  23. package/dist/{MainLayout-Bf42AcB1.js → MainLayout-Dt0ywph3.js} +3 -3
  24. package/dist/{Marketing-DruTMjiR.js → Marketing-BHwxzBZ0.js} +4 -4
  25. package/dist/{MarketingMaterialEdit-moEHd_gP.js → MarketingMaterialEdit-B6k4ceGx.js} +6 -6
  26. package/dist/{Member-C9VTQqIm.js → Member-DcPZfTj6.js} +7 -7
  27. package/dist/{MemberDetailSheet.vue_vue_type_script_setup_true_lang-DEsVSWmv.js → MemberDetailSheet.vue_vue_type_script_setup_true_lang-CiiBrlHY.js} +23 -23
  28. package/dist/{MemberImportHistory-DZVwya9v.js → MemberImportHistory-DmPMuu1g.js} +7 -7
  29. package/dist/{MemberList-KusIfy1u.js → MemberList-f9JejfNW.js} +14 -14
  30. package/dist/{MemberTransactions-msyjdzlI.js → MemberTransactions-D1YSXeX-.js} +1 -1
  31. package/dist/{MessageInput.vue_vue_type_script_setup_true_lang-DbV-m3cC.js → MessageInput.vue_vue_type_script_setup_true_lang-freeE-DP.js} +10 -10
  32. package/dist/{MetricInfoTooltip.vue_vue_type_script_setup_true_lang-1DYGpJnD.js → MetricInfoTooltip.vue_vue_type_script_setup_true_lang-m7ytg0ok.js} +1 -1
  33. package/dist/{Mission-CUUxpBUF.js → Mission-BaaEl5BV.js} +13 -13
  34. package/dist/{Overview-CYKoF8Hp.js → Overview-CviY55Gs.js} +4 -4
  35. package/dist/{Overview-C9jyKXHX.js → Overview-fx-0E3b8.js} +19 -19
  36. package/dist/{Point-CPpQ07yp.js → Point-BfqtflbC.js} +12 -12
  37. package/dist/{Promotion-CJ95m9Qb.js → Promotion-Be2ogRYt.js} +13 -13
  38. package/dist/{Queue-CX39ILh_.js → Queue-CLSUL-Cx.js} +11 -11
  39. package/dist/{Record-6I0qyXB5.js → Record-CpTMQT7B.js} +9 -9
  40. package/dist/{Review-DoWu2XNT.js → Review-DzSDx7dY.js} +2 -2
  41. package/dist/{ReviewFacebookCallback-Co-5TnI7.js → ReviewFacebookCallback-CvbPJADM.js} +5 -5
  42. package/dist/{ReviewGoogleCallback-Ca7ZuMcF.js → ReviewGoogleCallback-DJlqMbh3.js} +5 -5
  43. package/dist/{Reward-Cx_N6qBJ.js → Reward-DJOmd6Z5.js} +16 -16
  44. package/dist/{RewardGroup.vue_vue_type_script_setup_true_lang-Cn5Yp37p.js → RewardGroup.vue_vue_type_script_setup_true_lang-DY9fYxwc.js} +12 -12
  45. package/dist/{RuleGroup.vue_vue_type_script_setup_true_lang-M0c67Dyl.js → RuleGroup.vue_vue_type_script_setup_true_lang-BgYK4hpo.js} +13 -13
  46. package/dist/{Segment-Bx0EW966.js → Segment-G6xmeEaq.js} +24 -24
  47. package/dist/{SendCollectionSheet.vue_vue_type_script_setup_true_lang-ahvrEUGa.js → SendCollectionSheet.vue_vue_type_script_setup_true_lang-C3O0biLZ.js} +13 -13
  48. package/dist/{SendVoucherSheet.vue_vue_type_script_setup_true_lang-C7zSfZdl.js → SendVoucherSheet.vue_vue_type_script_setup_true_lang-CWP5sGT7.js} +4 -4
  49. package/dist/{Setting-DzEK3dWj.js → Setting-CKp441AW.js} +14 -14
  50. package/dist/{SettingAdvertisements-BNALbI88.js → SettingAdvertisements-C4Uf-DgK.js} +12 -12
  51. package/dist/{Settings-Cw85-xzq.js → Settings-CTvMVwp6.js} +5 -5
  52. package/dist/{Store-BSqW1gwf.js → Store-Bzei6Xev.js} +25 -25
  53. package/dist/{StoreRewards-CJXnS8Qf.js → StoreRewards-DMQNIpF5.js} +15 -15
  54. package/dist/{StoreTransactions.vue_vue_type_script_setup_true_lang-C6tUwHEj.js → StoreTransactions.vue_vue_type_script_setup_true_lang-mm1jbcvo.js} +24 -24
  55. package/dist/{TargetLocationInput.vue_vue_type_script_setup_true_lang-iylphGuV.js → TargetLocationInput.vue_vue_type_script_setup_true_lang-BspBXIO2.js} +2 -2
  56. package/dist/{Tier-DfitNxp2.js → Tier-BN32RwYr.js} +25 -25
  57. package/dist/{Title-QCbtOvKB.js → Title-BIhgfRUI.js} +21 -21
  58. package/dist/{Transaction-dOCzlidD.js → Transaction-CPjA7IN9.js} +2 -2
  59. package/dist/{UserRuleGroup.vue_vue_type_script_setup_true_lang-Be5X1C-Y.js → UserRuleGroup.vue_vue_type_script_setup_true_lang-DSutMvfk.js} +6 -6
  60. package/dist/{Voucher-BfoCDwjg.js → Voucher-CGJtn9bC.js} +14 -14
  61. package/dist/{VoucherEditor.vue_vue_type_script_setup_true_lang-0EIYoZ0F.js → VoucherEditor.vue_vue_type_script_setup_true_lang-B-IwtPvx.js} +12 -12
  62. package/dist/{ZodTextField.vue_vue_type_script_setup_true_lang-UdStgKbX.js → ZodTextField.vue_vue_type_script_setup_true_lang-Ce9xPwqA.js} +2 -2
  63. package/dist/{app-BxTElIm-.js → app-DAtx6aZ4.js} +182 -162
  64. package/dist/app.js +1 -1
  65. package/dist/{base.export-BmUK8hMh.js → base.export-BtRC4aWM.js} +2 -2
  66. package/dist/{business-DjAiT8tR.js → business-BZUIs8Ub.js} +1 -1
  67. package/dist/{campaign-tAmQNoq7.js → campaign-B6I6PuY4.js} +2 -2
  68. package/dist/{campaign-DlR3KF9m.js → campaign-DKjBjV2k.js} +138 -108
  69. package/dist/{campaign.enum-BjwEQd11.js → campaign.enum-BQy3e845.js} +1 -1
  70. package/dist/{campaign.fn-C6kWWIQx.js → campaign.fn--qVJ3jeH.js} +32 -32
  71. package/dist/{collectible.enum-BrtXpT9S.js → collectible.enum-vcvRFGl0.js} +1 -1
  72. package/dist/{collection.fn-CDhfM3Eq.js → collection.fn-C3bMPBkC.js} +2 -2
  73. package/dist/{currency-10nX5QnT.js → currency--R6VPInw.js} +1 -1
  74. package/dist/{duplicateCampaign-6oMZOvfM.js → duplicateCampaign-aIsX9cCi.js} +2 -2
  75. package/dist/{effect-T4YzuTc5.js → effect-CbjmtRph.js} +1 -1
  76. package/dist/{email-addresses-BjODnJMM.js → email-addresses-DZKMnoKf.js} +2 -2
  77. package/dist/{helper-BCl5r5yZ.js → helper-BGqw2-RO.js} +1 -1
  78. package/dist/{index-BeVWchv7.js → index-7TKoSEJ2.js} +5 -5
  79. package/dist/{index-BQk6zTgf.js → index-B9DM5Vuv.js} +2 -2
  80. package/dist/{index-DXiJa8Cw.js → index-BWlfW4Kr.js} +2 -2
  81. package/dist/{index-BxU--5J5.js → index-Bb4TieR_.js} +3 -3
  82. package/dist/{index-D8rGhchh.js → index-BbpqZrkB.js} +1 -1
  83. package/dist/{index-Ctja--IE.js → index-C22GPEM-.js} +1 -1
  84. package/dist/{index-BiolIgqR.js → index-CVYbfRGO.js} +1 -1
  85. package/dist/{index-C5IfNJUl.js → index-CVvSd60O.js} +1 -1
  86. package/dist/{index-DhtKt4OL.js → index-CXL5WAH0.js} +3 -3
  87. package/dist/{index-CnaQt4Pn.js → index-ClP7Xy6Q.js} +1 -1
  88. package/dist/{index-CRvUvCMA.js → index-D-P90w8K.js} +1 -1
  89. package/dist/{index-DeQKLilv.js → index-D_o9LsHU.js} +3 -3
  90. package/dist/{index-DJdTDF9C.js → index-DcA0B-Y5.js} +7 -7
  91. package/dist/{index-Bd4clHfr.js → index-FnsjvtSo.js} +5 -5
  92. package/dist/{index-B9ZMIUMa.js → index-LlFZ5kxi.js} +5 -5
  93. package/dist/{index-BBsK7TUw.js → index-LnCoUCnx.js} +3 -3
  94. package/dist/{index-Bz6oSli7.js → index-kkhrPH6s.js} +2 -2
  95. package/dist/{index-Bht1Z11w.js → index-v8Zv-2ko.js} +7 -7
  96. package/dist/{index.esm2017-CEOegJjn.js → index.esm2017-DO7bbE7J.js} +1 -1
  97. package/dist/{loading-Dx4SCvZY.js → loading-CzWOx4tE.js} +1 -1
  98. package/dist/{lodash-Dq8OKCKK.js → lodash-B_gr6Ayu.js} +1 -1
  99. package/dist/{member-import-DX-jn2uk.js → member-import-BxCrd9tq.js} +1 -1
  100. package/dist/{membership-CltAa-gH.js → membership-ILB4aB4h.js} +3 -3
  101. package/dist/{money-DsaAjJTI.js → money-CpIK1N_r.js} +1 -1
  102. package/dist/{number-DmhHKYgY.js → number-leVwmDCm.js} +1 -1
  103. package/dist/{objectid-BdNv-dZX.js → objectid-8hKuNcMN.js} +2 -2
  104. package/dist/{plugins-BFKVM3uC.js → plugins-DLIgnFIF.js} +3 -3
  105. package/dist/{reward--SjvIeyy.js → reward-DqT0zF01.js} +1 -1
  106. package/dist/{rule-CAKdNobZ.js → rule-DBtMGLxD.js} +8 -8
  107. package/dist/{template-Cfxc5eM8.js → template-CYKGCWY4.js} +6 -6
  108. package/dist/{timezone-D2b-V5XD.js → timezone-Brs5nrTL.js} +1 -1
  109. package/dist/{transaction.fn-B5mLY7bz.js → transaction.fn-0ZZcVp-j.js} +2 -2
  110. package/dist/{trigger-DvYcjRBZ.js → trigger-LhNre1L9.js} +5 -5
  111. package/dist/{useMarketingMaterialActions-DtqnjMSt.js → useMarketingMaterialActions-DbDRMmhM.js} +3 -3
  112. package/dist/{usePagination-DKX24g31.js → usePagination-DmZX0V64.js} +1 -1
  113. package/dist/{user-fWb1NxGO.js → user-CBPsvnx9.js} +1 -1
  114. package/dist/{vue-i18n-wJReAVJw.js → vue-i18n-BPeSHE3c.js} +157 -157
  115. package/dist/{xlsx-Mthhu4JR.js → xlsx-Cm3vGmLN.js} +1 -1
  116. package/dist/{zod-CVpVUgBZ.js → zod-GTEcy37q.js} +1 -1
  117. package/package.json +1 -1
package/dist/app.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import "vue";
2
- import { F as e, i as o, r as p } from "./app-BxTElIm-.js";
2
+ import { F as e, i as o, r as p } from "./app-DAtx6aZ4.js";
3
3
  export {
4
4
  e as FmApp,
5
5
  o as i18nMessages,
@@ -1,8 +1,8 @@
1
1
  var w = Object.defineProperty;
2
2
  var y = (e, s, o) => s in e ? w(e, s, { enumerable: !0, configurable: !0, writable: !0, value: o }) : e[s] = o;
3
3
  var n = (e, s, o) => y(e, typeof s != "symbol" ? s + "" : s, o);
4
- import { u as x } from "./loading-Dx4SCvZY.js";
5
- import { w as h, u as a } from "./xlsx-Mthhu4JR.js";
4
+ import { u as x } from "./loading-CzWOx4tE.js";
5
+ import { w as h, u as a } from "./xlsx-Cm3vGmLN.js";
6
6
  const t = {
7
7
  sortBy: "_id",
8
8
  descending: !1,
@@ -1,7 +1,7 @@
1
1
  import { ref as i, computed as u } from "vue";
2
2
  import { defineStore as w } from "pinia";
3
3
  import { useCoreStore as y } from "@feedmepos/mf-common";
4
- import { d as I, g as r, A as b, S, b as D } from "./index-BQk6zTgf.js";
4
+ import { d as I, g as r, A as b, S, b as D } from "./index-B9DM5Vuv.js";
5
5
  const $ = {
6
6
  async readSettings(e) {
7
7
  try {
@@ -1,7 +1,7 @@
1
1
  import { defineStore as d } from "pinia";
2
2
  import { reactive as b, onMounted as f, ref as s } from "vue";
3
- import { c } from "./index-Bz6oSli7.js";
4
- import { g as i, S as g, b as h } from "./index-BQk6zTgf.js";
3
+ import { c } from "./index-kkhrPH6s.js";
4
+ import { g as i, S as g, b as h } from "./index-B9DM5Vuv.js";
5
5
  const p = () => {
6
6
  const e = g.getBusinessId();
7
7
  if (!e) throw new Error("Invalid business ID");
@@ -1,27 +1,27 @@
1
- import { h as s } from "./moment-D7p2TMB-.js";
2
- import "./index-Bd4clHfr.js";
3
- import { e as l } from "./effect-T4YzuTc5.js";
4
- import { components as h } from "@feedmepos/ui-library";
5
- import { a as C } from "./index-DJdTDF9C.js";
6
- import { c as O } from "./rule-CAKdNobZ.js";
7
- import { u as b } from "./business-DjAiT8tR.js";
8
- import { C as i } from "./campaign.fn-C6kWWIQx.js";
9
- import { t as y } from "./index-BeVWchv7.js";
10
- import { c as d } from "./string-Gcy5IM_H.js";
11
- import { i as f } from "./plugins-BFKVM3uC.js";
1
+ import { h as u } from "./moment-D7p2TMB-.js";
2
+ import "./index-FnsjvtSo.js";
3
+ import { e as f } from "./effect-CbjmtRph.js";
4
+ import { components as d } from "@feedmepos/ui-library";
5
+ import { a as b } from "./index-DcA0B-Y5.js";
6
+ import { c as E } from "./rule-DBtMGLxD.js";
7
+ import { u as N } from "./business-BZUIs8Ub.js";
8
+ import { C as m } from "./campaign.fn--qVJ3jeH.js";
9
+ import { t as h } from "./index-7TKoSEJ2.js";
10
+ import { c as y } from "./string-Gcy5IM_H.js";
11
+ import { i as l } from "./plugins-DLIgnFIF.js";
12
12
  import { h as p } from "vue";
13
- import { F as c } from "./campaign.enum-BjwEQd11.js";
14
- const E = [
13
+ import { F as r } from "./campaign.enum-BQy3e845.js";
14
+ const I = [
15
15
  "APP_INBOX",
16
16
  "PUSH",
17
17
  "SMS",
18
18
  "EMAIL",
19
19
  "WHATSAPP"
20
- ], N = [...E];
21
- function G(t) {
22
- return N.includes(t);
20
+ ], R = [...I];
21
+ function j(t) {
22
+ return R.includes(t);
23
23
  }
24
- function I(t, e) {
24
+ function C(t, e) {
25
25
  return t === "APP_INBOX" ? {
26
26
  title: "",
27
27
  previewText: "",
@@ -40,13 +40,13 @@ function I(t, e) {
40
40
  variables: e
41
41
  };
42
42
  }
43
- function j(t, e, n = []) {
43
+ function k(t, e, n = []) {
44
44
  return t.channels.includes(e) ? t : {
45
45
  ...t,
46
46
  channels: [...t.channels, e],
47
47
  content: {
48
48
  ...t.content,
49
- [e]: t.content[e] ?? I(e, n)
49
+ [e]: t.content[e] ?? C(e, n)
50
50
  }
51
51
  };
52
52
  }
@@ -58,22 +58,42 @@ function V(t, e) {
58
58
  content: n
59
59
  };
60
60
  }
61
- function k(t, e, n) {
61
+ function z(t, e, n) {
62
62
  return {
63
63
  ...t,
64
64
  content: { ...t.content, [e]: n }
65
65
  };
66
66
  }
67
- function z(t, e, n) {
68
- const o = t.channels.indexOf(e), m = o + n;
69
- if (o < 0 || m < 0 || m >= t.channels.length) return t;
70
- const u = [...t.channels];
71
- return [u[o], u[m]] = [u[m], u[o]], { ...t, channels: u };
67
+ function X(t, e, n) {
68
+ const o = t.channels.indexOf(e), c = o + n;
69
+ if (o < 0 || c < 0 || c >= t.channels.length) return t;
70
+ const s = [...t.channels];
71
+ return [s[o], s[c]] = [s[c], s[o]], { ...t, channels: s };
72
+ }
73
+ function W(t, e, n = []) {
74
+ const [o, ...c] = t.channels;
75
+ if (o === e) return t;
76
+ const s = {
77
+ ...t.content,
78
+ [e]: t.content[e] ?? C(e, n)
79
+ };
80
+ return o && delete s[o], {
81
+ ...t,
82
+ channels: [e, ...c.filter((O) => O !== e)],
83
+ content: s
84
+ };
85
+ }
86
+ function J(t, e) {
87
+ if (!e) return !1;
88
+ const n = t.content[e];
89
+ return n ? ["title", "previewText", "content", "body"].some(
90
+ (o) => typeof n[o] == "string" && !!n[o].trim()
91
+ ) : !1;
72
92
  }
73
- function X(t, e) {
93
+ function K(t, e) {
74
94
  return { ...t, mode: e };
75
95
  }
76
- function W(t, e) {
96
+ function q(t, e) {
77
97
  const n = t.content[e];
78
98
  if (!n) return !1;
79
99
  if (e === "APP_INBOX") {
@@ -86,160 +106,170 @@ function W(t, e) {
86
106
  }
87
107
  return n.content.trim().length > 0;
88
108
  }
89
- function R(t, e) {
109
+ function S(t, e) {
90
110
  return t.channels.map(e).join(t.mode === "fallback" ? " → " : " + ");
91
111
  }
92
- const a = f.global.t;
93
- function S() {
94
- const t = f.global.locale;
112
+ function Q(t) {
113
+ var e, n;
114
+ if (!(!t || t.delivery)) {
115
+ if ((n = (e = t.message) == null ? void 0 : e.content) != null && n.trim()) {
116
+ t.delivery = h(t);
117
+ return;
118
+ }
119
+ delete t.message, t.delivery = { mode: "fallback", channels: [], content: {} };
120
+ }
121
+ }
122
+ const a = l.global.t;
123
+ function D() {
124
+ const t = l.global.locale;
95
125
  return typeof t == "string" ? t : t.value;
96
126
  }
97
127
  function g(t) {
98
- return new Intl.DateTimeFormat(S(), {
128
+ return new Intl.DateTimeFormat(D(), {
99
129
  day: "2-digit",
100
130
  month: "short",
101
131
  year: "numeric"
102
132
  }).format(new Date(t));
103
133
  }
104
- function r(t) {
134
+ function i(t) {
105
135
  return p(
106
136
  "div",
107
137
  {
108
138
  class: `${t.chipClass} gap-4 h-[22px] inline-flex items-center justify-center min-w-min px-8 rounded-md`
109
139
  },
110
140
  [
111
- p(h.FmIcon, { size: "sm", name: t.icon, outline: !0 }),
141
+ p(d.FmIcon, { size: "sm", name: t.icon, outline: !0 }),
112
142
  p("span", { class: "fm-typo-en-body-md-600" }, t.name)
113
143
  ]
114
144
  );
115
145
  }
116
- const J = {
117
- [c.enum.CREDIT]: {
146
+ const Z = {
147
+ [r.enum.CREDIT]: {
118
148
  chipClass: "!text-fm-color-secondary-plum !bg-[#f2ebfe]",
119
149
  icon: "local_activity",
120
150
  get name() {
121
151
  return a("connect.campaign.common.typeName.CREDIT");
122
152
  },
123
153
  chip() {
124
- return r(this);
154
+ return i(this);
125
155
  }
126
156
  },
127
- [c.enum.PROMOTION]: {
157
+ [r.enum.PROMOTION]: {
128
158
  chipClass: "!text-fm-color-secondary-citrus !bg-fm-color-system-warning-100",
129
159
  icon: "loyalty",
130
160
  get name() {
131
161
  return a("connect.campaign.common.typeName.PROMOTION");
132
162
  },
133
163
  chip() {
134
- return r(this);
164
+ return i(this);
135
165
  }
136
166
  },
137
- [c.enum.VOUCHER]: {
167
+ [r.enum.VOUCHER]: {
138
168
  chipClass: "!text-fm-color-secondary-halite !bg-[#fff0f6]",
139
169
  icon: "sell",
140
170
  get name() {
141
171
  return a("connect.campaign.common.typeName.VOUCHER");
142
172
  },
143
173
  chip() {
144
- return r(this);
174
+ return i(this);
145
175
  }
146
176
  },
147
- [c.enum.POINT]: {
177
+ [r.enum.POINT]: {
148
178
  chipClass: "!text-fm-color-secondary-cocoa !bg-[#fff9e6]",
149
179
  icon: "award_star",
150
180
  get name() {
151
181
  return a("connect.campaign.common.typeName.POINT");
152
182
  },
153
183
  chip() {
154
- return r(this);
184
+ return i(this);
155
185
  }
156
186
  },
157
- [c.enum.BROADCAST]: {
187
+ [r.enum.BROADCAST]: {
158
188
  chipClass: "!text-fm-color-typo-info !bg-fm-color-system-info-100",
159
189
  icon: "campaign",
160
190
  get name() {
161
191
  return a("connect.campaign.common.typeName.BROADCAST");
162
192
  },
163
193
  chip() {
164
- return r(this);
194
+ return i(this);
165
195
  }
166
196
  },
167
- [c.enum.GAME]: {
197
+ [r.enum.GAME]: {
168
198
  chipClass: "!text-fm-color-secondary-mint !bg-fm-color-system-success-100",
169
199
  icon: "database",
170
200
  get name() {
171
201
  return a("connect.campaign.common.typeName.GAME");
172
202
  },
173
203
  chip() {
174
- return r(this);
204
+ return i(this);
175
205
  }
176
206
  },
177
- [c.enum.REWARD_POOL]: {
207
+ [r.enum.REWARD_POOL]: {
178
208
  chipClass: "!text-fm-color-secondary-tuna !bg-[#e3f4f9]",
179
209
  icon: "editor_choice",
180
210
  get name() {
181
211
  return a("connect.campaign.common.typeName.REWARD_POOL");
182
212
  },
183
213
  chip() {
184
- return r(this);
214
+ return i(this);
185
215
  }
186
216
  },
187
- [c.enum.COIN]: {
217
+ [r.enum.COIN]: {
188
218
  chipClass: "!text-fm-color-system-success-400 !bg-fm-color-system-success-100",
189
219
  icon: "monetization_on",
190
220
  get name() {
191
221
  return a("connect.campaign.common.typeName.COIN");
192
222
  },
193
223
  chip() {
194
- return r(this);
224
+ return i(this);
195
225
  }
196
226
  },
197
- [c.enum.MEMBERSHIP]: {
227
+ [r.enum.MEMBERSHIP]: {
198
228
  chipClass: "",
199
229
  icon: "",
200
230
  get name() {
201
231
  return a("connect.campaign.common.typeName.MEMBERSHIP");
202
232
  },
203
233
  chip() {
204
- return r(this);
234
+ return i(this);
205
235
  }
206
236
  },
207
- [c.enum.MISSION]: {
237
+ [r.enum.MISSION]: {
208
238
  chipClass: "!text-fm-color-secondary-tuna !bg-[#e3f4f9]",
209
239
  icon: "editor_choice",
210
240
  get name() {
211
241
  return a("connect.campaign.common.typeName.MISSION");
212
242
  },
213
243
  chip() {
214
- return r(this);
244
+ return i(this);
215
245
  }
216
246
  },
217
- [c.enum.GRAB]: {
247
+ [r.enum.GRAB]: {
218
248
  chipClass: "!text-fm-color-secondary-tuna !bg-[#e3f4f9]",
219
249
  icon: "editor_choice",
220
250
  name: "Grab",
221
251
  chip() {
222
- return r(this);
252
+ return i(this);
223
253
  }
224
254
  }
225
255
  };
226
- function K(t) {
256
+ function tt(t) {
227
257
  const e = _(t), n = {
228
258
  active: "text-fm-color-typo-success bg-fm-color-system-success-100",
229
259
  upcoming: "text-fm-color-typo-info bg-fm-color-system-info-100",
230
260
  expired: "text-fm-color-typo-error bg-fm-color-system-error-100"
231
261
  };
232
- return t.type == "VOUCHER" ? p(h.FmChip, {
262
+ return t.type == "VOUCHER" ? p(d.FmChip, {
233
263
  class: n[e],
234
- label: d.title(a(`connect.campaign.common.status.${e}`)),
264
+ label: y.title(a(`connect.campaign.common.status.${e}`)),
235
265
  compact: !0
236
- }) : p(h.FmChip, {
266
+ }) : p(d.FmChip, {
237
267
  class: n[e],
238
- label: d.title(a(`connect.campaign.common.status.${e}`)),
268
+ label: y.title(a(`connect.campaign.common.status.${e}`)),
239
269
  compact: !0
240
270
  });
241
271
  }
242
- function q(t) {
272
+ function et(t) {
243
273
  const e = t.timeframeOptions;
244
274
  if (!e || !e.start && !e.end)
245
275
  return a("connect.campaign.common.always_active");
@@ -253,10 +283,10 @@ function q(t) {
253
283
  function A(t) {
254
284
  if (!t || !t.start && !t.end)
255
285
  return "connect.campaign.common.always";
256
- const e = t.start ? s(t.start).format("DD MMM YYYY") : "From campaign creation", n = t.end ? s(t.end).format("DD MMM YYYY") : "Never ends";
286
+ const e = t.start ? u(t.start).format("DD MMM YYYY") : "From campaign creation", n = t.end ? u(t.end).format("DD MMM YYYY") : "Never ends";
257
287
  return `${e} - ${n}`;
258
288
  }
259
- function Q(t) {
289
+ function nt(t) {
260
290
  const { campaign: e } = t;
261
291
  return {
262
292
  "connect.campaign.common.campaign_name": e.name,
@@ -264,84 +294,81 @@ function Q(t) {
264
294
  e.timeframeOptions
265
295
  ),
266
296
  get "connect.campaign.common.next_schedule_at"() {
267
- if ((e == null ? void 0 : e.event.type) != "SCHEDULE" || !e.event.rule || !C(e.event.rule))
297
+ if ((e == null ? void 0 : e.event.type) != "SCHEDULE" || !e.event.rule || !b(e.event.rule))
268
298
  return;
269
- const n = O(
299
+ const n = E(
270
300
  e.event.rule.rules.g_schedule
271
301
  );
272
- return n ? s(n).format("ddd, DD MMM YYYY, hh:mmA") : void 0;
302
+ return n ? u(n).format("ddd, DD MMM YYYY, hh:mmA") : void 0;
273
303
  },
274
304
  get "connect.campaign.common.discount_type"() {
275
- if (e.type == "PROMOTION") return l(e.effect);
305
+ if (e.type == "PROMOTION") return f(e.effect);
276
306
  if ("configs" in t && t.configs.type == "VOUCHER")
277
- return l(t.configs.extras.effect);
307
+ return f(t.configs.extras.effect);
278
308
  },
279
309
  get "connect.campaign.broadcast.summary.delivery"() {
280
310
  if (e.type != "BROADCAST") return;
281
- const n = y(e);
311
+ const n = h(e);
282
312
  if (!(n.channels.length < 2))
283
313
  return `connect.campaign.broadcast.mode.${n.mode}.label`;
284
314
  },
285
315
  get "connect.campaign.broadcast.summary.channels"() {
286
316
  var n;
287
317
  if (e.type == "BROADCAST")
288
- return ((n = D(e)) == null ? void 0 : n.route) ?? "connect.campaign.broadcast.noChannelsSelected";
318
+ return ((n = P(e)) == null ? void 0 : n.route) ?? "connect.campaign.broadcast.noChannelsSelected";
289
319
  },
290
320
  get "connect.campaign.common.available_at"() {
291
321
  return e.targetLocation ? e.targetLocation.length > 0 ? e.targetLocation.map(
292
- (n) => b().locationItems.find((o) => o.value == n).label
322
+ (n) => N().locationItems.find((o) => o.value == n).label
293
323
  ).join(",") : "connect.campaign.common.no_location" : "connect.campaign.common.all_locations";
294
324
  }
295
325
  };
296
326
  }
297
327
  function _(t) {
298
- return t.timeframeOptions && t.timeframeOptions.type == "timeframe" ? s().isBetween(
299
- t.timeframeOptions.start ?? s().subtract(1, "d"),
300
- t.timeframeOptions.end ?? s().add(1, "d")
301
- ) ? "active" : s().isAfter(t.timeframeOptions.end) ? "expired" : "upcoming" : "active";
328
+ return t.timeframeOptions && t.timeframeOptions.type == "timeframe" ? u().isBetween(
329
+ t.timeframeOptions.start ?? u().subtract(1, "d"),
330
+ t.timeframeOptions.end ?? u().add(1, "d")
331
+ ) ? "active" : u().isAfter(t.timeframeOptions.end) ? "expired" : "upcoming" : "active";
302
332
  }
303
- function D(t) {
304
- const e = y(t);
333
+ function P(t) {
334
+ const e = h(t);
305
335
  if (!e.channels.length) return null;
306
- const n = R(
307
- e,
308
- (o) => f.global.t(`connect.campaign.broadcast.channel.${o}`)
309
- );
336
+ const o = S(e, (c) => l.global.t(`connect.campaign.broadcast.channel.${c}`));
310
337
  return {
311
- strategy: e.channels.length > 1 ? f.global.t(
338
+ strategy: e.channels.length > 1 ? l.global.t(
312
339
  `connect.campaign.broadcast.strategy.${e.mode}`
313
340
  ) : null,
314
- route: n
341
+ route: o
315
342
  };
316
343
  }
317
- function Z(t) {
344
+ function ot(t) {
318
345
  var e, n;
319
346
  switch (t.event.type) {
320
347
  case "BILL_COMPLETED":
321
- const o = `Spend to get ${i.formattedType(t.type)}`;
348
+ const o = `Spend to get ${m.formattedType(t.type)}`;
322
349
  switch (t.type) {
323
350
  case "POINT":
324
351
  case "CREDIT":
325
352
  case "COIN":
326
- return t.earningOption.type == "FIXED" ? `Spend to get ${t.earningOption.amount} ${i.formattedType(t.type)}` : `Every ${t.earningOption.every} amount spent get ${t.earningOption.amount} ${i.formattedType(t.type)}`;
353
+ return t.earningOption.type == "FIXED" ? `Spend to get ${t.earningOption.amount} ${m.formattedType(t.type)}` : `Every ${t.earningOption.every} amount spent get ${t.earningOption.amount} ${m.formattedType(t.type)}`;
327
354
  case "VOUCHER":
328
- const m = (n = (e = t == null ? void 0 : t.pf_collectible) == null ? void 0 : e.extras) == null ? void 0 : n.effect;
329
- return m ? `${o} - ${l(m)}` : o;
355
+ const c = (n = (e = t == null ? void 0 : t.pf_collectible) == null ? void 0 : e.extras) == null ? void 0 : n.effect;
356
+ return c ? `${o} - ${f(c)}` : o;
330
357
  default:
331
358
  return o;
332
359
  }
333
360
  case "FEEDBACK":
334
- return `Give feedback to receive ${i.formattedType(t.type)}`;
361
+ return `Give feedback to receive ${m.formattedType(t.type)}`;
335
362
  case "SCHEDULE":
336
- return `Receive ${i.formattedType(t.type)} on scheduled time`;
363
+ return `Receive ${m.formattedType(t.type)} on scheduled time`;
337
364
  case "SIMPLE_CLAIM":
338
365
  return "Simple claim voucher";
339
366
  case "TIER_UPGRADED":
340
- return `Receive ${i.formattedType(t.type)} when member tier upgraded`;
367
+ return `Receive ${m.formattedType(t.type)} when member tier upgraded`;
341
368
  case "MEMBERSHIP_JOINED":
342
- return `Receive ${i.formattedType(t.type)} when member joined`;
369
+ return `Receive ${m.formattedType(t.type)} when member joined`;
343
370
  case "MAKING_ORDER":
344
- return t.type !== "PROMOTION" ? void 0 : l(t.effect);
371
+ return t.type !== "PROMOTION" ? void 0 : f(t.effect);
345
372
  default:
346
373
  throw new Error(
347
374
  `Not implemented ${JSON.stringify({ cause: t.event.type })}`
@@ -349,20 +376,23 @@ function Z(t) {
349
376
  }
350
377
  }
351
378
  export {
352
- J as C,
379
+ Z as C,
353
380
  _ as a,
354
- K as b,
355
- Z as c,
356
- D as d,
357
- E as e,
358
- W as f,
359
- q as g,
360
- j as h,
361
- G as i,
362
- X as j,
363
- k,
364
- Q as l,
365
- z as m,
381
+ tt as b,
382
+ ot as c,
383
+ P as d,
384
+ I as e,
385
+ q as f,
386
+ et as g,
387
+ k as h,
388
+ j as i,
389
+ K as j,
390
+ J as k,
391
+ W as l,
392
+ X as m,
393
+ z as n,
394
+ nt as o,
395
+ Q as p,
366
396
  V as r,
367
397
  A as s
368
398
  };
@@ -1,4 +1,4 @@
1
- import { z as E } from "./index-BxU--5J5.js";
1
+ import { z as E } from "./index-Bb4TieR_.js";
2
2
  const M = E.enum([
3
3
  "VOUCHER",
4
4
  "PROMOTION",