@itcase/config 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md ADDED
@@ -0,0 +1 @@
1
+ # ITCase Config
package/babel/index.js ADDED
@@ -0,0 +1,9 @@
1
+ export default {
2
+ presets: ['next/babel', '@babel/preset-typescript'],
3
+ plugins: [
4
+ [
5
+ '@babel/plugin-proposal-decorators',
6
+ { decoratorsBeforeExport: true, decoratorAutoAccessors: true },
7
+ ],
8
+ ],
9
+ }
@@ -0,0 +1,4 @@
1
+ export default {
2
+ '*.(js|jsx|ts|tsx)': ['npx eslint --fix'],
3
+ '*.css': ['npx stylelint --fix'],
4
+ }
package/package.json ADDED
@@ -0,0 +1,81 @@
1
+ {
2
+ "name": "@itcase/config",
3
+ "version": "1.0.0",
4
+ "author": "ITCase",
5
+ "description": "Config",
6
+ "engines": {
7
+ "node": ">=20.12.0"
8
+ },
9
+ "scripts": {
10
+ "prepare": "husky",
11
+ "semantic-release": "semantic-release"
12
+ },
13
+ "type": "module",
14
+ "license": "MIT",
15
+ "private": false,
16
+ "repository": {
17
+ "type": "git",
18
+ "url": "https://github.com/ITCase/itcase-config.git"
19
+ },
20
+ "files": [
21
+ "babel",
22
+ "lint-staged",
23
+ "postcss",
24
+ "svgr",
25
+ "README.md"
26
+ ],
27
+ "publishConfig": {
28
+ "access": "public",
29
+ "registry": "https://registry.npmjs.org/"
30
+ },
31
+ "dependencies": {
32
+ "@babel/eslint-parser": "^7.26.5",
33
+ "@babel/plugin-proposal-decorators": "^7.25.9",
34
+ "@babel/preset-typescript": "^7.26.0",
35
+ "@lehoczky/postcss-fluid": "^1.0.3",
36
+ "@svgr/webpack": "^8.1.0",
37
+ "autoprefixer": "^10.4.20",
38
+ "cssnano": "^7.0.6",
39
+ "cssnano-preset-default": "^7.0.6",
40
+ "eslint": "^9.19.0",
41
+ "postcss-aspect-ratio-polyfill": "^2.0.0",
42
+ "postcss-clamp": "^4.1.0",
43
+ "postcss-cli": "^11.0.0",
44
+ "postcss-combine-duplicated-selectors": "^10.0.3",
45
+ "postcss-dark-theme-class": "^1.3.0",
46
+ "postcss-discard-duplicates": "^7.0.1",
47
+ "postcss-each": "^1.1.0",
48
+ "postcss-easings": "^4.0.0",
49
+ "postcss-extend-rule": "^4.0.0",
50
+ "postcss-flexbugs-fixes": "^5.0.2",
51
+ "postcss-hexrgba": "^2.1.0",
52
+ "postcss-import": "^16.1.0",
53
+ "postcss-import-ext-glob": "^2.1.1",
54
+ "postcss-loader": "^8.1.1",
55
+ "postcss-mixins": "^11.0.3",
56
+ "postcss-nested": "^7.0.2",
57
+ "postcss-nested-ancestors": "^3.0.0",
58
+ "postcss-normalize": "^13.0.1",
59
+ "postcss-prepend-imports": "^1.0.1",
60
+ "postcss-preset-env": "^10.1.3",
61
+ "postcss-pxtorem": "^6.1.0",
62
+ "postcss-sort-media-queries": "^5.2.0",
63
+ "postcss-url": "^10.1.3",
64
+ "prettier": "^3.4.2",
65
+ "stylelint": "^16.14.1",
66
+ "typescript-eslint": "^8.22.0"
67
+ },
68
+ "devDependencies": {
69
+ "@commitlint/cli": "^19.6.1",
70
+ "@commitlint/config-conventional": "^19.6.0",
71
+ "@itcase/lint": "^1.0.36",
72
+ "@semantic-release/changelog": "^6.0.3",
73
+ "@semantic-release/git": "^10.0.1",
74
+ "@semantic-release/release-notes-generator": "14.0.3",
75
+ "conventional-changelog-conventionalcommits": "^8.0.0",
76
+ "husky": "^9.1.7",
77
+ "lint-staged": "^15.4.3",
78
+ "semantic-release": "^24.2.1",
79
+ "typescript": "^5.7.3"
80
+ }
81
+ }
@@ -0,0 +1,78 @@
1
+ const cssnano = [
2
+ 'cssnano',
3
+ {
4
+ preset: 'cssnano-preset-default',
5
+ },
6
+ ]
7
+
8
+ export default {
9
+ plugins: [
10
+ 'postcss-normalize',
11
+ [
12
+ 'postcss-prepend-imports',
13
+ {
14
+ files: ['import.css'],
15
+ path: 'src/styles/',
16
+ },
17
+ ],
18
+ 'postcss-import-ext-glob',
19
+ [
20
+ 'postcss-import',
21
+ {
22
+ addModulesDirectories: ['node_modules'],
23
+ },
24
+ ],
25
+ 'postcss-each',
26
+ 'postcss-mixins',
27
+ 'postcss-flexbugs-fixes',
28
+ [
29
+ 'postcss-preset-env',
30
+ {
31
+ features: {
32
+ 'custom-properties': {
33
+ preserve: false,
34
+ },
35
+ 'nesting-rules': false,
36
+ },
37
+ stage: 2,
38
+ },
39
+ ],
40
+ [
41
+ 'postcss-url',
42
+ {
43
+ maxSize: 256,
44
+ url: 'inline',
45
+ },
46
+ ],
47
+ 'postcss-nested-ancestors',
48
+ 'postcss-nested',
49
+ 'postcss-hexrgba',
50
+ 'postcss-easings',
51
+ [
52
+ 'postcss-dark-theme-class',
53
+ {
54
+ darkSelector: '.dark-theme',
55
+ lightSelector: '.light-theme',
56
+ },
57
+ ],
58
+ 'postcss-combine-duplicated-selectors',
59
+ 'postcss-discard-duplicates',
60
+
61
+ [
62
+ 'postcss-pxtorem',
63
+ {
64
+ minPixelValue: 0,
65
+ propList: ['font', 'font-size', 'line-height', 'letter-spacing'],
66
+ rootValue: 16,
67
+ },
68
+ ],
69
+ [
70
+ 'postcss-sort-media-queries',
71
+ {
72
+ sort: 'mobile-first',
73
+ },
74
+ ],
75
+ '@lehoczky/postcss-fluid',
76
+ ...(process.env.NODE_ENV === 'development' ? [cssnano] : []),
77
+ ],
78
+ }
package/svgr/index.js ADDED
@@ -0,0 +1,19 @@
1
+ export default {
2
+ svgoConfig: {
3
+ plugins: [
4
+ {
5
+ name: 'preset-default',
6
+ },
7
+ {
8
+ name: 'removeAttrs',
9
+ params: { attrs: '(fill|stroke|stroke-width)' },
10
+ },
11
+ {
12
+ name: 'addAttributesToSVGElement',
13
+ params: {
14
+ attributes: [{ fill: 'none' }, { stroke: 'none' }],
15
+ },
16
+ },
17
+ ],
18
+ },
19
+ }