@thoughtspot/visual-embed-sdk 1.32.4-dc.15 → 1.32.4-dc.17
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/auth.d.ts +1 -0
- package/cjs/src/auth.d.ts.map +1 -1
- package/cjs/src/auth.js +1 -0
- package/cjs/src/auth.js.map +1 -1
- package/cjs/src/embed/liveboard.d.ts +9 -0
- package/cjs/src/embed/liveboard.d.ts.map +1 -1
- package/cjs/src/embed/liveboard.js +16 -0
- package/cjs/src/embed/liveboard.js.map +1 -1
- package/cjs/src/tokenizedFetch.d.ts +1 -0
- package/cjs/src/tokenizedFetch.d.ts.map +1 -1
- package/cjs/src/tokenizedFetch.js +1 -0
- package/cjs/src/tokenizedFetch.js.map +1 -1
- package/cjs/src/types.d.ts +25 -3
- package/cjs/src/types.d.ts.map +1 -1
- package/cjs/src/types.js +25 -3
- package/cjs/src/types.js.map +1 -1
- package/cjs/src/utils/authService/tokenizedAuthService.d.ts +2 -0
- package/cjs/src/utils/authService/tokenizedAuthService.d.ts.map +1 -1
- package/cjs/src/utils/authService/tokenizedAuthService.js +2 -0
- package/cjs/src/utils/authService/tokenizedAuthService.js.map +1 -1
- package/cjs/src/utils/graphql/answerService/answerService.d.ts +1 -0
- package/cjs/src/utils/graphql/answerService/answerService.d.ts.map +1 -1
- package/cjs/src/utils/graphql/answerService/answerService.js +2 -0
- package/cjs/src/utils/graphql/answerService/answerService.js.map +1 -1
- package/cjs/src/utils/graphql/spotterService/nls-answer-service.d.ts +4 -1
- package/cjs/src/utils/graphql/spotterService/nls-answer-service.d.ts.map +1 -1
- package/cjs/src/utils/graphql/spotterService/nls-answer-service.js +4 -1
- package/cjs/src/utils/graphql/spotterService/nls-answer-service.js.map +1 -1
- package/cjs/src/utils/processData.d.ts.map +1 -1
- package/cjs/src/utils/processData.js +1 -0
- package/cjs/src/utils/processData.js.map +1 -1
- package/cjs/src/utils/sessionInfoService.d.ts +4 -0
- package/cjs/src/utils/sessionInfoService.d.ts.map +1 -1
- package/cjs/src/utils/sessionInfoService.js +4 -0
- package/cjs/src/utils/sessionInfoService.js.map +1 -1
- package/dist/src/auth.d.ts +1 -0
- package/dist/src/auth.d.ts.map +1 -1
- package/dist/src/embed/liveboard.d.ts +9 -0
- package/dist/src/embed/liveboard.d.ts.map +1 -1
- package/dist/src/tokenizedFetch.d.ts +1 -0
- package/dist/src/tokenizedFetch.d.ts.map +1 -1
- package/dist/src/types.d.ts +25 -3
- package/dist/src/types.d.ts.map +1 -1
- package/dist/src/utils/authService/tokenizedAuthService.d.ts +2 -0
- package/dist/src/utils/authService/tokenizedAuthService.d.ts.map +1 -1
- package/dist/src/utils/graphql/answerService/answerService.d.ts +1 -0
- package/dist/src/utils/graphql/answerService/answerService.d.ts.map +1 -1
- package/dist/src/utils/graphql/spotterService/nls-answer-service.d.ts +4 -1
- package/dist/src/utils/graphql/spotterService/nls-answer-service.d.ts.map +1 -1
- package/dist/src/utils/processData.d.ts.map +1 -1
- package/dist/src/utils/sessionInfoService.d.ts +4 -0
- package/dist/src/utils/sessionInfoService.d.ts.map +1 -1
- package/dist/tsembed-react.es.js +51 -4
- package/dist/tsembed-react.js +51 -4
- package/dist/tsembed.es.js +55 -5
- package/dist/tsembed.js +55 -5
- package/dist/visual-embed-sdk-react-full.d.ts +45 -4
- package/dist/visual-embed-sdk-react.d.ts +45 -4
- package/dist/visual-embed-sdk.d.ts +45 -4
- package/lib/package.json +1 -1
- package/lib/src/auth.d.ts +1 -0
- package/lib/src/auth.d.ts.map +1 -1
- package/lib/src/auth.js +1 -0
- package/lib/src/auth.js.map +1 -1
- package/lib/src/embed/liveboard.d.ts +9 -0
- package/lib/src/embed/liveboard.d.ts.map +1 -1
- package/lib/src/embed/liveboard.js +16 -0
- package/lib/src/embed/liveboard.js.map +1 -1
- package/lib/src/tokenizedFetch.d.ts +1 -0
- package/lib/src/tokenizedFetch.d.ts.map +1 -1
- package/lib/src/tokenizedFetch.js +1 -0
- package/lib/src/tokenizedFetch.js.map +1 -1
- package/lib/src/types.d.ts +25 -3
- package/lib/src/types.d.ts.map +1 -1
- package/lib/src/types.js +25 -3
- package/lib/src/types.js.map +1 -1
- package/lib/src/utils/authService/tokenizedAuthService.d.ts +2 -0
- package/lib/src/utils/authService/tokenizedAuthService.d.ts.map +1 -1
- package/lib/src/utils/authService/tokenizedAuthService.js +2 -0
- package/lib/src/utils/authService/tokenizedAuthService.js.map +1 -1
- package/lib/src/utils/graphql/answerService/answerService.d.ts +1 -0
- package/lib/src/utils/graphql/answerService/answerService.d.ts.map +1 -1
- package/lib/src/utils/graphql/answerService/answerService.js +2 -0
- package/lib/src/utils/graphql/answerService/answerService.js.map +1 -1
- package/lib/src/utils/graphql/spotterService/nls-answer-service.d.ts +4 -1
- package/lib/src/utils/graphql/spotterService/nls-answer-service.d.ts.map +1 -1
- package/lib/src/utils/graphql/spotterService/nls-answer-service.js +4 -1
- package/lib/src/utils/graphql/spotterService/nls-answer-service.js.map +1 -1
- package/lib/src/utils/processData.d.ts.map +1 -1
- package/lib/src/utils/processData.js +1 -0
- package/lib/src/utils/processData.js.map +1 -1
- package/lib/src/utils/sessionInfoService.d.ts +4 -0
- package/lib/src/utils/sessionInfoService.d.ts.map +1 -1
- package/lib/src/utils/sessionInfoService.js +4 -0
- package/lib/src/utils/sessionInfoService.js.map +1 -1
- package/lib/src/visual-embed-sdk.d.ts +45 -4
- package/package.json +1 -1
- package/src/auth.ts +1 -0
- package/src/embed/liveboard.ts +21 -0
- package/src/tokenizedFetch.ts +1 -0
- package/src/types.ts +25 -3
- package/src/utils/authService/tokenizedAuthService.ts +2 -0
- package/src/utils/graphql/answerService/answerService.ts +4 -0
- package/src/utils/graphql/spotterService/nls-answer-service.ts +9 -6
- package/src/utils/processData.ts +1 -0
- package/src/utils/sessionInfoService.ts +4 -0
package/dist/tsembed.js
CHANGED
|
@@ -1774,23 +1774,28 @@
|
|
|
1774
1774
|
/**
|
|
1775
1775
|
* Trigger the **Make a copy** action on a Liveboard,
|
|
1776
1776
|
* visualization, or Answer page.
|
|
1777
|
+
*
|
|
1777
1778
|
* @example
|
|
1778
1779
|
* ```js
|
|
1779
1780
|
* liveboardEmbed.trigger(HostEvent.MakeACopy)
|
|
1780
1781
|
* ```
|
|
1782
|
+
*
|
|
1781
1783
|
* @example
|
|
1782
1784
|
* ```js
|
|
1783
1785
|
* liveboardEmbed.trigger(HostEvent.MakeACopy, {
|
|
1784
1786
|
* vizId: '730496d6-6903-4601-937e-2c691821af3c'})
|
|
1785
1787
|
* ```
|
|
1788
|
+
*
|
|
1786
1789
|
* @example
|
|
1787
1790
|
* ```js
|
|
1788
1791
|
* vizEmbed.trigger(HostEvent.MakeACopy)
|
|
1789
1792
|
* ```
|
|
1793
|
+
*
|
|
1790
1794
|
* @example
|
|
1791
1795
|
* ```js
|
|
1792
1796
|
* searchEmbed.trigger(HostEvent.MakeACopy)
|
|
1793
1797
|
* ```
|
|
1798
|
+
*
|
|
1794
1799
|
* @version SDK: 1.15.0 | ThoughtSpot: 8.7.0.cl, 8.8.1.sw
|
|
1795
1800
|
*/
|
|
1796
1801
|
HostEvent["MakeACopy"] = "makeACopy";
|
|
@@ -1816,6 +1821,7 @@
|
|
|
1816
1821
|
/**
|
|
1817
1822
|
* Trigger the **Create alert** action on a KPI chart
|
|
1818
1823
|
* in a Liveboard or saved Answer.
|
|
1824
|
+
*
|
|
1819
1825
|
* @param - an object with `vizId` as a key
|
|
1820
1826
|
* @example
|
|
1821
1827
|
* ```js
|
|
@@ -1823,6 +1829,7 @@
|
|
|
1823
1829
|
* vizId: '730496d6-6903-4601-937e-2c691821af3c'
|
|
1824
1830
|
* })
|
|
1825
1831
|
* ```
|
|
1832
|
+
*
|
|
1826
1833
|
* @example
|
|
1827
1834
|
* ```js
|
|
1828
1835
|
* searchEmbed.trigger(HostEvent.CreateMonitor)
|
|
@@ -1833,6 +1840,7 @@
|
|
|
1833
1840
|
/**
|
|
1834
1841
|
* Trigger the **Manage alerts** action on a KPI chart
|
|
1835
1842
|
* in a visualization or saved Answer.
|
|
1843
|
+
*
|
|
1836
1844
|
* @param - an object with `vizId` as a key
|
|
1837
1845
|
* @example
|
|
1838
1846
|
* ```js
|
|
@@ -1840,10 +1848,12 @@
|
|
|
1840
1848
|
* vizId: '730496d6-6903-4601-937e-2c691821af3c'
|
|
1841
1849
|
* })
|
|
1842
1850
|
* ```
|
|
1851
|
+
*
|
|
1843
1852
|
* @example
|
|
1844
1853
|
* ```js
|
|
1845
1854
|
* searchEmbed.trigger(HostEvent.ManageMonitor)
|
|
1846
1855
|
* ```
|
|
1856
|
+
*
|
|
1847
1857
|
* @example
|
|
1848
1858
|
* ```js
|
|
1849
1859
|
* vizEmbed.trigger(HostEvent.ManageMonitor)
|
|
@@ -2241,6 +2251,7 @@
|
|
|
2241
2251
|
/**
|
|
2242
2252
|
* Get the answer session for a Search or
|
|
2243
2253
|
* Liveboard visualization.
|
|
2254
|
+
*
|
|
2244
2255
|
* @example
|
|
2245
2256
|
* ```js
|
|
2246
2257
|
* const {session} = await embed.trigger(
|
|
@@ -2248,10 +2259,12 @@
|
|
|
2248
2259
|
* vizId: '123', // For Liveboard Visualization.
|
|
2249
2260
|
* })
|
|
2250
2261
|
* ```
|
|
2262
|
+
*
|
|
2251
2263
|
* @example
|
|
2252
2264
|
* ```js
|
|
2253
2265
|
* const {session} = await embed.trigger( HostEvent.GetAnswerSession )
|
|
2254
2266
|
* ```
|
|
2267
|
+
*
|
|
2255
2268
|
* @version SDK: 1.26.0 | Thoughtspot: 9.10.0.cl
|
|
2256
2269
|
*/
|
|
2257
2270
|
HostEvent["GetAnswerSession"] = "getAnswerSession";
|
|
@@ -2943,6 +2956,7 @@
|
|
|
2943
2956
|
/**
|
|
2944
2957
|
* @deprecated
|
|
2945
2958
|
* Reports errors
|
|
2959
|
+
*
|
|
2946
2960
|
* @example
|
|
2947
2961
|
* ```js
|
|
2948
2962
|
* disabledActions: [Action.ReportError]
|
|
@@ -3172,12 +3186,14 @@
|
|
|
3172
3186
|
* ```js
|
|
3173
3187
|
* disabledActions: [Action.RequestVerification]
|
|
3174
3188
|
* ```
|
|
3189
|
+
*
|
|
3175
3190
|
* @version SDK: 1.25.0 | Thoughtspot: 9.6.0.cl
|
|
3176
3191
|
*/
|
|
3177
3192
|
Action["RequestVerification"] = "requestVerification";
|
|
3178
3193
|
/**
|
|
3179
3194
|
*
|
|
3180
|
-
*Allows users to mark a Liveboard as verified.
|
|
3195
|
+
* Allows users to mark a Liveboard as verified.
|
|
3196
|
+
*
|
|
3181
3197
|
* @example
|
|
3182
3198
|
* ```js
|
|
3183
3199
|
* disabledActions: [Action.MarkAsVerified]
|
|
@@ -3188,6 +3204,7 @@
|
|
|
3188
3204
|
/**
|
|
3189
3205
|
* The **Add Tab** action on a Liveboard.
|
|
3190
3206
|
* Allows adding a new tab to a Liveboard view.
|
|
3207
|
+
*
|
|
3191
3208
|
* @example
|
|
3192
3209
|
* ```js
|
|
3193
3210
|
* disabledActions: [Action.AddTab]
|
|
@@ -3197,7 +3214,8 @@
|
|
|
3197
3214
|
Action["AddTab"] = "addTab";
|
|
3198
3215
|
/**
|
|
3199
3216
|
*
|
|
3200
|
-
*Initiates contextual change analysis on KPI charts.
|
|
3217
|
+
* Initiates contextual change analysis on KPI charts.
|
|
3218
|
+
*
|
|
3201
3219
|
* @example
|
|
3202
3220
|
* ```js
|
|
3203
3221
|
* disabledActions: [Action.EnableContextualChangeAnalysis]
|
|
@@ -3211,6 +3229,7 @@
|
|
|
3211
3229
|
* ```js
|
|
3212
3230
|
* disabledActions: [Action.ShowSageQuery]
|
|
3213
3231
|
* ```
|
|
3232
|
+
*
|
|
3214
3233
|
* @version SDK: 1.26.0 | Thoughtspot: 9.7.0.cl
|
|
3215
3234
|
*/
|
|
3216
3235
|
Action["ShowSageQuery"] = "showSageQuery";
|
|
@@ -3225,7 +3244,8 @@
|
|
|
3225
3244
|
Action["EditSageAnswer"] = "editSageAnswer";
|
|
3226
3245
|
/**
|
|
3227
3246
|
*
|
|
3228
|
-
*This action allows users to send feedback on AI-generated Answers.
|
|
3247
|
+
* This action allows users to send feedback on AI-generated Answers.
|
|
3248
|
+
*
|
|
3229
3249
|
* @example
|
|
3230
3250
|
* ```js
|
|
3231
3251
|
* disabledActions: [Action.SageAnswerFeedback]
|
|
@@ -3302,6 +3322,7 @@
|
|
|
3302
3322
|
* hiddenAction: [Action.CreateLiveboard]
|
|
3303
3323
|
* disabledActions: [Action.CreateLiveboard]
|
|
3304
3324
|
* ```
|
|
3325
|
+
*
|
|
3305
3326
|
* @version SDK: 1.32.0 | Thoughtspot: 10.1.0.cl
|
|
3306
3327
|
*/
|
|
3307
3328
|
Action["CreateLiveboard"] = "createLiveboard";
|
|
@@ -3397,6 +3418,7 @@
|
|
|
3397
3418
|
Action["UnsubscribeScheduleHomepage"] = "unsubscribeScheduleHomepage";
|
|
3398
3419
|
/**
|
|
3399
3420
|
* The **Manage Tags** action on Homepage Favourite Module.
|
|
3421
|
+
*
|
|
3400
3422
|
* @example
|
|
3401
3423
|
* ```js
|
|
3402
3424
|
* disabledActions: [Action.ManageTags]
|
|
@@ -6016,6 +6038,7 @@
|
|
|
6016
6038
|
* Fetch wrapper that adds the authentication token to the request.
|
|
6017
6039
|
* Use this to call the ThoughtSpot APIs when using the visual embed sdk.
|
|
6018
6040
|
* The interface for this method is the same as Web `Fetch`.
|
|
6041
|
+
*
|
|
6019
6042
|
* @param input
|
|
6020
6043
|
* @param init
|
|
6021
6044
|
* @example
|
|
@@ -13960,6 +13983,8 @@ mutation GetUnsavedAnswerTML($session: BachSessionIdInput!, $exportDependencies:
|
|
|
13960
13983
|
},
|
|
13961
13984
|
};
|
|
13962
13985
|
}
|
|
13986
|
+
async getTMLTokens() {
|
|
13987
|
+
}
|
|
13963
13988
|
async addDisplayedVizToLiveboard(liveboardId) {
|
|
13964
13989
|
const { displayMode, visualizations } = await this.getAnswer();
|
|
13965
13990
|
const viz = getDisplayedViz(visualizations, displayMode);
|
|
@@ -20576,6 +20601,7 @@ mutation GetUnsavedAnswerTML($session: BachSessionIdInput!, $exportDependencies:
|
|
|
20576
20601
|
}
|
|
20577
20602
|
/**
|
|
20578
20603
|
* Fetches the session info from the ThoughtSpot server.
|
|
20604
|
+
*
|
|
20579
20605
|
* @param thoughtspotHost
|
|
20580
20606
|
* @returns {Promise<any>}
|
|
20581
20607
|
* @example
|
|
@@ -20607,6 +20633,7 @@ mutation GetUnsavedAnswerTML($session: BachSessionIdInput!, $exportDependencies:
|
|
|
20607
20633
|
}
|
|
20608
20634
|
/**
|
|
20609
20635
|
* Is active service to check if the user is logged in.
|
|
20636
|
+
*
|
|
20610
20637
|
* @param thoughtSpotHost
|
|
20611
20638
|
* @version SDK: 1.28.4 | ThoughtSpot: *
|
|
20612
20639
|
*/
|
|
@@ -20629,6 +20656,7 @@ mutation GetUnsavedAnswerTML($session: BachSessionIdInput!, $exportDependencies:
|
|
|
20629
20656
|
* Returns the session info object and caches it for future use.
|
|
20630
20657
|
* Once fetched the session info object is cached and returned from the cache on
|
|
20631
20658
|
* subsequent calls.
|
|
20659
|
+
*
|
|
20632
20660
|
* @example ```js
|
|
20633
20661
|
* const sessionInfo = await getSessionInfo();
|
|
20634
20662
|
* console.log(sessionInfo);
|
|
@@ -20647,6 +20675,7 @@ mutation GetUnsavedAnswerTML($session: BachSessionIdInput!, $exportDependencies:
|
|
|
20647
20675
|
}
|
|
20648
20676
|
/**
|
|
20649
20677
|
* Processes the session info response and returns the session info object.
|
|
20678
|
+
*
|
|
20650
20679
|
* @param sessionInfoResp {any} Response from the session info API.
|
|
20651
20680
|
* @returns {SessionInfo} The session info object.
|
|
20652
20681
|
* @example ```js
|
|
@@ -20791,6 +20820,7 @@ mutation GetUnsavedAnswerTML($session: BachSessionIdInput!, $exportDependencies:
|
|
|
20791
20820
|
* Services to be called after the login is successful,
|
|
20792
20821
|
* This should be called after the cookie is set for cookie auth or
|
|
20793
20822
|
* after the token is set for cookieless.
|
|
20823
|
+
*
|
|
20794
20824
|
* @return {Promise<void>}
|
|
20795
20825
|
* @example
|
|
20796
20826
|
* ```js
|
|
@@ -21356,6 +21386,7 @@ mutation GetUnsavedAnswerTML($session: BachSessionIdInput!, $exportDependencies:
|
|
|
21356
21386
|
}
|
|
21357
21387
|
/**
|
|
21358
21388
|
* Responds to AuthInit sent from host signifying successful authentication in host.
|
|
21389
|
+
*
|
|
21359
21390
|
* @param e
|
|
21360
21391
|
* @returns {any}
|
|
21361
21392
|
*/
|
|
@@ -21496,7 +21527,7 @@ mutation GetUnsavedAnswerTML($session: BachSessionIdInput!, $exportDependencies:
|
|
|
21496
21527
|
});
|
|
21497
21528
|
}
|
|
21498
21529
|
|
|
21499
|
-
var name="@thoughtspot/visual-embed-sdk";var version="1.32.4-dc.
|
|
21530
|
+
var name="@thoughtspot/visual-embed-sdk";var version="1.32.4-dc.17";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$1={".":{"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 . --incremental false; tsc -p . --incremental false --module commonjs --outDir cjs","build-and-publish":"npm run build:gatsby && npm run publish","bundle-dts-file":"dts-bundle --name @thoughtspot/visual-embed-sdk --out visual-embed-sdk.d.ts --main lib/src/index.d.ts","bundle-dts":"dts-bundle --name ../../dist/visual-embed-sdk --main lib/src/index.d.ts --outputAsModuleFolder=true","bundle-dts-react":"dts-bundle --name ../../../dist/visual-embed-sdk-react --main lib/src/react/index.d.ts --outputAsModuleFolder=true","bundle-dts-react-full":"dts-bundle --name ../../../dist/visual-embed-sdk-react-full --main lib/src/react/all-types-export.d.ts --outputAsModuleFolder=true",build:"rollup -c",watch:"rollup -cw",docgen:"typedoc --tsconfig tsconfig.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 | coveralls","is-publish-allowed":"node scripts/is-publish-allowed.js",prepublishOnly:"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 dc","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={algoliasearch:"^4.10.5",classnames:"^2.3.1",dompurify:"^2.3.4","eslint-plugin-comment-length":"^0.9.2","eslint-plugin-jsdoc":"^46.9.0",eventemitter3:"^4.0.7","gatsby-plugin-vercel":"^1.0.3","html-react-parser":"^1.4.12",lodash:"^4.17.21","mixpanel-browser":"^2.45.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":"^8.2.6","@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":"^22.2.3","@types/lodash":"^4.17.0","@types/mixpanel-browser":"^2.35.6","@types/react-test-renderer":"^17.0.1","@typescript-eslint/eslint-plugin":"^4.6.0","@typescript-eslint/parser":"^4.6.0",asciidoctor:"^2.2.1","babel-jest":"^26.6.3","babel-preset-gatsby":"^1.10.0","command-line-args":"^5.1.1",coveralls:"^3.1.0","current-git-branch":"^1.1.0","dts-bundle":"^0.7.3",eslint:"^7.12.1","eslint-config-airbnb-base":"^14.2.0","eslint-config-prettier":"^6.15.0","eslint-import-resolver-typescript":"^2.3.0","eslint-plugin-import":"^2.22.1","eslint-plugin-prettier":"^3.1.4","eslint-plugin-react-hooks":"^4.2.0","fs-extra":"^10.0.0","gh-pages":"^3.1.0","highlight.js":"^10.6.0","html-to-text":"^8.0.0","identity-obj-proxy":"^3.0.0","istanbul-merge":"^1.1.1",jest:"^26.6.3","jest-fetch-mock":"^3.0.3",jsdom:"^17.0.0","node-sass":"^8.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:"2.30.0","rollup-plugin-typescript2":"0.27.3","ts-jest":"^26.5.5","ts-loader":"8.0.4",typedoc:"0.21.6","typedoc-plugin-toc-group":"thoughtspot/typedoc-plugin-toc-group",typescript:"^4.9.4","url-search-params-polyfill":"^8.1.0",util:"^0.12.4",vite:"^5.3.4"};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,description:description,module:module,main:main,types:types,files:files,exports:exports$1,typesVersions:typesVersions,"size-limit":[{path:"dist/tsembed.js",limit:"48 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};
|
|
21500
21531
|
|
|
21501
21532
|
/**
|
|
21502
21533
|
* Copyright (c) 2022
|
|
@@ -23094,6 +23125,22 @@ query GetEurekaVizSnapshots(
|
|
|
23094
23125
|
this.render();
|
|
23095
23126
|
}
|
|
23096
23127
|
}
|
|
23128
|
+
/**
|
|
23129
|
+
* Returns the full url of the liveboard/viz which can be used to open
|
|
23130
|
+
* this liveboard inside the full Thoughtspot application in a new tab.
|
|
23131
|
+
*
|
|
23132
|
+
* @returns url string
|
|
23133
|
+
*/
|
|
23134
|
+
getLiveboardUrl() {
|
|
23135
|
+
let url = `${this.thoughtSpotHost}/#/pinboard/${this.viewConfig.liveboardId}`;
|
|
23136
|
+
if (this.viewConfig.activeTabId) {
|
|
23137
|
+
url = `${url}/tab/${this.viewConfig.activeTabId}`;
|
|
23138
|
+
}
|
|
23139
|
+
if (this.viewConfig.vizId) {
|
|
23140
|
+
url = `${url}/${this.viewConfig.vizId}`;
|
|
23141
|
+
}
|
|
23142
|
+
return url;
|
|
23143
|
+
}
|
|
23097
23144
|
}
|
|
23098
23145
|
/**
|
|
23099
23146
|
* @hidden
|
|
@@ -24296,7 +24343,10 @@ query GetEurekaResults($params: Input_eureka_SearchRequest) {
|
|
|
24296
24343
|
genNo: suggestion.stateKey.generationNumber,
|
|
24297
24344
|
},
|
|
24298
24345
|
};
|
|
24299
|
-
return
|
|
24346
|
+
return {
|
|
24347
|
+
answer: new AnswerService(answerSession, null, embedConfig.thoughtSpotHost),
|
|
24348
|
+
suggestion,
|
|
24349
|
+
};
|
|
24300
24350
|
};
|
|
24301
24351
|
|
|
24302
24352
|
const createLiveboardWithAnswers = async (answers, name) => {
|
|
@@ -1425,6 +1425,7 @@ export interface LiveboardViewConfig extends Omit<ViewConfig, 'hiddenHomepageMod
|
|
|
1425
1425
|
*
|
|
1426
1426
|
* Since, this will show preview images, be careful that it may show
|
|
1427
1427
|
* undesired data to the user when using row level security.
|
|
1428
|
+
*
|
|
1428
1429
|
* @example
|
|
1429
1430
|
* ```js
|
|
1430
1431
|
* const embed = new LiveboardEmbed('#embed-container', {
|
|
@@ -1434,6 +1435,7 @@ export interface LiveboardViewConfig extends Omit<ViewConfig, 'hiddenHomepageMod
|
|
|
1434
1435
|
* });
|
|
1435
1436
|
* embed.render();
|
|
1436
1437
|
* ```
|
|
1438
|
+
*
|
|
1437
1439
|
* @version SDK: 1.32.0 | ThoughtSpot: 10.0.0.cl
|
|
1438
1440
|
*/
|
|
1439
1441
|
showPreviewLoader?: boolean;
|
|
@@ -1476,6 +1478,13 @@ export declare class LiveboardEmbed extends V1Embed {
|
|
|
1476
1478
|
*/
|
|
1477
1479
|
render(): Promise<LiveboardEmbed>;
|
|
1478
1480
|
navigateToLiveboard(liveboardId: string, vizId?: string, activeTabId?: string): void;
|
|
1481
|
+
/**
|
|
1482
|
+
* Returns the full url of the liveboard/viz which can be used to open
|
|
1483
|
+
* this liveboard inside the full Thoughtspot application in a new tab.
|
|
1484
|
+
*
|
|
1485
|
+
* @returns url string
|
|
1486
|
+
*/
|
|
1487
|
+
getLiveboardUrl(): string;
|
|
1479
1488
|
}
|
|
1480
1489
|
/**
|
|
1481
1490
|
* @hidden
|
|
@@ -1783,6 +1792,7 @@ export declare function notifyLogout(): void;
|
|
|
1783
1792
|
* Services to be called after the login is successful,
|
|
1784
1793
|
* This should be called after the cookie is set for cookie auth or
|
|
1785
1794
|
* after the token is set for cookieless.
|
|
1795
|
+
*
|
|
1786
1796
|
* @return {Promise<void>}
|
|
1787
1797
|
* @example
|
|
1788
1798
|
* ```js
|
|
@@ -1842,6 +1852,7 @@ export type SessionInfo = {
|
|
|
1842
1852
|
* Returns the session info object and caches it for future use.
|
|
1843
1853
|
* Once fetched the session info object is cached and returned from the cache on
|
|
1844
1854
|
* subsequent calls.
|
|
1855
|
+
*
|
|
1845
1856
|
* @example ```js
|
|
1846
1857
|
* const sessionInfo = await getSessionInfo();
|
|
1847
1858
|
* console.log(sessionInfo);
|
|
@@ -1853,6 +1864,7 @@ export declare function getSessionInfo(): Promise<SessionInfo>;
|
|
|
1853
1864
|
/**
|
|
1854
1865
|
* Returns the cached session info object. If the client is not authenticated the
|
|
1855
1866
|
* function will return null.
|
|
1867
|
+
*
|
|
1856
1868
|
* @example ```js
|
|
1857
1869
|
* const sessionInfo = getCachedSessionInfo();
|
|
1858
1870
|
* if (sessionInfo) {
|
|
@@ -1867,6 +1879,7 @@ export declare function getSessionInfo(): Promise<SessionInfo>;
|
|
|
1867
1879
|
export declare function getCachedSessionInfo(): SessionInfo | null;
|
|
1868
1880
|
/**
|
|
1869
1881
|
* Processes the session info response and returns the session info object.
|
|
1882
|
+
*
|
|
1870
1883
|
* @param sessionInfoResp {any} Response from the session info API.
|
|
1871
1884
|
* @returns {SessionInfo} The session info object.
|
|
1872
1885
|
* @example ```js
|
|
@@ -1879,6 +1892,7 @@ export declare function getCachedSessionInfo(): SessionInfo | null;
|
|
|
1879
1892
|
export declare const getSessionDetails: (sessionInfoResp: any) => SessionInfo;
|
|
1880
1893
|
/**
|
|
1881
1894
|
* Resets the cached session info object and forces a new fetch on the next call.
|
|
1895
|
+
*
|
|
1882
1896
|
* @example ```js
|
|
1883
1897
|
* resetCachedSessionInfo();
|
|
1884
1898
|
* const sessionInfo = await getSessionInfo();
|
|
@@ -4307,23 +4321,28 @@ export declare enum HostEvent {
|
|
|
4307
4321
|
/**
|
|
4308
4322
|
* Trigger the **Make a copy** action on a Liveboard,
|
|
4309
4323
|
* visualization, or Answer page.
|
|
4324
|
+
*
|
|
4310
4325
|
* @example
|
|
4311
4326
|
* ```js
|
|
4312
4327
|
* liveboardEmbed.trigger(HostEvent.MakeACopy)
|
|
4313
4328
|
* ```
|
|
4329
|
+
*
|
|
4314
4330
|
* @example
|
|
4315
4331
|
* ```js
|
|
4316
4332
|
* liveboardEmbed.trigger(HostEvent.MakeACopy, {
|
|
4317
4333
|
* vizId: '730496d6-6903-4601-937e-2c691821af3c'})
|
|
4318
4334
|
* ```
|
|
4335
|
+
*
|
|
4319
4336
|
* @example
|
|
4320
4337
|
* ```js
|
|
4321
4338
|
* vizEmbed.trigger(HostEvent.MakeACopy)
|
|
4322
4339
|
* ```
|
|
4340
|
+
*
|
|
4323
4341
|
* @example
|
|
4324
4342
|
* ```js
|
|
4325
4343
|
* searchEmbed.trigger(HostEvent.MakeACopy)
|
|
4326
4344
|
* ```
|
|
4345
|
+
*
|
|
4327
4346
|
* @version SDK: 1.15.0 | ThoughtSpot: 8.7.0.cl, 8.8.1.sw
|
|
4328
4347
|
*/
|
|
4329
4348
|
MakeACopy = "makeACopy",
|
|
@@ -4349,6 +4368,7 @@ export declare enum HostEvent {
|
|
|
4349
4368
|
/**
|
|
4350
4369
|
* Trigger the **Create alert** action on a KPI chart
|
|
4351
4370
|
* in a Liveboard or saved Answer.
|
|
4371
|
+
*
|
|
4352
4372
|
* @param - an object with `vizId` as a key
|
|
4353
4373
|
* @example
|
|
4354
4374
|
* ```js
|
|
@@ -4356,6 +4376,7 @@ export declare enum HostEvent {
|
|
|
4356
4376
|
* vizId: '730496d6-6903-4601-937e-2c691821af3c'
|
|
4357
4377
|
* })
|
|
4358
4378
|
* ```
|
|
4379
|
+
*
|
|
4359
4380
|
* @example
|
|
4360
4381
|
* ```js
|
|
4361
4382
|
* searchEmbed.trigger(HostEvent.CreateMonitor)
|
|
@@ -4366,6 +4387,7 @@ export declare enum HostEvent {
|
|
|
4366
4387
|
/**
|
|
4367
4388
|
* Trigger the **Manage alerts** action on a KPI chart
|
|
4368
4389
|
* in a visualization or saved Answer.
|
|
4390
|
+
*
|
|
4369
4391
|
* @param - an object with `vizId` as a key
|
|
4370
4392
|
* @example
|
|
4371
4393
|
* ```js
|
|
@@ -4373,10 +4395,12 @@ export declare enum HostEvent {
|
|
|
4373
4395
|
* vizId: '730496d6-6903-4601-937e-2c691821af3c'
|
|
4374
4396
|
* })
|
|
4375
4397
|
* ```
|
|
4398
|
+
*
|
|
4376
4399
|
* @example
|
|
4377
4400
|
* ```js
|
|
4378
4401
|
* searchEmbed.trigger(HostEvent.ManageMonitor)
|
|
4379
4402
|
* ```
|
|
4403
|
+
*
|
|
4380
4404
|
* @example
|
|
4381
4405
|
* ```js
|
|
4382
4406
|
* vizEmbed.trigger(HostEvent.ManageMonitor)
|
|
@@ -4774,6 +4798,7 @@ export declare enum HostEvent {
|
|
|
4774
4798
|
/**
|
|
4775
4799
|
* Get the answer session for a Search or
|
|
4776
4800
|
* Liveboard visualization.
|
|
4801
|
+
*
|
|
4777
4802
|
* @example
|
|
4778
4803
|
* ```js
|
|
4779
4804
|
* const {session} = await embed.trigger(
|
|
@@ -4781,10 +4806,12 @@ export declare enum HostEvent {
|
|
|
4781
4806
|
* vizId: '123', // For Liveboard Visualization.
|
|
4782
4807
|
* })
|
|
4783
4808
|
* ```
|
|
4809
|
+
*
|
|
4784
4810
|
* @example
|
|
4785
4811
|
* ```js
|
|
4786
4812
|
* const {session} = await embed.trigger( HostEvent.GetAnswerSession )
|
|
4787
4813
|
* ```
|
|
4814
|
+
*
|
|
4788
4815
|
* @version SDK: 1.26.0 | Thoughtspot: 9.10.0.cl
|
|
4789
4816
|
*/
|
|
4790
4817
|
GetAnswerSession = "getAnswerSession",
|
|
@@ -5503,6 +5530,7 @@ export declare enum Action {
|
|
|
5503
5530
|
/**
|
|
5504
5531
|
* @deprecated
|
|
5505
5532
|
* Reports errors
|
|
5533
|
+
*
|
|
5506
5534
|
* @example
|
|
5507
5535
|
* ```js
|
|
5508
5536
|
* disabledActions: [Action.ReportError]
|
|
@@ -5732,12 +5760,14 @@ export declare enum Action {
|
|
|
5732
5760
|
* ```js
|
|
5733
5761
|
* disabledActions: [Action.RequestVerification]
|
|
5734
5762
|
* ```
|
|
5763
|
+
*
|
|
5735
5764
|
* @version SDK: 1.25.0 | Thoughtspot: 9.6.0.cl
|
|
5736
5765
|
*/
|
|
5737
5766
|
RequestVerification = "requestVerification",
|
|
5738
5767
|
/**
|
|
5739
5768
|
*
|
|
5740
|
-
*Allows users to mark a Liveboard as verified.
|
|
5769
|
+
* Allows users to mark a Liveboard as verified.
|
|
5770
|
+
*
|
|
5741
5771
|
* @example
|
|
5742
5772
|
* ```js
|
|
5743
5773
|
* disabledActions: [Action.MarkAsVerified]
|
|
@@ -5748,6 +5778,7 @@ export declare enum Action {
|
|
|
5748
5778
|
/**
|
|
5749
5779
|
* The **Add Tab** action on a Liveboard.
|
|
5750
5780
|
* Allows adding a new tab to a Liveboard view.
|
|
5781
|
+
*
|
|
5751
5782
|
* @example
|
|
5752
5783
|
* ```js
|
|
5753
5784
|
* disabledActions: [Action.AddTab]
|
|
@@ -5757,7 +5788,8 @@ export declare enum Action {
|
|
|
5757
5788
|
AddTab = "addTab",
|
|
5758
5789
|
/**
|
|
5759
5790
|
*
|
|
5760
|
-
*Initiates contextual change analysis on KPI charts.
|
|
5791
|
+
* Initiates contextual change analysis on KPI charts.
|
|
5792
|
+
*
|
|
5761
5793
|
* @example
|
|
5762
5794
|
* ```js
|
|
5763
5795
|
* disabledActions: [Action.EnableContextualChangeAnalysis]
|
|
@@ -5771,6 +5803,7 @@ export declare enum Action {
|
|
|
5771
5803
|
* ```js
|
|
5772
5804
|
* disabledActions: [Action.ShowSageQuery]
|
|
5773
5805
|
* ```
|
|
5806
|
+
*
|
|
5774
5807
|
* @version SDK: 1.26.0 | Thoughtspot: 9.7.0.cl
|
|
5775
5808
|
*/
|
|
5776
5809
|
ShowSageQuery = "showSageQuery",
|
|
@@ -5785,7 +5818,8 @@ export declare enum Action {
|
|
|
5785
5818
|
EditSageAnswer = "editSageAnswer",
|
|
5786
5819
|
/**
|
|
5787
5820
|
*
|
|
5788
|
-
*This action allows users to send feedback on AI-generated Answers.
|
|
5821
|
+
* This action allows users to send feedback on AI-generated Answers.
|
|
5822
|
+
*
|
|
5789
5823
|
* @example
|
|
5790
5824
|
* ```js
|
|
5791
5825
|
* disabledActions: [Action.SageAnswerFeedback]
|
|
@@ -5862,6 +5896,7 @@ export declare enum Action {
|
|
|
5862
5896
|
* hiddenAction: [Action.CreateLiveboard]
|
|
5863
5897
|
* disabledActions: [Action.CreateLiveboard]
|
|
5864
5898
|
* ```
|
|
5899
|
+
*
|
|
5865
5900
|
* @version SDK: 1.32.0 | Thoughtspot: 10.1.0.cl
|
|
5866
5901
|
*/
|
|
5867
5902
|
CreateLiveboard = "createLiveboard",
|
|
@@ -5957,6 +5992,7 @@ export declare enum Action {
|
|
|
5957
5992
|
UnsubscribeScheduleHomepage = "unsubscribeScheduleHomepage",
|
|
5958
5993
|
/**
|
|
5959
5994
|
* The **Manage Tags** action on Homepage Favourite Module.
|
|
5995
|
+
*
|
|
5960
5996
|
* @example
|
|
5961
5997
|
* ```js
|
|
5962
5998
|
* disabledActions: [Action.ManageTags]
|
|
@@ -6636,6 +6672,7 @@ export declare class AnswerService {
|
|
|
6636
6672
|
getSession(): SessionInterface;
|
|
6637
6673
|
getAnswer(): Promise<any>;
|
|
6638
6674
|
getTML(): Promise<any>;
|
|
6675
|
+
getTMLTokens(): Promise<void>;
|
|
6639
6676
|
addDisplayedVizToLiveboard(liveboardId: string): Promise<any>;
|
|
6640
6677
|
setTMLOverride(override: any): void;
|
|
6641
6678
|
}
|
|
@@ -6694,6 +6731,7 @@ export declare function testResetMixpanel(): void;
|
|
|
6694
6731
|
* Fetch wrapper that adds the authentication token to the request.
|
|
6695
6732
|
* Use this to call the ThoughtSpot APIs when using the visual embed sdk.
|
|
6696
6733
|
* The interface for this method is the same as Web `Fetch`.
|
|
6734
|
+
*
|
|
6697
6735
|
* @param input
|
|
6698
6736
|
* @param init
|
|
6699
6737
|
* @example
|
|
@@ -6713,7 +6751,10 @@ export declare const tokenizedFetch: typeof fetch;
|
|
|
6713
6751
|
* @param worksheetId string
|
|
6714
6752
|
* @returns answerService AnswerService
|
|
6715
6753
|
*/
|
|
6716
|
-
export declare const getAnswerFromQuery: (query: string, worksheetId: string) => Promise<
|
|
6754
|
+
export declare const getAnswerFromQuery: (query: string, worksheetId: string) => Promise<{
|
|
6755
|
+
answer: AnswerService;
|
|
6756
|
+
suggestion: any;
|
|
6757
|
+
}>;
|
|
6717
6758
|
|
|
6718
6759
|
export declare const createLiveboardWithAnswers: (answers: AnswerService[], name: string) => Promise<any>;
|
|
6719
6760
|
|