@feedmepos/mf-menu 0.32.37 → 0.32.38

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 (129) hide show
  1. package/dist/{App-Dl-BiHwh.js → App-CONXGagS.js} +5 -5
  2. package/dist/{ApplyProduct.vue_vue_type_script_setup_true_lang-Z4PgBxr3.js → ApplyProduct.vue_vue_type_script_setup_true_lang-DS_gQ7_2.js} +3 -3
  3. package/dist/{Catalog-BSZ8BAbX.js → Catalog-DqGqLNN2.js} +6 -6
  4. package/dist/Category-Brn_eOxZ.js +224 -0
  5. package/dist/{Category-bGvXpr0F.js → Category-DlvKgR7e.js} +9 -9
  6. package/dist/{CookingGuide-DijUR2JM.js → CookingGuide-DvsYJxXb.js} +4 -4
  7. package/dist/{CustomAttributeChip.vue_vue_type_script_setup_true_lang-B30t_PW1.js → CustomAttributeChip.vue_vue_type_script_setup_true_lang-CoAJkdZX.js} +1 -1
  8. package/dist/{Group-O4L3iHx0.js → Group-BTdbQ303.js} +1 -1
  9. package/dist/{Group-CrqE40ia.js → Group-CeOonB-B.js} +7 -7
  10. package/dist/{Group.vue_vue_type_script_setup_true_lang-CsM72Jnq.js → Group.vue_vue_type_script_setup_true_lang-WW3jF2A7.js} +227 -216
  11. package/dist/{GroupMarkupPriceDialog.vue_vue_type_script_setup_true_lang-BGR4kFzj.js → GroupMarkupPriceDialog.vue_vue_type_script_setup_true_lang-Btb2BTqb.js} +5 -5
  12. package/dist/{ImportProductDialog.vue_vue_type_script_setup_true_lang-wf0Wm51b.js → ImportProductDialog.vue_vue_type_script_setup_true_lang-DLswQZTA.js} +315 -315
  13. package/dist/{Ingredient-DvvuwOdH.js → Ingredient-DNVMZVrz.js} +3 -3
  14. package/dist/{InventoryBinding.vue_vue_type_script_setup_true_lang-anFCPZZD.js → InventoryBinding.vue_vue_type_script_setup_true_lang-BBjjgCDV.js} +2 -2
  15. package/dist/{LinkProductSideSheet-ImK8azTA.js → LinkProductSideSheet-1ZQVQTG_.js} +3 -3
  16. package/dist/{MenuSetting-BX0ohmwF.js → MenuSetting-CTCx0oeP.js} +5 -5
  17. package/dist/{PrintRoute-CXYZHJsf.js → PrintRoute-CZcDiXfi.js} +4 -4
  18. package/dist/{Product-BnnwL5DZ.js → Product-XtB1aNsr.js} +1 -1
  19. package/dist/{Product.vue_vue_type_script_setup_true_lang-DUBnQJZ1.js → Product.vue_vue_type_script_setup_true_lang-vf14Uzzm.js} +348 -337
  20. package/dist/{ProductInternalTools-DzRnmE1r.js → ProductInternalTools-DY1Np_PQ.js} +22 -22
  21. package/dist/{Products-CtzHONQZ.js → Products-DQorirQ3.js} +30 -30
  22. package/dist/{Publish-DmIbDy8-.js → Publish-Bv6Yiafq.js} +3 -3
  23. package/dist/{Recipe-D_0Ezt1C.js → Recipe-BDjd8TQg.js} +4 -4
  24. package/dist/{RuleView.vue_vue_type_script_setup_true_lang-DdeQnyfQ.js → RuleView.vue_vue_type_script_setup_true_lang-DLMPV1-F.js} +2 -2
  25. package/dist/{Scheduler-BgQsbdVM.js → Scheduler-XTwUJH8U.js} +3 -3
  26. package/dist/{ServingSequence-DCRzJsrs.js → ServingSequence-BujAc7xS.js} +3 -3
  27. package/dist/{Setting-CgtttPN_.js → Setting-BUovlSPt.js} +5 -5
  28. package/dist/Subcategory-BWZdguIR.js +345 -0
  29. package/dist/{Takeaway-CExKsbN5.js → Takeaway-CGGaO_dh.js} +4 -4
  30. package/dist/{Takeaway-BfcHs1we.js → Takeaway-Doy30uHo.js} +1 -1
  31. package/dist/Takeaway.vue_vue_type_script_setup_true_lang-Iy2ZwQf_.js +316 -0
  32. package/dist/{Thumbnail.vue_vue_type_script_setup_true_lang-Br279NC_.js → Thumbnail.vue_vue_type_script_setup_true_lang-CY9TyaLG.js} +4 -4
  33. package/dist/TranslationSideSheet.vue_vue_type_script_setup_true_lang-DiGAs3Gd.js +185 -0
  34. package/dist/TreeEditorOpenner.vue_vue_type_script_setup_true_lang-CZq5WTEG.js +6120 -0
  35. package/dist/{Unit-B6P_ykM-.js → Unit-Bl0DBmQ3.js} +2 -2
  36. package/dist/Variant-DgUxTOkz.js +247 -0
  37. package/dist/{_id_-D2ozS9Ck.js → _id_-BqediDNk.js} +9 -9
  38. package/dist/app-BVB_5Ks2.js +363 -0
  39. package/dist/{app-DqyNXgYz.js → app-DAPQhgfg.js} +1 -1
  40. package/dist/app.js +1 -1
  41. package/dist/apps/mf-menu/src/app.d.ts +264 -0
  42. package/dist/apps/mf-menu/src/components/ProductTranslationDialog.vue.d.ts +41 -0
  43. package/dist/apps/mf-menu/src/components/TranslationBadge.vue.d.ts +29 -0
  44. package/dist/apps/mf-menu/src/components/TranslationFieldSection.vue.d.ts +39 -0
  45. package/dist/apps/mf-menu/src/components/TranslationSideSheet.vue.d.ts +23 -0
  46. package/dist/apps/mf-menu/src/components/feature/ApplyProduct/ApplyProduct.vue.d.ts +12 -0
  47. package/dist/apps/mf-menu/src/components/feature/ApplyProduct/ApplyProductDialog.vue.d.ts +6 -0
  48. package/dist/apps/mf-menu/src/components/feature/ApplyProduct/index.d.ts +54 -0
  49. package/dist/apps/mf-menu/src/components/feature/CategoryManager/Form.vue.d.ts +1 -0
  50. package/dist/apps/mf-menu/src/components/feature/Fields/ImageDropField.vue.d.ts +1 -0
  51. package/dist/apps/mf-menu/src/components/feature/GroupManager/OptionTable.vue.d.ts +16 -0
  52. package/dist/apps/mf-menu/src/components/feature/GroupManager/ProductOverrideTranslation.vue.d.ts +22 -0
  53. package/dist/apps/mf-menu/src/components/feature/GroupManager/UpdateForm.vue.d.ts +6 -0
  54. package/dist/apps/mf-menu/src/components/feature/PriceTier/PriceTierButton.vue.d.ts +20 -0
  55. package/dist/apps/mf-menu/src/components/feature/PriceTier/PriceTierForm.vue.d.ts +20 -0
  56. package/dist/apps/mf-menu/src/components/feature/TreeEditor/composable/category.d.ts +8 -2
  57. package/dist/apps/mf-menu/src/components/feature/TreeEditor/composable/item.d.ts +24 -1
  58. package/dist/apps/mf-menu/src/components/feature/TreeEditor/composable/scheduler.d.ts +16 -0
  59. package/dist/apps/mf-menu/src/components/feature/TreeEditor/composable/useItemFormManagement.d.ts +10 -0
  60. package/dist/apps/mf-menu/src/components/feature/TreeEditor/form/GroupManager/OptionTable.vue.d.ts +16 -0
  61. package/dist/apps/mf-menu/src/components/feature/TreeEditor/form/GroupManager/UpdateForm.vue.d.ts +6 -0
  62. package/dist/apps/mf-menu/src/components/feature/TreeEditor/form/GroupManager/index.d.ts +24 -0
  63. package/dist/apps/mf-menu/src/components/feature/TreeEditor/item/ItemForm.vue.d.ts +30 -0
  64. package/dist/apps/mf-menu/src/components/feature/TreeEditor/menuUtils.d.ts +10 -0
  65. package/dist/apps/mf-menu/src/components/feature/TreeEditor/store/menuV2.d.ts +125 -1
  66. package/dist/apps/mf-menu/src/components/feature/VariantManager/ProductVariantTranslation.vue.d.ts +37 -0
  67. package/dist/apps/mf-menu/src/components/import/PreviewAddonContent.vue.d.ts +20 -0
  68. package/dist/apps/mf-menu/src/composable/linkProducts.d.ts +16 -0
  69. package/dist/apps/mf-menu/src/helper/item.d.ts +1 -0
  70. package/dist/apps/mf-menu/src/helper/itemCategories.d.ts +10 -0
  71. package/dist/apps/mf-menu/src/helper/menu.d.ts +11 -0
  72. package/dist/apps/mf-menu/src/helper/menuImport.d.ts +125 -1
  73. package/dist/apps/mf-menu/src/helper/menuSanitizer.d.ts +125 -1
  74. package/dist/apps/mf-menu/src/manager/menu/category.d.ts +8 -2
  75. package/dist/apps/mf-menu/src/manager/menu/group.d.ts +1 -0
  76. package/dist/apps/mf-menu/src/manager/menu/item.d.ts +125 -1
  77. package/dist/apps/mf-menu/src/manager/menu/subcategory.d.ts +6 -0
  78. package/dist/apps/mf-menu/src/stores/manager/item.d.ts +31 -1
  79. package/dist/apps/mf-menu/src/stores/manager/scheduler.d.ts +16 -0
  80. package/dist/apps/mf-menu/src/stores/manager/takeaway.d.ts +9 -0
  81. package/dist/apps/mf-menu/src/stores/menu.d.ts +125 -1
  82. package/dist/apps/mf-menu/src/utils/translation.d.ts +2 -0
  83. package/dist/apps/mf-menu/src/views/Catalog/Edit/AddCategoryDialogContentComponent.vue.d.ts +1 -0
  84. package/dist/apps/mf-menu/src/views/Catalog/Edit/AddProductPopup/Form.vue.d.ts +20 -0
  85. package/dist/apps/mf-menu/src/views/Publish/UpdateCatalogDialog.vue.d.ts +46 -0
  86. package/dist/apps/mf-menu/src/views/Scheduler/FilterForm.vue.d.ts +10 -0
  87. package/dist/apps/mf-menu/src/views/Scheduler/SchedulerDialog.vue.d.ts +10 -0
  88. package/dist/apps/mf-menu/tsconfig.app.tsbuildinfo +1 -1
  89. package/dist/assets/linked-status-CupfG8qX.js +13 -0
  90. package/dist/assets/menu-export-CL6U9A01.js +107 -0
  91. package/dist/assets/override-menu-K_rFGpIx.js +13 -0
  92. package/dist/assets/validate-menu-Dr7DxB6L.js +13 -0
  93. package/dist/{catalog-CFKVaXk7.js → catalog-8-hugI0j.js} +1 -1
  94. package/dist/{catalogSetting-N4nT-nGm.js → catalogSetting-BWa1ZTnY.js} +1 -1
  95. package/dist/{currency-Bi_GukGE.js → currency-B59CBSWJ.js} +1 -1
  96. package/dist/dayjs.min-D1xLv5bP.js +6 -0
  97. package/dist/index-ChzxrjXq.js +539 -0
  98. package/dist/index-DIXBx1sl.js +335 -0
  99. package/dist/{index-uiJS0BKT.js → index-wA29dyse.js} +1 -1
  100. package/dist/{index.vue_vue_type_script_setup_true_lang-CL6a622s.js → index.vue_vue_type_script_setup_true_lang-CZJpW7cW.js} +18104 -17902
  101. package/dist/item-Fu9YmyOy.js +8117 -0
  102. package/dist/{jszip.min-v__o3BM4.js → jszip.min-qs5Z6KRL.js} +383 -383
  103. package/dist/{menu-LtIuM7Qj.js → menu-CoqhBDql.js} +1 -1
  104. package/dist/{menuV2-N0hB53Gw.js → menuV2-CnCDR__p.js} +125 -125
  105. package/dist/mf-menu.css +1 -1
  106. package/dist/{priceTier-DZeAvlXs.js → priceTier-BvG_RNTn.js} +1 -1
  107. package/dist/rules-Av0lxCL-.js +212 -0
  108. package/dist/{scheduler-FVlscyjB.js → scheduler-CrvDOlmc.js} +4 -4
  109. package/dist/{toExcel-DBCbupeI.js → toExcel-CnzBt_4W.js} +2 -2
  110. package/dist/translation-BeqjfyEb.js +75 -0
  111. package/dist/{unit-DNphv-4C.js → unit-h28_cadr.js} +2 -2
  112. package/package.json +3 -3
  113. package/dist/Category-DMgNea31.js +0 -392
  114. package/dist/Subcategory-6SgvwWpX.js +0 -280
  115. package/dist/Takeaway.vue_vue_type_script_setup_true_lang-GAZ3S2_n.js +0 -305
  116. package/dist/TreeEditorOpenner.vue_vue_type_script_setup_true_lang-BFwMfAlB.js +0 -6024
  117. package/dist/Variant-DmNuLi96.js +0 -230
  118. package/dist/app-CE0yoao0.js +0 -363
  119. package/dist/assets/linked-status-BB6BrSUB.js +0 -13
  120. package/dist/assets/menu-export-C1TBcoi-.js +0 -107
  121. package/dist/assets/override-menu-C0RijOOI.js +0 -13
  122. package/dist/assets/validate-menu-9VpR7oZY.js +0 -13
  123. package/dist/category-BSGaVgyv.js +0 -156
  124. package/dist/dayjs.min-DgXlcVSD.js +0 -6
  125. package/dist/index-BaxQ5Nq0.js +0 -273
  126. package/dist/index-Bun2EboK.js +0 -239
  127. package/dist/item-DPivBmJh.js +0 -6950
  128. package/dist/rules-CIWTZQfh.js +0 -6
  129. package/dist/subcategory-CIctYwBF.js +0 -148
@@ -1,50 +1,51 @@
1
- import { defineComponent as X, computed as g, resolveComponent as M, createBlock as I, openBlock as m, withCtx as x, createElementBlock as C, Fragment as T, renderList as oe, createElementVNode as d, normalizeClass as W, toDisplayString as G, createVNode as s, ref as E, renderSlot as Ne, unref as r, createCommentVNode as U, watch as Re, h as pe, mergeProps as Ee, createSlots as Se, withModifiers as Ue, isRef as J, nextTick as fe } from "vue";
2
- import { J as H, u as ne, Q as Ie, G as Te, A as v, D as $e, a5 as Ye, B as Le, M as ze } from "./index.vue_vue_type_script_setup_true_lang-CL6a622s.js";
3
- import { d as Be } from "./vuedraggable-CK8z7qA8.js";
4
- import { b as ve, H as je } from "./app-5fxKLAzS.js";
5
- import { useI18n as le, useCoreStore as Ke, useCustomAttributes as He } from "@feedmepos/mf-common";
1
+ import { defineComponent as Z, computed as g, resolveComponent as M, createBlock as U, openBlock as m, withCtx as D, createElementBlock as C, Fragment as T, renderList as ne, createElementVNode as p, normalizeClass as X, toDisplayString as G, createVNode as i, ref as R, renderSlot as Ne, unref as r, createCommentVNode as I, watch as Ee, h as H, mergeProps as Re, createSlots as Se, withModifiers as Ie, isRef as W, nextTick as fe } from "vue";
2
+ import { J as q, u as le, Q as Ue, G as Te, A as v, D as $e, a4 as Ye, B as Le, M as ze } from "./index.vue_vue_type_script_setup_true_lang-CZJpW7cW.js";
3
+ import { d as je } from "./vuedraggable-CK8z7qA8.js";
4
+ import { b as ve, H as Be } from "./app-5fxKLAzS.js";
5
+ import { useI18n as ae, useCoreStore as Ke, useCustomAttributes as He } from "@feedmepos/mf-common";
6
6
  import { useBreakpoints as ye, components as _e, useSnackbar as qe, useDialog as Qe, FmButtonVariant as Je } from "@feedmepos/ui-library";
7
- import { _ as We, a as Xe } from "./CustomAttributeChip.vue_vue_type_script_setup_true_lang-B30t_PW1.js";
8
- import { _ as Ze } from "./app-CE0yoao0.js";
7
+ import { _ as We, a as Xe } from "./CustomAttributeChip.vue_vue_type_script_setup_true_lang-CoAJkdZX.js";
8
+ import { _ as Ze } from "./app-BVB_5Ks2.js";
9
9
  import { _ as et, a as tt } from "./BottomSheetMenuItem.vue_vue_type_script_setup_true_lang-DhrXKy3b.js";
10
10
  import { c as ot } from "./object-DVUNCr7w.js";
11
11
  import { u as nt } from "./discardConfirm-BHni0LNu.js";
12
- import { _ as lt } from "./ApplyProduct.vue_vue_type_script_setup_true_lang-Z4PgBxr3.js";
12
+ import { _ as lt } from "./ApplyProduct.vue_vue_type_script_setup_true_lang-DS_gQ7_2.js";
13
13
  import { c as at } from "./check-C9mY6LiX.js";
14
- import { M as ge, x as rt, y as ut, A as st, e as it, i as ct, r as mt } from "./item-DPivBmJh.js";
15
- import { u as dt } from "./search-BAPEUu1R.js";
16
- import { C as pt } from "./catalog-CFKVaXk7.js";
17
- import { c as ft } from "./menuV2-N0hB53Gw.js";
18
- const vt = /* @__PURE__ */ X({
14
+ import { M as ge, D as rt, E as ut, B as st, j as it, l as ct, r as mt } from "./item-Fu9YmyOy.js";
15
+ import { u as pt } from "./search-BAPEUu1R.js";
16
+ import { C as dt } from "./catalog-8-hugI0j.js";
17
+ import { c as ft } from "./menuV2-CnCDR__p.js";
18
+ import { g as vt } from "./translation-BeqjfyEb.js";
19
+ const gt = /* @__PURE__ */ Z({
19
20
  __name: "ResponsiveContextMenu",
20
21
  props: {
21
22
  items: {}
22
23
  },
23
24
  setup(L) {
24
25
  const S = ye(), u = g(() => S.breakpoints.value.xs);
25
- return (R, V) => {
26
+ return (E, V) => {
26
27
  const k = M("FmButton"), f = M("FmMenuItem"), y = M("FmMenu");
27
- return u.value ? (m(), I(et, { key: 0 }, {
28
- default: x(() => [
29
- (m(!0), C(T, null, oe(R.items, ({ icon: h, label: D, disabled: w, itemClass: A, onClick: _ }) => (m(), I(tt, {
30
- key: D,
28
+ return u.value ? (m(), U(et, { key: 0 }, {
29
+ default: D(() => [
30
+ (m(!0), C(T, null, ne(E.items, ({ icon: h, label: A, disabled: x, itemClass: F, onClick: _ }) => (m(), U(tt, {
31
+ key: A,
31
32
  icon: h,
32
- label: D,
33
- disabled: w,
34
- itemClass: A,
33
+ label: A,
34
+ disabled: x,
35
+ itemClass: F,
35
36
  onClick: () => {
36
- !w && (_ == null || _());
37
+ !x && (_ == null || _());
37
38
  }
38
39
  }, null, 8, ["icon", "label", "disabled", "itemClass", "onClick"]))), 128))
39
40
  ]),
40
41
  _: 1
41
- })) : (m(), I(y, {
42
+ })) : (m(), U(y, {
42
43
  key: 1,
43
44
  "stop-click-propagation": "",
44
45
  shift: !0
45
46
  }, {
46
- "menu-button": x(() => [
47
- s(k, {
47
+ "menu-button": D(() => [
48
+ i(k, {
48
49
  type: "button",
49
50
  variant: "tertiary",
50
51
  icon: "more_vert",
@@ -52,19 +53,19 @@ const vt = /* @__PURE__ */ X({
52
53
  size: "md"
53
54
  })
54
55
  ]),
55
- default: x(() => [
56
- (m(!0), C(T, null, oe(R.items, ({ icon: h, label: D, disabled: w, itemClass: A, onClick: _ }) => (m(), I(f, {
57
- key: D,
58
- disabled: w,
56
+ default: D(() => [
57
+ (m(!0), C(T, null, ne(E.items, ({ icon: h, label: A, disabled: x, itemClass: F, onClick: _ }) => (m(), U(f, {
58
+ key: A,
59
+ disabled: x,
59
60
  onClick: () => {
60
- !w && (_ == null || _());
61
+ !x && (_ == null || _());
61
62
  },
62
- label: D
63
+ label: A
63
64
  }, {
64
- label: x(() => [
65
- d("span", {
66
- class: W(w ? "text-fm-color-typo-disabled" : A)
67
- }, G(D), 3)
65
+ label: D(() => [
66
+ p("span", {
67
+ class: X(x ? "text-fm-color-typo-disabled" : F)
68
+ }, G(A), 3)
68
69
  ]),
69
70
  _: 2
70
71
  }, 1032, ["disabled", "onClick", "label"]))), 128))
@@ -73,7 +74,7 @@ const vt = /* @__PURE__ */ X({
73
74
  }));
74
75
  };
75
76
  }
76
- }), gt = { class: "fm-typo-en-title-md-600" }, yt = { class: "flex gap-8 items-center justify-start" }, _t = /* @__PURE__ */ X({
77
+ }), yt = { class: "fm-typo-en-title-md-600" }, _t = { class: "flex gap-8 items-center justify-start" }, bt = /* @__PURE__ */ Z({
77
78
  __name: "ApplyProductDialog",
78
79
  props: {
79
80
  title: {},
@@ -83,57 +84,57 @@ const vt = /* @__PURE__ */ X({
83
84
  },
84
85
  emits: ["apply:product"],
85
86
  setup(L, { emit: S }) {
86
- const u = L, R = S, { t: V } = le(), k = u.initialValue.map((A) => ({ _id: A })), f = E(H.clone(k)), y = nt(
87
- () => !H.isEqual(f.value, k),
87
+ const u = L, E = S, { t: V } = ae(), k = u.initialValue.map((F) => ({ _id: F })), f = R(q.clone(k)), y = nt(
88
+ () => !q.isEqual(f.value, k),
88
89
  () => {
89
90
  h.value = !1;
90
91
  }
91
- ), h = E(!1), D = (A) => {
92
- at.isBoolean(A) ? h.value = A : h.value = !h.value, h.value && (f.value = u.initialValue.map((_) => ({ _id: _ })));
93
- }, w = ne();
94
- return (A, _) => {
95
- const b = M("fm-button"), q = M("fm-side-sheet");
92
+ ), h = R(!1), A = (F) => {
93
+ at.isBoolean(F) ? h.value = F : h.value = !h.value, h.value && (f.value = u.initialValue.map((_) => ({ _id: _ })));
94
+ }, x = le();
95
+ return (F, _) => {
96
+ const b = M("fm-button"), Q = M("fm-side-sheet");
96
97
  return m(), C(T, null, [
97
- Ne(A.$slots, "default", { trigger: D }),
98
- s(q, {
98
+ Ne(F.$slots, "default", { trigger: A }),
99
+ i(Q, {
99
100
  id: "group-form",
100
101
  modelValue: h.value,
101
102
  "onUpdate:modelValue": _[1] || (_[1] = (N) => h.value = N),
102
103
  "is-container": r(_e).FmForm,
103
104
  "is-container-props": {
104
105
  onValidationSuccess: () => {
105
- R("apply:product", f.value), D(!1);
106
+ E("apply:product", f.value), A(!1);
106
107
  },
107
108
  blameFormChildOnValidationFailed: !0
108
109
  },
109
110
  "max-width": 560,
110
111
  "onOn:clickedAway": r(y)
111
112
  }, {
112
- "side-sheet-header": x(() => [
113
- d("p", gt, G(A.title), 1)
113
+ "side-sheet-header": D(() => [
114
+ p("p", yt, G(F.title), 1)
114
115
  ]),
115
- "side-sheet-footer": x(() => [
116
- d("div", yt, [
117
- s(b, {
116
+ "side-sheet-footer": D(() => [
117
+ p("div", _t, [
118
+ i(b, {
118
119
  label: r(V)("common.save"),
119
120
  size: "lg",
120
121
  type: "submit",
121
122
  variant: "primary"
122
123
  }, null, 8, ["label"]),
123
- s(b, {
124
+ i(b, {
124
125
  label: "Cancel",
125
126
  size: "lg",
126
127
  variant: "tertiary",
127
- onClick: D
128
+ onClick: A
128
129
  })
129
130
  ])
130
131
  ]),
131
- default: x(() => [
132
- s(lt, {
132
+ default: D(() => [
133
+ i(lt, {
133
134
  overrides: f.value,
134
135
  "onUpdate:overrides": _[0] || (_[0] = (N) => f.value = N),
135
- "categorized-items": r(w).categorizedItems,
136
- editable: A.editable,
136
+ "categorized-items": r(x).categorizedItems,
137
+ editable: F.editable,
137
138
  "select-variant": !1,
138
139
  "show-variant": !1,
139
140
  "link-button-label": r(V)("menu.group.actions.apply_product"),
@@ -145,125 +146,125 @@ const vt = /* @__PURE__ */ X({
145
146
  ], 64);
146
147
  };
147
148
  }
148
- }), bt = {
149
+ }), kt = {
149
150
  key: 0,
150
151
  class: "mt-4"
151
- }, kt = { class: "text-fm-color-typo-secondary mb-2" }, ht = { class: "list-disc list-inside text-fm-color-typo-secondary ml-4 space-y-1" }, Ct = /* @__PURE__ */ X({
152
+ }, ht = { class: "text-fm-color-typo-secondary mb-2" }, wt = { class: "list-disc list-inside text-fm-color-typo-secondary ml-4 space-y-1" }, Ct = /* @__PURE__ */ Z({
152
153
  __name: "DeleteGroupDialog",
153
154
  props: {
154
155
  group: {}
155
156
  },
156
157
  setup(L) {
157
- const S = L, { t: u } = le(), R = ne(), V = g(() => S.group.itemsLinked.map((k) => {
158
- const f = R.state.menu.modules.item.find((y) => y._id === k);
158
+ const S = L, { t: u } = ae(), E = le(), V = g(() => S.group.itemsLinked.map((k) => {
159
+ const f = E.state.menu.modules.item.find((y) => y._id === k);
159
160
  return (f == null ? void 0 : f.name) || k;
160
161
  }).filter(Boolean));
161
162
  return (k, f) => (m(), C("div", null, [
162
- d("div", null, G(r(u)("menu.group.dialogs.delete.message", { name: k.group.name })), 1),
163
- V.value.length > 0 ? (m(), C("div", bt, [
164
- d("div", kt, G(r(u)("menu.group.dialogs.delete.unlink_warning", { count: V.value.length })), 1),
165
- d("ul", ht, [
166
- (m(!0), C(T, null, oe(V.value, (y) => (m(), C("li", {
163
+ p("div", null, G(r(u)("menu.group.dialogs.delete.message", { name: k.group.name })), 1),
164
+ V.value.length > 0 ? (m(), C("div", kt, [
165
+ p("div", ht, G(r(u)("menu.group.dialogs.delete.unlink_warning", { count: V.value.length })), 1),
166
+ p("ul", wt, [
167
+ (m(!0), C(T, null, ne(V.value, (y) => (m(), C("li", {
167
168
  key: y,
168
169
  class: "text-sm"
169
170
  }, G(y), 1))), 128))
170
171
  ])
171
- ])) : U("", !0)
172
+ ])) : I("", !0)
172
173
  ]));
173
174
  }
174
- }), wt = {
175
+ }), xt = {
175
176
  key: 1,
176
177
  class: "xs:pt-24"
177
178
  }, Ot = {
178
179
  key: 0,
179
- class: /* @__PURE__ */ W(["flex-1 overflow-hidden", "space-y-8", "flex flex-col", "overflow-hidden", "pt-16"])
180
- }, xt = {
181
- class: "flex justify-between items-center space-x-8"
180
+ class: /* @__PURE__ */ X(["flex-1 overflow-hidden", "space-y-8", "flex flex-col", "overflow-hidden", "pt-16"])
182
181
  }, Dt = {
183
- class: "w-[320px]"
182
+ class: "flex justify-between items-center space-x-8"
184
183
  }, At = {
185
- key: 0
184
+ class: "w-[320px]"
186
185
  }, Ft = {
187
- class: "px-16 py-8"
186
+ key: 0
188
187
  }, Mt = {
189
- class: "py-8 px-16"
188
+ class: "px-16 py-8"
190
189
  }, Gt = {
190
+ class: "py-8 px-16"
191
+ }, Pt = {
191
192
  key: 0,
192
193
  class: "px-16 py-8"
193
- }, Pt = {
194
- class: "flex items-center flex-1"
195
194
  }, Vt = {
196
- class: "flex-1 space-y-4"
195
+ class: "flex items-center flex-1"
197
196
  }, Nt = {
197
+ class: "flex-1 space-y-4"
198
+ }, Et = {
198
199
  class: "fm-typo-en-body-lg-600"
199
200
  }, Rt = {
200
201
  key: 0,
201
202
  class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary"
202
- }, Et = {
203
+ }, St = {
203
204
  class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary"
204
- }, Zt = /* @__PURE__ */ X({
205
+ }, to = /* @__PURE__ */ Z({
205
206
  __name: "Group",
206
207
  emits: ["update:count"],
207
208
  setup(L, {
208
209
  emit: S
209
210
  }) {
210
- const u = ne(), R = Ke(), V = qe(), k = Ie(Te(V)), f = Qe(), y = g(() => u.rules.group), h = g(() => new ge(u, k.updateMenu, f)), D = g(() => h.value.mapGroups(u.groups, !1)), {
211
- searchKey: w,
212
- filter: A
213
- } = dt(), _ = E(!1), b = E(null), {
214
- attributes: q,
211
+ const u = le(), E = Ke(), V = qe(), k = Ue(Te(V)), f = Qe(), y = g(() => u.rules.group), h = g(() => new ge(u, k.updateMenu, f)), A = g(() => h.value.mapGroups(u.groups, !1)), {
212
+ searchKey: x,
213
+ filter: F
214
+ } = pt(), _ = R(!1), b = R(null), {
215
+ attributes: Q,
215
216
  filterRule: N,
216
- mongoQuery: ae
217
+ mongoQuery: re
217
218
  } = He({
218
- valueSource: D,
219
+ valueSource: A,
219
220
  entity: "group"
220
221
  }), z = g(() => {
221
- const t = (a) => A([a.name, ...Object.values(a.items).flatMap((n) => `${n.code} ${n.name ?? n.fallbackName} ${Le.Dinero.fromFdoDinero(n.price).toFormat()}`), a.type]), e = (a) => !a.customAttributes && !ae.value ? !0 : je(a.customAttributes ?? {}, ae.value);
222
- return D.value.filter((a) => t(a) && e(a)).filter((a) => !b.value || a.type === b.value);
222
+ const t = (a) => F([a.name, ...Object.values(a.items).flatMap((n) => `${n.code} ${n.name ?? n.fallbackName} ${Le.Dinero.fromFdoDinero(n.price).toFormat()}`), a.type]), e = (a) => !a.customAttributes && !re.value ? !0 : Be(a.customAttributes ?? {}, re.value);
223
+ return A.value.filter((a) => t(a) && e(a)).filter((a) => !b.value || a.type === b.value);
223
224
  }), be = S;
224
- Re(() => z.value.length, () => {
225
+ Ee(() => z.value.length, () => {
225
226
  be("update:count", z.value.length);
226
227
  }, {
227
228
  immediate: !0
228
229
  });
229
230
  const c = g(() => !!u.state.currentCatalogId || !!u.state.currentSchedulerId);
230
- function re(t) {
231
+ function ue(t) {
231
232
  var Y, o;
232
- const e = !u.state.currentCatalogId, a = !u.state.currentSchedulerId, n = ((Y = u.currentCatalog) == null ? void 0 : Y.priceTierRules) ?? ((o = u.currentCatalog) == null ? void 0 : o.usePriceTiers), i = u.rules.item.bindToVariant, F = u.rules.group.type, p = u.version === v.F_MENU_VERSION.enum.v3, P = u.rules.item.orderFromActiveOnly;
233
+ const e = !u.state.currentCatalogId, a = !u.state.currentSchedulerId, n = ((Y = u.currentCatalog) == null ? void 0 : Y.priceTierRules) ?? ((o = u.currentCatalog) == null ? void 0 : o.usePriceTiers), s = u.rules.item.bindToVariant, w = u.rules.group.type, d = u.version === v.F_MENU_VERSION.enum.v3, P = u.rules.item.orderFromActiveOnly;
233
234
  return {
234
- link: (O) => !c.value && (!O || i),
235
+ link: (O) => !c.value && (!O || s),
235
236
  name: (O) => !c.value && !O,
236
237
  isDefault: (O) => !c.value,
237
- type: F && !t._id && !c.value,
238
- price: !p || t.type !== v.F_ADDON_GROUP_TYPE.enum.DYNAMIC,
239
- priceEdit: !(n && n.length > 0 && !p && a),
240
- priceTier: !p && a && e,
241
- inventory: a ? p ? !c.value && t.type === v.F_ADDON_GROUP_TYPE.enum.NORMAL : !c.value : !1,
242
- orderFrom: (O) => a ? p ? t.type === v.F_ADDON_GROUP_TYPE.enum.DYNAMIC ? c.value : !!c.value == !O : c.value : !1,
238
+ type: w && !t._id && !c.value,
239
+ price: !d || t.type !== v.F_ADDON_GROUP_TYPE.enum.DYNAMIC,
240
+ priceEdit: !(n && n.length > 0 && !d && a),
241
+ priceTier: !d && a && e,
242
+ inventory: a ? d ? !c.value && t.type === v.F_ADDON_GROUP_TYPE.enum.NORMAL : !c.value : !1,
243
+ orderFrom: (O) => a ? d ? t.type === v.F_ADDON_GROUP_TYPE.enum.DYNAMIC ? c.value : !!c.value == !O : c.value : !1,
243
244
  orderFromActiveOnly: P,
244
- showOrderFrom: a ? p ? c.value ? !0 : t.type === v.F_ADDON_GROUP_TYPE.enum.PRODUCT : !0 : !1,
245
- bindToVariant: i,
245
+ showOrderFrom: a ? d ? c.value ? !0 : t.type === v.F_ADDON_GROUP_TYPE.enum.PRODUCT : !0 : !1,
246
+ bindToVariant: s,
246
247
  isOverride: c.value,
247
248
  isItemGroup: !1,
248
- isV4: !p
249
+ isV4: !d
249
250
  };
250
251
  }
251
252
  const ke = g(() => {
252
- const t = !u.state.currentSchedulerId, e = u.rules.group.type, a = u.version === v.F_MENU_VERSION.enum.v3, n = u.rules.item.orderFromActiveOnly, i = u.rules.item.bindToVariant;
253
- return function(p) {
253
+ const t = !u.state.currentSchedulerId, e = u.rules.group.type, a = u.version === v.F_MENU_VERSION.enum.v3, n = u.rules.item.orderFromActiveOnly, s = u.rules.item.bindToVariant;
254
+ return function(d) {
254
255
  return {
255
- link: (P) => !c.value && (!P || i),
256
+ link: (P) => !c.value && (!P || s),
256
257
  name: (P) => !c.value && !P,
257
258
  isDefault: (P) => !c.value,
258
- type: e && !p._id && !c.value,
259
- price: p.type !== v.F_ADDON_GROUP_TYPE.enum.DYNAMIC,
259
+ type: e && !d._id && !c.value,
260
+ price: d.type !== v.F_ADDON_GROUP_TYPE.enum.DYNAMIC,
260
261
  priceEdit: !0,
261
262
  priceTier: u.isV4,
262
- inventory: t ? a ? !c.value && p.type === v.F_ADDON_GROUP_TYPE.enum.NORMAL : !c.value : !1,
263
- orderFrom: (P) => t ? a ? p.type === v.F_ADDON_GROUP_TYPE.enum.DYNAMIC ? c.value : !!c.value == !P : c.value : !1,
263
+ inventory: t ? a ? !c.value && d.type === v.F_ADDON_GROUP_TYPE.enum.NORMAL : !c.value : !1,
264
+ orderFrom: (P) => t ? a ? d.type === v.F_ADDON_GROUP_TYPE.enum.DYNAMIC ? c.value : !!c.value == !P : c.value : !1,
264
265
  orderFromActiveOnly: n,
265
- showOrderFrom: t ? a ? c.value ? !0 : p.type === v.F_ADDON_GROUP_TYPE.enum.PRODUCT : c.value : !1,
266
- bindToVariant: i,
266
+ showOrderFrom: t ? a ? c.value ? !0 : d.type === v.F_ADDON_GROUP_TYPE.enum.PRODUCT : c.value : !1,
267
+ bindToVariant: s,
267
268
  isOverride: c.value,
268
269
  isItemGroup: !1,
269
270
  isV4: !a
@@ -275,11 +276,11 @@ const vt = /* @__PURE__ */ X({
275
276
  items: {},
276
277
  position: u.groups.length - 1,
277
278
  itemsLinked: []
278
- })), Z = g(() => ke.value(he.value).type);
279
- function ue(t) {
279
+ })), ee = g(() => ke.value(he.value).type);
280
+ function se(t) {
280
281
  h.value.sortGroups(t);
281
282
  }
282
- function Ce(t) {
283
+ function we(t) {
283
284
  f.open({
284
285
  title: l("menu.group.actions.duplicate.title"),
285
286
  message: l("menu.group.actions.duplicate.message", {
@@ -295,36 +296,36 @@ const vt = /* @__PURE__ */ X({
295
296
  }
296
297
  }).onPrimary(() => h.value.duplicateGroup(t));
297
298
  }
298
- const ee = g(() => u.currentCatalog), B = g(() => u.currentScheduler), j = g(() => new pt(ee.value, u, k.updateMenu, f)), te = g(() => new rt(B.value, u, k.updateMenu, f)), we = (t) => {
299
+ const te = g(() => u.currentCatalog), j = g(() => u.currentScheduler), B = g(() => new dt(te.value, u, k.updateMenu, f)), oe = g(() => new rt(j.value, u, k.updateMenu, f)), Ce = (t) => {
299
300
  let e = t;
300
301
  function a(n) {
301
- const F = u.state.menu.modules.group.find((o) => o._id === n._id), p = (n.items ?? []).reduce((o, O) => (o[O._id] = [...o[O._id] || [], O.combinationKey || ""], o), {}), Y = (F.items ?? []).filter((o) => {
302
+ const w = u.state.menu.modules.group.find((o) => o._id === n._id), d = (n.items ?? []).reduce((o, O) => (o[O._id] = [...o[O._id] || [], O.combinationKey || ""], o), {}), Y = (w.items ?? []).filter((o) => {
302
303
  var O;
303
- return !((O = p[o._id]) != null && O.includes(o.combinationKey || ""));
304
+ return !((O = d[o._id]) != null && O.includes(o.combinationKey || ""));
304
305
  }).map((o) => ({
305
306
  _id: o._id,
306
307
  combinationKey: o.combinationKey,
307
308
  selection: o.selection
308
309
  })).filter((o) => !!u.mergedMenu.modules.item.find((O) => O._id === o._id));
309
310
  return {
310
- ...F,
311
+ ...w,
311
312
  ...Object.fromEntries(Object.entries(n).filter(([, o]) => !!o)),
312
313
  items: [...n.items ?? [], ...Y]
313
314
  };
314
315
  }
315
316
  if (c.value) {
316
317
  let n;
317
- ee.value ? B.value ? n = j.value.getCatalogSchedulerGroup(t._id, B.value._id) : n = j.value.getCatalogGroup(t._id) : n = te.value.getSchedulerGroup(t._id);
318
- const i = a(n);
319
- e = new ge(u, k.updateMenu, f).mapGroups([i], !0)[0];
318
+ te.value ? j.value ? n = B.value.getCatalogSchedulerGroup(t._id, j.value._id) : n = B.value.getCatalogGroup(t._id) : n = oe.value.getSchedulerGroup(t._id);
319
+ const s = a(n);
320
+ e = new ge(u, k.updateMenu, f).mapGroups([s], !0)[0];
320
321
  }
321
322
  return {
322
323
  group: e,
323
- config: re,
324
+ config: ue,
324
325
  categorizedItems: u.categorizedItems
325
326
  };
326
327
  };
327
- function Oe(t) {
328
+ function xe(t) {
328
329
  f.open({
329
330
  title: l("menu.group.dialogs.delete.title"),
330
331
  contentComponent: Ct,
@@ -344,40 +345,40 @@ const vt = /* @__PURE__ */ X({
344
345
  await h.value.deleteGroup(t);
345
346
  });
346
347
  }
347
- function se(t, e) {
348
- return pe(_t, {
348
+ function ie(t, e) {
349
+ return H(bt, {
349
350
  key: t._id,
350
351
  initialValue: t.itemsLinked,
351
352
  group: it(t),
352
353
  editable: y.value.applyProduct,
353
354
  "onApply:product": async (a) => {
354
355
  var n;
355
- for (const i of a)
356
- if (ft(u.state.menu, t._id, i._id)) {
357
- const F = (n = u.state.menu.modules.item.find((p) => p._id === i._id)) == null ? void 0 : n.name;
356
+ for (const s of a)
357
+ if (ft(u.state.menu, t._id, s._id)) {
358
+ const w = (n = u.state.menu.modules.item.find((d) => d._id === s._id)) == null ? void 0 : n.name;
358
359
  V.open({
359
360
  type: "error",
360
361
  message: l("menu.product.form.group.circularError", {
361
362
  groupName: t.name,
362
- productName: F
363
+ productName: w
363
364
  })
364
365
  });
365
366
  return;
366
367
  }
367
- await h.value.applyItems(t, a.map((i) => i._id));
368
+ await h.value.applyItems(t, a.map((s) => s._id));
368
369
  }
369
370
  }, {
370
371
  default: e
371
372
  });
372
373
  }
373
- const ie = (t) => {
374
+ const ce = (t) => {
374
375
  const e = t.group;
375
- return se(e, ({
376
+ return ie(e, ({
376
377
  trigger: n
377
378
  }) => {
378
- const i = [{
379
+ const s = [{
379
380
  label: l("menu.common.actions.edit"),
380
- onClick: () => me(e)
381
+ onClick: () => pe(e)
381
382
  }, {
382
383
  label: l("menu.group.actions.apply_product"),
383
384
  disable: !y.value.applyProduct,
@@ -385,33 +386,43 @@ const vt = /* @__PURE__ */ X({
385
386
  }, {
386
387
  label: l("menu.group.actions.duplicate_action"),
387
388
  disabled: !y.value.create,
388
- onClick: () => Ce(e)
389
+ onClick: () => we(e)
389
390
  }, {
390
391
  label: l("menu.common.actions.delete"),
391
392
  itemClass: "text-fm-color-typo-error",
392
393
  disabled: !y.value.delete,
393
- onClick: () => Oe(e)
394
+ onClick: () => xe(e)
394
395
  }];
395
- return s(vt, {
396
+ return i(gt, {
396
397
  class: t.className,
397
- items: i
398
+ items: s
398
399
  }, null);
399
400
  });
400
- }, xe = g(() => [{
401
+ }, Oe = g(() => [{
401
402
  accessorKey: "name",
402
403
  header: () => l("menu.group.list.columns.name"),
403
- enableSorting: !1
404
+ enableSorting: !1,
405
+ cell: (t) => {
406
+ const e = t.row.original, a = t.getValue(), s = Object.keys(e.name_locale ?? {}).map((w) => vt(w));
407
+ return H("div", {
408
+ class: "flex items-center gap-8"
409
+ }, [H("span", {
410
+ class: "break-all"
411
+ }, a), ...s.map((w) => H("div", {
412
+ class: "rounded-lg border border-fm-color-primary text-fm-color-primary flex items-center justify-center fm-typo-en-body-sm-600 px-8"
413
+ }, w))]);
414
+ }
404
415
  }, {
405
416
  accessorKey: "items",
406
417
  header: () => l("menu.group.list.columns.products"),
407
418
  enableSorting: !1,
408
419
  cell: (t) => {
409
420
  const e = t.getValue(), a = Object.values(e).map((n) => {
410
- var F;
411
- const i = [(n == null ? void 0 : n.code) || "", n.name || n.fallbackName].join(" ").trim();
412
- return (n.items || []).length > 1 ? `${i} (${l("menu.group.list.variants", {
413
- count: (F = n.items) == null ? void 0 : F.length
414
- })})` : i;
421
+ var w;
422
+ const s = [(n == null ? void 0 : n.code) || "", n.name || n.fallbackName].join(" ").trim();
423
+ return (n.items || []).length > 1 ? `${s} (${l("menu.group.list.variants", {
424
+ count: (w = n.items) == null ? void 0 : w.length
425
+ })})` : s;
415
426
  });
416
427
  return a.length > 5 ? `${a.slice(0, 5).join(", ")} ${l("menu.group.list.more_items", {
417
428
  count: a.length - 5
@@ -440,7 +451,7 @@ const vt = /* @__PURE__ */ X({
440
451
  size: 140,
441
452
  cell: (t) => {
442
453
  const e = t.row.original;
443
- return pe(We, {
454
+ return H(We, {
444
455
  // FIXME:FdoCustomAttribute under "@feedmepos/custom-attributes" is not compatible
445
456
  // with FdoCustomAttribute from "@feedmepos/core", ! mark should be removed when fixed
446
457
  customAttributes: e.customAttributes
@@ -454,12 +465,12 @@ const vt = /* @__PURE__ */ X({
454
465
  const e = t.getValue(), a = l("menu.group.list.items_linked", {
455
466
  count: e.length
456
467
  });
457
- return se(t.row.original, ({
468
+ return ie(t.row.original, ({
458
469
  trigger: n
459
- }) => s("div", {
470
+ }) => i("div", {
460
471
  class: "w-fit cursor-pointer border-b border-dashed border-fm-color-neutral-gray-300 hover:border-fm-color-neutral-gray-400",
461
- onClick: (i) => {
462
- i.stopPropagation(), n(i);
472
+ onClick: (s) => {
473
+ s.stopPropagation(), n(s);
463
474
  }
464
475
  }, [a]));
465
476
  }
@@ -471,7 +482,7 @@ const vt = /* @__PURE__ */ X({
471
482
  },
472
483
  cell: (t) => {
473
484
  const e = t.row.original;
474
- return ie({
485
+ return ce({
475
486
  group: e,
476
487
  className: "flex justify-end w-full"
477
488
  });
@@ -481,14 +492,14 @@ const vt = /* @__PURE__ */ X({
481
492
  return {
482
493
  itemsLinked: y.value.showAppliedProduct,
483
494
  type: y.value.type,
484
- tagging: ((t = R.groupAttributeSettings) == null ? void 0 : t.value.length) > 0
495
+ tagging: ((t = E.groupAttributeSettings) == null ? void 0 : t.value.length) > 0
485
496
  };
486
497
  }), Ae = async (t) => {
487
- const e = ct(t), a = e.group, n = mt(a, re(t));
498
+ const e = ct(t), a = e.group, n = mt(a, ue(t));
488
499
  if (c.value)
489
- ee.value ? (B.value ? j.value.overrideCatalogSchedulerGroups([n], B.value._id) : j.value.overrideCatalogGroups([n]), await j.value.update()) : (te.value.overrideSchedulerGroups([n]), await te.value.update());
500
+ te.value ? (j.value ? B.value.overrideCatalogSchedulerGroups([n], j.value._id) : B.value.overrideCatalogGroups([n]), await B.value.update()) : (oe.value.overrideSchedulerGroups([n]), await oe.value.update());
490
501
  else {
491
- const i = {
502
+ const s = {
492
503
  module: v.F_MENU_MODULE_V4_KEY.enum.group,
493
504
  operation: ze.F_OPERATION_TYPE.update,
494
505
  data: n,
@@ -498,31 +509,31 @@ const vt = /* @__PURE__ */ X({
498
509
  data: e.linkItems
499
510
  }]
500
511
  };
501
- await k.updateMenu(i, n.name);
512
+ await k.updateMenu(s, n.name);
502
513
  }
503
- }, $ = E(null), ce = E(null), me = async (t) => {
514
+ }, $ = R(null), me = R(null), pe = async (t) => {
504
515
  var e;
505
- $.value = ot(t), await fe(), (e = ce.value) == null || e.trigger(!0);
516
+ $.value = ot(t), await fe(), (e = me.value) == null || e.trigger(!0);
506
517
  };
507
518
  function Fe(t) {
508
- me(t.original);
519
+ pe(t.original);
509
520
  }
510
521
  const Me = ye(), Ge = g(() => Me.breakpoints.value.xs), {
511
522
  t: l
512
- } = le(), Pe = g(() => {
523
+ } = ae(), Pe = g(() => {
513
524
  var t;
514
- return ((t = R.groupAttributeSettings) == null ? void 0 : t.value.length) > 0;
515
- }), K = E(!1), Q = E(null);
525
+ return ((t = E.groupAttributeSettings) == null ? void 0 : t.value.length) > 0;
526
+ }), K = R(!1), J = R(null);
516
527
  async function Ve() {
517
- K.value = !K.value, K.value && (await fe(), Q.value && Q.value.toggleProperty(!0));
528
+ K.value = !K.value, K.value && (await fe(), J.value && J.value.toggleProperty(!0));
518
529
  }
519
- const de = () => y.value.multiScheduler ? s(Xe, null, {
520
- append: () => Pe.value ? s("div", {
530
+ const de = () => y.value.multiScheduler ? i(Xe, null, {
531
+ append: () => Pe.value ? i("div", {
521
532
  class: "pl-8 flex items-center justify-center border-l border-fm-color-neutral-gray-200",
522
533
  onClick: (t) => {
523
534
  t.stopPropagation(), Ve();
524
535
  }
525
- }, [s(_e.FmIcon, {
536
+ }, [i(_e.FmIcon, {
526
537
  name: "filter_alt",
527
538
  outline: !0,
528
539
  color: "neutral-gray-400",
@@ -530,31 +541,31 @@ const vt = /* @__PURE__ */ X({
530
541
  }, null)]) : null
531
542
  }) : null;
532
543
  return (t, e) => {
533
- const a = M("fm-button"), n = M("fm-chip"), i = M("fm-menu-item"), F = M("fm-menu"), p = M("fm-search"), P = M("fm-table"), Y = M("fm-bottom-sheet");
534
- return m(), C(T, null, [$.value ? (m(), I(ut, Ee({
544
+ const a = M("fm-button"), n = M("fm-chip"), s = M("fm-menu-item"), w = M("fm-menu"), d = M("fm-search"), P = M("fm-table"), Y = M("fm-bottom-sheet");
545
+ return m(), C(T, null, [$.value ? (m(), U(ut, Re({
535
546
  ref_key: "groupManagerFormRef",
536
- ref: ce,
547
+ ref: me,
537
548
  key: $.value._id
538
- }, we($.value), {
549
+ }, Ce($.value), {
539
550
  action: "update",
540
551
  title: r(l)("menu.group.dialogs.update.title"),
541
552
  group: $.value,
542
553
  "onUpdate:group": e[0] || (e[0] = (o) => $.value = o),
543
554
  "onSubmit:group": e[1] || (e[1] = (o) => Ae(o))
544
- }), null, 16, ["title", "group"])) : U("", !0), D.value.length === 0 ? (m(), C("div", wt, [s(Ye, {
555
+ }), null, 16, ["title", "group"])) : I("", !0), A.value.length === 0 ? (m(), C("div", xt, [i(Ye, {
545
556
  subtitle: r(l)("menu.group.empty.subtitle"),
546
557
  title: r(l)("menu.group.empty.title")
547
558
  }, Se({
548
559
  _: 2
549
560
  }, [y.value.create ? {
550
561
  name: "action",
551
- fn: x(() => [s(r(st), null, {
552
- default: x(({
562
+ fn: D(() => [i(r(st), null, {
563
+ default: D(({
553
564
  trigger: o
554
- }) => [s(a, {
565
+ }) => [i(a, {
555
566
  "prepend-icon": "add",
556
567
  label: r(l)("menu.group.actions.add"),
557
- onClick: Ue(o, ["stop"])
568
+ onClick: Ie(o, ["stop"])
558
569
  }, null, 8, ["label", "onClick"])]),
559
570
  _: 1
560
571
  })]),
@@ -563,106 +574,106 @@ const vt = /* @__PURE__ */ X({
563
574
  key: 2
564
575
  }, [Ge.value ? (m(), C(T, {
565
576
  key: 1
566
- }, [d("div", Ft, [s(p, {
577
+ }, [p("div", Mt, [i(d, {
567
578
  autofocus: "",
568
- modelValue: r(w),
569
- "onUpdate:modelValue": e[9] || (e[9] = (o) => J(w) ? w.value = o : null),
579
+ modelValue: r(x),
580
+ "onUpdate:modelValue": e[9] || (e[9] = (o) => W(x) ? x.value = o : null),
570
581
  placeholder: r(l)("menu.group.search.placeholder")
571
- }, null, 8, ["modelValue", "placeholder"])]), e[17] || (e[17] = d("div", {
582
+ }, null, 8, ["modelValue", "placeholder"])]), e[17] || (e[17] = p("div", {
572
583
  class: "bg-fm-color-neutral-gray-100 w-full h-px rounded-md"
573
- }, null, -1)), d("div", Mt, [s(de), Z.value ? (m(), I(Y, {
584
+ }, null, -1)), p("div", Gt, [i(de), ee.value ? (m(), U(Y, {
574
585
  key: 0,
575
586
  modelValue: _.value,
576
587
  "onUpdate:modelValue": e[14] || (e[14] = (o) => _.value = o)
577
588
  }, {
578
- "bottom-sheet-button": x(() => [s(n, {
589
+ "bottom-sheet-button": D(() => [i(n, {
579
590
  label: r(l)("menu.group.type.title", {
580
- type: b.value ? r(H.capitalize)(b.value) : r(l)("menu.common.labels.all")
591
+ type: b.value ? r(q.capitalize)(b.value) : r(l)("menu.common.labels.all")
581
592
  }),
582
593
  class: "text-fm-color-typo-secondary",
583
594
  "right-icon": "keyboard_arrow_down"
584
595
  }, null, 8, ["label"])]),
585
- default: x(() => [d("div", null, [d("div", {
596
+ default: D(() => [p("div", null, [p("div", {
586
597
  class: "px-16 py-8",
587
598
  onClick: e[10] || (e[10] = (o) => b.value = null)
588
- }, G(r(l)("menu.group.type.all")), 1), d("div", {
599
+ }, G(r(l)("menu.group.type.all")), 1), p("div", {
589
600
  class: "px-16 py-8",
590
601
  onClick: e[11] || (e[11] = (o) => b.value = "NORMAL")
591
- }, G(r(l)("menu.group.type.normal")), 1), d("div", {
602
+ }, G(r(l)("menu.group.type.normal")), 1), p("div", {
592
603
  class: "px-16 py-8",
593
604
  onClick: e[12] || (e[12] = (o) => b.value = "PRODUCT")
594
- }, G(r(l)("menu.group.type.product")), 1), d("div", {
605
+ }, G(r(l)("menu.group.type.product")), 1), p("div", {
595
606
  class: "px-16 py-8",
596
607
  onClick: e[13] || (e[13] = (o) => b.value = "DYNAMIC")
597
608
  }, G(r(l)("menu.group.type.dynamic")), 1)])]),
598
609
  _: 1
599
- }, 8, ["modelValue"])) : U("", !0)]), K.value ? (m(), C("div", Gt, [s(r(ve), {
610
+ }, 8, ["modelValue"])) : I("", !0)]), K.value ? (m(), C("div", Pt, [i(r(ve), {
600
611
  ref_key: "attributeFilterRef",
601
- ref: Q,
602
- attributes: r(q),
612
+ ref: J,
613
+ attributes: r(Q),
603
614
  modelValue: r(N),
604
- "onUpdate:modelValue": e[15] || (e[15] = (o) => J(N) ? N.value = o : null)
605
- }, null, 8, ["attributes", "modelValue"])])) : U("", !0), s(r(Be), {
606
- class: W(["flex-1", "overflow-scroll", "divide-y divide-fm-color-neutral-gray-100", "pb-64"]),
615
+ "onUpdate:modelValue": e[15] || (e[15] = (o) => W(N) ? N.value = o : null)
616
+ }, null, 8, ["attributes", "modelValue"])])) : I("", !0), i(r(je), {
617
+ class: X(["flex-1", "overflow-scroll", "divide-y divide-fm-color-neutral-gray-100", "pb-64"]),
607
618
  "model-value": z.value,
608
619
  group: "categories",
609
620
  handle: ".handle",
610
621
  "item-key": "_id",
611
- "onUpdate:modelValue": e[16] || (e[16] = (o) => ue(o))
622
+ "onUpdate:modelValue": e[16] || (e[16] = (o) => se(o))
612
623
  }, {
613
- item: x(({
624
+ item: D(({
614
625
  element: o
615
626
  }) => [(m(), C("div", {
616
627
  key: o._id,
617
- class: W(["py-12 px-16", "flex space-x-16", "items-center"])
618
- }, [d("div", Pt, [d("div", Vt, [d("p", Nt, G(o.name), 1), d("div", null, [Z.value ? (m(), C("p", Rt, G(r(H.capitalize)(o.type)) + " type ", 1)) : U("", !0), d("p", Et, G(r(l)("menu.group.list.products_linked", {
628
+ class: X(["py-12 px-16", "flex space-x-16", "items-center"])
629
+ }, [p("div", Vt, [p("div", Nt, [p("p", Et, G(o.name), 1), p("div", null, [ee.value ? (m(), C("p", Rt, G(r(q.capitalize)(o.type)) + " type ", 1)) : I("", !0), p("p", St, G(r(l)("menu.group.list.products_linked", {
619
630
  count: o.itemsLinked.length
620
- })), 1)])]), s(ie, {
631
+ })), 1)])]), i(ce, {
621
632
  group: o
622
633
  }, null, 8, ["group"])])]))]),
623
634
  _: 1
624
- }, 8, ["model-value"])], 64)) : (m(), C("div", Ot, [d("div", xt, [s(de), Z.value ? (m(), I(F, {
635
+ }, 8, ["model-value"])], 64)) : (m(), C("div", Ot, [p("div", Dt, [i(de), ee.value ? (m(), U(w, {
625
636
  key: 0
626
637
  }, {
627
- "menu-button": x(() => [s(n, {
638
+ "menu-button": D(() => [i(n, {
628
639
  label: r(l)("menu.group.type.title", {
629
- type: b.value ? r(H.capitalize)(b.value) : r(l)("menu.common.labels.all")
640
+ type: b.value ? r(q.capitalize)(b.value) : r(l)("menu.common.labels.all")
630
641
  }),
631
642
  class: "text-fm-color-typo-secondary",
632
643
  "right-icon": "keyboard_arrow_down"
633
644
  }, null, 8, ["label"])]),
634
- default: x(() => [d("div", null, [s(i, {
645
+ default: D(() => [p("div", null, [i(s, {
635
646
  class: "px-16 py-8",
636
647
  label: r(l)("menu.group.type.all"),
637
648
  onClick: e[2] || (e[2] = (o) => b.value = null)
638
- }, null, 8, ["label"]), s(i, {
649
+ }, null, 8, ["label"]), i(s, {
639
650
  class: "px-16 py-8",
640
651
  label: r(l)("menu.group.type.normal"),
641
652
  onClick: e[3] || (e[3] = (o) => b.value = "NORMAL")
642
- }, null, 8, ["label"]), s(i, {
653
+ }, null, 8, ["label"]), i(s, {
643
654
  class: "px-16 py-8",
644
655
  label: r(l)("menu.group.type.product"),
645
656
  onClick: e[4] || (e[4] = (o) => b.value = "PRODUCT")
646
- }, null, 8, ["label"]), s(i, {
657
+ }, null, 8, ["label"]), i(s, {
647
658
  class: "px-16 py-8",
648
659
  label: r(l)("menu.group.type.dynamic"),
649
660
  onClick: e[5] || (e[5] = (o) => b.value = "DYNAMIC")
650
661
  }, null, 8, ["label"])])]),
651
662
  _: 1
652
- })) : U("", !0), d("div", Dt, [s(p, {
663
+ })) : I("", !0), p("div", At, [i(d, {
653
664
  autofocus: "",
654
- modelValue: r(w),
655
- "onUpdate:modelValue": e[6] || (e[6] = (o) => J(w) ? w.value = o : null),
665
+ modelValue: r(x),
666
+ "onUpdate:modelValue": e[6] || (e[6] = (o) => W(x) ? x.value = o : null),
656
667
  placeholder: r(l)("menu.group.search.placeholder")
657
- }, null, 8, ["modelValue", "placeholder"])])]), K.value ? (m(), C("div", At, [s(r(ve), {
668
+ }, null, 8, ["modelValue", "placeholder"])])]), K.value ? (m(), C("div", Ft, [i(r(ve), {
658
669
  ref_key: "attributeFilterRef",
659
- ref: Q,
660
- attributes: r(q),
670
+ ref: J,
671
+ attributes: r(Q),
661
672
  modelValue: r(N),
662
- "onUpdate:modelValue": e[7] || (e[7] = (o) => J(N) ? N.value = o : null)
663
- }, null, 8, ["attributes", "modelValue"])])) : U("", !0), s(Ze, null, {
664
- default: x(() => [s(P, {
665
- "column-defs": xe.value,
673
+ "onUpdate:modelValue": e[7] || (e[7] = (o) => W(N) ? N.value = o : null)
674
+ }, null, 8, ["attributes", "modelValue"])])) : I("", !0), i(Ze, null, {
675
+ default: D(() => [i(P, {
676
+ "column-defs": Oe.value,
666
677
  "column-visibility": De.value,
667
678
  loading: r(k).checkMenuIsLoading(),
668
679
  "page-size": z.value.length,
@@ -673,7 +684,7 @@ const vt = /* @__PURE__ */ X({
673
684
  "hide-footer": "",
674
685
  "pin-header-row": "",
675
686
  onRowClick: Fe,
676
- onDndChanged: e[8] || (e[8] = (o) => ue(o))
687
+ onDndChanged: e[8] || (e[8] = (o) => se(o))
677
688
  }, null, 8, ["column-defs", "column-visibility", "loading", "page-size", "row-data"])]),
678
689
  _: 1
679
690
  })]))], 64))], 64);
@@ -681,5 +692,5 @@ const vt = /* @__PURE__ */ X({
681
692
  }
682
693
  });
683
694
  export {
684
- Zt as _
695
+ to as _
685
696
  };