-
Notifications
You must be signed in to change notification settings - Fork 0
/
tailwind.config.js
101 lines (100 loc) · 2.83 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
const defaultTheme = require('tailwindcss/defaultTheme');
const colors = require('tailwindcss/colors');
/** @type {import('tailwindcss').Config} */
module.exports = {
content: ['./src/**/*.{js,ts,jsx,tsx}'],
darkMode: 'class',
theme: {
extend: {
keyframes: {
cursorBlink: {
'0%': { opacity: 0 },
},
},
fontFamily: {
sans: ['var(--font-sans)', ...defaultTheme.fontFamily.sans],
},
colors: {
primary: colors.pink,
secondary: colors.indigo,
gray: colors.slate,
},
typography: theme => ({
DEFAULT: {
css: {
strong: {
color: 'inherit',
},
'h1, h2, h3, h4, h5, h6': {
// so heading links aren't obscured by the sticky page header
scrollMarginTop: '112px',
// show the heading auto links
'&:hover': {
a: {
opacity: 1,
},
},
},
'p, li': {
color: theme('colors.gray.500'),
},
a: {
fontWeight: 500,
textDecoration: 'none',
'&:hover': {
textDecoration: 'underline',
},
},
blockquote: {
fontWeight: 400,
fontStyle: 'normal',
padding: '1.25rem',
p: {
color: 'inherit',
margin: 0,
},
color: theme('colors.secondary.600'),
backgroundColor: theme('colors.secondary.50'),
borderLeftColor: theme('colors.secondary.500'),
},
code: {
color: theme('colors.secondary.600'),
backgroundColor: theme('colors.secondary.50'),
padding: '4px 6px',
borderRadius: '0.25rem',
},
// Remove backticks from showing
'code::before': {
content: 'none',
},
// Remove backticks from showing
'code::after': {
content: 'none',
},
},
},
dark: {
css: {
'p, li': {
color: theme('colors.gray.400'),
},
blockquote: {
padding: '1.25rem',
color: theme('colors.white'),
backgroundColor: theme('colors.gray.800'),
borderLeftColor: theme('colors.secondary.700'),
code: {
backgroundColor: theme('colors.secondary.700'),
},
},
code: {
color: theme('colors.white'),
backgroundColor: theme('colors.gray.800'),
},
},
},
}),
},
},
plugins: [require('@tailwindcss/typography')],
};