-
Notifications
You must be signed in to change notification settings - Fork 6
/
tailwind.config.cjs
56 lines (54 loc) · 1.9 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
const { black, transparent, current } = require("tailwindcss/colors");
function withOpacityValue(variable) {
return ({ opacityValue }) => {
if (opacityValue === undefined) {
return `rgb(var(${variable}))`
}
return `rgb(var(${variable}) / ${opacityValue})`
}
}
module.exports = {
content: ['./src/**/*.{html,js,svelte,ts}'],
theme: {
colors: {
variable: withOpacityValue("--color-variable"),
"variable-hex": "var(--color-variable)",
accent: withOpacityValue("--color-accent"),
background: withOpacityValue("--color-background"),
foreground: withOpacityValue("--color-foreground"),
"foreground-grey": {
100: withOpacityValue("--color-foreground-grey"),
900: withOpacityValue("--color-foreground-grey-dark"),
},
"foreground-blue": {
100: withOpacityValue("--color-foreground-blue"),
900: withOpacityValue("--color-foreground-blue-dark"),
},
"text": {
100: withOpacityValue("--color-text-bright"),
200: withOpacityValue("--color-text-lighter"),
300: withOpacityValue("--color-text-light"),
400: withOpacityValue("--color-text"),
},
shadow: withOpacityValue("--color-shadow"),
overlay: withOpacityValue("--color-overlay"),
blue: withOpacityValue("--color-blue"),
red: withOpacityValue("--color-red"),
"blue-dim": withOpacityValue("--color-blue-dim"),
white: withOpacityValue("--color-white"),
black: withOpacityValue("--color-black"),
peach: withOpacityValue("--color-peach"),
orange: withOpacityValue("--color-orange"),
yellow: withOpacityValue("--color-yellow"),
green: withOpacityValue("--color-green"),
purple: withOpacityValue("--color-purple"),
pink: withOpacityValue("--color-pink"),
transparent,
current,
black
}
},
plugins: [
require("@tailwindcss/typography"),
],
}