@konnectio/core 4.0.56-rc2 → 4.0.56-rc21
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{ActionField-Qf4JAgBa.js → ActionField-mMYGNb-7.js} +29 -30
- package/dist/ActionField-mMYGNb-7.js.br +0 -0
- package/dist/AvailabilitySkeleton-iD7Vbt5K.js +215 -0
- package/dist/AvailabilitySkeleton-iD7Vbt5K.js.br +0 -0
- package/dist/{CheckoutWindow-S9xKe_Wf.js → CheckoutWindow-T32YH60g.js} +37 -38
- package/dist/CheckoutWindow-T32YH60g.js.br +0 -0
- package/dist/DateField.vue_vue_type_style_index_0_lang-seJ00xvJ.js +7607 -0
- package/dist/DateField.vue_vue_type_style_index_0_lang-seJ00xvJ.js.br +0 -0
- package/dist/ErrorMessage-4GwDZEsl.js +36 -0
- package/dist/ErrorMessage-4GwDZEsl.js.br +0 -0
- package/dist/EventAvailabilityForm-jvxOZKWx.js +366 -0
- package/dist/EventAvailabilityForm-jvxOZKWx.js.br +0 -0
- package/dist/{Field-b7XkSAoi.js → Field-EqFBeBE_.js} +11 -13
- package/dist/Field-EqFBeBE_.js.br +0 -0
- package/dist/{ThankYou-LiiG3Zv1.js → ThankYou-pu1PDfhl.js} +4772 -5989
- package/dist/ThankYou-pu1PDfhl.js.br +0 -0
- package/dist/_--L3VvP-p.js +30301 -0
- package/dist/_--L3VvP-p.js.br +0 -0
- package/dist/availability.js +80 -147
- package/dist/availability.js.br +0 -0
- package/dist/event.js +342 -529
- package/dist/event.js.br +0 -0
- package/dist/gift-card-validation.js +92 -57
- package/dist/gift-card-validation.js.br +0 -0
- package/dist/gift-card.js +272 -259
- package/dist/gift-card.js.br +0 -0
- package/dist/hotel.js +1658 -1518
- package/dist/hotel.js.br +0 -0
- package/dist/polyfill.js +3201 -3210
- package/dist/polyfill.js.br +0 -0
- package/dist/style.css +1 -1
- package/dist/style.css.br +0 -0
- package/package.json +34 -25
- package/dist/ActionField-Qf4JAgBa.js.br +0 -0
- package/dist/ActionField-ztW-1xka.cjs +0 -1
- package/dist/AvailabilitySkeleton-GPTCv3Xy.js +0 -242
- package/dist/AvailabilitySkeleton-GPTCv3Xy.js.br +0 -0
- package/dist/AvailabilitySkeleton-v0QVPuim.cjs +0 -1
- package/dist/CheckoutWindow-NUwbNAPw.cjs +0 -1
- package/dist/CheckoutWindow-S9xKe_Wf.js.br +0 -0
- package/dist/Container-Fl2PKj-u.js +0 -59
- package/dist/Container-Fl2PKj-u.js.br +0 -0
- package/dist/Container-Y6_3uTWy.cjs +0 -1
- package/dist/DateField.vue_vue_type_style_index_0_lang-hZTsLsOv.cjs +0 -2
- package/dist/DateField.vue_vue_type_style_index_0_lang-iz9zEBOR.js +0 -8559
- package/dist/DateField.vue_vue_type_style_index_0_lang-iz9zEBOR.js.br +0 -0
- package/dist/Field-UTbHMN9U.cjs +0 -1
- package/dist/Field-b7XkSAoi.js.br +0 -0
- package/dist/SelectField.vue_vue_type_style_index_0_lang-30hJu8vr.js +0 -21406
- package/dist/SelectField.vue_vue_type_style_index_0_lang-30hJu8vr.js.br +0 -0
- package/dist/SelectField.vue_vue_type_style_index_0_lang-eLyZ247i.cjs +0 -851
- package/dist/ThankYou-LiiG3Zv1.js.br +0 -0
- package/dist/ThankYou-M6d4G8pc.cjs +0 -59
- package/dist/_-FAlGPZqe.js +0 -20
- package/dist/_-oL4OsiNw.cjs +0 -1
- package/dist/_commonjsHelpers-f52AuuUj.cjs +0 -1
- package/dist/assets/typescript/mixins.d.ts +0 -34
- package/dist/availability.cjs +0 -2
- package/dist/availability.d.ts +0 -3
- package/dist/components/Alert.vue.d.ts +0 -5
- package/dist/components/Alert.vue.d.ts.map +0 -1
- package/dist/components/Clickable.vue.d.ts +0 -5
- package/dist/components/Clickable.vue.d.ts.map +0 -1
- package/dist/components/Container.vue.d.ts +0 -5
- package/dist/components/Container.vue.d.ts.map +0 -1
- package/dist/components/ErrorMessage.vue.d.ts +0 -5
- package/dist/components/ErrorMessage.vue.d.ts.map +0 -1
- package/dist/components/Gallery.vue.d.ts +0 -5
- package/dist/components/Gallery.vue.d.ts.map +0 -1
- package/dist/components/GoogleNotice.vue.d.ts +0 -4
- package/dist/components/GoogleNotice.vue.d.ts.map +0 -1
- package/dist/components/Icon.vue.d.ts +0 -5
- package/dist/components/Icon.vue.d.ts.map +0 -1
- package/dist/components/Loading.vue.d.ts +0 -5
- package/dist/components/Loading.vue.d.ts.map +0 -1
- package/dist/components/Spinner.vue.d.ts +0 -4
- package/dist/components/Spinner.vue.d.ts.map +0 -1
- package/dist/components/forms/EventAvailabilityForm.vue.d.ts +0 -5
- package/dist/components/forms/EventAvailabilityForm.vue.d.ts.map +0 -1
- package/dist/components/forms/HotelAvailabilityForm.vue.d.ts +0 -5
- package/dist/components/forms/HotelAvailabilityForm.vue.d.ts.map +0 -1
- package/dist/components/forms/HotelReservationForm.vue.d.ts +0 -4
- package/dist/components/forms/HotelReservationForm.vue.d.ts.map +0 -1
- package/dist/components/forms/MultiStepForm.vue.d.ts +0 -5
- package/dist/components/forms/MultiStepForm.vue.d.ts.map +0 -1
- package/dist/components/forms/ReservationForm.vue.d.ts +0 -6
- package/dist/components/forms/ReservationForm.vue.d.ts.map +0 -1
- package/dist/components/forms/_.vue.d.ts +0 -4
- package/dist/components/forms/_.vue.d.ts.map +0 -1
- package/dist/components/inputs/Checkbox.vue.d.ts +0 -5
- package/dist/components/inputs/Checkbox.vue.d.ts.map +0 -1
- package/dist/components/inputs/CheckboxField.vue.d.ts +0 -5
- package/dist/components/inputs/CheckboxField.vue.d.ts.map +0 -1
- package/dist/components/inputs/DateField.vue.d.ts +0 -5
- package/dist/components/inputs/DateField.vue.d.ts.map +0 -1
- package/dist/components/inputs/InputField.vue.d.ts +0 -5
- package/dist/components/inputs/InputField.vue.d.ts.map +0 -1
- package/dist/components/inputs/MediaSelector.vue.d.ts +0 -5
- package/dist/components/inputs/MediaSelector.vue.d.ts.map +0 -1
- package/dist/components/inputs/NumberField.vue.d.ts +0 -5
- package/dist/components/inputs/NumberField.vue.d.ts.map +0 -1
- package/dist/components/inputs/SelectField.vue.d.ts +0 -5
- package/dist/components/inputs/SelectField.vue.d.ts.map +0 -1
- package/dist/components/inputs/TextField.vue.d.ts +0 -5
- package/dist/components/inputs/TextField.vue.d.ts.map +0 -1
- package/dist/components/inputs/TimeField.vue.d.ts +0 -5
- package/dist/components/inputs/TimeField.vue.d.ts.map +0 -1
- package/dist/components/inputs/grouped/ActionField.vue.d.ts +0 -5
- package/dist/components/inputs/grouped/ActionField.vue.d.ts.map +0 -1
- package/dist/components/inputs/grouped/CountryField.vue.d.ts +0 -5
- package/dist/components/inputs/grouped/CountryField.vue.d.ts.map +0 -1
- package/dist/components/inputs/grouped/NameField.vue.d.ts +0 -5
- package/dist/components/inputs/grouped/NameField.vue.d.ts.map +0 -1
- package/dist/components/inputs/grouped/PhoneField.vue.d.ts +0 -5
- package/dist/components/inputs/grouped/PhoneField.vue.d.ts.map +0 -1
- package/dist/components/inputs/grouped/RoomConfigField.vue.d.ts +0 -5
- package/dist/components/inputs/grouped/RoomConfigField.vue.d.ts.map +0 -1
- package/dist/components/listings/Base.vue.d.ts +0 -6
- package/dist/components/listings/Base.vue.d.ts.map +0 -1
- package/dist/components/listings/Event.vue.d.ts +0 -5
- package/dist/components/listings/Event.vue.d.ts.map +0 -1
- package/dist/components/listings/Hotel.vue.d.ts +0 -5
- package/dist/components/listings/Hotel.vue.d.ts.map +0 -1
- package/dist/components/listings/Template.vue.d.ts +0 -5
- package/dist/components/listings/Template.vue.d.ts.map +0 -1
- package/dist/components/side-panels/Base.vue.d.ts +0 -6
- package/dist/components/side-panels/Base.vue.d.ts.map +0 -1
- package/dist/components/side-panels/ListingInfo.vue.d.ts +0 -5
- package/dist/components/side-panels/ListingInfo.vue.d.ts.map +0 -1
- package/dist/components/side-panels/Template.vue.d.ts +0 -5
- package/dist/components/side-panels/Template.vue.d.ts.map +0 -1
- package/dist/components/side-panels/TermsOfService.vue.d.ts +0 -5
- package/dist/components/side-panels/TermsOfService.vue.d.ts.map +0 -1
- package/dist/components/skeletons/AvailabilitySkeleton.vue.d.ts +0 -5
- package/dist/components/skeletons/AvailabilitySkeleton.vue.d.ts.map +0 -1
- package/dist/components/skeletons/Field.vue.d.ts +0 -5
- package/dist/components/skeletons/Field.vue.d.ts.map +0 -1
- package/dist/components/skeletons/GiftCardSkeleton.vue.d.ts +0 -5
- package/dist/components/skeletons/GiftCardSkeleton.vue.d.ts.map +0 -1
- package/dist/components/skeletons/HotelSkeleton.vue.d.ts +0 -5
- package/dist/components/skeletons/HotelSkeleton.vue.d.ts.map +0 -1
- package/dist/components/skeletons/Listing.vue.d.ts +0 -5
- package/dist/components/skeletons/Listing.vue.d.ts.map +0 -1
- package/dist/components/skeletons/Sidebar.vue.d.ts +0 -5
- package/dist/components/skeletons/Sidebar.vue.d.ts.map +0 -1
- package/dist/components/skeletons/_.vue.d.ts +0 -5
- package/dist/components/skeletons/_.vue.d.ts.map +0 -1
- package/dist/components/views/CheckoutWindow.vue.d.ts +0 -5
- package/dist/components/views/CheckoutWindow.vue.d.ts.map +0 -1
- package/dist/components/views/TermsOfService.vue.d.ts +0 -5
- package/dist/components/views/TermsOfService.vue.d.ts.map +0 -1
- package/dist/components/views/ThankYou.vue.d.ts +0 -5
- package/dist/components/views/ThankYou.vue.d.ts.map +0 -1
- package/dist/entries/availability.d.ts +0 -5
- package/dist/entries/event.d.ts +0 -2
- package/dist/entries/gift-card-validation.d.ts +0 -5
- package/dist/entries/gift-card.d.ts +0 -5
- package/dist/entries/hotel.d.ts +0 -5
- package/dist/entries/navigation.d.ts +0 -1
- package/dist/entries/polyfill.d.ts +0 -0
- package/dist/event-GaUgVNzy.cjs +0 -1
- package/dist/event-MXmxvcpC.js +0 -329
- package/dist/event-MXmxvcpC.js.br +0 -0
- package/dist/event.cjs +0 -1
- package/dist/event.d.ts +0 -3
- package/dist/gift-card-validation.cjs +0 -1
- package/dist/gift-card-validation.d.ts +0 -3
- package/dist/gift-card.cjs +0 -1
- package/dist/gift-card.d.ts +0 -3
- package/dist/hotel.cjs +0 -19
- package/dist/hotel.d.ts +0 -3
- package/dist/layouts/Availability.vue.d.ts +0 -25
- package/dist/layouts/Event.vue.d.ts +0 -18
- package/dist/layouts/GiftCard.vue.d.ts +0 -32
- package/dist/layouts/GiftCardValidation.vue.d.ts +0 -18
- package/dist/layouts/Hotel.vue.d.ts +0 -36
- package/dist/layouts/_.vue.d.ts +0 -39
- package/dist/navigation.cjs +0 -1
- package/dist/navigation.d.ts +0 -1
- package/dist/plugins/i18n.d.ts +0 -5
- package/dist/polyfill.cjs +0 -4
- package/dist/polyfill.d.ts +0 -1
- package/dist/store/alert.d.ts +0 -28
- package/dist/store/applyGiftCard.d.ts +0 -28
- package/dist/store/availability.d.ts +0 -40
- package/dist/store/event.d.ts +0 -683
- package/dist/store/giftCard.d.ts +0 -83
- package/dist/store/payment.d.ts +0 -139
- package/dist/store/recaptcha.d.ts +0 -28
- package/dist/store/tracking.d.ts +0 -57
- package/dist/store/utilities.d.ts +0 -350
- package/dist/types/index.d.ts +0 -976
package/dist/gift-card.js
CHANGED
|
@@ -1,102 +1,99 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
import "./_commonjsHelpers-f3sTPFkQ.js";
|
|
8
|
-
const oe = be("giftCard", () => {
|
|
9
|
-
const { pay: h } = ye(), { bearerToken: p, metaData: R, currencyId: o } = Q(re()), d = b(U.InitialState), P = J("konnectio_name", "", void 0, { serializer: Y.string }), u = J("konnectio_email", "", void 0, { serializer: Y.string }), m = J("konnectio_phone", "", void 0, { serializer: Y.string }), k = b(""), w = b(1), T = b(!0), G = b(""), v = b({
|
|
1
|
+
import { V as re, W as de, B as Q, D as oe, k as C, a8 as $, $ as Z, c as _, a4 as ee, a0 as J, a3 as ue, a2 as ce, a9 as pe, d as X, j as ne, Y as me, o as c, a as I, w as G, b as s, h as g, f as i, u as e, C as B, i as V, n as ie, I as fe, E as ve, g as se, G as ge, l as he, S as be, t as ae, aa as D, ab as W, F as ye, J as ke, H as T, _ as Ce, L as _e, T as j, e as Ve, q as we, s as Fe, y as Pe, z as Te, A as Se, U as $e } from "./_--L3VvP-p.js";
|
|
2
|
+
import { a as Ee, C as Ue, P as Ae, _ as Re } from "./CheckoutWindow-T32YH60g.js";
|
|
3
|
+
import { F as M } from "./Field-EqFBeBE_.js";
|
|
4
|
+
import { E as Ie } from "./ErrorMessage-4GwDZEsl.js";
|
|
5
|
+
const le = re("giftCard", () => {
|
|
6
|
+
const { pay: S } = de(), { bearerToken: m, metaData: w, currencyId: o } = Q(oe()), r = C($.InitialState), h = Z("konnectio_name", "", void 0, { serializer: J.string }), d = Z("konnectio_email", "", void 0, { serializer: J.string }), f = Z("konnectio_phone", "", void 0, { serializer: J.string }), n = C(""), v = C(1), p = C(!0), L = C(""), y = C({
|
|
10
7
|
base64: "",
|
|
11
8
|
type: "",
|
|
12
9
|
name: ""
|
|
13
|
-
}), l =
|
|
10
|
+
}), l = C(void 0), u = C(0), b = C(!1), U = C(0), F = _(() => r.value === $.InitialState || r.value === $.WaitingForResponse), A = _(() => r.value === $.ReadyToPay), q = _(() => r.value === $.PaymentSuccess), P = _(() => {
|
|
14
11
|
const a = {
|
|
15
12
|
1: {
|
|
16
|
-
label:
|
|
13
|
+
label: ee.t("giftCard.hotelType"),
|
|
17
14
|
data: []
|
|
18
15
|
},
|
|
19
16
|
2: {
|
|
20
|
-
label:
|
|
17
|
+
label: ee.t("giftCard.restaurantType"),
|
|
21
18
|
data: []
|
|
22
19
|
}
|
|
23
|
-
},
|
|
24
|
-
return
|
|
25
|
-
a[
|
|
20
|
+
}, t = w.value.hotels[0].places;
|
|
21
|
+
return t && t.forEach((k) => {
|
|
22
|
+
a[k.placeType].data.push(k);
|
|
26
23
|
}), Object.fromEntries(
|
|
27
|
-
Object.entries(a).filter(([,
|
|
24
|
+
Object.entries(a).filter(([, k]) => k.data.length > 0)
|
|
28
25
|
);
|
|
29
|
-
}),
|
|
26
|
+
}), H = _(() => U.value !== 0), E = _(() => {
|
|
30
27
|
let a;
|
|
31
|
-
if (
|
|
32
|
-
a =
|
|
33
|
-
else if (
|
|
34
|
-
const
|
|
35
|
-
|
|
36
|
-
String(
|
|
28
|
+
if (H.value)
|
|
29
|
+
a = P.value[U.value].data[0];
|
|
30
|
+
else if (u.value !== 0) {
|
|
31
|
+
const t = l.value, k = P.value[u.value].data;
|
|
32
|
+
k.length === 1 ? a = k[0] : t !== void 0 && k.forEach((z) => {
|
|
33
|
+
String(z.id) === String(t) && (a = z);
|
|
37
34
|
});
|
|
38
35
|
}
|
|
39
36
|
return a;
|
|
40
|
-
}),
|
|
41
|
-
async function
|
|
42
|
-
|
|
37
|
+
}), x = _(() => !(!h.value || !d.value || !(f.value.length >= 5) || !n.value || E.value === void 0)), N = _(() => !(r.value === $.InitialState && b.value)), K = _(() => !!(r.value === $.WaitingForResponse && b.value));
|
|
38
|
+
async function Y() {
|
|
39
|
+
r.value = $.WaitingForResponse, b.value = !0, await ue.post("https://production.hotel-service.konnectio.dk/api/gift-card/create", {
|
|
43
40
|
termsOfserviceURL: window.location.origin,
|
|
44
41
|
checkoutUrl: window.location.origin,
|
|
45
42
|
currencyID: o.value,
|
|
46
|
-
language:
|
|
47
|
-
amount:
|
|
48
|
-
quantity:
|
|
49
|
-
freeText:
|
|
50
|
-
showPrice:
|
|
51
|
-
contactName:
|
|
52
|
-
contactEmail:
|
|
53
|
-
contactPhone:
|
|
54
|
-
imageBase64:
|
|
55
|
-
imageName:
|
|
56
|
-
imageFormat:
|
|
57
|
-
placeType:
|
|
58
|
-
placeID:
|
|
43
|
+
language: ce(),
|
|
44
|
+
amount: n.value,
|
|
45
|
+
quantity: v.value,
|
|
46
|
+
freeText: L.value,
|
|
47
|
+
showPrice: p.value,
|
|
48
|
+
contactName: h.value,
|
|
49
|
+
contactEmail: d.value,
|
|
50
|
+
contactPhone: f.value,
|
|
51
|
+
imageBase64: pe(y.value.base64),
|
|
52
|
+
imageName: y.value.name,
|
|
53
|
+
imageFormat: y.value.type,
|
|
54
|
+
placeType: E.value ? E.value.placeType : void 0,
|
|
55
|
+
placeID: E.value ? E.value.id : void 0
|
|
59
56
|
}, {
|
|
60
57
|
headers: {
|
|
61
|
-
Authorization:
|
|
58
|
+
Authorization: m.value,
|
|
62
59
|
Accept: "application/json",
|
|
63
|
-
"Fresh-Booking-Ver": "4.0.56-
|
|
60
|
+
"Fresh-Booking-Ver": "4.0.56-rc21"
|
|
64
61
|
}
|
|
65
62
|
}).then((a) => {
|
|
66
|
-
|
|
63
|
+
r.value = $.ReadyToPay, b.value = !1, S({
|
|
67
64
|
callback: () => console.log("Callback!"),
|
|
68
65
|
response: a.data
|
|
69
66
|
});
|
|
70
67
|
});
|
|
71
68
|
}
|
|
72
|
-
function
|
|
73
|
-
a && (
|
|
69
|
+
function R(a) {
|
|
70
|
+
a && (U.value = a);
|
|
74
71
|
}
|
|
75
72
|
return {
|
|
76
|
-
selectedPlace:
|
|
77
|
-
moduleState:
|
|
78
|
-
name:
|
|
79
|
-
email:
|
|
80
|
-
phone:
|
|
81
|
-
value:
|
|
82
|
-
remark:
|
|
83
|
-
showValue:
|
|
84
|
-
quantity:
|
|
85
|
-
media:
|
|
73
|
+
selectedPlace: E,
|
|
74
|
+
moduleState: r,
|
|
75
|
+
name: h,
|
|
76
|
+
email: d,
|
|
77
|
+
phone: f,
|
|
78
|
+
value: n,
|
|
79
|
+
remark: L,
|
|
80
|
+
showValue: p,
|
|
81
|
+
quantity: v,
|
|
82
|
+
media: y,
|
|
86
83
|
placeId: l,
|
|
87
|
-
placeType:
|
|
88
|
-
showFormPage:
|
|
89
|
-
showPaymentPage:
|
|
90
|
-
showConfirmationPage:
|
|
91
|
-
places:
|
|
92
|
-
hasFilledForm:
|
|
93
|
-
hasForcedPlaceType:
|
|
84
|
+
placeType: u,
|
|
85
|
+
showFormPage: F,
|
|
86
|
+
showPaymentPage: A,
|
|
87
|
+
showConfirmationPage: q,
|
|
88
|
+
places: P,
|
|
89
|
+
hasFilledForm: x,
|
|
90
|
+
hasForcedPlaceType: H,
|
|
94
91
|
isWaitingForResponse: K,
|
|
95
|
-
isMetaDataAvailable:
|
|
96
|
-
orderGiftCard:
|
|
97
|
-
initialize:
|
|
92
|
+
isMetaDataAvailable: N,
|
|
93
|
+
orderGiftCard: Y,
|
|
94
|
+
initialize: R
|
|
98
95
|
};
|
|
99
|
-
}), Le = { class: "media-selector" },
|
|
96
|
+
}), Le = { class: "media-selector" }, qe = ["accept"], Me = { class: "media-selector-wrapper" }, Ge = { class: "media-selector-tools" }, Be = { key: 0 }, xe = { key: 1 }, ze = { key: 2 }, De = ["src"], We = /* @__PURE__ */ X({
|
|
100
97
|
__name: "MediaSelector",
|
|
101
98
|
props: {
|
|
102
99
|
modelValue: {},
|
|
@@ -106,94 +103,94 @@ const oe = be("giftCard", () => {
|
|
|
106
103
|
required: { type: Boolean, default: !1 }
|
|
107
104
|
},
|
|
108
105
|
emits: ["update:modelValue"],
|
|
109
|
-
setup(
|
|
110
|
-
const
|
|
111
|
-
function
|
|
112
|
-
|
|
106
|
+
setup(S, { emit: m }) {
|
|
107
|
+
const w = m, o = S, { t: r } = ne(), { display: h } = me(), d = C(), f = _(() => o.modelValue.base64 !== "");
|
|
108
|
+
function n(l) {
|
|
109
|
+
w("update:modelValue", l);
|
|
113
110
|
}
|
|
114
|
-
function
|
|
115
|
-
|
|
111
|
+
function v() {
|
|
112
|
+
n({
|
|
116
113
|
base64: "",
|
|
117
114
|
name: "",
|
|
118
115
|
type: ""
|
|
119
|
-
}),
|
|
116
|
+
}), d.value && (d.value.value = "");
|
|
120
117
|
}
|
|
121
|
-
function
|
|
122
|
-
|
|
118
|
+
function p() {
|
|
119
|
+
d.value && d.value.click();
|
|
123
120
|
}
|
|
124
|
-
function
|
|
125
|
-
const [
|
|
126
|
-
|
|
127
|
-
if (
|
|
128
|
-
const
|
|
129
|
-
|
|
121
|
+
function L(l, u) {
|
|
122
|
+
const [b, U] = [l.name, l.type], F = new FileReader();
|
|
123
|
+
F.onload = function(A) {
|
|
124
|
+
if (A.target) {
|
|
125
|
+
const q = A.target.result;
|
|
126
|
+
u({ base64: q, name: b, type: U });
|
|
130
127
|
} else
|
|
131
|
-
|
|
132
|
-
message:
|
|
128
|
+
h({
|
|
129
|
+
message: r("imageUploadError"),
|
|
133
130
|
type: "error"
|
|
134
131
|
});
|
|
135
|
-
},
|
|
132
|
+
}, F.readAsDataURL(l);
|
|
136
133
|
}
|
|
137
|
-
async function
|
|
134
|
+
async function y() {
|
|
138
135
|
let l;
|
|
139
|
-
(l =
|
|
136
|
+
(l = d.value.files) instanceof FileList && L(l[0], n);
|
|
140
137
|
}
|
|
141
|
-
return (l,
|
|
138
|
+
return (l, u) => (c(), I(fe, {
|
|
142
139
|
label: l.label,
|
|
143
140
|
required: l.required,
|
|
144
141
|
type: "media"
|
|
145
142
|
}, {
|
|
146
|
-
default:
|
|
147
|
-
|
|
148
|
-
|
|
143
|
+
default: G(() => [
|
|
144
|
+
s("div", Le, [
|
|
145
|
+
s("input", {
|
|
149
146
|
ref_key: "fileInput",
|
|
150
|
-
ref:
|
|
147
|
+
ref: d,
|
|
151
148
|
type: "file",
|
|
152
149
|
class: "hidden",
|
|
153
150
|
accept: l.validation,
|
|
154
151
|
single: "",
|
|
155
|
-
onChange:
|
|
156
|
-
}, null, 40,
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
i(
|
|
161
|
-
label: e(
|
|
152
|
+
onChange: u[0] || (u[0] = (b) => y())
|
|
153
|
+
}, null, 40, qe),
|
|
154
|
+
s("div", Me, [
|
|
155
|
+
s("ul", Ge, [
|
|
156
|
+
f.value ? V("", !0) : (c(), g("li", Be, [
|
|
157
|
+
i(B, {
|
|
158
|
+
label: e(r)("uploadFile"),
|
|
162
159
|
type: "button",
|
|
163
160
|
icon: "upload",
|
|
164
161
|
"icon-color": l.iconColor,
|
|
165
|
-
onClickEvent:
|
|
162
|
+
onClickEvent: u[1] || (u[1] = (b) => p())
|
|
166
163
|
}, null, 8, ["label", "icon-color"])
|
|
167
164
|
])),
|
|
168
|
-
|
|
169
|
-
i(
|
|
170
|
-
label: e(
|
|
165
|
+
f.value ? (c(), g("li", xe, [
|
|
166
|
+
i(B, {
|
|
167
|
+
label: e(r)("replaceFile"),
|
|
171
168
|
type: "button",
|
|
172
169
|
icon: "repeat-alt",
|
|
173
170
|
"icon-color": l.iconColor,
|
|
174
|
-
onClickEvent:
|
|
171
|
+
onClickEvent: u[2] || (u[2] = (b) => p())
|
|
175
172
|
}, null, 8, ["label", "icon-color"])
|
|
176
|
-
])) :
|
|
177
|
-
|
|
178
|
-
i(
|
|
179
|
-
label: e(
|
|
173
|
+
])) : V("", !0),
|
|
174
|
+
f.value ? (c(), g("li", ze, [
|
|
175
|
+
i(B, {
|
|
176
|
+
label: e(r)("removeFile"),
|
|
180
177
|
type: "button",
|
|
181
178
|
icon: "trash-alt",
|
|
182
179
|
"icon-color": l.iconColor,
|
|
183
|
-
onClickEvent:
|
|
180
|
+
onClickEvent: u[3] || (u[3] = (b) => v())
|
|
184
181
|
}, null, 8, ["label", "icon-color"])
|
|
185
|
-
])) :
|
|
182
|
+
])) : V("", !0)
|
|
186
183
|
]),
|
|
187
|
-
|
|
188
|
-
class:
|
|
184
|
+
s("div", {
|
|
185
|
+
class: ie([
|
|
189
186
|
"media-selector-previewer",
|
|
190
|
-
{ opened:
|
|
187
|
+
{ opened: f.value }
|
|
191
188
|
])
|
|
192
189
|
}, [
|
|
193
|
-
l.modelValue ? (
|
|
190
|
+
l.modelValue ? (c(), g("img", {
|
|
194
191
|
key: 0,
|
|
195
192
|
src: l.modelValue.base64
|
|
196
|
-
}, null, 8,
|
|
193
|
+
}, null, 8, De)) : V("", !0)
|
|
197
194
|
], 2)
|
|
198
195
|
])
|
|
199
196
|
])
|
|
@@ -202,9 +199,9 @@ const oe = be("giftCard", () => {
|
|
|
202
199
|
}, 8, ["label", "required"]));
|
|
203
200
|
}
|
|
204
201
|
});
|
|
205
|
-
function
|
|
206
|
-
const
|
|
207
|
-
|
|
202
|
+
function te(S) {
|
|
203
|
+
const m = S;
|
|
204
|
+
m.__i18n = m.__i18n || [], m.__i18n.push({
|
|
208
205
|
locale: "",
|
|
209
206
|
resource: {
|
|
210
207
|
da: {
|
|
@@ -222,39 +219,39 @@ function ie(h) {
|
|
|
222
219
|
}
|
|
223
220
|
});
|
|
224
221
|
}
|
|
225
|
-
typeof
|
|
226
|
-
const je = { class: "gift-card-skeleton" },
|
|
222
|
+
typeof te == "function" && te(We);
|
|
223
|
+
const je = { class: "gift-card-skeleton" }, Oe = { class: "gift-card-skeleton-form" }, He = /* @__PURE__ */ X({
|
|
227
224
|
__name: "GiftCardSkeleton",
|
|
228
|
-
setup(
|
|
229
|
-
return (
|
|
230
|
-
|
|
231
|
-
i(
|
|
232
|
-
i(
|
|
233
|
-
i(
|
|
234
|
-
i(
|
|
235
|
-
i(
|
|
236
|
-
i(
|
|
225
|
+
setup(S) {
|
|
226
|
+
return (m, w) => (c(), g("div", je, [
|
|
227
|
+
s("div", Oe, [
|
|
228
|
+
i(M),
|
|
229
|
+
i(M),
|
|
230
|
+
i(M),
|
|
231
|
+
i(M),
|
|
232
|
+
i(M, { "is-text-area": "" }),
|
|
233
|
+
i(ve, { height: "44px" })
|
|
237
234
|
])
|
|
238
235
|
]));
|
|
239
236
|
}
|
|
240
|
-
}),
|
|
237
|
+
}), Ne = /* @__PURE__ */ se(He, [["__scopeId", "data-v-ba3efaa1"]]), Ke = {
|
|
241
238
|
key: 0,
|
|
242
239
|
id: "konnectio-gift-card-wrapper"
|
|
243
|
-
},
|
|
240
|
+
}, Ye = { id: "konnectio-gift-card-title" }, Ze = { id: "konnectio-gift-card-content" }, Je = { id: "konnectio-gift-card-payment" }, Qe = ["innerHTML"], Xe = { key: 0 }, ea = {
|
|
244
241
|
key: 0,
|
|
245
242
|
id: "fresh-booking-select-place-type"
|
|
246
243
|
}, aa = {
|
|
247
|
-
class: /* @__PURE__ */
|
|
244
|
+
class: /* @__PURE__ */ ie(["fresh-booking-label", "required"])
|
|
248
245
|
}, la = { id: "fresh-booking-select-place-type-input" }, ta = ["innerHTML"], oa = {
|
|
249
246
|
key: 0,
|
|
250
247
|
id: "konnectio-gift-card-order"
|
|
251
|
-
},
|
|
248
|
+
}, na = { class: "fresh-booking-panel" }, ia = {
|
|
252
249
|
key: 1,
|
|
253
250
|
id: "konnectio-gift-card-remarks"
|
|
254
|
-
},
|
|
251
|
+
}, sa = {
|
|
255
252
|
key: 2,
|
|
256
253
|
id: "konnectio-gift-card-order-minimal"
|
|
257
|
-
},
|
|
254
|
+
}, ra = { id: "konnectio-gift-card-recaptcha" }, da = /* @__PURE__ */ X({
|
|
258
255
|
name: "GiftCardLayout",
|
|
259
256
|
__name: "GiftCard",
|
|
260
257
|
props: {
|
|
@@ -263,96 +260,100 @@ const je = { class: "gift-card-skeleton" }, He = { class: "gift-card-skeleton-fo
|
|
|
263
260
|
placeType: {},
|
|
264
261
|
styling: {}
|
|
265
262
|
},
|
|
266
|
-
setup(
|
|
267
|
-
const
|
|
263
|
+
setup(S) {
|
|
264
|
+
const m = S, w = _(() => ({
|
|
268
265
|
panelMaxWidth: "800px",
|
|
269
|
-
...
|
|
270
|
-
})), { t: o } =
|
|
271
|
-
name:
|
|
272
|
-
email:
|
|
273
|
-
phone:
|
|
274
|
-
value:
|
|
275
|
-
remark:
|
|
276
|
-
showValue:
|
|
277
|
-
quantity:
|
|
278
|
-
media:
|
|
279
|
-
placeId:
|
|
266
|
+
...m.styling
|
|
267
|
+
})), { t: o } = ne(), {
|
|
268
|
+
name: r,
|
|
269
|
+
email: h,
|
|
270
|
+
phone: d,
|
|
271
|
+
value: f,
|
|
272
|
+
remark: n,
|
|
273
|
+
showValue: v,
|
|
274
|
+
quantity: p,
|
|
275
|
+
media: L,
|
|
276
|
+
placeId: y,
|
|
280
277
|
placeType: l,
|
|
281
|
-
showFormPage:
|
|
282
|
-
showPaymentPage:
|
|
283
|
-
showConfirmationPage:
|
|
284
|
-
places:
|
|
285
|
-
hasFilledForm:
|
|
286
|
-
hasForcedPlaceType:
|
|
287
|
-
isWaitingForResponse:
|
|
288
|
-
isMetaDataAvailable:
|
|
289
|
-
} = Q(
|
|
290
|
-
return
|
|
291
|
-
|
|
292
|
-
}),
|
|
293
|
-
const
|
|
294
|
-
|
|
295
|
-
}), (
|
|
296
|
-
default:
|
|
297
|
-
(
|
|
298
|
-
default:
|
|
299
|
-
i(
|
|
278
|
+
showFormPage: u,
|
|
279
|
+
showPaymentPage: b,
|
|
280
|
+
showConfirmationPage: U,
|
|
281
|
+
places: F,
|
|
282
|
+
hasFilledForm: A,
|
|
283
|
+
hasForcedPlaceType: q,
|
|
284
|
+
isWaitingForResponse: P,
|
|
285
|
+
isMetaDataAvailable: H
|
|
286
|
+
} = Q(le()), { initialize: E, orderGiftCard: x } = le(), { isRecaptchaEnabled: N, currency: K, hasError: Y } = Q(oe());
|
|
287
|
+
return ge(l, () => {
|
|
288
|
+
y.value = void 0;
|
|
289
|
+
}), he(() => {
|
|
290
|
+
const R = m.placeType ? parseInt(m.placeType) : void 0;
|
|
291
|
+
E(R);
|
|
292
|
+
}), (R, a) => (c(), I(Fe, { styling: w.value }, {
|
|
293
|
+
default: G(() => [
|
|
294
|
+
(c(), I(be, null, {
|
|
295
|
+
default: G(() => [
|
|
296
|
+
i(we, {
|
|
300
297
|
id: "konnectio-gift-card-module",
|
|
301
298
|
type: "gift-card",
|
|
302
|
-
"access-token":
|
|
303
|
-
"data-layout":
|
|
299
|
+
"access-token": R.accessToken,
|
|
300
|
+
"data-layout": R.layout
|
|
304
301
|
}, {
|
|
305
|
-
default:
|
|
306
|
-
e(
|
|
307
|
-
|
|
308
|
-
|
|
302
|
+
default: G(() => [
|
|
303
|
+
e(Y) ? (c(), I(Ie, {
|
|
304
|
+
key: 1,
|
|
305
|
+
title: "Unable to render Gift card module",
|
|
306
|
+
description: "Gift card functionality hasn't been setup for this account. Please contact Octopus PMS for support."
|
|
307
|
+
})) : (c(), g("div", Ke, [
|
|
308
|
+
s("h2", Ye, [
|
|
309
|
+
s("span", null, ae(e(o)("giftCard.title")), 1)
|
|
309
310
|
]),
|
|
310
|
-
|
|
311
|
-
|
|
311
|
+
s("div", Ze, [
|
|
312
|
+
D(s("div", Je, [
|
|
312
313
|
i(Ee)
|
|
313
314
|
], 512), [
|
|
314
|
-
[
|
|
315
|
+
[W, e(b)]
|
|
315
316
|
]),
|
|
316
|
-
|
|
317
|
-
|
|
317
|
+
D(s("div", null, [
|
|
318
|
+
s("p", {
|
|
318
319
|
id: "konnectio-gift-card-description",
|
|
319
320
|
innerHTML: e(o)("giftCard.description")
|
|
320
|
-
}, null, 8,
|
|
321
|
-
|
|
322
|
-
e(
|
|
323
|
-
e(
|
|
324
|
-
|
|
325
|
-
|
|
321
|
+
}, null, 8, Qe),
|
|
322
|
+
s("form", null, [
|
|
323
|
+
e(q) ? V("", !0) : (c(), g("div", Xe, [
|
|
324
|
+
e(F) ? (c(), g("div", ea, [
|
|
325
|
+
s("label", aa, [
|
|
326
|
+
s("span", null, ae(e(o)("giftCard.selectType")), 1)
|
|
326
327
|
]),
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
(
|
|
330
|
-
i(
|
|
328
|
+
s("div", la, [
|
|
329
|
+
s("ul", null, [
|
|
330
|
+
(c(!0), g(ye, null, ke(e(F), (t, k) => (c(), g("li", { key: k }, [
|
|
331
|
+
i(Ue, {
|
|
331
332
|
modelValue: e(l),
|
|
332
|
-
"onUpdate:modelValue":
|
|
333
|
+
"onUpdate:modelValue": a[0] || (a[0] = (z) => T(l) ? l.value = z : null),
|
|
333
334
|
type: "radio",
|
|
334
335
|
name: "placeType",
|
|
335
|
-
val:
|
|
336
|
-
label:
|
|
336
|
+
val: k,
|
|
337
|
+
label: t.label
|
|
337
338
|
}, null, 8, ["modelValue", "val", "label"])
|
|
338
339
|
]))), 128))
|
|
339
340
|
]),
|
|
340
|
-
e(
|
|
341
|
+
e(F)[e(l)] && e(F)[e(l)].data.length > 1 ? (c(), I(Ce, {
|
|
341
342
|
key: 0,
|
|
342
|
-
modelValue: e(
|
|
343
|
-
"onUpdate:modelValue":
|
|
343
|
+
modelValue: e(y),
|
|
344
|
+
"onUpdate:modelValue": a[1] || (a[1] = (t) => T(y) ? y.value = t : null),
|
|
344
345
|
placeholder: e(o)("giftCard.selectPlacePlaceholder"),
|
|
345
|
-
options: e(
|
|
346
|
+
options: e(F)[e(l)].data,
|
|
346
347
|
labelKey: "name",
|
|
347
348
|
valueKey: "id",
|
|
348
349
|
required: ""
|
|
349
|
-
}, null, 8, ["modelValue", "placeholder", "options"])) :
|
|
350
|
+
}, null, 8, ["modelValue", "placeholder", "options"])) : V("", !0)
|
|
350
351
|
])
|
|
351
|
-
])) : (
|
|
352
|
+
])) : (c(), I(_e, { key: 1 }))
|
|
352
353
|
])),
|
|
353
|
-
i(
|
|
354
|
-
modelValue: e(
|
|
355
|
-
"onUpdate:modelValue":
|
|
354
|
+
i(j, {
|
|
355
|
+
modelValue: e(r),
|
|
356
|
+
"onUpdate:modelValue": a[2] || (a[2] = (t) => T(r) ? r.value = t : null),
|
|
356
357
|
type: "text",
|
|
357
358
|
name: "name",
|
|
358
359
|
autocomplete: "name",
|
|
@@ -361,9 +362,9 @@ const je = { class: "gift-card-skeleton" }, He = { class: "gift-card-skeleton-fo
|
|
|
361
362
|
placeholder: e(o)("giftCard.namePlaceholder"),
|
|
362
363
|
required: ""
|
|
363
364
|
}, null, 8, ["modelValue", "label", "placeholder"]),
|
|
364
|
-
i(
|
|
365
|
-
modelValue: e(
|
|
366
|
-
"onUpdate:modelValue":
|
|
365
|
+
i(j, {
|
|
366
|
+
modelValue: e(h),
|
|
367
|
+
"onUpdate:modelValue": a[3] || (a[3] = (t) => T(h) ? h.value = t : null),
|
|
367
368
|
type: "email",
|
|
368
369
|
name: "email",
|
|
369
370
|
autocomplete: "email",
|
|
@@ -372,17 +373,17 @@ const je = { class: "gift-card-skeleton" }, He = { class: "gift-card-skeleton-fo
|
|
|
372
373
|
placeholder: e(o)("giftCard.emailPlaceholder"),
|
|
373
374
|
required: ""
|
|
374
375
|
}, null, 8, ["modelValue", "label", "placeholder"]),
|
|
375
|
-
i(
|
|
376
|
-
modelValue: e(
|
|
377
|
-
"onUpdate:modelValue":
|
|
376
|
+
i(Ae, {
|
|
377
|
+
modelValue: e(d),
|
|
378
|
+
"onUpdate:modelValue": a[4] || (a[4] = (t) => T(d) ? d.value = t : null),
|
|
378
379
|
icon: "phone-office",
|
|
379
380
|
label: e(o)("giftCard.phone"),
|
|
380
381
|
placeholder: e(o)("giftCard.phonePlaceholder"),
|
|
381
382
|
required: ""
|
|
382
383
|
}, null, 8, ["modelValue", "label", "placeholder"]),
|
|
383
|
-
i(
|
|
384
|
-
modelValue: e(
|
|
385
|
-
"onUpdate:modelValue":
|
|
384
|
+
i(j, {
|
|
385
|
+
modelValue: e(f),
|
|
386
|
+
"onUpdate:modelValue": a[5] || (a[5] = (t) => T(f) ? f.value = t : null),
|
|
386
387
|
type: "number",
|
|
387
388
|
name: "value",
|
|
388
389
|
label: e(o)("giftCard.value"),
|
|
@@ -391,80 +392,73 @@ const je = { class: "gift-card-skeleton" }, He = { class: "gift-card-skeleton-fo
|
|
|
391
392
|
suffix: e(K),
|
|
392
393
|
required: ""
|
|
393
394
|
}, null, 8, ["modelValue", "label", "placeholder", "suffix"]),
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
label: e(o)("giftCard.showValue"),
|
|
400
|
-
checked: e(w)
|
|
401
|
-
}, null, 8, ["modelValue", "label", "checked"]),
|
|
402
|
-
F("", !0),
|
|
403
|
-
i(we, {
|
|
404
|
-
modelValue: e(T),
|
|
405
|
-
"onUpdate:modelValue": t[8] || (t[8] = (a) => g(T) ? T.value = a : null),
|
|
395
|
+
V("", !0),
|
|
396
|
+
V("", !0),
|
|
397
|
+
i(Ve, {
|
|
398
|
+
modelValue: e(p),
|
|
399
|
+
"onUpdate:modelValue": a[8] || (a[8] = (t) => T(p) ? p.value = t : null),
|
|
406
400
|
label: e(o)("giftCard.quantity"),
|
|
407
401
|
icon: "gift-card",
|
|
408
402
|
required: ""
|
|
409
403
|
}, null, 8, ["modelValue", "label"])
|
|
410
404
|
])
|
|
411
405
|
], 512), [
|
|
412
|
-
[
|
|
406
|
+
[W, e(u)]
|
|
413
407
|
]),
|
|
414
|
-
|
|
415
|
-
|
|
408
|
+
D(s("div", null, [
|
|
409
|
+
s("div", {
|
|
416
410
|
innerHTML: e(o)("giftCard.thankYou")
|
|
417
411
|
}, null, 8, ta)
|
|
418
412
|
], 512), [
|
|
419
|
-
[
|
|
413
|
+
[W, e(U)]
|
|
420
414
|
])
|
|
421
415
|
]),
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
i(
|
|
416
|
+
R.layout !== "minimal" && e(u) ? (c(), g("div", oa, [
|
|
417
|
+
s("div", na, [
|
|
418
|
+
i(B, {
|
|
425
419
|
label: e(o)("giftCard.orderGiftCard"),
|
|
426
420
|
"full-width": !0,
|
|
427
|
-
disabled: !e(
|
|
428
|
-
"is-loading": e(
|
|
429
|
-
"onUpdate:isLoading":
|
|
430
|
-
onClickEvent: e(
|
|
421
|
+
disabled: !e(A),
|
|
422
|
+
"is-loading": e(P),
|
|
423
|
+
"onUpdate:isLoading": a[9] || (a[9] = (t) => T(P) ? P.value = t : null),
|
|
424
|
+
onClickEvent: e(x)
|
|
431
425
|
}, null, 8, ["label", "disabled", "is-loading", "onClickEvent"])
|
|
432
426
|
])
|
|
433
|
-
])) :
|
|
434
|
-
e(
|
|
435
|
-
i(
|
|
436
|
-
modelValue: e(
|
|
437
|
-
"onUpdate:modelValue":
|
|
427
|
+
])) : V("", !0),
|
|
428
|
+
e(u) ? (c(), g("div", ia, [
|
|
429
|
+
i(j, {
|
|
430
|
+
modelValue: e(n),
|
|
431
|
+
"onUpdate:modelValue": a[10] || (a[10] = (t) => T(n) ? n.value = t : null),
|
|
438
432
|
type: "textarea",
|
|
439
433
|
name: "remark",
|
|
440
434
|
label: e(o)("giftCard.remark"),
|
|
441
435
|
icon: "info-circle",
|
|
442
436
|
placeholder: e(o)("giftCard.remarkPlaceholder")
|
|
443
437
|
}, null, 8, ["modelValue", "label", "placeholder"])
|
|
444
|
-
])) :
|
|
445
|
-
e(
|
|
446
|
-
i(
|
|
438
|
+
])) : V("", !0),
|
|
439
|
+
e(u) ? (c(), g("div", sa, [
|
|
440
|
+
i(B, {
|
|
447
441
|
label: e(o)("giftCard.orderGiftCard"),
|
|
448
442
|
"full-width": !0,
|
|
449
|
-
disabled: !e(
|
|
443
|
+
disabled: !e(A),
|
|
450
444
|
"data-test": "orderGiftCard",
|
|
451
|
-
"is-loading": e(
|
|
452
|
-
"onUpdate:isLoading":
|
|
453
|
-
onClickEvent: e(
|
|
445
|
+
"is-loading": e(P),
|
|
446
|
+
"onUpdate:isLoading": a[11] || (a[11] = (t) => T(P) ? P.value = t : null),
|
|
447
|
+
onClickEvent: e(x)
|
|
454
448
|
}, null, 8, ["label", "disabled", "is-loading", "onClickEvent"]),
|
|
455
|
-
|
|
456
|
-
i(
|
|
449
|
+
D(s("div", ra, [
|
|
450
|
+
i(Re)
|
|
457
451
|
], 512), [
|
|
458
|
-
[
|
|
452
|
+
[W, e(N)]
|
|
459
453
|
])
|
|
460
|
-
])) :
|
|
461
|
-
]))
|
|
454
|
+
])) : V("", !0)
|
|
455
|
+
]))
|
|
462
456
|
]),
|
|
463
457
|
_: 1
|
|
464
458
|
}, 8, ["access-token", "data-layout"])
|
|
465
459
|
]),
|
|
466
|
-
fallback:
|
|
467
|
-
i(
|
|
460
|
+
fallback: G(() => [
|
|
461
|
+
i(Ne)
|
|
468
462
|
]),
|
|
469
463
|
_: 1
|
|
470
464
|
}))
|
|
@@ -472,16 +466,35 @@ const je = { class: "gift-card-skeleton" }, He = { class: "gift-card-skeleton-fo
|
|
|
472
466
|
_: 1
|
|
473
467
|
}, 8, ["styling"]));
|
|
474
468
|
}
|
|
475
|
-
}),
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
const ya = {
|
|
481
|
-
install: (h) => {
|
|
482
|
-
h.component("GiftCard", ue);
|
|
469
|
+
}), O = /* @__PURE__ */ se(da, [["__scopeId", "data-v-3a6862b8"]]), ua = Pe();
|
|
470
|
+
class ca extends HTMLElement {
|
|
471
|
+
vueApp;
|
|
472
|
+
constructor() {
|
|
473
|
+
super();
|
|
483
474
|
}
|
|
484
|
-
|
|
475
|
+
disconnectedCallback() {
|
|
476
|
+
this.vueApp.unmount();
|
|
477
|
+
}
|
|
478
|
+
connectedCallback() {
|
|
479
|
+
const m = typeof O == "function" ? O.options : O;
|
|
480
|
+
let w = Array.isArray(m.props) ? m.props : Object.keys(m.props || {});
|
|
481
|
+
const o = (n) => n.replace(/[A-Z]+(?![a-z])|[A-Z]/g, (v, p) => (p ? "-" : "") + v.toLowerCase()), r = (n) => n.replace(/-./g, (v) => v[1].toUpperCase()), h = {};
|
|
482
|
+
w = w.map(o);
|
|
483
|
+
const d = {};
|
|
484
|
+
for (const n of this.attributes) {
|
|
485
|
+
const p = n.name.split(".");
|
|
486
|
+
p.length > 1 && (d[p[0]] || (d[p[0]] = {}), d[p[0]][r(p[1])] = n.value);
|
|
487
|
+
}
|
|
488
|
+
for (const n of w) {
|
|
489
|
+
let v = this.attributes.getNamedItem(n)?.value;
|
|
490
|
+
d.hasOwnProperty(n) && (v = d[n]), h[n] = v;
|
|
491
|
+
}
|
|
492
|
+
this.vueApp = Te(O, h), this.vueApp.use(ua), this.vueApp.use(Se), this.vueApp.use($e, { bootstrap: !0 });
|
|
493
|
+
const f = document.createElement("div");
|
|
494
|
+
this.vueApp.mount(f), this.appendChild(f.children[0]);
|
|
495
|
+
}
|
|
496
|
+
}
|
|
497
|
+
window.customElements.define("konnectio-gift-card", ca);
|
|
485
498
|
export {
|
|
486
|
-
|
|
499
|
+
ca as default
|
|
487
500
|
};
|