Skip to content

Commit 212cd4b

Browse files
committed
feat: pnpm 🎉
1 parent 3de1564 commit 212cd4b

20 files changed

+25654
-28925
lines changed

‎.npmrc

+27
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
####################
2+
# super strict mode
3+
####################
4+
auto-install-peers=false
5+
strict-peer-dependents=true
6+
resolve-peers-from-workspace-root=false
7+
8+
################
9+
# Optimizations
10+
################
11+
# Less strict, but required for tooling to not barf on duplicate peer trees.
12+
# (many libraries declare the same peers, which resolve to the same
13+
# versions)
14+
dedupe-peer-dependents=true
15+
public-hoist-pattern[]=ember-source
16+
17+
################
18+
# Compatibility
19+
################
20+
# highest is what everyone is used to, but
21+
# not ensuring folks are actually compatible with declared ranges.
22+
resolution-mode=highest
23+
24+
################
25+
# Misc
26+
################
27+
verify-deps-before-run=install # always verify deps before running any scripts

‎.yarn/patches/broccoli-asset-rewrite-npm-2.0.0-c4ce42084a.patch

-13
This file was deleted.

‎.yarn/releases/yarn-4.5.3.cjs

-934
This file was deleted.

‎.yarnrc.yml

-7
This file was deleted.

‎package.json

+8-11
Original file line numberDiff line numberDiff line change
@@ -2,23 +2,20 @@
22
"name": "@hashicorp/design-system",
33
"private": true,
44
"version": "0.0.0",
5-
"workspaces": [
6-
"./packages/*",
7-
"./showcase",
8-
"./website"
9-
],
105
"devDependencies": {
116
"@changesets/cli": "^2.27.11",
127
"@changesets/get-github-info": "^0.6.0",
138
"dotenv": "^16.4.7"
149
},
1510
"scripts": {
16-
"release-packages": "yarn changeset publish",
17-
"version-packages": "yarn changeset version && yarn install --mode update-lockfile && yarn workspace website generate-changelog-markdown-files"
11+
"release-packages": "pnpm changeset publish",
12+
"version-packages": "pnpm changeset version && pnpm install --mode update-lockfile && pnpm -F website generate-changelog-markdown-files"
1813
},
19-
"packageManager": "yarn@4.5.3",
20-
"resolutions": {
21-
"broccoli-asset-rewrite@^2.0.0": "patch:broccoli-asset-rewrite@npm%3A2.0.0#./.yarn/patches/broccoli-asset-rewrite-npm-2.0.0-c4ce42084a.patch",
22-
"@glint/environment-ember-loose": "patch:@glint/environment-ember-loose@npm%3A1.4.0#~/.yarn/patches/@glint-environment-ember-loose-npm-1.4.0-31c2f31bcb.patch"
14+
"packageManager": "pnpm@10.0.0+sha512.b8fef5494bd3fe4cbd4edabd0745df2ee5be3e4b0b8b08fa643aa3e4c6702ccc0f00d68fa8a8c9858a735a0032485a44990ed2810526c875e416f001b17df12b",
15+
"pnpm": {
16+
"patchedDependencies": {
17+
"@glint/environment-ember-loose": "patches/@glint__environment-ember-loose.patch",
18+
"@embroider/core": "patches/@embroider__core.patch"
19+
}
2320
}
2421
}

‎packages/components/babel.config.json

+1-3
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,6 @@
2424
}
2525
}
2626
],
27-
["@babel/plugin-proposal-decorators", { "legacy": true }],
28-
"@babel/plugin-transform-class-properties",
29-
"@babel/plugin-transform-private-methods"
27+
"ember-concurrency/async-arrow-task-transform"
3028
]
3129
}

‎packages/components/package.json

+19-26
Original file line numberDiff line numberDiff line change
@@ -17,17 +17,13 @@
1717
"license": "MPL-2.0",
1818
"author": "HashiCorp Design Systems <design-systems@hashicorp.com>",
1919
"scripts": {
20-
"build": "concurrently 'npm:build:*'",
21-
"build:js": "rollup --config",
22-
"build:types": "glint --declaration",
23-
"prepublishOnly": "yarn build && test -f 'dist/styles/@hashicorp/design-system-components.css' || (echo 'The pre-compiled CSS file was not found' && exit 1)",
24-
"start": "concurrently 'yarn:start:*'",
25-
"start:js": "rollup --config --watch --environment development",
26-
"start:types": "glint --declaration --watch",
27-
"lint": "concurrently \"yarn:lint:*(!fix)\" --names \"lint:\"",
28-
"lint:fix": "concurrently \"yarn:lint:*:fix\" --names \"fix:\"",
20+
"build": "rollup --config",
21+
"prepublishOnly": "pnpm build && test -f 'dist/styles/@hashicorp/design-system-components.css' || (echo 'The pre-compiled CSS file was not found' && exit 1)",
22+
"start": "rollup --config --watch --environment development",
23+
"lint": "concurrently \"pnpm:lint:*(!fix)\" --names \"lint:\"",
24+
"lint:fix": "concurrently \"pnpm:lint:*:fix\" --names \"fix:\"",
2925
"lint:css": "stylelint \"src/styles/**/*.scss\"",
30-
"lint:css:fix": "concurrently \"yarn:lint:css --fix\"",
26+
"lint:css:fix": "concurrently \"pnpm:lint:css --fix\"",
3127
"lint:types": "glint",
3228
"lint:hbs": "ember-template-lint .",
3329
"lint:hbs:fix": "ember-template-lint . --fix",
@@ -40,12 +36,13 @@
4036
"@ember/test-waiters": "^3.1.0",
4137
"@embroider/addon-shim": "^1.9.0",
4238
"@floating-ui/dom": "^1.6.12",
43-
"@hashicorp/design-system-tokens": "^2.2.2",
44-
"@hashicorp/flight-icons": "^3.8.0",
39+
"@glimmer/component": "^1.1.2",
40+
"@glimmer/tracking": "^1.1.2",
41+
"@hashicorp/design-system-tokens": "workspace:*",
42+
"@hashicorp/flight-icons": "workspace:*",
4543
"clipboard-polyfill": "^4.1.1",
46-
"decorator-transforms": "^1.2.1",
44+
"decorator-transforms": "^2.3.0",
4745
"ember-a11y-refocus": "^4.1.4",
48-
"ember-cli-sass": "^11.0.1",
4946
"ember-composable-helpers": "^5.0.0",
5047
"ember-concurrency": "^4.0.2",
5148
"ember-element-helper": "^0.8.6",
@@ -58,23 +55,18 @@
5855
"ember-truth-helpers": "^4.0.3",
5956
"luxon": "^2.3.2 || ^3.4.2",
6057
"prismjs": "^1.29.0",
61-
"sass": "^1.83.0",
6258
"tippy.js": "^6.3.7"
6359
},
6460
"devDependencies": {
6561
"@babel/core": "^7.26.0",
66-
"@babel/plugin-proposal-decorators": "^7.25.9",
67-
"@babel/plugin-transform-class-properties": "^7.25.9",
68-
"@babel/plugin-transform-private-methods": "^7.25.9",
6962
"@babel/plugin-transform-typescript": "^7.26.3",
7063
"@babel/runtime": "^7.26.0",
7164
"@ember/test-helpers": "^4.0.4",
72-
"@embroider/addon-dev": "^4.3.1",
73-
"@glimmer/component": "^1.1.2",
74-
"@glimmer/tracking": "^1.1.2",
75-
"@glint/core": "^1.5.0",
76-
"@glint/environment-ember-loose": "^1.4.0",
77-
"@glint/template": "^1.5.0",
65+
"@embroider/addon-dev": "^7.1.1",
66+
"@glint/core": "^1.5.1",
67+
"@glint/environment-ember-loose": "^1.5.1",
68+
"@glint/environment-ember-template-imports": "^1.5.1",
69+
"@glint/template": "^1.5.1",
7870
"@rollup/plugin-babel": "^6.0.4",
7971
"@tsconfig/ember": "^3.0.8",
8072
"@types/ember-qunit": "^6.1.3",
@@ -89,6 +81,7 @@
8981
"babel-plugin-ember-template-compilation": "^2.3.0",
9082
"concurrently": "^9.1.0",
9183
"ember-basic-dropdown": "^8.4.0",
84+
"ember-source": "^5.12.0",
9285
"ember-template-lint": "^6.0.0",
9386
"ember-template-lint-plugin-prettier": "^5.0.0",
9487
"eslint": "^8.57.1",
@@ -103,7 +96,7 @@
10396
"rollup": "^4.28.1",
10497
"rollup-plugin-copy": "^3.5.0",
10598
"rollup-plugin-scss": "^4.0.1",
106-
"rollup-plugin-ts": "^3.4.5",
99+
"sass": "^1.83.0",
107100
"stylelint": "^16.12.0",
108101
"stylelint-config-rational-order": "^0.1.2",
109102
"stylelint-config-standard-scss": "^14.0.0",
@@ -331,4 +324,4 @@
331324
"engines": {
332325
"node": ">= 18"
333326
}
334-
}
327+
}

‎packages/components/rollup.config.mjs

+4-1
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ const plugins = [
5151
scss({
5252
fileName: 'styles/@hashicorp/design-system-components.css',
5353
includePaths: [
54-
'../../node_modules/@hashicorp/design-system-tokens/dist/products/css',
54+
'node_modules/@hashicorp/design-system-tokens/dist/products/css',
5555
],
5656
}),
5757

@@ -65,6 +65,9 @@ const plugins = [
6565
// Ensure that .gjs files are properly integrated as Javascript
6666
addon.gjs(),
6767

68+
// Emit .d.ts declaration files
69+
addon.declarations('declarations'),
70+
6871
// This babel config should *not* apply presets or compile away ES modules.
6972
// It exists only to provide development niceties for you, like automatic
7073
// template colocation.

‎packages/ember-flight-icons/package.json

+13-13
Original file line numberDiff line numberDiff line change
@@ -17,26 +17,26 @@
1717
"license": "MPL-2.0",
1818
"author": "HashiCorp Design Systems <design-systems@hashicorp.com>",
1919
"scripts": {
20-
"build": "concurrently 'yarn:build:*'",
20+
"build": "concurrently 'pnpm:build:*'",
2121
"build:js": "rollup --config",
2222
"build:types": "glint --declaration",
23-
"lint": "concurrently 'yarn:lint:*(!fix)' --names 'lint:'",
24-
"lint:fix": "concurrently 'yarn:lint:*:fix' --names 'fix:'",
23+
"lint": "concurrently 'pnpm:lint:*(!fix)' --names 'lint:'",
24+
"lint:fix": "concurrently 'pnpm:lint:*:fix' --names 'fix:'",
2525
"lint:hbs": "ember-template-lint . --no-error-on-unmatched-pattern",
2626
"lint:hbs:fix": "ember-template-lint . --fix --no-error-on-unmatched-pattern",
2727
"lint:js": "eslint . --cache",
2828
"lint:js:fix": "eslint . --fix",
2929
"lint:types": "glint",
30-
"prepublishOnly": "concurrently 'yarn:build:*'",
31-
"start": "concurrently 'yarn:start:*'",
30+
"prepublishOnly": "concurrently 'pnpm:build:*'",
31+
"start": "concurrently 'pnpm:start:*'",
3232
"start:js": "rollup --config --watch --no-watch.clearScreen",
3333
"start:types": "glint --declaration --watch",
3434
"test": "echo 'A v2 addon does not have tests, run tests in test-app'"
3535
},
3636
"dependencies": {
3737
"@embroider/addon-shim": "^1.9.0",
38-
"@hashicorp/flight-icons": "^3.8.0",
39-
"decorator-transforms": "^1.2.1",
38+
"@hashicorp/flight-icons": "workspace:*",
39+
"decorator-transforms": "^2.3.0",
4040
"ember-get-config": "^2.1.1"
4141
},
4242
"devDependencies": {
@@ -47,13 +47,13 @@
4747
"@babel/plugin-transform-typescript": "^7.26.3",
4848
"@babel/preset-typescript": "^7.26.0",
4949
"@babel/runtime": "^7.26.0",
50-
"@embroider/addon-dev": "^4.3.1",
50+
"@embroider/addon-dev": "^7.1.1",
5151
"@glimmer/component": "^1.1.2",
5252
"@glimmer/tracking": "^1.1.2",
53-
"@glint/core": "^1.5.0",
54-
"@glint/environment-ember-loose": "^1.4.0",
55-
"@glint/environment-ember-template-imports": "^1.5.0",
56-
"@glint/template": "^1.5.0",
53+
"@glint/core": "^1.5.1",
54+
"@glint/environment-ember-loose": "^1.5.1",
55+
"@glint/environment-ember-template-imports": "^1.5.1",
56+
"@glint/template": "^1.5.1",
5757
"@rollup/plugin-babel": "^6.0.4",
5858
"@tsconfig/ember": "^3.0.8",
5959
"@typescript-eslint/eslint-plugin": "^8.18.1",
@@ -112,4 +112,4 @@
112112
"engines": {
113113
"node": ">= 18"
114114
}
115-
}
115+
}

‎packages/flight-icons/package.json

+3-3
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@
1616
"license": "MPL-2.0",
1717
"author": "HashiCorp Design Systems <design-systems@hashicorp.com>",
1818
"scripts": {
19-
"typecheck": "yarn tsc --noEmit",
20-
"lint": "yarn eslint --quiet --ext .js,.ts,.tsx",
19+
"typecheck": "pnpm tsc --noEmit",
20+
"lint": "pnpm eslint --quiet --ext .js,.ts,.tsx",
2121
"sync": "ts-node --transpile-only ./scripts/sync",
2222
"build": "ts-node --transpile-only ./scripts/build"
2323
},
@@ -54,4 +54,4 @@
5454
"ts-node": "^10.9.2",
5555
"typescript": "^5.7.2"
5656
}
57-
}
57+
}

‎packages/tokens/package.json

+3-3
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,8 @@
1818
"author": "HashiCorp Design Systems <design-systems@hashicorp.com>",
1919
"type": "module",
2020
"scripts": {
21-
"typecheck": "yarn tsc --noEmit",
22-
"lint": "yarn eslint --quiet --ext .js,.ts",
21+
"typecheck": "pnpm tsc --noEmit",
22+
"lint": "pnpm eslint --quiet --ext .js,.ts",
2323
"build": "tsx ./scripts/build"
2424
},
2525
"devDependencies": {
@@ -40,4 +40,4 @@
4040
"tsx": "^4.19.2",
4141
"typescript": "^5.7.2"
4242
}
43-
}
43+
}

‎patches/@embroider__core.patch

+19
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
diff --git a/src/app-files.js b/src/app-files.js
2+
index 924a11241f9e6584fee5aba793e9cd86ea6d708f..6822e87bba314adeacee240964fd6f3317349088 100644
3+
--- a/src/app-files.js
4+
+++ b/src/app-files.js
5+
@@ -74,10 +74,10 @@ class AppFiles {
6+
}
7+
continue;
8+
}
9+
- if (relativePath.startsWith('templates/components/')) {
10+
- components.push(relativePath);
11+
- continue;
12+
- }
13+
+ // if (relativePath.startsWith('templates/components/')) {
14+
+ // components.push(relativePath);
15+
+ // continue;
16+
+ // }
17+
if (relativePath.startsWith('helpers/')) {
18+
helpers.push(relativePath);
19+
continue;
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
diff --git a/-private/environment/index.js b/-private/environment/index.js
2-
index 217583f4bae53f6f72db8d3debd0f31b3dac2b8e..8caf5463cf2be2248952c2347c738b98d2b7e22b 100644
2+
index 217583f4bae53f6f72db8d3debd0f31b3dac2b8e..5f430a52343ad4fc0ac1aaa11855afd91d6741cc 100644
33
--- a/-private/environment/index.js
44
+++ b/-private/environment/index.js
5-
@@ -46,10 +46,8 @@ function emberLooseEnvironment(options) {
5+
@@ -46,10 +46,12 @@ function emberLooseEnvironment(options) {
66
// Pod component/controller/route
77
candidates.push(templatePath.replace(REGEXES.POD_TEMPLATE, '/component.ts'), templatePath.replace(REGEXES.POD_TEMPLATE, '/controller.ts'), templatePath.replace(REGEXES.POD_TEMPLATE, '/route.ts'));
88
}
@@ -12,6 +12,10 @@ index 217583f4bae53f6f72db8d3debd0f31b3dac2b8e..8caf5463cf2be2248952c2347c738b98
1212
- }
1313
+ // we no longer need this as it remnant of classic components and it interferes with our route stricture in showcase up
1414
+ // upstream PR: https://github.com/typed-ember/glint/pull/721
15+
+ // else if (templatePath.includes('/templates/components/')) {
16+
+ // // Classic component
17+
+ // candidates.push(colocatedTsScriptPath.replace('/templates/components/', '/components/'));
18+
+ // }
1519
else if (templatePath.includes('/templates/')) {
1620
// Classic controller/route
1721
candidates.push(colocatedTsScriptPath.replace('/templates/', '/controllers/'), colocatedTsScriptPath.replace('/templates/', '/routes/'));

0 commit comments

Comments
 (0)