mirror of
https://github.com/futurepress/epub.js.git
synced 2025-10-04 15:09:16 +02:00
Add RTL support
This commit is contained in:
parent
8999feb613
commit
9b6e864ae4
10 changed files with 380 additions and 111 deletions
|
@ -332,6 +332,7 @@ class Contents {
|
|||
resizeCheck() {
|
||||
let width = this.textWidth();
|
||||
let height = this.textHeight();
|
||||
|
||||
if (width != this._size.width || height != this._size.height) {
|
||||
|
||||
this._size = {
|
||||
|
@ -763,7 +764,7 @@ class Contents {
|
|||
var COLUMN_WIDTH = prefixed("column-width");
|
||||
var COLUMN_FILL = prefixed("column-fill");
|
||||
|
||||
this.width(width);
|
||||
this.width("100%");
|
||||
this.height(height);
|
||||
|
||||
// Deal with Mobile trying to scale to viewport
|
||||
|
@ -819,6 +820,12 @@ class Contents {
|
|||
this.css("background-color", "transparent");
|
||||
}
|
||||
|
||||
direction(dir) {
|
||||
if (this.documentElement) {
|
||||
this.documentElement.style["direction"] = dir;
|
||||
}
|
||||
}
|
||||
|
||||
mapPage(cfiBase, layout, start, end, dev) {
|
||||
var mapping = new Mapping(layout, dev);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue