1import F from"./CYlWAKHe.js";import I from"./iezB6qYw.js";import{f as $}from"./DtqqUhgo.js";import{r as P,j as p,c as n,o as s,f as b,d as N,e as a,q as y,ad as u,F as R,G as S}from"./FTaPbxLM.js";import"./CUQHcvjt.js";import"./D_WVsykS.js";import"./B9hwvYFO.js";import"./BzVpgML3.js";import"./8y_KnDCH.js";import"./DrazZ_kY.js";const T={key:0,class:"mb-4 text-sm font-light text-base-500 lg:mb-6"},V={class:"font-semibold"},j={key:1,class:"mb-4 text-sm font-light text-base-500 lg:mb-6"},O={__name:"SearchResults",props:{items:{type:Array,default:()=>[]},itemsPerPage:{type:Number,default:10},searchParam:{type:String,default:""}},setup(k){const r=k,o=P(r.itemsPerPage),l=P(1),D=p(()=>r.items.length>0),c=p(()=>r.items.length),v=p(()=>{const t=(l.value-1)*o.value,d=t+o.value;return r.items.slice(t,d)}),w=t=>{l.value=t,window.scrollTo(0,0)};return(t,d)=>{const x=F,B=I;return s(),n("div",null,[a(D)?(s(),n("p",T,[y("span",V,u(a(c)+" "),1),y("span",null,u(t.$t("searchResults")),1)])):(s(),n("p",j,u(t.$t("noResultsFound")),1)),(s(!0),n(R,null,S(a(v),e=>{var g,i,f,m,h,_;return s(),b(x,{key:e.id,class:"mb-4 w-full rounded-3xl bg-white",title:((g=e==null?void 0:e.properties)==null?void 0:g.title)||(e==null?void 0:e.name),description:(i=e==null?void 0:e.properties)==null?void 0:i.description,link:(f=e==null?void 0:e.route)==null?void 0:f.path,"has-facet":e.contentType!=="newsPage",transparent:!0,categories:(h=(m=e==null?void 0:e.properties)==null?void 0:m.tag)==null?void 0:h.map(C=>C.name),date:("formatDate"in t?t.formatDate:a($))(((_=e==null?void 0:e.properties)==null?void 0:_.publicationDate)||(e==null?void 0:e.createDate))},null,8,["title","description","link","has-facet","categories","date"])}),128)),a(c)>a(o)?(s(),b(B,{key:2,class:"mt-36","total-items":a(c),"items-per-page":a(o),"current-page":a(l),onPageChange:w},null,8,["total-items","items-per-page","current-page"])):N("",!0)])}}};export{O 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.