@alfresco/aca-shared 5.1.1 → 5.2.0
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/esm2022/lib/components/document-base-page/document-base-page.component.mjs +226 -0
- package/esm2022/lib/components/generic-error/generic-error.component.mjs +42 -0
- package/esm2022/lib/components/info-drawer/info-drawer.component.mjs +141 -0
- package/esm2022/lib/components/locked-by/locked-by.component.mjs +57 -0
- package/esm2022/lib/components/open-in-app/open-in-app.component.mjs +73 -0
- package/esm2022/lib/components/page-layout/page-layout-content.component.mjs +49 -0
- package/esm2022/lib/components/page-layout/page-layout-error.component.mjs +43 -0
- package/esm2022/lib/components/page-layout/page-layout-header.component.mjs +43 -0
- package/esm2022/lib/components/page-layout/page-layout.component.mjs +64 -0
- package/esm2022/lib/components/page-layout/page-layout.module.mjs +43 -0
- package/esm2022/lib/components/toolbar/toolbar-action/toolbar-action.component.mjs +63 -0
- package/esm2022/lib/components/toolbar/toolbar-button/toolbar-button.component.mjs +79 -0
- package/esm2022/lib/components/toolbar/toolbar-menu/toolbar-menu.component.mjs +92 -0
- package/esm2022/lib/components/toolbar/toolbar-menu-item/toolbar-menu-item.component.mjs +76 -0
- package/esm2022/lib/components/toolbar/toolbar.component.mjs +46 -0
- package/esm2022/lib/deprecated/shared-toolbar.module.mjs +44 -0
- package/esm2022/lib/deprecated/shared.module.mjs +45 -0
- package/esm2022/lib/directives/contextmenu/contextmenu.directive.mjs +114 -0
- package/esm2022/lib/directives/pagination.directive.mjs +59 -0
- package/esm2022/lib/services/aca-mobile-app-switcher.service.mjs +130 -0
- package/esm2022/lib/services/app-hook.service.mjs +78 -0
- package/esm2022/lib/services/app-settings.service.mjs +157 -0
- package/esm2022/lib/services/app.extension.service.mjs +481 -0
- package/esm2022/lib/services/app.service.mjs +239 -0
- package/esm2022/lib/services/auto-download.service.mjs +59 -0
- package/esm2022/lib/services/content-api.service.mjs +281 -0
- package/esm2022/lib/services/navigation-history.service.mjs +55 -0
- package/esm2022/lib/services/node-permission.service.mjs +88 -0
- package/esm2022/lib/services/router.extension.service.mjs +108 -0
- package/esm2022/lib/services/user-profile.service.mjs +76 -0
- package/esm2022/lib/testing/lib-testing-module.mjs +163 -0
- package/esm2022/public-api.mjs +62 -0
- package/esm2022/store/actions/app.actions.mjs +116 -0
- package/esm2022/store/actions/context-menu-action-types.mjs +29 -0
- package/esm2022/store/actions/contextmenu.actions.mjs +41 -0
- package/esm2022/store/actions/library.actions.mjs +67 -0
- package/esm2022/store/actions/metadata-aspect.actions.mjs +32 -0
- package/esm2022/store/actions/node.actions.mjs +217 -0
- package/esm2022/store/actions/router.actions.mjs +56 -0
- package/esm2022/store/actions/search-ai.actions.mjs +45 -0
- package/esm2022/store/actions/search.actions.mjs +41 -0
- package/esm2022/store/actions/snackbar.actions.mjs +68 -0
- package/esm2022/store/actions/template.actions.mjs +45 -0
- package/esm2022/store/actions/upload.actions.mjs +53 -0
- package/esm2022/store/actions/viewer.actions.mjs +93 -0
- package/esm2022/store/effects/router.effects.mjs +110 -0
- package/esm2022/store/effects/snackbar.effects.mjs +80 -0
- package/{fesm2020 → fesm2022}/alfresco-aca-shared-store.mjs +219 -142
- package/fesm2022/alfresco-aca-shared-store.mjs.map +1 -0
- package/{fesm2020 → fesm2022}/alfresco-aca-shared.mjs +466 -301
- package/fesm2022/alfresco-aca-shared.mjs.map +1 -0
- package/lib/components/document-base-page/document-base-page.component.d.ts +7 -3
- package/lib/components/generic-error/generic-error.component.d.ts +1 -1
- package/lib/components/info-drawer/info-drawer.component.d.ts +1 -1
- package/lib/components/locked-by/locked-by.component.d.ts +1 -1
- package/lib/components/page-layout/page-layout-content.component.d.ts +1 -1
- package/lib/components/page-layout/page-layout.component.d.ts +1 -1
- package/lib/components/toolbar/toolbar-action/toolbar-action.component.d.ts +1 -1
- package/lib/components/toolbar/toolbar-button/toolbar-button.component.d.ts +1 -1
- package/lib/components/toolbar/toolbar-menu/toolbar-menu.component.d.ts +1 -1
- package/lib/components/toolbar/toolbar-menu-item/toolbar-menu-item.component.d.ts +1 -1
- package/lib/components/toolbar/toolbar.component.d.ts +1 -1
- package/lib/directives/contextmenu/contextmenu.directive.d.ts +3 -1
- package/lib/services/app-hook.service.d.ts +6 -6
- package/lib/services/app-settings.service.d.ts +12 -0
- package/lib/services/app.service.d.ts +1 -1
- package/lib/services/navigation-history.service.d.ts +13 -0
- package/lib/services/node-permission.service.d.ts +1 -1
- package/package.json +15 -25
- package/public-api.d.ts +1 -0
- package/store/actions/context-menu-action-types.d.ts +2 -1
- package/store/actions/contextmenu.actions.d.ts +7 -0
- package/store/actions/search-ai.actions.d.ts +2 -1
- package/store/effects/router.effects.d.ts +1 -5
- package/store/effects/snackbar.effects.d.ts +0 -29
- package/esm2020/lib/components/document-base-page/document-base-page.component.mjs +0 -206
- package/esm2020/lib/components/generic-error/generic-error.component.mjs +0 -43
- package/esm2020/lib/components/info-drawer/info-drawer.component.mjs +0 -132
- package/esm2020/lib/components/locked-by/locked-by.component.mjs +0 -54
- package/esm2020/lib/components/open-in-app/open-in-app.component.mjs +0 -68
- package/esm2020/lib/components/page-layout/page-layout-content.component.mjs +0 -50
- package/esm2020/lib/components/page-layout/page-layout-error.component.mjs +0 -42
- package/esm2020/lib/components/page-layout/page-layout-header.component.mjs +0 -42
- package/esm2020/lib/components/page-layout/page-layout.component.mjs +0 -61
- package/esm2020/lib/components/page-layout/page-layout.module.mjs +0 -42
- package/esm2020/lib/components/toolbar/toolbar-action/toolbar-action.component.mjs +0 -58
- package/esm2020/lib/components/toolbar/toolbar-button/toolbar-button.component.mjs +0 -74
- package/esm2020/lib/components/toolbar/toolbar-menu/toolbar-menu.component.mjs +0 -87
- package/esm2020/lib/components/toolbar/toolbar-menu-item/toolbar-menu-item.component.mjs +0 -71
- package/esm2020/lib/components/toolbar/toolbar.component.mjs +0 -44
- package/esm2020/lib/deprecated/shared-toolbar.module.mjs +0 -43
- package/esm2020/lib/deprecated/shared.module.mjs +0 -44
- package/esm2020/lib/directives/contextmenu/contextmenu.directive.mjs +0 -104
- package/esm2020/lib/directives/pagination.directive.mjs +0 -55
- package/esm2020/lib/services/aca-mobile-app-switcher.service.mjs +0 -129
- package/esm2020/lib/services/app-hook.service.mjs +0 -79
- package/esm2020/lib/services/app-settings.service.mjs +0 -140
- package/esm2020/lib/services/app.extension.service.mjs +0 -462
- package/esm2020/lib/services/app.service.mjs +0 -221
- package/esm2020/lib/services/auto-download.service.mjs +0 -60
- package/esm2020/lib/services/content-api.service.mjs +0 -268
- package/esm2020/lib/services/node-permission.service.mjs +0 -89
- package/esm2020/lib/services/router.extension.service.mjs +0 -105
- package/esm2020/lib/services/user-profile.service.mjs +0 -77
- package/esm2020/lib/testing/lib-testing-module.mjs +0 -161
- package/esm2020/public-api.mjs +0 -61
- package/esm2020/store/actions/app.actions.mjs +0 -108
- package/esm2020/store/actions/context-menu-action-types.mjs +0 -28
- package/esm2020/store/actions/contextmenu.actions.mjs +0 -31
- package/esm2020/store/actions/library.actions.mjs +0 -63
- package/esm2020/store/actions/metadata-aspect.actions.mjs +0 -31
- package/esm2020/store/actions/node.actions.mjs +0 -188
- package/esm2020/store/actions/router.actions.mjs +0 -54
- package/esm2020/store/actions/search-ai.actions.mjs +0 -41
- package/esm2020/store/actions/search.actions.mjs +0 -41
- package/esm2020/store/actions/snackbar.actions.mjs +0 -57
- package/esm2020/store/actions/template.actions.mjs +0 -47
- package/esm2020/store/actions/upload.actions.mjs +0 -49
- package/esm2020/store/actions/viewer.actions.mjs +0 -81
- package/esm2020/store/effects/router.effects.mjs +0 -114
- package/esm2020/store/effects/snackbar.effects.mjs +0 -85
- package/fesm2015/alfresco-aca-shared-rules.mjs +0 -795
- package/fesm2015/alfresco-aca-shared-rules.mjs.map +0 -1
- package/fesm2015/alfresco-aca-shared-store.mjs +0 -1278
- package/fesm2015/alfresco-aca-shared-store.mjs.map +0 -1
- package/fesm2015/alfresco-aca-shared.mjs +0 -3278
- package/fesm2015/alfresco-aca-shared.mjs.map +0 -1
- package/fesm2020/alfresco-aca-shared-store.mjs.map +0 -1
- package/fesm2020/alfresco-aca-shared.mjs.map +0 -1
- /package/{esm2020 → esm2022}/alfresco-aca-shared.mjs +0 -0
- /package/{esm2020 → esm2022}/lib/adf-extensions/extensions-data-loader.guard.mjs +0 -0
- /package/{esm2020 → esm2022}/lib/components/document-base-page/document-base-page.service.mjs +0 -0
- /package/{esm2020 → esm2022}/lib/constants/index.mjs +0 -0
- /package/{esm2020 → esm2022}/lib/constants/mime-types.mjs +0 -0
- /package/{esm2020 → esm2022}/lib/models/types.mjs +0 -0
- /package/{esm2020 → esm2022}/lib/models/viewer.rules.mjs +0 -0
- /package/{esm2020 → esm2022}/lib/routing/plugin-enabled.guard.mjs +0 -0
- /package/{esm2020 → esm2022}/lib/routing/shared.guard.mjs +0 -0
- /package/{esm2020 → esm2022}/lib/utils/node.utils.mjs +0 -0
- /package/{esm2020 → esm2022}/rules/alfresco-aca-shared-rules.mjs +0 -0
- /package/{esm2020 → esm2022}/rules/app.rules.mjs +0 -0
- /package/{esm2020 → esm2022}/rules/navigation.rules.mjs +0 -0
- /package/{esm2020 → esm2022}/rules/public-api.mjs +0 -0
- /package/{esm2020 → esm2022}/rules/repository.rules.mjs +0 -0
- /package/{esm2020 → esm2022}/rules/user.rules.mjs +0 -0
- /package/{esm2020 → esm2022}/store/actions/app-action-types.mjs +0 -0
- /package/{esm2020 → esm2022}/store/actions/router-action-types.mjs +0 -0
- /package/{esm2020 → esm2022}/store/actions/template-action-types.mjs +0 -0
- /package/{esm2020 → esm2022}/store/alfresco-aca-shared-store.mjs +0 -0
- /package/{esm2020 → esm2022}/store/models/ai-search-by-term-payload.mjs +0 -0
- /package/{esm2020 → esm2022}/store/models/delete-status.model.mjs +0 -0
- /package/{esm2020 → esm2022}/store/models/deleted-node-info.model.mjs +0 -0
- /package/{esm2020 → esm2022}/store/models/modal-configuration.mjs +0 -0
- /package/{esm2020 → esm2022}/store/models/node-info.model.mjs +0 -0
- /package/{esm2020 → esm2022}/store/models/search-option.model.mjs +0 -0
- /package/{esm2020 → esm2022}/store/public-api.mjs +0 -0
- /package/{esm2020 → esm2022}/store/selectors/app.selectors.mjs +0 -0
- /package/{esm2020 → esm2022}/store/states/app.state.mjs +0 -0
- /package/{fesm2020 → fesm2022}/alfresco-aca-shared-rules.mjs +0 -0
- /package/{fesm2020 → fesm2022}/alfresco-aca-shared-rules.mjs.map +0 -0
|
@@ -1,3278 +0,0 @@
|
|
|
1
|
-
import * as i0 from '@angular/core';
|
|
2
|
-
import { InjectionToken, inject, Component, ViewEncapsulation, ChangeDetectionStrategy, Input, HostBinding, Injectable, Inject, NgModule, ViewChild, QueryList, ViewChildren, HostListener, Directive } from '@angular/core';
|
|
3
|
-
import { of, forkJoin, from, BehaviorSubject, Subject } from 'rxjs';
|
|
4
|
-
import { map, tap, catchError, filter, takeUntil, debounceTime } from 'rxjs/operators';
|
|
5
|
-
import * as i2 from '@angular/common';
|
|
6
|
-
import { CommonModule } from '@angular/common';
|
|
7
|
-
import * as i3$2 from '@ngx-translate/core';
|
|
8
|
-
import { TranslateModule, TranslateLoader } from '@ngx-translate/core';
|
|
9
|
-
import * as i4$1 from '@angular/material/button';
|
|
10
|
-
import { MatButtonModule } from '@angular/material/button';
|
|
11
|
-
import * as i5 from '@angular/material/icon';
|
|
12
|
-
import { MatIconModule } from '@angular/material/icon';
|
|
13
|
-
import { __awaiter } from 'tslib';
|
|
14
|
-
import * as i1 from '@alfresco/adf-core';
|
|
15
|
-
import { AppConfigService, CloseButtonPosition, NotificationService, IconComponent, IconModule, InfoDrawerModule, ShowHeaderMode, TranslationService, TranslationMock, TranslateLoaderService } from '@alfresco/adf-core';
|
|
16
|
-
import * as i3 from '@angular/router';
|
|
17
|
-
import { ActivationEnd, NavigationStart, Router } from '@angular/router';
|
|
18
|
-
import { SetCurrentUrlAction, ResetSelectionAction, SetRepositoryInfoAction, SetUserProfileAction, getRuleContext, infoDrawerPreview, SetInfoDrawerStateAction, ToggleInfoDrawerAction, isInfoDrawerOpened, getAppSelection, getCurrentFolder, SetSelectedNodesAction, ViewNodeAction, ContextMenu, isQuickShareEnabled } from '@alfresco/aca-shared/store';
|
|
19
|
-
import * as i1$1 from '@angular/material/dialog';
|
|
20
|
-
import { MAT_DIALOG_DATA, MatDialogModule, MatDialog } from '@angular/material/dialog';
|
|
21
|
-
import * as i1$2 from '@ngrx/store';
|
|
22
|
-
import { Store, StoreModule } from '@ngrx/store';
|
|
23
|
-
import * as i4 from '@alfresco/adf-content-services';
|
|
24
|
-
import { AlfrescoApiService, GroupService, FileAutoDownloadComponent, DocumentListService, UploadService, SearchAiService, DocumentListComponent, AlfrescoApiServiceMock } from '@alfresco/adf-content-services';
|
|
25
|
-
import * as i3$1 from '@alfresco/adf-extensions';
|
|
26
|
-
import { sortByOrder, reduceEmptyMenus, mergeObjects, mergeArrays, ContentActionType, reduceSeparators, DynamicExtensionComponent, DynamicTabComponent } from '@alfresco/adf-extensions';
|
|
27
|
-
import { NodesApi, TrashcanApi, SharedlinksApi, DiscoveryApi, FavoritesApi, ContentApi, SitesApi, SearchApi, PeopleApi, VersionsApi, RepositoryInfo } from '@alfresco/js-api';
|
|
28
|
-
import * as i7 from '@angular/cdk/overlay';
|
|
29
|
-
import { OverlayModule } from '@angular/cdk/overlay';
|
|
30
|
-
import { A11yModule } from '@angular/cdk/a11y';
|
|
31
|
-
import * as i4$2 from '@angular/material/menu';
|
|
32
|
-
import { MatMenuItem, MatMenuModule, MatMenu } from '@angular/material/menu';
|
|
33
|
-
import * as i5$1 from '@angular/material/divider';
|
|
34
|
-
import { MatDividerModule } from '@angular/material/divider';
|
|
35
|
-
import * as i6 from '@angular/platform-browser';
|
|
36
|
-
import * as i2$1 from '@angular/material/toolbar';
|
|
37
|
-
import { MatToolbarModule } from '@angular/material/toolbar';
|
|
38
|
-
import * as i7$1 from '@angular/material/progress-bar';
|
|
39
|
-
import { MatProgressBarModule } from '@angular/material/progress-bar';
|
|
40
|
-
import { BreakpointObserver, Breakpoints } from '@angular/cdk/layout';
|
|
41
|
-
import { NoopAnimationsModule } from '@angular/platform-browser/animations';
|
|
42
|
-
import { HttpClientModule } from '@angular/common/http';
|
|
43
|
-
import { RouterTestingModule } from '@angular/router/testing';
|
|
44
|
-
import * as i2$2 from '@ngrx/effects';
|
|
45
|
-
import { EffectsModule } from '@ngrx/effects';
|
|
46
|
-
import { MatIconTestingModule } from '@angular/material/icon/testing';
|
|
47
|
-
|
|
48
|
-
/*!
|
|
49
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
50
|
-
*
|
|
51
|
-
* Alfresco Example Content Application
|
|
52
|
-
*
|
|
53
|
-
* This file is part of the Alfresco Example Content Application.
|
|
54
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
55
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
56
|
-
* provided under the following open source license terms:
|
|
57
|
-
*
|
|
58
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
59
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
60
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
61
|
-
* (at your option) any later version.
|
|
62
|
-
*
|
|
63
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
64
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
65
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
66
|
-
* GNU Lesser General Public License for more details.
|
|
67
|
-
*
|
|
68
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
69
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
70
|
-
*/
|
|
71
|
-
const DefaultExtensionLoaderFactory = () => [];
|
|
72
|
-
const EXTENSION_DATA_LOADERS = new InjectionToken('EXTENSION_DATA_LOADERS', {
|
|
73
|
-
providedIn: 'root',
|
|
74
|
-
factory: DefaultExtensionLoaderFactory
|
|
75
|
-
});
|
|
76
|
-
let invoked = false;
|
|
77
|
-
const ExtensionsDataLoaderGuard = (route) => {
|
|
78
|
-
const extensionDataLoaders = inject(EXTENSION_DATA_LOADERS);
|
|
79
|
-
if (!invoked) {
|
|
80
|
-
if (!extensionDataLoaders.length) {
|
|
81
|
-
invoked = true;
|
|
82
|
-
return of(true);
|
|
83
|
-
}
|
|
84
|
-
const dataLoaderCallbacks = extensionDataLoaders.map((callback) => callback(route));
|
|
85
|
-
// Undocumented forkJoin behaviour/bug:
|
|
86
|
-
// https://github.com/ReactiveX/rxjs/issues/3246
|
|
87
|
-
// So all callbacks need to emit before completion, otherwise forkJoin will short circuit
|
|
88
|
-
return forkJoin(...dataLoaderCallbacks).pipe(map(() => true), tap(() => (invoked = true)), catchError((e) => {
|
|
89
|
-
// eslint-disable-next-line no-console
|
|
90
|
-
console.error('Some of the extension data loader guards has been errored.');
|
|
91
|
-
// eslint-disable-next-line no-console
|
|
92
|
-
console.error(e);
|
|
93
|
-
return of(true);
|
|
94
|
-
}));
|
|
95
|
-
}
|
|
96
|
-
else {
|
|
97
|
-
return of(true);
|
|
98
|
-
}
|
|
99
|
-
};
|
|
100
|
-
const resetInvoked = () => {
|
|
101
|
-
invoked = false;
|
|
102
|
-
};
|
|
103
|
-
|
|
104
|
-
/*!
|
|
105
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
106
|
-
*
|
|
107
|
-
* Alfresco Example Content Application
|
|
108
|
-
*
|
|
109
|
-
* This file is part of the Alfresco Example Content Application.
|
|
110
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
111
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
112
|
-
* provided under the following open source license terms:
|
|
113
|
-
*
|
|
114
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
115
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
116
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
117
|
-
* (at your option) any later version.
|
|
118
|
-
*
|
|
119
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
120
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
121
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
122
|
-
* GNU Lesser General Public License for more details.
|
|
123
|
-
*
|
|
124
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
125
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
126
|
-
*/
|
|
127
|
-
// @deprecated Use `.aca-page-layout-content` CSS selector instead
|
|
128
|
-
class PageLayoutContentComponent {
|
|
129
|
-
constructor() {
|
|
130
|
-
this.scrollable = false;
|
|
131
|
-
}
|
|
132
|
-
}
|
|
133
|
-
PageLayoutContentComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: PageLayoutContentComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
134
|
-
PageLayoutContentComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: PageLayoutContentComponent, isStandalone: true, selector: "aca-page-layout-content", inputs: { scrollable: "scrollable" }, host: { properties: { "class.aca-scrollable": "this.scrollable" }, classAttribute: "aca-page-layout-content" }, ngImport: i0, template: `<ng-content></ng-content>`, isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
135
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: PageLayoutContentComponent, decorators: [{
|
|
136
|
-
type: Component,
|
|
137
|
-
args: [{
|
|
138
|
-
standalone: true,
|
|
139
|
-
selector: 'aca-page-layout-content',
|
|
140
|
-
template: `<ng-content></ng-content>`,
|
|
141
|
-
encapsulation: ViewEncapsulation.None,
|
|
142
|
-
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
143
|
-
host: { class: 'aca-page-layout-content' }
|
|
144
|
-
}]
|
|
145
|
-
}], propDecorators: { scrollable: [{
|
|
146
|
-
type: Input
|
|
147
|
-
}, {
|
|
148
|
-
type: HostBinding,
|
|
149
|
-
args: ['class.aca-scrollable']
|
|
150
|
-
}] } });
|
|
151
|
-
|
|
152
|
-
/*!
|
|
153
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
154
|
-
*
|
|
155
|
-
* Alfresco Example Content Application
|
|
156
|
-
*
|
|
157
|
-
* This file is part of the Alfresco Example Content Application.
|
|
158
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
159
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
160
|
-
* provided under the following open source license terms:
|
|
161
|
-
*
|
|
162
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
163
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
164
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
165
|
-
* (at your option) any later version.
|
|
166
|
-
*
|
|
167
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
168
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
169
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
170
|
-
* GNU Lesser General Public License for more details.
|
|
171
|
-
*
|
|
172
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
173
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
174
|
-
*/
|
|
175
|
-
// @deprecated Use `.aca-page-layout-error` selectors instead
|
|
176
|
-
class PageLayoutErrorComponent {
|
|
177
|
-
}
|
|
178
|
-
PageLayoutErrorComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: PageLayoutErrorComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
179
|
-
PageLayoutErrorComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: PageLayoutErrorComponent, isStandalone: true, selector: "aca-page-layout-error", host: { classAttribute: "aca-page-layout-error" }, ngImport: i0, template: `<ng-content></ng-content>`, isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
180
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: PageLayoutErrorComponent, decorators: [{
|
|
181
|
-
type: Component,
|
|
182
|
-
args: [{
|
|
183
|
-
standalone: true,
|
|
184
|
-
selector: 'aca-page-layout-error',
|
|
185
|
-
template: `<ng-content></ng-content>`,
|
|
186
|
-
encapsulation: ViewEncapsulation.None,
|
|
187
|
-
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
188
|
-
host: { class: 'aca-page-layout-error' }
|
|
189
|
-
}]
|
|
190
|
-
}] });
|
|
191
|
-
|
|
192
|
-
/*!
|
|
193
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
194
|
-
*
|
|
195
|
-
* Alfresco Example Content Application
|
|
196
|
-
*
|
|
197
|
-
* This file is part of the Alfresco Example Content Application.
|
|
198
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
199
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
200
|
-
* provided under the following open source license terms:
|
|
201
|
-
*
|
|
202
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
203
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
204
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
205
|
-
* (at your option) any later version.
|
|
206
|
-
*
|
|
207
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
208
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
209
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
210
|
-
* GNU Lesser General Public License for more details.
|
|
211
|
-
*
|
|
212
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
213
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
214
|
-
*/
|
|
215
|
-
// @deprecated Use `.aca-page-layout-header` CSS selector instead
|
|
216
|
-
class PageLayoutHeaderComponent {
|
|
217
|
-
}
|
|
218
|
-
PageLayoutHeaderComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: PageLayoutHeaderComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
219
|
-
PageLayoutHeaderComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: PageLayoutHeaderComponent, isStandalone: true, selector: "aca-page-layout-header", host: { classAttribute: "aca-page-layout-header" }, ngImport: i0, template: '<ng-content></ng-content>', isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
220
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: PageLayoutHeaderComponent, decorators: [{
|
|
221
|
-
type: Component,
|
|
222
|
-
args: [{
|
|
223
|
-
standalone: true,
|
|
224
|
-
selector: 'aca-page-layout-header',
|
|
225
|
-
template: '<ng-content></ng-content>',
|
|
226
|
-
encapsulation: ViewEncapsulation.None,
|
|
227
|
-
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
228
|
-
host: { class: 'aca-page-layout-header' }
|
|
229
|
-
}]
|
|
230
|
-
}] });
|
|
231
|
-
|
|
232
|
-
/*!
|
|
233
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
234
|
-
*
|
|
235
|
-
* Alfresco Example Content Application
|
|
236
|
-
*
|
|
237
|
-
* This file is part of the Alfresco Example Content Application.
|
|
238
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
239
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
240
|
-
* provided under the following open source license terms:
|
|
241
|
-
*
|
|
242
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
243
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
244
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
245
|
-
* (at your option) any later version.
|
|
246
|
-
*
|
|
247
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
248
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
249
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
250
|
-
* GNU Lesser General Public License for more details.
|
|
251
|
-
*
|
|
252
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
253
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
254
|
-
*/
|
|
255
|
-
class RouterExtensionService {
|
|
256
|
-
constructor(router, extensions) {
|
|
257
|
-
this.router = router;
|
|
258
|
-
this.extensions = extensions;
|
|
259
|
-
this.defaults = {
|
|
260
|
-
layout: 'app.layout.main',
|
|
261
|
-
auth: ['app.auth']
|
|
262
|
-
};
|
|
263
|
-
}
|
|
264
|
-
mapExtensionRoutes() {
|
|
265
|
-
const routesWithoutParent = [];
|
|
266
|
-
this.getApplicationRoutes().forEach((extensionRoute) => {
|
|
267
|
-
if (this.extensionRouteHasChild(extensionRoute)) {
|
|
268
|
-
const parentRoute = this.findRoute(extensionRoute.parentRoute);
|
|
269
|
-
if (parentRoute) {
|
|
270
|
-
this.convertExtensionRouteToRoute(extensionRoute);
|
|
271
|
-
parentRoute.children.unshift(extensionRoute);
|
|
272
|
-
}
|
|
273
|
-
}
|
|
274
|
-
else {
|
|
275
|
-
routesWithoutParent.push(extensionRoute);
|
|
276
|
-
}
|
|
277
|
-
});
|
|
278
|
-
this.router.config.unshift(...routesWithoutParent);
|
|
279
|
-
}
|
|
280
|
-
getApplicationRoutes() {
|
|
281
|
-
return this.extensions.routes.map((route) => {
|
|
282
|
-
var _a;
|
|
283
|
-
const guards = this.extensions.getAuthGuards(route.auth && route.auth.length > 0 ? route.auth : this.defaults.auth);
|
|
284
|
-
return {
|
|
285
|
-
path: route.path,
|
|
286
|
-
component: this.getComponentById((_a = route.layout) !== null && _a !== void 0 ? _a : this.defaults.layout),
|
|
287
|
-
canActivateChild: guards,
|
|
288
|
-
canActivate: guards,
|
|
289
|
-
parentRoute: route.parentRoute,
|
|
290
|
-
children: [
|
|
291
|
-
...(route['children']
|
|
292
|
-
? route['children'].map(({ path, component, outlet, data }) => ({
|
|
293
|
-
path,
|
|
294
|
-
outlet,
|
|
295
|
-
data,
|
|
296
|
-
component: this.getComponentById(component)
|
|
297
|
-
}))
|
|
298
|
-
: []),
|
|
299
|
-
{
|
|
300
|
-
path: '',
|
|
301
|
-
component: this.getComponentById(route.component),
|
|
302
|
-
data: route.data
|
|
303
|
-
}
|
|
304
|
-
]
|
|
305
|
-
};
|
|
306
|
-
});
|
|
307
|
-
}
|
|
308
|
-
getComponentById(id) {
|
|
309
|
-
return this.extensions.getComponentById(id);
|
|
310
|
-
}
|
|
311
|
-
extensionRouteHasChild(route) {
|
|
312
|
-
return route.parentRoute !== undefined;
|
|
313
|
-
}
|
|
314
|
-
convertExtensionRouteToRoute(extensionRoute) {
|
|
315
|
-
delete extensionRoute.parentRoute;
|
|
316
|
-
delete extensionRoute.component;
|
|
317
|
-
}
|
|
318
|
-
findRoute(parentRoute) {
|
|
319
|
-
const routeIndex = this.router.config.findIndex((route) => route.path === parentRoute);
|
|
320
|
-
return this.router.config[routeIndex];
|
|
321
|
-
}
|
|
322
|
-
}
|
|
323
|
-
RouterExtensionService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RouterExtensionService, deps: [{ token: i3.Router }, { token: i3$1.ExtensionService }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
324
|
-
RouterExtensionService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RouterExtensionService, providedIn: 'root' });
|
|
325
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: RouterExtensionService, decorators: [{
|
|
326
|
-
type: Injectable,
|
|
327
|
-
args: [{
|
|
328
|
-
providedIn: 'root'
|
|
329
|
-
}]
|
|
330
|
-
}], ctorParameters: function () { return [{ type: i3.Router }, { type: i3$1.ExtensionService }]; } });
|
|
331
|
-
|
|
332
|
-
/*!
|
|
333
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
334
|
-
*
|
|
335
|
-
* Alfresco Example Content Application
|
|
336
|
-
*
|
|
337
|
-
* This file is part of the Alfresco Example Content Application.
|
|
338
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
339
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
340
|
-
* provided under the following open source license terms:
|
|
341
|
-
*
|
|
342
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
343
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
344
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
345
|
-
* (at your option) any later version.
|
|
346
|
-
*
|
|
347
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
348
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
349
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
350
|
-
* GNU Lesser General Public License for more details.
|
|
351
|
-
*
|
|
352
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
353
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
354
|
-
*/
|
|
355
|
-
class ContentApiService {
|
|
356
|
-
get nodesApi() {
|
|
357
|
-
var _a;
|
|
358
|
-
this._nodesApi = (_a = this._nodesApi) !== null && _a !== void 0 ? _a : new NodesApi(this.api.getInstance());
|
|
359
|
-
return this._nodesApi;
|
|
360
|
-
}
|
|
361
|
-
get trashcanApi() {
|
|
362
|
-
var _a;
|
|
363
|
-
this._trashcanApi = (_a = this._trashcanApi) !== null && _a !== void 0 ? _a : new TrashcanApi(this.api.getInstance());
|
|
364
|
-
return this._trashcanApi;
|
|
365
|
-
}
|
|
366
|
-
get sharedLinksApi() {
|
|
367
|
-
var _a;
|
|
368
|
-
this._sharedLinksApi = (_a = this._sharedLinksApi) !== null && _a !== void 0 ? _a : new SharedlinksApi(this.api.getInstance());
|
|
369
|
-
return this._sharedLinksApi;
|
|
370
|
-
}
|
|
371
|
-
get discoveryApi() {
|
|
372
|
-
var _a;
|
|
373
|
-
this._discoveryApi = (_a = this._discoveryApi) !== null && _a !== void 0 ? _a : new DiscoveryApi(this.api.getInstance());
|
|
374
|
-
return this._discoveryApi;
|
|
375
|
-
}
|
|
376
|
-
get favoritesApi() {
|
|
377
|
-
var _a;
|
|
378
|
-
this._favoritesApi = (_a = this._favoritesApi) !== null && _a !== void 0 ? _a : new FavoritesApi(this.api.getInstance());
|
|
379
|
-
return this._favoritesApi;
|
|
380
|
-
}
|
|
381
|
-
get contentApi() {
|
|
382
|
-
var _a;
|
|
383
|
-
this._contentApi = (_a = this._contentApi) !== null && _a !== void 0 ? _a : new ContentApi(this.api.getInstance());
|
|
384
|
-
return this._contentApi;
|
|
385
|
-
}
|
|
386
|
-
get sitesApi() {
|
|
387
|
-
var _a;
|
|
388
|
-
this._sitesApi = (_a = this._sitesApi) !== null && _a !== void 0 ? _a : new SitesApi(this.api.getInstance());
|
|
389
|
-
return this._sitesApi;
|
|
390
|
-
}
|
|
391
|
-
get searchApi() {
|
|
392
|
-
var _a;
|
|
393
|
-
this._searchApi = (_a = this._searchApi) !== null && _a !== void 0 ? _a : new SearchApi(this.api.getInstance());
|
|
394
|
-
return this._searchApi;
|
|
395
|
-
}
|
|
396
|
-
get peopleApi() {
|
|
397
|
-
var _a;
|
|
398
|
-
this._peopleApi = (_a = this._peopleApi) !== null && _a !== void 0 ? _a : new PeopleApi(this.api.getInstance());
|
|
399
|
-
return this._peopleApi;
|
|
400
|
-
}
|
|
401
|
-
get versionsApi() {
|
|
402
|
-
var _a;
|
|
403
|
-
this._versionsApi = (_a = this._versionsApi) !== null && _a !== void 0 ? _a : new VersionsApi(this.api.getInstance());
|
|
404
|
-
return this._versionsApi;
|
|
405
|
-
}
|
|
406
|
-
constructor(api, preferences) {
|
|
407
|
-
this.api = api;
|
|
408
|
-
this.preferences = preferences;
|
|
409
|
-
}
|
|
410
|
-
/**
|
|
411
|
-
* Moves a node to the trashcan.
|
|
412
|
-
*
|
|
413
|
-
* @param nodeId ID of the target node
|
|
414
|
-
* @param options Optional parameters supported by JS-API
|
|
415
|
-
* @returns Empty result that notifies when the deletion is complete
|
|
416
|
-
*/
|
|
417
|
-
deleteNode(nodeId, options = {}) {
|
|
418
|
-
return from(this.nodesApi.deleteNode(nodeId, options));
|
|
419
|
-
}
|
|
420
|
-
/**
|
|
421
|
-
* Gets the stored information about a node.
|
|
422
|
-
*
|
|
423
|
-
* @param nodeId ID of the target node
|
|
424
|
-
* @param options Optional parameters supported by JS-API
|
|
425
|
-
* @returns Node information
|
|
426
|
-
*/
|
|
427
|
-
getNode(nodeId, options = {}) {
|
|
428
|
-
const defaults = {
|
|
429
|
-
include: ['path', 'properties', 'allowableOperations', 'permissions', 'definition']
|
|
430
|
-
};
|
|
431
|
-
const queryOptions = Object.assign(defaults, options);
|
|
432
|
-
return from(this.nodesApi.getNode(nodeId, queryOptions));
|
|
433
|
-
}
|
|
434
|
-
getNodeInfo(nodeId, options) {
|
|
435
|
-
const defaults = {
|
|
436
|
-
include: ['isFavorite', 'allowableOperations', 'path', 'definition']
|
|
437
|
-
};
|
|
438
|
-
const queryOptions = Object.assign(defaults, options || {});
|
|
439
|
-
return from(new Promise((resolve, reject) => {
|
|
440
|
-
this.nodesApi.getNode(nodeId, queryOptions).then((nodeEntry) => {
|
|
441
|
-
resolve(nodeEntry.entry);
|
|
442
|
-
}, (error) => {
|
|
443
|
-
reject(error);
|
|
444
|
-
});
|
|
445
|
-
}));
|
|
446
|
-
}
|
|
447
|
-
/**
|
|
448
|
-
* Gets the items contained in a folder node.
|
|
449
|
-
*
|
|
450
|
-
* @param nodeId ID of the target node
|
|
451
|
-
* @param options Optional parameters supported by JS-API
|
|
452
|
-
* @returns List of child items from the folder
|
|
453
|
-
*/
|
|
454
|
-
getNodeChildren(nodeId, options = {}) {
|
|
455
|
-
const defaults = {
|
|
456
|
-
maxItems: this.preferences.paginationSize,
|
|
457
|
-
skipCount: 0,
|
|
458
|
-
include: ['isLocked', 'path', 'properties', 'allowableOperations', 'permissions']
|
|
459
|
-
};
|
|
460
|
-
const queryOptions = Object.assign(defaults, options);
|
|
461
|
-
return from(this.nodesApi.listNodeChildren(nodeId, queryOptions));
|
|
462
|
-
}
|
|
463
|
-
deleteSharedLink(linkId) {
|
|
464
|
-
return from(this.sharedLinksApi.deleteSharedLink(linkId));
|
|
465
|
-
}
|
|
466
|
-
getDeletedNodes(options = {}) {
|
|
467
|
-
const defaults = {
|
|
468
|
-
include: ['path']
|
|
469
|
-
};
|
|
470
|
-
const queryOptions = Object.assign(defaults, options);
|
|
471
|
-
return from(this.trashcanApi.listDeletedNodes(queryOptions));
|
|
472
|
-
}
|
|
473
|
-
restoreNode(nodeId) {
|
|
474
|
-
return from(this.trashcanApi.restoreDeletedNode(nodeId));
|
|
475
|
-
}
|
|
476
|
-
purgeDeletedNode(nodeId) {
|
|
477
|
-
return from(this.trashcanApi.deleteDeletedNode(nodeId));
|
|
478
|
-
}
|
|
479
|
-
/**
|
|
480
|
-
* Gets information about a user identified by their username.
|
|
481
|
-
*
|
|
482
|
-
* @param personId ID of the target user
|
|
483
|
-
* @param options Api options
|
|
484
|
-
* @returns User information
|
|
485
|
-
*/
|
|
486
|
-
getPerson(personId, options) {
|
|
487
|
-
return from(this.peopleApi.getPerson(personId, options));
|
|
488
|
-
}
|
|
489
|
-
/**
|
|
490
|
-
* Copy a node to destination node
|
|
491
|
-
*
|
|
492
|
-
* @param nodeId The id of the node to be copied
|
|
493
|
-
* @param targetParentId The id of the folder-node where the node have to be copied to
|
|
494
|
-
* @param name The new name for the copy that would be added on the destination folder
|
|
495
|
-
* @param opts Api options
|
|
496
|
-
*/
|
|
497
|
-
copyNode(nodeId, targetParentId, name, opts) {
|
|
498
|
-
return from(this.nodesApi.copyNode(nodeId, { targetParentId, name }, opts));
|
|
499
|
-
}
|
|
500
|
-
/**
|
|
501
|
-
* Gets product information for Content Services.
|
|
502
|
-
*
|
|
503
|
-
* @returns ProductVersionModel containing product details
|
|
504
|
-
*/
|
|
505
|
-
getRepositoryInformation() {
|
|
506
|
-
return from(this.discoveryApi.getRepositoryInformation());
|
|
507
|
-
}
|
|
508
|
-
getFavorites(personId, opts) {
|
|
509
|
-
return from(this.favoritesApi.listFavorites(personId, opts));
|
|
510
|
-
}
|
|
511
|
-
getFavoriteLibraries(personId = '-me-', opts) {
|
|
512
|
-
return this.getFavorites(personId, Object.assign(Object.assign({}, opts), { where: '(EXISTS(target/site))' })).pipe(map((response) => ({
|
|
513
|
-
list: {
|
|
514
|
-
entries: response.list.entries.map(({ entry }) => {
|
|
515
|
-
entry.target.site.createdAt = entry.createdAt;
|
|
516
|
-
return {
|
|
517
|
-
entry: entry.target.site
|
|
518
|
-
};
|
|
519
|
-
}),
|
|
520
|
-
pagination: response.list.pagination
|
|
521
|
-
}
|
|
522
|
-
})));
|
|
523
|
-
}
|
|
524
|
-
findSharedLinks(opts) {
|
|
525
|
-
return from(this.sharedLinksApi.listSharedLinks(opts));
|
|
526
|
-
}
|
|
527
|
-
getSharedLinkContent(sharedId, attachment) {
|
|
528
|
-
return this.contentApi.getSharedLinkContentUrl(sharedId, attachment);
|
|
529
|
-
}
|
|
530
|
-
search(request) {
|
|
531
|
-
return from(this.searchApi.search(request));
|
|
532
|
-
}
|
|
533
|
-
getContentUrl(nodeId, attachment) {
|
|
534
|
-
return this.contentApi.getContentUrl(nodeId, attachment);
|
|
535
|
-
}
|
|
536
|
-
getVersionContentUrl(nodeId, versionId, attachment) {
|
|
537
|
-
return this.contentApi.getVersionContentUrl(nodeId, versionId, attachment);
|
|
538
|
-
}
|
|
539
|
-
deleteSite(siteId, opts) {
|
|
540
|
-
return from(this.sitesApi.deleteSite(siteId, opts));
|
|
541
|
-
}
|
|
542
|
-
leaveSite(siteId) {
|
|
543
|
-
return from(this.sitesApi.deleteSiteMembership(siteId, '-me-'));
|
|
544
|
-
}
|
|
545
|
-
createSite(siteBody, opts) {
|
|
546
|
-
return from(this.sitesApi.createSite(siteBody, opts));
|
|
547
|
-
}
|
|
548
|
-
getSite(siteId, opts) {
|
|
549
|
-
return from(this.sitesApi.getSite(siteId, opts));
|
|
550
|
-
}
|
|
551
|
-
updateLibrary(siteId, siteBody) {
|
|
552
|
-
return from(this.sitesApi.updateSite(siteId, siteBody));
|
|
553
|
-
}
|
|
554
|
-
addFavorite(nodes) {
|
|
555
|
-
const payload = nodes.map((node) => {
|
|
556
|
-
const { isFolder, nodeId, id } = node.entry;
|
|
557
|
-
const siteId = node.entry['guid'];
|
|
558
|
-
const type = siteId ? 'site' : isFolder ? 'folder' : 'file';
|
|
559
|
-
const guid = siteId || nodeId || id;
|
|
560
|
-
return {
|
|
561
|
-
target: {
|
|
562
|
-
[type]: {
|
|
563
|
-
guid
|
|
564
|
-
}
|
|
565
|
-
}
|
|
566
|
-
};
|
|
567
|
-
});
|
|
568
|
-
return from(this.favoritesApi.createFavorite('-me-', payload));
|
|
569
|
-
}
|
|
570
|
-
removeFavorite(nodes) {
|
|
571
|
-
return from(Promise.all(nodes.map((node) => {
|
|
572
|
-
const id = node.entry.nodeId || node.entry.id;
|
|
573
|
-
return this.favoritesApi.deleteFavorite('-me-', id);
|
|
574
|
-
})));
|
|
575
|
-
}
|
|
576
|
-
unlockNode(nodeId, opts) {
|
|
577
|
-
return this.nodesApi.unlockNode(nodeId, opts);
|
|
578
|
-
}
|
|
579
|
-
getNodeVersions(nodeId, opts) {
|
|
580
|
-
return from(this.versionsApi.listVersionHistory(nodeId, opts));
|
|
581
|
-
}
|
|
582
|
-
requestNodeDirectAccessUrl(nodeId) {
|
|
583
|
-
return from(this.nodesApi.requestDirectAccessUrl(nodeId));
|
|
584
|
-
}
|
|
585
|
-
requestVersionDirectAccessUrl(nodeId, versionId) {
|
|
586
|
-
return from(this.versionsApi.requestDirectAccessUrl(nodeId, versionId));
|
|
587
|
-
}
|
|
588
|
-
}
|
|
589
|
-
ContentApiService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: ContentApiService, deps: [{ token: i4.AlfrescoApiService }, { token: i1.UserPreferencesService }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
590
|
-
ContentApiService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: ContentApiService, providedIn: 'root' });
|
|
591
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: ContentApiService, decorators: [{
|
|
592
|
-
type: Injectable,
|
|
593
|
-
args: [{
|
|
594
|
-
providedIn: 'root'
|
|
595
|
-
}]
|
|
596
|
-
}], ctorParameters: function () { return [{ type: i4.AlfrescoApiService }, { type: i1.UserPreferencesService }]; } });
|
|
597
|
-
|
|
598
|
-
/*!
|
|
599
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
600
|
-
*
|
|
601
|
-
* Alfresco Example Content Application
|
|
602
|
-
*
|
|
603
|
-
* This file is part of the Alfresco Example Content Application.
|
|
604
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
605
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
606
|
-
* provided under the following open source license terms:
|
|
607
|
-
*
|
|
608
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
609
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
610
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
611
|
-
* (at your option) any later version.
|
|
612
|
-
*
|
|
613
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
614
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
615
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
616
|
-
* GNU Lesser General Public License for more details.
|
|
617
|
-
*
|
|
618
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
619
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
620
|
-
*/
|
|
621
|
-
class OpenInAppComponent {
|
|
622
|
-
constructor(data, dialog) {
|
|
623
|
-
this.data = data;
|
|
624
|
-
this.dialog = dialog;
|
|
625
|
-
this.window = window;
|
|
626
|
-
if (data) {
|
|
627
|
-
this.redirectUrl = data.redirectUrl;
|
|
628
|
-
this.appStoreUrl = data.appStoreUrl;
|
|
629
|
-
}
|
|
630
|
-
}
|
|
631
|
-
openInApp() {
|
|
632
|
-
this.window.location.href = this.redirectUrl;
|
|
633
|
-
}
|
|
634
|
-
downloadIosApp() {
|
|
635
|
-
this.window.location.href = this.appStoreUrl;
|
|
636
|
-
}
|
|
637
|
-
onCloseDialog() {
|
|
638
|
-
const time = new Date().getTime();
|
|
639
|
-
sessionStorage.setItem('mobile_notification_expires_in', time.toString());
|
|
640
|
-
this.dialog.close();
|
|
641
|
-
}
|
|
642
|
-
}
|
|
643
|
-
OpenInAppComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: OpenInAppComponent, deps: [{ token: MAT_DIALOG_DATA }, { token: i1$1.MatDialogRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
644
|
-
OpenInAppComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: OpenInAppComponent, isStandalone: true, selector: "aca-open-in-app", ngImport: i0, template: "<div class=\"aca-open-in-app\">\n <div class=\"aca-mobile-application-container\">\n <span>{{ 'APP.DIALOGS.MOBILE_APP.OPEN_ALFRESCO_MOBILE_APP' | translate }}</span>\n <button mat-icon-button mat-dialog-close class=\"aca-cross-button\" (click)=\"onCloseDialog()\" >\n <mat-icon class=\"aca-cross-button-icon\">close</mat-icon>\n </button>\n </div>\n\n <div class=\"aca-open-in-app-button-container\">\n <button mat-button (click)=\"openInApp()\"\n data-automation-id=\"open-in-app-button\"\n class=\"aca-open-in-app-button-container\" cdkFocusInitial>\n <span>{{ 'APP.DIALOGS.MOBILE_APP.MOBILE_APP_BUTTON_LABEL' | translate }}</span>\n </button>\n </div>\n\n <div class=\"aca-download-app-container\" *ngIf=\"appStoreUrl\">\n <button mat-button data-automation-id=\"download-app-button\" class=\"aca-download-app-container-button\" (click)=\"downloadIosApp()\">\n <span>{{ 'APP.DIALOGS.MOBILE_APP.DOWNLOAD_APP_BUTTON_LABEL' | translate }}</span>\n </button>\n </div>\n</div>\n", styles: ["aca-open-in-app .aca-open-in-app .aca-open-in-app-button-container{display:flex;place-content:center;padding:0;border-radius:8px;background-color:var(--theme-primary-color);height:48px;overflow-x:hidden;font-size:16px;color:#fff;font-weight:600}aca-open-in-app .aca-open-in-app .aca-open-in-app-button-container:focus-visible{outline:none;border-radius:unset}aca-open-in-app .aca-open-in-app .aca-download-app-container{display:flex;place-content:center;margin-top:12px;margin-bottom:16px}aca-open-in-app .aca-open-in-app .aca-download-app-container-button{background:var(--theme-dialog-background-color);color:var(--theme-primary-color);font-size:14px}aca-open-in-app .aca-open-in-app .aca-mobile-application-container{display:flex;flex-direction:row;justify-content:space-between;align-items:center;font-size:14px;padding:6px 0;margin-bottom:12px}aca-open-in-app .aca-open-in-app .aca-cross-button{padding-right:0}aca-open-in-app .aca-open-in-app .aca-cross-button:focus-visible{outline:none;border-radius:unset}aca-open-in-app .aca-open-in-app .aca-cross-button-icon{font-weight:700;font-size:20px}aca-open-in-app .aca-open-in-app .mat-mdc-button{--mat-mdc-button-persistent-ripple-color: unset;--mat-mdc-button-ripple-color: unset}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i3$2.TranslatePipe, name: "translate" }, { kind: "ngmodule", type: MatButtonModule }, { kind: "component", type: i4$1.MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "component", type: i4$1.MatIconButton, selector: "button[mat-icon-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i5.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: A11yModule }, { kind: "ngmodule", type: MatDialogModule }, { kind: "directive", type: i1$1.MatDialogClose, selector: "[mat-dialog-close], [matDialogClose]", inputs: ["aria-label", "type", "mat-dialog-close", "matDialogClose"], exportAs: ["matDialogClose"] }], encapsulation: i0.ViewEncapsulation.None });
|
|
645
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: OpenInAppComponent, decorators: [{
|
|
646
|
-
type: Component,
|
|
647
|
-
args: [{ standalone: true, imports: [CommonModule, TranslateModule, MatButtonModule, MatIconModule, A11yModule, MatDialogModule], selector: 'aca-open-in-app', encapsulation: ViewEncapsulation.None, template: "<div class=\"aca-open-in-app\">\n <div class=\"aca-mobile-application-container\">\n <span>{{ 'APP.DIALOGS.MOBILE_APP.OPEN_ALFRESCO_MOBILE_APP' | translate }}</span>\n <button mat-icon-button mat-dialog-close class=\"aca-cross-button\" (click)=\"onCloseDialog()\" >\n <mat-icon class=\"aca-cross-button-icon\">close</mat-icon>\n </button>\n </div>\n\n <div class=\"aca-open-in-app-button-container\">\n <button mat-button (click)=\"openInApp()\"\n data-automation-id=\"open-in-app-button\"\n class=\"aca-open-in-app-button-container\" cdkFocusInitial>\n <span>{{ 'APP.DIALOGS.MOBILE_APP.MOBILE_APP_BUTTON_LABEL' | translate }}</span>\n </button>\n </div>\n\n <div class=\"aca-download-app-container\" *ngIf=\"appStoreUrl\">\n <button mat-button data-automation-id=\"download-app-button\" class=\"aca-download-app-container-button\" (click)=\"downloadIosApp()\">\n <span>{{ 'APP.DIALOGS.MOBILE_APP.DOWNLOAD_APP_BUTTON_LABEL' | translate }}</span>\n </button>\n </div>\n</div>\n", styles: ["aca-open-in-app .aca-open-in-app .aca-open-in-app-button-container{display:flex;place-content:center;padding:0;border-radius:8px;background-color:var(--theme-primary-color);height:48px;overflow-x:hidden;font-size:16px;color:#fff;font-weight:600}aca-open-in-app .aca-open-in-app .aca-open-in-app-button-container:focus-visible{outline:none;border-radius:unset}aca-open-in-app .aca-open-in-app .aca-download-app-container{display:flex;place-content:center;margin-top:12px;margin-bottom:16px}aca-open-in-app .aca-open-in-app .aca-download-app-container-button{background:var(--theme-dialog-background-color);color:var(--theme-primary-color);font-size:14px}aca-open-in-app .aca-open-in-app .aca-mobile-application-container{display:flex;flex-direction:row;justify-content:space-between;align-items:center;font-size:14px;padding:6px 0;margin-bottom:12px}aca-open-in-app .aca-open-in-app .aca-cross-button{padding-right:0}aca-open-in-app .aca-open-in-app .aca-cross-button:focus-visible{outline:none;border-radius:unset}aca-open-in-app .aca-open-in-app .aca-cross-button-icon{font-weight:700;font-size:20px}aca-open-in-app .aca-open-in-app .mat-mdc-button{--mat-mdc-button-persistent-ripple-color: unset;--mat-mdc-button-ripple-color: unset}\n"] }]
|
|
648
|
-
}], ctorParameters: function () {
|
|
649
|
-
return [{ type: undefined, decorators: [{
|
|
650
|
-
type: Inject,
|
|
651
|
-
args: [MAT_DIALOG_DATA]
|
|
652
|
-
}] }, { type: i1$1.MatDialogRef }];
|
|
653
|
-
} });
|
|
654
|
-
|
|
655
|
-
/*!
|
|
656
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
657
|
-
*
|
|
658
|
-
* Alfresco Example Content Application
|
|
659
|
-
*
|
|
660
|
-
* This file is part of the Alfresco Example Content Application.
|
|
661
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
662
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
663
|
-
* provided under the following open source license terms:
|
|
664
|
-
*
|
|
665
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
666
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
667
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
668
|
-
* (at your option) any later version.
|
|
669
|
-
*
|
|
670
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
671
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
672
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
673
|
-
* GNU Lesser General Public License for more details.
|
|
674
|
-
*
|
|
675
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
676
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
677
|
-
*/
|
|
678
|
-
class AcaMobileAppSwitcherService {
|
|
679
|
-
constructor() {
|
|
680
|
-
this.config = inject(AppConfigService);
|
|
681
|
-
this.dialog = inject(MatDialog);
|
|
682
|
-
}
|
|
683
|
-
get appStoreUrl() {
|
|
684
|
-
const defaultValue = 'https://apps.apple.com/us/app/alfresco-mobile-workspace/id1514434480';
|
|
685
|
-
return this.config.get('mobileAppSwitch.appStoreUrl', defaultValue);
|
|
686
|
-
}
|
|
687
|
-
get sessionTimeout() {
|
|
688
|
-
return this.config.get('mobileAppSwitch.sessionTimeout', 12);
|
|
689
|
-
}
|
|
690
|
-
getIPhoneRedirectUrl(url) {
|
|
691
|
-
const prefix = this.config.get('mobileAppSwitch.iphoneUrl', 'iosamw://');
|
|
692
|
-
return prefix + url;
|
|
693
|
-
}
|
|
694
|
-
getAndroidRedirectUrl(url) {
|
|
695
|
-
const prefix = this.config.get('mobileAppSwitch.androidUrlPart1', 'intent:///');
|
|
696
|
-
const suffix = this.config.get('mobileAppSwitch.androidUrlPart2', '#Intent;scheme=androidamw;package=com.alfresco.content.app;end');
|
|
697
|
-
return prefix + url + suffix;
|
|
698
|
-
}
|
|
699
|
-
resolveExistenceOfDialog() {
|
|
700
|
-
const url = this.getCurrentUrl();
|
|
701
|
-
const queryParams = url.split('?')[1];
|
|
702
|
-
let queryParamsList = [];
|
|
703
|
-
let hideBanner = false;
|
|
704
|
-
if (queryParams !== null && queryParams !== undefined) {
|
|
705
|
-
queryParamsList = queryParams.split('&');
|
|
706
|
-
hideBanner = queryParamsList.some((param) => param.split('=')[0] === 'mobileapps' && param.split('=')[1] === 'true');
|
|
707
|
-
}
|
|
708
|
-
if (!hideBanner) {
|
|
709
|
-
this.verifySessionExistsForDialog();
|
|
710
|
-
}
|
|
711
|
-
}
|
|
712
|
-
verifySessionExistsForDialog() {
|
|
713
|
-
const sessionTime = sessionStorage.getItem('mobile_notification_expires_in');
|
|
714
|
-
if (sessionTime !== null) {
|
|
715
|
-
const currentTime = new Date().getTime();
|
|
716
|
-
const sessionConvertedTime = parseFloat(sessionTime);
|
|
717
|
-
const timeDifference = (currentTime - sessionConvertedTime) / (1000 * 60 * 60);
|
|
718
|
-
if (timeDifference > this.sessionTimeout) {
|
|
719
|
-
this.clearSessionExpireTime();
|
|
720
|
-
this.identifyBrowserAndSetRedirectURL();
|
|
721
|
-
}
|
|
722
|
-
}
|
|
723
|
-
else {
|
|
724
|
-
this.identifyBrowserAndSetRedirectURL();
|
|
725
|
-
}
|
|
726
|
-
}
|
|
727
|
-
identifyBrowserAndSetRedirectURL() {
|
|
728
|
-
const ua = navigator.userAgent.toLowerCase();
|
|
729
|
-
const isAndroid = ua.indexOf('android') > -1;
|
|
730
|
-
const isIPadInSafari = /Macintosh/i.test(ua) && navigator.maxTouchPoints && navigator.maxTouchPoints > 1;
|
|
731
|
-
const isIOS = ua.indexOf('iphone') > -1 || ua.indexOf('ipad') > -1 || ua.indexOf('ipod') > -1 || isIPadInSafari;
|
|
732
|
-
const currentUrl = this.getCurrentUrl();
|
|
733
|
-
if (isIOS === true) {
|
|
734
|
-
this.redirectUrl = this.getIPhoneRedirectUrl(currentUrl);
|
|
735
|
-
}
|
|
736
|
-
else if (isAndroid === true) {
|
|
737
|
-
this.redirectUrl = this.getAndroidRedirectUrl(currentUrl);
|
|
738
|
-
}
|
|
739
|
-
if (this.redirectUrl !== undefined && this.redirectUrl !== null) {
|
|
740
|
-
this.openDialog(this.redirectUrl, this.appStoreUrl);
|
|
741
|
-
}
|
|
742
|
-
}
|
|
743
|
-
openDialog(redirectUrl, appStoreUrl) {
|
|
744
|
-
if (!this.dialogRef) {
|
|
745
|
-
this.dialogRef = this.dialog.open(OpenInAppComponent, {
|
|
746
|
-
data: {
|
|
747
|
-
redirectUrl,
|
|
748
|
-
appStoreUrl
|
|
749
|
-
},
|
|
750
|
-
hasBackdrop: false,
|
|
751
|
-
width: '100%',
|
|
752
|
-
role: 'dialog',
|
|
753
|
-
position: { bottom: '0' }
|
|
754
|
-
});
|
|
755
|
-
}
|
|
756
|
-
}
|
|
757
|
-
clearSessionExpireTime() {
|
|
758
|
-
sessionStorage.removeItem('mobile_notification_expires_in');
|
|
759
|
-
}
|
|
760
|
-
getCurrentUrl() {
|
|
761
|
-
return window.location.href;
|
|
762
|
-
}
|
|
763
|
-
closeDialog() {
|
|
764
|
-
if (this.dialogRef) {
|
|
765
|
-
this.dialog.closeAll();
|
|
766
|
-
this.dialogRef = null;
|
|
767
|
-
}
|
|
768
|
-
}
|
|
769
|
-
}
|
|
770
|
-
AcaMobileAppSwitcherService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: AcaMobileAppSwitcherService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
771
|
-
AcaMobileAppSwitcherService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: AcaMobileAppSwitcherService, providedIn: 'root' });
|
|
772
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: AcaMobileAppSwitcherService, decorators: [{
|
|
773
|
-
type: Injectable,
|
|
774
|
-
args: [{
|
|
775
|
-
providedIn: 'root'
|
|
776
|
-
}]
|
|
777
|
-
}] });
|
|
778
|
-
|
|
779
|
-
/*!
|
|
780
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
781
|
-
*
|
|
782
|
-
* Alfresco Example Content Application
|
|
783
|
-
*
|
|
784
|
-
* This file is part of the Alfresco Example Content Application.
|
|
785
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
786
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
787
|
-
* provided under the following open source license terms:
|
|
788
|
-
*
|
|
789
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
790
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
791
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
792
|
-
* (at your option) any later version.
|
|
793
|
-
*
|
|
794
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
795
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
796
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
797
|
-
* GNU Lesser General Public License for more details.
|
|
798
|
-
*
|
|
799
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
800
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
801
|
-
*/
|
|
802
|
-
const DefaultMimeTypes = [
|
|
803
|
-
{ value: 'video/3gpp', label: '3G Video' },
|
|
804
|
-
{ value: 'video/3gpp2', label: '3G2 Video' },
|
|
805
|
-
{ value: 'application/vnd.alfresco.ai.features.v1+json', label: 'AI-Features' },
|
|
806
|
-
{ value: 'application/vnd.alfresco.ai.labels.v1+json', label: 'AI-Labels' },
|
|
807
|
-
{ value: 'application/vnd.alfresco.ai.pii.entities.v1+json', label: 'AI-PII-Entities' },
|
|
808
|
-
{ value: 'application/vnd.alfresco.ai.speech-to-text.v1+json', label: 'AI-SpeechToText' },
|
|
809
|
-
{ value: 'application/vnd.alfresco.ai.textract.v1+json', label: 'AI-Textract' },
|
|
810
|
-
{ value: 'audio/x-aiff', label: 'AIFF Audio' },
|
|
811
|
-
{ value: 'application/vnd.adobe.air-application-installer-package+zip', label: 'Adobe AIR' },
|
|
812
|
-
{ value: 'application/vnd.adobe.xdp+xml', label: 'Adobe Acrobat XML Data Package' },
|
|
813
|
-
{ value: 'application/vnd.adobe.aftereffects.project', label: 'Adobe AfterEffects Project' },
|
|
814
|
-
{ value: 'application/vnd.adobe.aftereffects.template', label: 'Adobe AfterEffects Template' },
|
|
815
|
-
{ value: 'image/x-raw-adobe', label: 'Adobe Digital Negative Image' },
|
|
816
|
-
{ value: 'application/x-zip', label: 'Adobe Flex Project File' },
|
|
817
|
-
{ value: 'application/framemaker', label: 'Adobe FrameMaker' },
|
|
818
|
-
{ value: 'application/illustrator', label: 'Adobe Illustrator File' },
|
|
819
|
-
{ value: 'application/x-indesign', label: 'Adobe InDesign Document' },
|
|
820
|
-
{ value: 'application/pdf', label: 'Adobe PDF Document' },
|
|
821
|
-
{ value: 'application/pagemaker', label: 'Adobe PageMaker' },
|
|
822
|
-
{ value: 'image/vnd.adobe.photoshop', label: 'Adobe Photoshop' },
|
|
823
|
-
{ value: 'image/vnd.adobe.premiere', label: 'Adobe Premiere' },
|
|
824
|
-
{ value: 'audio/vnd.adobe.soundbooth', label: 'Adobe SoundBooth' },
|
|
825
|
-
{ value: 'application/acp', label: 'Alfresco Content Package' },
|
|
826
|
-
{ value: 'application/vnd.android.package-archive', label: 'Android Package' },
|
|
827
|
-
{ value: 'image/x-portable-anymap', label: 'Anymap Image' },
|
|
828
|
-
{ value: 'image/icns', label: 'Apple Icon' },
|
|
829
|
-
{ value: 'application/vnd.apple.keynote', label: 'Apple iWork Keynote' },
|
|
830
|
-
{ value: 'application/vnd.apple.numbers', label: 'Apple iWork Numbers' },
|
|
831
|
-
{ value: 'application/vnd.apple.pages', label: 'Apple iWork Pages' },
|
|
832
|
-
{ value: 'image/vnd.dwg', label: 'AutoCAD Drawing' },
|
|
833
|
-
{ value: 'image/x-dwt', label: 'AutoCAD Template' },
|
|
834
|
-
{ value: 'audio/basic', label: 'Basic Audio' },
|
|
835
|
-
{ value: 'application/x-dosexec', label: 'Binary File' },
|
|
836
|
-
{ value: 'application/octet-stream', label: 'Binary File (Octet Stream)' },
|
|
837
|
-
{ value: 'image/bmp', label: 'Bitmap Image' },
|
|
838
|
-
{ value: 'image/cgm', label: 'CGM Image' },
|
|
839
|
-
{ value: 'image/x-raw-canon', label: 'Canon RAW Image' },
|
|
840
|
-
{ value: 'text/csv', label: 'Comma Separated Values (CSV)' },
|
|
841
|
-
{ value: 'application/dita+xml', label: 'DITA' },
|
|
842
|
-
{ value: 'message/rfc822', label: 'EMail' },
|
|
843
|
-
{ value: 'application/eps', label: 'EPS Type PostScript' },
|
|
844
|
-
{ value: 'audio/x-flac', label: 'FLAC Audio' },
|
|
845
|
-
{ value: 'application/x-fla', label: 'Flash Source' },
|
|
846
|
-
{ value: 'video/x-flv', label: 'Flash Video' },
|
|
847
|
-
{ value: 'image/x-raw-fuji', label: 'Fuji RAW Image' },
|
|
848
|
-
{ value: 'image/gif', label: 'GIF Image' },
|
|
849
|
-
{ value: 'application/x-gzip', label: 'GZIP' },
|
|
850
|
-
{ value: 'application/x-gtar', label: 'GZIP Tarball' },
|
|
851
|
-
{ value: 'image/x-portable-graymap', label: 'Greymap Image' },
|
|
852
|
-
{ value: 'text/html', label: 'HTML' },
|
|
853
|
-
{ value: 'application/vnd.oasis.opendocument.text-web', label: 'HTML Document Template' },
|
|
854
|
-
{ value: 'image/x-raw-hasselblad', label: 'Hasselblad RAW Image' },
|
|
855
|
-
{ value: 'image/ief', label: 'IEF Image' },
|
|
856
|
-
{ value: 'image/jp2', label: 'JPEG 2000 Image' },
|
|
857
|
-
{ value: 'image/jpeg', label: 'JPEG Image' },
|
|
858
|
-
{ value: 'application/json', label: 'JSON' },
|
|
859
|
-
{ value: 'application/java-archive', label: 'Java Archive' },
|
|
860
|
-
{ value: 'application/java', label: 'Java Class' },
|
|
861
|
-
{ value: 'text/x-jsp', label: 'Java Server Page' },
|
|
862
|
-
{ value: 'text/x-java-source', label: 'Java Source File' },
|
|
863
|
-
{ value: 'application/x-javascript', label: 'JavaScript' },
|
|
864
|
-
{ value: 'image/x-raw-kodak', label: 'Kodak RAW Image' },
|
|
865
|
-
{ value: 'application/x-latex', label: 'LaTeX' },
|
|
866
|
-
{ value: 'image/x-raw-leica', label: 'Leica RAW Image' },
|
|
867
|
-
{ value: 'audio/mpeg', label: 'MPEG Audio' },
|
|
868
|
-
{ value: 'video/mp2t', label: 'MPEG Transport Stream' },
|
|
869
|
-
{ value: 'video/mpeg', label: 'MPEG Video' },
|
|
870
|
-
{ value: 'video/mpeg2', label: 'MPEG2 Video' },
|
|
871
|
-
{ value: 'audio/mp4', label: 'MPEG4 Audio' },
|
|
872
|
-
{ value: 'video/mp4', label: 'MPEG4 Video' },
|
|
873
|
-
{ value: 'video/x-m4v', label: 'MPEG4 Video (m4v)' },
|
|
874
|
-
{ value: 'video/x-ms-asf', label: 'MS ASF Streaming Video' },
|
|
875
|
-
{ value: 'video/x-msvideo', label: 'MS Video' },
|
|
876
|
-
{ value: 'audio/x-ms-wma', label: 'MS WMA Streaming Audio' },
|
|
877
|
-
{ value: 'video/x-ms-wmv', label: 'MS WMV Streaming Video' },
|
|
878
|
-
{ value: 'application/x-troff-man', label: 'Man Page' },
|
|
879
|
-
{ value: 'text/x-markdown', label: 'Markdown' },
|
|
880
|
-
{ value: 'text/mediawiki', label: 'MediaWiki Markup' },
|
|
881
|
-
{ value: 'application/vnd.ms-excel', label: 'Microsoft Excel' },
|
|
882
|
-
{ value: 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet', label: 'Microsoft Excel 2007' },
|
|
883
|
-
{ value: 'application/vnd.ms-excel.addin.macroenabled.12', label: 'Microsoft Excel 2007 add-in' },
|
|
884
|
-
{ value: 'application/vnd.ms-excel.sheet.binary.macroenabled.12', label: 'Microsoft Excel 2007 binary workbook' },
|
|
885
|
-
{ value: 'application/vnd.ms-excel.sheet.macroenabled.12', label: 'Microsoft Excel 2007 macro-enabled workbook' },
|
|
886
|
-
{ value: 'application/vnd.ms-excel.template.macroenabled.12', label: 'Microsoft Excel 2007 macro-enabled workbook template' },
|
|
887
|
-
{ value: 'application/vnd.openxmlformats-officedocument.spreadsheetml.template', label: 'Microsoft Excel template 2007' },
|
|
888
|
-
{ value: 'application/vnd.ms-outlook', label: 'Microsoft Outlook Message' },
|
|
889
|
-
{ value: 'application/vnd.ms-powerpoint', label: 'Microsoft PowerPoint' },
|
|
890
|
-
{ value: 'application/vnd.openxmlformats-officedocument.presentationml.presentation', label: 'Microsoft PowerPoint 2007' },
|
|
891
|
-
{ value: 'application/vnd.ms-powerpoint.addin.macroenabled.12', label: 'Microsoft PowerPoint 2007 add-in' },
|
|
892
|
-
{ value: 'application/vnd.ms-powerpoint.presentation.macroenabled.12', label: 'Microsoft PowerPoint 2007 macro-enabled presentation' },
|
|
893
|
-
{ value: 'application/vnd.ms-powerpoint.template.macroenabled.12', label: 'Microsoft PowerPoint 2007 macro-enabled presentation template' },
|
|
894
|
-
{ value: 'application/vnd.ms-powerpoint.slide.macroenabled.12', label: 'Microsoft PowerPoint 2007 macro-enabled slide' },
|
|
895
|
-
{ value: 'application/vnd.ms-powerpoint.slideshow.macroenabled.12', label: 'Microsoft PowerPoint 2007 macro-enabled slide show' },
|
|
896
|
-
{ value: 'application/vnd.openxmlformats-officedocument.presentationml.slide', label: 'Microsoft PowerPoint 2007 slide' },
|
|
897
|
-
{ value: 'application/vnd.openxmlformats-officedocument.presentationml.slideshow', label: 'Microsoft PowerPoint 2007 slide show' },
|
|
898
|
-
{ value: 'application/vnd.openxmlformats-officedocument.presentationml.template', label: 'Microsoft PowerPoint 2007 template' },
|
|
899
|
-
{ value: 'application/vnd.ms-project', label: 'Microsoft Project' },
|
|
900
|
-
{ value: 'application/vnd.visio', label: 'Microsoft Visio' },
|
|
901
|
-
{ value: 'application/vnd.visio2013', label: 'Microsoft Visio 2013' },
|
|
902
|
-
{ value: 'application/vnd.ms-visio.drawing.macroenabled.main+xml', label: 'Microsoft Visio macro-enabled drawing' },
|
|
903
|
-
{ value: 'application/vnd.ms-visio.stencil.macroenabled.main+xml', label: 'Microsoft Visio macro-enabled stencil' },
|
|
904
|
-
{ value: 'application/vnd.ms-visio.template.macroenabled.main+xml', label: 'Microsoft Visio macro-enabled template' },
|
|
905
|
-
{ value: 'application/vnd.ms-visio.stencil.main+xml', label: 'Microsoft Visio stencil' },
|
|
906
|
-
{ value: 'application/vnd.ms-visio.template.main+xml', label: 'Microsoft Visio template' },
|
|
907
|
-
{ value: 'application/msword', label: 'Microsoft Word' },
|
|
908
|
-
{ value: 'application/vnd.openxmlformats-officedocument.wordprocessingml.document', label: 'Microsoft Word 2007' },
|
|
909
|
-
{ value: 'application/vnd.ms-word.document.macroenabled.12', label: 'Microsoft Word 2007 macro-enabled document' },
|
|
910
|
-
{ value: 'application/vnd.ms-word.template.macroenabled.12', label: 'Microsoft Word 2007 macro-enabled document template' },
|
|
911
|
-
{ value: 'application/vnd.openxmlformats-officedocument.wordprocessingml.template', label: 'Microsoft Word 2007 template' },
|
|
912
|
-
{ value: 'image/x-raw-minolta', label: 'Minolta RAW Image' },
|
|
913
|
-
{ value: 'image/x-raw-nikon', label: 'Nikon RAW Image' },
|
|
914
|
-
{ value: 'audio/ogg', label: 'Ogg Audio' },
|
|
915
|
-
{ value: 'application/ogg', label: 'Ogg Multiplex' },
|
|
916
|
-
{ value: 'video/ogg', label: 'Ogg Video' },
|
|
917
|
-
{ value: 'audio/vorbis', label: 'Ogg Vorbis Audio' },
|
|
918
|
-
{ value: 'image/x-raw-olympus', label: 'Olympus RAW Image' },
|
|
919
|
-
{ value: 'application/vnd.oasis.opendocument.chart', label: 'OpenDocument Chart' },
|
|
920
|
-
{ value: 'application/vnd.oasis.opendocument.database', label: 'OpenDocument Database' },
|
|
921
|
-
{ value: 'application/vnd.oasis.opendocument.graphics', label: 'OpenDocument Drawing' },
|
|
922
|
-
{ value: 'application/vnd.oasis.opendocument.graphics-template', label: 'OpenDocument Drawing Template' },
|
|
923
|
-
{ value: 'application/vnd.oasis.opendocument.formula', label: 'OpenDocument Formula' },
|
|
924
|
-
{ value: 'application/vnd.oasis.opendocument.image', label: 'OpenDocument Image' },
|
|
925
|
-
{ value: 'application/vnd.oasis.opendocument.text-master', label: 'OpenDocument Master Document' },
|
|
926
|
-
{ value: 'application/vnd.oasis.opendocument.presentation', label: 'OpenDocument Presentation' },
|
|
927
|
-
{ value: 'application/vnd.oasis.opendocument.presentation-template', label: 'OpenDocument Presentation Template' },
|
|
928
|
-
{ value: 'application/vnd.oasis.opendocument.spreadsheet', label: 'OpenDocument Spreadsheet' },
|
|
929
|
-
{ value: 'application/vnd.oasis.opendocument.spreadsheet-template', label: 'OpenDocument Spreadsheet Template' },
|
|
930
|
-
{ value: 'application/vnd.oasis.opendocument.text', label: 'OpenDocument Text (OpenOffice 2.0)' },
|
|
931
|
-
{ value: 'application/vnd.oasis.opendocument.text-template', label: 'OpenDocument Text Template' },
|
|
932
|
-
{ value: 'application/vnd.sun.xml.calc', label: 'OpenOffice 1.0/StarOffice6.0 Calc 6.0' },
|
|
933
|
-
{ value: 'application/vnd.sun.xml.calc.template', label: 'OpenOffice 1.0/StarOffice6.0 Calc 6.0 Template' },
|
|
934
|
-
{ value: 'application/vnd.sun.xml.draw', label: 'OpenOffice 1.0/StarOffice6.0 Draw 6.0' },
|
|
935
|
-
{ value: 'application/vnd.sun.xml.impress', label: 'OpenOffice 1.0/StarOffice6.0 Impress 6.0' },
|
|
936
|
-
{ value: 'application/vnd.sun.xml.impress.template', label: 'OpenOffice 1.0/StarOffice6.0 Impress 6.0 Template' },
|
|
937
|
-
{ value: 'application/vnd.sun.xml.writer', label: 'OpenOffice 1.0/StarOffice6.0 Writer 6.0' },
|
|
938
|
-
{ value: 'application/vnd.sun.xml.writer.template', label: 'OpenOffice 1.0/StarOffice6.0 Writer 6.0 Template' },
|
|
939
|
-
{ value: 'image/png', label: 'PNG Image' },
|
|
940
|
-
{ value: 'image/x-raw-panasonic', label: 'Panasonic RAW Image' },
|
|
941
|
-
{ value: 'image/x-raw-pentax', label: 'Pentax RAW Image' },
|
|
942
|
-
{ value: 'image/x-portable-pixmap', label: 'Pixmap Image' },
|
|
943
|
-
{ value: 'text/plain', label: 'Plain Text' },
|
|
944
|
-
{ value: 'image/x-portable-bitmap', label: 'Portable Bitmap' },
|
|
945
|
-
{ value: 'application/postscript', label: 'PostScript' },
|
|
946
|
-
{ value: 'application/remote-printing', label: 'Printer Text File' },
|
|
947
|
-
{ value: 'video/quicktime', label: 'Quicktime Video' },
|
|
948
|
-
{ value: 'video/x-rad-screenplay', label: 'RAD Screen Display' },
|
|
949
|
-
{ value: 'application/x-rar-compressed', label: 'RAR Archive' },
|
|
950
|
-
{ value: 'image/x-raw-red', label: 'RED RAW Image' },
|
|
951
|
-
{ value: 'image/x-rgb', label: 'RGB Image' },
|
|
952
|
-
{ value: 'application/rss+xml', label: 'RSS' },
|
|
953
|
-
{ value: 'image/x-cmu-raster', label: 'Raster Image' },
|
|
954
|
-
{ value: 'text/richtext', label: 'Rich Text' },
|
|
955
|
-
{ value: 'application/rtf', label: 'Rich Text Format' },
|
|
956
|
-
{ value: 'video/x-sgi-movie', label: 'SGI Video' },
|
|
957
|
-
{ value: 'text/sgml', label: 'SGML (Human Readable)' },
|
|
958
|
-
{ value: 'application/sgml', label: 'SGML (Machine Readable)' },
|
|
959
|
-
{ value: 'image/svg+xml', label: 'Scalable Vector Graphics Image' },
|
|
960
|
-
{ value: 'application/x-sh', label: 'Shell Script' },
|
|
961
|
-
{ value: 'application/x-shockwave-flash', label: 'Shockwave Flash' },
|
|
962
|
-
{ value: 'image/x-raw-sigma', label: 'Sigma RAW Image' },
|
|
963
|
-
{ value: 'image/x-raw-sony', label: 'Sony RAW Image' },
|
|
964
|
-
{ value: 'application/vnd.stardivision.chart', label: 'StarChart 5.x' },
|
|
965
|
-
{ value: 'application/vnd.stardivision.calc', label: 'StarCalc 5.x' },
|
|
966
|
-
{ value: 'application/vnd.stardivision.draw', label: 'StarDraw 5.x' },
|
|
967
|
-
{ value: 'application/vnd.stardivision.impress', label: 'StarImpress 5.x' },
|
|
968
|
-
{ value: 'application/vnd.stardivision.impress-packed', label: 'StarImpress Packed 5.x' },
|
|
969
|
-
{ value: 'application/vnd.stardivision.math', label: 'StarMath 5.x' },
|
|
970
|
-
{ value: 'application/vnd.stardivision.writer', label: 'StarWriter 5.x' },
|
|
971
|
-
{ value: 'application/vnd.stardivision.writer-global', label: 'StarWriter 5.x global' },
|
|
972
|
-
{ value: 'text/css', label: 'Style Sheet' },
|
|
973
|
-
{ value: 'image/tiff', label: 'TIFF Image' },
|
|
974
|
-
{ value: 'text/tab-separated-values', label: 'Tab Separated Values' },
|
|
975
|
-
{ value: 'application/x-tar', label: 'Tarball' },
|
|
976
|
-
{ value: 'application/x-tex', label: 'Tex' },
|
|
977
|
-
{ value: 'application/x-texinfo', label: 'Tex Info' },
|
|
978
|
-
{ value: 'x-world/x-vrml', label: 'VRML' },
|
|
979
|
-
{ value: 'audio/x-wav', label: 'WAV Audio' },
|
|
980
|
-
{ value: 'video/webm', label: 'WebM Video' },
|
|
981
|
-
{ value: 'application/wordperfect', label: 'WordPerfect' },
|
|
982
|
-
{ value: 'image/x-xbitmap', label: 'XBitmap Image' },
|
|
983
|
-
{ value: 'application/xhtml+xml', label: 'XHTML' },
|
|
984
|
-
{ value: 'text/xml', label: 'XML' },
|
|
985
|
-
{ value: 'image/x-xpixmap', label: 'XPixmap Image' },
|
|
986
|
-
{ value: 'image/x-xwindowdump', label: 'XWindow Dump' },
|
|
987
|
-
{ value: 'application/x-compress', label: 'Z Compress' },
|
|
988
|
-
{ value: 'application/zip', label: 'ZIP' },
|
|
989
|
-
{ value: 'text/calendar', label: 'iCalendar File' }
|
|
990
|
-
];
|
|
991
|
-
|
|
992
|
-
/*!
|
|
993
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
994
|
-
*
|
|
995
|
-
* Alfresco Example Content Application
|
|
996
|
-
*
|
|
997
|
-
* This file is part of the Alfresco Example Content Application.
|
|
998
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
999
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
1000
|
-
* provided under the following open source license terms:
|
|
1001
|
-
*
|
|
1002
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
1003
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
1004
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
1005
|
-
* (at your option) any later version.
|
|
1006
|
-
*
|
|
1007
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
1008
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
1009
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
1010
|
-
* GNU Lesser General Public License for more details.
|
|
1011
|
-
*
|
|
1012
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
1013
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
1014
|
-
*/
|
|
1015
|
-
class AppSettingsService {
|
|
1016
|
-
constructor() {
|
|
1017
|
-
this.appConfig = inject(AppConfigService);
|
|
1018
|
-
}
|
|
1019
|
-
/**
|
|
1020
|
-
* Get the application copyright text from the app settings.
|
|
1021
|
-
*/
|
|
1022
|
-
get appCopyright() {
|
|
1023
|
-
return this.appConfig.get('application.copyright', '');
|
|
1024
|
-
}
|
|
1025
|
-
/**
|
|
1026
|
-
* Get the AOS (Alfresco Office Services) host URL from the app settings.
|
|
1027
|
-
*/
|
|
1028
|
-
get aosHost() {
|
|
1029
|
-
return this.appConfig.get('aosHost');
|
|
1030
|
-
}
|
|
1031
|
-
/**
|
|
1032
|
-
* Get the default landing page from the app settings.
|
|
1033
|
-
* Default value: `/personal-files`.
|
|
1034
|
-
*/
|
|
1035
|
-
get landingPage() {
|
|
1036
|
-
return this.appConfig.get('landingPage', '/personal-files');
|
|
1037
|
-
}
|
|
1038
|
-
/**
|
|
1039
|
-
* Get the list of mime types from the app settings.
|
|
1040
|
-
*/
|
|
1041
|
-
get mimeTypes() {
|
|
1042
|
-
return this.appConfig.get('mimeTypes', DefaultMimeTypes);
|
|
1043
|
-
}
|
|
1044
|
-
/**
|
|
1045
|
-
* Get the application name from the app settings.
|
|
1046
|
-
*/
|
|
1047
|
-
get appName() {
|
|
1048
|
-
return this.appConfig.get('application.name', 'Alfresco Content Application');
|
|
1049
|
-
}
|
|
1050
|
-
/**
|
|
1051
|
-
* Get the application version from the app settings.
|
|
1052
|
-
*/
|
|
1053
|
-
get appVersion() {
|
|
1054
|
-
return this.appConfig.get('application.version', '1.0.0');
|
|
1055
|
-
}
|
|
1056
|
-
/**
|
|
1057
|
-
* Get the application logo URL from the app settings.
|
|
1058
|
-
*/
|
|
1059
|
-
get appLogoUrl() {
|
|
1060
|
-
return this.appConfig.get('application.logo', 'assets/images/app-logo.svg');
|
|
1061
|
-
}
|
|
1062
|
-
/**
|
|
1063
|
-
* Get the custom CSS stylesheet path from the app settings.
|
|
1064
|
-
*/
|
|
1065
|
-
get customCssPath() {
|
|
1066
|
-
return this.appConfig.get('customCssPath', '');
|
|
1067
|
-
}
|
|
1068
|
-
/**
|
|
1069
|
-
* Get the custom web font path from the app settings.
|
|
1070
|
-
*/
|
|
1071
|
-
get webFontPath() {
|
|
1072
|
-
return this.appConfig.get('webFontPath', '');
|
|
1073
|
-
}
|
|
1074
|
-
/**
|
|
1075
|
-
* Get the base share URL from the app settings.
|
|
1076
|
-
*/
|
|
1077
|
-
get baseShareUrl() {
|
|
1078
|
-
let result = this.appConfig.get('baseShareUrl', '');
|
|
1079
|
-
if (!result.endsWith('/')) {
|
|
1080
|
-
result += '/';
|
|
1081
|
-
}
|
|
1082
|
-
return result;
|
|
1083
|
-
}
|
|
1084
|
-
/**
|
|
1085
|
-
* Get the viewer close button position from the app settings.
|
|
1086
|
-
*/
|
|
1087
|
-
get viewerCloseButtonPosition() {
|
|
1088
|
-
return this.appConfig.get('viewer.closeButtonPosition', CloseButtonPosition.Right);
|
|
1089
|
-
}
|
|
1090
|
-
/**
|
|
1091
|
-
* Get the viewer max retries from the app settings.
|
|
1092
|
-
*/
|
|
1093
|
-
get viewerMaxRetries() {
|
|
1094
|
-
return this.appConfig.get('viewer.maxRetries', 1);
|
|
1095
|
-
}
|
|
1096
|
-
/**
|
|
1097
|
-
* Enabled state of the comment feature for upload dialog
|
|
1098
|
-
*/
|
|
1099
|
-
get uploadAllowComments() {
|
|
1100
|
-
return this.appConfig.get('adf-version-manager.allowComments', true);
|
|
1101
|
-
}
|
|
1102
|
-
/**
|
|
1103
|
-
* Enabled state of the download feature for upload dialog
|
|
1104
|
-
*/
|
|
1105
|
-
get uploadAllowDownload() {
|
|
1106
|
-
return this.appConfig.get('adf-version-manager.allowDownload', true);
|
|
1107
|
-
}
|
|
1108
|
-
/**
|
|
1109
|
-
* Gets the enablement of the file auto tryDownload feature from the app settings.
|
|
1110
|
-
*/
|
|
1111
|
-
get autoDownloadEnabled() {
|
|
1112
|
-
return this.appConfig.get('viewer.enableFileAutoDownload', true);
|
|
1113
|
-
}
|
|
1114
|
-
/**
|
|
1115
|
-
* Gets the file auto tryDownload size threshold in MB from the app settings.
|
|
1116
|
-
*/
|
|
1117
|
-
get authDownloadThreshold() {
|
|
1118
|
-
return this.appConfig.get('viewer.fileAutoDownloadSizeThresholdInMB', 15);
|
|
1119
|
-
}
|
|
1120
|
-
}
|
|
1121
|
-
AppSettingsService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: AppSettingsService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
1122
|
-
AppSettingsService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: AppSettingsService, providedIn: 'root' });
|
|
1123
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: AppSettingsService, decorators: [{
|
|
1124
|
-
type: Injectable,
|
|
1125
|
-
args: [{ providedIn: 'root' }]
|
|
1126
|
-
}] });
|
|
1127
|
-
|
|
1128
|
-
class UserProfileService {
|
|
1129
|
-
constructor() {
|
|
1130
|
-
this.api = inject(AlfrescoApiService);
|
|
1131
|
-
this.groupService = inject(GroupService);
|
|
1132
|
-
this.userProfile = new BehaviorSubject(null);
|
|
1133
|
-
this.userProfile$ = this.userProfile.asObservable();
|
|
1134
|
-
}
|
|
1135
|
-
get peopleApi() {
|
|
1136
|
-
return new PeopleApi(this.api.getInstance());
|
|
1137
|
-
}
|
|
1138
|
-
/**
|
|
1139
|
-
* Load user profile.
|
|
1140
|
-
*/
|
|
1141
|
-
loadUserProfile() {
|
|
1142
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
1143
|
-
const groupsEntries = yield this.groupService.listAllGroupMembershipsForPerson('-me-', { maxItems: 250 });
|
|
1144
|
-
const groups = [];
|
|
1145
|
-
if (groupsEntries) {
|
|
1146
|
-
groups.push(...groupsEntries.map((obj) => obj.entry));
|
|
1147
|
-
}
|
|
1148
|
-
const { entry: user } = yield this.peopleApi.getPerson('-me-');
|
|
1149
|
-
const id = user.id;
|
|
1150
|
-
const firstName = user.firstName || '';
|
|
1151
|
-
const lastName = user.lastName || '';
|
|
1152
|
-
const userName = `${firstName} ${lastName}`;
|
|
1153
|
-
const initials = [firstName[0], lastName[0]].join('');
|
|
1154
|
-
const email = user.email;
|
|
1155
|
-
const capabilities = user.capabilities;
|
|
1156
|
-
const isAdmin = capabilities ? capabilities.isAdmin : true;
|
|
1157
|
-
const profile = {
|
|
1158
|
-
firstName,
|
|
1159
|
-
lastName,
|
|
1160
|
-
userName,
|
|
1161
|
-
initials,
|
|
1162
|
-
isAdmin,
|
|
1163
|
-
id,
|
|
1164
|
-
groups,
|
|
1165
|
-
email
|
|
1166
|
-
};
|
|
1167
|
-
this.userProfile.next(profile);
|
|
1168
|
-
return profile;
|
|
1169
|
-
});
|
|
1170
|
-
}
|
|
1171
|
-
}
|
|
1172
|
-
UserProfileService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: UserProfileService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
1173
|
-
UserProfileService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: UserProfileService, providedIn: 'root' });
|
|
1174
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: UserProfileService, decorators: [{
|
|
1175
|
-
type: Injectable,
|
|
1176
|
-
args: [{ providedIn: 'root' }]
|
|
1177
|
-
}] });
|
|
1178
|
-
|
|
1179
|
-
// After moving shell to ADF to core, AppService will implement ShellAppService
|
|
1180
|
-
class AppService {
|
|
1181
|
-
/**
|
|
1182
|
-
* Whether `withCredentials` mode is enabled.
|
|
1183
|
-
* Usually means that `Kerberos` mode is used.
|
|
1184
|
-
*/
|
|
1185
|
-
get withCredentials() {
|
|
1186
|
-
return this.config.get('auth.withCredentials', false);
|
|
1187
|
-
}
|
|
1188
|
-
constructor(preferencesService, authenticationService, store, router, activatedRoute, config, pageTitle, alfrescoApiService, uploadService, routerExtensionService, contentApi, sharedLinksApiService, overlayContainer, searchQueryBuilderService, acaMobileAppSwitcherService, appSettingsService, userProfileService) {
|
|
1189
|
-
this.preferencesService = preferencesService;
|
|
1190
|
-
this.authenticationService = authenticationService;
|
|
1191
|
-
this.store = store;
|
|
1192
|
-
this.router = router;
|
|
1193
|
-
this.activatedRoute = activatedRoute;
|
|
1194
|
-
this.config = config;
|
|
1195
|
-
this.pageTitle = pageTitle;
|
|
1196
|
-
this.alfrescoApiService = alfrescoApiService;
|
|
1197
|
-
this.uploadService = uploadService;
|
|
1198
|
-
this.routerExtensionService = routerExtensionService;
|
|
1199
|
-
this.contentApi = contentApi;
|
|
1200
|
-
this.sharedLinksApiService = sharedLinksApiService;
|
|
1201
|
-
this.overlayContainer = overlayContainer;
|
|
1202
|
-
this.acaMobileAppSwitcherService = acaMobileAppSwitcherService;
|
|
1203
|
-
this.appSettingsService = appSettingsService;
|
|
1204
|
-
this.userProfileService = userProfileService;
|
|
1205
|
-
this.notificationService = inject(NotificationService);
|
|
1206
|
-
this.matDialog = inject(MatDialog);
|
|
1207
|
-
this.pageHeading = new BehaviorSubject('');
|
|
1208
|
-
/** @deprecated page title is updated automatically */
|
|
1209
|
-
this.pageHeading$ = this.pageHeading.asObservable();
|
|
1210
|
-
this.appNavNarMode$ = new BehaviorSubject('expanded');
|
|
1211
|
-
this.toggleAppNavBar$ = new Subject();
|
|
1212
|
-
this.hideSidenavConditions = ['/preview/'];
|
|
1213
|
-
this.minimizeSidenavConditions = ['search'];
|
|
1214
|
-
this.onDestroy$ = new Subject();
|
|
1215
|
-
this.ready = new BehaviorSubject(this.authenticationService.isLoggedIn() || this.withCredentials);
|
|
1216
|
-
this.ready$ = this.ready.asObservable();
|
|
1217
|
-
this.authenticationService.onLogin.subscribe(() => {
|
|
1218
|
-
this.ready.next(true);
|
|
1219
|
-
this.preferencesService.setStoragePrefix(this.authenticationService.getUsername());
|
|
1220
|
-
});
|
|
1221
|
-
this.authenticationService.onLogout.subscribe(() => {
|
|
1222
|
-
searchQueryBuilderService.resetToDefaults();
|
|
1223
|
-
acaMobileAppSwitcherService.clearSessionExpireTime();
|
|
1224
|
-
acaMobileAppSwitcherService.closeDialog();
|
|
1225
|
-
});
|
|
1226
|
-
this.router.events
|
|
1227
|
-
.pipe(filter((event) => event instanceof ActivationEnd && event.snapshot.children.length === 0), map((event) => { var _a, _b, _c; return (_c = (_b = (_a = event.snapshot) === null || _a === void 0 ? void 0 : _a.data) === null || _b === void 0 ? void 0 : _b.title) !== null && _c !== void 0 ? _c : ''; }))
|
|
1228
|
-
.subscribe((title) => {
|
|
1229
|
-
this.pageHeading.next(title);
|
|
1230
|
-
this.pageTitle.setTitle(title);
|
|
1231
|
-
});
|
|
1232
|
-
}
|
|
1233
|
-
ngOnDestroy() {
|
|
1234
|
-
this.onDestroy$.next(true);
|
|
1235
|
-
this.onDestroy$.complete();
|
|
1236
|
-
}
|
|
1237
|
-
init() {
|
|
1238
|
-
this.alfrescoApiService.getInstance().on('error', (error) => {
|
|
1239
|
-
var _a, _b;
|
|
1240
|
-
if (error.status === 401 && !this.alfrescoApiService.isExcludedErrorListener((_b = (_a = error === null || error === void 0 ? void 0 : error.response) === null || _a === void 0 ? void 0 : _a.req) === null || _b === void 0 ? void 0 : _b.url)) {
|
|
1241
|
-
if (!this.authenticationService.isLoggedIn()) {
|
|
1242
|
-
this.matDialog.closeAll();
|
|
1243
|
-
let redirectUrl = this.activatedRoute.snapshot.queryParams['redirectUrl'];
|
|
1244
|
-
if (!redirectUrl) {
|
|
1245
|
-
redirectUrl = this.router.url;
|
|
1246
|
-
}
|
|
1247
|
-
this.router.navigate(['/login'], {
|
|
1248
|
-
queryParams: { redirectUrl }
|
|
1249
|
-
});
|
|
1250
|
-
}
|
|
1251
|
-
}
|
|
1252
|
-
});
|
|
1253
|
-
this.loadCustomCss();
|
|
1254
|
-
this.loadCustomWebFont();
|
|
1255
|
-
const { router } = this;
|
|
1256
|
-
this.router.events.pipe(filter((event) => event instanceof ActivationEnd && event.snapshot.children.length === 0)).subscribe(() => {
|
|
1257
|
-
this.store.dispatch(new SetCurrentUrlAction(router.url));
|
|
1258
|
-
});
|
|
1259
|
-
this.router.events.pipe(filter((event) => event instanceof NavigationStart)).subscribe(() => {
|
|
1260
|
-
this.store.dispatch(new ResetSelectionAction());
|
|
1261
|
-
});
|
|
1262
|
-
this.routerExtensionService.mapExtensionRoutes();
|
|
1263
|
-
this.uploadService.fileUploadError.subscribe((error) => this.onFileUploadedError(error));
|
|
1264
|
-
this.sharedLinksApiService.error.subscribe((err) => {
|
|
1265
|
-
if (err === null || err === void 0 ? void 0 : err.message) {
|
|
1266
|
-
this.notificationService.showError(err.message);
|
|
1267
|
-
}
|
|
1268
|
-
});
|
|
1269
|
-
this.ready$.subscribe((isReady) => {
|
|
1270
|
-
if (isReady) {
|
|
1271
|
-
this.loadRepositoryStatus();
|
|
1272
|
-
this.loadUserProfile();
|
|
1273
|
-
setTimeout(() => {
|
|
1274
|
-
this.openMobileAppDialog();
|
|
1275
|
-
});
|
|
1276
|
-
}
|
|
1277
|
-
});
|
|
1278
|
-
this.overlayContainer.getContainerElement().setAttribute('role', 'region');
|
|
1279
|
-
}
|
|
1280
|
-
setAppNavbarMode(mode) {
|
|
1281
|
-
this.appNavNarMode$.next(mode);
|
|
1282
|
-
this.preferencesService.set('expandedSidenav', mode === 'expanded');
|
|
1283
|
-
}
|
|
1284
|
-
loadRepositoryStatus() {
|
|
1285
|
-
this.contentApi.getRepositoryInformation().subscribe((response) => {
|
|
1286
|
-
var _a;
|
|
1287
|
-
if ((_a = response === null || response === void 0 ? void 0 : response.entry) === null || _a === void 0 ? void 0 : _a.repository) {
|
|
1288
|
-
this.store.dispatch(new SetRepositoryInfoAction(response.entry.repository));
|
|
1289
|
-
}
|
|
1290
|
-
});
|
|
1291
|
-
}
|
|
1292
|
-
loadUserProfile() {
|
|
1293
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
1294
|
-
const profile = yield this.userProfileService.loadUserProfile();
|
|
1295
|
-
this.store.dispatch(new SetUserProfileAction(profile));
|
|
1296
|
-
});
|
|
1297
|
-
}
|
|
1298
|
-
onFileUploadedError(error) {
|
|
1299
|
-
var _a, _b, _c, _d, _e;
|
|
1300
|
-
let message = 'APP.MESSAGES.UPLOAD.ERROR.GENERIC';
|
|
1301
|
-
if (((_a = error === null || error === void 0 ? void 0 : error.error) === null || _a === void 0 ? void 0 : _a.status) === 403) {
|
|
1302
|
-
message = 'APP.MESSAGES.UPLOAD.ERROR.403';
|
|
1303
|
-
}
|
|
1304
|
-
if (((_b = error === null || error === void 0 ? void 0 : error.error) === null || _b === void 0 ? void 0 : _b.status) === 404) {
|
|
1305
|
-
message = 'APP.MESSAGES.UPLOAD.ERROR.404';
|
|
1306
|
-
}
|
|
1307
|
-
if (((_c = error === null || error === void 0 ? void 0 : error.error) === null || _c === void 0 ? void 0 : _c.status) === 409) {
|
|
1308
|
-
message = 'APP.MESSAGES.UPLOAD.ERROR.CONFLICT';
|
|
1309
|
-
}
|
|
1310
|
-
if (((_d = error === null || error === void 0 ? void 0 : error.error) === null || _d === void 0 ? void 0 : _d.status) === 500) {
|
|
1311
|
-
message = 'APP.MESSAGES.UPLOAD.ERROR.500';
|
|
1312
|
-
}
|
|
1313
|
-
if (((_e = error === null || error === void 0 ? void 0 : error.error) === null || _e === void 0 ? void 0 : _e.status) === 504) {
|
|
1314
|
-
message = 'APP.MESSAGES.UPLOAD.ERROR.504';
|
|
1315
|
-
}
|
|
1316
|
-
this.notificationService.showError(message);
|
|
1317
|
-
}
|
|
1318
|
-
loadCustomCss() {
|
|
1319
|
-
const customCssPath = this.appSettingsService.customCssPath;
|
|
1320
|
-
if (customCssPath) {
|
|
1321
|
-
this.createLink(customCssPath);
|
|
1322
|
-
}
|
|
1323
|
-
}
|
|
1324
|
-
loadCustomWebFont() {
|
|
1325
|
-
const webFontPath = this.appSettingsService.webFontPath;
|
|
1326
|
-
if (webFontPath) {
|
|
1327
|
-
this.createLink(webFontPath);
|
|
1328
|
-
}
|
|
1329
|
-
}
|
|
1330
|
-
createLink(url) {
|
|
1331
|
-
const cssLinkElement = document.createElement('link');
|
|
1332
|
-
cssLinkElement.setAttribute('rel', 'stylesheet');
|
|
1333
|
-
cssLinkElement.setAttribute('type', 'text/css');
|
|
1334
|
-
cssLinkElement.setAttribute('href', url);
|
|
1335
|
-
document.head.appendChild(cssLinkElement);
|
|
1336
|
-
}
|
|
1337
|
-
openMobileAppDialog() {
|
|
1338
|
-
const isMobileSwitchEnabled = this.config.get('mobileAppSwitch.enabled', false);
|
|
1339
|
-
if (isMobileSwitchEnabled) {
|
|
1340
|
-
this.acaMobileAppSwitcherService.resolveExistenceOfDialog();
|
|
1341
|
-
}
|
|
1342
|
-
else {
|
|
1343
|
-
this.acaMobileAppSwitcherService.clearSessionExpireTime();
|
|
1344
|
-
}
|
|
1345
|
-
}
|
|
1346
|
-
}
|
|
1347
|
-
AppService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: AppService, deps: [{ token: i1.UserPreferencesService }, { token: i1.AuthenticationService }, { token: i1$2.Store }, { token: i3.Router }, { token: i3.ActivatedRoute }, { token: i1.AppConfigService }, { token: i1.PageTitleService }, { token: i4.AlfrescoApiService }, { token: i4.UploadService }, { token: RouterExtensionService }, { token: ContentApiService }, { token: i4.SharedLinksApiService }, { token: i7.OverlayContainer }, { token: i4.SearchQueryBuilderService }, { token: AcaMobileAppSwitcherService }, { token: AppSettingsService }, { token: UserProfileService }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
1348
|
-
AppService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: AppService, providedIn: 'root' });
|
|
1349
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: AppService, decorators: [{
|
|
1350
|
-
type: Injectable,
|
|
1351
|
-
args: [{
|
|
1352
|
-
providedIn: 'root'
|
|
1353
|
-
}]
|
|
1354
|
-
}], ctorParameters: function () { return [{ type: i1.UserPreferencesService }, { type: i1.AuthenticationService }, { type: i1$2.Store }, { type: i3.Router }, { type: i3.ActivatedRoute }, { type: i1.AppConfigService }, { type: i1.PageTitleService }, { type: i4.AlfrescoApiService }, { type: i4.UploadService }, { type: RouterExtensionService }, { type: ContentApiService }, { type: i4.SharedLinksApiService }, { type: i7.OverlayContainer }, { type: i4.SearchQueryBuilderService }, { type: AcaMobileAppSwitcherService }, { type: AppSettingsService }, { type: UserProfileService }]; } });
|
|
1355
|
-
|
|
1356
|
-
/*!
|
|
1357
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
1358
|
-
*
|
|
1359
|
-
* Alfresco Example Content Application
|
|
1360
|
-
*
|
|
1361
|
-
* This file is part of the Alfresco Example Content Application.
|
|
1362
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
1363
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
1364
|
-
* provided under the following open source license terms:
|
|
1365
|
-
*
|
|
1366
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
1367
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
1368
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
1369
|
-
* (at your option) any later version.
|
|
1370
|
-
*
|
|
1371
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
1372
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
1373
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
1374
|
-
* GNU Lesser General Public License for more details.
|
|
1375
|
-
*
|
|
1376
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
1377
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
1378
|
-
*/
|
|
1379
|
-
class PageLayoutComponent {
|
|
1380
|
-
constructor(appService) {
|
|
1381
|
-
this.appService = appService;
|
|
1382
|
-
this.hasError = false;
|
|
1383
|
-
this.onDestroy$ = new Subject();
|
|
1384
|
-
this.appNavNarMode$ = appService.appNavNarMode$.pipe(takeUntil(this.onDestroy$));
|
|
1385
|
-
}
|
|
1386
|
-
toggleClick() {
|
|
1387
|
-
this.appService.toggleAppNavBar$.next();
|
|
1388
|
-
}
|
|
1389
|
-
ngOnDestroy() {
|
|
1390
|
-
this.onDestroy$.next(true);
|
|
1391
|
-
this.onDestroy$.complete();
|
|
1392
|
-
}
|
|
1393
|
-
}
|
|
1394
|
-
PageLayoutComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: PageLayoutComponent, deps: [{ token: AppService }], target: i0.ɵɵFactoryTarget.Component });
|
|
1395
|
-
PageLayoutComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: PageLayoutComponent, isStandalone: true, selector: "aca-page-layout", inputs: { hasError: "hasError" }, host: { classAttribute: "aca-page-layout" }, ngImport: i0, template: "<div class=\"aca-content-header\">\n <button *ngIf=\"(appNavNarMode$ | async) === 'collapsed'\"\n mat-icon-button\n class=\"aca-content-header-button\"\n (click)=\"toggleClick()\"\n title=\"{{'APP.TOOLTIPS.EXPAND_NAVIGATION' | translate}}\">\n <mat-icon>keyboard_double_arrow_right</mat-icon>\n </button>\n <ng-content select=\".aca-page-layout-header, aca-page-layout-header\"></ng-content>\n</div>\n\n<ng-container *ngIf=\"hasError\">\n <ng-content select=\".aca-page-layout-error, aca-page-layout-error\"></ng-content>\n</ng-container>\n\n<ng-container *ngIf=\"!hasError\">\n <ng-content select=\".aca-page-layout-content, aca-page-layout-content\"></ng-content>\n</ng-container>\n", styles: [".aca-page-layout{display:flex;flex-direction:column;flex:1;height:100%;overflow:hidden;min-height:0}.aca-page-layout .aca-content-header{background:var(--theme-page-layout-header-background-color);height:96px;padding:0 24px;display:flex;align-items:center}.aca-page-layout .aca-content-header-button{margin-top:-1px}.aca-page-layout .aca-page-layout-header{display:flex;align-items:center;flex:auto;width:100%}.aca-page-layout .aca-page-layout-header .adf-breadcrumb-item{font-size:20px;font-weight:400;letter-spacing:.15px}.aca-page-layout .aca-page-layout-header .aca-toolbar-action button{border-radius:6px}.aca-page-layout .aca-page-layout-content{display:flex;flex-direction:row;flex:1;height:100%;overflow:hidden;border-top:1px solid var(--theme-metadata-property-panel-border-color)}.aca-page-layout .aca-page-layout-error{display:flex;flex-direction:row;flex:1;height:100%;overflow:hidden}.aca-page-layout .aca-main-content{display:flex;flex-direction:column;flex:1;height:100%;overflow:hidden;min-height:0}.aca-page-layout .aca-scrollable,.aca-page-layout .aca-scrollable .aca-main-content{overflow:auto}[dir=rtl] .aca-page-layout .aca-main-content{border-left:1px solid var(--theme-border-color, rgba(0, 0, 0, .07))}[dir=ltr] .aca-page-layout .aca-main-content{border-right:1px solid var(--theme-border-color, rgba(0, 0, 0, .07))}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "pipe", type: i2.AsyncPipe, name: "async" }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i3$2.TranslatePipe, name: "translate" }, { kind: "ngmodule", type: MatButtonModule }, { kind: "component", type: i4$1.MatIconButton, selector: "button[mat-icon-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i5.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }], encapsulation: i0.ViewEncapsulation.None });
|
|
1396
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: PageLayoutComponent, decorators: [{
|
|
1397
|
-
type: Component,
|
|
1398
|
-
args: [{ standalone: true, imports: [CommonModule, TranslateModule, MatButtonModule, MatIconModule], selector: 'aca-page-layout', encapsulation: ViewEncapsulation.None, host: { class: 'aca-page-layout' }, template: "<div class=\"aca-content-header\">\n <button *ngIf=\"(appNavNarMode$ | async) === 'collapsed'\"\n mat-icon-button\n class=\"aca-content-header-button\"\n (click)=\"toggleClick()\"\n title=\"{{'APP.TOOLTIPS.EXPAND_NAVIGATION' | translate}}\">\n <mat-icon>keyboard_double_arrow_right</mat-icon>\n </button>\n <ng-content select=\".aca-page-layout-header, aca-page-layout-header\"></ng-content>\n</div>\n\n<ng-container *ngIf=\"hasError\">\n <ng-content select=\".aca-page-layout-error, aca-page-layout-error\"></ng-content>\n</ng-container>\n\n<ng-container *ngIf=\"!hasError\">\n <ng-content select=\".aca-page-layout-content, aca-page-layout-content\"></ng-content>\n</ng-container>\n", styles: [".aca-page-layout{display:flex;flex-direction:column;flex:1;height:100%;overflow:hidden;min-height:0}.aca-page-layout .aca-content-header{background:var(--theme-page-layout-header-background-color);height:96px;padding:0 24px;display:flex;align-items:center}.aca-page-layout .aca-content-header-button{margin-top:-1px}.aca-page-layout .aca-page-layout-header{display:flex;align-items:center;flex:auto;width:100%}.aca-page-layout .aca-page-layout-header .adf-breadcrumb-item{font-size:20px;font-weight:400;letter-spacing:.15px}.aca-page-layout .aca-page-layout-header .aca-toolbar-action button{border-radius:6px}.aca-page-layout .aca-page-layout-content{display:flex;flex-direction:row;flex:1;height:100%;overflow:hidden;border-top:1px solid var(--theme-metadata-property-panel-border-color)}.aca-page-layout .aca-page-layout-error{display:flex;flex-direction:row;flex:1;height:100%;overflow:hidden}.aca-page-layout .aca-main-content{display:flex;flex-direction:column;flex:1;height:100%;overflow:hidden;min-height:0}.aca-page-layout .aca-scrollable,.aca-page-layout .aca-scrollable .aca-main-content{overflow:auto}[dir=rtl] .aca-page-layout .aca-main-content{border-left:1px solid var(--theme-border-color, rgba(0, 0, 0, .07))}[dir=ltr] .aca-page-layout .aca-main-content{border-right:1px solid var(--theme-border-color, rgba(0, 0, 0, .07))}\n"] }]
|
|
1399
|
-
}], ctorParameters: function () { return [{ type: AppService }]; }, propDecorators: { hasError: [{
|
|
1400
|
-
type: Input
|
|
1401
|
-
}] } });
|
|
1402
|
-
|
|
1403
|
-
/*!
|
|
1404
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
1405
|
-
*
|
|
1406
|
-
* Alfresco Example Content Application
|
|
1407
|
-
*
|
|
1408
|
-
* This file is part of the Alfresco Example Content Application.
|
|
1409
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
1410
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
1411
|
-
* provided under the following open source license terms:
|
|
1412
|
-
*
|
|
1413
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
1414
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
1415
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
1416
|
-
* (at your option) any later version.
|
|
1417
|
-
*
|
|
1418
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
1419
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
1420
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
1421
|
-
* GNU Lesser General Public License for more details.
|
|
1422
|
-
*
|
|
1423
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
1424
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
1425
|
-
*/
|
|
1426
|
-
class PageLayoutModule {
|
|
1427
|
-
}
|
|
1428
|
-
PageLayoutModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: PageLayoutModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
1429
|
-
PageLayoutModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: PageLayoutModule, imports: [PageLayoutComponent, PageLayoutContentComponent, PageLayoutErrorComponent, PageLayoutHeaderComponent], exports: [PageLayoutContentComponent, PageLayoutErrorComponent, PageLayoutHeaderComponent, PageLayoutComponent] });
|
|
1430
|
-
PageLayoutModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: PageLayoutModule, imports: [PageLayoutComponent, PageLayoutContentComponent, PageLayoutErrorComponent, PageLayoutHeaderComponent] });
|
|
1431
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: PageLayoutModule, decorators: [{
|
|
1432
|
-
type: NgModule,
|
|
1433
|
-
args: [{
|
|
1434
|
-
imports: [PageLayoutComponent, PageLayoutContentComponent, PageLayoutErrorComponent, PageLayoutHeaderComponent],
|
|
1435
|
-
exports: [PageLayoutContentComponent, PageLayoutErrorComponent, PageLayoutHeaderComponent, PageLayoutComponent]
|
|
1436
|
-
}]
|
|
1437
|
-
}] });
|
|
1438
|
-
|
|
1439
|
-
/*!
|
|
1440
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
1441
|
-
*
|
|
1442
|
-
* Alfresco Example Content Application
|
|
1443
|
-
*
|
|
1444
|
-
* This file is part of the Alfresco Example Content Application.
|
|
1445
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
1446
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
1447
|
-
* provided under the following open source license terms:
|
|
1448
|
-
*
|
|
1449
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
1450
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
1451
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
1452
|
-
* (at your option) any later version.
|
|
1453
|
-
*
|
|
1454
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
1455
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
1456
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
1457
|
-
* GNU Lesser General Public License for more details.
|
|
1458
|
-
*
|
|
1459
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
1460
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
1461
|
-
*/
|
|
1462
|
-
class LockedByComponent {
|
|
1463
|
-
ngOnInit() {
|
|
1464
|
-
var _a, _b, _c, _d;
|
|
1465
|
-
this.text = (_d = (_c = (_b = (_a = this.node) === null || _a === void 0 ? void 0 : _a.entry) === null || _b === void 0 ? void 0 : _b.properties) === null || _c === void 0 ? void 0 : _c['cm:lockOwner']) === null || _d === void 0 ? void 0 : _d.displayName;
|
|
1466
|
-
}
|
|
1467
|
-
}
|
|
1468
|
-
LockedByComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: LockedByComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1469
|
-
LockedByComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: LockedByComponent, isStandalone: true, selector: "aca-locked-by", inputs: { node: "node" }, host: { classAttribute: "aca-locked-by" }, ngImport: i0, template: `
|
|
1470
|
-
<mat-icon class="aca-locked-by--icon">lock</mat-icon>
|
|
1471
|
-
<span class="aca-locked-by--label">{{ 'APP.LOCKED_BY' | translate }}</span>
|
|
1472
|
-
<span class="aca-locked-by--name">{{ text }}</span>
|
|
1473
|
-
`, isInline: true, styles: [".aca-locked-by{display:flex;align-items:center;color:var(--theme-text-color, rgba(0, 0, 0, .54))}.aca-locked-by--icon{font-size:14px;width:14px;height:14px;min-width:14px}.aca-locked-by--label,.aca-locked-by--name{font-size:12px;padding:0 2px}\n"], dependencies: [{ kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i3$2.TranslatePipe, name: "translate" }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i5.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
1474
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: LockedByComponent, decorators: [{
|
|
1475
|
-
type: Component,
|
|
1476
|
-
args: [{ standalone: true, imports: [TranslateModule, MatIconModule], selector: 'aca-locked-by', template: `
|
|
1477
|
-
<mat-icon class="aca-locked-by--icon">lock</mat-icon>
|
|
1478
|
-
<span class="aca-locked-by--label">{{ 'APP.LOCKED_BY' | translate }}</span>
|
|
1479
|
-
<span class="aca-locked-by--name">{{ text }}</span>
|
|
1480
|
-
`, changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, host: {
|
|
1481
|
-
class: 'aca-locked-by'
|
|
1482
|
-
}, styles: [".aca-locked-by{display:flex;align-items:center;color:var(--theme-text-color, rgba(0, 0, 0, .54))}.aca-locked-by--icon{font-size:14px;width:14px;height:14px;min-width:14px}.aca-locked-by--label,.aca-locked-by--name{font-size:12px;padding:0 2px}\n"] }]
|
|
1483
|
-
}], propDecorators: { node: [{
|
|
1484
|
-
type: Input
|
|
1485
|
-
}] } });
|
|
1486
|
-
|
|
1487
|
-
/*!
|
|
1488
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
1489
|
-
*
|
|
1490
|
-
* Alfresco Example Content Application
|
|
1491
|
-
*
|
|
1492
|
-
* This file is part of the Alfresco Example Content Application.
|
|
1493
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
1494
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
1495
|
-
* provided under the following open source license terms:
|
|
1496
|
-
*
|
|
1497
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
1498
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
1499
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
1500
|
-
* (at your option) any later version.
|
|
1501
|
-
*
|
|
1502
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
1503
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
1504
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
1505
|
-
* GNU Lesser General Public License for more details.
|
|
1506
|
-
*
|
|
1507
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
1508
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
1509
|
-
*/
|
|
1510
|
-
class GenericErrorComponent {
|
|
1511
|
-
constructor() {
|
|
1512
|
-
this.text = 'APP.MESSAGES.ERRORS.MISSING_CONTENT';
|
|
1513
|
-
}
|
|
1514
|
-
}
|
|
1515
|
-
GenericErrorComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: GenericErrorComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
1516
|
-
GenericErrorComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: GenericErrorComponent, isStandalone: true, selector: "aca-generic-error", inputs: { text: "text" }, host: { classAttribute: "aca-generic-error" }, ngImport: i0, template: "<mat-icon class=\"generic-error__icon\">error</mat-icon>\n<p class=\"generic-error__title\">\n {{ text | translate }}\n</p>\n", styles: [".aca-generic-error{color:var(--theme-text-color, rgba(0, 0, 0, .54));display:flex;align-items:center;justify-content:center;flex-direction:column;width:100%;height:100%}.aca-generic-error__title{font-size:16px}.aca-generic-error__icon{color:var(--theme-warn-color, #f44336);font-size:52px;height:52px;width:52px}\n"], dependencies: [{ kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i5.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i3$2.TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
1517
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: GenericErrorComponent, decorators: [{
|
|
1518
|
-
type: Component,
|
|
1519
|
-
args: [{ standalone: true, imports: [MatIconModule, TranslateModule], selector: 'aca-generic-error', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, host: { class: 'aca-generic-error' }, template: "<mat-icon class=\"generic-error__icon\">error</mat-icon>\n<p class=\"generic-error__title\">\n {{ text | translate }}\n</p>\n", styles: [".aca-generic-error{color:var(--theme-text-color, rgba(0, 0, 0, .54));display:flex;align-items:center;justify-content:center;flex-direction:column;width:100%;height:100%}.aca-generic-error__title{font-size:16px}.aca-generic-error__icon{color:var(--theme-warn-color, #f44336);font-size:52px;height:52px;width:52px}\n"] }]
|
|
1520
|
-
}], propDecorators: { text: [{
|
|
1521
|
-
type: Input
|
|
1522
|
-
}] } });
|
|
1523
|
-
|
|
1524
|
-
/*!
|
|
1525
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
1526
|
-
*
|
|
1527
|
-
* Alfresco Example Content Application
|
|
1528
|
-
*
|
|
1529
|
-
* This file is part of the Alfresco Example Content Application.
|
|
1530
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
1531
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
1532
|
-
* provided under the following open source license terms:
|
|
1533
|
-
*
|
|
1534
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
1535
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
1536
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
1537
|
-
* (at your option) any later version.
|
|
1538
|
-
*
|
|
1539
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
1540
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
1541
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
1542
|
-
* GNU Lesser General Public License for more details.
|
|
1543
|
-
*
|
|
1544
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
1545
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
1546
|
-
*/
|
|
1547
|
-
class NodePermissionService {
|
|
1548
|
-
constructor() {
|
|
1549
|
-
this.defaultOptions = {
|
|
1550
|
-
operation: NodePermissionService.DEFAULT_OPERATION,
|
|
1551
|
-
target: null
|
|
1552
|
-
};
|
|
1553
|
-
}
|
|
1554
|
-
check(source, permissions, options) {
|
|
1555
|
-
const opts = Object.assign({}, this.defaultOptions, options || {});
|
|
1556
|
-
if (!source) {
|
|
1557
|
-
return false;
|
|
1558
|
-
}
|
|
1559
|
-
if (Array.isArray(source)) {
|
|
1560
|
-
source = source.filter((item) => item);
|
|
1561
|
-
if (source.length > 0) {
|
|
1562
|
-
return source.every((node) => this.isOperationAllowed(node, permissions, opts));
|
|
1563
|
-
}
|
|
1564
|
-
return false;
|
|
1565
|
-
}
|
|
1566
|
-
else {
|
|
1567
|
-
return this.isOperationAllowed(source, permissions, opts);
|
|
1568
|
-
}
|
|
1569
|
-
}
|
|
1570
|
-
isOperationAllowed(node, permissions, options) {
|
|
1571
|
-
const allowableOperations = this.getAllowableOperations(node, options.target);
|
|
1572
|
-
if (allowableOperations.length) {
|
|
1573
|
-
if (options.operation === NodePermissionService.DEFAULT_OPERATION) {
|
|
1574
|
-
return permissions.some((permission) => allowableOperations.includes(permission));
|
|
1575
|
-
}
|
|
1576
|
-
else {
|
|
1577
|
-
return permissions.every((permission) => allowableOperations.includes(permission));
|
|
1578
|
-
}
|
|
1579
|
-
}
|
|
1580
|
-
return false;
|
|
1581
|
-
}
|
|
1582
|
-
getAllowableOperations(node, property) {
|
|
1583
|
-
let entry;
|
|
1584
|
-
if ('entry' in node) {
|
|
1585
|
-
entry = node.entry;
|
|
1586
|
-
}
|
|
1587
|
-
else {
|
|
1588
|
-
entry = node;
|
|
1589
|
-
}
|
|
1590
|
-
if (property) {
|
|
1591
|
-
return entry[property] || [];
|
|
1592
|
-
}
|
|
1593
|
-
if ('allowableOperationsOnTarget' in entry) {
|
|
1594
|
-
return entry.allowableOperationsOnTarget || [];
|
|
1595
|
-
}
|
|
1596
|
-
else {
|
|
1597
|
-
return entry.allowableOperations || [];
|
|
1598
|
-
}
|
|
1599
|
-
}
|
|
1600
|
-
}
|
|
1601
|
-
NodePermissionService.DEFAULT_OPERATION = 'OR';
|
|
1602
|
-
NodePermissionService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: NodePermissionService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
1603
|
-
NodePermissionService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: NodePermissionService, providedIn: 'root' });
|
|
1604
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: NodePermissionService, decorators: [{
|
|
1605
|
-
type: Injectable,
|
|
1606
|
-
args: [{
|
|
1607
|
-
providedIn: 'root'
|
|
1608
|
-
}]
|
|
1609
|
-
}] });
|
|
1610
|
-
|
|
1611
|
-
class AppExtensionService {
|
|
1612
|
-
constructor(auth, store, loader, extensions, permissions, appConfig, matIconRegistry, sanitizer, logger) {
|
|
1613
|
-
this.auth = auth;
|
|
1614
|
-
this.store = store;
|
|
1615
|
-
this.loader = loader;
|
|
1616
|
-
this.extensions = extensions;
|
|
1617
|
-
this.permissions = permissions;
|
|
1618
|
-
this.appConfig = appConfig;
|
|
1619
|
-
this.matIconRegistry = matIconRegistry;
|
|
1620
|
-
this.sanitizer = sanitizer;
|
|
1621
|
-
this.logger = logger;
|
|
1622
|
-
this._references = new BehaviorSubject([]);
|
|
1623
|
-
this.bulkActionExecuted$ = new Subject();
|
|
1624
|
-
this.navbar = [];
|
|
1625
|
-
this.sidebarTabs = [];
|
|
1626
|
-
this.viewerRules = {};
|
|
1627
|
-
this._headerActions = new BehaviorSubject([]);
|
|
1628
|
-
this._toolbarActions = new BehaviorSubject([]);
|
|
1629
|
-
this._viewerToolbarActions = new BehaviorSubject([]);
|
|
1630
|
-
this._sharedLinkViewerToolbarActions = new BehaviorSubject([]);
|
|
1631
|
-
this._contextMenuActions = new BehaviorSubject([]);
|
|
1632
|
-
this._openWithActions = new BehaviorSubject([]);
|
|
1633
|
-
this._createActions = new BehaviorSubject([]);
|
|
1634
|
-
this._sidebarActions = new BehaviorSubject([]);
|
|
1635
|
-
this._badges = new BehaviorSubject([]);
|
|
1636
|
-
this._filesDocumentListPreset = new BehaviorSubject([]);
|
|
1637
|
-
this._customMetadataPanels = new BehaviorSubject([]);
|
|
1638
|
-
this._bulkActions = new BehaviorSubject([]);
|
|
1639
|
-
this.documentListPresets = {
|
|
1640
|
-
libraries: [],
|
|
1641
|
-
favoriteLibraries: [],
|
|
1642
|
-
shared: [],
|
|
1643
|
-
recent: [],
|
|
1644
|
-
favorites: [],
|
|
1645
|
-
trashcan: [],
|
|
1646
|
-
searchLibraries: [],
|
|
1647
|
-
searchResults: []
|
|
1648
|
-
};
|
|
1649
|
-
this.filesDocumentListPreset$ = this._filesDocumentListPreset.asObservable();
|
|
1650
|
-
this.references$ = this._references.asObservable();
|
|
1651
|
-
this.store.select(getRuleContext).subscribe((result) => {
|
|
1652
|
-
this.selection = result.selection;
|
|
1653
|
-
this.navigation = result.navigation;
|
|
1654
|
-
this.profile = result.profile;
|
|
1655
|
-
this.repository = result.repository;
|
|
1656
|
-
if (this.config) {
|
|
1657
|
-
this.setup(this.config);
|
|
1658
|
-
}
|
|
1659
|
-
});
|
|
1660
|
-
}
|
|
1661
|
-
load() {
|
|
1662
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
1663
|
-
this.config = yield this.extensions.load();
|
|
1664
|
-
this.setup(this.config);
|
|
1665
|
-
});
|
|
1666
|
-
}
|
|
1667
|
-
setup(config) {
|
|
1668
|
-
var _a, _b;
|
|
1669
|
-
if (!config) {
|
|
1670
|
-
this.logger.error('Extension configuration not found');
|
|
1671
|
-
return;
|
|
1672
|
-
}
|
|
1673
|
-
this._headerActions.next(this.loader.getContentActions(config, 'features.header'));
|
|
1674
|
-
this._sidebarActions.next(this.loader.getContentActions(config, 'features.sidebar.toolbar'));
|
|
1675
|
-
this._toolbarActions.next(this.loader.getContentActions(config, 'features.toolbar'));
|
|
1676
|
-
this._viewerToolbarActions.next(this.loader.getContentActions(config, 'features.viewer.toolbarActions'));
|
|
1677
|
-
this._sharedLinkViewerToolbarActions.next(this.loader.getContentActions(config, 'features.viewer.shared.toolbarActions'));
|
|
1678
|
-
this._contextMenuActions.next(this.loader.getContentActions(config, 'features.contextMenu'));
|
|
1679
|
-
this._openWithActions.next(this.loader.getContentActions(config, 'features.viewer.openWith'));
|
|
1680
|
-
this._createActions.next(this.loader.getElements(config, 'features.create'));
|
|
1681
|
-
this._badges.next(this.loader.getElements(config, 'features.badges'));
|
|
1682
|
-
this._filesDocumentListPreset.next(this.getDocumentListPreset(config, 'files'));
|
|
1683
|
-
this._customMetadataPanels.next(this.loader.getElements(config, 'features.customMetadataPanels'));
|
|
1684
|
-
this._bulkActions.next(this.loader.getElements(config, 'features.bulk-actions'));
|
|
1685
|
-
this.navbar = this.loadNavBar(config);
|
|
1686
|
-
this.sidebarTabs = this.loader.getElements(config, 'features.sidebar.tabs');
|
|
1687
|
-
this.contentMetadata = this.loadContentMetadata(config);
|
|
1688
|
-
this.search = this.loadSearchForms(config);
|
|
1689
|
-
(_a = this.search) === null || _a === void 0 ? void 0 : _a.forEach((searchSet) => {
|
|
1690
|
-
var _a;
|
|
1691
|
-
searchSet.categories = (_a = searchSet.categories) === null || _a === void 0 ? void 0 : _a.filter((category) => this.filterVisible(category));
|
|
1692
|
-
});
|
|
1693
|
-
this.documentListPresets = {
|
|
1694
|
-
libraries: this.getDocumentListPreset(config, 'libraries'),
|
|
1695
|
-
favoriteLibraries: this.getDocumentListPreset(config, 'favoriteLibraries'),
|
|
1696
|
-
shared: this.getDocumentListPreset(config, 'shared'),
|
|
1697
|
-
recent: this.getDocumentListPreset(config, 'recent'),
|
|
1698
|
-
favorites: this.getDocumentListPreset(config, 'favorites'),
|
|
1699
|
-
trashcan: this.getDocumentListPreset(config, 'trashcan'),
|
|
1700
|
-
searchLibraries: this.getDocumentListPreset(config, 'search-libraries'),
|
|
1701
|
-
searchResults: this.getDocumentListPreset(config, 'search-results')
|
|
1702
|
-
};
|
|
1703
|
-
this.withCredentials = this.appConfig.get('auth.withCredentials', false);
|
|
1704
|
-
if ((_b = config.features) === null || _b === void 0 ? void 0 : _b.viewer) {
|
|
1705
|
-
this.viewerRules = config.features.viewer['rules'] || {};
|
|
1706
|
-
}
|
|
1707
|
-
this.registerIcons(config);
|
|
1708
|
-
const references = (config.$references || []).filter((entry) => typeof entry === 'object').map((entry) => entry);
|
|
1709
|
-
this._references.next(references);
|
|
1710
|
-
}
|
|
1711
|
-
registerIcons(config) {
|
|
1712
|
-
const icons = this.loader.getElements(config, 'features.icons').filter((entry) => !entry.disabled);
|
|
1713
|
-
for (const icon of icons) {
|
|
1714
|
-
const [ns, id] = icon.id.split(':');
|
|
1715
|
-
const value = icon.value;
|
|
1716
|
-
if (!value) {
|
|
1717
|
-
this.logger.warn(`Missing icon value for "${icon.id}".`);
|
|
1718
|
-
}
|
|
1719
|
-
else if (!ns || !id) {
|
|
1720
|
-
this.logger.warn(`Incorrect icon id format.`);
|
|
1721
|
-
}
|
|
1722
|
-
else {
|
|
1723
|
-
this.matIconRegistry.addSvgIconInNamespace(ns, id, this.sanitizer.bypassSecurityTrustResourceUrl(value));
|
|
1724
|
-
}
|
|
1725
|
-
}
|
|
1726
|
-
}
|
|
1727
|
-
loadNavBar(config) {
|
|
1728
|
-
return this.loader.getElements(config, 'features.navbar');
|
|
1729
|
-
}
|
|
1730
|
-
getDocumentListPreset(config, key) {
|
|
1731
|
-
return this.loader
|
|
1732
|
-
.getElements(config, `features.documentList.${key}`)
|
|
1733
|
-
.filter((group) => this.filterVisible(group))
|
|
1734
|
-
.filter((entry) => !entry.disabled)
|
|
1735
|
-
.map((entry) => {
|
|
1736
|
-
var _a;
|
|
1737
|
-
entry.resizable = (_a = entry.resizable) !== null && _a !== void 0 ? _a : true;
|
|
1738
|
-
return entry;
|
|
1739
|
-
})
|
|
1740
|
-
.sort(sortByOrder);
|
|
1741
|
-
}
|
|
1742
|
-
getApplicationNavigation(elements) {
|
|
1743
|
-
return elements
|
|
1744
|
-
.filter((group) => this.filterVisible(group))
|
|
1745
|
-
.map((group) => (Object.assign(Object.assign({}, group), { items: (group.items || [])
|
|
1746
|
-
.filter((entry) => !entry.disabled)
|
|
1747
|
-
.filter((item) => this.filterVisible(item))
|
|
1748
|
-
.sort(sortByOrder)
|
|
1749
|
-
.map((item) => {
|
|
1750
|
-
if (item.children && item.children.length > 0) {
|
|
1751
|
-
item.children = item.children
|
|
1752
|
-
.filter((entry) => !entry.disabled)
|
|
1753
|
-
.filter((child) => this.filterVisible(child))
|
|
1754
|
-
.sort(sortByOrder)
|
|
1755
|
-
.map((child) => {
|
|
1756
|
-
if (child.component) {
|
|
1757
|
-
return Object.assign({}, child);
|
|
1758
|
-
}
|
|
1759
|
-
if (!child.click) {
|
|
1760
|
-
const childRouteRef = this.extensions.getRouteById(child.route);
|
|
1761
|
-
const childUrl = `/${childRouteRef ? childRouteRef.path : child.route}`;
|
|
1762
|
-
return Object.assign(Object.assign({}, child), { url: childUrl });
|
|
1763
|
-
}
|
|
1764
|
-
return Object.assign(Object.assign({}, child), { action: child.click });
|
|
1765
|
-
});
|
|
1766
|
-
return Object.assign({}, item);
|
|
1767
|
-
}
|
|
1768
|
-
if (item.component) {
|
|
1769
|
-
return Object.assign({}, item);
|
|
1770
|
-
}
|
|
1771
|
-
if (!item.click) {
|
|
1772
|
-
const routeRef = this.extensions.getRouteById(item.route);
|
|
1773
|
-
const url = `/${routeRef ? routeRef.path : item.route}`;
|
|
1774
|
-
return Object.assign(Object.assign({}, item), { url });
|
|
1775
|
-
}
|
|
1776
|
-
return Object.assign(Object.assign({}, item), { action: item.click });
|
|
1777
|
-
})
|
|
1778
|
-
.reduce(reduceEmptyMenus, []) })));
|
|
1779
|
-
}
|
|
1780
|
-
loadContentMetadata(config) {
|
|
1781
|
-
const elements = this.loader.getElements(config, 'features.content-metadata-presets');
|
|
1782
|
-
if (!elements.length) {
|
|
1783
|
-
return null;
|
|
1784
|
-
}
|
|
1785
|
-
let presets = {};
|
|
1786
|
-
presets = this.filterDisabled(mergeObjects(presets, ...elements));
|
|
1787
|
-
const metadata = this.appConfig.config['content-metadata'] || {};
|
|
1788
|
-
metadata.presets = presets;
|
|
1789
|
-
this.appConfig.config['content-metadata'] = metadata;
|
|
1790
|
-
return { presets };
|
|
1791
|
-
}
|
|
1792
|
-
loadSearchForms(config) {
|
|
1793
|
-
const elements = this.loader.getElements(config, 'features.search');
|
|
1794
|
-
if (!elements.length) {
|
|
1795
|
-
return null;
|
|
1796
|
-
}
|
|
1797
|
-
const search = mergeArrays([], elements)
|
|
1798
|
-
.filter((entry) => !entry.disabled)
|
|
1799
|
-
.filter((entry) => this.filterVisible(entry))
|
|
1800
|
-
.sort(sortByOrder);
|
|
1801
|
-
this.appConfig.config['search'] = search;
|
|
1802
|
-
return search;
|
|
1803
|
-
}
|
|
1804
|
-
filterDisabled(object) {
|
|
1805
|
-
if (Array.isArray(object)) {
|
|
1806
|
-
return object.filter((item) => !item.disabled).map((item) => this.filterDisabled(item));
|
|
1807
|
-
}
|
|
1808
|
-
else if (typeof object === 'object') {
|
|
1809
|
-
if (!object.disabled) {
|
|
1810
|
-
Object.keys(object).forEach((prop) => {
|
|
1811
|
-
object[prop] = this.filterDisabled(object[prop]);
|
|
1812
|
-
});
|
|
1813
|
-
return object;
|
|
1814
|
-
}
|
|
1815
|
-
}
|
|
1816
|
-
else {
|
|
1817
|
-
return object;
|
|
1818
|
-
}
|
|
1819
|
-
}
|
|
1820
|
-
getSidebarTabs() {
|
|
1821
|
-
return this.sidebarTabs.filter((action) => this.filterVisible(action));
|
|
1822
|
-
}
|
|
1823
|
-
setActionDisabledFromRule(action) {
|
|
1824
|
-
var _a;
|
|
1825
|
-
let disabled = false;
|
|
1826
|
-
if ((_a = action === null || action === void 0 ? void 0 : action.rules) === null || _a === void 0 ? void 0 : _a.enabled) {
|
|
1827
|
-
disabled = !this.extensions.evaluateRule(action.rules.enabled, this);
|
|
1828
|
-
}
|
|
1829
|
-
return Object.assign(Object.assign({}, action), { disabled });
|
|
1830
|
-
}
|
|
1831
|
-
updateSidebarActions() {
|
|
1832
|
-
this._sidebarActions.next(this.loader.getContentActions(this.config, 'features.sidebar.toolbar'));
|
|
1833
|
-
}
|
|
1834
|
-
getCreateActions() {
|
|
1835
|
-
return this._createActions.pipe(map((createActions) => createActions
|
|
1836
|
-
.filter((action) => this.filterVisible(action))
|
|
1837
|
-
.map((action) => this.copyAction(action))
|
|
1838
|
-
.map((action) => this.buildMenu(action))
|
|
1839
|
-
.map((action) => this.setActionDisabledFromRule(action))));
|
|
1840
|
-
}
|
|
1841
|
-
getBadges(node) {
|
|
1842
|
-
return this._badges.pipe(map((badges) => badges.filter((badge) => this.evaluateRule(badge.rules.visible, node))));
|
|
1843
|
-
}
|
|
1844
|
-
getCustomMetadataPanels(node) {
|
|
1845
|
-
return this._customMetadataPanels.pipe(map((panels) => panels.filter((panel) => this.evaluateRule(panel.rules.visible, node))));
|
|
1846
|
-
}
|
|
1847
|
-
buildMenu(actionRef) {
|
|
1848
|
-
if (actionRef.type === ContentActionType.menu && actionRef.children && actionRef.children.length > 0) {
|
|
1849
|
-
const children = actionRef.children.filter((action) => this.filterVisible(action)).map((action) => this.buildMenu(action));
|
|
1850
|
-
actionRef.children = children
|
|
1851
|
-
.map((action) => this.setActionDisabledFromRule(action))
|
|
1852
|
-
.sort(sortByOrder)
|
|
1853
|
-
.reduce(reduceEmptyMenus, [])
|
|
1854
|
-
.reduce(reduceSeparators, []);
|
|
1855
|
-
}
|
|
1856
|
-
return actionRef;
|
|
1857
|
-
}
|
|
1858
|
-
getAllowedActions(actions) {
|
|
1859
|
-
return (actions || [])
|
|
1860
|
-
.filter((action) => this.filterVisible(action))
|
|
1861
|
-
.map((action) => {
|
|
1862
|
-
if (action.type === ContentActionType.menu) {
|
|
1863
|
-
const copy = this.copyAction(action);
|
|
1864
|
-
if (copy.children && copy.children.length > 0) {
|
|
1865
|
-
copy.children = copy.children
|
|
1866
|
-
.filter((entry) => !entry.disabled)
|
|
1867
|
-
.filter((childAction) => this.filterVisible(childAction))
|
|
1868
|
-
.sort(sortByOrder)
|
|
1869
|
-
.reduce(reduceSeparators, []);
|
|
1870
|
-
}
|
|
1871
|
-
return copy;
|
|
1872
|
-
}
|
|
1873
|
-
return action;
|
|
1874
|
-
})
|
|
1875
|
-
.map((action) => this.setActionDisabledFromRule(action))
|
|
1876
|
-
.reduce(reduceEmptyMenus, [])
|
|
1877
|
-
.reduce(reduceSeparators, []);
|
|
1878
|
-
}
|
|
1879
|
-
getAllowedSidebarActions() {
|
|
1880
|
-
return this._sidebarActions.pipe(map((sidebarActions) => this.getAllowedActions(sidebarActions)));
|
|
1881
|
-
}
|
|
1882
|
-
getAllowedToolbarActions() {
|
|
1883
|
-
return this._toolbarActions.pipe(map((toolbarActions) => this.getAllowedActions(toolbarActions)));
|
|
1884
|
-
}
|
|
1885
|
-
getViewerToolbarActions() {
|
|
1886
|
-
return this._viewerToolbarActions.pipe(map((viewerToolbarActions) => this.getAllowedActions(viewerToolbarActions)));
|
|
1887
|
-
}
|
|
1888
|
-
getBulkActions() {
|
|
1889
|
-
return this._bulkActions.pipe(map((bulkActions) => this.getAllowedActions(bulkActions)));
|
|
1890
|
-
}
|
|
1891
|
-
getOpenWithActions() {
|
|
1892
|
-
return this._openWithActions.pipe(map((openWithActions) => this.getAllowedActions(openWithActions)));
|
|
1893
|
-
}
|
|
1894
|
-
getSharedLinkViewerToolbarActions() {
|
|
1895
|
-
return this._sharedLinkViewerToolbarActions.pipe(map((sharedLinkViewerToolbarActions) => (!this.selection.isEmpty ? this.getAllowedActions(sharedLinkViewerToolbarActions) : [])));
|
|
1896
|
-
}
|
|
1897
|
-
getHeaderActions() {
|
|
1898
|
-
return this._headerActions.pipe(map((headerActions) => headerActions
|
|
1899
|
-
.filter((action) => this.filterVisible(action))
|
|
1900
|
-
.map((action) => {
|
|
1901
|
-
if (action.type === ContentActionType.menu) {
|
|
1902
|
-
const copy = this.copyAction(action);
|
|
1903
|
-
if (copy.children && copy.children.length > 0) {
|
|
1904
|
-
copy.children = copy.children
|
|
1905
|
-
.filter((childAction) => this.filterVisible(childAction))
|
|
1906
|
-
.sort(sortByOrder)
|
|
1907
|
-
.reduce(reduceEmptyMenus, [])
|
|
1908
|
-
.reduce(reduceSeparators, []);
|
|
1909
|
-
}
|
|
1910
|
-
return copy;
|
|
1911
|
-
}
|
|
1912
|
-
return action;
|
|
1913
|
-
})
|
|
1914
|
-
.map((action) => this.setActionDisabledFromRule(action))
|
|
1915
|
-
.sort(sortByOrder)
|
|
1916
|
-
.reduce(reduceEmptyMenus, [])
|
|
1917
|
-
.reduce(reduceSeparators, [])));
|
|
1918
|
-
}
|
|
1919
|
-
getAllowedContextMenuActions() {
|
|
1920
|
-
return this._contextMenuActions.pipe(map((contextMenuActions) => (!this.selection.isEmpty ? this.getAllowedActions(contextMenuActions) : [])));
|
|
1921
|
-
}
|
|
1922
|
-
copyAction(action) {
|
|
1923
|
-
return Object.assign(Object.assign({}, action), { children: (action.children || []).map((child) => this.copyAction(child)) });
|
|
1924
|
-
}
|
|
1925
|
-
filterVisible(action) {
|
|
1926
|
-
var _a;
|
|
1927
|
-
if ((_a = action === null || action === void 0 ? void 0 : action.rules) === null || _a === void 0 ? void 0 : _a.visible) {
|
|
1928
|
-
if (Array.isArray(action.rules.visible)) {
|
|
1929
|
-
return action.rules.visible.every((rule) => this.extensions.evaluateRule(rule, this));
|
|
1930
|
-
}
|
|
1931
|
-
return this.extensions.evaluateRule(action.rules.visible, this);
|
|
1932
|
-
}
|
|
1933
|
-
return true;
|
|
1934
|
-
}
|
|
1935
|
-
isViewerExtensionDisabled(extension) {
|
|
1936
|
-
var _a;
|
|
1937
|
-
if (extension) {
|
|
1938
|
-
if (extension.disabled) {
|
|
1939
|
-
return true;
|
|
1940
|
-
}
|
|
1941
|
-
if ((_a = extension.rules) === null || _a === void 0 ? void 0 : _a.disabled) {
|
|
1942
|
-
return this.extensions.evaluateRule(extension.rules.disabled, this);
|
|
1943
|
-
}
|
|
1944
|
-
}
|
|
1945
|
-
return false;
|
|
1946
|
-
}
|
|
1947
|
-
runActionById(id, additionalPayload) {
|
|
1948
|
-
const action = this.extensions.getActionById(id);
|
|
1949
|
-
if (action) {
|
|
1950
|
-
const { type, payload } = action;
|
|
1951
|
-
const context = {
|
|
1952
|
-
selection: this.selection
|
|
1953
|
-
};
|
|
1954
|
-
const expression = this.extensions.runExpression(payload, context);
|
|
1955
|
-
this.store.dispatch({
|
|
1956
|
-
type,
|
|
1957
|
-
payload: expression,
|
|
1958
|
-
configuration: additionalPayload
|
|
1959
|
-
});
|
|
1960
|
-
}
|
|
1961
|
-
else {
|
|
1962
|
-
this.store.dispatch({
|
|
1963
|
-
type: id,
|
|
1964
|
-
configuration: additionalPayload
|
|
1965
|
-
});
|
|
1966
|
-
}
|
|
1967
|
-
}
|
|
1968
|
-
// todo: move to ADF/RuleService
|
|
1969
|
-
isRuleDefined(ruleId) {
|
|
1970
|
-
return !!(ruleId && this.getEvaluator(ruleId));
|
|
1971
|
-
}
|
|
1972
|
-
// todo: move to ADF/RuleService
|
|
1973
|
-
evaluateRule(ruleId, ...args) {
|
|
1974
|
-
const evaluator = this.getEvaluator(ruleId);
|
|
1975
|
-
if (evaluator) {
|
|
1976
|
-
return evaluator(this, ...args);
|
|
1977
|
-
}
|
|
1978
|
-
return false;
|
|
1979
|
-
}
|
|
1980
|
-
getEvaluator(key) {
|
|
1981
|
-
return this.extensions.getEvaluator(key);
|
|
1982
|
-
}
|
|
1983
|
-
canPreviewNode(node) {
|
|
1984
|
-
const rules = this.viewerRules;
|
|
1985
|
-
if (this.isRuleDefined(rules.canPreview)) {
|
|
1986
|
-
const canPreview = this.evaluateRule(rules.canPreview, node);
|
|
1987
|
-
if (!canPreview) {
|
|
1988
|
-
return false;
|
|
1989
|
-
}
|
|
1990
|
-
}
|
|
1991
|
-
return true;
|
|
1992
|
-
}
|
|
1993
|
-
canShowViewerNavigation(node) {
|
|
1994
|
-
const rules = this.viewerRules;
|
|
1995
|
-
if (this.isRuleDefined(rules.showNavigation)) {
|
|
1996
|
-
const showNavigation = this.evaluateRule(rules.showNavigation, node);
|
|
1997
|
-
if (!showNavigation) {
|
|
1998
|
-
return false;
|
|
1999
|
-
}
|
|
2000
|
-
}
|
|
2001
|
-
return true;
|
|
2002
|
-
}
|
|
2003
|
-
bulkActionExecuted() {
|
|
2004
|
-
this.bulkActionExecuted$.next();
|
|
2005
|
-
}
|
|
2006
|
-
}
|
|
2007
|
-
AppExtensionService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: AppExtensionService, deps: [{ token: i1.AuthenticationService }, { token: i1$2.Store }, { token: i3$1.ExtensionLoaderService }, { token: i3$1.ExtensionService }, { token: NodePermissionService }, { token: i1.AppConfigService }, { token: i5.MatIconRegistry }, { token: i6.DomSanitizer }, { token: i1.LogService }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
2008
|
-
AppExtensionService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: AppExtensionService, providedIn: 'root' });
|
|
2009
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: AppExtensionService, decorators: [{
|
|
2010
|
-
type: Injectable,
|
|
2011
|
-
args: [{
|
|
2012
|
-
providedIn: 'root'
|
|
2013
|
-
}]
|
|
2014
|
-
}], ctorParameters: function () { return [{ type: i1.AuthenticationService }, { type: i1$2.Store }, { type: i3$1.ExtensionLoaderService }, { type: i3$1.ExtensionService }, { type: NodePermissionService }, { type: i1.AppConfigService }, { type: i5.MatIconRegistry }, { type: i6.DomSanitizer }, { type: i1.LogService }]; } });
|
|
2015
|
-
|
|
2016
|
-
/*!
|
|
2017
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
2018
|
-
*
|
|
2019
|
-
* Alfresco Example Content Application
|
|
2020
|
-
*
|
|
2021
|
-
* This file is part of the Alfresco Example Content Application.
|
|
2022
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
2023
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
2024
|
-
* provided under the following open source license terms:
|
|
2025
|
-
*
|
|
2026
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
2027
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
2028
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
2029
|
-
* (at your option) any later version.
|
|
2030
|
-
*
|
|
2031
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
2032
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
2033
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
2034
|
-
* GNU Lesser General Public License for more details.
|
|
2035
|
-
*
|
|
2036
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
2037
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
2038
|
-
*/
|
|
2039
|
-
class ToolbarMenuItemComponent {
|
|
2040
|
-
constructor(extensions) {
|
|
2041
|
-
this.extensions = extensions;
|
|
2042
|
-
}
|
|
2043
|
-
runAction() {
|
|
2044
|
-
if (this.hasClickAction(this.actionRef)) {
|
|
2045
|
-
this.extensions.runActionById(this.actionRef.actions.click, this.menuId
|
|
2046
|
-
? {
|
|
2047
|
-
focusedElementOnCloseSelector: `#${this.menuId.replace(/\\/g, '\\\\').replace(/\./g, '\\.')}`
|
|
2048
|
-
}
|
|
2049
|
-
: undefined);
|
|
2050
|
-
}
|
|
2051
|
-
}
|
|
2052
|
-
hasClickAction(actionRef) {
|
|
2053
|
-
var _a;
|
|
2054
|
-
return !!((_a = actionRef === null || actionRef === void 0 ? void 0 : actionRef.actions) === null || _a === void 0 ? void 0 : _a.click);
|
|
2055
|
-
}
|
|
2056
|
-
trackByActionId(_, obj) {
|
|
2057
|
-
return obj.id;
|
|
2058
|
-
}
|
|
2059
|
-
}
|
|
2060
|
-
ToolbarMenuItemComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: ToolbarMenuItemComponent, deps: [{ token: AppExtensionService }], target: i0.ɵɵFactoryTarget.Component });
|
|
2061
|
-
ToolbarMenuItemComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: ToolbarMenuItemComponent, isStandalone: true, selector: "app-toolbar-menu-item", inputs: { actionRef: "actionRef", menuId: "menuId" }, host: { classAttribute: "app-toolbar-menu-item" }, viewQueries: [{ propertyName: "menuItem", first: true, predicate: MatMenuItem, descendants: true }], ngImport: i0, template: "<ng-container [ngSwitch]=\"actionRef.type\">\n <ng-container *ngSwitchCase=\"'menu'\">\n <button [id]=\"actionRef.id\" mat-menu-item role=\"menuitem\" tabindex=\"0\" [disabled]=\"actionRef.disabled\" [matMenuTriggerFor]=\"childMenu\">\n <adf-icon [value]=\"actionRef.icon\"></adf-icon>\n <span data-automation-id=\"menu-item-title\">{{ actionRef.title | translate }}</span>\n </button>\n\n <mat-menu #childMenu=\"matMenu\" class=\"app-create-menu__sub-menu\">\n <ng-container *ngFor=\"let child of actionRef.children; trackBy: trackByActionId\">\n <app-toolbar-menu-item [actionRef]=\"child\"></app-toolbar-menu-item>\n </ng-container>\n </mat-menu>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"'separator'\">\n <mat-divider></mat-divider>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"'custom'\">\n <adf-dynamic-component [id]=\"actionRef.component\"></adf-dynamic-component>\n </ng-container>\n\n <ng-container *ngSwitchDefault>\n <button\n [id]=\"actionRef.id\"\n role=\"menuitem\"\n mat-menu-item\n [role]=\"'menuitem'\"\n tabindex=\"0\"\n [disabled]=\"actionRef.disabled\"\n [attr.title]=\"(actionRef.disabled ? actionRef['description-disabled'] : actionRef.description || actionRef.title) | translate\"\n (click)=\"runAction()\"\n >\n <adf-icon [value]=\"actionRef.icon\" class=\"app-toolbar-menu-item--icon\"></adf-icon>\n <span data-automation-id=\"menu-item-title\">{{ actionRef.title | translate }}</span>\n </button>\n </ng-container>\n</ng-container>\n", styles: [".app-toolbar-menu-item:last-child>.mat-divider-horizontal{display:none}.app-toolbar-menu-item--icon{display:inline-flex;vertical-align:middle}\n"], dependencies: [{ kind: "component", type: ToolbarMenuItemComponent, selector: "app-toolbar-menu-item", inputs: ["actionRef", "menuId"] }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i2.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "directive", type: i2.NgSwitchDefault, selector: "[ngSwitchDefault]" }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i3$2.TranslatePipe, name: "translate" }, { kind: "ngmodule", type: MatMenuModule }, { kind: "component", type: i4$2.MatMenu, selector: "mat-menu", exportAs: ["matMenu"] }, { kind: "component", type: i4$2.MatMenuItem, selector: "[mat-menu-item]", inputs: ["disabled", "disableRipple", "role"], exportAs: ["matMenuItem"] }, { kind: "directive", type: i4$2.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", exportAs: ["matMenuTrigger"] }, { kind: "ngmodule", type: MatDividerModule }, { kind: "component", type: i5$1.MatDivider, selector: "mat-divider", inputs: ["vertical", "inset"] }, { kind: "component", type: IconComponent, selector: "adf-icon", inputs: ["color", "fontSet", "value"] }, { kind: "component", type: DynamicExtensionComponent, selector: "adf-dynamic-component", inputs: ["id", "data"] }], encapsulation: i0.ViewEncapsulation.None });
|
|
2062
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: ToolbarMenuItemComponent, decorators: [{
|
|
2063
|
-
type: Component,
|
|
2064
|
-
args: [{ standalone: true, imports: [CommonModule, TranslateModule, MatMenuModule, MatDividerModule, IconComponent, DynamicExtensionComponent], selector: 'app-toolbar-menu-item', encapsulation: ViewEncapsulation.None, host: { class: 'app-toolbar-menu-item' }, template: "<ng-container [ngSwitch]=\"actionRef.type\">\n <ng-container *ngSwitchCase=\"'menu'\">\n <button [id]=\"actionRef.id\" mat-menu-item role=\"menuitem\" tabindex=\"0\" [disabled]=\"actionRef.disabled\" [matMenuTriggerFor]=\"childMenu\">\n <adf-icon [value]=\"actionRef.icon\"></adf-icon>\n <span data-automation-id=\"menu-item-title\">{{ actionRef.title | translate }}</span>\n </button>\n\n <mat-menu #childMenu=\"matMenu\" class=\"app-create-menu__sub-menu\">\n <ng-container *ngFor=\"let child of actionRef.children; trackBy: trackByActionId\">\n <app-toolbar-menu-item [actionRef]=\"child\"></app-toolbar-menu-item>\n </ng-container>\n </mat-menu>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"'separator'\">\n <mat-divider></mat-divider>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"'custom'\">\n <adf-dynamic-component [id]=\"actionRef.component\"></adf-dynamic-component>\n </ng-container>\n\n <ng-container *ngSwitchDefault>\n <button\n [id]=\"actionRef.id\"\n role=\"menuitem\"\n mat-menu-item\n [role]=\"'menuitem'\"\n tabindex=\"0\"\n [disabled]=\"actionRef.disabled\"\n [attr.title]=\"(actionRef.disabled ? actionRef['description-disabled'] : actionRef.description || actionRef.title) | translate\"\n (click)=\"runAction()\"\n >\n <adf-icon [value]=\"actionRef.icon\" class=\"app-toolbar-menu-item--icon\"></adf-icon>\n <span data-automation-id=\"menu-item-title\">{{ actionRef.title | translate }}</span>\n </button>\n </ng-container>\n</ng-container>\n", styles: [".app-toolbar-menu-item:last-child>.mat-divider-horizontal{display:none}.app-toolbar-menu-item--icon{display:inline-flex;vertical-align:middle}\n"] }]
|
|
2065
|
-
}], ctorParameters: function () { return [{ type: AppExtensionService }]; }, propDecorators: { actionRef: [{
|
|
2066
|
-
type: Input
|
|
2067
|
-
}], menuId: [{
|
|
2068
|
-
type: Input
|
|
2069
|
-
}], menuItem: [{
|
|
2070
|
-
type: ViewChild,
|
|
2071
|
-
args: [MatMenuItem]
|
|
2072
|
-
}] } });
|
|
2073
|
-
|
|
2074
|
-
/*!
|
|
2075
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
2076
|
-
*
|
|
2077
|
-
* Alfresco Example Content Application
|
|
2078
|
-
*
|
|
2079
|
-
* This file is part of the Alfresco Example Content Application.
|
|
2080
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
2081
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
2082
|
-
* provided under the following open source license terms:
|
|
2083
|
-
*
|
|
2084
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
2085
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
2086
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
2087
|
-
* (at your option) any later version.
|
|
2088
|
-
*
|
|
2089
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
2090
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
2091
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
2092
|
-
* GNU Lesser General Public License for more details.
|
|
2093
|
-
*
|
|
2094
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
2095
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
2096
|
-
*/
|
|
2097
|
-
var ToolbarButtonType;
|
|
2098
|
-
(function (ToolbarButtonType) {
|
|
2099
|
-
ToolbarButtonType["ICON_BUTTON"] = "icon-button";
|
|
2100
|
-
ToolbarButtonType["FLAT_BUTTON"] = "flat-button";
|
|
2101
|
-
ToolbarButtonType["STROKED_BUTTON"] = "stroked-button";
|
|
2102
|
-
ToolbarButtonType["MENU_ITEM"] = "menu-item";
|
|
2103
|
-
})(ToolbarButtonType || (ToolbarButtonType = {}));
|
|
2104
|
-
class ToolbarButtonComponent {
|
|
2105
|
-
constructor(extensions) {
|
|
2106
|
-
this.extensions = extensions;
|
|
2107
|
-
this.type = ToolbarButtonType.ICON_BUTTON;
|
|
2108
|
-
}
|
|
2109
|
-
runAction() {
|
|
2110
|
-
if (this.hasClickAction(this.actionRef)) {
|
|
2111
|
-
this.extensions.runActionById(this.actionRef.actions.click, {
|
|
2112
|
-
focusedElementOnCloseSelector: `#${this.actionRef.id.replace(/\\/g, '\\\\').replace(/\./g, '\\.')}`
|
|
2113
|
-
});
|
|
2114
|
-
}
|
|
2115
|
-
}
|
|
2116
|
-
hasClickAction(actionRef) {
|
|
2117
|
-
var _a;
|
|
2118
|
-
return !!((_a = actionRef === null || actionRef === void 0 ? void 0 : actionRef.actions) === null || _a === void 0 ? void 0 : _a.click);
|
|
2119
|
-
}
|
|
2120
|
-
}
|
|
2121
|
-
ToolbarButtonComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: ToolbarButtonComponent, deps: [{ token: AppExtensionService }], target: i0.ɵɵFactoryTarget.Component });
|
|
2122
|
-
ToolbarButtonComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: ToolbarButtonComponent, isStandalone: true, selector: "app-toolbar-button", inputs: { data: "data", type: "type", color: "color", actionRef: "actionRef" }, host: { classAttribute: "app-toolbar-button" }, ngImport: i0, template: "<ng-container [ngSwitch]=\"data?.buttonType || type\">\n <ng-container *ngSwitchCase=\"'icon-button'\">\n <button\n [id]=\"actionRef.id\"\n mat-icon-button\n [color]=\"color\"\n [attr.aria-label]=\"actionRef.description || actionRef.title | translate\"\n [attr.title]=\"actionRef.description || actionRef.title | translate\"\n [disabled]=\"actionRef.disabled\"\n (click)=\"runAction()\"\n >\n <adf-icon [value]=\"actionRef.icon\"></adf-icon>\n </button>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"'flat-button'\">\n <button\n [id]=\"actionRef.id\"\n [color]=\"data?.color || color\"\n mat-flat-button\n [attr.aria-label]=\"actionRef.description || actionRef.title | translate\"\n [attr.title]=\"actionRef.description || actionRef.title | translate\"\n [disabled]=\"actionRef.disabled\"\n (click)=\"runAction()\"\n >\n <span *ngIf=\"actionRef.title\">{{ actionRef.title | translate }}</span>\n </button>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"'stroked-button'\">\n <button\n [id]=\"actionRef.id\"\n [color]=\"data?.color || color\"\n mat-stroked-button\n [attr.aria-label]=\"actionRef.description || actionRef.title | translate\"\n [attr.title]=\"actionRef.description || actionRef.title | translate\"\n [disabled]=\"actionRef.disabled\"\n (click)=\"runAction()\"\n >\n <span *ngIf=\"actionRef.title\">{{ actionRef.title | translate }}</span>\n </button>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"'menu-item'\">\n <app-toolbar-menu-item [actionRef]=\"actionRef\"></app-toolbar-menu-item>\n </ng-container>\n</ng-container>\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i2.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i3$2.TranslatePipe, name: "translate" }, { kind: "ngmodule", type: MatButtonModule }, { kind: "component", type: i4$1.MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "component", type: i4$1.MatIconButton, selector: "button[mat-icon-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "ngmodule", type: IconModule }, { kind: "component", type: i1.IconComponent, selector: "adf-icon", inputs: ["color", "fontSet", "value"] }, { kind: "component", type: ToolbarMenuItemComponent, selector: "app-toolbar-menu-item", inputs: ["actionRef", "menuId"] }], encapsulation: i0.ViewEncapsulation.None });
|
|
2123
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: ToolbarButtonComponent, decorators: [{
|
|
2124
|
-
type: Component,
|
|
2125
|
-
args: [{ standalone: true, imports: [CommonModule, TranslateModule, MatButtonModule, IconModule, ToolbarMenuItemComponent], selector: 'app-toolbar-button', encapsulation: ViewEncapsulation.None, host: { class: 'app-toolbar-button' }, template: "<ng-container [ngSwitch]=\"data?.buttonType || type\">\n <ng-container *ngSwitchCase=\"'icon-button'\">\n <button\n [id]=\"actionRef.id\"\n mat-icon-button\n [color]=\"color\"\n [attr.aria-label]=\"actionRef.description || actionRef.title | translate\"\n [attr.title]=\"actionRef.description || actionRef.title | translate\"\n [disabled]=\"actionRef.disabled\"\n (click)=\"runAction()\"\n >\n <adf-icon [value]=\"actionRef.icon\"></adf-icon>\n </button>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"'flat-button'\">\n <button\n [id]=\"actionRef.id\"\n [color]=\"data?.color || color\"\n mat-flat-button\n [attr.aria-label]=\"actionRef.description || actionRef.title | translate\"\n [attr.title]=\"actionRef.description || actionRef.title | translate\"\n [disabled]=\"actionRef.disabled\"\n (click)=\"runAction()\"\n >\n <span *ngIf=\"actionRef.title\">{{ actionRef.title | translate }}</span>\n </button>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"'stroked-button'\">\n <button\n [id]=\"actionRef.id\"\n [color]=\"data?.color || color\"\n mat-stroked-button\n [attr.aria-label]=\"actionRef.description || actionRef.title | translate\"\n [attr.title]=\"actionRef.description || actionRef.title | translate\"\n [disabled]=\"actionRef.disabled\"\n (click)=\"runAction()\"\n >\n <span *ngIf=\"actionRef.title\">{{ actionRef.title | translate }}</span>\n </button>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"'menu-item'\">\n <app-toolbar-menu-item [actionRef]=\"actionRef\"></app-toolbar-menu-item>\n </ng-container>\n</ng-container>\n" }]
|
|
2126
|
-
}], ctorParameters: function () { return [{ type: AppExtensionService }]; }, propDecorators: { data: [{
|
|
2127
|
-
type: Input
|
|
2128
|
-
}], type: [{
|
|
2129
|
-
type: Input
|
|
2130
|
-
}], color: [{
|
|
2131
|
-
type: Input
|
|
2132
|
-
}], actionRef: [{
|
|
2133
|
-
type: Input
|
|
2134
|
-
}] } });
|
|
2135
|
-
|
|
2136
|
-
/*!
|
|
2137
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
2138
|
-
*
|
|
2139
|
-
* Alfresco Example Content Application
|
|
2140
|
-
*
|
|
2141
|
-
* This file is part of the Alfresco Example Content Application.
|
|
2142
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
2143
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
2144
|
-
* provided under the following open source license terms:
|
|
2145
|
-
*
|
|
2146
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
2147
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
2148
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
2149
|
-
* (at your option) any later version.
|
|
2150
|
-
*
|
|
2151
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
2152
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
2153
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
2154
|
-
* GNU Lesser General Public License for more details.
|
|
2155
|
-
*
|
|
2156
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
2157
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
2158
|
-
*/
|
|
2159
|
-
class ToolbarMenuComponent {
|
|
2160
|
-
constructor() {
|
|
2161
|
-
this.type = 'default';
|
|
2162
|
-
}
|
|
2163
|
-
handleKeydownEscape() {
|
|
2164
|
-
this.matTrigger.closeMenu();
|
|
2165
|
-
}
|
|
2166
|
-
ngOnInit() {
|
|
2167
|
-
var _a;
|
|
2168
|
-
this.type = ((_a = this.data) === null || _a === void 0 ? void 0 : _a.menuType) || 'default';
|
|
2169
|
-
}
|
|
2170
|
-
ngAfterViewInit() {
|
|
2171
|
-
const menuItems = [];
|
|
2172
|
-
this.toolbarMenuItems.forEach((toolbarMenuItem) => {
|
|
2173
|
-
if (toolbarMenuItem.menuItem !== undefined) {
|
|
2174
|
-
menuItems.push(toolbarMenuItem.menuItem);
|
|
2175
|
-
}
|
|
2176
|
-
});
|
|
2177
|
-
const menuItemsQueryList = new QueryList();
|
|
2178
|
-
menuItemsQueryList.reset(menuItems);
|
|
2179
|
-
this.menu._allItems = menuItemsQueryList;
|
|
2180
|
-
this.menu.ngAfterContentInit();
|
|
2181
|
-
}
|
|
2182
|
-
trackByActionId(_, obj) {
|
|
2183
|
-
return obj.id;
|
|
2184
|
-
}
|
|
2185
|
-
}
|
|
2186
|
-
ToolbarMenuComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: ToolbarMenuComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
2187
|
-
ToolbarMenuComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: ToolbarMenuComponent, isStandalone: true, selector: "app-toolbar-menu", inputs: { actionRef: "actionRef", color: "color", data: "data" }, host: { listeners: { "document:keydown.Escape": "handleKeydownEscape()" }, classAttribute: "app-toolbar-menu" }, viewQueries: [{ propertyName: "matTrigger", first: true, predicate: ["matTrigger"], descendants: true }, { propertyName: "menu", first: true, predicate: MatMenu, descendants: true }, { propertyName: "toolbarMenuItems", predicate: ToolbarMenuItemComponent, descendants: true }], ngImport: i0, template: "<ng-container [ngSwitch]=\"type\">\n <ng-container *ngSwitchCase=\"'button'\">\n <button\n [id]=\"actionRef.id\"\n [color]=\"data?.color || color\"\n mat-button\n [attr.aria-label]=\"actionRef.description || actionRef.title | translate\"\n [attr.title]=\"actionRef.description || actionRef.title | translate\"\n [matMenuTriggerFor]=\"menu\"\n [disabled]=\"actionRef.disabled\"\n #matTrigger=\"matMenuTrigger\"\n >\n <span *ngIf=\"actionRef.title\">{{ actionRef.title | translate }}</span>\n </button>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"'flat-button'\">\n <button\n [id]=\"actionRef.id\"\n [color]=\"data?.color || color\"\n mat-flat-button\n [attr.aria-label]=\"actionRef.description || actionRef.title | translate\"\n [attr.title]=\"actionRef.description || actionRef.title | translate\"\n [matMenuTriggerFor]=\"menu\"\n [disabled]=\"actionRef.disabled\"\n #matTrigger=\"matMenuTrigger\"\n >\n <span *ngIf=\"actionRef.title\">{{ actionRef.title | translate }}</span>\n </button>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"'stroked-button'\">\n <button\n [id]=\"actionRef.id\"\n [color]=\"data?.color || color\"\n mat-stroked-button\n [attr.aria-label]=\"actionRef.description || actionRef.title | translate\"\n [attr.title]=\"actionRef.description || actionRef.title | translate\"\n [matMenuTriggerFor]=\"menu\"\n [disabled]=\"actionRef.disabled\"\n #matTrigger=\"matMenuTrigger\"\n >\n <span *ngIf=\"actionRef.title\">{{ actionRef.title | translate }}</span>\n </button>\n </ng-container>\n\n <ng-container *ngSwitchDefault>\n <button\n [id]=\"actionRef.id\"\n [color]=\"data?.color || color\"\n mat-icon-button\n [attr.aria-label]=\"actionRef.description || actionRef.title | translate\"\n [attr.title]=\"actionRef.description || actionRef.title | translate\"\n [matMenuTriggerFor]=\"menu\"\n [disabled]=\"actionRef.disabled\"\n #matTrigger=\"matMenuTrigger\"\n >\n <adf-icon *ngIf=\"actionRef.icon\" [value]=\"actionRef.icon\"></adf-icon>\n </button>\n </ng-container>\n</ng-container>\n\n<mat-menu #menu=\"matMenu\" [overlapTrigger]=\"false\" [xPosition]=\"'before'\">\n <ng-container *ngFor=\"let child of actionRef.children; trackBy: trackByActionId\">\n <ng-container [ngSwitch]=\"child.type\">\n <ng-container *ngSwitchCase=\"'custom'\">\n <adf-dynamic-component [id]=\"child.component\" [data]=\"child.data\"></adf-dynamic-component>\n </ng-container>\n <ng-container *ngSwitchDefault>\n <app-toolbar-menu-item [actionRef]=\"child\" [menuId]=\"actionRef.id\"></app-toolbar-menu-item>\n </ng-container>\n </ng-container>\n </ng-container>\n</mat-menu>\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i2.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "directive", type: i2.NgSwitchDefault, selector: "[ngSwitchDefault]" }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i3$2.TranslatePipe, name: "translate" }, { kind: "ngmodule", type: MatButtonModule }, { kind: "component", type: i4$1.MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "component", type: i4$1.MatIconButton, selector: "button[mat-icon-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { kind: "ngmodule", type: MatMenuModule }, { kind: "component", type: i4$2.MatMenu, selector: "mat-menu", exportAs: ["matMenu"] }, { kind: "directive", type: i4$2.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", exportAs: ["matMenuTrigger"] }, { kind: "component", type: ToolbarMenuItemComponent, selector: "app-toolbar-menu-item", inputs: ["actionRef", "menuId"] }, { kind: "component", type: IconComponent, selector: "adf-icon", inputs: ["color", "fontSet", "value"] }, { kind: "component", type: DynamicExtensionComponent, selector: "adf-dynamic-component", inputs: ["id", "data"] }], encapsulation: i0.ViewEncapsulation.None });
|
|
2188
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: ToolbarMenuComponent, decorators: [{
|
|
2189
|
-
type: Component,
|
|
2190
|
-
args: [{ standalone: true, imports: [CommonModule, TranslateModule, MatButtonModule, MatMenuModule, ToolbarMenuItemComponent, IconComponent, DynamicExtensionComponent], selector: 'app-toolbar-menu', encapsulation: ViewEncapsulation.None, host: { class: 'app-toolbar-menu' }, template: "<ng-container [ngSwitch]=\"type\">\n <ng-container *ngSwitchCase=\"'button'\">\n <button\n [id]=\"actionRef.id\"\n [color]=\"data?.color || color\"\n mat-button\n [attr.aria-label]=\"actionRef.description || actionRef.title | translate\"\n [attr.title]=\"actionRef.description || actionRef.title | translate\"\n [matMenuTriggerFor]=\"menu\"\n [disabled]=\"actionRef.disabled\"\n #matTrigger=\"matMenuTrigger\"\n >\n <span *ngIf=\"actionRef.title\">{{ actionRef.title | translate }}</span>\n </button>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"'flat-button'\">\n <button\n [id]=\"actionRef.id\"\n [color]=\"data?.color || color\"\n mat-flat-button\n [attr.aria-label]=\"actionRef.description || actionRef.title | translate\"\n [attr.title]=\"actionRef.description || actionRef.title | translate\"\n [matMenuTriggerFor]=\"menu\"\n [disabled]=\"actionRef.disabled\"\n #matTrigger=\"matMenuTrigger\"\n >\n <span *ngIf=\"actionRef.title\">{{ actionRef.title | translate }}</span>\n </button>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"'stroked-button'\">\n <button\n [id]=\"actionRef.id\"\n [color]=\"data?.color || color\"\n mat-stroked-button\n [attr.aria-label]=\"actionRef.description || actionRef.title | translate\"\n [attr.title]=\"actionRef.description || actionRef.title | translate\"\n [matMenuTriggerFor]=\"menu\"\n [disabled]=\"actionRef.disabled\"\n #matTrigger=\"matMenuTrigger\"\n >\n <span *ngIf=\"actionRef.title\">{{ actionRef.title | translate }}</span>\n </button>\n </ng-container>\n\n <ng-container *ngSwitchDefault>\n <button\n [id]=\"actionRef.id\"\n [color]=\"data?.color || color\"\n mat-icon-button\n [attr.aria-label]=\"actionRef.description || actionRef.title | translate\"\n [attr.title]=\"actionRef.description || actionRef.title | translate\"\n [matMenuTriggerFor]=\"menu\"\n [disabled]=\"actionRef.disabled\"\n #matTrigger=\"matMenuTrigger\"\n >\n <adf-icon *ngIf=\"actionRef.icon\" [value]=\"actionRef.icon\"></adf-icon>\n </button>\n </ng-container>\n</ng-container>\n\n<mat-menu #menu=\"matMenu\" [overlapTrigger]=\"false\" [xPosition]=\"'before'\">\n <ng-container *ngFor=\"let child of actionRef.children; trackBy: trackByActionId\">\n <ng-container [ngSwitch]=\"child.type\">\n <ng-container *ngSwitchCase=\"'custom'\">\n <adf-dynamic-component [id]=\"child.component\" [data]=\"child.data\"></adf-dynamic-component>\n </ng-container>\n <ng-container *ngSwitchDefault>\n <app-toolbar-menu-item [actionRef]=\"child\" [menuId]=\"actionRef.id\"></app-toolbar-menu-item>\n </ng-container>\n </ng-container>\n </ng-container>\n</mat-menu>\n" }]
|
|
2191
|
-
}], propDecorators: { actionRef: [{
|
|
2192
|
-
type: Input
|
|
2193
|
-
}], color: [{
|
|
2194
|
-
type: Input
|
|
2195
|
-
}], matTrigger: [{
|
|
2196
|
-
type: ViewChild,
|
|
2197
|
-
args: ['matTrigger']
|
|
2198
|
-
}], menu: [{
|
|
2199
|
-
type: ViewChild,
|
|
2200
|
-
args: [MatMenu]
|
|
2201
|
-
}], toolbarMenuItems: [{
|
|
2202
|
-
type: ViewChildren,
|
|
2203
|
-
args: [ToolbarMenuItemComponent]
|
|
2204
|
-
}], data: [{
|
|
2205
|
-
type: Input
|
|
2206
|
-
}], handleKeydownEscape: [{
|
|
2207
|
-
type: HostListener,
|
|
2208
|
-
args: ['document:keydown.Escape']
|
|
2209
|
-
}] } });
|
|
2210
|
-
|
|
2211
|
-
/*!
|
|
2212
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
2213
|
-
*
|
|
2214
|
-
* Alfresco Example Content Application
|
|
2215
|
-
*
|
|
2216
|
-
* This file is part of the Alfresco Example Content Application.
|
|
2217
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
2218
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
2219
|
-
* provided under the following open source license terms:
|
|
2220
|
-
*
|
|
2221
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
2222
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
2223
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
2224
|
-
* (at your option) any later version.
|
|
2225
|
-
*
|
|
2226
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
2227
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
2228
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
2229
|
-
* GNU Lesser General Public License for more details.
|
|
2230
|
-
*
|
|
2231
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
2232
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
2233
|
-
*/
|
|
2234
|
-
class ToolbarActionComponent {
|
|
2235
|
-
constructor(cd) {
|
|
2236
|
-
this.cd = cd;
|
|
2237
|
-
this.type = ToolbarButtonType.ICON_BUTTON;
|
|
2238
|
-
}
|
|
2239
|
-
// todo: review after ADF 2.6
|
|
2240
|
-
// preview component : change detection workaround for children without input
|
|
2241
|
-
ngDoCheck() {
|
|
2242
|
-
if (this.actionRef.id.includes('app.viewer')) {
|
|
2243
|
-
this.cd.markForCheck();
|
|
2244
|
-
}
|
|
2245
|
-
}
|
|
2246
|
-
}
|
|
2247
|
-
ToolbarActionComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: ToolbarActionComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
2248
|
-
ToolbarActionComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: ToolbarActionComponent, isStandalone: true, selector: "aca-toolbar-action", inputs: { data: "data", type: "type", color: "color", actionRef: "actionRef" }, host: { classAttribute: "aca-toolbar-action" }, ngImport: i0, template: "<ng-container [ngSwitch]=\"actionRef.type\">\n <div *ngSwitchCase=\"'default'\">\n <app-toolbar-button [type]=\"type\" [actionRef]=\"actionRef\" [color]=\"color\"> </app-toolbar-button>\n </div>\n\n <div *ngSwitchCase=\"'button'\">\n <app-toolbar-button [type]=\"data?.buttonType || type\" [actionRef]=\"actionRef\" [color]=\"color\" [data]=\"actionRef.data\"> </app-toolbar-button>\n </div>\n\n <div *ngSwitchCase=\"'separator'\" [id]=\"actionRef.id\" class=\"aca-toolbar-divider\"></div>\n\n <ng-container *ngSwitchCase=\"'menu'\">\n <app-toolbar-menu [actionRef]=\"actionRef\" [color]=\"color\" [data]=\"actionRef.data\"></app-toolbar-menu>\n </ng-container>\n\n <div *ngSwitchCase=\"'custom'\">\n <adf-dynamic-component [data]=\"actionRef.data\" [id]=\"actionRef.component\"></adf-dynamic-component>\n </div>\n</ng-container>\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i2.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i2.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "component", type: ToolbarButtonComponent, selector: "app-toolbar-button", inputs: ["data", "type", "color", "actionRef"] }, { kind: "component", type: ToolbarMenuComponent, selector: "app-toolbar-menu", inputs: ["actionRef", "color", "data"] }, { kind: "component", type: DynamicExtensionComponent, selector: "adf-dynamic-component", inputs: ["id", "data"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
2249
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: ToolbarActionComponent, decorators: [{
|
|
2250
|
-
type: Component,
|
|
2251
|
-
args: [{ standalone: true, imports: [CommonModule, ToolbarButtonComponent, ToolbarMenuComponent, DynamicExtensionComponent], selector: 'aca-toolbar-action', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, host: { class: 'aca-toolbar-action' }, template: "<ng-container [ngSwitch]=\"actionRef.type\">\n <div *ngSwitchCase=\"'default'\">\n <app-toolbar-button [type]=\"type\" [actionRef]=\"actionRef\" [color]=\"color\"> </app-toolbar-button>\n </div>\n\n <div *ngSwitchCase=\"'button'\">\n <app-toolbar-button [type]=\"data?.buttonType || type\" [actionRef]=\"actionRef\" [color]=\"color\" [data]=\"actionRef.data\"> </app-toolbar-button>\n </div>\n\n <div *ngSwitchCase=\"'separator'\" [id]=\"actionRef.id\" class=\"aca-toolbar-divider\"></div>\n\n <ng-container *ngSwitchCase=\"'menu'\">\n <app-toolbar-menu [actionRef]=\"actionRef\" [color]=\"color\" [data]=\"actionRef.data\"></app-toolbar-menu>\n </ng-container>\n\n <div *ngSwitchCase=\"'custom'\">\n <adf-dynamic-component [data]=\"actionRef.data\" [id]=\"actionRef.component\"></adf-dynamic-component>\n </div>\n</ng-container>\n" }]
|
|
2252
|
-
}], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }]; }, propDecorators: { data: [{
|
|
2253
|
-
type: Input
|
|
2254
|
-
}], type: [{
|
|
2255
|
-
type: Input
|
|
2256
|
-
}], color: [{
|
|
2257
|
-
type: Input
|
|
2258
|
-
}], actionRef: [{
|
|
2259
|
-
type: Input
|
|
2260
|
-
}] } });
|
|
2261
|
-
|
|
2262
|
-
/*!
|
|
2263
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
2264
|
-
*
|
|
2265
|
-
* Alfresco Example Content Application
|
|
2266
|
-
*
|
|
2267
|
-
* This file is part of the Alfresco Example Content Application.
|
|
2268
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
2269
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
2270
|
-
* provided under the following open source license terms:
|
|
2271
|
-
*
|
|
2272
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
2273
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
2274
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
2275
|
-
* (at your option) any later version.
|
|
2276
|
-
*
|
|
2277
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
2278
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
2279
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
2280
|
-
* GNU Lesser General Public License for more details.
|
|
2281
|
-
*
|
|
2282
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
2283
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
2284
|
-
*/
|
|
2285
|
-
class ToolbarComponent {
|
|
2286
|
-
trackByActionId(_, action) {
|
|
2287
|
-
return action.id;
|
|
2288
|
-
}
|
|
2289
|
-
}
|
|
2290
|
-
ToolbarComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: ToolbarComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
2291
|
-
ToolbarComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: ToolbarComponent, isStandalone: true, selector: "aca-toolbar", inputs: { items: "items" }, ngImport: i0, template: "<mat-toolbar class=\"aca-toolbar\">\n <ng-container *ngFor=\"let item of items; trackBy: trackByActionId\">\n <aca-toolbar-action [actionRef]=\"item\"></aca-toolbar-action>\n </ng-container>\n</mat-toolbar>\n", styles: ["aca-toolbar .aca-toolbar{min-height:48px;color:var(--adf-theme-foreground-text-color-054);background-color:inherit;border:none;padding:0;column-gap:5px}aca-toolbar .aca-toolbar-divider{height:24px;width:1px;background:var(--adf-theme-foreground-text-color-025);margin-left:5px;margin-right:5px}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "component", type: ToolbarActionComponent, selector: "aca-toolbar-action", inputs: ["data", "type", "color", "actionRef"] }, { kind: "ngmodule", type: MatToolbarModule }, { kind: "component", type: i2$1.MatToolbar, selector: "mat-toolbar", inputs: ["color"], exportAs: ["matToolbar"] }], encapsulation: i0.ViewEncapsulation.None });
|
|
2292
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: ToolbarComponent, decorators: [{
|
|
2293
|
-
type: Component,
|
|
2294
|
-
args: [{ selector: 'aca-toolbar', standalone: true, imports: [CommonModule, ToolbarActionComponent, MatToolbarModule], encapsulation: ViewEncapsulation.None, template: "<mat-toolbar class=\"aca-toolbar\">\n <ng-container *ngFor=\"let item of items; trackBy: trackByActionId\">\n <aca-toolbar-action [actionRef]=\"item\"></aca-toolbar-action>\n </ng-container>\n</mat-toolbar>\n", styles: ["aca-toolbar .aca-toolbar{min-height:48px;color:var(--adf-theme-foreground-text-color-054);background-color:inherit;border:none;padding:0;column-gap:5px}aca-toolbar .aca-toolbar-divider{height:24px;width:1px;background:var(--adf-theme-foreground-text-color-025);margin-left:5px;margin-right:5px}\n"] }]
|
|
2295
|
-
}], propDecorators: { items: [{
|
|
2296
|
-
type: Input
|
|
2297
|
-
}] } });
|
|
2298
|
-
|
|
2299
|
-
/*!
|
|
2300
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
2301
|
-
*
|
|
2302
|
-
* Alfresco Example Content Application
|
|
2303
|
-
*
|
|
2304
|
-
* This file is part of the Alfresco Example Content Application.
|
|
2305
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
2306
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
2307
|
-
* provided under the following open source license terms:
|
|
2308
|
-
*
|
|
2309
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
2310
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
2311
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
2312
|
-
* (at your option) any later version.
|
|
2313
|
-
*
|
|
2314
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
2315
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
2316
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
2317
|
-
* GNU Lesser General Public License for more details.
|
|
2318
|
-
*
|
|
2319
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
2320
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
2321
|
-
*/
|
|
2322
|
-
class InfoDrawerComponent {
|
|
2323
|
-
onEscapeKeyboardEvent() {
|
|
2324
|
-
this.close();
|
|
2325
|
-
}
|
|
2326
|
-
constructor(store, contentApi, extensions, nodesService, contentService) {
|
|
2327
|
-
this.store = store;
|
|
2328
|
-
this.contentApi = contentApi;
|
|
2329
|
-
this.extensions = extensions;
|
|
2330
|
-
this.nodesService = nodesService;
|
|
2331
|
-
this.contentService = contentService;
|
|
2332
|
-
this.isLoading = false;
|
|
2333
|
-
this.tabs = [];
|
|
2334
|
-
this.actions = [];
|
|
2335
|
-
this.onDestroy$ = new Subject();
|
|
2336
|
-
this.preventFromClosing = false;
|
|
2337
|
-
this.icon = null;
|
|
2338
|
-
}
|
|
2339
|
-
ngOnInit() {
|
|
2340
|
-
this.tabs = this.extensions.getSidebarTabs();
|
|
2341
|
-
this.extensions
|
|
2342
|
-
.getAllowedSidebarActions()
|
|
2343
|
-
.pipe(takeUntil(this.onDestroy$))
|
|
2344
|
-
.subscribe((actions) => {
|
|
2345
|
-
this.actions = actions;
|
|
2346
|
-
});
|
|
2347
|
-
this.store
|
|
2348
|
-
.select(infoDrawerPreview)
|
|
2349
|
-
.pipe(takeUntil(this.onDestroy$))
|
|
2350
|
-
.subscribe((isInfoDrawerPreviewOpened) => {
|
|
2351
|
-
this.preventFromClosing = isInfoDrawerPreviewOpened;
|
|
2352
|
-
});
|
|
2353
|
-
this.nodesService.nodeUpdated.pipe(takeUntil(this.onDestroy$)).subscribe((node) => {
|
|
2354
|
-
this.node.entry = node;
|
|
2355
|
-
});
|
|
2356
|
-
}
|
|
2357
|
-
ngOnDestroy() {
|
|
2358
|
-
this.onDestroy$.next(true);
|
|
2359
|
-
this.onDestroy$.complete();
|
|
2360
|
-
if (!this.preventFromClosing) {
|
|
2361
|
-
this.store.dispatch(new SetInfoDrawerStateAction(false));
|
|
2362
|
-
}
|
|
2363
|
-
}
|
|
2364
|
-
ngOnChanges() {
|
|
2365
|
-
if (this.node) {
|
|
2366
|
-
if (this.node['isLibrary']) {
|
|
2367
|
-
return this.setDisplayNode(this.node);
|
|
2368
|
-
}
|
|
2369
|
-
const entry = this.node.entry;
|
|
2370
|
-
const id = entry.nodeId || entry.id;
|
|
2371
|
-
return this.loadNodeInfo(id);
|
|
2372
|
-
}
|
|
2373
|
-
}
|
|
2374
|
-
close() {
|
|
2375
|
-
this.store.dispatch(new ToggleInfoDrawerAction());
|
|
2376
|
-
}
|
|
2377
|
-
loadNodeInfo(nodeId) {
|
|
2378
|
-
if (nodeId) {
|
|
2379
|
-
this.isLoading = true;
|
|
2380
|
-
this.contentApi.getNodeInfo(nodeId).subscribe((entity) => {
|
|
2381
|
-
this.setDisplayNode(entity);
|
|
2382
|
-
this.node.entry = entity;
|
|
2383
|
-
this.isLoading = false;
|
|
2384
|
-
}, () => (this.isLoading = false));
|
|
2385
|
-
}
|
|
2386
|
-
}
|
|
2387
|
-
setDisplayNode(node) {
|
|
2388
|
-
this.displayNode = node;
|
|
2389
|
-
this.icon = this.contentService.getNodeIcon(node);
|
|
2390
|
-
}
|
|
2391
|
-
}
|
|
2392
|
-
InfoDrawerComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: InfoDrawerComponent, deps: [{ token: i1$2.Store }, { token: ContentApiService }, { token: AppExtensionService }, { token: i4.NodesApiService }, { token: i4.ContentService }], target: i0.ɵɵFactoryTarget.Component });
|
|
2393
|
-
InfoDrawerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: InfoDrawerComponent, isStandalone: true, selector: "aca-info-drawer", inputs: { nodeId: "nodeId", node: "node" }, host: { listeners: { "keydown.escape": "onEscapeKeyboardEvent()" } }, usesOnChanges: true, ngImport: i0, template: "<div *ngIf=\"isLoading\">\n <mat-progress-bar mode=\"indeterminate\" [attr.aria-label]=\"'APP.INFO_DRAWER.DATA_LOADING' | translate\"></mat-progress-bar>\n</div>\n<ng-container *ngIf=\"!isLoading && !!displayNode\">\n <adf-info-drawer [icon]=\"icon\" [title]=\"node?.entry?.name || 'APP.INFO_DRAWER.TITLE'\" cdkTrapFocusAutoCapture>\n <aca-toolbar [items]=\"actions\" info-drawer-buttons></aca-toolbar>\n\n <adf-info-drawer-tab *ngFor=\"let tab of tabs\" [icon]=\"tab.icon\" [label]=\"tab.title\">\n <adf-dynamic-tab [node]=\"$any(displayNode)\" [id]=\"tab.component\" [attr.data-automation-id]=\"tab.component\"> </adf-dynamic-tab>\n </adf-info-drawer-tab>\n </adf-info-drawer>\n</ng-container>\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i3$2.TranslatePipe, name: "translate" }, { kind: "ngmodule", type: MatProgressBarModule }, { kind: "component", type: i7$1.MatProgressBar, selector: "mat-progress-bar", inputs: ["color", "value", "bufferValue", "mode"], outputs: ["animationEnd"], exportAs: ["matProgressBar"] }, { kind: "ngmodule", type: InfoDrawerModule }, { kind: "component", type: i1.InfoDrawerTabComponent, selector: "adf-info-drawer-tab", inputs: ["label", "icon"] }, { kind: "component", type: i1.InfoDrawerComponent, selector: "adf-info-drawer", inputs: ["title", "icon", "selectedIndex", "showHeader"], outputs: ["currentTab"] }, { kind: "directive", type: i1.InfoDrawerButtonsDirective, selector: "[adf-info-drawer-buttons], [info-drawer-buttons]" }, { kind: "ngmodule", type: A11yModule }, { kind: "component", type: ToolbarComponent, selector: "aca-toolbar", inputs: ["items"] }, { kind: "component", type: DynamicTabComponent, selector: "adf-dynamic-tab", inputs: ["id", "node"] }], encapsulation: i0.ViewEncapsulation.None });
|
|
2394
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: InfoDrawerComponent, decorators: [{
|
|
2395
|
-
type: Component,
|
|
2396
|
-
args: [{ standalone: true, imports: [CommonModule, TranslateModule, MatProgressBarModule, InfoDrawerModule, A11yModule, ToolbarComponent, DynamicTabComponent], selector: 'aca-info-drawer', encapsulation: ViewEncapsulation.None, template: "<div *ngIf=\"isLoading\">\n <mat-progress-bar mode=\"indeterminate\" [attr.aria-label]=\"'APP.INFO_DRAWER.DATA_LOADING' | translate\"></mat-progress-bar>\n</div>\n<ng-container *ngIf=\"!isLoading && !!displayNode\">\n <adf-info-drawer [icon]=\"icon\" [title]=\"node?.entry?.name || 'APP.INFO_DRAWER.TITLE'\" cdkTrapFocusAutoCapture>\n <aca-toolbar [items]=\"actions\" info-drawer-buttons></aca-toolbar>\n\n <adf-info-drawer-tab *ngFor=\"let tab of tabs\" [icon]=\"tab.icon\" [label]=\"tab.title\">\n <adf-dynamic-tab [node]=\"$any(displayNode)\" [id]=\"tab.component\" [attr.data-automation-id]=\"tab.component\"> </adf-dynamic-tab>\n </adf-info-drawer-tab>\n </adf-info-drawer>\n</ng-container>\n" }]
|
|
2397
|
-
}], ctorParameters: function () { return [{ type: i1$2.Store }, { type: ContentApiService }, { type: AppExtensionService }, { type: i4.NodesApiService }, { type: i4.ContentService }]; }, propDecorators: { nodeId: [{
|
|
2398
|
-
type: Input
|
|
2399
|
-
}], node: [{
|
|
2400
|
-
type: Input
|
|
2401
|
-
}], onEscapeKeyboardEvent: [{
|
|
2402
|
-
type: HostListener,
|
|
2403
|
-
args: ['keydown.escape']
|
|
2404
|
-
}] } });
|
|
2405
|
-
|
|
2406
|
-
/*!
|
|
2407
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
2408
|
-
*
|
|
2409
|
-
* Alfresco Example Content Application
|
|
2410
|
-
*
|
|
2411
|
-
* This file is part of the Alfresco Example Content Application.
|
|
2412
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
2413
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
2414
|
-
* provided under the following open source license terms:
|
|
2415
|
-
*
|
|
2416
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
2417
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
2418
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
2419
|
-
* (at your option) any later version.
|
|
2420
|
-
*
|
|
2421
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
2422
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
2423
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
2424
|
-
* GNU Lesser General Public License for more details.
|
|
2425
|
-
*
|
|
2426
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
2427
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
2428
|
-
*/
|
|
2429
|
-
class DocumentBasePageService {
|
|
2430
|
-
}
|
|
2431
|
-
|
|
2432
|
-
/*!
|
|
2433
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
2434
|
-
*
|
|
2435
|
-
* Alfresco Example Content Application
|
|
2436
|
-
*
|
|
2437
|
-
* This file is part of the Alfresco Example Content Application.
|
|
2438
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
2439
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
2440
|
-
* provided under the following open source license terms:
|
|
2441
|
-
*
|
|
2442
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
2443
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
2444
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
2445
|
-
* (at your option) any later version.
|
|
2446
|
-
*
|
|
2447
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
2448
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
2449
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
2450
|
-
* GNU Lesser General Public License for more details.
|
|
2451
|
-
*
|
|
2452
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
2453
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
2454
|
-
*/
|
|
2455
|
-
function isLocked(node) {
|
|
2456
|
-
var _a, _b;
|
|
2457
|
-
if (node === null || node === void 0 ? void 0 : node.entry) {
|
|
2458
|
-
const { entry } = node;
|
|
2459
|
-
return entry.isLocked || ((_a = entry.properties) === null || _a === void 0 ? void 0 : _a['cm:lockType']) === 'READ_ONLY_LOCK' || ((_b = entry.properties) === null || _b === void 0 ? void 0 : _b['cm:lockType']) === 'WRITE_LOCK';
|
|
2460
|
-
}
|
|
2461
|
-
else {
|
|
2462
|
-
return false;
|
|
2463
|
-
}
|
|
2464
|
-
}
|
|
2465
|
-
function isLibrary(node) {
|
|
2466
|
-
if (node === null || node === void 0 ? void 0 : node.entry) {
|
|
2467
|
-
const { entry } = node;
|
|
2468
|
-
return !!(entry.guid && entry.id && entry.preset && entry.title && entry.visibility) || entry.nodeType === 'st:site';
|
|
2469
|
-
}
|
|
2470
|
-
else {
|
|
2471
|
-
return false;
|
|
2472
|
-
}
|
|
2473
|
-
}
|
|
2474
|
-
|
|
2475
|
-
/*!
|
|
2476
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
2477
|
-
*
|
|
2478
|
-
* Alfresco Example Content Application
|
|
2479
|
-
*
|
|
2480
|
-
* This file is part of the Alfresco Example Content Application.
|
|
2481
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
2482
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
2483
|
-
* provided under the following open source license terms:
|
|
2484
|
-
*
|
|
2485
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
2486
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
2487
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
2488
|
-
* (at your option) any later version.
|
|
2489
|
-
*
|
|
2490
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
2491
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
2492
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
2493
|
-
* GNU Lesser General Public License for more details.
|
|
2494
|
-
*
|
|
2495
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
2496
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
2497
|
-
*/
|
|
2498
|
-
const BYTES_TO_MB_CONVERSION_VALUE = 1048576;
|
|
2499
|
-
class AutoDownloadService {
|
|
2500
|
-
constructor() {
|
|
2501
|
-
this.dialog = inject(MatDialog);
|
|
2502
|
-
}
|
|
2503
|
-
shouldDownload(node, threshold) {
|
|
2504
|
-
var _a, _b;
|
|
2505
|
-
const fileSizeInBytes = ((_b = (_a = node === null || node === void 0 ? void 0 : node.entry) === null || _a === void 0 ? void 0 : _a.content) === null || _b === void 0 ? void 0 : _b.sizeInBytes) || 0;
|
|
2506
|
-
const sizeInMB = fileSizeInBytes / BYTES_TO_MB_CONVERSION_VALUE;
|
|
2507
|
-
return sizeInMB && sizeInMB > threshold;
|
|
2508
|
-
}
|
|
2509
|
-
/**
|
|
2510
|
-
* Opens the dialog to download the node content.
|
|
2511
|
-
* Determines whether node content should be auto downloaded based on the file size and the configured threshold.
|
|
2512
|
-
* @param node node entry
|
|
2513
|
-
* @param threshold file size threshold in MB
|
|
2514
|
-
*/
|
|
2515
|
-
tryDownload(node, threshold) {
|
|
2516
|
-
if (this.shouldDownload(node, threshold)) {
|
|
2517
|
-
this.dialog.open(FileAutoDownloadComponent, { disableClose: true, data: node });
|
|
2518
|
-
return true;
|
|
2519
|
-
}
|
|
2520
|
-
return false;
|
|
2521
|
-
}
|
|
2522
|
-
}
|
|
2523
|
-
AutoDownloadService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: AutoDownloadService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
2524
|
-
AutoDownloadService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: AutoDownloadService, providedIn: 'root' });
|
|
2525
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: AutoDownloadService, decorators: [{
|
|
2526
|
-
type: Injectable,
|
|
2527
|
-
args: [{
|
|
2528
|
-
providedIn: 'root'
|
|
2529
|
-
}]
|
|
2530
|
-
}] });
|
|
2531
|
-
|
|
2532
|
-
/*!
|
|
2533
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
2534
|
-
*
|
|
2535
|
-
* Alfresco Example Content Application
|
|
2536
|
-
*
|
|
2537
|
-
* This file is part of the Alfresco Example Content Application.
|
|
2538
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
2539
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
2540
|
-
* provided under the following open source license terms:
|
|
2541
|
-
*
|
|
2542
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
2543
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
2544
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
2545
|
-
* (at your option) any later version.
|
|
2546
|
-
*
|
|
2547
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
2548
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
2549
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
2550
|
-
* GNU Lesser General Public License for more details.
|
|
2551
|
-
*
|
|
2552
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
2553
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
2554
|
-
*/
|
|
2555
|
-
/* eslint-disable @angular-eslint/directive-class-suffix */
|
|
2556
|
-
class PageComponent {
|
|
2557
|
-
constructor() {
|
|
2558
|
-
this.onDestroy$ = new Subject();
|
|
2559
|
-
this.title = 'Page';
|
|
2560
|
-
this.actions = [];
|
|
2561
|
-
this.viewerToolbarActions = [];
|
|
2562
|
-
this.bulkActions = [];
|
|
2563
|
-
this.canUpdateNode = false;
|
|
2564
|
-
this.canUpload = false;
|
|
2565
|
-
this.showHeader = ShowHeaderMode.Data;
|
|
2566
|
-
this.filterSorting = 'name-asc';
|
|
2567
|
-
this.createActions = [];
|
|
2568
|
-
this.isSmallScreen = false;
|
|
2569
|
-
this.selectedRowItemsCount = 0;
|
|
2570
|
-
this.documentListService = inject(DocumentListService);
|
|
2571
|
-
this.settings = inject(AppSettingsService);
|
|
2572
|
-
this.extensions = inject(AppExtensionService);
|
|
2573
|
-
this.content = inject(DocumentBasePageService);
|
|
2574
|
-
this.store = inject((Store));
|
|
2575
|
-
this.breakpointObserver = inject(BreakpointObserver);
|
|
2576
|
-
this.uploadService = inject(UploadService);
|
|
2577
|
-
this.router = inject(Router);
|
|
2578
|
-
this.autoDownloadService = inject(AutoDownloadService, { optional: true });
|
|
2579
|
-
this.searchAiService = inject(SearchAiService);
|
|
2580
|
-
this.subscriptions = [];
|
|
2581
|
-
this._searchAiInputState = {
|
|
2582
|
-
active: false
|
|
2583
|
-
};
|
|
2584
|
-
}
|
|
2585
|
-
get searchAiInputState() {
|
|
2586
|
-
return this._searchAiInputState;
|
|
2587
|
-
}
|
|
2588
|
-
ngOnInit() {
|
|
2589
|
-
this.extensions
|
|
2590
|
-
.getCreateActions()
|
|
2591
|
-
.pipe(takeUntil(this.onDestroy$))
|
|
2592
|
-
.subscribe((actions) => {
|
|
2593
|
-
this.createActions = actions;
|
|
2594
|
-
});
|
|
2595
|
-
this.infoDrawerOpened$ = this.store.select(isInfoDrawerOpened);
|
|
2596
|
-
this.store
|
|
2597
|
-
.select(getAppSelection)
|
|
2598
|
-
.pipe(takeUntil(this.onDestroy$))
|
|
2599
|
-
.subscribe((selection) => {
|
|
2600
|
-
this.selection = selection;
|
|
2601
|
-
this.canUpdateNode = this.selection.count === 1 && this.content.canUpdateNode(selection.first);
|
|
2602
|
-
});
|
|
2603
|
-
this.extensions
|
|
2604
|
-
.getAllowedToolbarActions()
|
|
2605
|
-
.pipe(takeUntil(this.onDestroy$))
|
|
2606
|
-
.subscribe((actions) => {
|
|
2607
|
-
this.actions = actions;
|
|
2608
|
-
});
|
|
2609
|
-
this.extensions
|
|
2610
|
-
.getBulkActions()
|
|
2611
|
-
.pipe(takeUntil(this.onDestroy$))
|
|
2612
|
-
.subscribe((actions) => {
|
|
2613
|
-
this.bulkActions = actions;
|
|
2614
|
-
});
|
|
2615
|
-
this.extensions
|
|
2616
|
-
.getViewerToolbarActions()
|
|
2617
|
-
.pipe(takeUntil(this.onDestroy$))
|
|
2618
|
-
.subscribe((actions) => {
|
|
2619
|
-
this.viewerToolbarActions = actions;
|
|
2620
|
-
});
|
|
2621
|
-
this.store
|
|
2622
|
-
.select(getCurrentFolder)
|
|
2623
|
-
.pipe(takeUntil(this.onDestroy$))
|
|
2624
|
-
.subscribe((node) => {
|
|
2625
|
-
this.canUpload = node && this.content.canUploadContent(node);
|
|
2626
|
-
});
|
|
2627
|
-
this.breakpointObserver
|
|
2628
|
-
.observe([Breakpoints.HandsetPortrait, Breakpoints.HandsetLandscape])
|
|
2629
|
-
.pipe(takeUntil(this.onDestroy$))
|
|
2630
|
-
.subscribe((result) => {
|
|
2631
|
-
this.isSmallScreen = result.matches;
|
|
2632
|
-
});
|
|
2633
|
-
this.searchAiService.toggleSearchAiInput$
|
|
2634
|
-
.pipe(takeUntil(this.onDestroy$))
|
|
2635
|
-
.subscribe((searchAiInputState) => (this._searchAiInputState = searchAiInputState));
|
|
2636
|
-
}
|
|
2637
|
-
ngOnChanges(changes) {
|
|
2638
|
-
var _a;
|
|
2639
|
-
if ((_a = changes.nodeResult) === null || _a === void 0 ? void 0 : _a.currentValue) {
|
|
2640
|
-
this.nodeResult = changes.nodeResult.currentValue;
|
|
2641
|
-
}
|
|
2642
|
-
}
|
|
2643
|
-
ngOnDestroy() {
|
|
2644
|
-
this.subscriptions.forEach((subscription) => subscription.unsubscribe());
|
|
2645
|
-
this.subscriptions = [];
|
|
2646
|
-
this.onDestroy$.next(true);
|
|
2647
|
-
this.onDestroy$.complete();
|
|
2648
|
-
this.store.dispatch(new SetSelectedNodesAction([]));
|
|
2649
|
-
}
|
|
2650
|
-
showPreview(node, extras) {
|
|
2651
|
-
if (node === null || node === void 0 ? void 0 : node.entry) {
|
|
2652
|
-
if (!this.settings.autoDownloadEnabled || !this.autoDownloadService.tryDownload(node, this.settings.authDownloadThreshold)) {
|
|
2653
|
-
let id;
|
|
2654
|
-
if (node.entry.nodeType === 'app:filelink') {
|
|
2655
|
-
id = node.entry.properties['cm:destination'];
|
|
2656
|
-
}
|
|
2657
|
-
else {
|
|
2658
|
-
id = node.entry.nodeId || node.entry.guid || node.entry.id;
|
|
2659
|
-
}
|
|
2660
|
-
this.store.dispatch(new ViewNodeAction(id, extras));
|
|
2661
|
-
}
|
|
2662
|
-
}
|
|
2663
|
-
}
|
|
2664
|
-
onSelectedItemsCountChanged(count) {
|
|
2665
|
-
this.selectedRowItemsCount = count;
|
|
2666
|
-
}
|
|
2667
|
-
getParentNodeId() {
|
|
2668
|
-
return this.node ? this.node.id : null;
|
|
2669
|
-
}
|
|
2670
|
-
imageResolver(row) {
|
|
2671
|
-
if (row) {
|
|
2672
|
-
if (isLocked(row.node)) {
|
|
2673
|
-
return 'material-icons://lock';
|
|
2674
|
-
}
|
|
2675
|
-
if (isLibrary(row.node)) {
|
|
2676
|
-
return 'material-icons://library_books';
|
|
2677
|
-
}
|
|
2678
|
-
}
|
|
2679
|
-
return null;
|
|
2680
|
-
}
|
|
2681
|
-
reload(selectedNode) {
|
|
2682
|
-
if (this.isOutletPreviewUrl()) {
|
|
2683
|
-
return;
|
|
2684
|
-
}
|
|
2685
|
-
this.documentListService.reload();
|
|
2686
|
-
if (selectedNode) {
|
|
2687
|
-
this.store.dispatch(new SetSelectedNodesAction([selectedNode]));
|
|
2688
|
-
}
|
|
2689
|
-
}
|
|
2690
|
-
trackByActionId(_, action) {
|
|
2691
|
-
return action.id;
|
|
2692
|
-
}
|
|
2693
|
-
trackById(_, obj) {
|
|
2694
|
-
return obj.id;
|
|
2695
|
-
}
|
|
2696
|
-
trackByColumnId(_, obj) {
|
|
2697
|
-
return obj.id;
|
|
2698
|
-
}
|
|
2699
|
-
isOutletPreviewUrl() {
|
|
2700
|
-
return location.href.includes('viewer:view');
|
|
2701
|
-
}
|
|
2702
|
-
onSortingChanged(event) {
|
|
2703
|
-
this.filterSorting = event.detail.key + '-' + event.detail.direction;
|
|
2704
|
-
}
|
|
2705
|
-
onAllFilterCleared() {
|
|
2706
|
-
if (!this.isOutletPreviewUrl()) {
|
|
2707
|
-
this.documentList.node = null;
|
|
2708
|
-
this.documentListService.reload();
|
|
2709
|
-
}
|
|
2710
|
-
}
|
|
2711
|
-
}
|
|
2712
|
-
PageComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: PageComponent, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
2713
|
-
PageComponent.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.10", type: PageComponent, host: { listeners: { "sorting-changed": "onSortingChanged($event)" } }, viewQueries: [{ propertyName: "documentList", first: true, predicate: DocumentListComponent, descendants: true }], usesOnChanges: true, ngImport: i0 });
|
|
2714
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: PageComponent, decorators: [{
|
|
2715
|
-
type: Directive
|
|
2716
|
-
}], propDecorators: { documentList: [{
|
|
2717
|
-
type: ViewChild,
|
|
2718
|
-
args: [DocumentListComponent]
|
|
2719
|
-
}], onSortingChanged: [{
|
|
2720
|
-
type: HostListener,
|
|
2721
|
-
args: ['sorting-changed', ['$event']]
|
|
2722
|
-
}] } });
|
|
2723
|
-
|
|
2724
|
-
/*!
|
|
2725
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
2726
|
-
*
|
|
2727
|
-
* Alfresco Example Content Application
|
|
2728
|
-
*
|
|
2729
|
-
* This file is part of the Alfresco Example Content Application.
|
|
2730
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
2731
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
2732
|
-
* provided under the following open source license terms:
|
|
2733
|
-
*
|
|
2734
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
2735
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
2736
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
2737
|
-
* (at your option) any later version.
|
|
2738
|
-
*
|
|
2739
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
2740
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
2741
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
2742
|
-
* GNU Lesser General Public License for more details.
|
|
2743
|
-
*
|
|
2744
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
2745
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
2746
|
-
*/
|
|
2747
|
-
|
|
2748
|
-
/*!
|
|
2749
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
2750
|
-
*
|
|
2751
|
-
* Alfresco Example Content Application
|
|
2752
|
-
*
|
|
2753
|
-
* This file is part of the Alfresco Example Content Application.
|
|
2754
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
2755
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
2756
|
-
* provided under the following open source license terms:
|
|
2757
|
-
*
|
|
2758
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
2759
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
2760
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
2761
|
-
* (at your option) any later version.
|
|
2762
|
-
*
|
|
2763
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
2764
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
2765
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
2766
|
-
* GNU Lesser General Public License for more details.
|
|
2767
|
-
*
|
|
2768
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
2769
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
2770
|
-
*/
|
|
2771
|
-
class ContextActionsDirective {
|
|
2772
|
-
onContextMenuEvent(event) {
|
|
2773
|
-
if (event) {
|
|
2774
|
-
event.preventDefault();
|
|
2775
|
-
if (this.enabled) {
|
|
2776
|
-
const target = this.getTarget(event);
|
|
2777
|
-
if (target) {
|
|
2778
|
-
this.execute(event, target);
|
|
2779
|
-
}
|
|
2780
|
-
}
|
|
2781
|
-
}
|
|
2782
|
-
}
|
|
2783
|
-
constructor(store) {
|
|
2784
|
-
this.store = store;
|
|
2785
|
-
this.execute$ = new Subject();
|
|
2786
|
-
this.onDestroy$ = new Subject();
|
|
2787
|
-
// eslint-disable-next-line
|
|
2788
|
-
this.enabled = true;
|
|
2789
|
-
}
|
|
2790
|
-
ngOnInit() {
|
|
2791
|
-
this.execute$.pipe(debounceTime(300), takeUntil(this.onDestroy$)).subscribe((event) => {
|
|
2792
|
-
this.store.dispatch(new ContextMenu(event));
|
|
2793
|
-
});
|
|
2794
|
-
}
|
|
2795
|
-
ngOnDestroy() {
|
|
2796
|
-
this.onDestroy$.next(true);
|
|
2797
|
-
this.onDestroy$.complete();
|
|
2798
|
-
}
|
|
2799
|
-
execute(event, target) {
|
|
2800
|
-
if (!this.isSelected(target)) {
|
|
2801
|
-
target.dispatchEvent(new MouseEvent('click'));
|
|
2802
|
-
}
|
|
2803
|
-
if (this.isEmptyTable(target)) {
|
|
2804
|
-
return null;
|
|
2805
|
-
}
|
|
2806
|
-
this.execute$.next(event);
|
|
2807
|
-
}
|
|
2808
|
-
getTarget(event) {
|
|
2809
|
-
const target = event.target;
|
|
2810
|
-
return this.findAncestor(target, 'adf-datatable-cell');
|
|
2811
|
-
}
|
|
2812
|
-
isSelected(target) {
|
|
2813
|
-
if (!target) {
|
|
2814
|
-
return false;
|
|
2815
|
-
}
|
|
2816
|
-
return this.findAncestor(target, 'adf-datatable-row').classList.contains('adf-is-selected');
|
|
2817
|
-
}
|
|
2818
|
-
isEmptyTable(target) {
|
|
2819
|
-
return this.findAncestor(target, 'adf-datatable-cell').classList.contains('adf-no-content-container');
|
|
2820
|
-
}
|
|
2821
|
-
findAncestor(el, className) {
|
|
2822
|
-
while (el && !el.classList.contains(className)) {
|
|
2823
|
-
el = el.parentElement;
|
|
2824
|
-
}
|
|
2825
|
-
return el;
|
|
2826
|
-
}
|
|
2827
|
-
}
|
|
2828
|
-
ContextActionsDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: ContextActionsDirective, deps: [{ token: i1$2.Store }], target: i0.ɵɵFactoryTarget.Directive });
|
|
2829
|
-
ContextActionsDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.10", type: ContextActionsDirective, isStandalone: true, selector: "[acaContextActions]", inputs: { enabled: ["acaContextEnable", "enabled"] }, host: { listeners: { "contextmenu": "onContextMenuEvent($event)" } }, exportAs: ["acaContextActions"], ngImport: i0 });
|
|
2830
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: ContextActionsDirective, decorators: [{
|
|
2831
|
-
type: Directive,
|
|
2832
|
-
args: [{
|
|
2833
|
-
standalone: true,
|
|
2834
|
-
selector: '[acaContextActions]',
|
|
2835
|
-
exportAs: 'acaContextActions'
|
|
2836
|
-
}]
|
|
2837
|
-
}], ctorParameters: function () { return [{ type: i1$2.Store }]; }, propDecorators: { enabled: [{
|
|
2838
|
-
type: Input,
|
|
2839
|
-
args: ['acaContextEnable']
|
|
2840
|
-
}], onContextMenuEvent: [{
|
|
2841
|
-
type: HostListener,
|
|
2842
|
-
args: ['contextmenu', ['$event']]
|
|
2843
|
-
}] } });
|
|
2844
|
-
|
|
2845
|
-
/*!
|
|
2846
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
2847
|
-
*
|
|
2848
|
-
* Alfresco Example Content Application
|
|
2849
|
-
*
|
|
2850
|
-
* This file is part of the Alfresco Example Content Application.
|
|
2851
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
2852
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
2853
|
-
* provided under the following open source license terms:
|
|
2854
|
-
*
|
|
2855
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
2856
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
2857
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
2858
|
-
* (at your option) any later version.
|
|
2859
|
-
*
|
|
2860
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
2861
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
2862
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
2863
|
-
* GNU Lesser General Public License for more details.
|
|
2864
|
-
*
|
|
2865
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
2866
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
2867
|
-
*/
|
|
2868
|
-
class PaginationDirective {
|
|
2869
|
-
constructor(pagination, preferences, config) {
|
|
2870
|
-
this.pagination = pagination;
|
|
2871
|
-
this.preferences = preferences;
|
|
2872
|
-
this.config = config;
|
|
2873
|
-
this.subscriptions = [];
|
|
2874
|
-
}
|
|
2875
|
-
ngOnInit() {
|
|
2876
|
-
this.pagination.supportedPageSizes = this.config.get('pagination.supportedPageSizes');
|
|
2877
|
-
this.subscriptions.push(this.pagination.changePageSize.subscribe((event) => {
|
|
2878
|
-
this.preferences.paginationSize = event.maxItems;
|
|
2879
|
-
}));
|
|
2880
|
-
}
|
|
2881
|
-
ngOnDestroy() {
|
|
2882
|
-
this.subscriptions.forEach((subscription) => subscription.unsubscribe());
|
|
2883
|
-
this.subscriptions = [];
|
|
2884
|
-
}
|
|
2885
|
-
}
|
|
2886
|
-
PaginationDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: PaginationDirective, deps: [{ token: i1.PaginationComponent }, { token: i1.UserPreferencesService }, { token: i1.AppConfigService }], target: i0.ɵɵFactoryTarget.Directive });
|
|
2887
|
-
PaginationDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "15.2.10", type: PaginationDirective, isStandalone: true, selector: "[acaPagination]", ngImport: i0 });
|
|
2888
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: PaginationDirective, decorators: [{
|
|
2889
|
-
type: Directive,
|
|
2890
|
-
args: [{
|
|
2891
|
-
standalone: true,
|
|
2892
|
-
selector: '[acaPagination]'
|
|
2893
|
-
}]
|
|
2894
|
-
}], ctorParameters: function () { return [{ type: i1.PaginationComponent }, { type: i1.UserPreferencesService }, { type: i1.AppConfigService }]; } });
|
|
2895
|
-
|
|
2896
|
-
/*!
|
|
2897
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
2898
|
-
*
|
|
2899
|
-
* Alfresco Example Content Application
|
|
2900
|
-
*
|
|
2901
|
-
* This file is part of the Alfresco Example Content Application.
|
|
2902
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
2903
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
2904
|
-
* provided under the following open source license terms:
|
|
2905
|
-
*
|
|
2906
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
2907
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
2908
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
2909
|
-
* (at your option) any later version.
|
|
2910
|
-
*
|
|
2911
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
2912
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
2913
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
2914
|
-
* GNU Lesser General Public License for more details.
|
|
2915
|
-
*
|
|
2916
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
2917
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
2918
|
-
*/
|
|
2919
|
-
const AppSharedRuleGuard = () => {
|
|
2920
|
-
const store = inject((Store));
|
|
2921
|
-
return store.select(isQuickShareEnabled);
|
|
2922
|
-
};
|
|
2923
|
-
|
|
2924
|
-
/*!
|
|
2925
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
2926
|
-
*
|
|
2927
|
-
* Alfresco Example Content Application
|
|
2928
|
-
*
|
|
2929
|
-
* This file is part of the Alfresco Example Content Application.
|
|
2930
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
2931
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
2932
|
-
* provided under the following open source license terms:
|
|
2933
|
-
*
|
|
2934
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
2935
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
2936
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
2937
|
-
* (at your option) any later version.
|
|
2938
|
-
*
|
|
2939
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
2940
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
2941
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
2942
|
-
* GNU Lesser General Public License for more details.
|
|
2943
|
-
*
|
|
2944
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
2945
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
2946
|
-
*/
|
|
2947
|
-
const PluginEnabledGuard = (route) => {
|
|
2948
|
-
const appConfigService = inject(AppConfigService);
|
|
2949
|
-
const router = inject(Router);
|
|
2950
|
-
const isPluginEnabled = appConfigService.get(route.data.plugin, true);
|
|
2951
|
-
if (!isPluginEnabled) {
|
|
2952
|
-
router.navigate(['/']);
|
|
2953
|
-
}
|
|
2954
|
-
return isPluginEnabled;
|
|
2955
|
-
};
|
|
2956
|
-
|
|
2957
|
-
/*!
|
|
2958
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
2959
|
-
*
|
|
2960
|
-
* Alfresco Example Content Application
|
|
2961
|
-
*
|
|
2962
|
-
* This file is part of the Alfresco Example Content Application.
|
|
2963
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
2964
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
2965
|
-
* provided under the following open source license terms:
|
|
2966
|
-
*
|
|
2967
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
2968
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
2969
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
2970
|
-
* (at your option) any later version.
|
|
2971
|
-
*
|
|
2972
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
2973
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
2974
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
2975
|
-
* GNU Lesser General Public License for more details.
|
|
2976
|
-
*
|
|
2977
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
2978
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
2979
|
-
*/
|
|
2980
|
-
class AppHookService {
|
|
2981
|
-
constructor() {
|
|
2982
|
-
/**
|
|
2983
|
-
* Gets emitted when user delete the node
|
|
2984
|
-
*/
|
|
2985
|
-
this.nodesDeleted = new Subject();
|
|
2986
|
-
/**
|
|
2987
|
-
* Gets emitted when user delete the library
|
|
2988
|
-
*/
|
|
2989
|
-
this.libraryDeleted = new Subject();
|
|
2990
|
-
/**
|
|
2991
|
-
* Gets emitted when user create the library
|
|
2992
|
-
*/
|
|
2993
|
-
this.libraryCreated = new Subject();
|
|
2994
|
-
/**
|
|
2995
|
-
* Gets emitted when user update the library
|
|
2996
|
-
*/
|
|
2997
|
-
this.libraryUpdated = new Subject();
|
|
2998
|
-
/**
|
|
2999
|
-
* Gets emitted when user join the library
|
|
3000
|
-
*/
|
|
3001
|
-
this.libraryJoined = new Subject();
|
|
3002
|
-
/**
|
|
3003
|
-
* Gets emitted when user left the library
|
|
3004
|
-
*/
|
|
3005
|
-
this.libraryLeft = new Subject();
|
|
3006
|
-
/**
|
|
3007
|
-
* Gets emitted when library throws 400 error code
|
|
3008
|
-
*/
|
|
3009
|
-
this.library400Error = new Subject();
|
|
3010
|
-
/**
|
|
3011
|
-
* Gets emitted when user join the library
|
|
3012
|
-
*/
|
|
3013
|
-
this.joinLibraryToggle = new Subject();
|
|
3014
|
-
/**
|
|
3015
|
-
* Gets emitted when user unlink the node
|
|
3016
|
-
*/
|
|
3017
|
-
this.linksUnshared = new Subject();
|
|
3018
|
-
/**
|
|
3019
|
-
* Gets emitted when user mark the favorite library
|
|
3020
|
-
*/
|
|
3021
|
-
this.favoriteLibraryToggle = new Subject();
|
|
3022
|
-
}
|
|
3023
|
-
}
|
|
3024
|
-
AppHookService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: AppHookService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
3025
|
-
AppHookService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: AppHookService, providedIn: 'root' });
|
|
3026
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: AppHookService, decorators: [{
|
|
3027
|
-
type: Injectable,
|
|
3028
|
-
args: [{
|
|
3029
|
-
providedIn: 'root'
|
|
3030
|
-
}]
|
|
3031
|
-
}] });
|
|
3032
|
-
|
|
3033
|
-
/*!
|
|
3034
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
3035
|
-
*
|
|
3036
|
-
* Alfresco Example Content Application
|
|
3037
|
-
*
|
|
3038
|
-
* This file is part of the Alfresco Example Content Application.
|
|
3039
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
3040
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
3041
|
-
* provided under the following open source license terms:
|
|
3042
|
-
*
|
|
3043
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
3044
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
3045
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
3046
|
-
* (at your option) any later version.
|
|
3047
|
-
*
|
|
3048
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
3049
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
3050
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
3051
|
-
* GNU Lesser General Public License for more details.
|
|
3052
|
-
*
|
|
3053
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
3054
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
3055
|
-
*/
|
|
3056
|
-
const initialState = {
|
|
3057
|
-
app: {
|
|
3058
|
-
appName: 'Alfresco Content Application',
|
|
3059
|
-
logoPath: 'assets/images/alfresco-logo-white.svg',
|
|
3060
|
-
sharedUrl: '',
|
|
3061
|
-
user: {
|
|
3062
|
-
isAdmin: null,
|
|
3063
|
-
id: null,
|
|
3064
|
-
firstName: '',
|
|
3065
|
-
lastName: ''
|
|
3066
|
-
},
|
|
3067
|
-
selection: {
|
|
3068
|
-
nodes: [],
|
|
3069
|
-
libraries: [],
|
|
3070
|
-
isEmpty: true,
|
|
3071
|
-
count: 0
|
|
3072
|
-
},
|
|
3073
|
-
navigation: {
|
|
3074
|
-
currentFolder: null
|
|
3075
|
-
},
|
|
3076
|
-
infoDrawerOpened: false,
|
|
3077
|
-
infoDrawerMetadataAspect: '',
|
|
3078
|
-
showFacetFilter: true,
|
|
3079
|
-
repository: {
|
|
3080
|
-
status: {
|
|
3081
|
-
isQuickShareEnabled: true
|
|
3082
|
-
}
|
|
3083
|
-
}
|
|
3084
|
-
}
|
|
3085
|
-
};
|
|
3086
|
-
const discoveryApiServiceMockValue = {
|
|
3087
|
-
ecmProductInfo$: new BehaviorSubject(null),
|
|
3088
|
-
getEcmProductInfo: () => of(new RepositoryInfo({
|
|
3089
|
-
version: {
|
|
3090
|
-
major: '10.0.0'
|
|
3091
|
-
}
|
|
3092
|
-
}))
|
|
3093
|
-
};
|
|
3094
|
-
class DocumentBasePageServiceMock extends DocumentBasePageService {
|
|
3095
|
-
canUpdateNode() {
|
|
3096
|
-
return true;
|
|
3097
|
-
}
|
|
3098
|
-
canUploadContent() {
|
|
3099
|
-
return true;
|
|
3100
|
-
}
|
|
3101
|
-
}
|
|
3102
|
-
DocumentBasePageServiceMock.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: DocumentBasePageServiceMock, deps: null, target: i0.ɵɵFactoryTarget.Injectable });
|
|
3103
|
-
DocumentBasePageServiceMock.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: DocumentBasePageServiceMock });
|
|
3104
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: DocumentBasePageServiceMock, decorators: [{
|
|
3105
|
-
type: Injectable
|
|
3106
|
-
}] });
|
|
3107
|
-
class LibTestingModule {
|
|
3108
|
-
}
|
|
3109
|
-
LibTestingModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: LibTestingModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
3110
|
-
LibTestingModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: LibTestingModule, imports: [NoopAnimationsModule,
|
|
3111
|
-
CommonModule,
|
|
3112
|
-
HttpClientModule,
|
|
3113
|
-
RouterTestingModule,
|
|
3114
|
-
MatIconTestingModule,
|
|
3115
|
-
StoreModule,
|
|
3116
|
-
OverlayModule, i1$2.StoreRootModule, i2$2.EffectsRootModule, i3$2.TranslateModule], exports: [TranslateModule] });
|
|
3117
|
-
LibTestingModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: LibTestingModule, providers: [
|
|
3118
|
-
{ provide: AlfrescoApiService, useClass: AlfrescoApiServiceMock },
|
|
3119
|
-
{ provide: TranslationService, useClass: TranslationMock }
|
|
3120
|
-
], imports: [NoopAnimationsModule,
|
|
3121
|
-
CommonModule,
|
|
3122
|
-
HttpClientModule,
|
|
3123
|
-
RouterTestingModule,
|
|
3124
|
-
MatIconTestingModule,
|
|
3125
|
-
StoreModule,
|
|
3126
|
-
OverlayModule,
|
|
3127
|
-
StoreModule.forRoot({ app: null }, {
|
|
3128
|
-
initialState,
|
|
3129
|
-
runtimeChecks: {
|
|
3130
|
-
strictStateImmutability: false,
|
|
3131
|
-
strictActionImmutability: false
|
|
3132
|
-
}
|
|
3133
|
-
}),
|
|
3134
|
-
EffectsModule.forRoot([]),
|
|
3135
|
-
TranslateModule.forRoot({
|
|
3136
|
-
loader: {
|
|
3137
|
-
provide: TranslateLoader,
|
|
3138
|
-
useClass: TranslateLoaderService
|
|
3139
|
-
}
|
|
3140
|
-
}), TranslateModule] });
|
|
3141
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: LibTestingModule, decorators: [{
|
|
3142
|
-
type: NgModule,
|
|
3143
|
-
args: [{
|
|
3144
|
-
imports: [
|
|
3145
|
-
NoopAnimationsModule,
|
|
3146
|
-
CommonModule,
|
|
3147
|
-
HttpClientModule,
|
|
3148
|
-
RouterTestingModule,
|
|
3149
|
-
MatIconTestingModule,
|
|
3150
|
-
StoreModule,
|
|
3151
|
-
OverlayModule,
|
|
3152
|
-
StoreModule.forRoot({ app: null }, {
|
|
3153
|
-
initialState,
|
|
3154
|
-
runtimeChecks: {
|
|
3155
|
-
strictStateImmutability: false,
|
|
3156
|
-
strictActionImmutability: false
|
|
3157
|
-
}
|
|
3158
|
-
}),
|
|
3159
|
-
EffectsModule.forRoot([]),
|
|
3160
|
-
TranslateModule.forRoot({
|
|
3161
|
-
loader: {
|
|
3162
|
-
provide: TranslateLoader,
|
|
3163
|
-
useClass: TranslateLoaderService
|
|
3164
|
-
}
|
|
3165
|
-
})
|
|
3166
|
-
],
|
|
3167
|
-
exports: [TranslateModule],
|
|
3168
|
-
providers: [
|
|
3169
|
-
{ provide: AlfrescoApiService, useClass: AlfrescoApiServiceMock },
|
|
3170
|
-
{ provide: TranslationService, useClass: TranslationMock }
|
|
3171
|
-
]
|
|
3172
|
-
}]
|
|
3173
|
-
}] });
|
|
3174
|
-
|
|
3175
|
-
/*!
|
|
3176
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
3177
|
-
*
|
|
3178
|
-
* Alfresco Example Content Application
|
|
3179
|
-
*
|
|
3180
|
-
* This file is part of the Alfresco Example Content Application.
|
|
3181
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
3182
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
3183
|
-
* provided under the following open source license terms:
|
|
3184
|
-
*
|
|
3185
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
3186
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
3187
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
3188
|
-
* (at your option) any later version.
|
|
3189
|
-
*
|
|
3190
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
3191
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
3192
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
3193
|
-
* GNU Lesser General Public License for more details.
|
|
3194
|
-
*
|
|
3195
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
3196
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
3197
|
-
*/
|
|
3198
|
-
// @deprecated
|
|
3199
|
-
class SharedModule {
|
|
3200
|
-
}
|
|
3201
|
-
SharedModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: SharedModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
3202
|
-
SharedModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: SharedModule, imports: [MatButtonModule, MatIconModule, MatDialogModule, TranslateModule, ContextActionsDirective], exports: [MatButtonModule, MatIconModule, MatDialogModule, TranslateModule, ContextActionsDirective] });
|
|
3203
|
-
SharedModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: SharedModule, imports: [MatButtonModule, MatIconModule, MatDialogModule, TranslateModule, MatButtonModule, MatIconModule, MatDialogModule, TranslateModule] });
|
|
3204
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: SharedModule, decorators: [{
|
|
3205
|
-
type: NgModule,
|
|
3206
|
-
args: [{
|
|
3207
|
-
imports: [MatButtonModule, MatIconModule, MatDialogModule, TranslateModule, ContextActionsDirective],
|
|
3208
|
-
exports: [MatButtonModule, MatIconModule, MatDialogModule, TranslateModule, ContextActionsDirective]
|
|
3209
|
-
}]
|
|
3210
|
-
}] });
|
|
3211
|
-
|
|
3212
|
-
/*!
|
|
3213
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
3214
|
-
*
|
|
3215
|
-
* Alfresco Example Content Application
|
|
3216
|
-
*
|
|
3217
|
-
* This file is part of the Alfresco Example Content Application.
|
|
3218
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
3219
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
3220
|
-
* provided under the following open source license terms:
|
|
3221
|
-
*
|
|
3222
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
3223
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
3224
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
3225
|
-
* (at your option) any later version.
|
|
3226
|
-
*
|
|
3227
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
3228
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
3229
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
3230
|
-
* GNU Lesser General Public License for more details.
|
|
3231
|
-
*
|
|
3232
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
3233
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
3234
|
-
*/
|
|
3235
|
-
// @deprecated
|
|
3236
|
-
class SharedToolbarModule {
|
|
3237
|
-
}
|
|
3238
|
-
SharedToolbarModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: SharedToolbarModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
3239
|
-
SharedToolbarModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: SharedToolbarModule, imports: [ToolbarButtonComponent, ToolbarActionComponent, ToolbarMenuItemComponent, ToolbarMenuComponent], exports: [ToolbarButtonComponent, ToolbarActionComponent, ToolbarMenuItemComponent, ToolbarMenuComponent] });
|
|
3240
|
-
SharedToolbarModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: SharedToolbarModule, imports: [ToolbarButtonComponent, ToolbarActionComponent, ToolbarMenuItemComponent, ToolbarMenuComponent] });
|
|
3241
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: SharedToolbarModule, decorators: [{
|
|
3242
|
-
type: NgModule,
|
|
3243
|
-
args: [{
|
|
3244
|
-
imports: [ToolbarButtonComponent, ToolbarActionComponent, ToolbarMenuItemComponent, ToolbarMenuComponent],
|
|
3245
|
-
exports: [ToolbarButtonComponent, ToolbarActionComponent, ToolbarMenuItemComponent, ToolbarMenuComponent]
|
|
3246
|
-
}]
|
|
3247
|
-
}] });
|
|
3248
|
-
|
|
3249
|
-
/*!
|
|
3250
|
-
* Copyright © 2005-2024 Hyland Software, Inc. and its affiliates. All rights reserved.
|
|
3251
|
-
*
|
|
3252
|
-
* Alfresco Example Content Application
|
|
3253
|
-
*
|
|
3254
|
-
* This file is part of the Alfresco Example Content Application.
|
|
3255
|
-
* If the software was purchased under a paid Alfresco license, the terms of
|
|
3256
|
-
* the paid license agreement will prevail. Otherwise, the software is
|
|
3257
|
-
* provided under the following open source license terms:
|
|
3258
|
-
*
|
|
3259
|
-
* The Alfresco Example Content Application is free software: you can redistribute it and/or modify
|
|
3260
|
-
* it under the terms of the GNU Lesser General Public License as published by
|
|
3261
|
-
* the Free Software Foundation, either version 3 of the License, or
|
|
3262
|
-
* (at your option) any later version.
|
|
3263
|
-
*
|
|
3264
|
-
* The Alfresco Example Content Application is distributed in the hope that it will be useful,
|
|
3265
|
-
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
3266
|
-
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
3267
|
-
* GNU Lesser General Public License for more details.
|
|
3268
|
-
*
|
|
3269
|
-
* You should have received a copy of the GNU Lesser General Public License
|
|
3270
|
-
* from Hyland Software. If not, see <http://www.gnu.org/licenses/>.
|
|
3271
|
-
*/
|
|
3272
|
-
|
|
3273
|
-
/**
|
|
3274
|
-
* Generated bundle index. Do not edit.
|
|
3275
|
-
*/
|
|
3276
|
-
|
|
3277
|
-
export { AppExtensionService, AppHookService, AppService, AppSettingsService, AppSharedRuleGuard, AutoDownloadService, ContentApiService, ContextActionsDirective, DefaultExtensionLoaderFactory, DefaultMimeTypes, DocumentBasePageService, DocumentBasePageServiceMock, EXTENSION_DATA_LOADERS, ExtensionsDataLoaderGuard, GenericErrorComponent, InfoDrawerComponent, LibTestingModule, LockedByComponent, NodePermissionService, OpenInAppComponent, PageComponent, PageLayoutComponent, PageLayoutContentComponent, PageLayoutErrorComponent, PageLayoutHeaderComponent, PageLayoutModule, PaginationDirective, PluginEnabledGuard, RouterExtensionService, SharedModule, SharedToolbarModule, ToolbarActionComponent, ToolbarButtonComponent, ToolbarButtonType, ToolbarComponent, ToolbarMenuComponent, ToolbarMenuItemComponent, UserProfileService, discoveryApiServiceMockValue, initialState, isLibrary, isLocked, resetInvoked };
|
|
3278
|
-
//# sourceMappingURL=alfresco-aca-shared.mjs.map
|