import { Component, Input, OnInit } from '@angular/core'; export type DeviceType = null | 'phone' | 'default' | 'router'; export type Manufacturer = null | 'cisco' | 'avaya'; @Component({ selector: 'onguard-device-icon', templateUrl: './device-icon.component.html', styleUrls: ['./device-icon.component.scss'] }) export class DeviceIconComponent implements OnInit { @Input() type: DeviceType = 'default'; @Input() width = 62; @Input() height = 62; public url: string; constructor() { } ngOnInit(): void { if (!this.type) { this.type = 'default' } this.url = `assets/images/device-icons/${this.type}.svg` } }