@thoughtspot/visual-embed-sdk 1.43.1 → 1.44.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (108) hide show
  1. package/cjs/package.json +1 -1
  2. package/cjs/src/embed/app.d.ts +15 -0
  3. package/cjs/src/embed/app.d.ts.map +1 -1
  4. package/cjs/src/embed/app.js +4 -1
  5. package/cjs/src/embed/app.js.map +1 -1
  6. package/cjs/src/embed/app.spec.js +20 -0
  7. package/cjs/src/embed/app.spec.js.map +1 -1
  8. package/cjs/src/embed/base.d.ts +7 -0
  9. package/cjs/src/embed/base.d.ts.map +1 -1
  10. package/cjs/src/embed/base.js +16 -1
  11. package/cjs/src/embed/base.js.map +1 -1
  12. package/cjs/src/embed/base.spec.js +21 -0
  13. package/cjs/src/embed/base.spec.js.map +1 -1
  14. package/cjs/src/embed/conversation.d.ts +15 -0
  15. package/cjs/src/embed/conversation.d.ts.map +1 -1
  16. package/cjs/src/embed/conversation.js +4 -1
  17. package/cjs/src/embed/conversation.js.map +1 -1
  18. package/cjs/src/embed/conversation.spec.js +24 -0
  19. package/cjs/src/embed/conversation.spec.js.map +1 -1
  20. package/cjs/src/embed/liveboard.d.ts +15 -0
  21. package/cjs/src/embed/liveboard.d.ts.map +1 -1
  22. package/cjs/src/embed/liveboard.js +4 -1
  23. package/cjs/src/embed/liveboard.js.map +1 -1
  24. package/cjs/src/embed/liveboard.spec.js +22 -0
  25. package/cjs/src/embed/liveboard.spec.js.map +1 -1
  26. package/cjs/src/index.d.ts +2 -2
  27. package/cjs/src/index.d.ts.map +1 -1
  28. package/cjs/src/index.js +2 -1
  29. package/cjs/src/index.js.map +1 -1
  30. package/cjs/src/react/all-types-export.d.ts +1 -1
  31. package/cjs/src/react/all-types-export.d.ts.map +1 -1
  32. package/cjs/src/react/all-types-export.js +2 -1
  33. package/cjs/src/react/all-types-export.js.map +1 -1
  34. package/cjs/src/types.d.ts +56 -6
  35. package/cjs/src/types.d.ts.map +1 -1
  36. package/cjs/src/types.js +41 -0
  37. package/cjs/src/types.js.map +1 -1
  38. package/dist/{index-CpkMygsc.js → index-BE9gGzRX.js} +1 -1
  39. package/dist/src/embed/app.d.ts +15 -0
  40. package/dist/src/embed/app.d.ts.map +1 -1
  41. package/dist/src/embed/base.d.ts +7 -0
  42. package/dist/src/embed/base.d.ts.map +1 -1
  43. package/dist/src/embed/conversation.d.ts +15 -0
  44. package/dist/src/embed/conversation.d.ts.map +1 -1
  45. package/dist/src/embed/liveboard.d.ts +15 -0
  46. package/dist/src/embed/liveboard.d.ts.map +1 -1
  47. package/dist/src/index.d.ts +2 -2
  48. package/dist/src/index.d.ts.map +1 -1
  49. package/dist/src/react/all-types-export.d.ts +1 -1
  50. package/dist/src/react/all-types-export.d.ts.map +1 -1
  51. package/dist/src/types.d.ts +56 -6
  52. package/dist/src/types.d.ts.map +1 -1
  53. package/dist/tsembed-react.es.js +126 -76
  54. package/dist/tsembed-react.js +125 -75
  55. package/dist/tsembed.es.js +140 -77
  56. package/dist/tsembed.js +139 -75
  57. package/dist/visual-embed-sdk-react-full.d.ts +106 -5
  58. package/dist/visual-embed-sdk-react.d.ts +99 -5
  59. package/dist/visual-embed-sdk.d.ts +106 -5
  60. package/lib/package.json +1 -1
  61. package/lib/src/embed/app.d.ts +15 -0
  62. package/lib/src/embed/app.d.ts.map +1 -1
  63. package/lib/src/embed/app.js +5 -2
  64. package/lib/src/embed/app.js.map +1 -1
  65. package/lib/src/embed/app.spec.js +20 -0
  66. package/lib/src/embed/app.spec.js.map +1 -1
  67. package/lib/src/embed/base.d.ts +7 -0
  68. package/lib/src/embed/base.d.ts.map +1 -1
  69. package/lib/src/embed/base.js +14 -0
  70. package/lib/src/embed/base.js.map +1 -1
  71. package/lib/src/embed/base.spec.js +21 -0
  72. package/lib/src/embed/base.spec.js.map +1 -1
  73. package/lib/src/embed/conversation.d.ts +15 -0
  74. package/lib/src/embed/conversation.d.ts.map +1 -1
  75. package/lib/src/embed/conversation.js +4 -1
  76. package/lib/src/embed/conversation.js.map +1 -1
  77. package/lib/src/embed/conversation.spec.js +24 -0
  78. package/lib/src/embed/conversation.spec.js.map +1 -1
  79. package/lib/src/embed/liveboard.d.ts +15 -0
  80. package/lib/src/embed/liveboard.d.ts.map +1 -1
  81. package/lib/src/embed/liveboard.js +4 -1
  82. package/lib/src/embed/liveboard.js.map +1 -1
  83. package/lib/src/embed/liveboard.spec.js +22 -0
  84. package/lib/src/embed/liveboard.spec.js.map +1 -1
  85. package/lib/src/index.d.ts +2 -2
  86. package/lib/src/index.d.ts.map +1 -1
  87. package/lib/src/index.js +2 -2
  88. package/lib/src/index.js.map +1 -1
  89. package/lib/src/react/all-types-export.d.ts +1 -1
  90. package/lib/src/react/all-types-export.d.ts.map +1 -1
  91. package/lib/src/react/all-types-export.js +1 -1
  92. package/lib/src/react/all-types-export.js.map +1 -1
  93. package/lib/src/types.d.ts +56 -6
  94. package/lib/src/types.d.ts.map +1 -1
  95. package/lib/src/types.js +41 -0
  96. package/lib/src/types.js.map +1 -1
  97. package/package.json +1 -1
  98. package/src/embed/app.spec.ts +30 -2
  99. package/src/embed/app.ts +43 -22
  100. package/src/embed/base.spec.ts +28 -0
  101. package/src/embed/base.ts +15 -0
  102. package/src/embed/conversation.spec.ts +32 -0
  103. package/src/embed/conversation.ts +21 -0
  104. package/src/embed/liveboard.spec.ts +29 -0
  105. package/src/embed/liveboard.ts +19 -0
  106. package/src/index.ts +2 -0
  107. package/src/react/all-types-export.ts +1 -0
  108. package/src/types.ts +54 -5
@@ -1,4 +1,4 @@
1
- /* @thoughtspot/visual-embed-sdk version 1.43.1 */
1
+ /* @thoughtspot/visual-embed-sdk version 1.44.1 */
2
2
  'use client';
3
3
  (function (global, factory) {
4
4
  typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('react')) :
@@ -3334,6 +3334,7 @@
3334
3334
  Param["isCentralizedLiveboardFilterUXEnabled"] = "isCentralizedLiveboardFilterUXEnabled";
3335
3335
  Param["isLinkParametersEnabled"] = "isLinkParametersEnabled";
3336
3336
  Param["EnablePastConversationsSidebar"] = "enablePastConversationsSidebar";
3337
+ Param["UpdatedSpotterChatPrompt"] = "updatedSpotterChatPrompt";
3337
3338
  })(Param || (Param = {}));
3338
3339
  /**
3339
3340
  * ThoughtSpot application pages include actions and menu commands
@@ -4648,6 +4649,46 @@
4648
4649
  * @version SDK: 1.43.0 | ThoughtSpot Cloud: 10.15.0.cl
4649
4650
  */
4650
4651
  Action["LiveboardStylePanel"] = "liveboardStylePanel";
4652
+ /**
4653
+ * The **Move to Group** menu action on a Liveboard.
4654
+ * Allows moving a visualization to a different group.
4655
+ * @example
4656
+ * ```js
4657
+ * disabledActions: [Action.MoveToGroup]
4658
+ * ```
4659
+ * @version SDK: 1.44.0 | ThoughtSpot Cloud: 26.2.0.cl
4660
+ */
4661
+ Action["MoveToGroup"] = "moveToGroup";
4662
+ /**
4663
+ * The **Move out of Group** menu action on a Liveboard.
4664
+ * Allows moving a visualization out of a group.
4665
+ * @example
4666
+ * ```js
4667
+ * disabledActions: [Action.MoveOutOfGroup]
4668
+ * ```
4669
+ * @version SDK: 1.44.0 | ThoughtSpot Cloud: 26.2.0.cl
4670
+ */
4671
+ Action["MoveOutOfGroup"] = "moveOutOfGroup";
4672
+ /**
4673
+ * The **Create Group** menu action on a Liveboard.
4674
+ * Allows creating a new group.
4675
+ * @example
4676
+ * ```js
4677
+ * disabledActions: [Action.CreateGroup]
4678
+ * ```
4679
+ * @version SDK: 1.44.0 | ThoughtSpot Cloud: 26.2.0.cl
4680
+ */
4681
+ Action["CreateGroup"] = "createGroup";
4682
+ /**
4683
+ * The **Ungroup Liveboard Group** menu action on a Liveboard.
4684
+ * Allows ungrouping a liveboard group.
4685
+ * @example
4686
+ * ```js
4687
+ * disabledActions: [Action.UngroupLiveboardGroup]
4688
+ * ```
4689
+ * @version SDK: 1.44.0 | ThoughtSpot Cloud: 26.2.0.cl
4690
+ */
4691
+ Action["UngroupLiveboardGroup"] = "ungroupLiveboardGroup";
4651
4692
  })(exports.Action || (exports.Action = {}));
4652
4693
  var PrefetchFeatures;
4653
4694
  (function (PrefetchFeatures) {
@@ -17337,6 +17378,76 @@ mutation GetUnsavedAnswerTML($session: BachSessionIdInput!, $exportDependencies:
17337
17378
  };
17338
17379
  }
17339
17380
 
17381
+ /**
17382
+ * Reloads the ThoughtSpot iframe.
17383
+ * @param iFrame
17384
+ */
17385
+ const reload = (iFrame) => {
17386
+ const src = iFrame.src;
17387
+ iFrame.src = '';
17388
+ setTimeout(() => {
17389
+ iFrame.src = src;
17390
+ }, 100);
17391
+ };
17392
+ /**
17393
+ * Post iframe message.
17394
+ * @param iFrame
17395
+ * @param message
17396
+ * @param message.type
17397
+ * @param message.data
17398
+ * @param thoughtSpotHost
17399
+ * @param channel
17400
+ */
17401
+ function postIframeMessage(iFrame, message, thoughtSpotHost, channel) {
17402
+ var _a;
17403
+ return (_a = iFrame.contentWindow) === null || _a === void 0 ? void 0 : _a.postMessage(message, thoughtSpotHost, [channel === null || channel === void 0 ? void 0 : channel.port2]);
17404
+ }
17405
+ const TRIGGER_TIMEOUT = 30000;
17406
+ /**
17407
+ *
17408
+ * @param iFrame
17409
+ * @param messageType
17410
+ * @param thoughtSpotHost
17411
+ * @param data
17412
+ */
17413
+ function processTrigger(iFrame, messageType, thoughtSpotHost, data) {
17414
+ return new Promise((res, rej) => {
17415
+ var _a;
17416
+ if (messageType === exports.HostEvent.Reload) {
17417
+ reload(iFrame);
17418
+ return res(null);
17419
+ }
17420
+ if (messageType === exports.HostEvent.Present) {
17421
+ const embedConfig = getEmbedConfig();
17422
+ const disableFullscreenPresentation = (_a = embedConfig === null || embedConfig === void 0 ? void 0 : embedConfig.disableFullscreenPresentation) !== null && _a !== void 0 ? _a : true;
17423
+ if (!disableFullscreenPresentation) {
17424
+ handlePresentEvent(iFrame);
17425
+ }
17426
+ else {
17427
+ logger$3.warn('Fullscreen presentation mode is disabled. Set disableFullscreenPresentation: false to enable this feature.');
17428
+ }
17429
+ }
17430
+ const channel = new MessageChannel();
17431
+ channel.port1.onmessage = ({ data: responseData }) => {
17432
+ var _a;
17433
+ channel.port1.close();
17434
+ const error = responseData.error || ((_a = responseData === null || responseData === void 0 ? void 0 : responseData.data) === null || _a === void 0 ? void 0 : _a.error);
17435
+ if (error) {
17436
+ rej(error);
17437
+ }
17438
+ else {
17439
+ res(responseData);
17440
+ }
17441
+ };
17442
+ // Close the messageChannel and resolve the promise if timeout.
17443
+ setTimeout(() => {
17444
+ channel.port1.close();
17445
+ res(new Error(ERROR_MESSAGE.TRIGGER_TIMED_OUT));
17446
+ }, TRIGGER_TIMEOUT);
17447
+ return postIframeMessage(iFrame, { type: messageType, data }, thoughtSpotHost, channel);
17448
+ });
17449
+ }
17450
+
17340
17451
  /* eslint-disable camelcase */
17341
17452
  /* eslint-disable import/no-mutable-exports */
17342
17453
  /**
@@ -17675,77 +17786,7 @@ mutation GetUnsavedAnswerTML($session: BachSessionIdInput!, $exportDependencies:
17675
17786
  return eventData;
17676
17787
  }
17677
17788
 
17678
- var name="@thoughtspot/visual-embed-sdk";var version$1="1.43.1";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 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":"^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":"^8.28.0","@typescript-eslint/parser":"^8.28.0",ajv:"^8.17.1",asciidoctor:"^2.2.1","babel-jest":"^26.6.3","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:"^26.6.3","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":"^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","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$1,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};
17679
-
17680
- /**
17681
- * Reloads the ThoughtSpot iframe.
17682
- * @param iFrame
17683
- */
17684
- const reload = (iFrame) => {
17685
- const src = iFrame.src;
17686
- iFrame.src = '';
17687
- setTimeout(() => {
17688
- iFrame.src = src;
17689
- }, 100);
17690
- };
17691
- /**
17692
- * Post iframe message.
17693
- * @param iFrame
17694
- * @param message
17695
- * @param message.type
17696
- * @param message.data
17697
- * @param thoughtSpotHost
17698
- * @param channel
17699
- */
17700
- function postIframeMessage(iFrame, message, thoughtSpotHost, channel) {
17701
- var _a;
17702
- return (_a = iFrame.contentWindow) === null || _a === void 0 ? void 0 : _a.postMessage(message, thoughtSpotHost, [channel === null || channel === void 0 ? void 0 : channel.port2]);
17703
- }
17704
- const TRIGGER_TIMEOUT = 30000;
17705
- /**
17706
- *
17707
- * @param iFrame
17708
- * @param messageType
17709
- * @param thoughtSpotHost
17710
- * @param data
17711
- */
17712
- function processTrigger(iFrame, messageType, thoughtSpotHost, data) {
17713
- return new Promise((res, rej) => {
17714
- var _a;
17715
- if (messageType === exports.HostEvent.Reload) {
17716
- reload(iFrame);
17717
- return res(null);
17718
- }
17719
- if (messageType === exports.HostEvent.Present) {
17720
- const embedConfig = getEmbedConfig();
17721
- const disableFullscreenPresentation = (_a = embedConfig === null || embedConfig === void 0 ? void 0 : embedConfig.disableFullscreenPresentation) !== null && _a !== void 0 ? _a : true;
17722
- if (!disableFullscreenPresentation) {
17723
- handlePresentEvent(iFrame);
17724
- }
17725
- else {
17726
- logger$3.warn('Fullscreen presentation mode is disabled. Set disableFullscreenPresentation: false to enable this feature.');
17727
- }
17728
- }
17729
- const channel = new MessageChannel();
17730
- channel.port1.onmessage = ({ data: responseData }) => {
17731
- var _a;
17732
- channel.port1.close();
17733
- const error = responseData.error || ((_a = responseData === null || responseData === void 0 ? void 0 : responseData.data) === null || _a === void 0 ? void 0 : _a.error);
17734
- if (error) {
17735
- rej(error);
17736
- }
17737
- else {
17738
- res(responseData);
17739
- }
17740
- };
17741
- // Close the messageChannel and resolve the promise if timeout.
17742
- setTimeout(() => {
17743
- channel.port1.close();
17744
- res(new Error(ERROR_MESSAGE.TRIGGER_TIMED_OUT));
17745
- }, TRIGGER_TIMEOUT);
17746
- return postIframeMessage(iFrame, { type: messageType, data }, thoughtSpotHost, channel);
17747
- });
17748
- }
17789
+ var name="@thoughtspot/visual-embed-sdk";var version$1="1.44.1";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 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":"^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":"^8.28.0","@typescript-eslint/parser":"^8.28.0",ajv:"^8.17.1",asciidoctor:"^2.2.1","babel-jest":"^26.6.3","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:"^26.6.3","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":"^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","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$1,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};
17749
17790
 
17750
17791
  class HostEventClient {
17751
17792
  constructor(iFrame) {
@@ -19943,7 +19984,7 @@ mutation GetUnsavedAnswerTML($session: BachSessionIdInput!, $exportDependencies:
19943
19984
  * embedded Liveboard or visualization.
19944
19985
  */
19945
19986
  getEmbedParams() {
19946
- const { tag, hideTagFilterChips, hideObjects, liveboardV2, showPrimaryNavbar, disableProfileAndHelp, hideHamburger, hideObjectSearch, hideNotification, hideApplicationSwitcher, hideOrgSwitcher, enableSearchAssist, fullHeight, dataPanelV2 = true, hideLiveboardHeader = false, showLiveboardTitle = true, showLiveboardDescription = true, hideHomepageLeftNav = false, modularHomeExperience = false, isLiveboardHeaderSticky = true, enableAskSage, collapseSearchBarInitially = false, enable2ColumnLayout, enableCustomColumnGroups = false, dataPanelCustomGroupsAccordionInitialState = DataPanelCustomColumnGroupsAccordionState.EXPAND_ALL, collapseSearchBar = true, isLiveboardCompactHeaderEnabled = false, showLiveboardVerifiedBadge = true, showLiveboardReverifyBanner = true, hideIrrelevantChipsInLiveboardTabs = false, isEnhancedFilterInteractivityEnabled = false, homePageSearchBarMode, isUnifiedSearchExperienceEnabled = true, enablePendoHelp = true, discoveryExperience, coverAndFilterOptionInPDF = false, liveboardXLSXCSVDownload, isLiveboardStylingAndGroupingEnabled, isPNGInScheduledEmailsEnabled = false, isCentralizedLiveboardFilterUXEnabled = false, isLinkParametersEnabled, } = this.viewConfig;
19987
+ const { tag, hideTagFilterChips, hideObjects, liveboardV2, showPrimaryNavbar, disableProfileAndHelp, hideHamburger, hideObjectSearch, hideNotification, hideApplicationSwitcher, hideOrgSwitcher, enableSearchAssist, fullHeight, dataPanelV2 = true, hideLiveboardHeader = false, showLiveboardTitle = true, showLiveboardDescription = true, hideHomepageLeftNav = false, modularHomeExperience = false, isLiveboardHeaderSticky = true, enableAskSage, collapseSearchBarInitially = false, enable2ColumnLayout, enableCustomColumnGroups = false, dataPanelCustomGroupsAccordionInitialState = DataPanelCustomColumnGroupsAccordionState.EXPAND_ALL, collapseSearchBar = true, isLiveboardCompactHeaderEnabled = false, showLiveboardVerifiedBadge = true, showLiveboardReverifyBanner = true, hideIrrelevantChipsInLiveboardTabs = false, isEnhancedFilterInteractivityEnabled = false, homePageSearchBarMode, isUnifiedSearchExperienceEnabled = true, enablePendoHelp = true, discoveryExperience, coverAndFilterOptionInPDF = false, liveboardXLSXCSVDownload, isLiveboardStylingAndGroupingEnabled, isPNGInScheduledEmailsEnabled = false, isCentralizedLiveboardFilterUXEnabled = false, isLinkParametersEnabled, updatedSpotterChatPrompt, } = this.viewConfig;
19947
19988
  let params = {};
19948
19989
  params[Param.PrimaryNavHidden] = !showPrimaryNavbar;
19949
19990
  params[Param.HideProfleAndHelp] = !!disableProfileAndHelp;
@@ -19962,6 +20003,9 @@ mutation GetUnsavedAnswerTML($session: BachSessionIdInput!, $exportDependencies:
19962
20003
  params[Param.IsUnifiedSearchExperienceEnabled] = isUnifiedSearchExperienceEnabled;
19963
20004
  params[Param.CoverAndFilterOptionInPDF] = !!coverAndFilterOptionInPDF;
19964
20005
  params = this.getBaseQueryParams(params);
20006
+ if (!isUndefined$1(updatedSpotterChatPrompt)) {
20007
+ params[Param.UpdatedSpotterChatPrompt] = !!updatedSpotterChatPrompt;
20008
+ }
19965
20009
  if (hideObjectSearch) {
19966
20010
  params[Param.HideObjectSearch] = !!hideObjectSearch;
19967
20011
  }
@@ -20374,7 +20418,7 @@ query GetEurekaVizSnapshots(
20374
20418
  getEmbedParamsObject() {
20375
20419
  let params = {};
20376
20420
  params = this.getBaseQueryParams(params);
20377
- const { enableVizTransformations, fullHeight, defaultHeight, visibleVizs, liveboardV2, vizId, hideTabPanel, activeTabId, hideLiveboardHeader, showLiveboardDescription, showLiveboardTitle, isLiveboardHeaderSticky = true, isLiveboardCompactHeaderEnabled = false, showLiveboardVerifiedBadge = true, showLiveboardReverifyBanner = true, hideIrrelevantChipsInLiveboardTabs = false, isEnhancedFilterInteractivityEnabled = false, enableAskSage, enable2ColumnLayout, dataPanelV2 = true, enableCustomColumnGroups = false, oAuthPollingInterval, isForceRedirect, dataSourceId, coverAndFilterOptionInPDF = false, liveboardXLSXCSVDownload, isLiveboardStylingAndGroupingEnabled, isPNGInScheduledEmailsEnabled = false, showSpotterLimitations, isCentralizedLiveboardFilterUXEnabled = false, isLinkParametersEnabled, } = this.viewConfig;
20421
+ const { enableVizTransformations, fullHeight, defaultHeight, visibleVizs, liveboardV2, vizId, hideTabPanel, activeTabId, hideLiveboardHeader, showLiveboardDescription, showLiveboardTitle, isLiveboardHeaderSticky = true, isLiveboardCompactHeaderEnabled = false, showLiveboardVerifiedBadge = true, showLiveboardReverifyBanner = true, hideIrrelevantChipsInLiveboardTabs = false, isEnhancedFilterInteractivityEnabled = false, enableAskSage, enable2ColumnLayout, dataPanelV2 = true, enableCustomColumnGroups = false, oAuthPollingInterval, isForceRedirect, dataSourceId, coverAndFilterOptionInPDF = false, liveboardXLSXCSVDownload, isLiveboardStylingAndGroupingEnabled, isPNGInScheduledEmailsEnabled = false, showSpotterLimitations, isCentralizedLiveboardFilterUXEnabled = false, isLinkParametersEnabled, updatedSpotterChatPrompt, } = this.viewConfig;
20378
20422
  const preventLiveboardFilterRemoval = this.viewConfig.preventLiveboardFilterRemoval
20379
20423
  || this.viewConfig.preventPinboardFilterRemoval;
20380
20424
  if (fullHeight === true) {
@@ -20393,6 +20437,9 @@ query GetEurekaVizSnapshots(
20393
20437
  if (preventLiveboardFilterRemoval) {
20394
20438
  params[Param.preventLiveboardFilterRemoval] = true;
20395
20439
  }
20440
+ if (!isUndefined$1(updatedSpotterChatPrompt)) {
20441
+ params[Param.UpdatedSpotterChatPrompt] = !!updatedSpotterChatPrompt;
20442
+ }
20396
20443
  if (visibleVizs) {
20397
20444
  params[Param.visibleVizs] = visibleVizs;
20398
20445
  }
@@ -21183,7 +21230,7 @@ query SendMessage($params: Input_convassist_SendMessageRequest) {
21183
21230
  this.viewConfig = viewConfig;
21184
21231
  }
21185
21232
  getEmbedParamsObject() {
21186
- const { worksheetId, searchOptions, disableSourceSelection, hideSourceSelection, dataPanelV2, showSpotterLimitations, hideSampleQuestions, enablePastConversationsSidebar, runtimeFilters, excludeRuntimeFiltersfromURL, runtimeParameters, excludeRuntimeParametersfromURL, } = this.viewConfig;
21233
+ const { worksheetId, searchOptions, disableSourceSelection, hideSourceSelection, dataPanelV2, showSpotterLimitations, hideSampleQuestions, enablePastConversationsSidebar, runtimeFilters, excludeRuntimeFiltersfromURL, runtimeParameters, excludeRuntimeParametersfromURL, updatedSpotterChatPrompt, } = this.viewConfig;
21187
21234
  if (!worksheetId) {
21188
21235
  this.handleError(ERROR_MESSAGE.SPOTTER_EMBED_WORKSHEED_ID_NOT_FOUND);
21189
21236
  }
@@ -21204,6 +21251,9 @@ query SendMessage($params: Input_convassist_SendMessageRequest) {
21204
21251
  if (!isUndefined_1(hideSampleQuestions)) {
21205
21252
  queryParams[Param.HideSampleQuestions] = !!hideSampleQuestions;
21206
21253
  }
21254
+ if (!isUndefined_1(updatedSpotterChatPrompt)) {
21255
+ queryParams[Param.UpdatedSpotterChatPrompt] = !!updatedSpotterChatPrompt;
21256
+ }
21207
21257
  return queryParams;
21208
21258
  }
21209
21259
  getIframeSrc() {
@@ -1,4 +1,4 @@
1
- /* @thoughtspot/visual-embed-sdk version 1.43.1 */
1
+ /* @thoughtspot/visual-embed-sdk version 1.44.1 */
2
2
  'use client';
3
3
  function _mergeNamespaces(n, m) {
4
4
  m.forEach(function (e) {
@@ -3144,6 +3144,7 @@ var Param;
3144
3144
  Param["isCentralizedLiveboardFilterUXEnabled"] = "isCentralizedLiveboardFilterUXEnabled";
3145
3145
  Param["isLinkParametersEnabled"] = "isLinkParametersEnabled";
3146
3146
  Param["EnablePastConversationsSidebar"] = "enablePastConversationsSidebar";
3147
+ Param["UpdatedSpotterChatPrompt"] = "updatedSpotterChatPrompt";
3147
3148
  })(Param || (Param = {}));
3148
3149
  /**
3149
3150
  * ThoughtSpot application pages include actions and menu commands
@@ -4458,6 +4459,46 @@ var Action;
4458
4459
  * @version SDK: 1.43.0 | ThoughtSpot Cloud: 10.15.0.cl
4459
4460
  */
4460
4461
  Action["LiveboardStylePanel"] = "liveboardStylePanel";
4462
+ /**
4463
+ * The **Move to Group** menu action on a Liveboard.
4464
+ * Allows moving a visualization to a different group.
4465
+ * @example
4466
+ * ```js
4467
+ * disabledActions: [Action.MoveToGroup]
4468
+ * ```
4469
+ * @version SDK: 1.44.0 | ThoughtSpot Cloud: 26.2.0.cl
4470
+ */
4471
+ Action["MoveToGroup"] = "moveToGroup";
4472
+ /**
4473
+ * The **Move out of Group** menu action on a Liveboard.
4474
+ * Allows moving a visualization out of a group.
4475
+ * @example
4476
+ * ```js
4477
+ * disabledActions: [Action.MoveOutOfGroup]
4478
+ * ```
4479
+ * @version SDK: 1.44.0 | ThoughtSpot Cloud: 26.2.0.cl
4480
+ */
4481
+ Action["MoveOutOfGroup"] = "moveOutOfGroup";
4482
+ /**
4483
+ * The **Create Group** menu action on a Liveboard.
4484
+ * Allows creating a new group.
4485
+ * @example
4486
+ * ```js
4487
+ * disabledActions: [Action.CreateGroup]
4488
+ * ```
4489
+ * @version SDK: 1.44.0 | ThoughtSpot Cloud: 26.2.0.cl
4490
+ */
4491
+ Action["CreateGroup"] = "createGroup";
4492
+ /**
4493
+ * The **Ungroup Liveboard Group** menu action on a Liveboard.
4494
+ * Allows ungrouping a liveboard group.
4495
+ * @example
4496
+ * ```js
4497
+ * disabledActions: [Action.UngroupLiveboardGroup]
4498
+ * ```
4499
+ * @version SDK: 1.44.0 | ThoughtSpot Cloud: 26.2.0.cl
4500
+ */
4501
+ Action["UngroupLiveboardGroup"] = "ungroupLiveboardGroup";
4461
4502
  })(Action || (Action = {}));
4462
4503
  var PrefetchFeatures;
4463
4504
  (function (PrefetchFeatures) {
@@ -8355,7 +8396,7 @@ class AnswerService {
8355
8396
  async getTML() {
8356
8397
  const { object } = await this.executeQuery(getAnswerTML, {});
8357
8398
  const edoc = object[0].edoc;
8358
- const YAML = await import('./index-CpkMygsc.js');
8399
+ const YAML = await import('./index-BE9gGzRX.js');
8359
8400
  const parsedDoc = YAML.parse(edoc);
8360
8401
  return {
8361
8402
  answer: {
@@ -17226,6 +17267,76 @@ if (typeof Promise.withResolvers === 'undefined') {
17226
17267
  };
17227
17268
  }
17228
17269
 
17270
+ /**
17271
+ * Reloads the ThoughtSpot iframe.
17272
+ * @param iFrame
17273
+ */
17274
+ const reload = (iFrame) => {
17275
+ const src = iFrame.src;
17276
+ iFrame.src = '';
17277
+ setTimeout(() => {
17278
+ iFrame.src = src;
17279
+ }, 100);
17280
+ };
17281
+ /**
17282
+ * Post iframe message.
17283
+ * @param iFrame
17284
+ * @param message
17285
+ * @param message.type
17286
+ * @param message.data
17287
+ * @param thoughtSpotHost
17288
+ * @param channel
17289
+ */
17290
+ function postIframeMessage(iFrame, message, thoughtSpotHost, channel) {
17291
+ var _a;
17292
+ return (_a = iFrame.contentWindow) === null || _a === void 0 ? void 0 : _a.postMessage(message, thoughtSpotHost, [channel === null || channel === void 0 ? void 0 : channel.port2]);
17293
+ }
17294
+ const TRIGGER_TIMEOUT = 30000;
17295
+ /**
17296
+ *
17297
+ * @param iFrame
17298
+ * @param messageType
17299
+ * @param thoughtSpotHost
17300
+ * @param data
17301
+ */
17302
+ function processTrigger(iFrame, messageType, thoughtSpotHost, data) {
17303
+ return new Promise((res, rej) => {
17304
+ var _a;
17305
+ if (messageType === HostEvent.Reload) {
17306
+ reload(iFrame);
17307
+ return res(null);
17308
+ }
17309
+ if (messageType === HostEvent.Present) {
17310
+ const embedConfig = getEmbedConfig();
17311
+ const disableFullscreenPresentation = (_a = embedConfig === null || embedConfig === void 0 ? void 0 : embedConfig.disableFullscreenPresentation) !== null && _a !== void 0 ? _a : true;
17312
+ if (!disableFullscreenPresentation) {
17313
+ handlePresentEvent(iFrame);
17314
+ }
17315
+ else {
17316
+ logger$3.warn('Fullscreen presentation mode is disabled. Set disableFullscreenPresentation: false to enable this feature.');
17317
+ }
17318
+ }
17319
+ const channel = new MessageChannel();
17320
+ channel.port1.onmessage = ({ data: responseData }) => {
17321
+ var _a;
17322
+ channel.port1.close();
17323
+ const error = responseData.error || ((_a = responseData === null || responseData === void 0 ? void 0 : responseData.data) === null || _a === void 0 ? void 0 : _a.error);
17324
+ if (error) {
17325
+ rej(error);
17326
+ }
17327
+ else {
17328
+ res(responseData);
17329
+ }
17330
+ };
17331
+ // Close the messageChannel and resolve the promise if timeout.
17332
+ setTimeout(() => {
17333
+ channel.port1.close();
17334
+ res(new Error(ERROR_MESSAGE.TRIGGER_TIMED_OUT));
17335
+ }, TRIGGER_TIMEOUT);
17336
+ return postIframeMessage(iFrame, { type: messageType, data }, thoughtSpotHost, channel);
17337
+ });
17338
+ }
17339
+
17229
17340
  /* eslint-disable camelcase */
17230
17341
  /* eslint-disable import/no-mutable-exports */
17231
17342
  /**
@@ -17571,6 +17682,19 @@ const exportTML = async (data) => {
17571
17682
  .catch((error) => {
17572
17683
  throw error;
17573
17684
  });
17685
+ };
17686
+ /**
17687
+ * Reloads the ThoughtSpot iframe.
17688
+ * @param iFrame
17689
+ * @group Global methods
17690
+ * @version SDK: 1.43.1
17691
+ */
17692
+ const reloadIframe = (iFrame) => {
17693
+ if (!iFrame) {
17694
+ logger$3.warn('reloadIframe called with no iFrame element.');
17695
+ return;
17696
+ }
17697
+ reload(iFrame);
17574
17698
  };
17575
17699
 
17576
17700
  /**
@@ -17704,77 +17828,7 @@ function processEventData(type, eventData, thoughtSpotHost, containerEl) {
17704
17828
  return eventData;
17705
17829
  }
17706
17830
 
17707
- var name="@thoughtspot/visual-embed-sdk";var version$1="1.43.1";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":"^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":"^8.28.0","@typescript-eslint/parser":"^8.28.0",ajv:"^8.17.1",asciidoctor:"^2.2.1","babel-jest":"^26.6.3","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:"^26.6.3","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":"^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","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};
17708
-
17709
- /**
17710
- * Reloads the ThoughtSpot iframe.
17711
- * @param iFrame
17712
- */
17713
- const reload = (iFrame) => {
17714
- const src = iFrame.src;
17715
- iFrame.src = '';
17716
- setTimeout(() => {
17717
- iFrame.src = src;
17718
- }, 100);
17719
- };
17720
- /**
17721
- * Post iframe message.
17722
- * @param iFrame
17723
- * @param message
17724
- * @param message.type
17725
- * @param message.data
17726
- * @param thoughtSpotHost
17727
- * @param channel
17728
- */
17729
- function postIframeMessage(iFrame, message, thoughtSpotHost, channel) {
17730
- var _a;
17731
- return (_a = iFrame.contentWindow) === null || _a === void 0 ? void 0 : _a.postMessage(message, thoughtSpotHost, [channel === null || channel === void 0 ? void 0 : channel.port2]);
17732
- }
17733
- const TRIGGER_TIMEOUT = 30000;
17734
- /**
17735
- *
17736
- * @param iFrame
17737
- * @param messageType
17738
- * @param thoughtSpotHost
17739
- * @param data
17740
- */
17741
- function processTrigger(iFrame, messageType, thoughtSpotHost, data) {
17742
- return new Promise((res, rej) => {
17743
- var _a;
17744
- if (messageType === HostEvent.Reload) {
17745
- reload(iFrame);
17746
- return res(null);
17747
- }
17748
- if (messageType === HostEvent.Present) {
17749
- const embedConfig = getEmbedConfig();
17750
- const disableFullscreenPresentation = (_a = embedConfig === null || embedConfig === void 0 ? void 0 : embedConfig.disableFullscreenPresentation) !== null && _a !== void 0 ? _a : true;
17751
- if (!disableFullscreenPresentation) {
17752
- handlePresentEvent(iFrame);
17753
- }
17754
- else {
17755
- logger$3.warn('Fullscreen presentation mode is disabled. Set disableFullscreenPresentation: false to enable this feature.');
17756
- }
17757
- }
17758
- const channel = new MessageChannel();
17759
- channel.port1.onmessage = ({ data: responseData }) => {
17760
- var _a;
17761
- channel.port1.close();
17762
- const error = responseData.error || ((_a = responseData === null || responseData === void 0 ? void 0 : responseData.data) === null || _a === void 0 ? void 0 : _a.error);
17763
- if (error) {
17764
- rej(error);
17765
- }
17766
- else {
17767
- res(responseData);
17768
- }
17769
- };
17770
- // Close the messageChannel and resolve the promise if timeout.
17771
- setTimeout(() => {
17772
- channel.port1.close();
17773
- res(new Error(ERROR_MESSAGE.TRIGGER_TIMED_OUT));
17774
- }, TRIGGER_TIMEOUT);
17775
- return postIframeMessage(iFrame, { type: messageType, data }, thoughtSpotHost, channel);
17776
- });
17777
- }
17831
+ var name="@thoughtspot/visual-embed-sdk";var version$1="1.44.1";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":"^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":"^8.28.0","@typescript-eslint/parser":"^8.28.0",ajv:"^8.17.1",asciidoctor:"^2.2.1","babel-jest":"^26.6.3","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:"^26.6.3","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":"^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","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};
17778
17832
 
17779
17833
  class HostEventClient {
17780
17834
  constructor(iFrame) {
@@ -19640,7 +19694,7 @@ class AppEmbed extends V1Embed {
19640
19694
  * embedded Liveboard or visualization.
19641
19695
  */
19642
19696
  getEmbedParams() {
19643
- const { tag, hideTagFilterChips, hideObjects, liveboardV2, showPrimaryNavbar, disableProfileAndHelp, hideHamburger, hideObjectSearch, hideNotification, hideApplicationSwitcher, hideOrgSwitcher, enableSearchAssist, fullHeight, dataPanelV2 = true, hideLiveboardHeader = false, showLiveboardTitle = true, showLiveboardDescription = true, 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, liveboardXLSXCSVDownload, isLiveboardStylingAndGroupingEnabled, isPNGInScheduledEmailsEnabled = false, isCentralizedLiveboardFilterUXEnabled = false, isLinkParametersEnabled, } = this.viewConfig;
19697
+ const { tag, hideTagFilterChips, hideObjects, liveboardV2, showPrimaryNavbar, disableProfileAndHelp, hideHamburger, hideObjectSearch, hideNotification, hideApplicationSwitcher, hideOrgSwitcher, enableSearchAssist, fullHeight, dataPanelV2 = true, hideLiveboardHeader = false, showLiveboardTitle = true, showLiveboardDescription = true, 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, liveboardXLSXCSVDownload, isLiveboardStylingAndGroupingEnabled, isPNGInScheduledEmailsEnabled = false, isCentralizedLiveboardFilterUXEnabled = false, isLinkParametersEnabled, updatedSpotterChatPrompt, } = this.viewConfig;
19644
19698
  let params = {};
19645
19699
  params[Param.PrimaryNavHidden] = !showPrimaryNavbar;
19646
19700
  params[Param.HideProfleAndHelp] = !!disableProfileAndHelp;
@@ -19659,6 +19713,9 @@ class AppEmbed extends V1Embed {
19659
19713
  params[Param.IsUnifiedSearchExperienceEnabled] = isUnifiedSearchExperienceEnabled;
19660
19714
  params[Param.CoverAndFilterOptionInPDF] = !!coverAndFilterOptionInPDF;
19661
19715
  params = this.getBaseQueryParams(params);
19716
+ if (!isUndefined$1(updatedSpotterChatPrompt)) {
19717
+ params[Param.UpdatedSpotterChatPrompt] = !!updatedSpotterChatPrompt;
19718
+ }
19662
19719
  if (hideObjectSearch) {
19663
19720
  params[Param.HideObjectSearch] = !!hideObjectSearch;
19664
19721
  }
@@ -20071,7 +20128,7 @@ class LiveboardEmbed extends V1Embed {
20071
20128
  getEmbedParamsObject() {
20072
20129
  let params = {};
20073
20130
  params = this.getBaseQueryParams(params);
20074
- const { enableVizTransformations, fullHeight, defaultHeight, visibleVizs, liveboardV2, vizId, hideTabPanel, activeTabId, hideLiveboardHeader, showLiveboardDescription, showLiveboardTitle, isLiveboardHeaderSticky = true, isLiveboardCompactHeaderEnabled = false, showLiveboardVerifiedBadge = true, showLiveboardReverifyBanner = true, hideIrrelevantChipsInLiveboardTabs = false, isEnhancedFilterInteractivityEnabled = false, enableAskSage, enable2ColumnLayout, dataPanelV2 = true, enableCustomColumnGroups = false, oAuthPollingInterval, isForceRedirect, dataSourceId, coverAndFilterOptionInPDF = false, liveboardXLSXCSVDownload, isLiveboardStylingAndGroupingEnabled, isPNGInScheduledEmailsEnabled = false, showSpotterLimitations, isCentralizedLiveboardFilterUXEnabled = false, isLinkParametersEnabled, } = this.viewConfig;
20131
+ const { enableVizTransformations, fullHeight, defaultHeight, visibleVizs, liveboardV2, vizId, hideTabPanel, activeTabId, hideLiveboardHeader, showLiveboardDescription, showLiveboardTitle, isLiveboardHeaderSticky = true, isLiveboardCompactHeaderEnabled = false, showLiveboardVerifiedBadge = true, showLiveboardReverifyBanner = true, hideIrrelevantChipsInLiveboardTabs = false, isEnhancedFilterInteractivityEnabled = false, enableAskSage, enable2ColumnLayout, dataPanelV2 = true, enableCustomColumnGroups = false, oAuthPollingInterval, isForceRedirect, dataSourceId, coverAndFilterOptionInPDF = false, liveboardXLSXCSVDownload, isLiveboardStylingAndGroupingEnabled, isPNGInScheduledEmailsEnabled = false, showSpotterLimitations, isCentralizedLiveboardFilterUXEnabled = false, isLinkParametersEnabled, updatedSpotterChatPrompt, } = this.viewConfig;
20075
20132
  const preventLiveboardFilterRemoval = this.viewConfig.preventLiveboardFilterRemoval
20076
20133
  || this.viewConfig.preventPinboardFilterRemoval;
20077
20134
  if (fullHeight === true) {
@@ -20090,6 +20147,9 @@ class LiveboardEmbed extends V1Embed {
20090
20147
  if (preventLiveboardFilterRemoval) {
20091
20148
  params[Param.preventLiveboardFilterRemoval] = true;
20092
20149
  }
20150
+ if (!isUndefined$1(updatedSpotterChatPrompt)) {
20151
+ params[Param.UpdatedSpotterChatPrompt] = !!updatedSpotterChatPrompt;
20152
+ }
20093
20153
  if (visibleVizs) {
20094
20154
  params[Param.visibleVizs] = visibleVizs;
20095
20155
  }
@@ -21140,7 +21200,7 @@ class SpotterEmbed extends TsEmbed {
21140
21200
  this.viewConfig = viewConfig;
21141
21201
  }
21142
21202
  getEmbedParamsObject() {
21143
- const { worksheetId, searchOptions, disableSourceSelection, hideSourceSelection, dataPanelV2, showSpotterLimitations, hideSampleQuestions, enablePastConversationsSidebar, runtimeFilters, excludeRuntimeFiltersfromURL, runtimeParameters, excludeRuntimeParametersfromURL, } = this.viewConfig;
21203
+ const { worksheetId, searchOptions, disableSourceSelection, hideSourceSelection, dataPanelV2, showSpotterLimitations, hideSampleQuestions, enablePastConversationsSidebar, runtimeFilters, excludeRuntimeFiltersfromURL, runtimeParameters, excludeRuntimeParametersfromURL, updatedSpotterChatPrompt, } = this.viewConfig;
21144
21204
  if (!worksheetId) {
21145
21205
  this.handleError(ERROR_MESSAGE.SPOTTER_EMBED_WORKSHEED_ID_NOT_FOUND);
21146
21206
  }
@@ -21161,6 +21221,9 @@ class SpotterEmbed extends TsEmbed {
21161
21221
  if (!isUndefined_1(hideSampleQuestions)) {
21162
21222
  queryParams[Param.HideSampleQuestions] = !!hideSampleQuestions;
21163
21223
  }
21224
+ if (!isUndefined_1(updatedSpotterChatPrompt)) {
21225
+ queryParams[Param.UpdatedSpotterChatPrompt] = !!updatedSpotterChatPrompt;
21226
+ }
21164
21227
  return queryParams;
21165
21228
  }
21166
21229
  getIframeSrc() {
@@ -21825,4 +21888,4 @@ const createLiveboardWithAnswers = async (answers, name) => {
21825
21888
  return result;
21826
21889
  };
21827
21890
 
21828
- export { Action, AnswerService, AppEmbed, AuthEvent, AuthFailureType, AuthStatus, AuthType, BodylessConversation, ContextMenuTriggerOptions, ConversationEmbed, CustomActionTarget, CustomActionsPosition, DataPanelCustomColumnGroupsAccordionState$1 as DataPanelCustomColumnGroupsAccordionState, DataSourceVisualMode, EmbedEvent, HomeLeftNavItem, HomePage, HomePageSearchBarMode, HomepageModule, HostEvent, InterceptedApiType, ListPage, ListPageColumns, LiveboardEmbed, LogLevel, MIXPANEL_EVENT, Page, PinboardEmbed, PrefetchFeatures, PrimaryNavbarVersion, RuntimeFilterOp, SageEmbed, SearchBarEmbed, SearchEmbed, SpotterAgentEmbed, SpotterEmbed, UIPassthroughEvent, createLiveboardWithAnswers, executeTML, exportTML, getAnswerFromQuery, getEmbedConfig as getInitConfig, getSessionInfo, init, logout, prefetch, resetCachedAuthToken, tokenizedFetch, uploadMixpanelEvent };
21891
+ export { Action, AnswerService, AppEmbed, AuthEvent, AuthFailureType, AuthStatus, AuthType, BodylessConversation, ContextMenuTriggerOptions, ConversationEmbed, CustomActionTarget, CustomActionsPosition, DataPanelCustomColumnGroupsAccordionState$1 as DataPanelCustomColumnGroupsAccordionState, DataSourceVisualMode, EmbedEvent, HomeLeftNavItem, HomePage, HomePageSearchBarMode, HomepageModule, HostEvent, InterceptedApiType, ListPage, ListPageColumns, LiveboardEmbed, LogLevel, MIXPANEL_EVENT, Page, PinboardEmbed, PrefetchFeatures, PrimaryNavbarVersion, RuntimeFilterOp, SageEmbed, SearchBarEmbed, SearchEmbed, SpotterAgentEmbed, SpotterEmbed, UIPassthroughEvent, createLiveboardWithAnswers, executeTML, exportTML, getAnswerFromQuery, getEmbedConfig as getInitConfig, getSessionInfo, init, logout, prefetch, reloadIframe, resetCachedAuthToken, tokenizedFetch, uploadMixpanelEvent };