-
Notifications
You must be signed in to change notification settings - Fork 153
/
package.json
127 lines (127 loc) · 7.37 KB
/
package.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
{
"name": "foundation.mozilla.org",
"repository": "https://github.com/mozilla/foundation.mozilla.org",
"issues": "https://github.com/mozilla/foundation.mozilla.org/issues",
"description": "Mozilla Foundation site",
"engines": {
"node": "20.x"
},
"scripts": {
"build": "run-s build:clean && run-p build:common build:js:prod && npm run postcss:build",
"build:clean": "shx rm -rf network-api/networkapi/temp/frontend && shx rm -rf network-api/networkapi/frontend && shx mkdir -p network-api/networkapi/frontend/_js",
"build:common": "run-p build:images build:fonts build:css build:contribute",
"build:contribute": "shx cp contribute.json network-api/networkapi/frontend/",
"build:images": "shx rm -rf network-api/networkapi/frontend/_images && shx cp -r source/images network-api/networkapi/frontend/_images",
"build:js:dev": "node esbuild.config.js -- --node-env development",
"build:js:prod": "node esbuild.config.js -- --node-env production",
"build:fonts": "run-p build:fonts:fonts && run-p build:fonts:css",
"build:fonts:fonts": "shx rm -rf network-api/networkapi/frontend/_fonts && cp -r source/fonts network-api/networkapi/frontend/_fonts",
"build:fonts:css": "run-p build:fonts:css:**",
"build:fonts:css:base": "sass --style=compressed source/fonts/css/base.css network-api/networkapi/frontend/_fonts/css/base.min.css && shx rm network-api/networkapi/frontend/_fonts/css/base.css",
"build:fonts:css:caveat": "sass --style=compressed source/fonts/css/caveat.css network-api/networkapi/frontend/_fonts/css/caveat.min.css && shx rm network-api/networkapi/frontend/_fonts/css/caveat.css",
"build:fonts:css:changa": "sass --style=compressed source/fonts/css/changa.css network-api/networkapi/frontend/_fonts/css/changa.min.css && shx rm network-api/networkapi/frontend/_fonts/css/changa.css",
"build:css": "run-p build:css:file:**",
"build:css:file:main": "sass source/sass/main.scss network-api/networkapi/temp/frontend/_css/main.compiled.css",
"build:css:file:bg": "sass source/sass/buyers-guide/bg-main.scss network-api/networkapi/temp/frontend/_css/buyers-guide.compiled.css",
"build:css:file:donate": "sass source/sass/donate/donate-main.scss network-api/networkapi/temp/frontend/_css/donate.compiled.css",
"build:css:file:formassembly": "sass source/sass/formassembly-override.scss network-api/networkapi/temp/frontend/_css/formassembly-override.compiled.css",
"fix": "run-s fix:*",
"fix:js": "npm run lint:js:eslint -- --fix",
"fix:css": "npm run lint:css:scss -- --fix",
"fix:scss": "npm run fix:css",
"heroku-postbuild": "npm run build",
"lint": "run-s lint:*",
"lint:procfile": "node test/test-procfile.js",
"lint:js": "run-s lint:js:*",
"lint:js:eslint": "eslint --config ./eslint.config.js \"source/js/**/*.jsx\" \"network-api/networkapi/wagtailcustomization/**/*.js\" \"tests/**/*.js\" \"./*.js\"",
"lint:css": "run-s lint:css:*",
"lint:css:scss": "stylelint \"source/sass/**/*.scss\" \"source/js/**/*.scss\" --custom-syntax postcss-scss",
"lint:css:scss:color": "stylelint \"source/sass/**/*.scss\" \"source/js/**/*.scss\" \"!source/sass/**/_colors.scss\" \"!source/sass/**/formassembly-override.scss\" --custom-syntax postcss-scss --config .stylelintrc-colors.js",
"lint:css:network": "stylelint \"network-api/networkapi/{,!(frontend)/**/}*.css\" --custom-syntax postcss-scss",
"postcss:build": "postcss network-api/networkapi/temp/frontend/_css/*.css --dir network-api/networkapi/frontend/_css --verbose",
"postcss:watch": "TAILWIND_MODE=watch postcss network-api/networkapi/temp/frontend/_css/*.css --dir network-api/networkapi/frontend/_css --watch --verbose",
"optimize:svg": "svgo --multipass --folder ./source/images/ --recursive",
"optimize:jpg": "find source/images -type f -name '*.jpg' -print0 | xargs -0 -n 1 -P 6 -I '{}' guetzli --quality 93 '{}' '{}'",
"optimize:png": "find source/images -type f -name '*.png' -print0 | xargs -0 -n 1 -P 6 optipng",
"optimize": "run-p optimize:**",
"percy": "percy exec -t 750 -- npm run playwright:percy",
"playwright": "npm run playwright:wait:dev && playwright test ./tests/integration/",
"playwright:install": "playwright install chromium firefox webkit",
"playwright:wait:dev": "wait-on -i 3000 http://localhost:8000/static/_css/tailwind.compiled.css",
"playwright:percy": "run-p --race server playwright:visual",
"playwright:urls": "wait-on -i 3000 -t 120000 -v http://127.0.0.1:8000/cms && playwright test ./tests/urls.spec.js",
"playwright:visual": "wait-on -i 3000 -t 120000 -v http://127.0.0.1:8000/cms && playwright test ./tests/visual.spec.js",
"playwright:ci": "run-p --race server playwright:integration",
"playwright:integration": "wait-on -i 3000 -t 120000 -v http://127.0.0.1:8000/cms && playwright test ./tests/integration/",
"precommit": "npm run test",
"prettier:js": "prettier \"source/js/**/*.js\" \"source/js/**/*.jsx\" \"network-api/networkapi/wagtailcustomization/**/*.js\" \"tests/**/*.js\" ./*.js",
"prettier:scss": "prettier \"source/sass/**/*.scss\" \"source/js/**/*.scss\" \"network-api/networkapi/{,!(frontend)/**/}*.css\"",
"pyright": "pyright",
"server": "python network-api/manage.py runserver 0.0.0.0:8000",
"server:silent": "python network-api/manage.py runserver 0.0.0.0:8000 >> server.log 2>&1",
"start": "docker-compose up",
"sync": "browser-sync start --proxy \"localhost:8000\" --reload-debounce 50 --files \"./network-api/networkapi/**/*.html\" \"./network-api/networkapi/frontend/_css/*.css\" \"./network-api/networkapi/frontend/_js/*.js\"",
"test": "npm run lint",
"watch": "run-s build:clean && run-p build:common && run-p build:js:dev postcss:watch watch:**",
"watch:images": "chokidar \"source/images/**/*\" -c \"npm run build:images\"",
"watch:scss": "chokidar \"source/**/*.scss\" -c \"npm run build:css\""
},
"browserslist": [
"> 1%",
"last 2 versions"
],
"author": "Mozilla",
"license": "MPL-2.0",
"dependencies": {
"@sentry/browser": "^8.38.0",
"@tailwindcss/forms": "^0.5.9",
"autoprefixer": "^10.4.20",
"axe-core": "^4.10.2",
"bootstrap": "^4.6.0",
"chart.js": "4.4.6",
"classnames": "2.5.1",
"countup.js": "^2.8.0",
"cssnano": "^7.0.6",
"esbuild": "^0.24.0",
"gsap": "^3.12.5",
"htmx.org": "^1.9.12",
"locomotive-scroll": "^4.1.4",
"moment": "^2.29.4",
"npm-run-all": "^4.1.3",
"postcss": "^8.4.49",
"postcss-cli": "^11.0.0",
"postcss-import": "^16.1.0",
"postcss-scss": "^4.0.9",
"prop-types": "^15.7.2",
"react": "^18.3.1",
"react-dom": "^18.3.1",
"react-ga": "3.3.1",
"sass": "^1.59.3",
"shx": "^0.3.4",
"swiper": "^11.1.15",
"tailwindcss": "^3.4.15",
"uuid": "^10.0.0",
"whatwg-fetch": "^3.6.20"
},
"devDependencies": {
"@axe-core/react": "^4.10.1",
"@percy/cli": "^1.27.1",
"@percy/playwright": "^1.0.7",
"@playwright/test": "^1.48.2",
"browser-sync": "^3.0.3",
"browserslist": "^4.24.2",
"chokidar-cli": "^3.0.0",
"eslint": "^9.15.0",
"eslint-config-prettier": "^9.1.0",
"eslint-plugin-jsx-a11y": "^6.10.2",
"eslint-plugin-prettier": "^5.2.1",
"eslint-plugin-react": "^7.37.2",
"optipng-bin": "^9.0.0",
"prettier": "^3.3.3",
"stylelint": "^16.10.0",
"stylelint-config-standard": "^36.0.1",
"stylelint-prettier": "^5.0.2",
"svgo": "^3.3.2",
"wait-on": "^7"
}
}