@feedmepos/mf-connect 0.1.114-prod → 0.1.115-dev
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.
- package/README.md +66 -1
- package/dist/{App-DMYXrCc7.js → App-43mZfFAr.js} +700 -654
- package/dist/AuditLogs-BPpdm96t.js +2016 -0
- package/dist/{Bin-CHZolo56.js → Bin-CA7v180Y.js} +8 -8
- package/dist/Broadcast-qmdifF2Y.js +306 -0
- package/dist/{CampaignAnalytic-DgZvsUoF.js → CampaignAnalytic-xnrDxqaH.js} +7 -7
- package/dist/{CampaignTypeDialog.vue_vue_type_script_setup_true_lang-C42uL_JO.js → CampaignTypeDialog.vue_vue_type_script_setup_true_lang-zjk-QdtX.js} +9 -9
- package/dist/{Card-wRFTJwJ9.js → Card-D8icsk7L.js} +25 -24
- package/dist/{Collections-9G-_9Etz.js → Collections--THcD-E_.js} +197 -185
- package/dist/{Credit-Bl7IDMCU.js → Credit-JrbtVMBp.js} +21 -20
- package/dist/{DateRangeChip.vue_vue_type_script_setup_true_lang-BVLJeofG.js → DateRangeChip.vue_vue_type_script_setup_true_lang-DrwKtnE5.js} +1 -1
- package/dist/EditCampaignSheet.vue_vue_type_script_setup_true_lang-DgdAlHU7.js +4442 -0
- package/dist/{EffectSheet.vue_vue_type_style_index_0_lang-Q1f6EQW3.js → EffectSheet.vue_vue_type_style_index_0_lang-hVgqWdD0.js} +32 -32
- package/dist/{Experience-Cs2iViLv.js → Experience-CFeRqBoj.js} +32 -31
- package/dist/{FileSaver.min-B3Levdbu.js → FileSaver.min-CCXIBm58.js} +1 -1
- package/dist/{Game-oXURgzan.js → Game-CPxq6Ex3.js} +19 -18
- package/dist/{GiftCardSetup-C2Wu-dRl.js → GiftCardSetup-D0esVZDp.js} +75 -75
- package/dist/{GoalPickerPanel.vue_vue_type_script_setup_true_lang-Da2e89Um.js → GoalPickerPanel.vue_vue_type_script_setup_true_lang-CJ1-vL-K.js} +7 -7
- package/dist/{Goals-B_xEM7gf.js → Goals-DaKI6uXt.js} +4 -4
- package/dist/Grab-BWzdN_cd.js +301 -0
- package/dist/{ImageInput.vue_vue_type_script_setup_true_lang-BRJR1heE.js → ImageInput.vue_vue_type_script_setup_true_lang-BOnL0GxM.js} +1 -1
- package/dist/{Index-kuT6W6R_.js → Index-2kENoaZm.js} +10 -10
- package/dist/{LocationPicker.vue_vue_type_script_setup_true_lang-7JqHfSk-.js → LocationPicker.vue_vue_type_script_setup_true_lang-BtWnJKU_.js} +1 -1
- package/dist/{LottieAnimation.vue_vue_type_script_setup_true_lang-CI_4S7tW.js → LottieAnimation.vue_vue_type_script_setup_true_lang-CX_Sspu5.js} +1 -1
- package/dist/{LoyaltyDashboard-CqxHdZcm.js → LoyaltyDashboard-CB93Fz8u.js} +15 -15
- package/dist/MainLayout-DwnjGXh6.js +4 -0
- package/dist/{MainLayout-CAERFIms.js → MainLayout.vue_vue_type_script_setup_true_lang-Du8fw5v_.js} +5 -4
- package/dist/Marketing-DCco__2F.js +273 -0
- package/dist/MarketingMaterialEdit-BbgFtrYP.js +1037 -0
- package/dist/{Member-B8VZEn9t.js → Member-B--nYyr0.js} +7 -7
- package/dist/{MemberDetailSheet.vue_vue_type_script_setup_true_lang-B31lVLKh.js → MemberDetailSheet.vue_vue_type_script_setup_true_lang-BBlzO7Db.js} +43 -50
- package/dist/{MemberImportHistory-D9tgHnTS.js → MemberImportHistory-D52Y4RTC.js} +7 -7
- package/dist/{MemberList-Hw_xQY1i.js → MemberList-13Owa1fj.js} +103 -105
- package/dist/{MemberTransactions-DiBO4plw.js → MemberTransactions-CpXEWNbq.js} +1 -1
- package/dist/{MessageInput.vue_vue_type_script_setup_true_lang-CbFt5X89.js → MessageInput.vue_vue_type_script_setup_true_lang-DlELjFM0.js} +4228 -4176
- package/dist/{MetricInfoTooltip.vue_vue_type_script_setup_true_lang-BE_-Ed4z.js → MetricInfoTooltip.vue_vue_type_script_setup_true_lang-C_y0rM8c.js} +1 -1
- package/dist/{Mission-DpYei3aF.js → Mission-Ci-UzXSu.js} +22 -21
- package/dist/{Overview-CARquJCS.js → Overview-CKxSfAGF.js} +145 -144
- package/dist/{Overview-BFQMmyT6.js → Overview-CXen9Ram.js} +23 -22
- package/dist/{Point-Dd2ykwNv.js → Point-CR3YOaag.js} +22 -21
- package/dist/{Promotion-DXl-W7np.js → Promotion-tw3J4ul-.js} +137 -131
- package/dist/{Queue-Cd3N-4iB.js → Queue-BZGA5ZXt.js} +47 -46
- package/dist/{Record-C3HdDsh5.js → Record-BTevVXnT.js} +9 -9
- package/dist/{Review-Bif3Ub9Z.js → Review-BU7c8ZF0.js} +2 -2
- package/dist/ReviewFacebookCallback-BnMF6Arh.js +225 -0
- package/dist/{ReviewGoogleCallback-i-RNLlLm.js → ReviewGoogleCallback-xpdPHSdg.js} +5 -5
- package/dist/{Reward-DHxzrR_7.js → Reward-jlA_7cxz.js} +29 -29
- package/dist/{RewardGroup.vue_vue_type_script_setup_true_lang-DcrFlcSo.js → RewardGroup.vue_vue_type_script_setup_true_lang-D3z_n42G.js} +16 -15
- package/dist/RuleGroup.vue_vue_type_script_setup_true_lang-CsHxqH9h.js +1923 -0
- package/dist/{Segment-Cjpxordk.js → Segment-C1Bwm--Q.js} +290 -291
- package/dist/{SendCollectionSheet.vue_vue_type_script_setup_true_lang-6u21xBu6.js → SendCollectionSheet.vue_vue_type_script_setup_true_lang-B6apgWTM.js} +31 -30
- package/dist/{SendVoucherSheet.vue_vue_type_script_setup_true_lang-BOXVzfer.js → SendVoucherSheet.vue_vue_type_script_setup_true_lang-B7m2F9UV.js} +4 -4
- package/dist/Setting-CDM4RhLW.js +574 -0
- package/dist/{SettingAdvertisements-aog5fz32.js → SettingAdvertisements-4XEAJzlL.js} +12 -12
- package/dist/Settings-D-0tvZRr.js +286 -0
- package/dist/{Store-Bq3kw1l2.js → Store-C56dXtc4.js} +31 -30
- package/dist/{StoreRewards-ZGXKEM09.js → StoreRewards-DQ1Q6WS6.js} +15 -15
- package/dist/StoreTransactions.vue_vue_type_script_setup_true_lang-LLD91Rz6.js +1319 -0
- package/dist/TargetLocationInput.vue_vue_type_script_setup_true_lang-Bvy4NJMd.js +7007 -0
- package/dist/{Tier-CfgpEHY7.js → Tier-D4CPZqw7.js} +2576 -687
- package/dist/{Title-B2itYWeD.js → Title-DCbwhUic.js} +94 -92
- package/dist/{Transaction-hJ5ygIcf.js → Transaction-C5LrasXr.js} +2 -2
- package/dist/{UserRuleGroup.vue_vue_type_script_setup_true_lang-8BgGlpTh.js → UserRuleGroup.vue_vue_type_script_setup_true_lang-Cl9b4mrK.js} +26 -26
- package/dist/{Voucher-TG47pGR3.js → Voucher-rrVbNZKR.js} +19 -19
- package/dist/{VoucherEditor.vue_vue_type_script_setup_true_lang-CjuXCTxg.js → VoucherEditor.vue_vue_type_script_setup_true_lang-BIq227nz.js} +16 -16
- package/dist/WhatsappAccount-oJDo5zTr.js +159 -0
- package/dist/WhatsappAccountStatusLabel.vue_vue_type_script_setup_true_lang-aCQCYFYq.js +39 -0
- package/dist/WhatsappBot-Cl64wG_F.js +876 -0
- package/dist/WhatsappBotLogs-D3uT4EiB.js +372 -0
- package/dist/WhatsappBotSettings-Cs1lLxh-.js +705 -0
- package/dist/WhatsappLayout-C639d2HP.js +21 -0
- package/dist/WhatsappNotificationGroupDialog.vue_vue_type_script_setup_true_lang-DpPxWp2x.js +253 -0
- package/dist/{ZodTextField.vue_vue_type_script_setup_true_lang-BRs-gbP0.js → ZodTextField.vue_vue_type_script_setup_true_lang-C39_95SZ.js} +2 -2
- package/dist/{app-tPHYkJcQ.js → app-CgimGODl.js} +10610 -8223
- package/dist/app.js +4 -3
- package/dist/{base.export-BHDVnGj2.js → base.export-D2P6HFvo.js} +2 -2
- package/dist/browser-BSAOEeIM.js +1478 -0
- package/dist/{business-HLyWfrXY.js → business-Bu5TqSA0.js} +1 -1
- package/dist/campaign-BFIXSgdJ.js +400 -0
- package/dist/{campaign-5zFgUNLw.js → campaign-zJxttSIk.js} +31 -25
- package/dist/{campaign.enum-BOkDnP2g.js → campaign.enum-Dx-Zo68Q.js} +3 -2
- package/dist/{campaign.fn-BIAoVtJj.js → campaign.fn-gvjlcEfe.js} +78 -78
- package/dist/{collectible.enum-BbZSAfys.js → collectible.enum-Liy2wH3s.js} +1 -1
- package/dist/{collection.fn-DPSgBHnz.js → collection.fn-DOm0HsSh.js} +2 -2
- package/dist/{currency-BVrMqU6-.js → currency-BpbQvbm8.js} +1 -1
- package/dist/duplicateCampaign-CvsvjRE9.js +51 -0
- package/dist/{effect-BBifVx76.js → effect-D-GtNB3n.js} +1 -1
- package/dist/{email-addresses-9C7xHTNv.js → email-addresses-BKMoAtMi.js} +2 -2
- package/dist/feature-flag-BJ_eyKsq.js +868 -0
- package/dist/feature-flag-Bo-k5sIG.js +50 -0
- package/dist/google-BQK68wbe.js +5 -0
- package/dist/{helper-C08jyQNK.js → helper-CkfjBgMM.js} +1 -1
- package/dist/{index-Dhyqf1s8.js → index-B6kU3PkV.js} +2700 -2613
- package/dist/{index-BgwZGunW.js → index-BAtUrtqM.js} +19 -6
- package/dist/index-BKsxIwbi.js +14571 -0
- package/dist/{index-DZ-q5O-V.js → index-BdEXUNoG.js} +4 -4
- package/dist/{index-hIUtD2eY.js → index-Bhl5IRXy.js} +11 -10
- package/dist/{index-kCbkOivd.js → index-BpTIulTX.js} +1 -1
- package/dist/index-C-iwb2Ln.js +109 -0
- package/dist/{index-Ciw2TZxV.js → index-CCEXSPxk.js} +8 -7
- package/dist/{index-CUle4c2B.js → index-CIej31pF.js} +4 -3
- package/dist/{index-ihw-WFCa.js → index-CQ8XFbBk.js} +2 -2
- package/dist/index-C_H8jFYf.js +2743 -0
- package/dist/{index-CEe1kJ0T.js → index-CfQuYqXn.js} +1 -1
- package/dist/{index-C_WoO58V.js → index-CuREApMc.js} +8 -7
- package/dist/{index-NJSI4wX4.js → index-D0JK99Ko.js} +693 -231
- package/dist/{index-DnRMNmUA.js → index-DKxN1mMS.js} +396 -232
- package/dist/index-DQ8JJhxs.js +74 -0
- package/dist/{index-D24Q28cH.js → index-DUAZOMVJ.js} +1 -1
- package/dist/{index-Yo0tP8KJ.js → index-DqGs6RJG.js} +683 -581
- package/dist/{index-B_334Y_i.js → index-DwU3fsLW.js} +29 -15
- package/dist/{index-hSRM1smQ.js → index-LygS9WsG.js} +8028 -10767
- package/dist/{index-96ZiAKj_.js → index-feCrYhi6.js} +1 -1
- package/dist/{index-Dk-jg0wN.js → index-zTvr2GR4.js} +2 -2
- package/dist/{index.esm2017-hN99SQTb.js → index.esm2017-DZi9IQPS.js} +209 -209
- package/dist/{loading-CVuY4vQ4.js → loading-Brid2wnu.js} +1 -1
- package/dist/{lodash-GFl9_FMH.js → lodash-C1epw3Kv.js} +1 -1
- package/dist/{member-import-CshTzabx.js → member-import-DAIxTIiu.js} +6 -5
- package/dist/{membership-S0KES3Ex.js → membership-BZmljFhF.js} +3 -3
- package/dist/{money-JxdX8ru4.js → money-cLcyGcSZ.js} +1 -1
- package/dist/{number-BRLwa-mB.js → number-C2jPLJr2.js} +1 -1
- package/dist/objectid-C-wocWKI.js +145 -0
- package/dist/{onboarding-BSKYeyP7.js → onboarding-oRfy_g05.js} +25 -25
- package/dist/{onboardingSetup-BqT52VRm.js → onboardingSetup-BLD6m8HY.js} +2 -2
- package/dist/{plugins-BR_wmMFJ.js → plugins-CUsr9vB0.js} +3 -3
- package/dist/{MarketingMaterialEdit-BvIthCHG.js → remy-icon-BhUGu2NI.js} +2 -1031
- package/dist/{reward-CpCGg_W2.js → reward-UOT03odb.js} +1 -1
- package/dist/{rule-Dbg9e8MO.js → rule-BgJnPjkI.js} +572 -492
- package/dist/style.css +1 -1
- package/dist/template-BZyFhr73.js +188 -0
- package/dist/{timezone-CDVa-xPr.js → timezone-BXA4wq7Y.js} +1 -1
- package/dist/{transaction.fn-DrTBoF9T.js → transaction.fn-CQ4fpRt3.js} +2 -2
- package/dist/{trigger-wqGwQfB2.js → trigger-DXJCGT0q.js} +8 -8
- package/dist/useMarketingMaterialActions-B-Wib5ga.js +125 -0
- package/dist/{usePagination-fODgpZZ8.js → usePagination-Pp4okWr8.js} +1 -1
- package/dist/{user-DaLUK1dk.js → user-B3gXcAIy.js} +1 -1
- package/dist/vue-i18n-DWGiC_vs.js +2365 -0
- package/dist/{xlsx-Bl4_Dtrq.js → xlsx-CCaDUTgW.js} +651 -651
- package/dist/{zod-CAzWyVqj.js → zod-CPwjOxvW.js} +1 -1
- package/package.json +12 -3
- package/dist/Broadcast-ByWvxVhW.js +0 -271
- package/dist/EditCampaignSheet.vue_vue_type_script_setup_true_lang-DGpQfV5T.js +0 -2431
- package/dist/Marketing-KgcwGErU.js +0 -236
- package/dist/ReviewFacebookCallback-mJF54-9l.js +0 -238
- package/dist/RuleGroup.vue_vue_type_script_setup_true_lang-39f3I4BB.js +0 -1883
- package/dist/Setting-Dl9MelHz.js +0 -2036
- package/dist/Settings-DvCCClIP.js +0 -179
- package/dist/StoreTransactions.vue_vue_type_script_setup_true_lang-DscLAF0p.js +0 -1264
- package/dist/TargetLocationInput.vue_vue_type_script_setup_true_lang-l_v4FHO0.js +0 -142
- package/dist/campaign-awCRccgX.js +0 -228
- package/dist/google-C3S8u0mT.js +0 -4
- package/dist/index-CoNJdOx7.js +0 -51
- package/dist/objectid-CEHN25HN.js +0 -145
- package/dist/rule-builder-BEIjxsE0.js +0 -102
- package/dist/template-CS-lExgI.js +0 -236
- package/dist/useMarketingMaterialActions-DC0gIyIZ.js +0 -96
- package/dist/vue-i18n-Dx-KXojZ.js +0 -2365
|
@@ -0,0 +1,273 @@
|
|
|
1
|
+
import { defineComponent as M, resolveComponent as p, openBlock as d, createBlock as N, unref as c, ref as _, watch as L, createElementBlock as f, createVNode as l, withCtx as k, createElementVNode as r, toDisplayString as w, withModifiers as P, createStaticVNode as H, computed as V, onMounted as j, nextTick as z, onUnmounted as G, Fragment as $, renderList as B, createCommentVNode as q } from "vue";
|
|
2
|
+
import { _ as K } from "./campaign-CpzFl8Vr.js";
|
|
3
|
+
import { u as b } from "./vue-i18n-DWGiC_vs.js";
|
|
4
|
+
import { u as Z, m as J } from "./useMarketingMaterialActions-B-Wib5ga.js";
|
|
5
|
+
import { u as O } from "./remy-Qz_pNsUS.js";
|
|
6
|
+
import { useRouter as Q } from "vue-router";
|
|
7
|
+
import "./index-feCrYhi6.js";
|
|
8
|
+
import { R as W } from "./app-CgimGODl.js";
|
|
9
|
+
const X = /* @__PURE__ */ M({
|
|
10
|
+
__name: "GenerateMaterialButton",
|
|
11
|
+
setup(u) {
|
|
12
|
+
const { t: m } = b(), i = O();
|
|
13
|
+
function a() {
|
|
14
|
+
i.activate({
|
|
15
|
+
command: "generateMarketingMaterial",
|
|
16
|
+
fullscreen: !0,
|
|
17
|
+
forceNewConversation: !0
|
|
18
|
+
});
|
|
19
|
+
}
|
|
20
|
+
return (e, n) => {
|
|
21
|
+
const v = p("FmButton");
|
|
22
|
+
return d(), N(v, {
|
|
23
|
+
label: c(m)("connect.marketing.emptyState.action"),
|
|
24
|
+
"prepend-icon": "wand_stars",
|
|
25
|
+
onClick: a
|
|
26
|
+
}, null, 8, ["label"]);
|
|
27
|
+
};
|
|
28
|
+
}
|
|
29
|
+
}), Y = { class: "text-fm-color-typo-error fm-typo-en-body-md-400" }, ee = /* @__PURE__ */ M({
|
|
30
|
+
__name: "MarketingMaterialItemActionButton",
|
|
31
|
+
props: {
|
|
32
|
+
material: {}
|
|
33
|
+
},
|
|
34
|
+
emits: ["update:menuOpened", "deleted"],
|
|
35
|
+
setup(u, { emit: m }) {
|
|
36
|
+
const i = u, a = m, { t: e } = b(), n = _(!1);
|
|
37
|
+
L(n, (o) => {
|
|
38
|
+
a("update:menuOpened", o);
|
|
39
|
+
});
|
|
40
|
+
const {
|
|
41
|
+
shareMaterial: v,
|
|
42
|
+
downloadMaterialImage: t,
|
|
43
|
+
copyMaterialLink: s,
|
|
44
|
+
deleteMaterial: C
|
|
45
|
+
} = Z();
|
|
46
|
+
async function F() {
|
|
47
|
+
n.value = !1, await v(i.material);
|
|
48
|
+
}
|
|
49
|
+
async function x() {
|
|
50
|
+
n.value = !1, await t(i.material.imageUrl);
|
|
51
|
+
}
|
|
52
|
+
async function I() {
|
|
53
|
+
n.value = !1, await s(i.material.imageUrl);
|
|
54
|
+
}
|
|
55
|
+
async function A() {
|
|
56
|
+
n.value = !1, await C(i.material) && a("deleted", i.material._id);
|
|
57
|
+
}
|
|
58
|
+
return (o, g) => {
|
|
59
|
+
const S = p("FmButton"), y = p("FmMenuItem"), h = p("FmMenuDivider"), R = p("FmIcon"), T = p("FmMenu");
|
|
60
|
+
return d(), f("div", null, [
|
|
61
|
+
l(T, {
|
|
62
|
+
placement: "right-start",
|
|
63
|
+
shift: !0,
|
|
64
|
+
"model-value": n.value,
|
|
65
|
+
onMenuChanged: g[0] || (g[0] = (U) => n.value = U)
|
|
66
|
+
}, {
|
|
67
|
+
"menu-button": k(() => [
|
|
68
|
+
l(S, {
|
|
69
|
+
icon: "more_vert",
|
|
70
|
+
variant: "tertiary",
|
|
71
|
+
size: "md"
|
|
72
|
+
})
|
|
73
|
+
]),
|
|
74
|
+
default: k(() => [
|
|
75
|
+
l(y, {
|
|
76
|
+
icon: "share",
|
|
77
|
+
label: c(e)("connect.marketing.actions.share"),
|
|
78
|
+
onClick: F
|
|
79
|
+
}, null, 8, ["label"]),
|
|
80
|
+
l(y, {
|
|
81
|
+
icon: "download",
|
|
82
|
+
label: c(e)("connect.marketing.actions.download"),
|
|
83
|
+
onClick: x
|
|
84
|
+
}, null, 8, ["label"]),
|
|
85
|
+
l(y, {
|
|
86
|
+
icon: "content_copy",
|
|
87
|
+
label: c(e)("connect.marketing.actions.copyLink"),
|
|
88
|
+
onClick: I
|
|
89
|
+
}, null, 8, ["label"]),
|
|
90
|
+
l(h),
|
|
91
|
+
l(y, { onClick: A }, {
|
|
92
|
+
prepend: k(() => [
|
|
93
|
+
l(R, {
|
|
94
|
+
name: "delete",
|
|
95
|
+
size: "md",
|
|
96
|
+
color: "typo-error",
|
|
97
|
+
outline: ""
|
|
98
|
+
})
|
|
99
|
+
]),
|
|
100
|
+
label: k(() => [
|
|
101
|
+
r("div", Y, w(c(e)("connect.common.delete")), 1)
|
|
102
|
+
]),
|
|
103
|
+
_: 1
|
|
104
|
+
})
|
|
105
|
+
]),
|
|
106
|
+
_: 1
|
|
107
|
+
}, 8, ["model-value"])
|
|
108
|
+
]);
|
|
109
|
+
};
|
|
110
|
+
}
|
|
111
|
+
}), te = { class: "h-[205.5px] w-full overflow-hidden bg-fm-color-neutral-gray-100" }, ne = ["src", "alt"], ae = { class: "p-3" }, oe = { class: "flex items-start justify-between gap-2" }, le = { class: "space-y-1 overflow-hidden" }, re = { class: "font-semibold text-sm text-gray-900 truncate" }, ie = { class: "text-xs text-gray-500 line-clamp-2" }, se = {
|
|
112
|
+
key: 1,
|
|
113
|
+
class: "rounded-lg overflow-hidden border border-transparent fm-shadow-light-100 animate-pulse bg-white"
|
|
114
|
+
}, D = /* @__PURE__ */ M({
|
|
115
|
+
__name: "MarketingMaterialItem",
|
|
116
|
+
props: {
|
|
117
|
+
material: {}
|
|
118
|
+
},
|
|
119
|
+
emits: ["deleted"],
|
|
120
|
+
setup(u, { emit: m }) {
|
|
121
|
+
const i = m, { t: a } = b(), e = Q(), n = _(!1);
|
|
122
|
+
return (v, t) => u.material ? (d(), f("div", {
|
|
123
|
+
key: 0,
|
|
124
|
+
class: "group rounded-lg overflow-hidden cursor-pointer border border-transparent hover:border-blue-500 hover:bg-blue-50 transition-[border-color,background-color] fm-shadow-light-100 hover:fm-shadow-light-300",
|
|
125
|
+
onClick: t[3] || (t[3] = () => {
|
|
126
|
+
n.value || c(e).push({
|
|
127
|
+
name: c(W)["$connect-MARKETING_MATERIAL_EDIT"],
|
|
128
|
+
query: { id: u.material._id }
|
|
129
|
+
});
|
|
130
|
+
})
|
|
131
|
+
}, [
|
|
132
|
+
r("div", te, [
|
|
133
|
+
r("img", {
|
|
134
|
+
src: u.material.imageUrl,
|
|
135
|
+
alt: c(a)("connect.marketing.title"),
|
|
136
|
+
class: "w-full h-full object-cover"
|
|
137
|
+
}, null, 8, ne)
|
|
138
|
+
]),
|
|
139
|
+
r("div", ae, [
|
|
140
|
+
r("div", oe, [
|
|
141
|
+
r("div", le, [
|
|
142
|
+
r("p", re, w(u.material.headline), 1),
|
|
143
|
+
r("p", ie, w(u.material.caption), 1)
|
|
144
|
+
]),
|
|
145
|
+
l(ee, {
|
|
146
|
+
material: u.material,
|
|
147
|
+
"onUpdate:menuOpened": t[0] || (t[0] = (s) => n.value = s),
|
|
148
|
+
onDeleted: t[1] || (t[1] = (s) => i("deleted", s)),
|
|
149
|
+
onClick: t[2] || (t[2] = P(() => {
|
|
150
|
+
}, ["stop"]))
|
|
151
|
+
}, null, 8, ["material"])
|
|
152
|
+
])
|
|
153
|
+
])
|
|
154
|
+
])) : (d(), f("div", se, [...t[4] || (t[4] = [
|
|
155
|
+
H('<div class="h-[205.5px] w-full bg-fm-color-neutral-gray-100"></div><div class="p-3 space-y-2"><div class="h-[16px] w-3/4 rounded bg-fm-color-neutral-gray-100"></div><div class="h-12 w-full rounded bg-fm-color-neutral-gray-100"></div><div class="h-12 w-2/3 rounded bg-fm-color-neutral-gray-100"></div></div>', 2)
|
|
156
|
+
])]));
|
|
157
|
+
}
|
|
158
|
+
}), ce = {
|
|
159
|
+
key: 0,
|
|
160
|
+
class: "px-24 xs:px-12 flex flex-col gap-y-16 py-24 xs:py-16"
|
|
161
|
+
}, ue = { class: "fm-typo-en-title-sm-800 text-center" }, me = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary w-4/6 xs:w-full text-center" }, de = {
|
|
162
|
+
key: 1,
|
|
163
|
+
class: "px-24 xs:px-12 flex flex-col gap-y-24 xs:gap-y-16 pt-24 xs:pt-16"
|
|
164
|
+
}, pe = { class: "grid grid-cols-1 sm:grid-cols-2 md:grid-cols-3 lg:grid-cols-4 gap-16" }, E = 20, we = /* @__PURE__ */ M({
|
|
165
|
+
__name: "Marketing",
|
|
166
|
+
setup(u) {
|
|
167
|
+
const { t: m } = b(), i = O(), a = _([]), e = _(!0), n = _(!0), v = _(null), t = _(null);
|
|
168
|
+
let s = null;
|
|
169
|
+
const C = V(() => ({
|
|
170
|
+
label: m("connect.marketing.emptyState.action"),
|
|
171
|
+
value: "generate",
|
|
172
|
+
isPrimary: !0,
|
|
173
|
+
prependIcon: "wand_stars"
|
|
174
|
+
}));
|
|
175
|
+
function F(o) {
|
|
176
|
+
o === "generate" && i.activate({
|
|
177
|
+
command: "generateMarketingMaterial",
|
|
178
|
+
fullscreen: !0,
|
|
179
|
+
forceNewConversation: !0
|
|
180
|
+
});
|
|
181
|
+
}
|
|
182
|
+
async function x() {
|
|
183
|
+
const o = await J.listMarketingMaterials(
|
|
184
|
+
v.value,
|
|
185
|
+
E
|
|
186
|
+
);
|
|
187
|
+
a.value.push(...o.resources), v.value = o.meta.nextCursor, n.value = !!o.meta.nextCursor;
|
|
188
|
+
}
|
|
189
|
+
async function I(o) {
|
|
190
|
+
if (a.value = a.value.filter((g) => g._id !== o), !(a.value.length > 0 || !n.value || e.value)) {
|
|
191
|
+
e.value = !0;
|
|
192
|
+
try {
|
|
193
|
+
await x();
|
|
194
|
+
} catch {
|
|
195
|
+
} finally {
|
|
196
|
+
e.value = !1;
|
|
197
|
+
}
|
|
198
|
+
}
|
|
199
|
+
}
|
|
200
|
+
function A() {
|
|
201
|
+
s = new IntersectionObserver(
|
|
202
|
+
async ([o]) => {
|
|
203
|
+
if (!(!o.isIntersecting || !n.value || e.value)) {
|
|
204
|
+
e.value = !0;
|
|
205
|
+
try {
|
|
206
|
+
await x();
|
|
207
|
+
} catch {
|
|
208
|
+
} finally {
|
|
209
|
+
e.value = !1;
|
|
210
|
+
}
|
|
211
|
+
}
|
|
212
|
+
},
|
|
213
|
+
{ rootMargin: "200px" }
|
|
214
|
+
), t.value && s.observe(t.value);
|
|
215
|
+
}
|
|
216
|
+
return j(async () => {
|
|
217
|
+
try {
|
|
218
|
+
await x();
|
|
219
|
+
} catch {
|
|
220
|
+
} finally {
|
|
221
|
+
e.value = !1, await z(), A();
|
|
222
|
+
}
|
|
223
|
+
}), G(() => {
|
|
224
|
+
s == null || s.disconnect();
|
|
225
|
+
}), (o, g) => {
|
|
226
|
+
const S = p("FmPageHead"), y = p("FmCard");
|
|
227
|
+
return d(), f($, null, [
|
|
228
|
+
l(S, {
|
|
229
|
+
title: c(m)("connect.marketing.title"),
|
|
230
|
+
actions: a.value.length > 0 ? [C.value] : [],
|
|
231
|
+
"onClick:action": F
|
|
232
|
+
}, null, 8, ["title", "actions"]),
|
|
233
|
+
!e.value && a.value.length === 0 ? (d(), f("div", ce, [
|
|
234
|
+
l(y, {
|
|
235
|
+
variant: "outlined",
|
|
236
|
+
class: "w-full justify-center items-center flex flex-col p-[24px] xs:p-16 gap-[24px] xs:gap-16"
|
|
237
|
+
}, {
|
|
238
|
+
default: k(() => [
|
|
239
|
+
g[0] || (g[0] = r("img", {
|
|
240
|
+
src: K,
|
|
241
|
+
class: "w-[150px]"
|
|
242
|
+
}, null, -1)),
|
|
243
|
+
r("p", ue, w(c(m)("connect.marketing.emptyState.title")), 1),
|
|
244
|
+
r("p", me, w(c(m)("connect.marketing.emptyState.description")), 1),
|
|
245
|
+
l(X)
|
|
246
|
+
]),
|
|
247
|
+
_: 1
|
|
248
|
+
})
|
|
249
|
+
])) : (d(), f("div", de, [
|
|
250
|
+
r("div", pe, [
|
|
251
|
+
(d(!0), f($, null, B(a.value, (h) => (d(), N(D, {
|
|
252
|
+
key: h._id,
|
|
253
|
+
material: h,
|
|
254
|
+
onDeleted: I
|
|
255
|
+
}, null, 8, ["material"]))), 128)),
|
|
256
|
+
e.value ? (d(), f($, { key: 0 }, B(E, (h) => l(D, {
|
|
257
|
+
key: `skeleton-${h}`,
|
|
258
|
+
material: null
|
|
259
|
+
})), 64)) : q("", !0)
|
|
260
|
+
]),
|
|
261
|
+
r("div", {
|
|
262
|
+
ref_key: "sentinel",
|
|
263
|
+
ref: t,
|
|
264
|
+
class: "h-1"
|
|
265
|
+
}, null, 512)
|
|
266
|
+
]))
|
|
267
|
+
], 64);
|
|
268
|
+
};
|
|
269
|
+
}
|
|
270
|
+
});
|
|
271
|
+
export {
|
|
272
|
+
we as default
|
|
273
|
+
};
|