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EAAIL,EAASM,OAAQD,IACzBsC,EAAU3C,EAASK,GAChBf,EAAoB6B,EAAEuB,EAAiBC,IAAYD,EAAgBC,IACrED,EAAgBC,GAAS,KAE1BD,EAAgBC,GAAW,EAE5B,OAAOrD,EAAoBQ,EAAEC,EAC9B,EAEIkD,EAAqBV,KAA4B,sBAAIA,KAA4B,uBAAK,GAC1FU,EAAmBC,QAAQN,EAAqBO,KAAK,KAAM,IAC3DF,EAAmB/D,KAAO0D,EAAqBO,KAAK,KAAMF,EAAmB/D,KAAKiE,KAAKF,OClDvF3D,EAAoB8D,QAAKhJ,ECGzB,IAAIiJ,EAAsB/D,EAAoBQ,OAAE1F,EAAW,CAAC,OAAO,WAAa,OAAOkF,EAAoB,KAAO,IAClH+D,EAAsB/D,EAAoBQ,EAAEuD","sources":["webpack:///nextcloud/webpack/runtime/chunk loaded","webpack:///nextcloud/apps/dav/src/dav/client.js","webpack:///nextcloud/apps/dav/src/service/logger.js","webpack:///nextcloud/apps/dav/src/service/CalendarService.js","webpack:///nextcloud/apps/dav/src/service/PreferenceService.js","webpack:///nextcloud/apps/dav/src/views/Availability.vue","webpack:///nextcloud/apps/dav/src/views/Availability.vue?vue&type=script&lang=js&","webpack://nextcloud/./apps/dav/src/views/Availability.vue?1dc9","webpack://nextcloud/./apps/dav/src/views/Availability.vue?aa5a","webpack://nextcloud/./apps/dav/src/views/Availability.vue?4eb1","webpack:///nextcloud/apps/dav/src/settings-personal-availability.js","webpack:///nextcloud/apps/dav/src/views/Availability.vue?vue&type=style&index=0&id=24aa351b&prod&lang=scss&scoped=true&","webpack:///nextcloud/webpack/bootstrap","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 2021 Christoph Wurst \n *\n * @author 2021 Christoph Wurst \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 .\n */\n\nimport * as webdav from 'webdav'\nimport axios from '@nextcloud/axios'\nimport memoize from 'lodash/fp/memoize'\nimport { generateRemoteUrl } from '@nextcloud/router'\nimport { getCurrentUser } from '@nextcloud/auth'\n\nexport const getClient = memoize((service) => {\n\t// Add this so the server knows it is an request from the browser\n\taxios.defaults.headers['X-Requested-With'] = 'XMLHttpRequest'\n\n\t// force our axios\n\tconst patcher = webdav.getPatcher()\n\tpatcher.patch('request', axios)\n\n\treturn webdav.createClient(\n\t\tgenerateRemoteUrl(`dav/${service}/${getCurrentUser().uid}`)\n\t)\n})\n","/*\n * @copyright 2021 Christoph Wurst \n *\n * @author 2021 Christoph Wurst \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 .\n */\nimport { getLoggerBuilder } from '@nextcloud/logger'\n\nconst logger = getLoggerBuilder()\n\t.setApp('dav')\n\t.detectUser()\n\t.build()\n\nexport default logger\n","/**\n * @copyright 2021 Christoph Wurst \n *\n * @author 2021 Christoph Wurst \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 .\n */\nimport { getClient } from '../dav/client'\nimport logger from './logger'\nimport { parseXML } from 'webdav/dist/node/tools/dav'\n\nimport {\n\tslotsToVavailability,\n\tvavailabilityToSlots,\n} from '@nextcloud/calendar-availability-vue'\n\n/**\n *\n */\nexport function getEmptySlots() {\n\treturn {\n\t\tMO: [],\n\t\tTU: [],\n\t\tWE: [],\n\t\tTH: [],\n\t\tFR: [],\n\t\tSA: [],\n\t\tSU: [],\n\t}\n}\n\n/**\n *\n */\nexport async function findScheduleInboxAvailability() {\n\tconst client = getClient('calendars')\n\n\tconst response = await client.customRequest('inbox', {\n\t\tmethod: 'PROPFIND',\n\t\tdata: `\n\t\t\t\n\t\t\t \n\t\t\t\t\n\t\t\t \n\t\t\t`,\n\t})\n\n\tconst xml = await parseXML(response.data)\n\n\tif (!xml) {\n\t\treturn undefined\n\t}\n\n\tconst availability = xml?.multistatus?.response[0]?.propstat?.prop['calendar-availability']\n\tif (!availability) {\n\t\treturn undefined\n\t}\n\n\treturn vavailabilityToSlots(availability)\n}\n\n/**\n * @param {any} slots -\n * @param {any} timezoneId -\n */\nexport async function saveScheduleInboxAvailability(slots, timezoneId) {\n\tconst all = [...Object.keys(slots).flatMap(dayId => slots[dayId].map(slot => ({\n\t\t...slot,\n\t\tday: dayId,\n\t})))]\n\n\tconst vavailability = slotsToVavailability(all, timezoneId)\n\n\tlogger.debug('New availability ical created', {\n\t\tvavailability,\n\t})\n\n\tconst client = getClient('calendars')\n\tawait client.customRequest('inbox', {\n\t\tmethod: 'PROPPATCH',\n\t\tdata: `\n\t\t\t\n\t\t\t \n\t\t\t\t\n\t\t\t\t ${vavailability}\n\t\t\t\t\n\t\t\t \n\t\t\t`,\n\t})\n}\n","/**\n * @copyright 2022 Joas Schilling \n *\n * @author Joas Schilling \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 .\n */\n\nimport axios from '@nextcloud/axios'\nimport { generateOcsUrl } from '@nextcloud/router'\n\n/**\n * Enable user status automation based on availability\n */\nexport async function enableUserStatusAutomation() {\n\treturn await axios.post(\n\t\tgenerateOcsUrl('/apps/provisioning_api/api/v1/config/users/{appId}/{configKey}', {\n\t\t\tappId: 'dav',\n\t\t\tconfigKey: 'user_status_automation',\n\t\t}),\n\t\t{\n\t\t\tconfigValue: 'yes',\n\t\t}\n\t)\n}\n\n/**\n * Disable user status automation based on availability\n */\nexport async function disableUserStatusAutomation() {\n\treturn await axios.delete(\n\t\tgenerateOcsUrl('/apps/provisioning_api/api/v1/config/users/{appId}/{configKey}', {\n\t\t\tappId: 'dav',\n\t\t\tconfigKey: 'user_status_automation',\n\t\t})\n\t)\n}\n","\n\n\n\n\n","import mod from \"-!../../../../node_modules/babel-loader/lib/index.js!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Availability.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!./Availability.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!./Availability.vue?vue&type=style&index=0&id=24aa351b&prod&lang=scss&scoped=true&\";\n \n \n\nvar options = {};\n\noptions.styleTagTransform = styleTagTransformFn;\noptions.setAttributes = setAttributes;\n\n options.insert = insertFn.bind(null, \"head\");\n \noptions.domAPI = domAPI;\noptions.insertStyleElement = insertStyleElement;\n\nvar update = API(content, options);\n\n\n\nexport * from \"!!../../../../node_modules/css-loader/dist/cjs.js!../../../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../../../node_modules/sass-loader/dist/cjs.js!../../../../node_modules/vue-loader/lib/index.js??vue-loader-options!./Availability.vue?vue&type=style&index=0&id=24aa351b&prod&lang=scss&scoped=true&\";\n export default content && content.locals ? content.locals : undefined;\n","import { render, staticRenderFns } from \"./Availability.vue?vue&type=template&id=24aa351b&scoped=true&\"\nimport script from \"./Availability.vue?vue&type=script&lang=js&\"\nexport * from \"./Availability.vue?vue&type=script&lang=js&\"\nimport style0 from \"./Availability.vue?vue&type=style&index=0&id=24aa351b&prod&lang=scss&scoped=true&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"24aa351b\",\n null\n \n)\n\nexport default component.exports","var render = function render(){var _vm=this,_c=_vm._self._c;return _c('NcSettingsSection',{attrs:{\"title\":_vm.$t('dav', 'Availability'),\"description\":_vm.$t('dav', 'If you configure your working hours, other users will see when you are out of office when they book a meeting.')}},[_c('div',{staticClass:\"time-zone\"},[_c('strong',[_vm._v(\"\\n\\t\\t\\t\"+_vm._s(_vm.$t('dav', 'Time zone:'))+\"\\n\\t\\t\")]),_vm._v(\" \"),_c('span',{staticClass:\"time-zone-text\"},[_c('NcTimezonePicker',{model:{value:(_vm.timezone),callback:function ($$v) {_vm.timezone=$$v},expression:\"timezone\"}})],1)]),_vm._v(\" \"),_c('CalendarAvailability',{attrs:{\"slots\":_vm.slots,\"loading\":_vm.loading,\"l10n-to\":_vm.$t('dav', 'to'),\"l10n-delete-slot\":_vm.$t('dav', 'Delete slot'),\"l10n-empty-day\":_vm.$t('dav', 'No working hours set'),\"l10n-add-slot\":_vm.$t('dav', 'Add slot'),\"l10n-monday\":_vm.$t('dav', 'Monday'),\"l10n-tuesday\":_vm.$t('dav', 'Tuesday'),\"l10n-wednesday\":_vm.$t('dav', 'Wednesday'),\"l10n-thursday\":_vm.$t('dav', 'Thursday'),\"l10n-friday\":_vm.$t('dav', 'Friday'),\"l10n-saturday\":_vm.$t('dav', 'Saturday'),\"l10n-sunday\":_vm.$t('dav', 'Sunday')},on:{\"update:slots\":function($event){_vm.slots=$event}}}),_vm._v(\" \"),_c('NcCheckboxRadioSwitch',{attrs:{\"checked\":_vm.automated},on:{\"update:checked\":function($event){_vm.automated=$event}}},[_vm._v(\"\\n\\t\\t\"+_vm._s(_vm.$t('dav', 'Automatically set user status to \"Do not disturb\" outside of availability to mute all notifications.'))+\"\\n\\t\")]),_vm._v(\" \"),_c('NcButton',{attrs:{\"disabled\":_vm.loading || _vm.saving,\"type\":\"primary\"},on:{\"click\":_vm.save}},[_vm._v(\"\\n\\t\\t\"+_vm._s(_vm.$t('dav', 'Save'))+\"\\n\\t\")])],1)\n}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","import Vue from 'vue'\nimport { translate } from '@nextcloud/l10n'\nimport Availability from './views/Availability'\n\nVue.prototype.$t = translate\n\nconst View = Vue.extend(Availability);\n\n(new View({})).$mount('#settings-personal-availability')\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, \".availability-day[data-v-24aa351b]{padding:0 10px 0 10px;position:absolute}.availability-slots[data-v-24aa351b]{display:flex;white-space:nowrap}.availability-slot[data-v-24aa351b]{display:flex;flex-direction:row;align-items:center}.availability-slot-group[data-v-24aa351b]{display:flex;flex-direction:column}[data-v-24aa351b] .mx-input-wrapper{width:85px}[data-v-24aa351b] .mx-datepicker{width:97px}[data-v-24aa351b] .multiselect{border:1px solid var(--color-border-dark);width:120px}.time-zone[data-v-24aa351b]{padding:32px 12px 12px 0}.grid-table[data-v-24aa351b]{display:grid;margin-bottom:32px;grid-column-gap:24px;grid-row-gap:6px;grid-template-columns:min-content min-content min-content}.button[data-v-24aa351b]{align-self:flex-end}.label-weekday[data-v-24aa351b]{position:relative;display:inline-flex;padding-top:4px}.delete-slot[data-v-24aa351b]{background-color:rgba(0,0,0,0);border:none;padding-bottom:12px;opacity:.5}.delete-slot[data-v-24aa351b]:hover{opacity:1}.add-another[data-v-24aa351b]{background-color:rgba(0,0,0,0);border:none;opacity:.5;display:inline-flex;padding:0;margin:0;margin-bottom:3px}.add-another[data-v-24aa351b]:hover{opacity:1}.to-text[data-v-24aa351b]{padding-right:12px}.time-zone-text[data-v-24aa351b]{padding-left:22px}.empty-content[data-v-24aa351b]{color:var(--color-text-lighter);margin-top:4px}\", \"\",{\"version\":3,\"sources\":[\"webpack://./apps/dav/src/views/Availability.vue\"],\"names\":[],\"mappings\":\"AACA,mCACC,qBAAA,CACA,iBAAA,CAED,qCACC,YAAA,CACA,kBAAA,CAED,oCACC,YAAA,CACA,kBAAA,CACA,kBAAA,CAED,0CACC,YAAA,CACA,qBAAA,CAED,oCACC,UAAA,CAED,iCACC,UAAA,CAED,+BACC,yCAAA,CACA,WAAA,CAED,4BACC,wBAAA,CAED,6BACC,YAAA,CACA,kBAAA,CACA,oBAAA,CACA,gBAAA,CACA,yDAAA,CAED,yBACC,mBAAA,CAED,gCACC,iBAAA,CACA,mBAAA,CACA,eAAA,CAED,8BACC,8BAAA,CACA,WAAA,CACA,mBAAA,CACA,UAAA,CACA,oCACC,SAAA,CAIF,8BACC,8BAAA,CACA,WAAA,CACA,UAAA,CACA,mBAAA,CACA,SAAA,CACA,QAAA,CACA,iBAAA,CAEA,oCACC,SAAA,CAGF,0BACC,kBAAA,CAED,iCACC,iBAAA,CAED,gCACC,+BAAA,CACA,cAAA\",\"sourcesContent\":[\"\\n.availability-day {\\n\\tpadding: 0 10px 0 10px;\\n\\tposition: absolute;\\n}\\n.availability-slots {\\n\\tdisplay: flex;\\n\\twhite-space: nowrap;\\n}\\n.availability-slot {\\n\\tdisplay: flex;\\n\\tflex-direction: row;\\n\\talign-items: center;\\n}\\n.availability-slot-group {\\n\\tdisplay: flex;\\n\\tflex-direction: column;\\n}\\n::v-deep .mx-input-wrapper {\\n\\twidth: 85px;\\n}\\n::v-deep .mx-datepicker {\\n\\twidth: 97px;\\n}\\n::v-deep .multiselect {\\n\\tborder: 1px solid var(--color-border-dark);\\n\\twidth: 120px;\\n}\\n.time-zone {\\n\\tpadding: 32px 12px 12px 0;\\n}\\n.grid-table {\\n\\tdisplay: grid;\\n\\tmargin-bottom: 32px;\\n\\tgrid-column-gap: 24px;\\n\\tgrid-row-gap: 6px;\\n\\tgrid-template-columns: min-content min-content min-content;\\n}\\n.button {\\n\\talign-self: flex-end;\\n}\\n.label-weekday {\\n\\tposition: relative;\\n\\tdisplay: inline-flex;\\n\\tpadding-top: 4px;\\n}\\n.delete-slot {\\n\\tbackground-color: transparent;\\n\\tborder: none;\\n\\tpadding-bottom: 12px;\\n\\topacity: .5;\\n\\t&:hover {\\n\\t\\topacity: 1;\\n\\t}\\n}\\n\\n.add-another {\\n\\tbackground-color: transparent;\\n\\tborder: none;\\n\\topacity: .5;\\n\\tdisplay: inline-flex;\\n\\tpadding: 0;\\n\\tmargin: 0;\\n\\tmargin-bottom: 3px;\\n\\n\\t&:hover {\\n\\t\\topacity: 1;\\n\\t}\\n}\\n.to-text {\\n\\tpadding-right: 12px;\\n}\\n.time-zone-text{\\n\\tpadding-left: 22px;\\n}\\n.empty-content {\\n\\tcolor: var(--color-text-lighter);\\n\\tmargin-top: 4px;\\n}\\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","// 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 = 3347;","__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\t3347: 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__(1224); })\n__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n"],"names":["deferred","getClient","memoize","service","axios","webdav","patch","generateRemoteUrl","getCurrentUser","uid","getLoggerBuilder","setApp","detectUser","build","findScheduleInboxAvailability","client","customRequest","method","data","response","parseXML","xml","undefined","availability","multistatus","propstat","prop","vavailabilityToSlots","saveScheduleInboxAvailability","slots","timezoneId","all","Object","keys","flatMap","dayId","map","slot","day","vavailability","slotsToVavailability","logger","enableUserStatusAutomation","generateOcsUrl","appId","configKey","configValue","disableUserStatusAutomation","name","components","NcButton","NcCheckboxRadioSwitch","CalendarAvailability","NcSettingsSection","NcTimezonePicker","loading","saving","timezone","MO","TU","WE","TH","FR","SA","SU","automated","mounted","slotData","console","showError","methods","save","showSuccess","options","styleTagTransform","setAttributes","insert","domAPI","insertStyleElement","_vm","this","_c","_self","attrs","$t","staticClass","_v","_s","model","value","callback","$$v","expression","on","$event","Vue","translate","Availability","$mount","___CSS_LOADER_EXPORT___","push","module","id","__webpack_module_cache__","__webpack_require__","moduleId","cachedModule","exports","loaded","__webpack_modules__","call","m","O","result","chunkIds","fn","priority","notFulfilled","Infinity","i","length","fulfilled","j","every","key","splice","r","n","getter","__esModule","d","a","definition","o","defineProperty","enumerable","get","g","globalThis","Function","e","window","obj","prototype","hasOwnProperty","Symbol","toStringTag","nmd","paths","children","b","document","baseURI","self","location","href","installedChunks","chunkId","webpackJsonpCallback","parentChunkLoadingFunction","moreModules","runtime","some","chunkLoadingGlobal","forEach","bind","nc","__webpack_exports__"],"sourceRoot":""}