@thoughtspot/visual-embed-sdk 1.46.5-beta.1 → 1.46.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/cjs/package.json +4 -4
- package/cjs/src/css-variables.d.ts +36 -0
- package/cjs/src/css-variables.d.ts.map +1 -1
- package/cjs/src/embed/app.d.ts +41 -2
- package/cjs/src/embed/app.d.ts.map +1 -1
- package/cjs/src/embed/app.js +26 -46
- package/cjs/src/embed/app.js.map +1 -1
- package/cjs/src/embed/app.spec.js +36 -69
- package/cjs/src/embed/app.spec.js.map +1 -1
- package/cjs/src/embed/conversation.d.ts +23 -1
- package/cjs/src/embed/conversation.d.ts.map +1 -1
- package/cjs/src/embed/conversation.js +18 -33
- package/cjs/src/embed/conversation.js.map +1 -1
- package/cjs/src/embed/conversation.spec.js +129 -97
- package/cjs/src/embed/conversation.spec.js.map +1 -1
- package/cjs/src/embed/hostEventClient/contracts.d.ts +31 -0
- package/cjs/src/embed/hostEventClient/contracts.d.ts.map +1 -1
- package/cjs/src/embed/hostEventClient/contracts.js +2 -0
- package/cjs/src/embed/hostEventClient/contracts.js.map +1 -1
- package/cjs/src/embed/hostEventClient/host-event-client.d.ts +18 -0
- package/cjs/src/embed/hostEventClient/host-event-client.d.ts.map +1 -1
- package/cjs/src/embed/hostEventClient/host-event-client.js +69 -9
- package/cjs/src/embed/hostEventClient/host-event-client.js.map +1 -1
- package/cjs/src/embed/hostEventClient/host-event-client.spec.js +185 -19
- package/cjs/src/embed/hostEventClient/host-event-client.spec.js.map +1 -1
- package/cjs/src/embed/hostEventClient/utils.d.ts +22 -0
- package/cjs/src/embed/hostEventClient/utils.d.ts.map +1 -0
- package/cjs/src/embed/hostEventClient/utils.js +51 -0
- package/cjs/src/embed/hostEventClient/utils.js.map +1 -0
- package/cjs/src/embed/hostEventClient/utils.spec.d.ts +2 -0
- package/cjs/src/embed/hostEventClient/utils.spec.d.ts.map +1 -0
- package/cjs/src/embed/hostEventClient/utils.spec.js +115 -0
- package/cjs/src/embed/hostEventClient/utils.spec.js.map +1 -0
- package/cjs/src/embed/liveboard.d.ts +18 -1
- package/cjs/src/embed/liveboard.d.ts.map +1 -1
- package/cjs/src/embed/liveboard.js +9 -11
- package/cjs/src/embed/liveboard.js.map +1 -1
- package/cjs/src/embed/liveboard.spec.js +29 -71
- package/cjs/src/embed/liveboard.spec.js.map +1 -1
- package/cjs/src/embed/spotter-utils.d.ts +20 -0
- package/cjs/src/embed/spotter-utils.d.ts.map +1 -0
- package/cjs/src/embed/spotter-utils.js +52 -0
- package/cjs/src/embed/spotter-utils.js.map +1 -0
- package/cjs/src/embed/spotter-utils.spec.d.ts +2 -0
- package/cjs/src/embed/spotter-utils.spec.d.ts.map +1 -0
- package/cjs/src/embed/spotter-utils.spec.js +54 -0
- package/cjs/src/embed/spotter-utils.spec.js.map +1 -0
- package/cjs/src/embed/ts-embed.d.ts.map +1 -1
- package/cjs/src/embed/ts-embed.js +13 -1
- package/cjs/src/embed/ts-embed.js.map +1 -1
- package/cjs/src/errors.d.ts +2 -0
- package/cjs/src/errors.d.ts.map +1 -1
- package/cjs/src/errors.js +2 -0
- package/cjs/src/errors.js.map +1 -1
- package/cjs/src/types.d.ts +102 -1
- package/cjs/src/types.d.ts.map +1 -1
- package/cjs/src/types.js +101 -0
- package/cjs/src/types.js.map +1 -1
- package/cjs/src/utils.d.ts +0 -9
- package/cjs/src/utils.d.ts.map +1 -1
- package/cjs/src/utils.js +1 -10
- package/cjs/src/utils.js.map +1 -1
- package/dist/index-ChNydfIz.js +7371 -0
- package/dist/index-DGV_zh53.js +7371 -0
- package/dist/src/css-variables.d.ts +36 -0
- package/dist/src/css-variables.d.ts.map +1 -1
- package/dist/src/embed/app.d.ts +41 -2
- package/dist/src/embed/app.d.ts.map +1 -1
- package/dist/src/embed/conversation.d.ts +23 -1
- package/dist/src/embed/conversation.d.ts.map +1 -1
- package/dist/src/embed/hostEventClient/contracts.d.ts +31 -0
- package/dist/src/embed/hostEventClient/contracts.d.ts.map +1 -1
- package/dist/src/embed/hostEventClient/host-event-client.d.ts +18 -0
- package/dist/src/embed/hostEventClient/host-event-client.d.ts.map +1 -1
- package/dist/src/embed/hostEventClient/utils.d.ts +22 -0
- package/dist/src/embed/hostEventClient/utils.d.ts.map +1 -0
- package/dist/src/embed/hostEventClient/utils.spec.d.ts +2 -0
- package/dist/src/embed/hostEventClient/utils.spec.d.ts.map +1 -0
- package/dist/src/embed/liveboard.d.ts +18 -1
- package/dist/src/embed/liveboard.d.ts.map +1 -1
- package/dist/src/embed/spotter-utils.d.ts +20 -0
- package/dist/src/embed/spotter-utils.d.ts.map +1 -0
- package/dist/src/embed/spotter-utils.spec.d.ts +2 -0
- package/dist/src/embed/spotter-utils.spec.d.ts.map +1 -0
- package/dist/src/embed/ts-embed.d.ts.map +1 -1
- package/dist/src/errors.d.ts +2 -0
- package/dist/src/errors.d.ts.map +1 -1
- package/dist/src/types.d.ts +102 -1
- package/dist/src/types.d.ts.map +1 -1
- package/dist/src/utils.d.ts +0 -9
- package/dist/src/utils.d.ts.map +1 -1
- package/dist/tsembed-react.es.js +324 -110
- package/dist/tsembed-react.js +323 -109
- package/dist/tsembed.es.js +324 -110
- package/dist/tsembed.js +323 -109
- package/dist/visual-embed-sdk-react-full.d.ts +266 -3
- package/dist/visual-embed-sdk-react.d.ts +266 -3
- package/dist/visual-embed-sdk.d.ts +266 -3
- package/lib/package.json +4 -4
- package/lib/src/css-variables.d.ts +36 -0
- package/lib/src/css-variables.d.ts.map +1 -1
- package/lib/src/embed/app.d.ts +41 -2
- package/lib/src/embed/app.d.ts.map +1 -1
- package/lib/src/embed/app.js +28 -48
- package/lib/src/embed/app.js.map +1 -1
- package/lib/src/embed/app.spec.js +36 -69
- package/lib/src/embed/app.spec.js.map +1 -1
- package/lib/src/embed/conversation.d.ts +23 -1
- package/lib/src/embed/conversation.d.ts.map +1 -1
- package/lib/src/embed/conversation.js +19 -34
- package/lib/src/embed/conversation.js.map +1 -1
- package/lib/src/embed/conversation.spec.js +131 -99
- package/lib/src/embed/conversation.spec.js.map +1 -1
- package/lib/src/embed/hostEventClient/contracts.d.ts +31 -0
- package/lib/src/embed/hostEventClient/contracts.d.ts.map +1 -1
- package/lib/src/embed/hostEventClient/contracts.js +2 -0
- package/lib/src/embed/hostEventClient/contracts.js.map +1 -1
- package/lib/src/embed/hostEventClient/host-event-client.d.ts +18 -0
- package/lib/src/embed/hostEventClient/host-event-client.d.ts.map +1 -1
- package/lib/src/embed/hostEventClient/host-event-client.js +69 -9
- package/lib/src/embed/hostEventClient/host-event-client.js.map +1 -1
- package/lib/src/embed/hostEventClient/host-event-client.spec.js +185 -19
- package/lib/src/embed/hostEventClient/host-event-client.spec.js.map +1 -1
- package/lib/src/embed/hostEventClient/utils.d.ts +22 -0
- package/lib/src/embed/hostEventClient/utils.d.ts.map +1 -0
- package/lib/src/embed/hostEventClient/utils.js +43 -0
- package/lib/src/embed/hostEventClient/utils.js.map +1 -0
- package/lib/src/embed/hostEventClient/utils.spec.d.ts +2 -0
- package/lib/src/embed/hostEventClient/utils.spec.d.ts.map +1 -0
- package/lib/src/embed/hostEventClient/utils.spec.js +113 -0
- package/lib/src/embed/hostEventClient/utils.spec.js.map +1 -0
- package/lib/src/embed/liveboard.d.ts +18 -1
- package/lib/src/embed/liveboard.d.ts.map +1 -1
- package/lib/src/embed/liveboard.js +9 -11
- package/lib/src/embed/liveboard.js.map +1 -1
- package/lib/src/embed/liveboard.spec.js +29 -71
- package/lib/src/embed/liveboard.spec.js.map +1 -1
- package/lib/src/embed/spotter-utils.d.ts +20 -0
- package/lib/src/embed/spotter-utils.d.ts.map +1 -0
- package/lib/src/embed/spotter-utils.js +47 -0
- package/lib/src/embed/spotter-utils.js.map +1 -0
- package/lib/src/embed/spotter-utils.spec.d.ts +2 -0
- package/lib/src/embed/spotter-utils.spec.d.ts.map +1 -0
- package/lib/src/embed/spotter-utils.spec.js +52 -0
- package/lib/src/embed/spotter-utils.spec.js.map +1 -0
- package/lib/src/embed/ts-embed.d.ts.map +1 -1
- package/lib/src/embed/ts-embed.js +13 -1
- package/lib/src/embed/ts-embed.js.map +1 -1
- package/lib/src/errors.d.ts +2 -0
- package/lib/src/errors.d.ts.map +1 -1
- package/lib/src/errors.js +2 -0
- package/lib/src/errors.js.map +1 -1
- package/lib/src/types.d.ts +102 -1
- package/lib/src/types.d.ts.map +1 -1
- package/lib/src/types.js +101 -0
- package/lib/src/types.js.map +1 -1
- package/lib/src/utils.d.ts +0 -9
- package/lib/src/utils.d.ts.map +1 -1
- package/lib/src/utils.js +0 -8
- package/lib/src/utils.js.map +1 -1
- package/lib/src/visual-embed-sdk.d.ts +266 -3
- package/package.json +4 -4
- package/src/css-variables.ts +45 -0
- package/src/embed/app.spec.ts +51 -92
- package/src/embed/app.ts +60 -64
- package/src/embed/conversation.spec.ts +150 -119
- package/src/embed/conversation.ts +30 -54
- package/src/embed/hostEventClient/contracts.ts +31 -0
- package/src/embed/hostEventClient/host-event-client.spec.ts +260 -19
- package/src/embed/hostEventClient/host-event-client.ts +87 -11
- package/src/embed/hostEventClient/utils.spec.ts +137 -0
- package/src/embed/hostEventClient/utils.ts +61 -0
- package/src/embed/liveboard.spec.ts +38 -93
- package/src/embed/liveboard.ts +28 -10
- package/src/embed/spotter-utils.spec.ts +56 -0
- package/src/embed/spotter-utils.ts +65 -0
- package/src/embed/ts-embed.ts +15 -1
- package/src/errors.ts +2 -0
- package/src/types.ts +104 -0
- package/src/utils.ts +0 -14
|
@@ -785,6 +785,42 @@ export interface CustomCssVariables {
|
|
|
785
785
|
* Color for section title text (e.g., "Recent", "Older") in the saved chats sidebar.
|
|
786
786
|
*/
|
|
787
787
|
"--ts-var-saved-chats-section-title-color"?: string;
|
|
788
|
+
/**
|
|
789
|
+
* Text color of the styling panel in the Liveboard.
|
|
790
|
+
*/
|
|
791
|
+
"--ts-var-liveboard-styling-panel-text-color"?: string;
|
|
792
|
+
/**
|
|
793
|
+
* Border color of the styling panel in the Liveboard.
|
|
794
|
+
*/
|
|
795
|
+
"--ts-var-liveboard-styling-panel-border-color"?: string;
|
|
796
|
+
/**
|
|
797
|
+
* Background color of the styling button in the Liveboard.
|
|
798
|
+
*/
|
|
799
|
+
"--ts-var-liveboard-styling-button-background"?: string;
|
|
800
|
+
/**
|
|
801
|
+
* Text color of the styling button in the Liveboard.
|
|
802
|
+
*/
|
|
803
|
+
"--ts-var-liveboard-styling-button-text-color"?: string;
|
|
804
|
+
/**
|
|
805
|
+
* Background color of the styling button in the Liveboard on hover.
|
|
806
|
+
*/
|
|
807
|
+
"--ts-var-liveboard-styling-button-hover-background"?: string;
|
|
808
|
+
/**
|
|
809
|
+
* Background color of the styling button in the Liveboard when active.
|
|
810
|
+
*/
|
|
811
|
+
"--ts-var-liveboard-styling-button-active-background"?: string;
|
|
812
|
+
/**
|
|
813
|
+
* Text color of the styling button in the Liveboard on hover.
|
|
814
|
+
*/
|
|
815
|
+
"--ts-var-liveboard-styling-button-hover-text-color"?: string;
|
|
816
|
+
/**
|
|
817
|
+
* Box shadow of the styling button in the Liveboard.
|
|
818
|
+
*/
|
|
819
|
+
"--ts-var-liveboard-styling-button-shadow"?: string;
|
|
820
|
+
/**
|
|
821
|
+
* Background color of the color palette in the Liveboard styling panel.
|
|
822
|
+
*/
|
|
823
|
+
"--ts-var-liveboard-styling-color-palette-background"?: string;
|
|
788
824
|
}
|
|
789
825
|
export interface SessionInterface {
|
|
790
826
|
sessionId: string;
|
|
@@ -3573,6 +3609,17 @@ export declare enum EmbedEvent {
|
|
|
3573
3609
|
* ```
|
|
3574
3610
|
*/
|
|
3575
3611
|
DownloadAsXlsx = "downloadAsXlsx",
|
|
3612
|
+
/**
|
|
3613
|
+
* Emitted when the Download Liveboard as Continuous PDF action is triggered
|
|
3614
|
+
* on a Liveboard.
|
|
3615
|
+
* @version SDK: 1.48.0 | ThoughtSpot: 26.5.0.cl
|
|
3616
|
+
* @example
|
|
3617
|
+
* ```js
|
|
3618
|
+
* liveboardEmbed.on(EmbedEvent.DownloadLiveboardAsContinuousPDF, payload => {
|
|
3619
|
+
* console.log('download liveboard as continuous PDF', payload)})
|
|
3620
|
+
* ```
|
|
3621
|
+
*/
|
|
3622
|
+
DownloadLiveboardAsContinuousPDF = "downloadLiveboardAsContinuousPDF",
|
|
3576
3623
|
/**
|
|
3577
3624
|
* Emitted when an Answer is deleted in the app
|
|
3578
3625
|
* Use start:true to subscribe to when delete is initiated, or end:true to subscribe
|
|
@@ -5100,6 +5147,18 @@ export declare enum HostEvent {
|
|
|
5100
5147
|
* @version SDK: 1.15.0 | ThoughtSpot: 8.7.0.cl, 8.8.1.sw
|
|
5101
5148
|
*/
|
|
5102
5149
|
DownloadAsPdf = "downloadAsPdf",
|
|
5150
|
+
/**
|
|
5151
|
+
* Trigger the **Download Liveboard as Continuous PDF** action on an
|
|
5152
|
+
* embedded Liveboard.
|
|
5153
|
+
*
|
|
5154
|
+
* @example
|
|
5155
|
+
* ```js
|
|
5156
|
+
* liveboardEmbed.trigger(HostEvent.DownloadLiveboardAsContinuousPDF)
|
|
5157
|
+
* ```
|
|
5158
|
+
*
|
|
5159
|
+
* @version SDK: 1.48.0 | ThoughtSpot: 26.5.0.cl
|
|
5160
|
+
*/
|
|
5161
|
+
DownloadLiveboardAsContinuousPDF = "downloadLiveboardAsContinuousPDF",
|
|
5103
5162
|
/**
|
|
5104
5163
|
* Trigger the **AI Highlights** action on an embedded Liveboard
|
|
5105
5164
|
*
|
|
@@ -5326,6 +5385,20 @@ export declare enum HostEvent {
|
|
|
5326
5385
|
* vizId: '730496d6-6903-4601-937e-2c691821af3c'
|
|
5327
5386
|
* }, ContextType.Liveboard);
|
|
5328
5387
|
* ```
|
|
5388
|
+
* @example
|
|
5389
|
+
* ```js
|
|
5390
|
+
* // Copy link from liveboard context
|
|
5391
|
+
* import { ContextType } from '@thoughtspot/visual-embed-sdk';
|
|
5392
|
+
* liveboardEmbed.trigger(HostEvent.CopyLink, {}, ContextType.Liveboard);
|
|
5393
|
+
* ```
|
|
5394
|
+
* @example
|
|
5395
|
+
* ```js
|
|
5396
|
+
* // Copy link from liveboard visualization context
|
|
5397
|
+
* import { ContextType } from '@thoughtspot/visual-embed-sdk';
|
|
5398
|
+
* liveboardEmbed.trigger(HostEvent.CopyLink, {
|
|
5399
|
+
* vizId: '730496d6-6903-4601-937e-2c691821af3c'
|
|
5400
|
+
* }, ContextType.Liveboard);
|
|
5401
|
+
* ```
|
|
5329
5402
|
* @version SDK: 1.15.0 | ThoughtSpot: 8.7.0.cl, 8.8.1.sw
|
|
5330
5403
|
*/
|
|
5331
5404
|
CopyLink = "embedDocument",
|
|
@@ -5357,6 +5430,20 @@ export declare enum HostEvent {
|
|
|
5357
5430
|
* import { ContextType } from '@thoughtspot/visual-embed-sdk';
|
|
5358
5431
|
* liveboardEmbed.trigger(HostEvent.Present, {}, ContextType.Liveboard);
|
|
5359
5432
|
* ```
|
|
5433
|
+
* @example
|
|
5434
|
+
* ```js
|
|
5435
|
+
* // Present from liveboard visualization context
|
|
5436
|
+
* import { ContextType } from '@thoughtspot/visual-embed-sdk';
|
|
5437
|
+
* liveboardEmbed.trigger(HostEvent.Present, {
|
|
5438
|
+
* vizId: '730496d6-6903-4601-937e-2c691821af3c'
|
|
5439
|
+
* }, ContextType.Liveboard);
|
|
5440
|
+
* ```
|
|
5441
|
+
* @example
|
|
5442
|
+
* ```js
|
|
5443
|
+
* // Present from liveboard context
|
|
5444
|
+
* import { ContextType } from '@thoughtspot/visual-embed-sdk';
|
|
5445
|
+
* liveboardEmbed.trigger(HostEvent.Present, {}, ContextType.Liveboard);
|
|
5446
|
+
* ```
|
|
5360
5447
|
* @version SDK: 1.15.0 | ThoughtSpot: 8.7.0.cl, 8.8.1.sw
|
|
5361
5448
|
*/
|
|
5362
5449
|
Present = "present",
|
|
@@ -6824,6 +6911,16 @@ export declare enum Action {
|
|
|
6824
6911
|
* @version SDK: 1.46.0 | ThoughtSpot: 26.3.0.cl
|
|
6825
6912
|
*/
|
|
6826
6913
|
DownloadLiveboard = "downloadLiveboard",
|
|
6914
|
+
/**
|
|
6915
|
+
* The **Download Liveboard as Continuous PDF** menu action on a Liveboard.
|
|
6916
|
+
* Allows downloading the entire Liveboard as a continuous PDF.
|
|
6917
|
+
* @example
|
|
6918
|
+
* ```js
|
|
6919
|
+
* disabledActions: [Action.DownloadLiveboardAsContinuousPDF]
|
|
6920
|
+
* ```
|
|
6921
|
+
* @version SDK: 1.48.0 | ThoughtSpot: 26.5.0.cl
|
|
6922
|
+
*/
|
|
6923
|
+
DownloadLiveboardAsContinuousPDF = "downloadLiveboardAsContinuousPDF",
|
|
6827
6924
|
/**
|
|
6828
6925
|
* @hidden
|
|
6829
6926
|
*/
|
|
@@ -8039,6 +8136,39 @@ export declare enum Action {
|
|
|
8039
8136
|
* @version SDK: 1.46.0 | ThoughtSpot Cloud: 26.3.0.cl
|
|
8040
8137
|
*/
|
|
8041
8138
|
SpotterDocs = "spotterDocs",
|
|
8139
|
+
/**
|
|
8140
|
+
* Controls visibility and disable state of the connector resources
|
|
8141
|
+
* section in the Spotter chat interface.
|
|
8142
|
+
* @example
|
|
8143
|
+
* ```js
|
|
8144
|
+
* hiddenActions: [Action.SpotterChatConnectorResources]
|
|
8145
|
+
* disabledActions: [Action.SpotterChatConnectorResources]
|
|
8146
|
+
* ```
|
|
8147
|
+
* @version SDK: 1.48.0 | ThoughtSpot Cloud: 26.5.0.cl
|
|
8148
|
+
*/
|
|
8149
|
+
SpotterChatConnectorResources = "spotterChatConnectorResources",
|
|
8150
|
+
/**
|
|
8151
|
+
* Controls visibility and disable state of the connectors
|
|
8152
|
+
* in the Spotter chat interface.
|
|
8153
|
+
* @example
|
|
8154
|
+
* ```js
|
|
8155
|
+
* hiddenActions: [Action.SpotterChatConnectors]
|
|
8156
|
+
* disabledActions: [Action.SpotterChatConnectors]
|
|
8157
|
+
* ```
|
|
8158
|
+
* @version SDK: 1.48.0 | ThoughtSpot Cloud: 26.5.0.cl
|
|
8159
|
+
*/
|
|
8160
|
+
SpotterChatConnectors = "spotterChatConnectors",
|
|
8161
|
+
/**
|
|
8162
|
+
* Controls visibility and disable state of the mode switcher
|
|
8163
|
+
* in the Spotter chat interface.
|
|
8164
|
+
* @example
|
|
8165
|
+
* ```js
|
|
8166
|
+
* hiddenActions: [Action.SpotterChatModeSwitcher]
|
|
8167
|
+
* disabledActions: [Action.SpotterChatModeSwitcher]
|
|
8168
|
+
* ```
|
|
8169
|
+
* @version SDK: 1.48.0 | ThoughtSpot Cloud: 26.5.0.cl
|
|
8170
|
+
*/
|
|
8171
|
+
SpotterChatModeSwitcher = "spotterChatModeSwitcher",
|
|
8042
8172
|
/**
|
|
8043
8173
|
* The **Include current period** checkbox for date filters.
|
|
8044
8174
|
* Controls the visibility and availability of the option to include
|
|
@@ -8283,7 +8413,13 @@ declare enum EmbedErrorCodes {
|
|
|
8283
8413
|
/** Failed to update embed parameters during pre-render */
|
|
8284
8414
|
UPDATE_PARAMS_FAILED = "UPDATE_PARAMS_FAILED",
|
|
8285
8415
|
/** Invalid URL provided in configuration */
|
|
8286
|
-
INVALID_URL = "INVALID_URL"
|
|
8416
|
+
INVALID_URL = "INVALID_URL",
|
|
8417
|
+
/** Host event payload validation failed */
|
|
8418
|
+
HOST_EVENT_VALIDATION = "HOST_EVENT_VALIDATION",
|
|
8419
|
+
/** UpdateFilters payload is invalid - missing or malformed filter/filters */
|
|
8420
|
+
UPDATEFILTERS_INVALID_PAYLOAD = "UPDATEFILTERS_INVALID_PAYLOAD",
|
|
8421
|
+
/** DrillDown payload is invalid - missing or malformed points */
|
|
8422
|
+
DRILLDOWN_INVALID_PAYLOAD = "DRILLDOWN_INVALID_PAYLOAD"
|
|
8287
8423
|
}
|
|
8288
8424
|
/**
|
|
8289
8425
|
* Error event object emitted when an error occurs in an embedded component.
|
|
@@ -8656,6 +8792,8 @@ declare enum UIPassthroughEvent {
|
|
|
8656
8792
|
GetAnswerConfig = "getAnswerPageConfig",
|
|
8657
8793
|
GetLiveboardConfig = "getPinboardPageConfig",
|
|
8658
8794
|
GetUnsavedAnswerTML = "getUnsavedAnswerTML",
|
|
8795
|
+
UpdateFilters = "updateFilters",
|
|
8796
|
+
Drilldown = "drillDown",
|
|
8659
8797
|
GetAnswerSession = "getAnswerSession",
|
|
8660
8798
|
GetFilters = "getFilters",
|
|
8661
8799
|
GetIframeUrl = "getIframeUrl",
|
|
@@ -8777,6 +8915,35 @@ export type UIPassthroughContractBase = {
|
|
|
8777
8915
|
v2Content: string;
|
|
8778
8916
|
};
|
|
8779
8917
|
};
|
|
8918
|
+
[UIPassthroughEvent.UpdateFilters]: {
|
|
8919
|
+
request: {
|
|
8920
|
+
filter?: {
|
|
8921
|
+
column: string;
|
|
8922
|
+
oper: string;
|
|
8923
|
+
values: string[];
|
|
8924
|
+
type?: string;
|
|
8925
|
+
};
|
|
8926
|
+
filters?: {
|
|
8927
|
+
column: string;
|
|
8928
|
+
oper: string;
|
|
8929
|
+
values: string[];
|
|
8930
|
+
type?: string;
|
|
8931
|
+
}[];
|
|
8932
|
+
};
|
|
8933
|
+
response: unknown;
|
|
8934
|
+
};
|
|
8935
|
+
[UIPassthroughEvent.Drilldown]: {
|
|
8936
|
+
request: {
|
|
8937
|
+
points: {
|
|
8938
|
+
selectedPoints?: string[];
|
|
8939
|
+
clickedPoint?: string;
|
|
8940
|
+
};
|
|
8941
|
+
columnGuid?: string;
|
|
8942
|
+
autoDrillDown?: boolean;
|
|
8943
|
+
vizId?: string;
|
|
8944
|
+
};
|
|
8945
|
+
response: unknown;
|
|
8946
|
+
};
|
|
8780
8947
|
};
|
|
8781
8948
|
export type UIPassthroughRequest<T extends keyof UIPassthroughContractBase> = UIPassthroughContractBase[T]["request"];
|
|
8782
8949
|
export type UIPassthroughResponse<T extends keyof UIPassthroughContractBase> = UIPassthroughContractBase[T]["response"];
|
|
@@ -8802,6 +8969,8 @@ export type TriggerPayload<PayloadT, HostEventT extends HostEvent> = PayloadT |
|
|
|
8802
8969
|
export type TriggerResponse<PayloadT, HostEventT extends HostEvent, ContextT extends ContextType> = PayloadT extends HostEventRequest<HostEventT> ? HostEventResponse<HostEventT, ContextT> : any;
|
|
8803
8970
|
declare class HostEventClient {
|
|
8804
8971
|
iFrame: HTMLIFrameElement;
|
|
8972
|
+
/** Cached list of available UI passthrough keys from the embedded app */
|
|
8973
|
+
private availablePassthroughKeysCache;
|
|
8805
8974
|
/** Host events with custom handlers
|
|
8806
8975
|
* (setters or special logic) -
|
|
8807
8976
|
* bound to instance for protected method access */
|
|
@@ -8827,9 +8996,25 @@ declare class HostEventClient {
|
|
|
8827
8996
|
* @param {HTMLIFrameElement} iFrame - the iframe element to set
|
|
8828
8997
|
*/
|
|
8829
8998
|
setIframeElement(iFrame: HTMLIFrameElement): void;
|
|
8999
|
+
/**
|
|
9000
|
+
* Fetches the list of available UI passthrough keys from the embedded app.
|
|
9001
|
+
* Result is cached for the session. Returns empty array on failure.
|
|
9002
|
+
*/
|
|
9003
|
+
private getAvailableUIPassthroughKeys;
|
|
8830
9004
|
triggerUIPassthroughApi<UIPassthroughEventT extends UIPassthroughEvent>(apiName: UIPassthroughEventT, parameters: UIPassthroughRequest<UIPassthroughEventT>, context?: ContextType): Promise<UIPassthroughArrayResponse<UIPassthroughEventT>>;
|
|
8831
9005
|
protected handlePinEvent(payload: HostEventRequest<HostEvent.Pin>, context?: ContextType): Promise<HostEventResponse<HostEvent.Pin, ContextType>>;
|
|
8832
9006
|
protected handleSaveAnswerEvent(payload: HostEventRequest<HostEvent.SaveAnswer>, context?: ContextType): Promise<any>;
|
|
9007
|
+
protected handleUpdateFiltersEvent(payload: HostEventRequest<HostEvent.UpdateFilters>, context?: ContextType): Promise<any>;
|
|
9008
|
+
protected handleDrillDownEvent(payload: HostEventRequest<HostEvent.DrillDown>, context?: ContextType): Promise<any>;
|
|
9009
|
+
/**
|
|
9010
|
+
* Dispatches a host event using the appropriate channel:
|
|
9011
|
+
* 1. If the embedded app supports UI passthrough for this event, use it (custom handler or getter).
|
|
9012
|
+
* 2. Otherwise fall back to the legacy host event channel.
|
|
9013
|
+
*
|
|
9014
|
+
* @param hostEvent - The host event to trigger
|
|
9015
|
+
* @param payload - Optional payload for the event
|
|
9016
|
+
* @param context - Optional context (e.g. vizId) for scoped operations
|
|
9017
|
+
*/
|
|
8833
9018
|
triggerHostEvent<HostEventT extends HostEvent, PayloadT, ContextT extends ContextType>(hostEvent: HostEventT, payload?: TriggerPayload<PayloadT, HostEventT>, context?: ContextT): Promise<TriggerResponse<PayloadT, HostEventT, ContextType>>;
|
|
8834
9019
|
}
|
|
8835
9020
|
declare class TsEmbed {
|
|
@@ -10251,9 +10436,31 @@ export interface SpotterEmbedViewConfig extends Omit<BaseViewConfig, "primaryAct
|
|
|
10251
10436
|
*/
|
|
10252
10437
|
export interface ConversationViewConfig extends SpotterEmbedViewConfig {
|
|
10253
10438
|
}
|
|
10439
|
+
/**
|
|
10440
|
+
* APP_INIT data shape for SpotterEmbed.
|
|
10441
|
+
* @internal
|
|
10442
|
+
*/
|
|
10443
|
+
export interface SpotterAppInitData extends DefaultAppInitData {
|
|
10444
|
+
embedParams?: {
|
|
10445
|
+
spotterSidebarConfig?: SpotterSidebarViewConfig;
|
|
10446
|
+
};
|
|
10447
|
+
}
|
|
10254
10448
|
declare class SpotterEmbed extends TsEmbed {
|
|
10255
10449
|
protected viewConfig: SpotterEmbedViewConfig;
|
|
10256
10450
|
constructor(container: HTMLElement, viewConfig: SpotterEmbedViewConfig);
|
|
10451
|
+
/**
|
|
10452
|
+
* Extends the default APP_INIT payload with `embedParams.spotterSidebarConfig`
|
|
10453
|
+
* so the conv-assist app can read sidebar configuration on initialisation.
|
|
10454
|
+
*
|
|
10455
|
+
* Precedence for `enablePastConversationsSidebar`:
|
|
10456
|
+
* `spotterSidebarConfig.enablePastConversationsSidebar` wins over the
|
|
10457
|
+
* deprecated top-level `enablePastConversationsSidebar` flag; if the former
|
|
10458
|
+
* is absent the latter is used as a fallback.
|
|
10459
|
+
*
|
|
10460
|
+
* An invalid `spotterDocumentationUrl` triggers a validation error and is
|
|
10461
|
+
* excluded from the payload rather than forwarded to the app.
|
|
10462
|
+
*/
|
|
10463
|
+
protected getAppInitData(): Promise<SpotterAppInitData>;
|
|
10257
10464
|
protected getEmbedParamsObject(): Record<any, any>;
|
|
10258
10465
|
getIframeSrc(): string;
|
|
10259
10466
|
render(): Promise<SpotterEmbed>;
|
|
@@ -10798,6 +11005,24 @@ export interface AppViewConfig extends AllEmbedViewConfig {
|
|
|
10798
11005
|
* ```
|
|
10799
11006
|
*/
|
|
10800
11007
|
isPNGInScheduledEmailsEnabled?: boolean;
|
|
11008
|
+
/**
|
|
11009
|
+
* Enables the 'what you see is what you get' PDF export for Liveboards. Each tab is rendered on a single page
|
|
11010
|
+
* following the exact UI layout, instead of splitting visualizations across multiple A4 pages.
|
|
11011
|
+
* This feature is GA from version 26.5.0.cl and is enabled by default on embed deployments.
|
|
11012
|
+
*
|
|
11013
|
+
* Supported embed types: `AppEmbed`, `LiveboardEmbed`
|
|
11014
|
+
* @type {boolean}
|
|
11015
|
+
* @version SDK: 1.48.0 | ThoughtSpot: 26.5.0.cl
|
|
11016
|
+
* @example
|
|
11017
|
+
* ```js
|
|
11018
|
+
* // Replace <EmbedComponent> with embed component name. For example, AppEmbed or LiveboardEmbed
|
|
11019
|
+
* const embed = new <EmbedComponent>('#tsEmbed', {
|
|
11020
|
+
* ... // other embed view config
|
|
11021
|
+
* isContinuousLiveboardPDFEnabled: true,
|
|
11022
|
+
* })
|
|
11023
|
+
* ```
|
|
11024
|
+
*/
|
|
11025
|
+
isContinuousLiveboardPDFEnabled?: boolean;
|
|
10801
11026
|
/**
|
|
10802
11027
|
* This flag is used to enable/disable the XLSX/CSV download option for Liveboards
|
|
10803
11028
|
*
|
|
@@ -10966,10 +11191,32 @@ export interface AppViewConfig extends AllEmbedViewConfig {
|
|
|
10966
11191
|
*/
|
|
10967
11192
|
enableHomepageAnnouncement?: boolean;
|
|
10968
11193
|
}
|
|
11194
|
+
/**
|
|
11195
|
+
* APP_INIT data shape for AppEmbed.
|
|
11196
|
+
* @internal
|
|
11197
|
+
*/
|
|
11198
|
+
export interface AppEmbedAppInitData extends DefaultAppInitData {
|
|
11199
|
+
embedParams?: {
|
|
11200
|
+
spotterSidebarConfig?: SpotterSidebarViewConfig;
|
|
11201
|
+
};
|
|
11202
|
+
}
|
|
10969
11203
|
declare class AppEmbed extends V1Embed {
|
|
10970
11204
|
protected viewConfig: AppViewConfig;
|
|
10971
11205
|
private defaultHeight;
|
|
10972
11206
|
constructor(domSelector: DOMSelector, viewConfig: AppViewConfig);
|
|
11207
|
+
/**
|
|
11208
|
+
* Extends the default APP_INIT payload with `embedParams.spotterSidebarConfig`
|
|
11209
|
+
* so the conv-assist app can read sidebar configuration on initialisation.
|
|
11210
|
+
*
|
|
11211
|
+
* Precedence for `enablePastConversationsSidebar`:
|
|
11212
|
+
* `spotterSidebarConfig.enablePastConversationsSidebar` wins over the
|
|
11213
|
+
* deprecated top-level `enablePastConversationsSidebar` flag; if the former
|
|
11214
|
+
* is absent the latter is used as a fallback.
|
|
11215
|
+
*
|
|
11216
|
+
* An invalid `spotterDocumentationUrl` triggers a validation error and is
|
|
11217
|
+
* excluded from the payload rather than forwarded to the app.
|
|
11218
|
+
*/
|
|
11219
|
+
protected getAppInitData(): Promise<AppEmbedAppInitData>;
|
|
10973
11220
|
/**
|
|
10974
11221
|
* Constructs a map of parameters to be passed on to the
|
|
10975
11222
|
* embedded Liveboard or visualization.
|
|
@@ -10988,7 +11235,6 @@ declare class AppEmbed extends V1Embed {
|
|
|
10988
11235
|
* @param pageId The ID of the page to be embedded.
|
|
10989
11236
|
*/
|
|
10990
11237
|
getIFrameSrc(): string;
|
|
10991
|
-
private HEIGHT_CHANAGE_THRESHOLD;
|
|
10992
11238
|
/**
|
|
10993
11239
|
* Set the iframe height as per the computed height received
|
|
10994
11240
|
* from the ThoughtSpot app.
|
|
@@ -11388,6 +11634,24 @@ export interface LiveboardViewConfig extends BaseViewConfig, SearchLiveboardComm
|
|
|
11388
11634
|
* ```
|
|
11389
11635
|
*/
|
|
11390
11636
|
isPNGInScheduledEmailsEnabled?: boolean;
|
|
11637
|
+
/**
|
|
11638
|
+
* Enables the 'what you see is what you get' PDF export for Liveboards. Each tab is rendered on a single page
|
|
11639
|
+
* following the exact UI layout, instead of splitting visualizations across multiple A4 pages.
|
|
11640
|
+
* This feature is GA from version 26.5.0.cl and is enabled by default on embed deployments.
|
|
11641
|
+
*
|
|
11642
|
+
* Supported embed types: `AppEmbed`, `LiveboardEmbed`
|
|
11643
|
+
* @type {boolean}
|
|
11644
|
+
* @version SDK: 1.48.0 | ThoughtSpot: 26.5.0.cl
|
|
11645
|
+
* @example
|
|
11646
|
+
* ```js
|
|
11647
|
+
* // Replace <EmbedComponent> with embed component name. For example, AppEmbed or LiveboardEmbed
|
|
11648
|
+
* const embed = new <EmbedComponent>('#tsEmbed', {
|
|
11649
|
+
* ... // other embed view config
|
|
11650
|
+
* isContinuousLiveboardPDFEnabled: true,
|
|
11651
|
+
* })
|
|
11652
|
+
* ```
|
|
11653
|
+
*/
|
|
11654
|
+
isContinuousLiveboardPDFEnabled?: boolean;
|
|
11391
11655
|
/**
|
|
11392
11656
|
* This flag is used to enable/disable the XLSX/CSV download option for Liveboards
|
|
11393
11657
|
*
|
|
@@ -11533,7 +11797,6 @@ declare class LiveboardEmbed extends V1Embed {
|
|
|
11533
11797
|
* to be loaded within the iFrame.
|
|
11534
11798
|
*/
|
|
11535
11799
|
private getIFrameSrc;
|
|
11536
|
-
private HEIGHT_CHANAGE_THRESHOLD;
|
|
11537
11800
|
/**
|
|
11538
11801
|
* Set the iframe height as per the computed height received
|
|
11539
11802
|
* from the ThoughtSpot app.
|