@feedmepos/mf-brand-app-builder 0.5.46-prod → 0.5.47-dev.1
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 +16 -0
- package/dist/App-Ck5Q4Z44.js +114 -0
- package/dist/{AssetsSettings-Do8rt2sU.js → AssetsSettings-DtZ6goQl.js} +22 -22
- package/dist/{BrandkitView-nfDiG0HS.js → BrandkitView-BZCLurZL.js} +3366 -3315
- package/dist/{BuilderView-D6aesdSu.js → BuilderView-BDYSDiXE.js} +7 -7
- package/dist/{CredentialSettings-BB_Yroul.js → CredentialSettings-3eVBw1x8.js} +1 -1
- package/dist/{ImageUpload-BZj85a8g.js → ImageUpload-XCqd_Lf1.js} +8 -8
- package/dist/{LinkButton-DNXBKGCn.js → LinkButton-De-YNclu.js} +1 -1
- package/dist/{ListRepeater-tz5QcoGP.js → ListRepeater-BjWvukJ6.js} +1 -1
- package/dist/{ManagementSettings-CjsGetkI.js → ManagementSettings-CWAKkmbz.js} +6 -6
- package/dist/{ProjectView-Dc-furGA.js → ProjectView-DO6VUrFS.js} +3 -3
- package/dist/{app-MFB1wiue.js → app-BG4E6k9-.js} +183 -151
- package/dist/app.js +1 -1
- package/dist/client/merchant/src/app.d.ts +32 -0
- package/dist/client/merchant/src/composables/miniprogramPortalEntry.d.ts +12 -0
- package/dist/{dayjs.min-Ctmrwhx3.js → dayjs.min-Df-s3E18.js} +1 -1
- package/dist/{image-S7-2rbQS.js → image-D_Djf1PS.js} +7 -7
- package/dist/{index-BpYD24Jn.js → index-BA2J-Ffh.js} +1 -1
- package/dist/{index-CPs0rWCO.js → index-Bk6TOZrx.js} +15 -15
- package/dist/index-CVVQJJYY.js +134 -0
- package/dist/{index-C6_vWPi0.js → index-D0LOMBBD.js} +27 -27
- package/dist/{main-LDiBfnFA.js → main-C91a3jWJ.js} +4 -4
- package/dist/package.json +1 -1
- package/dist/style.css +1 -1
- package/dist/{useBusinessFeatureFlag-Dw4hpcYo.js → useBusinessFeatureFlag-CfpvWi12.js} +218 -227
- package/package.json +1 -1
- package/dist/App-DD3xAvwR.js +0 -121
- package/dist/index-CP6_oC8N.js +0 -134
package/package.json
CHANGED
package/dist/App-DD3xAvwR.js
DELETED
|
@@ -1,121 +0,0 @@
|
|
|
1
|
-
import { defineComponent as g, computed as _, resolveComponent as d, createElementBlock as i, openBlock as a, Fragment as v, renderList as b, createVNode as n, unref as f, withCtx as h, ref as x, onMounted as y, onBeforeMount as B, watch as F, createElementVNode as p, createBlock as k, createCommentVNode as S } from "vue";
|
|
2
|
-
import { useCoreStore as C } from "@feedmepos/mf-common";
|
|
3
|
-
import { V as R } from "./vue-sonner-CBFYmm8_.js";
|
|
4
|
-
import { useRoute as V, useRouter as P, RouterLink as L, RouterView as N } from "vue-router";
|
|
5
|
-
import { u as A, i as E } from "./useBusinessFeatureFlag-Dw4hpcYo.js";
|
|
6
|
-
import { g as M } from "./index-C6_vWPi0.js";
|
|
7
|
-
import { u as $ } from "./index-BpYD24Jn.js";
|
|
8
|
-
const z = { class: "shrink-0 w-64 h-full bg-fm-color-neutral-white border-r border-fm-color-neutral-gray-100 p-[10px] flex flex-col gap-12" }, O = /* @__PURE__ */ g({
|
|
9
|
-
__name: "NavigationSidebar",
|
|
10
|
-
setup(w) {
|
|
11
|
-
const t = V();
|
|
12
|
-
P();
|
|
13
|
-
const c = A("order_miniprogram_v2"), r = [
|
|
14
|
-
{
|
|
15
|
-
name: "brandkit",
|
|
16
|
-
icon: "style"
|
|
17
|
-
},
|
|
18
|
-
{
|
|
19
|
-
name: "projects",
|
|
20
|
-
icon: "folder"
|
|
21
|
-
},
|
|
22
|
-
{
|
|
23
|
-
name: "builder",
|
|
24
|
-
icon: "build"
|
|
25
|
-
},
|
|
26
|
-
{
|
|
27
|
-
name: "miniprogram-workspace",
|
|
28
|
-
icon: "auto_awesome",
|
|
29
|
-
flag: c
|
|
30
|
-
},
|
|
31
|
-
{
|
|
32
|
-
name: "settings",
|
|
33
|
-
icon: "settings"
|
|
34
|
-
}
|
|
35
|
-
], u = _(
|
|
36
|
-
() => r.filter((e) => !e.flag || e.flag.value)
|
|
37
|
-
), o = _(
|
|
38
|
-
() => (e) => t.matched.map((s) => s.name).includes(e)
|
|
39
|
-
);
|
|
40
|
-
return (e, s) => {
|
|
41
|
-
const m = d("FmButton");
|
|
42
|
-
return a(), i("div", z, [
|
|
43
|
-
(a(!0), i(v, null, b(u.value, (l) => (a(), i("div", null, [
|
|
44
|
-
n(f(L), {
|
|
45
|
-
to: { name: l.name }
|
|
46
|
-
}, {
|
|
47
|
-
default: h(() => [
|
|
48
|
-
n(m, {
|
|
49
|
-
class: "w-[44px] !h-[44px]",
|
|
50
|
-
size: "lg",
|
|
51
|
-
icon: l.icon,
|
|
52
|
-
"icon-color": o.value(l.name) ? "primary" : "neutral-gray-400",
|
|
53
|
-
"bg-color": o.value(l.name) ? "system-warning-100" : "neutral-white"
|
|
54
|
-
}, null, 8, ["icon", "icon-color", "bg-color"])
|
|
55
|
-
]),
|
|
56
|
-
_: 2
|
|
57
|
-
}, 1032, ["to"])
|
|
58
|
-
]))), 256))
|
|
59
|
-
]);
|
|
60
|
-
};
|
|
61
|
-
}
|
|
62
|
-
}), j = { class: "relative h-[calc(100vh-56px)] w-screen" }, D = { class: "flex w-full h-full" }, Q = /* @__PURE__ */ g({
|
|
63
|
-
__name: "App",
|
|
64
|
-
setup(w) {
|
|
65
|
-
const t = C(), c = $(), r = x(!0);
|
|
66
|
-
async function u() {
|
|
67
|
-
var o;
|
|
68
|
-
r.value = !0, (o = t.currentBusiness.value) != null && o._id && (await M(), await c.getPremiumStatus(t.currentBusiness.value._id), r.value = !1);
|
|
69
|
-
}
|
|
70
|
-
return y(async () => {
|
|
71
|
-
console.log(
|
|
72
|
-
`Running v0.5.46-prod on ${t.namespace.value}`
|
|
73
|
-
), t.hideSidebar.value = !0;
|
|
74
|
-
const o = t.namespace.value === "prod" ? "prod" : "dev";
|
|
75
|
-
E(o).catch(
|
|
76
|
-
(e) => console.warn("[FeatureFlag] init failed:", e)
|
|
77
|
-
);
|
|
78
|
-
}), B(() => {
|
|
79
|
-
t.hideSidebar.value = !1;
|
|
80
|
-
}), F(
|
|
81
|
-
() => t.currentBusiness.value,
|
|
82
|
-
() => u(),
|
|
83
|
-
{ immediate: !0 }
|
|
84
|
-
), (o, e) => {
|
|
85
|
-
const s = d("FmCircularProgress"), m = d("FmOverlay");
|
|
86
|
-
return a(), i(v, null, [
|
|
87
|
-
e[0] || (e[0] = p("link", {
|
|
88
|
-
href: "https://fonts.googleapis.com/css2?family=Material+Symbols+Rounded:opsz,wght,FILL,GRAD@24,400,0..1,0",
|
|
89
|
-
rel: "stylesheet"
|
|
90
|
-
}, null, -1)),
|
|
91
|
-
p("div", j, [
|
|
92
|
-
n(f(R), {
|
|
93
|
-
position: "top-right",
|
|
94
|
-
"rich-colors": "",
|
|
95
|
-
"close-button": "",
|
|
96
|
-
duration: 3e3
|
|
97
|
-
}),
|
|
98
|
-
r.value ? (a(), k(m, {
|
|
99
|
-
key: 0,
|
|
100
|
-
"dismiss-away": !1,
|
|
101
|
-
"prevent-backdrop-event": !1,
|
|
102
|
-
transparent: !1,
|
|
103
|
-
"center-content": ""
|
|
104
|
-
}, {
|
|
105
|
-
default: h(() => [
|
|
106
|
-
n(s, { size: "xxl" })
|
|
107
|
-
]),
|
|
108
|
-
_: 1
|
|
109
|
-
})) : S("", !0),
|
|
110
|
-
p("div", D, [
|
|
111
|
-
n(O),
|
|
112
|
-
n(f(N), { class: "flex-1" })
|
|
113
|
-
])
|
|
114
|
-
])
|
|
115
|
-
], 64);
|
|
116
|
-
};
|
|
117
|
-
}
|
|
118
|
-
});
|
|
119
|
-
export {
|
|
120
|
-
Q as default
|
|
121
|
-
};
|
package/dist/index-CP6_oC8N.js
DELETED
|
@@ -1,134 +0,0 @@
|
|
|
1
|
-
import { H as e, a as o } from "./index-C6_vWPi0.js";
|
|
2
|
-
const d = () => o().PORTAL_V2_BACKEND, c = () => o().LICENSE_BACKEND;
|
|
3
|
-
async function p(t) {
|
|
4
|
-
return (await e.Get(
|
|
5
|
-
"https://api.feedme.vip",
|
|
6
|
-
`/short-url/${t}`
|
|
7
|
-
)).data;
|
|
8
|
-
}
|
|
9
|
-
async function u(t, a, s) {
|
|
10
|
-
return await e.Post(
|
|
11
|
-
"https://api.feedme.vip",
|
|
12
|
-
"/short-url",
|
|
13
|
-
{
|
|
14
|
-
data: {
|
|
15
|
-
slug: t,
|
|
16
|
-
oldSlug: a,
|
|
17
|
-
type: "BUSINESS",
|
|
18
|
-
businessId: s
|
|
19
|
-
}
|
|
20
|
-
}
|
|
21
|
-
).then((n) => n.data).catch((n) => {
|
|
22
|
-
var r;
|
|
23
|
-
throw (r = n.response) == null ? void 0 : r.data;
|
|
24
|
-
});
|
|
25
|
-
}
|
|
26
|
-
async function f(t) {
|
|
27
|
-
return (await e.Get(
|
|
28
|
-
"https://api.feedme.vip",
|
|
29
|
-
`/metadata/${t}/config`
|
|
30
|
-
)).data;
|
|
31
|
-
}
|
|
32
|
-
async function m(t, a, s) {
|
|
33
|
-
return (await e.Post(
|
|
34
|
-
"https://api.feedme.vip",
|
|
35
|
-
`/metadata/${t}/config`,
|
|
36
|
-
{
|
|
37
|
-
data: {
|
|
38
|
-
name: a,
|
|
39
|
-
backgroundColor: "#ffffff",
|
|
40
|
-
country: s
|
|
41
|
-
}
|
|
42
|
-
}
|
|
43
|
-
)).data;
|
|
44
|
-
}
|
|
45
|
-
async function l(t) {
|
|
46
|
-
return (await e.Get(
|
|
47
|
-
"https://api.feedme.vip",
|
|
48
|
-
`/metadata/${t}/brandkit`
|
|
49
|
-
)).data;
|
|
50
|
-
}
|
|
51
|
-
async function h(t, a) {
|
|
52
|
-
return (await e.Post(
|
|
53
|
-
"https://api.feedme.vip",
|
|
54
|
-
`/metadata/${t}/brandkit`,
|
|
55
|
-
{
|
|
56
|
-
data: a
|
|
57
|
-
}
|
|
58
|
-
)).data;
|
|
59
|
-
}
|
|
60
|
-
async function y(t, a) {
|
|
61
|
-
return (await e.Get(
|
|
62
|
-
"https://api.feedme.vip",
|
|
63
|
-
`/metadata/${t}/brandkit/template-history/${a}`
|
|
64
|
-
)).data;
|
|
65
|
-
}
|
|
66
|
-
async function $(t, a, s) {
|
|
67
|
-
return (await e.Post(
|
|
68
|
-
"https://api.feedme.vip",
|
|
69
|
-
`/metadata/${t}/brandkit/template-restore/${a}/${s}`,
|
|
70
|
-
{}
|
|
71
|
-
)).data;
|
|
72
|
-
}
|
|
73
|
-
async function w(t, a) {
|
|
74
|
-
return (await e.Delete(
|
|
75
|
-
"https://api.feedme.vip",
|
|
76
|
-
`/metadata/${t}/brandkit/template-history/${a}`
|
|
77
|
-
)).data;
|
|
78
|
-
}
|
|
79
|
-
async function g(t, a) {
|
|
80
|
-
const s = {
|
|
81
|
-
...a,
|
|
82
|
-
url: a.url || t
|
|
83
|
-
};
|
|
84
|
-
return await e.Put(
|
|
85
|
-
d(),
|
|
86
|
-
`businesses/${t}/profile`,
|
|
87
|
-
{
|
|
88
|
-
data: s
|
|
89
|
-
}
|
|
90
|
-
).catch((r) => {
|
|
91
|
-
var i;
|
|
92
|
-
throw (i = r.response) == null ? void 0 : i.data;
|
|
93
|
-
});
|
|
94
|
-
}
|
|
95
|
-
async function B(t) {
|
|
96
|
-
return await e.Get(
|
|
97
|
-
c(),
|
|
98
|
-
`api/business/${t}/feature/miniprogram`
|
|
99
|
-
).then((a) => a.data).catch(() => !1);
|
|
100
|
-
}
|
|
101
|
-
async function v(t) {
|
|
102
|
-
return (await e.Get(
|
|
103
|
-
"https://api.feedme.vip",
|
|
104
|
-
`/metadata/${t}/credentials`,
|
|
105
|
-
{}
|
|
106
|
-
)).data;
|
|
107
|
-
}
|
|
108
|
-
async function P(t, a) {
|
|
109
|
-
return (await e.Post(
|
|
110
|
-
"https://api.feedme.vip",
|
|
111
|
-
`/metadata/${t}/credentials`,
|
|
112
|
-
{
|
|
113
|
-
data: a
|
|
114
|
-
}
|
|
115
|
-
)).data;
|
|
116
|
-
}
|
|
117
|
-
const k = {
|
|
118
|
-
getGlobalSlug: p,
|
|
119
|
-
setShortUrl: u,
|
|
120
|
-
getBusinessMetadata: f,
|
|
121
|
-
setBusinessMetadata: m,
|
|
122
|
-
getBusinessBrandkit: l,
|
|
123
|
-
setBusinessBrandkit: h,
|
|
124
|
-
getTemplateHistory: y,
|
|
125
|
-
restoreTemplateVersion: $,
|
|
126
|
-
clearTemplateHistory: w,
|
|
127
|
-
updateBusinessProfile: g,
|
|
128
|
-
getBusinessPremiumStatus: B,
|
|
129
|
-
getCredentials: v,
|
|
130
|
-
updateCredentials: P
|
|
131
|
-
};
|
|
132
|
-
export {
|
|
133
|
-
k as B
|
|
134
|
-
};
|