Newer
Older
import { Component, OnInit, Input, Output, EventEmitter } from '@angular/core';
import { Exercise } from 'app/shared/model/exercise.model';
@Component({
selector: 'jhi-exercise-card',
templateUrl: './exercise-card.component.html',
styleUrls: ['./exercise-card.component.scss'],
})
export class ExerciseCardComponent implements OnInit {
@Input() exercise: Exercise | undefined;
@Output() exerciseSelectionEvent = new EventEmitter<Exercise>();
constructor() {}
ngOnInit(): void {}
selectExercise(): void {
this.exerciseSelectionEvent.emit(this.exercise);
}
}