@konnectio/core 4.0.41 → 4.0.43

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 (75) hide show
  1. package/dist/{ActionField-79f8bfae.cjs → ActionField-43360bd2.cjs} +1 -1
  2. package/dist/{ActionField-054975da.js → ActionField-46bc1332.js} +2 -2
  3. package/dist/ActionField-46bc1332.js.br +0 -0
  4. package/dist/{AvailabilitySkeleton-c92fc1d1.cjs → AvailabilitySkeleton-0a70de37.cjs} +1 -1
  5. package/dist/{AvailabilitySkeleton-3e6890a1.js → AvailabilitySkeleton-f86f40b9.js} +5 -5
  6. package/dist/AvailabilitySkeleton-f86f40b9.js.br +0 -0
  7. package/dist/CheckoutWindow-046e2e84.js +202 -0
  8. package/dist/CheckoutWindow-046e2e84.js.br +0 -0
  9. package/dist/CheckoutWindow-a2dfaa01.cjs +1 -0
  10. package/dist/{DateField.vue_vue_type_style_index_0_lang-77ca2367.js → DateField.vue_vue_type_style_index_0_lang-10d7dd19.js} +3030 -3015
  11. package/dist/DateField.vue_vue_type_style_index_0_lang-10d7dd19.js.br +0 -0
  12. package/dist/DateField.vue_vue_type_style_index_0_lang-a4c0f28b.cjs +2 -0
  13. package/dist/{Field-73b09327.cjs → Field-0588c03e.cjs} +1 -1
  14. package/dist/{Field-dffa8f30.js → Field-a28f1e97.js} +2 -2
  15. package/dist/Field-a28f1e97.js.br +0 -0
  16. package/dist/{NumberField.vue_vue_type_script_setup_true_lang-1108dcd6.cjs → NumberField.vue_vue_type_script_setup_true_lang-01f7e3ee.cjs} +1 -1
  17. package/dist/{NumberField.vue_vue_type_script_setup_true_lang-3517aeda.js → NumberField.vue_vue_type_script_setup_true_lang-9edbbae0.js} +1 -1
  18. package/dist/NumberField.vue_vue_type_script_setup_true_lang-9edbbae0.js.br +0 -0
  19. package/dist/{SelectField.vue_vue_type_style_index_0_lang-9544cd25.cjs → SelectField.vue_vue_type_style_index_0_lang-88de73f4.cjs} +39 -39
  20. package/dist/{SelectField.vue_vue_type_style_index_0_lang-bc4ca9a5.js → SelectField.vue_vue_type_style_index_0_lang-fbce2406.js} +47 -46
  21. package/dist/SelectField.vue_vue_type_style_index_0_lang-fbce2406.js.br +0 -0
  22. package/dist/{ThankYou-d42a4e49.js → ThankYou-0b7441d8.js} +5371 -4370
  23. package/dist/ThankYou-0b7441d8.js.br +0 -0
  24. package/dist/ThankYou-2acb4fdf.cjs +59 -0
  25. package/dist/{_-b8fd5e7f.cjs → _-357f8de1.cjs} +1 -1
  26. package/dist/{_-f51b7e1b.js → _-5f328ff3.js} +1 -1
  27. package/dist/availability.cjs +1 -1
  28. package/dist/availability.js +7 -7
  29. package/dist/availability.js.br +0 -0
  30. package/dist/components/forms/ReservationForm.vue.d.ts +2 -1
  31. package/dist/components/forms/ReservationForm.vue.d.ts.map +1 -1
  32. package/dist/components/listings/Base.vue.d.ts +1 -1
  33. package/dist/components/side-panels/Base.vue.d.ts +1 -1
  34. package/dist/components/side-panels/ListingInfo.vue.d.ts +5 -0
  35. package/dist/components/side-panels/ListingInfo.vue.d.ts.map +1 -0
  36. package/dist/components/side-panels/TermsOfService.vue.d.ts +5 -0
  37. package/dist/components/side-panels/TermsOfService.vue.d.ts.map +1 -0
  38. package/dist/components/views/TermsOfService.vue.d.ts +1 -1
  39. package/dist/{event-0c5b54ea.js → event-7eca2398.js} +7 -7
  40. package/dist/event-7eca2398.js.br +0 -0
  41. package/dist/{event-6671499b.cjs → event-b8c5517e.cjs} +1 -1
  42. package/dist/event.cjs +1 -1
  43. package/dist/event.js +108 -109
  44. package/dist/event.js.br +0 -0
  45. package/dist/gift-card-validation.cjs +1 -1
  46. package/dist/gift-card-validation.js +3 -3
  47. package/dist/gift-card-validation.js.br +0 -0
  48. package/dist/gift-card.cjs +1 -1
  49. package/dist/gift-card.js +293 -301
  50. package/dist/gift-card.js.br +0 -0
  51. package/dist/hotel.cjs +8 -8
  52. package/dist/hotel.js +1633 -2070
  53. package/dist/hotel.js.br +0 -0
  54. package/dist/layouts/Hotel.vue.d.ts +5 -0
  55. package/dist/polyfill.cjs +1 -1
  56. package/dist/polyfill.js +1 -1
  57. package/dist/polyfill.js.br +0 -0
  58. package/dist/style.css +1 -1
  59. package/dist/style.css.br +0 -0
  60. package/package.json +6 -6
  61. package/dist/ActionField-054975da.js.br +0 -0
  62. package/dist/AvailabilitySkeleton-3e6890a1.js.br +0 -0
  63. package/dist/DateField.vue_vue_type_style_index_0_lang-56ca7795.cjs +0 -2
  64. package/dist/DateField.vue_vue_type_style_index_0_lang-77ca2367.js.br +0 -0
  65. package/dist/Field-dffa8f30.js.br +0 -0
  66. package/dist/NumberField.vue_vue_type_script_setup_true_lang-3517aeda.js.br +0 -0
  67. package/dist/SelectField.vue_vue_type_style_index_0_lang-bc4ca9a5.js.br +0 -0
  68. package/dist/ThankYou-d42a4e49.js.br +0 -0
  69. package/dist/ThankYou-da4c5f50.cjs +0 -54
  70. package/dist/components/modals/Terms.vue.d.ts +0 -4
  71. package/dist/components/modals/Terms.vue.d.ts.map +0 -1
  72. package/dist/event-0c5b54ea.js.br +0 -0
  73. package/dist/index-2920831d.cjs +0 -1
  74. package/dist/index-906997b4.js +0 -375
  75. package/dist/index-906997b4.js.br +0 -0
package/dist/event.js CHANGED
@@ -1,13 +1,13 @@
1
- import { k as ge, D as ke, b as Qe, s as z, c as he, r as We, f as Ye, m as t, n as b, W as ze, w as g, A as l, p as r, H as k, F as n, q as e, X as He, Y as ie, v as i, Z as re, x as u, $ as Je, J as $, a0 as Ke, _ as fe, o as Xe, a1 as Ze, G as D, a2 as V, a3 as w, a4 as ue, O as de, T as me, a5 as ce, a6 as je, a7 as G, K as pe, M as Ge, P as xe, Q as el, U as ll, a8 as nl, R as tl, V as al, a9 as ol } from "./SelectField.vue_vue_type_style_index_0_lang-bc4ca9a5.js";
2
- import { B as sl, M as il, R as rl, T as ul, x as dl } from "./ThankYou-d42a4e49.js";
3
- import { u as H } from "./event-0c5b54ea.js";
4
- import { A as ml } from "./ActionField-054975da.js";
5
- import { P as cl, C as ve, a as pl, S as vl } from "./index-906997b4.js";
6
- import { _ as bl } from "./DateField.vue_vue_type_style_index_0_lang-77ca2367.js";
7
- import { _ as x } from "./NumberField.vue_vue_type_script_setup_true_lang-3517aeda.js";
1
+ import { k as ge, D as he, b as Qe, s as z, c as ke, r as We, f as Ye, m as t, n as b, W as ze, w as g, A as l, p as r, H as h, F as n, q as e, X as He, Y as ie, v as i, Z as re, x as u, $ as Je, J as $, a0 as Ke, _ as fe, o as Xe, a1 as Ze, G as D, a2 as V, a3 as w, a4 as ue, O as de, T as me, a5 as ce, a6 as je, a7 as G, K as pe, M as Ge, P as xe, Q as el, U as ll, a8 as nl, R as tl, V as al, a9 as ol } from "./SelectField.vue_vue_type_style_index_0_lang-fbce2406.js";
2
+ import { B as sl, M as il, R as rl, T as ul, x as dl } from "./ThankYou-0b7441d8.js";
3
+ import { u as H } from "./event-7eca2398.js";
4
+ import { A as ml } from "./ActionField-46bc1332.js";
5
+ import { P as cl, C as ve, a as pl } from "./CheckoutWindow-046e2e84.js";
6
+ import { _ as vl } from "./DateField.vue_vue_type_style_index_0_lang-10d7dd19.js";
7
+ import { _ as x } from "./NumberField.vue_vue_type_script_setup_true_lang-9edbbae0.js";
8
8
  import "./_commonjsHelpers-aeeeeb92.js";
9
- import "./_-f51b7e1b.js";
10
- const gl = { class: "fresh-booking-event-listing-information" }, kl = { key: 0 }, hl = { key: 1 }, fl = /* @__PURE__ */ ge({
9
+ import "./_-5f328ff3.js";
10
+ const bl = { class: "fresh-booking-event-listing-information" }, gl = { key: 0 }, hl = { key: 1 }, kl = /* @__PURE__ */ ge({
11
11
  __name: "Event",
12
12
  props: {
13
13
  name: {},
@@ -29,23 +29,23 @@ const gl = { class: "fresh-booking-event-listing-information" }, kl = { key: 0 }
29
29
  trackingEnabled: { type: Boolean },
30
30
  callback: {}
31
31
  },
32
- setup(L) {
33
- const { t: a } = ke(), v = L, { display: E } = Qe(), { currency: I } = z(he()), {
34
- maxNumberOfPeople: U,
32
+ setup(C) {
33
+ const { t: a } = he(), v = C, { display: E } = Qe(), { currency: I } = z(ke()), {
34
+ maxNumberOfPeople: L,
35
35
  numberOfPeople: J,
36
- eventId: B,
36
+ eventId: U,
37
37
  tableGroupId: R
38
38
  } = z(H()), {
39
- getTemplateAvailability: S,
40
- getEventAvailability: N,
39
+ getTemplateAvailability: N,
40
+ getEventAvailability: S,
41
41
  isEventListingLoading: O
42
42
  } = H(), P = We(0), Q = Ye(() => O(v.listingId)), K = () => {
43
- P.value > 0 ? (B.value = v.listingId, J.value = P.value, S(v.callback)) : E({
43
+ P.value > 0 ? (U.value = v.listingId, J.value = P.value, N(v.callback)) : E({
44
44
  type: "error",
45
45
  message: a("alert.error.selectPeople")
46
46
  });
47
- }, h = () => {
48
- P.value > 0 ? (B.value = v.listingId, R.value = v.tableGroupId, J.value = P.value, N(v.callback)) : E({
47
+ }, k = () => {
48
+ P.value > 0 ? (U.value = v.listingId, R.value = v.tableGroupId, J.value = P.value, S(v.callback)) : E({
49
49
  type: "error",
50
50
  message: a("alert.error.selectPeople")
51
51
  });
@@ -60,16 +60,16 @@ const gl = { class: "fresh-booking-event-listing-information" }, kl = { key: 0 }
60
60
  action: g(() => [
61
61
  r(ml, {
62
62
  modelValue: P.value,
63
- "onUpdate:modelValue": f[0] || (f[0] = (F) => P.value = F),
63
+ "onUpdate:modelValue": f[0] || (f[0] = (B) => P.value = B),
64
64
  type: "number",
65
65
  label: e(a)("event.numberOfGuests"),
66
66
  buttonLabel: s.soldOut ? e(a)("event.soldOut") : e(a)("event.bookNowButton"),
67
67
  buttonDisabled: s.soldOut,
68
68
  "min-value": s.type === "event" ? 1 : s.minimumPersonCount,
69
- "max-value": s.type === "event" ? s.maxOnlineReservationLimit || 1 / 0 : e(U),
69
+ "max-value": s.type === "event" ? s.maxOnlineReservationLimit || 1 / 0 : e(L),
70
70
  "is-loading": Q.value,
71
- "onUpdate:isLoading": f[1] || (f[1] = (F) => Q.value = F),
72
- onAction: f[2] || (f[2] = (F) => s.type === "event" ? h() : K())
71
+ "onUpdate:isLoading": f[1] || (f[1] = (B) => Q.value = B),
72
+ onAction: f[2] || (f[2] = (B) => s.type === "event" ? k() : K())
73
73
  }, null, 8, ["modelValue", "label", "buttonLabel", "buttonDisabled", "min-value", "max-value", "is-loading"])
74
74
  ]),
75
75
  _: 2
@@ -77,30 +77,30 @@ const gl = { class: "fresh-booking-event-listing-information" }, kl = { key: 0 }
77
77
  s.type === "event" ? {
78
78
  name: "description",
79
79
  fn: g(() => [
80
- l("ul", gl, [
80
+ l("ul", bl, [
81
81
  l("li", null, [
82
- r(k, {
82
+ r(h, {
83
83
  icon: "calendar-range",
84
84
  color: "header"
85
85
  }),
86
86
  l("span", null, n(e(He)(s.days)), 1)
87
87
  ]),
88
- e(ie)(s.fromDate, s.toDate) < 180 ? (t(), i("li", kl, [
89
- r(k, {
88
+ e(ie)(s.fromDate, s.toDate) < 180 ? (t(), i("li", gl, [
89
+ r(h, {
90
90
  icon: "calendar-days",
91
91
  color: "header"
92
92
  }),
93
93
  l("span", null, n(e(re)(s.fromDate, s.toDate)), 1)
94
94
  ])) : u("", !0),
95
95
  l("li", null, [
96
- r(k, {
96
+ r(h, {
97
97
  icon: "calendar-clock",
98
98
  color: "header"
99
99
  }),
100
100
  l("span", null, n(e(Je)(s.timeFrom, s.timeTo)), 1)
101
101
  ]),
102
102
  s.maxOnlineReservationLimit ? (t(), i("li", hl, [
103
- r(k, {
103
+ r(h, {
104
104
  icon: "user-alt",
105
105
  color: "header"
106
106
  }),
@@ -114,21 +114,21 @@ const gl = { class: "fresh-booking-event-listing-information" }, kl = { key: 0 }
114
114
  fn: g(() => [
115
115
  l("ul", { class: "fresh-booking-event-listing-information" }, [
116
116
  e(ie)(s.fromDate, s.toDate) < 180 ? (t(), i("li", { key: 0 }, [
117
- r(k, {
117
+ r(h, {
118
118
  icon: "calendar-days",
119
119
  color: "header"
120
120
  }),
121
121
  l("span", null, n(e(re)(s.fromDate, s.toDate, !0)), 1)
122
122
  ])) : u("", !0),
123
123
  l("li", null, [
124
- r(k, {
124
+ r(h, {
125
125
  icon: "user-alt",
126
126
  color: "header"
127
127
  }),
128
- l("span", null, n(`${s.minimumPersonCount} - ${e(U)} ${e(a)("general.people")}`), 1)
128
+ l("span", null, n(`${s.minimumPersonCount} - ${e(L)} ${e(a)("general.people")}`), 1)
129
129
  ]),
130
130
  l("li", null, [
131
- r(k, {
131
+ r(h, {
132
132
  icon: "money-bill",
133
133
  color: "header"
134
134
  }),
@@ -141,38 +141,38 @@ const gl = { class: "fresh-booking-event-listing-information" }, kl = { key: 0 }
141
141
  ]), 1032, ["listing-id", "gallery", "name", "description", "layout"]));
142
142
  }
143
143
  });
144
- const be = /* @__PURE__ */ fe(fl, [["__scopeId", "data-v-013d2269"]]), A = (L) => (xe("data-v-b2eee97d"), L = L(), el(), L), yl = { class: "fresh-booking-panel" }, _l = {
144
+ const be = /* @__PURE__ */ fe(kl, [["__scopeId", "data-v-013d2269"]]), F = (C) => (xe("data-v-b2eee97d"), C = C(), el(), C), fl = { class: "fresh-booking-panel" }, yl = {
145
145
  key: 0,
146
146
  id: "fresh-booking-event-overview"
147
- }, Vl = { class: "fresh-booking-event-listings" }, Pl = { class: "fresh-booking-event-listings" }, Tl = {
147
+ }, _l = { class: "fresh-booking-event-listings" }, Vl = { class: "fresh-booking-event-listings" }, Pl = {
148
148
  key: 2,
149
149
  id: "fresh-booking-event-addons"
150
- }, $l = { class: "fresh-booking-table" }, El = /* @__PURE__ */ A(() => /* @__PURE__ */ l("th", { class: "fresh-booking-event-addons-input" }, null, -1)), Ol = { class: "fresh-booking-event-addons-price" }, Dl = /* @__PURE__ */ A(() => /* @__PURE__ */ l("br", null, null, -1)), wl = { class: "fresh-booking-event-addons-input" }, Cl = { class: "fresh-booking-event-addons-price" }, Ll = /* @__PURE__ */ A(() => /* @__PURE__ */ l("td", { colspan: "2" }, null, -1)), Ul = { class: "fresh-booking-event-addons-price" }, Bl = { key: 3 }, Fl = { class: "fresh-booking-label required" }, Al = { id: "fresh-booking-event-table" }, Rl = { key: 4 }, Sl = { class: "fresh-booking-label required" }, Nl = { class: "fresh-booking-table" }, ql = /* @__PURE__ */ A(() => /* @__PURE__ */ l("th", { class: "fresh-booking-event-addons-input" }, null, -1)), Ml = { class: "fresh-booking-event-addons-price" }, Il = /* @__PURE__ */ A(() => /* @__PURE__ */ l("br", null, null, -1)), Ql = /* @__PURE__ */ A(() => /* @__PURE__ */ l("br", null, null, -1)), Wl = { class: "fresh-booking-event-addons-input" }, Yl = { class: "fresh-booking-event-addons-price" }, zl = { key: 0 }, Hl = { key: 1 }, Jl = { key: 2 }, Kl = { key: 3 }, Xl = { key: 4 }, Zl = { key: 5 }, jl = { key: 6 }, Gl = /* @__PURE__ */ ge({
150
+ }, Tl = { class: "fresh-booking-table" }, $l = /* @__PURE__ */ F(() => /* @__PURE__ */ l("th", { class: "fresh-booking-event-addons-input" }, null, -1)), El = { class: "fresh-booking-event-addons-price" }, Ol = /* @__PURE__ */ F(() => /* @__PURE__ */ l("br", null, null, -1)), Dl = { class: "fresh-booking-event-addons-input" }, wl = { class: "fresh-booking-event-addons-price" }, Cl = /* @__PURE__ */ F(() => /* @__PURE__ */ l("td", { colspan: "2" }, null, -1)), Ll = { class: "fresh-booking-event-addons-price" }, Ul = { key: 3 }, Bl = { class: "fresh-booking-label required" }, Fl = { id: "fresh-booking-event-table" }, Al = { key: 4 }, Rl = { class: "fresh-booking-label required" }, Nl = { class: "fresh-booking-table" }, Sl = /* @__PURE__ */ F(() => /* @__PURE__ */ l("th", { class: "fresh-booking-event-addons-input" }, null, -1)), ql = { class: "fresh-booking-event-addons-price" }, Ml = /* @__PURE__ */ F(() => /* @__PURE__ */ l("br", null, null, -1)), Il = /* @__PURE__ */ F(() => /* @__PURE__ */ l("br", null, null, -1)), Ql = { class: "fresh-booking-event-addons-input" }, Wl = { class: "fresh-booking-event-addons-price" }, Yl = { key: 0 }, zl = { key: 1 }, Hl = { key: 2 }, Jl = { key: 3 }, Kl = { key: 4 }, Xl = { key: 5 }, Zl = { key: 6 }, jl = /* @__PURE__ */ ge({
151
151
  name: "EventLayout",
152
152
  __name: "Event",
153
153
  props: {
154
154
  accessToken: {},
155
155
  styling: {}
156
156
  },
157
- setup(L) {
158
- const { t: a } = ke(), {
157
+ setup(C) {
158
+ const { t: a } = he(), {
159
159
  searchDate: v,
160
160
  addons: E,
161
161
  products: I,
162
- numberOfDays: U,
162
+ numberOfDays: L,
163
163
  discountCode: J,
164
- name: B,
164
+ name: U,
165
165
  phone: R,
166
- email: S,
167
- remark: N,
166
+ email: N,
167
+ remark: S,
168
168
  arrivalTime: O,
169
169
  title: P,
170
170
  subtitle: Q,
171
171
  slideshow: K,
172
- currency: h,
172
+ currency: k,
173
173
  numberOfPeople: s,
174
174
  numberOfTotalDays: f,
175
- numberOfRooms: F,
175
+ numberOfRooms: B,
176
176
  basePrice: ye,
177
177
  totalPrice: _e,
178
178
  isPaymentLoading: Ve,
@@ -198,17 +198,17 @@ const be = /* @__PURE__ */ fe(fl, [["__scopeId", "data-v-013d2269"]]), A = (L) =
198
198
  tableBasePrice: te
199
199
  } = z(H()), {
200
200
  initialize: Re,
201
- validateDiscountCode: nn,
202
- fetchListings: Se,
203
- createBooking: Ne,
201
+ validateDiscountCode: ln,
202
+ fetchListings: Ne,
203
+ createBooking: Se,
204
204
  localAddonPrice: ae,
205
205
  totalAddonPrice: oe,
206
206
  reset: qe
207
207
  } = H(), {
208
208
  hideEvents: Me,
209
209
  hideEventTemplates: Ie
210
- } = z(he());
211
- return Xe(() => Re()), Ze(v, () => Se()), (se, d) => (t(), b(Ge, {
210
+ } = z(ke());
211
+ return Xe(() => Re()), Ze(v, () => Ne()), (se, d) => (t(), b(Ge, {
212
212
  id: "fresh-booking-event-module",
213
213
  class: "fresh-booking-app",
214
214
  type: "event",
@@ -223,25 +223,25 @@ const be = /* @__PURE__ */ fe(fl, [["__scopeId", "data-v-013d2269"]]), A = (L) =
223
223
  subtitle: e(Q)
224
224
  }, {
225
225
  availability: g(({ next: Y }) => [
226
- l("div", yl, [
227
- r(bl, {
226
+ l("div", fl, [
227
+ r(vl, {
228
228
  modelValue: e(v),
229
229
  "onUpdate:modelValue": d[0] || (d[0] = (y) => D(v) ? v.value = y : null),
230
230
  label: e(a)("event.selectDate"),
231
231
  "min-date": /* @__PURE__ */ new Date()
232
232
  }, null, 8, ["modelValue", "label", "min-date"])
233
233
  ]),
234
- e(Be) ? (t(), i("div", _l, [
234
+ e(Be) ? (t(), i("div", yl, [
235
235
  e(Pe) && !e(Me) ? (t(), i(V, { key: 0 }, [
236
236
  l("h2", null, [
237
- r(k, {
237
+ r(h, {
238
238
  icon: "clock-seven",
239
239
  type: "fal",
240
240
  color: "header"
241
241
  }),
242
242
  l("span", null, n(e(a)("event.eventsTitle")), 1)
243
243
  ]),
244
- l("ul", Vl, [
244
+ l("ul", _l, [
245
245
  (t(!0), i(V, null, w(e($e), ({
246
246
  id: y,
247
247
  days: o,
@@ -274,14 +274,14 @@ const be = /* @__PURE__ */ fe(fl, [["__scopeId", "data-v-013d2269"]]), A = (L) =
274
274
  ], 64)) : u("", !0),
275
275
  e(Te) && !e(Ie) ? (t(), i(V, { key: 1 }, [
276
276
  l("h2", null, [
277
- r(k, {
277
+ r(h, {
278
278
  icon: "stars",
279
279
  type: "fal",
280
280
  color: "header"
281
281
  }),
282
282
  l("span", null, n(e(a)("event.stayTitle")), 1)
283
283
  ]),
284
- l("ul", Pl, [
284
+ l("ul", Vl, [
285
285
  (t(!0), i(V, null, w(e(Ee), ({
286
286
  id: y,
287
287
  name: o,
@@ -309,8 +309,8 @@ const be = /* @__PURE__ */ fe(fl, [["__scopeId", "data-v-013d2269"]]), A = (L) =
309
309
  reservation: g(({ next: Y, prev: y }) => [
310
310
  e(Ae) ? (t(), b(rl, {
311
311
  key: 0,
312
- remark: e(N),
313
- "onUpdate:remark": d[8] || (d[8] = (o) => D(N) ? N.value = o : null),
312
+ remark: e(S),
313
+ "onUpdate:remark": d[8] || (d[8] = (o) => D(S) ? S.value = o : null),
314
314
  "is-filled": e(Fe),
315
315
  "is-loading": e(Ve),
316
316
  "base-price": e(ye),
@@ -318,20 +318,20 @@ const be = /* @__PURE__ */ fe(fl, [["__scopeId", "data-v-013d2269"]]), A = (L) =
318
318
  "weekend-fee": e(Ce),
319
319
  "room-upgrade": e(we),
320
320
  onPrev: (o) => e(qe)(y),
321
- onNext: (o) => e(Ne)(Y)
321
+ onNext: (o) => e(Se)(Y)
322
322
  }, {
323
323
  form: g(() => [
324
324
  e(ne) === e(de).FullDayEvent ? (t(), b(x, {
325
325
  key: 0,
326
- modelValue: e(U),
327
- "onUpdate:modelValue": d[1] || (d[1] = (o) => D(U) ? U.value = o : null),
326
+ modelValue: e(L),
327
+ "onUpdate:modelValue": d[1] || (d[1] = (o) => D(L) ? L.value = o : null),
328
328
  label: e(a)("event.numberOfDays"),
329
329
  "min-value": 1,
330
330
  required: ""
331
331
  }, null, 8, ["modelValue", "label"])) : u("", !0),
332
332
  r(me, {
333
- modelValue: e(B),
334
- "onUpdate:modelValue": d[2] || (d[2] = (o) => D(B) ? B.value = o : null),
333
+ modelValue: e(U),
334
+ "onUpdate:modelValue": d[2] || (d[2] = (o) => D(U) ? U.value = o : null),
335
335
  type: "text",
336
336
  label: e(a)("booking.reservation.name"),
337
337
  icon: "user-alt",
@@ -339,8 +339,8 @@ const be = /* @__PURE__ */ fe(fl, [["__scopeId", "data-v-013d2269"]]), A = (L) =
339
339
  required: ""
340
340
  }, null, 8, ["modelValue", "label", "placeholder"]),
341
341
  r(me, {
342
- modelValue: e(S),
343
- "onUpdate:modelValue": d[3] || (d[3] = (o) => D(S) ? S.value = o : null),
342
+ modelValue: e(N),
343
+ "onUpdate:modelValue": d[3] || (d[3] = (o) => D(N) ? N.value = o : null),
344
344
  label: e(a)("booking.reservation.email"),
345
345
  type: "email",
346
346
  name: "email",
@@ -358,7 +358,7 @@ const be = /* @__PURE__ */ fe(fl, [["__scopeId", "data-v-013d2269"]]), A = (L) =
358
358
  required: ""
359
359
  }, null, 8, ["modelValue", "label", "placeholder"]),
360
360
  u("", !0),
361
- e(W) && e(W).length > 0 ? (t(), i("ul", Tl, [
361
+ e(W) && e(W).length > 0 ? (t(), i("ul", Pl, [
362
362
  (t(!0), i(V, null, w(e(W), ({
363
363
  roomGroupID: o,
364
364
  addons: c,
@@ -367,21 +367,21 @@ const be = /* @__PURE__ */ fe(fl, [["__scopeId", "data-v-013d2269"]]), A = (L) =
367
367
  l("h5", null, [
368
368
  l("span", null, n(e(a)("booking.reservation.room")) + " #" + n(m + 1), 1),
369
369
  ce(" ("),
370
- r(k, {
370
+ r(h, {
371
371
  icon: "male",
372
372
  type: "fas",
373
373
  color: "header"
374
374
  }),
375
375
  ce(" " + n(_) + ") ", 1)
376
376
  ]),
377
- l("table", $l, [
377
+ l("table", Tl, [
378
378
  l("thead", null, [
379
379
  l("tr", null, [
380
380
  l("th", null, [
381
381
  l("span", null, n(e(a)("booking.reservation.addons")), 1)
382
382
  ]),
383
- El,
384
- l("th", Ol, [
383
+ $l,
384
+ l("th", El, [
385
385
  l("span", null, n(e(a)("booking.availability.price")), 1)
386
386
  ])
387
387
  ])
@@ -396,10 +396,10 @@ const be = /* @__PURE__ */ fe(fl, [["__scopeId", "data-v-013d2269"]]), A = (L) =
396
396
  }) => (t(), i("tr", { key: p }, [
397
397
  l("td", null, [
398
398
  l("b", null, n(X), 1),
399
- Dl,
400
- l("span", null, n(e($)(Z, e(h))) + " " + n(e(je)(j)), 1)
399
+ Ol,
400
+ l("span", null, n(e($)(Z, e(k))) + " " + n(e(je)(j)), 1)
401
401
  ]),
402
- l("td", wl, [
402
+ l("td", Dl, [
403
403
  q === 3 ? (t(), b(x, {
404
404
  key: 0,
405
405
  modelValue: e(E)[`${o}.${p}.${m}`],
@@ -413,17 +413,17 @@ const be = /* @__PURE__ */ fe(fl, [["__scopeId", "data-v-013d2269"]]), A = (L) =
413
413
  numeric: !0
414
414
  }, null, 8, ["modelValue", "onUpdate:modelValue"]))
415
415
  ]),
416
- l("td", Cl, [
417
- l("span", null, n(e($)(e(ae)(p, o, m), e(h))), 1)
416
+ l("td", wl, [
417
+ l("span", null, n(e($)(e(ae)(p, o, m), e(k))), 1)
418
418
  ])
419
419
  ]))), 128))
420
420
  ]),
421
421
  l("tfoot", null, [
422
422
  l("tr", null, [
423
- Ll,
424
- l("td", Ul, [
423
+ Cl,
424
+ l("td", Ll, [
425
425
  l("u", null, [
426
- l("span", null, n(e($)(e(oe)(o, m), e(h))), 1)
426
+ l("span", null, n(e($)(e(oe)(o, m), e(k))), 1)
427
427
  ])
428
428
  ])
429
429
  ])
@@ -431,11 +431,11 @@ const be = /* @__PURE__ */ fe(fl, [["__scopeId", "data-v-013d2269"]]), A = (L) =
431
431
  ])
432
432
  ]))), 128))
433
433
  ])) : u("", !0),
434
- e(ne) !== e(de).FullDayEvent && !e(T) ? (t(), i("div", Bl, [
435
- l("label", Fl, [
434
+ e(ne) !== e(de).FullDayEvent && !e(T) ? (t(), i("div", Ul, [
435
+ l("label", Bl, [
436
436
  l("span", null, n(e(a)("event.selectArrivalTime")), 1)
437
437
  ]),
438
- l("ul", Al, [
438
+ l("ul", Fl, [
439
439
  (t(!0), i(V, null, w(e(De), (o, c) => (t(), i("li", { key: c }, [
440
440
  r(ve, {
441
441
  modelValue: e(O),
@@ -448,8 +448,8 @@ const be = /* @__PURE__ */ fe(fl, [["__scopeId", "data-v-013d2269"]]), A = (L) =
448
448
  ]))), 128))
449
449
  ])
450
450
  ])) : u("", !0),
451
- e(Le) ? (t(), i("div", Rl, [
452
- l("label", Sl, [
451
+ e(Le) ? (t(), i("div", Al, [
452
+ l("label", Rl, [
453
453
  l("span", null, n(e(a)("event.selectProducts")), 1)
454
454
  ]),
455
455
  l("table", Nl, [
@@ -458,8 +458,8 @@ const be = /* @__PURE__ */ fe(fl, [["__scopeId", "data-v-013d2269"]]), A = (L) =
458
458
  l("th", null, [
459
459
  l("span", null, n(e(a)("booking.reservation.addons")), 1)
460
460
  ]),
461
- ql,
462
- l("th", Ml, [
461
+ Sl,
462
+ l("th", ql, [
463
463
  l("span", null, n(e(a)("booking.availability.price")), 1)
464
464
  ])
465
465
  ])
@@ -470,12 +470,12 @@ const be = /* @__PURE__ */ fe(fl, [["__scopeId", "data-v-013d2269"]]), A = (L) =
470
470
  l("b", null, [
471
471
  l("span", null, n(c), 1)
472
472
  ]),
473
- Il,
473
+ Ml,
474
474
  l("span", null, n(m), 1),
475
- Ql,
476
- l("span", null, n(e($)(_, e(h))), 1)
475
+ Il,
476
+ l("span", null, n(e($)(_, e(k))), 1)
477
477
  ]),
478
- l("td", Wl, [
478
+ l("td", Ql, [
479
479
  r(x, {
480
480
  modelValue: e(I)[o],
481
481
  "onUpdate:modelValue": (p) => e(I)[o] = p,
@@ -483,8 +483,8 @@ const be = /* @__PURE__ */ fe(fl, [["__scopeId", "data-v-013d2269"]]), A = (L) =
483
483
  "min-value": 0
484
484
  }, null, 8, ["modelValue", "onUpdate:modelValue"])
485
485
  ]),
486
- l("td", Yl, [
487
- l("span", null, n(e($)(e(ae)(o), e(h))), 1)
486
+ l("td", Wl, [
487
+ l("span", null, n(e($)(e(ae)(o), e(k))), 1)
488
488
  ])
489
489
  ]))), 128))
490
490
  ])
@@ -496,39 +496,39 @@ const be = /* @__PURE__ */ fe(fl, [["__scopeId", "data-v-013d2269"]]), A = (L) =
496
496
  l("span", null, n(e(a)("event.numberOfGuests")), 1),
497
497
  l("b", null, n(e(s)), 1)
498
498
  ]),
499
- e(T) ? (t(), i("li", zl, [
499
+ e(T) ? (t(), i("li", Yl, [
500
500
  l("span", null, n(e(a)("event.numberOfRooms")), 1),
501
- l("b", null, n(e(F)), 1)
501
+ l("b", null, n(e(B)), 1)
502
502
  ])) : u("", !0),
503
- e(T) ? (t(), i("li", Hl, [
503
+ e(T) ? (t(), i("li", zl, [
504
504
  l("span", null, n(e(a)("event.numberOfDays")), 1),
505
505
  l("b", null, n(e(f)), 1)
506
506
  ])) : u("", !0),
507
- e(T) ? (t(), i("li", Jl, [
507
+ e(T) ? (t(), i("li", Hl, [
508
508
  l("span", null, n(e(a)("booking.reservation.arrival")), 1),
509
509
  l("b", null, n(e(pe)(e(le))), 1)
510
510
  ])) : u("", !0),
511
- e(T) ? (t(), i("li", Kl, [
511
+ e(T) ? (t(), i("li", Jl, [
512
512
  l("span", null, n(e(a)("booking.reservation.departure")), 1),
513
513
  l("b", null, n(e(pe)(e(le), e(f))), 1)
514
514
  ])) : u("", !0),
515
- !e(T) && e(O) ? (t(), i("li", Xl, [
515
+ !e(T) && e(O) ? (t(), i("li", Kl, [
516
516
  l("span", null, n(e(a)("event.startOfEvent")), 1),
517
517
  l("b", null, n(e(G)(e(O))), 1)
518
518
  ])) : u("", !0),
519
- !e(T) && e(ee) ? (t(), i("li", Zl, [
519
+ !e(T) && e(ee) ? (t(), i("li", Xl, [
520
520
  l("span", null, n(e(a)("event.lengthOfEvent")), 1),
521
521
  l("b", null, n(e(G)(e(ee))), 1)
522
522
  ])) : u("", !0),
523
- !e(T) && e(te) > 0 ? (t(), i("li", jl, [
523
+ !e(T) && e(te) > 0 ? (t(), i("li", Zl, [
524
524
  l("span", null, n(e(a)("booking.availability.basePrice")), 1),
525
- l("b", null, n(e($)(e(te), e(h))), 1)
525
+ l("b", null, n(e($)(e(te), e(k))), 1)
526
526
  ])) : u("", !0)
527
527
  ]),
528
528
  expenses: g(() => [
529
529
  (t(!0), i(V, null, w(e(W), ({ roomGroupID: o }, c) => (t(), i("li", { key: o }, [
530
530
  l("span", null, n(e(a)("booking.reservation.addons")) + " - " + n(e(a)("booking.reservation.room")) + " #" + n(c + 1), 1),
531
- l("b", null, n(e($)(e(oe)(o, c), e(h))), 1)
531
+ l("b", null, n(e($)(e(oe)(o, c), e(k))), 1)
532
532
  ]))), 128))
533
533
  ]),
534
534
  _: 2
@@ -549,14 +549,13 @@ const be = /* @__PURE__ */ fe(fl, [["__scopeId", "data-v-013d2269"]]), A = (L) =
549
549
  }, 8, ["access-token", "styling"]));
550
550
  }
551
551
  });
552
- const xl = /* @__PURE__ */ fe(Gl, [["__scopeId", "data-v-b2eee97d"]]), en = ll(), ln = nl(), C = tl({ components: { Event: xl } });
553
- C.use(en);
554
- C.use(ln);
555
- C.use(vl);
556
- C.use(al);
557
- C.use(dl);
558
- C.use(ol, { bootstrap: !0 });
559
- C.mount("#konnectio-event-app");
552
+ const Gl = /* @__PURE__ */ fe(jl, [["__scopeId", "data-v-b2eee97d"]]), xl = ll(), en = nl(), A = tl({ components: { Event: Gl } });
553
+ A.use(xl);
554
+ A.use(en);
555
+ A.use(al);
556
+ A.use(dl);
557
+ A.use(ol, { bootstrap: !0 });
558
+ A.mount("#konnectio-event-app");
560
559
  export {
561
- C as default
560
+ A as default
562
561
  };
package/dist/event.js.br CHANGED
Binary file
@@ -1 +1 @@
1
- "use strict";const e=require("./SelectField.vue_vue_type_style_index_0_lang-9544cd25.cjs"),g=require("./ActionField-79f8bfae.cjs");require("./_commonjsHelpers-6763f629.cjs");require("./NumberField.vue_vue_type_script_setup_true_lang-1108dcd6.cjs");const _=o=>(e.pushScopeId("data-v-5d5827dc"),o=o(),e.popScopeId(),o),y=["innerHTML"],N={key:0,id:"fresh-booking-gift-card-validation-resume",class:"fresh-booking-panel"},B=_(()=>e.createBaseVNode("span",null,"Loading...",-1)),m=e.defineComponent({name:"GiftCardValidationLayout",__name:"GiftCardValidation",props:{accessToken:{},styling:{}},setup(o){const{t:a}=e.useI18n(),{voucher:l,isValid:c,amount:u,expirationDate:p,productName:f,isLoading:i}=e.storeToRefs(e.useApplyGiftCardStore()),{currency:V}=e.storeToRefs(e.useUtilityStore()),{apply:s}=e.useApplyGiftCardStore();return(d,t)=>(e.openBlock(),e.createBlock(e.Suspense,null,{default:e.withCtx(()=>[e.createVNode(e._sfc_main$1,{id:"fresh-booking-gift-card-validation-module","access-token":d.accessToken,type:"gift-card",styling:d.styling},{default:e.withCtx(()=>[e.createBaseVNode("form",{onSubmit:t[3]||(t[3]=e.withModifiers(n=>e.unref(s)(),["prevent"]))},[e.createBaseVNode("h4",null,[e.createBaseVNode("span",null,e.toDisplayString(e.unref(a)("giftCardValidation.title")),1)]),e.createBaseVNode("p",{innerHTML:e.unref(a)("giftCardValidation.description")},null,8,y),e.createVNode(g.ActionField,{modelValue:e.unref(l),"onUpdate:modelValue":t[0]||(t[0]=n=>e.isRef(l)?l.value=n:null),icon:"gift-card",label:e.unref(a)("booking.reservation.giftCardCode"),buttonLabel:e.unref(a)("giftCardValidation.submitButton"),placeholder:"XXXXXXXX","is-loading":e.unref(i),"onUpdate:isLoading":t[1]||(t[1]=n=>e.isRef(i)?i.value=n:null),onAction:t[2]||(t[2]=n=>e.unref(s)())},null,8,["modelValue","label","buttonLabel","is-loading"]),!e.unref(i)&&e.unref(c)?(e.openBlock(),e.createElementBlock("table",N,[e.createBaseVNode("thead",null,[e.createBaseVNode("tr",null,[e.createBaseVNode("th",null,[e.createBaseVNode("span",null,e.toDisplayString(e.unref(a)("giftCardValidation.giftCard")),1),e.createVNode(e.Icon,{icon:"gift-card",type:"fas",color:"header"})]),e.createBaseVNode("th",null,[e.createBaseVNode("span",null,e.toDisplayString(e.unref(a)("giftCardValidation.balance")),1),e.createVNode(e.Icon,{icon:"money-bill",type:"fas",color:"header"})]),e.createBaseVNode("th",null,[e.createBaseVNode("span",null,e.toDisplayString(e.unref(a)("giftCardValidation.expirationDate")),1),e.createVNode(e.Icon,{icon:"timer",type:"fas",color:"header"})])])]),e.createBaseVNode("tbody",null,[e.createBaseVNode("tr",null,[e.createBaseVNode("td",null,[e.createBaseVNode("span",null,e.toDisplayString(e.unref(f)),1)]),e.createBaseVNode("td",null,[e.createBaseVNode("span",null,e.toDisplayString(e.unref(e.showPrice)(e.unref(u),e.unref(V))),1)]),e.createBaseVNode("td",null,[e.createBaseVNode("span",null,e.toDisplayString(e.unref(e.showDate)(e.unref(p))),1)])])])])):e.createCommentVNode("",!0)],32)]),_:1},8,["access-token","styling"])]),fallback:e.withCtx(()=>[B]),_:1}))}});const C=e._export_sfc(m,[["__scopeId","data-v-5d5827dc"]]),r=e.createApp({components:{GiftCardValidation:C}}),b=e.createPinia();r.use(b);r.use(e.instance);r.mount("#konnectio-gift-card-validation-app");module.exports=r;
1
+ "use strict";const e=require("./SelectField.vue_vue_type_style_index_0_lang-88de73f4.cjs"),g=require("./ActionField-43360bd2.cjs");require("./_commonjsHelpers-6763f629.cjs");require("./NumberField.vue_vue_type_script_setup_true_lang-01f7e3ee.cjs");const _=o=>(e.pushScopeId("data-v-5d5827dc"),o=o(),e.popScopeId(),o),y=["innerHTML"],N={key:0,id:"fresh-booking-gift-card-validation-resume",class:"fresh-booking-panel"},B=_(()=>e.createBaseVNode("span",null,"Loading...",-1)),m=e.defineComponent({name:"GiftCardValidationLayout",__name:"GiftCardValidation",props:{accessToken:{},styling:{}},setup(o){const{t:a}=e.useI18n(),{voucher:l,isValid:c,amount:u,expirationDate:p,productName:f,isLoading:i}=e.storeToRefs(e.useApplyGiftCardStore()),{currency:V}=e.storeToRefs(e.useUtilityStore()),{apply:s}=e.useApplyGiftCardStore();return(d,t)=>(e.openBlock(),e.createBlock(e.Suspense,null,{default:e.withCtx(()=>[e.createVNode(e._sfc_main$1,{id:"fresh-booking-gift-card-validation-module","access-token":d.accessToken,type:"gift-card",styling:d.styling},{default:e.withCtx(()=>[e.createBaseVNode("form",{onSubmit:t[3]||(t[3]=e.withModifiers(n=>e.unref(s)(),["prevent"]))},[e.createBaseVNode("h4",null,[e.createBaseVNode("span",null,e.toDisplayString(e.unref(a)("giftCardValidation.title")),1)]),e.createBaseVNode("p",{innerHTML:e.unref(a)("giftCardValidation.description")},null,8,y),e.createVNode(g.ActionField,{modelValue:e.unref(l),"onUpdate:modelValue":t[0]||(t[0]=n=>e.isRef(l)?l.value=n:null),icon:"gift-card",label:e.unref(a)("booking.reservation.giftCardCode"),buttonLabel:e.unref(a)("giftCardValidation.submitButton"),placeholder:"XXXXXXXX","is-loading":e.unref(i),"onUpdate:isLoading":t[1]||(t[1]=n=>e.isRef(i)?i.value=n:null),onAction:t[2]||(t[2]=n=>e.unref(s)())},null,8,["modelValue","label","buttonLabel","is-loading"]),!e.unref(i)&&e.unref(c)?(e.openBlock(),e.createElementBlock("table",N,[e.createBaseVNode("thead",null,[e.createBaseVNode("tr",null,[e.createBaseVNode("th",null,[e.createBaseVNode("span",null,e.toDisplayString(e.unref(a)("giftCardValidation.giftCard")),1),e.createVNode(e.Icon,{icon:"gift-card",type:"fas",color:"header"})]),e.createBaseVNode("th",null,[e.createBaseVNode("span",null,e.toDisplayString(e.unref(a)("giftCardValidation.balance")),1),e.createVNode(e.Icon,{icon:"money-bill",type:"fas",color:"header"})]),e.createBaseVNode("th",null,[e.createBaseVNode("span",null,e.toDisplayString(e.unref(a)("giftCardValidation.expirationDate")),1),e.createVNode(e.Icon,{icon:"timer",type:"fas",color:"header"})])])]),e.createBaseVNode("tbody",null,[e.createBaseVNode("tr",null,[e.createBaseVNode("td",null,[e.createBaseVNode("span",null,e.toDisplayString(e.unref(f)),1)]),e.createBaseVNode("td",null,[e.createBaseVNode("span",null,e.toDisplayString(e.unref(e.showPrice)(e.unref(u),e.unref(V))),1)]),e.createBaseVNode("td",null,[e.createBaseVNode("span",null,e.toDisplayString(e.unref(e.showDate)(e.unref(p))),1)])])])])):e.createCommentVNode("",!0)],32)]),_:1},8,["access-token","styling"])]),fallback:e.withCtx(()=>[B]),_:1}))}});const C=e._export_sfc(m,[["__scopeId","data-v-5d5827dc"]]),r=e.createApp({components:{GiftCardValidation:C}}),b=e.createPinia();r.use(b);r.use(e.instance);r.mount("#konnectio-gift-card-validation-app");module.exports=r;
@@ -1,7 +1,7 @@
1
- import { k as L, D as S, s as m, a as _, c as X, m as y, n as w, w as p, p as l, A as a, F as o, q as t, G as V, v as x, H as u, J as A, K as G, x as I, L as B, M as D, N, P as T, Q as M, _ as U, R as H, U as P, V as R } from "./SelectField.vue_vue_type_style_index_0_lang-bc4ca9a5.js";
2
- import { A as $ } from "./ActionField-054975da.js";
1
+ import { k as L, D as S, s as m, a as _, c as X, m as y, n as w, w as p, p as l, A as a, F as o, q as t, G as V, v as x, H as u, J as A, K as G, x as I, L as B, M as D, N, P as T, Q as M, _ as U, R as H, U as P, V as R } from "./SelectField.vue_vue_type_style_index_0_lang-fbce2406.js";
2
+ import { A as $ } from "./ActionField-46bc1332.js";
3
3
  import "./_commonjsHelpers-aeeeeb92.js";
4
- import "./NumberField.vue_vue_type_script_setup_true_lang-3517aeda.js";
4
+ import "./NumberField.vue_vue_type_script_setup_true_lang-9edbbae0.js";
5
5
  const F = (s) => (T("data-v-5d5827dc"), s = s(), M(), s), q = ["innerHTML"], E = {
6
6
  key: 0,
7
7
  id: "fresh-booking-gift-card-validation-resume",
Binary file
@@ -1 +1 @@
1
- "use strict";const e=require("./SelectField.vue_vue_type_style_index_0_lang-9544cd25.cjs"),N=require("./index-2920831d.cjs"),M=require("./_-b8fd5e7f.cjs"),x=require("./Field-73b09327.cjs");require("./_commonjsHelpers-6763f629.cjs");const U=e.defineStore("giftCard",()=>{const{pay:y}=e.usePaymentStore(),{bearerToken:a,metaData:g,currencyId:h}=e.storeToRefs(e.useUtilityStore()),n=e.ref(e.GiftCardModuleState.InitialState),_=e.useStorage("konnectio_name","",void 0,{serializer:e.StorageSerializers.string}),d=e.useStorage("konnectio_email","",void 0,{serializer:e.StorageSerializers.string}),s=e.useStorage("konnectio_phone","",void 0,{serializer:e.StorageSerializers.string}),b=e.ref(""),F=e.ref(1),p=e.ref(!0),c=e.ref(""),u=e.ref({base64:"",type:"",name:""}),l=e.ref(void 0),i=e.ref(0),r=e.ref(!1),k=e.ref(0),C=e.computed(()=>n.value===e.GiftCardModuleState.InitialState||n.value===e.GiftCardModuleState.WaitingForResponse),f=e.computed(()=>n.value===e.GiftCardModuleState.ReadyToPay),w=e.computed(()=>n.value===e.GiftCardModuleState.PaymentSuccess),R=e.computed(()=>{const t={1:{label:e.i18n.t("giftCard.hotelType"),data:[]},2:{label:e.i18n.t("giftCard.restaurantType"),data:[]}},v=g.value.places;return v&&v.forEach(m=>{t[m.placeType].data.push(m)}),Object.fromEntries(Object.entries(t).filter(([,m])=>m.data.length>0))}),T=e.computed(()=>k.value!==0),V=e.computed(()=>{let t;if(T.value)t=R.value[k.value].data[0];else if(i.value!==0){const v=l.value,m=R.value[i.value].data;m.length===1?t=m[0]:v!==void 0&&m.forEach(G=>{String(G.id)===String(v)&&(t=G)})}return t}),E=e.computed(()=>!(!_.value||!d.value||!(s.value.length>=5)||!b.value||V.value===void 0)),P=e.computed(()=>!(n.value===e.GiftCardModuleState.InitialState&&r.value)),B=e.computed(()=>!!(n.value===e.GiftCardModuleState.WaitingForResponse&&r.value));async function o(){n.value=e.GiftCardModuleState.WaitingForResponse,r.value=!0,await e.axios.post("https://production.hotel-service.konnectio.dk/api/gift-card/create",{termsOfserviceURL:"https://freshbooking.dk",checkoutUrl:"https://freshbooking.dk",currencyID:h.value,language:e.getUserLanguage(),amount:b.value,quantity:F.value,freeText:c.value,showPrice:p.value,contactName:_.value,contactEmail:d.value,contactPhone:s.value,imageBase64:e.b2a(u.value.base64),imageName:u.value.name,imageFormat:u.value.type,placeType:V.value?V.value.placeType:void 0,placeID:V.value?V.value.id:void 0},{headers:{Authorization:a.value,Accept:"application/json","Fresh-Booking-Ver":"4.0.41"}}).then(t=>{n.value=e.GiftCardModuleState.ReadyToPay,r.value=!1,y({callback:()=>console.log("Callback!"),response:t.data})})}function q(t){t&&(k.value=t)}return{moduleState:n,name:_,email:d,phone:s,value:b,remark:c,showValue:p,quantity:F,media:u,placeId:l,placeType:i,showFormPage:C,showPaymentPage:f,showConfirmationPage:w,places:R,hasFilledForm:E,hasForcedPlaceType:T,isWaitingForResponse:B,isMetaDataAvailable:P,orderGiftCard:o,initialize:q}}),D={class:"media-selector"},I=["accept"],L={class:"media-selector-wrapper"},z={class:"media-selector-tools"},A={key:0},W={key:1},j={key:2},H=["src"],O=e.defineComponent({__name:"MediaSelector",props:{modelValue:{},validation:{default:"image/*"},iconColor:{default:"#000"},label:{},required:{type:Boolean,default:!1}},emits:["update:modelValue"],setup(y,{emit:a}){const g=a,h=y,{t:n}=e.useI18n(),{display:_}=e.useAlertStore(),d=e.ref(),s=e.computed(()=>h.modelValue.base64!=="");function b(l){g("update:modelValue",l)}function F(){b({base64:"",name:"",type:""}),d.value&&(d.value.value="")}function p(){d.value&&d.value.click()}function c(l,i){const[r,k]=[l.name,l.type],C=new FileReader;C.onload=function(f){if(f.target){const w=f.target.result;i({base64:w,name:r,type:k})}else _({message:n("imageUploadError"),type:"error"})},C.readAsDataURL(l)}async function u(){let l;(l=d.value.files)instanceof FileList&&c(l[0],b)}return(l,i)=>(e.openBlock(),e.createBlock(e.InputField,{label:l.label,required:l.required,type:"media"},{default:e.withCtx(()=>[e.createBaseVNode("div",D,[e.createBaseVNode("input",{ref_key:"fileInput",ref:d,type:"file",class:"hidden",accept:l.validation,single:"",onChange:i[0]||(i[0]=r=>u())},null,40,I),e.createBaseVNode("div",L,[e.createBaseVNode("ul",z,[s.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("li",A,[e.createVNode(e.Clickable,{label:e.unref(n)("uploadFile"),type:"button",icon:"upload","icon-color":l.iconColor,onClickEvent:i[1]||(i[1]=r=>p())},null,8,["label","icon-color"])])),s.value?(e.openBlock(),e.createElementBlock("li",W,[e.createVNode(e.Clickable,{label:e.unref(n)("replaceFile"),type:"button",icon:"repeat-alt","icon-color":l.iconColor,onClickEvent:i[2]||(i[2]=r=>p())},null,8,["label","icon-color"])])):e.createCommentVNode("",!0),s.value?(e.openBlock(),e.createElementBlock("li",j,[e.createVNode(e.Clickable,{label:e.unref(n)("removeFile"),type:"button",icon:"trash-alt","icon-color":l.iconColor,onClickEvent:i[3]||(i[3]=r=>F())},null,8,["label","icon-color"])])):e.createCommentVNode("",!0)]),e.createBaseVNode("div",{class:e.normalizeClass(["media-selector-previewer",{opened:s.value}])},[l.modelValue?(e.openBlock(),e.createElementBlock("img",{key:0,src:l.modelValue.base64},null,8,H)):e.createCommentVNode("",!0)],2)])])]),_:1},8,["label","required"]))}});function $(y){const a=y;a.__i18n=a.__i18n||[],a.__i18n.push({locale:"",resource:{da:{uploadFile:{t:0,b:{t:2,i:[{t:3}],s:"Upload billede"}},removeFile:{t:0,b:{t:2,i:[{t:3}],s:"Fjern billede"}},replaceFile:{t:0,b:{t:2,i:[{t:3}],s:"Ersat billede"}},imageUploadError:{t:0,b:{t:2,i:[{t:3}],s:"Der skete en fejl under billede upload!"}}},en:{uploadFile:{t:0,b:{t:2,i:[{t:3}],s:"Upload image"}},removeFile:{t:0,b:{t:2,i:[{t:3}],s:"Remove image"}},replaceFile:{t:0,b:{t:2,i:[{t:3}],s:"Replace image"}},imageUploadError:{t:0,b:{t:2,i:[{t:3}],s:"An error occurred under image upload!"}}}}})}typeof $=="function"&&$(O);const K={class:"gift-card-skeleton"},Y={class:"gift-card-skeleton-form"},J=e.defineComponent({__name:"GiftCardSkeleton",setup(y){return(a,g)=>(e.openBlock(),e.createElementBlock("div",K,[e.createBaseVNode("div",Y,[e.createVNode(x.Field),e.createVNode(x.Field),e.createVNode(x.Field),e.createVNode(x.Field),e.createVNode(x.Field,{"is-text-area":""}),e.createVNode(M.Element,{height:"44px"})])]))}});const Q=e._export_sfc(J,[["__scopeId","data-v-2600a731"]]),X={key:0,id:"fresh-booking-gift-card-wrapper"},Z={id:"fresh-booking-gift-card-title"},ee={id:"fresh-booking-gift-card-content"},te={id:"fresh-booking-gift-card-payment"},ae=["innerHTML"],le={key:0},oe={key:0,id:"fresh-booking-select-place-type"},ne={class:e.normalizeClass(["fresh-booking-label","required"])},ie={id:"fresh-booking-select-place-type-input"},re=["innerHTML"],de={key:0,id:"fresh-booking-gift-card-order"},se={class:"fresh-booking-panel"},ce={key:1,id:"fresh-booking-gift-card-remarks"},ue={key:2,id:"fresh-booking-gift-card-order-minimal","sticky-side":"bottom"},fe={id:"fresh-booking-gift-card-recaptcha"},pe=e.defineComponent({name:"GiftCardLayout",__name:"GiftCard",props:{accessToken:{},layout:{default:"minimal"},placeType:{},styling:{}},setup(y){const{t:a}=e.useI18n(),{name:g,email:h,phone:n,value:_,remark:d,showValue:s,quantity:b,media:F,placeId:p,placeType:c,showFormPage:u,showPaymentPage:l,showConfirmationPage:i,places:r,hasFilledForm:k,hasForcedPlaceType:C,isWaitingForResponse:f,isMetaDataAvailable:w}=e.storeToRefs(U()),{initialize:R,orderGiftCard:T}=U(),{isRecaptchaEnabled:V,currency:E}=e.storeToRefs(e.useUtilityStore());async function P(){await T()}return e.watch(c,()=>{p.value=void 0}),e.onMounted(()=>{R()}),(B,o)=>{const q=e.resolveDirective("sticky");return e.openBlock(),e.createBlock(e.Suspense,null,{default:e.withCtx(()=>[e.createVNode(e._sfc_main$1,{id:"fresh-booking-gift-card-module",type:"gift-card","access-token":B.accessToken,"data-layout":B.layout,styling:B.styling,"sticky-container":""},{default:e.withCtx(()=>[e.unref(w)?(e.openBlock(),e.createElementBlock("div",X,[e.createBaseVNode("h4",Z,[e.createBaseVNode("span",null,e.toDisplayString(e.unref(a)("giftCard.title")),1)]),e.createBaseVNode("div",ee,[e.withDirectives(e.createBaseVNode("div",te,[e.createVNode(N.CheckoutWindow)],512),[[e.vShow,e.unref(l)]]),e.withDirectives(e.createBaseVNode("div",null,[e.createBaseVNode("p",{id:"fresh-booking-gift-card-description",innerHTML:e.unref(a)("giftCard.description")},null,8,ae),e.createBaseVNode("form",null,[e.createVNode(e.TextField,{modelValue:e.unref(g),"onUpdate:modelValue":o[0]||(o[0]=t=>e.isRef(g)?g.value=t:null),type:"text",name:"name",autocomplete:"name",label:e.unref(a)("giftCard.name"),icon:"user-alt",placeholder:e.unref(a)("giftCard.namePlaceholder"),required:""},null,8,["modelValue","label","placeholder"]),e.createVNode(e.TextField,{modelValue:e.unref(h),"onUpdate:modelValue":o[1]||(o[1]=t=>e.isRef(h)?h.value=t:null),type:"email",name:"email",autocomplete:"email",label:e.unref(a)("giftCard.email"),icon:"at",placeholder:e.unref(a)("giftCard.emailPlaceholder"),required:""},null,8,["modelValue","label","placeholder"]),e.createVNode(N.PhoneField,{modelValue:e.unref(n),"onUpdate:modelValue":o[2]||(o[2]=t=>e.isRef(n)?n.value=t:null),icon:"phone-office",label:e.unref(a)("giftCard.phone"),placeholder:e.unref(a)("giftCard.phonePlaceholder"),required:""},null,8,["modelValue","label","placeholder"]),e.unref(C)?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",le,[e.unref(r)?(e.openBlock(),e.createElementBlock("div",oe,[e.createBaseVNode("label",ne,[e.createBaseVNode("span",null,e.toDisplayString(e.unref(a)("giftCard.selectType")),1)]),e.createBaseVNode("div",ie,[e.createBaseVNode("ul",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(r),(t,v)=>(e.openBlock(),e.createElementBlock("li",{key:v},[e.createVNode(N.Checkbox,{modelValue:e.unref(c),"onUpdate:modelValue":o[3]||(o[3]=m=>e.isRef(c)?c.value=m:null),type:"radio",name:"placeType",val:v,label:t.label},null,8,["modelValue","val","label"])]))),128))]),e.unref(r)[e.unref(c)]&&e.unref(r)[e.unref(c)].data.length>1?(e.openBlock(),e.createBlock(e._sfc_main,{key:0,modelValue:e.unref(p),"onUpdate:modelValue":o[4]||(o[4]=t=>e.isRef(p)?p.value=t:null),placeholder:e.unref(a)("giftCard.selectPlacePlaceholder"),options:e.unref(r)[e.unref(c)].data,labelKey:"name",valueKey:"id",required:""},null,8,["modelValue","placeholder","options"])):e.createCommentVNode("",!0)])])):(e.openBlock(),e.createBlock(e.Loading,{key:1}))])),e.createVNode(e.TextField,{modelValue:e.unref(_),"onUpdate:modelValue":o[5]||(o[5]=t=>e.isRef(_)?_.value=t:null),type:"number",name:"value",label:e.unref(a)("giftCard.value"),icon:"money-bill",placeholder:e.unref(a)("giftCard.valuePlaceholder"),suffix:e.unref(E),required:""},null,8,["modelValue","label","placeholder","suffix"]),e.createVNode(N.Checkbox,{modelValue:e.unref(s),"onUpdate:modelValue":o[6]||(o[6]=t=>e.isRef(s)?s.value=t:null),type:"checkbox",name:"showValue",label:e.unref(a)("giftCard.showValue"),checked:e.unref(s)},null,8,["modelValue","label","checked"]),e.createCommentVNode("",!0),e.createCommentVNode("",!0)])],512),[[e.vShow,e.unref(u)]]),e.withDirectives(e.createBaseVNode("div",null,[e.createBaseVNode("div",{innerHTML:e.unref(a)("giftCard.thankYou")},null,8,re)],512),[[e.vShow,e.unref(i)]])]),B.layout!=="minimal"&&e.unref(u)?(e.openBlock(),e.createElementBlock("div",de,[e.createBaseVNode("div",se,[e.createVNode(e.Clickable,{label:e.unref(a)("giftCard.orderGiftCard"),"full-width":!0,disabled:!e.unref(k),"is-loading":e.unref(f),"onUpdate:isLoading":o[9]||(o[9]=t=>e.isRef(f)?f.value=t:null),onClickEvent:P},null,8,["label","disabled","is-loading"])])])):e.createCommentVNode("",!0),e.unref(u)?(e.openBlock(),e.createElementBlock("div",ce,[e.createVNode(e.TextField,{modelValue:e.unref(d),"onUpdate:modelValue":o[10]||(o[10]=t=>e.isRef(d)?d.value=t:null),type:"textarea",name:"remark",label:e.unref(a)("giftCard.remark"),icon:"info-circle",placeholder:e.unref(a)("giftCard.remarkPlaceholder")},null,8,["modelValue","label","placeholder"])])):e.createCommentVNode("",!0),e.unref(u)?e.withDirectives((e.openBlock(),e.createElementBlock("div",ue,[e.createVNode(e.Clickable,{label:e.unref(a)("giftCard.orderGiftCard"),"full-width":!0,disabled:!e.unref(k),"data-test":"orderGiftCard","is-loading":e.unref(f),"onUpdate:isLoading":o[11]||(o[11]=t=>e.isRef(f)?f.value=t:null),onClickEvent:P},null,8,["label","disabled","is-loading"]),e.withDirectives(e.createBaseVNode("div",fe,[e.createVNode(N._sfc_main)],512),[[e.vShow,e.unref(V)]])])),[[q]]):e.createCommentVNode("",!0)])):(e.openBlock(),e.createBlock(e.Loading,{key:1}))]),_:1},8,["access-token","data-layout","styling"])]),fallback:e.withCtx(()=>[e.createVNode(Q)]),_:1})}}});const me=e._export_sfc(pe,[["__scopeId","data-v-e4aa1e4c"]]),_e=e.createPinia(),ve=e.Go(),S=e.createApp({components:{GiftCard:me}});S.use(_e);S.use(e.instance);S.use(ve);S.use(N.StickyPlugin);S.use(e.install,{bootstrap:!0});S.mount("#konnectio-gift-card-app");
1
+ "use strict";const e=require("./SelectField.vue_vue_type_style_index_0_lang-88de73f4.cjs"),R=require("./CheckoutWindow-a2dfaa01.cjs"),M=require("./_-357f8de1.cjs"),T=require("./Field-0588c03e.cjs");require("./_commonjsHelpers-6763f629.cjs");const U=e.defineStore("giftCard",()=>{const{pay:h}=e.usePaymentStore(),{bearerToken:t,metaData:v,currencyId:b}=e.storeToRefs(e.useUtilityStore()),n=e.ref(e.GiftCardModuleState.InitialState),_=e.useStorage("konnectio_name","",void 0,{serializer:e.StorageSerializers.string}),u=e.useStorage("konnectio_email","",void 0,{serializer:e.StorageSerializers.string}),s=e.useStorage("konnectio_phone","",void 0,{serializer:e.StorageSerializers.string}),V=e.ref(""),S=e.ref(1),m=e.ref(!0),c=e.ref(""),f=e.ref({base64:"",type:"",name:""}),l=e.ref(void 0),i=e.ref(0),r=e.ref(!1),g=e.ref(0),B=e.computed(()=>n.value===e.GiftCardModuleState.InitialState||n.value===e.GiftCardModuleState.WaitingForResponse),p=e.computed(()=>n.value===e.GiftCardModuleState.ReadyToPay),F=e.computed(()=>n.value===e.GiftCardModuleState.PaymentSuccess),w=e.computed(()=>{const d={1:{label:e.i18n.t("giftCard.hotelType"),data:[]},2:{label:e.i18n.t("giftCard.restaurantType"),data:[]}},k=v.value.places;return k&&k.forEach(y=>{d[y.placeType].data.push(y)}),Object.fromEntries(Object.entries(d).filter(([,y])=>y.data.length>0))}),E=e.computed(()=>g.value!==0),C=e.computed(()=>{let d;if(E.value)d=w.value[g.value].data[0];else if(i.value!==0){const k=l.value,y=w.value[i.value].data;y.length===1?d=y[0]:k!==void 0&&y.forEach(G=>{String(G.id)===String(k)&&(d=G)})}return d}),q=e.computed(()=>!(!_.value||!u.value||!(s.value.length>=5)||!V.value||C.value===void 0)),P=e.computed(()=>!(n.value===e.GiftCardModuleState.InitialState&&r.value)),N=e.computed(()=>!!(n.value===e.GiftCardModuleState.WaitingForResponse&&r.value));async function o(){n.value=e.GiftCardModuleState.WaitingForResponse,r.value=!0,await e.axios.post("https://production.hotel-service.konnectio.dk/api/gift-card/create",{termsOfserviceURL:"https://freshbooking.dk",checkoutUrl:"https://freshbooking.dk",currencyID:b.value,language:e.getUserLanguage(),amount:V.value,quantity:S.value,freeText:c.value,showPrice:m.value,contactName:_.value,contactEmail:u.value,contactPhone:s.value,imageBase64:e.b2a(f.value.base64),imageName:f.value.name,imageFormat:f.value.type,placeType:C.value?C.value.placeType:void 0,placeID:C.value?C.value.id:void 0},{headers:{Authorization:t.value,Accept:"application/json","Fresh-Booking-Ver":"4.0.43"}}).then(d=>{n.value=e.GiftCardModuleState.ReadyToPay,r.value=!1,h({callback:()=>console.log("Callback!"),response:d.data})})}function a(d){d&&(g.value=d)}return{moduleState:n,name:_,email:u,phone:s,value:V,remark:c,showValue:m,quantity:S,media:f,placeId:l,placeType:i,showFormPage:B,showPaymentPage:p,showConfirmationPage:F,places:w,hasFilledForm:q,hasForcedPlaceType:E,isWaitingForResponse:N,isMetaDataAvailable:P,orderGiftCard:o,initialize:a}}),I={class:"media-selector"},L=["accept"],D={class:"media-selector-wrapper"},z={class:"media-selector-tools"},A={key:0},W={key:1},j={key:2},H=["src"],O=e.defineComponent({__name:"MediaSelector",props:{modelValue:{},validation:{default:"image/*"},iconColor:{default:"#000"},label:{},required:{type:Boolean,default:!1}},emits:["update:modelValue"],setup(h,{emit:t}){const v=t,b=h,{t:n}=e.useI18n(),{display:_}=e.useAlertStore(),u=e.ref(),s=e.computed(()=>b.modelValue.base64!=="");function V(l){v("update:modelValue",l)}function S(){V({base64:"",name:"",type:""}),u.value&&(u.value.value="")}function m(){u.value&&u.value.click()}function c(l,i){const[r,g]=[l.name,l.type],B=new FileReader;B.onload=function(p){if(p.target){const F=p.target.result;i({base64:F,name:r,type:g})}else _({message:n("imageUploadError"),type:"error"})},B.readAsDataURL(l)}async function f(){let l;(l=u.value.files)instanceof FileList&&c(l[0],V)}return(l,i)=>(e.openBlock(),e.createBlock(e.InputField,{label:l.label,required:l.required,type:"media"},{default:e.withCtx(()=>[e.createBaseVNode("div",I,[e.createBaseVNode("input",{ref_key:"fileInput",ref:u,type:"file",class:"hidden",accept:l.validation,single:"",onChange:i[0]||(i[0]=r=>f())},null,40,L),e.createBaseVNode("div",D,[e.createBaseVNode("ul",z,[s.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("li",A,[e.createVNode(e.Clickable,{label:e.unref(n)("uploadFile"),type:"button",icon:"upload","icon-color":l.iconColor,onClickEvent:i[1]||(i[1]=r=>m())},null,8,["label","icon-color"])])),s.value?(e.openBlock(),e.createElementBlock("li",W,[e.createVNode(e.Clickable,{label:e.unref(n)("replaceFile"),type:"button",icon:"repeat-alt","icon-color":l.iconColor,onClickEvent:i[2]||(i[2]=r=>m())},null,8,["label","icon-color"])])):e.createCommentVNode("",!0),s.value?(e.openBlock(),e.createElementBlock("li",j,[e.createVNode(e.Clickable,{label:e.unref(n)("removeFile"),type:"button",icon:"trash-alt","icon-color":l.iconColor,onClickEvent:i[3]||(i[3]=r=>S())},null,8,["label","icon-color"])])):e.createCommentVNode("",!0)]),e.createBaseVNode("div",{class:e.normalizeClass(["media-selector-previewer",{opened:s.value}])},[l.modelValue?(e.openBlock(),e.createElementBlock("img",{key:0,src:l.modelValue.base64},null,8,H)):e.createCommentVNode("",!0)],2)])])]),_:1},8,["label","required"]))}});function $(h){const t=h;t.__i18n=t.__i18n||[],t.__i18n.push({locale:"",resource:{da:{uploadFile:{t:0,b:{t:2,i:[{t:3}],s:"Upload billede"}},removeFile:{t:0,b:{t:2,i:[{t:3}],s:"Fjern billede"}},replaceFile:{t:0,b:{t:2,i:[{t:3}],s:"Ersat billede"}},imageUploadError:{t:0,b:{t:2,i:[{t:3}],s:"Der skete en fejl under billede upload!"}}},en:{uploadFile:{t:0,b:{t:2,i:[{t:3}],s:"Upload image"}},removeFile:{t:0,b:{t:2,i:[{t:3}],s:"Remove image"}},replaceFile:{t:0,b:{t:2,i:[{t:3}],s:"Replace image"}},imageUploadError:{t:0,b:{t:2,i:[{t:3}],s:"An error occurred under image upload!"}}}}})}typeof $=="function"&&$(O);const K={class:"gift-card-skeleton"},Y={class:"gift-card-skeleton-form"},J=e.defineComponent({__name:"GiftCardSkeleton",setup(h){return(t,v)=>(e.openBlock(),e.createElementBlock("div",K,[e.createBaseVNode("div",Y,[e.createVNode(T.Field),e.createVNode(T.Field),e.createVNode(T.Field),e.createVNode(T.Field),e.createVNode(T.Field,{"is-text-area":""}),e.createVNode(M.Element,{height:"44px"})])]))}});const Q=e._export_sfc(J,[["__scopeId","data-v-2600a731"]]),X={key:0,id:"fresh-booking-gift-card-wrapper"},Z={id:"fresh-booking-gift-card-title"},ee={id:"fresh-booking-gift-card-content"},te={id:"fresh-booking-gift-card-payment"},ae=["innerHTML"],le={key:0},oe={key:0,id:"fresh-booking-select-place-type"},ne={class:e.normalizeClass(["fresh-booking-label","required"])},ie={id:"fresh-booking-select-place-type-input"},re=["innerHTML"],de={key:0,id:"fresh-booking-gift-card-order"},ue={class:"fresh-booking-panel"},se={key:1,id:"fresh-booking-gift-card-remarks"},ce={key:2,id:"fresh-booking-gift-card-order-minimal"},fe={id:"fresh-booking-gift-card-recaptcha"},pe=e.defineComponent({name:"GiftCardLayout",__name:"GiftCard",props:{accessToken:{},layout:{default:"minimal"},placeType:{},styling:{}},setup(h){const{t}=e.useI18n(),{name:v,email:b,phone:n,value:_,remark:u,showValue:s,quantity:V,media:S,placeId:m,placeType:c,showFormPage:f,showPaymentPage:l,showConfirmationPage:i,places:r,hasFilledForm:g,hasForcedPlaceType:B,isWaitingForResponse:p,isMetaDataAvailable:F}=e.storeToRefs(U()),{initialize:w,orderGiftCard:E}=U(),{isRecaptchaEnabled:C,currency:q}=e.storeToRefs(e.useUtilityStore());async function P(){await E()}return e.watch(c,()=>{m.value=void 0}),e.onMounted(()=>{w()}),(N,o)=>(e.openBlock(),e.createBlock(e.Suspense,null,{default:e.withCtx(()=>[e.createVNode(e._sfc_main$1,{id:"fresh-booking-gift-card-module",type:"gift-card","access-token":N.accessToken,"data-layout":N.layout,styling:N.styling},{default:e.withCtx(()=>[e.unref(F)?(e.openBlock(),e.createElementBlock("div",X,[e.createBaseVNode("h4",Z,[e.createBaseVNode("span",null,e.toDisplayString(e.unref(t)("giftCard.title")),1)]),e.createBaseVNode("div",ee,[e.withDirectives(e.createBaseVNode("div",te,[e.createVNode(R.CheckoutWindow)],512),[[e.vShow,e.unref(l)]]),e.withDirectives(e.createBaseVNode("div",null,[e.createBaseVNode("p",{id:"fresh-booking-gift-card-description",innerHTML:e.unref(t)("giftCard.description")},null,8,ae),e.createBaseVNode("form",null,[e.createVNode(e.TextField,{modelValue:e.unref(v),"onUpdate:modelValue":o[0]||(o[0]=a=>e.isRef(v)?v.value=a:null),type:"text",name:"name",autocomplete:"name",label:e.unref(t)("giftCard.name"),icon:"user-alt",placeholder:e.unref(t)("giftCard.namePlaceholder"),required:""},null,8,["modelValue","label","placeholder"]),e.createVNode(e.TextField,{modelValue:e.unref(b),"onUpdate:modelValue":o[1]||(o[1]=a=>e.isRef(b)?b.value=a:null),type:"email",name:"email",autocomplete:"email",label:e.unref(t)("giftCard.email"),icon:"at",placeholder:e.unref(t)("giftCard.emailPlaceholder"),required:""},null,8,["modelValue","label","placeholder"]),e.createVNode(R.PhoneField,{modelValue:e.unref(n),"onUpdate:modelValue":o[2]||(o[2]=a=>e.isRef(n)?n.value=a:null),icon:"phone-office",label:e.unref(t)("giftCard.phone"),placeholder:e.unref(t)("giftCard.phonePlaceholder"),required:""},null,8,["modelValue","label","placeholder"]),e.unref(B)?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",le,[e.unref(r)?(e.openBlock(),e.createElementBlock("div",oe,[e.createBaseVNode("label",ne,[e.createBaseVNode("span",null,e.toDisplayString(e.unref(t)("giftCard.selectType")),1)]),e.createBaseVNode("div",ie,[e.createBaseVNode("ul",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(r),(a,d)=>(e.openBlock(),e.createElementBlock("li",{key:d},[e.createVNode(R.Checkbox,{modelValue:e.unref(c),"onUpdate:modelValue":o[3]||(o[3]=k=>e.isRef(c)?c.value=k:null),type:"radio",name:"placeType",val:d,label:a.label},null,8,["modelValue","val","label"])]))),128))]),e.unref(r)[e.unref(c)]&&e.unref(r)[e.unref(c)].data.length>1?(e.openBlock(),e.createBlock(e._sfc_main,{key:0,modelValue:e.unref(m),"onUpdate:modelValue":o[4]||(o[4]=a=>e.isRef(m)?m.value=a:null),placeholder:e.unref(t)("giftCard.selectPlacePlaceholder"),options:e.unref(r)[e.unref(c)].data,labelKey:"name",valueKey:"id",required:""},null,8,["modelValue","placeholder","options"])):e.createCommentVNode("",!0)])])):(e.openBlock(),e.createBlock(e.Loading,{key:1}))])),e.createVNode(e.TextField,{modelValue:e.unref(_),"onUpdate:modelValue":o[5]||(o[5]=a=>e.isRef(_)?_.value=a:null),type:"number",name:"value",label:e.unref(t)("giftCard.value"),icon:"money-bill",placeholder:e.unref(t)("giftCard.valuePlaceholder"),suffix:e.unref(q),required:""},null,8,["modelValue","label","placeholder","suffix"]),e.createVNode(R.Checkbox,{modelValue:e.unref(s),"onUpdate:modelValue":o[6]||(o[6]=a=>e.isRef(s)?s.value=a:null),type:"checkbox",name:"showValue",label:e.unref(t)("giftCard.showValue"),checked:e.unref(s)},null,8,["modelValue","label","checked"]),e.createCommentVNode("",!0),e.createCommentVNode("",!0)])],512),[[e.vShow,e.unref(f)]]),e.withDirectives(e.createBaseVNode("div",null,[e.createBaseVNode("div",{innerHTML:e.unref(t)("giftCard.thankYou")},null,8,re)],512),[[e.vShow,e.unref(i)]])]),N.layout!=="minimal"&&e.unref(f)?(e.openBlock(),e.createElementBlock("div",de,[e.createBaseVNode("div",ue,[e.createVNode(e.Clickable,{label:e.unref(t)("giftCard.orderGiftCard"),"full-width":!0,disabled:!e.unref(g),"is-loading":e.unref(p),"onUpdate:isLoading":o[9]||(o[9]=a=>e.isRef(p)?p.value=a:null),onClickEvent:P},null,8,["label","disabled","is-loading"])])])):e.createCommentVNode("",!0),e.unref(f)?(e.openBlock(),e.createElementBlock("div",se,[e.createVNode(e.TextField,{modelValue:e.unref(u),"onUpdate:modelValue":o[10]||(o[10]=a=>e.isRef(u)?u.value=a:null),type:"textarea",name:"remark",label:e.unref(t)("giftCard.remark"),icon:"info-circle",placeholder:e.unref(t)("giftCard.remarkPlaceholder")},null,8,["modelValue","label","placeholder"])])):e.createCommentVNode("",!0),e.unref(f)?(e.openBlock(),e.createElementBlock("div",ce,[e.createVNode(e.Clickable,{label:e.unref(t)("giftCard.orderGiftCard"),"full-width":!0,disabled:!e.unref(g),"data-test":"orderGiftCard","is-loading":e.unref(p),"onUpdate:isLoading":o[11]||(o[11]=a=>e.isRef(p)?p.value=a:null),onClickEvent:P},null,8,["label","disabled","is-loading"]),e.withDirectives(e.createBaseVNode("div",fe,[e.createVNode(R._sfc_main)],512),[[e.vShow,e.unref(C)]])])):e.createCommentVNode("",!0)])):(e.openBlock(),e.createBlock(e.Loading,{key:1}))]),_:1},8,["access-token","data-layout","styling"])]),fallback:e.withCtx(()=>[e.createVNode(Q)]),_:1}))}});const me=e._export_sfc(pe,[["__scopeId","data-v-d95c25af"]]),_e=e.createPinia(),ve=e.Go(),x=e.createApp({components:{GiftCard:me}});x.use(_e);x.use(e.instance);x.use(ve);x.use(e.install,{bootstrap:!0});x.mount("#konnectio-gift-card-app");