@thoughtspot/visual-embed-sdk 1.51.2 → 1.52.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/cjs/package.json +9 -1
- package/cjs/src/api-intercept.d.ts.map +1 -1
- package/cjs/src/api-intercept.js +1 -0
- package/cjs/src/api-intercept.js.map +1 -1
- package/cjs/src/contracts/contracts.spec.d.ts +2 -0
- package/cjs/src/contracts/contracts.spec.d.ts.map +1 -0
- package/cjs/src/contracts/contracts.spec.js +345 -0
- package/cjs/src/contracts/contracts.spec.js.map +1 -0
- package/cjs/src/contracts/embed-event-payloads.d.ts +73 -0
- package/cjs/src/contracts/embed-event-payloads.d.ts.map +1 -0
- package/cjs/src/contracts/embed-event-payloads.js +3 -0
- package/cjs/src/contracts/embed-event-payloads.js.map +1 -0
- package/cjs/src/contracts/host-event-contracts.d.ts +378 -0
- package/cjs/src/contracts/host-event-contracts.d.ts.map +1 -0
- package/cjs/src/contracts/host-event-contracts.js +3 -0
- package/cjs/src/contracts/host-event-contracts.js.map +1 -0
- package/cjs/src/contracts/index.d.ts +22 -0
- package/cjs/src/contracts/index.d.ts.map +1 -0
- package/cjs/src/contracts/index.js +33 -0
- package/cjs/src/contracts/index.js.map +1 -0
- package/cjs/src/contracts/ui-passthrough-contracts.d.ts +277 -0
- package/cjs/src/contracts/ui-passthrough-contracts.d.ts.map +1 -0
- package/cjs/src/{embed/hostEventClient/contracts.js → contracts/ui-passthrough-contracts.js} +6 -2
- package/cjs/src/contracts/ui-passthrough-contracts.js.map +1 -0
- package/cjs/src/css-variables.d.ts +1 -1
- package/cjs/src/embed/app.d.ts +17 -140
- package/cjs/src/embed/app.d.ts.map +1 -1
- package/cjs/src/embed/app.js +20 -120
- package/cjs/src/embed/app.js.map +1 -1
- package/cjs/src/embed/app.spec.js +70 -26
- package/cjs/src/embed/app.spec.js.map +1 -1
- package/cjs/src/embed/conversation.d.ts +5 -5
- package/cjs/src/embed/events.spec.js +12 -2
- package/cjs/src/embed/events.spec.js.map +1 -1
- package/cjs/src/embed/hostEventClient/host-event-client.d.ts +3 -2
- package/cjs/src/embed/hostEventClient/host-event-client.d.ts.map +1 -1
- package/cjs/src/embed/hostEventClient/host-event-client.js +23 -18
- package/cjs/src/embed/hostEventClient/host-event-client.js.map +1 -1
- package/cjs/src/embed/hostEventClient/host-event-client.spec.js +36 -36
- package/cjs/src/embed/hostEventClient/host-event-client.spec.js.map +1 -1
- package/cjs/src/embed/hostEventClient/utils.d.ts +1 -1
- package/cjs/src/embed/hostEventClient/utils.d.ts.map +1 -1
- package/cjs/src/embed/hostEventClient/utils.js +3 -3
- package/cjs/src/embed/hostEventClient/utils.js.map +1 -1
- package/cjs/src/embed/liveboard.d.ts +9 -161
- package/cjs/src/embed/liveboard.d.ts.map +1 -1
- package/cjs/src/embed/liveboard.js +68 -135
- package/cjs/src/embed/liveboard.js.map +1 -1
- package/cjs/src/embed/liveboard.spec.js +215 -32
- package/cjs/src/embed/liveboard.spec.js.map +1 -1
- package/cjs/src/embed/search.d.ts +14 -0
- package/cjs/src/embed/search.d.ts.map +1 -1
- package/cjs/src/embed/search.js +4 -1
- package/cjs/src/embed/search.js.map +1 -1
- package/cjs/src/embed/search.spec.js +65 -0
- package/cjs/src/embed/search.spec.js.map +1 -1
- package/cjs/src/embed/ts-embed.d.ts +21 -25
- package/cjs/src/embed/ts-embed.d.ts.map +1 -1
- package/cjs/src/embed/ts-embed.js +105 -72
- package/cjs/src/embed/ts-embed.js.map +1 -1
- package/cjs/src/embed/ts-embed.spec.d.ts.map +1 -1
- package/cjs/src/embed/ts-embed.spec.js +380 -33
- package/cjs/src/embed/ts-embed.spec.js.map +1 -1
- package/cjs/src/full-height.d.ts +137 -0
- package/cjs/src/full-height.d.ts.map +1 -0
- package/cjs/src/full-height.js +272 -0
- package/cjs/src/full-height.js.map +1 -0
- package/cjs/src/full-height.spec.d.ts +2 -0
- package/cjs/src/full-height.spec.d.ts.map +1 -0
- package/cjs/src/full-height.spec.js +835 -0
- package/cjs/src/full-height.spec.js.map +1 -0
- package/cjs/src/index.d.ts +4 -3
- package/cjs/src/index.d.ts.map +1 -1
- package/cjs/src/index.js +5 -4
- package/cjs/src/index.js.map +1 -1
- package/cjs/src/react/all-types-export.d.ts +1 -1
- package/cjs/src/react/all-types-export.d.ts.map +1 -1
- package/cjs/src/react/all-types-export.js +2 -1
- package/cjs/src/react/all-types-export.js.map +1 -1
- package/cjs/src/react/all-types-export.parity.spec.js +55 -3
- package/cjs/src/react/all-types-export.parity.spec.js.map +1 -1
- package/cjs/src/react/index.d.ts +8 -8
- package/cjs/src/react/index.d.ts.map +1 -1
- package/cjs/src/react/index.js +1 -1
- package/cjs/src/react/index.js.map +1 -1
- package/cjs/src/react/index.spec.js +7 -7
- package/cjs/src/react/index.spec.js.map +1 -1
- package/cjs/src/types.d.ts +664 -39
- package/cjs/src/types.d.ts.map +1 -1
- package/cjs/src/types.js +406 -13
- package/cjs/src/types.js.map +1 -1
- package/cjs/src/utils/processTrigger.d.ts +3 -1
- package/cjs/src/utils/processTrigger.d.ts.map +1 -1
- package/cjs/src/utils/processTrigger.js +19 -51
- package/cjs/src/utils/processTrigger.js.map +1 -1
- package/cjs/src/utils/transport/iframe-transport.d.ts +55 -0
- package/cjs/src/utils/transport/iframe-transport.d.ts.map +1 -0
- package/cjs/src/utils/transport/iframe-transport.js +108 -0
- package/cjs/src/utils/transport/iframe-transport.js.map +1 -0
- package/cjs/src/utils/transport/iframe-transport.spec.d.ts +2 -0
- package/cjs/src/utils/transport/iframe-transport.spec.d.ts.map +1 -0
- package/cjs/src/utils/transport/iframe-transport.spec.js +140 -0
- package/cjs/src/utils/transport/iframe-transport.spec.js.map +1 -0
- package/cjs/src/utils.d.ts +18 -0
- package/cjs/src/utils.d.ts.map +1 -1
- package/cjs/src/utils.js +39 -1
- package/cjs/src/utils.js.map +1 -1
- package/cjs/src/utils.spec.js +62 -0
- package/cjs/src/utils.spec.js.map +1 -1
- package/dist/{index-D8_Zs-Nr.js → index-C1pmYb5H.js} +1 -1
- package/dist/src/api-intercept.d.ts.map +1 -1
- package/dist/src/contracts/contracts.spec.d.ts +2 -0
- package/dist/src/contracts/contracts.spec.d.ts.map +1 -0
- package/dist/src/contracts/embed-event-payloads.d.ts +73 -0
- package/dist/src/contracts/embed-event-payloads.d.ts.map +1 -0
- package/dist/src/contracts/host-event-contracts.d.ts +378 -0
- package/dist/src/contracts/host-event-contracts.d.ts.map +1 -0
- package/dist/src/contracts/index.d.ts +22 -0
- package/dist/src/contracts/index.d.ts.map +1 -0
- package/dist/src/contracts/ui-passthrough-contracts.d.ts +277 -0
- package/dist/src/contracts/ui-passthrough-contracts.d.ts.map +1 -0
- package/dist/src/css-variables.d.ts +1 -1
- package/dist/src/embed/app.d.ts +17 -140
- package/dist/src/embed/app.d.ts.map +1 -1
- package/dist/src/embed/conversation.d.ts +5 -5
- package/dist/src/embed/hostEventClient/host-event-client.d.ts +3 -2
- package/dist/src/embed/hostEventClient/host-event-client.d.ts.map +1 -1
- package/dist/src/embed/hostEventClient/utils.d.ts +1 -1
- package/dist/src/embed/hostEventClient/utils.d.ts.map +1 -1
- package/dist/src/embed/liveboard.d.ts +9 -161
- package/dist/src/embed/liveboard.d.ts.map +1 -1
- package/dist/src/embed/search.d.ts +14 -0
- package/dist/src/embed/search.d.ts.map +1 -1
- package/dist/src/embed/ts-embed.d.ts +21 -25
- package/dist/src/embed/ts-embed.d.ts.map +1 -1
- package/dist/src/embed/ts-embed.spec.d.ts.map +1 -1
- package/dist/src/full-height.d.ts +137 -0
- package/dist/src/full-height.d.ts.map +1 -0
- package/dist/src/full-height.spec.d.ts +2 -0
- package/dist/src/full-height.spec.d.ts.map +1 -0
- package/dist/src/index.d.ts +4 -3
- package/dist/src/index.d.ts.map +1 -1
- package/dist/src/react/all-types-export.d.ts +1 -1
- package/dist/src/react/all-types-export.d.ts.map +1 -1
- package/dist/src/react/index.d.ts +8 -8
- package/dist/src/react/index.d.ts.map +1 -1
- package/dist/src/types.d.ts +664 -39
- package/dist/src/types.d.ts.map +1 -1
- package/dist/src/utils/processTrigger.d.ts +3 -1
- package/dist/src/utils/processTrigger.d.ts.map +1 -1
- package/dist/src/utils/transport/iframe-transport.d.ts +55 -0
- package/dist/src/utils/transport/iframe-transport.d.ts.map +1 -0
- package/dist/src/utils/transport/iframe-transport.spec.d.ts +2 -0
- package/dist/src/utils/transport/iframe-transport.spec.d.ts.map +1 -0
- package/dist/src/utils.d.ts +18 -0
- package/dist/src/utils.d.ts.map +1 -1
- package/dist/tsembed-react.es.js +1031 -392
- package/dist/tsembed-react.js +1030 -391
- package/dist/tsembed.es.js +1031 -392
- package/dist/tsembed.js +1029 -390
- package/dist/visual-embed-sdk-react-full.d.ts +1483 -693
- package/dist/visual-embed-sdk-react.d.ts +1364 -647
- package/dist/visual-embed-sdk.d.ts +1426 -659
- package/lib/package.json +9 -1
- package/lib/src/api-intercept.d.ts.map +1 -1
- package/lib/src/api-intercept.js +2 -1
- package/lib/src/api-intercept.js.map +1 -1
- package/lib/src/contracts/contracts.spec.d.ts +2 -0
- package/lib/src/contracts/contracts.spec.d.ts.map +1 -0
- package/lib/src/contracts/contracts.spec.js +342 -0
- package/lib/src/contracts/contracts.spec.js.map +1 -0
- package/lib/src/contracts/embed-event-payloads.d.ts +73 -0
- package/lib/src/contracts/embed-event-payloads.d.ts.map +1 -0
- package/lib/src/contracts/embed-event-payloads.js +2 -0
- package/lib/src/contracts/embed-event-payloads.js.map +1 -0
- package/lib/src/contracts/host-event-contracts.d.ts +378 -0
- package/lib/src/contracts/host-event-contracts.d.ts.map +1 -0
- package/lib/src/contracts/host-event-contracts.js +2 -0
- package/lib/src/contracts/host-event-contracts.js.map +1 -0
- package/lib/src/contracts/index.d.ts +22 -0
- package/lib/src/contracts/index.d.ts.map +1 -0
- package/lib/src/contracts/index.js +22 -0
- package/lib/src/contracts/index.js.map +1 -0
- package/lib/src/contracts/ui-passthrough-contracts.d.ts +277 -0
- package/lib/src/contracts/ui-passthrough-contracts.d.ts.map +1 -0
- package/lib/src/{embed/hostEventClient/contracts.js → contracts/ui-passthrough-contracts.js} +6 -2
- package/lib/src/contracts/ui-passthrough-contracts.js.map +1 -0
- package/lib/src/css-variables.d.ts +1 -1
- package/lib/src/embed/app.d.ts +17 -140
- package/lib/src/embed/app.d.ts.map +1 -1
- package/lib/src/embed/app.js +22 -122
- package/lib/src/embed/app.js.map +1 -1
- package/lib/src/embed/app.spec.js +70 -26
- package/lib/src/embed/app.spec.js.map +1 -1
- package/lib/src/embed/conversation.d.ts +5 -5
- package/lib/src/embed/events.spec.js +12 -2
- package/lib/src/embed/events.spec.js.map +1 -1
- package/lib/src/embed/hostEventClient/host-event-client.d.ts +3 -2
- package/lib/src/embed/hostEventClient/host-event-client.d.ts.map +1 -1
- package/lib/src/embed/hostEventClient/host-event-client.js +6 -1
- package/lib/src/embed/hostEventClient/host-event-client.js.map +1 -1
- package/lib/src/embed/hostEventClient/host-event-client.spec.js +1 -1
- package/lib/src/embed/hostEventClient/host-event-client.spec.js.map +1 -1
- package/lib/src/embed/hostEventClient/utils.d.ts +1 -1
- package/lib/src/embed/hostEventClient/utils.d.ts.map +1 -1
- package/lib/src/embed/hostEventClient/utils.js +1 -1
- package/lib/src/embed/hostEventClient/utils.js.map +1 -1
- package/lib/src/embed/liveboard.d.ts +9 -161
- package/lib/src/embed/liveboard.d.ts.map +1 -1
- package/lib/src/embed/liveboard.js +70 -137
- package/lib/src/embed/liveboard.js.map +1 -1
- package/lib/src/embed/liveboard.spec.js +215 -32
- package/lib/src/embed/liveboard.spec.js.map +1 -1
- package/lib/src/embed/search.d.ts +14 -0
- package/lib/src/embed/search.d.ts.map +1 -1
- package/lib/src/embed/search.js +4 -1
- package/lib/src/embed/search.js.map +1 -1
- package/lib/src/embed/search.spec.js +65 -0
- package/lib/src/embed/search.spec.js.map +1 -1
- package/lib/src/embed/ts-embed.d.ts +21 -25
- package/lib/src/embed/ts-embed.d.ts.map +1 -1
- package/lib/src/embed/ts-embed.js +106 -73
- package/lib/src/embed/ts-embed.js.map +1 -1
- package/lib/src/embed/ts-embed.spec.d.ts.map +1 -1
- package/lib/src/embed/ts-embed.spec.js +378 -31
- package/lib/src/embed/ts-embed.spec.js.map +1 -1
- package/lib/src/full-height.d.ts +137 -0
- package/lib/src/full-height.d.ts.map +1 -0
- package/lib/src/full-height.js +268 -0
- package/lib/src/full-height.js.map +1 -0
- package/lib/src/full-height.spec.d.ts +2 -0
- package/lib/src/full-height.spec.d.ts.map +1 -0
- package/lib/src/full-height.spec.js +833 -0
- package/lib/src/full-height.spec.js.map +1 -0
- package/lib/src/index.d.ts +4 -3
- package/lib/src/index.d.ts.map +1 -1
- package/lib/src/index.js +3 -3
- package/lib/src/index.js.map +1 -1
- package/lib/src/react/all-types-export.d.ts +1 -1
- package/lib/src/react/all-types-export.d.ts.map +1 -1
- package/lib/src/react/all-types-export.js +1 -1
- package/lib/src/react/all-types-export.js.map +1 -1
- package/lib/src/react/all-types-export.parity.spec.js +55 -3
- package/lib/src/react/all-types-export.parity.spec.js.map +1 -1
- package/lib/src/react/index.d.ts +8 -8
- package/lib/src/react/index.d.ts.map +1 -1
- package/lib/src/react/index.js +1 -1
- package/lib/src/react/index.js.map +1 -1
- package/lib/src/react/index.spec.js +7 -7
- package/lib/src/react/index.spec.js.map +1 -1
- package/lib/src/types.d.ts +664 -39
- package/lib/src/types.d.ts.map +1 -1
- package/lib/src/types.js +405 -12
- package/lib/src/types.js.map +1 -1
- package/lib/src/utils/processTrigger.d.ts +3 -1
- package/lib/src/utils/processTrigger.d.ts.map +1 -1
- package/lib/src/utils/processTrigger.js +19 -51
- package/lib/src/utils/processTrigger.js.map +1 -1
- package/lib/src/utils/transport/iframe-transport.d.ts +55 -0
- package/lib/src/utils/transport/iframe-transport.d.ts.map +1 -0
- package/lib/src/utils/transport/iframe-transport.js +101 -0
- package/lib/src/utils/transport/iframe-transport.js.map +1 -0
- package/lib/src/utils/transport/iframe-transport.spec.d.ts +2 -0
- package/lib/src/utils/transport/iframe-transport.spec.d.ts.map +1 -0
- package/lib/src/utils/transport/iframe-transport.spec.js +138 -0
- package/lib/src/utils/transport/iframe-transport.spec.js.map +1 -0
- package/lib/src/utils.d.ts +18 -0
- package/lib/src/utils.d.ts.map +1 -1
- package/lib/src/utils.js +37 -0
- package/lib/src/utils.js.map +1 -1
- package/lib/src/utils.spec.js +63 -1
- package/lib/src/utils.spec.js.map +1 -1
- package/lib/src/visual-embed-sdk.d.ts +1426 -659
- package/package.json +9 -1
- package/src/api-intercept.ts +2 -1
- package/src/contracts/contracts.spec.ts +392 -0
- package/src/contracts/embed-event-payloads.ts +83 -0
- package/src/contracts/host-event-contracts.ts +456 -0
- package/src/contracts/index.ts +53 -0
- package/src/contracts/ui-passthrough-contracts.ts +301 -0
- package/src/css-variables.ts +1 -1
- package/src/embed/app.spec.ts +86 -34
- package/src/embed/app.ts +37 -264
- package/src/embed/conversation.ts +5 -5
- package/src/embed/events.spec.ts +14 -2
- package/src/embed/hostEventClient/host-event-client.spec.ts +2 -2
- package/src/embed/hostEventClient/host-event-client.ts +18 -5
- package/src/embed/hostEventClient/utils.ts +2 -1
- package/src/embed/liveboard.spec.ts +261 -42
- package/src/embed/liveboard.ts +78 -297
- package/src/embed/search.spec.ts +80 -0
- package/src/embed/search.ts +20 -0
- package/src/embed/ts-embed.spec.ts +518 -31
- package/src/embed/ts-embed.ts +133 -82
- package/src/full-height.spec.ts +1008 -0
- package/src/full-height.ts +361 -0
- package/src/index.ts +95 -5
- package/src/react/all-types-export.parity.spec.ts +63 -3
- package/src/react/all-types-export.ts +46 -0
- package/src/react/index.spec.tsx +7 -7
- package/src/react/index.tsx +9 -9
- package/src/types.ts +665 -37
- package/src/utils/processTrigger.ts +28 -58
- package/src/utils/transport/iframe-transport.spec.ts +177 -0
- package/src/utils/transport/iframe-transport.ts +122 -0
- package/src/utils.spec.ts +71 -0
- package/src/utils.ts +38 -0
- package/cjs/src/embed/hostEventClient/contracts.d.ts +0 -231
- package/cjs/src/embed/hostEventClient/contracts.d.ts.map +0 -1
- package/cjs/src/embed/hostEventClient/contracts.js.map +0 -1
- package/dist/src/embed/hostEventClient/contracts.d.ts +0 -231
- package/dist/src/embed/hostEventClient/contracts.d.ts.map +0 -1
- package/lib/src/embed/hostEventClient/contracts.d.ts +0 -231
- package/lib/src/embed/hostEventClient/contracts.d.ts.map +0 -1
- package/lib/src/embed/hostEventClient/contracts.js.map +0 -1
- package/src/embed/hostEventClient/contracts.ts +0 -262
package/dist/src/types.d.ts
CHANGED
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
*/
|
|
8
8
|
import { CustomCssVariables } from './css-variables';
|
|
9
9
|
import type { SessionInterface } from './utils/graphql/answerService/answerService';
|
|
10
|
+
import type { Applicability } from './contracts/ui-passthrough-contracts';
|
|
10
11
|
/**
|
|
11
12
|
* The authentication mechanism for allowing access to
|
|
12
13
|
* the embedded app
|
|
@@ -862,9 +863,11 @@ export interface FrameParams {
|
|
|
862
863
|
}
|
|
863
864
|
/**
|
|
864
865
|
* Configuration for the pre-render wrapper element.
|
|
865
|
-
*
|
|
866
|
-
* {@link BaseViewConfig}
|
|
867
|
-
*
|
|
866
|
+
* Each property here supersedes its deprecated top-level counterpart on
|
|
867
|
+
* {@link BaseViewConfig} — `id` over `preRenderId`, `containerSelector` over
|
|
868
|
+
* `preRenderContainer` and `doNotTrackSize` over `doNotTrackPreRenderSize` —
|
|
869
|
+
* and takes precedence when both are set, so existing top-level usage continues
|
|
870
|
+
* to work without any changes.
|
|
868
871
|
*
|
|
869
872
|
* @version SDK: 1.52.0
|
|
870
873
|
* @example
|
|
@@ -872,9 +875,9 @@ export interface FrameParams {
|
|
|
872
875
|
* init({ thoughtSpotHost: '...', authType: AuthType.None });
|
|
873
876
|
* const embed = new LiveboardEmbed('#tsEmbed', {
|
|
874
877
|
* preRenderConfig: {
|
|
875
|
-
*
|
|
876
|
-
*
|
|
877
|
-
*
|
|
878
|
+
* id: 'my-liveboard',
|
|
879
|
+
* containerSelector: '#my-scroll-container',
|
|
880
|
+
* doNotTrackSize: false,
|
|
878
881
|
* zIndex: -10,
|
|
879
882
|
* },
|
|
880
883
|
* });
|
|
@@ -895,7 +898,7 @@ export interface PreRenderConfig {
|
|
|
895
898
|
*
|
|
896
899
|
* @default undefined
|
|
897
900
|
*/
|
|
898
|
-
|
|
901
|
+
id?: string;
|
|
899
902
|
/**
|
|
900
903
|
* The DOM element or CSS selector string specifying the container into
|
|
901
904
|
* which the pre-rendered wrapper is inserted.
|
|
@@ -911,7 +914,7 @@ export interface PreRenderConfig {
|
|
|
911
914
|
*
|
|
912
915
|
* @default document.body
|
|
913
916
|
*/
|
|
914
|
-
|
|
917
|
+
containerSelector?: string | HTMLElement;
|
|
915
918
|
/**
|
|
916
919
|
* Disables the `ResizeObserver` that keeps the wrapper sized to the
|
|
917
920
|
* placeholder element.
|
|
@@ -923,7 +926,7 @@ export interface PreRenderConfig {
|
|
|
923
926
|
*
|
|
924
927
|
* @default false
|
|
925
928
|
*/
|
|
926
|
-
|
|
929
|
+
doNotTrackSize?: boolean;
|
|
927
930
|
/**
|
|
928
931
|
* CSS `z-index` value applied to the pre-render wrapper when hidden.
|
|
929
932
|
* Override this when the host page's stacking context does not reach `-1000`
|
|
@@ -1130,7 +1133,7 @@ export interface BaseViewConfig extends ApiInterceptFlags {
|
|
|
1130
1133
|
*
|
|
1131
1134
|
* Supported embed types: `AppEmbed`, `LiveboardEmbed`, `SearchEmbed`, `SpotterAgentEmbed`, `SpotterEmbed`, `SearchBarEmbed`
|
|
1132
1135
|
* @version SDK: 1.25.0 | ThoughtSpot: 9.6.0.cl, 9.8.0.sw
|
|
1133
|
-
* @deprecated Use {@link PreRenderConfig.
|
|
1136
|
+
* @deprecated Use {@link PreRenderConfig.id} via `preRenderConfig` instead.
|
|
1134
1137
|
* @example
|
|
1135
1138
|
* ```js
|
|
1136
1139
|
* // Replace <EmbedComponent> with embed component name. For example, AppEmbed, SearchEmbed, or LiveboardEmbed
|
|
@@ -1150,7 +1153,7 @@ export interface BaseViewConfig extends ApiInterceptFlags {
|
|
|
1150
1153
|
* @type {boolean}
|
|
1151
1154
|
* @default false
|
|
1152
1155
|
* @version SDK: 1.24.0 | ThoughtSpot: 9.4.0.cl, 9.4.0.sw
|
|
1153
|
-
* @deprecated Use {@link PreRenderConfig.
|
|
1156
|
+
* @deprecated Use {@link PreRenderConfig.doNotTrackSize} via `preRenderConfig` instead.
|
|
1154
1157
|
* @example
|
|
1155
1158
|
* ```js
|
|
1156
1159
|
* // Disable tracking PreRender size in the configuration
|
|
@@ -1192,7 +1195,7 @@ export interface BaseViewConfig extends ApiInterceptFlags {
|
|
|
1192
1195
|
*
|
|
1193
1196
|
* @type {string | HTMLElement}
|
|
1194
1197
|
* @version SDK: 1.49.2 | ThoughtSpot: *
|
|
1195
|
-
* @deprecated Use {@link PreRenderConfig.
|
|
1198
|
+
* @deprecated Use {@link PreRenderConfig.containerSelector} via `preRenderConfig` instead.
|
|
1196
1199
|
* @example
|
|
1197
1200
|
* ```js
|
|
1198
1201
|
* const embed = new LiveboardEmbed('#tsEmbed', {
|
|
@@ -1205,9 +1208,11 @@ export interface BaseViewConfig extends ApiInterceptFlags {
|
|
|
1205
1208
|
preRenderContainer?: string | HTMLElement;
|
|
1206
1209
|
/**
|
|
1207
1210
|
* Configuration for the pre-render wrapper element.
|
|
1208
|
-
*
|
|
1209
|
-
* `BaseViewConfig`
|
|
1210
|
-
*
|
|
1211
|
+
* Each property here supersedes its deprecated top-level counterpart on
|
|
1212
|
+
* `BaseViewConfig` — `id` over `preRenderId`, `containerSelector` over
|
|
1213
|
+
* `preRenderContainer` and `doNotTrackSize` over `doNotTrackPreRenderSize` —
|
|
1214
|
+
* and takes precedence when both are set, so existing top-level usage
|
|
1215
|
+
* continues to work without any changes.
|
|
1211
1216
|
* See {@link PreRenderConfig} for available options.
|
|
1212
1217
|
*
|
|
1213
1218
|
* @version SDK: 1.52.0
|
|
@@ -1215,7 +1220,7 @@ export interface BaseViewConfig extends ApiInterceptFlags {
|
|
|
1215
1220
|
* ```js
|
|
1216
1221
|
* const embed = new LiveboardEmbed('#tsEmbed', {
|
|
1217
1222
|
* preRenderConfig: {
|
|
1218
|
-
*
|
|
1223
|
+
* id: 'my-liveboard',
|
|
1219
1224
|
* zIndex: -10,
|
|
1220
1225
|
* },
|
|
1221
1226
|
* });
|
|
@@ -1982,7 +1987,7 @@ export interface LiveboardAppEmbedViewConfig {
|
|
|
1982
1987
|
*
|
|
1983
1988
|
* Supported embed types: `AppEmbed`, `LiveboardEmbed`
|
|
1984
1989
|
* @type {boolean}
|
|
1985
|
-
* @version SDK: 1.
|
|
1990
|
+
* @version SDK: 1.51.1 | ThoughtSpot Cloud: 26.8.0.cl
|
|
1986
1991
|
* @default false
|
|
1987
1992
|
* @example
|
|
1988
1993
|
* ```js
|
|
@@ -2107,7 +2112,7 @@ export interface LiveboardAppEmbedViewConfig {
|
|
|
2107
2112
|
*
|
|
2108
2113
|
* Supported embed types: `AppEmbed`, `LiveboardEmbed`
|
|
2109
2114
|
* @type {number}
|
|
2110
|
-
* @version SDK: 1.
|
|
2115
|
+
* @version SDK: 1.51.1 | ThoughtSpot Cloud: 26.8.0.cl
|
|
2111
2116
|
* @example
|
|
2112
2117
|
* ```js
|
|
2113
2118
|
* // Replace <EmbedComponent> with embed component name. For example, AppEmbed or LiveboardEmbed
|
|
@@ -2452,6 +2457,15 @@ export interface RuntimeParameter {
|
|
|
2452
2457
|
* Values
|
|
2453
2458
|
*/
|
|
2454
2459
|
value: number | boolean | string;
|
|
2460
|
+
/**
|
|
2461
|
+
* Whether the parameter is visible to the user (`UpdateParameters` only).
|
|
2462
|
+
*/
|
|
2463
|
+
isVisibleToUser?: boolean;
|
|
2464
|
+
/**
|
|
2465
|
+
* Scope of the update (`UpdateParameters` only). Omitting it, or `level`,
|
|
2466
|
+
* targets the Liveboard level.
|
|
2467
|
+
*/
|
|
2468
|
+
applicability?: Applicability;
|
|
2455
2469
|
}
|
|
2456
2470
|
/**
|
|
2457
2471
|
* Event types emitted by the embedded ThoughtSpot application.
|
|
@@ -2903,6 +2917,9 @@ export declare enum EmbedEvent {
|
|
|
2903
2917
|
Download = "download",
|
|
2904
2918
|
/**
|
|
2905
2919
|
* Emitted when the download action is triggered on an Answer.
|
|
2920
|
+
* Payload varies by context: {@link VizScopedRequest} (Search, Answer,
|
|
2921
|
+
* Liveboard), {@link RequiredVizRequest} (Spotter, vizId required). trigger()
|
|
2922
|
+
* accepts the union now; per-context enforced next release.
|
|
2906
2923
|
* Use start:true to subscribe to when download is initiated, or end:true to
|
|
2907
2924
|
* subscribe to when download is completed. Default is end:true.
|
|
2908
2925
|
* @version SDK: 1.21.0 | ThoughtSpot: 9.2.0.cl, 9.4.0.sw
|
|
@@ -2919,6 +2936,9 @@ export declare enum EmbedEvent {
|
|
|
2919
2936
|
DownloadAsPng = "downloadAsPng",
|
|
2920
2937
|
/**
|
|
2921
2938
|
* Emitted when the Download as PDF action is triggered on an Answer
|
|
2939
|
+
* Payload varies by context: {@link VizScopedRequest} (Search, Answer; plus
|
|
2940
|
+
* liveboardId on Liveboard), {@link RequiredVizRequest} (Spotter). trigger()
|
|
2941
|
+
* accepts the union now; per-context enforced next release.
|
|
2922
2942
|
* Use start:true to subscribe to when download as PDF is initiated, or end:true to
|
|
2923
2943
|
* subscribe to when download as PDF is completed. Default is end:true.
|
|
2924
2944
|
* @version SDK: 1.11.0 | ThoughtSpot: 8.3.0.cl, 8.4.1.sw
|
|
@@ -2935,6 +2955,9 @@ export declare enum EmbedEvent {
|
|
|
2935
2955
|
DownloadAsPdf = "downloadAsPdf",
|
|
2936
2956
|
/**
|
|
2937
2957
|
* Emitted when the Download as CSV action is triggered on an Answer.
|
|
2958
|
+
* Payload varies by context: {@link VizScopedRequest} (Search, Answer,
|
|
2959
|
+
* Liveboard), {@link RequiredVizRequest} (Spotter, vizId required). trigger()
|
|
2960
|
+
* accepts the union now; per-context enforced next release.
|
|
2938
2961
|
* Use start:true to subscribe to when download as CSV is initiated, or end:true to
|
|
2939
2962
|
* subscribe to when download as CSV is completed. Default is end:true.
|
|
2940
2963
|
* @version SDK: 1.11.0 | ThoughtSpot: 8.3.0.cl, 8.4.1.sw
|
|
@@ -2951,6 +2974,9 @@ export declare enum EmbedEvent {
|
|
|
2951
2974
|
DownloadAsCsv = "downloadAsCsv",
|
|
2952
2975
|
/**
|
|
2953
2976
|
* Emitted when the Download as XLSX action is triggered on an Answer.
|
|
2977
|
+
* Payload varies by context: {@link VizScopedRequest} (Search, Answer,
|
|
2978
|
+
* Liveboard), {@link RequiredVizRequest} (Spotter, vizId required). trigger()
|
|
2979
|
+
* accepts the union now; per-context enforced next release.
|
|
2954
2980
|
* Use start:true to subscribe to when download as XLSX is initiated, or end:true to
|
|
2955
2981
|
* subscribe to when download as XLSX is completed. Default is end:true.
|
|
2956
2982
|
* @version SDK: 1.11.0 | ThoughtSpot: 8.3.0.cl, 8.4.1.sw
|
|
@@ -3229,6 +3255,9 @@ export declare enum EmbedEvent {
|
|
|
3229
3255
|
Schedule = "subscription",
|
|
3230
3256
|
/**
|
|
3231
3257
|
* Emitted when a user clicks **Edit** on a Liveboard or visualization
|
|
3258
|
+
* Payload varies by context: {@link VizScopedRequest} (Liveboard),
|
|
3259
|
+
* {@link RequiredVizRequest} (Spotter, vizId required). trigger() accepts the
|
|
3260
|
+
* union now; per-context enforced next release.
|
|
3232
3261
|
* @version SDK: 1.15.0 | ThoughtSpot: 8.7.0.cl, 8.8.1.sw
|
|
3233
3262
|
* @example
|
|
3234
3263
|
* ```js
|
|
@@ -3770,7 +3799,32 @@ export declare enum EmbedEvent {
|
|
|
3770
3799
|
*/
|
|
3771
3800
|
OrgSwitched = "orgSwitched",
|
|
3772
3801
|
/**
|
|
3773
|
-
* Emitted
|
|
3802
|
+
* Emitted before the embedded ThoughtSpot app sends a network request whose
|
|
3803
|
+
* fully resolved URL matches one of the `interceptUrls` in the view config.
|
|
3804
|
+
* The request is held until you call `responder`, which decides whether the
|
|
3805
|
+
* real request goes out or a response you supply is used in its place.
|
|
3806
|
+
*
|
|
3807
|
+
* Setting `interceptUrls` is what enables this; there is no separate enable
|
|
3808
|
+
* flag. If `responder` is not called within `interceptTimeout` (30000 ms by
|
|
3809
|
+
* default) the request fails and `EmbedEvent.Error` is emitted.
|
|
3810
|
+
*
|
|
3811
|
+
* The payload is `{ input, init, urlType }`, where `input` is the request
|
|
3812
|
+
* URL and `init` is the `fetch` init object, with `init.body` parsed into an
|
|
3813
|
+
* object when it is valid JSON. `urlType` is the matching
|
|
3814
|
+
* `InterceptedApiType`; it is `InterceptedApiType.ALL` for any URL outside
|
|
3815
|
+
* the recognized API groups.
|
|
3816
|
+
*
|
|
3817
|
+
* Interception wraps the outermost layer of `fetch`, so `init` holds the
|
|
3818
|
+
* request as the application composed it, before ThoughtSpot attaches its
|
|
3819
|
+
* authentication headers. Those headers, and any token refresh and retry,
|
|
3820
|
+
* are applied afterwards and only when you pass `execute: true`. Only
|
|
3821
|
+
* requests made through `fetch` are intercepted.
|
|
3822
|
+
*
|
|
3823
|
+
* Pass `execute: true` to let the original request proceed untouched, in
|
|
3824
|
+
* which case any `response` you supply alongside it is ignored. With
|
|
3825
|
+
* `execute: false` the request is never sent, and your `response.body` is
|
|
3826
|
+
* returned to the app as JSON, defaulting to status 200 and a
|
|
3827
|
+
* `Content-Type: application/json` header.
|
|
3774
3828
|
*
|
|
3775
3829
|
* Supported on all embed types.
|
|
3776
3830
|
*
|
|
@@ -4282,6 +4336,7 @@ export declare enum HostEvent {
|
|
|
4282
4336
|
* the search query string.
|
|
4283
4337
|
* Supported in `AppEmbed` and `SearchEmbed` deployments.
|
|
4284
4338
|
* Includes the following properties:
|
|
4339
|
+
* Payload: {@link SearchRequest}.
|
|
4285
4340
|
* @param - Includes the following keys:
|
|
4286
4341
|
* - `searchQuery`: Query string with search tokens.
|
|
4287
4342
|
* - `dataSources`: Data source GUID to search on.
|
|
@@ -4309,6 +4364,9 @@ export declare enum HostEvent {
|
|
|
4309
4364
|
Search = "search",
|
|
4310
4365
|
/**
|
|
4311
4366
|
* Triggers a drill on certain points of the specified column
|
|
4367
|
+
* Payload: {@link DrillDownRequest}; in Liveboard context vizId is required
|
|
4368
|
+
* ({@link RequiredVizRequest}). trigger() accepts the union now; per-context
|
|
4369
|
+
* enforced next release.
|
|
4312
4370
|
* Includes the following properties:
|
|
4313
4371
|
* @param - Includes the following keys:
|
|
4314
4372
|
* - `points`: An object containing `selectedPoints` and/or `clickedPoint`
|
|
@@ -4388,6 +4446,8 @@ export declare enum HostEvent {
|
|
|
4388
4446
|
Reload = "reload",
|
|
4389
4447
|
/**
|
|
4390
4448
|
* Get iframe URL for the current embed view.
|
|
4449
|
+
* Payload: none.
|
|
4450
|
+
* Response: {@link GetIframeUrlResponse}.
|
|
4391
4451
|
* @example
|
|
4392
4452
|
* ```js
|
|
4393
4453
|
* const url = embed.trigger(HostEvent.GetIframeUrl);
|
|
@@ -4406,6 +4466,7 @@ export declare enum HostEvent {
|
|
|
4406
4466
|
GetIframeUrl = "GetIframeUrl",
|
|
4407
4467
|
/**
|
|
4408
4468
|
* Display specific visualizations on a Liveboard.
|
|
4469
|
+
* Payload: `string[]`.
|
|
4409
4470
|
* @param - An array of GUIDs of the visualization to show. The visualization IDs not passed
|
|
4410
4471
|
* in this parameter will be hidden.
|
|
4411
4472
|
* @example
|
|
@@ -4428,6 +4489,7 @@ export declare enum HostEvent {
|
|
|
4428
4489
|
SetVisibleVizs = "SetPinboardVisibleVizs",
|
|
4429
4490
|
/**
|
|
4430
4491
|
* Set a Liveboard tab as an active tab.
|
|
4492
|
+
* Payload: {@link SetActiveTabRequest}.
|
|
4431
4493
|
* @param - tabId - string of id of Tab to show
|
|
4432
4494
|
* @example
|
|
4433
4495
|
* ```js
|
|
@@ -4455,6 +4517,7 @@ export declare enum HostEvent {
|
|
|
4455
4517
|
* and `AppEmbed` only. In full application embedding, this event updates
|
|
4456
4518
|
* the runtime filters applied on the Liveboard and saved Answer objects.
|
|
4457
4519
|
*
|
|
4520
|
+
* Payload: {@link RuntimeFilter}[].
|
|
4458
4521
|
* @param - Array of {@link RuntimeFilter} objects. Each item includes:
|
|
4459
4522
|
* - `columnName`: Name of the column to filter on.
|
|
4460
4523
|
* - `operator`: {@link RuntimeFilterOp} to apply. For more information, see
|
|
@@ -4496,6 +4559,7 @@ export declare enum HostEvent {
|
|
|
4496
4559
|
* Accepts either a plain value or an object with `path`
|
|
4497
4560
|
* and an optional `replace` flag.
|
|
4498
4561
|
*
|
|
4562
|
+
* Payload: `string` | `number` | {@link NavigateRequest}.
|
|
4499
4563
|
* @param data - A string path, a numeric history delta, or an object
|
|
4500
4564
|
* `{ path: string | number, replace?: boolean }`.
|
|
4501
4565
|
* - `path` — the route to navigate to, or a history delta such as `1`
|
|
@@ -4523,6 +4587,9 @@ export declare enum HostEvent {
|
|
|
4523
4587
|
/**
|
|
4524
4588
|
* Open the filter panel for a particular column.
|
|
4525
4589
|
* Works with Search and Liveboard embed.
|
|
4590
|
+
* Payload: {@link OpenFilterRequest} (the cross-context superset). The
|
|
4591
|
+
* accepted fields vary by context: {@link OpenFilterLiveboardRequest},
|
|
4592
|
+
* {@link OpenFilterSpotterRequest}, {@link OpenFilterSearchRequest}.
|
|
4526
4593
|
* @param - { columnId: string,
|
|
4527
4594
|
* name: string,
|
|
4528
4595
|
* type: ATTRIBUTE/MEASURE,
|
|
@@ -4579,7 +4646,7 @@ export declare enum HostEvent {
|
|
|
4579
4646
|
*
|
|
4580
4647
|
* Unlike {@link HostEvent.OpenFilter}, which opens the panel of an
|
|
4581
4648
|
* existing filter, this event starts the creation of a new filter.
|
|
4582
|
-
* @version SDK: 1.
|
|
4649
|
+
* @version SDK: 1.51.1 | ThoughtSpot Cloud: 26.8.0.cl
|
|
4583
4650
|
* @example
|
|
4584
4651
|
* ```js
|
|
4585
4652
|
* liveboardEmbed.trigger(HostEvent.OpenAddFilterModal);
|
|
@@ -4595,7 +4662,7 @@ export declare enum HostEvent {
|
|
|
4595
4662
|
* Hiding the *Add parameter* button with `hiddenActions:
|
|
4596
4663
|
* [Action.AddParameter]` does not block this event, but disabling it
|
|
4597
4664
|
* with `disabledActions` does.
|
|
4598
|
-
* @version SDK: 1.
|
|
4665
|
+
* @version SDK: 1.51.1 | ThoughtSpot Cloud: 26.8.0.cl
|
|
4599
4666
|
* @example
|
|
4600
4667
|
* ```js
|
|
4601
4668
|
* liveboardEmbed.trigger(HostEvent.OpenAddParameterModal);
|
|
@@ -4605,6 +4672,7 @@ export declare enum HostEvent {
|
|
|
4605
4672
|
/**
|
|
4606
4673
|
* Open the parameter panel for a particular parameter on a Liveboard.
|
|
4607
4674
|
* Mirrors {@link HostEvent.OpenFilter} for parameters.
|
|
4675
|
+
* Payload: {@link OpenParameterRequest}.
|
|
4608
4676
|
* @param - Includes the following keys:
|
|
4609
4677
|
* - `parameter`: An object identifying the parameter to open, for
|
|
4610
4678
|
* example, `{ parameterId: '<parameter-GUID>' }`.
|
|
@@ -4636,6 +4704,7 @@ export declare enum HostEvent {
|
|
|
4636
4704
|
OpenParameter = "openParameter",
|
|
4637
4705
|
/**
|
|
4638
4706
|
* Add columns to the current search query.
|
|
4707
|
+
* Payload: `{ columnIds: string[] }`.
|
|
4639
4708
|
* @param - { columnIds: string[] }
|
|
4640
4709
|
* @example
|
|
4641
4710
|
* ```js
|
|
@@ -4654,6 +4723,7 @@ export declare enum HostEvent {
|
|
|
4654
4723
|
AddColumns = "addColumns",
|
|
4655
4724
|
/**
|
|
4656
4725
|
* Remove a column from the current search query.
|
|
4726
|
+
* Payload: `{ columnId: string }`.
|
|
4657
4727
|
* @param - { columnId: string }
|
|
4658
4728
|
* @example
|
|
4659
4729
|
* ```js
|
|
@@ -4678,6 +4748,8 @@ export declare enum HostEvent {
|
|
|
4678
4748
|
* sorting, toggling of legends, and data drill down.
|
|
4679
4749
|
* For more information, see
|
|
4680
4750
|
* link:https://developers.thoughtspot.com/docs/fetch-data-and-report-apis#transient-lb-content[Liveboard data with unsaved changes].
|
|
4751
|
+
* Payload: none.
|
|
4752
|
+
* Response: {@link GetExportRequestForCurrentPinboardResponse}.
|
|
4681
4753
|
* @example
|
|
4682
4754
|
* ```js
|
|
4683
4755
|
* liveboardEmbed.trigger(HostEvent.getExportRequestForCurrentPinboard).then(
|
|
@@ -4699,6 +4771,8 @@ export declare enum HostEvent {
|
|
|
4699
4771
|
* requiring additional user input via the *Pin to Liveboard* modal, define
|
|
4700
4772
|
* the following parameters:
|
|
4701
4773
|
*
|
|
4774
|
+
* Payload: {@link PinAnswerToLiveboardRequest}.
|
|
4775
|
+
* Response: {@link PinAnswerToLiveboardResponse}.
|
|
4702
4776
|
* @param - Includes the following keys:
|
|
4703
4777
|
* - `vizId`: GUID of the saved Answer or Spotter visualization ID to pin to a
|
|
4704
4778
|
* Liveboard.
|
|
@@ -4813,6 +4887,7 @@ export declare enum HostEvent {
|
|
|
4813
4887
|
LiveboardInfo = "pinboardInfo",
|
|
4814
4888
|
/**
|
|
4815
4889
|
* Trigger the **Schedule** action on an embedded Liveboard.
|
|
4890
|
+
* Payload: {@link VizScopedRequest}.
|
|
4816
4891
|
* @example
|
|
4817
4892
|
* ```js
|
|
4818
4893
|
* liveboardEmbed.trigger(HostEvent.Schedule)
|
|
@@ -4828,6 +4903,7 @@ export declare enum HostEvent {
|
|
|
4828
4903
|
Schedule = "subscription",
|
|
4829
4904
|
/**
|
|
4830
4905
|
* Trigger the **Manage schedule** action on an embedded Liveboard
|
|
4906
|
+
* Payload: {@link VizScopedRequest}.
|
|
4831
4907
|
* @example
|
|
4832
4908
|
* ```js
|
|
4833
4909
|
* liveboardEmbed.trigger(HostEvent.SchedulesList)
|
|
@@ -4844,6 +4920,7 @@ export declare enum HostEvent {
|
|
|
4844
4920
|
/**
|
|
4845
4921
|
* Trigger the **Export TML** action on an embedded Liveboard or
|
|
4846
4922
|
* Answer.
|
|
4923
|
+
* Payload: {@link VizScopedRequest}.
|
|
4847
4924
|
* @example
|
|
4848
4925
|
* ```js
|
|
4849
4926
|
* liveboardEmbed.trigger(HostEvent.ExportTML)
|
|
@@ -4866,6 +4943,7 @@ export declare enum HostEvent {
|
|
|
4866
4943
|
/**
|
|
4867
4944
|
* Trigger the **Edit TML** action on an embedded Liveboard or
|
|
4868
4945
|
* saved Answers in the full application embedding.
|
|
4946
|
+
* Payload: {@link VizScopedRequest}.
|
|
4869
4947
|
* @example
|
|
4870
4948
|
* ```js
|
|
4871
4949
|
* liveboardEmbed.trigger(HostEvent.EditTML)
|
|
@@ -4887,6 +4965,7 @@ export declare enum HostEvent {
|
|
|
4887
4965
|
EditTML = "editTSL",
|
|
4888
4966
|
/**
|
|
4889
4967
|
* Trigger the **Update TML** action on an embedded Liveboard.
|
|
4968
|
+
* Payload: {@link VizScopedRequest}.
|
|
4890
4969
|
* @example
|
|
4891
4970
|
* ```js
|
|
4892
4971
|
* liveboardEmbed.trigger(HostEvent.UpdateTML)
|
|
@@ -4904,6 +4983,7 @@ export declare enum HostEvent {
|
|
|
4904
4983
|
* Trigger the **Download PDF** action on an embedded Liveboard,
|
|
4905
4984
|
* visualization or Answer.
|
|
4906
4985
|
*
|
|
4986
|
+
* Payload: {@link VizScopedRequest} plus optional `liveboardId`.
|
|
4907
4987
|
* @param - `vizId` refers to the Answer ID in Spotter embed and is required in Spotter embed.
|
|
4908
4988
|
*
|
|
4909
4989
|
* **NOTE**: The **Download** > **PDF** action is available on
|
|
@@ -4954,6 +5034,7 @@ export declare enum HostEvent {
|
|
|
4954
5034
|
/**
|
|
4955
5035
|
* Trigger the **AI Highlights** action on an embedded Liveboard
|
|
4956
5036
|
*
|
|
5037
|
+
* Payload: none.
|
|
4957
5038
|
* @example
|
|
4958
5039
|
* ```js
|
|
4959
5040
|
* liveboardEmbed.trigger(HostEvent.AIHighlights)
|
|
@@ -5008,6 +5089,9 @@ export declare enum HostEvent {
|
|
|
5008
5089
|
MakeACopy = "makeACopy",
|
|
5009
5090
|
/**
|
|
5010
5091
|
* Trigger the **Delete** action for a Liveboard.
|
|
5092
|
+
* Payload varies by context: {@link RequiredVizRequest} (Liveboard, vizId
|
|
5093
|
+
* required), {@link VizScopedRequest} (Search). trigger() accepts the union
|
|
5094
|
+
* now; per-context enforced next release.
|
|
5011
5095
|
* @example
|
|
5012
5096
|
* ```js
|
|
5013
5097
|
* appEmbed.trigger(HostEvent.Remove)
|
|
@@ -5022,6 +5106,7 @@ export declare enum HostEvent {
|
|
|
5022
5106
|
Remove = "delete",
|
|
5023
5107
|
/**
|
|
5024
5108
|
* Trigger the **Explore** action on a visualization.
|
|
5109
|
+
* Payload: {@link RequiredVizRequest}.
|
|
5025
5110
|
* @param - an object with `vizId` as a key
|
|
5026
5111
|
* @example
|
|
5027
5112
|
* ```js
|
|
@@ -5041,6 +5126,7 @@ export declare enum HostEvent {
|
|
|
5041
5126
|
/**
|
|
5042
5127
|
* Trigger the **Create alert** action on a KPI chart
|
|
5043
5128
|
* in a Liveboard or saved Answer.
|
|
5129
|
+
* Payload: {@link VizScopedRequest}.
|
|
5044
5130
|
* @param - an object with `vizId` as a key
|
|
5045
5131
|
* @example
|
|
5046
5132
|
* ```js
|
|
@@ -5072,6 +5158,7 @@ export declare enum HostEvent {
|
|
|
5072
5158
|
/**
|
|
5073
5159
|
* Trigger the **Manage alerts** action on a KPI chart
|
|
5074
5160
|
* in a visualization or saved Answer.
|
|
5161
|
+
* Payload: {@link VizScopedRequest}.
|
|
5075
5162
|
* @param - an object with `vizId` as a key
|
|
5076
5163
|
* @example
|
|
5077
5164
|
* ```js
|
|
@@ -5109,6 +5196,7 @@ export declare enum HostEvent {
|
|
|
5109
5196
|
* on a Liveboard.
|
|
5110
5197
|
*
|
|
5111
5198
|
* This event is not supported in visualization embed and search embed.
|
|
5199
|
+
* Payload: {@link VizScopedRequest}.
|
|
5112
5200
|
* @param - Object parameter. Includes the following keys:
|
|
5113
5201
|
* - `vizId`: To trigger the action for a specific visualization in Liveboard embed,
|
|
5114
5202
|
* pass in `vizId` as a key. In Spotter embed, `vizId` refers to the Answer ID and
|
|
@@ -5151,6 +5239,7 @@ export declare enum HostEvent {
|
|
|
5151
5239
|
Edit = "edit",
|
|
5152
5240
|
/**
|
|
5153
5241
|
* Trigger the **Copy link** action on a Liveboard or visualization
|
|
5242
|
+
* Payload: {@link VizScopedRequest}.
|
|
5154
5243
|
* @param - object - to trigger the action for a
|
|
5155
5244
|
* specific visualization in Liveboard embed, pass in `vizId` as a key
|
|
5156
5245
|
* @example
|
|
@@ -5196,6 +5285,7 @@ export declare enum HostEvent {
|
|
|
5196
5285
|
CopyLink = "embedDocument",
|
|
5197
5286
|
/**
|
|
5198
5287
|
* Trigger the **Present** action on a Liveboard or visualization
|
|
5288
|
+
* Payload: {@link VizScopedRequest}.
|
|
5199
5289
|
* @param - object - to trigger the action for a specific visualization
|
|
5200
5290
|
* in Liveboard embed, pass in `vizId` as a key
|
|
5201
5291
|
* @example
|
|
@@ -5241,6 +5331,8 @@ export declare enum HostEvent {
|
|
|
5241
5331
|
Present = "present",
|
|
5242
5332
|
/**
|
|
5243
5333
|
* Get TML for the current search.
|
|
5334
|
+
* Payload: {@link GetTMLRequest}.
|
|
5335
|
+
* Response: `Record<string, any>`.
|
|
5244
5336
|
* @example
|
|
5245
5337
|
* ```js
|
|
5246
5338
|
* searchEmbed.trigger(HostEvent.GetTML).then((tml) => {
|
|
@@ -5290,6 +5382,7 @@ export declare enum HostEvent {
|
|
|
5290
5382
|
* Trigger the **Show underlying data** action on a
|
|
5291
5383
|
* chart or table.
|
|
5292
5384
|
*
|
|
5385
|
+
* Payload: {@link VizScopedRequest}.
|
|
5293
5386
|
* @param - an object with vizId as a key
|
|
5294
5387
|
* @example
|
|
5295
5388
|
* ```js
|
|
@@ -5323,6 +5416,7 @@ export declare enum HostEvent {
|
|
|
5323
5416
|
* Trigger the **Delete** action for a visualization
|
|
5324
5417
|
* in an embedded Liveboard, or a chart or table
|
|
5325
5418
|
* generated from Search.
|
|
5419
|
+
* Payload: {@link VizScopedRequest}.
|
|
5326
5420
|
* @param - Liveboard embed takes an object with `vizId` as a key.
|
|
5327
5421
|
* Can be left empty if embedding Search or visualization.
|
|
5328
5422
|
* @example
|
|
@@ -5351,6 +5445,7 @@ export declare enum HostEvent {
|
|
|
5351
5445
|
/**
|
|
5352
5446
|
* Trigger the **SpotIQ analyze** action on a
|
|
5353
5447
|
* chart or table.
|
|
5448
|
+
* Payload: {@link VizScopedRequest}.
|
|
5354
5449
|
* @param - Liveboard embed takes `vizId` as a
|
|
5355
5450
|
* key. Can be left undefined when embedding Search or
|
|
5356
5451
|
* visualization.
|
|
@@ -5413,6 +5508,7 @@ export declare enum HostEvent {
|
|
|
5413
5508
|
/**
|
|
5414
5509
|
* Trigger the **Download** > **PNG** action on
|
|
5415
5510
|
* charts in the embedded view.
|
|
5511
|
+
* Payload: {@link VizScopedRequest}.
|
|
5416
5512
|
* @example
|
|
5417
5513
|
* ```js
|
|
5418
5514
|
* liveboardEmbed.trigger(HostEvent.DownloadAsPng,
|
|
@@ -5443,6 +5539,7 @@ export declare enum HostEvent {
|
|
|
5443
5539
|
/**
|
|
5444
5540
|
* Trigger the **Download** > **CSV** action on tables in
|
|
5445
5541
|
* the embedded view.
|
|
5542
|
+
* Payload: {@link VizScopedRequest}.
|
|
5446
5543
|
* @param - `vizId` refers to the Visualization ID in Spotter embed and is required in Spotter embed.
|
|
5447
5544
|
* @example
|
|
5448
5545
|
* ```js
|
|
@@ -5482,6 +5579,7 @@ export declare enum HostEvent {
|
|
|
5482
5579
|
/**
|
|
5483
5580
|
* Trigger the **Download** > **XLSX** action on tables
|
|
5484
5581
|
* in the embedded view.
|
|
5582
|
+
* Payload: {@link VizScopedRequest}.
|
|
5485
5583
|
* @param - `vizId` refers to the Visualization ID in Spotter embed and is required in Spotter embed.
|
|
5486
5584
|
* @example
|
|
5487
5585
|
* ```js
|
|
@@ -5521,6 +5619,7 @@ export declare enum HostEvent {
|
|
|
5521
5619
|
/**
|
|
5522
5620
|
* Trigger the **Share** action on an embedded
|
|
5523
5621
|
* Liveboard or Answer.
|
|
5622
|
+
* Payload: {@link VizScopedRequest}.
|
|
5524
5623
|
* @example
|
|
5525
5624
|
* ```js
|
|
5526
5625
|
* liveboardEmbed.trigger(HostEvent.Share)
|
|
@@ -5547,6 +5646,7 @@ export declare enum HostEvent {
|
|
|
5547
5646
|
* Trigger the **Save** action on a Liveboard, Answer, or Spotter.
|
|
5548
5647
|
* Saves the changes.
|
|
5549
5648
|
*
|
|
5649
|
+
* Payload: {@link VizScopedRequest}.
|
|
5550
5650
|
* @param - `vizId` refers to the Spotter Visualization Id used in Spotter embed.
|
|
5551
5651
|
* It is required and can be retrieved from the data embed event.
|
|
5552
5652
|
*
|
|
@@ -5598,6 +5698,7 @@ export declare enum HostEvent {
|
|
|
5598
5698
|
/**
|
|
5599
5699
|
* Trigger the **Sync to Sheets** action on an embedded visualization or Answer
|
|
5600
5700
|
* Sends data from an Answer or Liveboard visualization to a Google sheet.
|
|
5701
|
+
* Payload: {@link VizScopedRequest}.
|
|
5601
5702
|
* @param - an object with `vizId` as a key
|
|
5602
5703
|
* @example
|
|
5603
5704
|
* ```js
|
|
@@ -5628,6 +5729,7 @@ export declare enum HostEvent {
|
|
|
5628
5729
|
* Trigger the **Sync to Other Apps** action on an embedded visualization or Answer
|
|
5629
5730
|
* Sends data from an Answer or Liveboard visualization to third-party apps such
|
|
5630
5731
|
* as Slack, Salesforce, Microsoft Teams, ServiceNow and so on.
|
|
5732
|
+
* Payload: {@link VizScopedRequest}.
|
|
5631
5733
|
* @param - an object with vizId as a key
|
|
5632
5734
|
* @example
|
|
5633
5735
|
* ```js
|
|
@@ -5658,6 +5760,7 @@ export declare enum HostEvent {
|
|
|
5658
5760
|
* Trigger the **Manage pipelines** action on an embedded
|
|
5659
5761
|
* visualization or Answer.
|
|
5660
5762
|
* Allows users to manage ThoughtSpot Sync pipelines.
|
|
5763
|
+
* Payload: {@link VizScopedRequest}.
|
|
5661
5764
|
* @param - an object with `vizId` as a key
|
|
5662
5765
|
* @example
|
|
5663
5766
|
* ```js
|
|
@@ -5686,6 +5789,7 @@ export declare enum HostEvent {
|
|
|
5686
5789
|
ManagePipelines = "manage-pipeline",
|
|
5687
5790
|
/**
|
|
5688
5791
|
* Reset search operation on the Search or Answer page.
|
|
5792
|
+
* Payload: none.
|
|
5689
5793
|
* @example
|
|
5690
5794
|
* ```js
|
|
5691
5795
|
* searchEmbed.trigger(HostEvent.ResetSearch)
|
|
@@ -5713,6 +5817,8 @@ export declare enum HostEvent {
|
|
|
5713
5817
|
* whole Liveboard.
|
|
5714
5818
|
* The `applicability` attribute is available from SDK: 1.53.0 |
|
|
5715
5819
|
* ThoughtSpot: 26.10.0.cl.
|
|
5820
|
+
* Payload: {@link GetFiltersRequest}.
|
|
5821
|
+
* Response: {@link GetFiltersResponse}.
|
|
5716
5822
|
* @example
|
|
5717
5823
|
* ```js
|
|
5718
5824
|
* const data = await liveboardEmbed.trigger(HostEvent.GetFilters);
|
|
@@ -5732,6 +5838,7 @@ export declare enum HostEvent {
|
|
|
5732
5838
|
GetFilters = "getFilters",
|
|
5733
5839
|
/**
|
|
5734
5840
|
* Update one or several filters applied on a Liveboard.
|
|
5841
|
+
* Payload: {@link UpdateFiltersRequest}.
|
|
5735
5842
|
* @param - Includes the following keys:
|
|
5736
5843
|
* - `filter`: A single filter object containing column name, filter operator, and
|
|
5737
5844
|
* values.
|
|
@@ -5860,6 +5967,8 @@ export declare enum HostEvent {
|
|
|
5860
5967
|
UpdateFilters = "updateFilters",
|
|
5861
5968
|
/**
|
|
5862
5969
|
* Get tab details for the current Liveboard.
|
|
5970
|
+
* Payload: none.
|
|
5971
|
+
* Response: {@link GetTabsResponse}.
|
|
5863
5972
|
* @example
|
|
5864
5973
|
* ```js
|
|
5865
5974
|
* liveboardEmbed.trigger(HostEvent.GetTabs).then((tabDetails) => {
|
|
@@ -5885,6 +5994,8 @@ export declare enum HostEvent {
|
|
|
5885
5994
|
/**
|
|
5886
5995
|
* Get group details for the current Liveboard.
|
|
5887
5996
|
* Mirrors {@link HostEvent.GetTabs} for filter/parameter groups.
|
|
5997
|
+
* Payload: none.
|
|
5998
|
+
* Response: {@link GetGroupsResponse}.
|
|
5888
5999
|
* @example
|
|
5889
6000
|
* ```js
|
|
5890
6001
|
* liveboardEmbed.trigger(HostEvent.GetGroups).then((groupDetails) => {
|
|
@@ -5909,6 +6020,7 @@ export declare enum HostEvent {
|
|
|
5909
6020
|
GetGroups = "getGroups",
|
|
5910
6021
|
/**
|
|
5911
6022
|
* Set the visible tabs on a Liveboard.
|
|
6023
|
+
* Payload: `string[]`.
|
|
5912
6024
|
* @param - an array of ids of tabs to show, the IDs not passed
|
|
5913
6025
|
* will be hidden.
|
|
5914
6026
|
* @example
|
|
@@ -5931,6 +6043,7 @@ export declare enum HostEvent {
|
|
|
5931
6043
|
SetVisibleTabs = "SetPinboardVisibleTabs",
|
|
5932
6044
|
/**
|
|
5933
6045
|
* Set the hidden tabs on a Liveboard.
|
|
6046
|
+
* Payload: `string[]`.
|
|
5934
6047
|
* @param - an array of the IDs of the tabs to hide.
|
|
5935
6048
|
* The IDs not passed will be shown.
|
|
5936
6049
|
* @example
|
|
@@ -5959,6 +6072,8 @@ export declare enum HostEvent {
|
|
|
5959
6072
|
* `getAnswerService()` method on the embed instance to get an AnswerService
|
|
5960
6073
|
* object that provides a more convenient interface for working with answers.
|
|
5961
6074
|
*
|
|
6075
|
+
* Payload: {@link GetAnswerSessionRequest}.
|
|
6076
|
+
* Response: {@link GetAnswerSessionResponse}.
|
|
5962
6077
|
* @example
|
|
5963
6078
|
* ```js
|
|
5964
6079
|
* // Preferred way to get an AnswerService
|
|
@@ -5986,6 +6101,7 @@ export declare enum HostEvent {
|
|
|
5986
6101
|
GetAnswerSession = "getAnswerSession",
|
|
5987
6102
|
/**
|
|
5988
6103
|
* Trigger the *Ask Sage* action for visualizations
|
|
6104
|
+
* Payload: {@link RequiredVizRequest}.
|
|
5989
6105
|
* @example
|
|
5990
6106
|
* ```js
|
|
5991
6107
|
* liveboardEmbed.trigger(HostEvent.AskSage,
|
|
@@ -5997,6 +6113,7 @@ export declare enum HostEvent {
|
|
|
5997
6113
|
/**
|
|
5998
6114
|
* Trigger cross filter update action on a Liveboard.
|
|
5999
6115
|
*
|
|
6116
|
+
* Payload: {@link UpdateCrossFilterRequest}.
|
|
6000
6117
|
* @example
|
|
6001
6118
|
* ```js
|
|
6002
6119
|
* liveboardEmbed.trigger(HostEvent.UpdateCrossFilter, {
|
|
@@ -6012,7 +6129,9 @@ export declare enum HostEvent {
|
|
|
6012
6129
|
UpdateCrossFilter = "UpdateCrossFilter",
|
|
6013
6130
|
/**
|
|
6014
6131
|
* Trigger reset action for a personalized Liveboard view.
|
|
6015
|
-
* This event is deprecated.
|
|
6132
|
+
* This event is deprecated.
|
|
6133
|
+
* Use {@link HostEvent.ResetLiveboardPersonalizedView} instead.
|
|
6134
|
+
* Payload: none.
|
|
6016
6135
|
* @example
|
|
6017
6136
|
* ```js
|
|
6018
6137
|
* liveboardEmbed.trigger(HostEvent.ResetLiveboardPersonalisedView);
|
|
@@ -6033,6 +6152,7 @@ export declare enum HostEvent {
|
|
|
6033
6152
|
/**
|
|
6034
6153
|
* Triggers an action to update Parameter values on embedded
|
|
6035
6154
|
* Answers, Liveboard, and Spotter answer in Edit mode.
|
|
6155
|
+
* Payload: {@link RuntimeParameter}[].
|
|
6036
6156
|
* @param - Includes the following keys for each item:
|
|
6037
6157
|
* - `name`: Name of the parameter.
|
|
6038
6158
|
* - `value`: The value to set for the parameter.
|
|
@@ -6090,6 +6210,8 @@ export declare enum HostEvent {
|
|
|
6090
6210
|
* whole Liveboard.
|
|
6091
6211
|
* The `applicability` attribute is available from SDK: 1.53.0 |
|
|
6092
6212
|
* ThoughtSpot: 26.10.0.cl.
|
|
6213
|
+
* Payload: none.
|
|
6214
|
+
* Response: {@link GetParametersResponse}.
|
|
6093
6215
|
* @param - `vizId` refers to the Answer ID in Spotter embed and is required in Spotter embed.
|
|
6094
6216
|
* ```js
|
|
6095
6217
|
* liveboardEmbed.trigger(HostEvent.GetParameters).then((parameter) => {
|
|
@@ -6127,6 +6249,7 @@ export declare enum HostEvent {
|
|
|
6127
6249
|
* ```js
|
|
6128
6250
|
* liveboardEmbed.trigger(HostEvent.UpdatePersonalisedView, {viewId: '1234'})
|
|
6129
6251
|
* ```
|
|
6252
|
+
* Payload: {@link PersonalisedViewRequest} (`viewId` only).
|
|
6130
6253
|
* @example
|
|
6131
6254
|
* ```js
|
|
6132
6255
|
* // Update personalized view from liveboard context
|
|
@@ -6159,6 +6282,7 @@ export declare enum HostEvent {
|
|
|
6159
6282
|
* If neither is provided, the Liveboard resets to the original/default view.
|
|
6160
6283
|
* When a `viewName` is provided and multiple views share
|
|
6161
6284
|
* the same name, the first match is selected.
|
|
6285
|
+
* Payload: {@link PersonalisedViewRequest}.
|
|
6162
6286
|
* @example
|
|
6163
6287
|
* ```js
|
|
6164
6288
|
* liveboardEmbed.trigger(
|
|
@@ -6202,6 +6326,8 @@ export declare enum HostEvent {
|
|
|
6202
6326
|
* If no parameters are specified, the save action is
|
|
6203
6327
|
* triggered with a modal to prompt users to
|
|
6204
6328
|
* add a name and description for the Answer.
|
|
6329
|
+
* Payload: {@link SaveAnswerRequest}.
|
|
6330
|
+
* Response: {@link SaveAnswerResponse}.
|
|
6205
6331
|
* @param - Includes the following keys:
|
|
6206
6332
|
* - `vizId`: Refers to the Answer ID in Spotter embed and is **required** in Spotter
|
|
6207
6333
|
* embed.
|
|
@@ -6287,6 +6413,7 @@ export declare enum HostEvent {
|
|
|
6287
6413
|
/**
|
|
6288
6414
|
* Triggers a search operation with the search tokens specified in
|
|
6289
6415
|
* the search query string in spotter embed.
|
|
6416
|
+
* Payload: {@link SpotterSearchRequest}.
|
|
6290
6417
|
* @param - Includes the following keys:
|
|
6291
6418
|
* - `query`: Text string in Natural Language format.
|
|
6292
6419
|
* - `executeSearch`: Boolean to execute search and update search query.
|
|
@@ -6311,6 +6438,7 @@ export declare enum HostEvent {
|
|
|
6311
6438
|
SpotterSearch = "SpotterSearch",
|
|
6312
6439
|
/**
|
|
6313
6440
|
* Edits the last prompt in spotter embed.
|
|
6441
|
+
* Payload: `string`.
|
|
6314
6442
|
* @param - `query`: Text string
|
|
6315
6443
|
* @example
|
|
6316
6444
|
* ```js
|
|
@@ -6327,6 +6455,7 @@ export declare enum HostEvent {
|
|
|
6327
6455
|
EditLastPrompt = "EditLastPrompt",
|
|
6328
6456
|
/**
|
|
6329
6457
|
* Opens the data source preview modal in Spotter Embed.
|
|
6458
|
+
* Payload: none.
|
|
6330
6459
|
* @example
|
|
6331
6460
|
* ```js
|
|
6332
6461
|
* spotterEmbed.trigger(HostEvent.PreviewSpotterData);
|
|
@@ -6362,6 +6491,7 @@ export declare enum HostEvent {
|
|
|
6362
6491
|
DataModelInstructions = "DataModelInstructions",
|
|
6363
6492
|
/**
|
|
6364
6493
|
* Resets the Spotter Embed Conversation.
|
|
6494
|
+
* Payload: none.
|
|
6365
6495
|
* @example
|
|
6366
6496
|
* ```js
|
|
6367
6497
|
* spotterEmbed.trigger(HostEvent.ResetSpotterConversation);
|
|
@@ -6374,6 +6504,7 @@ export declare enum HostEvent {
|
|
|
6374
6504
|
* `conversationId` is **mandatory** — you must pass the id of the
|
|
6375
6505
|
* conversation to share. Also no-op when sharing is disabled
|
|
6376
6506
|
* (enableShareConversation off) or when already in the read-only shared view.
|
|
6507
|
+
* Payload: {@link ConversationScopedRequest}.
|
|
6377
6508
|
* @example
|
|
6378
6509
|
* ```js
|
|
6379
6510
|
* spotterEmbed.trigger(HostEvent.ShareSpotterConversation, { conversationId: 'abc' });
|
|
@@ -6383,6 +6514,7 @@ export declare enum HostEvent {
|
|
|
6383
6514
|
ShareSpotterConversation = "ShareSpotterConversation",
|
|
6384
6515
|
/**
|
|
6385
6516
|
* Closes the Spotter share-conversation modal. No-op if none is open.
|
|
6517
|
+
* Payload: none.
|
|
6386
6518
|
* @example
|
|
6387
6519
|
* ```js
|
|
6388
6520
|
* spotterEmbed.trigger(HostEvent.CloseSpotterShareConversation);
|
|
@@ -6392,6 +6524,7 @@ export declare enum HostEvent {
|
|
|
6392
6524
|
CloseSpotterShareConversation = "CloseSpotterShareConversation",
|
|
6393
6525
|
/**
|
|
6394
6526
|
* Exits the read-only shared-conversation view.
|
|
6527
|
+
* Payload: none.
|
|
6395
6528
|
* @example
|
|
6396
6529
|
* ```js
|
|
6397
6530
|
* spotterEmbed.trigger(HostEvent.ExitSpotterSharedConversation);
|
|
@@ -6401,6 +6534,7 @@ export declare enum HostEvent {
|
|
|
6401
6534
|
ExitSpotterSharedConversation = "ExitSpotterSharedConversation",
|
|
6402
6535
|
/**
|
|
6403
6536
|
* Deletes the last prompt in spotter embed.
|
|
6537
|
+
* Payload: none.
|
|
6404
6538
|
* @example
|
|
6405
6539
|
* ```js
|
|
6406
6540
|
* spotterEmbed.trigger(HostEvent.DeleteLastPrompt);
|
|
@@ -6410,6 +6544,7 @@ export declare enum HostEvent {
|
|
|
6410
6544
|
DeleteLastPrompt = "DeleteLastPrompt",
|
|
6411
6545
|
/**
|
|
6412
6546
|
* Toggle the visualization to chart or table view.
|
|
6547
|
+
* Payload: {@link RequiredVizRequest}.
|
|
6413
6548
|
* @param - `vizId ` refers to the Visualization ID in Spotter embed and is required.
|
|
6414
6549
|
* @example
|
|
6415
6550
|
* ```js
|
|
@@ -6448,6 +6583,7 @@ export declare enum HostEvent {
|
|
|
6448
6583
|
VisibleEmbedCoordinates = "visibleEmbedCoordinates",
|
|
6449
6584
|
/**
|
|
6450
6585
|
* Trigger the *Spotter* action for visualizations present on the liveboard's vizzes.
|
|
6586
|
+
* Payload: {@link RequiredVizRequest}.
|
|
6451
6587
|
* @param - `vizId` refers to the Visualization ID in Spotter embed and is required.
|
|
6452
6588
|
* @example
|
|
6453
6589
|
* ```js
|
|
@@ -6472,7 +6608,13 @@ export declare enum HostEvent {
|
|
|
6472
6608
|
*/
|
|
6473
6609
|
UpdateEmbedParams = "updateEmbedParams",
|
|
6474
6610
|
/**
|
|
6475
|
-
*
|
|
6611
|
+
* Notifies the embedded ThoughtSpot app that the embed is being torn down, so that
|
|
6612
|
+
* it can release any resources it holds before the iframe is removed from the DOM.
|
|
6613
|
+
*
|
|
6614
|
+
* This is triggered for you by `embed.destroy()`; you rarely need to trigger it
|
|
6615
|
+
* directly. If `waitForCleanupOnDestroy` is set in the embed config, `destroy()`
|
|
6616
|
+
* waits for the app to acknowledge this event (up to `cleanupTimeout`) before
|
|
6617
|
+
* removing the iframe.
|
|
6476
6618
|
* @example
|
|
6477
6619
|
* ```js
|
|
6478
6620
|
* liveboardEmbed.trigger(HostEvent.DestroyEmbed);
|
|
@@ -6503,6 +6645,7 @@ export declare enum HostEvent {
|
|
|
6503
6645
|
* instance. Contact your admin or ThoughtSpot Support to enable chat history on your
|
|
6504
6646
|
* instance.
|
|
6505
6647
|
*
|
|
6648
|
+
* Payload: {@link ConversationScopedRequest}.
|
|
6506
6649
|
* @version SDK: 1.53.0 | ThoughtSpot Cloud: 26.10.0.cl
|
|
6507
6650
|
* @example
|
|
6508
6651
|
* ```js
|
|
@@ -6520,6 +6663,7 @@ export declare enum HostEvent {
|
|
|
6520
6663
|
* instance. Contact your admin or ThoughtSpot Support to enable chat history on your
|
|
6521
6664
|
* instance.
|
|
6522
6665
|
*
|
|
6666
|
+
* Payload: {@link ConversationScopedRequest}.
|
|
6523
6667
|
* @version SDK: 1.53.0 | ThoughtSpot Cloud: 26.10.0.cl
|
|
6524
6668
|
* @example
|
|
6525
6669
|
* ```js
|
|
@@ -6544,6 +6688,7 @@ export declare enum HostEvent {
|
|
|
6544
6688
|
* Trigger the **Send Test Email** action in the Liveboard schedule modal.
|
|
6545
6689
|
* Sends a test schedule email to self or all recipients.
|
|
6546
6690
|
* Requires `isSendNowLiveboardSchedulingEnabled` to be enabled.
|
|
6691
|
+
* Payload: {@link ScheduleEmailRequest}.
|
|
6547
6692
|
* @example
|
|
6548
6693
|
* ```js
|
|
6549
6694
|
* liveboardEmbed.trigger(HostEvent.SendTestScheduleEmail, {
|
|
@@ -6562,6 +6707,7 @@ export declare enum HostEvent {
|
|
|
6562
6707
|
SendTestScheduleEmail = "sendTestScheduleEmail",
|
|
6563
6708
|
/**
|
|
6564
6709
|
* Sends a user message (prompt) to the SpotterViz panel programmatically.
|
|
6710
|
+
* Payload: `{ query: string }`.
|
|
6565
6711
|
* @version SDK: 1.50.0 | ThoughtSpot Cloud: 26.7.0.cl
|
|
6566
6712
|
* @param query - the prompt text to send.
|
|
6567
6713
|
* @example
|
|
@@ -6574,6 +6720,7 @@ export declare enum HostEvent {
|
|
|
6574
6720
|
SpotterVizSendUserMessage = "SpotterVizSendUserMessage",
|
|
6575
6721
|
/**
|
|
6576
6722
|
* Initializes a new SpotterViz conversation.
|
|
6723
|
+
* Payload: none.
|
|
6577
6724
|
* @version SDK: 1.50.0 | ThoughtSpot Cloud: 26.7.0.cl
|
|
6578
6725
|
* @example
|
|
6579
6726
|
* ```js
|
|
@@ -6583,6 +6730,7 @@ export declare enum HostEvent {
|
|
|
6583
6730
|
InitSpotterVizConversation = "InitSpotterVizConversation",
|
|
6584
6731
|
/**
|
|
6585
6732
|
* Opens the SpotterViz panel.
|
|
6733
|
+
* Payload: none.
|
|
6586
6734
|
* @version SDK: 1.50.0 | ThoughtSpot Cloud: 26.7.0.cl
|
|
6587
6735
|
* @example
|
|
6588
6736
|
* ```js
|
|
@@ -6592,6 +6740,7 @@ export declare enum HostEvent {
|
|
|
6592
6740
|
OpenSpotterVizPanel = "OpenSpotterVizPanel",
|
|
6593
6741
|
/**
|
|
6594
6742
|
* Closes the SpotterViz panel.
|
|
6743
|
+
* Payload: none.
|
|
6595
6744
|
* @version SDK: 1.50.0 | ThoughtSpot Cloud: 26.7.0.cl
|
|
6596
6745
|
* @example
|
|
6597
6746
|
* ```js
|
|
@@ -6602,6 +6751,7 @@ export declare enum HostEvent {
|
|
|
6602
6751
|
/**
|
|
6603
6752
|
* Clears browser cache and fetches new data for liveboard ChartViz Containers.
|
|
6604
6753
|
* Requires `enableLiveboardDataCache` to be enabled.
|
|
6754
|
+
* Payload: {@link ScheduleEmailRequest}.
|
|
6605
6755
|
* @example
|
|
6606
6756
|
* ```js
|
|
6607
6757
|
* liveboardEmbed.trigger(HostEvent.RefreshLiveboardBrowserCache);
|
|
@@ -6790,7 +6940,8 @@ export declare enum Param {
|
|
|
6790
6940
|
UpdatedSpotterExperience = "updatedSpotterExperience",
|
|
6791
6941
|
SpotterDataSources = "spotterDataSources",
|
|
6792
6942
|
AnalystId = "analystId",
|
|
6793
|
-
OpenSpotterOnLiveboardByDefault = "openSpotterOnLiveboardByDefault"
|
|
6943
|
+
OpenSpotterOnLiveboardByDefault = "openSpotterOnLiveboardByDefault",
|
|
6944
|
+
ShowAnswerEditPanel = "showAnswerEditPanel"
|
|
6794
6945
|
}
|
|
6795
6946
|
/**
|
|
6796
6947
|
* Configuration for allowed file types in Spotter file upload.
|
|
@@ -8586,7 +8737,7 @@ export declare enum Action {
|
|
|
8586
8737
|
* ```js
|
|
8587
8738
|
* hiddenActions: [Action.QuickSearchPill]
|
|
8588
8739
|
* ```
|
|
8589
|
-
* @version SDK: 1.
|
|
8740
|
+
* @version SDK: 1.53.0 | ThoughtSpot Cloud: 26.10.0.cl
|
|
8590
8741
|
*/
|
|
8591
8742
|
QuickSearchPill = "quickSearchPill",
|
|
8592
8743
|
/**
|
|
@@ -8601,7 +8752,7 @@ export declare enum Action {
|
|
|
8601
8752
|
* ```js
|
|
8602
8753
|
* hiddenActions: [Action.DeepAnalysisPill]
|
|
8603
8754
|
* ```
|
|
8604
|
-
* @version SDK: 1.
|
|
8755
|
+
* @version SDK: 1.53.0 | ThoughtSpot Cloud: 26.10.0.cl
|
|
8605
8756
|
*/
|
|
8606
8757
|
DeepAnalysisPill = "deepAnalysisPill",
|
|
8607
8758
|
/**
|
|
@@ -8616,7 +8767,7 @@ export declare enum Action {
|
|
|
8616
8767
|
* ```js
|
|
8617
8768
|
* hiddenActions: [Action.DataLiteracyPill]
|
|
8618
8769
|
* ```
|
|
8619
|
-
* @version SDK: 1.
|
|
8770
|
+
* @version SDK: 1.53.0 | ThoughtSpot Cloud: 26.10.0.cl
|
|
8620
8771
|
*/
|
|
8621
8772
|
DataLiteracyPill = "dataLiteracyPill",
|
|
8622
8773
|
/**
|
|
@@ -8798,7 +8949,226 @@ export declare enum Action {
|
|
|
8798
8949
|
* disabledActions: [Action.SpotterOnLiveboard]
|
|
8799
8950
|
* ```
|
|
8800
8951
|
*/
|
|
8801
|
-
SpotterOnLiveboard = "spotterOnLiveboard"
|
|
8952
|
+
SpotterOnLiveboard = "spotterOnLiveboard",
|
|
8953
|
+
/**
|
|
8954
|
+
* Controls the visibility and disabled state of the "Chart Type" menu item
|
|
8955
|
+
* in Chart Settings V2.
|
|
8956
|
+
* @version SDK: 1.54.0 | ThoughtSpot Cloud: 26.11.0.cl
|
|
8957
|
+
* @example
|
|
8958
|
+
* ```js
|
|
8959
|
+
* {
|
|
8960
|
+
* hiddenActions: [Action.ChartTypeSettings],
|
|
8961
|
+
* disabledActions: [Action.ChartTypeSettings],
|
|
8962
|
+
* }
|
|
8963
|
+
* ```
|
|
8964
|
+
*/
|
|
8965
|
+
ChartTypeSettings = "CHART_TYPE",
|
|
8966
|
+
/**
|
|
8967
|
+
* Controls the visibility and disabled state of the "Layout" menu item
|
|
8968
|
+
* in Chart Settings V2.
|
|
8969
|
+
* @version SDK: 1.54.0 | ThoughtSpot Cloud: 26.11.0.cl
|
|
8970
|
+
* @example
|
|
8971
|
+
* ```js
|
|
8972
|
+
* {
|
|
8973
|
+
* hiddenActions: [Action.LayoutSettings],
|
|
8974
|
+
* disabledActions: [Action.LayoutSettings],
|
|
8975
|
+
* }
|
|
8976
|
+
* ```
|
|
8977
|
+
*/
|
|
8978
|
+
LayoutSettings = "LAYOUT",
|
|
8979
|
+
/**
|
|
8980
|
+
* Controls the visibility and disabled state of the "Column" menu item
|
|
8981
|
+
* in Chart Settings V2.
|
|
8982
|
+
* @version SDK: 1.54.0 | ThoughtSpot Cloud: 26.11.0.cl
|
|
8983
|
+
* @example
|
|
8984
|
+
* ```js
|
|
8985
|
+
* {
|
|
8986
|
+
* hiddenActions: [Action.ColumnSettings],
|
|
8987
|
+
* disabledActions: [Action.ColumnSettings],
|
|
8988
|
+
* }
|
|
8989
|
+
* ```
|
|
8990
|
+
*/
|
|
8991
|
+
ColumnSettings = "COLUMN",
|
|
8992
|
+
/**
|
|
8993
|
+
* Controls the visibility and disabled state of the "Axis" menu item
|
|
8994
|
+
* in Chart Settings V2.
|
|
8995
|
+
* @version SDK: 1.54.0 | ThoughtSpot Cloud: 26.11.0.cl
|
|
8996
|
+
* @example
|
|
8997
|
+
* ```js
|
|
8998
|
+
* {
|
|
8999
|
+
* hiddenActions: [Action.AxisSettings],
|
|
9000
|
+
* disabledActions: [Action.AxisSettings],
|
|
9001
|
+
* }
|
|
9002
|
+
* ```
|
|
9003
|
+
*/
|
|
9004
|
+
AxisSettings = "AXIS",
|
|
9005
|
+
/**
|
|
9006
|
+
* Controls the visibility and disabled state of the "Data Label" menu item
|
|
9007
|
+
* in Chart Settings V2.
|
|
9008
|
+
* @version SDK: 1.54.0 | ThoughtSpot Cloud: 26.11.0.cl
|
|
9009
|
+
* @example
|
|
9010
|
+
* ```js
|
|
9011
|
+
* {
|
|
9012
|
+
* hiddenActions: [Action.DataLabelSettings],
|
|
9013
|
+
* disabledActions: [Action.DataLabelSettings],
|
|
9014
|
+
* }
|
|
9015
|
+
* ```
|
|
9016
|
+
*/
|
|
9017
|
+
DataLabelSettings = "DATA_LABEL",
|
|
9018
|
+
/**
|
|
9019
|
+
* Controls the visibility and disabled state of the "Tooltip" menu item
|
|
9020
|
+
* in Chart Settings V2.
|
|
9021
|
+
* @version SDK: 1.54.0 | ThoughtSpot Cloud: 26.11.0.cl
|
|
9022
|
+
* @example
|
|
9023
|
+
* ```js
|
|
9024
|
+
* {
|
|
9025
|
+
* hiddenActions: [Action.TooltipSettings],
|
|
9026
|
+
* disabledActions: [Action.TooltipSettings],
|
|
9027
|
+
* }
|
|
9028
|
+
* ```
|
|
9029
|
+
*/
|
|
9030
|
+
TooltipSettings = "TOOLTIP",
|
|
9031
|
+
/**
|
|
9032
|
+
* Controls the visibility and disabled state of the "Legend" menu item
|
|
9033
|
+
* in Chart Settings V2.
|
|
9034
|
+
* @version SDK: 1.54.0 | ThoughtSpot Cloud: 26.11.0.cl
|
|
9035
|
+
* @example
|
|
9036
|
+
* ```js
|
|
9037
|
+
* {
|
|
9038
|
+
* hiddenActions: [Action.LegendSettings],
|
|
9039
|
+
* disabledActions: [Action.LegendSettings],
|
|
9040
|
+
* }
|
|
9041
|
+
* ```
|
|
9042
|
+
*/
|
|
9043
|
+
LegendSettings = "LEGEND",
|
|
9044
|
+
/**
|
|
9045
|
+
* Controls the visibility and disabled state of the "Display" menu item
|
|
9046
|
+
* in Chart Settings V2.
|
|
9047
|
+
* @version SDK: 1.54.0 | ThoughtSpot Cloud: 26.11.0.cl
|
|
9048
|
+
* @example
|
|
9049
|
+
* ```js
|
|
9050
|
+
* {
|
|
9051
|
+
* hiddenActions: [Action.DisplaySettings],
|
|
9052
|
+
* disabledActions: [Action.DisplaySettings],
|
|
9053
|
+
* }
|
|
9054
|
+
* ```
|
|
9055
|
+
*/
|
|
9056
|
+
DisplaySettings = "DISPLAY",
|
|
9057
|
+
/**
|
|
9058
|
+
* Controls the visibility and disabled state of the "Query Details" menu
|
|
9059
|
+
* item in Chart Settings V2.
|
|
9060
|
+
* @version SDK: 1.54.0 | ThoughtSpot Cloud: 26.11.0.cl
|
|
9061
|
+
* @example
|
|
9062
|
+
* ```js
|
|
9063
|
+
* {
|
|
9064
|
+
* hiddenActions: [Action.QuerySettings],
|
|
9065
|
+
* disabledActions: [Action.QuerySettings],
|
|
9066
|
+
* }
|
|
9067
|
+
* ```
|
|
9068
|
+
*/
|
|
9069
|
+
QuerySettings = "QUERY_DETAILS",
|
|
9070
|
+
/**
|
|
9071
|
+
* Controls the visibility and disabled state of the "Custom Action" menu
|
|
9072
|
+
* item in Chart Settings V2.
|
|
9073
|
+
* @version SDK: 1.54.0 | ThoughtSpot Cloud: 26.11.0.cl
|
|
9074
|
+
* @example
|
|
9075
|
+
* ```js
|
|
9076
|
+
* {
|
|
9077
|
+
* hiddenActions: [Action.CustomSettings],
|
|
9078
|
+
* disabledActions: [Action.CustomSettings],
|
|
9079
|
+
* }
|
|
9080
|
+
* ```
|
|
9081
|
+
*/
|
|
9082
|
+
CustomSettings = "CUSTOM_ACTION",
|
|
9083
|
+
/**
|
|
9084
|
+
* Controls the visibility and disabled state of the "Muze AI" menu item
|
|
9085
|
+
* in Chart Settings V2.
|
|
9086
|
+
* @version SDK: 1.54.0 | ThoughtSpot Cloud: 26.11.0.cl
|
|
9087
|
+
* @example
|
|
9088
|
+
* ```js
|
|
9089
|
+
* {
|
|
9090
|
+
* hiddenActions: [Action.MuzeAiSettings],
|
|
9091
|
+
* disabledActions: [Action.MuzeAiSettings],
|
|
9092
|
+
* }
|
|
9093
|
+
* ```
|
|
9094
|
+
*/
|
|
9095
|
+
MuzeAiSettings = "MUZE_AI",
|
|
9096
|
+
/**
|
|
9097
|
+
* Controls the visibility and disabled state of the "R Analysis" menu item
|
|
9098
|
+
* in Chart Settings V2.
|
|
9099
|
+
* @version SDK: 1.54.0 | ThoughtSpot Cloud: 26.11.0.cl
|
|
9100
|
+
* @example
|
|
9101
|
+
* ```js
|
|
9102
|
+
* {
|
|
9103
|
+
* hiddenActions: [Action.RAnalysisSettings],
|
|
9104
|
+
* disabledActions: [Action.RAnalysisSettings],
|
|
9105
|
+
* }
|
|
9106
|
+
* ```
|
|
9107
|
+
*/
|
|
9108
|
+
RAnalysisSettings = "R_ANALYSIS",
|
|
9109
|
+
/**
|
|
9110
|
+
* Controls the visibility and disabled state of the "Add to Collection" menu item.
|
|
9111
|
+
* @version SDK: 1.52.1 | ThoughtSpot Cloud: 26.5.0.cl
|
|
9112
|
+
* @example
|
|
9113
|
+
* ```js
|
|
9114
|
+
* {
|
|
9115
|
+
* hiddenActions: [Action.AddToCollection],
|
|
9116
|
+
* disabledActions: [Action.AddToCollection],
|
|
9117
|
+
* }
|
|
9118
|
+
* ```
|
|
9119
|
+
*/
|
|
9120
|
+
AddToCollection = "addToCollection",
|
|
9121
|
+
/**
|
|
9122
|
+
* Controls the visibility and disabled state of the "Create Collection" button.
|
|
9123
|
+
* @version SDK: 1.52.1 | ThoughtSpot Cloud: 26.5.0.cl
|
|
9124
|
+
* @example
|
|
9125
|
+
* ```js
|
|
9126
|
+
* {
|
|
9127
|
+
* hiddenActions: [Action.CreateCollection],
|
|
9128
|
+
* disabledActions: [Action.CreateCollection],
|
|
9129
|
+
* }
|
|
9130
|
+
* ```
|
|
9131
|
+
*/
|
|
9132
|
+
CreateCollection = "createCollection",
|
|
9133
|
+
/**
|
|
9134
|
+
* Controls the visibility and disabled state of the "Move" menu item in a
|
|
9135
|
+
* Collection.
|
|
9136
|
+
* @version SDK: 1.52.1 | ThoughtSpot Cloud: 26.5.0.cl
|
|
9137
|
+
* @example
|
|
9138
|
+
* ```js
|
|
9139
|
+
* {
|
|
9140
|
+
* hiddenActions: [Action.MoveToCollection],
|
|
9141
|
+
* disabledActions: [Action.MoveToCollection],
|
|
9142
|
+
* }
|
|
9143
|
+
* ```
|
|
9144
|
+
*/
|
|
9145
|
+
MoveToCollection = "moveToCollection",
|
|
9146
|
+
/**
|
|
9147
|
+
* Controls the visibility and disabled state of the "Remove" menu item in a
|
|
9148
|
+
* Collection.
|
|
9149
|
+
* @version SDK: 1.52.1 | ThoughtSpot Cloud: 26.5.0.cl
|
|
9150
|
+
* @example
|
|
9151
|
+
* ```js
|
|
9152
|
+
* {
|
|
9153
|
+
* hiddenActions: [Action.RemoveFromCollection],
|
|
9154
|
+
* disabledActions: [Action.RemoveFromCollection],
|
|
9155
|
+
* }
|
|
9156
|
+
* ```
|
|
9157
|
+
*/
|
|
9158
|
+
RemoveFromCollection = "removeFromCollection",
|
|
9159
|
+
/**
|
|
9160
|
+
* Controls the visibility and disabled state of the "Delete" menu item for a
|
|
9161
|
+
* Collection.
|
|
9162
|
+
* @version SDK: 1.52.1 | ThoughtSpot Cloud: 26.5.0.cl
|
|
9163
|
+
* @example
|
|
9164
|
+
* ```js
|
|
9165
|
+
* {
|
|
9166
|
+
* hiddenActions: [Action.DeleteCollection],
|
|
9167
|
+
* disabledActions: [Action.DeleteCollection],
|
|
9168
|
+
* }
|
|
9169
|
+
* ```
|
|
9170
|
+
*/
|
|
9171
|
+
DeleteCollection = "deleteCollection"
|
|
8802
9172
|
}
|
|
8803
9173
|
export interface AnswerServiceType {
|
|
8804
9174
|
getAnswer?: (offset: number, batchSize: number) => any;
|
|
@@ -8840,6 +9210,11 @@ export interface VizPoint {
|
|
|
8840
9210
|
* @group Events
|
|
8841
9211
|
*/
|
|
8842
9212
|
export interface CustomActionPayload {
|
|
9213
|
+
/**
|
|
9214
|
+
* Id of the custom action that was triggered. Matches the `id` you set on
|
|
9215
|
+
* the {@link CustomAction}. Omitted on Liveboard-level code-based actions.
|
|
9216
|
+
*/
|
|
9217
|
+
id?: string;
|
|
8843
9218
|
contextMenuPoints?: {
|
|
8844
9219
|
clickedPoint: VizPoint;
|
|
8845
9220
|
selectedPoints: VizPoint[];
|
|
@@ -8859,21 +9234,58 @@ export interface CustomActionPayload {
|
|
|
8859
9234
|
session: SessionInterface;
|
|
8860
9235
|
vizId?: string;
|
|
8861
9236
|
}
|
|
9237
|
+
/**
|
|
9238
|
+
* A code-based custom action to inject into the embedded ThoughtSpot UI.
|
|
9239
|
+
* Pass an array of these as `customActions` in the embed view config. When a
|
|
9240
|
+
* user invokes the action, the host emits {@link EmbedEvent.CustomAction} with
|
|
9241
|
+
* a {@link CustomActionPayload} carrying the same `id`.
|
|
9242
|
+
*/
|
|
8862
9243
|
export interface CustomAction {
|
|
9244
|
+
/**
|
|
9245
|
+
* Display label shown on the action's button or menu item.
|
|
9246
|
+
*/
|
|
8863
9247
|
name: string;
|
|
9248
|
+
/**
|
|
9249
|
+
* Unique identifier for the action. Echoed back as `id` on the
|
|
9250
|
+
* {@link CustomActionPayload} when the action is invoked.
|
|
9251
|
+
*/
|
|
8864
9252
|
id: string;
|
|
9253
|
+
/**
|
|
9254
|
+
* Where the action appears: a primary button, the "More" menu, or the
|
|
9255
|
+
* right-click context menu. See {@link CustomActionsPosition}.
|
|
9256
|
+
*/
|
|
8865
9257
|
position: CustomActionsPosition;
|
|
9258
|
+
/**
|
|
9259
|
+
* The surface the action applies to (Liveboard, visualization, Answer, or
|
|
9260
|
+
* Spotter). See {@link CustomActionTarget}. The allowed `position` values
|
|
9261
|
+
* and scoping keys depend on the target.
|
|
9262
|
+
*/
|
|
8866
9263
|
target: CustomActionTarget;
|
|
9264
|
+
/**
|
|
9265
|
+
* Scope the action to specific objects by GUID. Which keys are allowed
|
|
9266
|
+
* depends on `target` (for example, a `VIZ` action may use `answerIds`,
|
|
9267
|
+
* `liveboardIds`, and `vizIds`).
|
|
9268
|
+
*/
|
|
8867
9269
|
metadataIds?: {
|
|
8868
9270
|
answerIds?: string[];
|
|
8869
9271
|
liveboardIds?: string[];
|
|
8870
9272
|
vizIds?: string[];
|
|
8871
9273
|
};
|
|
9274
|
+
/**
|
|
9275
|
+
* Scope the action by data model, using model GUIDs or column names.
|
|
9276
|
+
* Allowed for `VIZ`, `ANSWER`, and `SPOTTER` targets.
|
|
9277
|
+
*/
|
|
8872
9278
|
dataModelIds?: {
|
|
8873
9279
|
modelIds?: string[];
|
|
8874
9280
|
modelColumnNames?: string[];
|
|
8875
9281
|
};
|
|
9282
|
+
/**
|
|
9283
|
+
* Restrict the action to specific organizations by ID.
|
|
9284
|
+
*/
|
|
8876
9285
|
orgIds?: string[];
|
|
9286
|
+
/**
|
|
9287
|
+
* Restrict the action to specific user groups by ID.
|
|
9288
|
+
*/
|
|
8877
9289
|
groupIds?: string[];
|
|
8878
9290
|
}
|
|
8879
9291
|
/**
|
|
@@ -9200,9 +9612,40 @@ export interface EmbedErrorDetailsEvent {
|
|
|
9200
9612
|
message: string | string[];
|
|
9201
9613
|
/** Machine-readable error code for programmatic error handling */
|
|
9202
9614
|
code: EmbedErrorCodes;
|
|
9615
|
+
/** How badly the embed is affected. Defaults to {@link EmbedErrorSeverity.SEV3}. */
|
|
9616
|
+
severity?: EmbedErrorSeverity;
|
|
9203
9617
|
/** Additional context-specific for backward compatibility */
|
|
9204
9618
|
[key: string]: any;
|
|
9205
9619
|
}
|
|
9620
|
+
/**
|
|
9621
|
+
* How badly an error affects the embed, so the host can decide whether it is
|
|
9622
|
+
* worth surfacing to the end user.
|
|
9623
|
+
*
|
|
9624
|
+
* Mirrors the severity that ThoughtSpot itself stamps on errors raised inside
|
|
9625
|
+
* the embedded app, so a host can apply one rule to both sources.
|
|
9626
|
+
*
|
|
9627
|
+
* @version SDK: 1.52.0 | ThoughtSpot Cloud: 26.9.0.cl
|
|
9628
|
+
* @group Error Handling
|
|
9629
|
+
*
|
|
9630
|
+
* @example
|
|
9631
|
+
* Only surface errors that took the embed down
|
|
9632
|
+
*
|
|
9633
|
+
* ```js
|
|
9634
|
+
* embed.on(EmbedEvent.Error, (error) => {
|
|
9635
|
+
* if (error.severity === EmbedErrorSeverity.SEV1) {
|
|
9636
|
+
* showBanner(error.message);
|
|
9637
|
+
* }
|
|
9638
|
+
* });
|
|
9639
|
+
* ```
|
|
9640
|
+
*/
|
|
9641
|
+
export declare enum EmbedErrorSeverity {
|
|
9642
|
+
/** The embed cannot render. Nothing usable is on screen. */
|
|
9643
|
+
SEV1 = 1,
|
|
9644
|
+
/** Something is degraded but the embed still works. */
|
|
9645
|
+
SEV2 = 2,
|
|
9646
|
+
/** Everything else, including validation of the embedder's own input. */
|
|
9647
|
+
SEV3 = 3
|
|
9648
|
+
}
|
|
9206
9649
|
/**
|
|
9207
9650
|
* Context types for specifying the page context when triggering host events.
|
|
9208
9651
|
* Used as the third parameter in the `trigger` method to help ThoughtSpot
|
|
@@ -9260,25 +9703,40 @@ export interface DefaultAppInitData {
|
|
|
9260
9703
|
useHostEventsV2?: boolean;
|
|
9261
9704
|
}
|
|
9262
9705
|
/**
|
|
9263
|
-
*
|
|
9706
|
+
* Named groups of ThoughtSpot APIs that can be intercepted, for use in
|
|
9707
|
+
* `interceptUrls`. Each group expands to the underlying request URLs, so you do
|
|
9708
|
+
* not have to list them individually.
|
|
9264
9709
|
*/
|
|
9265
9710
|
export declare enum InterceptedApiType {
|
|
9266
9711
|
/**
|
|
9267
|
-
* The
|
|
9712
|
+
* The APIs that fetch the data backing an Answer, including its chart,
|
|
9713
|
+
* table, and headline data.
|
|
9268
9714
|
*/
|
|
9269
9715
|
AnswerData = "AnswerData",
|
|
9270
9716
|
/**
|
|
9271
|
-
*
|
|
9717
|
+
* Intercepts every `fetch` request the embedded application makes, not only
|
|
9718
|
+
* the data APIs. This includes authentication, session, and metadata calls,
|
|
9719
|
+
* so the handler must respond to requests it does not recognize by passing
|
|
9720
|
+
* `execute: true`. Listing this alongside other entries in `interceptUrls`
|
|
9721
|
+
* supersedes them.
|
|
9272
9722
|
*/
|
|
9273
9723
|
ALL = "ALL",
|
|
9274
9724
|
/**
|
|
9275
|
-
* The
|
|
9725
|
+
* The APIs that fetch the data backing a Liveboard.
|
|
9276
9726
|
*/
|
|
9277
9727
|
LiveboardData = "LiveboardData"
|
|
9278
9728
|
}
|
|
9279
9729
|
export type ApiInterceptFlags = {
|
|
9280
9730
|
/**
|
|
9281
|
-
*
|
|
9731
|
+
* Emits `EmbedEvent.OnBeforeGetVizDataIntercept` before the Answer data
|
|
9732
|
+
* APIs are called. This is the earlier, narrower form of interception, kept
|
|
9733
|
+
* for backward compatibility and implemented on top of
|
|
9734
|
+
* `EmbedEvent.ApiIntercept`. Prefer `interceptUrls` with
|
|
9735
|
+
* `InterceptedApiType.AnswerData` in new code.
|
|
9736
|
+
*
|
|
9737
|
+
* Setting this also intercepts the Answer data APIs, so both
|
|
9738
|
+
* `EmbedEvent.OnBeforeGetVizDataIntercept` and `EmbedEvent.ApiIntercept`
|
|
9739
|
+
* are emitted for those requests.
|
|
9282
9740
|
*
|
|
9283
9741
|
* Can be used for Search and App Embed from SDK 1.29.0
|
|
9284
9742
|
*
|
|
@@ -9286,14 +9744,21 @@ export type ApiInterceptFlags = {
|
|
|
9286
9744
|
*/
|
|
9287
9745
|
isOnBeforeGetVizDataInterceptEnabled?: boolean;
|
|
9288
9746
|
/**
|
|
9289
|
-
*
|
|
9290
|
-
*
|
|
9747
|
+
* The requests to intercept, given as `InterceptedApiType` groups, absolute
|
|
9748
|
+
* URLs, or paths beginning with `/` that are resolved against the
|
|
9749
|
+
* ThoughtSpot host. Setting this is what turns interception on.
|
|
9750
|
+
*
|
|
9751
|
+
* A URL matches only on exact equality with the request's fully resolved
|
|
9752
|
+
* URL, query string included, so prefer an `InterceptedApiType` group where
|
|
9753
|
+
* one covers the API you need.
|
|
9754
|
+
*
|
|
9755
|
+
* Each intercepted request pauses and emits `EmbedEvent.ApiIntercept`, then
|
|
9756
|
+
* proceeds according to the response passed to that event's responder.
|
|
9291
9757
|
*
|
|
9292
9758
|
* @example
|
|
9293
9759
|
* ```js
|
|
9294
9760
|
* const embed = new LiveboardEmbed('#embed', {
|
|
9295
9761
|
* ...viewConfig,
|
|
9296
|
-
* enableApiIntercept: true,
|
|
9297
9762
|
* interceptUrls: [InterceptedApiType.LiveboardData],
|
|
9298
9763
|
* })
|
|
9299
9764
|
* ```
|
|
@@ -9302,14 +9767,14 @@ export type ApiInterceptFlags = {
|
|
|
9302
9767
|
*/
|
|
9303
9768
|
interceptUrls?: (string | InterceptedApiType)[];
|
|
9304
9769
|
/**
|
|
9305
|
-
*
|
|
9306
|
-
*
|
|
9770
|
+
* How long, in milliseconds, an intercepted request waits for the
|
|
9771
|
+
* `EmbedEvent.ApiIntercept` responder before it is abandoned. Defaults to
|
|
9772
|
+
* 30000. On timeout the request fails and `EmbedEvent.Error` is emitted.
|
|
9307
9773
|
*
|
|
9308
9774
|
* @example
|
|
9309
9775
|
* ```js
|
|
9310
9776
|
* const embed = new LiveboardEmbed('#embed', {
|
|
9311
9777
|
* ...viewConfig,
|
|
9312
|
-
* enableApiIntercept: true,
|
|
9313
9778
|
* interceptUrls: [InterceptedApiType.ALL],
|
|
9314
9779
|
* interceptTimeout: 1000,
|
|
9315
9780
|
* })
|
|
@@ -9782,4 +10247,164 @@ export interface VisualizationOverrides {
|
|
|
9782
10247
|
/** Table visualization overrides */
|
|
9783
10248
|
table?: TableOverrides;
|
|
9784
10249
|
}
|
|
10250
|
+
/**
|
|
10251
|
+
* The configuration object for the full-height behavior shared by the
|
|
10252
|
+
* Liveboard and app embeds.
|
|
10253
|
+
*
|
|
10254
|
+
* When `fullHeight` is enabled the SDK resizes the embed container to match the
|
|
10255
|
+
* height reported by the ThoughtSpot app, and — when lazy loading is also
|
|
10256
|
+
* enabled — keeps the app informed of the portion of the embed that is
|
|
10257
|
+
* currently visible so that visualizations load on demand.
|
|
10258
|
+
*/
|
|
10259
|
+
export interface FullHeightViewConfig {
|
|
10260
|
+
/**
|
|
10261
|
+
* If set to true, the embedded object container dynamically resizes
|
|
10262
|
+
* according to the height of the Liveboard.
|
|
10263
|
+
*
|
|
10264
|
+
* **Note**: Using fullHeight loads all visualizations on the
|
|
10265
|
+
* Liveboard simultaneously, which results in multiple warehouse
|
|
10266
|
+
* queries and potentially a longer wait for the topmost
|
|
10267
|
+
* visualizations to display on the screen.
|
|
10268
|
+
* Setting `fullHeight` to `false` fetches visualizations
|
|
10269
|
+
* incrementally as users scroll the page to view the charts and tables.
|
|
10270
|
+
*
|
|
10271
|
+
* From SDK 1.52.0, enabling `fullHeight` also turns on
|
|
10272
|
+
* {@link lazyLoadingForFullHeight} and
|
|
10273
|
+
* {@link enableScrollableContainerLazyLoading}, so visualizations load as
|
|
10274
|
+
* they scroll into view. Set either flag to `false` to opt out.
|
|
10275
|
+
*
|
|
10276
|
+
* Supported embed types: `LiveboardEmbed`, `AppEmbed`
|
|
10277
|
+
* @version SDK: 1.1.0 | ThoughtSpot: ts7.may.cl, 7.2.1
|
|
10278
|
+
* @example
|
|
10279
|
+
* ```js
|
|
10280
|
+
* // Replace <EmbedComponent> with the embed component name.
|
|
10281
|
+
* // For example, AppEmbed or LiveboardEmbed
|
|
10282
|
+
* const embed = new <EmbedComponent>('#embed', {
|
|
10283
|
+
* ... // other view config
|
|
10284
|
+
* fullHeight: true,
|
|
10285
|
+
* });
|
|
10286
|
+
* ```
|
|
10287
|
+
*/
|
|
10288
|
+
fullHeight?: boolean;
|
|
10289
|
+
/**
|
|
10290
|
+
* This is the minimum height (in pixels) for a full-height Liveboard.
|
|
10291
|
+
* Setting this height helps resolve issues with empty Liveboards and
|
|
10292
|
+
* other screens navigable from a Liveboard.
|
|
10293
|
+
*
|
|
10294
|
+
* Supported embed types: `LiveboardEmbed`, `AppEmbed`
|
|
10295
|
+
* @version SDK: 1.44.2 | ThoughtSpot: 10.15.0.cl
|
|
10296
|
+
* @default 500
|
|
10297
|
+
* @example
|
|
10298
|
+
* ```js
|
|
10299
|
+
* // Replace <EmbedComponent> with the embed component name.
|
|
10300
|
+
* // For example, AppEmbed or LiveboardEmbed
|
|
10301
|
+
* const embed = new <EmbedComponent>('#embed', {
|
|
10302
|
+
* ... // other view config
|
|
10303
|
+
* fullHeight: true,
|
|
10304
|
+
* minimumHeight: 600,
|
|
10305
|
+
* });
|
|
10306
|
+
* ```
|
|
10307
|
+
*/
|
|
10308
|
+
minimumHeight?: number;
|
|
10309
|
+
/**
|
|
10310
|
+
* This is the minimum height (in pixels) for a full-height Liveboard.
|
|
10311
|
+
* Setting this height helps resolve issues with empty Liveboards and
|
|
10312
|
+
* other screens navigable from a Liveboard.
|
|
10313
|
+
*
|
|
10314
|
+
* Supported embed types: `LiveboardEmbed`, `AppEmbed`
|
|
10315
|
+
* @version SDK: 1.5.0 | ThoughtSpot: ts7.oct.cl, 7.2.1
|
|
10316
|
+
* @deprecated Use `minimumHeight` instead.
|
|
10317
|
+
* @default 500
|
|
10318
|
+
* @example
|
|
10319
|
+
* ```js
|
|
10320
|
+
* // Replace <EmbedComponent> with the embed component name.
|
|
10321
|
+
* // For example, AppEmbed or LiveboardEmbed
|
|
10322
|
+
* const embed = new <EmbedComponent>('#embed', {
|
|
10323
|
+
* ... // other view config
|
|
10324
|
+
* fullHeight: true,
|
|
10325
|
+
* defaultHeight: 600,
|
|
10326
|
+
* });
|
|
10327
|
+
* ```
|
|
10328
|
+
*/
|
|
10329
|
+
defaultHeight?: number;
|
|
10330
|
+
/**
|
|
10331
|
+
* Loads visualizations only as they scroll into the viewport, instead of
|
|
10332
|
+
* loading the whole full-height Liveboard at once.
|
|
10333
|
+
*
|
|
10334
|
+
* From SDK 1.52.0 this is enabled automatically whenever `fullHeight` is
|
|
10335
|
+
* `true`. On SDK 1.51.0 and earlier it defaulted to `false` and had to be
|
|
10336
|
+
* set explicitly. Set it to `false` to load every visualization upfront.
|
|
10337
|
+
* The flag has no effect unless `fullHeight` is enabled.
|
|
10338
|
+
*
|
|
10339
|
+
* Supported embed types: `LiveboardEmbed`, `AppEmbed`
|
|
10340
|
+
* @type {boolean}
|
|
10341
|
+
* @version SDK: 1.40.0 | ThoughtSpot: 10.12.0.cl
|
|
10342
|
+
* @default true when `fullHeight` is enabled, from SDK 1.52.0
|
|
10343
|
+
* @example
|
|
10344
|
+
* ```js
|
|
10345
|
+
* // Replace <EmbedComponent> with the embed component name.
|
|
10346
|
+
* // For example, AppEmbed or LiveboardEmbed
|
|
10347
|
+
* const embed = new <EmbedComponent>('#embed-container', {
|
|
10348
|
+
* // ...other options
|
|
10349
|
+
* fullHeight: true,
|
|
10350
|
+
* lazyLoadingForFullHeight: true,
|
|
10351
|
+
* })
|
|
10352
|
+
* ```
|
|
10353
|
+
*/
|
|
10354
|
+
lazyLoadingForFullHeight?: boolean;
|
|
10355
|
+
/**
|
|
10356
|
+
* How far outside the viewport a visualization starts loading, when
|
|
10357
|
+
* {@link lazyLoadingForFullHeight} is enabled.
|
|
10358
|
+
*
|
|
10359
|
+
* For example, if the margin is set to '10px',
|
|
10360
|
+
* the visualization will be loaded 10px before its top edge is visible in the
|
|
10361
|
+
* viewport.
|
|
10362
|
+
*
|
|
10363
|
+
* The format is similar to CSS margin, so `'500px 0px'` extends the
|
|
10364
|
+
* prefetch 500px above and below the viewport and not sideways. Accepted
|
|
10365
|
+
* units are `px`, `em`, `rem`, `%`, `vh` and `vw`, plus bare `0` and
|
|
10366
|
+
* `auto`; an invalid value is logged and ignored.
|
|
10367
|
+
*
|
|
10368
|
+
* From SDK 1.52.0 this defaults to `'500px 0px'` — roughly one
|
|
10369
|
+
* visualization ahead of the scroll position, so a chart has usually
|
|
10370
|
+
* finished loading by the time it scrolls into view. Use a smaller margin
|
|
10371
|
+
* to cut warehouse queries further, or `'0px'` to load a visualization
|
|
10372
|
+
* only once it is actually visible.
|
|
10373
|
+
*
|
|
10374
|
+
* Supported embed types: `LiveboardEmbed`, `AppEmbed`
|
|
10375
|
+
* @type {string}
|
|
10376
|
+
* @version SDK: 1.40.0 | ThoughtSpot: 10.12.0.cl
|
|
10377
|
+
* @default '500px 0px' when `fullHeight` is enabled, from SDK 1.52.0
|
|
10378
|
+
* @example
|
|
10379
|
+
* ```js
|
|
10380
|
+
* // Replace <EmbedComponent> with the embed component name.
|
|
10381
|
+
* // For example, AppEmbed or LiveboardEmbed
|
|
10382
|
+
* const embed = new <EmbedComponent>('#embed-container', {
|
|
10383
|
+
* // ...other options
|
|
10384
|
+
* fullHeight: true,
|
|
10385
|
+
* lazyLoadingForFullHeight: true,
|
|
10386
|
+
* // With 0px, the visualization only starts loading once it is
|
|
10387
|
+
* // visible in the viewport.
|
|
10388
|
+
* lazyLoadingMargin: '0px',
|
|
10389
|
+
* })
|
|
10390
|
+
* ```
|
|
10391
|
+
*/
|
|
10392
|
+
lazyLoadingMargin?: string;
|
|
10393
|
+
/**
|
|
10394
|
+
* Computes the visible region of the embed against its scrollable and
|
|
10395
|
+
* clipping ancestors, instead of treating the browser window as the only
|
|
10396
|
+
* viewport, and tracks scroll and resize on those ancestors.
|
|
10397
|
+
*
|
|
10398
|
+
* From SDK 1.52.0 this is enabled automatically whenever `fullHeight` is
|
|
10399
|
+
* `true`. On SDK 1.51.0 and earlier it defaulted to `false` and had to be
|
|
10400
|
+
* set explicitly. Set it to `false` when the page scrolls with the window
|
|
10401
|
+
* and the embed has no clipping ancestor, to skip the extra ancestor
|
|
10402
|
+
* tracking.
|
|
10403
|
+
*
|
|
10404
|
+
* Supported embed types: `LiveboardEmbed`, `AppEmbed`
|
|
10405
|
+
* @type {boolean}
|
|
10406
|
+
* @default true when `fullHeight` is enabled, from SDK 1.52.0
|
|
10407
|
+
*/
|
|
10408
|
+
enableScrollableContainerLazyLoading?: boolean;
|
|
10409
|
+
}
|
|
9785
10410
|
//# sourceMappingURL=types.d.ts.map
|