mirror of
https://github.com/DSpace/dspace-angular.git
synced 2025-10-07 01:54:15 +00:00
40 lines
1.1 KiB
TypeScript
40 lines
1.1 KiB
TypeScript
import { Component, Input } from '@angular/core';
|
|
import { MetadataValue } from '../../../core/shared/metadata.models';
|
|
import { environment } from '../../../../environments/environment';
|
|
|
|
/**
|
|
* This component renders the configured 'values' into the ds-metadata-field-wrapper component.
|
|
* It puts the given 'separator' between each two values.
|
|
*/
|
|
@Component({
|
|
selector: 'ds-metadata-values',
|
|
styleUrls: ['./metadata-values.component.scss'],
|
|
templateUrl: './metadata-values.component.html'
|
|
})
|
|
export class MetadataValuesComponent {
|
|
|
|
/**
|
|
* 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;
|
|
|
|
/**
|
|
* Whether the {@link MarkdownPipe} should be used to render these metadata values.
|
|
* This will only have effect if {@link MarkdownConfig#enabled} is true.
|
|
* Mathjax will only be rendered if {@link MarkdownConfig#mathjax} is true.
|
|
*/
|
|
@Input() enableMarkdown = false;
|
|
|
|
env = environment;
|
|
}
|