1import{_ as N}from"./BdMn5CsR.js";import D from"./NQvUE04U.js";import I from"./BTY52GvZ.js";import R from"./DrHGDyYc.js";import{d as B,o as K,N as O,C as Y,g as u,i as e,j as p,w as H,b as f,E as G,f as l,u as d,K as b,L as h,t as C,F as U,D as j,e as z,m as Q,k as c,l as k}from"./CvG0wzej.js";import{f as s}from"./CUzCvIsG.js";import{c as W}from"./BQZzJbKK.js";import{I as $}from"./DlKykd6e.js";import{u as J}from"./KQsXDnc0.js";import{v as X,e as Z}from"./CSSxz1HG.js";import"./0rkg3YHJ.js";import"./ws46tAyU.js";import"./a0KI0hBD.js";const ee={class:"coterie-slide-over-form"},te={class:"cotere-schedule-tour-container"},oe={class:"cotere-schedule-tour"},se={key:0,class:"cotere-schedule-tour-inner"},ie=["onKeydown"],re={class:"coterie-slide-over-form__title spacing spacing--is-pt-small spacing--is-pb-small"},ae={class:"spacing spacing--is-pb-medium"},ne={action:"submit",class:"coterie-slide-over-form__submitCTA coterie-slide-over-form__submit-button button button--is-primary button--is-solid-pulse button--is-solid-pulse-hover button--is-primary-hover"},le={key:1,class:"m-auto form-confirmation success-message"},ce=B({__name:"CoterieSlideOverForm",props:{isVisible:{type:Boolean,default:!1},communityId:{type:String,default:""},phoneNumber:{type:String,default:""},title:{type:String,default:""},submitCTAText:{type:String,default:""},successMessageTitle:{type:String,default:""},successMessageCopy:{type:String,default:""},isPhoneRequired:{type:Boolean,default:!1}},emits:["closeForm"],setup(r,{emit:F}){const S=J(),M=f(!1),g=f({}),a=f(!1),_=Z(),P=X(),T=F,y=r;K(()=>{g.value=W.getCurrentCommunity(P.fullPath)});const n=function(){T("closeForm"),a.value=!1},i=O({first_name:s.createFormField({label:"First Name",id:"first_name",validator:"required",placeholder:"First",errorMessage:"This field is required",componentProps:{required:!0}}),last_name:s.createFormField({label:"Last Name",id:"last_name",validator:"required",placeholder:"Last",errorMessage:"This field is required",componentProps:{required:!0}}),email:s.createFormField({label:"Email Address",id:"email",type:$.Email,validator:["email","required"],placeholder:"[email protected]",errorMessage:"Please enter a valid email",componentProps:{required:!0}}),phone:s.createFormField({label:"Phone Number",id:"phone_number",placeholder:"555.555.5555",errorMessage:y.isPhoneRequired?"This field is required":"",componentProps:{dataMask:"###.###.####",required:y.isPhoneRequired},validator:y.isPhoneRequired?["minLength","required"]:[],validationOptions:{minLength:10}})}),x=async()=>{if(s.validateFields(i,!0)){const o={formFields:i,formLocation:"bottom-bar",tags:s.getTags(_.public.PACKAGE_NAME.toLowerCase(),"slideOverForm"),recaptchaKey:_.public.recaptcha.v3SiteKey,community:{name:g?.value.name,number:g?.value.number}},m=await s.submitActiveCampaignForm(S,o);a.value=m,a.value&&(i.email.value="",i.first_name.value="",i.last_name.value="",i.phone.value="")}},V=v=>{let o=v.target.scrollingElement.scrollTop;M.value=o>0};return(v,o)=>{const m=N,q=D,w=I,A=R,E=G("onScroll");return Y((l(),u("div",null,[e("div",ee,[p(A,{overlay:!0,roundedCorners:!1,isVisible:r.isVisible,selectedView:"right",onOnClose:n},{default:H(()=>[e("div",te,[e("div",oe,[d(a)?k("",!0):(l(),u("div",se,[e("button",{type:"button",tabindex:"0",onClick:n,onKeydown:[b(h(n,["prevent"]),["space"]),b(h(n,["prevent"]),["enter"])]},[p(m,{icon:"close",iconColor:"light-lighter",iconSize:"large",extraClass:"close-icon spacing spacing--is-pt-small"})],40,ie),e("h3",re,C(r.title),1),e("form",{onSubmit:h(x,["prevent"])},[(l(!0),u(U,null,j(d(i),t=>(l(),z(q,Q({label:t.label,name:t.id,type:t.type,inputValue:t.value,"onUpdate:inputValue":L=>d(s).update(t,L),darkBackground:!0,placeholder:t.placeholder,errorMessage:t.isValid||!t.isDirty?"":t.errorMessage,dataMask:t.componentProps?.dataMask},{ref_for:!0},t.componentProps),null,16,["label","name","type","inputValue","onUpdate:inputValue","placeholder","errorMessage","dataMask"]))),256)),e("div",ae,[e("button",ne,C(r.submitCTAText),1),o[0]||(o[0]=e("p",{class:"form-help-text"},"FIELDS WITH * ARE REQUIRED",-1)),o[1]||(o[1]=e("p",{class:"privacy-copy spacing spacing--is-mt-medium"},[c(" If you are seeking employment, please visit "),e("a",{href:"https://atriacareers.com",class:"link privacy-copy"},"Atria Senior Living Careers")],-1)),o[2]||(o[2]=e("p",{class:"privacy-copy spacing spacing--is-mt-medium"},[c(" Your information is safe with us. For details, please see our "),e("a",{href:"/privacy-policy",class:"link privacy-copy"},"privacy policy"),c(". This site is protected by reCAPTCHA and the Google "),e("a",{href:"https://policies.google.com/privacy",class:"link privacy-copy"}," Privacy Policy "),c(" and "),e("a",{href:"https://policies.google.com/terms",class:"link privacy-copy"}," Terms of Service "),c(" apply. ")],-1))])],32)])),d(a)?(l(),u("div",le,[p(m,{onClick:n,icon:"close",iconColor:"light-lighter",iconSize:"large",class:"close-icon spacing spacing--is-pt-small"}),p(w,{thankYouTitle:r.successMessageTitle,thankYouCopy:r.successMessageCopy,darkMode:"true"},null,8,["thankYouTitle","thankYouCopy"])])):k("",!0)])])]),_:1},8,["isVisible"])])])),[[E,V]])}}}),Fe=Object.assign(ce,{__name:"CoterieSlideOverForm"});export{Fe 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.