1
|
import { Component, OnInit, Input } from '@angular/core';
|
2
|
|
3
|
@Component({
|
4
|
selector: 'app-card',
|
5
|
templateUrl: './card.component.html',
|
6
|
styleUrls: ['./card.component.scss']
|
7
|
})
|
8
|
export class CardComponent implements OnInit {
|
9
|
|
10
|
@Input() data: {
|
11
|
title: string,
|
12
|
subtitle: string,
|
13
|
headerImage: string,
|
14
|
footerImage: string,
|
15
|
path: string
|
16
|
};
|
17
|
|
18
|
constructor() { }
|
19
|
|
20
|
ngOnInit(): void {
|
21
|
}
|
22
|
|
23
|
calculateHeaderImageClasses() {
|
24
|
return this.data.headerImage;
|
25
|
}
|
26
|
|
27
|
calculateFooterImageClasses() {
|
28
|
return this.data.footerImage;
|
29
|
}
|
30
|
|
31
|
}
|