@feedmepos/mf-brand-app-builder 0.5.43-dev.1 → 0.5.45-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/dist/App-fxWMiswF.js +121 -0
- package/dist/{BrandkitView-CKCJs4dU.js → BrandkitView-CnsKm_nt.js} +2625 -2652
- package/dist/{BuilderView-Cdj86CAt.js → BuilderView-DlAFI1gC.js} +3 -3
- package/dist/{ImageUpload-czx5o-j6.js → ImageUpload-DxerDooG.js} +1 -1
- package/dist/{ListRepeater-DBkUbAFA.js → ListRepeater-DDEV4xLl.js} +1 -1
- package/dist/{ProjectView-DtxPapNI.js → ProjectView-DZ3qaw_E.js} +2 -2
- package/dist/{app-BlFm1Tkh.js → app-DqTMfqMo.js} +1135 -1156
- package/dist/app.js +1 -1
- package/dist/brand-core/src/brandkit.d.ts +34 -0
- package/dist/brand-core/src/entity.d.ts +0 -1
- package/dist/brandkit-Jwi77VnL.js +144 -0
- package/dist/client/merchant/src/app.d.ts +0 -28
- package/dist/client/merchant/src/composables/useBusinessFeatureFlag.d.ts +17 -0
- package/dist/client/merchant/src/main.d.ts +1 -0
- package/dist/client/merchant/src/stores/business/index.d.ts +0 -6
- package/dist/{dayjs.min-Bdy6lFTt.js → dayjs.min-B4vcU5Bc.js} +1 -1
- package/dist/{main-CozSePSS.js → main-DN4hx_tp.js} +2 -2
- package/dist/package.json +2 -1
- package/dist/style.css +1 -1
- package/dist/{useBusinessFeatureFlag-2_0Z_IYf.js → useBusinessFeatureFlag-BtLpiYy7.js} +281 -263
- package/package.json +2 -1
- package/dist/App-C1Sg6gD6.js +0 -114
- package/dist/brandkit-1Te5zV_c.js +0 -127
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@feedmepos/mf-brand-app-builder",
|
|
3
|
-
"version": "0.5.
|
|
3
|
+
"version": "0.5.45-dev.1",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"files": [
|
|
6
6
|
"dist"
|
|
@@ -19,6 +19,7 @@
|
|
|
19
19
|
"@feedmepos/feature-flag": "^0.0.15",
|
|
20
20
|
"@feedmepos/hrm-permission": "1.0.10",
|
|
21
21
|
"@feedmepos/mf-common": "^1.26.3",
|
|
22
|
+
"@feedmepos/mf-miniprogram-v2": "https://registry.npmjs.org/@feedmepos/mf-miniprogram-v2/-/mf-miniprogram-v2-0.2.0-dev.2.tgz",
|
|
22
23
|
"@feedmepos/ui-library": "1.8.4",
|
|
23
24
|
"@formkit/core": "^1.6.7",
|
|
24
25
|
"@formkit/vue": "^1.6.7",
|
package/dist/App-C1Sg6gD6.js
DELETED
|
@@ -1,114 +0,0 @@
|
|
|
1
|
-
import { defineComponent as d, computed as h, resolveComponent as u, createElementBlock as m, openBlock as i, Fragment as f, renderList as w, createElementVNode as l, createVNode as a, unref as p, withCtx as _, ref as b, onMounted as x, onBeforeMount as y, watch as B, createBlock as F, createCommentVNode as k } from "vue";
|
|
2
|
-
import { useCoreStore as S } from "@feedmepos/mf-common";
|
|
3
|
-
import { V as C } from "./vue-sonner-CBFYmm8_.js";
|
|
4
|
-
import { useRoute as R, useRouter as V, RouterLink as L, RouterView as P } from "vue-router";
|
|
5
|
-
import { g as A } from "./index-D0LOMBBD.js";
|
|
6
|
-
import { u as N } from "./index-BA2J-Ffh.js";
|
|
7
|
-
import { i as $ } from "./useBusinessFeatureFlag-2_0Z_IYf.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" }, M = /* @__PURE__ */ d({
|
|
9
|
-
__name: "NavigationSidebar",
|
|
10
|
-
setup(v) {
|
|
11
|
-
const e = R();
|
|
12
|
-
V();
|
|
13
|
-
const c = [
|
|
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: "settings",
|
|
28
|
-
icon: "settings"
|
|
29
|
-
}
|
|
30
|
-
], o = h(
|
|
31
|
-
() => (s) => e.matched.map((t) => t.name).includes(s)
|
|
32
|
-
);
|
|
33
|
-
return (s, t) => {
|
|
34
|
-
const n = u("FmButton");
|
|
35
|
-
return i(), m("div", z, [
|
|
36
|
-
(i(), m(f, null, w(c, (r) => l("div", null, [
|
|
37
|
-
a(p(L), {
|
|
38
|
-
to: { name: r.name }
|
|
39
|
-
}, {
|
|
40
|
-
default: _(() => [
|
|
41
|
-
a(n, {
|
|
42
|
-
class: "w-[44px] !h-[44px]",
|
|
43
|
-
size: "lg",
|
|
44
|
-
icon: r.icon,
|
|
45
|
-
"icon-color": o.value(r.name) ? "primary" : "neutral-gray-400",
|
|
46
|
-
"bg-color": o.value(r.name) ? "system-warning-100" : "neutral-white"
|
|
47
|
-
}, null, 8, ["icon", "icon-color", "bg-color"])
|
|
48
|
-
]),
|
|
49
|
-
_: 2
|
|
50
|
-
}, 1032, ["to"])
|
|
51
|
-
])), 64))
|
|
52
|
-
]);
|
|
53
|
-
};
|
|
54
|
-
}
|
|
55
|
-
}), E = { class: "relative h-[calc(100vh-56px)] w-screen" }, O = { class: "flex w-full h-full" }, J = /* @__PURE__ */ d({
|
|
56
|
-
__name: "App",
|
|
57
|
-
setup(v) {
|
|
58
|
-
const e = S(), c = N(), o = b(!0);
|
|
59
|
-
async function s() {
|
|
60
|
-
var t;
|
|
61
|
-
o.value = !0, (t = e.currentBusiness.value) != null && t._id && (await A(), await c.getPremiumStatus(e.currentBusiness.value._id), o.value = !1);
|
|
62
|
-
}
|
|
63
|
-
return x(async () => {
|
|
64
|
-
console.log(
|
|
65
|
-
`Running v0.5.43-dev.1 on ${e.namespace.value}`
|
|
66
|
-
), e.hideSidebar.value = !0;
|
|
67
|
-
const t = e.namespace.value === "prod" ? "prod" : "dev";
|
|
68
|
-
$(t).catch(
|
|
69
|
-
(n) => console.warn("[FeatureFlag] init failed:", n)
|
|
70
|
-
);
|
|
71
|
-
}), y(() => {
|
|
72
|
-
e.hideSidebar.value = !1;
|
|
73
|
-
}), B(
|
|
74
|
-
() => e.currentBusiness.value,
|
|
75
|
-
() => s(),
|
|
76
|
-
{ immediate: !0 }
|
|
77
|
-
), (t, n) => {
|
|
78
|
-
const r = u("FmCircularProgress"), g = u("FmOverlay");
|
|
79
|
-
return i(), m(f, null, [
|
|
80
|
-
n[0] || (n[0] = l("link", {
|
|
81
|
-
href: "https://fonts.googleapis.com/css2?family=Material+Symbols+Rounded:opsz,wght,FILL,GRAD@24,400,0..1,0",
|
|
82
|
-
rel: "stylesheet"
|
|
83
|
-
}, null, -1)),
|
|
84
|
-
l("div", E, [
|
|
85
|
-
a(p(C), {
|
|
86
|
-
position: "top-right",
|
|
87
|
-
"rich-colors": "",
|
|
88
|
-
"close-button": "",
|
|
89
|
-
duration: 3e3
|
|
90
|
-
}),
|
|
91
|
-
o.value ? (i(), F(g, {
|
|
92
|
-
key: 0,
|
|
93
|
-
"dismiss-away": !1,
|
|
94
|
-
"prevent-backdrop-event": !1,
|
|
95
|
-
transparent: !1,
|
|
96
|
-
"center-content": ""
|
|
97
|
-
}, {
|
|
98
|
-
default: _(() => [
|
|
99
|
-
a(r, { size: "xxl" })
|
|
100
|
-
]),
|
|
101
|
-
_: 1
|
|
102
|
-
})) : k("", !0),
|
|
103
|
-
l("div", O, [
|
|
104
|
-
a(M),
|
|
105
|
-
a(p(P), { class: "flex-1" })
|
|
106
|
-
])
|
|
107
|
-
])
|
|
108
|
-
], 64);
|
|
109
|
-
};
|
|
110
|
-
}
|
|
111
|
-
});
|
|
112
|
-
export {
|
|
113
|
-
J as default
|
|
114
|
-
};
|
|
@@ -1,127 +0,0 @@
|
|
|
1
|
-
import { useSnackbar as O } from "@feedmepos/ui-library";
|
|
2
|
-
function L() {
|
|
3
|
-
const a = O();
|
|
4
|
-
function f(u, y) {
|
|
5
|
-
const { loading: o, success: n, error: e, duration: t } = y, s = a.open(
|
|
6
|
-
{
|
|
7
|
-
message: typeof o == "function" ? o() : o,
|
|
8
|
-
type: "info",
|
|
9
|
-
spinner: !0,
|
|
10
|
-
dismissable: !1
|
|
11
|
-
},
|
|
12
|
-
null
|
|
13
|
-
);
|
|
14
|
-
return (typeof u == "function" ? u() : u).then((c) => (a.close(s), n && a.open(
|
|
15
|
-
{
|
|
16
|
-
message: typeof n == "function" ? n() : n,
|
|
17
|
-
type: "success",
|
|
18
|
-
spinner: !1,
|
|
19
|
-
dismissable: !0
|
|
20
|
-
},
|
|
21
|
-
t ?? 2e3
|
|
22
|
-
), c)).catch((c) => {
|
|
23
|
-
throw e && (a.close(s), a.open(
|
|
24
|
-
{
|
|
25
|
-
message: typeof e == "function" ? e(c) : e,
|
|
26
|
-
type: "error",
|
|
27
|
-
spinner: !1,
|
|
28
|
-
dismissable: !0
|
|
29
|
-
},
|
|
30
|
-
t ?? 2e3
|
|
31
|
-
)), c;
|
|
32
|
-
});
|
|
33
|
-
}
|
|
34
|
-
return {
|
|
35
|
-
promise: f
|
|
36
|
-
};
|
|
37
|
-
}
|
|
38
|
-
const S = /* @__PURE__ */ new Set(), T = {
|
|
39
|
-
colors: {
|
|
40
|
-
primary: "#ff7823",
|
|
41
|
-
secondary: "#fff3e6",
|
|
42
|
-
accent: "#B25300",
|
|
43
|
-
background: {
|
|
44
|
-
base: "#F8F8F8",
|
|
45
|
-
elevated: "#FFFFFF"
|
|
46
|
-
},
|
|
47
|
-
neutral: {
|
|
48
|
-
light: "#DADADA",
|
|
49
|
-
mid: "#B2B3B6",
|
|
50
|
-
dark: "#1C1C1E"
|
|
51
|
-
},
|
|
52
|
-
text: {
|
|
53
|
-
onPrimary: "#FFFFFF",
|
|
54
|
-
primary: "#1C1C1E",
|
|
55
|
-
secondary: "#555555",
|
|
56
|
-
tertiary: "#A2A09E"
|
|
57
|
-
},
|
|
58
|
-
status: {
|
|
59
|
-
success: "#10B981",
|
|
60
|
-
warning: "#F59E0B",
|
|
61
|
-
error: "#EF4444",
|
|
62
|
-
info: "#3B82F6"
|
|
63
|
-
// Add info if missing previously
|
|
64
|
-
}
|
|
65
|
-
},
|
|
66
|
-
fonts: {
|
|
67
|
-
brand: "'Inter', sans-serif",
|
|
68
|
-
heading: "'Inter', sans-serif",
|
|
69
|
-
body: "'Roboto', sans-serif"
|
|
70
|
-
},
|
|
71
|
-
ordering: {
|
|
72
|
-
app: {
|
|
73
|
-
category: "VERTICAL",
|
|
74
|
-
items: "LIST",
|
|
75
|
-
singleCategory: !1
|
|
76
|
-
},
|
|
77
|
-
kiosk: {
|
|
78
|
-
category: "VERTICAL",
|
|
79
|
-
singleCategory: !1
|
|
80
|
-
}
|
|
81
|
-
},
|
|
82
|
-
fontFamilies: []
|
|
83
|
-
};
|
|
84
|
-
function R(a = T, f, u) {
|
|
85
|
-
var c, d, m, p, g, b, h, F, x, B, w, E, A, k, I, P;
|
|
86
|
-
const y = {}, o = document.documentElement, n = (i, r) => {
|
|
87
|
-
r && o.style.setProperty(`--brand-${i}`, r);
|
|
88
|
-
}, { fonts: e } = a, t = y.overrideBy ? (m = (d = (c = a.ordering) == null ? void 0 : c[y.overrideBy]) == null ? void 0 : d.brandkitOverride) == null ? void 0 : m.colors : void 0, s = {
|
|
89
|
-
primary: (t == null ? void 0 : t.primary) ?? a.colors.primary,
|
|
90
|
-
secondary: (t == null ? void 0 : t.secondary) ?? a.colors.secondary,
|
|
91
|
-
accent: (t == null ? void 0 : t.accent) ?? a.colors.accent,
|
|
92
|
-
background: {
|
|
93
|
-
base: ((p = t == null ? void 0 : t.background) == null ? void 0 : p.base) ?? a.colors.background.base,
|
|
94
|
-
elevated: ((g = t == null ? void 0 : t.background) == null ? void 0 : g.elevated) ?? a.colors.background.elevated
|
|
95
|
-
},
|
|
96
|
-
neutral: {
|
|
97
|
-
light: ((b = t == null ? void 0 : t.neutral) == null ? void 0 : b.light) ?? a.colors.neutral.light,
|
|
98
|
-
mid: ((h = t == null ? void 0 : t.neutral) == null ? void 0 : h.mid) ?? a.colors.neutral.mid,
|
|
99
|
-
dark: ((F = t == null ? void 0 : t.neutral) == null ? void 0 : F.dark) ?? a.colors.neutral.dark
|
|
100
|
-
},
|
|
101
|
-
status: {
|
|
102
|
-
success: ((x = t == null ? void 0 : t.status) == null ? void 0 : x.success) ?? a.colors.status.success,
|
|
103
|
-
warning: ((B = t == null ? void 0 : t.status) == null ? void 0 : B.warning) ?? a.colors.status.warning,
|
|
104
|
-
error: ((w = t == null ? void 0 : t.status) == null ? void 0 : w.error) ?? a.colors.status.error,
|
|
105
|
-
info: ((E = t == null ? void 0 : t.status) == null ? void 0 : E.info) ?? a.colors.status.info
|
|
106
|
-
},
|
|
107
|
-
text: {
|
|
108
|
-
onPrimary: ((A = t == null ? void 0 : t.text) == null ? void 0 : A.onPrimary) ?? a.colors.text.onPrimary,
|
|
109
|
-
primary: ((k = t == null ? void 0 : t.text) == null ? void 0 : k.primary) ?? a.colors.text.primary,
|
|
110
|
-
secondary: ((I = t == null ? void 0 : t.text) == null ? void 0 : I.secondary) ?? a.colors.text.secondary,
|
|
111
|
-
tertiary: ((P = t == null ? void 0 : t.text) == null ? void 0 : P.tertiary) ?? a.colors.text.tertiary
|
|
112
|
-
}
|
|
113
|
-
};
|
|
114
|
-
n("color-primary", s.primary), n("color-secondary", s.secondary), n("color-accent", s.accent), n("color-background-base", s.background.base), n("color-background-elevated", s.background.elevated), n("color-neutral-light", s.neutral.light), n("color-neutral-mid", s.neutral.mid), n("color-neutral-dark", s.neutral.dark), n("color-typo-on-primary", s.text.onPrimary), n("color-typo-primary", s.text.primary), n("color-typo-secondary", s.text.secondary), n("color-typo-tertiary", s.text.tertiary), n("color-status-success", s.status.success), n("color-status-warning", s.status.warning), n("color-status-error", s.status.error), n("color-status-info", s.status.info), n("font-family-brand", e.brand), n("font-family-heading", e.heading ?? e.brand), n("font-family-body", e.body ?? e.brand);
|
|
115
|
-
for (const i of a.fontFamilies ?? []) {
|
|
116
|
-
const r = i.stylesheet;
|
|
117
|
-
if (!r || S.has(r) || document.querySelector(`link[href="${r}"]`))
|
|
118
|
-
continue;
|
|
119
|
-
const l = document.createElement("link");
|
|
120
|
-
l.rel = "stylesheet", l.href = r, l.setAttribute("data-brand-font", r), document.head.appendChild(l), S.add(r);
|
|
121
|
-
}
|
|
122
|
-
}
|
|
123
|
-
export {
|
|
124
|
-
R as a,
|
|
125
|
-
T as b,
|
|
126
|
-
L as u
|
|
127
|
-
};
|