@alfresco/aca-shared 4.3.0 → 4.4.0-6803224597

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 (28) hide show
  1. package/esm2020/lib/components/document-base-page/document-base-page.component.mjs +3 -3
  2. package/esm2020/lib/components/info-drawer/info-drawer.component.mjs +3 -4
  3. package/esm2020/lib/components/toolbar/toolbar-button/toolbar-button.component.mjs +2 -2
  4. package/esm2020/lib/components/toolbar/toolbar-menu-item/toolbar-menu-item.component.mjs +2 -2
  5. package/esm2020/lib/directives/contextmenu/contextmenu.directive.mjs +3 -6
  6. package/esm2020/lib/services/app.extension.service.mjs +5 -5
  7. package/esm2020/rules/app.rules.mjs +14 -26
  8. package/esm2020/rules/navigation.rules.mjs +13 -13
  9. package/esm2020/store/actions/router.actions.mjs +1 -1
  10. package/esm2020/store/actions/search.actions.mjs +1 -1
  11. package/esm2020/store/actions/template.actions.mjs +1 -1
  12. package/esm2020/store/effects/router.effects.mjs +5 -5
  13. package/fesm2015/alfresco-aca-shared-rules.mjs +34 -37
  14. package/fesm2015/alfresco-aca-shared-rules.mjs.map +1 -1
  15. package/fesm2015/alfresco-aca-shared-store.mjs +6 -4
  16. package/fesm2015/alfresco-aca-shared-store.mjs.map +1 -1
  17. package/fesm2015/alfresco-aca-shared.mjs +19 -16
  18. package/fesm2015/alfresco-aca-shared.mjs.map +1 -1
  19. package/fesm2020/alfresco-aca-shared-rules.mjs +25 -37
  20. package/fesm2020/alfresco-aca-shared-rules.mjs.map +1 -1
  21. package/fesm2020/alfresco-aca-shared-store.mjs +4 -4
  22. package/fesm2020/alfresco-aca-shared-store.mjs.map +1 -1
  23. package/fesm2020/alfresco-aca-shared.mjs +12 -16
  24. package/fesm2020/alfresco-aca-shared.mjs.map +1 -1
  25. package/package.json +1 -1
  26. package/store/actions/router.actions.d.ts +0 -1
  27. package/store/actions/search.actions.d.ts +0 -1
  28. package/store/actions/template.actions.d.ts +0 -2
@@ -35,7 +35,7 @@ function isPreview(context) {
35
35
  */
36
36
  function isFavorites(context) {
37
37
  const { url } = context.navigation;
38
- return url && url.startsWith('/favorites') && !isPreview(context);
38
+ return url?.startsWith('/favorites') && !isPreview(context);
39
39
  }
40
40
  /**
41
41
  * Checks if the activated route is not **Favorites**.
@@ -48,7 +48,7 @@ const isNotFavorites = (context) => !isFavorites(context);
48
48
  */
49
49
  function isSharedFiles(context) {
50
50
  const { url } = context.navigation;
51
- return url && url.startsWith('/shared') && !isPreview(context);
51
+ return url?.startsWith('/shared') && !isPreview(context);
52
52
  }
53
53
  /**
54
54
  * Checks if the activated route is not **Shared Files**.
@@ -61,7 +61,7 @@ const isNotSharedFiles = (context) => !isSharedFiles(context);
61
61
  */
62
62
  function isTrashcan(context) {
63
63
  const { url } = context.navigation;
64
- return url && url.startsWith('/trashcan');
64
+ return url?.startsWith('/trashcan');
65
65
  }
66
66
  /**
67
67
  * Checks if the activated route is not **Trashcan**.
@@ -74,7 +74,7 @@ const isNotTrashcan = (context) => !isTrashcan(context);
74
74
  */
75
75
  function isPersonalFiles(context) {
76
76
  const { url } = context.navigation;
77
- return url && url.startsWith('/personal-files');
77
+ return url?.startsWith('/personal-files');
78
78
  }
79
79
  /**
80
80
  * Checks if a **Library Files** route is activated.
@@ -82,7 +82,7 @@ function isPersonalFiles(context) {
82
82
  */
83
83
  function isLibraryFiles(context) {
84
84
  const { url } = context.navigation;
85
- return url && url.startsWith('/libraries');
85
+ return url?.startsWith('/libraries');
86
86
  }
87
87
  /**
88
88
  * Checks if a **Library Files** or **Library Search Result** route is activated.
@@ -90,11 +90,11 @@ function isLibraryFiles(context) {
90
90
  */
91
91
  function isLibraries(context) {
92
92
  const { url } = context.navigation;
93
- return url && (url.endsWith('/libraries') || url.startsWith('/search-libraries'));
93
+ return url?.endsWith('/libraries') || url?.startsWith('/search-libraries');
94
94
  }
95
95
  function isLibraryContent(context) {
96
96
  const { url } = context.navigation;
97
- return url && (url.endsWith('/libraries') || url.includes('/libraries/') || url.startsWith('/search-libraries'));
97
+ return url?.endsWith('/libraries') || url?.includes('/libraries/') || url?.startsWith('/search-libraries');
98
98
  }
99
99
  /**
100
100
  * Checks if the activated route is neither **Libraries** nor **Library Search Results**.
@@ -107,7 +107,7 @@ const isNotLibraries = (context) => !isLibraries(context);
107
107
  */
108
108
  function isRecentFiles(context) {
109
109
  const { url } = context.navigation;
110
- return url && url.startsWith('/recent-files');
110
+ return url?.startsWith('/recent-files');
111
111
  }
112
112
  /**
113
113
  * Checks if the activated route is not **Recent Files**.
@@ -122,7 +122,7 @@ function isSearchResults(context
122
122
  // ...args: RuleParameter[]
123
123
  ) {
124
124
  const { url } = context.navigation;
125
- return url && url.startsWith('/search');
125
+ return url?.startsWith('/search');
126
126
  }
127
127
  /**
128
128
  * Checks if the activated route is not **Search Results**.
@@ -135,7 +135,7 @@ const isNotSearchResults = (context) => !isSearchResults(context);
135
135
  */
136
136
  function isSharedPreview(context) {
137
137
  const { url } = context.navigation;
138
- return url && (url.startsWith('/shared/preview/') || (url.startsWith('/shared') && url.includes('viewer:view')));
138
+ return url?.startsWith('/shared/preview/') || (url?.startsWith('/shared') && url?.includes('viewer:view'));
139
139
  }
140
140
  /**
141
141
  * Checks if a **Favorites Preview** route is activated.
@@ -143,7 +143,7 @@ function isSharedPreview(context) {
143
143
  */
144
144
  function isFavoritesPreview(context) {
145
145
  const { url } = context.navigation;
146
- return url && (url.startsWith('/favorites/preview/') || (url.startsWith('/favorites') && url.includes('viewer:view')));
146
+ return url?.startsWith('/favorites/preview/') || (url?.startsWith('/favorites') && url?.includes('viewer:view'));
147
147
  }
148
148
  /**
149
149
  * Checks if a **Shared File Preview** route is activated.
@@ -151,7 +151,7 @@ function isFavoritesPreview(context) {
151
151
  */
152
152
  function isSharedFileViewer(context) {
153
153
  const { url } = context.navigation;
154
- return url && url.startsWith('/preview/s/');
154
+ return url?.startsWith('/preview/s/');
155
155
  }
156
156
 
157
157
  /*!
@@ -366,7 +366,7 @@ function isShared(context) {
366
366
  return true;
367
367
  }
368
368
  if (isNotTrashcan(context) && !context.selection.isEmpty && context.selection.file) {
369
- return !!(context.selection.file.entry && context.selection.file.entry.properties && context.selection.file.entry.properties['qshare:sharedId']);
369
+ return !!context.selection.file.entry?.properties?.['qshare:sharedId'];
370
370
  }
371
371
  return false;
372
372
  }
@@ -441,13 +441,7 @@ const canCreateLibrary = (context) => [isContentServiceEnabled(context), isLibra
441
441
  * JSON ref: `app.navigation.folder.canUpload`
442
442
  */
443
443
  function canUpload(context) {
444
- if (isContentServiceEnabled(context) && (isPersonalFiles(context) || isLibraryContent(context))) {
445
- const { currentFolder } = context.navigation;
446
- if (currentFolder) {
447
- return context.permissions.check(currentFolder, ['create']);
448
- }
449
- }
450
- return false;
444
+ return canCreateFolder(context);
451
445
  }
452
446
  /**
453
447
  * Checks if user can download selected nodes (either files or folders).
@@ -474,8 +468,7 @@ const hasLibrarySelected = (context) => !!context.selection.library;
474
468
  * JSON ref: `app.selection.isPrivateLibrary`
475
469
  */
476
470
  function isPrivateLibrary(context) {
477
- const library = context.selection.library;
478
- return library ? !!(library.entry && library.entry.visibility && library.entry.visibility === 'PRIVATE') : false;
471
+ return context.selection.library?.entry?.visibility === 'PRIVATE';
479
472
  }
480
473
  /**
481
474
  * Checks if the selected library has a **role** property defined.
@@ -483,7 +476,7 @@ function isPrivateLibrary(context) {
483
476
  */
484
477
  function hasLibraryRole(context) {
485
478
  const library = context.selection.library;
486
- return library ? !!(library.entry && library.entry.role) : false;
479
+ return library ? !!library.entry?.role : false;
487
480
  }
488
481
  /**
489
482
  * Checks if the selected library has no **role** property defined.
@@ -494,7 +487,7 @@ const hasNoLibraryRole = (context) => !hasLibraryRole(context);
494
487
  * Checks if user has selected a file.
495
488
  * JSON ref: `app.selection.file`
496
489
  */
497
- const hasFileSelected = (context) => !!(context && context.selection && context.selection.file);
490
+ const hasFileSelected = (context) => !!context?.selection?.file;
498
491
  /**
499
492
  * Checks if user can update the first selected node.
500
493
  * JSON ref: `app.selection.first.canUpdate`
@@ -534,12 +527,12 @@ function canUpdateSelectedFolder(context) {
534
527
  * JSON ref: `app.selection.file.isLocked`
535
528
  */
536
529
  function hasLockedFiles(context) {
537
- if (context && context.selection && context.selection.nodes) {
530
+ if (context?.selection?.nodes) {
538
531
  return context.selection.nodes.some((node) => {
539
532
  if (!node.entry.isFile) {
540
533
  return false;
541
534
  }
542
- return node.entry.isLocked || (node.entry.properties && node.entry.properties['cm:lockType'] === 'READ_ONLY_LOCK');
535
+ return node.entry.isLocked || node.entry.properties?.['cm:lockType'] === 'READ_ONLY_LOCK';
543
536
  });
544
537
  }
545
538
  return false;
@@ -548,13 +541,8 @@ function hasLockedFiles(context) {
548
541
  * Checks if the selected file has **write** or **read-only** locks specified.
549
542
  * JSON ref: `app.selection.file.isLocked`
550
543
  */
551
- const isWriteLocked = (context) => !!(context &&
552
- context.selection &&
553
- context.selection.file &&
554
- context.selection.file.entry &&
555
- context.selection.file.entry.properties &&
556
- (context.selection.file.entry.properties['cm:lockType'] === 'WRITE_LOCK' ||
557
- context.selection.file.entry.properties['cm:lockType'] === 'READ_ONLY_LOCK'));
544
+ const isWriteLocked = (context) => !!(context?.selection?.file?.entry?.properties?.['cm:lockType'] === 'WRITE_LOCK' ||
545
+ context?.selection?.file?.entry?.properties?.['cm:lockType'] === 'READ_ONLY_LOCK');
558
546
  /**
559
547
  * Checks if the selected file has **write** or **read-only** locks specified,
560
548
  * and that current user is the owner of the lock.
@@ -707,14 +695,14 @@ function canOpenWithOffice(context) {
707
695
  if (flag !== 'true') {
708
696
  return false;
709
697
  }
710
- if (context.navigation && context.navigation.url && context.navigation.url.startsWith('/trashcan')) {
698
+ if (context.navigation?.url?.startsWith('/trashcan')) {
711
699
  return false;
712
700
  }
713
- if (!context || !context.selection) {
701
+ if (!context?.selection) {
714
702
  return false;
715
703
  }
716
704
  const { file } = context.selection;
717
- if (!file || !file.entry) {
705
+ if (!file?.entry) {
718
706
  return false;
719
707
  }
720
708
  const extension = getFileExtension(file.entry.name);
@@ -735,7 +723,7 @@ function canOpenWithOffice(context) {
735
723
  return false;
736
724
  }
737
725
  // workaround for Shared files
738
- if (context.navigation && context.navigation.url && context.navigation.url.startsWith('/shared')) {
726
+ if (context.navigation?.url?.startsWith('/shared')) {
739
727
  // eslint-disable-next-line no-prototype-builtins
740
728
  if (file.entry.hasOwnProperty('allowableOperationsOnTarget')) {
741
729
  return context.permissions.check(file, ['update'], {
@@ -1 +1 @@
1
- {"version":3,"file":"alfresco-aca-shared-rules.mjs","sources":["../../../../projects/aca-shared/rules/src/navigation.rules.ts","../../../../projects/aca-shared/rules/src/repository.rules.ts","../../../../projects/aca-shared/rules/src/user.rules.ts","../../../../projects/aca-shared/rules/src/app.rules.ts","../../../../projects/aca-shared/rules/src/public-api.ts","../../../../projects/aca-shared/rules/src/alfresco-aca-shared-rules.ts"],"sourcesContent":["/*!\n * Copyright © 2005-2023 Hyland Software, Inc. and its affiliates. All rights reserved.\n *\n * Alfresco Example Content Application\n *\n * This file is part of the Alfresco Example Content Application.\n * If the software was purchased under a paid Alfresco license, the terms of\n * the paid license agreement will prevail. Otherwise, the software is\n * provided under the following open source license terms:\n *\n * The Alfresco Example Content Application is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Lesser General Public License as published by\n * the Free Software Foundation, either version 3 of the License, or\n * (at your option) any later version.\n *\n * The Alfresco Example Content Application 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 Lesser General Public License for more details.\n *\n * You should have received a copy of the GNU Lesser General Public License\n * from Hyland Software. If not, see <http://www.gnu.org/licenses/>.\n */\n\nimport { RuleContext } from '@alfresco/adf-extensions';\n\n/**\n * Checks if a Preview route is activated.\n * JSON ref: `app.navigation.isPreview`\n */\nexport function isPreview(context: RuleContext): boolean {\n const { url } = context.navigation;\n return url && (url.includes('/preview/') || url.includes('viewer:view') || url.includes('/view/'));\n}\n\n/**\n * Checks if a **Favorites** route is activated.\n * JSON ref: `app.navigation.isFavorites`\n */\nexport function isFavorites(context: RuleContext): boolean {\n const { url } = context.navigation;\n return url && url.startsWith('/favorites') && !isPreview(context);\n}\n\n/**\n * Checks if the activated route is not **Favorites**.\n * JSON ref: `app.navigation.isNotFavorites`\n */\nexport const isNotFavorites = (context: RuleContext): boolean => !isFavorites(context);\n\n/**\n * Checks if a **Shared Files** route is activated.\n * JSON ref: `app.navigation.isSharedFiles`\n */\nexport function isSharedFiles(context: RuleContext): boolean {\n const { url } = context.navigation;\n return url && url.startsWith('/shared') && !isPreview(context);\n}\n\n/**\n * Checks if the activated route is not **Shared Files**.\n * JSON ref: `app.navigation.isNotSharedFiles`\n */\nexport const isNotSharedFiles = (context: RuleContext): boolean => !isSharedFiles(context);\n\n/**\n * Checks if a **Trashcan** route is activated.\n * JSON ref: `app.navigation.isTrashcan`\n */\nexport function isTrashcan(context: RuleContext): boolean {\n const { url } = context.navigation;\n return url && url.startsWith('/trashcan');\n}\n\n/**\n * Checks if the activated route is not **Trashcan**.\n * JSON ref: `app.navigation.isNotTrashcan`\n */\nexport const isNotTrashcan = (context: RuleContext): boolean => !isTrashcan(context);\n\n/**\n * Checks if a **Personal Files** route is activated.\n * JSON ref: `app.navigation.isPersonalFiles`\n */\nexport function isPersonalFiles(context: RuleContext): boolean {\n const { url } = context.navigation;\n return url && url.startsWith('/personal-files');\n}\n\n/**\n * Checks if a **Library Files** route is activated.\n * JSON ref: `app.navigation.isLibraryFiles`\n */\nexport function isLibraryFiles(context: RuleContext): boolean {\n const { url } = context.navigation;\n return url && url.startsWith('/libraries');\n}\n\n/**\n * Checks if a **Library Files** or **Library Search Result** route is activated.\n * JSON ref: `app.navigation.isLibraryFiles`\n */\nexport function isLibraries(context: RuleContext): boolean {\n const { url } = context.navigation;\n return url && (url.endsWith('/libraries') || url.startsWith('/search-libraries'));\n}\n\nexport function isLibraryContent(context: RuleContext): boolean {\n const { url } = context.navigation;\n return url && (url.endsWith('/libraries') || url.includes('/libraries/') || url.startsWith('/search-libraries'));\n}\n\n/**\n * Checks if the activated route is neither **Libraries** nor **Library Search Results**.\n * JSON ref: `app.navigation.isNotLibraries`\n */\nexport const isNotLibraries = (context: RuleContext): boolean => !isLibraries(context);\n\n/**\n * Checks if a **Recent Files** route is activated.\n * JSON ref: `app.navigation.isRecentFiles`\n */\nexport function isRecentFiles(context: RuleContext): boolean {\n const { url } = context.navigation;\n return url && url.startsWith('/recent-files');\n}\n\n/**\n * Checks if the activated route is not **Recent Files**.\n * JSON ref: `app.navigation.isNotRecentFiles`\n */\nexport const isNotRecentFiles = (context: RuleContext): boolean => !isRecentFiles(context);\n\n/**\n * Checks if a **Search Results** route is activated.\n * JSON ref: `app.navigation.isSearchResults`\n */\nexport function isSearchResults(\n context: RuleContext\n // ...args: RuleParameter[]\n): boolean {\n const { url } = context.navigation;\n return url && url.startsWith('/search');\n}\n\n/**\n * Checks if the activated route is not **Search Results**.\n * JSON ref: `app.navigation.isNotSearchResults`\n */\nexport const isNotSearchResults = (context: RuleContext): boolean => !isSearchResults(context);\n\n/**\n * Checks if a **Shared Preview** route is activated.\n * JSON ref: `app.navigation.isSharedPreview`\n */\nexport function isSharedPreview(context: RuleContext): boolean {\n const { url } = context.navigation;\n return url && (url.startsWith('/shared/preview/') || (url.startsWith('/shared') && url.includes('viewer:view')));\n}\n\n/**\n * Checks if a **Favorites Preview** route is activated.\n * JSON ref: `app.navigation.isFavoritesPreview`\n */\nexport function isFavoritesPreview(context: RuleContext): boolean {\n const { url } = context.navigation;\n return url && (url.startsWith('/favorites/preview/') || (url.startsWith('/favorites') && url.includes('viewer:view')));\n}\n\n/**\n * Checks if a **Shared File Preview** route is activated.\n * JSON ref: `app.navigation.isFavoritesPreview`\n */\nexport function isSharedFileViewer(context: RuleContext): boolean {\n const { url } = context.navigation;\n return url && url.startsWith('/preview/s/');\n}\n","/*!\n * Copyright © 2005-2023 Hyland Software, Inc. and its affiliates. All rights reserved.\n *\n * Alfresco Example Content Application\n *\n * This file is part of the Alfresco Example Content Application.\n * If the software was purchased under a paid Alfresco license, the terms of\n * the paid license agreement will prevail. Otherwise, the software is\n * provided under the following open source license terms:\n *\n * The Alfresco Example Content Application is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Lesser General Public License as published by\n * the Free Software Foundation, either version 3 of the License, or\n * (at your option) any later version.\n *\n * The Alfresco Example Content Application 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 Lesser General Public License for more details.\n *\n * You should have received a copy of the GNU Lesser General Public License\n * from Hyland Software. If not, see <http://www.gnu.org/licenses/>.\n */\n\nimport { RuleContext } from '@alfresco/adf-extensions';\n\n/**\n * Checks if the quick share repository option is enabled or not.\n * JSON ref: `repository.isQuickShareEnabled`\n */\nexport const hasQuickShareEnabled = (context: RuleContext): boolean => context.repository.status.isQuickShareEnabled;\n\nexport function isMajorVersionAvailable(context: RuleContext, versionNumber: string): boolean {\n const majorVersion = context.repository.version?.major ? parseInt(context.repository.version.major, 10) : 0;\n return majorVersion >= parseInt(versionNumber, 10);\n}\n","/*!\n * Copyright © 2005-2023 Hyland Software, Inc. and its affiliates. All rights reserved.\n *\n * Alfresco Example Content Application\n *\n * This file is part of the Alfresco Example Content Application.\n * If the software was purchased under a paid Alfresco license, the terms of\n * the paid license agreement will prevail. Otherwise, the software is\n * provided under the following open source license terms:\n *\n * The Alfresco Example Content Application is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Lesser General Public License as published by\n * the Free Software Foundation, either version 3 of the License, or\n * (at your option) any later version.\n *\n * The Alfresco Example Content Application 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 Lesser General Public License for more details.\n *\n * You should have received a copy of the GNU Lesser General Public License\n * from Hyland Software. If not, see <http://www.gnu.org/licenses/>.\n */\n\nimport { RuleContext } from '@alfresco/adf-extensions';\n\n/**\n * Checks if user is admin.\n * JSON ref: `user.isAdmin`\n */\nexport const isAdmin = (context: RuleContext): boolean => context.profile.isAdmin;\n","/*!\n * Copyright © 2005-2023 Hyland Software, Inc. and its affiliates. All rights reserved.\n *\n * Alfresco Example Content Application\n *\n * This file is part of the Alfresco Example Content Application.\n * If the software was purchased under a paid Alfresco license, the terms of\n * the paid license agreement will prevail. Otherwise, the software is\n * provided under the following open source license terms:\n *\n * The Alfresco Example Content Application is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Lesser General Public License as published by\n * the Free Software Foundation, either version 3 of the License, or\n * (at your option) any later version.\n *\n * The Alfresco Example Content Application 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 Lesser General Public License for more details.\n *\n * You should have received a copy of the GNU Lesser General Public License\n * from Hyland Software. If not, see <http://www.gnu.org/licenses/>.\n */\n\nimport { AppConfigService } from '@alfresco/adf-core';\nimport { RuleContext } from '@alfresco/adf-extensions';\nimport * as navigation from './navigation.rules';\nimport * as repository from './repository.rules';\nimport { isAdmin } from './user.rules';\n\n/* cspell:disable */\nexport const supportedExtensions = {\n doc: 'ms-word',\n docx: 'ms-word',\n docm: 'ms-word',\n dot: 'ms-word',\n dotx: 'ms-word',\n dotm: 'ms-word',\n rtf: 'ms-word',\n xls: 'ms-excel',\n xlsx: 'ms-excel',\n xlsb: 'ms-excel',\n xlsm: 'ms-excel',\n xlt: 'ms-excel',\n xltx: 'ms-excel',\n xltm: 'ms-excel',\n xlam: 'ms-excel',\n ppt: 'ms-powerpoint',\n pptx: 'ms-powerpoint',\n pot: 'ms-powerpoint',\n potx: 'ms-powerpoint',\n potm: 'ms-powerpoint',\n pptm: 'ms-powerpoint',\n pps: 'ms-powerpoint',\n ppsx: 'ms-powerpoint',\n ppam: 'ms-powerpoint',\n ppsm: 'ms-powerpoint',\n sldx: 'ms-powerpoint',\n sldm: 'ms-powerpoint',\n vsd: 'ms-visio',\n vss: 'ms-visio',\n vst: 'ms-visio',\n vsdx: 'ms-visio',\n vsdm: 'ms-visio',\n vssx: 'ms-visio',\n vssm: 'ms-visio',\n vstx: 'ms-visio',\n vstm: 'ms-visio'\n};\n/* cspell:enable */\n\nexport function getFileExtension(fileName: string): string | null {\n if (fileName) {\n const match = fileName.match(/\\.([^\\./\\?\\#]+)($|\\?|\\#)/);\n\n return match ? match[1] : null;\n }\n\n return null;\n}\n\nexport interface AcaRuleContext extends RuleContext {\n withCredentials: boolean;\n appConfig: AppConfigService;\n}\n\n/**\n * Checks if the content plugin is enabled.\n * JSON ref: `app.isContentServiceEnabled`\n */\nexport const isContentServiceEnabled = (context: AcaRuleContext): boolean => {\n const flag = context.appConfig.get<boolean | string>('plugins.contentService');\n return flag === true || flag === 'true';\n};\n\n/**\n * Checks if Search is supported for active view\n * JSON ref: `app.isSearchSupported`\n */\nexport const isSearchSupported = (context: RuleContext): boolean =>\n [navigation.isNotSearchResults(context) /* , !hasSelection(context)*/].every(Boolean);\n\n/**\n * Checks if upload action is supported for the given context\n * JSON ref: `app.isUploadSupported`\n *\n * @param context Rule execution context\n */\nexport const isUploadSupported = (context: AcaRuleContext): boolean =>\n [isContentServiceEnabled(context), navigation.isPersonalFiles(context) || navigation.isLibraryContent(context), canUpload(context)].every(Boolean);\n/**\n * Checks if user can copy selected node.\n * JSON ref: `app.canCopyNode`\n *\n * @param context Rule execution context\n */\nexport const canCopyNode = (context: RuleContext): boolean =>\n [hasSelection(context), navigation.isNotTrashcan(context), navigation.isNotLibraries(context)].every(Boolean);\n\n/**\n * Checks if user can mark selected nodes as **Favorite**.\n * JSON ref: `app.selection.canAddFavorite`\n */\nexport function canAddFavorite(context: RuleContext): boolean {\n if (!context.selection.isEmpty) {\n if (navigation.isFavorites(context) || navigation.isLibraries(context) || navigation.isTrashcan(context)) {\n return false;\n }\n return context.selection.nodes.some((node) => !node.entry.isFavorite);\n }\n return false;\n}\n\n/**\n * Checks if user can un-mark selected nodes as **Favorite**.\n * JSON ref: `app.selection.canRemoveFavorite`\n */\nexport function canRemoveFavorite(context: RuleContext): boolean {\n if (!context.selection.isEmpty && !navigation.isTrashcan(context)) {\n if (navigation.isFavorites(context)) {\n return true;\n }\n return context.selection.nodes.every((node) => node.entry.isFavorite);\n }\n return false;\n}\n\n/**\n * Checks if user can share selected file.\n * JSON ref: `app.selection.file.canShare`\n */\nexport const canShareFile = (context: RuleContext): boolean =>\n [context.selection.file, navigation.isNotTrashcan(context), repository.hasQuickShareEnabled(context), !isShared(context)].every(Boolean);\n\n/**\n * Checks if user can perform \"Join\" or \"Cancel Join Request\" on a library.\n * JSON ref: `canToggleJoinLibrary`\n */\nexport const canToggleJoinLibrary = (context: RuleContext): boolean =>\n [hasLibrarySelected(context), !isPrivateLibrary(context), hasNoLibraryRole(context)].every(Boolean) ||\n [hasLibrarySelected(context), isPrivateLibrary(context), hasNoLibraryRole(context), isAdmin(context)].every(Boolean);\n\n/**\n * Checks if user can edit the selected folder.\n * JSON ref: `canEditFolder`\n *\n * @param context Rule execution context\n */\nexport const canEditFolder = (context: RuleContext): boolean => [canUpdateSelectedFolder(context), navigation.isNotTrashcan(context)].every(Boolean);\n\n/**\n * Checks if the selected file is already shared.\n * JSON ref: `app.selection.file.isShared`\n */\nexport function isShared(context: RuleContext): boolean {\n if (navigation.isSharedFiles(context) && context.selection.file) {\n return true;\n }\n\n if (navigation.isNotTrashcan(context) && !context.selection.isEmpty && context.selection.file) {\n return !!(context.selection.file.entry && context.selection.file.entry.properties && context.selection.file.entry.properties['qshare:sharedId']);\n }\n\n return false;\n}\n\n/**\n * Checks if user can delete selected nodes.\n * JSON ref: `app.selection.canDelete`\n */\nexport function canDeleteSelection(context: RuleContext): boolean {\n if (\n navigation.isNotTrashcan(context) &&\n navigation.isNotLibraries(context) &&\n navigation.isNotSearchResults(context) &&\n !context.selection.isEmpty\n ) {\n if (hasLockedFiles(context)) {\n return false;\n }\n\n // temp workaround for Favorites api\n if (navigation.isFavorites(context)) {\n return true;\n }\n\n if (navigation.isPreview(context)) {\n return context.permissions.check(context.selection.nodes, ['delete']);\n }\n\n // workaround for Shared Files\n if (navigation.isSharedFiles(context)) {\n return context.permissions.check(context.selection.nodes, ['delete'], {\n target: 'allowableOperationsOnTarget'\n });\n }\n\n return context.permissions.check(context.selection.nodes, ['delete']);\n }\n return false;\n}\n\n/**\n * Checks if user can un-share selected nodes.\n * JSON ref: `app.selection.canUnshare`\n */\nexport function canUnshareNodes(context: RuleContext): boolean {\n if (!context.selection.isEmpty) {\n return context.permissions.check(context.selection.nodes, ['delete'], {\n target: 'allowableOperationsOnTarget'\n });\n }\n return false;\n}\n\n/**\n * Checks if user selected anything.\n * JSON ref: `app.selection.notEmpty`\n */\nexport const hasSelection = (context: RuleContext): boolean => !context.selection.isEmpty;\n\n/**\n * Checks if user can create a new folder with current path.\n * JSON ref: `app.navigation.folder.canCreate`\n */\nexport function canCreateFolder(context: AcaRuleContext): boolean {\n if (isContentServiceEnabled(context) && (navigation.isPersonalFiles(context) || navigation.isLibraryContent(context))) {\n const { currentFolder } = context.navigation;\n\n if (currentFolder) {\n return context.permissions.check(currentFolder, ['create']);\n }\n }\n return false;\n}\n\n/**\n * Checks if user can create a Library\n * JSON ref: `app.canCreateLibrary`\n *\n * @param context Rule execution context\n */\nexport const canCreateLibrary = (context: AcaRuleContext): boolean =>\n [isContentServiceEnabled(context), navigation.isLibraries(context)].every(Boolean);\n\n/**\n * Checks if user can upload content to current folder.\n * JSON ref: `app.navigation.folder.canUpload`\n */\nexport function canUpload(context: AcaRuleContext): boolean {\n if (isContentServiceEnabled(context) && (navigation.isPersonalFiles(context) || navigation.isLibraryContent(context))) {\n const { currentFolder } = context.navigation;\n\n if (currentFolder) {\n return context.permissions.check(currentFolder, ['create']);\n }\n }\n return false;\n}\n\n/**\n * Checks if user can download selected nodes (either files or folders).\n * JSON ref: `app.selection.canDownload`\n */\nexport function canDownloadSelection(context: RuleContext): boolean {\n if (!context.selection.isEmpty && navigation.isNotTrashcan(context)) {\n return context.selection.nodes.every((node: any) => node.entry && (node.entry.isFile || node.entry.isFolder || !!node.entry.nodeId));\n }\n return false;\n}\n\n/**\n * Checks if user has selected a folder.\n * JSON ref: `app.selection.folder`\n */\nexport const hasFolderSelected = (context: RuleContext): boolean => !!context.selection.folder;\n\n/**\n * Checks if user has selected a library (site).\n * JSON ref: `app.selection.library`\n */\nexport const hasLibrarySelected = (context: RuleContext): boolean => !!context.selection.library;\n\n/**\n * Checks if user has selected a **private** library (site)\n * JSON ref: `app.selection.isPrivateLibrary`\n */\nexport function isPrivateLibrary(context: RuleContext): boolean {\n const library = context.selection.library;\n return library ? !!(library.entry && library.entry.visibility && library.entry.visibility === 'PRIVATE') : false;\n}\n\n/**\n * Checks if the selected library has a **role** property defined.\n * JSON ref: `app.selection.hasLibraryRole`\n */\nexport function hasLibraryRole(context: RuleContext): boolean {\n const library = context.selection.library;\n return library ? !!(library.entry && library.entry.role) : false;\n}\n\n/**\n * Checks if the selected library has no **role** property defined.\n * JSON ref: `app.selection.hasNoLibraryRole`\n */\nexport const hasNoLibraryRole = (context: RuleContext): boolean => !hasLibraryRole(context);\n\n/**\n * Checks if user has selected a file.\n * JSON ref: `app.selection.file`\n */\nexport const hasFileSelected = (context: RuleContext): boolean => !!(context && context.selection && context.selection.file);\n\n/**\n * Checks if user can update the first selected node.\n * JSON ref: `app.selection.first.canUpdate`\n */\nexport function canUpdateSelectedNode(context: RuleContext): boolean {\n if (context.selection && !context.selection.isEmpty) {\n const node = context.selection.first;\n\n if (node?.entry.isFile && hasLockedFiles(context)) {\n return false;\n }\n\n return context.permissions.check(node, ['update']);\n }\n return false;\n}\n\nexport function isMultiselection(context: RuleContext): boolean {\n let isMultiNodeSelected = false;\n if (context.selection && !context.selection.isEmpty) {\n isMultiNodeSelected = context.selection.count > 1;\n }\n return isMultiNodeSelected;\n}\n\n/**\n * Checks if user can update the first selected folder.\n * JSON ref: `app.selection.folder.canUpdate`\n */\nexport function canUpdateSelectedFolder(context: RuleContext): boolean {\n const { folder } = context.selection;\n if (folder) {\n return (\n // workaround for Favorites Api\n navigation.isFavorites(context) || context.permissions.check(folder.entry, ['update'])\n );\n }\n return false;\n}\n\n/**\n * Checks if user has selected a **locked** file node.\n * JSON ref: `app.selection.file.isLocked`\n */\nexport function hasLockedFiles(context: RuleContext): boolean {\n if (context && context.selection && context.selection.nodes) {\n return context.selection.nodes.some((node) => {\n if (!node.entry.isFile) {\n return false;\n }\n\n return node.entry.isLocked || (node.entry.properties && node.entry.properties['cm:lockType'] === 'READ_ONLY_LOCK');\n });\n }\n\n return false;\n}\n\n/**\n * Checks if the selected file has **write** or **read-only** locks specified.\n * JSON ref: `app.selection.file.isLocked`\n */\nexport const isWriteLocked = (context: RuleContext): boolean =>\n !!(\n context &&\n context.selection &&\n context.selection.file &&\n context.selection.file.entry &&\n context.selection.file.entry.properties &&\n (context.selection.file.entry.properties['cm:lockType'] === 'WRITE_LOCK' ||\n context.selection.file.entry.properties['cm:lockType'] === 'READ_ONLY_LOCK')\n );\n\n/**\n * Checks if the selected file has **write** or **read-only** locks specified,\n * and that current user is the owner of the lock.\n * JSON ref: `app.selection.file.isLockOwner`\n */\nexport const isUserWriteLockOwner = (context: RuleContext): boolean =>\n isWriteLocked(context) &&\n context.selection.file?.entry.properties['cm:lockOwner'] &&\n context.selection.file?.entry.properties['cm:lockOwner'].id === context.profile.id;\n\n/**\n * Checks if user can lock selected file.\n * JSON ref: `app.selection.file.canLock`\n */\nexport const canLockFile = (context: RuleContext): boolean => !isWriteLocked(context) && canUpdateSelectedNode(context);\n\n/**\n * Checks if user can unlock selected file.\n * JSON ref: `app.selection.file.canUnlock`\n */\nexport function canUnlockFile(context: RuleContext): boolean {\n const { file } = context.selection;\n return isWriteLocked(context) && (context.permissions.check(file?.entry, ['delete']) || isUserWriteLockOwner(context));\n}\n\n/**\n * Checks if user can upload a new version of the file.\n * JSON ref: `app.selection.file.canUploadVersion`\n */\nexport function canUploadVersion(context: RuleContext): boolean {\n if (navigation.isFavorites(context) || navigation.isSharedFiles(context)) {\n return hasFileSelected(context);\n }\n\n return [\n hasFileSelected(context),\n navigation.isNotTrashcan(context),\n isWriteLocked(context) ? isUserWriteLockOwner(context) : canUpdateSelectedNode(context)\n ].every(Boolean);\n}\n\n/**\n * Checks if user has trashcan item selected.\n * JSON ref: `isTrashcanItemSelected`\n *\n * @param context Rule execution context\n */\nexport const isTrashcanItemSelected = (context: RuleContext): boolean => [navigation.isTrashcan(context), hasSelection(context)].every(Boolean);\n\n/**\n * Checks if user can view the file.\n * JSON ref: `canViewFile`\n *\n * @param context Rule execution context\n */\nexport const canViewFile = (context: RuleContext): boolean => [hasFileSelected(context), navigation.isNotTrashcan(context)].every(Boolean);\n\n/**\n * Checks if user can **Leave** selected library.\n * JSON ref: `canLeaveLibrary`\n *\n * @param context Rule execution context\n */\nexport const canLeaveLibrary = (context: RuleContext): boolean => [hasLibrarySelected(context), hasLibraryRole(context)].every(Boolean);\n\n/**\n * Checks if user can toggle shared link mode.\n * JSON ref: `canToggleSharedLink`\n *\n * @param context Rule execution context\n */\nexport const canToggleSharedLink = (context: RuleContext): boolean =>\n [hasFileSelected(context), [canShareFile(context), isShared(context)].some(Boolean)].every(Boolean);\n\n/**\n * Checks if user can show **Info Drawer** for the selected node.\n * JSON ref: `canShowInfoDrawer`\n *\n * @param context Rule execution context\n */\nexport const canShowInfoDrawer = (context: RuleContext): boolean =>\n [hasSelection(context), navigation.isNotLibraries(context), navigation.isNotTrashcan(context)].every(Boolean);\n\n/**\n * Checks if user can manage file versions for the selected node.\n * JSON ref: `canManageFileVersions`\n *\n * @param context Rule execution context\n */\nexport const canManageFileVersions = (context: RuleContext): boolean =>\n [hasFileSelected(context), navigation.isNotTrashcan(context), !hasLockedFiles(context)].every(Boolean);\n\n/**\n * Checks if user can edit aspects for the selected node.\n * JSON ref: `canEditAspects`\n *\n * @param context Rule execution context\n */\nexport const canEditAspects = (context: RuleContext): boolean =>\n [\n !isMultiselection(context),\n canUpdateSelectedNode(context),\n !isWriteLocked(context),\n navigation.isNotTrashcan(context),\n repository.isMajorVersionAvailable(context, '7')\n ].every(Boolean);\n\n/**\n * Checks if user can manage permissions for the selected node.\n * JSON ref: `canManagePermissions`\n *\n * @param context Rule execution context\n */\nexport const canManagePermissions = (context: RuleContext): boolean =>\n [canUpdateSelectedNode(context), navigation.isNotTrashcan(context)].every(Boolean);\n\n/**\n * Checks if user can toggle **Edit Offline** mode for selected node.\n * JSON ref: `canToggleEditOffline`\n *\n * @param context Rule execution context\n */\nexport const canToggleEditOffline = (context: RuleContext): boolean =>\n [hasFileSelected(context), navigation.isNotTrashcan(context), canLockFile(context) || canUnlockFile(context)].every(Boolean);\n\n/**\n * @deprecated Uses workarounds for for recent files and search api issues.\n * Checks if user can toggle **Favorite** state for a node.\n * @param context Rule execution context\n */\nexport const canToggleFavorite = (context: RuleContext): boolean =>\n [\n [canAddFavorite(context), canRemoveFavorite(context)].some(Boolean),\n [navigation.isRecentFiles(context), navigation.isSharedFiles(context), navigation.isSearchResults(context), navigation.isFavorites(context)].some(\n Boolean\n )\n ].every(Boolean);\n\n/**\n * Checks if application should render logout option.\n * JSON ref: `canShowLogout`\n *\n * @param context Rule execution context\n */\nexport const canShowLogout = (context: AcaRuleContext): boolean => !context.withCredentials;\n\n/**\n * Checks if user is library manager\n * JSON ref: `isLibraryManager`\n *\n * @param context Rule execution context\n */\nexport const isLibraryManager = (context: RuleContext): boolean =>\n hasLibrarySelected(context) && context.selection.library?.entry.role === 'SiteManager';\n\n/**\n * Checks if the preview button for search results can be showed\n * JSON ref: `canInfoPreview`\n *\n * @param context Rule execution context\n */\nexport const canInfoPreview = (context: RuleContext): boolean => {\n const isSearchResult = navigation.isSearchResults(context);\n const isNotMultiselect = !isMultiselection(context);\n const isFileSelected = !hasFolderSelected(context);\n const isPreview = !navigation.isPreview(context);\n\n return isSearchResult && isNotMultiselect && isFileSelected && isPreview;\n};\n\nexport const showInfoSelectionButton = (context: RuleContext): boolean => navigation.isSearchResults(context) && !navigation.isPreview(context);\n\n/**\n * Checks if the file can be opened with MS Office\n * JSON ref: `aos.canOpenWithOffice`\n *\n * @param context Rule execution context\n */\nexport function canOpenWithOffice(context: AcaRuleContext): boolean {\n const flag = `${context.appConfig.get<boolean | string>('plugins.aosPlugin', false)}`;\n\n if (flag !== 'true') {\n return false;\n }\n\n if (context.navigation && context.navigation.url && context.navigation.url.startsWith('/trashcan')) {\n return false;\n }\n\n if (!context || !context.selection) {\n return false;\n }\n\n const { file } = context.selection;\n\n if (!file || !file.entry) {\n return false;\n }\n\n const extension = getFileExtension(file.entry.name);\n if (!extension || !supportedExtensions[extension]) {\n return false;\n }\n\n if (!file.entry.properties) {\n return false;\n }\n\n if (file.entry.isLocked) {\n return false;\n }\n\n if (file.entry.properties['cm:lockType'] === 'WRITE_LOCK' || file.entry.properties['cm:lockType'] === 'READ_ONLY_LOCK') {\n return false;\n }\n\n const lockOwner = file.entry.properties['cm:lockOwner'];\n if (lockOwner && lockOwner.id !== context.profile.id) {\n return false;\n }\n\n // workaround for Shared files\n if (context.navigation && context.navigation.url && context.navigation.url.startsWith('/shared')) {\n // eslint-disable-next-line no-prototype-builtins\n if (file.entry.hasOwnProperty('allowableOperationsOnTarget')) {\n return context.permissions.check(file, ['update'], {\n target: 'allowableOperationsOnTarget'\n });\n }\n }\n\n return context.permissions.check(file, ['update']);\n}\n","/*!\n * Copyright © 2005-2023 Hyland Software, Inc. and its affiliates. All rights reserved.\n *\n * Alfresco Example Content Application\n *\n * This file is part of the Alfresco Example Content Application.\n * If the software was purchased under a paid Alfresco license, the terms of\n * the paid license agreement will prevail. Otherwise, the software is\n * provided under the following open source license terms:\n *\n * The Alfresco Example Content Application is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Lesser General Public License as published by\n * the Free Software Foundation, either version 3 of the License, or\n * (at your option) any later version.\n *\n * The Alfresco Example Content Application 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 Lesser General Public License for more details.\n *\n * You should have received a copy of the GNU Lesser General Public License\n * from Hyland Software. If not, see <http://www.gnu.org/licenses/>.\n */\n\nexport * from './app.rules';\nexport * from './navigation.rules';\nexport * from './repository.rules';\nexport * from './user.rules';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":["navigation.isNotSearchResults","navigation.isPersonalFiles","navigation.isLibraryContent","navigation.isNotTrashcan","navigation.isNotLibraries","navigation.isFavorites","navigation.isLibraries","navigation.isTrashcan","repository.hasQuickShareEnabled","navigation.isSharedFiles","navigation.isPreview","repository.isMajorVersionAvailable","navigation.isRecentFiles","navigation.isSearchResults","isPreview"],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;AAsBG;AAIH;;;AAGG;AACG,SAAU,SAAS,CAAC,OAAoB,EAAA;AAC5C,IAAA,MAAM,EAAE,GAAG,EAAE,GAAG,OAAO,CAAC,UAAU,CAAC;IACnC,OAAO,GAAG,KAAK,GAAG,CAAC,QAAQ,CAAC,WAAW,CAAC,IAAI,GAAG,CAAC,QAAQ,CAAC,aAAa,CAAC,IAAI,GAAG,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC,CAAC;AACrG,CAAC;AAED;;;AAGG;AACG,SAAU,WAAW,CAAC,OAAoB,EAAA;AAC9C,IAAA,MAAM,EAAE,GAAG,EAAE,GAAG,OAAO,CAAC,UAAU,CAAC;AACnC,IAAA,OAAO,GAAG,IAAI,GAAG,CAAC,UAAU,CAAC,YAAY,CAAC,IAAI,CAAC,SAAS,CAAC,OAAO,CAAC,CAAC;AACpE,CAAC;AAED;;;AAGG;AACI,MAAM,cAAc,GAAG,CAAC,OAAoB,KAAc,CAAC,WAAW,CAAC,OAAO,EAAE;AAEvF;;;AAGG;AACG,SAAU,aAAa,CAAC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D,gBAAA,MAAM,EAAE,6BAA6B;AACtC,aAAA,CAAC,CAAC;AACJ,SAAA;AACF,KAAA;AAED,IAAA,OAAO,OAAO,CAAC,WAAW,CAAC,KAAK,CAAC,IAAI,EAAE,CAAC,QAAQ,CAAC,CAAC,CAAC;AACrD;;AC9nBA;;;;;;;;;;;;;;;;;;;;;;AAsBG;;ACtBH;;AAEG;;;;"}
1
+ {"version":3,"file":"alfresco-aca-shared-rules.mjs","sources":["../../../../projects/aca-shared/rules/src/navigation.rules.ts","../../../../projects/aca-shared/rules/src/repository.rules.ts","../../../../projects/aca-shared/rules/src/user.rules.ts","../../../../projects/aca-shared/rules/src/app.rules.ts","../../../../projects/aca-shared/rules/src/public-api.ts","../../../../projects/aca-shared/rules/src/alfresco-aca-shared-rules.ts"],"sourcesContent":["/*!\n * Copyright © 2005-2023 Hyland Software, Inc. and its affiliates. All rights reserved.\n *\n * Alfresco Example Content Application\n *\n * This file is part of the Alfresco Example Content Application.\n * If the software was purchased under a paid Alfresco license, the terms of\n * the paid license agreement will prevail. Otherwise, the software is\n * provided under the following open source license terms:\n *\n * The Alfresco Example Content Application is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Lesser General Public License as published by\n * the Free Software Foundation, either version 3 of the License, or\n * (at your option) any later version.\n *\n * The Alfresco Example Content Application 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 Lesser General Public License for more details.\n *\n * You should have received a copy of the GNU Lesser General Public License\n * from Hyland Software. If not, see <http://www.gnu.org/licenses/>.\n */\n\nimport { RuleContext } from '@alfresco/adf-extensions';\n\n/**\n * Checks if a Preview route is activated.\n * JSON ref: `app.navigation.isPreview`\n */\nexport function isPreview(context: RuleContext): boolean {\n const { url } = context.navigation;\n return url && (url.includes('/preview/') || url.includes('viewer:view') || url.includes('/view/'));\n}\n\n/**\n * Checks if a **Favorites** route is activated.\n * JSON ref: `app.navigation.isFavorites`\n */\nexport function isFavorites(context: RuleContext): boolean {\n const { url } = context.navigation;\n return url?.startsWith('/favorites') && !isPreview(context);\n}\n\n/**\n * Checks if the activated route is not **Favorites**.\n * JSON ref: `app.navigation.isNotFavorites`\n */\nexport const isNotFavorites = (context: RuleContext): boolean => !isFavorites(context);\n\n/**\n * Checks if a **Shared Files** route is activated.\n * JSON ref: `app.navigation.isSharedFiles`\n */\nexport function isSharedFiles(context: RuleContext): boolean {\n const { url } = context.navigation;\n return url?.startsWith('/shared') && !isPreview(context);\n}\n\n/**\n * Checks if the activated route is not **Shared Files**.\n * JSON ref: `app.navigation.isNotSharedFiles`\n */\nexport const isNotSharedFiles = (context: RuleContext): boolean => !isSharedFiles(context);\n\n/**\n * Checks if a **Trashcan** route is activated.\n * JSON ref: `app.navigation.isTrashcan`\n */\nexport function isTrashcan(context: RuleContext): boolean {\n const { url } = context.navigation;\n return url?.startsWith('/trashcan');\n}\n\n/**\n * Checks if the activated route is not **Trashcan**.\n * JSON ref: `app.navigation.isNotTrashcan`\n */\nexport const isNotTrashcan = (context: RuleContext): boolean => !isTrashcan(context);\n\n/**\n * Checks if a **Personal Files** route is activated.\n * JSON ref: `app.navigation.isPersonalFiles`\n */\nexport function isPersonalFiles(context: RuleContext): boolean {\n const { url } = context.navigation;\n return url?.startsWith('/personal-files');\n}\n\n/**\n * Checks if a **Library Files** route is activated.\n * JSON ref: `app.navigation.isLibraryFiles`\n */\nexport function isLibraryFiles(context: RuleContext): boolean {\n const { url } = context.navigation;\n return url?.startsWith('/libraries');\n}\n\n/**\n * Checks if a **Library Files** or **Library Search Result** route is activated.\n * JSON ref: `app.navigation.isLibraryFiles`\n */\nexport function isLibraries(context: RuleContext): boolean {\n const { url } = context.navigation;\n return url?.endsWith('/libraries') || url?.startsWith('/search-libraries');\n}\n\nexport function isLibraryContent(context: RuleContext): boolean {\n const { url } = context.navigation;\n return url?.endsWith('/libraries') || url?.includes('/libraries/') || url?.startsWith('/search-libraries');\n}\n\n/**\n * Checks if the activated route is neither **Libraries** nor **Library Search Results**.\n * JSON ref: `app.navigation.isNotLibraries`\n */\nexport const isNotLibraries = (context: RuleContext): boolean => !isLibraries(context);\n\n/**\n * Checks if a **Recent Files** route is activated.\n * JSON ref: `app.navigation.isRecentFiles`\n */\nexport function isRecentFiles(context: RuleContext): boolean {\n const { url } = context.navigation;\n return url?.startsWith('/recent-files');\n}\n\n/**\n * Checks if the activated route is not **Recent Files**.\n * JSON ref: `app.navigation.isNotRecentFiles`\n */\nexport const isNotRecentFiles = (context: RuleContext): boolean => !isRecentFiles(context);\n\n/**\n * Checks if a **Search Results** route is activated.\n * JSON ref: `app.navigation.isSearchResults`\n */\nexport function isSearchResults(\n context: RuleContext\n // ...args: RuleParameter[]\n): boolean {\n const { url } = context.navigation;\n return url?.startsWith('/search');\n}\n\n/**\n * Checks if the activated route is not **Search Results**.\n * JSON ref: `app.navigation.isNotSearchResults`\n */\nexport const isNotSearchResults = (context: RuleContext): boolean => !isSearchResults(context);\n\n/**\n * Checks if a **Shared Preview** route is activated.\n * JSON ref: `app.navigation.isSharedPreview`\n */\nexport function isSharedPreview(context: RuleContext): boolean {\n const { url } = context.navigation;\n return url?.startsWith('/shared/preview/') || (url?.startsWith('/shared') && url?.includes('viewer:view'));\n}\n\n/**\n * Checks if a **Favorites Preview** route is activated.\n * JSON ref: `app.navigation.isFavoritesPreview`\n */\nexport function isFavoritesPreview(context: RuleContext): boolean {\n const { url } = context.navigation;\n return url?.startsWith('/favorites/preview/') || (url?.startsWith('/favorites') && url?.includes('viewer:view'));\n}\n\n/**\n * Checks if a **Shared File Preview** route is activated.\n * JSON ref: `app.navigation.isFavoritesPreview`\n */\nexport function isSharedFileViewer(context: RuleContext): boolean {\n const { url } = context.navigation;\n return url?.startsWith('/preview/s/');\n}\n","/*!\n * Copyright © 2005-2023 Hyland Software, Inc. and its affiliates. All rights reserved.\n *\n * Alfresco Example Content Application\n *\n * This file is part of the Alfresco Example Content Application.\n * If the software was purchased under a paid Alfresco license, the terms of\n * the paid license agreement will prevail. Otherwise, the software is\n * provided under the following open source license terms:\n *\n * The Alfresco Example Content Application is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Lesser General Public License as published by\n * the Free Software Foundation, either version 3 of the License, or\n * (at your option) any later version.\n *\n * The Alfresco Example Content Application 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 Lesser General Public License for more details.\n *\n * You should have received a copy of the GNU Lesser General Public License\n * from Hyland Software. If not, see <http://www.gnu.org/licenses/>.\n */\n\nimport { RuleContext } from '@alfresco/adf-extensions';\n\n/**\n * Checks if the quick share repository option is enabled or not.\n * JSON ref: `repository.isQuickShareEnabled`\n */\nexport const hasQuickShareEnabled = (context: RuleContext): boolean => context.repository.status.isQuickShareEnabled;\n\nexport function isMajorVersionAvailable(context: RuleContext, versionNumber: string): boolean {\n const majorVersion = context.repository.version?.major ? parseInt(context.repository.version.major, 10) : 0;\n return majorVersion >= parseInt(versionNumber, 10);\n}\n","/*!\n * Copyright © 2005-2023 Hyland Software, Inc. and its affiliates. All rights reserved.\n *\n * Alfresco Example Content Application\n *\n * This file is part of the Alfresco Example Content Application.\n * If the software was purchased under a paid Alfresco license, the terms of\n * the paid license agreement will prevail. Otherwise, the software is\n * provided under the following open source license terms:\n *\n * The Alfresco Example Content Application is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Lesser General Public License as published by\n * the Free Software Foundation, either version 3 of the License, or\n * (at your option) any later version.\n *\n * The Alfresco Example Content Application 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 Lesser General Public License for more details.\n *\n * You should have received a copy of the GNU Lesser General Public License\n * from Hyland Software. If not, see <http://www.gnu.org/licenses/>.\n */\n\nimport { RuleContext } from '@alfresco/adf-extensions';\n\n/**\n * Checks if user is admin.\n * JSON ref: `user.isAdmin`\n */\nexport const isAdmin = (context: RuleContext): boolean => context.profile.isAdmin;\n","/*!\n * Copyright © 2005-2023 Hyland Software, Inc. and its affiliates. All rights reserved.\n *\n * Alfresco Example Content Application\n *\n * This file is part of the Alfresco Example Content Application.\n * If the software was purchased under a paid Alfresco license, the terms of\n * the paid license agreement will prevail. Otherwise, the software is\n * provided under the following open source license terms:\n *\n * The Alfresco Example Content Application is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Lesser General Public License as published by\n * the Free Software Foundation, either version 3 of the License, or\n * (at your option) any later version.\n *\n * The Alfresco Example Content Application 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 Lesser General Public License for more details.\n *\n * You should have received a copy of the GNU Lesser General Public License\n * from Hyland Software. If not, see <http://www.gnu.org/licenses/>.\n */\n\nimport { AppConfigService } from '@alfresco/adf-core';\nimport { RuleContext } from '@alfresco/adf-extensions';\nimport * as navigation from './navigation.rules';\nimport * as repository from './repository.rules';\nimport { isAdmin } from './user.rules';\n\n/* cspell:disable */\nexport const supportedExtensions = {\n doc: 'ms-word',\n docx: 'ms-word',\n docm: 'ms-word',\n dot: 'ms-word',\n dotx: 'ms-word',\n dotm: 'ms-word',\n rtf: 'ms-word',\n xls: 'ms-excel',\n xlsx: 'ms-excel',\n xlsb: 'ms-excel',\n xlsm: 'ms-excel',\n xlt: 'ms-excel',\n xltx: 'ms-excel',\n xltm: 'ms-excel',\n xlam: 'ms-excel',\n ppt: 'ms-powerpoint',\n pptx: 'ms-powerpoint',\n pot: 'ms-powerpoint',\n potx: 'ms-powerpoint',\n potm: 'ms-powerpoint',\n pptm: 'ms-powerpoint',\n pps: 'ms-powerpoint',\n ppsx: 'ms-powerpoint',\n ppam: 'ms-powerpoint',\n ppsm: 'ms-powerpoint',\n sldx: 'ms-powerpoint',\n sldm: 'ms-powerpoint',\n vsd: 'ms-visio',\n vss: 'ms-visio',\n vst: 'ms-visio',\n vsdx: 'ms-visio',\n vsdm: 'ms-visio',\n vssx: 'ms-visio',\n vssm: 'ms-visio',\n vstx: 'ms-visio',\n vstm: 'ms-visio'\n};\n/* cspell:enable */\n\nexport function getFileExtension(fileName: string): string | null {\n if (fileName) {\n const match = fileName.match(/\\.([^\\./\\?\\#]+)($|\\?|\\#)/);\n\n return match ? match[1] : null;\n }\n\n return null;\n}\n\nexport interface AcaRuleContext extends RuleContext {\n withCredentials: boolean;\n appConfig: AppConfigService;\n}\n\n/**\n * Checks if the content plugin is enabled.\n * JSON ref: `app.isContentServiceEnabled`\n */\nexport const isContentServiceEnabled = (context: AcaRuleContext): boolean => {\n const flag = context.appConfig.get<boolean | string>('plugins.contentService');\n return flag === true || flag === 'true';\n};\n\n/**\n * Checks if Search is supported for active view\n * JSON ref: `app.isSearchSupported`\n */\nexport const isSearchSupported = (context: RuleContext): boolean =>\n [navigation.isNotSearchResults(context) /* , !hasSelection(context)*/].every(Boolean);\n\n/**\n * Checks if upload action is supported for the given context\n * JSON ref: `app.isUploadSupported`\n *\n * @param context Rule execution context\n */\nexport const isUploadSupported = (context: AcaRuleContext): boolean =>\n [isContentServiceEnabled(context), navigation.isPersonalFiles(context) || navigation.isLibraryContent(context), canUpload(context)].every(Boolean);\n/**\n * Checks if user can copy selected node.\n * JSON ref: `app.canCopyNode`\n *\n * @param context Rule execution context\n */\nexport const canCopyNode = (context: RuleContext): boolean =>\n [hasSelection(context), navigation.isNotTrashcan(context), navigation.isNotLibraries(context)].every(Boolean);\n\n/**\n * Checks if user can mark selected nodes as **Favorite**.\n * JSON ref: `app.selection.canAddFavorite`\n */\nexport function canAddFavorite(context: RuleContext): boolean {\n if (!context.selection.isEmpty) {\n if (navigation.isFavorites(context) || navigation.isLibraries(context) || navigation.isTrashcan(context)) {\n return false;\n }\n return context.selection.nodes.some((node) => !node.entry.isFavorite);\n }\n return false;\n}\n\n/**\n * Checks if user can un-mark selected nodes as **Favorite**.\n * JSON ref: `app.selection.canRemoveFavorite`\n */\nexport function canRemoveFavorite(context: RuleContext): boolean {\n if (!context.selection.isEmpty && !navigation.isTrashcan(context)) {\n if (navigation.isFavorites(context)) {\n return true;\n }\n return context.selection.nodes.every((node) => node.entry.isFavorite);\n }\n return false;\n}\n\n/**\n * Checks if user can share selected file.\n * JSON ref: `app.selection.file.canShare`\n */\nexport const canShareFile = (context: RuleContext): boolean =>\n [context.selection.file, navigation.isNotTrashcan(context), repository.hasQuickShareEnabled(context), !isShared(context)].every(Boolean);\n\n/**\n * Checks if user can perform \"Join\" or \"Cancel Join Request\" on a library.\n * JSON ref: `canToggleJoinLibrary`\n */\nexport const canToggleJoinLibrary = (context: RuleContext): boolean =>\n [hasLibrarySelected(context), !isPrivateLibrary(context), hasNoLibraryRole(context)].every(Boolean) ||\n [hasLibrarySelected(context), isPrivateLibrary(context), hasNoLibraryRole(context), isAdmin(context)].every(Boolean);\n\n/**\n * Checks if user can edit the selected folder.\n * JSON ref: `canEditFolder`\n *\n * @param context Rule execution context\n */\nexport const canEditFolder = (context: RuleContext): boolean => [canUpdateSelectedFolder(context), navigation.isNotTrashcan(context)].every(Boolean);\n\n/**\n * Checks if the selected file is already shared.\n * JSON ref: `app.selection.file.isShared`\n */\nexport function isShared(context: RuleContext): boolean {\n if (navigation.isSharedFiles(context) && context.selection.file) {\n return true;\n }\n\n if (navigation.isNotTrashcan(context) && !context.selection.isEmpty && context.selection.file) {\n return !!context.selection.file.entry?.properties?.['qshare:sharedId'];\n }\n\n return false;\n}\n\n/**\n * Checks if user can delete selected nodes.\n * JSON ref: `app.selection.canDelete`\n */\nexport function canDeleteSelection(context: RuleContext): boolean {\n if (\n navigation.isNotTrashcan(context) &&\n navigation.isNotLibraries(context) &&\n navigation.isNotSearchResults(context) &&\n !context.selection.isEmpty\n ) {\n if (hasLockedFiles(context)) {\n return false;\n }\n\n // temp workaround for Favorites api\n if (navigation.isFavorites(context)) {\n return true;\n }\n\n if (navigation.isPreview(context)) {\n return context.permissions.check(context.selection.nodes, ['delete']);\n }\n\n // workaround for Shared Files\n if (navigation.isSharedFiles(context)) {\n return context.permissions.check(context.selection.nodes, ['delete'], {\n target: 'allowableOperationsOnTarget'\n });\n }\n\n return context.permissions.check(context.selection.nodes, ['delete']);\n }\n return false;\n}\n\n/**\n * Checks if user can un-share selected nodes.\n * JSON ref: `app.selection.canUnshare`\n */\nexport function canUnshareNodes(context: RuleContext): boolean {\n if (!context.selection.isEmpty) {\n return context.permissions.check(context.selection.nodes, ['delete'], {\n target: 'allowableOperationsOnTarget'\n });\n }\n return false;\n}\n\n/**\n * Checks if user selected anything.\n * JSON ref: `app.selection.notEmpty`\n */\nexport const hasSelection = (context: RuleContext): boolean => !context.selection.isEmpty;\n\n/**\n * Checks if user can create a new folder with current path.\n * JSON ref: `app.navigation.folder.canCreate`\n */\nexport function canCreateFolder(context: AcaRuleContext): boolean {\n if (isContentServiceEnabled(context) && (navigation.isPersonalFiles(context) || navigation.isLibraryContent(context))) {\n const { currentFolder } = context.navigation;\n\n if (currentFolder) {\n return context.permissions.check(currentFolder, ['create']);\n }\n }\n return false;\n}\n\n/**\n * Checks if user can create a Library\n * JSON ref: `app.canCreateLibrary`\n *\n * @param context Rule execution context\n */\nexport const canCreateLibrary = (context: AcaRuleContext): boolean =>\n [isContentServiceEnabled(context), navigation.isLibraries(context)].every(Boolean);\n\n/**\n * Checks if user can upload content to current folder.\n * JSON ref: `app.navigation.folder.canUpload`\n */\nexport function canUpload(context: AcaRuleContext): boolean {\n return canCreateFolder(context);\n}\n\n/**\n * Checks if user can download selected nodes (either files or folders).\n * JSON ref: `app.selection.canDownload`\n */\nexport function canDownloadSelection(context: RuleContext): boolean {\n if (!context.selection.isEmpty && navigation.isNotTrashcan(context)) {\n return context.selection.nodes.every((node: any) => node.entry && (node.entry.isFile || node.entry.isFolder || !!node.entry.nodeId));\n }\n return false;\n}\n\n/**\n * Checks if user has selected a folder.\n * JSON ref: `app.selection.folder`\n */\nexport const hasFolderSelected = (context: RuleContext): boolean => !!context.selection.folder;\n\n/**\n * Checks if user has selected a library (site).\n * JSON ref: `app.selection.library`\n */\nexport const hasLibrarySelected = (context: RuleContext): boolean => !!context.selection.library;\n\n/**\n * Checks if user has selected a **private** library (site)\n * JSON ref: `app.selection.isPrivateLibrary`\n */\nexport function isPrivateLibrary(context: RuleContext): boolean {\n return context.selection.library?.entry?.visibility === 'PRIVATE';\n}\n\n/**\n * Checks if the selected library has a **role** property defined.\n * JSON ref: `app.selection.hasLibraryRole`\n */\nexport function hasLibraryRole(context: RuleContext): boolean {\n const library = context.selection.library;\n return library ? !!library.entry?.role : false;\n}\n\n/**\n * Checks if the selected library has no **role** property defined.\n * JSON ref: `app.selection.hasNoLibraryRole`\n */\nexport const hasNoLibraryRole = (context: RuleContext): boolean => !hasLibraryRole(context);\n\n/**\n * Checks if user has selected a file.\n * JSON ref: `app.selection.file`\n */\nexport const hasFileSelected = (context: RuleContext): boolean => !!context?.selection?.file;\n\n/**\n * Checks if user can update the first selected node.\n * JSON ref: `app.selection.first.canUpdate`\n */\nexport function canUpdateSelectedNode(context: RuleContext): boolean {\n if (context.selection && !context.selection.isEmpty) {\n const node = context.selection.first;\n\n if (node?.entry.isFile && hasLockedFiles(context)) {\n return false;\n }\n\n return context.permissions.check(node, ['update']);\n }\n return false;\n}\n\nexport function isMultiselection(context: RuleContext): boolean {\n let isMultiNodeSelected = false;\n if (context.selection && !context.selection.isEmpty) {\n isMultiNodeSelected = context.selection.count > 1;\n }\n return isMultiNodeSelected;\n}\n\n/**\n * Checks if user can update the first selected folder.\n * JSON ref: `app.selection.folder.canUpdate`\n */\nexport function canUpdateSelectedFolder(context: RuleContext): boolean {\n const { folder } = context.selection;\n if (folder) {\n return (\n // workaround for Favorites Api\n navigation.isFavorites(context) || context.permissions.check(folder.entry, ['update'])\n );\n }\n return false;\n}\n\n/**\n * Checks if user has selected a **locked** file node.\n * JSON ref: `app.selection.file.isLocked`\n */\nexport function hasLockedFiles(context: RuleContext): boolean {\n if (context?.selection?.nodes) {\n return context.selection.nodes.some((node) => {\n if (!node.entry.isFile) {\n return false;\n }\n\n return node.entry.isLocked || node.entry.properties?.['cm:lockType'] === 'READ_ONLY_LOCK';\n });\n }\n\n return false;\n}\n\n/**\n * Checks if the selected file has **write** or **read-only** locks specified.\n * JSON ref: `app.selection.file.isLocked`\n */\nexport const isWriteLocked = (context: RuleContext): boolean =>\n !!(\n context?.selection?.file?.entry?.properties?.['cm:lockType'] === 'WRITE_LOCK' ||\n context?.selection?.file?.entry?.properties?.['cm:lockType'] === 'READ_ONLY_LOCK'\n );\n\n/**\n * Checks if the selected file has **write** or **read-only** locks specified,\n * and that current user is the owner of the lock.\n * JSON ref: `app.selection.file.isLockOwner`\n */\nexport const isUserWriteLockOwner = (context: RuleContext): boolean =>\n isWriteLocked(context) &&\n context.selection.file?.entry.properties['cm:lockOwner'] &&\n context.selection.file?.entry.properties['cm:lockOwner'].id === context.profile.id;\n\n/**\n * Checks if user can lock selected file.\n * JSON ref: `app.selection.file.canLock`\n */\nexport const canLockFile = (context: RuleContext): boolean => !isWriteLocked(context) && canUpdateSelectedNode(context);\n\n/**\n * Checks if user can unlock selected file.\n * JSON ref: `app.selection.file.canUnlock`\n */\nexport function canUnlockFile(context: RuleContext): boolean {\n const { file } = context.selection;\n return isWriteLocked(context) && (context.permissions.check(file?.entry, ['delete']) || isUserWriteLockOwner(context));\n}\n\n/**\n * Checks if user can upload a new version of the file.\n * JSON ref: `app.selection.file.canUploadVersion`\n */\nexport function canUploadVersion(context: RuleContext): boolean {\n if (navigation.isFavorites(context) || navigation.isSharedFiles(context)) {\n return hasFileSelected(context);\n }\n\n return [\n hasFileSelected(context),\n navigation.isNotTrashcan(context),\n isWriteLocked(context) ? isUserWriteLockOwner(context) : canUpdateSelectedNode(context)\n ].every(Boolean);\n}\n\n/**\n * Checks if user has trashcan item selected.\n * JSON ref: `isTrashcanItemSelected`\n *\n * @param context Rule execution context\n */\nexport const isTrashcanItemSelected = (context: RuleContext): boolean => [navigation.isTrashcan(context), hasSelection(context)].every(Boolean);\n\n/**\n * Checks if user can view the file.\n * JSON ref: `canViewFile`\n *\n * @param context Rule execution context\n */\nexport const canViewFile = (context: RuleContext): boolean => [hasFileSelected(context), navigation.isNotTrashcan(context)].every(Boolean);\n\n/**\n * Checks if user can **Leave** selected library.\n * JSON ref: `canLeaveLibrary`\n *\n * @param context Rule execution context\n */\nexport const canLeaveLibrary = (context: RuleContext): boolean => [hasLibrarySelected(context), hasLibraryRole(context)].every(Boolean);\n\n/**\n * Checks if user can toggle shared link mode.\n * JSON ref: `canToggleSharedLink`\n *\n * @param context Rule execution context\n */\nexport const canToggleSharedLink = (context: RuleContext): boolean =>\n [hasFileSelected(context), [canShareFile(context), isShared(context)].some(Boolean)].every(Boolean);\n\n/**\n * Checks if user can show **Info Drawer** for the selected node.\n * JSON ref: `canShowInfoDrawer`\n *\n * @param context Rule execution context\n */\nexport const canShowInfoDrawer = (context: RuleContext): boolean =>\n [hasSelection(context), navigation.isNotLibraries(context), navigation.isNotTrashcan(context)].every(Boolean);\n\n/**\n * Checks if user can manage file versions for the selected node.\n * JSON ref: `canManageFileVersions`\n *\n * @param context Rule execution context\n */\nexport const canManageFileVersions = (context: RuleContext): boolean =>\n [hasFileSelected(context), navigation.isNotTrashcan(context), !hasLockedFiles(context)].every(Boolean);\n\n/**\n * Checks if user can edit aspects for the selected node.\n * JSON ref: `canEditAspects`\n *\n * @param context Rule execution context\n */\nexport const canEditAspects = (context: RuleContext): boolean =>\n [\n !isMultiselection(context),\n canUpdateSelectedNode(context),\n !isWriteLocked(context),\n navigation.isNotTrashcan(context),\n repository.isMajorVersionAvailable(context, '7')\n ].every(Boolean);\n\n/**\n * Checks if user can manage permissions for the selected node.\n * JSON ref: `canManagePermissions`\n *\n * @param context Rule execution context\n */\nexport const canManagePermissions = (context: RuleContext): boolean =>\n [canUpdateSelectedNode(context), navigation.isNotTrashcan(context)].every(Boolean);\n\n/**\n * Checks if user can toggle **Edit Offline** mode for selected node.\n * JSON ref: `canToggleEditOffline`\n *\n * @param context Rule execution context\n */\nexport const canToggleEditOffline = (context: RuleContext): boolean =>\n [hasFileSelected(context), navigation.isNotTrashcan(context), canLockFile(context) || canUnlockFile(context)].every(Boolean);\n\n/**\n * @deprecated Uses workarounds for for recent files and search api issues.\n * Checks if user can toggle **Favorite** state for a node.\n * @param context Rule execution context\n */\nexport const canToggleFavorite = (context: RuleContext): boolean =>\n [\n [canAddFavorite(context), canRemoveFavorite(context)].some(Boolean),\n [navigation.isRecentFiles(context), navigation.isSharedFiles(context), navigation.isSearchResults(context), navigation.isFavorites(context)].some(\n Boolean\n )\n ].every(Boolean);\n\n/**\n * Checks if application should render logout option.\n * JSON ref: `canShowLogout`\n *\n * @param context Rule execution context\n */\nexport const canShowLogout = (context: AcaRuleContext): boolean => !context.withCredentials;\n\n/**\n * Checks if user is library manager\n * JSON ref: `isLibraryManager`\n *\n * @param context Rule execution context\n */\nexport const isLibraryManager = (context: RuleContext): boolean =>\n hasLibrarySelected(context) && context.selection.library?.entry.role === 'SiteManager';\n\n/**\n * Checks if the preview button for search results can be showed\n * JSON ref: `canInfoPreview`\n *\n * @param context Rule execution context\n */\nexport const canInfoPreview = (context: RuleContext): boolean => {\n const isSearchResult = navigation.isSearchResults(context);\n const isNotMultiselect = !isMultiselection(context);\n const isFileSelected = !hasFolderSelected(context);\n const isPreview = !navigation.isPreview(context);\n\n return isSearchResult && isNotMultiselect && isFileSelected && isPreview;\n};\n\nexport const showInfoSelectionButton = (context: RuleContext): boolean => navigation.isSearchResults(context) && !navigation.isPreview(context);\n\n/**\n * Checks if the file can be opened with MS Office\n * JSON ref: `aos.canOpenWithOffice`\n *\n * @param context Rule execution context\n */\nexport function canOpenWithOffice(context: AcaRuleContext): boolean {\n const flag = `${context.appConfig.get<boolean | string>('plugins.aosPlugin', false)}`;\n\n if (flag !== 'true') {\n return false;\n }\n\n if (context.navigation?.url?.startsWith('/trashcan')) {\n return false;\n }\n\n if (!context?.selection) {\n return false;\n }\n\n const { file } = context.selection;\n\n if (!file?.entry) {\n return false;\n }\n\n const extension = getFileExtension(file.entry.name);\n if (!extension || !supportedExtensions[extension]) {\n return false;\n }\n\n if (!file.entry.properties) {\n return false;\n }\n\n if (file.entry.isLocked) {\n return false;\n }\n\n if (file.entry.properties['cm:lockType'] === 'WRITE_LOCK' || file.entry.properties['cm:lockType'] === 'READ_ONLY_LOCK') {\n return false;\n }\n\n const lockOwner = file.entry.properties['cm:lockOwner'];\n if (lockOwner && lockOwner.id !== context.profile.id) {\n return false;\n }\n\n // workaround for Shared files\n if (context.navigation?.url?.startsWith('/shared')) {\n // eslint-disable-next-line no-prototype-builtins\n if (file.entry.hasOwnProperty('allowableOperationsOnTarget')) {\n return context.permissions.check(file, ['update'], {\n target: 'allowableOperationsOnTarget'\n });\n }\n }\n\n return context.permissions.check(file, ['update']);\n}\n","/*!\n * Copyright © 2005-2023 Hyland Software, Inc. and its affiliates. All rights reserved.\n *\n * Alfresco Example Content Application\n *\n * This file is part of the Alfresco Example Content Application.\n * If the software was purchased under a paid Alfresco license, the terms of\n * the paid license agreement will prevail. Otherwise, the software is\n * provided under the following open source license terms:\n *\n * The Alfresco Example Content Application is free software: you can redistribute it and/or modify\n * it under the terms of the GNU Lesser General Public License as published by\n * the Free Software Foundation, either version 3 of the License, or\n * (at your option) any later version.\n *\n * The Alfresco Example Content Application 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 Lesser General Public License for more details.\n *\n * You should have received a copy of the GNU Lesser General Public License\n * from Hyland Software. If not, see <http://www.gnu.org/licenses/>.\n */\n\nexport * from './app.rules';\nexport * from './navigation.rules';\nexport * from './repository.rules';\nexport * from './user.rules';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":["navigation.isNotSearchResults","navigation.isPersonalFiles","navigation.isLibraryContent","navigation.isNotTrashcan","navigation.isNotLibraries","navigation.isFavorites","navigation.isLibraries","navigation.isTrashcan","repository.hasQuickShareEnabled","navigation.isSharedFiles","navigation.isPreview","repository.isMajorVersionAvailable","navigation.isRecentFiles","navigation.isSearchResults","isPreview"],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;AAsBG;AAIH;;;AAGG;AACG,SAAU,SAAS,CAAC,OAAoB,EAAA;AAC5C,IAAA,MAAM,EAAE,GAAG,EAAE,GAAG,OAAO,CAAC,UAAU,CAAC;IACnC,OAAO,GAAG,KAAK,GAAG,CAAC,QAAQ,CAAC,WAAW,CAAC,IAAI,GAAG,CAAC,QAAQ,CAAC,aAAa,CAAC,IAAI,GAAG,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC,CAAC;AACrG,CAAC;AAED;;;AAGG;AACG,SAAU,WAAW,CAAC,OAAoB,EAAA;AAC9C,IAAA,MAAM,EAAE,GAAG,EAAE,GAAG,OAAO,CAAC,UAAU,CAAC;AACnC,IAAA,OAAO,GAAG,EAAE,UAAU,CAAC,YAAY,CAAC,IAAI,CAAC,SAAS,CAAC,OAAO,CAAC,CAAC;AAC9D,CAAC;AAED;;;AAGG;AACI,MAAM,cAAc,GAAG,CAAC,OAAoB,KAAc,CAAC,WAAW,CAAC,OAAO,EAAE;AAEvF;;;AAGG;AACG,SAAU,aAAa,CAAC,OAAoB,EAAA;AAChD,IAAA,MAAM,EAAE,GAAG,EAAE,GAAG,OAAO,CAAC,UAAU,CAAC;AACnC,IAAA,OAAO,GAAG,EAAE,UAAU,CAAC,SAAS,CAAC,IAAI,CAAC,SAAS,CAAC,OAAO,CAAC,CAAC;AAC3D,CAAC;AAED;;;AAGG;AACI,MAAM,gBAAgB,GAAG,CAAC,OAAoB,KAAc,CAAC,aAAa,CAAC,OAAO,EAAE;AAE3F;;;AAGG;AACG,SAAU,UAAU,CAAC,OAAoB,EAAA;AAC7C,IAAA,MAAM,EAAE,GAAG,E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Folder$ = createEffect(() => this.actions$.pipe(ofType(RouterActionTypes.NavigateFolder), map((action) => {
979
- if (action.payload && action.payload.entry) {
979
+ if (action.payload?.entry) {
980
980
  this.navigateToFolder(action.payload.entry);
981
981
  }
982
982
  })), { dispatch: false });
983
983
  this.navigateToParentFolder$ = createEffect(() => this.actions$.pipe(ofType(RouterActionTypes.NavigateParentFolder), map((action) => {
984
- if (action.payload && action.payload.entry) {
984
+ if (action.payload?.entry) {
985
985
  this.navigateToParentFolder(action.payload.entry);
986
986
  }
987
987
  })), { dispatch: false });
@@ -990,7 +990,7 @@ class RouterEffects {
990
990
  navigateToFolder(node) {
991
991
  let link = null;
992
992
  const { path, id } = node;
993
- if (path && path.name && path.elements) {
993
+ if (path?.name && path?.elements) {
994
994
  const isLibraryPath = this.isLibraryContent(path);
995
995
  const parent = path.elements[path.elements.length - 1];
996
996
  const area = isLibraryPath ? '/libraries' : '/personal-files';
@@ -1012,7 +1012,7 @@ class RouterEffects {
1012
1012
  navigateToParentFolder(node) {
1013
1013
  let link = null;
1014
1014
  const { path } = node;
1015
- if (path && path.name && path.elements) {
1015
+ if (path?.name && path?.elements) {
1016
1016
  const isLibraryPath = this.isLibraryContent(path);
1017
1017
  const parent = path.elements[path.elements.length - 1];
1018
1018
  const area = isLibraryPath ? '/libraries' : '/personal-files';