-
Notifications
You must be signed in to change notification settings - Fork 92
/
tailwind.config.cjs
76 lines (76 loc) · 2.45 KB
/
tailwind.config.cjs
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
const { fontFamily } = require('tailwindcss/defaultTheme')
const config = require('./tailwind.theme.config.cjs')
/**
* Find the applicable theme color palette, or use the default one
*/
const themeConfig = process.env.THEME_KEY && config[process.env.THEME_KEY] ? config[process.env.THEME_KEY] : config.default
const { colors } = themeConfig
module.exports = {
darkMode: 'class',
content: [
'./public/**/*.html',
'./src/**/*.{astro,js,ts}'
],
safelist: ['dark'],
theme: {
fontFamily: {
sans: ['Fira Code', ...fontFamily.sans],
},
extend: {
colors: {
theme: {
...colors
}
},
typography: (theme) => ({
dark: {
css: {
color: theme("colors.gray.200"),
blockquote: {
color: colors.dark.primary,
borderColor: colors.primary
},
'blockquote > p::before, p::after': {
color: colors.primary,
},
},
},
DEFAULT: {
css: {
a: {
color: colors.dark.primary,
'&:hover': {
color: colors.primary,
},
},
blockquote: {
color: colors.primary,
fontSize: theme("fontSize.2xl"),
borderColor: colors.dark.primary,
},
'blockquote > p::before, p::after': {
color: colors.dark.primary,
},
h1: {
color: colors.dark.secondary,
},
h2: {
color: colors.dark.secondary,
},
h3: {
color: colors.dark.secondary,
},
}
},
}),
},
},
variants: {
extend: { typography: ["dark"] }
},
plugins: [
require('@tailwindcss/typography'),
require('@tailwindcss/forms'),
require('@tailwindcss/aspect-ratio'),
]
};