1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6483],{85349:function(e,r,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/check-warranty",function(){return t(39082)}])},99763:function(e,r,t){"use strict";t.d(r,{Z:function(){return a}});let a=(0,t(33592).Z)("arrow-left",[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]])},72003:function(e,r,t){"use strict";t.d(r,{Z:function(){return a}});let a=(0,t(33592).Z)("calendar",[["path",{d:"M8 2v4",key:"1cmpym"}],["path",{d:"M16 2v4",key:"4m81vk"}],["rect",{width:"18",height:"18",x:"3",y:"4",rx:"2",key:"1hopcy"}],["path",{d:"M3 10h18",key:"8toen8"}]])},23973:function(e,r,t){"use strict";t.d(r,{Z:function(){return a}});let a=(0,t(33592).Z)("circle-alert",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]])},55975:function(e,r,t){"use strict";t.d(r,{Z:function(){return a}});let a=(0,t(33592).Z)("circle-check",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]])},18742:function(e,r,t){"use strict";t.d(r,{Z:function(){return a}});let a=(0,t(33592).Z)("clock",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16 14",key:"68esgv"}]])},83917:function(e,r,t){"use strict";t.d(r,{Z:function(){return a}});let a=(0,t(33592).Z)("file-text",[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]])},57211:function(e,r,t){"use strict";t.d(r,{Z:function(){return a}});let a=(0,t(33592).Z)("image",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",ry:"2",key:"1m3agn"}],["circle",{cx:"9",cy:"9",r:"2",key:"af1f0g"}],["path",{d:"m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21",key:"1xmnt7"}]])},114:function(e,r,t){"use strict";t.d(r,{Z:function(){return a}});let a=(0,t(33592).Z)("loader-circle",[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]])},53487:function(e,r,t){"use strict";t.d(r,{Z:function(){return a}});let a=(0,t(33592).Z)("search",[["path",{d:"m21 21-4.34-4.34",key:"14j7rj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}]])},40594:function(e,r,t){"use strict";t.d(r,{Z:function(){return a}});let a=(0,t(33592).Z)("send",[["path",{d:"M14.536 21.686a.5.5 0 0 0 .937-.024l6.5-19a.496.496 0 0 0-.635-.635l-19 6.5a.5.5 0 0 0-.024.937l7.93 3.18a2 2 0 0 1 1.112 1.11z",key:"1ffxy3"}],["path",{d:"m21.854 2.147-10.94 10.939",key:"12cjpa"}]])},74326:function(e,r,t){"use strict";t.d(r,{Z:function(){return a}});let a=(0,t(33592).Z)("shield-check",[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]])},59911:function(e,r,t){"use strict";t.d(r,{Z:function(){return a}});let a=(0,t(33592).Z)("shield",[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}]])},32330:function(e,r,t){"use strict";t.d(r,{Z:function(){return a}});let a=(0,t(33592).Z)("wrench",[["path",{d:"M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.77-3.77a6 6 0 0 1-7.94 7.94l-6.91 6.91a2.12 2.12 0 0 1-3-3l6.91-6.91a6 6 0 0 1 7.94-7.94l-3.76 3.76z",key:"cbrjhi"}]])},89556:function(e,r,t){"use strict";t.d(r,{Z:function(){return o}});var a=t(85893),s=t(9008),n=t.n(s),i=t(18755),l=t(64566);function o(e){let{children:r,title:t,metaDescription:s,canonical:o,noindex:d}=e,c=t?"".concat(t," | The Travelling Technicians"):"The Travelling Technicians | Mobile & Laptop Repair at Your Doorstep",m=s||"Expert mobile phone and laptop repair services right at your doorstep across the Lower Mainland, BC. Book online for convenient tech repair that comes to you.";return(0,a.jsxs)("div",{className:"flex flex-col min-h-screen",children:[(0,a.jsxs)(n(),{children:[(0,a.jsx)("title",{children:c}
1,"title"),(0,a.jsx)("meta",{name:"viewport",content:"width=device-width, initial-scale=1"}),(0,a.jsx)("meta",{name:"description",content:m},"description"),(0,a.jsx)("link",{rel:"icon",href:"/favicon.ico"}),(0,a.jsx)("link",{rel:"apple-touch-icon",href:"/favicons/favicon-192x192.png"}),(0,a.jsx)("link",{rel:"icon",type:"image/png",sizes:"32x32",href:"/favicons/favicon-32x32.png"}),(0,a.jsx)("link",{rel:"icon",type:"image/png",sizes:"192x192",href:"/favicons/favicon-192x192.png"}),(0,a.jsx)("link",{rel:"manifest",href:"/manifest.json"}),(0,a.jsx)("meta",{name:"theme-color",content:"#102a43"}),(0,a.jsx)("meta",{property:"og:title",content:c},"og:title"),(0,a.jsx)("meta",{property:"og:description",content:m},"og:description"),(0,a.jsx)("meta",{property:"og:type",content:"website"},"og:type"),(0,a.jsx)("meta",{property:"og:image",content:"https://www.travelling-technicians.ca/images/og/og-default.png"},"og:image"),(0,a.jsx)("meta",{property:"og:image:width",content:"1200"}),(0,a.jsx)("meta",{property:"og:image:height",content:"630"}),(0,a.jsx)("meta",{name:"twitter:card",content:"summary_large_image"},"twitter:card"),(0,a.jsx)("meta",{name:"twitter:title",content:c},"twitter:title"),(0,a.jsx)("meta",{name:"twitter:description",content:m},"twitter:description"),(0,a.jsx)("meta",{name:"twitter:image",content:"https://www.travelling-technicians.ca/images/og/og-default.png"},"twitter:image"),o&&(0,a.jsx)("link",{rel:"canonical",href:o},"canonical"),d&&(0,a.jsx)("meta",{name:"robots",content:"noindex, nofollow"})]}),(0,a.jsx)("a",{href:"#main-content",className:"sr-only focus:not-sr-only focus:absolute focus:top-2 focus:left-2 focus:z-[60] focus:bg-white dark:focus:bg-primary-900 focus:text-primary-900 dark:focus:text-primary-100 focus:px-4 focus:py-2 focus:rounded-lg focus:shadow-lg focus:outline-none focus:ring-2 focus:ring-accent-500",children:"Skip to content"}),(0,a.jsx)(i.Z,{}),(0,a.jsx)("main",{id:"main-content",className:"flex-grow",children:r}),(0,a.jsx)(l.Z,{})]})}},69626:function(e,r,t){"use strict";t.d(r,{R0:function(){return n},b4:function(){return l},d7:function(){return i}});let a=/^\d{14,16}$/,s=/^[A-Z0-9]{8,15}$/;function n(e){if(null==e)return null;let r=String(e).trim().toUpperCase().replace(/[\s\-./]/g,"");return r.length>0?r:null}function i(e){return!!e&&(a.test(e)||s.test(e))}function l(e){return"ADMINNOTCOLLECTED"===n(e)}},39082:function(e,r,t){"use strict";t.r(r),t.d(r,{default:function(){return E}});var a=t(85893),s=t(67294),n=t(11163),i=t(89556),l=t(99062),o=t(59911),d=t(23973),c=t(53487),m=t(74326),u=t(72003),p=t(32330),x=t(18742),y=t(83917),h=t(32209),g=t(55975),f=t(29661),b=t(99763),k=t(40594),w=t(57211),j=t(114),v=t(22972);let N="image/jpeg,image/png,image/webp",C=new Set(["image/heic","image/heif"]);function _(e){let{photos:r,onChange:t,disabled:n,uploadToken:i}=e,l=(0,s.useRef)(null),[o,c]=(0,s.useState)(!1),[m,u]=(0,s.useState)(""),[p,x]=(0,s.useState)(!1),y=(0,s.useRef)(r);(0,s.useEffect)(()=>{y.current=r},[r]),(0,s.useEffect)(()=>()=>{y.current.forEach(e=>{e.preview_url&&URL.revokeObjectURL(e.preview_url)})},[]);let h=(0,s.useCallback)(async e=>{if(u(""),!i){u("Upload session expired. Please look up your warranty again before adding photos.");return}let a=5-r.length,s=Array.from(e).slice(0,a);Array.from(e).length>a&&u("Only ".concat(5," photos allowed. Skipped extras."));let n=[];c(!0);try{for(let e of s){if(e.size>10485760){u('"'.concat(e.name,'" is over 10 MB â skipped.'));continue}if(C.has(e.type)||/\.(heic|heif)$/i.test(e.name)){u('"'.concat(e.name,'" is HEIC â please convert to JPEG first. On iPhone: open the photo, tap Share, then "Save to Files" (which converts to JPEG), or change Camera Settings â Formats â Most Compatible.'));continue}if(!N.split(",").includes(e.type)){u('"'.concat(e.name,"\" isn't a supported image â please use JPEG, PNG, or WebP."));continue}let r=await fetch("/api/warranties/claims/upload-photo",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({filename:e.name,content_type:e.type,size_bytes:e.size,upload_token:i})}),t=await r.json();if(!r.ok||!t.success){u(t.message||"Couldn't prepare upload for \"".concat(e.name,'".'));continue}if(!(await fetch(t.upload_url,{method:"PUT",headers:{"Content-Type":e.type,"x-upsert":"true"},body:e})).ok){u('Upload failed for "'.concat(e.name,'". Please try again.'));continue}n.push({storage_path:t.storage_path,preview_url:URL.createObjectURL(e),filename:e.name,size_bytes:e.size})}t([...r,...n])}catch(e){u((null==e?void 0:e.message)||"Upload failed. Please try again.")}finally{c(!1),l.current&&(l.current.value="")}},[r,t,i]),g=e=>{let a=[...r],s=a.splice(e,1)[0];(null==s?void 0:s.preview_url)&&URL.revokeObjectURL(s.preview_url),t(a)};return(0,a.jsxs)("div",{children:[(0,a.jsxs)("label",{className:"block text-sm font-medium text-gray-700 dark:text-primary-300 mb
1-2",children:["Photos ",(0,a.jsxs)("span",{className:"text-gray-400 dark:text-primary-500",children:["(optional â up to ",5,")"]})]}),(0,a.jsxs)("div",{onDragOver:e=>{e.preventDefault(),n||x(!0)},onDragLeave:()=>x(!1),onDrop:e=>{var r;e.preventDefault(),x(!1),!n&&(null===(r=e.dataTransfer.files)||void 0===r?void 0:r.length)&&h(e.dataTransfer.files)},className:"border-2 border-dashed rounded-lg p-6 text-center transition-colors ".concat(p?"border-primary-500 bg-primary-50 dark:bg-primary-800/40":"border-gray-300 dark:border-primary-600 bg-white dark:bg-primary-800/60"," ").concat(n||r.length>=5?"opacity-50 pointer-events-none":""),children:[(0,a.jsx)(w.Z,{className:"w-8 h-8 text-gray-400 dark:text-primary-500 mx-auto mb-2"}),(0,a.jsxs)("p",{className:"text-sm text-gray-600 dark:text-primary-300 mb-2",children:["Drag photos here or"," ",(0,a.jsx)("button",{type:"button",onClick:()=>{var e;return null===(e=l.current)||void 0===e?void 0:e.click()},className:"text-primary-700 dark:text-primary-400 font-medium hover:underline",children:"choose files"})]}),(0,a.jsx)("p",{className:"text-xs text-gray-400 dark:text-primary-500",children:"JPEG, PNG, or WebP \xb7 up to 10 MB each"}),(0,a.jsx)("input",{ref:l,type:"file",accept:N,multiple:!0,className:"hidden",onChange:e=>e.target.files&&h(e.target.files)})]}),o&&(0,a.jsxs)("p",{className:"mt-2 text-sm text-gray-500 dark:text-primary-400 flex items-center gap-2",children:[(0,a.jsx)(j.Z,{className:"w-4 h-4 animate-spin"}),"Uploading..."]}),m&&(0,a.jsxs)("div",{className:"mt-2 flex items-start gap-2 p-2 bg-red-50 dark:bg-red-900/30 border border-red-200 dark:border-red-800 rounded text-sm",children:[(0,a.jsx)(d.Z,{className:"w-4 h-4 text-red-500 flex-shrink-0 mt-0.5"}),(0,a.jsx)("span",{className:"text-red-700 dark:text-red-300",children:m})]}),r.length>0&&(0,a.jsx)("div",{className:"mt-3 grid grid-cols-3 sm:grid-cols-5 gap-3",children:r.map((e,r)=>(0,a.jsxs)("div",{className:"relative aspect-square rounded-lg overflow-hidden border border-gray-200 dark:border-primary-700 group",children:[(0,a.jsx)("img",{src:e.preview_url,alt:e.filename,className:"w-full h-full object-cover"}),(0,a.jsx)("button",{type:"button",onClick:()=>g(r),disabled:n,"aria-label":"Remove ".concat(e.filename),className:"absolute top-1 right-1 bg-black/70 hover:bg-black/90 text-white rounded-full p-2 sm:p-1 opacity-100 sm:opacity-0 sm:group-hover:opacity-100 transition-opacity disabled:opacity-50 disabled:cursor-not-allowed",children:(0,a.jsx)(v.Z,{className:"w-4 h-4 sm:w-3 sm:h-3"})})]},e.storage_path))})]})}var Z=t(69626);function S(e){let{email:r,warrantyNumber:t,bookingRef:n,warrantyDeviceName:i,uploadToken:l,onCancel:o,onSubmitted:c}=e,[m,u]=(0,s.useState)(""),[p,x]=(0,s.useState)("anytime"),[y,h]=(0,s.use
1State)([]),[w,j]=(0,s.useState)(""),[v,N]=(0,s.useState)(!1),[C,S]=(0,s.useState)(""),T=m.trim(),P=T.length>=10&&T.length<=2e3,E=(0,s.useMemo)(()=>(0,Z.R0)(w),[w]),M=!!E&&(0,Z.d7)(E),D=w.trim().length>0;(0,s.useEffect)(()=>{if(!T||v)return;let e=e=>{e.preventDefault(),e.returnValue=""};return window.addEventListener("beforeunload",e),()=>window.removeEventListener("beforeunload",e)},[T,v]);let R=async e=>{if(e.preventDefault(),S(""),!M){S("Please enter the IMEI or serial number of your device.");return}if(!P){S("Please describe the issue (at least ".concat(10," characters)."));return}N(!0);try{let e=await fetch("/api/warranties/claims/create",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({email:r,warranty_number:t,booking_ref:n,issue_description:T,preferred_contact_window:p,photo_storage_paths:y.map(e=>e.storage_path),claimed_device_serial:E})}),a=await e.json();429===e.status?S("Too many attempts. Please wait a few minutes and try again."):e.ok&&a.success?c(a.claim_number):S(a.message||"Could not file claim. Please try again.")}catch(e){S("Network error. Please try again.")}finally{N(!1)}};return(0,a.jsxs)("form",{onSubmit:R,className:"space-y-5",children:[(0,a.jsxs)("div",{className:"flex items-start gap-3 p-3 bg-amber-50 dark:bg-amber-900/30 border border-amber-200 dark:border-amber-800 rounded-lg",children:[(0,a.jsx)(g.Z,{className:"w-5 h-5 text-amber-600 dark:text-amber-400 flex-shrink-0 mt-0.5"}),(0,a.jsxs)("div",{className:"text-sm text-amber-900 dark:text-amber-200",children:[(0,a.jsxs)("p",{className:"font-medium mb-1",children:["Filing a claim for: ",i]}),(0,a.jsx)("p",{className:"text-amber-800 dark:text-amber-300 text-xs",children:"We'll call you within 24 hours to confirm the details and agree a time. If approved, the re-repair is free."})]})]}),(0,a.jsxs)("div",{children:[(0,a.jsxs)("label",{htmlFor:"claimSerial",className:"block text-sm font-medium text-gray-700 dark:text-primary-300 mb-1",children:[(0,a.jsx)(f.Z,{className:"w-4 h-4 inline-block mr-1 -mt-0.5"}),"Device IMEI / Serial ",(0,a.jsx)("span",{className:"text-red-500",children:"*"})]}),(0,a.jsx)("input",{id:"claimSerial",type:"text",value:w,onChange:e=>j(e.target.value),maxLength:20,autoComplete:"off",autoCorrect:"off",autoCapitalize:"characters",inputMode:"text",spellCheck:!1,required:!0,placeholder:"e.g. 356938765432101 (IMEI) or C02XK0AAJG5J (Apple serial)","aria-describedby":"claim-serial-help","aria-invalid":!!D&&!M||void 0,className:"w-full px-4 py-3 border border-gray-300 dark:border-primary-600 dark:bg-primary-800/60 dark:text-primary-100 rounded-lg font-mono focus:outline-none focus:ring-2 focus:ring-primary-500 focus:border-transparent"}),(0,a.jsx)("p",{id:"claim-serial-help",className:"mt-1 text-xs text-gray-500 dark:text-primary-400",children:"Find this in Settings â General â About on your phone, or About This Mac on a MacBook. We use it to verify the warranty matches the device youâre claiming about."}),D&&!M&&(0,a.jsx)("p",{className:"mt-1 text-xs text-red-500",role:"alert","aria-live":"polite",children:"That doesnât look right. IMEIs are 14-16 digits; Apple serials are 8-15 letters/numbers."})]}),(0,a.jsxs)("div",{children:[(0,a.jsxs)("label",{htmlFor:"issue",className:"block text-sm font-medium text-gray-700 dark:text-primary-300 mb-1",children:["What's going wrong? ",(0,a.jsx)("span",{className:"text-red-500",children:"*"})]}),(0,a.jsx)("textarea",{id:"issue",value:m,onChange:e=>u(e.target.value.slice(0,2e3)),rows:5,required:!0,placeholder:"Describe the issue in detail. When did it start? What's happening now? Does it happen all the time or only sometimes?",className:"w-full px-4 py-3 border border-gray-300 dark:border-primary-600 dark:bg-primary-800/60 dark:text-primary-100 rounded-lg focus:outline-none focus:ring-2 focus:ring-primary-500 focus:border-transparent resize-y"}),(0,a.jsxs)("p",{className:"mt-1 text-xs ".concat(T.length>0&&!P?"text-red-500":"text-gray-500 dark:text-primary-400"),children:[T.length," / ",2e3," characters ",T.length>0&&T.length<10?"(minimum ".concat(10,")"):""]})]}),(0,a.jsxs)("div",{children:[(0,a.jsx)("label",{htmlFor:"contact-window",className:"block text-sm font-medium text-gray-700 dark:text-primary-300 mb
1-1",children:"Best time to reach you"}),(0,a.jsxs)("select",{id:"contact-window",value:p,onChange:e=>x(e.target.value),className:"w-full px-4 py-3 border border-gray-300 dark:border-primary-600 dark:bg-primary-800/60 dark:text-primary-100 rounded-lg focus:outline-none focus:ring-2 focus:ring-primary-500 focus:border-transparent",children:[(0,a.jsx)("option",{value:"anytime",children:"Anytime"}),(0,a.jsx)("option",{value:"morning",children:"Morning (9amâ12pm)"}),(0,a.jsx)("option",{value:"afternoon",children:"Afternoon (12pmâ5pm)"}),(0,a.jsx)("option",{value:"evening",children:"Evening (5pmâ8pm)"})]})]}),(0,a.jsx)(_,{photos:y,onChange:h,disabled:v,uploadToken:l}),C&&(0,a.jsxs)("div",{className:"flex items-start gap-2 p-3 bg-red-50 dark:bg-red-900/30 border border-red-200 dark:border-red-800 rounded-lg",children:[(0,a.jsx)(d.Z,{className:"w-5 h-5 text-red-500 flex-shrink-0 mt-0.5"}),(0,a.jsx)("p",{className:"text-sm text-red-700 dark:text-red-300",children:C})]}),(0,a.jsxs)("div",{className:"flex gap-3 pt-2",children:[(0,a.jsxs)("button",{type:"button",onClick:o,disabled:v,className:"flex-1 sm:flex-none px-4 py-3 border border-gray-300 dark:border-primary-600 text-gray-700 dark:text-primary-300 rounded-lg font-medium hover:bg-gray-50 dark:hover:bg-primary-700/40 transition-colors flex items-center justify-center gap-2",children:[(0,a.jsx)(b.Z,{className:"w-4 h-4"}),"Back"]}),(0,a.jsx)("button",{type:"submit",disabled:v||!P||!M,className:"flex-1 btn-primary flex items-center justify-center gap-2",children:v?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("div",{className:"w-4 h-4 border-2 border-white/30 border-t-white rounded-full animate-spin"}),"Filing..."]}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(k.Z,{className:"w-4 h-4"}),"File Claim"]})})]}),(0,a.jsx)("p",{className:"text-xs text-gray-500 dark:text-primary-400 text-center",children:"By filing this claim you confirm the details are accurate. False claims may void the warranty."}),(0,a.jsx)("div",{className:"mt-3 pt-3 border-t border-gray-200 dark:border-primary-700",children:(0,a.jsxs)("p",{className:"text-xs text-gray-500 dark:text-primary-400 leading-relaxed",children:[(0,a.jsx)("strong",{className:"text-gray-600 dark:text-primary-300",children:"Privacy:"})," ","The details and photos you submit are stored securely on our private cloud, reviewed only by our triage team for the purpose of assessing your claim, and retained for up to 24 months after resolution. We do not share them with third parties except as needed to perform the re-repair (your assigned technician). See our"," ",(0,a.jsx)("a",{href:"/privacy-policy#data-retention",target:"_blank",rel:"noopener noreferrer",className:"text-primary-700 dark:text-primary-400 underline hover:no-underline",children:"Privacy Policy"})," ","for the full retention table and your access/deletion rights under PIPEDA."]})})]})}let T={submitted:"Under review",under_review:"Under review",approved:"Approved â appointment scheduled",scheduled:"Scheduled â re-repair upcoming",in_progress:"Re-repair in progress",resolved:"Re-repaired and resolved",rejected:"Not covered",cancelled:"Cancelled"},P={active:{bg:"bg-green-100 dark:bg-green-900/40",text:"text-green-800 dark:text-green-300",label:"Active"},expired:{bg:"bg-gray-100 dark:bg-primary-700/50",text:"text-gray-800 dark:text-primary-300",label:"Expired"},void:{bg:"bg-red-100 dark:bg-red-900/40",text:"text-red-800 dark:text-red-300",label:"Void"},claimed:{bg:"bg-blue-100 dark:bg-blue-900/40",text:"text-blue-800 dark:text-blue-300",label:"Claimed"}};function E(){var e,r,t;let g=(0,n.useRouter)(),{display:f,href:b}=(0,h.N_)(),[k,w]=(0,s.useState)("warranty"),[j,v]=(0,s.useState)(""),[N,C]=(0,s.useState)(""),[_,Z]=(0,s.useState)(""),[E,M]=(0,s.useState)(!1),[D,R]=(0,s.useState)(null),[W,F]=(0,s.useState)(""),[z,A]=(0,s.useState)(!1),[L,O]=(0,s.useState)(!1),[U,I]=(0,s.useState)(null),q=(0,s.useRef)(null),B=(0,s.useRef)(!1);(0,s.useEffect)(()=>{var e,r;if(!g.isReady||B.current)return;B.current=!0;let t="string"==typeof g.query.wt?g.query.wt.trim():"",a="string"==typeof g.query.ref?g.query.ref.trim():"";t?(w("warranty"),C(t),null===(e=q.current)||void 0===e||e.focus()):a&&(w("booking"),Z(a),null===(r=q.current)||void 0===r||r.focus())},[g.isReady,g.query]);let J=async e=>{if(e.preventDefault(),F(""),A(!1),R(null),!j){F("Please enter your email address.");return}if("warranty"===k&&!N){F("Please enter your warranty number.");return}if("booking"===k&&!_){F("Please enter your booking reference.");return}M(!0);try{let e={email:j.trim()};"warranty"===k?e.warranty_number=N.trim().toUpperCase():e.booking_ref=_.trim().toUpperCase();let r=await fetch("/api/warranties/lookup",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)}),t=await r.json();429===r.status?F("Too many requests. Please wait a minute and try again."):r.ok&&t.success?R(t):(F(t.message||"No warranty found. Please check your details and try again."),404===r.status&&A(!0))}catch(e){F("Something went wrong. Please try again later.")}finally{M(!1)}},G=null!=D&&("active"===D.warranty.status||"claimed"===D.warranty.status)&&D.warranty.days_remaining>0&&!D.claim&&!D.service_order;return(0,a.jsx)(i.Z,{title:"Check Warranty Status | The Travelling Technicians",metaDescription:"Look up your repair warranty status. Enter your warranty number or booking reference to check coverage details.",canonical:"https://www.travelling-technicians.ca/check-warranty",children:(0,a.jsxs)("div",{className:"max-w-2xl mx-auto px-4 py-16 sm:px-6 sm:py-24 lg:px-8",children:[(0,a.jsxs)("div",{className:"text-center mb-10",children:[(0,a.jsx)("div",{className:"inline-flex items-center justify-center w-16 h-16 rounded-full bg-primary-100 dark:bg-primary-700/50 mb-4",children:(0,a.jsx)(o.Z,{className:"w-8 h-8 text-primary-700 dark:text-primary-300"})}),(0,a.jsx)("h1",{className:"text-3xl font-heading font-bold text-primary-900 dark:text-primary-100 mb-3",children:"Check Your Warranty Status"}),(0,a.jsx)("p",{className:"text-gray-600 dark:text-primary-300 max-w-md mx-auto",children:"Enter your warranty number or booking reference along with your email to view your warranty coverage."})]}),!D&&(0,a.jsx)("div",{className:"bg-white dark:bg-primary-800/60 shadow-lg rounded-xl overflow-hidden",children:(0,a.jsxs)("div",{className:"px-6 py-6 sm:p-8",children:[(0,a.jsxs)("div",{className:"flex rounded-lg bg-gray-100 dark:bg-primary-700/50 p-1 mb-6",children:[(0,a.jsx)("button",{type:"button",onClick:()=>{w("warranty"),F(""),A(!1)},className:"flex-1 py-2.5 text-sm font-medium rounded-md transition-colors ".concat("warranty"===k?"bg-white dark:bg-primary-600 text-primary-900 dark:text-primary-100 shadow-sm":"text-gray-600 dark:text-primary-400 hover:text-gray-900 dark:hover:text-primary-200"),children:"Warranty Number"}),(0,a.jsx)("button",{type:"button",onClick:()=>{w("booking"),F(""),A(!1)},className:"flex-1 py-2.5 text-sm font-medium rounded-md transition-colors ".concat("booking"===k?"bg-white dark:bg-primary-600 text-primary-900 dark:text-primary-100 shadow-sm":"text-gray-600 dark:text-primary-400 hover:text-gray-900 dark:hover:text-primary-200"),children:"Booking Reference"})]}),(0,a.jsxs)("form",{onSubmit:J,className:"space-y-4",children:[(0,a.jsxs)("div",{children:[(0,a.jsx)("label",{htmlFor:"email",className:"block text-sm font-medium text-gray-700 dark:text-primary-300 mb
1-1",children:"Email Address"}),(0,a.jsx)("input",{ref:q,type:"email",id:"email",value:j,onChange:e=>v(e.target.value),className:"w-full px-4 py-3 border border-gray-300 dark:border-primary-600 dark:bg-primary-800/60 dark:text-primary-100 rounded-lg focus:outline-none focus:ring-2 focus:ring-primary-500 focus:border-transparent",placeholder:"The email used for your booking"})]}),"warranty"===k?(0,a.jsxs)("div",{children:[(0,a.jsx)("label",{htmlFor:"warranty",className:"block text-sm font-medium text-gray-700 dark:text-primary-300 mb-1",children:"Warranty Number"}),(0,a.jsx)("input",{type:"text",id:"warranty",value:N,onChange:e=>C(e.target.value),autoCapitalize:"characters",autoCorrect:"off",spellCheck:!1,className:"w-full px-4 py-3 border border-gray-300 dark:border-primary-600 dark:bg-primary-800/60 dark:text-primary-100 rounded-lg focus:outline-none focus:ring-2 focus:ring-primary-500 focus:border-transparent font-mono",placeholder:"e.g. WT-260207-A1B2C3D4"})]}):(0,a.jsxs)("div",{children:[(0,a.jsx)("label",{htmlFor:"bookingRef",className:"block text-sm font-medium text-gray-700 dark:text-primary-300 mb-1",children:"Booking Reference"}),(0,a.jsx)("input",{type:"text",id:"bookingRef",value:_,onChange:e=>Z(e.target.value),autoCapitalize:"characters",autoCorrect:"off",spellCheck:!1,className:"w-full px-4 py-3 border border-gray-300 dark:border-primary-600 dark:bg-primary-800/60 dark:text-primary-100 rounded-lg focus:outline-none focus:ring-2 focus:ring-primary-500 focus:border-transparent font-mono",placeholder:"e.g. TEC-12345"})]}),W&&(0,a.jsxs)("div",{className:"flex items-start gap-2 p-3 bg-red-50 dark:bg-red-900/30 border border-red-200 dark:border-red-800 rounded-lg",children:[(0,a.jsx)(d.Z,{className:"w-5 h-5 text-red-500 flex-shrink-0 mt-0.5"}),(0,a.jsxs)("div",{className:"flex-1",children:[(0,a.jsx)("p",{className:"text-sm text-red-700 dark:text-red-300",children:W}),z&&(0,a.jsxs)("div",{className:"mt-2 space-y-1.5 text-sm text-red-700 dark:text-red-300",children:[(0,a.jsx)("button",{type:"button",onClick:()=>{w("warranty"===k?"booking":"warranty"),F(""),A(!1)},className:"underline font-medium text-left hover:text-red-900 dark:hover:text-red-200",children:"warranty"===k?"Try your booking or bill reference instead (starts with TTR-, TTA- or SO-, itâs in every email from us)":"Try your warranty number instead (starts with WT-)"}),(0,a.jsx)("p",{children:"Warranties are created when your repair is completed."}),(0,a.jsxs)("p",{children:["Still stuck? Call us at"," ",(0,a.jsx)("a",{href:b,className:"underline font-medium hover:text-red-900 dark:hover:text-red-200",children:f}),"."]})]})]})]}),(0,a.jsx)("button",{type:"submit",disabled:E,className:"w-full btn-primary flex items-center justify-center gap-2",children:E?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("div",{className:"w-4 h-4 border-2 border-white/30 border-t-white rounded-full animate-spin"}),"Looking up..."]}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(c.Z,{className:"w-4 h-4"}),"Check Warranty"]})})]})]})}),D&&(0,a.jsx)("div",{className:"bg-white dark:bg-primary-800/60 shadow-lg rounded-xl overflow-hidden",children:(0,a.jsxs)("div",{className:"px-6 py-6 sm:p-8",children:[(0,a.jsxs)("div",{className:"text-center mb-6",children:[(0,a.jsx)("div",{className:"inline-flex items-center justify-center w-14 h-14 rounded-full bg-green-100 dark:bg-green-900/40 mb-3",children:(0,a.jsx)(m.Z,{className:"w-7 h-7 text-green-600 dark:text-green-400"})}),(0,a.jsx)("div",{className:"mb-3",children:(0,a.jsx)("span",{className:"inline-flex px-3 py-1 text-sm font-semibold rounded-full ".concat((null===(e=P[D.warranty.status])||void 0===e?void 0:e.bg)||"bg-gray-100 dark:bg-primary-700/50"," ").concat((null===(r=P[D.warranty.status])||void 0===r?void 0:r.text)||"text-gray-800 dark:text-primary-300"),children:(null===(t=P[D.warranty.status])||void 0===t?void 0:t.label)||D.warranty.status})}),(0,a.jsx)("p",{className:"text-sm text-gray-500 dark:text-primary-400 mb-1",children:"Warranty Number"}),(0,a.jsx)("p",{className:"text-2xl font-mono font-bold text-primary-900 dark:text-primary-100",children:D.warranty.warranty_number})]}),"active"===D.warranty.status&&(0,a.jsxs)("div",{className:"mb-6 p-4 bg-gray-50 dark:bg-primary-800/40 rounded-lg",children:[(0,a.jsxs)("div",{className:"flex justify-between text-sm mb-2",children:[(0,a.jsx)("span",{className:"text-gray-600 dark:text-primary-300",children:"Coverage Remaining"}),(0,a.jsxs)("span",{className:"font-semibold text-primary-900 dark:text-primary-100",children:[D.warranty.days_remaining," of ",D.warranty.duration_days," days"]})]}),(0,a.jsx)("div",{className:"w-full h-3 bg-gray-200 dark:bg-primary-700 rounded-full overflow-hidden",children:(0,a.jsx)("div",{className:"h-full bg-green-500 rounded-full transition-all",style:{width:"".concat(Math.round(D.warranty.days_remaining/D.warranty.duration_days*100),"%")}})})]}),(0,a.jsxs)("div",{className:"space-y-3 mb-6",children:[(0,a.jsxs)("div",{className:"flex items-center gap-3 py-2 border-b border-gray-100 dark:border-primary-700",children:[(0,a.jsx)(u.Z,{className:"w-4 h-4 text-gray-400 dark:text-primary-500 flex-shrink-0"}),(0,a.jsx)("span",{className:"text-sm text-gray-500 dark:text-primary-400 w-24",children:"Valid From"}),(0,a.jsx)("span",{className:"text-sm font-medium text-gray-900 dark:text-primary-100",children:new Date(D.warranty.start_date).toLocaleDateString("en-CA",{month:"long",day:"numeric",year:"numeric"})})]}),(0,a.jsxs)("div",{className:"flex items-center gap-3 py-2 border-b border-gray-100 dark:border-primary-700",children:[(0,a.jsx)(u.Z,{className:"w-4 h-4 text-gray-400 dark:text-primary-500 flex-shrink-0"}),(0,a.jsx)("span",{className:"text-sm text-gray-500 dark:text-primary-400 w-24",children:"Valid Until"}),(0,a.jsx)("span",{className:"text-sm font-medium text-gray-900 dark:text-primary-100",children:new Date(D.warranty.end_date).toLocaleDateString("en-CA",{month:"long",day:"numeric",year:"numeric"})})]}),(0,a.jsxs)("div",{className:"flex items-center gap-3 py-2 border-b border-gray-100 dark:border-primary-700",children:[(0,a.jsx)(p.Z,{className:"w-4 h-4 text-gray-400 dark:text-primary-500 flex-shrink-0"}),(0,a.jsx)("span",{className:"text-sm text-gray-500 dark:text-primary-400 w-24",children:"Device"}),(0,a.jsx)("span",{className:"text-sm font-medium text-gray-900 dark:text-primary-100",children:D.booking.device_name})]}),(0,a.jsxs)("div",{className:"flex items-center gap-3 py-2 border-b border-gray-100 dark:border-primary-700",children:[(0,a.jsx)(p.Z,{className:"w-4 h-4 text-gray-400 dark:text-primary-500 flex-shrink-0"}),(0,a.jsx)("span",{className:"text-sm text-gray-500 dark:text-primary-400 w-24",children:"Service"}),(0,a.jsx)("span",{className:"text-sm font-medium text-gray-900 dark:text-primary-100",children:D.booking.service_name})]}),(0,a.jsxs)("div",{className:"flex items-center gap-3 py-2",children:[(0,a.jsx)(o.Z,{className:"w-4 h-4 text-gray-400 dark:text-primary-500 flex-shrink-0"}),(0,a.jsx)("span",{className:"text-sm text-gray-500 dark:text-primary-400 w-24",children:"Booking Ref"}),(0,a.jsx)("span",{className:"text-sm font-mono font-medium text-gray-900 dark:text-primary-100",children:D.booking.booking_ref})]})]}),U?(0,a.jsxs)("div",{className:"p-4 bg-green-50 dark:bg-green-900/30 border border-green-200 dark:border-green-800 rounded-lg text-center",children:[(0,a.jsx)(m.Z,{className:"w-8 h-8 text-green-600 dark:text-green-400 mx-auto mb-2"}),(0,a.jsxs)("p",{className:"text-sm font-semibold text-green-800 dark:text-green-200 mb-1",children:["Claim filed: ",U]}),(0,a.jsx)("p",{className:"text-xs text-green-700 dark:text-green-300",children:"Check your email for confirmation. We'll call you within 24 hours â or send an approval email with your appointment if it's clear cut."})]}):L?(0,a.jsx)("div",{className:"border-t border-gray-200 dark:border-primary-700 pt-6",children:(0,a.jsx)(S,{email:j,warrantyNumber:D.warranty.warranty_number,warrantyDeviceName:D.booking.device_name,uploadToken:D.upload_token,onCancel:()=>O(!1),onSubmitted:e=>{I(e),O(!1)}})}):D.claim?(0,a.jsx)("div",{className:"p-4 bg-blue-50 dark:bg-blue-900/30 border border-blue-200 dark:border-blue-800 rounded-lg",children:(0,a.jsxs)("div",{className:"flex items-start gap-3",children:[(0,a.jsx)(x.Z,{className:"w-5 h-5 text-blue-600 dar
1k:text-blue-400 flex-shrink-0 mt-0.5"}),(0,a.jsxs)("div",{className:"flex-1",children:[(0,a.jsxs)("p",{className:"text-sm font-semibold text-blue-900 dark:text-blue-100 mb-1",children:["Claim ",D.claim.claim_number,": ",T[D.claim.status]||D.claim.status]}),(0,a.jsxs)("p",{className:"text-xs text-blue-800 dark:text-blue-300",children:["Filed ",new Date(D.claim.created_at).toLocaleDateString("en-CA",{month:"long",day:"numeric",year:"numeric"}),". Watch your email for updates, or call"," ",(0,a.jsx)("a",{href:b,className:"font-medium underline",children:f})," ","to check status."]})]})]})}):D.service_order&&"active"===D.warranty.status?(0,a.jsx)("div",{className:"p-4 bg-blue-50 dark:bg-blue-900/30 border border-blue-200 dark:border-blue-800 rounded-lg",children:(0,a.jsxs)("p",{className:"text-sm text-blue-900 dark:text-blue-100",children:["This warranty is attached to a service bill. To make a claim, call"," ",(0,a.jsx)("a",{href:b,className:"font-medium underline",children:f})," ","and quote ",(0,a.jsx)("span",{className:"font-mono",children:D.warranty.warranty_number}),"."]})}):G?(0,a.jsxs)("div",{children:[(0,a.jsxs)("button",{onClick:()=>O(!0),className:"w-full btn-primary flex items-center justify-center gap-2",children:[(0,a.jsx)(y.Z,{className:"w-4 h-4"}),"File a Warranty Claim"]}),(0,a.jsxs)("p",{className:"mt-2 text-xs text-center text-gray-500 dark:text-primary-400",children:["Free re-repair if the same issue comes back. Or call"," ",(0,a.jsx)("a",{href:b,className:"underline",children:f}),"."]})]}):(0,a.jsx)("div",{className:"p-4 bg-primary-50 dark:bg-primary-800/40 rounded-lg text-center",children:(0,a.jsxs)("p",{className:"text-sm text-primary-800 dark:text-primary-200",children:["Need help? Call us at"," ",(0,a.jsx)("a",{href:b,className:"font-semibold text-primary-900 dark:text-primary-100 hover:underline",children:f})]})}),(0,a.jsx)("div",{className:"mt-4 text-center",children:(0,a.jsx)("button",{onClick:()=>{R(null),F(""),A(!1),O(!1),I(null)},className:"text-sm text-primary-600 dark:text-primary-400 hover:text-primary-800 dark:hover:text-primary-200 font-medium",children:"Look up another warranty"})})]})}),(0,a.jsxs)("div",{className:"mt-12 space-y-6",children:[(0,a.jsx)("h2",{className:"text-xl font-heading font-bold text-primary-900 dark:text-primary-100",children:"Frequently Asked Questions"}),(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("details",{className:"bg-white dark:bg-primary-800/60 rounded-lg shadow-sm border border-gray-200 dark:border-primary-700 group",children:[(0,a.jsxs)("summary",{className:"px-5 py-4 cursor-pointer text-sm font-medium text-gray-900 dark:text-primary-100 flex items-center justify-between",children:["What does my warranty cover?",(0,a.jsx)("span",{className:"text-gray-400 dark:text-primary-500 group-open:rotate-180 transition-transform",children:"â¼"})]}),(0,a.jsx)("div",{className:"px-5 pb-4 text-sm text-gray-600 dark:text-primary-300",children:"Your warranty covers defects in parts used during the repair, workmanship issues related to the service performed, and the same issue recurring within the warranty period. It does not cover new damage, water damage, software issues, or unrelated hardware problems."})]}),(0,a.jsxs)("details",{className:"bg-white dark:bg-primary-800/60 rounded-lg shadow-sm border border-gray-200 dark:border-primary-700 group",children:[(0,a.jsxs)("summary",{className:"px-5 py-4 cursor-pointer text-sm font-medium text-gray-900 dark:text-primary-100 flex items-center justify-between",children:["How do I file a warranty claim?",(0,a.jsx)("span",{className:"text-gray-400 dark:text-primary-500 group-open:rotate-180 transition-transform",children:"â¼"})]}),(0,a.jsxs)("div",{className:"px-5 pb-4 text-sm text-gray-600 dark:text-primary-300",children:["Look up your warranty above and click ",(0,a.jsx)("strong",{children:"File a Warranty Claim"}),". Youâll be able to describe the issue and attach photos. We review every claim and call you back within 24 hours; if approved, the re-repair visit is free. Prefer to call? ",(0,a.jsx)("a",{href:b,className:"text-primary-700 dark:text-primary-400 font-medium hover:underline",children:f}),"."]})]}),(0,a.jsxs)("details",{className:"bg-white dark:bg-primary-800/60 rounded-lg shadow-sm border border-gray-200 dark:border-primary-700 group",children:[(0,a.jsxs)("summary",{className:"px-5 py-4 cursor-pointer text-sm font-medium text-gray-900 dark:text-primary-100 flex items-center justify-between",children:["My warranty has expired. What now?",(0,a.jsx)("span",{className:"text-gray-400 dark:text-primary-500 group-open:rotate-180 transition-transform",children:"â¼"})]}),(0,a.jsxs)("div",{className:"px-5 pb-4 text-sm text-gray-600 dark:text-primary-300",children:["If your warranty has expired, we can still fix it â same doorstep service, same technicians."," ",(0,a.jsx)(l.Z,{href:"/book-online",className:"text-primary-700 dark:text-primary-400 font-medium hover:underline",children:"Book a new repair"}),", and any referral rewards you've earned can go toward it."]})]})]})]})]})})}}},function(e){e.O(0,[2840,274,2465,9371,512,2888,9774,179],function(){return e(e.s=85349)}),_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.