@thoughtspot/visual-embed-sdk 1.6.0-alpha.1 → 1.6.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +8 -8
- package/dist/src/embed/app.d.ts +14 -3
- package/dist/src/embed/liveboard.d.ts +101 -0
- package/dist/src/embed/liveboard.spec.d.ts +1 -0
- package/dist/src/embed/pinboard.d.ts +6 -0
- package/dist/src/embed/search.d.ts +4 -0
- package/dist/src/embed/ts-embed.d.ts +2 -11
- package/dist/src/errors.d.ts +1 -1
- package/dist/src/index.d.ts +2 -2
- package/dist/src/react/index.d.ts +4 -3
- package/dist/src/types.d.ts +24 -20
- package/dist/src/v1/api.d.ts +19 -0
- package/dist/tsembed.es.js +87 -72
- package/dist/tsembed.js +86 -70
- package/lib/package.json +5 -1
- package/lib/src/embed/app.d.ts +14 -3
- package/lib/src/embed/app.js +25 -2
- package/lib/src/embed/app.js.map +1 -1
- package/lib/src/embed/app.spec.js +32 -0
- package/lib/src/embed/app.spec.js.map +1 -1
- package/lib/src/embed/events.spec.js +55 -2
- package/lib/src/embed/events.spec.js.map +1 -1
- package/lib/src/embed/liveboard.d.ts +101 -0
- package/lib/src/embed/liveboard.js +115 -0
- package/lib/src/embed/liveboard.js.map +1 -0
- package/lib/src/embed/liveboard.spec.d.ts +1 -0
- package/lib/src/embed/liveboard.spec.js +159 -0
- package/lib/src/embed/liveboard.spec.js.map +1 -0
- package/lib/src/embed/pinboard.d.ts +6 -0
- package/lib/src/embed/pinboard.js +4 -1
- package/lib/src/embed/pinboard.js.map +1 -1
- package/lib/src/embed/pinboard.spec.js +1 -1
- package/lib/src/embed/pinboard.spec.js.map +1 -1
- package/lib/src/embed/search.d.ts +4 -0
- package/lib/src/embed/search.js +1 -1
- package/lib/src/embed/search.js.map +1 -1
- package/lib/src/embed/ts-embed.d.ts +2 -11
- package/lib/src/embed/ts-embed.js +4 -23
- package/lib/src/embed/ts-embed.js.map +1 -1
- package/lib/src/embed/ts-embed.spec.js +63 -6
- package/lib/src/embed/ts-embed.spec.js.map +1 -1
- package/lib/src/errors.d.ts +1 -1
- package/lib/src/errors.js +1 -1
- package/lib/src/errors.js.map +1 -1
- package/lib/src/index.d.ts +2 -2
- package/lib/src/index.js +2 -2
- package/lib/src/index.js.map +1 -1
- package/lib/src/react/index.d.ts +4 -3
- package/lib/src/react/index.js +3 -2
- package/lib/src/react/index.js.map +1 -1
- package/lib/src/types.d.ts +24 -20
- package/lib/src/types.js +21 -18
- package/lib/src/types.js.map +1 -1
- package/lib/src/visual-embed-sdk.d.ts +84 -58
- package/package.json +5 -1
- package/src/embed/app.spec.ts +41 -0
- package/src/embed/app.ts +28 -3
- package/src/embed/events.spec.ts +64 -5
- package/src/embed/liveboard.spec.ts +199 -0
- package/src/embed/{pinboard.ts → liveboard.ts} +60 -42
- package/src/embed/pinboard.spec.ts +11 -11
- package/src/embed/search.ts +5 -0
- package/src/embed/ts-embed.spec.ts +81 -8
- package/src/embed/ts-embed.ts +6 -25
- package/src/errors.ts +2 -2
- package/src/index.ts +7 -2
- package/src/react/index.tsx +14 -8
- package/src/types.ts +24 -20
package/src/embed/search.ts
CHANGED
|
@@ -49,6 +49,10 @@ export interface SearchViewConfig extends ViewConfig {
|
|
|
49
49
|
* using raw answer data.
|
|
50
50
|
*/
|
|
51
51
|
hideResults?: boolean;
|
|
52
|
+
/**
|
|
53
|
+
* If set to true, expands all the data sources panel.
|
|
54
|
+
*/
|
|
55
|
+
expandAllDataSource?: boolean;
|
|
52
56
|
/**
|
|
53
57
|
* If set to true, the Search Assist feature is enabled.
|
|
54
58
|
*/
|
|
@@ -118,6 +122,7 @@ export class SearchEmbed extends TsEmbed {
|
|
|
118
122
|
private getIFrameSrc(answerId: string, dataSources?: string[]) {
|
|
119
123
|
const {
|
|
120
124
|
hideResults,
|
|
125
|
+
expandAllDataSource,
|
|
121
126
|
enableSearchAssist,
|
|
122
127
|
forceTable,
|
|
123
128
|
searchOptions,
|
|
@@ -5,8 +5,9 @@ import {
|
|
|
5
5
|
EmbedEvent,
|
|
6
6
|
SearchEmbed,
|
|
7
7
|
PinboardEmbed,
|
|
8
|
-
|
|
8
|
+
LiveboardViewConfig,
|
|
9
9
|
AppEmbed,
|
|
10
|
+
LiveboardEmbed,
|
|
10
11
|
} from '../index';
|
|
11
12
|
import { Action } from '../types';
|
|
12
13
|
import { getDocumentBody, getIFrameSrc, getRootEl } from '../test/test-utils';
|
|
@@ -24,6 +25,7 @@ const defaultViewConfig = {
|
|
|
24
25
|
},
|
|
25
26
|
};
|
|
26
27
|
const pinboardId = 'eca215d4-0d2c-4a55-90e3-d81ef6848ae0';
|
|
28
|
+
const liveboardId = 'eca215d4-0d2c-4a55-90e3-d81ef6848ae0';
|
|
27
29
|
const thoughtSpotHost = 'tshost';
|
|
28
30
|
const defaultParamsForPinboardEmbed = `hostAppUrl=local-host&viewPortHeight=768&viewPortWidth=1024&sdkVersion=${version}`;
|
|
29
31
|
|
|
@@ -119,29 +121,78 @@ describe('Unit test case for ts embed', () => {
|
|
|
119
121
|
});
|
|
120
122
|
|
|
121
123
|
describe('when visible actions are set', () => {
|
|
122
|
-
test('should throw error when there are both visible and hidden actions', async () => {
|
|
124
|
+
test('should throw error when there are both visible and hidden actions - pinboard', async () => {
|
|
123
125
|
spyOn(console, 'log');
|
|
124
126
|
const pinboardEmbed = new PinboardEmbed(getRootEl(), {
|
|
125
127
|
hiddenActions: [Action.DownloadAsCsv],
|
|
126
128
|
visibleActions: [Action.DownloadAsCsv],
|
|
127
129
|
...defaultViewConfig,
|
|
128
130
|
pinboardId,
|
|
129
|
-
} as
|
|
131
|
+
} as LiveboardViewConfig);
|
|
130
132
|
await pinboardEmbed.render();
|
|
131
133
|
expect(pinboardEmbed['isError']).toBe(true);
|
|
132
134
|
expect(console.log).toHaveBeenCalledWith(
|
|
133
135
|
'You cannot have both hidden actions and visible actions',
|
|
134
136
|
);
|
|
135
137
|
});
|
|
136
|
-
test('should not throw error when there are only visible or hidden actions', async () => {
|
|
138
|
+
test('should not throw error when there are only visible or hidden actions - pinboard', async () => {
|
|
137
139
|
const pinboardEmbed = new PinboardEmbed(getRootEl(), {
|
|
138
140
|
hiddenActions: [Action.DownloadAsCsv],
|
|
139
141
|
...defaultViewConfig,
|
|
140
142
|
pinboardId,
|
|
141
|
-
} as
|
|
143
|
+
} as LiveboardViewConfig);
|
|
142
144
|
pinboardEmbed.render();
|
|
143
145
|
expect(pinboardEmbed['isError']).toBe(false);
|
|
144
146
|
});
|
|
147
|
+
|
|
148
|
+
async function testActionsForLiveboards(
|
|
149
|
+
hiddenActions: Array<Action>,
|
|
150
|
+
visibleActions: Array<Action>,
|
|
151
|
+
) {
|
|
152
|
+
spyOn(console, 'log');
|
|
153
|
+
const liveboardEmbed = new LiveboardEmbed(getRootEl(), {
|
|
154
|
+
hiddenActions,
|
|
155
|
+
visibleActions,
|
|
156
|
+
...defaultViewConfig,
|
|
157
|
+
liveboardId,
|
|
158
|
+
} as LiveboardViewConfig);
|
|
159
|
+
await liveboardEmbed.render();
|
|
160
|
+
expect(liveboardEmbed['isError']).toBe(true);
|
|
161
|
+
expect(console.log).toHaveBeenCalledWith(
|
|
162
|
+
'You cannot have both hidden actions and visible actions',
|
|
163
|
+
);
|
|
164
|
+
}
|
|
165
|
+
test('should throw error when there are both visible and hidden action arrays', async () => {
|
|
166
|
+
await testActionsForLiveboards(
|
|
167
|
+
[Action.DownloadAsCsv],
|
|
168
|
+
[Action.DownloadAsCsv],
|
|
169
|
+
);
|
|
170
|
+
});
|
|
171
|
+
test('should throw error when there are both visible and hidden actions arrays as empty', async () => {
|
|
172
|
+
await testActionsForLiveboards([], []);
|
|
173
|
+
});
|
|
174
|
+
test('should throw error when there are both visible and hidden actions - one of them is an empty array', async () => {
|
|
175
|
+
await testActionsForLiveboards([], [Action.DownloadAsCsv]);
|
|
176
|
+
});
|
|
177
|
+
|
|
178
|
+
test('should not throw error when there are only visible or hidden actions', async () => {
|
|
179
|
+
const liveboardEmbed = new LiveboardEmbed(getRootEl(), {
|
|
180
|
+
hiddenActions: [Action.DownloadAsCsv],
|
|
181
|
+
...defaultViewConfig,
|
|
182
|
+
liveboardId,
|
|
183
|
+
} as LiveboardViewConfig);
|
|
184
|
+
liveboardEmbed.render();
|
|
185
|
+
expect(liveboardEmbed['isError']).toBe(false);
|
|
186
|
+
});
|
|
187
|
+
test('should not throw error when there are only visible or hidden actions', async () => {
|
|
188
|
+
const liveboardEmbed = new LiveboardEmbed(getRootEl(), {
|
|
189
|
+
visibleActions: [Action.DownloadAsCsv],
|
|
190
|
+
...defaultViewConfig,
|
|
191
|
+
liveboardId,
|
|
192
|
+
} as LiveboardViewConfig);
|
|
193
|
+
liveboardEmbed.render();
|
|
194
|
+
expect(liveboardEmbed['isError']).toBe(false);
|
|
195
|
+
});
|
|
145
196
|
});
|
|
146
197
|
|
|
147
198
|
describe('when thoughtSpotHost is empty', () => {
|
|
@@ -180,7 +231,7 @@ describe('Unit test case for ts embed', () => {
|
|
|
180
231
|
});
|
|
181
232
|
|
|
182
233
|
describe('Naviage to Page API', () => {
|
|
183
|
-
const path = '
|
|
234
|
+
const path = 'viz/e0836cad-4fdf-42d4-bd97-567a6b2a6058';
|
|
184
235
|
beforeEach(() => {
|
|
185
236
|
jest.spyOn(config, 'getThoughtSpotHost').mockImplementation(
|
|
186
237
|
() => 'http://tshost',
|
|
@@ -189,10 +240,10 @@ describe('Unit test case for ts embed', () => {
|
|
|
189
240
|
|
|
190
241
|
test('when app is PinboardEmbed after navigateToPage function call, new path should be set to iframe', async () => {
|
|
191
242
|
const pinboardEmbed = new PinboardEmbed(getRootEl(), {
|
|
192
|
-
pinboardId: '
|
|
243
|
+
pinboardId: 'e0836cad-4fdf-42d4-bd97-567a6b2a6058',
|
|
193
244
|
});
|
|
194
245
|
await pinboardEmbed.render();
|
|
195
|
-
pinboardEmbed.navigateToPage(path);
|
|
246
|
+
// pinboardEmbed.navigateToPage(path);
|
|
196
247
|
expect(getIFrameSrc()).toBe(
|
|
197
248
|
`http://${thoughtSpotHost}/?embedApp=true&${defaultParamsForPinboardEmbed}&isLiveboardEmbed=true#/embed/${path}`,
|
|
198
249
|
);
|
|
@@ -227,4 +278,26 @@ describe('Unit test case for ts embed', () => {
|
|
|
227
278
|
);
|
|
228
279
|
});
|
|
229
280
|
});
|
|
281
|
+
describe('Naviage to Page API - Pinboard', () => {
|
|
282
|
+
const path = 'pinboard/e0836cad-4fdf-42d4-bd97-567a6b2a6058';
|
|
283
|
+
beforeEach(() => {
|
|
284
|
+
jest.spyOn(config, 'getThoughtSpotHost').mockImplementation(
|
|
285
|
+
() => 'http://tshost',
|
|
286
|
+
);
|
|
287
|
+
});
|
|
288
|
+
|
|
289
|
+
test('when app is AppEmbed after navigateToPage function call, new path should be set to iframe', async () => {
|
|
290
|
+
const appEmbed = new AppEmbed(getRootEl(), {
|
|
291
|
+
frameParams: {
|
|
292
|
+
width: '100%',
|
|
293
|
+
height: '100%',
|
|
294
|
+
},
|
|
295
|
+
});
|
|
296
|
+
await appEmbed.render();
|
|
297
|
+
appEmbed.navigateToPage(path);
|
|
298
|
+
expect(getIFrameSrc()).toBe(
|
|
299
|
+
`http://${thoughtSpotHost}/?embedApp=true&primaryNavHidden=true&profileAndHelpInNavBarHidden=false&${defaultParamsForPinboardEmbed}#/${path}`,
|
|
300
|
+
);
|
|
301
|
+
});
|
|
302
|
+
});
|
|
230
303
|
});
|
package/src/embed/ts-embed.ts
CHANGED
|
@@ -32,9 +32,11 @@ import {
|
|
|
32
32
|
import { uploadMixpanelEvent, MIXPANEL_EVENT } from '../mixpanel-service';
|
|
33
33
|
import { getProcessData } from '../utils/processData';
|
|
34
34
|
import { processTrigger } from '../utils/processTrigger';
|
|
35
|
-
import
|
|
35
|
+
import pkgInfo from '../../package.json';
|
|
36
36
|
import { getAuthPromise, getEmbedConfig, renderInQueue } from './base';
|
|
37
37
|
|
|
38
|
+
const { version } = pkgInfo;
|
|
39
|
+
|
|
38
40
|
/**
|
|
39
41
|
* The event id map from v2 event names to v1 event id
|
|
40
42
|
* v1 events are the classic embed events implemented in Blink v1
|
|
@@ -105,7 +107,7 @@ export interface ViewConfig {
|
|
|
105
107
|
visibleActions?: Action[];
|
|
106
108
|
/**
|
|
107
109
|
* The list of runtime filters to apply to a search answer,
|
|
108
|
-
* visualization, or
|
|
110
|
+
* visualization, or Liveboard.
|
|
109
111
|
*/
|
|
110
112
|
runtimeFilters?: RuntimeFilter[];
|
|
111
113
|
}
|
|
@@ -327,7 +329,7 @@ export class TsEmbed {
|
|
|
327
329
|
visibleActions,
|
|
328
330
|
} = this.viewConfig;
|
|
329
331
|
|
|
330
|
-
if (visibleActions
|
|
332
|
+
if (Array.isArray(visibleActions) && Array.isArray(hiddenActions)) {
|
|
331
333
|
this.handleError(
|
|
332
334
|
'You cannot have both hidden actions and visible actions',
|
|
333
335
|
);
|
|
@@ -351,7 +353,7 @@ export class TsEmbed {
|
|
|
351
353
|
|
|
352
354
|
/**
|
|
353
355
|
* Constructs the base URL string to load v1 of the ThoughtSpot app.
|
|
354
|
-
* This is used for embedding
|
|
356
|
+
* This is used for embedding Liveboards, visualizations, and full application.
|
|
355
357
|
* @param queryString The query string to append to the URL.
|
|
356
358
|
* @param isAppEmbed A Boolean parameter to specify if you are embedding
|
|
357
359
|
* the full application.
|
|
@@ -587,27 +589,6 @@ export class TsEmbed {
|
|
|
587
589
|
return this;
|
|
588
590
|
}
|
|
589
591
|
|
|
590
|
-
/**
|
|
591
|
-
* Navigates users to the specified application page.
|
|
592
|
-
* Use this method to navigate users from the embedded
|
|
593
|
-
* ThoughtSpot context to a specific page in your app.
|
|
594
|
-
* @param path The page path string.
|
|
595
|
-
* For example, to navigate users to a pinboard page,
|
|
596
|
-
* define the method as navigateToPage('pinboard/<pinboardId>').
|
|
597
|
-
*/
|
|
598
|
-
public navigateToPage(path: string): void {
|
|
599
|
-
const iframeSrc = this.iFrame?.src;
|
|
600
|
-
if (iframeSrc) {
|
|
601
|
-
const embedPath = '#/embed';
|
|
602
|
-
const currentPath = iframeSrc.includes(embedPath) ? embedPath : '#';
|
|
603
|
-
this.iFrame.src = `${
|
|
604
|
-
iframeSrc.split(currentPath)[0]
|
|
605
|
-
}${currentPath}/${path.replace(/^\/?#?\//, '')}`;
|
|
606
|
-
} else {
|
|
607
|
-
console.log('Please call render before invoking this method');
|
|
608
|
-
}
|
|
609
|
-
}
|
|
610
|
-
|
|
611
592
|
/**
|
|
612
593
|
* Triggers an event on specific Port registered against
|
|
613
594
|
* for the EmbedEvent
|
package/src/errors.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export const ERROR_MESSAGE = {
|
|
2
2
|
INVALID_THOUGHTSPOT_HOST:
|
|
3
3
|
'Error parsing ThoughtSpot host. Please provide a valid URL.',
|
|
4
|
-
|
|
5
|
-
'Please provide either
|
|
4
|
+
LIVEBOARD_VIZ_ID_VALIDATION:
|
|
5
|
+
'Please provide either liveboardId or pinboardId',
|
|
6
6
|
};
|
package/src/index.ts
CHANGED
|
@@ -10,7 +10,11 @@
|
|
|
10
10
|
|
|
11
11
|
import { AppEmbed, Page, AppViewConfig } from './embed/app';
|
|
12
12
|
import { init, prefetch } from './embed/base';
|
|
13
|
-
import {
|
|
13
|
+
import {
|
|
14
|
+
PinboardEmbed,
|
|
15
|
+
LiveboardViewConfig,
|
|
16
|
+
LiveboardEmbed,
|
|
17
|
+
} from './embed/liveboard';
|
|
14
18
|
import { SearchEmbed, SearchViewConfig } from './embed/search';
|
|
15
19
|
import {
|
|
16
20
|
AuthType,
|
|
@@ -28,6 +32,7 @@ export {
|
|
|
28
32
|
prefetch,
|
|
29
33
|
SearchEmbed,
|
|
30
34
|
PinboardEmbed,
|
|
35
|
+
LiveboardEmbed,
|
|
31
36
|
AppEmbed,
|
|
32
37
|
// types
|
|
33
38
|
Page,
|
|
@@ -40,6 +45,6 @@ export {
|
|
|
40
45
|
Action,
|
|
41
46
|
EmbedConfig,
|
|
42
47
|
SearchViewConfig,
|
|
43
|
-
|
|
48
|
+
LiveboardViewConfig,
|
|
44
49
|
AppViewConfig,
|
|
45
50
|
};
|
package/src/react/index.tsx
CHANGED
|
@@ -2,9 +2,9 @@ import React from 'react';
|
|
|
2
2
|
import { SearchEmbed as _SearchEmbed, SearchViewConfig } from '../embed/search';
|
|
3
3
|
import { AppEmbed as _AppEmbed, AppViewConfig } from '../embed/app';
|
|
4
4
|
import {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
} from '../embed/
|
|
5
|
+
LiveboardEmbed as _LiveboardEmbed,
|
|
6
|
+
LiveboardViewConfig,
|
|
7
|
+
} from '../embed/liveboard';
|
|
8
8
|
import { TsEmbed, ViewConfig } from '../embed/ts-embed';
|
|
9
9
|
|
|
10
10
|
import { EmbedEvent, MessageCallback } from '../types';
|
|
@@ -55,10 +55,16 @@ export const AppEmbed = componentFactory<
|
|
|
55
55
|
AppViewConfig
|
|
56
56
|
>(_AppEmbed);
|
|
57
57
|
|
|
58
|
-
interface
|
|
58
|
+
interface LiveboardProps extends EmbedProps, LiveboardViewConfig {}
|
|
59
|
+
|
|
60
|
+
export const LiveboardEmbed = componentFactory<
|
|
61
|
+
typeof _LiveboardEmbed,
|
|
62
|
+
LiveboardProps,
|
|
63
|
+
LiveboardViewConfig
|
|
64
|
+
>(_LiveboardEmbed);
|
|
59
65
|
|
|
60
66
|
export const PinboardEmbed = componentFactory<
|
|
61
|
-
typeof
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
>(
|
|
67
|
+
typeof _LiveboardEmbed,
|
|
68
|
+
LiveboardProps,
|
|
69
|
+
LiveboardViewConfig
|
|
70
|
+
>(_LiveboardEmbed);
|
package/src/types.ts
CHANGED
|
@@ -124,13 +124,14 @@ export interface EmbedConfig {
|
|
|
124
124
|
* When there are multiple embeds, queue the render of embed to start
|
|
125
125
|
* after the previous embed's render is complete. This helps in the load performance
|
|
126
126
|
* by decreasing the load on the browser.
|
|
127
|
+
* @version 1.5.0 or later
|
|
127
128
|
* @default false
|
|
128
129
|
*/
|
|
129
130
|
queueMultiRenders?: boolean;
|
|
130
131
|
|
|
131
132
|
/**
|
|
132
133
|
* Dynamic CSS Url to be injected in the loaded application.
|
|
133
|
-
*
|
|
134
|
+
* @version 1.6.0 or later
|
|
134
135
|
* @default ''
|
|
135
136
|
*/
|
|
136
137
|
customCssUrl?: string;
|
|
@@ -212,7 +213,7 @@ export enum RuntimeFilterOp {
|
|
|
212
213
|
}
|
|
213
214
|
|
|
214
215
|
/**
|
|
215
|
-
* A filter that can be applied to ThoughtSpot answers,
|
|
216
|
+
* A filter that can be applied to ThoughtSpot answers, Liveboards, or
|
|
216
217
|
* visualizations at runtime.
|
|
217
218
|
*/
|
|
218
219
|
export interface RuntimeFilter {
|
|
@@ -252,12 +253,12 @@ export enum EmbedEvent {
|
|
|
252
253
|
*/
|
|
253
254
|
Load = 'load',
|
|
254
255
|
/**
|
|
255
|
-
* Data pertaining to answer or
|
|
256
|
-
* @return data - The answer or
|
|
256
|
+
* Data pertaining to answer or Liveboard is received
|
|
257
|
+
* @return data - The answer or Liveboard data
|
|
257
258
|
*/
|
|
258
259
|
Data = 'data',
|
|
259
260
|
/**
|
|
260
|
-
* Search/answer/
|
|
261
|
+
* Search/answer/Liveboard filters have been applied/updated
|
|
261
262
|
* @hidden
|
|
262
263
|
*/
|
|
263
264
|
FiltersChanged = 'filtersChanged',
|
|
@@ -280,13 +281,13 @@ export enum EmbedEvent {
|
|
|
280
281
|
/**
|
|
281
282
|
* A custom action has been triggered
|
|
282
283
|
* @return actionId - The id of the custom action
|
|
283
|
-
* @return data - The answer or
|
|
284
|
+
* @return data - The answer or Liveboard data
|
|
284
285
|
*/
|
|
285
286
|
CustomAction = 'customAction',
|
|
286
287
|
/**
|
|
287
288
|
* A double click has been triggered on table/chart
|
|
288
289
|
* @return ContextMenuInputPoints - data point that is double clicked
|
|
289
|
-
*
|
|
290
|
+
* @version 1.5.0 or later
|
|
290
291
|
*/
|
|
291
292
|
VizPointDoubleClick = 'vizPointDoubleClick',
|
|
292
293
|
/**
|
|
@@ -304,8 +305,8 @@ export enum EmbedEvent {
|
|
|
304
305
|
*/
|
|
305
306
|
AuthExpire = 'ThoughtspotAuthExpired',
|
|
306
307
|
/**
|
|
307
|
-
* The height of the embedded
|
|
308
|
-
* @return data - The height of the embedded
|
|
308
|
+
* The height of the embedded Liveboard or visualization has been computed.
|
|
309
|
+
* @return data - The height of the embedded Liveboard or visualization
|
|
309
310
|
* @hidden
|
|
310
311
|
*/
|
|
311
312
|
EmbedHeight = 'EMBED_HEIGHT',
|
|
@@ -317,7 +318,6 @@ export enum EmbedEvent {
|
|
|
317
318
|
EmbedIframeCenter = 'EmbedIframeCenter',
|
|
318
319
|
/**
|
|
319
320
|
* Detects the route change.
|
|
320
|
-
* @hidden
|
|
321
321
|
*/
|
|
322
322
|
RouteChange = 'ROUTE_CHANGE',
|
|
323
323
|
/**
|
|
@@ -329,7 +329,7 @@ export enum EmbedEvent {
|
|
|
329
329
|
* Emitted when the embed does not have cookie access. This
|
|
330
330
|
* happens on Safari where third-party cookies are blocked by default.
|
|
331
331
|
*
|
|
332
|
-
* @version 1.1.0
|
|
332
|
+
* @version 1.1.0 or later
|
|
333
333
|
*/
|
|
334
334
|
NoCookieAccess = 'noCookieAccess',
|
|
335
335
|
/**
|
|
@@ -340,12 +340,12 @@ export enum EmbedEvent {
|
|
|
340
340
|
SAMLComplete = 'samlComplete',
|
|
341
341
|
/**
|
|
342
342
|
* Emitted when any modal is opened in the app
|
|
343
|
-
*
|
|
343
|
+
* @version 1.6.0 or later
|
|
344
344
|
*/
|
|
345
345
|
DialogOpen = 'dialog-open',
|
|
346
346
|
/**
|
|
347
347
|
* Emitted when any modal is closed in the app
|
|
348
|
-
*
|
|
348
|
+
* @version 1.6.0 or later
|
|
349
349
|
*/
|
|
350
350
|
DialogClose = 'dialog-close',
|
|
351
351
|
}
|
|
@@ -368,7 +368,7 @@ export enum HostEvent {
|
|
|
368
368
|
* eg. { selectedPoints: []}
|
|
369
369
|
* @param columnGuid - a string guid of the column to drill by. This is optional,
|
|
370
370
|
* if not provided it will auto drill by the configured column. \
|
|
371
|
-
*
|
|
371
|
+
* @version 1.5.0 or later
|
|
372
372
|
*/
|
|
373
373
|
DrillDown = 'triggerDrillDown',
|
|
374
374
|
/**
|
|
@@ -382,10 +382,10 @@ export enum HostEvent {
|
|
|
382
382
|
*/
|
|
383
383
|
Reload = 'reload',
|
|
384
384
|
/**
|
|
385
|
-
* Set the visible
|
|
386
|
-
* @param - an array of ids of
|
|
385
|
+
* Set the visible visualizations on a Liveboard.
|
|
386
|
+
* @param - an array of ids of visualizations to show, the ids not passed
|
|
387
387
|
* will be hidden.
|
|
388
|
-
*
|
|
388
|
+
* @version 1.6.0 or later
|
|
389
389
|
*/
|
|
390
390
|
SetVisibleVizs = 'SetPinboardVisibleVizs',
|
|
391
391
|
}
|
|
@@ -418,10 +418,11 @@ export enum DataSourceVisualMode {
|
|
|
418
418
|
export enum Param {
|
|
419
419
|
DataSources = 'dataSources',
|
|
420
420
|
DataSourceMode = 'dataSourceMode',
|
|
421
|
+
ExpandAllDataSource = 'expandAllDataSource',
|
|
421
422
|
DisableActions = 'disableAction',
|
|
422
423
|
DisableActionReason = 'disableHint',
|
|
423
424
|
ForceTable = 'forceTable',
|
|
424
|
-
|
|
425
|
+
preventLiveboardFilterRemoval = 'preventPinboardFilterRemoval', // update-TSCB
|
|
425
426
|
SearchQuery = 'searchQuery',
|
|
426
427
|
HideActions = 'hideAction',
|
|
427
428
|
HideObjects = 'hideObjects',
|
|
@@ -444,7 +445,7 @@ export enum Param {
|
|
|
444
445
|
|
|
445
446
|
/**
|
|
446
447
|
* The list of actions that can be performed on visual ThoughtSpot
|
|
447
|
-
* entities, such as answers and
|
|
448
|
+
* entities, such as answers and Liveboards.
|
|
448
449
|
*/
|
|
449
450
|
// eslint-disable-next-line no-shadow
|
|
450
451
|
export enum Action {
|
|
@@ -455,7 +456,6 @@ export enum Action {
|
|
|
455
456
|
MakeACopy = 'makeACopy',
|
|
456
457
|
EditACopy = 'editACopy',
|
|
457
458
|
CopyLink = 'embedDocument',
|
|
458
|
-
PinboardSnapshot = 'pinboardSnapshot',
|
|
459
459
|
ResetLayout = 'resetLayout',
|
|
460
460
|
Schedule = 'schedule',
|
|
461
461
|
SchedulesList = 'schedule-list',
|
|
@@ -488,7 +488,11 @@ export enum Action {
|
|
|
488
488
|
Describe = 'describe',
|
|
489
489
|
Relate = 'relate',
|
|
490
490
|
CustomizeHeadlines = 'customizeHeadlines',
|
|
491
|
+
/**
|
|
492
|
+
* @hidden
|
|
493
|
+
*/
|
|
491
494
|
PinboardInfo = 'pinboardInfo',
|
|
495
|
+
LiveboardInfo = 'pinboardInfo',
|
|
492
496
|
SendAnswerFeedback = 'sendFeedback',
|
|
493
497
|
/**
|
|
494
498
|
* @deprecated Will be removed in next version
|