diff --git a/superset-frontend/.eslintrc.js b/superset-frontend/.eslintrc.js index f97c6d2133b28..b37c5ff451dbd 100644 --- a/superset-frontend/.eslintrc.js +++ b/superset-frontend/.eslintrc.js @@ -61,8 +61,7 @@ module.exports = { moduleDirectory: ['node_modules', '.'], }, }, - // Allow only core/src and core/test, avoid import modules from lib - 'import/internal-regex': /^@superset-ui\/core\/(src|test)\/.*/, + // only allow import from top level of module 'import/core-modules': importCoreModules, react: { version: 'detect', @@ -156,6 +155,8 @@ module.exports = { '*.test.tsx', '*.test.js', '*.test.jsx', + '*.stories.tsx', + '*.stories.jsx', 'fixtures.*', ], plugins: ['jest', 'jest-dom', 'no-only-tests', 'testing-library'], diff --git a/superset-frontend/jest.config.js b/superset-frontend/jest.config.js index 90af1ee6cd343..a957fe531c790 100644 --- a/superset-frontend/jest.config.js +++ b/superset-frontend/jest.config.js @@ -19,24 +19,20 @@ module.exports = { testRegex: '\\/(spec|src|plugins|packages)\\/.*(_spec|\\.test)\\.[jt]sx?$', - testPathIgnorePatterns: [ - 'packages\\/generator-superset\\/.*', - '/node_modules/', - ], moduleNameMapper: { '\\.(css|less|geojson)$': '/spec/__mocks__/mockExportObject.js', '\\.(gif|ttf|eot|png|jpg)$': '/spec/__mocks__/mockExportString.js', '\\.svg$': '/spec/__mocks__/svgrMock.tsx', '^src/(.*)$': '/src/$1', '^spec/(.*)$': '/spec/$1', - // mapping to souce code instead of lib or esm module - '@superset-ui/(((?!(core/src)).)*)$': - '/node_modules/@superset-ui/$1/src', - '@superset-ui/core/src/(.*)$': - '/node_modules/@superset-ui/core/src/$1', + // mapping plugins of superset-ui to souce code + '@superset-ui/(.*)$': '/node_modules/@superset-ui/$1/src', }, testEnvironment: 'jsdom', - modulePathIgnorePatterns: ['/temporary_superset_ui'], + modulePathIgnorePatterns: [ + '/temporary_superset_ui', + '/packages/generator-superset', + ], setupFilesAfterEnv: ['/spec/helpers/setup.ts'], testURL: 'http://localhost', collectCoverageFrom: [ diff --git a/superset-frontend/package-lock.json b/superset-frontend/package-lock.json index cdd825a9b518f..ebf21d7e4f60d 100644 --- a/superset-frontend/package-lock.json +++ b/superset-frontend/package-lock.json @@ -64,8 +64,10 @@ "d3-scale": "^2.1.2", "dom-to-image": "^2.6.0", "emotion-rgba": "0.0.9", + "fast-glob": "^3.2.7", "fontsource-fira-code": "^3.0.5", "fontsource-inter": "^3.0.5", + "fs-extra": "^10.0.0", "fuse.js": "^6.4.6", "geolib": "^2.0.24", "global-box": "^1.2.0", @@ -14468,6 +14470,21 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/@storybook/addon-essentials/node_modules/fs-extra": { + "version": "9.1.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz", + "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==", + "dev": true, + "dependencies": { + "at-least-node": "^1.0.0", + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + }, + "engines": { + "node": ">=10" + } + }, "node_modules/@storybook/addon-essentials/node_modules/fs-minipass": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/fs-minipass/-/fs-minipass-2.1.0.tgz", @@ -16340,6 +16357,21 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/@storybook/builder-webpack5/node_modules/fs-extra": { + "version": "9.1.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz", + "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==", + "devOptional": true, + "dependencies": { + "at-least-node": "^1.0.0", + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + }, + "engines": { + "node": ">=10" + } + }, "node_modules/@storybook/builder-webpack5/node_modules/has-flag": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", @@ -17059,6 +17091,20 @@ "url": "https://opencollective.com/storybook" } }, + "node_modules/@storybook/csf-tools/node_modules/fs-extra": { + "version": "9.1.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz", + "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==", + "dependencies": { + "at-least-node": "^1.0.0", + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + }, + "engines": { + "node": ">=10" + } + }, "node_modules/@storybook/csf-tools/node_modules/prettier": { "version": "2.2.1", "resolved": "https://registry.npmjs.org/prettier/-/prettier-2.2.1.tgz", @@ -17993,6 +18039,21 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/@storybook/manager-webpack5/node_modules/fs-extra": { + "version": "9.1.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz", + "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==", + "devOptional": true, + "dependencies": { + "at-least-node": "^1.0.0", + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + }, + "engines": { + "node": ">=10" + } + }, "node_modules/@storybook/manager-webpack5/node_modules/fuse.js": { "version": "3.6.1", "resolved": "https://registry.npmjs.org/fuse.js/-/fuse.js-3.6.1.tgz", @@ -20390,6 +20451,20 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/@storybook/react/node_modules/fs-extra": { + "version": "9.1.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz", + "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==", + "dependencies": { + "at-least-node": "^1.0.0", + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + }, + "engines": { + "node": ">=10" + } + }, "node_modules/@storybook/react/node_modules/fs-minipass": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/fs-minipass/-/fs-minipass-2.1.0.tgz", @@ -21942,7 +22017,6 @@ "version": "0.22.21", "resolved": "https://registry.npmjs.org/@types/cheerio/-/cheerio-0.22.21.tgz", "integrity": "sha512-aGI3DfswwqgKPiEOTaiHV2ZPC9KEhprpgEbJnv0fZl3SGX0cGgEva1126dGrMC6AJM6v/aihlUgJn9M5DbDZ/Q==", - "dev": true, "dependencies": { "@types/node": "*" } @@ -22050,7 +22124,6 @@ "version": "3.10.10", "resolved": "https://registry.npmjs.org/@types/enzyme/-/enzyme-3.10.10.tgz", "integrity": "sha512-/D4wFhiEjUDfPu+j5FVK0g/jf7rqeEIpNfAI+kyxzLpw5CKO0drnW3W5NC38alIjsWgnyQ8pbuPF5+UD+vhVyg==", - "dev": true, "dependencies": { "@types/cheerio": "*", "@types/react": "*" @@ -22098,8 +22171,7 @@ "node_modules/@types/fetch-mock": { "version": "7.3.5", "resolved": "https://registry.npmjs.org/@types/fetch-mock/-/fetch-mock-7.3.5.tgz", - "integrity": "sha512-sLecm9ohBdGIpYUP9rWk5/XIKY2xHMYTBJIcJuBBM8IJWnYoQ1DAj8F4OVjnfD0API1drlkWEV0LPNk+ACuhsg==", - "dev": true + "integrity": "sha512-sLecm9ohBdGIpYUP9rWk5/XIKY2xHMYTBJIcJuBBM8IJWnYoQ1DAj8F4OVjnfD0API1drlkWEV0LPNk+ACuhsg==" }, "node_modules/@types/flatbuffers": { "version": "1.10.0", @@ -22359,9 +22431,9 @@ "integrity": "sha512-VjID5MJb1eGKthz2qUerWT8+R4b9N+CHvGCzg9fn4kWZgaF9AhdYikQio3R7wV8YY1NsQKPaCwKz1Yff+aHNUQ==" }, "node_modules/@types/prop-types": { - "version": "15.5.8", - "resolved": "https://registry.npmjs.org/@types/prop-types/-/prop-types-15.5.8.tgz", - "integrity": "sha512-3AQoUxQcQtLHsK25wtTWIoIpgYjH3vSDroZOUr7PpCHw/jLY1RB9z9E8dBT/OSmwStVgkRNvdh+ZHNiomRieaw==" + "version": "15.7.4", + "resolved": "https://registry.npmjs.org/@types/prop-types/-/prop-types-15.7.4.tgz", + "integrity": "sha512-rZ5drC/jWjrArrS8BR6SIr4cWpW09RNTYt9AMZo3Jwwif+iacXAqgVjm0B0Bv/S1jhDXKHqRVNCbACkJ89RAnQ==" }, "node_modules/@types/q": { "version": "1.5.2", @@ -24689,8 +24761,7 @@ "node_modules/array-filter": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/array-filter/-/array-filter-1.0.0.tgz", - "integrity": "sha1-uveeYubvTCpMC4MSMtr/7CUfnYM=", - "dev": true + "integrity": "sha1-uveeYubvTCpMC4MSMtr/7CUfnYM=" }, "node_modules/array-find-index": { "version": "1.0.2", @@ -26951,7 +27022,6 @@ "version": "1.0.0-rc.3", "resolved": "https://registry.npmjs.org/cheerio/-/cheerio-1.0.0-rc.3.tgz", "integrity": "sha512-0td5ijfUPuubwLUu0OBoe98gZj8C/AA+RW3v67GPlGOrvxWjZmBXiBCRU+I8VEiNyJzjth40POfHiz2RB3gImA==", - "dev": true, "dependencies": { "css-select": "~1.2.0", "dom-serializer": "~0.1.1", @@ -26968,7 +27038,6 @@ "version": "0.1.1", "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-0.1.1.tgz", "integrity": "sha512-l0IU0pPzLWSHBcieZbpOKgkIn3ts3vAh7ZuFyXNwJxJXk/c4Gwj9xaTJwIDVQCXawWD0qb3IzMGH5rglQaO0XA==", - "dev": true, "dependencies": { "domelementtype": "^1.3.0", "entities": "^1.1.1" @@ -27229,20 +27298,6 @@ "node": ">=6" } }, - "node_modules/chromatic/node_modules/fs-extra": { - "version": "10.0.0", - "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-10.0.0.tgz", - "integrity": "sha512-C5owb14u9eJwizKGdchcDUQeFtlSHHthBk8pbX9Vc1PFZrLombudjDnNns88aYslCyF6IY5SUw3Roz6xShcEIQ==", - "dev": true, - "dependencies": { - "graceful-fs": "^4.2.0", - "jsonfile": "^6.0.1", - "universalify": "^2.0.0" - }, - "engines": { - "node": ">=12" - } - }, "node_modules/chromatic/node_modules/get-stream": { "version": "6.0.1", "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-6.0.1.tgz", @@ -30236,7 +30291,6 @@ "version": "1.2.0", "resolved": "https://registry.npmjs.org/css-select/-/css-select-1.2.0.tgz", "integrity": "sha1-KzoRBTnFNV8c2NMUYj6HCxIeyFg=", - "dev": true, "dependencies": { "boolbase": "~1.0.0", "css-what": "2.1", @@ -30282,7 +30336,6 @@ "version": "2.1.2", "resolved": "https://registry.npmjs.org/css-what/-/css-what-2.1.2.tgz", "integrity": "sha512-wan8dMWQ0GUeF7DGEPVjhHemVW/vy6xUYmFzRY8RYqgA0JtXC9rJmbScBjqSu6dg9q0lwPQy6ZAmJVr3PPTvqQ==", - "dev": true, "engines": { "node": "*" } @@ -30570,6 +30623,22 @@ "url": "https://github.com/sindresorhus/execa?sponsor=1" } }, + "node_modules/cypress/node_modules/fs-extra": { + "version": "9.1.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz", + "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==", + "dev": true, + "peer": true, + "dependencies": { + "at-least-node": "^1.0.0", + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + }, + "engines": { + "node": ">=10" + } + }, "node_modules/cypress/node_modules/get-stream": { "version": "5.2.0", "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-5.2.0.tgz", @@ -31650,8 +31719,7 @@ "node_modules/discontinuous-range": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/discontinuous-range/-/discontinuous-range-1.0.0.tgz", - "integrity": "sha1-44Mx8IRLukm5qctxx3FYWqsbxlo=", - "dev": true + "integrity": "sha1-44Mx8IRLukm5qctxx3FYWqsbxlo=" }, "node_modules/distributions": { "version": "1.1.0", @@ -31738,7 +31806,6 @@ "version": "0.1.0", "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-0.1.0.tgz", "integrity": "sha1-BzxpdUbOB4DOI75KKOKT5AvDDII=", - "dev": true, "dependencies": { "domelementtype": "~1.1.1", "entities": "~1.1.1" @@ -31747,8 +31814,7 @@ "node_modules/dom-serializer/node_modules/domelementtype": { "version": "1.1.3", "resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-1.1.3.tgz", - "integrity": "sha1-vSh3PiZCiBrsUVRJJCmcXNgiGFs=", - "dev": true + "integrity": "sha1-vSh3PiZCiBrsUVRJJCmcXNgiGFs=" }, "node_modules/dom-to-image": { "version": "2.6.0", @@ -31772,8 +31838,7 @@ "node_modules/domelementtype": { "version": "1.3.1", "resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-1.3.1.tgz", - "integrity": "sha512-BSKB+TSpMpFI/HOxCNr1O8aMOTZ8hT3pM3GQ0w/mWRmkhEDSFJkkyzz4XQsBV44BChwGkrDfMyjVD0eA2aFV3w==", - "dev": true + "integrity": "sha512-BSKB+TSpMpFI/HOxCNr1O8aMOTZ8hT3pM3GQ0w/mWRmkhEDSFJkkyzz4XQsBV44BChwGkrDfMyjVD0eA2aFV3w==" }, "node_modules/domexception": { "version": "2.0.1", @@ -31800,7 +31865,6 @@ "version": "2.4.2", "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-2.4.2.tgz", "integrity": "sha512-JiK04h0Ht5u/80fdLMCEmV4zkNh2BcoMFBmZ/91WtYZ8qVXSKjiw7fXMgFPnHcSZgOo3XdinHvmnDUeMf5R4wA==", - "dev": true, "dependencies": { "domelementtype": "1" } @@ -31814,7 +31878,6 @@ "version": "1.5.1", "resolved": "https://registry.npmjs.org/domutils/-/domutils-1.5.1.tgz", "integrity": "sha1-3NhIiib1Y9YQeeSMn3t+Mjc2gs8=", - "dev": true, "dependencies": { "dom-serializer": "0", "domelementtype": "1" @@ -32234,8 +32297,7 @@ "node_modules/entities": { "version": "1.1.2", "resolved": "https://registry.npmjs.org/entities/-/entities-1.1.2.tgz", - "integrity": "sha512-f2LZMYl1Fzu7YSBKg+RoROelpOaNrcGmE9AZubeDfrCEia483oW4MI4VyFd5VNHIgQ/7qm1I0wUHK1eJnn2y2w==", - "dev": true + "integrity": "sha512-f2LZMYl1Fzu7YSBKg+RoROelpOaNrcGmE9AZubeDfrCEia483oW4MI4VyFd5VNHIgQ/7qm1I0wUHK1eJnn2y2w==" }, "node_modules/env-ci": { "version": "5.4.1", @@ -32403,7 +32465,6 @@ "version": "3.10.0", "resolved": "https://registry.npmjs.org/enzyme/-/enzyme-3.10.0.tgz", "integrity": "sha512-p2yy9Y7t/PFbPoTvrWde7JIYB2ZyGC+NgTNbVEGvZ5/EyoYSr9aG/2rSbVvyNvMHEhw9/dmGUJHWtfQIEiX9pg==", - "dev": true, "dependencies": { "array.prototype.flat": "^1.2.1", "cheerio": "^1.0.0-rc.2", @@ -32519,8 +32580,7 @@ "node_modules/enzyme/node_modules/object-inspect": { "version": "1.6.0", "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.6.0.tgz", - "integrity": "sha512-GJzfBZ6DgDAmnuaM3104jR4s1Myxr3Y3zfIyN4z3UdqN69oSRacNK8UhnobDdC+7J2AHCjGwxQubNJfE70SXXQ==", - "dev": true + "integrity": "sha512-GJzfBZ6DgDAmnuaM3104jR4s1Myxr3Y3zfIyN4z3UdqN69oSRacNK8UhnobDdC+7J2AHCjGwxQubNJfE70SXXQ==" }, "node_modules/err-code": { "version": "1.1.2", @@ -35339,6 +35399,20 @@ "node": ">=0.10.0" } }, + "node_modules/fork-ts-checker-webpack-plugin/node_modules/fs-extra": { + "version": "9.1.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz", + "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==", + "dependencies": { + "at-least-node": "^1.0.0", + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + }, + "engines": { + "node": ">=10" + } + }, "node_modules/fork-ts-checker-webpack-plugin/node_modules/lru-cache": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", @@ -35490,17 +35564,16 @@ ] }, "node_modules/fs-extra": { - "version": "9.1.0", - "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz", - "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==", + "version": "10.0.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-10.0.0.tgz", + "integrity": "sha512-C5owb14u9eJwizKGdchcDUQeFtlSHHthBk8pbX9Vc1PFZrLombudjDnNns88aYslCyF6IY5SUw3Roz6xShcEIQ==", "dependencies": { - "at-least-node": "^1.0.0", "graceful-fs": "^4.2.0", "jsonfile": "^6.0.1", "universalify": "^2.0.0" }, "engines": { - "node": ">=10" + "node": ">=12" } }, "node_modules/fs-minipass": { @@ -37542,7 +37615,6 @@ "version": "1.1.0", "resolved": "https://registry.npmjs.org/html-element-map/-/html-element-map-1.1.0.tgz", "integrity": "sha512-iqiG3dTZmy+uUaTmHarTL+3/A2VW9ox/9uasKEZC+R/wAtUrTcRlXPSaPqsnWPfIu8wqn09jQNwMRqzL54jSYA==", - "dev": true, "dependencies": { "array-filter": "^1.0.0" } @@ -37714,7 +37786,6 @@ "version": "3.10.1", "resolved": "https://registry.npmjs.org/htmlparser2/-/htmlparser2-3.10.1.tgz", "integrity": "sha512-IgieNijUMbkDovyoKObU1DUhm1iwNYE/fuifEoEHfd1oZKZDaONBSkal7Y01shxsM49R4XaMdGez3WnF9UfiCQ==", - "dev": true, "dependencies": { "domelementtype": "^1.3.1", "domhandler": "^2.3.0", @@ -37728,7 +37799,6 @@ "version": "3.4.0", "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.4.0.tgz", "integrity": "sha512-jItXPLmrSR8jmTRmRWJXCnGJsfy85mB3Wd/uINMXA65yrnFo0cPClFIUWzo2najVNSl+mx7/4W8ttlLWJe99pQ==", - "dev": true, "dependencies": { "inherits": "^2.0.3", "string_decoder": "^1.1.1", @@ -39120,8 +39190,7 @@ "node_modules/is-subset": { "version": "0.1.1", "resolved": "https://registry.npmjs.org/is-subset/-/is-subset-0.1.1.tgz", - "integrity": "sha1-ilkRfZMt4d4A8kX83TnOQ/HpOaY=", - "dev": true + "integrity": "sha1-ilkRfZMt4d4A8kX83TnOQ/HpOaY=" }, "node_modules/is-symbol": { "version": "1.0.4", @@ -43307,14 +43376,12 @@ "node_modules/lodash.escape": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/lodash.escape/-/lodash.escape-4.0.1.tgz", - "integrity": "sha1-yQRGkMIeBClL6qUXcS/e0fqI3pg=", - "dev": true + "integrity": "sha1-yQRGkMIeBClL6qUXcS/e0fqI3pg=" }, "node_modules/lodash.flattendeep": { "version": "4.4.0", "resolved": "https://registry.npmjs.org/lodash.flattendeep/-/lodash.flattendeep-4.4.0.tgz", - "integrity": "sha1-+wMJF/hqMTTlvJvsDWngAT3f7bI=", - "dev": true + "integrity": "sha1-+wMJF/hqMTTlvJvsDWngAT3f7bI=" }, "node_modules/lodash.flow": { "version": "3.5.0", @@ -44963,8 +45030,7 @@ "node_modules/moo": { "version": "0.4.3", "resolved": "https://registry.npmjs.org/moo/-/moo-0.4.3.tgz", - "integrity": "sha512-gFD2xGCl8YFgGHsqJ9NKRVdwlioeW3mI1iqfLNYQOv0+6JRwG58Zk9DIGQgyIaffSYaO1xsKnMaYzzNr1KyIAw==", - "dev": true + "integrity": "sha512-gFD2xGCl8YFgGHsqJ9NKRVdwlioeW3mI1iqfLNYQOv0+6JRwG58Zk9DIGQgyIaffSYaO1xsKnMaYzzNr1KyIAw==" }, "node_modules/mousetrap": { "version": "1.6.2", @@ -45172,7 +45238,6 @@ "version": "2.18.0", "resolved": "https://registry.npmjs.org/nearley/-/nearley-2.18.0.tgz", "integrity": "sha512-/zQOMCeJcioI0xJtd5RpBiWw2WP7wLe6vq8/3Yu0rEwgus/G/+pViX80oA87JdVgjRt2895mZSv2VfZmy4W1uw==", - "dev": true, "dependencies": { "commander": "^2.19.0", "moo": "^0.4.3", @@ -46140,7 +46205,6 @@ "version": "1.0.2", "resolved": "https://registry.npmjs.org/nth-check/-/nth-check-1.0.2.tgz", "integrity": "sha512-WeBOdju8SnzPN5vTUJYxYUxLeXpCaVP5i5e0LF8fg7WORF2Wd7wFX/pk0tYZk7s8T+J7VLy0Da6J1+wCT0AtHg==", - "dev": true, "dependencies": { "boolbase": "~1.0.0" } @@ -46241,7 +46305,6 @@ "version": "1.0.1", "resolved": "https://registry.npmjs.org/object-is/-/object-is-1.0.1.tgz", "integrity": "sha1-CqYOyZiaCz7Xlc9NBvYs8a1lObY=", - "devOptional": true, "engines": { "node": ">= 0.4" } @@ -47351,7 +47414,6 @@ "version": "3.0.3", "resolved": "https://registry.npmjs.org/parse5/-/parse5-3.0.3.tgz", "integrity": "sha512-rgO9Zg5LLLkfJF9E6CCmXlSE4UVceloys8JrFqCcHloC3usd/kJCyPDwH2SOlzix2j3xaP9sUX3e8+kvkuleAA==", - "dev": true, "dependencies": { "@types/node": "*" } @@ -48493,8 +48555,7 @@ "node_modules/railroad-diagrams": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/railroad-diagrams/-/railroad-diagrams-1.0.0.tgz", - "integrity": "sha1-635iZ1SN3t+4mcG5Dlc3RVnN234=", - "dev": true + "integrity": "sha1-635iZ1SN3t+4mcG5Dlc3RVnN234=" }, "node_modules/ramda": { "version": "0.26.1", @@ -48505,7 +48566,6 @@ "version": "0.4.6", "resolved": "https://registry.npmjs.org/randexp/-/randexp-0.4.6.tgz", "integrity": "sha512-80WNmd9DA0tmZrw9qQa62GPPWfuXJknrmVmLcxvq4uZBdYqb1wYoKTmnlGUchvVWe0XiLupYkBoXVOxz3C8DYQ==", - "dev": true, "dependencies": { "discontinuous-range": "1.0.0", "ret": "~0.1.10" @@ -52157,7 +52217,6 @@ "version": "2.2.3", "resolved": "https://registry.npmjs.org/rst-selector-parser/-/rst-selector-parser-2.2.3.tgz", "integrity": "sha1-gbIw6i/MYGbInjRy3nlChdmwPZE=", - "dev": true, "dependencies": { "lodash.flattendeep": "^4.4.0", "nearley": "^2.7.10" @@ -53807,7 +53866,6 @@ "version": "1.2.0", "resolved": "https://registry.npmjs.org/string.prototype.trim/-/string.prototype.trim-1.2.0.tgz", "integrity": "sha512-9EIjYD/WdlvLpn987+ctkLf0FfvBefOCuiEr2henD8X+7jfwPnyvTdmW8OJhj5p+M0/96mBdynLWkxUr+rHlpg==", - "dev": true, "dependencies": { "define-properties": "^1.1.3", "es-abstract": "^1.13.0", @@ -59927,20 +59985,6 @@ "npm": ">= 4.0.0" } }, - "packages/generator-superset/node_modules/fs-extra": { - "version": "10.0.0", - "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-10.0.0.tgz", - "integrity": "sha512-C5owb14u9eJwizKGdchcDUQeFtlSHHthBk8pbX9Vc1PFZrLombudjDnNns88aYslCyF6IY5SUw3Roz6xShcEIQ==", - "dev": true, - "dependencies": { - "graceful-fs": "^4.2.0", - "jsonfile": "^6.0.1", - "universalify": "^2.0.0" - }, - "engines": { - "node": ">=12" - } - }, "packages/superset-ui-chart-controls": { "name": "@superset-ui/chart-controls", "version": "0.18.25", @@ -59953,6 +59997,7 @@ }, "peerDependencies": { "@emotion/react": "^11.4.1", + "@types/enzyme": "^3.10.5", "@types/react": "*", "antd": "^4.9.4", "react": "^16.13.1", @@ -59970,8 +60015,11 @@ "@types/d3-scale": "^2.1.1", "@types/d3-time": "^1.0.9", "@types/d3-time-format": "^2.1.0", + "@types/enzyme": "^3.10.5", + "@types/fetch-mock": "^7.3.3", "@types/lodash": "^4.14.149", "@types/math-expression-evaluator": "^1.2.1", + "@types/prop-types": "^15.7.2", "@types/rison": "0.0.6", "@types/seedrandom": "^2.4.28", "@vx/responsive": "^0.0.199", @@ -59995,9 +60043,9 @@ }, "devDependencies": { "@emotion/styled": "^11.3.0", - "@types/fetch-mock": "^7.3.3", "fetch-mock": "^6.5.2", - "jest-mock-console": "^1.0.0" + "jest-mock-console": "^1.0.0", + "resize-observer-polyfill": "1.5.1" }, "peerDependencies": { "@emotion/cache": "^11.4.0", @@ -60252,6 +60300,21 @@ "yarn": ">=1.0.0" } }, + "packages/superset-ui-demo/node_modules/fs-extra": { + "version": "9.1.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz", + "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==", + "dev": true, + "dependencies": { + "at-least-node": "^1.0.0", + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + }, + "engines": { + "node": ">=10" + } + }, "packages/superset-ui-demo/node_modules/is-number": { "version": "7.0.0", "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", @@ -60678,6 +60741,7 @@ "viewport-mercator-project": "^6.1.1" }, "peerDependencies": { + "mapbox-gl": "*", "react": "^15 || ^16" } }, @@ -60722,6 +60786,7 @@ "prop-types": "^15.6.2" }, "peerDependencies": { + "enzyme": "*", "react": "^16.13.1" } }, @@ -60921,6 +60986,7 @@ "peerDependencies": { "@superset-ui/chart-controls": "0.x.x", "@superset-ui/core": "0.x.x", + "mapbox-gl": "*", "react": "^16.13.1", "react-dom": "^16.13.1", "react-map-gl": "^4.0.10" @@ -60993,7 +61059,8 @@ "@superset-ui/core": "0.18.25", "d3-array": "^1.2.0", "echarts": "^5.2.2", - "lodash": "^4.17.15" + "lodash": "^4.17.15", + "moment": "^2.26.0" }, "peerDependencies": { "react": "^16.13.1" @@ -61014,6 +61081,7 @@ }, "peerDependencies": { "@ant-design/icons": "^4.2.2", + "prop-types": "*", "react": "^16.13.1", "react-dom": "^16.13.1" } @@ -61027,6 +61095,7 @@ "@superset-ui/chart-controls": "0.18.25", "@superset-ui/core": "0.18.25", "@types/d3-array": "^2.9.0", + "@types/enzyme": "^3.10.5", "@types/react-table": "^7.0.29", "d3-array": "^2.4.0", "match-sorter": "^6.3.0", @@ -72245,6 +72314,18 @@ "path-exists": "^4.0.0" } }, + "fs-extra": { + "version": "9.1.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz", + "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==", + "dev": true, + "requires": { + "at-least-node": "^1.0.0", + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + } + }, "fs-minipass": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/fs-minipass/-/fs-minipass-2.1.0.tgz", @@ -73627,6 +73708,18 @@ "path-exists": "^4.0.0" } }, + "fs-extra": { + "version": "9.1.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz", + "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==", + "devOptional": true, + "requires": { + "at-least-node": "^1.0.0", + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + } + }, "has-flag": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", @@ -74141,6 +74234,17 @@ "regenerator-runtime": "^0.13.7" }, "dependencies": { + "fs-extra": { + "version": "9.1.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz", + "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==", + "requires": { + "at-least-node": "^1.0.0", + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + } + }, "prettier": { "version": "2.2.1", "resolved": "https://registry.npmjs.org/prettier/-/prettier-2.2.1.tgz", @@ -74850,6 +74954,18 @@ "path-exists": "^4.0.0" } }, + "fs-extra": { + "version": "9.1.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz", + "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==", + "devOptional": true, + "requires": { + "at-least-node": "^1.0.0", + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + } + }, "fuse.js": { "version": "3.6.1", "resolved": "https://registry.npmjs.org/fuse.js/-/fuse.js-3.6.1.tgz", @@ -76458,6 +76574,17 @@ "path-exists": "^4.0.0" } }, + "fs-extra": { + "version": "9.1.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz", + "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==", + "requires": { + "at-least-node": "^1.0.0", + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + } + }, "fs-minipass": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/fs-minipass/-/fs-minipass-2.1.0.tgz", @@ -77276,9 +77403,11 @@ "@types/d3-scale": "^2.1.1", "@types/d3-time": "^1.0.9", "@types/d3-time-format": "^2.1.0", + "@types/enzyme": "^3.10.5", "@types/fetch-mock": "^7.3.3", "@types/lodash": "^4.14.149", "@types/math-expression-evaluator": "^1.2.1", + "@types/prop-types": "^15.7.2", "@types/rison": "0.0.6", "@types/seedrandom": "^2.4.28", "@vx/responsive": "^0.0.199", @@ -77298,6 +77427,7 @@ "react-error-boundary": "^1.2.5", "react-markdown": "^4.3.1", "reselect": "^4.0.0", + "resize-observer-polyfill": "1.5.1", "rison": "^0.1.1", "seedrandom": "^3.0.5", "whatwg-fetch": "^3.0.0" @@ -77507,6 +77637,18 @@ "tapable": "^1.0.0" } }, + "fs-extra": { + "version": "9.1.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz", + "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==", + "dev": true, + "requires": { + "at-least-node": "^1.0.0", + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + } + }, "is-number": { "version": "7.0.0", "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", @@ -77660,19 +77802,6 @@ "yeoman-generator": "^4.0.0", "yeoman-test": "^6.2.0", "yosay": "^2.0.2" - }, - "dependencies": { - "fs-extra": { - "version": "10.0.0", - "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-10.0.0.tgz", - "integrity": "sha512-C5owb14u9eJwizKGdchcDUQeFtlSHHthBk8pbX9Vc1PFZrLombudjDnNns88aYslCyF6IY5SUw3Roz6xShcEIQ==", - "dev": true, - "requires": { - "graceful-fs": "^4.2.0", - "jsonfile": "^6.0.1", - "universalify": "^2.0.0" - } - } } }, "@superset-ui/legacy-plugin-chart-calendar": { @@ -78112,7 +78241,8 @@ "@superset-ui/core": "0.18.25", "d3-array": "^1.2.0", "echarts": "^5.2.2", - "lodash": "^4.17.15" + "lodash": "^4.17.15", + "moment": "^2.26.0" } }, "@superset-ui/plugin-chart-pivot-table": { @@ -78132,6 +78262,7 @@ "@superset-ui/chart-controls": "0.18.25", "@superset-ui/core": "0.18.25", "@types/d3-array": "^2.9.0", + "@types/enzyme": "^3.10.5", "@types/react-table": "^7.0.29", "d3-array": "^2.4.0", "match-sorter": "^6.3.0", @@ -78622,7 +78753,6 @@ "version": "0.22.21", "resolved": "https://registry.npmjs.org/@types/cheerio/-/cheerio-0.22.21.tgz", "integrity": "sha512-aGI3DfswwqgKPiEOTaiHV2ZPC9KEhprpgEbJnv0fZl3SGX0cGgEva1126dGrMC6AJM6v/aihlUgJn9M5DbDZ/Q==", - "dev": true, "requires": { "@types/node": "*" } @@ -78730,7 +78860,6 @@ "version": "3.10.10", "resolved": "https://registry.npmjs.org/@types/enzyme/-/enzyme-3.10.10.tgz", "integrity": "sha512-/D4wFhiEjUDfPu+j5FVK0g/jf7rqeEIpNfAI+kyxzLpw5CKO0drnW3W5NC38alIjsWgnyQ8pbuPF5+UD+vhVyg==", - "dev": true, "requires": { "@types/cheerio": "*", "@types/react": "*" @@ -78778,8 +78907,7 @@ "@types/fetch-mock": { "version": "7.3.5", "resolved": "https://registry.npmjs.org/@types/fetch-mock/-/fetch-mock-7.3.5.tgz", - "integrity": "sha512-sLecm9ohBdGIpYUP9rWk5/XIKY2xHMYTBJIcJuBBM8IJWnYoQ1DAj8F4OVjnfD0API1drlkWEV0LPNk+ACuhsg==", - "dev": true + "integrity": "sha512-sLecm9ohBdGIpYUP9rWk5/XIKY2xHMYTBJIcJuBBM8IJWnYoQ1DAj8F4OVjnfD0API1drlkWEV0LPNk+ACuhsg==" }, "@types/flatbuffers": { "version": "1.10.0", @@ -79038,9 +79166,9 @@ "integrity": "sha512-VjID5MJb1eGKthz2qUerWT8+R4b9N+CHvGCzg9fn4kWZgaF9AhdYikQio3R7wV8YY1NsQKPaCwKz1Yff+aHNUQ==" }, "@types/prop-types": { - "version": "15.5.8", - "resolved": "https://registry.npmjs.org/@types/prop-types/-/prop-types-15.5.8.tgz", - "integrity": "sha512-3AQoUxQcQtLHsK25wtTWIoIpgYjH3vSDroZOUr7PpCHw/jLY1RB9z9E8dBT/OSmwStVgkRNvdh+ZHNiomRieaw==" + "version": "15.7.4", + "resolved": "https://registry.npmjs.org/@types/prop-types/-/prop-types-15.7.4.tgz", + "integrity": "sha512-rZ5drC/jWjrArrS8BR6SIr4cWpW09RNTYt9AMZo3Jwwif+iacXAqgVjm0B0Bv/S1jhDXKHqRVNCbACkJ89RAnQ==" }, "@types/q": { "version": "1.5.2", @@ -80914,8 +81042,7 @@ "array-filter": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/array-filter/-/array-filter-1.0.0.tgz", - "integrity": "sha1-uveeYubvTCpMC4MSMtr/7CUfnYM=", - "dev": true + "integrity": "sha1-uveeYubvTCpMC4MSMtr/7CUfnYM=" }, "array-find-index": { "version": "1.0.2", @@ -82691,7 +82818,6 @@ "version": "1.0.0-rc.3", "resolved": "https://registry.npmjs.org/cheerio/-/cheerio-1.0.0-rc.3.tgz", "integrity": "sha512-0td5ijfUPuubwLUu0OBoe98gZj8C/AA+RW3v67GPlGOrvxWjZmBXiBCRU+I8VEiNyJzjth40POfHiz2RB3gImA==", - "dev": true, "requires": { "css-select": "~1.2.0", "dom-serializer": "~0.1.1", @@ -82705,7 +82831,6 @@ "version": "0.1.1", "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-0.1.1.tgz", "integrity": "sha512-l0IU0pPzLWSHBcieZbpOKgkIn3ts3vAh7ZuFyXNwJxJXk/c4Gwj9xaTJwIDVQCXawWD0qb3IzMGH5rglQaO0XA==", - "dev": true, "requires": { "domelementtype": "^1.3.0", "entities": "^1.1.1" @@ -82907,17 +83032,6 @@ "locate-path": "^3.0.0" } }, - "fs-extra": { - "version": "10.0.0", - "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-10.0.0.tgz", - "integrity": "sha512-C5owb14u9eJwizKGdchcDUQeFtlSHHthBk8pbX9Vc1PFZrLombudjDnNns88aYslCyF6IY5SUw3Roz6xShcEIQ==", - "dev": true, - "requires": { - "graceful-fs": "^4.2.0", - "jsonfile": "^6.0.1", - "universalify": "^2.0.0" - } - }, "get-stream": { "version": "6.0.1", "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-6.0.1.tgz", @@ -85175,7 +85289,6 @@ "version": "1.2.0", "resolved": "https://registry.npmjs.org/css-select/-/css-select-1.2.0.tgz", "integrity": "sha1-KzoRBTnFNV8c2NMUYj6HCxIeyFg=", - "dev": true, "requires": { "boolbase": "~1.0.0", "css-what": "2.1", @@ -85216,8 +85329,7 @@ "css-what": { "version": "2.1.2", "resolved": "https://registry.npmjs.org/css-what/-/css-what-2.1.2.tgz", - "integrity": "sha512-wan8dMWQ0GUeF7DGEPVjhHemVW/vy6xUYmFzRY8RYqgA0JtXC9rJmbScBjqSu6dg9q0lwPQy6ZAmJVr3PPTvqQ==", - "dev": true + "integrity": "sha512-wan8dMWQ0GUeF7DGEPVjhHemVW/vy6xUYmFzRY8RYqgA0JtXC9rJmbScBjqSu6dg9q0lwPQy6ZAmJVr3PPTvqQ==" }, "css.escape": { "version": "1.5.1", @@ -85428,6 +85540,19 @@ "strip-final-newline": "^2.0.0" } }, + "fs-extra": { + "version": "9.1.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz", + "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==", + "dev": true, + "peer": true, + "requires": { + "at-least-node": "^1.0.0", + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + } + }, "get-stream": { "version": "5.2.0", "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-5.2.0.tgz", @@ -86305,8 +86430,7 @@ "discontinuous-range": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/discontinuous-range/-/discontinuous-range-1.0.0.tgz", - "integrity": "sha1-44Mx8IRLukm5qctxx3FYWqsbxlo=", - "dev": true + "integrity": "sha1-44Mx8IRLukm5qctxx3FYWqsbxlo=" }, "distributions": { "version": "1.1.0", @@ -86390,7 +86514,6 @@ "version": "0.1.0", "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-0.1.0.tgz", "integrity": "sha1-BzxpdUbOB4DOI75KKOKT5AvDDII=", - "dev": true, "requires": { "domelementtype": "~1.1.1", "entities": "~1.1.1" @@ -86399,8 +86522,7 @@ "domelementtype": { "version": "1.1.3", "resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-1.1.3.tgz", - "integrity": "sha1-vSh3PiZCiBrsUVRJJCmcXNgiGFs=", - "dev": true + "integrity": "sha1-vSh3PiZCiBrsUVRJJCmcXNgiGFs=" } } }, @@ -86422,8 +86544,7 @@ "domelementtype": { "version": "1.3.1", "resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-1.3.1.tgz", - "integrity": "sha512-BSKB+TSpMpFI/HOxCNr1O8aMOTZ8hT3pM3GQ0w/mWRmkhEDSFJkkyzz4XQsBV44BChwGkrDfMyjVD0eA2aFV3w==", - "dev": true + "integrity": "sha512-BSKB+TSpMpFI/HOxCNr1O8aMOTZ8hT3pM3GQ0w/mWRmkhEDSFJkkyzz4XQsBV44BChwGkrDfMyjVD0eA2aFV3w==" }, "domexception": { "version": "2.0.1", @@ -86446,7 +86567,6 @@ "version": "2.4.2", "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-2.4.2.tgz", "integrity": "sha512-JiK04h0Ht5u/80fdLMCEmV4zkNh2BcoMFBmZ/91WtYZ8qVXSKjiw7fXMgFPnHcSZgOo3XdinHvmnDUeMf5R4wA==", - "dev": true, "requires": { "domelementtype": "1" } @@ -86460,7 +86580,6 @@ "version": "1.5.1", "resolved": "https://registry.npmjs.org/domutils/-/domutils-1.5.1.tgz", "integrity": "sha1-3NhIiib1Y9YQeeSMn3t+Mjc2gs8=", - "dev": true, "requires": { "dom-serializer": "0", "domelementtype": "1" @@ -86838,8 +86957,7 @@ "entities": { "version": "1.1.2", "resolved": "https://registry.npmjs.org/entities/-/entities-1.1.2.tgz", - "integrity": "sha512-f2LZMYl1Fzu7YSBKg+RoROelpOaNrcGmE9AZubeDfrCEia483oW4MI4VyFd5VNHIgQ/7qm1I0wUHK1eJnn2y2w==", - "dev": true + "integrity": "sha512-f2LZMYl1Fzu7YSBKg+RoROelpOaNrcGmE9AZubeDfrCEia483oW4MI4VyFd5VNHIgQ/7qm1I0wUHK1eJnn2y2w==" }, "env-ci": { "version": "5.4.1", @@ -86955,7 +87073,6 @@ "version": "3.10.0", "resolved": "https://registry.npmjs.org/enzyme/-/enzyme-3.10.0.tgz", "integrity": "sha512-p2yy9Y7t/PFbPoTvrWde7JIYB2ZyGC+NgTNbVEGvZ5/EyoYSr9aG/2rSbVvyNvMHEhw9/dmGUJHWtfQIEiX9pg==", - "dev": true, "requires": { "array.prototype.flat": "^1.2.1", "cheerio": "^1.0.0-rc.2", @@ -86983,8 +87100,7 @@ "object-inspect": { "version": "1.6.0", "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.6.0.tgz", - "integrity": "sha512-GJzfBZ6DgDAmnuaM3104jR4s1Myxr3Y3zfIyN4z3UdqN69oSRacNK8UhnobDdC+7J2AHCjGwxQubNJfE70SXXQ==", - "dev": true + "integrity": "sha512-GJzfBZ6DgDAmnuaM3104jR4s1Myxr3Y3zfIyN4z3UdqN69oSRacNK8UhnobDdC+7J2AHCjGwxQubNJfE70SXXQ==" } } }, @@ -89222,6 +89338,17 @@ "resolved": "https://registry.npmjs.org/deepmerge/-/deepmerge-4.2.2.tgz", "integrity": "sha512-FJ3UgI4gIl+PHZm53knsuSFpE+nESMr7M4v9QcgB7S63Kj/6WqMiFQJpBBYz1Pt+66bZpP3Q7Lye0Oo9MPKEdg==" }, + "fs-extra": { + "version": "9.1.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz", + "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==", + "requires": { + "at-least-node": "^1.0.0", + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + } + }, "lru-cache": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", @@ -89321,11 +89448,10 @@ "dev": true }, "fs-extra": { - "version": "9.1.0", - "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-9.1.0.tgz", - "integrity": "sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==", + "version": "10.0.0", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-10.0.0.tgz", + "integrity": "sha512-C5owb14u9eJwizKGdchcDUQeFtlSHHthBk8pbX9Vc1PFZrLombudjDnNns88aYslCyF6IY5SUw3Roz6xShcEIQ==", "requires": { - "at-least-node": "^1.0.0", "graceful-fs": "^4.2.0", "jsonfile": "^6.0.1", "universalify": "^2.0.0" @@ -90877,7 +91003,6 @@ "version": "1.1.0", "resolved": "https://registry.npmjs.org/html-element-map/-/html-element-map-1.1.0.tgz", "integrity": "sha512-iqiG3dTZmy+uUaTmHarTL+3/A2VW9ox/9uasKEZC+R/wAtUrTcRlXPSaPqsnWPfIu8wqn09jQNwMRqzL54jSYA==", - "dev": true, "requires": { "array-filter": "^1.0.0" } @@ -91017,7 +91142,6 @@ "version": "3.10.1", "resolved": "https://registry.npmjs.org/htmlparser2/-/htmlparser2-3.10.1.tgz", "integrity": "sha512-IgieNijUMbkDovyoKObU1DUhm1iwNYE/fuifEoEHfd1oZKZDaONBSkal7Y01shxsM49R4XaMdGez3WnF9UfiCQ==", - "dev": true, "requires": { "domelementtype": "^1.3.1", "domhandler": "^2.3.0", @@ -91031,7 +91155,6 @@ "version": "3.4.0", "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.4.0.tgz", "integrity": "sha512-jItXPLmrSR8jmTRmRWJXCnGJsfy85mB3Wd/uINMXA65yrnFo0cPClFIUWzo2najVNSl+mx7/4W8ttlLWJe99pQ==", - "dev": true, "requires": { "inherits": "^2.0.3", "string_decoder": "^1.1.1", @@ -92070,8 +92193,7 @@ "is-subset": { "version": "0.1.1", "resolved": "https://registry.npmjs.org/is-subset/-/is-subset-0.1.1.tgz", - "integrity": "sha1-ilkRfZMt4d4A8kX83TnOQ/HpOaY=", - "dev": true + "integrity": "sha1-ilkRfZMt4d4A8kX83TnOQ/HpOaY=" }, "is-symbol": { "version": "1.0.4", @@ -95336,14 +95458,12 @@ "lodash.escape": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/lodash.escape/-/lodash.escape-4.0.1.tgz", - "integrity": "sha1-yQRGkMIeBClL6qUXcS/e0fqI3pg=", - "dev": true + "integrity": "sha1-yQRGkMIeBClL6qUXcS/e0fqI3pg=" }, "lodash.flattendeep": { "version": "4.4.0", "resolved": "https://registry.npmjs.org/lodash.flattendeep/-/lodash.flattendeep-4.4.0.tgz", - "integrity": "sha1-+wMJF/hqMTTlvJvsDWngAT3f7bI=", - "dev": true + "integrity": "sha1-+wMJF/hqMTTlvJvsDWngAT3f7bI=" }, "lodash.flow": { "version": "3.5.0", @@ -96671,8 +96791,7 @@ "moo": { "version": "0.4.3", "resolved": "https://registry.npmjs.org/moo/-/moo-0.4.3.tgz", - "integrity": "sha512-gFD2xGCl8YFgGHsqJ9NKRVdwlioeW3mI1iqfLNYQOv0+6JRwG58Zk9DIGQgyIaffSYaO1xsKnMaYzzNr1KyIAw==", - "dev": true + "integrity": "sha512-gFD2xGCl8YFgGHsqJ9NKRVdwlioeW3mI1iqfLNYQOv0+6JRwG58Zk9DIGQgyIaffSYaO1xsKnMaYzzNr1KyIAw==" }, "mousetrap": { "version": "1.6.2", @@ -96856,7 +96975,6 @@ "version": "2.18.0", "resolved": "https://registry.npmjs.org/nearley/-/nearley-2.18.0.tgz", "integrity": "sha512-/zQOMCeJcioI0xJtd5RpBiWw2WP7wLe6vq8/3Yu0rEwgus/G/+pViX80oA87JdVgjRt2895mZSv2VfZmy4W1uw==", - "dev": true, "requires": { "commander": "^2.19.0", "moo": "^0.4.3", @@ -97657,7 +97775,6 @@ "version": "1.0.2", "resolved": "https://registry.npmjs.org/nth-check/-/nth-check-1.0.2.tgz", "integrity": "sha512-WeBOdju8SnzPN5vTUJYxYUxLeXpCaVP5i5e0LF8fg7WORF2Wd7wFX/pk0tYZk7s8T+J7VLy0Da6J1+wCT0AtHg==", - "dev": true, "requires": { "boolbase": "~1.0.0" } @@ -97737,8 +97854,7 @@ "object-is": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/object-is/-/object-is-1.0.1.tgz", - "integrity": "sha1-CqYOyZiaCz7Xlc9NBvYs8a1lObY=", - "devOptional": true + "integrity": "sha1-CqYOyZiaCz7Xlc9NBvYs8a1lObY=" }, "object-keys": { "version": "1.1.1", @@ -98608,7 +98724,6 @@ "version": "3.0.3", "resolved": "https://registry.npmjs.org/parse5/-/parse5-3.0.3.tgz", "integrity": "sha512-rgO9Zg5LLLkfJF9E6CCmXlSE4UVceloys8JrFqCcHloC3usd/kJCyPDwH2SOlzix2j3xaP9sUX3e8+kvkuleAA==", - "dev": true, "requires": { "@types/node": "*" } @@ -99499,8 +99614,7 @@ "railroad-diagrams": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/railroad-diagrams/-/railroad-diagrams-1.0.0.tgz", - "integrity": "sha1-635iZ1SN3t+4mcG5Dlc3RVnN234=", - "dev": true + "integrity": "sha1-635iZ1SN3t+4mcG5Dlc3RVnN234=" }, "ramda": { "version": "0.26.1", @@ -99511,7 +99625,6 @@ "version": "0.4.6", "resolved": "https://registry.npmjs.org/randexp/-/randexp-0.4.6.tgz", "integrity": "sha512-80WNmd9DA0tmZrw9qQa62GPPWfuXJknrmVmLcxvq4uZBdYqb1wYoKTmnlGUchvVWe0XiLupYkBoXVOxz3C8DYQ==", - "dev": true, "requires": { "discontinuous-range": "1.0.0", "ret": "~0.1.10" @@ -102333,7 +102446,6 @@ "version": "2.2.3", "resolved": "https://registry.npmjs.org/rst-selector-parser/-/rst-selector-parser-2.2.3.tgz", "integrity": "sha1-gbIw6i/MYGbInjRy3nlChdmwPZE=", - "dev": true, "requires": { "lodash.flattendeep": "^4.4.0", "nearley": "^2.7.10" @@ -103679,7 +103791,6 @@ "version": "1.2.0", "resolved": "https://registry.npmjs.org/string.prototype.trim/-/string.prototype.trim-1.2.0.tgz", "integrity": "sha512-9EIjYD/WdlvLpn987+ctkLf0FfvBefOCuiEr2henD8X+7jfwPnyvTdmW8OJhj5p+M0/96mBdynLWkxUr+rHlpg==", - "dev": true, "requires": { "define-properties": "^1.1.3", "es-abstract": "^1.13.0", diff --git a/superset-frontend/package.json b/superset-frontend/package.json index 565242d5e3c04..f14075b262ec3 100644 --- a/superset-frontend/package.json +++ b/superset-frontend/package.json @@ -124,8 +124,10 @@ "d3-scale": "^2.1.2", "dom-to-image": "^2.6.0", "emotion-rgba": "0.0.9", + "fast-glob": "^3.2.7", "fontsource-fira-code": "^3.0.5", "fontsource-inter": "^3.0.5", + "fs-extra": "^10.0.0", "fuse.js": "^6.4.6", "geolib": "^2.0.24", "global-box": "^1.2.0", diff --git a/superset-frontend/packages/superset-ui-chart-controls/package.json b/superset-frontend/packages/superset-ui-chart-controls/package.json index 1b8e79bb2c051..0a24d05c63ee0 100644 --- a/superset-frontend/packages/superset-ui-chart-controls/package.json +++ b/superset-frontend/packages/superset-ui-chart-controls/package.json @@ -36,6 +36,7 @@ "@types/react": "*", "antd": "^4.9.4", "react": "^16.13.1", - "react-dom": "^16.13.1" + "react-dom": "^16.13.1", + "@types/enzyme": "^3.10.5" } } diff --git a/superset-frontend/packages/superset-ui-core/package.json b/superset-frontend/packages/superset-ui-core/package.json index d066080b26f92..0b9713bc4346b 100644 --- a/superset-frontend/packages/superset-ui-core/package.json +++ b/superset-frontend/packages/superset-ui-core/package.json @@ -27,7 +27,7 @@ }, "devDependencies": { "@emotion/styled": "^11.3.0", - "@types/fetch-mock": "^7.3.3", + "resize-observer-polyfill": "1.5.1", "fetch-mock": "^6.5.2", "jest-mock-console": "^1.0.0" }, @@ -42,6 +42,9 @@ "@types/math-expression-evaluator": "^1.2.1", "@types/rison": "0.0.6", "@types/seedrandom": "^2.4.28", + "@types/fetch-mock": "^7.3.3", + "@types/enzyme": "^3.10.5", + "@types/prop-types": "^15.7.2", "@vx/responsive": "^0.0.199", "csstype": "^2.6.4", "d3-format": "^1.3.2", diff --git a/superset-frontend/packages/superset-ui-core/test/chart-composition/ChartFrame.test.tsx b/superset-frontend/packages/superset-ui-core/test/chart-composition/ChartFrame.test.tsx index a83f120af5531..777a7b2a2a521 100644 --- a/superset-frontend/packages/superset-ui-core/test/chart-composition/ChartFrame.test.tsx +++ b/superset-frontend/packages/superset-ui-core/test/chart-composition/ChartFrame.test.tsx @@ -19,7 +19,7 @@ import React from 'react'; import { shallow } from 'enzyme'; -import { ChartFrame } from '@superset-ui/core/src'; +import { ChartFrame } from '@superset-ui/core'; describe('TooltipFrame', () => { it('renders content that requires smaller space than frame', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/chart-composition/legend/WithLegend.test.tsx b/superset-frontend/packages/superset-ui-core/test/chart-composition/legend/WithLegend.test.tsx index ddef03bf47170..ebb53366987c9 100644 --- a/superset-frontend/packages/superset-ui-core/test/chart-composition/legend/WithLegend.test.tsx +++ b/superset-frontend/packages/superset-ui-core/test/chart-composition/legend/WithLegend.test.tsx @@ -20,8 +20,7 @@ import React from 'react'; import { mount, shallow } from 'enzyme'; import { triggerResizeObserver } from 'resize-observer-polyfill'; -import { promiseTimeout } from '@superset-ui/core/src'; -import { WithLegend } from '@superset-ui/core/src/chart-composition'; +import { promiseTimeout, WithLegend } from '@superset-ui/core'; let renderChart = jest.fn(); let renderLegend = jest.fn(); diff --git a/superset-frontend/packages/superset-ui-core/test/chart-composition/tooltip/TooltipFrame.test.tsx b/superset-frontend/packages/superset-ui-core/test/chart-composition/tooltip/TooltipFrame.test.tsx index 45b5dd6f733df..c2db1c36148db 100644 --- a/superset-frontend/packages/superset-ui-core/test/chart-composition/tooltip/TooltipFrame.test.tsx +++ b/superset-frontend/packages/superset-ui-core/test/chart-composition/tooltip/TooltipFrame.test.tsx @@ -19,7 +19,7 @@ import React from 'react'; import { shallow } from 'enzyme'; -import { TooltipFrame } from '@superset-ui/core/src'; +import { TooltipFrame } from '@superset-ui/core'; describe('TooltipFrame', () => { it('sets className', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/chart-composition/tooltip/TooltipTable.test.tsx b/superset-frontend/packages/superset-ui-core/test/chart-composition/tooltip/TooltipTable.test.tsx index 29597214839f1..b339bab537208 100644 --- a/superset-frontend/packages/superset-ui-core/test/chart-composition/tooltip/TooltipTable.test.tsx +++ b/superset-frontend/packages/superset-ui-core/test/chart-composition/tooltip/TooltipTable.test.tsx @@ -19,7 +19,7 @@ import React from 'react'; import { shallow } from 'enzyme'; -import { TooltipTable } from '@superset-ui/core/src'; +import { TooltipTable } from '@superset-ui/core'; describe('TooltipTable', () => { it('sets className', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/chart/clients/ChartClient.test.ts b/superset-frontend/packages/superset-ui-core/test/chart/clients/ChartClient.test.ts index bfa16e9c35367..9992ca9381853 100644 --- a/superset-frontend/packages/superset-ui-core/test/chart/clients/ChartClient.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/chart/clients/ChartClient.test.ts @@ -24,17 +24,15 @@ import { buildQueryContext, QueryFormData, configure as configureTranslation, -} from '@superset-ui/core/src'; - -import { ChartClient, getChartBuildQueryRegistry, getChartMetadataRegistry, ChartMetadata, -} from '@superset-ui/core/src/chart'; -import { SliceIdAndOrFormData } from '@superset-ui/core/src/chart/clients/ChartClient'; +} from '@superset-ui/core'; + import { LOGIN_GLOB } from '../fixtures/constants'; import { sankeyFormData } from '../fixtures/formData'; +import { SliceIdAndOrFormData } from '../../../src/chart/clients/ChartClient'; configureTranslation(); diff --git a/superset-frontend/packages/superset-ui-core/test/chart/components/ChartDataProvider.test.tsx b/superset-frontend/packages/superset-ui-core/test/chart/components/ChartDataProvider.test.tsx index 3efe4b1214acf..ec0d73c4b8bca 100644 --- a/superset-frontend/packages/superset-ui-core/test/chart/components/ChartDataProvider.test.tsx +++ b/superset-frontend/packages/superset-ui-core/test/chart/components/ChartDataProvider.test.tsx @@ -19,10 +19,10 @@ import React from 'react'; import { shallow } from 'enzyme'; -import ChartClient from '@superset-ui/core/src/chart/clients/ChartClient'; +import ChartClient from '../../../src/chart/clients/ChartClient'; import ChartDataProvider, { ChartDataProviderProps, -} from '@superset-ui/core/src/chart/components/ChartDataProvider'; +} from '../../../src/chart/components/ChartDataProvider'; import { bigNumberFormData } from '../fixtures/formData'; // Note: the mock implementation of these function directly affects the expected results below @@ -50,7 +50,7 @@ const mockLoadQueryData = jest.fn, unknown[]>( ); // ChartClient is now a mock -jest.mock('@superset-ui/core/src/chart/clients/ChartClient', () => +jest.mock('../../../src/chart/clients/ChartClient', () => jest.fn().mockImplementation(() => ({ loadDatasource: mockLoadDatasource, loadFormData: mockLoadFormData, diff --git a/superset-frontend/packages/superset-ui-core/test/chart/components/FallbackComponent.test.tsx b/superset-frontend/packages/superset-ui-core/test/chart/components/FallbackComponent.test.tsx index ef47e11410ed3..f5d2bf0df2e72 100644 --- a/superset-frontend/packages/superset-ui-core/test/chart/components/FallbackComponent.test.tsx +++ b/superset-frontend/packages/superset-ui-core/test/chart/components/FallbackComponent.test.tsx @@ -19,7 +19,7 @@ import React from 'react'; import { shallow } from 'enzyme'; -import FallbackComponent from '@superset-ui/core/src/chart/components/FallbackComponent'; +import FallbackComponent from '../../../src/chart/components/FallbackComponent'; describe('FallbackComponent', () => { const ERROR = new Error('CaffeineOverLoadException'); diff --git a/superset-frontend/packages/superset-ui-core/test/chart/components/NoResultsComponent.test.tsx b/superset-frontend/packages/superset-ui-core/test/chart/components/NoResultsComponent.test.tsx index 3a2ace08f6b92..333a0cb8750a6 100644 --- a/superset-frontend/packages/superset-ui-core/test/chart/components/NoResultsComponent.test.tsx +++ b/superset-frontend/packages/superset-ui-core/test/chart/components/NoResultsComponent.test.tsx @@ -19,8 +19,8 @@ import React from 'react'; import { shallow } from 'enzyme'; -import NoResultsComponent from '@superset-ui/core/src/chart/components/NoResultsComponent'; -import { configure } from '@superset-ui/core/src'; +import { configure } from '@superset-ui/core'; +import NoResultsComponent from '../../../src/chart/components/NoResultsComponent'; configure(); diff --git a/superset-frontend/packages/superset-ui-core/test/chart/components/SuperChart.test.tsx b/superset-frontend/packages/superset-ui-core/test/chart/components/SuperChart.test.tsx index b5b833ca01ff6..870dda1040442 100644 --- a/superset-frontend/packages/superset-ui-core/test/chart/components/SuperChart.test.tsx +++ b/superset-frontend/packages/superset-ui-core/test/chart/components/SuperChart.test.tsx @@ -20,15 +20,14 @@ import React from 'react'; import { mount } from 'enzyme'; import mockConsole, { RestoreConsole } from 'jest-mock-console'; - import { triggerResizeObserver } from 'resize-observer-polyfill'; import ErrorBoundary from 'react-error-boundary'; -import { promiseTimeout } from '@superset-ui/core'; -import { SuperChart } from '@superset-ui/core/src/chart'; + +import { promiseTimeout, SuperChart } from '@superset-ui/core'; import RealSuperChart, { WrapperProps, -} from '@superset-ui/core/src/chart/components/SuperChart'; -import NoResultsComponent from '@superset-ui/core/src/chart/components/NoResultsComponent'; +} from '../../../src/chart/components/SuperChart'; +import NoResultsComponent from '../../../src/chart/components/NoResultsComponent'; import { ChartKeys, diff --git a/superset-frontend/packages/superset-ui-core/test/chart/components/SuperChartCore.test.tsx b/superset-frontend/packages/superset-ui-core/test/chart/components/SuperChartCore.test.tsx index bad750bb2eccf..21e75e11d51f9 100644 --- a/superset-frontend/packages/superset-ui-core/test/chart/components/SuperChartCore.test.tsx +++ b/superset-frontend/packages/superset-ui-core/test/chart/components/SuperChartCore.test.tsx @@ -19,11 +19,10 @@ import React from 'react'; import { mount, shallow } from 'enzyme'; -import { promiseTimeout } from '@superset-ui/core'; import mockConsole, { RestoreConsole } from 'jest-mock-console'; -import { ChartProps } from '@superset-ui/core/src/chart'; -import SuperChartCore from '@superset-ui/core/src/chart/components/SuperChartCore'; +import { ChartProps, promiseTimeout } from '@superset-ui/core'; +import SuperChartCore from '../../../src/chart/components/SuperChartCore'; import { ChartKeys, DiligentChartPlugin, diff --git a/superset-frontend/packages/superset-ui-core/test/chart/components/createLoadableRenderer.test.tsx b/superset-frontend/packages/superset-ui-core/test/chart/components/createLoadableRenderer.test.tsx index 7befbdb105e86..34ab7a3cc6990 100644 --- a/superset-frontend/packages/superset-ui-core/test/chart/components/createLoadableRenderer.test.tsx +++ b/superset-frontend/packages/superset-ui-core/test/chart/components/createLoadableRenderer.test.tsx @@ -22,7 +22,7 @@ import { shallow } from 'enzyme'; import mockConsole, { RestoreConsole } from 'jest-mock-console'; import createLoadableRenderer, { LoadableRenderer as LoadableRendererType, -} from '@superset-ui/core/src/chart/components/createLoadableRenderer'; +} from '../../../src/chart/components/createLoadableRenderer'; describe('createLoadableRenderer', () => { function TestComponent() { diff --git a/superset-frontend/packages/superset-ui-core/test/chart/components/reactify.test.tsx b/superset-frontend/packages/superset-ui-core/test/chart/components/reactify.test.tsx index 793ced8060566..121f815c4cc4f 100644 --- a/superset-frontend/packages/superset-ui-core/test/chart/components/reactify.test.tsx +++ b/superset-frontend/packages/superset-ui-core/test/chart/components/reactify.test.tsx @@ -20,9 +20,8 @@ import PropTypes from 'prop-types'; import React from 'react'; import { mount } from 'enzyme'; -import reactify, { - RenderFuncType, -} from '@superset-ui/core/src/chart/components/reactify'; +import { reactify } from '@superset-ui/core'; +import { RenderFuncType } from '../../../src/chart/components/reactify'; describe('reactify(renderFn)', () => { const renderFn: RenderFuncType<{ content?: string }> = jest.fn( diff --git a/superset-frontend/packages/superset-ui-core/test/chart/index.test.ts b/superset-frontend/packages/superset-ui-core/test/chart/index.test.ts index 1a71ffd09afc5..45d1902a533fa 100644 --- a/superset-frontend/packages/superset-ui-core/test/chart/index.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/chart/index.test.ts @@ -29,7 +29,7 @@ import { getChartMetadataRegistry, getChartTransformPropsRegistry, reactify, -} from '@superset-ui/core/src/chart'; +} from '@superset-ui/core'; describe('index', () => { it('exports modules', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/chart/models/ChartMetadata.test.ts b/superset-frontend/packages/superset-ui-core/test/chart/models/ChartMetadata.test.ts index 485c904295a1a..636e4170a1b7b 100644 --- a/superset-frontend/packages/superset-ui-core/test/chart/models/ChartMetadata.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/chart/models/ChartMetadata.test.ts @@ -17,7 +17,7 @@ * under the License. */ -import ChartMetadata from '@superset-ui/core/src/chart/models/ChartMetadata'; +import { ChartMetadata } from '@superset-ui/core'; describe('ChartMetadata', () => { it('exists', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/chart/models/ChartPlugin.test.tsx b/superset-frontend/packages/superset-ui-core/test/chart/models/ChartPlugin.test.tsx index caf94107e60cd..6bb69c27ca913 100644 --- a/superset-frontend/packages/superset-ui-core/test/chart/models/ChartPlugin.test.tsx +++ b/superset-frontend/packages/superset-ui-core/test/chart/models/ChartPlugin.test.tsx @@ -18,7 +18,6 @@ */ import React from 'react'; -import { QueryFormData, DatasourceType } from '@superset-ui/core'; import { ChartPlugin, ChartMetadata, @@ -30,7 +29,9 @@ import { getChartTransformPropsRegistry, getChartBuildQueryRegistry, getChartControlPanelRegistry, -} from '@superset-ui/core/src/chart'; + QueryFormData, + DatasourceType, +} from '@superset-ui/core'; describe('ChartPlugin', () => { const FakeChart = () => test; diff --git a/superset-frontend/packages/superset-ui-core/test/chart/models/ChartProps.test.ts b/superset-frontend/packages/superset-ui-core/test/chart/models/ChartProps.test.ts index a53381331624a..3e1b22b066e6a 100644 --- a/superset-frontend/packages/superset-ui-core/test/chart/models/ChartProps.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/chart/models/ChartProps.test.ts @@ -17,7 +17,7 @@ * under the License. */ -import { Behavior, ChartProps } from '@superset-ui/core/src'; +import { Behavior, ChartProps } from '@superset-ui/core'; const RAW_FORM_DATA = { some_field: 1, diff --git a/superset-frontend/packages/superset-ui-core/test/color/CategoricalColorNameSpace.test.ts b/superset-frontend/packages/superset-ui-core/test/color/CategoricalColorNameSpace.test.ts index fb3eb6d002154..d5e1ef8f0b5d2 100644 --- a/superset-frontend/packages/superset-ui-core/test/color/CategoricalColorNameSpace.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/color/CategoricalColorNameSpace.test.ts @@ -17,14 +17,17 @@ * under the License. */ -import CategoricalColorNamespace, { +import { + CategoricalScheme, + getCategoricalSchemeRegistry, + CategoricalColorNamespace, +} from '@superset-ui/core'; +import { getNamespace, getScale, getColor, DEFAULT_NAMESPACE, -} from '@superset-ui/core/src/color/CategoricalColorNamespace'; -import getCategoricalSchemeRegistry from '@superset-ui/core/src/color/CategoricalSchemeRegistrySingleton'; -import CategoricalScheme from '@superset-ui/core/src/color/CategoricalScheme'; +} from '../../src/color/CategoricalColorNamespace'; describe('CategoricalColorNamespace', () => { beforeAll(() => { diff --git a/superset-frontend/packages/superset-ui-core/test/color/CategoricalColorScale.test.ts b/superset-frontend/packages/superset-ui-core/test/color/CategoricalColorScale.test.ts index e50e409cc663e..f080b6fc84e5d 100644 --- a/superset-frontend/packages/superset-ui-core/test/color/CategoricalColorScale.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/color/CategoricalColorScale.test.ts @@ -18,7 +18,7 @@ */ import { ScaleOrdinal } from 'd3-scale'; -import CategoricalColorScale from '@superset-ui/core/src/color/CategoricalColorScale'; +import { CategoricalColorScale } from '@superset-ui/core'; describe('CategoricalColorScale', () => { it('exists', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/color/CategoricalSchemeRegistrySingleton.test.ts b/superset-frontend/packages/superset-ui-core/test/color/CategoricalSchemeRegistrySingleton.test.ts index 02e378efa80b8..dcbf8126f43a9 100644 --- a/superset-frontend/packages/superset-ui-core/test/color/CategoricalSchemeRegistrySingleton.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/color/CategoricalSchemeRegistrySingleton.test.ts @@ -20,7 +20,7 @@ import { CategoricalScheme, getCategoricalSchemeRegistry, -} from '@superset-ui/core/src/color'; +} from '@superset-ui/core'; describe('CategoricalSchemeRegistry', () => { it('has default value out-of-the-box', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/color/ColorScheme.test.ts b/superset-frontend/packages/superset-ui-core/test/color/ColorScheme.test.ts index 8220f0ae4a6f6..90bbfaa558ca1 100644 --- a/superset-frontend/packages/superset-ui-core/test/color/ColorScheme.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/color/ColorScheme.test.ts @@ -17,7 +17,7 @@ * under the License. */ -import ColorScheme from '@superset-ui/core/src/color/ColorScheme'; +import ColorScheme from '../../src/color/ColorScheme'; describe('ColorScheme', () => { describe('new ColorScheme()', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/color/ColorSchemeRegistry.test.ts b/superset-frontend/packages/superset-ui-core/test/color/ColorSchemeRegistry.test.ts index 8a97d4f5b40d5..4629828474904 100644 --- a/superset-frontend/packages/superset-ui-core/test/color/ColorSchemeRegistry.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/color/ColorSchemeRegistry.test.ts @@ -17,7 +17,7 @@ * under the License. */ -import ColorSchemeRegistry from '@superset-ui/core/src/color/ColorSchemeRegistry'; +import ColorSchemeRegistry from '../../src/color/ColorSchemeRegistry'; describe('ColorSchemeRegistry', () => { it('exists', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/color/SequentialScheme.test.ts b/superset-frontend/packages/superset-ui-core/test/color/SequentialScheme.test.ts index 5de951756ac09..c4056f4369d2d 100644 --- a/superset-frontend/packages/superset-ui-core/test/color/SequentialScheme.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/color/SequentialScheme.test.ts @@ -17,7 +17,7 @@ * under the License. */ -import SequentialScheme from '@superset-ui/core/src/color/SequentialScheme'; +import { SequentialScheme } from '@superset-ui/core'; describe('SequentialScheme', () => { const scheme = new SequentialScheme({ diff --git a/superset-frontend/packages/superset-ui-core/test/color/SequentialSchemeRegistrySingleton.test.ts b/superset-frontend/packages/superset-ui-core/test/color/SequentialSchemeRegistrySingleton.test.ts index d367da408e744..8a62fc2491182 100644 --- a/superset-frontend/packages/superset-ui-core/test/color/SequentialSchemeRegistrySingleton.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/color/SequentialSchemeRegistrySingleton.test.ts @@ -20,7 +20,7 @@ import { SequentialScheme, getSequentialSchemeRegistry, -} from '@superset-ui/core/src/color'; +} from '@superset-ui/core'; describe('SequentialSchemeRegistry', () => { it('has default value out-of-the-box', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/color/colorSchemes.test.ts b/superset-frontend/packages/superset-ui-core/test/color/colorSchemes.test.ts index b1c08366f3bc1..f241cee6e6a2a 100644 --- a/superset-frontend/packages/superset-ui-core/test/color/colorSchemes.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/color/colorSchemes.test.ts @@ -16,30 +16,31 @@ * specific language governing permissions and limitations * under the License. */ - -import categoricalAirbnb from '@superset-ui/core/src/color/colorSchemes/categorical/airbnb'; -import categoricalEcharts from '@superset-ui/core/src/color/colorSchemes/categorical/echarts'; -import categoricalSuperset from '@superset-ui/core/src/color/colorSchemes/categorical/superset'; -import categoricalPreset from '@superset-ui/core/src/color/colorSchemes/categorical/preset'; -import categoricalD3 from '@superset-ui/core/src/color/colorSchemes/categorical/d3'; -import categoricalGoogle from '@superset-ui/core/src/color/colorSchemes/categorical/google'; -import categoricalLyft from '@superset-ui/core/src/color/colorSchemes/categorical/lyft'; -import sequentialCommon from '@superset-ui/core/src/color/colorSchemes/sequential/common'; -import sequentialD3 from '@superset-ui/core/src/color/colorSchemes/sequential/d3'; -import CategoricalScheme from '@superset-ui/core/src/color/CategoricalScheme'; -import SequentialScheme from '@superset-ui/core/src/color/SequentialScheme'; +import { + CategoricalAirbnb, + CategoricalEcharts, + CategoricalSuperset, + CategoricalPreset, + CategoricalD3, + CategoricalGoogle, + CategoricalLyft, + SequentialCommon, + SequentialD3, + CategoricalScheme, + SequentialScheme, +} from '@superset-ui/core'; describe('Color Schemes', () => { describe('categorical', () => { it('returns an array of CategoricalScheme', () => { [ - categoricalAirbnb, - categoricalEcharts, - categoricalD3, - categoricalGoogle, - categoricalLyft, - categoricalSuperset, - categoricalPreset, + CategoricalAirbnb, + CategoricalEcharts, + CategoricalD3, + CategoricalGoogle, + CategoricalLyft, + CategoricalSuperset, + CategoricalPreset, ].forEach(group => { expect(group).toBeInstanceOf(Array); group.forEach(scheme => @@ -50,7 +51,7 @@ describe('Color Schemes', () => { }); describe('sequential', () => { it('returns an array of SequentialScheme', () => { - [sequentialCommon, sequentialD3].forEach(group => { + [SequentialCommon, SequentialD3].forEach(group => { expect(group).toBeInstanceOf(Array); group.forEach(scheme => expect(scheme).toBeInstanceOf(SequentialScheme), diff --git a/superset-frontend/packages/superset-ui-core/test/color/index.test.ts b/superset-frontend/packages/superset-ui-core/test/color/index.test.ts index 23d12b060d5bb..42891808d2f9e 100644 --- a/superset-frontend/packages/superset-ui-core/test/color/index.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/color/index.test.ts @@ -25,7 +25,7 @@ import { getCategoricalSchemeRegistry, getSequentialSchemeRegistry, SequentialScheme, -} from '@superset-ui/core/src/color'; +} from '@superset-ui/core'; describe('index', () => { it('exports modules', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/color/utils.test.ts b/superset-frontend/packages/superset-ui-core/test/color/utils.test.ts index bf6db2708ce9e..f04b88dafc70e 100644 --- a/superset-frontend/packages/superset-ui-core/test/color/utils.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/color/utils.test.ts @@ -17,7 +17,7 @@ * under the License. */ -import { getContrastingColor } from '@superset-ui/core/src/color'; +import { getContrastingColor } from '@superset-ui/core'; describe('color utils', () => { describe('getContrastingColor', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/connection/SupersetClient.test.ts b/superset-frontend/packages/superset-ui-core/test/connection/SupersetClient.test.ts index 1296a8040c48f..227d59b17288a 100644 --- a/superset-frontend/packages/superset-ui-core/test/connection/SupersetClient.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/connection/SupersetClient.test.ts @@ -18,10 +18,7 @@ */ import fetchMock from 'fetch-mock'; -import { - SupersetClient, - SupersetClientClass, -} from '@superset-ui/core/src/connection'; +import { SupersetClient, SupersetClientClass } from '@superset-ui/core'; import { LOGIN_GLOB } from './fixtures/constants'; describe('SupersetClient', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/connection/callApi/callApi.test.ts b/superset-frontend/packages/superset-ui-core/test/connection/callApi/callApi.test.ts index 7d9cd859bcf0c..254883333af3a 100644 --- a/superset-frontend/packages/superset-ui-core/test/connection/callApi/callApi.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/connection/callApi/callApi.test.ts @@ -17,10 +17,9 @@ * under the License. */ import fetchMock from 'fetch-mock'; -import callApi from '@superset-ui/core/src/connection/callApi/callApi'; -import * as constants from '@superset-ui/core/src/connection/constants'; -import { CallApi, JsonObject } from '@superset-ui/core/src/connection/types'; -import { DEFAULT_FETCH_RETRY_OPTIONS } from '@superset-ui/core/src/connection/constants'; +import { CallApi, JsonObject } from '@superset-ui/core'; +import * as constants from '../../../src/connection/constants'; +import callApi from '../../../src/connection/callApi/callApi'; import { LOGIN_GLOB } from '../fixtures/constants'; @@ -463,7 +462,7 @@ describe('callApi()', () => { let error; try { await callApi({ - fetchRetryOptions: DEFAULT_FETCH_RETRY_OPTIONS, + fetchRetryOptions: constants.DEFAULT_FETCH_RETRY_OPTIONS, url: mockErrorUrl, method: 'GET', }); @@ -499,7 +498,7 @@ describe('callApi()', () => { expect.assertions(2); const url = mock503; const response = await callApi({ - fetchRetryOptions: DEFAULT_FETCH_RETRY_OPTIONS, + fetchRetryOptions: constants.DEFAULT_FETCH_RETRY_OPTIONS, url, method: 'GET', }); diff --git a/superset-frontend/packages/superset-ui-core/test/connection/callApi/callApiAndParseWithTimeout.test.ts b/superset-frontend/packages/superset-ui-core/test/connection/callApi/callApiAndParseWithTimeout.test.ts index 722180fc46036..36cc95bfa10c6 100644 --- a/superset-frontend/packages/superset-ui-core/test/connection/callApi/callApiAndParseWithTimeout.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/connection/callApi/callApiAndParseWithTimeout.test.ts @@ -18,12 +18,12 @@ */ import fetchMock from 'fetch-mock'; -import callApiAndParseWithTimeout from '@superset-ui/core/src/connection/callApi/callApiAndParseWithTimeout'; +import callApiAndParseWithTimeout from '../../../src/connection/callApi/callApiAndParseWithTimeout'; // we import these via * so that we can spy on the 'default' property of the object -import * as callApi from '@superset-ui/core/src/connection/callApi/callApi'; -import * as parseResponse from '@superset-ui/core/src/connection/callApi/parseResponse'; -import * as rejectAfterTimeout from '@superset-ui/core/src/connection/callApi/rejectAfterTimeout'; +import * as callApi from '../../../src/connection/callApi/callApi'; +import * as parseResponse from '../../../src/connection/callApi/parseResponse'; +import * as rejectAfterTimeout from '../../../src/connection/callApi/rejectAfterTimeout'; import { LOGIN_GLOB } from '../fixtures/constants'; diff --git a/superset-frontend/packages/superset-ui-core/test/connection/callApi/parseResponse.test.ts b/superset-frontend/packages/superset-ui-core/test/connection/callApi/parseResponse.test.ts index be0a019001d91..d54be27e9c8f1 100644 --- a/superset-frontend/packages/superset-ui-core/test/connection/callApi/parseResponse.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/connection/callApi/parseResponse.test.ts @@ -17,8 +17,8 @@ * under the License. */ import fetchMock from 'fetch-mock'; -import callApi from '@superset-ui/core/src/connection/callApi/callApi'; -import parseResponse from '@superset-ui/core/src/connection/callApi/parseResponse'; +import callApi from '../../../src/connection/callApi/callApi'; +import parseResponse from '../../../src/connection/callApi/parseResponse'; import { LOGIN_GLOB } from '../fixtures/constants'; diff --git a/superset-frontend/packages/superset-ui-core/test/connection/callApi/rejectAfterTimeout.test.ts b/superset-frontend/packages/superset-ui-core/test/connection/callApi/rejectAfterTimeout.test.ts index da2161bc561fb..9be808dc29eba 100644 --- a/superset-frontend/packages/superset-ui-core/test/connection/callApi/rejectAfterTimeout.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/connection/callApi/rejectAfterTimeout.test.ts @@ -16,7 +16,7 @@ * specific language governing permissions and limitations * under the License. */ -import rejectAfterTimeout from '@superset-ui/core/src/connection/callApi/rejectAfterTimeout'; +import rejectAfterTimeout from '../../../src/connection/callApi/rejectAfterTimeout'; describe('rejectAfterTimeout()', () => { it('returns a promise that rejects after the specified timeout', async () => { diff --git a/superset-frontend/packages/superset-ui-core/test/dimension/computeMaxFontSize.test.ts b/superset-frontend/packages/superset-ui-core/test/dimension/computeMaxFontSize.test.ts index e74eec1e2c8de..99574f4ccf758 100644 --- a/superset-frontend/packages/superset-ui-core/test/dimension/computeMaxFontSize.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/dimension/computeMaxFontSize.test.ts @@ -17,7 +17,7 @@ * under the License. */ -import { computeMaxFontSize } from '@superset-ui/core/src'; +import { computeMaxFontSize } from '@superset-ui/core'; import { addDummyFill, removeDummyFill, SAMPLE_TEXT } from './getBBoxDummyFill'; describe('computeMaxFontSize(input)', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/dimension/getMultipleTextDimensions.test.ts b/superset-frontend/packages/superset-ui-core/test/dimension/getMultipleTextDimensions.test.ts index b392404c0ed58..687c2d9c2b9e6 100644 --- a/superset-frontend/packages/superset-ui-core/test/dimension/getMultipleTextDimensions.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/dimension/getMultipleTextDimensions.test.ts @@ -17,10 +17,7 @@ * under the License. */ -import { - getMultipleTextDimensions, - promiseTimeout, -} from '@superset-ui/core/src'; +import { getMultipleTextDimensions, promiseTimeout } from '@superset-ui/core'; import { addDummyFill, removeDummyFill, SAMPLE_TEXT } from './getBBoxDummyFill'; describe('getMultipleTextDimension(input)', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/dimension/getTextDimension.test.ts b/superset-frontend/packages/superset-ui-core/test/dimension/getTextDimension.test.ts index b04a60664cc20..def5c213fa231 100644 --- a/superset-frontend/packages/superset-ui-core/test/dimension/getTextDimension.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/dimension/getTextDimension.test.ts @@ -17,7 +17,7 @@ * under the License. */ -import { promiseTimeout, getTextDimension } from '@superset-ui/core/src'; +import { promiseTimeout, getTextDimension } from '@superset-ui/core'; import { addDummyFill, removeDummyFill, SAMPLE_TEXT } from './getBBoxDummyFill'; describe('getTextDimension(input)', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/dimension/mergeMargin.test.ts b/superset-frontend/packages/superset-ui-core/test/dimension/mergeMargin.test.ts index 43f45c29f4d9d..6567605efe7ec 100644 --- a/superset-frontend/packages/superset-ui-core/test/dimension/mergeMargin.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/dimension/mergeMargin.test.ts @@ -17,7 +17,7 @@ * under the License. */ -import { mergeMargin } from '@superset-ui/core/src'; +import { mergeMargin } from '@superset-ui/core'; describe('mergeMargin(margin1, margin2, mode?)', () => { it('combines two given margin', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/dimension/parseLength.test.ts b/superset-frontend/packages/superset-ui-core/test/dimension/parseLength.test.ts index 902e85493bb13..60c1663b46e77 100644 --- a/superset-frontend/packages/superset-ui-core/test/dimension/parseLength.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/dimension/parseLength.test.ts @@ -17,7 +17,7 @@ * under the License. */ -import { parseLength } from '@superset-ui/core/src'; +import { parseLength } from '@superset-ui/core'; describe('parseLength(input)', () => { it('handles string "auto"', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/dimension/svg/LazyFactory.test.ts b/superset-frontend/packages/superset-ui-core/test/dimension/svg/LazyFactory.test.ts index 84dac58a5938f..8e0bac5a71770 100644 --- a/superset-frontend/packages/superset-ui-core/test/dimension/svg/LazyFactory.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/dimension/svg/LazyFactory.test.ts @@ -17,7 +17,7 @@ * under the License. */ -import LazyFactory from '@superset-ui/core/src/dimension/svg/LazyFactory'; +import LazyFactory from '../../../src/dimension/svg/LazyFactory'; describe('LazyFactory', () => { describe('createInContainer()', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/dimension/svg/getBBoxCeil.test.ts b/superset-frontend/packages/superset-ui-core/test/dimension/svg/getBBoxCeil.test.ts index fffc41d458c93..047a79dd02401 100644 --- a/superset-frontend/packages/superset-ui-core/test/dimension/svg/getBBoxCeil.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/dimension/svg/getBBoxCeil.test.ts @@ -17,8 +17,8 @@ * under the License. */ -import getBBoxCeil from '@superset-ui/core/src/dimension/svg/getBBoxCeil'; -import createTextNode from '@superset-ui/core/src/dimension/svg/createTextNode'; +import getBBoxCeil from '../../../src/dimension/svg/getBBoxCeil'; +import createTextNode from '../../../src/dimension/svg/createTextNode'; describe('getBBoxCeil(node, defaultDimension)', () => { describe('returns default dimension if getBBox() is not available', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/dimension/svg/updateTextNode.test.ts b/superset-frontend/packages/superset-ui-core/test/dimension/svg/updateTextNode.test.ts index ffdb94d3f4ea1..f33a4db10461e 100644 --- a/superset-frontend/packages/superset-ui-core/test/dimension/svg/updateTextNode.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/dimension/svg/updateTextNode.test.ts @@ -17,8 +17,8 @@ * under the License. */ -import updateTextNode from '@superset-ui/core/src/dimension/svg/updateTextNode'; -import createTextNode from '@superset-ui/core/src/dimension/svg/createTextNode'; +import updateTextNode from '../../../src/dimension/svg/updateTextNode'; +import createTextNode from '../../../src/dimension/svg/createTextNode'; describe('updateTextNode(node, options)', () => { it('handles empty options', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/fixtures.ts b/superset-frontend/packages/superset-ui-core/test/fixtures.ts index 2588fc2b77d32..c4d3cc6d1b2b1 100644 --- a/superset-frontend/packages/superset-ui-core/test/fixtures.ts +++ b/superset-frontend/packages/superset-ui-core/test/fixtures.ts @@ -16,7 +16,7 @@ * specific language governing permissions and limitations * under the License. */ -import { AdhocMetric, GenericDataType } from '../src'; +import { AdhocMetric, GenericDataType } from '@superset-ui/core'; export const NUM_METRIC: AdhocMetric = { expressionType: 'SIMPLE', diff --git a/superset-frontend/packages/superset-ui-core/test/index.test.ts b/superset-frontend/packages/superset-ui-core/test/index.test.ts index 7debecea3d341..68fdd65be2912 100644 --- a/superset-frontend/packages/superset-ui-core/test/index.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/index.test.ts @@ -27,7 +27,7 @@ import { isDefined, isRequired, makeSingleton, -} from '@superset-ui/core/src'; +} from '@superset-ui/core'; describe('index', () => { it('exports modules', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/math-expression/index.test.ts b/superset-frontend/packages/superset-ui-core/test/math-expression/index.test.ts index 161f9f8c9c15b..d9d0f4931ddcf 100644 --- a/superset-frontend/packages/superset-ui-core/test/math-expression/index.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/math-expression/index.test.ts @@ -17,10 +17,7 @@ * under the License. */ -import { - evalExpression, - isValidExpression, -} from '@superset-ui/core/src/math-expression'; +import { evalExpression, isValidExpression } from '@superset-ui/core'; test('evalExpression evaluates constants correctly', () => { expect(evalExpression('0', 10)).toEqual(0); diff --git a/superset-frontend/packages/superset-ui-core/test/models/ExtensibleFunction.test.ts b/superset-frontend/packages/superset-ui-core/test/models/ExtensibleFunction.test.ts index 96cede80aab75..3f8c38e1ae568 100644 --- a/superset-frontend/packages/superset-ui-core/test/models/ExtensibleFunction.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/models/ExtensibleFunction.test.ts @@ -17,7 +17,7 @@ * under the License. */ -import { ExtensibleFunction } from '@superset-ui/core/src'; +import { ExtensibleFunction } from '@superset-ui/core'; describe('ExtensibleFunction', () => { interface Func1 { diff --git a/superset-frontend/packages/superset-ui-core/test/models/Plugin.test.ts b/superset-frontend/packages/superset-ui-core/test/models/Plugin.test.ts index d2251ccc81fd9..68d9c0b375e2c 100644 --- a/superset-frontend/packages/superset-ui-core/test/models/Plugin.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/models/Plugin.test.ts @@ -17,7 +17,7 @@ * under the License. */ -import { Plugin } from '@superset-ui/core/src'; +import { Plugin } from '@superset-ui/core'; describe('Plugin', () => { it('exists', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/models/Preset.test.ts b/superset-frontend/packages/superset-ui-core/test/models/Preset.test.ts index 9b887e744801f..188983de79470 100644 --- a/superset-frontend/packages/superset-ui-core/test/models/Preset.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/models/Preset.test.ts @@ -17,7 +17,7 @@ * under the License. */ -import { Plugin, Preset } from '@superset-ui/core/src'; +import { Plugin, Preset } from '@superset-ui/core'; describe('Preset', () => { it('exists', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/models/Registry.test.ts b/superset-frontend/packages/superset-ui-core/test/models/Registry.test.ts index 88c34c61008e5..1c85dc242c90c 100644 --- a/superset-frontend/packages/superset-ui-core/test/models/Registry.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/models/Registry.test.ts @@ -19,7 +19,7 @@ /* eslint no-console: 0 */ import mockConsole from 'jest-mock-console'; -import { Registry, OverwritePolicy } from '@superset-ui/core/src'; +import { Registry, OverwritePolicy } from '@superset-ui/core'; const loader = () => 'testValue'; diff --git a/superset-frontend/packages/superset-ui-core/test/models/RegistryWithDefaultKey.test.ts b/superset-frontend/packages/superset-ui-core/test/models/RegistryWithDefaultKey.test.ts index b334f4d0bfa92..781d2c0aebdbc 100644 --- a/superset-frontend/packages/superset-ui-core/test/models/RegistryWithDefaultKey.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/models/RegistryWithDefaultKey.test.ts @@ -17,7 +17,7 @@ * under the License. */ -import { Registry, RegistryWithDefaultKey } from '@superset-ui/core/src'; +import { Registry, RegistryWithDefaultKey } from '@superset-ui/core'; describe('RegistryWithDefaultKey', () => { let registry: RegistryWithDefaultKey; diff --git a/superset-frontend/packages/superset-ui-core/test/number-format/NumberFormatter.test.ts b/superset-frontend/packages/superset-ui-core/test/number-format/NumberFormatter.test.ts index 55f7a97c76c05..7cb11444448d0 100644 --- a/superset-frontend/packages/superset-ui-core/test/number-format/NumberFormatter.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/number-format/NumberFormatter.test.ts @@ -17,7 +17,7 @@ * under the License. */ -import { NumberFormatter } from '@superset-ui/core/src/number-format'; +import { NumberFormatter } from '@superset-ui/core'; describe('NumberFormatter', () => { describe('new NumberFormatter(config)', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/number-format/NumberFormatterRegistry.test.ts b/superset-frontend/packages/superset-ui-core/test/number-format/NumberFormatterRegistry.test.ts index 0994c283cee6f..2ff49f155c025 100644 --- a/superset-frontend/packages/superset-ui-core/test/number-format/NumberFormatterRegistry.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/number-format/NumberFormatterRegistry.test.ts @@ -21,7 +21,7 @@ import { NumberFormats, NumberFormatter, NumberFormatterRegistry, -} from '@superset-ui/core/src'; +} from '@superset-ui/core'; describe('NumberFormatterRegistry', () => { let registry: NumberFormatterRegistry; diff --git a/superset-frontend/packages/superset-ui-core/test/number-format/NumberFormatterRegistrySingleton.test.ts b/superset-frontend/packages/superset-ui-core/test/number-format/NumberFormatterRegistrySingleton.test.ts index a7ca85d8b7211..b978f5b27d6ae 100644 --- a/superset-frontend/packages/superset-ui-core/test/number-format/NumberFormatterRegistrySingleton.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/number-format/NumberFormatterRegistrySingleton.test.ts @@ -22,7 +22,7 @@ import { getNumberFormatterRegistry, getNumberFormatter, formatNumber, -} from '@superset-ui/core/src'; +} from '@superset-ui/core'; describe('NumberFormatterRegistrySingleton', () => { describe('getNumberFormatterRegistry()', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/number-format/factories/createD3NumberFormatter.test.ts b/superset-frontend/packages/superset-ui-core/test/number-format/factories/createD3NumberFormatter.test.ts index 1a5dee63ea8a0..c80c72c30868c 100644 --- a/superset-frontend/packages/superset-ui-core/test/number-format/factories/createD3NumberFormatter.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/number-format/factories/createD3NumberFormatter.test.ts @@ -17,7 +17,7 @@ * under the License. */ -import { createD3NumberFormatter } from '@superset-ui/core/src/number-format'; +import { createD3NumberFormatter } from '@superset-ui/core'; describe('createD3NumberFormatter(config)', () => { it('requires config.formatString', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/number-format/factories/createDurationFormatter.test.ts b/superset-frontend/packages/superset-ui-core/test/number-format/factories/createDurationFormatter.test.ts index 63c75480e9124..fa24948163cbb 100644 --- a/superset-frontend/packages/superset-ui-core/test/number-format/factories/createDurationFormatter.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/number-format/factories/createDurationFormatter.test.ts @@ -17,10 +17,7 @@ * under the License. */ -import { - NumberFormatter, - createDurationFormatter, -} from '@superset-ui/core/src/number-format'; +import { NumberFormatter, createDurationFormatter } from '@superset-ui/core'; describe('createDurationFormatter()', () => { it('creates an instance of NumberFormatter', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/number-format/factories/createSiAtMostNDigitFormatter.test.ts b/superset-frontend/packages/superset-ui-core/test/number-format/factories/createSiAtMostNDigitFormatter.test.ts index e13f01b3dcf98..3d9ddf24b5b46 100644 --- a/superset-frontend/packages/superset-ui-core/test/number-format/factories/createSiAtMostNDigitFormatter.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/number-format/factories/createSiAtMostNDigitFormatter.test.ts @@ -20,7 +20,7 @@ import { NumberFormatter, createSiAtMostNDigitFormatter, -} from '@superset-ui/core/src/number-format'; +} from '@superset-ui/core'; describe('createSiAtMostNDigitFormatter({ n })', () => { it('creates an instance of NumberFormatter', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/number-format/factories/createSmartNumberFormatter.test.ts b/superset-frontend/packages/superset-ui-core/test/number-format/factories/createSmartNumberFormatter.test.ts index e4f3c18950069..a322203173f1b 100644 --- a/superset-frontend/packages/superset-ui-core/test/number-format/factories/createSmartNumberFormatter.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/number-format/factories/createSmartNumberFormatter.test.ts @@ -17,10 +17,7 @@ * under the License. */ -import { - NumberFormatter, - createSmartNumberFormatter, -} from '@superset-ui/core/src'; +import { NumberFormatter, createSmartNumberFormatter } from '@superset-ui/core'; describe('createSmartNumberFormatter(options)', () => { it('creates an instance of NumberFormatter', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/number-format/index.test.ts b/superset-frontend/packages/superset-ui-core/test/number-format/index.test.ts index 5f482c564f1d6..09395e722e6e2 100644 --- a/superset-frontend/packages/superset-ui-core/test/number-format/index.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/number-format/index.test.ts @@ -27,7 +27,7 @@ import { NumberFormats, NumberFormatter, PREVIEW_VALUE, -} from '@superset-ui/core/src'; +} from '@superset-ui/core'; describe('index', () => { it('exports modules', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/query/DatasourceKey.test.ts b/superset-frontend/packages/superset-ui-core/test/query/DatasourceKey.test.ts index d0faab462582d..6b1d62e6aa135 100644 --- a/superset-frontend/packages/superset-ui-core/test/query/DatasourceKey.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/query/DatasourceKey.test.ts @@ -16,7 +16,7 @@ * specific language governing permissions and limitations * under the License. */ -import { DatasourceKey } from '@superset-ui/core/src/query'; +import { DatasourceKey } from '@superset-ui/core'; describe('DatasourceKey', () => { const tableKey = '5__table'; diff --git a/superset-frontend/packages/superset-ui-core/test/query/api/legacy/fetchExploreJson.test.ts b/superset-frontend/packages/superset-ui-core/test/query/api/legacy/fetchExploreJson.test.ts index e1c031a6b17f1..40203c824eee0 100644 --- a/superset-frontend/packages/superset-ui-core/test/query/api/legacy/fetchExploreJson.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/query/api/legacy/fetchExploreJson.test.ts @@ -17,7 +17,7 @@ * under the License. */ import fetchMock from 'fetch-mock'; -import { fetchExploreJson } from '@superset-ui/core/src/query/api/legacy'; +import { fetchExploreJson } from '../../../../src/query/api/legacy'; import setupClientForTest from '../setupClientForTest'; describe('fetchExploreJson()', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/query/api/legacy/getDatasourceMetadata.test.ts b/superset-frontend/packages/superset-ui-core/test/query/api/legacy/getDatasourceMetadata.test.ts index cf3a93f90dcef..91ba94083d15e 100644 --- a/superset-frontend/packages/superset-ui-core/test/query/api/legacy/getDatasourceMetadata.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/query/api/legacy/getDatasourceMetadata.test.ts @@ -17,7 +17,7 @@ * under the License. */ import fetchMock from 'fetch-mock'; -import { getDatasourceMetadata } from '@superset-ui/core/src/query/api/legacy'; +import { getDatasourceMetadata } from '../../../../src/query/api/legacy'; import setupClientForTest from '../setupClientForTest'; diff --git a/superset-frontend/packages/superset-ui-core/test/query/api/legacy/getFormData.test.ts b/superset-frontend/packages/superset-ui-core/test/query/api/legacy/getFormData.test.ts index 089a14b37da56..b5530560e3c3c 100644 --- a/superset-frontend/packages/superset-ui-core/test/query/api/legacy/getFormData.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/query/api/legacy/getFormData.test.ts @@ -17,7 +17,7 @@ * under the License. */ import fetchMock from 'fetch-mock'; -import { getFormData } from '@superset-ui/core/src/query/api/legacy'; +import { getFormData } from '../../../../src/query/api/legacy'; import setupClientForTest from '../setupClientForTest'; diff --git a/superset-frontend/packages/superset-ui-core/test/query/api/setupClientForTest.ts b/superset-frontend/packages/superset-ui-core/test/query/api/setupClientForTest.ts index 92596e43cb136..6df7cd84f591d 100644 --- a/superset-frontend/packages/superset-ui-core/test/query/api/setupClientForTest.ts +++ b/superset-frontend/packages/superset-ui-core/test/query/api/setupClientForTest.ts @@ -17,7 +17,7 @@ * under the License. */ import fetchMock from 'fetch-mock'; -import { SupersetClient } from '@superset-ui/core/src/connection'; +import { SupersetClient } from '@superset-ui/core'; const LOGIN_GLOB = 'glob:*api/v1/security/csrf_token/*'; diff --git a/superset-frontend/packages/superset-ui-core/test/query/api/v1/getChartData.test.ts b/superset-frontend/packages/superset-ui-core/test/query/api/v1/getChartData.test.ts index 16af3daf4df8c..24d8dcbf91f76 100644 --- a/superset-frontend/packages/superset-ui-core/test/query/api/v1/getChartData.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/query/api/v1/getChartData.test.ts @@ -17,7 +17,7 @@ * under the License. */ import fetchMock from 'fetch-mock'; -import { buildQueryContext, ApiV1 } from '@superset-ui/core/src/query'; +import { buildQueryContext, ApiV1 } from '@superset-ui/core'; import setupClientForTest from '../setupClientForTest'; describe('API v1 > getChartData()', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/query/api/v1/handleError.test.ts b/superset-frontend/packages/superset-ui-core/test/query/api/v1/handleError.test.ts index 5bfd2986fa18a..eec7a47b9ab7c 100644 --- a/superset-frontend/packages/superset-ui-core/test/query/api/v1/handleError.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/query/api/v1/handleError.test.ts @@ -17,14 +17,14 @@ * under the License. */ import 'whatwg-fetch'; // for adding Response polyfill -import { JsonObject } from '@superset-ui/core/src/connection'; -import handleError, { - ErrorInput, -} from '@superset-ui/core/src/query/api/v1/handleError'; import { + JsonObject, SupersetApiError, SupersetApiErrorType, -} from '@superset-ui/core/src/query/api/v1/types'; +} from '@superset-ui/core'; +import handleError, { + ErrorInput, +} from '../../../../src/query/api/v1/handleError'; async function testHandleError( inputError: ErrorInput, diff --git a/superset-frontend/packages/superset-ui-core/test/query/api/v1/makeApi.test.ts b/superset-frontend/packages/superset-ui-core/test/query/api/v1/makeApi.test.ts index c25ffd68995e8..774a11ed0852f 100644 --- a/superset-frontend/packages/superset-ui-core/test/query/api/v1/makeApi.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/query/api/v1/makeApi.test.ts @@ -17,11 +17,8 @@ * under the License. */ import fetchMock from 'fetch-mock'; -import { - JsonValue, - SupersetClientClass, -} from '@superset-ui/core/src/connection'; -import { makeApi, SupersetApiError } from '@superset-ui/core/src/query'; +import { JsonValue, SupersetClientClass } from '@superset-ui/core'; +import { makeApi, SupersetApiError } from '../../../../src/query'; import setupClientForTest from '../setupClientForTest'; describe('makeApi()', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/query/buildQueryContext.test.ts b/superset-frontend/packages/superset-ui-core/test/query/buildQueryContext.test.ts index 3bd899c629ed6..be94a877b2923 100644 --- a/superset-frontend/packages/superset-ui-core/test/query/buildQueryContext.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/query/buildQueryContext.test.ts @@ -16,7 +16,7 @@ * specific language governing permissions and limitations * under the License. */ -import { buildQueryContext } from '@superset-ui/core/src/query'; +import { buildQueryContext } from '@superset-ui/core'; describe('buildQueryContext', () => { it('should build datasource for table sources and apply defaults', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/query/buildQueryObject.test.ts b/superset-frontend/packages/superset-ui-core/test/query/buildQueryObject.test.ts index 430d2145cc4c5..1d3e19854c24b 100644 --- a/superset-frontend/packages/superset-ui-core/test/query/buildQueryObject.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/query/buildQueryObject.test.ts @@ -16,8 +16,8 @@ * specific language governing permissions and limitations * under the License. */ -import { JsonObject } from '@superset-ui/core'; import { + JsonObject, AnnotationLayer, AnnotationOpacity, AnnotationSourceType, @@ -25,7 +25,7 @@ import { AnnotationType, buildQueryObject, QueryObject, -} from '../../src/query'; +} from '@superset-ui/core'; describe('buildQueryObject', () => { let query: QueryObject; diff --git a/superset-frontend/packages/superset-ui-core/test/query/convertFilter.test.ts b/superset-frontend/packages/superset-ui-core/test/query/convertFilter.test.ts index 9869c1e139f67..1a7e54b40081d 100644 --- a/superset-frontend/packages/superset-ui-core/test/query/convertFilter.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/query/convertFilter.test.ts @@ -16,7 +16,7 @@ * specific language governing permissions and limitations * under the License. */ -import { convertFilter } from '@superset-ui/core/src/query'; +import { convertFilter } from '@superset-ui/core'; describe('convertFilter', () => { it('should handle unary filter', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/query/extractExtras.test.ts b/superset-frontend/packages/superset-ui-core/test/query/extractExtras.test.ts index 4b5f5340b2500..defcb80986b19 100644 --- a/superset-frontend/packages/superset-ui-core/test/query/extractExtras.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/query/extractExtras.test.ts @@ -16,7 +16,7 @@ * specific language governing permissions and limitations * under the License. */ -import extractExtras from '@superset-ui/core/src/query/extractExtras'; +import extractExtras from '../../src/query/extractExtras'; describe('extractExtras', () => { const baseQueryFormData = { diff --git a/superset-frontend/packages/superset-ui-core/test/query/extractQueryFields.test.ts b/superset-frontend/packages/superset-ui-core/test/query/extractQueryFields.test.ts index 056f4ce3c0b6d..dfc48c50a0243 100644 --- a/superset-frontend/packages/superset-ui-core/test/query/extractQueryFields.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/query/extractQueryFields.test.ts @@ -16,9 +16,8 @@ * specific language governing permissions and limitations * under the License. */ -import extractQueryFields from '@superset-ui/core/src/query/extractQueryFields'; -import { configure } from '../../src/translation'; -import { QueryMode, DTTM_ALIAS } from '../../src'; +import { configure, QueryMode, DTTM_ALIAS } from '@superset-ui/core'; +import extractQueryFields from '../../src/query/extractQueryFields'; import { NUM_METRIC } from '../fixtures'; configure(); diff --git a/superset-frontend/packages/superset-ui-core/test/query/extractTimegrain.test.ts b/superset-frontend/packages/superset-ui-core/test/query/extractTimegrain.test.ts index 444fc2289cbf8..d063e11a8f7c8 100644 --- a/superset-frontend/packages/superset-ui-core/test/query/extractTimegrain.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/query/extractTimegrain.test.ts @@ -16,8 +16,7 @@ * specific language governing permissions and limitations * under the License. */ -import extractTimegrain from '@superset-ui/core/src/query/extractTimegrain'; -import { QueryFormData } from '@superset-ui/core'; +import { extractTimegrain, QueryFormData } from '@superset-ui/core'; describe('extractTimegrain', () => { const baseFormData: QueryFormData = { diff --git a/superset-frontend/packages/superset-ui-core/test/query/getColumnLabel.test.ts b/superset-frontend/packages/superset-ui-core/test/query/getColumnLabel.test.ts index 865463481cdc4..aadde6e4b557f 100644 --- a/superset-frontend/packages/superset-ui-core/test/query/getColumnLabel.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/query/getColumnLabel.test.ts @@ -16,7 +16,7 @@ * specific language governing permissions and limitations * under the License. */ -import { getColumnLabel } from '@superset-ui/core/src/query'; +import { getColumnLabel } from '@superset-ui/core'; describe('getColumnLabel', () => { it('should handle physical column', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/query/getMetricLabel.test.ts b/superset-frontend/packages/superset-ui-core/test/query/getMetricLabel.test.ts index 434eb7215564d..057c3225ea985 100644 --- a/superset-frontend/packages/superset-ui-core/test/query/getMetricLabel.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/query/getMetricLabel.test.ts @@ -16,7 +16,7 @@ * specific language governing permissions and limitations * under the License. */ -import { getMetricLabel } from '@superset-ui/core/src/query'; +import { getMetricLabel } from '@superset-ui/core'; describe('getMetricLabel', () => { it('should handle predefined metric name', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/query/normalizeOrderBy.test.ts b/superset-frontend/packages/superset-ui-core/test/query/normalizeOrderBy.test.ts index 13b7147e8b6a0..a32aa4994a58e 100644 --- a/superset-frontend/packages/superset-ui-core/test/query/normalizeOrderBy.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/query/normalizeOrderBy.test.ts @@ -16,7 +16,7 @@ * specific language governing permissions and limitations * under the License. */ -import { normalizeOrderBy, QueryObject } from '@superset-ui/core/src/query'; +import { normalizeOrderBy, QueryObject } from '@superset-ui/core'; describe('normalizeOrderBy', () => { it('should not change original queryObject when orderby populated', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/query/processExtraFormData.test.ts b/superset-frontend/packages/superset-ui-core/test/query/processExtraFormData.test.ts index 53f7d7aa19f6a..871218bfd55ed 100644 --- a/superset-frontend/packages/superset-ui-core/test/query/processExtraFormData.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/query/processExtraFormData.test.ts @@ -16,7 +16,7 @@ * specific language governing permissions and limitations * under the License. */ -import { overrideExtraFormData } from '@superset-ui/core/src/query/processExtraFormData'; +import { overrideExtraFormData } from '../../src/query/processExtraFormData'; describe('overrideExtraFormData', () => { it('should assign allowed non-existent value', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/query/processFilters.test.ts b/superset-frontend/packages/superset-ui-core/test/query/processFilters.test.ts index 9eb462ac297cb..267b416493e35 100644 --- a/superset-frontend/packages/superset-ui-core/test/query/processFilters.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/query/processFilters.test.ts @@ -16,7 +16,7 @@ * specific language governing permissions and limitations * under the License. */ -import processFilters from '@superset-ui/core/src/query/processFilters'; +import processFilters from '../../src/query/processFilters'; describe('processFilters', () => { it('should handle non-array adhoc_filters', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/query/types/AnnotationLayer.test.ts b/superset-frontend/packages/superset-ui-core/test/query/types/AnnotationLayer.test.ts index aadf30743c372..c586239fd71c2 100644 --- a/superset-frontend/packages/superset-ui-core/test/query/types/AnnotationLayer.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/query/types/AnnotationLayer.test.ts @@ -35,7 +35,7 @@ import { TableAnnotationLayer, TimeseriesAnnotationLayer, TimeseriesAnnotationResult, -} from '@superset-ui/core/src/query/types/AnnotationLayer'; +} from '@superset-ui/core'; describe('AnnotationLayer type guards', () => { const formulaAnnotationLayer: FormulaAnnotationLayer = { diff --git a/superset-frontend/packages/superset-ui-core/test/query/types/Filter.test.ts b/superset-frontend/packages/superset-ui-core/test/query/types/Filter.test.ts index e8db7c8756c95..3861bb0085b51 100644 --- a/superset-frontend/packages/superset-ui-core/test/query/types/Filter.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/query/types/Filter.test.ts @@ -21,7 +21,7 @@ import { isUnaryAdhocFilter, isBinaryAdhocFilter, isSetAdhocFilter, -} from '@superset-ui/core/src/query/types/Filter'; +} from '@superset-ui/core'; describe('Filter type guards', () => { describe('isUnaryAdhocFilter', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/query/types/PostProcessing.test.ts b/superset-frontend/packages/superset-ui-core/test/query/types/PostProcessing.test.ts index f0aad20a59699..63394f536cc7e 100644 --- a/superset-frontend/packages/superset-ui-core/test/query/types/PostProcessing.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/query/types/PostProcessing.test.ts @@ -41,7 +41,7 @@ import { PostProcessingResample, PostProcessingRolling, PostProcessingSort, -} from '@superset-ui/core/src/query/types/PostProcessing'; +} from '@superset-ui/core'; import { ComparisionType, RollingType, TimeGranularity } from '../../../src'; const AGGREGATES_OPTION: Aggregates = { diff --git a/superset-frontend/packages/superset-ui-core/test/time-format/TimeFormatter.test.ts b/superset-frontend/packages/superset-ui-core/test/time-format/TimeFormatter.test.ts index 7ff4a0a94c6f3..e6353e856d01a 100644 --- a/superset-frontend/packages/superset-ui-core/test/time-format/TimeFormatter.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/time-format/TimeFormatter.test.ts @@ -17,9 +17,7 @@ * under the License. */ -import TimeFormatter, { - PREVIEW_TIME, -} from '@superset-ui/core/src/time-format/TimeFormatter'; +import { TimeFormatter, PREVIEW_TIME } from '@superset-ui/core'; describe('TimeFormatter', () => { describe('new TimeFormatter(config)', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/time-format/TimeFormatterRegistry.test.ts b/superset-frontend/packages/superset-ui-core/test/time-format/TimeFormatterRegistry.test.ts index 3ac636a8bee57..5ff3953d04365 100644 --- a/superset-frontend/packages/superset-ui-core/test/time-format/TimeFormatterRegistry.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/time-format/TimeFormatterRegistry.test.ts @@ -17,12 +17,8 @@ * under the License. */ -import TimeFormatterRegistry from '@superset-ui/core/src/time-format/TimeFormatterRegistry'; -import { - TimeFormats, - TimeFormatter, - PREVIEW_TIME, -} from '@superset-ui/core/src/time-format'; +import { TimeFormats, TimeFormatter, PREVIEW_TIME } from '@superset-ui/core'; +import TimeFormatterRegistry from '../../src/time-format/TimeFormatterRegistry'; describe('TimeFormatterRegistry', () => { let registry: TimeFormatterRegistry; diff --git a/superset-frontend/packages/superset-ui-core/test/time-format/TimeFormatterRegistrySingleton.test.ts b/superset-frontend/packages/superset-ui-core/test/time-format/TimeFormatterRegistrySingleton.test.ts index 5d51a6bc3af82..eb406c3ca8933 100644 --- a/superset-frontend/packages/superset-ui-core/test/time-format/TimeFormatterRegistrySingleton.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/time-format/TimeFormatterRegistrySingleton.test.ts @@ -17,18 +17,17 @@ * under the License. */ -import getTimeFormatterRegistry, { +import { + TimeGranularity, + LOCAL_PREFIX, + PREVIEW_TIME, getTimeFormatter, formatTime, getTimeFormatterForGranularity, formatTimeRange, -} from '@superset-ui/core/src/time-format/TimeFormatterRegistrySingleton'; -import TimeFormatterRegistry from '@superset-ui/core/src/time-format/TimeFormatterRegistry'; -import { PREVIEW_TIME } from '@superset-ui/core/src/time-format/TimeFormatter'; -import { - TimeGranularity, - LOCAL_PREFIX, -} from '@superset-ui/core/src/time-format'; + getTimeFormatterRegistry, +} from '@superset-ui/core'; +import TimeFormatterRegistry from '../../src/time-format/TimeFormatterRegistry'; describe('TimeFormatterRegistrySingleton', () => { describe('getTimeFormatterRegistry()', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/time-format/factories/createD3TimeFormatter.test.ts b/superset-frontend/packages/superset-ui-core/test/time-format/factories/createD3TimeFormatter.test.ts index c6cc18d66f409..a47e0e2f5b402 100644 --- a/superset-frontend/packages/superset-ui-core/test/time-format/factories/createD3TimeFormatter.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/time-format/factories/createD3TimeFormatter.test.ts @@ -18,9 +18,11 @@ */ import { TimeLocaleDefinition } from 'd3-time-format'; -import createD3TimeFormatter from '@superset-ui/core/src/time-format/factories/createD3TimeFormatter'; -import { PREVIEW_TIME } from '@superset-ui/core/src/time-format/TimeFormatter'; -import { TimeFormats } from '@superset-ui/core/src/time-format'; +import { + createD3TimeFormatter, + PREVIEW_TIME, + TimeFormats, +} from '@superset-ui/core'; const thLocale: TimeLocaleDefinition = { dateTime: '%a %e %b %Y %X', diff --git a/superset-frontend/packages/superset-ui-core/test/time-format/factories/createMultiFormatter.test.ts b/superset-frontend/packages/superset-ui-core/test/time-format/factories/createMultiFormatter.test.ts index ffd99f63da412..197120b919210 100644 --- a/superset-frontend/packages/superset-ui-core/test/time-format/factories/createMultiFormatter.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/time-format/factories/createMultiFormatter.test.ts @@ -17,7 +17,7 @@ * under the License. */ -import createMultiFormatter from '@superset-ui/core/src/time-format/factories/createMultiFormatter'; +import { createMultiFormatter } from '@superset-ui/core'; describe('createMultiFormatter()', () => { describe('creates a multi-step formatter', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/time-format/formatters/smartDate.test.ts b/superset-frontend/packages/superset-ui-core/test/time-format/formatters/smartDate.test.ts index 4e8ad52bf1c2c..04354b0c807e8 100644 --- a/superset-frontend/packages/superset-ui-core/test/time-format/formatters/smartDate.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/time-format/formatters/smartDate.test.ts @@ -17,8 +17,7 @@ * under the License. */ -import TimeFormatter from '@superset-ui/core/src/time-format/TimeFormatter'; -import smartDateFormatter from '@superset-ui/core/src/time-format/formatters/smartDate'; +import { TimeFormatter, smartDateFormatter } from '@superset-ui/core'; describe('smartDateFormatter', () => { it('is a function', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/time-format/formatters/smartDateDetailed.test.ts b/superset-frontend/packages/superset-ui-core/test/time-format/formatters/smartDateDetailed.test.ts index a7878d92c8c4d..7fd5201d75bcd 100644 --- a/superset-frontend/packages/superset-ui-core/test/time-format/formatters/smartDateDetailed.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/time-format/formatters/smartDateDetailed.test.ts @@ -17,8 +17,7 @@ * under the License. */ -import TimeFormatter from '@superset-ui/core/src/time-format/TimeFormatter'; -import smartDateDetailedFormatter from '@superset-ui/core/src/time-format/formatters/smartDateDetailed'; +import { TimeFormatter, smartDateDetailedFormatter } from '@superset-ui/core'; describe('smartDateDetailedFormatter', () => { const formatter = smartDateDetailedFormatter; diff --git a/superset-frontend/packages/superset-ui-core/test/time-format/formatters/smartDateVerbose.test.ts b/superset-frontend/packages/superset-ui-core/test/time-format/formatters/smartDateVerbose.test.ts index 103ce6c4cc9e7..1fde19a6d7171 100644 --- a/superset-frontend/packages/superset-ui-core/test/time-format/formatters/smartDateVerbose.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/time-format/formatters/smartDateVerbose.test.ts @@ -17,8 +17,7 @@ * under the License. */ -import TimeFormatter from '@superset-ui/core/src/time-format/TimeFormatter'; -import smartDateVerboseFormatter from '@superset-ui/core/src/time-format/formatters/smartDateVerbose'; +import { TimeFormatter, smartDateVerboseFormatter } from '@superset-ui/core'; describe('smartDateVerboseFormatter', () => { const formatter = smartDateVerboseFormatter; diff --git a/superset-frontend/packages/superset-ui-core/test/time-format/index.test.ts b/superset-frontend/packages/superset-ui-core/test/time-format/index.test.ts index 6982dc5c62162..ab2f3649fc570 100644 --- a/superset-frontend/packages/superset-ui-core/test/time-format/index.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/time-format/index.test.ts @@ -29,7 +29,7 @@ import { smartDateVerboseFormatter, TimeFormats, TimeFormatter, -} from '@superset-ui/core/src/time-format'; +} from '@superset-ui/core'; describe('index', () => { it('exports modules', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/time-format/utils/createTime.test.ts b/superset-frontend/packages/superset-ui-core/test/time-format/utils/createTime.test.ts index 4d196a1cb15f5..39629c5b84e38 100644 --- a/superset-frontend/packages/superset-ui-core/test/time-format/utils/createTime.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/time-format/utils/createTime.test.ts @@ -17,7 +17,7 @@ * under the License. */ -import createTime from '@superset-ui/core/src/time-format/utils/createTime'; +import createTime from '../../../src/time-format/utils/createTime'; describe('createTime(mode, year, month, date, hours, minutes, seconds, milliseconds)', () => { describe('mode', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/time-format/utils/createTimeRangeFromGranularity.test.ts b/superset-frontend/packages/superset-ui-core/test/time-format/utils/createTimeRangeFromGranularity.test.ts index b62d8f52e52c3..50c12dd8ed3b9 100644 --- a/superset-frontend/packages/superset-ui-core/test/time-format/utils/createTimeRangeFromGranularity.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/time-format/utils/createTimeRangeFromGranularity.test.ts @@ -17,12 +17,12 @@ * under the License. */ -import createTimeRangeFromGranularity from '@superset-ui/core/src/time-format/utils/createTimeRangeFromGranularity'; import { TimeGranularity, getTimeRangeFormatter, LOCAL_PREFIX, -} from '@superset-ui/core/src/time-format'; +} from '@superset-ui/core'; +import createTimeRangeFromGranularity from '../../../src/time-format/utils/createTimeRangeFromGranularity'; const formatString = '%Y-%m-%d %H:%M:%S.%L'; const formatUTCTimeRange = getTimeRangeFormatter(formatString); diff --git a/superset-frontend/packages/superset-ui-core/test/time-format/utils/d3Time.test.ts b/superset-frontend/packages/superset-ui-core/test/time-format/utils/d3Time.test.ts index 7bf76b00e920e..ec36563e0afb4 100644 --- a/superset-frontend/packages/superset-ui-core/test/time-format/utils/d3Time.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/time-format/utils/d3Time.test.ts @@ -20,7 +20,7 @@ import { utcUtils, localTimeUtils, -} from '@superset-ui/core/src/time-format/utils/d3Time'; +} from '../../../src/time-format/utils/d3Time'; describe('utils', () => { describe('utcUtils', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/utils/convertKeysToCamelCase.test.ts b/superset-frontend/packages/superset-ui-core/test/utils/convertKeysToCamelCase.test.ts index c7d042d587406..7b902f6cbe5cc 100644 --- a/superset-frontend/packages/superset-ui-core/test/utils/convertKeysToCamelCase.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/utils/convertKeysToCamelCase.test.ts @@ -17,7 +17,7 @@ * under the License. */ -import { convertKeysToCamelCase } from '@superset-ui/core/src'; +import { convertKeysToCamelCase } from '@superset-ui/core'; describe('convertKeysToCamelCase(object)', () => { it('returns undefined for undefined input', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/utils/ensureIsArray.test.ts b/superset-frontend/packages/superset-ui-core/test/utils/ensureIsArray.test.ts index f1fca8631fbcd..223782e6460bb 100644 --- a/superset-frontend/packages/superset-ui-core/test/utils/ensureIsArray.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/utils/ensureIsArray.test.ts @@ -16,7 +16,7 @@ * specific language governing permissions and limitations * under the License. */ -import { ensureIsArray } from '../../src'; +import { ensureIsArray } from '@superset-ui/core'; describe('ensureIsArray', () => { it('handle inputs correctly', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/utils/ensureIsInt.test.ts b/superset-frontend/packages/superset-ui-core/test/utils/ensureIsInt.test.ts index 0558d7d93a824..41f0df79d0e68 100644 --- a/superset-frontend/packages/superset-ui-core/test/utils/ensureIsInt.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/utils/ensureIsInt.test.ts @@ -16,7 +16,7 @@ * specific language governing permissions and limitations * under the License. */ -import { ensureIsInt } from '../../src'; +import { ensureIsInt } from '@superset-ui/core'; describe('ensureIsInt', () => { it('handle inputs correctly', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/utils/featureFlag.test.ts b/superset-frontend/packages/superset-ui-core/test/utils/featureFlag.test.ts index c07f3134e76b4..52a57909aa386 100644 --- a/superset-frontend/packages/superset-ui-core/test/utils/featureFlag.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/utils/featureFlag.test.ts @@ -17,7 +17,7 @@ * under the License. */ -import { FeatureFlag, isFeatureEnabled } from '../../src'; +import { FeatureFlag, isFeatureEnabled } from '@superset-ui/core'; describe('isFeatureFlagEnabled', () => { window.featureFlags = { diff --git a/superset-frontend/packages/superset-ui-core/test/utils/isDefined.test.ts b/superset-frontend/packages/superset-ui-core/test/utils/isDefined.test.ts index 89d33ab01966b..756a4ec81ad8f 100644 --- a/superset-frontend/packages/superset-ui-core/test/utils/isDefined.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/utils/isDefined.test.ts @@ -17,7 +17,7 @@ * under the License. */ -import { isDefined } from '@superset-ui/core/src'; +import { isDefined } from '@superset-ui/core'; describe('isDefined(value)', () => { it('returns true if value is not null and not undefined', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/utils/isRequired.test.ts b/superset-frontend/packages/superset-ui-core/test/utils/isRequired.test.ts index 4cc14aa356437..99d7b78fdd82e 100644 --- a/superset-frontend/packages/superset-ui-core/test/utils/isRequired.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/utils/isRequired.test.ts @@ -17,7 +17,7 @@ * under the License. */ -import { isRequired } from '@superset-ui/core/src'; +import { isRequired } from '@superset-ui/core'; describe('isRequired(field)', () => { it('should throw error with the given field in the message', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/utils/makeSingleton.test.ts b/superset-frontend/packages/superset-ui-core/test/utils/makeSingleton.test.ts index e1cbfc8b7f2d3..0a74183326a16 100644 --- a/superset-frontend/packages/superset-ui-core/test/utils/makeSingleton.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/utils/makeSingleton.test.ts @@ -17,7 +17,7 @@ * under the License. */ -import { makeSingleton } from '@superset-ui/core/src'; +import { makeSingleton } from '@superset-ui/core'; describe('makeSingleton()', () => { class Dog { diff --git a/superset-frontend/packages/superset-ui-core/test/utils/promiseTimeout.test.ts b/superset-frontend/packages/superset-ui-core/test/utils/promiseTimeout.test.ts index 31af484f59da5..ab1e28ae6d089 100644 --- a/superset-frontend/packages/superset-ui-core/test/utils/promiseTimeout.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/utils/promiseTimeout.test.ts @@ -17,7 +17,7 @@ * under the License. */ -import { promiseTimeout } from '@superset-ui/core/src'; +import { promiseTimeout } from '@superset-ui/core'; describe('promiseTimeout(func, delay)', () => { beforeEach(() => { diff --git a/superset-frontend/packages/superset-ui-core/test/utils/random.test.ts b/superset-frontend/packages/superset-ui-core/test/utils/random.test.ts index 151d6d05a4baf..4badf57021444 100644 --- a/superset-frontend/packages/superset-ui-core/test/utils/random.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/utils/random.test.ts @@ -17,7 +17,7 @@ * under the License. */ -import { seed, seedRandom } from '../../src'; +import { seed, seedRandom } from '@superset-ui/core'; describe('random', () => { it('seeded random should return the same value', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/utils/removeDuplicates.test.ts b/superset-frontend/packages/superset-ui-core/test/utils/removeDuplicates.test.ts index 8b900307b3393..439866771d637 100644 --- a/superset-frontend/packages/superset-ui-core/test/utils/removeDuplicates.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/utils/removeDuplicates.test.ts @@ -16,7 +16,7 @@ * specific language governing permissions and limitations * under the License. */ -import { removeDuplicates } from '@superset-ui/core/src'; +import { removeDuplicates } from '@superset-ui/core'; describe('removeDuplicates([...])', () => { it('should remove duplicates from a simple list', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/validator/legacyValidateInteger.test.ts b/superset-frontend/packages/superset-ui-core/test/validator/legacyValidateInteger.test.ts index 909a8bbd0a8ac..2e3388489b80b 100644 --- a/superset-frontend/packages/superset-ui-core/test/validator/legacyValidateInteger.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/validator/legacyValidateInteger.test.ts @@ -17,7 +17,7 @@ * under the License. */ -import { legacyValidateInteger } from '@superset-ui/core/src'; +import { legacyValidateInteger } from '@superset-ui/core'; import './setup'; describe('legacyValidateInteger()', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/validator/legacyValidateNumber.test.ts b/superset-frontend/packages/superset-ui-core/test/validator/legacyValidateNumber.test.ts index 155ba9bfdbc22..9613c48fd34e9 100644 --- a/superset-frontend/packages/superset-ui-core/test/validator/legacyValidateNumber.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/validator/legacyValidateNumber.test.ts @@ -17,7 +17,7 @@ * under the License. */ -import { legacyValidateNumber } from '@superset-ui/core/src'; +import { legacyValidateNumber } from '@superset-ui/core'; import './setup'; describe('legacyValidateNumber()', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/validator/setup.ts b/superset-frontend/packages/superset-ui-core/test/validator/setup.ts index b0d37311e1f5e..ca4a8311375d3 100644 --- a/superset-frontend/packages/superset-ui-core/test/validator/setup.ts +++ b/superset-frontend/packages/superset-ui-core/test/validator/setup.ts @@ -17,6 +17,6 @@ * under the License. */ -import { configure as configureTranslation } from '@superset-ui/core/src'; +import { configure as configureTranslation } from '@superset-ui/core'; configureTranslation(); diff --git a/superset-frontend/packages/superset-ui-core/test/validator/validateInteger.test.ts b/superset-frontend/packages/superset-ui-core/test/validator/validateInteger.test.ts index 4db30410f0ee6..fd7cc1095b466 100644 --- a/superset-frontend/packages/superset-ui-core/test/validator/validateInteger.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/validator/validateInteger.test.ts @@ -17,7 +17,7 @@ * under the License. */ -import { validateInteger } from '@superset-ui/core/src'; +import { validateInteger } from '@superset-ui/core'; import './setup'; describe('validateInteger()', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/validator/validateNonEmpty.test.ts b/superset-frontend/packages/superset-ui-core/test/validator/validateNonEmpty.test.ts index d10a4e472c4f9..384c2b57c7572 100644 --- a/superset-frontend/packages/superset-ui-core/test/validator/validateNonEmpty.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/validator/validateNonEmpty.test.ts @@ -17,7 +17,7 @@ * under the License. */ -import { validateNonEmpty } from '@superset-ui/core/src'; +import { validateNonEmpty } from '@superset-ui/core'; import './setup'; describe('validateNonEmpty()', () => { diff --git a/superset-frontend/packages/superset-ui-core/test/validator/validateNumber.test.ts b/superset-frontend/packages/superset-ui-core/test/validator/validateNumber.test.ts index 6b7628c677caf..0c785d720070c 100644 --- a/superset-frontend/packages/superset-ui-core/test/validator/validateNumber.test.ts +++ b/superset-frontend/packages/superset-ui-core/test/validator/validateNumber.test.ts @@ -17,7 +17,7 @@ * under the License. */ -import { validateNumber } from '@superset-ui/core/src'; +import { validateNumber } from '@superset-ui/core'; import './setup'; describe('validateNumber()', () => { diff --git a/superset-frontend/plugins/legacy-plugin-chart-map-box/package.json b/superset-frontend/plugins/legacy-plugin-chart-map-box/package.json index 16096b3ad2ff6..77aca98be34e1 100644 --- a/superset-frontend/plugins/legacy-plugin-chart-map-box/package.json +++ b/superset-frontend/plugins/legacy-plugin-chart-map-box/package.json @@ -36,6 +36,7 @@ "viewport-mercator-project": "^6.1.1" }, "peerDependencies": { - "react": "^15 || ^16" + "react": "^15 || ^16", + "mapbox-gl": "*" } } diff --git a/superset-frontend/plugins/legacy-plugin-chart-partition/package.json b/superset-frontend/plugins/legacy-plugin-chart-partition/package.json index 0b03f50d00714..e0f005773deb0 100644 --- a/superset-frontend/plugins/legacy-plugin-chart-partition/package.json +++ b/superset-frontend/plugins/legacy-plugin-chart-partition/package.json @@ -35,6 +35,7 @@ "prop-types": "^15.6.2" }, "peerDependencies": { - "react": "^16.13.1" + "react": "^16.13.1", + "enzyme": "*" } } diff --git a/superset-frontend/plugins/legacy-preset-chart-deckgl/package.json b/superset-frontend/plugins/legacy-preset-chart-deckgl/package.json index c5c7fbf0cacc3..ca33e0beed8ad 100644 --- a/superset-frontend/plugins/legacy-preset-chart-deckgl/package.json +++ b/superset-frontend/plugins/legacy-preset-chart-deckgl/package.json @@ -45,7 +45,8 @@ "@superset-ui/core": "0.x.x", "react": "^16.13.1", "react-dom": "^16.13.1", - "react-map-gl": "^4.0.10" + "react-map-gl": "^4.0.10", + "mapbox-gl": "*" }, "publishConfig": { "access": "public" diff --git a/superset-frontend/plugins/plugin-chart-echarts/package.json b/superset-frontend/plugins/plugin-chart-echarts/package.json index 3b65580c8bfe6..28f1f271f24f0 100644 --- a/superset-frontend/plugins/plugin-chart-echarts/package.json +++ b/superset-frontend/plugins/plugin-chart-echarts/package.json @@ -30,7 +30,8 @@ "@superset-ui/core": "0.18.25", "d3-array": "^1.2.0", "echarts": "^5.2.2", - "lodash": "^4.17.15" + "lodash": "^4.17.15", + "moment": "^2.26.0" }, "peerDependencies": { "react": "^16.13.1" diff --git a/superset-frontend/plugins/plugin-chart-pivot-table/package.json b/superset-frontend/plugins/plugin-chart-pivot-table/package.json index 25e99aa297509..23141faa19f51 100644 --- a/superset-frontend/plugins/plugin-chart-pivot-table/package.json +++ b/superset-frontend/plugins/plugin-chart-pivot-table/package.json @@ -32,7 +32,8 @@ "peerDependencies": { "@ant-design/icons": "^4.2.2", "react": "^16.13.1", - "react-dom": "^16.13.1" + "react-dom": "^16.13.1", + "prop-types": "*" }, "devDependencies": { "@babel/types": "^7.13.12", diff --git a/superset-frontend/plugins/plugin-chart-table/package.json b/superset-frontend/plugins/plugin-chart-table/package.json index 81496f350b90b..19751fb4ba70c 100644 --- a/superset-frontend/plugins/plugin-chart-table/package.json +++ b/superset-frontend/plugins/plugin-chart-table/package.json @@ -31,6 +31,7 @@ "@superset-ui/core": "0.18.25", "@types/d3-array": "^2.9.0", "@types/react-table": "^7.0.29", + "@types/enzyme": "^3.10.5", "d3-array": "^2.4.0", "match-sorter": "^6.3.0", "memoize-one": "^5.1.1",