import f from"./WebProfiles-CR8ny-CA.mjs";import{_ as h,o as r,c as n,a,d as p,F as _,x as g,p as u,l as c,t as A,b,s as x,q as D,y as $,r as C,b8 as k}from"./DMx7NOIV.js";import B from"./WebHTML-DrEtfn0i.mjs";import"./WebImage-Ci5dwqsM.mjs";import"./nuxt-link-BppoxXIT.mjs";import"./index-iW2jWPF-.mjs";import"./WebContentListNew-DQC0ukJ9.mjs";import"./WebContentItem-CEOn8ipf.mjs";import"./useImageUrl-1XbeiwSF.mjs";import"./WebSubscribeNew-BgH0980w.mjs";const T={props:{items:{type:Array},ids:{type:Array},topDividerColor:{type:String,default:"#000"},bottomDivider:{type:Boolean,default:!1},bottomDividerColor:{type:String,default:"#000"}},computed:{sortedAuthors(){const t=[];return this.ids.forEach(e=>{const o=this.items.find(d=>d.id===e);typeof o<"u"&&t.push(o)}),t}}},w={class:"about-author-new"};function S(t,e,o,d,l,i){const m=f;return r(),n("div",w,[e[0]||(e[0]=a("h2",{class:"heading"}," About the Author ",-1)),p(m,{profiles:i.sortedAuthors},null,8,["profiles"])])}const N=h(T,[["render",S],["__scopeId","data-v-930241e2"]]),W={props:{items:{type:Array},ids:{type:Array},topDividerColor:{type:String,default:"#000"},bottomDivider:{type:Boolean,default:!1},bottomDividerColor:{type:String,default:"#000"}},computed:{dividers(){return{borderTopStyle:"solid",borderTopColor:this.topDividerColor,borderTopWidth:"2px",paddingTop:"10px",borderBottomStyle:this.bottomDivider?"solid":"none",borderBottomColor:this.bottomDivider?this.bottomDividerColor:"transparent",borderBottomWidth:this.bottomDivider?"2px":"0px",paddingBottom:this.bottomDivider?"10px":"0px"}},nameTitle(){let t=this.name;return t+=this.title?` | ${this.title}`:"",t},rounded(){var t,e,o;return(t=this.$ss)!=null&&t.useNewDesign?!1:((o=(e=this.$ss)==null?void 0:e.baseStyles)==null?void 0:o.siteTheme)===2},sortedAuthors(){const t=[];return this.ids.forEach(e=>{const o=this.items.find(d=>d.id===e);typeof o<"u"&&t.push(o)}),t}},methods:{getNameTitle(t){let e=t.name;return e+=t.title?` | ${t.title}`:"",e}}},E={class:$(["ebm-about-author","wide"])},F={key:0,class:"author-image"},I={class:"author-content"},L={key:0,class:"author-bio"};function V(t,e,o,d,l,i){const m=C,y=B,v=k;return r(),n("div",E,[(r(!0),n(_,null,g(i.sortedAuthors,s=>(r(),n("div",{key:s.id,class:"author-item",style:u(i.dividers)},[s.primaryImage?(r(),n("div",F,[p(m,{src:s.primaryImage.src.split("?")[0]+"?w=150",style:u({borderRadius:i.rounded?"8px":"0",boxShadow:i.rounded?"1px 1px 3px rgba(0,0,0,.5)":"none",width:"100%"})},null,8,["src","style"])])):c("",!0),a("div",I,[e[1]||(e[1]=a("div",{class:"heading"}," About the Author ",-1)),a("h3",{class:"author-name-title",style:u({fontFamily:t.$ss.primaryFontFamily})},A(i.getNameTitle(s)),5),s.body?(r(),n("div",L,[p(y,{html:s.body},null,8,["html"])])):c("",!0),s.publicEmail?(r(),b(v,{key:1,type:"link",mode:"hollow",link:`mailto:${s.publicEmail}`,class:"author-email"},{default:x(()=>e[0]||(e[0]=[D(" Email ")])),_:2},1032,["link"])):c("",!0)])],4))),128))])}const q=h(W,[["render",V],["__scopeId","data-v-d0888b06"]]),Q={__name:"AboutAuthorBlock",props:{data:{type:Object,required:!0,validator(t){return["ids","items"].every(e=>e in t)}},settings:{type:Object,required:!0}},setup(t){return(e,o)=>{var i;const d=N,l=q;return(i=e.$ss)!=null&&i.useNewDesign?(r(),b(d,{key:0,ids:t.data.ids,items:t.data.items,"display-all-authors":t.settings.displayAllAuthors,"top-divider-color":t.settings.topDividerColor,"bottom-divider":t.settings.bottomDivider,"bottom-divider-color":t.settings.bottomDividerColor},null,8,["ids","items","display-all-authors","top-divider-color","bottom-divider","bottom-divider-color"])):(r(),b(l,{key:1,ids:t.data.ids,items:t.data.items,"display-all-authors":t.settings.displayAllAuthors,"top-divider-color":t.settings.topDividerColor,"bottom-divider":t.settings.bottomDivider,"bottom-divider-color":t.settings.bottomDividerColor},null,8,["ids","items","display-all-authors","top-divider-color","bottom-divider","bottom-divider-color"]))}}};export{Q as default};