// Angular // import { Component, Input, OnInit } from '@angular/core'; // Other // import * as statics from '@fb/statics'; // input class not implemented since that should be possible to do on the component seperatly from now on. /* * @ngdoc fbTruncatingText * @name fasit.directives.#fbTruncatingText * @fbTruncatingText * * @description * Directive som skapar text som 'trunkeras' om det inte får plats och visas i sin helhet vid hover. */ @Component({ selector: 'fb-truncating-text', templateUrl: './fb-truncating-text.component.html' }) export class FbTruncatingTextComponent implements OnInit { @Input() text: string; @Input() title: string; @Input() // Todo check functionality showFulltextOnHover: boolean = false; @Input() strikeClass: boolean = false; ngOnInit(): void { if (statics.isUndefined(this.text)) { const errorString: string = `Missing required parameter for TruncatingText${this.text}`; console.error(errorString); return; } } }