You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
31 lines
778 B
TypeScript
31 lines
778 B
TypeScript
|
7 years ago
|
import { Component, OnInit, Input, Output, EventEmitter } from '@angular/core';
|
||
|
|
import { CommonService } from '../../services/common/common.service';
|
||
|
|
import { TranslatorService } from '../../services/translator/translator.service';
|
||
|
|
|
||
|
|
@Component({
|
||
|
|
selector: 'detail-button',
|
||
|
|
templateUrl: './detail-button.component.html',
|
||
|
|
styleUrls: ['./detail-button.component.scss'],
|
||
|
|
})
|
||
|
|
export class DetailButtonComponent implements OnInit {
|
||
|
|
|
||
|
|
@Input() src: string;
|
||
|
|
@Input() title: string;
|
||
|
|
@Output() click = new EventEmitter();
|
||
|
|
public direction;
|
||
|
|
|
||
|
|
constructor(
|
||
|
|
public cs: CommonService,
|
||
|
|
public ts: TranslatorService
|
||
|
|
) { }
|
||
|
|
|
||
|
|
ngOnInit() {
|
||
|
|
this.direction = TranslatorService.getCurrentDirection();
|
||
|
|
}
|
||
|
|
|
||
|
|
public onClick(event: any) {
|
||
|
|
this.click.emit(event);
|
||
|
|
}
|
||
|
|
|
||
|
|
}
|