summaryrefslogtreecommitdiff
path: root/js
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2018-07-01 15:35:59 +0300
committerAndrew Dolgov <[email protected]>2018-07-01 15:35:59 +0300
commit3f7843e9a7f04e7b6fd7109ce1e1ea1b0159627f (patch)
treea3c971bf5df239dc33fa9c7664d6e5dfd7a099e5 /js
parentd80e7a5c5ecbef3836bfdb871acc867bc3d7054e (diff)
apparently you can't adjust default epubjs theme
Diffstat (limited to 'js')
-rw-r--r--js/read.js10
1 files changed, 4 insertions, 6 deletions
diff --git a/js/read.js b/js/read.js
index bc37f98..77570c7 100644
--- a/js/read.js
+++ b/js/read.js
@@ -180,12 +180,10 @@ function apply_styles() {
var lineHeight = res[2] ? res[2] + "%" : DEFAULT_LINE_HEIGHT + "%";
var themeName = res[3] ? res[3] : false;
- window.book.rendition.themes.default({
- html: {
- 'font-size': fontSize,
- 'font-family': fontFamily,
- 'line-height': lineHeight,
- }
+ $.each(window.book.rendition.getContents(), function(i, c) {
+ c.css("font-size", fontSize);
+ c.css("font-family", fontFamily);
+ c.css("line-height", lineHeight);
});
apply_theme();