import{j as s,a,l}from"./vue.runtime.esm-esM0TXTr.chunk.mjs";import{N as i}from"./NcEmptyContent-iUjukkIR.chunk.mjs";import{I as r,n}from"./icons-DTUVT_9j.chunk.mjs";import{C as c,a as p}from"./CollectionsList-C7xoFkxL.chunk.mjs";import{H as m}from"./HeaderNavigation-woa2Kd8J.chunk.mjs";import{F as h}from"./FetchCollectionsMixin-Br9ggFUn.chunk.mjs";import{z as f}from"./index-VfyFTmuq.chunk.mjs";import"./createElementId-DhjFt1I9-B2HCdIOx.chunk.mjs";import"./video-KKp9iT8x.chunk.mjs";import"./index-CZ3uO_vZ.chunk.mjs";import"./preload-helper-DxYC2qmj.chunk.mjs";import"./collectionFetcher-DOI412ME.chunk.mjs";import"./AbortControllerMixin-B9m47d-C.chunk.mjs";const u={name:"PlacesView",components:{ImageMultipleOutline:r,NcEmptyContent:i,CollectionsList:p,CollectionCover:c,HeaderNavigation:m},filters:{coverUrl(t){return t===-1?"":l(`/apps/photos/api/v1/preview/${t}?x=512&y=512`)}},mixins:[h],computed:{places(){return this.$store.getters.places}},async beforeMount(){this.fetchPlaces()},methods:{fetchPlaces(){this.fetchCollections(f)},t:a,n:s}};var d=function(){var t=this,e=t._self._c;return e("div",[e("CollectionsList",{staticClass:"places-list",attrs:{collections:t.places,loading:t.loadingCollections,error:t.errorFetchingCollections},scopedSlots:t._u([{key:"default",fn:function({collection:o}){return e("CollectionCover",{key:o.basename,attrs:{"parent-route":"/places","collection-name":o.basename,"alt-img":t.t("photos","Cover photo for place {placeName}",{placeName:o.basename}),"cover-url":t._f("coverUrl")(o.attributes["last-photo"])}},[e("span",{staticClass:"place__name"},[t._v(" "+t._s(o.basename)+" ")]),e("div",{staticClass:"place__details",attrs:{slot:"subtitle"},slot:"subtitle"},[t._v(" "+t._s(t.n("photos","%n item","%n photos and videos",o.attributes.nbItems))+" ")])])}}])},[e("HeaderNavigation",{key:"navigation",attrs:{slot:"header",loading:t.loadingCollections,title:t.t("photos","Places"),"root-title":t.t("photos","Places")},on:{refresh:t.fetchPlaces},slot:"header"}),e("NcEmptyContent",{attrs:{slot:"empty-collections-list",name:t.t("photos","There is no place yet!")},slot:"empty-collections-list"},[e("ImageMultipleOutline",{attrs:{slot:"icon"},slot:"icon"})],1)],1)],1)},v=[],C=n(u,d,v,!1,null,"6fbdde2a");const F=C.exports;export{F as default};
//# sourceMappingURL=PlacesView-Bzr8DKtj.chunk.mjs.map
