From 4a236906eb6f487a9a475d70b808698dadb145f9 Mon Sep 17 00:00:00 2001 From: Michael Spalti Date: Mon, 6 May 2024 16:19:03 -0700 Subject: [PATCH 01/63] Updated browser init to update cache after external auth. --- src/modules/app/browser-init.service.ts | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/src/modules/app/browser-init.service.ts b/src/modules/app/browser-init.service.ts index 014a8f5daa..8cd869e15f 100644 --- a/src/modules/app/browser-init.service.ts +++ b/src/modules/app/browser-init.service.ts @@ -32,9 +32,11 @@ import { AppState } from '../../app/app.reducer'; import { BreadcrumbsService } from '../../app/breadcrumbs/breadcrumbs.service'; import { AuthService } from '../../app/core/auth/auth.service'; import { coreSelector } from '../../app/core/core.selectors'; +import { RequestService } from '../../app/core/data/request.service'; import { RootDataService } from '../../app/core/data/root-data.service'; import { LocaleService } from '../../app/core/locale/locale.service'; import { HeadTagService } from '../../app/core/metadata/head-tag.service'; +import { HALEndpointService } from '../../app/core/shared/hal-endpoint.service'; import { CorrelationIdService } from '../../app/correlation-id/correlation-id.service'; import { InitService } from '../../app/init.service'; import { KlaroService } from '../../app/shared/cookies/klaro.service'; @@ -81,6 +83,9 @@ export class BrowserInitService extends InitService { protected menuService: MenuService, private rootDataService: RootDataService, protected router: Router, + private requestService: RequestService, + private halService: HALEndpointService, + ) { super( store, @@ -169,17 +174,15 @@ export class BrowserInitService extends InitService { } /** - * During an external authentication flow invalidate the SSR transferState + * During an external authentication flow invalidate the * data in the cache. This allows the app to fetch fresh content. * @private */ private externalAuthCheck() { - this.sub = this.authService.isExternalAuthentication().pipe( filter((externalAuth: boolean) => externalAuth), ).subscribe(() => { - // Clear the transferState data. - this.rootDataService.invalidateRootCache(); + this.requestService.setStaleByHrefSubstring(this.halService.getRootHref()); this.authService.setExternalAuthStatus(false); }, ); From 96748b9bacd8540af53bf7cf6e067b066c43128c Mon Sep 17 00:00:00 2001 From: Sascha Szott Date: Wed, 20 Mar 2024 11:39:17 +0100 Subject: [PATCH 02/63] added missing interfaces --- ...lection-admin-search-result-grid-element.component.ts | 9 ++++++--- ...mmunity-admin-search-result-grid-element.component.ts | 9 ++++++--- ...lection-admin-search-result-list-element.component.ts | 9 ++++++--- ...mmunity-admin-search-result-list-element.component.ts | 9 ++++++--- .../collection-curate/collection-curate.component.ts | 7 +++++-- .../collection-source-controls.component.ts | 2 +- .../forgot-password-form.component.ts | 7 +++++-- .../item-register-doi/item-register-doi.component.ts | 7 +++++-- .../item-version-history.component.ts | 7 +++++-- .../simple/related-items/related-items-component.ts | 3 ++- .../date-value-input/date-value-input.component.ts | 5 +++-- .../string-value-input/string-value-input.component.ts | 5 +++-- .../process-parameters/process-parameters.component.ts | 5 +++-- .../dso-edit-menu-expandable-section.component.ts | 3 ++- src/app/shared/error/error.component.ts | 8 +++++--- .../dynamic-lookup-relation-selection-tab.component.ts | 5 +++-- .../access-status-badge/access-status-badge.component.ts | 4 +++- ...rkflow-item-search-result-detail-element.component.ts | 9 ++++++--- ...kspace-item-search-result-detail-element.component.ts | 9 ++++++--- .../item/item-search-result-grid-element.component.ts | 7 +++++-- .../identifier-data/identifier-data.component.ts | 3 ++- ...imed-approved-search-result-list-element.component.ts | 5 +++-- ...imed-declined-search-result-list-element.component.ts | 5 +++-- ...workflow-item-search-result-list-element.component.ts | 5 +++-- ...orkspace-item-search-result-list-element.component.ts | 5 +++-- .../collection-search-result-list-element.component.ts | 7 +++++-- .../community-search-result-list-element.component.ts | 8 +++++--- .../sidebar-search-list-element.component.ts | 7 +++++-- .../abstract-paginated-drag-and-drop-list.component.ts | 5 +++-- src/app/shared/upload/uploader/uploader.component.ts | 8 +++++--- .../identifiers/section-identifiers.component.ts | 6 +++--- 31 files changed, 126 insertions(+), 67 deletions(-) diff --git a/src/app/admin/admin-search-page/admin-search-results/admin-search-result-grid-element/collection-search-result/collection-admin-search-result-grid-element.component.ts b/src/app/admin/admin-search-page/admin-search-results/admin-search-result-grid-element/collection-search-result/collection-admin-search-result-grid-element.component.ts index 172226dd07..38352e7816 100644 --- a/src/app/admin/admin-search-page/admin-search-results/admin-search-result-grid-element/collection-search-result/collection-admin-search-result-grid-element.component.ts +++ b/src/app/admin/admin-search-page/admin-search-results/admin-search-result-grid-element/collection-search-result/collection-admin-search-result-grid-element.component.ts @@ -1,4 +1,7 @@ -import { Component } from '@angular/core'; +import { + Component, + OnInit, +} from '@angular/core'; import { RouterLink } from '@angular/router'; import { getCollectionEditRoute } from '../../../../../collection-page/collection-page-routing-paths'; @@ -21,10 +24,10 @@ import { SearchResultGridElementComponent } from '../../../../../shared/object-g /** * The component for displaying a list element for a collection search result on the admin search page */ -export class CollectionAdminSearchResultGridElementComponent extends SearchResultGridElementComponent { +export class CollectionAdminSearchResultGridElementComponent extends SearchResultGridElementComponent implements OnInit { editPath: string; - ngOnInit() { + ngOnInit(): void { super.ngOnInit(); this.editPath = getCollectionEditRoute(this.dso.uuid); } diff --git a/src/app/admin/admin-search-page/admin-search-results/admin-search-result-grid-element/community-search-result/community-admin-search-result-grid-element.component.ts b/src/app/admin/admin-search-page/admin-search-results/admin-search-result-grid-element/community-search-result/community-admin-search-result-grid-element.component.ts index 50be35229d..509c1e9266 100644 --- a/src/app/admin/admin-search-page/admin-search-results/admin-search-result-grid-element/community-search-result/community-admin-search-result-grid-element.component.ts +++ b/src/app/admin/admin-search-page/admin-search-results/admin-search-result-grid-element/community-search-result/community-admin-search-result-grid-element.component.ts @@ -1,4 +1,7 @@ -import { Component } from '@angular/core'; +import { + Component, + OnInit, +} from '@angular/core'; import { RouterLink } from '@angular/router'; import { getCommunityEditRoute } from '../../../../../community-page/community-page-routing-paths'; @@ -21,10 +24,10 @@ import { SearchResultGridElementComponent } from '../../../../../shared/object-g /** * The component for displaying a list element for a community search result on the admin search page */ -export class CommunityAdminSearchResultGridElementComponent extends SearchResultGridElementComponent { +export class CommunityAdminSearchResultGridElementComponent extends SearchResultGridElementComponent implements OnInit { editPath: string; - ngOnInit() { + ngOnInit(): void { super.ngOnInit(); this.editPath = getCommunityEditRoute(this.dso.uuid); } diff --git a/src/app/admin/admin-search-page/admin-search-results/admin-search-result-list-element/collection-search-result/collection-admin-search-result-list-element.component.ts b/src/app/admin/admin-search-page/admin-search-results/admin-search-result-list-element/collection-search-result/collection-admin-search-result-list-element.component.ts index 37afbf14fe..0924379ea5 100644 --- a/src/app/admin/admin-search-page/admin-search-results/admin-search-result-list-element/collection-search-result/collection-admin-search-result-list-element.component.ts +++ b/src/app/admin/admin-search-page/admin-search-results/admin-search-result-list-element/collection-search-result/collection-admin-search-result-list-element.component.ts @@ -1,4 +1,7 @@ -import { Component } from '@angular/core'; +import { + Component, + OnInit, +} from '@angular/core'; import { RouterLink } from '@angular/router'; import { TranslateModule } from '@ngx-translate/core'; @@ -22,10 +25,10 @@ import { SearchResultListElementComponent } from '../../../../../shared/object-l /** * The component for displaying a list element for a collection search result on the admin search page */ -export class CollectionAdminSearchResultListElementComponent extends SearchResultListElementComponent { +export class CollectionAdminSearchResultListElementComponent extends SearchResultListElementComponent implements OnInit { editPath: string; - ngOnInit() { + ngOnInit(): void { super.ngOnInit(); this.editPath = getCollectionEditRoute(this.dso.uuid); } diff --git a/src/app/admin/admin-search-page/admin-search-results/admin-search-result-list-element/community-search-result/community-admin-search-result-list-element.component.ts b/src/app/admin/admin-search-page/admin-search-results/admin-search-result-list-element/community-search-result/community-admin-search-result-list-element.component.ts index 5861f15c1f..c4146dbd60 100644 --- a/src/app/admin/admin-search-page/admin-search-results/admin-search-result-list-element/community-search-result/community-admin-search-result-list-element.component.ts +++ b/src/app/admin/admin-search-page/admin-search-results/admin-search-result-list-element/community-search-result/community-admin-search-result-list-element.component.ts @@ -1,4 +1,7 @@ -import { Component } from '@angular/core'; +import { + Component, + OnInit, +} from '@angular/core'; import { RouterLink } from '@angular/router'; import { TranslateModule } from '@ngx-translate/core'; @@ -22,10 +25,10 @@ import { SearchResultListElementComponent } from '../../../../../shared/object-l /** * The component for displaying a list element for a community search result on the admin search page */ -export class CommunityAdminSearchResultListElementComponent extends SearchResultListElementComponent { +export class CommunityAdminSearchResultListElementComponent extends SearchResultListElementComponent implements OnInit { editPath: string; - ngOnInit() { + ngOnInit(): void { super.ngOnInit(); this.editPath = getCommunityEditRoute(this.dso.uuid); } diff --git a/src/app/collection-page/edit-collection-page/collection-curate/collection-curate.component.ts b/src/app/collection-page/edit-collection-page/collection-curate/collection-curate.component.ts index 14ba01421b..370506e473 100644 --- a/src/app/collection-page/edit-collection-page/collection-curate/collection-curate.component.ts +++ b/src/app/collection-page/edit-collection-page/collection-curate/collection-curate.component.ts @@ -1,5 +1,8 @@ import { AsyncPipe } from '@angular/common'; -import { Component } from '@angular/core'; +import { + Component, + OnInit, +} from '@angular/core'; import { ActivatedRoute } from '@angular/router'; import { TranslateModule } from '@ngx-translate/core'; import { Observable } from 'rxjs'; @@ -28,7 +31,7 @@ import { hasValue } from '../../../shared/empty.util'; ], standalone: true, }) -export class CollectionCurateComponent { +export class CollectionCurateComponent implements OnInit { dsoRD$: Observable>; collectionName$: Observable; diff --git a/src/app/collection-page/edit-collection-page/collection-source/collection-source-controls/collection-source-controls.component.ts b/src/app/collection-page/edit-collection-page/collection-source/collection-source-controls/collection-source-controls.component.ts index 3b51a8e9d9..fdd65a43c7 100644 --- a/src/app/collection-page/edit-collection-page/collection-source/collection-source-controls/collection-source-controls.component.ts +++ b/src/app/collection-page/edit-collection-page/collection-source/collection-source-controls/collection-source-controls.component.ts @@ -95,7 +95,7 @@ export class CollectionSourceControlsComponent implements OnInit, OnDestroy { ) { } - ngOnInit() { + ngOnInit(): void { // ensure the contentSource gets updated after being set to stale this.contentSource$ = this.collectionService.findByHref(this.collection._links.self.href, false).pipe( getAllSucceededRemoteDataPayload(), diff --git a/src/app/forgot-password/forgot-password-form/forgot-password-form.component.ts b/src/app/forgot-password/forgot-password-form/forgot-password-form.component.ts index 442e4bf9fa..7b2b1beedd 100644 --- a/src/app/forgot-password/forgot-password-form/forgot-password-form.component.ts +++ b/src/app/forgot-password/forgot-password-form/forgot-password-form.component.ts @@ -2,7 +2,10 @@ import { AsyncPipe, NgIf, } from '@angular/common'; -import { Component } from '@angular/core'; +import { + Component, + OnInit, +} from '@angular/core'; import { ActivatedRoute, Router, @@ -45,7 +48,7 @@ import { BrowserOnlyPipe } from '../../shared/utils/browser-only.pipe'; /** * Component for a user to enter a new password for a forgot token. */ -export class ForgotPasswordFormComponent { +export class ForgotPasswordFormComponent implements OnInit { registration$: Observable; diff --git a/src/app/item-page/edit-item-page/item-register-doi/item-register-doi.component.ts b/src/app/item-page/edit-item-page/item-register-doi/item-register-doi.component.ts index 9acc12e95d..d9e0283267 100644 --- a/src/app/item-page/edit-item-page/item-register-doi/item-register-doi.component.ts +++ b/src/app/item-page/edit-item-page/item-register-doi/item-register-doi.component.ts @@ -3,7 +3,10 @@ import { NgForOf, NgIf, } from '@angular/common'; -import { Component } from '@angular/core'; +import { + Component, + OnInit, +} from '@angular/core'; import { ActivatedRoute, Router, @@ -47,7 +50,7 @@ import { AbstractSimpleItemActionComponent } from '../simple-item-action/abstrac /** * Component responsible for rendering the Item Register DOI page */ -export class ItemRegisterDoiComponent extends AbstractSimpleItemActionComponent { +export class ItemRegisterDoiComponent extends AbstractSimpleItemActionComponent implements OnInit { protected messageKey = 'register-doi'; doiToUpdateMessage = 'item.edit.' + this.messageKey + '.to-update'; diff --git a/src/app/item-page/edit-item-page/item-version-history/item-version-history.component.ts b/src/app/item-page/edit-item-page/item-version-history/item-version-history.component.ts index 9c61231164..a414af0ce4 100644 --- a/src/app/item-page/edit-item-page/item-version-history/item-version-history.component.ts +++ b/src/app/item-page/edit-item-page/item-version-history/item-version-history.component.ts @@ -2,7 +2,10 @@ import { AsyncPipe, NgIf, } from '@angular/common'; -import { Component } from '@angular/core'; +import { + Component, + OnInit, +} from '@angular/core'; import { ActivatedRoute } from '@angular/router'; import { Observable } from 'rxjs'; import { map } from 'rxjs/operators'; @@ -28,7 +31,7 @@ import { ItemVersionsComponent } from '../../versions/item-versions.component'; /** * Component for listing and managing an item's version history */ -export class ItemVersionHistoryComponent { +export class ItemVersionHistoryComponent implements OnInit { /** * The item to display the version history for */ diff --git a/src/app/item-page/simple/related-items/related-items-component.ts b/src/app/item-page/simple/related-items/related-items-component.ts index b65f903a5d..434093ba2a 100644 --- a/src/app/item-page/simple/related-items/related-items-component.ts +++ b/src/app/item-page/simple/related-items/related-items-component.ts @@ -10,6 +10,7 @@ import { ElementRef, Inject, Input, + OnInit, PLATFORM_ID, } from '@angular/core'; import { TranslateModule } from '@ngx-translate/core'; @@ -43,7 +44,7 @@ import { AbstractIncrementalListComponent } from '../abstract-incremental-list/a * This component is used for displaying relations between items * It expects a parent item and relationship type, as well as a label to display on top */ -export class RelatedItemsComponent extends AbstractIncrementalListComponent>>> { +export class RelatedItemsComponent extends AbstractIncrementalListComponent>>> implements OnInit { /** * The parent of the list of related items to display diff --git a/src/app/process-page/form/process-parameters/parameter-value-input/date-value-input/date-value-input.component.ts b/src/app/process-page/form/process-parameters/parameter-value-input/date-value-input/date-value-input.component.ts index 29b2a85d57..74ee21471c 100644 --- a/src/app/process-page/form/process-parameters/parameter-value-input/date-value-input/date-value-input.component.ts +++ b/src/app/process-page/form/process-parameters/parameter-value-input/date-value-input/date-value-input.component.ts @@ -2,6 +2,7 @@ import { NgIf } from '@angular/common'; import { Component, Input, + OnInit, Optional, } from '@angular/core'; import { @@ -27,7 +28,7 @@ import { ValueInputComponent } from '../value-input.component'; standalone: true, imports: [FormsModule, NgIf, TranslateModule], }) -export class DateValueInputComponent extends ValueInputComponent { +export class DateValueInputComponent extends ValueInputComponent implements OnInit { /** * The current value of the date string */ @@ -38,7 +39,7 @@ export class DateValueInputComponent extends ValueInputComponent { */ @Input() initialValue; - ngOnInit() { + ngOnInit(): void { this.value = this.initialValue; } diff --git a/src/app/process-page/form/process-parameters/parameter-value-input/string-value-input/string-value-input.component.ts b/src/app/process-page/form/process-parameters/parameter-value-input/string-value-input/string-value-input.component.ts index d19e149311..d7fa528544 100644 --- a/src/app/process-page/form/process-parameters/parameter-value-input/string-value-input/string-value-input.component.ts +++ b/src/app/process-page/form/process-parameters/parameter-value-input/string-value-input/string-value-input.component.ts @@ -2,6 +2,7 @@ import { NgIf } from '@angular/common'; import { Component, Input, + OnInit, Optional, } from '@angular/core'; import { @@ -27,7 +28,7 @@ import { ValueInputComponent } from '../value-input.component'; standalone: true, imports: [FormsModule, NgIf, TranslateModule], }) -export class StringValueInputComponent extends ValueInputComponent { +export class StringValueInputComponent extends ValueInputComponent implements OnInit { /** * The current value of the string */ @@ -38,7 +39,7 @@ export class StringValueInputComponent extends ValueInputComponent { */ @Input() initialValue; - ngOnInit() { + ngOnInit(): void { this.value = this.initialValue; } diff --git a/src/app/process-page/form/process-parameters/process-parameters.component.ts b/src/app/process-page/form/process-parameters/process-parameters.component.ts index 0b72b086c1..ac174e338b 100644 --- a/src/app/process-page/form/process-parameters/process-parameters.component.ts +++ b/src/app/process-page/form/process-parameters/process-parameters.component.ts @@ -7,6 +7,7 @@ import { EventEmitter, Input, OnChanges, + OnInit, Optional, Output, SimpleChanges, @@ -39,7 +40,7 @@ import { ParameterSelectComponent } from './parameter-select/parameter-select.co standalone: true, imports: [NgIf, NgFor, ParameterSelectComponent, TranslateModule], }) -export class ProcessParametersComponent implements OnChanges { +export class ProcessParametersComponent implements OnChanges, OnInit { /** * The currently selected script */ @@ -59,7 +60,7 @@ export class ProcessParametersComponent implements OnChanges { */ parameterValues: ProcessParameter[]; - ngOnInit() { + ngOnInit(): void { if (hasValue(this.initialParams)) { this.parameterValues = this.initialParams; } diff --git a/src/app/shared/dso-page/dso-edit-menu/dso-edit-expandable-menu-section/dso-edit-menu-expandable-section.component.ts b/src/app/shared/dso-page/dso-edit-menu/dso-edit-expandable-menu-section/dso-edit-menu-expandable-section.component.ts index 8f458d4e56..94d0ddd260 100644 --- a/src/app/shared/dso-page/dso-edit-menu/dso-edit-expandable-menu-section/dso-edit-menu-expandable-section.component.ts +++ b/src/app/shared/dso-page/dso-edit-menu/dso-edit-expandable-menu-section/dso-edit-menu-expandable-section.component.ts @@ -8,6 +8,7 @@ import { Component, Inject, Injector, + OnInit, } from '@angular/core'; import { Router } from '@angular/router'; import { @@ -34,7 +35,7 @@ import { MenuService } from '../../../menu/menu.service'; standalone: true, imports: [NgbDropdownModule, NgbTooltipModule, NgFor, NgIf, NgComponentOutlet, TranslateModule, AsyncPipe], }) -export class DsoEditMenuExpandableSectionComponent extends MenuSectionComponent { +export class DsoEditMenuExpandableSectionComponent extends MenuSectionComponent implements OnInit { menuID: MenuID = MenuID.DSO_EDIT; itemModel; diff --git a/src/app/shared/error/error.component.ts b/src/app/shared/error/error.component.ts index 900ea67887..168415c0b1 100644 --- a/src/app/shared/error/error.component.ts +++ b/src/app/shared/error/error.component.ts @@ -1,6 +1,8 @@ import { Component, Input, + OnDestroy, + OnInit, } from '@angular/core'; import { TranslateService } from '@ngx-translate/core'; import { Subscription } from 'rxjs'; @@ -15,7 +17,7 @@ import { AlertType } from '../alert/alert-type'; standalone: true, imports: [AlertComponent], }) -export class ErrorComponent { +export class ErrorComponent implements OnDestroy, OnInit { @Input() message = 'Error...'; @@ -31,7 +33,7 @@ export class ErrorComponent { } - ngOnInit() { + ngOnInit(): void { if (this.message === undefined) { this.subscription = this.translate.get('error.default').subscribe((message: string) => { this.message = message; @@ -39,7 +41,7 @@ export class ErrorComponent { } } - ngOnDestroy() { + ngOnDestroy(): void { if (this.subscription !== undefined) { this.subscription.unsubscribe(); } diff --git a/src/app/shared/form/builder/ds-dynamic-form-ui/relation-lookup-modal/selection-tab/dynamic-lookup-relation-selection-tab.component.ts b/src/app/shared/form/builder/ds-dynamic-form-ui/relation-lookup-modal/selection-tab/dynamic-lookup-relation-selection-tab.component.ts index d1e516513b..51229be599 100644 --- a/src/app/shared/form/builder/ds-dynamic-form-ui/relation-lookup-modal/selection-tab/dynamic-lookup-relation-selection-tab.component.ts +++ b/src/app/shared/form/builder/ds-dynamic-form-ui/relation-lookup-modal/selection-tab/dynamic-lookup-relation-selection-tab.component.ts @@ -6,6 +6,7 @@ import { Component, EventEmitter, Input, + OnInit, Output, } from '@angular/core'; import { Router } from '@angular/router'; @@ -57,7 +58,7 @@ import { PaginatedSearchOptions } from '../../../../../search/models/paginated-s /** * Tab for inside the lookup model that represents the currently selected relationships */ -export class DsDynamicLookupRelationSelectionTabComponent { +export class DsDynamicLookupRelationSelectionTabComponent implements OnInit { /** * A string that describes the type of relationship */ @@ -120,7 +121,7 @@ export class DsDynamicLookupRelationSelectionTabComponent { /** * Set up the selection and pagination on load */ - ngOnInit() { + ngOnInit(): void { this.resetRoute(); this.selectionRD$ = this.searchConfigService.paginatedSearchOptions .pipe( diff --git a/src/app/shared/object-collection/shared/badges/access-status-badge/access-status-badge.component.ts b/src/app/shared/object-collection/shared/badges/access-status-badge/access-status-badge.component.ts index 5b69a7e72a..0b86b782f6 100644 --- a/src/app/shared/object-collection/shared/badges/access-status-badge/access-status-badge.component.ts +++ b/src/app/shared/object-collection/shared/badges/access-status-badge/access-status-badge.component.ts @@ -5,6 +5,8 @@ import { import { Component, Input, + OnDestroy, + OnInit, } from '@angular/core'; import { TranslateModule } from '@ngx-translate/core'; import { @@ -35,7 +37,7 @@ import { AccessStatusObject } from './access-status.model'; /** * Component rendering the access status of an item as a badge */ -export class AccessStatusBadgeComponent { +export class AccessStatusBadgeComponent implements OnDestroy, OnInit { @Input() object: DSpaceObject; accessStatus$: Observable; diff --git a/src/app/shared/object-detail/my-dspace-result-detail-element/workflow-item-search-result/workflow-item-search-result-detail-element.component.ts b/src/app/shared/object-detail/my-dspace-result-detail-element/workflow-item-search-result/workflow-item-search-result-detail-element.component.ts index cd28223013..1453d9246e 100644 --- a/src/app/shared/object-detail/my-dspace-result-detail-element/workflow-item-search-result/workflow-item-search-result-detail-element.component.ts +++ b/src/app/shared/object-detail/my-dspace-result-detail-element/workflow-item-search-result/workflow-item-search-result-detail-element.component.ts @@ -1,4 +1,7 @@ -import { Component } from '@angular/core'; +import { + Component, + OnInit, +} from '@angular/core'; import { Observable } from 'rxjs'; import { find } from 'rxjs/operators'; import { Context } from 'src/app/core/shared/context.model'; @@ -29,7 +32,7 @@ import { SearchResultDetailElementComponent } from '../search-result-detail-elem }) @listableObjectComponent(WorkflowItemSearchResult, ViewMode.DetailedListElement) -export class WorkflowItemSearchResultDetailElementComponent extends SearchResultDetailElementComponent { +export class WorkflowItemSearchResultDetailElementComponent extends SearchResultDetailElementComponent implements OnInit { /** * The item object that belonging to the result object @@ -51,7 +54,7 @@ export class WorkflowItemSearchResultDetailElementComponent extends SearchResult /** * Initialize all instance variables */ - ngOnInit() { + ngOnInit(): void { super.ngOnInit(); this.linkService.resolveLink(this.dso, followLink('item')); this.initItem(this.dso.item as Observable>); diff --git a/src/app/shared/object-detail/my-dspace-result-detail-element/workspace-item-search-result/workspace-item-search-result-detail-element.component.ts b/src/app/shared/object-detail/my-dspace-result-detail-element/workspace-item-search-result/workspace-item-search-result-detail-element.component.ts index 5c51e3464f..b88cef64b5 100644 --- a/src/app/shared/object-detail/my-dspace-result-detail-element/workspace-item-search-result/workspace-item-search-result-detail-element.component.ts +++ b/src/app/shared/object-detail/my-dspace-result-detail-element/workspace-item-search-result/workspace-item-search-result-detail-element.component.ts @@ -1,4 +1,7 @@ -import { Component } from '@angular/core'; +import { + Component, + OnInit, +} from '@angular/core'; import { Observable } from 'rxjs'; import { find } from 'rxjs/operators'; @@ -29,7 +32,7 @@ import { SearchResultDetailElementComponent } from '../search-result-detail-elem }) @listableObjectComponent(WorkspaceItemSearchResult, ViewMode.DetailedListElement) -export class WorkspaceItemSearchResultDetailElementComponent extends SearchResultDetailElementComponent { +export class WorkspaceItemSearchResultDetailElementComponent extends SearchResultDetailElementComponent implements OnInit { /** * The item object that belonging to the result object @@ -51,7 +54,7 @@ export class WorkspaceItemSearchResultDetailElementComponent extends SearchResul /** * Initialize all instance variables */ - ngOnInit() { + ngOnInit(): void { super.ngOnInit(); this.linkService.resolveLink(this.dso, followLink('item')); this.initItem(this.dso.item as Observable>); diff --git a/src/app/shared/object-grid/search-result-grid-element/item-search-result/item/item-search-result-grid-element.component.ts b/src/app/shared/object-grid/search-result-grid-element/item-search-result/item/item-search-result-grid-element.component.ts index c9c56daff1..a0c8ec84ce 100644 --- a/src/app/shared/object-grid/search-result-grid-element/item-search-result/item/item-search-result-grid-element.component.ts +++ b/src/app/shared/object-grid/search-result-grid-element/item-search-result/item/item-search-result-grid-element.component.ts @@ -3,7 +3,10 @@ import { NgFor, NgIf, } from '@angular/common'; -import { Component } from '@angular/core'; +import { + Component, + OnInit, +} from '@angular/core'; import { RouterLink } from '@angular/router'; import { TranslateModule } from '@ngx-translate/core'; @@ -35,7 +38,7 @@ import { SearchResultGridElementComponent } from '../../search-result-grid-eleme /** * The component for displaying a grid element for an item search result of the type Publication */ -export class ItemSearchResultGridElementComponent extends SearchResultGridElementComponent { +export class ItemSearchResultGridElementComponent extends SearchResultGridElementComponent implements OnInit { /** * Route to the item's page */ diff --git a/src/app/shared/object-list/identifier-data/identifier-data.component.ts b/src/app/shared/object-list/identifier-data/identifier-data.component.ts index ecc0bd1ca3..af658c6cf2 100644 --- a/src/app/shared/object-list/identifier-data/identifier-data.component.ts +++ b/src/app/shared/object-list/identifier-data/identifier-data.component.ts @@ -5,6 +5,7 @@ import { import { Component, Input, + OnInit, } from '@angular/core'; import { TranslateModule } from '@ngx-translate/core'; import { Observable } from 'rxjs'; @@ -28,7 +29,7 @@ import { IdentifierData } from './identifier-data.model'; /** * Component rendering an identifier, eg. DOI or handle */ -export class IdentifierDataComponent { +export class IdentifierDataComponent implements OnInit { @Input() item: Item; identifiers$: Observable; diff --git a/src/app/shared/object-list/my-dspace-result-list-element/claimed-search-result/claimed-approved-search-result/claimed-approved-search-result-list-element.component.ts b/src/app/shared/object-list/my-dspace-result-list-element/claimed-search-result/claimed-approved-search-result/claimed-approved-search-result-list-element.component.ts index fc024944e8..f94effe2a4 100644 --- a/src/app/shared/object-list/my-dspace-result-list-element/claimed-search-result/claimed-approved-search-result/claimed-approved-search-result-list-element.component.ts +++ b/src/app/shared/object-list/my-dspace-result-list-element/claimed-search-result/claimed-approved-search-result/claimed-approved-search-result-list-element.component.ts @@ -5,6 +5,7 @@ import { import { Component, Inject, + OnInit, } from '@angular/core'; import { TranslateModule } from '@ngx-translate/core'; import { Observable } from 'rxjs'; @@ -40,7 +41,7 @@ import { ThemedItemListPreviewComponent } from '../../item-list-preview/themed-i imports: [NgIf, ThemedItemListPreviewComponent, AsyncPipe, TranslateModule, VarDirective], }) @listableObjectComponent(ClaimedApprovedTaskSearchResult, ViewMode.ListElement) -export class ClaimedApprovedSearchResultListElementComponent extends SearchResultListElementComponent { +export class ClaimedApprovedSearchResultListElementComponent extends SearchResultListElementComponent implements OnInit { /** * A boolean representing if to show submitter information @@ -69,7 +70,7 @@ export class ClaimedApprovedSearchResultListElementComponent extends SearchResul /** * Initialize all instance variables */ - ngOnInit() { + ngOnInit(): void { super.ngOnInit(); this.linkService.resolveLinks(this.dso, followLink('workflowitem', diff --git a/src/app/shared/object-list/my-dspace-result-list-element/claimed-search-result/claimed-declined-search-result/claimed-declined-search-result-list-element.component.ts b/src/app/shared/object-list/my-dspace-result-list-element/claimed-search-result/claimed-declined-search-result/claimed-declined-search-result-list-element.component.ts index fa5f7a3a04..d69b9ecda0 100644 --- a/src/app/shared/object-list/my-dspace-result-list-element/claimed-search-result/claimed-declined-search-result/claimed-declined-search-result-list-element.component.ts +++ b/src/app/shared/object-list/my-dspace-result-list-element/claimed-search-result/claimed-declined-search-result/claimed-declined-search-result-list-element.component.ts @@ -5,6 +5,7 @@ import { import { Component, Inject, + OnInit, } from '@angular/core'; import { TranslateModule } from '@ngx-translate/core'; import { Observable } from 'rxjs'; @@ -40,7 +41,7 @@ import { ThemedItemListPreviewComponent } from '../../item-list-preview/themed-i imports: [NgIf, ThemedItemListPreviewComponent, AsyncPipe, TranslateModule, VarDirective], }) @listableObjectComponent(ClaimedDeclinedTaskSearchResult, ViewMode.ListElement) -export class ClaimedDeclinedSearchResultListElementComponent extends SearchResultListElementComponent { +export class ClaimedDeclinedSearchResultListElementComponent extends SearchResultListElementComponent implements OnInit { /** * A boolean representing if to show submitter information @@ -69,7 +70,7 @@ export class ClaimedDeclinedSearchResultListElementComponent extends SearchResul /** * Initialize all instance variables */ - ngOnInit() { + ngOnInit(): void { super.ngOnInit(); this.linkService.resolveLinks(this.dso, followLink('workflowitem', diff --git a/src/app/shared/object-list/my-dspace-result-list-element/workflow-item-search-result/workflow-item-search-result-list-element.component.ts b/src/app/shared/object-list/my-dspace-result-list-element/workflow-item-search-result/workflow-item-search-result-list-element.component.ts index 7c88dcc36d..d7f735e1ad 100644 --- a/src/app/shared/object-list/my-dspace-result-list-element/workflow-item-search-result/workflow-item-search-result-list-element.component.ts +++ b/src/app/shared/object-list/my-dspace-result-list-element/workflow-item-search-result/workflow-item-search-result-list-element.component.ts @@ -6,6 +6,7 @@ import { import { Component, Inject, + OnInit, } from '@angular/core'; import { BehaviorSubject } from 'rxjs'; @@ -43,7 +44,7 @@ import { SearchResultListElementComponent } from '../../search-result-list-eleme }) @listableObjectComponent(WorkflowItemSearchResult, ViewMode.ListElement) -export class WorkflowItemSearchResultListElementComponent extends SearchResultListElementComponent { +export class WorkflowItemSearchResultListElementComponent extends SearchResultListElementComponent implements OnInit { LinkTypes = CollectionElementLinkType; ViewModes = ViewMode; @@ -75,7 +76,7 @@ export class WorkflowItemSearchResultListElementComponent extends SearchResultLi /** * Initialize all instance variables */ - ngOnInit() { + ngOnInit(): void { super.ngOnInit(); this.deriveSearchResult(); this.showThumbnails = this.appConfig.browseBy.showThumbnails; diff --git a/src/app/shared/object-list/my-dspace-result-list-element/workspace-item-search-result/workspace-item-search-result-list-element.component.ts b/src/app/shared/object-list/my-dspace-result-list-element/workspace-item-search-result/workspace-item-search-result-list-element.component.ts index 8938064da6..4a8863d22f 100644 --- a/src/app/shared/object-list/my-dspace-result-list-element/workspace-item-search-result/workspace-item-search-result-list-element.component.ts +++ b/src/app/shared/object-list/my-dspace-result-list-element/workspace-item-search-result/workspace-item-search-result-list-element.component.ts @@ -6,6 +6,7 @@ import { import { Component, Inject, + OnInit, } from '@angular/core'; import { BehaviorSubject } from 'rxjs'; @@ -43,7 +44,7 @@ import { SearchResultListElementComponent } from '../../search-result-list-eleme }) @listableObjectComponent(WorkspaceItemSearchResult, ViewMode.ListElement) -export class WorkspaceItemSearchResultListElementComponent extends SearchResultListElementComponent { +export class WorkspaceItemSearchResultListElementComponent extends SearchResultListElementComponent implements OnInit { LinkTypes = CollectionElementLinkType; ViewModes = ViewMode; @@ -75,7 +76,7 @@ export class WorkspaceItemSearchResultListElementComponent extends SearchResult /** * Initialize all instance variables */ - ngOnInit() { + ngOnInit(): void { super.ngOnInit(); this.deriveSearchResult(); this.showThumbnails = this.appConfig.browseBy.showThumbnails; diff --git a/src/app/shared/object-list/search-result-list-element/collection-search-result/collection-search-result-list-element.component.ts b/src/app/shared/object-list/search-result-list-element/collection-search-result/collection-search-result-list-element.component.ts index 58cd875ce2..2641792b02 100644 --- a/src/app/shared/object-list/search-result-list-element/collection-search-result/collection-search-result-list-element.component.ts +++ b/src/app/shared/object-list/search-result-list-element/collection-search-result/collection-search-result-list-element.component.ts @@ -2,7 +2,10 @@ import { NgClass, NgIf, } from '@angular/common'; -import { Component } from '@angular/core'; +import { + Component, + OnInit, +} from '@angular/core'; import { RouterLink } from '@angular/router'; import { Collection } from '../../../../core/shared/collection.model'; @@ -23,7 +26,7 @@ import { SearchResultListElementComponent } from '../search-result-list-element. * Component representing a collection search result in list view */ @listableObjectComponent(CollectionSearchResult, ViewMode.ListElement) -export class CollectionSearchResultListElementComponent extends SearchResultListElementComponent { +export class CollectionSearchResultListElementComponent extends SearchResultListElementComponent implements OnInit { /** * Display thumbnails if required by configuration diff --git a/src/app/shared/object-list/search-result-list-element/community-search-result/community-search-result-list-element.component.ts b/src/app/shared/object-list/search-result-list-element/community-search-result/community-search-result-list-element.component.ts index 52d7ad6e6b..e8e3c57959 100644 --- a/src/app/shared/object-list/search-result-list-element/community-search-result/community-search-result-list-element.component.ts +++ b/src/app/shared/object-list/search-result-list-element/community-search-result/community-search-result-list-element.component.ts @@ -2,7 +2,10 @@ import { NgClass, NgIf, } from '@angular/common'; -import { Component } from '@angular/core'; +import { + Component, + OnInit, +} from '@angular/core'; import { RouterLink } from '@angular/router'; import { Community } from '../../../../core/shared/community.model'; @@ -23,13 +26,12 @@ import { SearchResultListElementComponent } from '../search-result-list-element. * Component representing a community search result in list view */ @listableObjectComponent(CommunitySearchResult, ViewMode.ListElement) -export class CommunitySearchResultListElementComponent extends SearchResultListElementComponent { +export class CommunitySearchResultListElementComponent extends SearchResultListElementComponent implements OnInit { /** * Display thumbnails if required by configuration */ showThumbnails: boolean; - ngOnInit(): void { super.ngOnInit(); this.showThumbnails = this.showThumbnails ?? this.appConfig.browseBy.showThumbnails; diff --git a/src/app/shared/object-list/sidebar-search-list-element/sidebar-search-list-element.component.ts b/src/app/shared/object-list/sidebar-search-list-element/sidebar-search-list-element.component.ts index c262dee259..e65883cd3e 100644 --- a/src/app/shared/object-list/sidebar-search-list-element/sidebar-search-list-element.component.ts +++ b/src/app/shared/object-list/sidebar-search-list-element/sidebar-search-list-element.component.ts @@ -3,7 +3,10 @@ import { NgClass, NgIf, } from '@angular/common'; -import { Component } from '@angular/core'; +import { + Component, + OnInit, +} from '@angular/core'; import { TranslateModule } from '@ngx-translate/core'; import { Observable, @@ -41,7 +44,7 @@ import { SearchResultListElementComponent } from '../search-result-list-element/ * It displays the name of the parent, title and description of the object. All of which are customizable in the child * component by overriding the relevant methods of this component */ -export class SidebarSearchListElementComponent, K extends DSpaceObject> extends SearchResultListElementComponent { +export class SidebarSearchListElementComponent, K extends DSpaceObject> extends SearchResultListElementComponent implements OnInit { /** * Observable for the title of the parent object (displayed above the object's title) */ diff --git a/src/app/shared/pagination-drag-and-drop/abstract-paginated-drag-and-drop-list.component.ts b/src/app/shared/pagination-drag-and-drop/abstract-paginated-drag-and-drop-list.component.ts index 1ebf626484..444e7bc14c 100644 --- a/src/app/shared/pagination-drag-and-drop/abstract-paginated-drag-and-drop-list.component.ts +++ b/src/app/shared/pagination-drag-and-drop/abstract-paginated-drag-and-drop-list.component.ts @@ -7,6 +7,7 @@ import { ElementRef, EventEmitter, OnDestroy, + OnInit, Output, ViewChild, } from '@angular/core'; @@ -65,7 +66,7 @@ export const compareArraysUsingFieldUuids = () => selector: 'ds-paginated-drag-drop-abstract', template: '', }) -export abstract class AbstractPaginatedDragAndDropListComponent implements OnDestroy { +export abstract class AbstractPaginatedDragAndDropListComponent implements OnInit, OnDestroy { /** * A view on the child pagination component */ @@ -142,7 +143,7 @@ export abstract class AbstractPaginatedDragAndDropListComponent { this.onFileSelected.emit(items); }); diff --git a/src/app/submission/sections/identifiers/section-identifiers.component.ts b/src/app/submission/sections/identifiers/section-identifiers.component.ts index 1483ea47b7..e297c795df 100644 --- a/src/app/submission/sections/identifiers/section-identifiers.component.ts +++ b/src/app/submission/sections/identifiers/section-identifiers.component.ts @@ -7,6 +7,7 @@ import { ChangeDetectionStrategy, Component, Inject, + OnInit, } from '@angular/core'; import { TranslateModule, @@ -47,7 +48,7 @@ import { SectionsService } from '../sections.service'; standalone: true, }) -export class SubmissionSectionIdentifiersComponent extends SectionModelComponent { +export class SubmissionSectionIdentifiersComponent extends SectionModelComponent implements OnInit { /** * The Alert categories. * @type {AlertType} @@ -76,7 +77,6 @@ export class SubmissionSectionIdentifiersComponent extends SectionModelComponent /** * Initialize instance variables. * - * @param {PaginationService} paginationService * @param {TranslateService} translate * @param {SectionsService} sectionService * @param {SubmissionService} submissionService @@ -93,7 +93,7 @@ export class SubmissionSectionIdentifiersComponent extends SectionModelComponent super(injectedCollectionId, injectedSectionData, injectedSubmissionId); } - ngOnInit() { + ngOnInit(): void { super.ngOnInit(); } From 66e1a2488b14c84b41486fabc77350f17d722b0d Mon Sep 17 00:00:00 2001 From: Andrea Barbasso <´andrea.barbasso@4science.com´> Date: Fri, 7 Jun 2024 14:58:50 +0200 Subject: [PATCH 03/63] [DURACOM-273] fix markdown rendering applying before mathjax rendering --- src/app/core/shared/client-math.service.ts | 4 +-- src/app/core/shared/math.service.spec.ts | 4 +-- src/app/core/shared/math.service.ts | 2 +- src/app/core/shared/server-math.service.ts | 2 +- src/app/shared/utils/markdown.directive.ts | 42 +++++++++++++--------- 5 files changed, 32 insertions(+), 22 deletions(-) diff --git a/src/app/core/shared/client-math.service.ts b/src/app/core/shared/client-math.service.ts index 2fde521ba9..0630ec3246 100644 --- a/src/app/core/shared/client-math.service.ts +++ b/src/app/core/shared/client-math.service.ts @@ -31,7 +31,7 @@ export class ClientMathService extends MathService { protected mathJaxOptions = { tex: { - inlineMath: [['$', '$'], ['\\(', '\\)']], + inlineMath: [['$', '$'], ['$$', '$$'], ['\\(', '\\)']], }, svg: { fontCache: 'global', @@ -108,7 +108,7 @@ export class ClientMathService extends MathService { */ render(element: HTMLElement) { if (environment.markdown.mathjax) { - this._window.nativeWindow.MathJax.typesetPromise([element]); + return (window as any).MathJax.typesetPromise([element]) as Promise; } } } diff --git a/src/app/core/shared/math.service.spec.ts b/src/app/core/shared/math.service.spec.ts index cc0b2814f2..75d8bf1024 100644 --- a/src/app/core/shared/math.service.spec.ts +++ b/src/app/core/shared/math.service.spec.ts @@ -22,8 +22,8 @@ export class MockMathService extends MathService { return of(true); } - render(element: HTMLElement): void { - return; + render(element: HTMLElement): Promise { + return Promise.resolve(); } } diff --git a/src/app/core/shared/math.service.ts b/src/app/core/shared/math.service.ts index c06ce06220..909e039564 100644 --- a/src/app/core/shared/math.service.ts +++ b/src/app/core/shared/math.service.ts @@ -15,5 +15,5 @@ export abstract class MathService { protected abstract registerMathJaxAsync(config: MathJaxConfig): Promise; abstract ready(): Observable; - abstract render(element: HTMLElement): void; + abstract render(element: HTMLElement): Promise; } diff --git a/src/app/core/shared/server-math.service.ts b/src/app/core/shared/server-math.service.ts index 75fa775fee..62070dbafc 100644 --- a/src/app/core/shared/server-math.service.ts +++ b/src/app/core/shared/server-math.service.ts @@ -47,6 +47,6 @@ export class ServerMathService extends MathService { } render(element: HTMLElement) { - return; + return Promise.resolve(); } } diff --git a/src/app/shared/utils/markdown.directive.ts b/src/app/shared/utils/markdown.directive.ts index a38b079ffd..0540e25cc5 100644 --- a/src/app/shared/utils/markdown.directive.ts +++ b/src/app/shared/utils/markdown.directive.ts @@ -55,30 +55,40 @@ export class MarkdownDirective implements OnInit, OnDestroy { async render(value: string, forcePreview = false): Promise { if (isEmpty(value) || (!environment.markdown.enabled && !forcePreview)) { - return value; + this.el.innerHTML = value; + return; + } else { + if (environment.markdown.mathjax) { + this.renderMathjaxThenMarkdown(value); + } else { + this.renderMarkdown(value); + } } + } + + private renderMathjaxThenMarkdown(value: string) { + const sanitized = this.sanitizer.sanitize(SecurityContext.HTML, value); + this.el.innerHTML = sanitized; + this.mathService.ready().pipe( + filter((ready) => ready), + take(1), + takeUntil(this.alive$), + ).subscribe(() => { + this.mathService.render(this.el)?.then(_ => { + this.renderMarkdown(this.el.innerHTML, true); + }); + }); + } + + private async renderMarkdown(value: string, alreadySanitized = false) { const MarkdownIt = await this.markdownIt; const md = new MarkdownIt({ html: true, linkify: true, }); - const html = this.sanitizer.sanitize(SecurityContext.HTML, md.render(value)); + const html = alreadySanitized ? md.render(value) : this.sanitizer.sanitize(SecurityContext.HTML, md.render(value)); this.el.innerHTML = html; - - if (environment.markdown.mathjax) { - this.renderMathjax(); - } - } - - private renderMathjax() { - this.mathService.ready().pipe( - filter((ready) => ready), - take(1), - takeUntil(this.alive$), - ).subscribe(() => { - this.mathService.render(this.el); - }); } ngOnDestroy() { From cc975bb0b517cd73adcc7a4eb5cd362ece936903 Mon Sep 17 00:00:00 2001 From: Sascha Szott Date: Thu, 13 Jun 2024 13:07:51 +0200 Subject: [PATCH 04/63] add lint rule (use-lifecycle-interface) --- .eslintrc.json | 1 + 1 file changed, 1 insertion(+) diff --git a/.eslintrc.json b/.eslintrc.json index 4cc8c6dbc5..dc76a7dea3 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -165,6 +165,7 @@ "@angular-eslint/no-output-native": "warn", "@angular-eslint/no-output-on-prefix": "warn", "@angular-eslint/no-conflicting-lifecycle": "warn", + "@angular-eslint/use-lifecycle-interface": "error" "@typescript-eslint/no-inferrable-types":[ "error", From 3cedeffec93b41fce27ea432552b335b37a30894 Mon Sep 17 00:00:00 2001 From: Sascha Szott Date: Thu, 13 Jun 2024 13:12:35 +0200 Subject: [PATCH 05/63] add missing comma --- .eslintrc.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.eslintrc.json b/.eslintrc.json index dc76a7dea3..5fb4c12171 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -165,7 +165,7 @@ "@angular-eslint/no-output-native": "warn", "@angular-eslint/no-output-on-prefix": "warn", "@angular-eslint/no-conflicting-lifecycle": "warn", - "@angular-eslint/use-lifecycle-interface": "error" + "@angular-eslint/use-lifecycle-interface": "error", "@typescript-eslint/no-inferrable-types":[ "error", From 2d9ad8e5cf6f04805dc27e147708ae9367864935 Mon Sep 17 00:00:00 2001 From: Sascha Szott Date: Thu, 13 Jun 2024 13:46:57 +0200 Subject: [PATCH 06/63] add missing imports of Angular lifecycle interfaces --- .../metadata-registry/metadata-registry.component.ts | 7 +++++-- .../filtered-collections.component.ts | 3 ++- .../filtered-items/filtered-items.component.ts | 5 +++-- .../core/submission/submission-duplicate-data.service.ts | 8 ++++++-- .../person/person-search-result-list-element.component.ts | 3 ++- .../recent-item-list/recent-item-list.component.ts | 3 ++- .../edit-item-page/item-status/item-status.component.ts | 3 ++- .../orcid-page/orcid-queue/orcid-queue.component.ts | 3 ++- .../project-entry-import-modal.component.ts | 3 ++- .../qa/source/quality-assurance-source.component.ts | 4 +++- .../publication-claim/publication-claim.component.ts | 3 ++- .../profile-page-security-form.component.ts | 3 ++- .../ds-dynamic-form-control-container.component.ts | 5 ++++- .../models/onebox/dynamic-onebox.component.ts | 3 ++- .../shared/form/number-picker/number-picker.component.ts | 3 ++- .../item/item-search-result-list-element.component.ts | 7 +++++-- .../collection/submission-form-collection.component.ts | 3 ++- .../submission-upload-files.component.ts | 3 ++- .../sections/duplicates/section-duplicates.component.ts | 3 ++- 19 files changed, 52 insertions(+), 23 deletions(-) diff --git a/src/app/admin/admin-registries/metadata-registry/metadata-registry.component.ts b/src/app/admin/admin-registries/metadata-registry/metadata-registry.component.ts index a148559bd2..be989d49e2 100644 --- a/src/app/admin/admin-registries/metadata-registry/metadata-registry.component.ts +++ b/src/app/admin/admin-registries/metadata-registry/metadata-registry.component.ts @@ -4,7 +4,10 @@ import { NgForOf, NgIf, } from '@angular/common'; -import { Component } from '@angular/core'; +import { + Component, + OnDestroy, +} from '@angular/core'; import { Router, RouterLink, @@ -60,7 +63,7 @@ import { MetadataSchemaFormComponent } from './metadata-schema-form/metadata-sch * A component used for managing all existing metadata schemas within the repository. * The admin can create, edit or delete metadata schemas here. */ -export class MetadataRegistryComponent { +export class MetadataRegistryComponent implements OnDestroy { /** * A list of all the current metadata schemas within the repository diff --git a/src/app/admin/admin-reports/filtered-collections/filtered-collections.component.ts b/src/app/admin/admin-reports/filtered-collections/filtered-collections.component.ts index b4bebfc924..e1f54bd8d3 100644 --- a/src/app/admin/admin-reports/filtered-collections/filtered-collections.component.ts +++ b/src/app/admin/admin-reports/filtered-collections/filtered-collections.component.ts @@ -4,6 +4,7 @@ import { } from '@angular/common'; import { Component, + OnInit, ViewChild, } from '@angular/core'; import { @@ -40,7 +41,7 @@ import { FilteredCollections } from './filtered-collections.model'; ], standalone: true, }) -export class FilteredCollectionsComponent { +export class FilteredCollectionsComponent implements OnInit { queryForm: FormGroup; results: FilteredCollections = new FilteredCollections(); diff --git a/src/app/admin/admin-reports/filtered-items/filtered-items.component.ts b/src/app/admin/admin-reports/filtered-items/filtered-items.component.ts index 9fd4643573..4cb93aa9be 100644 --- a/src/app/admin/admin-reports/filtered-items/filtered-items.component.ts +++ b/src/app/admin/admin-reports/filtered-items/filtered-items.component.ts @@ -5,6 +5,7 @@ import { } from '@angular/common'; import { Component, + OnInit, ViewChild, } from '@angular/core'; import { @@ -66,7 +67,7 @@ import { QueryPredicate } from './query-predicate.model'; ], standalone: true, }) -export class FilteredItemsComponent { +export class FilteredItemsComponent implements OnInit { collections: OptionVO[]; presetQueries: PresetQuery[]; @@ -90,7 +91,7 @@ export class FilteredItemsComponent { private formBuilder: FormBuilder, private restService: DspaceRestService) {} - ngOnInit() { + ngOnInit(): void { this.loadCollections(); this.loadPresetQueries(); this.loadMetadataFields(); diff --git a/src/app/core/submission/submission-duplicate-data.service.ts b/src/app/core/submission/submission-duplicate-data.service.ts index 755fec05c2..b327342469 100644 --- a/src/app/core/submission/submission-duplicate-data.service.ts +++ b/src/app/core/submission/submission-duplicate-data.service.ts @@ -1,5 +1,8 @@ /* eslint-disable max-classes-per-file */ -import { Injectable } from '@angular/core'; +import { + Injectable, + OnDestroy, +} from '@angular/core'; import { Observable } from 'rxjs'; import { Duplicate } from '../../shared/object-list/duplicate-data/duplicate.model'; @@ -33,7 +36,8 @@ import { HALEndpointService } from '../shared/hal-endpoint.service'; * */ @Injectable({ providedIn: 'root' }) -export class SubmissionDuplicateDataService extends BaseDataService implements SearchData { +export class SubmissionDuplicateDataService extends BaseDataService + implements SearchData, OnDestroy { /** * The ResponseParsingService constructor name diff --git a/src/app/entity-groups/research-entities/item-list-elements/search-result-list-elements/person/person-search-result-list-element.component.ts b/src/app/entity-groups/research-entities/item-list-elements/search-result-list-elements/person/person-search-result-list-element.component.ts index ac8bac2f13..86ead8b825 100644 --- a/src/app/entity-groups/research-entities/item-list-elements/search-result-list-elements/person/person-search-result-list-element.component.ts +++ b/src/app/entity-groups/research-entities/item-list-elements/search-result-list-elements/person/person-search-result-list-element.component.ts @@ -7,6 +7,7 @@ import { import { Component, Inject, + OnInit, } from '@angular/core'; import { RouterLink } from '@angular/router'; import { TranslateModule } from '@ngx-translate/core'; @@ -36,7 +37,7 @@ import { ThemedThumbnailComponent } from '../../../../../thumbnail/themed-thumbn /** * The component for displaying a list element for an item search result of the type Person */ -export class PersonSearchResultListElementComponent extends ItemSearchResultListElementComponent { +export class PersonSearchResultListElementComponent extends ItemSearchResultListElementComponent implements OnInit { public constructor( protected truncatableService: TruncatableService, diff --git a/src/app/home-page/recent-item-list/recent-item-list.component.ts b/src/app/home-page/recent-item-list/recent-item-list.component.ts index 351677fce4..65c1998b7a 100644 --- a/src/app/home-page/recent-item-list/recent-item-list.component.ts +++ b/src/app/home-page/recent-item-list/recent-item-list.component.ts @@ -10,6 +10,7 @@ import { Component, ElementRef, Inject, + OnDestroy, OnInit, PLATFORM_ID, } from '@angular/core'; @@ -62,7 +63,7 @@ import { VarDirective } from '../../shared/utils/var.directive'; standalone: true, imports: [VarDirective, NgIf, NgClass, NgFor, ListableObjectComponentLoaderComponent, ErrorComponent, ThemedLoadingComponent, AsyncPipe, TranslateModule], }) -export class RecentItemListComponent implements OnInit { +export class RecentItemListComponent implements OnInit, OnDestroy { itemRD$: Observable>>; paginationConfig: PaginationComponentOptions; sortConfig: SortOptions; diff --git a/src/app/item-page/edit-item-page/item-status/item-status.component.ts b/src/app/item-page/edit-item-page/item-status/item-status.component.ts index bbd7b99a97..1bb17dc77c 100644 --- a/src/app/item-page/edit-item-page/item-status/item-status.component.ts +++ b/src/app/item-page/edit-item-page/item-status/item-status.component.ts @@ -7,6 +7,7 @@ import { import { ChangeDetectionStrategy, Component, + OnDestroy, OnInit, } from '@angular/core'; import { @@ -79,7 +80,7 @@ import { ItemOperation } from '../item-operation/itemOperation.model'; /** * Component for displaying an item's status */ -export class ItemStatusComponent implements OnInit { +export class ItemStatusComponent implements OnInit, OnDestroy { /** * The item to display the status for diff --git a/src/app/item-page/orcid-page/orcid-queue/orcid-queue.component.ts b/src/app/item-page/orcid-page/orcid-queue/orcid-queue.component.ts index 0f02d7083c..dfc7fac526 100644 --- a/src/app/item-page/orcid-page/orcid-queue/orcid-queue.component.ts +++ b/src/app/item-page/orcid-page/orcid-queue/orcid-queue.component.ts @@ -2,6 +2,7 @@ import { CommonModule } from '@angular/common'; import { Component, Input, + OnChanges, OnDestroy, OnInit, SimpleChanges, @@ -56,7 +57,7 @@ import { PaginationComponentOptions } from '../../../shared/pagination/paginatio ], standalone: true, }) -export class OrcidQueueComponent implements OnInit, OnDestroy { +export class OrcidQueueComponent implements OnInit, OnDestroy, OnChanges { /** * The item for which showing the orcid settings diff --git a/src/app/notifications/qa/project-entry-import-modal/project-entry-import-modal.component.ts b/src/app/notifications/qa/project-entry-import-modal/project-entry-import-modal.component.ts index 4b31e2316a..b2d45916d2 100644 --- a/src/app/notifications/qa/project-entry-import-modal/project-entry-import-modal.component.ts +++ b/src/app/notifications/qa/project-entry-import-modal/project-entry-import-modal.component.ts @@ -6,6 +6,7 @@ import { Component, EventEmitter, Input, + OnDestroy, OnInit, } from '@angular/core'; import { FormsModule } from '@angular/forms'; @@ -110,7 +111,7 @@ export interface QualityAssuranceEventData { * Component to display a modal window for linking a project to an Quality Assurance event * Shows information about the selected project and a selectable list. */ -export class ProjectEntryImportModalComponent implements OnInit { +export class ProjectEntryImportModalComponent implements OnInit, OnDestroy { /** * The external source entry */ diff --git a/src/app/notifications/qa/source/quality-assurance-source.component.ts b/src/app/notifications/qa/source/quality-assurance-source.component.ts index a918b8c3b6..c7457c5d2b 100644 --- a/src/app/notifications/qa/source/quality-assurance-source.component.ts +++ b/src/app/notifications/qa/source/quality-assurance-source.component.ts @@ -5,7 +5,9 @@ import { NgIf, } from '@angular/common'; import { + AfterViewInit, Component, + OnDestroy, OnInit, } from '@angular/core'; import { RouterLink } from '@angular/router'; @@ -40,7 +42,7 @@ import { NotificationsStateService } from '../../notifications-state.service'; standalone: true, imports: [AlertComponent, NgIf, ThemedLoadingComponent, PaginationComponent, NgFor, RouterLink, AsyncPipe, TranslateModule, DatePipe], }) -export class QualityAssuranceSourceComponent implements OnInit { +export class QualityAssuranceSourceComponent implements OnDestroy, OnInit, AfterViewInit { /** * The pagination system configuration for HTML listing. diff --git a/src/app/notifications/suggestion-targets/publication-claim/publication-claim.component.ts b/src/app/notifications/suggestion-targets/publication-claim/publication-claim.component.ts index 136466b4ac..952bf9c75b 100644 --- a/src/app/notifications/suggestion-targets/publication-claim/publication-claim.component.ts +++ b/src/app/notifications/suggestion-targets/publication-claim/publication-claim.component.ts @@ -6,6 +6,7 @@ import { import { Component, Input, + OnDestroy, OnInit, } from '@angular/core'; import { @@ -50,7 +51,7 @@ import { SuggestionTargetsStateService } from '../suggestion-targets.state.servi ], standalone: true, }) -export class PublicationClaimComponent implements OnInit { +export class PublicationClaimComponent implements OnDestroy, OnInit { /** * The source for which to list targets diff --git a/src/app/profile-page/profile-page-security-form/profile-page-security-form.component.ts b/src/app/profile-page/profile-page-security-form/profile-page-security-form.component.ts index 7c0bf9ea2d..0fdee2080b 100644 --- a/src/app/profile-page/profile-page-security-form/profile-page-security-form.component.ts +++ b/src/app/profile-page/profile-page-security-form/profile-page-security-form.component.ts @@ -3,6 +3,7 @@ import { Component, EventEmitter, Input, + OnDestroy, OnInit, Output, } from '@angular/core'; @@ -44,7 +45,7 @@ import { NotificationsService } from '../../shared/notifications/notifications.s * Component for a user to edit their security information * Displays a form containing a password field and a confirmation of the password */ -export class ProfilePageSecurityFormComponent implements OnInit { +export class ProfilePageSecurityFormComponent implements OnDestroy, OnInit { /** * Emits the validity of the password diff --git a/src/app/shared/form/builder/ds-dynamic-form-ui/ds-dynamic-form-control-container.component.ts b/src/app/shared/form/builder/ds-dynamic-form-ui/ds-dynamic-form-control-container.component.ts index 595a1304a0..a373c53984 100644 --- a/src/app/shared/form/builder/ds-dynamic-form-ui/ds-dynamic-form-control-container.component.ts +++ b/src/app/shared/form/builder/ds-dynamic-form-ui/ds-dynamic-form-control-container.component.ts @@ -6,11 +6,13 @@ import { NgTemplateOutlet, } from '@angular/common'; import { + AfterViewInit, ChangeDetectionStrategy, ChangeDetectorRef, Component, ComponentFactoryResolver, ContentChildren, + DoCheck, EventEmitter, Inject, Input, @@ -143,7 +145,8 @@ import { DsDynamicLookupRelationModalComponent } from './relation-lookup-modal/d ], standalone: true, }) -export class DsDynamicFormControlContainerComponent extends DynamicFormControlContainerComponent implements OnInit, OnChanges, OnDestroy { +export class DsDynamicFormControlContainerComponent extends DynamicFormControlContainerComponent + implements OnInit, OnChanges, OnDestroy, AfterViewInit, DoCheck { @ContentChildren(DynamicTemplateDirective) contentTemplateList: QueryList; // eslint-disable-next-line @angular-eslint/no-input-rename @Input('templates') inputTemplateList: QueryList; diff --git a/src/app/shared/form/builder/ds-dynamic-form-ui/models/onebox/dynamic-onebox.component.ts b/src/app/shared/form/builder/ds-dynamic-form-ui/models/onebox/dynamic-onebox.component.ts index 23cec6b502..22f8dce244 100644 --- a/src/app/shared/form/builder/ds-dynamic-form-ui/models/onebox/dynamic-onebox.component.ts +++ b/src/app/shared/form/builder/ds-dynamic-form-ui/models/onebox/dynamic-onebox.component.ts @@ -9,6 +9,7 @@ import { Component, EventEmitter, Input, + OnDestroy, OnInit, Output, ViewChild, @@ -92,7 +93,7 @@ import { DynamicOneboxModel } from './dynamic-onebox.model'; ], standalone: true, }) -export class DsDynamicOneboxComponent extends DsDynamicVocabularyComponent implements OnInit { +export class DsDynamicOneboxComponent extends DsDynamicVocabularyComponent implements OnDestroy, OnInit { @Input() group: UntypedFormGroup; @Input() model: DynamicOneboxModel; diff --git a/src/app/shared/form/number-picker/number-picker.component.ts b/src/app/shared/form/number-picker/number-picker.component.ts index e268919101..b097236659 100644 --- a/src/app/shared/form/number-picker/number-picker.component.ts +++ b/src/app/shared/form/number-picker/number-picker.component.ts @@ -4,6 +4,7 @@ import { Component, EventEmitter, Input, + OnChanges, OnInit, Output, SimpleChanges, @@ -36,7 +37,7 @@ import { isEmpty } from '../../empty.util'; standalone: true, }) -export class NumberPickerComponent implements OnInit, ControlValueAccessor { +export class NumberPickerComponent implements OnChanges, OnInit, ControlValueAccessor { @Input() id: string; @Input() step: number; @Input() min: number; diff --git a/src/app/shared/object-list/search-result-list-element/item-search-result/item-types/item/item-search-result-list-element.component.ts b/src/app/shared/object-list/search-result-list-element/item-search-result/item-types/item/item-search-result-list-element.component.ts index 8afafa2b86..26a1d7e655 100644 --- a/src/app/shared/object-list/search-result-list-element/item-search-result/item-types/item/item-search-result-list-element.component.ts +++ b/src/app/shared/object-list/search-result-list-element/item-search-result/item-types/item/item-search-result-list-element.component.ts @@ -4,7 +4,10 @@ import { NgFor, NgIf, } from '@angular/common'; -import { Component } from '@angular/core'; +import { + Component, + OnInit, +} from '@angular/core'; import { RouterLink } from '@angular/router'; import { Item } from '../../../../../../core/shared/item.model'; @@ -30,7 +33,7 @@ import { SearchResultListElementComponent } from '../../../search-result-list-el /** * The component for displaying a list element for an item search result of the type Publication */ -export class ItemSearchResultListElementComponent extends SearchResultListElementComponent { +export class ItemSearchResultListElementComponent extends SearchResultListElementComponent implements OnInit { /** * Route to the item's page */ diff --git a/src/app/submission/form/collection/submission-form-collection.component.ts b/src/app/submission/form/collection/submission-form-collection.component.ts index dcbcfd9cb3..2aec1c9e30 100644 --- a/src/app/submission/form/collection/submission-form-collection.component.ts +++ b/src/app/submission/form/collection/submission-form-collection.component.ts @@ -5,6 +5,7 @@ import { EventEmitter, Input, OnChanges, + OnDestroy, OnInit, Output, SimpleChanges, @@ -58,7 +59,7 @@ import { SubmissionService } from '../../submission.service'; ThemedCollectionDropdownComponent, ], }) -export class SubmissionFormCollectionComponent implements OnChanges, OnInit { +export class SubmissionFormCollectionComponent implements OnDestroy, OnChanges, OnInit { /** * The current collection id this submission belonging to diff --git a/src/app/submission/form/submission-upload-files/submission-upload-files.component.ts b/src/app/submission/form/submission-upload-files/submission-upload-files.component.ts index e694a868ca..3632ec6760 100644 --- a/src/app/submission/form/submission-upload-files/submission-upload-files.component.ts +++ b/src/app/submission/form/submission-upload-files/submission-upload-files.component.ts @@ -3,6 +3,7 @@ import { Component, Input, OnChanges, + OnDestroy, } from '@angular/core'; import { TranslateService } from '@ngx-translate/core'; import { @@ -43,7 +44,7 @@ import parseSectionErrors from '../../utils/parseSectionErrors'; ], standalone: true, }) -export class SubmissionUploadFilesComponent implements OnChanges { +export class SubmissionUploadFilesComponent implements OnChanges, OnDestroy { /** * The collection id this submission belonging to diff --git a/src/app/submission/sections/duplicates/section-duplicates.component.ts b/src/app/submission/sections/duplicates/section-duplicates.component.ts index d90a0ca85a..885511ca52 100644 --- a/src/app/submission/sections/duplicates/section-duplicates.component.ts +++ b/src/app/submission/sections/duplicates/section-duplicates.component.ts @@ -7,6 +7,7 @@ import { ChangeDetectionStrategy, Component, Inject, + OnInit, } from '@angular/core'; import { TranslateModule, @@ -48,7 +49,7 @@ import { SectionsService } from '../sections.service'; standalone: true, }) -export class SubmissionSectionDuplicatesComponent extends SectionModelComponent { +export class SubmissionSectionDuplicatesComponent extends SectionModelComponent implements OnInit { protected readonly Metadata = Metadata; /** * The Alert categories. From e06b67fd73358ac52e2e71fa96d708520de33f3e Mon Sep 17 00:00:00 2001 From: root Date: Wed, 26 Jun 2024 08:29:32 -0300 Subject: [PATCH 07/63] Resolution of issue #1190 - Improving the accessibility of the status page using the item-operation component --- .../item-operation/item-operation.component.html | 4 ++-- .../item-operation/item-operation.component.scss | 9 +++++++++ .../item-operation/item-operation.component.ts | 1 + 3 files changed, 12 insertions(+), 2 deletions(-) create mode 100644 src/app/item-page/edit-item-page/item-operation/item-operation.component.scss diff --git a/src/app/item-page/edit-item-page/item-operation/item-operation.component.html b/src/app/item-page/edit-item-page/item-operation/item-operation.component.html index 85c6a2cca1..e282017315 100644 --- a/src/app/item-page/edit-item-page/item-operation/item-operation.component.html +++ b/src/app/item-page/edit-item-page/item-operation/item-operation.component.html @@ -1,9 +1,9 @@ -
+
{{'item.edit.tabs.status.buttons.' + operation.operationKey + '.label' | translate}}
-
+
From cddceadea145069b62d306a2d4150e61877b86a2 Mon Sep 17 00:00:00 2001 From: Sascha Szott Date: Wed, 7 Aug 2024 16:05:17 +0200 Subject: [PATCH 19/63] remove duplicated delete route --- .../workspaceitems-edit-page-routes.ts | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/src/app/workspaceitems-edit-page/workspaceitems-edit-page-routes.ts b/src/app/workspaceitems-edit-page/workspaceitems-edit-page-routes.ts index 8f07c24edc..35cf2521c7 100644 --- a/src/app/workspaceitems-edit-page/workspaceitems-edit-page-routes.ts +++ b/src/app/workspaceitems-edit-page/workspaceitems-edit-page-routes.ts @@ -50,16 +50,6 @@ export const ROUTES: Route[] = [ }, data: { title: 'workspace-item.delete', breadcrumbKey: 'workspace-item.delete' }, }, - { - canActivate: [authenticatedGuard], - path: 'delete', - component: ThemedWorkspaceItemsDeletePageComponent, - resolve: { - dso: itemFromWorkspaceResolver, - breadcrumb: i18nBreadcrumbResolver, - }, - data: { title: 'workspace-item.delete', breadcrumbKey: 'workspace-item.delete' }, - }, ], }, ]; From 45c018f5f62fd85aae296e22fd4c0c606eaf3d96 Mon Sep 17 00:00:00 2001 From: Sascha Szott Date: Wed, 7 Aug 2024 16:50:17 +0200 Subject: [PATCH 20/63] added missing translations in de.json5 (prefix workspace-item) --- src/assets/i18n/de.json5 | 35 ++++++++++++++++++++++++++++++++++- 1 file changed, 34 insertions(+), 1 deletion(-) diff --git a/src/assets/i18n/de.json5 b/src/assets/i18n/de.json5 index 7f2485ab29..0749271ab0 100644 --- a/src/assets/i18n/de.json5 +++ b/src/assets/i18n/de.json5 @@ -5881,7 +5881,7 @@ "workflow-item.delete.notification.success.title": "Gelöscht", // "workflow-item.delete.notification.success.content": "This workflow item was successfully deleted", - "workflow-item.delete.notification.success.content": "Dieses Workflow-Item wurde gelöscht.", + "workflow-item.delete.notification.success.content": "Dieses Workflow-Item wurde erfolgreich gelöscht.", // "workflow-item.delete.notification.error.title": "Something went wrong", "workflow-item.delete.notification.error.title": "Das hat leider nicht funktioniert.", @@ -5926,4 +5926,37 @@ // "workflow-item.send-back.button.confirm": "Send back" "workflow-item.send-back.button.confirm": "Zurücksenden", + // "workflow-item.view.breadcrumbs": "Workflow View", + "workflow-item.view.breadcrumbs": "Workflow-Ansicht", + + // "workspace-item.view.breadcrumbs": "Workspace View", + "workspace-item.view.breadcrumbs": "Workspace-Ansicht", + + // "workspace-item.view.title": "Workspace View", + "workspace-item.view.title": "Workspace-Ansicht", + + // "workspace-item.delete.breadcrumbs": "Workspace Delete", + "workspace-item.delete.breadcrumbs": "Workspace-Item löschen", + + // "workspace-item.delete.header": "Delete workspace item", + "workspace-item.delete.header": "Workspace-Item löschen", + + // "workspace-item.delete.button.confirm": "Delete", + "workspace-item.delete.button.confirm": "Löschen", + + // "workspace-item.delete.button.cancel": "Cancel", + "workspace-item.delete.button.cancel": "Abbrechen", + + // "workspace-item.delete.notification.success.title": "Deleted", + "workspace-item.delete.notification.success.title": "Gelöscht", + + // "workspace-item.delete.title": "This workspace item was successfully deleted", + "workspace-item.delete.title": "Dieses Workspace-Item wurde erfolgreich gelöscht.", + + // "workspace-item.delete.notification.error.title": "Something went wrong", + "workspace-item.delete.notification.error.title": "Das hat leider nicht funktioniert.", + + // "workspace-item.delete.notification.error.content": "The workspace item could not be deleted", + "workspace-item.delete.notification.error.content": "Das Workspace-Item konnte nicht gelöscht werden.", + } From 92dcffcba1c9c58250f467d6d8812326b51bb919 Mon Sep 17 00:00:00 2001 From: Sascha Szott Date: Wed, 7 Aug 2024 16:57:02 +0200 Subject: [PATCH 21/63] fix space issue --- src/assets/i18n/de.json5 | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/assets/i18n/de.json5 b/src/assets/i18n/de.json5 index 0749271ab0..285bbfa43d 100644 --- a/src/assets/i18n/de.json5 +++ b/src/assets/i18n/de.json5 @@ -5948,7 +5948,7 @@ "workspace-item.delete.button.cancel": "Abbrechen", // "workspace-item.delete.notification.success.title": "Deleted", - "workspace-item.delete.notification.success.title": "Gelöscht", + "workspace-item.delete.notification.success.title": "Gelöscht", // "workspace-item.delete.title": "This workspace item was successfully deleted", "workspace-item.delete.title": "Dieses Workspace-Item wurde erfolgreich gelöscht.", @@ -5958,5 +5958,4 @@ // "workspace-item.delete.notification.error.content": "The workspace item could not be deleted", "workspace-item.delete.notification.error.content": "Das Workspace-Item konnte nicht gelöscht werden.", - } From ad6a9438de13f861a9096768e6efdacccbfdeaf4 Mon Sep 17 00:00:00 2001 From: Tim Donohue Date: Thu, 8 Aug 2024 16:49:20 -0500 Subject: [PATCH 22/63] Fix lint error regarding missing interface --- .../publication-claim/publication-claim.component.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/app/notifications/suggestion-targets/publication-claim/publication-claim.component.ts b/src/app/notifications/suggestion-targets/publication-claim/publication-claim.component.ts index 5128c88468..a111fcd704 100644 --- a/src/app/notifications/suggestion-targets/publication-claim/publication-claim.component.ts +++ b/src/app/notifications/suggestion-targets/publication-claim/publication-claim.component.ts @@ -4,6 +4,7 @@ import { NgIf, } from '@angular/common'; import { + AfterViewInit, Component, Input, OnDestroy, @@ -51,7 +52,7 @@ import { SuggestionTargetsStateService } from '../suggestion-targets.state.servi ], standalone: true, }) -export class PublicationClaimComponent implements OnDestroy, OnInit { +export class PublicationClaimComponent implements AfterViewInit, OnDestroy, OnInit { /** * The source for which to list targets From a0515c412140184c23cface4febb5d48f0d430eb Mon Sep 17 00:00:00 2001 From: Alexandre Vryghem Date: Tue, 13 Aug 2024 11:43:36 +0200 Subject: [PATCH 23/63] 110615: Fixed related entities ay11 tab issue & removed potential duplicate ID issue by removing the unused #browseDropdown ID --- .../tabbed-related-entities-search.component.html | 8 +++++--- .../expandable-navbar-section.component.html | 2 +- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/src/app/item-page/simple/related-entities/tabbed-related-entities-search/tabbed-related-entities-search.component.html b/src/app/item-page/simple/related-entities/tabbed-related-entities-search/tabbed-related-entities-search.component.html index 223d4a6ed0..3ce96b2ce3 100644 --- a/src/app/item-page/simple/related-entities/tabbed-related-entities-search/tabbed-related-entities-search.component.html +++ b/src/app/item-page/simple/related-entities/tabbed-related-entities-search/tabbed-related-entities-search.component.html @@ -1,7 +1,9 @@ -