files-personal-settings.js.map 34 KB

1
  1. {"version":3,"file":"files-personal-settings.js?v=00b0627ff83260d86ceb","mappings":";6BAAIA,+BC0BcC,+HAYlB,EAXc,QADIA,GAYOC,EAAAA,EAAAA,oBAVhBC,EAAAA,EAAAA,MACLC,OAAO,SACPC,SAEIF,EAAAA,EAAAA,MACLC,OAAO,SACPE,OAAOL,EAAKM,KACZF,iIC2CH,iEACA,mBACA,aACA,WACA,mBACA,QAEA,GACA,iCACA,YACA,kBACA,cAEA,KANA,WAOA,OACA,iBACA,4BACA,mBACA,gBACA,kBACA,mBACA,QACA,kFAGA,EACA,UACA,UADA,WAEA,2CACA,EACA,wBAJA,WAIA,WACA,0DACA,2BACA,OACA,WACA,0BACA,iBAEA,GACA,EACA,iBAdA,WAeA,mBACA,6BAEA,wCACA,yGACA,EACA,kBArBA,WAsBA,sBAGA,4BAFA,EAGA,GAEA,QA/CA,WAgDA,8CACA,iBACA,EACA,SACA,MADA,WACA,WACA,iCAEA,SACA,wCACA,kBAEA,GADA,mEACA,kBACA,oDAIA,aACA,uBACA,gGAEA,4DACA,GACA,EACA,SApBA,SAoBA,wJACA,mBAEA,yCAHA,wDAOA,kBAPA,kBASA,yEACA,QACA,cACA,gBACA,SACA,WACA,aAfA,OASA,EATA,OAmBA,qBACA,+EACA,8CACA,sBACA,qBAEA,IAzBA,kDA2BA,8CA3BA,yBA6BA,kBA7BA,4PA+BA,EACA,OApDA,WAoDA,WACA,gBACA,+BAGA,wBACA,OACA,oBACA,kCAEA,4CAEA,kEAEA,oBACA,mCACA,kBACA,mDAEA,mBACA,qBACA,qDACA,IACA,yBACA,+DAEA,mEACA,wFAEA,mDAEA,GACA,IC5NsM,qICWlMG,EAAU,CAAC,EAEfA,EAAQC,kBAAoB,IAC5BD,EAAQE,cAAgB,IAElBF,EAAQG,OAAS,SAAc,KAAM,QAE3CH,EAAQI,OAAS,IACjBJ,EAAQK,mBAAqB,IAEhB,IAAI,IAASL,GAKJ,KAAW,YAAiB,WALlD,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AAEU,EAAI,SAASqC,GAAW,OAAoC,IAA7BD,EAAgBC,EAAgB,EAGrF,IAAIC,EAAuB,SAASC,EAA4BC,GAC/D,IAKI5D,EAAUyD,EALV7C,EAAWgD,EAAK,GAChBC,EAAcD,EAAK,GACnBE,EAAUF,EAAK,GAGI3C,EAAI,EAC3B,GAAGL,EAASmD,MAAK,SAASlE,GAAM,OAA+B,IAAxB2D,EAAgB3D,EAAW,IAAI,CACrE,IAAIG,KAAY6D,EACZ9D,EAAoBkC,EAAE4B,EAAa7D,KACrCD,EAAoBO,EAAEN,GAAY6D,EAAY7D,IAGhD,GAAG8D,EAAS,IAAInD,EAASmD,EAAQ/D,EAClC,CAEA,IADG4D,GAA4BA,EAA2BC,GACrD3C,EAAIL,EAASM,OAAQD,IACzBwC,EAAU7C,EAASK,GAChBlB,EAAoBkC,EAAEuB,EAAiBC,IAAYD,EAAgBC,IACrED,EAAgBC,GAAS,KAE1BD,EAAgBC,GAAW,EAE5B,OAAO1D,EAAoBW,EAAEC,EAC9B,EAEIqD,EAAqBX,KAA4B,sBAAIA,KAA4B,uBAAK,GAC1FW,EAAmBC,QAAQP,EAAqBQ,KAAK,KAAM,IAC3DF,EAAmBrE,KAAO+D,EAAqBQ,KAAK,KAAMF,EAAmBrE,KAAKuE,KAAKF,OClDvFjE,EAAoBoE,QAAKnG,ECGzB,IAAIoG,EAAsBrE,EAAoBW,OAAE1C,EAAW,CAAC,OAAO,WAAa,OAAO+B,EAAoB,MAAQ,IACnHqE,EAAsBrE,EAAoBW,EAAE0D","sources":["webpack:///nextcloud/webpack/runtime/chunk loaded","webpack:///nextcloud/apps/files/src/logger.js","webpack:///nextcloud/apps/files/src/components/TransferOwnershipDialogue.vue","webpack:///nextcloud/apps/files/src/components/TransferOwnershipDialogue.vue?vue&type=script&lang=js&","webpack://nextcloud/./apps/files/src/components/TransferOwnershipDialogue.vue?0ad7","webpack://nextcloud/./apps/files/src/components/TransferOwnershipDialogue.vue?2a1f","webpack://nextcloud/./apps/files/src/components/TransferOwnershipDialogue.vue?6355","webpack:///nextcloud/apps/files/src/components/PersonalSettings.vue?vue&type=script&lang=js&","webpack:///nextcloud/apps/files/src/components/PersonalSettings.vue","webpack://nextcloud/./apps/files/src/components/PersonalSettings.vue?7d7e","webpack://nextcloud/./apps/files/src/components/PersonalSettings.vue?3bbf","webpack:///nextcloud/apps/files/src/main-personal-settings.js","webpack:///nextcloud/apps/files/src/components/TransferOwnershipDialogue.vue?vue&type=style&index=0&id=0efa77f2&prod&scoped=true&lang=scss&","webpack:///nextcloud/webpack/bootstrap","webpack:///nextcloud/webpack/runtime/amd define","webpack:///nextcloud/webpack/runtime/amd options","webpack:///nextcloud/webpack/runtime/compat get default export","webpack:///nextcloud/webpack/runtime/define property getters","webpack:///nextcloud/webpack/runtime/global","webpack:///nextcloud/webpack/runtime/hasOwnProperty shorthand","webpack:///nextcloud/webpack/runtime/make namespace object","webpack:///nextcloud/webpack/runtime/node module decorator","webpack:///nextcloud/webpack/runtime/runtimeId","webpack:///nextcloud/webpack/runtime/jsonp chunk loading","webpack:///nextcloud/webpack/runtime/nonce","webpack:///nextcloud/webpack/startup"],"sourcesContent":["var deferred = [];\n__webpack_require__.O = function(result, chunkIds, fn, priority) {\n\tif(chunkIds) {\n\t\tpriority = priority || 0;\n\t\tfor(var i = deferred.length; i > 0 && deferred[i - 1][2] > priority; i--) deferred[i] = deferred[i - 1];\n\t\tdeferred[i] = [chunkIds, fn, priority];\n\t\treturn;\n\t}\n\tvar notFulfilled = Infinity;\n\tfor (var i = 0; i < deferred.length; i++) {\n\t\tvar chunkIds = deferred[i][0];\n\t\tvar fn = deferred[i][1];\n\t\tvar priority = deferred[i][2];\n\t\tvar fulfilled = true;\n\t\tfor (var j = 0; j < chunkIds.length; j++) {\n\t\t\tif ((priority & 1 === 0 || notFulfilled >= priority) && Object.keys(__webpack_require__.O).every(function(key) { return __webpack_require__.O[key](chunkIds[j]); })) {\n\t\t\t\tchunkIds.splice(j--, 1);\n\t\t\t} else {\n\t\t\t\tfulfilled = false;\n\t\t\t\tif(priority < notFulfilled) notFulfilled = priority;\n\t\t\t}\n\t\t}\n\t\tif(fulfilled) {\n\t\t\tdeferred.splice(i--, 1)\n\t\t\tvar r = fn();\n\t\t\tif (r !== undefined) result = r;\n\t\t}\n\t}\n\treturn result;\n};","/**\n * @copyright 2019 Christoph Wurst <christoph@winzerhof-wurst.at>\n *\n * @author Christoph Wurst <christoph@winzerhof-wurst.at>\n * @author Roeland Jago Douma <roeland@famdouma.nl>\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 { getCurrentUser } from '@nextcloud/auth'\nimport { getLoggerBuilder } from '@nextcloud/logger'\n\nconst getLogger = user => {\n\tif (user === null) {\n\t\treturn getLoggerBuilder()\n\t\t\t.setApp('files')\n\t\t\t.build()\n\t}\n\treturn getLoggerBuilder()\n\t\t.setApp('files')\n\t\t.setUid(user.uid)\n\t\t.build()\n}\n\nexport default getLogger(getCurrentUser())\n","<!--\n - @copyright 2019 Christoph Wurst <christoph@winzerhof-wurst.at>\n -\n - @author 2019 Christoph Wurst <christoph@winzerhof-wurst.at>\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\n<template>\n\t<div>\n\t\t<h3>{{ t('files', 'Transfer ownership of a file or folder') }} </h3>\n\t\t<form @submit.prevent=\"submit\">\n\t\t\t<p class=\"transfer-select-row\">\n\t\t\t\t<span>{{ readableDirectory }}</span>\n\t\t\t\t<NcButton v-if=\"directory === undefined\" @click.prevent=\"start\">\n\t\t\t\t\t{{ t('files', 'Choose file or folder to transfer') }}\n\t\t\t\t</NcButton>\n\t\t\t\t<NcButton v-else @click.prevent=\"start\">\n\t\t\t\t\t{{ t('files', 'Change') }}\n\t\t\t\t</NcButton>\n\t\t\t\t<span class=\"error\">{{ directoryPickerError }}</span>\n\t\t\t</p>\n\t\t\t<p class=\"new-owner-row\">\n\t\t\t\t<label for=\"targetUser\">\n\t\t\t\t\t<span>{{ t('files', 'New owner') }}</span>\n\t\t\t\t</label>\n\t\t\t\t<NcMultiselect id=\"targetUser\"\n\t\t\t\t\tv-model=\"selectedUser\"\n\t\t\t\t\t:options=\"formatedUserSuggestions\"\n\t\t\t\t\t:multiple=\"false\"\n\t\t\t\t\t:searchable=\"true\"\n\t\t\t\t\t:placeholder=\"t('files', 'Search users')\"\n\t\t\t\t\t:preselect-first=\"true\"\n\t\t\t\t\t:preserve-search=\"true\"\n\t\t\t\t\t:loading=\"loadingUsers\"\n\t\t\t\t\ttrack-by=\"user\"\n\t\t\t\t\tlabel=\"displayName\"\n\t\t\t\t\t:internal-search=\"false\"\n\t\t\t\t\t:clear-on-select=\"false\"\n\t\t\t\t\t:user-select=\"true\"\n\t\t\t\t\tclass=\"middle-align\"\n\t\t\t\t\t@search-change=\"findUserDebounced\" />\n\t\t\t</p>\n\t\t\t<p>\n\t\t\t\t<input type=\"submit\"\n\t\t\t\t\tclass=\"primary\"\n\t\t\t\t\t:value=\"submitButtonText\"\n\t\t\t\t\t:disabled=\"!canSubmit\">\n\t\t\t\t<span class=\"error\">{{ submitError }}</span>\n\t\t\t</p>\n\t\t</form>\n\t</div>\n</template>\n\n<script>\nimport axios from '@nextcloud/axios'\nimport debounce from 'debounce'\nimport { generateOcsUrl } from '@nextcloud/router'\nimport { getFilePickerBuilder, showSuccess } from '@nextcloud/dialogs'\nimport NcMultiselect from '@nextcloud/vue/dist/Components/NcMultiselect'\nimport Vue from 'vue'\nimport NcButton from '@nextcloud/vue/dist/Components/NcButton'\n\nimport logger from '../logger'\n\nconst picker = getFilePickerBuilder(t('files', 'Choose a file or folder to transfer'))\n\t.setMultiSelect(false)\n\t.setModal(true)\n\t.setType(1)\n\t.allowDirectories()\n\t.build()\n\nexport default {\n\tname: 'TransferOwnershipDialogue',\n\tcomponents: {\n\t\tNcMultiselect,\n\t\tNcButton,\n\t},\n\tdata() {\n\t\treturn {\n\t\t\tdirectory: undefined,\n\t\t\tdirectoryPickerError: undefined,\n\t\t\tsubmitError: undefined,\n\t\t\tloadingUsers: false,\n\t\t\tselectedUser: null,\n\t\t\tuserSuggestions: {},\n\t\t\tconfig: {\n\t\t\t\tminSearchStringLength: parseInt(OC.config['sharing.minSearchStringLength'], 10) || 0,\n\t\t\t},\n\t\t}\n\t},\n\tcomputed: {\n\t\tcanSubmit() {\n\t\t\treturn !!this.directory && !!this.selectedUser\n\t\t},\n\t\tformatedUserSuggestions() {\n\t\t\treturn Object.keys(this.userSuggestions).map((uid) => {\n\t\t\t\tconst user = this.userSuggestions[uid]\n\t\t\t\treturn {\n\t\t\t\t\tuser: user.uid,\n\t\t\t\t\tdisplayName: user.displayName,\n\t\t\t\t\ticon: 'icon-user',\n\t\t\t\t}\n\t\t\t})\n\t\t},\n\t\tsubmitButtonText() {\n\t\t\tif (!this.canSubmit) {\n\t\t\t\treturn t('files', 'Transfer')\n\t\t\t}\n\t\t\tconst components = this.readableDirectory.split('/')\n\t\t\treturn t('files', 'Transfer {path} to {userid}', { path: components[components.length - 1], userid: this.selectedUser.displayName })\n\t\t},\n\t\treadableDirectory() {\n\t\t\tif (!this.directory) {\n\t\t\t\treturn ''\n\t\t\t}\n\t\t\treturn this.directory.substring(1)\n\t\t},\n\t},\n\tcreated() {\n\t\tthis.findUserDebounced = debounce(this.findUser, 300)\n\t\tthis.findUser('')\n\t},\n\tmethods: {\n\t\tstart() {\n\t\t\tthis.directoryPickerError = undefined\n\n\t\t\tpicker.pick()\n\t\t\t\t.then(dir => dir === '' ? '/' : dir)\n\t\t\t\t.then(dir => {\n\t\t\t\t\tlogger.debug(`path ${dir} selected for transferring ownership`)\n\t\t\t\t\tif (!dir.startsWith('/')) {\n\t\t\t\t\t\tthrow new Error(t('files', 'Invalid path selected'))\n\t\t\t\t\t}\n\t\t\t\t\t// /ocs/v2.php/apps/files/api/v1/transferownership\n\t\t\t\t\t// /ocs/v2.php/apps/files/api/v1/transferownership\n\t\t\t\t\tthis.directory = dir\n\t\t\t\t}).catch(error => {\n\t\t\t\t\tlogger.error(`Selecting object for transfer aborted: ${error.message || 'Unknown error'}`, { error })\n\n\t\t\t\t\tthis.directoryPickerError = error.message || t('files', 'Unknown error')\n\t\t\t\t})\n\t\t},\n\t\tasync findUser(query) {\n\t\t\tthis.query = query.trim()\n\n\t\t\tif (query.length < this.config.minSearchStringLength) {\n\t\t\t\treturn\n\t\t\t}\n\n\t\t\tthis.loadingUsers = true\n\t\t\ttry {\n\t\t\t\tconst response = await axios.get(generateOcsUrl('apps/files_sharing/api/v1/sharees'), {\n\t\t\t\t\tparams: {\n\t\t\t\t\t\tformat: 'json',\n\t\t\t\t\t\titemType: 'file',\n\t\t\t\t\t\tsearch: query,\n\t\t\t\t\t\tperPage: 20,\n\t\t\t\t\t\tlookup: false,\n\t\t\t\t\t},\n\t\t\t\t})\n\n\t\t\t\tthis.userSuggestions = {}\n\t\t\t\tresponse.data.ocs.data.exact.users.concat(response.data.ocs.data.users).forEach(user => {\n\t\t\t\t\tVue.set(this.userSuggestions, user.value.shareWith, {\n\t\t\t\t\t\tuid: user.value.shareWith,\n\t\t\t\t\t\tdisplayName: user.label,\n\t\t\t\t\t})\n\t\t\t\t})\n\t\t\t} catch (error) {\n\t\t\t\tlogger.error('could not fetch users', { error })\n\t\t\t} finally {\n\t\t\t\tthis.loadingUsers = false\n\t\t\t}\n\t\t},\n\t\tsubmit() {\n\t\t\tif (!this.canSubmit) {\n\t\t\t\tlogger.warn('ignoring form submit')\n\t\t\t}\n\n\t\t\tthis.submitError = undefined\n\t\t\tconst data = {\n\t\t\t\tpath: this.directory,\n\t\t\t\trecipient: this.selectedUser.user,\n\t\t\t}\n\t\t\tlogger.debug('submit transfer ownership form', data)\n\n\t\t\tconst url = generateOcsUrl('apps/files/api/v1/transferownership')\n\n\t\t\taxios.post(url, data)\n\t\t\t\t.then(resp => resp.data)\n\t\t\t\t.then(data => {\n\t\t\t\t\tlogger.info('Transfer ownership request sent', { data })\n\n\t\t\t\t\tthis.directory = undefined\n\t\t\t\t\tthis.selectedUser = null\n\t\t\t\t\tshowSuccess(t('files', 'Ownership transfer request sent'))\n\t\t\t\t})\n\t\t\t\t.catch(error => {\n\t\t\t\t\tlogger.error('Could not send ownership transfer request', { error })\n\n\t\t\t\t\tif (error?.response?.status === 403) {\n\t\t\t\t\t\tthis.submitError = t('files', 'Cannot transfer ownership of a file or folder you do not own')\n\t\t\t\t\t} else {\n\t\t\t\t\t\tthis.submitError = error.message || t('files', 'Unknown error')\n\t\t\t\t\t}\n\t\t\t\t})\n\t\t},\n\t},\n}\n</script>\n\n<style scoped lang=\"scss\">\n.middle-align {\n\tvertical-align: middle;\n}\np {\n\tmargin-top: 12px;\n\tmargin-bottom: 12px;\n}\n.new-owner-row {\n\tdisplay: flex;\n\n\tlabel {\n\t\tdisplay: flex;\n\t\talign-items: center;\n\n\t\tspan {\n\t\t\tmargin-right: 8px;\n\t\t}\n\t}\n\n\t.multiselect {\n\t\tflex-grow: 1;\n\t\tmax-width: 280px;\n\t}\n}\n.transfer-select-row {\n\tspan {\n\t\tmargin-right: 8px;\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!./TransferOwnershipDialogue.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!./TransferOwnershipDialogue.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/sass-loader/dist/cjs.js!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./TransferOwnershipDialogue.vue?vue&type=style&index=0&id=0efa77f2&prod&scoped=true&lang=scss&\";\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/sass-loader/dist/cjs.js!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./TransferOwnershipDialogue.vue?vue&type=style&index=0&id=0efa77f2&prod&scoped=true&lang=scss&\";\n export default content && content.locals ? content.locals : undefined;\n","import { render, staticRenderFns } from \"./TransferOwnershipDialogue.vue?vue&type=template&id=0efa77f2&scoped=true&\"\nimport script from \"./TransferOwnershipDialogue.vue?vue&type=script&lang=js&\"\nexport * from \"./TransferOwnershipDialogue.vue?vue&type=script&lang=js&\"\nimport style0 from \"./TransferOwnershipDialogue.vue?vue&type=style&index=0&id=0efa77f2&prod&scoped=true&lang=scss&\"\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 \"0efa77f2\",\n null\n \n)\n\nexport default component.exports","var render = function render(){var _vm=this,_c=_vm._self._c;return _c('div',[_c('h3',[_vm._v(_vm._s(_vm.t('files', 'Transfer ownership of a file or folder'))+\" \")]),_vm._v(\" \"),_c('form',{on:{\"submit\":function($event){$event.preventDefault();return _vm.submit.apply(null, arguments)}}},[_c('p',{staticClass:\"transfer-select-row\"},[_c('span',[_vm._v(_vm._s(_vm.readableDirectory))]),_vm._v(\" \"),(_vm.directory === undefined)?_c('NcButton',{on:{\"click\":function($event){$event.preventDefault();return _vm.start.apply(null, arguments)}}},[_vm._v(\"\\n\\t\\t\\t\\t\"+_vm._s(_vm.t('files', 'Choose file or folder to transfer'))+\"\\n\\t\\t\\t\")]):_c('NcButton',{on:{\"click\":function($event){$event.preventDefault();return _vm.start.apply(null, arguments)}}},[_vm._v(\"\\n\\t\\t\\t\\t\"+_vm._s(_vm.t('files', 'Change'))+\"\\n\\t\\t\\t\")]),_vm._v(\" \"),_c('span',{staticClass:\"error\"},[_vm._v(_vm._s(_vm.directoryPickerError))])],1),_vm._v(\" \"),_c('p',{staticClass:\"new-owner-row\"},[_c('label',{attrs:{\"for\":\"targetUser\"}},[_c('span',[_vm._v(_vm._s(_vm.t('files', 'New owner')))])]),_vm._v(\" \"),_c('NcMultiselect',{staticClass:\"middle-align\",attrs:{\"id\":\"targetUser\",\"options\":_vm.formatedUserSuggestions,\"multiple\":false,\"searchable\":true,\"placeholder\":_vm.t('files', 'Search users'),\"preselect-first\":true,\"preserve-search\":true,\"loading\":_vm.loadingUsers,\"track-by\":\"user\",\"label\":\"displayName\",\"internal-search\":false,\"clear-on-select\":false,\"user-select\":true},on:{\"search-change\":_vm.findUserDebounced},model:{value:(_vm.selectedUser),callback:function ($$v) {_vm.selectedUser=$$v},expression:\"selectedUser\"}})],1),_vm._v(\" \"),_c('p',[_c('input',{staticClass:\"primary\",attrs:{\"type\":\"submit\",\"disabled\":!_vm.canSubmit},domProps:{\"value\":_vm.submitButtonText}}),_vm._v(\" \"),_c('span',{staticClass:\"error\"},[_vm._v(_vm._s(_vm.submitError))])])])])\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","import mod from \"-!../../../../node_modules/babel-loader/lib/index.js!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./PersonalSettings.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!./PersonalSettings.vue?vue&type=script&lang=js&\"","<!--\n - @copyright 2019 Christoph Wurst <christoph@winzerhof-wurst.at>\n -\n - @author 2019 Christoph Wurst <christoph@winzerhof-wurst.at>\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\n<template>\n\t<div id=\"files-personal-settings\" class=\"section\">\n\t\t<h2>{{ t('files', 'Files') }}</h2>\n\t\t<TransferOwnershipDialogue />\n\t</div>\n</template>\n\n<script>\nimport TransferOwnershipDialogue from './TransferOwnershipDialogue'\n\nexport default {\n\tname: 'PersonalSettings',\n\tcomponents: {\n\t\tTransferOwnershipDialogue,\n\t},\n}\n</script>\n","import { render, staticRenderFns } from \"./PersonalSettings.vue?vue&type=template&id=cd18d6bc&\"\nimport script from \"./PersonalSettings.vue?vue&type=script&lang=js&\"\nexport * from \"./PersonalSettings.vue?vue&type=script&lang=js&\"\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 null,\n null\n \n)\n\nexport default component.exports","var render = function render(){var _vm=this,_c=_vm._self._c;return _c('div',{staticClass:\"section\",attrs:{\"id\":\"files-personal-settings\"}},[_c('h2',[_vm._v(_vm._s(_vm.t('files', 'Files')))]),_vm._v(\" \"),_c('TransferOwnershipDialogue')],1)\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","/**\n * @copyright 2019 Christoph Wurst <christoph@winzerhof-wurst.at>\n * @copyright 2019 Christoph Wurst <christoph@winzerhof-wurst.at>\n * @copyright 2019 Christoph Wurst <christoph@winzerhof-wurst.at>\n *\n * @author Roeland Jago Douma <roeland@famdouma.nl>\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 Vue from 'vue'\nimport { getRequestToken } from '@nextcloud/auth'\n\nimport PersonalSettings from './components/PersonalSettings'\n\n// eslint-disable-next-line camelcase\n__webpack_nonce__ = btoa(getRequestToken())\n\nVue.prototype.t = t\n\nif (!window.TESTING) {\n\tconst View = Vue.extend(PersonalSettings)\n\tnew View().$mount('#files-personal-settings')\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, \".middle-align[data-v-0efa77f2]{vertical-align:middle}p[data-v-0efa77f2]{margin-top:12px;margin-bottom:12px}.new-owner-row[data-v-0efa77f2]{display:flex}.new-owner-row label[data-v-0efa77f2]{display:flex;align-items:center}.new-owner-row label span[data-v-0efa77f2]{margin-right:8px}.new-owner-row .multiselect[data-v-0efa77f2]{flex-grow:1;max-width:280px}.transfer-select-row span[data-v-0efa77f2]{margin-right:8px}\", \"\",{\"version\":3,\"sources\":[\"webpack://./apps/files/src/components/TransferOwnershipDialogue.vue\"],\"names\":[],\"mappings\":\"AACA,+BACC,qBAAA,CAED,mBACC,eAAA,CACA,kBAAA,CAED,gCACC,YAAA,CAEA,sCACC,YAAA,CACA,kBAAA,CAEA,2CACC,gBAAA,CAIF,6CACC,WAAA,CACA,eAAA,CAID,2CACC,gBAAA\",\"sourcesContent\":[\"\\n.middle-align {\\n\\tvertical-align: middle;\\n}\\np {\\n\\tmargin-top: 12px;\\n\\tmargin-bottom: 12px;\\n}\\n.new-owner-row {\\n\\tdisplay: flex;\\n\\n\\tlabel {\\n\\t\\tdisplay: flex;\\n\\t\\talign-items: center;\\n\\n\\t\\tspan {\\n\\t\\t\\tmargin-right: 8px;\\n\\t\\t}\\n\\t}\\n\\n\\t.multiselect {\\n\\t\\tflex-grow: 1;\\n\\t\\tmax-width: 280px;\\n\\t}\\n}\\n.transfer-select-row {\\n\\tspan {\\n\\t\\tmargin-right: 8px;\\n\\t}\\n}\\n\"],\"sourceRoot\":\"\"}]);\n// Exports\nexport default ___CSS_LOADER_EXPORT___;\n","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\tid: moduleId,\n\t\tloaded: false,\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Flag the module as loaded\n\tmodule.loaded = true;\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n// expose the modules object (__webpack_modules__)\n__webpack_require__.m = __webpack_modules__;\n\n","__webpack_require__.amdD = function () {\n\tthrow new Error('define cannot be used indirect');\n};","__webpack_require__.amdO = {};","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = function(module) {\n\tvar getter = module && module.__esModule ?\n\t\tfunction() { return module['default']; } :\n\t\tfunction() { return module; };\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = function(exports, definition) {\n\tfor(var key in definition) {\n\t\tif(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {\n\t\t\tObject.defineProperty(exports, key, { enumerable: true, get: definition[key] });\n\t\t}\n\t}\n};","__webpack_require__.g = (function() {\n\tif (typeof globalThis === 'object') return globalThis;\n\ttry {\n\t\treturn this || new Function('return this')();\n\t} catch (e) {\n\t\tif (typeof window === 'object') return window;\n\t}\n})();","__webpack_require__.o = function(obj, prop) { return Object.prototype.hasOwnProperty.call(obj, prop); }","// define __esModule on exports\n__webpack_require__.r = function(exports) {\n\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n\t}\n\tObject.defineProperty(exports, '__esModule', { value: true });\n};","__webpack_require__.nmd = function(module) {\n\tmodule.paths = [];\n\tif (!module.children) module.children = [];\n\treturn module;\n};","__webpack_require__.j = 1623;","__webpack_require__.b = document.baseURI || self.location.href;\n\n// object to store loaded and loading chunks\n// undefined = chunk not loaded, null = chunk preloaded/prefetched\n// [resolve, reject, Promise] = chunk loading, 0 = chunk loaded\nvar installedChunks = {\n\t1623: 0\n};\n\n// no chunk on demand loading\n\n// no prefetching\n\n// no preloaded\n\n// no HMR\n\n// no HMR manifest\n\n__webpack_require__.O.j = function(chunkId) { return installedChunks[chunkId] === 0; };\n\n// install a JSONP callback for chunk loading\nvar webpackJsonpCallback = function(parentChunkLoadingFunction, data) {\n\tvar chunkIds = data[0];\n\tvar moreModules = data[1];\n\tvar runtime = data[2];\n\t// add \"moreModules\" to the modules object,\n\t// then flag all \"chunkIds\" as loaded and fire callback\n\tvar moduleId, chunkId, i = 0;\n\tif(chunkIds.some(function(id) { return installedChunks[id] !== 0; })) {\n\t\tfor(moduleId in moreModules) {\n\t\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t\t}\n\t\t}\n\t\tif(runtime) var result = runtime(__webpack_require__);\n\t}\n\tif(parentChunkLoadingFunction) parentChunkLoadingFunction(data);\n\tfor(;i < chunkIds.length; i++) {\n\t\tchunkId = chunkIds[i];\n\t\tif(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {\n\t\t\tinstalledChunks[chunkId][0]();\n\t\t}\n\t\tinstalledChunks[chunkId] = 0;\n\t}\n\treturn __webpack_require__.O(result);\n}\n\nvar chunkLoadingGlobal = self[\"webpackChunknextcloud\"] = self[\"webpackChunknextcloud\"] || [];\nchunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0));\nchunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal));","__webpack_require__.nc = undefined;","// startup\n// Load entry module and return exports\n// This entry module depends on other loaded chunks and execution need to be delayed\nvar __webpack_exports__ = __webpack_require__.O(undefined, [7874], function() { return __webpack_require__(70556); })\n__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n"],"names":["deferred","user","getCurrentUser","getLoggerBuilder","setApp","build","setUid","uid","options","styleTagTransform","setAttributes","insert","domAPI","insertStyleElement","component","_vm","this","_c","_self","_v","_s","t","on","$event","preventDefault","submit","apply","arguments","staticClass","readableDirectory","undefined","directory","start","directoryPickerError","attrs","formatedUserSuggestions","loadingUsers","findUserDebounced","model","value","selectedUser","callback","$$v","expression","canSubmit","domProps","submitButtonText","submitError","__webpack_nonce__","btoa","getRequestToken","Vue","window","TESTING","PersonalSettings","$mount","___CSS_LOADER_EXPORT___","push","module","id","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","exports","loaded","__webpack_modules__","call","m","amdD","Error","amdO","O","result","chunkIds","fn","priority","notFulfilled","Infinity","i","length","fulfilled","j","Object","keys","every","key","splice","r","n","getter","__esModule","d","a","definition","o","defineProperty","enumerable","get","g","globalThis","Function","e","obj","prop","prototype","hasOwnProperty","Symbol","toStringTag","nmd","paths","children","b","document","baseURI","self","location","href","installedChunks","chunkId","webpackJsonpCallback","parentChunkLoadingFunction","data","moreModules","runtime","some","chunkLoadingGlobal","forEach","bind","nc","__webpack_exports__"],"sourceRoot":""}