1var k=(s,e,u)=>new Promise((b,o)=>{var a=d=>{try{p(u.next(d))}catch(f){o(f)}},_=d=>{try{p(u.throw(d))}catch(f){o(f)}},p=d=>d.done?b(d.value):Promise.resolve(d.value).then(a,_);p((u=u.apply(s,e)).next())});import{a as S,Q as E}from"./entry.CoPCKUW3BkOv.js";import{a as U}from"./chunk.vKmSb7iagUEM.js";import{R as B}from"./chunk.BYYn09UaC-Rz.js";import{U as N}from"./chunk.MdNQ6rdoEQWs.js";import{R as M}from"./chunk.CVYLX2CFNG5a.js";import{c as A,n as F}from"./chunk.CEjCldHVkN4e.js";import{L as V}from"./chunk.DGksOcLQgZEB.js";import{q as y,V as L,s as i,z as r,C as t,A as n,S as x,E as h,F as v,T as w,y as g,x as m,N as C,v as q,a0 as I,_ as j}from"./chunk.BhnF8lqErK1Y.js";import{a as P}from"./chunk.C6PXV3Pxc_ps.js";import"./chunk.DMiigLJ6-phQ.js";import"./chunk.BbtcIZGqd4iu.js";const R={components:{RoundedInput:B,UnderlinedSelect:N,RequiredFieldInfo:M},data(){return{school:{type:"",name:"",website:"",country:V.getItem("bookDemoCountry",""),studentCount:""},admin:{firstName:"",lastName:"",workMail:"",phone:"",needs:""},currentStep:E.get("step")==="calendar"?3:1,steps:[{number:1,name:`${this.__("School")} / ${this.__("Organization")}`},{number:2,name:this.__("Administrator")}],countryOptions:[],status:"idle",analyticsStepsCompleted:[],showEmailError:!1}},computed:{calendarLink(){return this.school.country==="NZ"||this.school.country==="AU"?"https://calendar.google.com/calendar/u/0/appointments/schedules/AcZssZ3lsKC9rhc5x9XPGsA0m7EU3IJPgbqTGEevuFdf_PMv_wjBC8GbtULcifH7Bln0_tM2lKMdJTPm":"https://calendar.google.com/calendar/u/0/appointments/schedules/AcZssZ1X3_KiPlmndqZDPePRxhGKpj8UeaptfMPp2ivN2WojtFcBlLrflkwNhPnAtnfaU8H116R_lhLM"}},created(){this.loadCountries(),this.SCHOOL_TYPES=[{label:this.__("Select school type"),value:""},{label:this.__("School"),value:"school"},{label:this.__("School district or group"),value:"school_district_or_group"},{label:this.__("University or higher education"),value:"university"},{label:this.__("Business"),value:"business"},{label:this.__("Vocational school"),value:"vocational_school"},{label:this.__("Other"),value:"other"}]},methods:{sendAnalyticsEvent(s){this.analyticsStepsCompleted.includes(s)||(this.analyticsStepsCompleted.push(s),window.dataLayer.push({event:s,user_data:{sha256_email_address:F(this.admin.workMail)}}))},nextStep(){this.$refs.schoolInformationForm.checkValidity()?(this.currentStep+=1,this.sendAnalyticsEvent("book_a_demo_school_info")):this.$refs.schoolInformationForm.reportValidity()},previousStep(){this.currentStep-=1},submit(){return k(this,null,function*(){var s,e,u,b;if(this.showEmailError=!1,!this.$refs.adminInformationForm.checkValidity())this.$refs.adminInformationForm.reportValidity();else{this.status="pending";try{yield S.post("/book-demo",{data:{school:this.school,administrator:this.admin}}),this.sendAnalyticsEvent("book_a_demo_form_submitted")}catch(a){this.status="idle",(e=(s=a==null?void 0:a.response)==null?void 0:s.data)!=null&&e.errors&&"data.administrator.workMail"in(((b=(u=a==null?void 0:a.response)==null?void 0:u.data)==null?void 0:b.errors)||{})&&(this.showEmailError=!0);return}const o=["exam.net","staging-app-pardot-fh.redwater-27df5bbc.northeurope.azurecontainerapps.io"].includes(window.location.hostname);V.setItem("bookDemoCountry",this.school.country),U.send({url:o?"https://go.exam.net/l/1056423/2024-03-04/44x8":"dummy-url-for-testing",data:{email:this.admin.workMail,schoolType:this.school.type,schoolName:this.school.name,schoolWebsite:this.school.website,studentCount:this.school.studentCount,countryCode:this.school.country,firstName:this.admin.firstName,lastName:this.admin.lastName,phone:this.admin.phone,needs:this.admin.needs,emailOptIn:"True"}})}})},loadCountries(){S.get("/api/countries").then(s=>{this.countryOptions=[{label:this.__("Select country"),value:""},...s.data.filter(e=>A(e.en_name)).map(({en_name:e,country_code:u})=>({label:e,value:u})).sort((e,u)=>e.label.localeCompare(u.label))]}).catch(s=>{console.error(s)})}}},T={class:"bg-white container h-full mb-8 mt-6 mx-auto overflow-hidden rounded-xl shadow-md"},O={key:0,class:"flex flex-col justify-center mt-8 mx-auto w-4/5"},z={class:"font-semibold sm:truncate text-3xl text-center text-gray-900"},H={class:"intro-text"},D={class:"mt-4 text-lg"},Z={class:"mb-9 mt-4 text-left text-lg"},G={key:1,class:"my-2 shadow"},K={class:"divide-gray-300 divide-y md:divide-y-0 md:flex"},W={class:"flex font-medium items-center leading-5 px-6 py-4 space-x-4 text-base"},Y={key:0,class:"h-6 text-white w-6",viewBox:"0 0 20 20",fill:"currentColor"},J={class:"font-medium leading-5 text-gray-900 text-sm"}
1,Q={key:0,class:"absolute h-full hidden md:block right-0 top-0 w-5"},X={key:2,class:"bg-white form-wrapper mx-auto px-6 py-2 w-96"},$={class:"font-medium leading-6 mb-5 mt-8 text-gray-900 text-left text-xl"},ee={ref:"schoolInformationForm",action:""},te={class:"space-y-5"},oe={class:"block font-medium text-base text-exam-gray-900"},se=["disabled","value","textContent"],le={class:"block font-medium text-base text-exam-gray-900"},ne=["value","disabled","selected","textContent"],ie={class:"flex justify-center p-6"},re={key:3,class:"bg-white"},ae={class:"form-wrapper mx-auto px-6 py-2 w-96"},de={class:"font-medium leading-6 mb-5 mt-8 text-gray-900 text-left text-xl"},ue={ref:"adminInformationForm"},me={class:"space-y-5"},ce={class:"block font-medium text-exam-gray-900 text-sm"},he=["placeholder"],pe={class:"center flex items"},fe={for:"opt-in",class:"ml-2 text-exam-gray-900"},be={class:"flex flex-wrap-reverse justify-center p-6"},_e=["disabled"],ye={key:0,class:"text-center text-red-400"},xe={key:4,class:"flex flex-col items-center justify-center mx-auto py-8 text-center w-96"},ve={class:"font-bold mb-2 text-xl"};function we(s,e,u,b,o,a){const _=y("RequiredFieldInfo"),p=y("UnderlinedSelect"),d=y("RoundedInput"),f=L("sanitized-html");return i(),r("div",null,[t("div",T,[t("div",null,[o.currentStep!==3?(i(),r("div",O,[t("h1",z,n(s.__("Request a demo")),1),t("div",H,[x(t("p",D,null,512),[[f,s.__("If you want an exclusive look at everything Exam.net has to offer, we offer free live demos where you'll be able to ask questions and see the full experience.")]]),x(t("p",Z,null,512),[[f,s.__("If you have any other questions, feel free to contact us by email at <a href='mailto:[email protected]' rel='noopener'>[email protected]</a>.")]])])])):h("",!0),o.currentStep!==3?(i(),r("nav",G,[t("ul",K,[(i(!0),r(v,null,w(o.steps,l=>(i(),r("li",{key:l.number,class:"bg-white justify-center md:flex md:flex-1 relative"},[t("div",W,[t("div",{class:g(["duration-150 ease-in-out flex flex-shrink-0 h-10 items-center justify-center rounded-full transition w-10",{"bg-exam-blue":o.currentStep>l.number}])},[o.currentStep>l.number?(i(),r("svg",Y,[...e[13]||(e[13]=[t("path",{"fill-rule":"evenodd",d:"M16.707 5.293a1 1 0 010 1.414l-8 8a1 1 0 01-1.414 0l-4-4a1 1 0 011.414-1.414L8 12.586l7.293-7.293a1 1 0 011.414 0z","clip-rule":"evenodd"},null,-1)])])):(i(),r("div",{key:1,class:g(["border-2 flex flex-shrink-0 h-10 items-center justify-center rounded-full w-10",{"border-exam":o.currentStep===l.number}])},[t("p",{class:g(["text-gray",{"text-exam":o.currentStep===l.number}])},n(l.number),3)],2))],2),t("p",J,n(l.name),1)]),l.number<o.steps.length?(i(),r("div",Q,[...e[14]||(e[14]=[t("svg",{class:"h-full text-gray-300 w-full",viewBox:"0 0 22 80",fill:"none",preserveAspectRatio:"none"},[t("path",{d:"M0 -2L20 40L0 82","vector-effect":"non-scaling-stroke",stroke:"currentcolor","stroke-linejoin":"round"})],-1)])])):h("",!0)]))),128))])])):h("",!0),o.currentStep===1?(i(),r("div",X,[t("h2",$,n(s.__("School information")),1),t("form",ee,[m(_),t("div",te,[t("label",oe,[C(n(s.__("School type"))+" ",1),e[15]||(e[15]=t("span",null,"*",-1)),m(p,{modelValue:o.school.type,"onUpdate:modelValue":e[0]||(e[0]=l=>o.school.type=l),required:"",class:"mt-1"},{default:q(()=>[(i(!0),r(v,null,w(s.SCHOOL_TYPES,({label:l,value:c})=>(i(),r("option",{key:c,disabled:!c,value:c,textContent:n(l)},null,8,se))),128))]),_:1},8,["modelValue"])]),m(d,{modelValue:o.school.name,"onUpdate:modelValue":e[1]||(e[1]=l=>o.school.name=l),required:"",hasBorder:"",class:"mt-1",label:s.__("School name")},null,8,["modelValue","label"]),m(d,{modelValue:o.school.website,"onUpdate:modelValue":e[2]||(e[2]=l=>o.school.website=l),required:"",hasBorder:"",type:"text",class:"mt-1",inputHint:"www.example.com",label:s.__("School's web address")},null,8,["modelValue","label"]),m(d,{modelValue:o.school.studentCount,"onUpdate:modelValue":e[3]||(e[3]=l=>o.school.studentCount=l),required:"",hasBorder:"",type:"number",min:0,class:"mt-1",inputHint:s.__("Accurate students counts required for price quotes"),label:s.__("Approximate total number of students at your school")},null,8,["modelValue","inputHint","label"]),t("label",le,[C(n(s.__("Country"))+" ",1),e[16]||(e[16]=t("span",null,"*",-1)),m(p,{modelValue:o.school.country,"onUpdate:modelValue":e[4]||(e[4]=l=>o.school.country=l),required:"required",class:"mt-1"},{default:q(()=>[(i(!0),r(v,null,w(o.countryOptions,({label:l,value:c})=>(i(),r("option",{key:c,value:c,disabled:!c,selected:!c,textContent:n(l)},null,8,ne))),128))]),_:1},8,["modelValue"])])]),t("div",ie,[t("button",{type:"button",class:"border border-exam-blue duration-150 ease-in-out focus:outline-none font-medium hover:border-exam-orange hover:text-exam-orange px-8 py-2 rounded-full text-base text-exam-blue transition",onClick:e[5]||(e[5]=I((...l)=>a.nextStep&&a.nextStep(...l),["prevent"]))},n(s.__("Continue")),1)])],512)])):h("",!0),o.currentStep===2?(i(),r("div",re,[t("div",ae,[t("h2",de,n(s.__("Administrator information")),1),t("form",ue,[m(_),t("div",me,[m(d,{modelValue:o.admin.firstName,"onUpdate:modelValue":e[6]||(e[6]=l=>o.admin.firstName=l),required:"",hasBorder:"",class:"mt-1",label:s.__("First name")},null,8,["modelValue","label"]),m(d,{modelValue:o.admin.lastName,"onUpdate:modelValue":e[7]||
1(e[7]=l=>o.admin.lastName=l),required:"",hasBorder:"",class:"mt-1",label:s.__("Last name")},null,8,["modelValue","label"]),m(d,{modelValue:o.admin.workMail,"onUpdate:modelValue":e[8]||(e[8]=l=>o.admin.workMail=l),required:"",hasBorder:"",type:"email",class:"mt-1",label:s.__("Work email")},null,8,["modelValue","label"]),m(d,{modelValue:o.admin.phone,"onUpdate:modelValue":e[9]||(e[9]=l=>o.admin.phone=l),type:"tel",required:"",hasBorder:"",class:"mt-1",label:s.__("Phone number")},null,8,["modelValue","label"]),t("label",ce,[t("div",null,n(s.__("Tell us about your needs"))+" *",1),x(t("textarea",{"onUpdate:modelValue":e[10]||(e[10]=l=>o.admin.needs=l),required:"",class:"border font-normal h-20 mt-2 p-2 resize-none rounded w-full",placeholder:`${s.__("Type here")}...`},null,8,he),[[j,o.admin.needs]])]),t("div",pe,[e[17]||(e[17]=t("input",{id:"opt-in",type:"checkbox",required:"",class:"h-4 mt-1 w-4"},null,-1)),t("label",fe,n(s.__("I consent to Exam.net using my personal data to contact me regarding my inquiry.")),1)])])],512)]),t("div",be,[t("button",{type:"button",class:"duration-150 ease-in-out focus:outline-none font-medium hover:text-exam-orange opacity-80 px-8 py-2 rounded-full text-base text-exam-blue transition",onClick:e[11]||(e[11]=(...l)=>a.previousStep&&a.previousStep(...l))},n(s.__("Back")),1),t("button",{type:"button",class:"bg-exam-blue border duration-150 ease-in-out focus:outline-none font-medium hover:bg-exam-orange px-8 py-2 rounded-full submit-btn text-base text-white transition",disabled:o.status==="pending",onClick:e[12]||(e[12]=I((...l)=>a.submit&&a.submit(...l),["prevent"]))},n(s.__("Submit")),9,_e)]),o.showEmailError?(i(),r("p",ye,n(s.__("If you do not have an organisation email, email [email protected] with your request.")),1)):h("",!0)])):h("",!0),o.currentStep===3?(i(),r("div",xe,[e[18]||(e[18]=t("div",{class:"bg-blue-100 flex h-8 items-center justify-center mb-4 rounded-full w-8"},[t("svg",{xmlns:"http://www.w3.org/2000/svg",class:"h-5 text-exam-blue w-5",viewBox:"0 0 512 512"},[t("title",null,"Checkmark"),t("path",{fill:"none",stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"32",d:"M416 128L192 384l-96-96"})])],-1)),t("h1",ve,n(s.__("Your request for a demo has been submitted.")),1),t("p",null,n(s.__("We will respond to you within 2 business days to set up a meeting. Thank you!")),1)])):h("",!0)])])])}const Ae=P(R,[["render",we],["__scopeId","data-v-da47931a"]]);export{Ae as default}; 2//# sourceMappingURL=chunk.bqtO87kh6w-W.js.map
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.