quick fix resize height
This commit is contained in:
parent
c308b800df
commit
0edd7f854a
1 changed files with 5 additions and 1 deletions
|
|
@ -34,7 +34,11 @@ export class Ng2FittextDirective implements AfterViewInit, OnInit {
|
||||||
@HostListener('window:resize', ['$event'])
|
@HostListener('window:resize', ['$event'])
|
||||||
onResize() {
|
onResize() {
|
||||||
if(this.activateOnResize && this.fittext) {
|
if(this.activateOnResize && this.fittext) {
|
||||||
this.setFontSize(this.container.clientWidth);
|
if(this.activateOnInputEvents && this.fittext) {
|
||||||
|
this.setFontSize(this.container.clientHeight);
|
||||||
|
} else{
|
||||||
|
this.setFontSize(this.container.clientWidth);
|
||||||
|
}
|
||||||
this.ngAfterViewInit();
|
this.ngAfterViewInit();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue