@feedmepos/mf-order-setting 0.0.105 → 0.0.106

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 (102) hide show
  1. package/dist/DisplaySystemView-aLqc6lz9.js +9068 -0
  2. package/dist/{FoodCourtInvitationsView-Bo174yfB.js → FoodCourtInvitationsView-B30qld2i.js} +4 -4
  3. package/dist/{FoodCourtOrderSettingsView-uUe53O0Z.js → FoodCourtOrderSettingsView-CWmaKgbe.js} +1 -1
  4. package/dist/{FoodCourtOrdersView-CxC5oGp2.js → FoodCourtOrdersView-FfrganVo.js} +4 -4
  5. package/dist/{FoodCourtStallsView-BEpRBmSL.js → FoodCourtStallsView-CpGZNP6p.js} +2 -2
  6. package/dist/{FoodCourtStatusView-DA7mdsuf.js → FoodCourtStatusView-ljQUwIwk.js} +1 -1
  7. package/dist/{KioskDevicesView-BY9Egk75.js → KioskDevicesView-BwDAYIhX.js} +1 -1
  8. package/dist/{KioskDevicesView.vue_vue_type_script_setup_true_lang-CxroxD-b.js → KioskDevicesView.vue_vue_type_script_setup_true_lang-VidDJfGG.js} +487 -473
  9. package/dist/KioskSettingView-mfhi9vuf.js +1240 -0
  10. package/dist/{KioskView-BYL0u6kj.js → KioskView-6p5h92fk.js} +173 -167
  11. package/dist/{OrderSettingsView-BBHAhgE9.js → OrderSettingsView-Cf_Ye9U_.js} +11 -11
  12. package/dist/{RestaurantSelector.vue_vue_type_script_setup_true_lang--9bdtLE1.js → RestaurantSelector.vue_vue_type_script_setup_true_lang-TJJ3PBlq.js} +1 -1
  13. package/dist/{app-BV2USn83.js → app-BorqCaJT.js} +6965 -6415
  14. package/dist/app.js +1 -1
  15. package/dist/{dayjs.min-Bp4Kgnt_.js → dayjs.min-CTTY2vkL.js} +1 -1
  16. package/dist/display-preview/assets/{BandBoard-DIcfXsNV.js → BandBoard-BLwgs3WX.js} +1 -1
  17. package/dist/display-preview/assets/{CarouselBlock-XAhTyEWB.js → CarouselBlock-CUrVSbQp.js} +1 -1
  18. package/dist/display-preview/assets/{CategoryBoard-DBKe18hv.js → CategoryBoard-BkvpcxHR.js} +1 -1
  19. package/dist/display-preview/assets/{ImageBlock-BCbnYSHq.js → ImageBlock-0UYDHTm0.js} +1 -1
  20. package/dist/display-preview/assets/{PickupMode-Df_TPCh8.js → PickupMode-BY4iL0BH.js} +1 -1
  21. package/dist/display-preview/assets/{StatusBoard-28z3bPOf.js → StatusBoard-DGEZ6hvH.js} +1 -1
  22. package/dist/display-preview/assets/{TextBlock-CvJKITtx.js → TextBlock-CxKwtqoO.js} +1 -1
  23. package/dist/display-preview/assets/{VideoBlock-Dop43wDv.js → VideoBlock-BKkxdLAd.js} +1 -1
  24. package/dist/display-preview/assets/{index-cqMoOpSN.js → index-B1olKQmQ.js} +2 -2
  25. package/dist/display-preview/assets/{pickupView-DRMVXqrc.js → pickupView-CB9fV5jD.js} +1 -1
  26. package/dist/display-preview/images/feedme-bg-left-image.png +0 -0
  27. package/dist/display-preview/index.html +1 -1
  28. package/dist/{featureFlag-C1uGG7u6.js → featureFlag-DFenoxmg.js} +1 -1
  29. package/dist/frontend/mf-order/src/api/display-system/index.d.ts +2 -2
  30. package/dist/frontend/mf-order/src/app.d.ts +118 -12
  31. package/dist/frontend/mf-order/src/composables/useDisplaySystemPermission.d.ts +5 -0
  32. package/dist/frontend/mf-order/src/main.d.ts +118 -12
  33. package/dist/frontend/mf-order/src/modules/display-system/interface.d.ts +9 -11
  34. package/dist/frontend/mf-order/src/modules/display-system/legacy-ods/convert.d.ts +10 -0
  35. package/dist/frontend/mf-order/src/modules/kiosk/deviceCount.d.ts +18 -0
  36. package/dist/frontend/mf-order/src/modules/order-setting/kiosk/interface.d.ts +12 -0
  37. package/dist/frontend/mf-order/src/modules/order-setting/kiosk/tableNumberHint.d.ts +33 -0
  38. package/dist/frontend/mf-order/src/stores/display-system/index.d.ts +10 -70
  39. package/dist/frontend/mf-order/src/stores/order-setting/index.d.ts +51 -0
  40. package/dist/frontend/mf-order/src/views/display-system/DisplayTemplateEditor.vue.d.ts +2 -0
  41. package/dist/frontend/mf-order/src/views/display-system/legacy-ods/LegacyOdsTemplateList.vue.d.ts +11 -2
  42. package/dist/frontend/mf-order/src/views/display-system/view-selection.d.ts +1 -2
  43. package/dist/frontend/mf-order/tsconfig.app.tsbuildinfo +1 -1
  44. package/dist/{index-0GuybwuA.js → index-BZkJr7iu.js} +1 -1
  45. package/dist/{index-HF3qh9qG.js → index-C4Isv-r7.js} +1 -1
  46. package/dist/{index-CRNutZC_.js → index-DuJOWWP8.js} +4 -4
  47. package/dist/{index-D0ZIByef.js → index-nUvyt9Wm.js} +1 -1
  48. package/dist/{index-KWOCCun9.js → index-tLkJL436.js} +2 -2
  49. package/dist/{order.dto-GQaBESZq.js → order.dto-nVwtcdX2.js} +6049 -5992
  50. package/dist/package/entity/display/mediaHosts.d.ts +4 -0
  51. package/dist/package/entity/food-court/order-v2.do.d.ts +667 -0
  52. package/dist/package/entity/food-court/order-v2.dto.d.ts +262 -0
  53. package/dist/package/entity/incoming-order/incoming-order-to-bill.dto.d.ts +16 -0
  54. package/dist/package/entity/order-platform/menu.dto.d.ts +44 -44
  55. package/dist/package/entity/order-setting/kiosk/kiosk.do.d.ts +52 -0
  56. package/dist/package/entity/order-setting/kiosk/kiosk.dto.d.ts +293 -0
  57. package/dist/package/entity/order-setting/order-setting.do.d.ts +42 -0
  58. package/dist/package/entity/order-setting/order-setting.dto.d.ts +174 -0
  59. package/dist/package/entity/restaurant/restaurant.dto.d.ts +42 -0
  60. package/dist/package/entity/websocket/websocket.dto.d.ts +92 -0
  61. package/dist/style.css +1 -1
  62. package/dist/{useInternalUser-C39xpsBU.js → useInternalUser-HhxjbzGl.js} +1 -1
  63. package/package.json +3 -3
  64. package/src/api/display-system/index.ts +2 -2
  65. package/src/composables/useDisplaySystemPermission.spec.ts +27 -0
  66. package/src/composables/useDisplaySystemPermission.ts +16 -0
  67. package/src/locales/en-US.json +51 -17
  68. package/src/locales/ja-JP.json +26 -11
  69. package/src/locales/th-TH.json +32 -17
  70. package/src/locales/zh-CN.json +51 -17
  71. package/src/modules/display-system/interface.spec.ts +1 -32
  72. package/src/modules/display-system/interface.ts +7 -24
  73. package/src/modules/display-system/legacy-ods/convert.spec.ts +65 -0
  74. package/src/modules/display-system/legacy-ods/convert.ts +95 -0
  75. package/src/modules/display-system/legacy-ods/media.spec.ts +16 -0
  76. package/src/modules/kiosk/deviceCount.spec.ts +23 -0
  77. package/src/modules/kiosk/deviceCount.ts +21 -0
  78. package/src/modules/order-setting/kiosk/interface.ts +13 -0
  79. package/src/modules/order-setting/kiosk/tableNumberHint.spec.ts +68 -0
  80. package/src/modules/order-setting/kiosk/tableNumberHint.ts +71 -0
  81. package/src/router/display-system-permission.spec.ts +13 -0
  82. package/src/router/routes.ts +2 -1
  83. package/src/stores/display-system/index.spec.ts +104 -0
  84. package/src/stores/display-system/index.ts +18 -7
  85. package/src/stores/order-setting/mapper.ts +11 -2
  86. package/src/views/display-system/DisplayInspector.vue +3 -0
  87. package/src/views/display-system/DisplayModulePickerDialog.vue +8 -0
  88. package/src/views/display-system/DisplaySystemView.conversion.spec.ts +164 -0
  89. package/src/views/display-system/DisplaySystemView.vue +72 -26
  90. package/src/views/display-system/DisplayTemplateEditor.spec.ts +18 -0
  91. package/src/views/display-system/DisplayTemplateEditor.vue +8 -2
  92. package/src/views/display-system/legacy-ods/LegacyOdsTemplateList.spec.ts +44 -4
  93. package/src/views/display-system/legacy-ods/LegacyOdsTemplateList.vue +12 -4
  94. package/src/views/display-system/view-selection.spec.ts +4 -17
  95. package/src/views/display-system/view-selection.ts +3 -4
  96. package/src/views/kiosk/devices/KioskDevicesView.vue +6 -2
  97. package/src/views/kiosk/devices/KioskLicenseSummary.spec.ts +45 -0
  98. package/src/views/kiosk/devices/KioskLicenseSummary.vue +9 -2
  99. package/src/views/kiosk/settings/KioskSettingView.vue +140 -6
  100. package/vitest.config.ts +1 -0
  101. package/dist/DisplaySystemView-CFr9DnaD.js +0 -8926
  102. package/dist/KioskSettingView-DPaQ7YFV.js +0 -1124
@@ -0,0 +1,1240 @@
1
+ import { defineComponent as Re, computed as C, ref as R, onMounted as ge, resolveComponent as O, openBlock as S, createBlock as le, withCtx as M, createVNode as i, unref as a, createElementVNode as l, withDirectives as P, vShow as T, toDisplayString as u, reactive as da, watch as Pe, nextTick as fe, onBeforeUnmount as ia, createElementBlock as V, normalizeStyle as Te, Fragment as H, renderList as G, normalizeClass as ae, createCommentVNode as W, toRaw as ua } from "vue";
2
+ import { e as Ne, b as Oe, s as Fe, d as ca, r as Ae, f as Ue, h as ma } from "./app-BorqCaJT.js";
3
+ import { b as _, K as pa, c as ya, d as fa } from "./order.dto-nVwtcdX2.js";
4
+ import { _ as va, u as ba } from "./index-DuJOWWP8.js";
5
+ import { useI18n as Le, FeedMeAuth as Me, useCoreStore as ga } from "@feedmepos/mf-common";
6
+ import { u as xa } from "./index-Cmb4sEqq.js";
7
+ import { useSnackbar as ha } from "@feedmepos/ui-library";
8
+ const _a = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary ml-7" }, Sa = { class: "ml-7" }, Ia = { class: "ml-7" }, ka = { class: "flex flex-row flex-wrap gap-x-24 gap-y-8" }, wa = /* @__PURE__ */ Re({
9
+ __name: "KioskPaymentTypeSection",
10
+ props: {
11
+ paymentTypes: {
12
+ type: Array,
13
+ required: !0
14
+ },
15
+ offlinePaymentTypes: {
16
+ type: Array,
17
+ required: !0
18
+ },
19
+ allowEPayment: {
20
+ type: [Boolean, String],
21
+ required: !0
22
+ },
23
+ allowCredit: {
24
+ type: [Boolean, String],
25
+ default: !1
26
+ },
27
+ ePaymentTypes: {
28
+ type: Object,
29
+ required: !0
30
+ }
31
+ },
32
+ emits: ["update:paymentTypes", "update:offlinePaymentTypes", "update:ePaymentTypes"],
33
+ setup(n, { emit: r }) {
34
+ const { t: e } = Le(), c = n, b = r, k = C(() => (c.paymentTypes || []).includes(Ne.F_ORDER_PAYMENT_TYPE.enum.ePayment)), g = R(), x = R([]), U = R(!1), v = R(!1), m = R(!1), N = () => {
35
+ Object.keys(c.ePaymentTypes).length !== 0 && (c.ePaymentTypes.terminal && (v.value = !0), c.ePaymentTypes.card.terminal ? (g.value = _.enum.TERMINAL, U.value = !0) : c.ePaymentTypes.card.nfc && (g.value = _.enum.NFC, U.value = !0), c.ePaymentTypes.eWallet.qrPay && (x.value.push(_.enum.QRPAY), m.value = !0), c.ePaymentTypes.eWallet.scanPay && (x.value.push(_.enum.SCANPAY), m.value = !0));
36
+ };
37
+ N();
38
+ const z = (h) => {
39
+ const y = {
40
+ terminal: !1,
41
+ card: {
42
+ terminal: !1,
43
+ nfc: !1
44
+ },
45
+ eWallet: {
46
+ qrPay: !1,
47
+ scanPay: !1
48
+ }
49
+ };
50
+ k.value && (h == _.enum.TERMINAL && (y.card.terminal = !0), h == _.enum.NFC && (y.card.nfc = !0), x.value.length > 0 && (x.value.includes(_.enum.QRPAY) && (y.eWallet.qrPay = !0), x.value.includes(_.enum.SCANPAY) && (y.eWallet.scanPay = !0))), v.value && (y.terminal = !0), b("update:ePaymentTypes", y);
51
+ }, $ = () => {
52
+ const h = {
53
+ terminal: !1,
54
+ card: {
55
+ terminal: !1,
56
+ nfc: !1
57
+ },
58
+ eWallet: {
59
+ qrPay: !1,
60
+ scanPay: !1,
61
+ terminalScanPay: !1,
62
+ terminalQrPay: !1
63
+ }
64
+ };
65
+ k.value && (g.value && (g.value === _.enum.TERMINAL && (h.card.terminal = !0), g.value === _.enum.NFC && (h.card.nfc = !0)), v.value && (h.terminal = !0), x.value.includes(_.enum.QRPAY) && (h.eWallet.qrPay = !0), x.value.includes(_.enum.SCANPAY) && (h.eWallet.scanPay = !0), x.value.includes(_.enum.TERMINAL_SCAN_PAY) && (h.eWallet.terminalScanPay = !0), x.value.includes(_.enum.TERMINAL_QR_PAY) && (h.eWallet.terminalQrPay = !0)), b("update:ePaymentTypes", h);
66
+ }, o = (h) => {
67
+ g.value = "", h && (g.value = _.enum.TERMINAL), $();
68
+ }, j = (h) => {
69
+ x.value = [], h && (x.value = [
70
+ _.enum.QRPAY,
71
+ _.enum.SCANPAY
72
+ ]), $();
73
+ }, Y = (h) => {
74
+ b("update:paymentTypes", h), h.includes(Ne.F_ORDER_PAYMENT_TYPE.enum.ePayment) || (U.value = !1, m.value = !1, o(!1), j(!1));
75
+ };
76
+ return ge(() => {
77
+ N();
78
+ }), (h, y) => {
79
+ const B = O("FmSwitch"), q = O("FmRadio"), ce = O("FmRadioGroup"), Q = O("FmCardSection"), X = O("FmCard"), D = O("FmCheckbox");
80
+ return S(), le(va, {
81
+ "payment-types": n.paymentTypes,
82
+ "offline-payment-types": n.offlinePaymentTypes,
83
+ "allow-e-payment": c.allowEPayment,
84
+ "allow-credit": c.allowCredit,
85
+ "onUpdate:paymentTypes": Y,
86
+ "onUpdate:offlinePaymentTypes": y[8] || (y[8] = (I) => b("update:offlinePaymentTypes", I || []))
87
+ }, {
88
+ "e-payment-note": M(() => [
89
+ l("div", _a, u(a(e)("order.legacyEPaymentNote")), 1)
90
+ ]),
91
+ "e-payment-content": M(() => [
92
+ i(X, { variant: "outlined" }, {
93
+ default: M(() => [
94
+ i(Q, null, {
95
+ default: M(() => [
96
+ i(B, {
97
+ label: a(e)("order.bankCard"),
98
+ sublabel: a(e)("order.cardPaymentDescription"),
99
+ "label-placement": "right",
100
+ modelValue: U.value,
101
+ "onUpdate:modelValue": [
102
+ y[0] || (y[0] = (I) => U.value = I),
103
+ o
104
+ ]
105
+ }, null, 8, ["label", "sublabel", "modelValue"]),
106
+ y[9] || (y[9] = l("br", null, null, -1)),
107
+ P(l("div", Sa, [
108
+ i(ce, {
109
+ modelValue: g.value,
110
+ "onUpdate:modelValue": [
111
+ y[1] || (y[1] = (I) => g.value = I),
112
+ z
113
+ ],
114
+ inline: ""
115
+ }, {
116
+ default: M(() => [
117
+ i(q, {
118
+ label: a(e)("order.terminal"),
119
+ value: a(_).enum.TERMINAL
120
+ }, null, 8, ["label", "value"]),
121
+ i(q, {
122
+ label: a(e)("order.nfc"),
123
+ value: a(_).enum.NFC
124
+ }, null, 8, ["label", "value"])
125
+ ]),
126
+ _: 1
127
+ }, 8, ["modelValue"])
128
+ ], 512), [
129
+ [T, U.value]
130
+ ])
131
+ ]),
132
+ _: 1
133
+ })
134
+ ]),
135
+ _: 1
136
+ }),
137
+ i(X, {
138
+ variant: "outlined",
139
+ class: "mt-2"
140
+ }, {
141
+ default: M(() => [
142
+ i(Q, null, {
143
+ default: M(() => [
144
+ i(B, {
145
+ label: a(e)("order.terminal"),
146
+ sublabel: a(e)("order.terminalPaymentDescription"),
147
+ "label-placement": "right",
148
+ modelValue: v.value,
149
+ "onUpdate:modelValue": [
150
+ y[2] || (y[2] = (I) => v.value = I),
151
+ $
152
+ ]
153
+ }, null, 8, ["label", "sublabel", "modelValue"])
154
+ ]),
155
+ _: 1
156
+ })
157
+ ]),
158
+ _: 1
159
+ }),
160
+ i(X, {
161
+ variant: "outlined",
162
+ class: "mt-2"
163
+ }, {
164
+ default: M(() => [
165
+ i(Q, null, {
166
+ default: M(() => [
167
+ i(B, {
168
+ label: a(e)("order.eWallet"),
169
+ sublabel: a(e)("order.eWalletDescription"),
170
+ "label-placement": "right",
171
+ modelValue: m.value,
172
+ "onUpdate:modelValue": [
173
+ y[3] || (y[3] = (I) => m.value = I),
174
+ j
175
+ ]
176
+ }, null, 8, ["label", "sublabel", "modelValue"]),
177
+ y[10] || (y[10] = l("br", null, null, -1)),
178
+ P(l("div", Ia, [
179
+ l("div", ka, [
180
+ i(D, {
181
+ modelValue: x.value,
182
+ "onUpdate:modelValue": [
183
+ y[4] || (y[4] = (I) => x.value = I),
184
+ $
185
+ ],
186
+ label: a(e)("order.qrPay"),
187
+ value: a(_).enum.QRPAY
188
+ }, null, 8, ["modelValue", "label", "value"]),
189
+ i(D, {
190
+ modelValue: x.value,
191
+ "onUpdate:modelValue": [
192
+ y[5] || (y[5] = (I) => x.value = I),
193
+ $
194
+ ],
195
+ label: a(e)("order.scanPay"),
196
+ value: a(_).enum.SCANPAY
197
+ }, null, 8, ["modelValue", "label", "value"]),
198
+ i(D, {
199
+ modelValue: x.value,
200
+ "onUpdate:modelValue": [
201
+ y[6] || (y[6] = (I) => x.value = I),
202
+ $
203
+ ],
204
+ label: a(e)("order.terminalScanPay"),
205
+ value: a(_).enum.TERMINAL_SCAN_PAY
206
+ }, null, 8, ["modelValue", "label", "value"]),
207
+ i(D, {
208
+ modelValue: x.value,
209
+ "onUpdate:modelValue": [
210
+ y[7] || (y[7] = (I) => x.value = I),
211
+ $
212
+ ],
213
+ label: a(e)("order.terminalQrPay"),
214
+ value: a(_).enum.TERMINAL_QR_PAY
215
+ }, null, 8, ["modelValue", "label", "value"])
216
+ ])
217
+ ], 512), [
218
+ [T, m.value]
219
+ ])
220
+ ]),
221
+ _: 1
222
+ })
223
+ ]),
224
+ _: 1
225
+ })
226
+ ]),
227
+ _: 1
228
+ }, 8, ["payment-types", "offline-payment-types", "allow-e-payment", "allow-credit"]);
229
+ };
230
+ }
231
+ }), Ca = {
232
+ "en-US": "English",
233
+ "zh-CN": "中文",
234
+ "th-TH": "ไทย",
235
+ "vi-VN": "Tiếng Việt",
236
+ "id-ID": "Bahasa Indonesia",
237
+ "ko-KR": "한국어",
238
+ "ja-JP": "日本語",
239
+ "ar-SA": "العربية"
240
+ }, ie = pa.map((n) => ({
241
+ code: n,
242
+ label: Ca[n]
243
+ })), Va = {
244
+ "en-US": "Enter a number between {min} and {max}",
245
+ "zh-CN": "请输入 {min} 到 {max} 之间的号码",
246
+ "th-TH": "กรอกหมายเลขระหว่าง {min} และ {max}",
247
+ "vi-VN": "Nhập một số từ {min} đến {max}",
248
+ "id-ID": "Masukkan angka antara {min} dan {max}",
249
+ "ko-KR": "{min}부터 {max} 사이의 번호를 입력해 주세요",
250
+ "ja-JP": "{min}から{max}の数字を入力してください",
251
+ "ar-SA": "أدخل رقمًا بين {min} و{max}"
252
+ };
253
+ function Pa(n) {
254
+ return !n || n.length === 0 ? ie : ie.filter((r) => n.includes(r.code));
255
+ }
256
+ function Ta(n, r) {
257
+ if (r.min == null || r.max == null) return null;
258
+ const e = r.prefix ?? "";
259
+ return Va[n].replace("{min}", `${e}${r.min}`).replace("{max}", `${e}${r.max}`);
260
+ }
261
+ function Na(n) {
262
+ var e;
263
+ if (!n) return null;
264
+ const r = {};
265
+ for (const { code: c } of ie) {
266
+ const b = (e = n[c]) == null ? void 0 : e.trim();
267
+ b && (r[c] = b);
268
+ }
269
+ return Object.keys(r).length > 0 ? r : null;
270
+ }
271
+ var Aa = { firebase: {} }, Ua = {};
272
+ let de = null;
273
+ function Ea(n) {
274
+ var c;
275
+ const r = (c = n.name.split(".").pop()) == null ? void 0 : c.toLowerCase();
276
+ return r && /^[a-z0-9]+$/.test(r) ? r : {
277
+ "image/jpeg": "jpg",
278
+ "image/png": "png",
279
+ "image/webp": "webp",
280
+ "image/gif": "gif"
281
+ }[n.type] ?? "bin";
282
+ }
283
+ function Ra() {
284
+ var e;
285
+ return (((e = Ua.firebase) == null ? void 0 : e.storageBucket) ?? Aa.firebase.storageBucket ?? "image.feedme.cc").replace(/^https?:\/\//, "").replace(/\/+$/, "");
286
+ }
287
+ function Oa(n) {
288
+ const r = n.replace(/^\/+/, "");
289
+ return `https://${Ra()}/${r}`;
290
+ }
291
+ async function Fa() {
292
+ const n = Oe();
293
+ if (!n.currentUser && (await n.authStateReady(), !n.currentUser && (de || (de = (async () => {
294
+ const r = await Me.getCustomToken();
295
+ await Fe(n, r);
296
+ })().finally(() => {
297
+ de = null;
298
+ })), await de, !n.currentUser)))
299
+ throw new Error("User not authenticated for image upload");
300
+ }
301
+ async function La() {
302
+ const n = Oe();
303
+ n.currentUser && await ma(n);
304
+ const r = await Me.getCustomToken();
305
+ await Fe(n, r);
306
+ }
307
+ async function Ma(n, r) {
308
+ const e = ca(), c = Ae(e, n);
309
+ try {
310
+ await Ue(c, r, {
311
+ contentType: r.type || void 0
312
+ });
313
+ return;
314
+ } catch (k) {
315
+ if ((k == null ? void 0 : k.code) !== "storage/unauthorized")
316
+ throw k;
317
+ }
318
+ await La();
319
+ const b = Ae(e, n);
320
+ await Ue(b, r, {
321
+ contentType: r.type || void 0
322
+ });
323
+ }
324
+ async function $a(n, r) {
325
+ await Fa();
326
+ const e = n.replace(/^\/+/, "").replace(/\/+$/, ""), c = Ea(r), b = `${Date.now()}_${Math.random().toString(36).slice(2, 10)}.${c}`, k = `${e}/${b}`;
327
+ return await Ma(k, r), Oa(k);
328
+ }
329
+ const te = 8, Ee = 6, $e = 2, De = 60, Da = {
330
+ landscape: "coverImageLandscape",
331
+ portrait: "coverImagePortrait"
332
+ };
333
+ function We(n) {
334
+ if (!Array.isArray(n)) return [];
335
+ const r = /* @__PURE__ */ new Set(), e = [];
336
+ for (const c of n) {
337
+ const b = typeof c == "string" ? c.trim() : "";
338
+ !b || r.has(b) || (r.add(b), e.push(b));
339
+ }
340
+ return e;
341
+ }
342
+ function ue(n, r) {
343
+ var e;
344
+ return We((e = n.coverCarousel) == null ? void 0 : e[r]);
345
+ }
346
+ function Wa(n, r) {
347
+ const e = n[Da[r]], c = typeof e == "string" ? e.trim() : "";
348
+ return c.length > 0 ? c : null;
349
+ }
350
+ function Ha(n, r) {
351
+ const e = ue(n, r);
352
+ if (e.length > 0) return e;
353
+ const c = Wa(n, r);
354
+ return c ? [c] : [];
355
+ }
356
+ function Ga(n) {
357
+ var e;
358
+ const r = (e = n.coverCarousel) == null ? void 0 : e.intervalMs;
359
+ return typeof r != "number" || !Number.isFinite(r) || r <= 0 ? null : Math.round(r / 1e3);
360
+ }
361
+ function He(n, r, e) {
362
+ return n.length === 0 && r.length === 0 ? null : {
363
+ landscape: n.length > 0 ? n : void 0,
364
+ portrait: r.length > 0 ? r : void 0,
365
+ intervalMs: typeof e == "number" && e > 0 ? e : void 0
366
+ };
367
+ }
368
+ function za(n, r, e) {
369
+ var g;
370
+ const c = We(e).slice(0, te), b = r === "landscape" ? "portrait" : "landscape", k = {
371
+ [r]: c.length > 1 ? c : [],
372
+ [b]: ue(n, b)
373
+ };
374
+ return {
375
+ coverImageLandscape: r === "landscape" ? c[0] ?? null : n.coverImageLandscape,
376
+ coverImagePortrait: r === "portrait" ? c[0] ?? null : n.coverImagePortrait,
377
+ coverCarousel: He(
378
+ k.landscape,
379
+ k.portrait,
380
+ (g = n.coverCarousel) == null ? void 0 : g.intervalMs
381
+ )
382
+ };
383
+ }
384
+ function Ka(n, r) {
385
+ const e = r == null || !Number.isFinite(r) ? null : Math.min(De, Math.max($e, Math.round(r)));
386
+ return {
387
+ coverImageLandscape: n.coverImageLandscape,
388
+ coverImagePortrait: n.coverImagePortrait,
389
+ coverCarousel: He(
390
+ ue(n, "landscape"),
391
+ ue(n, "portrait"),
392
+ e == null ? null : e * 1e3
393
+ )
394
+ };
395
+ }
396
+ function ja(n, r, e) {
397
+ if (r === e) return [...n];
398
+ if (r < 0 || e < 0 || r >= n.length || e >= n.length) return [...n];
399
+ const c = [...n], [b] = c.splice(r, 1);
400
+ return c.splice(e, 0, b), c;
401
+ }
402
+ const Ge = ["ordering", "look", "payment", "updates"];
403
+ function Ya(n) {
404
+ return Ge.filter((r) => r !== "updates" || n);
405
+ }
406
+ const ze = 1e5;
407
+ function Ba(n) {
408
+ var c, b, k, g, x, U, v;
409
+ const r = /* @__PURE__ */ new Set();
410
+ if (n.dineIn.enabled && n.dineIn.displayStand.enabled) {
411
+ const { padDigit: m, standSlotRange: N } = n.dineIn.displayStand;
412
+ m != null && m >= 0 && N.min != null && N.max != null && N.min <= N.max || r.add("ordering");
413
+ }
414
+ n.minWeighGrams != null && (!Number.isInteger(n.minWeighGrams) || n.minWeighGrams < 1 || n.minWeighGrams > ze) && r.add("ordering"), n.languages != null && n.languages.length === 0 && r.add("look");
415
+ const e = n.paymentSetting;
416
+ if ((c = e == null ? void 0 : e.paymentTypes) != null && c.includes(ya.enum.ePayment)) {
417
+ const m = e.ePaymentTypes, N = ((b = m == null ? void 0 : m.card) == null ? void 0 : b.terminal) || ((k = m == null ? void 0 : m.card) == null ? void 0 : k.nfc), z = ((g = m == null ? void 0 : m.eWallet) == null ? void 0 : g.qrPay) || ((x = m == null ? void 0 : m.eWallet) == null ? void 0 : x.scanPay) || ((U = m == null ? void 0 : m.eWallet) == null ? void 0 : U.terminalScanPay) || ((v = m == null ? void 0 : m.eWallet) == null ? void 0 : v.terminalQrPay);
418
+ (!m || !N && !z && !m.terminal) && r.add("payment");
419
+ }
420
+ return Ge.filter((m) => r.has(m));
421
+ }
422
+ function ve(n) {
423
+ var r, e;
424
+ return !!((r = n == null ? void 0 : n.payAtCounter) != null && r.trim() || (e = n == null ? void 0 : n.paid) != null && e.trim());
425
+ }
426
+ const qa = ["aria-label"], Qa = {
427
+ role: "tablist",
428
+ "aria-orientation": "vertical",
429
+ class: "flex flex-col gap-4 xs:flex-row xs:flex-wrap xs:gap-8"
430
+ }, Xa = ["id", "aria-selected", "aria-controls", "onClick"], Ja = { class: "flex-1 min-w-0 max-w-[720px]" }, Za = {
431
+ id: "kiosk-settings-panel-ordering",
432
+ role: "tabpanel",
433
+ "aria-labelledby": "kiosk-settings-tab-ordering",
434
+ class: "flex flex-col gap-32"
435
+ }, el = { class: "flex flex-col gap-4" }, al = { class: "fm-typo-en-title-md-600" }, ll = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, tl = { class: "flex flex-col gap-8" }, nl = { class: "fm-typo-en-title-sm-600" }, ol = { class: "flex flex-col gap-16 pt-8" }, sl = { class: "flex flex-col gap-8" }, rl = { class: "ml-[60px] xs:ml-0 flex flex-col gap-8" }, dl = { class: "flex flex-row flex-wrap items-center gap-x-8" }, il = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary" }, ul = { class: "border p-16 fm-corner-radius-lg flex flex-col gap-8" }, cl = { class: "flex flex-col gap-4" }, ml = { class: "fm-typo-en-body-md-600" }, pl = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary" }, yl = { class: "flex flex-col gap-8" }, fl = { class: "ml-[60px] xs:ml-0 flex flex-col gap-8" }, vl = { class: "fm-typo-en-body-md-600" }, bl = { class: "grid grid-cols-4 gap-12 xs:grid-cols-2" }, gl = { class: "flex flex-row flex-wrap items-center gap-x-8" }, xl = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary" }, hl = { class: "border p-16 fm-corner-radius-lg flex flex-col gap-8" }, _l = { class: "flex flex-col gap-4" }, Sl = { class: "fm-typo-en-body-md-600" }, Il = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary" }, kl = { class: "flex flex-col gap-8" }, wl = { class: "fm-typo-en-title-sm-600" }, Cl = { class: "ml-[60px] xs:ml-0 flex flex-col gap-8" }, Vl = { class: "flex flex-row flex-wrap items-center gap-x-8" }, Pl = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary" }, Tl = { class: "border p-16 fm-corner-radius-lg flex flex-col gap-8" }, Nl = { class: "flex flex-col gap-4" }, Al = { class: "fm-typo-en-body-md-600" }, Ul = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary" }, El = { class: "flex flex-col gap-8" }, Rl = { class: "fm-typo-en-title-sm-600" }, Ol = { class: "flex flex-col gap-8" }, Fl = { class: "fm-typo-en-title-sm-600" }, Ll = { class: "flex flex-col gap-8" }, Ml = { class: "fm-typo-en-title-sm-600" }, $l = { class: "ml-[60px] xs:ml-0 flex flex-col gap-8" }, Dl = {
436
+ key: 0,
437
+ class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary",
438
+ "data-testid": "kiosk-table-number-hint-off-note"
439
+ }, Wl = { class: "flex flex-row flex-wrap items-center gap-x-8" }, Hl = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary" }, Gl = {
440
+ class: "border p-16 fm-corner-radius-lg flex flex-col gap-8",
441
+ "data-testid": "kiosk-table-number-hint"
442
+ }, zl = { class: "fm-typo-en-body-md-600" }, Kl = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary" }, jl = { class: "flex flex-col gap-8" }, Yl = { class: "fm-typo-en-title-sm-600" }, Bl = { class: "flex flex-col gap-8" }, ql = { class: "fm-typo-en-title-sm-600" }, Ql = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary" }, Xl = {
443
+ id: "kiosk-settings-panel-look",
444
+ role: "tabpanel",
445
+ "aria-labelledby": "kiosk-settings-tab-look",
446
+ class: "flex flex-col gap-32"
447
+ }, Jl = { class: "flex flex-col gap-4" }, Zl = { class: "fm-typo-en-title-md-600" }, et = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, at = { class: "flex flex-col gap-8" }, lt = { class: "fm-typo-en-title-sm-600" }, tt = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary" }, nt = { class: "ml-[60px] xs:ml-0 grid grid-cols-2 xs:grid-cols-1 gap-8" }, ot = {
448
+ key: 0,
449
+ class: "ml-[60px] xs:ml-0 fm-typo-en-body-sm-400 text-fm-color-system-error-300"
450
+ }, st = { class: "flex flex-col gap-8" }, rt = { class: "fm-typo-en-title-sm-600" }, dt = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary" }, it = { class: "flex flex-row flex-wrap items-end gap-24 pt-4" }, ut = { class: "fm-typo-en-body-sm-600" }, ct = { class: "flex flex-row gap-4" }, mt = ["src", "alt"], pt = ["aria-label"], yt = {
451
+ id: "kiosk-settings-panel-payment",
452
+ role: "tabpanel",
453
+ "aria-labelledby": "kiosk-settings-tab-payment",
454
+ class: "flex flex-col gap-32"
455
+ }, ft = { class: "flex flex-col gap-4" }, vt = { class: "fm-typo-en-title-md-600" }, bt = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, gt = {
456
+ key: 0,
457
+ id: "kiosk-settings-panel-updates",
458
+ role: "tabpanel",
459
+ "aria-labelledby": "kiosk-settings-tab-updates",
460
+ class: "flex flex-col gap-32"
461
+ }, xt = { class: "flex flex-col gap-4" }, ht = { class: "fm-typo-en-title-md-600" }, _t = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, St = { class: "flex flex-col gap-4 max-w-[360px]" }, It = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary" }, kt = { class: "fm-typo-en-title-sm-600 text-fm-color-typo-primary" }, wt = { class: "flex flex-col gap-16" }, Ct = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary" }, Vt = { class: "fm-typo-en-body-md-600" }, Pt = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary" }, Tt = { class: "flex flex-wrap items-start gap-8" }, Nt = { class: "relative" }, At = ["src", "alt"], Ut = { class: "absolute top-2 left-2 px-2 rounded-full bg-fm-color-typo-primary text-fm-color-neutral-white fm-typo-en-body-sm-400" }, Et = { class: "flex items-center gap-1" }, Rt = { key: 0 }, Ot = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary" }, Ft = { class: "w-full flex flex-row items-center justify-between gap-12 xs:flex-col xs:items-stretch" }, Lt = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary" }, Mt = { class: "flex flex-row gap-8" }, $t = { key: 1 }, Dt = 10 * 1e3 * 1e3, be = 24, Bt = /* @__PURE__ */ Re({
462
+ __name: "KioskSettingView",
463
+ props: {
464
+ restaurantId: {},
465
+ form: {},
466
+ save: { type: Function }
467
+ },
468
+ emits: ["dirtyChange"],
469
+ setup(n, { emit: r }) {
470
+ const { t: e } = Le(), c = ga(), b = C(() => {
471
+ var d;
472
+ return ((d = c.sessionUser.value) == null ? void 0 : d.role.isAdmin) ?? !1;
473
+ }), k = C(() => Ya(b.value)), g = R("ordering"), x = {
474
+ ordering: { title: "order.settingsSectionOrdering" },
475
+ look: { title: "order.settingsSectionLook" },
476
+ payment: { title: "order.settingsSectionPayment" },
477
+ updates: { title: "order.settingsSectionUpdates" }
478
+ }, U = R(!1), v = da({
479
+ pickUp: !1,
480
+ displayStand: !1,
481
+ takeaway: !1,
482
+ tableNumber: !1
483
+ }), m = n, N = ha(), z = r;
484
+ function $(d) {
485
+ return structuredClone(ua(d));
486
+ }
487
+ const o = R($(m.form)), j = ie, Y = C(() => o.value.languages != null), h = C(() => o.value.languages ?? []);
488
+ function y(d) {
489
+ o.value.languages = d ? ["en-US"] : null;
490
+ }
491
+ function B(d, s) {
492
+ const p = o.value.languages ?? [];
493
+ o.value.languages = s ? j.filter((f) => f.code === d || p.includes(f.code)).map((f) => f.code) : p.filter((f) => f !== d);
494
+ }
495
+ const q = C(
496
+ () => Pa(o.value.languages)
497
+ ), ce = C(() => {
498
+ const d = o.value.dineIn.displayStand.hint.messages;
499
+ return q.value.some((s) => {
500
+ var p;
501
+ return !!((p = d == null ? void 0 : d[s.code]) != null && p.trim());
502
+ });
503
+ });
504
+ function Q(d, s) {
505
+ const p = o.value.dineIn.displayStand, f = { ...p.hint.messages ?? {} };
506
+ s ? f[d] = s : delete f[d], p.hint.messages = Object.keys(f).length > 0 ? f : null;
507
+ }
508
+ function X(d) {
509
+ const { prefix: s, standSlotRange: p } = o.value.dineIn.displayStand;
510
+ return Ta(d, { prefix: s, min: p.min, max: p.max }) ?? "";
511
+ }
512
+ const D = (d) => d < 0 ? e("order.nonNegativeRule") : !0, I = (d) => d <= (o.value.dineIn.displayStand.standSlotRange.min ?? 0) ? e("order.greaterThanMinRule") : !0, Ke = C(() => [D]), je = C(() => [D]), Ye = C(() => [D, I]), me = C(() => Ba(o.value)), Be = C(() => {
513
+ var p;
514
+ const d = o.value, s = (p = d.otaChannel) == null ? void 0 : p.trim();
515
+ return me.value.length > 0 ? null : {
516
+ ...d,
517
+ otaChannel: s || void 0,
518
+ dineIn: {
519
+ ...d.dineIn,
520
+ displayStand: {
521
+ ...d.dineIn.displayStand,
522
+ enabled: d.dineIn.enabled && d.dineIn.displayStand.enabled,
523
+ padDigit: d.dineIn.displayStand.padDigit ?? 0,
524
+ standSlotRange: {
525
+ min: d.dineIn.displayStand.standSlotRange.min ?? 0,
526
+ max: d.dineIn.displayStand.standSlotRange.max ?? 10
527
+ },
528
+ prefix: d.dineIn.displayStand.prefix ?? "",
529
+ // Every kiosk language's text, ticked or not, without empty ones; none left =
530
+ // the kiosk's own text. Saved whatever `hint.show` is: the texts can be prepared
531
+ // while the hint is off and show once it is switched on.
532
+ hint: {
533
+ show: d.dineIn.displayStand.hint.show,
534
+ messages: Na(d.dineIn.displayStand.hint.messages)
535
+ }
536
+ }
537
+ }
538
+ };
539
+ }), { startAsyncCall: qe } = xa();
540
+ function Qe(d) {
541
+ o.value.paymentSetting.paymentTypes = d;
542
+ }
543
+ function Xe(d) {
544
+ o.value.paymentSetting.ePaymentTypes = d;
545
+ }
546
+ const Je = ba(), xe = [
547
+ {
548
+ value: "landscape",
549
+ labelKey: "order.coverImageLandscape",
550
+ hintKey: "order.coverImageLandscapeHint",
551
+ previewClass: "w-[280px] aspect-video",
552
+ thumbClass: "h-[56px] aspect-video",
553
+ dropClass: "w-[280px] aspect-video"
554
+ },
555
+ {
556
+ value: "portrait",
557
+ labelKey: "order.coverImagePortrait",
558
+ hintKey: "order.coverImagePortraitHint",
559
+ previewClass: "w-[160px] aspect-[9/16]",
560
+ thumbClass: "h-[72px] aspect-[9/16]",
561
+ dropClass: "w-[160px] aspect-[9/16]"
562
+ }
563
+ ];
564
+ function L(d) {
565
+ return Ha(o.value, d);
566
+ }
567
+ const Ze = C(
568
+ () => L("landscape").length > 1 || L("portrait").length > 1
569
+ );
570
+ function pe(d, s) {
571
+ Object.assign(
572
+ o.value,
573
+ za(o.value, d, s)
574
+ );
575
+ }
576
+ function he(d, s, p) {
577
+ pe(d, ja(L(d), s, p));
578
+ }
579
+ function ea(d, s) {
580
+ const p = L(d).filter((f, w) => w !== s);
581
+ pe(d, p);
582
+ }
583
+ const _e = C({
584
+ get: () => o.value.minWeighGrams ?? null,
585
+ set: (d) => {
586
+ o.value.minWeighGrams = typeof d == "number" && Number.isFinite(d) && d >= 1 ? Math.trunc(d) : null;
587
+ }
588
+ }), Se = C({
589
+ get: () => Ga(o.value),
590
+ set: (d) => {
591
+ Object.assign(
592
+ o.value,
593
+ Ka(o.value, d)
594
+ );
595
+ }
596
+ });
597
+ async function aa(d, s) {
598
+ if (!(L(d).length >= te))
599
+ try {
600
+ const p = await qe(async () => {
601
+ const f = `/restaurant/${m.restaurantId}/kiosk/cover-${d}`;
602
+ return await $a(f, s);
603
+ });
604
+ pe(d, [...L(d), p]), N.open({
605
+ title: e("order.imageUploadSuccess"),
606
+ type: "success"
607
+ });
608
+ } catch (p) {
609
+ console.error(p), N.open({
610
+ title: e("order.imageUploadFailed"),
611
+ type: "error"
612
+ });
613
+ }
614
+ }
615
+ function la(d, s) {
616
+ var w, F;
617
+ const p = e(d === "landscape" ? "order.coverImageLandscape" : "order.coverImagePortrait"), f = (F = (w = s[0]) == null ? void 0 : w.reason) == null ? void 0 : F[0];
618
+ N.open({
619
+ title: f ? `${e("order.imageUploadRejected")}: ${p} (${f})` : `${e("order.imageUploadRejected")}: ${p}`,
620
+ type: "error"
621
+ });
622
+ }
623
+ const ta = C(() => Je.getRestaurantEPayment()), Ie = C({
624
+ get: () => (o.value.dineIn.displayStand.enabled && o.value.dineIn.displayStand.enablePaxDialog || o.value.dineIn.pickUp.enablePaxDialog) ?? !1,
625
+ set: (d) => {
626
+ o.value.dineIn.displayStand.enablePaxDialog = d, o.value.dineIn.pickUp.enablePaxDialog = d;
627
+ }
628
+ });
629
+ Pe(
630
+ () => [
631
+ o.value.dineIn.enabled,
632
+ o.value.dineIn.pickUp.enabled,
633
+ o.value.dineIn.displayStand.enabled
634
+ ],
635
+ ([d, s, p], f) => {
636
+ const w = (f == null ? void 0 : f[0]) ?? !1;
637
+ d && !s && !p && (o.value.dineIn.pickUp.enabled = !0, w || N.open({
638
+ title: e("order.dineInModeAutoCorrected"),
639
+ type: "info"
640
+ }));
641
+ },
642
+ { immediate: !0 }
643
+ );
644
+ const ne = R(null), ye = () => JSON.stringify(o.value), J = C(() => ne.value !== null && ye() !== ne.value);
645
+ Pe(J, (d) => z("dirtyChange", d)), ge(async () => {
646
+ await fe(), ne.value = ye();
647
+ });
648
+ async function ke() {
649
+ o.value = $(m.form), await fe(), ne.value = ye();
650
+ }
651
+ const Z = R(!1), oe = R(null), se = R(null), we = R({}), Ce = R(0);
652
+ let K = null;
653
+ function re() {
654
+ var p;
655
+ const d = oe.value;
656
+ if (!d) return;
657
+ const s = d.getBoundingClientRect();
658
+ we.value = {
659
+ left: `${s.left - be}px`,
660
+ width: `${s.width + 2 * be}px`
661
+ }, Ce.value = (((p = se.value) == null ? void 0 : p.offsetHeight) ?? 0) + be;
662
+ }
663
+ ge(() => {
664
+ re(), K = new ResizeObserver(re), oe.value && K.observe(oe.value), se.value && K.observe(se.value), window.addEventListener("resize", re);
665
+ }), ia(() => {
666
+ K == null || K.disconnect(), window.removeEventListener("resize", re);
667
+ });
668
+ async function na() {
669
+ const d = Be.value;
670
+ if (!d) {
671
+ g.value = me.value[0] ?? g.value, N.open({
672
+ title: e("order.failedToUpdateSetting"),
673
+ type: "error"
674
+ });
675
+ return;
676
+ }
677
+ Z.value = !0;
678
+ try {
679
+ await m.save(d), await fe(), await ke();
680
+ } catch {
681
+ } finally {
682
+ Z.value = !1;
683
+ }
684
+ }
685
+ return (d, s) => {
686
+ const p = O("FmIcon"), f = O("FmSwitch"), w = O("FmButton"), F = O("FmTextField"), ee = O("FmStepperField"), oa = O("FmCheckbox"), sa = O("FmDropField"), ra = O("FmDialog");
687
+ return o.value ? (S(), V("div", {
688
+ key: 0,
689
+ ref_key: "formRoot",
690
+ ref: oe,
691
+ class: "flex flex-row gap-32 xs:flex-col xs:gap-16",
692
+ style: Te({ paddingBottom: `${Ce.value}px` })
693
+ }, [
694
+ l("nav", {
695
+ "aria-label": a(e)("order.settingsSectionsLabel"),
696
+ class: "w-[200px] shrink-0 xs:w-full"
697
+ }, [
698
+ l("div", Qa, [
699
+ (S(!0), V(H, null, G(k.value, (t) => (S(), V("button", {
700
+ id: `kiosk-settings-tab-${t}`,
701
+ key: t,
702
+ type: "button",
703
+ role: "tab",
704
+ "aria-selected": g.value === t,
705
+ "aria-controls": `kiosk-settings-panel-${t}`,
706
+ class: ae([
707
+ "flex flex-row items-center justify-between gap-8 px-12 py-8 fm-corner-radius-md text-left whitespace-nowrap fm-typo-en-body-md-600 transition-colors",
708
+ g.value === t ? "bg-fm-color-neutral-gray-100 text-fm-color-typo-primary" : "text-fm-color-typo-secondary hover:bg-fm-color-neutral-gray-100"
709
+ ]),
710
+ onClick: (E) => g.value = t
711
+ }, [
712
+ l("span", null, u(a(e)(x[t].title)), 1),
713
+ me.value.includes(t) ? (S(), le(p, {
714
+ key: 0,
715
+ name: "error",
716
+ size: "sm",
717
+ color: "system-error-300",
718
+ "aria-label": a(e)("order.settingsSectionError")
719
+ }, null, 8, ["aria-label"])) : W("", !0)
720
+ ], 10, Xa))), 128))
721
+ ])
722
+ ], 8, qa),
723
+ l("div", Ja, [
724
+ P(l("section", Za, [
725
+ l("div", el, [
726
+ l("h2", al, u(a(e)("order.settingsSectionOrdering")), 1),
727
+ l("p", ll, u(a(e)("order.settingsSectionOrderingHint")), 1)
728
+ ]),
729
+ l("div", tl, [
730
+ l("span", nl, u(a(e)("order.dineIn")), 1),
731
+ i(f, {
732
+ modelValue: o.value.dineIn.enabled,
733
+ "onUpdate:modelValue": s[0] || (s[0] = (t) => o.value.dineIn.enabled = t),
734
+ label: a(e)("order.dineInSwitch"),
735
+ sublabel: a(e)("order.dineInSwitchHint"),
736
+ "label-placement": "right"
737
+ }, null, 8, ["modelValue", "label", "sublabel"]),
738
+ P(l("div", ol, [
739
+ l("div", sl, [
740
+ i(f, {
741
+ modelValue: o.value.dineIn.pickUp.enabled,
742
+ "onUpdate:modelValue": s[1] || (s[1] = (t) => o.value.dineIn.pickUp.enabled = t),
743
+ label: a(e)("order.pickAtCounter"),
744
+ "label-placement": "right"
745
+ }, null, 8, ["modelValue", "label"]),
746
+ P(l("div", rl, [
747
+ l("div", dl, [
748
+ i(w, {
749
+ class: "-ml-[12px]",
750
+ variant: "tertiary",
751
+ size: "md",
752
+ label: a(e)("order.customiseMessages"),
753
+ "append-icon": v.pickUp ? "expand_less" : "expand_more",
754
+ "aria-expanded": v.pickUp,
755
+ onClick: s[2] || (s[2] = (t) => v.pickUp = !v.pickUp)
756
+ }, null, 8, ["label", "append-icon", "aria-expanded"]),
757
+ l("span", il, u(a(ve)(o.value.dineIn.pickUp.submitOrderInstruction) ? a(e)("order.messagesCustom") : a(e)("order.messagesDefault")), 1)
758
+ ]),
759
+ P(l("div", ul, [
760
+ l("div", cl, [
761
+ l("span", ml, u(a(e)("order.submitOrderInstruction")), 1),
762
+ l("span", pl, u(a(e)("order.submitOrderInstructionHint")), 1)
763
+ ]),
764
+ i(F, {
765
+ modelValue: o.value.dineIn.pickUp.submitOrderInstruction.payAtCounter,
766
+ "onUpdate:modelValue": s[3] || (s[3] = (t) => o.value.dineIn.pickUp.submitOrderInstruction.payAtCounter = t),
767
+ label: a(e)("order.payAtCounter"),
768
+ placeholder: "Collect your transaction slip below and present it to the cashier"
769
+ }, null, 8, ["modelValue", "label"]),
770
+ i(F, {
771
+ modelValue: o.value.dineIn.pickUp.submitOrderInstruction.paid,
772
+ "onUpdate:modelValue": s[4] || (s[4] = (t) => o.value.dineIn.pickUp.submitOrderInstruction.paid = t),
773
+ label: a(e)("order.paid"),
774
+ placeholder: "Please wait as we prepare your food. We'll call your number when it's ready."
775
+ }, null, 8, ["modelValue", "label"])
776
+ ], 512), [
777
+ [T, v.pickUp]
778
+ ])
779
+ ], 512), [
780
+ [T, o.value.dineIn.pickUp.enabled]
781
+ ])
782
+ ]),
783
+ l("div", yl, [
784
+ i(f, {
785
+ modelValue: o.value.dineIn.displayStand.enabled,
786
+ "onUpdate:modelValue": s[5] || (s[5] = (t) => o.value.dineIn.displayStand.enabled = t),
787
+ label: a(e)("order.displayStand"),
788
+ "label-placement": "right"
789
+ }, null, 8, ["modelValue", "label"]),
790
+ P(l("div", fl, [
791
+ l("span", vl, u(a(e)("order.tableServiceSetting")), 1),
792
+ l("div", bl, [
793
+ i(F, {
794
+ modelValue: o.value.dineIn.displayStand.prefix,
795
+ "onUpdate:modelValue": s[6] || (s[6] = (t) => o.value.dineIn.displayStand.prefix = t),
796
+ label: a(e)("order.prefix"),
797
+ placeholder: a(e)("order.prefix")
798
+ }, null, 8, ["modelValue", "label", "placeholder"]),
799
+ i(ee, {
800
+ modelValue: o.value.dineIn.displayStand.standSlotRange.min,
801
+ "onUpdate:modelValue": s[7] || (s[7] = (t) => o.value.dineIn.displayStand.standSlotRange.min = t),
802
+ label: a(e)("order.start"),
803
+ labelMark: "required",
804
+ rules: je.value,
805
+ placeholder: a(e)("order.enterANumber")
806
+ }, null, 8, ["modelValue", "label", "rules", "placeholder"]),
807
+ i(ee, {
808
+ modelValue: o.value.dineIn.displayStand.standSlotRange.max,
809
+ "onUpdate:modelValue": s[8] || (s[8] = (t) => o.value.dineIn.displayStand.standSlotRange.max = t),
810
+ label: a(e)("order.end"),
811
+ labelMark: "required",
812
+ rules: Ye.value,
813
+ placeholder: a(e)("order.enterANumber")
814
+ }, null, 8, ["modelValue", "label", "rules", "placeholder"]),
815
+ i(ee, {
816
+ modelValue: o.value.dineIn.displayStand.padDigit,
817
+ "onUpdate:modelValue": s[9] || (s[9] = (t) => o.value.dineIn.displayStand.padDigit = t),
818
+ label: a(e)("order.padDigit"),
819
+ labelMark: "required",
820
+ rules: Ke.value,
821
+ placeholder: a(e)("order.padDigit")
822
+ }, null, 8, ["modelValue", "label", "rules", "placeholder"])
823
+ ]),
824
+ l("div", gl, [
825
+ i(w, {
826
+ class: "-ml-[12px]",
827
+ variant: "tertiary",
828
+ size: "md",
829
+ label: a(e)("order.customiseMessages"),
830
+ "append-icon": v.displayStand ? "expand_less" : "expand_more",
831
+ "aria-expanded": v.displayStand,
832
+ onClick: s[10] || (s[10] = (t) => v.displayStand = !v.displayStand)
833
+ }, null, 8, ["label", "append-icon", "aria-expanded"]),
834
+ l("span", xl, u(a(ve)(o.value.dineIn.displayStand.submitOrderInstruction) ? a(e)("order.messagesCustom") : a(e)("order.messagesDefault")), 1)
835
+ ]),
836
+ P(l("div", hl, [
837
+ l("div", _l, [
838
+ l("span", Sl, u(a(e)("order.submitOrderInstruction")), 1),
839
+ l("span", Il, u(a(e)("order.submitOrderInstructionHint")), 1)
840
+ ]),
841
+ i(F, {
842
+ modelValue: o.value.dineIn.displayStand.submitOrderInstruction.payAtCounter,
843
+ "onUpdate:modelValue": s[11] || (s[11] = (t) => o.value.dineIn.displayStand.submitOrderInstruction.payAtCounter = t),
844
+ label: a(e)("order.payAtCounter"),
845
+ placeholder: "Collect your transaction slip below and present it to the cashier"
846
+ }, null, 8, ["modelValue", "label"]),
847
+ i(F, {
848
+ modelValue: o.value.dineIn.displayStand.submitOrderInstruction.paid,
849
+ "onUpdate:modelValue": s[12] || (s[12] = (t) => o.value.dineIn.displayStand.submitOrderInstruction.paid = t),
850
+ label: a(e)("order.paid"),
851
+ placeholder: "Please collect your receipt and we'll bring your food to your table once it's ready."
852
+ }, null, 8, ["modelValue", "label"])
853
+ ], 512), [
854
+ [T, v.displayStand]
855
+ ])
856
+ ], 512), [
857
+ [T, o.value.dineIn.displayStand.enabled]
858
+ ])
859
+ ])
860
+ ], 512), [
861
+ [T, o.value.dineIn.enabled]
862
+ ])
863
+ ]),
864
+ l("div", kl, [
865
+ l("span", wl, u(a(e)("order.takeawayTitle")), 1),
866
+ i(f, {
867
+ modelValue: o.value.takeaway.enabled,
868
+ "onUpdate:modelValue": s[13] || (s[13] = (t) => o.value.takeaway.enabled = t),
869
+ label: a(e)("order.takeawaySwitch"),
870
+ "label-placement": "right"
871
+ }, null, 8, ["modelValue", "label"]),
872
+ P(l("div", Cl, [
873
+ l("div", Vl, [
874
+ i(w, {
875
+ class: "-ml-[12px]",
876
+ variant: "tertiary",
877
+ size: "md",
878
+ label: a(e)("order.customiseMessages"),
879
+ "append-icon": v.takeaway ? "expand_less" : "expand_more",
880
+ "aria-expanded": v.takeaway,
881
+ onClick: s[14] || (s[14] = (t) => v.takeaway = !v.takeaway)
882
+ }, null, 8, ["label", "append-icon", "aria-expanded"]),
883
+ l("span", Pl, u(a(ve)(o.value.takeaway.submitOrderInstruction) ? a(e)("order.messagesCustom") : a(e)("order.messagesDefault")), 1)
884
+ ]),
885
+ P(l("div", Tl, [
886
+ l("div", Nl, [
887
+ l("span", Al, u(a(e)("order.submitOrderInstruction")), 1),
888
+ l("span", Ul, u(a(e)("order.submitOrderInstructionHint")), 1)
889
+ ]),
890
+ i(F, {
891
+ modelValue: o.value.takeaway.submitOrderInstruction.payAtCounter,
892
+ "onUpdate:modelValue": s[15] || (s[15] = (t) => o.value.takeaway.submitOrderInstruction.payAtCounter = t),
893
+ label: a(e)("order.payAtCounter"),
894
+ placeholder: "Collect your transaction slip below and present it to the cashier"
895
+ }, null, 8, ["modelValue", "label"]),
896
+ i(F, {
897
+ modelValue: o.value.takeaway.submitOrderInstruction.paid,
898
+ "onUpdate:modelValue": s[16] || (s[16] = (t) => o.value.takeaway.submitOrderInstruction.paid = t),
899
+ label: a(e)("order.paid"),
900
+ placeholder: "Please wait as we prepare your food. We'll call your number when it's ready."
901
+ }, null, 8, ["modelValue", "label"])
902
+ ], 512), [
903
+ [T, v.takeaway]
904
+ ])
905
+ ], 512), [
906
+ [T, o.value.takeaway.enabled]
907
+ ])
908
+ ]),
909
+ l("div", El, [
910
+ l("span", Rl, u(a(e)("order.kioskOrderNumber")), 1),
911
+ i(F, {
912
+ modelValue: o.value.dineIn.sequenceNumber.prefix,
913
+ "onUpdate:modelValue": s[17] || (s[17] = (t) => o.value.dineIn.sequenceNumber.prefix = t),
914
+ class: "max-w-[360px]",
915
+ label: a(e)("order.kioskOrderNumberPrefix"),
916
+ placeholder: "#K",
917
+ "helper-text": a(e)("order.kioskOrderNumberHint")
918
+ }, null, 8, ["modelValue", "label", "helper-text"]),
919
+ i(f, {
920
+ modelValue: o.value.shareNumber,
921
+ "onUpdate:modelValue": s[18] || (s[18] = (t) => o.value.shareNumber = t),
922
+ label: a(e)("order.kioskShareNumber"),
923
+ sublabel: a(e)("order.kioskShareNumberSublabel"),
924
+ "label-placement": "right"
925
+ }, null, 8, ["modelValue", "label", "sublabel"])
926
+ ]),
927
+ l("div", Ol, [
928
+ l("span", Fl, u(a(e)("order.displayPaxDialogTitle")), 1),
929
+ i(f, {
930
+ modelValue: Ie.value,
931
+ "onUpdate:modelValue": s[19] || (s[19] = (t) => Ie.value = t),
932
+ label: a(e)("order.displayPaxDialogDescription"),
933
+ sublabel: a(e)("order.paxDialogTabletNote"),
934
+ "label-placement": "right"
935
+ }, null, 8, ["modelValue", "label", "sublabel"])
936
+ ]),
937
+ P(l("div", Ll, [
938
+ l("span", Ml, u(a(e)("order.tableNumber")), 1),
939
+ i(f, {
940
+ modelValue: o.value.dineIn.displayStand.hint.show,
941
+ "onUpdate:modelValue": s[20] || (s[20] = (t) => o.value.dineIn.displayStand.hint.show = t),
942
+ label: a(e)("order.showHintMessage"),
943
+ sublabel: a(e)("order.showHintMessageSublabel"),
944
+ "label-placement": "right"
945
+ }, null, 8, ["modelValue", "label", "sublabel"]),
946
+ l("div", $l, [
947
+ o.value.dineIn.displayStand.hint.show ? W("", !0) : (S(), V("span", Dl, u(a(e)("order.hintMessageOffNote")), 1)),
948
+ l("div", Wl, [
949
+ i(w, {
950
+ class: "-ml-[12px]",
951
+ variant: "tertiary",
952
+ size: "md",
953
+ label: a(e)("order.customiseMessages"),
954
+ "append-icon": v.tableNumber ? "expand_less" : "expand_more",
955
+ "aria-expanded": v.tableNumber,
956
+ onClick: s[21] || (s[21] = (t) => v.tableNumber = !v.tableNumber)
957
+ }, null, 8, ["label", "append-icon", "aria-expanded"]),
958
+ l("span", Hl, u(ce.value ? a(e)("order.messagesCustom") : a(e)("order.messagesDefault")), 1)
959
+ ]),
960
+ P(l("div", Gl, [
961
+ l("span", zl, u(a(e)("order.hintMessage")), 1),
962
+ (S(!0), V(H, null, G(q.value, (t) => {
963
+ var E;
964
+ return S(), le(F, {
965
+ key: t.code,
966
+ "model-value": ((E = o.value.dineIn.displayStand.hint.messages) == null ? void 0 : E[t.code]) ?? "",
967
+ label: t.label,
968
+ placeholder: X(t.code),
969
+ "max-length": a(fa),
970
+ "onUpdate:modelValue": (A) => Q(t.code, A)
971
+ }, null, 8, ["model-value", "label", "placeholder", "max-length", "onUpdate:modelValue"]);
972
+ }), 128)),
973
+ l("span", Kl, u(a(e)("order.customiseHintMessageEmpty")), 1)
974
+ ], 512), [
975
+ [T, v.tableNumber]
976
+ ])
977
+ ])
978
+ ], 512), [
979
+ [T, o.value.dineIn.enabled && o.value.dineIn.displayStand.enabled]
980
+ ]),
981
+ l("div", jl, [
982
+ l("span", Yl, u(a(e)("order.menuItem")), 1),
983
+ i(f, {
984
+ modelValue: o.value.menuItem.showAllOnly,
985
+ "onUpdate:modelValue": s[22] || (s[22] = (t) => o.value.menuItem.showAllOnly = t),
986
+ label: a(e)("order.showNotAvailableMenuItem"),
987
+ "label-placement": "right"
988
+ }, null, 8, ["modelValue", "label"])
989
+ ]),
990
+ l("div", Bl, [
991
+ l("span", ql, u(a(e)("order.minWeighGrams")), 1),
992
+ l("div", null, [
993
+ i(ee, {
994
+ modelValue: _e.value,
995
+ "onUpdate:modelValue": s[23] || (s[23] = (t) => _e.value = t),
996
+ class: "max-w-[240px]",
997
+ label: a(e)("order.minWeighGramsLabel"),
998
+ min: 1,
999
+ max: a(ze),
1000
+ placeholder: a(e)("order.minWeighGramsPlaceholder")
1001
+ }, null, 8, ["modelValue", "label", "max", "placeholder"]),
1002
+ l("span", Ql, u(a(e)("order.minWeighGramsHint")), 1)
1003
+ ])
1004
+ ])
1005
+ ], 512), [
1006
+ [T, g.value === "ordering"]
1007
+ ]),
1008
+ P(l("section", Xl, [
1009
+ l("div", Jl, [
1010
+ l("h2", Zl, u(a(e)("order.settingsSectionLook")), 1),
1011
+ l("p", et, u(a(e)("order.settingsSectionLookHint")), 1)
1012
+ ]),
1013
+ l("div", at, [
1014
+ l("span", lt, u(a(e)("order.kioskLanguage")), 1),
1015
+ l("span", tt, u(a(e)("order.kioskLanguageHint")), 1),
1016
+ i(f, {
1017
+ "model-value": Y.value,
1018
+ label: a(e)("order.kioskLanguageRestrict"),
1019
+ sublabel: a(e)("order.kioskLanguageRestrictSublabel"),
1020
+ "label-placement": "right",
1021
+ "onUpdate:modelValue": y
1022
+ }, null, 8, ["model-value", "label", "sublabel"]),
1023
+ P(l("div", nt, [
1024
+ (S(!0), V(H, null, G(a(j), (t) => (S(), le(oa, {
1025
+ key: t.code,
1026
+ "model-value": h.value.includes(t.code),
1027
+ value: t.code,
1028
+ label: t.label,
1029
+ "onUpdate:modelValue": (E) => B(t.code, E)
1030
+ }, null, 8, ["model-value", "value", "label", "onUpdate:modelValue"]))), 128))
1031
+ ], 512), [
1032
+ [T, Y.value]
1033
+ ]),
1034
+ Y.value && h.value.length === 0 ? (S(), V("span", ot, u(a(e)("order.kioskLanguageAtLeastOne")), 1)) : W("", !0)
1035
+ ]),
1036
+ l("div", st, [
1037
+ l("span", rt, u(a(e)("order.coverImage")), 1),
1038
+ l("span", dt, u(a(e)("order.coverImageFallbackHint")), 1),
1039
+ l("div", it, [
1040
+ (S(), V(H, null, G(xe, (t) => l("div", {
1041
+ key: `cover-preview-${t.value}`,
1042
+ class: "flex flex-col gap-8"
1043
+ }, [
1044
+ l("span", ut, u(a(e)(t.labelKey)) + " · " + u(a(e)("order.coverImageCount", {
1045
+ count: L(t.value).length,
1046
+ max: a(te)
1047
+ })), 1),
1048
+ l("div", ct, [
1049
+ (S(!0), V(H, null, G(L(t.value).slice(0, 4), (E, A) => (S(), V("img", {
1050
+ key: `cover-preview-${t.value}-${A}`,
1051
+ src: E,
1052
+ alt: `${a(e)(t.labelKey)} ${A + 1}`,
1053
+ class: ae([t.thumbClass, "object-cover rounded-md border border-fm-color-neutral-gray-200"])
1054
+ }, null, 10, mt))), 128)),
1055
+ L(t.value).length === 0 ? (S(), V("div", {
1056
+ key: 0,
1057
+ role: "img",
1058
+ "aria-label": a(e)("order.coverNoImage"),
1059
+ class: ae([t.thumbClass, "rounded-md border border-dashed border-fm-color-neutral-gray-400"])
1060
+ }, null, 10, pt)) : W("", !0)
1061
+ ])
1062
+ ])), 64)),
1063
+ i(w, {
1064
+ variant: "secondary",
1065
+ size: "md",
1066
+ "prepend-icon": "edit",
1067
+ label: a(e)("order.changeCovers"),
1068
+ onClick: s[24] || (s[24] = (t) => U.value = !0)
1069
+ }, null, 8, ["label"])
1070
+ ])
1071
+ ])
1072
+ ], 512), [
1073
+ [T, g.value === "look"]
1074
+ ]),
1075
+ P(l("section", yt, [
1076
+ l("div", ft, [
1077
+ l("h2", vt, u(a(e)("order.settingsSectionPayment")), 1),
1078
+ l("p", bt, u(a(e)("order.settingsSectionPaymentHint")), 1)
1079
+ ]),
1080
+ i(wa, {
1081
+ "payment-types": o.value.paymentSetting.paymentTypes ?? [],
1082
+ "allow-credit": !0,
1083
+ "allow-e-payment": ta.value,
1084
+ "offline-payment-types": o.value.paymentSetting.offlinePaymentTypes ?? [],
1085
+ ePaymentTypes: o.value.paymentSetting.ePaymentTypes ?? {},
1086
+ "onUpdate:paymentTypes": Qe,
1087
+ "onUpdate:offlinePaymentTypes": s[25] || (s[25] = (t) => o.value.paymentSetting.offlinePaymentTypes = t),
1088
+ "onUpdate:ePaymentTypes": Xe
1089
+ }, null, 8, ["payment-types", "allow-e-payment", "offline-payment-types", "ePaymentTypes"]),
1090
+ W("", !0)
1091
+ ], 512), [
1092
+ [T, g.value === "payment"]
1093
+ ]),
1094
+ b.value ? P((S(), V("section", gt, [
1095
+ l("div", xt, [
1096
+ l("h2", ht, u(a(e)("order.settingsSectionUpdates")), 1),
1097
+ l("p", _t, u(a(e)("order.settingsSectionUpdatesHint")), 1)
1098
+ ]),
1099
+ l("div", St, [
1100
+ i(F, {
1101
+ modelValue: o.value.otaChannel,
1102
+ "onUpdate:modelValue": s[27] || (s[27] = (t) => o.value.otaChannel = t),
1103
+ label: a(e)("order.otaChannel")
1104
+ }, null, 8, ["modelValue", "label"]),
1105
+ l("span", It, u(a(e)("order.otaChannelHint")), 1)
1106
+ ])
1107
+ ], 512)), [
1108
+ [T, g.value === "updates"]
1109
+ ]) : W("", !0)
1110
+ ]),
1111
+ i(ra, {
1112
+ modelValue: U.value,
1113
+ "onUpdate:modelValue": s[30] || (s[30] = (t) => U.value = t),
1114
+ "max-width": 800
1115
+ }, {
1116
+ "dialog-header": M(() => [
1117
+ l("div", kt, u(a(e)("order.coverImage")), 1)
1118
+ ]),
1119
+ "dialog-footer": M(() => [
1120
+ l("div", Ft, [
1121
+ l("span", Lt, u(a(e)("order.coverDialogNote")), 1),
1122
+ i(w, {
1123
+ variant: "primary",
1124
+ label: a(e)("order.done"),
1125
+ onClick: s[29] || (s[29] = (t) => U.value = !1)
1126
+ }, null, 8, ["label"])
1127
+ ])
1128
+ ]),
1129
+ default: M(() => [
1130
+ l("div", wt, [
1131
+ l("span", Ct, u(a(e)("order.coverCarouselHint", { max: a(te) })), 1),
1132
+ (S(), V(H, null, G(xe, (t) => l("div", {
1133
+ key: t.value,
1134
+ class: "border p-16 fm-corner-radius-lg flex flex-col gap-8"
1135
+ }, [
1136
+ l("span", Vt, u(a(e)(t.labelKey)), 1),
1137
+ l("span", Pt, u(a(e)(t.hintKey)), 1),
1138
+ l("div", Tt, [
1139
+ (S(!0), V(H, null, G(L(t.value), (E, A) => (S(), V("div", {
1140
+ key: `${t.value}-${A}-${E}`,
1141
+ class: "flex flex-col gap-2"
1142
+ }, [
1143
+ l("div", Nt, [
1144
+ l("img", {
1145
+ src: E,
1146
+ alt: `${a(e)(t.labelKey)} ${A + 1}`,
1147
+ class: ae([
1148
+ t.previewClass,
1149
+ "object-cover rounded-md border border-fm-color-neutral-gray-200"
1150
+ ])
1151
+ }, null, 10, At),
1152
+ l("span", Ut, u(A + 1), 1)
1153
+ ]),
1154
+ l("div", Et, [
1155
+ i(w, {
1156
+ variant: "tertiary",
1157
+ size: "md",
1158
+ "prepend-icon": "arrow_back",
1159
+ disabled: A === 0,
1160
+ "aria-label": a(e)("order.coverCarouselMoveEarlier"),
1161
+ onClick: (Ve) => he(t.value, A, A - 1)
1162
+ }, null, 8, ["disabled", "aria-label", "onClick"]),
1163
+ i(w, {
1164
+ variant: "tertiary",
1165
+ size: "md",
1166
+ "prepend-icon": "arrow_forward",
1167
+ disabled: A === L(t.value).length - 1,
1168
+ "aria-label": a(e)("order.coverCarouselMoveLater"),
1169
+ onClick: (Ve) => he(t.value, A, A + 1)
1170
+ }, null, 8, ["disabled", "aria-label", "onClick"]),
1171
+ i(w, {
1172
+ variant: "tertiary",
1173
+ size: "md",
1174
+ "prepend-icon": "delete",
1175
+ "aria-label": a(e)("common.delete"),
1176
+ onClick: (Ve) => ea(t.value, A)
1177
+ }, null, 8, ["aria-label", "onClick"])
1178
+ ])
1179
+ ]))), 128)),
1180
+ L(t.value).length < a(te) ? (S(), le(sa, {
1181
+ key: 0,
1182
+ accept: "image/*",
1183
+ "max-file-size": Dt,
1184
+ "content-class": t.dropClass,
1185
+ onFileUpload: (E) => aa(t.value, E),
1186
+ onFileRejected: (E) => la(t.value, E)
1187
+ }, null, 8, ["content-class", "onFileUpload", "onFileRejected"])) : W("", !0)
1188
+ ])
1189
+ ])), 64)),
1190
+ Ze.value ? (S(), V("div", Rt, [
1191
+ i(ee, {
1192
+ modelValue: Se.value,
1193
+ "onUpdate:modelValue": s[28] || (s[28] = (t) => Se.value = t),
1194
+ class: "max-w-[240px]",
1195
+ label: a(e)("order.coverCarouselInterval"),
1196
+ min: a($e),
1197
+ max: a(De),
1198
+ placeholder: String(a(Ee))
1199
+ }, null, 8, ["modelValue", "label", "min", "max", "placeholder"]),
1200
+ l("span", Ot, u(a(e)("order.coverCarouselIntervalHint", { seconds: a(Ee) })), 1)
1201
+ ])) : W("", !0)
1202
+ ])
1203
+ ]),
1204
+ _: 1
1205
+ }, 8, ["modelValue"]),
1206
+ l("div", {
1207
+ ref_key: "saveBar",
1208
+ ref: se,
1209
+ class: "fixed bottom-0 z-[1] px-24 py-12 bg-fm-color-neutral-white border-t border-fm-color-neutral-gray-200 flex flex-row items-center justify-between gap-12 xs:flex-col xs:items-stretch",
1210
+ style: Te(we.value),
1211
+ "data-testid": "kiosk-settings-save-bar"
1212
+ }, [
1213
+ l("span", {
1214
+ class: ae(["fm-typo-en-body-md-600", J.value ? "text-fm-color-typo-primary" : "text-fm-color-typo-secondary"])
1215
+ }, u(J.value ? a(e)("order.unsavedChanges") : a(e)("order.allChangesSaved")), 3),
1216
+ l("div", Mt, [
1217
+ i(w, {
1218
+ class: "xs:flex-1",
1219
+ variant: "tertiary",
1220
+ label: a(e)("order.discardChanges"),
1221
+ disabled: !J.value || Z.value,
1222
+ onClick: ke
1223
+ }, null, 8, ["label", "disabled"]),
1224
+ i(w, {
1225
+ class: "xs:flex-1",
1226
+ variant: "primary",
1227
+ label: a(e)("order.updateSetting"),
1228
+ disabled: !J.value || Z.value,
1229
+ loading: Z.value,
1230
+ onClick: na
1231
+ }, null, 8, ["label", "disabled", "loading"])
1232
+ ])
1233
+ ], 4)
1234
+ ], 4)) : (S(), V("div", $t, u(a(e)("order.pleaseSelectRestaurant")), 1));
1235
+ };
1236
+ }
1237
+ });
1238
+ export {
1239
+ Bt as default
1240
+ };