1"use strict";(self["webpackChunkportweb_frontend"]=self["webpackChunkportweb_frontend"]||[]).push([[792],{3792:function(e,t,a){a.r(t),a.d(t,{default:function(){return N}});var c=a(641),s=a(33),l=a(3751);const o={class:"row"},n=["innerHTML"],i={class:"col col-xl-4"},r={class:"card hide-print"},d={class:"card-header"},p={class:"card-body"},h={id:"form"},m={class:"form-group"},u={for:"email-subject"},b={class:"form-group"},f=["placeholder"],v={class:"form-group"},S=["placeholder"],C={class:"form-group"},k=["placeholder"];function g(e,t,a,g,L,w){const y=(0,c.g2)("multiselect"),j=(0,c.g2)("captcha");return(0,c.uX)(),(0,c.CE)("div",o,[(0,c.Lk)("div",{class:"col-xl-8",innerHTML:L.siteContent},null,8,n),(0,c.Lk)("div",i,[(0,c.Lk)("div",r,[(0,c.Lk)("div",d,[t[5]||(t[5]=(0,c.Lk)("i",{class:"fa fa-envelope"},null,-1)),(0,c.eW)(" "+(0,s.v_)(e.$t("contacts.question")),1)]),(0,c.Lk)("div",p,[(0,c.Lk)("form",h,[(0,c.Lk)("div",m,[(0,c.Lk)("label",u,(0,s.v_)(e.$t("contacts.subject")),1),(0,c.bF)(y,{modelValue:L.subject,"onUpdate:modelValue":t[0]||(t[0]=e=>L.subject=e),options:L.subjects,placeholder:e.$t("contacts.placeholder"),"select-label":e.$t("enterToSelect"),"deselect-label":e.$t("enterToDeselect"),"selected-label":e.$t("selectedLabel"),id:"email-subject"},null,8,["modelValue","options","placeholder","select-label","deselect-label","selected-label"])]),(0,c.Lk)("div",b,[(0,c.bo)((0,c.Lk)("input",{type:"text","onUpdate:modelValue":t[1]||(t[1]=e=>L.name=e),del:"name",class:"form-control",id:"exampleInputName1","aria-describedby":"nameHelp",placeholder:e.$t("contacts.name")},null,8,f),[[l.Jo,L.name]])]),(0,c.Lk)("div",v,[(0,c.bo)((0,c.Lk)("input",{type:"email","onUpdate:modelValue":t[2]||(t[2]=e=>L.email=e),class:"form-control",id:"exampleInputEmail1","aria-describedby":"emailHelp",placeholder:e.$t("contacts.email")},null,8,S),[[l.Jo,L.email]])]),(0,c.Lk)("div",C,[(0,c.bo)((0,c.Lk)("textarea",{class:"form-control","onUpdate:modelValue":t[3]||(t[3]=e=>L.emailContent=e),placeholder:e.$t("contacts.questionContent")},null,8,k),[[l.Jo,L.emailContent]])]),(0,c.Lk)("button",{type:"button",class:"btn btn-primary",onClick:t[4]||(t[4]=(...e)=>w.send&&w.send(...e))},(0,s.v_)(e.$t("contacts.send")),1)])])])]),(0,c.bF)(j,{ref:"captcha"},null,512)])}var L=a(8374),w=a(6017),y=a(5877);function j(e,t,a,s,l,o){return(0,c.uX)(),(0,c.CE)("div")}var A=a(101),$={data(){return{captchaScript:null,captchaSiteKey:window.appSettings.CaptchaSiteKey}},created(){const e=A.A.global.locale;this.captchaScript=document.createElement("script"),this.captchaScript.setAttribute("src","https://www.google.com/recaptcha/api.js?render="+this.captchaSiteKey+"&hl="+e),document.head.appendChild(this.captchaScript)},destroyed(){this.captchaScript&&this.captchaScript.parentNode&&this.captchaScript.parentNode.removeChild(this.captchaScript);const e=document.head.querySelector("script[src*='https://www.gstatic.com/recaptcha']");e&&e.parentNode.removeChild(e);const t=document.body.querySelector("div[class='grecaptcha-badge']")?.parentNode;t&&t.parentNode.removeChild(t)},methods:{async getCaptchaToken(e){return await window.grecaptcha.execute(this.captchaSiteKey,{action:e})}}},E=a(6262);const _=(0,E.A)($,[["render",j]]);var M=_,x={name:"Contacts",refs:{captcha:M},data(){return{subject:"",name:"",email:"",siteContent:"",emailContent:"",subjects:[]}},components:{Captcha:M,Multiselect:y.Ay},methods:{async send(){if(""===this.subject||""===this.name||""===this.email||""===this.emailContent)return void w.A.emit("FLASHMESSAGE",{message:this.$t("portMessage.fail"),error:!0});const e=await this.$refs.captcha.getCaptchaToken("ports_public_web_contact_form");await L.A.sendEmail(this.name,this.email,this.subject,this.emailContent,e).then((e=>{w.A.emit("FLASHMESSAGE",{message:this.$t("portMessage.success"),error:!1}),this.name="",this.email="",this.subject="",this.emailContent=""})).catch((e=>{const t=Object.values(e.response.data.messages).flat().join(" ");w.A.emit("FLASHMESSAGE",{message:t,error:!0})}))}},created(){this.siteContent=this.$tm("contacts.content").join(""),this.subjects=this.$tm("contacts.subjects")}};const H=(0,E.A)(x,[["render",g]]);var N=H}}]); 2//# sourceMappingURL=792.648880c3.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.