@thoughtspot/visual-embed-sdk 1.47.3 → 1.49.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (244) hide show
  1. package/cjs/package.json +1 -1
  2. package/cjs/src/auth.d.ts.map +1 -1
  3. package/cjs/src/auth.js +11 -1
  4. package/cjs/src/auth.js.map +1 -1
  5. package/cjs/src/auth.spec.js +38 -0
  6. package/cjs/src/auth.spec.js.map +1 -1
  7. package/cjs/src/authToken.d.ts +2 -0
  8. package/cjs/src/authToken.d.ts.map +1 -1
  9. package/cjs/src/authToken.js +7 -5
  10. package/cjs/src/authToken.js.map +1 -1
  11. package/cjs/src/css-variables.d.ts +140 -0
  12. package/cjs/src/css-variables.d.ts.map +1 -1
  13. package/cjs/src/embed/app.d.ts +63 -2
  14. package/cjs/src/embed/app.d.ts.map +1 -1
  15. package/cjs/src/embed/app.js +57 -6
  16. package/cjs/src/embed/app.js.map +1 -1
  17. package/cjs/src/embed/app.spec.js +200 -1
  18. package/cjs/src/embed/app.spec.js.map +1 -1
  19. package/cjs/src/embed/auto-frame-renderer.js +7 -2
  20. package/cjs/src/embed/auto-frame-renderer.js.map +1 -1
  21. package/cjs/src/embed/auto-frame-renderer.spec.js +385 -6
  22. package/cjs/src/embed/auto-frame-renderer.spec.js.map +1 -1
  23. package/cjs/src/embed/base.d.ts +1 -0
  24. package/cjs/src/embed/base.d.ts.map +1 -1
  25. package/cjs/src/embed/base.js +13 -1
  26. package/cjs/src/embed/base.js.map +1 -1
  27. package/cjs/src/embed/base.spec.js +21 -0
  28. package/cjs/src/embed/base.spec.js.map +1 -1
  29. package/cjs/src/embed/bodyless-conversation.spec.js +86 -0
  30. package/cjs/src/embed/bodyless-conversation.spec.js.map +1 -1
  31. package/cjs/src/embed/conversation.d.ts +16 -1
  32. package/cjs/src/embed/conversation.d.ts.map +1 -1
  33. package/cjs/src/embed/conversation.js +5 -1
  34. package/cjs/src/embed/conversation.js.map +1 -1
  35. package/cjs/src/embed/conversation.spec.js +26 -0
  36. package/cjs/src/embed/conversation.spec.js.map +1 -1
  37. package/cjs/src/embed/liveboard.d.ts +48 -2
  38. package/cjs/src/embed/liveboard.d.ts.map +1 -1
  39. package/cjs/src/embed/liveboard.js +48 -7
  40. package/cjs/src/embed/liveboard.js.map +1 -1
  41. package/cjs/src/embed/liveboard.spec.js +139 -1
  42. package/cjs/src/embed/liveboard.spec.js.map +1 -1
  43. package/cjs/src/embed/spotter-viz-utils.d.ts +85 -0
  44. package/cjs/src/embed/spotter-viz-utils.d.ts.map +1 -0
  45. package/cjs/src/embed/spotter-viz-utils.js +17 -0
  46. package/cjs/src/embed/spotter-viz-utils.js.map +1 -0
  47. package/cjs/src/embed/spotter-viz-utils.spec.d.ts +2 -0
  48. package/cjs/src/embed/spotter-viz-utils.spec.d.ts.map +1 -0
  49. package/cjs/src/embed/spotter-viz-utils.spec.js +31 -0
  50. package/cjs/src/embed/spotter-viz-utils.spec.js.map +1 -0
  51. package/cjs/src/embed/ts-embed.d.ts +58 -38
  52. package/cjs/src/embed/ts-embed.d.ts.map +1 -1
  53. package/cjs/src/embed/ts-embed.js +247 -151
  54. package/cjs/src/embed/ts-embed.js.map +1 -1
  55. package/cjs/src/embed/ts-embed.spec.js +397 -122
  56. package/cjs/src/embed/ts-embed.spec.js.map +1 -1
  57. package/cjs/src/index.d.ts +2 -1
  58. package/cjs/src/index.d.ts.map +1 -1
  59. package/cjs/src/index.js.map +1 -1
  60. package/cjs/src/react/index.d.ts.map +1 -1
  61. package/cjs/src/react/index.js +3 -0
  62. package/cjs/src/react/index.js.map +1 -1
  63. package/cjs/src/tokenizedFetch.d.ts.map +1 -1
  64. package/cjs/src/tokenizedFetch.js +12 -9
  65. package/cjs/src/tokenizedFetch.js.map +1 -1
  66. package/cjs/src/tokenizedFetch.spec.d.ts +2 -0
  67. package/cjs/src/tokenizedFetch.spec.d.ts.map +1 -0
  68. package/cjs/src/tokenizedFetch.spec.js +68 -0
  69. package/cjs/src/tokenizedFetch.spec.js.map +1 -0
  70. package/cjs/src/types.d.ts +309 -40
  71. package/cjs/src/types.d.ts.map +1 -1
  72. package/cjs/src/types.js +251 -23
  73. package/cjs/src/types.js.map +1 -1
  74. package/cjs/src/utils/authService/tokenizedAuthService.spec.js +6 -7
  75. package/cjs/src/utils/authService/tokenizedAuthService.spec.js.map +1 -1
  76. package/cjs/src/utils/logger.js +2 -1
  77. package/cjs/src/utils/logger.js.map +1 -1
  78. package/cjs/src/utils/logger.spec.d.ts +1 -0
  79. package/cjs/src/utils/logger.spec.d.ts.map +1 -1
  80. package/cjs/src/utils/logger.spec.js +10 -9
  81. package/cjs/src/utils/logger.spec.js.map +1 -1
  82. package/cjs/src/utils.d.ts +4 -1
  83. package/cjs/src/utils.d.ts.map +1 -1
  84. package/cjs/src/utils.js +107 -10
  85. package/cjs/src/utils.js.map +1 -1
  86. package/cjs/src/utils.spec.js +163 -4
  87. package/cjs/src/utils.spec.js.map +1 -1
  88. package/dist/{index-DZq20cR6.js → index-_UGCSSDR.js} +1 -1
  89. package/dist/src/auth.d.ts.map +1 -1
  90. package/dist/src/authToken.d.ts +2 -0
  91. package/dist/src/authToken.d.ts.map +1 -1
  92. package/dist/src/css-variables.d.ts +140 -0
  93. package/dist/src/css-variables.d.ts.map +1 -1
  94. package/dist/src/embed/app.d.ts +63 -2
  95. package/dist/src/embed/app.d.ts.map +1 -1
  96. package/dist/src/embed/base.d.ts +1 -0
  97. package/dist/src/embed/base.d.ts.map +1 -1
  98. package/dist/src/embed/conversation.d.ts +16 -1
  99. package/dist/src/embed/conversation.d.ts.map +1 -1
  100. package/dist/src/embed/liveboard.d.ts +48 -2
  101. package/dist/src/embed/liveboard.d.ts.map +1 -1
  102. package/dist/src/embed/spotter-viz-utils.d.ts +85 -0
  103. package/dist/src/embed/spotter-viz-utils.d.ts.map +1 -0
  104. package/dist/src/embed/spotter-viz-utils.spec.d.ts +2 -0
  105. package/dist/src/embed/spotter-viz-utils.spec.d.ts.map +1 -0
  106. package/dist/src/embed/ts-embed.d.ts +58 -38
  107. package/dist/src/embed/ts-embed.d.ts.map +1 -1
  108. package/dist/src/index.d.ts +2 -1
  109. package/dist/src/index.d.ts.map +1 -1
  110. package/dist/src/react/index.d.ts.map +1 -1
  111. package/dist/src/tokenizedFetch.d.ts.map +1 -1
  112. package/dist/src/tokenizedFetch.spec.d.ts +2 -0
  113. package/dist/src/tokenizedFetch.spec.d.ts.map +1 -0
  114. package/dist/src/types.d.ts +309 -40
  115. package/dist/src/types.d.ts.map +1 -1
  116. package/dist/src/utils/logger.spec.d.ts +1 -0
  117. package/dist/src/utils/logger.spec.d.ts.map +1 -1
  118. package/dist/src/utils.d.ts +4 -1
  119. package/dist/src/utils.d.ts.map +1 -1
  120. package/dist/tsembed-react.es.js +3418 -2899
  121. package/dist/tsembed-react.js +3420 -2901
  122. package/dist/tsembed.es.js +3426 -2905
  123. package/dist/tsembed.js +3419 -2898
  124. package/dist/visual-embed-sdk-react-full.d.ts +687 -78
  125. package/dist/visual-embed-sdk-react.d.ts +687 -78
  126. package/dist/visual-embed-sdk.d.ts +702 -80
  127. package/lib/package.json +1 -1
  128. package/lib/src/auth.d.ts.map +1 -1
  129. package/lib/src/auth.js +12 -2
  130. package/lib/src/auth.js.map +1 -1
  131. package/lib/src/auth.spec.js +38 -0
  132. package/lib/src/auth.spec.js.map +1 -1
  133. package/lib/src/authToken.d.ts +2 -0
  134. package/lib/src/authToken.d.ts.map +1 -1
  135. package/lib/src/authToken.js +2 -2
  136. package/lib/src/authToken.js.map +1 -1
  137. package/lib/src/css-variables.d.ts +140 -0
  138. package/lib/src/css-variables.d.ts.map +1 -1
  139. package/lib/src/embed/app.d.ts +63 -2
  140. package/lib/src/embed/app.d.ts.map +1 -1
  141. package/lib/src/embed/app.js +58 -7
  142. package/lib/src/embed/app.js.map +1 -1
  143. package/lib/src/embed/app.spec.js +201 -2
  144. package/lib/src/embed/app.spec.js.map +1 -1
  145. package/lib/src/embed/auto-frame-renderer.js +7 -2
  146. package/lib/src/embed/auto-frame-renderer.js.map +1 -1
  147. package/lib/src/embed/auto-frame-renderer.spec.js +387 -8
  148. package/lib/src/embed/auto-frame-renderer.spec.js.map +1 -1
  149. package/lib/src/embed/base.d.ts +1 -0
  150. package/lib/src/embed/base.d.ts.map +1 -1
  151. package/lib/src/embed/base.js +11 -0
  152. package/lib/src/embed/base.js.map +1 -1
  153. package/lib/src/embed/base.spec.js +22 -1
  154. package/lib/src/embed/base.spec.js.map +1 -1
  155. package/lib/src/embed/bodyless-conversation.spec.js +86 -0
  156. package/lib/src/embed/bodyless-conversation.spec.js.map +1 -1
  157. package/lib/src/embed/conversation.d.ts +16 -1
  158. package/lib/src/embed/conversation.d.ts.map +1 -1
  159. package/lib/src/embed/conversation.js +5 -1
  160. package/lib/src/embed/conversation.js.map +1 -1
  161. package/lib/src/embed/conversation.spec.js +27 -1
  162. package/lib/src/embed/conversation.spec.js.map +1 -1
  163. package/lib/src/embed/liveboard.d.ts +48 -2
  164. package/lib/src/embed/liveboard.d.ts.map +1 -1
  165. package/lib/src/embed/liveboard.js +49 -8
  166. package/lib/src/embed/liveboard.js.map +1 -1
  167. package/lib/src/embed/liveboard.spec.js +139 -1
  168. package/lib/src/embed/liveboard.spec.js.map +1 -1
  169. package/lib/src/embed/spotter-viz-utils.d.ts +85 -0
  170. package/lib/src/embed/spotter-viz-utils.d.ts.map +1 -0
  171. package/lib/src/embed/spotter-viz-utils.js +13 -0
  172. package/lib/src/embed/spotter-viz-utils.js.map +1 -0
  173. package/lib/src/embed/spotter-viz-utils.spec.d.ts +2 -0
  174. package/lib/src/embed/spotter-viz-utils.spec.d.ts.map +1 -0
  175. package/lib/src/embed/spotter-viz-utils.spec.js +29 -0
  176. package/lib/src/embed/spotter-viz-utils.spec.js.map +1 -0
  177. package/lib/src/embed/ts-embed.d.ts +58 -38
  178. package/lib/src/embed/ts-embed.d.ts.map +1 -1
  179. package/lib/src/embed/ts-embed.js +250 -154
  180. package/lib/src/embed/ts-embed.js.map +1 -1
  181. package/lib/src/embed/ts-embed.spec.js +397 -122
  182. package/lib/src/embed/ts-embed.spec.js.map +1 -1
  183. package/lib/src/index.d.ts +2 -1
  184. package/lib/src/index.d.ts.map +1 -1
  185. package/lib/src/index.js.map +1 -1
  186. package/lib/src/react/index.d.ts.map +1 -1
  187. package/lib/src/react/index.js +3 -0
  188. package/lib/src/react/index.js.map +1 -1
  189. package/lib/src/tokenizedFetch.d.ts.map +1 -1
  190. package/lib/src/tokenizedFetch.js +13 -10
  191. package/lib/src/tokenizedFetch.js.map +1 -1
  192. package/lib/src/tokenizedFetch.spec.d.ts +2 -0
  193. package/lib/src/tokenizedFetch.spec.d.ts.map +1 -0
  194. package/lib/src/tokenizedFetch.spec.js +65 -0
  195. package/lib/src/tokenizedFetch.spec.js.map +1 -0
  196. package/lib/src/types.d.ts +309 -40
  197. package/lib/src/types.d.ts.map +1 -1
  198. package/lib/src/types.js +251 -23
  199. package/lib/src/types.js.map +1 -1
  200. package/lib/src/utils/authService/tokenizedAuthService.spec.js +6 -7
  201. package/lib/src/utils/authService/tokenizedAuthService.spec.js.map +1 -1
  202. package/lib/src/utils/logger.js +2 -1
  203. package/lib/src/utils/logger.js.map +1 -1
  204. package/lib/src/utils/logger.spec.d.ts +1 -0
  205. package/lib/src/utils/logger.spec.d.ts.map +1 -1
  206. package/lib/src/utils/logger.spec.js +10 -9
  207. package/lib/src/utils/logger.spec.js.map +1 -1
  208. package/lib/src/utils.d.ts +4 -1
  209. package/lib/src/utils.d.ts.map +1 -1
  210. package/lib/src/utils.js +103 -9
  211. package/lib/src/utils.js.map +1 -1
  212. package/lib/src/utils.spec.js +164 -5
  213. package/lib/src/utils.spec.js.map +1 -1
  214. package/lib/src/visual-embed-sdk.d.ts +702 -80
  215. package/package.json +1 -1
  216. package/src/auth.spec.ts +55 -1
  217. package/src/auth.ts +11 -2
  218. package/src/authToken.ts +2 -2
  219. package/src/css-variables.ts +175 -1
  220. package/src/embed/app.spec.ts +260 -3
  221. package/src/embed/app.ts +127 -7
  222. package/src/embed/auto-frame-renderer.spec.ts +457 -58
  223. package/src/embed/auto-frame-renderer.ts +7 -2
  224. package/src/embed/base.spec.ts +25 -1
  225. package/src/embed/base.ts +19 -5
  226. package/src/embed/bodyless-conversation.spec.ts +93 -0
  227. package/src/embed/conversation.spec.ts +34 -0
  228. package/src/embed/conversation.ts +22 -1
  229. package/src/embed/liveboard.spec.ts +163 -1
  230. package/src/embed/liveboard.ts +106 -10
  231. package/src/embed/spotter-viz-utils.spec.ts +30 -0
  232. package/src/embed/spotter-viz-utils.ts +94 -0
  233. package/src/embed/ts-embed.spec.ts +564 -231
  234. package/src/embed/ts-embed.ts +384 -258
  235. package/src/index.ts +3 -0
  236. package/src/react/index.tsx +3 -0
  237. package/src/tokenizedFetch.spec.ts +81 -0
  238. package/src/tokenizedFetch.ts +14 -11
  239. package/src/types.ts +326 -36
  240. package/src/utils/authService/tokenizedAuthService.spec.ts +6 -6
  241. package/src/utils/logger.spec.ts +11 -9
  242. package/src/utils/logger.ts +2 -2
  243. package/src/utils.spec.ts +200 -4
  244. package/src/utils.ts +128 -9
@@ -821,6 +821,146 @@ export interface CustomCssVariables {
821
821
  * Background color of the color palette in the Liveboard styling panel.
822
822
  */
823
823
  "--ts-var-liveboard-styling-color-palette-background"?: string;
824
+ /**
825
+ * Main panel background of the SpotterViz.
826
+ */
827
+ "--ts-var-spotterviz-panel-background"?: string;
828
+ /**
829
+ * Background color of the chat input field in SpotterViz.
830
+ */
831
+ "--ts-var-spotterviz-input-background"?: string;
832
+ /**
833
+ * Placeholder text color of the chat input field in SpotterViz.
834
+ */
835
+ "--ts-var-spotterviz-input-placeholder-color"?: string;
836
+ /**
837
+ * CTA color of the chat input field in SpotterViz.
838
+ */
839
+ "--ts-var-spotterviz-input-cta-color"?: string;
840
+ /**
841
+ * CTA hover color of the chat input field in SpotterViz.
842
+ */
843
+ "--ts-var-spotterviz-input-cta-hover-color"?: string;
844
+ /**
845
+ * Text color for the SpotterViz label in the empty state, displayed below
846
+ * the SpotterViz icon.
847
+ */
848
+ "--ts-var-spotterviz-emptystate-spotterviz-color"?: string;
849
+ /**
850
+ * Background color of the starter prompt cards in SpotterViz.
851
+ */
852
+ "--ts-var-spotterviz-prompt-card-background"?: string;
853
+ /**
854
+ * Background hover color of the starter prompt cards in SpotterViz.
855
+ */
856
+ "--ts-var-spotterviz-prompt-card-hover-background"?: string;
857
+ /**
858
+ * Primary text color in SpotterViz, also used for tool response text,
859
+ * upvote/downvote buttons, and other primary content.
860
+ */
861
+ "--ts-var-spotterviz-text-primary"?: string;
862
+ /**
863
+ * Secondary text color in SpotterViz.
864
+ */
865
+ "--ts-var-spotterviz-text-secondary"?: string;
866
+ /**
867
+ * Background color of the user chat message bubble in SpotterViz.
868
+ */
869
+ "--ts-var-spotterviz-message-background"?: string;
870
+ /**
871
+ * Hover color for the user chat message expand button in SpotterViz.
872
+ */
873
+ "--ts-var-spotterviz-usermessage-icon-hover"?: string;
874
+ /**
875
+ * Background color of the user chat message expand button in SpotterViz.
876
+ */
877
+ "--ts-var-spotterviz-usermessage-icon-background"?: string;
878
+ /**
879
+ * Color of the thinking step header when in progress in SpotterViz.
880
+ */
881
+ "--ts-var-spotterviz-thinking-inprogress-header-color"?: string;
882
+ /**
883
+ * Color of the thinking step header when completed in SpotterViz.
884
+ */
885
+ "--ts-var-spotterviz-thinking-completed-header-color"?: string;
886
+ /**
887
+ * Color of the final completion indicator icon shown when all work is done.
888
+ * The last green dot which is shown when work is done.
889
+ */
890
+ "--ts-var-spotterviz-thinking-work-done-icon-color"?: string;
891
+ /**
892
+ * Hover background color for the working/work done CTA in SpotterViz.
893
+ */
894
+ "--ts-var-spotterviz-thinking-cta-hover-background"?: string;
895
+ /**
896
+ * Background color of tool call panels in SpotterViz.
897
+ */
898
+ "--ts-var-spotterviz-tool-call-background"?: string;
899
+ /**
900
+ * Color of tool titles and icons in SpotterViz.
901
+ */
902
+ "--ts-var-spotterviz-tool-title-color"?: string;
903
+ /**
904
+ * Border color of tool call panels in SpotterViz.
905
+ */
906
+ "--ts-var-spotterviz-tool-border-color"?: string;
907
+ /**
908
+ * Background color of the JSON input panel inside a tool call in SpotterViz.
909
+ */
910
+ "--ts-var-spotterviz-tool-json-input-background"?: string;
911
+ /**
912
+ * Background color of the upvote/downvote feedback buttons in SpotterViz.
913
+ */
914
+ "--ts-var-spotterviz-tool-feedback-button-background"?: string;
915
+ /**
916
+ * Hover background color of the upvote/downvote feedback buttons in SpotterViz.
917
+ */
918
+ "--ts-var-spotterviz-tool-feedback-button-hover"?: string;
919
+ /**
920
+ * Text color of the JSON input panel inside a tool call in SpotterViz.
921
+ */
922
+ "--ts-var-spotterviz-tool-json-input-color"?: string;
923
+ /**
924
+ * Background color of the last checkpoint section in SpotterViz.
925
+ */
926
+ "--ts-var-spotterviz-last-checkpoint-background"?: string;
927
+ /**
928
+ * Border color of the last checkpoint section in SpotterViz.
929
+ */
930
+ "--ts-var-spotterviz-last-checkpoint-border"?: string;
931
+ /**
932
+ * Border color of the Liveboard edit header toolbar.
933
+ */
934
+ "--ts-var-liveboard-edit-toolbar-border"?: string;
935
+ /**
936
+ * Background color of the selected section in the Liveboard edit header toolbar.
937
+ */
938
+ "--ts-var-liveboard-edit-toolbar-selected-background"?: string;
939
+ /**
940
+ * Text color of the selected section in the Liveboard edit header toolbar.
941
+ */
942
+ "--ts-var-liveboard-edit-toolbar-selected-text-color"?: string;
943
+ /**
944
+ * Text color of unselected items in the Liveboard edit header toolbar.
945
+ */
946
+ "--ts-var-liveboard-edit-toolbar-text"?: string;
947
+ /**
948
+ * Hover background color of unselected items in the Liveboard edit header toolbar.
949
+ */
950
+ "--ts-var-liveboard-edit-toolbar-hover-background"?: string;
951
+ /**
952
+ * Hover text color of unselected items in the Liveboard edit header toolbar.
953
+ */
954
+ "--ts-var-liveboard-edit-toolbar-hover-text-color"?: string;
955
+ /**
956
+ * Text color of the SpotterViz footer.
957
+ */
958
+ "--ts-var-spotterviz-footer-text-color"?: string;
959
+ /**
960
+ * Shared border color used throughout SpotterViz: input box, user message,
961
+ * header underline, left panel border, thinking step connector and dots.
962
+ */
963
+ "--ts-var-spotterviz-border-color"?: string;
824
964
  }
825
965
  export interface SessionInterface {
826
966
  sessionId: string;
@@ -1847,9 +1987,10 @@ export interface BaseViewConfig extends ApiInterceptFlags {
1847
1987
  styleSheet__unstable?: string;
1848
1988
  /**
1849
1989
  * The list of actions to disable from the primary menu, more menu
1850
- * (...), and the contextual menu. These actions will be disabled
1851
- * for the user.
1852
- * Use this to disable actions.
1990
+ * (...), and the contextual menu. Disabled actions are grayed out
1991
+ * and still visible to the user, but cannot be clicked.
1992
+ * Use this when you want to disable an action (keep it visible but non-interactive).
1993
+ * To completely remove an action from the UI, use {@link hiddenActions} instead.
1853
1994
  *
1854
1995
  * Supported embed types: `AppEmbed`, `LiveboardEmbed`, `SearchEmbed`, `SpotterAgentEmbed`, `SpotterEmbed`, `SearchBarEmbed`
1855
1996
  * @version SDK: 1.6.0 | ThoughtSpot: ts8.nov.cl, 8.4.1.sw
@@ -1880,9 +2021,10 @@ export interface BaseViewConfig extends ApiInterceptFlags {
1880
2021
  */
1881
2022
  disabledActionReason?: string;
1882
2023
  /**
1883
- * The list of actions to hide from the embedded view.
1884
- * These actions will be hidden from the user.
1885
- * Use this to hide an action.
2024
+ * The list of actions to completely remove from the embedded view.
2025
+ * Hidden actions are not visible to the user at all (fully removed from the UI).
2026
+ * Use this when you want to remove an action entirely.
2027
+ * To keep an action visible but non-interactive (grayed out), use {@link disabledActions} instead.
1886
2028
  *
1887
2029
  * Supported embed types: `AppEmbed`, `LiveboardEmbed`, `SearchEmbed`, `SpotterAgentEmbed`, `SpotterEmbed`, `SearchBarEmbed`
1888
2030
  * @version SDK: 1.6.0 | ThoughtSpot: ts8.nov.cl, 8.4.1.sw
@@ -1901,9 +2043,8 @@ export interface BaseViewConfig extends ApiInterceptFlags {
1901
2043
  * The list of actions to display from the primary menu, more menu
1902
2044
  * (...), and the contextual menu. These will be only actions that
1903
2045
  * are visible to the user.
1904
- * Use this to hide all actions except the ones you want to show.
1905
- *
1906
- * Use either this or hiddenActions.
2046
+ * Use this as an allowlist only the actions listed here will be shown.
2047
+ * All other actions will be hidden. Use either this or {@link hiddenActions}, not both.
1907
2048
  *
1908
2049
  * Supported embed types: `AppEmbed`, `LiveboardEmbed`, `SearchEmbed`, `SpotterAgentEmbed`, `SpotterEmbed`, `SearchBarEmbed`
1909
2050
  * @version SDK: 1.6.0 | ThoughtSpot: ts8.nov.cl, 8.4.1.sw
@@ -2060,6 +2201,14 @@ export interface BaseViewConfig extends ApiInterceptFlags {
2060
2201
  * This flag can be used to disable links inside the embedded app,
2061
2202
  * and disable redirection of links in a new tab.
2062
2203
  *
2204
+ * Note: When set to `true`, this flag automatically disables
2205
+ * {@link enableLinkOverridesV2} for the
2206
+ * embed session. The two features are mutually exclusive — link
2207
+ * overrides mutate anchors (delete `href`, attach a JS click handler),
2208
+ * which breaks native browser behavior (Cmd/Ctrl+Click, middle-click,
2209
+ * right-click "Open in new tab") when combined with the disable flag.
2210
+ * The disable flag preserves native anchor semantics instead.
2211
+ *
2063
2212
  * Supported embed types: `AppEmbed`, `LiveboardEmbed`, `SearchEmbed`, `SpotterAgentEmbed`, `SpotterEmbed`, `SearchBarEmbed`
2064
2213
  * @version SDK: 1.32.1 | ThoughtSpot: 10.3.0.cl
2065
2214
  * @example
@@ -2095,8 +2244,13 @@ export interface BaseViewConfig extends ApiInterceptFlags {
2095
2244
  * Flag to override the *Open Link in New Tab* context
2096
2245
  * menu option.
2097
2246
  *
2098
- * For improved link override handling, use
2099
- * {@link enableLinkOverridesV2} instead.
2247
+ * Note: Setting this flag implicitly enables
2248
+ * {@link enableLinkOverridesV2}. V1 is auto-upgraded to
2249
+ * V2 to ensure consistent link-override behavior; the
2250
+ * legacy V1-only path is no longer used in isolation.
2251
+ *
2252
+ * Note: This flag is ignored when
2253
+ * {@link disableRedirectionLinksInNewTab} is `true`.
2100
2254
  *
2101
2255
  * Supported embed types: `AppEmbed`, `LiveboardEmbed`,
2102
2256
  * `SearchEmbed`, `SpotterAgentEmbed`,
@@ -2122,6 +2276,9 @@ export interface BaseViewConfig extends ApiInterceptFlags {
2122
2276
  * alongside this flag for backward compatibility with
2123
2277
  * older ThoughtSpot versions.
2124
2278
  *
2279
+ * Note: This flag is ignored when
2280
+ * {@link disableRedirectionLinksInNewTab} is `true`.
2281
+ *
2125
2282
  * Supported embed types: `AppEmbed`, `LiveboardEmbed`,
2126
2283
  * `SearchEmbed`, `SpotterAgentEmbed`,
2127
2284
  * `SpotterEmbed`, `SearchBarEmbed`
@@ -2357,6 +2514,7 @@ export interface BaseViewConfig extends ApiInterceptFlags {
2357
2514
  /**
2358
2515
  * Refresh the auth token when the token is near expiry.
2359
2516
  * @version SDK: 1.45.2 | ThoughtSpot: 26.3.0.cl
2517
+ * @default true
2360
2518
  * @example
2361
2519
  * ```js
2362
2520
  * const embed = new AppEmbed('#tsEmbed', {
@@ -3324,38 +3482,54 @@ export declare enum EmbedEvent {
3324
3482
  */
3325
3483
  VizPointClick = "vizPointClick",
3326
3484
  /**
3327
- * An error has occurred. This event is fired for the following error types:
3485
+ * Fired when an error occurs in the embedded component.
3486
+ *
3487
+ * **Important:** This event fires for many reasons — including internal
3488
+ * validation warnings (e.g. `HOST_EVENT_VALIDATION`), configuration issues,
3489
+ * and transient errors that ThoughtSpot already handles gracefully inside the
3490
+ * iframe. **Do not call `embed.destroy()` or unmount the embed component on
3491
+ * every error.** Doing so will tear down the iframe and abort all in-flight
3492
+ * requests, causing the embed to fail entirely.
3328
3493
  *
3494
+ * Only treat the following codes as unrecoverable:
3495
+ * - `INIT_ERROR` — SDK was not initialised before render
3496
+ * - `LOGIN_FAILED` — authentication could not be completed
3497
+ *
3498
+ * All other error codes should be logged and inspected, not acted upon
3499
+ * destructively.
3500
+ *
3501
+ * **Note:** There is currently no dedicated event for a true unrecoverable
3502
+ * crash. A future `EmbedEvent.FatalError` event is planned to give customers
3503
+ * a clean signal for when the embed cannot recover and needs to be torn down.
3504
+ *
3505
+ * Error types include:
3329
3506
  * `API` - API call failure.
3330
- * `FULLSCREEN` - Error when presenting a Liveboard or visualization in full screen
3331
- * mode. `SINGLE_VALUE_FILTER` - Error due to multiple values in the single value
3332
- * filter. `NON_EXIST_FILTER` - Error due to a non-existent filter.
3333
- * `INVALID_DATE_VALUE` - Invalid date value error.
3334
- * `INVALID_OPERATOR` - Use of invalid operator during filter application.
3507
+ * `FULLSCREEN` - Error when presenting a Liveboard in full screen mode.
3508
+ * `VALIDATION_ERROR` - Internal host event or configuration validation warning.
3335
3509
  *
3336
3510
  * For more information, see https://developers.thoughtspot.com/docs/events-app-integration#errorType
3337
3511
  * @returns error - An error object or message
3338
3512
  * @version SDK: 1.1.0 | ThoughtSpot: ts7.may.cl, 8.4.1.sw
3339
3513
  * @example
3340
3514
  * ```js
3341
- * // API error
3342
- * SearchEmbed.on(EmbedEvent.Error, (error) => {
3343
- * console.log(error);
3344
- * // { type: "Error", data: { errorType: "API", error: { message: '...', error: '...' } } }
3345
- * // { errorType: "API", message: '...', code: '...' } new format
3515
+ * // Recommended pattern — only destroy on truly fatal errors
3516
+ * embed.on(EmbedEvent.Error, (error) => {
3517
+ * const FATAL_CODES = ['INIT_ERROR', 'LOGIN_FAILED'];
3518
+ * if (FATAL_CODES.includes(error.data?.code)) {
3519
+ * embed.destroy();
3520
+ * return;
3521
+ * }
3522
+ * // Log all other errors — do not destroy
3523
+ * console.warn('Embed error (non-fatal):', error);
3346
3524
  * });
3347
3525
  * ```
3348
3526
  * @example
3349
3527
  * ```js
3350
- * // Fullscreen error (Errors during presenting of a liveboard)
3351
- * LiveboardEmbed.on(EmbedEvent.Error, (error) => {
3528
+ * // API error
3529
+ * SearchEmbed.on(EmbedEvent.Error, (error) => {
3352
3530
  * console.log(error);
3353
- * // { type: "Error", data: { errorType: "FULLSCREEN", error: {
3354
- * // message: "Fullscreen API is not enabled",
3355
- * // stack: "..."
3356
- * // } }}
3357
- * // { errorType: "FULLSCREEN", message: "Fullscreen API is not enabled", code: '...' } new format
3358
- * })
3531
+ * // { errorType: "API", message: '...', code: '...' }
3532
+ * });
3359
3533
  * ```
3360
3534
  */
3361
3535
  Error = "Error",
@@ -4556,7 +4730,103 @@ export declare enum EmbedEvent {
4556
4730
  * ```
4557
4731
  * @version SDK: 1.48.0 | ThoughtSpot Cloud: 26.5.0.cl
4558
4732
  */
4559
- SendTestScheduleEmail = "sendTestScheduleEmail"
4733
+ SendTestScheduleEmail = "sendTestScheduleEmail",
4734
+ /**
4735
+ * Emitted when the SpotterViz panel mounts in embed mode.
4736
+ * @version SDK: 1.50.0 | ThoughtSpot Cloud: 26.7.0.cl
4737
+ * @example
4738
+ * ```js
4739
+ * liveboardEmbed.on(EmbedEvent.SpotterVizInit, (payload) => {
4740
+ * console.log('SpotterViz initialized', payload);
4741
+ * // payload: { liveboardId: string }
4742
+ * })
4743
+ * ```
4744
+ */
4745
+ SpotterVizInit = "SpotterVizInit",
4746
+ /**
4747
+ * Emitted when the user submits a prompt in the SpotterViz panel.
4748
+ * @version SDK: 1.50.0 | ThoughtSpot Cloud: 26.7.0.cl
4749
+ * @example
4750
+ * ```js
4751
+ * liveboardEmbed.on(EmbedEvent.SpotterVizQueryTriggered, (payload) => {
4752
+ * console.log('SpotterViz query triggered', payload);
4753
+ * // payload: { query: string, sessionId: string }
4754
+ * })
4755
+ * ```
4756
+ */
4757
+ SpotterVizQueryTriggered = "SpotterVizQueryTriggered",
4758
+ /**
4759
+ * Emitted when the SpotterViz agent finishes responding.
4760
+ * @version SDK: 1.50.0 | ThoughtSpot Cloud: 26.7.0.cl
4761
+ * @example
4762
+ * ```js
4763
+ * liveboardEmbed.on(EmbedEvent.SpotterVizResponseComplete, (payload) => {
4764
+ * console.log('SpotterViz response complete', payload);
4765
+ * // payload: { sessionId: string, messageId: string }
4766
+ * })
4767
+ * ```
4768
+ */
4769
+ SpotterVizResponseComplete = "SpotterVizResponseComplete",
4770
+ /**
4771
+ * Emitted when a checkpoint is created in the SpotterViz panel.
4772
+ * @version SDK: 1.50.0 | ThoughtSpot Cloud: 26.7.0.cl
4773
+ * @example
4774
+ * ```js
4775
+ * liveboardEmbed.on(EmbedEvent.SpotterVizCheckpointCreated, (payload) => {
4776
+ * console.log('SpotterViz checkpoint created', payload);
4777
+ * // payload: { checkpointId: string, source: string, label: string }
4778
+ * })
4779
+ * ```
4780
+ */
4781
+ SpotterVizCheckpointCreated = "SpotterVizCheckpointCreated",
4782
+ /**
4783
+ * Emitted when a checkpoint is restored in the SpotterViz panel.
4784
+ * @version SDK: 1.50.0 | ThoughtSpot Cloud: 26.7.0.cl
4785
+ * @example
4786
+ * ```js
4787
+ * liveboardEmbed.on(EmbedEvent.SpotterVizCheckpointRestored, (payload) => {
4788
+ * console.log('SpotterViz checkpoint restored', payload);
4789
+ * // payload: { checkpointId: string, newGenNumber: number }
4790
+ * })
4791
+ * ```
4792
+ */
4793
+ SpotterVizCheckpointRestored = "SpotterVizCheckpointRestored",
4794
+ /**
4795
+ * Emitted when an error occurs in the SpotterViz panel.
4796
+ * @version SDK: 1.50.0 | ThoughtSpot Cloud: 26.7.0.cl
4797
+ * @example
4798
+ * ```js
4799
+ * liveboardEmbed.on(EmbedEvent.SpotterVizError, (payload) => {
4800
+ * console.log('SpotterViz error', payload);
4801
+ * })
4802
+ * ```
4803
+ */
4804
+ SpotterVizError = "SpotterVizError",
4805
+ /**
4806
+ * Emitted when the SpotterViz panel is closed.
4807
+ * @version SDK: 1.50.0 | ThoughtSpot Cloud: 26.7.0.cl
4808
+ * @example
4809
+ * ```js
4810
+ * liveboardEmbed.on(EmbedEvent.SpotterVizClosed, (payload) => {
4811
+ * console.log('SpotterViz panel closed', payload);
4812
+ * })
4813
+ * ```
4814
+ */
4815
+ SpotterVizClosed = "SpotterVizClosed",
4816
+ /**
4817
+ * Emitted when a user clicks the **Refresh** button in the
4818
+ * Liveboard header. Requires `enableLiveboardDataCache`
4819
+ * to be enabled.
4820
+ * @example
4821
+ * ```js
4822
+ * liveboardEmbed.on(EmbedEvent.RefreshLiveboardBrowserCache, (payload) => {
4823
+ * console.log('Liveboard browser cache refreshed', payload);
4824
+ * // payload: { liveboardId: string }
4825
+ * })
4826
+ * ```
4827
+ * @version SDK: 1.49.0 | ThoughtSpot Cloud: 26.6.0.cl
4828
+ */
4829
+ RefreshLiveboardBrowserCache = "refreshLiveboardBrowserCache"
4560
4830
  }
4561
4831
  /**
4562
4832
  * Event types that can be triggered by the host application
@@ -6626,7 +6896,38 @@ export declare enum HostEvent {
6626
6896
  * ```
6627
6897
  * @version SDK: 1.48.0 | ThoughtSpot Cloud: 26.5.0.cl
6628
6898
  */
6629
- SendTestScheduleEmail = "sendTestScheduleEmail"
6899
+ SendTestScheduleEmail = "sendTestScheduleEmail",
6900
+ /**
6901
+ * Sends a user message (prompt) to the SpotterViz panel programmatically.
6902
+ * @version SDK: 1.50.0 | ThoughtSpot Cloud: 26.7.0.cl
6903
+ * @param query - the prompt text to send.
6904
+ * @example
6905
+ * ```js
6906
+ * liveboardEmbed.trigger(HostEvent.SpotterVizSendUserMessage, {
6907
+ * query: 'Show me revenue by region',
6908
+ * });
6909
+ * ```
6910
+ */
6911
+ SpotterVizSendUserMessage = "SpotterVizSendUserMessage",
6912
+ /**
6913
+ * Initializes a new SpotterViz conversation.
6914
+ * @version SDK: 1.50.0 | ThoughtSpot Cloud: 26.7.0.cl
6915
+ * @example
6916
+ * ```js
6917
+ * liveboardEmbed.trigger(HostEvent.InitSpotterVizConversation);
6918
+ * ```
6919
+ */
6920
+ InitSpotterVizConversation = "InitSpotterVizConversation",
6921
+ /**
6922
+ * Clears browser cache and fetches new data for liveboard ChartViz Containers.
6923
+ * Requires `enableLiveboardDataCache` to be enabled.
6924
+ * @example
6925
+ * ```js
6926
+ * liveboardEmbed.trigger(HostEvent.RefreshLiveboardBrowserCache);
6927
+ * ```
6928
+ * @version SDK: 1.49.0 | ThoughtSpot Cloud: 26.6.0.cl
6929
+ */
6930
+ RefreshLiveboardBrowserCache = "refreshLiveboardBrowserCache"
6630
6931
  }
6631
6932
  /**
6632
6933
  * The different visual modes that the data sources panel within
@@ -6646,13 +6947,24 @@ export declare enum DataSourceVisualMode {
6646
6947
  */
6647
6948
  Expanded = "expand"
6648
6949
  }
6950
+ /**
6951
+ * Configuration for allowed file types in Spotter file upload.
6952
+ * @group Embed components
6953
+ */
6954
+ export type SpotterFileUploadFileTypes = {
6955
+ types?: string[];
6956
+ };
6649
6957
  /**
6650
6958
  * ThoughtSpot application pages include actions and menu commands
6651
6959
  * for various user-initiated operations. These actions are represented
6652
- * as enumeration members in the SDK. To show, hide, or disable
6653
- * specific actions in the embedded view, define the Action
6654
- * enumeration members in the `disabledActions`, `visibleActions`,
6655
- * or `hiddenActions` array.
6960
+ * as enumeration members in the SDK. To control actions in the embedded view:
6961
+ * - disabledActions the action is grayed out and still visible, but non-interactive (user can see but not click).
6962
+ * - hiddenActions the action is completely removed from the UI (user cannot see it at all).
6963
+ * - visibleActions — allowlist, only these actions are shown; all others are hidden.
6964
+ *
6965
+ * Use disabledActions to disable (gray out) an action.
6966
+ * Use hiddenActions to hide (fully remove) an action.
6967
+ * Use visibleActions to show only specific actions.
6656
6968
  * @example
6657
6969
  * ```js
6658
6970
  * const embed = new LiveboardEmbed('#tsEmbed', {
@@ -6978,6 +7290,20 @@ export declare enum Action {
6978
7290
  * @version SDK: 1.48.0 | ThoughtSpot: 26.5.0.cl
6979
7291
  */
6980
7292
  DownloadLiveboardAsContinuousPDF = "downloadLiveboardAsContinuousPDF",
7293
+ /**
7294
+ * The Download Liveboard as A4 PDF menu action on a Liveboard.
7295
+ * Allows downloading the entire Liveboard as an A4 PDF.
7296
+ * Requires {@link Action.DownloadLiveboard} as a parent action when
7297
+ * {@link LiveboardViewConfig.isLiveboardXLSXCSVDownloadEnabled} or
7298
+ * {@link LiveboardViewConfig.isContinuousLiveboardPDFEnabled} flags are enabled.
7299
+ * Use this instead of {@link Action.DownloadAsPdf} when either flag is on.
7300
+ * @version SDK: 1.50.0 | ThoughtSpot Cloud: 26.7.0.cl
7301
+ * @example
7302
+ * ```js
7303
+ * disabledActions: [Action.DownloadLiveboardAsA4Pdf]
7304
+ * ```
7305
+ */
7306
+ DownloadLiveboardAsA4Pdf = "downloadLiveboardAsA4Pdf",
6981
7307
  /**
6982
7308
  * The **Download Liveboard as XLSX** menu action on a Liveboard.
6983
7309
  * Allows downloading the entire Liveboard as an XLSX file.
@@ -7499,6 +7825,26 @@ export declare enum Action {
7499
7825
  * @version SDK: 1.21.0 | ThoughtSpot: 9.2.0.cl, 9.5.1.sw
7500
7826
  */
7501
7827
  AxisMenuRemove = "axisMenuRemove",
7828
+ /**
7829
+ * The **Compare with** action in the chart axis customization menu.
7830
+ * Allows comparing data across dimensions or measures.
7831
+ * @example
7832
+ * ```js
7833
+ * disabledActions: [Action.AxisMenuCompare]
7834
+ * ```
7835
+ * @version SDK: 1.50.0 | ThoughtSpot: 26.7.0.cl
7836
+ */
7837
+ AxisMenuCompare = "axisMenuCompare",
7838
+ /**
7839
+ * The **Merge with** action in the chart axis customization menu.
7840
+ * Allows merging data across dimensions or measures.
7841
+ * @example
7842
+ * ```js
7843
+ * disabledActions: [Action.AxisMenuMerge]
7844
+ * ```
7845
+ * @version SDK: 1.50.0 | ThoughtSpot: 26.7.0.cl
7846
+ */
7847
+ AxisMenuMerge = "axisMenuMerge",
7502
7848
  /**
7503
7849
  * @hidden
7504
7850
  */
@@ -8269,7 +8615,51 @@ export declare enum Action {
8269
8615
  * ```
8270
8616
  * @version SDK: 1.48.0 | ThoughtSpot Cloud: 26.5.0.cl
8271
8617
  */
8272
- SendTestScheduleEmail = "sendTestScheduleEmail"
8618
+ SendTestScheduleEmail = "sendTestScheduleEmail",
8619
+ /**
8620
+ * The thumbs up/down feedback buttons in the SpotterViz panel.
8621
+ * Visible by default.
8622
+ * @version SDK: 1.50.0 | ThoughtSpot Cloud: 26.7.0.cl
8623
+ * @example
8624
+ * ```js
8625
+ * hiddenActions: [Action.SpotterVizFeedback]
8626
+ * disabledActions: [Action.SpotterVizFeedback]
8627
+ * ```
8628
+ */
8629
+ SpotterVizFeedback = "spotterVizFeedback",
8630
+ /**
8631
+ * The version restore button on checkpoint cards in the SpotterViz panel.
8632
+ * Visible by default.
8633
+ * @version SDK: 1.50.0 | ThoughtSpot Cloud: 26.7.0.cl
8634
+ * @example
8635
+ * ```js
8636
+ * hiddenActions: [Action.SpotterVizCheckpointRestore]
8637
+ * disabledActions: [Action.SpotterVizCheckpointRestore]
8638
+ * ```
8639
+ */
8640
+ SpotterVizCheckpointRestore = "spotterVizCheckpointRestore",
8641
+ /**
8642
+ * The **SpotterViz** button in the top edit header.
8643
+ * Visible by default.
8644
+ * @version SDK: 1.50.0 | ThoughtSpot Cloud: 26.7.0.cl
8645
+ * @example
8646
+ * ```js
8647
+ * hiddenActions: [Action.SpotterViz]
8648
+ * disabledActions: [Action.SpotterViz]
8649
+ * ```
8650
+ */
8651
+ SpotterViz = "spotterViz",
8652
+ /**
8653
+ * Clears browser cache and fetches new data for liveboard ChartViz Containers.
8654
+ * Requires `enableLiveboardDataCache` to be enabled.
8655
+ * @example
8656
+ * ```js
8657
+ * disabledActions: [Action.RefreshLiveboardBrowserCache]
8658
+ * hiddenActions: [Action.RefreshLiveboardBrowserCache]
8659
+ * ```
8660
+ * @version SDK: 1.49.0 | ThoughtSpot Cloud: 26.6.0.cl
8661
+ */
8662
+ RefreshLiveboardBrowserCache = "refreshLiveboardBrowserCache"
8273
8663
  }
8274
8664
  export declare enum PrefetchFeatures {
8275
8665
  FullApp = "FullApp",
@@ -8612,6 +9002,9 @@ export interface DefaultAppInitData {
8612
9002
  customActions: CustomAction[];
8613
9003
  interceptTimeout: number | undefined;
8614
9004
  interceptUrls: (string | InterceptedApiType)[];
9005
+ embedExpiryInAuthToken: boolean;
9006
+ shouldBypassPayloadValidation?: boolean;
9007
+ useHostEventsV2?: boolean;
8615
9008
  }
8616
9009
  /**
8617
9010
  * Enum for the type of API intercepted
@@ -9521,7 +9914,7 @@ declare class TsEmbed {
9521
9914
  /**
9522
9915
  * The DOM node where the ThoughtSpot app is to be embedded.
9523
9916
  */
9524
- protected el: HTMLElement;
9917
+ protected hostElement: HTMLElement;
9525
9918
  /**
9526
9919
  * The key to store the embed instance in the DOM node
9527
9920
  */
@@ -9577,6 +9970,7 @@ declare class TsEmbed {
9577
9970
  private resizeObserver;
9578
9971
  protected hostEventClient: HostEventClient;
9579
9972
  protected isReadyForRenderPromise: Promise<void>;
9973
+ protected shouldWaitForRenderPromise: boolean;
9580
9974
  /**
9581
9975
  * Handler for fullscreen change events
9582
9976
  */
@@ -9710,6 +10104,10 @@ declare class TsEmbed {
9710
10104
  protected getEmbedParamsObject(): Record<any, any>;
9711
10105
  protected getRootIframeSrc(): string;
9712
10106
  protected createIframeEl(frameSrc: string): HTMLIFrameElement;
10107
+ /**
10108
+ * Returns true if this embed instance is configured for pre-rendering.
10109
+ */
10110
+ protected isPreRenderEmbed(): boolean;
9713
10111
  protected handleInsertionIntoDOM(child: string | Node): void;
9714
10112
  /**
9715
10113
  * Renders the embedded ThoughtSpot app in an iframe and sets up
@@ -9720,9 +10118,23 @@ declare class TsEmbed {
9720
10118
  protected createPreRenderWrapper(): HTMLDivElement;
9721
10119
  protected preRenderWrapper: HTMLElement;
9722
10120
  protected preRenderChild: HTMLElement;
10121
+ /**
10122
+ * Checks for an existing pre-rendered component and connects to it.
10123
+ *
10124
+ * If a matching pre-rendered component is found in the DOM, this method
10125
+ * sets the internal properties of the embed object to reference it.
10126
+ *
10127
+ * @returns True if a connection was successfully established, false otherwise.
10128
+ */
9723
10129
  protected connectPreRendered(): boolean;
9724
- protected isPreRenderAvailable(): boolean;
10130
+ protected isPreRenderConnected(): boolean;
9725
10131
  protected createPreRenderChild(child: string | Node): HTMLElement;
10132
+ /**
10133
+ * Creates the in-flow placeholder div inserted into the host element when
10134
+ * showPreRender() is called. The wrapper observes this element to stay
10135
+ * aligned with the host layout.
10136
+ */
10137
+ private createPreRenderPlaceholder;
9726
10138
  protected insertIntoDOMForPreRender(child: string | Node): void;
9727
10139
  private showPreRenderByDefault;
9728
10140
  protected insertIntoDOM(child: string | Node): void;
@@ -9819,10 +10231,10 @@ declare class TsEmbed {
9819
10231
  */
9820
10232
  private triggerEventOnPort;
9821
10233
  /**
9822
- * @hidden
9823
- * Internal state to track if the embed container is loaded.
9824
- * This is used to trigger events after the embed container is loaded.
9825
- */
10234
+ * @hidden
10235
+ * Internal state to track if the embed container is loaded.
10236
+ * This is used to trigger events after the embed container is loaded.
10237
+ */
9826
10238
  isEmbedContainerLoaded: boolean;
9827
10239
  /**
9828
10240
  * @hidden
@@ -9879,33 +10291,33 @@ declare class TsEmbed {
9879
10291
  getIframeSrc(): string;
9880
10292
  protected handleRenderForPrerender(): Promise<TsEmbed>;
9881
10293
  /**
9882
- * Context object for the embedded component.
9883
- * @returns {ContextObject} The current context object containing the page type and object ids.
9884
- * @example
9885
- * ```js
9886
- * const context = await embed.getCurrentContext();
9887
- * console.log(context);
9888
- *
9889
- * // Example output
9890
- * {
9891
- * stack: [
9892
- * {
9893
- * name: 'Liveboard',
9894
- * type: ContextType.Liveboard,
9895
- * objectIds: {
9896
- * liveboardId: '123',
9897
- * },
9898
- * },
9899
- * ],
9900
- * currentContext: {
9901
- * name: 'Liveboard',
9902
- * type: ContextType.Liveboard,
9903
- * objectIds: {
9904
- * liveboardId: '123',
9905
- * },
9906
- * },
9907
- * }
9908
- * ```
10294
+ * Context object for the embedded component.
10295
+ * @returns {ContextObject} The current context object containing the page type and object ids.
10296
+ * @example
10297
+ * ```js
10298
+ * const context = await embed.getCurrentContext();
10299
+ * console.log(context);
10300
+ *
10301
+ * // Example output
10302
+ * {
10303
+ * stack: [
10304
+ * {
10305
+ * name: 'Liveboard',
10306
+ * type: ContextType.Liveboard,
10307
+ * objectIds: {
10308
+ * liveboardId: '123',
10309
+ * },
10310
+ * },
10311
+ * ],
10312
+ * currentContext: {
10313
+ * name: 'Liveboard',
10314
+ * type: ContextType.Liveboard,
10315
+ * objectIds: {
10316
+ * liveboardId: '123',
10317
+ * },
10318
+ * },
10319
+ * }
10320
+ * ```
9909
10321
  * @version SDK: 1.45.2 | ThoughtSpot: 26.3.0.cl
9910
10322
  */
9911
10323
  getCurrentContext(): Promise<ContextObject>;
@@ -9950,14 +10362,14 @@ declare class TsEmbed {
9950
10362
  */
9951
10363
  prerenderGeneric(): Promise<any>;
9952
10364
  protected beforePrerenderVisible(): void;
9953
- private validatePreRenderViewConfig;
9954
10365
  /**
9955
- * Displays the PreRender component.
9956
- * If the component is not preRendered, it attempts to create and render it.
9957
- * Also, synchronizes the style of the PreRender component with the embedding
9958
- * element.
10366
+ * Displays the pre-rendered component inside the host element.
10367
+ * If the component has not been pre-rendered yet, it initiates rendering first.
10368
+ * Inserts a placeholder element into the host and positions the pre-render
10369
+ * wrapper to overlay it.
9959
10370
  */
9960
10371
  showPreRender(): Promise<TsEmbed>;
10372
+ protected getPreRenderPlaceHolderElement(): HTMLDivElement;
9961
10373
  /**
9962
10374
  * Synchronizes the style properties of the PreRender component with the embedding
9963
10375
  * element. This function adjusts the position, width, and height of the PreRender
@@ -9982,6 +10394,7 @@ declare class TsEmbed {
9982
10394
  getPreRenderIds(): {
9983
10395
  wrapper: string;
9984
10396
  child: string;
10397
+ placeHolder: string;
9985
10398
  };
9986
10399
  /**
9987
10400
  * Returns the answerService which can be used to make arbitrary graphql calls on top
@@ -10593,6 +11006,21 @@ export interface SpotterChatViewConfig {
10593
11006
  * External MCP tool branding is not affected.
10594
11007
  */
10595
11008
  toolResponseCardBrandingLabel?: string;
11009
+ /**
11010
+ * Enables file upload in the Spotter chat interface.
11011
+ *
11012
+ * Supported embed types: `SpotterEmbed`, `LiveboardEmbed`, `AppEmbed`
11013
+ * @version SDK: 1.49.0 | ThoughtSpot: 26.6.0.cl
11014
+ * @default false
11015
+ */
11016
+ spotterFileUploadEnabled?: boolean;
11017
+ /**
11018
+ * Restricts the allowed file types for Spotter file upload.
11019
+ *
11020
+ * Supported embed types: `SpotterEmbed`, `LiveboardEmbed`, `AppEmbed`
11021
+ * @version SDK: 1.49.0 | ThoughtSpot: 26.6.0.cl
11022
+ */
11023
+ spotterFileUploadFileTypes?: SpotterFileUploadFileTypes;
10596
11024
  }
10597
11025
  /**
10598
11026
  * The configuration for the embedded spotterEmbed options.
@@ -10864,6 +11292,82 @@ declare class ConversationEmbed extends SpotterEmbed {
10864
11292
  protected viewConfig: ConversationViewConfig;
10865
11293
  constructor(container: HTMLElement, viewConfig: ConversationViewConfig);
10866
11294
  }
11295
+ /**
11296
+ * Defines starter prompts displayed in the SpotterViz interface.
11297
+ * @version SDK: 1.50.0 | ThoughtSpot Cloud: 26.7.0.cl
11298
+ * @group Embed components
11299
+ */
11300
+ export interface SpotterVizStarterPrompt {
11301
+ /** Identifier for the prompt. */
11302
+ id: string;
11303
+ /** Short label shown to the user as a clickable suggestion. */
11304
+ displayText: string;
11305
+ /** Full prompt text sent to Spotter when the user clicks the suggestion. */
11306
+ fullPrompt: string;
11307
+ }
11308
+ /**
11309
+ * Configuration for the SpotterViz interface shown on the Liveboard.
11310
+ * Supported embed types: `AppEmbed`, `LiveboardEmbed`
11311
+ * @version SDK: 1.50.0 | ThoughtSpot Cloud: 26.7.0.cl
11312
+ * @group Embed components
11313
+ * @example
11314
+ * ```js
11315
+ * const embed = new AppEmbed('#embed-container', {
11316
+ * ... // other options,
11317
+ * spotterViz: {
11318
+ * brandName: 'MyBrand',
11319
+ * brandHeadline: 'Hi, there! I\'m',
11320
+ * description: 'Ask questions about your data',
11321
+ * inputChatPlaceholder: 'Ask a question...',
11322
+ * hideStarterPrompts: false,
11323
+ * customStarterPrompts: [
11324
+ * { id: '1', displayText: 'Top products', fullPrompt: 'What are the top products by revenue?' }
11325
+ * ],
11326
+ * },
11327
+ * })
11328
+ * ```
11329
+ */
11330
+ export interface SpotterVizConfig {
11331
+ /**
11332
+ * Rename the default "SpotterViz" label shown in the SpotterViz interface with a custom brand name.
11333
+ * @version SDK: 1.50.0 | ThoughtSpot Cloud: 26.7.0.cl
11334
+ * @default ''
11335
+ */
11336
+ brandName?: string;
11337
+ /**
11338
+ * Custom headline text shown before the brand name in the SpotterViz interface.
11339
+ * Replaces the default greeting prefix (e.g. "Hi, there! I'm").
11340
+ * @version SDK: 1.50.0 | ThoughtSpot Cloud: 26.7.0.cl
11341
+ * @default ''
11342
+ */
11343
+ brandHeadline?: string;
11344
+ /**
11345
+ * Hides the starter prompts section entirely in the SpotterViz interface.
11346
+ * When set to `true`, the starter prompts are not displayed.
11347
+ * @version SDK: 1.50.0 | ThoughtSpot Cloud: 26.7.0.cl
11348
+ * @default false
11349
+ */
11350
+ hideStarterPrompts?: boolean;
11351
+ /**
11352
+ * Overrides the starter prompts with a custom list.
11353
+ * Each entry must match the {@link SpotterVizStarterPrompt} shape.
11354
+ * Has no effect when `hideStarterPrompts` is `true`.
11355
+ * @version SDK: 1.50.0 | ThoughtSpot Cloud: 26.7.0.cl
11356
+ */
11357
+ customStarterPrompts?: SpotterVizStarterPrompt[];
11358
+ /**
11359
+ * Custom description text shown in the SpotterViz interface.
11360
+ * Replaces the default SpotterViz description.
11361
+ * @version SDK: 1.50.0 | ThoughtSpot Cloud: 26.7.0.cl
11362
+ */
11363
+ description?: string;
11364
+ /**
11365
+ * Custom placeholder text for the chat input in the SpotterViz interface.
11366
+ * Replaces the default chat input placeholder text.
11367
+ * @version SDK: 1.50.0 | ThoughtSpot Cloud: 26.7.0.cl
11368
+ */
11369
+ inputChatPlaceholder?: string;
11370
+ }
10867
11371
  /**
10868
11372
  * Pages within the ThoughtSpot app that can be embedded.
10869
11373
  */
@@ -10942,7 +11446,15 @@ declare enum HomePage {
10942
11446
  * ModularWithStylingChanges (v3) introduces Modular Home Experience
10943
11447
  * with styling changes.
10944
11448
  */
10945
- ModularWithStylingChanges = "v3"
11449
+ ModularWithStylingChanges = "v3",
11450
+ /**
11451
+ * Focused (v4) introduces the V4 homepage experience
11452
+ * in which Watchlist and recents and incorporated together
11453
+ * to form a more focused homepage.
11454
+ * Pre-requisite : spotter enablement
11455
+ * @version SDK: 1.50.0 | ThoughtSpot Cloud: 26.7.0.cl
11456
+ */
11457
+ Focused = "v4"
10946
11458
  }
10947
11459
  declare enum ListPage {
10948
11460
  /**
@@ -11370,6 +11882,21 @@ export interface AppViewConfig extends AllEmbedViewConfig {
11370
11882
  * ```
11371
11883
  */
11372
11884
  isUnifiedSearchExperienceEnabled?: boolean;
11885
+ /**
11886
+ * This flag is used to enable the new connection experience for AppEmbed.
11887
+ *
11888
+ * Supported embed types: `AppEmbed`
11889
+ * @version SDK: 1.51.0 | ThoughtSpot Cloud: 26.8.0.cl
11890
+ * @default false
11891
+ * @example
11892
+ * ```js
11893
+ * const embed = new AppEmbed('#tsEmbed', {
11894
+ * ... // other embed view config
11895
+ * newConnectionsExperience: true,
11896
+ * })
11897
+ * ```
11898
+ */
11899
+ newConnectionsExperience?: boolean;
11373
11900
  /**
11374
11901
  * This flag is used to enable/disable the styling and grouping in a Liveboard. Use {@link isLiveboardMasterpiecesEnabled} instead.
11375
11902
  * @deprecated This flag is deprecated.
@@ -11407,7 +11934,7 @@ export interface AppViewConfig extends AllEmbedViewConfig {
11407
11934
  /**
11408
11935
  * Enables the 'what you see is what you get' PDF export for Liveboards. Each tab is rendered on a single page
11409
11936
  * following the exact UI layout, instead of splitting visualizations across multiple A4 pages.
11410
- * This feature is GA from version 26.5.0.cl and is enabled by default on embed deployments.
11937
+ * This feature is GA from version 26.5.0.cl. It is disabled by default in embed deployments.
11411
11938
  *
11412
11939
  * Supported embed types: `AppEmbed`, `LiveboardEmbed`
11413
11940
  * @type {boolean}
@@ -11470,6 +11997,17 @@ export interface AppViewConfig extends AllEmbedViewConfig {
11470
11997
  * ```
11471
11998
  */
11472
11999
  lazyLoadingForFullHeight?: boolean;
12000
+ /**
12001
+ * This flag is used to enable container-aware full height lazy loading.
12002
+ *
12003
+ * Use this when the embed is rendered inside a scrollable or clipping
12004
+ * container instead of relying on the browser window as the only viewport.
12005
+ *
12006
+ * @type {boolean}
12007
+ * @default false
12008
+ * @hidden
12009
+ */
12010
+ enableScrollableContainerLazyLoading?: boolean;
11473
12011
  /**
11474
12012
  * The margin to be used for lazy loading.
11475
12013
  *
@@ -11556,6 +12094,29 @@ export interface AppViewConfig extends AllEmbedViewConfig {
11556
12094
  * ```
11557
12095
  */
11558
12096
  spotterChatConfig?: SpotterChatViewConfig;
12097
+ /**
12098
+ * Configuration for the SpotterViz interface shown on the Liveboard.
12099
+ * Customize the brand name, description, chat input placeholder,
12100
+ * starter prompts, and visibility of starter prompts in the SpotterViz panel.
12101
+ *
12102
+ * Supported embed types: `AppEmbed`, `LiveboardEmbed`
12103
+ * @version SDK: 1.50.0 | ThoughtSpot Cloud: 26.7.0.cl
12104
+ * @example
12105
+ * ```js
12106
+ * const embed = new AppEmbed('#embed-container', {
12107
+ * ... // other options
12108
+ * spotterViz: {
12109
+ * brandName: 'MyBrand',
12110
+ * brandHeadline: 'Hi, there! I\'m',
12111
+ * description: 'Ask questions about your data',
12112
+ * inputChatPlaceholder: 'Ask a question...',
12113
+ * hideStarterPrompts: false,
12114
+ * customStarterPrompts: [{ id: '1', displayText: 'Top products', fullPrompt: 'What are the top products by revenue?' }]
12115
+ * },
12116
+ * })
12117
+ * ```
12118
+ */
12119
+ spotterViz?: SpotterVizConfig;
11559
12120
  /**
11560
12121
  * Enables the stop answer generation button in the Spotter embed UI,
11561
12122
  * allowing users to interrupt an ongoing answer generation.
@@ -11624,11 +12185,14 @@ export interface AppViewConfig extends AllEmbedViewConfig {
11624
12185
  export interface AppEmbedAppInitData extends DefaultAppInitData {
11625
12186
  embedParams?: {
11626
12187
  spotterSidebarConfig?: SpotterSidebarViewConfig;
12188
+ spotterVizConfig?: SpotterVizConfig;
11627
12189
  };
11628
12190
  }
11629
12191
  declare class AppEmbed extends V1Embed {
11630
12192
  protected viewConfig: AppViewConfig;
11631
12193
  private defaultHeight;
12194
+ private lazyLoadScrollContainers;
12195
+ private lazyLoadResizeObserver;
11632
12196
  constructor(domSelector: DOMSelector, viewConfig: AppViewConfig);
11633
12197
  /**
11634
12198
  * Extends the default APP_INIT payload with `embedParams.spotterSidebarConfig`
@@ -11708,6 +12272,15 @@ declare class AppEmbed extends V1Embed {
11708
12272
  */
11709
12273
  render(): Promise<AppEmbed>;
11710
12274
  }
12275
+ /**
12276
+ * APP_INIT data shape for LiveboardEmbed.
12277
+ * @internal
12278
+ */
12279
+ export interface LiveboardEmbedAppInitData extends DefaultAppInitData {
12280
+ embedParams?: {
12281
+ spotterVizConfig?: SpotterVizConfig;
12282
+ };
12283
+ }
11711
12284
  /**
11712
12285
  * The configuration for the embedded Liveboard or visualization page view.
11713
12286
  * @group Embed components
@@ -12063,7 +12636,7 @@ export interface LiveboardViewConfig extends BaseViewConfig, SearchLiveboardComm
12063
12636
  /**
12064
12637
  * Enables the 'what you see is what you get' PDF export for Liveboards. Each tab is rendered on a single page
12065
12638
  * following the exact UI layout, instead of splitting visualizations across multiple A4 pages.
12066
- * This feature is GA from version 26.5.0.cl and is enabled by default on embed deployments.
12639
+ * This feature is GA from version 26.5.0.cl. It is disabled by default in embed deployments.
12067
12640
  *
12068
12641
  * Supported embed types: `AppEmbed`, `LiveboardEmbed`
12069
12642
  * @type {boolean}
@@ -12126,6 +12699,16 @@ export interface LiveboardViewConfig extends BaseViewConfig, SearchLiveboardComm
12126
12699
  * ```
12127
12700
  */
12128
12701
  lazyLoadingForFullHeight?: boolean;
12702
+ /**
12703
+ * This flag is used to enable container-aware full height lazy loading.
12704
+ *
12705
+ * Use this when the embed is rendered inside a scrollable or clipping
12706
+ * container instead of relying on the browser window as the only viewport.
12707
+ *
12708
+ * @type {boolean}
12709
+ * @default false
12710
+ */
12711
+ enableScrollableContainerLazyLoading?: boolean;
12129
12712
  /**
12130
12713
  * The margin to be used for lazy loading.
12131
12714
  *
@@ -12207,6 +12790,29 @@ export interface LiveboardViewConfig extends BaseViewConfig, SearchLiveboardComm
12207
12790
  * ```
12208
12791
  */
12209
12792
  spotterChatConfig?: SpotterChatViewConfig;
12793
+ /**
12794
+ * Configuration for the SpotterViz interface shown on the Liveboard.
12795
+ * Customize the brand name, description, chat input placeholder,
12796
+ * starter prompts, and visibility of starter prompts in the SpotterViz panel.
12797
+ *
12798
+ * Supported embed types: `AppEmbed`, `LiveboardEmbed`
12799
+ * @version SDK: 1.50.0 | ThoughtSpot Cloud: 26.7.0.cl
12800
+ * @example
12801
+ * ```js
12802
+ * const embed = new LiveboardEmbed('#embed-container', {
12803
+ * ... // other options
12804
+ * spotterViz: {
12805
+ * brandName: 'MyBrand',
12806
+ * brandHeadline: 'Hi, there! I\'m',
12807
+ * description: 'Ask questions about your data',
12808
+ * inputChatPlaceholder: 'Ask a question...',
12809
+ * hideStarterPrompts: false,
12810
+ * customStarterPrompts: [{ id: '1', displayText: 'Top products', fullPrompt: 'What are the top products by revenue?' }],
12811
+ * },
12812
+ * })
12813
+ * ```
12814
+ */
12815
+ spotterViz?: SpotterVizConfig;
12210
12816
  /**
12211
12817
  * If set to true, enables visualization data caching on the Liveboard.
12212
12818
  * @type {boolean}
@@ -12224,7 +12830,10 @@ export interface LiveboardViewConfig extends BaseViewConfig, SearchLiveboardComm
12224
12830
  declare class LiveboardEmbed extends V1Embed {
12225
12831
  protected viewConfig: LiveboardViewConfig;
12226
12832
  private defaultHeight;
12833
+ private lazyLoadScrollContainers;
12834
+ private lazyLoadResizeObserver;
12227
12835
  constructor(domSelector: DOMSelector, viewConfig: LiveboardViewConfig);
12836
+ protected getAppInitData(): Promise<LiveboardEmbedAppInitData>;
12228
12837
  /**
12229
12838
  * Construct a map of params to be passed on to the
12230
12839
  * embedded Liveboard or visualization.