fix: Forge iframe fills full modal height (position:absolute)
.editor-body has flex height, so percentage height on iframe didn't work. Changed to position:absolute;inset:0 which fills the relative parent regardless of flex sizing.
This commit is contained in:
+1
-1
@@ -3302,7 +3302,7 @@
|
|||||||
var iframe = document.createElement("iframe");
|
var iframe = document.createElement("iframe");
|
||||||
iframe.id = "forge-iframe";
|
iframe.id = "forge-iframe";
|
||||||
iframe.src = "/editor-poc?vault=" + encodeURIComponent(data.vault) + "&path=" + encodeURIComponent(data.path);
|
iframe.src = "/editor-poc?vault=" + encodeURIComponent(data.vault) + "&path=" + encodeURIComponent(data.path);
|
||||||
iframe.style.cssText = "width:100%;height:100%;border:none;";
|
iframe.style.cssText = "position:absolute;top:0;left:0;width:100%;height:100%;border:none;";
|
||||||
bodyEl.appendChild(iframe);
|
bodyEl.appendChild(iframe);
|
||||||
modal.classList.add("active");
|
modal.classList.add("active");
|
||||||
safeCreateIcons();
|
safeCreateIcons();
|
||||||
|
|||||||
@@ -507,7 +507,7 @@ export function renderFile(data) {
|
|||||||
var iframe = document.createElement("iframe");
|
var iframe = document.createElement("iframe");
|
||||||
iframe.id = "forge-iframe";
|
iframe.id = "forge-iframe";
|
||||||
iframe.src = "/editor-poc?vault=" + encodeURIComponent(data.vault) + "&path=" + encodeURIComponent(data.path);
|
iframe.src = "/editor-poc?vault=" + encodeURIComponent(data.vault) + "&path=" + encodeURIComponent(data.path);
|
||||||
iframe.style.cssText = "width:100%;height:100%;border:none;";
|
iframe.style.cssText = "position:absolute;top:0;left:0;width:100%;height:100%;border:none;";
|
||||||
bodyEl.appendChild(iframe);
|
bodyEl.appendChild(iframe);
|
||||||
modal.classList.add("active");
|
modal.classList.add("active");
|
||||||
safeCreateIcons();
|
safeCreateIcons();
|
||||||
|
|||||||
Reference in New Issue
Block a user