diff --git a/.github/actions/setup-node/action.yml b/.github/actions/setup-node/action.yml new file mode 100644 index 0000000000..89bd8521e1 --- /dev/null +++ b/.github/actions/setup-node/action.yml @@ -0,0 +1,32 @@ +name: 'Setup nodejs' +description: 'Setup nodejs' +author: 'Talend' +secrets: + NPM_TOKEN: + description: 'The NPM token to use' +runs: + using: 'composite' + steps: + - name: Set up Node.js + uses: actions/setup-node@5e21ff4d9bc1a8cf6de233a3057d20ec6b3fb69d #v3.8.1 + with: + node-version: '20' + registry-url: 'https://registry.npmjs.org/' + scope: '@talend' + + - name: Install yarn + shell: bash + run: npm i -g yarn + + - name: Get yarn cache directory path + id: yarn-cache-dir-path + shell: bash + run: echo "dir=$(yarn cache dir)" >> $GITHUB_OUTPUT + + - uses: actions/cache@704facf57e6136b1bc63b828d79edcd491f0ee84 #v3.3.2 + id: yarn-cache # use this to check for `cache-hit` (`steps.yarn-cache.outputs.cache-hit != 'true'`) + with: + path: ${{ steps.yarn-cache-dir-path.outputs.dir }} + key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} + restore-keys: | + ${{ runner.os }}-yarn- diff --git a/.github/workflows/changeset.yml b/.github/workflows/changeset.yml index 5a55cab4a2..91147291ee 100644 --- a/.github/workflows/changeset.yml +++ b/.github/workflows/changeset.yml @@ -29,14 +29,9 @@ jobs: fetch-depth: 0 persist-credentials: false - - name: Setup Node.js - uses: actions/setup-node@5e21ff4d9bc1a8cf6de233a3057d20ec6b3fb69d # v3.8.1 - with: - node-version: 18 - registry-url: "https://registry.npmjs.org/" - scope: "@talend" - cache: "yarn" - + - name: Use Node.js + uses: ./.github/actions/setup-node + - name: Install Dependencies run: yarn --frozen-lockfile diff --git a/.github/workflows/dependencies.yml b/.github/workflows/dependencies.yml index 83ec2f6039..be1104fe28 100644 --- a/.github/workflows/dependencies.yml +++ b/.github/workflows/dependencies.yml @@ -22,12 +22,7 @@ jobs: uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac #v4.0.0 - name: Use Node.js - uses: actions/setup-node@5e21ff4d9bc1a8cf6de233a3057d20ec6b3fb69d # v3.8.1 - with: - node-version: 18 - registry-url: "https://registry.npmjs.org/" - scope: "@talend" - cache: "yarn" + uses: ./.github/actions/setup-node - name: Upgrade dependencies run: | diff --git a/.github/workflows/design-system-component-testing.yml b/.github/workflows/design-system-component-testing.yml index 6eb5a721fe..f8c47c05f7 100644 --- a/.github/workflows/design-system-component-testing.yml +++ b/.github/workflows/design-system-component-testing.yml @@ -24,12 +24,8 @@ jobs: - name: Checkout repository uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac #v4.0.0 - - uses: actions/setup-node@5e21ff4d9bc1a8cf6de233a3057d20ec6b3fb69d # v3.8.1 - with: - node-version: 18 - registry-url: "https://registry.npmjs.org/" - scope: "@talend" - cache: "yarn" + - name: Use Node.js + uses: ./.github/actions/setup-node - uses: actions/cache@704facf57e6136b1bc63b828d79edcd491f0ee84 #v3.3.2 with: diff --git a/.github/workflows/icons.yml b/.github/workflows/icons.yml index c6104b3f40..04d6a4b7b2 100644 --- a/.github/workflows/icons.yml +++ b/.github/workflows/icons.yml @@ -25,12 +25,8 @@ jobs: persist-credentials: false - name: Use Node.js - uses: actions/setup-node@5e21ff4d9bc1a8cf6de233a3057d20ec6b3fb69d # v3.8.1 - with: - node-version: 18 - check-latest: true - cache: "yarn" - + uses: ./.github/actions/setup-node + - name: Download icons run: npx @talend/figma-icons-downloader env: diff --git a/.github/workflows/pr-lint.yml b/.github/workflows/pr-lint.yml index f172765eef..9dcc3c90db 100644 --- a/.github/workflows/pr-lint.yml +++ b/.github/workflows/pr-lint.yml @@ -28,14 +28,8 @@ jobs: fetch-depth: 0 # otherwise, you will failed to push refs to dest repo - name: Use Node.js - uses: actions/setup-node@5e21ff4d9bc1a8cf6de233a3057d20ec6b3fb69d # v3.8.1 - with: - node-version: 18 - check-latest: true - registry-url: "https://registry.npmjs.org/" - scope: "@talend" - cache: "yarn" - + uses: ./.github/actions/setup-node + - name: Install run: yarn install --frozen-lockfile --ignore-scripts diff --git a/.github/workflows/pr-playground.yml b/.github/workflows/pr-playground.yml index 0798d9371d..374f049c24 100644 --- a/.github/workflows/pr-playground.yml +++ b/.github/workflows/pr-playground.yml @@ -27,12 +27,8 @@ jobs: uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac #v4.0.0 - name: Use Node.js - uses: actions/setup-node@5e21ff4d9bc1a8cf6de233a3057d20ec6b3fb69d # v3.8.1 - with: - node-version: 18 - registry-url: "https://registry.npmjs.org/" - scope: "@talend" - cache: "yarn" + uses: ./.github/actions/setup-node + - name: Install and build playground id: build diff --git a/.github/workflows/pr-test.yml b/.github/workflows/pr-test.yml index b271fedefb..f4a95de179 100644 --- a/.github/workflows/pr-test.yml +++ b/.github/workflows/pr-test.yml @@ -24,13 +24,7 @@ jobs: uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac #v4.0.0 - name: Use Node.js - uses: actions/setup-node@5e21ff4d9bc1a8cf6de233a3057d20ec6b3fb69d # v3.8.1 - with: - node-version: 18 - check-latest: true - registry-url: "https://registry.npmjs.org/" - scope: "@talend" - cache: "yarn" + uses: ./.github/actions/setup-node - name: Install run: yarn install --frozen-lockfile diff --git a/.github/workflows/surge-cleanup.yml b/.github/workflows/surge-cleanup.yml index fc3a610663..4bc6b29e9d 100644 --- a/.github/workflows/surge-cleanup.yml +++ b/.github/workflows/surge-cleanup.yml @@ -13,10 +13,8 @@ jobs: environment: pull_request_unsafe steps: - - name: Use Node.js - uses: actions/setup-node@5e21ff4d9bc1a8cf6de233a3057d20ec6b3fb69d # v3.8.1 - with: - node-version: 18 - - - name: Push to surge - run: npx surge teardown ${{ github.event.pull_request.number }}.talend.surge.sh --token ${{ secrets.SURGE_TOKEN }} + - name: Use Node.js + uses: ./.github/actions/setup-node + + - name: Push to surge + run: npx surge teardown ${{ github.event.pull_request.number }}.talend.surge.sh --token ${{ secrets.SURGE_TOKEN }} diff --git a/.github/workflows/tests-cron.yml b/.github/workflows/tests-cron.yml index 20362c668b..1641011e9d 100644 --- a/.github/workflows/tests-cron.yml +++ b/.github/workflows/tests-cron.yml @@ -20,12 +20,7 @@ jobs: uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac #v4.0.0 - name: Use Node.js - uses: actions/setup-node@5e21ff4d9bc1a8cf6de233a3057d20ec6b3fb69d # v3.8.1 - with: - node-version: 18 - registry-url: "https://registry.npmjs.org/" - scope: "@talend" - cache: "yarn" + uses: ./.github/actions/setup-node - name: Install and tests run: | diff --git a/.github/workflows/visual-testing.yml b/.github/workflows/visual-testing.yml index 95d824a139..7d2a26b583 100644 --- a/.github/workflows/visual-testing.yml +++ b/.github/workflows/visual-testing.yml @@ -32,10 +32,8 @@ jobs: with: fetch-depth: 0 - - uses: actions/setup-node@5e21ff4d9bc1a8cf6de233a3057d20ec6b3fb69d # v3.8.1 - with: - node-version: 18 - cache: "yarn" + - name: Use Node.js + uses: ./.github/actions/setup-node - name: Install dependencies run: yarn --frozen-lock diff --git a/.github/workflows/yarn-deduplicate.yml b/.github/workflows/yarn-deduplicate.yml index 601eab816f..d9dfb8526d 100644 --- a/.github/workflows/yarn-deduplicate.yml +++ b/.github/workflows/yarn-deduplicate.yml @@ -29,12 +29,7 @@ jobs: fetch-depth: 0 # otherwise, you will failed to push refs to dest repo - name: Use Node.js - uses: actions/setup-node@5e21ff4d9bc1a8cf6de233a3057d20ec6b3fb69d # v3.8.1 - with: - node-version: 18 - registry-url: "https://registry.npmjs.org/" - scope: "@talend" - cache: "yarn" + uses: ./.github/actions/setup-node - name: yarn-deduplicate id: deduplicate diff --git a/fork/bootstrap-sass/CHANGELOG.md b/fork/bootstrap-sass/CHANGELOG.md index f6634c90ed..768f54ad9e 100644 --- a/fork/bootstrap-sass/CHANGELOG.md +++ b/fork/bootstrap-sass/CHANGELOG.md @@ -1,5 +1,16 @@ # Changelog +## 3.5.0 + +### Minor Changes + +- 9d137cb98: \* 275e7da72 2023-08-03 feat(TDOPS-4875): use elevation tokens (#4821) + - bfc02c4fb 2023-07-24 feat(ARCH-720): use design-tokens for colors (#4779) + - c18aabb97 2023-01-12 feat(ARCH-662/scripts-core): move to ESM and remove presets (#4531) + - aa5223cf3 2021-12-20 chore(ARCH-404/CI): decrease time needed (#3564) + - 4842bffc2 2021-11-02 chore: wake up the playground to test UMDs (#3428) + - 667cd0a50 2021-10-05 chore: upgrade dependencies (#3459) + ## 3.4.8 ### Patch Changes diff --git a/fork/bootstrap-sass/package.json b/fork/bootstrap-sass/package.json index 664cff8d3c..bf65b31c98 100644 --- a/fork/bootstrap-sass/package.json +++ b/fork/bootstrap-sass/package.json @@ -1,6 +1,6 @@ { "name": "@talend/bootstrap-sass", - "version": "3.4.8", + "version": "3.5.0", "description": "bootstrap-sass is a Sass-powered version of Bootstrap 3, ready to drop right into your Sass powered applications.", "main": "assets/javascripts/bootstrap.js", "style": "assets/stylesheets/_bootstrap.scss", diff --git a/fork/dynamic-cdn-webpack-plugin/src/find.js b/fork/dynamic-cdn-webpack-plugin/src/find.js index cc51eeb70c..c2a93405b0 100644 --- a/fork/dynamic-cdn-webpack-plugin/src/find.js +++ b/fork/dynamic-cdn-webpack-plugin/src/find.js @@ -34,14 +34,12 @@ function findPackagesFromScopeFolder(scope, name, scopeFolderPath) { // just add the path to the found list return accu.concat(subFolderPath); } - // TODO CHECKJM Not compatible with pnpm + // TODO 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.concat(findPackagesFromNonScopeFolder(scope, name, nestedNodeModulesPath, [])); } return accu; }, []); @@ -62,32 +60,22 @@ function findPackagesFromNonScopeFolder(scope, name, nonScopeFolderPath) { // for scope folders, we need a special treatment to avoid getting scoped packages when we don't want a scoped one. // ex: search for `classnames`, we don't want to find `@types/classnames` in the result return accu.concat( - findPackagesFromScopeFolder( - scope, - name, - path.join(nonScopeFolderPath, subFolder.name), - ), + findPackagesFromScopeFolder(scope, name, path.join(nonScopeFolderPath, subFolder.name)), ); } else if (!scope && subFolder.name === name) { // we want a NON scoped package, we are in a non scoped folder, and the names match return accu.concat(path.join(nonScopeFolderPath, subFolder.name)); } - const nestedNodeModulesPath = path.join( - nonScopeFolderPath, - subFolder.name, - 'node_modules', - ); + const nestedNodeModulesPath = path.join(nonScopeFolderPath, subFolder.name, 'node_modules'); if (fs.existsSync(nestedNodeModulesPath)) { - return accu.concat( - findPackagesFromNonScopeFolder(scope, name, nestedNodeModulesPath), - ); + return accu.concat(findPackagesFromNonScopeFolder(scope, name, nestedNodeModulesPath)); } return accu; }, []); } function findPackages(scope, name, buff = []) { - console.log('findPackages', scope, name, buff) + console.log('findPackages', scope, name, buff); // https://nodejs.org/dist/latest-v14.x/docs/api/modules.html#modules_require_resolve_paths_request const roots = require.resolve.paths(name).filter(p => fs.existsSync(p)); if (roots === null) { diff --git a/packages/components/CHANGELOG.md b/packages/components/CHANGELOG.md index 120810182c..4b781da04c 100644 --- a/packages/components/CHANGELOG.md +++ b/packages/components/CHANGELOG.md @@ -1,5 +1,13 @@ # @talend/react-components +## 11.4.4 + +### Patch Changes + +- 1cb4b7b29: fix(TFD-16296): Add ellipsis on collapsible panel header +- Updated dependencies [9d137cb98] + - @talend/bootstrap-theme@8.2.0 + ## 11.4.3 ### Patch Changes diff --git a/packages/components/package.json b/packages/components/package.json index 35f1555e76..480f878828 100644 --- a/packages/components/package.json +++ b/packages/components/package.json @@ -35,7 +35,7 @@ "dependencies": { "@popperjs/core": "^2.11.8", "@talend/assets-api": "^1.2.2", - "@talend/bootstrap-theme": "^8.1.3", + "@talend/bootstrap-theme": "^8.2.0", "@talend/design-tokens": "^2.9.0", "@talend/react-a11y": "^1.1.0", "@talend/icons": "^6.60.1", @@ -70,12 +70,12 @@ }, "devDependencies": { "@storybook/addon-actions": "^7.4.1", - "@talend/bootstrap-theme": "^8.1.3", + "@talend/bootstrap-theme": "^8.2.0", "@talend/design-system": "^7.15.1", "@talend/locales-design-system": "^7.3.0", "@talend/locales-tui-components": "^9.5.0", "@talend/scripts-core": "^15.0.0", - "@talend/scripts-config-react-webpack": "^16.0.0", + "@talend/scripts-config-react-webpack": "^16.1.0", "@testing-library/jest-dom": "^5.17.0", "@testing-library/react": "^12.1.5", "@testing-library/user-event": "^13.5.0", @@ -110,5 +110,5 @@ "publishConfig": { "access": "public" }, - "version": "11.4.3" + "version": "11.4.4" } diff --git a/packages/components/src/CollapsiblePanel/CollapsiblePanel.module.scss b/packages/components/src/CollapsiblePanel/CollapsiblePanel.module.scss index 9d5d3bafbf..e6209d3b2d 100644 --- a/packages/components/src/CollapsiblePanel/CollapsiblePanel.module.scss +++ b/packages/components/src/CollapsiblePanel/CollapsiblePanel.module.scss @@ -173,6 +173,13 @@ $tc-collapsible-panel-padding-larger: $padding-larger !default; display: flex; align-items: center; justify-content: space-between; + min-width: 0; // trick to avoid conflict between flex and overflow + + > * { + white-space: nowrap; + overflow: hidden; + text-overflow: ellipsis; + } } } } diff --git a/packages/components/src/CollapsiblePanel/CollapsiblePanel.stories.js b/packages/components/src/CollapsiblePanel/CollapsiblePanel.stories.js index 5f82d51240..192752ac0d 100644 --- a/packages/components/src/CollapsiblePanel/CollapsiblePanel.stories.js +++ b/packages/components/src/CollapsiblePanel/CollapsiblePanel.stories.js @@ -172,6 +172,18 @@ export const Header = () => (