1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[9739],{39571:function(e,r,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/bookings/cancel",function(){return t(63624)}])},21212:function(e,r,t){"use strict";var i=t(85893),o=t(50661);let n=(0,o.keyframes)(["0%{transform:rotate(0deg);}100%{transform:rotate(360deg);}"]),s=o.default.div.withConfig({componentId:"sc-263faced-0"})(["display:flex;justify-content:center;align-items:center;padding:2rem;min-height:200px;"]),a=o.default.div.withConfig({componentId:"sc-263faced-1"})(["border:4px solid ",";border-top:4px solid ",";border-radius:50%;width:50px;height:50px;animation:"," 1s linear infinite;"],e=>e.theme.colors.grey||"#f3f3f3",e=>e.theme.colors.primary,n);r.Z=()=>(0,i.jsx)(s,{children:(0,i.jsx)(a,{})})},59618:function(e,r,t){"use strict";t.d(r,{W:function(){return i},x:function(){return o}});let i={AED:{pos:"prefix",space:!0,symbol:"AED"},AUD:{pos:"prefix",space:!0,symbol:"AUD"},BRL:{pos:"prefix",space:!1,symbol:"R$"},CAD:{pos:"prefix",space:!0,symbol:"CAD"},CHF:{pos:"prefix",space:!0,symbol:"CHF"},CNY:{pos:"prefix",space:!1,symbol:"\xa5"},DKK:{pos:"suffix",space:!0,symbol:"kr"},EUR:{pos:"prefix",space:!1,symbol:"â¬"},GBP:{pos:"prefix",space:!1,symbol:"\xa3"},HKD:{pos:"prefix",space:!0,symbol:"HKD"},IDR:{pos:"prefix",space:!1,symbol:"Rp",dp:0},INR:{pos:"prefix",space:!1,symbol:"â¹"},JPY:{pos:"prefix",space:!1,symbol:"\xa5",dp:0},KRW:{pos:"prefix",space:!1,symbol:"â©",dp:0},NZD:{pos:"prefix",space:!0,symbol:"NZD"},PLN:{pos:"suffix",space:!0,symbol:"zÅ"},SGD:{pos:"prefix",space:!0,symbol:"SGD"},THB:{pos:"prefix",space:!1,symbol:"฿"},TRY:{pos:"prefix",space:!1,symbol:"âº"},USD:{pos:"prefix",space:!1,symbol:"$"}},o=(e,r,t={})=>{let o,n;let s=r||"GBP",a=i[s]||{pos:"prefix",space:!0,symbol:s},l="number"==typeof e?e:parseFloat(String(e)),c=Number.isFinite(l);if(Number.isInteger(a.dp))o=n=a.dp;else if(null!=t.minimumFractionDigits||null!=t.maximumFractionDigits){let e=t.minimumFractionDigits??0,r=t.maximumFractionDigits??e;n=Math.max(o=Math.max(0,Math.min(20,e)),Math.min(20,r))}else o=n=0;let d=c?l.toLocaleString("en-US",{minimumFractionDigits:o,maximumFractionDigits:n}):e;return"prefix"===a.pos?`${a.symbol}${a.space?" ":""}${d}`:`${d}${a.space?" ":""}${a.symbol}`}},63624:function(e,r,t){"use strict";t.r(r),t.d(r,{__N_SSG:function(){return L},default:function(){return K}});var i=t(85893),o=t(67294),n=t(41664),s=t.n(n),a=t(11163),l=t(50661),c=t(32369),d=t(49092);let m=l.default.div.withConfig({componentId:"sc-7f3de728-0"})(["padding:1.25rem;border:1px solid ",";border-radius:0.25rem;@media (min-width:","){margin:0 0 1.25rem 0;}"],e=>e.theme.colors.dustyGrey,d.Z.md),h=l.default.h2.withConfig({componentId:"sc-7f3de728-1"})(["font-size:1.25rem;line-height:1.5rem;margin:0 0 1.25rem 0;"]),p=l.default.h2.withConfig({componentId:"sc-7f3de728-2"})(["font-size:1rem;line-height:1.2;color:",";margin:0 0 0.625rem;"],e=>e.theme.colors.sharkGrey),f=l.default.p.withConfig({componentId:"sc-7f3de728-3"})(["margin-bottom:1.25rem;font-size:1rem;line-height:1.2;color:",";"],e=>e.theme.colors.sharkGrey),u=l.default.div.withConfig({componentId:"sc-7f3de728-4"})(["border-top:1px solid ",";display:grid;grid-template-columns:repeat(2,1fr);padding-top:1.25rem;margin-bottom:1.25rem;div{display:flex;flex-direction:column;&:first-of-type{padding-right:1rem;border-right:1px solid ",";}&:nth-of-type(2){padding-left:1rem;}span{margin-bottom:0.625rem;font-size:1rem;line-height:1.118rem;}p,b{font-size:1rem;line-height:1.118rem;margin-bottom:0;}}"],e=>e.theme.colors.dustyGrey,e=>e.theme.colors.dustyGrey),g=l.default.div.withConfig({componentId:"sc-7f3de728-5"})(["display:flex;flex-direction:column;margin-bottom:1.25rem;border-bottom:1px solid ",";padding-bottom:1.25rem;p{margin-bottom:0;}"],e=>e.theme.colors.dustyGrey),x=l.default.div.withConfig({componentId:"sc-7f3de728-6"})(["border-bottom:1px solid ",";margin-bottom:1.25rem;padding-bottom:1.25rem;b{line-height:1.5rem;display:block;}p{margin:0;}"],e=>e.theme.colors.dustyGrey);var b=({property:e,nights:r,checkin:t,roomName:o})=>{let n,s;let{t:a,ready:l}=(0,c.V)("components/bookingDetails");if(t&&r){let e=new Date(t),i=new Date(t);i.setDate(i.getDate()+parseInt(r)),n=e.toString().split(" ").slice(0,4).join(" "),s=i.toString().split(" ").slice(0,4).join(" ")}return e?(0,i.jsxs)(m,{children:[(0,i.jsx)(h,{children:a("your_booking_details")}),(0,i.jsx)(p,{children:e.name}),e.address&&(0,i.jsxs)(f,{children:[e.address.line1?`${e.address.line1}, `:"",e.address.line2?`${e.address.line2}, `:"",e.address.city?`${e.address.city}, `:"",e.address.postCode?`${e.address.postCode}, `:"",e.address.state?`${e.address.state}`:""]}),n&&s&&(0,i.jsxs)(u,{children:[(0,i.jsxs)("div",{children:[(0,i.jsx)("span",{children:a("check_in")}),(0,i.jsx)("b",{children:n}),e.checkinInfo?.beginTime&&(0,i.jsx)("p",{children:e.checkinInfo.beginTime})]}),(0,i.jsxs)("div",{children:[(0,i.jsx)("span",{children:a("check_out")}),(0,i.jsx)("b",{children:s}),e.checkoutInfo?.endTime&&(0,i.jsxs)("p",{children:[a("until")," ",e.checkoutInfo.endTime]})]})]}),r&&(0,i.jsxs)(g,{children:[(0,i.jsx)("p",{children:a("total_length_stay")}),(0,i.jsxs)("b",{children:[r," ",a("night",{count:parseInt(r)})]})]}),o&&(0,i.jsxs)(x,{children:[(0,i.jsx)("b",{children:a("you_selected")}),(0,i.jsx)("p",{children:o})]})]}):null},y=t(37251),j=t(13223),w=t(21212),k=t(25461),_=t(80462),v=t(19857),C=t(59618),I=t(81531),S=t(97684),D=t(53);let N=e=>{if(!e)return"";let r=String(e).toUpperCase();return C.W[r]?.symbol||r},G=l.default.div.withConfig({componentId:"sc-70f2cc07-0"})(["padding-top:1.25rem;"]),F=l.default.h1.withConfig({componentId:"sc-70f2cc07-1"})(["font-size:1.25rem;line-height:1.5rem;margin:0 0 1.25rem 0;"]),Z=l.default.form.withConfig({componentId:"sc-70f2cc07-2"})(['input{font-family:"DM Sans Variable",Montserrat,sans-serif;&.error{border-color:',";&::placeholder{color:",";}}}button{margin:1.25rem 0 2.375rem;width:10rem;display:flex;justify-content:center;&:disabled{background:",";}}@media (min-width:","){margin-top:1.25rem;}"],e=>e.theme.colors.red,e=>e.theme.colors.red,e=>e.theme.colors.mediumGrey,d.Z.md),$=l.default.div.withConfig({componentId:"sc-70f2cc07-3"})(["display:flex;flex-direction:column;margin-bottom:1.5rem;width:100%;@media (min-width:","){width:80%;}label{font-size:1rem;line-height:1.188rem;font-weight:600;margin-bottom:0.625rem;}span{display:block;font-weight:400;font-size:0.75rem;margin-top:0.25rem;}input{border-radius:0.25rem;background:",";border:1px solid #e0e0e0;outline:none;height:3rem;padding:0 0.625rem;font-size:0.875rem;color:",';font-family:"DM Sans Variable",Montserrat,sans-serif;&::placeholder{color:',";}&.error{border-color:",";&::placeholder{color:",";}}&:-webkit-autofill,&:-webkit-autofill:hover,&:-webkit-autofill:focus,&:-webkit-autofill:active{-webkit-box-shadow:0 0 0 1.5rem "," inset !important;}}"],d.Z.md,e=>e.theme.colors.smokeGrey,e=>e.theme.colors.darkGrey,e=>e.theme.colors.darkGrey,e=>e.theme.colors.red,e=>e.theme.colors.red,e=>e.theme.colors.smokeGrey),z=l.default.div.withConfig({componentId:"sc-70f2cc07-4"})(["color:",";background:#b33f40;padding:0.625rem;margin-bottom:0.625rem;border-radius:0.25rem;font-size:0.688rem;"],e=>e.theme.colors.white),T=l.default.div.withConfig({componentId:"sc-70f2cc07-5"})(["margin:2rem 0;padding:1.25rem;border:1px solid ",";border-radius:0.25rem;h2{font-size:1.25rem;margin:0 0 0.75rem;}p{margin:0 0 0.5rem;color:",";}a{color:",";font-weight:600;}"],e=>e.theme.colors.borderGrey,e=>e.theme.colors.darkGrey,e=>e.theme.colors.primary),R=l.default.div.withConfig({componentId:"sc-70f2cc07-6"}
1)(["height:100%;width:100%;position:fixed;left:0;z-index:1;top:0;opacity:0.3;background:",";"],e=>e.theme.colors.black),P=l.default.div.withConfig({componentId:"sc-70f2cc07-7"})(["position:fixed;top:50%;left:50%;transform:translate(-50%,-50%);background:white;padding:1.5rem;border-radius:0.25rem;z-index:2;max-width:400px;width:90%;button{position:absolute;top:0.5rem;right:0.5rem;height:1.75rem;width:1.75rem;display:flex;background:transparent;justify-content:center;align-items:center;cursor:pointer;border:none;font-size:1rem;padding:0;}"]),E=l.default.div.withConfig({componentId:"sc-70f2cc07-8"})(["display:flex;flex-direction:column;justify-content:space-between;margin-bottom:1.25rem;p:first-of-type{margin-bottom:0.15rem;}.actions{display:flex;gap:0.625rem;margin-top:1rem;}button.no{background:white;color:",";border:"," 2px solid;box-sizing:border-box;width:unset;height:3rem;display:flex;align-items:center;margin:0;}button.yes{height:3rem;width:6rem;margin:0;}"],e=>e.theme.colors.primary,e=>e.theme.colors.primary),M=l.default.div.withConfig({componentId:"sc-70f2cc07-9"})(["a{color:",";display:flex;align-items:center;margin:0.9375rem 0;font-weight:600;text-decoration:none;}p{margin:0;color:",";}"],e=>e.theme.colors.primary,e=>e.theme.colors.darkGrey),q=l.default.div.withConfig({componentId:"sc-70f2cc07-10"})(["margin:1.25rem 0;h3{margin:0 0 1.25rem 0;}a{color:",";}"],e=>e.theme.colors.primary),A=l.default.div.withConfig({componentId:"sc-70f2cc07-11"})(["border:1px solid ",";border-radius:0.25rem;padding:1rem 1.25rem;margin-top:1.25rem;h3{font-size:1.125rem;margin:0 0 1rem;}"],e=>e.theme.colors.borderGrey),U=l.default.div.withConfig({componentId:"sc-70f2cc07-12"})(["display:flex;justify-content:space-between;margin-bottom:0.5rem;p{margin:0;font-size:0.875rem;}&.total{border-top:1px solid ",";padding-top:0.5rem;margin-top:0.5rem;p{font-weight:700;}}"],e=>e.theme.colors.borderGrey),B=l.default.img.withConfig({componentId:"sc-70f2cc07-13"})(["width:100%;object-fit:cover;margin-bottom:1.25rem;height:15rem;border-radius:0.25rem;"]),O={title:"Cancellation - LateRooms - Book Cheap Hotels & Last Minute Hotel Deals",description:"It's going to be a great night⦠Now book yourself a great room, with LateRooms. Find top hotel deals for all occasions. Tonight, or any night.",robots:!1},H=(e="")=>e.trim().replace(/\.+$/,"");var L=!0,K=()=>{let{t:e,ready:r}=(0,c.V)("components/cancel"),t=(0,a.useRouter)(),[n,l]=(0,o.useState)(!1),[d,m]=(0,o.useState)(""),[h,p]=(0,o.useState)(""),[f,u]=(0,o.useState)(!1),[g,x]=(0,o.useState)(!1),[C,L]=(0,o.useState)(!1),[K,V]=(0,o.useState)(!1),[W,J]=(0,o.useState)(!1),[Y,X]=(0,o.useState)(!1),[Q,ee]=(0,o.useState)(null),[er,et]=(0,o.useState)(null),[ei,eo]=(0,o.useState)(null),[en,es]=(0,o.useState)(!1),[ea,el]=(0,o.useState)(null),[ec,ed]=(0,o.useState)(null),[em,eh]=(0,o.useState)(null),[ep,ef]=(0,o.useState)(null),[eu,eg]=(0,o.useState)(""),[ex,eb]=(0,o.useState)(""),[ey,ej]=(0,o.useState)(!1),[ew,ek]=(0,o.useState)(!1),[e_,ev]=(0,o.useState)(!1),eC=n&&t.isReady?t.query.tk||!1:null,eI=D.x(eC)?.src==="hotelbeds";(0,o.useEffect)(()=>
1{l(!0)},[]);let eS=()=>JSON.parse(window.localStorage.getItem("locale")||"null")||(0,I.Z)("/en-gb/"),eD=async()=>{J(!0),X(!1);try{let e=(await v.l.query({query:S.fn,variables:{email:d,key:H(h),token:eC},fetchPolicy:"network-only",context:{headers:eS()}})).data.retrieveBooking;ee(e),es(e.onlineCancellation),el(e.totalNow),ed(e.taxesAndFees),eh(e.payableAtProperty),ef(e.grandTotal),eb(e.currency),eg(N(e.currency));let r=new Date(e.checkin),t=new Date(e.checkout);eo(Math.ceil(Math.abs(t-r)/864e5));let i=await v.l.query({query:S.eC,variables:{id:parseInt(e.propertyId)},fetchPolicy:"network-only",context:{headers:eS()}});et(i.data.getProperty)}catch(e){console.error("Retrieve booking error:",e),X(!0)}finally{J(!1)}},eN=async()=>{ek(!0);try{await v.l.mutate({mutation:S.W2,variables:{email:d.toLowerCase(),key:H(h),token:eC},context:{headers:eS()}}),ej(!0)}catch(e){console.error("Cancel booking error:",e),ev(!0)}finally{ek(!1)}},eG=/^\w+([.-]?\w+)*@\w+([.-]?\w+)*(\.\w{2,3})+$/,eF=eG.test(d.trim()),eZ=""!==h.trim(),e$=eF&&eZ;return n&&r&&null!==eC?(0,i.jsx)(_.Z,{isBooking:!0,page:"cancel",seo:O,children:(0,i.jsx)(G,{children:(0,i.jsxs)(j.Z,{children:[(0,i.jsxs)(k.Z,{children:[!eC&&(0,i.jsx)(y.Z,{lg:6,lgOffset:1,md:7,children:(0,i.jsxs)(T,{children:[(0,i.jsx)("h2",{children:"Cancellation link required"}),(0,i.jsx)("p",{children:"This page requires a cancellation token from your booking confirmation email. Please check your email for a cancellation link, or use the link from your booking confirmation."}),(0,i.jsxs)("p",{children:["Need help? ",(0,i.jsx)(s(),{href:"/contact-us",children:"Contact our support team"})," or call"," ",(0,i.jsx)("a",{href:"tel:+442034674017",children:"+44 20 3467 4017"}),"."]})]})}),eC&&!ey&&!ew&&(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)(y.Z,{lg:6,lgOffset:1,md:7,children:[!er&&!W&&(0,i.jsxs)(Z,{onSubmit:e=>{e.preventDefault(),eC&&(L(!0),V(!0),u(!eF),x(!eZ),e$&&eD())},children:[(0,i.jsx)(F,{children:e("cancellation")}),C&&f&&(0,i.jsx)(z,{children:e("email_is_required")}),K&&g&&(0,i.jsx)(z,{children:e("itinerary_number_is_required")}),(0,i.jsxs)($,{children:[(0,i.jsx)("label",{htmlFor:"email",children:e("email")}),(0,i.jsx)("input",{className:C&&f?"error":"",id:"email",name:"email",type:"email",value:d,onChange:e=>{let r=e.target.value;m(r),L(!0),u(!eG.test(r.trim()))}})]}),(0,i.jsxs)($,{children:[(0,i.jsxs)("label",{htmlFor:"id",children:[e("itinerary_number"),(0,i.jsx)("span",{children:e("this_can_be_found")})]}),(0,i.jsx)("input",{className:K&&g?"error":"",id:"id",name:"id",type:"text",value:h,onChange:e=>{let r=H(e.target.value);p(r),V(!0),x(""===r.trim())}})]}),(0,i.jsx)("button",{disabled:!e$||W,type:"submit",children:"Submit"})]}),W&&(0,i.jsx)(w.Z,{}),er&&en&&!e_&&(0,i.jsxs)(E,{children:[(0,i.jsxs)("div",{children:[(0,i.jsxs)("p",{children:[e("are_you_sure_you")," ",(0,i.jsx)("b",{children:e("cancel")})]}),(0,i.jsx)("p",{children:(0,i.jsx)("b",{children:er.name})})]}),(0,i.jsxs)("div",{className:"actions",children:[(0,i.jsx)("button",{className:"yes",onClick:eN,children:e("confirm")}),(0,i.jsx)(s(),{href:"/searches",children:(0,i.jsx)("button",{className:"no",children:e("go_back")})})]})]}),er&&er.images?.[0]?.large&&(0,i.jsx)(B,{alt:er.images[0].caption||er.name,src:er.images[0].large}),er&&!en&&(0,i.jsxs)(M,{children:[(0,i.jsx)("h4",{children:e("please_contact_customer_support")}),(0,i.jsx)("a",{href:eI?"tel:02035143316":"tel:+442034674017",children:eI?"0203 514 3316":"+44 20 3467 4017"}),(0,i.jsx)("p",{children:e("you_will_need_your")})]}),e_&&(0,i.jsxs)(q,{children:[(0,i.jsx)("h3",{children:e("oops_an_error_has")}),(0,i.jsxs)("p",{children:[e("we_re_sorry_there")," ",(0,i.jsx)(s(),{href:"USD"===ex?"/en-us/contact-us":"/contact-us",children:e("contact_us")})," ",e("and_we_will_get")]})]})]}),(0,i.jsx)(y.Z,{lg:4,md:5,children:er&&(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(b,{checkin:Q?.checkin,nights:ei,property:er,roomName:Q?.rooms?.[0]?.name}),ep&&(0,i.jsxs)(A,{children:[(0,i.jsx)("h3",{children:"Price summary"}),ea&&(0,i.jsxs)(U,{children:[(0,i.jsx)("p",{children:"Total now"}),(0,i.jsxs)("p",{children:[eu,Number(ea).toFixed(2)]})]}),ec&&(0,i.jsxs)(U,{children:[(0,i.jsx)("p",{children:"Taxes & fees"}),(0,i.jsxs)("p",{children:[eu,Number(ec).toFixed(2)]})]}),em&&(0,i.jsxs)(U,{children:[(0,i.jsx)("p",{children:"Payable at property"}),(0,i.jsxs)("p",{children:[eu,Number(em).toFixed(2)]})]}),(0,i.jsxs)(U,{className:"total",children:[(0,i.jsx)("p",{children:"Grand total"}),(0,i.jsxs)("p",{children:[eu,Number(ep).toFixed(2)]})]})]})]})})]}),eC&&!ey&&ew&&(0,i.jsx)(y.Z,{lg:6,lgOffset:1,md:7,children:(0,i.jsx)(w.Z,{})}),ey&&(0,i.jsxs)(y.Z,{lg:6,lgOffset:1,md:7,children:[(0,i.jsx)("h4",{children:e("your_booking_has_been")}),(0,i.jsx)(s(),{href:"/searches",children:(0,i.jsx)("button",{style:{marginTop:"0.9375rem"},children:e("back_to_search")})})]})]}),Y&&(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)(P,{children:[(0,i.jsx)("button",{onClick:()=>X(!1),children:"â"}),(0,i.jsx)("p",{children:e("oops_no_booking_found")}),(0,i.jsx)("p",{children:e("please_review_your_information")})]}),(0,i.jsx)(R,{onClick:()=>X(!1)})]})]})})}):(0,i.jsx)(_.Z,{isBooking:!0,page:"cancel",seo:O,children:(0,i.jsx)(G,{children:(0,i.jsx)(j.Z,{children:(0,i.jsx)(w.Z,{})})})})}},53:function(e,r,t){"use strict";t.d(r,{x:function(){return o}});var i=t(61202);let o=e=>{try{return(0,i.o)(e)}catch{return null}}},61202:function(e,r,t){"use strict";t.d(r,{o:function(){return o}});
1class i extends Error{}function o(e,r){let t;if("string"!=typeof e)throw new i("Invalid token specified: must be a string");r||(r={});let o=!0===r.header?0:1,n=e.split(".")[o];if("string"!=typeof n)throw new i(`Invalid token specified: missing part #${o+1}`);try{t=function(e){let r=e.replace(/-/g,"+").replace(/_/g,"/");switch(r.length%4){case 0:break;case 2:r+="==";break;case 3:r+="=";break;default:throw Error("base64 string is not of the correct length")}try{var t;return t=r,decodeURIComponent(atob(t).replace(/(.)/g,(e,r)=>{let t=r.charCodeAt(0).toString(16).toUpperCase();return t.length<2&&(t="0"+t),"%"+t}))}catch(e){return atob(r)}}(n)}catch(e){throw new i(`Invalid token specified: invalid base64 for part #${o+1} (${e.message})`)}try{return JSON.parse(t)}catch(e){throw new i(`Invalid token specified: invalid json for part #${o+1} (${e.message})`)}}i.prototype.name="InvalidTokenError"}},function(e){e.O(0,[8701,5063,462,2888,9774,179],function(){return e(e.s=39571)}),_N_E=e.O()}]);
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.