PageSourceSearch

https://tickets.sydneyzoo.com/encounters/www_shared/assets/ContainerCheckout-vue.d686886dd6258a44e8ed.js

js sydneyzoo.com collected 2026-10-02 17:07:27 UTC 36,897 bytes, 1 lines download raw bytes

1(self.webpackChunk_webcoda_boilerplatev_template=self.webpackChunk_webcoda_boilerplatev_template||[]).push([[3238],{112:(t,e,r)=>{"use strict";r.d(e,{HI:()=>l,II:()=>c,I7:()=>d});var n=r(5853),i=r(696),a=r(1683);function o(t,e){var r;if("undefined"==typeof Symbol||null==t[Symbol.iterator]){if(Array.isArray(t)||(r=function(t,e){if(!t)return;if("string"==typeof t)return s(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);"Object"===r&&t.constructor&&(r=t.constructor.name);if("Map"===r||"Set"===r)return Array.from(t);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return s(t,e)}(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0,i=function(){};return{s:i,n:function(){return n>=t.length?{done:!0}:{done:!1,value:t[n++]}},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,l=!1;return{s:function(){r=t[Symbol.iterator]()},n:function(){var t=r.next();return o=t.done,t},e:function(t){l=!0,a=t},f:function(){try{o||null==r.return||r.return()}finally{if(l)throw a}}}}function s(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=new Array(e);r<e;r++)n[r]=t[r];return n}var l="All guests aged 16 or younger must be accompanied by an adult. Please ensure your ticket selection includes one adult per guest.";function c(t){return function(t){return(null==t?void 0:t.length)?t.filter((function(t){return t.code&&String(t.code).toUpperCase().includes("CHILD")}
1)).reduce((function(t,e){return t+(parseInt(e.quantity,10)||0)}),0):0}(t)<=function(t){return(null==t?void 0:t.length)?t.reduce((function(t,e){var r=(e.code||"").toUpperCase();return"CONCESSION"===r||r.includes("ADULT")?t+(parseInt(e.quantity,10)||0):t}),0):0}(t)}function u(t,e){if(t.linkedMember){var r=(t.fare&&t.fare.code?String(t.fare.code):"").toUpperCase();return r.includes("CHILD")||r.includes("INF")?"child":"adult_supervisor"}if(!t.dateOfBirth)return null;var o;try{o=(0,n.Z)(e,a.iK,new Date)}catch(t){return null}var s=t.dateOfBirth instanceof Date?t.dateOfBirth:new Date(t.dateOfBirth);if(Number.isNaN(s.getTime())||Number.isNaN(o.getTime()))return null;var l=(0,i.Z)(o,s);return Number.isNaN(l)?null:l<=16?"child":17===l?"teen":"adult_supervisor"}function d(t,e){if(!(null==t?void 0:t.length)||!e)return!0;var r,n=0,i=0,a=o(t);try{for(a.s();!(r=a.n()).done;){var s=u(r.value,e);if(null===s)return!1;"child"===s&&n++,"adult_supervisor"===s&&i++}}catch(t){a.e(t)}finally{a.f()}return n<=i}},6336:(t,e,r)=>{"use strict";r.d(e,{C:()=>n});var n=function(t){return function(e){if(e.target.value.length===t)return e.preventDefault(),!1}}},973:(t,e,r)=>{"use strict";r.d(e,{Z:()=>n});const n=(0,r(3312).Sz)("email",/^(?:[A-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[A-z0-9!#$%&'*+/=?^_`{|}~-]+)*|"(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21\x23-\x5b\x5d-\x7f]|[\x01-\x09\x0b\x0c\x0e-\x7f])*")@(?:(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9]{2,}(?:[a-z0-9-]*[a-z0-9])?|\[(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?|[a-z0-9-]*[a-z0-9]:(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21-\x5a\x53-\x7f]|\\[\x01-\x09\x0b\x0c\x0e-\x7f])+)\])$/i)},3638:(t,e,r)=>{"use strict";r.d(e,{Z:()=>n});const n=(0,r(3312).Sz)("validname",/^[a-zA-Z\ \-]*$/)},3766:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>i});const n={data:function(){return{isOpen:!1}},methods:{toggleAccordion:function(){this.isOpen=!this.isOpen}}};const i=(0,r(1900).Z)(n,(function(){var t=this,e=t.$createElement,r=t._self._c||e;return r("div",[r("button",{staticClass:"w-full flex items-center space-x-3 justify-between focus:outline-none",attrs:{"aria-expanded":t.isOpen,"aria-controls":"collapse"+t._uid},on:{click:function(e){return t.toggleAccordion()}}},[t._t("title"),t._v(" "),r("svg",{staticClass:"w-3 transition-all duration-200 transform",class:{"rotate-180":t.isOpen,"rotate-0":!t.isOpen},attrs:{fill:"none",stroke:"currentColor",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 16 10","aria-hidden":"true"}},[r("path",{attrs:{d:"M15 1.2l-7 7-7-7","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"}})])],2),t._v(" "),r("div",{directives:[{name:"show",rawName:"v-show",value:t.isOpen,expression:"isOpen"}],staticClass:"mt-8 prose",staticStyle:{"font-size":"1rem !important"},attrs:{id:"collapse"+t._uid}},[t._t("content")],2)])}),[],!1,null,null,null).exports},3511:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>u});var n=r(9713),i=r.n(n),a=r(4612),o=r.n(a);function s(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function l(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?s(Object(r),!0).forEach((function(e){i()(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):s(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}const c={props:{name:String,placeholder:String,type:{type:String,default:"text"},value:String,size:String,error:[Boolean,String],inputAttrs:Object,mask:[Array,Object]},components:{MaskedInput:o()},computed:{_component:function(){return o()},_inputAttrs:function(){return l(l({},this.inputAttrs),{},{name:this.name,placeholder:this.placeholder,type:this.type})}},methods:{handleInput:function(t,e){this.$emit("input",t,e)}}};const u=(0,r(1900).Z)(c,(function(){var t=this,e=t.$createElement;return(t._self._c||e)("BaseTextbox",t._b({attrs:{comp:t._component,mask:t.mask,guide:!1,inputAttrs:t._inputAttrs},on:{input:t.handleInput,blur:function(e){return t.$emit("blur",e)}}},"BaseTextbox",{size:t.size,error:t.error,value:t.value},!1))}),[],!1,null,null,null).exports},3399:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>n});const n=(0,r(1900).Z)({},(function(){var t=this.$createElement,e=this._self._c||t;return e("h2",{staticClass:"text-center md:text-left theme-light:text-left"},[e("span",[this._t("default")],2),this._v(" "),e("span",{staticClass:"block md:hidden mx-auto mt-3.5 w-4.5 h-1 bg-highlight theme-light:hidden"})])}),[],!1,null,null,null).exports},8761:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>a});var n=r(1424);const i={props:{activeStepIndex:{type:Number,default:0}},mixins:[n.Z],data:function(){var t=this.urlBase,e=this.urlCheckout;return{steps:[{href:t,label:"Encounters"},{href:this.urlNameDetails,label:"Profile"},{href:e,label:"Checkout"}]}}};const a=(0,r(1900).Z)(i,(function(){var t=this,e=t.$createElement,r=t._self._c||e;return r("div",{staticClass:"flex items-center"},t._l(t.steps,(function(e,n){return r(n<t.activeStepIndex?"a":"div",{key:"step-"+e.label,tag:"component",class:["flex items-center font-extrabold text-center BookingSteps__step group",{"text-brown":n<t.activeStepIndex},{"text-highlight-2 theme-light:text-yellow":n===t.activeStepIndex,"text-inherit hocus:text-inherit theme-light:text-inherit":n>t.activeStepIndex}],attrs:{href:n<t.activeStepIndex?e.href:void 0,"data-index":n}},[n>0?r("svg",{class:[{"text-brown":n<=t.activeStepIndex}],attrs:{xmlns:"http://www.w3.org/2000/svg",width:"59.047",height:"3",viewBox:"0 0 59.047 3"}},[r("line",{attrs:{x2:"59.047",transform:"translate(0 1.5)",fill:"none",stroke:"currentColor","stroke-miterlimit":"10","stroke-width":"3",opacity:n<=t.activeStepIndex?1:.4}})]):t._e(),t._v(" "),r("div",{class:{"text-center":!0,"-ml-2":n>0,"opacity-40":n>t.activeStepIndex},staticStyle:{"min-width":"46px"}},[r("svg",{staticClass:"group fill-current inline-block",attrs:{xmlns:"http://www.w3.org/2000/svg",width:"24.273",height:"17.47"}},[r("g",{attrs:{transform:"translate(-101.648)"}},[r("path",{attrs:{d:"M119.754 17.47a7.357 7.357 0 001.288-4.17 7 7 0 10-13.985 0 7.356 7.356 0 001.288 4.17z"}}
1),t._v(" "),t.activeStepIndex===n?r("g",[r("ellipse",{attrs:{cx:"2.481",cy:"2.564",rx:"2.481",ry:"2.564",transform:"translate(101.648 4.885)"}}),t._v(" "),r("ellipse",{attrs:{cx:"2.481",cy:"2.564",rx:"2.481",ry:"2.564",transform:"translate(107.436)"}}),t._v(" "),r("ellipse",{attrs:{cx:"2.481",cy:"2.564",rx:"2.481",ry:"2.564",transform:"translate(114.996)"}}),t._v(" "),r("ellipse",{attrs:{cx:"2.481",cy:"2.564",rx:"2.481",ry:"2.564",transform:"translate(120.96 4.885)"}})]):t._e()])]),t._v(" "),r("div",{staticClass:"mt-1.5"},[t._v(t._s(e.label))])])])})),1)}),[],!1,null,null,null).exports},9706:(t,e,r)=>{"use strict";r.r(e),r.d(e,{default:()=>G});var n=r(7757),i=r.n(n),a=r(8926),o=r.n(a),s=r(319),l=r.n(s),c=r(9713),u=r.n(c),d=r(2005),m=r.n(d),h=r(821),p=r.n(h),v=r(8620),f=r(5986),g=r(5460),y=r(5853),b=r(9208),x=r.n(b),k=r(7103),_=r(1145),C=r.n(_),w=r(4731),S=r.n(w),O=r(3171),P=r.n(O),I=r(7780),$=r(8883),B=r(3243),D=r(3511),N=r(6365),A=r(3399),L=r(8761),q=r(6102),T=r(396),M=r(3766),E=r(973),j=r(1683),z=r(4088),Z=r(3638),K=r(6336),F=r(1424),H=r(4461),R=r(112);function U(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function J(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?U(Object(r),!0).forEach((function(e){u()(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):U(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}m().use(P()),m().use(v.ZP),m().use(p(),j.bZ);var V=function(t){return!!t};const X={props:{initialOrder:Object,gatewayId:String,publicKey:String,environment:String,tnCUrl:String,rebilling:String},components:{Button:I.default,BaseInputBox:$.default,BaseTextbox:B.default,BaseTextboxMasked:D.default,BaseTelTextBox:N.default,BookingHeading:A.default,BookingSteps:L.default,BookingSummary:q.default,PaymentDetails:T.default,Accordion:M.default,Countdown:S()},validations:function(){return{order:{firstName:{required:f.C1,validname:Z.Z},lastName:{required:f.C1,validname:Z.Z},mobile:{required:f.C1,minLength:(0,f.Ei)(10)},email:{required:f.C1,email:E.Z},countryIso2:{required:f.C1},postcode:{required:f.C1,validPostcode:function(t){return!t||("AU"===this.order.countryIso2?/^\d{4}$/.test(t):/^[a-zA-Z0-9\s\-]{1,20}$/.test(t))}},agree:{mustBeTrue:V},emailOptIn:{}}}},filters:{currency:k.Z,twoDigits:H.Ol},mixins:[F.Z],data:function(){var t,e,r,n,i,a,o,s,l,c,u,d,m,h=this.initialOrder,p=this.handleInputBlur,v=(this.tnCUrl,null==h||null===(t=h.tickets)||void 0===t||null===(e=t[0])||void 0===e||null===(r=e.namedetails)||void 0===r?void 0:r[0]);return{paymentDetailsKey:0,textInputs:[{label:"First Name",name:"order.firstName",errorMsg:{required:"First name is required",validname:"Invalid characters"},listeners:{change:p}},{label:"Last Name",name:"order.lastName",errorMsg:{required:"Last name is required",validname:"Invalid characters"},listeners:{change:p}},{label:"Email",name:"order.email",inputAttrs:{type:"email"},errorMsg:{required:"Email is required",email:"Invalid email address"}},{label:"Mobile",name:"order.mobile",inputAttrs:{type:"number"},errorMsg:{required:"Mobile is required",minLength:"Min. 10 digits"},listeners:{keypress:(0,K.C)(10)}},{label:"Postcode",name:"order.postcode",type:"number",inputAttrs:{type:"number"},errorMsg:{required:"Postcode is required",minLength:"Min. 4 digits"},listeners:{keypress:(0,K.C)(4)}}],checkboxes:[{label:'<span>I have read and accept the <a href="https://sydneyzoo.com/ticket-terms" target="_blank" class="font-bold text-inherit hocus:text-inherit theme-light:text-yellow theme-light:hocus:text-yellow underline">Terms &amp; Conditions*</a></span>',name:"order.agree",listeners:{blur:this.handleInputBlur},errorMsg:{mustBeTrue:"Please verify that you have read the Terms and Conditions"}},{label:"I consent to the use of my contact details for marketing communications from Sydney Zoo and our relevant event partners.",name:"order.emailOptIn",listeners:{blur:this.handleInputBlur}}],order:J(J({},h),{},{firstName:null!==(n=h.firstName||(null==v?void 0:v.firstName))&&void 0!==n?n:"",lastName:null!==(i=h.lastName||(null==v?void 0:v.lastName))&&void 0!==i?i:"",mobile:null!==(a=h.mobile||(null==v?void 0:v.mobilePhone))&&void 0!==a?a:"",email:null!==(o=h.email||(null==v?void 0:v.emailAddress))&&void 0!==o?o:"",countryIso2:null!==(s=h.countryIso2)&&void 0!==s?s:"AU",postcode:null!==(l=h.postcode||(null==v?void 0:v.postcode))&&void 0!==l?l:"",emailOptIn:null===(c=h.emailOptIn)||void 0===c||c,agree:null!==(u=null!==(d=h.agree)&&void 0!==d?d:h.locallyConfirmed)&&void 0!==u&&u,vouchers:null!==(m=h.vouchers)&&void 0!==m?m:[],isValid:!1}
1),voucherInput:"",isLoading:!1,termsData:"",secure3DForm:"",errorPaymentDetails:"",cardtype:"",cardTypeSessionId:"",isConfirmPurchaseClicked:!!(null==h?void 0:h.locallyConfirmed),selectedPayment:"credit_card"}},watch:{cardtype:function(){this.cardTypeSessionId="".concat(+new Date)}},computed:{allInputs:function(){var t=this.textInputs,e=this.checkboxes,r=[{name:"order.mobile",errorMsg:{required:"Mobile is required",minLength:"Min. 11 digits"}},{name:"order.postcode",errorMsg:{required:"Postcode is required",validPostcode:"AU"===this.order.countryIso2?"Please enter a valid 4-digit postcode":"Please enter a valid postcode (1-20 characters)"}}];return[].concat(l()(t),r,l()(e))},allErrorMessages:function(){var t=this.$v;return this.allInputs.reduce((function(e,r){return J(J({},e),{},u()({},r.name,function(t,e){var r="";return(!x()(e,t.name)||e.$dirty&&x()(e,"".concat(t.name,".$dirty")))&&t.errorMsg?(Object.keys(t.errorMsg).forEach((function(n){x()(e,"".concat(t.name,".").concat(n))||(r=t.errorMsg[n])})),r):r}(r,t)))}),{})},bookingSummaryEntries:function(){var t,e=this.order;return null==e||null===(t=e.tickets)||void 0===t?void 0:t.map((function(t){var r,n=(0,y.Z)(e.date,j.iK,new Date);return{key:t.code,amount:t.quantity,name:t.description,day:(0,g.Z)(n,"EEE"),date:(0,g.Z)(n,"MMM dd"),year:(0,g.Z)(n,"yyyy"),arrivalTime:null===(r=e.time)||void 0===r?void 0:r.replace(/\ /,""),price:t.price}})).filter((function(t){return t.amount>0}))},totalVouchers:function(){var t,e;return null===(t=this.order)||void 0===t||null===(e=t.vouchers)||void 0===e?void 0:e.reduce((function(t,e){return t+e.value}),0)},timelimit:function(){var t=this.order;return t.dndtimelimit?new Date(t.dndtimelimit)-Date.now():0},hasNswVoucher:function(){var t,e;return null===(t=this.order)||void 0===t||null===(e=t.vouchers)||void 0===e?void 0:e.some((function(t){return t.isDnD}))},hasNswVoucherAndConfirmPurchaseClicked:function(){return this.hasNswVoucher&&this.isConfirmPurchaseClicked}},methods:{lodashGet:x(),setPaymentMethod:function(t){this.selectedPayment=t},handleCountrySelected:function(t){this.$set(this.order,"countryIso2",t),this.updateBooking()},handlePostcodeKeydown:function(t){if("AU"===this.order.countryIso2){var e=t.which?t.which:t.keyCode;if(-1!==[8,9,27,13,46,35,36,37,39].indexOf(e)||65===e&&!0===t.ctrlKey||67===e&&!0===t.ctrlKey||86===e&&!0===t.ctrlKey||88===e&&!0===t.ctrlKey)return;if((e<48||e>57)&&(e<96||e>105))return void t.preventDefault();t.target.value.length>=4&&t.preventDefault()}},handlePostcodeInput:function(t){if("AU"===this.order.countryIso2){var e=t.target.value.replace(/\D/g,"");t.target.value!==e&&(t.target.value=e,this.$v.order.postcode.$model=e)}else{var r=t.target.value.replace(/[^a-zA-Z0-9\s\-]/g,"");t.target.value!==r&&(t.target.value=r,this.$v.order.postcode.$model=r)}},getTerms:function(){var t=this;return o()(i().mark((function e(){return i().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:fetch(t.tnCUrl).then((function(t){return t.text()})).then((function(e){t.termsData=e})).catch((function(t){return console.error(t)}));case 1:case"end":return e.stop()}}),e)})))()},updateBooking:function(){var t=this;return o()(i().mark((function e(){var r;return i().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,(0,z.pZ)(J({},t.order));case 2:return r=e.sent,(0,z.H7)({name:"Browser Backend API CALL",logLevel:"Information",method:"POST",requestPath:"/api/startbooking",request:JSON.stringify(t.order),response:JSON.stringify(r)}),e.abrupt("return",r);case 5:case"end":return e.stop()}}),e)})))()},requestClearBookingAndRedirect:function(t){var e=this;return o()(i().mark((function r(){var n,a,o,s;return i().wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return n=e.order,a=e.urlBooking,r.next=3,(0,z.DM)({apiFn:z.wF,data:n});case 3:o=r.sent,o.ok,s=o.data,(0,z.H7)({name:"Browser Backend API CALL",logLevel:"Information",method:"POST",requestPath:"/api/removebooking",request:JSON.stringify(n),response:JSON.stringify(s)}),document.location.href=t||a;case 8:case"end":return r.stop()}}),r)})))()},validateForm:function(){var t=this;return o()(i().mark((function e(){var r,n;return i().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=t.$v,t.order,n=t.$noty,t.handlePaymentDetailsSuccess,t.cardTypeSessionId,r.$touch(),e.next=4,t.$nextTick();
1case 4:if(t.order.isValid=!r.$invalid,!r.$invalid){e.next=8;break}return r.$invalid&&n.error("Please fill in the mandatory fields highlighted in red"),e.abrupt("return",!1);case 8:return e.abrupt("return",!0);case 9:case"end":return e.stop()}}),e)})))()},handleClickCheckout:function(){var t=this;return o()(i().mark((function e(){var r,n;return i().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=t.$v,t.order,n=t.$noty,t.handlePaymentDetailsSuccess,t.cardTypeSessionId,t.errorPaymentDetails="",console.log("handleClickCheckout"),r.$touch(),e.next=6,t.$nextTick();case 6:if(!r.$invalid){e.next=9;break}return r.$invalid&&n.error("Please fill in the mandatory fields highlighted in red"),e.abrupt("return");case 9:t.$refs.paymentDetails?t.$refs.paymentDetails.runSubmit():(t.rebilling=!1,t.handlePaymentDetailsSuccess()),t.isConfirmPurchaseClicked=!0;case 11:case"end":return e.stop()}}),e)})))()},handleInputBlur:function(){var t=this;this.updateBooking(),"credit_card"!=this.selectedPayment&&this.validateForm().then((function(e){t.order.isValid=e}))},handleBookingSummaryRemoveItem:function(t){var e=this;return o()(i().mark((function r(){var n,a,o,s,l;return i().wrap((function(r){for(;;)switch(r.prev=r.next){case 0:if(n=e.initialOrder.tickets.map((function(e){return e.code===t?J(J({},e),{},{quantity:e.quantity-1}):e})),(0,R.II)(n)){r.next=4;break}return e.$noty.error(R.HI),r.abrupt("return");case 4:return e.initialOrder.tickets.find((function(e){return(null==e?void 0:e.code)==t})).quantity--,e.initialOrder.tickets.find((function(e){return(null==e?void 0:e.code)==t})).namedetails.splice(-1,1),e.isLoading=!0,r.next=9,(0,z.DM)({apiFn:z.pZ,data:e.initialOrder});case 9:if(r.t0=r.sent,r.t0){r.next=12;break}r.t0={};case 12:if(a=r.t0,o=a.ok,s=a.data,e.isLoading=!1,!o){r.next=30;break}if((0,z.H7)({name:"Browser Backend API CALL",logLevel:"Information",method:"POST",requestPath:"/api/startbooking",request:JSON.stringify(e.order),response:JSON.stringify(s)}),null==(l=e.bookingSummaryEntries)?void 0:l.length){r.next=30;break}return e.$set(e.order,"firstName",""),e.$set(e.order,"lastName",""),e.$set(e.order,"email",""),e.$set(e.order,"mobile",""),e.$set(e.order,"postcode",""),e.$set(e.order,"emailOptIn",!1),e.$set(e.order,"agree",!1),r.next=29,e.updateBooking();case 29:e.requestClearBookingAndRedirect();case 30:case"end":return r.stop()}}),r)})))()},handlePaymentDetailsSuccess:function(t,e){var r=this;return o()(i().mark((function n(){var a,o,s,l,c,u,d,m,h,p;return i().wrap((function(n){for(;;)switch(n.prev=n.next){case 0:if(a=r.order,r.$noty,o=r.urlConfirmation,!r.isLoading){n.next=3;break}return n.abrupt("return");case 3:if(!(s="true"===r.rebilling)){n.next=8;break}r.order.clientPaymentResponse=null,n.next=17;break;case 8:if(e||!t){n.next=16;break}return console.log("response inline"),console.log(t),"authentication_not_supported"===t.status&&(t.charge_3ds_id=t._3ds.id),r.order.clientPaymentResponse=t,n.abrupt("return");case 16:a.total>0&&("authentication_not_supported"===t.status&&(t.charge_3ds_id=t._3ds.id),r.order.clientPaymentResponse=t);case 17:return l={},l=s?J(J({},a),{},{payment_source:t}):J({},a),r.isLoading=!0,c=!0,n.next=23,(0,z.DM)({apiFn:z.eg,data:l,disableErrorNoty:c});case 23:if(n.t0=n.sent,n.t0){n.next=26;break}n.t0={};case 26:if(u=n.t0,d=u.ok,m=u.data,!d||!m){n.next=48;break}if("error"!=m.status||!c){n.next=36;break}return m.bookingNumber&&r.$set(r.order,"bookingNumber",m.bookingNumber),(0,z.H7)({name:"Browser Backend API CALL",logLevel:"Error",method:"POST",requestPath:"/api/finalizebooking",request:JSON.stringify(l),response:JSON.stringify(m)}),"Transaction Declined"===m.message||"error"===m.status?r.showDialogOnErrorOnDiscoverCase("Transaction has been declined. Please try another card or you can call us on XXXX and provide booking reference XXX"):r.showDialogOnErrorOnDiscoverCase(m.message),r.isLoading=!1,n.abrupt("return");case 36:if((0,z.H7)({name:"Browser Backend API CALL",logLevel:"Information",method:"POST",requestPath:"/api/finalizebooking",request:JSON.stringify(l),response:JSON.stringify(m)}),h=m.useSecure,p=m.hostUrl,!h||!p){n.next=44;break}
1return r.secure3DForm=p.replace(/\\"/g,'"').replace(/\\n/g,""),n.next=42,r.$nextTick();case 42:return window.document.echoForm.submit(),n.abrupt("return");case 44:return r.initialOrder,sessionStorage.clear(),document.location.href=o,n.abrupt("return");case 48:r.isLoading=!1;case 49:case"end":return n.stop()}}),n)})))()},handleApplyVoucherClick:function(){var t=this;return o()(i().mark((function e(){var r,n,a,o,s,l,c,u,d,m,h,p,v,f;return i().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(r=t.order,n=t.voucherInput,a=t.$noty,o=J({},r),l=(s=r||{}).firstName,c=s.lastName,u=s.mobile,d=s.email,m=s.postcode,""!=l&&""!=c&&""!=u&&""!=d&&""!=m){e.next=6;break}return a.error("Please enter the booking details first before entering the voucher code"),e.abrupt("return");case 6:return h={code:n,sessionKey:r.sessionKey},t.isLoading=!0,e.next=10,(0,z.DM)({apiFn:z.ou,data:h});case 10:if(e.t0=e.sent,e.t0){e.next=13;break}e.t0={};case 13:p=e.t0,v=p.ok,f=p.data,t.isLoading=!1,v&&((0,z.H7)({name:"Browser Backend API CALL",logLevel:"Information",method:"POST",requestPath:"/api/removevoucher",request:JSON.stringify(h),response:JSON.stringify(f)}),t.$set(t,"voucherInput",""),t.$set(t,"order",J(J({},f),{},{agree:o.agree})),t.$set(t,"paymentDetailsKey",t.paymentDetailsKey+1));case 18:case"end":return e.stop()}}),e)})))()},handleRemoveVoucherClick:function(t){var e=this;return o()(i().mark((function r(){var n,a,o,s,l,c;return i().wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return n=e.order,a=J({},n),o={code:t,sessionKey:n.sessionKey},e.isLoading=!0,r.next=6,(0,z.DM)({apiFn:z.i0,data:o});case 6:if(r.t0=r.sent,r.t0){r.next=9;break}r.t0={};case 9:s=r.t0,l=s.ok,c=s.data,e.isLoading=!1,l&&((0,z.H7)({name:"Browser Backend API CALL",logLevel:"Information",method:"POST",requestPath:"/api/removevoucher",request:JSON.stringify(o),response:JSON.stringify(c)}),e.$set(e,"order",J(J({},c),{},{agree:a.agree})),e.$set(e,"paymentDetailsKey",e.paymentDetailsKey+1));case 14:case"end":return r.stop()}}),r)})))()},handleTimerEnded:function(){var t=this;return o()(i().mark((function e(){var r,n,a;return i().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,(0,z.DM)({apiFn:z.Y0,data:t.order});case 2:if(r=e.sent,n=r.ok,a=r.data,!n||"true"!==a.status){e.next=10;break}return(0,z.H7)({name:"Browser Backend API CALL",logLevel:"Information",method:"POST",requestPath:"/api/dnd/timerstop",request:JSON.stringify(t.order),response:JSON.stringify(a)}),t.$set(t,"order",J({},a.order)),t.$dialog.alert("All Discover vouchers are voided. Please re-enter the vouchers"),e.abrupt("return");case 10:t.$dialog.alert(a.errorMessage||"Unknown error");case 11:case"end":return e.stop()}}),e)})))()},showDialogOnErrorOnDiscoverCase:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,r=this.order,n=this.urlBooking,i=this.hasNswVoucher;this.$dialog.confirm(e.toLowerCase().includes("exceeds available pax")?"Roar! Maximum ticket limit exceeded. Please reduce the quantity.":"Payment failed, please try again. If you are having issues please contact us on (02) 7202-2560".concat(r.bookingNumber?" and quote your reference number: <strong>".concat(r.bookingNumber,"</strong>"):""),{html:!0,okText:"Close and exit",cancelText:"Try again",customClass:i?"hasNswVoucher":"",reverse:i}).then((function(){t.requestClearBookingAndRedirect(n)})).catch((function(t){(0,z.H7)({name:"Browser Errors",logLevel:"ERROR",content:t}),window.location.reload()}))}},mounted:function(){this.getTerms();window.wcSiteKey;var t=this.initialError,e=this.$noty;t&&e.error(t.message);var r=C()("?errorMessage")||C()("?errormessage")||C()("?error");r&&(this.order.bookingNumber?this.showDialogOnErrorOnDiscoverCase():e.error(r))}};const G=(0,r(1900).Z)(X,(function(){var t=this,e=t.$createElement,r=t._self._c||e;return r("div",{ref:"comp",staticClass:"container pt-0 xs:pt-16 ContainerCheckout"},[r("div",{staticClass:"overflow-hidden"},[r("div",{staticClass:"\n\t\t\t\tflex\n\t\t\t\tjustify-center\n\t\t\t\tbg-grey-4\n\t\t\t\tpy-3.5\n\t\t\t\tmd:py-0 md:justify-end md:bg-transparent\n\t\t\t\ttheme-light:bg-transparent\n\t\t\t\tmx-n
1hs\n\t\t\t\tmd:mx-0\n\t\t\t"},[r("BookingSteps",{attrs:{activeStepIndex:2}})],1)]),t._v(" "),r("div",{staticClass:"row mt-10 ContainerCheckout__row"},[r("div",{staticClass:"md:col-8 space-y-7 ContainerCheckout__col"},[r("div",{staticClass:"theme-light:p-10 theme-light:bg-white"},[r("div",{class:{"pointer-events-none":t.isConfirmPurchaseClicked}},[r("BookingHeading",[t._v("Booking Details")]),t._v(" "),r("div",{staticClass:"\n\t\t\t\t\t\t\tbg-white\n\t\t\t\t\t\t\tpx-6\n\t\t\t\t\t\t\tpy-5\n\t\t\t\t\t\t\tmt-5\n\t\t\t\t\t\t\ttheme-light:px-0 theme-light:mt-0 theme-light:py-6 theme-light:mb-6 theme-light:border-b\n\t\t\t\t\t\t\tContainerCheckout__booking-details\n\t\t\t\t\t\t"},[r("div",{staticClass:"space-y-1.5 md:space-y-4",class:{"pointer-events-none":t.isConfirmPurchaseClicked}},[t._l(t.textInputs.slice(0,3),(function(e){return r("BaseTextbox",t._g({key:e.name,attrs:{comp:e.as,name:e.name,label:e.label,inputAttrs:e.inputAttrs,error:t.allErrorMessages[e.name]},on:{blur:t.handleInputBlur},scopedSlots:t._u([{key:"after-input",fn:function(){return[r("span",{staticClass:"u-vertical-center right-0 text-error h-2 !mr-1 leading-none"},[t._v("*")])]},proxy:!0}],null,!0),model:{value:t.$v[e.name.split(".")[0]][e.name.split(".")[1]].$model,callback:function(r){t.$set(t.$v[e.name.split(".")[0]][e.name.split(".")[1]],"$model","string"==typeof r?r.trim():r)},expression:"$v[input.name.split('.')[0]][input.name.split('.')[1]].$model"}},e.listeners))})),t._v(" "),r("div",{staticClass:"md:flex md:space-x-1.5"},[r("div",{staticClass:"flex-1 md:max-w-[60%] md:min-w-[60%]"},[r("label",{staticClass:"block relative text-primary-2 space-y-1.5 items-center md:flex md:space-y-0 md:space-x-1.5"},[r("span",{staticClass:"block md:text-right w-30 flex-shrink-0 text-label BaseTextbox__label"},[t._v("Mobile")]),t._v(" "),r("div",{staticClass:"flex-1 relative"},[r("BaseTelTextBox",{attrs:{name:"order.mobile",placeholder:"Mobile",inputClasses:"w-full bg-grey-3 theme-light:bg-[#ececec] focus:bg-white border border-grey-3 theme-light:border-[#ececec] px-3",defaultCountry:t.order.countryIso2||"AU"},on:{blur:t.handleInputBlur,"country-selected":t.handleCountrySelected},model:{value:t.$v.order.mobile.$model,callback:function(e){t.$set(t.$v.order.mobile,"$model",e)},expression:"$v.order.mobile.$model"}}),t._v(" "),r("span",{staticClass:"u-vertical-center right-0 text-error h-2 !mr-1 leading-none"},[t._v("*")])],1)]),t._v(" "),t.allErrorMessages["order.mobile"]?r("div",{staticClass:"text-sm text-error mt-1 md:ml-31.5"},[t._v(t._s(t.allErrorMessages["order.mobile"]))]):t._e()]),t._v(" "),r("div",{staticClass:"mt-1 md:mt-0 md:flex-1"},[r("BaseTextbox",{attrs:{name:"order.postcode",label:"Postcode",inputAttrs:"AU"===t.order.countryIso2?{type:"text",maxlength:4,inputmode:"numeric"}:{type:"text",maxlength:20},error:t.allErrorMessages["order.postcode"]},on:{blur:t.handleInputBlur,keydown:t.handlePostcodeKeydown,input:t.handlePostcodeInput},scopedSlots:t._u([{key:"after-input",fn:function(){return[r("span",{staticClass:"u-vertical-center right-0 text-error h-2 !mr-1 leading-none"},[t._v("*")])]},proxy:!0}]),model:{value:t.$v.order.postcode.$model,callback:function(e){t.$set(t.$v.order.postcode,"$model","string"==typeof e?e.trim():e)},expression:"$v.order.postcode.$model"}})],1)])],2),t._v(" "),r("div",{staticClass:"space-y-5 theme-light:space-y-3 theme-light:mt-4 theme-light:md:pl-[126px]"},t._l(t.checkboxes,(function(e){return r("BaseInputBox",t._g({key:e.name,attrs:{name:e.name,label:e.label,error:t.allErrorMessages[e.name],disabled:t.isConfirmPurchaseClicked,inputBackgroundColorClass:"theme-light:bg-[#ececec] theme-light:sibling-checked:bg-yellow"},model:{value:t.$v[e.name.split(".")[0]][e.name.split(".")[1]].$model,callback:function(r){t.$set(t.$v[e.name.split(".")[0]][e.name.split(".")[1]],"$model",r)},expression:"$v[input.name.split('.')[0]][input.name.split('.')[1]].$model"}},e.listeners))})),1)])],1),t._v(" "),r("div",[r("BookingHeading",{attrs:{id:"billing-heading"}},[t._v("Billing Details")]),t._v(" "),r("div",{staticClass:"\n\t\t\t\t\t\t\tbg-white\n\t\t\t\t\t\t\tpx-6\n\t\t\t\t\t\t\tpy-5\n\t\t\t\t\t\t\tmt-5\n\t\t\t\t\t\t\ttheme-light:px-0 theme-light:mt-0 theme-light:py-6\n\t\t\t\t\t\t\tContainerCheckout__booking-details\n\t\t\t\t\t\t"},[t.order.total?r("div",{staticClass:"space-y-1.5 mt-3"},[r("PaymentDetails",{key:t.paymentDetailsKey,ref:"paymentDetails",attrs:{cardTypeSessionId:t.cardTypeSessionId,initializationSessionId:t.order.paymentGatewaySessionInitial,bookingNumber:t.order.bookingNumber,total:t.order.total,gatewayId:t.gatewayId,publicKey:t.publicKey,environment:t.environment,rebilling:t.rebilling,order:t.order}
1,on:{handleClickCheckout:t.handleClickCheckout,showDialogOnErrorOnDiscoverCase:t.showDialogOnErrorOnDiscoverCase,setPaymentMethod:t.setPaymentMethod,validateForm:t.validateForm,success:t.handlePaymentDetailsSuccess}}),t._v(" "),t.errorPaymentDetails?r("div",{staticClass:"flex justify-end"},[r("div",{staticClass:"text-sm text-error"},[t._v(t._s(t.errorPaymentDetails))])]):t._e()],1):r("div",{staticClass:"text-center font-bold text-primary-2"},[t._v("No payment is required")])])],1)]),t._v(" "),r("div",{staticClass:"text-right font-extrabold !mt-2 hidden theme-light:block",staticStyle:{"font-size":"10px"}},[t._v("\n\t\t\t\t* Required fields\n\t\t\t")]),t._v(" "),t._m(0)]),t._v(" "),r("div",{staticClass:"md:col-4 mt-15 md:mt-0 ContainerCheckout__col"},[r("BookingSummary",{staticClass:"ContainerBooking__BookingSummary",attrs:{entries:t.bookingSummaryEntries,ticketRemovalDisabled:t.isConfirmPurchaseClicked||t.hasNswVoucher,hidePricePerLine:""},on:{"remove-item":t.handleBookingSummaryRemoveItem},scopedSlots:t._u([{key:"buttons",fn:function(){return[t.bookingSummaryEntries&&t.bookingSummaryEntries.length&&"credit_card"===t.selectedPayment?r("Button",{attrs:{disabled:t.isLoading,variant:"secondary"},on:{click:function(e){return e.preventDefault(),t.handleClickCheckout(e)}}},[r("span",[t._v("Confirm purchase →")])]):t._e(),t._v(" "),r("Button",{staticClass:"!bg-transparent",attrs:{tag:"a",href:"namedetails",variant:"transparent",disabled:t.isLoading}},[r("span",[t._v("← Back")])])]},proxy:!0},{key:"before-total",fn:function(){return[r("div",{staticClass:"mt-8 space-y-3"},[r("div",{staticClass:"divide-y divide-[#eee]"},[t._l(t.order.vouchers,(function(e){return r("div",{staticClass:"flex text-[green] space-between relative py-1"},[r("div",{staticClass:"flex-1"},[r("div",[t._v(t._s(e.code))]),t._v(" "),e.description?r("div",{staticClass:"font-normal"},[t._v("\n\t\t\t\t\t\t\t\t\t\t"+t._s(e.description)+"\n\t\t\t\t\t\t\t\t\t")]):t._e()]),t._v(" "),r("div",[t._v("-"+t._s(t._f("currency")(e.value,"$")))]),t._v(" "),t.isConfirmPurchaseClicked?t._e(
1):r("button",{staticClass:"text-yellow u-vertical-center -right-5 w-3.5 h-3.5 leading-none",attrs:{type:"button","aria-label":"Remove voucher"},on:{click:function(r){return t.handleRemoveVoucherClick(e.code)}}},[r("svg",{staticClass:"w-full h-full",attrs:{"aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 352 512"}},[r("path",{attrs:{fill:"currentColor",d:"M242.72 256l100.07-100.07c12.28-12.28 12.28-32.19 0-44.48l-22.24-22.24c-12.28-12.28-32.19-12.28-44.48 0L176 189.28 75.93 89.21c-12.28-12.28-32.19-12.28-44.48 0L9.21 111.45c-12.28 12.28-12.28 32.19 0 44.48L109.28 256 9.21 356.07c-12.28 12.28-12.28 32.19 0 44.48l22.24 22.24c12.28 12.28 32.2 12.28 44.48 0L176 322.72l100.07 100.07c12.28 12.28 32.2 12.28 44.48 0l22.24-22.24c12.28-12.28 12.28-32.19 0-44.48L242.72 256z"}})])])])})),t._v(" "),t.totalVouchers>0?r("div",{staticClass:"flex font-bold text-[green] py-1"},[r("div",{staticClass:"flex-1"},[t._v("Total Discount")]),t._v(" "),r("div",{},[t._v("-"+t._s(t._f("currency")(t.totalVouchers,"$")))])]):t._e()],2),t._v(" "),t.order.dndtimelimit&&t.timelimit>0&&!t.isConfirmPurchaseClicked?r("div",{key:t.order.dndtimelimit,staticClass:"mt-6"},[r("countdown",{attrs:{time:t.timelimit},on:{end:t.handleTimerEnded},scopedSlots:t._u([{key:"default",fn:function(e){var n=e.minutes,i=e.seconds;return[60*n+i>0?r("div",[t._v("\n\t\t\t\t\t\t\t\t\t\tService NSW voucher will expire in:"),r("br"),t._v(t._s(t._f("twoDigits")(n))+":"+t._s(t._f("twoDigits")(i))+"\n\t\t\t\t\t\t\t\t\t\t"),r("progress",{staticClass:"w-full",attrs:{max:t.timelimit/1e3},domProps:{value:60*n+i}})]):t._e()]}}],null,!1,2639990708)}
1)],1):t._e(),t._v(" "),t.isConfirmPurchaseClicked?t._e():r("form",{on:{submit:function(e){return e.preventDefault(),t.handleApplyVoucherClick(e)}}},[r("div",{staticClass:"text-sm text-[1rem] font-normal my-1"},[t._v("\n\t\t\t\t\t\t\t\tEnter your gift voucher or promo code here.\n\t\t\t\t\t\t\t")]),t._v(" "),r("div",{staticClass:"flex space-x-5.5 theme-light:space-x-4"},[r("div",{staticClass:"relative flex-1"},[r("label",{staticClass:"block text-primary-2 space-y-1.5 items-center md:flex md:space-y-0"},[r("span",{staticClass:"\n\t\t\t\t\t\t\t\t\t\t\t\tblock\n\t\t\t\t\t\t\t\t\t\t\t\tmd:text-right\n\t\t\t\t\t\t\t\t\t\t\t\tw-30\n\t\t\t\t\t\t\t\t\t\t\t\tflex-shrink-0\n\t\t\t\t\t\t\t\t\t\t\t\ttext-label\n\t\t\t\t\t\t\t\t\t\t\t\tBaseTextbox__label\n\t\t\t\t\t\t\t\t\t\t\t\tsr-only\n\t\t\t\t\t\t\t\t\t\t\t"},[t._v("\n\t\t\t\t\t\t\t\t\t\t\tEnter code\n\t\t\t\t\t\t\t\t\t\t")]),t._v(" "),r("input",{directives:[{name:"model",rawName:"v-model",value:t.voucherInput,expression:"voucherInput"}],staticClass:"\n\t\t\t\t\t\t\t\t\t\t\t\tflex-1\n\t\t\t\t\t\t\t\t\t\t\t\tbg-grey-3\n\t\t\t\t\t\t\t\t\t\t\t\ttheme-light:bg-[#ececec]\n\t\t\t\t\t\t\t\t\t\t\t\tfocus:bg-white\n\t\t\t\t\t\t\t\t\t\t\t\tborder border-grey-3\n\t\t\t\t\t\t\t\t\t\t\t\ttheme-light:border-[#ececec]\n\t\t\t\t\t\t\t\t\t\t\t",attrs:{type:"text",placeholder:"Enter code",disabled:0==t.order.total},domProps:{value:t.voucherInput},on:{input:function(e){e.target.composing||(t.voucherInput=e.target.value)}}})])]),t._v(" "),r("div",{staticClass:"flex flex-col justify-end"},[r("button",{class:["border-3 border-highlight rounded-full font-extrabold py-1.5 px-4.5 focus:outline-none hover:bg-highlight hover:text-white transition duration-300","disabled:border-grey disabled:text-grey disabled:bg-white disabled:opacity-50 disabled:cursor-not-allowed text-xbase BookingSummary__apply","theme-light:border-0 theme-light:bg-yellow theme-light:text-xs theme-light:rounded-full theme-light:hover:bg-green theme-light:focus:bg-green theme-light:h-[34px] theme-light:!tracking-normal theme-light:text-white"],attrs:{type:"submit",disabled:!t.voucherInput.length||0==t.order.total||t.isLoading}},[t._v("\n\t\t\t\t\t\t\t\t\t\tApply\n\t\t\t\t\t\t\t\t\t")])])])])])]},proxy:!0},{key:"total",fn:function(){return[r("div",[t._v(t._s(t._f("currency")(t.order.total,"$",2)))])]},proxy:!0}])})],1)]),t._v(" "),r("div",{staticClass:"hidden",domProps:{innerHTML:t._s(t.secure3DForm)}})])}),[function(){var t=this.$createElement,e=this._self._c||t;return e("span",{staticClass:"text-sm inline-block mt-[8px]"},[this._v("\n\t\t\t\tPlease also view the\n\t\t\t\t"),e("a",{staticClass:"font-bold text-inherit hocus:text-inherit theme-light:text-yellow theme-light:hocus:text-yellow underline",attrs:{href:"https://sydneyzoo.com/privacy/",target:"_blank"}},[this._v("Sydney Zoo Privacy Policy")]),this._v("\n\t\t\t\tand our "),e("a",{staticClass:"font-bold text-inherit hocus:text-inherit theme-light:text-yellow theme-light:hocus:text-yellow underline",attrs:{href:"https://sydneyzoo.com/privacy/",target:"_blank"}},[this._v("Collection Notice")]),this._v("\n\t\t\t\tto understand how we collect and handle your personal information.\n\t\t\t")])}],!1,null,null,null).exports}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.