settings-apps-view-7418.js 43 KB

12
  1. "use strict";(self.webpackChunknextcloud=self.webpackChunknextcloud||[]).push([[7418],{87194:(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-09bfa13d]{padding:20px}.app-details__actions-manage[data-v-09bfa13d]{display:flex}.app-details__actions-manage input[data-v-09bfa13d]{flex:0 1 auto;min-width:0;text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.app-details__dependencies[data-v-09bfa13d]{opacity:.7}.app-details__documentation[data-v-09bfa13d]{padding-top:20px}.app-details__description[data-v-09bfa13d]{padding-top:20px}.force[data-v-09bfa13d]{color:var(--color-error);border-color:var(--color-error);background:var(--color-main-background)}.force[data-v-09bfa13d]:hover,.force[data-v-09bfa13d]: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,CAED,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}\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},44680:(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-652eb552] h1,.settings-markdown[data-v-652eb552] h2,.settings-markdown[data-v-652eb552] h3,.settings-markdown[data-v-652eb552] h4,.settings-markdown[data-v-652eb552] h5,.settings-markdown[data-v-652eb552] h6{font-weight:600;line-height:120%;margin-top:24px;margin-bottom:12px;color:var(--color-main-text)}.settings-markdown[data-v-652eb552] h1{font-size:36px;margin-top:48px}.settings-markdown[data-v-652eb552] h2{font-size:28px;margin-top:48px}.settings-markdown[data-v-652eb552] h3{font-size:24px}.settings-markdown[data-v-652eb552] h4{font-size:21px}.settings-markdown[data-v-652eb552] h5{font-size:17px}.settings-markdown[data-v-652eb552] h6{font-size:var(--default-font-size)}.settings-markdown[data-v-652eb552] 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-652eb552] p code{background-color:var(--color-background-dark);border-radius:var(--border-radius);padding:.1em .3em}.settings-markdown[data-v-652eb552] li{position:relative}.settings-markdown[data-v-652eb552] ul,.settings-markdown[data-v-652eb552] ol{padding-left:10px;margin-left:10px}.settings-markdown[data-v-652eb552] ul li{list-style-type:disc}.settings-markdown[data-v-652eb552] ul>li>ul>li{list-style-type:circle}.settings-markdown[data-v-652eb552] ul>li>ul>li ul li{list-style-type:square}.settings-markdown[data-v-652eb552] 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},38938:(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-58c9cb1e]:not(.app-sidebar--without-background) :not(.app-sidebar-header--compact) .app-sidebar-header__figure{background-size:cover}.app-sidebar[data-v-58c9cb1e]: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-58c9cb1e] .app-sidebar-header__description .app-version{padding-left:10px}.app-sidebar[data-v-58c9cb1e].app-sidebar--without-background .app-sidebar-header__figure{display:flex;align-items:center;justify-content:center}.app-sidebar[data-v-58c9cb1e].app-sidebar--without-background .app-sidebar-header__figure--default-app-icon{width:32px;height:32px;background-size:32px}.app-sidebar[data-v-58c9cb1e] .app-sidebar-header__desc .app-sidebar-header__subtitle{overflow:visible !important;height:auto;white-space:normal !important;line-height:16px}.app-sidebar[data-v-58c9cb1e] .app-sidebar-header__action{margin:0 20px}.app-sidebar[data-v-58c9cb1e] .app-sidebar-header__action input{margin:3px}.app-navigation[data-v-58c9cb1e] button.app-navigation-toggle{top:8px;right:-8px}.app-sidebar-tabs__release h2[data-v-58c9cb1e]{border-bottom:1px solid var(--color-border)}.app-sidebar-tabs__release[data-v-58c9cb1e] h3{font-size:20px}.app-sidebar-tabs__release[data-v-58c9cb1e] 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},72845:(e,a,n)=>{n.r(a),n.d(a,{default:()=>ft});var s=n(78595),i=n(20144),p=n(87369),r=n.n(p),o=n(69680),l=n.n(o),c=n(55209),d=n.n(c),u=n(53110),h=n.n(u),g=n(14032),A=n.n(g),v=n(47493),m=n.n(v),b=n(10250),C=n.n(b),f=n(62574),_=n.n(f),y=n(27472),w=n.n(y),k=n(79753);const x={name:"AppScore",props:["score"],computed:{scoreImage(){const t="rating/s"+Math.round(10*this.score)+".svg";return(0,k.imagePath)("core",t)}}};var N=n(51900);const B=(0,N.Z)(x,(function(){return(0,this._self._c)("img",{staticClass:"app-score-image",attrs:{src:this.scoreImage}})}),[],!1,null,null,null).exports;var D=n(64024),T=n(4820);const S=()=>T.default.get((0,k.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")))})),I={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=>{S()})).catch((t=>{(0,D.x2)(t)}))},enable(t){this.$store.dispatch("enableApp",{appId:t,groups:[]}).then((t=>{S()})).catch((t=>{(0,D.x2)(t)}))},disable(t){this.$store.dispatch("disableApp",{appId:t}).then((t=>{S()})).catch((t=>{(0,D.x2)(t)}))},remove(t){this.$store.dispatch("uninstallApp",{appId:t}).then((t=>{S()})).catch((t=>{(0,D.x2)(t)}))},install(t){this.$store.dispatch("enableApp",{appId:t}).then((t=>{S()})).catch((t=>{(0,D.x2)(t)}))},update(t){this.$store.dispatch("updateApp",{appId:t}).then((t=>{S()})).catch((t=>{(0,D.x2)(t)}))}}},L={name:"SvgFilterMixin",data:()=>({filterId:""}),computed:{filterUrl(){return"url(#".concat(this.filterId,")")}},mounted(){this.filterId="invertIconApps-"+Math.random().toString(36).substring(2)}},E=(0,N.Z)(L,void 0,void 0,!1,null,null,null).exports;var U=n(10861),G=n.n(U);const $={name:"AppItem",components:{AppScore:B,NcButton:G()},mixins:[I,E],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 M=n(93379),P=n.n(M),R=n(7795),V=n.n(R),O=n(90569),Z=n.n(O),z=n(3565),F=n.n(z),j=n(19216),Y=n.n(j),q=n(44589),H=n.n(q),Q=n(28952),W={};W.styleTagTransform=H(),W.setAttributes=F(),W.insert=Z().bind(null,"head"),W.domAPI=V(),W.insertStyleElement=Y(),P()(Q.Z,W),Q.Z&&Q.Z.locals&&Q.Z.locals;const J=(0,N.Z)($,(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,K=(0,N.Z)({name:"PrefixMixin",methods:{prefix:(t,e)=>t+"_"+e}},void 0,void 0,!1,null,null,null).exports;var X=n(63560),tt=n(25108);const et={name:"AppList",components:{AppItem:J,NcButton:G()},mixins:[K],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)):"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},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=>{tt.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,X.Z)(1);this.apps.filter((t=>t.update)).map((e=>t((()=>this.$store.dispatch("updateApp",{appId:e.id})))))}}},at=(0,N.Z)(et,(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 nt=n(98266),st=n.n(nt),it=n(87441),pt=n(27856),rt=n.n(pt);const ot={name:"Markdown",props:{text:{type:String,default:""}},computed:{renderMarkdown(){const t=new it.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},rt().sanitize((0,it.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 lt=n(44680),ct={};ct.styleTagTransform=H(),ct.setAttributes=F(),ct.insert=Z().bind(null,"head"),ct.domAPI=V(),ct.insertStyleElement=Y(),P()(lt.Z,ct),lt.Z&&lt.Z.locals&&lt.Z.locals;const dt=(0,N.Z)(ot,(function(){var t=this;return(0,t._self._c)("div",{staticClass:"settings-markdown",domProps:{innerHTML:t._s(t.renderMarkdown)}})}),[],!1,null,"652eb552",null).exports,ut={name:"AppDetails",components:{NcMultiselect:st(),Markdown:dt},mixins:[I,K],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(87194),gt={};gt.styleTagTransform=H(),gt.setAttributes=F(),gt.insert=Z().bind(null,"head"),gt.domAPI=V(),gt.insertStyleElement=Y(),P()(ht.Z,gt),ht.Z&&ht.Z.locals&&ht.Z.locals;const At=(0,N.Z)(ut,(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,"09bfa13d",null).exports;var vt=n(92652);i.default.use(r());const mt={name:"Apps",APPS_SECTION_ENUM:vt.J,components:{NcAppContent:l(),AppDetails:At,AppList:at,NcAppNavigation:d(),NcAppNavigationCounter:h(),NcAppNavigationItem:A(),NcAppNavigationSpacer:m(),AppScore:B,NcAppSidebar:C(),NcAppSidebarTab:_(),NcContent:w(),Markdown:dt},mixins:[I],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},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 bt=n(38938),Ct={};Ct.styleTagTransform=H(),Ct.setAttributes=F(),Ct.insert=Z().bind(null,"head"),Ct.domAPI=V(),Ct.insertStyleElement=Y(),P()(bt.Z,Ct),bt.Z&&bt.Z.locals&&bt.Z.locals;const ft=(0,N.Z)(mt,(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(" "),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,"58c9cb1e",null).exports}}]);
  2. //# sourceMappingURL=settings-apps-view-7418.js.map?v=faf2213249ab04354b2e