1import _ from"./LupusImage.c9e0cd38.js";import v from"./LupusGalleryPhotoswipe.2d9988f8.js";import{o as n,c as i,a as l,_ as y,r as w,U as c,a4 as h,i as o,F as b,e as f,t as d}from"./entry.d7b89367.js";import"./LupusPictureElement.4e15352b.js";const $={viewBox:"0 0 24 24",width:"1.2em",height:"1.2em"},x=l("path",{fill:"currentColor",d:"M4 6H2v14a2 2 0 0 0 2 2h14v-2H4V6m16-4H8a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V4a2 2 0 0 0-2-2m-8 12.5v-9l6 4.5l-6 4.5Z"},null,-1),P=[x];function S(e,t){return n(),i("svg",$,[...P])}const U={name:"mdi-PlayBoxMultiple",render:S};const k={name:"pg-gallery",components:{IconPlayBoxMultiple:U},inheritAttrs:!1,props:{sources:{type:Array,required:!0},labels:{type:Object,default:()=>({})},hashNavigation:{type:Boolean,default:!1},galleryName:{type:String,default:""}},computed:{mainImage(){return this.sources[0]},previewImages(){return this.sources.filter((e,t)=>t>=1&&t<=3)},srcset(){return`${this.sources[0].url} 1200w, 2 ${this.sources[0].mediumUrl} 840w`},lightboxSources(){return this.sources.map(e=>({src:e.url,webPSrc:this.convertUrlToWebP(e.url),srcset:`${e.url} 1200w, ${e.mediumUrl} 840w`,webPSrcSet:this.convertUrlToWebP(`${e.url} 1200w, ${e.mediumUrl} 840w`),alt:e.alt,title:e.title,copyright:`<p>${e.copyright}</p>`,caption:e.caption,width:1200,height:675}))}},methods:{convertUrlToWebP(e){return e.replace(/(\.jpg|\.jpeg|\.png|\.gif)/gim,"$1.webp")}}},B=["data-id"],C={class:"title"},I={class:"gallery-preview"},N={type:"button",class:"open-button text-base-100"},L={class:"preview-rectangles"},M=["onClick"],A={class:"show-all-icon"},V={class:"count"},j={class:"show-all-text"};function H(e,t,r,T,W,s){const p=_,m=w("icon-play-box-multiple"),g=v;return n(),i("div",{"data-id":e.$options.name,class:"c-paragraph c-max-width-narrow"},[l("div",C,[c(e.$slots,"title")]),l("div",I,[l("div",{class:"preview-hero",onClick:t[0]||(t[0]=h(a=>e.$refs.gallery.loadLightbox(0),["prevent"])),onMouseover:t[1]||(t[1]=a=>e.$refs.gallery.loadLightbox())},[o(p,{src:s.mainImage.url,srcset:s.srcset,alt:s.mainImage.alt,"aspect-ratio":177.778},null,8,["src","srcset","alt"]),l("button",N,[c(e.$slots,"open-button"),o(m,{width:"3em",height:"3em","aria-label":"Open gallery"})])],32),l("div",L,[(n(!0),i(b,null,f(s.previewImages,(a,u)=>(n(),i("div",{key:"preview"+u,class:"preview-rectangle",onClick:h(F=>e.$refs.gallery.loadLightbox(u+1),["prevent"])},[o(p,{src:a.thumbnailUrl,alt:a.alt,"aspect-ratio":133.333},null,8,["src","alt"])],8,M))),128)),l("div",{class:"preview-rectangle show-all",onClick:t[2]||(t[2]=h(a=>e.$refs.gallery.loadLightbox(0),["prevent"]))},[l("div",A,[c(e.$slots,"show-all-icon"),l("div",V,d(r.sources.length),1)]),l("div",j,d(r.labels.showAll||e.$t("gallery.showAll")),1)])])]),o(g,{ref:"gallery","gallery-name":r.galleryName,"hash-navigation":r.hashNavigation,sources:s.lightboxSources},null,8,["gallery-name","hash-navigation","sources"])],8,B)}const E=y(k,[["render",H]]);export{E 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.