@alfresco/aca-shared 1.12.0 → 4.0.0-A.2-9919
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.
- package/README.md +2 -1
- package/esm2020/alfresco-aca-shared.mjs +5 -0
- package/esm2020/lib/adf-extensions/extensions-data-loader.guard.mjs +74 -0
- package/esm2020/lib/components/document-base-page/document-base-page.component.mjs +160 -0
- package/esm2020/lib/components/document-base-page/document-base-page.service.mjs +10 -0
- package/esm2020/lib/components/generic-error/generic-error.component.mjs +42 -0
- package/esm2020/lib/components/generic-error/generic-error.module.mjs +45 -0
- package/esm2020/lib/components/info-drawer/info-drawer.component.mjs +124 -0
- package/esm2020/lib/components/info-drawer/shared-info-drawer.module.mjs +47 -0
- package/esm2020/lib/components/locked-by/locked-by.component.mjs +53 -0
- package/esm2020/lib/components/locked-by/locked-by.module.mjs +45 -0
- package/esm2020/lib/components/page-layout/page-layout-content.component.mjs +49 -0
- package/{esm2015/lib/models/types.js → esm2020/lib/components/page-layout/page-layout-error.component.mjs} +16 -42
- package/esm2020/lib/components/page-layout/page-layout-header.component.mjs +41 -0
- package/esm2020/lib/components/page-layout/page-layout.component.mjs +41 -0
- package/esm2020/lib/components/page-layout/page-layout.module.mjs +45 -0
- package/esm2020/lib/components/tool-bar/shared-toolbar.module.mjs +47 -0
- package/esm2020/lib/components/tool-bar/toolbar-action/toolbar-action.component.mjs +58 -0
- package/esm2020/lib/components/tool-bar/toolbar-button/toolbar-button.component.mjs +67 -0
- package/esm2020/lib/components/tool-bar/toolbar-menu/toolbar-menu.component.mjs +78 -0
- package/esm2020/lib/components/tool-bar/toolbar-menu-item/toolbar-menu-item.component.mjs +69 -0
- package/esm2020/lib/directives/contextmenu/contextmenu.directive.mjs +107 -0
- package/{esm2015/lib/components/locked-by/locked-by.module.js → esm2020/lib/directives/contextmenu/contextmenu.module.mjs} +17 -16
- package/esm2020/lib/directives/pagination.directive.mjs +55 -0
- package/esm2020/lib/directives/shared.directives.module.mjs +42 -0
- package/esm2020/lib/models/modal-configuration.mjs +2 -0
- package/esm2020/lib/models/types.mjs +26 -0
- package/esm2020/lib/models/viewer.rules.mjs +26 -0
- package/esm2020/lib/routing/shared.guard.mjs +49 -0
- package/esm2020/lib/services/alfresco-office-extension.service.mjs +64 -0
- package/esm2020/lib/services/app-hook.service.mjs +88 -0
- package/esm2020/lib/services/app.extension.service.mjs +453 -0
- package/esm2020/lib/services/app.service.mjs +213 -0
- package/esm2020/lib/services/content-api.service.mjs +268 -0
- package/esm2020/lib/services/node-permission.service.mjs +90 -0
- package/esm2020/lib/services/router.extension.service.mjs +106 -0
- package/esm2020/lib/shared.module.mjs +49 -0
- package/esm2020/lib/testing/lib-testing-module.mjs +118 -0
- package/esm2020/lib/testing/translation.service.mjs +45 -0
- package/esm2020/lib/utils/node.utils.mjs +34 -0
- package/esm2020/public-api.mjs +63 -0
- package/esm2020/rules/alfresco-aca-shared-rules.mjs +5 -0
- package/esm2020/rules/app.rules.mjs +503 -0
- package/esm2020/rules/navigation.rules.mjs +152 -0
- package/{esm5/store/store.module.js → esm2020/rules/public-api.mjs} +5 -23
- package/{esm5/store/actions/metadata-aspect.actions.js → esm2020/rules/repository.rules.mjs} +9 -20
- package/{esm2015/rules/repository.rules.js → esm2020/rules/user.rules.mjs} +4 -12
- package/esm2020/store/actions/app-action-types.mjs +48 -0
- package/esm2020/store/actions/app.actions.mjs +135 -0
- package/esm2020/store/actions/context-menu-action-types.mjs +29 -0
- package/esm2020/store/actions/contextmenu.actions.mjs +32 -0
- package/esm2020/store/actions/library.actions.mjs +64 -0
- package/{esm5/lib/components/locked-by/locked-by.module.js → esm2020/store/actions/metadata-aspect.actions.mjs} +7 -21
- package/esm2020/store/actions/node.actions.mjs +189 -0
- package/esm2020/store/actions/router-action-types.mjs +33 -0
- package/esm2020/store/actions/router.actions.mjs +55 -0
- package/{esm2015/lib/components/page-layout/page-layout-content.component.js → esm2020/store/actions/search.actions.mjs} +10 -27
- package/esm2020/store/actions/snackbar.actions.mjs +58 -0
- package/esm2020/store/actions/template-action-types.mjs +32 -0
- package/esm2020/store/actions/template.actions.mjs +48 -0
- package/esm2020/store/actions/upload.actions.mjs +50 -0
- package/esm2020/store/actions/viewer.actions.mjs +82 -0
- package/esm2020/store/alfresco-aca-shared-store.mjs +5 -0
- package/esm2020/store/effects/dialog.effects.mjs +45 -0
- package/esm2020/store/effects/router.effects.mjs +117 -0
- package/esm2020/store/effects/snackbar.effects.mjs +86 -0
- package/esm2020/store/models/delete-status.model.mjs +26 -0
- package/esm2020/store/models/deleted-node-info.model.mjs +26 -0
- package/esm2020/store/models/modal-configuration.mjs +2 -0
- package/{esm2015/lib/components/page-layout/page-layout-error.component.js → esm2020/store/models/node-info.model.mjs} +2 -19
- package/{esm5/lib/components/page-layout/page-layout-error.component.js → esm2020/store/models/search-option.model.mjs} +7 -21
- package/esm2020/store/public-api.mjs +50 -0
- package/esm2020/store/selectors/app.selectors.mjs +60 -0
- package/{esm5/lib/directives/shared.directives.module.js → esm2020/store/states/app.state.mjs} +3 -21
- package/esm2020/store/store.module.mjs +43 -0
- package/fesm2015/alfresco-aca-shared-rules.mjs +751 -0
- package/fesm2015/alfresco-aca-shared-rules.mjs.map +1 -0
- package/fesm2015/alfresco-aca-shared-store.mjs +1327 -0
- package/fesm2015/alfresco-aca-shared-store.mjs.map +1 -0
- package/fesm2015/alfresco-aca-shared.mjs +2726 -0
- package/fesm2015/alfresco-aca-shared.mjs.map +1 -0
- package/{fesm2015/alfresco-aca-shared-rules.js → fesm2020/alfresco-aca-shared-rules.mjs} +273 -353
- package/fesm2020/alfresco-aca-shared-rules.mjs.map +1 -0
- package/fesm2020/alfresco-aca-shared-store.mjs +1406 -0
- package/fesm2020/alfresco-aca-shared-store.mjs.map +1 -0
- package/fesm2020/alfresco-aca-shared.mjs +2841 -0
- package/fesm2020/alfresco-aca-shared.mjs.map +1 -0
- package/{rules/alfresco-aca-shared-rules.d.ts → index.d.ts} +1 -0
- package/lib/adf-extensions/extensions-data-loader.guard.d.ts +4 -1
- package/lib/components/document-base-page/document-base-page.component.d.ts +74 -0
- package/lib/components/document-base-page/document-base-page.service.d.ts +5 -0
- package/lib/components/generic-error/generic-error.component.d.ts +3 -24
- package/lib/components/generic-error/generic-error.module.d.ts +8 -24
- package/lib/components/info-drawer/info-drawer.component.d.ts +6 -0
- package/lib/components/info-drawer/shared-info-drawer.module.d.ts +11 -24
- package/lib/components/locked-by/locked-by.component.d.ts +5 -30
- package/lib/components/locked-by/locked-by.module.d.ts +8 -24
- package/lib/components/page-layout/page-layout-content.component.d.ts +3 -24
- package/lib/components/page-layout/page-layout-error.component.d.ts +3 -24
- package/lib/components/page-layout/page-layout-header.component.d.ts +3 -24
- package/lib/components/page-layout/page-layout.component.d.ts +3 -24
- package/lib/components/page-layout/page-layout.module.d.ts +9 -24
- package/lib/components/tool-bar/shared-toolbar.module.d.ts +11 -24
- package/lib/components/tool-bar/toolbar-action/toolbar-action.component.d.ts +7 -2
- package/lib/components/tool-bar/toolbar-button/toolbar-button.component.d.ts +5 -25
- package/lib/components/tool-bar/toolbar-menu/toolbar-menu.component.d.ts +15 -6
- package/lib/components/tool-bar/toolbar-menu-item/toolbar-menu-item.component.d.ts +7 -27
- package/lib/directives/contextmenu/contextmenu.directive.d.ts +5 -1
- package/lib/directives/contextmenu/contextmenu.module.d.ts +5 -24
- package/lib/directives/pagination.directive.d.ts +3 -0
- package/lib/directives/shared.directives.module.d.ts +6 -24
- package/lib/models/modal-configuration.d.ts +3 -0
- package/lib/models/viewer.rules.d.ts +4 -0
- package/lib/routing/shared.guard.d.ts +3 -24
- package/lib/services/alfresco-office-extension.service.d.ts +11 -0
- package/lib/services/app-hook.service.d.ts +55 -0
- package/lib/services/app.extension.service.d.ts +31 -53
- package/lib/services/app.service.d.ts +43 -7
- package/lib/services/content-api.service.d.ts +35 -25
- package/lib/services/node-permission.service.d.ts +3 -24
- package/lib/services/router.extension.service.d.ts +21 -0
- package/lib/shared.module.d.ts +6 -1
- package/lib/testing/lib-testing-module.d.ts +43 -0
- package/lib/testing/translation.service.d.ts +10 -0
- package/package.json +58 -21
- package/public-api.d.ts +19 -5
- package/rules/app.rules.d.ts +104 -30
- package/{store/alfresco-aca-shared-store.d.ts → rules/index.d.ts} +1 -0
- package/rules/navigation.rules.d.ts +6 -6
- package/rules/repository.rules.d.ts +2 -1
- package/rules/user.rules.d.ts +1 -1
- package/store/actions/app-action-types.d.ts +46 -0
- package/store/actions/app.actions.d.ts +25 -18
- package/{lib/routing/app.routes.strategy.d.ts → store/actions/context-menu-action-types.d.ts} +2 -15
- package/store/actions/contextmenu.actions.d.ts +1 -3
- package/store/actions/library.actions.d.ts +3 -1
- package/store/actions/node.actions.d.ts +33 -7
- package/store/actions/router-action-types.d.ts +31 -0
- package/store/actions/router.actions.d.ts +5 -6
- package/store/actions/search.actions.d.ts +1 -13
- package/store/actions/snackbar.actions.d.ts +8 -11
- package/store/actions/template-action-types.d.ts +30 -0
- package/store/actions/template.actions.d.ts +1 -6
- package/store/actions/upload.actions.d.ts +3 -1
- package/store/actions/viewer.actions.d.ts +22 -1
- package/store/effects/dialog.effects.d.ts +4 -1
- package/store/effects/router.effects.d.ts +11 -29
- package/store/effects/snackbar.effects.d.ts +6 -3
- package/store/index.d.ts +5 -0
- package/store/models/modal-configuration.d.ts +3 -0
- package/store/public-api.d.ts +4 -0
- package/store/selectors/app.selectors.d.ts +33 -19
- package/store/states/app.state.d.ts +10 -2
- package/store/store.module.d.ts +5 -24
- package/alfresco-aca-shared.d.ts +0 -11
- package/alfresco-aca-shared.metadata.json +0 -1
- package/bundles/alfresco-aca-shared-rules.umd.js +0 -895
- package/bundles/alfresco-aca-shared-rules.umd.js.map +0 -1
- package/bundles/alfresco-aca-shared-rules.umd.min.js +0 -75
- package/bundles/alfresco-aca-shared-rules.umd.min.js.map +0 -1
- package/bundles/alfresco-aca-shared-store.umd.js +0 -1399
- package/bundles/alfresco-aca-shared-store.umd.js.map +0 -1
- package/bundles/alfresco-aca-shared-store.umd.min.js +0 -26
- package/bundles/alfresco-aca-shared-store.umd.min.js.map +0 -1
- package/bundles/alfresco-aca-shared.umd.js +0 -2845
- package/bundles/alfresco-aca-shared.umd.js.map +0 -1
- package/bundles/alfresco-aca-shared.umd.min.js +0 -27
- package/bundles/alfresco-aca-shared.umd.min.js.map +0 -1
- package/esm2015/alfresco-aca-shared.js +0 -16
- package/esm2015/lib/adf-extensions/extensions-data-loader.guard.js +0 -106
- package/esm2015/lib/components/generic-error/generic-error.component.js +0 -52
- package/esm2015/lib/components/generic-error/generic-error.module.js +0 -43
- package/esm2015/lib/components/info-drawer/info-drawer.component.js +0 -179
- package/esm2015/lib/components/info-drawer/shared-info-drawer.module.js +0 -52
- package/esm2015/lib/components/locked-by/locked-by.component.js +0 -74
- package/esm2015/lib/components/page-layout/page-layout-header.component.js +0 -41
- package/esm2015/lib/components/page-layout/page-layout.component.js +0 -52
- package/esm2015/lib/components/page-layout/page-layout.module.js +0 -54
- package/esm2015/lib/components/tool-bar/shared-toolbar.module.js +0 -56
- package/esm2015/lib/components/tool-bar/toolbar-action/toolbar-action.component.js +0 -81
- package/esm2015/lib/components/tool-bar/toolbar-button/toolbar-button.component.js +0 -96
- package/esm2015/lib/components/tool-bar/toolbar-menu/toolbar-menu.component.js +0 -69
- package/esm2015/lib/components/tool-bar/toolbar-menu-item/toolbar-menu-item.component.js +0 -95
- package/esm2015/lib/directives/contextmenu/contextmenu.directive.js +0 -156
- package/esm2015/lib/directives/contextmenu/contextmenu.module.js +0 -42
- package/esm2015/lib/directives/pagination.directive.js +0 -93
- package/esm2015/lib/directives/shared.directives.module.js +0 -41
- package/esm2015/lib/models/viewer.rules.js +0 -40
- package/esm2015/lib/routing/app.routes.strategy.js +0 -207
- package/esm2015/lib/routing/shared.guard.js +0 -70
- package/esm2015/lib/services/app.extension.service.js +0 -686
- package/esm2015/lib/services/app.service.js +0 -95
- package/esm2015/lib/services/content-api.service.js +0 -331
- package/esm2015/lib/services/node-permission.service.js +0 -133
- package/esm2015/lib/shared.module.js +0 -51
- package/esm2015/lib/utils/node.utils.js +0 -53
- package/esm2015/public-api.js +0 -53
- package/esm2015/rules/alfresco-aca-shared-rules.js +0 -9
- package/esm2015/rules/app.rules.js +0 -563
- package/esm2015/rules/navigation.rules.js +0 -211
- package/esm2015/rules/public-api.js +0 -33
- package/esm2015/rules/user.rules.js +0 -38
- package/esm2015/store/actions/app.actions.js +0 -234
- package/esm2015/store/actions/contextmenu.actions.js +0 -49
- package/esm2015/store/actions/library.actions.js +0 -111
- package/esm2015/store/actions/metadata-aspect.actions.js +0 -46
- package/esm2015/store/actions/node.actions.js +0 -337
- package/esm2015/store/actions/router.actions.js +0 -97
- package/esm2015/store/actions/search.actions.js +0 -83
- package/esm2015/store/actions/snackbar.actions.js +0 -138
- package/esm2015/store/actions/template.actions.js +0 -85
- package/esm2015/store/actions/upload.actions.js +0 -81
- package/esm2015/store/actions/viewer.actions.js +0 -115
- package/esm2015/store/alfresco-aca-shared-store.js +0 -9
- package/esm2015/store/effects/dialog.effects.js +0 -72
- package/esm2015/store/effects/router.effects.js +0 -192
- package/esm2015/store/effects/snackbar.effects.js +0 -144
- package/esm2015/store/models/delete-status.model.js +0 -55
- package/esm2015/store/models/deleted-node-info.model.js +0 -41
- package/esm2015/store/models/node-info.model.js +0 -45
- package/esm2015/store/models/search-option.model.js +0 -52
- package/esm2015/store/public-api.js +0 -50
- package/esm2015/store/selectors/app.selectors.js +0 -82
- package/esm2015/store/states/app.state.js +0 -71
- package/esm2015/store/store.module.js +0 -43
- package/esm5/alfresco-aca-shared.js +0 -16
- package/esm5/lib/adf-extensions/extensions-data-loader.guard.js +0 -115
- package/esm5/lib/components/generic-error/generic-error.component.js +0 -54
- package/esm5/lib/components/generic-error/generic-error.module.js +0 -47
- package/esm5/lib/components/info-drawer/info-drawer.component.js +0 -209
- package/esm5/lib/components/info-drawer/shared-info-drawer.module.js +0 -56
- package/esm5/lib/components/locked-by/locked-by.component.js +0 -80
- package/esm5/lib/components/page-layout/page-layout-content.component.js +0 -53
- package/esm5/lib/components/page-layout/page-layout-header.component.js +0 -45
- package/esm5/lib/components/page-layout/page-layout.component.js +0 -54
- package/esm5/lib/components/page-layout/page-layout.module.js +0 -58
- package/esm5/lib/components/tool-bar/shared-toolbar.module.js +0 -60
- package/esm5/lib/components/tool-bar/toolbar-action/toolbar-action.component.js +0 -88
- package/esm5/lib/components/tool-bar/toolbar-button/toolbar-button.component.js +0 -103
- package/esm5/lib/components/tool-bar/toolbar-menu/toolbar-menu.component.js +0 -80
- package/esm5/lib/components/tool-bar/toolbar-menu-item/toolbar-menu-item.component.js +0 -103
- package/esm5/lib/directives/contextmenu/contextmenu.directive.js +0 -187
- package/esm5/lib/directives/contextmenu/contextmenu.module.js +0 -46
- package/esm5/lib/directives/pagination.directive.js +0 -97
- package/esm5/lib/models/types.js +0 -67
- package/esm5/lib/models/viewer.rules.js +0 -40
- package/esm5/lib/routing/app.routes.strategy.js +0 -268
- package/esm5/lib/routing/shared.guard.js +0 -77
- package/esm5/lib/services/app.extension.service.js +0 -835
- package/esm5/lib/services/app.service.js +0 -100
- package/esm5/lib/services/content-api.service.js +0 -495
- package/esm5/lib/services/node-permission.service.js +0 -161
- package/esm5/lib/shared.module.js +0 -58
- package/esm5/lib/utils/node.utils.js +0 -53
- package/esm5/public-api.js +0 -53
- package/esm5/rules/alfresco-aca-shared-rules.js +0 -9
- package/esm5/rules/app.rules.js +0 -563
- package/esm5/rules/navigation.rules.js +0 -211
- package/esm5/rules/public-api.js +0 -33
- package/esm5/rules/repository.rules.js +0 -38
- package/esm5/rules/user.rules.js +0 -38
- package/esm5/store/actions/app.actions.js +0 -232
- package/esm5/store/actions/contextmenu.actions.js +0 -48
- package/esm5/store/actions/library.actions.js +0 -108
- package/esm5/store/actions/node.actions.js +0 -322
- package/esm5/store/actions/router.actions.js +0 -93
- package/esm5/store/actions/search.actions.js +0 -87
- package/esm5/store/actions/snackbar.actions.js +0 -130
- package/esm5/store/actions/template.actions.js +0 -87
- package/esm5/store/actions/upload.actions.js +0 -78
- package/esm5/store/actions/viewer.actions.js +0 -109
- package/esm5/store/alfresco-aca-shared-store.js +0 -9
- package/esm5/store/effects/dialog.effects.js +0 -71
- package/esm5/store/effects/router.effects.js +0 -207
- package/esm5/store/effects/snackbar.effects.js +0 -154
- package/esm5/store/models/delete-status.model.js +0 -55
- package/esm5/store/models/deleted-node-info.model.js +0 -41
- package/esm5/store/models/node-info.model.js +0 -45
- package/esm5/store/models/search-option.model.js +0 -52
- package/esm5/store/public-api.js +0 -50
- package/esm5/store/selectors/app.selectors.js +0 -82
- package/esm5/store/states/app.state.js +0 -71
- package/fesm2015/alfresco-aca-shared-rules.js.map +0 -1
- package/fesm2015/alfresco-aca-shared-store.js +0 -1354
- package/fesm2015/alfresco-aca-shared-store.js.map +0 -1
- package/fesm2015/alfresco-aca-shared.js +0 -2096
- package/fesm2015/alfresco-aca-shared.js.map +0 -1
- package/fesm5/alfresco-aca-shared-rules.js +0 -827
- package/fesm5/alfresco-aca-shared-rules.js.map +0 -1
- package/fesm5/alfresco-aca-shared-store.js +0 -1278
- package/fesm5/alfresco-aca-shared-store.js.map +0 -1
- package/fesm5/alfresco-aca-shared.js +0 -2637
- package/fesm5/alfresco-aca-shared.js.map +0 -1
- package/rules/alfresco-aca-shared-rules.metadata.json +0 -1
- package/rules/package.json +0 -13
- package/store/alfresco-aca-shared-store.metadata.json +0 -1
- package/store/package.json +0 -13
|
@@ -1,7 +1,3 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @fileoverview added by tsickle
|
|
3
|
-
* @suppress {checkTypes,extraRequire,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
|
|
4
|
-
*/
|
|
5
1
|
/*!
|
|
6
2
|
* @license
|
|
7
3
|
* Alfresco Example Content Application
|
|
@@ -29,21 +25,14 @@
|
|
|
29
25
|
/**
|
|
30
26
|
* Checks if a Preview route is activated.
|
|
31
27
|
* JSON ref: `app.navigation.isPreview`
|
|
32
|
-
* @param {?} context
|
|
33
|
-
* @return {?}
|
|
34
28
|
*/
|
|
35
29
|
function isPreview(context) {
|
|
36
30
|
const { url } = context.navigation;
|
|
37
|
-
return (url
|
|
38
|
-
(url.includes('/preview/') ||
|
|
39
|
-
url.includes('viewer:view') ||
|
|
40
|
-
url.includes('/view/')));
|
|
31
|
+
return url && (url.includes('/preview/') || url.includes('viewer:view') || url.includes('/view/'));
|
|
41
32
|
}
|
|
42
33
|
/**
|
|
43
34
|
* Checks if a **Favorites** route is activated.
|
|
44
35
|
* JSON ref: `app.navigation.isFavorites`
|
|
45
|
-
* @param {?} context
|
|
46
|
-
* @return {?}
|
|
47
36
|
*/
|
|
48
37
|
function isFavorites(context) {
|
|
49
38
|
const { url } = context.navigation;
|
|
@@ -52,17 +41,11 @@ function isFavorites(context) {
|
|
|
52
41
|
/**
|
|
53
42
|
* Checks if the activated route is not **Favorites**.
|
|
54
43
|
* JSON ref: `app.navigation.isNotFavorites`
|
|
55
|
-
* @param {?} context
|
|
56
|
-
* @return {?}
|
|
57
44
|
*/
|
|
58
|
-
|
|
59
|
-
return !isFavorites(context);
|
|
60
|
-
}
|
|
45
|
+
const isNotFavorites = (context) => !isFavorites(context);
|
|
61
46
|
/**
|
|
62
47
|
* Checks if a **Shared Files** route is activated.
|
|
63
48
|
* JSON ref: `app.navigation.isSharedFiles`
|
|
64
|
-
* @param {?} context
|
|
65
|
-
* @return {?}
|
|
66
49
|
*/
|
|
67
50
|
function isSharedFiles(context) {
|
|
68
51
|
const { url } = context.navigation;
|
|
@@ -71,17 +54,11 @@ function isSharedFiles(context) {
|
|
|
71
54
|
/**
|
|
72
55
|
* Checks if the activated route is not **Shared Files**.
|
|
73
56
|
* JSON ref: `app.navigation.isNotSharedFiles`
|
|
74
|
-
* @param {?} context
|
|
75
|
-
* @return {?}
|
|
76
57
|
*/
|
|
77
|
-
|
|
78
|
-
return !isSharedFiles(context);
|
|
79
|
-
}
|
|
58
|
+
const isNotSharedFiles = (context) => !isSharedFiles(context);
|
|
80
59
|
/**
|
|
81
60
|
* Checks if a **Trashcan** route is activated.
|
|
82
61
|
* JSON ref: `app.navigation.isTrashcan`
|
|
83
|
-
* @param {?} context
|
|
84
|
-
* @return {?}
|
|
85
62
|
*/
|
|
86
63
|
function isTrashcan(context) {
|
|
87
64
|
const { url } = context.navigation;
|
|
@@ -90,17 +67,11 @@ function isTrashcan(context) {
|
|
|
90
67
|
/**
|
|
91
68
|
* Checks if the activated route is not **Trashcan**.
|
|
92
69
|
* JSON ref: `app.navigation.isNotTrashcan`
|
|
93
|
-
* @param {?} context
|
|
94
|
-
* @return {?}
|
|
95
70
|
*/
|
|
96
|
-
|
|
97
|
-
return !isTrashcan(context);
|
|
98
|
-
}
|
|
71
|
+
const isNotTrashcan = (context) => !isTrashcan(context);
|
|
99
72
|
/**
|
|
100
73
|
* Checks if a **Personal Files** route is activated.
|
|
101
74
|
* JSON ref: `app.navigation.isPersonalFiles`
|
|
102
|
-
* @param {?} context
|
|
103
|
-
* @return {?}
|
|
104
75
|
*/
|
|
105
76
|
function isPersonalFiles(context) {
|
|
106
77
|
const { url } = context.navigation;
|
|
@@ -109,8 +80,6 @@ function isPersonalFiles(context) {
|
|
|
109
80
|
/**
|
|
110
81
|
* Checks if a **Library Files** route is activated.
|
|
111
82
|
* JSON ref: `app.navigation.isLibraryFiles`
|
|
112
|
-
* @param {?} context
|
|
113
|
-
* @return {?}
|
|
114
83
|
*/
|
|
115
84
|
function isLibraryFiles(context) {
|
|
116
85
|
const { url } = context.navigation;
|
|
@@ -119,27 +88,19 @@ function isLibraryFiles(context) {
|
|
|
119
88
|
/**
|
|
120
89
|
* Checks if a **Library Files** or **Library Search Result** route is activated.
|
|
121
90
|
* JSON ref: `app.navigation.isLibraryFiles`
|
|
122
|
-
* @param {?} context
|
|
123
|
-
* @return {?}
|
|
124
91
|
*/
|
|
125
92
|
function isLibraries(context) {
|
|
126
93
|
const { url } = context.navigation;
|
|
127
|
-
return
|
|
94
|
+
return url && (url.endsWith('/libraries') || url.startsWith('/search-libraries'));
|
|
128
95
|
}
|
|
129
96
|
/**
|
|
130
97
|
* Checks if the activated route is neither **Libraries** nor **Library Search Results**.
|
|
131
98
|
* JSON ref: `app.navigation.isNotLibraries`
|
|
132
|
-
* @param {?} context
|
|
133
|
-
* @return {?}
|
|
134
99
|
*/
|
|
135
|
-
|
|
136
|
-
return !isLibraries(context);
|
|
137
|
-
}
|
|
100
|
+
const isNotLibraries = (context) => !isLibraries(context);
|
|
138
101
|
/**
|
|
139
102
|
* Checks if a **Recent Files** route is activated.
|
|
140
103
|
* JSON ref: `app.navigation.isRecentFiles`
|
|
141
|
-
* @param {?} context
|
|
142
|
-
* @return {?}
|
|
143
104
|
*/
|
|
144
105
|
function isRecentFiles(context) {
|
|
145
106
|
const { url } = context.navigation;
|
|
@@ -148,17 +109,11 @@ function isRecentFiles(context) {
|
|
|
148
109
|
/**
|
|
149
110
|
* Checks if the activated route is not **Recent Files**.
|
|
150
111
|
* JSON ref: `app.navigation.isNotRecentFiles`
|
|
151
|
-
* @param {?} context
|
|
152
|
-
* @return {?}
|
|
153
112
|
*/
|
|
154
|
-
|
|
155
|
-
return !isRecentFiles(context);
|
|
156
|
-
}
|
|
113
|
+
const isNotRecentFiles = (context) => !isRecentFiles(context);
|
|
157
114
|
/**
|
|
158
115
|
* Checks if a **Search Results** route is activated.
|
|
159
116
|
* JSON ref: `app.navigation.isSearchResults`
|
|
160
|
-
* @param {?} context
|
|
161
|
-
* @return {?}
|
|
162
117
|
*/
|
|
163
118
|
function isSearchResults(context /*,
|
|
164
119
|
...args: RuleParameter[]*/) {
|
|
@@ -168,51 +123,33 @@ function isSearchResults(context /*,
|
|
|
168
123
|
/**
|
|
169
124
|
* Checks if the activated route is not **Search Results**.
|
|
170
125
|
* JSON ref: `app.navigation.isNotSearchResults`
|
|
171
|
-
* @param {?} context
|
|
172
|
-
* @return {?}
|
|
173
126
|
*/
|
|
174
|
-
|
|
175
|
-
return !isSearchResults(context);
|
|
176
|
-
}
|
|
127
|
+
const isNotSearchResults = (context) => !isSearchResults(context);
|
|
177
128
|
/**
|
|
178
129
|
* Checks if a **Shared Preview** route is activated.
|
|
179
130
|
* JSON ref: `app.navigation.isSharedPreview`
|
|
180
|
-
* @param {?} context
|
|
181
|
-
* @return {?}
|
|
182
131
|
*/
|
|
183
132
|
function isSharedPreview(context) {
|
|
184
133
|
const { url } = context.navigation;
|
|
185
|
-
return (url &&
|
|
186
|
-
(url.startsWith('/shared/preview/') ||
|
|
187
|
-
(url.startsWith('/shared') && url.includes('viewer:view'))));
|
|
134
|
+
return url && (url.startsWith('/shared/preview/') || (url.startsWith('/shared') && url.includes('viewer:view')));
|
|
188
135
|
}
|
|
189
136
|
/**
|
|
190
137
|
* Checks if a **Favorites Preview** route is activated.
|
|
191
138
|
* JSON ref: `app.navigation.isFavoritesPreview`
|
|
192
|
-
* @param {?} context
|
|
193
|
-
* @return {?}
|
|
194
139
|
*/
|
|
195
140
|
function isFavoritesPreview(context) {
|
|
196
141
|
const { url } = context.navigation;
|
|
197
|
-
return (url &&
|
|
198
|
-
(url.startsWith('/favorites/preview/') ||
|
|
199
|
-
(url.startsWith('/favorites') && url.includes('viewer:view'))));
|
|
142
|
+
return url && (url.startsWith('/favorites/preview/') || (url.startsWith('/favorites') && url.includes('viewer:view')));
|
|
200
143
|
}
|
|
201
144
|
/**
|
|
202
145
|
* Checks if a **Shared File Preview** route is activated.
|
|
203
146
|
* JSON ref: `app.navigation.isFavoritesPreview`
|
|
204
|
-
* @param {?} context
|
|
205
|
-
* @return {?}
|
|
206
147
|
*/
|
|
207
148
|
function isSharedFileViewer(context) {
|
|
208
149
|
const { url } = context.navigation;
|
|
209
150
|
return url && url.startsWith('/preview/s/');
|
|
210
151
|
}
|
|
211
152
|
|
|
212
|
-
/**
|
|
213
|
-
* @fileoverview added by tsickle
|
|
214
|
-
* @suppress {checkTypes,extraRequire,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
|
|
215
|
-
*/
|
|
216
153
|
/*!
|
|
217
154
|
* @license
|
|
218
155
|
* Alfresco Example Content Application
|
|
@@ -240,124 +177,186 @@ function isSharedFileViewer(context) {
|
|
|
240
177
|
/**
|
|
241
178
|
* Checks if the quick share repository option is enabled or not.
|
|
242
179
|
* JSON ref: `repository.isQuickShareEnabled`
|
|
243
|
-
* @param {?} context
|
|
244
|
-
* @return {?}
|
|
245
180
|
*/
|
|
246
|
-
|
|
247
|
-
|
|
181
|
+
const hasQuickShareEnabled = (context) => context.repository.status.isQuickShareEnabled;
|
|
182
|
+
function isMajorVersionAvailable(context, versionNumber) {
|
|
183
|
+
const majorVersion = context.repository.version?.major ? parseInt(context.repository.version.major, 10) : 0;
|
|
184
|
+
return majorVersion >= parseInt(versionNumber, 10);
|
|
248
185
|
}
|
|
249
186
|
|
|
187
|
+
/*!
|
|
188
|
+
* @license
|
|
189
|
+
* Alfresco Example Content Application
|
|
190
|
+
*
|
|
191
|
+
* Copyright (C) 2005 - 2020 Alfresco Software Limited
|
|
192
|
+
*
|
|
193
|
+
* This file is part of the Alfresco Example Content Application.
|
|
194
|
+
* If the software was purchased under a paid Alfresco license, the terms of
|
|
195
|
+
* the paid license agreement will prevail. Otherwise, the software is
|
|
196
|
+
* provided under the following open source license terms:
|
|
197
|
+
*
|
|
198
|
+
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
199
|
+
* it under the terms of the GNU Lesser General Public License as published by
|
|
200
|
+
* the Free Software Foundation, either version 3 of the License, or
|
|
201
|
+
* (at your option) any later version.
|
|
202
|
+
*
|
|
203
|
+
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
204
|
+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
205
|
+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
206
|
+
* GNU Lesser General Public License for more details.
|
|
207
|
+
*
|
|
208
|
+
* You should have received a copy of the GNU Lesser General Public License
|
|
209
|
+
* along with Alfresco. If not, see <http://www.gnu.org/licenses/>.
|
|
210
|
+
*/
|
|
250
211
|
/**
|
|
251
|
-
*
|
|
252
|
-
*
|
|
212
|
+
* Checks if user is admin.
|
|
213
|
+
* JSON ref: `user.isAdmin`
|
|
253
214
|
*/
|
|
215
|
+
const isAdmin = (context) => context.profile.isAdmin;
|
|
216
|
+
|
|
217
|
+
/*!
|
|
218
|
+
* @license
|
|
219
|
+
* Alfresco Example Content Application
|
|
220
|
+
*
|
|
221
|
+
* Copyright (C) 2005 - 2020 Alfresco Software Limited
|
|
222
|
+
*
|
|
223
|
+
* This file is part of the Alfresco Example Content Application.
|
|
224
|
+
* If the software was purchased under a paid Alfresco license, the terms of
|
|
225
|
+
* the paid license agreement will prevail. Otherwise, the software is
|
|
226
|
+
* provided under the following open source license terms:
|
|
227
|
+
*
|
|
228
|
+
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
229
|
+
* it under the terms of the GNU Lesser General Public License as published by
|
|
230
|
+
* the Free Software Foundation, either version 3 of the License, or
|
|
231
|
+
* (at your option) any later version.
|
|
232
|
+
*
|
|
233
|
+
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
234
|
+
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
235
|
+
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
236
|
+
* GNU Lesser General Public License for more details.
|
|
237
|
+
*
|
|
238
|
+
* You should have received a copy of the GNU Lesser General Public License
|
|
239
|
+
* along with Alfresco. If not, see <http://www.gnu.org/licenses/>.
|
|
240
|
+
*/
|
|
241
|
+
/* cspell:disable */
|
|
242
|
+
const supportedExtensions = {
|
|
243
|
+
doc: 'ms-word',
|
|
244
|
+
docx: 'ms-word',
|
|
245
|
+
docm: 'ms-word',
|
|
246
|
+
dot: 'ms-word',
|
|
247
|
+
dotx: 'ms-word',
|
|
248
|
+
dotm: 'ms-word',
|
|
249
|
+
rtf: 'ms-word',
|
|
250
|
+
xls: 'ms-excel',
|
|
251
|
+
xlsx: 'ms-excel',
|
|
252
|
+
xlsb: 'ms-excel',
|
|
253
|
+
xlsm: 'ms-excel',
|
|
254
|
+
xlt: 'ms-excel',
|
|
255
|
+
xltx: 'ms-excel',
|
|
256
|
+
xltm: 'ms-excel',
|
|
257
|
+
xlam: 'ms-excel',
|
|
258
|
+
ppt: 'ms-powerpoint',
|
|
259
|
+
pptx: 'ms-powerpoint',
|
|
260
|
+
pot: 'ms-powerpoint',
|
|
261
|
+
potx: 'ms-powerpoint',
|
|
262
|
+
potm: 'ms-powerpoint',
|
|
263
|
+
pptm: 'ms-powerpoint',
|
|
264
|
+
pps: 'ms-powerpoint',
|
|
265
|
+
ppsx: 'ms-powerpoint',
|
|
266
|
+
ppam: 'ms-powerpoint',
|
|
267
|
+
ppsm: 'ms-powerpoint',
|
|
268
|
+
sldx: 'ms-powerpoint',
|
|
269
|
+
sldm: 'ms-powerpoint',
|
|
270
|
+
vsd: 'ms-visio',
|
|
271
|
+
vss: 'ms-visio',
|
|
272
|
+
vst: 'ms-visio',
|
|
273
|
+
vsdx: 'ms-visio',
|
|
274
|
+
vsdm: 'ms-visio',
|
|
275
|
+
vssx: 'ms-visio',
|
|
276
|
+
vssm: 'ms-visio',
|
|
277
|
+
vstx: 'ms-visio',
|
|
278
|
+
vstm: 'ms-visio'
|
|
279
|
+
};
|
|
280
|
+
/* cspell:enable */
|
|
281
|
+
function getFileExtension(fileName) {
|
|
282
|
+
if (fileName) {
|
|
283
|
+
const match = fileName.match(/\.([^\./\?\#]+)($|\?|\#)/);
|
|
284
|
+
return match ? match[1] : null;
|
|
285
|
+
}
|
|
286
|
+
return null;
|
|
287
|
+
}
|
|
288
|
+
/**
|
|
289
|
+
* Checks if the content plugin is enabled.
|
|
290
|
+
* JSON ref: `app.isContentServiceEnabled`
|
|
291
|
+
*/
|
|
292
|
+
const isContentServiceEnabled = () => localStorage && localStorage.getItem('contentService') !== 'false';
|
|
254
293
|
/**
|
|
255
294
|
* Checks if user can copy selected node.
|
|
256
295
|
* JSON ref: `app.canCopyNode`
|
|
257
|
-
*
|
|
258
|
-
* @
|
|
296
|
+
*
|
|
297
|
+
* @param context Rule execution context
|
|
259
298
|
*/
|
|
260
|
-
|
|
261
|
-
return [
|
|
262
|
-
hasSelection(context),
|
|
263
|
-
isNotTrashcan(context),
|
|
264
|
-
isNotLibraries(context)
|
|
265
|
-
].every(Boolean);
|
|
266
|
-
}
|
|
299
|
+
const canCopyNode = (context) => [hasSelection(context), isNotTrashcan(context), isNotLibraries(context)].every(Boolean);
|
|
267
300
|
/**
|
|
268
301
|
* Checks if user can mark selected nodes as **Favorite**.
|
|
269
302
|
* JSON ref: `app.selection.canAddFavorite`
|
|
270
|
-
* @param {?} context
|
|
271
|
-
* @return {?}
|
|
272
303
|
*/
|
|
273
304
|
function canAddFavorite(context) {
|
|
274
305
|
if (!context.selection.isEmpty) {
|
|
275
|
-
if (isFavorites(context) ||
|
|
276
|
-
isLibraries(context) ||
|
|
277
|
-
isTrashcan(context)) {
|
|
306
|
+
if (isFavorites(context) || isLibraries(context) || isTrashcan(context)) {
|
|
278
307
|
return false;
|
|
279
308
|
}
|
|
280
|
-
return context.selection.nodes.some(node => !node.entry.isFavorite);
|
|
309
|
+
return context.selection.nodes.some((node) => !node.entry.isFavorite);
|
|
281
310
|
}
|
|
282
311
|
return false;
|
|
283
312
|
}
|
|
284
313
|
/**
|
|
285
314
|
* Checks if user can un-mark selected nodes as **Favorite**.
|
|
286
315
|
* JSON ref: `app.selection.canRemoveFavorite`
|
|
287
|
-
* @param {?} context
|
|
288
|
-
* @return {?}
|
|
289
316
|
*/
|
|
290
317
|
function canRemoveFavorite(context) {
|
|
291
318
|
if (!context.selection.isEmpty && !isTrashcan(context)) {
|
|
292
319
|
if (isFavorites(context)) {
|
|
293
320
|
return true;
|
|
294
321
|
}
|
|
295
|
-
return context.selection.nodes.every(node => node.entry.isFavorite);
|
|
322
|
+
return context.selection.nodes.every((node) => node.entry.isFavorite);
|
|
296
323
|
}
|
|
297
324
|
return false;
|
|
298
325
|
}
|
|
299
326
|
/**
|
|
300
327
|
* Checks if user can share selected file.
|
|
301
328
|
* JSON ref: `app.selection.file.canShare`
|
|
302
|
-
* @param {?} context
|
|
303
|
-
* @return {?}
|
|
304
329
|
*/
|
|
305
|
-
|
|
306
|
-
return [
|
|
307
|
-
context.selection.file,
|
|
308
|
-
isNotTrashcan(context),
|
|
309
|
-
hasQuickShareEnabled(context),
|
|
310
|
-
!isShared(context)
|
|
311
|
-
].every(Boolean);
|
|
312
|
-
}
|
|
330
|
+
const canShareFile = (context) => [context.selection.file, isNotTrashcan(context), hasQuickShareEnabled(context), !isShared(context)].every(Boolean);
|
|
313
331
|
/**
|
|
314
332
|
* Checks if user can perform "Join" or "Cancel Join Request" on a library.
|
|
315
333
|
* JSON ref: `canToggleJoinLibrary`
|
|
316
|
-
* @param {?} context
|
|
317
|
-
* @return {?}
|
|
318
334
|
*/
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
hasLibrarySelected(context),
|
|
322
|
-
!isPrivateLibrary(context),
|
|
323
|
-
hasNoLibraryRole(context)
|
|
324
|
-
].every(Boolean);
|
|
325
|
-
}
|
|
335
|
+
const canToggleJoinLibrary = (context) => [hasLibrarySelected(context), !isPrivateLibrary(context), hasNoLibraryRole(context)].every(Boolean) ||
|
|
336
|
+
[hasLibrarySelected(context), isPrivateLibrary(context), hasNoLibraryRole(context), isAdmin(context)].every(Boolean);
|
|
326
337
|
/**
|
|
327
338
|
* Checks if user can edit the selected folder.
|
|
328
339
|
* JSON ref: `canEditFolder`
|
|
329
|
-
*
|
|
330
|
-
* @
|
|
340
|
+
*
|
|
341
|
+
* @param context Rule execution context
|
|
331
342
|
*/
|
|
332
|
-
|
|
333
|
-
return [
|
|
334
|
-
canUpdateSelectedFolder(context),
|
|
335
|
-
isNotTrashcan(context)
|
|
336
|
-
].every(Boolean);
|
|
337
|
-
}
|
|
343
|
+
const canEditFolder = (context) => [canUpdateSelectedFolder(context), isNotTrashcan(context)].every(Boolean);
|
|
338
344
|
/**
|
|
339
345
|
* Checks if the selected file is already shared.
|
|
340
346
|
* JSON ref: `app.selection.file.isShared`
|
|
341
|
-
* @param {?} context
|
|
342
|
-
* @return {?}
|
|
343
347
|
*/
|
|
344
348
|
function isShared(context) {
|
|
345
349
|
if (isSharedFiles(context) && context.selection.file) {
|
|
346
350
|
return true;
|
|
347
351
|
}
|
|
348
|
-
if (
|
|
349
|
-
|
|
350
|
-
return !!(context.selection.file.entry &&
|
|
351
|
-
context.selection.file.entry.properties &&
|
|
352
|
-
context.selection.file.entry.properties['qshare:sharedId']);
|
|
352
|
+
if (isNotTrashcan(context) && !context.selection.isEmpty && context.selection.file) {
|
|
353
|
+
return !!(context.selection.file.entry && context.selection.file.entry.properties && context.selection.file.entry.properties['qshare:sharedId']);
|
|
353
354
|
}
|
|
354
355
|
return false;
|
|
355
356
|
}
|
|
356
357
|
/**
|
|
357
358
|
* Checks if user can delete selected nodes.
|
|
358
359
|
* JSON ref: `app.selection.canDelete`
|
|
359
|
-
* @param {?} context
|
|
360
|
-
* @return {?}
|
|
361
360
|
*/
|
|
362
361
|
function canDeleteSelection(context) {
|
|
363
362
|
if (isNotTrashcan(context) &&
|
|
@@ -387,8 +386,6 @@ function canDeleteSelection(context) {
|
|
|
387
386
|
/**
|
|
388
387
|
* Checks if user can un-share selected nodes.
|
|
389
388
|
* JSON ref: `app.selection.canUnshare`
|
|
390
|
-
* @param {?} context
|
|
391
|
-
* @return {?}
|
|
392
389
|
*/
|
|
393
390
|
function canUnshareNodes(context) {
|
|
394
391
|
if (!context.selection.isEmpty) {
|
|
@@ -401,17 +398,11 @@ function canUnshareNodes(context) {
|
|
|
401
398
|
/**
|
|
402
399
|
* Checks if user selected anything.
|
|
403
400
|
* JSON ref: `app.selection.notEmpty`
|
|
404
|
-
* @param {?} context
|
|
405
|
-
* @return {?}
|
|
406
401
|
*/
|
|
407
|
-
|
|
408
|
-
return !context.selection.isEmpty;
|
|
409
|
-
}
|
|
402
|
+
const hasSelection = (context) => !context.selection.isEmpty;
|
|
410
403
|
/**
|
|
411
404
|
* Checks if user can create a new folder with current path.
|
|
412
405
|
* JSON ref: `app.navigation.folder.canCreate`
|
|
413
|
-
* @param {?} context
|
|
414
|
-
* @return {?}
|
|
415
406
|
*/
|
|
416
407
|
function canCreateFolder(context) {
|
|
417
408
|
const { currentFolder } = context.navigation;
|
|
@@ -423,8 +414,6 @@ function canCreateFolder(context) {
|
|
|
423
414
|
/**
|
|
424
415
|
* Checks if user can upload content to current folder.
|
|
425
416
|
* JSON ref: `app.navigation.folder.canUpload`
|
|
426
|
-
* @param {?} context
|
|
427
|
-
* @return {?}
|
|
428
417
|
*/
|
|
429
418
|
function canUpload(context) {
|
|
430
419
|
const { currentFolder } = context.navigation;
|
|
@@ -436,135 +425,94 @@ function canUpload(context) {
|
|
|
436
425
|
/**
|
|
437
426
|
* Checks if user can download selected nodes (either files or folders).
|
|
438
427
|
* JSON ref: `app.selection.canDownload`
|
|
439
|
-
* @param {?} context
|
|
440
|
-
* @return {?}
|
|
441
428
|
*/
|
|
442
429
|
function canDownloadSelection(context) {
|
|
443
430
|
if (!context.selection.isEmpty && isNotTrashcan(context)) {
|
|
444
|
-
return context.selection.nodes.every((node) =>
|
|
445
|
-
return (node.entry &&
|
|
446
|
-
(node.entry.isFile || node.entry.isFolder || !!node.entry.nodeId));
|
|
447
|
-
});
|
|
431
|
+
return context.selection.nodes.every((node) => node.entry && (node.entry.isFile || node.entry.isFolder || !!node.entry.nodeId));
|
|
448
432
|
}
|
|
449
433
|
return false;
|
|
450
434
|
}
|
|
451
435
|
/**
|
|
452
436
|
* Checks if user has selected a folder.
|
|
453
437
|
* JSON ref: `app.selection.folder`
|
|
454
|
-
* @param {?} context
|
|
455
|
-
* @return {?}
|
|
456
438
|
*/
|
|
457
|
-
|
|
458
|
-
/** @type {?} */
|
|
459
|
-
const folder = context.selection.folder;
|
|
460
|
-
return folder ? true : false;
|
|
461
|
-
}
|
|
439
|
+
const hasFolderSelected = (context) => !!context.selection.folder;
|
|
462
440
|
/**
|
|
463
441
|
* Checks if user has selected a library (site).
|
|
464
442
|
* JSON ref: `app.selection.library`
|
|
465
|
-
* @param {?} context
|
|
466
|
-
* @return {?}
|
|
467
443
|
*/
|
|
468
|
-
|
|
469
|
-
/** @type {?} */
|
|
470
|
-
const library = context.selection.library;
|
|
471
|
-
return library ? true : false;
|
|
472
|
-
}
|
|
444
|
+
const hasLibrarySelected = (context) => !!context.selection.library;
|
|
473
445
|
/**
|
|
474
446
|
* Checks if user has selected a **private** library (site)
|
|
475
447
|
* JSON ref: `app.selection.isPrivateLibrary`
|
|
476
|
-
* @param {?} context
|
|
477
|
-
* @return {?}
|
|
478
448
|
*/
|
|
479
449
|
function isPrivateLibrary(context) {
|
|
480
|
-
/** @type {?} */
|
|
481
450
|
const library = context.selection.library;
|
|
482
|
-
return library
|
|
483
|
-
? !!(library.entry &&
|
|
484
|
-
library.entry.visibility &&
|
|
485
|
-
library.entry.visibility === 'PRIVATE')
|
|
486
|
-
: false;
|
|
451
|
+
return library ? !!(library.entry && library.entry.visibility && library.entry.visibility === 'PRIVATE') : false;
|
|
487
452
|
}
|
|
488
453
|
/**
|
|
489
454
|
* Checks if the selected library has a **role** property defined.
|
|
490
455
|
* JSON ref: `app.selection.hasLibraryRole`
|
|
491
|
-
* @param {?} context
|
|
492
|
-
* @return {?}
|
|
493
456
|
*/
|
|
494
457
|
function hasLibraryRole(context) {
|
|
495
|
-
/** @type {?} */
|
|
496
458
|
const library = context.selection.library;
|
|
497
459
|
return library ? !!(library.entry && library.entry.role) : false;
|
|
498
460
|
}
|
|
499
461
|
/**
|
|
500
462
|
* Checks if the selected library has no **role** property defined.
|
|
501
463
|
* JSON ref: `app.selection.hasNoLibraryRole`
|
|
502
|
-
* @param {?} context
|
|
503
|
-
* @return {?}
|
|
504
464
|
*/
|
|
505
|
-
|
|
506
|
-
return !hasLibraryRole(context);
|
|
507
|
-
}
|
|
465
|
+
const hasNoLibraryRole = (context) => !hasLibraryRole(context);
|
|
508
466
|
/**
|
|
509
467
|
* Checks if user has selected a file.
|
|
510
468
|
* JSON ref: `app.selection.file`
|
|
511
|
-
* @param {?} context
|
|
512
|
-
* @return {?}
|
|
513
469
|
*/
|
|
514
|
-
|
|
515
|
-
if (context && context.selection && context.selection.file) {
|
|
516
|
-
return true;
|
|
517
|
-
}
|
|
518
|
-
return false;
|
|
519
|
-
}
|
|
470
|
+
const hasFileSelected = (context) => !!(context && context.selection && context.selection.file);
|
|
520
471
|
/**
|
|
521
472
|
* Checks if user can update the first selected node.
|
|
522
473
|
* JSON ref: `app.selection.first.canUpdate`
|
|
523
|
-
* @param {?} context
|
|
524
|
-
* @return {?}
|
|
525
474
|
*/
|
|
526
475
|
function canUpdateSelectedNode(context) {
|
|
527
476
|
if (context.selection && !context.selection.isEmpty) {
|
|
528
|
-
/** @type {?} */
|
|
529
477
|
const node = context.selection.first;
|
|
530
|
-
if (node
|
|
478
|
+
if (node?.entry.isFile && hasLockedFiles(context)) {
|
|
531
479
|
return false;
|
|
532
480
|
}
|
|
533
481
|
return context.permissions.check(node, ['update']);
|
|
534
482
|
}
|
|
535
483
|
return false;
|
|
536
484
|
}
|
|
485
|
+
function isMultiselection(context) {
|
|
486
|
+
let isMultiNodeSelected = false;
|
|
487
|
+
if (context.selection && !context.selection.isEmpty) {
|
|
488
|
+
isMultiNodeSelected = context.selection.count > 1;
|
|
489
|
+
}
|
|
490
|
+
return isMultiNodeSelected;
|
|
491
|
+
}
|
|
537
492
|
/**
|
|
538
493
|
* Checks if user can update the first selected folder.
|
|
539
494
|
* JSON ref: `app.selection.folder.canUpdate`
|
|
540
|
-
* @param {?} context
|
|
541
|
-
* @return {?}
|
|
542
495
|
*/
|
|
543
496
|
function canUpdateSelectedFolder(context) {
|
|
544
497
|
const { folder } = context.selection;
|
|
545
498
|
if (folder) {
|
|
546
499
|
return (
|
|
547
500
|
// workaround for Favorites Api
|
|
548
|
-
isFavorites(context) ||
|
|
549
|
-
context.permissions.check(folder.entry, ['update']));
|
|
501
|
+
isFavorites(context) || context.permissions.check(folder.entry, ['update']));
|
|
550
502
|
}
|
|
551
503
|
return false;
|
|
552
504
|
}
|
|
553
505
|
/**
|
|
554
506
|
* Checks if user has selected a **locked** file node.
|
|
555
507
|
* JSON ref: `app.selection.file.isLocked`
|
|
556
|
-
* @param {?} context
|
|
557
|
-
* @return {?}
|
|
558
508
|
*/
|
|
559
509
|
function hasLockedFiles(context) {
|
|
560
510
|
if (context && context.selection && context.selection.nodes) {
|
|
561
|
-
return context.selection.nodes.some(node => {
|
|
511
|
+
return context.selection.nodes.some((node) => {
|
|
562
512
|
if (!node.entry.isFile) {
|
|
563
513
|
return false;
|
|
564
514
|
}
|
|
565
|
-
return
|
|
566
|
-
(node.entry.properties &&
|
|
567
|
-
node.entry.properties['cm:lockType'] === 'READ_ONLY_LOCK'));
|
|
515
|
+
return node.entry.isLocked || (node.entry.properties && node.entry.properties['cm:lockType'] === 'READ_ONLY_LOCK');
|
|
568
516
|
});
|
|
569
517
|
}
|
|
570
518
|
return false;
|
|
@@ -572,58 +520,38 @@ function hasLockedFiles(context) {
|
|
|
572
520
|
/**
|
|
573
521
|
* Checks if the selected file has **write** or **read-only** locks specified.
|
|
574
522
|
* JSON ref: `app.selection.file.isLocked`
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
context.selection.file.entry
|
|
583
|
-
context.selection.file.entry.properties &&
|
|
584
|
-
(context.selection.file.entry.properties['cm:lockType'] === 'WRITE_LOCK' ||
|
|
585
|
-
context.selection.file.entry.properties['cm:lockType'] ===
|
|
586
|
-
'READ_ONLY_LOCK'));
|
|
587
|
-
}
|
|
523
|
+
*/
|
|
524
|
+
const isWriteLocked = (context) => !!(context &&
|
|
525
|
+
context.selection &&
|
|
526
|
+
context.selection.file &&
|
|
527
|
+
context.selection.file.entry &&
|
|
528
|
+
context.selection.file.entry.properties &&
|
|
529
|
+
(context.selection.file.entry.properties['cm:lockType'] === 'WRITE_LOCK' ||
|
|
530
|
+
context.selection.file.entry.properties['cm:lockType'] === 'READ_ONLY_LOCK'));
|
|
588
531
|
/**
|
|
589
532
|
* Checks if the selected file has **write** or **read-only** locks specified,
|
|
590
533
|
* and that current user is the owner of the lock.
|
|
591
534
|
* JSON ref: `app.selection.file.isLockOwner`
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
return (isWriteLocked(context) &&
|
|
597
|
-
(context.selection.file.entry.properties['cm:lockOwner'] &&
|
|
598
|
-
context.selection.file.entry.properties['cm:lockOwner'].id ===
|
|
599
|
-
context.profile.id));
|
|
600
|
-
}
|
|
535
|
+
*/
|
|
536
|
+
const isUserWriteLockOwner = (context) => isWriteLocked(context) &&
|
|
537
|
+
context.selection.file?.entry.properties['cm:lockOwner'] &&
|
|
538
|
+
context.selection.file?.entry.properties['cm:lockOwner'].id === context.profile.id;
|
|
601
539
|
/**
|
|
602
540
|
* Checks if user can lock selected file.
|
|
603
541
|
* JSON ref: `app.selection.file.canLock`
|
|
604
|
-
* @param {?} context
|
|
605
|
-
* @return {?}
|
|
606
542
|
*/
|
|
607
|
-
|
|
608
|
-
return !isWriteLocked(context) && canUpdateSelectedNode(context);
|
|
609
|
-
}
|
|
543
|
+
const canLockFile = (context) => !isWriteLocked(context) && canUpdateSelectedNode(context);
|
|
610
544
|
/**
|
|
611
545
|
* Checks if user can unlock selected file.
|
|
612
546
|
* JSON ref: `app.selection.file.canUnlock`
|
|
613
|
-
* @param {?} context
|
|
614
|
-
* @return {?}
|
|
615
547
|
*/
|
|
616
548
|
function canUnlockFile(context) {
|
|
617
549
|
const { file } = context.selection;
|
|
618
|
-
return
|
|
619
|
-
(context.permissions.check(file.entry, ['delete']) ||
|
|
620
|
-
isUserWriteLockOwner(context)));
|
|
550
|
+
return isWriteLocked(context) && (context.permissions.check(file?.entry, ['delete']) || isUserWriteLockOwner(context));
|
|
621
551
|
}
|
|
622
552
|
/**
|
|
623
553
|
* Checks if user can upload a new version of the file.
|
|
624
554
|
* JSON ref: `app.selection.file.canUploadVersion`
|
|
625
|
-
* @param {?} context
|
|
626
|
-
* @return {?}
|
|
627
555
|
*/
|
|
628
556
|
function canUploadVersion(context) {
|
|
629
557
|
if (isFavorites(context) || isSharedFiles(context)) {
|
|
@@ -632,152 +560,160 @@ function canUploadVersion(context) {
|
|
|
632
560
|
return [
|
|
633
561
|
hasFileSelected(context),
|
|
634
562
|
isNotTrashcan(context),
|
|
635
|
-
isWriteLocked(context)
|
|
636
|
-
? isUserWriteLockOwner(context)
|
|
637
|
-
: canUpdateSelectedNode(context)
|
|
563
|
+
isWriteLocked(context) ? isUserWriteLockOwner(context) : canUpdateSelectedNode(context)
|
|
638
564
|
].every(Boolean);
|
|
639
565
|
}
|
|
640
566
|
/**
|
|
641
567
|
* Checks if user has trashcan item selected.
|
|
642
568
|
* JSON ref: `isTrashcanItemSelected`
|
|
643
|
-
*
|
|
644
|
-
* @
|
|
569
|
+
*
|
|
570
|
+
* @param context Rule execution context
|
|
645
571
|
*/
|
|
646
|
-
|
|
647
|
-
return [isTrashcan(context), hasSelection(context)].every(Boolean);
|
|
648
|
-
}
|
|
572
|
+
const isTrashcanItemSelected = (context) => [isTrashcan(context), hasSelection(context)].every(Boolean);
|
|
649
573
|
/**
|
|
650
574
|
* Checks if user can view the file.
|
|
651
575
|
* JSON ref: `canViewFile`
|
|
652
|
-
*
|
|
653
|
-
* @
|
|
576
|
+
*
|
|
577
|
+
* @param context Rule execution context
|
|
654
578
|
*/
|
|
655
|
-
|
|
656
|
-
return [hasFileSelected(context), isNotTrashcan(context)].every(Boolean);
|
|
657
|
-
}
|
|
579
|
+
const canViewFile = (context) => [hasFileSelected(context), isNotTrashcan(context)].every(Boolean);
|
|
658
580
|
/**
|
|
659
581
|
* Checks if user can **Leave** selected library.
|
|
660
582
|
* JSON ref: `canLeaveLibrary`
|
|
661
|
-
*
|
|
662
|
-
* @
|
|
583
|
+
*
|
|
584
|
+
* @param context Rule execution context
|
|
663
585
|
*/
|
|
664
|
-
|
|
665
|
-
return [hasLibrarySelected(context), hasLibraryRole(context)].every(Boolean);
|
|
666
|
-
}
|
|
586
|
+
const canLeaveLibrary = (context) => [hasLibrarySelected(context), hasLibraryRole(context)].every(Boolean);
|
|
667
587
|
/**
|
|
668
588
|
* Checks if user can toggle shared link mode.
|
|
669
589
|
* JSON ref: `canToggleSharedLink`
|
|
670
|
-
*
|
|
671
|
-
* @
|
|
590
|
+
*
|
|
591
|
+
* @param context Rule execution context
|
|
672
592
|
*/
|
|
673
|
-
|
|
674
|
-
return [
|
|
675
|
-
hasFileSelected(context),
|
|
676
|
-
[canShareFile(context), isShared(context)].some(Boolean)
|
|
677
|
-
].every(Boolean);
|
|
678
|
-
}
|
|
593
|
+
const canToggleSharedLink = (context) => [hasFileSelected(context), [canShareFile(context), isShared(context)].some(Boolean)].every(Boolean);
|
|
679
594
|
/**
|
|
680
595
|
* Checks if user can show **Info Drawer** for the selected node.
|
|
681
596
|
* JSON ref: `canShowInfoDrawer`
|
|
682
|
-
*
|
|
683
|
-
* @
|
|
597
|
+
*
|
|
598
|
+
* @param context Rule execution context
|
|
684
599
|
*/
|
|
685
|
-
|
|
686
|
-
return [
|
|
687
|
-
hasSelection(context),
|
|
688
|
-
isNotLibraries(context),
|
|
689
|
-
isNotTrashcan(context)
|
|
690
|
-
].every(Boolean);
|
|
691
|
-
}
|
|
600
|
+
const canShowInfoDrawer = (context) => [hasSelection(context), isNotLibraries(context), isNotTrashcan(context)].every(Boolean);
|
|
692
601
|
/**
|
|
693
602
|
* Checks if user can manage file versions for the selected node.
|
|
694
603
|
* JSON ref: `canManageFileVersions`
|
|
695
|
-
*
|
|
696
|
-
* @
|
|
604
|
+
*
|
|
605
|
+
* @param context Rule execution context
|
|
697
606
|
*/
|
|
698
|
-
|
|
699
|
-
|
|
700
|
-
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
|
|
607
|
+
const canManageFileVersions = (context) => [hasFileSelected(context), isNotTrashcan(context), !hasLockedFiles(context)].every(Boolean);
|
|
608
|
+
/**
|
|
609
|
+
* Checks if user can edit aspects for the selected node.
|
|
610
|
+
* JSON ref: `canEditAspects`
|
|
611
|
+
*
|
|
612
|
+
* @param context Rule execution context
|
|
613
|
+
*/
|
|
614
|
+
const canEditAspects = (context) => [
|
|
615
|
+
!isMultiselection(context),
|
|
616
|
+
canUpdateSelectedNode(context),
|
|
617
|
+
!isWriteLocked(context),
|
|
618
|
+
isNotTrashcan(context),
|
|
619
|
+
isMajorVersionAvailable(context, '7')
|
|
620
|
+
].every(Boolean);
|
|
705
621
|
/**
|
|
706
622
|
* Checks if user can manage permissions for the selected node.
|
|
707
623
|
* JSON ref: `canManagePermissions`
|
|
708
|
-
*
|
|
709
|
-
* @
|
|
624
|
+
*
|
|
625
|
+
* @param context Rule execution context
|
|
710
626
|
*/
|
|
711
|
-
|
|
712
|
-
return [
|
|
713
|
-
canUpdateSelectedNode(context),
|
|
714
|
-
isNotTrashcan(context)
|
|
715
|
-
].every(Boolean);
|
|
716
|
-
}
|
|
627
|
+
const canManagePermissions = (context) => [canUpdateSelectedNode(context), isNotTrashcan(context)].every(Boolean);
|
|
717
628
|
/**
|
|
718
629
|
* Checks if user can toggle **Edit Offline** mode for selected node.
|
|
719
630
|
* JSON ref: `canToggleEditOffline`
|
|
720
|
-
*
|
|
721
|
-
* @
|
|
631
|
+
*
|
|
632
|
+
* @param context Rule execution context
|
|
722
633
|
*/
|
|
723
|
-
|
|
724
|
-
return [
|
|
725
|
-
hasFileSelected(context),
|
|
726
|
-
isNotTrashcan(context),
|
|
727
|
-
canLockFile(context) || canUnlockFile(context)
|
|
728
|
-
].every(Boolean);
|
|
729
|
-
}
|
|
634
|
+
const canToggleEditOffline = (context) => [hasFileSelected(context), isNotTrashcan(context), canLockFile(context) || canUnlockFile(context)].every(Boolean);
|
|
730
635
|
/**
|
|
731
636
|
* @deprecated Uses workarounds for for recent files and search api issues.
|
|
732
637
|
* Checks if user can toggle **Favorite** state for a node.
|
|
733
|
-
* @param
|
|
734
|
-
* @return {?}
|
|
638
|
+
* @param context Rule execution context
|
|
735
639
|
*/
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
|
|
739
|
-
|
|
740
|
-
isRecentFiles(context),
|
|
741
|
-
isSharedFiles(context),
|
|
742
|
-
isSearchResults(context),
|
|
743
|
-
isFavorites(context)
|
|
744
|
-
].some(Boolean)
|
|
745
|
-
].every(Boolean);
|
|
746
|
-
}
|
|
747
|
-
/**
|
|
748
|
-
* Checks if application should render language picker menu.
|
|
749
|
-
* JSON ref: `canShowLanguagePicker`
|
|
750
|
-
* @param {?} context Rule execution context
|
|
751
|
-
* @return {?}
|
|
752
|
-
*/
|
|
753
|
-
function canShowLanguagePicker(context) {
|
|
754
|
-
return context.languagePicker;
|
|
755
|
-
}
|
|
640
|
+
const canToggleFavorite = (context) => [
|
|
641
|
+
[canAddFavorite(context), canRemoveFavorite(context)].some(Boolean),
|
|
642
|
+
[isRecentFiles(context), isSharedFiles(context), isSearchResults(context), isFavorites(context)].some(Boolean)
|
|
643
|
+
].every(Boolean);
|
|
756
644
|
/**
|
|
757
645
|
* Checks if application should render logout option.
|
|
758
646
|
* JSON ref: `canShowLogout`
|
|
759
|
-
*
|
|
760
|
-
* @
|
|
647
|
+
*
|
|
648
|
+
* @param context Rule execution context
|
|
761
649
|
*/
|
|
762
|
-
|
|
763
|
-
return !context.withCredentials;
|
|
764
|
-
}
|
|
650
|
+
const canShowLogout = (context) => !context.withCredentials;
|
|
765
651
|
/**
|
|
766
652
|
* Checks if user is library manager
|
|
767
653
|
* JSON ref: `isLibraryManager`
|
|
768
|
-
*
|
|
769
|
-
* @
|
|
654
|
+
*
|
|
655
|
+
* @param context Rule execution context
|
|
770
656
|
*/
|
|
771
|
-
|
|
772
|
-
return (hasLibrarySelected(context) &&
|
|
773
|
-
context.selection.library.entry &&
|
|
774
|
-
context.selection.library.entry.role === 'SiteManager');
|
|
775
|
-
}
|
|
776
|
-
|
|
657
|
+
const isLibraryManager = (context) => hasLibrarySelected(context) && context.selection.library?.entry.role === 'SiteManager';
|
|
777
658
|
/**
|
|
778
|
-
*
|
|
779
|
-
*
|
|
659
|
+
* Checks if the preview button for search results can be showed
|
|
660
|
+
* JSON ref: `canInfoPreview`
|
|
661
|
+
*
|
|
662
|
+
* @param context Rule execution context
|
|
663
|
+
*/
|
|
664
|
+
const canInfoPreview = (context) => {
|
|
665
|
+
const isSearchResult = isSearchResults(context);
|
|
666
|
+
const isNotMultiselect = !isMultiselection(context);
|
|
667
|
+
const isFileSelected = !hasFolderSelected(context);
|
|
668
|
+
const isPreview$1 = !isPreview(context);
|
|
669
|
+
return isSearchResult && isNotMultiselect && isFileSelected && isPreview$1;
|
|
670
|
+
};
|
|
671
|
+
const showInfoSelectionButton = (context) => isSearchResults(context) && !isPreview(context);
|
|
672
|
+
/**
|
|
673
|
+
* Checks if the file can be opened with MS Office
|
|
674
|
+
* JSON ref: `aos.canOpenWithOffice`
|
|
675
|
+
*
|
|
676
|
+
* @param context Rule execution context
|
|
780
677
|
*/
|
|
678
|
+
function canOpenWithOffice(context) {
|
|
679
|
+
if (context.navigation && context.navigation.url && context.navigation.url.startsWith('/trashcan')) {
|
|
680
|
+
return false;
|
|
681
|
+
}
|
|
682
|
+
if (!context || !context.selection) {
|
|
683
|
+
return false;
|
|
684
|
+
}
|
|
685
|
+
const { file } = context.selection;
|
|
686
|
+
if (!file || !file.entry) {
|
|
687
|
+
return false;
|
|
688
|
+
}
|
|
689
|
+
const extension = getFileExtension(file.entry.name);
|
|
690
|
+
if (!extension || !supportedExtensions[extension]) {
|
|
691
|
+
return false;
|
|
692
|
+
}
|
|
693
|
+
if (!file.entry.properties) {
|
|
694
|
+
return false;
|
|
695
|
+
}
|
|
696
|
+
if (file.entry.isLocked) {
|
|
697
|
+
return false;
|
|
698
|
+
}
|
|
699
|
+
if (file.entry.properties['cm:lockType'] === 'WRITE_LOCK' || file.entry.properties['cm:lockType'] === 'READ_ONLY_LOCK') {
|
|
700
|
+
return false;
|
|
701
|
+
}
|
|
702
|
+
const lockOwner = file.entry.properties['cm:lockOwner'];
|
|
703
|
+
if (lockOwner && lockOwner.id !== context.profile.id) {
|
|
704
|
+
return false;
|
|
705
|
+
}
|
|
706
|
+
// workaround for Shared files
|
|
707
|
+
if (context.navigation && context.navigation.url && context.navigation.url.startsWith('/shared')) {
|
|
708
|
+
if (file.entry.hasOwnProperty('allowableOperationsOnTarget')) {
|
|
709
|
+
return context.permissions.check(file, ['update'], {
|
|
710
|
+
target: 'allowableOperationsOnTarget'
|
|
711
|
+
});
|
|
712
|
+
}
|
|
713
|
+
}
|
|
714
|
+
return context.permissions.check(file, ['update']);
|
|
715
|
+
}
|
|
716
|
+
|
|
781
717
|
/*!
|
|
782
718
|
* @license
|
|
783
719
|
* Alfresco Example Content Application
|
|
@@ -802,26 +738,10 @@ function isLibraryManager(context) {
|
|
|
802
738
|
* You should have received a copy of the GNU Lesser General Public License
|
|
803
739
|
* along with Alfresco. If not, see <http://www.gnu.org/licenses/>.
|
|
804
740
|
*/
|
|
805
|
-
/**
|
|
806
|
-
* Checks if user is admin.
|
|
807
|
-
* JSON ref: `user.isAdmin`
|
|
808
|
-
* @param {?} context
|
|
809
|
-
* @return {?}
|
|
810
|
-
*/
|
|
811
|
-
function isAdmin(context) {
|
|
812
|
-
return context.profile.isAdmin;
|
|
813
|
-
}
|
|
814
741
|
|
|
815
742
|
/**
|
|
816
|
-
*
|
|
817
|
-
* @suppress {checkTypes,extraRequire,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
|
|
743
|
+
* Generated bundle index. Do not edit.
|
|
818
744
|
*/
|
|
819
745
|
|
|
820
|
-
|
|
821
|
-
|
|
822
|
-
* @suppress {checkTypes,extraRequire,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
|
|
823
|
-
*/
|
|
824
|
-
|
|
825
|
-
export { canCopyNode, canAddFavorite, canRemoveFavorite, canShareFile, canToggleJoinLibrary, canEditFolder, isShared, canDeleteSelection, canUnshareNodes, hasSelection, canCreateFolder, canUpload, canDownloadSelection, hasFolderSelected, hasLibrarySelected, isPrivateLibrary, hasLibraryRole, hasNoLibraryRole, hasFileSelected, canUpdateSelectedNode, canUpdateSelectedFolder, hasLockedFiles, isWriteLocked, isUserWriteLockOwner, canLockFile, canUnlockFile, canUploadVersion, isTrashcanItemSelected, canViewFile, canLeaveLibrary, canToggleSharedLink, canShowInfoDrawer, canManageFileVersions, canManagePermissions, canToggleEditOffline, canToggleFavorite, canShowLanguagePicker, canShowLogout, isLibraryManager, isPreview, isFavorites, isNotFavorites, isSharedFiles, isNotSharedFiles, isTrashcan, isNotTrashcan, isPersonalFiles, isLibraryFiles, isLibraries, isNotLibraries, isRecentFiles, isNotRecentFiles, isSearchResults, isNotSearchResults, isSharedPreview, isFavoritesPreview, isSharedFileViewer, hasQuickShareEnabled, isAdmin };
|
|
826
|
-
|
|
827
|
-
//# sourceMappingURL=alfresco-aca-shared-rules.js.map
|
|
746
|
+
export { canAddFavorite, canCopyNode, canCreateFolder, canDeleteSelection, canDownloadSelection, canEditAspects, canEditFolder, canInfoPreview, canLeaveLibrary, canLockFile, canManageFileVersions, canManagePermissions, canOpenWithOffice, canRemoveFavorite, canShareFile, canShowInfoDrawer, canShowLogout, canToggleEditOffline, canToggleFavorite, canToggleJoinLibrary, canToggleSharedLink, canUnlockFile, canUnshareNodes, canUpdateSelectedFolder, canUpdateSelectedNode, canUpload, canUploadVersion, canViewFile, getFileExtension, hasFileSelected, hasFolderSelected, hasLibraryRole, hasLibrarySelected, hasLockedFiles, hasNoLibraryRole, hasQuickShareEnabled, hasSelection, isAdmin, isContentServiceEnabled, isFavorites, isFavoritesPreview, isLibraries, isLibraryFiles, isLibraryManager, isMajorVersionAvailable, isMultiselection, isNotFavorites, isNotLibraries, isNotRecentFiles, isNotSearchResults, isNotSharedFiles, isNotTrashcan, isPersonalFiles, isPreview, isPrivateLibrary, isRecentFiles, isSearchResults, isShared, isSharedFileViewer, isSharedFiles, isSharedPreview, isTrashcan, isTrashcanItemSelected, isUserWriteLockOwner, isWriteLocked, showInfoSelectionButton, supportedExtensions };
|
|
747
|
+
//# sourceMappingURL=alfresco-aca-shared-rules.mjs.map
|