@thoughtspot/visual-embed-sdk 1.5.1 → 1.6.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 +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/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 -22
- package/dist/tsembed.es.js +83 -74
- package/dist/tsembed.js +82 -72
- package/lib/package.json +4 -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/{pinboard.js → liveboard.js} +34 -29
- 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.spec.js +1 -1
- package/lib/src/embed/pinboard.spec.js.map +1 -1
- package/lib/src/embed/ts-embed.d.ts +2 -11
- package/lib/src/embed/ts-embed.js +2 -22
- 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 -22
- package/lib/src/types.js +20 -19
- package/lib/src/types.js.map +1 -1
- package/lib/src/visual-embed-sdk.d.ts +79 -65
- package/package.json +4 -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} +59 -51
- package/src/embed/pinboard.spec.ts +11 -11
- package/src/embed/ts-embed.spec.ts +81 -8
- package/src/embed/ts-embed.ts +3 -24
- package/src/errors.ts +2 -2
- package/src/index.ts +7 -2
- package/src/react/index.tsx +14 -8
- package/src/types.ts +23 -21
- package/dist/src/embed/pinboard.d.ts +0 -91
- package/dist/src/v1/api.d.ts +0 -19
- package/lib/src/embed/pinboard.d.ts +0 -91
- package/lib/src/embed/pinboard.js.map +0 -1
package/dist/tsembed.js
CHANGED
|
@@ -220,12 +220,12 @@
|
|
|
220
220
|
*/
|
|
221
221
|
EmbedEvent["Load"] = "load";
|
|
222
222
|
/**
|
|
223
|
-
* Data pertaining to answer or
|
|
224
|
-
* @return data - The answer or
|
|
223
|
+
* Data pertaining to answer or Liveboard is received
|
|
224
|
+
* @return data - The answer or Liveboard data
|
|
225
225
|
*/
|
|
226
226
|
EmbedEvent["Data"] = "data";
|
|
227
227
|
/**
|
|
228
|
-
* Search/answer/
|
|
228
|
+
* Search/answer/Liveboard filters have been applied/updated
|
|
229
229
|
* @hidden
|
|
230
230
|
*/
|
|
231
231
|
EmbedEvent["FiltersChanged"] = "filtersChanged";
|
|
@@ -248,13 +248,13 @@
|
|
|
248
248
|
/**
|
|
249
249
|
* A custom action has been triggered
|
|
250
250
|
* @return actionId - The id of the custom action
|
|
251
|
-
* @return data - The answer or
|
|
251
|
+
* @return data - The answer or Liveboard data
|
|
252
252
|
*/
|
|
253
253
|
EmbedEvent["CustomAction"] = "customAction";
|
|
254
254
|
/**
|
|
255
255
|
* A double click has been triggered on table/chart
|
|
256
256
|
* @return ContextMenuInputPoints - data point that is double clicked
|
|
257
|
-
*
|
|
257
|
+
* @version 1.5.0 or later
|
|
258
258
|
*/
|
|
259
259
|
EmbedEvent["VizPointDoubleClick"] = "vizPointDoubleClick";
|
|
260
260
|
/**
|
|
@@ -272,8 +272,8 @@
|
|
|
272
272
|
*/
|
|
273
273
|
EmbedEvent["AuthExpire"] = "ThoughtspotAuthExpired";
|
|
274
274
|
/**
|
|
275
|
-
* The height of the embedded
|
|
276
|
-
* @return data - The height of the embedded
|
|
275
|
+
* The height of the embedded Liveboard or visualization has been computed.
|
|
276
|
+
* @return data - The height of the embedded Liveboard or visualization
|
|
277
277
|
* @hidden
|
|
278
278
|
*/
|
|
279
279
|
EmbedEvent["EmbedHeight"] = "EMBED_HEIGHT";
|
|
@@ -285,7 +285,6 @@
|
|
|
285
285
|
EmbedEvent["EmbedIframeCenter"] = "EmbedIframeCenter";
|
|
286
286
|
/**
|
|
287
287
|
* Detects the route change.
|
|
288
|
-
* @hidden
|
|
289
288
|
*/
|
|
290
289
|
EmbedEvent["RouteChange"] = "ROUTE_CHANGE";
|
|
291
290
|
/**
|
|
@@ -297,7 +296,7 @@
|
|
|
297
296
|
* Emitted when the embed does not have cookie access. This
|
|
298
297
|
* happens on Safari where third-party cookies are blocked by default.
|
|
299
298
|
*
|
|
300
|
-
* @version 1.1.0
|
|
299
|
+
* @version 1.1.0 or later
|
|
301
300
|
*/
|
|
302
301
|
EmbedEvent["NoCookieAccess"] = "noCookieAccess";
|
|
303
302
|
/**
|
|
@@ -308,12 +307,12 @@
|
|
|
308
307
|
EmbedEvent["SAMLComplete"] = "samlComplete";
|
|
309
308
|
/**
|
|
310
309
|
* Emitted when any modal is opened in the app
|
|
311
|
-
*
|
|
310
|
+
* @version 1.6.0 or later
|
|
312
311
|
*/
|
|
313
312
|
EmbedEvent["DialogOpen"] = "dialog-open";
|
|
314
313
|
/**
|
|
315
314
|
* Emitted when any modal is closed in the app
|
|
316
|
-
*
|
|
315
|
+
* @version 1.6.0 or later
|
|
317
316
|
*/
|
|
318
317
|
EmbedEvent["DialogClose"] = "dialog-close";
|
|
319
318
|
})(exports.EmbedEvent || (exports.EmbedEvent = {}));
|
|
@@ -330,7 +329,7 @@
|
|
|
330
329
|
* eg. { selectedPoints: []}
|
|
331
330
|
* @param columnGuid - a string guid of the column to drill by. This is optional,
|
|
332
331
|
* if not provided it will auto drill by the configured column. \
|
|
333
|
-
*
|
|
332
|
+
* @version 1.5.0 or later
|
|
334
333
|
*/
|
|
335
334
|
HostEvent["DrillDown"] = "triggerDrillDown";
|
|
336
335
|
/**
|
|
@@ -344,10 +343,10 @@
|
|
|
344
343
|
*/
|
|
345
344
|
HostEvent["Reload"] = "reload";
|
|
346
345
|
/**
|
|
347
|
-
* Set the visible
|
|
348
|
-
* @param - an array of ids of
|
|
346
|
+
* Set the visible visualizations on a Liveboard.
|
|
347
|
+
* @param - an array of ids of visualizations to show, the ids not passed
|
|
349
348
|
* will be hidden.
|
|
350
|
-
*
|
|
349
|
+
* @version 1.6.0 or later
|
|
351
350
|
*/
|
|
352
351
|
HostEvent["SetVisibleVizs"] = "SetPinboardVisibleVizs";
|
|
353
352
|
})(exports.HostEvent || (exports.HostEvent = {}));
|
|
@@ -378,7 +377,7 @@
|
|
|
378
377
|
Param["DisableActions"] = "disableAction";
|
|
379
378
|
Param["DisableActionReason"] = "disableHint";
|
|
380
379
|
Param["ForceTable"] = "forceTable";
|
|
381
|
-
Param["
|
|
380
|
+
Param["preventLiveboardFilterRemoval"] = "preventPinboardFilterRemoval";
|
|
382
381
|
Param["SearchQuery"] = "searchQuery";
|
|
383
382
|
Param["HideActions"] = "hideAction";
|
|
384
383
|
Param["HideObjects"] = "hideObjects";
|
|
@@ -397,7 +396,6 @@
|
|
|
397
396
|
Param["ViewPortWidth"] = "viewPortWidth";
|
|
398
397
|
Param["VisibleActions"] = "visibleAction";
|
|
399
398
|
Param["CustomCSSUrl"] = "customCssUrl";
|
|
400
|
-
Param["PinboardVisibleVizs"] = "pinboardVisibleVizs";
|
|
401
399
|
})(Param || (Param = {}));
|
|
402
400
|
(function (Action) {
|
|
403
401
|
Action["Save"] = "save";
|
|
@@ -407,7 +405,6 @@
|
|
|
407
405
|
Action["MakeACopy"] = "makeACopy";
|
|
408
406
|
Action["EditACopy"] = "editACopy";
|
|
409
407
|
Action["CopyLink"] = "embedDocument";
|
|
410
|
-
Action["PinboardSnapshot"] = "pinboardSnapshot";
|
|
411
408
|
Action["ResetLayout"] = "resetLayout";
|
|
412
409
|
Action["Schedule"] = "schedule";
|
|
413
410
|
Action["SchedulesList"] = "schedule-list";
|
|
@@ -440,7 +437,11 @@
|
|
|
440
437
|
Action["Describe"] = "describe";
|
|
441
438
|
Action["Relate"] = "relate";
|
|
442
439
|
Action["CustomizeHeadlines"] = "customizeHeadlines";
|
|
440
|
+
/**
|
|
441
|
+
* @hidden
|
|
442
|
+
*/
|
|
443
443
|
Action["PinboardInfo"] = "pinboardInfo";
|
|
444
|
+
Action["LiveboardInfo"] = "pinboardInfo";
|
|
444
445
|
Action["SendAnswerFeedback"] = "sendFeedback";
|
|
445
446
|
/**
|
|
446
447
|
* @deprecated Will be removed in next version
|
|
@@ -470,7 +471,7 @@
|
|
|
470
471
|
|
|
471
472
|
const ERROR_MESSAGE = {
|
|
472
473
|
INVALID_THOUGHTSPOT_HOST: 'Error parsing ThoughtSpot host. Please provide a valid URL.',
|
|
473
|
-
|
|
474
|
+
LIVEBOARD_VIZ_ID_VALIDATION: 'Please provide either liveboardId or pinboardId',
|
|
474
475
|
};
|
|
475
476
|
|
|
476
477
|
/**
|
|
@@ -8811,7 +8812,7 @@
|
|
|
8811
8812
|
}
|
|
8812
8813
|
}
|
|
8813
8814
|
|
|
8814
|
-
var version="1.
|
|
8815
|
+
var version="1.6.0";
|
|
8815
8816
|
|
|
8816
8817
|
/**
|
|
8817
8818
|
* Copyright (c) 2021
|
|
@@ -8977,7 +8978,7 @@
|
|
|
8977
8978
|
queryParams[Param.CustomCSSUrl] = this.embedConfig.customCssUrl;
|
|
8978
8979
|
}
|
|
8979
8980
|
const { disabledActions, disabledActionReason, hiddenActions, visibleActions, } = this.viewConfig;
|
|
8980
|
-
if ((visibleActions
|
|
8981
|
+
if (Array.isArray(visibleActions) && Array.isArray(hiddenActions)) {
|
|
8981
8982
|
this.handleError('You cannot have both hidden actions and visible actions');
|
|
8982
8983
|
return queryParams;
|
|
8983
8984
|
}
|
|
@@ -8997,7 +8998,7 @@
|
|
|
8997
8998
|
}
|
|
8998
8999
|
/**
|
|
8999
9000
|
* Constructs the base URL string to load v1 of the ThoughtSpot app.
|
|
9000
|
-
* This is used for embedding
|
|
9001
|
+
* This is used for embedding Liveboards, visualizations, and full application.
|
|
9001
9002
|
* @param queryString The query string to append to the URL.
|
|
9002
9003
|
* @param isAppEmbed A Boolean parameter to specify if you are embedding
|
|
9003
9004
|
* the full application.
|
|
@@ -9175,26 +9176,6 @@
|
|
|
9175
9176
|
this.eventHandlerMap.set(messageType, callbacks);
|
|
9176
9177
|
return this;
|
|
9177
9178
|
}
|
|
9178
|
-
/**
|
|
9179
|
-
* Navigates users to the specified application page.
|
|
9180
|
-
* Use this method to navigate users from the embedded
|
|
9181
|
-
* ThoughtSpot context to a specific page in your app.
|
|
9182
|
-
* @param path The page path string.
|
|
9183
|
-
* For example, to navigate users to a pinboard page,
|
|
9184
|
-
* define the method as navigateToPage('pinboard/<pinboardId>').
|
|
9185
|
-
*/
|
|
9186
|
-
navigateToPage(path) {
|
|
9187
|
-
var _a;
|
|
9188
|
-
const iframeSrc = (_a = this.iFrame) === null || _a === void 0 ? void 0 : _a.src;
|
|
9189
|
-
if (iframeSrc) {
|
|
9190
|
-
const embedPath = '#/embed';
|
|
9191
|
-
const currentPath = iframeSrc.includes(embedPath) ? embedPath : '#';
|
|
9192
|
-
this.iFrame.src = `${iframeSrc.split(currentPath)[0]}${currentPath}/${path.replace(/^\/?#?\//, '')}`;
|
|
9193
|
-
}
|
|
9194
|
-
else {
|
|
9195
|
-
console.log('Please call render before invoking this method');
|
|
9196
|
-
}
|
|
9197
|
-
}
|
|
9198
9179
|
/**
|
|
9199
9180
|
* Triggers an event on specific Port registered against
|
|
9200
9181
|
* for the EmbedEvent
|
|
@@ -9287,7 +9268,11 @@
|
|
|
9287
9268
|
*/
|
|
9288
9269
|
Page["Answers"] = "answers";
|
|
9289
9270
|
/**
|
|
9290
|
-
*
|
|
9271
|
+
* Liveboards listing page
|
|
9272
|
+
*/
|
|
9273
|
+
Page["Liveboards"] = "liveboards";
|
|
9274
|
+
/**
|
|
9275
|
+
* @hidden
|
|
9291
9276
|
*/
|
|
9292
9277
|
Page["Pinboards"] = "pinboards";
|
|
9293
9278
|
/**
|
|
@@ -9306,7 +9291,7 @@
|
|
|
9306
9291
|
}
|
|
9307
9292
|
/**
|
|
9308
9293
|
* Constructs a map of parameters to be passed on to the
|
|
9309
|
-
* embedded
|
|
9294
|
+
* embedded Liveboard or visualization.
|
|
9310
9295
|
*/
|
|
9311
9296
|
getEmbedParams() {
|
|
9312
9297
|
const params = this.getBaseQueryParams();
|
|
@@ -9343,6 +9328,8 @@
|
|
|
9343
9328
|
return 'answer';
|
|
9344
9329
|
case exports.Page.Answers:
|
|
9345
9330
|
return 'answers';
|
|
9331
|
+
case exports.Page.Liveboards:
|
|
9332
|
+
return 'pinboards';
|
|
9346
9333
|
case exports.Page.Pinboards:
|
|
9347
9334
|
return 'pinboards';
|
|
9348
9335
|
case exports.Page.Data:
|
|
@@ -9367,6 +9354,23 @@
|
|
|
9367
9354
|
}
|
|
9368
9355
|
return path;
|
|
9369
9356
|
}
|
|
9357
|
+
/**
|
|
9358
|
+
* Navigate to particular page for app embed. eg:answers/pinboards/home
|
|
9359
|
+
* This is used for embedding answers, pinboards, visualizations and full application only.
|
|
9360
|
+
* @param path The string, set to iframe src and navigate to new page
|
|
9361
|
+
* eg: appEmbed.navigateToPage('pinboards')
|
|
9362
|
+
*/
|
|
9363
|
+
navigateToPage(path) {
|
|
9364
|
+
if (this.iFrame) {
|
|
9365
|
+
const iframeSrc = this.iFrame.src;
|
|
9366
|
+
const embedPath = '#/embed';
|
|
9367
|
+
const currentPath = iframeSrc.includes(embedPath) ? embedPath : '#';
|
|
9368
|
+
this.iFrame.src = `${iframeSrc.split(currentPath)[0]}${currentPath}/${path.replace(/^\/?#?\//, '')}`;
|
|
9369
|
+
}
|
|
9370
|
+
else {
|
|
9371
|
+
console.log('Please call render before invoking this method');
|
|
9372
|
+
}
|
|
9373
|
+
}
|
|
9370
9374
|
/**
|
|
9371
9375
|
* Renders the embedded application pages in the ThoughtSpot app.
|
|
9372
9376
|
* @param renderOptions An object containing the page ID
|
|
@@ -9385,18 +9389,18 @@
|
|
|
9385
9389
|
/**
|
|
9386
9390
|
* Copyright (c) 2021
|
|
9387
9391
|
*
|
|
9388
|
-
* Embed a ThoughtSpot
|
|
9392
|
+
* Embed a ThoughtSpot Liveboard or visualization
|
|
9389
9393
|
* https://developers.thoughtspot.com/docs/?pageid=embed-pinboard
|
|
9390
9394
|
* https://developers.thoughtspot.com/docs/?pageid=embed-a-viz
|
|
9391
9395
|
*
|
|
9392
|
-
* @summary
|
|
9396
|
+
* @summary Liveboard & visualization embed
|
|
9393
9397
|
* @author Ayon Ghosh <ayon.ghosh@thoughtspot.com>
|
|
9394
9398
|
*/
|
|
9395
9399
|
/**
|
|
9396
|
-
* Embed a ThoughtSpot
|
|
9397
|
-
* @Category
|
|
9400
|
+
* Embed a ThoughtSpot Liveboard or visualization
|
|
9401
|
+
* @Category Liveboards and Charts
|
|
9398
9402
|
*/
|
|
9399
|
-
class
|
|
9403
|
+
class LiveboardEmbed extends V1Embed {
|
|
9400
9404
|
// eslint-disable-next-line no-useless-constructor
|
|
9401
9405
|
constructor(domSelector, viewConfig) {
|
|
9402
9406
|
super(domSelector, viewConfig);
|
|
@@ -9413,20 +9417,21 @@
|
|
|
9413
9417
|
const obj = this.getIframeCenter();
|
|
9414
9418
|
responder({ type: exports.EmbedEvent.EmbedIframeCenter, data: obj });
|
|
9415
9419
|
};
|
|
9416
|
-
this.
|
|
9417
|
-
if (data.data.
|
|
9418
|
-
data.data.canvasState !== 'pinboard') {
|
|
9420
|
+
this.setIframeHeightForNonEmbedLiveboard = (data) => {
|
|
9421
|
+
if (!data.data.currentPath.startsWith('/embed/viz/')) {
|
|
9419
9422
|
this.setIFrameHeight(this.defaultHeight);
|
|
9420
9423
|
}
|
|
9421
9424
|
};
|
|
9422
9425
|
}
|
|
9423
9426
|
/**
|
|
9424
9427
|
* Construct a map of params to be passed on to the
|
|
9425
|
-
* embedded
|
|
9428
|
+
* embedded Liveboard or visualization.
|
|
9426
9429
|
*/
|
|
9427
9430
|
getEmbedParams() {
|
|
9428
9431
|
const params = this.getBaseQueryParams();
|
|
9429
|
-
const { enableVizTransformations, fullHeight,
|
|
9432
|
+
const { enableVizTransformations, fullHeight, defaultHeight, } = this.viewConfig;
|
|
9433
|
+
const preventLiveboardFilterRemoval = this.viewConfig.preventLiveboardFilterRemoval ||
|
|
9434
|
+
this.viewConfig.preventPinboardFilterRemoval;
|
|
9430
9435
|
if (fullHeight === true) {
|
|
9431
9436
|
params[Param.fullHeight] = true;
|
|
9432
9437
|
}
|
|
@@ -9436,56 +9441,60 @@
|
|
|
9436
9441
|
if (enableVizTransformations !== undefined) {
|
|
9437
9442
|
params[Param.EnableVizTransformations] = enableVizTransformations.toString();
|
|
9438
9443
|
}
|
|
9439
|
-
if (
|
|
9440
|
-
params[Param.
|
|
9441
|
-
}
|
|
9442
|
-
if (pinboardVisibleVizs) {
|
|
9443
|
-
params[Param.PinboardVisibleVizs] = pinboardVisibleVizs;
|
|
9444
|
+
if (preventLiveboardFilterRemoval) {
|
|
9445
|
+
params[Param.preventLiveboardFilterRemoval] = true;
|
|
9444
9446
|
}
|
|
9445
9447
|
params[Param.livedBoardEmbed] = true;
|
|
9446
9448
|
const queryParams = getQueryParamString(params, true);
|
|
9447
9449
|
return queryParams;
|
|
9448
9450
|
}
|
|
9449
9451
|
/**
|
|
9450
|
-
* Construct the URL of the embedded ThoughtSpot
|
|
9452
|
+
* Construct the URL of the embedded ThoughtSpot Liveboard or visualization
|
|
9451
9453
|
* to be loaded within the iframe.
|
|
9452
|
-
* @param
|
|
9453
|
-
* @param vizId The optional GUID of a visualization within the
|
|
9454
|
+
* @param liveboardId The GUID of the Liveboard.
|
|
9455
|
+
* @param vizId The optional GUID of a visualization within the Liveboard.
|
|
9454
9456
|
* @param runtimeFilters A list of runtime filters to be applied to
|
|
9455
|
-
* the
|
|
9457
|
+
* the Liveboard or visualization on load.
|
|
9456
9458
|
*/
|
|
9457
|
-
getIFrameSrc(
|
|
9459
|
+
getIFrameSrc(liveboardId, vizId, runtimeFilters) {
|
|
9458
9460
|
const filterQuery = getFilterQuery(runtimeFilters || []);
|
|
9459
9461
|
const queryParams = this.getEmbedParams();
|
|
9460
9462
|
const queryString = [filterQuery, queryParams]
|
|
9461
9463
|
.filter(Boolean)
|
|
9462
9464
|
.join('&');
|
|
9463
|
-
let url = `${this.getV1EmbedBasePath(queryString, true, false, false)}/viz/${
|
|
9465
|
+
let url = `${this.getV1EmbedBasePath(queryString, true, false, false)}/viz/${liveboardId}`;
|
|
9464
9466
|
if (vizId) {
|
|
9465
9467
|
url = `${url}/${vizId}`;
|
|
9466
9468
|
}
|
|
9467
9469
|
return url;
|
|
9468
9470
|
}
|
|
9469
9471
|
/**
|
|
9470
|
-
* Render an embedded ThoughtSpot
|
|
9471
|
-
* @param renderOptions An object specifying the
|
|
9472
|
+
* Render an embedded ThoughtSpot Liveboard or visualization
|
|
9473
|
+
* @param renderOptions An object specifying the Liveboard ID,
|
|
9472
9474
|
* visualization ID and the runtime filters.
|
|
9473
9475
|
*/
|
|
9474
9476
|
render() {
|
|
9475
|
-
|
|
9476
|
-
|
|
9477
|
-
|
|
9477
|
+
var _a;
|
|
9478
|
+
const { vizId, runtimeFilters } = this.viewConfig;
|
|
9479
|
+
const liveboardId = (_a = this.viewConfig.liveboardId) !== null && _a !== void 0 ? _a : this.viewConfig.pinboardId;
|
|
9480
|
+
if (!liveboardId) {
|
|
9481
|
+
this.handleError(ERROR_MESSAGE.LIVEBOARD_VIZ_ID_VALIDATION);
|
|
9478
9482
|
}
|
|
9479
9483
|
if (this.viewConfig.fullHeight === true) {
|
|
9480
|
-
this.on(exports.EmbedEvent.RouteChange, this.
|
|
9484
|
+
this.on(exports.EmbedEvent.RouteChange, this.setIframeHeightForNonEmbedLiveboard);
|
|
9481
9485
|
this.on(exports.EmbedEvent.EmbedHeight, this.updateIFrameHeight);
|
|
9482
9486
|
this.on(exports.EmbedEvent.EmbedIframeCenter, this.embedIframeCenter);
|
|
9483
9487
|
}
|
|
9484
9488
|
super.render();
|
|
9485
|
-
const src = this.getIFrameSrc(
|
|
9489
|
+
const src = this.getIFrameSrc(liveboardId, vizId, runtimeFilters);
|
|
9486
9490
|
this.renderV1Embed(src);
|
|
9487
9491
|
return this;
|
|
9488
9492
|
}
|
|
9493
|
+
}
|
|
9494
|
+
/**
|
|
9495
|
+
* @hidden
|
|
9496
|
+
*/
|
|
9497
|
+
class PinboardEmbed extends LiveboardEmbed {
|
|
9489
9498
|
}
|
|
9490
9499
|
|
|
9491
9500
|
/**
|
|
@@ -9570,6 +9579,7 @@
|
|
|
9570
9579
|
}
|
|
9571
9580
|
|
|
9572
9581
|
exports.AppEmbed = AppEmbed;
|
|
9582
|
+
exports.LiveboardEmbed = LiveboardEmbed;
|
|
9573
9583
|
exports.PinboardEmbed = PinboardEmbed;
|
|
9574
9584
|
exports.SearchEmbed = SearchEmbed;
|
|
9575
9585
|
exports.init = init;
|
package/lib/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@thoughtspot/visual-embed-sdk",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.6.0",
|
|
4
4
|
"description": "ThoughtSpot Embed SDK",
|
|
5
5
|
"module": "lib/src/index.js",
|
|
6
6
|
"main": "dist/tsembed.js",
|
|
@@ -127,6 +127,9 @@
|
|
|
127
127
|
"type": "git",
|
|
128
128
|
"url": "git+https://github.com/thoughtspot/visual-embed-sdk.git"
|
|
129
129
|
},
|
|
130
|
+
"publishConfig": {
|
|
131
|
+
"registry": "https://registry.npmjs.org"
|
|
132
|
+
},
|
|
130
133
|
"keywords": [
|
|
131
134
|
"thoughtspot",
|
|
132
135
|
"everywhere",
|
package/lib/src/embed/app.d.ts
CHANGED
|
@@ -27,7 +27,11 @@ export declare enum Page {
|
|
|
27
27
|
*/
|
|
28
28
|
Answers = "answers",
|
|
29
29
|
/**
|
|
30
|
-
*
|
|
30
|
+
* Liveboards listing page
|
|
31
|
+
*/
|
|
32
|
+
Liveboards = "liveboards",
|
|
33
|
+
/**
|
|
34
|
+
* @hidden
|
|
31
35
|
*/
|
|
32
36
|
Pinboards = "pinboards",
|
|
33
37
|
/**
|
|
@@ -63,7 +67,7 @@ export interface AppViewConfig extends ViewConfig {
|
|
|
63
67
|
pageId?: Page;
|
|
64
68
|
/**
|
|
65
69
|
* This puts a filter tag on the application. All metadata lists in the application, such as
|
|
66
|
-
*
|
|
70
|
+
* Liveboards and answers, would be filtered by this tag.
|
|
67
71
|
*/
|
|
68
72
|
tag?: string;
|
|
69
73
|
/**
|
|
@@ -80,7 +84,7 @@ export declare class AppEmbed extends V1Embed {
|
|
|
80
84
|
constructor(domSelector: DOMSelector, viewConfig: AppViewConfig);
|
|
81
85
|
/**
|
|
82
86
|
* Constructs a map of parameters to be passed on to the
|
|
83
|
-
* embedded
|
|
87
|
+
* embedded Liveboard or visualization.
|
|
84
88
|
*/
|
|
85
89
|
private getEmbedParams;
|
|
86
90
|
/**
|
|
@@ -99,6 +103,13 @@ export declare class AppEmbed extends V1Embed {
|
|
|
99
103
|
* @returns The URL path that the embedded app understands.
|
|
100
104
|
*/
|
|
101
105
|
private formatPath;
|
|
106
|
+
/**
|
|
107
|
+
* Navigate to particular page for app embed. eg:answers/pinboards/home
|
|
108
|
+
* This is used for embedding answers, pinboards, visualizations and full application only.
|
|
109
|
+
* @param path The string, set to iframe src and navigate to new page
|
|
110
|
+
* eg: appEmbed.navigateToPage('pinboards')
|
|
111
|
+
*/
|
|
112
|
+
navigateToPage(path: string): void;
|
|
102
113
|
/**
|
|
103
114
|
* Renders the embedded application pages in the ThoughtSpot app.
|
|
104
115
|
* @param renderOptions An object containing the page ID
|
package/lib/src/embed/app.js
CHANGED
|
@@ -30,7 +30,11 @@ export var Page;
|
|
|
30
30
|
*/
|
|
31
31
|
Page["Answers"] = "answers";
|
|
32
32
|
/**
|
|
33
|
-
*
|
|
33
|
+
* Liveboards listing page
|
|
34
|
+
*/
|
|
35
|
+
Page["Liveboards"] = "liveboards";
|
|
36
|
+
/**
|
|
37
|
+
* @hidden
|
|
34
38
|
*/
|
|
35
39
|
Page["Pinboards"] = "pinboards";
|
|
36
40
|
/**
|
|
@@ -49,7 +53,7 @@ export class AppEmbed extends V1Embed {
|
|
|
49
53
|
}
|
|
50
54
|
/**
|
|
51
55
|
* Constructs a map of parameters to be passed on to the
|
|
52
|
-
* embedded
|
|
56
|
+
* embedded Liveboard or visualization.
|
|
53
57
|
*/
|
|
54
58
|
getEmbedParams() {
|
|
55
59
|
const params = this.getBaseQueryParams();
|
|
@@ -86,6 +90,8 @@ export class AppEmbed extends V1Embed {
|
|
|
86
90
|
return 'answer';
|
|
87
91
|
case Page.Answers:
|
|
88
92
|
return 'answers';
|
|
93
|
+
case Page.Liveboards:
|
|
94
|
+
return 'pinboards';
|
|
89
95
|
case Page.Pinboards:
|
|
90
96
|
return 'pinboards';
|
|
91
97
|
case Page.Data:
|
|
@@ -110,6 +116,23 @@ export class AppEmbed extends V1Embed {
|
|
|
110
116
|
}
|
|
111
117
|
return path;
|
|
112
118
|
}
|
|
119
|
+
/**
|
|
120
|
+
* Navigate to particular page for app embed. eg:answers/pinboards/home
|
|
121
|
+
* This is used for embedding answers, pinboards, visualizations and full application only.
|
|
122
|
+
* @param path The string, set to iframe src and navigate to new page
|
|
123
|
+
* eg: appEmbed.navigateToPage('pinboards')
|
|
124
|
+
*/
|
|
125
|
+
navigateToPage(path) {
|
|
126
|
+
if (this.iFrame) {
|
|
127
|
+
const iframeSrc = this.iFrame.src;
|
|
128
|
+
const embedPath = '#/embed';
|
|
129
|
+
const currentPath = iframeSrc.includes(embedPath) ? embedPath : '#';
|
|
130
|
+
this.iFrame.src = `${iframeSrc.split(currentPath)[0]}${currentPath}/${path.replace(/^\/?#?\//, '')}`;
|
|
131
|
+
}
|
|
132
|
+
else {
|
|
133
|
+
console.log('Please call render before invoking this method');
|
|
134
|
+
}
|
|
135
|
+
}
|
|
113
136
|
/**
|
|
114
137
|
* Renders the embedded application pages in the ThoughtSpot app.
|
|
115
138
|
* @param renderOptions An object containing the page ID
|
package/lib/src/embed/app.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"app.js","sourceRoot":"","sources":["../../../src/embed/app.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,OAAO,EAAE,cAAc,EAAE,mBAAmB,EAAE,MAAM,UAAU,CAAC;AAC/D,OAAO,EAAE,KAAK,EAA8B,MAAM,UAAU,CAAC;AAC7D,OAAO,EAAE,OAAO,EAAc,MAAM,YAAY,CAAC;AAEjD;;GAEG;AACH,qCAAqC;AACrC,MAAM,CAAN,IAAY,
|
|
1
|
+
{"version":3,"file":"app.js","sourceRoot":"","sources":["../../../src/embed/app.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,OAAO,EAAE,cAAc,EAAE,mBAAmB,EAAE,MAAM,UAAU,CAAC;AAC/D,OAAO,EAAE,KAAK,EAA8B,MAAM,UAAU,CAAC;AAC7D,OAAO,EAAE,OAAO,EAAc,MAAM,YAAY,CAAC;AAEjD;;GAEG;AACH,qCAAqC;AACrC,MAAM,CAAN,IAAY,IAyBX;AAzBD,WAAY,IAAI;IACZ;;OAEG;IACH,qBAAa,CAAA;IACb;;OAEG;IACH,yBAA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AAU,EAAE,EAAE,CAAC,EAAE,CAAC;SACpD;aAAM;YACH,OAAO,CAAC,GAAG,CAAC,gDAAgD,CAAC,CAAC;SACjE;IACL,CAAC;IAED;;;;OAIG;IACI,MAAM;QACT,KAAK,CAAC,MAAM,EAAE,CAAC;QAEf,MAAM,EAAE,MAAM,EAAE,cAAc,EAAE,IAAI,EAAE,GAAG,IAAI,CAAC,UAAU,CAAC;QACzD,MAAM,SAAS,GAAG,IAAI,CAAC,UAAU,CAAC,IAAI,CAAC,IAAI,IAAI,CAAC,YAAY,CAAC,MAAM,CAAC,CAAC;QACrE,MAAM,GAAG,GAAG,IAAI,CAAC,YAAY,CAAC,SAAS,EAAE,cAAc,CAAC,CAAC;QACzD,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,CAAC;QAExB,OAAO,IAAI,CAAC;IAChB,CAAC;CACJ"}
|
|
@@ -3,6 +3,7 @@ import { init } from '../index';
|
|
|
3
3
|
import { Action, AuthType, RuntimeFilterOp } from '../types';
|
|
4
4
|
import { executeAfterWait, getDocumentBody, getIFrameSrc, getRootEl, } from '../test/test-utils';
|
|
5
5
|
import { version } from '../../package.json';
|
|
6
|
+
import * as config from '../config';
|
|
6
7
|
const defaultViewConfig = {
|
|
7
8
|
frameParams: {
|
|
8
9
|
width: 1280,
|
|
@@ -11,6 +12,7 @@ const defaultViewConfig = {
|
|
|
11
12
|
};
|
|
12
13
|
const thoughtSpotHost = 'tshost';
|
|
13
14
|
const defaultParams = `&hostAppUrl=local-host&viewPortHeight=768&viewPortWidth=1024&sdkVersion=${version}`;
|
|
15
|
+
const defaultParamsForPinboardEmbed = `hostAppUrl=local-host&viewPortHeight=768&viewPortWidth=1024&sdkVersion=${version}`;
|
|
14
16
|
beforeAll(() => {
|
|
15
17
|
init({
|
|
16
18
|
thoughtSpotHost,
|
|
@@ -57,6 +59,7 @@ describe('App embed tests', () => {
|
|
|
57
59
|
[Page.Search]: 'answer',
|
|
58
60
|
[Page.Answers]: 'answers',
|
|
59
61
|
[Page.Pinboards]: 'pinboards',
|
|
62
|
+
[Page.Liveboards]: 'pinboards',
|
|
60
63
|
[Page.Data]: 'data/tables',
|
|
61
64
|
[Page.Home]: 'home',
|
|
62
65
|
};
|
|
@@ -128,5 +131,34 @@ describe('App embed tests', () => {
|
|
|
128
131
|
expect(getIFrameSrc()).toBe(`http://${thoughtSpotHost}/?embedApp=true&primaryNavHidden=true&profileAndHelpInNavBarHidden=false${defaultParams}&tag=Finance#/home`);
|
|
129
132
|
});
|
|
130
133
|
});
|
|
134
|
+
describe('Naviage to Page API', () => {
|
|
135
|
+
const path = 'pinboard/e0836cad-4fdf-42d4-bd97-567a6b2a6058';
|
|
136
|
+
beforeEach(() => {
|
|
137
|
+
jest.spyOn(config, 'getThoughtSpotHost').mockImplementation(() => 'http://tshost');
|
|
138
|
+
});
|
|
139
|
+
test('when app is AppEmbed after navigateToPage function call, new path should be set to iframe', async () => {
|
|
140
|
+
const appEmbed = new AppEmbed(getRootEl(), {
|
|
141
|
+
frameParams: {
|
|
142
|
+
width: '100%',
|
|
143
|
+
height: '100%',
|
|
144
|
+
},
|
|
145
|
+
});
|
|
146
|
+
await appEmbed.render();
|
|
147
|
+
appEmbed.navigateToPage(path);
|
|
148
|
+
expect(getIFrameSrc()).toBe(`http://${thoughtSpotHost}/?embedApp=true&primaryNavHidden=true&profileAndHelpInNavBarHidden=false&${defaultParamsForPinboardEmbed}#/${path}`);
|
|
149
|
+
});
|
|
150
|
+
test('navigateToPage function use before render', async () => {
|
|
151
|
+
spyOn(console, 'log');
|
|
152
|
+
const appEmbed = new AppEmbed(getRootEl(), {
|
|
153
|
+
frameParams: {
|
|
154
|
+
width: '100%',
|
|
155
|
+
height: '100%',
|
|
156
|
+
},
|
|
157
|
+
});
|
|
158
|
+
appEmbed.navigateToPage(path);
|
|
159
|
+
await appEmbed.render();
|
|
160
|
+
expect(console.log).toHaveBeenCalledWith('Please call render before invoking this method');
|
|
161
|
+
});
|
|
162
|
+
});
|
|
131
163
|
});
|
|
132
164
|
//# sourceMappingURL=app.spec.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"app.spec.js","sourceRoot":"","sources":["../../../src/embed/app.spec.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAiB,IAAI,EAAE,MAAM,OAAO,CAAC;AACtD,OAAO,EAAE,IAAI,EAAE,MAAM,UAAU,CAAC;AAChC,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,eAAe,EAAE,MAAM,UAAU,CAAC;AAC7D,OAAO,EACH,gBAAgB,EAChB,eAAe,EACf,YAAY,EACZ,SAAS,GACZ,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAAE,OAAO,EAAE,MAAM,oBAAoB,CAAC;
|
|
1
|
+
{"version":3,"file":"app.spec.js","sourceRoot":"","sources":["../../../src/embed/app.spec.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAiB,IAAI,EAAE,MAAM,OAAO,CAAC;AACtD,OAAO,EAAE,IAAI,EAAE,MAAM,UAAU,CAAC;AAChC,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,eAAe,EAAE,MAAM,UAAU,CAAC;AAC7D,OAAO,EACH,gBAAgB,EAChB,eAAe,EACf,YAAY,EACZ,SAAS,GACZ,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAAE,OAAO,EAAE,MAAM,oBAAoB,CAAC;AAC7C,OAAO,KAAK,MAAM,MAAM,WAAW,CAAC;AAEpC,MAAM,iBAAiB,GAAG;IACtB,WAAW,EAAE;QACT,KAAK,EAAE,IAAI;QACX,MAAM,EAAE,GAAG;KACd;CACJ,CAAC;AACF,MAAM,eAAe,GAAG,QAAQ,CAAC;AACjC,MAAM,aAAa,GAAG,2EAA2E,OAAO,EAAE,CAAC;AAC3G,MAAM,6BAA6B,GAAG,0EAA0E,OAAO,EAAE,CAAC;AAE1H,SAAS,CAAC,GAAG,EAAE;IACX,IAAI,CAAC;QACD,eAAe;QACf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