diff --git a/src/app/entity-groups/research-entities/item-pages/person/person.component.html b/src/app/entity-groups/research-entities/item-pages/person/person.component.html
index 7505a31327..96cfdbfacd 100644
--- a/src/app/entity-groups/research-entities/item-pages/person/person.component.html
+++ b/src/app/entity-groups/research-entities/item-pages/person/person.component.html
@@ -4,7 +4,7 @@
-
+
@@ -20,18 +20,10 @@
[fields]="['person.email']"
[label]="'person.page.email'">
-
-
-
-
-
-
-
-
+
+
{{"item.page.link.full" | translate}}
diff --git a/src/app/entity-groups/research-entities/item-pages/person/person.component.spec.ts b/src/app/entity-groups/research-entities/item-pages/person/person.component.spec.ts
index 93b3cf208d..efbc48a209 100644
--- a/src/app/entity-groups/research-entities/item-pages/person/person.component.spec.ts
+++ b/src/app/entity-groups/research-entities/item-pages/person/person.component.spec.ts
@@ -17,24 +17,12 @@ const mockItem: Item = Object.assign(new Item(), {
value: 'fake@email.com'
}
],
- // 'person.identifier.orcid': [
- // {
- // language: 'en_US',
- // value: 'ORCID-1'
- // }
- // ],
'person.birthDate': [
{
language: 'en_US',
value: '1993'
}
],
- // 'person.identifier.staffid': [
- // {
- // language: 'en_US',
- // value: '1'
- // }
- // ],
'person.jobTitle': [
{
language: 'en_US',
@@ -62,4 +50,42 @@ const mockItem: Item = Object.assign(new Item(), {
}
});
-describe('PersonComponent', getItemPageFieldsTest(mockItem, PersonComponent));
+const mockItemWithTitle: Item = Object.assign(new Item(), {
+ bundles: createSuccessfulRemoteDataObject$(buildPaginatedList(new PageInfo(), [])),
+ metadata: {
+ 'person.email': [
+ {
+ language: 'en_US',
+ value: 'fake@email.com'
+ }
+ ],
+ 'person.birthDate': [
+ {
+ language: 'en_US',
+ value: '1993'
+ }
+ ],
+ 'person.jobTitle': [
+ {
+ language: 'en_US',
+ value: 'Developer'
+ }
+ ],
+ 'dc.title': [
+ {
+ language: 'en_US',
+ value: 'Doe, John'
+ }
+ ]
+ },
+ relationships: createRelationshipsObservable(),
+ _links: {
+ self : {
+ href: 'item-href'
+ }
+ }
+});
+
+describe('PersonComponent with family and given names', getItemPageFieldsTest(mockItem, PersonComponent));
+
+describe('PersonComponent with dc.title', getItemPageFieldsTest(mockItemWithTitle, PersonComponent));
diff --git a/src/app/entity-groups/research-entities/item-pages/person/person.component.ts b/src/app/entity-groups/research-entities/item-pages/person/person.component.ts
index 33db18681f..27fdd2ab15 100644
--- a/src/app/entity-groups/research-entities/item-pages/person/person.component.ts
+++ b/src/app/entity-groups/research-entities/item-pages/person/person.component.ts
@@ -1,20 +1,10 @@
-import {Component, OnInit} from '@angular/core';
+import { Component } from '@angular/core';
import { ItemComponent } from '../../../../item-page/simple/item-types/shared/item.component';
import { ViewMode } from '../../../../core/shared/view-mode.model';
-import { listableObjectComponent } from '../../../../shared/object-collection/shared/listable-object/listable-object.decorator';
-import {MetadataValue} from '../../../../core/shared/metadata.models';
-import {FeatureID} from '../../../../core/data/feature-authorization/feature-id';
-import {mergeMap, take} from 'rxjs/operators';
-import {getFirstSucceededRemoteData} from '../../../../core/shared/operators';
-import {RemoteData} from '../../../../core/data/remote-data';
-import {ResearcherProfile} from '../../../../core/profile/model/researcher-profile.model';
-import {isNotUndefined} from '../../../../shared/empty.util';
-import {BehaviorSubject, Observable} from 'rxjs';
-import {RouteService} from '../../../../core/services/route.service';
-import {AuthorizationDataService} from '../../../../core/data/feature-authorization/authorization-data.service';
-import {ResearcherProfileService} from '../../../../core/profile/researcher-profile.service';
-import {NotificationsService} from '../../../../shared/notifications/notifications.service';
-import {TranslateService} from '@ngx-translate/core';
+import {
+ listableObjectComponent
+} from '../../../../shared/object-collection/shared/listable-object/listable-object.decorator';
+import { MetadataValue } from '../../../../core/shared/metadata.models';
@listableObjectComponent('Person', ViewMode.StandalonePage)
@Component({
@@ -25,76 +15,25 @@ import {TranslateService} from '@ngx-translate/core';
/**
* The component for displaying metadata and relations of an item of the type Person
*/
-export class PersonComponent extends ItemComponent implements OnInit {
-
- claimable$: BehaviorSubject = new BehaviorSubject(false);
-
- constructor(protected routeService: RouteService,
- protected authorizationService: AuthorizationDataService,
- protected notificationsService: NotificationsService,
- protected translate: TranslateService,
- protected researcherProfileService: ResearcherProfileService) {
- super(routeService);
- }
-
- ngOnInit(): void {
- super.ngOnInit();
-
- this.authorizationService.isAuthorized(FeatureID.CanClaimItem, this.object._links.self.href).pipe(
- take(1)
- ).subscribe((isAuthorized: boolean) => {
- this.claimable$.next(isAuthorized);
- });
-
- }
-
- /**
- * Create a new researcher profile claiming the current item.
- */
- claim() {
- this.researcherProfileService.createFromExternalSource(this.object._links.self.href).pipe(
- getFirstSucceededRemoteData(),
- mergeMap((rd: RemoteData) => {
- return this.researcherProfileService.findRelatedItemId(rd.payload);
- }))
- .subscribe((id: string) => {
- if (isNotUndefined(id)) {
- this.notificationsService.success(this.translate.get('researcherprofile.success.claim.title'),
- this.translate.get('researcherprofile.success.claim.body'));
- this.claimable$.next(false);
- } else {
- this.notificationsService.error(
- this.translate.get('researcherprofile.error.claim.title'),
- this.translate.get('researcherprofile.error.claim.body'));
- }
- });
- }
-
- /**
- * Returns true if the item is claimable, false otherwise.
- */
- isClaimable(): Observable {
- return this.claimable$;
- }
+export class PersonComponent extends ItemComponent {
/**
* Returns the metadata values to be used for the page title.
*/
- getTitleMetadataValues(): MetadataValue[]{
+ getTitleMetadataValues(): MetadataValue[] {
const metadataValues = [];
const familyName = this.object?.firstMetadata('person.familyName');
const givenName = this.object?.firstMetadata('person.givenName');
const title = this.object?.firstMetadata('dc.title');
- if (familyName){
+ if (familyName) {
metadataValues.push(familyName);
}
- if (givenName){
+ if (givenName) {
metadataValues.push(givenName);
}
- if (metadataValues.length === 0 && title){
+ if (metadataValues.length === 0 && title) {
metadataValues.push(title);
}
return metadataValues;
}
-
}
diff --git a/src/app/shared/dso-page/person-page-claim-button/person-page-claim-button.component.html b/src/app/shared/dso-page/person-page-claim-button/person-page-claim-button.component.html
new file mode 100644
index 0000000000..12d5d2b47d
--- /dev/null
+++ b/src/app/shared/dso-page/person-page-claim-button/person-page-claim-button.component.html
@@ -0,0 +1 @@
+
diff --git a/src/app/shared/dso-page/person-page-claim-button/person-page-claim-button.component.scss b/src/app/shared/dso-page/person-page-claim-button/person-page-claim-button.component.scss
new file mode 100644
index 0000000000..e69de29bb2
diff --git a/src/app/shared/dso-page/person-page-claim-button/person-page-claim-button.component.spec.ts b/src/app/shared/dso-page/person-page-claim-button/person-page-claim-button.component.spec.ts
new file mode 100644
index 0000000000..168517b47a
--- /dev/null
+++ b/src/app/shared/dso-page/person-page-claim-button/person-page-claim-button.component.spec.ts
@@ -0,0 +1,186 @@
+import { ComponentFixture, TestBed } from '@angular/core/testing';
+import { By } from '@angular/platform-browser';
+
+import { of as observableOf } from 'rxjs';
+import { TranslateLoader, TranslateModule } from '@ngx-translate/core';
+
+import { PersonPageClaimButtonComponent } from './person-page-claim-button.component';
+import { AuthorizationDataService } from '../../../core/data/feature-authorization/authorization-data.service';
+import { NotificationsService } from '../../notifications/notifications.service';
+import { NotificationsServiceStub } from '../../testing/notifications-service.stub';
+import { TranslateLoaderMock } from '../../mocks/translate-loader.mock';
+import { ResearcherProfileService } from '../../../core/profile/researcher-profile.service';
+import { RouteService } from '../../../core/services/route.service';
+import { routeServiceStub } from '../../testing/route-service.stub';
+import { Item } from '../../../core/shared/item.model';
+import { ResearcherProfile } from '../../../core/profile/model/researcher-profile.model';
+import { createFailedRemoteDataObject$, createSuccessfulRemoteDataObject$ } from '../../remote-data.utils';
+import { getTestScheduler } from 'jasmine-marbles';
+import { TestScheduler } from 'rxjs/testing';
+
+describe('PersonPageClaimButtonComponent', () => {
+ let scheduler: TestScheduler;
+ let component: PersonPageClaimButtonComponent;
+ let fixture: ComponentFixture;
+
+ const mockItem: Item = Object.assign(new Item(), {
+ metadata: {
+ 'person.email': [
+ {
+ language: 'en_US',
+ value: 'fake@email.com'
+ }
+ ],
+ 'person.birthDate': [
+ {
+ language: 'en_US',
+ value: '1993'
+ }
+ ],
+ 'person.jobTitle': [
+ {
+ language: 'en_US',
+ value: 'Developer'
+ }
+ ],
+ 'person.familyName': [
+ {
+ language: 'en_US',
+ value: 'Doe'
+ }
+ ],
+ 'person.givenName': [
+ {
+ language: 'en_US',
+ value: 'John'
+ }
+ ]
+ },
+ _links: {
+ self: {
+ href: 'item-href'
+ }
+ }
+ });
+
+ const mockResearcherProfile: ResearcherProfile = Object.assign(new ResearcherProfile(), {
+ id: 'test-id',
+ visible: true,
+ type: 'profile',
+ _links: {
+ item: {
+ href: 'https://rest.api/rest/api/profiles/test-id/item'
+ },
+ self: {
+ href: 'https://rest.api/rest/api/profiles/test-id'
+ },
+ }
+ });
+
+ const notificationsService = new NotificationsServiceStub();
+
+ const authorizationDataService = jasmine.createSpyObj('authorizationDataService', {
+ isAuthorized: jasmine.createSpy('isAuthorized')
+ });
+
+ const researcherProfileService = jasmine.createSpyObj('researcherProfileService', {
+ createFromExternalSource: jasmine.createSpy('createFromExternalSource'),
+ findRelatedItemId: jasmine.createSpy('findRelatedItemId'),
+ });
+
+ beforeEach(async () => {
+ await TestBed.configureTestingModule({
+ imports: [
+ TranslateModule.forRoot({
+ loader: {
+ provide: TranslateLoader,
+ useClass: TranslateLoaderMock
+ }
+ })
+ ],
+ declarations: [PersonPageClaimButtonComponent],
+ providers: [
+ { provide: AuthorizationDataService, useValue: authorizationDataService },
+ { provide: NotificationsService, useValue: notificationsService },
+ { provide: ResearcherProfileService, useValue: researcherProfileService },
+ { provide: RouteService, useValue: routeServiceStub },
+ ]
+ })
+ .compileComponents();
+ });
+
+ beforeEach(() => {
+ fixture = TestBed.createComponent(PersonPageClaimButtonComponent);
+ component = fixture.componentInstance;
+ component.object = mockItem;
+ });
+
+ describe('when item can be claimed', () => {
+ beforeEach(() => {
+ authorizationDataService.isAuthorized.and.returnValue(observableOf(true));
+ researcherProfileService.createFromExternalSource.calls.reset();
+ researcherProfileService.findRelatedItemId.calls.reset();
+ fixture.detectChanges();
+ });
+
+ it('should create', () => {
+ expect(component).toBeTruthy();
+ });
+
+ it('should create claim button', () => {
+ const btn = fixture.debugElement.query(By.css('[data-test="item-claim"]'));
+ expect(btn).toBeTruthy();
+ });
+
+ describe('claim', () => {
+ describe('when successfully', () => {
+ beforeEach(() => {
+ scheduler = getTestScheduler();
+ researcherProfileService.createFromExternalSource.and.returnValue(createSuccessfulRemoteDataObject$(mockResearcherProfile));
+ researcherProfileService.findRelatedItemId.and.returnValue(observableOf('test-id'));
+ });
+
+ it('should display success notification', () => {
+ scheduler.schedule(() => component.claim());
+ scheduler.flush();
+
+ expect(researcherProfileService.findRelatedItemId).toHaveBeenCalled();
+ expect(notificationsService.success).toHaveBeenCalled();
+ });
+ });
+
+ describe('when not successfully', () => {
+ beforeEach(() => {
+ scheduler = getTestScheduler();
+ researcherProfileService.createFromExternalSource.and.returnValue(createFailedRemoteDataObject$());
+ });
+
+ it('should display success notification', () => {
+ scheduler.schedule(() => component.claim());
+ scheduler.flush();
+
+ expect(researcherProfileService.findRelatedItemId).not.toHaveBeenCalled();
+ expect(notificationsService.error).toHaveBeenCalled();
+ });
+ });
+ });
+
+ });
+
+ describe('when item cannot be claimed', () => {
+ beforeEach(() => {
+ authorizationDataService.isAuthorized.and.returnValue(observableOf(false));
+ fixture.detectChanges();
+ });
+
+ it('should create', () => {
+ expect(component).toBeTruthy();
+ });
+
+ it('should create claim button', () => {
+ const btn = fixture.debugElement.query(By.css('[data-test="item-claim"]'));
+ expect(btn).toBeFalsy();
+ });
+
+ });
+});
diff --git a/src/app/shared/dso-page/person-page-claim-button/person-page-claim-button.component.ts b/src/app/shared/dso-page/person-page-claim-button/person-page-claim-button.component.ts
new file mode 100644
index 0000000000..d2e8e888e1
--- /dev/null
+++ b/src/app/shared/dso-page/person-page-claim-button/person-page-claim-button.component.ts
@@ -0,0 +1,85 @@
+import { Component, Input, OnInit } from '@angular/core';
+
+import { BehaviorSubject, Observable, of as observableOf } from 'rxjs';
+import { mergeMap, take } from 'rxjs/operators';
+import { TranslateService } from '@ngx-translate/core';
+
+import { RouteService } from '../../../core/services/route.service';
+import { AuthorizationDataService } from '../../../core/data/feature-authorization/authorization-data.service';
+import { NotificationsService } from '../../notifications/notifications.service';
+import { ResearcherProfileService } from '../../../core/profile/researcher-profile.service';
+import { FeatureID } from '../../../core/data/feature-authorization/feature-id';
+import { getFirstCompletedRemoteData } from '../../../core/shared/operators';
+import { RemoteData } from '../../../core/data/remote-data';
+import { ResearcherProfile } from '../../../core/profile/model/researcher-profile.model';
+import { isNotEmpty } from '../../empty.util';
+import { DSpaceObject } from '../../../core/shared/dspace-object.model';
+
+@Component({
+ selector: 'ds-person-page-claim-button',
+ templateUrl: './person-page-claim-button.component.html',
+ styleUrls: ['./person-page-claim-button.component.scss']
+})
+export class PersonPageClaimButtonComponent implements OnInit {
+
+ /**
+ * The target person item to claim
+ */
+ @Input() object: DSpaceObject;
+
+ /**
+ * A boolean representing if item can be claimed or not
+ */
+ claimable$: BehaviorSubject = new BehaviorSubject(false);
+
+ constructor(protected routeService: RouteService,
+ protected authorizationService: AuthorizationDataService,
+ protected notificationsService: NotificationsService,
+ protected translate: TranslateService,
+ protected researcherProfileService: ResearcherProfileService) {
+ }
+
+ ngOnInit(): void {
+ this.authorizationService.isAuthorized(FeatureID.CanClaimItem, this.object._links.self.href).pipe(
+ take(1)
+ ).subscribe((isAuthorized: boolean) => {
+ this.claimable$.next(isAuthorized);
+ });
+
+ }
+
+ /**
+ * Create a new researcher profile claiming the current item.
+ */
+ claim() {
+ this.researcherProfileService.createFromExternalSource(this.object._links.self.href).pipe(
+ getFirstCompletedRemoteData(),
+ mergeMap((rd: RemoteData) => {
+ console.log(rd);
+ if (rd.hasSucceeded) {
+ return this.researcherProfileService.findRelatedItemId(rd.payload);
+ } else {
+ return observableOf(null);
+ }
+ }))
+ .subscribe((id: string) => {
+ if (isNotEmpty(id)) {
+ this.notificationsService.success(this.translate.get('researcherprofile.success.claim.title'),
+ this.translate.get('researcherprofile.success.claim.body'));
+ this.claimable$.next(false);
+ } else {
+ this.notificationsService.error(
+ this.translate.get('researcherprofile.error.claim.title'),
+ this.translate.get('researcherprofile.error.claim.body'));
+ }
+ });
+ }
+
+ /**
+ * Returns true if the item is claimable, false otherwise.
+ */
+ isClaimable(): Observable {
+ return this.claimable$;
+ }
+
+}
diff --git a/src/app/shared/shared.module.ts b/src/app/shared/shared.module.ts
index 847b3910e0..b2a36285bb 100644
--- a/src/app/shared/shared.module.ts
+++ b/src/app/shared/shared.module.ts
@@ -7,7 +7,12 @@ import { DragDropModule } from '@angular/cdk/drag-drop';
import { NouisliderModule } from 'ng2-nouislider';
import {
- NgbDatepickerModule, NgbDropdownModule, NgbNavModule, NgbPaginationModule, NgbTimepickerModule, NgbTooltipModule,
+ NgbDatepickerModule,
+ NgbDropdownModule,
+ NgbNavModule,
+ NgbPaginationModule,
+ NgbTimepickerModule,
+ NgbTooltipModule,
NgbTypeaheadModule,
} from '@ng-bootstrap/ng-bootstrap';
import { MissingTranslationHandler, TranslateModule } from '@ngx-translate/core';
@@ -16,7 +21,9 @@ import { FileUploadModule } from 'ng2-file-upload';
import { InfiniteScrollModule } from 'ngx-infinite-scroll';
import { MomentModule } from 'ngx-moment';
import { ConfirmationModalComponent } from './confirmation-modal/confirmation-modal.component';
-import { ExportMetadataSelectorComponent } from './dso-selector/modal-wrappers/export-metadata-selector/export-metadata-selector.component';
+import {
+ ExportMetadataSelectorComponent
+} from './dso-selector/modal-wrappers/export-metadata-selector/export-metadata-selector.component';
import { FileDropzoneNoUploaderComponent } from './file-dropzone-no-uploader/file-dropzone-no-uploader.component';
import { ItemListElementComponent } from './object-list/item-list-element/item-types/item/item-list-element.component';
import { EnumKeysPipe } from './utils/enum-keys-pipe';
@@ -24,13 +31,21 @@ import { FileSizePipe } from './utils/file-size-pipe';
import { MetadataFieldValidator } from './utils/metadatafield-validator.directive';
import { SafeUrlPipe } from './utils/safe-url-pipe';
import { ConsolePipe } from './utils/console.pipe';
-import { CollectionListElementComponent } from './object-list/collection-list-element/collection-list-element.component';
+import {
+ CollectionListElementComponent
+} from './object-list/collection-list-element/collection-list-element.component';
import { CommunityListElementComponent } from './object-list/community-list-element/community-list-element.component';
-import { SearchResultListElementComponent } from './object-list/search-result-list-element/search-result-list-element.component';
+import {
+ SearchResultListElementComponent
+} from './object-list/search-result-list-element/search-result-list-element.component';
import { ObjectListComponent } from './object-list/object-list.component';
-import { CollectionGridElementComponent } from './object-grid/collection-grid-element/collection-grid-element.component';
+import {
+ CollectionGridElementComponent
+} from './object-grid/collection-grid-element/collection-grid-element.component';
import { CommunityGridElementComponent } from './object-grid/community-grid-element/community-grid-element.component';
-import { AbstractListableElementComponent } from './object-collection/shared/object-collection-element/abstract-listable-element.component';
+import {
+ AbstractListableElementComponent
+} from './object-collection/shared/object-collection-element/abstract-listable-element.component';
import { ObjectGridComponent } from './object-grid/object-grid.component';
import { ObjectCollectionComponent } from './object-collection/object-collection.component';
import { ErrorComponent } from './error/error.component';
@@ -38,7 +53,9 @@ import { LoadingComponent } from './loading/loading.component';
import { PaginationComponent } from './pagination/pagination.component';
import { ThumbnailComponent } from '../thumbnail/thumbnail.component';
import { SearchFormComponent } from './search-form/search-form.component';
-import { SearchResultGridElementComponent } from './object-grid/search-result-grid-element/search-result-grid-element.component';
+import {
+ SearchResultGridElementComponent
+} from './object-grid/search-result-grid-element/search-result-grid-element.component';
import { ViewModeSwitchComponent } from './view-mode-switch/view-mode-switch.component';
import { VarDirective } from './utils/var.directive';
import { AuthNavMenuComponent } from './auth-nav-menu/auth-nav-menu.component';
@@ -53,21 +70,33 @@ import { ChipsComponent } from './chips/chips.component';
import { NumberPickerComponent } from './number-picker/number-picker.component';
import { MockAdminGuard } from './mocks/admin-guard.service.mock';
import { AlertComponent } from './alert/alert.component';
-import { SearchResultDetailElementComponent } from './object-detail/my-dspace-result-detail-element/search-result-detail-element.component';
+import {
+ SearchResultDetailElementComponent
+} from './object-detail/my-dspace-result-detail-element/search-result-detail-element.component';
import { ClaimedTaskActionsComponent } from './mydspace-actions/claimed-task/claimed-task-actions.component';
import { PoolTaskActionsComponent } from './mydspace-actions/pool-task/pool-task-actions.component';
import { ObjectDetailComponent } from './object-detail/object-detail.component';
-import { ItemDetailPreviewComponent } from './object-detail/my-dspace-result-detail-element/item-detail-preview/item-detail-preview.component';
-import { MyDSpaceItemStatusComponent } from './object-collection/shared/mydspace-item-status/my-dspace-item-status.component';
+import {
+ ItemDetailPreviewComponent
+} from './object-detail/my-dspace-result-detail-element/item-detail-preview/item-detail-preview.component';
+import {
+ MyDSpaceItemStatusComponent
+} from './object-collection/shared/mydspace-item-status/my-dspace-item-status.component';
import { WorkspaceitemActionsComponent } from './mydspace-actions/workspaceitem/workspaceitem-actions.component';
import { WorkflowitemActionsComponent } from './mydspace-actions/workflowitem/workflowitem-actions.component';
import { ItemSubmitterComponent } from './object-collection/shared/mydspace-item-submitter/item-submitter.component';
import { ItemActionsComponent } from './mydspace-actions/item/item-actions.component';
-import { ClaimedTaskActionsApproveComponent } from './mydspace-actions/claimed-task/approve/claimed-task-actions-approve.component';
-import { ClaimedTaskActionsRejectComponent } from './mydspace-actions/claimed-task/reject/claimed-task-actions-reject.component';
+import {
+ ClaimedTaskActionsApproveComponent
+} from './mydspace-actions/claimed-task/approve/claimed-task-actions-approve.component';
+import {
+ ClaimedTaskActionsRejectComponent
+} from './mydspace-actions/claimed-task/reject/claimed-task-actions-reject.component';
import { ObjNgFor } from './utils/object-ngfor.pipe';
import { BrowseByComponent } from './browse-by/browse-by.component';
-import { BrowseEntryListElementComponent } from './object-list/browse-entry-list-element/browse-entry-list-element.component';
+import {
+ BrowseEntryListElementComponent
+} from './object-list/browse-entry-list-element/browse-entry-list-element.component';
import { DebounceDirective } from './utils/debounce.directive';
import { ClickOutsideDirective } from './utils/click-outside.directive';
import { EmphasizePipe } from './utils/emphasize.pipe';
@@ -76,53 +105,105 @@ import { CapitalizePipe } from './utils/capitalize.pipe';
import { ObjectKeysPipe } from './utils/object-keys-pipe';
import { AuthorityConfidenceStateDirective } from './authority-confidence/authority-confidence-state.directive';
import { LangSwitchComponent } from './lang-switch/lang-switch.component';
-import { PlainTextMetadataListElementComponent } from './object-list/metadata-representation-list-element/plain-text/plain-text-metadata-list-element.component';
-import { ItemMetadataListElementComponent } from './object-list/metadata-representation-list-element/item/item-metadata-list-element.component';
-import { MetadataRepresentationListElementComponent } from './object-list/metadata-representation-list-element/metadata-representation-list-element.component';
+import {
+ PlainTextMetadataListElementComponent
+} from './object-list/metadata-representation-list-element/plain-text/plain-text-metadata-list-element.component';
+import {
+ ItemMetadataListElementComponent
+} from './object-list/metadata-representation-list-element/item/item-metadata-list-element.component';
+import {
+ MetadataRepresentationListElementComponent
+} from './object-list/metadata-representation-list-element/metadata-representation-list-element.component';
import { ObjectValuesPipe } from './utils/object-values-pipe';
import { InListValidator } from './utils/in-list-validator.directive';
import { AutoFocusDirective } from './utils/auto-focus.directive';
import { StartsWithDateComponent } from './starts-with/date/starts-with-date.component';
import { StartsWithTextComponent } from './starts-with/text/starts-with-text.component';
import { DSOSelectorComponent } from './dso-selector/dso-selector/dso-selector.component';
-import { CreateCommunityParentSelectorComponent } from './dso-selector/modal-wrappers/create-community-parent-selector/create-community-parent-selector.component';
-import { CreateItemParentSelectorComponent } from './dso-selector/modal-wrappers/create-item-parent-selector/create-item-parent-selector.component';
-import { CreateCollectionParentSelectorComponent } from './dso-selector/modal-wrappers/create-collection-parent-selector/create-collection-parent-selector.component';
-import { CommunitySearchResultListElementComponent } from './object-list/search-result-list-element/community-search-result/community-search-result-list-element.component';
-import { CollectionSearchResultListElementComponent } from './object-list/search-result-list-element/collection-search-result/collection-search-result-list-element.component';
-import { EditItemSelectorComponent } from './dso-selector/modal-wrappers/edit-item-selector/edit-item-selector.component';
-import { EditCommunitySelectorComponent } from './dso-selector/modal-wrappers/edit-community-selector/edit-community-selector.component';
-import { EditCollectionSelectorComponent } from './dso-selector/modal-wrappers/edit-collection-selector/edit-collection-selector.component';
-import { ItemListPreviewComponent } from './object-list/my-dspace-result-list-element/item-list-preview/item-list-preview.component';
-import { MetadataFieldWrapperComponent } from '../item-page/field-components/metadata-field-wrapper/metadata-field-wrapper.component';
+import {
+ CreateCommunityParentSelectorComponent
+} from './dso-selector/modal-wrappers/create-community-parent-selector/create-community-parent-selector.component';
+import {
+ CreateItemParentSelectorComponent
+} from './dso-selector/modal-wrappers/create-item-parent-selector/create-item-parent-selector.component';
+import {
+ CreateCollectionParentSelectorComponent
+} from './dso-selector/modal-wrappers/create-collection-parent-selector/create-collection-parent-selector.component';
+import {
+ CommunitySearchResultListElementComponent
+} from './object-list/search-result-list-element/community-search-result/community-search-result-list-element.component';
+import {
+ CollectionSearchResultListElementComponent
+} from './object-list/search-result-list-element/collection-search-result/collection-search-result-list-element.component';
+import {
+ EditItemSelectorComponent
+} from './dso-selector/modal-wrappers/edit-item-selector/edit-item-selector.component';
+import {
+ EditCommunitySelectorComponent
+} from './dso-selector/modal-wrappers/edit-community-selector/edit-community-selector.component';
+import {
+ EditCollectionSelectorComponent
+} from './dso-selector/modal-wrappers/edit-collection-selector/edit-collection-selector.component';
+import {
+ ItemListPreviewComponent
+} from './object-list/my-dspace-result-list-element/item-list-preview/item-list-preview.component';
+import {
+ MetadataFieldWrapperComponent
+} from '../item-page/field-components/metadata-field-wrapper/metadata-field-wrapper.component';
import { MetadataValuesComponent } from '../item-page/field-components/metadata-values/metadata-values.component';
import { RoleDirective } from './roles/role.directive';
import { UserMenuComponent } from './auth-nav-menu/user-menu/user-menu.component';
-import { ClaimedTaskActionsReturnToPoolComponent } from './mydspace-actions/claimed-task/return-to-pool/claimed-task-actions-return-to-pool.component';
-import { ItemDetailPreviewFieldComponent } from './object-detail/my-dspace-result-detail-element/item-detail-preview/item-detail-preview-field/item-detail-preview-field.component';
-import { CollectionSearchResultGridElementComponent } from './object-grid/search-result-grid-element/collection-search-result/collection-search-result-grid-element.component';
-import { CommunitySearchResultGridElementComponent } from './object-grid/search-result-grid-element/community-search-result/community-search-result-grid-element.component';
+import {
+ ClaimedTaskActionsReturnToPoolComponent
+} from './mydspace-actions/claimed-task/return-to-pool/claimed-task-actions-return-to-pool.component';
+import {
+ ItemDetailPreviewFieldComponent
+} from './object-detail/my-dspace-result-detail-element/item-detail-preview/item-detail-preview-field/item-detail-preview-field.component';
+import {
+ CollectionSearchResultGridElementComponent
+} from './object-grid/search-result-grid-element/collection-search-result/collection-search-result-grid-element.component';
+import {
+ CommunitySearchResultGridElementComponent
+} from './object-grid/search-result-grid-element/community-search-result/community-search-result-grid-element.component';
import { PageSizeSelectorComponent } from './page-size-selector/page-size-selector.component';
import { AbstractTrackableComponent } from './trackable/abstract-trackable.component';
-import { ComcolMetadataComponent } from './comcol/comcol-forms/edit-comcol-page/comcol-metadata/comcol-metadata.component';
+import {
+ ComcolMetadataComponent
+} from './comcol/comcol-forms/edit-comcol-page/comcol-metadata/comcol-metadata.component';
import { ItemSelectComponent } from './object-select/item-select/item-select.component';
import { CollectionSelectComponent } from './object-select/collection-select/collection-select.component';
-import { FilterInputSuggestionsComponent } from './input-suggestions/filter-suggestions/filter-input-suggestions.component';
-import { DsoInputSuggestionsComponent } from './input-suggestions/dso-input-suggestions/dso-input-suggestions.component';
+import {
+ FilterInputSuggestionsComponent
+} from './input-suggestions/filter-suggestions/filter-input-suggestions.component';
+import {
+ DsoInputSuggestionsComponent
+} from './input-suggestions/dso-input-suggestions/dso-input-suggestions.component';
import { ItemGridElementComponent } from './object-grid/item-grid-element/item-types/item/item-grid-element.component';
import { TypeBadgeComponent } from './object-list/type-badge/type-badge.component';
-import { MetadataRepresentationLoaderComponent } from './metadata-representation/metadata-representation-loader.component';
+import {
+ MetadataRepresentationLoaderComponent
+} from './metadata-representation/metadata-representation-loader.component';
import { MetadataRepresentationDirective } from './metadata-representation/metadata-representation.directive';
-import { ListableObjectComponentLoaderComponent } from './object-collection/shared/listable-object/listable-object-component-loader.component';
-import { ItemSearchResultListElementComponent } from './object-list/search-result-list-element/item-search-result/item-types/item/item-search-result-list-element.component';
+import {
+ ListableObjectComponentLoaderComponent
+} from './object-collection/shared/listable-object/listable-object-component-loader.component';
+import {
+ ItemSearchResultListElementComponent
+} from './object-list/search-result-list-element/item-search-result/item-types/item/item-search-result-list-element.component';
import { ListableObjectDirective } from './object-collection/shared/listable-object/listable-object.directive';
-import { ItemMetadataRepresentationListElementComponent } from './object-list/metadata-representation-list-element/item/item-metadata-representation-list-element.component';
+import {
+ ItemMetadataRepresentationListElementComponent
+} from './object-list/metadata-representation-list-element/item/item-metadata-representation-list-element.component';
import { PageWithSidebarComponent } from './sidebar/page-with-sidebar.component';
import { SidebarDropdownComponent } from './sidebar/sidebar-dropdown.component';
import { SidebarFilterComponent } from './sidebar/filter/sidebar-filter.component';
import { SidebarFilterSelectedOptionComponent } from './sidebar/filter/sidebar-filter-selected-option.component';
-import { SelectableListItemControlComponent } from './object-collection/shared/selectable-list-item-control/selectable-list-item-control.component';
-import { ImportableListItemControlComponent } from './object-collection/shared/importable-list-item-control/importable-list-item-control.component';
+import {
+ SelectableListItemControlComponent
+} from './object-collection/shared/selectable-list-item-control/selectable-list-item-control.component';
+import {
+ ImportableListItemControlComponent
+} from './object-collection/shared/importable-list-item-control/importable-list-item-control.component';
import { ItemVersionsComponent } from './item/item-versions/item-versions.component';
import { SortablejsModule } from 'ngx-sortablejs';
import { LogInContainerComponent } from './log-in/container/log-in-container.component';
@@ -135,10 +216,16 @@ import { ItemVersionsNoticeComponent } from './item/item-versions/notice/item-ve
import { FileValidator } from './utils/require-file.validator';
import { FileValueAccessorDirective } from './utils/file-value-accessor.directive';
import { FileSectionComponent } from '../item-page/simple/field-components/file-section/file-section.component';
-import { ModifyItemOverviewComponent } from '../item-page/edit-item-page/modify-item-overview/modify-item-overview.component';
-import { ClaimedTaskActionsLoaderComponent } from './mydspace-actions/claimed-task/switcher/claimed-task-actions-loader.component';
+import {
+ ModifyItemOverviewComponent
+} from '../item-page/edit-item-page/modify-item-overview/modify-item-overview.component';
+import {
+ ClaimedTaskActionsLoaderComponent
+} from './mydspace-actions/claimed-task/switcher/claimed-task-actions-loader.component';
import { ClaimedTaskActionsDirective } from './mydspace-actions/claimed-task/switcher/claimed-task-actions.directive';
-import { ClaimedTaskActionsEditMetadataComponent } from './mydspace-actions/claimed-task/edit-metadata/claimed-task-actions-edit-metadata.component';
+import {
+ ClaimedTaskActionsEditMetadataComponent
+} from './mydspace-actions/claimed-task/edit-metadata/claimed-task-actions-edit-metadata.component';
import { ImpersonateNavbarComponent } from './impersonate-navbar/impersonate-navbar.component';
import { NgForTrackByIdDirective } from './ng-for-track-by-id.directive';
import { FileDownloadLinkComponent } from './file-download-link/file-download-link.component';
@@ -146,34 +233,63 @@ import { CollectionDropdownComponent } from './collection-dropdown/collection-dr
import { EntityDropdownComponent } from './entity-dropdown/entity-dropdown.component';
import { VocabularyTreeviewComponent } from './vocabulary-treeview/vocabulary-treeview.component';
import { CurationFormComponent } from '../curation-form/curation-form.component';
-import { PublicationSidebarSearchListElementComponent } from './object-list/sidebar-search-list-element/item-types/publication/publication-sidebar-search-list-element.component';
-import { SidebarSearchListElementComponent } from './object-list/sidebar-search-list-element/sidebar-search-list-element.component';
-import { CollectionSidebarSearchListElementComponent } from './object-list/sidebar-search-list-element/collection/collection-sidebar-search-list-element.component';
-import { CommunitySidebarSearchListElementComponent } from './object-list/sidebar-search-list-element/community/community-sidebar-search-list-element.component';
-import { AuthorizedCollectionSelectorComponent } from './dso-selector/dso-selector/authorized-collection-selector/authorized-collection-selector.component';
+import {
+ PublicationSidebarSearchListElementComponent
+} from './object-list/sidebar-search-list-element/item-types/publication/publication-sidebar-search-list-element.component';
+import {
+ SidebarSearchListElementComponent
+} from './object-list/sidebar-search-list-element/sidebar-search-list-element.component';
+import {
+ CollectionSidebarSearchListElementComponent
+} from './object-list/sidebar-search-list-element/collection/collection-sidebar-search-list-element.component';
+import {
+ CommunitySidebarSearchListElementComponent
+} from './object-list/sidebar-search-list-element/community/community-sidebar-search-list-element.component';
+import {
+ AuthorizedCollectionSelectorComponent
+} from './dso-selector/dso-selector/authorized-collection-selector/authorized-collection-selector.component';
import { DsoPageEditButtonComponent } from './dso-page/dso-page-edit-button/dso-page-edit-button.component';
import { DsoPageVersionButtonComponent } from './dso-page/dso-page-version-button/dso-page-version-button.component';
import { HoverClassDirective } from './hover-class.directive';
-import { ValidationSuggestionsComponent } from './input-suggestions/validation-suggestions/validation-suggestions.component';
+import {
+ ValidationSuggestionsComponent
+} from './input-suggestions/validation-suggestions/validation-suggestions.component';
import { ItemAlertsComponent } from './item/item-alerts/item-alerts.component';
-import { ItemSearchResultGridElementComponent } from './object-grid/search-result-grid-element/item-search-result/item/item-search-result-grid-element.component';
+import {
+ ItemSearchResultGridElementComponent
+} from './object-grid/search-result-grid-element/item-search-result/item/item-search-result-grid-element.component';
import { BitstreamDownloadPageComponent } from './bitstream-download-page/bitstream-download-page.component';
-import { GenericItemPageFieldComponent } from '../item-page/simple/field-components/specific-field/generic/generic-item-page-field.component';
-import { MetadataRepresentationListComponent } from '../item-page/simple/metadata-representation-list/metadata-representation-list.component';
+import {
+ GenericItemPageFieldComponent
+} from '../item-page/simple/field-components/specific-field/generic/generic-item-page-field.component';
+import {
+ MetadataRepresentationListComponent
+} from '../item-page/simple/metadata-representation-list/metadata-representation-list.component';
import { RelatedItemsComponent } from '../item-page/simple/related-items/related-items-component';
import { LinkMenuItemComponent } from './menu/menu-item/link-menu-item.component';
import { OnClickMenuItemComponent } from './menu/menu-item/onclick-menu-item.component';
import { TextMenuItemComponent } from './menu/menu-item/text-menu-item.component';
import { SearchNavbarComponent } from '../search-navbar/search-navbar.component';
-import { ItemVersionsSummaryModalComponent } from './item/item-versions/item-versions-summary-modal/item-versions-summary-modal.component';
-import { ItemVersionsDeleteModalComponent } from './item/item-versions/item-versions-delete-modal/item-versions-delete-modal.component';
+import {
+ ItemVersionsSummaryModalComponent
+} from './item/item-versions/item-versions-summary-modal/item-versions-summary-modal.component';
+import {
+ ItemVersionsDeleteModalComponent
+} from './item/item-versions/item-versions-delete-modal/item-versions-delete-modal.component';
import { ScopeSelectorModalComponent } from './search-form/scope-selector-modal/scope-selector-modal.component';
-import { BitstreamRequestACopyPageComponent } from './bitstream-request-a-copy-page/bitstream-request-a-copy-page.component';
+import {
+ BitstreamRequestACopyPageComponent
+} from './bitstream-request-a-copy-page/bitstream-request-a-copy-page.component';
import { DsSelectComponent } from './ds-select/ds-select.component';
import { LogInOidcComponent } from './log-in/methods/oidc/log-in-oidc.component';
-import { ThemedItemListPreviewComponent } from './object-list/my-dspace-result-list-element/item-list-preview/themed-item-list-preview.component';
-import { ClaimItemSelectorComponent } from './dso-selector/modal-wrappers/claim-item-selector/claim-item-selector.component';
+import {
+ ThemedItemListPreviewComponent
+} from './object-list/my-dspace-result-list-element/item-list-preview/themed-item-list-preview.component';
+import {
+ ClaimItemSelectorComponent
+} from './dso-selector/modal-wrappers/claim-item-selector/claim-item-selector.component';
import { ExternalLinkMenuItemComponent } from './menu/menu-item/external-link-menu-item.component';
+import { PersonPageClaimButtonComponent } from './dso-page/person-page-claim-button/person-page-claim-button.component';
const MODULES = [
// Do NOT include UniversalModule, HttpModule, or JsonpModule here
@@ -410,6 +526,7 @@ const SHARED_ITEM_PAGE_COMPONENTS = [
MetadataValuesComponent,
DsoPageEditButtonComponent,
DsoPageVersionButtonComponent,
+ PersonPageClaimButtonComponent,
ItemAlertsComponent,
GenericItemPageFieldComponent,
MetadataRepresentationListComponent,
diff --git a/src/assets/i18n/en.json5 b/src/assets/i18n/en.json5
index e4875d153e..868f79e490 100644
--- a/src/assets/i18n/en.json5
+++ b/src/assets/i18n/en.json5
@@ -2762,6 +2762,8 @@
"person.page.lastname": "Last Name",
+ "person.page.name": "Name",
+
"person.page.link.full": "Show all metadata",
"person.page.orcid": "ORCID",