mirror of
https://github.com/DSpace/dspace-angular.git
synced 2025-10-13 13:03:04 +00:00

Conflicts: src/app/+collection-page/collection-page.component.ts src/app/+collection-page/collection-page.module.ts src/app/+item-page/field-components/metadata-uri-values/metadata-uri-values.component.ts src/app/+item-page/field-components/metadata-values/metadata-values.component.ts src/app/+item-page/simple/field-components/specific-field/item-page-field.component.html src/app/+item-page/simple/field-components/specific-field/uri/item-page-uri-field.component.html src/app/+search-page/search-service/search.service.ts src/app/core/core.module.ts src/app/core/data/base-response-parsing.service.ts src/app/core/data/data.service.ts src/app/core/data/request.service.spec.ts src/app/core/metadata/metadata.service.spec.ts src/app/core/shared/dspace-object.model.ts src/app/core/shared/metadatum.model.ts src/app/core/shared/operators.ts src/app/core/shared/resource-type.ts src/app/shared/object-list/item-list-element/item-list-element.component.html src/app/shared/object-list/item-list-element/item-list-element.component.spec.ts src/app/shared/object-list/search-result-list-element/item-search-result/item-search-result-list-element.component.html src/app/shared/object-list/search-result-list-element/item-search-result/item-search-result-list-element.component.spec.ts src/app/shared/object-list/search-result-list-element/search-result-list-element.component.ts src/app/shared/services/route.service.ts src/app/shared/shared.module.ts
41 lines
1.2 KiB
TypeScript
41 lines
1.2 KiB
TypeScript
import { Component, Input } from '@angular/core';
|
|
|
|
import { MetadataValuesComponent } from '../metadata-values/metadata-values.component';
|
|
import { MetadataValue } from '../../../core/shared/metadata.models';
|
|
|
|
/**
|
|
* This component renders the configured 'values' into the ds-metadata-field-wrapper component as a link.
|
|
* It puts the given 'separator' between each two values
|
|
* and creates an 'a' tag for each value,
|
|
* using the 'linktext' as it's value (if it exists)
|
|
* and using the values as the 'href' attribute (and as value of the tag when no 'linktext' is defined)
|
|
*/
|
|
@Component({
|
|
selector: 'ds-metadata-uri-values',
|
|
styleUrls: ['./metadata-uri-values.component.scss'],
|
|
templateUrl: './metadata-uri-values.component.html'
|
|
})
|
|
export class MetadataUriValuesComponent extends MetadataValuesComponent {
|
|
|
|
/**
|
|
* Optional text to replace the links with
|
|
* If undefined, the metadata value (uri) is displayed
|
|
*/
|
|
@Input() linktext: any;
|
|
|
|
/**
|
|
* The metadata values to display
|
|
*/
|
|
@Input() mdValues: MetadataValue[];
|
|
|
|
/**
|
|
* The seperator used to split the metadata values (can contain HTML)
|
|
*/
|
|
@Input() separator: string;
|
|
|
|
/**
|
|
* The label for this iteration of metadata values
|
|
*/
|
|
@Input() label: string;
|
|
}
|