@feedmepos/mf-menu-portal 1.0.4-dev.2 → 1.0.4-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.
- package/dist/{App-DtX4DyDA.js → App-CrpoLCjA.js} +3 -3
- package/dist/{ApplyProduct.vue_vue_type_script_setup_true_lang-C9OSr8ft.js → ApplyProduct.vue_vue_type_script_setup_true_lang-Hdsnu29V.js} +1 -1
- package/dist/{BindingTable.vue_vue_type_script_setup_true_lang-BJN8ajuD.js → BindingTable.vue_vue_type_script_setup_true_lang-D3CmOOPY.js} +1 -1
- package/dist/{Catalog-Dly_r1yA.js → Catalog-VU3HhNro.js} +4 -4
- package/dist/{CatalogBinding-CNG4YcVq.js → CatalogBinding-BNATtZEY.js} +3 -3
- package/dist/{CatalogEditTabs.vue_vue_type_script_setup_true_lang-Cy2culdR.js → CatalogEditTabs.vue_vue_type_script_setup_true_lang-BmG-xpW4.js} +3 -3
- package/dist/CatalogEditor.vue_vue_type_script_setup_true_lang-BFsRDFpj.js +784 -0
- package/dist/{CatalogLinkProductAction.vue_vue_type_script_setup_true_lang-4EZ4yM_N.js → CatalogLinkProductAction.vue_vue_type_script_setup_true_lang-Bk4FqVmx.js} +14 -14
- package/dist/{Category-Dz1yFYyY.js → Category-DMoXTsfG.js} +5 -5
- package/dist/{Category-BS-vFDYy.js → Category-DxjdQ-NN.js} +2 -2
- package/dist/CategoryList.vue_vue_type_script_setup_true_lang-B3Ts1O-9.js +847 -0
- package/dist/{CookingGuide-CmbvWFgp.js → CookingGuide-DiZZDYD-.js} +5 -5
- package/dist/{Group-B7s-vPXb.js → Group-DFR8q-tt.js} +5 -5
- package/dist/{Group-BRmWZnHh.js → Group-rzfh_o6r.js} +2 -2
- package/dist/GroupList.vue_vue_type_script_setup_true_lang-DiN-wQXX.js +1807 -0
- package/dist/Ingredient-DpjGIuH9.js +505 -0
- package/dist/LinkProductSideSheet.vue_vue_type_script_setup_true_lang-CnI80Ojd.js +782 -0
- package/dist/{MenuSetting-Ci7V_Jxn.js → MenuSetting-DR-pDSF_.js} +4 -4
- package/dist/OrderPacing-JcTuweqF.js +769 -0
- package/dist/{OrderPacingFields.vue_vue_type_script_setup_true_lang-NCH-SrZU.js → OrderPacingFields.vue_vue_type_script_setup_true_lang-HwwJ2mGv.js} +2 -2
- package/dist/{Preview-BBGNaj1F.js → Preview-BZyun5lZ.js} +1 -1
- package/dist/{PriceTierNotice.vue_vue_type_script_setup_true_lang-BXJDpDCm.js → PriceTierNotice.vue_vue_type_script_setup_true_lang-DquqNbE1.js} +1 -1
- package/dist/PrintRoute-CzEx2dCt.js +518 -0
- package/dist/{Product-DqN0NFUU.js → Product-CQb0n06E.js} +4 -4
- package/dist/ProductAttributeFilter.vue_vue_type_script_setup_true_lang-B2KdolJS.js +7931 -0
- package/dist/{ProductEditorHost.vue_vue_type_script_setup_true_lang-Fkiw4lZp.js → ProductEditorHost.vue_vue_type_script_setup_true_lang-CBlDEjqF.js} +9 -9
- package/dist/ProductGroupCreateSheet.vue_vue_type_script_setup_true_lang-D8NQTCLx.js +2011 -0
- package/dist/{ProductImageEditorDialog.vue_vue_type_script_setup_true_lang-CNWCT1OB.js → ProductImageEditorDialog.vue_vue_type_script_setup_true_lang-cG47Pu-6.js} +1 -1
- package/dist/{ProductInlineCreateHost.vue_vue_type_script_setup_true_lang-BoQ9mVPY.js → ProductInlineCreateHost.vue_vue_type_script_setup_true_lang-0UwUcA2L.js} +800 -749
- package/dist/{ProductInternalTools-CC3SWSlT.js → ProductInternalTools-QrBR1nFp.js} +2 -2
- package/dist/{ProductInventoryDialog-SAhsVekx.js → ProductInventoryDialog-fV38GO1a.js} +1 -1
- package/dist/{ProductInventoryDialog.vue_vue_type_script_setup_true_lang-BB8UIIsW.js → ProductInventoryDialog.vue_vue_type_script_setup_true_lang-Bzb3RrMg.js} +1 -1
- package/dist/ProductList.vue_vue_type_script_setup_true_lang-BwKQESr3.js +2765 -0
- package/dist/{ProductVariantTranslationSheet.vue_vue_type_script_setup_true_lang-BMDSkfcn.js → ProductVariantTranslationSheet.vue_vue_type_script_setup_true_lang-CDYcHXo1.js} +1 -1
- package/dist/{Products-Cn6j1DOQ.js → Products-B8tysOAL.js} +3 -3
- package/dist/Publish-DTvOvFNa.js +1337 -0
- package/dist/Recipe-Ddx31csF.js +388 -0
- package/dist/{Scheduler-DlaSVACJ.js → Scheduler-CST5L_cw.js} +314 -254
- package/dist/ServingSequence-DYyEZI2S.js +374 -0
- package/dist/{Setting-CyCp2uw4.js → Setting-Ip0pGjks.js} +6 -6
- package/dist/Subcategory-BIgjzVta.js +459 -0
- package/dist/{Takeaway-sVVykWDg.js → Takeaway-CekhGM-m.js} +2 -2
- package/dist/{Takeaway-tYHCAXYU.js → Takeaway-aXsPg4JT.js} +5 -5
- package/dist/{TakeawayList.vue_vue_type_script_setup_true_lang-CV24v8Zg.js → TakeawayList.vue_vue_type_script_setup_true_lang-CaRR4_j3.js} +4 -4
- package/dist/TreeEditorOpenner.vue_vue_type_script_setup_true_lang-CshqYpc9.js +1291 -0
- package/dist/Unit-BMW8u0Us.js +424 -0
- package/dist/{Variant-BNnR5rLv.js → Variant-CZsrYRMU.js} +5 -5
- package/dist/{_id_-a9ZtdjtT.js → _id_-D4swrvNa.js} +3 -3
- package/dist/{app-CmElp8cO.js → app-BWwwHsWi.js} +337 -337
- package/dist/app.js +1 -1
- package/dist/apps/mf-menu/src/app.d.ts +80 -0
- package/dist/apps/mf-menu/src/components/PriceTier/LinkPriceTierSection.vue.d.ts +9 -0
- package/dist/apps/mf-menu/src/components/Product/BulkCategorySelect.vue.d.ts +37 -0
- package/dist/apps/mf-menu/src/components/Product/ProductAttributeFilter.vue.d.ts +11 -1
- package/dist/apps/mf-menu/src/components/ProductList.vue.d.ts +2 -2
- package/dist/apps/mf-menu/src/components/feature/NestedGroupManager/NestedGroupOverrideSheets.vue.d.ts +27 -0
- package/dist/apps/mf-menu/src/components/feature/RestaurantAttributesFilter.vue.d.ts +20 -0
- package/dist/apps/mf-menu/tsconfig.app.tsbuildinfo +1 -1
- package/dist/assets/{menu-compute-B_wpWLAj.js → menu-compute-D7TdiHt4.js} +4 -4
- package/dist/assets/{validate-menu-DjxNxUxH.js → validate-menu-DXppWUVq.js} +2 -2
- package/dist/mf-menu-portal.css +1 -1
- package/dist/{provide-BJRbSauL.js → provide-CDmXzkhz.js} +67539 -65978
- package/dist/{useActionFeedback-89GwO41T.js → useActionFeedback-Dm2HDa_2.js} +1 -1
- package/dist/{FormSection.vue_vue_type_script_setup_true_lang-pY-_msnM.js → vuedraggable-CBtQLb_S.js} +140 -139
- package/package.json +2 -2
- package/dist/CatalogEditor.vue_vue_type_script_setup_true_lang-Byp1db9_.js +0 -484
- package/dist/CategoryList.vue_vue_type_script_setup_true_lang-CrHYjrTn.js +0 -797
- package/dist/GroupList.vue_vue_type_script_setup_true_lang-CWr52_a-.js +0 -2183
- package/dist/Ingredient-BMAlctE4.js +0 -463
- package/dist/LinkProductSideSheet.vue_vue_type_script_setup_true_lang-CR99740r.js +0 -709
- package/dist/OrderPacing-Bz5kn6DY.js +0 -698
- package/dist/PrintRoute-BnARWdR2.js +0 -473
- package/dist/ProductChipSummary.vue_vue_type_script_setup_true_lang-D8DygCBl.js +0 -110
- package/dist/ProductGroupCreateSheet.vue_vue_type_script_setup_true_lang-DryxrG-x.js +0 -1257
- package/dist/ProductList.vue_vue_type_script_setup_true_lang-BDnTs366.js +0 -10353
- package/dist/Publish-BPJhG39B.js +0 -1261
- package/dist/Recipe-mt1vec5-.js +0 -350
- package/dist/ServingSequence-Cr1REWZP.js +0 -336
- package/dist/Subcategory-kuB7gYvc.js +0 -412
- package/dist/TreeEditorOpenner.vue_vue_type_script_setup_true_lang-Dz-Chgek.js +0 -1213
- package/dist/Unit-BSOvZxRy.js +0 -385
- package/dist/apps/mf-menu/src/views/MenuManagementEditor/RestaurantAttributesFilter.vue.d.ts +0 -2
package/dist/Unit-BSOvZxRy.js
DELETED
|
@@ -1,385 +0,0 @@
|
|
|
1
|
-
import { defineComponent as W, computed as f, ref as me, shallowRef as G, h as re, withModifiers as de, onUnmounted as ce, resolveComponent as g, openBlock as c, createBlock as M, unref as e, withCtx as S, createElementBlock as x, toDisplayString as V, Fragment as H, createElementVNode as d, createVNode as i, createCommentVNode as U, mergeProps as $, renderList as ve } from "vue";
|
|
2
|
-
import { useI18n as pe } from "@feedmepos/mf-common";
|
|
3
|
-
import { useDialog as be, components as J, FmButtonVariant as fe } from "@feedmepos/ui-library";
|
|
4
|
-
import { _ as ye } from "./index.vue_vue_type_script_setup_true_lang-CGPDazqs.js";
|
|
5
|
-
import { _ as _e } from "./ListCountTag.vue_vue_type_script_setup_true_lang-0bjk8Aly.js";
|
|
6
|
-
import { _ as ge } from "./PageLayout.vue_vue_type_script_setup_true_lang-B3szUH39.js";
|
|
7
|
-
import { u as he } from "./useActionFeedback-89GwO41T.js";
|
|
8
|
-
import { u as ke } from "./useEditorValidation-Ctef5Bxt.js";
|
|
9
|
-
import { b as xe, u as we, a as Fe } from "./provide-BJRbSauL.js";
|
|
10
|
-
const Ce = {
|
|
11
|
-
key: 0,
|
|
12
|
-
class: "flex-1 flex justify-between gap-8 pl-8"
|
|
13
|
-
}, Se = { class: "flex items-center" }, Ve = {
|
|
14
|
-
key: 0,
|
|
15
|
-
role: "alert",
|
|
16
|
-
class: "text-fm-color-typo-secondary"
|
|
17
|
-
}, Me = {
|
|
18
|
-
key: 1,
|
|
19
|
-
class: "text-fm-color-typo-secondary"
|
|
20
|
-
}, $e = { class: "flex justify-end items-center" }, Ie = { class: "w-[320px]" }, Ne = { class: "fm-typo-en-title-md-600" }, Ue = { class: "pt-8 space-y-40" }, Ee = { class: "flex flex-row gap-16" }, je = { class: "flex justify-between items-center" }, Ae = { class: "fm-typo-en-body-md-600" }, Be = { class: "flex flex-row gap-8" }, Pe = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary" }, ze = { class: "flex gap-8 items-center justify-start" }, De = /* @__PURE__ */ W({
|
|
21
|
-
__name: "UnitList",
|
|
22
|
-
props: {
|
|
23
|
-
sdk: {}
|
|
24
|
-
},
|
|
25
|
-
setup(E) {
|
|
26
|
-
const y = E, { t } = pe(), h = xe(), j = be(), { run: A } = he(), v = we(y.sdk.unit.list), r = f(
|
|
27
|
-
() => v.value.status === "ready" ? v.value.value : null
|
|
28
|
-
), X = f(() => {
|
|
29
|
-
var a;
|
|
30
|
-
return ((a = r.value) == null ? void 0 : a.query) ?? "";
|
|
31
|
-
}), Y = f(() => {
|
|
32
|
-
var a;
|
|
33
|
-
return [...((a = r.value) == null ? void 0 : a.rows) ?? []];
|
|
34
|
-
}), p = me(!1), n = G(y.sdk.unit.editor()), w = G(
|
|
35
|
-
n.value.get()
|
|
36
|
-
);
|
|
37
|
-
let I = n.value.subscribe(
|
|
38
|
-
(a) => {
|
|
39
|
-
w.value = a;
|
|
40
|
-
}
|
|
41
|
-
);
|
|
42
|
-
const o = f(
|
|
43
|
-
() => w.value.status === "ready" ? w.value.value : null
|
|
44
|
-
), b = ke(() => n.value), B = f(
|
|
45
|
-
() => o.value ? b.issue(o.value.fieldIssues, "name") ?? o.value.nameIssue : null
|
|
46
|
-
), P = f(
|
|
47
|
-
() => o.value ? b.issue(o.value.fieldIssues, "symbol") ?? o.value.symbolIssue : null
|
|
48
|
-
);
|
|
49
|
-
function z(a) {
|
|
50
|
-
var _;
|
|
51
|
-
const l = a == null ? void 0 : a.match(/^(measurementName|measurementSymbol):(\d+)$/), u = l ? (_ = o.value) == null ? void 0 : _.measurements[Number(l[2]) - 1] : void 0;
|
|
52
|
-
return l && u ? `${l[1]}:${u.id}` : a;
|
|
53
|
-
}
|
|
54
|
-
const Z = f(
|
|
55
|
-
() => {
|
|
56
|
-
var a;
|
|
57
|
-
return Object.fromEntries(
|
|
58
|
-
Object.entries(((a = o.value) == null ? void 0 : a.fieldIssues) ?? {}).map(
|
|
59
|
-
([l, u]) => [z(l), u]
|
|
60
|
-
)
|
|
61
|
-
);
|
|
62
|
-
}
|
|
63
|
-
);
|
|
64
|
-
function D(a, l, u) {
|
|
65
|
-
const _ = b.issue(Z.value, `${l}:${a}`) ?? u;
|
|
66
|
-
return _ ? [h(_)] : [];
|
|
67
|
-
}
|
|
68
|
-
function O(a) {
|
|
69
|
-
I(), n.value.dispose(), n.value = y.sdk.unit.editor(a), w.value = n.value.get(), I = n.value.subscribe(
|
|
70
|
-
(l) => {
|
|
71
|
-
w.value = l;
|
|
72
|
-
}
|
|
73
|
-
);
|
|
74
|
-
}
|
|
75
|
-
function R() {
|
|
76
|
-
var a;
|
|
77
|
-
((a = r.value) == null ? void 0 : a.create.state) === "allowed" && (O(), p.value = !0);
|
|
78
|
-
}
|
|
79
|
-
function ee(a) {
|
|
80
|
-
O(a.id), p.value = !0;
|
|
81
|
-
}
|
|
82
|
-
async function ae() {
|
|
83
|
-
(await A(
|
|
84
|
-
() => b.submit(async () => {
|
|
85
|
-
const l = await n.value.submit();
|
|
86
|
-
return l.kind === "rejected" ? {
|
|
87
|
-
...l,
|
|
88
|
-
issues: l.issues.map((u) => ({
|
|
89
|
-
...u,
|
|
90
|
-
field: z(u.field)
|
|
91
|
-
}))
|
|
92
|
-
} : l;
|
|
93
|
-
}),
|
|
94
|
-
{
|
|
95
|
-
// `submit()` publishes `submitting` synchronously only when it will
|
|
96
|
-
// actually perform a write. A required-field rejection is decided locally
|
|
97
|
-
// and issues no request, and legacy showed no spinner for it — the frozen
|
|
98
|
-
// `unit/create/validation-rejected` and `unit/update/validation-rejected`
|
|
99
|
-
// groups record the inline message and no snackbar at all.
|
|
100
|
-
showLoading: () => {
|
|
101
|
-
var l;
|
|
102
|
-
return ((l = o.value) == null ? void 0 : l.status) === "submitting";
|
|
103
|
-
},
|
|
104
|
-
// The SDK returns the name it stored, so the toast renders the value that
|
|
105
|
-
// was actually written rather than a second trim of the draft.
|
|
106
|
-
successMessage: (l) => t("menu.unit.form.saved", { name: l.name })
|
|
107
|
-
}
|
|
108
|
-
)).kind === "success" && (p.value = !1);
|
|
109
|
-
}
|
|
110
|
-
function te() {
|
|
111
|
-
var a;
|
|
112
|
-
if (!((a = o.value) != null && a.dirty)) {
|
|
113
|
-
p.value = !1;
|
|
114
|
-
return;
|
|
115
|
-
}
|
|
116
|
-
j.open({
|
|
117
|
-
title: t("menu.common.dialog.dismiss.title"),
|
|
118
|
-
message: t("menu.common.dialog.dismiss.message"),
|
|
119
|
-
primaryActions: {
|
|
120
|
-
text: t("menu.common.dialog.dismiss.discard"),
|
|
121
|
-
close: !0
|
|
122
|
-
},
|
|
123
|
-
secondaryActions: {
|
|
124
|
-
text: t("menu.common.actions.cancel"),
|
|
125
|
-
close: !0
|
|
126
|
-
}
|
|
127
|
-
}).onPrimary(() => {
|
|
128
|
-
p.value = !1;
|
|
129
|
-
});
|
|
130
|
-
}
|
|
131
|
-
function le(a) {
|
|
132
|
-
a.remove.state === "allowed" && j.open({
|
|
133
|
-
title: t("menu.common.dialog.remove.unit.title"),
|
|
134
|
-
message: t("menu.common.dialog.remove.unit.message", {
|
|
135
|
-
name: a.name
|
|
136
|
-
}),
|
|
137
|
-
primaryActions: {
|
|
138
|
-
text: t("menu.common.actions.remove"),
|
|
139
|
-
close: !0,
|
|
140
|
-
variant: fe.Destructive
|
|
141
|
-
},
|
|
142
|
-
secondaryActions: {
|
|
143
|
-
text: t("menu.common.actions.cancel"),
|
|
144
|
-
close: !0
|
|
145
|
-
}
|
|
146
|
-
}).onPrimary(async () => {
|
|
147
|
-
await A(() => y.sdk.unit.remove(a.id), {
|
|
148
|
-
successMessage: t("menu.unit.form.removed", { name: a.name })
|
|
149
|
-
});
|
|
150
|
-
});
|
|
151
|
-
}
|
|
152
|
-
const se = f(() => [
|
|
153
|
-
{
|
|
154
|
-
accessorKey: "name",
|
|
155
|
-
header: () => t("menu.unit.columns.name"),
|
|
156
|
-
enableSorting: !1
|
|
157
|
-
},
|
|
158
|
-
{
|
|
159
|
-
accessorKey: "symbol",
|
|
160
|
-
header: () => t("menu.unit.columns.symbol"),
|
|
161
|
-
enableSorting: !1
|
|
162
|
-
},
|
|
163
|
-
{
|
|
164
|
-
id: "actions",
|
|
165
|
-
size: 52,
|
|
166
|
-
meta: { cellClass: "pl-16", headerContentClass: "-mx-16" },
|
|
167
|
-
header: "",
|
|
168
|
-
cell: (a) => re(J.FmButton, {
|
|
169
|
-
icon: "delete",
|
|
170
|
-
variant: "tertiary",
|
|
171
|
-
textColor: "neutral-gray-400",
|
|
172
|
-
disabled: a.row.original.remove.state !== "allowed",
|
|
173
|
-
"aria-label": t("menu.common.actions.delete"),
|
|
174
|
-
onClick: de(
|
|
175
|
-
() => le(a.row.original),
|
|
176
|
-
["stop", "prevent"]
|
|
177
|
-
)
|
|
178
|
-
})
|
|
179
|
-
}
|
|
180
|
-
]);
|
|
181
|
-
return ce(() => {
|
|
182
|
-
I(), n.value.dispose();
|
|
183
|
-
}), (a, l) => {
|
|
184
|
-
const u = g("FmButton"), _ = g("FmCircularProgress"), oe = g("FmSearch"), ne = g("FmTable"), F = g("FmTextField"), ue = g("FmStepperField"), ie = g("FmSideSheet");
|
|
185
|
-
return c(), M(ge, {
|
|
186
|
-
"data-visual-root": "unit",
|
|
187
|
-
heading: e(t)("menu.unit.title")
|
|
188
|
-
}, {
|
|
189
|
-
"append-heading": S(() => [
|
|
190
|
-
e(v).status === "ready" && r.value ? (c(), x("div", Ce, [
|
|
191
|
-
d("div", Se, [
|
|
192
|
-
i(_e, {
|
|
193
|
-
value: r.value.totalCount
|
|
194
|
-
}, null, 8, ["value"])
|
|
195
|
-
]),
|
|
196
|
-
r.value.totalCount > 0 ? (c(), M(u, {
|
|
197
|
-
key: 0,
|
|
198
|
-
disabled: r.value.create.state !== "allowed",
|
|
199
|
-
label: e(t)("menu.unit.add"),
|
|
200
|
-
"prepend-icon": "add",
|
|
201
|
-
onClick: R
|
|
202
|
-
}, null, 8, ["disabled", "label"])) : U("", !0)
|
|
203
|
-
])) : U("", !0)
|
|
204
|
-
]),
|
|
205
|
-
default: S(() => [
|
|
206
|
-
e(v).status === "error" ? (c(), x("p", Ve, V(e(h)(e(v).error.message)), 1)) : e(v).status === "unavailable" ? (c(), x("p", Me, V(e(h)(e(v).reason)), 1)) : e(v).status === "loading" ? (c(), M(_, { key: 2 })) : r.value && r.value.totalCount === 0 ? (c(), M(e(ye), {
|
|
207
|
-
key: 3,
|
|
208
|
-
action: { text: e(t)("menu.unit.add"), callback: R },
|
|
209
|
-
title: e(t)("menu.unit.empty.title"),
|
|
210
|
-
subtitle: e(t)("menu.unit.empty.subtitle")
|
|
211
|
-
}, null, 8, ["action", "title", "subtitle"])) : r.value ? (c(), x(H, { key: 4 }, [
|
|
212
|
-
d("div", $e, [
|
|
213
|
-
d("div", Ie, [
|
|
214
|
-
i(oe, {
|
|
215
|
-
autofocus: "",
|
|
216
|
-
class: "mb-8",
|
|
217
|
-
"model-value": X.value,
|
|
218
|
-
placeholder: e(t)("menu.unit.table.search.placeholder"),
|
|
219
|
-
"onUpdate:modelValue": y.sdk.unit.search
|
|
220
|
-
}, null, 8, ["model-value", "placeholder", "onUpdate:modelValue"])
|
|
221
|
-
])
|
|
222
|
-
]),
|
|
223
|
-
i(ne, {
|
|
224
|
-
"column-defs": se.value,
|
|
225
|
-
"hide-footer": "",
|
|
226
|
-
"page-size": Math.max(r.value.rows.length, 1),
|
|
227
|
-
"pin-header-row": "",
|
|
228
|
-
"row-data": Y.value,
|
|
229
|
-
"shrink-at": !1,
|
|
230
|
-
onRowClick: l[0] || (l[0] = (m) => ee(m.original))
|
|
231
|
-
}, null, 8, ["column-defs", "page-size", "row-data"])
|
|
232
|
-
], 64)) : U("", !0),
|
|
233
|
-
i(ie, {
|
|
234
|
-
modelValue: p.value,
|
|
235
|
-
"onUpdate:modelValue": l[4] || (l[4] = (m) => p.value = m),
|
|
236
|
-
"is-container": e(J).FmForm,
|
|
237
|
-
"is-container-props": { onValidationSuccess: ae },
|
|
238
|
-
"max-width": 560,
|
|
239
|
-
"onOn:clickedAway": te
|
|
240
|
-
}, {
|
|
241
|
-
"side-sheet-header": S(() => {
|
|
242
|
-
var m;
|
|
243
|
-
return [
|
|
244
|
-
d("p", Ne, V(((m = o.value) == null ? void 0 : m.mode) === "update" ? e(t)("menu.unit.update") : e(t)("menu.unit.add")), 1)
|
|
245
|
-
];
|
|
246
|
-
}),
|
|
247
|
-
"side-sheet-footer": S(() => {
|
|
248
|
-
var m, C;
|
|
249
|
-
return [
|
|
250
|
-
d("div", ze, [
|
|
251
|
-
i(u, {
|
|
252
|
-
disabled: ((m = o.value) == null ? void 0 : m.submit.state) !== "allowed",
|
|
253
|
-
label: ((C = o.value) == null ? void 0 : C.mode) === "update" ? e(t)("menu.common.actions.update") : e(t)("menu.common.actions.add"),
|
|
254
|
-
size: "lg",
|
|
255
|
-
type: "submit",
|
|
256
|
-
variant: "primary"
|
|
257
|
-
}, null, 8, ["disabled", "label"]),
|
|
258
|
-
i(u, {
|
|
259
|
-
label: e(t)("menu.common.actions.cancel"),
|
|
260
|
-
size: "lg",
|
|
261
|
-
variant: "tertiary",
|
|
262
|
-
onClick: l[3] || (l[3] = (N) => p.value = !1)
|
|
263
|
-
}, null, 8, ["label"])
|
|
264
|
-
])
|
|
265
|
-
];
|
|
266
|
-
}),
|
|
267
|
-
default: S(() => {
|
|
268
|
-
var m, C, N, T, L, K, q;
|
|
269
|
-
return [
|
|
270
|
-
d("div", Ue, [
|
|
271
|
-
d("div", Ee, [
|
|
272
|
-
i(F, $({
|
|
273
|
-
class: "flex-2",
|
|
274
|
-
"error-messages": B.value ? [e(h)(B.value)] : [],
|
|
275
|
-
label: e(t)("menu.unit.columns.name"),
|
|
276
|
-
"model-value": ((m = o.value) == null ? void 0 : m.name) ?? ""
|
|
277
|
-
}, e(b).field("name", n.value.setName)), null, 16, ["error-messages", "label", "model-value"]),
|
|
278
|
-
i(F, $({
|
|
279
|
-
class: "flex-1",
|
|
280
|
-
"error-messages": P.value ? [e(h)(P.value)] : [],
|
|
281
|
-
label: e(t)("menu.unit.columns.symbol"),
|
|
282
|
-
"model-value": ((C = o.value) == null ? void 0 : C.symbol) ?? ""
|
|
283
|
-
}, e(b).field("symbol", n.value.setSymbol)), null, 16, ["error-messages", "label", "model-value"])
|
|
284
|
-
]),
|
|
285
|
-
i(ue, {
|
|
286
|
-
label: e(t)("menu.unit.precision"),
|
|
287
|
-
max: (N = o.value) == null ? void 0 : N.precisionMax,
|
|
288
|
-
min: (T = o.value) == null ? void 0 : T.precisionMin,
|
|
289
|
-
"model-value": ((L = o.value) == null ? void 0 : L.precision) ?? 0,
|
|
290
|
-
placeholder: e(t)("menu.unit.precision_placeholder"),
|
|
291
|
-
step: 1,
|
|
292
|
-
"onUpdate:modelValue": l[1] || (l[1] = (s) => n.value.setPrecision(Number(s)))
|
|
293
|
-
}, null, 8, ["label", "max", "min", "model-value", "placeholder"]),
|
|
294
|
-
i(u, {
|
|
295
|
-
disabled: ((K = o.value) == null ? void 0 : K.addMeasurement.state) !== "allowed",
|
|
296
|
-
label: e(t)("menu.unit.measurement.add"),
|
|
297
|
-
variant: "secondary",
|
|
298
|
-
onClick: l[2] || (l[2] = (s) => n.value.addMeasurement())
|
|
299
|
-
}, null, 8, ["disabled", "label"]),
|
|
300
|
-
(c(!0), x(H, null, ve(((q = o.value) == null ? void 0 : q.measurements) ?? [], (s) => {
|
|
301
|
-
var Q;
|
|
302
|
-
return c(), x("div", {
|
|
303
|
-
key: s.id,
|
|
304
|
-
class: "flex flex-col gap-8"
|
|
305
|
-
}, [
|
|
306
|
-
d("div", je, [
|
|
307
|
-
d("p", Ae, V(e(t)("menu.unit.measurement.title", {
|
|
308
|
-
number: s.position
|
|
309
|
-
})), 1),
|
|
310
|
-
i(u, {
|
|
311
|
-
"aria-label": e(t)("menu.unit.measurement.remove", {
|
|
312
|
-
number: s.position
|
|
313
|
-
}),
|
|
314
|
-
disabled: s.remove.state !== "allowed",
|
|
315
|
-
icon: "delete",
|
|
316
|
-
variant: "secondary",
|
|
317
|
-
onClick: (k) => n.value.removeMeasurement(s.id)
|
|
318
|
-
}, null, 8, ["aria-label", "disabled", "onClick"])
|
|
319
|
-
]),
|
|
320
|
-
d("div", Be, [
|
|
321
|
-
i(F, $(
|
|
322
|
-
{
|
|
323
|
-
"error-messages": D(
|
|
324
|
-
s.id,
|
|
325
|
-
"measurementName",
|
|
326
|
-
s.nameIssue
|
|
327
|
-
),
|
|
328
|
-
label: e(t)("menu.unit.measurement.name"),
|
|
329
|
-
"model-value": s.name
|
|
330
|
-
},
|
|
331
|
-
{ ref_for: !0 },
|
|
332
|
-
e(b).field(
|
|
333
|
-
`measurementName:${s.id}`,
|
|
334
|
-
(k) => n.value.setMeasurementName(s.id, k)
|
|
335
|
-
)
|
|
336
|
-
), null, 16, ["error-messages", "label", "model-value"]),
|
|
337
|
-
i(F, $(
|
|
338
|
-
{
|
|
339
|
-
"error-messages": D(
|
|
340
|
-
s.id,
|
|
341
|
-
"measurementSymbol",
|
|
342
|
-
s.symbolIssue
|
|
343
|
-
),
|
|
344
|
-
label: e(t)("menu.unit.measurement.symbol"),
|
|
345
|
-
"model-value": s.symbol
|
|
346
|
-
},
|
|
347
|
-
{ ref_for: !0 },
|
|
348
|
-
e(b).field(
|
|
349
|
-
`measurementSymbol:${s.id}`,
|
|
350
|
-
(k) => n.value.setMeasurementSymbol(s.id, k)
|
|
351
|
-
)
|
|
352
|
-
), null, 16, ["error-messages", "label", "model-value"])
|
|
353
|
-
]),
|
|
354
|
-
i(F, {
|
|
355
|
-
label: e(t)("menu.unit.measurement.conversion"),
|
|
356
|
-
"model-value": s.conversion,
|
|
357
|
-
"onUpdate:modelValue": (k) => n.value.setMeasurementConversion(s.id, k)
|
|
358
|
-
}, null, 8, ["label", "model-value", "onUpdate:modelValue"]),
|
|
359
|
-
d("p", Pe, V(e(t)("menu.unit.measurement.preview_line", {
|
|
360
|
-
name: s.name,
|
|
361
|
-
value: s.conversionValue,
|
|
362
|
-
unit: ((Q = o.value) == null ? void 0 : Q.name) ?? ""
|
|
363
|
-
})), 1)
|
|
364
|
-
]);
|
|
365
|
-
}), 128))
|
|
366
|
-
])
|
|
367
|
-
];
|
|
368
|
-
}),
|
|
369
|
-
_: 1
|
|
370
|
-
}, 8, ["modelValue", "is-container", "is-container-props"])
|
|
371
|
-
]),
|
|
372
|
-
_: 1
|
|
373
|
-
}, 8, ["heading"]);
|
|
374
|
-
};
|
|
375
|
-
}
|
|
376
|
-
}), Je = /* @__PURE__ */ W({
|
|
377
|
-
__name: "Unit",
|
|
378
|
-
setup(E) {
|
|
379
|
-
const y = Fe();
|
|
380
|
-
return (t, h) => (c(), M(De, { sdk: e(y) }, null, 8, ["sdk"]));
|
|
381
|
-
}
|
|
382
|
-
});
|
|
383
|
-
export {
|
|
384
|
-
Je as default
|
|
385
|
-
};
|
package/dist/apps/mf-menu/src/views/MenuManagementEditor/RestaurantAttributesFilter.vue.d.ts
DELETED
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<{}> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
2
|
-
export default _default;
|