From 3867cfbc570f70f6d91ee420aa7ae73360f9303f Mon Sep 17 00:00:00 2001 From: Rani Gangwar Date: Sat, 14 Nov 2026 17:50:02 +0530 Subject: [PATCH] SCAL-351912 --- modules/ROOT/pages/best-practices.adoc | 7 +++ modules/ROOT/pages/embed-a-viz.adoc | 2 +- modules/ROOT/pages/embed-new-spotter.adoc | 8 +++ modules/ROOT/pages/embed-pinboard.adoc | 6 ++ modules/ROOT/pages/embed-search.adoc | 2 +- modules/ROOT/pages/embed-spotter.adoc | 8 +++ modules/ROOT/pages/full-embed.adoc | 6 ++ .../ROOT/pages/lazy-loading-fullheight.adoc | 56 +++++++++++++++++-- 8 files changed, 88 insertions(+), 7 deletions(-) diff --git a/modules/ROOT/pages/best-practices.adoc b/modules/ROOT/pages/best-practices.adoc index 277e950af..6921deb27 100644 --- a/modules/ROOT/pages/best-practices.adoc +++ b/modules/ROOT/pages/best-practices.adoc @@ -19,6 +19,13 @@ The SDK provides different packages for embedding ThoughtSpot components in your + To avoid page scroll as visualizations load on a Liveboard, you can set the `fullHeight` property to `true` in the `LiveboardEmbed` code. +// SOURCE: SCAL-351912 +Size the embed frame appropriately:: +ThoughtSpot recommends an embed frame size of at least *300 px wide × 580 px high*. + +Set frame dimensions with `frameParams` or apply `min-width` and `min-height` constraints to the host container element in your CSS. + +For `LiveboardEmbed` and `AppEmbed` using `fullHeight: true`, set `minimumHeight` to 580 or higher — the default of 500 can clip parts of the UI. + +For more information, see xref:lazy-loading-fullheight.adoc#min-embed-size[Recommended minimum embed size]. + Prefetch and cache resources:: Use the `prefetch` method in the SDK to xref:prefetch-and-cache.adoc[prefetch and cache] static resources required for loading the embedded components. You can achieve this in two ways: diff --git a/modules/ROOT/pages/embed-a-viz.adoc b/modules/ROOT/pages/embed-a-viz.adoc index 763d737d6..e85b4d607 100644 --- a/modules/ROOT/pages/embed-a-viz.adoc +++ b/modules/ROOT/pages/embed-a-viz.adoc @@ -88,7 +88,7 @@ const liveboardEmbed = new LiveboardEmbed(document.getElementById('ts-embed'), { -frameParams:: Sets the `width` and `height` dimensions to render the visualization object. You can set the `width` and `height` attribute values in pixels or as a percentage. +frameParams:: Sets the `width` and `height` dimensions to render the visualization object. You can set the `width` and `height` attribute values in pixels or as a percentage. For the recommended minimum frame size, see xref:lazy-loading-fullheight.adoc#min-embed-size[Recommended minimum embed size]. include::{path}/additional-flags.adoc[] diff --git a/modules/ROOT/pages/embed-new-spotter.adoc b/modules/ROOT/pages/embed-new-spotter.adoc index 4ae238648..ebd462a97 100644 --- a/modules/ROOT/pages/embed-new-spotter.adoc +++ b/modules/ROOT/pages/embed-new-spotter.adoc @@ -114,6 +114,14 @@ const appEmbed = new AppEmbed(document.getElementById('ts-embed'), { appEmbed.render(); ---- +[NOTE] +==== +// SOURCE: SCAL-351912, SCAL-347722 +ThoughtSpot recommends an embed frame size of at least *300 px wide × 580 px high*. When using `height: '100%'`, make sure the host container is at least 580 px high. The `fullHeight` and `minimumHeight` parameters do not apply to `SpotterEmbed`. + +From ThoughtSpot Cloud release 26.11.0.cl, the Spotter landing panel scrolls in frames shorter than 580 px so the prompt input remains reachable. The 580 px minimum is still recommended for the full experience without scrolling. + +For more information, see xref:lazy-loading-fullheight.adoc#min-embed-size[Recommended minimum embed size]. +==== + == Spotter on Liveboards in embedded apps When the new experience is enabled, you'll see the following behavior: diff --git a/modules/ROOT/pages/embed-pinboard.adoc b/modules/ROOT/pages/embed-pinboard.adoc index 17359dd9e..b40243794 100644 --- a/modules/ROOT/pages/embed-pinboard.adoc +++ b/modules/ROOT/pages/embed-pinboard.adoc @@ -57,6 +57,12 @@ const liveboardEmbed = new LiveboardEmbed(document.getElementById('ts-embed'), { }); ---- +[NOTE] +==== +// SOURCE: SCAL-351912 +ThoughtSpot recommends an embed frame size of at least *300 px wide × 580 px high*. When using `height: '100%'`, make sure the host container is at least 580 px high. For full-height Liveboards, set `minimumHeight` to 580 or higher. For more information, see xref:lazy-loading-fullheight.adoc#min-embed-size[Recommended minimum embed size]. +==== + For more information about the Liveboard embed object, classes, methods, interface properties, and enumeration members, see the following pages: * xref:LiveboardEmbed.adoc[LiveboardEmbed] diff --git a/modules/ROOT/pages/embed-search.adoc b/modules/ROOT/pages/embed-search.adoc index e09949efa..18c48caca 100644 --- a/modules/ROOT/pages/embed-search.adoc +++ b/modules/ROOT/pages/embed-search.adoc @@ -111,7 +111,7 @@ const searchEmbed = new SearchEmbed(document.getElementById('ts-embed'), { //// frameParams:: -Sets the `width` and `height` dimensions to render the search object in a web browser. You can set the `width` and `height` attribute values in pixels or as a percentage. +Sets the `width` and `height` dimensions to render the search object in a web browser. You can set the `width` and `height` attribute values in pixels or as a percentage. ThoughtSpot recommends an embed frame size of at least 300 px wide × 580 px high. The `fullHeight` and `minimumHeight` parameters do not apply to `SearchEmbed`, so set the frame size with `frameParams` or by sizing the host container. For more information, see xref:lazy-loading-fullheight.adoc#min-embed-size[Recommended minimum embed size]. include::{path}/additional-flags.adoc[] diff --git a/modules/ROOT/pages/embed-spotter.adoc b/modules/ROOT/pages/embed-spotter.adoc index 5f14da352..ed822c548 100644 --- a/modules/ROOT/pages/embed-spotter.adoc +++ b/modules/ROOT/pages/embed-spotter.adoc @@ -98,6 +98,14 @@ const spotterEmbed = new SpotterEmbed(document.getElementById('ts-embed'), { }); ---- +[NOTE] +==== +// SOURCE: SCAL-351912, SCAL-347722 +ThoughtSpot recommends an embed frame size of at least *300 px wide × 580 px high* for Spotter. The `fullHeight` and `minimumHeight` parameters do not apply to `SpotterEmbed`. Set frame dimensions using `frameParams` or by applying `min-height: 580px` to the host container element in your CSS. + +From ThoughtSpot Cloud release 26.11.0.cl, the Spotter landing panel scrolls in frames shorter than 580 px so the prompt input remains reachable. The 580 px minimum is still recommended for the full experience without scrolling. + +For more information, see xref:lazy-loading-fullheight.adoc#min-embed-size[Recommended minimum embed size]. +==== + === Customize your embed (Optional) The SDK provides configuration settings to customize the embedded Spotter interface. For example, you can hide sample questions or disable data source selection using the `hideSampleQuestions` and `disableSourceSelection` parameters. diff --git a/modules/ROOT/pages/full-embed.adoc b/modules/ROOT/pages/full-embed.adoc index 4123abacd..466c562c1 100644 --- a/modules/ROOT/pages/full-embed.adoc +++ b/modules/ROOT/pages/full-embed.adoc @@ -76,6 +76,12 @@ const appEmbed = new AppEmbed(document.getElementById('ts-embed'), { }); ---- +[NOTE] +==== +// SOURCE: SCAL-351912 +ThoughtSpot recommends an embed frame size of at least *300 px wide × 580 px high*. If you set `fullHeight: true`, also set `minimumHeight` to 580 or higher, because the default of 500 can clip parts of the UI. For more information, see xref:lazy-loading-fullheight.adoc#min-embed-size[Recommended minimum embed size]. +==== + The `AppEmbed` component allows you to embed a specific application page or the entire application experience. If you are embedding the full experience, you can xref:set-default-page.adoc[set a specific application page as the default page when the embedded content loads] using the `pageId` or `path` property. diff --git a/modules/ROOT/pages/lazy-loading-fullheight.adoc b/modules/ROOT/pages/lazy-loading-fullheight.adoc index ed3d8c8bb..ca4e80905 100644 --- a/modules/ROOT/pages/lazy-loading-fullheight.adoc +++ b/modules/ROOT/pages/lazy-loading-fullheight.adoc @@ -2,12 +2,51 @@ :toc: true :toclevels: 1 -:page-title: Lazy loading of viusalizations on a Liveboard +:page-title: Lazy loading of visualizations on a Liveboard :page-pageid: lazy-load-fullHeight :page-description: Load visualizations progressively on embedded Liveboard The Visual Embed SDK provides configuration options to control how embedded apps handle the height of frame and loading of visualizations on an embedded Liveboard. +// SOURCE: SCAL-351912 +[#min-embed-size] +== Recommended minimum embed size + +ThoughtSpot recommends an embed frame size of at least *300 px wide × 580 px high* for all embedded components. Frames smaller than this may clip parts of the UI. + +You can set frame dimensions using the `frameParams` parameter in the embed configuration, or by applying `min-width` and `min-height` constraints to the host container element in your CSS. + +[source,JavaScript] +---- +const embed = new LiveboardEmbed('#embed', { + frameParams: { + width: '100%', + height: '100%', // Fills the host container + }, + liveboardId: 'your-liveboard-id', +}); +---- + +[source,CSS] +---- +#embed { + min-width: 300px; + min-height: 580px; +} +---- + +[NOTE] +==== +// SOURCE: SCAL-347722 fix (26.11.0.cl) +From 26.11.0.cl, the Spotter landing panel scrolls when the embed frame height is less than 580 px, so the prompt input remains reachable in short frames. The 580 px minimum is still recommended for the full experience without scrolling. +==== + +[IMPORTANT] +==== +// SOURCE: SCAL-351912 +The `fullHeight` and `minimumHeight` parameters apply only to `LiveboardEmbed` and `AppEmbed`. For `SearchEmbed`, `SearchBarEmbed`, and `SpotterEmbed`, size the embed frame using `frameParams` or by sizing the host container element. +==== + == Loading visualizations in the Liveboard viewport To dynamically resize the height of the Liveboard embed container, the Visual Embed SDK provides the `fullHeight` property. @@ -54,22 +93,29 @@ const embed = new LiveboardEmbed("#your-embed-div", { }); ---- +// SOURCE: SCAL-351912 == Full height with minimum height setting -In addition to `fullHeight`, the SDK also provides the `minimumHeight` parameter to set the minimum height (in pixels) for this container. The value defined for the `minimumHeight` attribute is applied only when `fullHeight` is set to `true`. -This ensures that even if the Liveboard is empty or has little content, the container maintains at least the specified minimum height. +In addition to `fullHeight`, the SDK provides the `minimumHeight` parameter to set the minimum height in pixels for the Liveboard or full application embed container. The `minimumHeight` parameter is available from Visual Embed SDK v1.44.2 and ThoughtSpot Cloud 10.15.0.cl, and replaces the deprecated `defaultHeight` parameter. The `minimumHeight` value applies only when `fullHeight` is set to `true`. + +Setting `minimumHeight` ensures that the container maintains at least the specified height even when the Liveboard is empty or has little content. + +[WARNING] +==== +The `minimumHeight` parameter defaults to *500 px*, which is below the recommended minimum height of 580 px. A full-height embed left at the default may clip parts of the UI. Set `minimumHeight` to *580 or higher* to avoid this. For more information, see xref:lazy-loading-fullheight.adoc#min-embed-size[Recommended minimum embed size]. +==== [source,JavaScript] ---- const embed = new LiveboardEmbed('#embed', { - // other liveboard view config fullHeight: true, - minimumHeight: 600, + minimumHeight: 580, // Set to 580 or higher; the default of 500 can clip the UI }); ---- == Additional resources * xref:embed-pinboard.adoc[Embedding a Liveboard] +* xref:full-embed.adoc[Embedding the full application] * xref:LiveboardViewConfig.adoc[Liveboard embed view configuration properties] * xref:AppViewConfig.adoc[Full app embed view configuration properties]