@feedmepos/mf-miniprogram-v2 0.2.8-dev.2 → 0.2.8-dev.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.
Files changed (33) hide show
  1. package/dist/{App-C8Vn8LvE.js → App-CFKKclWT.js} +267 -277
  2. package/dist/{BrandFontPicker-JHyoGusq.js → BrandFontPicker-VX2LAN2w.js} +1 -1
  3. package/dist/{BrandKitView-Dlt_ifI0.js → BrandKitView-CB7kcVy2.js} +2 -2
  4. package/dist/ControlPlaneView-DhAZbPoA.js +26578 -0
  5. package/dist/{EcosystemView-XP9IZ9wn.js → EcosystemView-hqiZRHIC.js} +6 -6
  6. package/dist/MobileProjectDialog-CZWx6IYl.js +430 -0
  7. package/dist/MobileProjectsView-BlQQvHCc.js +232 -0
  8. package/dist/ModuleCenterView-CY8o1GJG.js +165 -0
  9. package/dist/{ModuleDetailView-CSfMF0Uo.js → ModuleDetailView-BuZgg6e0.js} +1 -1
  10. package/dist/{PagesView-DzDqCd8N.js → PagesView-3KDcHMIh.js} +2 -2
  11. package/dist/{PlatformUnavailableView-CdHjkolw.js → PlatformUnavailableView-ChSD6P3O.js} +1 -1
  12. package/dist/{PortalSettingsView-Df5jChmi.js → PortalSettingsView-BVgkeXpL.js} +9 -9
  13. package/dist/StatusBadge.vue_vue_type_script_setup_true_lang-DMm_s9ua.js +41 -0
  14. package/dist/TemplateCenterView-UQ03rcwn.js +515 -0
  15. package/dist/{WorkspaceEntryView-DQkYJWdf.js → WorkspaceEntryView-BMrZWby1.js} +2 -2
  16. package/dist/{adminAccess-D2K-L-Vt.js → adminAccess-B8pYZwW9.js} +2 -2
  17. package/dist/app.js +12 -12
  18. package/dist/{controlPlane-sXaC6pAh.js → controlPlane-DR5ykj4d.js} +8 -8
  19. package/dist/package.json +1 -1
  20. package/dist/{portalContext-DV-6uUwp.js → portalContext-BKjPuVfn.js} +2 -2
  21. package/dist/portalNavigation-L5VwKlps.js +42 -0
  22. package/dist/{routes-CeuodIgg.js → routes-i1Lpq1LK.js} +42 -27
  23. package/dist/style.css +1 -1
  24. package/dist/{useBrandKit-CXLIXo5j.js → useBrandKit-CKn1fm2o.js} +1 -1
  25. package/dist/{useModuleCatalog-Cep-pzWO.js → useModuleCatalog-u7EWW11V.js} +2 -2
  26. package/package.json +1 -1
  27. package/dist/AppTemplatePicker.vue_vue_type_script_setup_true_lang-LE_aKvfg.js +0 -198
  28. package/dist/ControlPlaneView-qDA8RgiR.js +0 -25317
  29. package/dist/MobileProjectsView-aAyHV5G-.js +0 -333
  30. package/dist/ModuleCenterView-C6mCPATr.js +0 -147
  31. package/dist/StatusBadge.vue_vue_type_script_setup_true_lang-CMgQ0bd_.js +0 -30
  32. package/dist/TemplateCenterView-DrWImUYO.js +0 -425
  33. package/dist/portalNavigation-C29ihtq_.js +0 -38
@@ -1,333 +0,0 @@
1
- import { defineComponent as A, ref as g, onMounted as O, resolveComponent as w, openBlock as a, createBlock as S, withCtx as L, createVNode as j, createElementVNode as i, toDisplayString as V, createElementBlock as b, Fragment as E, createCommentVNode as I, computed as D, h as r, withModifiers as T, onScopeDispose as Y, createTextVNode as q, unref as B } from "vue";
2
- import { useRoute as H, useRouter as J } from "vue-router";
3
- import { components as G, useDialog as K } from "@feedmepos/ui-library";
4
- import { a as P } from "./routes-CeuodIgg.js";
5
- import { c as $, e as z, a as Q } from "./controlPlane-sXaC6pAh.js";
6
- import { u as W } from "./portalContext-DV-6uUwp.js";
7
- import { w as F } from "./portalNavigation-C29ihtq_.js";
8
- import { _ as X, p as Z } from "./AppTemplatePicker.vue_vue_type_script_setup_true_lang-LE_aKvfg.js";
9
- import { m as ee } from "./index-CIJWcl_6.js";
10
- import { _ as U } from "./_plugin-vue_export-helper-CHgC5LLL.js";
11
- import { _ as R } from "./StatusBadge.vue_vue_type_script_setup_true_lang-CMgQ0bd_.js";
12
- const te = { class: "project-dialog__body" }, oe = {
13
- key: 0,
14
- role: "status"
15
- }, ae = {
16
- key: 1,
17
- class: "portal-error",
18
- role: "alert"
19
- }, le = /* @__PURE__ */ A({
20
- __name: "MobileProjectDialog",
21
- props: {
22
- businessId: {},
23
- projectId: {},
24
- initialName: {}
25
- },
26
- emits: ["saved", "close"],
27
- setup(C, { emit: h }) {
28
- const s = C, m = h, o = g(s.initialName ?? ""), u = g(null), d = g([]), l = !s.projectId, c = g(l), n = g(!1), p = g(""), _ = ee();
29
- async function x() {
30
- var v, t;
31
- c.value = !0, p.value = "";
32
- try {
33
- const e = await $(P.appTemplates());
34
- d.value = e.templates, u.value = ((v = e.templates.find((f) => f.default)) == null ? void 0 : v.id) ?? ((t = e.templates[0]) == null ? void 0 : t.id) ?? null;
35
- } catch (e) {
36
- p.value = z(e);
37
- } finally {
38
- c.value = !1;
39
- }
40
- }
41
- async function N() {
42
- if (!(n.value || !o.value.trim() || o.value.trim().length > 120 || l && !u.value)) {
43
- n.value = !0, p.value = "";
44
- try {
45
- const v = await $(s.projectId ? P.project(s.businessId, s.projectId) : P.projects(s.businessId), {
46
- method: s.projectId ? "PATCH" : "POST",
47
- body: JSON.stringify({ name: o.value.trim(), ...s.projectId ? {} : {
48
- projectId: _,
49
- kind: "mobile",
50
- appTemplate: u.value,
51
- country: Q()
52
- } })
53
- });
54
- m("saved", v);
55
- } catch (v) {
56
- p.value = z(v);
57
- } finally {
58
- n.value = !1;
59
- }
60
- }
61
- }
62
- return O(() => {
63
- l && x();
64
- }), (v, t) => {
65
- const e = w("FmTextField"), f = w("FmButton"), M = w("FmCard"), k = w("FmForm");
66
- return a(), S(k, { onValidationSuccess: N }, {
67
- default: L(() => [
68
- j(M, { class: "project-dialog" }, {
69
- default: L(() => [
70
- i("h2", null, V(C.projectId ? "Rename project" : "New Mobile project"), 1),
71
- i("div", te, [
72
- j(e, {
73
- modelValue: o.value,
74
- "onUpdate:modelValue": t[0] || (t[0] = (y) => o.value = y),
75
- label: "Project name",
76
- placeholder: "e.g. Summer ordering",
77
- disabled: n.value,
78
- rules: [(y) => y.trim().length > 0 && y.trim().length <= 120 || "Enter a name up to 120 characters"]
79
- }, null, 8, ["modelValue", "disabled", "rules"]),
80
- l ? (a(), b(E, { key: 0 }, [
81
- c.value ? (a(), b("p", oe, "Loading templates…")) : (a(), S(X, {
82
- key: 1,
83
- templates: d.value,
84
- modelValue: u.value,
85
- "onUpdate:modelValue": t[1] || (t[1] = (y) => u.value = y),
86
- disabled: n.value
87
- }, null, 8, ["templates", "modelValue", "disabled"])),
88
- t[3] || (t[3] = i("p", { class: "project-dialog__note" }, "Start a separate app from a template. Your live app stays as it is.", -1))
89
- ], 64)) : I("", !0),
90
- p.value ? (a(), b("p", ae, V(p.value), 1)) : I("", !0),
91
- l && !d.value.length && !c.value ? (a(), S(f, {
92
- key: 2,
93
- label: "Retry loading templates",
94
- variant: "secondary",
95
- onClick: x
96
- })) : I("", !0)
97
- ]),
98
- i("footer", null, [
99
- j(f, {
100
- label: "Cancel",
101
- variant: "tertiary",
102
- disabled: n.value,
103
- onClick: t[2] || (t[2] = (y) => m("close"))
104
- }, null, 8, ["disabled"]),
105
- j(f, {
106
- label: C.projectId ? "Save" : "Create project",
107
- type: "submit",
108
- loading: n.value,
109
- disabled: c.value || !o.value.trim() || o.value.trim().length > 120 || l && !u.value
110
- }, null, 8, ["label", "loading", "disabled"])
111
- ])
112
- ]),
113
- _: 1
114
- })
115
- ]),
116
- _: 1
117
- });
118
- };
119
- }
120
- }), re = /* @__PURE__ */ U(le, [["__scopeId", "data-v-0c7183bf"]]), se = { class: "portal-page" }, ne = { class: "portal-page-inner" }, ie = { class: "portal-page-heading" }, ue = {
121
- key: 0,
122
- class: "mobile-projects__count"
123
- }, de = {
124
- key: 0,
125
- class: "portal-error",
126
- role: "alert"
127
- }, ce = {
128
- key: 1,
129
- role: "status"
130
- }, pe = {
131
- key: 2,
132
- class: "portal-empty"
133
- }, me = {
134
- key: 3,
135
- class: "rounded-2xl border border-portal-border-default bg-portal-bg-default",
136
- "aria-label": "Mobile projects"
137
- }, ve = /* @__PURE__ */ A({
138
- __name: "MobileProjectsView",
139
- setup(C) {
140
- const { FmButton: h } = G, s = W(), m = H(), o = J(), u = K(), d = g([]), l = g(!0), c = g(""), n = new AbortController();
141
- async function p() {
142
- l.value = !0, c.value = "";
143
- try {
144
- const t = await $(P.projects(s.businessId.value), {
145
- signal: n.signal
146
- });
147
- d.value = t.projects;
148
- } catch (t) {
149
- n.signal.aborted || (c.value = z(t));
150
- } finally {
151
- l.value = !1;
152
- }
153
- }
154
- function _(t) {
155
- u.open({
156
- title: t ? "Rename project" : "New Mobile project",
157
- dialogComponent: re,
158
- dialogComponentProps: {
159
- businessId: s.businessId.value,
160
- projectId: t == null ? void 0 : t.projectId,
161
- initialName: t == null ? void 0 : t.name,
162
- onClose: () => u.close(),
163
- onSaved: (e) => {
164
- u.close(), t ? p() : o.push(F(e.projectId, "workspace", m.query, { setup: !0 }));
165
- }
166
- }
167
- });
168
- }
169
- function x(t) {
170
- return new Intl.DateTimeFormat(void 0, { dateStyle: "medium", timeStyle: "short" }).format(new Date(t));
171
- }
172
- const N = D(() => [
173
- {
174
- id: "project",
175
- header: () => "Project",
176
- cell: (t) => {
177
- const e = t.row.original;
178
- return r("div", { class: "flex min-w-0 flex-col gap-2" }, [
179
- r("span", { class: "truncate fm-typo-en-body-md-600 text-portal-text-primary" }, e.name),
180
- r(
181
- "span",
182
- { class: "fm-typo-en-body-sm-400 text-portal-text-muted", title: e.projectId },
183
- `…${e.projectId.slice(-6)}`
184
- )
185
- ]);
186
- }
187
- },
188
- {
189
- id: "setup",
190
- header: () => "Setup",
191
- size: 130,
192
- enableSorting: !1,
193
- cell: (t) => r(
194
- R,
195
- { variant: t.row.original.provisioningStatus === "failed" ? "error" : "neutral", size: "sm" },
196
- () => Z(t.row.original.provisioningStatus)
197
- )
198
- },
199
- {
200
- id: "live",
201
- header: () => "Live",
202
- size: 200,
203
- enableSorting: !1,
204
- // Badges only. The muted sentence this replaces ("Unpublished release
205
- // available") was the one thing in the row set in prose, and prose in a 200px
206
- // column wraps — which is what made the cell look crowded. The state it
207
- // carried is worth keeping, so it becomes a second tag rather than going away:
208
- // it is the only place in this list that shows a merchant they have work built
209
- // and waiting to go live.
210
- //
211
- // Nothing is rendered for a project with no pending release. That is the
212
- // resting state of most rows, and a tag saying so would be back to filling the
213
- // column with "nothing happened".
214
- cell: (t) => {
215
- const e = t.row.original;
216
- return r("div", { class: "flex flex-wrap items-center gap-4" }, [
217
- // "Live project" in a column headed Live said the word twice, and cost the
218
- // width that made the line below it wrap.
219
- r(
220
- R,
221
- { variant: e.isLive ? "success" : "neutral", size: "sm" },
222
- () => e.isLive ? "Live" : "Not live"
223
- ),
224
- // `=== true` rather than truthiness: the field is optional in the contract,
225
- // and an absent value means the state is unknown, not that it is false.
226
- // This endpoint always sends a boolean, so that is a contract-level
227
- // possibility rather than one a merchant meets.
228
- e.hasUnpublishedRelease === !0 ? r(
229
- R,
230
- { variant: "warning", size: "sm", title: "A release is built and waiting to be published" },
231
- () => "Unpublished"
232
- ) : null
233
- ]);
234
- }
235
- },
236
- {
237
- id: "updatedAt",
238
- header: () => "Last edited",
239
- size: 170,
240
- enableSorting: !1,
241
- cell: (t) => r("span", { class: "fm-typo-en-body-sm-400 text-portal-text-muted" }, x(t.row.original.updatedAt))
242
- },
243
- {
244
- id: "actions",
245
- header: () => "",
246
- size: 340,
247
- enableSorting: !1,
248
- cell: (t) => {
249
- const e = t.row.original;
250
- return r("div", { class: "flex flex-wrap items-center justify-end gap-4" }, [
251
- e.provisioningStatus === "ready" ? r(h, {
252
- icon: "deployed_code",
253
- variant: "tertiary",
254
- title: "View releases",
255
- onClick: T(
256
- () => o.push(F(e.projectId, "releases", m.query)),
257
- ["stop"]
258
- )
259
- }) : null,
260
- r(h, {
261
- label: "Rename",
262
- variant: "tertiary",
263
- onClick: T(() => _(e), ["stop"])
264
- }),
265
- r(h, {
266
- label: e.provisioningStatus === "ready" ? "Open editor" : "Continue setup",
267
- variant: "secondary",
268
- onClick: T(
269
- () => o.push(F(e.projectId, "workspace", m.query)),
270
- ["stop"]
271
- )
272
- })
273
- ]);
274
- }
275
- }
276
- ]), v = D(() => !l.value && d.value.length > 0);
277
- return O(() => {
278
- if (p(), m.query.create === "1") {
279
- const { create: t, ...e } = m.query;
280
- o.replace({ query: e }), _();
281
- }
282
- }), Y(() => n.abort()), (t, e) => {
283
- const f = w("FmButton"), M = w("FmTable");
284
- return a(), b("div", se, [
285
- i("div", ne, [
286
- i("header", ie, [
287
- i("div", null, [
288
- e[4] || (e[4] = i("p", { class: "portal-eyebrow" }, "Mobile Ordering", -1)),
289
- i("h1", null, [
290
- e[3] || (e[3] = q("Projects ", -1)),
291
- l.value ? I("", !0) : (a(), b("span", ue, V(d.value.length), 1))
292
- ])
293
- ]),
294
- v.value ? (a(), S(f, {
295
- key: 0,
296
- label: "New project",
297
- icon: "add",
298
- onClick: e[0] || (e[0] = (k) => _())
299
- })) : I("", !0)
300
- ]),
301
- c.value ? (a(), b("p", de, [
302
- q(V(c.value) + " ", 1),
303
- j(f, {
304
- label: "Retry",
305
- variant: "tertiary",
306
- onClick: p
307
- })
308
- ])) : l.value ? (a(), b("p", ce, "Loading projects…")) : d.value.length ? (a(), b("section", me, [
309
- j(M, {
310
- "column-defs": N.value,
311
- "row-data": d.value,
312
- "page-size": d.value.length,
313
- "hide-footer": "",
314
- "pin-header-row": "",
315
- onRowClick: e[2] || (e[2] = (k) => B(o).push(B(F)(k.original.projectId, "workspace", B(m).query)))
316
- }, null, 8, ["column-defs", "row-data", "page-size"])
317
- ])) : (a(), b("section", pe, [
318
- e[5] || (e[5] = i("h2", null, "Your first Mobile project", -1)),
319
- e[6] || (e[6] = i("p", null, "Create an app from a template to start editing.", -1)),
320
- j(f, {
321
- label: "New project",
322
- icon: "add",
323
- onClick: e[1] || (e[1] = (k) => _())
324
- })
325
- ]))
326
- ])
327
- ]);
328
- };
329
- }
330
- }), xe = /* @__PURE__ */ U(ve, [["__scopeId", "data-v-e7f1f8c0"]]);
331
- export {
332
- xe as default
333
- };
@@ -1,147 +0,0 @@
1
- import { defineComponent as F, openBlock as e, createElementBlock as n, createElementVNode as o, toDisplayString as d, createCommentVNode as k, ref as w, computed as m, onMounted as q, resolveComponent as f, createVNode as p, unref as i, Fragment as v, renderList as b, normalizeClass as A, createBlock as y, withCtx as R } from "vue";
2
- import { useRoute as z } from "vue-router";
3
- import { _ as T } from "./_plugin-vue_export-helper-CHgC5LLL.js";
4
- import { u as D, c as G, f as K, _ as h, t as O } from "./useModuleCatalog-Cep-pzWO.js";
5
- const P = { class: "card" }, U = { class: "card__head" }, j = { class: "card__name fm-typo-en-body-md-600 text-portal-text-primary" }, H = { class: "card__version fm-typo-en-body-sm-400 text-portal-text-muted" }, J = { class: "card__description fm-typo-en-body-sm-400 text-portal-text-muted" }, Q = { class: "card__tags" }, W = { class: "card__tag card__tag--tier fm-typo-en-body-sm-600" }, X = {
6
- key: 0,
7
- class: "card__tag card__tag--slot fm-typo-en-body-sm-400"
8
- }, Y = /* @__PURE__ */ F({
9
- __name: "ModuleCard",
10
- props: {
11
- entry: {}
12
- },
13
- setup(l) {
14
- return (s, g) => (e(), n("article", P, [
15
- o("header", U, [
16
- o("h3", j, d(l.entry.name), 1),
17
- o("span", H, d(l.entry.version), 1)
18
- ]),
19
- o("p", J, d(l.entry.description || l.entry.id), 1),
20
- o("footer", Q, [
21
- o("span", W, d(l.entry.category), 1),
22
- l.entry.slot ? (e(), n("span", X, d(l.entry.slot), 1)) : k("", !0)
23
- ])
24
- ]));
25
- }
26
- }), Z = /* @__PURE__ */ T(Y, [["__scopeId", "data-v-2fbfd7b3"]]), ee = { class: "shell" }, te = { class: "centre" }, oe = { class: "centre__inner" }, ne = { class: "centre__head" }, se = {
27
- key: 0,
28
- class: "centre__filters"
29
- }, ae = { class: "centre__facet-label fm-typo-en-body-sm-600 text-portal-text-muted" }, le = { class: "centre__chips" }, re = ["aria-pressed", "onClick"], ie = {
30
- key: 1,
31
- class: "centre__note fm-typo-en-body-md-400"
32
- }, de = {
33
- key: 6,
34
- class: "centre__grid"
35
- }, ce = /* @__PURE__ */ F({
36
- __name: "ModuleCenterView",
37
- setup(l) {
38
- const s = D(), g = z(), u = w(""), c = w([]), V = m(() => G(s.entries.value ?? [])), x = m(() => K(s.entries.value ?? [], u.value, c.value)), N = m(() => u.value.trim().length > 0 || c.value.length > 0), C = m(() => {
39
- var r;
40
- return (((r = s.entries.value) == null ? void 0 : r.length) ?? 0) > 0;
41
- }), B = {
42
- tier: "Type",
43
- slot: "Slot"
44
- };
45
- function $(r) {
46
- return c.value.some((a) => a.kind === r.kind && a.value === r.value);
47
- }
48
- function L(r) {
49
- c.value = O(c.value, r);
50
- }
51
- function M() {
52
- u.value = "", c.value = [];
53
- }
54
- return q(() => s.load()), (r, a) => {
55
- const E = f("FmButton"), S = f("FmTextField"), I = f("RouterLink");
56
- return e(), n("div", ee, [
57
- o("div", te, [
58
- o("div", oe, [
59
- o("header", ne, [
60
- a[3] || (a[3] = o("div", null, [
61
- o("h2", { class: "centre__title fm-typo-en-title-sm-600 text-portal-text-primary" }, "Module library"),
62
- o("p", { class: "centre__subtitle fm-typo-en-body-md-400 text-portal-text-muted" }, " Modules the agent can put on a page. Published from the platform, not from your app. ")
63
- ], -1)),
64
- p(E, {
65
- size: "md",
66
- variant: "tertiary",
67
- icon: "refresh",
68
- onClick: a[0] || (a[0] = (t) => i(s).load(!0))
69
- })
70
- ]),
71
- C.value ? (e(), n("div", se, [
72
- p(S, {
73
- modelValue: u.value,
74
- "onUpdate:modelValue": a[1] || (a[1] = (t) => u.value = t),
75
- label: "Search",
76
- placeholder: "name, slot, or label"
77
- }, null, 8, ["modelValue"]),
78
- (e(!0), n(v, null, b(V.value, (t) => (e(), n("div", {
79
- key: t.kind,
80
- class: "centre__facet"
81
- }, [
82
- o("span", ae, d(B[t.kind]), 1),
83
- o("div", le, [
84
- (e(!0), n(v, null, b(t.values, (_) => (e(), n("button", {
85
- key: _,
86
- type: "button",
87
- class: A(["centre__chip fm-typo-en-body-sm-400", { "centre__chip--on": $({ kind: t.kind, value: _ }) }]),
88
- "aria-pressed": $({ kind: t.kind, value: _ }),
89
- onClick: (ue) => L({ kind: t.kind, value: _ })
90
- }, d(_), 11, re))), 128))
91
- ])
92
- ]))), 128)),
93
- N.value ? (e(), n("button", {
94
- key: 0,
95
- type: "button",
96
- class: "centre__clear fm-typo-en-body-sm-600",
97
- onClick: M
98
- }, " Clear filters ")) : k("", !0)
99
- ])) : k("", !0),
100
- i(s).entries.value === null ? (e(), n("p", ie, "Loading…")) : i(s).loadError.value ? (e(), y(h, {
101
- key: 2,
102
- icon: "error_outline",
103
- tone: "error",
104
- title: "Could not load the module library",
105
- message: i(s).loadError.value,
106
- "action-label": "Try again",
107
- onAction: a[2] || (a[2] = (t) => i(s).load(!0))
108
- }, null, 8, ["message"])) : i(s).unpublished.value ? (e(), y(h, {
109
- key: 3,
110
- icon: "widgets",
111
- title: "No module library has been published yet",
112
- message: "Modules are published from the platform, separately from merging them. Once one is published it appears here, and every workspace started afterwards receives it."
113
- })) : C.value ? x.value.length ? (e(), n("ul", de, [
114
- (e(!0), n(v, null, b(x.value, (t) => (e(), n("li", {
115
- key: t.id
116
- }, [
117
- p(I, {
118
- class: "centre__link",
119
- to: { name: "miniprogram-v2-module-detail", params: { name: t.name }, query: i(g).query }
120
- }, {
121
- default: R(() => [
122
- p(Z, { entry: t }, null, 8, ["entry"])
123
- ]),
124
- _: 2
125
- }, 1032, ["to"])
126
- ]))), 128))
127
- ])) : (e(), y(h, {
128
- key: 5,
129
- icon: "search_off",
130
- title: "No module matches these filters",
131
- "action-label": "Clear filters",
132
- onAction: M
133
- })) : (e(), y(h, {
134
- key: 4,
135
- icon: "widgets",
136
- title: "The module library is empty",
137
- message: "It has been published, but holds no modules. Nothing here is available to put on a page yet."
138
- }))
139
- ])
140
- ])
141
- ]);
142
- };
143
- }
144
- }), he = /* @__PURE__ */ T(ce, [["__scopeId", "data-v-644d1ae5"]]);
145
- export {
146
- he as default
147
- };
@@ -1,30 +0,0 @@
1
- import { defineComponent as p, computed as a, openBlock as c, createElementBlock as l, normalizeClass as m, renderSlot as i } from "vue";
2
- const d = /* @__PURE__ */ p({
3
- __name: "StatusBadge",
4
- props: {
5
- variant: { default: "neutral" },
6
- size: { default: "md" }
7
- },
8
- setup(e) {
9
- const o = e, t = {
10
- success: "bg-fm-color-system-success-100 text-fm-color-typo-success",
11
- warning: "bg-fm-color-system-warning-100 text-fm-color-typo-warning",
12
- error: "bg-fm-color-system-error-100 text-fm-color-typo-error",
13
- info: "bg-fm-color-system-info-100 text-fm-color-typo-info",
14
- neutral: "bg-fm-color-neutral-gray-100 text-fm-color-typo-secondary",
15
- primary: "bg-fm-color-primary text-fm-color-typo-white"
16
- }, r = {
17
- xs: "rounded-[4px] px-[4px] py-[2px] text-[10px] leading-[14px] font-medium tracking-[0.2px]",
18
- sm: "rounded-[4px] px-[6px] py-[4px] text-[12px] leading-[16px] font-medium tracking-[0.24px]",
19
- md: "rounded-full px-8 py-2 leading-[16px]"
20
- }, n = a(() => r[o.size]);
21
- return (s, x) => (c(), l("span", {
22
- class: m(["inline-flex shrink-0 items-center gap-4", [t[e.variant], n.value]])
23
- }, [
24
- i(s.$slots, "default")
25
- ], 2));
26
- }
27
- });
28
- export {
29
- d as _
30
- };