-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtailwind.config.cjs
70 lines (69 loc) · 1.51 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
const plugin = require('tailwindcss/plugin');
const flattenColorPalette = require('tailwindcss/lib/util/flattenColorPalette').default;
/** @type {import('tailwindcss').Config} */
module.exports = {
content: ['./src/**/*.{html,js,svelte,ts}'],
theme: {
extend: {
colors: {
neutral: {
50: '#d9d9d9',
100: '#cacaca',
500: '#aaaaaa',
600: '#bbbbbb',
800: '#222222',
900: '#050d18'
}
},
boxShadow: {
1: '0 0 0 1px black',
2: '0 0 0 2px black',
3: '0 0 0 3px black',
4: '0 0 0 4px black'
}
}
},
plugins: [
plugin(({ matchComponents, theme }) => {
matchComponents(
{
lines: (value) => ({
display: 'flex',
alignItems: 'center',
'&:before': {
content: "''",
width: '100%',
height: '0.25rem',
marginRight: '0.25rem',
backgroundColor: value,
borderRadius: '9999px'
},
'&:after': {
content: "''",
width: '100%',
height: '0.25rem',
marginLeft: '0.25rem',
backgroundColor: value,
borderRadius: '9999px'
}
}),
line: (value) => ({
display: 'block',
width: '100%',
minHeight: '0.25rem',
backgroundColor: value,
borderRadius: '9999px'
}),
'line-vertical': (value) => ({
display: 'inline-block',
height: '100%',
minWidth: '0.25rem',
backgroundColor: value,
borderRadius: '9999px'
})
},
{ values: flattenColorPalette(theme('colors')), type: 'color' }
);
})
]
};