Skip to content

Commit 2df072e

Browse files
Fix stylelint integration (#836)
* Fix the npm run lint:css command * Fix rule for vec4 * Rewrite with a simple media query instead of stylus function * Fix the no-duplicate-selectors errors * Use css variables --font-normal and --font-monospace * Remove non used webfontloader and Select rules * Auto fix all stylelint errors * Add lint:css to CI * Make the media query min-width 1025px to really hide #viewportHud on iPad * Disable selector-not-notation stylelint that wrongly report error * Disable eslint indent rule that conflicts with prettier
1 parent 8de513c commit 2df072e

File tree

15 files changed

+286
-201
lines changed

15 files changed

+286
-201
lines changed

.eslintrc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
{
22
"extends": ["eslint:recommended", "plugin:react/recommended", "plugin:react/jsx-runtime", "standard"],
33
"rules": {
4+
"indent": "off",
45
"multiline-ternary": "off",
56
"no-console": "off",
67
"no-lone-blocks": "off",

.github/workflows/ci.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,5 +35,8 @@ jobs:
3535
- name: Check Lint
3636
run: npm run lint
3737

38+
- name: Check CSS Lint
39+
run: npm run lint:css
40+
3841
- name: Check Build
3942
run: npm run dist

.stylelintrc

Lines changed: 0 additions & 12 deletions
This file was deleted.

package-lock.json

Lines changed: 144 additions & 21 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
"dist:min": "cross-env MINIFY=true npm run build",
1212
"ghpages": "npm run preghpages && gh-pages -d gh-pages",
1313
"lint": "npm run lintfile src/",
14-
"lint:css": "stylelint src/css/main.css",
14+
"lint:css": "stylelint src/style/",
1515
"lintfile": "eslint",
1616
"preghpages": "npm run dist && shx rm -rf gh-pages && shx mkdir gh-pages && shx cp -r assets dist examples index.html gh-pages && shx sed -i http://localhost:3333 .. gh-pages/examples/index.html",
1717
"prepare": "husky",
@@ -57,9 +57,10 @@
5757
"react-test-renderer": "^18.2.0",
5858
"shx": "^0.3.4",
5959
"style-loader": "^3.3.4",
60-
"stylelint": "^16.2.1",
61-
"stylelint-config-standard": "^36.0.0",
62-
"stylelint-order": "^6.0.4",
60+
"postcss-styl": "^0.12.3",
61+
"stylelint": "^16.26.1",
62+
"stylelint-config-standard": "^39.0.1",
63+
"stylelint-order": "^7.0.0",
6364
"stylus": "^0.62.0",
6465
"stylus-loader": "^8.1.0",
6566
"webpack": "^5.91.0",

0 commit comments

Comments
 (0)