Skip to content

Commit 5530673

Browse files
committed
Merge branch 'develop' of https://github.com/cukCS/FE into fix/#27/color-chip
2 parents 3efdd6c + 3d2d2bc commit 5530673

File tree

4 files changed

+96
-2
lines changed

4 files changed

+96
-2
lines changed

package.json

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,8 @@
1818
"react": "19.1.0",
1919
"react-dom": "19.1.0",
2020
"react-hook-form": "^7.64.0",
21-
"svgo": "^4.0.0"
21+
"svgo": "^4.0.0",
22+
"tailwind-merge": "^3.3.1"
2223
},
2324
"devDependencies": {
2425
"@eslint/eslintrc": "^3",
@@ -32,6 +33,7 @@
3233
"postcss": "^8.5.6",
3334
"svg-sprite-loader": "^6.0.11",
3435
"tailwindcss": "4.1.14",
35-
"typescript": "^5"
36+
"typescript": "^5",
37+
"class-variance-authority": "^0.7.1"
3638
}
3739
}

pnpm-lock.yaml

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

src/shared/lib/index.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
export * from './utils';

src/shared/lib/utils.ts

Lines changed: 73 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,73 @@
1+
import { type ClassValue, clsx } from 'clsx';
2+
import { extendTailwindMerge } from 'tailwind-merge';
3+
4+
const twMerge = extendTailwindMerge({
5+
extend: {
6+
theme: {
7+
text: [
8+
'text-display-lg',
9+
'text-display-md',
10+
'text-display-sm',
11+
'text-headline-lg',
12+
'text-headline-md',
13+
'text-headline-sm',
14+
'text-title-lg',
15+
'text-title-md',
16+
'text-title-sm',
17+
'text-label-lg',
18+
'text-label-md',
19+
'text-label-sm',
20+
'text-body-lg',
21+
'text-body-md',
22+
'text-body-sm',
23+
'text-display-serif',
24+
'text-headline-lg-serif',
25+
'text-headline-md-serif',
26+
'text-headline-sm-serif',
27+
'text-label-serif',
28+
],
29+
30+
color: [
31+
'mint-50',
32+
'mint-100',
33+
'mint-200',
34+
'mint-300',
35+
'mint-400',
36+
'mint-500',
37+
'mint-600',
38+
'mint-700',
39+
'mint-800',
40+
'mint-900',
41+
'pink-50',
42+
'pink-100',
43+
'pink-200',
44+
'pink-300',
45+
'pink-400',
46+
'pink-500',
47+
'pink-600',
48+
'pink-700',
49+
'pink-800',
50+
'pink-900',
51+
'gray-50',
52+
'gray-100',
53+
'gray-200',
54+
'gray-300',
55+
'gray-400',
56+
'gray-500',
57+
'gray-600',
58+
'gray-700',
59+
'gray-800',
60+
'gray-900',
61+
'blue-400',
62+
'red-300',
63+
'red-400',
64+
'background',
65+
'foreground',
66+
],
67+
},
68+
},
69+
});
70+
71+
export const cn = (...inputs: ClassValue[]) => {
72+
return twMerge(clsx(inputs));
73+
};

0 commit comments

Comments
 (0)