forked from withastro/astro.build
-
Notifications
You must be signed in to change notification settings - Fork 0
/
tailwind.config.cjs
62 lines (60 loc) · 2.13 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
const plugin = require('tailwindcss/plugin')
const colors = require('tailwindcss/colors')
/** @type {import('tailwindcss').Config} */
module.exports = {
content: ['./src/**/*.{astro,html,js,jsx,md,svelte,ts,tsx,vue}'],
theme: {
extend: {
colors: {
neutral: colors.slate,
primary: colors.purple,
secondary: colors.orange,
accent: colors.fuchsia
},
screens: {
xs: '420px'
},
typography: (theme) => ({
DEFAULT: {
css: {
'blockquote p:first-of-type::before': {
content: 'none'
},
'blockquote p:first-of-type::after': {
content: 'none'
},
'code::before': { content: 'none' },
'code::after': { content: 'none' },
code: {
fontWeight: theme('fontWeight.normal'),
backgroundColor: theme('colors.violet.100'),
paddingBlock: theme('spacing')[1],
paddingInline: theme('spacing')[1.5],
borderRadius: theme('borderRadius.DEFAULT')
}
}
}
}),
keyframes: {
'fade-in': {
from: { opacity: 0 },
to: { opacity: 1 }
}
},
animation: {
'fade-in': 'fade-in 0.5s ease-in-out'
}
}
},
plugins: [
require('@tailwindcss/typography'),
require('@tailwindcss/aspect-ratio'),
require('@tailwindcss/line-clamp'),
require('@tailwindcss/container-queries'),
plugin(function childrenPlugin({ addVariant }) {
// apply a style to all direct children
// example usage: "children:border-l children:border-blue-500"
addVariant('children', '& > *')
})
]
}