@konnectio/core 4.0.0
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/README.md +274 -0
- package/package.json +99 -0
- package/target/assets/ActionField-b0b40c88.js +2 -0
- package/target/assets/ActionField-b0b40c88.js.br +0 -0
- package/target/assets/AvailabilityForm-13918dfc.js +2 -0
- package/target/assets/AvailabilityForm-13918dfc.js.br +0 -0
- package/target/assets/Checkbox-0b398a1a.js +2 -0
- package/target/assets/Checkbox-0b398a1a.js.br +0 -0
- package/target/assets/Clickable-803d7e0c.js +2 -0
- package/target/assets/Clickable-803d7e0c.js.br +0 -0
- package/target/assets/DateField.vue_vue_type_style_index_0_lang-f5878599.js +2 -0
- package/target/assets/DateField.vue_vue_type_style_index_0_lang-f5878599.js.br +0 -0
- package/target/assets/GoogleNotice-950f8f64.js +2 -0
- package/target/assets/GoogleNotice-950f8f64.js.br +0 -0
- package/target/assets/NumberField.vue_vue_type_script_setup_true_lang-3c220f4d.js +2 -0
- package/target/assets/NumberField.vue_vue_type_script_setup_true_lang-3c220f4d.js.br +0 -0
- package/target/assets/NumberField.vue_vue_type_style_index_0_lang-8bcb59b1.js +2 -0
- package/target/assets/NumberField.vue_vue_type_style_index_0_lang-8bcb59b1.js.br +0 -0
- package/target/assets/SelectField.vue_vue_type_style_index_0_lang-d1aa221e.js +2 -0
- package/target/assets/SelectField.vue_vue_type_style_index_0_lang-d1aa221e.js.br +0 -0
- package/target/assets/ThankYou-670c2cca.js +5 -0
- package/target/assets/ThankYou-670c2cca.js.br +0 -0
- package/target/assets/TimeField.vue_vue_type_style_index_0_lang-8f7003f1.js +2 -0
- package/target/assets/TimeField.vue_vue_type_style_index_0_lang-8f7003f1.js.br +0 -0
- package/target/assets/admin-708f5aa9.js +2 -0
- package/target/assets/admin-708f5aa9.js.br +0 -0
- package/target/assets/applyGiftCard-dff85e53.js +2 -0
- package/target/assets/applyGiftCard-dff85e53.js.br +0 -0
- package/target/assets/availability-72ce6097.js +2 -0
- package/target/assets/availability-a20d4ba0.js +2 -0
- package/target/assets/availability-a20d4ba0.js.br +0 -0
- package/target/assets/event-5d483aec.js +2 -0
- package/target/assets/event-5d483aec.js.br +0 -0
- package/target/assets/gift-card-a840a7f0.js +2 -0
- package/target/assets/gift-card-a840a7f0.js.br +0 -0
- package/target/assets/gift-card-validation-385d06bd.js +2 -0
- package/target/assets/gift-card-validation-385d06bd.js.br +0 -0
- package/target/assets/giftCard-75628b52.js +2 -0
- package/target/assets/giftCard-75628b52.js.br +0 -0
- package/target/assets/hotel-9386d0a1.js +2 -0
- package/target/assets/hotel-9386d0a1.js.br +0 -0
- package/target/assets/navigation-bce4c537.js +2 -0
- package/target/assets/navigation-bce4c537.js.br +0 -0
- package/target/assets/polyfill-a64d350a.js +2 -0
- package/target/assets/style.css +1 -0
- package/target/assets/style.css.br +0 -0
- package/target/assets/vendor-7782fc29.js +878 -0
- package/target/assets/vendor-7782fc29.js.br +0 -0
- package/target/manifest.json.br +0 -0
- package/target/vite-dev-server.json +1 -0
package/README.md
ADDED
|
@@ -0,0 +1,274 @@
|
|
|
1
|
+
# FreshBooking integration for Octopus PMS for WordPress
|
|
2
|
+
|
|
3
|
+
<p align="center">
|
|
4
|
+
<a href="https://vuejs.org/"><img src="https://img.shields.io/badge/vue-3-brightgreen.svg"/></a>
|
|
5
|
+
</p>
|
|
6
|
+
|
|
7
|
+
## Features
|
|
8
|
+
|
|
9
|
+
- Three feature-rich shortcode modules:
|
|
10
|
+
- Hotel availability 'call-to-action'
|
|
11
|
+
- Hotel module (with support for ReePay & Dibs)
|
|
12
|
+
- Gift card module (with support for ReePay & Dibs)
|
|
13
|
+
- Gift card validation
|
|
14
|
+
- Event module
|
|
15
|
+
- The look of the modules will adapt to the existing design of the website.
|
|
16
|
+
- Multiple languages supported:
|
|
17
|
+
- Works with popular multi-language plugins such as WPML and Polylang.
|
|
18
|
+
- Language strings can be modified through an easy to use interface.
|
|
19
|
+
- Comes prepackaged with Danish and English.
|
|
20
|
+
- Various customization options.
|
|
21
|
+
- Continuous updates. See [CHANGELOG.md](CHANGELOG.md).
|
|
22
|
+
|
|
23
|
+
## Getting started
|
|
24
|
+
|
|
25
|
+
### Installation
|
|
26
|
+
Simply upload and install `FreshBooking for Octopus PMS` in the same way you'd install any other plugin.
|
|
27
|
+
|
|
28
|
+
During the installation of the plugin two database tables are created. One for containing custom translation strings (which currently comes prepackaged with translations for Danish and English) and another for storing FreshBooking credentials.
|
|
29
|
+
|
|
30
|
+
### License activation
|
|
31
|
+
After the installation of the FreshBooking WordPress plugin it is necessary to activate the FreshBooking license. This is done by navigating to the 'FreshBooking' page in the sidebar menu within the WordPress administration panel. From there you click the tab labeled 'License'. Here you just fill out your Octopus PMS login credentials, and then click 'Generate License'. This will generate the FreshBooking token required to use the plugin.
|
|
32
|
+
|
|
33
|
+

|
|
34
|
+
|
|
35
|
+
After successfully generating the FreshBooking token, you will be able to begin setting up plugin provided shortcodes that constitute the main functionality.
|
|
36
|
+
|
|
37
|
+
## Usage
|
|
38
|
+
The FreshBooking WordPress plugin currently contains three shortcodes that require manual placement on a given page.
|
|
39
|
+
|
|
40
|
+
The shortcodes can be inserted without further configuration.
|
|
41
|
+
|
|
42
|
+
Common for all shortcodes is that they inject small [Vue.js](https://vuejs.org/) applications that work isolated from the rest of the Wordpress website.
|
|
43
|
+
|
|
44
|
+
The most optimal way to insert them are on pages with a _"full width"_ layout with about a 15-25 pixel margin in the sides.
|
|
45
|
+
|
|
46
|
+
### 'Availability' shortcode
|
|
47
|
+
|
|
48
|
+
The availability shortcode would most likely be inserted on the front page, and used as a _call to action_ to direct guests to _hotel_ module where the actual booking process happens.
|
|
49
|
+
|
|
50
|
+
The availability shortcode can be inserted anywhere on the wordpress site using the following name:
|
|
51
|
+
|
|
52
|
+
```
|
|
53
|
+
[fresh-booking-availability]
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
You can add custom properties to the availability shortcode like so:
|
|
57
|
+
|
|
58
|
+
```
|
|
59
|
+
[fresh-booking-availability panel-padding="24px"]
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
The availability shortcode supports the following properties (the default property settings are listed in the right side of the arrows):
|
|
63
|
+
|
|
64
|
+
```js
|
|
65
|
+
[
|
|
66
|
+
'accent-color' => '#e7c55e',
|
|
67
|
+
'button-background' => '#e7c55e',
|
|
68
|
+
'button-border' => null,
|
|
69
|
+
'button-border-radius' => '4px',
|
|
70
|
+
'button-color' => '#000000',
|
|
71
|
+
'button-font-family' => 'inherit',
|
|
72
|
+
'button-font-size' => '14px',
|
|
73
|
+
'button-font-weight' => '400',
|
|
74
|
+
'button-text-transform' => 'uppercase',
|
|
75
|
+
'font-color' => '#666',
|
|
76
|
+
'font-family' => 'inherit',
|
|
77
|
+
'font-size' => '18px',
|
|
78
|
+
'header-color' => '#000000',
|
|
79
|
+
'header-font-size' => '42px',
|
|
80
|
+
'input-background' => '#fff',
|
|
81
|
+
'input-border' => '1px solid rgba(0, 0, 0, 0.15)',
|
|
82
|
+
'input-border-radius' => '0px',
|
|
83
|
+
'label-font-weight' => 'bold',
|
|
84
|
+
'label-padding' => '6px',
|
|
85
|
+
'panel-background' => 'rgba(255, 255, 255, 0.8)',
|
|
86
|
+
'panel-border' => null,
|
|
87
|
+
'panel-border-radius' => '8px',
|
|
88
|
+
'panel-padding' => '24px'
|
|
89
|
+
]
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
|
|
93
|
+
### 'Hotel' shortcode
|
|
94
|
+
|
|
95
|
+
The hotel shortcode can be inserted anywhere on the wordpress site using the following name:
|
|
96
|
+
|
|
97
|
+
```
|
|
98
|
+
[fresh-booking-hotel]
|
|
99
|
+
```
|
|
100
|
+
|
|
101
|
+
The hotel shortcode supports the following properties:
|
|
102
|
+
|
|
103
|
+
```js
|
|
104
|
+
[
|
|
105
|
+
'accent-color' => '#e7c55e',
|
|
106
|
+
'button-background' => '#e7c55e',
|
|
107
|
+
'button-border-radius' => '4px',
|
|
108
|
+
'button-border' => null,
|
|
109
|
+
'button-color' => '#000000',
|
|
110
|
+
'button-font-family' => 'inherit',
|
|
111
|
+
'button-font-size' => '14px',
|
|
112
|
+
'button-font-weight' => '400',
|
|
113
|
+
'button-text-transform' => 'uppercase',
|
|
114
|
+
'danger-color' => '#afa997',
|
|
115
|
+
'font-color' => '#666',
|
|
116
|
+
'font-family' => 'inherit',
|
|
117
|
+
'font-size' => '18px',
|
|
118
|
+
'gray-color' => 'grey',
|
|
119
|
+
'header-color' => '#000000',
|
|
120
|
+
'header-layout' => 'default',
|
|
121
|
+
'input-background' => '#ffffff',
|
|
122
|
+
'input-border-radius' => '0px',
|
|
123
|
+
'input-border' => '1px solid rgba(0, 0, 0, 0.15)',
|
|
124
|
+
'label-font-weight' => 'bold',
|
|
125
|
+
'label-padding' => '6px',
|
|
126
|
+
'layout' => 'selective',
|
|
127
|
+
'loading-color' => '#666',
|
|
128
|
+
'packages-title-max-lines' => '1',
|
|
129
|
+
'panel-background' => '#ffffff',
|
|
130
|
+
'panel-border-radius' => '8px',
|
|
131
|
+
'panel-border' => null,
|
|
132
|
+
'panel-padding' => '24px',
|
|
133
|
+
'success-color' => '#e7c55e'
|
|
134
|
+
]
|
|
135
|
+
```
|
|
136
|
+
|
|
137
|
+
### 'Gift card' shortcode
|
|
138
|
+
|
|
139
|
+
The gift card shortcode can be inserted anywhere on the wordpress site using the following name:
|
|
140
|
+
|
|
141
|
+
```
|
|
142
|
+
[fresh-booking-gift-card]
|
|
143
|
+
```
|
|
144
|
+
|
|
145
|
+
The gift card shortcode supports the following properties:
|
|
146
|
+
|
|
147
|
+
```js
|
|
148
|
+
[
|
|
149
|
+
'accent-color' => '#e7c55e',
|
|
150
|
+
'button-background' => '#e7c55e',
|
|
151
|
+
'button-border' => null,
|
|
152
|
+
'button-border-radius' => '4px',
|
|
153
|
+
'button-color' => '#000000',
|
|
154
|
+
'button-font-family' => 'inherit',
|
|
155
|
+
'button-font-size' => '14px',
|
|
156
|
+
'button-text-transform' => 'uppercase',
|
|
157
|
+
'button-font-weight' => '400',
|
|
158
|
+
'font-color' => '#666',
|
|
159
|
+
'font-family' => 'inherit',
|
|
160
|
+
'font-size' => '18px',
|
|
161
|
+
'font-weight' => '400',
|
|
162
|
+
'gray-color' => 'grey',
|
|
163
|
+
'header-color' => '#000000',
|
|
164
|
+
'header-font-size' => '32px',
|
|
165
|
+
'input-background' => '#ffffff',
|
|
166
|
+
'input-border' => '1px solid rgba(0, 0, 0, 0.15)',
|
|
167
|
+
'input-border-radius' => '0px',
|
|
168
|
+
'label-font-weight' => 'bold',
|
|
169
|
+
'label-padding' => '6px',
|
|
170
|
+
'loading-color' => '#666',
|
|
171
|
+
'panel-background' => '#ffffff',
|
|
172
|
+
'panel-border' => null,
|
|
173
|
+
'panel-border-radius' => '8px',
|
|
174
|
+
'panel-padding' => '24px',
|
|
175
|
+
'place-type' => '0',
|
|
176
|
+
'success-color' => '#e7c55e'
|
|
177
|
+
]
|
|
178
|
+
```
|
|
179
|
+
|
|
180
|
+
### 'Gift card validation' shortcode
|
|
181
|
+
|
|
182
|
+
The gift card validation shortcode can be inserted anywhere on the wordpress site using the following name:
|
|
183
|
+
|
|
184
|
+
```
|
|
185
|
+
[fresh-booking-gift-card-validation]
|
|
186
|
+
```
|
|
187
|
+
|
|
188
|
+
The gift card validation shortcode supports the following properties:
|
|
189
|
+
|
|
190
|
+
```js
|
|
191
|
+
[
|
|
192
|
+
'accent-color' => '#e7c55e',
|
|
193
|
+
'button-background' => '#e7c55e',
|
|
194
|
+
'button-border' => null,
|
|
195
|
+
'button-border-radius' => '4px',
|
|
196
|
+
'button-color' => '#000000',
|
|
197
|
+
'button-font-family' => 'inherit',
|
|
198
|
+
'button-font-size' => '14px',
|
|
199
|
+
'button-text-transform' => 'uppercase',
|
|
200
|
+
'button-font-weight' => '400',
|
|
201
|
+
'font-color' => '#666',
|
|
202
|
+
'font-family' => 'inherit',
|
|
203
|
+
'font-size' => '18px',
|
|
204
|
+
'font-weight' => '400',
|
|
205
|
+
'gray-color' => 'grey',
|
|
206
|
+
'header-color' => '#000000',
|
|
207
|
+
'header-font-size' => '32px',
|
|
208
|
+
'input-background' => '#ffffff',
|
|
209
|
+
'input-border' => '1px solid rgba(0, 0, 0, 0.15)',
|
|
210
|
+
'input-border-radius' => '0px',
|
|
211
|
+
'label-font-weight' => 'bold',
|
|
212
|
+
'label-padding' => '6px',
|
|
213
|
+
'loading-color' => '#666',
|
|
214
|
+
'panel-background' => '#ffffff',
|
|
215
|
+
'panel-border' => null,
|
|
216
|
+
'panel-border-radius' => '8px',
|
|
217
|
+
'panel-padding' => '24px'
|
|
218
|
+
]
|
|
219
|
+
```
|
|
220
|
+
|
|
221
|
+
### 'Event' shortcode
|
|
222
|
+
|
|
223
|
+
The event shortcode can be inserted anywhere on the wordpress site using the following name:
|
|
224
|
+
|
|
225
|
+
```
|
|
226
|
+
[fresh-booking-event]
|
|
227
|
+
```
|
|
228
|
+
|
|
229
|
+
The event validation shortcode supports the following properties:
|
|
230
|
+
|
|
231
|
+
```js
|
|
232
|
+
[
|
|
233
|
+
'accent-color' => '#e7c55e',
|
|
234
|
+
'button-background' => '#e7c55e',
|
|
235
|
+
'button-border-radius' => '4px',
|
|
236
|
+
'button-border' => null,
|
|
237
|
+
'button-color' => '#000000',
|
|
238
|
+
'button-font-family' => 'inherit',
|
|
239
|
+
'button-font-size' => '14px',
|
|
240
|
+
'button-font-weight' => '400',
|
|
241
|
+
'button-text-transform' => 'uppercase',
|
|
242
|
+
'danger-color' => '#afa997',
|
|
243
|
+
'font-color' => '#666',
|
|
244
|
+
'font-family' => 'inherit',
|
|
245
|
+
'font-size' => '18px',
|
|
246
|
+
'gray-color' => 'grey',
|
|
247
|
+
'header-color' => '#000000',
|
|
248
|
+
'input-background' => '#ffffff',
|
|
249
|
+
'input-border-radius' => '0px',
|
|
250
|
+
'input-border' => '1px solid rgba(0, 0, 0, 0.15)',
|
|
251
|
+
'label-font-weight' => 'bold',
|
|
252
|
+
'label-padding' => '6px',
|
|
253
|
+
'loading-color' => '#666',
|
|
254
|
+
'panel-background' => '#ffffff',
|
|
255
|
+
'panel-border-radius' => '8px',
|
|
256
|
+
'panel-border' => null,
|
|
257
|
+
'panel-padding' => '24px',
|
|
258
|
+
'success-color' => '#e7c55e'
|
|
259
|
+
]
|
|
260
|
+
```
|
|
261
|
+
|
|
262
|
+
## Configuration
|
|
263
|
+
|
|
264
|
+
The FreshBooking WordPress plugin can be configured from the `FreshBooking` page within the WordPress administration panel.
|
|
265
|
+
|
|
266
|
+
### Settings
|
|
267
|
+
|
|
268
|
+

|
|
269
|
+
|
|
270
|
+
### Translations
|
|
271
|
+
|
|
272
|
+
FreshBooking supports custom translations.
|
|
273
|
+
|
|
274
|
+

|
package/package.json
ADDED
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@konnectio/core",
|
|
3
|
+
"version": "4.0.0",
|
|
4
|
+
"author": "Konnectio <info@freshcase.dk> (https://konnectio.dk)",
|
|
5
|
+
"homepage": "https://konnectio.dk",
|
|
6
|
+
"description": "Konnectio Core Frontend Integration.",
|
|
7
|
+
"private": false,
|
|
8
|
+
"files": [
|
|
9
|
+
"target/**/*.css",
|
|
10
|
+
"target/**/*.js",
|
|
11
|
+
"target/**/*.gz",
|
|
12
|
+
"target/**/*.br",
|
|
13
|
+
"target/**/*.json"
|
|
14
|
+
],
|
|
15
|
+
"scripts": {
|
|
16
|
+
"dev": "vite",
|
|
17
|
+
"prod": "vite build",
|
|
18
|
+
"production": "vue-tsc --noEmit && vite build --mode export && node ./createZipArchive.cjs production",
|
|
19
|
+
"staging": "vue-tsc --noEmit && vite build --mode staging && node ./createZipArchive.cjs staging",
|
|
20
|
+
"analysis": "vue-tsc --noEmit",
|
|
21
|
+
"preview": "vite preview",
|
|
22
|
+
"e2e": "cypress open"
|
|
23
|
+
},
|
|
24
|
+
"dependencies": {
|
|
25
|
+
"@chenfengyuan/vue-number-input": "2.0.1",
|
|
26
|
+
"@flareapp/flare-client": "3.0.5",
|
|
27
|
+
"@flareapp/flare-vue": "3.0.5",
|
|
28
|
+
"@flareapp/vite-plugin-sourcemap-uploader": "1.0.2",
|
|
29
|
+
"@fortawesome/fontawesome-pro": "6.4.2",
|
|
30
|
+
"@fortawesome/fontawesome-svg-core": "6.4.2",
|
|
31
|
+
"@fortawesome/free-brands-svg-icons": "6.4.2",
|
|
32
|
+
"@fortawesome/pro-light-svg-icons": "6.4.2",
|
|
33
|
+
"@fortawesome/pro-solid-svg-icons": "6.4.2",
|
|
34
|
+
"@fortawesome/vue-fontawesome": "3.0.3",
|
|
35
|
+
"@intlify/unplugin-vue-i18n": "1.0.1",
|
|
36
|
+
"@vuepic/vue-datepicker": "6.0.3",
|
|
37
|
+
"@vueup/vue-quill": "1.2.0",
|
|
38
|
+
"@vueuse/core": "10.4.1",
|
|
39
|
+
"adm-zip": "0.5.10",
|
|
40
|
+
"axios": "1.5.0",
|
|
41
|
+
"core-js": "3.32.2",
|
|
42
|
+
"cqfill": "0.6.1",
|
|
43
|
+
"dotenv": "16.3.1",
|
|
44
|
+
"floating-vue": "2.0.0-beta.24",
|
|
45
|
+
"pinia": "2.1.6",
|
|
46
|
+
"postcss": "8.4.29",
|
|
47
|
+
"regenerator-runtime": "0.14.0",
|
|
48
|
+
"vue": "3.3.4",
|
|
49
|
+
"vue-agile": "2.0.0",
|
|
50
|
+
"vue-final-modal": "4.4.5",
|
|
51
|
+
"vue-gtag": "2.0.1",
|
|
52
|
+
"vue-i18n": "9.3.0",
|
|
53
|
+
"vue-inner-image-zoom": "2.0.0",
|
|
54
|
+
"vue-masonry": "0.16.0",
|
|
55
|
+
"vue-recaptcha": "3.0.0-alpha.6",
|
|
56
|
+
"vue-recaptcha-v3": "2.0.1",
|
|
57
|
+
"vue-select": "4.0.0-beta.6",
|
|
58
|
+
"vue-snip": "2.0.0",
|
|
59
|
+
"vue3-side-panel": "1.2.0",
|
|
60
|
+
"vue3-sticky-directive": "0.0.2"
|
|
61
|
+
},
|
|
62
|
+
"devDependencies": {
|
|
63
|
+
"@babel/eslint-parser": "7.22.15",
|
|
64
|
+
"@kucrut/vite-for-wp": "0.5.2",
|
|
65
|
+
"@originjs/vite-plugin-commonjs": "1.0.3",
|
|
66
|
+
"@types/node": "20.5.9",
|
|
67
|
+
"@typescript-eslint/eslint-plugin": "5.62.0",
|
|
68
|
+
"@typescript-eslint/parser": "5.62.0",
|
|
69
|
+
"@vitejs/plugin-vue": "4.3.4",
|
|
70
|
+
"@vue/eslint-config-typescript": "11.0.3",
|
|
71
|
+
"@vue/test-utils": "2.4.1",
|
|
72
|
+
"cross-env": "7.0.3",
|
|
73
|
+
"cypress": "12.17.3",
|
|
74
|
+
"eslint": "8.48.0",
|
|
75
|
+
"eslint-plugin-vue": "9.17.0",
|
|
76
|
+
"sass": "1.68.0",
|
|
77
|
+
"ts-node": "10.9.1",
|
|
78
|
+
"typescript": "5.2.2",
|
|
79
|
+
"vite": "4.4.9",
|
|
80
|
+
"vite-plugin-compression": "0.5.1",
|
|
81
|
+
"vue-tsc": "1.8.14"
|
|
82
|
+
},
|
|
83
|
+
"contributors": [
|
|
84
|
+
{
|
|
85
|
+
"name": "Benjamin Bach Jensen",
|
|
86
|
+
"email": "dev@dapperbenji.com",
|
|
87
|
+
"url": "https://dapperbenji.com"
|
|
88
|
+
}
|
|
89
|
+
],
|
|
90
|
+
"keywords": [
|
|
91
|
+
"wordpress",
|
|
92
|
+
"vuejs",
|
|
93
|
+
"freshcase",
|
|
94
|
+
"freshbooking",
|
|
95
|
+
"booking",
|
|
96
|
+
"octopus-pms",
|
|
97
|
+
"hotelboss"
|
|
98
|
+
]
|
|
99
|
+
}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{b,r as p,J as m,f as d,m as i,A as c,h as V,i as t,j as v,_ as q}from"./vendor-7782fc29.js";import{r as g,I as k}from"./NumberField.vue_vue_type_style_index_0_lang-8bcb59b1.js";import{_ as B,T as I}from"./SelectField.vue_vue_type_style_index_0_lang-d1aa221e.js";import{_ as C}from"./NumberField.vue_vue_type_script_setup_true_lang-3c220f4d.js";import{C as A}from"./Clickable-803d7e0c.js";const h={class:"fresh-booking-action-field"},F=b({__name:"ActionField",props:{modelValue:{},label:{},buttonLabel:{},buttonIcon:{},buttonIconColor:{},buttonDisabled:{type:Boolean,default:!1},secondary:{type:Boolean,default:!1},name:{},id:{},type:{default:"text"},placeholder:{},icon:{},iconType:{default:"fal"},required:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},data:{},action:{},minValue:{},maxValue:{},isLoading:{type:Boolean,default:!1}},emits:["update:modelValue","action"],setup(f,{emit:r}){const n=f.id||g(),l=p(""),u=p(0);function s(e){r("update:modelValue",e)}m(l,e=>{s(e)}),m(u,e=>{s(e)});function y(){r("action")}return(e,a)=>(d(),i(k,{label:e.label,id:t(n),icon:e.icon,"icon-type":e.iconType,required:e.required,type:e.type,readonly:e.readonly},{default:c(()=>[V("div",h,[e.type==="dropdown"&&e.data?(d(),i(B,{key:0,modelValue:l.value,"onUpdate:modelValue":a[0]||(a[0]=o=>l.value=o),id:t(n),options:e.data,name:e.name,required:e.required,placeholder:e.placeholder},null,8,["modelValue","id","options","name","required","placeholder"])):e.type==="number"?(d(),i(C,{key:1,modelValue:u.value,"onUpdate:modelValue":a[1]||(a[1]=o=>u.value=o),id:t(n),"min-value":e.minValue,"max-value":e.maxValue},null,8,["modelValue","id","min-value","max-value"])):(d(),i(I,{key:2,modelValue:l.value,"onUpdate:modelValue":a[2]||(a[2]=o=>l.value=o),id:t(n),name:e.name,required:e.required,placeholder:e.placeholder},null,8,["modelValue","id","name","required","placeholder"])),v(A,{"data-test":`${e.name}Submit`,icon:e.buttonIcon,label:e.buttonLabel,"icon-color":e.buttonIconColor,styling:e.action,type:"button","is-loading":e.isLoading,disabled:e.buttonDisabled,secondary:e.secondary,onClickEvent:a[3]||(a[3]=o=>y())},null,8,["data-test","icon","label","icon-color","styling","is-loading","disabled","secondary"])])]),_:1},8,["label","id","icon","icon-type","required","type","readonly"]))}});const N=q(F,[["__scopeId","data-v-1d7a0ce8"]]);export{N as A};
|
|
2
|
+
//# sourceMappingURL=ActionField-b0b40c88.js.map
|
|
Binary file
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{b as T,u as $,s as w,c as d,J as j,o as z,f as m,g as D,i as e,h as b,t as J,p as v,j as g,k as f,m as h,n as V,B as L,C as M,_ as G}from"./vendor-7782fc29.js";import{u as S}from"./availability-72ce6097.js";import{m as H}from"./NumberField.vue_vue_type_style_index_0_lang-8bcb59b1.js";import{C as K}from"./Clickable-803d7e0c.js";import{_ as A}from"./DateField.vue_vue_type_style_index_0_lang-f5878599.js";import{_ as x}from"./NumberField.vue_vue_type_script_setup_true_lang-3c220f4d.js";const P=u=>(L("data-v-bc57b105"),u=u(),M(),u),Q={key:0,id:"fresh-booking-availability-form-title"},W={id:"fresh-booking-availability-date-selection"},X={key:0,id:"fresh-booking-availability-guest-selection"},Y={id:"fresh-booking-availability-confirmation"},Z=P(()=>b("div",null,null,-1)),ee=T({__name:"AvailabilityForm",props:{booking:{type:Boolean,default:!1}},setup(u){const C=u,{t:o}=$(),{adults:c,children:p,arrivalDate:t,departureDate:n,isExpired:B}=w(S()),{reset:q}=S(),{firstSelectableDateOffset:y,lastSelectableDateOffset:_,disableChildSelection:s,disableAdultSelection:l,hideTitle:I,bookingUri:U}=w(H()),E=d(()=>new Date(new Date().setDate(new Date().getDate()+(y.value-1)))),F=d(()=>new Date(new Date().setDate(new Date().getDate()+_.value))),N=d(()=>new Date(new Date().setDate(t.value.getDate()+y.value))),R=d(()=>new Date(new Date().setDate(t.value.getDate()+(_.value+1)))),k=d(()=>!(!l.value&&c.value===0));function O(){C.booking===!1?window.location.replace(U.value):k.value&&location.reload()}return j(t,r=>{const a=new Date(new Date(r).setDate(new Date(r).getDate()+1));new Date(n.value)<a&&(n.value=a)}),z(()=>{B.value&&q()}),(r,a)=>(m(),D("form",{id:"fresh-booking-availability-form",class:V({reservation:r.booking})},[!e(I)&&!r.booking?(m(),D("h3",Q,[b("span",null,J(e(o)("availability.title")),1)])):v("",!0),b("ul",{id:"fresh-booking-availability-form-content",class:V([{"is-not-booking-page":!r.booking},{"only-adult-guests":!e(l)&&e(s)},{"only-child-guests":!e(s)&&e(l)},{"no-guests":e(l)&&e(s)},{"all-guests":!e(l)&&!e(s)}])},[b("li",W,[g(A,{modelValue:e(t),"onUpdate:modelValue":a[0]||(a[0]=i=>f(t)?t.value=i:null),label:e(o)("availability.arrivalDate"),name:"arrivalDate","start-date":e(t),"min-date":E.value,"max-date":F.value,required:!0},null,8,["modelValue","label","start-date","min-date","max-date"]),g(A,{modelValue:e(n),"onUpdate:modelValue":a[1]||(a[1]=i=>f(n)?n.value=i:null),label:e(o)("availability.departureDate"),name:"departureDate","start-date":e(n),"min-date":N.value,"max-date":R.value,required:!0},null,8,["modelValue","label","start-date","min-date","max-date"])]),!e(l)||!e(s)?(m(),D("li",X,[e(l)?v("",!0):(m(),h(x,{key:0,modelValue:e(c),"onUpdate:modelValue":a[2]||(a[2]=i=>f(c)?c.value=i:null),label:e(o)("availability.adults"),name:"adults",icon:"male",required:""},null,8,["modelValue","label"])),e(s)?v("",!0):(m(),h(x,{key:1,modelValue:e(p),"onUpdate:modelValue":a[3]||(a[3]=i=>f(p)?p.value=i:null),label:e(o)("availability.children"),name:"children",icon:"child",required:""},null,8,["modelValue","label"]))])):v("",!0),b("li",Y,[Z,g(K,{label:e(o)("availability.buttonLabel"),disabled:!k.value,onClickEvent:O},null,8,["label","disabled"])])],2)],2))}});const se=G(ee,[["__scopeId","data-v-bc57b105"]]);export{se as A};
|
|
2
|
+
//# sourceMappingURL=AvailabilityForm-13918dfc.js.map
|
|
Binary file
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{b as m,f as n,m as b,A as f,h as o,a0 as c,n as r,v as h,a1 as k,g as s,t,p as i,_ as v}from"./vendor-7782fc29.js";import{I as V}from"./NumberField.vue_vue_type_style_index_0_lang-8bcb59b1.js";const B=["required","type","name","readonly","disabled","value","checked"],g=["data-test"],C={key:0},q=m({__name:"Checkbox",props:{modelValue:{type:[String,Boolean,Number]},numeric:{type:Boolean,default:!1},checked:{type:Boolean,default:!1},label:{},price:{},name:{},readonly:{type:Boolean,default:!1},type:{default:"checkbox"},required:{type:Boolean,default:!1},inputStyle:{},val:{}},emits:["update:modelValue"],setup(p,{emit:u}){const a=p;function d(){a.readonly!==!0&&u("update:modelValue",a.type==="radio"?a.val:a.numeric?a.modelValue?0:1:!a.modelValue)}return(e,l)=>(n(),b(V,{required:e.required,type:e.type,readonly:e.readonly},{default:f(()=>[o("label",{class:r(["fresh-booking-click-box-container",{"is-readonly":e.readonly},{"has-label":e.label},e.type==="radio"?"radio":"checkbox"])},[o("input",c(e.$attrs,{required:!!e.required,type:e.type,name:e.name,class:"hidden",readonly:!!e.readonly,disabled:!!e.readonly,value:e.type==="radio"?e.val:e.modelValue,checked:e.type==="radio"?e.val===e.modelValue:!!e.modelValue,onChange:l[0]||(l[0]=y=>d())}),null,16,B),o("div",{class:r(["fresh-booking-click-box",{checked:e.type==="radio"?e.val===e.modelValue:!!e.modelValue}]),tabindex:"0",style:h(e.inputStyle),"data-test":e.name,onKeyup:l[1]||(l[1]=k(y=>d(),["enter"]))},null,46,g),e.label?(n(),s("div",{key:0,class:r(["fresh-booking-click-box-label",{"with-price":e.price}])},[o("span",null,t(e.label),1),e.price?(n(),s("span",C,t(e.price),1)):i("",!0)],2)):i("",!0)],2)]),_:1},8,["required","type","readonly"]))}});const I=v(q,[["__scopeId","data-v-7ef656cb"]]);export{I as C};
|
|
2
|
+
//# sourceMappingURL=Checkbox-0b398a1a.js.map
|
|
Binary file
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{b as t,a9 as u,aa as y,ab as C,ac as g,ad as _,ae as h,af as k,ag as m,ah as v,ai as B,aj as S,ak as T,al as $,am as I,an as A,ao as H,ap as L,aq as M,ar as P,as as E,at as w,au as F,av as N,aw as W,ax as D,ay as R,az as U,aA as V,aB as G,aC as j,aD as z,aE as q,aF as K,aG as O,aH as X,aI as J,aJ as Q,aK as Y,aL as Z,aM as x,aN as aa,aO as ea,aP as sa,aQ as oa,aR as la,aS as na,aT as ia,aU as fa,aV as ta,aW as ra,aX as ca,aY as da,aZ as pa,a_ as ba,a$ as ua,b0 as ya,b1 as Ca,b2 as ga,b3 as _a,b4 as ha,b5 as ka,b6 as ma,b7 as va,b8 as Ba,b9 as Sa,ba as Ta,bb as $a,bc as Ia,bd as Aa,be as Ha,bf as La,bg as Ma,bh as Pa,bi as Ea,bj as wa,bk as Fa,bl as Na,bm as Wa,bn as Da,bo as Ra,bp as Ua,bq as Va,f as s,m as f,v as o,i as Ga,br as ja,_ as r,g as n,h as l,n as b,F as za,p as d,t as qa,j as Ka}from"./vendor-7782fc29.js";const Oa=t({__name:"Icon",props:{icon:{},iconColor:{},type:{default:"fal"},rotate:{type:Boolean,default:!1}},setup(c){return u.add(y,C,g,_,h,k,m,v,B,S,T,$,I,A,H,L,M,P,E,w,F,N,W,D,R,U,V,G,j,z,q,K,O,X,J,Q,Y,Z,x,aa,ea,sa,oa,la,na,ia,fa,ta,ra,ca,da,pa,ba,ua,ya,Ca,ga,_a,ha,ka,ma,va,Ba,Sa,Ta,$a,Ia,Aa,Ha,La,Ma,Pa,Ea,wa,Fa,Na,Wa,Da,Ra,Ua,Va),(e,i)=>(s(),f(Ga(ja),{class:"fresh-booking-icon",style:o({color:e.iconColor}),icon:[e.type,e.icon],rotation:e.rotate?180:void 0},null,8,["style","icon","rotation"]))}});const p=r(Oa,[["__scopeId","data-v-0e843a72"]]),Xa=t({__name:"Loading",props:{color:{},insideButton:{type:Boolean,default:!1}},setup(c){return(e,i)=>(s(),n("div",{class:b(["fresh-booking-loading",{"inside-button":e.insideButton}])},[l("div",{style:o({background:e.color})},null,4),l("div",{style:o({background:e.color})},null,4),l("div",{style:o({background:e.color})},null,4),l("div",{style:o({background:e.color})},null,4)],2))}});const Ja=r(Xa,[["__scopeId","data-v-2fe80841"]]),Qa=["type","tabindex","disabled"],Ya={key:0},Za=t({__name:"Clickable",props:{label:{},type:{default:"button"},icon:{},iconType:{default:"fal"},iconColor:{},tabindex:{default:"0"},fullWidth:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},secondary:{type:Boolean,default:!1},isLoading:{type:Boolean,default:!1}},emits:["click-event"],setup(c,{emit:e}){function i(){e("click-event")}return(a,xa)=>(s(),n("button",{ref:"button",type:a.type,tabindex:a.tabindex,disabled:a.disabled||a.isLoading,class:b([{"full-width":a.fullWidth},{"icon-only":!a.label&&a.icon},{"has-icon":a.label&&a.icon},{secondary:a.secondary}]),onClick:i},[a.isLoading?(s(),f(Ja,{key:1,"inside-button":!0})):(s(),n(za,{key:0},[l("span",{style:o({"--accentColor":"var(--buttonColor)"})},[a.icon?(s(),f(p,{key:0,icon:a.icon,type:a.iconType,"icon-color":a.iconColor},null,8,["icon","type","icon-color"])):d("",!0)],4),a.label?(s(),n("span",Ya,qa(a.label),1)):d("",!0),l("i",null,[Ka(p,{icon:"chevron-right",type:"fal","icon-color":"inherit"})])],64))],10,Qa))}});const ee=r(Za,[["__scopeId","data-v-c06c52a1"]]);export{ee as C,p as I,Ja as L};
|
|
2
|
+
//# sourceMappingURL=Clickable-803d7e0c.js.map
|
|
Binary file
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{b as V,Z as v,r as b,c as r,f as B,m as D,A as p,h as i,j as P,n as C,t as T,i as n,$ as q}from"./vendor-7782fc29.js";import{r as w,f as A,I}from"./NumberField.vue_vue_type_style_index_0_lang-8bcb59b1.js";const M=["name","value"],F=V({__name:"DateField",props:{modelValue:{},type:{default:"date"},label:{},id:{},name:{},placeholder:{},icon:{default:"calendar-alt"},iconColor:{},iconType:{default:"fal"},primaryColor:{},secondaryColor:{},weekendColor:{default:"inherit"},highlightedColor:{default:"inherit"},required:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},inline:{type:Boolean,default:!1},monthPicker:{type:Boolean,default:!1},yearPicker:{type:Boolean,default:!1},weekPicker:{type:Boolean,default:!1},startDate:{},minDate:{},maxDate:{},range:{type:Boolean,default:!1},autoApply:{type:Boolean,default:!0},inputStyle:{}},emits:["update:modelValue"],setup(c,{emit:d}){const o=c;v(e=>({"420ea8db":e.color}));const u=o.id||w();b(new Date().getDate());const m=e=>e.hours;function f(e){m(e)?d("update:modelValue",s(e)):d("update:modelValue",e)}function y(e){const[t,a]=e.split(":");return{hours:t,minutes:a}}function s(e){const t=a=>String(a).length===1?"0"+a:a;return`${t(e.hours)}:${t(e.minutes)}`}const l=r(()=>o.type==="time"),h=r(()=>{let e=o.modelValue;return l.value&&typeof e=="string"&&(e=y(e)),e}),k=r(()=>{let e=o.modelValue;return l.value&&typeof e!="string"&&(e=s(e)),e});return(e,t)=>(B(),D(I,{label:e.label,id:`dp-input-${n(u)}`,icon:e.icon,"icon-color":e.iconColor,"icon-type":e.iconType,required:e.required,type:"fresh-booking-datetime-picker",readonly:e.readonly},{default:p(()=>[i("input",{type:"hidden",name:e.name,value:k.value},null,8,M),i("div",null,[P(n(q),{uid:n(u),"input-class-name":"datetime-picker-input",inline:e.inline,placeholder:e.placeholder,required:!!e.required,readonly:e.readonly,locale:n(A)(!0),"onUpdate:modelValue":f,highlightWeekDays:[0,6],modelValue:h.value,"week-picker":e.weekPicker,"month-picker":e.monthPicker,"year-picker":e.yearPicker,"time-picker":l.value,format:l.value?"HH:mm":"dd MMM yyyy",range:e.range,enableTimePicker:l.value,"start-date":e.startDate,"min-date":e.minDate,"max-date":e.maxDate,autoApply:e.autoApply,hideInputIcon:!0,clearable:!1,transitions:{open:"none"}},{"calendar-header":p(({index:a,day:g})=>[i("div",{class:C(a===5||a===6?"calendar-header-highlight":"calendar-header-normal")},T(g),3)]),_:1},8,["uid","inline","placeholder","required","readonly","locale","modelValue","week-picker","month-picker","year-picker","time-picker","format","range","enableTimePicker","start-date","min-date","max-date","autoApply"])])]),_:1},8,["label","id","icon","icon-color","icon-type","required","readonly"]))}});export{F as _};
|
|
2
|
+
//# sourceMappingURL=DateField.vue_vue_type_style_index_0_lang-f5878599.js.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{b as _,r as h,o as z,f as v,m as b,A as V,h as p,j as m,i as a,_ as P,u as T,g as A,K as s,t as d}from"./vendor-7782fc29.js";import{r as y,I as q}from"./NumberField.vue_vue_type_style_index_0_lang-8bcb59b1.js";import{T as g}from"./SelectField.vue_vue_type_style_index_0_lang-d1aa221e.js";const C={class:"fresh-booking-phone-input"},S=_({__name:"PhoneField",props:{modelValue:{},label:{},id:{},placeholder:{},icon:{default:"phone-office"},iconColor:{},iconType:{default:"fal"},required:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},inputStyle:{}},emits:["update:modelValue"],setup(u,{emit:n}){const e=u,o=e.id||y(),r=h({code:"+45",number:""});function c(){n("update:modelValue",`${r.value.code} ${r.value.number}`)}return z(()=>{if(e.modelValue){const l=e.modelValue.split(" ");r.value.code=l[0],r.value.number=l[1]}}),(l,t)=>(v(),b(q,{label:l.label,id:a(o),type:"phone",required:l.required,readonly:l.readonly},{default:V(()=>[p("div",C,[m(g,{modelValue:r.value.code,"onUpdate:modelValue":t[0]||(t[0]=i=>r.value.code=i),type:"text",id:a(y)(),name:"phone-code",autocomplete:"tel-country-code",icon:l.icon,"icon-color":l.iconColor,"icon-type":l.iconType,placeholder:"+45",required:l.required,readonly:l.readonly,"input-style":l.inputStyle,onInput:t[1]||(t[1]=i=>c())},null,8,["modelValue","id","icon","icon-color","icon-type","required","readonly","input-style"]),m(g,{modelValue:r.value.number,"onUpdate:modelValue":t[2]||(t[2]=i=>r.value.number=i),type:"number",name:"phone",autocomplete:"tel-national",id:a(o),placeholder:l.placeholder,required:l.required,readonly:l.readonly,"input-style":l.inputStyle,onInput:t[3]||(t[3]=i=>c())},null,8,["modelValue","id","placeholder","required","readonly","input-style"])])]),_:1},8,["label","id","required","readonly"]))}});const G=P(S,[["__scopeId","data-v-bd936115"]]),k={href:"https://policies.google.com/privacy"},I={href:"https://policies.google.com/terms"},N=_({__name:"GoogleNotice",setup(u){const{t:n}=T();return(e,o)=>(v(),A("span",null,[s(d(a(n)("googleNotice"))+" ",1),p("a",k,d(a(n)("googlePrivacyPolicy")),1),s(" "+d(a(n)("googleAnd"))+" ",1),p("a",I,d(a(n)("googleTOS")),1),s(" "+d(a(n)("googleApply"))+". ",1)]))}});function f(u){const n=u;n.__i18n=n.__i18n||[],n.__i18n.push({locale:"",resource:{da:{googleNotice:e=>{const{normalize:o}=e;return o(["Denne side er beskyttet af reCAPTCHA og Google's"])},googlePrivacyPolicy:e=>{const{normalize:o}=e;return o(["Privatlivspolitik"])},googleAnd:e=>{const{normalize:o}=e;return o(["og"])},googleTOS:e=>{const{normalize:o}=e;return o(["Servicevilkår"])},googleApply:e=>{const{normalize:o}=e;return o(["er gældende"])}},en:{googleNotice:e=>{const{normalize:o}=e;return o(["This site is protected by reCAPTCHA and the Google"])},googlePrivacyPolicy:e=>{const{normalize:o}=e;return o(["Privacy Policy"])},googleAnd:e=>{const{normalize:o}=e;return o(["and"])},googleTOS:e=>{const{normalize:o}=e;return o(["Terms of Service"])},googleApply:e=>{const{normalize:o}=e;return o(["apply"])}}}})}typeof f=="function"&&f(N);export{G as P,N as _};
|
|
2
|
+
//# sourceMappingURL=GoogleNotice-950f8f64.js.map
|
|
Binary file
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{b as r,o as t,f as u,m as s,A as p,j as f,i as a,a2 as m}from"./vendor-7782fc29.js";import{r as y,I as c}from"./NumberField.vue_vue_type_style_index_0_lang-8bcb59b1.js";const h=r({__name:"NumberField",props:{modelValue:{default:0},minValue:{default:0},maxValue:{default:1/0},inputtable:{type:Boolean,default:!0},label:{},placeholder:{},icon:{},iconColor:{},iconType:{default:"fal"},step:{default:1},controls:{type:Boolean,default:!0},required:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},inline:{type:Boolean,default:!1},id:{},rounded:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},small:{type:Boolean,default:!1}},emits:["update:modelValue"],setup(d,{emit:i}){const l=d,o=l.id||y();function n(e){i("update:modelValue",e)}return t(()=>{l.modelValue||n(l.minValue)}),(e,b)=>(u(),s(c,{label:e.label,id:a(o),icon:e.icon,"icon-color":e.iconColor,"icon-type":e.iconType,required:e.required,type:e.small?"fresh-booking-number-picker small":"fresh-booking-number-picker",readonly:e.readonly},{default:p(()=>[f(a(m),{attrs:{id:a(o)},modelValue:e.modelValue,min:e.minValue,max:e.maxValue,step:e.step,inline:e.inline,controls:e.controls,placeholder:e.placeholder,readonly:e.readonly,inputtable:e.inputtable,rounded:e.rounded,disabled:e.disabled,"onUpdate:modelValue":n},null,8,["attrs","modelValue","min","max","step","inline","controls","placeholder","readonly","inputtable","rounded","disabled"])]),_:1},8,["label","id","icon","icon-color","icon-type","required","type","readonly"]))}});export{h as _};
|
|
2
|
+
//# sourceMappingURL=NumberField.vue_vue_type_script_setup_true_lang-3c220f4d.js.map
|
|
Binary file
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{d as I,r as m,c as s,a7 as ie,s as U,a8 as ce,R as O,b as $,f as b,g as _,i as v,j as D,h as C,t as K,p as N,n as w,_ as x,u as ue,x as L}from"./vendor-7782fc29.js";import{I as W}from"./Clickable-803d7e0c.js";const de=I("auth",()=>{const e=m(""),t=s(()=>`Bearer ${e.value}`);function r(n){e.value=n}return{token:e,accessToken:t,initialize:r}}),z="en",fe=document.documentElement.lang.slice(0,2)||z,f=ie({warnHtmlMessage:!1,fallbackRootWithEmptyString:!1,silentTranslationWarn:!0,allowComposition:!0,legacy:!1,globalInjection:!0,locale:fe,fallbackLocale:z});var pe=(e=>(e[e.Accept=0]="Accept",e[e.Error=1]="Error",e[e.Cancel=2]="Cancel",e[e.Close=3]="Close",e[e.Open=4]="Open",e[e.CheckResult=5]="CheckResult",e))(pe||{}),c=(e=>(e[e.Invalid=0]="Invalid",e[e.PerUnit=1]="PerUnit",e[e.PerPerson=2]="PerPerson",e[e.PerAdult=3]="PerAdult",e[e.PerChild=4]="PerChild",e[e.PerNight=5]="PerNight",e[e.PerPersonPerNight=6]="PerPersonPerNight",e[e.PerAdultPerNight=7]="PerAdultPerNight",e[e.PerChildPerNight=8]="PerChildPerNight",e[e.Consumption=9]="Consumption",e[e.EarlyCheckIn=10]="EarlyCheckIn",e[e.EarlyCheckOut=11]="EarlyCheckOut",e[e.OneTimePayment=12]="OneTimePayment",e))(c||{}),he=(e=>(e[e.None=0]="None",e[e.AskForCreditCard=2]="AskForCreditCard",e[e.Stripe=18]="Stripe",e[e.DIBS=47]="DIBS",e[e.EasyPay=56]="EasyPay",e[e.ReePay=57]="ReePay",e))(he||{}),ge=(e=>(e.Selective="selective",e.Wholesale="wholesale",e.Simplified="simplified",e.Template="template",e.Event="event",e))(ge||{}),me=(e=>(e.Default="default",e.Minimal="minimal",e))(me||{}),ve=(e=>(e[e.InitialState=0]="InitialState",e[e.WaitingForResponse=1]="WaitingForResponse",e[e.ReadyToPay=2]="ReadyToPay",e[e.PaymentSuccess=3]="PaymentSuccess",e))(ve||{}),be=(e=>(e[e.None=0]="None",e[e.Hourly=1]="Hourly",e[e.FullDayEvent=2]="FullDayEvent",e[e.Weekly=3]="Weekly",e))(be||{}),_e=(e=>(e[e.InitialState=0]="InitialState",e[e.AvailabilityState=1]="AvailabilityState",e[e.ReservationState=2]="ReservationState",e[e.PaymentState=3]="PaymentState",e))(_e||{});function ke(e){return`{${e.slice(1,-1).replace(/({|}|@|\$|\|)/,"{'$1'}")}}`}function Le(e){switch(e){case c.PerUnit:return f.global.t("general.perUnit");case c.PerNight:return f.global.t("general.perNight");case c.PerPerson:return f.global.t("general.perPerson");case c.PerAdultPerNight:return f.global.t("general.perAdultPerNight")}}function We(e,t,r,n=0,a=0){switch(t){case c.PerUnit:return e;case c.PerNight:return e*r;case c.PerAdult:return e*n;case c.PerChild:return e*a;case c.PerPerson:return e*(n+a);case c.PerAdultPerNight:return e*n*r;case c.PerChildPerNight:return e*a*r;case c.PerPersonPerNight:return e*(n+a)*r;case c.OneTimePayment:return e;default:return e}}function ze(e){return e===void 0?e:e.replace(/([!?.])([a-z])/g,function(t,r,n){return n.toUpperCase()})}function Be(e){if(e!==void 0){const t=new RegExp("\\n","g");return e.replace(t,"<br>")}else return""}function Ee(e){switch(e){case 2:return f.global.t("booking.reservation.nameTitleMr");case 3:return f.global.t("booking.reservation.nameTitleMs");case 4:return f.global.t("booking.reservation.nameTitleMrs");case 5:return f.global.t("booking.reservation.nameTitleDr");default:return""}}function He(e){const t=[];return e.flatMap(r=>{r.occupantRates.flatMap(n=>{t.push(`"${n.roomGroupID}.${n.ratePlanID}.${n.adultsCount}.${n.childrenCount}":0`)})}),JSON.parse(`{${t.toString()}}`)}function Je(e){const t=[];return e.flatMap(r=>{r.occupantRates.flatMap(n=>{t.push(`"${n.roomGroupID}":1`)})}),JSON.parse(`{${t.toString()}}`)}function Me(e){let t,r,n,a,i,u,p,l,d,h=0,A=0,g="";const k="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",P=[];if(!e)return e;do t=e.charCodeAt(h++),r=e.charCodeAt(h++),n=e.charCodeAt(h++),l=t<<16|r<<8|n,a=63&l>>18,i=63&l>>12,u=63&l>>6,p=63&l,P[A++]=k.charAt(a)+k.charAt(i)+k.charAt(u)+k.charAt(p);while(h<e.length);return g=P.join(""),d=e.length%3,(d?g.slice(0,d-3):g)+"===".slice(d||3)}function Ve(e){return e.toLowerCase()}function qe(e){return e==="true"}function Re(e){return new Date(e).toISOString()}function Ye(e,t){const r=new Date(e),n=new Date(t),a=n.getTime()-r.getTime();return Math.round(a/(1e3*60*60*24))}function F(e=!1){return e?document.documentElement.lang||"en-US":document.documentElement.lang.slice(0,2)||"en"}function Ae(e){const t={};return e.forEach(r=>{t[r.iso]=JSON.parse(ke(r.message))}),t}function Xe(e){const t=Object.prototype.hasOwnProperty;if(e==null)return!0;if(e.length>0)return!1;if(e.length===0||typeof e!="object")return!0;for(const r in e)if(t.call(e,r))return!1;return!0}function Ze(e,t){let r={label:"",value:""};return e.forEach(n=>{String(n.value)===String(t)&&(r=n)}),r}function Pe(e=10){const t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",r=t.length;let n="";for(let a=0;a<e;a++)n+=t.charAt(Math.floor(Math.random()*r));return n}function T(e,t=0){let r=new Date(e);r=new Date(r.setDate(r.getDate()+t));let n;switch(F()){case"da":case"se":n={0:"jan",1:"feb",2:"mar",3:"apr",4:"maj",5:"jun",6:"jul",7:"aug",8:"sep",9:"okt",10:"nov",11:"dec"};break;case"no":n={0:"jan",1:"feb",2:"mar",3:"apr",4:"mai",5:"jun",6:"jul",7:"aug",8:"sep",9:"okt",10:"nov",11:"des"};break;case"de":n={0:"jan",1:"feb",2:"mär",3:"apr",4:"mai",5:"jun",6:"jul",7:"aug",8:"sep",9:"okt",10:"nov",11:"dez"};break;case"fi":n={0:"tam",1:"hel",2:"maa",3:"huh",4:"tou",5:"kes",6:"hei",7:"elo",8:"syy",9:"lok",10:"mar",11:"jou"};break;case"fr":n={0:"jan",1:"feb",2:"mar",3:"apr",4:"mai",5:"jun",6:"jui",7:"aoû",8:"sep",9:"okt",10:"nov",11:"dec"};break;case"it":n={0:"gen",1:"feb",2:"mar",3:"apr",4:"mag",5:"giu",6:"lug",7:"ago",8:"set",9:"ott",10:"nov",11:"dic"};break;default:n={0:"Jan",1:"Feb",2:"Mar",3:"Apr",4:"May",5:"Jun",6:"Jul",7:"Aug",8:"Sep",9:"Oct",10:"Nov",11:"Dec"};break}return`${r.getDate()} ${n[r.getMonth()]} ${r.getFullYear()}`}function Ce(e){const t=e.sort();for(let r=1;r<t.length;r++)if(t[r]!=t[r-1]+1)return!1;return!0}function ye(e){let t=e;const r=[6,7],n=e.split(",").map(Number);let a;switch(F()){case"da":a={1:"Man",2:"Tir",3:"Ons",4:"Tor",5:"Fre",6:"Lør",7:"Søn"};break;default:a={1:"Mon",2:"Tue",3:"Wed",4:"Thu",5:"Fri",6:"Sat",7:"Sun"};break}return n.length===7?t=f.global.t("general.everyday"):r.some(i=>n.includes(i))?t=f.global.t("general.weekends"):Ce(n)&&n.length>1?t=`${a[n[0]]} - ${a[n[n.length-1]]}`:t="-",t}function Ge(e,t,r=!1){if(r){const n=e.split("-");e=`${n[1]}-${n[0]}-${n[2]}`;const a=t.split("-");t=`${a[1]}-${a[0]}-${a[2]}`}return e===t?`${T(e)}}`:`${T(e)} - ${T(t)}`}function S(e){let t=e;const r=e.split(":");return r[2]&&(t=`${r[0]}:${r[1]}`),t}function Qe(e,t){return e===t?S(e):`${S(e)} - ${S(t)}`}function et(e,t="DKK"){const r=F();let n=",";switch(r){case"da":n=".";break}const a=e.toString().split(".");return a[0]=a[0].replace(/\B(?=(\d{3})+(?!\d))/g,n),a[1]&&(a[1]=a[1].substr(0,2)),`${t} ${a.join(n===","?".":",")}`}function o(e){return e==="false"?!1:!!e}const B=I("settings",()=>{const e=m({}),t=s(()=>e.value.arrivalDefault),r=s(()=>e.value.arrivalEarliest),n=s(()=>e.value.arrivalLatest),a=s(()=>e.value.bookingUri),i=s(()=>e.value.departureDefault),u=s(()=>e.value.departureEarliest),p=s(()=>e.value.departureLatest),l=s(()=>o(e.value.disableAdultSelection)),d=s(()=>o(e.value.disableArrivalUserSelection)),h=s(()=>o(e.value.disableChildSelection)),A=s(()=>o(e.value.disableDepartureUserSelection)),g=s(()=>o(e.value.disableGiftCardVoucher)),k=s(()=>o(e.value.disableNamePrefix)),P=s(()=>o(e.value.enablePackages)),E=s(()=>o(e.value.enableTracking)),H=s(()=>parseInt(e.value.firstSelectableDateOffset)),J=s(()=>e.value.googleApiKey),M=s(()=>e.value.headerHeight),V=s(()=>o(e.value.hideArrivalDepartureInputs)),q=s(()=>o(e.value.hideTitle)),R=s(()=>parseInt(e.value.lastSelectableDateOffset)),Y=s(()=>parseInt(e.value.maxAdultAmount)),X=s(()=>parseInt(e.value.maxChildAmount)),Z=s(()=>parseInt(e.value.maximumNightsAvailable)),y=s(()=>e.value.recaptchaSecretKey),j=s(()=>e.value.recaptchaSiteKey),G=s(()=>!!j.value),Q=s(()=>o(e.value.disablePricesFrom)),ee=s(()=>o(e.value.hideAvailableRoomAmount)),te=s(()=>o(e.value.hideEvents)),re=s(()=>o(e.value.hideEventTemplates)),ne=s(()=>o(e.value.disableNewsletterSignup)),ae=s(()=>o(e.value.disableTravelingFor)),se=s(()=>o(e.value.disableCompanyField));function le(oe){e.value=oe}return{setSettings:le,arrivalDefault:t,arrivalEarliest:r,arrivalLatest:n,bookingUri:a,departureDefault:i,departureEarliest:u,departureLatest:p,disableAdultSelection:l,disableArrivalUserSelection:d,disableChildSelection:h,disableDepartureUserSelection:A,disableGiftCardVoucher:g,disableNamePrefix:k,enablePackages:P,enableTracking:E,firstSelectableDateOffset:H,googleApiKey:J,headerHeight:M,hideArrivalDepartureInputs:V,hideTitle:q,lastSelectableDateOffset:R,maxAdultAmount:Y,maxChildAmount:X,maximumNightsAvailable:Z,recaptchaSecretKey:y,recaptchaSiteKey:j,isRecaptchaEnabled:G,disablePricesFrom:Q,hideAvailableRoomAmount:ee,hideEvents:te,hideEventTemplates:re,disableNewsletterSignup:ne,disableTravelingFor:ae,disableCompanyField:se}}),Ne=I("tracking",()=>{const{enableTracking:e,googleApiKey:t}=U(B());function r(){ce({config:{id:t.value,params:{send_page_view:!1}},enabled:e.value})}function n({id:l,name:d,value:h,label:A,category:g="general"}){return{items:[{id:l,name:d}],event_label:A,event_category:g,value:h}}function a(l,d){O(l,n(d))}function i(l){a("add_to_cart",{...l,label:"Added to cart",category:"ecommerce"})}function u(l){a("remove_from_cart",{...l,label:"Removed to cart",category:"ecommerce"})}function p(l){O("view_item",{items:[{name:l}]})}return{setup:r,viewItem:p,addToCart:i,removeFromCart:u}}),Ie=I("alert",()=>{const e=m(""),t=m("default"),r=m("NotActive"),n=m(NaN),a=m("global");function i({message:u,type:p="default"}){e.value=u,t.value=p,r.value!=="NotActive"?(r.value="KeepActive",clearTimeout(n.value),n.value=window.setTimeout(()=>{r.value="NotActive"},4e3)):(r.value="StartActive",n.value=window.setTimeout(()=>{r.value="NotActive"},4e3))}return{message:e,type:t,status:r,timer:n,domain:a,display:i}}),Te={key:0,class:"fresh-booking-alert-message"},Se=$({__name:"Alert",props:{localDomain:{default:"global"}},setup(e){const t={default:"info",error:"exclamation-triangle",warning:"do-not-enter",success:"check-circle"},{message:r,type:n,status:a}=U(Ie());return(i,u)=>(b(),_("div",{class:w(["fresh-booking-alert",v(n),v(a).toLowerCase()]),role:"alert"},[v(r)?(b(),_("div",Te,[D(W,{icon:t[v(n)]},null,8,["icon"]),C("span",null,K(v(r)),1)])):N("",!0)],2))}});const we=x(Se,[["__scopeId","data-v-bdb46110"]]),tt=$({__name:"_",props:{token:{},wpSettings:{},wpTranslations:{}},setup(e){const t=e,{initialize:r}=de(),{setSettings:n}=B(),{setup:a}=Ne();return t.token&&r(t.token),n(t.wpSettings),a(),t.wpTranslations&&ue({useScope:"global",messages:Ae(t.wpTranslations)}),(i,u)=>(b(),_("div",null,[L(i.$slots,"default"),D(we,{"local-domain":"global"})]))}}),$e={class:"fresh-booking-input-field"},De=["for"],Fe={key:1,class:"fresh-booking-description"},je=["innerHTML"],Oe=["for"],Ue=$({__name:"InputField",props:{type:{},label:{},id:{},icon:{},iconColor:{},iconType:{default:"fal"},required:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},limit:{default:1/0},description:{}},setup(e){const t=e,r=t.id||Pe(),n=s(()=>{if(t.limit!==1/0){let a=t.limit.toString().length;return a<=2?"has-2-digit-limit":a===3?"has-3-digit-limit":"has-4-digit-limit"}else return});return(a,i)=>(b(),_("div",$e,[a.label?(b(),_("label",{key:0,for:v(r),class:w(["fresh-booking-label",{required:a.required}])},[C("span",null,K(a.label),1)],10,De)):N("",!0),a.description?(b(),_("div",Fe,[C("span",{innerHTML:a.description},null,8,je)])):N("",!0),C("div",{class:w([{"has-icon":a.icon},{"is-readonly":a.readonly},"fresh-booking-input-fillable",n.value,a.type])},[a.icon?(b(),_("label",{key:0,class:"fresh-booking-input-icon",for:v(r)},[D(W,{icon:a.icon,"icon-color":a.iconColor,type:a.iconType},null,8,["icon","icon-color","type"])],8,Oe)):N("",!0),L(a.$slots,"default")],2)]))}});const rt=x(Ue,[["__scopeId","data-v-6a2c2370"]]);export{me as A,ge as B,Me as C,_e as E,ve as G,rt as I,be as O,he as P,c as Q,pe as R,tt as _,f as a,qe as b,ze as c,de as d,We as e,F as f,Ze as g,Ye as h,Xe as i,Ge as j,Qe as k,et as l,B as m,Le as n,S as o,T as p,Ne as q,Pe as r,ye as s,Be as t,Ie as u,Ve as v,He as w,Je as x,Ee as y,Re as z};
|
|
2
|
+
//# sourceMappingURL=NumberField.vue_vue_type_style_index_0_lang-8bcb59b1.js.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{b as I,r as v,c as f,o as $,f as n,m as T,A as h,g as r,p as k,q as w,a3 as A,a0 as F,i as t,a4 as U,v as D,a5 as j,h as p,t as B,n as z,K as E,_ as L,J as O,j as P,x as S,a6 as Q}from"./vendor-7782fc29.js";import{r as H,c as C,I as K}from"./NumberField.vue_vue_type_style_index_0_lang-8bcb59b1.js";const J=["name","value"],G=["id","data-test","name","required","readonly","autocomplete","placeholder","disabled","maxlength","row"],R=["id","data-test","name","type","required","readonly","autocomplete","placeholder","disabled","maxlength"],W={key:4,class:"suffix"},X={key:5,class:"fresh-booking-input-limit"},Y=I({__name:"TextField",props:{modelValue:{},description:{},suffix:{},label:{},id:{},name:{},placeholder:{},icon:{},iconColor:{},iconType:{default:"fal"},required:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},type:{default:"text"},autocomplete:{},disabled:{type:Boolean,default:!1},limit:{default:1/0},rows:{default:3},inputStyle:{}},emits:["update:modelValue"],setup(b,{emit:m}){const a=b,u=v(),d=v(),s=a.id||H(),l=()=>{m("update:modelValue",d.value.getHTML())},y=v({placeholder:a.placeholder,readOnly:a.readonly,theme:"snow"}),o=f({get:()=>a.modelValue,set:e=>{m("update:modelValue",e)}}),g=f(()=>{const e=a.limit;let i=0;return a.modelValue&&(i=a.modelValue.toString().length),e-i}),V=f(()=>a.readonly?void 0:a.placeholder),c=f(()=>!!a.name&&!!a.autocomplete);function M(){if(a.type==="textarea"){const e=u.value;e.setAttribute("style",`height:${e.scrollHeight}px`)}}function N(){const e=u.value;e.style.height="auto",e.style.height=e.scrollHeight+"px"}return $(()=>{M()}),(e,i)=>(n(),T(K,{label:e.label,id:t(s),icon:e.icon,"icon-color":e.iconColor,"icon-type":e.iconType,required:e.required,type:e.type,readonly:e.readonly,description:e.description,limit:e.limit},{default:h(()=>[c.value?k("",!0):(n(),r("input",{key:0,type:"hidden",name:e.name,value:e.modelValue},null,8,J)),e.type==="textarea"?w((n(),r("textarea",F({key:1,"onUpdate:modelValue":i[0]||(i[0]=q=>o.value=q)},e.$attrs,{ref_key:"textField",ref:u,id:t(s),"data-test":t(C)(e.name),name:c.value?e.name:void 0,required:!!e.required,readonly:!!e.readonly,autocomplete:e.autocomplete||"off",placeholder:V.value,disabled:e.disabled,maxlength:e.limit,row:e.rows,style:e.inputStyle,onInput:N}),null,16,G)),[[A,o.value]]):e.type==="editor"?(n(),T(t(U),{key:2,content:e.modelValue,ref_key:"editorField",ref:d,options:y.value,"content-type":"html",id:t(s),name:c.value?e.name:null,required:!!e.required,autocomplete:e.autocomplete||"off",placeholder:V.value,disabled:e.disabled,style:D(e.inputStyle),"onUpdate:content":l},null,8,["content","options","id","name","required","autocomplete","placeholder","disabled","style"])):w((n(),r("input",F({key:3,"onUpdate:modelValue":i[1]||(i[1]=q=>o.value=q)},e.$attrs,{id:t(s),"data-test":t(C)(e.name),name:c.value?e.name:void 0,type:e.type,required:!!e.required,readonly:!!e.readonly,autocomplete:e.autocomplete||"off",placeholder:V.value,disabled:e.disabled,maxlength:e.limit,style:e.inputStyle}),null,16,R)),[[j,o.value]]),e.suffix?(n(),r("div",W,[p("div",null,[p("span",null,B(e.suffix),1)])])):k("",!0),g.value!==1/0?(n(),r("div",X,[p("span",{class:z({danger:g.value<=15})},B(g.value),3),E("/"),p("small",null,B(e.limit),1)])):k("",!0)]),_:1},8,["label","id","icon","icon-color","icon-type","required","type","readonly","description","limit"]))}});const ee=L(Y,[["__scopeId","data-v-5059c1f2"]]),Z=["name","value"],le=I({__name:"SelectField",props:{modelValue:{},label:{},options:{},labelKey:{default:"label"},valueKey:{default:"value"},name:{},icon:{},iconType:{},iconColor:{},id:{},multiple:{type:Boolean,default:!1},taggable:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},required:{type:Boolean,default:!1},placeholder:{},autocomplete:{default:"off"},clearable:{type:Boolean,default:!1}},emits:["update:modelValue"],setup(b,{emit:m}){const a=b,u=a.id||H(),d=v();function s(l){m("update:modelValue",l)}return O(d,l=>{s(l)}),$(()=>d.value=a.modelValue),(l,y)=>(n(),T(K,{label:l.label,id:t(u),icon:l.icon,"icon-type":l.iconType,"icon-color":l.iconColor,required:l.required,type:"dropdown",readonly:l.readonly},{default:h(()=>[p("input",{type:"hidden",name:l.name,value:l.modelValue},null,8,Z),P(t(Q),{modelValue:d.value,"onUpdate:modelValue":y[0]||(y[0]=o=>d.value=o),label:l.labelKey,uid:t(u),reduce:o=>o[l.valueKey],placeholder:l.placeholder,options:l.options,multiple:l.multiple,taggable:l.taggable,autocomplete:l.autocomplete,clearable:l.clearable},{option:h(o=>[S(l.$slots,"option",{data:o})]),"selected-option":h(o=>[S(l.$slots,"selected-option",{data:o})]),_:3},8,["modelValue","label","uid","reduce","placeholder","options","multiple","taggable","autocomplete","clearable"])]),_:3},8,["label","id","icon","icon-type","icon-color","required","readonly"]))}});export{ee as T,le as _};
|
|
2
|
+
//# sourceMappingURL=SelectField.vue_vue_type_style_index_0_lang-d1aa221e.js.map
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import{d as Ye,r as _,c as d,a as ue,s as q,G as L,H as V,b as te,u as ge,o as $t,e as Pe,f as s,g as c,m as ee,i as t,A as Pt,p as y,n as Q,h as e,F as Z,l as J,t as l,w as ce,j as H,q as ve,x as W,U as Se,X as Dt,_ as ae,y as wt,Y as Tt,k as Ct,B as Rt,C as At}from"./vendor-7782fc29.js";import{d as Qe,u as We,P as de,f as pe,a as G,R as He,m as we,h as qe,Q as M,w as Ft,x as Nt,y as $e,z as Bt,B as re,l as E,t as Xe,A as Y,p as zt}from"./NumberField.vue_vue_type_style_index_0_lang-8bcb59b1.js";import{u as De}from"./applyGiftCard-dff85e53.js";import{u as Mt}from"./availability-72ce6097.js";import{I as me,C as Ke}from"./Clickable-803d7e0c.js";import{A as Et}from"./ActionField-b0b40c88.js";import{T as Gt}from"./SelectField.vue_vue_type_style_index_0_lang-d1aa221e.js";import{_ as Lt}from"./GoogleNotice-950f8f64.js";const Te=Ye("payment",()=>{const T=Qe(),{display:p}=We(),S=_(de.None),r=_({}),w=d(()=>S.value!==de.None),B=d(()=>r.value&&r.value.guest?r.value.guest.name:""),C=d(()=>r.value&&r.value.guest?r.value.guest.email:""),D=d(()=>r.value&&r.value.guest?r.value.guest.phone:""),A=d(()=>r.value.adults),z=d(()=>r.value.children),h=d(()=>r.value.totalPrice||0),N=d(()=>r.value.totalVAT||0),$=d(()=>r.value.offerDate),g=d(()=>h.value-N.value),k=d(()=>r.value.orderLinesSummary),v=d(()=>k.value?k.value.length>0:!1);async function o(){const F=(await ue.get("https://octopus.freshcase.dk/api/v3/metadata/payment",{params:{language:pe()},headers:{Authorization:T.accessToken,"Fresh-Booking-Ver":"3.3.3"}})).data;S.value=F.paymentGateway}async function u({callback:F,response:b}){if(!b.error)if(!b.offer)p({message:G.global.t("booking.other.errorMessage"),type:"warning"});else if(r.value=b.offer,b.easyPayment)if(F(),S.value===de.ReePay){const R=new Reepay.EmbeddedCheckout(b.easyPayment.paymentID,{html_element:"fresh-booking-payment-checkout"});R.addEventHandler(He.Accept,()=>{p({message:G.global.t("alert.success.payment"),type:"success"}),F()}),R.addEventHandler(He.Error,()=>{p({message:G.global.t("alert.error.payment"),type:"warning"})})}else{const R={checkoutKey:b.easyPayment.checkoutSecretKey,paymentId:b.easyPayment.paymentID,containerId:"fresh-booking-payment-checkout",language:pe()==="da"?"da-DK":"en-GB"},X=new Dibs.Checkout(R);X.on("payment-completed",()=>{console.log("FreshBooking: Payment completed!"),p({message:G.global.t("alert.success.payment"),type:"success"}),F()}),X.on("pay-initialized",()=>{X.send("payment-order-finalized",!0)})}else F(2)}function I(){o()}return{paymentGateway:S,offerData:r,hasPaymentGateway:w,name:B,email:C,phone:D,adults:A,children:z,totalPrice:h,totalVAT:N,offerDate:$,subTotalPrice:g,orderSummary:k,hasOrderLines:v,fetchMetaData:o,pay:u,initialize:I}});const Vt=Ye("hotel",()=>{const T=Qe(),p=Te(),{voucher:S,amount:r}=q(De()),{display:w}=We(),{adults:B,children:C,arrivalDate:D,departureDate:A}=q(Mt()),{arrivalDefault:z,departureDefault:h,disableArrivalUserSelection:N,disableDepartureUserSelection:$}=q(we()),g=_({}),k=_({}),v=_(!0),o=_(0),u=_({}),I=_({}),F=_(NaN),b=_(NaN),R=_(""),X=_(""),Ce=_(""),oe=L("freshBookingName","",void 0,{serializer:V.string}),he=L("freshBookingNameTitle",2,void 0,{serializer:V.number}),ne=L("freshBookingEmail","",void 0,{serializer:V.string}),se=L("freshBookingPhone","",void 0,{serializer:V.string}),Re=L("freshBookingFirmName","",void 0,{serializer:V.string}),fe=L("freshBookingPostal","",void 0,{serializer:V.string}),ye=L("freshBookingCity","",void 0,{serializer:V.string}),Ae=L("freshBookingCountry",57,void 0,{serializer:V.number}),ke=L("freshBookingAddress","",void 0,{serializer:V.string}),Fe=_(""),Ne=_(""),le=_(!1),O=_({}),Be=_(!1),je=d(()=>g.value.termsOfService),Ze=d(()=>qe(k.value.fromDate,k.value.toDate)),Je=d(()=>g.value.currency?g.value.currency.iso:"DKK"),xe=d(()=>g.value.country?g.value.country:""),et=d(()=>g.value.countries?g.value.countries:[]),tt=d(()=>g.value.name?g.value.name:""),at=d(()=>g.value.hotelImages?g.value.hotelImages:[]),ot=d(()=>Object.keys(g.value).length!==0),nt=d(()=>Object.keys(k.value).length!==0),st=d(()=>!(!oe.value[1]||!ne.value||!(se.value.length>=5)||!fe.value||!ye.value||!ke.value)),lt=d(()=>o.value===3&&v.value),K=d(()=>{if(k.value.availableTemplates)return k.value.availableTemplates.find(a=>a.id===F.value)});function it(a){if(K.value)return K.value.avilableRoomGroups.find(i=>i.roomGroupID===a)}const be=d(()=>{if(K.value)return K.value.avilableRoomGroups.find(a=>a.roomGroupID===b.value)});function rt(a){return k.value.availableRoomGroups.find(i=>i.roomGroupId===a)}const ze=d(()=>{for(const a in u.value)if(u.value[a]!==0){const i=a.split("."),n=parseInt(i[1]);if(isNaN(n))return!1}return!0}),Me=d(()=>{for(const a in u.value)if(u.value[a]!==0)return!0;return!1}),ut=d(()=>Me.value&&ze.value);function _e(a){let i="";const n=k.value.availableRoomGroups.find(m=>m.roomGroupId===a);return n&&n.name&&(i=n.name),i}const U=d(()=>{const a=[];for(const i in u.value)if(u.value[i]!==0){const n=i.split(".");for(let m=0;m<u.value[i];m++)a.push({roomName:_e(parseInt(n[0])),roomGroupID:parseInt(n[0]),ratePlanID:parseInt(n[1]),adults:parseInt(n[2]),children:parseInt(n[3]),guestName:"",guestNameTitle:1,guestEmail:"",guestPhone:""})}return a}),ct=d(()=>{const a=[];for(const i in u.value)if(u.value[i]!==0){const n=i.split(".");let m,f=0;const P=parseInt(n[1]);parseInt(n[4])!==0&&(m=parseInt(n[4])),isNaN(P)||(f=Le(parseInt(n[0]),P)),a.push({name:_e(parseInt(n[0])),roomGroupID:parseInt(n[0]),ratePlanID:P,amount:u.value[i],adults:parseInt(n[2]),children:parseInt(n[3]),index:m,price:f})}return a});function dt(a,i){return`[REMARKS]: ${Fe.value} \r
|
|
2
|
+
[ALLERGIES]: ${Ne.value} \r
|
|
3
|
+
[REQUESTED ARRIVAL]: ${a} \r
|
|
4
|
+
[REQUESTED DEPARTURE]: ${i}`}function Ee(a,i,n,m){const P=(i?n:m?X.value:Ce.value).split(":");return Bt(new Date(a).setUTCHours(parseInt(P[0]),parseInt(P[1]),0,0))}function x(a){return qe(D.value,A.value)*a}const vt=d(()=>{let a=0;if(!isNaN(F.value)&&!isNaN(b.value))a+=be.value&&be.value.extraPrice||0,a+=K.value&&K.value.weekendFee||0;else for(const i in u.value){const n=u.value[i];if(n!==0){const m=i.split("."),f=k.value.ratesByOccupants.flatMap(P=>P.occupantRates).find(P=>P.roomGroupID===parseInt(m[0])&&P.ratePlanID===parseInt(m[1])&&P.adultsCount===parseInt(m[2])&&P.childrenCount===parseInt(m[3]));f&&f.totalPrice&&(a+=f.totalPrice*n)}}if(O.value){for(const i in O.value)if(O.value[i]){const m=i.split("."),f=k.value.availableRoomAddons[parseInt(m[0])].find(P=>P.addonID===parseInt(m[1]));if(f&&f.price)switch(f.quantityStrategy){case M.PerUnit:a+=f.price;break;case M.PerNight:a+=x(f.price);break;case M.PerAdultPerNight:a+=x(f.price*parseInt(m[2]));break;case M.PerChildPerNight:a+=x(f.price*parseInt(m[3]));break;case M.OneTimePayment:a+=x(f.price);break}}}return a-=r.value,a}),pt=d(()=>{let a=!1;return U.value.length>0&&k.value.availableRoomAddons[U.value[0].roomGroupID].forEach(i=>{i.quantityStrategy===M.OneTimePayment&&(a=!0)}),a}),mt=d(()=>U.value.map(a=>({adults:a.adults,children:a.children,name:a.roomName,roomGroupID:a.roomGroupID,addons:Ge(a)})));function Ge(a){return k.value.availableRoomAddons[a.roomGroupID].filter(i=>i.quantityStrategy===M.PerAdultPerNight||i.quantityStrategy===M.PerChildPerNight||i.quantityStrategy===M.PerNight||i.quantityStrategy===M.PerUnit)}const gt=d(()=>U.value.flatMap(i=>Ge(i)).length>0);function Le(a,i){let n=0;const m=I.value[`${a}`];for(let f=1;f<=m;f++){const P=I.value[`${a}.${f}.adults`],Ue=I.value[`${a}.${f}.children`]||0,ie=I.value[`${a}.${f}.amount`],Ie=k.value.ratesByOccupants.flatMap(j=>j.occupantRates).find(j=>j.roomGroupID===a&&j.ratePlanID===i&&j.adultsCount===P&&j.childrenCount===Ue);Ie&&Ie.totalPrice&&(n+=Ie.totalPrice*ie)}return n}function ht(a,i=!1){const n={};return g.value.roomFacilities.forEach(m=>{if(m.roomGroupID===a){const f=i?m.categoryID:m.category;n[f]?n[f].push(m):n[f]=[m]}}),n}function ft(a){const i=[];return g.value.roomImages.forEach(n=>{n.roomGroupID===a&&i.push(n)}),i}const yt=d(()=>{if(k.value&&U.value)return k.value.availableRoomAddons[U.value[0].roomGroupID].filter(a=>a.quantityStrategy===M.OneTimePayment)});async function Ve(){try{const a=(await ue.get("https://octopus.freshcase.dk/api/v3/hotel/get-metadata",{params:{language:pe()},headers:{Authorization:T.accessToken,"Fresh-Booking-Ver":"3.3.3"}})).data;g.value=a,v.value=!1}catch{w({message:G.global.t("alert.error.couldntFetchMetadata"),type:"warning"})}}async function Oe(){o.value=1,v.value=!0;try{const a=await ue.get("https://octopus.freshcase.dk/api/v3/hotel/get-availability",{params:{from:D.value,to:A.value,adults:B.value,children:C.value,language:pe()},headers:{Authorization:T.accessToken,"Fresh-Booking-Ver":"3.3.3"}});a.status!==200?w({message:`${G.global.t("booking.other.errorMessage")} (HTTP: ${a.status})`,type:"warning"}):(k.value=a.data,u.value=Ft(a.data.ratesByOccupants),I.value=Nt(a.data.ratesByOccupants),v.value=!1)}catch{w({message:G.global.t("alert.error.couldntFetchListings"),type:"warning"})}}async function kt(a){o.value=3,v.value=!0;const i=[];isNaN(F.value)?U.value.forEach(n=>{const m=[];let f=0;for(const P in O.value)if(O.value[P]){const ie=P.split(".");parseInt(ie[0])===n.roomGroupID&&(m.push({id:f,addonID:parseInt(ie[1]),quantity:1}),f++)}i.push({roomGroupID:n.roomGroupID,ratePlanID:n.ratePlanID,adultsCount:n.adults,childrenCount:n.children,guest:{title:n.guestNameTitle?$e(n.guestNameTitle):"",guestID:0,name:n.guestName?n.guestName:"-",email:n.guestEmail,phone:n.guestPhone,newsmails:le.value},roomAddons:m})}):i.push({templateID:F.value,roomGroupID:b.value,ratePlanID:null,adultsCount:B.value,childrenCount:C.value,guest:{title:$e(he.value),guestID:0,name:oe.value,email:ne.value,phone:se.value,newsmails:le.value}}),await ue.post("https://octopus.freshcase.dk/api/v3/hotel/create-reservation",{fromDate:k.value.fromDate,toDate:k.value.toDate,guest:{travellingFor:R.value,title:$e(he.value),guestID:0,name:oe.value,email:ne.value,firmName:Re.value,phone:se.value,country:Ae.value,address1:ke.value,postal:fe.value,city:ye.value,newsmails:le.value},giftCardCode:S.value,selectedRooms:i,remark:dt(Ee(D.value,N.value,z.value,!0),Ee(A.value,$.value,h.value,!1)),checkoutUrl:window.location.origin,privacyUrl:window.location.origin},{headers:{Authorization:T.accessToken,"Fresh-Booking-Ver":"3.3.3"}}).then(n=>{Be.value=!1,v.value=!1,p.pay({callback:a,response:n.data})}).catch(n=>{if(v.value=!1,o.value=2,n.response){const{status:m}=n.response;w(m===433?{message:G.global.t("alert.error.noRoomAvailable"),type:"error"}:{message:G.global.t("booking.other.errorMessage"),type:"warning"})}else w({message:G.global.t("booking.other.errorMessage"),type:"warning"})})}function bt(){F.value=NaN,b.value=NaN}function _t(){for(const a in u.value)u.value[a]=0}function It(){for(const a in O.value)O.value[a]=!1}function St(a){T.initialize(a),Ve(),Oe(),p.initialize()}return{termsOfService:je,metaData:g,availabilityData:k,isLoading:v,moduleState:o,selection:u,roomSelection:I,templateID:F,roomGroupID:b,travelingFor:R,arrivalTime:X,departureTime:Ce,name:oe,nameTitle:he,email:ne,phone:se,firmName:Re,postal:fe,city:ye,country:Ae,address:ke,remark:Fe,allergies:Ne,newsMails:le,addons:O,hasRoomAddons:gt,renderRoomAddons:mt,isPaymentInitialized:Be,nights:Ze,currency:Je,calculateRoomPrice:Le,hotelCountry:xe,countries:et,title:tt,slideshow:at,isMetaDataAvailable:ot,isAvailabilityDataAvailable:nt,totalPrice:vt,selectedPackage:K,getFacilities:ht,getImages:ft,oneTimePaymentAddons:yt,isPaymentLoading:lt,getSingleListing:rt,getSpecifiedPackageRoom:it,getRoomName:_e,getBasePrice:x,getSelectedPackageRoom:be,selectedRoomsDisplay:ct,selectedRooms:U,hasSelectedRooms:Me,hasOneTimePaymentAddons:pt,isReservationFormFilled:st,canStartReservation:ut,correctRoomConfiguration:ze,fetchMetaData:Ve,fetchAvailabilityData:Oe,createReservation:kt,resetTemplate:bt,resetBookingSelection:_t,resetAddonSelection:It,initialize:St}}),Ot={key:0,class:"booking-availability-listing-featured"},Ut=["onClick"],Ht=["src"],qt={class:"booking-availability-listing-details"},Xt={key:0},Kt={class:"booking-availability-listing-description"},Yt={key:0},Qt=["innerHTML"],Wt={key:0},jt=["innerHTML"],Zt={key:0,class:"booking-availability-listing-details-facilities"},Jt={class:"booking-availability-listing-action"},xt=te({__name:"Base",props:{name:{},currency:{},description:{},listingId:{},gallery:{},styling:{},layout:{default:re.Selective},pricesFrom:{},trackingEnabled:{type:Boolean,default:!1},callback:{}},setup(T){const p=T,{t:S}=ge(),{getFacilities:r}=Vt(),{disablePricesFrom:w}=q(we()),B=_(!w&&!!p.pricesFrom),C=_(!1),D=_(null),A=_(0);function z(o){A.value=o.currentSlide}function h(){C.value=!0}function N(o){let u;switch(o){case"26":u="shower";break;case"27":u="tv";break;case"28":u="bed";break;case"29":u="wifi";break;case"32":u="pump-soap";break;case"30":u="mountains";break;default:u=void 0}return u}function $(o){let u=!1;for(let I in o)N(I)&&(u=!0);return u}function g(o){let u="";return o.forEach(I=>{u+=`<li>${I.name}</li>`}),`<ul>${u}</ul>`}function k(o){D.value.goTo(o)}function v(){D.value&&D.value.reload()}return $t(()=>setTimeout(()=>v(),500)),(o,u)=>{const I=Pe("snip"),F=Pe("tooltip");return s(),c("li",{class:Q(["booking-availability-listing",{"no-gallery":o.gallery===void 0||o.gallery.length===0}])},[o.gallery?(s(),c("div",Ot,[typeof o.gallery=="string"?(s(),ee(t(Se),{key:0,src:o.gallery,zoomScale:1,zoomType:"hover",width:420,height:230,zoomPreload:!0,fullscreenOnMobile:!1},null,8,["src"])):o.gallery.length===1?(s(),ee(t(Se),{key:1,src:o.gallery[0]["1x"],zoomSrc:o.gallery[0]["2x"],zoomScale:1,zoomType:"hover",width:420,height:230,zoomPreload:!0,fullscreenOnMobile:!1},null,8,["src","zoomSrc"])):o.gallery.length>1?(s(),ee(t(Dt),{ref_key:"bookingSlider",ref:D,fade:!0,"nav-buttons":!1,dots:!1,key:o.gallery.length,onAfterChange:u[0]||(u[0]=b=>z(b))},{default:Pt(()=>[(s(!0),c(Z,null,J(o.gallery,(b,R)=>(s(),c("div",{key:R,class:"booking-availability-listing-featured-img",style:{maxHeight:"230px",maxWidth:"420px"}},[H(t(Se),{src:b["1x"],zoomSrc:b["2x"],zoomScale:1,zoomType:"hover",width:420,height:230,zoomPreload:!0,fullscreenOnMobile:!1},null,8,["src","zoomSrc"])]))),128))]),_:1})):y("",!0)])):y("",!0),o.gallery&&typeof o.gallery!="string"&&o.gallery.length>1?(s(),c("div",{key:1,class:Q(["booking-availability-listing-gallery",{"small-gallery":o.gallery.length>6}])},[e("ul",null,[(s(!0),c(Z,null,J(o.gallery,(b,R)=>(s(),c("li",{key:R,class:Q({active:R===A.value}),onClick:ce(X=>k(R),["prevent"])},[e("img",{src:b.thumb,width:"132",height:"72"},null,8,Ht)],10,Ut))),128))])],2)):y("",!0),e("div",qt,[e("div",{class:Q(["fresh-booking-listing-title",{"has-from-price":B.value}])},[e("h3",null,[e("span",null,l(o.name),1),o.layout!==t(re).Event&&o.description!==void 0?(s(),c("button",{key:0,class:"booking-availability-listing-read-more",type:"button",onClick:u[1]||(u[1]=ce(b=>o.callback(),["prevent"]))},[H(me,{icon:"info-circle","icon-color":o.styling.headerColor},null,8,["icon-color"])])):y("",!0)]),B.value?(s(),c("b",Xt,[e("span",null,l(`${t(S)("general.pricesFrom")}: ${t(E)(o.pricesFrom,o.currency)}`),1)])):y("",!0)],2),e("div",Kt,[o.layout!==t(re).Event&&o.description?(s(),c("div",Yt,[ve(e("p",{innerHTML:t(Xe)(o.description)},null,8,Qt),[[I,{lines:$(t(r)(o.listingId,!0))?2:4,onSnipped:h}]]),C.value?(s(),c("span",Wt,[e("a",{href:"#",onClick:u[2]||(u[2]=ce(b=>o.callback(),["prevent"]))},l(t(S)("general.readMore")),1)])):y("",!0)])):o.description?(s(),c("p",{key:1,innerHTML:t(Xe)(o.description)},null,8,jt)):y("",!0)]),o.layout!==t(re).Event?(s(),c("ul",Zt,[(s(!0),c(Z,null,J(t(r)(o.listingId,!0),(b,R)=>ve((s(),c("li",{key:R},[N(R)?(s(),ee(me,{key:0,icon:N(R),"icon-color":o.styling.headerColor},null,8,["icon","icon-color"])):y("",!0)])),[[F,{content:g(b),classes:["tooltip","freshcase-octopus-tooltip"],container:"#fresh-booking-hotel-module",html:!0}]])),128))])):y("",!0),W(o.$slots,"description")]),e("div",Jt,[W(o.$slots,"action")])],2)}}});const so=ae(xt,[["__scopeId","data-v-3aa82b29"]]),ea={id:"fresh-booking-multi-step-form-navigation"},ta={key:0,id:"fresh-booking-multi-step-form-overlay"},aa=["src"],oa={id:"fresh-booking-multi-step-form-steps-wrapper"},na={key:0},sa={key:1},la={class:"fresh-booking-multi-steps"},ia={style:{fontSize:"18px"}},ra={id:"fresh-booking-multi-step-form-content"},ua=te({__name:"MultiStepForm",props:{slideshow:{},layout:{default:Y.Default},title:{},subtitle:{}},setup(T){const p=_(0),S=_(),{t:r}=ge(),w=[{id:"availability",label:r("booking.availability.title"),icon:"search"},{id:"reservation",label:r("booking.reservation.title"),icon:"concierge-bell"},{id:"payment",hidden:!0},{id:"confirmation",label:r("booking.confirmation.title"),icon:"calendar-check"}],B=d(()=>w.filter(h=>!h.hidden)),C=d(()=>w[p.value].id),D=()=>{S.value!==void 0&&S.value.scrollIntoView({behavior:"smooth"})},A=(h=1)=>{D(),p.value=p.value+h},z=()=>{D(),p.value--};return(h,N)=>(s(),c("div",{id:"fresh-booking-multi-step-form",ref_key:"multiStepForm",ref:S,class:Q({minimal:h.layout===t(Y).Minimal})},[e("div",null,[e("header",ea,[h.layout!==t(Y).Minimal?(s(),c("div",ta)):y("",!0),h.layout!==t(Y).Minimal&&h.slideshow?(s(),c("img",{key:1,src:h.slideshow[0]},null,8,aa)):y("",!0),e("div",oa,[e("div",null,[h.title&&h.layout!==t(Y).Minimal?(s(),c("h2",na,[e("span",null,l(h.title),1)])):y("",!0),h.subtitle&&h.layout!==t(Y).Minimal?(s(),c("h5",sa,[e("span",null,l(h.subtitle),1)])):y("",!0),e("ul",la,[(s(!0),c(Z,null,J(B.value,$=>(s(),c("li",{key:$.id,class:Q({"is-active":C.value===$.id})},[$.icon?(s(),ee(me,{key:0,icon:$.icon,type:"fas","icon-color":h.layout!==t(Y).Minimal?"#fff":void 0,style:{fontSize:"18px"}},null,8,["icon","icon-color"])):y("",!0),e("b",ia,l($.label),1)],2))),128))])])])]),e("ul",ra,[(s(),c(Z,null,J(w,$=>e("li",{key:$.id,class:"fresh-booking-multi-step-form-content-tab"},[ve(e("div",null,[W(h.$slots,$.id,{next:A,prev:z},void 0,!0)],512),[[wt,C.value===$.id]])])),64))])])],2))}});const lo=ae(ua,[["__scopeId","data-v-edf115c0"]]),ca={id:"fresh-booking-reservation-layout","sticky-container":""},da={id:"fresh-booking-reservation-layout-content"},va={id:"fresh-booking-reservation-layout-form"},pa={id:"fresh-booking-reservation-layout-remarks"},ma={id:"fresh-booking-reservation-layout-aside"},ga={class:"fresh-booking-panel"},ha={id:"fresh-booking-reservation-layout-aside-resume"},fa={key:0},ya={key:1},ka={key:2},ba={key:3},_a={key:0,class:"fresh-booking-panel"},Ia={id:"fresh-booking-reservation-layout-aside-gift-card"},Sa={key:1,class:"fresh-booking-panel"},$a={id:"fresh-booking-reservation-layout-aside-addons"},Pa=["innerHTML"],Da={key:0,id:"fresh-booking-reservation-layout-recaptcha"},wa={id:"fresh-booking-reservation-layout-footer","sticky-side":"bottom"},Ta={id:"fresh-booking-reservation-layout-footer-navigation"},Ca=te({__name:"ReservationForm",props:{isFilled:{type:Boolean},isLoading:{type:Boolean,default:!1},remark:{},currency:{},totalPrice:{},basePrice:{default:0},weekendFee:{default:0},roomUpgrade:{default:0},buttonIconColor:{},notice:{},styling:{}},emits:["update:remark","next","prev"],setup(T,{emit:p}){const S=T,{t:r}=ge(),{disableGiftCardVoucher:w,isRecaptchaEnabled:B}=q(we()),{amount:C,voucher:D}=q(De()),{apply:A,reset:z}=De(),h=Tt(),N=()=>p("next"),$=()=>p("prev"),g=d({get:()=>S.remark,set:v=>p("update:remark",v)}),k=d(()=>S.basePrice-S.weekendFee-S.roomUpgrade);return(v,o)=>{const u=Pe("sticky");return s(),c("div",ca,[e("div",da,[e("div",va,[e("h4",null,[e("span",null,l(t(r)("booking.reservation.detailsTitle")),1)]),e("form",null,[W(v.$slots,"form")])]),e("div",pa,[H(Gt,{modelValue:g.value,"onUpdate:modelValue":o[0]||(o[0]=I=>g.value=I),type:"textarea",label:`${t(r)("booking.reservation.remark")} (${t(r)("booking.reservation.optional")})`,icon:"info-circle",placeholder:t(r)("booking.reservation.remarkPlaceholder")},null,8,["modelValue","label","placeholder"])]),e("aside",ma,[e("div",ga,[e("h5",null,[e("span",null,l(t(r)("booking.reservation.resumeTitle")),1)]),e("ul",ha,[W(v.$slots,"resume"),k.value>0?(s(),c("li",fa,[e("span",null,l(t(r)("booking.availability.basePrice")),1),e("b",null,l(t(E)(k.value,v.currency)),1)])):y("",!0),v.weekendFee>0?(s(),c("li",ya,[e("span",null,l(t(r)("general.weekendFee")),1),e("b",null,l(t(E)(v.weekendFee,v.currency)),1)])):y("",!0),v.roomUpgrade>0?(s(),c("li",ka,[e("span",null,l(t(r)("general.roomUpgrade")),1),e("b",null,l(t(E)(v.roomUpgrade,v.currency)),1)])):y("",!0),W(v.$slots,"expenses"),t(C)!==0?(s(),c("li",ba,[e("span",null,[e("span",null,l(t(r)("booking.reservation.giftCardDiscount")),1),e("a",{class:"resume-item-remove",onClick:o[1]||(o[1]=ce(I=>t(z)(),["prevent"]))},[H(me,{icon:"times",type:"fas","icon-color":"#ff0000"})])]),e("b",null,[e("span",null,l(t(E)(-t(C),v.currency)),1)])])):y("",!0),e("li",null,[e("span",null,l(t(r)("booking.reservation.totalPrice")),1),e("b",null,[e("u",null,l(t(E)(v.totalPrice,v.currency)),1)])])])]),t(C)===0&&!t(w)?(s(),c("div",_a,[e("h5",null,[e("span",null,l(t(r)("booking.reservation.giftCardCode")),1)]),e("div",Ia,[H(Et,{modelValue:t(D),"onUpdate:modelValue":o[2]||(o[2]=I=>Ct(D)?D.value=I:null),icon:"gift-card","button-icon":"paper-plane-top","button-icon-color":v.buttonIconColor,placeholder:"XXXXXXXX",action:"success",secondary:!0,onAction:o[3]||(o[3]=I=>t(A)())},null,8,["modelValue","button-icon-color"])])])):y("",!0),t(h).addons?(s(),c("div",Sa,[e("h5",null,[e("span",null,l(t(r)("booking.reservation.addons")),1)]),e("ul",$a,[W(v.$slots,"addons")])])):y("",!0),v.notice?(s(),c("p",{key:2,innerHTML:v.notice,class:"fresh-booking-wysiwyg"},null,8,Pa)):y("",!0)]),t(B)?(s(),c("div",Da,[H(Lt)])):y("",!0)]),ve((s(),c("div",wa,[e("div",Ta,[e("ul",null,[H(Ke,{label:t(r)("general.abortReservation"),secondary:"",onClickEvent:$},null,8,["label"]),H(Ke,{label:t(r)("general.confirmReservation"),disabled:!v.isFilled,"is-loading":v.isLoading,onClickEvent:N},null,8,["label","disabled","is-loading"])])])])),[[u]])])}}});const io=ae(Ca,[["__scopeId","data-v-52cd04f0"]]),Ra=T=>(Rt("data-v-46bb2543"),T=T(),At(),T),Aa=Ra(()=>e("div",{id:"fresh-booking-payment-checkout"},null,-1)),Fa=[Aa],Na=te({__name:"CheckoutWindow",setup(T){const{paymentGateway:p}=q(Te());return(S,r)=>(s(),c("div",null,[e("div",{id:"fresh-booking-payment-checkout-wrapper",class:Q({reePay:t(p)===t(de).ReePay})},Fa,2)]))}});const ro=ae(Na,[["__scopeId","data-v-46bb2543"]]),Ba={id:"fresh-booking-confirmation"},za={id:"fresh-booking-confirmation-introduction"},Ma={id:"fresh-booking-confirmation-title"},Ea=["innerHTML"],Ga={class:"fresh-booking-order-panel"},La={key:0},Va={class:"fresh-booking-order-panel"},Oa={class:"fresh-booking-order-lines"},Ua={key:0},Ha={key:1},qa={key:0,class:"fresh-booking-order-panel"},Xa={class:"fresh-booking-table with-lines"},Ka={class:"fresh-booking-order-lines"},Ya={key:0},Qa={key:1},Wa={key:2,class:"highlighted-line"},ja=te({__name:"ThankYou",props:{message:{},currency:{}},setup(T){const{t:p}=ge(),{hasOrderLines:S,orderSummary:r,name:w,email:B,phone:C,adults:D,children:A,offerDate:z,totalPrice:h,totalVAT:N,subTotalPrice:$}=q(Te());return(g,k)=>(s(),c("div",Ba,[e("div",za,[e("h2",Ma,[e("span",null,l(t(p)("general.thankYou")),1)]),e("div",{id:"fresh-booking-confirmation-message",innerHTML:g.message},null,8,Ea)]),e("div",Ga,[e("h5",null,[e("span",null,l(t(p)("general.primaryContact")),1)]),e("div",null,l(t(w)),1),e("div",null,l(t(B)),1),t(C)?(s(),c("div",La,l(t(C)),1)):y("",!0)]),e("div",Va,[e("h5",null,[e("span",null,l(t(p)("booking.reservation.detailsTitle")),1)]),e("ul",Oa,[t(z)?(s(),c("li",Ua,[e("span",null,l(t(p)("general.date")),1),e("b",null,l(t(zt)(t(z))),1)])):y("",!0),e("li",null,[e("span",null,l(t(p)("availability.adults")),1),e("b",null,l(t(D)),1)]),t(A)&&t(A)>0?(s(),c("li",Ha,[e("span",null,l(t(p)("availability.children")),1),e("b",null,l(t(A)),1)])):y("",!0)])]),t(S)?(s(),c("div",qa,[e("h5",null,[e("span",null,l(t(p)("general.orderDetails")),1)]),e("table",Xa,[e("thead",null,[e("tr",null,[e("th",null,l(t(p)("general.orderItem")),1),e("th",null,l(t(p)("general.quantity")),1),e("th",null,l(t(p)("booking.availability.price")),1),e("th",null,l(t(p)("booking.reservation.totalPrice")),1)])]),e("tbody",null,[(s(!0),c(Z,null,J(t(r),({productName:v,quantity:o,unitPrice:u,totalPrice:I})=>(s(),c("tr",{key:v},[e("td",null,[e("span",null,l(v),1)]),e("td",null,[e("span",null,l(o),1)]),e("td",null,[e("span",null,l(t(E)(u,g.currency)),1)]),e("td",null,[e("span",null,l(t(E)(I,g.currency)),1)])]))),128))])])])):y("",!0),e("ul",Ka,[t($)?(s(),c("li",Ya,[e("span",null,l(t(p)("general.subTotal")),1),e("b",null,l(t(E)(t($),g.currency)),1)])):y("",!0),t(N)?(s(),c("li",Qa,[e("span",null,l(t(p)("general.vat")),1),e("b",null,l(t(E)(t(N),g.currency)),1)])):y("",!0),t(h)?(s(),c("li",Wa,[e("span",null,l(t(p)("booking.reservation.totalPrice")),1),e("b",null,l(t(E)(t(h),g.currency)),1)])):y("",!0)])]))}});const uo=ae(ja,[["__scopeId","data-v-a0a9141a"]]);export{so as B,ro as C,lo as M,io as R,uo as T,Vt as a,Te as u};
|
|
5
|
+
//# sourceMappingURL=ThankYou-670c2cca.js.map
|
|
Binary file
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{b as p,r as t,J as u,f as m,m as y}from"./vendor-7782fc29.js";import{_ as s}from"./DateField.vue_vue_type_style_index_0_lang-f5878599.js";const B=p({__name:"TimeField",props:{modelValue:{},label:{},id:{},name:{},placeholder:{},icon:{},iconColor:{},iconType:{},primaryColor:{},secondaryColor:{},weekendColor:{},highlightedColor:{},required:{type:Boolean},readonly:{type:Boolean},disabled:{type:Boolean},inline:{type:Boolean},range:{type:Boolean},enableTimePicker:{type:Boolean},inputStyle:{}},emits:["update:modelValue"],setup(a,{emit:n}){const i=a;function r(e){n("update:modelValue",e)}const o=t(i.modelValue);return u(o,e=>{r(e)}),(e,l)=>(m(),y(s,{modelValue:o.value,"onUpdate:modelValue":l[0]||(l[0]=d=>o.value=d),type:"time",label:e.label,id:e.id,name:e.name,icon:e.icon,"icon-type":e.iconType,"icon-color":e.iconColor,"auto-apply":!0,required:e.required,readonly:e.readonly},null,8,["modelValue","label","id","name","icon","icon-type","icon-color","required","readonly"]))}});export{B as _};
|
|
2
|
+
//# sourceMappingURL=TimeField.vue_vue_type_style_index_0_lang-8f7003f1.js.map
|