1
0

settings-apps-view-7418.js 43 KB

12
  1. "use strict";(self.webpackChunknextcloud=self.webpackChunknextcloud||[]).push([[7418],{81:(t,e,a)=>{a.d(e,{Z:()=>r});var n=a(87537),s=a.n(n),i=a(23645),p=a.n(i)()(s());p.push([t.id,".app-details[data-v-60e3cd51]{padding:20px}.app-details__actions-manage[data-v-60e3cd51]{display:flex}.app-details__actions-manage input[data-v-60e3cd51]{flex:0 1 auto;min-width:0;text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.app-details__dependencies[data-v-60e3cd51]{opacity:.7}.app-details__documentation[data-v-60e3cd51]{padding-top:20px}.app-details__documentation a.appslink[data-v-60e3cd51]{display:block}.app-details__description[data-v-60e3cd51]{padding-top:20px}.force[data-v-60e3cd51]{color:var(--color-error);border-color:var(--color-error);background:var(--color-main-background)}.force[data-v-60e3cd51]:hover,.force[data-v-60e3cd51]:active{color:var(--color-main-background);border-color:var(--color-error) !important;background:var(--color-error)}","",{version:3,sources:["webpack://./apps/settings/src/components/AppDetails.vue"],names:[],mappings:"AACA,8BACC,YAAA,CAIC,8CAEC,YAAA,CACA,oDACC,aAAA,CACA,WAAA,CACA,sBAAA,CACA,kBAAA,CACA,eAAA,CAIH,4CACC,UAAA,CAED,6CACC,gBAAA,CACA,wDACC,aAAA,CAGF,2CACC,gBAAA,CAIF,wBACC,wBAAA,CACA,+BAAA,CACA,uCAAA,CAED,6DAEC,kCAAA,CACA,0CAAA,CACA,6BAAA",sourcesContent:["\n.app-details {\n\tpadding: 20px;\n\n\t&__actions {\n\t\t// app management\n\t\t&-manage {\n\t\t\t// if too many, shrink them and ellipsis\n\t\t\tdisplay: flex;\n\t\t\tinput {\n\t\t\t\tflex: 0 1 auto;\n\t\t\t\tmin-width: 0;\n\t\t\t\ttext-overflow: ellipsis;\n\t\t\t\twhite-space: nowrap;\n\t\t\t\toverflow: hidden;\n\t\t\t}\n\t\t}\n\t}\n\t&__dependencies {\n\t\topacity: .7;\n\t}\n\t&__documentation {\n\t\tpadding-top: 20px;\n\t\ta.appslink {\n\t\t\tdisplay: block;\n\t\t}\n\t}\n\t&__description {\n\t\tpadding-top: 20px;\n\t}\n}\n\n.force {\n\tcolor: var(--color-error);\n\tborder-color: var(--color-error);\n\tbackground: var(--color-main-background);\n}\n.force:hover,\n.force:active {\n\tcolor: var(--color-main-background);\n\tborder-color: var(--color-error) !important;\n\tbackground: var(--color-error);\n}\n\n"],sourceRoot:""}]);const r=p},37702:(t,e,a)=>{a.d(e,{Z:()=>r});var n=a(87537),s=a.n(n),i=a(23645),p=a.n(i)()(s());p.push([t.id,".settings-markdown[data-v-ffd9a2d6] h1,.settings-markdown[data-v-ffd9a2d6] h2,.settings-markdown[data-v-ffd9a2d6] h3,.settings-markdown[data-v-ffd9a2d6] h4,.settings-markdown[data-v-ffd9a2d6] h5,.settings-markdown[data-v-ffd9a2d6] h6{font-weight:600;line-height:120%;margin-top:24px;margin-bottom:12px;color:var(--color-main-text)}.settings-markdown[data-v-ffd9a2d6] h1{font-size:36px;margin-top:48px}.settings-markdown[data-v-ffd9a2d6] h2{font-size:28px;margin-top:48px}.settings-markdown[data-v-ffd9a2d6] h3{font-size:24px}.settings-markdown[data-v-ffd9a2d6] h4{font-size:21px}.settings-markdown[data-v-ffd9a2d6] h5{font-size:17px}.settings-markdown[data-v-ffd9a2d6] h6{font-size:var(--default-font-size)}.settings-markdown[data-v-ffd9a2d6] pre{white-space:pre;overflow-x:auto;background-color:var(--color-background-dark);border-radius:var(--border-radius);padding:1em 1.3em;margin-bottom:1em}.settings-markdown[data-v-ffd9a2d6] p code{background-color:var(--color-background-dark);border-radius:var(--border-radius);padding:.1em .3em}.settings-markdown[data-v-ffd9a2d6] li{position:relative}.settings-markdown[data-v-ffd9a2d6] ul,.settings-markdown[data-v-ffd9a2d6] ol{padding-left:10px;margin-left:10px}.settings-markdown[data-v-ffd9a2d6] ul li{list-style-type:disc}.settings-markdown[data-v-ffd9a2d6] ul>li>ul>li{list-style-type:circle}.settings-markdown[data-v-ffd9a2d6] ul>li>ul>li ul li{list-style-type:square}.settings-markdown[data-v-ffd9a2d6] blockquote{padding-left:1em;border-left:4px solid var(--color-primary-element);color:var(--color-text-maxcontrast);margin-left:0;margin-right:0}","",{version:3,sources:["webpack://./apps/settings/src/components/Markdown.vue"],names:[],mappings:"AAGA,0OAMC,eAAA,CACA,gBAAA,CACA,eAAA,CACA,kBAAA,CACA,4BAAA,CAGD,uCACC,cAAA,CACA,eAAA,CAGD,uCACC,cAAA,CACA,eAAA,CAGD,uCACC,cAAA,CAGD,uCACC,cAAA,CAGD,uCACC,cAAA,CAGD,uCACC,kCAAA,CAGD,wCACC,eAAA,CACA,eAAA,CACA,6CAAA,CACA,kCAAA,CACA,iBAAA,CACA,iBAAA,CAGD,2CACC,6CAAA,CACA,kCAAA,CACA,iBAAA,CAGD,uCACC,iBAAA,CAGD,8EACC,iBAAA,CACA,gBAAA,CAGD,0CACC,oBAAA,CAGD,gDACC,sBAAA,CAGD,sDACC,sBAAA,CAGD,+CACC,gBAAA,CACA,kDAAA,CACA,mCAAA,CACA,aAAA,CACA,cAAA",sourcesContent:["\n.settings-markdown::v-deep {\n\nh1,\nh2,\nh3,\nh4,\nh5,\nh6 {\n\tfont-weight: 600;\n\tline-height: 120%;\n\tmargin-top: 24px;\n\tmargin-bottom: 12px;\n\tcolor: var(--color-main-text);\n}\n\nh1 {\n\tfont-size: 36px;\n\tmargin-top: 48px;\n}\n\nh2 {\n\tfont-size: 28px;\n\tmargin-top: 48px;\n}\n\nh3 {\n\tfont-size: 24px;\n}\n\nh4 {\n\tfont-size: 21px;\n}\n\nh5 {\n\tfont-size: 17px;\n}\n\nh6 {\n\tfont-size: var(--default-font-size);\n}\n\npre {\n\twhite-space: pre;\n\toverflow-x: auto;\n\tbackground-color: var(--color-background-dark);\n\tborder-radius: var(--border-radius);\n\tpadding: 1em 1.3em;\n\tmargin-bottom: 1em;\n}\n\np code {\n\tbackground-color: var(--color-background-dark);\n\tborder-radius: var(--border-radius);\n\tpadding: .1em .3em;\n}\n\nli {\n\tposition: relative;\n}\n\nul, ol {\n\tpadding-left: 10px;\n\tmargin-left: 10px;\n}\n\nul li {\n\tlist-style-type: disc;\n}\n\nul > li > ul > li {\n\tlist-style-type: circle;\n}\n\nul > li > ul > li ul li {\n\tlist-style-type: square;\n}\n\nblockquote {\n\tpadding-left: 1em;\n\tborder-left: 4px solid var(--color-primary-element);\n\tcolor: var(--color-text-maxcontrast);\n\tmargin-left: 0;\n\tmargin-right: 0;\n}\n\n}\n"],sourceRoot:""}]);const r=p},52411:(t,e,a)=>{a.d(e,{Z:()=>r});var n=a(87537),s=a.n(n),i=a(23645),p=a.n(i)()(s());p.push([t.id,".app-sidebar[data-v-ce9b8b58]:not(.app-sidebar--without-background) :not(.app-sidebar-header--compact) .app-sidebar-header__figure{background-size:cover}.app-sidebar[data-v-ce9b8b58]:not(.app-sidebar--without-background) .app-sidebar-header--compact .app-sidebar-header__figure{background-size:32px;filter:var(--background-invert-if-bright)}.app-sidebar[data-v-ce9b8b58] .app-sidebar-header__description .app-version{padding-left:10px}.app-sidebar[data-v-ce9b8b58].app-sidebar--without-background .app-sidebar-header__figure{display:flex;align-items:center;justify-content:center}.app-sidebar[data-v-ce9b8b58].app-sidebar--without-background .app-sidebar-header__figure--default-app-icon{width:32px;height:32px;background-size:32px}.app-sidebar[data-v-ce9b8b58] .app-sidebar-header__desc .app-sidebar-header__subtitle{overflow:visible !important;height:auto;white-space:normal !important;line-height:16px}.app-sidebar[data-v-ce9b8b58] .app-sidebar-header__action{margin:0 20px}.app-sidebar[data-v-ce9b8b58] .app-sidebar-header__action input{margin:3px}.app-navigation[data-v-ce9b8b58] button.app-navigation-toggle{top:8px;right:-8px}.app-sidebar-tabs__release h2[data-v-ce9b8b58]{border-bottom:1px solid var(--color-border)}.app-sidebar-tabs__release[data-v-ce9b8b58] h3{font-size:20px}.app-sidebar-tabs__release[data-v-ce9b8b58] h4{font-size:17px}","",{version:3,sources:["webpack://./apps/settings/src/views/Apps.vue"],names:[],mappings:"AAIE,mIACC,qBAAA,CAGD,6HACC,oBAAA,CAEA,yCAAA,CAKD,4EACC,iBAAA,CAMD,0FACC,YAAA,CACA,kBAAA,CACA,sBAAA,CACA,4GACC,UAAA,CACA,WAAA,CACA,oBAAA,CAQF,sFACC,2BAAA,CACA,WAAA,CACA,6BAAA,CACA,gBAAA,CAIF,0DAEC,aAAA,CACA,gEACC,UAAA,CAMH,8DACC,OAAA,CACA,UAAA,CAIA,+CACC,2CAAA,CAKA,+CACC,cAAA,CAED,+CACC,cAAA",sourcesContent:["\n.app-sidebar::v-deep {\n\t&:not(.app-sidebar--without-background) {\n\t\t// with full screenshot, let's fill the figure\n\t\t:not(.app-sidebar-header--compact) .app-sidebar-header__figure {\n\t\t\tbackground-size: cover;\n\t\t}\n\t\t// revert sidebar app icon so it is black\n\t\t.app-sidebar-header--compact .app-sidebar-header__figure {\n\t\t\tbackground-size: 32px;\n\n\t\t\tfilter: var(--background-invert-if-bright);\n\t\t}\n\t}\n\n\t.app-sidebar-header__description {\n\t\t.app-version {\n\t\t\tpadding-left: 10px;\n\t\t}\n\t}\n\n\t// default icon slot styling\n\t&.app-sidebar--without-background {\n\t\t.app-sidebar-header__figure {\n\t\t\tdisplay: flex;\n\t\t\talign-items: center;\n\t\t\tjustify-content: center;\n\t\t\t&--default-app-icon {\n\t\t\t\twidth: 32px;\n\t\t\t\theight: 32px;\n\t\t\t\tbackground-size: 32px;\n\t\t\t}\n\t\t}\n\t}\n\n\t// TODO: migrate to components\n\t.app-sidebar-header__desc {\n\t\t// allow multi line subtitle for the license\n\t\t.app-sidebar-header__subtitle {\n\t\t\toverflow: visible !important;\n\t\t\theight: auto;\n\t\t\twhite-space: normal !important;\n\t\t\tline-height: 16px;\n\t\t}\n\t}\n\n\t.app-sidebar-header__action {\n\t\t// align with tab content\n\t\tmargin: 0 20px;\n\t\tinput {\n\t\t\tmargin: 3px;\n\t\t}\n\t}\n}\n\n// Align the appNavigation toggle with the apps header toolbar\n.app-navigation::v-deep button.app-navigation-toggle {\n\ttop: 8px;\n\tright: -8px;\n}\n\n.app-sidebar-tabs__release {\n\th2 {\n\t\tborder-bottom: 1px solid var(--color-border);\n\t}\n\n\t// Overwrite changelog heading styles\n\t::v-deep {\n\t\th3 {\n\t\t\tfont-size: 20px;\n\t\t}\n\t\th4 {\n\t\t\tfont-size: 17px;\n\t\t}\n\t}\n}\n"],sourceRoot:""}]);const r=p},28952:(t,e,a)=>{a.d(e,{Z:()=>r});var n=a(87537),s=a.n(n),i=a(23645),p=a.n(i)()(s());p.push([t.id,"\n.app-icon[data-v-4a912665] {\n\tfilter: var(--background-invert-if-bright);\n}\n.actions[data-v-4a912665] {\n\tdisplay: flex !important;\n\tgap: 8px;\n\tflex-wrap: wrap;\n\tjustify-content: end;\n}\n","",{version:3,sources:["webpack://./apps/settings/src/components/AppList/AppItem.vue"],names:[],mappings:";AAkMA;CACA,0CAAA;AACA;AACA;CACA,wBAAA;CACA,QAAA;CACA,eAAA;CACA,oBAAA;AACA",sourcesContent:['\x3c!--\n - @copyright Copyright (c) 2018 Julius Härtl <jus@bitgrid.net>\n -\n - @author Julius Härtl <jus@bitgrid.net>\n -\n - @license GNU AGPL version 3 or any later version\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 --\x3e\n\n<template>\n\t<div class="section" :class="{ selected: isSelected }" @click="showAppDetails">\n\t\t<div class="app-image app-image-icon" @click="showAppDetails">\n\t\t\t<div v-if="(listView && !app.preview) || (!listView && !screenshotLoaded)" class="icon-settings-dark" />\n\n\t\t\t<svg v-else-if="listView && app.preview"\n\t\t\t\twidth="32"\n\t\t\t\theight="32"\n\t\t\t\tviewBox="0 0 32 32">\n\t\t\t\t<image x="0"\n\t\t\t\t\ty="0"\n\t\t\t\t\twidth="32"\n\t\t\t\t\theight="32"\n\t\t\t\t\tpreserveAspectRatio="xMinYMin meet"\n\t\t\t\t\t:xlink:href="app.preview"\n\t\t\t\t\tclass="app-icon" />\n\t\t\t</svg>\n\n\t\t\t<img v-if="!listView && app.screenshot && screenshotLoaded" :src="app.screenshot" width="100%">\n\t\t</div>\n\t\t<div class="app-name" @click="showAppDetails">\n\t\t\t{{ app.name }}\n\t\t</div>\n\t\t<div v-if="!listView" class="app-summary">\n\t\t\t{{ app.summary }}\n\t\t</div>\n\t\t<div v-if="listView" class="app-version">\n\t\t\t<span v-if="app.version">{{ app.version }}</span>\n\t\t\t<span v-else-if="app.appstoreData.releases[0].version">{{ app.appstoreData.releases[0].version }}</span>\n\t\t</div>\n\n\t\t<div class="app-level">\n\t\t\t<span v-if="app.level === 300"\n\t\t\t\t:title="t(\'settings\', \'This app is supported via your current Nextcloud subscription.\')"\n\t\t\t\t:aria-label="t(\'settings\', \'This app is supported via your current Nextcloud subscription.\')"\n\t\t\t\tclass="supported icon-checkmark-color">\n\t\t\t\t{{ t(\'settings\', \'Supported\') }}</span>\n\t\t\t<span v-if="app.level === 200"\n\t\t\t\t:title="t(\'settings\', \'Featured apps are developed by and within the community. They offer central functionality and are ready for production use.\')"\n\t\t\t\t:aria-label="t(\'settings\', \'Featured apps are developed by and within the community. They offer central functionality and are ready for production use.\')"\n\t\t\t\tclass="official icon-checkmark">\n\t\t\t\t{{ t(\'settings\', \'Featured\') }}</span>\n\t\t\t<AppScore v-if="hasRating && !listView" :score="app.score" />\n\t\t</div>\n\n\t\t<div class="actions">\n\t\t\t<div v-if="app.error" class="warning">\n\t\t\t\t{{ app.error }}\n\t\t\t</div>\n\t\t\t<div v-if="isLoading" class="icon icon-loading-small" />\n\t\t\t<NcButton v-if="app.update"\n\t\t\t\ttype="primary"\n\t\t\t\t:disabled="installing || isLoading"\n\t\t\t\t@click.stop="update(app.id)">\n\t\t\t\t{{ t(\'settings\', \'Update to {update}\', {update:app.update}) }}\n\t\t\t</NcButton>\n\t\t\t<NcButton v-if="app.canUnInstall"\n\t\t\t\tclass="uninstall"\n\t\t\t\ttype="tertiary"\n\t\t\t\t:disabled="installing || isLoading"\n\t\t\t\t@click.stop="remove(app.id)">\n\t\t\t\t{{ t(\'settings\', \'Remove\') }}\n\t\t\t</NcButton>\n\t\t\t<NcButton v-if="app.active"\n\t\t\t\t:disabled="installing || isLoading"\n\t\t\t\t@click.stop="disable(app.id)">\n\t\t\t\t{{ t(\'settings\',\'Disable\') }}\n\t\t\t</NcButton>\n\t\t\t<NcButton v-if="!app.active && (app.canInstall || app.isCompatible)"\n\t\t\t\t:title="enableButtonTooltip"\n\t\t\t\t:aria-label="enableButtonTooltip"\n\t\t\t\ttype="primary"\n\t\t\t\t:disabled="!app.canInstall || installing || isLoading"\n\t\t\t\t@click.stop="enable(app.id)">\n\t\t\t\t{{ enableButtonText }}\n\t\t\t</NcButton>\n\t\t\t<NcButton v-else-if="!app.active"\n\t\t\t\t:title="forceEnableButtonTooltip"\n\t\t\t\t:aria-label="forceEnableButtonTooltip"\n\t\t\t\ttype="secondary"\n\t\t\t\t:disabled="installing || isLoading"\n\t\t\t\t@click.stop="forceEnable(app.id)">\n\t\t\t\t{{ forceEnableButtonText }}\n\t\t\t</NcButton>\n\t\t</div>\n\t</div>\n</template>\n\n<script>\nimport AppScore from \'./AppScore.vue\'\nimport AppManagement from \'../../mixins/AppManagement.js\'\nimport SvgFilterMixin from \'../SvgFilterMixin.vue\'\nimport NcButton from \'@nextcloud/vue/dist/Components/NcButton.js\'\n\nexport default {\n\tname: \'AppItem\',\n\tcomponents: {\n\t\tAppScore,\n\t\tNcButton,\n\t},\n\tmixins: [AppManagement, SvgFilterMixin],\n\tprops: {\n\t\tapp: {},\n\t\tcategory: {},\n\t\tlistView: {\n\t\t\ttype: Boolean,\n\t\t\tdefault: true,\n\t\t},\n\t},\n\tdata() {\n\t\treturn {\n\t\t\tisSelected: false,\n\t\t\tscrolled: false,\n\t\t\tscreenshotLoaded: false,\n\t\t}\n\t},\n\tcomputed: {\n\t\thasRating() {\n\t\t\treturn this.app.appstoreData && this.app.appstoreData.ratingNumOverall > 5\n\t\t},\n\t},\n\twatch: {\n\t\t\'$route.params.id\'(id) {\n\t\t\tthis.isSelected = (this.app.id === id)\n\t\t},\n\t},\n\tmounted() {\n\t\tthis.isSelected = (this.app.id === this.$route.params.id)\n\t\tif (this.app.releases && this.app.screenshot) {\n\t\t\tconst image = new Image()\n\t\t\timage.onload = (e) => {\n\t\t\t\tthis.screenshotLoaded = true\n\t\t\t}\n\t\t\timage.src = this.app.screenshot\n\t\t}\n\t},\n\twatchers: {\n\n\t},\n\tmethods: {\n\t\tasync showAppDetails(event) {\n\t\t\tif (event.currentTarget.tagName === \'INPUT\' || event.currentTarget.tagName === \'A\') {\n\t\t\t\treturn\n\t\t\t}\n\t\t\ttry {\n\t\t\t\tawait this.$router.push({\n\t\t\t\t\tname: \'apps-details\',\n\t\t\t\t\tparams: { category: this.category, id: this.app.id },\n\t\t\t\t})\n\t\t\t} catch (e) {\n\t\t\t\t// we already view this app\n\t\t\t}\n\t\t},\n\t\tprefix(prefix, content) {\n\t\t\treturn prefix + \'_\' + content\n\t\t},\n\t},\n}\n<\/script>\n\n<style scoped>\n\t.app-icon {\n\t\tfilter: var(--background-invert-if-bright);\n\t}\n\t.actions {\n\t\tdisplay: flex !important;\n\t\tgap: 8px;\n\t\tflex-wrap: wrap;\n\t\tjustify-content: end;\n\t}\n</style>\n'],sourceRoot:""}]);const r=p},39789:(e,a,n)=>{n.r(a),n.d(a,{default:()=>_t});var s=n(69183),i=n(20144),p=n(87369),r=n.n(p),o=n(69680),l=n.n(o),d=n(55209),c=n.n(d),u=n(53110),g=n.n(u),h=n(14032),A=n.n(h),v=n(47493),m=n.n(v),b=n(10250),f=n.n(b),C=n(62574),_=n.n(C),y=n(27472),w=n.n(y),k=n(79311),x=n(79753);const N={name:"AppScore",props:["score"],computed:{scoreImage(){const t="rating/s"+Math.round(10*this.score)+".svg";return(0,x.imagePath)("core",t)}}};var B=n(51900);const D=(0,B.Z)(N,(function(){return(0,this._self._c)("img",{staticClass:"app-score-image",attrs:{src:this.scoreImage}})}),[],!1,null,null,null).exports;var S=n(64024),T=n(4820);const I=()=>T.default.get((0,x.generateOcsUrl)("core/navigation",2)+"/apps?format=json").then((t=>{let{data:e}=t;200===e.ocs.meta.statuscode&&((0,s.j8)("nextcloud:app-menu.refresh",{apps:e.ocs.data}),window.dispatchEvent(new Event("resize")))})),L={computed:{appGroups(){return this.app.groups.map((t=>({id:t,name:t})))},installing(){return this.$store.getters.loading("install")},isLoading(){return this.app&&this.$store.getters.loading(this.app.id)},enableButtonText(){return this.app.needsDownload?t("settings","Download and enable"):t("settings","Enable")},forceEnableButtonText(){return this.app.needsDownload,t("settings","Enable untested app")},enableButtonTooltip(){return!!this.app.needsDownload&&t("settings","The app will be downloaded from the App Store")},forceEnableButtonTooltip(){const e=t("settings","This app is not marked as compatible with your Nextcloud version. If you continue you will still be able to install the app. Note that the app might not work as expected.");return this.app.needsDownload?e+" "+t("settings","The app will be downloaded from the App Store"):e}},data:()=>({groupCheckedAppsData:!1}),mounted(){this.app&&this.app.groups&&this.app.groups.length>0&&(this.groupCheckedAppsData=!0)},methods:{asyncFindGroup(t){return this.$store.dispatch("getGroups",{search:t,limit:5,offset:0})},isLimitedToGroups(t){return!(!this.app.groups.length&&!this.groupCheckedAppsData)},setGroupLimit(){this.groupCheckedAppsData||this.$store.dispatch("enableApp",{appId:this.app.id,groups:[]})},canLimitToGroups:t=>!(t.types&&t.types.includes("filesystem")||t.types.includes("prelogin")||t.types.includes("authentication")||t.types.includes("logging")||t.types.includes("prevent_group_restriction")),addGroupLimitation(t){const e=this.app.groups.concat([]).concat([t.id]);this.$store.dispatch("enableApp",{appId:this.app.id,groups:e})},removeGroupLimitation(t){const e=this.app.groups.concat([]),a=e.indexOf(t.id);a>-1&&e.splice(a,1),this.$store.dispatch("enableApp",{appId:this.app.id,groups:e})},forceEnable(t){this.$store.dispatch("forceEnableApp",{appId:t,groups:[]}).then((t=>{I()})).catch((t=>{(0,S.x2)(t)}))},enable(t){this.$store.dispatch("enableApp",{appId:t,groups:[]}).then((t=>{I()})).catch((t=>{(0,S.x2)(t)}))},disable(t){this.$store.dispatch("disableApp",{appId:t}).then((t=>{I()})).catch((t=>{(0,S.x2)(t)}))},remove(t){this.$store.dispatch("uninstallApp",{appId:t}).then((t=>{I()})).catch((t=>{(0,S.x2)(t)}))},install(t){this.$store.dispatch("enableApp",{appId:t}).then((t=>{I()})).catch((t=>{(0,S.x2)(t)}))},update(t){this.$store.dispatch("updateApp",{appId:t}).then((t=>{I()})).catch((t=>{(0,S.x2)(t)}))}}},E={name:"SvgFilterMixin",data:()=>({filterId:""}),computed:{filterUrl(){return"url(#".concat(this.filterId,")")}},mounted(){this.filterId="invertIconApps-"+Math.random().toString(36).substring(2)}},U=(0,B.Z)(E,void 0,void 0,!1,null,null,null).exports;var G=n(10861),$=n.n(G);const M={name:"AppItem",components:{AppScore:D,NcButton:$()},mixins:[L,U],props:{app:{},category:{},listView:{type:Boolean,default:!0}},data:()=>({isSelected:!1,scrolled:!1,screenshotLoaded:!1}),computed:{hasRating(){return this.app.appstoreData&&this.app.appstoreData.ratingNumOverall>5}},watch:{"$route.params.id"(t){this.isSelected=this.app.id===t}},mounted(){if(this.isSelected=this.app.id===this.$route.params.id,this.app.releases&&this.app.screenshot){const t=new Image;t.onload=t=>{this.screenshotLoaded=!0},t.src=this.app.screenshot}},watchers:{},methods:{async showAppDetails(t){if("INPUT"!==t.currentTarget.tagName&&"A"!==t.currentTarget.tagName)try{await this.$router.push({name:"apps-details",params:{category:this.category,id:this.app.id}})}catch(t){}},prefix:(t,e)=>t+"_"+e}};var P=n(93379),O=n.n(P),R=n(7795),V=n.n(R),Z=n(90569),z=n.n(Z),F=n(3565),j=n.n(F),Y=n(19216),q=n.n(Y),H=n(44589),Q=n.n(H),W=n(28952),J={};J.styleTagTransform=Q(),J.setAttributes=j(),J.insert=z().bind(null,"head"),J.domAPI=V(),J.insertStyleElement=q(),O()(W.Z,J),W.Z&&W.Z.locals&&W.Z.locals;const K=(0,B.Z)(M,(function(){var t=this,e=t._self._c;return e("div",{staticClass:"section",class:{selected:t.isSelected},on:{click:t.showAppDetails}},[e("div",{staticClass:"app-image app-image-icon",on:{click:t.showAppDetails}},[t.listView&&!t.app.preview||!t.listView&&!t.screenshotLoaded?e("div",{staticClass:"icon-settings-dark"}):t.listView&&t.app.preview?e("svg",{attrs:{width:"32",height:"32",viewBox:"0 0 32 32"}},[e("image",{staticClass:"app-icon",attrs:{x:"0",y:"0",width:"32",height:"32",preserveAspectRatio:"xMinYMin meet","xlink:href":t.app.preview}})]):t._e(),t._v(" "),!t.listView&&t.app.screenshot&&t.screenshotLoaded?e("img",{attrs:{src:t.app.screenshot,width:"100%"}}):t._e()]),t._v(" "),e("div",{staticClass:"app-name",on:{click:t.showAppDetails}},[t._v("\n\t\t"+t._s(t.app.name)+"\n\t")]),t._v(" "),t.listView?t._e():e("div",{staticClass:"app-summary"},[t._v("\n\t\t"+t._s(t.app.summary)+"\n\t")]),t._v(" "),t.listView?e("div",{staticClass:"app-version"},[t.app.version?e("span",[t._v(t._s(t.app.version))]):t.app.appstoreData.releases[0].version?e("span",[t._v(t._s(t.app.appstoreData.releases[0].version))]):t._e()]):t._e(),t._v(" "),e("div",{staticClass:"app-level"},[300===t.app.level?e("span",{staticClass:"supported icon-checkmark-color",attrs:{title:t.t("settings","This app is supported via your current Nextcloud subscription."),"aria-label":t.t("settings","This app is supported via your current Nextcloud subscription.")}},[t._v("\n\t\t\t"+t._s(t.t("settings","Supported")))]):t._e(),t._v(" "),200===t.app.level?e("span",{staticClass:"official icon-checkmark",attrs:{title:t.t("settings","Featured apps are developed by and within the community. They offer central functionality and are ready for production use."),"aria-label":t.t("settings","Featured apps are developed by and within the community. They offer central functionality and are ready for production use.")}},[t._v("\n\t\t\t"+t._s(t.t("settings","Featured")))]):t._e(),t._v(" "),t.hasRating&&!t.listView?e("AppScore",{attrs:{score:t.app.score}}):t._e()],1),t._v(" "),e("div",{staticClass:"actions"},[t.app.error?e("div",{staticClass:"warning"},[t._v("\n\t\t\t"+t._s(t.app.error)+"\n\t\t")]):t._e(),t._v(" "),t.isLoading?e("div",{staticClass:"icon icon-loading-small"}):t._e(),t._v(" "),t.app.update?e("NcButton",{attrs:{type:"primary",disabled:t.installing||t.isLoading},on:{click:function(e){return e.stopPropagation(),t.update(t.app.id)}}},[t._v("\n\t\t\t"+t._s(t.t("settings","Update to {update}",{update:t.app.update}))+"\n\t\t")]):t._e(),t._v(" "),t.app.canUnInstall?e("NcButton",{staticClass:"uninstall",attrs:{type:"tertiary",disabled:t.installing||t.isLoading},on:{click:function(e){return e.stopPropagation(),t.remove(t.app.id)}}},[t._v("\n\t\t\t"+t._s(t.t("settings","Remove"))+"\n\t\t")]):t._e(),t._v(" "),t.app.active?e("NcButton",{attrs:{disabled:t.installing||t.isLoading},on:{click:function(e){return e.stopPropagation(),t.disable(t.app.id)}}},[t._v("\n\t\t\t"+t._s(t.t("settings","Disable"))+"\n\t\t")]):t._e(),t._v(" "),t.app.active||!t.app.canInstall&&!t.app.isCompatible?t.app.active?t._e():e("NcButton",{attrs:{title:t.forceEnableButtonTooltip,"aria-label":t.forceEnableButtonTooltip,type:"secondary",disabled:t.installing||t.isLoading},on:{click:function(e){return e.stopPropagation(),t.forceEnable(t.app.id)}}},[t._v("\n\t\t\t"+t._s(t.forceEnableButtonText)+"\n\t\t")]):e("NcButton",{attrs:{title:t.enableButtonTooltip,"aria-label":t.enableButtonTooltip,type:"primary",disabled:!t.app.canInstall||t.installing||t.isLoading},on:{click:function(e){return e.stopPropagation(),t.enable(t.app.id)}}},[t._v("\n\t\t\t"+t._s(t.enableButtonText)+"\n\t\t")])],1)])}),[],!1,null,"4a912665",null).exports,X=(0,B.Z)({name:"PrefixMixin",methods:{prefix:(t,e)=>t+"_"+e}},void 0,void 0,!1,null,null,null).exports;var tt=n(63560),et=n(25108);const at={name:"AppList",components:{AppItem:K,NcButton:$()},mixins:[X],props:["category","app","search"],computed:{counter(){return this.apps.filter((t=>t.update)).length},loading(){return this.$store.getters.loading("list")},hasPendingUpdate(){return this.apps.filter((t=>t.update)).length>0},showUpdateAll(){return this.hasPendingUpdate&&this.useListView},apps(){const t=this.$store.getters.getAllApps.filter((t=>-1!==t.name.toLowerCase().search(this.search.toLowerCase()))).sort((function(t,e){const a=""+(t.active?0:1)+(t.update?0:1)+t.name,n=""+(e.active?0:1)+(e.update?0:1)+e.name;return OC.Util.naturalSortCompare(a,n)}));return"installed"===this.category?t.filter((t=>t.installed)):"enabled"===this.category?t.filter((t=>t.active&&t.installed)):"disabled"===this.category?t.filter((t=>!t.active&&t.installed)):"app-bundles"===this.category?t.filter((t=>t.bundles)):"updates"===this.category?t.filter((t=>t.update)):"supported"===this.category?t.filter((t=>300===t.level)):"featured"===this.category?t.filter((t=>200===t.level)):t.filter((t=>t.appstore&&void 0!==t.category&&(t.category===this.category||t.category.indexOf(this.category)>-1)))},bundles(){return this.$store.getters.getServerData.bundles.filter((t=>this.bundleApps(t.id).length>0))},bundleApps:()=>function(t){return this.$store.getters.getAllApps.filter((e=>void 0!==e.bundleIds&&e.bundleIds.includes(t)))},searchApps(){return""===this.search?[]:this.$store.getters.getAllApps.filter((t=>-1!==t.name.toLowerCase().search(this.search.toLowerCase())&&!this.apps.find((e=>e.id===t.id))))},useAppStoreView(){return!this.useListView&&!this.useBundleView},useListView(){return"installed"===this.category||"enabled"===this.category||"disabled"===this.category||"updates"===this.category||"featured"===this.category||"supported"===this.category},useBundleView(){return"app-bundles"===this.category},allBundlesEnabled(){const t=this;return function(e){return 0===t.bundleApps(e).filter((t=>!t.active)).length}},bundleToggleText(){const e=this;return function(a){return e.allBundlesEnabled(a)?t("settings","Disable all"):t("settings","Enable all")}}},methods:{toggleBundle(t){return this.allBundlesEnabled(t)?this.disableBundle(t):this.enableBundle(t)},enableBundle(t){const e=this.bundleApps(t).map((t=>t.id));this.$store.dispatch("enableApp",{appId:e,groups:[]}).catch((t=>{et.error(t),OC.Notification.show(t)}))},disableBundle(t){const e=this.bundleApps(t).map((t=>t.id));this.$store.dispatch("disableApp",{appId:e,groups:[]}).catch((t=>{OC.Notification.show(t)}))},updateAll(){const t=(0,tt.Z)(1);this.apps.filter((t=>t.update)).map((e=>t((()=>this.$store.dispatch("updateApp",{appId:e.id})))))}}},nt=(0,B.Z)(at,(function(){var t=this,e=t._self._c;return e("div",{attrs:{id:"app-content-inner"}},[e("div",{staticClass:"apps-list",class:{installed:t.useBundleView||t.useListView,store:t.useAppStoreView},attrs:{id:"apps-list"}},[t.useListView?[t.showUpdateAll?e("div",{staticClass:"toolbar"},[t._v("\n\t\t\t\t"+t._s(t.n("settings","%n app has an update available","%n apps have an update available",t.counter))+"\n\t\t\t\t"),t.showUpdateAll?e("NcButton",{attrs:{id:"app-list-update-all",type:"primary"},on:{click:t.updateAll}},[t._v("\n\t\t\t\t\t"+t._s(t.n("settings","Update","Update all",t.counter))+"\n\t\t\t\t")]):t._e()],1):t._e(),t._v(" "),t.showUpdateAll?t._e():e("div",{staticClass:"toolbar"},[t._v("\n\t\t\t\t"+t._s(t.t("settings","All apps are up-to-date."))+"\n\t\t\t")]),t._v(" "),e("transition-group",{staticClass:"apps-list-container",attrs:{name:"app-list",tag:"div"}},t._l(t.apps,(function(a){return e("AppItem",{key:a.id,attrs:{app:a,category:t.category}})})),1)]:t._e(),t._v(" "),t.useBundleView?e("transition-group",{staticClass:"apps-list-container",attrs:{name:"app-list",tag:"div"}},[t._l(t.bundles,(function(a){return[e("div",{key:a.id,staticClass:"apps-header"},[e("div",{staticClass:"app-image"}),t._v(" "),e("h2",[t._v(t._s(a.name)+" "),e("input",{attrs:{type:"button",value:t.bundleToggleText(a.id)},on:{click:function(e){return t.toggleBundle(a.id)}}})]),t._v(" "),e("div",{staticClass:"app-version"}),t._v(" "),e("div",{staticClass:"app-level"}),t._v(" "),e("div",{staticClass:"app-groups"}),t._v(" "),e("div",{staticClass:"actions"},[t._v("\n\t\t\t\t\t\t \n\t\t\t\t\t")])]),t._v(" "),t._l(t.bundleApps(a.id),(function(n){return e("AppItem",{key:a.id+n.id,attrs:{app:n,category:t.category}})}))]}))],2):t._e(),t._v(" "),t.useAppStoreView?t._l(t.apps,(function(a){return e("AppItem",{key:a.id,attrs:{app:a,category:t.category,"list-view":!1}})})):t._e()],2),t._v(" "),e("div",{staticClass:"apps-list installed",attrs:{id:"apps-list-search"}},[e("div",{staticClass:"apps-list-container"},[""!==t.search&&t.searchApps.length>0?[e("div",{staticClass:"section"},[e("div"),t._v(" "),e("td",{attrs:{colspan:"5"}},[e("h2",[t._v(t._s(t.t("settings","Results from other categories")))])])]),t._v(" "),t._l(t.searchApps,(function(a){return e("AppItem",{key:a.id,attrs:{app:a,category:t.category,"list-view":!0}})}))]:t._e()],2)]),t._v(" "),""===t.search||t.loading||0!==t.searchApps.length||0!==t.apps.length?t._e():e("div",{staticClass:"emptycontent emptycontent-search",attrs:{id:"apps-list-empty"}},[e("div",{staticClass:"icon-settings-dark",attrs:{id:"app-list-empty-icon"}}),t._v(" "),e("h2",[t._v(t._s(t.t("settings","No apps found for your version")))])]),t._v(" "),e("div",{attrs:{id:"searchresults"}})])}),[],!1,null,null,null).exports;var st=n(98266),it=n.n(st),pt=n(87441),rt=n(27856),ot=n.n(rt);const lt={name:"Markdown",props:{text:{type:String,default:""}},computed:{renderMarkdown(){const t=new pt.TU.Renderer;return t.link=function(t,e,a){let n;try{n=decodeURIComponent(unescape(t)).replace(/[^\w:]/g,"").toLowerCase()}catch(t){return""}if(0!==n.indexOf("http:")&&0!==n.indexOf("https:"))return"";let s='<a href="'+t+'" rel="noreferrer noopener"';return e&&(s+=' title="'+e+'"'),s+=">"+a+"</a>",s},t.image=function(t,e,a){return a||e},t.blockquote=function(t){return t},ot().sanitize((0,pt.TU)(this.text.trim(),{renderer:t,gfm:!1,highlight:!1,tables:!1,breaks:!1,pedantic:!1,sanitize:!0,smartLists:!0,smartypants:!1}),{SAFE_FOR_JQUERY:!0,ALLOWED_TAGS:["h1","h2","h3","h4","h5","h6","strong","p","a","ul","ol","li","em","del","blockquote"]})}}};var dt=n(37702),ct={};ct.styleTagTransform=Q(),ct.setAttributes=j(),ct.insert=z().bind(null,"head"),ct.domAPI=V(),ct.insertStyleElement=q(),O()(dt.Z,ct),dt.Z&&dt.Z.locals&&dt.Z.locals;const ut=(0,B.Z)(lt,(function(){var t=this;return(0,t._self._c)("div",{staticClass:"settings-markdown",domProps:{innerHTML:t._s(t.renderMarkdown)}})}),[],!1,null,"ffd9a2d6",null).exports,gt={name:"AppDetails",components:{NcMultiselect:it(),Markdown:ut},mixins:[L,X],props:{app:{type:Object,required:!0}},data:()=>({groupCheckedAppsData:!1}),computed:{appstoreUrl(){return"https://apps.nextcloud.com/apps/".concat(this.app.id)},licence(){return this.app.licence?t("settings","{license}-licensed",{license:(""+this.app.licence).toUpperCase()}):null},author(){return"string"==typeof this.app.author?[{"@value":this.app.author}]:this.app.author["@value"]?[this.app.author]:this.app.author},appGroups(){return this.app.groups.map((t=>({id:t,name:t})))},groups(){return this.$store.getters.getGroups.filter((t=>"disabled"!==t.id)).sort(((t,e)=>t.name.localeCompare(e.name)))}},mounted(){this.app.groups.length>0&&(this.groupCheckedAppsData=!0)}};var ht=n(81),At={};At.styleTagTransform=Q(),At.setAttributes=j(),At.insert=z().bind(null,"head"),At.domAPI=V(),At.insertStyleElement=q(),O()(ht.Z,At),ht.Z&&ht.Z.locals&&ht.Z.locals;const vt=(0,B.Z)(gt,(function(){var t=this,e=t._self._c;return e("div",{staticClass:"app-details"},[e("div",{staticClass:"app-details__actions"},[t.app.active&&t.canLimitToGroups(t.app)?e("div",{staticClass:"app-details__actions-groups"},[e("input",{directives:[{name:"model",rawName:"v-model",value:t.groupCheckedAppsData,expression:"groupCheckedAppsData"}],staticClass:"groups-enable__checkbox checkbox",attrs:{id:t.prefix("groups_enable",t.app.id),type:"checkbox"},domProps:{value:t.app.id,checked:Array.isArray(t.groupCheckedAppsData)?t._i(t.groupCheckedAppsData,t.app.id)>-1:t.groupCheckedAppsData},on:{change:[function(e){var a=t.groupCheckedAppsData,n=e.target,s=!!n.checked;if(Array.isArray(a)){var i=t.app.id,p=t._i(a,i);n.checked?p<0&&(t.groupCheckedAppsData=a.concat([i])):p>-1&&(t.groupCheckedAppsData=a.slice(0,p).concat(a.slice(p+1)))}else t.groupCheckedAppsData=s},t.setGroupLimit]}}),t._v(" "),e("label",{attrs:{for:t.prefix("groups_enable",t.app.id)}},[t._v(t._s(t.t("settings","Limit to groups")))]),t._v(" "),e("input",{staticClass:"group_select",attrs:{type:"hidden",title:t.t("settings","All"),value:""}}),t._v(" "),t.isLimitedToGroups(t.app)?e("NcMultiselect",{staticClass:"multiselect-vue",attrs:{options:t.groups,value:t.appGroups,"options-limit":5,placeholder:t.t("settings","Limit app usage to groups"),label:"name","track-by":"id",multiple:!0,"close-on-select":!1,"tag-width":60},on:{select:t.addGroupLimitation,remove:t.removeGroupLimitation,"search-change":t.asyncFindGroup}},[e("span",{attrs:{slot:"noResult"},slot:"noResult"},[t._v(t._s(t.t("settings","No results")))])]):t._e()],1):t._e(),t._v(" "),e("div",{staticClass:"app-details__actions-manage"},[t.app.update?e("input",{staticClass:"update primary",attrs:{type:"button",value:t.t("settings","Update to {version}",{version:t.app.update}),disabled:t.installing||t.isLoading},on:{click:function(e){return t.update(t.app.id)}}}):t._e(),t._v(" "),t.app.canUnInstall?e("input",{staticClass:"uninstall",attrs:{type:"button",value:t.t("settings","Remove"),disabled:t.installing||t.isLoading},on:{click:function(e){return t.remove(t.app.id)}}}):t._e(),t._v(" "),t.app.active?e("input",{staticClass:"enable",attrs:{type:"button",value:t.t("settings","Disable"),disabled:t.installing||t.isLoading},on:{click:function(e){return t.disable(t.app.id)}}}):t._e(),t._v(" "),t.app.active||!t.app.canInstall&&!t.app.isCompatible?t.app.active||t.app.canInstall?t._e():e("input",{staticClass:"enable force",attrs:{title:t.forceEnableButtonTooltip,"aria-label":t.forceEnableButtonTooltip,type:"button",value:t.forceEnableButtonText,disabled:t.installing||t.isLoading},on:{click:function(e){return t.forceEnable(t.app.id)}}}):e("input",{staticClass:"enable primary",attrs:{title:t.enableButtonTooltip,"aria-label":t.enableButtonTooltip,type:"button",value:t.enableButtonText,disabled:!t.app.canInstall||t.installing||t.isLoading},on:{click:function(e){return t.enable(t.app.id)}}})])]),t._v(" "),e("ul",{staticClass:"app-details__dependencies"},[t.app.missingMinOwnCloudVersion?e("li",[t._v("\n\t\t\t"+t._s(t.t("settings","This app has no minimum Nextcloud version assigned. This will be an error in the future."))+"\n\t\t")]):t._e(),t._v(" "),t.app.missingMaxOwnCloudVersion?e("li",[t._v("\n\t\t\t"+t._s(t.t("settings","This app has no maximum Nextcloud version assigned. This will be an error in the future."))+"\n\t\t")]):t._e(),t._v(" "),t.app.canInstall?t._e():e("li",[t._v("\n\t\t\t"+t._s(t.t("settings","This app cannot be installed because the following dependencies are not fulfilled:"))+"\n\t\t\t"),e("ul",{staticClass:"missing-dependencies"},t._l(t.app.missingDependencies,(function(a,n){return e("li",{key:n},[t._v("\n\t\t\t\t\t"+t._s(a)+"\n\t\t\t\t")])})),0)])]),t._v(" "),e("p",{staticClass:"app-details__documentation"},[t.app.internal?t._e():e("a",{staticClass:"appslink",attrs:{href:t.appstoreUrl,target:"_blank",rel:"noreferrer noopener"}},[t._v(t._s(t.t("settings","View in store"))+" ↗")]),t._v(" "),t.app.website?e("a",{staticClass:"appslink",attrs:{href:t.app.website,target:"_blank",rel:"noreferrer noopener"}},[t._v(t._s(t.t("settings","Visit website"))+" ↗")]):t._e(),t._v(" "),t.app.bugs?e("a",{staticClass:"appslink",attrs:{href:t.app.bugs,target:"_blank",rel:"noreferrer noopener"}},[t._v(t._s(t.t("settings","Report a bug"))+" ↗")]):t._e(),t._v(" "),t.app.documentation&&t.app.documentation.user?e("a",{staticClass:"appslink",attrs:{href:t.app.documentation.user,target:"_blank",rel:"noreferrer noopener"}},[t._v(t._s(t.t("settings","User documentation"))+" ↗")]):t._e(),t._v(" "),t.app.documentation&&t.app.documentation.admin?e("a",{staticClass:"appslink",attrs:{href:t.app.documentation.admin,target:"_blank",rel:"noreferrer noopener"}},[t._v(t._s(t.t("settings","Admin documentation"))+" ↗")]):t._e(),t._v(" "),t.app.documentation&&t.app.documentation.developer?e("a",{staticClass:"appslink",attrs:{href:t.app.documentation.developer,target:"_blank",rel:"noreferrer noopener"}},[t._v(t._s(t.t("settings","Developer documentation"))+" ↗")]):t._e()]),t._v(" "),e("Markdown",{staticClass:"app-details__description",attrs:{text:t.app.description}})],1)}),[],!1,null,"60e3cd51",null).exports;var mt=n(92652);i.default.use(r());const bt={name:"Apps",APPS_SECTION_ENUM:mt.J,components:{NcAppContent:l(),AppDetails:vt,AppList:nt,IconStarShooting:k.Z,NcAppNavigation:c(),NcAppNavigationCounter:g(),NcAppNavigationItem:A(),NcAppNavigationSpacer:m(),AppScore:D,NcAppSidebar:f(),NcAppSidebarTab:_(),NcContent:w(),Markdown:ut},mixins:[L],props:{category:{type:String,default:"installed"},id:{type:String,default:""}},data:()=>({searchQuery:"",screenshotLoaded:!1}),computed:{loading(){return this.$store.getters.loading("categories")},loadingList(){return this.$store.getters.loading("list")},app(){return this.apps.find((t=>t.id===this.id))},categories(){return this.$store.getters.getCategories},apps(){return this.$store.getters.getAllApps},updateCount(){return this.$store.getters.getUpdateCount},settings(){return this.$store.getters.getServerData},hasRating(){return this.app.appstoreData&&this.app.appstoreData.ratingNumOverall>5},appSidebar(){const e=t=>t["@value"]?t["@value"]:t,a=Array.isArray(this.app.author)?this.app.author.map(e).join(", "):e(this.app.author),n=t("settings","{license}-licensed",{license:(""+this.app.licence).toUpperCase()});return{subtitle:t("settings","by {author}\n{license}",{author:a,license:n}),background:this.app.screenshot&&this.screenshotLoaded?this.app.screenshot:this.app.preview,compact:!(this.app.screenshot&&this.screenshotLoaded),title:this.app.name}},changelog:()=>t=>t.translations.en.changelog,isSubscribed(){return this.apps.some((t=>300===t.level))}},watch:{category(){this.searchQuery=""},app(){var t,e;if(this.screenshotLoaded=!1,null!==(t=this.app)&&void 0!==t&&t.releases&&null!==(e=this.app)&&void 0!==e&&e.screenshot){const t=new Image;t.onload=t=>{this.screenshotLoaded=!0},t.src=this.app.screenshot}}},beforeMount(){this.$store.dispatch("getCategories",{shouldRefetchCategories:!0}),this.$store.dispatch("getAllApps"),this.$store.dispatch("getGroups",{offset:0,limit:5}),this.$store.commit("setUpdateCount",this.$store.getters.getServerData.updateCount)},mounted(){(0,s.Ld)("nextcloud:unified-search.search",this.setSearch),(0,s.Ld)("nextcloud:unified-search.reset",this.resetSearch)},beforeDestroy(){(0,s.r1)("nextcloud:unified-search.search",this.setSearch),(0,s.r1)("nextcloud:unified-search.reset",this.resetSearch)},methods:{setSearch(t){let{query:e}=t;this.searchQuery=e},resetSearch(){this.searchQuery=""},hideAppDetails(){this.$router.push({name:"apps-category",params:{category:this.category}})},openDeveloperDocumentation(){window.open(this.settings.developerDocumentation)}}};var ft=n(52411),Ct={};Ct.styleTagTransform=Q(),Ct.setAttributes=j(),Ct.insert=z().bind(null,"head"),Ct.domAPI=V(),Ct.insertStyleElement=q(),O()(ft.Z,Ct),ft.Z&&ft.Z.locals&&ft.Z.locals;const _t=(0,B.Z)(bt,(function(){var t=this,e=t._self._c;return e("NcContent",{class:{"with-app-sidebar":t.app},attrs:{"app-name":"settings","content-class":{"icon-loading":t.loadingList},"navigation-class":{"icon-loading":t.loading}}},[e("NcAppNavigation",{scopedSlots:t._u([{key:"list",fn:function(){return[e("NcAppNavigationItem",{attrs:{id:"app-category-your-apps",to:{name:"apps"},exact:!0,icon:"icon-category-installed",title:t.t("settings","Your apps")}}),t._v(" "),e("NcAppNavigationItem",{attrs:{id:"app-category-enabled",to:{name:"apps-category",params:{category:"enabled"}},icon:"icon-category-enabled",title:t.$options.APPS_SECTION_ENUM.enabled}}),t._v(" "),e("NcAppNavigationItem",{attrs:{id:"app-category-disabled",to:{name:"apps-category",params:{category:"disabled"}},icon:"icon-category-disabled",title:t.$options.APPS_SECTION_ENUM.disabled}}),t._v(" "),t.updateCount>0?e("NcAppNavigationItem",{attrs:{id:"app-category-updates",to:{name:"apps-category",params:{category:"updates"}},icon:"icon-download",title:t.$options.APPS_SECTION_ENUM.updates}},[e("NcAppNavigationCounter",{attrs:{slot:"counter"},slot:"counter"},[t._v("\n\t\t\t\t\t"+t._s(t.updateCount)+"\n\t\t\t\t")])],1):t._e(),t._v(" "),t.isSubscribed?e("NcAppNavigationItem",{attrs:{id:"app-category-supported",to:{name:"apps-category",params:{category:"supported"}},name:t.$options.APPS_SECTION_ENUM.supported},scopedSlots:t._u([{key:"icon",fn:function(){return[e("IconStarShooting",{attrs:{size:20}})]},proxy:!0}],null,!1,704374136)}):t._e(),t._v(" "),e("NcAppNavigationItem",{attrs:{id:"app-category-your-bundles",to:{name:"apps-category",params:{category:"app-bundles"}},icon:"icon-category-app-bundles",title:t.$options.APPS_SECTION_ENUM["app-bundles"]}}),t._v(" "),e("NcAppNavigationSpacer"),t._v(" "),t.settings.appstoreEnabled?[e("NcAppNavigationItem",{attrs:{id:"app-category-featured",to:{name:"apps-category",params:{category:"featured"}},icon:"icon-favorite",title:t.$options.APPS_SECTION_ENUM.featured}}),t._v(" "),t._l(t.categories,(function(t){return e("NcAppNavigationItem",{key:"icon-category-"+t.ident,attrs:{icon:"icon-category-"+t.ident,to:{name:"apps-category",params:{category:t.ident}},title:t.displayName}})}))]:t._e(),t._v(" "),e("NcAppNavigationItem",{attrs:{id:"app-developer-docs",title:t.t("settings","Developer documentation")+" ↗"},on:{click:t.openDeveloperDocumentation}})]},proxy:!0}])}),t._v(" "),e("NcAppContent",{staticClass:"app-settings-content",class:{"icon-loading":t.loadingList}},[e("AppList",{attrs:{category:t.category,app:t.app,search:t.searchQuery}})],1),t._v(" "),t.id&&t.app?e("NcAppSidebar",t._b({class:{"app-sidebar--without-background":!t.appSidebar.background},on:{close:t.hideAppDetails},scopedSlots:t._u([t.appSidebar.background?null:{key:"header",fn:function(){return[e("div",{staticClass:"app-sidebar-header__figure--default-app-icon icon-settings-dark"})]},proxy:!0},{key:"description",fn:function(){return[300===t.app.level||200===t.app.level||t.hasRating?e("div",{staticClass:"app-level"},[300===t.app.level?e("span",{staticClass:"supported icon-checkmark-color",attrs:{title:t.t("settings","This app is supported via your current Nextcloud subscription.")}},[t._v("\n\t\t\t\t\t"+t._s(t.t("settings","Supported")))]):t._e(),t._v(" "),200===t.app.level?e("span",{staticClass:"official icon-checkmark",attrs:{title:t.t("settings","Featured apps are developed by and within the community. They offer central functionality and are ready for production use.")}},[t._v("\n\t\t\t\t\t"+t._s(t.t("settings","Featured")))]):t._e(),t._v(" "),t.hasRating?e("AppScore",{attrs:{score:t.app.appstoreData.ratingOverall}}):t._e()],1):t._e(),t._v(" "),e("div",{staticClass:"app-version"},[e("p",[t._v(t._s(t.app.version))])])]},proxy:!0}],null,!0)},"NcAppSidebar",t.appSidebar,!1),[t._v(" "),t._v(" "),e("NcAppSidebarTab",{attrs:{id:"desc",icon:"icon-category-office",name:t.t("settings","Details"),order:0}},[e("AppDetails",{attrs:{app:t.app}})],1),t._v(" "),t.app.appstoreData&&t.app.releases[0].translations.en.changelog?e("NcAppSidebarTab",{attrs:{id:"desca",icon:"icon-category-organization",name:t.t("settings","Changelog"),order:1}},t._l(t.app.releases,(function(a){return e("div",{key:a.version,staticClass:"app-sidebar-tabs__release"},[e("h2",[t._v(t._s(a.version))]),t._v(" "),t.changelog(a)?e("Markdown",{attrs:{text:t.changelog(a)}}):t._e()],1)})),0):t._e()],1):t._e()],1)}),[],!1,null,"ce9b8b58",null).exports}}]);
  2. //# sourceMappingURL=settings-apps-view-7418.js.map?v=4ade86747cf564489847