diff --git a/book.js b/book.js index 00374e1..6ae97e6 100644 --- a/book.js +++ b/book.js @@ -344,13 +344,13 @@ var stylesheet = document.createElement('style'); stylesheet.innerHTML = ".pagination-main-contents-container {display: -webkit-flex; " + - "-webkit-flex-direction: column;}" + + "-webkit-flex-direction: column; display: flex; floex-direction: column; }" + "\n.pagination-contents-container {position: absolute;}" + - "\n.pagination-contents {display: -webkit-flex; -webkit-flex: 1;}" + "\n.pagination-contents {display: -webkit-flex; -webkit-flex: 1; display: flex; flex: 1;}" /* There seems to be a bug in the new flexbox model code which requires the * height to be set to an arbitrary value (which is ignored). */ + "\n.pagination-contents {height: 0px;}" + - "\n.pagination-contents-column {-webkit-flex: 1;}" + "\nbody {" + + "\n.pagination-contents-column {-webkit-flex: 1; flex: 1;}" + "\nbody {" + "counter-reset: pagination-footnote pagination-footnote-reference;}" + "\n.pagination-footnote::before {" + "counter-increment: pagination-footnote-reference; " + @@ -364,12 +364,12 @@ "-webkit-region-break-after: always;}" + "\n.pagination-pagenumber, .pagination-header {position: absolute;}" + "\n.pagination-pagebreak {-webkit-region-break-after: always;}" + - "\n.pagination-simple {height: auto; position-relative;}" + + "\n.pagination-simple {height: auto; position: relative;}" + "\n.pagination-page {margin-left:auto; margin-right:auto;}" + "\n.pagination-marginnote-item {position:absolute;}" + "\n.pagination-marginnote > * {display: block;}" + "\n.pagination-index-page {float:right;}" + - "\n.pagination-index-list div {margin-left: 5px;)"; + "\n.pagination-index-list div {margin-left: 5px;}"; document.head.appendChild(stylesheet); }; @@ -417,9 +417,9 @@ + "\n@media screen{.pagination-page {border:solid 1px #000; " + "margin-bottom:.2in;}}" + "\n.pagination-main-contents-container {width:" + contentsWidth + ";}" + - "\n.pagination-contents-container {bottom:" + contentsBottomMargin + "; height:" + contentsHeight + "; display: -webkit-flex;}" + "\n.pagination-contents-container {bottom:" + contentsBottomMargin + "; height:" + contentsHeight + "; display: -webkit-flex; display: flex; }" + // Images should at max size be slightly smaller than the contentsWidth. - + "\nimg {max-height: " + imageMaxHeight + ";max-width: " + + "\nimg {max-height: " + imageMaxHeight + ";max-width: " + imageMaxWidth + ";}" + "\n.pagination-pagenumber {bottom:" + pagenumberBottomMargin + ";}" + "\n.pagination-header {top:" + headerTopMargin + ";}" + @@ -447,7 +447,7 @@ "{position: relative; top: -0.5em; font-size: 80%;}" + "\n.pagination-toc-entry .pagination-toc-pagenumber, " + ".pagination-tof-entry .pagination-tof-pagenumber, " + - ".pagination-tot-entry .pagination-tot-pagenumber {float:right}" + ".pagination-tot-entry .pagination-tot-pagenumber {float:right;}" /* This seems to be a bug in Webkit. But unless we set the width of the * original element that is being flown, some elements extend beyond the * mainContentsContainer's width. diff --git a/test.html b/test.html index b0635be..722b2ce 100644 --- a/test.html +++ b/test.html @@ -1,6 +1,7 @@ + BookJS test diff --git a/test2.html b/test2.html index deab5a0..4ed773e 100644 --- a/test2.html +++ b/test2.html @@ -2,6 +2,7 @@ + BookJS test diff --git a/test3.html b/test3.html index 2a13ac6..0a2c00b 100644 --- a/test3.html +++ b/test3.html @@ -2,6 +2,7 @@ + BookJS test diff --git a/test4.html b/test4.html index 340dfb5..1bad220 100644 --- a/test4.html +++ b/test4.html @@ -2,7 +2,8 @@ - + + The Malay Archipelago