Summary Table

Categories Total Count
PII 0
URL 0
DNS 0
EKL 0
IP 0
PORT 0
VsID 0
CF 0
AI 0
VPD 0
PL 0
Other 0

File Content

import { Component, Input, AfterViewInit, OnDestroy } from '@angular/core';
import { TooltipService } from './tooltip.service';

@Component({
selector: 'app-tooltip',
templateUrl: './tooltip.component.html',
styleUrls: ['./../../../ewv/ewv-viewer/ewv-viewer.component.scss']
})
export class TooltipComponent implements AfterViewInit, OnDestroy {
@Input() data;
@Input() type;
displayTooltip = false;
id: number = null;
constructor(private tooltipService: TooltipService) {}

ngAfterViewInit() {
this.tooltipService.registerTooltip(this);
}
showTooltip() {
this.displayTooltip = true;
this.tooltipService.showTooltip(this.id);
}
hideTooltip() {
this.displayTooltip = false;
}

ngOnDestroy() {
this.tooltipService.unRegisterTooltips();
}
}