@thoughtspot/visual-embed-sdk 1.41.0 → 1.41.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.
- package/README.md +2 -4
- package/cjs/package.json +1 -1
- package/cjs/src/authToken.d.ts +1 -0
- package/cjs/src/authToken.d.ts.map +1 -1
- package/cjs/src/authToken.js +13 -3
- package/cjs/src/authToken.js.map +1 -1
- package/cjs/src/authToken.spec.js +29 -0
- package/cjs/src/authToken.spec.js.map +1 -1
- package/cjs/src/css-variables.d.ts +2 -1
- package/cjs/src/css-variables.d.ts.map +1 -1
- package/cjs/src/embed/app.d.ts +16 -0
- package/cjs/src/embed/app.d.ts.map +1 -1
- package/cjs/src/embed/app.js +4 -1
- package/cjs/src/embed/app.js.map +1 -1
- package/cjs/src/embed/app.spec.js +10 -0
- package/cjs/src/embed/app.spec.js.map +1 -1
- package/cjs/src/embed/conversation.d.ts +2 -2
- package/cjs/src/embed/liveboard.d.ts +32 -0
- package/cjs/src/embed/liveboard.d.ts.map +1 -1
- package/cjs/src/embed/liveboard.js +7 -1
- package/cjs/src/embed/liveboard.js.map +1 -1
- package/cjs/src/embed/liveboard.spec.js +85 -11
- package/cjs/src/embed/liveboard.spec.js.map +1 -1
- package/cjs/src/embed/sage.spec.js +20 -10
- package/cjs/src/embed/sage.spec.js.map +1 -1
- package/cjs/src/embed/search.js +1 -1
- package/cjs/src/embed/search.js.map +1 -1
- package/cjs/src/embed/search.spec.js +10 -10
- package/cjs/src/embed/search.spec.js.map +1 -1
- package/cjs/src/embed/ts-embed.d.ts +1 -1
- package/cjs/src/embed/ts-embed.d.ts.map +1 -1
- package/cjs/src/embed/ts-embed.js +5 -1
- package/cjs/src/embed/ts-embed.js.map +1 -1
- package/cjs/src/errors.d.ts +1 -0
- package/cjs/src/errors.d.ts.map +1 -1
- package/cjs/src/errors.js +1 -0
- package/cjs/src/errors.js.map +1 -1
- package/cjs/src/react/index.d.ts.map +1 -1
- package/cjs/src/react/index.js +2 -1
- package/cjs/src/react/index.js.map +1 -1
- package/cjs/src/react/index.spec.js +1 -1
- package/cjs/src/react/index.spec.js.map +1 -1
- package/cjs/src/types.d.ts +29 -5
- package/cjs/src/types.d.ts.map +1 -1
- package/cjs/src/types.js +25 -1
- package/cjs/src/types.js.map +1 -1
- package/cjs/src/utils.d.ts +14 -0
- package/cjs/src/utils.d.ts.map +1 -1
- package/cjs/src/utils.js +22 -1
- package/cjs/src/utils.js.map +1 -1
- package/cjs/src/utils.spec.js +10 -0
- package/cjs/src/utils.spec.js.map +1 -1
- package/dist/{index-B_mxAan8.js → index-DQueHwfQ.js} +1 -1
- package/dist/src/authToken.d.ts +1 -0
- package/dist/src/authToken.d.ts.map +1 -1
- package/dist/src/css-variables.d.ts +2 -1
- package/dist/src/css-variables.d.ts.map +1 -1
- package/dist/src/embed/app.d.ts +16 -0
- package/dist/src/embed/app.d.ts.map +1 -1
- package/dist/src/embed/conversation.d.ts +2 -2
- package/dist/src/embed/liveboard.d.ts +32 -0
- package/dist/src/embed/liveboard.d.ts.map +1 -1
- package/dist/src/embed/ts-embed.d.ts +1 -1
- package/dist/src/embed/ts-embed.d.ts.map +1 -1
- package/dist/src/errors.d.ts +1 -0
- package/dist/src/errors.d.ts.map +1 -1
- package/dist/src/react/index.d.ts.map +1 -1
- package/dist/src/types.d.ts +29 -5
- package/dist/src/types.d.ts.map +1 -1
- package/dist/src/utils.d.ts +14 -0
- package/dist/src/utils.d.ts.map +1 -1
- package/dist/tsembed-react.es.js +77 -9
- package/dist/tsembed-react.js +76 -8
- package/dist/tsembed.es.js +75 -8
- package/dist/tsembed.js +74 -7
- package/dist/visual-embed-sdk-react-full.d.ts +83 -9
- package/dist/visual-embed-sdk-react.d.ts +83 -9
- package/dist/visual-embed-sdk.d.ts +83 -9
- package/lib/package.json +1 -1
- package/lib/src/authToken.d.ts +1 -0
- package/lib/src/authToken.d.ts.map +1 -1
- package/lib/src/authToken.js +11 -2
- package/lib/src/authToken.js.map +1 -1
- package/lib/src/authToken.spec.js +30 -1
- package/lib/src/authToken.spec.js.map +1 -1
- package/lib/src/css-variables.d.ts +2 -1
- package/lib/src/css-variables.d.ts.map +1 -1
- package/lib/src/embed/app.d.ts +16 -0
- package/lib/src/embed/app.d.ts.map +1 -1
- package/lib/src/embed/app.js +4 -1
- package/lib/src/embed/app.js.map +1 -1
- package/lib/src/embed/app.spec.js +10 -0
- package/lib/src/embed/app.spec.js.map +1 -1
- package/lib/src/embed/conversation.d.ts +2 -2
- package/lib/src/embed/liveboard.d.ts +32 -0
- package/lib/src/embed/liveboard.d.ts.map +1 -1
- package/lib/src/embed/liveboard.js +7 -1
- package/lib/src/embed/liveboard.js.map +1 -1
- package/lib/src/embed/liveboard.spec.js +85 -11
- package/lib/src/embed/liveboard.spec.js.map +1 -1
- package/lib/src/embed/sage.spec.js +20 -10
- package/lib/src/embed/sage.spec.js.map +1 -1
- package/lib/src/embed/search.js +1 -1
- package/lib/src/embed/search.js.map +1 -1
- package/lib/src/embed/search.spec.js +11 -11
- package/lib/src/embed/search.spec.js.map +1 -1
- package/lib/src/embed/ts-embed.d.ts +1 -1
- package/lib/src/embed/ts-embed.d.ts.map +1 -1
- package/lib/src/embed/ts-embed.js +5 -1
- package/lib/src/embed/ts-embed.js.map +1 -1
- package/lib/src/errors.d.ts +1 -0
- package/lib/src/errors.d.ts.map +1 -1
- package/lib/src/errors.js +1 -0
- package/lib/src/errors.js.map +1 -1
- package/lib/src/react/index.d.ts.map +1 -1
- package/lib/src/react/index.js +2 -1
- package/lib/src/react/index.js.map +1 -1
- package/lib/src/react/index.spec.js +1 -1
- package/lib/src/react/index.spec.js.map +1 -1
- package/lib/src/types.d.ts +29 -5
- package/lib/src/types.d.ts.map +1 -1
- package/lib/src/types.js +25 -1
- package/lib/src/types.js.map +1 -1
- package/lib/src/utils.d.ts +14 -0
- package/lib/src/utils.d.ts.map +1 -1
- package/lib/src/utils.js +20 -0
- package/lib/src/utils.js.map +1 -1
- package/lib/src/utils.spec.js +11 -1
- package/lib/src/utils.spec.js.map +1 -1
- package/lib/src/visual-embed-sdk.d.ts +83 -9
- package/package.json +1 -1
- package/src/authToken.spec.ts +48 -1
- package/src/authToken.ts +13 -2
- package/src/css-variables.ts +2 -1
- package/src/embed/app.spec.ts +14 -0
- package/src/embed/app.ts +23 -1
- package/src/embed/conversation.ts +2 -2
- package/src/embed/liveboard.spec.ts +112 -14
- package/src/embed/liveboard.ts +65 -23
- package/src/embed/sage.spec.ts +24 -10
- package/src/embed/search.spec.ts +13 -14
- package/src/embed/search.ts +1 -1
- package/src/embed/ts-embed.ts +7 -1
- package/src/errors.ts +1 -0
- package/src/react/index.spec.tsx +1 -1
- package/src/react/index.tsx +4 -2
- package/src/types.ts +27 -3
- package/src/utils.spec.ts +18 -0
- package/src/utils.ts +21 -0
package/dist/tsembed-react.es.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* @thoughtspot/visual-embed-sdk version 1.41.
|
|
1
|
+
/* @thoughtspot/visual-embed-sdk version 1.41.1 */
|
|
2
2
|
'use client';
|
|
3
3
|
import * as React from 'react';
|
|
4
4
|
import React__default, { useRef, useCallback } from 'react';
|
|
@@ -2614,7 +2614,7 @@ var HostEvent;
|
|
|
2614
2614
|
* column: "Date",
|
|
2615
2615
|
* oper: 'EQ',
|
|
2616
2616
|
* values: ["2023-07-31"],
|
|
2617
|
-
*
|
|
2617
|
+
* type: "EXACT_DATE"
|
|
2618
2618
|
* }]
|
|
2619
2619
|
* });
|
|
2620
2620
|
* ```
|
|
@@ -3106,6 +3106,7 @@ var Param;
|
|
|
3106
3106
|
Param["IsLazyLoadingForEmbedEnabled"] = "isLazyLoadingForEmbedEnabled";
|
|
3107
3107
|
Param["RootMarginForLazyLoad"] = "rootMarginForLazyLoad";
|
|
3108
3108
|
Param["LiveboardXLSXCSVDownload"] = "isLiveboardXLSXCSVDownloadEnabled";
|
|
3109
|
+
Param["isPNGInScheduledEmailsEnabled"] = "isPNGInScheduledEmailsEnabled";
|
|
3109
3110
|
})(Param || (Param = {}));
|
|
3110
3111
|
/**
|
|
3111
3112
|
* ThoughtSpot application pages include actions and menu commands
|
|
@@ -4387,6 +4388,29 @@ var Action;
|
|
|
4387
4388
|
* @version SDK: 1.41.0 | ThoughtSpot Cloud: 10.13.0.cl
|
|
4388
4389
|
*/
|
|
4389
4390
|
Action["SpotterTokenQuickEdit"] = "SpotterTokenQuickEdit";
|
|
4391
|
+
/**
|
|
4392
|
+
* The **PNG screenshot in email** option in the schedule email dialog.
|
|
4393
|
+
* Includes a PNG screenshot in the notification email body.
|
|
4394
|
+
* @example
|
|
4395
|
+
* ```js
|
|
4396
|
+
* disabledActions: [Action.PngScreenshotInEmail]
|
|
4397
|
+
* ```
|
|
4398
|
+
* ```
|
|
4399
|
+
* @version SDK: 1.42.0 | ThoughtSpot Cloud: 10.14.0.cl
|
|
4400
|
+
*/
|
|
4401
|
+
Action["PngScreenshotInEmail"] = "pngScreenshotInEmail";
|
|
4402
|
+
/**
|
|
4403
|
+
* The **Remove attachment** action in the schedule email dialog.
|
|
4404
|
+
* Removes an attachment from the email configuration.
|
|
4405
|
+
* @example
|
|
4406
|
+
* ```js
|
|
4407
|
+
* disabledActions: [Action.RemoveAttachment]
|
|
4408
|
+
* ```
|
|
4409
|
+
* ```
|
|
4410
|
+
* ```
|
|
4411
|
+
* @version SDK: 1.42.0 | ThoughtSpot Cloud: 10.14.0.cl
|
|
4412
|
+
*/
|
|
4413
|
+
Action["RemoveAttachment"] = "removeAttachment";
|
|
4390
4414
|
})(Action || (Action = {}));
|
|
4391
4415
|
var PrefetchFeatures;
|
|
4392
4416
|
(function (PrefetchFeatures) {
|
|
@@ -4975,6 +4999,26 @@ const calculateVisibleElementData = (element) => {
|
|
|
4975
4999
|
width: Math.max(0, frameRelativeRight - frameRelativeLeft),
|
|
4976
5000
|
};
|
|
4977
5001
|
return data;
|
|
5002
|
+
};
|
|
5003
|
+
/**
|
|
5004
|
+
* Replaces placeholders in a template string with provided values.
|
|
5005
|
+
* Placeholders should be in the format {key}.
|
|
5006
|
+
* @param template - The template string with placeholders
|
|
5007
|
+
* @param values - An object containing key-value pairs to replace placeholders
|
|
5008
|
+
* @returns The template string with placeholders replaced
|
|
5009
|
+
* @example
|
|
5010
|
+
* formatTemplate('Hello {name}, you are {age} years old', { name: 'John', age: 30 })
|
|
5011
|
+
* // Returns: 'Hello John, you are 30 years old'
|
|
5012
|
+
*
|
|
5013
|
+
* formatTemplate('Expected {type}, but received {actual}', { type: 'string', actual: 'number' })
|
|
5014
|
+
* // Returns: 'Expected string, but received number'
|
|
5015
|
+
*/
|
|
5016
|
+
const formatTemplate = (template, values) => {
|
|
5017
|
+
// This regex /\{(\w+)\}/g finds all placeholders in the format {word}
|
|
5018
|
+
// and captures the word inside the braces for replacement.
|
|
5019
|
+
return template.replace(/\{(\w+)\}/g, (match, key) => {
|
|
5020
|
+
return values[key] !== undefined ? String(values[key]) : match;
|
|
5021
|
+
});
|
|
4978
5022
|
};
|
|
4979
5023
|
|
|
4980
5024
|
/**
|
|
@@ -7263,6 +7307,7 @@ const ERROR_MESSAGE = {
|
|
|
7263
7307
|
SDK_NOT_INITIALIZED: 'SDK not initialized',
|
|
7264
7308
|
SESSION_INFO_FAILED: 'Failed to get session information',
|
|
7265
7309
|
INVALID_TOKEN_ERROR: 'Received invalid token from getAuthToken callback or authToken endpoint.',
|
|
7310
|
+
INVALID_TOKEN_TYPE_ERROR: 'Expected getAuthToken to return a string, but received a {invalidType}.',
|
|
7266
7311
|
MIXPANEL_TOKEN_NOT_FOUND: 'Mixpanel token not found in session info',
|
|
7267
7312
|
PRERENDER_ID_MISSING: 'PreRender ID is required for preRender',
|
|
7268
7313
|
SYNC_STYLE_CALLED_BEFORE_RENDER: 'PreRender should be called before using syncPreRenderStyle',
|
|
@@ -7443,6 +7488,15 @@ async function getAuthenticationToken(embedConfig) {
|
|
|
7443
7488
|
return authToken;
|
|
7444
7489
|
}
|
|
7445
7490
|
const validateAuthToken = async (embedConfig, authToken, suppressAlert) => {
|
|
7491
|
+
// even if token verification is disabled, we will still validate
|
|
7492
|
+
// that the token is a string before proceeding.
|
|
7493
|
+
if (typeof authToken !== 'string') {
|
|
7494
|
+
const errorMessage = formatTemplate(ERROR_MESSAGE.INVALID_TOKEN_TYPE_ERROR, {
|
|
7495
|
+
invalidType: typeof authToken,
|
|
7496
|
+
});
|
|
7497
|
+
logger$3.error(errorMessage);
|
|
7498
|
+
throw new Error(errorMessage);
|
|
7499
|
+
}
|
|
7446
7500
|
const cachedAuthToken = getCacheAuthToken();
|
|
7447
7501
|
if (embedConfig.disableTokenVerification) {
|
|
7448
7502
|
logger$3.info('Token verification is disabled. Assuming token is valid.');
|
|
@@ -8171,7 +8225,7 @@ class AnswerService {
|
|
|
8171
8225
|
async getTML() {
|
|
8172
8226
|
const { object } = await this.executeQuery(getAnswerTML, {});
|
|
8173
8227
|
const edoc = object[0].edoc;
|
|
8174
|
-
const YAML = await import('./index-
|
|
8228
|
+
const YAML = await import('./index-DQueHwfQ.js');
|
|
8175
8229
|
const parsedDoc = YAML.parse(edoc);
|
|
8176
8230
|
return {
|
|
8177
8231
|
answer: {
|
|
@@ -17344,7 +17398,7 @@ function processEventData(type, e, thoughtSpotHost, containerEl) {
|
|
|
17344
17398
|
return e;
|
|
17345
17399
|
}
|
|
17346
17400
|
|
|
17347
|
-
var name="@thoughtspot/visual-embed-sdk";var version$1="1.41.
|
|
17401
|
+
var name="@thoughtspot/visual-embed-sdk";var version$1="1.41.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 . --incremental false; tsc -p . --incremental false --module commonjs --outDir cjs","build-and-publish":"npm run build:gatsby && npm run publish","bundle-dts-file":"dts-bundle --name @thoughtspot/visual-embed-sdk --out visual-embed-sdk.d.ts --main lib/src/index.d.ts","bundle-dts":"dts-bundle --name ../../dist/visual-embed-sdk --main lib/src/index.d.ts --outputAsModuleFolder=true","bundle-dts-react":"dts-bundle --name ../../../dist/visual-embed-sdk-react --main lib/src/react/index.d.ts --outputAsModuleFolder=true","bundle-dts-react-full":"dts-bundle --name ../../../dist/visual-embed-sdk-react-full --main lib/src/react/all-types-export.d.ts --outputAsModuleFolder=true",build:"rollup -c",watch:"rollup -cw",docgen:"typedoc --tsconfig tsconfig.json --theme typedoc-theme --json static/typedoc/typedoc.json --disableOutputCheck","test-sdk":"jest -c jest.config.sdk.js --runInBand",test:"npm run test-sdk",posttest:"cat ./coverage/sdk/lcov.info | 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":"^0.7.3",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};
|
|
17348
17402
|
|
|
17349
17403
|
/**
|
|
17350
17404
|
* Reloads the ThoughtSpot iframe.
|
|
@@ -18538,13 +18592,17 @@ class TsEmbed {
|
|
|
18538
18592
|
* Creates the preRender shell
|
|
18539
18593
|
* @param showPreRenderByDefault - Show the preRender after render, hidden by default
|
|
18540
18594
|
*/
|
|
18541
|
-
async preRender(showPreRenderByDefault = false) {
|
|
18595
|
+
async preRender(showPreRenderByDefault = false, replaceExistingPreRender = false) {
|
|
18542
18596
|
if (!this.viewConfig.preRenderId) {
|
|
18543
18597
|
logger$3.error(ERROR_MESSAGE.PRERENDER_ID_MISSING);
|
|
18544
18598
|
return this;
|
|
18545
18599
|
}
|
|
18546
18600
|
this.isPreRendered = true;
|
|
18547
18601
|
this.showPreRenderByDefault = showPreRenderByDefault;
|
|
18602
|
+
const isAlreadyRendered = this.connectPreRendered();
|
|
18603
|
+
if (isAlreadyRendered && !replaceExistingPreRender) {
|
|
18604
|
+
return this;
|
|
18605
|
+
}
|
|
18548
18606
|
return this.handleRenderForPrerender();
|
|
18549
18607
|
}
|
|
18550
18608
|
/**
|
|
@@ -19045,7 +19103,7 @@ let SearchEmbed$1 = class SearchEmbed extends TsEmbed {
|
|
|
19045
19103
|
}
|
|
19046
19104
|
getEmbedParams() {
|
|
19047
19105
|
var _a;
|
|
19048
|
-
const { hideResults, enableSearchAssist, forceTable, searchOptions, runtimeFilters, dataSource, dataSources, excludeRuntimeFiltersfromURL, hideSearchBar, dataPanelV2 =
|
|
19106
|
+
const { hideResults, enableSearchAssist, forceTable, searchOptions, runtimeFilters, dataSource, dataSources, excludeRuntimeFiltersfromURL, hideSearchBar, dataPanelV2 = true, useLastSelectedSources = false, runtimeParameters, collapseSearchBarInitially = false, enableCustomColumnGroups = false, isOnBeforeGetVizDataInterceptEnabled = false,
|
|
19049
19107
|
/* eslint-disable-next-line max-len */
|
|
19050
19108
|
dataPanelCustomGroupsAccordionInitialState = DataPanelCustomColumnGroupsAccordionState$1.EXPAND_ALL, focusSearchBarOnRender = true, excludeRuntimeParametersfromURL, excludeSearchTokenStringFromURL, collapseSearchBar = true, } = this.viewConfig;
|
|
19051
19109
|
const queryParams = this.getBaseQueryParams();
|
|
@@ -19339,7 +19397,7 @@ let AppEmbed$1 = class AppEmbed extends V1Embed {
|
|
|
19339
19397
|
* embedded Liveboard or visualization.
|
|
19340
19398
|
*/
|
|
19341
19399
|
getEmbedParams() {
|
|
19342
|
-
const { tag, hideObjects, liveboardV2, showPrimaryNavbar, disableProfileAndHelp, hideHamburger, hideObjectSearch, hideNotification, hideApplicationSwitcher, hideOrgSwitcher, enableSearchAssist, fullHeight, dataPanelV2 =
|
|
19400
|
+
const { tag, 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, isOnBeforeGetVizDataInterceptEnabled = false, dataPanelCustomGroupsAccordionInitialState = DataPanelCustomColumnGroupsAccordionState.EXPAND_ALL, collapseSearchBar = true, isLiveboardCompactHeaderEnabled = false, showLiveboardVerifiedBadge = true, showLiveboardReverifyBanner = true, hideIrrelevantChipsInLiveboardTabs = false, homePageSearchBarMode, isUnifiedSearchExperienceEnabled = true, enablePendoHelp = true, discoveryExperience, coverAndFilterOptionInPDF = false, liveboardXLSXCSVDownload = false, isLiveboardStylingAndGroupingEnabled, isPNGInScheduledEmailsEnabled = false, } = this.viewConfig;
|
|
19343
19401
|
let params = {};
|
|
19344
19402
|
params[Param.PrimaryNavHidden] = !showPrimaryNavbar;
|
|
19345
19403
|
params[Param.HideProfleAndHelp] = !!disableProfileAndHelp;
|
|
@@ -19404,6 +19462,9 @@ let AppEmbed$1 = class AppEmbed extends V1Embed {
|
|
|
19404
19462
|
if (isLiveboardStylingAndGroupingEnabled !== undefined) {
|
|
19405
19463
|
params[Param.IsLiveboardStylingAndGroupingEnabled] = isLiveboardStylingAndGroupingEnabled;
|
|
19406
19464
|
}
|
|
19465
|
+
if (isPNGInScheduledEmailsEnabled !== undefined) {
|
|
19466
|
+
params[Param.isPNGInScheduledEmailsEnabled] = isPNGInScheduledEmailsEnabled;
|
|
19467
|
+
}
|
|
19407
19468
|
params[Param.DataPanelV2Enabled] = dataPanelV2;
|
|
19408
19469
|
params[Param.HideHomepageLeftNav] = hideHomepageLeftNav;
|
|
19409
19470
|
params[Param.ModularHomeExperienceEnabled] = modularHomeExperience;
|
|
@@ -19753,7 +19814,7 @@ let LiveboardEmbed$1 = class LiveboardEmbed extends V1Embed {
|
|
|
19753
19814
|
getEmbedParams() {
|
|
19754
19815
|
let params = {};
|
|
19755
19816
|
params = this.getBaseQueryParams(params);
|
|
19756
|
-
const { enableVizTransformations, fullHeight, defaultHeight, visibleVizs, liveboardV2, vizId, hideTabPanel, activeTabId, hideLiveboardHeader, showLiveboardDescription, showLiveboardTitle, isLiveboardHeaderSticky = true, isLiveboardCompactHeaderEnabled = false, showLiveboardVerifiedBadge = true, showLiveboardReverifyBanner = true, hideIrrelevantChipsInLiveboardTabs = false, enableAskSage, enable2ColumnLayout, dataPanelV2 =
|
|
19817
|
+
const { enableVizTransformations, fullHeight, defaultHeight, visibleVizs, liveboardV2, vizId, hideTabPanel, activeTabId, hideLiveboardHeader, showLiveboardDescription, showLiveboardTitle, isLiveboardHeaderSticky = true, isLiveboardCompactHeaderEnabled = false, showLiveboardVerifiedBadge = true, showLiveboardReverifyBanner = true, hideIrrelevantChipsInLiveboardTabs = false, enableAskSage, enable2ColumnLayout, dataPanelV2 = true, enableCustomColumnGroups = false, oAuthPollingInterval, isForceRedirect, dataSourceId, coverAndFilterOptionInPDF = false, liveboardXLSXCSVDownload = false, isLiveboardStylingAndGroupingEnabled, isPNGInScheduledEmailsEnabled = false, showSpotterLimitations, } = this.viewConfig;
|
|
19757
19818
|
const preventLiveboardFilterRemoval = this.viewConfig.preventLiveboardFilterRemoval
|
|
19758
19819
|
|| this.viewConfig.preventPinboardFilterRemoval;
|
|
19759
19820
|
if (fullHeight === true) {
|
|
@@ -19812,6 +19873,12 @@ let LiveboardEmbed$1 = class LiveboardEmbed extends V1Embed {
|
|
|
19812
19873
|
if (isLiveboardStylingAndGroupingEnabled !== undefined) {
|
|
19813
19874
|
params[Param.IsLiveboardStylingAndGroupingEnabled] = isLiveboardStylingAndGroupingEnabled;
|
|
19814
19875
|
}
|
|
19876
|
+
if (isPNGInScheduledEmailsEnabled !== undefined) {
|
|
19877
|
+
params[Param.isPNGInScheduledEmailsEnabled] = isPNGInScheduledEmailsEnabled;
|
|
19878
|
+
}
|
|
19879
|
+
if (showSpotterLimitations !== undefined) {
|
|
19880
|
+
params[Param.ShowSpotterLimitations] = showSpotterLimitations;
|
|
19881
|
+
}
|
|
19815
19882
|
params[Param.LiveboardHeaderSticky] = isLiveboardHeaderSticky;
|
|
19816
19883
|
params[Param.LiveboardHeaderV2] = isLiveboardCompactHeaderEnabled;
|
|
19817
19884
|
params[Param.ShowLiveboardVerifiedBadge] = showLiveboardVerifiedBadge;
|
|
@@ -20673,7 +20740,8 @@ isPreRenderedComponent = false) => React__default.forwardRef((props, forwardedRe
|
|
|
20673
20740
|
handleDestroy(tsEmbed);
|
|
20674
20741
|
};
|
|
20675
20742
|
}, [viewConfig, listeners]);
|
|
20676
|
-
|
|
20743
|
+
const preRenderStyles = isPreRenderedComponent ? { display: 'none' } : {};
|
|
20744
|
+
return viewConfig.insertAsSibling ? (React__default.createElement("span", { "data-testid": "tsEmbed", ref: ref, style: { position: 'absolute', ...preRenderStyles } })) : (React__default.createElement("div", { "data-testid": "tsEmbed", ref: ref, style: { ...style, ...preRenderStyles }, className: `ts-embed-container ${className}` }));
|
|
20677
20745
|
});
|
|
20678
20746
|
/**
|
|
20679
20747
|
* React component for Search Embed.
|
package/dist/tsembed-react.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* @thoughtspot/visual-embed-sdk version 1.41.
|
|
1
|
+
/* @thoughtspot/visual-embed-sdk version 1.41.1 */
|
|
2
2
|
'use client';
|
|
3
3
|
(function (global, factory) {
|
|
4
4
|
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('react')) :
|
|
@@ -2636,7 +2636,7 @@
|
|
|
2636
2636
|
* column: "Date",
|
|
2637
2637
|
* oper: 'EQ',
|
|
2638
2638
|
* values: ["2023-07-31"],
|
|
2639
|
-
*
|
|
2639
|
+
* type: "EXACT_DATE"
|
|
2640
2640
|
* }]
|
|
2641
2641
|
* });
|
|
2642
2642
|
* ```
|
|
@@ -3128,6 +3128,7 @@
|
|
|
3128
3128
|
Param["IsLazyLoadingForEmbedEnabled"] = "isLazyLoadingForEmbedEnabled";
|
|
3129
3129
|
Param["RootMarginForLazyLoad"] = "rootMarginForLazyLoad";
|
|
3130
3130
|
Param["LiveboardXLSXCSVDownload"] = "isLiveboardXLSXCSVDownloadEnabled";
|
|
3131
|
+
Param["isPNGInScheduledEmailsEnabled"] = "isPNGInScheduledEmailsEnabled";
|
|
3131
3132
|
})(Param || (Param = {}));
|
|
3132
3133
|
/**
|
|
3133
3134
|
* ThoughtSpot application pages include actions and menu commands
|
|
@@ -4409,6 +4410,29 @@
|
|
|
4409
4410
|
* @version SDK: 1.41.0 | ThoughtSpot Cloud: 10.13.0.cl
|
|
4410
4411
|
*/
|
|
4411
4412
|
Action["SpotterTokenQuickEdit"] = "SpotterTokenQuickEdit";
|
|
4413
|
+
/**
|
|
4414
|
+
* The **PNG screenshot in email** option in the schedule email dialog.
|
|
4415
|
+
* Includes a PNG screenshot in the notification email body.
|
|
4416
|
+
* @example
|
|
4417
|
+
* ```js
|
|
4418
|
+
* disabledActions: [Action.PngScreenshotInEmail]
|
|
4419
|
+
* ```
|
|
4420
|
+
* ```
|
|
4421
|
+
* @version SDK: 1.42.0 | ThoughtSpot Cloud: 10.14.0.cl
|
|
4422
|
+
*/
|
|
4423
|
+
Action["PngScreenshotInEmail"] = "pngScreenshotInEmail";
|
|
4424
|
+
/**
|
|
4425
|
+
* The **Remove attachment** action in the schedule email dialog.
|
|
4426
|
+
* Removes an attachment from the email configuration.
|
|
4427
|
+
* @example
|
|
4428
|
+
* ```js
|
|
4429
|
+
* disabledActions: [Action.RemoveAttachment]
|
|
4430
|
+
* ```
|
|
4431
|
+
* ```
|
|
4432
|
+
* ```
|
|
4433
|
+
* @version SDK: 1.42.0 | ThoughtSpot Cloud: 10.14.0.cl
|
|
4434
|
+
*/
|
|
4435
|
+
Action["RemoveAttachment"] = "removeAttachment";
|
|
4412
4436
|
})(exports.Action || (exports.Action = {}));
|
|
4413
4437
|
var PrefetchFeatures;
|
|
4414
4438
|
(function (PrefetchFeatures) {
|
|
@@ -4997,6 +5021,26 @@
|
|
|
4997
5021
|
width: Math.max(0, frameRelativeRight - frameRelativeLeft),
|
|
4998
5022
|
};
|
|
4999
5023
|
return data;
|
|
5024
|
+
};
|
|
5025
|
+
/**
|
|
5026
|
+
* Replaces placeholders in a template string with provided values.
|
|
5027
|
+
* Placeholders should be in the format {key}.
|
|
5028
|
+
* @param template - The template string with placeholders
|
|
5029
|
+
* @param values - An object containing key-value pairs to replace placeholders
|
|
5030
|
+
* @returns The template string with placeholders replaced
|
|
5031
|
+
* @example
|
|
5032
|
+
* formatTemplate('Hello {name}, you are {age} years old', { name: 'John', age: 30 })
|
|
5033
|
+
* // Returns: 'Hello John, you are 30 years old'
|
|
5034
|
+
*
|
|
5035
|
+
* formatTemplate('Expected {type}, but received {actual}', { type: 'string', actual: 'number' })
|
|
5036
|
+
* // Returns: 'Expected string, but received number'
|
|
5037
|
+
*/
|
|
5038
|
+
const formatTemplate = (template, values) => {
|
|
5039
|
+
// This regex /\{(\w+)\}/g finds all placeholders in the format {word}
|
|
5040
|
+
// and captures the word inside the braces for replacement.
|
|
5041
|
+
return template.replace(/\{(\w+)\}/g, (match, key) => {
|
|
5042
|
+
return values[key] !== undefined ? String(values[key]) : match;
|
|
5043
|
+
});
|
|
5000
5044
|
};
|
|
5001
5045
|
|
|
5002
5046
|
/**
|
|
@@ -7285,6 +7329,7 @@
|
|
|
7285
7329
|
SDK_NOT_INITIALIZED: 'SDK not initialized',
|
|
7286
7330
|
SESSION_INFO_FAILED: 'Failed to get session information',
|
|
7287
7331
|
INVALID_TOKEN_ERROR: 'Received invalid token from getAuthToken callback or authToken endpoint.',
|
|
7332
|
+
INVALID_TOKEN_TYPE_ERROR: 'Expected getAuthToken to return a string, but received a {invalidType}.',
|
|
7288
7333
|
MIXPANEL_TOKEN_NOT_FOUND: 'Mixpanel token not found in session info',
|
|
7289
7334
|
PRERENDER_ID_MISSING: 'PreRender ID is required for preRender',
|
|
7290
7335
|
SYNC_STYLE_CALLED_BEFORE_RENDER: 'PreRender should be called before using syncPreRenderStyle',
|
|
@@ -7465,6 +7510,15 @@
|
|
|
7465
7510
|
return authToken;
|
|
7466
7511
|
}
|
|
7467
7512
|
const validateAuthToken = async (embedConfig, authToken, suppressAlert) => {
|
|
7513
|
+
// even if token verification is disabled, we will still validate
|
|
7514
|
+
// that the token is a string before proceeding.
|
|
7515
|
+
if (typeof authToken !== 'string') {
|
|
7516
|
+
const errorMessage = formatTemplate(ERROR_MESSAGE.INVALID_TOKEN_TYPE_ERROR, {
|
|
7517
|
+
invalidType: typeof authToken,
|
|
7518
|
+
});
|
|
7519
|
+
logger$3.error(errorMessage);
|
|
7520
|
+
throw new Error(errorMessage);
|
|
7521
|
+
}
|
|
7468
7522
|
const cachedAuthToken = getCacheAuthToken();
|
|
7469
7523
|
if (embedConfig.disableTokenVerification) {
|
|
7470
7524
|
logger$3.info('Token verification is disabled. Assuming token is valid.');
|
|
@@ -17366,7 +17420,7 @@ mutation GetUnsavedAnswerTML($session: BachSessionIdInput!, $exportDependencies:
|
|
|
17366
17420
|
return e;
|
|
17367
17421
|
}
|
|
17368
17422
|
|
|
17369
|
-
var name="@thoughtspot/visual-embed-sdk";var version$1="1.41.
|
|
17423
|
+
var name="@thoughtspot/visual-embed-sdk";var version$1="1.41.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 . --incremental false; tsc -p . --incremental false --module commonjs --outDir cjs","build-and-publish":"npm run build:gatsby && npm run publish","bundle-dts-file":"dts-bundle --name @thoughtspot/visual-embed-sdk --out visual-embed-sdk.d.ts --main lib/src/index.d.ts","bundle-dts":"dts-bundle --name ../../dist/visual-embed-sdk --main lib/src/index.d.ts --outputAsModuleFolder=true","bundle-dts-react":"dts-bundle --name ../../../dist/visual-embed-sdk-react --main lib/src/react/index.d.ts --outputAsModuleFolder=true","bundle-dts-react-full":"dts-bundle --name ../../../dist/visual-embed-sdk-react-full --main lib/src/react/all-types-export.d.ts --outputAsModuleFolder=true",build:"rollup -c",watch:"rollup -cw",docgen:"typedoc --tsconfig tsconfig.json --theme typedoc-theme --json static/typedoc/typedoc.json --disableOutputCheck","test-sdk":"jest -c jest.config.sdk.js --runInBand",test:"npm run test-sdk",posttest:"cat ./coverage/sdk/lcov.info | 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":"^0.7.3",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};
|
|
17370
17424
|
|
|
17371
17425
|
/**
|
|
17372
17426
|
* Reloads the ThoughtSpot iframe.
|
|
@@ -18560,13 +18614,17 @@ mutation GetUnsavedAnswerTML($session: BachSessionIdInput!, $exportDependencies:
|
|
|
18560
18614
|
* Creates the preRender shell
|
|
18561
18615
|
* @param showPreRenderByDefault - Show the preRender after render, hidden by default
|
|
18562
18616
|
*/
|
|
18563
|
-
async preRender(showPreRenderByDefault = false) {
|
|
18617
|
+
async preRender(showPreRenderByDefault = false, replaceExistingPreRender = false) {
|
|
18564
18618
|
if (!this.viewConfig.preRenderId) {
|
|
18565
18619
|
logger$3.error(ERROR_MESSAGE.PRERENDER_ID_MISSING);
|
|
18566
18620
|
return this;
|
|
18567
18621
|
}
|
|
18568
18622
|
this.isPreRendered = true;
|
|
18569
18623
|
this.showPreRenderByDefault = showPreRenderByDefault;
|
|
18624
|
+
const isAlreadyRendered = this.connectPreRendered();
|
|
18625
|
+
if (isAlreadyRendered && !replaceExistingPreRender) {
|
|
18626
|
+
return this;
|
|
18627
|
+
}
|
|
18570
18628
|
return this.handleRenderForPrerender();
|
|
18571
18629
|
}
|
|
18572
18630
|
/**
|
|
@@ -19067,7 +19125,7 @@ mutation GetUnsavedAnswerTML($session: BachSessionIdInput!, $exportDependencies:
|
|
|
19067
19125
|
}
|
|
19068
19126
|
getEmbedParams() {
|
|
19069
19127
|
var _a;
|
|
19070
|
-
const { hideResults, enableSearchAssist, forceTable, searchOptions, runtimeFilters, dataSource, dataSources, excludeRuntimeFiltersfromURL, hideSearchBar, dataPanelV2 =
|
|
19128
|
+
const { hideResults, enableSearchAssist, forceTable, searchOptions, runtimeFilters, dataSource, dataSources, excludeRuntimeFiltersfromURL, hideSearchBar, dataPanelV2 = true, useLastSelectedSources = false, runtimeParameters, collapseSearchBarInitially = false, enableCustomColumnGroups = false, isOnBeforeGetVizDataInterceptEnabled = false,
|
|
19071
19129
|
/* eslint-disable-next-line max-len */
|
|
19072
19130
|
dataPanelCustomGroupsAccordionInitialState = DataPanelCustomColumnGroupsAccordionState$1.EXPAND_ALL, focusSearchBarOnRender = true, excludeRuntimeParametersfromURL, excludeSearchTokenStringFromURL, collapseSearchBar = true, } = this.viewConfig;
|
|
19073
19131
|
const queryParams = this.getBaseQueryParams();
|
|
@@ -19361,7 +19419,7 @@ mutation GetUnsavedAnswerTML($session: BachSessionIdInput!, $exportDependencies:
|
|
|
19361
19419
|
* embedded Liveboard or visualization.
|
|
19362
19420
|
*/
|
|
19363
19421
|
getEmbedParams() {
|
|
19364
|
-
const { tag, hideObjects, liveboardV2, showPrimaryNavbar, disableProfileAndHelp, hideHamburger, hideObjectSearch, hideNotification, hideApplicationSwitcher, hideOrgSwitcher, enableSearchAssist, fullHeight, dataPanelV2 =
|
|
19422
|
+
const { tag, 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, isOnBeforeGetVizDataInterceptEnabled = false, dataPanelCustomGroupsAccordionInitialState = DataPanelCustomColumnGroupsAccordionState.EXPAND_ALL, collapseSearchBar = true, isLiveboardCompactHeaderEnabled = false, showLiveboardVerifiedBadge = true, showLiveboardReverifyBanner = true, hideIrrelevantChipsInLiveboardTabs = false, homePageSearchBarMode, isUnifiedSearchExperienceEnabled = true, enablePendoHelp = true, discoveryExperience, coverAndFilterOptionInPDF = false, liveboardXLSXCSVDownload = false, isLiveboardStylingAndGroupingEnabled, isPNGInScheduledEmailsEnabled = false, } = this.viewConfig;
|
|
19365
19423
|
let params = {};
|
|
19366
19424
|
params[Param.PrimaryNavHidden] = !showPrimaryNavbar;
|
|
19367
19425
|
params[Param.HideProfleAndHelp] = !!disableProfileAndHelp;
|
|
@@ -19426,6 +19484,9 @@ mutation GetUnsavedAnswerTML($session: BachSessionIdInput!, $exportDependencies:
|
|
|
19426
19484
|
if (isLiveboardStylingAndGroupingEnabled !== undefined) {
|
|
19427
19485
|
params[Param.IsLiveboardStylingAndGroupingEnabled] = isLiveboardStylingAndGroupingEnabled;
|
|
19428
19486
|
}
|
|
19487
|
+
if (isPNGInScheduledEmailsEnabled !== undefined) {
|
|
19488
|
+
params[Param.isPNGInScheduledEmailsEnabled] = isPNGInScheduledEmailsEnabled;
|
|
19489
|
+
}
|
|
19429
19490
|
params[Param.DataPanelV2Enabled] = dataPanelV2;
|
|
19430
19491
|
params[Param.HideHomepageLeftNav] = hideHomepageLeftNav;
|
|
19431
19492
|
params[Param.ModularHomeExperienceEnabled] = modularHomeExperience;
|
|
@@ -19775,7 +19836,7 @@ query GetEurekaVizSnapshots(
|
|
|
19775
19836
|
getEmbedParams() {
|
|
19776
19837
|
let params = {};
|
|
19777
19838
|
params = this.getBaseQueryParams(params);
|
|
19778
|
-
const { enableVizTransformations, fullHeight, defaultHeight, visibleVizs, liveboardV2, vizId, hideTabPanel, activeTabId, hideLiveboardHeader, showLiveboardDescription, showLiveboardTitle, isLiveboardHeaderSticky = true, isLiveboardCompactHeaderEnabled = false, showLiveboardVerifiedBadge = true, showLiveboardReverifyBanner = true, hideIrrelevantChipsInLiveboardTabs = false, enableAskSage, enable2ColumnLayout, dataPanelV2 =
|
|
19839
|
+
const { enableVizTransformations, fullHeight, defaultHeight, visibleVizs, liveboardV2, vizId, hideTabPanel, activeTabId, hideLiveboardHeader, showLiveboardDescription, showLiveboardTitle, isLiveboardHeaderSticky = true, isLiveboardCompactHeaderEnabled = false, showLiveboardVerifiedBadge = true, showLiveboardReverifyBanner = true, hideIrrelevantChipsInLiveboardTabs = false, enableAskSage, enable2ColumnLayout, dataPanelV2 = true, enableCustomColumnGroups = false, oAuthPollingInterval, isForceRedirect, dataSourceId, coverAndFilterOptionInPDF = false, liveboardXLSXCSVDownload = false, isLiveboardStylingAndGroupingEnabled, isPNGInScheduledEmailsEnabled = false, showSpotterLimitations, } = this.viewConfig;
|
|
19779
19840
|
const preventLiveboardFilterRemoval = this.viewConfig.preventLiveboardFilterRemoval
|
|
19780
19841
|
|| this.viewConfig.preventPinboardFilterRemoval;
|
|
19781
19842
|
if (fullHeight === true) {
|
|
@@ -19834,6 +19895,12 @@ query GetEurekaVizSnapshots(
|
|
|
19834
19895
|
if (isLiveboardStylingAndGroupingEnabled !== undefined) {
|
|
19835
19896
|
params[Param.IsLiveboardStylingAndGroupingEnabled] = isLiveboardStylingAndGroupingEnabled;
|
|
19836
19897
|
}
|
|
19898
|
+
if (isPNGInScheduledEmailsEnabled !== undefined) {
|
|
19899
|
+
params[Param.isPNGInScheduledEmailsEnabled] = isPNGInScheduledEmailsEnabled;
|
|
19900
|
+
}
|
|
19901
|
+
if (showSpotterLimitations !== undefined) {
|
|
19902
|
+
params[Param.ShowSpotterLimitations] = showSpotterLimitations;
|
|
19903
|
+
}
|
|
19837
19904
|
params[Param.LiveboardHeaderSticky] = isLiveboardHeaderSticky;
|
|
19838
19905
|
params[Param.LiveboardHeaderV2] = isLiveboardCompactHeaderEnabled;
|
|
19839
19906
|
params[Param.ShowLiveboardVerifiedBadge] = showLiveboardVerifiedBadge;
|
|
@@ -20695,7 +20762,8 @@ query SendMessage($params: Input_convassist_SendMessageRequest) {
|
|
|
20695
20762
|
handleDestroy(tsEmbed);
|
|
20696
20763
|
};
|
|
20697
20764
|
}, [viewConfig, listeners]);
|
|
20698
|
-
|
|
20765
|
+
const preRenderStyles = isPreRenderedComponent ? { display: 'none' } : {};
|
|
20766
|
+
return viewConfig.insertAsSibling ? (React.createElement("span", { "data-testid": "tsEmbed", ref: ref, style: { position: 'absolute', ...preRenderStyles } })) : (React.createElement("div", { "data-testid": "tsEmbed", ref: ref, style: { ...style, ...preRenderStyles }, className: `ts-embed-container ${className}` }));
|
|
20699
20767
|
});
|
|
20700
20768
|
/**
|
|
20701
20769
|
* React component for Search Embed.
|