Skip to content

Commit

Permalink
ensure iframe is correct size on spaces (#5447)
Browse files Browse the repository at this point in the history
  • Loading branch information
pngwn committed Sep 7, 2023
1 parent 67bb7bc commit 7a4a89e
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 0 deletions.
6 changes: 6 additions & 0 deletions .changeset/six-months-act.md
@@ -0,0 +1,6 @@
---
"@gradio/app": patch
"gradio": patch
---

fix:ensure iframe is correct size on spaces
3 changes: 3 additions & 0 deletions js/app/index.html
Expand Up @@ -36,6 +36,9 @@

<script>
window.__gradio_mode__ = "app";
window.iFrameResizer = {
heightCalculationMethod: "taggedElement",
}
</script>

%gradio_config%
Expand Down
1 change: 1 addition & 0 deletions js/app/src/Embed.svelte
Expand Up @@ -20,6 +20,7 @@
class="gradio-container gradio-container-{version}"
style:min-height={loaded ? "initial" : initial_height}
style:flex-grow={!display ? "1" : "auto"}
data-iframe-height
>
<div class="main">
<slot />
Expand Down

0 comments on commit 7a4a89e

Please sign in to comment.