mirror of
https://github.com/john-okeefe/foliate-js.git
synced 2026-09-09 11:29:14 -04:00
FXL: hide empty iframes
This commit is contained in:
+2
-2
@@ -111,13 +111,13 @@ export class FixedLayout extends HTMLElement {
|
||||
right.height ?? blankHeight))
|
||||
|
||||
const transform = frame => {
|
||||
const { element, iframe, width, height } = frame
|
||||
const { element, iframe, width, height, blank } = frame
|
||||
Object.assign(iframe.style, {
|
||||
width: `${width}px`,
|
||||
height: `${height}px`,
|
||||
transform: `scale(${scale})`,
|
||||
transformOrigin: 'top left',
|
||||
display: 'block',
|
||||
display: blank ? 'none' : 'block',
|
||||
})
|
||||
Object.assign(element.style, {
|
||||
width: `${(width ?? blankWidth) * scale}px`,
|
||||
|
||||
Reference in New Issue
Block a user