-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtailwind.config.js
56 lines (55 loc) · 1.69 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
function withOpacityValue(variable) {
return ({ opacityValue }) => {
if (opacityValue === undefined) {
return `rgb(var(${variable}))`
}
return `rgb(var(${variable}) / ${opacityValue})`
}
}
module.exports = {
content: [
"./pages/**/*.{js,ts,jsx,tsx}",
"./components/**/*.{js,ts,jsx,tsx}",
],
theme: {
container: {
center: true,
padding: '2rem'
},
fontFamily: {
'heading': ["var(--font-heading)", 'sans-serif'],
'body': ["var(--font-body)", 'serif']
},
fontSize: {
xs: ["var(--font-xs-size)", "var(--font-xs-height)"],
sm: ["var(--font-sm-size)", "var(--font-sm-height)"],
base: ["var(--font-base-size)", "var(--font-base-height)"],
lg: ["var(--font-lg-size)", "var(--font-lg-height)"],
xl: ["var(--font-xl-size)", "var(--font-xl-height)"],
'2xl': ["var(--font-xxl-size)", "var(--font-xxl-height)"],
'3xl': ["var(--font-xxxl-size)", "var(--font-xxxl-height)"]
},
extend: {
colors: {
base: withOpacityValue('--color-text'),
alt: withOpacityValue('--color-text-alt'),
rev: withOpacityValue('--color-text-rev'),
back: withOpacityValue('--color-back'),
'back-alt': withOpacityValue('--color-back-alt'),
'back-rev': withOpacityValue('--color-back-rev'),
accent: withOpacityValue('--color-accent'),
'accent-rev': withOpacityValue('--color-accent-rev'),
button: withOpacityValue('--color-button'),
'button-back': withOpacityValue('--color-button-back'),
},
letterSpacing: {
widest: '.25em'
},
spacing: {
'128': '32rem',
'160': '40rem',
}
},
},
plugins: [],
}