@zextras/carbonio-shell-ui 0.4.14 → 0.4.15

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (33) hide show
  1. package/dist/CHANGELOG.md +18 -0
  2. package/dist/PKGBUILD +6 -6
  3. package/dist/commit +1 -1
  4. package/dist/component.json +3 -3
  5. package/dist/i18n/de.json +82 -1
  6. package/dist/i18n/fr.json +64 -1
  7. package/dist/i18n/hi.json +138 -1
  8. package/dist/i18n/id.json +138 -1
  9. package/dist/i18n/it.json +35 -1
  10. package/dist/i18n/ja.json +138 -1
  11. package/dist/i18n/nl.json +138 -1
  12. package/dist/i18n/pl.json +7 -7
  13. package/dist/i18n/pt_BR.json +138 -1
  14. package/dist/i18n/th.json +138 -1
  15. package/dist/i18n/tr.json +138 -1
  16. package/dist/i18n/zh_Hans.json +138 -1
  17. package/dist/index.html +3 -3
  18. package/dist/{src_boot_bootstrapper_tsx-node_modules_moment_locale_sync_recursive_.19871cdd.chunk.js → src_boot_bootstrapper_tsx-node_modules_moment_locale_sync_recursive_.6dd85d32.chunk.js} +229 -202
  19. package/dist/src_boot_bootstrapper_tsx-node_modules_moment_locale_sync_recursive_.6dd85d32.chunk.js.map +1 -0
  20. package/dist/{src_workers_folder_ts.6e00c930.chunk.js → src_workers_folder_ts.b953ead8.chunk.js} +2 -2
  21. package/dist/{src_workers_folder_ts.6e00c930.chunk.js.map → src_workers_folder_ts.b953ead8.chunk.js.map} +1 -1
  22. package/dist/{src_workers_tag_ts.275881ac.chunk.js → src_workers_tag_ts.f72cbbc5.chunk.js} +2 -2
  23. package/dist/{src_workers_tag_ts.275881ac.chunk.js.map → src_workers_tag_ts.f72cbbc5.chunk.js.map} +1 -1
  24. package/dist/{style.e1b357a2.css → style.b11f5282.css} +1 -1
  25. package/dist/{style.e1b357a2.css.map → style.b11f5282.css.map} +1 -1
  26. package/dist/{vendors-node_modules_reduxjs_toolkit_dist_redux-toolkit_esm_js-node_modules_sentry_browser_es-eb34a0.8b6b16b5.chunk.js → vendors-node_modules_reduxjs_toolkit_dist_redux-toolkit_esm_js-node_modules_sentry_browser_es-eb34a0.e0814547.chunk.js} +79 -38
  27. package/dist/{vendors-node_modules_reduxjs_toolkit_dist_redux-toolkit_esm_js-node_modules_sentry_browser_es-eb34a0.8b6b16b5.chunk.js.map → vendors-node_modules_reduxjs_toolkit_dist_redux-toolkit_esm_js-node_modules_sentry_browser_es-eb34a0.e0814547.chunk.js.map} +1 -1
  28. package/dist/zapp-shell.bundle.js +2 -2
  29. package/dist/zapp-shell.bundle.js.map +1 -1
  30. package/package.json +3 -3
  31. package/types/exports/index.d.ts +4 -0
  32. package/types/misc/index.d.ts +2 -2
  33. package/dist/src_boot_bootstrapper_tsx-node_modules_moment_locale_sync_recursive_.19871cdd.chunk.js.map +0 -1
@@ -490,7 +490,7 @@ onmessage = function onmessage(_ref2) {
490
490
  /******/
491
491
  /******/ /* webpack/runtime/publicPath */
492
492
  /******/ (() => {
493
- /******/ __webpack_require__.p = "/static/iris/carbonio-shell-ui/c7ccd56ade6f4addd8a92e5fcf802aa3d2c0be11/";
493
+ /******/ __webpack_require__.p = "/static/iris/carbonio-shell-ui/10daf3b28c4be4fa1aca2a5f7e603e3490dc8d59/";
494
494
  /******/ })();
495
495
  /******/
496
496
  /******/ /* webpack/runtime/importScripts chunk loading */
@@ -549,4 +549,4 @@ onmessage = function onmessage(_ref2) {
549
549
  /******/
550
550
  /******/ })()
551
551
  ;
552
- //# sourceMappingURL=src_workers_folder_ts.6e00c930.chunk.js.map
552
+ //# sourceMappingURL=src_workers_folder_ts.b953ead8.chunk.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"src_workers_folder_ts.6e00c930.chunk.js","mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AACA;AACA;AACA;AACA;AAmBA,IAAMA,OAAO,GAAG,IA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A;;;;;WCPA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,EAAE;WACF;;;;;WCRA;WACA;WACA;WACA,8BAA8B,wcAAwc;WACte;;;;;WCJA;WACA;WACA;WACA;WACA;;;;;WCJA;WACA;WACA;WACA;WACA,GAAG;WACH;WACA;WACA,CAAC;;;;;WCPD;;;;;WCAA;WACA;WACA;WACA,uDAAuD,iBAAiB;WACxE;WACA,gDAAgD,aAAa;WAC7D;;;;;WCNA;;;;;WCAA;;WAEA;WACA;WACA;WACA;WACA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,aAAa;WACb;WACA;WACA;WACA;;WAEA;WACA;WACA;;WAEA;;WAEA;;;;;WCpCA;WACA;WACA;WACA;;;;;UEHA;UACA","sources":["webpack://@zextras/carbonio-shell-ui/./src/workers/folder.ts","webpack://@zextras/carbonio-shell-ui/webpack/bootstrap","webpack://@zextras/carbonio-shell-ui/webpack/runtime/chunk loaded","webpack://@zextras/carbonio-shell-ui/webpack/runtime/compat get default export","webpack://@zextras/carbonio-shell-ui/webpack/runtime/define property getters","webpack://@zextras/carbonio-shell-ui/webpack/runtime/ensure chunk","webpack://@zextras/carbonio-shell-ui/webpack/runtime/get javascript chunk filename","webpack://@zextras/carbonio-shell-ui/webpack/runtime/get mini-css chunk filename","webpack://@zextras/carbonio-shell-ui/webpack/runtime/global","webpack://@zextras/carbonio-shell-ui/webpack/runtime/hasOwnProperty shorthand","webpack://@zextras/carbonio-shell-ui/webpack/runtime/make namespace object","webpack://@zextras/carbonio-shell-ui/webpack/runtime/publicPath","webpack://@zextras/carbonio-shell-ui/webpack/runtime/importScripts chunk loading","webpack://@zextras/carbonio-shell-ui/webpack/runtime/startup chunk dependencies","webpack://@zextras/carbonio-shell-ui/webpack/before-startup","webpack://@zextras/carbonio-shell-ui/webpack/startup","webpack://@zextras/carbonio-shell-ui/webpack/after-startup"],"sourcesContent":["/*\n * SPDX-FileCopyrightText: 2022 Zextras <https://www.zextras.com>\n *\n * SPDX-License-Identifier: AGPL-3.0-only\n */\n\nimport {\n\tBaseFolder,\n\tUserFolder,\n\tFolderMessage,\n\tFolders,\n\tLinkFolder,\n\tLinkFolderFields,\n\tRoots,\n\tSearches,\n\tSearchFolderFields,\n\tSoapFolder,\n\tSoapLink,\n\tSoapNotify,\n\tSoapSearchFolder,\n\tFolder\n} from '../../types';\n\nconst IM_LOGS = '14';\nconst ROOT_NAME = 'USER_ROOT';\nconst DEFAULT_ROOT = 'USER';\n\nconst folders: Folders = {};\nconst roots: Roots = {};\nconst searches: Searches = {};\n\nconst omit = ({\n\tlink: _1,\n\tfolder: _2,\n\tsearch: _3,\n\t...obj\n}: Partial<SoapFolder>): Partial<SoapFolder> => obj;\n\nconst hasId = (f: SoapFolder, id: string): boolean => f.id.split(':').includes(id);\nconst normalize = (f: SoapFolder): BaseFolder => ({\n\tid: f.id,\n\tuuid: f.uuid,\n\tname: f.name,\n\tabsFolderPath: f.absFolderPath,\n\tl: f.l,\n\tluuid: f.luuid,\n\tf: f.f,\n\tcolor: f.color,\n\trgb: f.rgb,\n\tu: f.u,\n\ti4u: f.i4u,\n\tview: f.view,\n\trev: f.rev,\n\tms: f.ms,\n\tmd: f.md,\n\tn: f.n,\n\ti4n: f.i4n,\n\ts: f.s,\n\ti4ms: f.i4ms,\n\ti4next: f.i4next,\n\turl: f.url,\n\tactivesyncdisabled: !!f.activesyncdisabled,\n\twebOfflineSyncDays: f.webOfflineSyncDays,\n\tperm: f.perm,\n\trecursive: !!f.recursive,\n\trest: f.rest,\n\tdeletable: !!f.deletable,\n\tmeta: f.meta,\n\tacl: f.acl,\n\tretentionPolicy: f.retentionPolicy\n});\n\nconst normalizeSearch = (s: SoapSearchFolder): BaseFolder & SearchFolderFields => ({\n\t...normalize(s),\n\tquery: s.query,\n\tsortBy: s.sortBy,\n\ttypes: s.types\n});\n\nconst normalizeLink = (l: SoapLink): BaseFolder & LinkFolderFields => ({\n\t...normalize(l),\n\towner: l.owner,\n\tzid: l.zid,\n\trid: l.rid,\n\truuid: l.ruuid,\n\toname: l.oname,\n\treminder: !!l.reminder,\n\tbroken: !!l.broken\n});\n\nconst processSearch = (soapSearch: SoapSearchFolder, parent: Folder): void => {\n\tconst search = {\n\t\t...normalizeSearch(soapSearch),\n\t\tparent,\n\t\tisLink: parent?.isLink\n\t};\n\tsearches[search.id] = search;\n};\n\nconst processLink = (soapLink: SoapLink, depth: number, parent?: Folder): LinkFolder => {\n\tconst link = {\n\t\t...normalizeLink(soapLink),\n\t\tisLink: true,\n\t\tchildren: [],\n\t\tparent,\n\t\tdepth\n\t} as LinkFolder;\n\t// eslint-disable-next-line no-param-reassign\n\tfolders[soapLink.id] = link;\n\tif (link.oname === ROOT_NAME) {\n\t\troots[link.owner ?? 'unknown'] = link;\n\t}\n\tsoapLink?.folder?.forEach((f) => {\n\t\tif (!hasId(f, IM_LOGS)) {\n\t\t\t// eslint-disable-next-line @typescript-eslint/no-use-before-define\n\t\t\tconst child = processFolder(f, depth + 1, link);\n\t\t\tlink.children.push(child);\n\t\t}\n\t});\n\tsoapLink?.link?.forEach((l) => {\n\t\tif (!hasId(l, IM_LOGS)) {\n\t\t\tconst child = processLink(l, depth + 1, link);\n\t\t\tlink.children.push(child);\n\t\t}\n\t});\n\tsoapLink?.search?.forEach((s) => {\n\t\tprocessSearch(s, link);\n\t});\n\n\treturn link;\n};\n\nconst processFolder = (soapFolder: SoapFolder, depth: number, parent?: Folder): UserFolder => {\n\tconst folder: UserFolder = {\n\t\t...normalize(soapFolder),\n\t\tisLink: false,\n\t\tchildren: [],\n\t\tparent,\n\t\tdepth\n\t};\n\tfolders[soapFolder.id] = folder;\n\tif (folder.name === ROOT_NAME) {\n\t\troots[DEFAULT_ROOT] = folder;\n\t}\n\tsoapFolder?.folder?.forEach((f) => {\n\t\tif (!hasId(f, IM_LOGS)) {\n\t\t\tconst child = processFolder(f, depth + 1, folder);\n\t\t\tfolder.children.push(child);\n\t\t}\n\t});\n\tsoapFolder?.link?.forEach((l) => {\n\t\tif (!hasId(l, IM_LOGS)) {\n\t\t\tconst child = processLink(l, depth + 1, folder);\n\t\t\tfolder.children.push(child);\n\t\t}\n\t});\n\tsoapFolder?.search?.forEach((s) => {\n\t\tprocessSearch(s, folder);\n\t});\n\treturn folder;\n};\n\nconst handleFolderRefresh = (soapFolders: Array<SoapFolder>): UserFolder =>\n\tprocessFolder(soapFolders[0], 0);\n\nexport const handleFolderCreated = (created: Array<SoapFolder>): void =>\n\tcreated.forEach((val: SoapFolder) => {\n\t\tif (val.id && val.l) {\n\t\t\tconst parent = folders[val.l];\n\t\t\tconst folder: UserFolder = {\n\t\t\t\t...normalize(val),\n\t\t\t\tisLink: false,\n\t\t\t\tchildren: [],\n\t\t\t\tparent,\n\t\t\t\tdepth: parent?.depth ? parent.depth + 1 : 0\n\t\t\t};\n\t\t\tfolders[val.id] = folder;\n\t\t\tparent.children.push(folder);\n\t\t}\n\t});\nexport const handleFolderModified = (modified: Array<Partial<UserFolder>>): void =>\n\tmodified.forEach((val: Partial<SoapFolder>): void => {\n\t\tif (val.id) {\n\t\t\tconst folder = folders[val.id];\n\t\t\tif (folder) {\n\t\t\t\tObject.assign(folder, omit(val));\n\t\t\t\tif (val.l) {\n\t\t\t\t\tconst oldParent = folders[val.id].parent;\n\t\t\t\t\tconst newParent = folders[val.l];\n\t\t\t\t\tif (oldParent) {\n\t\t\t\t\t\toldParent.children = oldParent.children.filter((f) => f.id !== val.id);\n\t\t\t\t\t\tnewParent.children.push(folder);\n\t\t\t\t\t}\n\t\t\t\t\tfolder.parent = newParent;\n\t\t\t\t}\n\t\t\t\tfolders[val.id] = folder;\n\t\t\t}\n\t\t}\n\t});\nexport const handleFolderDeleted = (deleted: string[]): void =>\n\tdeleted.forEach((val) => {\n\t\tconst folder = folders[val];\n\t\tif (folder) {\n\t\t\tif (folder.parent) {\n\t\t\t\tfolder.parent.children = folder.parent.children.filter((f) => f.id !== val);\n\t\t\t}\n\t\t\tdelete folders[val];\n\t\t\tdelete roots[val];\n\t\t\tdelete searches[val];\n\t\t}\n\t});\nexport const handleFolderNotify = (notify: SoapNotify): void => {\n\thandleFolderCreated(notify.created?.folder ?? []);\n\thandleFolderModified(notify.modified?.folder ?? []);\n\thandleFolderDeleted(notify.deleted ?? []);\n};\nonmessage = ({ data }: FolderMessage): void => {\n\tif (data.op === 'refresh' && data.folder) {\n\t\thandleFolderRefresh(data.folder);\n\t}\n\tif (data.op === 'notify') {\n\t\thandleFolderNotify(data.notify);\n\t}\n\tpostMessage({ folders, roots, searches });\n};\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\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\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// the startup function\n__webpack_require__.x = () => {\n\t// Load entry module and return exports\n\t// This entry module depends on other loaded chunks and execution need to be delayed\n\tvar __webpack_exports__ = __webpack_require__.O(undefined, [\"vendors-node_modules_core-js_modules_es_array_filter_js-node_modules_core-js_modules_es_array-f8dfc2\",\"vendors-node_modules_core-js_internals_array-iteration_js-node_modules_core-js_internals_arra-a012fe\",\"vendors-node_modules_core-js_modules_es_array_includes_js-node_modules_core-js_modules_es_fun-f57f90\",\"vendors-node_modules_core-js_internals_add-to-unscopables_js-node_modules_core-js_internals_s-261a68\"], () => (__webpack_require__(\"./src/workers/folder.ts\")))\n\t__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n\treturn __webpack_exports__;\n};\n\n","var deferred = [];\n__webpack_require__.O = (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, fn, priority] = deferred[i];\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((key) => (__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};","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (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__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \".\" + {\"vendors-node_modules_core-js_modules_es_array_filter_js-node_modules_core-js_modules_es_array-f8dfc2\":\"5b2b999c\",\"vendors-node_modules_core-js_internals_array-iteration_js-node_modules_core-js_internals_arra-a012fe\":\"428e0a2a\",\"vendors-node_modules_core-js_modules_es_array_includes_js-node_modules_core-js_modules_es_fun-f57f90\":\"cc38c8f6\",\"vendors-node_modules_core-js_internals_add-to-unscopables_js-node_modules_core-js_internals_s-261a68\":\"e87ecee6\"}[chunkId] + \".chunk.js\";\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.miniCssF = (chunkId) => {\n\t// return url for filenames based on template\n\treturn undefined;\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 = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (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__.p = \"/static/iris/carbonio-shell-ui/c7ccd56ade6f4addd8a92e5fcf802aa3d2c0be11/\";","// no baseURI\n\n// object to store loaded chunks\n// \"1\" means \"already loaded\"\nvar installedChunks = {\n\t\"src_workers_folder_ts\": 1\n};\n\n// importScripts chunk loading\nvar installChunk = (data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\tfor(var moduleId in moreModules) {\n\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t}\n\t}\n\tif(runtime) runtime(__webpack_require__);\n\twhile(chunkIds.length)\n\t\tinstalledChunks[chunkIds.pop()] = 1;\n\tparentChunkLoadingFunction(data);\n};\n__webpack_require__.f.i = (chunkId, promises) => {\n\t// \"1\" is the signal for \"already loaded\"\n\tif(!installedChunks[chunkId]) {\n\t\tif(true) { // all chunks have JS\n\t\t\timportScripts(__webpack_require__.p + __webpack_require__.u(chunkId));\n\t\t}\n\t}\n};\n\nvar chunkLoadingGlobal = self[\"webpackChunk_zextras_carbonio_shell_ui\"] = self[\"webpackChunk_zextras_carbonio_shell_ui\"] || [];\nvar parentChunkLoadingFunction = chunkLoadingGlobal.push.bind(chunkLoadingGlobal);\nchunkLoadingGlobal.push = installChunk;\n\n// no HMR\n\n// no HMR manifest","var next = __webpack_require__.x;\n__webpack_require__.x = () => {\n\treturn Promise.all([\"vendors-node_modules_core-js_modules_es_array_filter_js-node_modules_core-js_modules_es_array-f8dfc2\",\"vendors-node_modules_core-js_internals_array-iteration_js-node_modules_core-js_internals_arra-a012fe\",\"vendors-node_modules_core-js_modules_es_array_includes_js-node_modules_core-js_modules_es_fun-f57f90\",\"vendors-node_modules_core-js_internals_add-to-unscopables_js-node_modules_core-js_internals_s-261a68\"].map(__webpack_require__.e, __webpack_require__)).then(next);\n};","","// run startup\nvar __webpack_exports__ = __webpack_require__.x();\n",""],"names":["IM_LOGS","ROOT_NAME","DEFAULT_ROOT","folders","roots","searches","omit","_1","link","_2","folder","_3","search","obj","hasId","f","id","split","includes","normalize","uuid","name","absFolderPath","l","luuid","color","rgb","u","i4u","view","rev","ms","md","n","i4n","s","i4ms","i4next","url","activesyncdisabled","webOfflineSyncDays","perm","recursive","rest","deletable","meta","acl","retentionPolicy","normalizeSearch","query","sortBy","types","normalizeLink","owner","zid","rid","ruuid","oname","reminder","broken","processSearch","soapSearch","parent","isLink","processLink","soapLink","depth","children","forEach","child","processFolder","push","soapFolder","handleFolderRefresh","soapFolders","handleFolderCreated","created","val","handleFolderModified","modified","Object","assign","oldParent","newParent","filter","handleFolderDeleted","deleted","handleFolderNotify","notify","onmessage","data","op","postMessage"],"sourceRoot":""}
1
+ {"version":3,"file":"src_workers_folder_ts.b953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ACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;;;;;WC3BA;WACA;WACA;WACA;WACA;WACA,iCAAiC,WAAW;WAC5C;WACA;;;;;WCPA;WACA;WACA;WACA;WACA,yCAAyC,wCAAwC;WACjF;WACA;WACA;;;;;WCPA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,EAAE;WACF;;;;;WCRA;WACA;WACA;WACA,8BAA8B,wcAAwc;WACte;;;;;WCJA;WACA;WACA;WACA;WACA;;;;;WCJA;WACA;WACA;WACA;WACA,GAAG;WACH;WACA;WACA,CAAC;;;;;WCPD;;;;;WCAA;WACA;WACA;WACA,uDAAuD,iBAAiB;WACxE;WACA,gDAAgD,aAAa;WAC7D;;;;;WCNA;;;;;WCAA;;WAEA;WACA;WACA;WACA;WACA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,aAAa;WACb;WACA;WACA;WACA;;WAEA;WACA;WACA;;WAEA;;WAEA;;;;;WCpCA;WACA;WACA;WACA;;;;;UEHA;UACA","sources":["webpack://@zextras/carbonio-shell-ui/./src/workers/folder.ts","webpack://@zextras/carbonio-shell-ui/webpack/bootstrap","webpack://@zextras/carbonio-shell-ui/webpack/runtime/chunk loaded","webpack://@zextras/carbonio-shell-ui/webpack/runtime/compat get default export","webpack://@zextras/carbonio-shell-ui/webpack/runtime/define property getters","webpack://@zextras/carbonio-shell-ui/webpack/runtime/ensure chunk","webpack://@zextras/carbonio-shell-ui/webpack/runtime/get javascript chunk filename","webpack://@zextras/carbonio-shell-ui/webpack/runtime/get mini-css chunk filename","webpack://@zextras/carbonio-shell-ui/webpack/runtime/global","webpack://@zextras/carbonio-shell-ui/webpack/runtime/hasOwnProperty shorthand","webpack://@zextras/carbonio-shell-ui/webpack/runtime/make namespace object","webpack://@zextras/carbonio-shell-ui/webpack/runtime/publicPath","webpack://@zextras/carbonio-shell-ui/webpack/runtime/importScripts chunk loading","webpack://@zextras/carbonio-shell-ui/webpack/runtime/startup chunk dependencies","webpack://@zextras/carbonio-shell-ui/webpack/before-startup","webpack://@zextras/carbonio-shell-ui/webpack/startup","webpack://@zextras/carbonio-shell-ui/webpack/after-startup"],"sourcesContent":["/*\n * SPDX-FileCopyrightText: 2022 Zextras <https://www.zextras.com>\n *\n * SPDX-License-Identifier: AGPL-3.0-only\n */\n\nimport {\n\tBaseFolder,\n\tUserFolder,\n\tFolderMessage,\n\tFolders,\n\tLinkFolder,\n\tLinkFolderFields,\n\tRoots,\n\tSearches,\n\tSearchFolderFields,\n\tSoapFolder,\n\tSoapLink,\n\tSoapNotify,\n\tSoapSearchFolder,\n\tFolder\n} from '../../types';\n\nconst IM_LOGS = '14';\nconst ROOT_NAME = 'USER_ROOT';\nconst DEFAULT_ROOT = 'USER';\n\nconst folders: Folders = {};\nconst roots: Roots = {};\nconst searches: Searches = {};\n\nconst omit = ({\n\tlink: _1,\n\tfolder: _2,\n\tsearch: _3,\n\t...obj\n}: Partial<SoapFolder>): Partial<SoapFolder> => obj;\n\nconst hasId = (f: SoapFolder, id: string): boolean => f.id.split(':').includes(id);\nconst normalize = (f: SoapFolder): BaseFolder => ({\n\tid: f.id,\n\tuuid: f.uuid,\n\tname: f.name,\n\tabsFolderPath: f.absFolderPath,\n\tl: f.l,\n\tluuid: f.luuid,\n\tf: f.f,\n\tcolor: f.color,\n\trgb: f.rgb,\n\tu: f.u,\n\ti4u: f.i4u,\n\tview: f.view,\n\trev: f.rev,\n\tms: f.ms,\n\tmd: f.md,\n\tn: f.n,\n\ti4n: f.i4n,\n\ts: f.s,\n\ti4ms: f.i4ms,\n\ti4next: f.i4next,\n\turl: f.url,\n\tactivesyncdisabled: !!f.activesyncdisabled,\n\twebOfflineSyncDays: f.webOfflineSyncDays,\n\tperm: f.perm,\n\trecursive: !!f.recursive,\n\trest: f.rest,\n\tdeletable: !!f.deletable,\n\tmeta: f.meta,\n\tacl: f.acl,\n\tretentionPolicy: f.retentionPolicy\n});\n\nconst normalizeSearch = (s: SoapSearchFolder): BaseFolder & SearchFolderFields => ({\n\t...normalize(s),\n\tquery: s.query,\n\tsortBy: s.sortBy,\n\ttypes: s.types\n});\n\nconst normalizeLink = (l: SoapLink): BaseFolder & LinkFolderFields => ({\n\t...normalize(l),\n\towner: l.owner,\n\tzid: l.zid,\n\trid: l.rid,\n\truuid: l.ruuid,\n\toname: l.oname,\n\treminder: !!l.reminder,\n\tbroken: !!l.broken\n});\n\nconst processSearch = (soapSearch: SoapSearchFolder, parent: Folder): void => {\n\tconst search = {\n\t\t...normalizeSearch(soapSearch),\n\t\tparent,\n\t\tisLink: parent?.isLink\n\t};\n\tsearches[search.id] = search;\n};\n\nconst processLink = (soapLink: SoapLink, depth: number, parent?: Folder): LinkFolder => {\n\tconst link = {\n\t\t...normalizeLink(soapLink),\n\t\tisLink: true,\n\t\tchildren: [],\n\t\tparent,\n\t\tdepth\n\t} as LinkFolder;\n\t// eslint-disable-next-line no-param-reassign\n\tfolders[soapLink.id] = link;\n\tif (link.oname === ROOT_NAME) {\n\t\troots[link.owner ?? 'unknown'] = link;\n\t}\n\tsoapLink?.folder?.forEach((f) => {\n\t\tif (!hasId(f, IM_LOGS)) {\n\t\t\t// eslint-disable-next-line @typescript-eslint/no-use-before-define\n\t\t\tconst child = processFolder(f, depth + 1, link);\n\t\t\tlink.children.push(child);\n\t\t}\n\t});\n\tsoapLink?.link?.forEach((l) => {\n\t\tif (!hasId(l, IM_LOGS)) {\n\t\t\tconst child = processLink(l, depth + 1, link);\n\t\t\tlink.children.push(child);\n\t\t}\n\t});\n\tsoapLink?.search?.forEach((s) => {\n\t\tprocessSearch(s, link);\n\t});\n\n\treturn link;\n};\n\nconst processFolder = (soapFolder: SoapFolder, depth: number, parent?: Folder): UserFolder => {\n\tconst folder: UserFolder = {\n\t\t...normalize(soapFolder),\n\t\tisLink: false,\n\t\tchildren: [],\n\t\tparent,\n\t\tdepth\n\t};\n\tfolders[soapFolder.id] = folder;\n\tif (folder.name === ROOT_NAME) {\n\t\troots[DEFAULT_ROOT] = folder;\n\t}\n\tsoapFolder?.folder?.forEach((f) => {\n\t\tif (!hasId(f, IM_LOGS)) {\n\t\t\tconst child = processFolder(f, depth + 1, folder);\n\t\t\tfolder.children.push(child);\n\t\t}\n\t});\n\tsoapFolder?.link?.forEach((l) => {\n\t\tif (!hasId(l, IM_LOGS)) {\n\t\t\tconst child = processLink(l, depth + 1, folder);\n\t\t\tfolder.children.push(child);\n\t\t}\n\t});\n\tsoapFolder?.search?.forEach((s) => {\n\t\tprocessSearch(s, folder);\n\t});\n\treturn folder;\n};\n\nconst handleFolderRefresh = (soapFolders: Array<SoapFolder>): UserFolder =>\n\tprocessFolder(soapFolders[0], 0);\n\nexport const handleFolderCreated = (created: Array<SoapFolder>): void =>\n\tcreated.forEach((val: SoapFolder) => {\n\t\tif (val.id && val.l) {\n\t\t\tconst parent = folders[val.l];\n\t\t\tconst folder: UserFolder = {\n\t\t\t\t...normalize(val),\n\t\t\t\tisLink: false,\n\t\t\t\tchildren: [],\n\t\t\t\tparent,\n\t\t\t\tdepth: parent?.depth ? parent.depth + 1 : 0\n\t\t\t};\n\t\t\tfolders[val.id] = folder;\n\t\t\tparent.children.push(folder);\n\t\t}\n\t});\nexport const handleFolderModified = (modified: Array<Partial<UserFolder>>): void =>\n\tmodified.forEach((val: Partial<SoapFolder>): void => {\n\t\tif (val.id) {\n\t\t\tconst folder = folders[val.id];\n\t\t\tif (folder) {\n\t\t\t\tObject.assign(folder, omit(val));\n\t\t\t\tif (val.l) {\n\t\t\t\t\tconst oldParent = folders[val.id].parent;\n\t\t\t\t\tconst newParent = folders[val.l];\n\t\t\t\t\tif (oldParent) {\n\t\t\t\t\t\toldParent.children = oldParent.children.filter((f) => f.id !== val.id);\n\t\t\t\t\t\tnewParent.children.push(folder);\n\t\t\t\t\t}\n\t\t\t\t\tfolder.parent = newParent;\n\t\t\t\t}\n\t\t\t\tfolders[val.id] = folder;\n\t\t\t}\n\t\t}\n\t});\nexport const handleFolderDeleted = (deleted: string[]): void =>\n\tdeleted.forEach((val) => {\n\t\tconst folder = folders[val];\n\t\tif (folder) {\n\t\t\tif (folder.parent) {\n\t\t\t\tfolder.parent.children = folder.parent.children.filter((f) => f.id !== val);\n\t\t\t}\n\t\t\tdelete folders[val];\n\t\t\tdelete roots[val];\n\t\t\tdelete searches[val];\n\t\t}\n\t});\nexport const handleFolderNotify = (notify: SoapNotify): void => {\n\thandleFolderCreated(notify.created?.folder ?? []);\n\thandleFolderModified(notify.modified?.folder ?? []);\n\thandleFolderDeleted(notify.deleted ?? []);\n};\nonmessage = ({ data }: FolderMessage): void => {\n\tif (data.op === 'refresh' && data.folder) {\n\t\thandleFolderRefresh(data.folder);\n\t}\n\tif (data.op === 'notify') {\n\t\thandleFolderNotify(data.notify);\n\t}\n\tpostMessage({ folders, roots, searches });\n};\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\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\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// the startup function\n__webpack_require__.x = () => {\n\t// Load entry module and return exports\n\t// This entry module depends on other loaded chunks and execution need to be delayed\n\tvar __webpack_exports__ = __webpack_require__.O(undefined, [\"vendors-node_modules_core-js_modules_es_array_filter_js-node_modules_core-js_modules_es_array-f8dfc2\",\"vendors-node_modules_core-js_internals_array-iteration_js-node_modules_core-js_internals_arra-a012fe\",\"vendors-node_modules_core-js_modules_es_array_includes_js-node_modules_core-js_modules_es_fun-f57f90\",\"vendors-node_modules_core-js_internals_add-to-unscopables_js-node_modules_core-js_internals_s-261a68\"], () => (__webpack_require__(\"./src/workers/folder.ts\")))\n\t__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n\treturn __webpack_exports__;\n};\n\n","var deferred = [];\n__webpack_require__.O = (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, fn, priority] = deferred[i];\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((key) => (__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};","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (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__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \".\" + {\"vendors-node_modules_core-js_modules_es_array_filter_js-node_modules_core-js_modules_es_array-f8dfc2\":\"5b2b999c\",\"vendors-node_modules_core-js_internals_array-iteration_js-node_modules_core-js_internals_arra-a012fe\":\"428e0a2a\",\"vendors-node_modules_core-js_modules_es_array_includes_js-node_modules_core-js_modules_es_fun-f57f90\":\"cc38c8f6\",\"vendors-node_modules_core-js_internals_add-to-unscopables_js-node_modules_core-js_internals_s-261a68\":\"e87ecee6\"}[chunkId] + \".chunk.js\";\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.miniCssF = (chunkId) => {\n\t// return url for filenames based on template\n\treturn undefined;\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 = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (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__.p = \"/static/iris/carbonio-shell-ui/10daf3b28c4be4fa1aca2a5f7e603e3490dc8d59/\";","// no baseURI\n\n// object to store loaded chunks\n// \"1\" means \"already loaded\"\nvar installedChunks = {\n\t\"src_workers_folder_ts\": 1\n};\n\n// importScripts chunk loading\nvar installChunk = (data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\tfor(var moduleId in moreModules) {\n\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t}\n\t}\n\tif(runtime) runtime(__webpack_require__);\n\twhile(chunkIds.length)\n\t\tinstalledChunks[chunkIds.pop()] = 1;\n\tparentChunkLoadingFunction(data);\n};\n__webpack_require__.f.i = (chunkId, promises) => {\n\t// \"1\" is the signal for \"already loaded\"\n\tif(!installedChunks[chunkId]) {\n\t\tif(true) { // all chunks have JS\n\t\t\timportScripts(__webpack_require__.p + __webpack_require__.u(chunkId));\n\t\t}\n\t}\n};\n\nvar chunkLoadingGlobal = self[\"webpackChunk_zextras_carbonio_shell_ui\"] = self[\"webpackChunk_zextras_carbonio_shell_ui\"] || [];\nvar parentChunkLoadingFunction = chunkLoadingGlobal.push.bind(chunkLoadingGlobal);\nchunkLoadingGlobal.push = installChunk;\n\n// no HMR\n\n// no HMR manifest","var next = __webpack_require__.x;\n__webpack_require__.x = () => {\n\treturn Promise.all([\"vendors-node_modules_core-js_modules_es_array_filter_js-node_modules_core-js_modules_es_array-f8dfc2\",\"vendors-node_modules_core-js_internals_array-iteration_js-node_modules_core-js_internals_arra-a012fe\",\"vendors-node_modules_core-js_modules_es_array_includes_js-node_modules_core-js_modules_es_fun-f57f90\",\"vendors-node_modules_core-js_internals_add-to-unscopables_js-node_modules_core-js_internals_s-261a68\"].map(__webpack_require__.e, __webpack_require__)).then(next);\n};","","// run startup\nvar __webpack_exports__ = __webpack_require__.x();\n",""],"names":["IM_LOGS","ROOT_NAME","DEFAULT_ROOT","folders","roots","searches","omit","_1","link","_2","folder","_3","search","obj","hasId","f","id","split","includes","normalize","uuid","name","absFolderPath","l","luuid","color","rgb","u","i4u","view","rev","ms","md","n","i4n","s","i4ms","i4next","url","activesyncdisabled","webOfflineSyncDays","perm","recursive","rest","deletable","meta","acl","retentionPolicy","normalizeSearch","query","sortBy","types","normalizeLink","owner","zid","rid","ruuid","oname","reminder","broken","processSearch","soapSearch","parent","isLink","processLink","soapLink","depth","children","forEach","child","processFolder","push","soapFolder","handleFolderRefresh","soapFolders","handleFolderCreated","created","val","handleFolderModified","modified","Object","assign","oldParent","newParent","filter","handleFolderDeleted","deleted","handleFolderNotify","notify","onmessage","data","op","postMessage"],"sourceRoot":""}
@@ -372,7 +372,7 @@ onmessage = function onmessage(_ref) {
372
372
  /******/
373
373
  /******/ /* webpack/runtime/publicPath */
374
374
  /******/ (() => {
375
- /******/ __webpack_require__.p = "/static/iris/carbonio-shell-ui/c7ccd56ade6f4addd8a92e5fcf802aa3d2c0be11/";
375
+ /******/ __webpack_require__.p = "/static/iris/carbonio-shell-ui/10daf3b28c4be4fa1aca2a5f7e603e3490dc8d59/";
376
376
  /******/ })();
377
377
  /******/
378
378
  /******/ /* webpack/runtime/importScripts chunk loading */
@@ -434,4 +434,4 @@ onmessage = function onmessage(_ref) {
434
434
  /******/
435
435
  /******/ })()
436
436
  ;
437
- //# sourceMappingURL=src_workers_tag_ts.275881ac.chunk.js.map
437
+ //# sourceMappingURL=src_workers_tag_ts.f72cbbc5.chunk.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"src_workers_tag_ts.275881ac.chunk.js","mappings":";;;;;;;;;AAAA,aAAa,mBAAO,CAAC,uEAAqB;AAC1C,gBAAgB,mBAAO,CAAC,+EAAyB;AACjD,eAAe,mBAAO,CAAC,6EAAwB;AAC/C,oBAAoB,mBAAO,CAAC,uFAA6B;AACzD,wBAAwB,mBAAO,CAAC,mGAAmC;AACnE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;AC1CA,cAAc,mBAAO,CAAC,iFAA0B;AAChD,aAAa,mBAAO,CAAC,uEAAqB;AAC1C;AACA;;;;;;;;;;;;;ACHa;AACb,QAAQ,mBAAO,CAAC,uEAAqB;AACrC,cAAc,+GAAy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ACA,+BAA+B,wCAAwC;WACvE;WACA;WACA;WACA;WACA,iBAAiB,qBAAqB;WACtC;WACA;WACA,kBAAkB,qBAAqB;WACvC;WACA;WACA,KAAK;WACL;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;;;;;WC3BA;WACA;WACA;WACA;WACA;WACA,iCAAiC,WAAW;WAC5C;WACA;;;;;WCPA;WACA;WACA;WACA;WACA,yCAAyC,wCAAwC;WACjF;WACA;WACA;;;;;WCPA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,EAAE;WACF;;;;;WCRA;WACA;WACA;WACA,8BAA8B,oOAAoO;WAClQ;;;;;WCJA;WACA;WACA;WACA;WACA;;;;;WCJA;WACA;WACA;WACA;WACA,GAAG;WACH;WACA;WACA,CAAC;;;;;WCPD;;;;;WCAA;WACA;WACA;WACA,uDAAuD,iBAAiB;WACxE;WACA,gDAAgD,aAAa;WAC7D;;;;;WCNA;;;;;WCAA;;WAEA;WACA;WACA;WACA;WACA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,aAAa;WACb;WACA;WACA;WACA;;WAEA;WACA;WACA;;WAEA;;WAEA;;;;;WCpCA;WACA;WACA;WACA;WACA;WACA;WACA;;;;;UENA;UACA","sources":["webpack://@zextras/carbonio-shell-ui/./node_modules/core-js/internals/array-reduce.js","webpack://@zextras/carbonio-shell-ui/./node_modules/core-js/internals/engine-is-node.js","webpack://@zextras/carbonio-shell-ui/./node_modules/core-js/modules/es.array.reduce.js","webpack://@zextras/carbonio-shell-ui/./src/workers/tag.ts","webpack://@zextras/carbonio-shell-ui/webpack/bootstrap","webpack://@zextras/carbonio-shell-ui/webpack/runtime/chunk loaded","webpack://@zextras/carbonio-shell-ui/webpack/runtime/compat get default export","webpack://@zextras/carbonio-shell-ui/webpack/runtime/define property getters","webpack://@zextras/carbonio-shell-ui/webpack/runtime/ensure chunk","webpack://@zextras/carbonio-shell-ui/webpack/runtime/get javascript chunk filename","webpack://@zextras/carbonio-shell-ui/webpack/runtime/get mini-css chunk filename","webpack://@zextras/carbonio-shell-ui/webpack/runtime/global","webpack://@zextras/carbonio-shell-ui/webpack/runtime/hasOwnProperty shorthand","webpack://@zextras/carbonio-shell-ui/webpack/runtime/make namespace object","webpack://@zextras/carbonio-shell-ui/webpack/runtime/publicPath","webpack://@zextras/carbonio-shell-ui/webpack/runtime/importScripts chunk loading","webpack://@zextras/carbonio-shell-ui/webpack/runtime/startup chunk dependencies","webpack://@zextras/carbonio-shell-ui/webpack/before-startup","webpack://@zextras/carbonio-shell-ui/webpack/startup","webpack://@zextras/carbonio-shell-ui/webpack/after-startup"],"sourcesContent":["var global = require('../internals/global');\nvar aCallable = require('../internals/a-callable');\nvar toObject = require('../internals/to-object');\nvar IndexedObject = require('../internals/indexed-object');\nvar lengthOfArrayLike = require('../internals/length-of-array-like');\n\nvar TypeError = global.TypeError;\n\n// `Array.prototype.{ reduce, reduceRight }` methods implementation\nvar createMethod = function (IS_RIGHT) {\n return function (that, callbackfn, argumentsLength, memo) {\n aCallable(callbackfn);\n var O = toObject(that);\n var self = IndexedObject(O);\n var length = lengthOfArrayLike(O);\n var index = IS_RIGHT ? length - 1 : 0;\n var i = IS_RIGHT ? -1 : 1;\n if (argumentsLength < 2) while (true) {\n if (index in self) {\n memo = self[index];\n index += i;\n break;\n }\n index += i;\n if (IS_RIGHT ? index < 0 : length <= index) {\n throw TypeError('Reduce of empty array with no initial value');\n }\n }\n for (;IS_RIGHT ? index >= 0 : length > index; index += i) if (index in self) {\n memo = callbackfn(memo, self[index], index, O);\n }\n return memo;\n };\n};\n\nmodule.exports = {\n // `Array.prototype.reduce` method\n // https://tc39.es/ecma262/#sec-array.prototype.reduce\n left: createMethod(false),\n // `Array.prototype.reduceRight` method\n // https://tc39.es/ecma262/#sec-array.prototype.reduceright\n right: createMethod(true)\n};\n","var classof = require('../internals/classof-raw');\nvar global = require('../internals/global');\n\nmodule.exports = classof(global.process) == 'process';\n","'use strict';\nvar $ = require('../internals/export');\nvar $reduce = require('../internals/array-reduce').left;\nvar arrayMethodIsStrict = require('../internals/array-method-is-strict');\nvar CHROME_VERSION = require('../internals/engine-v8-version');\nvar IS_NODE = require('../internals/engine-is-node');\n\nvar STRICT_METHOD = arrayMethodIsStrict('reduce');\n// Chrome 80-82 has a critical bug\n// https://bugs.chromium.org/p/chromium/issues/detail?id=1049982\nvar CHROME_BUG = !IS_NODE && CHROME_VERSION > 79 && CHROME_VERSION < 83;\n\n// `Array.prototype.reduce` method\n// https://tc39.es/ecma262/#sec-array.prototype.reduce\n$({ target: 'Array', proto: true, forced: !STRICT_METHOD || CHROME_BUG }, {\n reduce: function reduce(callbackfn /* , initialValue */) {\n var length = arguments.length;\n return $reduce(this, callbackfn, length, length > 1 ? arguments[1] : undefined);\n }\n});\n","/*\n * SPDX-FileCopyrightText: 2022 Zextras <https://www.zextras.com>\n *\n * SPDX-License-Identifier: AGPL-3.0-only\n */\n\nimport { SoapNotify, Tag, TagMessage, Tags } from '../../types';\n\nexport const handleTagRefresh = (tags: Array<Tag>): Tags => {\n\tif (typeof tags !== 'undefined') {\n\t\treturn tags.reduce((acc: Tags, val: Tag): Tags => {\n\t\t\t// eslint-disable-next-line no-param-reassign\n\t\t\tacc[val.id] = val;\n\t\t\treturn acc;\n\t\t}, {});\n\t}\n\treturn {};\n};\n\nexport const handleTagCreated = (tags: Tags, created: Array<Tag>): Tags =>\n\tcreated.reduce((acc: Tags, val: Tag): Tags => {\n\t\t// eslint-disable-next-line no-param-reassign\n\t\tacc[val.id] = val;\n\t\treturn acc;\n\t}, tags);\nexport const handleTagModified = (tags: Tags, modified: Array<Partial<Tag>>): Tags =>\n\tmodified.reduce((acc: Tags, val: Partial<Tag>): Tags => {\n\t\tif (val.id) {\n\t\t\t// eslint-disable-next-line no-param-reassign\n\t\t\tacc[val.id] = { ...tags[val.id], ...val };\n\t\t}\n\t\treturn acc;\n\t}, tags);\nexport const handleTagDeleted = (tags: Tags, deleted: string[]): Tags =>\n\tdeleted.reduce((acc, val) => {\n\t\t// eslint-disable-next-line no-param-reassign\n\t\tdelete acc[val];\n\t\treturn acc;\n\t}, tags);\nexport const handleTagNotify = (notify: SoapNotify, state: Tags): Tags =>\n\thandleTagDeleted(\n\t\thandleTagModified(\n\t\t\thandleTagCreated(state, notify.created?.tag ?? []),\n\t\t\tnotify.modified?.tag ?? []\n\t\t),\n\t\tnotify.deleted ?? []\n\t);\n\nonmessage = ({ data }: TagMessage): void => {\n\tif (data.op === 'refresh' && data.tags) postMessage({ tags: handleTagRefresh(data.tags.tag) });\n\tif (data.op === 'notify') postMessage({ tags: handleTagNotify(data.notify, data.state) });\n};\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\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\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// the startup function\n__webpack_require__.x = () => {\n\t// Load entry module and return exports\n\t// This entry module depends on other loaded chunks and execution need to be delayed\n\tvar __webpack_exports__ = __webpack_require__.O(undefined, [\"vendors-node_modules_core-js_modules_es_array_filter_js-node_modules_core-js_modules_es_array-f8dfc2\",\"vendors-node_modules_core-js_internals_array-iteration_js-node_modules_core-js_internals_arra-a012fe\"], () => (__webpack_require__(\"./src/workers/tag.ts\")))\n\t__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n\treturn __webpack_exports__;\n};\n\n","var deferred = [];\n__webpack_require__.O = (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, fn, priority] = deferred[i];\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((key) => (__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};","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (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__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \".\" + {\"vendors-node_modules_core-js_modules_es_array_filter_js-node_modules_core-js_modules_es_array-f8dfc2\":\"5b2b999c\",\"vendors-node_modules_core-js_internals_array-iteration_js-node_modules_core-js_internals_arra-a012fe\":\"428e0a2a\"}[chunkId] + \".chunk.js\";\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.miniCssF = (chunkId) => {\n\t// return url for filenames based on template\n\treturn undefined;\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 = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (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__.p = \"/static/iris/carbonio-shell-ui/c7ccd56ade6f4addd8a92e5fcf802aa3d2c0be11/\";","// no baseURI\n\n// object to store loaded chunks\n// \"1\" means \"already loaded\"\nvar installedChunks = {\n\t\"src_workers_tag_ts\": 1\n};\n\n// importScripts chunk loading\nvar installChunk = (data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\tfor(var moduleId in moreModules) {\n\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t}\n\t}\n\tif(runtime) runtime(__webpack_require__);\n\twhile(chunkIds.length)\n\t\tinstalledChunks[chunkIds.pop()] = 1;\n\tparentChunkLoadingFunction(data);\n};\n__webpack_require__.f.i = (chunkId, promises) => {\n\t// \"1\" is the signal for \"already loaded\"\n\tif(!installedChunks[chunkId]) {\n\t\tif(true) { // all chunks have JS\n\t\t\timportScripts(__webpack_require__.p + __webpack_require__.u(chunkId));\n\t\t}\n\t}\n};\n\nvar chunkLoadingGlobal = self[\"webpackChunk_zextras_carbonio_shell_ui\"] = self[\"webpackChunk_zextras_carbonio_shell_ui\"] || [];\nvar parentChunkLoadingFunction = chunkLoadingGlobal.push.bind(chunkLoadingGlobal);\nchunkLoadingGlobal.push = installChunk;\n\n// no HMR\n\n// no HMR manifest","var next = __webpack_require__.x;\n__webpack_require__.x = () => {\n\treturn Promise.all([\n\t\t__webpack_require__.e(\"vendors-node_modules_core-js_modules_es_array_filter_js-node_modules_core-js_modules_es_array-f8dfc2\"),\n\t\t__webpack_require__.e(\"vendors-node_modules_core-js_internals_array-iteration_js-node_modules_core-js_internals_arra-a012fe\")\n\t]).then(next);\n};","","// run startup\nvar __webpack_exports__ = __webpack_require__.x();\n",""],"names":["handleTagRefresh","tags","reduce","acc","val","id","handleTagCreated","created","handleTagModified","modified","handleTagDeleted","deleted","handleTagNotify","notify","state","tag","onmessage","data","op","postMessage"],"sourceRoot":""}
1
+ {"version":3,"file":"src_workers_tag_ts.f72cbbc5.chunk.js","mappings":";;;;;;;;;AAAA,aAAa,mBAAO,CAAC,uEAAqB;AAC1C,gBAAgB,mBAAO,CAAC,+EAAyB;AACjD,eAAe,mBAAO,CAAC,6EAAwB;AAC/C,oBAAoB,mBAAO,CAAC,uFAA6B;AACzD,wBAAwB,mBAAO,CAAC,mGAAmC;AACnE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;AC1CA,cAAc,mBAAO,CAAC,iFAA0B;AAChD,aAAa,mBAAO,CAAC,uEAAqB;AAC1C;AACA;;;;;;;;;;;;;ACHa;AACb,QAAQ,mBAAO,CAAC,uEAAqB;AACrC,cAAc,+GAAyC;AACvD,0BAA0B,mBAAO,CAAC,uGAAqC;AACvE,qBAAqB,mBAAO,CAAC,6FAAgC;AAC7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BAAkB,qBAAqB;WACvC;WACA;WACA,KAAK;WACL;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;;;;;WC3BA;WACA;WACA;WACA;WACA;WACA,iCAAiC,WAAW;WAC5C;WACA;;;;;WCPA;WACA;WACA;WACA;WACA,yCAAyC,wCAAwC;WACjF;WACA;WACA;;;;;WCPA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,EAAE;WACF;;;;;WCRA;WACA;WACA;WACA,8BAA8B,oOAAoO;WAClQ;;;;;WCJA;WACA;WACA;WACA;WACA;;;;;WCJA;WACA;WACA;WACA;WACA,GAAG;WACH;WACA;WACA,CAAC;;;;;WCPD;;;;;WCAA;WACA;WACA;WACA,uDAAuD,iBAAiB;WACxE;WACA,gDAAgD,aAAa;WAC7D;;;;;WCNA;;;;;WCAA;;WAEA;WACA;WACA;WACA;WACA;;WAEA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA;WACA,aAAa;WACb;WACA;WACA;WACA;;WAEA;WACA;WACA;;WAEA;;WAEA;;;;;WCpCA;WACA;WACA;WACA;WACA;WACA;WACA;;;;;UENA;UACA","sources":["webpack://@zextras/carbonio-shell-ui/./node_modules/core-js/internals/array-reduce.js","webpack://@zextras/carbonio-shell-ui/./node_modules/core-js/internals/engine-is-node.js","webpack://@zextras/carbonio-shell-ui/./node_modules/core-js/modules/es.array.reduce.js","webpack://@zextras/carbonio-shell-ui/./src/workers/tag.ts","webpack://@zextras/carbonio-shell-ui/webpack/bootstrap","webpack://@zextras/carbonio-shell-ui/webpack/runtime/chunk loaded","webpack://@zextras/carbonio-shell-ui/webpack/runtime/compat get default export","webpack://@zextras/carbonio-shell-ui/webpack/runtime/define property getters","webpack://@zextras/carbonio-shell-ui/webpack/runtime/ensure chunk","webpack://@zextras/carbonio-shell-ui/webpack/runtime/get javascript chunk filename","webpack://@zextras/carbonio-shell-ui/webpack/runtime/get mini-css chunk filename","webpack://@zextras/carbonio-shell-ui/webpack/runtime/global","webpack://@zextras/carbonio-shell-ui/webpack/runtime/hasOwnProperty shorthand","webpack://@zextras/carbonio-shell-ui/webpack/runtime/make namespace object","webpack://@zextras/carbonio-shell-ui/webpack/runtime/publicPath","webpack://@zextras/carbonio-shell-ui/webpack/runtime/importScripts chunk loading","webpack://@zextras/carbonio-shell-ui/webpack/runtime/startup chunk dependencies","webpack://@zextras/carbonio-shell-ui/webpack/before-startup","webpack://@zextras/carbonio-shell-ui/webpack/startup","webpack://@zextras/carbonio-shell-ui/webpack/after-startup"],"sourcesContent":["var global = require('../internals/global');\nvar aCallable = require('../internals/a-callable');\nvar toObject = require('../internals/to-object');\nvar IndexedObject = require('../internals/indexed-object');\nvar lengthOfArrayLike = require('../internals/length-of-array-like');\n\nvar TypeError = global.TypeError;\n\n// `Array.prototype.{ reduce, reduceRight }` methods implementation\nvar createMethod = function (IS_RIGHT) {\n return function (that, callbackfn, argumentsLength, memo) {\n aCallable(callbackfn);\n var O = toObject(that);\n var self = IndexedObject(O);\n var length = lengthOfArrayLike(O);\n var index = IS_RIGHT ? length - 1 : 0;\n var i = IS_RIGHT ? -1 : 1;\n if (argumentsLength < 2) while (true) {\n if (index in self) {\n memo = self[index];\n index += i;\n break;\n }\n index += i;\n if (IS_RIGHT ? index < 0 : length <= index) {\n throw TypeError('Reduce of empty array with no initial value');\n }\n }\n for (;IS_RIGHT ? index >= 0 : length > index; index += i) if (index in self) {\n memo = callbackfn(memo, self[index], index, O);\n }\n return memo;\n };\n};\n\nmodule.exports = {\n // `Array.prototype.reduce` method\n // https://tc39.es/ecma262/#sec-array.prototype.reduce\n left: createMethod(false),\n // `Array.prototype.reduceRight` method\n // https://tc39.es/ecma262/#sec-array.prototype.reduceright\n right: createMethod(true)\n};\n","var classof = require('../internals/classof-raw');\nvar global = require('../internals/global');\n\nmodule.exports = classof(global.process) == 'process';\n","'use strict';\nvar $ = require('../internals/export');\nvar $reduce = require('../internals/array-reduce').left;\nvar arrayMethodIsStrict = require('../internals/array-method-is-strict');\nvar CHROME_VERSION = require('../internals/engine-v8-version');\nvar IS_NODE = require('../internals/engine-is-node');\n\nvar STRICT_METHOD = arrayMethodIsStrict('reduce');\n// Chrome 80-82 has a critical bug\n// https://bugs.chromium.org/p/chromium/issues/detail?id=1049982\nvar CHROME_BUG = !IS_NODE && CHROME_VERSION > 79 && CHROME_VERSION < 83;\n\n// `Array.prototype.reduce` method\n// https://tc39.es/ecma262/#sec-array.prototype.reduce\n$({ target: 'Array', proto: true, forced: !STRICT_METHOD || CHROME_BUG }, {\n reduce: function reduce(callbackfn /* , initialValue */) {\n var length = arguments.length;\n return $reduce(this, callbackfn, length, length > 1 ? arguments[1] : undefined);\n }\n});\n","/*\n * SPDX-FileCopyrightText: 2022 Zextras <https://www.zextras.com>\n *\n * SPDX-License-Identifier: AGPL-3.0-only\n */\n\nimport { SoapNotify, Tag, TagMessage, Tags } from '../../types';\n\nexport const handleTagRefresh = (tags: Array<Tag>): Tags => {\n\tif (typeof tags !== 'undefined') {\n\t\treturn tags.reduce((acc: Tags, val: Tag): Tags => {\n\t\t\t// eslint-disable-next-line no-param-reassign\n\t\t\tacc[val.id] = val;\n\t\t\treturn acc;\n\t\t}, {});\n\t}\n\treturn {};\n};\n\nexport const handleTagCreated = (tags: Tags, created: Array<Tag>): Tags =>\n\tcreated.reduce((acc: Tags, val: Tag): Tags => {\n\t\t// eslint-disable-next-line no-param-reassign\n\t\tacc[val.id] = val;\n\t\treturn acc;\n\t}, tags);\nexport const handleTagModified = (tags: Tags, modified: Array<Partial<Tag>>): Tags =>\n\tmodified.reduce((acc: Tags, val: Partial<Tag>): Tags => {\n\t\tif (val.id) {\n\t\t\t// eslint-disable-next-line no-param-reassign\n\t\t\tacc[val.id] = { ...tags[val.id], ...val };\n\t\t}\n\t\treturn acc;\n\t}, tags);\nexport const handleTagDeleted = (tags: Tags, deleted: string[]): Tags =>\n\tdeleted.reduce((acc, val) => {\n\t\t// eslint-disable-next-line no-param-reassign\n\t\tdelete acc[val];\n\t\treturn acc;\n\t}, tags);\nexport const handleTagNotify = (notify: SoapNotify, state: Tags): Tags =>\n\thandleTagDeleted(\n\t\thandleTagModified(\n\t\t\thandleTagCreated(state, notify.created?.tag ?? []),\n\t\t\tnotify.modified?.tag ?? []\n\t\t),\n\t\tnotify.deleted ?? []\n\t);\n\nonmessage = ({ data }: TagMessage): void => {\n\tif (data.op === 'refresh' && data.tags) postMessage({ tags: handleTagRefresh(data.tags.tag) });\n\tif (data.op === 'notify') postMessage({ tags: handleTagNotify(data.notify, data.state) });\n};\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\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId](module, module.exports, __webpack_require__);\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// the startup function\n__webpack_require__.x = () => {\n\t// Load entry module and return exports\n\t// This entry module depends on other loaded chunks and execution need to be delayed\n\tvar __webpack_exports__ = __webpack_require__.O(undefined, [\"vendors-node_modules_core-js_modules_es_array_filter_js-node_modules_core-js_modules_es_array-f8dfc2\",\"vendors-node_modules_core-js_internals_array-iteration_js-node_modules_core-js_internals_arra-a012fe\"], () => (__webpack_require__(\"./src/workers/tag.ts\")))\n\t__webpack_exports__ = __webpack_require__.O(__webpack_exports__);\n\treturn __webpack_exports__;\n};\n\n","var deferred = [];\n__webpack_require__.O = (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, fn, priority] = deferred[i];\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((key) => (__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};","// getDefaultExport function for compatibility with non-harmony modules\n__webpack_require__.n = (module) => {\n\tvar getter = module && module.__esModule ?\n\t\t() => (module['default']) :\n\t\t() => (module);\n\t__webpack_require__.d(getter, { a: getter });\n\treturn getter;\n};","// define getter functions for harmony exports\n__webpack_require__.d = (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__.f = {};\n// This file contains only the entry chunk.\n// The chunk loading function for additional chunks\n__webpack_require__.e = (chunkId) => {\n\treturn Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {\n\t\t__webpack_require__.f[key](chunkId, promises);\n\t\treturn promises;\n\t}, []));\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.u = (chunkId) => {\n\t// return url for filenames based on template\n\treturn \"\" + chunkId + \".\" + {\"vendors-node_modules_core-js_modules_es_array_filter_js-node_modules_core-js_modules_es_array-f8dfc2\":\"5b2b999c\",\"vendors-node_modules_core-js_internals_array-iteration_js-node_modules_core-js_internals_arra-a012fe\":\"428e0a2a\"}[chunkId] + \".chunk.js\";\n};","// This function allow to reference async chunks and sibling chunks for the entrypoint\n__webpack_require__.miniCssF = (chunkId) => {\n\t// return url for filenames based on template\n\treturn undefined;\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 = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))","// define __esModule on exports\n__webpack_require__.r = (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__.p = \"/static/iris/carbonio-shell-ui/10daf3b28c4be4fa1aca2a5f7e603e3490dc8d59/\";","// no baseURI\n\n// object to store loaded chunks\n// \"1\" means \"already loaded\"\nvar installedChunks = {\n\t\"src_workers_tag_ts\": 1\n};\n\n// importScripts chunk loading\nvar installChunk = (data) => {\n\tvar [chunkIds, moreModules, runtime] = data;\n\tfor(var moduleId in moreModules) {\n\t\tif(__webpack_require__.o(moreModules, moduleId)) {\n\t\t\t__webpack_require__.m[moduleId] = moreModules[moduleId];\n\t\t}\n\t}\n\tif(runtime) runtime(__webpack_require__);\n\twhile(chunkIds.length)\n\t\tinstalledChunks[chunkIds.pop()] = 1;\n\tparentChunkLoadingFunction(data);\n};\n__webpack_require__.f.i = (chunkId, promises) => {\n\t// \"1\" is the signal for \"already loaded\"\n\tif(!installedChunks[chunkId]) {\n\t\tif(true) { // all chunks have JS\n\t\t\timportScripts(__webpack_require__.p + __webpack_require__.u(chunkId));\n\t\t}\n\t}\n};\n\nvar chunkLoadingGlobal = self[\"webpackChunk_zextras_carbonio_shell_ui\"] = self[\"webpackChunk_zextras_carbonio_shell_ui\"] || [];\nvar parentChunkLoadingFunction = chunkLoadingGlobal.push.bind(chunkLoadingGlobal);\nchunkLoadingGlobal.push = installChunk;\n\n// no HMR\n\n// no HMR manifest","var next = __webpack_require__.x;\n__webpack_require__.x = () => {\n\treturn Promise.all([\n\t\t__webpack_require__.e(\"vendors-node_modules_core-js_modules_es_array_filter_js-node_modules_core-js_modules_es_array-f8dfc2\"),\n\t\t__webpack_require__.e(\"vendors-node_modules_core-js_internals_array-iteration_js-node_modules_core-js_internals_arra-a012fe\")\n\t]).then(next);\n};","","// run startup\nvar __webpack_exports__ = __webpack_require__.x();\n",""],"names":["handleTagRefresh","tags","reduce","acc","val","id","handleTagCreated","created","handleTagModified","modified","handleTagDeleted","deleted","handleTagNotify","notify","state","tag","onmessage","data","op","postMessage"],"sourceRoot":""}
@@ -139,4 +139,4 @@ body {
139
139
  }
140
140
 
141
141
 
142
- /*# sourceMappingURL=style.e1b357a2.css.map*/
142
+ /*# sourceMappingURL=style.b11f5282.css.map*/
@@ -1 +1 @@
1
- {"version":3,"file":"style.e1b357a2.css","mappings":";;;AAAA;;;;EAIE;AAGF;;EACE;EACA;EACA;AAAF;AAGA;EACE;EACA;AADF;AAIA;EACE;EACA;EACA;EACA;EACA;EACA;EACA;AAFF;AAKA;EACC;EACA;EACA;AAHD;AAMA;EACC;IACC;EAJA;AACF;AAOA;EACC;IACC;EALA;AACF;;;;;ACtCA;;;;EAIE;AAEF;EACC;IAAG,gBAAgB;IAEjB;IACA;EAAD;EAED;IACE;EAAD;EAGD;IACE;IADC,gBAAgB;IAGjB;EADD;AACF;AAbA;EACC;IAAG,gBAAgB;IAEjB;IACA;EAAD;EAED;IACE;EAAD;EAGD;IACE;IADC,gBAAgB;IAGjB;EADD;AACF;AAIA;EACC;EACA;EACA;EACA;EACA;EACA;AAFD;AAIA;EACC;EACA;EACA;EACA;EAEA;UAAA;EACA;UAAA;EACA;UAAA;EACA;UAAA;EACA;UAAA;AAHD;AAKA;EACC;EACA;EACA;EACA;EACA;EACA;EACA;EACA;AAHD;AAKA;EACC;IACC;IACA;EAHA;EAKD;IACC;EAHA;EAKD;IACC;EAHA;AACF;AAMA;EACC;IACC;IACA;EAJA;EAMD;IACC;EAJA;EAMD;IACC;EAJA;AACF","sources":["webpack://@zextras/carbonio-shell-ui/./src/index.css","webpack://@zextras/carbonio-shell-ui/./src/splash.css"],"sourcesContent":["/*\n * SPDX-FileCopyrightText: 2021 Zextras <https://www.zextras.com>\n *\n * SPDX-License-Identifier: AGPL-3.0-only\n */\n\n\nhtml, body {\n height: 100vh;\n width: 100vw;\n overflow: hidden;\n}\n\nbody {\n margin: 0;\n font-family: \"Roboto\", sans-serif;\n}\n\n#app {\n display: flex;\n flex-direction: column;\n width: 100vw;\n max-width: 100vw;\n height: 100%;\n min-height: 100%;\n max-height: 100%;\n}\n\n.tox.tox-tinymce {\n\twidth: 100%;\n\theight: 100%;\n\tborder: none;\n}\n\n@media (prefers-color-scheme: dark) {\n\thtml {\n\t\tbackground: #00506D;\n\t}\n}\n\n@media (prefers-color-scheme: light) {\n\thtml {\n\t\tbackground: #e5e5e5;\n\t}\n}\n","/*\n * SPDX-FileCopyrightText: 2021 Zextras <https://www.zextras.com>\n *\n * SPDX-License-Identifier: AGPL-3.0-only\n */\n\n@keyframes loader-animation {\n\t0% {\n\t\t\t/* width: 15%; */\n\t\t\twidth: 20%;\n\t\t\tleft: 0%;\n\t}\n\t50% {\n\t\t\twidth: 50%;\n\t}\n\n\t100% {\n\t\t\tleft: 100%;\n\t\t\t/* width: 15%; */\n\t\t\twidth: 20%;\n\t\t\t\n\t}\n}\n.loader {\n\theight: 4px;\n\tmin-height: 4px;\n\tposition: relative;\n\twidth: 100%;\n\toverflow-x: clip;\n\toverflow-y: visible;\n}\n.loader .bar {\n\tposition: absolute;\n\ttransform: translateX(-50%);\n\ttop: -2px;\n\theight: 8px;\n\t\n\tanimation-name: loader-animation;\n\tanimation-direction: alternate;\n\tanimation-duration: 1.5s;\n\tanimation-iteration-count: infinite;\n\tanimation-timing-function: ease-in-out;\n}\n.splash {\n\twidth: 100vw;\n\theight: 100vh;\n\tdisplay: flex;\n\tflex-direction: column;\n\talign-items: center;\n\tjustify-content: space-evenly;\n\tpadding: 15vh 30vw;\n\tbox-sizing: border-box;\n}\n@media (prefers-color-scheme: dark) {\n\t.splash {\n\t\tbackground: #00506D;\n\t\tcolor: #FFFFFF;\n\t}\n\t.loader .bar {\n\t\tbackground-color: #FFFFFF;\n\t}\n\t.loader {\n\t\tbackground: #AAC8EE;\n\t}\n}\n\n@media (prefers-color-scheme: light) {\n\t.splash {\n\t\tbackground: #e5e5e5;\n\t\tcolor: #A3AEBC;\n\t}\n\t.loader .bar {\n\t\tbackground-color: #00506D;\n\t}\n\t.loader {\n\t\tbackground: #FFFFFF;\n\t}\n}\n"],"names":[],"sourceRoot":""}
1
+ {"version":3,"file":"style.b11f5282.css","mappings":";;;AAAA;;;;EAIE;AAGF;;EACE;EACA;EACA;AAAF;AAGA;EACE;EACA;AADF;AAIA;EACE;EACA;EACA;EACA;EACA;EACA;EACA;AAFF;AAKA;EACC;EACA;EACA;AAHD;AAMA;EACC;IACC;EAJA;AACF;AAOA;EACC;IACC;EALA;AACF;;;;;ACtCA;;;;EAIE;AAEF;EACC;IAAG,gBAAgB;IAEjB;IACA;EAAD;EAED;IACE;EAAD;EAGD;IACE;IADC,gBAAgB;IAGjB;EADD;AACF;AAbA;EACC;IAAG,gBAAgB;IAEjB;IACA;EAAD;EAED;IACE;EAAD;EAGD;IACE;IADC,gBAAgB;IAGjB;EADD;AACF;AAIA;EACC;EACA;EACA;EACA;EACA;EACA;AAFD;AAIA;EACC;EACA;EACA;EACA;EAEA;UAAA;EACA;UAAA;EACA;UAAA;EACA;UAAA;EACA;UAAA;AAHD;AAKA;EACC;EACA;EACA;EACA;EACA;EACA;EACA;EACA;AAHD;AAKA;EACC;IACC;IACA;EAHA;EAKD;IACC;EAHA;EAKD;IACC;EAHA;AACF;AAMA;EACC;IACC;IACA;EAJA;EAMD;IACC;EAJA;EAMD;IACC;EAJA;AACF","sources":["webpack://@zextras/carbonio-shell-ui/./src/index.css","webpack://@zextras/carbonio-shell-ui/./src/splash.css"],"sourcesContent":["/*\n * SPDX-FileCopyrightText: 2021 Zextras <https://www.zextras.com>\n *\n * SPDX-License-Identifier: AGPL-3.0-only\n */\n\n\nhtml, body {\n height: 100vh;\n width: 100vw;\n overflow: hidden;\n}\n\nbody {\n margin: 0;\n font-family: \"Roboto\", sans-serif;\n}\n\n#app {\n display: flex;\n flex-direction: column;\n width: 100vw;\n max-width: 100vw;\n height: 100%;\n min-height: 100%;\n max-height: 100%;\n}\n\n.tox.tox-tinymce {\n\twidth: 100%;\n\theight: 100%;\n\tborder: none;\n}\n\n@media (prefers-color-scheme: dark) {\n\thtml {\n\t\tbackground: #00506D;\n\t}\n}\n\n@media (prefers-color-scheme: light) {\n\thtml {\n\t\tbackground: #e5e5e5;\n\t}\n}\n","/*\n * SPDX-FileCopyrightText: 2021 Zextras <https://www.zextras.com>\n *\n * SPDX-License-Identifier: AGPL-3.0-only\n */\n\n@keyframes loader-animation {\n\t0% {\n\t\t\t/* width: 15%; */\n\t\t\twidth: 20%;\n\t\t\tleft: 0%;\n\t}\n\t50% {\n\t\t\twidth: 50%;\n\t}\n\n\t100% {\n\t\t\tleft: 100%;\n\t\t\t/* width: 15%; */\n\t\t\twidth: 20%;\n\t\t\t\n\t}\n}\n.loader {\n\theight: 4px;\n\tmin-height: 4px;\n\tposition: relative;\n\twidth: 100%;\n\toverflow-x: clip;\n\toverflow-y: visible;\n}\n.loader .bar {\n\tposition: absolute;\n\ttransform: translateX(-50%);\n\ttop: -2px;\n\theight: 8px;\n\t\n\tanimation-name: loader-animation;\n\tanimation-direction: alternate;\n\tanimation-duration: 1.5s;\n\tanimation-iteration-count: infinite;\n\tanimation-timing-function: ease-in-out;\n}\n.splash {\n\twidth: 100vw;\n\theight: 100vh;\n\tdisplay: flex;\n\tflex-direction: column;\n\talign-items: center;\n\tjustify-content: space-evenly;\n\tpadding: 15vh 30vw;\n\tbox-sizing: border-box;\n}\n@media (prefers-color-scheme: dark) {\n\t.splash {\n\t\tbackground: #00506D;\n\t\tcolor: #FFFFFF;\n\t}\n\t.loader .bar {\n\t\tbackground-color: #FFFFFF;\n\t}\n\t.loader {\n\t\tbackground: #AAC8EE;\n\t}\n}\n\n@media (prefers-color-scheme: light) {\n\t.splash {\n\t\tbackground: #e5e5e5;\n\t\tcolor: #A3AEBC;\n\t}\n\t.loader .bar {\n\t\tbackground-color: #00506D;\n\t}\n\t.loader {\n\t\tbackground: #FFFFFF;\n\t}\n}\n"],"names":[],"sourceRoot":""}
@@ -47104,26 +47104,28 @@ var _excluded$b = ["item", "children"],
47104
47104
  var AccordionContainerEl = styled__default["default"](Container$1).withConfig({
47105
47105
  displayName: "Accordion__AccordionContainerEl",
47106
47106
  componentId: "sc-s8zgku-0"
47107
- })(["padding-left:", ";background-color:", ";", ";"], function (_ref) {
47107
+ })(["padding-left:", ";padding-right:", ";background-color:", ";", ";"], function (_ref) {
47108
47108
  var theme = _ref.theme,
47109
47109
  level = _ref.level;
47110
- return styled.css(["calc(", " * ", ")"], level, theme.sizes.padding.large);
47110
+ return styled.css(["calc(", " * ", ")"], Math.min(level + 1, 5), theme.sizes.padding.small);
47111
47111
  }, function (_ref2) {
47112
- var theme = _ref2.theme,
47113
- background = _ref2.background;
47114
- _ref2.item;
47115
- var active = _ref2.active;
47116
- return theme.palette[active ? 'highlight' : background].regular;
47112
+ var theme = _ref2.theme;
47113
+ return theme.sizes.padding.small;
47117
47114
  }, function (_ref3) {
47118
47115
  var theme = _ref3.theme,
47119
47116
  background = _ref3.background,
47120
- item = _ref3.item;
47117
+ active = _ref3.active;
47118
+ return theme.palette[active ? 'highlight' : background].regular;
47119
+ }, function (_ref4) {
47120
+ var theme = _ref4.theme,
47121
+ background = _ref4.background,
47122
+ item = _ref4.item;
47121
47123
  return !item.disableHover && pseudoClasses(theme, item.active ? 'highlight' : background);
47122
47124
  });
47123
- var AccordionItem = /*#__PURE__*/React__default["default"].forwardRef(function AccordionItemFn(_ref4, ref) {
47124
- var item = _ref4.item,
47125
- children = _ref4.children,
47126
- rest = _objectWithoutProperties(_ref4, _excluded$b);
47125
+ var AccordionItem = /*#__PURE__*/React__default["default"].forwardRef(function AccordionItemFn(_ref5, ref) {
47126
+ var item = _ref5.item,
47127
+ children = _ref5.children,
47128
+ rest = _objectWithoutProperties(_ref5, _excluded$b);
47127
47129
 
47128
47130
  return /*#__PURE__*/React__default["default"].createElement(Container$1, _extends({
47129
47131
  orientation: "horizontal",
@@ -47159,13 +47161,13 @@ var AccordionItem = /*#__PURE__*/React__default["default"].forwardRef(function A
47159
47161
  value: item.badgeCounter
47160
47162
  })), children);
47161
47163
  });
47162
- var AccordionRoot = /*#__PURE__*/React__default["default"].forwardRef(function AccordionRootFn(_ref5, ref) {
47163
- var level = _ref5.level,
47164
- item = _ref5.item,
47165
- background = _ref5.background,
47166
- activeId = _ref5.activeId,
47167
- openIds = _ref5.openIds,
47168
- rest = _objectWithoutProperties(_ref5, _excluded2$4);
47164
+ var AccordionRoot = /*#__PURE__*/React__default["default"].forwardRef(function AccordionRootFn(_ref6, ref) {
47165
+ var level = _ref6.level,
47166
+ item = _ref6.item,
47167
+ background = _ref6.background,
47168
+ activeId = _ref6.activeId,
47169
+ openIds = _ref6.openIds,
47170
+ rest = _objectWithoutProperties(_ref6, _excluded2$4);
47169
47171
 
47170
47172
  var _useState = React.useState(!!item.open),
47171
47173
  _useState2 = _slicedToArray(_useState, 2),
@@ -47180,7 +47182,15 @@ var AccordionRoot = /*#__PURE__*/React__default["default"].forwardRef(function A
47180
47182
  });
47181
47183
  }, [item.id, item.open, openIds]);
47182
47184
  var handleClick = React.useCallback(function (e) {
47183
- setOpen(true);
47185
+ setOpen(function (op) {
47186
+ if (op) return op;
47187
+
47188
+ if (item.onOpen) {
47189
+ item.onOpen(e);
47190
+ }
47191
+
47192
+ return true;
47193
+ });
47184
47194
  if (item.onClick) item.onClick(e);
47185
47195
  }, [item]);
47186
47196
  var expandOnIconClick = React.useCallback(function (e) {
@@ -47245,13 +47255,13 @@ var AccordionRoot = /*#__PURE__*/React__default["default"].forwardRef(function A
47245
47255
  background: background
47246
47256
  }))));
47247
47257
  });
47248
- var Accordion = /*#__PURE__*/React__default["default"].forwardRef(function AccordionFn(_ref6, ref) {
47249
- var items = _ref6.items,
47250
- level = _ref6.level,
47251
- background = _ref6.background,
47252
- activeId = _ref6.activeId,
47253
- openIds = _ref6.openIds,
47254
- rest = _objectWithoutProperties(_ref6, _excluded3$1);
47258
+ var Accordion = /*#__PURE__*/React__default["default"].forwardRef(function AccordionFn(_ref7, ref) {
47259
+ var items = _ref7.items,
47260
+ level = _ref7.level,
47261
+ background = _ref7.background,
47262
+ activeId = _ref7.activeId,
47263
+ openIds = _ref7.openIds,
47264
+ rest = _objectWithoutProperties(_ref7, _excluded3$1);
47255
47265
 
47256
47266
  return /*#__PURE__*/React__default["default"].createElement(Container$1, _extends({
47257
47267
  orientation: "vertical",
@@ -47261,10 +47271,10 @@ var Accordion = /*#__PURE__*/React__default["default"].forwardRef(function Accor
47261
47271
  background: background,
47262
47272
  ref: ref
47263
47273
  }, rest), map_1(items, function (item, index) {
47264
- var _ref7, _item$id;
47274
+ var _ref8, _item$id;
47265
47275
 
47266
47276
  return /*#__PURE__*/React__default["default"].createElement(AccordionRoot, {
47267
- key: (_ref7 = (_item$id = item.id) !== null && _item$id !== void 0 ? _item$id : item.label) !== null && _ref7 !== void 0 ? _ref7 : index,
47277
+ key: (_ref8 = (_item$id = item.id) !== null && _item$id !== void 0 ? _item$id : item.label) !== null && _ref8 !== void 0 ? _ref8 : index,
47268
47278
  level: level,
47269
47279
  item: item,
47270
47280
  background: background,
@@ -49193,7 +49203,7 @@ var CustomModal = /*#__PURE__*/React__default["default"].forwardRef(function Mod
49193
49203
  var defaultOverflowY = windowObj.document.body.style.overflowY;
49194
49204
  var defaultPaddingRight = windowObj.document.body.style.paddingRight;
49195
49205
  windowObj.document.body.style.overflowY = 'hidden';
49196
- isBodyOverflowing(modalRef, windowObj) && (windowObj.document.body.style.paddingRight = "".concat(getScrollbarSize(), "px"));
49206
+ isBodyOverflowing(modalRef, windowObj) && (windowObj.document.body.style.paddingRight = "".concat(getScrollbarSize(windowObj), "px"));
49197
49207
  return function () {
49198
49208
  windowObj.document.body.style.overflowY = defaultOverflowY;
49199
49209
  windowObj.document.body.style.paddingRight = defaultPaddingRight;
@@ -53162,7 +53172,7 @@ var ImagePreview = react__WEBPACK_IMPORTED_MODULE_0___default().forwardRef(funct
53162
53172
  react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_Header__WEBPACK_IMPORTED_MODULE_2__["default"], { actions: actions, filename: filename, extension: extension, size: size, closeAction: closeAction }),
53163
53173
  react__WEBPACK_IMPORTED_MODULE_0___default().createElement(MiddleContainer, { orientation: "horizontal", crossAlignment: "unset", minHeight: 0 },
53164
53174
  react__WEBPACK_IMPORTED_MODULE_0___default().createElement(PreviewContainer, { ref: previewRef },
53165
- react__WEBPACK_IMPORTED_MODULE_0___default().createElement(Image, { alt: alt !== null && alt !== void 0 ? alt : filename, src: src, onError: function () { return console.log('TODO handle error'); }, ref: imageRef }))))))));
53175
+ react__WEBPACK_IMPORTED_MODULE_0___default().createElement(Image, { alt: alt !== null && alt !== void 0 ? alt : filename, src: src, onError: function (error) { return console.error('TODO handle error', error); }, ref: imageRef }))))))));
53166
53176
  });
53167
53177
 
53168
53178
  var templateObject_1, templateObject_2, templateObject_3, templateObject_4, templateObject_5;
@@ -53246,6 +53256,7 @@ var zoomStep = [800, 1000, 1200, 1400, 1600, 2000, 2400, 3200];
53246
53256
  var PdfPreview = react__WEBPACK_IMPORTED_MODULE_0___default().forwardRef(function PreviewFn(_a, ref) {
53247
53257
  var src = _a.src, show = _a.show, container = _a.container, disablePortal = _a.disablePortal, _b = _a.extension, extension = _b === void 0 ? '' : _b, _c = _a.filename, filename = _c === void 0 ? '' : _c, _d = _a.size, size = _d === void 0 ? '' : _d, _e = _a.actions, actions = _e === void 0 ? [] : _e, closeAction = _a.closeAction, onClose = _a.onClose, _f = _a.useFallback, useFallback = _f === void 0 ? false : _f, customContent = _a.customContent, _g = _a.renderTextLayer, renderTextLayer = _g === void 0 ? false : _g, openSrc = _a.openSrc, titleLabel = _a.titleLabel, contentLabel = _a.contentLabel, downloadLabel = _a.downloadLabel, openLabel = _a.openLabel, noteLabel = _a.noteLabel, _h = _a.zoomOutLabel, zoomOutLabel = _h === void 0 ? 'Zoom out' : _h, _j = _a.fitToWidthLabel, fitToWidthLabel = _j === void 0 ? 'Fit to width' : _j, _k = _a.lowerLimitReachedLabel, lowerLimitReachedLabel = _k === void 0 ? 'Minimum zoom level reached' : _k, _l = _a.resetZoomLabel, resetZoomLabel = _l === void 0 ? 'Reset zoom' : _l, _m = _a.upperLimitReachedLabel, upperLimitReachedLabel = _m === void 0 ? 'Maximum zoom level reached' : _m, _o = _a.zoomInLabel, zoomInLabel = _o === void 0 ? 'Zoom in' : _o;
53248
53258
  var previewRef = (0,_zextras_carbonio_design_system__WEBPACK_IMPORTED_MODULE_9__.useCombinedRefs)(ref);
53259
+ var documentLoaded = (0,react__WEBPACK_IMPORTED_MODULE_0__.useRef)(useFallback);
53249
53260
  var _p = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)(null), numPages = _p[0], setNumPages = _p[1];
53250
53261
  var $closeAction = (0,react__WEBPACK_IMPORTED_MODULE_0__.useMemo)(function () {
53251
53262
  if (closeAction) {
@@ -53253,16 +53264,29 @@ var PdfPreview = react__WEBPACK_IMPORTED_MODULE_0___default().forwardRef(functio
53253
53264
  }
53254
53265
  return closeAction;
53255
53266
  }, [closeAction, onClose]);
53267
+ var escapeEvent = (0,react__WEBPACK_IMPORTED_MODULE_0__.useCallback)(function (event) {
53268
+ if (event.key === 'Escape') {
53269
+ onClose(event);
53270
+ }
53271
+ }, [onClose]);
53272
+ (0,react__WEBPACK_IMPORTED_MODULE_0__.useEffect)(function () {
53273
+ if (show) {
53274
+ document.addEventListener('keyup', escapeEvent);
53275
+ }
53276
+ return function () {
53277
+ document.removeEventListener('keyup', escapeEvent);
53278
+ };
53279
+ }, [escapeEvent, show]);
53256
53280
  var onOverlayClick = (0,react__WEBPACK_IMPORTED_MODULE_0__.useCallback)(function (event) {
53257
- // TODO: stop propagation or not?
53258
53281
  event.stopPropagation();
53259
- (useFallback || numPages) &&
53282
+ // close preview on click on overlay only if document is loaded (both success or error)
53283
+ documentLoaded.current &&
53260
53284
  previewRef.current &&
53261
53285
  !event.isDefaultPrevented() &&
53262
53286
  (previewRef.current === event.target ||
53263
53287
  !previewRef.current.contains(event.target)) &&
53264
53288
  onClose(event);
53265
- }, [numPages, onClose, previewRef, useFallback]);
53289
+ }, [onClose, previewRef]);
53266
53290
  var _q = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)(zoomStep[0]), currentZoom = _q[0], setCurrentZoom = _q[1];
53267
53291
  var _r = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)(true), incrementable = _r[0], setIncrementable = _r[1];
53268
53292
  var _s = (0,react__WEBPACK_IMPORTED_MODULE_0__.useState)(false), decrementable = _s[0], setDecrementable = _s[1];
@@ -53346,14 +53370,31 @@ var PdfPreview = react__WEBPACK_IMPORTED_MODULE_0___default().forwardRef(functio
53346
53370
  }, [currentZoom, numPages, renderTextLayer]);
53347
53371
  var onDocumentLoadSuccess = (0,react__WEBPACK_IMPORTED_MODULE_0__.useCallback)(function (args) {
53348
53372
  setNumPages(args.numPages);
53373
+ documentLoaded.current = true;
53374
+ }, []);
53375
+ var onDocumentLoadError = (0,react__WEBPACK_IMPORTED_MODULE_0__.useCallback)(function () {
53376
+ documentLoaded.current = true;
53377
+ }, []);
53378
+ var onDocumentLoadProgress = (0,react__WEBPACK_IMPORTED_MODULE_0__.useCallback)(function () {
53379
+ documentLoaded.current = false;
53349
53380
  }, []);
53350
53381
  var file = (0,react__WEBPACK_IMPORTED_MODULE_0__.useMemo)(function () { return ({ url: src }); }, [src]);
53351
53382
  var $customContent = (0,react__WEBPACK_IMPORTED_MODULE_0__.useMemo)(function () {
53352
53383
  if (useFallback) {
53353
- return (customContent || react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_PreviewCriteriaAlternativeContent__WEBPACK_IMPORTED_MODULE_7__.PreviewCriteriaAlternativeContent, { downloadSrc: src, openSrc: openSrc, contentLabel: contentLabel, downloadLabel: downloadLabel, noteLabel: noteLabel, openLabel: openLabel, titleLabel: titleLabel }));
53384
+ return (customContent || (react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_PreviewCriteriaAlternativeContent__WEBPACK_IMPORTED_MODULE_7__.PreviewCriteriaAlternativeContent, { downloadSrc: src, openSrc: openSrc, contentLabel: contentLabel, downloadLabel: downloadLabel, noteLabel: noteLabel, openLabel: openLabel, titleLabel: titleLabel })));
53354
53385
  }
53355
53386
  return undefined;
53356
- }, [customContent, openSrc, src, useFallback, contentLabel, downloadLabel, noteLabel, openLabel, titleLabel]);
53387
+ }, [
53388
+ customContent,
53389
+ openSrc,
53390
+ src,
53391
+ useFallback,
53392
+ contentLabel,
53393
+ downloadLabel,
53394
+ noteLabel,
53395
+ openLabel,
53396
+ titleLabel
53397
+ ]);
53357
53398
  return (react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_zextras_carbonio_design_system__WEBPACK_IMPORTED_MODULE_9__.Portal, { show: show, disablePortal: disablePortal, container: container },
53358
53399
  react__WEBPACK_IMPORTED_MODULE_0___default().createElement(Overlay, { onClick: onOverlayClick },
53359
53400
  react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_FocusWithin__WEBPACK_IMPORTED_MODULE_5__["default"], null,
@@ -53367,7 +53408,7 @@ var PdfPreview = react__WEBPACK_IMPORTED_MODULE_0___default().forwardRef(functio
53367
53408
  react__WEBPACK_IMPORTED_MODULE_0___default().createElement(CustomIconButton, { icon: "Plus", size: "small", backgroundColor: "gray0", iconColor: "gray6", onClick: increaseOfOneStep, disabled: !incrementable })))),
53368
53409
  react__WEBPACK_IMPORTED_MODULE_0___default().createElement(_Header__WEBPACK_IMPORTED_MODULE_6__["default"], { actions: actions, filename: filename, extension: extension, size: size, closeAction: $closeAction }),
53369
53410
  react__WEBPACK_IMPORTED_MODULE_0___default().createElement(MiddleContainer, { orientation: "horizontal", crossAlignment: "unset", minHeight: 0 },
53370
- react__WEBPACK_IMPORTED_MODULE_0___default().createElement(PreviewContainer, { ref: previewRef }, $customContent || (react__WEBPACK_IMPORTED_MODULE_0___default().createElement(react_pdf_dist_esm_entry_webpack__WEBPACK_IMPORTED_MODULE_4__.Document, { file: file, onLoadSuccess: onDocumentLoadSuccess }, pageElements)))))))));
53411
+ react__WEBPACK_IMPORTED_MODULE_0___default().createElement(PreviewContainer, { ref: previewRef }, $customContent || (react__WEBPACK_IMPORTED_MODULE_0___default().createElement(react_pdf_dist_esm_entry_webpack__WEBPACK_IMPORTED_MODULE_4__.Document, { file: file, onLoadSuccess: onDocumentLoadSuccess, onLoadError: onDocumentLoadError, onLoadProgress: onDocumentLoadProgress }, pageElements)))))))));
53371
53412
  });
53372
53413
 
53373
53414
  var templateObject_1, templateObject_2, templateObject_3, templateObject_4, templateObject_5, templateObject_6, templateObject_7;
@@ -251085,4 +251126,4 @@ var loadLanguages = instance.loadLanguages;
251085
251126
  /***/ })
251086
251127
 
251087
251128
  }]);
251088
- //# sourceMappingURL=vendors-node_modules_reduxjs_toolkit_dist_redux-toolkit_esm_js-node_modules_sentry_browser_es-eb34a0.8b6b16b5.chunk.js.map
251129
+ //# sourceMappingURL=vendors-node_modules_reduxjs_toolkit_dist_redux-toolkit_esm_js-node_modules_sentry_browser_es-eb34a0.e0814547.chunk.js.map