import {Component, Input} from '@angular/core'; import {HostedByCollectedFrom} from "../../utils/result-preview/result-preview"; import {properties} from "../../../../environments/environment"; @Component({ selector: 'availableOn', template: `
{{instance.downloadNames.join("; ")}}
{{instance.types.join(" . ")}} . {{instance.years.join(" . ")}}
Providers: {{collectedName}};
View less
View more
` }) export class AvailableOnComponent { @Input() availableOn: HostedByCollectedFrom[]; public threshold: number = 4; public showNum: number = 4; public dataProviderUrl = properties.searchLinkToDataProvider.split('?')[0]; constructor() { } ngOnInit() {} public removeUnknown(value: string): string { if (value.toLowerCase() === 'unknown') { return null; } return value; } }