From 89a42b3de52f701d9952cd9bca4987aa22a4905c Mon Sep 17 00:00:00 2001
From: AleksanderSklorz <115619721+AleksanderSklorz@users.noreply.github.com>
Date: Wed, 25 Mar 2026 08:45:32 +0100
Subject: [PATCH] [ACS-11417] lint enable angular eslint prefer inject rule
default in ng20 for alfresco apps (#5111)
* [ACS-11417] Enable inject prefer eslint rule
* [ACS-11417] Added eslint rule for prefer readonly
* [ACS-11417] Fixed unit tests
* [ACS-11417] Addressed copilot comments
---
.eslintrc.json | 4 +-
app/src/app/app.components.ts | 11 +-
package-lock.json | 204 +++++++++++-------
package.json | 10 +-
.../aca-content/about/src/about.component.ts | 8 +-
.../manage-rules.smart-component.ts | 18 +-
.../actions/rule-action.ui-component.ts | 16 +-
.../rule-simple-condition.ui-component.ts | 6 +-
.../edit-rule-dialog.ui-component.ts | 6 +-
.../rule-details/rule-details.ui-component.ts | 4 +-
.../rule-set-picker.smart-component.ts | 2 +-
.../src/services/actions.service.ts | 12 +-
.../src/services/folder-rule-sets.service.ts | 22 +-
.../src/services/folder-rules.service.ts | 14 +-
.../ms-office/src/aos-extension.service.ts | 10 +-
.../ms-office/src/effects/aos.effects.ts | 4 +-
.../location-link/location-link.component.ts | 6 +-
.../common/logout/logout.component.ts | 4 +-
.../toggle-shared.component.spec.ts | 20 +-
.../toggle-shared/toggle-shared.component.ts | 4 +-
.../common/user-info/user-info.component.ts | 2 +-
.../base-context-menu.directive.ts | 12 +-
.../context-menu-item.component.ts | 6 +-
.../context-menu/context-menu-overlay.ts | 2 +-
.../context-menu/context-menu.component.ts | 10 +-
.../context-menu/context-menu.service.spec.ts | 24 +--
.../context-menu/context-menu.service.ts | 12 +-
.../custom-context-menu.component.ts | 16 +-
.../components/details/details.component.ts | 20 +-
.../datatable-cell-badges.component.ts | 4 +-
.../tags-column/tags-column.component.ts | 6 +-
.../thumbnail-column.component.ts | 2 +-
.../favorite-libraries.component.ts | 14 +-
.../favorites/favorites.component.ts | 8 +-
.../lib/components/files/files.component.ts | 16 +-
.../src/lib/components/home/home.component.ts | 4 +-
.../comments-tab/comments-tab.component.ts | 10 +-
.../library-metadata-form.component.ts | 10 +-
.../metadata-tab/metadata-tab.component.ts | 24 +--
.../agents-button/agents-button.component.ts | 16 +-
.../search-ai-input-container.component.ts | 12 +-
.../search-ai-input.component.ts | 22 +-
.../search-ai-results.component.ts | 26 +--
.../library-list/library-list.component.ts | 14 +-
.../search-action-menu.component.ts | 6 +-
.../search/search-execution.service.ts | 14 +-
.../search/search-filter.service.ts | 6 +-
.../search-input/search-input.component.ts | 20 +-
...ch-libraries-query-builder.service.spec.ts | 2 +-
.../search-libraries-query-builder.service.ts | 6 +-
.../search-libraries-results.component.ts | 13 +-
.../search/search-navigation.service.ts | 6 +-
.../search-results-row.component.ts | 14 +-
.../search-results.component.ts | 20 +-
.../saved-search-delete-dialog.component.ts | 14 +-
.../saved-search-edit-dialog.component.ts | 16 +-
.../dialog/save-search-dialog.component.ts | 18 +-
.../dialog/unique-search-name-validator.ts | 4 +-
.../directive/save-search.directive.ts | 4 +-
.../shared-files/shared-files.component.ts | 8 +-
.../shared-link-view.component.ts | 16 +-
.../components/button-menu.component.ts | 10 +-
.../components/expand-menu.component.ts | 6 +-
.../components/sidenav-header.component.ts | 4 +-
.../directives/action.directive.spec.ts | 4 +-
.../sidenav/directives/action.directive.ts | 10 +-
.../directives/active-link.directive.spec.ts | 2 +-
.../directives/active-link.directive.ts | 26 +--
.../expansion-panel.directive.spec.ts | 53 +++--
.../directives/expansion-panel.directive.ts | 10 +-
.../directives/menu-panel.directive.spec.ts | 42 ++--
.../directives/menu-panel.directive.ts | 8 +-
.../components/sidenav/sidenav.component.ts | 12 +-
.../sidenav/user-menu/user-menu.component.ts | 2 +-
.../toggle-edit-offline.component.ts | 14 +-
.../toggle-favorite-library.component.ts | 10 +-
.../toggle-favorite.component.ts | 10 +-
.../toggle-info-drawer.component.ts | 6 +-
.../toggle-join-library-button.component.ts | 8 +-
.../toolbar/view-node/view-node.component.ts | 14 +-
.../components/trashcan/trashcan.component.ts | 2 +-
.../upload-files-dialog.component.ts | 6 +-
.../view-profile/view-profile.component.ts | 16 +-
.../create-from-template.dialog.ts | 16 +-
.../document-list.directive.spec.ts | 43 +++-
.../lib/directives/document-list.directive.ts | 16 +-
.../lib/pipes/is-feature-supported.pipe.ts | 8 +-
.../src/lib/services/modal-ai.service.ts | 6 +-
.../src/lib/services/node-actions.service.ts | 20 +-
.../src/lib/services/node-template.service.ts | 8 +-
.../saved-searches-context.service.ts | 13 +-
.../services/search-ai-navigation.service.ts | 10 +-
.../src/lib/store/effects/download.effects.ts | 10 +-
.../src/lib/store/effects/favorite.effects.ts | 6 +-
.../src/lib/store/effects/library.effects.ts | 10 +-
.../lib/store/effects/search-ai.effects.ts | 6 +-
.../src/lib/store/effects/template.effects.ts | 4 +-
.../src/lib/store/effects/upload.effects.ts | 2 +-
.../src/lib/store/effects/viewer.effects.ts | 10 +-
.../components/preview/preview.component.ts | 24 +--
.../lib/components/viewer/viewer.component.ts | 30 ++-
.../viewer/src/lib/services/viewer.service.ts | 10 +-
.../src/api/categories-api.ts | 2 +-
.../src/api/favorites-api.ts | 2 +-
.../src/api/file-actions.ts | 2 +-
.../src/api/nodes-api.ts | 2 +-
.../src/api/queries-api.ts | 2 +-
.../src/api/rules-api.ts | 2 +-
.../src/api/search-api.ts | 2 +-
.../src/api/shared-links-api.ts | 2 +-
.../src/api/sites-api.ts | 2 +-
.../aca-playwright-shared/src/api/tags-api.ts | 2 +-
.../src/api/trashcan-api.ts | 2 +-
.../components/aca-header.component.ts | 6 +-
.../components/actions-dropdown.component.ts | 25 +--
.../components/adf-info-drawer.component.ts | 2 +-
.../page-objects/components/base.component.ts | 2 +-
.../breadcrumb/breadcrumb.component.ts | 2 +-
.../components/conditions.component.ts | 3 +-
.../dataTable/data-table.component.ts | 2 +-
.../dataTable/mat-menu.component.ts | 2 +-
.../datetime-picker.component.ts | 2 +-
.../dialogs/adf-confirm-dialog.component.ts | 2 +-
.../dialogs/adf-folder-dialog.component.ts | 2 +-
.../dialogs/adf-library-dialog.component.ts | 2 +-
.../dialogs/content-node-selector-dialog.ts | 6 +-
.../create-from-template-dialog-component.ts | 2 +-
.../dialogs/delete-trash-dialog.component.ts | 2 +-
.../dialogs/edit-dialog.component.ts | 2 +-
.../dialogs/link-rules.component.ts | 4 +-
.../manage-versions-dialog.component.ts | 2 +-
.../password-overlay-dialog.component.ts | 2 +-
.../dialogs/share-dialog.component.ts | 2 +-
.../dialogs/upload-dialog.component.ts | 2 +-
.../upload-new-version-dialog.component.ts | 2 +-
.../viewer-overlay-dialog.component.ts | 2 +-
.../components/error.component.ts | 2 +-
.../manage-rules-dialog.component.ts | 2 +-
.../manageRules/manage-rules.component.ts | 2 +-
.../components/pagination.component.ts | 16 +-
.../search/search-filters.component.ts | 2 +-
.../search-filters-categories.component.ts | 2 +-
.../search-filters-date.component.ts | 2 +-
.../search-filters-location.component.ts | 2 +-
.../search-filters-logic.component.ts | 2 +-
.../search-filters-properties.component.ts | 2 +-
.../search-filters-tags.component.ts | 2 +-
.../search/search-input.component.ts | 2 +-
.../search-sorting-picker.components.ts | 2 +-
.../components/sidenav.component.ts | 20 +-
.../snackBar/snack-bar.component.ts | 2 +-
.../components/spinner.component.ts | 2 +-
.../components/viewer.component.ts | 2 +-
.../pages/favorites-libraries.page.ts | 2 +-
.../src/page-objects/pages/favorites.page.ts | 2 +-
.../src/page-objects/pages/login.page.ts | 2 +-
.../page-objects/pages/my-libraries.page.ts | 2 +-
.../src/page-objects/pages/nodes.page.ts | 2 +-
.../page-objects/pages/personal-files.page.ts | 2 +-
.../page-objects/pages/recent-files.page.ts | 2 +-
.../src/page-objects/pages/search.page.ts | 2 +-
.../src/page-objects/pages/shared.page.ts | 2 +-
.../src/page-objects/pages/trash.page.ts | 2 +-
.../document-base-page.component.ts | 4 +-
.../info-drawer/info-drawer.component.ts | 14 +-
.../open-in-app/open-in-app.component.ts | 15 +-
.../page-layout/page-layout.component.ts | 8 +-
.../toolbar-action.component.spec.ts | 20 +-
.../toolbar-action.component.ts | 6 +-
.../toolbar-button.component.ts | 6 +-
.../toolbar-menu-item.component.ts | 6 +-
.../contextmenu/contextmenu.directive.spec.ts | 7 +-
.../contextmenu/contextmenu.directive.ts | 6 +-
.../directives/pagination.directive.spec.ts | 36 ++--
.../lib/directives/pagination.directive.ts | 10 +-
.../aca-mobile-app-switcher.service.ts | 4 +-
.../src/lib/services/app-settings.service.ts | 2 +-
.../src/lib/services/app.extension.service.ts | 48 ++---
.../src/lib/services/app.service.ts | 50 ++---
.../src/lib/services/auto-download.service.ts | 2 +-
.../src/lib/services/content-api.service.ts | 10 +-
.../services/navigation-history.service.ts | 6 +-
.../lib/services/node-permission.service.ts | 2 +-
.../lib/services/router.extension.service.ts | 10 +-
.../src/lib/services/user-profile.service.ts | 8 +-
.../store/src/effects/router.effects.ts | 8 +-
186 files changed, 929 insertions(+), 938 deletions(-)
diff --git a/.eslintrc.json b/.eslintrc.json
index 200aa27c5..70d909d63 100644
--- a/.eslintrc.json
+++ b/.eslintrc.json
@@ -306,7 +306,9 @@
"selector": ":matches(Literal[value=/ng-reflect-/], TemplateElement[value.cooked=/ng-reflect-/])",
"message": "*ng-reflect-* attributes should not be used. Consider alternatives for proper selectors."
}
- ]
+ ],
+ "@angular-eslint/prefer-inject": "error",
+ "@typescript-eslint/prefer-readonly": "error"
}
},
{
diff --git a/app/src/app/app.components.ts b/app/src/app/app.components.ts
index 430ba7d05..fa07ee03a 100644
--- a/app/src/app/app.components.ts
+++ b/app/src/app/app.components.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { Component, ViewEncapsulation } from '@angular/core';
+import { Component, ViewEncapsulation, inject } from '@angular/core';
import { AppService } from '@alfresco/aca-shared';
import { MatIconRegistry } from '@angular/material/icon';
import { RouterOutlet } from '@angular/router';
@@ -36,10 +36,11 @@ import { RouterOutlet } from '@angular/router';
imports: [RouterOutlet]
})
export class AppComponent {
- constructor(
- private appService: AppService,
- matIconRegistry: MatIconRegistry
- ) {
+ private readonly appService = inject(AppService);
+
+ constructor() {
+ const matIconRegistry = inject(MatIconRegistry);
+
this.appService.init();
matIconRegistry.setDefaultFontSetClass('material-icons-outlined');
}
diff --git a/package-lock.json b/package-lock.json
index 923af9213..f52c554c2 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -50,11 +50,11 @@
"@angular-devkit/build-angular": "19.2.22",
"@angular-devkit/core": "19.2.18",
"@angular-devkit/schematics": "19.2.18",
- "@angular-eslint/builder": "19.3.0",
- "@angular-eslint/eslint-plugin": "19.3.0",
- "@angular-eslint/eslint-plugin-template": "19.3.0",
- "@angular-eslint/schematics": "19.3.0",
- "@angular-eslint/template-parser": "19.3.0",
+ "@angular-eslint/builder": "19.8.1",
+ "@angular-eslint/eslint-plugin": "19.8.1",
+ "@angular-eslint/eslint-plugin-template": "19.8.1",
+ "@angular-eslint/schematics": "19.8.1",
+ "@angular-eslint/template-parser": "19.8.1",
"@angular/compiler-cli": "19.2.19",
"@angular/language-service": "19.2.18",
"@cspell/eslint-plugin": "^9.2.1",
@@ -149,6 +149,7 @@
"resolved": "https://registry.npmjs.org/@alfresco/adf-core/-/adf-core-8.5.0-23298028349.tgz",
"integrity": "sha512-jRi7qyK9Eas6S0mfPurm7vdrnXPgiQDF3b+/hKyqdatSIuIMF2p0Y+dxazqfd+/OzK26S/X4Ju9pBR8wlnDvmg==",
"license": "Apache-2.0",
+ "peer": true,
"dependencies": {
"angular-oauth2-oidc": "17.0.2",
"angular-oauth2-oidc-jwks": "17.0.2",
@@ -196,6 +197,7 @@
"resolved": "https://registry.npmjs.org/@alfresco/adf-extensions/-/adf-extensions-8.5.0-23298028349.tgz",
"integrity": "sha512-PXuUrxKMsWVCn1Ts++7aRzNgVUrzJ7FgcwVxgBzqM4YzXT/cZmrXHDRGIZl0e4R3MLpKR8axqnEFogec8ws4TQ==",
"license": "Apache-2.0",
+ "peer": true,
"dependencies": {
"tslib": "^2.3.0"
},
@@ -216,6 +218,7 @@
"resolved": "https://registry.npmjs.org/@alfresco/js-api/-/js-api-9.5.0-23298028349.tgz",
"integrity": "sha512-S5SQmpuSYsBsVCGUcEv1eQsqsPTMwFkACwGUFHu2iWKRKo4wk/0MdM2eKV7dIjswrMCACDcEPx1K3tvQ8zeYyQ==",
"license": "Apache-2.0",
+ "peer": true,
"dependencies": {
"eventemitter3": "^5.0.1",
"superagent": "^9.0.1",
@@ -729,9 +732,9 @@
}
},
"node_modules/@angular-eslint/builder": {
- "version": "19.3.0",
- "resolved": "https://registry.npmjs.org/@angular-eslint/builder/-/builder-19.3.0.tgz",
- "integrity": "sha512-j9xNrzZJq29ONSG6EaeQHve0Squkm6u6Dm8fZgWP7crTFOrtLXn7Wxgxuyl9eddpbWY1Ov1gjFuwBVnxIdyAqg==",
+ "version": "19.8.1",
+ "resolved": "https://registry.npmjs.org/@angular-eslint/builder/-/builder-19.8.1.tgz",
+ "integrity": "sha512-NOMkw0xgDoDVCLkL5nkkvdd3ouDYkOGqtEmabTR7N4/kQnk1R4coOTWGCqAgMXCFdxlyjuxquDwuJ+yni81pRg==",
"dev": true,
"license": "MIT",
"dependencies": {
@@ -744,21 +747,21 @@
}
},
"node_modules/@angular-eslint/bundled-angular-compiler": {
- "version": "19.3.0",
- "resolved": "https://registry.npmjs.org/@angular-eslint/bundled-angular-compiler/-/bundled-angular-compiler-19.3.0.tgz",
- "integrity": "sha512-63Zci4pvnUR1iSkikFlNbShF1tO5HOarYd8fvNfmOZwFfZ/1T3j3bCy9YbE+aM5SYrWqPaPP/OcwZ3wJ8WNvqA==",
+ "version": "19.8.1",
+ "resolved": "https://registry.npmjs.org/@angular-eslint/bundled-angular-compiler/-/bundled-angular-compiler-19.8.1.tgz",
+ "integrity": "sha512-WXi1YbSs7SIQo48u+fCcc5Nt14/T4QzYQPLZUnjtsUXPgQG7ZoahhcGf7PPQ+n0V3pSopHOlSHwqK+tSsYK87A==",
"dev": true,
"license": "MIT"
},
"node_modules/@angular-eslint/eslint-plugin": {
- "version": "19.3.0",
- "resolved": "https://registry.npmjs.org/@angular-eslint/eslint-plugin/-/eslint-plugin-19.3.0.tgz",
- "integrity": "sha512-nBLslLI20KnVbqlfNW7GcnI9R6cYCvRGjOE2QYhzxM316ciAQ62tvQuXP9ZVnRBLSKDAVnMeC0eTq9O4ysrxrQ==",
+ "version": "19.8.1",
+ "resolved": "https://registry.npmjs.org/@angular-eslint/eslint-plugin/-/eslint-plugin-19.8.1.tgz",
+ "integrity": "sha512-wZEBMPwD2TRhifG751hcj137EMIEaFmsxRB2EI+vfINCgPnFGSGGOHXqi8aInn9fXqHs7VbXkAzXYdBsvy1m4Q==",
"dev": true,
"license": "MIT",
"dependencies": {
- "@angular-eslint/bundled-angular-compiler": "19.3.0",
- "@angular-eslint/utils": "19.3.0"
+ "@angular-eslint/bundled-angular-compiler": "19.8.1",
+ "@angular-eslint/utils": "19.8.1"
},
"peerDependencies": {
"@typescript-eslint/utils": "^7.11.0 || ^8.0.0",
@@ -767,18 +770,19 @@
}
},
"node_modules/@angular-eslint/eslint-plugin-template": {
- "version": "19.3.0",
- "resolved": "https://registry.npmjs.org/@angular-eslint/eslint-plugin-template/-/eslint-plugin-template-19.3.0.tgz",
- "integrity": "sha512-WyouppTpOYut+wvv13wlqqZ8EHoDrCZxNfGKuEUYK1BPmQlTB8EIZfQH4iR1rFVS28Rw+XRIiXo1x3oC0SOfnA==",
+ "version": "19.8.1",
+ "resolved": "https://registry.npmjs.org/@angular-eslint/eslint-plugin-template/-/eslint-plugin-template-19.8.1.tgz",
+ "integrity": "sha512-0ZVQldndLrDfB0tzFe/uIwvkUcakw8qGxvkEU0l7kSbv/ngNQ/qrkRi7P64otB15inIDUNZI2jtmVat52dqSfQ==",
"dev": true,
"license": "MIT",
"dependencies": {
- "@angular-eslint/bundled-angular-compiler": "19.3.0",
- "@angular-eslint/utils": "19.3.0",
+ "@angular-eslint/bundled-angular-compiler": "19.8.1",
+ "@angular-eslint/utils": "19.8.1",
"aria-query": "5.3.2",
"axobject-query": "4.1.0"
},
"peerDependencies": {
+ "@angular-eslint/template-parser": "19.8.1",
"@typescript-eslint/types": "^7.11.0 || ^8.0.0",
"@typescript-eslint/utils": "^7.11.0 || ^8.0.0",
"eslint": "^8.57.0 || ^9.0.0",
@@ -786,29 +790,43 @@
}
},
"node_modules/@angular-eslint/schematics": {
- "version": "19.3.0",
- "resolved": "https://registry.npmjs.org/@angular-eslint/schematics/-/schematics-19.3.0.tgz",
- "integrity": "sha512-Wl5sFQ4t84LUb8mJ2iVfhYFhtF55IugXu7rRhPHtgIu9Ty5s1v3HGUx4LKv51m2kWhPPeFOTmjeBv1APzFlmnQ==",
+ "version": "19.8.1",
+ "resolved": "https://registry.npmjs.org/@angular-eslint/schematics/-/schematics-19.8.1.tgz",
+ "integrity": "sha512-MKzfO3puOCuQFgP8XDUkEr5eaqcCQLAdYLLMcywEO/iRs1eRHL46+rkW+SjDp1cUqlxKtu+rLiTYr0T/O4fi9Q==",
"dev": true,
"license": "MIT",
"dependencies": {
"@angular-devkit/core": ">= 19.0.0 < 20.0.0",
"@angular-devkit/schematics": ">= 19.0.0 < 20.0.0",
- "@angular-eslint/eslint-plugin": "19.3.0",
- "@angular-eslint/eslint-plugin-template": "19.3.0",
- "ignore": "7.0.3",
- "semver": "7.7.1",
+ "@angular-eslint/eslint-plugin": "19.8.1",
+ "@angular-eslint/eslint-plugin-template": "19.8.1",
+ "ignore": "7.0.5",
+ "semver": "7.7.2",
"strip-json-comments": "3.1.1"
}
},
+ "node_modules/@angular-eslint/schematics/node_modules/semver": {
+ "version": "7.7.2",
+ "resolved": "https://registry.npmjs.org/semver/-/semver-7.7.2.tgz",
+ "integrity": "sha512-RF0Fw+rO5AMf9MAyaRXI4AV0Ulj5lMHqVxxdSgiVbixSCXoEmmX/jk0CuJw4+3SqroYO9VoUh+HcuJivvtJemA==",
+ "dev": true,
+ "license": "ISC",
+ "bin": {
+ "semver": "bin/semver.js"
+ },
+ "engines": {
+ "node": ">=10"
+ }
+ },
"node_modules/@angular-eslint/template-parser": {
- "version": "19.3.0",
- "resolved": "https://registry.npmjs.org/@angular-eslint/template-parser/-/template-parser-19.3.0.tgz",
- "integrity": "sha512-VxMNgsHXMWbbmZeBuBX5i8pzsSSEaoACVpaE+j8Muk60Am4Mxc0PytJm4n3znBSvI3B7Kq2+vStSRYPkOER4lA==",
+ "version": "19.8.1",
+ "resolved": "https://registry.npmjs.org/@angular-eslint/template-parser/-/template-parser-19.8.1.tgz",
+ "integrity": "sha512-pQiOg+se1AU/ncMlnJ9V6xYnMQ84qI1BGWuJpbU6A99VTXJg90scg0+T7DWmKssR1YjP5qmmBtrZfKsHEcLW/A==",
"dev": true,
"license": "MIT",
+ "peer": true,
"dependencies": {
- "@angular-eslint/bundled-angular-compiler": "19.3.0",
+ "@angular-eslint/bundled-angular-compiler": "19.8.1",
"eslint-scope": "^8.0.2"
},
"peerDependencies": {
@@ -817,13 +835,13 @@
}
},
"node_modules/@angular-eslint/utils": {
- "version": "19.3.0",
- "resolved": "https://registry.npmjs.org/@angular-eslint/utils/-/utils-19.3.0.tgz",
- "integrity": "sha512-ovvbQh96FIJfepHqLCMdKFkPXr3EbcvYc9kMj9hZyIxs/9/VxwPH7x25mMs4VsL6rXVgH2FgG5kR38UZlcTNNw==",
+ "version": "19.8.1",
+ "resolved": "https://registry.npmjs.org/@angular-eslint/utils/-/utils-19.8.1.tgz",
+ "integrity": "sha512-gVDKYWmAjeTPtaYmddT/HS03fCebXJtrk8G1MouQIviZbHqLjap6TbVlzlkBigRzaF0WnFnrDduQslkJzEdceA==",
"dev": true,
"license": "MIT",
"dependencies": {
- "@angular-eslint/bundled-angular-compiler": "19.3.0"
+ "@angular-eslint/bundled-angular-compiler": "19.8.1"
},
"peerDependencies": {
"@typescript-eslint/utils": "^7.11.0 || ^8.0.0",
@@ -836,6 +854,7 @@
"resolved": "https://registry.npmjs.org/@angular/animations/-/animations-19.2.19.tgz",
"integrity": "sha512-XGChk+26XZpcwzIQUVjgLxGVC//m5TaDrogseQNIGs2Chzv6KYbo91HftL69fTiM5udRYjg6IV7XEzDNF/GVUw==",
"license": "MIT",
+ "peer": true,
"dependencies": {
"tslib": "^2.3.0"
},
@@ -852,6 +871,7 @@
"resolved": "https://registry.npmjs.org/@angular/cdk/-/cdk-19.2.19.tgz",
"integrity": "sha512-PCpJagurPBqciqcq4Z8+3OtKLb7rSl4w/qBJoIMua8CgnrjvA1i+SWawhdtfI1zlY8FSwhzLwXV0CmWWfFzQPg==",
"license": "MIT",
+ "peer": true,
"dependencies": {
"parse5": "^7.1.2",
"tslib": "^2.3.0"
@@ -867,6 +887,7 @@
"resolved": "https://registry.npmjs.org/@angular/common/-/common-19.2.19.tgz",
"integrity": "sha512-/JYo8jJZ6BAgw3IVYJpinAfGb+RbaZubrElFvaq450BWxDPInv7Z99HKEQ3qEBRsBeIAQ/WrKXDxoJSjy7QMNQ==",
"license": "MIT",
+ "peer": true,
"dependencies": {
"tslib": "^2.3.0"
},
@@ -883,6 +904,7 @@
"resolved": "https://registry.npmjs.org/@angular/compiler/-/compiler-19.2.19.tgz",
"integrity": "sha512-kWlqFW7ExvAqKv+X/6ZsWVW7YTmI1/3VUvADLC/6bkLTdKrHS8OtBHfsklXmHMNVbbFopTvoTeKkoqLGrW2lwg==",
"license": "MIT",
+ "peer": true,
"dependencies": {
"tslib": "^2.3.0"
},
@@ -896,6 +918,7 @@
"integrity": "sha512-vdMJX9E7wePN41T+6BYRQBA+XiR9a5DBhs20dqtv8YVireQktH6mxLZIg1pVxkL/gnao2gpl/lOvp0xmC7UN/Q==",
"dev": true,
"license": "MIT",
+ "peer": true,
"dependencies": {
"@babel/core": "7.26.9",
"@jridgewell/sourcemap-codec": "^1.4.14",
@@ -972,6 +995,7 @@
"resolved": "https://registry.npmjs.org/@angular/core/-/core-19.2.19.tgz",
"integrity": "sha512-VZAzpxBoQgyy7AOlhxbAHxPQWo0nk8xsnrD36PLCZeTZA/5GNzO3lLVaX2N5BCUgpgiCBjNBKq9kVo6ZkAls9g==",
"license": "MIT",
+ "peer": true,
"dependencies": {
"tslib": "^2.3.0"
},
@@ -988,6 +1012,7 @@
"resolved": "https://registry.npmjs.org/@angular/forms/-/forms-19.2.19.tgz",
"integrity": "sha512-J09++utTVaPs962y/adeDjIgqyhzNpnzAS7Nex+HNy/LnWPcTNW781cOh1EGS1X/+CmgnI8HWs5z4KGeBeU1aA==",
"license": "MIT",
+ "peer": true,
"dependencies": {
"tslib": "^2.3.0"
},
@@ -1015,6 +1040,7 @@
"resolved": "https://registry.npmjs.org/@angular/material/-/material-19.2.19.tgz",
"integrity": "sha512-auIE6JUzTIA3LyYklh9J/T7u64crmphxUBgAa0zcOMDog6SYfwbNe9YeLQqua5ek4OUAOdK/BHHfVl5W5iaUoQ==",
"license": "MIT",
+ "peer": true,
"dependencies": {
"tslib": "^2.3.0"
},
@@ -1032,6 +1058,7 @@
"resolved": "https://registry.npmjs.org/@angular/material-date-fns-adapter/-/material-date-fns-adapter-19.2.19.tgz",
"integrity": "sha512-So+jptG1uhLhdSA1NuCkbfPl5tf/PRJVdfSn/9R2HzmjZSV65RuvhwDvFK9CV/Zhj9s9h7rXyn7V5GtThjznGw==",
"license": "MIT",
+ "peer": true,
"dependencies": {
"tslib": "^2.3.0"
},
@@ -1046,6 +1073,7 @@
"resolved": "https://registry.npmjs.org/@angular/platform-browser/-/platform-browser-19.2.19.tgz",
"integrity": "sha512-bnQSmoJNI1LQxJnHnB01XQXqgOdgAtLAOsa24ZT6b2pWV3Vw0/7+V2dZsNZX/TJtejunvSgSDCEqgJhIQ5vBVg==",
"license": "MIT",
+ "peer": true,
"dependencies": {
"tslib": "^2.3.0"
},
@@ -1068,6 +1096,7 @@
"resolved": "https://registry.npmjs.org/@angular/platform-browser-dynamic/-/platform-browser-dynamic-19.2.19.tgz",
"integrity": "sha512-u8aYmIRGtx4yOXhmqgiRIm+DyH+05bAkzMHr6RE0JV/wxVJmAIKZnquHM6ItFvF0eV0pfMTPwArmRuHVWu7tQg==",
"license": "MIT",
+ "peer": true,
"dependencies": {
"tslib": "^2.3.0"
},
@@ -1086,6 +1115,7 @@
"resolved": "https://registry.npmjs.org/@angular/router/-/router-19.2.19.tgz",
"integrity": "sha512-zh40ihKgYOM5pjgUOLlUKdWYsGgEj7MQHgzdV1E9Zz6LBrQTp/PGS/UdCQn88H6KAshR0uXrkc/vP+tnB2jqdg==",
"license": "MIT",
+ "peer": true,
"dependencies": {
"tslib": "^2.3.0"
},
@@ -1143,6 +1173,7 @@
"integrity": "sha512-vMqyb7XCDMPvJFFOaT9kxtiRh42GwlZEg1/uIgtZshS5a/8OaduUfCi7kynKgc3Tw/6Uo2D+db9qBttghhmxwQ==",
"dev": true,
"license": "MIT",
+ "peer": true,
"dependencies": {
"@ampproject/remapping": "^2.2.0",
"@babel/code-frame": "^7.26.2",
@@ -3183,7 +3214,8 @@
"resolved": "https://registry.npmjs.org/@cspell/dict-css/-/dict-css-4.0.18.tgz",
"integrity": "sha512-EF77RqROHL+4LhMGW5NTeKqfUd/e4OOv6EDFQ/UQQiFyWuqkEKyEz0NDILxOFxWUEVdjT2GQ2cC7t12B6pESwg==",
"dev": true,
- "license": "MIT"
+ "license": "MIT",
+ "peer": true
},
"node_modules/@cspell/dict-dart": {
"version": "2.3.1",
@@ -3323,14 +3355,16 @@
"resolved": "https://registry.npmjs.org/@cspell/dict-html/-/dict-html-4.0.13.tgz",
"integrity": "sha512-vHzk2xfqQYPvoXtQtywa6ekIonPrUEwe2uftjry3UNRNl89TtzLJVSkiymKJ3WMb+W/DwKXKIb1tKzcIS8ccIg==",
"dev": true,
- "license": "MIT"
+ "license": "MIT",
+ "peer": true
},
"node_modules/@cspell/dict-html-symbol-entities": {
"version": "4.0.4",
"resolved": "https://registry.npmjs.org/@cspell/dict-html-symbol-entities/-/dict-html-symbol-entities-4.0.4.tgz",
"integrity": "sha512-afea+0rGPDeOV9gdO06UW183Qg6wRhWVkgCFwiO3bDupAoyXRuvupbb5nUyqSTsLXIKL8u8uXQlJ9pkz07oVXw==",
"dev": true,
- "license": "MIT"
+ "license": "MIT",
+ "peer": true
},
"node_modules/@cspell/dict-java": {
"version": "5.0.12",
@@ -3528,7 +3562,8 @@
"resolved": "https://registry.npmjs.org/@cspell/dict-typescript/-/dict-typescript-3.2.3.tgz",
"integrity": "sha512-zXh1wYsNljQZfWWdSPYwQhpwiuW0KPW1dSd8idjMRvSD0aSvWWHoWlrMsmZeRl4qM4QCEAjua8+cjflm41cQBg==",
"dev": true,
- "license": "MIT"
+ "license": "MIT",
+ "peer": true
},
"node_modules/@cspell/dict-vue": {
"version": "3.0.5",
@@ -3647,6 +3682,7 @@
}
],
"license": "MIT",
+ "peer": true,
"engines": {
"node": "^14 || ^16 || >=18"
},
@@ -3670,6 +3706,7 @@
}
],
"license": "MIT",
+ "peer": true,
"engines": {
"node": "^14 || ^16 || >=18"
}
@@ -5221,6 +5258,7 @@
"resolved": "https://registry.npmjs.org/@mat-datetimepicker/core/-/core-15.0.2.tgz",
"integrity": "sha512-2vyKub5uCSAWoKC7UlUbNFOwHrHu9gdaK1xluMiimj8GibkxuP0uh2AP1tRsYz2514CAFvsSkD39X6qy0kz7Iw==",
"license": "MIT",
+ "peer": true,
"dependencies": {
"tslib": "~2.8.1"
},
@@ -5341,6 +5379,7 @@
"integrity": "sha512-8PFQxtmXc6ukBC4CqGIoc96M2Ly9WVwCPu4Ffvt+K/SB6rGbeFeZoYAwREV1zGNMJ5v5ly6+AHIEOBxNuSnzSg==",
"dev": true,
"license": "MIT",
+ "peer": true,
"dependencies": {
"@module-federation/bridge-react-webpack-plugin": "0.21.6",
"@module-federation/cli": "0.21.6",
@@ -5679,6 +5718,7 @@
"integrity": "sha512-MfDNbQFvbfeQNdc2hvb85qBQ29aehs9NGVWXE0goDPLb4SJNPVMYXjrgiNx6Z0glud7rEnXdstRGsmLcRAOujA==",
"dev": true,
"license": "MIT",
+ "peer": true,
"dependencies": {
"@module-federation/runtime": "2.2.1",
"@module-federation/webpack-bundler-runtime": "2.2.1"
@@ -5794,6 +5834,7 @@
"integrity": "sha512-fnP+ZOZTFeBGiTAnxve+axGmiYn2D60h86nUISXjXClK3LUY1krUfPgf6MaD4YDJ4i51OGXZWPekeMe16pkd8Q==",
"dev": true,
"license": "MIT",
+ "peer": true,
"dependencies": {
"@module-federation/runtime": "0.21.6",
"@module-federation/webpack-bundler-runtime": "0.21.6"
@@ -6481,6 +6522,7 @@
"resolved": "https://registry.npmjs.org/@ngrx/store/-/store-19.2.1.tgz",
"integrity": "sha512-c5vQId7YoAhM0y4HASrz9mtLju+28vJspd6OBlhPbBlSae8GN8m9S/oav+8LaSY19yh95cZ5B/nMcLNNWgL/jA==",
"license": "MIT",
+ "peer": true,
"dependencies": {
"tslib": "^2.0.0"
},
@@ -6525,6 +6567,7 @@
"resolved": "https://registry.npmjs.org/@ngx-translate/core/-/core-17.0.0.tgz",
"integrity": "sha512-Rft2D5ns2pq4orLZjEtx1uhNuEBerUdpFUG1IcqtGuipj6SavgB8SkxtNQALNDA+EVlvsNCCjC2ewZVtUeN6rg==",
"license": "MIT",
+ "peer": true,
"dependencies": {
"tslib": "^2.3.0"
},
@@ -8426,6 +8469,7 @@
"integrity": "sha512-FolcIAH5FW4J2FET+qwjd1kNeFbCkd0VLuIHO0thyolEjaPSxw5qxG67DA7BZGm6PVcoiSgPLks1DL6eZ8c+fA==",
"dev": true,
"license": "MIT",
+ "peer": true,
"dependencies": {
"@module-federation/runtime-tools": "0.21.6",
"@rspack/binding": "1.6.8",
@@ -8638,7 +8682,6 @@
"integrity": "sha512-JZdvBNrWODBTLrmtUF6+UD26z5cENpV0X9liR1jPDT1O7taQqwRePSuCQcjRo1qXCjlNfBW7pGGVxVCRKK8EXw==",
"dev": true,
"license": "MIT",
- "peer": true,
"dependencies": {
"@angular-devkit/core": "20.3.18",
"@angular-devkit/schematics": "20.3.18",
@@ -8656,7 +8699,6 @@
"integrity": "sha512-zGWMjMqE8qXYr8baYCs43k9HlKz9J4Gh3Yx+7XE0uS0Y1LXzzALevSoUw7GIPdSvOriQJAEgtWE6QKssqSGltQ==",
"dev": true,
"license": "MIT",
- "peer": true,
"dependencies": {
"ajv": "8.18.0",
"ajv-formats": "3.0.1",
@@ -8685,7 +8727,6 @@
"integrity": "sha512-GRMEGl3YTL/qhQhaxYXLbSQxUTPTYMQ65IlxLQRq5+UKPomN9KVxxVdADXqs7Ss1uQcetr+jc+taVgxOqsAoxg==",
"dev": true,
"license": "MIT",
- "peer": true,
"dependencies": {
"@angular-devkit/core": "20.3.18",
"jsonc-parser": "3.3.1",
@@ -8705,7 +8746,6 @@
"integrity": "sha512-PlXPeEWMXMZ7sPYOHqmDyCJzcfNrUr3fGNKtezX14ykXOEIvyK81d+qydx89KY5O71FKMPaQ2vBfBFI5NHR63A==",
"dev": true,
"license": "MIT",
- "peer": true,
"dependencies": {
"fast-deep-equal": "^3.1.3",
"fast-uri": "^3.0.1",
@@ -8723,7 +8763,6 @@
"integrity": "sha512-Bq3SmSpyFHaWjPk8If9yc6svM8c56dB5BAtW4Qbw5jHTwwXXcTLoRMkpDJp6VL0XzlWaCHTXrkFURMYmD0sLqg==",
"dev": true,
"license": "MIT",
- "peer": true,
"engines": {
"node": ">=12"
},
@@ -8737,7 +8776,6 @@
"integrity": "sha512-7NzBL0rN6fMUW+f7A6Io4h40qQlG+xGmtMxfbnH/K7TAtt8JQWVQK+6g0UXKMeVJoyV5EkkNsErQ8pVD3bLHbA==",
"dev": true,
"license": "MIT",
- "peer": true,
"engines": {
"node": "^12.17.0 || ^14.13 || >=16.0.0"
},
@@ -8751,7 +8789,6 @@
"integrity": "sha512-ywqV+5MmyL4E7ybXgKys4DugZbX0FC6LnwrhjuykIjnK9k8OQacQ7axGKnjDXWNhns0xot3bZI5h55H8yo9cJg==",
"dev": true,
"license": "MIT",
- "peer": true,
"engines": {
"node": ">=6"
},
@@ -8764,8 +8801,7 @@
"resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-10.6.0.tgz",
"integrity": "sha512-toUI84YS5YmxW219erniWD0CIVOo46xGKColeNQRgOzDorgBi1v4D71/OFzgD9GO2UGKIv1C3Sp8DAn0+j5w7A==",
"dev": true,
- "license": "MIT",
- "peer": true
+ "license": "MIT"
},
"node_modules/@schematics/angular/node_modules/is-interactive": {
"version": "2.0.0",
@@ -8773,7 +8809,6 @@
"integrity": "sha512-qP1vozQRI+BMOPcjFzrjXuQvdak2pHNUMZoeG2eRbiSqyvbEf/wQtEOTOX1guk6E3t36RkaqiSt8A/6YElNxLQ==",
"dev": true,
"license": "MIT",
- "peer": true,
"engines": {
"node": ">=12"
},
@@ -8787,7 +8822,6 @@
"integrity": "sha512-mE00Gnza5EEB3Ds0HfMyllZzbBrmLOX3vfWoj9A9PEnTfratQ/BcaJOuMhnkhjXvb2+FkY3VuHqtAGpTPmglFQ==",
"dev": true,
"license": "MIT",
- "peer": true,
"engines": {
"node": ">=18"
},
@@ -8801,7 +8835,6 @@
"integrity": "sha512-i24m8rpwhmPIS4zscNzK6MSEhk0DUWa/8iYQWxhffV8jkI4Phvs3F+quL5xvS0gdQR0FyTCMMH33Y78dDTzzIw==",
"dev": true,
"license": "MIT",
- "peer": true,
"dependencies": {
"chalk": "^5.3.0",
"is-unicode-supported": "^1.3.0"
@@ -8819,7 +8852,6 @@
"integrity": "sha512-43r2mRvz+8JRIKnWJ+3j8JtjRKZ6GmjzfaE/qiBJnikNnYv/6bagRJ1kUhNk8R5EX/GkobD+r+sfxCPJsiKBLQ==",
"dev": true,
"license": "MIT",
- "peer": true,
"engines": {
"node": ">=12"
},
@@ -8833,7 +8865,6 @@
"integrity": "sha512-weP+BZ8MVNnlCm8c0Qdc1WSWq4Qn7I+9CJGm7Qali6g44e/PUzbjNqJX5NJ9ljlNMosfJvg1fKEGILklK9cwnw==",
"dev": true,
"license": "MIT",
- "peer": true,
"dependencies": {
"chalk": "^5.3.0",
"cli-cursor": "^5.0.0",
@@ -8858,7 +8889,6 @@
"integrity": "sha512-5gTmgEY/sqK6gFXLIsQNH19lWb4ebPDLA4SdLP7dsWkIXHWlG66oPuVvXSGFPppYZz8ZDZq0dYYrbHfBCVUb1Q==",
"dev": true,
"license": "MIT",
- "peer": true,
"engines": {
"node": ">=12"
},
@@ -8872,7 +8902,6 @@
"integrity": "sha512-i5uvt8C3ikiWeNZSVZNWcfZPItFQOsYTUAOkcUPGd8DqDy1uOUikjt5dG+uRlwyvR108Fb9DOd4GvXfT0N2/uQ==",
"dev": true,
"license": "BSD-3-Clause",
- "peer": true,
"engines": {
"node": ">= 12"
}
@@ -8883,7 +8912,6 @@
"integrity": "sha512-tsaTIkKW9b4N+AEj+SVA+WhJzV7/zMhcSu78mLKWSk7cXMOSHsBKFWUs0fWwq8QyK3MgJBQRX6Gbi4kYbdvGkQ==",
"dev": true,
"license": "MIT",
- "peer": true,
"dependencies": {
"emoji-regex": "^10.3.0",
"get-east-asian-width": "^1.0.0",
@@ -8902,7 +8930,6 @@
"integrity": "sha512-yDPMNjp4WyfYBkHnjIRLfca1i6KMyGCtsVgoKe/z1+6vukgaENdgGBZt+ZmKPc4gavvEZ5OgHfHdrazhgNyG7w==",
"dev": true,
"license": "MIT",
- "peer": true,
"dependencies": {
"ansi-regex": "^6.2.2"
},
@@ -9343,6 +9370,7 @@
"integrity": "sha512-dVd04UKsfpINUnK0yBoYHDF3xu7xVH4BuDotC/xGuycx4CgbP48X/KF/586bcObxT0HENHXEU8Nqtu6NR+eKhw==",
"dev": true,
"license": "MIT",
+ "peer": true,
"dependencies": {
"@types/body-parser": "*",
"@types/express-serve-static-core": "^4.17.33",
@@ -9464,6 +9492,7 @@
"integrity": "sha512-W609buLVRVmeW693xKfzHeIV6nJGGz98uCPfeXI1ELMLXVeKYZ9m15fAMSaUPBHYLGFsVRcMmSCksQOrZV9BYA==",
"dev": true,
"license": "MIT",
+ "peer": true,
"dependencies": {
"undici-types": "~7.16.0"
}
@@ -9882,6 +9911,7 @@
"integrity": "sha512-4Z+L8I2OqhZV8qA132M4wNL30ypZGYOQVBfMgxDH/K5UX0PNqTu1c6za9ST5r9+tavvHiTWmBnKzpCJ/GlVFtg==",
"dev": true,
"license": "BSD-2-Clause",
+ "peer": true,
"dependencies": {
"@typescript-eslint/scope-manager": "7.18.0",
"@typescript-eslint/types": "7.18.0",
@@ -10161,6 +10191,7 @@
"integrity": "sha512-+fZ3LZNeiELGmimrujsDCT4CRIbq5oXdHe7chLiW8qzqyPMnn1puNstCrMNVAqwcl2FdIxkuJ4tOs/RFDBVc/Q==",
"dev": true,
"license": "MIT",
+ "peer": true,
"engines": {
"node": "^18.18.0 || ^20.9.0 || >=21.1.0"
},
@@ -10244,6 +10275,7 @@
"integrity": "sha512-XDY4mXTez3Z1iRDI5mbRhH4DFSt46oaIFsLg+Zn97+sYrXACziXSQcSelMybnVZ5pa1P6xYkPr5cMJyunM1ZDA==",
"dev": true,
"license": "MIT",
+ "peer": true,
"dependencies": {
"@eslint-community/eslint-utils": "^4.9.1",
"@typescript-eslint/scope-manager": "8.53.0",
@@ -10722,6 +10754,7 @@
"integrity": "sha512-nrUSn7hzt7J6JWgWGz78ZYI8wj+gdIJdk0Ynjpp8l+trkn58Uqsf6RYrYkEK+3X18EX+TNdtJI0WxAtc+L84SQ==",
"dev": true,
"license": "MIT",
+ "peer": true,
"dependencies": {
"argparse": "^2.0.1"
},
@@ -10755,6 +10788,7 @@
"resolved": "https://registry.npmjs.org/acorn/-/acorn-8.16.0.tgz",
"integrity": "sha512-UVJyE9MttOsBQIDKw1skb9nAwQuR5wuGD3+82K6JgJlm/Y+KI92oNsMNGZCYdDsVtRHSak0pcV5Dno5+4jh9sw==",
"license": "MIT",
+ "peer": true,
"bin": {
"acorn": "bin/acorn"
},
@@ -10863,6 +10897,7 @@
"integrity": "sha512-B/gBuNg5SiMTrPkC+A2+cW0RszwxYmn6VYxB/inlBStS5nx6xHIt/ehKRhIMhqusl7a8LjQoZnjCs5vhwxOQ1g==",
"dev": true,
"license": "MIT",
+ "peer": true,
"dependencies": {
"fast-deep-equal": "^3.1.3",
"fast-uri": "^3.0.1",
@@ -11329,6 +11364,7 @@
"integrity": "sha512-ChTCHMouEe2kn713WHbQGcuYrr6fXTBiu460OTwWrWob16g1bXn4vtz07Ope7ewMozJAnEquLk5lWQWtBig9DQ==",
"dev": true,
"license": "MIT",
+ "peer": true,
"dependencies": {
"follow-redirects": "^1.15.11",
"form-data": "^4.0.5",
@@ -11729,6 +11765,7 @@
}
],
"license": "MIT",
+ "peer": true,
"dependencies": {
"baseline-browser-mapping": "^2.9.0",
"caniuse-lite": "^1.0.30001759",
@@ -12004,6 +12041,7 @@
"resolved": "https://registry.npmjs.org/chevrotain/-/chevrotain-11.1.1.tgz",
"integrity": "sha512-f0yv5CPKaFxfsPTBzX7vGuim4oIC1/gcS7LUGdBSwl2dU6+FON6LVUksdOo1qJjoUvXNn45urgh8C+0a24pACQ==",
"license": "Apache-2.0",
+ "peer": true,
"dependencies": {
"@chevrotain/cst-dts-gen": "11.1.1",
"@chevrotain/gast": "11.1.1",
@@ -12031,6 +12069,7 @@
"integrity": "sha512-Qgzu8kfBvo+cA4962jnP1KkS6Dop5NS6g7R5LFYJr4b8Ub94PPQXUksCw9PvXoeXPRRddRNC5C1JQUR2SMGtnA==",
"dev": true,
"license": "MIT",
+ "peer": true,
"dependencies": {
"readdirp": "^4.0.1"
},
@@ -13351,6 +13390,7 @@
"resolved": "https://registry.npmjs.org/cytoscape/-/cytoscape-3.33.1.tgz",
"integrity": "sha512-iJc4TwyANnOGR1OmWhsS9ayRS3s+XQ185FmuHObThD+5AeJCakAAbWv8KimMTt08xCCLNgneQwFp+JRJOr9qGQ==",
"license": "MIT",
+ "peer": true,
"engines": {
"node": ">=0.10"
}
@@ -13760,6 +13800,7 @@
"resolved": "https://registry.npmjs.org/d3-selection/-/d3-selection-3.0.0.tgz",
"integrity": "sha512-fmTRWbNMmsmWq6xJV8D19U/gw/bwrHfNXxrIN+HfZgnzqTHp9jOmKMhsTUjXOJnZOdZY9Q28y4yebKzqDKlxlQ==",
"license": "ISC",
+ "peer": true,
"engines": {
"node": ">=12"
}
@@ -13913,6 +13954,7 @@
"resolved": "https://registry.npmjs.org/date-fns/-/date-fns-4.1.0.tgz",
"integrity": "sha512-Ukq0owbQXxa/U3EGtsdVBkR1w7KOQ5gIBqdH2hkvknzZPYvBxb/aa6E8L7tmjFtkwZBu3UXBbjIgPo/Ez4xaNg==",
"license": "MIT",
+ "peer": true,
"funding": {
"type": "github",
"url": "https://github.com/sponsors/kossnocorp"
@@ -14511,6 +14553,7 @@
"integrity": "sha512-ETBauow1T35Y/WZMkio9jiM0Z5xjHHmJ4XmjZOq1l/dXz3lr2sRn87nJy20RupqSh1F2m3HHPSp8ShIPQJrJ3A==",
"dev": true,
"license": "MIT",
+ "peer": true,
"dependencies": {
"iconv-lite": "^0.6.2"
}
@@ -14955,6 +14998,7 @@
"deprecated": "This version is no longer supported. Please see https://eslint.org/version-support for other options.",
"dev": true,
"license": "MIT",
+ "peer": true,
"dependencies": {
"@eslint-community/eslint-utils": "^4.2.0",
"@eslint-community/regexpp": "^4.6.1",
@@ -16287,6 +16331,7 @@
"integrity": "sha512-IWrosm/yrn43eiKqkfkHis7QioDleaXQHdDVPKg0FSwwd/DuvyX79TZnFOnYpB7dcsFAMmtFztZuXPDvSePkFw==",
"dev": true,
"license": "MIT",
+ "peer": true,
"dependencies": {
"fast-deep-equal": "^3.1.1",
"fast-json-stable-stringify": "^2.0.0",
@@ -17555,9 +17600,9 @@
"license": "BSD-3-Clause"
},
"node_modules/ignore": {
- "version": "7.0.3",
- "resolved": "https://registry.npmjs.org/ignore/-/ignore-7.0.3.tgz",
- "integrity": "sha512-bAH5jbK/F3T3Jls4I0SO1hmPR0dKU0a7+SY6n1yzRtG54FLO8d6w/nxLFX2Nb7dBu6cCWXPaAME6cYqFUMmuCA==",
+ "version": "7.0.5",
+ "resolved": "https://registry.npmjs.org/ignore/-/ignore-7.0.5.tgz",
+ "integrity": "sha512-Hs59xBNfUIunMFgWAbGX5cq6893IbWg4KnrjbYwX3tx0ztorVgTDA6B2sxf8ejHJ4wz8BqGUMYlnzNBer5NvGg==",
"dev": true,
"license": "MIT",
"engines": {
@@ -18507,7 +18552,8 @@
"resolved": "https://registry.npmjs.org/jasmine-core/-/jasmine-core-6.0.1.tgz",
"integrity": "sha512-gUtzV5ASR0MLBwDNqri4kBsgKNCcRQd9qOlNw/w/deavD0cl3JmWXXfH8JhKM4LTg6LPTt2IOQ4px3YYfgh2Xg==",
"dev": true,
- "license": "MIT"
+ "license": "MIT",
+ "peer": true
},
"node_modules/jasmine-spec-reporter": {
"version": "5.0.2",
@@ -18654,6 +18700,7 @@
"integrity": "sha512-rg9zJN+G4n2nfJl5MW3BMygZX56zKPNVEYYqq7adpmMh4Jn2QNEwhvQlFy6jPVdcod7txZtKHWnyZiA3a0zP7A==",
"dev": true,
"license": "MIT",
+ "peer": true,
"bin": {
"jiti": "lib/jiti-cli.mjs"
}
@@ -18796,6 +18843,7 @@
"integrity": "sha512-LrtUxbdvt1gOpo3gxG+VAJlJAEMhbWlM4YrFQgql98FwF7+K8K12LYO4hnDdUkNjeztYrOXEMqgTajSWgmtI/w==",
"dev": true,
"license": "MIT",
+ "peer": true,
"dependencies": {
"@colors/colors": "1.5.0",
"body-parser": "^1.19.0",
@@ -19503,6 +19551,7 @@
"integrity": "sha512-tkuLHQlvWUTeQ3doAqnHbNn8T6WX1KA8yvbKG9x4VtKtIjHsVKQZCH11zRgAfbDAXC2UNIg/K9BYAAcEzUIrNg==",
"dev": true,
"license": "Apache-2.0",
+ "peer": true,
"dependencies": {
"copy-anything": "^2.0.1",
"parse-node-version": "^1.0.1",
@@ -20967,6 +21016,7 @@
"resolved": "https://registry.npmjs.org/minimatch/-/minimatch-10.2.4.tgz",
"integrity": "sha512-oRjTw/97aTBN0RHbYCdtF1MQfvusSIBQM0IZEgzl6426+8jSC0nF1a/GmnVLpfB9yyr6g6FTqWqiZVbxrtaCIg==",
"license": "BlueOak-1.0.0",
+ "peer": true,
"dependencies": {
"brace-expansion": "^5.0.2"
},
@@ -21211,6 +21261,7 @@
"integrity": "sha512-dFuwFsDJMBSd1YtmLLcX5bNNUCQUlRqgf34aXA+79PmkOP+0eF8GP2949wq3+jMjmFTNm80Oo8IUYiSLwklKCQ==",
"dev": true,
"license": "MIT",
+ "peer": true,
"dependencies": {
"@rollup/plugin-json": "^6.1.0",
"@rollup/wasm-node": "^4.24.0",
@@ -21610,6 +21661,7 @@
"dev": true,
"hasInstallScript": true,
"license": "MIT",
+ "peer": true,
"dependencies": {
"@napi-rs/wasm-runtime": "0.2.4",
"@yarnpkg/lockfile": "^1.1.0",
@@ -21746,16 +21798,6 @@
"dev": true,
"license": "MIT"
},
- "node_modules/nx/node_modules/ignore": {
- "version": "7.0.5",
- "resolved": "https://registry.npmjs.org/ignore/-/ignore-7.0.5.tgz",
- "integrity": "sha512-Hs59xBNfUIunMFgWAbGX5cq6893IbWg4KnrjbYwX3tx0ztorVgTDA6B2sxf8ejHJ4wz8BqGUMYlnzNBer5NvGg==",
- "dev": true,
- "license": "MIT",
- "engines": {
- "node": ">= 4"
- }
- },
"node_modules/nx/node_modules/is-docker": {
"version": "2.2.1",
"resolved": "https://registry.npmjs.org/is-docker/-/is-docker-2.2.1.tgz",
@@ -22607,6 +22649,7 @@
"resolved": "https://registry.npmjs.org/pdfjs-dist/-/pdfjs-dist-5.4.449.tgz",
"integrity": "sha512-CegnUaT0QwAyQMS+7o2POr4wWUNNe8VaKKlcuoRHeYo98cVnqPpwOXNSx6Trl6szH02JrRcsPgletV6GmF3LtQ==",
"license": "Apache-2.0",
+ "peer": true,
"engines": {
"node": ">=20.16.0 || >=22.3.0"
},
@@ -22886,6 +22929,7 @@
}
],
"license": "MIT",
+ "peer": true,
"dependencies": {
"nanoid": "^3.3.8",
"picocolors": "^1.1.1",
@@ -23548,6 +23592,7 @@
"integrity": "sha512-Q8qQfPiZ+THO/3ZrOrO0cJJKfpYCagtMUkXbnEfmgUjwXg6z/WBeOyS9APBBPCTSiDV+s4SwQGu8yFsiMRIudg==",
"dev": true,
"license": "MIT",
+ "peer": true,
"dependencies": {
"cssesc": "^3.0.0",
"util-deprecate": "^1.0.2"
@@ -23612,6 +23657,7 @@
"integrity": "sha512-UOnG6LftzbdaHZcKoPFtOcCKztrQ57WkHDeRD9t/PTQtmT0NHSeWWepj6pS0z/N7+08BHFDQVUrfmfMRcZwbMg==",
"dev": true,
"license": "MIT",
+ "peer": true,
"bin": {
"prettier": "bin/prettier.cjs"
},
@@ -24858,6 +24904,7 @@
"integrity": "sha512-+VUy01yfDqNmIVMd/LLKl2TTtY0ovZN0rTonh+FhKr65mFwIYgU9WzgIZKS7U9/SPCQvWTsTGx9jyt+qRm/XFw==",
"dev": true,
"license": "MIT",
+ "peer": true,
"dependencies": {
"@bufbuild/protobuf": "^2.5.0",
"buffer-builder": "^0.2.0",
@@ -25317,8 +25364,7 @@
"resolved": "https://registry.npmjs.org/scheduler/-/scheduler-0.27.0.tgz",
"integrity": "sha512-eNv+WrVbKu1f3vbYJT/xtiF5syA5HPIMtf9IgY/nKg0sWqzAUEvqY/xm7OcZc/qafLx/iO9FgOmeSAp4v5ti/Q==",
"dev": true,
- "license": "MIT",
- "peer": true
+ "license": "MIT"
},
"node_modules/schema-utils": {
"version": "4.3.3",
@@ -26331,7 +26377,6 @@
"integrity": "sha512-UhDfHmA92YAlNnCfhmq0VeNL5bDbiZGg7sZ2IvPsXubGkiNa9EC+tUTsjBRsYUAz87btI6/1wf4XoVvQ3uRnmQ==",
"dev": true,
"license": "MIT",
- "peer": true,
"engines": {
"node": ">=18"
},
@@ -26672,6 +26717,7 @@
"integrity": "sha512-78O4c6IswZ9TzpcIiQJIN49K3qNoXTM8zEJzhaTE/xRTCZswaovSEVIa/uwbOltZrk16X4jAxjaOhzz/hTm1Kw==",
"dev": true,
"license": "MIT",
+ "peer": true,
"dependencies": {
"@csstools/css-parser-algorithms": "^2.3.1",
"@csstools/css-tokenizer": "^2.2.0",
@@ -27209,6 +27255,7 @@
"integrity": "sha512-LBAhFyLho16harJoWMg/nZsQYgTrg5jXOn2nCYjRUcZZEdE3qa2zb8QEDRUGVZBW4rlazf2fxkg8tztybTaqWw==",
"dev": true,
"license": "BSD-2-Clause",
+ "peer": true,
"dependencies": {
"@jridgewell/source-map": "^0.3.3",
"acorn": "^8.8.2",
@@ -27770,7 +27817,8 @@
"version": "2.8.1",
"resolved": "https://registry.npmjs.org/tslib/-/tslib-2.8.1.tgz",
"integrity": "sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w==",
- "license": "0BSD"
+ "license": "0BSD",
+ "peer": true
},
"node_modules/tsscmp": {
"version": "1.0.6",
@@ -27952,6 +28000,7 @@
"integrity": "sha512-aJn6wq13/afZp/jT9QZmwEjDqqvSGp1VT5GVg+f/t6/oVyrgXM6BY1h9BRh/O5p3PlUPAe+WuiEZOmb/49RqoQ==",
"dev": true,
"license": "Apache-2.0",
+ "peer": true,
"bin": {
"tsc": "bin/tsc",
"tsserver": "bin/tsserver"
@@ -28484,6 +28533,7 @@
"integrity": "sha512-gX/dMkRQc7QOMzgTe6KsYFM7DxeIONQSui1s0n/0xht36HvrgbxtM1xBlgx596NbpHuQU8P7QpKwrZYwUX48nw==",
"dev": true,
"license": "MIT",
+ "peer": true,
"dependencies": {
"@types/eslint-scope": "^3.7.7",
"@types/estree": "^1.0.8",
@@ -28651,6 +28701,7 @@
"integrity": "sha512-QcQ72gh8a+7JO63TAx/6XZf/CWhgMzu5m0QirvPfGvptOusAxG12w2+aua1Jkjr7hzaWDnJ2n6JFeexMHI+Zjg==",
"dev": true,
"license": "MIT",
+ "peer": true,
"dependencies": {
"@types/bonjour": "^3.5.13",
"@types/connect-history-api-fallback": "^1.5.4",
@@ -29213,6 +29264,7 @@
"integrity": "sha512-8VbfWfHLbbwu3+N6OKsOMpBdT4kXPDDB9cJk2bJ6mh9ucxdlnNvH1e+roYkKmN9Nxw2yjz7VzeO9oOz2zJ04Pw==",
"dev": true,
"license": "MIT",
+ "peer": true,
"engines": {
"node": ">=10.0.0"
},
diff --git a/package.json b/package.json
index 7c5d22c99..534208ac0 100644
--- a/package.json
+++ b/package.json
@@ -83,11 +83,11 @@
"@angular-devkit/build-angular": "19.2.22",
"@angular-devkit/core": "19.2.18",
"@angular-devkit/schematics": "19.2.18",
- "@angular-eslint/builder": "19.3.0",
- "@angular-eslint/eslint-plugin": "19.3.0",
- "@angular-eslint/eslint-plugin-template": "19.3.0",
- "@angular-eslint/schematics": "19.3.0",
- "@angular-eslint/template-parser": "19.3.0",
+ "@angular-eslint/builder": "19.8.1",
+ "@angular-eslint/eslint-plugin": "19.8.1",
+ "@angular-eslint/eslint-plugin-template": "19.8.1",
+ "@angular-eslint/schematics": "19.8.1",
+ "@angular-eslint/template-parser": "19.8.1",
"@angular/compiler-cli": "19.2.19",
"@angular/language-service": "19.2.18",
"@cspell/eslint-plugin": "^9.2.1",
diff --git a/projects/aca-content/about/src/about.component.ts b/projects/aca-content/about/src/about.component.ts
index b843d3798..2f4e14e25 100644
--- a/projects/aca-content/about/src/about.component.ts
+++ b/projects/aca-content/about/src/about.component.ts
@@ -42,10 +42,10 @@ import { MatButtonModule } from '@angular/material/button';
encapsulation: ViewEncapsulation.None
})
export class AboutComponent implements OnInit {
- private authService = inject(AuthenticationService);
- private appExtensions = inject(AppExtensionService);
- private appSettings = inject(AppSettingsService);
- private discovery = inject(DiscoveryApiService);
+ private readonly authService = inject(AuthenticationService);
+ private readonly appExtensions = inject(AppExtensionService);
+ private readonly appSettings = inject(AppSettingsService);
+ private readonly discovery = inject(DiscoveryApiService);
public packageJson? = inject(PACKAGE_JSON, { optional: true });
public dev = inject(DEV_MODE_TOKEN);
diff --git a/projects/aca-content/folder-rules/src/manage-rules/manage-rules.smart-component.ts b/projects/aca-content/folder-rules/src/manage-rules/manage-rules.smart-component.ts
index f276323e2..12f4d9fa1 100644
--- a/projects/aca-content/folder-rules/src/manage-rules/manage-rules.smart-component.ts
+++ b/projects/aca-content/folder-rules/src/manage-rules/manage-rules.smart-component.ts
@@ -76,6 +76,14 @@ import { MatToolbar } from '@angular/material/toolbar';
host: { class: 'aca-manage-rules' }
})
export class ManageRulesSmartComponent implements OnInit {
+ private readonly location = inject(Location);
+ private readonly folderRulesService = inject(FolderRulesService);
+ private readonly route = inject(ActivatedRoute);
+ private readonly matDialogService = inject(MatDialog);
+ private readonly notificationService = inject(NotificationService);
+ private readonly actionsService = inject(ActionsService);
+ private readonly folderRuleSetsService = inject(FolderRuleSetsService);
+
nodeId = '';
isInheritanceEnabled = true;
isInheritanceToggleDisabled = false;
@@ -98,16 +106,6 @@ export class ManageRulesSmartComponent implements OnInit {
private readonly destroyRef = inject(DestroyRef);
- constructor(
- private location: Location,
- private folderRulesService: FolderRulesService,
- private route: ActivatedRoute,
- private matDialogService: MatDialog,
- private notificationService: NotificationService,
- private actionsService: ActionsService,
- private folderRuleSetsService: FolderRuleSetsService
- ) {}
-
ngOnInit() {
this.mainRuleSet$ = this.folderRuleSetsService.mainRuleSet$;
this.inheritedRuleSets$ = this.folderRuleSetsService.inheritedRuleSets$;
diff --git a/projects/aca-content/folder-rules/src/rule-details/actions/rule-action.ui-component.ts b/projects/aca-content/folder-rules/src/rule-details/actions/rule-action.ui-component.ts
index 763c17480..3234c408a 100644
--- a/projects/aca-content/folder-rules/src/rule-details/actions/rule-action.ui-component.ts
+++ b/projects/aca-content/folder-rules/src/rule-details/actions/rule-action.ui-component.ts
@@ -73,6 +73,13 @@ import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
]
})
export class RuleActionUiComponent implements ControlValueAccessor, OnInit, OnChanges {
+ private readonly cardViewUpdateService = inject(CardViewUpdateService);
+ private readonly dialog = inject(MatDialog);
+ private readonly translate = inject(TranslateService);
+ private readonly tagService = inject(TagService);
+ private readonly categoryService = inject(CategoryService);
+ private readonly securityControlsService = inject(SecurityControlsService);
+
@Input()
nodeId = '';
@@ -121,15 +128,6 @@ export class RuleActionUiComponent implements ControlValueAccessor, OnInit, OnCh
private readonly destroyRef = inject(DestroyRef);
- constructor(
- private cardViewUpdateService: CardViewUpdateService,
- private dialog: MatDialog,
- private translate: TranslateService,
- private tagService: TagService,
- private categoryService: CategoryService,
- private securityControlsService: SecurityControlsService
- ) {}
-
writeValue(action: RuleAction) {
this.form.setValue({
actionDefinitionId: action.actionDefinitionId
diff --git a/projects/aca-content/folder-rules/src/rule-details/conditions/rule-simple-condition.ui-component.ts b/projects/aca-content/folder-rules/src/rule-details/conditions/rule-simple-condition.ui-component.ts
index 68757114c..830b7536d 100644
--- a/projects/aca-content/folder-rules/src/rule-details/conditions/rule-simple-condition.ui-component.ts
+++ b/projects/aca-content/folder-rules/src/rule-details/conditions/rule-simple-condition.ui-component.ts
@@ -75,9 +75,9 @@ const AUTOCOMPLETE_OPTIONS_DEBOUNCE_TIME = 500;
]
})
export class RuleSimpleConditionUiComponent implements OnInit, ControlValueAccessor, OnChanges {
- private appSettings = inject(AppSettingsService);
- private categoryService = inject(CategoryService);
- private tagService = inject(TagService);
+ private readonly appSettings = inject(AppSettingsService);
+ private readonly categoryService = inject(CategoryService);
+ private readonly tagService = inject(TagService);
form = new FormGroup({
field: new FormControl('cm:name'),
diff --git a/projects/aca-content/folder-rules/src/rule-details/edit-rule-dialog.ui-component.ts b/projects/aca-content/folder-rules/src/rule-details/edit-rule-dialog.ui-component.ts
index a21e194e0..6168b30ef 100644
--- a/projects/aca-content/folder-rules/src/rule-details/edit-rule-dialog.ui-component.ts
+++ b/projects/aca-content/folder-rules/src/rule-details/edit-rule-dialog.ui-component.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { Component, EventEmitter, Inject, Output, ViewEncapsulation } from '@angular/core';
+import { Component, EventEmitter, Output, ViewEncapsulation, inject } from '@angular/core';
import { MAT_DIALOG_DATA, MatDialogModule } from '@angular/material/dialog';
import { Rule } from '../model/rule.model';
import { Observable } from 'rxjs';
@@ -50,6 +50,8 @@ export interface EditRuleDialogOptions {
host: { class: 'aca-edit-rule-dialog' }
})
export class EditRuleDialogUiComponent {
+ data = inject(MAT_DIALOG_DATA);
+
formValid = false;
model: Partial;
nodeId = '';
@@ -60,7 +62,7 @@ export class EditRuleDialogUiComponent {
formValue: Partial;
@Output() submitted = new EventEmitter>();
- constructor(@Inject(MAT_DIALOG_DATA) public data: EditRuleDialogOptions) {
+ constructor() {
this.model = this.data?.model || {};
this.nodeId = this.data?.nodeId;
this.actionDefinitions$ = this.data?.actionDefinitions$;
diff --git a/projects/aca-content/folder-rules/src/rule-details/rule-details.ui-component.ts b/projects/aca-content/folder-rules/src/rule-details/rule-details.ui-component.ts
index cdc8c6d7b..6808571cb 100644
--- a/projects/aca-content/folder-rules/src/rule-details/rule-details.ui-component.ts
+++ b/projects/aca-content/folder-rules/src/rule-details/rule-details.ui-component.ts
@@ -61,6 +61,8 @@ import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
host: { class: 'aca-rule-details' }
})
export class RuleDetailsUiComponent implements OnInit {
+ private readonly categoryService = inject(CategoryService);
+
@Input()
readOnly: boolean;
@@ -138,8 +140,6 @@ export class RuleDetailsUiComponent implements OnInit {
private readonly destroyRef = inject(DestroyRef);
- constructor(private categoryService: CategoryService) {}
-
ngOnInit() {
const disabledCategory = !this.categoryService.areCategoriesEnabled();
this.actionDefinitions = this.actionDefinitions.filter((action) => !(disabledCategory && action.id === 'link-category'));
diff --git a/projects/aca-content/folder-rules/src/rule-set-picker/rule-set-picker.smart-component.ts b/projects/aca-content/folder-rules/src/rule-set-picker/rule-set-picker.smart-component.ts
index 2fe30fbf0..b0b28e4ca 100644
--- a/projects/aca-content/folder-rules/src/rule-set-picker/rule-set-picker.smart-component.ts
+++ b/projects/aca-content/folder-rules/src/rule-set-picker/rule-set-picker.smart-component.ts
@@ -72,7 +72,7 @@ export class RuleSetPickerSmartComponent implements OnInit {
hasOwnedRules = false;
private selectedNodeId = '';
- private folderLoading$ = new BehaviorSubject(true);
+ private readonly folderLoading$ = new BehaviorSubject(true);
public readonly data: RuleSetPickerOptions = inject(MAT_DIALOG_DATA);
public readonly folderRuleSetsService = inject(FolderRuleSetsService);
diff --git a/projects/aca-content/folder-rules/src/services/actions.service.ts b/projects/aca-content/folder-rules/src/services/actions.service.ts
index 2adfca3fb..dfa382b56 100644
--- a/projects/aca-content/folder-rules/src/services/actions.service.ts
+++ b/projects/aca-content/folder-rules/src/services/actions.service.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { Injectable } from '@angular/core';
+import { Injectable, inject } from '@angular/core';
import { ActionDefinition, ActionDefinitionEntry, ActionDefinitionList, ActionsApi } from '@alfresco/js-api';
import { AlfrescoApiService } from '@alfresco/adf-content-services';
import { BehaviorSubject, forkJoin, from, Observable, of } from 'rxjs';
@@ -32,11 +32,13 @@ import { ActionParameterConstraint, ConstraintValue } from '../model/action-para
@Injectable({ providedIn: 'root' })
export class ActionsService {
- private actionDefinitionsListingSource = new BehaviorSubject([]);
+ private readonly apiService = inject(AlfrescoApiService);
+
+ private readonly actionDefinitionsListingSource = new BehaviorSubject([]);
actionDefinitionsListing$ = this.actionDefinitionsListingSource.asObservable();
- private loadingSource = new BehaviorSubject(false);
+ private readonly loadingSource = new BehaviorSubject(false);
loading$ = this.loadingSource.asObservable();
- private parameterConstraintsSource = new BehaviorSubject([]);
+ private readonly parameterConstraintsSource = new BehaviorSubject([]);
parameterConstraints$: Observable = this.parameterConstraintsSource.asObservable();
private _actionsApi: ActionsApi;
@@ -47,8 +49,6 @@ export class ActionsService {
return this._actionsApi;
}
- constructor(private apiService: AlfrescoApiService) {}
-
loadActionDefinitions() {
this.loadingSource.next(true);
from(this.actionsApi.listActions())
diff --git a/projects/aca-content/folder-rules/src/services/folder-rule-sets.service.ts b/projects/aca-content/folder-rules/src/services/folder-rule-sets.service.ts
index 08bb88304..7327b1c22 100644
--- a/projects/aca-content/folder-rules/src/services/folder-rule-sets.service.ts
+++ b/projects/aca-content/folder-rules/src/services/folder-rule-sets.service.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { Injectable } from '@angular/core';
+import { Injectable, inject } from '@angular/core';
import { AlfrescoApiService } from '@alfresco/adf-content-services';
import { BehaviorSubject, combineLatest, from, Observable, of, startWith } from 'rxjs';
import { NodeInfo } from '@alfresco/aca-shared/store';
@@ -37,6 +37,10 @@ import { Rule } from '../model/rule.model';
providedIn: 'root'
})
export class FolderRuleSetsService {
+ private readonly apiService = inject(AlfrescoApiService);
+ private readonly contentApi = inject(ContentApiService);
+ private readonly folderRulesService = inject(FolderRulesService);
+
public static readonly MAX_RULE_SETS_PER_GET = 100;
static isOwnedRuleSet(ruleSet: RuleSet, nodeId: string): boolean {
@@ -57,11 +61,11 @@ export class FolderRuleSetsService {
private inheritedRuleSets: RuleSet[] = [];
private hasMoreRuleSets = true;
- private mainRuleSetSource = new BehaviorSubject(null);
- private inheritedRuleSetsSource = new BehaviorSubject([]);
- private hasMoreRuleSetsSource = new BehaviorSubject(true);
- private folderInfoSource = new BehaviorSubject(null);
- private isLoadingSource = new BehaviorSubject(false);
+ private readonly mainRuleSetSource = new BehaviorSubject(null);
+ private readonly inheritedRuleSetsSource = new BehaviorSubject([]);
+ private readonly hasMoreRuleSetsSource = new BehaviorSubject(true);
+ private readonly folderInfoSource = new BehaviorSubject(null);
+ private readonly isLoadingSource = new BehaviorSubject(false);
mainRuleSet$: Observable = this.mainRuleSetSource.asObservable();
inheritedRuleSets$: Observable = this.inheritedRuleSetsSource.asObservable();
@@ -70,11 +74,7 @@ export class FolderRuleSetsService {
isLoading$: Observable = this.isLoadingSource.asObservable();
selectedRuleSet$: Observable;
- constructor(
- private readonly apiService: AlfrescoApiService,
- private readonly contentApi: ContentApiService,
- private readonly folderRulesService: FolderRulesService
- ) {
+ constructor() {
this.selectedRuleSet$ = this.folderRulesService.selectedRule$.pipe(
startWith(null),
map((rule: Rule) => {
diff --git a/projects/aca-content/folder-rules/src/services/folder-rules.service.ts b/projects/aca-content/folder-rules/src/services/folder-rules.service.ts
index fb81772a9..dc4e75e11 100644
--- a/projects/aca-content/folder-rules/src/services/folder-rules.service.ts
+++ b/projects/aca-content/folder-rules/src/services/folder-rules.service.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { Injectable } from '@angular/core';
+import { Injectable, inject } from '@angular/core';
import { AlfrescoApiService } from '@alfresco/adf-content-services';
import { BehaviorSubject, from, Observable } from 'rxjs';
import { finalize, map } from 'rxjs/operators';
@@ -41,6 +41,9 @@ interface GetRulesResult {
providedIn: 'root'
})
export class FolderRulesService {
+ private readonly apiService = inject(AlfrescoApiService);
+ private readonly notificationService = inject(NotificationService);
+
public static readonly MAX_RULES_PER_GET = 100;
public static get emptyCompositeCondition(): RuleCompositeCondition {
@@ -85,17 +88,12 @@ export class FolderRulesService {
return value;
}
- private selectedRuleSource = new BehaviorSubject(null);
- private deletedRuleIdSource = new BehaviorSubject(null);
+ private readonly selectedRuleSource = new BehaviorSubject(null);
+ private readonly deletedRuleIdSource = new BehaviorSubject(null);
selectedRule$ = this.selectedRuleSource.asObservable();
deletedRuleId$: Observable = this.deletedRuleIdSource.asObservable();
- constructor(
- private readonly apiService: AlfrescoApiService,
- private readonly notificationService: NotificationService
- ) {}
-
private callApi(path: string, httpMethod: string, body: object = {}): Promise {
// APIs used by this service are still private and not yet available for public use
const params = [{}, {}, {}, {}, body, ['application/json'], ['application/json']];
diff --git a/projects/aca-content/ms-office/src/aos-extension.service.ts b/projects/aca-content/ms-office/src/aos-extension.service.ts
index 0973264cf..6ffcc89c3 100644
--- a/projects/aca-content/ms-office/src/aos-extension.service.ts
+++ b/projects/aca-content/ms-office/src/aos-extension.service.ts
@@ -24,7 +24,7 @@
/* cspell:disable */
import { AuthenticationService, NotificationService } from '@alfresco/adf-core';
-import { Injectable } from '@angular/core';
+import { Injectable, inject } from '@angular/core';
import { Node } from '@alfresco/js-api';
import { getFileExtension, supportedExtensions } from '@alfresco/aca-shared/rules';
import { AppSettingsService } from '@alfresco/aca-shared';
@@ -37,11 +37,9 @@ export interface IAosEditOnlineService {
providedIn: 'root'
})
export class AosEditOnlineService implements IAosEditOnlineService {
- constructor(
- private authenticationService: AuthenticationService,
- private appSettings: AppSettingsService,
- private notificationService: NotificationService
- ) {}
+ private readonly authenticationService = inject(AuthenticationService);
+ private readonly appSettings = inject(AppSettingsService);
+ private readonly notificationService = inject(NotificationService);
onActionEditOnlineAos(node: Node): void {
if (node && this.isFile(node) && node.properties) {
diff --git a/projects/aca-content/ms-office/src/effects/aos.effects.ts b/projects/aca-content/ms-office/src/effects/aos.effects.ts
index 8cf01fa2a..37138f282 100755
--- a/projects/aca-content/ms-office/src/effects/aos.effects.ts
+++ b/projects/aca-content/ms-office/src/effects/aos.effects.ts
@@ -31,8 +31,8 @@ import { AosEditOnlineService } from '../aos-extension.service';
@Injectable()
export class AosEffects {
- private actions$ = inject(Actions);
- private aosEditOnlineService = inject(AosEditOnlineService);
+ private readonly actions$ = inject(Actions);
+ private readonly aosEditOnlineService = inject(AosEditOnlineService);
openOffice$ = createEffect(
() =>
diff --git a/projects/aca-content/src/lib/components/common/location-link/location-link.component.ts b/projects/aca-content/src/lib/components/common/location-link/location-link.component.ts
index 7e72f8bcd..2588bb6bf 100644
--- a/projects/aca-content/src/lib/components/common/location-link/location-link.component.ts
+++ b/projects/aca-content/src/lib/components/common/location-link/location-link.component.ts
@@ -48,9 +48,9 @@ import { NodeLocationReferencesComponent } from '../../../dialogs/node-location-
}
})
export class LocationLinkComponent implements OnInit {
- private store = inject(Store);
- private contentApi = inject(ContentApiService);
- private translationService = inject(TranslationService);
+ private readonly store = inject(Store);
+ private readonly contentApi = inject(ContentApiService);
+ private readonly translationService = inject(TranslationService);
private _path: PathInfo;
private readonly dialogRef = inject(MatDialog);
diff --git a/projects/aca-content/src/lib/components/common/logout/logout.component.ts b/projects/aca-content/src/lib/components/common/logout/logout.component.ts
index 1467687d9..ac3edb3bf 100644
--- a/projects/aca-content/src/lib/components/common/logout/logout.component.ts
+++ b/projects/aca-content/src/lib/components/common/logout/logout.component.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { Component, ViewChild, ViewEncapsulation } from '@angular/core';
+import { Component, ViewChild, ViewEncapsulation, inject } from '@angular/core';
import { Store } from '@ngrx/store';
import { SetSelectedNodesAction } from '@alfresco/aca-shared/store';
import { TranslatePipe } from '@ngx-translate/core';
@@ -42,7 +42,7 @@ import { LogoutDirective } from '@alfresco/adf-core';
encapsulation: ViewEncapsulation.None
})
export class LogoutComponent {
- constructor(private store: Store) {}
+ private readonly store = inject(Store);
@ViewChild(MatMenuItem)
menuItem: MatMenuItem;
diff --git a/projects/aca-content/src/lib/components/common/toggle-shared/toggle-shared.component.spec.ts b/projects/aca-content/src/lib/components/common/toggle-shared/toggle-shared.component.spec.ts
index c1983dc8b..3c46dcb4a 100644
--- a/projects/aca-content/src/lib/components/common/toggle-shared/toggle-shared.component.spec.ts
+++ b/projects/aca-content/src/lib/components/common/toggle-shared/toggle-shared.component.spec.ts
@@ -25,9 +25,11 @@
import { ToggleSharedComponent } from './toggle-shared.component';
import { of } from 'rxjs';
import { TestBed } from '@angular/core/testing';
+import { Store } from '@ngrx/store';
+import { SelectionState } from '@alfresco/adf-extensions';
describe('ToggleSharedComponent', () => {
- let component;
+ let component: ToggleSharedComponent;
let entry;
const storeMock: any = {
@@ -36,15 +38,21 @@ describe('ToggleSharedComponent', () => {
};
beforeEach(() => {
+ TestBed.configureTestingModule({
+ imports: [ToggleSharedComponent],
+ providers: [
+ {
+ provide: Store,
+ useValue: storeMock
+ }
+ ]
+ });
entry = {
properties: {
'qshare:sharedId': null
}
};
-
- TestBed.runInInjectionContext(() => {
- component = new ToggleSharedComponent(storeMock);
- });
+ component = TestBed.createComponent(ToggleSharedComponent).componentInstance;
});
it('should get Store selection entry on initialization', (done) => {
@@ -71,7 +79,7 @@ describe('ToggleSharedComponent', () => {
it('should dispatch `SHARE_NODE` action on share', () => {
component.ngOnInit();
- component.editSharedNode({ first: { entry } });
+ component.editSharedNode({ first: { entry } } as SelectionState, undefined);
expect(storeMock.dispatch).toHaveBeenCalled();
});
diff --git a/projects/aca-content/src/lib/components/common/toggle-shared/toggle-shared.component.ts b/projects/aca-content/src/lib/components/common/toggle-shared/toggle-shared.component.ts
index 1ba33f0b3..1701a556c 100644
--- a/projects/aca-content/src/lib/components/common/toggle-shared/toggle-shared.component.ts
+++ b/projects/aca-content/src/lib/components/common/toggle-shared/toggle-shared.component.ts
@@ -41,6 +41,8 @@ import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
encapsulation: ViewEncapsulation.None
})
export class ToggleSharedComponent implements OnInit {
+ private readonly store = inject>(Store);
+
@Input()
data: {
iconButton?: string;
@@ -56,8 +58,6 @@ export class ToggleSharedComponent implements OnInit {
private readonly destroyRef = inject(DestroyRef);
- constructor(private store: Store) {}
-
ngOnInit() {
this.selection$ = this.store.select(getAppSelection);
this.selection$.pipe(takeUntilDestroyed(this.destroyRef)).subscribe((selectionState) => {
diff --git a/projects/aca-content/src/lib/components/common/user-info/user-info.component.ts b/projects/aca-content/src/lib/components/common/user-info/user-info.component.ts
index d45e6a0a9..2fa534620 100644
--- a/projects/aca-content/src/lib/components/common/user-info/user-info.component.ts
+++ b/projects/aca-content/src/lib/components/common/user-info/user-info.component.ts
@@ -37,7 +37,7 @@ import { UserProfileService } from '@alfresco/aca-shared';
encapsulation: ViewEncapsulation.None
})
export class UserInfoComponent {
- private userProfileService = inject(UserProfileService);
+ private readonly userProfileService = inject(UserProfileService);
@ViewChild(MatMenuItem)
menuItem: MatMenuItem;
diff --git a/projects/aca-content/src/lib/components/context-menu/base-context-menu.directive.ts b/projects/aca-content/src/lib/components/context-menu/base-context-menu.directive.ts
index 82bc5dcf6..b211f91a9 100644
--- a/projects/aca-content/src/lib/components/context-menu/base-context-menu.directive.ts
+++ b/projects/aca-content/src/lib/components/context-menu/base-context-menu.directive.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { HostListener, ViewChild, Inject, Directive } from '@angular/core';
+import { HostListener, ViewChild, Directive, inject } from '@angular/core';
import { MatMenuTrigger } from '@angular/material/menu';
import { ContentActionRef } from '@alfresco/adf-extensions';
import { ContextMenuOverlayRef } from './context-menu-overlay';
@@ -32,6 +32,10 @@ import { AppExtensionService } from '@alfresco/aca-shared';
@Directive()
export class BaseContextMenuDirective {
+ protected readonly contextMenuOverlayRef = inject(ContextMenuOverlayRef);
+ protected readonly extensions = inject(AppExtensionService);
+ readonly direction = inject(CONTEXT_MENU_DIRECTION);
+
actions: Array = [];
@ViewChild(MatMenuTrigger)
@@ -44,12 +48,6 @@ export class BaseContextMenuDirective {
}
}
- constructor(
- private readonly contextMenuOverlayRef: ContextMenuOverlayRef,
- protected extensions: AppExtensionService,
- @Inject(CONTEXT_MENU_DIRECTION) public direction: Direction
- ) {}
-
onClickOutsideEvent() {
if (this.contextMenuOverlayRef) {
this.contextMenuOverlayRef.close();
diff --git a/projects/aca-content/src/lib/components/context-menu/context-menu-item.component.ts b/projects/aca-content/src/lib/components/context-menu/context-menu-item.component.ts
index 3b6ec6a87..8236c4af8 100644
--- a/projects/aca-content/src/lib/components/context-menu/context-menu-item.component.ts
+++ b/projects/aca-content/src/lib/components/context-menu/context-menu-item.component.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { Component, Input, ViewEncapsulation } from '@angular/core';
+import { Component, Input, ViewEncapsulation, inject } from '@angular/core';
import { ContentActionRef, DynamicExtensionComponent } from '@alfresco/adf-extensions';
import { AppExtensionService } from '@alfresco/aca-shared';
import { CommonModule } from '@angular/common';
@@ -39,11 +39,11 @@ import { IconComponent } from '@alfresco/adf-core';
host: { class: 'app-context-menu-item' }
})
export class ContextMenuItemComponent {
+ private readonly extensions = inject(AppExtensionService);
+
@Input()
actionRef: ContentActionRef;
- constructor(private extensions: AppExtensionService) {}
-
runAction() {
if (this.hasClickAction(this.actionRef)) {
this.extensions.runActionById(this.actionRef.actions.click);
diff --git a/projects/aca-content/src/lib/components/context-menu/context-menu-overlay.ts b/projects/aca-content/src/lib/components/context-menu/context-menu-overlay.ts
index 7dffbff3e..e8e382f37 100644
--- a/projects/aca-content/src/lib/components/context-menu/context-menu-overlay.ts
+++ b/projects/aca-content/src/lib/components/context-menu/context-menu-overlay.ts
@@ -25,7 +25,7 @@
import { OverlayRef } from '@angular/cdk/overlay';
export class ContextMenuOverlayRef {
- constructor(private overlayRef: OverlayRef) {}
+ constructor(private readonly overlayRef: OverlayRef) {}
close(): void {
this.overlayRef.dispose();
diff --git a/projects/aca-content/src/lib/components/context-menu/context-menu.component.ts b/projects/aca-content/src/lib/components/context-menu/context-menu.component.ts
index 70c11b9b1..a127dbdbe 100644
--- a/projects/aca-content/src/lib/components/context-menu/context-menu.component.ts
+++ b/projects/aca-content/src/lib/components/context-menu/context-menu.component.ts
@@ -22,13 +22,9 @@
* from Hyland Software. If not, see .
*/
-import { AfterViewInit, Component, DestroyRef, inject, Inject, OnInit, QueryList, ViewChild, ViewChildren, ViewEncapsulation } from '@angular/core';
+import { AfterViewInit, Component, DestroyRef, inject, OnInit, QueryList, ViewChild, ViewChildren, ViewEncapsulation } from '@angular/core';
import { MatMenu, MatMenuItem, MatMenuModule } from '@angular/material/menu';
import { ContentActionType, DynamicExtensionComponent } from '@alfresco/adf-extensions';
-import { ContextMenuOverlayRef } from './context-menu-overlay';
-import { CONTEXT_MENU_DIRECTION } from './direction.token';
-import { Direction } from '@angular/cdk/bidi';
-import { AppExtensionService } from '@alfresco/aca-shared';
import { CommonModule } from '@angular/common';
import { TranslatePipe } from '@ngx-translate/core';
import { MatDividerModule } from '@angular/material/divider';
@@ -69,10 +65,6 @@ export class ContextMenuComponent extends BaseContextMenuDirective implements On
private readonly destroyRef = inject(DestroyRef);
- constructor(contextMenuOverlayRef: ContextMenuOverlayRef, extensions: AppExtensionService, @Inject(CONTEXT_MENU_DIRECTION) direction: Direction) {
- super(contextMenuOverlayRef, extensions, direction);
- }
-
ngOnInit() {
this.extensions
.getAllowedContextMenuActions()
diff --git a/projects/aca-content/src/lib/components/context-menu/context-menu.service.spec.ts b/projects/aca-content/src/lib/components/context-menu/context-menu.service.spec.ts
index d81021676..4451255f5 100644
--- a/projects/aca-content/src/lib/components/context-menu/context-menu.service.spec.ts
+++ b/projects/aca-content/src/lib/components/context-menu/context-menu.service.spec.ts
@@ -24,7 +24,6 @@
import { TestBed } from '@angular/core/testing';
import { Overlay } from '@angular/cdk/overlay';
-import { Injector } from '@angular/core';
import { Store } from '@ngrx/store';
import { of } from 'rxjs';
import { NoopTranslateModule, UserPreferencesService, provideCoreAuthTesting } from '@alfresco/adf-core';
@@ -35,8 +34,6 @@ import { ContentActionRef, ContentActionType } from '@alfresco/adf-extensions';
describe('ContextMenuService', () => {
let contextMenuService: ContextMenuService;
- let overlay: Overlay;
- let injector: Injector;
let userPreferencesService: UserPreferencesService;
const customActionMock: ContentActionRef[] = [
@@ -66,31 +63,25 @@ describe('ContextMenuService', () => {
imports: [NoopTranslateModule, ContextMenuComponent],
providers: [provideCoreAuthTesting(), Overlay, { provide: Store, useValue: { select: () => of() } }, UserPreferencesService]
});
-
- injector = TestBed.inject(Injector);
- overlay = TestBed.inject(Overlay);
userPreferencesService = TestBed.inject(UserPreferencesService);
});
it('should create a custom overlay', () => {
- contextMenuService = new ContextMenuService(injector, overlay, userPreferencesService);
-
+ contextMenuService = TestBed.inject(ContextMenuService);
contextMenuService.open(overlayConfig);
expect(document.querySelector('.test-panel')).not.toBe(null);
});
it('should render component', () => {
- contextMenuService = new ContextMenuService(injector, overlay, userPreferencesService);
-
+ contextMenuService = TestBed.inject(ContextMenuService);
contextMenuService.open(overlayConfig);
expect(document.querySelector('aca-context-menu')).not.toBe(null);
});
it('should have default LTR direction value', () => {
- contextMenuService = new ContextMenuService(injector, overlay, userPreferencesService);
-
+ contextMenuService = TestBed.inject(ContextMenuService);
contextMenuService.open(overlayConfig);
expect(document.body.querySelector('div[dir="ltr"]')).not.toEqual(null);
@@ -98,8 +89,7 @@ describe('ContextMenuService', () => {
it('should change direction on textOrientation event', () => {
spyOn(userPreferencesService, 'select').and.returnValue(of('rtl'));
-
- contextMenuService = new ContextMenuService(injector, overlay, userPreferencesService);
+ contextMenuService = TestBed.inject(ContextMenuService);
contextMenuService.open(overlayConfig);
@@ -107,16 +97,14 @@ describe('ContextMenuService', () => {
});
it('should render custom context menu component', () => {
- contextMenuService = new ContextMenuService(injector, overlay, userPreferencesService);
-
+ contextMenuService = TestBed.inject(ContextMenuService);
contextMenuService.open(overlayConfig, customActionMock);
expect(document.querySelector('aca-custom-context-menu')).not.toBe(null);
});
it('should not render custom context menu when no custom actions are provided', () => {
- contextMenuService = new ContextMenuService(injector, overlay, userPreferencesService);
-
+ contextMenuService = TestBed.inject(ContextMenuService);
contextMenuService.open(overlayConfig, []);
expect(document.querySelector('aca-custom-context-menu')).toBe(null);
diff --git a/projects/aca-content/src/lib/components/context-menu/context-menu.service.ts b/projects/aca-content/src/lib/components/context-menu/context-menu.service.ts
index 9c923c912..48f1ace48 100644
--- a/projects/aca-content/src/lib/components/context-menu/context-menu.service.ts
+++ b/projects/aca-content/src/lib/components/context-menu/context-menu.service.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { ComponentRef, Injectable, Injector } from '@angular/core';
+import { ComponentRef, Injectable, Injector, inject } from '@angular/core';
import { Overlay, OverlayConfig, OverlayRef } from '@angular/cdk/overlay';
import { ComponentPortal } from '@angular/cdk/portal';
import { ContextMenuOverlayRef } from './context-menu-overlay';
@@ -39,13 +39,13 @@ import { CustomContextMenuComponent } from './custom-context-menu.component';
providedIn: 'root'
})
export class ContextMenuService {
+ private readonly injector = inject(Injector);
+ private readonly overlay = inject(Overlay);
+ private readonly userPreferenceService = inject(UserPreferencesService);
+
private direction: Directionality;
- constructor(
- private readonly injector: Injector,
- private readonly overlay: Overlay,
- private readonly userPreferenceService: UserPreferencesService
- ) {
+ constructor() {
this.userPreferenceService.select('textOrientation').subscribe((textOrientation) => {
this.direction = textOrientation;
});
diff --git a/projects/aca-content/src/lib/components/context-menu/custom-context-menu.component.ts b/projects/aca-content/src/lib/components/context-menu/custom-context-menu.component.ts
index cbd240709..1b71b2cfa 100644
--- a/projects/aca-content/src/lib/components/context-menu/custom-context-menu.component.ts
+++ b/projects/aca-content/src/lib/components/context-menu/custom-context-menu.component.ts
@@ -22,11 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { AfterViewInit, Component, Inject, ViewEncapsulation } from '@angular/core';
-import { Direction } from '@angular/cdk/bidi';
-import { ContextMenuOverlayRef } from './context-menu-overlay';
-import { AppExtensionService } from '@alfresco/aca-shared';
-import { CONTEXT_MENU_DIRECTION } from './direction.token';
+import { AfterViewInit, Component, ViewEncapsulation, inject } from '@angular/core';
import { ContentActionRef, DynamicExtensionComponent } from '@alfresco/adf-extensions';
import { CommonModule } from '@angular/common';
import { TranslatePipe } from '@ngx-translate/core';
@@ -58,13 +54,9 @@ import { BaseContextMenuDirective } from './base-context-menu.directive';
encapsulation: ViewEncapsulation.None
})
export class CustomContextMenuComponent extends BaseContextMenuDirective implements AfterViewInit {
- constructor(
- contextMenuOverlayRef: ContextMenuOverlayRef,
- extensions: AppExtensionService,
- @Inject(CONTEXT_MENU_DIRECTION) direction: Direction,
- @Inject(CONTEXT_MENU_CUSTOM_ACTIONS) customActions: ContentActionRef[]
- ) {
- super(contextMenuOverlayRef, extensions, direction);
+ constructor() {
+ super();
+ const customActions = inject(CONTEXT_MENU_CUSTOM_ACTIONS) as ContentActionRef[];
this.actions = customActions;
}
diff --git a/projects/aca-content/src/lib/components/details/details.component.ts b/projects/aca-content/src/lib/components/details/details.component.ts
index cb13a104d..e17797da2 100644
--- a/projects/aca-content/src/lib/components/details/details.component.ts
+++ b/projects/aca-content/src/lib/components/details/details.component.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { Component, OnDestroy, OnInit, ViewEncapsulation } from '@angular/core';
+import { Component, OnDestroy, OnInit, ViewEncapsulation, inject } from '@angular/core';
import { ActivatedRoute } from '@angular/router';
import { AppHookService, ContentApiService, PageComponent, PageLayoutComponent, ToolbarComponent } from '@alfresco/aca-shared';
import { NavigateToFolder, NavigateToPreviousPage, SetSelectedNodesAction } from '@alfresco/aca-shared/store';
@@ -63,6 +63,13 @@ import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
encapsulation: ViewEncapsulation.None
})
export class DetailsComponent extends PageComponent implements OnInit, OnDestroy {
+ private readonly route = inject(ActivatedRoute);
+ private readonly contentApi = inject(ContentApiService);
+ private readonly contentService = inject(ContentService);
+ private readonly nodesApiService = inject(NodesApiService);
+ private readonly appHookService = inject(AppHookService);
+ private readonly location = inject(Location);
+
nodeId: string;
isLoading: boolean;
activeTab = 1;
@@ -70,17 +77,6 @@ export class DetailsComponent extends PageComponent implements OnInit, OnDestroy
nodeIcon: string;
canManagePermissions = true;
- constructor(
- private readonly route: ActivatedRoute,
- private readonly contentApi: ContentApiService,
- private readonly contentService: ContentService,
- private readonly nodesApiService: NodesApiService,
- private readonly appHookService: AppHookService,
- private readonly location: Location
- ) {
- super();
- }
-
ngOnInit(): void {
super.ngOnInit();
this.isLoading = true;
diff --git a/projects/aca-content/src/lib/components/dl-custom-components/datatable-cell-badges/datatable-cell-badges.component.ts b/projects/aca-content/src/lib/components/dl-custom-components/datatable-cell-badges/datatable-cell-badges.component.ts
index 6b0a4852c..5ccfa74f6 100644
--- a/projects/aca-content/src/lib/components/dl-custom-components/datatable-cell-badges/datatable-cell-badges.component.ts
+++ b/projects/aca-content/src/lib/components/dl-custom-components/datatable-cell-badges/datatable-cell-badges.component.ts
@@ -40,14 +40,14 @@ import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
imports: [CommonModule, TranslatePipe, DynamicExtensionComponent, IconComponent]
})
export class DatatableCellBadgesComponent implements OnInit {
+ private readonly appExtensionService = inject(AppExtensionService);
+
@Input({ required: true }) node: NodeEntry;
badges: Badge[];
private readonly destroyRef = inject(DestroyRef);
- constructor(private appExtensionService: AppExtensionService) {}
-
ngOnInit() {
this.appExtensionService
.getBadges(this.node)
diff --git a/projects/aca-content/src/lib/components/dl-custom-components/tags-column/tags-column.component.ts b/projects/aca-content/src/lib/components/dl-custom-components/tags-column/tags-column.component.ts
index 295cd00a9..fa9432852 100644
--- a/projects/aca-content/src/lib/components/dl-custom-components/tags-column/tags-column.component.ts
+++ b/projects/aca-content/src/lib/components/dl-custom-components/tags-column/tags-column.component.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { ChangeDetectorRef, Component, Input, OnInit, ViewEncapsulation } from '@angular/core';
+import { ChangeDetectorRef, Component, Input, OnInit, ViewEncapsulation, inject } from '@angular/core';
import { TagNodeListComponent } from '@alfresco/adf-content-services';
@Component({
@@ -36,13 +36,13 @@ import { TagNodeListComponent } from '@alfresco/adf-content-services';
}
})
export class TagsColumnComponent implements OnInit {
+ private readonly cd = inject(ChangeDetectorRef);
+
@Input()
context: any;
nodeId: string;
- constructor(private cd: ChangeDetectorRef) {}
-
ngOnInit(): void {
this.nodeId = this.context?.row?.id;
}
diff --git a/projects/aca-content/src/lib/components/dl-custom-components/thumbnail-column/thumbnail-column.component.ts b/projects/aca-content/src/lib/components/dl-custom-components/thumbnail-column/thumbnail-column.component.ts
index 6b8786688..9e994b306 100644
--- a/projects/aca-content/src/lib/components/dl-custom-components/thumbnail-column/thumbnail-column.component.ts
+++ b/projects/aca-content/src/lib/components/dl-custom-components/thumbnail-column/thumbnail-column.component.ts
@@ -34,7 +34,7 @@ import { MatIconModule } from '@angular/material/icon';
encapsulation: ViewEncapsulation.None
})
export class ThumbnailColumnComponent implements OnChanges {
- private translation = inject(TranslationService);
+ private readonly translation = inject(TranslationService);
@Input()
context: any;
diff --git a/projects/aca-content/src/lib/components/favorite-libraries/favorite-libraries.component.ts b/projects/aca-content/src/lib/components/favorite-libraries/favorite-libraries.component.ts
index 0b1027f64..9e0c6eb1a 100644
--- a/projects/aca-content/src/lib/components/favorite-libraries/favorite-libraries.component.ts
+++ b/projects/aca-content/src/lib/components/favorite-libraries/favorite-libraries.component.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { ChangeDetectorRef, Component, OnInit, ViewEncapsulation } from '@angular/core';
+import { ChangeDetectorRef, Component, OnInit, ViewEncapsulation, inject } from '@angular/core';
import { FavoritePaging, Pagination } from '@alfresco/js-api';
import { ContentApiService } from '@alfresco/aca-shared';
import { UserPreferencesService } from '@alfresco/adf-core';
@@ -37,6 +37,10 @@ import { LibrariesBaseComponent } from '../libraries-base/libraries-base.compone
encapsulation: ViewEncapsulation.None
})
export class FavoriteLibrariesComponent extends LibrariesBaseComponent implements OnInit {
+ private readonly contentApiService = inject(ContentApiService);
+ private readonly preferences = inject(UserPreferencesService);
+ private readonly changeDetectorRef = inject(ChangeDetectorRef);
+
pagination: Pagination = new Pagination({
skipCount: 0,
maxItems: 25,
@@ -46,14 +50,6 @@ export class FavoriteLibrariesComponent extends LibrariesBaseComponent implement
list: FavoritePaging = null;
columns: DocumentListPresetRef[] = [];
- constructor(
- private contentApiService: ContentApiService,
- private preferences: UserPreferencesService,
- private changeDetectorRef: ChangeDetectorRef
- ) {
- super();
- }
-
ngOnInit() {
super.ngOnInit();
diff --git a/projects/aca-content/src/lib/components/favorites/favorites.component.ts b/projects/aca-content/src/lib/components/favorites/favorites.component.ts
index 4a1286295..4798947a9 100644
--- a/projects/aca-content/src/lib/components/favorites/favorites.component.ts
+++ b/projects/aca-content/src/lib/components/favorites/favorites.component.ts
@@ -32,7 +32,7 @@ import {
ToolbarComponent
} from '@alfresco/aca-shared';
import { Node, NodeEntry, PathElement, PathInfo } from '@alfresco/js-api';
-import { Component, OnInit, ViewEncapsulation } from '@angular/core';
+import { Component, OnInit, ViewEncapsulation, inject } from '@angular/core';
import { debounceTime, map } from 'rxjs/operators';
import { DocumentListPresetRef, DynamicColumnComponent } from '@alfresco/adf-extensions';
import { CommonModule } from '@angular/common';
@@ -72,11 +72,9 @@ import { SearchAiInputContainerComponent } from '../knowledge-retrieval/search-a
selector: 'aca-favorites'
})
export class FavoritesComponent extends PageComponent implements OnInit {
- columns: DocumentListPresetRef[] = [];
+ private readonly contentApi = inject(ContentApiService);
- constructor(private contentApi: ContentApiService) {
- super();
- }
+ columns: DocumentListPresetRef[] = [];
ngOnInit() {
super.ngOnInit();
diff --git a/projects/aca-content/src/lib/components/files/files.component.ts b/projects/aca-content/src/lib/components/files/files.component.ts
index fb53f1ca8..cd735e931 100644
--- a/projects/aca-content/src/lib/components/files/files.component.ts
+++ b/projects/aca-content/src/lib/components/files/files.component.ts
@@ -29,7 +29,7 @@ import {
PaginationComponent,
ShowHeaderMode
} from '@alfresco/adf-core';
-import { Component, OnDestroy, OnInit, ViewEncapsulation } from '@angular/core';
+import { Component, OnDestroy, OnInit, ViewEncapsulation, inject } from '@angular/core';
import { ActivatedRoute, Params } from '@angular/router';
import { Node, NodeEntry, PathElement } from '@alfresco/js-api';
import { NodeActionsService } from '../../services/node-actions.service';
@@ -92,6 +92,11 @@ import { extractFiltersFromEncodedQuery } from '../../utils/aca-search-utils';
selector: 'aca-files'
})
export class FilesComponent extends PageComponent implements OnInit, OnDestroy {
+ private readonly contentApi = inject(ContentApiService);
+ private readonly nodeActionsService = inject(NodeActionsService);
+ private readonly route = inject(ActivatedRoute);
+ private readonly queryBuilderService = inject(SearchHeaderQueryBuilderService);
+
isValidPath = true;
isAdmin = false;
selectedNode: NodeEntry;
@@ -107,15 +112,6 @@ export class FilesComponent extends PageComponent implements OnInit, OnDestroy {
return this._errorTranslationKey;
}
- constructor(
- private readonly contentApi: ContentApiService,
- private readonly nodeActionsService: NodeActionsService,
- private readonly route: ActivatedRoute,
- private readonly queryBuilderService: SearchHeaderQueryBuilderService
- ) {
- super();
- }
-
ngOnInit() {
super.ngOnInit();
diff --git a/projects/aca-content/src/lib/components/home/home.component.ts b/projects/aca-content/src/lib/components/home/home.component.ts
index bbbfd1dcd..c7d2495f5 100644
--- a/projects/aca-content/src/lib/components/home/home.component.ts
+++ b/projects/aca-content/src/lib/components/home/home.component.ts
@@ -32,8 +32,8 @@ import { AppSettingsService } from '@alfresco/aca-shared';
encapsulation: ViewEncapsulation.None
})
export class HomeComponent implements OnInit {
- private appSettings = inject(AppSettingsService);
- private router = inject(Router);
+ private readonly appSettings = inject(AppSettingsService);
+ private readonly router = inject(Router);
ngOnInit() {
this.router.navigateByUrl(this.appSettings.landingPage);
diff --git a/projects/aca-content/src/lib/components/info-drawer/comments-tab/comments-tab.component.ts b/projects/aca-content/src/lib/components/info-drawer/comments-tab/comments-tab.component.ts
index 78efd870b..6e339c5cd 100644
--- a/projects/aca-content/src/lib/components/info-drawer/comments-tab/comments-tab.component.ts
+++ b/projects/aca-content/src/lib/components/info-drawer/comments-tab/comments-tab.component.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { Component, Input, OnInit, Optional, ViewEncapsulation } from '@angular/core';
+import { Component, Input, OnInit, ViewEncapsulation, inject } from '@angular/core';
import { Node } from '@alfresco/js-api';
import { isLocked, NodePermissionService } from '@alfresco/aca-shared';
import { MatCardModule } from '@angular/material/card';
@@ -40,16 +40,14 @@ import { ExternalNodePermissionCommentsTabService } from './external-node-permis
styleUrls: ['./comments-tab.component.scss']
})
export class CommentsTabComponent implements OnInit {
+ private readonly permission = inject(NodePermissionService);
+ private readonly externalPermissionNodeService = inject(ExternalNodePermissionCommentsTabService, { optional: true });
+
@Input()
node: Node;
canUpdateNode = false;
- constructor(
- private readonly permission: NodePermissionService,
- @Optional() private readonly externalPermissionNodeService: ExternalNodePermissionCommentsTabService
- ) {}
-
ngOnInit(): void {
if (!this.node) {
this.canUpdateNode = false;
diff --git a/projects/aca-content/src/lib/components/info-drawer/library-metadata-tab/library-metadata-form.component.ts b/projects/aca-content/src/lib/components/info-drawer/library-metadata-tab/library-metadata-form.component.ts
index 965d4c24d..86ba533e3 100644
--- a/projects/aca-content/src/lib/components/info-drawer/library-metadata-tab/library-metadata-form.component.ts
+++ b/projects/aca-content/src/lib/components/info-drawer/library-metadata-tab/library-metadata-form.component.ts
@@ -77,6 +77,10 @@ export class InstantErrorStateMatcher implements ErrorStateMatcher {
encapsulation: ViewEncapsulation.None
})
export class LibraryMetadataFormComponent implements OnInit, OnChanges {
+ private readonly alfrescoApiService = inject(AlfrescoApiService);
+ protected readonly store = inject>(Store);
+ private readonly appHookService = inject(AppHookService);
+
private _titleErrorTranslationKey: string;
@LazyApi((self: LibraryMetadataFormComponent) => new QueriesApi(self.alfrescoApiService.getInstance()))
@@ -112,12 +116,6 @@ export class LibraryMetadataFormComponent implements OnInit, OnChanges {
private readonly libraryNameInput: ElementRef;
private readonly destroyRef = inject(DestroyRef);
- constructor(
- private readonly alfrescoApiService: AlfrescoApiService,
- protected readonly store: Store,
- private readonly appHookService: AppHookService
- ) {}
-
toggleEdit() {
if (this.form.enabled) {
this.form.disable({
diff --git a/projects/aca-content/src/lib/components/info-drawer/metadata-tab/metadata-tab.component.ts b/projects/aca-content/src/lib/components/info-drawer/metadata-tab/metadata-tab.component.ts
index c78b65bee..9e175652f 100644
--- a/projects/aca-content/src/lib/components/info-drawer/metadata-tab/metadata-tab.component.ts
+++ b/projects/aca-content/src/lib/components/info-drawer/metadata-tab/metadata-tab.component.ts
@@ -61,6 +61,17 @@ import { ExtensionService } from '@alfresco/adf-extensions';
host: { class: 'app-metadata-tab' }
})
export class MetadataTabComponent implements OnInit {
+ private readonly permission = inject(NodePermissionService);
+ protected readonly extensions = inject(AppExtensionService);
+ private readonly appConfig = inject(AppConfigService);
+ private readonly notificationService = inject(NotificationService);
+ private readonly contentMetadataService = inject(ContentMetadataService);
+ private readonly actions$ = inject(Actions);
+ private readonly tagService = inject(TagService);
+ private readonly categoryService = inject(CategoryService);
+ private readonly store = inject>(Store);
+ private readonly extensionService = inject(ExtensionService);
+
private _displayCategories = true;
private _displayTags = true;
@@ -80,18 +91,7 @@ export class MetadataTabComponent implements OnInit {
private readonly destroyRef = inject(DestroyRef);
- constructor(
- private readonly permission: NodePermissionService,
- protected readonly extensions: AppExtensionService,
- private readonly appConfig: AppConfigService,
- private readonly notificationService: NotificationService,
- private readonly contentMetadataService: ContentMetadataService,
- private readonly actions$: Actions,
- private readonly tagService: TagService,
- private readonly categoryService: CategoryService,
- private readonly store: Store,
- private readonly extensionService: ExtensionService
- ) {
+ constructor() {
if (this.extensions.contentMetadata) {
this.appConfig.config['content-metadata'].presets = this.extensions.contentMetadata.presets;
}
diff --git a/projects/aca-content/src/lib/components/knowledge-retrieval/search-ai/agents-button/agents-button.component.ts b/projects/aca-content/src/lib/components/knowledge-retrieval/search-ai/agents-button/agents-button.component.ts
index a856fbf43..bfffd1027 100644
--- a/projects/aca-content/src/lib/components/knowledge-retrieval/search-ai/agents-button/agents-button.component.ts
+++ b/projects/aca-content/src/lib/components/knowledge-retrieval/search-ai/agents-button/agents-button.component.ts
@@ -47,6 +47,13 @@ import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
host: { class: 'aca-agents-button' }
})
export class AgentsButtonComponent implements OnInit {
+ private readonly store = inject>(Store);
+ private readonly notificationService = inject(NotificationService);
+ private readonly searchAiService = inject(SearchAiService);
+ private readonly agentService = inject(AgentService);
+ private readonly translateService = inject(TranslateService);
+ private readonly cd = inject(ChangeDetectorRef);
+
@Input()
data: { trigger: string };
@@ -74,15 +81,6 @@ export class AgentsButtonComponent implements OnInit {
private readonly destroyRef = inject(DestroyRef);
- constructor(
- private store: Store,
- private notificationService: NotificationService,
- private searchAiService: SearchAiService,
- private agentService: AgentService,
- private translateService: TranslateService,
- private cd: ChangeDetectorRef
- ) {}
-
ngOnInit(): void {
this.store
.select(getAppSelection)
diff --git a/projects/aca-content/src/lib/components/knowledge-retrieval/search-ai/search-ai-input-container/search-ai-input-container.component.ts b/projects/aca-content/src/lib/components/knowledge-retrieval/search-ai/search-ai-input-container/search-ai-input-container.component.ts
index d6e83a660..29229befc 100644
--- a/projects/aca-content/src/lib/components/knowledge-retrieval/search-ai/search-ai-input-container/search-ai-input-container.component.ts
+++ b/projects/aca-content/src/lib/components/knowledge-retrieval/search-ai/search-ai-input-container/search-ai-input-container.component.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { Component, Input, OnInit, ViewEncapsulation } from '@angular/core';
+import { Component, Input, OnInit, ViewEncapsulation, inject } from '@angular/core';
import { MatButtonModule } from '@angular/material/button';
import { MatIconModule } from '@angular/material/icon';
import { SearchAiInputComponent } from '../search-ai-input/search-ai-input.component';
@@ -42,6 +42,10 @@ import { Router } from '@angular/router';
encapsulation: ViewEncapsulation.None
})
export class SearchAiInputContainerComponent implements OnInit {
+ private readonly searchAiService = inject(SearchAiService);
+ private readonly searchNavigationService = inject(SearchAiNavigationService);
+ private readonly router = inject(Router);
+
@Input()
placeholder = 'KNOWLEDGE_RETRIEVAL.SEARCH.SEARCH_INPUT.DEFAULT_PLACEHOLDER';
@Input()
@@ -52,12 +56,6 @@ export class SearchAiInputContainerComponent implements OnInit {
inputState$: Observable;
isKnowledgeRetrievalPage = false;
- constructor(
- private readonly searchAiService: SearchAiService,
- private searchNavigationService: SearchAiNavigationService,
- private router: Router
- ) {}
-
ngOnInit(): void {
this.isKnowledgeRetrievalPage = this.router.url.startsWith('/knowledge-retrieval');
this.inputState$ = this.searchAiService.toggleSearchAiInput$;
diff --git a/projects/aca-content/src/lib/components/knowledge-retrieval/search-ai/search-ai-input/search-ai-input.component.ts b/projects/aca-content/src/lib/components/knowledge-retrieval/search-ai/search-ai-input/search-ai-input.component.ts
index c60a611d2..780dc2ed6 100644
--- a/projects/aca-content/src/lib/components/knowledge-retrieval/search-ai/search-ai-input/search-ai-input.component.ts
+++ b/projects/aca-content/src/lib/components/knowledge-retrieval/search-ai/search-ai-input/search-ai-input.component.ts
@@ -77,6 +77,14 @@ const MatTooltipOptions: MatTooltipDefaultOptions = {
providers: [{ provide: MAT_TOOLTIP_DEFAULT_OPTIONS, useValue: MatTooltipOptions }]
})
export class SearchAiInputComponent implements OnInit {
+ private readonly store = inject>(Store);
+ private readonly searchAiService = inject(SearchAiService);
+ private readonly notificationService = inject(NotificationService);
+ private readonly agentService = inject(AgentService);
+ private readonly userPreferencesService = inject(UserPreferencesService);
+ private readonly translateService = inject(TranslateService);
+ private readonly modalAiService = inject(ModalAiService);
+
@Input()
placeholder: string;
@@ -91,10 +99,10 @@ export class SearchAiInputComponent implements OnInit {
private readonly storedNodesKey = 'knowledgeRetrievalNodes';
- private _agentControl = new FormControl(null);
+ private readonly _agentControl = new FormControl(null);
private _agents: Agent[] = [];
private selectedNodesState: SelectionState;
- private _queryControl = new FormControl('');
+ private readonly _queryControl = new FormControl('');
private _initialsByAgentId: { [key: string]: string } = {};
get agentControl(): FormControl {
@@ -115,16 +123,6 @@ export class SearchAiInputComponent implements OnInit {
private readonly destroyRef = inject(DestroyRef);
- constructor(
- private store: Store,
- private searchAiService: SearchAiService,
- private notificationService: NotificationService,
- private agentService: AgentService,
- private userPreferencesService: UserPreferencesService,
- private translateService: TranslateService,
- private modalAiService: ModalAiService
- ) {}
-
ngOnInit(): void {
const queryValue = this.usedInAiResultsPage ? '' : this.searchTerm || '';
this.queryControl.setValue(queryValue);
diff --git a/projects/aca-content/src/lib/components/knowledge-retrieval/search-ai/search-ai-results/search-ai-results.component.ts b/projects/aca-content/src/lib/components/knowledge-retrieval/search-ai/search-ai-results/search-ai-results.component.ts
index 00c2a2456..3a5c974e0 100644
--- a/projects/aca-content/src/lib/components/knowledge-retrieval/search-ai/search-ai-results/search-ai-results.component.ts
+++ b/projects/aca-content/src/lib/components/knowledge-retrieval/search-ai/search-ai-results/search-ai-results.component.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { Component, ElementRef, OnInit, ViewEncapsulation } from '@angular/core';
+import { Component, ElementRef, OnInit, ViewEncapsulation, inject } from '@angular/core';
import { ActivatedRoute } from '@angular/router';
import { PageComponent, PageLayoutComponent, ContentApiService } from '@alfresco/aca-shared';
import { catchError, delay, filter, finalize, map, retry, shareReplay, switchMap, tap } from 'rxjs/operators';
@@ -74,6 +74,16 @@ import { searchAiMarkedOptions } from './search-ai-marked-options';
host: { class: 'aca-search-ai-results' }
})
export class SearchAiResultsComponent extends PageComponent implements OnInit {
+ private readonly route = inject(ActivatedRoute);
+ private readonly clipboardService = inject(ClipboardService);
+ private readonly thumbnailService = inject(ThumbnailService);
+ private readonly translateService = inject(TranslateService);
+ private readonly unsavedChangesGuard = inject(UnsavedChangesGuard);
+ private readonly modalAiService = inject(ModalAiService);
+ private readonly viewerService = inject(ViewerService);
+ private readonly elementRef = inject(ElementRef);
+ private readonly contentApi = inject(ContentApiService);
+
private static readonly MERMAID_BLOCK_REGEX = /```mermaid([\s\S]*?)```/g;
private static readonly LATEX_BLOCK_REGEX = /```latex([\s\S]*?)```/g;
@@ -124,20 +134,6 @@ export class SearchAiResultsComponent extends PageComponent implements OnInit {
return this._hasReferencesLoadingError;
}
- constructor(
- private readonly route: ActivatedRoute,
- private readonly clipboardService: ClipboardService,
- private readonly thumbnailService: ThumbnailService,
- private readonly translateService: TranslateService,
- private readonly unsavedChangesGuard: UnsavedChangesGuard,
- private readonly modalAiService: ModalAiService,
- private readonly viewerService: ViewerService,
- private readonly elementRef: ElementRef,
- private readonly contentApi: ContentApiService
- ) {
- super();
- }
-
ngOnInit(): void {
this.viewerService.customNodesOrder = JSON.parse(this.userPreferencesService.get('aiReferences', '[]'));
this.route.queryParams
diff --git a/projects/aca-content/src/lib/components/library-list/library-list.component.ts b/projects/aca-content/src/lib/components/library-list/library-list.component.ts
index 6a0edf37a..4e6f3207b 100644
--- a/projects/aca-content/src/lib/components/library-list/library-list.component.ts
+++ b/projects/aca-content/src/lib/components/library-list/library-list.component.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { ChangeDetectorRef, Component, OnInit, ViewEncapsulation } from '@angular/core';
+import { ChangeDetectorRef, Component, OnInit, ViewEncapsulation, inject } from '@angular/core';
import { Pagination, SitePaging } from '@alfresco/js-api';
import { UserPreferencesService } from '@alfresco/adf-core';
import { SitesService } from '@alfresco/adf-content-services';
@@ -36,6 +36,10 @@ import { LibrariesBaseComponent } from '../libraries-base/libraries-base.compone
encapsulation: ViewEncapsulation.None
})
export class LibraryListComponent extends LibrariesBaseComponent implements OnInit {
+ private readonly preferences = inject(UserPreferencesService);
+ private readonly changeDetectorRef = inject(ChangeDetectorRef);
+ private readonly sitesService = inject(SitesService);
+
pagination = new Pagination({
skipCount: 0,
maxItems: 25,
@@ -44,14 +48,6 @@ export class LibraryListComponent extends LibrariesBaseComponent implements OnIn
isLoading = false;
list: SitePaging = null;
- constructor(
- private readonly preferences: UserPreferencesService,
- private readonly changeDetectorRef: ChangeDetectorRef,
- private readonly sitesService: SitesService
- ) {
- super();
- }
-
ngOnInit() {
super.ngOnInit();
diff --git a/projects/aca-content/src/lib/components/search/search-action-menu/search-action-menu.component.ts b/projects/aca-content/src/lib/components/search/search-action-menu/search-action-menu.component.ts
index d0e78dcb5..bd926d21a 100644
--- a/projects/aca-content/src/lib/components/search/search-action-menu/search-action-menu.component.ts
+++ b/projects/aca-content/src/lib/components/search/search-action-menu/search-action-menu.component.ts
@@ -24,7 +24,7 @@
import { SearchQueryBuilderService } from '@alfresco/adf-content-services';
import { SearchSortingDefinition } from '@alfresco/adf-content-services/lib/search/models/search-sorting-definition.interface';
-import { Component, EventEmitter, OnInit, Output, ViewEncapsulation } from '@angular/core';
+import { Component, EventEmitter, OnInit, Output, ViewEncapsulation, inject } from '@angular/core';
import { CommonModule } from '@angular/common';
import { TranslatePipe } from '@ngx-translate/core';
import { MatMenuModule } from '@angular/material/menu';
@@ -38,13 +38,13 @@ import { MatButtonModule } from '@angular/material/button';
encapsulation: ViewEncapsulation.None
})
export class SearchActionMenuComponent implements OnInit {
+ private readonly queryBuilder = inject(SearchQueryBuilderService);
+
@Output()
sortingSelected: EventEmitter = new EventEmitter();
options: SearchSortingDefinition[] = [];
- constructor(private queryBuilder: SearchQueryBuilderService) {}
-
ngOnInit(): void {
this.options = this.queryBuilder.getSortingOptions();
}
diff --git a/projects/aca-content/src/lib/components/search/search-execution.service.ts b/projects/aca-content/src/lib/components/search/search-execution.service.ts
index b8f774161..812e35b6c 100644
--- a/projects/aca-content/src/lib/components/search/search-execution.service.ts
+++ b/projects/aca-content/src/lib/components/search/search-execution.service.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { Injectable } from '@angular/core';
+import { Injectable, inject } from '@angular/core';
import { Store } from '@ngrx/store';
import { AppStore, SearchByTermAction } from '@alfresco/aca-shared/store';
import { SearchQueryBuilderService } from '@alfresco/adf-content-services';
@@ -32,13 +32,11 @@ import { SearchLibrariesQueryBuilderService } from './search-libraries-results/s
@Injectable({ providedIn: 'root' })
export class SearchExecutionService {
- constructor(
- private readonly store: Store,
- private readonly queryBuilder: SearchQueryBuilderService,
- private readonly queryLibrariesBuilder: SearchLibrariesQueryBuilderService,
- private readonly filterService: SearchFilterService,
- private readonly searchNavigationService: SearchNavigationService
- ) {}
+ private readonly store = inject>(Store);
+ private readonly queryBuilder = inject(SearchQueryBuilderService);
+ private readonly queryLibrariesBuilder = inject(SearchLibrariesQueryBuilderService);
+ private readonly filterService = inject(SearchFilterService);
+ private readonly searchNavigationService = inject(SearchNavigationService);
execute(searchedWord: string) {
if (!searchedWord?.trim()) {
diff --git a/projects/aca-content/src/lib/components/search/search-filter.service.ts b/projects/aca-content/src/lib/components/search/search-filter.service.ts
index bf055ccb8..87d2a74c4 100644
--- a/projects/aca-content/src/lib/components/search/search-filter.service.ts
+++ b/projects/aca-content/src/lib/components/search/search-filter.service.ts
@@ -22,13 +22,15 @@
* from Hyland Software. If not, see .
*/
-import { Injectable } from '@angular/core';
+import { Injectable, inject } from '@angular/core';
import { SearchQueryBuilderService } from '@alfresco/adf-content-services';
import { SearchOptionIds, SearchOptionModel } from '@alfresco/aca-shared/store';
import { isOperator } from '../../utils/aca-search-utils';
@Injectable({ providedIn: 'root' })
export class SearchFilterService {
+ private readonly queryBuilder = inject(SearchQueryBuilderService);
+
searchInMode: 'content' | 'libraries' = 'content';
filesChecked = true;
foldersChecked = true;
@@ -54,8 +56,6 @@ export class SearchFilterService {
}
];
- constructor(private readonly queryBuilder: SearchQueryBuilderService) {}
-
isFilesChecked(): boolean {
return this.getOptionValue(SearchOptionIds.Files);
}
diff --git a/projects/aca-content/src/lib/components/search/search-input/search-input.component.ts b/projects/aca-content/src/lib/components/search/search-input/search-input.component.ts
index d33ff2308..6ac32107f 100644
--- a/projects/aca-content/src/lib/components/search/search-input/search-input.component.ts
+++ b/projects/aca-content/src/lib/components/search/search-input/search-input.component.ts
@@ -52,6 +52,15 @@ import { extractSearchedWordFromEncodedQuery } from '../../../utils/aca-search-u
host: { class: 'aca-search-input' }
})
export class SearchInputComponent implements OnInit, OnDestroy {
+ private readonly queryBuilder = inject(SearchQueryBuilderService);
+ private readonly config = inject(AppConfigService);
+ private readonly router = inject(Router);
+ private readonly route = inject(ActivatedRoute);
+ private readonly appHookService = inject(AppHookService);
+ private readonly filterService = inject(SearchFilterService);
+ private readonly searchExecutionService = inject(SearchExecutionService);
+ readonly searchNavigationService = inject(SearchNavigationService);
+
has400LibraryError = false;
searchOnChange: boolean;
searchedWord: string = null;
@@ -62,16 +71,7 @@ export class SearchInputComponent implements OnInit, OnDestroy {
private readonly destroyRef = inject(DestroyRef);
- constructor(
- private readonly queryBuilder: SearchQueryBuilderService,
- private readonly config: AppConfigService,
- private readonly router: Router,
- private readonly route: ActivatedRoute,
- private readonly appHookService: AppHookService,
- private readonly filterService: SearchFilterService,
- private readonly searchExecutionService: SearchExecutionService,
- public readonly searchNavigationService: SearchNavigationService
- ) {
+ constructor() {
this.searchOnChange = this.config.get('search.aca:triggeredOnChange', true);
}
diff --git a/projects/aca-content/src/lib/components/search/search-libraries-results/search-libraries-query-builder.service.spec.ts b/projects/aca-content/src/lib/components/search/search-libraries-results/search-libraries-query-builder.service.spec.ts
index ac70fa8fc..280c3c892 100644
--- a/projects/aca-content/src/lib/components/search/search-libraries-results/search-libraries-query-builder.service.spec.ts
+++ b/projects/aca-content/src/lib/components/search/search-libraries-results/search-libraries-query-builder.service.spec.ts
@@ -40,7 +40,7 @@ describe('SearchLibrariesQueryBuilderService', () => {
apiService = TestBed.inject(AlfrescoApiService);
apiService.reset();
- builder = new SearchLibrariesQueryBuilderService(apiService);
+ builder = TestBed.inject(SearchLibrariesQueryBuilderService);
queriesApi = builder['queriesApi'];
});
diff --git a/projects/aca-content/src/lib/components/search/search-libraries-results/search-libraries-query-builder.service.ts b/projects/aca-content/src/lib/components/search/search-libraries-results/search-libraries-query-builder.service.ts
index a37a185ed..6104eebe5 100644
--- a/projects/aca-content/src/lib/components/search/search-libraries-results/search-libraries-query-builder.service.ts
+++ b/projects/aca-content/src/lib/components/search/search-libraries-results/search-libraries-query-builder.service.ts
@@ -23,7 +23,7 @@
*/
import { AlfrescoApiService } from '@alfresco/adf-content-services';
-import { Injectable } from '@angular/core';
+import { Injectable, inject } from '@angular/core';
import { QueriesApi, SitePaging, LazyApi } from '@alfresco/js-api';
import { Subject } from 'rxjs';
@@ -39,6 +39,8 @@ export interface LibrarySearchQuery {
providedIn: 'root'
})
export class SearchLibrariesQueryBuilderService {
+ private readonly alfrescoApiService = inject(AlfrescoApiService);
+
private _userQuery = '';
@LazyApi((self: SearchLibrariesQueryBuilderService) => new QueriesApi(self.alfrescoApiService.getInstance()))
@@ -58,8 +60,6 @@ export class SearchLibrariesQueryBuilderService {
this._userQuery = value ? value.trim() : '';
}
- constructor(private alfrescoApiService: AlfrescoApiService) {}
-
update(): void {
const query = this.buildQuery();
if (query) {
diff --git a/projects/aca-content/src/lib/components/search/search-libraries-results/search-libraries-results.component.ts b/projects/aca-content/src/lib/components/search/search-libraries-results/search-libraries-results.component.ts
index e9ef2dceb..e11f87462 100644
--- a/projects/aca-content/src/lib/components/search/search-libraries-results/search-libraries-results.component.ts
+++ b/projects/aca-content/src/lib/components/search/search-libraries-results/search-libraries-results.component.ts
@@ -24,7 +24,7 @@
import { NavigateLibraryAction } from '@alfresco/aca-shared/store';
import { NodePaging, Pagination, SiteEntry } from '@alfresco/js-api';
-import { Component, OnInit, ViewEncapsulation } from '@angular/core';
+import { Component, OnInit, ViewEncapsulation, inject } from '@angular/core';
import { ActivatedRoute, Params } from '@angular/router';
import { SearchLibrariesQueryBuilderService } from './search-libraries-query-builder.service';
import {
@@ -72,6 +72,10 @@ import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
encapsulation: ViewEncapsulation.None
})
export class SearchLibrariesResultsComponent extends PageComponent implements OnInit {
+ private readonly librariesQueryBuilder = inject(SearchLibrariesQueryBuilderService);
+ private readonly route = inject(ActivatedRoute);
+ private readonly appHookService = inject(AppHookService);
+
searchedWord: string;
queryParamName = 'q';
data: NodePaging;
@@ -79,12 +83,9 @@ export class SearchLibrariesResultsComponent extends PageComponent implements On
isLoading = false;
columns: DocumentListPresetRef[] = [];
- constructor(
- private readonly librariesQueryBuilder: SearchLibrariesQueryBuilderService,
- private readonly route: ActivatedRoute,
- private readonly appHookService: AppHookService
- ) {
+ constructor() {
super();
+ const librariesQueryBuilder = this.librariesQueryBuilder;
librariesQueryBuilder.paging = {
skipCount: 0,
diff --git a/projects/aca-content/src/lib/components/search/search-navigation.service.ts b/projects/aca-content/src/lib/components/search/search-navigation.service.ts
index a4c816af1..4cea1a5c8 100644
--- a/projects/aca-content/src/lib/components/search/search-navigation.service.ts
+++ b/projects/aca-content/src/lib/components/search/search-navigation.service.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { Injectable } from '@angular/core';
+import { Injectable, inject } from '@angular/core';
import { PRIMARY_OUTLET, Router, UrlSegment, UrlSegmentGroup, UrlTree } from '@angular/router';
import { extractSearchedWordFromEncodedQuery } from '../../utils/aca-search-utils';
@@ -30,6 +30,8 @@ import { extractSearchedWordFromEncodedQuery } from '../../utils/aca-search-util
providedIn: 'root'
})
export class SearchNavigationService {
+ private readonly router = inject(Router);
+
private _previousRoute = '';
get previousRoute(): string {
@@ -44,8 +46,6 @@ export class SearchNavigationService {
return !this.onLibrariesSearchResults && this.router?.url.indexOf('/search') === 0;
}
- constructor(private router: Router) {}
-
saveRoute(route: string): void {
this._previousRoute = route;
}
diff --git a/projects/aca-content/src/lib/components/search/search-results-row/search-results-row.component.ts b/projects/aca-content/src/lib/components/search/search-results-row/search-results-row.component.ts
index 25857e794..6da4fbda3 100644
--- a/projects/aca-content/src/lib/components/search/search-results-row/search-results-row.component.ts
+++ b/projects/aca-content/src/lib/components/search/search-results-row/search-results-row.component.ts
@@ -46,7 +46,12 @@ import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
host: { class: 'aca-search-results-row' }
})
export class SearchResultsRowComponent implements OnInit {
- private settings = inject(AppSettingsService);
+ private readonly store = inject>(Store);
+ private readonly nodesApiService = inject(NodesApiService);
+ private readonly router = inject(Router);
+ private readonly autoDownloadService = inject(AutoDownloadService);
+
+ private readonly settings = inject(AppSettingsService);
private readonly highlightPrefix = ``;
private readonly highlightPostfix = ``;
@@ -80,13 +85,6 @@ export class SearchResultsRowComponent implements OnInit {
private readonly destroyRef = inject(DestroyRef);
- constructor(
- private store: Store,
- private nodesApiService: NodesApiService,
- private router: Router,
- private autoDownloadService: AutoDownloadService
- ) {}
-
ngOnInit() {
this.updateValues();
diff --git a/projects/aca-content/src/lib/components/search/search-results/search-results.component.ts b/projects/aca-content/src/lib/components/search/search-results/search-results.component.ts
index 75238f076..3304e9d87 100644
--- a/projects/aca-content/src/lib/components/search/search-results/search-results.component.ts
+++ b/projects/aca-content/src/lib/components/search/search-results/search-results.component.ts
@@ -132,7 +132,13 @@ import { SavedSearchesContextService } from '../../../services/saved-searches-co
styleUrls: ['./search-results.component.scss']
})
export class SearchResultsComponent extends PageComponent implements OnInit, OnDestroy {
- private notificationService = inject(NotificationService);
+ private readonly queryBuilder = inject(SearchQueryBuilderService);
+ private readonly changeDetectorRef = inject(ChangeDetectorRef);
+ private readonly route = inject(ActivatedRoute);
+ private readonly translationService = inject(TranslationService);
+ private readonly savedSearchesService = inject(SavedSearchesContextService);
+
+ private readonly notificationService = inject(NotificationService);
infoDrawerPreview$ = this.store.select(infoDrawerPreview);
@@ -156,15 +162,11 @@ export class SearchResultsComponent extends PageComponent implements OnInit, OnD
this.isSmallScreen = window.innerWidth < 320;
};
- constructor(
- tagsService: TagService,
- private readonly queryBuilder: SearchQueryBuilderService,
- private readonly changeDetectorRef: ChangeDetectorRef,
- private readonly route: ActivatedRoute,
- private readonly translationService: TranslationService,
- private readonly savedSearchesService: SavedSearchesContextService
- ) {
+ constructor() {
+ const tagsService = inject(TagService);
+
super();
+ const queryBuilder = this.queryBuilder;
this.isTagsEnabled = tagsService.areTagsEnabled();
diff --git a/projects/aca-content/src/lib/components/search/search-save/dialog/delete/saved-search-delete-dialog.component.ts b/projects/aca-content/src/lib/components/search/search-save/dialog/delete/saved-search-delete-dialog.component.ts
index 8a146f294..18921b3fc 100644
--- a/projects/aca-content/src/lib/components/search/search-save/dialog/delete/saved-search-delete-dialog.component.ts
+++ b/projects/aca-content/src/lib/components/search/search-save/dialog/delete/saved-search-delete-dialog.component.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { Component, Inject, ViewEncapsulation } from '@angular/core';
+import { Component, ViewEncapsulation, inject } from '@angular/core';
import { AutoFocusDirective, SavedSearch } from '@alfresco/adf-content-services';
import { MAT_DIALOG_DATA, MatDialogModule, MatDialogRef } from '@angular/material/dialog';
import { take } from 'rxjs/operators';
@@ -42,14 +42,12 @@ import { SavedSearchesContextService } from '../../../../../services/saved-searc
host: { class: 'aca-saved-search-delete-dialog' }
})
export class SavedSearchDeleteDialogComponent {
- isLoading = false;
+ private readonly dialog = inject>(MatDialogRef);
+ private readonly notificationService = inject(NotificationService);
+ private readonly savedSearchesService = inject(SavedSearchesContextService);
+ private readonly data = inject(MAT_DIALOG_DATA);
- constructor(
- private readonly dialog: MatDialogRef,
- private readonly notificationService: NotificationService,
- private readonly savedSearchesService: SavedSearchesContextService,
- @Inject(MAT_DIALOG_DATA) private readonly data: SavedSearch
- ) {}
+ isLoading = false;
onSubmit() {
if (this.isLoading) {
diff --git a/projects/aca-content/src/lib/components/search/search-save/dialog/edit/saved-search-edit-dialog.component.ts b/projects/aca-content/src/lib/components/search/search-save/dialog/edit/saved-search-edit-dialog.component.ts
index eb6f35635..78a990280 100644
--- a/projects/aca-content/src/lib/components/search/search-save/dialog/edit/saved-search-edit-dialog.component.ts
+++ b/projects/aca-content/src/lib/components/search/search-save/dialog/edit/saved-search-edit-dialog.component.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { Component, Inject, ViewEncapsulation } from '@angular/core';
+import { Component, ViewEncapsulation, inject } from '@angular/core';
import { AutoFocusDirective, forbidOnlySpaces, SavedSearch } from '@alfresco/adf-content-services';
import { MAT_DIALOG_DATA, MatDialogModule, MatDialogRef } from '@angular/material/dialog';
import { take } from 'rxjs/operators';
@@ -57,16 +57,16 @@ import { SavedSearchesContextService } from '../../../../../services/saved-searc
host: { class: 'aca-saved-search-edit-dialog' }
})
export class SavedSearchEditDialogComponent {
+ private readonly dialog = inject>(MatDialogRef);
+ private readonly notificationService = inject(NotificationService);
+ private readonly savedSearchesService = inject(SavedSearchesContextService);
+ private readonly uniqueSearchNameValidator = inject(UniqueSearchNameValidator);
+ private readonly data = inject(MAT_DIALOG_DATA);
+
form: FormGroup;
isLoading = false;
- constructor(
- private readonly dialog: MatDialogRef,
- private readonly notificationService: NotificationService,
- private readonly savedSearchesService: SavedSearchesContextService,
- private readonly uniqueSearchNameValidator: UniqueSearchNameValidator,
- @Inject(MAT_DIALOG_DATA) private readonly data: SavedSearch
- ) {
+ constructor() {
this.form = new FormGroup({
name: new FormControl('', {
validators: [Validators.required, forbidOnlySpaces],
diff --git a/projects/aca-content/src/lib/components/search/search-save/dialog/save-search-dialog.component.ts b/projects/aca-content/src/lib/components/search/search-save/dialog/save-search-dialog.component.ts
index f310a0682..a91107d5d 100644
--- a/projects/aca-content/src/lib/components/search/search-save/dialog/save-search-dialog.component.ts
+++ b/projects/aca-content/src/lib/components/search/search-save/dialog/save-search-dialog.component.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { Component, Inject, ViewEncapsulation } from '@angular/core';
+import { Component, ViewEncapsulation, inject } from '@angular/core';
import { MatMenuModule } from '@angular/material/menu';
import { CommonModule } from '@angular/common';
import { TranslatePipe } from '@ngx-translate/core';
@@ -63,16 +63,18 @@ import { SavedSearchesContextService } from '../../../../services/saved-searches
host: { class: 'aca-save-search-dialog' }
})
export class SaveSearchDialogComponent {
+ private readonly dialog = inject>(MatDialogRef);
+ private readonly notificationService = inject(NotificationService);
+ private readonly savedSearchesService = inject(SavedSearchesContextService);
+ private readonly uniqueSearchNameValidator = inject(UniqueSearchNameValidator);
+ private readonly data = inject<{
+ searchUrl: string;
+ }>(MAT_DIALOG_DATA);
+
form: FormGroup;
disableSubmitButton = false;
- constructor(
- private readonly dialog: MatDialogRef,
- private readonly notificationService: NotificationService,
- private readonly savedSearchesService: SavedSearchesContextService,
- private readonly uniqueSearchNameValidator: UniqueSearchNameValidator,
- @Inject(MAT_DIALOG_DATA) private readonly data: { searchUrl: string }
- ) {
+ constructor() {
this.form = new FormGroup({
name: new FormControl('', {
validators: [Validators.required, forbidOnlySpaces],
diff --git a/projects/aca-content/src/lib/components/search/search-save/dialog/unique-search-name-validator.ts b/projects/aca-content/src/lib/components/search/search-save/dialog/unique-search-name-validator.ts
index da41588a7..55bc95e47 100644
--- a/projects/aca-content/src/lib/components/search/search-save/dialog/unique-search-name-validator.ts
+++ b/projects/aca-content/src/lib/components/search/search-save/dialog/unique-search-name-validator.ts
@@ -22,14 +22,14 @@
* from Hyland Software. If not, see .
*/
-import { Injectable } from '@angular/core';
+import { Injectable, inject } from '@angular/core';
import { AbstractControl, AsyncValidator, ValidationErrors } from '@angular/forms';
import { catchError, map, Observable, of } from 'rxjs';
import { SavedSearchesContextService } from '../../../../services/saved-searches-context.service';
@Injectable({ providedIn: 'root' })
export class UniqueSearchNameValidator implements AsyncValidator {
- constructor(private readonly savedSearchesService: SavedSearchesContextService) {}
+ private readonly savedSearchesService = inject(SavedSearchesContextService);
validate(control: AbstractControl): Observable {
return this.savedSearchesService.getSavedSearches().pipe(
diff --git a/projects/aca-content/src/lib/components/search/search-save/directive/save-search.directive.ts b/projects/aca-content/src/lib/components/search/search-save/directive/save-search.directive.ts
index 004506bbc..f57e716a8 100644
--- a/projects/aca-content/src/lib/components/search/search-save/directive/save-search.directive.ts
+++ b/projects/aca-content/src/lib/components/search/search-save/directive/save-search.directive.ts
@@ -34,6 +34,8 @@ import { SaveSearchDirectiveDialogData } from '../dialog/save-search-directive-d
standalone: true
})
export class SaveSearchDirective {
+ private readonly overlayContainer = inject(OverlayContainer);
+
/** Encoded search query */
@Input()
acaSaveSearchQuery: string;
@@ -46,8 +48,6 @@ export class SaveSearchDirective {
private readonly dialogRef = inject(MatDialog);
private readonly elementRef = inject(ElementRef);
- constructor(private readonly overlayContainer: OverlayContainer) {}
-
@HostListener('click', ['$event'])
onClick(event: MouseEvent) {
event.preventDefault();
diff --git a/projects/aca-content/src/lib/components/shared-files/shared-files.component.ts b/projects/aca-content/src/lib/components/shared-files/shared-files.component.ts
index e53c2e351..7071ed59b 100644
--- a/projects/aca-content/src/lib/components/shared-files/shared-files.component.ts
+++ b/projects/aca-content/src/lib/components/shared-files/shared-files.component.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { Component, OnInit, ViewEncapsulation } from '@angular/core';
+import { Component, OnInit, ViewEncapsulation, inject } from '@angular/core';
import { debounceTime } from 'rxjs/operators';
import { NodeEntry } from '@alfresco/js-api';
import {
@@ -72,11 +72,9 @@ import { DocumentListComponent } from '@alfresco/adf-content-services';
selector: 'aca-shared-files'
})
export class SharedFilesComponent extends PageComponent implements OnInit {
- columns: DocumentListPresetRef[] = [];
+ private readonly appHookService = inject(AppHookService);
- constructor(private appHookService: AppHookService) {
- super();
- }
+ columns: DocumentListPresetRef[] = [];
ngOnInit() {
super.ngOnInit();
diff --git a/projects/aca-content/src/lib/components/shared-link-view/shared-link-view.component.ts b/projects/aca-content/src/lib/components/shared-link-view/shared-link-view.component.ts
index 96e351a1c..49ac2b2dc 100644
--- a/projects/aca-content/src/lib/components/shared-link-view/shared-link-view.component.ts
+++ b/projects/aca-content/src/lib/components/shared-link-view/shared-link-view.component.ts
@@ -45,22 +45,20 @@ import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
host: { class: 'app-shared-link-view' }
})
export class SharedLinkViewComponent implements OnInit {
+ private readonly route = inject(ActivatedRoute);
+ private readonly store = inject>(Store);
+ private readonly extensions = inject(AppExtensionService);
+ private readonly alfrescoApiService = inject(AlfrescoApiService);
+ private readonly appService = inject(AppService);
+
sharedLinkId: string = null;
viewerToolbarActions: Array = [];
@LazyApi((self: SharedLinkViewComponent) => new SharedlinksApi(self.alfrescoApiService.getInstance()))
- declare private sharedLinksApi: SharedlinksApi;
+ declare private readonly sharedLinksApi: SharedlinksApi;
private readonly destroyRef = inject(DestroyRef);
- constructor(
- private route: ActivatedRoute,
- private store: Store,
- private extensions: AppExtensionService,
- private alfrescoApiService: AlfrescoApiService,
- private appService: AppService
- ) {}
-
ngOnInit() {
this.route.params
.pipe(
diff --git a/projects/aca-content/src/lib/components/sidenav/components/button-menu.component.ts b/projects/aca-content/src/lib/components/sidenav/components/button-menu.component.ts
index deada691a..d7384e6ce 100644
--- a/projects/aca-content/src/lib/components/sidenav/components/button-menu.component.ts
+++ b/projects/aca-content/src/lib/components/sidenav/components/button-menu.component.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { ChangeDetectorRef, Component, Input, OnInit, ViewEncapsulation } from '@angular/core';
+import { ChangeDetectorRef, Component, Input, OnInit, ViewEncapsulation, inject } from '@angular/core';
import { OverlayContainer } from '@angular/cdk/overlay';
import { NavBarLinkRef } from '@alfresco/adf-extensions';
import { CommonModule } from '@angular/common';
@@ -42,13 +42,13 @@ import { MenuPanelDirective } from '../directives/menu-panel.directive';
encapsulation: ViewEncapsulation.None
})
export class ButtonMenuComponent implements OnInit {
+ private readonly cd = inject(ChangeDetectorRef);
+ private readonly overlayContainer = inject(OverlayContainer);
+
@Input({ required: true })
item: NavBarLinkRef;
- constructor(
- private readonly cd: ChangeDetectorRef,
- private readonly overlayContainer: OverlayContainer
- ) {
+ constructor() {
this.overlayContainer.getContainerElement().classList.add('aca-menu-panel');
}
diff --git a/projects/aca-content/src/lib/components/sidenav/components/expand-menu.component.ts b/projects/aca-content/src/lib/components/sidenav/components/expand-menu.component.ts
index 46a90ef34..ce5e4e68a 100644
--- a/projects/aca-content/src/lib/components/sidenav/components/expand-menu.component.ts
+++ b/projects/aca-content/src/lib/components/sidenav/components/expand-menu.component.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { ChangeDetectorRef, Component, EventEmitter, Input, OnInit, Output, ViewEncapsulation } from '@angular/core';
+import { ChangeDetectorRef, Component, EventEmitter, Input, OnInit, Output, ViewEncapsulation, inject } from '@angular/core';
import { NavBarLinkRef } from '@alfresco/adf-extensions';
import { CommonModule } from '@angular/common';
import { TranslatePipe } from '@ngx-translate/core';
@@ -40,14 +40,14 @@ import { MatExpansionModule } from '@angular/material/expansion';
host: { class: 'app-expand-menu' }
})
export class ExpandMenuComponent implements OnInit {
+ private readonly cd = inject(ChangeDetectorRef);
+
@Input({ required: true })
item: NavBarLinkRef;
@Output()
actionClicked = new EventEmitter();
- constructor(private cd: ChangeDetectorRef) {}
-
ngOnInit() {
this.cd.detectChanges();
}
diff --git a/projects/aca-content/src/lib/components/sidenav/components/sidenav-header.component.ts b/projects/aca-content/src/lib/components/sidenav/components/sidenav-header.component.ts
index 251b5ed5c..a34d3bc09 100644
--- a/projects/aca-content/src/lib/components/sidenav/components/sidenav-header.component.ts
+++ b/projects/aca-content/src/lib/components/sidenav/components/sidenav-header.component.ts
@@ -38,8 +38,8 @@ import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
host: { class: 'app-sidenav-header' }
})
export class SidenavHeaderComponent implements OnInit {
- private appSettings = inject(AppSettingsService);
- private appExtensions = inject(AppExtensionService);
+ private readonly appSettings = inject(AppSettingsService);
+ private readonly appExtensions = inject(AppExtensionService);
private readonly destroyRef = inject(DestroyRef);
diff --git a/projects/aca-content/src/lib/components/sidenav/directives/action.directive.spec.ts b/projects/aca-content/src/lib/components/sidenav/directives/action.directive.spec.ts
index 06939b158..7b9322c56 100644
--- a/projects/aca-content/src/lib/components/sidenav/directives/action.directive.spec.ts
+++ b/projects/aca-content/src/lib/components/sidenav/directives/action.directive.spec.ts
@@ -37,12 +37,12 @@ describe('ActionDirective', () => {
beforeEach(() => {
TestBed.configureTestingModule({
imports: [ActionDirective],
- providers: [provideRouter([]), provideMockStore()]
+ providers: [ActionDirective, provideRouter([]), provideMockStore()]
});
store = TestBed.inject(Store);
router = TestBed.inject(Router);
- directive = new ActionDirective(router, store);
+ directive = TestBed.inject(ActionDirective);
});
it('should navigate if action is route', () => {
diff --git a/projects/aca-content/src/lib/components/sidenav/directives/action.directive.ts b/projects/aca-content/src/lib/components/sidenav/directives/action.directive.ts
index 9b3616791..457c8432d 100644
--- a/projects/aca-content/src/lib/components/sidenav/directives/action.directive.ts
+++ b/projects/aca-content/src/lib/components/sidenav/directives/action.directive.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { Directive, EventEmitter, HostListener, Input, Output } from '@angular/core';
+import { Directive, EventEmitter, HostListener, Input, Output, inject } from '@angular/core';
import { Params, PRIMARY_OUTLET, Router } from '@angular/router';
import { Store } from '@ngrx/store';
import { AppStore } from '@alfresco/aca-shared/store';
@@ -35,6 +35,9 @@ import { NavBarLinkRef } from '@alfresco/adf-extensions';
exportAs: 'action'
})
export class ActionDirective {
+ private readonly router = inject(Router);
+ private readonly store = inject>(Store);
+
@Input() action;
@Output() actionClicked = new EventEmitter();
@@ -51,11 +54,6 @@ export class ActionDirective {
}
this.actionClicked.next(this.action);
}
-
- constructor(
- private router: Router,
- private store: Store
- ) {}
private getNavigationCommands(url: string): any[] {
const urlTree = this.router.parseUrl(url);
const urlSegmentGroup = urlTree.root.children[PRIMARY_OUTLET];
diff --git a/projects/aca-content/src/lib/components/sidenav/directives/active-link.directive.spec.ts b/projects/aca-content/src/lib/components/sidenav/directives/active-link.directive.spec.ts
index e51a2aac3..009ffaf4d 100644
--- a/projects/aca-content/src/lib/components/sidenav/directives/active-link.directive.spec.ts
+++ b/projects/aca-content/src/lib/components/sidenav/directives/active-link.directive.spec.ts
@@ -42,7 +42,7 @@ class TestComponent {
}
class MockRouter {
- private subject = new Subject();
+ private readonly subject = new Subject();
events = this.subject.asObservable();
url = '';
diff --git a/projects/aca-content/src/lib/components/sidenav/directives/active-link.directive.ts b/projects/aca-content/src/lib/components/sidenav/directives/active-link.directive.ts
index da7f675c9..a83c43fab 100644
--- a/projects/aca-content/src/lib/components/sidenav/directives/active-link.directive.ts
+++ b/projects/aca-content/src/lib/components/sidenav/directives/active-link.directive.ts
@@ -22,19 +22,7 @@
* from Hyland Software. If not, see .
*/
-import {
- AfterContentInit,
- ContentChildren,
- DestroyRef,
- Directive,
- ElementRef,
- inject,
- Input,
- OnInit,
- Optional,
- QueryList,
- Renderer2
-} from '@angular/core';
+import { AfterContentInit, ContentChildren, DestroyRef, Directive, ElementRef, inject, Input, OnInit, QueryList, Renderer2 } from '@angular/core';
import { NavigationEnd, Router } from '@angular/router';
import { filter } from 'rxjs/operators';
import { ActionDirective } from './action.directive';
@@ -46,6 +34,11 @@ import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
exportAs: 'acaActiveLink'
})
export class ActiveLinkDirective implements OnInit, AfterContentInit {
+ private readonly router = inject(Router);
+ private readonly element = inject(ElementRef);
+ private readonly renderer = inject(Renderer2);
+ private readonly action = inject(ActionDirective, { optional: true });
+
@Input() acaActiveLink;
@ContentChildren(ActionDirective, { descendants: true })
links: QueryList;
@@ -53,13 +46,6 @@ export class ActiveLinkDirective implements OnInit, AfterContentInit {
private readonly destroyRef = inject(DestroyRef);
- constructor(
- private router: Router,
- private element: ElementRef,
- private renderer: Renderer2,
- @Optional() private action?: ActionDirective
- ) {}
-
ngOnInit() {
this.router.events
.pipe(
diff --git a/projects/aca-content/src/lib/components/sidenav/directives/expansion-panel.directive.spec.ts b/projects/aca-content/src/lib/components/sidenav/directives/expansion-panel.directive.spec.ts
index ffaaeb819..3aa320de3 100644
--- a/projects/aca-content/src/lib/components/sidenav/directives/expansion-panel.directive.spec.ts
+++ b/projects/aca-content/src/lib/components/sidenav/directives/expansion-panel.directive.spec.ts
@@ -22,14 +22,16 @@
* from Hyland Software. If not, see .
*/
-import { NavigationEnd } from '@angular/router';
+import { NavigationEnd, Router } from '@angular/router';
import { ExpansionPanelDirective } from './expansion-panel.directive';
import { Subject } from 'rxjs';
import { TestBed } from '@angular/core/testing';
+import { Store } from '@ngrx/store';
+import { MatExpansionPanel } from '@angular/material/expansion';
class RouterStub {
url;
- private subject = new Subject();
+ private readonly subject = new Subject();
events = this.subject.asObservable();
constructor(url = 'some-url') {
@@ -59,16 +61,31 @@ describe('AcaExpansionPanel', () => {
children: []
};
+ beforeEach(() => {
+ TestBed.configureTestingModule({
+ imports: [ExpansionPanelDirective],
+ providers: [
+ ExpansionPanelDirective,
+ {
+ provide: Store,
+ useValue: mockStore
+ },
+ {
+ provide: MatExpansionPanel,
+ useValue: mockMatExpansionPanel
+ }
+ ]
+ });
+ });
+
describe('hasActiveLinks()', () => {
it('should return true if child is active route', () => {
const router: any = new RouterStub('dummy-route-2');
const item = {
children: [{ url: 'dummy-route-1' }, { url: 'dummy-route-2' }]
};
- let directive: ExpansionPanelDirective;
- TestBed.runInInjectionContext(() => {
- directive = new ExpansionPanelDirective(mockStore, router, mockMatExpansionPanel);
- });
+ TestBed.overrideProvider(Router, { useValue: router });
+ const directive = TestBed.inject(ExpansionPanelDirective);
directive.acaExpansionPanel = item;
@@ -79,10 +96,8 @@ describe('AcaExpansionPanel', () => {
const item = {
children: [{ url: 'dummy-route-1' }, { url: 'dummy-route-2' }]
};
- let directive: ExpansionPanelDirective;
- TestBed.runInInjectionContext(() => {
- directive = new ExpansionPanelDirective(mockStore, router, mockMatExpansionPanel);
- });
+ TestBed.overrideProvider(Router, { useValue: router });
+ const directive = TestBed.inject(ExpansionPanelDirective);
directive.acaExpansionPanel = item;
@@ -100,10 +115,8 @@ describe('AcaExpansionPanel', () => {
mockMatExpansionPanel.expanded = true;
- let directive: ExpansionPanelDirective;
- TestBed.runInInjectionContext(() => {
- directive = new ExpansionPanelDirective(mockStore, router, mockMatExpansionPanel);
- });
+ TestBed.overrideProvider(Router, { useValue: router });
+ const directive = TestBed.inject(ExpansionPanelDirective);
directive.acaExpansionPanel = item;
@@ -119,10 +132,8 @@ describe('AcaExpansionPanel', () => {
children: [{ url: 'dummy-route-1' }, { url: 'dummy-route-2' }]
};
- let directive: ExpansionPanelDirective;
- TestBed.runInInjectionContext(() => {
- directive = new ExpansionPanelDirective(mockStore, router, mockMatExpansionPanel);
- });
+ TestBed.overrideProvider(Router, { useValue: router });
+ const directive = TestBed.inject(ExpansionPanelDirective);
directive.acaExpansionPanel = item;
mockMatExpansionPanel.expanded = true;
@@ -142,10 +153,8 @@ describe('AcaExpansionPanel', () => {
}
};
- let directive: ExpansionPanelDirective;
- TestBed.runInInjectionContext(() => {
- directive = new ExpansionPanelDirective(mockStore, router, mockMatExpansionPanel);
- });
+ TestBed.overrideProvider(Router, { useValue: router });
+ const directive = TestBed.inject(ExpansionPanelDirective);
directive.acaExpansionPanel = item;
mockMatExpansionPanel.expanded = true;
diff --git a/projects/aca-content/src/lib/components/sidenav/directives/expansion-panel.directive.ts b/projects/aca-content/src/lib/components/sidenav/directives/expansion-panel.directive.ts
index ab5539a82..3840c8d1f 100644
--- a/projects/aca-content/src/lib/components/sidenav/directives/expansion-panel.directive.ts
+++ b/projects/aca-content/src/lib/components/sidenav/directives/expansion-panel.directive.ts
@@ -35,6 +35,10 @@ import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
exportAs: 'acaExpansionPanel'
})
export class ExpansionPanelDirective implements OnInit {
+ private readonly store = inject>(Store);
+ private readonly router = inject(Router);
+ private readonly expansionPanel = inject(MatExpansionPanel);
+
@Input() acaExpansionPanel;
public hasActiveChildren = false;
@@ -55,12 +59,6 @@ export class ExpansionPanelDirective implements OnInit {
private readonly destroyRef = inject(DestroyRef);
- constructor(
- private store: Store,
- private router: Router,
- private expansionPanel: MatExpansionPanel
- ) {}
-
hasActiveLinks() {
if (this.acaExpansionPanel?.children) {
return this.acaExpansionPanel.children.some((child) => this.router.url.startsWith(child.url || child.action.payload));
diff --git a/projects/aca-content/src/lib/components/sidenav/directives/menu-panel.directive.spec.ts b/projects/aca-content/src/lib/components/sidenav/directives/menu-panel.directive.spec.ts
index 13da804b4..1b9ae55fa 100644
--- a/projects/aca-content/src/lib/components/sidenav/directives/menu-panel.directive.spec.ts
+++ b/projects/aca-content/src/lib/components/sidenav/directives/menu-panel.directive.spec.ts
@@ -22,14 +22,15 @@
* from Hyland Software. If not, see .
*/
-import { NavigationEnd } from '@angular/router';
+import { NavigationEnd, Router } from '@angular/router';
import { MenuPanelDirective } from './menu-panel.directive';
import { Subject } from 'rxjs';
import { TestBed } from '@angular/core/testing';
+import { Store } from '@ngrx/store';
class RouterStub {
url;
- private subject = new Subject();
+ private readonly subject = new Subject();
events = this.subject.asObservable();
constructor(url = 'some-url') {
@@ -59,16 +60,27 @@ describe('MenuPanelDirective', () => {
children: []
};
+ beforeEach(() => {
+ TestBed.configureTestingModule({
+ imports: [MenuPanelDirective],
+ providers: [
+ MenuPanelDirective,
+ {
+ provide: Store,
+ useValue: mockStore
+ }
+ ]
+ });
+ });
+
describe('hasActiveLinks()', () => {
it('should return true if child is active route', () => {
const router: any = new RouterStub('dummy-route-2');
const item = {
children: [{ url: 'dummy-route-1' }, { url: 'dummy-route-2' }]
};
- let directive: MenuPanelDirective;
- TestBed.runInInjectionContext(() => {
- directive = new MenuPanelDirective(mockStore, router);
- });
+ TestBed.overrideProvider(Router, { useValue: router });
+ const directive = TestBed.inject(MenuPanelDirective);
directive.acaMenuPanel = item;
@@ -79,10 +91,8 @@ describe('MenuPanelDirective', () => {
const item = {
children: [{ url: 'dummy-route-1' }, { url: 'dummy-route-2' }]
};
- let directive: MenuPanelDirective;
- TestBed.runInInjectionContext(() => {
- directive = new MenuPanelDirective(mockStore, router);
- });
+ TestBed.overrideProvider(Router, { useValue: router });
+ const directive = TestBed.inject(MenuPanelDirective);
directive.acaMenuPanel = item;
@@ -100,10 +110,8 @@ describe('MenuPanelDirective', () => {
mockMatExpansionPanel.expanded = true;
- let directive: MenuPanelDirective;
- TestBed.runInInjectionContext(() => {
- directive = new MenuPanelDirective(mockStore, router);
- });
+ TestBed.overrideProvider(Router, { useValue: router });
+ const directive = TestBed.inject(MenuPanelDirective);
directive.acaMenuPanel = item;
@@ -119,10 +127,8 @@ describe('MenuPanelDirective', () => {
children: [{ url: 'dummy-route-1' }, { url: 'dummy-route-2' }]
};
- let directive: MenuPanelDirective;
- TestBed.runInInjectionContext(() => {
- directive = new MenuPanelDirective(mockStore, router);
- });
+ TestBed.overrideProvider(Router, { useValue: router });
+ const directive = TestBed.inject(MenuPanelDirective);
directive.acaMenuPanel = item;
mockMatExpansionPanel.expanded = true;
diff --git a/projects/aca-content/src/lib/components/sidenav/directives/menu-panel.directive.ts b/projects/aca-content/src/lib/components/sidenav/directives/menu-panel.directive.ts
index bb56ab644..3ab77e967 100644
--- a/projects/aca-content/src/lib/components/sidenav/directives/menu-panel.directive.ts
+++ b/projects/aca-content/src/lib/components/sidenav/directives/menu-panel.directive.ts
@@ -34,6 +34,9 @@ import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
exportAs: 'acaMenuPanel'
})
export class MenuPanelDirective implements OnInit {
+ private readonly store = inject>(Store);
+ private readonly router = inject(Router);
+
@Input() acaMenuPanel;
hasActiveChildren = false;
@@ -54,11 +57,6 @@ export class MenuPanelDirective implements OnInit {
private readonly destroyRef = inject(DestroyRef);
- constructor(
- private store: Store,
- private router: Router
- ) {}
-
hasActiveLinks() {
if (this.acaMenuPanel?.children) {
return this.acaMenuPanel.children.some((child) => this.router.url.startsWith(child.url || child.action.payload));
diff --git a/projects/aca-content/src/lib/components/sidenav/sidenav.component.ts b/projects/aca-content/src/lib/components/sidenav/sidenav.component.ts
index f7f0506c8..bbb32ba7a 100755
--- a/projects/aca-content/src/lib/components/sidenav/sidenav.component.ts
+++ b/projects/aca-content/src/lib/components/sidenav/sidenav.component.ts
@@ -46,6 +46,11 @@ import { TranslatePipe } from '@ngx-translate/core';
host: { class: 'app-sidenav' }
})
export class SidenavComponent implements OnInit {
+ private readonly store = inject>(Store);
+ private readonly extensions = inject(AppExtensionService);
+ private readonly appService = inject(AppService);
+ private readonly navigationHistoryService = inject(NavigationHistoryService);
+
@Input()
data: {
layout?: SidenavLayoutComponent;
@@ -56,13 +61,6 @@ export class SidenavComponent implements OnInit {
private readonly destroyRef = inject(DestroyRef);
- constructor(
- private store: Store,
- private extensions: AppExtensionService,
- private appService: AppService,
- private navigationHistoryService: NavigationHistoryService
- ) {}
-
ngOnInit() {
this.store
.select(getSideNavState)
diff --git a/projects/aca-content/src/lib/components/sidenav/user-menu/user-menu.component.ts b/projects/aca-content/src/lib/components/sidenav/user-menu/user-menu.component.ts
index 97943c258..fff0f36c9 100644
--- a/projects/aca-content/src/lib/components/sidenav/user-menu/user-menu.component.ts
+++ b/projects/aca-content/src/lib/components/sidenav/user-menu/user-menu.component.ts
@@ -39,7 +39,7 @@ import { ToolbarMenuItemComponent, UserProfileService } from '@alfresco/aca-shar
host: { class: 'aca-user-menu' }
})
export class UserMenuComponent implements OnInit, AfterViewInit {
- private userProfileService = inject(UserProfileService);
+ private readonly userProfileService = inject(UserProfileService);
user$ = this.userProfileService.userProfile$;
diff --git a/projects/aca-content/src/lib/components/toolbar/toggle-edit-offline/toggle-edit-offline.component.ts b/projects/aca-content/src/lib/components/toolbar/toggle-edit-offline/toggle-edit-offline.component.ts
index bf0edf75d..8c3fc4597 100644
--- a/projects/aca-content/src/lib/components/toolbar/toggle-edit-offline/toggle-edit-offline.component.ts
+++ b/projects/aca-content/src/lib/components/toolbar/toggle-edit-offline/toggle-edit-offline.component.ts
@@ -47,24 +47,22 @@ import { MatIconModule } from '@angular/material/icon';
host: { class: 'app-toggle-edit-offline' }
})
export class ToggleEditOfflineComponent implements OnInit {
+ private readonly store = inject>(Store);
+ private readonly alfrescoApiService = inject(AlfrescoApiService);
+ private readonly extensions = inject(AppExtensionService);
+
@ViewChild(MatMenuItem)
menuItem: MatMenuItem;
- private notificationService = inject(NotificationService);
+ private readonly notificationService = inject(NotificationService);
@LazyApi((self: ToggleEditOfflineComponent) => new NodesApi(self.alfrescoApiService.getInstance()))
- declare private nodesApi: NodesApi;
+ declare private readonly nodesApi: NodesApi;
selection: NodeEntry;
nodeTitle = '';
isNodeLocked = false;
- constructor(
- private store: Store,
- private alfrescoApiService: AlfrescoApiService,
- private extensions: AppExtensionService
- ) {}
-
ngOnInit() {
this.store.select(getAppSelection).subscribe(({ file }) => {
this.selection = file;
diff --git a/projects/aca-content/src/lib/components/toolbar/toggle-favorite-library/toggle-favorite-library.component.ts b/projects/aca-content/src/lib/components/toolbar/toggle-favorite-library/toggle-favorite-library.component.ts
index d6c26873c..d2f69c5cb 100644
--- a/projects/aca-content/src/lib/components/toolbar/toggle-favorite-library/toggle-favorite-library.component.ts
+++ b/projects/aca-content/src/lib/components/toolbar/toggle-favorite-library/toggle-favorite-library.component.ts
@@ -54,6 +54,10 @@ import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
host: { class: 'app-toggle-favorite-library' }
})
export class ToggleFavoriteLibraryComponent implements OnInit {
+ private readonly store = inject>(Store);
+ private readonly appHookService = inject(AppHookService);
+ private readonly router = inject(Router);
+
library;
@Input() data: { focusAfterClosed?: string };
@@ -63,12 +67,6 @@ export class ToggleFavoriteLibraryComponent implements OnInit {
private readonly destroyRef = inject(DestroyRef);
- constructor(
- private store: Store,
- private appHookService: AppHookService,
- private router: Router
- ) {}
-
ngOnInit() {
const isFavoriteLibraries = this.router.url.startsWith('/favorite/libraries');
diff --git a/projects/aca-content/src/lib/components/toolbar/toggle-favorite/toggle-favorite.component.ts b/projects/aca-content/src/lib/components/toolbar/toggle-favorite/toggle-favorite.component.ts
index 3bdd2635b..addf409ea 100644
--- a/projects/aca-content/src/lib/components/toolbar/toggle-favorite/toggle-favorite.component.ts
+++ b/projects/aca-content/src/lib/components/toolbar/toggle-favorite/toggle-favorite.component.ts
@@ -47,7 +47,10 @@ import { MatMenuItem, MatMenuModule } from '@angular/material/menu';
host: { class: 'app-toggle-favorite' }
})
export class ToggleFavoriteComponent implements OnInit {
- private documentListService = inject(DocumentListService);
+ private readonly store = inject>(Store);
+ private readonly router = inject(Router);
+
+ private readonly documentListService = inject(DocumentListService);
@Input() data: any;
selection$: Observable;
@@ -56,10 +59,7 @@ export class ToggleFavoriteComponent implements OnInit {
@ViewChild(MatMenuItem)
menuItem: MatMenuItem;
- constructor(
- private store: Store,
- private router: Router
- ) {
+ constructor() {
this.selection$ = this.store.select(getAppSelection);
}
diff --git a/projects/aca-content/src/lib/components/toolbar/toggle-info-drawer/toggle-info-drawer.component.ts b/projects/aca-content/src/lib/components/toolbar/toggle-info-drawer/toggle-info-drawer.component.ts
index 084bbf80e..39fb22628 100644
--- a/projects/aca-content/src/lib/components/toolbar/toggle-info-drawer/toggle-info-drawer.component.ts
+++ b/projects/aca-content/src/lib/components/toolbar/toggle-info-drawer/toggle-info-drawer.component.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { Component, ViewEncapsulation } from '@angular/core';
+import { Component, ViewEncapsulation, inject } from '@angular/core';
import { Observable } from 'rxjs';
import { Store } from '@ngrx/store';
import { isInfoDrawerOpened, ToggleInfoDrawerAction } from '@alfresco/aca-shared/store';
@@ -60,9 +60,11 @@ import { MatIconModule } from '@angular/material/icon';
host: { class: 'app-toggle-info-drawer' }
})
export class ToggleInfoDrawerComponent {
+ private readonly store = inject>(Store);
+
infoDrawerOpened$: Observable;
- constructor(private store: Store) {
+ constructor() {
this.infoDrawerOpened$ = this.store.select(isInfoDrawerOpened);
}
diff --git a/projects/aca-content/src/lib/components/toolbar/toggle-join-library/toggle-join-library-button.component.ts b/projects/aca-content/src/lib/components/toolbar/toggle-join-library/toggle-join-library-button.component.ts
index 0ecfff65b..dfc896d6e 100644
--- a/projects/aca-content/src/lib/components/toolbar/toggle-join-library/toggle-join-library-button.component.ts
+++ b/projects/aca-content/src/lib/components/toolbar/toggle-join-library/toggle-join-library-button.component.ts
@@ -61,10 +61,10 @@ export class ToggleJoinLibraryButtonComponent {
@ViewChild(MatMenuItem)
menuItem: MatMenuItem;
- private userProfileService = inject(UserProfileService);
- private notificationService = inject(NotificationService);
- private appHookService = inject(AppHookService);
- private store = inject(Store);
+ private readonly userProfileService = inject(UserProfileService);
+ private readonly notificationService = inject(NotificationService);
+ private readonly appHookService = inject(AppHookService);
+ private readonly store = inject(Store);
selection$: Observable;
profile$ = this.userProfileService.userProfile$;
diff --git a/projects/aca-content/src/lib/components/toolbar/view-node/view-node.component.ts b/projects/aca-content/src/lib/components/toolbar/view-node/view-node.component.ts
index 7681220f6..89504c937 100644
--- a/projects/aca-content/src/lib/components/toolbar/view-node/view-node.component.ts
+++ b/projects/aca-content/src/lib/components/toolbar/view-node/view-node.component.ts
@@ -59,20 +59,18 @@ import { MatDialogModule } from '@angular/material/dialog';
host: { class: 'app-view-node' }
})
export class ViewNodeComponent {
- private settings = inject(AppSettingsService);
+ private readonly store = inject>(Store);
+ private readonly router = inject(Router);
+ private readonly autoDownloadService = inject(AutoDownloadService);
+ private readonly activatedRoute = inject(ActivatedRoute);
+
+ private readonly settings = inject(AppSettingsService);
@Input() data: { title?: string; menuButton?: boolean; iconButton?: boolean };
@ViewChild(MatMenuItem)
menuItem: MatMenuItem;
- constructor(
- private store: Store,
- private router: Router,
- private autoDownloadService: AutoDownloadService,
- private activatedRoute: ActivatedRoute
- ) {}
-
onClick() {
this.store
.select(getAppSelection)
diff --git a/projects/aca-content/src/lib/components/trashcan/trashcan.component.ts b/projects/aca-content/src/lib/components/trashcan/trashcan.component.ts
index 7501535a9..7498eac67 100644
--- a/projects/aca-content/src/lib/components/trashcan/trashcan.component.ts
+++ b/projects/aca-content/src/lib/components/trashcan/trashcan.component.ts
@@ -65,7 +65,7 @@ import { DocumentListComponent } from '@alfresco/adf-content-services';
encapsulation: ViewEncapsulation.None
})
export class TrashcanComponent extends PageComponent implements OnInit {
- private userProfileService = inject(UserProfileService);
+ private readonly userProfileService = inject(UserProfileService);
user$ = this.userProfileService.userProfile$;
columns: DocumentListPresetRef[] = [];
diff --git a/projects/aca-content/src/lib/components/upload-files-dialog/upload-files-dialog.component.ts b/projects/aca-content/src/lib/components/upload-files-dialog/upload-files-dialog.component.ts
index b1ff17e1d..05f3ade4e 100644
--- a/projects/aca-content/src/lib/components/upload-files-dialog/upload-files-dialog.component.ts
+++ b/projects/aca-content/src/lib/components/upload-files-dialog/upload-files-dialog.component.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { Component, ViewEncapsulation } from '@angular/core';
+import { Component, ViewEncapsulation, inject } from '@angular/core';
import { Observable } from 'rxjs';
import { delay } from 'rxjs/operators';
import { Store } from '@ngrx/store';
@@ -38,9 +38,11 @@ import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
encapsulation: ViewEncapsulation.None
})
export class UploadFilesDialogComponent {
+ private readonly store = inject>(Store);
+
showFileUploadingDialog$: Observable;
- constructor(private store: Store) {
+ constructor() {
this.showFileUploadingDialog$ = this.store.select(getFileUploadingDialog).pipe(delay(0), takeUntilDestroyed());
}
}
diff --git a/projects/aca-content/src/lib/components/view-profile/view-profile.component.ts b/projects/aca-content/src/lib/components/view-profile/view-profile.component.ts
index 468e8ef3a..e9f7cb624 100644
--- a/projects/aca-content/src/lib/components/view-profile/view-profile.component.ts
+++ b/projects/aca-content/src/lib/components/view-profile/view-profile.component.ts
@@ -24,7 +24,7 @@
import { AlfrescoApiService } from '@alfresco/adf-content-services';
import { PeopleApi, Person, LazyApi } from '@alfresco/js-api';
-import { Component, OnInit, ViewEncapsulation } from '@angular/core';
+import { Component, OnInit, ViewEncapsulation, inject } from '@angular/core';
import { FormControl, FormGroup, ReactiveFormsModule, Validators } from '@angular/forms';
import { Router } from '@angular/router';
import { Observable, take, throwError } from 'rxjs';
@@ -57,6 +57,11 @@ import { MatInputModule } from '@angular/material/input';
encapsulation: ViewEncapsulation.None
})
export class ViewProfileComponent implements OnInit {
+ private readonly router = inject(Router);
+ private readonly apiService = inject(AlfrescoApiService);
+ private readonly appService = inject(AppService);
+ private readonly extensionService = inject(AppExtensionService);
+
@LazyApi((self: ViewProfileComponent) => new PeopleApi(self.apiService.getInstance()))
declare peopleApi: PeopleApi;
profileForm = new FormGroup({
@@ -88,12 +93,9 @@ export class ViewProfileComponent implements OnInit {
return `APP.TOOLTIPS.${this.contactSectionExpanded ? 'COLLAPSE' : 'EXPAND'}_SECTION`;
}
- constructor(
- private router: Router,
- private readonly apiService: AlfrescoApiService,
- private readonly appService: AppService,
- private readonly extensionService: AppExtensionService
- ) {
+ constructor() {
+ const appService = this.appService;
+
this.appNavNarMode$ = appService.appNavNarMode$.pipe(takeUntilDestroyed());
}
diff --git a/projects/aca-content/src/lib/dialogs/node-template/create-from-template.dialog.ts b/projects/aca-content/src/lib/dialogs/node-template/create-from-template.dialog.ts
index aa1ee2357..1613ba513 100644
--- a/projects/aca-content/src/lib/dialogs/node-template/create-from-template.dialog.ts
+++ b/projects/aca-content/src/lib/dialogs/node-template/create-from-template.dialog.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { Component, ViewEncapsulation, Inject, OnInit } from '@angular/core';
+import { Component, ViewEncapsulation, OnInit, inject } from '@angular/core';
import { MatDialogRef, MAT_DIALOG_DATA, MatDialogModule } from '@angular/material/dialog';
import { Node } from '@alfresco/js-api';
import { UntypedFormBuilder, UntypedFormGroup, Validators, UntypedFormControl, ValidationErrors, ReactiveFormsModule } from '@angular/forms';
@@ -43,18 +43,16 @@ import { MatButtonModule } from '@angular/material/button';
encapsulation: ViewEncapsulation.None
})
export class CreateFromTemplateDialogComponent implements OnInit {
+ private readonly translationService = inject(TranslationService);
+ private readonly store = inject>(Store);
+ private readonly formBuilder = inject(UntypedFormBuilder);
+ private readonly dialogRef = inject>(MatDialogRef);
+ data = inject(MAT_DIALOG_DATA);
+
public form: UntypedFormGroup;
title = '';
- constructor(
- private translationService: TranslationService,
- private store: Store,
- private formBuilder: UntypedFormBuilder,
- private dialogRef: MatDialogRef,
- @Inject(MAT_DIALOG_DATA) public data: Node
- ) {}
-
ngOnInit() {
this.form = this.formBuilder.group({
name: [this.data.name, [Validators.required, this.forbidEndingDot, this.forbidOnlySpaces, this.forbidSpecialCharacters]],
diff --git a/projects/aca-content/src/lib/directives/document-list.directive.spec.ts b/projects/aca-content/src/lib/directives/document-list.directive.spec.ts
index eeb12ac66..b95dd257e 100644
--- a/projects/aca-content/src/lib/directives/document-list.directive.spec.ts
+++ b/projects/aca-content/src/lib/directives/document-list.directive.spec.ts
@@ -26,6 +26,10 @@ import { DocumentListDirective } from './document-list.directive';
import { Subject } from 'rxjs';
import { SetSelectedNodesAction } from '@alfresco/aca-shared/store';
import { TestBed } from '@angular/core/testing';
+import { Store } from '@ngrx/store';
+import { DocumentListComponent, DocumentListService } from '@alfresco/adf-content-services';
+import { UserPreferencesService } from '@alfresco/adf-core';
+import { ActivatedRoute, Router } from '@angular/router';
describe('DocumentListDirective', () => {
let documentListDirective: DocumentListDirective;
@@ -77,16 +81,37 @@ describe('DocumentListDirective', () => {
};
beforeEach(() => {
- TestBed.runInInjectionContext(() => {
- documentListDirective = new DocumentListDirective(
- storeMock,
- documentListMock,
- userPreferencesServiceMock,
- mockRoute,
- mockRouter,
- documentListServiceMock as any
- );
+ TestBed.configureTestingModule({
+ imports: [DocumentListDirective],
+ providers: [
+ DocumentListDirective,
+ {
+ provide: Store,
+ useValue: storeMock
+ },
+ {
+ provide: DocumentListComponent,
+ useValue: documentListMock
+ },
+ {
+ provide: UserPreferencesService,
+ useValue: userPreferencesServiceMock
+ },
+ {
+ provide: ActivatedRoute,
+ useValue: mockRoute
+ },
+ {
+ provide: Router,
+ useValue: mockRouter
+ },
+ {
+ provide: DocumentListService,
+ useValue: documentListServiceMock
+ }
+ ]
});
+ documentListDirective = TestBed.inject(DocumentListDirective);
});
afterEach(() => {
diff --git a/projects/aca-content/src/lib/directives/document-list.directive.ts b/projects/aca-content/src/lib/directives/document-list.directive.ts
index bb4aab843..f10932f86 100644
--- a/projects/aca-content/src/lib/directives/document-list.directive.ts
+++ b/projects/aca-content/src/lib/directives/document-list.directive.ts
@@ -37,6 +37,13 @@ import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
selector: '[acaDocumentList]'
})
export class DocumentListDirective implements OnInit {
+ private readonly store = inject>(Store);
+ private readonly documentList = inject(DocumentListComponent);
+ private readonly preferences = inject(UserPreferencesService);
+ private readonly route = inject(ActivatedRoute);
+ private readonly router = inject(Router);
+ private readonly documentListService = inject(DocumentListService);
+
private isLibrary = false;
selectedNode: NodeEntry;
@@ -46,15 +53,6 @@ export class DocumentListDirective implements OnInit {
private readonly destroyRef = inject(DestroyRef);
- constructor(
- private store: Store,
- private documentList: DocumentListComponent,
- private preferences: UserPreferencesService,
- private route: ActivatedRoute,
- private router: Router,
- private documentListService: DocumentListService
- ) {}
-
ngOnInit() {
this.documentList.stickyHeader = true;
this.documentList.includeFields = ['isFavorite', 'aspectNames', 'definition'];
diff --git a/projects/aca-content/src/lib/pipes/is-feature-supported.pipe.ts b/projects/aca-content/src/lib/pipes/is-feature-supported.pipe.ts
index 572c743be..d1bf332a7 100644
--- a/projects/aca-content/src/lib/pipes/is-feature-supported.pipe.ts
+++ b/projects/aca-content/src/lib/pipes/is-feature-supported.pipe.ts
@@ -23,7 +23,7 @@
*/
import { AppExtensionService } from '@alfresco/aca-shared';
-import { Pipe, PipeTransform } from '@angular/core';
+import { Pipe, PipeTransform, inject } from '@angular/core';
import { AppStore, getRepositoryStatus } from '@alfresco/aca-shared/store';
import { Store } from '@ngrx/store';
import { filter, map, Observable } from 'rxjs';
@@ -32,10 +32,8 @@ import { filter, map, Observable } from 'rxjs';
name: 'isFeatureSupportedInCurrentAcs'
})
export class IsFeatureSupportedInCurrentAcsPipe implements PipeTransform {
- constructor(
- private readonly appExtensionsService: AppExtensionService,
- private readonly store: Store
- ) {}
+ private readonly appExtensionsService = inject(AppExtensionService);
+ private readonly store = inject>(Store);
transform(evaluatorId: string): Observable {
return this.store.select(getRepositoryStatus).pipe(
diff --git a/projects/aca-content/src/lib/services/modal-ai.service.ts b/projects/aca-content/src/lib/services/modal-ai.service.ts
index ba4ebc273..84350a3c3 100644
--- a/projects/aca-content/src/lib/services/modal-ai.service.ts
+++ b/projects/aca-content/src/lib/services/modal-ai.service.ts
@@ -29,9 +29,9 @@ import { MatDialog } from '@angular/material/dialog';
@Injectable({ providedIn: 'root' })
export class ModalAiService {
- private route = inject(ActivatedRoute);
- private dialog = inject(MatDialog);
- private userPreferencesService = inject(UserPreferencesService);
+ private readonly route = inject(ActivatedRoute);
+ private readonly dialog = inject(MatDialog);
+ private readonly userPreferencesService = inject(UserPreferencesService);
openUnsavedChangesModal(callback: () => void): void {
const hasPreviousSearch = this.route.snapshot?.queryParams?.query?.length > 0;
diff --git a/projects/aca-content/src/lib/services/node-actions.service.ts b/projects/aca-content/src/lib/services/node-actions.service.ts
index 3c0a61653..f66b08b78 100644
--- a/projects/aca-content/src/lib/services/node-actions.service.ts
+++ b/projects/aca-content/src/lib/services/node-actions.service.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { Injectable } from '@angular/core';
+import { Injectable, inject } from '@angular/core';
import { MatDialog } from '@angular/material/dialog';
import { Observable, Subject, of, zip, from } from 'rxjs';
import { ThumbnailService, TranslationService } from '@alfresco/adf-core';
@@ -56,6 +56,14 @@ type BatchOperationType = Extract;
providedIn: 'root'
})
export class NodeActionsService {
+ private readonly contentService = inject(ContentService);
+ private readonly contentApi = inject(ContentApiService);
+ private readonly dialog = inject(MatDialog);
+ private readonly documentListService = inject(DocumentListService);
+ private readonly apiService = inject(AlfrescoApiService);
+ private readonly translation = inject(TranslationService);
+ private readonly thumbnailService = inject(ThumbnailService);
+
contentCopied: Subject = new Subject();
contentMoved: Subject = new Subject();
moveDeletedEntries: any[] = [];
@@ -64,16 +72,6 @@ export class NodeActionsService {
@LazyApi((self: NodeActionsService) => new NodesApi(self.apiService.getInstance()))
declare nodesApi: NodesApi;
- constructor(
- private contentService: ContentService,
- private contentApi: ContentApiService,
- private dialog: MatDialog,
- private documentListService: DocumentListService,
- private apiService: AlfrescoApiService,
- private translation: TranslationService,
- private thumbnailService: ThumbnailService
- ) {}
-
/**
* Copy node list
*
diff --git a/projects/aca-content/src/lib/services/node-template.service.ts b/projects/aca-content/src/lib/services/node-template.service.ts
index 4b07d1fc2..63f7752ad 100644
--- a/projects/aca-content/src/lib/services/node-template.service.ts
+++ b/projects/aca-content/src/lib/services/node-template.service.ts
@@ -46,10 +46,10 @@ export interface TemplateDialogConfig {
providedIn: 'root'
})
export class NodeTemplateService {
- private alfrescoApiService = inject(AlfrescoApiService);
- private notificationService = inject(NotificationService);
- private translation = inject(TranslationService);
- private dialog = inject(MatDialog);
+ private readonly alfrescoApiService = inject(AlfrescoApiService);
+ private readonly notificationService = inject(NotificationService);
+ private readonly translation = inject(TranslationService);
+ private readonly dialog = inject(MatDialog);
private currentTemplateConfig: TemplateDialogConfig = null;
private rootNode: ResultNode;
diff --git a/projects/aca-content/src/lib/services/saved-searches-context.service.ts b/projects/aca-content/src/lib/services/saved-searches-context.service.ts
index 7a4fc8cff..d31df5a99 100644
--- a/projects/aca-content/src/lib/services/saved-searches-context.service.ts
+++ b/projects/aca-content/src/lib/services/saved-searches-context.service.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { Injectable } from '@angular/core';
+import { Injectable, inject } from '@angular/core';
import { Observable, ReplaySubject, switchMap, take } from 'rxjs';
import { NodeEntry } from '@alfresco/js-api';
import { SavedSearch, SavedSearchesLegacyService, SavedSearchesService, SavedSearchStrategy } from '@alfresco/adf-content-services';
@@ -33,15 +33,16 @@ import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
providedIn: 'root'
})
export class SavedSearchesContextService implements SavedSearchStrategy {
+ private readonly legacyService = inject(SavedSearchesLegacyService);
+ private readonly modernService = inject(SavedSearchesService);
+
currentContextSavedSearch: SavedSearch;
private readonly strategy$ = new ReplaySubject(1);
- constructor(
- private readonly legacyService: SavedSearchesLegacyService,
- private readonly modernService: SavedSearchesService,
- isFeatureSupported: IsFeatureSupportedInCurrentAcsPipe
- ) {
+ constructor() {
+ const isFeatureSupported = inject(IsFeatureSupportedInCurrentAcsPipe);
+
isFeatureSupported
.transform('isPreferencesApiAvailable')
.pipe(takeUntilDestroyed())
diff --git a/projects/aca-content/src/lib/services/search-ai-navigation.service.ts b/projects/aca-content/src/lib/services/search-ai-navigation.service.ts
index ba4a86fd9..a4b2850b8 100644
--- a/projects/aca-content/src/lib/services/search-ai-navigation.service.ts
+++ b/projects/aca-content/src/lib/services/search-ai-navigation.service.ts
@@ -22,21 +22,19 @@
* from Hyland Software. If not, see .
*/
-import { Injectable } from '@angular/core';
+import { Injectable, inject } from '@angular/core';
import { Params, Router } from '@angular/router';
import { SearchAiService } from '@alfresco/adf-content-services';
@Injectable({ providedIn: 'root' })
export class SearchAiNavigationService {
+ private readonly router = inject(Router);
+ private readonly searchAiService = inject(SearchAiService);
+
private readonly knowledgeRetrievalRoute = '/knowledge-retrieval';
private previousRoute = '';
- constructor(
- private router: Router,
- private searchAiService: SearchAiService
- ) {}
-
navigateToPreviousRouteOrCloseInput(): void {
if (this.router.url.includes(this.knowledgeRetrievalRoute)) {
void this.router.navigateByUrl(this.previousRoute || '/personal-files');
diff --git a/projects/aca-content/src/lib/store/effects/download.effects.ts b/projects/aca-content/src/lib/store/effects/download.effects.ts
index 72559d584..b8cb99b26 100644
--- a/projects/aca-content/src/lib/store/effects/download.effects.ts
+++ b/projects/aca-content/src/lib/store/effects/download.effects.ts
@@ -35,11 +35,11 @@ import { ContentUrlService } from '../../services/content-url.service';
@Injectable()
export class DownloadEffects {
- private store = inject(Store);
- private actions$ = inject(Actions);
- private contentApi = inject(ContentApiService);
- private dialog = inject(MatDialog);
- private contentUrlService = inject(ContentUrlService);
+ private readonly store = inject(Store);
+ private readonly actions$ = inject(Actions);
+ private readonly contentApi = inject(ContentApiService);
+ private readonly dialog = inject(MatDialog);
+ private readonly contentUrlService = inject(ContentUrlService);
downloadNode$ = createEffect(
() =>
diff --git a/projects/aca-content/src/lib/store/effects/favorite.effects.ts b/projects/aca-content/src/lib/store/effects/favorite.effects.ts
index ee1db6791..5aef1c838 100644
--- a/projects/aca-content/src/lib/store/effects/favorite.effects.ts
+++ b/projects/aca-content/src/lib/store/effects/favorite.effects.ts
@@ -31,9 +31,9 @@ import { ContentManagementService } from '../../services/content-management.serv
@Injectable()
export class FavoriteEffects {
- private store = inject(Store);
- private actions$ = inject(Actions);
- private content = inject(ContentManagementService);
+ private readonly store = inject(Store);
+ private readonly actions$ = inject(Actions);
+ private readonly content = inject(ContentManagementService);
addFavorite$ = createEffect(
() =>
diff --git a/projects/aca-content/src/lib/store/effects/library.effects.ts b/projects/aca-content/src/lib/store/effects/library.effects.ts
index 845b10fb1..3dae0af28 100644
--- a/projects/aca-content/src/lib/store/effects/library.effects.ts
+++ b/projects/aca-content/src/lib/store/effects/library.effects.ts
@@ -45,11 +45,11 @@ import { HttpErrorResponse } from '@angular/common/http';
@Injectable()
export class LibraryEffects {
- private notificationService = inject(NotificationService);
- private store = inject(Store);
- private actions$ = inject(Actions);
- private content = inject(ContentManagementService);
- private contentApi = inject(ContentApiService);
+ private readonly notificationService = inject(NotificationService);
+ private readonly store = inject(Store);
+ private readonly actions$ = inject(Actions);
+ private readonly content = inject(ContentManagementService);
+ private readonly contentApi = inject(ContentApiService);
deleteLibrary$ = createEffect(
() =>
diff --git a/projects/aca-content/src/lib/store/effects/search-ai.effects.ts b/projects/aca-content/src/lib/store/effects/search-ai.effects.ts
index 13a3a79c3..ae564d2e4 100644
--- a/projects/aca-content/src/lib/store/effects/search-ai.effects.ts
+++ b/projects/aca-content/src/lib/store/effects/search-ai.effects.ts
@@ -32,9 +32,9 @@ import { Params } from '@angular/router';
@Injectable()
export class SearchAiEffects {
- private actions$ = inject(Actions);
- private searchNavigationService = inject(SearchAiNavigationService);
- private searchAiService = inject(SearchAiService);
+ private readonly actions$ = inject(Actions);
+ private readonly searchNavigationService = inject(SearchAiNavigationService);
+ private readonly searchAiService = inject(SearchAiService);
searchByTerm$ = createEffect(
() =>
this.actions$.pipe(
diff --git a/projects/aca-content/src/lib/store/effects/template.effects.ts b/projects/aca-content/src/lib/store/effects/template.effects.ts
index 791ab031b..126f58149 100644
--- a/projects/aca-content/src/lib/store/effects/template.effects.ts
+++ b/projects/aca-content/src/lib/store/effects/template.effects.ts
@@ -44,8 +44,8 @@ import { AlfrescoApiService, DocumentListService } from '@alfresco/adf-content-s
@Injectable()
export class TemplateEffects {
- private notificationService = inject(NotificationService);
- private documentListService = inject(DocumentListService);
+ private readonly notificationService = inject(NotificationService);
+ private readonly documentListService = inject(DocumentListService);
@LazyApi((self: TemplateEffects) => new NodesApi(self.apiService.getInstance()))
declare nodesApi: NodesApi;
diff --git a/projects/aca-content/src/lib/store/effects/upload.effects.ts b/projects/aca-content/src/lib/store/effects/upload.effects.ts
index d707ad1f0..aa5a9c666 100644
--- a/projects/aca-content/src/lib/store/effects/upload.effects.ts
+++ b/projects/aca-content/src/lib/store/effects/upload.effects.ts
@@ -43,7 +43,7 @@ import { FileModel, UploadService } from '@alfresco/adf-content-services';
@Injectable()
export class UploadEffects {
- private notificationService = inject(NotificationService);
+ private readonly notificationService = inject(NotificationService);
private readonly fileInput: HTMLInputElement;
private readonly folderInput: HTMLInputElement;
diff --git a/projects/aca-content/src/lib/store/effects/viewer.effects.ts b/projects/aca-content/src/lib/store/effects/viewer.effects.ts
index a1ccc6b74..472c58159 100644
--- a/projects/aca-content/src/lib/store/effects/viewer.effects.ts
+++ b/projects/aca-content/src/lib/store/effects/viewer.effects.ts
@@ -48,11 +48,11 @@ export const fileToPreview = createSelector(getAppSelection, getCurrentFolder, (
@Injectable()
export class ViewerEffects {
- private store = inject(Store);
- private actions$ = inject(Actions);
- private router = inject(Router);
- private extensions = inject(AppExtensionService);
- private dialog = inject(MatDialog);
+ private readonly store = inject(Store);
+ private readonly actions$ = inject(Actions);
+ private readonly router = inject(Router);
+ private readonly extensions = inject(AppExtensionService);
+ private readonly dialog = inject(MatDialog);
fullscreenViewer$ = createEffect(
() =>
diff --git a/projects/aca-content/viewer/src/lib/components/preview/preview.component.ts b/projects/aca-content/viewer/src/lib/components/preview/preview.component.ts
index af989796c..fd80bdf10 100644
--- a/projects/aca-content/viewer/src/lib/components/preview/preview.component.ts
+++ b/projects/aca-content/viewer/src/lib/components/preview/preview.component.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { Component, HostListener, OnInit, ViewEncapsulation } from '@angular/core';
+import { Component, HostListener, OnInit, ViewEncapsulation, inject } from '@angular/core';
import { CommonModule, Location } from '@angular/common';
import { ActivatedRoute, PRIMARY_OUTLET, UrlSegment, UrlSegmentGroup, UrlTree } from '@angular/router';
import { debounceTime, map } from 'rxjs/operators';
@@ -52,6 +52,14 @@ import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
host: { class: 'app-preview' }
})
export class PreviewComponent extends PageComponent implements OnInit {
+ private readonly actions$ = inject(Actions);
+ private readonly appHookService = inject(AppHookService);
+ private readonly contentApi = inject(ContentApiService);
+ private readonly location = inject(Location);
+ private readonly nodesApiService = inject(NodesApiService);
+ private readonly route = inject(ActivatedRoute);
+ private readonly viewerService = inject(ViewerService);
+
folderId: string = null;
navigateBackAsClose = false;
navigateMultiple = false;
@@ -66,19 +74,7 @@ export class PreviewComponent extends PageComponent implements OnInit {
showRightSide = false;
simplestMode = false;
- private containersSkipNavigation = ['adf-viewer__sidebar', 'cdk-overlay-container', 'adf-image-viewer'];
-
- constructor(
- private actions$: Actions,
- private appHookService: AppHookService,
- private contentApi: ContentApiService,
- private location: Location,
- private nodesApiService: NodesApiService,
- private route: ActivatedRoute,
- private viewerService: ViewerService
- ) {
- super();
- }
+ private readonly containersSkipNavigation = ['adf-viewer__sidebar', 'cdk-overlay-container', 'adf-image-viewer'];
ngOnInit() {
super.ngOnInit();
diff --git a/projects/aca-content/viewer/src/lib/components/viewer/viewer.component.ts b/projects/aca-content/viewer/src/lib/components/viewer/viewer.component.ts
index 214a6bcc6..9a73a39cd 100644
--- a/projects/aca-content/viewer/src/lib/components/viewer/viewer.component.ts
+++ b/projects/aca-content/viewer/src/lib/components/viewer/viewer.component.ts
@@ -74,9 +74,21 @@ import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
host: { class: 'app-viewer' }
})
export class AcaViewerComponent implements OnInit, OnDestroy {
+ private readonly actions$ = inject(Actions);
+ private readonly apiService = inject(AlfrescoApiService);
+ private readonly appHookService = inject(AppHookService);
+ private readonly contentApi = inject(ContentApiService);
+ private readonly extensions = inject(AppExtensionService);
+ private readonly nodesApiService = inject(NodesApiService);
+ private readonly route = inject(ActivatedRoute);
+ private readonly router = inject(Router);
+ private readonly store = inject>(Store);
+ private readonly uploadService = inject(UploadService);
+ private readonly viewerService = inject(ViewerService);
+
settings = inject(AppSettingsService);
- private documentListService = inject(DocumentListService);
+ private readonly documentListService = inject(DocumentListService);
@LazyApi((self: AcaViewerComponent) => new VersionsApi(self.apiService.getInstance()))
declare versionsApi: VersionsApi;
@@ -98,24 +110,10 @@ export class AcaViewerComponent implements OnInit, OnDestroy {
private navigationPath: string;
private previewLocation: string;
- private containersSkipNavigation = ['adf-viewer__sidebar', 'cdk-overlay-container', 'adf-image-viewer'];
+ private readonly containersSkipNavigation = ['adf-viewer__sidebar', 'cdk-overlay-container', 'adf-image-viewer'];
private readonly destroyRef = inject(DestroyRef);
- constructor(
- private actions$: Actions,
- private apiService: AlfrescoApiService,
- private appHookService: AppHookService,
- private contentApi: ContentApiService,
- private extensions: AppExtensionService,
- private nodesApiService: NodesApiService,
- private route: ActivatedRoute,
- private router: Router,
- private store: Store,
- private uploadService: UploadService,
- private viewerService: ViewerService
- ) {}
-
ngOnInit() {
this.infoDrawerOpened$ = this.store.select(isInfoDrawerOpened);
diff --git a/projects/aca-content/viewer/src/lib/services/viewer.service.ts b/projects/aca-content/viewer/src/lib/services/viewer.service.ts
index 030574238..e4c6495f9 100644
--- a/projects/aca-content/viewer/src/lib/services/viewer.service.ts
+++ b/projects/aca-content/viewer/src/lib/services/viewer.service.ts
@@ -24,7 +24,7 @@
import { ObjectUtils, UserPreferencesService } from '@alfresco/adf-core';
import { FavoritePaging, Node, NodePaging, SearchRequest, ResultSetPaging, SharedLink, SharedLinkPaging } from '@alfresco/js-api';
-import { Injectable } from '@angular/core';
+import { Injectable, inject } from '@angular/core';
import { ContentApiService } from '@alfresco/aca-shared';
interface AdjacentFiles {
@@ -36,17 +36,15 @@ interface AdjacentFiles {
providedIn: 'root'
})
export class ViewerService {
+ private readonly preferences = inject(UserPreferencesService);
+ private readonly contentApi = inject(ContentApiService);
+
private _customNodesOrder: string[] = [];
set customNodesOrder(customNodesOrder: string[]) {
this._customNodesOrder = customNodesOrder;
}
- constructor(
- private preferences: UserPreferencesService,
- private contentApi: ContentApiService
- ) {}
-
recentFileFilters = [
'TYPE:"content"',
'-PATH:"//cm:wiki/*"',
diff --git a/projects/aca-playwright-shared/src/api/categories-api.ts b/projects/aca-playwright-shared/src/api/categories-api.ts
index c744e5fb7..12a72996f 100644
--- a/projects/aca-playwright-shared/src/api/categories-api.ts
+++ b/projects/aca-playwright-shared/src/api/categories-api.ts
@@ -26,7 +26,7 @@ import { ApiClientFactory } from './api-client-factory';
import { CategoryEntry, CategoryBody, CategoryQuery, CategoryPaging, CategoryLinkBody } from '@alfresco/js-api';
export class CategoriesApi {
- private apiService: ApiClientFactory;
+ private readonly apiService: ApiClientFactory;
constructor() {
this.apiService = new ApiClientFactory();
diff --git a/projects/aca-playwright-shared/src/api/favorites-api.ts b/projects/aca-playwright-shared/src/api/favorites-api.ts
index 9127d4879..c15f8fea3 100755
--- a/projects/aca-playwright-shared/src/api/favorites-api.ts
+++ b/projects/aca-playwright-shared/src/api/favorites-api.ts
@@ -27,7 +27,7 @@ import { FavoriteEntry, FavoritePaging } from '@alfresco/js-api';
import { Utils } from '../utils';
export class FavoritesPageApi {
- private apiService: ApiClientFactory;
+ private readonly apiService: ApiClientFactory;
constructor() {
this.apiService = new ApiClientFactory();
diff --git a/projects/aca-playwright-shared/src/api/file-actions.ts b/projects/aca-playwright-shared/src/api/file-actions.ts
index c4d38e5a9..8ddd161f6 100644
--- a/projects/aca-playwright-shared/src/api/file-actions.ts
+++ b/projects/aca-playwright-shared/src/api/file-actions.ts
@@ -28,7 +28,7 @@ import { Utils, waitForApi } from '../utils';
import { NodeBodyCreate, NodeEntry, ResultSetPaging, SearchRequest } from '@alfresco/js-api';
export class FileActionsApi {
- private apiService: ApiClientFactory;
+ private readonly apiService: ApiClientFactory;
constructor() {
this.apiService = new ApiClientFactory();
diff --git a/projects/aca-playwright-shared/src/api/nodes-api.ts b/projects/aca-playwright-shared/src/api/nodes-api.ts
index 35bc37bc4..4563e0a29 100755
--- a/projects/aca-playwright-shared/src/api/nodes-api.ts
+++ b/projects/aca-playwright-shared/src/api/nodes-api.ts
@@ -27,7 +27,7 @@ import { NodeChildAssociationPaging, NodeEntry, NodePaging, NodesIncludeQuery, N
import { NodeContentTree, flattenNodeContentTree } from './node-content-tree';
export class NodesApi {
- private apiService: ApiClientFactory;
+ private readonly apiService: ApiClientFactory;
constructor() {
this.apiService = new ApiClientFactory();
diff --git a/projects/aca-playwright-shared/src/api/queries-api.ts b/projects/aca-playwright-shared/src/api/queries-api.ts
index 0e3fc6240..b61f1c4e9 100755
--- a/projects/aca-playwright-shared/src/api/queries-api.ts
+++ b/projects/aca-playwright-shared/src/api/queries-api.ts
@@ -27,7 +27,7 @@ import { Utils } from '../utils';
import { ApiClientFactory } from './api-client-factory';
export class QueriesApi {
- private apiService: ApiClientFactory;
+ private readonly apiService: ApiClientFactory;
constructor() {
this.apiService = new ApiClientFactory();
diff --git a/projects/aca-playwright-shared/src/api/rules-api.ts b/projects/aca-playwright-shared/src/api/rules-api.ts
index fc1d1eb04..02138c3e3 100644
--- a/projects/aca-playwright-shared/src/api/rules-api.ts
+++ b/projects/aca-playwright-shared/src/api/rules-api.ts
@@ -26,7 +26,7 @@ import { ApiClientFactory } from './api-client-factory';
import * as crypto from 'crypto';
export class RulesApi {
- private apiService: ApiClientFactory;
+ private readonly apiService: ApiClientFactory;
constructor() {
this.apiService = new ApiClientFactory();
diff --git a/projects/aca-playwright-shared/src/api/search-api.ts b/projects/aca-playwright-shared/src/api/search-api.ts
index b806a285b..70c9b1e77 100755
--- a/projects/aca-playwright-shared/src/api/search-api.ts
+++ b/projects/aca-playwright-shared/src/api/search-api.ts
@@ -27,7 +27,7 @@ import { Utils } from '../utils';
import { ResultSetPaging } from '@alfresco/js-api';
export class SearchPageApi {
- private apiService: ApiClientFactory;
+ private readonly apiService: ApiClientFactory;
constructor() {
this.apiService = new ApiClientFactory();
diff --git a/projects/aca-playwright-shared/src/api/shared-links-api.ts b/projects/aca-playwright-shared/src/api/shared-links-api.ts
index 0db5a7b36..8cea2ee22 100755
--- a/projects/aca-playwright-shared/src/api/shared-links-api.ts
+++ b/projects/aca-playwright-shared/src/api/shared-links-api.ts
@@ -27,7 +27,7 @@ import { SharedLinkEntry, SharedLinkPaging } from '@alfresco/js-api';
import { Utils } from '../utils';
export class SharedLinksApi {
- private apiService: ApiClientFactory;
+ private readonly apiService: ApiClientFactory;
constructor() {
this.apiService = new ApiClientFactory();
diff --git a/projects/aca-playwright-shared/src/api/sites-api.ts b/projects/aca-playwright-shared/src/api/sites-api.ts
index a46f16a80..677381834 100755
--- a/projects/aca-playwright-shared/src/api/sites-api.ts
+++ b/projects/aca-playwright-shared/src/api/sites-api.ts
@@ -35,7 +35,7 @@ import {
} from '@alfresco/js-api';
export class SitesApi {
- private apiService: ApiClientFactory;
+ private readonly apiService: ApiClientFactory;
constructor() {
this.apiService = new ApiClientFactory();
diff --git a/projects/aca-playwright-shared/src/api/tags-api.ts b/projects/aca-playwright-shared/src/api/tags-api.ts
index 5fa25ccc7..5d693b94d 100644
--- a/projects/aca-playwright-shared/src/api/tags-api.ts
+++ b/projects/aca-playwright-shared/src/api/tags-api.ts
@@ -26,7 +26,7 @@ import { TagBody, TagEntry, TagPaging } from '@alfresco/js-api';
import { ApiClientFactory } from './api-client-factory';
export class TagsApi {
- private apiService: ApiClientFactory;
+ private readonly apiService: ApiClientFactory;
constructor() {
this.apiService = new ApiClientFactory();
diff --git a/projects/aca-playwright-shared/src/api/trashcan-api.ts b/projects/aca-playwright-shared/src/api/trashcan-api.ts
index 0f2ecd49d..1bcd591c9 100644
--- a/projects/aca-playwright-shared/src/api/trashcan-api.ts
+++ b/projects/aca-playwright-shared/src/api/trashcan-api.ts
@@ -25,7 +25,7 @@
import { ApiClientFactory } from './api-client-factory';
export class TrashcanApi {
- private apiService = new ApiClientFactory();
+ private readonly apiService = new ApiClientFactory();
static async initialize(userName: string, password?: string): Promise {
const classObj = new TrashcanApi();
diff --git a/projects/aca-playwright-shared/src/page-objects/components/aca-header.component.ts b/projects/aca-playwright-shared/src/page-objects/components/aca-header.component.ts
index fccd4eb35..9654d5b3b 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/aca-header.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/aca-header.component.ts
@@ -27,9 +27,9 @@ import { MatMenuComponent } from './dataTable';
import { BaseComponent } from './base.component';
export class AcaHeader extends BaseComponent {
- private static rootElement = 'aca-toolbar';
- private moreActionsButton = this.getChild('button[id="app.viewer.toolbar.more"]');
- private toolbarMoreActions = this.getChild('button[id="app.toolbar.more"]');
+ private static readonly rootElement = 'aca-toolbar';
+ private readonly moreActionsButton = this.getChild('button[id="app.viewer.toolbar.more"]');
+ private readonly toolbarMoreActions = this.getChild('button[id="app.toolbar.more"]');
public createButton = this.getChild('[id="app.toolbar.create"]');
public viewDetails = this.getChild('[title="View Details"]');
public viewButton = this.getChild('button[title="View"]');
diff --git a/projects/aca-playwright-shared/src/page-objects/components/actions-dropdown.component.ts b/projects/aca-playwright-shared/src/page-objects/components/actions-dropdown.component.ts
index b6fe9289a..7ec21fb51 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/actions-dropdown.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/actions-dropdown.component.ts
@@ -60,19 +60,20 @@ export enum MimeType {
}
export class ActionsDropdownComponent extends BaseComponent {
- private static rootElement = 'aca-edit-rule-dialog aca-rule-action-list';
+ private static readonly rootElement = 'aca-edit-rule-dialog aca-rule-action-list';
- private getOptionLocator = (optionName: string): Locator => this.page.locator('[role=listbox] [role=option]', { hasText: optionName }).first();
- private ruleActionLocator = this.getChild('aca-rule-action');
- private addActionButtonLocator = this.getChild('[data-automation-id="rule-action-list-add-action-button"]');
- private actionDropdownLocator = this.getChild('[data-automation-id="rule-action-select"]');
- private actionAspectNameLocator = '[data-automation-id="header-aspect-name"] .adf-property-field';
- private actionCheckInInputLocator = '[data-automation-id="header-description"] input';
- private actionSimpleWorkflowStepInputLocator = '[data-automation-id="header-approve-step"] input';
- private actionSimpleWorkflowActionChoiceLocator = '[data-automation-id="content-node-selector-actions-choose"]';
- private actionSimpleWorkflowLabelApproveLocator = `[data-automation-id="card-boolean-label-approve-move"]`;
- private actionSimpleWorkflowSRejectStepLocator = '[data-automation-id="header-reject-step"] input';
- private actionSimpleWorkflowRejectFolderLocator = `[data-automation-id="header-reject-folder"] input`;
+ private readonly getOptionLocator = (optionName: string): Locator =>
+ this.page.locator('[role=listbox] [role=option]', { hasText: optionName }).first();
+ private readonly ruleActionLocator = this.getChild('aca-rule-action');
+ private readonly addActionButtonLocator = this.getChild('[data-automation-id="rule-action-list-add-action-button"]');
+ private readonly actionDropdownLocator = this.getChild('[data-automation-id="rule-action-select"]');
+ private readonly actionAspectNameLocator = '[data-automation-id="header-aspect-name"] .adf-property-field';
+ private readonly actionCheckInInputLocator = '[data-automation-id="header-description"] input';
+ private readonly actionSimpleWorkflowStepInputLocator = '[data-automation-id="header-approve-step"] input';
+ private readonly actionSimpleWorkflowActionChoiceLocator = '[data-automation-id="content-node-selector-actions-choose"]';
+ private readonly actionSimpleWorkflowLabelApproveLocator = `[data-automation-id="card-boolean-label-approve-move"]`;
+ private readonly actionSimpleWorkflowSRejectStepLocator = '[data-automation-id="header-reject-step"] input';
+ private readonly actionSimpleWorkflowRejectFolderLocator = `[data-automation-id="header-reject-folder"] input`;
private readonly actionSimpleWorkflowApproveFolderLocator = `[data-automation-id="header-approve-folder"] [role="img"]`;
private readonly actionSpecialiseTypeLocator = '[data-automation-id="header-type-name"] [role="combobox"]';
private readonly mimeTypeDropdownLocator = this.getChild('[data-automation-id="select-box"][aria-label="Mimetype *"]');
diff --git a/projects/aca-playwright-shared/src/page-objects/components/adf-info-drawer.component.ts b/projects/aca-playwright-shared/src/page-objects/components/adf-info-drawer.component.ts
index a14b3ec0c..aa3e79eb4 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/adf-info-drawer.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/adf-info-drawer.component.ts
@@ -26,7 +26,7 @@ import { BaseComponent } from './base.component';
import { Locator, Page } from '@playwright/test';
export class AdfInfoDrawerComponent extends BaseComponent {
- private static rootElement = 'adf-info-drawer';
+ private static readonly rootElement = 'adf-info-drawer';
constructor(page: Page) {
super(page, AdfInfoDrawerComponent.rootElement);
diff --git a/projects/aca-playwright-shared/src/page-objects/components/base.component.ts b/projects/aca-playwright-shared/src/page-objects/components/base.component.ts
index f7a4581b8..2631fc506 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/base.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/base.component.ts
@@ -28,7 +28,7 @@ import { timeouts } from '../../utils';
export abstract class BaseComponent extends PlaywrightBase {
private readonly rootElement: string;
- private progressBar = this.page.locator('[role="progressbar"]');
+ private readonly progressBar = this.page.locator('[role="progressbar"]');
protected constructor(page: Page, rootElement: string) {
super(page);
diff --git a/projects/aca-playwright-shared/src/page-objects/components/breadcrumb/breadcrumb.component.ts b/projects/aca-playwright-shared/src/page-objects/components/breadcrumb/breadcrumb.component.ts
index e7cd653f5..35b83f12f 100755
--- a/projects/aca-playwright-shared/src/page-objects/components/breadcrumb/breadcrumb.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/breadcrumb/breadcrumb.component.ts
@@ -25,7 +25,7 @@
import { BaseComponent } from '.././base.component';
import { Locator, Page } from '@playwright/test';
export class Breadcrumb extends BaseComponent {
- private static rootElement = 'adf-breadcrumb';
+ private static readonly rootElement = 'adf-breadcrumb';
public items = this.getChild('.adf-breadcrumb-item');
public currentItem = this.getChild('.adf-breadcrumb-item-current');
getItemByTitle = (name: string): Locator => this.getChild(`.adf-breadcrumb-item[title=${name}]`);
diff --git a/projects/aca-playwright-shared/src/page-objects/components/conditions.component.ts b/projects/aca-playwright-shared/src/page-objects/components/conditions.component.ts
index 5ef57e62d..56b51013b 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/conditions.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/conditions.component.ts
@@ -43,7 +43,8 @@ export enum Comparator {
}
export class ConditionComponent extends ManageRulesDialogComponent {
- private getOptionLocator = (optionName: string): Locator => this.page.locator('[role=listbox] [role=option]', { hasText: optionName }).first();
+ private readonly getOptionLocator = (optionName: string): Locator =>
+ this.page.locator('[role=listbox] [role=option]', { hasText: optionName }).first();
private async selectField(fields: Partial, index: number): Promise {
await this.fieldDropDown.nth(index).click();
diff --git a/projects/aca-playwright-shared/src/page-objects/components/dataTable/data-table.component.ts b/projects/aca-playwright-shared/src/page-objects/components/dataTable/data-table.component.ts
index 2669b3528..a5b13fa3f 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/dataTable/data-table.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/dataTable/data-table.component.ts
@@ -29,7 +29,7 @@ import { PaginationActionsType, PaginationComponent } from '../pagination.compon
import { timeouts } from '../../../utils';
export class DataTableComponent extends BaseComponent {
- private static rootElement = 'adf-datatable';
+ private static readonly rootElement = 'adf-datatable';
contextMenuActions = new MatMenuComponent(this.page);
constructor(page: Page, rootElement = DataTableComponent.rootElement) {
diff --git a/projects/aca-playwright-shared/src/page-objects/components/dataTable/mat-menu.component.ts b/projects/aca-playwright-shared/src/page-objects/components/dataTable/mat-menu.component.ts
index 1a0d6d7ef..6777b4008 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/dataTable/mat-menu.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/dataTable/mat-menu.component.ts
@@ -26,7 +26,7 @@ import { expect, Page } from '@playwright/test';
import { BaseComponent } from '../base.component';
export class MatMenuComponent extends BaseComponent {
- private static rootElement = '[role="menu"]';
+ private static readonly rootElement = '[role="menu"]';
constructor(page: Page) {
super(page, MatMenuComponent.rootElement);
diff --git a/projects/aca-playwright-shared/src/page-objects/components/datetime-picker/datetime-picker.component.ts b/projects/aca-playwright-shared/src/page-objects/components/datetime-picker/datetime-picker.component.ts
index 62be62e26..7088106a2 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/datetime-picker/datetime-picker.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/datetime-picker/datetime-picker.component.ts
@@ -26,7 +26,7 @@ import { Page } from '@playwright/test';
import { BaseComponent } from '../base.component';
export class DateTimePicker extends BaseComponent {
- private static rootElement = '[role="dialog"]';
+ private static readonly rootElement = '[role="dialog"]';
dayPicker = this.getChild('[role="grid"]');
nextMonthBtn = this.getChild('[aria-label="Next month"]');
diff --git a/projects/aca-playwright-shared/src/page-objects/components/dialogs/adf-confirm-dialog.component.ts b/projects/aca-playwright-shared/src/page-objects/components/dialogs/adf-confirm-dialog.component.ts
index e4aceac00..279f64902 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/dialogs/adf-confirm-dialog.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/dialogs/adf-confirm-dialog.component.ts
@@ -26,7 +26,7 @@ import { Page } from '@playwright/test';
import { BaseComponent } from '../base.component';
export class AdfConfirmDialogComponent extends BaseComponent {
- private static rootElement = 'adf-confirm-dialog';
+ private static readonly rootElement = 'adf-confirm-dialog';
constructor(page: Page) {
super(page, AdfConfirmDialogComponent.rootElement);
diff --git a/projects/aca-playwright-shared/src/page-objects/components/dialogs/adf-folder-dialog.component.ts b/projects/aca-playwright-shared/src/page-objects/components/dialogs/adf-folder-dialog.component.ts
index 8c53dc9b9..cfd36a003 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/dialogs/adf-folder-dialog.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/dialogs/adf-folder-dialog.component.ts
@@ -26,7 +26,7 @@ import { BaseComponent } from '../base.component';
import { Page } from '@playwright/test';
export class AdfFolderDialogComponent extends BaseComponent {
- private static rootElement = 'adf-folder-dialog';
+ private static readonly rootElement = 'adf-folder-dialog';
public folderNameInputLocator = this.getChild('[id="adf-folder-name-input"]');
public folderNameInputHint = this.getChild('[aria-atomic="true"] span');
diff --git a/projects/aca-playwright-shared/src/page-objects/components/dialogs/adf-library-dialog.component.ts b/projects/aca-playwright-shared/src/page-objects/components/dialogs/adf-library-dialog.component.ts
index b41f76eaf..d1d90ca65 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/dialogs/adf-library-dialog.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/dialogs/adf-library-dialog.component.ts
@@ -27,7 +27,7 @@ import { BaseComponent } from '../base.component';
import { Locator, Page } from '@playwright/test';
export class AdfLibraryDialogComponent extends BaseComponent {
- private static rootElement = 'adf-library-dialog';
+ private static readonly rootElement = 'adf-library-dialog';
public createButton = this.getChild('[data-automation-id="create-library-id"]');
public cancelButton = this.getChild('[data-automation-id="cancel-library-id"]');
diff --git a/projects/aca-playwright-shared/src/page-objects/components/dialogs/content-node-selector-dialog.ts b/projects/aca-playwright-shared/src/page-objects/components/dialogs/content-node-selector-dialog.ts
index bd5d7def4..6a7cf1d6d 100755
--- a/projects/aca-playwright-shared/src/page-objects/components/dialogs/content-node-selector-dialog.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/dialogs/content-node-selector-dialog.ts
@@ -26,9 +26,9 @@ import { Locator, Page, expect } from '@playwright/test';
import { BaseComponent } from '../base.component';
export class ContentNodeSelectorDialog extends BaseComponent {
- private static rootElement = 'adf-content-node-selector';
- private selectedRow = this.getChild('.adf-is-selected');
- private getRowByName = (name: string | number): Locator => this.getChild(`adf-datatable-row`, { hasText: name.toString() });
+ private static readonly rootElement = 'adf-content-node-selector';
+ private readonly selectedRow = this.getChild('.adf-is-selected');
+ private readonly getRowByName = (name: string | number): Locator => this.getChild(`adf-datatable-row`, { hasText: name.toString() });
public cancelButton = this.getChild('[data-automation-id="content-node-selector-actions-cancel"]');
public actionButton = this.getChild('[data-automation-id="content-node-selector-actions-choose"]');
diff --git a/projects/aca-playwright-shared/src/page-objects/components/dialogs/create-from-template-dialog-component.ts b/projects/aca-playwright-shared/src/page-objects/components/dialogs/create-from-template-dialog-component.ts
index bc97b9d43..1e330705e 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/dialogs/create-from-template-dialog-component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/dialogs/create-from-template-dialog-component.ts
@@ -27,7 +27,7 @@ import { BaseComponent } from '../base.component';
import { timeouts } from '../../../utils';
export class CreateFromTemplateDialogComponent extends BaseComponent {
- private static rootElement = '.aca-create-from-template-dialog';
+ private static readonly rootElement = '.aca-create-from-template-dialog';
constructor(page: Page) {
super(page, CreateFromTemplateDialogComponent.rootElement);
diff --git a/projects/aca-playwright-shared/src/page-objects/components/dialogs/delete-trash-dialog.component.ts b/projects/aca-playwright-shared/src/page-objects/components/dialogs/delete-trash-dialog.component.ts
index eaf88874c..94c5d49e9 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/dialogs/delete-trash-dialog.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/dialogs/delete-trash-dialog.component.ts
@@ -26,7 +26,7 @@ import { Page } from '@playwright/test';
import { BaseComponent } from '../base.component';
export class AdfDeleteTrashComponent extends BaseComponent {
- private static rootElement = 'adf-confirm-dialog';
+ private static readonly rootElement = 'adf-confirm-dialog';
constructor(page: Page) {
super(page, AdfDeleteTrashComponent.rootElement);
diff --git a/projects/aca-playwright-shared/src/page-objects/components/dialogs/edit-dialog.component.ts b/projects/aca-playwright-shared/src/page-objects/components/dialogs/edit-dialog.component.ts
index 2670691a0..efdacd2bf 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/dialogs/edit-dialog.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/dialogs/edit-dialog.component.ts
@@ -26,7 +26,7 @@ import { Page } from '@playwright/test';
import { BaseComponent } from '../base.component';
export class EditDialog extends BaseComponent {
- private static rootElement = 'adf-folder-dialog';
+ private static readonly rootElement = 'adf-folder-dialog';
public editDialog = this.page.locator(EditDialog.rootElement);
public titleInput = this.getChild('[data-automation-id="adf-folder-dialog-title"]');
diff --git a/projects/aca-playwright-shared/src/page-objects/components/dialogs/link-rules.component.ts b/projects/aca-playwright-shared/src/page-objects/components/dialogs/link-rules.component.ts
index f83d663e1..ac7d25f0e 100755
--- a/projects/aca-playwright-shared/src/page-objects/components/dialogs/link-rules.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/dialogs/link-rules.component.ts
@@ -26,8 +26,8 @@ import { Locator, Page, expect } from '@playwright/test';
import { BaseComponent } from '../base.component';
export class LinkRulesDialog extends BaseComponent {
- private static rootElement = 'aca-rule-set-picker';
- private getRowByName = (name: string | number): Locator => this.getChild(`adf-datatable-row`, { hasText: name.toString() });
+ private static readonly rootElement = 'aca-rule-set-picker';
+ private readonly getRowByName = (name: string | number): Locator => this.getChild(`adf-datatable-row`, { hasText: name.toString() });
selectFolderButton = this.getChild('button', { hasText: ' Select folder ' });
getOptionLocator = (optionName: string): Locator => this.page.locator('[role=listbox] [role=option]', { hasText: optionName }).first();
diff --git a/projects/aca-playwright-shared/src/page-objects/components/dialogs/manage-versions-dialog.component.ts b/projects/aca-playwright-shared/src/page-objects/components/dialogs/manage-versions-dialog.component.ts
index 6271b8317..dbd06910f 100755
--- a/projects/aca-playwright-shared/src/page-objects/components/dialogs/manage-versions-dialog.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/dialogs/manage-versions-dialog.component.ts
@@ -26,7 +26,7 @@ import { Page } from '@playwright/test';
import { BaseComponent } from '../base.component';
export class ManageVersionsDialog extends BaseComponent {
- private static rootElement = '.adf-new-version-uploader-dialog';
+ private static readonly rootElement = '.adf-new-version-uploader-dialog';
async viewFileVersion(version: string): Promise {
const versionActionsButton = this.getChild(`[id="adf-version-list-action-menu-button-${version}"]`);
diff --git a/projects/aca-playwright-shared/src/page-objects/components/dialogs/password-overlay-dialog.component.ts b/projects/aca-playwright-shared/src/page-objects/components/dialogs/password-overlay-dialog.component.ts
index 8bd7449dc..bbf2731d5 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/dialogs/password-overlay-dialog.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/dialogs/password-overlay-dialog.component.ts
@@ -27,7 +27,7 @@ import { BaseComponent } from '../base.component';
import { timeouts } from '../../../utils';
export class PasswordOverlayDialogComponent extends BaseComponent {
- private static rootElement = '.cdk-overlay-pane';
+ private static readonly rootElement = '.cdk-overlay-pane';
public closeButton = this.getChild('[data-automation-id="adf-password-dialog-close"]');
public submitButton = this.getChild('[data-automation-id="adf-password-dialog-submit"]');
diff --git a/projects/aca-playwright-shared/src/page-objects/components/dialogs/share-dialog.component.ts b/projects/aca-playwright-shared/src/page-objects/components/dialogs/share-dialog.component.ts
index 1678ad014..bb8a7ed46 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/dialogs/share-dialog.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/dialogs/share-dialog.component.ts
@@ -28,7 +28,7 @@ import { timeouts } from '../../../utils';
import { DateTimePicker } from '../datetime-picker/datetime-picker.component';
export class ShareDialogComponent extends BaseComponent {
- private static rootElement = 'adf-share-dialog';
+ private static readonly rootElement = 'adf-share-dialog';
constructor(page: Page) {
super(page, ShareDialogComponent.rootElement);
diff --git a/projects/aca-playwright-shared/src/page-objects/components/dialogs/upload-dialog.component.ts b/projects/aca-playwright-shared/src/page-objects/components/dialogs/upload-dialog.component.ts
index 9c5cf58ca..8121a8307 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/dialogs/upload-dialog.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/dialogs/upload-dialog.component.ts
@@ -26,7 +26,7 @@ import { Page } from '@playwright/test';
import { BaseComponent } from '../base.component';
export class UploadDialog extends BaseComponent {
- private static rootElement = 'aca-upload-files-dialog';
+ private static readonly rootElement = 'aca-upload-files-dialog';
public uploadDialogContent = this.getChild('.adf-upload-dialog__content');
public closeButton = this.getChild('#adf-upload-dialog-close');
diff --git a/projects/aca-playwright-shared/src/page-objects/components/dialogs/upload-new-version-dialog.component.ts b/projects/aca-playwright-shared/src/page-objects/components/dialogs/upload-new-version-dialog.component.ts
index 826555ecc..5de441e4f 100755
--- a/projects/aca-playwright-shared/src/page-objects/components/dialogs/upload-new-version-dialog.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/dialogs/upload-new-version-dialog.component.ts
@@ -26,7 +26,7 @@ import { Page } from '@playwright/test';
import { BaseComponent } from '../base.component';
export class UploadNewVersionDialog extends BaseComponent {
- private static rootElement = 'adf-new-version-uploader-dialog';
+ private static readonly rootElement = 'adf-new-version-uploader-dialog';
public cancelButton = this.getChild('#adf-new-version-cancel');
public uploadButton = this.getChild('[data-automation-id="adf-new-version-file-upload"]');
diff --git a/projects/aca-playwright-shared/src/page-objects/components/dialogs/viewer-overlay-dialog.component.ts b/projects/aca-playwright-shared/src/page-objects/components/dialogs/viewer-overlay-dialog.component.ts
index 74bff629d..85425e67f 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/dialogs/viewer-overlay-dialog.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/dialogs/viewer-overlay-dialog.component.ts
@@ -27,7 +27,7 @@ import { BaseComponent } from '../base.component';
import { timeouts } from '../../../utils';
export class ViewerOverlayDialogComponent extends BaseComponent {
- private static rootElement = '.cdk-overlay-pane';
+ private static readonly rootElement = '.cdk-overlay-pane';
public copyDialog = this.getChild('[data-automation-id="content-node-selector-title"]');
public copyMenuButton = this.getChild('[id="app.viewer.copy"]');
diff --git a/projects/aca-playwright-shared/src/page-objects/components/error.component.ts b/projects/aca-playwright-shared/src/page-objects/components/error.component.ts
index fa58ed0f5..f192a8c4a 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/error.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/error.component.ts
@@ -26,7 +26,7 @@ import { Page } from '@playwright/test';
import { BaseComponent } from './base.component';
export class ErrorComponent extends BaseComponent {
- private static rootElement = 'aca-page-layout';
+ private static readonly rootElement = 'aca-page-layout';
genericError = this.getChild('aca-generic-error');
genericErrorTitle = this.getChild('.generic-error__title');
diff --git a/projects/aca-playwright-shared/src/page-objects/components/manageRules/manage-rules-dialog.component.ts b/projects/aca-playwright-shared/src/page-objects/components/manageRules/manage-rules-dialog.component.ts
index 326e1b6b0..f6bfe7aca 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/manageRules/manage-rules-dialog.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/manageRules/manage-rules-dialog.component.ts
@@ -26,7 +26,7 @@ import { BaseComponent } from '../base.component';
import { Page } from '@playwright/test';
export class ManageRulesDialogComponent extends BaseComponent {
- private static rootElement = 'aca-edit-rule-dialog';
+ private static readonly rootElement = 'aca-edit-rule-dialog';
public createRuleButton = this.getChild('[data-automation-id="edit-rule-dialog-submit"]');
public cancelRuleButton = this.getChild('.aca-edit-rule-dialog__footer button').filter({ hasText: 'Cancel' });
diff --git a/projects/aca-playwright-shared/src/page-objects/components/manageRules/manage-rules.component.ts b/projects/aca-playwright-shared/src/page-objects/components/manageRules/manage-rules.component.ts
index 28ae5b974..980306ce8 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/manageRules/manage-rules.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/manageRules/manage-rules.component.ts
@@ -26,7 +26,7 @@ import { Locator, Page, expect } from '@playwright/test';
import { BaseComponent } from '../base.component';
export class ManageRules extends BaseComponent {
- private static rootElement = '.aca-manage-rules';
+ private static readonly rootElement = '.aca-manage-rules';
public getGroupsList = (optionName: string): Locator => this.getChild('.aca-rule-list-item__header', { hasText: optionName });
public ruleToggle = this.getChild('.aca-manage-rules__container [role="switch"]').first();
diff --git a/projects/aca-playwright-shared/src/page-objects/components/pagination.component.ts b/projects/aca-playwright-shared/src/page-objects/components/pagination.component.ts
index 72c7e6b03..994fe0825 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/pagination.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/pagination.component.ts
@@ -33,19 +33,19 @@ export enum PaginationActionsType {
}
export class PaginationComponent extends BaseComponent {
- private static rootElement = 'adf-pagination';
+ private static readonly rootElement = 'adf-pagination';
constructor(page: Page) {
super(page, PaginationComponent.rootElement);
}
- private range = this.getChild('.adf-pagination__range');
- private maxItems = this.getChild('.adf-pagination__max-items');
- private currentPage = this.getChild('.adf-pagination__current-page');
- private totalPages = this.getChild('.adf-pagination__total-pages');
- private previousButton = this.getChild('.adf-pagination__previous-button');
- private nextButton = this.getChild('.adf-pagination__next-button');
- private maxItemsButton = this.getChild('.adf-pagination__max-items + button[mat-icon-button]');
+ private readonly range = this.getChild('.adf-pagination__range');
+ private readonly maxItems = this.getChild('.adf-pagination__max-items');
+ private readonly currentPage = this.getChild('.adf-pagination__current-page');
+ private readonly totalPages = this.getChild('.adf-pagination__total-pages');
+ private readonly previousButton = this.getChild('.adf-pagination__previous-button');
+ private readonly nextButton = this.getChild('.adf-pagination__next-button');
+ private readonly maxItemsButton = this.getChild('.adf-pagination__max-items + button[mat-icon-button]');
public currentPageLocator = this.getChild('.adf-pagination__current-page');
public totalPageLocator = this.getChild('.adf-pagination__total-pages');
diff --git a/projects/aca-playwright-shared/src/page-objects/components/search/search-filters.component.ts b/projects/aca-playwright-shared/src/page-objects/components/search/search-filters.component.ts
index 9cfedda93..596feae84 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/search/search-filters.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/search/search-filters.component.ts
@@ -26,7 +26,7 @@ import { BaseComponent } from '../base.component';
import { Page } from '@playwright/test';
export class SearchFilters extends BaseComponent {
- private static rootElement = '.aca-content__advanced-filters';
+ private static readonly rootElement = '.aca-content__advanced-filters';
constructor(page: Page) {
super(page, SearchFilters.rootElement);
diff --git a/projects/aca-playwright-shared/src/page-objects/components/search/search-filters/search-filters-categories.component.ts b/projects/aca-playwright-shared/src/page-objects/components/search/search-filters/search-filters-categories.component.ts
index 1e2b9e5e1..bddd76a21 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/search/search-filters/search-filters-categories.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/search/search-filters/search-filters-categories.component.ts
@@ -26,7 +26,7 @@ import { BaseComponent } from '../../base.component';
import { Page } from '@playwright/test';
export class SearchFiltersCategories extends BaseComponent {
- private static rootElement = '.adf-search-filter-menu-card';
+ private static readonly rootElement = '.adf-search-filter-menu-card';
constructor(page: Page) {
super(page, SearchFiltersCategories.rootElement);
diff --git a/projects/aca-playwright-shared/src/page-objects/components/search/search-filters/search-filters-date.component.ts b/projects/aca-playwright-shared/src/page-objects/components/search/search-filters/search-filters-date.component.ts
index 0e03ac3aa..9811997e4 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/search/search-filters/search-filters-date.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/search/search-filters/search-filters-date.component.ts
@@ -29,7 +29,7 @@ import { SearchPage } from '../../../pages';
type FilterTab = 'Created' | 'Modified';
export class SearchFiltersDate extends BaseComponent {
- private static rootElement = '.adf-search-filter-menu-card';
+ private static readonly rootElement = '.adf-search-filter-menu-card';
constructor(page: Page) {
super(page, SearchFiltersDate.rootElement);
diff --git a/projects/aca-playwright-shared/src/page-objects/components/search/search-filters/search-filters-location.component.ts b/projects/aca-playwright-shared/src/page-objects/components/search/search-filters/search-filters-location.component.ts
index 84d156caf..be855455f 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/search/search-filters/search-filters-location.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/search/search-filters/search-filters-location.component.ts
@@ -27,7 +27,7 @@ import { BaseComponent } from '../../base.component';
import { Page, Locator } from '@playwright/test';
export class SearchFiltersLocation extends BaseComponent {
- private static rootElement = '.adf-search-filter-menu-card';
+ private static readonly rootElement = '.adf-search-filter-menu-card';
constructor(page: Page) {
super(page, SearchFiltersLocation.rootElement);
diff --git a/projects/aca-playwright-shared/src/page-objects/components/search/search-filters/search-filters-logic.component.ts b/projects/aca-playwright-shared/src/page-objects/components/search/search-filters/search-filters-logic.component.ts
index dda23975e..b129a0f73 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/search/search-filters/search-filters-logic.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/search/search-filters/search-filters-logic.component.ts
@@ -26,7 +26,7 @@ import { BaseComponent } from '../../base.component';
import { Page } from '@playwright/test';
export class SearchFiltersLogic extends BaseComponent {
- private static rootElement = '.adf-search-filter-menu-card';
+ private static readonly rootElement = '.adf-search-filter-menu-card';
constructor(page: Page) {
super(page, SearchFiltersLogic.rootElement);
diff --git a/projects/aca-playwright-shared/src/page-objects/components/search/search-filters/search-filters-properties.component.ts b/projects/aca-playwright-shared/src/page-objects/components/search/search-filters/search-filters-properties.component.ts
index f49baa092..1ddea7b78 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/search/search-filters/search-filters-properties.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/search/search-filters/search-filters-properties.component.ts
@@ -27,7 +27,7 @@ import { BaseComponent } from '../../base.component';
import { Page } from '@playwright/test';
export class SearchFiltersProperties extends BaseComponent {
- private static rootElement = '.adf-search-filter-menu-card';
+ private static readonly rootElement = '.adf-search-filter-menu-card';
constructor(page: Page) {
super(page, SearchFiltersProperties.rootElement);
diff --git a/projects/aca-playwright-shared/src/page-objects/components/search/search-filters/search-filters-tags.component.ts b/projects/aca-playwright-shared/src/page-objects/components/search/search-filters/search-filters-tags.component.ts
index ca3e43c3b..9f53656f3 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/search/search-filters/search-filters-tags.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/search/search-filters/search-filters-tags.component.ts
@@ -27,7 +27,7 @@ import { BaseComponent } from '../../base.component';
import { Page, Locator } from '@playwright/test';
export class SearchFiltersTags extends BaseComponent {
- private static rootElement = '.adf-search-filter-menu-card';
+ private static readonly rootElement = '.adf-search-filter-menu-card';
constructor(page: Page) {
super(page, SearchFiltersTags.rootElement);
diff --git a/projects/aca-playwright-shared/src/page-objects/components/search/search-input.component.ts b/projects/aca-playwright-shared/src/page-objects/components/search/search-input.component.ts
index e13b7cd46..acdc9ad44 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/search/search-input.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/search/search-input.component.ts
@@ -26,7 +26,7 @@ import { Locator, Page } from '@playwright/test';
import { BaseComponent } from '.././base.component';
export class SearchInputComponent extends BaseComponent {
- private static rootElement = 'aca-page-layout';
+ private static readonly rootElement = 'aca-page-layout';
public searchInput = this.getChild('aca-search-input input');
public searchButton = this.page.locator('.aca-search-input--search-button');
public searchCloseButton = this.page.locator('.aca-search-input--close-button');
diff --git a/projects/aca-playwright-shared/src/page-objects/components/search/search-sorting-picker.components.ts b/projects/aca-playwright-shared/src/page-objects/components/search/search-sorting-picker.components.ts
index bb294c52d..ede100a38 100755
--- a/projects/aca-playwright-shared/src/page-objects/components/search/search-sorting-picker.components.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/search/search-sorting-picker.components.ts
@@ -29,7 +29,7 @@ export type SortByType = 'Relevance' | 'Title' | 'Filename' | 'Modified date' |
export type SortByDirection = 'asc' | 'desc';
export class SearchSortingPicker extends BaseComponent {
- private static rootElement = '#aca-button-action-menu';
+ private static readonly rootElement = '#aca-button-action-menu';
public actionMenu = this.page.locator('[data-automation-id="auto_header_content_id_$thumbnail"]');
public sortOrderButton = this.page.locator('#aca-button-sorting-menu');
diff --git a/projects/aca-playwright-shared/src/page-objects/components/sidenav.component.ts b/projects/aca-playwright-shared/src/page-objects/components/sidenav.component.ts
index fb41dae82..039567c94 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/sidenav.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/sidenav.component.ts
@@ -27,17 +27,17 @@ import { BaseComponent } from './base.component';
import { Locator, Page } from '@playwright/test';
export class SidenavComponent extends BaseComponent {
- private static rootElement = '.adf-layout-container-sidenav';
+ private static readonly rootElement = '.adf-layout-container-sidenav';
- private personalFiles = this.getChild(`[data-automation-id='app.navbar.personalFiles']`);
- private myLibraries = this.getChild(`[data-automation-id='app.navbar.libraries.files']`);
- private favoriteLibraries = this.getChild(`[data-automation-id='app.navbar.libraries.favorite']`);
- private shared = this.getChild(`[data-automation-id='app.navbar.shared']`);
- private recentFiles = this.getChild(`[data-automation-id='app.navbar.recentFiles']`);
- private favorites = this.getChild(`[data-automation-id='app.navbar.favorites']`);
- private trash = this.getChild(`[data-automation-id='app.navbar.trashcan']`);
- private sidenavToggle = this.getChild(`.aca-sidenav-header-title-logo`);
- private sidenavExpand = this.page.locator(`[title='Expand navigation menu']`);
+ private readonly personalFiles = this.getChild(`[data-automation-id='app.navbar.personalFiles']`);
+ private readonly myLibraries = this.getChild(`[data-automation-id='app.navbar.libraries.files']`);
+ private readonly favoriteLibraries = this.getChild(`[data-automation-id='app.navbar.libraries.favorite']`);
+ private readonly shared = this.getChild(`[data-automation-id='app.navbar.shared']`);
+ private readonly recentFiles = this.getChild(`[data-automation-id='app.navbar.recentFiles']`);
+ private readonly favorites = this.getChild(`[data-automation-id='app.navbar.favorites']`);
+ private readonly trash = this.getChild(`[data-automation-id='app.navbar.trashcan']`);
+ private readonly sidenavToggle = this.getChild(`.aca-sidenav-header-title-logo`);
+ private readonly sidenavExpand = this.page.locator(`[title='Expand navigation menu']`);
public expandedSidenav = this.getChild(`[data-automation-id='expanded']`);
constructor(page: Page) {
diff --git a/projects/aca-playwright-shared/src/page-objects/components/snackBar/snack-bar.component.ts b/projects/aca-playwright-shared/src/page-objects/components/snackBar/snack-bar.component.ts
index dca397590..51a5debfc 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/snackBar/snack-bar.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/snackBar/snack-bar.component.ts
@@ -26,7 +26,7 @@ import { Page, expect } from '@playwright/test';
import { BaseComponent } from '../base.component';
export class SnackBarComponent extends BaseComponent {
- private static rootElement = 'adf-snackbar-content';
+ private static readonly rootElement = 'adf-snackbar-content';
public message = this.getChild('[data-automation-id="adf-snackbar-message-content"]').first();
diff --git a/projects/aca-playwright-shared/src/page-objects/components/spinner.component.ts b/projects/aca-playwright-shared/src/page-objects/components/spinner.component.ts
index 023125afe..6943995dc 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/spinner.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/spinner.component.ts
@@ -26,7 +26,7 @@ import { Page } from '@playwright/test';
import { BaseComponent } from './base.component';
export class SpinnerComponent extends BaseComponent {
- private static rootElement = '[role="progressbar"]';
+ private static readonly rootElement = '[role="progressbar"]';
constructor(page: Page, rootElement = SpinnerComponent.rootElement) {
super(page, rootElement);
diff --git a/projects/aca-playwright-shared/src/page-objects/components/viewer.component.ts b/projects/aca-playwright-shared/src/page-objects/components/viewer.component.ts
index 1e7419e3c..5b89be4d7 100644
--- a/projects/aca-playwright-shared/src/page-objects/components/viewer.component.ts
+++ b/projects/aca-playwright-shared/src/page-objects/components/viewer.component.ts
@@ -28,7 +28,7 @@ import { AcaHeader } from './aca-header.component';
import { timeouts } from '../../utils';
export class ViewerComponent extends BaseComponent {
- private static rootElement = 'adf-viewer';
+ private static readonly rootElement = 'adf-viewer';
public viewerLocator = this.getChild('adf-viewer-render');
public closeButtonLocator = this.getChild('.adf-viewer-close-button');
diff --git a/projects/aca-playwright-shared/src/page-objects/pages/favorites-libraries.page.ts b/projects/aca-playwright-shared/src/page-objects/pages/favorites-libraries.page.ts
index eff1c8c8a..14f344372 100644
--- a/projects/aca-playwright-shared/src/page-objects/pages/favorites-libraries.page.ts
+++ b/projects/aca-playwright-shared/src/page-objects/pages/favorites-libraries.page.ts
@@ -29,7 +29,7 @@ import { AcaHeader } from '../components/aca-header.component';
import { AdfConfirmDialogComponent, AdfFolderDialogComponent, ViewerOverlayDialogComponent } from '../components/dialogs';
export class FavoritesLibrariesPage extends BasePage {
- private static pageUrl = 'favorite/libraries';
+ private static readonly pageUrl = 'favorite/libraries';
constructor(page: Page) {
super(page, FavoritesLibrariesPage.pageUrl);
diff --git a/projects/aca-playwright-shared/src/page-objects/pages/favorites.page.ts b/projects/aca-playwright-shared/src/page-objects/pages/favorites.page.ts
index 5f5dd947f..5e96b1c05 100644
--- a/projects/aca-playwright-shared/src/page-objects/pages/favorites.page.ts
+++ b/projects/aca-playwright-shared/src/page-objects/pages/favorites.page.ts
@@ -37,7 +37,7 @@ import { AcaHeader } from '../components/aca-header.component';
import { AdfFolderDialogComponent, ViewerOverlayDialogComponent, ManageVersionsDialog } from '../components/dialogs';
export class FavoritesPage extends BasePage {
- private static pageUrl = 'favorites';
+ private static readonly pageUrl = 'favorites';
constructor(page: Page) {
super(page, FavoritesPage.pageUrl);
diff --git a/projects/aca-playwright-shared/src/page-objects/pages/login.page.ts b/projects/aca-playwright-shared/src/page-objects/pages/login.page.ts
index 5842e683b..5cbc0290f 100644
--- a/projects/aca-playwright-shared/src/page-objects/pages/login.page.ts
+++ b/projects/aca-playwright-shared/src/page-objects/pages/login.page.ts
@@ -31,7 +31,7 @@ interface LoginOptions {
withNavigation?: boolean;
}
export class LoginPage extends BasePage {
- private static pageUrl = 'login';
+ private static readonly pageUrl = 'login';
constructor(page: Page) {
super(page, LoginPage.pageUrl);
diff --git a/projects/aca-playwright-shared/src/page-objects/pages/my-libraries.page.ts b/projects/aca-playwright-shared/src/page-objects/pages/my-libraries.page.ts
index c3eaecbeb..1b268dda0 100644
--- a/projects/aca-playwright-shared/src/page-objects/pages/my-libraries.page.ts
+++ b/projects/aca-playwright-shared/src/page-objects/pages/my-libraries.page.ts
@@ -41,7 +41,7 @@ import {
} from '../components';
export class MyLibrariesPage extends BasePage {
- private static pageUrl = 'libraries';
+ private static readonly pageUrl = 'libraries';
constructor(page: Page) {
super(page, MyLibrariesPage.pageUrl);
diff --git a/projects/aca-playwright-shared/src/page-objects/pages/nodes.page.ts b/projects/aca-playwright-shared/src/page-objects/pages/nodes.page.ts
index fd2591d51..670837002 100644
--- a/projects/aca-playwright-shared/src/page-objects/pages/nodes.page.ts
+++ b/projects/aca-playwright-shared/src/page-objects/pages/nodes.page.ts
@@ -35,7 +35,7 @@ import {
import { BasePage } from './base.page';
export class NodesPage extends BasePage {
- private static pageUrl = 'nodes';
+ private static readonly pageUrl = 'nodes';
constructor(page: Page) {
super(page, NodesPage.pageUrl);
diff --git a/projects/aca-playwright-shared/src/page-objects/pages/personal-files.page.ts b/projects/aca-playwright-shared/src/page-objects/pages/personal-files.page.ts
index 71959eb6c..6222aca02 100644
--- a/projects/aca-playwright-shared/src/page-objects/pages/personal-files.page.ts
+++ b/projects/aca-playwright-shared/src/page-objects/pages/personal-files.page.ts
@@ -50,7 +50,7 @@ import {
} from '../components';
export class PersonalFilesPage extends BasePage {
- private static pageUrl = 'personal-files';
+ private static readonly pageUrl = 'personal-files';
constructor(page: Page) {
super(page, PersonalFilesPage.pageUrl);
diff --git a/projects/aca-playwright-shared/src/page-objects/pages/recent-files.page.ts b/projects/aca-playwright-shared/src/page-objects/pages/recent-files.page.ts
index 15e791556..8a0abfb92 100644
--- a/projects/aca-playwright-shared/src/page-objects/pages/recent-files.page.ts
+++ b/projects/aca-playwright-shared/src/page-objects/pages/recent-files.page.ts
@@ -29,7 +29,7 @@ import { AcaHeader } from '../components/aca-header.component';
import { AdfFolderDialogComponent, ContentNodeSelectorDialog, ManageVersionsDialog } from '../components/dialogs';
export class RecentFilesPage extends BasePage {
- private static pageUrl = 'recent-files';
+ private static readonly pageUrl = 'recent-files';
constructor(page: Page) {
super(page, RecentFilesPage.pageUrl);
diff --git a/projects/aca-playwright-shared/src/page-objects/pages/search.page.ts b/projects/aca-playwright-shared/src/page-objects/pages/search.page.ts
index fad6d7221..cd930a1be 100644
--- a/projects/aca-playwright-shared/src/page-objects/pages/search.page.ts
+++ b/projects/aca-playwright-shared/src/page-objects/pages/search.page.ts
@@ -48,7 +48,7 @@ import { SearchInDialogComponent } from '../components/search/search-in-dialog.c
export type SearchType = 'files' | 'folders' | 'filesAndFolders' | 'libraries';
export class SearchPage extends BasePage {
- private static pageUrl = 'search';
+ private static readonly pageUrl = 'search';
constructor(page: Page) {
super(page, SearchPage.pageUrl);
diff --git a/projects/aca-playwright-shared/src/page-objects/pages/shared.page.ts b/projects/aca-playwright-shared/src/page-objects/pages/shared.page.ts
index 2a2488c7f..08b058b9c 100644
--- a/projects/aca-playwright-shared/src/page-objects/pages/shared.page.ts
+++ b/projects/aca-playwright-shared/src/page-objects/pages/shared.page.ts
@@ -29,7 +29,7 @@ import { AcaHeader } from '../components/aca-header.component';
import { AdfFolderDialogComponent, ViewerOverlayDialogComponent, ManageVersionsDialog } from '../components/dialogs';
export class SharedPage extends BasePage {
- private static pageUrl = 'shared';
+ private static readonly pageUrl = 'shared';
constructor(page: Page) {
super(page, SharedPage.pageUrl);
diff --git a/projects/aca-playwright-shared/src/page-objects/pages/trash.page.ts b/projects/aca-playwright-shared/src/page-objects/pages/trash.page.ts
index 5d2db3578..f3cd9f0a4 100644
--- a/projects/aca-playwright-shared/src/page-objects/pages/trash.page.ts
+++ b/projects/aca-playwright-shared/src/page-objects/pages/trash.page.ts
@@ -29,7 +29,7 @@ import { AcaHeader } from '../components/aca-header.component';
import { AdfFolderDialogComponent, ViewerOverlayDialogComponent, AdfDeleteTrashComponent } from '../components/dialogs';
export class TrashPage extends BasePage {
- private static pageUrl = 'trashcan';
+ private static readonly pageUrl = 'trashcan';
constructor(page: Page) {
super(page, TrashPage.pageUrl);
diff --git a/projects/aca-shared/src/lib/components/document-base-page/document-base-page.component.ts b/projects/aca-shared/src/lib/components/document-base-page/document-base-page.component.ts
index 8ebe91459..cf318a711 100644
--- a/projects/aca-shared/src/lib/components/document-base-page/document-base-page.component.ts
+++ b/projects/aca-shared/src/lib/components/document-base-page/document-base-page.component.ts
@@ -91,8 +91,8 @@ export abstract class PageComponent implements OnInit, OnDestroy, OnChanges {
protected readonly destroyRef = inject(DestroyRef);
- private autoDownloadService = inject(AutoDownloadService, { optional: true });
- private navigationHistoryService = inject(NavigationHistoryService);
+ private readonly autoDownloadService = inject(AutoDownloadService, { optional: true });
+ private readonly navigationHistoryService = inject(NavigationHistoryService);
protected subscriptions: Subscription[] = [];
diff --git a/projects/aca-shared/src/lib/components/info-drawer/info-drawer.component.ts b/projects/aca-shared/src/lib/components/info-drawer/info-drawer.component.ts
index 79c9dcffd..8679bad38 100644
--- a/projects/aca-shared/src/lib/components/info-drawer/info-drawer.component.ts
+++ b/projects/aca-shared/src/lib/components/info-drawer/info-drawer.component.ts
@@ -54,6 +54,12 @@ import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
encapsulation: ViewEncapsulation.None
})
export class InfoDrawerComponent implements OnChanges, OnInit, OnDestroy {
+ private readonly store = inject>(Store);
+ private readonly contentApi = inject(ContentApiService);
+ private readonly extensions = inject(AppExtensionService);
+ private readonly nodesService = inject(NodesApiService);
+ private readonly contentService = inject(ContentService);
+
@Input()
nodeId: string;
@@ -75,14 +81,6 @@ export class InfoDrawerComponent implements OnChanges, OnInit, OnDestroy {
private readonly destroyRef = inject(DestroyRef);
- constructor(
- private store: Store,
- private contentApi: ContentApiService,
- private extensions: AppExtensionService,
- private nodesService: NodesApiService,
- private contentService: ContentService
- ) {}
-
ngOnInit() {
this.tabs = this.extensions.getSidebarTabs();
this.extensions
diff --git a/projects/aca-shared/src/lib/components/open-in-app/open-in-app.component.ts b/projects/aca-shared/src/lib/components/open-in-app/open-in-app.component.ts
index 7ca38d706..406b3a47d 100644
--- a/projects/aca-shared/src/lib/components/open-in-app/open-in-app.component.ts
+++ b/projects/aca-shared/src/lib/components/open-in-app/open-in-app.component.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { Component, Inject, ViewEncapsulation } from '@angular/core';
+import { Component, ViewEncapsulation, inject } from '@angular/core';
import { MAT_DIALOG_DATA, MatDialogModule, MatDialogRef } from '@angular/material/dialog';
import { CommonModule } from '@angular/common';
import { TranslatePipe } from '@ngx-translate/core';
@@ -42,15 +42,16 @@ export interface OpenInAppDialogOptions {
encapsulation: ViewEncapsulation.None
})
export class OpenInAppComponent {
- private redirectUrl: string;
+ data = inject(MAT_DIALOG_DATA);
+ private readonly dialog = inject>(MatDialogRef);
+
+ private readonly redirectUrl: string;
public appStoreUrl: string;
public window: Window & typeof globalThis = window;
- constructor(
- @Inject(MAT_DIALOG_DATA)
- public data: OpenInAppDialogOptions,
- private dialog: MatDialogRef
- ) {
+ constructor() {
+ const data = this.data;
+
if (data) {
this.redirectUrl = data.redirectUrl;
this.appStoreUrl = data.appStoreUrl;
diff --git a/projects/aca-shared/src/lib/components/page-layout/page-layout.component.ts b/projects/aca-shared/src/lib/components/page-layout/page-layout.component.ts
index a7366e691..68cfc216f 100644
--- a/projects/aca-shared/src/lib/components/page-layout/page-layout.component.ts
+++ b/projects/aca-shared/src/lib/components/page-layout/page-layout.component.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { Component, Input, ViewEncapsulation } from '@angular/core';
+import { Component, Input, ViewEncapsulation, inject } from '@angular/core';
import { Observable } from 'rxjs';
import { AppService } from '../../services/app.service';
import { CommonModule } from '@angular/common';
@@ -40,12 +40,16 @@ import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
host: { class: 'aca-page-layout' }
})
export class PageLayoutComponent {
+ private readonly appService = inject(AppService);
+
@Input()
hasError = false;
appNavNarMode$: Observable<'collapsed' | 'expanded'>;
- constructor(private appService: AppService) {
+ constructor() {
+ const appService = this.appService;
+
this.appNavNarMode$ = appService.appNavNarMode$.pipe(takeUntilDestroyed());
}
diff --git a/projects/aca-shared/src/lib/components/toolbar/toolbar-action/toolbar-action.component.spec.ts b/projects/aca-shared/src/lib/components/toolbar/toolbar-action/toolbar-action.component.spec.ts
index 7c39fc720..fd6bb2e11 100644
--- a/projects/aca-shared/src/lib/components/toolbar/toolbar-action/toolbar-action.component.spec.ts
+++ b/projects/aca-shared/src/lib/components/toolbar/toolbar-action/toolbar-action.component.spec.ts
@@ -25,25 +25,30 @@
import { ComponentFixture, TestBed } from '@angular/core/testing';
import { ToolbarActionComponent } from './toolbar-action.component';
import { ToolbarButtonType } from '../toolbar-button/toolbar-button.component';
-import { ChangeDetectorRef } from '@angular/core';
import { ContentActionType } from '@alfresco/adf-extensions';
import { LibTestingModule } from '@alfresco/aca-shared';
+import { ChangeDetectorRef } from '@angular/core';
describe('ToolbarActionComponent', () => {
let fixture: ComponentFixture;
let component: ToolbarActionComponent;
- let changeDetectorRef: ChangeDetectorRef;
+ let mockChangeDetectorRef: jasmine.SpyObj;
beforeEach(() => {
+ mockChangeDetectorRef = jasmine.createSpyObj('ChangeDetectorRef', ['markForCheck', 'detectChanges']);
+
TestBed.configureTestingModule({
- imports: [LibTestingModule, ToolbarActionComponent],
- providers: [{ provide: ChangeDetectorRef, useValue: { markForCheck() {} } }]
+ imports: [LibTestingModule, ToolbarActionComponent]
});
fixture = TestBed.createComponent(ToolbarActionComponent);
component = fixture.componentInstance;
- changeDetectorRef = TestBed.inject(ChangeDetectorRef);
+ Object.defineProperty(component, 'cd', {
+ value: mockChangeDetectorRef,
+ writable: false,
+ configurable: true
+ });
});
it('should be icon button by default', () => {
@@ -51,9 +56,6 @@ describe('ToolbarActionComponent', () => {
});
it('should force update UI on check for the viewer', () => {
- component = new ToolbarActionComponent(changeDetectorRef);
- const markForCheck = spyOn(changeDetectorRef, 'markForCheck');
-
component.actionRef = {
id: '-app.viewer',
type: ContentActionType.button,
@@ -63,6 +65,6 @@ describe('ToolbarActionComponent', () => {
};
component.ngDoCheck();
- expect(markForCheck).toHaveBeenCalled();
+ expect(mockChangeDetectorRef.markForCheck).toHaveBeenCalled();
});
});
diff --git a/projects/aca-shared/src/lib/components/toolbar/toolbar-action/toolbar-action.component.ts b/projects/aca-shared/src/lib/components/toolbar/toolbar-action/toolbar-action.component.ts
index dcb37b55c..a666767a6 100644
--- a/projects/aca-shared/src/lib/components/toolbar/toolbar-action/toolbar-action.component.ts
+++ b/projects/aca-shared/src/lib/components/toolbar/toolbar-action/toolbar-action.component.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { Component, ViewEncapsulation, ChangeDetectionStrategy, Input, DoCheck, ChangeDetectorRef } from '@angular/core';
+import { Component, ViewEncapsulation, ChangeDetectionStrategy, Input, DoCheck, ChangeDetectorRef, inject } from '@angular/core';
import { ContentActionRef, DynamicExtensionComponent } from '@alfresco/adf-extensions';
import { ToolbarButtonComponent, ToolbarButtonType } from '../toolbar-button/toolbar-button.component';
import { ThemePalette } from '@angular/material/core';
@@ -39,6 +39,8 @@ import { ToolbarMenuComponent } from '../toolbar-menu/toolbar-menu.component';
host: { class: 'aca-toolbar-action' }
})
export class ToolbarActionComponent implements DoCheck {
+ private readonly cd = inject(ChangeDetectorRef);
+
@Input()
data: {
buttonType?: ToolbarButtonType;
@@ -54,8 +56,6 @@ export class ToolbarActionComponent implements DoCheck {
@Input()
actionRef: ContentActionRef;
- constructor(private cd: ChangeDetectorRef) {}
-
// todo: review after ADF 2.6
// preview component : change detection workaround for children without input
ngDoCheck() {
diff --git a/projects/aca-shared/src/lib/components/toolbar/toolbar-button/toolbar-button.component.ts b/projects/aca-shared/src/lib/components/toolbar/toolbar-button/toolbar-button.component.ts
index c83fc28f7..ef5678b5b 100644
--- a/projects/aca-shared/src/lib/components/toolbar/toolbar-button/toolbar-button.component.ts
+++ b/projects/aca-shared/src/lib/components/toolbar/toolbar-button/toolbar-button.component.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { Component, Input, ViewEncapsulation } from '@angular/core';
+import { Component, Input, ViewEncapsulation, inject } from '@angular/core';
import { ContentActionRef } from '@alfresco/adf-extensions';
import { AppExtensionService } from '../../../services/app.extension.service';
import { ThemePalette } from '@angular/material/core';
@@ -47,6 +47,8 @@ export enum ToolbarButtonType {
host: { class: 'app-toolbar-button' }
})
export class ToolbarButtonComponent {
+ private readonly extensions = inject(AppExtensionService);
+
@Input()
data: {
buttonType?: ToolbarButtonType;
@@ -62,8 +64,6 @@ export class ToolbarButtonComponent {
@Input()
actionRef: ContentActionRef;
- constructor(private extensions: AppExtensionService) {}
-
runAction() {
if (this.hasClickAction(this.actionRef)) {
this.extensions.runActionById(this.actionRef.actions.click, {
diff --git a/projects/aca-shared/src/lib/components/toolbar/toolbar-menu-item/toolbar-menu-item.component.ts b/projects/aca-shared/src/lib/components/toolbar/toolbar-menu-item/toolbar-menu-item.component.ts
index 4392ef360..c41e69f30 100644
--- a/projects/aca-shared/src/lib/components/toolbar/toolbar-menu-item/toolbar-menu-item.component.ts
+++ b/projects/aca-shared/src/lib/components/toolbar/toolbar-menu-item/toolbar-menu-item.component.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { AfterViewInit, Component, Input, ViewChild, ViewEncapsulation } from '@angular/core';
+import { AfterViewInit, Component, Input, ViewChild, ViewEncapsulation, inject } from '@angular/core';
import { ContentActionRef, DynamicExtensionComponent } from '@alfresco/adf-extensions';
import { AppExtensionService } from '../../../services/app.extension.service';
import { MatMenuItem, MatMenuModule } from '@angular/material/menu';
@@ -40,6 +40,8 @@ import { IconComponent } from '@alfresco/adf-core';
host: { class: 'app-toolbar-menu-item' }
})
export class ToolbarMenuItemComponent implements AfterViewInit {
+ private readonly extensions = inject(AppExtensionService);
+
@Input()
actionRef: ContentActionRef;
@Input()
@@ -51,8 +53,6 @@ export class ToolbarMenuItemComponent implements AfterViewInit {
@ViewChild(DynamicExtensionComponent)
dynamicComponent: DynamicExtensionComponent;
- constructor(private extensions: AppExtensionService) {}
-
runAction() {
if (this.hasClickAction(this.actionRef)) {
this.extensions.runActionById(
diff --git a/projects/aca-shared/src/lib/directives/contextmenu/contextmenu.directive.spec.ts b/projects/aca-shared/src/lib/directives/contextmenu/contextmenu.directive.spec.ts
index 4a63303cd..6690164e4 100644
--- a/projects/aca-shared/src/lib/directives/contextmenu/contextmenu.directive.spec.ts
+++ b/projects/aca-shared/src/lib/directives/contextmenu/contextmenu.directive.spec.ts
@@ -27,7 +27,6 @@ import { ContextMenu, CustomContextMenu } from '@alfresco/aca-shared/store';
import { ContentActionRef, ContentActionType } from '@alfresco/adf-extensions';
import { fakeAsync, TestBed, tick } from '@angular/core/testing';
import { Store } from '@ngrx/store';
-import { Injector, runInInjectionContext } from '@angular/core';
const customActionsMock: ContentActionRef[] = [
{
@@ -50,11 +49,9 @@ describe('ContextActionsDirective', () => {
beforeEach(() => {
TestBed.configureTestingModule({
imports: [ContextActionsDirective],
- providers: [{ provide: Store, useValue: storeMock }]
- });
- runInInjectionContext(TestBed.inject(Injector), () => {
- directive = new ContextActionsDirective(storeMock);
+ providers: [ContextActionsDirective, { provide: Store, useValue: storeMock }]
});
+ directive = TestBed.inject(ContextActionsDirective);
});
it('should not render context menu when `enabled` property is false', () => {
diff --git a/projects/aca-shared/src/lib/directives/contextmenu/contextmenu.directive.ts b/projects/aca-shared/src/lib/directives/contextmenu/contextmenu.directive.ts
index ccefe0cad..e2e07e219 100644
--- a/projects/aca-shared/src/lib/directives/contextmenu/contextmenu.directive.ts
+++ b/projects/aca-shared/src/lib/directives/contextmenu/contextmenu.directive.ts
@@ -36,6 +36,8 @@ import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
exportAs: 'acaContextActions'
})
export class ContextActionsDirective implements OnInit {
+ private readonly store = inject>(Store);
+
// eslint-disable-next-line
@Input('acaContextEnable')
enabled = true;
@@ -57,12 +59,10 @@ export class ContextActionsDirective implements OnInit {
}
}
- private execute$: Subject = new Subject();
+ private readonly execute$: Subject = new Subject();
private readonly destroyRef = inject(DestroyRef);
- constructor(private store: Store) {}
-
ngOnInit() {
this.execute$.pipe(debounceTime(300), takeUntilDestroyed(this.destroyRef)).subscribe((event: MouseEvent) => {
if (this.customActions?.length) {
diff --git a/projects/aca-shared/src/lib/directives/pagination.directive.spec.ts b/projects/aca-shared/src/lib/directives/pagination.directive.spec.ts
index 9bbb4cd6e..9119434bf 100644
--- a/projects/aca-shared/src/lib/directives/pagination.directive.spec.ts
+++ b/projects/aca-shared/src/lib/directives/pagination.directive.spec.ts
@@ -23,50 +23,50 @@
*/
import { PaginationDirective } from './pagination.directive';
+import { Component, ViewChild } from '@angular/core';
import { ComponentFixture, TestBed } from '@angular/core/testing';
import { AppConfigService, PaginationComponent, PaginationModel, UserPreferencesService } from '@alfresco/adf-core';
import { initialState, LibTestingModule } from '../testing/lib-testing-module';
import { provideMockStore } from '@ngrx/store/testing';
-import { Injector, runInInjectionContext } from '@angular/core';
+
+@Component({
+ template: '',
+ imports: [PaginationComponent, PaginationDirective]
+})
+class TestComponent {
+ @ViewChild(PaginationComponent) pagination: PaginationComponent;
+}
describe('PaginationDirective', () => {
let preferences: UserPreferencesService;
let config: AppConfigService;
- let pagination: PaginationComponent;
- let fixture: ComponentFixture;
- let directive: PaginationDirective;
+ let fixture: ComponentFixture;
+ let component: TestComponent;
beforeEach(() => {
TestBed.configureTestingModule({
- imports: [LibTestingModule, PaginationDirective],
+ imports: [LibTestingModule, TestComponent],
providers: [provideMockStore({ initialState })]
});
+ fixture = TestBed.createComponent(TestComponent);
+ component = fixture.componentInstance;
preferences = TestBed.inject(UserPreferencesService);
config = TestBed.inject(AppConfigService);
- fixture = TestBed.createComponent(PaginationComponent);
- pagination = fixture.componentInstance;
- runInInjectionContext(TestBed.inject(Injector), () => {
- directive = new PaginationDirective(pagination, preferences, config);
- });
- });
-
- afterEach(() => {
- fixture.destroy();
});
it('should setup supported page sizes from app config', () => {
spyOn(config, 'get').and.returnValue([21, 31, 41]);
- directive.ngOnInit();
+ fixture.detectChanges();
- expect(pagination.supportedPageSizes).toEqual([21, 31, 41]);
+ expect(component.pagination.supportedPageSizes).toEqual([21, 31, 41]);
});
it('should update preferences on page size change', () => {
- directive.ngOnInit();
+ fixture.detectChanges();
- pagination.changePageSize.emit(
+ component.pagination.changePageSize.emit(
new PaginationModel({
maxItems: 100
})
diff --git a/projects/aca-shared/src/lib/directives/pagination.directive.ts b/projects/aca-shared/src/lib/directives/pagination.directive.ts
index 8a4423802..6c0c8a0ac 100644
--- a/projects/aca-shared/src/lib/directives/pagination.directive.ts
+++ b/projects/aca-shared/src/lib/directives/pagination.directive.ts
@@ -31,13 +31,11 @@ import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
selector: '[acaPagination]'
})
export class PaginationDirective implements OnInit {
- private readonly destroyRef = inject(DestroyRef);
+ private readonly pagination = inject(PaginationComponent);
+ private readonly preferences = inject(UserPreferencesService);
+ private readonly config = inject(AppConfigService);
- constructor(
- private readonly pagination: PaginationComponent,
- private readonly preferences: UserPreferencesService,
- private readonly config: AppConfigService
- ) {}
+ private readonly destroyRef = inject(DestroyRef);
ngOnInit() {
this.pagination.supportedPageSizes = this.config.get('pagination.supportedPageSizes');
diff --git a/projects/aca-shared/src/lib/services/aca-mobile-app-switcher.service.ts b/projects/aca-shared/src/lib/services/aca-mobile-app-switcher.service.ts
index 3d24c2aec..f5b4e54d5 100644
--- a/projects/aca-shared/src/lib/services/aca-mobile-app-switcher.service.ts
+++ b/projects/aca-shared/src/lib/services/aca-mobile-app-switcher.service.ts
@@ -33,8 +33,8 @@ import { OpenInAppComponent } from '../components/open-in-app/open-in-app.compon
export class AcaMobileAppSwitcherService {
public redirectUrl: string;
private dialogRef: MatDialogRef;
- private config = inject(AppConfigService);
- private dialog = inject(MatDialog);
+ private readonly config = inject(AppConfigService);
+ private readonly dialog = inject(MatDialog);
get appStoreUrl(): string {
const defaultValue = 'https://apps.apple.com/us/app/alfresco-mobile-workspace/id1514434480';
diff --git a/projects/aca-shared/src/lib/services/app-settings.service.ts b/projects/aca-shared/src/lib/services/app-settings.service.ts
index 11177fba3..a1e8f02f6 100644
--- a/projects/aca-shared/src/lib/services/app-settings.service.ts
+++ b/projects/aca-shared/src/lib/services/app-settings.service.ts
@@ -28,7 +28,7 @@ import { AlfrescoMimeType, DefaultMimeTypes } from '../constants/mime-types';
@Injectable({ providedIn: 'root' })
export class AppSettingsService {
- private appConfig = inject(AppConfigService);
+ private readonly appConfig = inject(AppConfigService);
/**
* Get the application copyright text from the app settings.
diff --git a/projects/aca-shared/src/lib/services/app.extension.service.ts b/projects/aca-shared/src/lib/services/app.extension.service.ts
index 57d6d0fb8..c6217ac4f 100644
--- a/projects/aca-shared/src/lib/services/app.extension.service.ts
+++ b/projects/aca-shared/src/lib/services/app.extension.service.ts
@@ -71,7 +71,17 @@ export function provideContentAppExtensions(): EnvironmentProviders[] {
providedIn: 'root'
})
export class AppExtensionService implements RuleContext {
- private _references = new BehaviorSubject([]);
+ readonly auth = inject(AuthenticationService);
+ protected readonly store = inject>(Store);
+ protected readonly loader = inject(ExtensionLoaderService);
+ protected readonly extensions = inject(ExtensionService);
+ readonly permissions = inject(NodePermissionService);
+ readonly appConfig = inject(AppConfigService);
+ protected readonly matIconRegistry = inject(MatIconRegistry);
+ protected readonly sanitizer = inject(DomSanitizer);
+ protected readonly logger = inject(LogService);
+
+ private readonly _references = new BehaviorSubject([]);
bulkActionExecuted$ = new Subject();
navbar: Array = [];
@@ -80,18 +90,18 @@ export class AppExtensionService implements RuleContext {
search: any;
viewerRules: ViewerRules = {};
- private _headerActions = new BehaviorSubject>([]);
- private _toolbarActions = new BehaviorSubject>([]);
- private _viewerToolbarActions = new BehaviorSubject>([]);
- private _sharedLinkViewerToolbarActions = new BehaviorSubject>([]);
- private _contextMenuActions = new BehaviorSubject>([]);
- private _openWithActions = new BehaviorSubject>([]);
- private _createActions = new BehaviorSubject>([]);
- private _sidebarActions = new BehaviorSubject>([]);
- private _badges = new BehaviorSubject>([]);
- private _filesDocumentListPreset = new BehaviorSubject>([]);
- private _customMetadataPanels = new BehaviorSubject>([]);
- private _bulkActions = new BehaviorSubject>([]);
+ private readonly _headerActions = new BehaviorSubject>([]);
+ private readonly _toolbarActions = new BehaviorSubject>([]);
+ private readonly _viewerToolbarActions = new BehaviorSubject>([]);
+ private readonly _sharedLinkViewerToolbarActions = new BehaviorSubject>([]);
+ private readonly _contextMenuActions = new BehaviorSubject>([]);
+ private readonly _openWithActions = new BehaviorSubject>([]);
+ private readonly _createActions = new BehaviorSubject>([]);
+ private readonly _sidebarActions = new BehaviorSubject>([]);
+ private readonly _badges = new BehaviorSubject>([]);
+ private readonly _filesDocumentListPreset = new BehaviorSubject>([]);
+ private readonly _customMetadataPanels = new BehaviorSubject>([]);
+ private readonly _bulkActions = new BehaviorSubject>([]);
private readonly _userProfileSections = new BehaviorSubject>([]);
documentListPresets: {
@@ -125,17 +135,7 @@ export class AppExtensionService implements RuleContext {
config: ExtensionConfig;
- constructor(
- public auth: AuthenticationService,
- protected store: Store,
- protected loader: ExtensionLoaderService,
- protected extensions: ExtensionService,
- public permissions: NodePermissionService,
- public appConfig: AppConfigService,
- protected matIconRegistry: MatIconRegistry,
- protected sanitizer: DomSanitizer,
- protected logger: LogService
- ) {
+ constructor() {
this.references$ = this._references.asObservable();
this.store.select(getRuleContext).subscribe((result) => {
diff --git a/projects/aca-shared/src/lib/services/app.service.ts b/projects/aca-shared/src/lib/services/app.service.ts
index 11fc80f8a..8bb0f244b 100644
--- a/projects/aca-shared/src/lib/services/app.service.ts
+++ b/projects/aca-shared/src/lib/services/app.service.ts
@@ -58,13 +58,31 @@ import { MatDialog } from '@angular/material/dialog';
})
// After moving shell to ADF to core, AppService will implement ShellAppService
export class AppService implements ShellAppService {
- private notificationService = inject(NotificationService);
- private matDialog = inject(MatDialog);
- private ready: BehaviorSubject;
+ preferencesService = inject(UserPreferencesService);
+ private readonly authenticationService = inject(AuthenticationService);
+ private readonly store = inject>(Store);
+ private readonly router = inject(Router);
+ private readonly activatedRoute = inject(ActivatedRoute);
+ private readonly config = inject(AppConfigService);
+ private readonly pageTitle = inject(PageTitleService);
+ private readonly alfrescoApiService = inject(AlfrescoApiService);
+ private readonly uploadService = inject(UploadService);
+ private readonly routerExtensionService = inject(RouterExtensionService);
+ private readonly contentApi = inject(ContentApiService);
+ private readonly sharedLinksApiService = inject(SharedLinksApiService);
+ private readonly overlayContainer = inject(OverlayContainer);
+ private readonly acaMobileAppSwitcherService = inject(AcaMobileAppSwitcherService);
+ private readonly appSettingsService = inject(AppSettingsService);
+ private readonly userProfileService = inject(UserProfileService);
+ private readonly storage = inject(StorageService);
+
+ private readonly notificationService = inject(NotificationService);
+ private readonly matDialog = inject(MatDialog);
+ private readonly ready: BehaviorSubject;
ready$: Observable;
- private pageHeading = new BehaviorSubject('');
+ private readonly pageHeading = new BehaviorSubject('');
/** @deprecated page title is updated automatically */
pageHeading$ = this.pageHeading.asObservable();
@@ -82,26 +100,10 @@ export class AppService implements ShellAppService {
return this.config.get('auth.withCredentials', false);
}
- constructor(
- public preferencesService: UserPreferencesService,
- private authenticationService: AuthenticationService,
- private store: Store,
- private router: Router,
- private activatedRoute: ActivatedRoute,
- private config: AppConfigService,
- private pageTitle: PageTitleService,
- private alfrescoApiService: AlfrescoApiService,
- private uploadService: UploadService,
- private routerExtensionService: RouterExtensionService,
- private contentApi: ContentApiService,
- private sharedLinksApiService: SharedLinksApiService,
- private overlayContainer: OverlayContainer,
- searchQueryBuilderService: SearchQueryBuilderService,
- private acaMobileAppSwitcherService: AcaMobileAppSwitcherService,
- private appSettingsService: AppSettingsService,
- private readonly userProfileService: UserProfileService,
- private readonly storage: StorageService
- ) {
+ constructor() {
+ const searchQueryBuilderService = inject(SearchQueryBuilderService);
+ const acaMobileAppSwitcherService = this.acaMobileAppSwitcherService;
+
this.ready = new BehaviorSubject(this.authenticationService.isLoggedIn() || this.withCredentials);
this.ready$ = this.ready.asObservable();
diff --git a/projects/aca-shared/src/lib/services/auto-download.service.ts b/projects/aca-shared/src/lib/services/auto-download.service.ts
index 0bbe1daa5..33a5baf75 100644
--- a/projects/aca-shared/src/lib/services/auto-download.service.ts
+++ b/projects/aca-shared/src/lib/services/auto-download.service.ts
@@ -33,7 +33,7 @@ const BYTES_TO_MB_CONVERSION_VALUE = 1048576;
providedIn: 'root'
})
export class AutoDownloadService {
- private dialog = inject(MatDialog);
+ private readonly dialog = inject(MatDialog);
private shouldDownload(node: NodeEntry, threshold: number): boolean {
const fileSizeInBytes = node?.entry?.content?.sizeInBytes || 0;
diff --git a/projects/aca-shared/src/lib/services/content-api.service.ts b/projects/aca-shared/src/lib/services/content-api.service.ts
index 60669260b..0317e03ce 100644
--- a/projects/aca-shared/src/lib/services/content-api.service.ts
+++ b/projects/aca-shared/src/lib/services/content-api.service.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { Injectable } from '@angular/core';
+import { Injectable, inject } from '@angular/core';
import { UserPreferencesService } from '@alfresco/adf-core';
import { AlfrescoApiService } from '@alfresco/adf-content-services';
import { Observable, from } from 'rxjs';
@@ -61,6 +61,9 @@ import { map } from 'rxjs/operators';
providedIn: 'root'
})
export class ContentApiService {
+ private readonly api = inject(AlfrescoApiService);
+ private readonly preferences = inject(UserPreferencesService);
+
@LazyApi((self: ContentApiService) => new NodesApi(self.api.getInstance()))
declare nodesApi: NodesApi;
@@ -91,11 +94,6 @@ export class ContentApiService {
@LazyApi((self: ContentApiService) => new VersionsApi(self.api.getInstance()))
declare versionsApi: VersionsApi;
- constructor(
- private readonly api: AlfrescoApiService,
- private readonly preferences: UserPreferencesService
- ) {}
-
/**
* Moves a node to the trashcan.
*
diff --git a/projects/aca-shared/src/lib/services/navigation-history.service.ts b/projects/aca-shared/src/lib/services/navigation-history.service.ts
index 5bb175514..0531fa8d8 100644
--- a/projects/aca-shared/src/lib/services/navigation-history.service.ts
+++ b/projects/aca-shared/src/lib/services/navigation-history.service.ts
@@ -22,16 +22,16 @@
* from Hyland Software. If not, see .
*/
-import { Injectable } from '@angular/core';
+import { Injectable, inject } from '@angular/core';
import { NavigationEnd, Router } from '@angular/router';
import { filter, startWith } from 'rxjs/operators';
import { Observable } from 'rxjs';
@Injectable({ providedIn: 'root' })
export class NavigationHistoryService {
- history: string[] = [];
+ private readonly router = inject(Router);
- constructor(private router: Router) {}
+ history: string[] = [];
listenToRouteChanges(): Observable {
return this.router.events.pipe(
diff --git a/projects/aca-shared/src/lib/services/node-permission.service.ts b/projects/aca-shared/src/lib/services/node-permission.service.ts
index 2ea20c650..7be8bcb4c 100644
--- a/projects/aca-shared/src/lib/services/node-permission.service.ts
+++ b/projects/aca-shared/src/lib/services/node-permission.service.ts
@@ -39,7 +39,7 @@ export interface PermissionOptions {
export class NodePermissionService implements NodePermissions {
static readonly DEFAULT_OPERATION = 'OR';
- private defaultOptions: PermissionOptions = {
+ private readonly defaultOptions: PermissionOptions = {
operation: NodePermissionService.DEFAULT_OPERATION,
target: null
};
diff --git a/projects/aca-shared/src/lib/services/router.extension.service.ts b/projects/aca-shared/src/lib/services/router.extension.service.ts
index 3eb18b960..5f15312d7 100644
--- a/projects/aca-shared/src/lib/services/router.extension.service.ts
+++ b/projects/aca-shared/src/lib/services/router.extension.service.ts
@@ -22,7 +22,7 @@
* from Hyland Software. If not, see .
*/
-import { Injectable, Type } from '@angular/core';
+import { Injectable, Type, inject } from '@angular/core';
import { ExtensionService } from '@alfresco/adf-extensions';
import { ExtensionRoute } from '../models/types';
import { Router } from '@angular/router';
@@ -31,16 +31,14 @@ import { Router } from '@angular/router';
providedIn: 'root'
})
export class RouterExtensionService {
+ private readonly router = inject(Router);
+ protected readonly extensions = inject(ExtensionService);
+
defaults = {
layout: 'app.layout.main',
auth: ['app.auth', 'app.extensions.dataLoaderGuard']
};
- constructor(
- private readonly router: Router,
- protected readonly extensions: ExtensionService
- ) {}
-
mapExtensionRoutes() {
const routesWithoutParent = [];
this.getApplicationRoutes().forEach((extensionRoute: ExtensionRoute) => {
diff --git a/projects/aca-shared/src/lib/services/user-profile.service.ts b/projects/aca-shared/src/lib/services/user-profile.service.ts
index a90c42cf3..1e7d40a2c 100644
--- a/projects/aca-shared/src/lib/services/user-profile.service.ts
+++ b/projects/aca-shared/src/lib/services/user-profile.service.ts
@@ -30,13 +30,13 @@ import { PeopleApi, LazyApi } from '@alfresco/js-api';
@Injectable({ providedIn: 'root' })
export class UserProfileService {
- private api = inject(AlfrescoApiService);
- private groupService = inject(GroupService);
+ private readonly api = inject(AlfrescoApiService);
+ private readonly groupService = inject(GroupService);
@LazyApi((self: UserProfileService) => new PeopleApi(self.api.getInstance()))
- declare private peopleApi: PeopleApi;
+ declare private readonly peopleApi: PeopleApi;
- private userProfile = new BehaviorSubject(null);
+ private readonly userProfile = new BehaviorSubject(null);
userProfile$ = this.userProfile.asObservable();
/**
diff --git a/projects/aca-shared/store/src/effects/router.effects.ts b/projects/aca-shared/store/src/effects/router.effects.ts
index b82c65143..8d8c135e7 100644
--- a/projects/aca-shared/store/src/effects/router.effects.ts
+++ b/projects/aca-shared/store/src/effects/router.effects.ts
@@ -34,10 +34,10 @@ import { NotificationService } from '@alfresco/adf-core';
@Injectable()
export class RouterEffects {
- private notificationService = inject(NotificationService);
- private actions$ = inject(Actions);
- private router = inject(Router);
- private location = inject(Location);
+ private readonly notificationService = inject(NotificationService);
+ private readonly actions$ = inject(Actions);
+ private readonly router = inject(Router);
+ private readonly location = inject(Location);
navigateUrl$ = createEffect(
() =>