PageSourceSearch

https://www.hachmolog.com/assets/BackgroundInfoView-D2uuwNaO.js

js hachmolog.com collected 2026-09-24 14:15:02 UTC 13,116 bytes, 1 lines download raw bytes

1import{m as C,a as V}from"./vendor-vuex-DawOPd79.js";import{_ as F,h as T,N as k,s as b,E as d,n as v,o as q,C as P}from"./index-i_39S9TT.js";import{b as x}from"./vendor-exponential-backoff-CTCpx--5.js";import{u as R}from"./vendor-maz-ui-CcIfur3Z.js";import{C as L,V as A}from"./VolunteerService-HML8ZkvX.js";import{F as B}from"./FormSearchableSelect-BV2BiYkz.js";import{e as m,h as D}from"./vendor-vue-runtime-dom-ngu7FkgX.js";import{g as M}from"./vendor-lodash-es-Dr2nHDXK.js";import{ak as n,I as s,J as t,O as a,G,aN as w,H as l,i as f,aP as c,F as h,ap as W,ar as g}from"./vendor-vue-runtime-core-O0r61XkH.js";import{q as H,Q as I}from"./vendor-vue-shared-C_oE6NXO.js";import"./vendor-vue-devtools-api-Cow_pXkh.js";import"./vendor-vue-reactivity-_PYbVOMb.js";import"./vendor-vue-select-Cn2oH4dd.js";import"./vendor-vue-star-rating-D42Atl4Q.js";import"./vendor-vue-compiler-dom-BjqiHA0M.js";import"./vendor-vue-compiler-core-B_m9pfJg.js";import"./vendor-vue-BfDmC2hc.js";import"./vendor-ionic-vue-Cp6ESLlK.js";import"./vendor-ionic-core-DDVmzL1A.js";import"./vendor-ionicons-CnTsVUQ5.js";import"./vendor-gleap-C_nLUrYA.js";import"./vendor-posthog-js-BcP-dMRa.js";import"./vendor-vue-router-BrjMN5S_.js";import"./vendor-axios-D8dNGRK6.js";import"./vendor-err-code-Btjngwyv.js";import"./vendor-promise-retry-CvXhdAiW.js";import"./vendor-retry-Drt1HQ7J.js";import"./vendor-case-DCoxfN6b.js";import"./vendor-dayjs-CMAHqsIS.js";import"./vendor-xstate-gZzxgXGH.js";import"./vendor-socket-io-client-DrXE8q1S.js";import"./vendor-engine-io-client-C-_nnA9b.js";import"./vendor-engine-io-parser-DPmA-eyr.js";import"./vendor-socket-io-component-emitter-Dkula2eQ.js";import"./vendor-socket-io-parser-SgV_gTLD.js";import"./vendor-validator-CzLPc2u2.js";import"./vendor-vueuse-core-C1QNX1u6.js";import"./vendor-vueuse-shared-DO1b_29_.js";import"./vendor-vuelidate-validators-H9iLFjxf.js";import"./vendor-vuelidate-core-Bd16nddI.js";import"./vendor-neoconfetti-vue-CCbt6K7L.js";import"./vendor-vue-draggable-resizable-X1h3rUy6.js";import"./vendor-vuetify-DDTyW1fq.js";import"./vendor-libphonenumber-js-CDO7CG9b.js";import"./information-Qn8HXtbY.js";import"./exclamation-Drsgy8Ui.js";const z={name:"background-info-view",components:{FormSearchableSelect:B,Callout:L,LargeButton:T,MazPhoneNumberInput:R},data(){return{options:{occupations:A},showInputErrors:!1,formError:"",occupation:[],linkedInUrl:"",wasSubmitted:!1,country:"",state:"",city:"",college:"",company:"",signupSourceId:"",signupSourcesOptions:[],otherSignupSource:"",isLoadingSignupSources:!1,invalidInputs:[],phoneInputInfo:{},phoneNumber:"",showRemovedFromNTHSMessage:!1}}
1,async beforeMount(){await this.getSignupSources()},computed:{...V({user:u=>u.user.user}),...C({isStudentVolunteer:"user/isStudentVolunteer"}),hasCompletedBackgroundInfo(){return Object.hasOwn(this.user,"occupation")&&this.user.occupation.length>0&&Object.hasOwn(this.user,"country")&&this.user.country.length>0},countries(){return P},states(){return q},isUnitedStatesSelected(){return this.country==="United States of America"},linkedInUrlPattern(){return/https?:\/\/(www\.)?linkedin\.com.*\/in\/.{1,}$/},isValidLinkedInUrl(){return this.linkedInUrl?this.linkedInUrlPattern.test(this.linkedInUrl):!0},isCollegeEducated(){return this.occupation.includes("An undergraduate student")||this.occupation.includes("A graduate student")},isWorkingFullTime(){return this.occupation.includes("Working full-time")&&!this.user.volunteerPartnerOrg},shouldShowOtherSignupInput(){if(this.isLoadingSignupSources||!this.signupSourcesOptions)return!1;const u=this.signupSourcesOptions.find(e=>e.name==="Other");return u&&u.id===this.signupSourceId},signedUpWithGoogle(){return!M(this.user.issuers)}},methods:{goToDashboard(){this.$router.push("/dashboard")},onPhoneInputUpdate(u){this.phoneInputInfo=u},async getSignupSources(){this.isLoadingSignupSources=!0;try{let e=(await x.backOff(()=>k.getStudentSignupSources())).data.signupSources;e=e.filter(p=>p.name!=="School / Teacher").map(p=>(p.name==="Friend / Classmate"&&(p.name="Friend"),p)),this.signupSourcesOptions=e}catch(u){v.noticeError(u)}finally{this.isLoadingSignupSources=!1}},async submitForm(u){if(u.preventDefault(),this.showInputErrors=!1,this.formError="",this.wasSubmitted)return;if(this.invalidForm()){this.showInputErrors=!0,this.formError="Please answer the required fields above.";return}this.wasSubmitted=!0;const e={occupation:this.occupation,linkedInUrl:this.linkedInUrl,country:this.country,state:this.isUnitedStatesSelected?this.state:"",city:this.city,college:this.college,company:this.company,phoneNumber:this.phoneNumber,signupSourceId:this.signupSourceId,otherSignupSource:this.otherSignupSource};try{(await k.addBackgroundInfo(e)).data?.wasRemovedFromNTHS&&(this.showRemovedFromNTHSMessage=!0,await this.$store.commit("nths/setNTHSGroups",[])),b.captureEvent(d.BACKGROUND_INFORMATION_COMPLETED,{event:d.BACKGROUND_INFORMATION_COMPLETED}),this.isStudentVolunteer&&b.captureEvent(d.ROLE_SWITCHING_USER_COMPLETED_BACKGROUND_INFO_FORM),this.user.volunteerPartnerOrg&&b.captureEvent(d.ACCOUNT_APPROVED,{event:d.ACCOUNT_APPROVED});const y={occupation:e.occupation,country:e.country};await this.$store.dispatch("user/addToUser",y)}catch(p){v.noticeError(p),b.captureEvent(d.BACKGROUND_INFORMATION_ERROR,{error:p?.message}),this.formError="Sorry, we had some trouble saving your information.",this.wasSubmitted=!1}},invalidForm(){return this.occupation.length===0||this.signedUpWithGoogle&&!this.phoneNumber||!this.country||!this.city||this.isUnitedStatesSelected&&!this.state||!this.isValidLinkedInUrl||this.isCollegeEducated&&!this.college||this.isWorkingFullTime&&!this.company}}},K={class:"background-info"},Y={class:"background-info__wrapper"},j={key:0,class:"complete"},J={key:0,class:"uc-form-col"},Q={key:0,class:"uc-column"},X={class:"uc-form-col"},Z={key:2,class:"error"},$={class:"uc-form-col"},ee={key:0,class:"error"},te=["value","id","data-testid"],oe=["for"],re={class:"uc-form-col"},ne=["pattern"],ie={key:0,class:"error"},se={key:1,class:"uc-form-col"},ue={key:0,class:"error form-error"},le=["disabled"];function ae(u,e,p,y,o,i){const U=g("Callout"),E=g("LargeButton"),O=g("FormSelect"),S=g("FormSearchableSelect"),N=g("maz-phone-number-input");return n(),s("div",K,[t("div",Y,[e[30]||(e[30]=t("h1",{class:"background-info__header","data-testid":"background-information-header"}," Background Information ",-1)),i.hasCompletedBackgroundInfo?(n(),s("div",j,[e[13]||(e[13]=t("p",{"data-testid":"bg-info-complete"},[a(" Thank you for submitting your background information!"),t("br")],-1)),o.showRemovedFromNTHSMessage?(n(),G(U,{key:0,variant:"information"},{content:w(()=>[...e[11]||(e[11]=[a(" Your responses in this form indicate that you are not currently a high school student. Don't worry— you can still volunteer! However, we have removed you from your National Tutoring Honors Society chapter since that program is for current high school students only. ",-1)])]),_:1})):l("",!0),f(E,{variant:"primary",class:"continue-onboarding-btn",showArrow:!1,onClick:i.goToDashboard},{default:w(()=>[...e[12]||(e[12]=[a("Continue Onboarding",-1)])]),_:1},8,["onClick"])])):(n(),s("form",{key:1,class:"background-info__form",onSubmit:e[10]||(e[10]=(...r)=>i.submitForm&&i.submitForm(...r)),autocomplete:"off"},[e[29]||(e[29]=t("p",{"data-testid":"background-information-explainer"}," Please provide some basic background information so that we can learn more about you! Don't worry: this information will be kept private unless we receive your permission to share it. ",-1)),t("ol",null,[i.signedUpWithGoogle?(n(),s("li",J,[e[15]||(e[15]=t("p",null,"How did you hear about us?",-1)),e[16]||(e[16]=t("p",{class:"background-info__question-description"},"(optional)",-1)),f(O,{"data-testid":"signupSourceField",name:"signup-source",modelValue:o.signupSourceId,"onUpdate:modelValue":e[0]||(e[0]=r=>o.signupSourceId=r),options:o.signupSourcesOptions,"option-text-field":"name","
1is-required":!1,reduce:r=>r.id},null,8,["modelValue","options","reduce"]),i.shouldShowOtherSignupInput?(n(),s("div",Q,[c(t("input",{id:"otherSignupSource","data-testid":"otherSignupSource",required:!1,type:"text",class:H(["uc-form-input",{"uc-form-input--invalid":o.invalidInputs.indexOf("otherSignupSource")>-1}]),"onUpdate:modelValue":e[1]||(e[1]=r=>o.otherSignupSource=r),autofocus:"",autocomplete:"off"},null,2),[[m,o.otherSignupSource]]),e[14]||(e[14]=t("p",{class:"uc-form-subtext"},"Tell us where you heard about us!",-1))])):l("",!0)])):l("",!0),t("li",X,[e[19]||(e[19]=t("p",{"data-testid":"question-where-do-you-live"},[a(" Where do you currently live?"),t("span",{class:"background-info__question-required"},"*")],-1)),e[20]||(e[20]=t("label",{class:"uc-form-label location-label"},[a("Country"),t("span",{class:"background-info__question-required"},"*")],-1)),f(S,{name:"country-select",class:"location-input",modelValue:o.country,"onUpdate:modelValue":e[2]||(e[2]=r=>o.country=r),options:i.countries,"data-testid":"location-input"},null,8,["modelValue","options"]),i.isUnitedStatesSelected?(n(),s(h,{key:0},[e[17]||(e[17]=t("label",{class:"uc-form-label location-label"},[a("State"),t("span",{class:"background-info__question-required"},"*")],-1)),f(S,{class:"location-input",name:"state-select",id:"state",modelValue:o.state,"onUpdate:modelValue":e[3]||(e[3]=r=>o.state=r),options:i.states,searchable:!0,"data-testid":"state-select"},null,8,["modelValue","options"])],64)):l("",!0),o.country?(n(),s(h,{key:1},[e[18]||(e[18]=t("label",{class:"uc-form-label location-label",for:"city"},[a("City"),t("span",{class:"background-info__question-required"},"*")],-1)),c(t("input",{type:"text","onUpdate:modelValue":e[4]||(e[4]=r=>o.city=r),placeholder:"Enter a city...",class:"uc-form-input location-input",id:"city","data-testid":"city-input",autocomplete:"off"},null,512),[[m,o.city]])],64)):l("",!0),o.showInputErrors?(n(),s("p",Z," Please fill out these fields. ")):l("",!0)]),t("li",$,[e[23]||(e[23]=t("p",{"data-testid":"question-i-am-currently"},[a(" I am currently..."),t("span",{class:"background-info__question-required"},"*")],-1)),e[24]||(e[24]=t("p",{class:"background-info__question-description"}," Select all that apply. ",-1)),o.showInputErrors&&o.occupation.length===0?(n(),s("p",ee," Please fill out this field. ")):l("",!0),(n(!0),s(h,null,W(o.options.occupations,r=>(n(),s("div",{class:"uc-form-checkbox",key:r},[c(t("input",{type:"checkbox",value:r,"onUpdate:modelValue":e[5]||(e[5]=_=>o.occupation=_),id:r,"data-testid":r},null,8,te),[[D,o.occupation]]),t("label",{class:"uc-form-label",for:r},I(r),9,oe)]))),128)),i.isCollegeEducated?(n(),s(h,{key:1},[e[21]||(e[21]=t("label",{class:"uc-form-label occupations-label",for:"college"},[a("What college/university do you currently attend?"),t("span",{class:"background-info__question-required"},"*")],-1)),c(t("input",{type:"text","onUpdate:modelValue":e[6]||(e[6]=r=>o.college=r),placeholder:"Enter a college...",class:"uc-form-input occupations-input",id:"college",autocomplete:"off"},null,512),[[m,o.college]])],64)):l("",!0),i.isWorkingFullTime?(n(),s(h,{key:2},[e[22]||(e[22]=t("label",{class:"uc-form-label occupations-label",for:"company"},[a("What company do you currently work at?"),t("span",{class:"background-info__question-required"},"*")],-1)),c(t("input",{type:"text","onUpdate:modelValue":e[7]||(e[7]=r=>o.company=r),placeholder:"Enter your company...",class:"uc-form-input occupations-input",id:"company",autocomplete:"off"},null,512),[[m,o.company]])],64)):l("",!0)]),t("li",re,[e[25]||(e[25]=t("p",{"data-testid":"question-linkedin-profile"}," If you have one, please provide us with a link to your LinkedIn profile. ",-1)),e[26]||(e[26]=t("p",{class:"background-info__question-description"},"(optional)",-1)),c(t("input",{type:"text",pattern:i.linkedInUrlPattern.source,"onUpdate:modelValue":e[8]||(e[8]=r=>o.linkedInUrl=r),placeholder:"https://www.linkedin.com/in/yourname",class:"linkedin-input uc-form-input",id:"linkedin","data-testid":"linked-in-input",autocomplete:"off"},null,8,ne),[[m,o.linkedInUrl]]),i.isValidLinkedInUrl?l("",!0):(n(),s("p",ie," Your url should be in this format: https://www.linkedin.com/in/yourname "))]),i.signedUpWithGoogle?(n(),s("li",se,[e[27]||(e[27]=t("label",{for:"phoneNumber",class:"uc-form-label"},[a("Cell Phone Number"),t("span",{class:"background-info__question-required"},"*")],-1)),f(N,{id:"phoneNumber","data-testid":"phoneNumberField",class:"phone-input",required:"true","show-code-on-list":"",onUpdate:i.onPhoneInputUpdate,modelValue:o.phoneNumber,"onUpdate:modelValue":e[9]||(e[9]=r=>o.phoneNumber=r)},null,8,["onUpdate","modelValue"]),e[28]||(e[28]=t("p",{class:"uc-form-subtext"}," UPchieve notifies volunteers of incoming student requests via text. You can customize when you receive requests. ",-1))])):l("",!0)]),o.formError?(n(),s("p",ue,I(o.formError),1)):l("",!0),t("button",{class:"uc-form-button submit-btn",type:"submit",disabled:i.invalidForm()?!0:null,"data-testid":"submit-bg-info"}," Submit ",8,le)],32))])])}const ot=F(z,[["render",ae],["__scopeId","data-v-5123c267"]]);export{ot as default};

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.