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AAK,MAAS,GAAGnE,EAAIK,GAAG,KAAKL,EAAIK,GAAG,KAAKJ,EAAG,iBAAiB,CAACG,MAAM,CAAC,KAAO,yBAAyB,KAAOJ,EAAIkB,EAAE,SAAU,2BAA2BE,KAAK,0BAA0B,CAACnB,EAAG,sBAAsB,CAACG,MAAM,CAAC,KAAO,QAAQgB,KAAK,UAAU,IAAI,GAAGpB,EAAIK,GAAG,KAAML,EAAIwC,sBAAuBvC,EAAG,UAAU,CAAC+D,GAAG,CAAC,MAAQ,SAASE,GAAQlE,EAAIwC,uBAAwB,CAAK,IAAI,CAACvC,EAAG,KAAK,CAACE,YAAY,2BAA2B,CAACH,EAAIK,GAAG,WAAWL,EAAI6D,GAAG7D,EAAIkB,EAAE,SAAU,cAAc,YAAYlB,EAAIK,GAAG,KAAKJ,EAAG,YAAY,CAAC+D,GAAG,CAAC,KAAOhE,EAAIgD,uBAAuB,GAAGhD,EAAIqB,MAAM,EAC/hE,GACsB,IIUpB,EACA,KACA,WACA,MAI8B","sources":["webpack:///photos/src/mixins/AbortControllerMixin.js","webpack:///photos/src/mixins/FetchCollectionsMixin.js","webpack:///photos/src/components/Collection/CollectionCover.vue?vue&type=style&index=0&id=356d6ce0&prod&lang=scss&scoped=true","webpack:///photos/src/components/Collection/CollectionsList.vue?vue&type=style&index=0&id=ec45e78e&prod&lang=scss&scoped=true","webpack:///photos/src/views/Albums.vue?vue&type=style&index=0&id=4eebcf83&prod&lang=scss&scoped=true","webpack:///photos/src/components/Collection/CollectionCover.vue","webpack:///photos/src/components/Collection/CollectionCover.vue?vue&type=script&lang=js","webpack://photos/./src/components/Collection/CollectionCover.vue?688b","webpack://photos/./src/components/Collection/CollectionCover.vue?4a0b","webpack://photos/./src/components/Collection/CollectionCover.vue?e7e4","webpack://photos/./src/components/Collection/CollectionsList.vue?2493","webpack:///photos/src/components/Collection/CollectionsList.vue","webpack:///photos/src/components/Collection/CollectionsList.vue?vue&type=script&lang=js","webpack://photos/./src/components/Collection/CollectionsList.vue?8f52","webpack://photos/./src/components/Collection/CollectionsList.vue?a92d","webpack://photos/./src/views/Albums.vue?be55","webpack:///photos/src/views/Albums.vue","webpack:///photos/src/views/Albums.vue?vue&type=script&lang=js","webpack://photos/./src/views/Albums.vue?c657","webpack://photos/./src/views/Albums.vue?2029"],"sourcesContent":["/**\n * @copyright Copyright (c) 2022 Louis Chemineau <louis@chmn.me>\n *\n * @author Louis Chemineau <louis@chmn.me>\n *\n * @license AGPL-3.0-or-later\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\nexport default {\n\tname: 'AbortControllerMixin',\n\n\tdata() {\n\t\treturn {\n\t\t\tabortController: new AbortController(),\n\t\t}\n\t},\n\n\tbeforeDestroy() {\n\t\tthis.abortController.abort()\n\t},\n\n\tbeforeRouteLeave(from, to, next) {\n\t\tthis.abortController.abort()\n\t\tthis.abortController = new AbortController()\n\t\tnext()\n\t},\n}\n","/**\n * @copyright Copyright (c) 2022 Louis Chemineau <louis@chmn.me>\n *\n * @author Louis Chemineau <louis@chmn.me>\n *\n * @license AGPL-3.0-or-later\n *\n * This program is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Affero General Public License as\n * published by the Free Software Foundation, either version 3 of the\n * License, or (at your option) any later version.\n *\n * This program is distributed in the hope that it will be useful,\n * but WITHOUT ANY WARRANTY; without even the implied warranty of\n * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n * GNU Affero General Public License for more details.\n *\n * You should have received a copy of the GNU Affero General Public License\n * along with this program. If not, see <http://www.gnu.org/licenses/>.\n *\n */\n\nimport { mapActions } from 'vuex'\n\nimport AbortControllerMixin from './AbortControllerMixin.js'\nimport { fetchCollections } from '../services/collectionFetcher.js'\n\nexport default {\n\tname: 'FetchCollectionsMixin',\n\n\tdata() {\n\t\treturn {\n\t\t\terrorFetchingCollections: null,\n\t\t\tloadingCollections: false,\n\t\t}\n\t},\n\n\tmixins: [\n\t\tAbortControllerMixin,\n\t],\n\n\tmethods: {\n\t\t...mapActions([\n\t\t\t'addCollections',\n\t\t]),\n\n\t\t/**\n\t\t * @param {string} collectionHome\n\t\t * @param {string[]} [extraProps] - Extra properties to add to the DAV request.\n\t\t * @param {import('webdav').WebDAVClient} [client] - The DAV client to use.\n\t\t * @return {Promise<import('../services/collectionFetcher.js').Collection[]>}\n\t\t */\n\t\tasync fetchCollections(collectionHome, extraProps, client) {\n\t\t\tif (this.loadingCollections) {\n\t\t\t\treturn []\n\t\t\t}\n\n\t\t\ttry {\n\t\t\t\tthis.loadingCollections = true\n\t\t\t\tthis.errorFetchingCollections = null\n\n\t\t\t\tconst collections = await fetchCollections(collectionHome, { signal: this.abortController.signal }, extraProps, client)\n\n\t\t\t\tthis.addCollections({ collections })\n\n\t\t\t\treturn collections\n\t\t\t} catch (error) {\n\t\t\t\tif (error.response?.status === 404) {\n\t\t\t\t\tthis.errorFetchingCollections = 404\n\t\t\t\t} else {\n\t\t\t\t\tthis.errorFetchingCollections = error\n\t\t\t\t}\n\t\t\t} finally {\n\t\t\t\tthis.loadingCollections = false\n\t\t\t}\n\n\t\t\treturn []\n\t\t},\n\t},\n}\n","// Imports\nimport ___CSS_LOADER_API_SOURCEMAP_IMPORT___ from \"../../../node_modules/css-loader/dist/runtime/sourceMaps.js\";\nimport ___CSS_LOADER_API_IMPORT___ from \"../../../node_modules/css-loader/dist/runtime/api.js\";\nvar ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);\n// Module\n___CSS_LOADER_EXPORT___.push([module.id, \".collection-cover[data-v-356d6ce0]{display:flex;flex-direction:column;padding:16px;border-radius:var(--border-radius-large)}.collection-cover[data-v-356d6ce0]:hover,.collection-cover[data-v-356d6ce0]:focus{background:var(--color-background-dark)}.collection-cover__image[data-v-356d6ce0]{width:350px;height:350px;object-fit:cover;border-radius:var(--border-radius-large)}@media only screen and (max-width: 1200px){.collection-cover__image[data-v-356d6ce0]{width:250px;height:250px}}.collection-cover__image--placeholder[data-v-356d6ce0]{background:var(--color-primary-element-light)}.collection-cover__image--placeholder[data-v-356d6ce0] .material-design-icon{width:100%;height:100%}.collection-cover__image--placeholder[data-v-356d6ce0] .material-design-icon .material-design-icon__svg{fill:var(--color-primary-element)}.collection-cover__details[data-v-356d6ce0]{display:flex;flex-direction:column;margin-top:16px;width:350px}@media only screen and (max-width: 1200px){.collection-cover__details[data-v-356d6ce0]{width:250px}}.collection-cover__details__title[data-v-356d6ce0]{display:flex}.collection-cover__details__subtitle[data-v-356d6ce0]{display:flex;color:var(--color-text-lighter)}\", \"\",{\"version\":3,\"sources\":[\"webpack://./src/components/Collection/CollectionCover.vue\"],\"names\":[],\"mappings\":\"AAEA,mCACC,YAAA,CACA,qBAAA,CACA,YAAA,CACA,wCAAA,CAEA,kFACC,uCAAA,CAGD,0CACC,WAAA,CACA,YAAA,CACA,gBAAA,CACA,wCAAA,CAEA,2CAND,0CAOE,WAAA,CACA,YAAA,CAAA,CAGD,uDACC,6CAAA,CAEA,6EACC,UAAA,CACA,WAAA,CAEA,wGACC,iCAAA,CAMJ,4CACC,YAAA,CACA,qBAAA,CACA,eAAA,CACA,WAAA,CAEA,2CAND,4CAOE,WAAA,CAAA,CAGD,mDACC,YAAA,CAGD,sDACC,YAAA,CACA,+BAAA\",\"sourcesContent\":[\"$sizes: (\\\"400\\\": (\\\"count\\\": 3, \\\"marginTop\\\": 66, \\\"marginW\\\": 8), \\\"700\\\": (\\\"count\\\": 4, \\\"marginTop\\\": 66, \\\"marginW\\\": 8), \\\"1024\\\": (\\\"count\\\": 5, \\\"marginTop\\\": 66, \\\"marginW\\\": 44), \\\"1280\\\": (\\\"count\\\": 4, \\\"marginTop\\\": 66, \\\"marginW\\\": 44), \\\"1440\\\": (\\\"count\\\": 5, \\\"marginTop\\\": 88, \\\"marginW\\\": 66), \\\"1600\\\": (\\\"count\\\": 6, \\\"marginTop\\\": 88, \\\"marginW\\\": 66), \\\"2048\\\": (\\\"count\\\": 7, \\\"marginTop\\\": 88, \\\"marginW\\\": 66), \\\"2560\\\": (\\\"count\\\": 8, \\\"marginTop\\\": 88, \\\"marginW\\\": 88), \\\"3440\\\": (\\\"count\\\": 9, \\\"marginTop\\\": 88, \\\"marginW\\\": 88), \\\"max\\\": (\\\"count\\\": 10, \\\"marginTop\\\": 88, \\\"marginW\\\": 88));\\n\\n.collection-cover {\\n\\tdisplay: flex;\\n\\tflex-direction: column;\\n\\tpadding: 16px;\\n\\tborder-radius: var(--border-radius-large);\\n\\n\\t&:hover, &:focus {\\n\\t\\tbackground: var(--color-background-dark);\\n\\t}\\n\\n\\t&__image {\\n\\t\\twidth: 350px;\\n\\t\\theight: 350px;\\n\\t\\tobject-fit: cover;\\n\\t\\tborder-radius: var(--border-radius-large);\\n\\n\\t\\t@media only screen and (max-width: 1200px) {\\n\\t\\t\\twidth: 250px;\\n\\t\\t\\theight: 250px;\\n\\t\\t}\\n\\n\\t\\t&--placeholder {\\n\\t\\t\\tbackground: var(--color-primary-element-light);\\n\\n\\t\\t\\t:deep .material-design-icon {\\n\\t\\t\\t\\twidth: 100%;\\n\\t\\t\\t\\theight: 100%;\\n\\n\\t\\t\\t\\t.material-design-icon__svg {\\n\\t\\t\\t\\t\\tfill: var(--color-primary-element);\\n\\t\\t\\t\\t}\\n\\t\\t\\t}\\n\\t\\t}\\n\\t}\\n\\n\\t&__details {\\n\\t\\tdisplay: flex;\\n\\t\\tflex-direction: column;\\n\\t\\tmargin-top: 16px;\\n\\t\\twidth: 350px;\\n\\n\\t\\t@media only screen and (max-width: 1200px) {\\n\\t\\t\\twidth: 250px;\\n\\t\\t}\\n\\n\\t\\t&__title {\\n\\t\\t\\tdisplay: flex;\\n\\t\\t}\\n\\n\\t\\t&__subtitle {\\n\\t\\t\\tdisplay: flex;\\n\\t\\t\\tcolor: var(--color-text-lighter);\\n\\t\\t}\\n\\t}\\n\\n}\\n\"],\"sourceRoot\":\"\"}]);\n// Exports\nexport default ___CSS_LOADER_EXPORT___;\n","// Imports\nimport ___CSS_LOADER_API_SOURCEMAP_IMPORT___ from \"../../../node_modules/css-loader/dist/runtime/sourceMaps.js\";\nimport ___CSS_LOADER_API_IMPORT___ from \"../../../node_modules/css-loader/dist/runtime/api.js\";\nvar ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);\n// Module\n___CSS_LOADER_EXPORT___.push([module.id, \".collections[data-v-ec45e78e]{display:flex;flex-direction:column;height:100%}.collections__list[data-v-ec45e78e]{padding:32px 48px;flex-grow:1;display:flex;flex-wrap:wrap;gap:16px;align-items:flex-start;height:calc(100% - 60px);overflow-x:scroll}@media only screen and (max-width: 1200px){.collections__list[data-v-ec45e78e]{padding:32px 12px;justify-content:center}}\", \"\",{\"version\":3,\"sources\":[\"webpack://./src/components/Collection/CollectionsList.vue\"],\"names\":[],\"mappings\":\"AAEA,8BACC,YAAA,CACA,qBAAA,CACA,WAAA,CAEA,oCACC,iBAAA,CACA,WAAA,CACA,YAAA,CACA,cAAA,CACA,QAAA,CACA,sBAAA,CACA,wBAAA,CACA,iBAAA,CAEA,2CAVD,oCAWE,iBAAA,CACA,sBAAA,CAAA\",\"sourcesContent\":[\"$sizes: (\\\"400\\\": (\\\"count\\\": 3, \\\"marginTop\\\": 66, \\\"marginW\\\": 8), \\\"700\\\": (\\\"count\\\": 4, \\\"marginTop\\\": 66, \\\"marginW\\\": 8), \\\"1024\\\": (\\\"count\\\": 5, \\\"marginTop\\\": 66, \\\"marginW\\\": 44), \\\"1280\\\": (\\\"count\\\": 4, \\\"marginTop\\\": 66, \\\"marginW\\\": 44), \\\"1440\\\": (\\\"count\\\": 5, \\\"marginTop\\\": 88, \\\"marginW\\\": 66), \\\"1600\\\": (\\\"count\\\": 6, \\\"marginTop\\\": 88, \\\"marginW\\\": 66), \\\"2048\\\": (\\\"count\\\": 7, \\\"marginTop\\\": 88, \\\"marginW\\\": 66), \\\"2560\\\": (\\\"count\\\": 8, \\\"marginTop\\\": 88, \\\"marginW\\\": 88), \\\"3440\\\": (\\\"count\\\": 9, \\\"marginTop\\\": 88, \\\"marginW\\\": 88), \\\"max\\\": (\\\"count\\\": 10, \\\"marginTop\\\": 88, \\\"marginW\\\": 88));\\n\\n.collections {\\n\\tdisplay: flex;\\n\\tflex-direction: column;\\n\\theight: 100%;\\n\\n\\t&__list {\\n\\t\\tpadding: 32px 48px;\\n\\t\\tflex-grow: 1;\\n\\t\\tdisplay: flex;\\n\\t\\tflex-wrap: wrap;\\n\\t\\tgap: 16px;\\n\\t\\talign-items: flex-start;\\n\\t\\theight: calc(100% - 60px);\\n\\t\\toverflow-x: scroll;\\n\\n\\t\\t@media only screen and (max-width: 1200px) {\\n\\t\\t\\tpadding: 32px 12px;\\n\\t\\t\\tjustify-content: center;\\n\\t\\t}\\n\\t}\\n}\\n\"],\"sourceRoot\":\"\"}]);\n// Exports\nexport default ___CSS_LOADER_EXPORT___;\n","// Imports\nimport ___CSS_LOADER_API_SOURCEMAP_IMPORT___ from \"../../node_modules/css-loader/dist/runtime/sourceMaps.js\";\nimport ___CSS_LOADER_API_IMPORT___ from \"../../node_modules/css-loader/dist/runtime/api.js\";\nvar ___CSS_LOADER_EXPORT___ = ___CSS_LOADER_API_IMPORT___(___CSS_LOADER_API_SOURCEMAP_IMPORT___);\n// Module\n___CSS_LOADER_EXPORT___.push([module.id, \".albums-list[data-v-4eebcf83]{display:flex;flex-direction:column}.albums-list .album__name[data-v-4eebcf83]{font-weight:normal;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;font-size:20px;margin-bottom:12px;line-height:30px;color:var(--color-main-text)}.album-creation__heading[data-v-4eebcf83]{padding:calc(var(--default-grid-baseline)*4);margin-bottom:0px;padding-bottom:0px}\", \"\",{\"version\":3,\"sources\":[\"webpack://./src/views/Albums.vue\"],\"names\":[],\"mappings\":\"AAEA,8BACC,YAAA,CACA,qBAAA,CAEA,2CACC,kBAAA,CACA,eAAA,CACA,kBAAA,CACA,sBAAA,CACA,cAAA,CACA,kBAAA,CACA,gBAAA,CACA,4BAAA,CAIF,0CACC,4CAAA,CACA,iBAAA,CACA,kBAAA\",\"sourcesContent\":[\"$sizes: (\\\"400\\\": (\\\"count\\\": 3, \\\"marginTop\\\": 66, \\\"marginW\\\": 8), \\\"700\\\": (\\\"count\\\": 4, \\\"marginTop\\\": 66, \\\"marginW\\\": 8), \\\"1024\\\": (\\\"count\\\": 5, \\\"marginTop\\\": 66, \\\"marginW\\\": 44), \\\"1280\\\": (\\\"count\\\": 4, \\\"marginTop\\\": 66, \\\"marginW\\\": 44), \\\"1440\\\": (\\\"count\\\": 5, \\\"marginTop\\\": 88, \\\"marginW\\\": 66), \\\"1600\\\": (\\\"count\\\": 6, \\\"marginTop\\\": 88, \\\"marginW\\\": 66), \\\"2048\\\": (\\\"count\\\": 7, \\\"marginTop\\\": 88, \\\"marginW\\\": 66), \\\"2560\\\": (\\\"count\\\": 8, \\\"marginTop\\\": 88, \\\"marginW\\\": 88), \\\"3440\\\": (\\\"count\\\": 9, \\\"marginTop\\\": 88, \\\"marginW\\\": 88), \\\"max\\\": (\\\"count\\\": 10, \\\"marginTop\\\": 88, \\\"marginW\\\": 88));\\n\\n.albums-list {\\n\\tdisplay: flex;\\n\\tflex-direction: column;\\n\\n\\t.album__name {\\n\\t\\tfont-weight: normal;\\n\\t\\toverflow: hidden;\\n\\t\\twhite-space: nowrap;\\n\\t\\ttext-overflow: ellipsis;\\n\\t\\tfont-size: 20px;\\n\\t\\tmargin-bottom: 12px;\\n\\t\\tline-height: 30px;\\n\\t\\tcolor: var(--color-main-text);\\n\\t}\\n}\\n\\n.album-creation__heading {\\n\\tpadding: calc(var(--default-grid-baseline) * 4);\\n\\tmargin-bottom: 0px;\\n\\tpadding-bottom: 0px;\\n}\\n\"],\"sourceRoot\":\"\"}]);\n// Exports\nexport default ___CSS_LOADER_EXPORT___;\n","<!--\n - @copyright Copyright (c) 2022 Louis Chemineau <louis@chmn.me>\n -\n - @author Louis Chemineau <louis@chmn.me>\n -\n - @license AGPL-3.0-or-later\n -\n - This program is free software: you can redistribute it and/or modify\n - it under the terms of the GNU Affero General Public License as\n - published by the Free Software Foundation, either version 3 of the\n - License, or (at your option) any later version.\n -\n - This program is distributed in the hope that it will be useful,\n - but WITHOUT ANY WARRANTY; without even the implied warranty of\n - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n - GNU Affero General Public License for more details.\n -\n - You should have received a copy of the GNU Affero General Public License\n - along with this program. If not, see <http://www.gnu.org/licenses/>.\n -\n -->\n<template>\n\t<li>\n\t\t<router-link class=\"collection-cover\" :to=\"link\">\n\t\t\t<img v-if=\"coverUrl !== ''\"\n\t\t\t\tclass=\"collection-cover__image\"\n\t\t\t\t:src=\"coverUrl\"\n\t\t\t\t:alt=\"altImg\">\n\n\t\t\t<div v-else class=\"collection-cover__image collection-cover__image--placeholder\">\n\t\t\t\t<ImageMultiple :size=\"128\" />\n\t\t\t</div>\n\t\t\t<div class=\"collection-cover__details\">\n\t\t\t\t<div class=\"collection-cover__details__title\">\n\t\t\t\t\t<slot name=\"default\" />\n\t\t\t\t</div>\n\t\t\t\t<div class=\"collection-cover__details__subtitle\">\n\t\t\t\t\t<slot name=\"subtitle\" />\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t</router-link>\n\t</li>\n</template>\n<script>\nimport ImageMultiple from 'vue-material-design-icons/ImageMultiple.vue'\n\nexport default {\n\tname: 'CollectionCover',\n\n\tcomponents: {\n\t\tImageMultiple,\n\t},\n\n\tprops: {\n\t\tcoverUrl: {\n\t\t\ttype: String,\n\t\t\trequired: true,\n\t\t},\n\t\taltImg: {\n\t\t\ttype: String,\n\t\t\trequired: true,\n\t\t},\n\t\tlink: {\n\t\t\ttype: String,\n\t\t\trequired: true,\n\t\t},\n\t},\n}\n</script>\n<style lang=\"scss\" scoped>\n.collection-cover {\n\tdisplay: flex;\n\tflex-direction: column;\n\tpadding: 16px;\n\tborder-radius: var(--border-radius-large);\n\n\t&:hover, &:focus {\n\t\tbackground: var(--color-background-dark);\n\t}\n\n\t&__image {\n\t\twidth: 350px;\n\t\theight: 350px;\n\t\tobject-fit: cover;\n\t\tborder-radius: var(--border-radius-large);\n\n\t\t@media only screen and (max-width: 1200px) {\n\t\t\twidth: 250px;\n\t\t\theight: 250px;\n\t\t}\n\n\t\t&--placeholder {\n\t\t\tbackground: var(--color-primary-element-light);\n\n\t\t\t:deep .material-design-icon {\n\t\t\t\twidth: 100%;\n\t\t\t\theight: 100%;\n\n\t\t\t\t.material-design-icon__svg {\n\t\t\t\t\tfill: var(--color-primary-element);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\t&__details {\n\t\tdisplay: flex;\n\t\tflex-direction: column;\n\t\tmargin-top: 16px;\n\t\twidth: 350px;\n\n\t\t@media only screen and (max-width: 1200px) {\n\t\t\twidth: 250px;\n\t\t}\n\n\t\t&__title {\n\t\t\tdisplay: flex;\n\t\t}\n\n\t\t&__subtitle {\n\t\t\tdisplay: flex;\n\t\t\tcolor: var(--color-text-lighter);\n\t\t}\n\t}\n\n}\n</style>\n","import mod from \"-!../../../node_modules/babel-loader/lib/index.js!../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./CollectionCover.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../../../node_modules/babel-loader/lib/index.js!../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./CollectionCover.vue?vue&type=script&lang=js\"","\n import API from \"!../../../node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js\";\n import domAPI from \"!../../../node_modules/style-loader/dist/runtime/styleDomAPI.js\";\n import insertFn from \"!../../../node_modules/style-loader/dist/runtime/insertBySelector.js\";\n import setAttributes from \"!../../../node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js\";\n import insertStyleElement from \"!../../../node_modules/style-loader/dist/runtime/insertStyleElement.js\";\n import styleTagTransformFn from \"!../../../node_modules/style-loader/dist/runtime/styleTagTransform.js\";\n import content, * as namedExport from \"!!../../../node_modules/css-loader/dist/cjs.js!../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../node_modules/postcss-loader/dist/cjs.js!../../../node_modules/sass-loader/dist/cjs.js??clonedRuleSet-2.use[3]!../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./CollectionCover.vue?vue&type=style&index=0&id=356d6ce0&prod&lang=scss&scoped=true\";\n \n \n\nvar options = {};\n\noptions.styleTagTransform = styleTagTransformFn;\noptions.setAttributes = setAttributes;\n\n options.insert = insertFn.bind(null, \"head\");\n \noptions.domAPI = domAPI;\noptions.insertStyleElement = insertStyleElement;\n\nvar update = API(content, options);\n\n\n\nexport * from \"!!../../../node_modules/css-loader/dist/cjs.js!../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../node_modules/postcss-loader/dist/cjs.js!../../../node_modules/sass-loader/dist/cjs.js??clonedRuleSet-2.use[3]!../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./CollectionCover.vue?vue&type=style&index=0&id=356d6ce0&prod&lang=scss&scoped=true\";\n export default content && content.locals ? content.locals : undefined;\n","import { render, staticRenderFns } from \"./CollectionCover.vue?vue&type=template&id=356d6ce0&scoped=true\"\nimport script from \"./CollectionCover.vue?vue&type=script&lang=js\"\nexport * from \"./CollectionCover.vue?vue&type=script&lang=js\"\nimport style0 from \"./CollectionCover.vue?vue&type=style&index=0&id=356d6ce0&prod&lang=scss&scoped=true\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"356d6ce0\",\n null\n \n)\n\nexport default component.exports","var render = function render(){var _vm=this,_c=_vm._self._c;return _c('li',[_c('router-link',{staticClass:\"collection-cover\",attrs:{\"to\":_vm.link}},[(_vm.coverUrl !== '')?_c('img',{staticClass:\"collection-cover__image\",attrs:{\"src\":_vm.coverUrl,\"alt\":_vm.altImg}}):_c('div',{staticClass:\"collection-cover__image collection-cover__image--placeholder\"},[_c('ImageMultiple',{attrs:{\"size\":128}})],1),_vm._v(\" \"),_c('div',{staticClass:\"collection-cover__details\"},[_c('div',{staticClass:\"collection-cover__details__title\"},[_vm._t(\"default\")],2),_vm._v(\" \"),_c('div',{staticClass:\"collection-cover__details__subtitle\"},[_vm._t(\"subtitle\")],2)])])],1)\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","var render = function render(){var _vm=this,_c=_vm._self._c;return (_vm.error)?_c('NcEmptyContent',{attrs:{\"name\":_vm.t('photos', 'An error occurred')}},[_c('AlertCircle',{attrs:{\"slot\":\"icon\"},slot:\"icon\"})],1):_c('div',{staticClass:\"collections\"},[_vm._t(\"header\"),_vm._v(\" \"),(_vm.noCollection && !_vm.loading)?_vm._t(\"empty-collections-list\"):(!_vm.noCollection)?_c('ul',{staticClass:\"collections__list\"},[_vm._l((_vm.collections),function(collection){return _vm._t(\"default\",null,{\"collection\":collection})})],2):_vm._e()],2)\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","<!--\n - @copyright Copyright (c) 2022 Louis Chemineau <louis@chmn.me>\n -\n - @author Louis Chemineau <louis@chmn.me>\n -\n - @license AGPL-3.0-or-later\n -\n - This program is free software: you can redistribute it and/or modify\n - it under the terms of the GNU Affero General Public License as\n - published by the Free Software Foundation, either version 3 of the\n - License, or (at your option) any later version.\n -\n - This program is distributed in the hope that it will be useful,\n - but WITHOUT ANY WARRANTY; without even the implied warranty of\n - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n - GNU Affero General Public License for more details.\n -\n - You should have received a copy of the GNU Affero General Public License\n - along with this program. If not, see <http://www.gnu.org/licenses/>.\n -\n -->\n<template>\n\t<!-- Errors handlers-->\n\t<NcEmptyContent v-if=\"error\" :name=\"t('photos', 'An error occurred') \">\n\t\t<AlertCircle slot=\"icon\" />\n\t</NcEmptyContent>\n\n\t<div v-else class=\"collections\">\n\t\t<!-- Collection header -->\n\t\t<slot name=\"header\" />\n\n\t\t<!-- No collections -->\n\t\t<slot v-if=\"noCollection && !loading\" name=\"empty-collections-list\" class=\"collections__empty\" />\n\n\t\t<!-- List -->\n\t\t<ul v-else-if=\"!noCollection\" class=\"collections__list\">\n\t\t\t<slot v-for=\"collection in collections\"\n\t\t\t\t:collection=\"collection\"\n\t\t\t\tclass=\"collection\" />\n\t\t</ul>\n\t</div>\n</template>\n\n<script>\nimport AlertCircle from 'vue-material-design-icons/AlertCircle.vue'\n\nimport { NcEmptyContent } from '@nextcloud/vue'\nimport { translate } from '@nextcloud/l10n'\n\nexport default {\n\tname: 'CollectionsList',\n\n\tcomponents: {\n\t\tAlertCircle,\n\t\tNcEmptyContent,\n\t},\n\n\tprops: {\n\t\t/** @type {import('vue').PropType<import('../../services/collectionFetcher').IndexedCollections>} */\n\t\tcollections: {\n\t\t\ttype: Object,\n\t\t\trequired: true,\n\t\t},\n\t\tloading: {\n\t\t\ttype: Boolean,\n\t\t\tdefault: false,\n\t\t},\n\t\terror: {\n\t\t\ttype: Error,\n\t\t\tdefault: null,\n\t\t},\n\t},\n\n\tcomputed: {\n\t\t/**\n\t\t * @return {boolean} Whether the list of collections is empty or not.\n\t\t */\n\t\tnoCollection() {\n\t\t\treturn Object.keys(this.collections).length === 0\n\t\t},\n\t},\n\n\tmethods: {\n\t\tt: translate,\n\t},\n}\n</script>\n<style lang=\"scss\" scoped>\n.collections {\n\tdisplay: flex;\n\tflex-direction: column;\n\theight: 100%;\n\n\t&__list {\n\t\tpadding: 32px 48px;\n\t\tflex-grow: 1;\n\t\tdisplay: flex;\n\t\tflex-wrap: wrap;\n\t\tgap: 16px;\n\t\talign-items: flex-start;\n\t\theight: calc(100% - 60px);\n\t\toverflow-x: scroll;\n\n\t\t@media only screen and (max-width: 1200px) {\n\t\t\tpadding: 32px 12px;\n\t\t\tjustify-content: center;\n\t\t}\n\t}\n}\n</style>\n","import mod from \"-!../../../node_modules/babel-loader/lib/index.js!../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./CollectionsList.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../../../node_modules/babel-loader/lib/index.js!../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./CollectionsList.vue?vue&type=script&lang=js\"","\n import API from \"!../../../node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js\";\n import domAPI from \"!../../../node_modules/style-loader/dist/runtime/styleDomAPI.js\";\n import insertFn from \"!../../../node_modules/style-loader/dist/runtime/insertBySelector.js\";\n import setAttributes from \"!../../../node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js\";\n import insertStyleElement from \"!../../../node_modules/style-loader/dist/runtime/insertStyleElement.js\";\n import styleTagTransformFn from \"!../../../node_modules/style-loader/dist/runtime/styleTagTransform.js\";\n import content, * as namedExport from \"!!../../../node_modules/css-loader/dist/cjs.js!../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../node_modules/postcss-loader/dist/cjs.js!../../../node_modules/sass-loader/dist/cjs.js??clonedRuleSet-2.use[3]!../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./CollectionsList.vue?vue&type=style&index=0&id=ec45e78e&prod&lang=scss&scoped=true\";\n \n \n\nvar options = {};\n\noptions.styleTagTransform = styleTagTransformFn;\noptions.setAttributes = setAttributes;\n\n options.insert = insertFn.bind(null, \"head\");\n \noptions.domAPI = domAPI;\noptions.insertStyleElement = insertStyleElement;\n\nvar update = API(content, options);\n\n\n\nexport * from \"!!../../../node_modules/css-loader/dist/cjs.js!../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../node_modules/postcss-loader/dist/cjs.js!../../../node_modules/sass-loader/dist/cjs.js??clonedRuleSet-2.use[3]!../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./CollectionsList.vue?vue&type=style&index=0&id=ec45e78e&prod&lang=scss&scoped=true\";\n export default content && content.locals ? content.locals : undefined;\n","import { render, staticRenderFns } from \"./CollectionsList.vue?vue&type=template&id=ec45e78e&scoped=true\"\nimport script from \"./CollectionsList.vue?vue&type=script&lang=js\"\nexport * from \"./CollectionsList.vue?vue&type=script&lang=js\"\nimport style0 from \"./CollectionsList.vue?vue&type=style&index=0&id=ec45e78e&prod&lang=scss&scoped=true\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"ec45e78e\",\n null\n \n)\n\nexport default component.exports","var render = function render(){var _vm=this,_c=_vm._self._c;return _c('div',[_c('CollectionsList',{staticClass:\"albums-list\",attrs:{\"collections\":_vm.albums,\"loading\":_vm.loadingCollections,\"error\":_vm.errorFetchingCollections},scopedSlots:_vm._u([{key:\"default\",fn:function({collection}){return _c('CollectionCover',{key:collection.basename,attrs:{\"link\":`/albums/${collection.basename}`,\"alt-img\":_vm.t('photos', 'Cover photo for album {albumName}', { albumName: collection.basename }),\"cover-url\":_vm._f(\"coverUrl\")(collection.lastPhoto)}},[_c('span',{staticClass:\"album__name\"},[_vm._v(\"\\n\\t\\t\\t\\t\"+_vm._s(collection.basename)+\"\\n\\t\\t\\t\")]),_vm._v(\" \"),_c('div',{staticClass:\"album__details\",attrs:{\"slot\":\"subtitle\"},slot:\"subtitle\"},[_vm._v(\"\\n\\t\\t\\t\\t\"+_vm._s(collection.date)+\" ⸱ \"+_vm._s(_vm.n('photos', '%n item', '%n photos and videos', collection.nbItems,))+\"\\n\\t\\t\\t\")])])}}])},[_c('HeaderNavigation',{key:\"navigation\",attrs:{\"slot\":\"header\",\"loading\":_vm.loadingCollections,\"title\":_vm.t('photos', 'Albums'),\"root-title\":_vm.t('photos', 'Albums')},on:{\"refresh\":_vm.fetchAlbums},slot:\"header\"},[_c('NcButton',{attrs:{\"aria-label\":_vm.isMobile ? _vm.t('photos', 'New album') : undefined},on:{\"click\":function($event){_vm.showAlbumCreationForm = true}},scopedSlots:_vm._u([{key:\"icon\",fn:function(){return [_c('Plus',{attrs:{\"size\":20}})]},proxy:true},(!_vm.isMobile)?{key:\"default\",fn:function(){return [_vm._v(\"\\n\\t\\t\\t\\t\\t\"+_vm._s(_vm.t('photos', 'New album'))+\"\\n\\t\\t\\t\\t\")]},proxy:true}:null],null,true)})],1),_vm._v(\" \"),_vm._v(\" \"),_c('NcEmptyContent',{attrs:{\"slot\":\"empty-collections-list\",\"name\":_vm.t('photos', 'There is no album yet!')},slot:\"empty-collections-list\"},[_c('FolderMultipleImage',{attrs:{\"slot\":\"icon\"},slot:\"icon\"})],1)],1),_vm._v(\" \"),(_vm.showAlbumCreationForm)?_c('NcModal',{on:{\"close\":function($event){_vm.showAlbumCreationForm = false}}},[_c('h2',{staticClass:\"album-creation__heading\"},[_vm._v(\"\\n\\t\\t\\t\"+_vm._s(_vm.t('photos', 'New album'))+\"\\n\\t\\t\")]),_vm._v(\" \"),_c('AlbumForm',{on:{\"done\":_vm.handleAlbumCreated}})],1):_vm._e()],1)\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","<!--\n - @copyright Copyright (c) 2022 Louis Chemineau <louis@chmn.me>\n -\n - @author Louis Chemineau <louis@chmn.me>\n -\n - @license AGPL-3.0-or-later\n -\n - This program is free software: you can redistribute it and/or modify\n - it under the terms of the GNU Affero General Public License as\n - published by the Free Software Foundation, either version 3 of the\n - License, or (at your option) any later version.\n -\n - This program is distributed in the hope that it will be useful,\n - but WITHOUT ANY WARRANTY; without even the implied warranty of\n - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\n - GNU Affero General Public License for more details.\n -\n - You should have received a copy of the GNU Affero General Public License\n - along with this program. If not, see <http://www.gnu.org/licenses/>.\n -\n -->\n<template>\n\t<div>\n\t\t<CollectionsList :collections=\"albums\"\n\t\t\t:loading=\"loadingCollections\"\n\t\t\t:error=\"errorFetchingCollections\"\n\t\t\tclass=\"albums-list\">\n\t\t\t<HeaderNavigation key=\"navigation\"\n\t\t\t\tslot=\"header\"\n\t\t\t\t:loading=\"loadingCollections\"\n\t\t\t\t:title=\"t('photos', 'Albums')\"\n\t\t\t\t:root-title=\"t('photos', 'Albums')\"\n\t\t\t\t@refresh=\"fetchAlbums\">\n\t\t\t\t<NcButton :aria-label=\"isMobile ? t('photos', 'New album') : undefined\"\n\t\t\t\t\t@click=\"showAlbumCreationForm = true\">\n\t\t\t\t\t<template #icon>\n\t\t\t\t\t\t<Plus :size=\"20\" />\n\t\t\t\t\t</template>\n\t\t\t\t\t<template v-if=\"!isMobile\" #default>\n\t\t\t\t\t\t{{ t('photos', 'New album') }}\n\t\t\t\t\t</template>\n\t\t\t\t</NcButton>\n\t\t\t</HeaderNavigation>\n\n\t\t\t<CollectionCover :key=\"collection.basename\"\n\t\t\t\tslot-scope=\"{collection}\"\n\t\t\t\t:link=\"`/albums/${collection.basename}`\"\n\t\t\t\t:alt-img=\"t('photos', 'Cover photo for album {albumName}', { albumName: collection.basename })\"\n\t\t\t\t:cover-url=\"collection.lastPhoto | coverUrl\">\n\t\t\t\t<span class=\"album__name\">\n\t\t\t\t\t{{ collection.basename }}\n\t\t\t\t</span>\n\n\t\t\t\t<div slot=\"subtitle\" class=\"album__details\">\n\t\t\t\t\t{{ collection.date }} ⸱ {{ n('photos', '%n item', '%n photos and videos', collection.nbItems,) }}\n\t\t\t\t</div>\n\t\t\t</CollectionCover>\n\n\t\t\t<NcEmptyContent slot=\"empty-collections-list\" :name=\"t('photos', 'There is no album yet!')\">\n\t\t\t\t<FolderMultipleImage slot=\"icon\" />\n\t\t\t</NcEmptyContent>\n\t\t</CollectionsList>\n\n\t\t<NcModal v-if=\"showAlbumCreationForm\"\n\t\t\t@close=\"showAlbumCreationForm = false\">\n\t\t\t<h2 class=\"album-creation__heading\">\n\t\t\t\t{{ t('photos', 'New album') }}\n\t\t\t</h2>\n\t\t\t<AlbumForm @done=\"handleAlbumCreated\" />\n\t\t</NcModal>\n\t</div>\n</template>\n\n<script>\nimport Plus from 'vue-material-design-icons/Plus.vue'\nimport FolderMultipleImage from 'vue-material-design-icons/FolderMultipleImage.vue'\n\nimport { generateUrl } from '@nextcloud/router'\nimport { NcModal, NcButton, NcEmptyContent, useIsSmallMobile } from '@nextcloud/vue'\nimport { translate, translatePlural } from '@nextcloud/l10n'\nimport { getCurrentUser } from '@nextcloud/auth'\n\nimport CollectionsList from '../components/Collection/CollectionsList.vue'\nimport CollectionCover from '../components/Collection/CollectionCover.vue'\nimport HeaderNavigation from '../components/HeaderNavigation.vue'\nimport AlbumForm from '../components/Albums/AlbumForm.vue'\nimport FetchCollectionsMixin from '../mixins/FetchCollectionsMixin.js'\n\nexport default {\n\tname: 'Albums',\n\tcomponents: {\n\t\tPlus,\n\t\tFolderMultipleImage,\n\t\tNcModal,\n\t\tNcButton,\n\t\tNcEmptyContent,\n\t\tCollectionsList,\n\t\tCollectionCover,\n\t\tHeaderNavigation,\n\t\tAlbumForm,\n\t},\n\n\tfilters: {\n\t\t/**\n\t\t * @param {string} lastPhoto The album's last photos.\n\t\t */\n\t\tcoverUrl(lastPhoto) {\n\t\t\tif (lastPhoto === -1) {\n\t\t\t\treturn ''\n\t\t\t}\n\n\t\t\treturn generateUrl(`/apps/photos/api/v1/preview/${lastPhoto}?x=${512}&y=${512}`)\n\t\t},\n\t},\n\n\tmixins: [\n\t\tFetchCollectionsMixin,\n\t],\n\n\tsetup() {\n\t\tconst isMobile = useIsSmallMobile()\n\t\treturn {\n\t\t\tisMobile,\n\t\t}\n\t},\n\n\tdata() {\n\t\treturn {\n\t\t\tshowAlbumCreationForm: false,\n\t\t}\n\t},\n\n\tcomputed: {\n\t\t/**\n\t\t * @return {import('../services/Albums').IndexedAlbums}\n\t\t */\n\t\talbums() {\n\t\t\treturn this.$store.getters.albums\n\t\t},\n\t},\n\n\tasync beforeMount() {\n\t\tthis.fetchAlbums()\n\t},\n\n\tmethods: {\n\t\tfetchAlbums() {\n\t\t\tthis.fetchCollections(\n\t\t\t\t`/photos/${getCurrentUser()?.uid}/albums`,\n\t\t\t\t['<nc:location />', '<nc:dateRange />', '<nc:collaborators />']\n\t\t\t)\n\t\t},\n\n\t\thandleAlbumCreated({ album }) {\n\t\t\tthis.showAlbumCreationForm = false\n\t\t\tthis.$router.push(`albums/${album.basename}`)\n\t\t},\n\n\t\tt: translate,\n\t\tn: translatePlural,\n\t},\n}\n</script>\n<style lang=\"scss\" scoped>\n.albums-list {\n\tdisplay: flex;\n\tflex-direction: column;\n\n\t.album__name {\n\t\tfont-weight: normal;\n\t\toverflow: hidden;\n\t\twhite-space: nowrap;\n\t\ttext-overflow: ellipsis;\n\t\tfont-size: 20px;\n\t\tmargin-bottom: 12px;\n\t\tline-height: 30px;\n\t\tcolor: var(--color-main-text);\n\t}\n}\n\n.album-creation__heading {\n\tpadding: calc(var(--default-grid-baseline) * 4);\n\tmargin-bottom: 0px;\n\tpadding-bottom: 0px;\n}\n</style>\n","import mod from \"-!../../node_modules/babel-loader/lib/index.js!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Albums.vue?vue&type=script&lang=js\"; export default mod; export * from \"-!../../node_modules/babel-loader/lib/index.js!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Albums.vue?vue&type=script&lang=js\"","\n import API from \"!../../node_modules/style-loader/dist/runtime/injectStylesIntoStyleTag.js\";\n import domAPI from \"!../../node_modules/style-loader/dist/runtime/styleDomAPI.js\";\n import insertFn from \"!../../node_modules/style-loader/dist/runtime/insertBySelector.js\";\n import setAttributes from \"!../../node_modules/style-loader/dist/runtime/setAttributesWithoutAttributes.js\";\n import insertStyleElement from \"!../../node_modules/style-loader/dist/runtime/insertStyleElement.js\";\n import styleTagTransformFn from \"!../../node_modules/style-loader/dist/runtime/styleTagTransform.js\";\n import content, * as namedExport from \"!!../../node_modules/css-loader/dist/cjs.js!../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../node_modules/postcss-loader/dist/cjs.js!../../node_modules/sass-loader/dist/cjs.js??clonedRuleSet-2.use[3]!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Albums.vue?vue&type=style&index=0&id=4eebcf83&prod&lang=scss&scoped=true\";\n \n \n\nvar options = {};\n\noptions.styleTagTransform = styleTagTransformFn;\noptions.setAttributes = setAttributes;\n\n options.insert = insertFn.bind(null, \"head\");\n \noptions.domAPI = domAPI;\noptions.insertStyleElement = insertStyleElement;\n\nvar update = API(content, options);\n\n\n\nexport * from \"!!../../node_modules/css-loader/dist/cjs.js!../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../node_modules/postcss-loader/dist/cjs.js!../../node_modules/sass-loader/dist/cjs.js??clonedRuleSet-2.use[3]!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Albums.vue?vue&type=style&index=0&id=4eebcf83&prod&lang=scss&scoped=true\";\n export default content && content.locals ? content.locals : undefined;\n","import { render, staticRenderFns } from \"./Albums.vue?vue&type=template&id=4eebcf83&scoped=true\"\nimport script from \"./Albums.vue?vue&type=script&lang=js\"\nexport * from \"./Albums.vue?vue&type=script&lang=js\"\nimport style0 from \"./Albums.vue?vue&type=style&index=0&id=4eebcf83&prod&lang=scss&scoped=true\"\n\n\n/* normalize component */\nimport normalizer from \"!../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"4eebcf83\",\n null\n \n)\n\nexport default component.exports"],"names":["name","data","abortController","AbortController","beforeDestroy","this","abort","beforeRouteLeave","from","to","next","errorFetchingCollections","loadingCollections","mixins","AbortControllerMixin","methods","mapActions","async","collectionHome","extraProps","client","collections","fetchCollections","signal","addCollections","error","_error$response","response","status","___CSS_LOADER_EXPORT___","push","module","id","components","ImageMultiple","props","coverUrl","type","String","required","altImg","link","options","styleTagTransform","setAttributes","insert","domAPI","insertStyleElement","_vm","_c","_self","staticClass","attrs","_v","_t","AlertCircle","NcEmptyContent","Object","loading","Boolean","default","Error","computed","noCollection","keys","length","t","translate","slot","_e","_l","collection","Plus","FolderMultipleImage","NcModal","NcButton","CollectionsList","CollectionCover","HeaderNavigation","AlbumForm","filters","lastPhoto","generateUrl","concat","FetchCollectionsMixin","setup","isMobile","useIsSmallMobile","showAlbumCreationForm","albums","$store","getters","fetchAlbums","_getCurrentUser","getCurrentUser","uid","handleAlbumCreated","_ref","album","$router","basename","n","translatePlural","scopedSlots","_u","key","fn","albumName","_f","_s","date","nbItems","on","undefined","$event","proxy"],"sourceRoot":""}