@feedmepos/mf-connect 0.1.38-beta.83 → 0.1.38-beta.85

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 (107) hide show
  1. package/dist/{Analytic-DJAlQ2pL.js → Analytic-b8mA9c9Y.js} +13 -13
  2. package/dist/{App-Be9v2Mex.js → App-XFiefZAx.js} +595 -592
  3. package/dist/{AuditLogs-DwtO0cf4.js → AuditLogs-DTcAAlxV.js} +9 -9
  4. package/dist/{Bin-Cxa9zQnN.js → Bin-CzsWUmIN.js} +8 -8
  5. package/dist/{Broadcast-D5KL5PdU.js → Broadcast-D_3C1KYk.js} +9 -9
  6. package/dist/{CampaignTypeDialog.vue_vue_type_script_setup_true_lang-Bggy1rRH.js → CampaignTypeDialog.vue_vue_type_script_setup_true_lang-DX5JM6sI.js} +6 -6
  7. package/dist/{Card-lZQHWj1I.js → Card-BmEm66lU.js} +18 -18
  8. package/dist/{Collections-C8qPkQLj.js → Collections-Ry-MQM44.js} +7 -7
  9. package/dist/{Credit-9ysOHfc_.js → Credit-DVVJjxgZ.js} +9 -9
  10. package/dist/{EditCampaignSheet.vue_vue_type_script_setup_true_lang-PsT33T3z.js → EditCampaignSheet.vue_vue_type_script_setup_true_lang-_WZUfwnP.js} +33 -33
  11. package/dist/{EffectSheet.vue_vue_type_style_index_0_lang-BL3eRbqu.js → EffectSheet.vue_vue_type_style_index_0_lang-B6KcW1Rh.js} +6 -6
  12. package/dist/{Experience-CA4lgQXP.js → Experience-DyOeEZu2.js} +9 -9
  13. package/dist/{FileSaver.min-BbU3im0h.js → FileSaver.min-D0Xa_nbt.js} +1 -1
  14. package/dist/{Game-YhxaGafX.js → Game-C25Rgy7x.js} +10 -10
  15. package/dist/{Grab-TKwe3os8.js → Grab-BaG_Xwvt.js} +8 -8
  16. package/dist/{ImageInput.vue_vue_type_script_setup_true_lang-CbEUTniY.js → ImageInput.vue_vue_type_script_setup_true_lang-X9zk3Atr.js} +1 -1
  17. package/dist/{Index-D1LAt3Np.js → Index-BIFAhH2O.js} +10 -10
  18. package/dist/{LocationPicker.vue_vue_type_script_setup_true_lang-57wNU0SV.js → LocationPicker.vue_vue_type_script_setup_true_lang-DQQVh3ap.js} +1 -1
  19. package/dist/{LottieAnimation.vue_vue_type_script_setup_true_lang-B3YaW9Ot.js → LottieAnimation.vue_vue_type_script_setup_true_lang-BwJaLc8D.js} +1 -1
  20. package/dist/{MainLayout-D6_st4qp.js → MainLayout-BhCYNX3n.js} +1 -1
  21. package/dist/{Marketing-DL5qQws0.js → Marketing-C19yd_BK.js} +99 -100
  22. package/dist/{MarketingMaterialEdit-D1cfcfBu.js → MarketingMaterialEdit-CyKJp44W.js} +411 -409
  23. package/dist/{Member-DTD0mS4Z.js → Member-CINhmBJN.js} +11 -11
  24. package/dist/{MemberList-BUjxE5NK.js → MemberList-BWvurFcu.js} +26 -26
  25. package/dist/{MemberTransactions-CcZDFo0g.js → MemberTransactions-DjxllAVe.js} +1 -1
  26. package/dist/{MessageInput.vue_vue_type_script_setup_true_lang-HUuPLKIl.js → MessageInput.vue_vue_type_script_setup_true_lang-BOohwOuN.js} +9 -9
  27. package/dist/{Mission-BzSCDXcq.js → Mission-DHS0FPgm.js} +10 -10
  28. package/dist/{Overview-BSGHpRSU.js → Overview-DFKG3hyX.js} +18 -18
  29. package/dist/{Point-CrQhN0Vf.js → Point-C0lV-lkL.js} +9 -9
  30. package/dist/{Promotion-DeOhdHkm.js → Promotion-aDnFW2P_.js} +10 -10
  31. package/dist/{Queue-DOv6c0Ge.js → Queue-CtH9-eLs.js} +14 -14
  32. package/dist/{Record-M_U9BsVx.js → Record-CQydFJqp.js} +9 -9
  33. package/dist/{Review-BjTjYx14.js → Review-CKsWMX2o.js} +4 -4
  34. package/dist/{ReviewFacebookCallback-YC7Z3b93.js → ReviewFacebookCallback-D4jb1HC4.js} +4 -4
  35. package/dist/{ReviewGoogleCallback-CyyVC3LZ.js → ReviewGoogleCallback-CCXJc9fi.js} +4 -4
  36. package/dist/{Reward-CwoLTenr.js → Reward-BRr8fWN4.js} +16 -16
  37. package/dist/{RewardGroup.vue_vue_type_script_setup_true_lang-C6Ji5bXQ.js → RewardGroup.vue_vue_type_script_setup_true_lang-t4cBlpPd.js} +11 -11
  38. package/dist/{RuleGroup.vue_vue_type_script_setup_true_lang-DS4VODfI.js → RuleGroup.vue_vue_type_script_setup_true_lang-oiLK2FWO.js} +14 -14
  39. package/dist/Segment-BMNT_K48.js +1015 -0
  40. package/dist/{SelectItems.vue_vue_type_script_setup_true_lang-DZ2CbKu6.js → SelectItems.vue_vue_type_script_setup_true_lang-Co9D6B80.js} +2 -2
  41. package/dist/{SendCollectionSheet.vue_vue_type_script_setup_true_lang-DSLOGG9z.js → SendCollectionSheet.vue_vue_type_script_setup_true_lang-RMfUCmZH.js} +12 -12
  42. package/dist/{SendVoucherSheet.vue_vue_type_script_setup_true_lang-CNO95DBX.js → SendVoucherSheet.vue_vue_type_script_setup_true_lang-B7BP9ow8.js} +4 -4
  43. package/dist/{Setting-DPsDvTr-.js → Setting-Bv6KoqKT.js} +160 -160
  44. package/dist/{SettingAdvertisements-B78nHQWZ.js → SettingAdvertisements-C5EdDN8V.js} +29 -29
  45. package/dist/{Store-CtOsS8xI.js → Store-Iiwd-cqe.js} +21 -21
  46. package/dist/{StoreRewards-DYiTSy_e.js → StoreRewards-B8GCy9Q8.js} +15 -15
  47. package/dist/{StoreTransactions.vue_vue_type_script_setup_true_lang-CWjC-H8n.js → StoreTransactions.vue_vue_type_script_setup_true_lang-DCuLpnZz.js} +21 -21
  48. package/dist/{TargetLocationInput.vue_vue_type_script_setup_true_lang-BsWr5iPt.js → TargetLocationInput.vue_vue_type_script_setup_true_lang-CKjg0o86.js} +2 -2
  49. package/dist/{Tier-BjA-f408.js → Tier-C5QHgi86.js} +23 -23
  50. package/dist/{Title-CCyLBahF.js → Title-DCpgwhkh.js} +20 -20
  51. package/dist/{Transaction-CtF7MpPV.js → Transaction-p-jqY2uR.js} +2 -2
  52. package/dist/{UserRuleGroup.vue_vue_type_script_setup_true_lang-_GgNR8VU.js → UserRuleGroup.vue_vue_type_script_setup_true_lang-z_pRXQs5.js} +6 -6
  53. package/dist/{Voucher-CiB7KTLn.js → Voucher-CwPK7CI3.js} +13 -13
  54. package/dist/{VoucherEditor.vue_vue_type_script_setup_true_lang-BH4xZfZN.js → VoucherEditor.vue_vue_type_script_setup_true_lang-U3lPcMsO.js} +12 -12
  55. package/dist/{ZodTextField.vue_vue_type_script_setup_true_lang-Desirrtn.js → ZodTextField.vue_vue_type_script_setup_true_lang-DZK3Vhgl.js} +2 -2
  56. package/dist/{app-DwodX_i8.js → app-Bd1PovAE.js} +201 -51
  57. package/dist/app.js +1 -1
  58. package/dist/{business-Cn27thty.js → business-DY9T_8D6.js} +1 -1
  59. package/dist/{campaign-B5A9loZe.js → campaign-Cj8ykwZM.js} +1 -1
  60. package/dist/{campaign-6X21-84u.js → campaign-D9-2cfGS.js} +8 -8
  61. package/dist/{campaign.enum-C4XI-2uW.js → campaign.enum-Dn1IZjm3.js} +1 -1
  62. package/dist/{campaign.fn-Cy8xHdXa.js → campaign.fn-BpmRNefC.js} +49 -49
  63. package/dist/{collectible.enum-BwXbunhX.js → collectible.enum-DwDiqgOQ.js} +1 -1
  64. package/dist/{collection.fn-CoZvQLXf.js → collection.fn-DxxhNNiS.js} +2 -2
  65. package/dist/{dto-CJPgpJeE.js → dto-exJWIIFh.js} +4 -4
  66. package/dist/{duplicateCampaign-Co8IUe8o.js → duplicateCampaign-VlwdEOpi.js} +2 -2
  67. package/dist/{effect-OOGMytqr.js → effect-B1gX3HYy.js} +1 -1
  68. package/dist/{email-addresses-C9y4CjuV.js → email-addresses-C0tfIamr.js} +2 -2
  69. package/dist/{export-CvC5ed4-.js → export-D2LYUW7D.js} +3 -3
  70. package/dist/{helper-CDsjQExO.js → helper-9iFjiuBS.js} +1 -1
  71. package/dist/{index-BqerQCGe.js → index--0-PrELA.js} +1 -1
  72. package/dist/{index-kSWGToWZ.js → index-CBMnWVoT.js} +1 -1
  73. package/dist/{index-B9nPYjQB.js → index-CdANllE-.js} +1 -1
  74. package/dist/index-DBXGg3yg.js +36 -0
  75. package/dist/{index-sFHmfWSg.js → index-DWi7IG9Q.js} +1 -1
  76. package/dist/{index-BfyCSqKW.js → index-DZr_AJes.js} +1 -1
  77. package/dist/{index-Bd45J3-G.js → index-DaIOBj8s.js} +1 -1
  78. package/dist/{index-C1qWtbsk.js → index-E19Gtmxw.js} +3 -3
  79. package/dist/{index-DuFCtWQR.js → index-I9yn8pHU.js} +2 -2
  80. package/dist/{index-BLT69c7j.js → index-TwCRZqdr.js} +557 -559
  81. package/dist/{index-CXx7eJq-.js → index-VnQA51n7.js} +6 -6
  82. package/dist/{index-OpxeXVwt.js → index-_ax9IcMt.js} +1499 -1328
  83. package/dist/{index-Bb4k_x_l.js → index-mkNRK108.js} +1 -1
  84. package/dist/{index-BF8lJP43.js → index-mynItfLE.js} +3 -3
  85. package/dist/{index.esm2017-DaR3DCu-.js → index.esm2017-CbwAxX_t.js} +1 -1
  86. package/dist/{loading-C6rG0eo_.js → loading-BUUuNRb8.js} +1 -1
  87. package/dist/{lodash-CjEq2BFu.js → lodash-DzFwGhp3.js} +1 -1
  88. package/dist/{membership-F6iQ9MVy.js → membership-BSY7S3nW.js} +13 -6
  89. package/dist/{money-5QzsxME5.js → money-DB8eMVCB.js} +1 -1
  90. package/dist/{number-D4fGOH1o.js → number-CmlQv3bk.js} +1 -1
  91. package/dist/{objectid--IshXbfs.js → objectid-DN-4NnaP.js} +5 -5
  92. package/dist/{plugins-DXS2Wod6.js → plugins-DATxgRFK.js} +3 -3
  93. package/dist/remy-D_Deb3ue.js +13 -0
  94. package/dist/{reward-C0xdUVfq.js → reward-C3NsvqTO.js} +1 -1
  95. package/dist/{rule-builder-D0vYClpg.js → rule-builder-EOj4zyYT.js} +1 -1
  96. package/dist/{rule-DOM5_QUx.js → rule-zKaaqUwQ.js} +3 -3
  97. package/dist/{template-B_TviSPw.js → template-KUFfOua-.js} +6 -6
  98. package/dist/{timezone-Ds--TfLn.js → timezone-HIZKEUxS.js} +2 -2
  99. package/dist/{trigger-3i4tC4VG.js → trigger-8HJ7QGEI.js} +12 -12
  100. package/dist/{usePagination-9ioQud_y.js → usePagination-CvSSPoM-.js} +1 -1
  101. package/dist/{user-QfaNByCY.js → user-C5FK05SW.js} +1 -1
  102. package/dist/{vue-i18n-C8QhQx73.js → vue-i18n-VE9cLms0.js} +327 -327
  103. package/dist/{xlsx-DwXQmhHW.js → xlsx-C_8oyTCI.js} +1 -1
  104. package/dist/{zod-BbCQlI-1.js → zod-DrlA6hIW.js} +1 -1
  105. package/package.json +1 -1
  106. package/dist/Segment-CKPt2gET.js +0 -891
  107. package/dist/remy-BnbV5Fsx.js +0 -46
@@ -1,891 +0,0 @@
1
- import { defineComponent as ee, ref as z, resolveComponent as S, openBlock as m, createElementBlock as k, createElementVNode as l, createVNode as r, unref as t, createCommentVNode as le, withCtx as E, Fragment as O, renderList as ie, createBlock as J, toDisplayString as P, normalizeClass as re, onMounted as Se, computed as ce, isRef as Ie, createSlots as Me, h as Y, onBeforeMount as Te } from "vue";
2
- import { _ as Ee } from "./campaign-CpzFl8Vr.js";
3
- import { n as Ae, p as De } from "./plugins-DXS2Wod6.js";
4
- import { u as $e } from "./loading-C6rG0eo_.js";
5
- import { FmButtonVariant as ae, useSnackbar as Pe, components as X } from "@feedmepos/ui-library";
6
- import { u as he, _ as Fe } from "./usePagination-9ioQud_y.js";
7
- import { u as be } from "./vue-i18n-C8QhQx73.js";
8
- import "./index-CXx7eJq-.js";
9
- import { i as Re, j as $, c as fe } from "./index-OpxeXVwt.js";
10
- import "./index-BLT69c7j.js";
11
- import { F as ye, z as Be } from "./index-C1qWtbsk.js";
12
- import "./index-BF8lJP43.js";
13
- import { u as ne, w as we } from "./xlsx-DwXQmhHW.js";
14
- import { e as Ne, M as Ve } from "./email-addresses-C9y4CjuV.js";
15
- import { Z as Ye } from "./zod-BbCQlI-1.js";
16
- import { u as Ue } from "./app-wDQR6dpb.js";
17
- import { R as ge } from "./rule-builder-D0vYClpg.js";
18
- import { _ as Le } from "./ZodTextField.vue_vue_type_script_setup_true_lang-Desirrtn.js";
19
- import { _ as ze } from "./RuleGroup.vue_vue_type_script_setup_true_lang-DS4VODfI.js";
20
- import { u as Oe, v as je, w as qe } from "./index.esm2017-DaR3DCu-.js";
21
- import { F as Ge } from "./FileSaver.min-BbU3im0h.js";
22
- import { h as H } from "./moment-D7p2TMB-.js";
23
- import { s as B, u as He } from "./membership-F6iQ9MVy.js";
24
- import { o as Je } from "./objectId-dwaoBfJX.js";
25
- import { u as Ce } from "./business-Cn27thty.js";
26
- import { f as Qe } from "./number-D4fGOH1o.js";
27
- import { t as We } from "./money-5QzsxME5.js";
28
- import "./index-sFHmfWSg.js";
29
- import { useRouter as Ze } from "vue-router";
30
- import { m as ve } from "./index-kSWGToWZ.js";
31
- import { R as _e } from "./app-DwodX_i8.js";
32
- const Ke = Re.extend({
33
- _id: ye.optional(),
34
- business: ye.optional(),
35
- file: Be.any().nullish()
36
- });
37
- var Xe = { firebase: { apiKey: "AIzaSyAj8JdCHtP0Vc5vZobCfgoLzWxPIn0WUG4", authDomain: "feedme-dev-4c3ef.firebaseapp.com", databaseURL: "https://feedme-dev-4c3ef.firebaseio.com", projectId: "feedme-dev-4c3ef", storageBucket: "feedme-dev-4c3ef.appspot.com", messagingSenderId: "458797803788", appId: "1:458797803788:web:37f2af2926a84288f0c129", measurementId: "G-J2QG09D2Q7" }, assetBucketUrl: "feedme-dev-4c3ef.appspot.com", importFilesBucketUrl: "feedme-dev-4c3ef.appspot.com", clientId: "1a362d621873497b277ea55258cc82594ba148d235257f7bd44ea2acc132d8a4" };
38
- const et = { class: "flex flex-col space-y-16" }, tt = {
39
- key: 0,
40
- class: /* @__PURE__ */ re([
41
- "p-16 pl-24 space-x-8",
42
- "bg-fm-color-primary-oats rounded-lg",
43
- "flex items-center",
44
- "justify-between"
45
- ])
46
- }, ot = { class: "flex justify-end" }, at = {
47
- key: 1,
48
- class: /* @__PURE__ */ re([
49
- "flex items-center",
50
- "border border-fm-color-neutral-gray-300",
51
- "p-16 space-x-16 rounded-md"
52
- ])
53
- }, nt = { class: "fm-typo-en-body-lg-400 flex-1 truncate" }, st = /* @__PURE__ */ ee({
54
- __name: "ImportSegment",
55
- props: {
56
- importFile: {}
57
- },
58
- emits: ["update:file"],
59
- setup(e, { emit: v }) {
60
- const _ = e, C = v, { t: f } = be(), p = z(null), h = z(null), F = ["Id"], n = [
61
- {
62
- label: "CSV",
63
- icon: "csv",
64
- value: "csv"
65
- },
66
- {
67
- label: "Excel",
68
- icon: "description",
69
- value: "xlsx"
70
- }
71
- ];
72
- async function i() {
73
- if (_.importFile)
74
- try {
75
- const w = Oe(void 0, Xe.importFilesBucketUrl), y = je(w, _.importFile), x = await qe(y);
76
- window.open(x, "_blank");
77
- } catch (w) {
78
- console.log(w), Ae.error("Failed to download uploaded file");
79
- }
80
- }
81
- async function c(w) {
82
- switch (w) {
83
- case "csv":
84
- const y = new Blob([F.join(",")], {
85
- type: "text/csv;charset=utf-8;"
86
- });
87
- Ge.saveAs(y, "ImportSegmentTemplate.csv");
88
- break;
89
- case "xlsx":
90
- const x = ne.aoa_to_sheet([F]), I = ne.book_new();
91
- ne.book_append_sheet(I, x, "Sheet1"), we(I, "ImportSegmentTemplate.xlsx");
92
- break;
93
- }
94
- }
95
- function b(w) {
96
- p.value = w, C("update:file", p.value);
97
- }
98
- function D(w) {
99
- var x, I;
100
- const y = ((I = (x = w.target) == null ? void 0 : x.files) == null ? void 0 : I[0]) ?? null;
101
- b(y);
102
- }
103
- return (w, y) => {
104
- const x = S("FmButton"), I = S("FmMenuItem"), u = S("FmMenu"), s = S("FmDropField");
105
- return m(), k("div", et, [
106
- y[2] || (y[2] = l("div", { class: "fm-typo-en-title-sm-800" }, "Upload File", -1)),
107
- e.importFile ? (m(), k("div", tt, [
108
- r(x, {
109
- label: t(f)("View uploaded file"),
110
- variant: t(ae).Plain,
111
- icon: "file_present",
112
- onClick: i
113
- }, null, 8, ["label", "variant"])
114
- ])) : le("", !0),
115
- l("div", null, [
116
- l("div", ot, [
117
- r(u, { class: "" }, {
118
- "menu-button": E(() => [
119
- r(x, {
120
- variant: "tertiary",
121
- icon: "download",
122
- label: "Download Template"
123
- })
124
- ]),
125
- default: E(() => [
126
- (m(), k(O, null, ie(n, (g) => r(I, {
127
- key: g.value,
128
- icon: g.icon,
129
- label: g.label,
130
- onClick: (U) => c(g.value),
131
- selectable: ""
132
- }, null, 8, ["icon", "label", "onClick"])), 64))
133
- ]),
134
- _: 1
135
- })
136
- ]),
137
- p.value ? (m(), k("div", at, [
138
- r(x, {
139
- variant: t(ae).Tertiary,
140
- "prepend-icon": "attach_file"
141
- }, null, 8, ["variant"]),
142
- l("p", nt, P(p.value.name), 1),
143
- l("label", {
144
- ref_key: "fileLabelRef",
145
- ref: h,
146
- htmlFor: "file"
147
- }, [
148
- r(x, {
149
- variant: t(ae).Plain,
150
- label: t(f)("Replace File"),
151
- onClick: y[1] || (y[1] = () => {
152
- var g;
153
- return (g = h.value) == null ? void 0 : g.click();
154
- })
155
- }, null, 8, ["variant", "label"]),
156
- l("input", {
157
- id: "file",
158
- accept: ".csv",
159
- class: "hidden",
160
- type: "file",
161
- multiple: "",
162
- onChange: D
163
- }, null, 32)
164
- ], 512)
165
- ])) : (m(), J(s, {
166
- key: 0,
167
- onFileUpload: y[0] || (y[0] = (g) => b(g)),
168
- accept: ".csv, .xlsx",
169
- "max-file-size": 2e7
170
- }))
171
- ])
172
- ]);
173
- };
174
- }
175
- }), lt = { class: "space-y-16 pr-12" }, it = { class: "fm-typo-en-title-md-800" }, rt = { class: "flex space-x-8" }, ct = { class: "fm-typo-en-title-md-800 text-fm-color-primary" }, dt = { class: "text-fm-color-typo-secondary" }, ut = /* @__PURE__ */ ee({
176
- __name: "ReviewSegment",
177
- props: {
178
- title: {},
179
- segment: {}
180
- },
181
- setup(e) {
182
- const v = e, _ = [
183
- {
184
- header: "Name",
185
- accessorFn: (i) => i.name
186
- },
187
- {
188
- header: "Id",
189
- accessorFn: (i) => i._id
190
- },
191
- {
192
- header: "Customer Since",
193
- accessorFn: (i) => H(Je(i._id.toString())).format("DD MMM YYYY")
194
- },
195
- {
196
- header: "Phone",
197
- accessorFn: (i) => i.phoneNumber
198
- },
199
- {
200
- header: "Birthday",
201
- accessorFn: (i) => H(i.birthday).format("DD MMM YYYY")
202
- },
203
- {
204
- header: "Last Visit",
205
- accessorFn: (i) => H(i.stats.lastVisit).format("DD MMM YYYY")
206
- }
207
- ];
208
- async function C(i) {
209
- return v.segment._id ? (console.log(i), await B.paginateSegmentUsers(
210
- v.segment._id,
211
- i
212
- )) : {
213
- resources: [],
214
- meta: {
215
- totalResources: 0,
216
- totalPages: 0,
217
- skip: i.skip,
218
- limit: i.limit,
219
- sortBy: i.sortBy
220
- }
221
- };
222
- }
223
- const { tableMeta: f, rowData: p, onSort: h, debouncedFetchData: F, onSearch: n } = he(C);
224
- return Se(async () => {
225
- await F();
226
- }), (i, c) => (m(), k("div", lt, [
227
- l("div", it, P(v.title), 1),
228
- l("div", rt, [
229
- l("div", ct, P(e.segment.members.length), 1),
230
- l("div", dt, [
231
- c[1] || (c[1] = l("div", null, "contacts in your segment", -1)),
232
- l("div", null, "as of " + P(t(H)(e.segment.lastUpdated).format("DD MMM YYYY")), 1)
233
- ])
234
- ]),
235
- r(Fe, {
236
- loading: t(f).isLoading,
237
- "row-data": t(p),
238
- "row-count": t(f).totalRows,
239
- "column-defs": _,
240
- "page-size": t(f).pageSize,
241
- "page-count": t(f).pageCount,
242
- "page-index": t(f).pageIndex,
243
- onSortChange: t(h),
244
- onPageChange: c[0] || (c[0] = (b) => t(F)({ pageSize: b.pageSize, pageIndex: b.pageIndex }))
245
- }, null, 8, ["loading", "row-data", "row-count", "page-size", "page-count", "page-index", "onSortChange"])
246
- ]));
247
- }
248
- }), pt = { class: "space-y-24" }, mt = { class: "grid grid-cols-2 gap-16" }, ft = { class: "fm-typo-en-title-sm-800" }, yt = { class: "fm-typo-en-body-lg-400 text-fm-color-typo-secondary" }, gt = /* @__PURE__ */ ee({
249
- __name: "SegmentTypeOption",
250
- props: {
251
- modelValue: {},
252
- errorText: {}
253
- },
254
- emits: ["update:model-value"],
255
- setup(e, { emit: v }) {
256
- const _ = e, C = v, f = [
257
- {
258
- label: "Dynamic",
259
- sublabel: "Segment statistics are based on rules configured and will be recalculated automatically when rule changes.",
260
- value: $.enum.DYNAMIC
261
- },
262
- {
263
- label: "Static",
264
- sublabel: "Segment statistics are based on imported data and will not be recalculated.",
265
- value: $.enum.STATIC
266
- }
267
- ];
268
- function p(h) {
269
- h !== _.modelValue && C("update:model-value", h);
270
- }
271
- return (h, F) => {
272
- const n = S("FmCard"), i = S("FmHelperText");
273
- return m(), k("div", pt, [
274
- l("div", mt, [
275
- (m(), k(O, null, ie(f, (c) => r(n, {
276
- variant: "outlined",
277
- class: re(["p-16 space-y-8 h-full cursor-pointer select-none xs:col-span-2", {
278
- "col-span-2": f.length == 1,
279
- "border-fm-color-primary bg-fm-color-system-warning-100 hover:border-[var(--fm-color-system-orange-300)]": e.modelValue === c.value,
280
- "hover:bg-fm-color-opacity-sm": e.modelValue !== c.value
281
- }]),
282
- onClick: (b) => p(c.value),
283
- key: c.value
284
- }, {
285
- default: E(() => [
286
- l("div", ft, P(c.label), 1),
287
- l("div", yt, P(c.sublabel), 1)
288
- ]),
289
- _: 2
290
- }, 1032, ["class", "onClick"])), 64))
291
- ]),
292
- e.errorText ? (m(), J(i, {
293
- key: 0,
294
- class: "!mt-4",
295
- text: e.errorText,
296
- state: "error"
297
- }, null, 8, ["text"])) : le("", !0)
298
- ]);
299
- };
300
- }
301
- }), vt = { class: "flex items-center gap-x-8" }, _t = {
302
- key: 0,
303
- class: "space-y-16 pr-12"
304
- }, xt = { class: "flex flex-col space-y-16" }, St = {
305
- key: 0,
306
- class: "flex flex-col space-y-16"
307
- }, ht = {
308
- key: 1,
309
- class: "flex flex-col space-y-16"
310
- }, Ft = {
311
- key: 2,
312
- class: "flex flex-col space-y-16"
313
- }, bt = { class: "flex items-center gap-8" }, wt = /* @__PURE__ */ ee({
314
- __name: "SegmentSheet",
315
- emits: ["update:model-value"],
316
- setup(e, { expose: v, emit: _ }) {
317
- const C = Ue(), f = z(!1), p = z(!1), h = {
318
- name: "",
319
- isActive: !0,
320
- type: $.enum.DYNAMIC,
321
- rule: ge.scaffoldGroup(),
322
- members: []
323
- }, F = Ke, n = z(h), i = ce(() => {
324
- const u = F.safeParse(n.value);
325
- return u.success ? [] : u.error.errors;
326
- });
327
- function c(u) {
328
- f.value = !0, p.value = !1, u ? n.value = {
329
- ...u,
330
- isActive: u.isActive !== !1,
331
- type: u.type ?? (u.importFile ? $.enum.STATIC : $.enum.DYNAMIC)
332
- } : n.value = { ...h };
333
- }
334
- function b() {
335
- f.value = !1;
336
- }
337
- async function D() {
338
- F.safeParse(n.value).success && (p.value = !0);
339
- }
340
- function w(u) {
341
- u === $.enum.STATIC ? b() : p.value = !1;
342
- }
343
- async function y() {
344
- n.value.type === $.enum.STATIC ? (n.value.rule = ge.scaffoldGroup(), n.value.isActive = !0) : n.value.file = void 0, I("update:model-value", n.value);
345
- }
346
- async function x(u) {
347
- n.value.type = u;
348
- }
349
- Se(async () => {
350
- });
351
- const I = _;
352
- return v({
353
- showSheet: c,
354
- hideSheet: b
355
- }), (u, s) => {
356
- const g = S("FmButton"), U = S("FmSwitch"), a = S("FmSideSheet");
357
- return m(), J(a, {
358
- modelValue: t(f),
359
- "onUpdate:modelValue": s[8] || (s[8] = (o) => Ie(f) ? f.value = o : null),
360
- header: "Add segment",
361
- "dismiss-away": "",
362
- "close-button": !0,
363
- "max-width": 1100
364
- }, Me({
365
- "side-sheet-footer": E(() => [
366
- l("div", bt, [
367
- t(p) || t(n).type === t($).enum.STATIC ? (m(), k(O, { key: 0 }, [
368
- r(g, {
369
- label: "Save Segment",
370
- onClick: y,
371
- loading: t(C).isLoading,
372
- disabled: t(i).length > 0 || t(C).isLoading
373
- }, null, 8, ["loading", "disabled"]),
374
- r(g, {
375
- label: "Cancel",
376
- onClick: s[6] || (s[6] = (o) => w(t(n).type)),
377
- variant: "tertiary"
378
- })
379
- ], 64)) : (m(), k(O, { key: 1 }, [
380
- r(g, {
381
- label: "Review Segment",
382
- disabled: t(i).length > 0 || t(C).isLoading,
383
- onClick: D
384
- }, null, 8, ["disabled"]),
385
- r(g, {
386
- label: "Cancel",
387
- onClick: s[7] || (s[7] = (o) => b()),
388
- variant: "tertiary"
389
- })
390
- ], 64))
391
- ])
392
- ]),
393
- default: E(() => {
394
- var o;
395
- return [
396
- t(p) ? (m(), J(ut, {
397
- key: 1,
398
- title: t(n).name,
399
- segment: t(n)
400
- }, null, 8, ["title", "segment"])) : (m(), k("div", _t, [
401
- r(Le, {
402
- modelValue: t(n).name,
403
- "onUpdate:modelValue": s[1] || (s[1] = (d) => t(n).name = d),
404
- label: "Segment title",
405
- schema: t(Ye).typeAtPath(t(F), "name")
406
- }, null, 8, ["modelValue", "schema"]),
407
- l("div", xt, [
408
- s[10] || (s[10] = l("div", { class: "fm-typo-en-title-sm-800" }, "Segment Type", -1)),
409
- r(gt, {
410
- "model-value": t(n).type,
411
- "onUpdate:modelValue": s[2] || (s[2] = (d) => {
412
- x(d);
413
- })
414
- }, null, 8, ["model-value"])
415
- ]),
416
- t(n).type === t($).enum.DYNAMIC ? (m(), k("div", St, [
417
- s[11] || (s[11] = l("div", { class: "fm-typo-en-title-sm-800" }, "Segment Filter", -1)),
418
- r(ze, {
419
- "trigger-type": "MEMBERSHIP_JOINED",
420
- includeOnly: "user",
421
- "model-value": (o = t(n)) == null ? void 0 : o.rule,
422
- "onUpdate:modelValue": s[3] || (s[3] = (d) => {
423
- t(n).rule = d;
424
- })
425
- }, null, 8, ["model-value"])
426
- ])) : (m(), k("div", ht, [
427
- r(st, {
428
- importFile: t(n).importFile,
429
- "onUpdate:file": s[4] || (s[4] = (d) => {
430
- t(n).file = d;
431
- })
432
- }, null, 8, ["importFile"])
433
- ])),
434
- t(n).type === t($).enum.DYNAMIC ? (m(), k("div", Ft, [
435
- s[12] || (s[12] = l("div", { class: "fm-typo-en-title-sm-800" }, "Segment Status", -1)),
436
- r(U, {
437
- "model-value": t(n).isActive ?? !0,
438
- "onUpdate:modelValue": s[5] || (s[5] = (d) => t(n).isActive = d),
439
- label: "Active",
440
- sublabel: "When enabled, this will recalculate the segment statistics daily.",
441
- "label-placement": "right"
442
- }, null, 8, ["model-value"])
443
- ])) : le("", !0)
444
- ]))
445
- ];
446
- }),
447
- _: 2
448
- }, [
449
- t(p) ? {
450
- name: "side-sheet-header",
451
- fn: E(() => [
452
- l("div", vt, [
453
- r(g, {
454
- icon: "arrow_back",
455
- variant: "tertiary",
456
- onClick: s[0] || (s[0] = (o) => p.value = !1)
457
- }),
458
- s[9] || (s[9] = l("div", null, "Review segment", -1))
459
- ])
460
- ]),
461
- key: "0"
462
- } : void 0
463
- ]), 1032, ["modelValue"]);
464
- };
465
- }
466
- }), xe = He(), Ct = Ce();
467
- function se(e) {
468
- const v = H(e);
469
- return v.isValid() ? v.format("DD/MM/YYYY") : "";
470
- }
471
- const kt = {
472
- mapMemberExportRow: (e) => {
473
- var i, c, b, D, w, y, x, I, u, s, g, U, a, o, d, R, A, N, V, j, q, G, te, M, Q, de, ue, pe;
474
- const v = ce(() => Ct.locations.map((T) => ({
475
- label: T.name,
476
- value: T._id
477
- }))), _ = (i = Ne.parseOneAddress(
478
- e == null ? void 0 : e.email
479
- )) != null && i.domain.includes("feedmepos.com") ? void 0 : e.email, C = (b = ((c = e == null ? void 0 : e.collection) == null ? void 0 : c.TITLE) || []) == null ? void 0 : b.reduce(
480
- (T, L) => {
481
- var Z, K;
482
- const W = (K = (Z = xe.sortedTitles) == null ? void 0 : Z.find(
483
- (oe) => oe._id === L.collectible
484
- )) == null ? void 0 : K.name;
485
- return !W || L.balance <= 0 || T.push(W), T;
486
- },
487
- []
488
- ), f = (xe.sortedTitles || []).reduce(
489
- (T, L) => {
490
- var Z, K, oe, me;
491
- const W = (me = (oe = (K = (((Z = e == null ? void 0 : e.collection) == null ? void 0 : Z.TITLE) || []).find(
492
- (ke) => ke.collectible === L._id
493
- )) == null ? void 0 : K.expiryBalance) == null ? void 0 : oe[0]) == null ? void 0 : me.expiredAt;
494
- return T[L.name] = W ? H(W).format("DD/MM/YYYY") : "", T;
495
- },
496
- {}
497
- ), p = ((y = (w = (D = e.collection) == null ? void 0 : D.CREDIT) == null ? void 0 : w.at(0)) == null ? void 0 : y.balance) || 0, h = ((s = (u = (I = (x = e.collection) == null ? void 0 : x.CREDIT) == null ? void 0 : I.at(0)) == null ? void 0 : u.expiryBalance) == null ? void 0 : s.reduce(
498
- (T, L) => T + L.amount,
499
- 0
500
- )) || 0, F = Qe(p, 2);
501
- return {
502
- ID: e._id.toString(),
503
- Name: ((g = e.name) == null ? void 0 : g.trim()) || "",
504
- Phone: ((U = e == null ? void 0 : e.phoneNumber) == null ? void 0 : U.trim()) || "",
505
- Email: _ || "",
506
- Gender: e.gender || "",
507
- CardNo: e.cardNo || "",
508
- Birthday: e != null && e.birthday ? se(e == null ? void 0 : e.birthday) : "",
509
- Credit: parseFloat((Number(F) - Number(h)).toFixed(2)),
510
- FreeCredit: Number(h.toFixed(2)),
511
- TotalCredit: Number(F),
512
- Exp: e != null && e.collection ? ((d = (o = (a = e.collection) == null ? void 0 : a.POINT) == null ? void 0 : o.at(0)) == null ? void 0 : d.balance) ?? 0 : 0,
513
- Point: e != null && e.collection ? ((N = (A = (R = e.collection) == null ? void 0 : R.COIN) == null ? void 0 : A.at(0)) == null ? void 0 : N.balance) ?? 0 : 0,
514
- Level: e != null && e.collection ? ((q = (j = (V = e.collection) == null ? void 0 : V.TIER) == null ? void 0 : j.at(0)) == null ? void 0 : q.balance) ?? 0 : 0,
515
- Tier: e != null && e.collection ? ((M = (te = (G = e.collection) == null ? void 0 : G.TIER) == null ? void 0 : te.at(0)) == null ? void 0 : M.balance) ?? 0 : 0,
516
- Titles: C.join(","),
517
- ...f,
518
- TotalTransaction: e.stats.visitCount,
519
- AvgSpent: We(Number(e.stats.avgBillSize || 0)).toFormat(
520
- !1
521
- ),
522
- TotalSpent: e.stats.avgBillSize * e.stats.visitCount,
523
- LastVisit: se(e.stats.lastVisit),
524
- Feedback: ((Q = e.stats) == null ? void 0 : Q.feedbackCount) || 0,
525
- LastSeasonTierEarned: ((de = e.stats) == null ? void 0 : de.lastSeasonTierEarned) || 0,
526
- LastSeasonPointEarned: ((ue = e.stats) == null ? void 0 : ue.lastSeasonPointEarned) || 0,
527
- JoinedAt: se(e.joinAt || void 0),
528
- JoinedAtLocation: e.location && ((pe = v.value.find((T) => T.value == e.location)) == null ? void 0 : pe.label) || "-",
529
- VisitFrequency: `${Number(
530
- Math.ceil(e.stats.avgVisitFrequency).toFixed(0)
531
- )}`
532
- };
533
- }
534
- }, It = { class: "flex items-center" }, Mt = { class: "fm-typo-en-title-md-600 fm-step-title line-clamp-2 mr-8" }, Tt = { class: "px-24 flex flex-col gap-y-16" }, Et = { class: "fm-typo-en-body-md-600 text-fm-color-typo-secondary" }, At = { class: "fm-typo-en-body-md-600" }, Dt = { class: "fm-typo-en-body-md-600 text-fm-color-typo-secondary" }, uo = /* @__PURE__ */ ee({
535
- __name: "Segment",
536
- setup(e) {
537
- const { minor: v } = $e, { t: _ } = be(), C = Ce(), { mapMemberExportRow: f } = kt, p = Pe(), h = Ze(), F = z(0), n = [
538
- {
539
- header: _("connect.loyalty.segment.table.name"),
540
- accessorFn: (a) => a.name
541
- },
542
- {
543
- header: _("connect.loyalty.segment.table.status"),
544
- enableSorting: !1,
545
- cell(a) {
546
- const o = a.row.original.isActive === !1 ? "Inactive" : "Active";
547
- return Y(X.FmChip, {
548
- class: a.row.original.isActive === !1 ? "text-fm-color-typo-error bg-fm-color-system-error-100" : "text-fm-color-typo-success bg-fm-color-system-success-100",
549
- label: o,
550
- compact: !0
551
- });
552
- }
553
- },
554
- {
555
- header: _("connect.loyalty.segment.table.total_customers"),
556
- accessorFn: (a) => a.memberCount ?? 0
557
- },
558
- {
559
- header: _("connect.loyalty.segment.table.customer_percentage"),
560
- accessorFn: (a) => ((a.memberCount ?? 0) * 100 / F.value).toFixed(2)
561
- },
562
- {
563
- header: _("connect.loyalty.segment.table.actions"),
564
- meta: {
565
- maxWidth: "100px"
566
- },
567
- cell(a) {
568
- return Y("div", { class: "flex items-center justify-end" }, [
569
- Y(
570
- X.FmMenu,
571
- {
572
- placement: "bottom-end",
573
- onClick: (o) => {
574
- o.stopPropagation();
575
- }
576
- },
577
- {
578
- "menu-button": () => Y(X.FmButton, {
579
- icon: "more_vert",
580
- iconColor: "neutral-gray-400",
581
- variant: "tertiary"
582
- }),
583
- default: () => [
584
- Y(
585
- X.FmMenuItem,
586
- {
587
- onClick: async (o) => {
588
- o.stopPropagation(), x(a.row.original);
589
- }
590
- },
591
- {
592
- label: Y(
593
- "div",
594
- {
595
- class: "fm-typo-en-body-md-400"
596
- },
597
- "Export"
598
- )
599
- }
600
- ),
601
- Y(
602
- X.FmMenuItem,
603
- {
604
- onClick: async (o) => {
605
- o.stopPropagation(), y(a.row.original);
606
- }
607
- },
608
- {
609
- label: Y(
610
- "div",
611
- {
612
- class: "text-fm-color-typo-error fm-typo-en-body-md-400"
613
- },
614
- "Remove"
615
- )
616
- }
617
- )
618
- ]
619
- }
620
- )
621
- ]);
622
- }
623
- }
624
- ], i = z(null), { tableMeta: c, rowData: b, debouncedFetchData: D } = he(
625
- B.readAll
626
- );
627
- async function w() {
628
- var a;
629
- try {
630
- await B.refreshSegments(), p.open({ type: "info", title: "Segment refresh queued" });
631
- } catch (o) {
632
- if (((o == null ? void 0 : o.status) ?? ((a = o == null ? void 0 : o.response) == null ? void 0 : a.status)) === 409) {
633
- p.open({
634
- type: "info",
635
- title: "Segment refresh already in progress"
636
- });
637
- return;
638
- }
639
- p.open({
640
- type: "error",
641
- title: (o == null ? void 0 : o.message) ?? "Failed to queue segment refresh"
642
- });
643
- }
644
- }
645
- async function y(a) {
646
- await De.remove(`Are you sure you want to remove ${a.name}?`) && await v(
647
- async () => {
648
- await B.delete(a._id), await D({ pageSize: 10, pageIndex: 0 });
649
- },
650
- {
651
- message: `Removing ${a.name}`,
652
- successMessage: `Removed ${a.name} successfully`
653
- }
654
- );
655
- }
656
- async function x(a) {
657
- const o = {
658
- sortBy: "_id",
659
- descending: !1,
660
- rowsPerPage: 1e3,
661
- page: 1,
662
- rowsNumber: 0
663
- }, d = new Ve(), R = (await ve.read({
664
- limit: 1,
665
- skip: 0,
666
- sortBy: o.sortBy,
667
- descending: o.descending
668
- })).meta.totalResources ?? 0, A = o.rowsPerPage;
669
- await v(
670
- async () => {
671
- for (let N = 0; N < R; N += A) {
672
- const V = {
673
- ...o,
674
- limit: A,
675
- skip: o.page - 1,
676
- sortBy: o.sortBy,
677
- descending: o.descending
678
- }, j = await B.paginateSegmentUsers(
679
- a._id,
680
- V
681
- );
682
- for (const q of j.resources) {
683
- const G = f(q);
684
- d.addRecord(G);
685
- }
686
- o.page++;
687
- }
688
- await we(
689
- d.buildExcel(),
690
- `[${a.name}]-members-${(/* @__PURE__ */ new Date()).toISOString()}.xlsx`,
691
- {
692
- bookType: "xlsx",
693
- bookSST: !1,
694
- type: "array"
695
- }
696
- ), o.page = 1;
697
- },
698
- {
699
- message: "Exporting member...",
700
- successMessage: "Member exported successfully"
701
- }
702
- );
703
- }
704
- async function I(a) {
705
- await v(
706
- async () => {
707
- var o;
708
- if (a.type === $.enum.STATIC) {
709
- const d = new FormData();
710
- if (d.append("file", a.file), a._id) {
711
- const { members: R, _id: A, file: N, ...V } = a;
712
- d.append("segment", JSON.stringify(V)), await B.updateStatic(a._id, d);
713
- } else {
714
- const { file: R, ...A } = a;
715
- d.append("segment", JSON.stringify(A)), await B.createStatic(d);
716
- }
717
- a.file && p.open({
718
- type: "info",
719
- title: "Import begins soon. Check Queue for updates.",
720
- action: "View",
721
- onAction: async () => {
722
- await h.push({
723
- name: _e["$connect-QUEUE"],
724
- query: { type: [fe.enum.SEGMENTATION_IMPORTED] }
725
- });
726
- }
727
- });
728
- } else if (a._id) {
729
- const { members: d, _id: R, ...A } = a;
730
- await B.update(a._id, A);
731
- } else
732
- await B.create(a);
733
- await D({ pageSize: 10, pageIndex: 0 }), (o = i.value) == null || o.hideSheet();
734
- },
735
- {
736
- message: "Saving segment",
737
- successMessage: "Segment saved"
738
- }
739
- );
740
- }
741
- function u(a) {
742
- var o;
743
- (o = i.value) == null || o.showSheet(a);
744
- }
745
- const s = {
746
- label: _("connect.navigation.queue"),
747
- value: "queue",
748
- isPrimary: !1,
749
- prependIcon: "work_history"
750
- }, g = ce(() => C.isPremium ? [
751
- s,
752
- {
753
- label: "Refresh segments",
754
- value: "refresh",
755
- prependIcon: "refresh"
756
- },
757
- {
758
- label: "Add segment",
759
- value: "add",
760
- isPrimary: !0,
761
- prependIcon: "add"
762
- }
763
- ] : []);
764
- function U(a) {
765
- switch (a) {
766
- case "add":
767
- u();
768
- break;
769
- case "refresh":
770
- w();
771
- break;
772
- case "queue":
773
- h.push({
774
- name: _e["$connect-QUEUE"],
775
- query: { type: [fe.enum.SEGMENTATION_IMPORTED] }
776
- });
777
- break;
778
- }
779
- }
780
- return Te(async () => {
781
- const { meta: a } = await ve.read({
782
- limit: 1,
783
- skip: 0,
784
- sortBy: "_id",
785
- search: void 0,
786
- descending: !1
787
- });
788
- F.value = a.totalResources ?? 0, await D({ pageSize: 10, pageIndex: 0 }), await C.readPremium(), await C.readLocations();
789
- }), (a, o) => {
790
- const d = S("FmPill"), R = S("FmPageHead"), A = S("FmIcon"), N = S("FmMenuItem"), V = S("FmMenu"), j = S("FmListItem"), q = S("FmList"), G = S("FmButton"), te = S("FmCard");
791
- return m(), k(O, null, [
792
- r(R, {
793
- title: "Segments",
794
- actions: t(g),
795
- "onClick:action": o[0] || (o[0] = (M) => U(M))
796
- }, {
797
- title: E(() => [
798
- l("div", It, [
799
- l("span", Mt, P(t(_)("connect.loyalty.segment.title")), 1),
800
- r(d, { variant: "premium" })
801
- ])
802
- ]),
803
- _: 1
804
- }, 8, ["actions"]),
805
- l("div", Tt, [
806
- t(b).length > 0 || t(c).searchValue || t(c).isLoading ? (m(), k(O, { key: 0 }, [
807
- r(Fe, {
808
- loading: t(c).isLoading,
809
- "row-data": t(b),
810
- "row-count": t(c).totalRows,
811
- "column-defs": n,
812
- "shrink-at": !1,
813
- "page-count": t(c).pageCount,
814
- "page-index": t(c).pageIndex,
815
- "page-size": t(c).pageSize,
816
- onRowClick: o[1] || (o[1] = (M) => {
817
- u(M.original);
818
- }),
819
- onPageChange: t(D)
820
- }, null, 8, ["loading", "row-data", "row-count", "page-count", "page-index", "page-size", "onPageChange"]),
821
- r(q, { class: "w-full hidden xs:!block" }, {
822
- default: E(() => [
823
- (m(!0), k(O, null, ie(t(b), (M) => (m(), J(j, {
824
- key: M._id.toString(),
825
- tag: "label",
826
- onClick: (Q) => u(M)
827
- }, {
828
- default: E(() => [
829
- l("div", null, [
830
- l("div", Et, P((M.memberCount ?? 0).toLocaleString()) + " total customers ", 1),
831
- l("div", At, P(M.name), 1),
832
- l("div", Dt, P(((M.memberCount ?? 0) * 100 / t(F)).toFixed(2)) + "% of customers ", 1)
833
- ])
834
- ]),
835
- append: E(() => [
836
- r(V, { "stop-click-propagation": !0 }, {
837
- "menu-button": E(() => [
838
- r(A, { name: "more_vert" })
839
- ]),
840
- default: E(() => [
841
- r(N, {
842
- class: "text-fm-color-typo-error fm-typo-en-body-md-400",
843
- label: "Remove",
844
- "onUpdate:modelValue": (Q) => Q && y(M)
845
- }, null, 8, ["onUpdate:modelValue"])
846
- ]),
847
- _: 2
848
- }, 1024)
849
- ]),
850
- _: 2
851
- }, 1032, ["onClick"]))), 128))
852
- ]),
853
- _: 1
854
- })
855
- ], 64)) : (m(), J(te, {
856
- key: 1,
857
- variant: "outlined",
858
- class: "w-full flex flex-col items-center justify-center gap-y-24 p-24"
859
- }, {
860
- default: E(() => [
861
- o[3] || (o[3] = l("img", {
862
- src: Ee,
863
- class: "aspect-square w-[150px]"
864
- }, null, -1)),
865
- o[4] || (o[4] = l("div", { class: "flex flex-col gap-16 text-center" }, [
866
- l("div", { class: "fm-typo-en-title-sm-800" }, "Create customer segments"),
867
- l("div", { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, " Segments allow you to categorize your customers based on various criteria, enabling targeted marketing and personalized experiences. ")
868
- ], -1)),
869
- r(G, {
870
- variant: "primary",
871
- label: "Create segment",
872
- disabled: !t(C).isPremium,
873
- icon: "add",
874
- onClick: o[2] || (o[2] = (M) => u())
875
- }, null, 8, ["disabled"])
876
- ]),
877
- _: 1
878
- })),
879
- r(wt, {
880
- ref_key: "sheetRef",
881
- ref: i,
882
- "onUpdate:modelValue": I
883
- }, null, 512)
884
- ])
885
- ], 64);
886
- };
887
- }
888
- });
889
- export {
890
- uo as default
891
- };