@thoughtspot/visual-embed-sdk 1.44.4 → 1.45.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/cjs/package.json +1 -1
- package/cjs/src/embed/app.d.ts +33 -1
- package/cjs/src/embed/app.d.ts.map +1 -1
- package/cjs/src/embed/app.js +10 -4
- package/cjs/src/embed/app.js.map +1 -1
- package/cjs/src/embed/app.spec.js +28 -7
- package/cjs/src/embed/app.spec.js.map +1 -1
- package/cjs/src/embed/conversation.d.ts +10 -6
- package/cjs/src/embed/conversation.d.ts.map +1 -1
- package/cjs/src/embed/conversation.js +12 -2
- package/cjs/src/embed/conversation.js.map +1 -1
- package/cjs/src/embed/conversation.spec.js +3 -0
- package/cjs/src/embed/conversation.spec.js.map +1 -1
- package/cjs/src/embed/embed.spec.js +1 -0
- package/cjs/src/embed/embed.spec.js.map +1 -1
- package/cjs/src/embed/liveboard.d.ts +32 -0
- package/cjs/src/embed/liveboard.d.ts.map +1 -1
- package/cjs/src/embed/liveboard.js +10 -4
- package/cjs/src/embed/liveboard.js.map +1 -1
- package/cjs/src/embed/liveboard.spec.js +57 -33
- package/cjs/src/embed/liveboard.spec.js.map +1 -1
- package/cjs/src/embed/pinboard.spec.js +1 -0
- package/cjs/src/embed/pinboard.spec.js.map +1 -1
- package/cjs/src/embed/search.d.ts +1 -0
- package/cjs/src/embed/search.d.ts.map +1 -1
- package/cjs/src/embed/search.js +10 -2
- package/cjs/src/embed/search.js.map +1 -1
- package/cjs/src/embed/search.spec.js +12 -0
- package/cjs/src/embed/search.spec.js.map +1 -1
- package/cjs/src/embed/ts-embed.d.ts.map +1 -1
- package/cjs/src/embed/ts-embed.js +7 -3
- package/cjs/src/embed/ts-embed.js.map +1 -1
- package/cjs/src/embed/ts-embed.spec.js +1 -0
- package/cjs/src/embed/ts-embed.spec.js.map +1 -1
- package/cjs/src/types.d.ts +236 -158
- package/cjs/src/types.d.ts.map +1 -1
- package/cjs/src/types.js +198 -125
- package/cjs/src/types.js.map +1 -1
- package/cjs/src/utils/graphql/answerService/answer-queries.d.ts +1 -1
- package/cjs/src/utils/graphql/answerService/answer-queries.d.ts.map +1 -1
- package/cjs/src/utils/graphql/answerService/answer-queries.js +0 -1
- package/cjs/src/utils/graphql/answerService/answer-queries.js.map +1 -1
- package/cjs/src/utils/graphql/answerService/answerService.spec.js +0 -1
- package/cjs/src/utils/graphql/answerService/answerService.spec.js.map +1 -1
- package/cjs/src/utils/processTrigger.js +1 -1
- package/cjs/src/utils/processTrigger.js.map +1 -1
- package/cjs/src/utils/processTrigger.spec.js +12 -0
- package/cjs/src/utils/processTrigger.spec.js.map +1 -1
- package/dist/{index-C5FAW929.js → index-Dk-SLdNk.js} +1 -1
- package/dist/src/embed/app.d.ts +33 -1
- package/dist/src/embed/app.d.ts.map +1 -1
- package/dist/src/embed/conversation.d.ts +10 -6
- package/dist/src/embed/conversation.d.ts.map +1 -1
- package/dist/src/embed/liveboard.d.ts +32 -0
- package/dist/src/embed/liveboard.d.ts.map +1 -1
- package/dist/src/embed/search.d.ts +1 -0
- package/dist/src/embed/search.d.ts.map +1 -1
- package/dist/src/embed/ts-embed.d.ts.map +1 -1
- package/dist/src/types.d.ts +236 -158
- package/dist/src/types.d.ts.map +1 -1
- package/dist/src/utils/graphql/answerService/answer-queries.d.ts +1 -1
- package/dist/src/utils/graphql/answerService/answer-queries.d.ts.map +1 -1
- package/dist/tsembed-react.es.js +251 -145
- package/dist/tsembed-react.js +250 -144
- package/dist/tsembed.es.js +251 -145
- package/dist/tsembed.js +250 -144
- package/dist/visual-embed-sdk-react-full.d.ts +303 -146
- package/dist/visual-embed-sdk-react.d.ts +303 -146
- package/dist/visual-embed-sdk.d.ts +308 -163
- package/lib/package.json +1 -1
- package/lib/src/embed/app.d.ts +33 -1
- package/lib/src/embed/app.d.ts.map +1 -1
- package/lib/src/embed/app.js +10 -4
- package/lib/src/embed/app.js.map +1 -1
- package/lib/src/embed/app.spec.js +28 -7
- package/lib/src/embed/app.spec.js.map +1 -1
- package/lib/src/embed/conversation.d.ts +10 -6
- package/lib/src/embed/conversation.d.ts.map +1 -1
- package/lib/src/embed/conversation.js +12 -2
- package/lib/src/embed/conversation.js.map +1 -1
- package/lib/src/embed/conversation.spec.js +3 -0
- package/lib/src/embed/conversation.spec.js.map +1 -1
- package/lib/src/embed/embed.spec.js +1 -0
- package/lib/src/embed/embed.spec.js.map +1 -1
- package/lib/src/embed/liveboard.d.ts +32 -0
- package/lib/src/embed/liveboard.d.ts.map +1 -1
- package/lib/src/embed/liveboard.js +10 -4
- package/lib/src/embed/liveboard.js.map +1 -1
- package/lib/src/embed/liveboard.spec.js +57 -33
- package/lib/src/embed/liveboard.spec.js.map +1 -1
- package/lib/src/embed/pinboard.spec.js +1 -0
- package/lib/src/embed/pinboard.spec.js.map +1 -1
- package/lib/src/embed/search.d.ts +1 -0
- package/lib/src/embed/search.d.ts.map +1 -1
- package/lib/src/embed/search.js +10 -2
- package/lib/src/embed/search.js.map +1 -1
- package/lib/src/embed/search.spec.js +12 -0
- package/lib/src/embed/search.spec.js.map +1 -1
- package/lib/src/embed/ts-embed.d.ts.map +1 -1
- package/lib/src/embed/ts-embed.js +7 -3
- package/lib/src/embed/ts-embed.js.map +1 -1
- package/lib/src/embed/ts-embed.spec.js +1 -0
- package/lib/src/embed/ts-embed.spec.js.map +1 -1
- package/lib/src/types.d.ts +236 -158
- package/lib/src/types.d.ts.map +1 -1
- package/lib/src/types.js +198 -125
- package/lib/src/types.js.map +1 -1
- package/lib/src/utils/graphql/answerService/answer-queries.d.ts +1 -1
- package/lib/src/utils/graphql/answerService/answer-queries.d.ts.map +1 -1
- package/lib/src/utils/graphql/answerService/answer-queries.js +0 -1
- package/lib/src/utils/graphql/answerService/answer-queries.js.map +1 -1
- package/lib/src/utils/graphql/answerService/answerService.spec.js +0 -1
- package/lib/src/utils/graphql/answerService/answerService.spec.js.map +1 -1
- package/lib/src/utils/processTrigger.js +1 -1
- package/lib/src/utils/processTrigger.js.map +1 -1
- package/lib/src/utils/processTrigger.spec.js +12 -0
- package/lib/src/utils/processTrigger.spec.js.map +1 -1
- package/package.json +1 -1
- package/src/embed/app.spec.ts +39 -7
- package/src/embed/app.ts +50 -6
- package/src/embed/conversation.spec.ts +3 -0
- package/src/embed/conversation.ts +22 -8
- package/src/embed/embed.spec.ts +1 -0
- package/src/embed/liveboard.spec.ts +77 -42
- package/src/embed/liveboard.ts +47 -5
- package/src/embed/pinboard.spec.ts +1 -0
- package/src/embed/search.spec.ts +16 -0
- package/src/embed/search.ts +12 -1
- package/src/embed/ts-embed.spec.ts +1 -0
- package/src/embed/ts-embed.ts +7 -3
- package/src/types.ts +263 -184
- package/src/utils/graphql/answerService/answer-queries.ts +0 -1
- package/src/utils/graphql/answerService/answerService.spec.ts +0 -1
- package/src/utils/processTrigger.spec.ts +18 -0
- package/src/utils/processTrigger.ts +1 -1
package/dist/tsembed.es.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* @thoughtspot/visual-embed-sdk version 1.
|
|
1
|
+
/* @thoughtspot/visual-embed-sdk version 1.45.0 */
|
|
2
2
|
'use client';
|
|
3
3
|
function _mergeNamespaces(n, m) {
|
|
4
4
|
m.forEach(function (e) {
|
|
@@ -360,7 +360,11 @@ var HomepageModule;
|
|
|
360
360
|
var ListPageColumns;
|
|
361
361
|
(function (ListPageColumns) {
|
|
362
362
|
/**
|
|
363
|
-
*
|
|
363
|
+
* Favorites
|
|
364
|
+
*/
|
|
365
|
+
ListPageColumns["Favorites"] = "FAVOURITE";
|
|
366
|
+
/**
|
|
367
|
+
* @deprecated Use {@link ListPageColumns.Favorites} instead.
|
|
364
368
|
*/
|
|
365
369
|
ListPageColumns["Favourite"] = "FAVOURITE";
|
|
366
370
|
/**
|
|
@@ -379,6 +383,10 @@ var ListPageColumns;
|
|
|
379
383
|
* Share
|
|
380
384
|
*/
|
|
381
385
|
ListPageColumns["Share"] = "SHARE";
|
|
386
|
+
/**
|
|
387
|
+
* Verified badge/column
|
|
388
|
+
*/
|
|
389
|
+
ListPageColumns["Verified"] = "VERIFIED";
|
|
382
390
|
})(ListPageColumns || (ListPageColumns = {}));
|
|
383
391
|
/**
|
|
384
392
|
* Event types emitted by the embedded ThoughtSpot application.
|
|
@@ -595,7 +603,7 @@ var EmbedEvent;
|
|
|
595
603
|
/**
|
|
596
604
|
* An error has occurred. This event is fired for the following error types:
|
|
597
605
|
*
|
|
598
|
-
* `API` - API call failure
|
|
606
|
+
* `API` - API call failure.
|
|
599
607
|
* `FULLSCREEN` - Error when presenting a Liveboard or visualization in full screen
|
|
600
608
|
* mode. `SINGLE_VALUE_FILTER` - Error due to multiple values in the single value
|
|
601
609
|
* filter. `NON_EXIST_FILTER` - Error due to a non-existent filter.
|
|
@@ -1326,20 +1334,20 @@ var EmbedEvent;
|
|
|
1326
1334
|
/**
|
|
1327
1335
|
*
|
|
1328
1336
|
* This event can be emitted to intercept search execution initiated by
|
|
1329
|
-
*
|
|
1330
|
-
* You can
|
|
1337
|
+
* users and implement logic to allow or restrict search execution.
|
|
1338
|
+
* You can also show custom error text if the search query must be
|
|
1331
1339
|
* restricted due to your application or business requirements.
|
|
1332
1340
|
|
|
1333
1341
|
* Prerequisite: Set `isOnBeforeGetVizDataInterceptEnabled` to `true`
|
|
1334
1342
|
* for this embed event to get emitted.
|
|
1335
|
-
* @param
|
|
1336
|
-
*
|
|
1337
|
-
* Contains elements that
|
|
1338
|
-
*
|
|
1339
|
-
*
|
|
1343
|
+
* @param - Includes the following event listener parameters:
|
|
1344
|
+
* - `payload`: The payload received from the embed related to the Data API call.
|
|
1345
|
+
* - `responder`: Contains elements that let developers define whether ThoughtSpot
|
|
1346
|
+
* should run the search, and if not, what error message
|
|
1347
|
+
* should be shown to the user.
|
|
1340
1348
|
*
|
|
1341
|
-
* `execute` - When execute returns `true`, the search will be run.
|
|
1342
|
-
* When execute returns `false`, the search will not be executed.
|
|
1349
|
+
* `execute` - When `execute` returns `true`, the search will be run.
|
|
1350
|
+
* When `execute` returns `false`, the search will not be executed.
|
|
1343
1351
|
*
|
|
1344
1352
|
* `error` - Developers can customize the error message text when `execute`
|
|
1345
1353
|
* is `false` using the `errorText` and `errorDescription` parameters in responder.
|
|
@@ -1511,7 +1519,7 @@ var EmbedEvent;
|
|
|
1511
1519
|
* console.log('payload', payload);
|
|
1512
1520
|
* })
|
|
1513
1521
|
* ```
|
|
1514
|
-
* @version SDK: 1.
|
|
1522
|
+
* @version SDK: 1.46.0 | ThoughtSpot: 26.3.0.cl
|
|
1515
1523
|
*/
|
|
1516
1524
|
EmbedEvent["DataModelInstructions"] = "DataModelInstructions";
|
|
1517
1525
|
/**
|
|
@@ -1730,14 +1738,14 @@ var HostEvent;
|
|
|
1730
1738
|
* the search query string.
|
|
1731
1739
|
* Supported in `AppEmbed` and `SearchEmbed` deployments.
|
|
1732
1740
|
* Includes the following properties:
|
|
1733
|
-
* @param -
|
|
1734
|
-
*
|
|
1735
|
-
*
|
|
1736
|
-
*
|
|
1737
|
-
*
|
|
1741
|
+
* @param - Includes the following keys:
|
|
1742
|
+
* - `searchQuery`: Query string with search tokens.
|
|
1743
|
+
* - `dataSources`: Data source GUID to search on.
|
|
1744
|
+
* Although an array, only a single source is supported.
|
|
1745
|
+
* - `execute`: Executes search and updates the existing query.
|
|
1738
1746
|
* @example
|
|
1739
1747
|
* ```js
|
|
1740
|
-
*
|
|
1748
|
+
* searchEmbed.trigger(HostEvent.Search, {
|
|
1741
1749
|
searchQuery: "[sales] by [item type]",
|
|
1742
1750
|
dataSources: ["cd252e5c-b552-49a8-821d-3eadaa049cca"],
|
|
1743
1751
|
execute: true
|
|
@@ -1748,16 +1756,15 @@ var HostEvent;
|
|
|
1748
1756
|
/**
|
|
1749
1757
|
* Triggers a drill on certain points of the specified column
|
|
1750
1758
|
* Includes the following properties:
|
|
1751
|
-
* @param -
|
|
1752
|
-
*
|
|
1753
|
-
*
|
|
1754
|
-
*
|
|
1755
|
-
* column.
|
|
1756
|
-
*
|
|
1757
|
-
*
|
|
1758
|
-
*
|
|
1759
|
-
*
|
|
1760
|
-
* @param - `vizId` refers to the Answer ID in Spotter embed and is required in Spotter embed.
|
|
1759
|
+
* @param - Includes the following keys:
|
|
1760
|
+
* - `points`: An object containing `selectedPoints` and/or `clickedPoint`
|
|
1761
|
+
* to drill to. For example, `{ selectedPoints: [] }`.
|
|
1762
|
+
* - `columnGuid`: Optional. GUID of the column to drill by. If not provided,
|
|
1763
|
+
* it will auto drill by the configured column.
|
|
1764
|
+
* - `autoDrillDown`: Optional. If `true`, the drill down will be done automatically
|
|
1765
|
+
* on the most popular column.
|
|
1766
|
+
* - `vizId` (TS >= 9.8.0): Optional. The GUID of the visualization to drill in case
|
|
1767
|
+
* of a Liveboard. In Spotter embed, `vizId` refers to the Answer ID and is **required**.
|
|
1761
1768
|
* @example
|
|
1762
1769
|
* ```js
|
|
1763
1770
|
* searchEmbed.on(EmbedEvent.VizPointDoubleClick, (payload) => {
|
|
@@ -1850,14 +1857,12 @@ var HostEvent;
|
|
|
1850
1857
|
* and `AppEmbed` only. In full application embedding, this event updates
|
|
1851
1858
|
* the runtime filters applied on the Liveboard and saved Answer objects.
|
|
1852
1859
|
*
|
|
1853
|
-
* @param -
|
|
1854
|
-
* `columnName
|
|
1855
|
-
*
|
|
1856
|
-
*
|
|
1857
|
-
*
|
|
1858
|
-
*
|
|
1859
|
-
* `values` - List of operands. Some operators such as EQ and LE allow a
|
|
1860
|
-
* single value, whereas BW and IN accept multiple values.
|
|
1860
|
+
* @param - Array of {@link RuntimeFilter} objects. Each item includes:
|
|
1861
|
+
* - `columnName`: Name of the column to filter on.
|
|
1862
|
+
* - `operator`: {@link RuntimeFilterOp} to apply. For more information, see
|
|
1863
|
+
* link:https://developers.thoughtspot.com/docs/runtime-filters#rtOperator[Developer Documentation].
|
|
1864
|
+
* - `values`: List of operands. Some operators such as EQ and LE allow a single
|
|
1865
|
+
* value, whereas BW and IN accept multiple values.
|
|
1861
1866
|
*
|
|
1862
1867
|
* **Note**: Updating runtime filters resets the ThoughtSpot
|
|
1863
1868
|
* object to its original state and applies new filter conditions.
|
|
@@ -1880,7 +1885,7 @@ var HostEvent;
|
|
|
1880
1885
|
/**
|
|
1881
1886
|
* Navigate to a specific page in the embedded ThoughtSpot application.
|
|
1882
1887
|
* This is the same as calling `appEmbed.navigateToPage(path, true)`.
|
|
1883
|
-
* @param - `path` - the path to navigate to
|
|
1888
|
+
* @param - `path` - the path to navigate to go forward or back. The path value can
|
|
1884
1889
|
* be a number; for example, `1`, `-1`.
|
|
1885
1890
|
* @example
|
|
1886
1891
|
* ```js
|
|
@@ -1951,30 +1956,25 @@ var HostEvent;
|
|
|
1951
1956
|
* for the Answer that the user is currently on
|
|
1952
1957
|
* and a modal opens for Liveboard selection.
|
|
1953
1958
|
* To add an Answer or visualization to a Liveboard programmatically without
|
|
1954
|
-
*
|
|
1959
|
+
* requiring additional user input via the *Pin to Liveboard* modal, define
|
|
1955
1960
|
* the following parameters:
|
|
1956
1961
|
*
|
|
1957
|
-
* @param
|
|
1958
|
-
* `vizId
|
|
1959
|
-
*
|
|
1960
|
-
*
|
|
1961
|
-
*
|
|
1962
|
-
* `
|
|
1963
|
-
*
|
|
1964
|
-
*
|
|
1965
|
-
*
|
|
1966
|
-
*
|
|
1967
|
-
*
|
|
1968
|
-
*
|
|
1969
|
-
*
|
|
1970
|
-
*
|
|
1971
|
-
*
|
|
1972
|
-
*
|
|
1973
|
-
* `newLiveboardName` - Name string for the Liveboard.
|
|
1974
|
-
* Creates a new Liveboard object with the specified name.
|
|
1975
|
-
* @param
|
|
1976
|
-
* `newTabName` - Name of the tab. Adds a new tab Liveboard specified
|
|
1977
|
-
* in the code.
|
|
1962
|
+
* @param - Includes the following keys:
|
|
1963
|
+
* - `vizId`: GUID of the saved Answer or Spotter visualization ID to pin to a Liveboard.
|
|
1964
|
+
* Optional when pinning a new chart or table generated from a Search query.
|
|
1965
|
+
* **Required** in Spotter Embed.
|
|
1966
|
+
* - `liveboardId`: GUID of the Liveboard to pin an Answer. If there is no Liveboard,
|
|
1967
|
+
* specify the `newLiveboardName` parameter to create a new Liveboard.
|
|
1968
|
+
* - `tabId`: GUID of the Liveboard tab. Adds the Answer to the Liveboard tab
|
|
1969
|
+
* specified in the code.
|
|
1970
|
+
* - `newVizName`: Name string for the Answer or visualization. If defined,
|
|
1971
|
+
* this parameter adds a new visualization object or creates a copy of the
|
|
1972
|
+
* Answer or visualization specified in `vizId`.
|
|
1973
|
+
* Required.
|
|
1974
|
+
* - `newLiveboardName`: Name string for the Liveboard.
|
|
1975
|
+
* Creates a new Liveboard object with the specified name.
|
|
1976
|
+
* - `newTabName`: Name of the tab. Adds a new tab Liveboard specified
|
|
1977
|
+
* in the code.
|
|
1978
1978
|
*
|
|
1979
1979
|
* @example
|
|
1980
1980
|
* ```js
|
|
@@ -2214,9 +2214,9 @@ var HostEvent;
|
|
|
2214
2214
|
* on a Liveboard.
|
|
2215
2215
|
*
|
|
2216
2216
|
* This event is not supported in visualization embed and search embed.
|
|
2217
|
-
* @param -
|
|
2218
|
-
*
|
|
2219
|
-
*
|
|
2217
|
+
* @param - Object parameter. Includes the following keys:
|
|
2218
|
+
* - `vizId`: To trigger the action for a specific visualization in Liveboard embed,
|
|
2219
|
+
* pass in `vizId` as a key. In Spotter embed, `vizId` refers to the Answer ID and is **required**.
|
|
2220
2220
|
*
|
|
2221
2221
|
* @example
|
|
2222
2222
|
* ```js
|
|
@@ -2583,10 +2583,9 @@ var HostEvent;
|
|
|
2583
2583
|
HostEvent["GetFilters"] = "getFilters";
|
|
2584
2584
|
/**
|
|
2585
2585
|
* Update one or several filters applied on a Liveboard.
|
|
2586
|
-
* @param -
|
|
2587
|
-
* filter operator, and values.
|
|
2588
|
-
*
|
|
2589
|
-
* and values for each.
|
|
2586
|
+
* @param - Includes the following keys:
|
|
2587
|
+
* - `filter`: A single filter object containing column name, filter operator, and values.
|
|
2588
|
+
* - `filters`: Multiple filter objects with column name, filter operator, and values for each.
|
|
2590
2589
|
*
|
|
2591
2590
|
* Each filter object must include the following attributes:
|
|
2592
2591
|
*
|
|
@@ -2712,8 +2711,9 @@ var HostEvent;
|
|
|
2712
2711
|
HostEvent["SetHiddenTabs"] = "SetPinboardHiddenTabs";
|
|
2713
2712
|
/**
|
|
2714
2713
|
* Updates the search query string for Natural Language Search operations.
|
|
2715
|
-
* @param -
|
|
2716
|
-
*
|
|
2714
|
+
* @param - Includes the following keys:
|
|
2715
|
+
* - `queryString`: Text string in Natural Language format.
|
|
2716
|
+
* - `executeSearch`: Boolean to execute search and update search query.
|
|
2717
2717
|
* @example
|
|
2718
2718
|
* ```js
|
|
2719
2719
|
* sageEmbed.trigger(HostEvent.UpdateSageQuery, {
|
|
@@ -2792,11 +2792,10 @@ var HostEvent;
|
|
|
2792
2792
|
/**
|
|
2793
2793
|
* Triggers an action to update Parameter values on embedded
|
|
2794
2794
|
* Answers, Liveboard, and Spotter answer in Edit mode.
|
|
2795
|
-
* @param -
|
|
2796
|
-
*
|
|
2797
|
-
*
|
|
2798
|
-
*
|
|
2799
|
-
* use the `isVisibleToUser` attribute when applying an override.
|
|
2795
|
+
* @param - Includes the following keys for each item:
|
|
2796
|
+
* - `name`: Name of the parameter.
|
|
2797
|
+
* - `value`: The value to set for the parameter.
|
|
2798
|
+
* - `isVisibleToUser`: Optional. To control the visibility of the parameter chip.
|
|
2800
2799
|
*
|
|
2801
2800
|
* @example
|
|
2802
2801
|
* ```js
|
|
@@ -2854,11 +2853,10 @@ var HostEvent;
|
|
|
2854
2853
|
* If no parameters are specified, the save action is
|
|
2855
2854
|
* triggered with a modal to prompt users to
|
|
2856
2855
|
* add a name and description for the Answer.
|
|
2857
|
-
* @param -
|
|
2858
|
-
* and is required in Spotter embed.
|
|
2859
|
-
* Optional
|
|
2860
|
-
*
|
|
2861
|
-
* @param - `description` - Description text for the Answer.
|
|
2856
|
+
* @param - Includes the following keys:
|
|
2857
|
+
* - `vizId`: Refers to the Answer ID in Spotter embed and is **required** in Spotter embed.
|
|
2858
|
+
* - `name`: Optional. Name string for the Answer.
|
|
2859
|
+
* - `description`: Optional. Description text for the Answer.
|
|
2862
2860
|
* @example
|
|
2863
2861
|
* ```js
|
|
2864
2862
|
* const saveAnswerResponse = await searchEmbed.trigger(HostEvent.SaveAnswer, {
|
|
@@ -2907,8 +2905,9 @@ var HostEvent;
|
|
|
2907
2905
|
/**
|
|
2908
2906
|
* Triggers a search operation with the search tokens specified in
|
|
2909
2907
|
* the search query string in spotter embed.
|
|
2910
|
-
* @param -
|
|
2911
|
-
*
|
|
2908
|
+
* @param - Includes the following keys:
|
|
2909
|
+
* - `query`: Text string in Natural Language format.
|
|
2910
|
+
* - `executeSearch`: Boolean to execute search and update search query.
|
|
2912
2911
|
* @example
|
|
2913
2912
|
* ```js
|
|
2914
2913
|
* spotterEmbed.trigger(HostEvent.SpotterSearch, {
|
|
@@ -2955,7 +2954,7 @@ var HostEvent;
|
|
|
2955
2954
|
* ```js
|
|
2956
2955
|
* spotterEmbed.trigger(HostEvent.DataModelInstructions);
|
|
2957
2956
|
* ```
|
|
2958
|
-
* @version SDK: 1.
|
|
2957
|
+
* @version SDK: 1.46.0 | ThoughtSpot: 26.3.0.cl
|
|
2959
2958
|
*/
|
|
2960
2959
|
HostEvent["DataModelInstructions"] = "DataModelInstructions";
|
|
2961
2960
|
/**
|
|
@@ -3040,7 +3039,7 @@ var HostEvent;
|
|
|
3040
3039
|
*/
|
|
3041
3040
|
HostEvent["UpdateEmbedParams"] = "updateEmbedParams";
|
|
3042
3041
|
/**
|
|
3043
|
-
* Triggered when the embed
|
|
3042
|
+
* Triggered when the embed needs to be destroyed. This is used to clean up any embed-related resources internally.
|
|
3044
3043
|
* @example
|
|
3045
3044
|
* ```js
|
|
3046
3045
|
* liveboardEmbed.trigger(HostEvent.DestroyEmbed);
|
|
@@ -3048,11 +3047,12 @@ var HostEvent;
|
|
|
3048
3047
|
* @version SDK: 1.41.0 | ThoughtSpot: 10.12.0.cl
|
|
3049
3048
|
*/
|
|
3050
3049
|
HostEvent["DestroyEmbed"] = "EmbedDestroyed";
|
|
3051
|
-
/**
|
|
3052
|
-
*
|
|
3053
|
-
*
|
|
3050
|
+
/**
|
|
3051
|
+
* Triggers a new conversation in Spotter embed.
|
|
3052
|
+
*
|
|
3054
3053
|
* This feature is available only when chat history is enabled on your ThoughtSpot instance.
|
|
3055
3054
|
* Contact your admin or ThoughtSpot Support to enable chat history on your instance.
|
|
3055
|
+
*
|
|
3056
3056
|
* @example
|
|
3057
3057
|
* ```js
|
|
3058
3058
|
* spotterEmbed.trigger(HostEvent.StartNewSpotterConversation);
|
|
@@ -3209,12 +3209,14 @@ var Param;
|
|
|
3209
3209
|
Param["IsLiveboardStylingAndGroupingEnabled"] = "isLiveboardStylingAndGroupingEnabled";
|
|
3210
3210
|
Param["IsLazyLoadingForEmbedEnabled"] = "isLazyLoadingForEmbedEnabled";
|
|
3211
3211
|
Param["RootMarginForLazyLoad"] = "rootMarginForLazyLoad";
|
|
3212
|
-
Param["LiveboardXLSXCSVDownload"] = "isLiveboardXLSXCSVDownloadEnabled";
|
|
3213
3212
|
Param["isPNGInScheduledEmailsEnabled"] = "isPNGInScheduledEmailsEnabled";
|
|
3213
|
+
Param["isLiveboardXLSXCSVDownloadEnabled"] = "isLiveboardXLSXCSVDownloadEnabled";
|
|
3214
|
+
Param["isGranularXLSXCSVSchedulesEnabled"] = "isGranularXLSXCSVSchedulesEnabled";
|
|
3214
3215
|
Param["isCentralizedLiveboardFilterUXEnabled"] = "isCentralizedLiveboardFilterUXEnabled";
|
|
3215
3216
|
Param["isLinkParametersEnabled"] = "isLinkParametersEnabled";
|
|
3216
3217
|
Param["EnablePastConversationsSidebar"] = "enablePastConversationsSidebar";
|
|
3217
3218
|
Param["UpdatedSpotterChatPrompt"] = "updatedSpotterChatPrompt";
|
|
3219
|
+
Param["IsThisPeriodInDateFiltersEnabled"] = "isThisPeriodInDateFiltersEnabled";
|
|
3218
3220
|
})(Param || (Param = {}));
|
|
3219
3221
|
/**
|
|
3220
3222
|
* ThoughtSpot application pages include actions and menu commands
|
|
@@ -3227,7 +3229,7 @@ var Param;
|
|
|
3227
3229
|
* ```js
|
|
3228
3230
|
* const embed = new LiveboardEmbed('#tsEmbed', {
|
|
3229
3231
|
* ... //other embed view config
|
|
3230
|
-
* visibleActions: [Action.Save, Action.Edit, Action.Present,
|
|
3232
|
+
* visibleActions: [Action.Save, Action.Edit, Action.Present, Action.Explore],
|
|
3231
3233
|
* disabledActions: [Action.Download],
|
|
3232
3234
|
* //hiddenActions: [], // Set either this or visibleActions
|
|
3233
3235
|
* })
|
|
@@ -3238,10 +3240,10 @@ var Param;
|
|
|
3238
3240
|
* ... //other embed view config
|
|
3239
3241
|
* //visibleActions: [],
|
|
3240
3242
|
* disabledActions: [Action.Download],
|
|
3241
|
-
* hiddenActions: [Action.Edit,
|
|
3243
|
+
* hiddenActions: [Action.Edit, Action.Explore],
|
|
3242
3244
|
* })
|
|
3243
3245
|
* ```
|
|
3244
|
-
* See also link:https://developers.thoughtspot.com/docs/actions[
|
|
3246
|
+
* See also link:https://developers.thoughtspot.com/docs/actions[Developer Documentation].
|
|
3245
3247
|
*/
|
|
3246
3248
|
var Action;
|
|
3247
3249
|
(function (Action) {
|
|
@@ -3529,6 +3531,16 @@ var Action;
|
|
|
3529
3531
|
* ```
|
|
3530
3532
|
*/
|
|
3531
3533
|
Action["DownloadAsXlsx"] = "downloadAsXLSX";
|
|
3534
|
+
/**
|
|
3535
|
+
* The **Download Liveboard** menu action on a Liveboard.
|
|
3536
|
+
* Allows downloading the entire Liveboard.
|
|
3537
|
+
* @example
|
|
3538
|
+
* ```js
|
|
3539
|
+
* disabledActions: [Action.DownloadLiveboard]
|
|
3540
|
+
* ```
|
|
3541
|
+
* @version SDK: 1.46.0 | ThoughtSpot: 26.3.0.cl
|
|
3542
|
+
*/
|
|
3543
|
+
Action["DownloadLiveboard"] = "downloadLiveboard";
|
|
3532
3544
|
/**
|
|
3533
3545
|
* @hidden
|
|
3534
3546
|
*/
|
|
@@ -3748,13 +3760,15 @@ var Action;
|
|
|
3748
3760
|
*/
|
|
3749
3761
|
Action["RequestAccess"] = "requestAccess";
|
|
3750
3762
|
/**
|
|
3751
|
-
*
|
|
3752
|
-
* Query details panel
|
|
3763
|
+
* Controls the display and availability of the **Query visualizer** and
|
|
3764
|
+
* **Query SQL** buttons in the Query details panel on the Answer page.
|
|
3753
3765
|
*
|
|
3754
|
-
* **Query visualizer** - Displays the tables
|
|
3755
|
-
*
|
|
3756
|
-
*
|
|
3757
|
-
*
|
|
3766
|
+
* **Query visualizer** - Displays the tables and filters used in the search query.
|
|
3767
|
+
* **Query SQL** - Displays the SQL statements used to retrieve data for the query.
|
|
3768
|
+
*
|
|
3769
|
+
* Note: This action ID only affects the visibility of the buttons within the
|
|
3770
|
+
* Query details panel. It does not control the visibility
|
|
3771
|
+
* of the query details icon on the Answer page.
|
|
3758
3772
|
* @example
|
|
3759
3773
|
* ```js
|
|
3760
3774
|
* disabledActions: [Action.QueryDetailsButtons]
|
|
@@ -3868,28 +3882,28 @@ var Action;
|
|
|
3868
3882
|
Action["CrossFilter"] = "context-menu-item-cross-filter";
|
|
3869
3883
|
/**
|
|
3870
3884
|
* The **Sync to Slack** action on Liveboard visualizations.
|
|
3871
|
-
* Allows sending data to third-party apps Slack
|
|
3885
|
+
* Allows sending data to third-party apps like Slack.
|
|
3872
3886
|
* @example
|
|
3873
3887
|
* ```js
|
|
3874
3888
|
* disabledActions: [Action.SyncToSlack]
|
|
3875
3889
|
* ```
|
|
3876
|
-
* @version
|
|
3890
|
+
* @version SDK: 1.32.0 | ThoughtSpot Cloud: 10.1.0.cl
|
|
3877
3891
|
*/
|
|
3878
3892
|
Action["SyncToSlack"] = "syncToSlack";
|
|
3879
3893
|
/**
|
|
3880
3894
|
* The **Sync to Teams** action on Liveboard visualizations.
|
|
3881
|
-
* Allows sending data to third-party apps
|
|
3895
|
+
* Allows sending data to third-party apps like Microsoft Teams.
|
|
3882
3896
|
* @example
|
|
3883
3897
|
* ```js
|
|
3884
3898
|
* disabledActions: [Action.SyncToTeams]
|
|
3885
3899
|
* ```
|
|
3886
|
-
* @version
|
|
3900
|
+
* @version SDK: 1.32.0 | ThoughtSpot Cloud: 10.1.0.cl
|
|
3887
3901
|
*/
|
|
3888
3902
|
Action["SyncToTeams"] = "syncToTeams";
|
|
3889
3903
|
/**
|
|
3890
3904
|
* The **Remove** action that appears when cross filters are applied
|
|
3891
3905
|
* on a Liveboard.
|
|
3892
|
-
* Removes filters applied
|
|
3906
|
+
* Removes filters applied to a visualization.
|
|
3893
3907
|
* @example
|
|
3894
3908
|
* ```js
|
|
3895
3909
|
* disabledActions: [Action.RemoveCrossFilter]
|
|
@@ -4075,7 +4089,7 @@ var Action;
|
|
|
4075
4089
|
Action["AddTab"] = "addTab";
|
|
4076
4090
|
/**
|
|
4077
4091
|
*
|
|
4078
|
-
*Initiates contextual change analysis on KPI charts.
|
|
4092
|
+
* Initiates contextual change analysis on KPI charts.
|
|
4079
4093
|
* @example
|
|
4080
4094
|
* ```js
|
|
4081
4095
|
* disabledActions: [Action.EnableContextualChangeAnalysis]
|
|
@@ -4085,7 +4099,7 @@ var Action;
|
|
|
4085
4099
|
Action["EnableContextualChangeAnalysis"] = "enableContextualChangeAnalysis";
|
|
4086
4100
|
/**
|
|
4087
4101
|
* Action ID to hide or disable Iterative Change Analysis option
|
|
4088
|
-
*
|
|
4102
|
+
* in the contextual change analysis Insight charts context menu.
|
|
4089
4103
|
*
|
|
4090
4104
|
* @example
|
|
4091
4105
|
* ```js
|
|
@@ -4363,6 +4377,17 @@ var Action;
|
|
|
4363
4377
|
* @version SDK: 1.36.0 | ThoughtSpot Cloud: 10.6.0.cl
|
|
4364
4378
|
*/
|
|
4365
4379
|
Action["ChangeFilterVisibilityInTab"] = "changeFilterVisibilityInTab";
|
|
4380
|
+
/**
|
|
4381
|
+
* The **Data model instructions** button on the Spotter interface.
|
|
4382
|
+
* Allows opening the data model instructions modal.
|
|
4383
|
+
*
|
|
4384
|
+
* @example
|
|
4385
|
+
* ```js
|
|
4386
|
+
* hiddenAction: [Action.DataModelInstructions]
|
|
4387
|
+
* ```
|
|
4388
|
+
* @version SDK: 1.46.0 | ThoughtSpot Cloud: 26.3.0.cl
|
|
4389
|
+
*/
|
|
4390
|
+
Action["DataModelInstructions"] = "DataModelInstructions";
|
|
4366
4391
|
/**
|
|
4367
4392
|
* The **Preview data** button on the Spotter interface.
|
|
4368
4393
|
* Allows previewing the data used for Spotter queries.
|
|
@@ -4448,12 +4473,11 @@ var Action;
|
|
|
4448
4473
|
*/
|
|
4449
4474
|
Action["CoverAndFilterOptionInPDF"] = "coverAndFilterOptionInPDF";
|
|
4450
4475
|
/**
|
|
4451
|
-
|
|
4452
|
-
|
|
4453
|
-
|
|
4454
|
-
|
|
4455
|
-
|
|
4456
|
-
* contact ThoughtSpot Support.
|
|
4476
|
+
* Action ID to hide or disable the Coaching workflow in Spotter conversations.
|
|
4477
|
+
* When disabled, users cannot access **Add to Coaching** workflow in conversation.
|
|
4478
|
+
* The **Add to Coaching** feature allows adding reference questions and
|
|
4479
|
+
* business terms to improve Spotter’s responses. This feature is generally available
|
|
4480
|
+
* (GA) from version 26.2.0.cl and enabled by default on embed deployments.
|
|
4457
4481
|
* @example
|
|
4458
4482
|
* ```js
|
|
4459
4483
|
* hiddenAction: [Action.InConversationTraining]
|
|
@@ -4529,6 +4553,55 @@ var Action;
|
|
|
4529
4553
|
* @version SDK: 1.43.0 | ThoughtSpot Cloud: 10.15.0.cl
|
|
4530
4554
|
*/
|
|
4531
4555
|
Action["LiveboardStylePanel"] = "liveboardStylePanel";
|
|
4556
|
+
/**
|
|
4557
|
+
* The **Publish** action for Liveboards, Answers and Models.
|
|
4558
|
+
* Opens the publishing modal. It's a parent action for the
|
|
4559
|
+
* **Manage Publishing** and **Unpublish** actions if the object
|
|
4560
|
+
* is already published, otherwise appears standalone.
|
|
4561
|
+
* @example
|
|
4562
|
+
* ```js
|
|
4563
|
+
* hiddenActions: [Action.Publish]
|
|
4564
|
+
* disabledActions: [Action.Publish]
|
|
4565
|
+
* ```
|
|
4566
|
+
* @version SDK: 1.45.0 | ThoughtSpot Cloud: 26.2.0.cl
|
|
4567
|
+
*/
|
|
4568
|
+
Action["Publish"] = "publish";
|
|
4569
|
+
/**
|
|
4570
|
+
* The **Manage Publishing** action for Liveboards, Answers and Models.
|
|
4571
|
+
* Opens the same publishing modal as the **Publish** action.
|
|
4572
|
+
* Appears as a child action to the **Publish** action if the
|
|
4573
|
+
* object is already published.
|
|
4574
|
+
* @example
|
|
4575
|
+
* ```js
|
|
4576
|
+
* hiddenActions: [Action.ManagePublishing]
|
|
4577
|
+
* disabledActions: [Action.ManagePublishing]
|
|
4578
|
+
* ```
|
|
4579
|
+
* @version SDK: 1.45.0 | ThoughtSpot Cloud: 26.2.0.cl
|
|
4580
|
+
*/
|
|
4581
|
+
Action["ManagePublishing"] = "managePublishing";
|
|
4582
|
+
/**
|
|
4583
|
+
* The **Unpublish** action for Liveboards, Answers and Models.
|
|
4584
|
+
* Opens the unpublishing modal. Appears as a child action to
|
|
4585
|
+
* the **Publish** action if the object is already published.
|
|
4586
|
+
* @example
|
|
4587
|
+
* ```js
|
|
4588
|
+
* hiddenActions: [Action.Unpublish]
|
|
4589
|
+
* disabledActions: [Action.Unpublish]
|
|
4590
|
+
* ```
|
|
4591
|
+
* @version SDK: 1.45.0 | ThoughtSpot Cloud: 26.2.0.cl
|
|
4592
|
+
*/
|
|
4593
|
+
Action["Unpublish"] = "unpublish";
|
|
4594
|
+
/**
|
|
4595
|
+
* The **Parameterize** action for Tables and Connections.
|
|
4596
|
+
* Opens the parameterization modal.
|
|
4597
|
+
* @example
|
|
4598
|
+
* ```js
|
|
4599
|
+
* hiddenActions: [Action.Parameterize]
|
|
4600
|
+
* disabledActions: [Action.Parameterize]
|
|
4601
|
+
* ```
|
|
4602
|
+
* @version SDK: 1.45.0 | ThoughtSpot Cloud: 26.2.0.cl
|
|
4603
|
+
*/
|
|
4604
|
+
Action["Parameterize"] = "parameterise";
|
|
4532
4605
|
/**
|
|
4533
4606
|
* The **Move to Group** menu action on a Liveboard.
|
|
4534
4607
|
* Allows moving a visualization to a different group.
|
|
@@ -4569,6 +4642,18 @@ var Action;
|
|
|
4569
4642
|
* @version SDK: 1.44.0 | ThoughtSpot Cloud: 26.2.0.cl
|
|
4570
4643
|
*/
|
|
4571
4644
|
Action["UngroupLiveboardGroup"] = "ungroupLiveboardGroup";
|
|
4645
|
+
/**
|
|
4646
|
+
* The **Include current period** checkbox for date filters.
|
|
4647
|
+
* Controls the visibility and availability of the option to include
|
|
4648
|
+
* the current time period in filter results.
|
|
4649
|
+
* @example
|
|
4650
|
+
* ```js
|
|
4651
|
+
* hiddenActions: [Action.IncludeCurrentPeriod]
|
|
4652
|
+
* disabledActions: [Action.IncludeCurrentPeriod]
|
|
4653
|
+
* ```
|
|
4654
|
+
* @version SDK: 1.45.0 | ThoughtSpot: 26.4.0.cl
|
|
4655
|
+
*/
|
|
4656
|
+
Action["IncludeCurrentPeriod"] = "includeCurrentPeriod";
|
|
4572
4657
|
})(Action || (Action = {}));
|
|
4573
4658
|
var PrefetchFeatures;
|
|
4574
4659
|
(function (PrefetchFeatures) {
|
|
@@ -4713,31 +4798,19 @@ var ErrorDetailsTypes;
|
|
|
4713
4798
|
ErrorDetailsTypes["NETWORK"] = "NETWORK";
|
|
4714
4799
|
})(ErrorDetailsTypes || (ErrorDetailsTypes = {}));
|
|
4715
4800
|
/**
|
|
4716
|
-
*
|
|
4717
|
-
*
|
|
4718
|
-
* These codes provide granular identification of errors that occur in embedded components.
|
|
4719
|
-
* They are returned in the {@link EmbedErrorDetailsEvent.code} property and allow for
|
|
4720
|
-
* precise error handling and debugging.
|
|
4801
|
+
* Error codes for identifying specific issues in embedded ThoughtSpot components.
|
|
4721
4802
|
*
|
|
4722
|
-
*
|
|
4723
|
-
*
|
|
4724
|
-
* - **Liveboard ID missing**: Errors related to missing liveboard ID
|
|
4725
|
-
* - **Conflicting actions configuration**: Errors related to conflicting actions configuration
|
|
4726
|
-
* - **Conflicting tabs configuration**: Errors related to conflicting tabs configuration
|
|
4727
|
-
* - **Initialization error**: Errors related to initialization error
|
|
4728
|
-
* - **Network error**: Errors related to network error
|
|
4729
|
-
* - **Custom action validation**: Errors related to custom action validation
|
|
4730
|
-
* - **Login failed**: Errors related to login failed
|
|
4731
|
-
* - **Render not called**: Errors related to render not called
|
|
4732
|
-
* - **Host event type undefined or invalid**: Errors related to host event type undefined or invalid
|
|
4803
|
+
* Use these codes for precise error handling and debugging. Each code maps to a
|
|
4804
|
+
* distinct failure scenario, enabling targeted recovery strategies.
|
|
4733
4805
|
*
|
|
4734
4806
|
* @version SDK: 1.44.2 | ThoughtSpot: 26.2.0.cl
|
|
4735
4807
|
* @group Error Handling
|
|
4808
|
+
*
|
|
4736
4809
|
* @see {@link EmbedErrorDetailsEvent} - The error event object that includes these codes
|
|
4737
4810
|
* @see {@link ErrorDetailsTypes} - General error type categories
|
|
4738
4811
|
*
|
|
4739
4812
|
* @example
|
|
4740
|
-
* Handle specific error codes
|
|
4813
|
+
* Handle specific error codes in the error event handler
|
|
4741
4814
|
*
|
|
4742
4815
|
* embed.on(EmbedEvent.Error, (error) => {
|
|
4743
4816
|
* if (error.code === EmbedErrorCodes.WORKSHEET_ID_NOT_FOUND) {
|
|
@@ -8279,7 +8352,6 @@ const addVizToLiveboard = `
|
|
|
8279
8352
|
const getSQLQuery = `
|
|
8280
8353
|
mutation GetSQLQuery($session: BachSessionIdInput!) {
|
|
8281
8354
|
Answer__getQuery(session: $session) {
|
|
8282
|
-
${bachSessionId}
|
|
8283
8355
|
sql
|
|
8284
8356
|
}
|
|
8285
8357
|
}
|
|
@@ -8607,7 +8679,7 @@ class AnswerService {
|
|
|
8607
8679
|
async getTML() {
|
|
8608
8680
|
const { object } = await this.executeQuery(getAnswerTML, {});
|
|
8609
8681
|
const edoc = object[0].edoc;
|
|
8610
|
-
const YAML = await import('./index-
|
|
8682
|
+
const YAML = await import('./index-Dk-SLdNk.js');
|
|
8611
8683
|
const parsedDoc = YAML.parse(edoc);
|
|
8612
8684
|
return {
|
|
8613
8685
|
answer: {
|
|
@@ -17531,7 +17603,7 @@ function processTrigger(iFrame, messageType, thoughtSpotHost, data) {
|
|
|
17531
17603
|
channel.port1.onmessage = ({ data: responseData }) => {
|
|
17532
17604
|
var _a;
|
|
17533
17605
|
channel.port1.close();
|
|
17534
|
-
const error = responseData.error || ((_a = responseData === null || responseData === void 0 ? void 0 : responseData.data) === null || _a === void 0 ? void 0 : _a.error);
|
|
17606
|
+
const error = (responseData === null || responseData === void 0 ? void 0 : responseData.error) || ((_a = responseData === null || responseData === void 0 ? void 0 : responseData.data) === null || _a === void 0 ? void 0 : _a.error);
|
|
17535
17607
|
if (error) {
|
|
17536
17608
|
rej(error);
|
|
17537
17609
|
}
|
|
@@ -18043,7 +18115,7 @@ function processEventData(type, eventData, thoughtSpotHost, containerEl) {
|
|
|
18043
18115
|
return eventData;
|
|
18044
18116
|
}
|
|
18045
18117
|
|
|
18046
|
-
var name="@thoughtspot/visual-embed-sdk";var version$1="1.
|
|
18118
|
+
var name="@thoughtspot/visual-embed-sdk";var version$1="1.45.0";var description="ThoughtSpot Embed SDK";var module="lib/src/index.js";var main="dist/tsembed.js";var types="lib/src/index.d.ts";var files=["dist/**","lib/**","src/**","cjs/**"];var exports={".":{"import":"./lib/src/index.js",require:"./cjs/src/index.js",types:"./lib/src/index.d.ts"},"./react":{"import":"./lib/src/react/all-types-export.js",require:"./cjs/src/react/all-types-export.js",types:"./lib/src/react/all-types-export.d.ts"},"./lib/src/react":{"import":"./lib/src/react/all-types-export.js",require:"./cjs/src/react/all-types-export.js",types:"./lib/src/react/all-types-export.d.ts"}};var typesVersions={"*":{react:["./lib/src/react/all-types-export.d.ts"]}};var scripts={lint:"eslint 'src/**'","lint:fix":"eslint 'src/**/*.*' --fix",tsc:"tsc -p tsconfig.build.json --incremental false; tsc -p tsconfig.build.json --incremental false --module commonjs --outDir cjs","build-and-publish":"npm run build:gatsby && npm run publish","bundle-dts-file":"dts-bundle-generator --config ./dts-config/dts-bundle-file.config.js","bundle-dts":"dts-bundle-generator --config ./dts-config/dts-bundle.config.js","bundle-dts-react":"dts-bundle-generator --config ./dts-config/dts-bundle-react.config.js","bundle-dts-react-full":"dts-bundle-generator --config ./dts-config/dts-bundle-react-full.config.js",build:"rollup -c",watch:"rollup -cw",docgen:"typedoc --tsconfig tsconfig.build.json --theme typedoc-theme --json static/typedoc/typedoc.json --disableOutputCheck","test-sdk":"jest -c jest.config.sdk.js --runInBand",test:"npm run test-sdk",posttest:"cat ./coverage/sdk/lcov.info | npx coveralls-next","is-publish-allowed":"node scripts/is-publish-allowed.js",prepublishOnly:"npm run is-publish-allowed && npm run test && npm run tsc && npm run bundle-dts-file && npm run bundle-dts && npm run bundle-dts-react && npm run bundle-dts-react-full && npm run build","check-size":"npm run build && size-limit","publish-dev":"npm publish --tag dev","publish-prod":"npm publish --tag latest",dev:"vite -c vite.local.config.ts"};var peerDependencies={react:"> 16.8.0","react-dom":"> 16.8.0"};var dependencies={classnames:"^2.3.1",eventemitter3:"^4.0.7",lodash:"^4.17.21","mixpanel-browser":"2.47.0","ts-deepmerge":"^6.0.2",tslib:"^2.5.3","use-deep-compare-effect":"^1.8.1",yaml:"^2.5.1"};var devDependencies={"@mdx-js/mdx":"^1.6.22","@mdx-js/react":"^1.6.22","@react-icons/all-files":"^4.1.0","@rollup/plugin-commonjs":"^18.0.0","@rollup/plugin-json":"^4.1.0","@rollup/plugin-node-resolve":"^11.2.1","@rollup/plugin-replace":"^5.0.2","@size-limit/preset-big-lib":"^11.2.0","@testing-library/dom":"^7.31.0","@testing-library/jest-dom":"^5.14.1","@testing-library/react":"^11.2.7","@testing-library/user-event":"^13.1.8","@types/jest":"^30.0.0","@types/lodash":"^4.17.0","@types/mixpanel-browser":"^2.35.6","@types/react-test-renderer":"^17.0.1","@typescript-eslint/eslint-plugin":"^8.28.0","@typescript-eslint/parser":"^8.28.0",ajv:"^8.17.1",asciidoctor:"^2.2.1","babel-jest":"^30.2.0","babel-preset-gatsby":"^1.10.0","command-line-args":"^5.1.1","coveralls-next":"^5.0.0",crypto:"^1.0.1","current-git-branch":"^1.1.0","dts-bundle-generator":"^9.5.1",eslint:"^9.23.0","eslint-config-airbnb-base":"^15.0.0","eslint-config-prettier":"^10.1.1","eslint-import-resolver-typescript":"^4.2.5","eslint-plugin-comment-length":"2.2.1","eslint-plugin-import":"^2.31.0","eslint-plugin-jsdoc":"^50.6.9","eslint-plugin-prettier":"^5.2.5","eslint-plugin-react":"^7.37.5","eslint-plugin-react-hooks":"^5.2.0","fs-extra":"^10.0.0","gh-pages":"6.3.0",globals:"^16.0.0","highlight.js":"^10.6.0","html-to-text":"^8.0.0","identity-obj-proxy":"^3.0.0","istanbul-merge":"^2.0.0",jest:"^30.2.0","jest-environment-jsdom":"^29.7.0","jest-fetch-mock":"^3.0.3",jsdom:"^17.0.0",prettier:"2.1.2",react:"^16.14.0","react-dom":"^16.14.0","react-resizable":"^1.11.0","react-resize-detector":"^6.6.0","react-test-renderer":"^17.0.2","react-use-flexsearch":"^0.1.1",rollup:"4.24.0","rollup-plugin-typescript2":"0.27.3","ts-jest":"^29.4.6","ts-loader":"8.0.4",typedoc:"0.21.6","typedoc-plugin-toc-group":"thoughtspot/typedoc-plugin-toc-group",typescript:"^4.9.4","typescript-eslint":"^8.29.1","url-search-params-polyfill":"^8.1.0",util:"^0.12.4",vite:"^6.3.5"};var author="ThoughtSpot";var email="support@thoughtspot.com";var license="ThoughtSpot Development Tools End User License Agreement";var directories={lib:"lib"};var repository={type:"git",url:"git+https://github.com/thoughtspot/visual-embed-sdk.git"};var publishConfig={registry:"https://registry.npmjs.org"};var keywords=["thoughtspot","everywhere","embedded","embed","sdk","analytics"];var bugs={url:"https://github.com/thoughtspot/visual-embed-sdk/issues"};var homepage="https://github.com/thoughtspot/visual-embed-sdk#readme";var globals={window:{}};var pkgInfo = {name:name,version:version$1,description:description,module:module,main:main,types:types,files:files,exports:exports,typesVersions:typesVersions,"size-limit":[{path:"dist/tsembed.es.js",limit:"32 kB"}],scripts:scripts,peerDependencies:peerDependencies,dependencies:dependencies,devDependencies:devDependencies,author:author,email:email,license:license,directories:directories,repository:repository,publishConfig:publishConfig,keywords:keywords,bugs:bugs,homepage:homepage,globals:globals};
|
|
18047
18119
|
|
|
18048
18120
|
class HostEventClient {
|
|
18049
18121
|
constructor(iFrame) {
|
|
@@ -18535,8 +18607,8 @@ class TsEmbed {
|
|
|
18535
18607
|
this.eventHandlerMap = new Map();
|
|
18536
18608
|
this.isError = false;
|
|
18537
18609
|
this.viewConfig = {
|
|
18538
|
-
excludeRuntimeFiltersfromURL:
|
|
18539
|
-
excludeRuntimeParametersfromURL:
|
|
18610
|
+
excludeRuntimeFiltersfromURL: true,
|
|
18611
|
+
excludeRuntimeParametersfromURL: true,
|
|
18540
18612
|
...viewConfig,
|
|
18541
18613
|
};
|
|
18542
18614
|
this.registerAppInit();
|
|
@@ -19728,7 +19800,11 @@ class V1Embed extends TsEmbed {
|
|
|
19728
19800
|
* @hidden
|
|
19729
19801
|
*/
|
|
19730
19802
|
this.test__executeCallbacks = this.executeCallbacks;
|
|
19731
|
-
this.viewConfig = {
|
|
19803
|
+
this.viewConfig = {
|
|
19804
|
+
excludeRuntimeFiltersfromURL: true,
|
|
19805
|
+
excludeRuntimeParametersfromURL: true,
|
|
19806
|
+
...viewConfig,
|
|
19807
|
+
};
|
|
19732
19808
|
}
|
|
19733
19809
|
/**
|
|
19734
19810
|
* Render the app in an iframe and set up event handlers
|
|
@@ -19964,7 +20040,7 @@ class AppEmbed extends V1Embed {
|
|
|
19964
20040
|
* embedded Liveboard or visualization.
|
|
19965
20041
|
*/
|
|
19966
20042
|
getEmbedParams() {
|
|
19967
|
-
const { tag, hideTagFilterChips, hideObjects, liveboardV2, showPrimaryNavbar, disableProfileAndHelp, hideHamburger, hideObjectSearch, hideNotification, hideApplicationSwitcher, hideOrgSwitcher, enableSearchAssist, fullHeight, dataPanelV2 = true, hideLiveboardHeader = false, showLiveboardTitle = true, showLiveboardDescription = true, showMaskedFilterChip = false, isLiveboardMasterpiecesEnabled = false, hideHomepageLeftNav = false, modularHomeExperience = false, isLiveboardHeaderSticky = true, enableAskSage, collapseSearchBarInitially = false, enable2ColumnLayout, enableCustomColumnGroups = false, dataPanelCustomGroupsAccordionInitialState = DataPanelCustomColumnGroupsAccordionState$1.EXPAND_ALL, collapseSearchBar = true, isLiveboardCompactHeaderEnabled = false, showLiveboardVerifiedBadge = true, showLiveboardReverifyBanner = true, hideIrrelevantChipsInLiveboardTabs = false, isEnhancedFilterInteractivityEnabled = false, homePageSearchBarMode, isUnifiedSearchExperienceEnabled = true, enablePendoHelp = true, discoveryExperience, coverAndFilterOptionInPDF = false,
|
|
20043
|
+
const { tag, hideTagFilterChips, hideObjects, liveboardV2, showPrimaryNavbar, disableProfileAndHelp, hideHamburger, hideObjectSearch, hideNotification, hideApplicationSwitcher, hideOrgSwitcher, enableSearchAssist, fullHeight, dataPanelV2 = true, hideLiveboardHeader = false, showLiveboardTitle = true, showLiveboardDescription = true, showMaskedFilterChip = false, isLiveboardMasterpiecesEnabled = false, hideHomepageLeftNav = false, modularHomeExperience = false, isLiveboardHeaderSticky = true, enableAskSage, collapseSearchBarInitially = false, enable2ColumnLayout, enableCustomColumnGroups = false, dataPanelCustomGroupsAccordionInitialState = DataPanelCustomColumnGroupsAccordionState$1.EXPAND_ALL, collapseSearchBar = true, isLiveboardCompactHeaderEnabled = false, showLiveboardVerifiedBadge = true, showLiveboardReverifyBanner = true, hideIrrelevantChipsInLiveboardTabs = false, isEnhancedFilterInteractivityEnabled = false, homePageSearchBarMode, isUnifiedSearchExperienceEnabled = true, enablePendoHelp = true, discoveryExperience, coverAndFilterOptionInPDF = false, isLiveboardStylingAndGroupingEnabled, isPNGInScheduledEmailsEnabled = false, isLiveboardXLSXCSVDownloadEnabled = false, isGranularXLSXCSVSchedulesEnabled = false, isCentralizedLiveboardFilterUXEnabled = false, isLinkParametersEnabled, updatedSpotterChatPrompt, minimumHeight, isThisPeriodInDateFiltersEnabled, } = this.viewConfig;
|
|
19968
20044
|
let params = {};
|
|
19969
20045
|
params[Param.PrimaryNavHidden] = !showPrimaryNavbar;
|
|
19970
20046
|
params[Param.HideProfleAndHelp] = !!disableProfileAndHelp;
|
|
@@ -20033,12 +20109,15 @@ class AppEmbed extends V1Embed {
|
|
|
20033
20109
|
if (isLiveboardStylingAndGroupingEnabled !== undefined) {
|
|
20034
20110
|
params[Param.IsLiveboardStylingAndGroupingEnabled] = isLiveboardStylingAndGroupingEnabled;
|
|
20035
20111
|
}
|
|
20036
|
-
if (liveboardXLSXCSVDownload !== undefined) {
|
|
20037
|
-
params[Param.LiveboardXLSXCSVDownload] = !!liveboardXLSXCSVDownload;
|
|
20038
|
-
}
|
|
20039
20112
|
if (isPNGInScheduledEmailsEnabled !== undefined) {
|
|
20040
20113
|
params[Param.isPNGInScheduledEmailsEnabled] = isPNGInScheduledEmailsEnabled;
|
|
20041
20114
|
}
|
|
20115
|
+
if (isLiveboardXLSXCSVDownloadEnabled !== undefined) {
|
|
20116
|
+
params[Param.isLiveboardXLSXCSVDownloadEnabled] = isLiveboardXLSXCSVDownloadEnabled;
|
|
20117
|
+
}
|
|
20118
|
+
if (isGranularXLSXCSVSchedulesEnabled !== undefined) {
|
|
20119
|
+
params[Param.isGranularXLSXCSVSchedulesEnabled] = isGranularXLSXCSVSchedulesEnabled;
|
|
20120
|
+
}
|
|
20042
20121
|
if (hideTagFilterChips !== undefined) {
|
|
20043
20122
|
params[Param.HideTagFilterChips] = hideTagFilterChips;
|
|
20044
20123
|
}
|
|
@@ -20048,6 +20127,9 @@ class AppEmbed extends V1Embed {
|
|
|
20048
20127
|
if (isCentralizedLiveboardFilterUXEnabled != undefined) {
|
|
20049
20128
|
params[Param.isCentralizedLiveboardFilterUXEnabled] = isCentralizedLiveboardFilterUXEnabled;
|
|
20050
20129
|
}
|
|
20130
|
+
if (isThisPeriodInDateFiltersEnabled !== undefined) {
|
|
20131
|
+
params[Param.IsThisPeriodInDateFiltersEnabled] = isThisPeriodInDateFiltersEnabled;
|
|
20132
|
+
}
|
|
20051
20133
|
this.defaultHeight = minimumHeight || this.defaultHeight;
|
|
20052
20134
|
params[Param.DataPanelV2Enabled] = dataPanelV2;
|
|
20053
20135
|
params[Param.HideHomepageLeftNav] = hideHomepageLeftNav;
|
|
@@ -20403,7 +20485,7 @@ class LiveboardEmbed extends V1Embed {
|
|
|
20403
20485
|
getEmbedParamsObject() {
|
|
20404
20486
|
let params = {};
|
|
20405
20487
|
params = this.getBaseQueryParams(params);
|
|
20406
|
-
const { enableVizTransformations, fullHeight, defaultHeight, minimumHeight, visibleVizs, liveboardV2, vizId, hideTabPanel, activeTabId, hideLiveboardHeader, showLiveboardDescription, showLiveboardTitle, isLiveboardHeaderSticky = true, isLiveboardCompactHeaderEnabled = false, showLiveboardVerifiedBadge = true, showLiveboardReverifyBanner = true, hideIrrelevantChipsInLiveboardTabs = false, showMaskedFilterChip = false, isLiveboardMasterpiecesEnabled = false, isEnhancedFilterInteractivityEnabled = false, enableAskSage, enable2ColumnLayout, dataPanelV2 = true, enableCustomColumnGroups = false, oAuthPollingInterval, isForceRedirect, dataSourceId, coverAndFilterOptionInPDF = false,
|
|
20488
|
+
const { enableVizTransformations, fullHeight, defaultHeight, minimumHeight, visibleVizs, liveboardV2, vizId, hideTabPanel, activeTabId, hideLiveboardHeader, showLiveboardDescription, showLiveboardTitle, isLiveboardHeaderSticky = true, isLiveboardCompactHeaderEnabled = false, showLiveboardVerifiedBadge = true, showLiveboardReverifyBanner = true, hideIrrelevantChipsInLiveboardTabs = false, showMaskedFilterChip = false, isLiveboardMasterpiecesEnabled = false, isEnhancedFilterInteractivityEnabled = false, enableAskSage, enable2ColumnLayout, dataPanelV2 = true, enableCustomColumnGroups = false, oAuthPollingInterval, isForceRedirect, dataSourceId, coverAndFilterOptionInPDF = false, isLiveboardStylingAndGroupingEnabled, isPNGInScheduledEmailsEnabled = false, isLiveboardXLSXCSVDownloadEnabled = false, isGranularXLSXCSVSchedulesEnabled = false, showSpotterLimitations, isCentralizedLiveboardFilterUXEnabled = false, isLinkParametersEnabled, updatedSpotterChatPrompt, isThisPeriodInDateFiltersEnabled, } = this.viewConfig;
|
|
20407
20489
|
const preventLiveboardFilterRemoval = this.viewConfig.preventLiveboardFilterRemoval
|
|
20408
20490
|
|| this.viewConfig.preventPinboardFilterRemoval;
|
|
20409
20491
|
if (fullHeight === true) {
|
|
@@ -20468,6 +20550,12 @@ class LiveboardEmbed extends V1Embed {
|
|
|
20468
20550
|
if (isPNGInScheduledEmailsEnabled !== undefined) {
|
|
20469
20551
|
params[Param.isPNGInScheduledEmailsEnabled] = isPNGInScheduledEmailsEnabled;
|
|
20470
20552
|
}
|
|
20553
|
+
if (isLiveboardXLSXCSVDownloadEnabled !== undefined) {
|
|
20554
|
+
params[Param.isLiveboardXLSXCSVDownloadEnabled] = isLiveboardXLSXCSVDownloadEnabled;
|
|
20555
|
+
}
|
|
20556
|
+
if (isGranularXLSXCSVSchedulesEnabled !== undefined) {
|
|
20557
|
+
params[Param.isGranularXLSXCSVSchedulesEnabled] = isGranularXLSXCSVSchedulesEnabled;
|
|
20558
|
+
}
|
|
20471
20559
|
if (showSpotterLimitations !== undefined) {
|
|
20472
20560
|
params[Param.ShowSpotterLimitations] = showSpotterLimitations;
|
|
20473
20561
|
}
|
|
@@ -20477,6 +20565,9 @@ class LiveboardEmbed extends V1Embed {
|
|
|
20477
20565
|
if (isCentralizedLiveboardFilterUXEnabled !== undefined) {
|
|
20478
20566
|
params[Param.isCentralizedLiveboardFilterUXEnabled] = isCentralizedLiveboardFilterUXEnabled;
|
|
20479
20567
|
}
|
|
20568
|
+
if (isThisPeriodInDateFiltersEnabled !== undefined) {
|
|
20569
|
+
params[Param.IsThisPeriodInDateFiltersEnabled] = isThisPeriodInDateFiltersEnabled;
|
|
20570
|
+
}
|
|
20480
20571
|
params[Param.LiveboardHeaderSticky] = isLiveboardHeaderSticky;
|
|
20481
20572
|
params[Param.LiveboardHeaderV2] = isLiveboardCompactHeaderEnabled;
|
|
20482
20573
|
params[Param.ShowLiveboardVerifiedBadge] = showLiveboardVerifiedBadge;
|
|
@@ -20488,9 +20579,6 @@ class LiveboardEmbed extends V1Embed {
|
|
|
20488
20579
|
params[Param.DataPanelV2Enabled] = dataPanelV2;
|
|
20489
20580
|
params[Param.EnableCustomColumnGroups] = enableCustomColumnGroups;
|
|
20490
20581
|
params[Param.CoverAndFilterOptionInPDF] = coverAndFilterOptionInPDF;
|
|
20491
|
-
if (liveboardXLSXCSVDownload !== undefined) {
|
|
20492
|
-
params[Param.LiveboardXLSXCSVDownload] = !!liveboardXLSXCSVDownload;
|
|
20493
|
-
}
|
|
20494
20582
|
getQueryParamString(params, true);
|
|
20495
20583
|
return params;
|
|
20496
20584
|
}
|
|
@@ -20707,7 +20795,12 @@ const HiddenActionItemByDefaultForSearchEmbed = [
|
|
|
20707
20795
|
*/
|
|
20708
20796
|
class SearchEmbed extends TsEmbed {
|
|
20709
20797
|
constructor(domSelector, viewConfig) {
|
|
20710
|
-
viewConfig
|
|
20798
|
+
viewConfig = {
|
|
20799
|
+
embedComponentType: 'SearchEmbed',
|
|
20800
|
+
excludeRuntimeFiltersfromURL: true,
|
|
20801
|
+
excludeRuntimeParametersfromURL: true,
|
|
20802
|
+
...viewConfig,
|
|
20803
|
+
};
|
|
20711
20804
|
super(domSelector, viewConfig);
|
|
20712
20805
|
}
|
|
20713
20806
|
/**
|
|
@@ -20741,7 +20834,7 @@ class SearchEmbed extends TsEmbed {
|
|
|
20741
20834
|
}
|
|
20742
20835
|
getEmbedParamsObject() {
|
|
20743
20836
|
var _a;
|
|
20744
|
-
const { hideResults, enableSearchAssist, forceTable, searchOptions, runtimeFilters, dataSource, dataSources, excludeRuntimeFiltersfromURL, hideSearchBar, dataPanelV2 = true, useLastSelectedSources = false, runtimeParameters, collapseSearchBarInitially = false, enableCustomColumnGroups = false, dataPanelCustomGroupsAccordionInitialState = DataPanelCustomColumnGroupsAccordionState.EXPAND_ALL, focusSearchBarOnRender = true, excludeRuntimeParametersfromURL, excludeSearchTokenStringFromURL, collapseSearchBar = true, } = this.viewConfig;
|
|
20837
|
+
const { hideResults, enableSearchAssist, forceTable, searchOptions, runtimeFilters, dataSource, dataSources, excludeRuntimeFiltersfromURL, hideSearchBar, dataPanelV2 = true, useLastSelectedSources = false, runtimeParameters, collapseSearchBarInitially = false, enableCustomColumnGroups = false, dataPanelCustomGroupsAccordionInitialState = DataPanelCustomColumnGroupsAccordionState.EXPAND_ALL, focusSearchBarOnRender = true, excludeRuntimeParametersfromURL, excludeSearchTokenStringFromURL, collapseSearchBar = true, isThisPeriodInDateFiltersEnabled, } = this.viewConfig;
|
|
20745
20838
|
const queryParams = this.getBaseQueryParams();
|
|
20746
20839
|
queryParams[Param.HideActions] = [
|
|
20747
20840
|
...((_a = queryParams[Param.HideActions]) !== null && _a !== void 0 ? _a : []),
|
|
@@ -20776,6 +20869,9 @@ class SearchEmbed extends TsEmbed {
|
|
|
20776
20869
|
if (!focusSearchBarOnRender) {
|
|
20777
20870
|
queryParams[Param.FocusSearchBarOnRender] = focusSearchBarOnRender;
|
|
20778
20871
|
}
|
|
20872
|
+
if (isThisPeriodInDateFiltersEnabled !== undefined) {
|
|
20873
|
+
queryParams[Param.IsThisPeriodInDateFiltersEnabled] = isThisPeriodInDateFiltersEnabled;
|
|
20874
|
+
}
|
|
20779
20875
|
queryParams[Param.DataPanelV2Enabled] = dataPanelV2;
|
|
20780
20876
|
queryParams[Param.DataSourceMode] = this.getDataSourceMode();
|
|
20781
20877
|
queryParams[Param.UseLastSelectedDataSource] = useLastSelectedSources;
|
|
@@ -21477,7 +21573,12 @@ var isUndefined_1 = isUndefined;
|
|
|
21477
21573
|
*/
|
|
21478
21574
|
class SpotterEmbed extends TsEmbed {
|
|
21479
21575
|
constructor(container, viewConfig) {
|
|
21480
|
-
viewConfig
|
|
21576
|
+
viewConfig = {
|
|
21577
|
+
embedComponentType: 'conversation',
|
|
21578
|
+
excludeRuntimeFiltersfromURL: true,
|
|
21579
|
+
excludeRuntimeParametersfromURL: true,
|
|
21580
|
+
...viewConfig,
|
|
21581
|
+
};
|
|
21481
21582
|
super(container, viewConfig);
|
|
21482
21583
|
this.viewConfig = viewConfig;
|
|
21483
21584
|
}
|
|
@@ -21565,7 +21666,12 @@ class SpotterEmbed extends TsEmbed {
|
|
|
21565
21666
|
*/
|
|
21566
21667
|
class ConversationEmbed extends SpotterEmbed {
|
|
21567
21668
|
constructor(container, viewConfig) {
|
|
21568
|
-
viewConfig
|
|
21669
|
+
viewConfig = {
|
|
21670
|
+
embedComponentType: 'conversation',
|
|
21671
|
+
excludeRuntimeFiltersfromURL: true,
|
|
21672
|
+
excludeRuntimeParametersfromURL: true,
|
|
21673
|
+
...viewConfig,
|
|
21674
|
+
};
|
|
21569
21675
|
super(container, viewConfig);
|
|
21570
21676
|
this.viewConfig = viewConfig;
|
|
21571
21677
|
}
|