-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtailwind.config.js
180 lines (171 loc) · 3.53 KB
/
tailwind.config.js
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
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
const docmakerPlugin = require('./src/theme/plugins/docmaker')
const colors = require('./src/theme/data/colors')
const { getDynamicColors } = require('./src/theme/plugins/color-variants')
const borderRadius = {
none: '0',
sm: '3px',
default: '5px',
lg: '10px',
xlg: '20px',
full: '9999em'
}
const boxShadow = {
none: 'none',
inset: 'inset 0 0 0 1px rgba(103, 126, 138, 0.25)',
link: 'inset 0 -4px 0 rgba(103, 126, 138, 0.25)',
outline: '0 0 0 4px rgba(103, 126, 138, 0.125)',
1: '0 0 1px rgba(7, 11, 15, 0.05), 0 1px 2px rgba(7, 11, 15, 0.075)'
}
boxShadow[2] = `${boxShadow[1]}, 0 2px 8px rgba(7, 11, 15, 0.1)`
boxShadow[3] = `${boxShadow[2]}, 0 4px 16px rgba(7, 11, 15, 0.125)`
boxShadow[4] = `${boxShadow[3]}, 0 8px 32px rgba(7, 11, 15, 0.1375)`
boxShadow[5] = `${boxShadow[4]}, 0 16px 64px rgba(7, 11, 15, 0.25)`
boxShadow[6] = `0 2.8px 2.2px rgba(0, 0, 0, 0.02),
0 6.7px 5.3px rgba(0, 0, 0, 0.028), 0 12.5px 10px rgba(0, 0, 0, 0.035),
0 22.3px 17.9px rgba(0, 0, 0, 0.042), 0 41.8px 33.4px rgba(0, 0, 0, 0.05),
0 100px 80px rgba(0, 0, 0, 0.07)`
const fontFamily = {
sans: [
'system-ui',
'-apple-system',
'BlinkMacSystemFont',
'"Segoe UI"',
'Roboto',
'"Helvetica Neue"',
'Arial',
'"Noto Sans"',
'sans-serif'
],
mono: [
'Consolas',
'Liberation Mono',
'Menlo',
'Courier',
'Monaco',
'monospace'
]
}
const opacity = {
0: '0',
10: '0.1',
25: '0.25',
33: '0.33',
50: '0.5',
66: '0.66',
75: '0.75',
99: '0.99',
100: '1'
}
const spacing = {
px: '1px',
0: '0',
1: '1px',
2: '2px',
4: '4px',
6: '6px',
8: '8px',
10: '10px',
12: '12px',
16: '16px',
18: '18px',
20: '20px',
24: '24px',
28: '28px',
32: '32px',
36: '36px',
40: '40px',
48: '48px',
56: '56px',
60: '60px',
64: '64px',
80: '80px',
120: '120px',
144: '144px',
150: '150px',
160: '160px',
180: '180px',
200: '200px',
240: '240px',
272: '272px',
296: '296px',
320: '320px',
360: '360px',
380: '380px',
480: '480px',
600: '600px',
640: '640px'
}
const timing = {
75: '75ms',
125: '125ms',
250: '250ms',
500: '500ms',
750: '750ms',
1000: '1000ms'
}
module.exports = {
future: {
removeDeprecatedGapUtilities: true,
purgeLayersByDefault: true
},
purge: {
content: [
'./src/**/*.html',
'./src/**/*.js',
'./src/**/*.jsx',
'./src/**/*.ts',
'./src/**/*.tsx',
'./public/index.html'
]
},
corePlugins: {
fontSize: false,
lineHeight: false,
letterSpacing: false
},
plugins: [docmakerPlugin],
variants: {
// ...colorVariants,
textColor: ({ after }) => after(['focus-within']),
borderColor: ({ after }) => after(['focus-within'])
},
theme: {
borderRadius,
boxShadow,
colors: {
...colors,
...getDynamicColors()
},
fontFamily,
opacity,
spacing,
transitionDelay: timing,
transitionDuration: timing,
zIndex: {
beneath: -10,
0: 0,
1: 10,
2: 20,
3: 30,
4: 40,
5: 50
},
transitionTimingFunction: {
default: 'ease',
linear: 'linear',
in: 'cubic-bezier(0.4, 0, 1, 1)',
out: 'cubic-bezier(0, 0, 0.2, 1)',
'in-out': 'cubic-bezier(0.4, 0, 0.2, 1)'
},
extend: {
screens: {
sm: '480px',
print: { raw: 'print' },
retina: {
raw:
'only screen and (min-device-pixel-ratio: 2), only screen and (min-resolution: 192dpi), only screen and (min-resolution: 2dppx)'
}
}
}
}
}