@feedmepos/mf-miniprogram-v2 0.2.3 → 0.2.4
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/{AppTemplatePicker.vue_vue_type_script_setup_true_lang-CDvGnq6F.js → AppTemplatePicker.vue_vue_type_script_setup_true_lang-LE_aKvfg.js} +94 -80
- package/dist/{ControlPlaneView-CqUxRaS2.js → ControlPlaneView-Bd8w7Yub.js} +1 -1
- package/dist/{MobileProjectsView-obtkXdEv.js → MobileProjectsView-BCXdpVTc.js} +1 -1
- package/dist/app.js +2 -2
- package/dist/package.json +1 -1
- package/package.json +1 -1
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
function
|
|
1
|
+
import { defineComponent as k, computed as x, openBlock as a, createElementBlock as l, createStaticVNode as m, createCommentVNode as p, createElementVNode as e, createVNode as b, toDisplayString as h, Fragment as w, renderList as _, normalizeClass as y } from "vue";
|
|
2
|
+
function K(t) {
|
|
3
3
|
return t === "active" ? "success" : t === "needs_attention" ? "warning" : "neutral";
|
|
4
4
|
}
|
|
5
|
-
function
|
|
5
|
+
function O(t) {
|
|
6
6
|
return t === "active" ? "Active" : t === "needs_attention" ? "Needs attention" : "Archived";
|
|
7
7
|
}
|
|
8
|
-
function
|
|
8
|
+
function X(t) {
|
|
9
9
|
return t === "succeeded" ? "success" : t === "failed" ? "error" : t === "queued" || t === "running" ? "info" : "neutral";
|
|
10
10
|
}
|
|
11
|
-
function
|
|
11
|
+
function Y(t) {
|
|
12
12
|
switch (t) {
|
|
13
13
|
case "queued":
|
|
14
14
|
return "Queued";
|
|
@@ -22,7 +22,7 @@ function W(t) {
|
|
|
22
22
|
return "No build yet";
|
|
23
23
|
}
|
|
24
24
|
}
|
|
25
|
-
function
|
|
25
|
+
function Z(t) {
|
|
26
26
|
switch (t) {
|
|
27
27
|
case "ready":
|
|
28
28
|
return "Ready";
|
|
@@ -34,66 +34,69 @@ function G(t) {
|
|
|
34
34
|
return "Not set up";
|
|
35
35
|
}
|
|
36
36
|
}
|
|
37
|
-
const
|
|
38
|
-
function
|
|
39
|
-
return
|
|
37
|
+
const C = ["preview", "published", "rolled_back"];
|
|
38
|
+
function tt(t) {
|
|
39
|
+
return C.includes(t.status);
|
|
40
40
|
}
|
|
41
|
-
function
|
|
41
|
+
function et(t) {
|
|
42
42
|
return t.is_live === 1 ? "Live" : t.build_status === "queued" || t.build_status === "running" ? "Building" : t.build_status === "failed" ? "Failed" : t.build_status === "succeeded" ? "Ready" : "Draft";
|
|
43
43
|
}
|
|
44
|
-
function
|
|
44
|
+
function rt(t) {
|
|
45
45
|
return t.is_live === 1 ? "primary" : t.build_status === "succeeded" ? "success" : t.build_status === "queued" || t.build_status === "running" ? "info" : t.build_status === "failed" ? "error" : "neutral";
|
|
46
46
|
}
|
|
47
|
-
const
|
|
47
|
+
const A = {
|
|
48
48
|
key: 0,
|
|
49
49
|
viewBox: "0 0 56 96",
|
|
50
50
|
class: "h-[72px] w-[42px] shrink-0 rounded-[6px] border border-portal-border-default bg-portal-bg-default",
|
|
51
51
|
"aria-hidden": "true",
|
|
52
52
|
focusable: "false"
|
|
53
|
-
},
|
|
53
|
+
}, E = {
|
|
54
54
|
key: 0,
|
|
55
55
|
fill: "currentColor",
|
|
56
56
|
class: "text-fm-color-neutral-gray-300"
|
|
57
|
-
},
|
|
57
|
+
}, B = {
|
|
58
58
|
key: 1,
|
|
59
59
|
fill: "currentColor",
|
|
60
60
|
class: "text-fm-color-neutral-gray-300"
|
|
61
|
-
},
|
|
61
|
+
}, L = {
|
|
62
62
|
key: 2,
|
|
63
63
|
fill: "currentColor",
|
|
64
64
|
class: "text-fm-color-neutral-gray-300"
|
|
65
|
-
},
|
|
65
|
+
}, v = /* @__PURE__ */ k({
|
|
66
66
|
__name: "AppTemplateThumbnail",
|
|
67
67
|
props: {
|
|
68
68
|
restaurantStyle: {}
|
|
69
69
|
},
|
|
70
70
|
setup(t) {
|
|
71
|
-
const
|
|
72
|
-
() =>
|
|
71
|
+
const d = t, u = x(
|
|
72
|
+
() => d.restaurantStyle === "qsr" || d.restaurantStyle === "coffee" || d.restaurantStyle === "tea"
|
|
73
73
|
);
|
|
74
|
-
return (
|
|
75
|
-
t.restaurantStyle === "qsr" ? (a(),
|
|
76
|
-
|
|
77
|
-
])])) : t.restaurantStyle === "coffee" ? (a(),
|
|
78
|
-
|
|
79
|
-
])])) : (a(),
|
|
80
|
-
|
|
74
|
+
return (g, o) => u.value ? (a(), l("svg", A, [
|
|
75
|
+
t.restaurantStyle === "qsr" ? (a(), l("g", E, [...o[0] || (o[0] = [
|
|
76
|
+
m('<rect x="6" y="7" width="44" height="6" rx="3"></rect><rect x="6" y="18" width="19" height="18" rx="2"></rect><rect x="31" y="18" width="19" height="18" rx="2"></rect><rect x="6" y="40" width="19" height="18" rx="2"></rect><rect x="31" y="40" width="19" height="18" rx="2"></rect><rect x="6" y="62" width="19" height="18" rx="2"></rect><rect x="31" y="62" width="19" height="18" rx="2"></rect><rect x="6" y="85" width="44" height="7" rx="3.5" class="text-fm-color-neutral-gray-400"></rect>', 8)
|
|
77
|
+
])])) : t.restaurantStyle === "coffee" ? (a(), l("g", B, [...o[1] || (o[1] = [
|
|
78
|
+
m('<rect x="6" y="7" width="44" height="30" rx="3"></rect><rect x="6" y="43" width="26" height="4" rx="2"></rect><rect x="6" y="53" width="44" height="12" rx="2"></rect><rect x="6" y="69" width="44" height="12" rx="2"></rect><rect x="6" y="87" width="18" height="4" rx="2"></rect>', 5)
|
|
79
|
+
])])) : (a(), l("g", L, [...o[2] || (o[2] = [
|
|
80
|
+
m('<rect x="6" y="7" width="44" height="5" rx="2.5"></rect><rect x="6" y="17" width="44" height="9" rx="2"></rect><rect x="6" y="28" width="9" height="4" rx="2" class="text-fm-color-neutral-gray-400"></rect><rect x="18" y="28" width="9" height="4" rx="2" class="text-fm-color-neutral-gray-400"></rect><rect x="30" y="28" width="9" height="4" rx="2" class="text-fm-color-neutral-gray-400"></rect><rect x="6" y="38" width="44" height="9" rx="2"></rect><rect x="6" y="49" width="9" height="4" rx="2" class="text-fm-color-neutral-gray-400"></rect><rect x="18" y="49" width="9" height="4" rx="2" class="text-fm-color-neutral-gray-400"></rect><rect x="6" y="59" width="44" height="9" rx="2"></rect><rect x="6" y="70" width="9" height="4" rx="2" class="text-fm-color-neutral-gray-400"></rect><rect x="18" y="70" width="9" height="4" rx="2" class="text-fm-color-neutral-gray-400"></rect><rect x="30" y="70" width="9" height="4" rx="2" class="text-fm-color-neutral-gray-400"></rect><rect x="6" y="80" width="44" height="9" rx="2"></rect>', 13)
|
|
81
81
|
])]))
|
|
82
|
-
])) :
|
|
82
|
+
])) : p("", !0);
|
|
83
83
|
}
|
|
84
|
-
}),
|
|
84
|
+
}), N = {
|
|
85
85
|
key: 0,
|
|
86
86
|
class: "rounded-lg border border-portal-border-default bg-portal-bg-default p-16"
|
|
87
|
-
},
|
|
87
|
+
}, T = { class: "mt-12 flex items-start gap-12" }, q = { class: "min-w-0 max-w-[640px] flex-1" }, $ = { class: "m-0 fm-typo-en-body-md-600 text-portal-text-primary" }, D = { class: "m-0 mt-4 fm-typo-en-body-sm-400 text-portal-text-muted" }, R = {
|
|
88
|
+
key: 1,
|
|
89
|
+
class: "rounded-lg border border-portal-border-default bg-portal-bg-default p-16"
|
|
90
|
+
}, P = { class: "mt-12 max-w-[640px]" }, F = {
|
|
88
91
|
key: 0,
|
|
89
92
|
class: "m-0 mb-8 fm-typo-en-body-sm-600 uppercase tracking-wide text-portal-text-muted"
|
|
90
|
-
},
|
|
93
|
+
}, I = { class: "flex flex-col gap-8" }, j = ["aria-checked", "disabled", "onClick"], z = {
|
|
91
94
|
key: 0,
|
|
92
95
|
class: "h-[6px] w-[6px] rounded-full bg-portal-bg-default"
|
|
93
|
-
},
|
|
96
|
+
}, H = { class: "min-w-0 max-w-[640px] flex-1" }, M = { class: "flex flex-wrap items-center gap-8" }, Q = { class: "fm-typo-en-body-md-600 text-portal-text-primary" }, U = {
|
|
94
97
|
key: 0,
|
|
95
98
|
class: "rounded-full bg-portal-bg-canvas px-8 py-[2px] fm-typo-en-body-sm-400 text-portal-text-muted"
|
|
96
|
-
},
|
|
99
|
+
}, W = { class: "mt-4 block fm-typo-en-body-sm-400 text-portal-text-muted" }, st = /* @__PURE__ */ k({
|
|
97
100
|
__name: "AppTemplatePicker",
|
|
98
101
|
props: {
|
|
99
102
|
templates: {},
|
|
@@ -101,84 +104,95 @@ const V = {
|
|
|
101
104
|
disabled: { type: Boolean }
|
|
102
105
|
},
|
|
103
106
|
emits: ["update:modelValue"],
|
|
104
|
-
setup(t, { emit:
|
|
105
|
-
const
|
|
106
|
-
const c = [],
|
|
107
|
-
for (const
|
|
108
|
-
if (!
|
|
109
|
-
c.push(
|
|
107
|
+
setup(t, { emit: d }) {
|
|
108
|
+
const u = t, g = d, o = x(() => u.templates.length > 1), f = x(() => u.templates.length === 1 ? u.templates[0] : null), S = x(() => {
|
|
109
|
+
const c = [], n = /* @__PURE__ */ new Map();
|
|
110
|
+
for (const r of u.templates) {
|
|
111
|
+
if (!r.industries.length) {
|
|
112
|
+
c.push(r);
|
|
110
113
|
continue;
|
|
111
114
|
}
|
|
112
|
-
for (const
|
|
113
|
-
const
|
|
114
|
-
|
|
115
|
+
for (const i of r.industries) {
|
|
116
|
+
const s = n.get(i) ?? [];
|
|
117
|
+
s.push(r), n.set(i, s);
|
|
115
118
|
}
|
|
116
119
|
}
|
|
117
120
|
return [
|
|
118
121
|
...c.length ? [{ label: null, templates: c }] : [],
|
|
119
|
-
...[...
|
|
122
|
+
...[...n.entries()].sort(([r], [i]) => r.localeCompare(i)).map(([r, i]) => ({ label: r, templates: i }))
|
|
120
123
|
];
|
|
121
124
|
});
|
|
122
|
-
function
|
|
123
|
-
|
|
125
|
+
function V(c) {
|
|
126
|
+
u.disabled || g("update:modelValue", c);
|
|
124
127
|
}
|
|
125
|
-
return (c,
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
128
|
+
return (c, n) => f.value ? (a(), l("section", N, [
|
|
129
|
+
n[0] || (n[0] = e("p", { class: "m-0 fm-typo-en-body-md-600 text-portal-text-primary" }, "App template", -1)),
|
|
130
|
+
e("div", T, [
|
|
131
|
+
b(v, {
|
|
132
|
+
"restaurant-style": f.value.restaurantStyle
|
|
133
|
+
}, null, 8, ["restaurant-style"]),
|
|
134
|
+
e("div", q, [
|
|
135
|
+
e("p", $, h(f.value.label), 1),
|
|
136
|
+
e("p", D, h(f.value.description), 1)
|
|
137
|
+
])
|
|
138
|
+
])
|
|
139
|
+
])) : o.value ? (a(), l("section", R, [
|
|
140
|
+
n[1] || (n[1] = e("p", { class: "m-0 fm-typo-en-body-md-600 text-portal-text-primary" }, "App template", -1)),
|
|
141
|
+
n[2] || (n[2] = e("p", { class: "m-0 mt-4 fm-typo-en-body-sm-400 text-portal-text-muted" }, " Choose how this app looks and works for your customers. This cannot be changed after setup. ", -1)),
|
|
142
|
+
e("div", P, [
|
|
143
|
+
(a(!0), l(w, null, _(S.value, (r, i) => (a(), l("div", {
|
|
144
|
+
key: r.label ?? "__general",
|
|
131
145
|
role: "radiogroup",
|
|
132
146
|
"aria-label": "App template",
|
|
133
|
-
class:
|
|
147
|
+
class: y(i === 0 ? "" : "mt-16")
|
|
134
148
|
}, [
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
(a(!0),
|
|
138
|
-
key:
|
|
149
|
+
r.label ? (a(), l("p", F, h(r.label), 1)) : p("", !0),
|
|
150
|
+
e("div", I, [
|
|
151
|
+
(a(!0), l(w, null, _(r.templates, (s) => (a(), l("button", {
|
|
152
|
+
key: s.id,
|
|
139
153
|
type: "button",
|
|
140
154
|
role: "radio",
|
|
141
|
-
"aria-checked": t.modelValue ===
|
|
155
|
+
"aria-checked": t.modelValue === s.id,
|
|
142
156
|
disabled: t.disabled,
|
|
143
|
-
class:
|
|
157
|
+
class: y([
|
|
144
158
|
"flex w-full cursor-pointer items-start gap-12 rounded-lg border p-12 text-left transition disabled:cursor-not-allowed disabled:opacity-60",
|
|
145
|
-
t.modelValue ===
|
|
159
|
+
t.modelValue === s.id ? "border-fm-color-primary bg-fm-color-primary-50" : "border-fm-color-neutral-gray-200 bg-fm-color-neutral-white hover:border-fm-color-neutral-gray-300"
|
|
146
160
|
]),
|
|
147
|
-
onClick: (
|
|
161
|
+
onClick: (G) => V(s.id)
|
|
148
162
|
}, [
|
|
149
|
-
|
|
150
|
-
class:
|
|
163
|
+
e("span", {
|
|
164
|
+
class: y([
|
|
151
165
|
"mt-[2px] flex h-16 w-16 shrink-0 items-center justify-center rounded-full border",
|
|
152
|
-
t.modelValue ===
|
|
166
|
+
t.modelValue === s.id ? "border-fm-color-primary bg-fm-color-primary" : "border-fm-color-neutral-gray-300 bg-fm-color-neutral-white"
|
|
153
167
|
])
|
|
154
168
|
}, [
|
|
155
|
-
t.modelValue ===
|
|
169
|
+
t.modelValue === s.id ? (a(), l("span", z)) : p("", !0)
|
|
156
170
|
], 2),
|
|
157
|
-
v
|
|
158
|
-
"restaurant-style":
|
|
171
|
+
b(v, {
|
|
172
|
+
"restaurant-style": s.restaurantStyle
|
|
159
173
|
}, null, 8, ["restaurant-style"]),
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
174
|
+
e("span", H, [
|
|
175
|
+
e("span", M, [
|
|
176
|
+
e("span", Q, h(s.label), 1),
|
|
177
|
+
s.default ? (a(), l("span", U, " Default ")) : p("", !0)
|
|
164
178
|
]),
|
|
165
|
-
|
|
179
|
+
e("span", W, h(s.description), 1)
|
|
166
180
|
])
|
|
167
|
-
], 10,
|
|
181
|
+
], 10, j))), 128))
|
|
168
182
|
])
|
|
169
183
|
], 2))), 128))
|
|
170
184
|
])
|
|
171
|
-
])) :
|
|
185
|
+
])) : p("", !0);
|
|
172
186
|
}
|
|
173
187
|
});
|
|
174
188
|
export {
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
189
|
+
st as _,
|
|
190
|
+
rt as a,
|
|
191
|
+
et as b,
|
|
192
|
+
O as c,
|
|
193
|
+
X as d,
|
|
194
|
+
Y as e,
|
|
195
|
+
Z as p,
|
|
196
|
+
tt as r,
|
|
197
|
+
K as s
|
|
184
198
|
};
|
|
@@ -6,7 +6,7 @@ import { D as ni, l as Ba, T as ri, e as Wc } from "./index-CIJWcl_6.js";
|
|
|
6
6
|
import { useI18n as hr, useCoreStore as Ll } from "@feedmepos/mf-common";
|
|
7
7
|
import { useDialog as xs, components as Gc, useSnackbar as Kc } from "@feedmepos/ui-library";
|
|
8
8
|
import { e as Qe, d as ar, f as Gn, c as nt, g as Jc, s as ai, C as fa, h as os, i as ja, a as Bl, j as Zc, n as Yc, k as Xc, b as Qc } from "./controlPlane-DT3t_ftg.js";
|
|
9
|
-
import { r as jl, a as eu, b as tu, s as Ua, c as qa, p as nu, _ as ru, d as au, e as su } from "./AppTemplatePicker.vue_vue_type_script_setup_true_lang-
|
|
9
|
+
import { r as jl, a as eu, b as tu, s as Ua, c as qa, p as nu, _ as ru, d as au, e as su } from "./AppTemplatePicker.vue_vue_type_script_setup_true_lang-LE_aKvfg.js";
|
|
10
10
|
import { _ as Ul, B as iu } from "./BrandFontPicker-BZyGrK3D.js";
|
|
11
11
|
import { g as lu } from "./_commonjsHelpers-DaMA6jEr.js";
|
|
12
12
|
import { _ as Ft } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
@@ -5,7 +5,7 @@ import { a as P } from "./routes-CeuodIgg.js";
|
|
|
5
5
|
import { c as $, e as z, a as Q } from "./controlPlane-DT3t_ftg.js";
|
|
6
6
|
import { u as W } from "./portalContext-B2pXdNtB.js";
|
|
7
7
|
import { w as F } from "./portalNavigation-DKCfwTH8.js";
|
|
8
|
-
import { _ as X, p as Z } from "./AppTemplatePicker.vue_vue_type_script_setup_true_lang-
|
|
8
|
+
import { _ as X, p as Z } from "./AppTemplatePicker.vue_vue_type_script_setup_true_lang-LE_aKvfg.js";
|
|
9
9
|
import { m as ee } from "./index-CIJWcl_6.js";
|
|
10
10
|
import { _ as U } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
11
11
|
import { _ as R } from "./StatusBadge.vue_vue_type_script_setup_true_lang-CMgQ0bd_.js";
|
package/dist/app.js
CHANGED
|
@@ -4,7 +4,7 @@ const o = [
|
|
|
4
4
|
path: "/platforms/mobile",
|
|
5
5
|
name: "miniprogram-v2-mobile-projects",
|
|
6
6
|
meta: { title: "Mobile" },
|
|
7
|
-
component: () => import("./MobileProjectsView-
|
|
7
|
+
component: () => import("./MobileProjectsView-BCXdpVTc.js")
|
|
8
8
|
},
|
|
9
9
|
{
|
|
10
10
|
path: "/",
|
|
@@ -21,7 +21,7 @@ const o = [
|
|
|
21
21
|
{
|
|
22
22
|
path: "/p/:projectId/:view(workspace|releases|sessions)?",
|
|
23
23
|
name: "miniprogram-v2-project",
|
|
24
|
-
component: () => import("./ControlPlaneView-
|
|
24
|
+
component: () => import("./ControlPlaneView-Bd8w7Yub.js")
|
|
25
25
|
},
|
|
26
26
|
{
|
|
27
27
|
path: "/brand-kit",
|
package/dist/package.json
CHANGED