Cast to number

This commit is contained in:
aditya.chandel
2025-01-17 19:34:30 -07:00
parent a8c3e346e3
commit 0940fcbbeb

View File

@@ -165,12 +165,12 @@ export class EpubViewerComponent implements OnInit, OnDestroy {
}
increaseFontSize(): void {
this.fontSize = Math.min(this.fontSize + 10, FALLBACK_EPUB_SETTINGS.maxFontSize);
this.fontSize = Math.min(Number(this.fontSize) + 10, FALLBACK_EPUB_SETTINGS.maxFontSize);
this.updateFontSize();
}
decreaseFontSize(): void {
this.fontSize = Math.max(this.fontSize - 10, FALLBACK_EPUB_SETTINGS.minFontSize);
this.fontSize = Math.max(Number(this.fontSize) - 10, FALLBACK_EPUB_SETTINGS.minFontSize);
this.updateFontSize();
}