Commit cf7eb09b authored by Fred Chasen's avatar Fred Chasen

Set height: 100% on all page containing elements

parent a37f0e50
Pipeline #31 failed with stage
......@@ -507,7 +507,7 @@ class AtPage extends Handler {
list.append(hVar);
// Disabled due to causing issues with Chrome on print
/*
// width dimension
let widthList = new csstree.List();
widthList.insert(widthList.createItem({
......@@ -541,7 +541,7 @@ class AtPage extends Handler {
}
});
list.append(h);
*/
}
addMarginalia(page, list, item, sheet) {
......
......@@ -118,17 +118,17 @@ class Breaks extends Handler {
if (before.dataset.splitFrom) {
page.splitFrom = before.dataset.splitFrom;
page.element.setAttribute("data-split-from", before.dataset.splitFrom);
} else {
} else if (before.dataset.breakBefore && before.dataset.breakBefore !== "avoid") {
page.breakBefore = before.dataset.breakBefore;
page.element.setAttribute("data-break-before", before.dataset.breakBefore);
}
}
if (after) {
if (after && after.dataset) {
if (after.dataset.splitTo) {
page.splitTo = after.dataset.splitTo;
page.element.setAttribute("data-split-to", after.dataset.splitTo);
} else {
} else if (after.dataset.breakAfter && after.dataset.breakAfter !== "avoid") {
page.breakAfter = after.dataset.breakAfter;
page.element.setAttribute("data-break-after", after.dataset.breakAfter);
}
......
......@@ -224,7 +224,7 @@ export default `
.pagedjs_pages > .pagedjs_page > .pagedjs_area > div [data-split-from]::first-letter {
color: unset;
font-size: unset;
font-wieght: unset;
font-weight: unset;
font-family: unset;
color: unset;
line-height: unset;
......@@ -260,23 +260,35 @@ export default `
}
@media print {
html {
width: 100%;
height: 100%;
}
body {
width: unset;
height: unset;
margin: 0;
padding: 0;
width: 100% !important;
height: 100% !important;
min-width: 100%;
max-width: 100%;
min-height: 100%;
max-height: 100%;
}
.pagedjs_pages {
width: var(--width);
display: block;
display: block !important;
transform: none !important;
height: 100% !important;
min-height: 100%;
max-height: 100%;
overflow: visible;
}
.pagedjs_page {
margin: 0;
padding: 0;
width: 100%;
height: 100%;
break-before: page;
max-height: 100%;
min-height: 100%;
height: 100% !important;
break-after: page;
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment