Skip to content

Commit

Permalink
fix(TDOPS-5327): prepare TUI to pnpm and solve some missing deps in p…
Browse files Browse the repository at this point in the history
…ackages
  • Loading branch information
smouillour committed Oct 11, 2023
1 parent cd04f75 commit d8a6638
Show file tree
Hide file tree
Showing 51 changed files with 389 additions and 192 deletions.
17 changes: 9 additions & 8 deletions fork/dynamic-cdn-webpack-plugin/src/find.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,14 +34,15 @@ function findPackagesFromScopeFolder(scope, name, scopeFolderPath) {
// just add the path to the found list
return accu.concat(subFolderPath);
}
// the scope or package name is not the one we look for
// if there is a nested node modules folder, we dive into it for the search
const nestedNodeModulesPath = path.join(subFolderPath, 'node_modules');
if (fs.existsSync(nestedNodeModulesPath)) {
return accu.concat(
findPackagesFromNonScopeFolder(scope, name, nestedNodeModulesPath, []),
);
}
// NOT COMPATIBLE WITH PNPM
// // the scope or package name is not the one we look for
// // if there is a nested node modules folder, we dive into it for the search
// const nestedNodeModulesPath = path.join(subFolderPath, 'node_modules');
// if (fs.existsSync(nestedNodeModulesPath)) {
// return accu.concat(
// findPackagesFromNonScopeFolder(scope, name, nestedNodeModulesPath, []),
// );
// }
return accu;
}, []);
}
Expand Down
2 changes: 1 addition & 1 deletion fork/module-to-cdn/.babelrc
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"extends": "../../node_modules/@talend/scripts-config-babel/.babelrc.json"
"extends": "@talend/scripts-config-babel/.babelrc.json"
}
23 changes: 12 additions & 11 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,14 +1,5 @@
{
"devDependencies": {
"@changesets/cli": "^2.26.2",
"cross-env": "^7.0.3",
"cross-spawn": "^7.0.3",
"eslint": "^7.32.0",
"husky": "^8.0.3",
"i18next-scanner": "^4.4.0",
"lint-staged": "^13.3.0",
"prettier": "^2.8.8"
},

"scripts": {
"postinstall": "talend-yarn-workspace run build:lib",
"pre-release": "talend-yarn-workspace run pre-release",
Expand Down Expand Up @@ -57,9 +48,19 @@
"prettier --write"
]
},
"dependencies": {
"devDependencies": {
"@changesets/cli": "^2.26.2",
"@talend/scripts-config-prettier": "^12.0.0",
"@types/react": "^17.0.2",
"@types/react-dom": "^17.0.20",
"cross-env": "^7.0.3",
"cross-spawn": "^7.0.3",
"eslint": "^7.32.0",
"husky": "^8.0.3",
"i18next-scanner": "^4.4.0",
"lint-staged": "^13.3.0",
"prettier": "^2.8.8",
"rimraf": "^3.0.2",
"terser-webpack-plugin": "^5.3.9",
"typescript": "^5.0.4",
"webpack": "^5.73.0"
Expand Down
3 changes: 3 additions & 0 deletions packages/a11y/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,10 @@
"lodash": "^4.17.21"
},
"devDependencies": {
"@talend/eslint-plugin": "^1.0.1",
"@talend/scripts-core": "^15.0.0",
"@talend/scripts-config-prettier": "^12.0.0",
"@talend/scripts-config-typescript": "^11.1.0",
"@testing-library/react": "^12.1.5",
"react": "^17.0.2",
"react-dom": "^17.0.2"
Expand Down
4 changes: 3 additions & 1 deletion packages/cmf-cqrs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,13 +33,15 @@
"homepage": "https://github.com/Talend/ui/cmf-cqrs#readme",
"dependencies": {
"@talend/react-cmf": "^7.3.0",
"@talend/utils": "2.6.0",
"@talend/utils": "^2.6.0",
"immutable": "^3.8.2",
"redux-saga": "^1.2.3"
},
"devDependencies": {
"@talend/eslint-plugin": "^1.0.1",
"@talend/scripts-core": "^15.0.0",
"@talend/scripts-config-react-webpack": "^16.0.0",
"@talend/scripts-config-typescript": "^11.1.0",
"@testing-library/react-hooks": "^8.0.1",
"mock-socket": "^9.3.1",
"prop-types": "^15.8.1",
Expand Down
1 change: 1 addition & 0 deletions packages/cmf-router/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@
},
"devDependencies": {
"@redux-saga/testing-utils": "^1.1.5",
"@talend/eslint-plugin": "^1.0.1",
"@talend/scripts-core": "^15.0.0",
"@talend/scripts-config-react-webpack": "^16.0.0",
"react": "^17.0.2",
Expand Down
2 changes: 1 addition & 1 deletion packages/cmf/jest.config.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
const defaults = require('../../node_modules/@talend/scripts-config-jest/jest.config.js');
const defaults = require('@talend/scripts-config-jest/jest.config.js');

module.exports = {
...defaults,
Expand Down
2 changes: 2 additions & 0 deletions packages/cmf/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,9 @@
},
"devDependencies": {
"@redux-saga/testing-utils": "^1.1.5",
"@talend/eslint-plugin": "^1.0.1",
"@talend/scripts-core": "^15.0.0",
"@talend/scripts-config-jest": "^12.2.0",
"@talend/scripts-config-react-webpack": "^16.0.0",
"@testing-library/react": "^12.1.5",
"jest-in-case": "^1.0.2",
Expand Down
6 changes: 5 additions & 1 deletion packages/components/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@
},
"dependencies": {
"@popperjs/core": "^2.11.8",
"@talend/assets-api": "^1.2.2",
"@talend/bootstrap-theme": "^8.2.0",
"@talend/design-tokens": "^2.9.0",
"@talend/react-a11y": "^1.1.0",
Expand Down Expand Up @@ -72,10 +73,13 @@
"@talend/bootstrap-theme": "^8.2.0",
"@talend/design-system": "^7.15.1",
"@talend/icons": "^6.60.1",
"@talend/eslint-plugin": "^1.0.1",
"@talend/locales-design-system": "^7.3.0",
"@talend/locales-tui-components": "^9.5.0",
"@talend/scripts-config-stylelint": "^4.0.0",
"@talend/scripts-core": "^15.0.0",
"@talend/scripts-config-react-webpack": "^16.1.0",
"@talend/scripts-config-react-webpack": "^16.0.0",
"@talend/scripts-config-typescript": "^11.1.0",
"@testing-library/jest-dom": "^5.17.0",
"@testing-library/react": "^12.1.5",
"@testing-library/user-event": "^13.5.0",
Expand Down
4 changes: 3 additions & 1 deletion packages/containers/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@
"url": "https://github.com/Talend/ui.git"
},
"dependencies": {
"@talend/design-system": "^7.15.1",
"@talend/react-bootstrap": "^1.35.2",
"@talend/react-cmf": "^7.3.0",
"@talend/react-components": "^11.4.0",
Expand All @@ -50,7 +51,8 @@
},
"devDependencies": {
"@storybook/addon-actions": "^7.4.1",
"@talend/bootstrap-theme": "^8.1.3",
"@talend/bootstrap-theme": "^8.2.0",
"@talend/eslint-plugin": "^1.0.1",
"@talend/icons": "^6.60.1",
"@talend/locales-tui-containers": "^8.0.2",
"@talend/react-storybook-cmf": "^7.2.0",
Expand Down
5 changes: 4 additions & 1 deletion packages/dataviz/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -49,13 +49,16 @@
"devDependencies": {
"@cypress/react": "^7.0.3",
"@cypress/webpack-dev-server": "^3.6.1",
"@talend/bootstrap-theme": "^8.1.3",
"@talend/bootstrap-theme": "^8.2.0",
"@talend/design-system": "^7.15.1",
"@talend/eslint-plugin": "^1.0.1",
"@talend/icons": "^6.60.1",
"@talend/locales-tui-components": "^9.5.0",
"@talend/locales-tui-dataviz": "^0.4.6",
"@talend/react-components": "^11.4.0",
"@talend/scripts-core": "^15.0.0",
"@talend/scripts-config-react-webpack": "^16.0.0",
"@talend/scripts-config-typescript": "^11.1.0",
"@testing-library/react": "^12.1.5",
"@types/classnames": "^2.3.1",
"@types/d3": "^7.4.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/dataviz/tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

"rootDirs": ["cypress", "@testing-library/cypress", "src"],
"target": "es5",
"lib": ["es5", "dom"],
"lib": ["es6", "dom", "ES2017"],
"types": ["cypress", "node"]
}
}
30 changes: 16 additions & 14 deletions packages/design-docs/.storybook/main.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
import path from 'path';
import { packageDirectorySync } from 'pkg-dir';

const iconConfig = require('@talend/icons/.storybook/main.js');
const rootPath = require.resolve('@talend/design-docs').replace('src/index.ts', '');
const rootPath = packageDirectorySync();
const {
getJSAndTSLoader,
} = require('@talend/scripts-config-react-webpack/config/webpack.config.common');
Expand All @@ -11,19 +13,19 @@ const monoRepoFixSourceMap = ['./src', '../design-system/src'];
const srcDirectories = monoRepoFixSourceMap.map(src => path.resolve(process.cwd(), src));

const STORIES = [
`${rootPath}src/Welcome.mdx`,
`${rootPath}src/GettingStarted.mdx`,
`${rootPath}src/Principles.mdx`,
`${rootPath}src/Statuses.mdx`,
// `${rootPath}src/Catalog.mdx`,
`${rootPath}src/content/VoiceAndTone.@(js|tsx|mdx)`,
`${rootPath}src/content/Internationalization.@(js|tsx|mdx)`,
`${rootPath}src/content/Conventions.@(js|tsx|mdx)`,
`${rootPath}src/content/Capitalization.@(js|tsx|mdx)`,
`${rootPath}src/content/Wording.@(js|tsx|mdx)`,
`${rootPath}src/tokens/**/*.mdx`,
`${rootPath}../design-system/src/stories/**/*.@(stories.tsx|mdx)`,
// `${rootPath}src/components/**/*.@(stories.tsx|mdx)`,
`${rootPath}/src/Welcome.mdx`,
`${rootPath}/src/GettingStarted.mdx`,
`${rootPath}/src/Principles.mdx`,
`${rootPath}/src/Statuses.mdx`,
// `${rootPath}/src/Catalog.mdx`,
`${rootPath}/src/content/VoiceAndTone.@(js|tsx|mdx)`,
`${rootPath}/src/content/Internationalization.@(js|tsx|mdx)`,
`${rootPath}/src/content/Conventions.@(js|tsx|mdx)`,
`${rootPath}/src/content/Capitalization.@(js|tsx|mdx)`,
`${rootPath}/src/content/Wording.@(js|tsx|mdx)`,
`${rootPath}/src/tokens/**/*.mdx`,
`${rootPath}/../design-system/src/stories/**/*.@(stories.tsx|mdx)`,
// `${rootPath}/src/components/**/*.@(stories.tsx|mdx)`,
];

export default {
Expand Down
3 changes: 3 additions & 0 deletions packages/design-docs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@
"classnames": "^2.3.1",
"color-contrast-checker": "^2.1.0",
"figma-js": "^1.16.0",
"pkg-dir": "^7.0.0",
"react-hook-form": "^6.15.8",
"react": "^17.0.2",
"react-dom": "^17.0.2",
Expand All @@ -49,11 +50,13 @@
"@storybook/testing-library": "^0.2.0",
"@storybook/testing-react": "^2.0.1",
"@storybook/theming": "^7.4.1",
"@talend/eslint-plugin": "^1.0.1",
"@talend/locales-design-system": "^7.3.0",
"@talend/locales-tui-components": "^9.5.0",
"@talend/locales-tui-containers": "^8.0.2",
"@talend/locales-tui-faceted-search": "^8.1.2",
"@talend/locales-tui-forms": "^9.0.1",
"@talend/scripts-config-typescript": "^11.1.0",
"@talend/scripts-core": "^15.0.0",
"@types/react": "^17.0.65",
"i18next": "^20.6.1",
Expand Down
3 changes: 2 additions & 1 deletion packages/design-system/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -59,11 +59,12 @@
"@storybook/testing-library": "^0.2.0",
"@storybook/theming": "^7.4.1",
"@svgr/webpack": "^5.5.0",
"@talend/bootstrap-theme": "^8.1.3",
"@talend/bootstrap-theme": "^8.2.0",
"@talend/icons": "^6.60.1",
"@talend/locales-design-system": "^7.3.0",
"@talend/scripts-core": "^15.0.0",
"@talend/scripts-config-react-webpack": "^16.0.0",
"@talend/storybook-docs": "^1.2.0",
"@testing-library/cypress": "^9.0.0",
"@types/classnames": "^2.3.1",
"@types/react": "^17.0.65",
Expand Down
4 changes: 4 additions & 0 deletions packages/design-tokens/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,10 @@
"devDependencies": {
"@talend/scripts-core": "^15.0.0",
"@talend/scripts-config-react-webpack": "^16.0.0",
"@talend/scripts-config-typescript": "^11.1.0",
"@talend/babel-plugin-import-from-index": "^1.5.1",
"@talend/babel-plugin-assets-api": "^1.1.0",
"@talend/eslint-plugin": "^1.0.1",
"typeface-source-sans-pro": "^1.1.13"
},
"dependencies": {}
Expand Down
4 changes: 2 additions & 2 deletions packages/faceted-search/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
"@talend/daikon-tql-client": "^1.3.1",
"@talend/utils": "^2.6.0",
"@talend/react-bootstrap": "^1.35.2",
"@talend/design-tokens": "2.9.0",
"@talend/design-tokens": "^2.9.0",
"classnames": "^2.3.2",
"date-fns": "^1.30.1",
"invariant": "^2.2.4",
Expand All @@ -46,7 +46,7 @@
"devDependencies": {
"@storybook/addon-actions": "^7.4.1",
"@storybook/testing-library": "^0.2.0",
"@talend/bootstrap-theme": "^8.1.3",
"@talend/bootstrap-theme": "^8.2.0",
"@talend/design-system": "^7.15.1",
"@talend/icons": "^6.60.1",
"@talend/locales-tui-components": "^9.5.0",
Expand Down
4 changes: 4 additions & 0 deletions packages/flow-designer/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,13 @@
"author": "Talend <[email protected]>",
"license": "Apache-2.0",
"devDependencies": {
"@talend/babel-plugin-import-from-index": "^1.5.1",
"@talend/babel-plugin-assets-api": "^1.1.0",
"@talend/eslint-plugin": "^1.0.1",
"@talend/scripts-config-jest": "^12.2.0",
"@talend/scripts-core": "^15.0.0",
"@talend/scripts-config-react-webpack": "^16.0.0",
"@talend/scripts-config-typescript": "^11.1.0",
"@types/d3": "^7.4.0",
"@types/enzyme": "^3.10.13",
"@types/invariant": "^2.2.35",
Expand Down
2 changes: 1 addition & 1 deletion packages/flow-designer/tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"extends": "../../node_modules/@talend/scripts-config-typescript/tsconfig.json",
"extends": "@talend/scripts-config-typescript/tsconfig.json",
"include": ["src/**/*"],
"compilerOptions": {
"declaration": true,
Expand Down
8 changes: 5 additions & 3 deletions packages/forms/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,11 @@
},
"dependencies": {
"@talend/assets-api": "^1.2.2",
"@talend/json-schema-form-core": "1.1.1",
"@talend/json-schema-form-core": "^1.1.1",
"@talend/react-components": "^11.4.0",
"@talend/design-system": "^7.15.1",
"@talend/design-tokens": "^2.9.0",
"@talend/react-bootstrap": "^1.35.2",
"@talend/utils": "^2.6.0",
"ace-builds": "1.10.1",
"ajv": "^6.12.6",
Expand All @@ -49,7 +50,6 @@
"lodash": "^4.17.21",
"memoize-one": "^6.0.0",
"react-autowhatever": "10.2.0",
"@talend/react-bootstrap": "^1.35.2",
"react-ace": "10.1.0",
"react-hook-form": "^6.15.8",
"react-jsonschema-form": "0.51.0",
Expand All @@ -58,12 +58,14 @@
"devDependencies": {
"@storybook/addon-actions": "^7.4.1",
"@storybook/addon-controls": "^7.4.1",
"@talend/bootstrap-theme": "^8.1.3",
"@talend/bootstrap-theme": "^8.2.0",
"@talend/eslint-plugin": "^1.0.1",
"@talend/icons": "^6.60.1",
"@talend/locales-tui-forms": "^9.0.1",
"@talend/react-components": "^11.4.0",
"@talend/scripts-core": "^15.0.0",
"@talend/scripts-config-react-webpack": "^16.0.0",
"@talend/scripts-config-typescript": "^11.1.0",
"@testing-library/jest-dom": "^5.17.0",
"@testing-library/react": "^12.1.5",
"@testing-library/user-event": "^14.5.1",
Expand Down
3 changes: 3 additions & 0 deletions packages/http/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,11 @@
"lint": "talend-scripts lint"
},
"devDependencies": {
"@talend/eslint-plugin": "^1.0.1",
"@talend/scripts-core": "^15.0.0",
"@talend/scripts-config-babel": "^13.0.0",
"@talend/scripts-config-react-webpack": "^16.0.0",
"@talend/scripts-config-typescript": "^11.1.0",
"fetch-mock": "^9.11.0",
"node-fetch": "^2.7.0",
"react": "^17.0.2",
Expand Down
5 changes: 5 additions & 0 deletions packages/icons/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,11 @@
"@babel/preset-react": "^7.22.15",
"@svgr/webpack": "^5.5.0",
"@talend/scripts-core": "^15.0.0",
"@talend/scripts-config-babel": "^13.0.0",
"@talend/babel-plugin-assets-api": "^1.1.0",
"@talend/babel-plugin-import-from-index": "^1.5.1",
"@talend/scripts-config-typescript": "^11.1.0",
"@talend/design-tokens": "^2.9.0",
"babel-loader": "^9.1.3",
"copy-webpack-plugin": "^10.2.4",
"css-loader": "^4.3.0",
Expand Down
3 changes: 3 additions & 0 deletions packages/jsfc/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,9 @@
"devDependencies": {
"@talend/scripts-core": "^15.0.0",
"@talend/scripts-config-react-webpack": "^16.0.0",
"@talend/scripts-config-typescript": "^11.1.0",
"@talend/babel-plugin-import-from-index":"^1.5.1",
"@talend/babel-plugin-assets-api": "^1.1.0",
"@types/chai": "^3.5.2",
"@types/node": "^6.14.13",
"json-refs": "^3.0.15",
Expand Down
2 changes: 2 additions & 0 deletions packages/local-libs-webpack-plugin/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@
"access": "public"
},
"devDependencies": {
"@talend/eslint-plugin": "^1.0.1",
"@talend/scripts-core": "^15.0.0",
"jest-cli": "^29.7.0"
}
}
Loading

0 comments on commit d8a6638

Please sign in to comment.