holidoit 1.0.185 → 1.0.187

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (46) hide show
  1. package/dist/embed.html +1 -1
  2. package/dist/holidoit-embed.js +1 -1
  3. package/dist/holidoit-js-releases/{20261202095359217-a04cce2cb673-134cda53 → 20261204090104486-2a8b6fd1848e-dfb1891e}/holidoit-embed.js +1 -1
  4. package/dist/holidoit-js-releases/20261204090104486-2a8b6fd1848e-dfb1891e/holidoit.js +2 -0
  5. package/dist/holidoit-js-releases/20261204090104486-2a8b6fd1848e-dfb1891e/holidoit.umd.js +2 -0
  6. package/dist/holidoit-js-releases/{20261202095359217-a04cce2cb673-134cda53 → 20261204090104486-2a8b6fd1848e-dfb1891e}/widgets/experience-grid-drawer-loader.js +1 -1
  7. package/dist/holidoit-js-releases/20261204090104486-2a8b6fd1848e-dfb1891e/widgets/experience-page-drawer-loader.js +2 -0
  8. package/dist/holidoit-js-releases/{20261202095359217-a04cce2cb673-134cda53 → 20261204090104486-2a8b6fd1848e-dfb1891e}/widgets/inline-book-now-loader.js +1 -1
  9. package/dist/holidoit-js-releases/{20261202095359217-a04cce2cb673-134cda53 → 20261204090104486-2a8b6fd1848e-dfb1891e}/widgets/widget-booking-box.js +1 -1
  10. package/dist/holidoit-js-releases/{20261202095359217-a04cce2cb673-134cda53 → 20261204090104486-2a8b6fd1848e-dfb1891e}/widgets/widget-experience-grid-drawer.js +1 -1
  11. package/dist/holidoit-js-releases/20261204090104486-2a8b6fd1848e-dfb1891e/widgets/widget-experience-grid.js +2 -0
  12. package/dist/holidoit-js-releases/{20261202095359217-a04cce2cb673-134cda53 → 20261204090104486-2a8b6fd1848e-dfb1891e}/widgets/widget-experience-page-drawer.js +1 -1
  13. package/dist/holidoit-js-releases/{20261202095359217-a04cce2cb673-134cda53 → 20261204090104486-2a8b6fd1848e-dfb1891e}/widgets/widget-experience.js +1 -1
  14. package/dist/holidoit-js-releases/{20261202095359217-a04cce2cb673-134cda53 → 20261204090104486-2a8b6fd1848e-dfb1891e}/widgets/widgets-loader.js +1 -1
  15. package/dist/holidoit.js +1 -1
  16. package/dist/holidoit.umd.js +1 -1
  17. package/dist/release-manifest.json +25 -25
  18. package/dist/widgets/experience-grid-drawer-loader.js +1 -1
  19. package/dist/widgets/experience-page-drawer-loader.js +1 -1
  20. package/dist/widgets/inline-book-now-loader.js +1 -1
  21. package/dist/widgets/widget-book-now-button.html +1 -1
  22. package/dist/widgets/widget-booking-box.html +1 -1
  23. package/dist/widgets/widget-booking-box.js +1 -1
  24. package/dist/widgets/widget-experience-grid-drawer.html +1 -1
  25. package/dist/widgets/widget-experience-grid-drawer.js +1 -1
  26. package/dist/widgets/widget-experience-grid.html +1 -1
  27. package/dist/widgets/widget-experience-grid.js +1 -1
  28. package/dist/widgets/widget-experience-page-drawer.html +1 -1
  29. package/dist/widgets/widget-experience-page-drawer.js +1 -1
  30. package/dist/widgets/widget-experience.html +1 -1
  31. package/dist/widgets/widget-experience.js +1 -1
  32. package/dist/widgets/widgets-loader.js +1 -1
  33. package/package.json +1 -1
  34. package/dist/holidoit-js-releases/20261202095359217-a04cce2cb673-134cda53/holidoit.js +0 -2
  35. package/dist/holidoit-js-releases/20261202095359217-a04cce2cb673-134cda53/holidoit.umd.js +0 -2
  36. package/dist/holidoit-js-releases/20261202095359217-a04cce2cb673-134cda53/widgets/experience-page-drawer-loader.js +0 -2
  37. package/dist/holidoit-js-releases/20261202095359217-a04cce2cb673-134cda53/widgets/widget-experience-grid.js +0 -2
  38. /package/dist/holidoit-js-releases/{20261202095359217-a04cce2cb673-134cda53 → 20261204090104486-2a8b6fd1848e-dfb1891e}/embed.html +0 -0
  39. /package/dist/holidoit-js-releases/{20261202095359217-a04cce2cb673-134cda53 → 20261204090104486-2a8b6fd1848e-dfb1891e}/payment-redirect.html +0 -0
  40. /package/dist/holidoit-js-releases/{20261202095359217-a04cce2cb673-134cda53 → 20261204090104486-2a8b6fd1848e-dfb1891e}/widgets/widget-book-now-button.html +0 -0
  41. /package/dist/holidoit-js-releases/{20261202095359217-a04cce2cb673-134cda53 → 20261204090104486-2a8b6fd1848e-dfb1891e}/widgets/widget-book-now-button.js +0 -0
  42. /package/dist/holidoit-js-releases/{20261202095359217-a04cce2cb673-134cda53 → 20261204090104486-2a8b6fd1848e-dfb1891e}/widgets/widget-booking-box.html +0 -0
  43. /package/dist/holidoit-js-releases/{20261202095359217-a04cce2cb673-134cda53 → 20261204090104486-2a8b6fd1848e-dfb1891e}/widgets/widget-experience-grid-drawer.html +0 -0
  44. /package/dist/holidoit-js-releases/{20261202095359217-a04cce2cb673-134cda53 → 20261204090104486-2a8b6fd1848e-dfb1891e}/widgets/widget-experience-grid.html +0 -0
  45. /package/dist/holidoit-js-releases/{20261202095359217-a04cce2cb673-134cda53 → 20261204090104486-2a8b6fd1848e-dfb1891e}/widgets/widget-experience-page-drawer.html +0 -0
  46. /package/dist/holidoit-js-releases/{20261202095359217-a04cce2cb673-134cda53 → 20261204090104486-2a8b6fd1848e-dfb1891e}/widgets/widget-experience.html +0 -0
@@ -1 +1 @@
1
- !function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define("HolidoitWidgets",[],e):"object"==typeof exports?exports.HolidoitWidgets=e():t.HolidoitWidgets=e()}(this,()=>(()=>{var t={317:function(t,e,n){t.exports=function(t){"use strict";function e(t){return t&&"object"==typeof t&&"default"in t?t:{default:t}}var n=e(t),r={name:"es",monthsShort:"ene_feb_mar_abr_may_jun_jul_ago_sep_oct_nov_dic".split("_"),weekdays:"domingo_lunes_martes_miércoles_jueves_viernes_sábado".split("_"),weekdaysShort:"dom._lun._mar._mié._jue._vie._sáb.".split("_"),weekdaysMin:"do_lu_ma_mi_ju_vi_sá".split("_"),months:"enero_febrero_marzo_abril_mayo_junio_julio_agosto_septiembre_octubre_noviembre_diciembre".split("_"),weekStart:1,formats:{LT:"H:mm",LTS:"H:mm:ss",L:"DD/MM/YYYY",LL:"D [de] MMMM [de] YYYY",LLL:"D [de] MMMM [de] YYYY H:mm",LLLL:"dddd, D [de] MMMM [de] YYYY H:mm"},relativeTime:{future:"en %s",past:"hace %s",s:"unos segundos",m:"un minuto",mm:"%d minutos",h:"una hora",hh:"%d horas",d:"un día",dd:"%d días",M:"un mes",MM:"%d meses",y:"un año",yy:"%d años"},ordinal:function(t){return t+"º"}};return n.default.locale(r,null,!0),r}(n(353))},353:function(t){t.exports=function(){"use strict";var t=1e3,e=6e4,n=36e5,r="millisecond",i="second",a="minute",o="hour",s="day",u="week",l="month",d="quarter",c="year",f="date",m="Invalid Date",h=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,p=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,g={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(t){var e=["th","st","nd","rd"],n=t%100;return"["+t+(e[(n-20)%10]||e[n]||e[0])+"]"}},y=function(t,e,n){var r=String(t);return!r||r.length>=e?t:""+Array(e+1-r.length).join(n)+t},v={s:y,z:function(t){var e=-t.utcOffset(),n=Math.abs(e),r=Math.floor(n/60),i=n%60;return(e<=0?"+":"-")+y(r,2,"0")+":"+y(i,2,"0")},m:function t(e,n){if(e.date()<n.date())return-t(n,e);var r=12*(n.year()-e.year())+(n.month()-e.month()),i=e.clone().add(r,l),a=n-i<0,o=e.clone().add(r+(a?-1:1),l);return+(-(r+(n-i)/(a?i-o:o-i))||0)},a:function(t){return t<0?Math.ceil(t)||0:Math.floor(t)},p:function(t){return{M:l,y:c,w:u,d:s,D:f,h:o,m:a,s:i,ms:r,Q:d}[t]||String(t||"").toLowerCase().replace(/s$/,"")},u:function(t){return void 0===t}},w="en",_={};_[w]=g;var b="$isDayjsObject",M=function(t){return t instanceof $||!(!t||!t[b])},T=function t(e,n,r){var i;if(!e)return w;if("string"==typeof e){var a=e.toLowerCase();_[a]&&(i=a),n&&(_[a]=n,i=a);var o=e.split("-");if(!i&&o.length>1)return t(o[0])}else{var s=e.name;_[s]=e,i=s}return!r&&i&&(w=i),i||!r&&w},S=function(t,e){if(M(t))return t.clone();var n="object"==typeof e?e:{};return n.date=t,n.args=arguments,new $(n)},A=v;A.l=T,A.i=M,A.w=function(t,e){return S(t,{locale:e.$L,utc:e.$u,x:e.$x,$offset:e.$offset})};var $=function(){function g(t){this.$L=T(t.locale,null,!0),this.parse(t),this.$x=this.$x||t.x||{},this[b]=!0}var y=g.prototype;return y.parse=function(t){this.$d=function(t){var e=t.date,n=t.utc;if(null===e)return new Date(NaN);if(A.u(e))return new Date;if(e instanceof Date)return new Date(e);if("string"==typeof e&&!/Z$/i.test(e)){var r=e.match(h);if(r){var i=r[2]-1||0,a=(r[7]||"0").substring(0,3);return n?new Date(Date.UTC(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,a)):new Date(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,a)}}return new Date(e)}(t),this.init()},y.init=function(){var t=this.$d;this.$y=t.getFullYear(),this.$M=t.getMonth(),this.$D=t.getDate(),this.$W=t.getDay(),this.$H=t.getHours(),this.$m=t.getMinutes(),this.$s=t.getSeconds(),this.$ms=t.getMilliseconds()},y.$utils=function(){return A},y.isValid=function(){return!(this.$d.toString()===m)},y.isSame=function(t,e){var n=S(t);return this.startOf(e)<=n&&n<=this.endOf(e)},y.isAfter=function(t,e){return S(t)<this.startOf(e)},y.isBefore=function(t,e){return this.endOf(e)<S(t)},y.$g=function(t,e,n){return A.u(t)?this[e]:this.set(n,t)},y.unix=function(){return Math.floor(this.valueOf()/1e3)},y.valueOf=function(){return this.$d.getTime()},y.startOf=function(t,e){var n=this,r=!!A.u(e)||e,d=A.p(t),m=function(t,e){var i=A.w(n.$u?Date.UTC(n.$y,e,t):new Date(n.$y,e,t),n);return r?i:i.endOf(s)},h=function(t,e){return A.w(n.toDate()[t].apply(n.toDate("s"),(r?[0,0,0,0]:[23,59,59,999]).slice(e)),n)},p=this.$W,g=this.$M,y=this.$D,v="set"+(this.$u?"UTC":"");switch(d){case c:return r?m(1,0):m(31,11);case l:return r?m(1,g):m(0,g+1);case u:var w=this.$locale().weekStart||0,_=(p<w?p+7:p)-w;return m(r?y-_:y+(6-_),g);case s:case f:return h(v+"Hours",0);case o:return h(v+"Minutes",1);case a:return h(v+"Seconds",2);case i:return h(v+"Milliseconds",3);default:return this.clone()}},y.endOf=function(t){return this.startOf(t,!1)},y.$set=function(t,e){var n,u=A.p(t),d="set"+(this.$u?"UTC":""),m=(n={},n[s]=d+"Date",n[f]=d+"Date",n[l]=d+"Month",n[c]=d+"FullYear",n[o]=d+"Hours",n[a]=d+"Minutes",n[i]=d+"Seconds",n[r]=d+"Milliseconds",n)[u],h=u===s?this.$D+(e-this.$W):e;if(u===l||u===c){var p=this.clone().set(f,1);p.$d[m](h),p.init(),this.$d=p.set(f,Math.min(this.$D,p.daysInMonth())).$d}else m&&this.$d[m](h);return this.init(),this},y.set=function(t,e){return this.clone().$set(t,e)},y.get=function(t){return this[A.p(t)]()},y.add=function(r,d){var f,m=this;r=Number(r);var h=A.p(d),p=function(t){var e=S(m);return A.w(e.date(e.date()+Math.round(t*r)),m)};if(h===l)return this.set(l,this.$M+r);if(h===c)return this.set(c,this.$y+r);if(h===s)return p(1);if(h===u)return p(7);var g=(f={},f[a]=e,f[o]=n,f[i]=t,f)[h]||1,y=this.$d.getTime()+r*g;return A.w(y,this)},y.subtract=function(t,e){return this.add(-1*t,e)},y.format=function(t){var e=this,n=this.$locale();if(!this.isValid())return n.invalidDate||m;var r=t||"YYYY-MM-DDTHH:mm:ssZ",i=A.z(this),a=this.$H,o=this.$m,s=this.$M,u=n.weekdays,l=n.months,d=n.meridiem,c=function(t,n,i,a){return t&&(t[n]||t(e,r))||i[n].slice(0,a)},f=function(t){return A.s(a%12||12,t,"0")},h=d||function(t,e,n){var r=t<12?"AM":"PM";return n?r.toLowerCase():r};return r.replace(p,function(t,r){return r||function(t){switch(t){case"YY":return String(e.$y).slice(-2);case"YYYY":return A.s(e.$y,4,"0");case"M":return s+1;case"MM":return A.s(s+1,2,"0");case"MMM":return c(n.monthsShort,s,l,3);case"MMMM":return c(l,s);case"D":return e.$D;case"DD":return A.s(e.$D,2,"0");case"d":return String(e.$W);case"dd":return c(n.weekdaysMin,e.$W,u,2);case"ddd":return c(n.weekdaysShort,e.$W,u,3);case"dddd":return u[e.$W];case"H":return String(a);case"HH":return A.s(a,2,"0");case"h":return f(1);case"hh":return f(2);case"a":return h(a,o,!0);case"A":return h(a,o,!1);case"m":return String(o);case"mm":return A.s(o,2,"0");case"s":return String(e.$s);case"ss":return A.s(e.$s,2,"0");case"SSS":return A.s(e.$ms,3,"0");case"Z":return i}return null}(t)||i.replace(":","")})},y.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},y.diff=function(r,f,m){var h,p=this,g=A.p(f),y=S(r),v=(y.utcOffset()-this.utcOffset())*e,w=this-y,_=function(){return A.m(p,y)};switch(g){case c:h=_()/12;break;case l:h=_();break;case d:h=_()/3;break;case u:h=(w-v)/6048e5;break;case s:h=(w-v)/864e5;break;case o:h=w/n;break;case a:h=w/e;break;case i:h=w/t;break;default:h=w}return m?h:A.a(h)},y.daysInMonth=function(){return this.endOf(l).$D},y.$locale=function(){return _[this.$L]},y.locale=function(t,e){if(!t)return this.$L;var n=this.clone(),r=T(t,e,!0);return r&&(n.$L=r),n},y.clone=function(){return A.w(this.$d,this)},y.toDate=function(){return new Date(this.valueOf())},y.toJSON=function(){return this.isValid()?this.toISOString():null},y.toISOString=function(){return this.$d.toISOString()},y.toString=function(){return this.$d.toUTCString()},g}(),x=$.prototype;return S.prototype=x,[["$ms",r],["$s",i],["$m",a],["$H",o],["$W",s],["$M",l],["$y",c],["$D",f]].forEach(function(t){x[t[1]]=function(e){return this.$g(e,t[0],t[1])}}),S.extend=function(t,e){return t.$i||(t(e,$,S),t.$i=!0),S},S.locale=T,S.isDayjs=M,S.unix=function(t){return S(1e3*t)},S.en=_[w],S.Ls=_,S.p={},S}()},445:function(t){t.exports=function(){"use strict";var t="minute",e=/[+-]\d\d(?::?\d\d)?/g,n=/([+-]|\d\d)/g;return function(r,i,a){var o=i.prototype;a.utc=function(t){return new i({date:t,utc:!0,args:arguments})},o.utc=function(e){var n=a(this.toDate(),{locale:this.$L,utc:!0});return e?n.add(this.utcOffset(),t):n},o.local=function(){return a(this.toDate(),{locale:this.$L,utc:!1})};var s=o.parse;o.parse=function(t){t.utc&&(this.$u=!0),this.$utils().u(t.$offset)||(this.$offset=t.$offset),s.call(this,t)};var u=o.init;o.init=function(){if(this.$u){var t=this.$d;this.$y=t.getUTCFullYear(),this.$M=t.getUTCMonth(),this.$D=t.getUTCDate(),this.$W=t.getUTCDay(),this.$H=t.getUTCHours(),this.$m=t.getUTCMinutes(),this.$s=t.getUTCSeconds(),this.$ms=t.getUTCMilliseconds()}else u.call(this)};var l=o.utcOffset;o.utcOffset=function(r,i){var a=this.$utils().u;if(a(r))return this.$u?0:a(this.$offset)?l.call(this):this.$offset;if("string"==typeof r&&(r=function(t){void 0===t&&(t="");var r=t.match(e);if(!r)return null;var i=(""+r[0]).match(n)||["-",0,0],a=i[0],o=60*+i[1]+ +i[2];return 0===o?0:"+"===a?o:-o}(r),null===r))return this;var o=Math.abs(r)<=16?60*r:r;if(0===o)return this.utc(i);var s=this.clone();if(i)return s.$offset=o,s.$u=!1,s;var u=this.$u?this.toDate().getTimezoneOffset():-1*this.utcOffset();return(s=this.local().add(o+u,t)).$offset=o,s.$x.$localOffset=u,s};var d=o.format;o.format=function(t){var e=t||(this.$u?"YYYY-MM-DDTHH:mm:ss[Z]":"");return d.call(this,e)},o.valueOf=function(){var t=this.$utils().u(this.$offset)?0:this.$offset+(this.$x.$localOffset||this.$d.getTimezoneOffset());return this.$d.valueOf()-6e4*t},o.isUTC=function(){return!!this.$u},o.toISOString=function(){return this.toDate().toISOString()},o.toString=function(){return this.toDate().toUTCString()};var c=o.toDate;o.toDate=function(t){return"s"===t&&this.$offset?a(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate():c.call(this)};var f=o.diff;o.diff=function(t,e,n){if(t&&this.$u===t.$u)return f.call(this,t,e,n);var r=this.local(),i=a(t).local();return f.call(r,i,e,n)}}}()},494:function(t,e,n){t.exports=function(t){"use strict";function e(t){return t&&"object"==typeof t&&"default"in t?t:{default:t}}var n=e(t),r={s:"ein paar Sekunden",m:["eine Minute","einer Minute"],mm:"%d Minuten",h:["eine Stunde","einer Stunde"],hh:"%d Stunden",d:["ein Tag","einem Tag"],dd:["%d Tage","%d Tagen"],M:["ein Monat","einem Monat"],MM:["%d Monate","%d Monaten"],y:["ein Jahr","einem Jahr"],yy:["%d Jahre","%d Jahren"]};function i(t,e,n){var i=r[n];return Array.isArray(i)&&(i=i[e?0:1]),i.replace("%d",t)}var a={name:"de",weekdays:"Sonntag_Montag_Dienstag_Mittwoch_Donnerstag_Freitag_Samstag".split("_"),weekdaysShort:"So._Mo._Di._Mi._Do._Fr._Sa.".split("_"),weekdaysMin:"So_Mo_Di_Mi_Do_Fr_Sa".split("_"),months:"Januar_Februar_März_April_Mai_Juni_Juli_August_September_Oktober_November_Dezember".split("_"),monthsShort:"Jan._Feb._März_Apr._Mai_Juni_Juli_Aug._Sept._Okt._Nov._Dez.".split("_"),ordinal:function(t){return t+"."},weekStart:1,yearStart:4,formats:{LTS:"HH:mm:ss",LT:"HH:mm",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY HH:mm",LLLL:"dddd, D. MMMM YYYY HH:mm"},relativeTime:{future:"in %s",past:"vor %s",s:i,m:i,mm:i,h:i,hh:i,d:i,dd:i,M:i,MM:i,y:i,yy:i}};return n.default.locale(a,null,!0),a}(n(353))},569:function(t){t.exports=function(){"use strict";var t={year:0,month:1,day:2,hour:3,minute:4,second:5},e={};return function(n,r,i){var a,o=function(t,n,r){void 0===r&&(r={});var i=new Date(t),a=function(t,n){void 0===n&&(n={});var r=n.timeZoneName||"short",i=t+"|"+r,a=e[i];return a||(a=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:t,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",timeZoneName:r}),e[i]=a),a}(n,r);return a.formatToParts(i)},s=function(e,n){for(var r=o(e,n),a=[],s=0;s<r.length;s+=1){var u=r[s],l=u.type,d=u.value,c=t[l];c>=0&&(a[c]=parseInt(d,10))}var f=a[3],m=24===f?0:f,h=a[0]+"-"+a[1]+"-"+a[2]+" "+m+":"+a[4]+":"+a[5]+":000",p=+e;return(i.utc(h).valueOf()-(p-=p%1e3))/6e4},u=r.prototype;u.tz=function(t,e){void 0===t&&(t=a);var n,r=this.utcOffset(),o=this.toDate(),s=o.toLocaleString("en-US",{timeZone:t}),u=Math.round((o-new Date(s))/1e3/60),l=15*-Math.round(o.getTimezoneOffset()/15)-u;if(Number(l)){if(n=i(s,{locale:this.$L}).$set("millisecond",this.$ms).utcOffset(l,!0),e){var d=n.utcOffset();n=n.add(r-d,"minute")}}else n=this.utcOffset(0,e);return n.$x.$timezone=t,n},u.offsetName=function(t){var e=this.$x.$timezone||i.tz.guess(),n=o(this.valueOf(),e,{timeZoneName:t}).find(function(t){return"timezonename"===t.type.toLowerCase()});return n&&n.value};var l=u.startOf;u.startOf=function(t,e){if(!this.$x||!this.$x.$timezone)return l.call(this,t,e);var n=i(this.format("YYYY-MM-DD HH:mm:ss:SSS"),{locale:this.$L});return l.call(n,t,e).tz(this.$x.$timezone,!0)},i.tz=function(t,e,n){var r=n&&e,o=n||e||a,u=s(+i(),o);if("string"!=typeof t)return i(t).tz(o);var l=function(t,e,n){var r=t-60*e*1e3,i=s(r,n);if(e===i)return[r,e];var a=s(r-=60*(i-e)*1e3,n);return i===a?[r,i]:[t-60*Math.min(i,a)*1e3,Math.max(i,a)]}(i.utc(t,r).valueOf(),u,o),d=l[0],c=l[1],f=i(d).utcOffset(c);return f.$x.$timezone=o,f},i.tz.guess=function(){return Intl.DateTimeFormat().resolvedOptions().timeZone},i.tz.setDefault=function(t){a=t}}}()},813:function(t,e,n){t.exports=function(t){"use strict";function e(t){return t&&"object"==typeof t&&"default"in t?t:{default:t}}var n=e(t),r={name:"fr",weekdays:"dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi".split("_"),weekdaysShort:"dim._lun._mar._mer._jeu._ven._sam.".split("_"),weekdaysMin:"di_lu_ma_me_je_ve_sa".split("_"),months:"janvier_février_mars_avril_mai_juin_juillet_août_septembre_octobre_novembre_décembre".split("_"),monthsShort:"janv._févr._mars_avr._mai_juin_juil._août_sept._oct._nov._déc.".split("_"),weekStart:1,yearStart:4,formats:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},relativeTime:{future:"dans %s",past:"il y a %s",s:"quelques secondes",m:"une minute",mm:"%d minutes",h:"une heure",hh:"%d heures",d:"un jour",dd:"%d jours",M:"un mois",MM:"%d mois",y:"un an",yy:"%d ans"},ordinal:function(t){return t+(1===t?"er":"")}};return n.default.locale(r,null,!0),r}(n(353))},826:function(t){t.exports=function(){"use strict";return{name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(t){var e=["th","st","nd","rd"],n=t%100;return"["+t+(e[(n-20)%10]||e[n]||e[0])+"]"}}}()},840:function(t){t.exports=function(){"use strict";return function(t,e,n){var r=e.prototype,i=function(t){return t&&(t.indexOf?t:t.s)},a=function(t,e,n,r,a){var o=t.name?t:t.$locale(),s=i(o[e]),u=i(o[n]),l=s||u.map(function(t){return t.slice(0,r)});if(!a)return l;var d=o.weekStart;return l.map(function(t,e){return l[(e+(d||0))%7]})},o=function(){return n.Ls[n.locale()]},s=function(t,e){return t.formats[e]||function(t){return t.replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(t,e,n){return e||n.slice(1)})}(t.formats[e.toUpperCase()])},u=function(){var t=this;return{months:function(e){return e?e.format("MMMM"):a(t,"months")},monthsShort:function(e){return e?e.format("MMM"):a(t,"monthsShort","months",3)},firstDayOfWeek:function(){return t.$locale().weekStart||0},weekdays:function(e){return e?e.format("dddd"):a(t,"weekdays")},weekdaysMin:function(e){return e?e.format("dd"):a(t,"weekdaysMin","weekdays",2)},weekdaysShort:function(e){return e?e.format("ddd"):a(t,"weekdaysShort","weekdays",3)},longDateFormat:function(e){return s(t.$locale(),e)},meridiem:this.$locale().meridiem,ordinal:this.$locale().ordinal}};r.localeData=function(){return u.bind(this)()},n.localeData=function(){var t=o();return{firstDayOfWeek:function(){return t.weekStart||0},weekdays:function(){return n.weekdays()},weekdaysShort:function(){return n.weekdaysShort()},weekdaysMin:function(){return n.weekdaysMin()},months:function(){return n.months()},monthsShort:function(){return n.monthsShort()},longDateFormat:function(e){return s(t,e)},meridiem:t.meridiem,ordinal:t.ordinal}},n.months=function(){return a(o(),"months")},n.monthsShort=function(){return a(o(),"monthsShort","months",3)},n.weekdays=function(t){return a(o(),"weekdays",null,null,t)},n.weekdaysShort=function(t){return a(o(),"weekdaysShort","weekdays",3,t)},n.weekdaysMin=function(t){return a(o(),"weekdaysMin","weekdays",2,t)}}}()},900:function(t,e,n){t.exports=function(t){"use strict";function e(t){return t&&"object"==typeof t&&"default"in t?t:{default:t}}var n=e(t),r={name:"it",weekdays:"domenica_lunedì_martedì_mercoledì_giovedì_venerdì_sabato".split("_"),weekdaysShort:"dom_lun_mar_mer_gio_ven_sab".split("_"),weekdaysMin:"do_lu_ma_me_gi_ve_sa".split("_"),months:"gennaio_febbraio_marzo_aprile_maggio_giugno_luglio_agosto_settembre_ottobre_novembre_dicembre".split("_"),weekStart:1,monthsShort:"gen_feb_mar_apr_mag_giu_lug_ago_set_ott_nov_dic".split("_"),formats:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},relativeTime:{future:"tra %s",past:"%s fa",s:"qualche secondo",m:"un minuto",mm:"%d minuti",h:"un'ora",hh:"%d ore",d:"un giorno",dd:"%d giorni",M:"un mese",MM:"%d mesi",y:"un anno",yy:"%d anni"},ordinal:function(t){return t+"º"}};return n.default.locale(r,null,!0),r}(n(353))}},e={};function n(r){var i=e[r];if(void 0!==i)return i.exports;var a=e[r]={exports:{}};return t[r].call(a.exports,a,a.exports,n),a.exports}n.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return n.d(e,{a:e}),e},n.d=(t,e)=>{for(var r in e)n.o(e,r)&&!n.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},n.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),n.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})};var r={};return(()=>{"use strict";function t(e){return t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},t(e)}function e(e){var n=function(e,n){if("object"!=t(e)||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var i=r.call(e,n||"default");if("object"!=t(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===n?String:Number)(e)}(e,"string");return"symbol"==t(n)?n:n+""}function i(t,n){for(var r=0;r<n.length;r++){var i=n[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,e(i.key),i)}}function a(t,n,r){return(n=e(n))in t?Object.defineProperty(t,n,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[n]=r,t}n.r(r),n.d(r,{holidoitWidgetsLoader:()=>H});var o="HOLIDOIT_ANALYTICS_EVENT";function s(t,e){var n="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!n){if(Array.isArray(t)||(n=function(t,e){if(t){if("string"==typeof t)return u(t,e);var n={}.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?u(t,e):void 0}}(t))||e&&t&&"number"==typeof t.length){n&&(t=n);var r=0,i=function(){};return{s:i,n:function(){return r>=t.length?{done:!0}:{done:!1,value:t[r++]}},e:function(t){throw t},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,o=!0,s=!1;return{s:function(){n=n.call(t)},n:function(){var t=n.next();return o=t.done,t},e:function(t){s=!0,a=t},f:function(){try{o||null==n.return||n.return()}finally{if(s)throw a}}}}function u(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=Array(e);n<e;n++)r[n]=t[n];return r}var l="holidoit_analytics_dedupe_keys",d=new Set;function c(e){return"object"===t(e)&&null!==e&&!Array.isArray(e)}function f(){if("undefined"==typeof window)return null;try{return window.sessionStorage}catch(t){return null}}function m(){var t=f();if(!t)return[];try{var e=t.getItem(l);if(!e)return[];var n=JSON.parse(e);return Array.isArray(n)?n.filter(function(t){return"string"==typeof t&&t.length>0}):[]}catch(t){return[]}}function h(t){if(t){d.add(t);var e=m().filter(function(e){return e!==t});e.push(t),function(t){var e=f();if(e)try{e.setItem(l,JSON.stringify(t.slice(-200)))}catch(t){}}(e)}}function p(t,e){return"undefined"!=typeof window&&(!function(t){return!(!t||!d.has(t)&&(!m().includes(t)||(d.add(t),0)))}(e)&&(Array.isArray(window.dataLayer)||(window.dataLayer=[]),h(e),window.dataLayer.push(t),!0))}function g(t){if(!c(t)||t.type!==o)return null;var e,n=c(t.payload)?t.payload:t,r=n.channel,i=n.dedupeKey,a=n.eventData,s=n.source,u=n.widgetType;return"dataLayer"!==r||"embed"!==s&&"widget"!==s||"string"!=typeof i||""===i.trim()||(!c(e=a)||"string"!=typeof e.event||""===e.event.trim())?null:{channel:r,dedupeKey:i.trim(),eventData:a,source:s,widgetType:"string"==typeof u&&u.trim()?u:void 0}}function y(t){try{return new URL(t,window.location.href).origin}catch(t){return null}}var v=new Set(["holidoit.js","embed.html","payment-redirect.html","widgets/widget-book-now-button.html","widgets/widget-booking-box.html","widgets/widget-experience.html","widgets/widget-experience-grid.html","widgets/widget-experience-grid-drawer.html","widgets/widget-experience-page-drawer.html"]);var w=n(353),_=n.n(w),b=(n(494),n(826),n(317),n(813),n(900),n(840)),M=n.n(b),T=n(569),S=n.n(T),A=n(445),$=n.n(A);_().extend($()),_().extend(S()),_().extend(M());var x=function(t){return t.ITALIAN="it",t.ENGLISH="en",t.SPANISH="es",t.FRENCH="fr",t.GERMAN="de",t}({});_()().locale("it").localeData().months(),_()().locale("it").localeData().weekdays(),_()().locale("en").localeData().months(),_()().locale("en").localeData().weekdays(),_()().locale("de").localeData().months(),_()().locale("de").localeData().weekdays(),_()().locale("es").localeData().months(),_()().locale("es").localeData().weekdays(),_()().locale("fr").localeData().months(),_()().locale("fr").localeData().weekdays();function D(t,e){var n="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!n){if(Array.isArray(t)||(n=function(t,e){if(t){if("string"==typeof t)return L(t,e);var n={}.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?L(t,e):void 0}}(t))||e&&t&&"number"==typeof t.length){n&&(t=n);var r=0,i=function(){};return{s:i,n:function(){return r>=t.length?{done:!0}:{done:!1,value:t[r++]}},e:function(t){throw t},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,o=!0,s=!1;return{s:function(){n=n.call(t)},n:function(){var t=n.next();return o=t.done,t},e:function(t){s=!0,a=t},f:function(){try{o||null==n.return||n.return()}finally{if(s)throw a}}}}function L(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=Array(e);n<e;n++)r[n]=t[n];return r}var C="holidoitWidget",O=48,k=Object.values(x),Y=function(){return t=function t(){var e=this;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),a(this,"config",null),a(this,"widgets",[]),a(this,"isInitialized",!1),a(this,"resizeObserver",null),a(this,"primaryCTAUpdateFrame",null),a(this,"schedulePrimaryCTAUpdate",function(){null===e.primaryCTAUpdateFrame&&(e.primaryCTAUpdateFrame=requestAnimationFrame(function(){e.primaryCTAUpdateFrame=null;var t,n=null,r=1/0,i=D(e.widgets);try{for(i.s();!(t=i.n()).done;){var a=t.value,o=e.updatePrimaryCTAScrollButton(a);null!==o&&o<r&&(n=a,r=o)}}catch(t){i.e(t)}finally{i.f()}var s,u=D(e.widgets);try{for(u.s();!(s=u.n()).done;){var l,d=s.value;d!==n&&(null===(l=d.primaryCTAScrollButton)||void 0===l||l.style.setProperty("display","none","important"))}}catch(t){u.e(t)}finally{u.f()}}))}),a(this,"handleMessage",function(t){var n=t.data||{},r=n.type,i=n.height;if(r!==o)if("HOLIDOIT_WIDGET_RESIZE"!==r||"number"!=typeof i)if("HOLIDOIT_WIDGET_REQUEST_CAPABILITIES"!==r){if("HOLIDOIT_WIDGET_PRIMARY_CTA"===r){var a,s=e.findTrustedWidgetForEvent(t);if(null==s||!s.supportsPrimaryCTAScroll)return;if(!0!==t.data.active)return s.primaryCTAOffsetY=null,s.primaryCTAHeight=0,s.primaryCTAActivationOffsetY=null,null===(a=s.primaryCTAScrollButton)||void 0===a||a.style.setProperty("display","none","important"),void e.schedulePrimaryCTAUpdate();if("number"!=typeof t.data.offsetY||!Number.isFinite(t.data.offsetY)||"number"!=typeof t.data.elementHeight||!Number.isFinite(t.data.elementHeight))return;return s.primaryCTAOffsetY=Math.max(0,t.data.offsetY),s.primaryCTAHeight=Math.max(0,t.data.elementHeight),s.primaryCTAActivationOffsetY="number"==typeof t.data.activationOffsetY&&Number.isFinite(t.data.activationOffsetY)?Math.max(0,t.data.activationOffsetY):null,e.ensurePrimaryCTAScrollButton(s),void e.schedulePrimaryCTAUpdate()}if("HOLIDOIT_WIDGET_LANGUAGE_CHANGED"!==r)if("HOLIDOIT_WIDGET_READY"!==r){if("HOLIDOIT_WIDGET_SCROLL_TO"===r&&"number"==typeof t.data.offsetY){var u,l=e.findTrustedWidgetForEvent(t);if(!l)return;var d=l.iframe.getBoundingClientRect(),c=window.pageYOffset||document.documentElement.scrollTop,f="number"==typeof t.data.topOffset?Math.min(Math.max(t.data.topOffset,0),300):0,m="number"==typeof t.data.elementHeight?Math.max(t.data.elementHeight,0):null,h=d.top+c+t.data.offsetY,p=(null===(u=window.visualViewport)||void 0===u?void 0:u.height)||window.innerHeight;if(null!==m&&h>=c+f&&h+m<=c+p-24)return;var g=Math.max(0,document.documentElement.scrollHeight-p),y=l.isBookingBox&&"nearest"===t.data.alignment&&null!==m,v=y?function(t){var e=t.scrollTop,n=t.viewportHeight,r=t.elementTop,i=t.elementHeight,a=t.topOffset,o=t.bottomOffset,s=t.maxScrollTop,u=r-a,l=r+i-n+o,d=i<=Math.max(0,n-a-o)?Math.min(Math.max(e,l),u):u;return Math.min(Math.max(0,d),s)}({scrollTop:c,viewportHeight:p,elementTop:h,elementHeight:m,topOffset:f,bottomOffset:24,maxScrollTop:g}):Math.min(Math.max(0,h-f),g);if(y&&Math.abs(v-c)<2)return;var w=window.matchMedia("(prefers-reduced-motion: reduce)").matches?"auto":"smooth";try{window.scrollTo({top:v,behavior:w})}catch(t){window.scrollTo(0,v)}e.log("Scrolled to position",v)}}else{if(!e.findTrustedWidgetForEvent(t))return;e.log("Widget ready:",t.data)}else{var _,b,M=e.findTrustedWidgetForEvent(t),T=null===(_=t.data)||void 0===_||null===(_=_.payload)||void 0===_?void 0:_.language;if(!M||!k.includes(T))return;M.language=T,M.isExperiencePage?e.renderExperiencePageBookCTA(M):null===(b=M.primaryCTAScrollButton)||void 0===b||b.setAttribute("aria-label",e.getPrimaryCTAScrollLabel(M)),e.schedulePrimaryCTAUpdate()}}else{var S,A=e.findTrustedWidgetForEvent(t);null==A||null===(S=A.iframe.contentWindow)||void 0===S||S.postMessage({type:"HOLIDOIT_WIDGET_CAPABILITIES",primaryCTAHelper:A.supportsPrimaryCTAScroll},t.origin)}else{var $=e.findTrustedWidgetForEvent(t);if(!$)return;if($.hasMeasuredHeight||($.hasMeasuredHeight=!0,$.iframe.style.minHeight="".concat(400,"px"),$.element.dataset.holidoitInitialHeight&&($.element.style.minHeight="")),Math.abs(i-$.lastAppliedHeight)<2)return;var x=function(){$.iframe.style.height="".concat(i,"px"),$.lastAppliedHeight=i,e.schedulePrimaryCTAUpdate(),e.log("Resized widget to",i,"px")};if($.isBookingBox){var D=window.pageYOffset||document.documentElement.scrollTop;x(),requestAnimationFrame(function(){var t,e=(null===(t=window.visualViewport)||void 0===t?void 0:t.height)||window.innerHeight,n=Math.max(0,document.documentElement.scrollHeight-e),r=Math.min(D,n),i=window.pageYOffset||document.documentElement.scrollTop;Math.abs(i-r)>=1&&window.scrollTo(0,r)})}else requestAnimationFrame(x)}else e.handleAnalyticsMessage(t)})},e=[{key:"init",value:function(t){var e=this;this.isInitialized?this.log("Already initialized, skipping"):t.embedId&&(this.config=t,this.isInitialized=!0,this.log("Initializing widgets loader",t),this.setupMessageListener(),this.setupResizeObserver(),this.setupPrimaryCTAViewportListeners(),"loading"===document.readyState?document.addEventListener("DOMContentLoaded",function(){return e.scanAndCreateWidgets()}):this.scanAndCreateWidgets(),this.observeForWidgets())}},{key:"scanAndCreateWidgets",value:function(){var t=this;document.querySelectorAll(".".concat(C)).forEach(function(e){var n=e;if("true"!==n.dataset.holidoitProcessed){var r=n.dataset.src;r&&t.createWidget(n,r)}})}},{key:"createWidget",value:function(t,e){var n,r,i,a,o,s,u;t.dataset.holidoitProcessed="true";try{u=new URL(function(t){try{var e=new URL(t,"undefined"==typeof window?void 0:window.location.href),n=new URL("https://cdn.holidoit.com/");if(e.origin!==n.origin||!e.pathname.startsWith(n.pathname))return t;var r=e.pathname.slice(n.pathname.length);return v.has(r)?(e.pathname="".concat(n.pathname,"holidoit-js-releases/").concat("20261202095359217-a04cce2cb673-134cda53","/").concat(r),e.toString()):t}catch(e){return t}}(e),window.location.href)}catch(e){return void(t.dataset.holidoitProcessed="false")}null!==(n=this.config)&&void 0!==n&&n.embedId&&!u.searchParams.has("embedId")&&u.searchParams.set("embedId",this.config.embedId),null!==(r=this.config)&&void 0!==r&&r.language&&!u.searchParams.has("lang")&&u.searchParams.set("lang",this.config.language),null!==(i=this.config)&&void 0!==i&&i.withLogo&&!u.searchParams.has("with_logo")&&u.searchParams.set("with_logo","true"),null!==(a=this.config)&&void 0!==a&&a.gift&&!u.searchParams.has("gift")&&u.searchParams.set("gift","true");var l=u.searchParams.get("lang"),d=k.includes(l||"")?l:(null===(o=this.config)||void 0===o?void 0:o.language)||x.ITALIAN,c=u.pathname.endsWith("/widget-booking-box.html"),f=u.pathname.endsWith("/widget-experience.html"),m=c||f,h=Number(t.dataset.holidoitInitialHeight),p=t.getBoundingClientRect().width||window.innerWidth,g=Number.isFinite(h)&&h>0?h:function(t,e){return t.pathname.endsWith("/widget-booking-box.html")?760:t.pathname.endsWith("/widget-experience.html")?e&&e<=600?1863:e&&e<=775?1923:e&&e<=1024?2027:1002:400}(u,p),y=document.createElement("iframe");y.className="holidoit-widget-iframe",y.src=u.toString(),y.allow="payment",t.style.setProperty("overflow-anchor","none"),y.setAttribute("scrolling","no"),y.setAttribute("frameborder","0"),y.style.cssText="\n width: 100% !important;\n height: ".concat(g,"px;\n min-height: ").concat(g,"px !important;\n border: none !important;\n display: block !important;\n overflow: hidden !important;\n overflow-anchor: none !important;\n "),y.setAttribute("sandbox","allow-scripts allow-same-origin allow-forms allow-popups allow-popups-to-escape-sandbox"),t.innerHTML="",t.appendChild(y);var w={element:t,iframe:y,src:u.toString(),language:d,isBookingBox:c,isExperiencePage:f,supportsPrimaryCTAScroll:m,lastAppliedHeight:g,hasMeasuredHeight:!1,primaryCTAOffsetY:null,primaryCTAHeight:0,primaryCTAActivationOffsetY:null,primaryCTAScrollButton:null};this.widgets.push(w),null===(s=this.resizeObserver)||void 0===s||s.observe(t),this.log("Created widget",w)}},{key:"setupPrimaryCTAViewportListeners",value:function(){var t,e;window.addEventListener("scroll",this.schedulePrimaryCTAUpdate,{passive:!0}),window.addEventListener("resize",this.schedulePrimaryCTAUpdate),null===(t=window.visualViewport)||void 0===t||t.addEventListener("scroll",this.schedulePrimaryCTAUpdate,{passive:!0}),null===(e=window.visualViewport)||void 0===e||e.addEventListener("resize",this.schedulePrimaryCTAUpdate)}},{key:"getPrimaryCTAScrollLabel",value:function(t){switch(t.language){case x.ITALIAN:return"Scorri fino al pulsante Prenota";case x.SPANISH:return"Desplázate hasta el botón Reservar";case x.FRENCH:return"Faire défiler jusqu’au bouton Réserver";case x.GERMAN:return"Zum Buchen-Button scrollen";default:return"Scroll to the booking button"}}},{key:"getExperiencePagePrimaryCTALabel",value:function(t){switch(t.language){case x.ITALIAN:return"Prenota";case x.SPANISH:return"Reservar";case x.FRENCH:return"Réserver";case x.GERMAN:return"Buchen";default:return"Book"}}},{key:"ensurePrimaryCTAScrollButton",value:function(t){var e=this;if(t.primaryCTAScrollButton)return t.primaryCTAScrollButton;var n=document.createElement("button");return n.type="button",n.dataset.holidoitPrimaryCtaScroll="true",t.isExperiencePage?(this.renderExperiencePageBookCTA(t,n),n.style.cssText="\n all: initial !important;\n position: fixed !important;\n display: none !important;\n align-items: center !important;\n justify-content: center !important;\n gap: 8px !important;\n box-sizing: border-box !important;\n height: ".concat(54,"px !important;\n bottom: max(").concat(14,'px, env(safe-area-inset-bottom)) !important;\n padding: 0 20px !important;\n border: 0 !important;\n border-radius: 12px !important;\n background: rgb(15, 23, 42) !important;\n color: white !important;\n box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1) !important;\n cursor: pointer !important;\n font-family: "Google Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif !important;\n font-size: 16px !important;\n font-weight: 500 !important;\n line-height: 1 !important;\n white-space: nowrap !important;\n touch-action: manipulation !important;\n transition: all 200ms ease-out !important;\n z-index: 2147483000 !important;\n -webkit-tap-highlight-color: transparent !important;\n ')):(n.setAttribute("aria-label",this.getPrimaryCTAScrollLabel(t)),n.innerHTML='\n <svg aria-hidden="true" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.25" stroke-linecap="round" stroke-linejoin="round" style="display:block!important;width:22px!important;height:22px!important">\n <path d="m6 9 6 6 6-6"></path>\n </svg>\n ',n.style.cssText="\n all: initial !important;\n position: fixed !important;\n display: none !important;\n align-items: center !important;\n justify-content: center !important;\n box-sizing: border-box !important;\n width: ".concat(O,"px !important;\n height: ").concat(O,"px !important;\n bottom: max(").concat(12,"px, env(safe-area-inset-bottom)) !important;\n border: 0 !important;\n border-radius: 9999px !important;\n background: rgb(30, 41, 59) !important;\n color: white !important;\n box-shadow: 0 8px 24px rgba(15, 23, 42, 0.24) !important;\n cursor: pointer !important;\n touch-action: manipulation !important;\n z-index: 2147483000 !important;\n -webkit-tap-highlight-color: transparent !important;\n ")),n.addEventListener("focus",function(){var t=!0;try{t=n.matches(":focus-visible")}catch(t){}t&&(n.style.setProperty("outline","3px solid rgb(37, 99, 235)","important"),n.style.setProperty("outline-offset","3px","important"))}),n.addEventListener("blur",function(){n.style.removeProperty("outline"),n.style.removeProperty("outline-offset")}),n.addEventListener("click",function(){return e.handlePrimaryCTAButtonClick(t)}),document.body.appendChild(n),t.primaryCTAScrollButton=n,n}},{key:"updatePrimaryCTAScrollButton",value:function(t){var e=t.primaryCTAScrollButton;if(!e)return null;var n=window.visualViewport,r=(null==n?void 0:n.offsetTop)||0,i=(null==n?void 0:n.offsetLeft)||0,a=(null==n?void 0:n.height)||window.innerHeight,o=(null==n?void 0:n.width)||window.innerWidth,s=r+a,u=t.iframe.getBoundingClientRect(),l=null===t.primaryCTAOffsetY?null:u.top+t.primaryCTAOffsetY,d=null===t.primaryCTAActivationOffsetY?null:u.top+t.primaryCTAActivationOffsetY,c=u.bottom>r&&u.top<s,f=null!==l&&l>=s,m=null===d||d<=s-O,h=window.matchMedia("(max-width: ".concat(775,"px)")).matches,p=u.width<=1024;if(t.isExperiencePage){var g=Math.max(u.left+14,i+14),y=Math.min(u.right-14,i+o-14);return!p||!c||null===d||y-g<54||d<=s-54?(e.style.setProperty("display","none","important"),null):(e.style.setProperty("left","".concat(g,"px"),"important"),e.style.setProperty("width","".concat(y-g,"px"),"important"),e.style.setProperty("display","flex","important"),d)}var v=Math.max(u.left,i+12),w=Math.min(u.right-O,i+o-12-O);if(!h||!c||!f||!m||w<v)return e.style.setProperty("display","none","important"),null;var _=u.left+(u.width-O)/2,b=Math.min(Math.max(_,v),w);return e.style.setProperty("left","".concat(b,"px"),"important"),e.style.setProperty("display","flex","important"),l}},{key:"renderExperiencePageBookCTA",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:t.primaryCTAScrollButton;if(e){var n=this.getExperiencePagePrimaryCTALabel(t);e.setAttribute("aria-label",n),e.innerHTML='\n <span style="all:initial!important;color:inherit!important;font:inherit!important;line-height:inherit!important">'.concat(n,'</span>\n <svg aria-hidden="true" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.25" stroke-linecap="round" stroke-linejoin="round" style="display:block!important;width:20px!important;height:20px!important;flex:none!important">\n <path d="m6 9 6 6 6-6"></path>\n </svg>\n ')}}},{key:"handlePrimaryCTAButtonClick",value:function(t){var e;t.isExperiencePage?(null===(e=t.primaryCTAScrollButton)||void 0===e||e.blur(),this.scrollToPrimaryCTAActivationTarget(t)):this.scrollToPrimaryCTA(t)}},{key:"scrollToPrimaryCTAActivationTarget",value:function(t){if(null!==t.primaryCTAActivationOffsetY){var e=t.iframe.getBoundingClientRect(),n=window.pageYOffset||document.documentElement.scrollTop,r=window.visualViewport,i=(null==r?void 0:r.height)||window.innerHeight,a=(null==r?void 0:r.offsetTop)||0,o=e.top+n+t.primaryCTAActivationOffsetY,s=Math.max(0,document.documentElement.scrollHeight-i),u=Math.min(Math.max(0,o-a-12),s),l=window.matchMedia("(prefers-reduced-motion: reduce)").matches?"auto":"smooth";try{window.scrollTo({top:u,behavior:l})}catch(t){window.scrollTo(0,u)}}else this.scrollToPrimaryCTA(t)}},{key:"scrollToPrimaryCTA",value:function(t){var e;if(null!==t.primaryCTAOffsetY){var n=t.iframe.getBoundingClientRect(),r=window.pageYOffset||document.documentElement.scrollTop,i=window.visualViewport,a=(null==i?void 0:i.height)||window.innerHeight,o=(null==i?void 0:i.offsetTop)||0,s=n.top+r+t.primaryCTAOffsetY+t.primaryCTAHeight,u=Math.max(0,document.documentElement.scrollHeight-a),l=Math.min(Math.max(0,s-a-o+24),u),d=window.matchMedia("(prefers-reduced-motion: reduce)").matches?"auto":"smooth";null===(e=t.primaryCTAScrollButton)||void 0===e||e.blur();try{window.scrollTo({top:l,behavior:d})}catch(t){window.scrollTo(0,l)}}}},{key:"observeForWidgets",value:function(){var t=this;new MutationObserver(function(e){var n,r=!1,i=D(e);try{for(i.s();!(n=i.n()).done;){var a=n.value;if("childList"===a.type)for(var o=0;o<a.addedNodes.length;o++){var s,u,l=a.addedNodes[o];if(l instanceof HTMLElement&&(null!==(s=l.classList)&&void 0!==s&&s.contains(C)||null!==(u=l.querySelector)&&void 0!==u&&u.call(l,".".concat(C)))){r=!0;break}}if(r)break}}catch(t){i.e(t)}finally{i.f()}r&&(t.log("Detected new widget elements, scanning..."),t.scanAndCreateWidgets())}).observe(document.body,{childList:!0,subtree:!0})}},{key:"setupMessageListener",value:function(){window.addEventListener("message",this.handleMessage)}},{key:"handleAnalyticsMessage",value:function(t){var e=this,n=this.findTrustedWidgetForEvent(t);!function(t){var e=t.event,n=t.isTrustedSource,r=t.widgetSrc,i=t.log;if(n){var a=g(e.data);a&&"widget"===a.source&&(p(a.eventData,a.dedupeKey)?null==i||i("Pushed analytics event to dataLayer",{dedupeKey:a.dedupeKey,widgetType:a.widgetType,src:r}):null==i||i("Skipped duplicate analytics event",a.dedupeKey))}else null==i||i("Ignored analytics message from untrusted iframe",e.origin)}({event:t,isTrustedSource:Boolean(n),widgetSrc:null==n?void 0:n.src,log:function(){return e.log.apply(e,arguments)}})}},{key:"findTrustedWidgetForEvent",value:function(t){return function(t){var e,n=t.widgets,r=t.event,i=t.getWidgetSrc,a=s(n);try{for(a.s();!(e=a.n()).done;){var o=e.value;if(o.iframe.contentWindow===r.source){var u=y(i(o));return u&&r.origin===u?o:null}}}catch(t){a.e(t)}finally{a.f()}return null}({widgets:this.widgets,event:t,getWidgetSrc:function(t){return t.src}})}},{key:"setupResizeObserver",value:function(){var t=this;this.resizeObserver=new ResizeObserver(function(e){var n,r=D(e);try{for(r.s();!(n=r.n()).done;){var i,a=n.value.target,o=D(t.widgets);try{for(o.s();!(i=o.n()).done;){var s=i.value;if(s.element===a){var u;null===(u=s.iframe.contentWindow)||void 0===u||u.postMessage({type:"HOLIDOIT_REQUEST_HEIGHT"},"*");break}}}catch(t){o.e(t)}finally{o.f()}}}catch(t){r.e(t)}finally{r.f()}})}},{key:"changeLanguage",value:function(t){this.log("Changing language to",t),this.config&&(this.config.language=t);var e,n=D(this.widgets);try{for(n.s();!(e=n.n()).done;){var r,i=e.value;i.language=t,i.isExperiencePage?this.renderExperiencePageBookCTA(i):null===(r=i.primaryCTAScrollButton)||void 0===r||r.setAttribute("aria-label",this.getPrimaryCTAScrollLabel(i))}}catch(t){n.e(t)}finally{n.f()}this.schedulePrimaryCTAUpdate();var a,o=D(this.widgets);try{for(o.s();!(a=o.n()).done;){var s;null===(s=a.value.iframe.contentWindow)||void 0===s||s.postMessage({type:"HOLIDOIT_CHANGE_LANGUAGE",payload:{language:t}},"*")}}catch(t){o.e(t)}finally{o.f()}}},{key:"destroy",value:function(){var t,e,n;this.log("Destroying widgets"),window.removeEventListener("message",this.handleMessage),window.removeEventListener("scroll",this.schedulePrimaryCTAUpdate),window.removeEventListener("resize",this.schedulePrimaryCTAUpdate),null===(t=window.visualViewport)||void 0===t||t.removeEventListener("scroll",this.schedulePrimaryCTAUpdate),null===(e=window.visualViewport)||void 0===e||e.removeEventListener("resize",this.schedulePrimaryCTAUpdate),null!==this.primaryCTAUpdateFrame&&(cancelAnimationFrame(this.primaryCTAUpdateFrame),this.primaryCTAUpdateFrame=null);var r,i=D(this.widgets);try{for(i.s();!(r=i.n()).done;){var a,o=r.value;null===(a=o.primaryCTAScrollButton)||void 0===a||a.remove(),o.iframe.remove(),o.element.dataset.holidoitProcessed="false"}}catch(t){i.e(t)}finally{i.f()}null===(n=this.resizeObserver)||void 0===n||n.disconnect(),this.resizeObserver=null,this.widgets=[],this.config=null,this.isInitialized=!1}},{key:"log",value:function(){var t,e="undefined"!=typeof window&&("localhost"===window.location.hostname||"127.0.0.1"===window.location.hostname);if(null!==(t=this.config)&&void 0!==t&&t.debug||e){for(var n,r=arguments.length,i=new Array(r),a=0;a<r;a++)i[a]=arguments[a];(n=console).log.apply(n,["[HolidoitWidgets]"].concat(i))}}}],e&&i(t.prototype,e),n&&i(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e,n}(),H=new Y;if("undefined"!=typeof window){var P=document.currentScript;if(P){var I=new URL(P.src),E=I.searchParams.get("embedId")||P.dataset.embedId;if(E){var W=I.searchParams.get("lang")||P.dataset.language;H.init({embedId:E,language:W,debug:"true"===I.searchParams.get("debug")||"true"===P.dataset.debug,withLogo:"true"===I.searchParams.get("with_logo")||"true"===P.dataset.withLogo,gift:"true"===I.searchParams.get("gift")||"true"===P.dataset.gift})}}window.HolidoitWidgets=H}})(),r})());
1
+ !function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define("HolidoitWidgets",[],e):"object"==typeof exports?exports.HolidoitWidgets=e():t.HolidoitWidgets=e()}(this,()=>(()=>{var t={317:function(t,e,n){t.exports=function(t){"use strict";function e(t){return t&&"object"==typeof t&&"default"in t?t:{default:t}}var n=e(t),r={name:"es",monthsShort:"ene_feb_mar_abr_may_jun_jul_ago_sep_oct_nov_dic".split("_"),weekdays:"domingo_lunes_martes_miércoles_jueves_viernes_sábado".split("_"),weekdaysShort:"dom._lun._mar._mié._jue._vie._sáb.".split("_"),weekdaysMin:"do_lu_ma_mi_ju_vi_sá".split("_"),months:"enero_febrero_marzo_abril_mayo_junio_julio_agosto_septiembre_octubre_noviembre_diciembre".split("_"),weekStart:1,formats:{LT:"H:mm",LTS:"H:mm:ss",L:"DD/MM/YYYY",LL:"D [de] MMMM [de] YYYY",LLL:"D [de] MMMM [de] YYYY H:mm",LLLL:"dddd, D [de] MMMM [de] YYYY H:mm"},relativeTime:{future:"en %s",past:"hace %s",s:"unos segundos",m:"un minuto",mm:"%d minutos",h:"una hora",hh:"%d horas",d:"un día",dd:"%d días",M:"un mes",MM:"%d meses",y:"un año",yy:"%d años"},ordinal:function(t){return t+"º"}};return n.default.locale(r,null,!0),r}(n(353))},353:function(t){t.exports=function(){"use strict";var t=1e3,e=6e4,n=36e5,r="millisecond",i="second",a="minute",o="hour",s="day",u="week",l="month",d="quarter",c="year",f="date",m="Invalid Date",h=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,p=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,g={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(t){var e=["th","st","nd","rd"],n=t%100;return"["+t+(e[(n-20)%10]||e[n]||e[0])+"]"}},y=function(t,e,n){var r=String(t);return!r||r.length>=e?t:""+Array(e+1-r.length).join(n)+t},v={s:y,z:function(t){var e=-t.utcOffset(),n=Math.abs(e),r=Math.floor(n/60),i=n%60;return(e<=0?"+":"-")+y(r,2,"0")+":"+y(i,2,"0")},m:function t(e,n){if(e.date()<n.date())return-t(n,e);var r=12*(n.year()-e.year())+(n.month()-e.month()),i=e.clone().add(r,l),a=n-i<0,o=e.clone().add(r+(a?-1:1),l);return+(-(r+(n-i)/(a?i-o:o-i))||0)},a:function(t){return t<0?Math.ceil(t)||0:Math.floor(t)},p:function(t){return{M:l,y:c,w:u,d:s,D:f,h:o,m:a,s:i,ms:r,Q:d}[t]||String(t||"").toLowerCase().replace(/s$/,"")},u:function(t){return void 0===t}},w="en",_={};_[w]=g;var b="$isDayjsObject",M=function(t){return t instanceof $||!(!t||!t[b])},T=function t(e,n,r){var i;if(!e)return w;if("string"==typeof e){var a=e.toLowerCase();_[a]&&(i=a),n&&(_[a]=n,i=a);var o=e.split("-");if(!i&&o.length>1)return t(o[0])}else{var s=e.name;_[s]=e,i=s}return!r&&i&&(w=i),i||!r&&w},S=function(t,e){if(M(t))return t.clone();var n="object"==typeof e?e:{};return n.date=t,n.args=arguments,new $(n)},A=v;A.l=T,A.i=M,A.w=function(t,e){return S(t,{locale:e.$L,utc:e.$u,x:e.$x,$offset:e.$offset})};var $=function(){function g(t){this.$L=T(t.locale,null,!0),this.parse(t),this.$x=this.$x||t.x||{},this[b]=!0}var y=g.prototype;return y.parse=function(t){this.$d=function(t){var e=t.date,n=t.utc;if(null===e)return new Date(NaN);if(A.u(e))return new Date;if(e instanceof Date)return new Date(e);if("string"==typeof e&&!/Z$/i.test(e)){var r=e.match(h);if(r){var i=r[2]-1||0,a=(r[7]||"0").substring(0,3);return n?new Date(Date.UTC(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,a)):new Date(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,a)}}return new Date(e)}(t),this.init()},y.init=function(){var t=this.$d;this.$y=t.getFullYear(),this.$M=t.getMonth(),this.$D=t.getDate(),this.$W=t.getDay(),this.$H=t.getHours(),this.$m=t.getMinutes(),this.$s=t.getSeconds(),this.$ms=t.getMilliseconds()},y.$utils=function(){return A},y.isValid=function(){return!(this.$d.toString()===m)},y.isSame=function(t,e){var n=S(t);return this.startOf(e)<=n&&n<=this.endOf(e)},y.isAfter=function(t,e){return S(t)<this.startOf(e)},y.isBefore=function(t,e){return this.endOf(e)<S(t)},y.$g=function(t,e,n){return A.u(t)?this[e]:this.set(n,t)},y.unix=function(){return Math.floor(this.valueOf()/1e3)},y.valueOf=function(){return this.$d.getTime()},y.startOf=function(t,e){var n=this,r=!!A.u(e)||e,d=A.p(t),m=function(t,e){var i=A.w(n.$u?Date.UTC(n.$y,e,t):new Date(n.$y,e,t),n);return r?i:i.endOf(s)},h=function(t,e){return A.w(n.toDate()[t].apply(n.toDate("s"),(r?[0,0,0,0]:[23,59,59,999]).slice(e)),n)},p=this.$W,g=this.$M,y=this.$D,v="set"+(this.$u?"UTC":"");switch(d){case c:return r?m(1,0):m(31,11);case l:return r?m(1,g):m(0,g+1);case u:var w=this.$locale().weekStart||0,_=(p<w?p+7:p)-w;return m(r?y-_:y+(6-_),g);case s:case f:return h(v+"Hours",0);case o:return h(v+"Minutes",1);case a:return h(v+"Seconds",2);case i:return h(v+"Milliseconds",3);default:return this.clone()}},y.endOf=function(t){return this.startOf(t,!1)},y.$set=function(t,e){var n,u=A.p(t),d="set"+(this.$u?"UTC":""),m=(n={},n[s]=d+"Date",n[f]=d+"Date",n[l]=d+"Month",n[c]=d+"FullYear",n[o]=d+"Hours",n[a]=d+"Minutes",n[i]=d+"Seconds",n[r]=d+"Milliseconds",n)[u],h=u===s?this.$D+(e-this.$W):e;if(u===l||u===c){var p=this.clone().set(f,1);p.$d[m](h),p.init(),this.$d=p.set(f,Math.min(this.$D,p.daysInMonth())).$d}else m&&this.$d[m](h);return this.init(),this},y.set=function(t,e){return this.clone().$set(t,e)},y.get=function(t){return this[A.p(t)]()},y.add=function(r,d){var f,m=this;r=Number(r);var h=A.p(d),p=function(t){var e=S(m);return A.w(e.date(e.date()+Math.round(t*r)),m)};if(h===l)return this.set(l,this.$M+r);if(h===c)return this.set(c,this.$y+r);if(h===s)return p(1);if(h===u)return p(7);var g=(f={},f[a]=e,f[o]=n,f[i]=t,f)[h]||1,y=this.$d.getTime()+r*g;return A.w(y,this)},y.subtract=function(t,e){return this.add(-1*t,e)},y.format=function(t){var e=this,n=this.$locale();if(!this.isValid())return n.invalidDate||m;var r=t||"YYYY-MM-DDTHH:mm:ssZ",i=A.z(this),a=this.$H,o=this.$m,s=this.$M,u=n.weekdays,l=n.months,d=n.meridiem,c=function(t,n,i,a){return t&&(t[n]||t(e,r))||i[n].slice(0,a)},f=function(t){return A.s(a%12||12,t,"0")},h=d||function(t,e,n){var r=t<12?"AM":"PM";return n?r.toLowerCase():r};return r.replace(p,function(t,r){return r||function(t){switch(t){case"YY":return String(e.$y).slice(-2);case"YYYY":return A.s(e.$y,4,"0");case"M":return s+1;case"MM":return A.s(s+1,2,"0");case"MMM":return c(n.monthsShort,s,l,3);case"MMMM":return c(l,s);case"D":return e.$D;case"DD":return A.s(e.$D,2,"0");case"d":return String(e.$W);case"dd":return c(n.weekdaysMin,e.$W,u,2);case"ddd":return c(n.weekdaysShort,e.$W,u,3);case"dddd":return u[e.$W];case"H":return String(a);case"HH":return A.s(a,2,"0");case"h":return f(1);case"hh":return f(2);case"a":return h(a,o,!0);case"A":return h(a,o,!1);case"m":return String(o);case"mm":return A.s(o,2,"0");case"s":return String(e.$s);case"ss":return A.s(e.$s,2,"0");case"SSS":return A.s(e.$ms,3,"0");case"Z":return i}return null}(t)||i.replace(":","")})},y.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},y.diff=function(r,f,m){var h,p=this,g=A.p(f),y=S(r),v=(y.utcOffset()-this.utcOffset())*e,w=this-y,_=function(){return A.m(p,y)};switch(g){case c:h=_()/12;break;case l:h=_();break;case d:h=_()/3;break;case u:h=(w-v)/6048e5;break;case s:h=(w-v)/864e5;break;case o:h=w/n;break;case a:h=w/e;break;case i:h=w/t;break;default:h=w}return m?h:A.a(h)},y.daysInMonth=function(){return this.endOf(l).$D},y.$locale=function(){return _[this.$L]},y.locale=function(t,e){if(!t)return this.$L;var n=this.clone(),r=T(t,e,!0);return r&&(n.$L=r),n},y.clone=function(){return A.w(this.$d,this)},y.toDate=function(){return new Date(this.valueOf())},y.toJSON=function(){return this.isValid()?this.toISOString():null},y.toISOString=function(){return this.$d.toISOString()},y.toString=function(){return this.$d.toUTCString()},g}(),x=$.prototype;return S.prototype=x,[["$ms",r],["$s",i],["$m",a],["$H",o],["$W",s],["$M",l],["$y",c],["$D",f]].forEach(function(t){x[t[1]]=function(e){return this.$g(e,t[0],t[1])}}),S.extend=function(t,e){return t.$i||(t(e,$,S),t.$i=!0),S},S.locale=T,S.isDayjs=M,S.unix=function(t){return S(1e3*t)},S.en=_[w],S.Ls=_,S.p={},S}()},445:function(t){t.exports=function(){"use strict";var t="minute",e=/[+-]\d\d(?::?\d\d)?/g,n=/([+-]|\d\d)/g;return function(r,i,a){var o=i.prototype;a.utc=function(t){return new i({date:t,utc:!0,args:arguments})},o.utc=function(e){var n=a(this.toDate(),{locale:this.$L,utc:!0});return e?n.add(this.utcOffset(),t):n},o.local=function(){return a(this.toDate(),{locale:this.$L,utc:!1})};var s=o.parse;o.parse=function(t){t.utc&&(this.$u=!0),this.$utils().u(t.$offset)||(this.$offset=t.$offset),s.call(this,t)};var u=o.init;o.init=function(){if(this.$u){var t=this.$d;this.$y=t.getUTCFullYear(),this.$M=t.getUTCMonth(),this.$D=t.getUTCDate(),this.$W=t.getUTCDay(),this.$H=t.getUTCHours(),this.$m=t.getUTCMinutes(),this.$s=t.getUTCSeconds(),this.$ms=t.getUTCMilliseconds()}else u.call(this)};var l=o.utcOffset;o.utcOffset=function(r,i){var a=this.$utils().u;if(a(r))return this.$u?0:a(this.$offset)?l.call(this):this.$offset;if("string"==typeof r&&(r=function(t){void 0===t&&(t="");var r=t.match(e);if(!r)return null;var i=(""+r[0]).match(n)||["-",0,0],a=i[0],o=60*+i[1]+ +i[2];return 0===o?0:"+"===a?o:-o}(r),null===r))return this;var o=Math.abs(r)<=16?60*r:r;if(0===o)return this.utc(i);var s=this.clone();if(i)return s.$offset=o,s.$u=!1,s;var u=this.$u?this.toDate().getTimezoneOffset():-1*this.utcOffset();return(s=this.local().add(o+u,t)).$offset=o,s.$x.$localOffset=u,s};var d=o.format;o.format=function(t){var e=t||(this.$u?"YYYY-MM-DDTHH:mm:ss[Z]":"");return d.call(this,e)},o.valueOf=function(){var t=this.$utils().u(this.$offset)?0:this.$offset+(this.$x.$localOffset||this.$d.getTimezoneOffset());return this.$d.valueOf()-6e4*t},o.isUTC=function(){return!!this.$u},o.toISOString=function(){return this.toDate().toISOString()},o.toString=function(){return this.toDate().toUTCString()};var c=o.toDate;o.toDate=function(t){return"s"===t&&this.$offset?a(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate():c.call(this)};var f=o.diff;o.diff=function(t,e,n){if(t&&this.$u===t.$u)return f.call(this,t,e,n);var r=this.local(),i=a(t).local();return f.call(r,i,e,n)}}}()},494:function(t,e,n){t.exports=function(t){"use strict";function e(t){return t&&"object"==typeof t&&"default"in t?t:{default:t}}var n=e(t),r={s:"ein paar Sekunden",m:["eine Minute","einer Minute"],mm:"%d Minuten",h:["eine Stunde","einer Stunde"],hh:"%d Stunden",d:["ein Tag","einem Tag"],dd:["%d Tage","%d Tagen"],M:["ein Monat","einem Monat"],MM:["%d Monate","%d Monaten"],y:["ein Jahr","einem Jahr"],yy:["%d Jahre","%d Jahren"]};function i(t,e,n){var i=r[n];return Array.isArray(i)&&(i=i[e?0:1]),i.replace("%d",t)}var a={name:"de",weekdays:"Sonntag_Montag_Dienstag_Mittwoch_Donnerstag_Freitag_Samstag".split("_"),weekdaysShort:"So._Mo._Di._Mi._Do._Fr._Sa.".split("_"),weekdaysMin:"So_Mo_Di_Mi_Do_Fr_Sa".split("_"),months:"Januar_Februar_März_April_Mai_Juni_Juli_August_September_Oktober_November_Dezember".split("_"),monthsShort:"Jan._Feb._März_Apr._Mai_Juni_Juli_Aug._Sept._Okt._Nov._Dez.".split("_"),ordinal:function(t){return t+"."},weekStart:1,yearStart:4,formats:{LTS:"HH:mm:ss",LT:"HH:mm",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY HH:mm",LLLL:"dddd, D. MMMM YYYY HH:mm"},relativeTime:{future:"in %s",past:"vor %s",s:i,m:i,mm:i,h:i,hh:i,d:i,dd:i,M:i,MM:i,y:i,yy:i}};return n.default.locale(a,null,!0),a}(n(353))},569:function(t){t.exports=function(){"use strict";var t={year:0,month:1,day:2,hour:3,minute:4,second:5},e={};return function(n,r,i){var a,o=function(t,n,r){void 0===r&&(r={});var i=new Date(t),a=function(t,n){void 0===n&&(n={});var r=n.timeZoneName||"short",i=t+"|"+r,a=e[i];return a||(a=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:t,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",timeZoneName:r}),e[i]=a),a}(n,r);return a.formatToParts(i)},s=function(e,n){for(var r=o(e,n),a=[],s=0;s<r.length;s+=1){var u=r[s],l=u.type,d=u.value,c=t[l];c>=0&&(a[c]=parseInt(d,10))}var f=a[3],m=24===f?0:f,h=a[0]+"-"+a[1]+"-"+a[2]+" "+m+":"+a[4]+":"+a[5]+":000",p=+e;return(i.utc(h).valueOf()-(p-=p%1e3))/6e4},u=r.prototype;u.tz=function(t,e){void 0===t&&(t=a);var n,r=this.utcOffset(),o=this.toDate(),s=o.toLocaleString("en-US",{timeZone:t}),u=Math.round((o-new Date(s))/1e3/60),l=15*-Math.round(o.getTimezoneOffset()/15)-u;if(Number(l)){if(n=i(s,{locale:this.$L}).$set("millisecond",this.$ms).utcOffset(l,!0),e){var d=n.utcOffset();n=n.add(r-d,"minute")}}else n=this.utcOffset(0,e);return n.$x.$timezone=t,n},u.offsetName=function(t){var e=this.$x.$timezone||i.tz.guess(),n=o(this.valueOf(),e,{timeZoneName:t}).find(function(t){return"timezonename"===t.type.toLowerCase()});return n&&n.value};var l=u.startOf;u.startOf=function(t,e){if(!this.$x||!this.$x.$timezone)return l.call(this,t,e);var n=i(this.format("YYYY-MM-DD HH:mm:ss:SSS"),{locale:this.$L});return l.call(n,t,e).tz(this.$x.$timezone,!0)},i.tz=function(t,e,n){var r=n&&e,o=n||e||a,u=s(+i(),o);if("string"!=typeof t)return i(t).tz(o);var l=function(t,e,n){var r=t-60*e*1e3,i=s(r,n);if(e===i)return[r,e];var a=s(r-=60*(i-e)*1e3,n);return i===a?[r,i]:[t-60*Math.min(i,a)*1e3,Math.max(i,a)]}(i.utc(t,r).valueOf(),u,o),d=l[0],c=l[1],f=i(d).utcOffset(c);return f.$x.$timezone=o,f},i.tz.guess=function(){return Intl.DateTimeFormat().resolvedOptions().timeZone},i.tz.setDefault=function(t){a=t}}}()},813:function(t,e,n){t.exports=function(t){"use strict";function e(t){return t&&"object"==typeof t&&"default"in t?t:{default:t}}var n=e(t),r={name:"fr",weekdays:"dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi".split("_"),weekdaysShort:"dim._lun._mar._mer._jeu._ven._sam.".split("_"),weekdaysMin:"di_lu_ma_me_je_ve_sa".split("_"),months:"janvier_février_mars_avril_mai_juin_juillet_août_septembre_octobre_novembre_décembre".split("_"),monthsShort:"janv._févr._mars_avr._mai_juin_juil._août_sept._oct._nov._déc.".split("_"),weekStart:1,yearStart:4,formats:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},relativeTime:{future:"dans %s",past:"il y a %s",s:"quelques secondes",m:"une minute",mm:"%d minutes",h:"une heure",hh:"%d heures",d:"un jour",dd:"%d jours",M:"un mois",MM:"%d mois",y:"un an",yy:"%d ans"},ordinal:function(t){return t+(1===t?"er":"")}};return n.default.locale(r,null,!0),r}(n(353))},826:function(t){t.exports=function(){"use strict";return{name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(t){var e=["th","st","nd","rd"],n=t%100;return"["+t+(e[(n-20)%10]||e[n]||e[0])+"]"}}}()},840:function(t){t.exports=function(){"use strict";return function(t,e,n){var r=e.prototype,i=function(t){return t&&(t.indexOf?t:t.s)},a=function(t,e,n,r,a){var o=t.name?t:t.$locale(),s=i(o[e]),u=i(o[n]),l=s||u.map(function(t){return t.slice(0,r)});if(!a)return l;var d=o.weekStart;return l.map(function(t,e){return l[(e+(d||0))%7]})},o=function(){return n.Ls[n.locale()]},s=function(t,e){return t.formats[e]||function(t){return t.replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(t,e,n){return e||n.slice(1)})}(t.formats[e.toUpperCase()])},u=function(){var t=this;return{months:function(e){return e?e.format("MMMM"):a(t,"months")},monthsShort:function(e){return e?e.format("MMM"):a(t,"monthsShort","months",3)},firstDayOfWeek:function(){return t.$locale().weekStart||0},weekdays:function(e){return e?e.format("dddd"):a(t,"weekdays")},weekdaysMin:function(e){return e?e.format("dd"):a(t,"weekdaysMin","weekdays",2)},weekdaysShort:function(e){return e?e.format("ddd"):a(t,"weekdaysShort","weekdays",3)},longDateFormat:function(e){return s(t.$locale(),e)},meridiem:this.$locale().meridiem,ordinal:this.$locale().ordinal}};r.localeData=function(){return u.bind(this)()},n.localeData=function(){var t=o();return{firstDayOfWeek:function(){return t.weekStart||0},weekdays:function(){return n.weekdays()},weekdaysShort:function(){return n.weekdaysShort()},weekdaysMin:function(){return n.weekdaysMin()},months:function(){return n.months()},monthsShort:function(){return n.monthsShort()},longDateFormat:function(e){return s(t,e)},meridiem:t.meridiem,ordinal:t.ordinal}},n.months=function(){return a(o(),"months")},n.monthsShort=function(){return a(o(),"monthsShort","months",3)},n.weekdays=function(t){return a(o(),"weekdays",null,null,t)},n.weekdaysShort=function(t){return a(o(),"weekdaysShort","weekdays",3,t)},n.weekdaysMin=function(t){return a(o(),"weekdaysMin","weekdays",2,t)}}}()},900:function(t,e,n){t.exports=function(t){"use strict";function e(t){return t&&"object"==typeof t&&"default"in t?t:{default:t}}var n=e(t),r={name:"it",weekdays:"domenica_lunedì_martedì_mercoledì_giovedì_venerdì_sabato".split("_"),weekdaysShort:"dom_lun_mar_mer_gio_ven_sab".split("_"),weekdaysMin:"do_lu_ma_me_gi_ve_sa".split("_"),months:"gennaio_febbraio_marzo_aprile_maggio_giugno_luglio_agosto_settembre_ottobre_novembre_dicembre".split("_"),weekStart:1,monthsShort:"gen_feb_mar_apr_mag_giu_lug_ago_set_ott_nov_dic".split("_"),formats:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},relativeTime:{future:"tra %s",past:"%s fa",s:"qualche secondo",m:"un minuto",mm:"%d minuti",h:"un'ora",hh:"%d ore",d:"un giorno",dd:"%d giorni",M:"un mese",MM:"%d mesi",y:"un anno",yy:"%d anni"},ordinal:function(t){return t+"º"}};return n.default.locale(r,null,!0),r}(n(353))}},e={};function n(r){var i=e[r];if(void 0!==i)return i.exports;var a=e[r]={exports:{}};return t[r].call(a.exports,a,a.exports,n),a.exports}n.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return n.d(e,{a:e}),e},n.d=(t,e)=>{for(var r in e)n.o(e,r)&&!n.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},n.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),n.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})};var r={};return(()=>{"use strict";function t(e){return t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},t(e)}function e(e){var n=function(e,n){if("object"!=t(e)||!e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var i=r.call(e,n||"default");if("object"!=t(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===n?String:Number)(e)}(e,"string");return"symbol"==t(n)?n:n+""}function i(t,n){for(var r=0;r<n.length;r++){var i=n[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(t,e(i.key),i)}}function a(t,n,r){return(n=e(n))in t?Object.defineProperty(t,n,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[n]=r,t}n.r(r),n.d(r,{holidoitWidgetsLoader:()=>H});var o="HOLIDOIT_ANALYTICS_EVENT";function s(t,e){var n="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!n){if(Array.isArray(t)||(n=function(t,e){if(t){if("string"==typeof t)return u(t,e);var n={}.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?u(t,e):void 0}}(t))||e&&t&&"number"==typeof t.length){n&&(t=n);var r=0,i=function(){};return{s:i,n:function(){return r>=t.length?{done:!0}:{done:!1,value:t[r++]}},e:function(t){throw t},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,o=!0,s=!1;return{s:function(){n=n.call(t)},n:function(){var t=n.next();return o=t.done,t},e:function(t){s=!0,a=t},f:function(){try{o||null==n.return||n.return()}finally{if(s)throw a}}}}function u(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=Array(e);n<e;n++)r[n]=t[n];return r}var l="holidoit_analytics_dedupe_keys",d=new Set;function c(e){return"object"===t(e)&&null!==e&&!Array.isArray(e)}function f(){if("undefined"==typeof window)return null;try{return window.sessionStorage}catch(t){return null}}function m(){var t=f();if(!t)return[];try{var e=t.getItem(l);if(!e)return[];var n=JSON.parse(e);return Array.isArray(n)?n.filter(function(t){return"string"==typeof t&&t.length>0}):[]}catch(t){return[]}}function h(t){if(t){d.add(t);var e=m().filter(function(e){return e!==t});e.push(t),function(t){var e=f();if(e)try{e.setItem(l,JSON.stringify(t.slice(-200)))}catch(t){}}(e)}}function p(t,e){return"undefined"!=typeof window&&(!function(t){return!(!t||!d.has(t)&&(!m().includes(t)||(d.add(t),0)))}(e)&&(Array.isArray(window.dataLayer)||(window.dataLayer=[]),h(e),window.dataLayer.push(t),!0))}function g(t){if(!c(t)||t.type!==o)return null;var e,n=c(t.payload)?t.payload:t,r=n.channel,i=n.dedupeKey,a=n.eventData,s=n.source,u=n.widgetType;return"dataLayer"!==r||"embed"!==s&&"widget"!==s||"string"!=typeof i||""===i.trim()||(!c(e=a)||"string"!=typeof e.event||""===e.event.trim())?null:{channel:r,dedupeKey:i.trim(),eventData:a,source:s,widgetType:"string"==typeof u&&u.trim()?u:void 0}}function y(t){try{return new URL(t,window.location.href).origin}catch(t){return null}}var v=new Set(["holidoit.js","embed.html","payment-redirect.html","widgets/widget-book-now-button.html","widgets/widget-booking-box.html","widgets/widget-experience.html","widgets/widget-experience-grid.html","widgets/widget-experience-grid-drawer.html","widgets/widget-experience-page-drawer.html"]);var w=n(353),_=n.n(w),b=(n(494),n(826),n(317),n(813),n(900),n(840)),M=n.n(b),T=n(569),S=n.n(T),A=n(445),$=n.n(A);_().extend($()),_().extend(S()),_().extend(M());var x=function(t){return t.ITALIAN="it",t.ENGLISH="en",t.SPANISH="es",t.FRENCH="fr",t.GERMAN="de",t}({});_()().locale("it").localeData().months(),_()().locale("it").localeData().weekdays(),_()().locale("en").localeData().months(),_()().locale("en").localeData().weekdays(),_()().locale("de").localeData().months(),_()().locale("de").localeData().weekdays(),_()().locale("es").localeData().months(),_()().locale("es").localeData().weekdays(),_()().locale("fr").localeData().months(),_()().locale("fr").localeData().weekdays();function D(t,e){var n="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(!n){if(Array.isArray(t)||(n=function(t,e){if(t){if("string"==typeof t)return L(t,e);var n={}.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?L(t,e):void 0}}(t))||e&&t&&"number"==typeof t.length){n&&(t=n);var r=0,i=function(){};return{s:i,n:function(){return r>=t.length?{done:!0}:{done:!1,value:t[r++]}},e:function(t){throw t},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,o=!0,s=!1;return{s:function(){n=n.call(t)},n:function(){var t=n.next();return o=t.done,t},e:function(t){s=!0,a=t},f:function(){try{o||null==n.return||n.return()}finally{if(s)throw a}}}}function L(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=Array(e);n<e;n++)r[n]=t[n];return r}var C="holidoitWidget",O=48,k=Object.values(x),Y=function(){return t=function t(){var e=this;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),a(this,"config",null),a(this,"widgets",[]),a(this,"isInitialized",!1),a(this,"resizeObserver",null),a(this,"primaryCTAUpdateFrame",null),a(this,"schedulePrimaryCTAUpdate",function(){null===e.primaryCTAUpdateFrame&&(e.primaryCTAUpdateFrame=requestAnimationFrame(function(){e.primaryCTAUpdateFrame=null;var t,n=null,r=1/0,i=D(e.widgets);try{for(i.s();!(t=i.n()).done;){var a=t.value,o=e.updatePrimaryCTAScrollButton(a);null!==o&&o<r&&(n=a,r=o)}}catch(t){i.e(t)}finally{i.f()}var s,u=D(e.widgets);try{for(u.s();!(s=u.n()).done;){var l,d=s.value;d!==n&&(null===(l=d.primaryCTAScrollButton)||void 0===l||l.style.setProperty("display","none","important"))}}catch(t){u.e(t)}finally{u.f()}}))}),a(this,"handleMessage",function(t){var n=t.data||{},r=n.type,i=n.height;if(r!==o)if("HOLIDOIT_WIDGET_RESIZE"!==r||"number"!=typeof i)if("HOLIDOIT_WIDGET_REQUEST_CAPABILITIES"!==r){if("HOLIDOIT_WIDGET_PRIMARY_CTA"===r){var a,s=e.findTrustedWidgetForEvent(t);if(null==s||!s.supportsPrimaryCTAScroll)return;if(!0!==t.data.active)return s.primaryCTAOffsetY=null,s.primaryCTAHeight=0,s.primaryCTAActivationOffsetY=null,null===(a=s.primaryCTAScrollButton)||void 0===a||a.style.setProperty("display","none","important"),void e.schedulePrimaryCTAUpdate();if("number"!=typeof t.data.offsetY||!Number.isFinite(t.data.offsetY)||"number"!=typeof t.data.elementHeight||!Number.isFinite(t.data.elementHeight))return;return s.primaryCTAOffsetY=Math.max(0,t.data.offsetY),s.primaryCTAHeight=Math.max(0,t.data.elementHeight),s.primaryCTAActivationOffsetY="number"==typeof t.data.activationOffsetY&&Number.isFinite(t.data.activationOffsetY)?Math.max(0,t.data.activationOffsetY):null,e.ensurePrimaryCTAScrollButton(s),void e.schedulePrimaryCTAUpdate()}if("HOLIDOIT_WIDGET_LANGUAGE_CHANGED"!==r)if("HOLIDOIT_WIDGET_READY"!==r){if("HOLIDOIT_WIDGET_SCROLL_TO"===r&&"number"==typeof t.data.offsetY){var u,l=e.findTrustedWidgetForEvent(t);if(!l)return;var d=l.iframe.getBoundingClientRect(),c=window.pageYOffset||document.documentElement.scrollTop,f="number"==typeof t.data.topOffset?Math.min(Math.max(t.data.topOffset,0),300):0,m="number"==typeof t.data.elementHeight?Math.max(t.data.elementHeight,0):null,h=d.top+c+t.data.offsetY,p=(null===(u=window.visualViewport)||void 0===u?void 0:u.height)||window.innerHeight;if(null!==m&&h>=c+f&&h+m<=c+p-24)return;var g=Math.max(0,document.documentElement.scrollHeight-p),y=l.isBookingBox&&"nearest"===t.data.alignment&&null!==m,v=y?function(t){var e=t.scrollTop,n=t.viewportHeight,r=t.elementTop,i=t.elementHeight,a=t.topOffset,o=t.bottomOffset,s=t.maxScrollTop,u=r-a,l=r+i-n+o,d=i<=Math.max(0,n-a-o)?Math.min(Math.max(e,l),u):u;return Math.min(Math.max(0,d),s)}({scrollTop:c,viewportHeight:p,elementTop:h,elementHeight:m,topOffset:f,bottomOffset:24,maxScrollTop:g}):Math.min(Math.max(0,h-f),g);if(y&&Math.abs(v-c)<2)return;var w=window.matchMedia("(prefers-reduced-motion: reduce)").matches?"auto":"smooth";try{window.scrollTo({top:v,behavior:w})}catch(t){window.scrollTo(0,v)}e.log("Scrolled to position",v)}}else{if(!e.findTrustedWidgetForEvent(t))return;e.log("Widget ready:",t.data)}else{var _,b,M=e.findTrustedWidgetForEvent(t),T=null===(_=t.data)||void 0===_||null===(_=_.payload)||void 0===_?void 0:_.language;if(!M||!k.includes(T))return;M.language=T,M.isExperiencePage?e.renderExperiencePageBookCTA(M):null===(b=M.primaryCTAScrollButton)||void 0===b||b.setAttribute("aria-label",e.getPrimaryCTAScrollLabel(M)),e.schedulePrimaryCTAUpdate()}}else{var S,A=e.findTrustedWidgetForEvent(t);null==A||null===(S=A.iframe.contentWindow)||void 0===S||S.postMessage({type:"HOLIDOIT_WIDGET_CAPABILITIES",primaryCTAHelper:A.supportsPrimaryCTAScroll},t.origin)}else{var $=e.findTrustedWidgetForEvent(t);if(!$)return;if($.hasMeasuredHeight||($.hasMeasuredHeight=!0,$.iframe.style.minHeight="".concat(400,"px"),$.element.dataset.holidoitInitialHeight&&($.element.style.minHeight="")),Math.abs(i-$.lastAppliedHeight)<2)return;var x=function(){$.iframe.style.height="".concat(i,"px"),$.lastAppliedHeight=i,e.schedulePrimaryCTAUpdate(),e.log("Resized widget to",i,"px")};if($.isBookingBox){var D=window.pageYOffset||document.documentElement.scrollTop;x(),requestAnimationFrame(function(){var t,e=(null===(t=window.visualViewport)||void 0===t?void 0:t.height)||window.innerHeight,n=Math.max(0,document.documentElement.scrollHeight-e),r=Math.min(D,n),i=window.pageYOffset||document.documentElement.scrollTop;Math.abs(i-r)>=1&&window.scrollTo(0,r)})}else requestAnimationFrame(x)}else e.handleAnalyticsMessage(t)})},e=[{key:"init",value:function(t){var e=this;this.isInitialized?this.log("Already initialized, skipping"):t.embedId&&(this.config=t,this.isInitialized=!0,this.log("Initializing widgets loader",t),this.setupMessageListener(),this.setupResizeObserver(),this.setupPrimaryCTAViewportListeners(),"loading"===document.readyState?document.addEventListener("DOMContentLoaded",function(){return e.scanAndCreateWidgets()}):this.scanAndCreateWidgets(),this.observeForWidgets())}},{key:"scanAndCreateWidgets",value:function(){var t=this;document.querySelectorAll(".".concat(C)).forEach(function(e){var n=e;if("true"!==n.dataset.holidoitProcessed){var r=n.dataset.src;r&&t.createWidget(n,r)}})}},{key:"createWidget",value:function(t,e){var n,r,i,a,o,s,u;t.dataset.holidoitProcessed="true";try{u=new URL(function(t){try{var e=new URL(t,"undefined"==typeof window?void 0:window.location.href),n=new URL("https://cdn.holidoit.com/");if(e.origin!==n.origin||!e.pathname.startsWith(n.pathname))return t;var r=e.pathname.slice(n.pathname.length);return v.has(r)?(e.pathname="".concat(n.pathname,"holidoit-js-releases/").concat("20261204090104486-2a8b6fd1848e-dfb1891e","/").concat(r),e.toString()):t}catch(e){return t}}(e),window.location.href)}catch(e){return void(t.dataset.holidoitProcessed="false")}null!==(n=this.config)&&void 0!==n&&n.embedId&&!u.searchParams.has("embedId")&&u.searchParams.set("embedId",this.config.embedId),null!==(r=this.config)&&void 0!==r&&r.language&&!u.searchParams.has("lang")&&u.searchParams.set("lang",this.config.language),null!==(i=this.config)&&void 0!==i&&i.withLogo&&!u.searchParams.has("with_logo")&&u.searchParams.set("with_logo","true"),null!==(a=this.config)&&void 0!==a&&a.gift&&!u.searchParams.has("gift")&&u.searchParams.set("gift","true");var l=u.searchParams.get("lang"),d=k.includes(l||"")?l:(null===(o=this.config)||void 0===o?void 0:o.language)||x.ITALIAN,c=u.pathname.endsWith("/widget-booking-box.html"),f=u.pathname.endsWith("/widget-experience.html"),m=c||f,h=Number(t.dataset.holidoitInitialHeight),p=t.getBoundingClientRect().width||window.innerWidth,g=Number.isFinite(h)&&h>0?h:function(t,e){return t.pathname.endsWith("/widget-booking-box.html")?760:t.pathname.endsWith("/widget-experience.html")?e&&e<=600?1863:e&&e<=775?1923:e&&e<=1024?2027:1002:400}(u,p),y=document.createElement("iframe");y.className="holidoit-widget-iframe",y.src=u.toString(),y.allow="payment",t.style.setProperty("overflow-anchor","none"),y.setAttribute("scrolling","no"),y.setAttribute("frameborder","0"),y.style.cssText="\n width: 100% !important;\n height: ".concat(g,"px;\n min-height: ").concat(g,"px !important;\n border: none !important;\n display: block !important;\n overflow: hidden !important;\n overflow-anchor: none !important;\n "),y.setAttribute("sandbox","allow-scripts allow-same-origin allow-forms allow-popups allow-popups-to-escape-sandbox"),t.innerHTML="",t.appendChild(y);var w={element:t,iframe:y,src:u.toString(),language:d,isBookingBox:c,isExperiencePage:f,supportsPrimaryCTAScroll:m,lastAppliedHeight:g,hasMeasuredHeight:!1,primaryCTAOffsetY:null,primaryCTAHeight:0,primaryCTAActivationOffsetY:null,primaryCTAScrollButton:null};this.widgets.push(w),null===(s=this.resizeObserver)||void 0===s||s.observe(t),this.log("Created widget",w)}},{key:"setupPrimaryCTAViewportListeners",value:function(){var t,e;window.addEventListener("scroll",this.schedulePrimaryCTAUpdate,{passive:!0}),window.addEventListener("resize",this.schedulePrimaryCTAUpdate),null===(t=window.visualViewport)||void 0===t||t.addEventListener("scroll",this.schedulePrimaryCTAUpdate,{passive:!0}),null===(e=window.visualViewport)||void 0===e||e.addEventListener("resize",this.schedulePrimaryCTAUpdate)}},{key:"getPrimaryCTAScrollLabel",value:function(t){switch(t.language){case x.ITALIAN:return"Scorri fino al pulsante Prenota";case x.SPANISH:return"Desplázate hasta el botón Reservar";case x.FRENCH:return"Faire défiler jusqu’au bouton Réserver";case x.GERMAN:return"Zum Buchen-Button scrollen";default:return"Scroll to the booking button"}}},{key:"getExperiencePagePrimaryCTALabel",value:function(t){switch(t.language){case x.ITALIAN:return"Prenota";case x.SPANISH:return"Reservar";case x.FRENCH:return"Réserver";case x.GERMAN:return"Buchen";default:return"Book"}}},{key:"ensurePrimaryCTAScrollButton",value:function(t){var e=this;if(t.primaryCTAScrollButton)return t.primaryCTAScrollButton;var n=document.createElement("button");return n.type="button",n.dataset.holidoitPrimaryCtaScroll="true",t.isExperiencePage?(this.renderExperiencePageBookCTA(t,n),n.style.cssText="\n all: initial !important;\n position: fixed !important;\n display: none !important;\n align-items: center !important;\n justify-content: center !important;\n gap: 8px !important;\n box-sizing: border-box !important;\n height: ".concat(54,"px !important;\n bottom: max(").concat(14,'px, env(safe-area-inset-bottom)) !important;\n padding: 0 20px !important;\n border: 0 !important;\n border-radius: 12px !important;\n background: rgb(15, 23, 42) !important;\n color: white !important;\n box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1) !important;\n cursor: pointer !important;\n font-family: "Google Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif !important;\n font-size: 16px !important;\n font-weight: 500 !important;\n line-height: 1 !important;\n white-space: nowrap !important;\n touch-action: manipulation !important;\n transition: all 200ms ease-out !important;\n z-index: 2147483000 !important;\n -webkit-tap-highlight-color: transparent !important;\n ')):(n.setAttribute("aria-label",this.getPrimaryCTAScrollLabel(t)),n.innerHTML='\n <svg aria-hidden="true" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.25" stroke-linecap="round" stroke-linejoin="round" style="display:block!important;width:22px!important;height:22px!important">\n <path d="m6 9 6 6 6-6"></path>\n </svg>\n ',n.style.cssText="\n all: initial !important;\n position: fixed !important;\n display: none !important;\n align-items: center !important;\n justify-content: center !important;\n box-sizing: border-box !important;\n width: ".concat(O,"px !important;\n height: ").concat(O,"px !important;\n bottom: max(").concat(12,"px, env(safe-area-inset-bottom)) !important;\n border: 0 !important;\n border-radius: 9999px !important;\n background: rgb(30, 41, 59) !important;\n color: white !important;\n box-shadow: 0 8px 24px rgba(15, 23, 42, 0.24) !important;\n cursor: pointer !important;\n touch-action: manipulation !important;\n z-index: 2147483000 !important;\n -webkit-tap-highlight-color: transparent !important;\n ")),n.addEventListener("focus",function(){var t=!0;try{t=n.matches(":focus-visible")}catch(t){}t&&(n.style.setProperty("outline","3px solid rgb(37, 99, 235)","important"),n.style.setProperty("outline-offset","3px","important"))}),n.addEventListener("blur",function(){n.style.removeProperty("outline"),n.style.removeProperty("outline-offset")}),n.addEventListener("click",function(){return e.handlePrimaryCTAButtonClick(t)}),document.body.appendChild(n),t.primaryCTAScrollButton=n,n}},{key:"updatePrimaryCTAScrollButton",value:function(t){var e=t.primaryCTAScrollButton;if(!e)return null;var n=window.visualViewport,r=(null==n?void 0:n.offsetTop)||0,i=(null==n?void 0:n.offsetLeft)||0,a=(null==n?void 0:n.height)||window.innerHeight,o=(null==n?void 0:n.width)||window.innerWidth,s=r+a,u=t.iframe.getBoundingClientRect(),l=null===t.primaryCTAOffsetY?null:u.top+t.primaryCTAOffsetY,d=null===t.primaryCTAActivationOffsetY?null:u.top+t.primaryCTAActivationOffsetY,c=u.bottom>r&&u.top<s,f=null!==l&&l>=s,m=null===d||d<=s-O,h=window.matchMedia("(max-width: ".concat(775,"px)")).matches,p=u.width<=1024;if(t.isExperiencePage){var g=Math.max(u.left+14,i+14),y=Math.min(u.right-14,i+o-14);return!p||!c||null===d||y-g<54||d<=s-54?(e.style.setProperty("display","none","important"),null):(e.style.setProperty("left","".concat(g,"px"),"important"),e.style.setProperty("width","".concat(y-g,"px"),"important"),e.style.setProperty("display","flex","important"),d)}var v=Math.max(u.left,i+12),w=Math.min(u.right-O,i+o-12-O);if(!h||!c||!f||!m||w<v)return e.style.setProperty("display","none","important"),null;var _=u.left+(u.width-O)/2,b=Math.min(Math.max(_,v),w);return e.style.setProperty("left","".concat(b,"px"),"important"),e.style.setProperty("display","flex","important"),l}},{key:"renderExperiencePageBookCTA",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:t.primaryCTAScrollButton;if(e){var n=this.getExperiencePagePrimaryCTALabel(t);e.setAttribute("aria-label",n),e.innerHTML='\n <span style="all:initial!important;color:inherit!important;font:inherit!important;line-height:inherit!important">'.concat(n,'</span>\n <svg aria-hidden="true" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2.25" stroke-linecap="round" stroke-linejoin="round" style="display:block!important;width:20px!important;height:20px!important;flex:none!important">\n <path d="m6 9 6 6 6-6"></path>\n </svg>\n ')}}},{key:"handlePrimaryCTAButtonClick",value:function(t){var e;t.isExperiencePage?(null===(e=t.primaryCTAScrollButton)||void 0===e||e.blur(),this.scrollToPrimaryCTAActivationTarget(t)):this.scrollToPrimaryCTA(t)}},{key:"scrollToPrimaryCTAActivationTarget",value:function(t){if(null!==t.primaryCTAActivationOffsetY){var e=t.iframe.getBoundingClientRect(),n=window.pageYOffset||document.documentElement.scrollTop,r=window.visualViewport,i=(null==r?void 0:r.height)||window.innerHeight,a=(null==r?void 0:r.offsetTop)||0,o=e.top+n+t.primaryCTAActivationOffsetY,s=Math.max(0,document.documentElement.scrollHeight-i),u=Math.min(Math.max(0,o-a-12),s),l=window.matchMedia("(prefers-reduced-motion: reduce)").matches?"auto":"smooth";try{window.scrollTo({top:u,behavior:l})}catch(t){window.scrollTo(0,u)}}else this.scrollToPrimaryCTA(t)}},{key:"scrollToPrimaryCTA",value:function(t){var e;if(null!==t.primaryCTAOffsetY){var n=t.iframe.getBoundingClientRect(),r=window.pageYOffset||document.documentElement.scrollTop,i=window.visualViewport,a=(null==i?void 0:i.height)||window.innerHeight,o=(null==i?void 0:i.offsetTop)||0,s=n.top+r+t.primaryCTAOffsetY+t.primaryCTAHeight,u=Math.max(0,document.documentElement.scrollHeight-a),l=Math.min(Math.max(0,s-a-o+24),u),d=window.matchMedia("(prefers-reduced-motion: reduce)").matches?"auto":"smooth";null===(e=t.primaryCTAScrollButton)||void 0===e||e.blur();try{window.scrollTo({top:l,behavior:d})}catch(t){window.scrollTo(0,l)}}}},{key:"observeForWidgets",value:function(){var t=this;new MutationObserver(function(e){var n,r=!1,i=D(e);try{for(i.s();!(n=i.n()).done;){var a=n.value;if("childList"===a.type)for(var o=0;o<a.addedNodes.length;o++){var s,u,l=a.addedNodes[o];if(l instanceof HTMLElement&&(null!==(s=l.classList)&&void 0!==s&&s.contains(C)||null!==(u=l.querySelector)&&void 0!==u&&u.call(l,".".concat(C)))){r=!0;break}}if(r)break}}catch(t){i.e(t)}finally{i.f()}r&&(t.log("Detected new widget elements, scanning..."),t.scanAndCreateWidgets())}).observe(document.body,{childList:!0,subtree:!0})}},{key:"setupMessageListener",value:function(){window.addEventListener("message",this.handleMessage)}},{key:"handleAnalyticsMessage",value:function(t){var e=this,n=this.findTrustedWidgetForEvent(t);!function(t){var e=t.event,n=t.isTrustedSource,r=t.widgetSrc,i=t.log;if(n){var a=g(e.data);a&&"widget"===a.source&&(p(a.eventData,a.dedupeKey)?null==i||i("Pushed analytics event to dataLayer",{dedupeKey:a.dedupeKey,widgetType:a.widgetType,src:r}):null==i||i("Skipped duplicate analytics event",a.dedupeKey))}else null==i||i("Ignored analytics message from untrusted iframe",e.origin)}({event:t,isTrustedSource:Boolean(n),widgetSrc:null==n?void 0:n.src,log:function(){return e.log.apply(e,arguments)}})}},{key:"findTrustedWidgetForEvent",value:function(t){return function(t){var e,n=t.widgets,r=t.event,i=t.getWidgetSrc,a=s(n);try{for(a.s();!(e=a.n()).done;){var o=e.value;if(o.iframe.contentWindow===r.source){var u=y(i(o));return u&&r.origin===u?o:null}}}catch(t){a.e(t)}finally{a.f()}return null}({widgets:this.widgets,event:t,getWidgetSrc:function(t){return t.src}})}},{key:"setupResizeObserver",value:function(){var t=this;this.resizeObserver=new ResizeObserver(function(e){var n,r=D(e);try{for(r.s();!(n=r.n()).done;){var i,a=n.value.target,o=D(t.widgets);try{for(o.s();!(i=o.n()).done;){var s=i.value;if(s.element===a){var u;null===(u=s.iframe.contentWindow)||void 0===u||u.postMessage({type:"HOLIDOIT_REQUEST_HEIGHT"},"*");break}}}catch(t){o.e(t)}finally{o.f()}}}catch(t){r.e(t)}finally{r.f()}})}},{key:"changeLanguage",value:function(t){this.log("Changing language to",t),this.config&&(this.config.language=t);var e,n=D(this.widgets);try{for(n.s();!(e=n.n()).done;){var r,i=e.value;i.language=t,i.isExperiencePage?this.renderExperiencePageBookCTA(i):null===(r=i.primaryCTAScrollButton)||void 0===r||r.setAttribute("aria-label",this.getPrimaryCTAScrollLabel(i))}}catch(t){n.e(t)}finally{n.f()}this.schedulePrimaryCTAUpdate();var a,o=D(this.widgets);try{for(o.s();!(a=o.n()).done;){var s;null===(s=a.value.iframe.contentWindow)||void 0===s||s.postMessage({type:"HOLIDOIT_CHANGE_LANGUAGE",payload:{language:t}},"*")}}catch(t){o.e(t)}finally{o.f()}}},{key:"destroy",value:function(){var t,e,n;this.log("Destroying widgets"),window.removeEventListener("message",this.handleMessage),window.removeEventListener("scroll",this.schedulePrimaryCTAUpdate),window.removeEventListener("resize",this.schedulePrimaryCTAUpdate),null===(t=window.visualViewport)||void 0===t||t.removeEventListener("scroll",this.schedulePrimaryCTAUpdate),null===(e=window.visualViewport)||void 0===e||e.removeEventListener("resize",this.schedulePrimaryCTAUpdate),null!==this.primaryCTAUpdateFrame&&(cancelAnimationFrame(this.primaryCTAUpdateFrame),this.primaryCTAUpdateFrame=null);var r,i=D(this.widgets);try{for(i.s();!(r=i.n()).done;){var a,o=r.value;null===(a=o.primaryCTAScrollButton)||void 0===a||a.remove(),o.iframe.remove(),o.element.dataset.holidoitProcessed="false"}}catch(t){i.e(t)}finally{i.f()}null===(n=this.resizeObserver)||void 0===n||n.disconnect(),this.resizeObserver=null,this.widgets=[],this.config=null,this.isInitialized=!1}},{key:"log",value:function(){var t,e="undefined"!=typeof window&&("localhost"===window.location.hostname||"127.0.0.1"===window.location.hostname);if(null!==(t=this.config)&&void 0!==t&&t.debug||e){for(var n,r=arguments.length,i=new Array(r),a=0;a<r;a++)i[a]=arguments[a];(n=console).log.apply(n,["[HolidoitWidgets]"].concat(i))}}}],e&&i(t.prototype,e),n&&i(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e,n}(),H=new Y;if("undefined"!=typeof window){var P=document.currentScript;if(P){var I=new URL(P.src),E=I.searchParams.get("embedId")||P.dataset.embedId;if(E){var W=I.searchParams.get("lang")||P.dataset.language;H.init({embedId:E,language:W,debug:"true"===I.searchParams.get("debug")||"true"===P.dataset.debug,withLogo:"true"===I.searchParams.get("with_logo")||"true"===P.dataset.withLogo,gift:"true"===I.searchParams.get("gift")||"true"===P.dataset.gift})}}window.HolidoitWidgets=H}})(),r})());
package/package.json CHANGED
@@ -11,7 +11,7 @@
11
11
  "npm-minor": "npm version patch",
12
12
  "npm-publish": "npm publish"
13
13
  },
14
- "version": "1.0.185",
14
+ "version": "1.0.187",
15
15
  "main": "dist/holidoit.umd.js",
16
16
  "module": "dist/holidoit.es5.js",
17
17
  "types": "dist/types/holidoit.d.ts",
@@ -1,2 +0,0 @@
1
- /*! For license information please see holidoit.umd.js.LICENSE.txt */
2
- !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define("Holidoit",[],t):"object"==typeof exports?exports.Holidoit=t():e.Holidoit=t()}(this,()=>(()=>{var e={172:e=>{e.exports=function(e,t){this.v=e,this.k=t},e.exports.__esModule=!0,e.exports.default=e.exports},317:function(e,t,n){e.exports=function(e){"use strict";function t(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var n=t(e),i={name:"es",monthsShort:"ene_feb_mar_abr_may_jun_jul_ago_sep_oct_nov_dic".split("_"),weekdays:"domingo_lunes_martes_miércoles_jueves_viernes_sábado".split("_"),weekdaysShort:"dom._lun._mar._mié._jue._vie._sáb.".split("_"),weekdaysMin:"do_lu_ma_mi_ju_vi_sá".split("_"),months:"enero_febrero_marzo_abril_mayo_junio_julio_agosto_septiembre_octubre_noviembre_diciembre".split("_"),weekStart:1,formats:{LT:"H:mm",LTS:"H:mm:ss",L:"DD/MM/YYYY",LL:"D [de] MMMM [de] YYYY",LLL:"D [de] MMMM [de] YYYY H:mm",LLLL:"dddd, D [de] MMMM [de] YYYY H:mm"},relativeTime:{future:"en %s",past:"hace %s",s:"unos segundos",m:"un minuto",mm:"%d minutos",h:"una hora",hh:"%d horas",d:"un día",dd:"%d días",M:"un mes",MM:"%d meses",y:"un año",yy:"%d años"},ordinal:function(e){return e+"º"}};return n.default.locale(i,null,!0),i}(n(353))},353:function(e){e.exports=function(){"use strict";var e=1e3,t=6e4,n=36e5,i="millisecond",o="second",r="minute",a="hour",s="day",l="week",u="month",c="quarter",d="year",h="date",f="Invalid Date",p=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,m=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,g={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(e){var t=["th","st","nd","rd"],n=e%100;return"["+e+(t[(n-20)%10]||t[n]||t[0])+"]"}},v=function(e,t,n){var i=String(e);return!i||i.length>=t?e:""+Array(t+1-i.length).join(n)+e},y={s:v,z:function(e){var t=-e.utcOffset(),n=Math.abs(t),i=Math.floor(n/60),o=n%60;return(t<=0?"+":"-")+v(i,2,"0")+":"+v(o,2,"0")},m:function e(t,n){if(t.date()<n.date())return-e(n,t);var i=12*(n.year()-t.year())+(n.month()-t.month()),o=t.clone().add(i,u),r=n-o<0,a=t.clone().add(i+(r?-1:1),u);return+(-(i+(n-o)/(r?o-a:a-o))||0)},a:function(e){return e<0?Math.ceil(e)||0:Math.floor(e)},p:function(e){return{M:u,y:d,w:l,d:s,D:h,h:a,m:r,s:o,ms:i,Q:c}[e]||String(e||"").toLowerCase().replace(/s$/,"")},u:function(e){return void 0===e}},b="en",w={};w[b]=g;var _="$isDayjsObject",S=function(e){return e instanceof M||!(!e||!e[_])},k=function e(t,n,i){var o;if(!t)return b;if("string"==typeof t){var r=t.toLowerCase();w[r]&&(o=r),n&&(w[r]=n,o=r);var a=t.split("-");if(!o&&a.length>1)return e(a[0])}else{var s=t.name;w[s]=t,o=s}return!i&&o&&(b=o),o||!i&&b},O=function(e,t){if(S(e))return e.clone();var n="object"==typeof t?t:{};return n.date=e,n.args=arguments,new M(n)},x=y;x.l=k,x.i=S,x.w=function(e,t){return O(e,{locale:t.$L,utc:t.$u,x:t.$x,$offset:t.$offset})};var M=function(){function g(e){this.$L=k(e.locale,null,!0),this.parse(e),this.$x=this.$x||e.x||{},this[_]=!0}var v=g.prototype;return v.parse=function(e){this.$d=function(e){var t=e.date,n=e.utc;if(null===t)return new Date(NaN);if(x.u(t))return new Date;if(t instanceof Date)return new Date(t);if("string"==typeof t&&!/Z$/i.test(t)){var i=t.match(p);if(i){var o=i[2]-1||0,r=(i[7]||"0").substring(0,3);return n?new Date(Date.UTC(i[1],o,i[3]||1,i[4]||0,i[5]||0,i[6]||0,r)):new Date(i[1],o,i[3]||1,i[4]||0,i[5]||0,i[6]||0,r)}}return new Date(t)}(e),this.init()},v.init=function(){var e=this.$d;this.$y=e.getFullYear(),this.$M=e.getMonth(),this.$D=e.getDate(),this.$W=e.getDay(),this.$H=e.getHours(),this.$m=e.getMinutes(),this.$s=e.getSeconds(),this.$ms=e.getMilliseconds()},v.$utils=function(){return x},v.isValid=function(){return!(this.$d.toString()===f)},v.isSame=function(e,t){var n=O(e);return this.startOf(t)<=n&&n<=this.endOf(t)},v.isAfter=function(e,t){return O(e)<this.startOf(t)},v.isBefore=function(e,t){return this.endOf(t)<O(e)},v.$g=function(e,t,n){return x.u(e)?this[t]:this.set(n,e)},v.unix=function(){return Math.floor(this.valueOf()/1e3)},v.valueOf=function(){return this.$d.getTime()},v.startOf=function(e,t){var n=this,i=!!x.u(t)||t,c=x.p(e),f=function(e,t){var o=x.w(n.$u?Date.UTC(n.$y,t,e):new Date(n.$y,t,e),n);return i?o:o.endOf(s)},p=function(e,t){return x.w(n.toDate()[e].apply(n.toDate("s"),(i?[0,0,0,0]:[23,59,59,999]).slice(t)),n)},m=this.$W,g=this.$M,v=this.$D,y="set"+(this.$u?"UTC":"");switch(c){case d:return i?f(1,0):f(31,11);case u:return i?f(1,g):f(0,g+1);case l:var b=this.$locale().weekStart||0,w=(m<b?m+7:m)-b;return f(i?v-w:v+(6-w),g);case s:case h:return p(y+"Hours",0);case a:return p(y+"Minutes",1);case r:return p(y+"Seconds",2);case o:return p(y+"Milliseconds",3);default:return this.clone()}},v.endOf=function(e){return this.startOf(e,!1)},v.$set=function(e,t){var n,l=x.p(e),c="set"+(this.$u?"UTC":""),f=(n={},n[s]=c+"Date",n[h]=c+"Date",n[u]=c+"Month",n[d]=c+"FullYear",n[a]=c+"Hours",n[r]=c+"Minutes",n[o]=c+"Seconds",n[i]=c+"Milliseconds",n)[l],p=l===s?this.$D+(t-this.$W):t;if(l===u||l===d){var m=this.clone().set(h,1);m.$d[f](p),m.init(),this.$d=m.set(h,Math.min(this.$D,m.daysInMonth())).$d}else f&&this.$d[f](p);return this.init(),this},v.set=function(e,t){return this.clone().$set(e,t)},v.get=function(e){return this[x.p(e)]()},v.add=function(i,c){var h,f=this;i=Number(i);var p=x.p(c),m=function(e){var t=O(f);return x.w(t.date(t.date()+Math.round(e*i)),f)};if(p===u)return this.set(u,this.$M+i);if(p===d)return this.set(d,this.$y+i);if(p===s)return m(1);if(p===l)return m(7);var g=(h={},h[r]=t,h[a]=n,h[o]=e,h)[p]||1,v=this.$d.getTime()+i*g;return x.w(v,this)},v.subtract=function(e,t){return this.add(-1*e,t)},v.format=function(e){var t=this,n=this.$locale();if(!this.isValid())return n.invalidDate||f;var i=e||"YYYY-MM-DDTHH:mm:ssZ",o=x.z(this),r=this.$H,a=this.$m,s=this.$M,l=n.weekdays,u=n.months,c=n.meridiem,d=function(e,n,o,r){return e&&(e[n]||e(t,i))||o[n].slice(0,r)},h=function(e){return x.s(r%12||12,e,"0")},p=c||function(e,t,n){var i=e<12?"AM":"PM";return n?i.toLowerCase():i};return i.replace(m,function(e,i){return i||function(e){switch(e){case"YY":return String(t.$y).slice(-2);case"YYYY":return x.s(t.$y,4,"0");case"M":return s+1;case"MM":return x.s(s+1,2,"0");case"MMM":return d(n.monthsShort,s,u,3);case"MMMM":return d(u,s);case"D":return t.$D;case"DD":return x.s(t.$D,2,"0");case"d":return String(t.$W);case"dd":return d(n.weekdaysMin,t.$W,l,2);case"ddd":return d(n.weekdaysShort,t.$W,l,3);case"dddd":return l[t.$W];case"H":return String(r);case"HH":return x.s(r,2,"0");case"h":return h(1);case"hh":return h(2);case"a":return p(r,a,!0);case"A":return p(r,a,!1);case"m":return String(a);case"mm":return x.s(a,2,"0");case"s":return String(t.$s);case"ss":return x.s(t.$s,2,"0");case"SSS":return x.s(t.$ms,3,"0");case"Z":return o}return null}(e)||o.replace(":","")})},v.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},v.diff=function(i,h,f){var p,m=this,g=x.p(h),v=O(i),y=(v.utcOffset()-this.utcOffset())*t,b=this-v,w=function(){return x.m(m,v)};switch(g){case d:p=w()/12;break;case u:p=w();break;case c:p=w()/3;break;case l:p=(b-y)/6048e5;break;case s:p=(b-y)/864e5;break;case a:p=b/n;break;case r:p=b/t;break;case o:p=b/e;break;default:p=b}return f?p:x.a(p)},v.daysInMonth=function(){return this.endOf(u).$D},v.$locale=function(){return w[this.$L]},v.locale=function(e,t){if(!e)return this.$L;var n=this.clone(),i=k(e,t,!0);return i&&(n.$L=i),n},v.clone=function(){return x.w(this.$d,this)},v.toDate=function(){return new Date(this.valueOf())},v.toJSON=function(){return this.isValid()?this.toISOString():null},v.toISOString=function(){return this.$d.toISOString()},v.toString=function(){return this.$d.toUTCString()},g}(),I=M.prototype;return O.prototype=I,[["$ms",i],["$s",o],["$m",r],["$H",a],["$W",s],["$M",u],["$y",d],["$D",h]].forEach(function(e){I[e[1]]=function(t){return this.$g(t,e[0],e[1])}}),O.extend=function(e,t){return e.$i||(e(t,M,O),e.$i=!0),O},O.locale=k,O.isDayjs=S,O.unix=function(e){return O(1e3*e)},O.en=w[b],O.Ls=w,O.p={},O}()},373:e=>{e.exports=function(e){var t=Object(e),n=[];for(var i in t)n.unshift(i);return function e(){for(;n.length;)if((i=n.pop())in t)return e.value=i,e.done=!1,e;return e.done=!0,e}},e.exports.__esModule=!0,e.exports.default=e.exports},445:function(e){e.exports=function(){"use strict";var e="minute",t=/[+-]\d\d(?::?\d\d)?/g,n=/([+-]|\d\d)/g;return function(i,o,r){var a=o.prototype;r.utc=function(e){return new o({date:e,utc:!0,args:arguments})},a.utc=function(t){var n=r(this.toDate(),{locale:this.$L,utc:!0});return t?n.add(this.utcOffset(),e):n},a.local=function(){return r(this.toDate(),{locale:this.$L,utc:!1})};var s=a.parse;a.parse=function(e){e.utc&&(this.$u=!0),this.$utils().u(e.$offset)||(this.$offset=e.$offset),s.call(this,e)};var l=a.init;a.init=function(){if(this.$u){var e=this.$d;this.$y=e.getUTCFullYear(),this.$M=e.getUTCMonth(),this.$D=e.getUTCDate(),this.$W=e.getUTCDay(),this.$H=e.getUTCHours(),this.$m=e.getUTCMinutes(),this.$s=e.getUTCSeconds(),this.$ms=e.getUTCMilliseconds()}else l.call(this)};var u=a.utcOffset;a.utcOffset=function(i,o){var r=this.$utils().u;if(r(i))return this.$u?0:r(this.$offset)?u.call(this):this.$offset;if("string"==typeof i&&(i=function(e){void 0===e&&(e="");var i=e.match(t);if(!i)return null;var o=(""+i[0]).match(n)||["-",0,0],r=o[0],a=60*+o[1]+ +o[2];return 0===a?0:"+"===r?a:-a}(i),null===i))return this;var a=Math.abs(i)<=16?60*i:i;if(0===a)return this.utc(o);var s=this.clone();if(o)return s.$offset=a,s.$u=!1,s;var l=this.$u?this.toDate().getTimezoneOffset():-1*this.utcOffset();return(s=this.local().add(a+l,e)).$offset=a,s.$x.$localOffset=l,s};var c=a.format;a.format=function(e){var t=e||(this.$u?"YYYY-MM-DDTHH:mm:ss[Z]":"");return c.call(this,t)},a.valueOf=function(){var e=this.$utils().u(this.$offset)?0:this.$offset+(this.$x.$localOffset||this.$d.getTimezoneOffset());return this.$d.valueOf()-6e4*e},a.isUTC=function(){return!!this.$u},a.toISOString=function(){return this.toDate().toISOString()},a.toString=function(){return this.toDate().toUTCString()};var d=a.toDate;a.toDate=function(e){return"s"===e&&this.$offset?r(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate():d.call(this)};var h=a.diff;a.diff=function(e,t,n){if(e&&this.$u===e.$u)return h.call(this,e,t,n);var i=this.local(),o=r(e).local();return h.call(i,o,t,n)}}}()},494:function(e,t,n){e.exports=function(e){"use strict";function t(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var n=t(e),i={s:"ein paar Sekunden",m:["eine Minute","einer Minute"],mm:"%d Minuten",h:["eine Stunde","einer Stunde"],hh:"%d Stunden",d:["ein Tag","einem Tag"],dd:["%d Tage","%d Tagen"],M:["ein Monat","einem Monat"],MM:["%d Monate","%d Monaten"],y:["ein Jahr","einem Jahr"],yy:["%d Jahre","%d Jahren"]};function o(e,t,n){var o=i[n];return Array.isArray(o)&&(o=o[t?0:1]),o.replace("%d",e)}var r={name:"de",weekdays:"Sonntag_Montag_Dienstag_Mittwoch_Donnerstag_Freitag_Samstag".split("_"),weekdaysShort:"So._Mo._Di._Mi._Do._Fr._Sa.".split("_"),weekdaysMin:"So_Mo_Di_Mi_Do_Fr_Sa".split("_"),months:"Januar_Februar_März_April_Mai_Juni_Juli_August_September_Oktober_November_Dezember".split("_"),monthsShort:"Jan._Feb._März_Apr._Mai_Juni_Juli_Aug._Sept._Okt._Nov._Dez.".split("_"),ordinal:function(e){return e+"."},weekStart:1,yearStart:4,formats:{LTS:"HH:mm:ss",LT:"HH:mm",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY HH:mm",LLLL:"dddd, D. MMMM YYYY HH:mm"},relativeTime:{future:"in %s",past:"vor %s",s:o,m:o,mm:o,h:o,hh:o,d:o,dd:o,M:o,MM:o,y:o,yy:o}};return n.default.locale(r,null,!0),r}(n(353))},546:e=>{function t(n,i,o,r){var a=Object.defineProperty;try{a({},"",{})}catch(n){a=0}e.exports=t=function(e,n,i,o){function r(n,i){t(e,n,function(e){return this._invoke(n,i,e)})}n?a?a(e,n,{value:i,enumerable:!o,configurable:!o,writable:!o}):e[n]=i:(r("next",0),r("throw",1),r("return",2))},e.exports.__esModule=!0,e.exports.default=e.exports,t(n,i,o,r)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports},569:function(e){e.exports=function(){"use strict";var e={year:0,month:1,day:2,hour:3,minute:4,second:5},t={};return function(n,i,o){var r,a=function(e,n,i){void 0===i&&(i={});var o=new Date(e),r=function(e,n){void 0===n&&(n={});var i=n.timeZoneName||"short",o=e+"|"+i,r=t[o];return r||(r=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:e,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",timeZoneName:i}),t[o]=r),r}(n,i);return r.formatToParts(o)},s=function(t,n){for(var i=a(t,n),r=[],s=0;s<i.length;s+=1){var l=i[s],u=l.type,c=l.value,d=e[u];d>=0&&(r[d]=parseInt(c,10))}var h=r[3],f=24===h?0:h,p=r[0]+"-"+r[1]+"-"+r[2]+" "+f+":"+r[4]+":"+r[5]+":000",m=+t;return(o.utc(p).valueOf()-(m-=m%1e3))/6e4},l=i.prototype;l.tz=function(e,t){void 0===e&&(e=r);var n,i=this.utcOffset(),a=this.toDate(),s=a.toLocaleString("en-US",{timeZone:e}),l=Math.round((a-new Date(s))/1e3/60),u=15*-Math.round(a.getTimezoneOffset()/15)-l;if(Number(u)){if(n=o(s,{locale:this.$L}).$set("millisecond",this.$ms).utcOffset(u,!0),t){var c=n.utcOffset();n=n.add(i-c,"minute")}}else n=this.utcOffset(0,t);return n.$x.$timezone=e,n},l.offsetName=function(e){var t=this.$x.$timezone||o.tz.guess(),n=a(this.valueOf(),t,{timeZoneName:e}).find(function(e){return"timezonename"===e.type.toLowerCase()});return n&&n.value};var u=l.startOf;l.startOf=function(e,t){if(!this.$x||!this.$x.$timezone)return u.call(this,e,t);var n=o(this.format("YYYY-MM-DD HH:mm:ss:SSS"),{locale:this.$L});return u.call(n,e,t).tz(this.$x.$timezone,!0)},o.tz=function(e,t,n){var i=n&&t,a=n||t||r,l=s(+o(),a);if("string"!=typeof e)return o(e).tz(a);var u=function(e,t,n){var i=e-60*t*1e3,o=s(i,n);if(t===o)return[i,t];var r=s(i-=60*(o-t)*1e3,n);return o===r?[i,o]:[e-60*Math.min(o,r)*1e3,Math.max(o,r)]}(o.utc(e,i).valueOf(),l,a),c=u[0],d=u[1],h=o(c).utcOffset(d);return h.$x.$timezone=a,h},o.tz.guess=function(){return Intl.DateTimeFormat().resolvedOptions().timeZone},o.tz.setDefault=function(e){r=e}}}()},579:(e,t,n)=>{var i=n(738).default;e.exports=function(e){if(null!=e){var t=e["function"==typeof Symbol&&Symbol.iterator||"@@iterator"],n=0;if(t)return t.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length))return{next:function(){return e&&n>=e.length&&(e=void 0),{value:e&&e[n++],done:!e}}}}throw new TypeError(i(e)+" is not iterable")},e.exports.__esModule=!0,e.exports.default=e.exports},633:(e,t,n)=>{var i=n(172),o=n(993),r=n(869),a=n(887),s=n(791),l=n(373),u=n(579);function c(){"use strict";var t=o(),n=t.m(c),d=(Object.getPrototypeOf?Object.getPrototypeOf(n):n.__proto__).constructor;function h(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===d||"GeneratorFunction"===(t.displayName||t.name))}var f={throw:1,return:2,break:3,continue:3};function p(e){var t,n;return function(i){t||(t={stop:function(){return n(i.a,2)},catch:function(){return i.v},abrupt:function(e,t){return n(i.a,f[e],t)},delegateYield:function(e,o,r){return t.resultName=o,n(i.d,u(e),r)},finish:function(e){return n(i.f,e)}},n=function(e,n,o){i.p=t.prev,i.n=t.next;try{return e(n,o)}finally{t.next=i.n}}),t.resultName&&(t[t.resultName]=i.v,t.resultName=void 0),t.sent=i.v,t.next=i.n;try{return e.call(this,t)}finally{i.p=t.prev,i.n=t.next}}}return(e.exports=c=function(){return{wrap:function(e,n,i,o){return t.w(p(e),n,i,o&&o.reverse())},isGeneratorFunction:h,mark:t.m,awrap:function(e,t){return new i(e,t)},AsyncIterator:s,async:function(e,t,n,i,o){return(h(t)?a:r)(p(e),t,n,i,o)},keys:l,values:u}},e.exports.__esModule=!0,e.exports.default=e.exports)()}e.exports=c,e.exports.__esModule=!0,e.exports.default=e.exports},738:e=>{function t(n){return e.exports=t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e.exports.__esModule=!0,e.exports.default=e.exports,t(n)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports},756:(e,t,n)=>{var i=n(633)();e.exports=i;try{regeneratorRuntime=i}catch(e){"object"==typeof globalThis?globalThis.regeneratorRuntime=i:Function("r","regeneratorRuntime = r")(i)}},791:(e,t,n)=>{var i=n(172),o=n(546);e.exports=function e(t,n){function r(e,o,a,s){try{var l=t[e](o),u=l.value;return u instanceof i?n.resolve(u.v).then(function(e){r("next",e,a,s)},function(e){r("throw",e,a,s)}):n.resolve(u).then(function(e){l.value=e,a(l)},function(e){return r("throw",e,a,s)})}catch(e){s(e)}}var a;this.next||(o(e.prototype),o(e.prototype,"function"==typeof Symbol&&Symbol.asyncIterator||"@asyncIterator",function(){return this})),o(this,"_invoke",function(e,t,i){function o(){return new n(function(t,n){r(e,i,t,n)})}return a=a?a.then(o,o):o()},!0)},e.exports.__esModule=!0,e.exports.default=e.exports},813:function(e,t,n){e.exports=function(e){"use strict";function t(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var n=t(e),i={name:"fr",weekdays:"dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi".split("_"),weekdaysShort:"dim._lun._mar._mer._jeu._ven._sam.".split("_"),weekdaysMin:"di_lu_ma_me_je_ve_sa".split("_"),months:"janvier_février_mars_avril_mai_juin_juillet_août_septembre_octobre_novembre_décembre".split("_"),monthsShort:"janv._févr._mars_avr._mai_juin_juil._août_sept._oct._nov._déc.".split("_"),weekStart:1,yearStart:4,formats:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},relativeTime:{future:"dans %s",past:"il y a %s",s:"quelques secondes",m:"une minute",mm:"%d minutes",h:"une heure",hh:"%d heures",d:"un jour",dd:"%d jours",M:"un mois",MM:"%d mois",y:"un an",yy:"%d ans"},ordinal:function(e){return e+(1===e?"er":"")}};return n.default.locale(i,null,!0),i}(n(353))},826:function(e){e.exports=function(){"use strict";return{name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(e){var t=["th","st","nd","rd"],n=e%100;return"["+e+(t[(n-20)%10]||t[n]||t[0])+"]"}}}()},840:function(e){e.exports=function(){"use strict";return function(e,t,n){var i=t.prototype,o=function(e){return e&&(e.indexOf?e:e.s)},r=function(e,t,n,i,r){var a=e.name?e:e.$locale(),s=o(a[t]),l=o(a[n]),u=s||l.map(function(e){return e.slice(0,i)});if(!r)return u;var c=a.weekStart;return u.map(function(e,t){return u[(t+(c||0))%7]})},a=function(){return n.Ls[n.locale()]},s=function(e,t){return e.formats[t]||function(e){return e.replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(e,t,n){return t||n.slice(1)})}(e.formats[t.toUpperCase()])},l=function(){var e=this;return{months:function(t){return t?t.format("MMMM"):r(e,"months")},monthsShort:function(t){return t?t.format("MMM"):r(e,"monthsShort","months",3)},firstDayOfWeek:function(){return e.$locale().weekStart||0},weekdays:function(t){return t?t.format("dddd"):r(e,"weekdays")},weekdaysMin:function(t){return t?t.format("dd"):r(e,"weekdaysMin","weekdays",2)},weekdaysShort:function(t){return t?t.format("ddd"):r(e,"weekdaysShort","weekdays",3)},longDateFormat:function(t){return s(e.$locale(),t)},meridiem:this.$locale().meridiem,ordinal:this.$locale().ordinal}};i.localeData=function(){return l.bind(this)()},n.localeData=function(){var e=a();return{firstDayOfWeek:function(){return e.weekStart||0},weekdays:function(){return n.weekdays()},weekdaysShort:function(){return n.weekdaysShort()},weekdaysMin:function(){return n.weekdaysMin()},months:function(){return n.months()},monthsShort:function(){return n.monthsShort()},longDateFormat:function(t){return s(e,t)},meridiem:e.meridiem,ordinal:e.ordinal}},n.months=function(){return r(a(),"months")},n.monthsShort=function(){return r(a(),"monthsShort","months",3)},n.weekdays=function(e){return r(a(),"weekdays",null,null,e)},n.weekdaysShort=function(e){return r(a(),"weekdaysShort","weekdays",3,e)},n.weekdaysMin=function(e){return r(a(),"weekdaysMin","weekdays",2,e)}}}()},869:(e,t,n)=>{var i=n(887);e.exports=function(e,t,n,o,r){var a=i(e,t,n,o,r);return a.next().then(function(e){return e.done?e.value:a.next()})},e.exports.__esModule=!0,e.exports.default=e.exports},887:(e,t,n)=>{var i=n(993),o=n(791);e.exports=function(e,t,n,r,a){return new o(i().w(e,t,n,r),a||Promise)},e.exports.__esModule=!0,e.exports.default=e.exports},900:function(e,t,n){e.exports=function(e){"use strict";function t(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}var n=t(e),i={name:"it",weekdays:"domenica_lunedì_martedì_mercoledì_giovedì_venerdì_sabato".split("_"),weekdaysShort:"dom_lun_mar_mer_gio_ven_sab".split("_"),weekdaysMin:"do_lu_ma_me_gi_ve_sa".split("_"),months:"gennaio_febbraio_marzo_aprile_maggio_giugno_luglio_agosto_settembre_ottobre_novembre_dicembre".split("_"),weekStart:1,monthsShort:"gen_feb_mar_apr_mag_giu_lug_ago_set_ott_nov_dic".split("_"),formats:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},relativeTime:{future:"tra %s",past:"%s fa",s:"qualche secondo",m:"un minuto",mm:"%d minuti",h:"un'ora",hh:"%d ore",d:"un giorno",dd:"%d giorni",M:"un mese",MM:"%d mesi",y:"un anno",yy:"%d anni"},ordinal:function(e){return e+"º"}};return n.default.locale(i,null,!0),i}(n(353))},993:(e,t,n)=>{var i=n(546);function o(){var t,n,r="function"==typeof Symbol?Symbol:{},a=r.iterator||"@@iterator",s=r.toStringTag||"@@toStringTag";function l(e,o,r,a){var s=o&&o.prototype instanceof c?o:c,l=Object.create(s.prototype);return i(l,"_invoke",function(e,i,o){var r,a,s,l=0,c=o||[],d=!1,h={p:0,n:0,v:t,a:f,f:f.bind(t,4),d:function(e,n){return r=e,a=0,s=t,h.n=n,u}};function f(e,i){for(a=e,s=i,n=0;!d&&l&&!o&&n<c.length;n++){var o,r=c[n],f=h.p,p=r[2];e>3?(o=p===i)&&(s=r[(a=r[4])?5:(a=3,3)],r[4]=r[5]=t):r[0]<=f&&((o=e<2&&f<r[1])?(a=0,h.v=i,h.n=r[1]):f<p&&(o=e<3||r[0]>i||i>p)&&(r[4]=e,r[5]=i,h.n=p,a=0))}if(o||e>1)return u;throw d=!0,i}return function(o,c,p){if(l>1)throw TypeError("Generator is already running");for(d&&1===c&&f(c,p),a=c,s=p;(n=a<2?t:s)||!d;){r||(a?a<3?(a>1&&(h.n=-1),f(a,s)):h.n=s:h.v=s);try{if(l=2,r){if(a||(o="next"),n=r[o]){if(!(n=n.call(r,s)))throw TypeError("iterator result is not an object");if(!n.done)return n;s=n.value,a<2&&(a=0)}else 1===a&&(n=r.return)&&n.call(r),a<2&&(s=TypeError("The iterator does not provide a '"+o+"' method"),a=1);r=t}else if((n=(d=h.n<0)?s:e.call(i,h))!==u)break}catch(e){r=t,a=1,s=e}finally{l=1}}return{value:n,done:d}}}(e,r,a),!0),l}var u={};function c(){}function d(){}function h(){}n=Object.getPrototypeOf;var f=[][a]?n(n([][a]())):(i(n={},a,function(){return this}),n),p=h.prototype=c.prototype=Object.create(f);function m(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,h):(e.__proto__=h,i(e,s,"GeneratorFunction")),e.prototype=Object.create(p),e}return d.prototype=h,i(p,"constructor",h),i(h,"constructor",d),d.displayName="GeneratorFunction",i(h,s,"GeneratorFunction"),i(p),i(p,s,"Generator"),i(p,a,function(){return this}),i(p,"toString",function(){return"[object Generator]"}),(e.exports=o=function(){return{w:l,m}},e.exports.__esModule=!0,e.exports.default=e.exports)()}e.exports=o,e.exports.__esModule=!0,e.exports.default=e.exports}},t={};function n(i){var o=t[i];if(void 0!==o)return o.exports;var r=t[i]={exports:{}};return e[i].call(r.exports,r,r.exports,n),r.exports}n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var i in t)n.o(t,i)&&!n.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var i={};return(()=>{"use strict";n.r(i),n.d(i,{EmbedView:()=>d,Languages:()=>c,changeLanguage:()=>le,close:()=>ae,closeEmbed:()=>pe,destroy:()=>ue,init:()=>oe,open:()=>re,openEmbed:()=>fe,renderHolidoitEmbed:()=>de,toggle:()=>se,toggleEmbed:()=>he,version:()=>ce});var e=n(353),t=n.n(e),o=(n(494),n(826),n(317),n(813),n(900),n(840)),r=n.n(o),a=n(569),s=n.n(a),l=n(445),u=n.n(l);t().extend(u()),t().extend(s()),t().extend(r());var c=function(e){return e.ITALIAN="it",e.ENGLISH="en",e.SPANISH="es",e.FRENCH="fr",e.GERMAN="de",e}({}),d=function(e){return e.EXPERIENCES="experiences",e.COMBOS="combos",e}({});t()().locale("it").localeData().months(),t()().locale("it").localeData().weekdays(),t()().locale("en").localeData().months(),t()().locale("en").localeData().weekdays(),t()().locale("de").localeData().months(),t()().locale("de").localeData().weekdays(),t()().locale("es").localeData().months(),t()().locale("es").localeData().weekdays(),t()().locale("fr").localeData().months(),t()().locale("fr").localeData().weekdays();function h(e,t,n,i,o,r,a){try{var s=e[r](a),l=s.value}catch(e){return void n(e)}s.done?t(l):Promise.resolve(l).then(i,o)}function f(e){return function(){var t=this,n=arguments;return new Promise(function(i,o){var r=e.apply(t,n);function a(e){h(r,i,o,a,s,"next",e)}function s(e){h(r,i,o,a,s,"throw",e)}a(void 0)})}}function p(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=Array(t);n<t;n++)i[n]=e[n];return i}function m(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var i,o,r,a,s=[],l=!0,u=!1;try{if(r=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;l=!1}else for(;!(l=(i=r.call(n)).done)&&(s.push(i.value),s.length!==t);l=!0);}catch(e){u=!0,o=e}finally{try{if(!l&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(u)throw o}}return s}}(e,t)||function(e,t){if(e){if("string"==typeof e)return p(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?p(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function g(e){return g="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},g(e)}function v(e){var t=function(e,t){if("object"!=g(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var i=n.call(e,t||"default");if("object"!=g(i))return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==g(t)?t:t+""}function y(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,v(i.key),i)}}function b(e,t,n){return(t=v(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var w=n(756),_=n.n(w),S="holidoit-loader-iframe",k="2.0.0",O="_holidoit_payment_session";var x="holidoit_analytics_dedupe_keys",M=new Set;function I(e){return"object"===g(e)&&null!==e&&!Array.isArray(e)}function L(){if("undefined"==typeof window)return null;try{return window.sessionStorage}catch(e){return null}}function E(){var e=L();if(!e)return[];try{var t=e.getItem(x);if(!t)return[];var n=JSON.parse(t);return Array.isArray(n)?n.filter(function(e){return"string"==typeof e&&e.length>0}):[]}catch(e){return[]}}function D(e){if(e){M.add(e);var t=E().filter(function(t){return t!==e});t.push(e),function(e){var t=L();if(t)try{t.setItem(x,JSON.stringify(e.slice(-200)))}catch(e){}}(t)}}function T(e,t){return"undefined"!=typeof window&&(!function(e){return!(!e||!M.has(e)&&(!E().includes(e)||(M.add(e),0)))}(t)&&(Array.isArray(window.dataLayer)||(window.dataLayer=[]),D(t),window.dataLayer.push(e),!0))}function C(e){if(!I(e)||"HOLIDOIT_ANALYTICS_EVENT"!==e.type)return null;var t,n=I(e.payload)?e.payload:e,i=n.channel,o=n.dedupeKey,r=n.eventData,a=n.source,s=n.widgetType;return"dataLayer"!==i||"embed"!==a&&"widget"!==a||"string"!=typeof o||""===o.trim()||(!I(t=r)||"string"!=typeof t.event||""===t.event.trim())?null:{channel:i,dedupeKey:o.trim(),eventData:r,source:a,widgetType:"string"==typeof s&&s.trim()?s:void 0}}function B(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return $(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?$(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var i=0,o=function(){};return{s:o,n:function(){return i>=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var r,a=!0,s=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){s=!0,r=e},f:function(){try{a||null==n.return||n.return()}finally{if(s)throw r}}}}function $(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=Array(t);n<t;n++)i[n]=e[n];return i}var A="experience_groups",H="experiences";function P(e){var t=Array.isArray(e)?e:"string"==typeof e?e.split(","):null==e?[]:[e],n=[];return t.forEach(function(e){var t="number"==typeof e?e:parseInt(String(e).trim(),10);Number.isInteger(t)&&t>0&&!n.includes(t)&&n.push(t)}),n}function V(e,t){var n,i=B(t);try{for(i.s();!(n=i.n()).done;){var o,r,a,s=n.value,l=null!==(o=null!==(r=e.getAttribute(s))&&void 0!==r?r:null===(a=e.closest("[".concat(s,"]")))||void 0===a?void 0:a.getAttribute(s))&&void 0!==o?o:null;if(null!==l)return P(l)}}catch(e){i.e(e)}finally{i.f()}return[]}function Y(e){return V(e,["data-experience-groups","data-experience-group"])}function R(e){return P(e.get(H))}function j(e){return V(e,["data-experiences"])}function U(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,i)}return n}function N(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?U(Object(n),!0).forEach(function(t){b(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):U(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var F="holidoit_recovery";function G(){return(G=f(_().mark(function e(t,n,i){var o,r;return _().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=1,fetch("".concat(t,"/api/v2/embed/").concat(encodeURIComponent(n),"/checkout-recovery?token=").concat(encodeURIComponent(i)));case 1:if((o=e.sent).ok){e.next=2;break}return e.abrupt("return",null);case 2:return e.next=3,o.json();case 3:return r=e.sent,e.abrupt("return",N(N({},r),{},{token:i}));case 4:return e.prev=4,e.catch(0),e.abrupt("return",null);case 5:case"end":return e.stop()}},e,null,[[0,4]])}))).apply(this,arguments)}function W(){var e,t,n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},o=n.view===d.COMBOS?d.COMBOS:n.view===d.EXPERIENCES||n.experienceId||n.gift||n.giftCard||null!==(e=n.experienceGroupIds)&&void 0!==e&&e.length||null!==(t=n.experienceIds)&&void 0!==t&&t.length?d.EXPERIENCES:i.view===d.COMBOS?d.COMBOS:d.EXPERIENCES,r=void 0===n.comboId?i.comboId:n.comboId;return{view:o,comboId:o===d.COMBOS&&Number.isSafeInteger(r)&&r>0?r:null}}var z=new Set(["holidoit.js","embed.html","payment-redirect.html","widgets/widget-book-now-button.html","widgets/widget-booking-box.html","widgets/widget-experience.html","widgets/widget-experience-grid.html","widgets/widget-experience-grid-drawer.html","widgets/widget-experience-page-drawer.html"]);function K(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return J(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?J(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var i=0,o=function(){};return{s:o,n:function(){return i>=e.length?{done:!0}:{done:!1,value:e[i++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var r,a=!0,s=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return a=e.done,e},e:function(e){s=!0,r=e},f:function(){try{a||null==n.return||n.return()}finally{if(s)throw r}}}}function J(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=Array(t);n<t;n++)i[n]=e[n];return i}function q(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,i)}return n}function Z(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?q(Object(n),!0).forEach(function(t){b(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):q(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var X=function(){if("undefined"==typeof window)return null;try{var e=new URLSearchParams(window.location.search),t=e.get("payment_intent");if(!t)return null;var n={paymentIntent:t,paymentIntentClientSecret:e.get("payment_intent_client_secret"),redirectStatus:e.get("redirect_status")};"localhost"===window.location.hostname||window.location.hostname;return n}catch(e){return null}}(),Q=!1,ee=new Set(["holidoitExperienceSelected","holidoitGiftCardSelected","holidoitComboSelected","holidoitIFrameChangeLanguage","holidoitExperienceCount"]),te=Object.values(c),ne=b(b(b(b(b({},c.ITALIAN,"Prenota ora"),c.ENGLISH,"Book now"),c.SPANISH,"Reservar ahora"),c.FRENCH,"Réserver maintenant"),c.GERMAN,"Jetzt buchen");var ie=new(function(){return e=function e(){var t=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),b(this,"config",null),b(this,"recoveryToken",null),b(this,"embedConfig",null),b(this,"iframe",null),b(this,"container",null),b(this,"floatingButton",null),b(this,"isOpen",!1),b(this,"hasDrawerEntered",!1),b(this,"closeTimeout",null),b(this,"isReady",!1),b(this,"pendingMessages",[]),b(this,"embedOrigin",""),b(this,"resolvedEmbedUrl",""),b(this,"resolvedApiUrl",""),b(this,"htmlLangObserver",null),b(this,"hasExplicitLanguageSelection",!1),b(this,"hasReceivedEmbedReady",!1),b(this,"embedConfigLoaded",!1),b(this,"previouslyFocusedElement",null),b(this,"visualViewportBaselineHeight",null),b(this,"visualViewportBaselineWidth",null),b(this,"visualViewportUpdateFrame",null),b(this,"isKeyboardVisible",!1),b(this,"lastKeyboardViewportHeight",null),b(this,"lastKeyboardViewportOffsetTop",0),b(this,"keyboardOpeningGuardUntil",0),b(this,"keyboardOpeningCheckTimeout",null),b(this,"keyboardDismissalGuardUntil",0),b(this,"hostCanvasStyles",null),b(this,"scrollLockState",null),b(this,"touchMoveHandler",null),b(this,"scheduleVisualViewportUpdate",function(){null!==t.visualViewportUpdateFrame&&cancelAnimationFrame(t.visualViewportUpdateFrame),t.visualViewportUpdateFrame=requestAnimationFrame(function(){t.visualViewportUpdateFrame=null,t.syncKeyboardViewport()})}),b(this,"handleExternalMessage",function(e){var n=e.data;if(n&&"string"==typeof n.action&&ee.has(n.action)){var i=null;if(e.source!==window){if(!(i=t.getSenderIframe(e.source)))return void t.log("Ignoring external message from unknown iframe source",n.action);if(i.id===S)return;if(!t.isTrustedHolidoitOrigin(e.origin))return void t.log("Ignoring external message from untrusted origin",e.origin,n.action)}switch(t.log("Received external message",n),n.action){case"holidoitExperienceSelected":var o;n.experienceId&&(t.log("Experience selected from external iframe",n.experienceId),t.open({experienceId:n.experienceId,gift:!!n.gift,experienceGroupIds:P(null!==(o=n.experienceGroupIds)&&void 0!==o?o:n.experienceGroupId),experienceIds:P(n.experienceIds)}));break;case"holidoitGiftCardSelected":t.log("Gift card selected from external iframe"),t.open({giftCard:!0});break;case"holidoitComboSelected":var r=m(P(n.comboId),1)[0];if(r){t.log("Combo selected from external iframe",r);var a="string"==typeof n.embedId&&n.embedId?n.embedId:void 0;t.open({embedId:a,view:d.COMBOS,comboId:r})}break;case"holidoitIFrameChangeLanguage":n.language&&(t.log("Language change from external iframe",n.language),t.changeLanguage(n.language));break;case"holidoitExperienceCount":if(!i)return;if(t.log("Experience count from external iframe",n.count),"number"==typeof n.height){var s=n.height+16,l=parseInt(i.style.height||"0",10);Math.abs(s-l)>15&&(i.style.height="".concat(s,"px"),t.log("Adjusted iframe height to",s,"for",i.id||i.src))}}}}),b(this,"handleMessage",function(e){var n,i,o,r;if(t.isMessageFromOwnEmbedIframe(e)){var a,s=e.data;if("object"===g(a=s)&&null!==a&&!Array.isArray(a)&&"string"==typeof s.type&&s.type.startsWith("HOLIDOIT_")&&(t.log("Received message from embed iframe",s),!t.handleAnalyticsMessage(s)))switch(s.type){case"HOLIDOIT_READY":t.hasReceivedEmbedReady=!0,t.maybeSendInitMessage();break;case"HOLIDOIT_OPENED":t.isOpen&&null===t.closeTimeout&&(t.hasDrawerEntered=!0,t.syncContainerBackdrop());break;case"HOLIDOIT_CLOSED":t.close();break;case"HOLIDOIT_DRAWER_EXITED":null!==t.closeTimeout&&t.finishClose();break;case"HOLIDOIT_BOOKING_COMPLETE":var l=s.payload;t.recoveryToken=null,t.log("Booking complete",l),null===(n=t.config)||void 0===n||null===(i=n.onBookingComplete)||void 0===i||i.call(n,l);break;case"HOLIDOIT_PAYMENT_REDIRECT_START":var u=s.payload;if(null!=u&&u.session){t.log("Saving payment session for redirect",u.session);try{localStorage.setItem(O,JSON.stringify(u.session))}catch(e){t.log("Failed to save payment session (incognito mode?)",e)}}break;case"HOLIDOIT_LANGUAGE_CHANGED":var c=s.payload,d=t.normalizeLanguage(null==c?void 0:c.language);d&&(t.log("Language changed from embed:",d),t.applyLanguage(d,{markAsExplicit:!0,syncEmbed:!1}),window.postMessage({action:"holidoitEmbedChangeLanguage",language:d},"*"));break;case"HOLIDOIT_CHECKOUT_FIELD_FOCUS":var h,f=s.payload;if(!t.isOpen||null!==t.closeTimeout||"boolean"!=typeof(null==f?void 0:f.focused)||window.innerWidth>=775)break;t.clearKeyboardOpeningCheck(),f.focused?(t.keyboardOpeningGuardUntil=performance.now()+600,t.keyboardDismissalGuardUntil=0,t.updateKeyboardVisibility(!0,null===(h=window.visualViewport)||void 0===h?void 0:h.height),t.keyboardOpeningCheckTimeout=window.setTimeout(function(){t.keyboardOpeningCheckTimeout=null;var e=window.visualViewport;e&&null!==t.visualViewportBaselineHeight&&t.visualViewportBaselineHeight-e.height>100||t.scheduleVisualViewportUpdate()},650)):(t.keyboardOpeningGuardUntil=0,t.keyboardDismissalGuardUntil=performance.now()+450,t.updateKeyboardVisibility(!1));break;case"HOLIDOIT_ERROR":var p=s.payload;null===(o=t.config)||void 0===o||null===(r=o.onError)||void 0===r||r.call(o,(null==p?void 0:p.message)||"Unknown error");break;case"HOLIDOIT_NAVIGATE_TO":var m=s.payload;null!=m&&m.url&&(t.log("Navigating parent page to:",m.url),window.location.href=m.url)}}})},t=[{key:"isIOSDevice",value:function(){if("undefined"==typeof window||"undefined"==typeof navigator)return!1;var e=navigator.userAgent||"",t=/iPad|iPhone|iPod/.test(e),n="MacIntel"===navigator.platform&&navigator.maxTouchPoints>1;return t||n}},{key:"safeScrollToPosition",value:function(e,t){var n=null;try{(n=document.createElement("style")).textContent="html, body { scroll-behavior: auto !important; }",(document.head||document.documentElement).appendChild(n),window.scrollTo({left:e,top:t,behavior:"auto"})}catch(n){window.scrollTo(e,t)}finally{n&&requestAnimationFrame(function(){var e;null===(e=n)||void 0===e||e.remove()})}}},{key:"getDocumentScrollRoot",value:function(){var e=document.scrollingElement;return e instanceof HTMLElement?e:document.documentElement}},{key:"isDocumentScrollRoot",value:function(e){return e===this.getDocumentScrollRoot()||e===document.documentElement||e===document.body}},{key:"getScrollPosition",value:function(){return{top:window.scrollY,left:window.scrollX}}},{key:"getScrollbarWidth",value:function(){return window.innerWidth-document.documentElement.clientWidth}},{key:"restoreScrollPosition",value:function(e,t){var n=this.getScrollPosition();(Math.abs(n.top-e)>1||Math.abs(n.left-t)>1)&&this.safeScrollToPosition(t,e)}},{key:"focusWithoutScroll",value:function(e){if(e&&e.isConnected)try{e.focus({preventScroll:!0})}catch(t){e.focus()}}},{key:"init",value:function(e){var t,n,i,o,r=this;if(e.embedId&&(e.embedId=e.embedId.trim()),e.embedId){if(e.experienceGroupIds=P(null!==(t=e.experienceGroupIds)&&void 0!==t?t:e.experienceGroupId),e.experienceIds=P(e.experienceIds),delete e.experienceGroupId,this.container)return this.log("Holidoit already initialized, skipping duplicate init"),this.config=Z(Z({},this.config),e),void this.syncLanguageWithDocument();var a=window.scrollY,s=history.scrollRestoration||"auto";try{history.scrollRestoration="manual"}catch(e){this.log("scrollRestoration not supported, continuing without it")}this.hasExplicitLanguageSelection=!1,this.hasReceivedEmbedReady=!1,this.embedConfigLoaded=!1,this.visualViewportBaselineHeight=null,this.visualViewportBaselineWidth=null,this.config=Z(Z({},e),{},{language:this.normalizeLanguage(e.language)||void 0}),this.resolvedEmbedUrl=function(e){try{var t=new URL(e,"undefined"==typeof window?void 0:window.location.href),n=new URL("https://cdn.holidoit.com/");if(t.origin!==n.origin||!t.pathname.startsWith(n.pathname))return e;var i=t.pathname.slice(n.pathname.length);return z.has(i)?(t.pathname="".concat(n.pathname,"holidoit-js-releases/").concat("20261202095359217-a04cce2cb673-134cda53","/").concat(i),t.toString()):e}catch(t){return e}}(e.embedUrl||"https://cdn.holidoit.com/embed.html"),this.resolvedApiUrl="https://engine.holydoit.com",this.embedOrigin=this.getEmbedOrigin(this.resolvedEmbedUrl),this.log("Initializing Holidoit embed",{embedId:e.embedId,version:k}),this.createContainer(),this.createIframe(),null===(n=window.visualViewport)||void 0===n||n.addEventListener("resize",this.scheduleVisualViewportUpdate),null===(i=window.visualViewport)||void 0===i||i.addEventListener("scroll",this.scheduleVisualViewportUpdate,{passive:!0}),this.safeScrollToPosition(0,a),requestAnimationFrame(function(){try{history.scrollRestoration=s}catch(e){}}),this.setupMessageListener(),this.observeDocumentLanguage();var l,u,c=function(){r.bindBookNowButtons(),r.observeForBookNowButtons(),r.interceptHolidoitLinks()};"loading"===document.readyState?document.addEventListener("DOMContentLoaded",c):c(),this.recoveryToken=(l=new URL(window.location.href),(u=l.searchParams.get(F))&&(l.searchParams.delete(F),window.history.replaceState(window.history.state,"",l.toString())),u),this.fetchEmbedConfig().then(function(){var t;((null===(t=r.embedConfig)||void 0===t?void 0:t.has_floating_button)||e.floatingButton)&&r.createFloatingButton(),r.maybeSendInitMessage()}),this.checkPaymentRedirect();var d=this.recoveryToken;if(d&&null!==(o=this.config)&&void 0!==o&&o.embedId&&!Q){var h=this.config.embedId;(function(e,t,n){return G.apply(this,arguments)})(this.resolvedApiUrl,h,d).then(function(e){var t;e&&(null===(t=r.config)||void 0===t?void 0:t.embedId)===h&&r.open({experienceId:e.experience_id})})}}}},{key:"fetchEmbedConfig",value:(i=f(_().mark(function e(){var t,n,i,o,r,a,s;return _().wrap(function(e){for(;;)switch(e.prev=e.next){case 0:if(null!==(t=this.config)&&void 0!==t&&t.embedId){e.next=1;break}return e.abrupt("return");case 1:return n="".concat(this.resolvedApiUrl,"/partner/v0/embed-config/").concat(this.config.embedId,"/get"),this.log("Fetching embed config from:",n),e.prev=2,e.next=3,fetch(n,{method:"GET",headers:{"Content-Type":"application/json"}});case 3:if((i=e.sent).ok){e.next=4;break}throw new Error("Failed to fetch embed config: ".concat(i.status));case 4:return e.next=5,i.json();case 5:o=e.sent,this.embedConfig=o,this.log("Embed config loaded:",o),r=this.getDocumentLanguage(),a=this.isLanguageSupportedByEmbed(r),!this.hasExplicitLanguageSelection&&r&&a?(this.applyLanguage(r,{markAsExplicit:!1,syncEmbed:this.isReady}),this.log("Language set from <html lang>:",r)):!this.config.language&&o.language&&(this.config.language=o.language,this.log("Language set from API config:",o.language)),o.floating_button_config&&(this.config.floatingButtonOptions=this.mergeFloatingButtonOptions(this.config.floatingButtonOptions,o.floating_button_config),this.log("Merged floating button options:",this.config.floatingButtonOptions)),e.next=7;break;case 6:e.prev=6,s=e.catch(2),this.log("Failed to fetch embed config, using local options:",s);case 7:return e.prev=7,this.embedConfigLoaded=!0,e.finish(7);case 8:case"end":return e.stop()}},e,this,[[2,6,7,8]])})),function(){return i.apply(this,arguments)})},{key:"mergeFloatingButtonOptions",value:function(e,t){var n,i,o,r;return e?{desktop:Z(Z({},e.desktop),t.desktop),mobile:Z(Z({},e.mobile),t.mobile),zIndex:null!==(n=t.zIndex)&&void 0!==n?n:e.zIndex,callToAction:null!==(i=t.callToAction)&&void 0!==i?i:e.callToAction,italianCallToAction:null!==(o=t.italianCallToAction)&&void 0!==o?o:e.italianCallToAction,englishCallToAction:null!==(r=t.englishCallToAction)&&void 0!==r?r:e.englishCallToAction}:t}},{key:"open",value:function(e){var t,n,i,o,r;null!=e&&e.embedId&&(e.embedId=e.embedId.trim()),this.log("Opening embed",e),this.iframe&&this.container&&(this.clearCloseTimeout(),this.isOpen||(this.previouslyFocusedElement=document.activeElement instanceof HTMLElement&&document.activeElement!==document.body&&document.activeElement!==document.documentElement?document.activeElement:null),this.isOpen=!0,this.clearKeyboardOpeningCheck(),this.keyboardOpeningGuardUntil=0,this.keyboardDismissalGuardUntil=0,this.visualViewportBaselineHeight=null!==(t=null===(n=window.visualViewport)||void 0===n?void 0:n.height)&&void 0!==t?t:null,this.visualViewportBaselineWidth=window.innerWidth,this.lockBodyScroll(),this.container.style.display="block",this.container.style.pointerEvents="auto",this.syncContainerBackdrop(),this.scheduleVisualViewportUpdate(),this.floatingButton&&(this.floatingButton.setAttribute("inert",""),this.floatingButton.setAttribute("aria-hidden","true"),this.floatingButton.tabIndex=-1),this.postMessage({type:"HOLIDOIT_OPEN",payload:Z(Z({embedId:(null==e?void 0:e.embedId)||(null===(i=this.config)||void 0===i?void 0:i.embedId)},W(e,this.config||{})),{},{experienceId:null==e?void 0:e.experienceId,test:null==e?void 0:e.test,gift:null==e?void 0:e.gift,giftCard:null==e?void 0:e.giftCard},this.resolveScope(e))}),null===(o=this.config)||void 0===o||null===(r=o.onOpen)||void 0===r||r.call(o))}},{key:"resolveScope",value:function(e){var t,n,i,o=P(null!==(t=null==e?void 0:e.experienceGroupIds)&&void 0!==t?t:null==e?void 0:e.experienceGroupId),r=P(null==e?void 0:e.experienceIds);return o.length>0||r.length>0?{experienceGroupIds:o,experienceIds:r}:null!=(null==e?void 0:e.experienceId)?{}:{experienceGroupIds:null===(n=this.config)||void 0===n?void 0:n.experienceGroupIds,experienceIds:null===(i=this.config)||void 0===i?void 0:i.experienceIds}}},{key:"close",value:function(){var e=this;this.isOpen&&null===this.closeTimeout&&(this.log("Closing embed"),this.clearKeyboardOpeningCheck(),this.keyboardOpeningGuardUntil=0,this.keyboardDismissalGuardUntil=0,this.closeTimeout=window.setTimeout(function(){e.finishClose()},600),this.hasDrawerEntered=!1,this.syncContainerBackdrop(),this.postMessage({type:"HOLIDOIT_CLOSE"}))}},{key:"finishClose",value:function(){var e,t;this.clearCloseTimeout(),this.isOpen=!1,this.hasDrawerEntered=!1,this.clearKeyboardOpeningCheck(),this.keyboardOpeningGuardUntil=0,this.keyboardDismissalGuardUntil=0,this.updateKeyboardVisibility(!1),document.activeElement===this.iframe&&this.iframe.blur(),this.floatingButton&&(this.floatingButton.removeAttribute("inert"),this.floatingButton.removeAttribute("aria-hidden"),this.floatingButton.removeAttribute("tabindex")),this.focusWithoutScroll(this.previouslyFocusedElement),this.previouslyFocusedElement=null,this.unlockBodyScroll(),this.container&&(this.syncContainerBackdrop(),this.container.style.display="none",this.container.style.pointerEvents="none"),this.visualViewportBaselineHeight=null,this.visualViewportBaselineWidth=null,null===(e=this.config)||void 0===e||null===(t=e.onClose)||void 0===t||t.call(e)}},{key:"toggle",value:function(e){this.isOpen?this.close():this.open(e)}},{key:"changeLanguage",value:function(e){var t=this.normalizeLanguage(e);t?(this.log("Changing language",t),this.applyLanguage(t,{markAsExplicit:!0,syncEmbed:!0})):this.log("Ignoring unsupported language change",e)}},{key:"updateFloatingButtonText",value:function(e){var t,n;if(this.floatingButton&&this.config){var i=this.config.floatingButtonOptions,o=this.resolveFloatingButtonResponsiveOption(null==i||null===(t=i.desktop)||void 0===t?void 0:t.textColor,null==i||null===(n=i.mobile)||void 0===n?void 0:n.textColor,"white"),r=this.getFloatingButtonCallToAction(e),a='<svg style="fill: '.concat(o,' !important;" xmlns="http://www.w3.org/2000/svg" height="19" width="19" viewBox="0 0 448 512"><path style="fill: ').concat(o,' !important;" d="M152 24c0-13.3-10.7-24-24-24s-24 10.7-24 24V64H64C28.7 64 0 92.7 0 128v16 48V448c0 35.3 28.7 64 64 64H384c35.3 0 64-28.7 64-64V192 144 128c0-35.3-28.7-64-64-64H344V24c0-13.3-10.7-24-24-24s-24 10.7-24 24V64H152V24zM48 192H400V448c0 8.8-7.2 16-16 16H64c-8.8 0-16-7.2-16-16V192z"/></svg>');this.floatingButton.innerHTML='<span style="display: flex; align-items: center; gap: 10px; color: '.concat(o," !important; font-family: 'Google Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important; font-size: inherit !important; font-weight: inherit !important;\">").concat(a," ").concat(r,"</span>"),this.log("Updated floating button text to:",r)}}},{key:"destroy",value:function(){var e,t;this.log("Destroying embed"),this.clearCloseTimeout(),this.syncHostCanvasBackdrop(!1),this.scrollLockState&&this.unlockBodyScroll(),this.container&&(this.container.remove(),this.container=null),this.floatingButton&&(this.floatingButton.remove(),this.floatingButton=null),this.htmlLangObserver&&(this.htmlLangObserver.disconnect(),this.htmlLangObserver=null),this.iframe=null,this.config=null,this.isOpen=!1,this.hasDrawerEntered=!1,this.isReady=!1,this.hasExplicitLanguageSelection=!1,this.hasReceivedEmbedReady=!1,this.embedConfigLoaded=!1,this.clearKeyboardOpeningCheck(),this.keyboardOpeningGuardUntil=0,this.keyboardDismissalGuardUntil=0,this.visualViewportBaselineHeight=null,this.visualViewportBaselineWidth=null,window.removeEventListener("message",this.handleMessage),window.removeEventListener("message",this.handleExternalMessage),null===(e=window.visualViewport)||void 0===e||e.removeEventListener("resize",this.scheduleVisualViewportUpdate),null===(t=window.visualViewport)||void 0===t||t.removeEventListener("scroll",this.scheduleVisualViewportUpdate),null!==this.visualViewportUpdateFrame&&(cancelAnimationFrame(this.visualViewportUpdateFrame),this.visualViewportUpdateFrame=null),this.touchMoveHandler&&(document.removeEventListener("touchmove",this.touchMoveHandler),this.touchMoveHandler=null)}},{key:"clearKeyboardOpeningCheck",value:function(){null!==this.keyboardOpeningCheckTimeout&&(window.clearTimeout(this.keyboardOpeningCheckTimeout),this.keyboardOpeningCheckTimeout=null)}},{key:"clearCloseTimeout",value:function(){null!==this.closeTimeout&&(window.clearTimeout(this.closeTimeout),this.closeTimeout=null)}},{key:"syncKeyboardViewport",value:function(){var e,t=window.visualViewport;if(this.container&&this.isOpen&&null===this.closeTimeout&&t){if(this.syncContainerBackdrop(),window.innerWidth>=775)return this.visualViewportBaselineHeight=t.height,this.visualViewportBaselineWidth=window.innerWidth,void this.updateKeyboardVisibility(!1,t.height);if(performance.now()<this.keyboardDismissalGuardUntil)this.updateKeyboardVisibility(!1,t.height);else{if(null===this.visualViewportBaselineWidth||Math.abs(this.visualViewportBaselineWidth-window.innerWidth)>2)return this.visualViewportBaselineWidth=window.innerWidth,this.visualViewportBaselineHeight=t.height,void this.updateKeyboardVisibility(!1,t.height);var n=null!==(e=this.visualViewportBaselineHeight)&&void 0!==e?e:t.height;this.visualViewportBaselineHeight=Math.max(n,t.height);var i=this.visualViewportBaselineHeight-t.height>100||performance.now()<this.keyboardOpeningGuardUntil;this.updateKeyboardVisibility(i,t.height)}}}},{key:"updateKeyboardVisibility",value:function(e,t){e&&this.isOpen&&!this.hasDrawerEntered&&(this.hasDrawerEntered=!0,this.syncContainerBackdrop());var n="number"==typeof t&&t>0?Math.round(t):null,i=e&&this.iframe?Math.max(0,Math.round(-this.iframe.getBoundingClientRect().top)):0;(this.isKeyboardVisible!==e||e&&(this.lastKeyboardViewportHeight!==n||this.lastKeyboardViewportOffsetTop!==i))&&(this.isKeyboardVisible=e,this.lastKeyboardViewportHeight=e?n:null,this.lastKeyboardViewportOffsetTop=i,this.syncContainerBackdrop(),this.postMessage({type:"HOLIDOIT_KEYBOARD_VISIBILITY",payload:Z({visible:e,viewportOffsetTop:i},null!==n&&{viewportHeight:n})}))}},{key:"syncContainerBackdrop",value:function(){var e,t,n=this.isOpen&&this.hasDrawerEntered&&window.innerWidth<775,i=n?this.isKeyboardVisible?"#fff":"linear-gradient(to bottom, transparent calc(2dvh + 16px), #fff 0)":"transparent";null===(e=this.container)||void 0===e||e.style.setProperty("background",i,"important"),null===(t=this.iframe)||void 0===t||t.style.setProperty("background",i,"important");var o=window.visualViewport,r=null!==this.hostCanvasStyles&&o&&null!==this.visualViewportBaselineHeight&&this.visualViewportBaselineHeight-o.height>100;this.syncHostCanvasBackdrop(n&&this.isIOSDevice()&&(this.isKeyboardVisible||!!r))}},{key:"syncHostCanvasBackdrop",value:function(e){var t;if(e){if(this.hostCanvasStyles)return;this.hostCanvasStyles=[];for(var n=0,i=[document.documentElement,document.body];n<i.length;n++)for(var o=i[n],r=0,a=[["background-color","#fff"],["background-image","none"]];r<a.length;r++){var s=m(a[r],2),l=s[0],u=s[1],c=o.style.getPropertyValue(l),d=o.style.getPropertyPriority(l);o.style.setProperty(l,u,"important"),this.hostCanvasStyles.push({element:o,property:l,value:c,priority:d,appliedValue:o.style.getPropertyValue(l)})}}else{var h,f=K(null!==(t=this.hostCanvasStyles)&&void 0!==t?t:[]);try{for(f.s();!(h=f.n()).done;){var p=h.value,g=p.element,v=p.property,y=p.value,b=p.priority,w=p.appliedValue;g.style.getPropertyValue(v)===w&&"important"===g.style.getPropertyPriority(v)&&(y?g.style.setProperty(v,y,b):g.style.removeProperty(v))}}catch(e){f.e(e)}finally{f.f()}this.hostCanvasStyles=null}}},{key:"createContainer",value:function(){this.container=document.createElement("div"),this.container.id="holidoit-loader-container",this.container.style.cssText="\n position: fixed !important;\n top: 0 !important;\n left: 0 !important;\n width: 100% !important;\n height: 100% !important;\n z-index: 2147483647 !important;\n display: none;\n pointer-events: none;\n ",document.body.appendChild(this.container)}},{key:"createIframe",value:function(){var e=this;this.container&&this.config&&(this.iframe=document.createElement("iframe"),this.iframe.id=S,this.iframe.src=this.resolvedEmbedUrl,this.iframe.allow="payment",this.iframe.setAttribute("tabindex","-1"),this.iframe.style.cssText="\n position: absolute !important;\n top: 0 !important;\n left: 0 !important;\n width: 100% !important;\n height: 100% !important;\n border: none !important;\n background: transparent !important;\n ",this.iframe.setAttribute("sandbox","allow-scripts allow-same-origin allow-forms allow-popups allow-popups-to-escape-sandbox allow-top-navigation-by-user-activation allow-top-navigation"),this.container.appendChild(this.iframe),document.activeElement===this.iframe&&this.iframe.blur(),this.iframe.onload=function(){e.log("Iframe loaded, waiting for HOLIDOIT_READY from embed")})}},{key:"createFloatingButton",value:function(){var e,t,n,i,o,r,a,s,l,u,d,h,f,p,m,g,v,y,b,w,_,S,k,O,x=this;if(this.config){var M=this.config.floatingButtonOptions;this.floatingButton=document.createElement("button"),this.floatingButton.id="holidoit-floating-button";var I=window.innerWidth,L=I<775,E=this.resolveFloatingButtonResponsiveOption(null==M||null===(e=M.desktop)||void 0===e?void 0:e.width,null==M||null===(t=M.mobile)||void 0===t?void 0:t.width,L?I-34:190),D=this.resolveFloatingButtonResponsiveOption(null==M||null===(n=M.desktop)||void 0===n?void 0:n.height,null==M||null===(i=M.mobile)||void 0===i?void 0:i.height,54),T=this.resolveFloatingButtonResponsiveOption(null==M||null===(o=M.desktop)||void 0===o?void 0:o.backgroundColor,null==M||null===(r=M.mobile)||void 0===r?void 0:r.backgroundColor,"#0f172a"),C=this.resolveFloatingButtonResponsiveOption(null==M||null===(a=M.desktop)||void 0===a?void 0:a.textColor,null==M||null===(s=M.mobile)||void 0===s?void 0:s.textColor,"white"),B=this.resolveFloatingButtonResponsiveOption(null==M||null===(l=M.desktop)||void 0===l?void 0:l.borderRounding,null==M||null===(u=M.mobile)||void 0===u?void 0:u.borderRounding,30),$=this.resolveFloatingButtonResponsiveOption(null==M||null===(d=M.desktop)||void 0===d?void 0:d.fontSize,null==M||null===(h=M.mobile)||void 0===h?void 0:h.fontSize,16),A=this.resolveFloatingButtonResponsiveOption(null==M||null===(f=M.desktop)||void 0===f?void 0:f.fontWeight,null==M||null===(p=M.mobile)||void 0===p?void 0:p.fontWeight,500),H=this.resolveFloatingButtonResponsiveOption(null==M||null===(m=M.desktop)||void 0===m?void 0:m.textCase,null==M||null===(g=M.mobile)||void 0===g?void 0:g.textCase,"none"),P=this.resolveFloatingButtonResponsiveOption(null==M||null===(v=M.desktop)||void 0===v?void 0:v.bottomPosition,null==M||null===(y=M.mobile)||void 0===y?void 0:y.bottomPosition,L?22:30),V=this.resolveFloatingButtonResponsiveOption(null==M||null===(b=M.desktop)||void 0===b?void 0:b.rightPosition,null==M||null===(w=M.mobile)||void 0===w?void 0:w.rightPosition,L?17:30),Y=this.resolveFloatingButtonResponsiveOption(null==M||null===(_=M.desktop)||void 0===_?void 0:_.leftPosition,null==M||null===(S=M.mobile)||void 0===S?void 0:S.leftPosition,void 0),R=this.resolveFloatingButtonResponsiveOption(null==M||null===(k=M.desktop)||void 0===k?void 0:k.topPosition,null==M||null===(O=M.mobile)||void 0===O?void 0:O.topPosition,void 0),j=Math.min((null==M?void 0:M.zIndex)||2147483646,2147483646),U=this.config.language||c.ITALIAN,N=this.getFloatingButtonCallToAction(U),F="0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1)",G="#0f172a"===T?"#1e293b":T;this.floatingButton.style.cssText="\n display: flex !important;\n align-items: center !important;\n justify-content: center !important;\n gap: 10px !important;\n position: fixed !important;\n z-index: ".concat(j," !important;\n width: ").concat(E,"px !important;\n height: ").concat(D,"px !important;\n background: ").concat(T," !important;\n color: ").concat(C," !important;\n border: none !important;\n border-radius: ").concat(B,"px !important;\n font-size: ").concat($,"px !important;\n font-weight: ").concat(A," !important;\n text-transform: ").concat("uppercase"===H?"uppercase":"capitalize"===H?"capitalize":"none"," !important;\n cursor: pointer !important;\n box-shadow: ").concat(F,' !important;\n padding: 12px 24px !important;\n font-family: "Google Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif !important;\n transition: all 200ms cubic-bezier(0.4, 0, 0.2, 1) !important;\n transform: scale(1) !important;\n ').concat(void 0!==P?"bottom: ".concat(P,"px !important;"):"","\n ").concat(void 0!==V?"right: ".concat(V,"px !important;"):"","\n ").concat(void 0!==Y?"left: ".concat(Y,"px !important;"):"left: auto !important;","\n ").concat(void 0!==R?"top: ".concat(R,"px !important;"):"top: auto !important;","\n "),this.floatingButton.addEventListener("mouseenter",function(){x.floatingButton&&(x.floatingButton.style.background="".concat(G," !important"),x.floatingButton.style.boxShadow="".concat("0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1)"," !important"))}),this.floatingButton.addEventListener("mouseleave",function(){x.floatingButton&&(x.floatingButton.style.background="".concat(T," !important"),x.floatingButton.style.boxShadow="".concat(F," !important"),x.floatingButton.style.transform="scale(1) !important")}),this.floatingButton.addEventListener("mousedown",function(){x.floatingButton&&(x.floatingButton.style.transform="scale(0.98) !important")}),this.floatingButton.addEventListener("mouseup",function(){x.floatingButton&&(x.floatingButton.style.transform="scale(1) !important")});var W='<svg style="fill: '.concat(C,' !important;" xmlns="http://www.w3.org/2000/svg" height="20" width="20" viewBox="0 0 448 512"><path style="fill: ').concat(C,' !important;" d="M152 24c0-13.3-10.7-24-24-24s-24 10.7-24 24V64H64C28.7 64 0 92.7 0 128v16 48V448c0 35.3 28.7 64 64 64H384c35.3 0 64-28.7 64-64V192 144 128c0-35.3-28.7-64-64-64H344V24c0-13.3-10.7-24-24-24s-24 10.7-24 24V64H152V24zM48 192H400V448c0 8.8-7.2 16-16 16H64c-8.8 0-16-7.2-16-16V192z"/></svg>');this.floatingButton.innerHTML='<span style="display: flex; align-items: center; gap: 10px; color: '.concat(C," !important; font-family: 'Google Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important; font-size: inherit !important; font-weight: inherit !important;\">").concat(W," ").concat(N,"</span>"),this.floatingButton.addEventListener("click",function(){return x.open()}),this.isOpen&&(this.floatingButton.setAttribute("inert",""),this.floatingButton.setAttribute("aria-hidden","true"),this.floatingButton.tabIndex=-1),document.body.appendChild(this.floatingButton)}}},{key:"normalizeLanguage",value:function(e){if(!e)return null;var t=e.trim().toLowerCase();if(!t)return null;if(te.includes(t))return t;var n=t.split(/[-_]/)[0];return te.includes(n)?n:null}},{key:"getDocumentLanguage",value:function(){var e;return"undefined"==typeof document?null:this.normalizeLanguage(null===(e=document.documentElement)||void 0===e?void 0:e.lang)}},{key:"syncLanguageWithDocument",value:function(){var e;if(!this.hasExplicitLanguageSelection){var t=this.getDocumentLanguage();t&&this.isLanguageSupportedByEmbed(t)&&(null===(e=this.config)||void 0===e?void 0:e.language)!==t&&(this.applyLanguage(t,{markAsExplicit:!1,syncEmbed:this.isReady}),this.log("Language set from <html lang>:",t))}}},{key:"isLanguageSupportedByEmbed",value:function(e){var t;if(!e)return!1;var n=null===(t=this.embedConfig)||void 0===t?void 0:t.languages;return Array.isArray(n)&&n.includes(e)}},{key:"observeDocumentLanguage",value:function(){var e=this;"undefined"!=typeof MutationObserver&&"undefined"!=typeof document&&(this.htmlLangObserver&&this.htmlLangObserver.disconnect(),this.htmlLangObserver=new MutationObserver(function(t){var n,i=K(t);try{for(i.s();!(n=i.n()).done;){var o=n.value;if("attributes"===o.type&&"lang"===o.attributeName)return void e.syncLanguageWithDocument()}}catch(e){i.e(e)}finally{i.f()}}),this.htmlLangObserver.observe(document.documentElement,{attributes:!0,attributeFilter:["lang"]}))}},{key:"applyLanguage",value:function(e,t){t.markAsExplicit&&(this.hasExplicitLanguageSelection=!0),this.config&&(this.config.language=e),this.updateFloatingButtonText(e),t.syncEmbed&&this.postMessage({type:"HOLIDOIT_CHANGE_LANGUAGE",payload:{language:e}})}},{key:"getFloatingButtonCallToAction",value:function(e){var t,n=null===(t=this.config)||void 0===t?void 0:t.floatingButtonOptions;return e===c.ITALIAN&&null!=n&&n.italianCallToAction?n.italianCallToAction:e===c.ENGLISH&&null!=n&&n.englishCallToAction?n.englishCallToAction:null!=n&&n.callToAction?n.callToAction:ne[e]||ne[c.ENGLISH]}},{key:"resolveFloatingButtonResponsiveOption",value:function(e,t,n){return window.innerWidth<775?void 0!==t?t:n:void 0!==e?e:n}},{key:"bindBookNowButtons",value:function(){var e=this,t=document.querySelectorAll(".book-now-button");if(0!==t.length){var n=0;t.forEach(function(t){var i=t,o="_holidoitClickBound";i[o]||(i[o]=!0,n++,i.addEventListener("click",function(t){var n;t.preventDefault(),t.stopPropagation();var o=i.getAttribute("data-product-number")||(null===(n=i.closest("[data-product-number]"))||void 0===n?void 0:n.getAttribute("data-product-number"))||"",r=Y(i),a=j(i);e.log("Book now button clicked",{element:i.tagName,productNumber:o,experienceGroupIds:r,experienceIds:a});var s=parseInt(o,10),l=i.getAttribute("data-view"),u=i.getAttribute("data-combo-id");setTimeout(function(){l===d.COMBOS?e.open({view:d.COMBOS,comboId:u?Number(u):null}):isNaN(s)?r.length>0||a.length>0?e.open({experienceGroupIds:r,experienceIds:a}):l===d.EXPERIENCES?e.open({view:d.EXPERIENCES}):e.open():e.open({experienceId:s})},0)}))}),n>0&&this.log("Bound click handlers to ".concat(n," .book-now-button element(s)"))}}},{key:"observeForBookNowButtons",value:function(){var e=this;window._holidoitObserverActive||(window._holidoitObserverActive=!0,new MutationObserver(function(t){for(var n=!1,i=0;i<t.length;i++){var o=t[i];if("childList"===o.type)for(var r=0;r<o.addedNodes.length;r++){var a,s,l=o.addedNodes[r];if(l instanceof HTMLElement&&(null!==(a=l.classList)&&void 0!==a&&a.contains("book-now-button")||null!==(s=l.querySelector)&&void 0!==s&&s.call(l,".book-now-button"))){n=!0;break}}if(n)break}n&&(e.log("Detected dynamically added .book-now-button elements, binding..."),e.bindBookNowButtons())}).observe(document.body,{childList:!0,subtree:!0}),this.log("MutationObserver active for .book-now-button elements"))}},{key:"parseHolidoitEmbedUrl",value:function(e){try{var t=new URL(e),n=t.hostname.replace(/^www\./,"");if("holidoit.com"!==n&&"holido.it"!==n)return null;var i=t.pathname.match(/^\/embed\/web\/([^/]+)\/?$/);if(!i)return null;var o=i[1],r=t.searchParams.get("experienceId"),a=r?parseInt(r,10):void 0;return Z(Z({embedId:o,experienceId:a&&!isNaN(a)?a:void 0},W({view:t.searchParams.get("view")===d.COMBOS?d.COMBOS:d.EXPERIENCES,comboId:Number(t.searchParams.get("comboId"))})),{},{experienceGroupIds:(s=t.searchParams,P(null!==(l=s.get(A))&&void 0!==l?l:s.get("experience_group"))),experienceIds:R(t.searchParams)})}catch(e){return null}var s,l}},{key:"interceptHolidoitLinks",value:function(){var e=this;document.addEventListener("click",function(t){var n,i,o,r=null===(n=t.target)||void 0===n||null===(i=n.closest)||void 0===i?void 0:i.call(n,"a[href]");if(null!=r&&r.href){var a=e.parseHolidoitEmbedUrl(r.href);a&&a.embedId===(null===(o=e.config)||void 0===o?void 0:o.embedId)&&(t.preventDefault(),t.stopPropagation(),e.log("Intercepted holidoit embed link",a),e.open(a))}},!0)}},{key:"setupMessageListener",value:function(){window.addEventListener("message",this.handleMessage),window.addEventListener("message",this.handleExternalMessage)}},{key:"getSenderIframe",value:function(e){if(!e)return null;for(var t=0,n=Array.from(document.querySelectorAll("iframe"));t<n.length;t++){var i=n[t];if(i.contentWindow===e)return i}return null}},{key:"isMessageFromOwnEmbedIframe",value:function(e){var t;return!(null===(t=this.iframe)||void 0===t||!t.contentWindow)&&e.source===this.iframe.contentWindow&&e.origin===this.embedOrigin}},{key:"isTrustedHolidoitOrigin",value:function(e){if(!e||"null"===e)return!1;if(e===this.embedOrigin)return!0;try{var t=new URL(e).hostname;return"localhost"===t||"127.0.0.1"===t||"holidoit.com"===t||t.endsWith(".holidoit.com")||"holido.it"===t||t.endsWith(".holido.it")||"holydoit.com"===t||t.endsWith(".holydoit.com")}catch(e){return!1}}},{key:"extractAnalyticsPayload",value:function(e){var t=C(e);return t&&"embed"===t.source?t:(this.log("Ignoring invalid analytics message payload",e),null)}},{key:"handleAnalyticsMessage",value:function(e){var t=this.extractAnalyticsPayload(e);return!!t&&(T(t.eventData,t.dedupeKey)?(this.log("Pushed analytics event to dataLayer",t.dedupeKey,t.eventData),!0):(this.log("Ignoring duplicate analytics event",t.dedupeKey),!0))}},{key:"postMessage",value:function(e){var t;return null!==(t=this.iframe)&&void 0!==t&&t.contentWindow?this.isReady||"HOLIDOIT_INIT"===e.type?(this.log("Posting message to iframe",e),void this.iframe.contentWindow.postMessage(e,this.embedOrigin)):(this.log("Embed not ready, queueing message",e),void this.pendingMessages.push(e)):(this.log("Iframe not ready, queueing message",e),void this.pendingMessages.push(e))}},{key:"maybeSendInitMessage",value:function(){var e=this;if(this.hasReceivedEmbedReady&&this.embedConfigLoaded&&!this.isReady&&this.config){this.log("Embed and config are ready, sending HOLIDOIT_INIT");var t="localhost"===window.location.hostname||"127.0.0.1"===window.location.hostname;this.postMessage({type:"HOLIDOIT_INIT",payload:Z(Z({embedId:this.config.embedId},W(this.config)),{},{language:this.config.language,floatingButton:this.config.floatingButton,floatingButtonOptions:this.config.floatingButtonOptions,experienceGroupIds:this.config.experienceGroupIds,experienceIds:this.config.experienceIds,parentOrigin:window.location.origin,parentUrl:window.location.href,recoveryToken:this.recoveryToken||void 0,isMobile:window.innerWidth<775,debug:this.config.debug||t})}),this.isReady=!0,this.pendingMessages.forEach(function(t){return e.postMessage(t)}),this.pendingMessages=[]}}},{key:"checkPaymentRedirect",value:function(){var e=this;if(Q)this.log("Payment redirect already processed, skipping");else{var t=null,n=null,i=null;if(X)t=X.paymentIntent,n=X.redirectStatus,i=X.paymentIntentClientSecret,this.log("Using captured Stripe params",X);else{var o=new URLSearchParams(window.location.search);t=o.get("payment_intent"),n=o.get("redirect_status"),i=o.get("payment_intent_client_secret")}if(t&&n){this.log("Payment redirect detected",{paymentIntent:t,redirectStatus:n}),Q=!0;var r=null;try{r=localStorage.getItem(O)}catch(e){this.log("localStorage not available (incognito mode?)",e)}if(r)try{var a=JSON.parse(r);this.log("Found payment session",a),this.open(),this.isReady?e.postMessage({type:"HOLIDOIT_PAYMENT_REDIRECT",payload:{paymentIntent:t,paymentIntentClientSecret:i||void 0,redirectStatus:n,session:a}}):this.pendingMessages.push({type:"HOLIDOIT_PAYMENT_REDIRECT",payload:{paymentIntent:t,paymentIntentClientSecret:i||void 0,redirectStatus:n,session:a}}),this.cleanUrlParams();try{localStorage.removeItem(O)}catch(e){this.log("Failed to remove payment session from localStorage",e)}}catch(e){this.log("Failed to parse payment session",e)}else this.log("Payment redirect params found but no session - cleaning URL"),this.cleanUrlParams()}}}},{key:"cleanUrlParams",value:function(){var e=new URL(window.location.href);e.searchParams.delete("payment_intent"),e.searchParams.delete("payment_intent_client_secret"),e.searchParams.delete("redirect_status"),window.history.replaceState({},"",e.toString())}},{key:"getEmbedOrigin",value:function(e){try{return new URL(e).origin}catch(e){return window.location.origin}}},{key:"lockBodyScroll",value:function(){var e=this;if(this.scrollLockState)this.log("Scroll already locked, skipping");else{var t=this.getDocumentScrollRoot(),n=this.getScrollPosition(),i=n.top,o=n.left,r=this.getScrollbarWidth(),a={overflow:document.body.style.overflow,overscrollBehavior:document.body.style.overscrollBehavior,paddingRight:document.body.style.paddingRight,position:document.body.style.position,top:document.body.style.top,left:document.body.style.left,right:document.body.style.right,width:document.body.style.width},s={overflow:document.documentElement.style.overflow,overscrollBehavior:document.documentElement.style.overscrollBehavior};this.scrollLockState={mode:this.isIOSDevice()&&this.isDocumentScrollRoot(t)?"fixed-body":"document-overflow",scrollTop:i,scrollLeft:o,scrollbarWidth:r,bodyStyles:a,htmlStyles:s},document.documentElement.style.overflow="hidden",document.documentElement.style.overscrollBehavior="none",document.body.style.overflow="hidden",document.body.style.overscrollBehavior="none",r>0&&(document.body.style.paddingRight="".concat(r,"px")),"fixed-body"===this.scrollLockState.mode&&(document.body.style.position="fixed",document.body.style.top="-".concat(i,"px"),document.body.style.left="0",document.body.style.right="0",document.body.style.width="100%",this.touchMoveHandler=function(t){var n,i=t.target;null!==(n=e.container)&&void 0!==n&&n.contains(i)||t.preventDefault()},document.addEventListener("touchmove",this.touchMoveHandler,{passive:!1})),this.log("Scroll locked",{mode:this.scrollLockState.mode,scrollbarWidth:r})}}},{key:"unlockBodyScroll",value:function(){if(this.scrollLockState){var e=this.scrollLockState,t=e.mode,n=e.scrollTop,i=e.scrollLeft,o=e.bodyStyles,r=e.htmlStyles;document.body.style.overflow=o.overflow,document.body.style.overscrollBehavior=o.overscrollBehavior,document.body.style.paddingRight=o.paddingRight,document.documentElement.style.overflow=r.overflow,document.documentElement.style.overscrollBehavior=r.overscrollBehavior,"fixed-body"===t&&(document.body.style.position=o.position,document.body.style.top=o.top,document.body.style.left=o.left,document.body.style.right=o.right,document.body.style.width=o.width,this.touchMoveHandler&&(document.removeEventListener("touchmove",this.touchMoveHandler),this.touchMoveHandler=null)),this.restoreScrollPosition(n,i),this.scrollLockState=null,this.log("Scroll unlocked",{mode:t})}else this.log("Scroll not locked, skipping unlock")}},{key:"log",value:function(){var e,t="undefined"!=typeof window&&("localhost"===window.location.hostname||"127.0.0.1"===window.location.hostname);if(null!==(e=this.config)&&void 0!==e&&e.debug||t){for(var n,i=arguments.length,o=new Array(i),r=0;r<i;r++)o[r]=arguments[r];(n=console).log.apply(n,["[Holidoit]"].concat(o))}}}],t&&y(e.prototype,t),n&&y(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e;var e,t,n,i}()),oe=function(e){return ie.init(e)},re=function(e){return ie.open(e)},ae=function(){return ie.close()},se=function(e){return ie.toggle(e)},le=function(e){return ie.changeLanguage(e)},ue=function(){return ie.destroy()},ce=k,de=function(e,t,n){e&&ie.init({embedId:e,floatingButton:null==t||t,floatingButtonOptions:n})},he=function(e,t,n,i,o){ie.toggle({embedId:e,experienceId:t?parseInt(t,10):void 0,test:n,experienceGroupIds:P(i),experienceIds:P(o)})},fe=function(){return ie.open()},pe=function(){return ie.close()},me={EmbedView:d,init:oe,open:re,close:ae,toggle:se,changeLanguage:le,destroy:ue,version:ce,renderHolidoitEmbed:de,toggleEmbed:he,openEmbed:fe,closeEmbed:pe};if("undefined"!=typeof window){window.Holidoit=me;var ge=document.currentScript,ve=function(){var e=window.HolidoitConfig;if(null!=e&&e.embedId)ie.init(e);else if(null!=ge&&ge.getAttribute("data-embed-id")){var t=ge.getAttribute("data-embed-id"),n=ge.getAttribute("data-floating-button"),i=ge.getAttribute("data-language"),o=ge.getAttribute("data-embed-url"),r=ge.getAttribute("data-debug"),a=ge.getAttribute("data-view"),s=ge.getAttribute("data-combo-id");ie.init({embedId:t,view:a===d.COMBOS?d.COMBOS:d.EXPERIENCES,comboId:s?Number(s):void 0,floatingButton:"true"===n,language:i||void 0,embedUrl:o||void 0,debug:"true"===r,experienceGroupIds:Y(ge),experienceIds:j(ge)})}};"loading"===document.readyState?document.addEventListener("DOMContentLoaded",ve):ve()}})(),i})());