-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathtailwind.config.js
More file actions
105 lines (101 loc) · 3.09 KB
/
Copy pathtailwind.config.js
File metadata and controls
105 lines (101 loc) · 3.09 KB
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
/** @type {import('tailwindcss').Config} */
export default {
content: [
"./index.html",
"./src/**/*.{js,ts,jsx,tsx}",
],
theme: {
extend: {
fontFamily: {
// 标题字体:Inter - 现代几何风格
display: ['Inter', '-apple-system', 'BlinkMacSystemFont', 'sans-serif'],
// 正文字体:IBM Plex Sans - 专业、易读
body: ['IBM Plex Sans', '-apple-system', 'BlinkMacSystemFont', 'sans-serif'],
// 中文专用字体
chinese: ['PingFang SC', 'Noto Sans SC', 'Microsoft YaHei', 'sans-serif'],
// 等宽字体:JetBrains Mono - 现代编程字体
mono: ['JetBrains Mono', 'SF Mono', 'Monaco', 'Consolas', 'monospace'],
// 保留 sans 作为默认字体
sans: [
'-apple-system',
'BlinkMacSystemFont',
'Segoe UI',
'Roboto',
'Helvetica Neue',
'Arial',
'PingFang SC',
'Microsoft YaHei',
'sans-serif',
],
},
fontSize: {
'xs': ['0.75rem', { lineHeight: '1rem', letterSpacing: '0.01em' }],
'sm': ['0.875rem', { lineHeight: '1.375rem', letterSpacing: '0.005em' }],
'base': ['1rem', { lineHeight: '1.5rem', letterSpacing: '0' }],
'lg': ['1.125rem', { lineHeight: '1.75rem', letterSpacing: '-0.005em' }],
'xl': ['1.25rem', { lineHeight: '1.75rem', letterSpacing: '-0.01em' }],
'2xl': ['1.5rem', { lineHeight: '2rem', letterSpacing: '-0.015em' }],
},
colors: {
primary: {
DEFAULT: '#3B82F6',
50: '#EFF6FF',
100: '#DBEAFE',
200: '#BFDBFE',
300: '#93C5FD',
400: '#60A5FA',
500: '#3B82F6',
600: '#2563EB',
700: '#1D4ED8',
800: '#1E40AF',
900: '#1E3A8A',
},
slate: {
50: '#F8FAFC',
100: '#F1F5F9',
200: '#E2E8F0',
300: '#CBD5E1',
400: '#94A3B8',
500: '#64748B',
600: '#475569',
700: '#334155',
800: '#1E293B',
900: '#0F172A',
},
},
borderRadius: {
DEFAULT: '8px',
'xl': '12px',
},
boxShadow: {
'card': '0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1)',
'card-hover': '0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1)',
'modal': '0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1)',
},
},
},
plugins: [
function({ addUtilities }) {
addUtilities({
'.line-clamp-1': {
overflow: 'hidden',
display: '-webkit-box',
'-webkit-box-orient': 'vertical',
'-webkit-line-clamp': '1',
},
'.line-clamp-2': {
overflow: 'hidden',
display: '-webkit-box',
'-webkit-box-orient': 'vertical',
'-webkit-line-clamp': '2',
},
'.line-clamp-3': {
overflow: 'hidden',
display: '-webkit-box',
'-webkit-box-orient': 'vertical',
'-webkit-line-clamp': '3',
},
});
},
],
}