Skip to content

Commit fcc8b72

Browse files
authored
Better typescript support added (#398)
1 parent 767f7ce commit fcc8b72

36 files changed

+1011
-230
lines changed

package-lock.json

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

package.json

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@
4242
"storybook": "storybook dev -p 6006",
4343
"build-storybook": "storybook build",
4444
"build-css": "parcel build styles/themes/default.scss --out-dir dist/themes/",
45-
"generate-tokens": "node ./scripts/tokenGen/index.js",
45+
"generate-tokens": "tsx ./scripts/tokenGen/index.js",
4646
"bundle-tokens": "rollup --config rollup-tokens.config.js",
4747
"build-components": "rollup -c --bundleConfigAsCjs --max-old-space-size=8076",
4848
"copy-components": "mkdirp ./dist/components && cp -r ./dist/temp-cleanup/*js ./dist/components && rimraf dist/temp-cleanup",
@@ -84,14 +84,15 @@
8484
"@storybook/testing-library": "0.2.2",
8585
"@testing-library/jest-dom": "6.4.2",
8686
"@testing-library/react": "14.2.1",
87+
"@types/react": "^18.3.1",
8788
"@typescript-eslint/eslint-plugin": "7.0.0",
8889
"@typescript-eslint/parser": "6.21.0",
8990
"autoprefixer": "10.4.15",
9091
"babel-plugin-module-resolver": "5.0.2",
9192
"eslint": "8.56.0",
9293
"eslint-config-google": "0.14.0",
94+
"eslint-config-love": "^62.0.0",
9395
"eslint-config-standard": "17.1.0",
94-
"eslint-config-standard-with-typescript": "43.0.1",
9596
"eslint-plugin-import": "2.29.1",
9697
"eslint-plugin-n": "16.6.2",
9798
"eslint-plugin-promise": "6.4.0",
@@ -107,12 +108,13 @@
107108
"rimraf": "5.0.5",
108109
"rollup": "4.9.4",
109110
"rollup-plugin-banner2": "1.2.2",
111+
"sass": "^1.77.2",
110112
"sass-loader": "14.1.1",
111113
"storybook": "7.4.0",
112114
"tailwindcss": "3.4.1",
113115
"ts-jest": "29.1.1",
114-
"typescript": "5.4.5",
115-
"sass": "^1.77.2"
116+
"tsx": "^4.17.0",
117+
"typescript": "5.4.5"
116118
},
117119
"dependencies": {
118120
"@floating-ui/react": "^0.26.20",

src/colors/amber.js renamed to src/colors/amber.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,6 @@ const amber = {
3131
1000: '#ffe7b3',
3232

3333
},
34-
};
34+
} as const;
3535

3636
export default amber;

src/colors/blue.js renamed to src/colors/blue.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,6 @@ const blue = {
3030
950: '#70b8ff',
3131
1000: '#c2e6ff',
3232
},
33-
};
33+
} as const;
3434

3535
export default blue;

src/colors/bronze.js renamed to src/colors/bronze.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,6 @@ const bronze = {
3030
1000: '#ede0d9',
3131

3232
},
33-
};
33+
} as const;
3434

3535
export default bronze;

src/colors/brown.js renamed to src/colors/brown.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,6 @@ const brown = {
3131
950: '#dbb594',
3232
1000: '#f2e1ca',
3333
},
34-
};
34+
} as const;
3535

3636
export default brown;

src/colors/crimson.js renamed to src/colors/crimson.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,6 @@ const crimson = {
2727
950: 'hsl(341, 100%, 76.0%)',
2828
1000: 'hsl(330, 90.0%, 91.0%)',
2929
},
30-
};
30+
} as const;
3131

3232
export default crimson;

src/colors/cyan.js renamed to src/colors/cyan.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,6 @@ const cyan = {
2828
950: '#4ccce6',
2929
1000: '#b6ecf7',
3030
},
31-
};
31+
} as const;
3232

3333
export default cyan;

src/colors/gold.js renamed to src/colors/gold.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,6 @@ const gold = {
2929
950: '#cbb99f',
3030
1000: '#e8e2d9',
3131
},
32-
};
32+
} as const;
3333

3434
export default gold;

src/colors/grass.js renamed to src/colors/grass.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,6 @@ const grass = {
3131
1000: '#c2f0c2',
3232

3333
},
34-
};
34+
} as const;
3535

3636
export default grass;

0 commit comments

Comments
 (0)