1import x from"./B_N8k-7s.js";import y from"./fm8Zky-k.js";import{_ as v}from"./DcmYWu72.js";import{X as k,d as a,h as c,e,p as n,g as w,a1 as g,F as b,m as I,c as p,i as h,q as m,ae as B,b0 as C,b2 as q,a4 as P}from"./Dyf_xAow.js";const U={key:0},F={class:"flex flex-col gap-y-4"},H={class:"media aspect-wide bg-light-grey shadow"},z={key:1,class:"flex items-center justify-center w-full text-dark-grey-80 p-2 aspect-wide"},L={class:"flex flex-col gap-y-1"},M={key:0,class:"flex flex-wrap gap-2 mb-2"},Z=["aria-label","title"],_={key:1,class:"text-lg text-black"},E={key:2,class:"text-sm text-dark-grey-80"},S={key:0},$=["href"],j=["href"],N=["href"],Q=["innerHTML"],R=k({__name:"ContactItem",props:{contact:{},showFlag:{type:Boolean,default:!1},showInformation:{type:Boolean,default:!1}},setup(t){const s=t,l=p(()=>(s.contact.userCountries??"").split(",").map(o=>o.toLowerCase()).filter(o=>o));return(o,i)=>{var f;const u=x,r=y;return t.contact?(e(),a("article",U,[n("div",F,[n("div",H,[t.contact.userImage?(e(),w(u,{key:0,src:("_getResizeImageUrl"in o?o._getResizeImageUrl:g(v))(t.contact.userImage,{resize:"fill",width:525,height:400,gravity:"ce"}),pt:{root:"items-center justify-center aspect-wide",image:"h-full"},alt:t.contact.name},null,8,["src","alt"])):(e(),a("div",z,[...i[0]||(i[0]=[n("svg",{xmlns:"http://www.w3.org/2000/svg",height:"40px",viewBox:"0 -960 960 960",width:"40px",fill:"currentColor"},[n("path",{d:"M479.67-264.67q73.33 0 123.5-50.16 50.16-50.17 50.16-123.5 0-73.34-50.16-123.17-50.17-49.83-123.5-49.83-73.34 0-123.17 49.83t-49.83 123.17q0 73.33 49.83 123.5 49.83 50.16 123.17 50.16Zm0-66.66q-45.67 0-76-30.67-30.34-30.67-30.34-76.33 0-45.67 30.34-76 30.33-30.34 76-30.34 45.66 0 76.33 30.34 30.67 30.33 30.67 76 0 45.66-30.67 76.33t-76.33 30.67ZM146.67-120q-27 0-46.84-19.83Q80-159.67 80-186.67v-502q0-26.33 19.83-46.5 19.84-20.16 46.84-20.16h140L360-840h240l73.33 84.67h140q26.34 0 46.5 20.16Q880-715 880-688.67v502q0 27-20.17 46.84Q839.67-120 813.33-120H146.67Zm0-66.67h666.66v-502H642.67l-73-84.66H390.33l-73 84.66H146.67v502ZM480-438Z"})],-1)])]))]),n("div",L,[t.showFlag&&t.contact.userCountries&&((f=t.contact.userCountries)==null?void 0:f.length)>0?(e(),a("div",M,[(e(!0),a(b,null,I(g(l),d=>(e(),a("div",{key:d,"aria-label":d,title:d},[h(r,{name:`flagpack:${d}`,class:"size-6"},null,8,["name"])],8,Z))),128))])):c("",!0),t.contact.name?(e(),a("p",_,m(t.contact.name),1)):c("",!0),t.contact.title?(e(),a("p",E,m(t.contact.title),1)):c("",!0)]),t.contact.privatePhone||t.contact.mobilePhone||t.contact.email?(e(),a("div",S,[t.contact.privatePhone?(e(),a("a",{key:0,href:`tel:${t.contact.phone}`,class:"inline-flex text-sm gap-2 w-full hover:text-black-true underline decoration-transparent hover:decoration-black underline-offset-[3px] transition-colors"},[n("span",null,[h(r,{name:"mdi:phone-outline"})]),n("span",null,m(t.contact.privatePhone),1)],8,$)):c("",!0),t.contact.mobilePhone?(e(),a("a",{key:1,href:`tel:${t.contact.mobilePhone}`,class:"inline-flex text-sm gap-2 w-full hover:text-black-true underline decoration-transparent hover:decoration-black underline-offset-[3px] transition-colors"},[n("span",null,[h(r,{name:"mdi:cellphone"})]),n("span",null,m(t.contact.mobilePhone),1)],8,j)):c("",!0),t.contact.email?(e(),a("a",{key:2,href:`mailto:${t.contact.email}`,class:"inline-flex text-sm gap-2 w-full hover:text-black-true underline decoration-transparent hover:decoration-black underline-offset-[3px] transition-colors"},[n("span",null,[h(r,{name:"mdi:email-outline"})]),n("span",null,m(t.contact.email),1)],8,N)):c("",!0)])):c("",!0),t.showInformation&&t.contact.userInformation?(e(),a("div",{key:1,innerHTML:t.contact.userInformation,class:"user-information"},null,8,Q)):c("",!0)])])):c("",!0)}}}),O=B(R,[["__scopeId","data-v-9518354b"]]),X=C("contactsStore",{state:()=>({_loading:!1,contacts:[]}),actions:{async getUsersByInitials(t){try{const l=q();this._loading=!0;let o={areaInfo:P(),initials:t},i=await l.getTefcoldUsersByInitials(o);if(i!=null&&i.tefcoldUsers){var s=Object.values(i.tefcoldUsers);s.forEach(u=>{this.contacts.find(r=>r.email===u.email)===void 0&&this.contacts.push(u)})}}catch{this.contacts=[]}finally{this._loading=!1}},contactsByIntials(t){return!t||!this.contacts?[]:t==null?void 0:t.map(s=>{var l;return(l=this.contacts)==null?void 0:l.find(o=>this.getInitialsFromEmail(o.email)===s)}).filter(s=>s)},getInitialsFromEmail(t){return t.split("@")[0]}}});
1export{O as _,X as u};
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.