@thoughtspot/visual-embed-sdk 1.26.2 → 1.27.0-alpha.0
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/README.md +1 -1
- package/cjs/package.json +1 -1
- package/cjs/src/auth.d.ts +4 -4
- package/cjs/src/auth.d.ts.map +1 -1
- package/cjs/src/auth.js +10 -4
- package/cjs/src/auth.js.map +1 -1
- package/cjs/src/embed/app.d.ts +15 -15
- package/cjs/src/embed/app.d.ts.map +1 -1
- package/cjs/src/embed/app.js +1 -1
- package/cjs/src/embed/app.js.map +1 -1
- package/cjs/src/embed/liveboard.d.ts +28 -23
- package/cjs/src/embed/liveboard.d.ts.map +1 -1
- package/cjs/src/embed/liveboard.js +4 -3
- package/cjs/src/embed/liveboard.js.map +1 -1
- package/cjs/src/embed/sage.d.ts +48 -30
- package/cjs/src/embed/sage.d.ts.map +1 -1
- package/cjs/src/embed/sage.js +1 -1
- package/cjs/src/embed/sage.js.map +1 -1
- package/cjs/src/embed/search-bar.d.ts +22 -6
- package/cjs/src/embed/search-bar.d.ts.map +1 -1
- package/cjs/src/embed/search-bar.js.map +1 -1
- package/cjs/src/embed/search.d.ts +34 -19
- package/cjs/src/embed/search.d.ts.map +1 -1
- package/cjs/src/embed/search.js +7 -3
- package/cjs/src/embed/search.js.map +1 -1
- package/cjs/src/embed/search.spec.js +10 -0
- package/cjs/src/embed/search.spec.js.map +1 -1
- package/cjs/src/embed/ts-embed.d.ts +1 -0
- package/cjs/src/embed/ts-embed.d.ts.map +1 -1
- package/cjs/src/embed/ts-embed.js +27 -7
- package/cjs/src/embed/ts-embed.js.map +1 -1
- package/cjs/src/embed/ts-embed.spec.js +114 -0
- package/cjs/src/embed/ts-embed.spec.js.map +1 -1
- package/cjs/src/react/index.spec.js +0 -12
- package/cjs/src/react/index.spec.js.map +1 -1
- package/cjs/src/types.d.ts +727 -242
- package/cjs/src/types.d.ts.map +1 -1
- package/cjs/src/types.js +653 -175
- package/cjs/src/types.js.map +1 -1
- package/cjs/src/utils/graphql/answerService/answerService.d.ts +2 -4
- package/cjs/src/utils/graphql/answerService/answerService.d.ts.map +1 -1
- package/cjs/src/utils/graphql/answerService/answerService.js +2 -4
- package/cjs/src/utils/graphql/answerService/answerService.js.map +1 -1
- package/cjs/src/utils/processData.d.ts +6 -0
- package/cjs/src/utils/processData.d.ts.map +1 -1
- package/cjs/src/utils/processData.js +5 -1
- package/cjs/src/utils/processData.js.map +1 -1
- package/cjs/src/utils/processTrigger.js +1 -1
- package/dist/src/auth.d.ts +4 -4
- package/dist/src/auth.d.ts.map +1 -1
- package/dist/src/embed/app.d.ts +15 -15
- package/dist/src/embed/app.d.ts.map +1 -1
- package/dist/src/embed/liveboard.d.ts +28 -23
- package/dist/src/embed/liveboard.d.ts.map +1 -1
- package/dist/src/embed/sage.d.ts +48 -30
- package/dist/src/embed/sage.d.ts.map +1 -1
- package/dist/src/embed/search-bar.d.ts +22 -6
- package/dist/src/embed/search-bar.d.ts.map +1 -1
- package/dist/src/embed/search.d.ts +34 -19
- package/dist/src/embed/search.d.ts.map +1 -1
- package/dist/src/embed/ts-embed.d.ts +1 -0
- package/dist/src/embed/ts-embed.d.ts.map +1 -1
- package/dist/src/types.d.ts +727 -242
- package/dist/src/types.d.ts.map +1 -1
- package/dist/src/utils/graphql/answerService/answerService.d.ts +2 -4
- package/dist/src/utils/graphql/answerService/answerService.d.ts.map +1 -1
- package/dist/src/utils/processData.d.ts +6 -0
- package/dist/src/utils/processData.d.ts.map +1 -1
- package/dist/tsembed-react.es.js +706 -200
- package/dist/tsembed-react.js +705 -199
- package/dist/tsembed.es.js +709 -200
- package/dist/tsembed.js +707 -198
- package/dist/visual-embed-sdk-react-full.d.ts +898 -339
- package/dist/visual-embed-sdk-react.d.ts +898 -339
- package/dist/visual-embed-sdk.d.ts +898 -339
- package/lib/package.json +1 -1
- package/lib/src/auth.d.ts +4 -4
- package/lib/src/auth.d.ts.map +1 -1
- package/lib/src/auth.js +10 -4
- package/lib/src/auth.js.map +1 -1
- package/lib/src/embed/app.d.ts +15 -15
- package/lib/src/embed/app.d.ts.map +1 -1
- package/lib/src/embed/app.js +1 -1
- package/lib/src/embed/app.js.map +1 -1
- package/lib/src/embed/liveboard.d.ts +28 -23
- package/lib/src/embed/liveboard.d.ts.map +1 -1
- package/lib/src/embed/liveboard.js +4 -3
- package/lib/src/embed/liveboard.js.map +1 -1
- package/lib/src/embed/sage.d.ts +48 -30
- package/lib/src/embed/sage.d.ts.map +1 -1
- package/lib/src/embed/sage.js +1 -1
- package/lib/src/embed/sage.js.map +1 -1
- package/lib/src/embed/search-bar.d.ts +22 -6
- package/lib/src/embed/search-bar.d.ts.map +1 -1
- package/lib/src/embed/search-bar.js.map +1 -1
- package/lib/src/embed/search.d.ts +34 -19
- package/lib/src/embed/search.d.ts.map +1 -1
- package/lib/src/embed/search.js +7 -3
- package/lib/src/embed/search.js.map +1 -1
- package/lib/src/embed/search.spec.js +10 -0
- package/lib/src/embed/search.spec.js.map +1 -1
- package/lib/src/embed/ts-embed.d.ts +1 -0
- package/lib/src/embed/ts-embed.d.ts.map +1 -1
- package/lib/src/embed/ts-embed.js +28 -8
- package/lib/src/embed/ts-embed.js.map +1 -1
- package/lib/src/embed/ts-embed.spec.js +114 -0
- package/lib/src/embed/ts-embed.spec.js.map +1 -1
- package/lib/src/react/index.spec.js +0 -12
- package/lib/src/react/index.spec.js.map +1 -1
- package/lib/src/types.d.ts +727 -242
- package/lib/src/types.d.ts.map +1 -1
- package/lib/src/types.js +653 -175
- package/lib/src/types.js.map +1 -1
- package/lib/src/utils/graphql/answerService/answerService.d.ts +2 -4
- package/lib/src/utils/graphql/answerService/answerService.d.ts.map +1 -1
- package/lib/src/utils/graphql/answerService/answerService.js +2 -4
- package/lib/src/utils/graphql/answerService/answerService.js.map +1 -1
- package/lib/src/utils/processData.d.ts +6 -0
- package/lib/src/utils/processData.d.ts.map +1 -1
- package/lib/src/utils/processData.js +4 -1
- package/lib/src/utils/processData.js.map +1 -1
- package/lib/src/utils/processTrigger.js +1 -1
- package/lib/src/visual-embed-sdk.d.ts +898 -339
- package/package.json +1 -1
- package/src/auth.ts +10 -4
- package/src/embed/app.ts +20 -20
- package/src/embed/liveboard.ts +32 -27
- package/src/embed/sage.ts +48 -30
- package/src/embed/search-bar.tsx +22 -6
- package/src/embed/search.spec.ts +13 -0
- package/src/embed/search.ts +42 -22
- package/src/embed/ts-embed.spec.ts +132 -0
- package/src/embed/ts-embed.ts +32 -14
- package/src/react/index.spec.tsx +0 -29
- package/src/types.ts +727 -243
- package/src/utils/graphql/answerService/answerService.ts +2 -4
- package/src/utils/processData.ts +4 -1
- package/src/utils/processTrigger.ts +1 -1
- package/cjs/src/embed/TsEmbed.d.ts +0 -302
- package/cjs/src/embed/TsEmbed.d.ts.map +0 -1
- package/cjs/src/embed/TsEmbed.js +0 -851
- package/cjs/src/embed/TsEmbed.js.map +0 -1
- package/cjs/src/utils/answerService.d.ts +0 -10
- package/cjs/src/utils/answerService.d.ts.map +0 -1
- package/cjs/src/utils/answerService.js +0 -61
- package/cjs/src/utils/answerService.js.map +0 -1
- package/cjs/src/utils/answerService.spec.d.ts +0 -2
- package/cjs/src/utils/answerService.spec.d.ts.map +0 -1
- package/cjs/src/utils/answerService.spec.js +0 -31
- package/cjs/src/utils/answerService.spec.js.map +0 -1
- package/cjs/src/utils/authService/tokenisedAuthSerice.d.ts +0 -11
- package/cjs/src/utils/authService/tokenisedAuthSerice.d.ts.map +0 -1
- package/cjs/src/utils/authService/tokenisedAuthSerice.js +0 -44
- package/cjs/src/utils/authService/tokenisedAuthSerice.js.map +0 -1
- package/cjs/src/utils/authService.d.ts +0 -55
- package/cjs/src/utils/authService.d.ts.map +0 -1
- package/cjs/src/utils/authService.js +0 -139
- package/cjs/src/utils/authService.js.map +0 -1
- package/cjs/src/utils/authService.spec.d.ts +0 -2
- package/cjs/src/utils/authService.spec.d.ts.map +0 -1
- package/cjs/src/utils/authService.spec.js +0 -82
- package/cjs/src/utils/authService.spec.js.map +0 -1
- package/cjs/src/utils/graphql/graphql-request.spec.d.ts +0 -2
- package/cjs/src/utils/graphql/graphql-request.spec.d.ts.map +0 -1
- package/cjs/src/utils/graphql/graphql-request.spec.js +0 -39
- package/cjs/src/utils/graphql/graphql-request.spec.js.map +0 -1
- package/cjs/src/utils/logger.d.ts +0 -28
- package/cjs/src/utils/logger.d.ts.map +0 -1
- package/cjs/src/utils/logger.js +0 -82
- package/cjs/src/utils/logger.js.map +0 -1
- package/dist/src/utils/answerService.d.ts +0 -10
- package/dist/src/utils/answerService.d.ts.map +0 -1
- package/dist/src/utils/answerService.spec.d.ts +0 -2
- package/dist/src/utils/answerService.spec.d.ts.map +0 -1
- package/dist/src/utils/authService/tokenisedAuthSerice.d.ts +0 -11
- package/dist/src/utils/authService/tokenisedAuthSerice.d.ts.map +0 -1
- package/dist/src/utils/authService.d.ts +0 -55
- package/dist/src/utils/authService.d.ts.map +0 -1
- package/dist/src/utils/authService.spec.d.ts +0 -2
- package/dist/src/utils/authService.spec.d.ts.map +0 -1
- package/dist/src/utils/graphql/graphql-request.spec.d.ts +0 -2
- package/dist/src/utils/graphql/graphql-request.spec.d.ts.map +0 -1
- package/dist/src/utils/logger.d.ts +0 -28
- package/dist/src/utils/logger.d.ts.map +0 -1
- package/lib/src/embed/TsEmbed.d.ts +0 -302
- package/lib/src/embed/TsEmbed.d.ts.map +0 -1
- package/lib/src/embed/TsEmbed.js +0 -847
- package/lib/src/embed/TsEmbed.js.map +0 -1
- package/lib/src/utils/answerService.d.ts +0 -10
- package/lib/src/utils/answerService.d.ts.map +0 -1
- package/lib/src/utils/answerService.js +0 -57
- package/lib/src/utils/answerService.js.map +0 -1
- package/lib/src/utils/answerService.spec.d.ts +0 -2
- package/lib/src/utils/answerService.spec.d.ts.map +0 -1
- package/lib/src/utils/answerService.spec.js +0 -29
- package/lib/src/utils/answerService.spec.js.map +0 -1
- package/lib/src/utils/authService/tokenisedAuthSerice.d.ts +0 -11
- package/lib/src/utils/authService/tokenisedAuthSerice.d.ts.map +0 -1
- package/lib/src/utils/authService/tokenisedAuthSerice.js +0 -39
- package/lib/src/utils/authService/tokenisedAuthSerice.js.map +0 -1
- package/lib/src/utils/authService.d.ts +0 -55
- package/lib/src/utils/authService.d.ts.map +0 -1
- package/lib/src/utils/authService.js +0 -129
- package/lib/src/utils/authService.js.map +0 -1
- package/lib/src/utils/authService.spec.d.ts +0 -2
- package/lib/src/utils/authService.spec.d.ts.map +0 -1
- package/lib/src/utils/authService.spec.js +0 -80
- package/lib/src/utils/authService.spec.js.map +0 -1
- package/lib/src/utils/graphql/graphql-request.spec.d.ts +0 -2
- package/lib/src/utils/graphql/graphql-request.spec.d.ts.map +0 -1
- package/lib/src/utils/graphql/graphql-request.spec.js +0 -36
- package/lib/src/utils/graphql/graphql-request.spec.js.map +0 -1
- package/lib/src/utils/logger.d.ts +0 -28
- package/lib/src/utils/logger.d.ts.map +0 -1
- package/lib/src/utils/logger.js +0 -75
- package/lib/src/utils/logger.js.map +0 -1
|
@@ -65,43 +65,43 @@ export enum Page {
|
|
|
65
65
|
*/
|
|
66
66
|
export interface AppViewConfig extends Omit<ViewConfig, 'visibleTabs'> {
|
|
67
67
|
/**
|
|
68
|
-
* If true, the
|
|
68
|
+
* If true, the top navigation bar within the ThoughtSpot app
|
|
69
69
|
* is displayed. By default, the navigation bar is hidden.
|
|
70
|
-
* This flag also
|
|
70
|
+
* This flag also controls the homepage left navigation bar.
|
|
71
71
|
*/
|
|
72
72
|
showPrimaryNavbar?: boolean;
|
|
73
73
|
/**
|
|
74
|
-
*
|
|
75
|
-
* If showPrimaryNavbar is true,
|
|
76
|
-
* nav-
|
|
77
|
-
*
|
|
74
|
+
* Control the visibility of the left navigation bar on the Homepage.
|
|
75
|
+
* If showPrimaryNavbar is true, that is, if the Global and Homepage
|
|
76
|
+
* nav-bars are visible, this flag will only hide the homepage left nav-bar.
|
|
77
|
+
* The showPrimaryNavbar flag takes precedence over the hideHomepageLeftNav.
|
|
78
78
|
*
|
|
79
79
|
* @default false
|
|
80
80
|
* @version SDK: 1.27.0 | Thoughtspot: 9.8.0.cl
|
|
81
81
|
*/
|
|
82
82
|
hideHomepageLeftNav?: boolean;
|
|
83
83
|
/**
|
|
84
|
-
*
|
|
85
|
-
*
|
|
84
|
+
* Control the visibility of the help (?) and profile buttons on the
|
|
85
|
+
* Global nav-bar. By default, these buttons are visible on the nav-bar.
|
|
86
86
|
*/
|
|
87
87
|
disableProfileAndHelp?: boolean;
|
|
88
88
|
/**
|
|
89
|
-
*
|
|
90
|
-
*
|
|
89
|
+
* Control the visibility of the application switcher button on the nav-bar.
|
|
90
|
+
* By default, the application switcher is shown.
|
|
91
91
|
*/
|
|
92
92
|
hideApplicationSwitcher?: boolean;
|
|
93
93
|
/**
|
|
94
|
-
*
|
|
95
|
-
*
|
|
94
|
+
* Control the visibility of the Org switcher button on the nav-bar.
|
|
95
|
+
* By default, the Org switcher button is shown.
|
|
96
96
|
*/
|
|
97
97
|
hideOrgSwitcher?: boolean;
|
|
98
98
|
/**
|
|
99
|
-
* A URL path
|
|
99
|
+
* A URL path to the embedded application page
|
|
100
100
|
* If both path and pageId attributes are defined, the path definition
|
|
101
101
|
* takes precedence. This is the path post the `#/` in the URL of the standalone
|
|
102
102
|
* ThoughtSpot app. Use this to open the embedded view to a specific path.
|
|
103
103
|
*
|
|
104
|
-
* For eg, if you want the component to open to a specific
|
|
104
|
+
* For eg, if you want the component to open to a specific Liveboard
|
|
105
105
|
* you could set the path to `pinboard/<liveboardId>/tab/<tabId>`.
|
|
106
106
|
*
|
|
107
107
|
* @example
|
|
@@ -213,6 +213,12 @@ export class AppEmbed extends V1Embed {
|
|
|
213
213
|
* embedded Liveboard or visualization.
|
|
214
214
|
*/
|
|
215
215
|
protected getEmbedParams(): string;
|
|
216
|
+
/**
|
|
217
|
+
* Constructs the URL of the ThoughtSpot app page to be rendered.
|
|
218
|
+
*
|
|
219
|
+
* @param pageId The ID of the page to be embedded.
|
|
220
|
+
*/
|
|
221
|
+
getIFrameSrc(): string;
|
|
216
222
|
/**
|
|
217
223
|
* Set the iframe height as per the computed height received
|
|
218
224
|
* from the ThoughtSpot app.
|
|
@@ -404,8 +410,8 @@ export interface LiveboardViewConfig extends Omit<ViewConfig, 'hiddenHomepageMod
|
|
|
404
410
|
*/
|
|
405
411
|
fullHeight?: boolean;
|
|
406
412
|
/**
|
|
407
|
-
* This is the minimum height(in pixels) for a full
|
|
408
|
-
* Setting this height helps
|
|
413
|
+
* This is the minimum height(in pixels) for a full-height Liveboard.
|
|
414
|
+
* Setting this height helps resolve issues with empty Liveboards and
|
|
409
415
|
* other screens navigable from a Liveboard.
|
|
410
416
|
*
|
|
411
417
|
* @version SDK: 1.5.0 | ThoughtSpot: ts7.oct.cl, 7.2.1
|
|
@@ -418,7 +424,7 @@ export interface LiveboardViewConfig extends Omit<ViewConfig, 'hiddenHomepageMod
|
|
|
418
424
|
enableVizTransformations?: boolean;
|
|
419
425
|
/**
|
|
420
426
|
* The Liveboard to display in the embedded view.
|
|
421
|
-
* Use either
|
|
427
|
+
* Use either liveboardId or pinboardId to reference the Liveboard to embed.
|
|
422
428
|
*
|
|
423
429
|
* @version SDK: 1.3.0 | ThoughtSpot ts7.aug.cl, 7.2.1
|
|
424
430
|
*/
|
|
@@ -437,79 +443,84 @@ export interface LiveboardViewConfig extends Omit<ViewConfig, 'hiddenHomepageMod
|
|
|
437
443
|
* If set to true, all filter chips from a
|
|
438
444
|
* Liveboard page will be read-only (no X buttons)
|
|
439
445
|
*
|
|
440
|
-
* @version SDK: 1.3.0 | ThoughtSpot ts7.aug.cl, 7.2.1
|
|
446
|
+
* @version SDK: 1.3.0 | ThoughtSpot ts7.aug.cl, 7.2.1.sw
|
|
441
447
|
*/
|
|
442
448
|
preventLiveboardFilterRemoval?: boolean;
|
|
443
449
|
/**
|
|
444
|
-
* Array of
|
|
445
|
-
*
|
|
450
|
+
* Array of visualization IDs which should be visible when the Liveboard
|
|
451
|
+
* renders. This can be changed by triggering the `SetVisibleVizs`
|
|
446
452
|
* event.
|
|
447
453
|
*
|
|
448
454
|
* @version SDK: 1.9.1 | ThoughtSpot: 8.1.0.cl, 8.4.1-sw
|
|
449
455
|
*/
|
|
450
456
|
visibleVizs?: string[];
|
|
451
457
|
/**
|
|
452
|
-
* To support backward
|
|
458
|
+
* To support backward compatibility
|
|
453
459
|
*
|
|
454
460
|
* @hidden
|
|
455
461
|
*/
|
|
456
462
|
preventPinboardFilterRemoval?: boolean;
|
|
457
463
|
/**
|
|
458
|
-
* Render embedded Liveboards and visualizations in the
|
|
464
|
+
* Render embedded Liveboards and visualizations in the
|
|
465
|
+
* new Liveboard experience mode.
|
|
459
466
|
*
|
|
460
467
|
* @version SDK: 1.14.0 | ThoughtSpot: 8.6.0.cl, 8.8.1-sw
|
|
461
468
|
*/
|
|
462
469
|
liveboardV2?: boolean;
|
|
463
470
|
/**
|
|
464
|
-
*
|
|
471
|
+
* Set a Liveboard tab as an active tab.
|
|
472
|
+
* Specify the tab ID.
|
|
465
473
|
*
|
|
466
474
|
* @version SDK: 1.15.0 | ThoughtSpot: 8.7.0.cl, 8.8.1-sw
|
|
467
475
|
*/
|
|
468
476
|
activeTabId?: string;
|
|
469
477
|
/**
|
|
470
|
-
*
|
|
478
|
+
* Show or hide the tab panel of the embedded Liveboard.
|
|
471
479
|
*
|
|
472
|
-
* @version SDK: 1.25.0 | Thoughtspot: 9.6.0.cl
|
|
480
|
+
* @version SDK: 1.25.0 | Thoughtspot: 9.6.0.cl, 9.8.0.sw
|
|
473
481
|
*/
|
|
474
482
|
hideTabPanel?: boolean;
|
|
475
483
|
/**
|
|
476
|
-
* Show or hide Liveboard header
|
|
484
|
+
* Show or hide the Liveboard header.
|
|
477
485
|
*
|
|
478
|
-
* @version SDK: 1.26.0 | Thoughtspot: 9.7.0.cl
|
|
486
|
+
* @version SDK: 1.26.0 | Thoughtspot: 9.7.0.cl, 9.8.0.sw
|
|
479
487
|
* @default false
|
|
480
488
|
*/
|
|
481
489
|
hideLiveboardHeader?: boolean;
|
|
482
490
|
/**
|
|
483
|
-
* Show or hide Liveboard title
|
|
491
|
+
* Show or hide the Liveboard title.
|
|
484
492
|
*
|
|
485
|
-
* @version SDK: 1.26.0 | Thoughtspot: 9.7.0.cl
|
|
493
|
+
* @version SDK: 1.26.0 | Thoughtspot: 9.7.0.cl, 9.8.0.sw
|
|
486
494
|
* @default false
|
|
487
495
|
*/
|
|
488
496
|
showLiveboardTitle?: boolean;
|
|
489
497
|
/**
|
|
490
|
-
* Show or hide Liveboard description
|
|
498
|
+
* Show or hide the Liveboard description.
|
|
491
499
|
*
|
|
492
|
-
* @version SDK: 1.26.0 | Thoughtspot: 9.7.0.cl
|
|
500
|
+
* @version SDK: 1.26.0 | Thoughtspot: 9.7.0.cl, 9.8.0.sw
|
|
493
501
|
* @default false
|
|
494
502
|
*/
|
|
495
503
|
showLiveboardDescription?: boolean;
|
|
496
504
|
/**
|
|
497
|
-
*
|
|
505
|
+
* Control the position and visibility of
|
|
506
|
+
* the Liveboard header as the users scroll down the
|
|
507
|
+
* embedded Liveboard page.
|
|
498
508
|
*
|
|
499
509
|
* @example
|
|
500
510
|
* ```js
|
|
501
511
|
* const embed = new LiveboardEmbed('#embed', {
|
|
502
|
-
* ... // other
|
|
512
|
+
* ... // other Liveboard view config
|
|
503
513
|
* isLiveboardHeaderSticky: true,
|
|
504
514
|
* });
|
|
505
515
|
* ```
|
|
506
|
-
* @version SDK: 1.26.0 | Thoughtspot: 9.7.0.cl
|
|
516
|
+
* @version SDK: 1.26.0 | Thoughtspot: 9.7.0.cl, 9.8.0.sw
|
|
507
517
|
*/
|
|
508
518
|
isLiveboardHeaderSticky?: boolean;
|
|
509
519
|
}
|
|
510
520
|
/**
|
|
511
|
-
* Embed a ThoughtSpot Liveboard or
|
|
512
|
-
* waits for the authentication to complete, so
|
|
521
|
+
* Embed a ThoughtSpot Liveboard or visualization. When rendered it already
|
|
522
|
+
* waits for the authentication to complete, so you need not wait for
|
|
523
|
+
* `AuthStatus.SUCCESS`.
|
|
513
524
|
*
|
|
514
525
|
* @example
|
|
515
526
|
* ```js
|
|
@@ -564,18 +575,19 @@ export class PinboardEmbed extends LiveboardEmbed {
|
|
|
564
575
|
* @author Ayon Ghosh <ayon.ghosh@thoughtspot.com>
|
|
565
576
|
*/
|
|
566
577
|
/**
|
|
567
|
-
* Configuration for search options
|
|
578
|
+
* Configuration for search options.
|
|
579
|
+
*
|
|
568
580
|
*/
|
|
569
581
|
export interface SearchOptions {
|
|
570
582
|
/**
|
|
571
|
-
*
|
|
583
|
+
* Search tokens to pass in the query.
|
|
572
584
|
*/
|
|
573
585
|
searchTokenString: string;
|
|
574
586
|
/**
|
|
575
|
-
* Boolean to
|
|
576
|
-
*
|
|
577
|
-
*
|
|
578
|
-
* the
|
|
587
|
+
* Boolean to define if the search should be executed or not.
|
|
588
|
+
* If it is executed, the focus is placed on the results.
|
|
589
|
+
* If it’s not executed, the focus is placed at the end of
|
|
590
|
+
* the token string in the search bar.
|
|
579
591
|
*/
|
|
580
592
|
executeSearch?: boolean;
|
|
581
593
|
}
|
|
@@ -591,19 +603,15 @@ export interface SearchViewConfig extends Omit<ViewConfig, 'hiddenHomepageModule
|
|
|
591
603
|
*/
|
|
592
604
|
collapseDataSources?: boolean;
|
|
593
605
|
/**
|
|
594
|
-
*
|
|
606
|
+
* Show or hide the data sources panel.
|
|
595
607
|
*/
|
|
596
608
|
hideDataSources?: boolean;
|
|
597
609
|
/**
|
|
598
|
-
*
|
|
610
|
+
* Show or hide the charts and tables in search answers.
|
|
599
611
|
* This attribute can be used to create a custom visualization
|
|
600
612
|
* using raw answer data.
|
|
601
613
|
*/
|
|
602
614
|
hideResults?: boolean;
|
|
603
|
-
/**
|
|
604
|
-
* If set to true, expands all the data sources panel.
|
|
605
|
-
*/
|
|
606
|
-
expandAllDataSource?: boolean;
|
|
607
615
|
/**
|
|
608
616
|
* If set to true, the Search Assist feature is enabled.
|
|
609
617
|
*
|
|
@@ -617,9 +625,9 @@ export interface SearchViewConfig extends Omit<ViewConfig, 'hiddenHomepageModule
|
|
|
617
625
|
forceTable?: boolean;
|
|
618
626
|
/**
|
|
619
627
|
* The array of data source GUIDs to set on load.
|
|
620
|
-
* Only a single
|
|
628
|
+
* Only a single data source is supported currently.
|
|
621
629
|
*
|
|
622
|
-
* @deprecated Use dataSource instead
|
|
630
|
+
* @deprecated Use `dataSource` instead.
|
|
623
631
|
*/
|
|
624
632
|
dataSources?: string[];
|
|
625
633
|
/**
|
|
@@ -631,11 +639,29 @@ export interface SearchViewConfig extends Omit<ViewConfig, 'hiddenHomepageModule
|
|
|
631
639
|
/**
|
|
632
640
|
* The initial search query to load the answer with.
|
|
633
641
|
*
|
|
634
|
-
* @deprecated
|
|
642
|
+
* @deprecated
|
|
643
|
+
*
|
|
644
|
+
* Use {@link searchOptions} instead.
|
|
635
645
|
*/
|
|
636
646
|
searchQuery?: string;
|
|
637
647
|
/**
|
|
638
|
-
* Configuration for search options
|
|
648
|
+
* Configuration for search options.
|
|
649
|
+
* Includes the following properties:
|
|
650
|
+
*
|
|
651
|
+
* `searchTokenString`: Search tokens to pass in the query.
|
|
652
|
+
*
|
|
653
|
+
* `executeSearch`: Boolean to define if the search should be executed or not.
|
|
654
|
+
* If it is executed, the focus is placed on the results.
|
|
655
|
+
* If it’s not executed, the focus is placed at the end of
|
|
656
|
+
* the token string in the search bar.
|
|
657
|
+
*
|
|
658
|
+
* @example
|
|
659
|
+
* ```js
|
|
660
|
+
* searchOptions: {
|
|
661
|
+
* searchTokenString: '[quantity purchased] [region]',
|
|
662
|
+
* executeSearch: true,
|
|
663
|
+
* }
|
|
664
|
+
* ```
|
|
639
665
|
*/
|
|
640
666
|
searchOptions?: SearchOptions;
|
|
641
667
|
/**
|
|
@@ -643,10 +669,10 @@ export interface SearchViewConfig extends Omit<ViewConfig, 'hiddenHomepageModule
|
|
|
643
669
|
*/
|
|
644
670
|
answerId?: string;
|
|
645
671
|
/**
|
|
646
|
-
* If set to true, search page will render without the Search Bar
|
|
672
|
+
* If set to true, the search page will render without the Search Bar
|
|
647
673
|
* The chart/table should still be visible.
|
|
648
674
|
*
|
|
649
|
-
* @version SDK: 1.21.0 | ThoughtSpot: 9.2.0.cl
|
|
675
|
+
* @version SDK: 1.21.0 | ThoughtSpot: 9.2.0.cl, 9.5.0.sw
|
|
650
676
|
*/
|
|
651
677
|
hideSearchBar?: boolean;
|
|
652
678
|
/**
|
|
@@ -677,6 +703,14 @@ export class SearchEmbed extends TsEmbed {
|
|
|
677
703
|
protected embedComponentType: string;
|
|
678
704
|
constructor(domSelector: DOMSelector, viewConfig: SearchViewConfig);
|
|
679
705
|
protected getEmbedParams(): string;
|
|
706
|
+
/**
|
|
707
|
+
* Construct the URL of the embedded ThoughtSpot search to be
|
|
708
|
+
* loaded in the iframe
|
|
709
|
+
*
|
|
710
|
+
* @param answerId The GUID of a saved answer
|
|
711
|
+
* @param dataSources A list of data source GUIDs
|
|
712
|
+
*/
|
|
713
|
+
getIFrameSrc(): string;
|
|
680
714
|
/**
|
|
681
715
|
* Render the embedded ThoughtSpot search
|
|
682
716
|
*/
|
|
@@ -689,25 +723,41 @@ export class SearchEmbed extends TsEmbed {
|
|
|
689
723
|
export interface SearchBarViewConfig extends Omit<ViewConfig, 'runtimeFilters' | 'showAlerts' | 'dataPanelV2' | 'hiddenHomepageModules' | 'hiddenHomeLeftNavItems' | 'hiddenTabs' | 'visibleTabs' | 'reorderedHomepageModules'> {
|
|
690
724
|
/**
|
|
691
725
|
* The array of data source GUIDs to set on load.
|
|
692
|
-
* Only a single
|
|
726
|
+
* Only a single data source is supported currently.
|
|
693
727
|
*
|
|
694
|
-
* @deprecated Use dataSource instead
|
|
728
|
+
* @deprecated Use `dataSource` instead
|
|
695
729
|
*/
|
|
696
730
|
dataSources?: string[];
|
|
697
731
|
/**
|
|
698
732
|
* The array of data source GUIDs to set on load.
|
|
699
733
|
*
|
|
700
|
-
* @version: SDK: 1.19.0
|
|
734
|
+
* @version: SDK: 1.19.0, ThoughtSpot 9.0.0.cl, 9.0.1.sw
|
|
701
735
|
*/
|
|
702
736
|
dataSource?: string;
|
|
703
737
|
/**
|
|
704
|
-
*
|
|
738
|
+
* Boolean to define if the last selected data source should be used
|
|
705
739
|
*
|
|
706
|
-
* @version: SDK: 1.24.0
|
|
740
|
+
* @version: SDK: 1.24.0, ThoughtSpot 9.5.0.cl, 9.5.0.sw
|
|
707
741
|
*/
|
|
708
742
|
useLastSelectedSources?: boolean;
|
|
709
743
|
/**
|
|
710
|
-
* Configuration for search options
|
|
744
|
+
* Configuration for search options.
|
|
745
|
+
* Includes the following properties:
|
|
746
|
+
*
|
|
747
|
+
* `searchTokenString`: Search tokens to pass in the query.
|
|
748
|
+
*
|
|
749
|
+
* `executeSearch`: Boolean to define if the search should be executed or not.
|
|
750
|
+
* If it is executed, the focus is placed on the results.
|
|
751
|
+
* If it’s not executed, the focus is placed at the end of
|
|
752
|
+
* the token string in the search bar.
|
|
753
|
+
*
|
|
754
|
+
* @example
|
|
755
|
+
* ```js
|
|
756
|
+
* searchOptions: {
|
|
757
|
+
* searchTokenString: '[quantity purchased] [region]',
|
|
758
|
+
* executeSearch: true,
|
|
759
|
+
* }
|
|
760
|
+
* ```
|
|
711
761
|
*/
|
|
712
762
|
searchOptions?: SearchOptions;
|
|
713
763
|
}
|
|
@@ -775,8 +825,8 @@ export enum AuthStatus {
|
|
|
775
825
|
*/
|
|
776
826
|
LOGOUT = "LOGOUT",
|
|
777
827
|
/**
|
|
778
|
-
* Emitted when inPopup
|
|
779
|
-
*
|
|
828
|
+
* Emitted when inPopup is true in the SAMLRedirect flow and the
|
|
829
|
+
* popup is waiting to be triggered either programmatically
|
|
780
830
|
* or by the trigger button.
|
|
781
831
|
*
|
|
782
832
|
* @version SDK: 1.19.0
|
|
@@ -821,8 +871,8 @@ export interface AuthEventEmitter {
|
|
|
821
871
|
*/
|
|
822
872
|
export enum AuthEvent {
|
|
823
873
|
/**
|
|
824
|
-
* Manually trigger the SSO popup. This is useful
|
|
825
|
-
* authStatus
|
|
874
|
+
* Manually trigger the SSO popup. This is useful when
|
|
875
|
+
* authStatus is SAMLRedirect/OIDCRedirect and inPopup is set to true
|
|
826
876
|
*/
|
|
827
877
|
TRIGGER_SSO_POPUP = "TRIGGER_SSO_POPUP"
|
|
828
878
|
}
|
|
@@ -931,10 +981,14 @@ export enum AuthType {
|
|
|
931
981
|
*/
|
|
932
982
|
None = "None",
|
|
933
983
|
/**
|
|
934
|
-
* Passthrough SSO to the embedded
|
|
984
|
+
* Passthrough SSO to the embedded application within the iframe. Requires least
|
|
935
985
|
* configuration, but may not be supported by all IDPs. This will behave like `None`
|
|
936
986
|
* if SSO is not configured on ThoughtSpot.
|
|
937
987
|
*
|
|
988
|
+
* To use this:
|
|
989
|
+
* Your SAML or OpenID provider must allow iframe redirects.
|
|
990
|
+
* For example, if you are using Okta as IdP, you can enable iframe embedding.
|
|
991
|
+
*
|
|
938
992
|
* @example
|
|
939
993
|
* ```js
|
|
940
994
|
* init({
|
|
@@ -942,12 +996,7 @@ export enum AuthType {
|
|
|
942
996
|
* authType: AuthType.EmbeddedSSO,
|
|
943
997
|
* });
|
|
944
998
|
* ```
|
|
945
|
-
*
|
|
946
|
-
*
|
|
947
|
-
* To use this:
|
|
948
|
-
* Your SAML or OpenID provider must allow iframe redirects.
|
|
949
|
-
* eg. If you are using okta as IdP, you can enable iFrame embedding.
|
|
950
|
-
* @version: SDK: 1.15.0 | ThouhgtSpot: 8.8.0.cl
|
|
999
|
+
* @version: SDK: 1.15.0 | ThoughtSpot: 8.8.0.cl
|
|
951
1000
|
*/
|
|
952
1001
|
EmbeddedSSO = "EmbeddedSSO",
|
|
953
1002
|
/**
|
|
@@ -966,10 +1015,10 @@ export enum AuthType {
|
|
|
966
1015
|
SAML = "SSO_SAML",
|
|
967
1016
|
/**
|
|
968
1017
|
* SSO using SAML
|
|
969
|
-
*
|
|
970
|
-
*
|
|
1018
|
+
* Makes the host application redirect to the SAML IdP. Use this
|
|
1019
|
+
* if your IdP does not allow itself to be embedded.
|
|
971
1020
|
*
|
|
972
|
-
* This redirects the host application to the SAML
|
|
1021
|
+
* This redirects the host application to the SAML IdP. The host application
|
|
973
1022
|
* will be redirected back to the ThoughtSpot app after authentication.
|
|
974
1023
|
*
|
|
975
1024
|
* @example
|
|
@@ -980,7 +1029,7 @@ export enum AuthType {
|
|
|
980
1029
|
* });
|
|
981
1030
|
* ```
|
|
982
1031
|
*
|
|
983
|
-
* This opens the SAML
|
|
1032
|
+
* This opens the SAML IdP in a popup window. The popup is triggered
|
|
984
1033
|
* when the user clicks the trigger button. The popup window will be
|
|
985
1034
|
* closed automatically after authentication.
|
|
986
1035
|
* @example
|
|
@@ -994,8 +1043,8 @@ export enum AuthType {
|
|
|
994
1043
|
* });
|
|
995
1044
|
* ```
|
|
996
1045
|
*
|
|
997
|
-
* Can also use event to trigger the popup flow. Works the same
|
|
998
|
-
* as above example.
|
|
1046
|
+
* Can also use the event to trigger the popup flow. Works the same
|
|
1047
|
+
* as the above example.
|
|
999
1048
|
* @example
|
|
1000
1049
|
* ```js
|
|
1001
1050
|
* const authEE = init({
|
|
@@ -1019,7 +1068,7 @@ export enum AuthType {
|
|
|
1019
1068
|
OIDC = "SSO_OIDC",
|
|
1020
1069
|
/**
|
|
1021
1070
|
* SSO using OIDC
|
|
1022
|
-
* Will make the host application redirect to the OIDC
|
|
1071
|
+
* Will make the host application redirect to the OIDC IdP.
|
|
1023
1072
|
* See code samples in {@link SAMLRedirect}.
|
|
1024
1073
|
*/
|
|
1025
1074
|
OIDCRedirect = "SSO_OIDC",
|
|
@@ -1031,8 +1080,8 @@ export enum AuthType {
|
|
|
1031
1080
|
*/
|
|
1032
1081
|
AuthServer = "AuthServer",
|
|
1033
1082
|
/**
|
|
1034
|
-
* Trusted authentication server
|
|
1035
|
-
* which returns a bearer token, generated using the secret_key obtained
|
|
1083
|
+
* Trusted authentication server. Use your own authentication server
|
|
1084
|
+
* which returns a bearer token, generated using the `secret_key` obtained
|
|
1036
1085
|
* from ThoughtSpot.
|
|
1037
1086
|
*
|
|
1038
1087
|
* @example
|
|
@@ -1049,11 +1098,11 @@ export enum AuthType {
|
|
|
1049
1098
|
*/
|
|
1050
1099
|
TrustedAuthToken = "AuthServer",
|
|
1051
1100
|
/**
|
|
1052
|
-
* Trusted authentication server Cookieless, Use
|
|
1053
|
-
* server which returns a bearer token, generated using the secret_key
|
|
1101
|
+
* Trusted authentication server Cookieless, Use your own authentication
|
|
1102
|
+
* server which returns a bearer token, generated using the `secret_key`
|
|
1054
1103
|
* obtained from ThoughtSpot. This uses a cookieless authentication
|
|
1055
|
-
* approach, recommended to
|
|
1056
|
-
* implemented by some browsers
|
|
1104
|
+
* approach, recommended to bypass the third-party cookie-blocking restriction
|
|
1105
|
+
* implemented by some browsers.
|
|
1057
1106
|
*
|
|
1058
1107
|
* @example
|
|
1059
1108
|
* ```js
|
|
@@ -1066,7 +1115,7 @@ export enum AuthType {
|
|
|
1066
1115
|
* .then((data) => data.token);
|
|
1067
1116
|
* }
|
|
1068
1117
|
* ```
|
|
1069
|
-
* @version SDK: 1.22.0|
|
|
1118
|
+
* @version SDK: 1.22.0| ThoughtSpot: 9.3.0.cl, 9.5.1.sw
|
|
1070
1119
|
*/
|
|
1071
1120
|
TrustedAuthTokenCookieless = "AuthServerCookieless",
|
|
1072
1121
|
/**
|
|
@@ -1188,13 +1237,19 @@ export interface EmbedConfig {
|
|
|
1188
1237
|
* The ThoughtSpot cluster hostname or IP address.
|
|
1189
1238
|
*/
|
|
1190
1239
|
thoughtSpotHost: string;
|
|
1240
|
+
/**
|
|
1241
|
+
* If true, all the iframe links will have /v2 added automatically.
|
|
1242
|
+
* If false, all the iframe links will have /v1 added automatically.
|
|
1243
|
+
* If undefined, nothing will be added
|
|
1244
|
+
*/
|
|
1245
|
+
enableReactShell?: boolean | undefined;
|
|
1191
1246
|
/**
|
|
1192
1247
|
* The authentication mechanism to use.
|
|
1193
1248
|
*/
|
|
1194
1249
|
authType: AuthType;
|
|
1195
1250
|
/**
|
|
1196
1251
|
* [AuthServer] The trusted authentication endpoint to use to get the
|
|
1197
|
-
* authentication token. A GET request is made to the
|
|
1252
|
+
* authentication token. A `GET` request is made to the
|
|
1198
1253
|
* authentication API endpoint, which returns the token
|
|
1199
1254
|
* as a plaintext response. For trusted authentication,
|
|
1200
1255
|
* the `authEndpoint` or `getAuthToken` attribute is required.
|
|
@@ -1207,8 +1262,8 @@ export interface EmbedConfig {
|
|
|
1207
1262
|
* attribute is required.
|
|
1208
1263
|
*
|
|
1209
1264
|
* It is advisable to fetch a new token inside this method and not
|
|
1210
|
-
* reuse
|
|
1211
|
-
* called again and if it is called with an older token the authentication
|
|
1265
|
+
* reuse the old issued token. When auth expires this method is
|
|
1266
|
+
* called again and if it is called with an older token, the authentication
|
|
1212
1267
|
* will not succeed.
|
|
1213
1268
|
*/
|
|
1214
1269
|
getAuthToken?: () => Promise<string>;
|
|
@@ -1218,7 +1273,7 @@ export interface EmbedConfig {
|
|
|
1218
1273
|
*/
|
|
1219
1274
|
username?: string;
|
|
1220
1275
|
/**
|
|
1221
|
-
* [Basic] The ThoughtSpot login password corresponding to the
|
|
1276
|
+
* [Basic] The ThoughtSpot login password corresponding to the username
|
|
1222
1277
|
*
|
|
1223
1278
|
* Warning: This feature is primarily intended for developer testing. It is
|
|
1224
1279
|
* strongly advised not to use this authentication method in production.
|
|
@@ -1226,7 +1281,7 @@ export interface EmbedConfig {
|
|
|
1226
1281
|
password?: string;
|
|
1227
1282
|
/**
|
|
1228
1283
|
* [SSO] For SSO Authentication, if `noRedirect` is set to true, it will
|
|
1229
|
-
* open the SAML auth flow in a popup, instead of redirecting browser in
|
|
1284
|
+
* open the SAML auth flow in a popup, instead of redirecting the browser in
|
|
1230
1285
|
* place.
|
|
1231
1286
|
*
|
|
1232
1287
|
* @default false
|
|
@@ -1235,91 +1290,93 @@ export interface EmbedConfig {
|
|
|
1235
1290
|
noRedirect?: boolean;
|
|
1236
1291
|
/**
|
|
1237
1292
|
* [SSO] For SSO Authentication, if `inPopup` is set to true, it will open
|
|
1238
|
-
* the SAML auth flow in a popup, instead of redirecting browser in place.
|
|
1293
|
+
* the SAML auth flow in a popup, instead of redirecting the browser in place.
|
|
1239
1294
|
*
|
|
1240
|
-
* Need to use this with authTriggerContainer
|
|
1241
|
-
* the AuthEvent.TRIGGER_SSO_POPUP event on a user interaction.
|
|
1295
|
+
* Need to use this with `authTriggerContainer`. Or manually trigger
|
|
1296
|
+
* the `AuthEvent.TRIGGER_SSO_POPUP` event on a user interaction.
|
|
1242
1297
|
*
|
|
1243
1298
|
* @default false
|
|
1244
1299
|
* @version SDK: 1.18.0
|
|
1245
1300
|
*/
|
|
1246
1301
|
inPopup?: boolean;
|
|
1247
1302
|
/**
|
|
1248
|
-
* [SSO] For SSO Authentication, one can supply an optional path param
|
|
1249
|
-
*
|
|
1303
|
+
* [SSO] For SSO Authentication, one can supply an optional path param;
|
|
1304
|
+
* This will be the path on the host origin where the SAML flow will be
|
|
1250
1305
|
* terminated.
|
|
1251
1306
|
*
|
|
1252
1307
|
* Eg: "/dashboard", "#/foo" [Do not include the host]
|
|
1253
1308
|
*
|
|
1254
|
-
* @version SDK: 1.10.2 | 8.2.0.cl, 8.4.1.sw
|
|
1309
|
+
* @version SDK: 1.10.2 | ThoughtSpot 8.2.0.cl, 8.4.1.sw
|
|
1255
1310
|
*/
|
|
1256
1311
|
redirectPath?: string;
|
|
1257
1312
|
/** @internal */
|
|
1258
1313
|
basepath?: string;
|
|
1259
1314
|
/**
|
|
1260
|
-
*
|
|
1261
|
-
*
|
|
1262
|
-
*
|
|
1315
|
+
* Boolean to define if the query parameters in the ThoughtSpot URL
|
|
1316
|
+
* should be encoded in base64. This provides additional security to
|
|
1317
|
+
* Thoughtspot clusters against cross-site scripting attacks.
|
|
1263
1318
|
*
|
|
1264
1319
|
* @default false
|
|
1265
1320
|
*/
|
|
1266
1321
|
shouldEncodeUrlQueryParams?: boolean;
|
|
1267
1322
|
/**
|
|
1268
|
-
* Suppress cookie access alert when third
|
|
1269
|
-
* user's browser. Third
|
|
1270
|
-
*
|
|
1271
|
-
* encouraged to handle `noCookieAccess` event, to show your own treatment
|
|
1323
|
+
* Suppress cookie access alert when third-party cookies are blocked by the
|
|
1324
|
+
* user's browser. Third-party cookie blocking is the default behaviour on
|
|
1325
|
+
* some web browsers like Safari. If you set this attribute to `true`,
|
|
1326
|
+
* you are encouraged to handle `noCookieAccess` event, to show your own treatment
|
|
1272
1327
|
* in this case.
|
|
1273
1328
|
*
|
|
1274
1329
|
* @default false
|
|
1275
1330
|
*/
|
|
1276
1331
|
suppressNoCookieAccessAlert?: boolean;
|
|
1277
1332
|
/**
|
|
1278
|
-
* Ignore cookie access alert when third
|
|
1333
|
+
* Ignore the cookie access alert when third-party cookies are blocked by the
|
|
1279
1334
|
* user's browser. If you set this to `true`, the embedded iframe behaviour
|
|
1280
|
-
*
|
|
1335
|
+
* persists even in the case of a non-logged-in user.
|
|
1281
1336
|
*
|
|
1282
1337
|
* @default false
|
|
1283
1338
|
*/
|
|
1284
1339
|
ignoreNoCookieAccess?: boolean;
|
|
1285
1340
|
/**
|
|
1286
|
-
* Re-login
|
|
1341
|
+
* Re-login a user with the previous login options
|
|
1342
|
+
* when a user session expires.
|
|
1287
1343
|
*
|
|
1288
1344
|
* @default false
|
|
1289
1345
|
*/
|
|
1290
1346
|
autoLogin?: boolean;
|
|
1291
1347
|
/**
|
|
1292
1348
|
* Disable redirection to the login page when the embedded session expires
|
|
1293
|
-
* This flag is typically used alongside the combination of
|
|
1294
|
-
* AuthType.AuthServer} and auto
|
|
1349
|
+
* This flag is typically used alongside the combination of authentication modes such
|
|
1350
|
+
* as {@link AuthType.AuthServer} and auto-login behavior {@link
|
|
1351
|
+
* EmbedConfig.autoLogin}
|
|
1295
1352
|
*
|
|
1296
1353
|
* @version SDK: 1.9.3 | ThoughtSpot: 8.1.0.cl, 8.4.1.sw
|
|
1297
1354
|
* @default false
|
|
1298
1355
|
*/
|
|
1299
1356
|
disableLoginRedirect?: boolean;
|
|
1300
1357
|
/**
|
|
1301
|
-
* This message is displayed
|
|
1358
|
+
* This message is displayed in the embedded view when a user login fails.
|
|
1302
1359
|
*
|
|
1303
1360
|
* @version SDK: 1.10.1 | ThoughtSpot: 8.2.0.cl, 8.4.1.sw
|
|
1304
1361
|
*/
|
|
1305
1362
|
loginFailedMessage?: string;
|
|
1306
1363
|
/**
|
|
1307
|
-
* Calls the prefetch method internally when set to true
|
|
1364
|
+
* Calls the prefetch method internally when set to `true`
|
|
1308
1365
|
*
|
|
1309
1366
|
* @default false
|
|
1310
1367
|
*/
|
|
1311
1368
|
callPrefetch?: boolean;
|
|
1312
1369
|
/**
|
|
1313
|
-
* When there are multiple
|
|
1314
|
-
*
|
|
1315
|
-
*
|
|
1370
|
+
* When there are multiple objects embedded, queue the rendering of embedded objects
|
|
1371
|
+
* to start after the previous embed's render is complete. This helps improve
|
|
1372
|
+
* performance by decreasing the load on the browser.
|
|
1316
1373
|
*
|
|
1317
1374
|
* @Version SDK: 1.5.0 | ThoughtSpot: ts7.oct.cl, 7.2.1
|
|
1318
1375
|
* @default false
|
|
1319
1376
|
*/
|
|
1320
1377
|
queueMultiRenders?: boolean;
|
|
1321
1378
|
/**
|
|
1322
|
-
* Dynamic CSS
|
|
1379
|
+
* Dynamic CSS URL to be injected in the loaded application.
|
|
1323
1380
|
* You would also need to set `style-src` in the CSP settings.
|
|
1324
1381
|
*
|
|
1325
1382
|
* @version SDK: 1.6.0 | ThoughtSpot: ts8.nov.cl, 8.4.1.sw
|
|
@@ -1327,9 +1384,9 @@ export interface EmbedConfig {
|
|
|
1327
1384
|
*/
|
|
1328
1385
|
customCssUrl?: string;
|
|
1329
1386
|
/**
|
|
1330
|
-
* [AuthServer|Basic] Detect if
|
|
1387
|
+
* [AuthServer|Basic] Detect if third-party party cookies are enabled by doing an
|
|
1331
1388
|
* additional call. This is slower and should be avoided. Listen to the
|
|
1332
|
-
* NO_COOKIE_ACCESS event to handle the situation.
|
|
1389
|
+
* `NO_COOKIE_ACCESS` event to handle the situation.
|
|
1333
1390
|
*
|
|
1334
1391
|
* This is slightly slower than letting the browser handle the cookie check, as it
|
|
1335
1392
|
* involves an extra network call.
|
|
@@ -1338,26 +1395,26 @@ export interface EmbedConfig {
|
|
|
1338
1395
|
*/
|
|
1339
1396
|
detectCookieAccessSlow?: boolean;
|
|
1340
1397
|
/**
|
|
1341
|
-
* Hide beta alert warning message for SearchEmbed.
|
|
1398
|
+
* Hide the `beta` alert warning message for SearchEmbed.
|
|
1342
1399
|
*
|
|
1343
1400
|
* @version SDK: 1.12.0 | ThoughtSpot: 8.4.0.cl, 8.4.1.sw*
|
|
1344
1401
|
*/
|
|
1345
1402
|
suppressSearchEmbedBetaWarning?: boolean;
|
|
1346
1403
|
/**
|
|
1347
|
-
* Hide beta alert warning message for SageEmbed.
|
|
1404
|
+
* Hide `beta` alert warning message for SageEmbed.
|
|
1348
1405
|
*
|
|
1349
1406
|
*/
|
|
1350
1407
|
suppressSageEmbedBetaWarning?: boolean;
|
|
1351
1408
|
/**
|
|
1352
1409
|
* Custom style params for embed Config.
|
|
1353
1410
|
*
|
|
1354
|
-
* @version SDK: 1.17.0 | ThoughtSpot: 8.9.0.cl
|
|
1411
|
+
* @version SDK: 1.17.0 | ThoughtSpot: 8.9.0.cl, 9.0.1.sw
|
|
1355
1412
|
*/
|
|
1356
1413
|
customizations?: CustomisationsInterface;
|
|
1357
1414
|
/**
|
|
1358
|
-
* For inPopup SAMLRedirect or OIDCRedirect
|
|
1359
|
-
* click to trigger the flow.
|
|
1360
|
-
* for that button.
|
|
1415
|
+
* For `inPopup` SAMLRedirect or OIDCRedirect authentication, we need a
|
|
1416
|
+
* button that the user can click to trigger the flow.
|
|
1417
|
+
* This attribute sets a containing element for that button.
|
|
1361
1418
|
*
|
|
1362
1419
|
* @example
|
|
1363
1420
|
* ```js
|
|
@@ -1367,11 +1424,11 @@ export interface EmbedConfig {
|
|
|
1367
1424
|
* authTriggerContainer: '#auth-trigger-container'
|
|
1368
1425
|
* })
|
|
1369
1426
|
* ```
|
|
1370
|
-
* @version SDK: 1.17.0 | ThoughtSpot:
|
|
1427
|
+
* @version SDK: 1.17.0 | ThoughtSpot: 8.9.0.cl, 9.0.1.sw
|
|
1371
1428
|
*/
|
|
1372
1429
|
authTriggerContainer?: string | HTMLElement;
|
|
1373
1430
|
/**
|
|
1374
|
-
* Specify that we want to use the AuthEvent.TRIGGER_SSO_POPUP event to trigger
|
|
1431
|
+
* Specify that we want to use the `AuthEvent.TRIGGER_SSO_POPUP` event to trigger
|
|
1375
1432
|
* SAML popup. This is useful when you want to trigger the popup on a custom user
|
|
1376
1433
|
* action.
|
|
1377
1434
|
*
|
|
@@ -1379,20 +1436,22 @@ export interface EmbedConfig {
|
|
|
1379
1436
|
useEventForSAMLPopup?: boolean;
|
|
1380
1437
|
/**
|
|
1381
1438
|
* Text to show in the button which triggers the popup auth flow.
|
|
1382
|
-
* Default:
|
|
1439
|
+
* Default: `Authorize`.
|
|
1383
1440
|
*
|
|
1384
|
-
* @version SDK: 1.17.0 | ThoughtSpot:
|
|
1441
|
+
* @version SDK: 1.17.0 | ThoughtSpot: 8.9.0.cl, 9.0.1.sw
|
|
1385
1442
|
*/
|
|
1386
1443
|
authTriggerText?: string;
|
|
1387
1444
|
/**
|
|
1388
|
-
*
|
|
1445
|
+
* Prevent users from accessing the full application or ThoughtSpot application pages
|
|
1446
|
+
* access to the embedded application users
|
|
1447
|
+
* outside of the iframe.
|
|
1389
1448
|
*
|
|
1390
1449
|
* @default true
|
|
1391
1450
|
* @version SDK: 1.22.0 | ThoughtSpot: 9.3.0.cl, 9.5.1.sw
|
|
1392
1451
|
*/
|
|
1393
1452
|
blockNonEmbedFullAppAccess?: boolean;
|
|
1394
1453
|
/**
|
|
1395
|
-
* Host config
|
|
1454
|
+
* Host config in case embedded app is inside TS app itself
|
|
1396
1455
|
*
|
|
1397
1456
|
* @hidden
|
|
1398
1457
|
*/
|
|
@@ -1418,17 +1477,17 @@ export interface EmbedConfig {
|
|
|
1418
1477
|
export interface LayoutConfig {
|
|
1419
1478
|
}
|
|
1420
1479
|
/**
|
|
1421
|
-
* Embedded
|
|
1480
|
+
* Embedded iframe configuration
|
|
1422
1481
|
*
|
|
1423
1482
|
* @group Embed components
|
|
1424
1483
|
*/
|
|
1425
1484
|
export interface FrameParams {
|
|
1426
1485
|
/**
|
|
1427
|
-
* The width of the
|
|
1486
|
+
* The width of the iframe (unit is pixels if numeric).
|
|
1428
1487
|
*/
|
|
1429
1488
|
width?: number | string;
|
|
1430
1489
|
/**
|
|
1431
|
-
* The height of the
|
|
1490
|
+
* The height of the iframe (unit is pixels if numeric).
|
|
1432
1491
|
*/
|
|
1433
1492
|
height?: number | string;
|
|
1434
1493
|
/**
|
|
@@ -1529,7 +1588,6 @@ export interface ViewConfig {
|
|
|
1529
1588
|
*/
|
|
1530
1589
|
runtimeParameters?: RuntimeParameter[];
|
|
1531
1590
|
/**
|
|
1532
|
-
/**
|
|
1533
1591
|
* The locale/language to use for the embedded view.
|
|
1534
1592
|
*
|
|
1535
1593
|
* @version SDK: 1.9.4 | ThoughtSpot 8.1.0.cl, 8.4.1.sw
|
|
@@ -1629,31 +1687,29 @@ export interface ViewConfig {
|
|
|
1629
1687
|
*/
|
|
1630
1688
|
reorderedHomepageModules?: HomepageModule[];
|
|
1631
1689
|
/**
|
|
1632
|
-
* The list of tab IDs to show in the embedded.
|
|
1633
|
-
* Only
|
|
1634
|
-
* Use this to show an tabID.
|
|
1690
|
+
* The list of tab IDs to show in the embedded Liveboard.
|
|
1691
|
+
* Only the tabs specified in the array will be shown in the Liveboard.
|
|
1635
1692
|
*
|
|
1636
|
-
* Use either
|
|
1693
|
+
* Use either `visibleTabs` or `hiddenTabs`.
|
|
1637
1694
|
*
|
|
1638
1695
|
* @example
|
|
1639
1696
|
* ```js
|
|
1640
|
-
*
|
|
1641
|
-
* ... // other liveboard view config
|
|
1642
|
-
* visibleTabs: [
|
|
1697
|
+
* visibleTabs: [
|
|
1643
1698
|
* '430496d6-6903-4601-937e-2c691821af3c',
|
|
1644
|
-
*
|
|
1645
|
-
* });
|
|
1699
|
+
* 'f547ec54-2a37-4516-a222-2b06719af726']
|
|
1646
1700
|
* ```
|
|
1647
1701
|
* @version SDK: 1.26.0 | Thoughtspot: 9.7.0.cl
|
|
1648
1702
|
*/
|
|
1649
1703
|
visibleTabs?: string[];
|
|
1650
1704
|
/**
|
|
1651
|
-
* homepageLeftNavItems :
|
|
1652
|
-
* There are 8 home
|
|
1653
|
-
*
|
|
1654
|
-
* eg: hiddenHomeLeftNavItems = [HomeLeftNavItem.Home] to hide home.
|
|
1705
|
+
* homepageLeftNavItems : Show or hide the left navigation bar items.
|
|
1706
|
+
* There are 8 eight home navigation list items.
|
|
1707
|
+
* To hide these items, specify the string in the array.
|
|
1655
1708
|
*
|
|
1656
|
-
*
|
|
1709
|
+
* ```js
|
|
1710
|
+
* hiddenHomeLeftNavItems = [HomeLeftNavItem.Home]
|
|
1711
|
+
* ```
|
|
1712
|
+
* @version SDK: 1.27.0 | Thoughtspot: 9.10.0.cl
|
|
1657
1713
|
*/
|
|
1658
1714
|
hiddenHomeLeftNavItems?: HomeLeftNavItem[];
|
|
1659
1715
|
/**
|
|
@@ -1669,7 +1725,7 @@ export interface ViewConfig {
|
|
|
1669
1725
|
* });
|
|
1670
1726
|
* embed.showPreRender();
|
|
1671
1727
|
* ```
|
|
1672
|
-
* @version SDK: 1.25.0 | Thoughtspot: 9.6.0.cl
|
|
1728
|
+
* @version SDK: 1.25.0 | Thoughtspot: 9.6.0.cl, 9.8.0.sw
|
|
1673
1729
|
*/
|
|
1674
1730
|
preRenderId?: string;
|
|
1675
1731
|
/**
|
|
@@ -1702,7 +1758,7 @@ export type MessagePayload = {
|
|
|
1702
1758
|
status?: string;
|
|
1703
1759
|
};
|
|
1704
1760
|
/**
|
|
1705
|
-
* MessageOptions: By
|
|
1761
|
+
* MessageOptions: By providing options, getting specific event start / end based on
|
|
1706
1762
|
* option
|
|
1707
1763
|
*
|
|
1708
1764
|
* @group Events
|
|
@@ -1710,7 +1766,7 @@ export type MessagePayload = {
|
|
|
1710
1766
|
export type MessageOptions = {
|
|
1711
1767
|
/**
|
|
1712
1768
|
* A boolean value indicating that start status events of this type
|
|
1713
|
-
* will be dispatched
|
|
1769
|
+
* will be dispatched.
|
|
1714
1770
|
*/
|
|
1715
1771
|
start?: boolean;
|
|
1716
1772
|
};
|
|
@@ -1730,7 +1786,7 @@ responder?: (data: any) => void) => void;
|
|
|
1730
1786
|
*/
|
|
1731
1787
|
export type MessageCallbackObj = {
|
|
1732
1788
|
/**
|
|
1733
|
-
* options: It contains start,
|
|
1789
|
+
* options: It contains start, a boolean value indicating that start
|
|
1734
1790
|
* status events of this type will be dispatched
|
|
1735
1791
|
*/
|
|
1736
1792
|
options: MessageOptions;
|
|
@@ -1802,7 +1858,7 @@ export enum RuntimeFilterOp {
|
|
|
1802
1858
|
IN = "IN"
|
|
1803
1859
|
}
|
|
1804
1860
|
/**
|
|
1805
|
-
* Home page module that can be
|
|
1861
|
+
* Home page module that can be hidden
|
|
1806
1862
|
*/
|
|
1807
1863
|
export enum HomepageModule {
|
|
1808
1864
|
/**
|
|
@@ -1818,7 +1874,7 @@ export enum HomepageModule {
|
|
|
1818
1874
|
*/
|
|
1819
1875
|
Favorite = "FAVORITE",
|
|
1820
1876
|
/**
|
|
1821
|
-
* List of answers and
|
|
1877
|
+
* List of answers and Liveboards
|
|
1822
1878
|
*/
|
|
1823
1879
|
MyLibrary = "MY_LIBRARY",
|
|
1824
1880
|
/**
|
|
@@ -1851,7 +1907,7 @@ export interface RuntimeFilter {
|
|
|
1851
1907
|
values: (number | boolean | string)[];
|
|
1852
1908
|
}
|
|
1853
1909
|
/**
|
|
1854
|
-
* A filter that can be applied to ThoughtSpot
|
|
1910
|
+
* A filter that can be applied to ThoughtSpot Answers, Liveboards, or
|
|
1855
1911
|
* visualizations at runtime.
|
|
1856
1912
|
*/
|
|
1857
1913
|
export interface RuntimeParameter {
|
|
@@ -1887,6 +1943,14 @@ export interface RuntimeParameter {
|
|
|
1887
1943
|
export enum EmbedEvent {
|
|
1888
1944
|
/**
|
|
1889
1945
|
* Rendering has initialized.
|
|
1946
|
+
* @example
|
|
1947
|
+
*```js
|
|
1948
|
+
* liveboardEmbed.on(EmbedEvent.Init, showLoader)
|
|
1949
|
+
* //show a loader
|
|
1950
|
+
* function showLoader() {
|
|
1951
|
+
* document.getElementById("loader");
|
|
1952
|
+
* }
|
|
1953
|
+
*```
|
|
1890
1954
|
*
|
|
1891
1955
|
* @returns timestamp - The timestamp when the event was generated.
|
|
1892
1956
|
*/
|
|
@@ -1894,69 +1958,162 @@ export enum EmbedEvent {
|
|
|
1894
1958
|
/**
|
|
1895
1959
|
* Authentication has either succeeded or failed.
|
|
1896
1960
|
*
|
|
1961
|
+
* @example
|
|
1962
|
+
*```js
|
|
1963
|
+
* appEmbed.on(EmbedEvent.AuthInit, payload => {
|
|
1964
|
+
* console.log('AuthInit', payload);
|
|
1965
|
+
* })
|
|
1966
|
+
*```
|
|
1967
|
+
*
|
|
1897
1968
|
* @returns isLoggedIn - A Boolean specifying whether authentication was successful.
|
|
1898
1969
|
*/
|
|
1899
1970
|
AuthInit = "authInit",
|
|
1900
1971
|
/**
|
|
1901
1972
|
* The embed object container has loaded.
|
|
1902
|
-
*
|
|
1903
1973
|
* @returns timestamp - The timestamp when the event was generated.
|
|
1974
|
+
* @example
|
|
1975
|
+
*```js
|
|
1976
|
+
* liveboardEmbed.on(EmbedEvent.Load, hideLoader)
|
|
1977
|
+
* //hide loader
|
|
1978
|
+
* function hideLoader() {
|
|
1979
|
+
* document.getElementById("loader");
|
|
1980
|
+
* }
|
|
1981
|
+
*```
|
|
1904
1982
|
*/
|
|
1905
1983
|
Load = "load",
|
|
1906
1984
|
/**
|
|
1907
1985
|
* Data pertaining to answer or Liveboard is received
|
|
1908
|
-
*
|
|
1909
1986
|
* @return data - The answer or Liveboard data
|
|
1987
|
+
* @example
|
|
1988
|
+
*```js
|
|
1989
|
+
* liveboardEmbed.on(EmbedEvent.Data, payload => {
|
|
1990
|
+
* console.log('data', payload);
|
|
1991
|
+
* })
|
|
1992
|
+
*```
|
|
1910
1993
|
* @important
|
|
1911
1994
|
*/
|
|
1912
1995
|
Data = "data",
|
|
1913
1996
|
/**
|
|
1914
|
-
* Search/
|
|
1997
|
+
* Search/Answer/Liveboard filters have been applied/updated by the user.
|
|
1915
1998
|
*
|
|
1916
1999
|
* @hidden
|
|
1917
2000
|
*/
|
|
1918
2001
|
FiltersChanged = "filtersChanged",
|
|
1919
2002
|
/**
|
|
1920
2003
|
* Search query has been updated by the user.
|
|
2004
|
+
*
|
|
2005
|
+
* @example
|
|
2006
|
+
*```js
|
|
2007
|
+
* searchEmbed.on(EmbedEvent.QueryChanged, payload => console.log('data', payload))
|
|
2008
|
+
*```
|
|
2009
|
+
*
|
|
1921
2010
|
*/
|
|
1922
2011
|
QueryChanged = "queryChanged",
|
|
1923
2012
|
/**
|
|
1924
|
-
* A drill
|
|
2013
|
+
* A drill-down operation has been performed.
|
|
1925
2014
|
*
|
|
1926
2015
|
* @returns additionalFilters - Any additional filters applied
|
|
1927
2016
|
* @returns drillDownColumns - The columns on which drill down was performed
|
|
1928
2017
|
* @returns nonFilteredColumns - The columns that were not filtered
|
|
2018
|
+
*
|
|
2019
|
+
* @example
|
|
2020
|
+
*```js
|
|
2021
|
+
* searchEmbed.trigger(HostEvent.DrillDown, {
|
|
2022
|
+
* points: {
|
|
2023
|
+
* clickedPoint,
|
|
2024
|
+
* selectedPoints: selectedPoint
|
|
2025
|
+
* },
|
|
2026
|
+
* autoDrillDown: true,
|
|
2027
|
+
* })
|
|
2028
|
+
*```
|
|
2029
|
+
* In this example, `VizPointDoubleClick` event is used for
|
|
2030
|
+
* triggering the `DrillDown` event when an area or specific
|
|
2031
|
+
* data point on a table or chart is double-clicked.
|
|
2032
|
+
*
|
|
2033
|
+
* @example
|
|
2034
|
+
*```js
|
|
2035
|
+
* searchEmbed.on(EmbedEvent.VizPointDoubleClick, (payload) => {
|
|
2036
|
+
* console.log(payload);
|
|
2037
|
+
* const clickedPoint = payload.data.clickedPoint;
|
|
2038
|
+
* const selectedPoint = payload.data.selectedPoints;
|
|
2039
|
+
* console.log('>>> called', clickedPoint);
|
|
2040
|
+
* embed.trigger(HostEvent.DrillDown, {
|
|
2041
|
+
* points: {
|
|
2042
|
+
* clickedPoint,
|
|
2043
|
+
* selectedPoints: selectedPoint
|
|
2044
|
+
* },
|
|
2045
|
+
* autoDrillDown: true,
|
|
2046
|
+
* })
|
|
2047
|
+
* })
|
|
2048
|
+
*```
|
|
2049
|
+
*
|
|
1929
2050
|
*/
|
|
1930
2051
|
Drilldown = "drillDown",
|
|
1931
2052
|
/**
|
|
1932
2053
|
* One or more data sources have been selected.
|
|
1933
|
-
*
|
|
1934
2054
|
* @returns dataSourceIds - the list of data sources
|
|
2055
|
+
*
|
|
2056
|
+
* @example
|
|
2057
|
+
* ```js
|
|
2058
|
+
* searchEmbed.on(EmbedEvent.DataSourceSelected, payload => {
|
|
2059
|
+
* console.log('DataSourceSelected', payload);
|
|
2060
|
+
* })
|
|
2061
|
+
* ```
|
|
2062
|
+
*
|
|
1935
2063
|
*/
|
|
1936
2064
|
DataSourceSelected = "dataSourceSelected",
|
|
1937
2065
|
/**
|
|
1938
2066
|
* One or more data columns have been selected.
|
|
1939
|
-
*
|
|
1940
2067
|
* @returns columnIds - the list of columns
|
|
1941
2068
|
* @version SDK: 1.10.0 | ThoughtSpot: 8.2.0.cl, 8.4.1.sw
|
|
2069
|
+
*
|
|
2070
|
+
* @example
|
|
2071
|
+
* ```js
|
|
2072
|
+
* appEmbed.on(EmbedEvent.AddRemoveColumns, payload => {
|
|
2073
|
+
* console.log('AddRemoveColumns', payload);
|
|
2074
|
+
* })
|
|
2075
|
+
* ```
|
|
2076
|
+
*
|
|
1942
2077
|
*/
|
|
1943
2078
|
AddRemoveColumns = "addRemoveColumns",
|
|
1944
2079
|
/**
|
|
1945
|
-
* A custom action has been triggered
|
|
2080
|
+
* A custom action has been triggered.
|
|
1946
2081
|
*
|
|
1947
|
-
* @returns actionId -
|
|
1948
|
-
* @returns data -
|
|
2082
|
+
* @returns actionId - ID of the custom action
|
|
2083
|
+
* @returns data - Response payload with the Answer or Liveboard data
|
|
2084
|
+
*
|
|
2085
|
+
* @example
|
|
2086
|
+
* ```js
|
|
2087
|
+
* appEmbed.on(EmbedEvent.customAction, payload => {
|
|
2088
|
+
* const data = payload.data;
|
|
2089
|
+
* if (data.id === 'insert Custom Action ID here') {
|
|
2090
|
+
* console.log('Custom Action event:', data.embedAnswerData);
|
|
2091
|
+
* }
|
|
2092
|
+
* })
|
|
2093
|
+
* ```
|
|
1949
2094
|
*/
|
|
1950
2095
|
CustomAction = "customAction",
|
|
1951
2096
|
/**
|
|
1952
|
-
* Listen to double
|
|
2097
|
+
* Listen to double click actions on a visualization.
|
|
2098
|
+
*
|
|
2099
|
+
* @return ContextMenuInputPoints - Data point that is double-clicked
|
|
1953
2100
|
*
|
|
1954
|
-
* @return ContextMenuInputPoints - data point that is double clicked
|
|
1955
2101
|
* @version SDK: 1.5.0 | ThoughtSpot: ts7.oct.cl, 7.2.1
|
|
2102
|
+
*
|
|
2103
|
+
* @example
|
|
2104
|
+
* ```js
|
|
2105
|
+
* livebaordEmbed.on(EmbedEvent.VizPointDoubleClick, payload => {
|
|
2106
|
+
* console.log('VizPointDoubleClick', payload)
|
|
2107
|
+
* })
|
|
2108
|
+
* ```
|
|
1956
2109
|
*/
|
|
1957
2110
|
VizPointDoubleClick = "vizPointDoubleClick",
|
|
1958
2111
|
/**
|
|
1959
|
-
* Listen to clicks on a visualization in a
|
|
2112
|
+
* Listen to clicks on a visualization in a Liveboard or Search result.
|
|
2113
|
+
*
|
|
2114
|
+
* @return viz, clickedPoint - metadata about the point that is clicked
|
|
2115
|
+
* @version SDK: 1.11.0 | ThoughtSpot: 8.3.0.cl, 8.4.1.sw
|
|
2116
|
+
* @important
|
|
1960
2117
|
*
|
|
1961
2118
|
* @example
|
|
1962
2119
|
* ```js
|
|
@@ -1970,25 +2127,46 @@ export enum EmbedEvent {
|
|
|
1970
2127
|
* )
|
|
1971
2128
|
* });
|
|
1972
2129
|
* ```
|
|
1973
|
-
* @return viz, clickedPoint - metadata about point that is clicked
|
|
1974
|
-
* @version SDK: 1.11.0 | ThoughtSpot: 8.3.0.cl, 8.4.1.sw
|
|
1975
|
-
* @important
|
|
1976
2130
|
*/
|
|
1977
2131
|
VizPointClick = "vizPointClick",
|
|
1978
2132
|
/**
|
|
1979
2133
|
* An error has occurred.
|
|
1980
2134
|
*
|
|
1981
2135
|
* @returns error - An error object or message
|
|
2136
|
+
*
|
|
2137
|
+
* @example
|
|
2138
|
+
* ```js
|
|
2139
|
+
* SearchEmbed.on(EmbedEvent.Error, showErrorMsg)
|
|
2140
|
+
* //show error messaage
|
|
2141
|
+
* function showErrorMsg() {
|
|
2142
|
+
* document.getElementById("error");
|
|
2143
|
+
* ```
|
|
2144
|
+
*
|
|
1982
2145
|
*/
|
|
1983
2146
|
Error = "Error",
|
|
1984
2147
|
/**
|
|
1985
|
-
* The embedded object has sent an alert
|
|
2148
|
+
* The embedded object has sent an alert.
|
|
1986
2149
|
*
|
|
1987
2150
|
* @returns alert - An alert object
|
|
2151
|
+
*
|
|
2152
|
+
* @example
|
|
2153
|
+
* ```js
|
|
2154
|
+
* searchEmbed.on(EmbedEvent.Alert)
|
|
2155
|
+
* ```
|
|
2156
|
+
*
|
|
1988
2157
|
*/
|
|
1989
2158
|
Alert = "alert",
|
|
1990
2159
|
/**
|
|
1991
2160
|
* The ThoughtSpot auth session has expired.
|
|
2161
|
+
*
|
|
2162
|
+
* @example
|
|
2163
|
+
*```js
|
|
2164
|
+
* appEmbed.on(EmbedEvent.AuthExpire, showAuthExpired)
|
|
2165
|
+
* //show auth expired banner
|
|
2166
|
+
* function showAuthExpired() {
|
|
2167
|
+
* document.getElementById("authExpiredBanner");
|
|
2168
|
+
* }
|
|
2169
|
+
*```
|
|
1992
2170
|
*/
|
|
1993
2171
|
AuthExpire = "ThoughtspotAuthExpired",
|
|
1994
2172
|
/**
|
|
@@ -2018,14 +2196,28 @@ export enum EmbedEvent {
|
|
|
2018
2196
|
*/
|
|
2019
2197
|
EmbedIframeCenter = "EmbedIframeCenter",
|
|
2020
2198
|
/**
|
|
2021
|
-
* Emitted when
|
|
2022
|
-
*
|
|
2199
|
+
* Emitted when the **Get Data** action is initiated.
|
|
2200
|
+
* Applicable to `SearchBarEmbed` only.
|
|
2201
|
+
*
|
|
2202
|
+
* @version SDK: 1.19.0 | ThoughtSpot: 9.0.0.cl, 9.0.1.sw
|
|
2023
2203
|
*
|
|
2024
|
-
* @
|
|
2204
|
+
* @example
|
|
2205
|
+
*```js
|
|
2206
|
+
* searchbarEmbed.on(EmbedEvent.GetDataClick)
|
|
2207
|
+
* .then(data => {
|
|
2208
|
+
* console.log('Answer Data:', data);
|
|
2209
|
+
* })
|
|
2210
|
+
*```
|
|
2025
2211
|
*/
|
|
2026
2212
|
GetDataClick = "getDataClick",
|
|
2027
2213
|
/**
|
|
2028
2214
|
* Detects the route change.
|
|
2215
|
+
*
|
|
2216
|
+
* @example
|
|
2217
|
+
*```js
|
|
2218
|
+
* searchEmbed.on(EmbedEvent.RouteChange, payload =>
|
|
2219
|
+
* console.log('data', payload))
|
|
2220
|
+
*```
|
|
2029
2221
|
*/
|
|
2030
2222
|
RouteChange = "ROUTE_CHANGE",
|
|
2031
2223
|
/**
|
|
@@ -2035,10 +2227,15 @@ export enum EmbedEvent {
|
|
|
2035
2227
|
*/
|
|
2036
2228
|
V1Data = "exportVizDataToParent",
|
|
2037
2229
|
/**
|
|
2038
|
-
* Emitted when the embed does not have cookie access. This
|
|
2039
|
-
*
|
|
2230
|
+
* Emitted when the embed does not have cookie access. This happens
|
|
2231
|
+
* when Safari and other Web browsers block third-party cookies
|
|
2232
|
+
* are blocked by default. `NoCookieAccess` can trigger
|
|
2040
2233
|
*
|
|
2041
|
-
* @
|
|
2234
|
+
* @example
|
|
2235
|
+
*```js
|
|
2236
|
+
* appEmbed.on(EmbedEvent.NoCookieAccess)
|
|
2237
|
+
*```
|
|
2238
|
+
* @version SDK: 1.1.0 | ThoughtSpot: ts7.may.cl, 7.2.1.sw
|
|
2042
2239
|
*/
|
|
2043
2240
|
NoCookieAccess = "noCookieAccess",
|
|
2044
2241
|
/**
|
|
@@ -2050,239 +2247,539 @@ export enum EmbedEvent {
|
|
|
2050
2247
|
SAMLComplete = "samlComplete",
|
|
2051
2248
|
/**
|
|
2052
2249
|
* Emitted when any modal is opened in the app
|
|
2053
|
-
*
|
|
2054
2250
|
* @version SDK: 1.6.0 | ThoughtSpot: ts8.nov.cl, 8.4.1.sw
|
|
2251
|
+
*
|
|
2252
|
+
* @example
|
|
2253
|
+
*```js
|
|
2254
|
+
* appEmbed.on(EmbedEvent.DialogOpen, payload => {
|
|
2255
|
+
* console.log('dialog open', payload);
|
|
2256
|
+
* })
|
|
2257
|
+
*```
|
|
2055
2258
|
*/
|
|
2056
2259
|
DialogOpen = "dialog-open",
|
|
2057
2260
|
/**
|
|
2058
2261
|
* Emitted when any modal is closed in the app
|
|
2059
|
-
*
|
|
2060
2262
|
* @version SDK: 1.6.0 | ThoughtSpot: ts8.nov.cl, 8.4.1.sw
|
|
2263
|
+
*
|
|
2264
|
+
* @example
|
|
2265
|
+
*```js
|
|
2266
|
+
* appEmbed.on(EmbedEvent.DialogClose, payload => {
|
|
2267
|
+
* console.log('dialog close', payload);
|
|
2268
|
+
* })
|
|
2269
|
+
*```
|
|
2061
2270
|
*/
|
|
2062
2271
|
DialogClose = "dialog-close",
|
|
2063
2272
|
/**
|
|
2064
2273
|
* Emitted when the Liveboard shell loads.
|
|
2065
2274
|
* You can use this event as a hook to trigger
|
|
2066
2275
|
* other events on the rendered Liveboard.
|
|
2067
|
-
*
|
|
2068
2276
|
* @version SDK: 1.9.1 | ThoughtSpot: 8.1.0.cl, 8.4.1.sw
|
|
2277
|
+
*
|
|
2278
|
+
* @example
|
|
2279
|
+
*```js
|
|
2280
|
+
* liveboardEmbed.on(EmbedEvent.LiveboardRendered, payload => {
|
|
2281
|
+
console.log('Liveboard is rendered', payload);
|
|
2282
|
+
})
|
|
2283
|
+
*```
|
|
2284
|
+
* The following example shows how to trigger
|
|
2285
|
+
* `SetVisibleVizs` event using LiveboardRendered embed event:
|
|
2286
|
+
*
|
|
2287
|
+
* @example
|
|
2288
|
+
*```js
|
|
2289
|
+
* const embedRef = useEmbedRef();
|
|
2290
|
+
* const onLiveboardRendered = () => {
|
|
2291
|
+
* embed.trigger(HostEvent.SetVisibleVizs, ['viz1', 'viz2']);
|
|
2292
|
+
* };
|
|
2293
|
+
*```
|
|
2069
2294
|
*/
|
|
2070
2295
|
LiveboardRendered = "PinboardRendered",
|
|
2071
2296
|
/**
|
|
2072
2297
|
* This can be used to register an event listener which
|
|
2073
2298
|
* is triggered on all events.
|
|
2074
|
-
*
|
|
2075
2299
|
* @Version SDK: 1.10.0 | ThoughtSpot: 8.2.0.cl, 8.4.1.sw
|
|
2300
|
+
*
|
|
2301
|
+
* @example
|
|
2302
|
+
*```js
|
|
2303
|
+
* appEmbed.on(EmbedEvent.ALL, payload => {
|
|
2304
|
+
* console.log('Embed Events', payload)
|
|
2305
|
+
* })
|
|
2306
|
+
*```
|
|
2076
2307
|
*/
|
|
2077
2308
|
ALL = "*",
|
|
2078
2309
|
/**
|
|
2079
2310
|
* Emitted when an Answer is saved in the app
|
|
2080
|
-
*
|
|
2081
2311
|
* @Version SDK: 1.11.0 | ThoughtSpot: 8.3.0.cl, 8.4.1.sw
|
|
2312
|
+
* @example
|
|
2313
|
+
*```js
|
|
2314
|
+
* //trigger when action starts
|
|
2315
|
+
* searchEmbed.on(EmbedEvent.Save, payload => {
|
|
2316
|
+
* console.log('Save', payload)
|
|
2317
|
+
* }, {
|
|
2318
|
+
* start: true
|
|
2319
|
+
* })
|
|
2320
|
+
* //trigger when action ends
|
|
2321
|
+
* searchEmbed.on(EmbedEvent.Save, payload => {
|
|
2322
|
+
* console.log('Save', payload)
|
|
2323
|
+
* })
|
|
2324
|
+
*```
|
|
2082
2325
|
*/
|
|
2083
2326
|
Save = "save",
|
|
2084
2327
|
/**
|
|
2085
2328
|
* Emitted when the download action is triggered on an answer
|
|
2086
2329
|
*
|
|
2330
|
+
* **Note**: This event is deprecated in v1.21.0.
|
|
2331
|
+
* To fire an event when a download action is initiated on a chart or table,
|
|
2332
|
+
* use `EmbedEvent.DownloadAsPng`, `EmbedEvent.DownloadAsPDF`, `EmbedEvent.DownloadAsCSV`,
|
|
2333
|
+
* or `EmbedEvent.DownloadAsXLSX`
|
|
2334
|
+
*
|
|
2087
2335
|
* @version SDK: 1.11.0 | ThoughtSpot: 8.3.0.cl, 8.4.1.sw
|
|
2336
|
+
*
|
|
2337
|
+
* @example
|
|
2338
|
+
*```js
|
|
2339
|
+
* liveboardEmbed.trigger(HostEvent.Download, {
|
|
2340
|
+
* vizId: '730496d6-6903-4601-937e-2c691821af3c'
|
|
2341
|
+
* })
|
|
2342
|
+
*```
|
|
2088
2343
|
*/
|
|
2089
2344
|
Download = "download",
|
|
2090
2345
|
/**
|
|
2091
2346
|
* Emitted when the download action is triggered on an answer
|
|
2092
|
-
*
|
|
2093
2347
|
* @version SDK: 1.21.0 | ThoughtSpot: 9.2.0.cl, 9.4.0.sw
|
|
2348
|
+
*
|
|
2349
|
+
* @example
|
|
2350
|
+
*```js
|
|
2351
|
+
* //trigger when action starts
|
|
2352
|
+
* searchEmbed.on(EmbedEvent.DownloadAsPng, payload => {
|
|
2353
|
+
* console.log('download PNG', payload)}, {start: true })
|
|
2354
|
+
* //trigger when action ends
|
|
2355
|
+
* searchEmbed.on(EmbedEvent.DownloadAsPng, payload => {
|
|
2356
|
+
* console.log('download PNG', payload)})
|
|
2357
|
+
*```
|
|
2358
|
+
*
|
|
2094
2359
|
*/
|
|
2095
2360
|
DownloadAsPng = "downloadAsPng",
|
|
2096
2361
|
/**
|
|
2097
2362
|
* Emitted when the Download as PDF action is triggered on an answer
|
|
2098
2363
|
*
|
|
2099
2364
|
* @version SDK: 1.11.0 | ThoughtSpot: 8.3.0.cl, 8.4.1.sw
|
|
2365
|
+
*
|
|
2366
|
+
* @example
|
|
2367
|
+
*```js
|
|
2368
|
+
* //trigger when action starts
|
|
2369
|
+
* searchEmbed.on(EmbedEvent.DownloadAsPdf, payload => {
|
|
2370
|
+
* console.log('download PDF', payload)}, {start: true })
|
|
2371
|
+
* //trigger when action ends
|
|
2372
|
+
* searchEmbed.on(EmbedEvent.DownloadAsPdf, payload => {
|
|
2373
|
+
* console.log('download PDF', payload)})
|
|
2374
|
+
*```
|
|
2375
|
+
*
|
|
2100
2376
|
*/
|
|
2101
2377
|
DownloadAsPdf = "downloadAsPdf",
|
|
2102
2378
|
/**
|
|
2103
2379
|
* Emitted when the Download as CSV action is triggered on an answer
|
|
2104
2380
|
*
|
|
2105
2381
|
* @version SDK: 1.11.0 | ThoughtSpot: 8.3.0.cl, 8.4.1.sw
|
|
2382
|
+
* @example
|
|
2383
|
+
*```js
|
|
2384
|
+
* //trigger when action starts
|
|
2385
|
+
* searchEmbed.on(EmbedEvent.DownloadAsCSV, payload => {
|
|
2386
|
+
* console.log('download CSV', payload)}, {start: true })
|
|
2387
|
+
* //trigger when action ends
|
|
2388
|
+
* searchEmbed.on(EmbedEvent.DownloadAsCSV, payload => {
|
|
2389
|
+
* console.log('download CSV', payload)})
|
|
2390
|
+
*```
|
|
2106
2391
|
*/
|
|
2107
2392
|
DownloadAsCsv = "downloadAsCsv",
|
|
2108
2393
|
/**
|
|
2109
2394
|
* Emitted when the Download as XLSX action is triggered on an answer
|
|
2110
2395
|
*
|
|
2111
2396
|
* @version SDK: 1.11.0 | ThoughtSpot: 8.3.0.cl, 8.4.1.sw
|
|
2397
|
+
*
|
|
2398
|
+
* @example
|
|
2399
|
+
*```js
|
|
2400
|
+
* //trigger when action starts
|
|
2401
|
+
* searchEmbed.on(EmbedEvent.DownloadAsXlsx, payload => {
|
|
2402
|
+
* console.log('download Xlsx', payload)}, { start: true })
|
|
2403
|
+
* //trigger when action ends
|
|
2404
|
+
* searchEmbed.on(EmbedEvent.DownloadAsXlsx, payload => {
|
|
2405
|
+
* console.log('download Xlsx', payload)})
|
|
2406
|
+
*```
|
|
2112
2407
|
*/
|
|
2113
2408
|
DownloadAsXlsx = "downloadAsXlsx",
|
|
2114
2409
|
/**
|
|
2115
|
-
* Emitted when an
|
|
2410
|
+
* Emitted when an Answer is deleted in the app
|
|
2116
2411
|
*
|
|
2117
2412
|
* @version SDK: 1.11.0 | ThoughtSpot: 8.3.0.cl, 8.4.1.sw
|
|
2413
|
+
*
|
|
2414
|
+
* @example
|
|
2415
|
+
*```js
|
|
2416
|
+
* //trigger when action starts
|
|
2417
|
+
* appEmbed.on(EmbedEvent.AnswerDelete, payload => {
|
|
2418
|
+
* console.log('delete answer', payload)}, {start: true })
|
|
2419
|
+
* //trigger when action is completed
|
|
2420
|
+
* appEmbed.on(EmbedEvent.AnswerDelete, payload => {
|
|
2421
|
+
* console.log('delete answer', payload)})
|
|
2422
|
+
*```
|
|
2118
2423
|
*/
|
|
2119
2424
|
AnswerDelete = "answerDelete",
|
|
2120
2425
|
/**
|
|
2121
2426
|
* Emitted when an answer is pinned to a Liveboard
|
|
2122
2427
|
*
|
|
2123
2428
|
* @version SDK: 1.11.0 | ThoughtSpot: 8.3.0.cl, 8.4.1.sw
|
|
2429
|
+
* @example
|
|
2430
|
+
*```js
|
|
2431
|
+
* //trigger when action starts
|
|
2432
|
+
* searchEmbed.on(EmbedEvent.Pin, payload => {
|
|
2433
|
+
* console.log('pin', payload)
|
|
2434
|
+
* }, {
|
|
2435
|
+
* start: true
|
|
2436
|
+
* })
|
|
2437
|
+
* //trigger when action ends
|
|
2438
|
+
* searchEmbed.on(EmbedEvent.Pin, payload => {
|
|
2439
|
+
* console.log('pin', payload)
|
|
2440
|
+
* })
|
|
2441
|
+
*```
|
|
2124
2442
|
*/
|
|
2125
2443
|
Pin = "pin",
|
|
2126
2444
|
/**
|
|
2127
2445
|
* Emitted when SpotIQ analysis is triggered
|
|
2128
2446
|
*
|
|
2129
2447
|
* @version SDK: 1.11.0 | ThoughtSpot: 8.3.0.cl, 8.4.1.sw
|
|
2448
|
+
* @example
|
|
2449
|
+
*```js
|
|
2450
|
+
* //trigger when action starts
|
|
2451
|
+
* searchEmbed.on(EmbedEvent.SpotIQAnalyze, payload => {
|
|
2452
|
+
* console.log('SpotIQAnalyze', payload)
|
|
2453
|
+
* }, {
|
|
2454
|
+
* start: true
|
|
2455
|
+
* })
|
|
2456
|
+
* //trigger when action ends
|
|
2457
|
+
* searchEmbed.on(EmbedEvent.SpotIQAnalyze, payload => {
|
|
2458
|
+
* console.log('SpotIQ analyze', payload)
|
|
2459
|
+
* })
|
|
2460
|
+
*```
|
|
2130
2461
|
*/
|
|
2131
2462
|
SpotIQAnalyze = "spotIQAnalyze",
|
|
2132
2463
|
/**
|
|
2133
2464
|
* Emitted when a user shares an object with another user or group
|
|
2134
2465
|
*
|
|
2135
2466
|
* @version SDK: 1.11.0 | ThoughtSpot: 8.3.0.cl, 8.4.1.sw
|
|
2467
|
+
*
|
|
2468
|
+
* @example
|
|
2469
|
+
*```js
|
|
2470
|
+
* //trigger when action starts
|
|
2471
|
+
* searchEmbed.on(EmbedEvent.Share, payload => {
|
|
2472
|
+
* console.log('Share', payload)
|
|
2473
|
+
* }, {
|
|
2474
|
+
* start: true
|
|
2475
|
+
* })
|
|
2476
|
+
* //trigger when action ends
|
|
2477
|
+
* searchEmbed.on(EmbedEvent.Share, payload => {
|
|
2478
|
+
* console.log('Share', payload)
|
|
2479
|
+
* })
|
|
2480
|
+
*```
|
|
2136
2481
|
*/
|
|
2137
2482
|
Share = "share",
|
|
2138
2483
|
/**
|
|
2139
|
-
* Emitted when a user clicks the Include action to include a specific value or
|
|
2140
|
-
* on a chart or table
|
|
2484
|
+
* Emitted when a user clicks the **Include** action to include a specific value or
|
|
2485
|
+
* data on a chart or table.
|
|
2141
2486
|
*
|
|
2142
2487
|
* @version SDK: 1.11.0 | ThoughtSpot: 8.3.0.cl, 8.4.1.sw
|
|
2488
|
+
* @example
|
|
2489
|
+
*```js
|
|
2490
|
+
* appEmbed.on(EmbedEvent.DrillInclude, payload => {
|
|
2491
|
+
* console.log('Drill include', payload);
|
|
2492
|
+
* })
|
|
2493
|
+
*```
|
|
2143
2494
|
*/
|
|
2144
2495
|
DrillInclude = "context-menu-item-include",
|
|
2145
2496
|
/**
|
|
2146
|
-
* Emitted when a user clicks the Exclude action to exclude a specific value or
|
|
2147
|
-
* on a chart or table
|
|
2497
|
+
* Emitted when a user clicks the **Exclude** action to exclude a specific value or
|
|
2498
|
+
* data on a chart or table
|
|
2148
2499
|
*
|
|
2149
2500
|
* @version SDK: 1.11.0 | ThoughtSpot: 8.3.0.cl, 8.4.1.sw
|
|
2501
|
+
* @example
|
|
2502
|
+
*```js
|
|
2503
|
+
* appEmbed.on(EmbedEvent.DrillExclude, payload => {
|
|
2504
|
+
* console.log('Drill exclude', payload);
|
|
2505
|
+
* })
|
|
2506
|
+
*```
|
|
2150
2507
|
*/
|
|
2151
2508
|
DrillExclude = "context-menu-item-exclude",
|
|
2152
2509
|
/**
|
|
2153
|
-
* Emitted when
|
|
2510
|
+
* Emitted when a column value is copied in the embedded app.
|
|
2154
2511
|
*
|
|
2155
2512
|
* @version SDK: 1.11.0 | ThoughtSpot: 8.3.0.cl, 8.4.1.sw
|
|
2513
|
+
* @example
|
|
2514
|
+
*```js
|
|
2515
|
+
* seachEmbed.on(EmbedEvent.CopyToClipboard, payload => {
|
|
2516
|
+
* console.log('copy to clipboard', payload);
|
|
2517
|
+
* })
|
|
2518
|
+
*```
|
|
2156
2519
|
*/
|
|
2157
2520
|
CopyToClipboard = "context-menu-item-copy-to-clipboard",
|
|
2158
2521
|
/**
|
|
2159
|
-
* Emitted when a user clicks the Update TML action
|
|
2522
|
+
* Emitted when a user clicks the **Update TML** action
|
|
2160
2523
|
*
|
|
2161
2524
|
* @version SDK: 1.11.0 | ThoughtSpot: 8.3.0.cl, 8.4.1.sw
|
|
2525
|
+
* @example
|
|
2526
|
+
*```js
|
|
2527
|
+
* liveboardEmbed.on(EmbedEvent.UpdateTML)
|
|
2528
|
+
* })
|
|
2529
|
+
*```
|
|
2162
2530
|
*/
|
|
2163
2531
|
UpdateTML = "updateTSL",
|
|
2164
2532
|
/**
|
|
2165
|
-
* Emitted when a user clicks the Edit TML action
|
|
2533
|
+
* Emitted when a user clicks the **Edit TML** action
|
|
2166
2534
|
*
|
|
2167
2535
|
* @version SDK: 1.11.0 | ThoughtSpot: 8.3.0.cl, 8.4.1.sw
|
|
2536
|
+
* @example
|
|
2537
|
+
*```js
|
|
2538
|
+
* appEmbed.on(EmbedEvent.EditTML, payload => {
|
|
2539
|
+
* console.log('Edit TML', payload);
|
|
2540
|
+
* })
|
|
2541
|
+
*```
|
|
2168
2542
|
*/
|
|
2169
2543
|
EditTML = "editTSL",
|
|
2170
2544
|
/**
|
|
2171
|
-
* Emitted when
|
|
2172
|
-
*
|
|
2545
|
+
* Emitted when the **Export TML** action is triggered on an
|
|
2546
|
+
* an embedded object in the app
|
|
2173
2547
|
* @version SDK: 1.11.0 | ThoughtSpot: 8.3.0.cl, 8.4.1.sw
|
|
2548
|
+
* @example
|
|
2549
|
+
*```js
|
|
2550
|
+
* //trigger when action starts
|
|
2551
|
+
* searchEmbed.on(EmbedEvent.ExportTML, payload => {
|
|
2552
|
+
* console.log('Export TML', payload)}, { start: true })
|
|
2553
|
+
* //trigger when action ends
|
|
2554
|
+
* searchEmbed.on(EmbedEvent.ExportTML, payload => {
|
|
2555
|
+
* console.log('Export TML', payload)})
|
|
2556
|
+
*```
|
|
2174
2557
|
*/
|
|
2175
2558
|
ExportTML = "exportTSL",
|
|
2176
2559
|
/**
|
|
2177
|
-
* Emitted when an
|
|
2560
|
+
* Emitted when an Answer is saved as a View.
|
|
2178
2561
|
*
|
|
2179
2562
|
* @version SDK: 1.11.0 | ThoughtSpot: 8.3.0.cl, 8.4.1.sw
|
|
2563
|
+
* @example
|
|
2564
|
+
*```js
|
|
2565
|
+
* appEmbed.on(EmbedEvent.SaveAsView, payload => {
|
|
2566
|
+
* console.log('View', payload);
|
|
2567
|
+
* })
|
|
2568
|
+
*```
|
|
2180
2569
|
*/
|
|
2181
2570
|
SaveAsView = "saveAsView",
|
|
2182
2571
|
/**
|
|
2183
|
-
* Emitted when
|
|
2572
|
+
* Emitted when the user creates a copy of an Answer
|
|
2184
2573
|
*
|
|
2185
2574
|
* @version SDK: 1.11.0 | ThoughtSpot: 8.3.0.cl, 8.4.1.sw
|
|
2575
|
+
* @example
|
|
2576
|
+
*```js
|
|
2577
|
+
* //trigger when action starts
|
|
2578
|
+
* appEmbed.on(EmbedEvent.CopyAEdit, payload => {
|
|
2579
|
+
* console.log('Copy and edit', payload)}, {start: true })
|
|
2580
|
+
* //trigger when action ends
|
|
2581
|
+
* appEmbed.on(EmbedEvent.CopyAEdit, payload => {
|
|
2582
|
+
* console.log('Copy and edit', payload)})
|
|
2583
|
+
*```
|
|
2186
2584
|
*/
|
|
2187
2585
|
CopyAEdit = "copyAEdit",
|
|
2188
2586
|
/**
|
|
2189
|
-
* Emitted when a user clicks Show underlying data on an
|
|
2587
|
+
* Emitted when a user clicks Show underlying data on an Answer
|
|
2190
2588
|
*
|
|
2191
2589
|
* @version SDK: 1.11.0 | ThoughtSpot: 8.3.0.cl, 8.4.1.sw
|
|
2590
|
+
* @example
|
|
2591
|
+
*```js
|
|
2592
|
+
* liveboardEmbed.on(EmbedEvent.ShowUnderlyingData, payload => {
|
|
2593
|
+
* console.log('show data', payload);
|
|
2594
|
+
* })
|
|
2595
|
+
*```
|
|
2192
2596
|
*/
|
|
2193
2597
|
ShowUnderlyingData = "showUnderlyingData",
|
|
2194
2598
|
/**
|
|
2195
|
-
* Emitted when an answer is switched to a chart or table view
|
|
2599
|
+
* Emitted when an answer is switched to a chart or table view.
|
|
2196
2600
|
*
|
|
2197
2601
|
* @version SDK: 1.11.0 | ThoughtSpot: 8.3.0.cl, 8.4.1.sw
|
|
2602
|
+
* @example
|
|
2603
|
+
*```js
|
|
2604
|
+
* searchEmbed.on(EmbedEvent.AnswerChartSwitcher, payload => {
|
|
2605
|
+
* console.log('switch view', payload);
|
|
2606
|
+
* })
|
|
2607
|
+
*```
|
|
2198
2608
|
*/
|
|
2199
2609
|
AnswerChartSwitcher = "answerChartSwitcher",
|
|
2200
2610
|
/**
|
|
2201
|
-
* Internal event to communicate the initial settings back to the
|
|
2611
|
+
* Internal event to communicate the initial settings back to the ThoughtSpot app
|
|
2202
2612
|
*
|
|
2203
2613
|
* @hidden
|
|
2204
2614
|
*/
|
|
2205
2615
|
APP_INIT = "appInit",
|
|
2206
2616
|
/**
|
|
2207
|
-
* Emitted when a user clicks Show Liveboard details on a Liveboard
|
|
2617
|
+
* Emitted when a user clicks **Show Liveboard details** on a Liveboard
|
|
2208
2618
|
*
|
|
2209
2619
|
* @version SDK: 1.15.0 | ThoughtSpot: 8.7.0.cl, 8.8.1.sw
|
|
2620
|
+
* @example
|
|
2621
|
+
*```js
|
|
2622
|
+
* liveboardEmbed.on(EmbedEvent.AnswerChartSwitcher, payload => {
|
|
2623
|
+
* console.log('Liveboard details', payload);
|
|
2624
|
+
* })
|
|
2625
|
+
*```
|
|
2210
2626
|
*/
|
|
2211
2627
|
LiveboardInfo = "pinboardInfo",
|
|
2212
2628
|
/**
|
|
2213
2629
|
* Emitted when a user clicks on the Favorite icon on a Liveboard
|
|
2214
2630
|
*
|
|
2215
2631
|
* @version SDK: 1.15.0 | ThoughtSpot: 8.7.0.cl, 8.8.1.sw
|
|
2632
|
+
* @example
|
|
2633
|
+
*```js
|
|
2634
|
+
* liveboardEmbed.on(EmbedEvent.AddToFavorites, payload => {
|
|
2635
|
+
* console.log('favorites', payload);
|
|
2636
|
+
* })
|
|
2637
|
+
*```
|
|
2216
2638
|
*/
|
|
2217
2639
|
AddToFavorites = "addToFavorites",
|
|
2218
2640
|
/**
|
|
2219
|
-
* Emitted when a user clicks Schedule on a Liveboard
|
|
2641
|
+
* Emitted when a user clicks **Schedule** on a Liveboard
|
|
2220
2642
|
*
|
|
2221
2643
|
* @version SDK: 1.15.0 | ThoughtSpot: 8.7.0.cl, 8.8.1.sw
|
|
2644
|
+
* @example
|
|
2645
|
+
*```js
|
|
2646
|
+
* liveboardEmbed.on(EmbedEvent.Schedule, payload => {
|
|
2647
|
+
* console.log(`Liveboard schedule', payload);
|
|
2648
|
+
* })
|
|
2649
|
+
*```
|
|
2222
2650
|
*/
|
|
2223
2651
|
Schedule = "subscription",
|
|
2224
2652
|
/**
|
|
2225
|
-
* Emitted when a user clicks Edit on a Liveboard or visualization
|
|
2653
|
+
* Emitted when a user clicks **Edit** on a Liveboard or visualization
|
|
2226
2654
|
*
|
|
2227
2655
|
* @version SDK: 1.15.0 | ThoughtSpot: 8.7.0.cl, 8.8.1.sw
|
|
2656
|
+
* @example
|
|
2657
|
+
*```js
|
|
2658
|
+
* liveboardEmbed.on(EmbedEvent.Edit, payload => {
|
|
2659
|
+
* console.log(`Liveboard edit', payload);
|
|
2660
|
+
* })
|
|
2661
|
+
*```
|
|
2228
2662
|
*/
|
|
2229
2663
|
Edit = "edit",
|
|
2230
2664
|
/**
|
|
2231
|
-
* Emitted when a user clicks Make a copy on a Liveboard
|
|
2665
|
+
* Emitted when a user clicks *Make a copy* on a Liveboard
|
|
2232
2666
|
*
|
|
2233
2667
|
* @version SDK: 1.15.0 | ThoughtSpot: 8.7.0.cl, 8.8.1.sw
|
|
2668
|
+
* @example
|
|
2669
|
+
*```js
|
|
2670
|
+
* liveboardEmbed.on(EmbedEvent.MakeACopy, payload => {
|
|
2671
|
+
* console.log(`Copy', payload);
|
|
2672
|
+
* })
|
|
2673
|
+
*```
|
|
2234
2674
|
*/
|
|
2235
2675
|
MakeACopy = "makeACopy",
|
|
2236
2676
|
/**
|
|
2237
|
-
* Emitted when a user clicks Present on a Liveboard or visualization
|
|
2677
|
+
* Emitted when a user clicks **Present** on a Liveboard or visualization
|
|
2238
2678
|
*
|
|
2239
2679
|
* @version SDK: 1.15.0 | ThoughtSpot: 8.7.0.cl, 8.8.1.sw
|
|
2680
|
+
* @example
|
|
2681
|
+
*```js
|
|
2682
|
+
* liveboardEmbed.trigger(HostEvent.Present)
|
|
2683
|
+
*```
|
|
2684
|
+
*
|
|
2685
|
+
* @example
|
|
2686
|
+
*```js
|
|
2687
|
+
* liveboardEmbed.on(EmbedEvent.Present, {
|
|
2688
|
+
* vizId: '730496d6-6903-4601-937e-2c691821af3c'})
|
|
2689
|
+
* })
|
|
2690
|
+
*```
|
|
2240
2691
|
*/
|
|
2241
2692
|
Present = "present",
|
|
2242
2693
|
/**
|
|
2243
|
-
* Emitted when a user clicks Delete on a
|
|
2694
|
+
* Emitted when a user clicks **Delete** on a visualization
|
|
2244
2695
|
*
|
|
2245
2696
|
* @version SDK: 1.15.0 | ThoughtSpot: 8.7.0.cl, 8.8.1.sw
|
|
2697
|
+
* @example
|
|
2698
|
+
*```js
|
|
2699
|
+
* liveboardEmbed.trigger(HostEvent.Delete,
|
|
2700
|
+
* {vizId: '730496d6-6903-4601-937e-2c691821af3c'})
|
|
2701
|
+
*```
|
|
2702
|
+
*
|
|
2246
2703
|
*/
|
|
2247
2704
|
Delete = "delete",
|
|
2248
2705
|
/**
|
|
2249
2706
|
* Emitted when a user clicks Manage schedules on a Liveboard
|
|
2250
2707
|
*
|
|
2251
2708
|
* @version SDK: 1.15.0 | ThoughtSpot: 8.7.0.cl, 8.8.1.sw
|
|
2709
|
+
*
|
|
2710
|
+
* @example
|
|
2711
|
+
*```js
|
|
2712
|
+
* liveboardEmbed.trigger(HostEvent.SchedulesList)
|
|
2713
|
+
*```
|
|
2714
|
+
*
|
|
2252
2715
|
*/
|
|
2253
2716
|
SchedulesList = "schedule-list",
|
|
2254
2717
|
/**
|
|
2255
|
-
* Emitted when a user clicks Cancel in edit mode on a Liveboard
|
|
2718
|
+
* Emitted when a user clicks **Cancel** in edit mode on a Liveboard
|
|
2256
2719
|
*
|
|
2257
2720
|
* @version SDK: 1.15.0 | ThoughtSpot: 8.7.0.cl, 8.8.1.sw
|
|
2721
|
+
*
|
|
2722
|
+
* @example
|
|
2723
|
+
*```js
|
|
2724
|
+
* liveboardEmbed.trigger(HostEvent.Cancel)
|
|
2725
|
+
*```
|
|
2726
|
+
*
|
|
2258
2727
|
*/
|
|
2259
2728
|
Cancel = "cancel",
|
|
2260
2729
|
/**
|
|
2261
|
-
* Emitted when a user clicks Explore on a visualization
|
|
2730
|
+
* Emitted when a user clicks **Explore** on a visualization
|
|
2262
2731
|
*
|
|
2263
2732
|
* @version SDK: 1.15.0 | ThoughtSpot: 8.7.0.cl, 8.8.1.sw
|
|
2733
|
+
*
|
|
2734
|
+
* @example
|
|
2735
|
+
*```js
|
|
2736
|
+
* liveboardEmbed.trigger(HostEvent.Explore, {
|
|
2737
|
+
* vizId: '730496d6-6903-4601-937e-2c691821af3c'})
|
|
2738
|
+
*```
|
|
2739
|
+
*
|
|
2264
2740
|
*/
|
|
2265
2741
|
Explore = "explore",
|
|
2266
2742
|
/**
|
|
2267
|
-
* Emitted when a user clicks Copy link action on a visualization
|
|
2743
|
+
* Emitted when a user clicks **Copy link** action on a visualization
|
|
2268
2744
|
*
|
|
2269
2745
|
* @version SDK: 1.15.0 | ThoughtSpot: 8.7.0.cl, 8.8.1.sw
|
|
2746
|
+
*
|
|
2747
|
+
* @example
|
|
2748
|
+
*```js
|
|
2749
|
+
* liveboardEmbed.trigger(HostEvent.CopyLink, {
|
|
2750
|
+
* vizId: '730496d6-6903-4601-937e-2c691821af3c'})
|
|
2751
|
+
*```
|
|
2752
|
+
*
|
|
2270
2753
|
*/
|
|
2271
2754
|
CopyLink = "embedDocument",
|
|
2272
2755
|
/**
|
|
2273
|
-
* Emitted when a user interacts with cross filters on a visualization or
|
|
2756
|
+
* Emitted when a user interacts with cross filters on a visualization or Liveboard
|
|
2757
|
+
*
|
|
2758
|
+
* @version SDK: 1.21.0 | ThoughtSpot: 9.2.0.cl, 9.5.0.sw
|
|
2759
|
+
*
|
|
2760
|
+
* @example
|
|
2761
|
+
*```js
|
|
2762
|
+
* liveboardEmbed.trigger(HostEvent.CrossFilterChanged, {
|
|
2763
|
+
* vizId: '730496d6-6903-4601-937e-2c691821af3c'})
|
|
2764
|
+
*```
|
|
2274
2765
|
*
|
|
2275
|
-
* @version SDK: 1.21.0 | ThoughtSpot: 9.2.0.cl
|
|
2276
2766
|
*/
|
|
2277
2767
|
CrossFilterChanged = "cross-filter-changed",
|
|
2278
2768
|
/**
|
|
2279
2769
|
* Emitted when a user right clicks on a visualization (chart or table)
|
|
2280
2770
|
*
|
|
2281
|
-
* @version SDK: 1.21.0 | ThoughtSpot: 9.2.0.cl
|
|
2771
|
+
* @version SDK: 1.21.0 | ThoughtSpot: 9.2.0.cl, 9.5.0.sw
|
|
2772
|
+
*
|
|
2773
|
+
* @example
|
|
2774
|
+
*```js
|
|
2775
|
+
* LiveboardEmbed.on(EmbedEvent.VizPointRightClick, payload => {
|
|
2776
|
+
* console.log('VizPointClick', payload)
|
|
2777
|
+
* })
|
|
2778
|
+
*```
|
|
2282
2779
|
*/
|
|
2283
2780
|
VizPointRightClick = "vizPointRightClick",
|
|
2284
2781
|
/**
|
|
2285
|
-
* Emitted when a user clicks
|
|
2782
|
+
* Emitted when a user clicks **Insert to slide** on a visualization
|
|
2286
2783
|
*
|
|
2287
2784
|
* @hidden
|
|
2288
2785
|
*/
|
|
@@ -2290,52 +2787,53 @@ export enum EmbedEvent {
|
|
|
2290
2787
|
/**
|
|
2291
2788
|
* @hidden
|
|
2292
2789
|
* Emitted when a user changes any filter on a Liveboard.
|
|
2293
|
-
* @version SDK: 1.23.0 | ThoughtSpot: 9.4.0.cl
|
|
2790
|
+
* @version SDK: 1.23.0 | ThoughtSpot: 9.4.0.cl, 9.5.0.sw
|
|
2294
2791
|
*/
|
|
2295
2792
|
FilterChanged = "filterChanged",
|
|
2296
2793
|
/**
|
|
2297
|
-
* Emitted when a user
|
|
2794
|
+
* Emitted when a user clicks the **Go** button on the Search page
|
|
2298
2795
|
*
|
|
2299
|
-
* @version SDK : 1.26.0 | Thoughtspot: 9.7.0.cl
|
|
2796
|
+
* @version SDK : 1.26.0 | Thoughtspot: 9.7.0.cl, 9.8.0.sw
|
|
2300
2797
|
*/
|
|
2301
2798
|
SageEmbedQuery = "sageEmbedQuery",
|
|
2302
2799
|
/**
|
|
2303
|
-
*
|
|
2800
|
+
* Emitted when a user selects a data source.
|
|
2801
|
+
*
|
|
2802
|
+
* @version SDK : 1.26.0 | Thoughtspot: 9.7.0.cl, 9.8.0.sw
|
|
2304
2803
|
*
|
|
2305
|
-
* @version SDK : 1.26.0 | Thoughtspot: 9.7.0.cl
|
|
2306
2804
|
*/
|
|
2307
2805
|
SageWorksheetUpdated = "sageWorksheetUpdated",
|
|
2308
2806
|
/**
|
|
2309
|
-
* Emitted when a user updates a connection
|
|
2807
|
+
* Emitted when a user updates a connection on the **Data** page
|
|
2310
2808
|
*
|
|
2311
|
-
* @version SDK : 1.27.0 | Thoughtspot: 9.8.0.cl
|
|
2809
|
+
* @version SDK : 1.27.0 | Thoughtspot: 9.8.0.cl, 9.8.0.sw
|
|
2312
2810
|
*/
|
|
2313
2811
|
UpdateConnection = "updateConnection",
|
|
2314
2812
|
/**
|
|
2315
|
-
* Emitted when a user updates a connection
|
|
2813
|
+
* Emitted when a user updates a connection on the **Data** page
|
|
2316
2814
|
*
|
|
2317
|
-
* @version SDK : 1.27.0 | Thoughtspot: 9.8.0.cl
|
|
2815
|
+
* @version SDK : 1.27.0 | Thoughtspot: 9.8.0.cl, 9.8.0.sw
|
|
2318
2816
|
*/
|
|
2319
2817
|
CreateConnection = "createConnection",
|
|
2320
2818
|
/**
|
|
2321
2819
|
* Emitted when name, status (private or public) or filter values of a
|
|
2322
|
-
*
|
|
2820
|
+
* Personalised view is updated.
|
|
2323
2821
|
*
|
|
2324
2822
|
* @returns viewName: string
|
|
2325
2823
|
* @returns viewId: string
|
|
2326
2824
|
* @returns liveboardId: string
|
|
2327
2825
|
* @returns isPublic: boolean
|
|
2328
|
-
* @version SDK : 1.26.0 | Thoughtspot: 9.7.0.cl
|
|
2826
|
+
* @version SDK : 1.26.0 | Thoughtspot: 9.7.0.cl, 9.8.0.sw
|
|
2329
2827
|
*/
|
|
2330
2828
|
UpdatePersonalisedView = "updatePersonalisedView",
|
|
2331
2829
|
/**
|
|
2332
|
-
* Emitted when a
|
|
2830
|
+
* Emitted when a Personalised view is saved.
|
|
2333
2831
|
*
|
|
2334
2832
|
* @returns viewName: string
|
|
2335
2833
|
* @returns viewId: string
|
|
2336
2834
|
* @returns liveboardId: string
|
|
2337
2835
|
* @returns isPublic: boolean
|
|
2338
|
-
* @version SDK : 1.26.0 | Thoughtspot: 9.7.0.cl
|
|
2836
|
+
* @version SDK : 1.26.0 | Thoughtspot: 9.7.0.cl, 9.8.0.sw
|
|
2339
2837
|
*/
|
|
2340
2838
|
SavePersonalisedView = "savePersonalisedView",
|
|
2341
2839
|
/**
|
|
@@ -2345,7 +2843,7 @@ export enum EmbedEvent {
|
|
|
2345
2843
|
* @returns viewId: string
|
|
2346
2844
|
* @returns liveboardId: string
|
|
2347
2845
|
* @returns isPublic: boolean
|
|
2348
|
-
* @version SDK : 1.26.0 | Thoughtspot: 9.7.0.cl
|
|
2846
|
+
* @version SDK : 1.26.0 | Thoughtspot: 9.7.0.cl, 9.8.0.sw
|
|
2349
2847
|
*/
|
|
2350
2848
|
ResetLiveboard = "resetLiveboard",
|
|
2351
2849
|
/**
|
|
@@ -2353,11 +2851,11 @@ export enum EmbedEvent {
|
|
|
2353
2851
|
*
|
|
2354
2852
|
* @returns views: string[]
|
|
2355
2853
|
* @returns liveboardId: string
|
|
2356
|
-
* @version SDK : 1.26.0 | Thoughtspot: 9.7.0.cl
|
|
2854
|
+
* @version SDK : 1.26.0 | Thoughtspot: 9.7.0.cl, 9.8.0.sw
|
|
2357
2855
|
*/
|
|
2358
2856
|
DeletePersonalisedView = "deletePersonalisedView",
|
|
2359
2857
|
/**
|
|
2360
|
-
*
|
|
2858
|
+
* Emitted when a user creates a new worksheet
|
|
2361
2859
|
*
|
|
2362
2860
|
* @version SDK : 1.27.0 | Thoughtspot: 9.8.0.cl
|
|
2363
2861
|
*/
|
|
@@ -2387,15 +2885,16 @@ export enum EmbedEvent {
|
|
|
2387
2885
|
*/
|
|
2388
2886
|
export enum HostEvent {
|
|
2389
2887
|
/**
|
|
2390
|
-
* Triggers a search
|
|
2391
|
-
*
|
|
2888
|
+
* Triggers a search operation with the search tokens specified in
|
|
2889
|
+
* the search query string.
|
|
2890
|
+
* Supported in `AppEmbed` and `SearchEmbed` deployments.
|
|
2392
2891
|
* Includes the following properties:
|
|
2393
2892
|
*
|
|
2394
|
-
* @param -
|
|
2893
|
+
* @param - `searchQuery` - query string with search tokens
|
|
2894
|
+
* @param - `dataSources` - Data source GUID to Search on
|
|
2395
2895
|
* - Although an array, only a single source
|
|
2396
2896
|
* is supported.
|
|
2397
|
-
* @param -
|
|
2398
|
-
* @param - execute - executes the existing / updated query
|
|
2897
|
+
* @param - `execute` - executes search and updates the existing query
|
|
2399
2898
|
* @example
|
|
2400
2899
|
* ```js
|
|
2401
2900
|
* searchembed.trigger(HostEvent.Search, {
|
|
@@ -2415,6 +2914,10 @@ export enum HostEvent {
|
|
|
2415
2914
|
* @param - columnGuid - Optional. GUID of the column to drill
|
|
2416
2915
|
* by. If not provided it will auto drill by the configured
|
|
2417
2916
|
* column.
|
|
2917
|
+
* @param - autoDrillDown - Optional. If true, the drill down will be
|
|
2918
|
+
* done automatically on the most popular column.
|
|
2919
|
+
* @param - vizId [TS >= 9.8.0] - Optional. The GUID of the visualization to drill
|
|
2920
|
+
* in case of a liveboard.
|
|
2418
2921
|
* @example
|
|
2419
2922
|
* ```js
|
|
2420
2923
|
* searchEmbed.on(EmbedEvent.VizPointDoubleClick, (payload) => {
|
|
@@ -2431,6 +2934,25 @@ export enum HostEvent {
|
|
|
2431
2934
|
* });
|
|
2432
2935
|
* })
|
|
2433
2936
|
* ```
|
|
2937
|
+
* @example
|
|
2938
|
+
* ```js
|
|
2939
|
+
* // Works with TS 9.8.0 and above
|
|
2940
|
+
*
|
|
2941
|
+
* liveboardEmbed.on(EmbedEvent.VizPointDoubleClick, (payload) => {
|
|
2942
|
+
* console.log(payload);
|
|
2943
|
+
* const clickedPoint = payload.data.clickedPoint;
|
|
2944
|
+
* const selectedPoint = payload.data.selectedPoints;
|
|
2945
|
+
* console.log('>>> called', clickedPoint);
|
|
2946
|
+
* liveboardEmbed.trigger(HostEvent.DrillDown, {
|
|
2947
|
+
* points: {
|
|
2948
|
+
* clickedPoint,
|
|
2949
|
+
* selectedPoints: selectedPoint
|
|
2950
|
+
* },
|
|
2951
|
+
* autoDrillDown: true,
|
|
2952
|
+
* vizId: payload.data.vizId
|
|
2953
|
+
* });
|
|
2954
|
+
* })
|
|
2955
|
+
* ```
|
|
2434
2956
|
* @version SDK: 1.5.0 | ThoughtSpot: ts7.oct.cl, 7.2.1
|
|
2435
2957
|
*/
|
|
2436
2958
|
DrillDown = "triggerDrillDown",
|
|
@@ -2447,7 +2969,7 @@ export enum HostEvent {
|
|
|
2447
2969
|
*/
|
|
2448
2970
|
Reload = "reload",
|
|
2449
2971
|
/**
|
|
2450
|
-
*
|
|
2972
|
+
* Display specific visualizations on a Liveboard.
|
|
2451
2973
|
*
|
|
2452
2974
|
* @param - An array of GUIDs of the visualization to show. The visualization IDs not passed
|
|
2453
2975
|
* in this parameter will be hidden.
|
|
@@ -2461,7 +2983,7 @@ export enum HostEvent {
|
|
|
2461
2983
|
*/
|
|
2462
2984
|
SetVisibleVizs = "SetPinboardVisibleVizs",
|
|
2463
2985
|
/**
|
|
2464
|
-
* Set
|
|
2986
|
+
* Set a Liveboard tab as an active tab.
|
|
2465
2987
|
*
|
|
2466
2988
|
* @param - tabId - string of id of Tab to show
|
|
2467
2989
|
* @example
|
|
@@ -2474,7 +2996,7 @@ export enum HostEvent {
|
|
|
2474
2996
|
*/
|
|
2475
2997
|
SetActiveTab = "SetActiveTab",
|
|
2476
2998
|
/**
|
|
2477
|
-
*
|
|
2999
|
+
* Update runtime filters applied on a Saved Answer or Liveboard. The
|
|
2478
3000
|
* runtime filters passed here are appended to the existing runtime
|
|
2479
3001
|
* filters.
|
|
2480
3002
|
* Pass an array of runtime filters with the following attributes:
|
|
@@ -2500,10 +3022,12 @@ export enum HostEvent {
|
|
|
2500
3022
|
*/
|
|
2501
3023
|
UpdateRuntimeFilters = "UpdateRuntimeFilters",
|
|
2502
3024
|
/**
|
|
2503
|
-
* Navigate to a specific page in the embedded application
|
|
3025
|
+
* Navigate to a specific page in the embedded ThoughtSpot application.
|
|
2504
3026
|
* This is the same as calling `appEmbed.navigateToPage(path, true)`
|
|
2505
3027
|
*
|
|
2506
|
-
* @param - path - the path to navigate to
|
|
3028
|
+
* @param - `path` - the path to navigate to to go forward or back. The path value can
|
|
3029
|
+
* be a number; for example, `1`, `-1`.
|
|
3030
|
+
*
|
|
2507
3031
|
* @example
|
|
2508
3032
|
* ```js
|
|
2509
3033
|
* appEmbed.navigateToPage(-1)
|
|
@@ -2512,7 +3036,7 @@ export enum HostEvent {
|
|
|
2512
3036
|
*/
|
|
2513
3037
|
Navigate = "Navigate",
|
|
2514
3038
|
/**
|
|
2515
|
-
*
|
|
3039
|
+
* Open the filter panel for a particular column.
|
|
2516
3040
|
* Works with Search and Liveboard embed.
|
|
2517
3041
|
*
|
|
2518
3042
|
* @param - { columnId: string,
|
|
@@ -2530,7 +3054,7 @@ export enum HostEvent {
|
|
|
2530
3054
|
*/
|
|
2531
3055
|
OpenFilter = "openFilter",
|
|
2532
3056
|
/**
|
|
2533
|
-
*
|
|
3057
|
+
* Add columns to the current search query.
|
|
2534
3058
|
*
|
|
2535
3059
|
* @param - { columnIds: string[] }
|
|
2536
3060
|
* @example
|
|
@@ -2541,7 +3065,7 @@ export enum HostEvent {
|
|
|
2541
3065
|
*/
|
|
2542
3066
|
AddColumns = "addColumns",
|
|
2543
3067
|
/**
|
|
2544
|
-
*
|
|
3068
|
+
* Remove a column from the current search query.
|
|
2545
3069
|
*
|
|
2546
3070
|
* @param - { columnId: string }
|
|
2547
3071
|
* @example
|
|
@@ -2552,27 +3076,29 @@ export enum HostEvent {
|
|
|
2552
3076
|
*/
|
|
2553
3077
|
RemoveColumn = "removeColumn",
|
|
2554
3078
|
/**
|
|
2555
|
-
*
|
|
3079
|
+
* Get the transient state of a Liveboard as encoded content.
|
|
3080
|
+
* This includes unsaved and ad hoc changes such as
|
|
3081
|
+
* Liveboard filters, runtime filters applied on visualizations on a
|
|
3082
|
+
* Liveboard, and Liveboard layout, changes to visualizations such as
|
|
3083
|
+
* sorting, toggling of legends, and data drill down.
|
|
2556
3084
|
*
|
|
2557
3085
|
* @example
|
|
2558
3086
|
* ```js
|
|
2559
|
-
* liveboardEmbed.trigger(HostEvent.
|
|
3087
|
+
* liveboardEmbed.trigger(HostEvent.getexportrequestforcurrentpinboard).then(
|
|
3088
|
+
* data=>console.log(data))
|
|
2560
3089
|
* ```
|
|
2561
3090
|
* @version SDK: 1.13.0 | ThoughtSpot: 8.5.0.cl, 8.8.1.sw
|
|
2562
3091
|
*/
|
|
2563
3092
|
getExportRequestForCurrentPinboard = "getExportRequestForCurrentPinboard",
|
|
2564
3093
|
/**
|
|
2565
|
-
*
|
|
3094
|
+
* Trigger the **Pin** action on an embedded object
|
|
2566
3095
|
*
|
|
2567
3096
|
* @param - Liveboard embed takes the `vizId` as a
|
|
2568
|
-
* key. Can be left undefined when embedding Search, full app or
|
|
3097
|
+
* key. Can be left undefined when embedding Search, full app, or
|
|
2569
3098
|
* a visualization.
|
|
2570
3099
|
* @example
|
|
2571
3100
|
* ```js
|
|
2572
|
-
*
|
|
2573
|
-
* ```
|
|
2574
|
-
* ```js
|
|
2575
|
-
* vizEmbed.trigger(HostEvent.Pin)
|
|
3101
|
+
* appEmbed.trigger(HostEvent.Pin)
|
|
2576
3102
|
* ```
|
|
2577
3103
|
* ```js
|
|
2578
3104
|
* searchEmbed.trigger(HostEvent.Pin)
|
|
@@ -2581,17 +3107,18 @@ export enum HostEvent {
|
|
|
2581
3107
|
*/
|
|
2582
3108
|
Pin = "pin",
|
|
2583
3109
|
/**
|
|
2584
|
-
*
|
|
3110
|
+
* Trigger the **Show Liveboard details** action
|
|
3111
|
+
* on an embedded Liveboard.
|
|
2585
3112
|
*
|
|
2586
3113
|
* @example
|
|
2587
|
-
|
|
2588
|
-
*
|
|
2589
|
-
|
|
3114
|
+
*```js
|
|
3115
|
+
* liveboardEmbed.trigger(HostEvent.LiveboardInfo)
|
|
3116
|
+
*```
|
|
2590
3117
|
* @version SDK: 1.15.0 | ThoughtSpot: 8.7.0.cl, 8.8.1.sw
|
|
2591
3118
|
*/
|
|
2592
3119
|
LiveboardInfo = "pinboardInfo",
|
|
2593
3120
|
/**
|
|
2594
|
-
*
|
|
3121
|
+
* Trigger the **Schedule** action on an embedded Liveboard.
|
|
2595
3122
|
*
|
|
2596
3123
|
* @example
|
|
2597
3124
|
* ```js
|
|
@@ -2601,7 +3128,7 @@ export enum HostEvent {
|
|
|
2601
3128
|
*/
|
|
2602
3129
|
Schedule = "subscription",
|
|
2603
3130
|
/**
|
|
2604
|
-
*
|
|
3131
|
+
* Trigger the **Manage schedule** action on an embedded Liveboard
|
|
2605
3132
|
*
|
|
2606
3133
|
* @example
|
|
2607
3134
|
* ```js
|
|
@@ -2611,7 +3138,7 @@ export enum HostEvent {
|
|
|
2611
3138
|
*/
|
|
2612
3139
|
SchedulesList = "schedule-list",
|
|
2613
3140
|
/**
|
|
2614
|
-
*
|
|
3141
|
+
* Trigger the **Export TML** action on an embedded Liveboard.
|
|
2615
3142
|
*
|
|
2616
3143
|
* @example
|
|
2617
3144
|
* ```js
|
|
@@ -2621,7 +3148,7 @@ export enum HostEvent {
|
|
|
2621
3148
|
*/
|
|
2622
3149
|
ExportTML = "exportTSL",
|
|
2623
3150
|
/**
|
|
2624
|
-
*
|
|
3151
|
+
* Trigger the **Edit TML** action on an embedded Liveboard.
|
|
2625
3152
|
*
|
|
2626
3153
|
* @example
|
|
2627
3154
|
* ```js
|
|
@@ -2631,7 +3158,7 @@ export enum HostEvent {
|
|
|
2631
3158
|
*/
|
|
2632
3159
|
EditTML = "editTSL",
|
|
2633
3160
|
/**
|
|
2634
|
-
*
|
|
3161
|
+
* Trigger the **Update TML** action on an embedded Liveboard.
|
|
2635
3162
|
*
|
|
2636
3163
|
* @example
|
|
2637
3164
|
* ```js
|
|
@@ -2641,7 +3168,7 @@ export enum HostEvent {
|
|
|
2641
3168
|
*/
|
|
2642
3169
|
UpdateTML = "updateTSL",
|
|
2643
3170
|
/**
|
|
2644
|
-
*
|
|
3171
|
+
* Trigger the **Download PDF** action on an embedded Liveboard.
|
|
2645
3172
|
*
|
|
2646
3173
|
* @example
|
|
2647
3174
|
* ```js
|
|
@@ -2651,8 +3178,8 @@ export enum HostEvent {
|
|
|
2651
3178
|
*/
|
|
2652
3179
|
DownloadAsPdf = "downloadAsPdf",
|
|
2653
3180
|
/**
|
|
2654
|
-
*
|
|
2655
|
-
* visualization page
|
|
3181
|
+
* Trigger the **Make a copy** action on a Liveboard, Search, or
|
|
3182
|
+
* visualization page.
|
|
2656
3183
|
*
|
|
2657
3184
|
* @example
|
|
2658
3185
|
* ```js
|
|
@@ -2668,7 +3195,7 @@ export enum HostEvent {
|
|
|
2668
3195
|
*/
|
|
2669
3196
|
MakeACopy = "makeACopy",
|
|
2670
3197
|
/**
|
|
2671
|
-
*
|
|
3198
|
+
* Trigger the **Delete** action for a Liveboard.
|
|
2672
3199
|
*
|
|
2673
3200
|
* @example
|
|
2674
3201
|
* ```js
|
|
@@ -2678,7 +3205,7 @@ export enum HostEvent {
|
|
|
2678
3205
|
*/
|
|
2679
3206
|
Remove = "delete",
|
|
2680
3207
|
/**
|
|
2681
|
-
*
|
|
3208
|
+
* Trigger the **Explore** action on a visualization.
|
|
2682
3209
|
*
|
|
2683
3210
|
* @param - an object with `vizId` as a key
|
|
2684
3211
|
* @example
|
|
@@ -2689,7 +3216,7 @@ export enum HostEvent {
|
|
|
2689
3216
|
*/
|
|
2690
3217
|
Explore = "explore",
|
|
2691
3218
|
/**
|
|
2692
|
-
*
|
|
3219
|
+
* Trigger the **Create alert** action on a visualization
|
|
2693
3220
|
*
|
|
2694
3221
|
* @param - an object with `vizId` as a key
|
|
2695
3222
|
* @example
|
|
@@ -2702,7 +3229,7 @@ export enum HostEvent {
|
|
|
2702
3229
|
*/
|
|
2703
3230
|
CreateMonitor = "createMonitor",
|
|
2704
3231
|
/**
|
|
2705
|
-
*
|
|
3232
|
+
* Trigger the **Manage alerts** action on a visualization
|
|
2706
3233
|
*
|
|
2707
3234
|
* @param - an object with `vizId` as a key
|
|
2708
3235
|
* @example
|
|
@@ -2715,7 +3242,7 @@ export enum HostEvent {
|
|
|
2715
3242
|
*/
|
|
2716
3243
|
ManageMonitor = "manageMonitor",
|
|
2717
3244
|
/**
|
|
2718
|
-
*
|
|
3245
|
+
* Trigger the **Edit** action on a Liveboard or visualization
|
|
2719
3246
|
*
|
|
2720
3247
|
* @param - object - To trigger the action for a specific visualization
|
|
2721
3248
|
* in Liveboard embed, pass in `vizId` as a key.
|
|
@@ -2736,7 +3263,7 @@ export enum HostEvent {
|
|
|
2736
3263
|
*/
|
|
2737
3264
|
Edit = "edit",
|
|
2738
3265
|
/**
|
|
2739
|
-
*
|
|
3266
|
+
* Trigger the **Copy link** action on a Liveboard or visualization
|
|
2740
3267
|
*
|
|
2741
3268
|
* @param - object - to trigger the action for a
|
|
2742
3269
|
* specific visualization in Liveboard embed, pass in `vizId` as a key
|
|
@@ -2754,7 +3281,7 @@ export enum HostEvent {
|
|
|
2754
3281
|
*/
|
|
2755
3282
|
CopyLink = "embedDocument",
|
|
2756
3283
|
/**
|
|
2757
|
-
*
|
|
3284
|
+
* Trigger the **Present** action on a Liveboard or visualization
|
|
2758
3285
|
*
|
|
2759
3286
|
* @param - object - to trigger the action for a specific visualization
|
|
2760
3287
|
* in Liveboard embed, pass in `vizId` as a key
|
|
@@ -2772,7 +3299,7 @@ export enum HostEvent {
|
|
|
2772
3299
|
*/
|
|
2773
3300
|
Present = "present",
|
|
2774
3301
|
/**
|
|
2775
|
-
*
|
|
3302
|
+
* Get TML for the current search.
|
|
2776
3303
|
*
|
|
2777
3304
|
* @example
|
|
2778
3305
|
* ```js
|
|
@@ -2787,7 +3314,7 @@ export enum HostEvent {
|
|
|
2787
3314
|
*/
|
|
2788
3315
|
GetTML = "getTML",
|
|
2789
3316
|
/**
|
|
2790
|
-
*
|
|
3317
|
+
* Trigger the **Show underlying data** action on visualization or search
|
|
2791
3318
|
*
|
|
2792
3319
|
* @param - an object with vizId as a key
|
|
2793
3320
|
* @example
|
|
@@ -2805,7 +3332,9 @@ export enum HostEvent {
|
|
|
2805
3332
|
*/
|
|
2806
3333
|
ShowUnderlyingData = "showUnderlyingData",
|
|
2807
3334
|
/**
|
|
2808
|
-
*
|
|
3335
|
+
* Trigger the **Delete** action for a visualization
|
|
3336
|
+
* in an embedded Liveboard, or a chart or table
|
|
3337
|
+
* generated from Search.
|
|
2809
3338
|
*
|
|
2810
3339
|
* @param - Liveboard embed takes an object with `vizId` as a key.
|
|
2811
3340
|
* Can be left empty if embedding Search or visualization.
|
|
@@ -2815,16 +3344,13 @@ export enum HostEvent {
|
|
|
2815
3344
|
* '730496d6-6903-4601-937e-2c691821af3c'})
|
|
2816
3345
|
* ```
|
|
2817
3346
|
* ```js
|
|
2818
|
-
* vizEmbed.trigger(HostEvent.Delete)
|
|
2819
|
-
* ```
|
|
2820
|
-
* ```js
|
|
2821
3347
|
* searchEmbed.trigger(HostEvent.Delete)
|
|
2822
3348
|
* ```
|
|
2823
3349
|
* @version SDK: 1.19.0 | ThoughtSpot: 9.0.0.cl, 9.0.1.sw
|
|
2824
3350
|
*/
|
|
2825
3351
|
Delete = "onDeleteAnswer",
|
|
2826
3352
|
/**
|
|
2827
|
-
*
|
|
3353
|
+
* Trigger the **SpotIQ analyze** action on visualization
|
|
2828
3354
|
* or search.
|
|
2829
3355
|
*
|
|
2830
3356
|
* @param - Liveboard embed takes `vizId` as a
|
|
@@ -2845,7 +3371,7 @@ export enum HostEvent {
|
|
|
2845
3371
|
*/
|
|
2846
3372
|
SpotIQAnalyze = "spotIQAnalyze",
|
|
2847
3373
|
/**
|
|
2848
|
-
*
|
|
3374
|
+
* Trigger the **Download** action on charts in
|
|
2849
3375
|
* the embedded view.
|
|
2850
3376
|
*
|
|
2851
3377
|
* @example
|
|
@@ -2854,17 +3380,15 @@ export enum HostEvent {
|
|
|
2854
3380
|
* '730496d6-6903-4601-937e-2c691821af3c'})
|
|
2855
3381
|
* ```
|
|
2856
3382
|
* ```js
|
|
2857
|
-
*
|
|
3383
|
+
* embed.trigger(HostEvent.Download)
|
|
2858
3384
|
* ```
|
|
2859
|
-
*
|
|
2860
|
-
*
|
|
2861
|
-
* ```
|
|
2862
|
-
* @deprecated from SDK: 1.21.0 | ThoughtSpot: 9.2.0.cl ,9.4.1.sw ,Use {@link DownloadAsPng}
|
|
3385
|
+
* @deprecated from SDK: 1.21.0 | ThoughtSpot: 9.2.0.cl ,9.4.1.sw
|
|
3386
|
+
* Use {@link DownloadAsPng}
|
|
2863
3387
|
* @version SDK: 1.19.0 | ThoughtSpot: 9.0.0.cl, 9.0.1.sw
|
|
2864
3388
|
*/
|
|
2865
3389
|
Download = "downloadAsPng",
|
|
2866
3390
|
/**
|
|
2867
|
-
*
|
|
3391
|
+
* Trigger the **Download** > **PNG** action on
|
|
2868
3392
|
* charts in the embedded view.
|
|
2869
3393
|
*
|
|
2870
3394
|
* @example
|
|
@@ -2880,7 +3404,7 @@ export enum HostEvent {
|
|
|
2880
3404
|
*/
|
|
2881
3405
|
DownloadAsPng = "downloadAsPng",
|
|
2882
3406
|
/**
|
|
2883
|
-
*
|
|
3407
|
+
* Trigger the **Download** > **CSV** action on tables in
|
|
2884
3408
|
* the embedded view.
|
|
2885
3409
|
*
|
|
2886
3410
|
* @example
|
|
@@ -2898,7 +3422,7 @@ export enum HostEvent {
|
|
|
2898
3422
|
*/
|
|
2899
3423
|
DownloadAsCsv = "downloadAsCSV",
|
|
2900
3424
|
/**
|
|
2901
|
-
*
|
|
3425
|
+
* Trigger the **Download** > **XLSX** action on tables
|
|
2902
3426
|
* in the embedded view.
|
|
2903
3427
|
*
|
|
2904
3428
|
* @example
|
|
@@ -2916,7 +3440,7 @@ export enum HostEvent {
|
|
|
2916
3440
|
*/
|
|
2917
3441
|
DownloadAsXlsx = "downloadAsXLSX",
|
|
2918
3442
|
/**
|
|
2919
|
-
*
|
|
3443
|
+
* Trigger the **Share** action on an embedded
|
|
2920
3444
|
* Liveboard or Answer.
|
|
2921
3445
|
*
|
|
2922
3446
|
* @example
|
|
@@ -2930,7 +3454,7 @@ export enum HostEvent {
|
|
|
2930
3454
|
*/
|
|
2931
3455
|
Share = "share",
|
|
2932
3456
|
/**
|
|
2933
|
-
*
|
|
3457
|
+
* Trigger the **Save** action on a Liveboard or Answer.
|
|
2934
3458
|
* Saves the changes.
|
|
2935
3459
|
*
|
|
2936
3460
|
* @example
|
|
@@ -2944,7 +3468,7 @@ export enum HostEvent {
|
|
|
2944
3468
|
*/
|
|
2945
3469
|
Save = "save",
|
|
2946
3470
|
/**
|
|
2947
|
-
*
|
|
3471
|
+
* Trigger the **Sync to Sheets** action on an embedded visualization or Answer
|
|
2948
3472
|
* Sends data from an Answer or Liveboard visualization to a Google sheet.
|
|
2949
3473
|
*
|
|
2950
3474
|
* @param - an object with `vizId` as a key
|
|
@@ -2960,7 +3484,7 @@ export enum HostEvent {
|
|
|
2960
3484
|
*/
|
|
2961
3485
|
SyncToSheets = "sync-to-sheets",
|
|
2962
3486
|
/**
|
|
2963
|
-
*
|
|
3487
|
+
* Trigger the **Sync to Other Apps** action on an embedded visualization or Answer
|
|
2964
3488
|
* Sends data from an Answer or Liveboard visualization to third-party apps such
|
|
2965
3489
|
* as Slack, Salesforce, Microsoft Teams, ServiceNow and so on.
|
|
2966
3490
|
*
|
|
@@ -2977,7 +3501,7 @@ export enum HostEvent {
|
|
|
2977
3501
|
*/
|
|
2978
3502
|
SyncToOtherApps = "sync-to-other-apps",
|
|
2979
3503
|
/**
|
|
2980
|
-
*
|
|
3504
|
+
* Trigger the **Manage pipelines** action on an embedded
|
|
2981
3505
|
* visualization or Answer.
|
|
2982
3506
|
* Allows users to manage ThoughtSpot Sync pipelines.
|
|
2983
3507
|
*
|
|
@@ -2994,18 +3518,21 @@ export enum HostEvent {
|
|
|
2994
3518
|
*/
|
|
2995
3519
|
ManagePipelines = "manage-pipeline",
|
|
2996
3520
|
/**
|
|
2997
|
-
*
|
|
3521
|
+
* Reset search operation on the Search or Answer page.
|
|
2998
3522
|
*
|
|
2999
3523
|
* @example
|
|
3000
3524
|
* ```js
|
|
3001
3525
|
* searchEmbed.trigger(HostEvent.ResetSearch)
|
|
3002
3526
|
* ```
|
|
3527
|
+
* ```js
|
|
3528
|
+
* appEmbed.trigger(HostEvent.ResetSearch)
|
|
3529
|
+
* ```
|
|
3003
3530
|
* @version SDK: 1.21.0 | ThoughtSpot: 9.2.0.cl, 9.0.1.sw
|
|
3004
3531
|
*/
|
|
3005
3532
|
ResetSearch = "resetSearch",
|
|
3006
3533
|
/**
|
|
3007
3534
|
* @hidden
|
|
3008
|
-
*
|
|
3535
|
+
* Get the currents visible and runtime filters applied on a Liveboard
|
|
3009
3536
|
* @example
|
|
3010
3537
|
* liveboardEmbed.trigger(HostEvent.GetFilters)
|
|
3011
3538
|
* @version SDK: 1.23.0 | ThoughtSpot: 9.4.0.cl
|
|
@@ -3013,7 +3540,7 @@ export enum HostEvent {
|
|
|
3013
3540
|
GetFilters = "getFilters",
|
|
3014
3541
|
/**
|
|
3015
3542
|
* @hidden
|
|
3016
|
-
*
|
|
3543
|
+
* Update the visible filters on the Liveboard.
|
|
3017
3544
|
* @param - filter: filter object containing column name and filter operation and values
|
|
3018
3545
|
* @example
|
|
3019
3546
|
*
|
|
@@ -3026,7 +3553,7 @@ export enum HostEvent {
|
|
|
3026
3553
|
*/
|
|
3027
3554
|
UpdateFilters = "updateFilters",
|
|
3028
3555
|
/**
|
|
3029
|
-
* Get
|
|
3556
|
+
* Get tab details for the current Liveboard.
|
|
3030
3557
|
*
|
|
3031
3558
|
* @example
|
|
3032
3559
|
* ```js
|
|
@@ -3040,9 +3567,9 @@ export enum HostEvent {
|
|
|
3040
3567
|
*/
|
|
3041
3568
|
GetTabs = "getTabs",
|
|
3042
3569
|
/**
|
|
3043
|
-
* Set the visible
|
|
3570
|
+
* Set the visible tabs on a Liveboard.
|
|
3044
3571
|
*
|
|
3045
|
-
* @param - an array of ids of
|
|
3572
|
+
* @param - an array of ids of tabs to show, the IDs not passed
|
|
3046
3573
|
* will be hidden.
|
|
3047
3574
|
* @example
|
|
3048
3575
|
* ```js
|
|
@@ -3056,8 +3583,8 @@ export enum HostEvent {
|
|
|
3056
3583
|
/**
|
|
3057
3584
|
* Set the hidden tabs on a Liveboard.
|
|
3058
3585
|
*
|
|
3059
|
-
* @param - an array of
|
|
3060
|
-
*
|
|
3586
|
+
* @param - an array of the IDs of the tabs to hide.
|
|
3587
|
+
* The IDs not passed will be shown.
|
|
3061
3588
|
* @example
|
|
3062
3589
|
* ```js
|
|
3063
3590
|
* liveboardEmbed.trigger(HostEvent.SetHiddenTabs, [
|
|
@@ -3068,9 +3595,12 @@ export enum HostEvent {
|
|
|
3068
3595
|
*/
|
|
3069
3596
|
SetHiddenTabs = "SetPinboardHiddenTabs",
|
|
3070
3597
|
/**
|
|
3071
|
-
* Updates the search query for
|
|
3598
|
+
* Updates the search query string for Natural Language Search operations.
|
|
3599
|
+
*
|
|
3600
|
+
* @param - `queryString`: Text string in Natural Language format
|
|
3601
|
+
*
|
|
3602
|
+
* @param - `executeSearch`: Boolean to execute search and update search query
|
|
3072
3603
|
*
|
|
3073
|
-
* @param - searchOptions: an object queryString and option to execute the query.
|
|
3074
3604
|
* @example
|
|
3075
3605
|
* ```js
|
|
3076
3606
|
* sageEmbed.trigger(HostEvent.UpdateSageQuery, {
|
|
@@ -3078,7 +3608,7 @@ export enum HostEvent {
|
|
|
3078
3608
|
* executeSearch: true,
|
|
3079
3609
|
* })
|
|
3080
3610
|
* ```
|
|
3081
|
-
* @version SDK: 1.26.0 | Thoughtspot: 9.
|
|
3611
|
+
* @version SDK: 1.26.0 | Thoughtspot: 9.8.0.cl, 9.8.0.sw
|
|
3082
3612
|
*/
|
|
3083
3613
|
UpdateSageQuery = "updateSageQuery",
|
|
3084
3614
|
/**
|
|
@@ -3091,24 +3621,25 @@ export enum HostEvent {
|
|
|
3091
3621
|
* vizId: '123', // For Liveboard Visualization.
|
|
3092
3622
|
* })
|
|
3093
3623
|
* ```
|
|
3624
|
+
* @version SDK: 1.26.0 | Thoughtspot: 9.10.0.cl
|
|
3094
3625
|
*/
|
|
3095
3626
|
GetAnswerSession = "getAnswerSession"
|
|
3096
3627
|
}
|
|
3097
3628
|
/**
|
|
3098
3629
|
* The different visual modes that the data sources panel within
|
|
3099
|
-
* search could appear in,
|
|
3630
|
+
* search could appear in, such as hidden, collapsed, or expanded.
|
|
3100
3631
|
*/
|
|
3101
3632
|
export enum DataSourceVisualMode {
|
|
3102
3633
|
/**
|
|
3103
|
-
*
|
|
3634
|
+
* The data source panel is hidden.
|
|
3104
3635
|
*/
|
|
3105
3636
|
Hidden = "hide",
|
|
3106
3637
|
/**
|
|
3107
|
-
*
|
|
3638
|
+
* The data source panel is collapsed, but the user can manually expand it.
|
|
3108
3639
|
*/
|
|
3109
3640
|
Collapsed = "collapse",
|
|
3110
3641
|
/**
|
|
3111
|
-
*
|
|
3642
|
+
* The data source panel is expanded, but the user can manually collapse it.
|
|
3112
3643
|
*/
|
|
3113
3644
|
Expanded = "expand"
|
|
3114
3645
|
}
|
|
@@ -3184,7 +3715,8 @@ export enum Param {
|
|
|
3184
3715
|
LiveboardHeaderSticky = "isLiveboardHeaderSticky",
|
|
3185
3716
|
IsProductTour = "isProductTour",
|
|
3186
3717
|
HideSearchBarTitle = "hideSearchBarTitle",
|
|
3187
|
-
HideSageAnswerHeader = "hideSageAnswerHeader"
|
|
3718
|
+
HideSageAnswerHeader = "hideSageAnswerHeader",
|
|
3719
|
+
HideSearchBar = "hideSearchBar"
|
|
3188
3720
|
}
|
|
3189
3721
|
/**
|
|
3190
3722
|
* ThoughtSpot application pages include actions and menu commands
|
|
@@ -3244,9 +3776,11 @@ export enum Action {
|
|
|
3244
3776
|
SaveAsView = "saveAsView",
|
|
3245
3777
|
/**
|
|
3246
3778
|
* The **Make a copy** action on a Liveboard or Answer
|
|
3247
|
-
* page.
|
|
3248
|
-
*
|
|
3249
|
-
*
|
|
3779
|
+
* page. Creates a copy of the Liveboard.
|
|
3780
|
+
* In LiveboardEmbed, the **Make a copy** action is not available for
|
|
3781
|
+
* visualizations in the embedded Liveboard view.
|
|
3782
|
+
* In AppEmbed, the **Make a copy** action is available on both
|
|
3783
|
+
* Liveboards and visualizations.
|
|
3250
3784
|
*
|
|
3251
3785
|
* @example
|
|
3252
3786
|
* ```js
|
|
@@ -3430,7 +3964,7 @@ export enum Action {
|
|
|
3430
3964
|
*/
|
|
3431
3965
|
DownloadAsPdf = "downloadAsPdf",
|
|
3432
3966
|
/**
|
|
3433
|
-
* The **Download**
|
|
3967
|
+
* The **Download** > **CSV** menu action for tables on a Liveboard
|
|
3434
3968
|
* or Answer page.
|
|
3435
3969
|
* Downloads a visualization or Answer in the XLSX format.
|
|
3436
3970
|
*
|
|
@@ -3961,6 +4495,7 @@ export enum Action {
|
|
|
3961
4495
|
*/
|
|
3962
4496
|
RenameModalTitleDescription = "renameModalTitleDescription",
|
|
3963
4497
|
/**
|
|
4498
|
+
*
|
|
3964
4499
|
* @version SDK: 1.25.0 | Thoughtspot: 9.6.0.cl
|
|
3965
4500
|
*/
|
|
3966
4501
|
RequestVerification = "requestVerification",
|
|
@@ -4451,14 +4986,14 @@ export interface CustomCssVariables {
|
|
|
4451
4986
|
*/
|
|
4452
4987
|
export interface SearchOptions {
|
|
4453
4988
|
/**
|
|
4454
|
-
* The query string to
|
|
4989
|
+
* The query string to pass for Natural Language Search.
|
|
4455
4990
|
*/
|
|
4456
4991
|
searchQuery: string;
|
|
4457
4992
|
/**
|
|
4458
|
-
* Boolean to
|
|
4459
|
-
*
|
|
4460
|
-
*
|
|
4461
|
-
* the
|
|
4993
|
+
* Boolean to define if the search should be executed or not.
|
|
4994
|
+
* If it is executed, the focus is placed on the results.
|
|
4995
|
+
* If it’s not executed, the focus is placed at the end of
|
|
4996
|
+
* the token string in the search bar.
|
|
4462
4997
|
*/
|
|
4463
4998
|
executeSearch?: boolean;
|
|
4464
4999
|
}
|
|
@@ -4466,16 +5001,16 @@ export interface SearchOptions {
|
|
|
4466
5001
|
* The configuration attributes for the embedded Natural language search view. Based on
|
|
4467
5002
|
* GPT and LLM.
|
|
4468
5003
|
*
|
|
4469
|
-
* @version: SDK: 1.23.0 | ThoughtSpot: 9.
|
|
5004
|
+
* @version: SDK: 1.23.0 | ThoughtSpot: 9.8.0.cl, 9.8.0.sw
|
|
4470
5005
|
* @group Embed components
|
|
4471
5006
|
*/
|
|
4472
5007
|
export interface SageViewConfig extends Omit<ViewConfig, 'hiddenHomepageModules' | 'hiddenHomeLeftNavItems' | 'hiddenTabs' | 'visibleTabs' | 'reorderedHomepageModules'> {
|
|
4473
5008
|
/**
|
|
4474
|
-
* If set to true, a list of
|
|
5009
|
+
* If set to true, a list of Liveboard and Answers related
|
|
4475
5010
|
* to the natural language search will be shown below the
|
|
4476
5011
|
* AI generated answer.
|
|
4477
5012
|
*
|
|
4478
|
-
* @deprecated Currently
|
|
5013
|
+
* @deprecated Currently Liveboard and Answers related
|
|
4479
5014
|
* to the natural language search will not be shown for sage
|
|
4480
5015
|
* embed
|
|
4481
5016
|
*/
|
|
@@ -4492,63 +5027,81 @@ export interface SageViewConfig extends Omit<ViewConfig, 'hiddenHomepageModules'
|
|
|
4492
5027
|
*/
|
|
4493
5028
|
isProductTour?: boolean;
|
|
4494
5029
|
/**
|
|
4495
|
-
*
|
|
5030
|
+
* Show or hide the search bar title.
|
|
4496
5031
|
*
|
|
4497
|
-
* @version SDK: 1.26.0 | Thoughtspot: 9.8.0.cl
|
|
5032
|
+
* @version SDK: 1.26.0 | Thoughtspot: 9.8.0.cl, 9.8.0.sw
|
|
4498
5033
|
*/
|
|
4499
5034
|
hideSearchBarTitle?: boolean;
|
|
4500
5035
|
/**
|
|
4501
|
-
*
|
|
4502
|
-
*
|
|
5036
|
+
* Show or hide the Answer header, that is, the `AI Answer` title
|
|
5037
|
+
* at the top of the Answer page.
|
|
4503
5038
|
*
|
|
4504
|
-
* @version SDK: 1.26.0 | Thoughtspot: 9.
|
|
5039
|
+
* @version SDK: 1.26.0 | Thoughtspot: 9.10.0.cl
|
|
4505
5040
|
*/
|
|
4506
5041
|
hideSageAnswerHeader?: boolean;
|
|
4507
5042
|
/**
|
|
4508
|
-
*
|
|
5043
|
+
* Disable the worksheet selection option.
|
|
4509
5044
|
*
|
|
4510
|
-
* @version SDK: 1.26.0 | Thoughtspot: 9.9.0.
|
|
5045
|
+
* @version SDK: 1.26.0 | Thoughtspot: 9.8.0.cl, 9.8.0.sw
|
|
4511
5046
|
*/
|
|
4512
5047
|
disableWorksheetChange?: boolean;
|
|
4513
5048
|
/**
|
|
4514
|
-
*
|
|
5049
|
+
* Hide the worksheet selection panel.
|
|
5050
|
+
*
|
|
5051
|
+
* @version SDK: 1.26.0 | Thoughtspot: 9.8.0.cl, 9.8.0.sw
|
|
4515
5052
|
*/
|
|
4516
5053
|
hideWorksheetSelector?: boolean;
|
|
4517
5054
|
/**
|
|
4518
|
-
*
|
|
4519
|
-
* default false
|
|
5055
|
+
* Show or hide autocomplete suggestions for the search query string.
|
|
4520
5056
|
*
|
|
4521
|
-
* @version SDK: 1.26.0 | Thoughtspot: 9.9.0.
|
|
5057
|
+
* @version SDK: 1.26.0 | Thoughtspot: 9.8.0.cl, 9.8.0.sw
|
|
4522
5058
|
*/
|
|
4523
5059
|
hideAutocompleteSuggestions?: boolean;
|
|
4524
5060
|
/**
|
|
4525
|
-
*
|
|
5061
|
+
* Show or hide autocomplete suggestions for the search query string.
|
|
4526
5062
|
*
|
|
4527
|
-
* @deprecated
|
|
4528
|
-
*
|
|
5063
|
+
* @deprecated
|
|
5064
|
+
* Currently, the object suggestions will not be shown for Natural Language Search.
|
|
5065
|
+
* You can use {@link hideAutocompleteSuggestions} instead.
|
|
4529
5066
|
*/
|
|
4530
5067
|
showObjectSuggestions?: boolean;
|
|
4531
5068
|
/**
|
|
4532
|
-
*
|
|
4533
|
-
*
|
|
5069
|
+
* Show or hide sample questions.
|
|
5070
|
+
* The sample questions are autogenerated based on the worksheet
|
|
5071
|
+
* selected for the search operation.
|
|
4534
5072
|
*
|
|
4535
|
-
* @version SDK: 1.26.0 | Thoughtspot: 9.
|
|
5073
|
+
* @version SDK: 1.26.0 | Thoughtspot: 9.8.0.cl, 9.8.0.sw
|
|
4536
5074
|
*/
|
|
4537
5075
|
hideSampleQuestions?: boolean;
|
|
4538
5076
|
/**
|
|
4539
|
-
* The data source GUID to set on load.
|
|
5077
|
+
* The data source GUID (Worksheet GUID) to set on load.
|
|
4540
5078
|
*/
|
|
4541
5079
|
dataSource?: string;
|
|
4542
5080
|
/**
|
|
4543
|
-
*
|
|
5081
|
+
* Includes the following properties:
|
|
4544
5082
|
*
|
|
4545
|
-
*
|
|
5083
|
+
* `searchQuery`: The search query string to pass in the search bar.
|
|
5084
|
+
* Supports Natural Language Search queries.
|
|
5085
|
+
*
|
|
5086
|
+
* `executeSearch`: Boolean to define if the search should be executed or not.
|
|
5087
|
+
* If it is executed, the focus is placed on the results.
|
|
5088
|
+
* If it’s not executed, the focus is placed at the end of
|
|
5089
|
+
* the token string in the search bar.
|
|
5090
|
+
*
|
|
5091
|
+
* @example
|
|
5092
|
+
* ```js
|
|
5093
|
+
* searchOptions: {
|
|
5094
|
+
* searchQuery: 'average sales by country and product type',
|
|
5095
|
+
* executeSearch: true,
|
|
5096
|
+
* }
|
|
5097
|
+
* ```
|
|
5098
|
+
* @version SDK: 1.26.0 | Thoughtspot: 9.8.0.cl, 9.8.0.sw
|
|
4546
5099
|
*/
|
|
4547
5100
|
searchOptions?: SearchOptions;
|
|
4548
5101
|
}
|
|
4549
5102
|
export const HiddenActionItemByDefaultForSageEmbed: Action[];
|
|
4550
5103
|
/**
|
|
4551
|
-
* Embed ThoughtSpot LLM and GPT
|
|
5104
|
+
* Embed ThoughtSpot LLM and GPT-based Natural Language Search component.
|
|
4552
5105
|
*
|
|
4553
5106
|
* @version: SDK: 1.23.0 | ThoughtSpot: 9.4.0.cl, 9.5.1-sw
|
|
4554
5107
|
* @group Embed components
|
|
@@ -4568,6 +5121,13 @@ export class SageEmbed extends V1Embed {
|
|
|
4568
5121
|
* @returns {string} query string
|
|
4569
5122
|
*/
|
|
4570
5123
|
protected getEmbedParams(): string;
|
|
5124
|
+
/**
|
|
5125
|
+
* Construct the URL of the embedded ThoughtSpot sage to be
|
|
5126
|
+
* loaded in the iframe
|
|
5127
|
+
*
|
|
5128
|
+
* @returns {string} iframe url
|
|
5129
|
+
*/
|
|
5130
|
+
getIFrameSrc(): string;
|
|
4571
5131
|
/**
|
|
4572
5132
|
* Render the embedded ThoughtSpot Sage
|
|
4573
5133
|
*
|
|
@@ -4607,8 +5167,7 @@ interface UnderlyingDataPoint {
|
|
|
4607
5167
|
* const data = await underlying.fetchData(0, 100);
|
|
4608
5168
|
* })
|
|
4609
5169
|
* ```
|
|
4610
|
-
* @version
|
|
4611
|
-
* ThoughtSpot: 9.9.0.cl / SDK: 1.25.0
|
|
5170
|
+
* @version SDK: 1.25.0| ThoughtSpot: 9.10.0.cl
|
|
4612
5171
|
* @group Events
|
|
4613
5172
|
*/
|
|
4614
5173
|
export class AnswerService {
|
|
@@ -4642,8 +5201,7 @@ export class AnswerService {
|
|
|
4642
5201
|
* const data = await underlying.fetchData(0, 100);
|
|
4643
5202
|
* })
|
|
4644
5203
|
* ```
|
|
4645
|
-
* @version
|
|
4646
|
-
* ThoughtSpot: 9.9.0.cl / SDK: 1.25.0
|
|
5204
|
+
* @version SDK: 1.25.0| ThoughtSpot: 9.10.0.cl
|
|
4647
5205
|
*/
|
|
4648
5206
|
getUnderlyingDataForPoint(outputColumnNames: string[], selectedPoints?: UnderlyingDataPoint[]): Promise<AnswerService>;
|
|
4649
5207
|
executeQuery(query: string, variables: any): Promise<any>;
|
|
@@ -4862,6 +5420,7 @@ export class TsEmbed {
|
|
|
4862
5420
|
* @param args
|
|
4863
5421
|
*/
|
|
4864
5422
|
render(): TsEmbed;
|
|
5423
|
+
getIframeSrc(): string;
|
|
4865
5424
|
protected handleRenderForPrerender(): void;
|
|
4866
5425
|
/**
|
|
4867
5426
|
* Creates the preRender shell
|