@thoughtspot/visual-embed-sdk 1.25.0-alpha.0 → 1.25.0-alpha.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/cjs/package.json +1 -1
- package/dist/tsembed-react.es.js +1 -1
- package/dist/tsembed-react.js +1 -1
- package/dist/tsembed.es.js +1 -1
- package/dist/tsembed.js +1 -1
- package/lib/package.json +1 -1
- package/package.json +1 -1
- package/cjs/src/utils/answerService/answerService.d.ts +0 -34
- package/cjs/src/utils/answerService/answerService.d.ts.map +0 -1
- package/cjs/src/utils/answerService/answerService.js +0 -142
- package/cjs/src/utils/answerService/answerService.js.map +0 -1
- package/cjs/src/utils/answerService/answerService.spec.d.ts +0 -1
- package/cjs/src/utils/answerService/answerService.spec.d.ts.map +0 -1
- package/cjs/src/utils/answerService/answerService.spec.js +0 -1
- package/cjs/src/utils/answerService/answerService.spec.js.map +0 -1
- package/cjs/src/utils/answerService/graphql-queries.d.ts +0 -6
- package/cjs/src/utils/answerService/graphql-queries.d.ts.map +0 -1
- package/cjs/src/utils/answerService/graphql-queries.js +0 -123
- package/cjs/src/utils/answerService/graphql-queries.js.map +0 -1
- package/cjs/src/utils/graphql/answerService/graphql-queries.d.ts +0 -5
- package/cjs/src/utils/graphql/answerService/graphql-queries.d.ts.map +0 -1
- package/cjs/src/utils/graphql/answerService/graphql-queries.js +0 -80
- package/cjs/src/utils/graphql/answerService/graphql-queries.js.map +0 -1
- package/lib/src/.index.d.ts.swp +0 -0
- package/lib/src/utils/answerService/answerService.d.ts +0 -34
- package/lib/src/utils/answerService/answerService.d.ts.map +0 -1
- package/lib/src/utils/answerService/answerService.js +0 -137
- package/lib/src/utils/answerService/answerService.js.map +0 -1
- package/lib/src/utils/answerService/answerService.spec.d.ts +0 -1
- package/lib/src/utils/answerService/answerService.spec.d.ts.map +0 -1
- package/lib/src/utils/answerService/answerService.spec.js +0 -1
- package/lib/src/utils/answerService/answerService.spec.js.map +0 -1
- package/lib/src/utils/answerService/graphql-queries.d.ts +0 -6
- package/lib/src/utils/answerService/graphql-queries.d.ts.map +0 -1
- package/lib/src/utils/answerService/graphql-queries.js +0 -120
- package/lib/src/utils/answerService/graphql-queries.js.map +0 -1
- package/lib/src/utils/graphql/answerService/graphql-queries.d.ts +0 -5
- package/lib/src/utils/graphql/answerService/graphql-queries.d.ts.map +0 -1
- package/lib/src/utils/graphql/answerService/graphql-queries.js +0 -77
- package/lib/src/utils/graphql/answerService/graphql-queries.js.map +0 -1
package/cjs/package.json
CHANGED
package/dist/tsembed-react.es.js
CHANGED
|
@@ -10704,7 +10704,7 @@ function processTrigger(iFrame, messageType, thoughtSpotHost, data) {
|
|
|
10704
10704
|
});
|
|
10705
10705
|
}
|
|
10706
10706
|
|
|
10707
|
-
var name="@thoughtspot/visual-embed-sdk";var version="1.25.0-alpha.
|
|
10707
|
+
var name="@thoughtspot/visual-embed-sdk";var version="1.25.0-alpha.2";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",start:"gatsby develop","build:gatsby":"npm run clean:gatsby && gatsby build --prefix-paths","build:gatsby:noprefix":"npm run clean:gatsby && gatsby build","serve:gatsby":"gatsby serve","clean:gatsby":"gatsby clean","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","docs-cmd":"node scripts/gatsby-commands.js",docgen:"typedoc --tsconfig tsconfig.json --theme typedoc-theme","test-sdk":"jest -c jest.config.sdk.js --runInBand","test-docs":"jest -c jest.config.docs.js",test:"npm run test-sdk && npm run test-docs",posttest:"cat ./coverage/sdk/lcov.info | coveralls","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"};var peerDependencies={react:"> 16.8.0","react-dom":"> 16.8.0"};var dependencies={algoliasearch:"^4.10.5",classnames:"^2.3.1",dompurify:"^2.3.4","eslint-plugin-comment-length":"^0.9.2","eslint-plugin-jsdoc":"^40.1.0",eventemitter3:"^4.0.7","gatsby-plugin-vercel":"^1.0.3","html-react-parser":"^1.4.12",lodash:"^4.17.21","mixpanel-browser":"^2.45.0","ts-deepmerge":"^6.0.2",tslib:"^2.5.3","use-deep-compare-effect":"^1.8.1"};var devDependencies={"@mdx-js/mdx":"^1.6.22","@mdx-js/react":"^1.6.22","@react-icons/all-files":"^4.1.0","@rollup/plugin-commonjs":"^18.0.0","@rollup/plugin-json":"^4.1.0","@rollup/plugin-node-resolve":"^11.2.1","@rollup/plugin-replace":"^5.0.2","@size-limit/preset-big-lib":"^8.2.6","@testing-library/dom":"^7.31.0","@testing-library/jest-dom":"^5.14.1","@testing-library/react":"^11.2.7","@testing-library/user-event":"^13.1.8","@types/jest":"^22.2.3","@types/mixpanel-browser":"^2.35.6","@types/react-test-renderer":"^17.0.1","@typescript-eslint/eslint-plugin":"^4.6.0","@typescript-eslint/parser":"^4.6.0",asciidoctor:"^2.2.1","babel-jest":"^26.6.3","babel-preset-gatsby":"^1.10.0","command-line-args":"^5.1.1",coveralls:"^3.1.0","current-git-branch":"^1.1.0","dts-bundle":"^0.7.3",eslint:"^7.12.1","eslint-config-airbnb-base":"^14.2.0","eslint-config-prettier":"^6.15.0","eslint-import-resolver-typescript":"^2.3.0","eslint-plugin-import":"^2.22.1","eslint-plugin-prettier":"^3.1.4","eslint-plugin-react-hooks":"^4.2.0","fs-extra":"^10.0.0",gatsby:"3.13.1","gatsby-plugin-algolia":"^0.22.2","gatsby-plugin-catch-links":"^3.1.0","gatsby-plugin-env-variables":"^2.1.0","gatsby-plugin-intl":"^0.3.3","gatsby-plugin-manifest":"^3.2.0","gatsby-plugin-output":"^0.1.3","gatsby-plugin-sass":"6.7.0","gatsby-plugin-sitemap":"^4.10.0","gatsby-source-filesystem":"3.1.0","gatsby-transformer-asciidoc":"2.1.0","gatsby-transformer-rehype":"2.0.0","gh-pages":"^3.1.0","highlight.js":"^10.6.0","html-to-text":"^8.0.0","identity-obj-proxy":"^3.0.0","istanbul-merge":"^1.1.1",jest:"^26.6.3","jest-fetch-mock":"^3.0.3",jsdom:"^17.0.0","node-sass":"^8.0.0",prettier:"2.1.2",react:"^16.14.0","react-dom":"^16.14.0","react-resizable":"^1.11.0","react-resize-detector":"^6.6.0","react-test-renderer":"^17.0.2","react-use-flexsearch":"^0.1.1",rollup:"2.30.0","rollup-plugin-typescript2":"0.27.3","ts-jest":"^26.5.5","ts-loader":"8.0.4",typedoc:"0.21.6","typedoc-plugin-toc-group":"thoughtspot/typedoc-plugin-toc-group",typescript:"^4.9.4","url-search-params-polyfill":"^8.1.0",util:"^0.12.4"};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","embed","sdk","analytics"];var bugs={url:"https://github.com/thoughtspot/visual-embed-sdk/issues"};var homepage="https://github.com/thoughtspot/visual-embed-sdk#readme";var globals={window:{}};var pkgInfo = {name:name,version:version,description:description,module:module,main:main,types:types,files:files,exports:exports,typesVersions:typesVersions,"size-limit":[{path:"dist/tsembed.js",limit:"40 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};
|
|
10708
10708
|
|
|
10709
10709
|
/**
|
|
10710
10710
|
* Copyright (c) 2022
|
package/dist/tsembed-react.js
CHANGED
|
@@ -10626,7 +10626,7 @@ mutation RemoveColumns($session: BachSessionIdInput!, $logicalColumnIds: [GUID!]
|
|
|
10626
10626
|
});
|
|
10627
10627
|
}
|
|
10628
10628
|
|
|
10629
|
-
var name="@thoughtspot/visual-embed-sdk";var version="1.25.0-alpha.
|
|
10629
|
+
var name="@thoughtspot/visual-embed-sdk";var version="1.25.0-alpha.2";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",start:"gatsby develop","build:gatsby":"npm run clean:gatsby && gatsby build --prefix-paths","build:gatsby:noprefix":"npm run clean:gatsby && gatsby build","serve:gatsby":"gatsby serve","clean:gatsby":"gatsby clean","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","docs-cmd":"node scripts/gatsby-commands.js",docgen:"typedoc --tsconfig tsconfig.json --theme typedoc-theme","test-sdk":"jest -c jest.config.sdk.js --runInBand","test-docs":"jest -c jest.config.docs.js",test:"npm run test-sdk && npm run test-docs",posttest:"cat ./coverage/sdk/lcov.info | coveralls","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"};var peerDependencies={react:"> 16.8.0","react-dom":"> 16.8.0"};var dependencies={algoliasearch:"^4.10.5",classnames:"^2.3.1",dompurify:"^2.3.4","eslint-plugin-comment-length":"^0.9.2","eslint-plugin-jsdoc":"^40.1.0",eventemitter3:"^4.0.7","gatsby-plugin-vercel":"^1.0.3","html-react-parser":"^1.4.12",lodash:"^4.17.21","mixpanel-browser":"^2.45.0","ts-deepmerge":"^6.0.2",tslib:"^2.5.3","use-deep-compare-effect":"^1.8.1"};var devDependencies={"@mdx-js/mdx":"^1.6.22","@mdx-js/react":"^1.6.22","@react-icons/all-files":"^4.1.0","@rollup/plugin-commonjs":"^18.0.0","@rollup/plugin-json":"^4.1.0","@rollup/plugin-node-resolve":"^11.2.1","@rollup/plugin-replace":"^5.0.2","@size-limit/preset-big-lib":"^8.2.6","@testing-library/dom":"^7.31.0","@testing-library/jest-dom":"^5.14.1","@testing-library/react":"^11.2.7","@testing-library/user-event":"^13.1.8","@types/jest":"^22.2.3","@types/mixpanel-browser":"^2.35.6","@types/react-test-renderer":"^17.0.1","@typescript-eslint/eslint-plugin":"^4.6.0","@typescript-eslint/parser":"^4.6.0",asciidoctor:"^2.2.1","babel-jest":"^26.6.3","babel-preset-gatsby":"^1.10.0","command-line-args":"^5.1.1",coveralls:"^3.1.0","current-git-branch":"^1.1.0","dts-bundle":"^0.7.3",eslint:"^7.12.1","eslint-config-airbnb-base":"^14.2.0","eslint-config-prettier":"^6.15.0","eslint-import-resolver-typescript":"^2.3.0","eslint-plugin-import":"^2.22.1","eslint-plugin-prettier":"^3.1.4","eslint-plugin-react-hooks":"^4.2.0","fs-extra":"^10.0.0",gatsby:"3.13.1","gatsby-plugin-algolia":"^0.22.2","gatsby-plugin-catch-links":"^3.1.0","gatsby-plugin-env-variables":"^2.1.0","gatsby-plugin-intl":"^0.3.3","gatsby-plugin-manifest":"^3.2.0","gatsby-plugin-output":"^0.1.3","gatsby-plugin-sass":"6.7.0","gatsby-plugin-sitemap":"^4.10.0","gatsby-source-filesystem":"3.1.0","gatsby-transformer-asciidoc":"2.1.0","gatsby-transformer-rehype":"2.0.0","gh-pages":"^3.1.0","highlight.js":"^10.6.0","html-to-text":"^8.0.0","identity-obj-proxy":"^3.0.0","istanbul-merge":"^1.1.1",jest:"^26.6.3","jest-fetch-mock":"^3.0.3",jsdom:"^17.0.0","node-sass":"^8.0.0",prettier:"2.1.2",react:"^16.14.0","react-dom":"^16.14.0","react-resizable":"^1.11.0","react-resize-detector":"^6.6.0","react-test-renderer":"^17.0.2","react-use-flexsearch":"^0.1.1",rollup:"2.30.0","rollup-plugin-typescript2":"0.27.3","ts-jest":"^26.5.5","ts-loader":"8.0.4",typedoc:"0.21.6","typedoc-plugin-toc-group":"thoughtspot/typedoc-plugin-toc-group",typescript:"^4.9.4","url-search-params-polyfill":"^8.1.0",util:"^0.12.4"};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","embed","sdk","analytics"];var bugs={url:"https://github.com/thoughtspot/visual-embed-sdk/issues"};var homepage="https://github.com/thoughtspot/visual-embed-sdk#readme";var globals={window:{}};var pkgInfo = {name:name,version:version,description:description,module:module,main:main,types:types,files:files,exports:exports$1,typesVersions:typesVersions,"size-limit":[{path:"dist/tsembed.js",limit:"40 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};
|
|
10630
10630
|
|
|
10631
10631
|
/**
|
|
10632
10632
|
* Copyright (c) 2022
|
package/dist/tsembed.es.js
CHANGED
|
@@ -11611,7 +11611,7 @@ function processTrigger(iFrame, messageType, thoughtSpotHost, data) {
|
|
|
11611
11611
|
});
|
|
11612
11612
|
}
|
|
11613
11613
|
|
|
11614
|
-
var name="@thoughtspot/visual-embed-sdk";var version="1.25.0-alpha.
|
|
11614
|
+
var name="@thoughtspot/visual-embed-sdk";var version="1.25.0-alpha.2";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",start:"gatsby develop","build:gatsby":"npm run clean:gatsby && gatsby build --prefix-paths","build:gatsby:noprefix":"npm run clean:gatsby && gatsby build","serve:gatsby":"gatsby serve","clean:gatsby":"gatsby clean","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","docs-cmd":"node scripts/gatsby-commands.js",docgen:"typedoc --tsconfig tsconfig.json --theme typedoc-theme","test-sdk":"jest -c jest.config.sdk.js --runInBand","test-docs":"jest -c jest.config.docs.js",test:"npm run test-sdk && npm run test-docs",posttest:"cat ./coverage/sdk/lcov.info | coveralls","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"};var peerDependencies={react:"> 16.8.0","react-dom":"> 16.8.0"};var dependencies={algoliasearch:"^4.10.5",classnames:"^2.3.1",dompurify:"^2.3.4","eslint-plugin-comment-length":"^0.9.2","eslint-plugin-jsdoc":"^40.1.0",eventemitter3:"^4.0.7","gatsby-plugin-vercel":"^1.0.3","html-react-parser":"^1.4.12",lodash:"^4.17.21","mixpanel-browser":"^2.45.0","ts-deepmerge":"^6.0.2",tslib:"^2.5.3","use-deep-compare-effect":"^1.8.1"};var devDependencies={"@mdx-js/mdx":"^1.6.22","@mdx-js/react":"^1.6.22","@react-icons/all-files":"^4.1.0","@rollup/plugin-commonjs":"^18.0.0","@rollup/plugin-json":"^4.1.0","@rollup/plugin-node-resolve":"^11.2.1","@rollup/plugin-replace":"^5.0.2","@size-limit/preset-big-lib":"^8.2.6","@testing-library/dom":"^7.31.0","@testing-library/jest-dom":"^5.14.1","@testing-library/react":"^11.2.7","@testing-library/user-event":"^13.1.8","@types/jest":"^22.2.3","@types/mixpanel-browser":"^2.35.6","@types/react-test-renderer":"^17.0.1","@typescript-eslint/eslint-plugin":"^4.6.0","@typescript-eslint/parser":"^4.6.0",asciidoctor:"^2.2.1","babel-jest":"^26.6.3","babel-preset-gatsby":"^1.10.0","command-line-args":"^5.1.1",coveralls:"^3.1.0","current-git-branch":"^1.1.0","dts-bundle":"^0.7.3",eslint:"^7.12.1","eslint-config-airbnb-base":"^14.2.0","eslint-config-prettier":"^6.15.0","eslint-import-resolver-typescript":"^2.3.0","eslint-plugin-import":"^2.22.1","eslint-plugin-prettier":"^3.1.4","eslint-plugin-react-hooks":"^4.2.0","fs-extra":"^10.0.0",gatsby:"3.13.1","gatsby-plugin-algolia":"^0.22.2","gatsby-plugin-catch-links":"^3.1.0","gatsby-plugin-env-variables":"^2.1.0","gatsby-plugin-intl":"^0.3.3","gatsby-plugin-manifest":"^3.2.0","gatsby-plugin-output":"^0.1.3","gatsby-plugin-sass":"6.7.0","gatsby-plugin-sitemap":"^4.10.0","gatsby-source-filesystem":"3.1.0","gatsby-transformer-asciidoc":"2.1.0","gatsby-transformer-rehype":"2.0.0","gh-pages":"^3.1.0","highlight.js":"^10.6.0","html-to-text":"^8.0.0","identity-obj-proxy":"^3.0.0","istanbul-merge":"^1.1.1",jest:"^26.6.3","jest-fetch-mock":"^3.0.3",jsdom:"^17.0.0","node-sass":"^8.0.0",prettier:"2.1.2",react:"^16.14.0","react-dom":"^16.14.0","react-resizable":"^1.11.0","react-resize-detector":"^6.6.0","react-test-renderer":"^17.0.2","react-use-flexsearch":"^0.1.1",rollup:"2.30.0","rollup-plugin-typescript2":"0.27.3","ts-jest":"^26.5.5","ts-loader":"8.0.4",typedoc:"0.21.6","typedoc-plugin-toc-group":"thoughtspot/typedoc-plugin-toc-group",typescript:"^4.9.4","url-search-params-polyfill":"^8.1.0",util:"^0.12.4"};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","embed","sdk","analytics"];var bugs={url:"https://github.com/thoughtspot/visual-embed-sdk/issues"};var homepage="https://github.com/thoughtspot/visual-embed-sdk#readme";var globals={window:{}};var pkgInfo = {name:name,version:version,description:description,module:module,main:main,types:types,files:files,exports:exports,typesVersions:typesVersions,"size-limit":[{path:"dist/tsembed.js",limit:"40 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};
|
|
11615
11615
|
|
|
11616
11616
|
/**
|
|
11617
11617
|
* Copyright (c) 2022
|
package/dist/tsembed.js
CHANGED
|
@@ -11493,7 +11493,7 @@ mutation RemoveColumns($session: BachSessionIdInput!, $logicalColumnIds: [GUID!]
|
|
|
11493
11493
|
});
|
|
11494
11494
|
}
|
|
11495
11495
|
|
|
11496
|
-
var name="@thoughtspot/visual-embed-sdk";var version="1.25.0-alpha.
|
|
11496
|
+
var name="@thoughtspot/visual-embed-sdk";var version="1.25.0-alpha.2";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",start:"gatsby develop","build:gatsby":"npm run clean:gatsby && gatsby build --prefix-paths","build:gatsby:noprefix":"npm run clean:gatsby && gatsby build","serve:gatsby":"gatsby serve","clean:gatsby":"gatsby clean","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","docs-cmd":"node scripts/gatsby-commands.js",docgen:"typedoc --tsconfig tsconfig.json --theme typedoc-theme","test-sdk":"jest -c jest.config.sdk.js --runInBand","test-docs":"jest -c jest.config.docs.js",test:"npm run test-sdk && npm run test-docs",posttest:"cat ./coverage/sdk/lcov.info | coveralls","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"};var peerDependencies={react:"> 16.8.0","react-dom":"> 16.8.0"};var dependencies={algoliasearch:"^4.10.5",classnames:"^2.3.1",dompurify:"^2.3.4","eslint-plugin-comment-length":"^0.9.2","eslint-plugin-jsdoc":"^40.1.0",eventemitter3:"^4.0.7","gatsby-plugin-vercel":"^1.0.3","html-react-parser":"^1.4.12",lodash:"^4.17.21","mixpanel-browser":"^2.45.0","ts-deepmerge":"^6.0.2",tslib:"^2.5.3","use-deep-compare-effect":"^1.8.1"};var devDependencies={"@mdx-js/mdx":"^1.6.22","@mdx-js/react":"^1.6.22","@react-icons/all-files":"^4.1.0","@rollup/plugin-commonjs":"^18.0.0","@rollup/plugin-json":"^4.1.0","@rollup/plugin-node-resolve":"^11.2.1","@rollup/plugin-replace":"^5.0.2","@size-limit/preset-big-lib":"^8.2.6","@testing-library/dom":"^7.31.0","@testing-library/jest-dom":"^5.14.1","@testing-library/react":"^11.2.7","@testing-library/user-event":"^13.1.8","@types/jest":"^22.2.3","@types/mixpanel-browser":"^2.35.6","@types/react-test-renderer":"^17.0.1","@typescript-eslint/eslint-plugin":"^4.6.0","@typescript-eslint/parser":"^4.6.0",asciidoctor:"^2.2.1","babel-jest":"^26.6.3","babel-preset-gatsby":"^1.10.0","command-line-args":"^5.1.1",coveralls:"^3.1.0","current-git-branch":"^1.1.0","dts-bundle":"^0.7.3",eslint:"^7.12.1","eslint-config-airbnb-base":"^14.2.0","eslint-config-prettier":"^6.15.0","eslint-import-resolver-typescript":"^2.3.0","eslint-plugin-import":"^2.22.1","eslint-plugin-prettier":"^3.1.4","eslint-plugin-react-hooks":"^4.2.0","fs-extra":"^10.0.0",gatsby:"3.13.1","gatsby-plugin-algolia":"^0.22.2","gatsby-plugin-catch-links":"^3.1.0","gatsby-plugin-env-variables":"^2.1.0","gatsby-plugin-intl":"^0.3.3","gatsby-plugin-manifest":"^3.2.0","gatsby-plugin-output":"^0.1.3","gatsby-plugin-sass":"6.7.0","gatsby-plugin-sitemap":"^4.10.0","gatsby-source-filesystem":"3.1.0","gatsby-transformer-asciidoc":"2.1.0","gatsby-transformer-rehype":"2.0.0","gh-pages":"^3.1.0","highlight.js":"^10.6.0","html-to-text":"^8.0.0","identity-obj-proxy":"^3.0.0","istanbul-merge":"^1.1.1",jest:"^26.6.3","jest-fetch-mock":"^3.0.3",jsdom:"^17.0.0","node-sass":"^8.0.0",prettier:"2.1.2",react:"^16.14.0","react-dom":"^16.14.0","react-resizable":"^1.11.0","react-resize-detector":"^6.6.0","react-test-renderer":"^17.0.2","react-use-flexsearch":"^0.1.1",rollup:"2.30.0","rollup-plugin-typescript2":"0.27.3","ts-jest":"^26.5.5","ts-loader":"8.0.4",typedoc:"0.21.6","typedoc-plugin-toc-group":"thoughtspot/typedoc-plugin-toc-group",typescript:"^4.9.4","url-search-params-polyfill":"^8.1.0",util:"^0.12.4"};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","embed","sdk","analytics"];var bugs={url:"https://github.com/thoughtspot/visual-embed-sdk/issues"};var homepage="https://github.com/thoughtspot/visual-embed-sdk#readme";var globals={window:{}};var pkgInfo = {name:name,version:version,description:description,module:module,main:main,types:types,files:files,exports:exports$1,typesVersions:typesVersions,"size-limit":[{path:"dist/tsembed.js",limit:"40 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};
|
|
11497
11497
|
|
|
11498
11498
|
/**
|
|
11499
11499
|
* Copyright (c) 2022
|
package/lib/package.json
CHANGED
package/package.json
CHANGED
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
export interface SessionInterface {
|
|
2
|
-
sessionId: string;
|
|
3
|
-
genNo: number;
|
|
4
|
-
acSession: {
|
|
5
|
-
sessionId: string;
|
|
6
|
-
genNo: number;
|
|
7
|
-
};
|
|
8
|
-
}
|
|
9
|
-
export declare enum OperationType {
|
|
10
|
-
GetChartWithData = "GetChartWithData",
|
|
11
|
-
GetTableWithHeadlineData = "GetTableWithHeadlineData"
|
|
12
|
-
}
|
|
13
|
-
export declare class AnswerService {
|
|
14
|
-
private session;
|
|
15
|
-
private answer;
|
|
16
|
-
private thoughtSpotHost;
|
|
17
|
-
constructor(session: SessionInterface, answer: any, thoughtSpotHost: string);
|
|
18
|
-
getSourceDetail(): Promise<any>;
|
|
19
|
-
removeColumns(columnIds: string[]): Promise<any>;
|
|
20
|
-
addColumns(columnIds: string[]): Promise<any>;
|
|
21
|
-
fetchData(offset?: number, size?: number): Promise<{
|
|
22
|
-
columns: any;
|
|
23
|
-
data: any;
|
|
24
|
-
}>;
|
|
25
|
-
getUnderlyingDataForPoint(selectedPoint: {
|
|
26
|
-
columnId: string;
|
|
27
|
-
dataValue: any;
|
|
28
|
-
}[], outputColumnNames: string[], offset: number, size: number): Promise<{
|
|
29
|
-
columns: any;
|
|
30
|
-
data: any;
|
|
31
|
-
}>;
|
|
32
|
-
executeQuery(query: string, variables: any): Promise<any>;
|
|
33
|
-
}
|
|
34
|
-
//# sourceMappingURL=answerService.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"answerService.d.ts","sourceRoot":"","sources":["../../../../src/utils/answerService/answerService.ts"],"names":[],"mappings":"AAGA,MAAM,WAAW,gBAAgB;IAC7B,SAAS,EAAE,MAAM,CAAC;IAClB,KAAK,EAAE,MAAM,CAAC;IACd,SAAS,EAAE;QAAE,SAAS,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAA;KAAE,CAAC;CACnD;AAGD,oBAAY,aAAa;IACrB,gBAAgB,qBAAqB;IACrC,wBAAwB,6BAA6B;CACxD;AAED,qBAAa,aAAa;IAElB,OAAO,CAAC,OAAO;IACf,OAAO,CAAC,MAAM;IACd,OAAO,CAAC,eAAe;gBAFf,OAAO,EAAE,gBAAgB,EACzB,MAAM,EAAE,GAAG,EACX,eAAe,EAAE,MAAM;IAKtB,eAAe;IAWf,aAAa,CAAC,SAAS,EAAE,MAAM,EAAE;IASjC,UAAU,CAAC,SAAS,EAAE,MAAM,EAAE;IAS9B,SAAS,CAAC,MAAM,SAAI,EAAE,IAAI,SAAO;;;;IAmBjC,yBAAyB,CAClC,aAAa,EAAE;QAAE,QAAQ,EAAE,MAAM,CAAC;QAAC,SAAS,EAAE,GAAG,CAAA;KAAE,EAAE,EACrD,iBAAiB,EAAE,MAAM,EAAE,EAC3B,MAAM,EAAE,MAAM,EACd,IAAI,EAAE,MAAM;;;;IA4BH,YAAY,CAAC,KAAK,EAAE,MAAM,EAAE,SAAS,EAAE,GAAG;CAa1D"}
|
|
@@ -1,142 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.AnswerService = exports.OperationType = void 0;
|
|
4
|
-
const tslib_1 = require("tslib");
|
|
5
|
-
const utils_1 = require("../../utils");
|
|
6
|
-
const queries = tslib_1.__importStar(require("./graphql-queries"));
|
|
7
|
-
// eslint-disable-next-line no-shadow
|
|
8
|
-
var OperationType;
|
|
9
|
-
(function (OperationType) {
|
|
10
|
-
OperationType["GetChartWithData"] = "GetChartWithData";
|
|
11
|
-
OperationType["GetTableWithHeadlineData"] = "GetTableWithHeadlineData";
|
|
12
|
-
})(OperationType = exports.OperationType || (exports.OperationType = {}));
|
|
13
|
-
class AnswerService {
|
|
14
|
-
constructor(session, answer, thoughtSpotHost) {
|
|
15
|
-
this.session = session;
|
|
16
|
-
this.answer = answer;
|
|
17
|
-
this.thoughtSpotHost = thoughtSpotHost;
|
|
18
|
-
this.session = (0, utils_1.removeTypename)(session);
|
|
19
|
-
}
|
|
20
|
-
async getSourceDetail() {
|
|
21
|
-
const details = await graphqlQuery({
|
|
22
|
-
query: queries.getSourceDetail,
|
|
23
|
-
variables: {
|
|
24
|
-
ids: [this.answer.sources[0].header.guid],
|
|
25
|
-
},
|
|
26
|
-
thoughtSpotHost: this.thoughtSpotHost,
|
|
27
|
-
});
|
|
28
|
-
return details[0];
|
|
29
|
-
}
|
|
30
|
-
async removeColumns(columnIds) {
|
|
31
|
-
return this.executeQuery(queries.removeColumns, {
|
|
32
|
-
logicalColumnIds: columnIds,
|
|
33
|
-
});
|
|
34
|
-
}
|
|
35
|
-
async addColumns(columnIds) {
|
|
36
|
-
return this.executeQuery(queries.addColumns, {
|
|
37
|
-
columns: columnIds.map((colId) => ({ logicalColumnId: colId })),
|
|
38
|
-
});
|
|
39
|
-
}
|
|
40
|
-
async fetchData(offset = 0, size = 1000) {
|
|
41
|
-
const { answer } = await this.executeQuery(queries.getAnswerData, {
|
|
42
|
-
deadline: 0,
|
|
43
|
-
dataPaginationParams: {
|
|
44
|
-
isClientPaginated: true,
|
|
45
|
-
offset,
|
|
46
|
-
size,
|
|
47
|
-
},
|
|
48
|
-
});
|
|
49
|
-
const { columns, data } = answer.visualizations[0];
|
|
50
|
-
return {
|
|
51
|
-
columns,
|
|
52
|
-
data,
|
|
53
|
-
};
|
|
54
|
-
}
|
|
55
|
-
async getUnderlyingDataForPoint(selectedPoint, outputColumnNames, offset, size) {
|
|
56
|
-
const sourceDetail = await this.getSourceDetail();
|
|
57
|
-
const ouputColumnGuids = getGuidsFromColumnNames(sourceDetail, outputColumnNames);
|
|
58
|
-
const unAggAnswer = await graphqlQuery({
|
|
59
|
-
query: queries.getUnaggregatedAnswerSession,
|
|
60
|
-
variables: {
|
|
61
|
-
session: this.session,
|
|
62
|
-
columns: selectedPoint,
|
|
63
|
-
},
|
|
64
|
-
thoughtSpotHost: this.thoughtSpotHost,
|
|
65
|
-
});
|
|
66
|
-
const unaggAnswerSession = new AnswerService(unAggAnswer.id, unAggAnswer.answer, this.thoughtSpotHost);
|
|
67
|
-
const currentColumns = new Set(unAggAnswer.answer.visualizations[0].columns.map((c) => c.column.referencedColumns[0].guid));
|
|
68
|
-
const columnsToAdd = [...ouputColumnGuids].filter((col) => !currentColumns.has(col));
|
|
69
|
-
if (columnsToAdd.length) {
|
|
70
|
-
await unaggAnswerSession.addColumns(columnsToAdd);
|
|
71
|
-
}
|
|
72
|
-
const columnsToRemove = [...currentColumns].filter((col) => !ouputColumnGuids.has(col));
|
|
73
|
-
if (columnsToRemove.length) {
|
|
74
|
-
await unaggAnswerSession.removeColumns(columnsToRemove);
|
|
75
|
-
}
|
|
76
|
-
return unaggAnswerSession.fetchData(offset, size);
|
|
77
|
-
}
|
|
78
|
-
async executeQuery(query, variables) {
|
|
79
|
-
const data = await graphqlQuery({
|
|
80
|
-
query,
|
|
81
|
-
variables: {
|
|
82
|
-
session: this.session,
|
|
83
|
-
...variables,
|
|
84
|
-
},
|
|
85
|
-
thoughtSpotHost: this.thoughtSpotHost,
|
|
86
|
-
isCompositeQuery: false,
|
|
87
|
-
});
|
|
88
|
-
this.session = (0, utils_1.deepMerge)(this.session, data.id);
|
|
89
|
-
return data;
|
|
90
|
-
}
|
|
91
|
-
}
|
|
92
|
-
exports.AnswerService = AnswerService;
|
|
93
|
-
/**
|
|
94
|
-
*
|
|
95
|
-
* @param root0
|
|
96
|
-
* @param root0.query
|
|
97
|
-
* @param root0.variables
|
|
98
|
-
* @param root0.thoughtSpotHost
|
|
99
|
-
* @param root0.isCompositeQuery
|
|
100
|
-
*/
|
|
101
|
-
async function graphqlQuery({ query, variables, thoughtSpotHost, isCompositeQuery = false, }) {
|
|
102
|
-
const operationName = (0, utils_1.getOperationNameFromQuery)(query);
|
|
103
|
-
try {
|
|
104
|
-
const response = await fetch(`${thoughtSpotHost}/prism/?op=${operationName}`, {
|
|
105
|
-
method: 'POST',
|
|
106
|
-
headers: {
|
|
107
|
-
'content-type': 'application/json;charset=UTF-8',
|
|
108
|
-
'x-requested-by': 'ThoughtSpot',
|
|
109
|
-
accept: '*/*',
|
|
110
|
-
'accept-language': 'en-us',
|
|
111
|
-
},
|
|
112
|
-
body: JSON.stringify({
|
|
113
|
-
operationName,
|
|
114
|
-
query,
|
|
115
|
-
variables,
|
|
116
|
-
}),
|
|
117
|
-
credentials: 'include',
|
|
118
|
-
});
|
|
119
|
-
const result = await response.json();
|
|
120
|
-
const dataValues = Object.values(result.data);
|
|
121
|
-
return (isCompositeQuery) ? result.data : dataValues[0];
|
|
122
|
-
}
|
|
123
|
-
catch (error) {
|
|
124
|
-
return error;
|
|
125
|
-
}
|
|
126
|
-
}
|
|
127
|
-
/**
|
|
128
|
-
*
|
|
129
|
-
* @param sourceDetail
|
|
130
|
-
* @param colNames
|
|
131
|
-
*/
|
|
132
|
-
function getGuidsFromColumnNames(sourceDetail, colNames) {
|
|
133
|
-
const cols = sourceDetail.columns.reduce((colSet, col) => {
|
|
134
|
-
colSet[col.name] = col;
|
|
135
|
-
return colSet;
|
|
136
|
-
}, {});
|
|
137
|
-
return new Set(colNames.map((colName) => {
|
|
138
|
-
const col = cols[colName];
|
|
139
|
-
return col.id;
|
|
140
|
-
}));
|
|
141
|
-
}
|
|
142
|
-
//# sourceMappingURL=answerService.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"answerService.js","sourceRoot":"","sources":["../../../../src/utils/answerService/answerService.ts"],"names":[],"mappings":";;;;AAAA,uCAAmF;AACnF,mEAA6C;AAQ7C,qCAAqC;AACrC,IAAY,aAGX;AAHD,WAAY,aAAa;IACrB,sDAAqC,CAAA;IACrC,sEAAqD,CAAA;AACzD,CAAC,EAHW,aAAa,GAAb,qBAAa,KAAb,qBAAa,QAGxB;AAED,MAAa,aAAa;I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,EAAE,SAAS;SACzB,CAAC,CAAC;QACH,MAAM,MAAM,GAAG,MAAM,QAAQ,CAAC,IAAI,EAAE,CAAC;QACrC,MAAM,UAAU,GAAG,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC;QAC9C,OAAO,CAAC,gBAAgB,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC;KAC3D;IAAC,OAAO,KAAK,EAAE;QACZ,OAAO,KAAK,CAAC;KAChB;AACL,CAAC;AAED;;;;GAIG;AACH,SAAS,uBAAuB,CAAC,YAAiB,EAAE,QAAkB;IAClE,MAAM,IAAI,GAAG,YAAY,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC,MAAW,EAAE,GAAQ,EAAE,EAAE;QAC/D,MAAM,CAAC,GAAG,CAAC,IAAI,CAAC,GAAG,GAAG,CAAC;QACvB,OAAO,MAAM,CAAC;IAClB,CAAC,EAAE,EAAE,CAAC,CAAC;IAEP,OAAO,IAAI,GAAG,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC,OAAO,EAAE,EAAE;QACpC,MAAM,GAAG,GAAG,IAAI,CAAC,OAAO,CAAC,CAAC;QAC1B,OAAO,GAAG,CAAC,EAAE,CAAC;IAClB,CAAC,CAAC,CAAC,CAAC;AACR,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
//# sourceMappingURL=answerService.spec.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"answerService.spec.d.ts","sourceRoot":"","sources":["../../../../src/utils/answerService/answerService.spec.ts"],"names":[],"mappings":""}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
//# sourceMappingURL=answerService.spec.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"answerService.spec.js","sourceRoot":"","sources":["../../../../src/utils/answerService/answerService.spec.ts"],"names":[],"mappings":""}
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
export declare const getUnaggregatedAnswerSession: string;
|
|
2
|
-
export declare const removeColumns: string;
|
|
3
|
-
export declare const addColumns: string;
|
|
4
|
-
export declare const getAnswerData: string;
|
|
5
|
-
export declare const getSourceDetail = "\n query GetSourceDetail($ids: [GUID!]!) {\n getSourceDetailById(ids: $ids, type: LOGICAL_TABLE) {\n id\n name\n description\n authorName\n authorDisplayName\n isExternal\n type\n created\n modified\n columns {\n id\n name\n author\n authorDisplayName\n description\n dataType\n type\n modified\n ownerName\n owner\n dataRecency\n sources {\n tableId\n tableName\n columnId\n columnName\n __typename\n }\n synonyms\n cohortAnswerId\n __typename\n }\n relationships\n destinationRelationships\n dataSourceId\n __typename\n }\n } \n";
|
|
6
|
-
//# sourceMappingURL=graphql-queries.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"graphql-queries.d.ts","sourceRoot":"","sources":["../../../../src/utils/answerService/graphql-queries.ts"],"names":[],"mappings":"AAWA,eAAO,MAAM,4BAA4B,QAsBxC,CAAC;AAEF,eAAO,MAAM,aAAa,QAUrB,CAAC;AAEN,eAAO,MAAM,UAAU,QAMlB,CAAC;AAEN,eAAO,MAAM,aAAa,QAwBzB,CAAC;AAEF,eAAO,MAAM,eAAe,43BAyC3B,CAAC"}
|
|
@@ -1,123 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.getSourceDetail = exports.getAnswerData = exports.addColumns = exports.removeColumns = exports.getUnaggregatedAnswerSession = void 0;
|
|
4
|
-
const bachSessionId = `
|
|
5
|
-
id {
|
|
6
|
-
sessionId
|
|
7
|
-
genNo
|
|
8
|
-
acSession {
|
|
9
|
-
sessionId
|
|
10
|
-
genNo
|
|
11
|
-
}
|
|
12
|
-
}
|
|
13
|
-
`;
|
|
14
|
-
exports.getUnaggregatedAnswerSession = `
|
|
15
|
-
mutation GetUnAggregatedAnswerSession($session: BachSessionIdInput!, $columns: [UserPointSelectionInput!]!) {
|
|
16
|
-
Answer__getUnaggregatedAnswer(session: $session, columns: $columns) {
|
|
17
|
-
${bachSessionId}
|
|
18
|
-
answer {
|
|
19
|
-
visualizations {
|
|
20
|
-
... on TableViz {
|
|
21
|
-
columns {
|
|
22
|
-
column {
|
|
23
|
-
id
|
|
24
|
-
name
|
|
25
|
-
referencedColumns {
|
|
26
|
-
guid
|
|
27
|
-
displayName
|
|
28
|
-
}
|
|
29
|
-
}
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
`;
|
|
37
|
-
exports.removeColumns = `
|
|
38
|
-
mutation RemoveColumns($session: BachSessionIdInput!, $logicalColumnIds: [GUID!], $columnIds: [GUID!]) {
|
|
39
|
-
Answer__removeColumns(
|
|
40
|
-
session: $session
|
|
41
|
-
logicalColumnIds: $logicalColumnIds
|
|
42
|
-
columnIds: $columnIds
|
|
43
|
-
) {
|
|
44
|
-
${bachSessionId}
|
|
45
|
-
}
|
|
46
|
-
}
|
|
47
|
-
`;
|
|
48
|
-
exports.addColumns = `
|
|
49
|
-
mutation AddColumns($session: BachSessionIdInput!, $columns: [AnswerColumnInfo!]!) {
|
|
50
|
-
Answer__addColumn(session: $session, columns: $columns) {
|
|
51
|
-
${bachSessionId}
|
|
52
|
-
}
|
|
53
|
-
}
|
|
54
|
-
`;
|
|
55
|
-
exports.getAnswerData = `
|
|
56
|
-
query GetTableWithHeadlineData($session: BachSessionIdInput!, $deadline: Int!, $dataPaginationParams: DataPaginationParamsInput!) {
|
|
57
|
-
getAnswer(session: $session) {
|
|
58
|
-
${bachSessionId}
|
|
59
|
-
answer {
|
|
60
|
-
id
|
|
61
|
-
visualizations {
|
|
62
|
-
id
|
|
63
|
-
... on TableViz {
|
|
64
|
-
columns {
|
|
65
|
-
column {
|
|
66
|
-
id
|
|
67
|
-
name
|
|
68
|
-
type
|
|
69
|
-
aggregationType
|
|
70
|
-
dataType
|
|
71
|
-
}
|
|
72
|
-
}
|
|
73
|
-
data(deadline: $deadline, pagination: $dataPaginationParams)
|
|
74
|
-
}
|
|
75
|
-
}
|
|
76
|
-
}
|
|
77
|
-
}
|
|
78
|
-
}
|
|
79
|
-
`;
|
|
80
|
-
exports.getSourceDetail = `
|
|
81
|
-
query GetSourceDetail($ids: [GUID!]!) {
|
|
82
|
-
getSourceDetailById(ids: $ids, type: LOGICAL_TABLE) {
|
|
83
|
-
id
|
|
84
|
-
name
|
|
85
|
-
description
|
|
86
|
-
authorName
|
|
87
|
-
authorDisplayName
|
|
88
|
-
isExternal
|
|
89
|
-
type
|
|
90
|
-
created
|
|
91
|
-
modified
|
|
92
|
-
columns {
|
|
93
|
-
id
|
|
94
|
-
name
|
|
95
|
-
author
|
|
96
|
-
authorDisplayName
|
|
97
|
-
description
|
|
98
|
-
dataType
|
|
99
|
-
type
|
|
100
|
-
modified
|
|
101
|
-
ownerName
|
|
102
|
-
owner
|
|
103
|
-
dataRecency
|
|
104
|
-
sources {
|
|
105
|
-
tableId
|
|
106
|
-
tableName
|
|
107
|
-
columnId
|
|
108
|
-
columnName
|
|
109
|
-
__typename
|
|
110
|
-
}
|
|
111
|
-
synonyms
|
|
112
|
-
cohortAnswerId
|
|
113
|
-
__typename
|
|
114
|
-
}
|
|
115
|
-
relationships
|
|
116
|
-
destinationRelationships
|
|
117
|
-
dataSourceId
|
|
118
|
-
__typename
|
|
119
|
-
}
|
|
120
|
-
}
|
|
121
|
-
`;
|
|
122
|
-
const operations = {};
|
|
123
|
-
//# sourceMappingURL=graphql-queries.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"graphql-queries.js","sourceRoot":"","sources":["../../../../src/utils/answerService/graphql-queries.ts"],"names":[],"mappings":";;;AAAA,MAAM,aAAa,GAAG;;;;;;;;;CASrB,CAAC;AAEW,QAAA,4BAA4B,GAAG;;;UAGlC,aAAa;;;;;;;;;;;;;;;;;;;CAmBtB,CAAC;AAEW,QAAA,aAAa,GAAG;;;;;;;cAOf,aAAa;;;KAGtB,CAAC;AAEO,QAAA,UAAU,GAAG;;;cAGZ,aAAa;;;KAGtB,CAAC;AAEO,QAAA,aAAa,GAAG;;;cAGf,aAAa;;;;;;;;;;;;;;;;;;;;;CAqB1B,CAAC;AAEW,QAAA,eAAe,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAyC9B,CAAC;AAEF,MAAM,UAAU,GAAG,EAElB,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"graphql-queries.d.ts","sourceRoot":"","sources":["../../../../../src/utils/graphql/answerService/graphql-queries.ts"],"names":[],"mappings":"AAWA,eAAO,MAAM,4BAA4B,QAsBxC,CAAC;AAEF,eAAO,MAAM,aAAa,QAUrB,CAAC;AAEN,eAAO,MAAM,UAAU,QAMlB,CAAC;AAEN,eAAO,MAAM,aAAa,QAwBzB,CAAC"}
|
|
@@ -1,80 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.getAnswerData = exports.addColumns = exports.removeColumns = exports.getUnaggregatedAnswerSession = void 0;
|
|
4
|
-
const bachSessionId = `
|
|
5
|
-
id {
|
|
6
|
-
sessionId
|
|
7
|
-
genNo
|
|
8
|
-
acSession {
|
|
9
|
-
sessionId
|
|
10
|
-
genNo
|
|
11
|
-
}
|
|
12
|
-
}
|
|
13
|
-
`;
|
|
14
|
-
exports.getUnaggregatedAnswerSession = `
|
|
15
|
-
mutation GetUnAggregatedAnswerSession($session: BachSessionIdInput!, $columns: [UserPointSelectionInput!]!) {
|
|
16
|
-
Answer__getUnaggregatedAnswer(session: $session, columns: $columns) {
|
|
17
|
-
${bachSessionId}
|
|
18
|
-
answer {
|
|
19
|
-
visualizations {
|
|
20
|
-
... on TableViz {
|
|
21
|
-
columns {
|
|
22
|
-
column {
|
|
23
|
-
id
|
|
24
|
-
name
|
|
25
|
-
referencedColumns {
|
|
26
|
-
guid
|
|
27
|
-
displayName
|
|
28
|
-
}
|
|
29
|
-
}
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
`;
|
|
37
|
-
exports.removeColumns = `
|
|
38
|
-
mutation RemoveColumns($session: BachSessionIdInput!, $logicalColumnIds: [GUID!], $columnIds: [GUID!]) {
|
|
39
|
-
Answer__removeColumns(
|
|
40
|
-
session: $session
|
|
41
|
-
logicalColumnIds: $logicalColumnIds
|
|
42
|
-
columnIds: $columnIds
|
|
43
|
-
) {
|
|
44
|
-
${bachSessionId}
|
|
45
|
-
}
|
|
46
|
-
}
|
|
47
|
-
`;
|
|
48
|
-
exports.addColumns = `
|
|
49
|
-
mutation AddColumns($session: BachSessionIdInput!, $columns: [AnswerColumnInfo!]!) {
|
|
50
|
-
Answer__addColumn(session: $session, columns: $columns) {
|
|
51
|
-
${bachSessionId}
|
|
52
|
-
}
|
|
53
|
-
}
|
|
54
|
-
`;
|
|
55
|
-
exports.getAnswerData = `
|
|
56
|
-
query GetTableWithHeadlineData($session: BachSessionIdInput!, $deadline: Int!, $dataPaginationParams: DataPaginationParamsInput!) {
|
|
57
|
-
getAnswer(session: $session) {
|
|
58
|
-
${bachSessionId}
|
|
59
|
-
answer {
|
|
60
|
-
id
|
|
61
|
-
visualizations {
|
|
62
|
-
id
|
|
63
|
-
... on TableViz {
|
|
64
|
-
columns {
|
|
65
|
-
column {
|
|
66
|
-
id
|
|
67
|
-
name
|
|
68
|
-
type
|
|
69
|
-
aggregationType
|
|
70
|
-
dataType
|
|
71
|
-
}
|
|
72
|
-
}
|
|
73
|
-
data(deadline: $deadline, pagination: $dataPaginationParams)
|
|
74
|
-
}
|
|
75
|
-
}
|
|
76
|
-
}
|
|
77
|
-
}
|
|
78
|
-
}
|
|
79
|
-
`;
|
|
80
|
-
//# sourceMappingURL=graphql-queries.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"graphql-queries.js","sourceRoot":"","sources":["../../../../../src/utils/graphql/answerService/graphql-queries.ts"],"names":[],"mappings":";;;AAAA,MAAM,aAAa,GAAG;;;;;;;;;CASrB,CAAC;AAEW,QAAA,4BAA4B,GAAG;;;UAGlC,aAAa;;;;;;;;;;;;;;;;;;;CAmBtB,CAAC;AAEW,QAAA,aAAa,GAAG;;;;;;;cAOf,aAAa;;;KAGtB,CAAC;AAEO,QAAA,UAAU,GAAG;;;cAGZ,aAAa;;;KAGtB,CAAC;AAEO,QAAA,aAAa,GAAG;;;cAGf,aAAa;;;;;;;;;;;;;;;;;;;;;CAqB1B,CAAC"}
|
package/lib/src/.index.d.ts.swp
DELETED
|
Binary file
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
export interface SessionInterface {
|
|
2
|
-
sessionId: string;
|
|
3
|
-
genNo: number;
|
|
4
|
-
acSession: {
|
|
5
|
-
sessionId: string;
|
|
6
|
-
genNo: number;
|
|
7
|
-
};
|
|
8
|
-
}
|
|
9
|
-
export declare enum OperationType {
|
|
10
|
-
GetChartWithData = "GetChartWithData",
|
|
11
|
-
GetTableWithHeadlineData = "GetTableWithHeadlineData"
|
|
12
|
-
}
|
|
13
|
-
export declare class AnswerService {
|
|
14
|
-
private session;
|
|
15
|
-
private answer;
|
|
16
|
-
private thoughtSpotHost;
|
|
17
|
-
constructor(session: SessionInterface, answer: any, thoughtSpotHost: string);
|
|
18
|
-
getSourceDetail(): Promise<any>;
|
|
19
|
-
removeColumns(columnIds: string[]): Promise<any>;
|
|
20
|
-
addColumns(columnIds: string[]): Promise<any>;
|
|
21
|
-
fetchData(offset?: number, size?: number): Promise<{
|
|
22
|
-
columns: any;
|
|
23
|
-
data: any;
|
|
24
|
-
}>;
|
|
25
|
-
getUnderlyingDataForPoint(selectedPoint: {
|
|
26
|
-
columnId: string;
|
|
27
|
-
dataValue: any;
|
|
28
|
-
}[], outputColumnNames: string[], offset: number, size: number): Promise<{
|
|
29
|
-
columns: any;
|
|
30
|
-
data: any;
|
|
31
|
-
}>;
|
|
32
|
-
executeQuery(query: string, variables: any): Promise<any>;
|
|
33
|
-
}
|
|
34
|
-
//# sourceMappingURL=answerService.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"answerService.d.ts","sourceRoot":"","sources":["../../../../src/utils/answerService/answerService.ts"],"names":[],"mappings":"AAGA,MAAM,WAAW,gBAAgB;IAC7B,SAAS,EAAE,MAAM,CAAC;IAClB,KAAK,EAAE,MAAM,CAAC;IACd,SAAS,EAAE;QAAE,SAAS,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAA;KAAE,CAAC;CACnD;AAGD,oBAAY,aAAa;IACrB,gBAAgB,qBAAqB;IACrC,wBAAwB,6BAA6B;CACxD;AAED,qBAAa,aAAa;IAElB,OAAO,CAAC,OAAO;IACf,OAAO,CAAC,MAAM;IACd,OAAO,CAAC,eAAe;gBAFf,OAAO,EAAE,gBAAgB,EACzB,MAAM,EAAE,GAAG,EACX,eAAe,EAAE,MAAM;IAKtB,eAAe;IAWf,aAAa,CAAC,SAAS,EAAE,MAAM,EAAE;IASjC,UAAU,CAAC,SAAS,EAAE,MAAM,EAAE;IAS9B,SAAS,CAAC,MAAM,SAAI,EAAE,IAAI,SAAO;;;;IAmBjC,yBAAyB,CAClC,aAAa,EAAE;QAAE,QAAQ,EAAE,MAAM,CAAC;QAAC,SAAS,EAAE,GAAG,CAAA;KAAE,EAAE,EACrD,iBAAiB,EAAE,MAAM,EAAE,EAC3B,MAAM,EAAE,MAAM,EACd,IAAI,EAAE,MAAM;;;;IA4BH,YAAY,CAAC,KAAK,EAAE,MAAM,EAAE,SAAS,EAAE,GAAG;CAa1D"}
|
|
@@ -1,137 +0,0 @@
|
|
|
1
|
-
import { deepMerge, getOperationNameFromQuery, removeTypename } from '../../utils';
|
|
2
|
-
import * as queries from './graphql-queries';
|
|
3
|
-
// eslint-disable-next-line no-shadow
|
|
4
|
-
export var OperationType;
|
|
5
|
-
(function (OperationType) {
|
|
6
|
-
OperationType["GetChartWithData"] = "GetChartWithData";
|
|
7
|
-
OperationType["GetTableWithHeadlineData"] = "GetTableWithHeadlineData";
|
|
8
|
-
})(OperationType || (OperationType = {}));
|
|
9
|
-
export class AnswerService {
|
|
10
|
-
constructor(session, answer, thoughtSpotHost) {
|
|
11
|
-
this.session = session;
|
|
12
|
-
this.answer = answer;
|
|
13
|
-
this.thoughtSpotHost = thoughtSpotHost;
|
|
14
|
-
this.session = removeTypename(session);
|
|
15
|
-
}
|
|
16
|
-
async getSourceDetail() {
|
|
17
|
-
const details = await graphqlQuery({
|
|
18
|
-
query: queries.getSourceDetail,
|
|
19
|
-
variables: {
|
|
20
|
-
ids: [this.answer.sources[0].header.guid],
|
|
21
|
-
},
|
|
22
|
-
thoughtSpotHost: this.thoughtSpotHost,
|
|
23
|
-
});
|
|
24
|
-
return details[0];
|
|
25
|
-
}
|
|
26
|
-
async removeColumns(columnIds) {
|
|
27
|
-
return this.executeQuery(queries.removeColumns, {
|
|
28
|
-
logicalColumnIds: columnIds,
|
|
29
|
-
});
|
|
30
|
-
}
|
|
31
|
-
async addColumns(columnIds) {
|
|
32
|
-
return this.executeQuery(queries.addColumns, {
|
|
33
|
-
columns: columnIds.map((colId) => ({ logicalColumnId: colId })),
|
|
34
|
-
});
|
|
35
|
-
}
|
|
36
|
-
async fetchData(offset = 0, size = 1000) {
|
|
37
|
-
const { answer } = await this.executeQuery(queries.getAnswerData, {
|
|
38
|
-
deadline: 0,
|
|
39
|
-
dataPaginationParams: {
|
|
40
|
-
isClientPaginated: true,
|
|
41
|
-
offset,
|
|
42
|
-
size,
|
|
43
|
-
},
|
|
44
|
-
});
|
|
45
|
-
const { columns, data } = answer.visualizations[0];
|
|
46
|
-
return {
|
|
47
|
-
columns,
|
|
48
|
-
data,
|
|
49
|
-
};
|
|
50
|
-
}
|
|
51
|
-
async getUnderlyingDataForPoint(selectedPoint, outputColumnNames, offset, size) {
|
|
52
|
-
const sourceDetail = await this.getSourceDetail();
|
|
53
|
-
const ouputColumnGuids = getGuidsFromColumnNames(sourceDetail, outputColumnNames);
|
|
54
|
-
const unAggAnswer = await graphqlQuery({
|
|
55
|
-
query: queries.getUnaggregatedAnswerSession,
|
|
56
|
-
variables: {
|
|
57
|
-
session: this.session,
|
|
58
|
-
columns: selectedPoint,
|
|
59
|
-
},
|
|
60
|
-
thoughtSpotHost: this.thoughtSpotHost,
|
|
61
|
-
});
|
|
62
|
-
const unaggAnswerSession = new AnswerService(unAggAnswer.id, unAggAnswer.answer, this.thoughtSpotHost);
|
|
63
|
-
const currentColumns = new Set(unAggAnswer.answer.visualizations[0].columns.map((c) => c.column.referencedColumns[0].guid));
|
|
64
|
-
const columnsToAdd = [...ouputColumnGuids].filter((col) => !currentColumns.has(col));
|
|
65
|
-
if (columnsToAdd.length) {
|
|
66
|
-
await unaggAnswerSession.addColumns(columnsToAdd);
|
|
67
|
-
}
|
|
68
|
-
const columnsToRemove = [...currentColumns].filter((col) => !ouputColumnGuids.has(col));
|
|
69
|
-
if (columnsToRemove.length) {
|
|
70
|
-
await unaggAnswerSession.removeColumns(columnsToRemove);
|
|
71
|
-
}
|
|
72
|
-
return unaggAnswerSession.fetchData(offset, size);
|
|
73
|
-
}
|
|
74
|
-
async executeQuery(query, variables) {
|
|
75
|
-
const data = await graphqlQuery({
|
|
76
|
-
query,
|
|
77
|
-
variables: {
|
|
78
|
-
session: this.session,
|
|
79
|
-
...variables,
|
|
80
|
-
},
|
|
81
|
-
thoughtSpotHost: this.thoughtSpotHost,
|
|
82
|
-
isCompositeQuery: false,
|
|
83
|
-
});
|
|
84
|
-
this.session = deepMerge(this.session, data.id);
|
|
85
|
-
return data;
|
|
86
|
-
}
|
|
87
|
-
}
|
|
88
|
-
/**
|
|
89
|
-
*
|
|
90
|
-
* @param root0
|
|
91
|
-
* @param root0.query
|
|
92
|
-
* @param root0.variables
|
|
93
|
-
* @param root0.thoughtSpotHost
|
|
94
|
-
* @param root0.isCompositeQuery
|
|
95
|
-
*/
|
|
96
|
-
async function graphqlQuery({ query, variables, thoughtSpotHost, isCompositeQuery = false, }) {
|
|
97
|
-
const operationName = getOperationNameFromQuery(query);
|
|
98
|
-
try {
|
|
99
|
-
const response = await fetch(`${thoughtSpotHost}/prism/?op=${operationName}`, {
|
|
100
|
-
method: 'POST',
|
|
101
|
-
headers: {
|
|
102
|
-
'content-type': 'application/json;charset=UTF-8',
|
|
103
|
-
'x-requested-by': 'ThoughtSpot',
|
|
104
|
-
accept: '*/*',
|
|
105
|
-
'accept-language': 'en-us',
|
|
106
|
-
},
|
|
107
|
-
body: JSON.stringify({
|
|
108
|
-
operationName,
|
|
109
|
-
query,
|
|
110
|
-
variables,
|
|
111
|
-
}),
|
|
112
|
-
credentials: 'include',
|
|
113
|
-
});
|
|
114
|
-
const result = await response.json();
|
|
115
|
-
const dataValues = Object.values(result.data);
|
|
116
|
-
return (isCompositeQuery) ? result.data : dataValues[0];
|
|
117
|
-
}
|
|
118
|
-
catch (error) {
|
|
119
|
-
return error;
|
|
120
|
-
}
|
|
121
|
-
}
|
|
122
|
-
/**
|
|
123
|
-
*
|
|
124
|
-
* @param sourceDetail
|
|
125
|
-
* @param colNames
|
|
126
|
-
*/
|
|
127
|
-
function getGuidsFromColumnNames(sourceDetail, colNames) {
|
|
128
|
-
const cols = sourceDetail.columns.reduce((colSet, col) => {
|
|
129
|
-
colSet[col.name] = col;
|
|
130
|
-
return colSet;
|
|
131
|
-
}, {});
|
|
132
|
-
return new Set(colNames.map((colName) => {
|
|
133
|
-
const col = cols[colName];
|
|
134
|
-
return col.id;
|
|
135
|
-
}));
|
|
136
|
-
}
|
|
137
|
-
//# sourceMappingURL=answerService.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"answerService.js","sourceRoot":"","sources":["../../../../src/utils/answerService/answerService.ts"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,"file":"answerService.spec.d.ts","sourceRoot":"","sources":["../../../../src/utils/answerService/answerService.spec.ts"],"names":[],"mappings":""}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
//# sourceMappingURL=answerService.spec.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"answerService.spec.js","sourceRoot":"","sources":["../../../../src/utils/answerService/answerService.spec.ts"],"names":[],"mappings":""}
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
export declare const getUnaggregatedAnswerSession: string;
|
|
2
|
-
export declare const removeColumns: string;
|
|
3
|
-
export declare const addColumns: string;
|
|
4
|
-
export declare const getAnswerData: string;
|
|
5
|
-
export declare const getSourceDetail = "\n query GetSourceDetail($ids: [GUID!]!) {\n getSourceDetailById(ids: $ids, type: LOGICAL_TABLE) {\n id\n name\n description\n authorName\n authorDisplayName\n isExternal\n type\n created\n modified\n columns {\n id\n name\n author\n authorDisplayName\n description\n dataType\n type\n modified\n ownerName\n owner\n dataRecency\n sources {\n tableId\n tableName\n columnId\n columnName\n __typename\n }\n synonyms\n cohortAnswerId\n __typename\n }\n relationships\n destinationRelationships\n dataSourceId\n __typename\n }\n } \n";
|
|
6
|
-
//# sourceMappingURL=graphql-queries.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"graphql-queries.d.ts","sourceRoot":"","sources":["../../../../src/utils/answerService/graphql-queries.ts"],"names":[],"mappings":"AAWA,eAAO,MAAM,4BAA4B,QAsBxC,CAAC;AAEF,eAAO,MAAM,aAAa,QAUrB,CAAC;AAEN,eAAO,MAAM,UAAU,QAMlB,CAAC;AAEN,eAAO,MAAM,aAAa,QAwBzB,CAAC;AAEF,eAAO,MAAM,eAAe,43BAyC3B,CAAC"}
|
|
@@ -1,120 +0,0 @@
|
|
|
1
|
-
const bachSessionId = `
|
|
2
|
-
id {
|
|
3
|
-
sessionId
|
|
4
|
-
genNo
|
|
5
|
-
acSession {
|
|
6
|
-
sessionId
|
|
7
|
-
genNo
|
|
8
|
-
}
|
|
9
|
-
}
|
|
10
|
-
`;
|
|
11
|
-
export const getUnaggregatedAnswerSession = `
|
|
12
|
-
mutation GetUnAggregatedAnswerSession($session: BachSessionIdInput!, $columns: [UserPointSelectionInput!]!) {
|
|
13
|
-
Answer__getUnaggregatedAnswer(session: $session, columns: $columns) {
|
|
14
|
-
${bachSessionId}
|
|
15
|
-
answer {
|
|
16
|
-
visualizations {
|
|
17
|
-
... on TableViz {
|
|
18
|
-
columns {
|
|
19
|
-
column {
|
|
20
|
-
id
|
|
21
|
-
name
|
|
22
|
-
referencedColumns {
|
|
23
|
-
guid
|
|
24
|
-
displayName
|
|
25
|
-
}
|
|
26
|
-
}
|
|
27
|
-
}
|
|
28
|
-
}
|
|
29
|
-
}
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
`;
|
|
34
|
-
export const removeColumns = `
|
|
35
|
-
mutation RemoveColumns($session: BachSessionIdInput!, $logicalColumnIds: [GUID!], $columnIds: [GUID!]) {
|
|
36
|
-
Answer__removeColumns(
|
|
37
|
-
session: $session
|
|
38
|
-
logicalColumnIds: $logicalColumnIds
|
|
39
|
-
columnIds: $columnIds
|
|
40
|
-
) {
|
|
41
|
-
${bachSessionId}
|
|
42
|
-
}
|
|
43
|
-
}
|
|
44
|
-
`;
|
|
45
|
-
export const addColumns = `
|
|
46
|
-
mutation AddColumns($session: BachSessionIdInput!, $columns: [AnswerColumnInfo!]!) {
|
|
47
|
-
Answer__addColumn(session: $session, columns: $columns) {
|
|
48
|
-
${bachSessionId}
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
`;
|
|
52
|
-
export const getAnswerData = `
|
|
53
|
-
query GetTableWithHeadlineData($session: BachSessionIdInput!, $deadline: Int!, $dataPaginationParams: DataPaginationParamsInput!) {
|
|
54
|
-
getAnswer(session: $session) {
|
|
55
|
-
${bachSessionId}
|
|
56
|
-
answer {
|
|
57
|
-
id
|
|
58
|
-
visualizations {
|
|
59
|
-
id
|
|
60
|
-
... on TableViz {
|
|
61
|
-
columns {
|
|
62
|
-
column {
|
|
63
|
-
id
|
|
64
|
-
name
|
|
65
|
-
type
|
|
66
|
-
aggregationType
|
|
67
|
-
dataType
|
|
68
|
-
}
|
|
69
|
-
}
|
|
70
|
-
data(deadline: $deadline, pagination: $dataPaginationParams)
|
|
71
|
-
}
|
|
72
|
-
}
|
|
73
|
-
}
|
|
74
|
-
}
|
|
75
|
-
}
|
|
76
|
-
`;
|
|
77
|
-
export const getSourceDetail = `
|
|
78
|
-
query GetSourceDetail($ids: [GUID!]!) {
|
|
79
|
-
getSourceDetailById(ids: $ids, type: LOGICAL_TABLE) {
|
|
80
|
-
id
|
|
81
|
-
name
|
|
82
|
-
description
|
|
83
|
-
authorName
|
|
84
|
-
authorDisplayName
|
|
85
|
-
isExternal
|
|
86
|
-
type
|
|
87
|
-
created
|
|
88
|
-
modified
|
|
89
|
-
columns {
|
|
90
|
-
id
|
|
91
|
-
name
|
|
92
|
-
author
|
|
93
|
-
authorDisplayName
|
|
94
|
-
description
|
|
95
|
-
dataType
|
|
96
|
-
type
|
|
97
|
-
modified
|
|
98
|
-
ownerName
|
|
99
|
-
owner
|
|
100
|
-
dataRecency
|
|
101
|
-
sources {
|
|
102
|
-
tableId
|
|
103
|
-
tableName
|
|
104
|
-
columnId
|
|
105
|
-
columnName
|
|
106
|
-
__typename
|
|
107
|
-
}
|
|
108
|
-
synonyms
|
|
109
|
-
cohortAnswerId
|
|
110
|
-
__typename
|
|
111
|
-
}
|
|
112
|
-
relationships
|
|
113
|
-
destinationRelationships
|
|
114
|
-
dataSourceId
|
|
115
|
-
__typename
|
|
116
|
-
}
|
|
117
|
-
}
|
|
118
|
-
`;
|
|
119
|
-
const operations = {};
|
|
120
|
-
//# sourceMappingURL=graphql-queries.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"graphql-queries.js","sourceRoot":"","sources":["../../../../src/utils/answerService/graphql-queries.ts"],"names":[],"mappings":"AAAA,MAAM,aAAa,GAAG;;;;;;;;;CASrB,CAAC;AAEF,MAAM,CAAC,MAAM,4BAA4B,GAAG;;;UAGlC,aAAa;;;;;;;;;;;;;;;;;;;CAmBtB,CAAC;AAEF,MAAM,CAAC,MAAM,aAAa,GAAG;;;;;;;cAOf,aAAa;;;KAGtB,CAAC;AAEN,MAAM,CAAC,MAAM,UAAU,GAAG;;;cAGZ,aAAa;;;KAGtB,CAAC;AAEN,MAAM,CAAC,MAAM,aAAa,GAAG;;;cAGf,aAAa;;;;;;;;;;;;;;;;;;;;;CAqB1B,CAAC;AAEF,MAAM,CAAC,MAAM,eAAe,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAyC9B,CAAC;AAEF,MAAM,UAAU,GAAG,EAElB,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"graphql-queries.d.ts","sourceRoot":"","sources":["../../../../../src/utils/graphql/answerService/graphql-queries.ts"],"names":[],"mappings":"AAWA,eAAO,MAAM,4BAA4B,QAsBxC,CAAC;AAEF,eAAO,MAAM,aAAa,QAUrB,CAAC;AAEN,eAAO,MAAM,UAAU,QAMlB,CAAC;AAEN,eAAO,MAAM,aAAa,QAwBzB,CAAC"}
|
|
@@ -1,77 +0,0 @@
|
|
|
1
|
-
const bachSessionId = `
|
|
2
|
-
id {
|
|
3
|
-
sessionId
|
|
4
|
-
genNo
|
|
5
|
-
acSession {
|
|
6
|
-
sessionId
|
|
7
|
-
genNo
|
|
8
|
-
}
|
|
9
|
-
}
|
|
10
|
-
`;
|
|
11
|
-
export const getUnaggregatedAnswerSession = `
|
|
12
|
-
mutation GetUnAggregatedAnswerSession($session: BachSessionIdInput!, $columns: [UserPointSelectionInput!]!) {
|
|
13
|
-
Answer__getUnaggregatedAnswer(session: $session, columns: $columns) {
|
|
14
|
-
${bachSessionId}
|
|
15
|
-
answer {
|
|
16
|
-
visualizations {
|
|
17
|
-
... on TableViz {
|
|
18
|
-
columns {
|
|
19
|
-
column {
|
|
20
|
-
id
|
|
21
|
-
name
|
|
22
|
-
referencedColumns {
|
|
23
|
-
guid
|
|
24
|
-
displayName
|
|
25
|
-
}
|
|
26
|
-
}
|
|
27
|
-
}
|
|
28
|
-
}
|
|
29
|
-
}
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
`;
|
|
34
|
-
export const removeColumns = `
|
|
35
|
-
mutation RemoveColumns($session: BachSessionIdInput!, $logicalColumnIds: [GUID!], $columnIds: [GUID!]) {
|
|
36
|
-
Answer__removeColumns(
|
|
37
|
-
session: $session
|
|
38
|
-
logicalColumnIds: $logicalColumnIds
|
|
39
|
-
columnIds: $columnIds
|
|
40
|
-
) {
|
|
41
|
-
${bachSessionId}
|
|
42
|
-
}
|
|
43
|
-
}
|
|
44
|
-
`;
|
|
45
|
-
export const addColumns = `
|
|
46
|
-
mutation AddColumns($session: BachSessionIdInput!, $columns: [AnswerColumnInfo!]!) {
|
|
47
|
-
Answer__addColumn(session: $session, columns: $columns) {
|
|
48
|
-
${bachSessionId}
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
`;
|
|
52
|
-
export const getAnswerData = `
|
|
53
|
-
query GetTableWithHeadlineData($session: BachSessionIdInput!, $deadline: Int!, $dataPaginationParams: DataPaginationParamsInput!) {
|
|
54
|
-
getAnswer(session: $session) {
|
|
55
|
-
${bachSessionId}
|
|
56
|
-
answer {
|
|
57
|
-
id
|
|
58
|
-
visualizations {
|
|
59
|
-
id
|
|
60
|
-
... on TableViz {
|
|
61
|
-
columns {
|
|
62
|
-
column {
|
|
63
|
-
id
|
|
64
|
-
name
|
|
65
|
-
type
|
|
66
|
-
aggregationType
|
|
67
|
-
dataType
|
|
68
|
-
}
|
|
69
|
-
}
|
|
70
|
-
data(deadline: $deadline, pagination: $dataPaginationParams)
|
|
71
|
-
}
|
|
72
|
-
}
|
|
73
|
-
}
|
|
74
|
-
}
|
|
75
|
-
}
|
|
76
|
-
`;
|
|
77
|
-
//# sourceMappingURL=graphql-queries.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"graphql-queries.js","sourceRoot":"","sources":["../../../../../src/utils/graphql/answerService/graphql-queries.ts"],"names":[],"mappings":"AAAA,MAAM,aAAa,GAAG;;;;;;;;;CASrB,CAAC;AAEF,MAAM,CAAC,MAAM,4BAA4B,GAAG;;;UAGlC,aAAa;;;;;;;;;;;;;;;;;;;CAmBtB,CAAC;AAEF,MAAM,CAAC,MAAM,aAAa,GAAG;;;;;;;cAOf,aAAa;;;KAGtB,CAAC;AAEN,MAAM,CAAC,MAAM,UAAU,GAAG;;;cAGZ,aAAa;;;KAGtB,CAAC;AAEN,MAAM,CAAC,MAAM,aAAa,GAAG;;;cAGf,aAAa;;;;;;;;;;;;;;;;;;;;;CAqB1B,CAAC"}
|