From ded2dd0341327bb8527f065702a02683e2edc920 Mon Sep 17 00:00:00 2001 From: "Yuichiro Tachibana (Tsuchiya)" Date: Wed, 15 Mar 2023 00:37:16 +0900 Subject: [PATCH] Split the section about embed=true parameter of embedded Streamlit apps --- docs/hub/spaces-sdks-streamlit.md | 25 +++++++++++++++++++++++-- 1 file changed, 23 insertions(+), 2 deletions(-) diff --git a/docs/hub/spaces-sdks-streamlit.md b/docs/hub/spaces-sdks-streamlit.md index a50360dca..ac81f665c 100644 --- a/docs/hub/spaces-sdks-streamlit.md +++ b/docs/hub/spaces-sdks-streamlit.md @@ -76,10 +76,33 @@ You can use the HTML ` +``` + + + +## Embed mode + +You can use the `embed=true` query parameter in the URL to activate the embed mode of the Streamlit app, removing some spacers and the footer for slim embeds. +Please note that this parameter disables scrolling in the iframe, so you'll need to set the height of the iframe enough to fit the embedded Streamlit app's content. + ``` ``` @@ -94,7 +117,5 @@ For example, the demo above can be embedded in these docs with the following tag sandbox="allow-forms allow-modals allow-popups allow-popups-to-escape-sandbox allow-same-origin allow-scripts allow-downloads" > -Please note that we have added `?embed=true` to the URL, which activates the embed mode of the Streamlit app, removing some spacers and the footer for slim embeds. - Additionally, you can checkout [our documentation](./spaces-embed).