Files
frontend/src/app/movie-category/movie-category.component.ts
Piet Ostendorp b304185e21 Make movie category dynamic
Refactored MovieCategoryComponent to accept a 'category' input and display it dynamically. Updated usage in MoviePosterComponent to pass the category value, improving flexibility and reusability.
2025-10-29 10:26:29 +01:00

16 lines
353 B
TypeScript

import { Component, Input } from '@angular/core';
@Component({
selector: 'app-movie-category',
standalone: false,
templateUrl: './movie-category.component.html',
styleUrl: './movie-category.component.css'
})
export class MovieCategoryComponent {
@Input() category: string = '-';
getCategoryText(): string {
return this.category;
}
}