forked from zaydek/todo-app-mvp
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtailwind.config.js
93 lines (87 loc) · 2.54 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
// const plugin = require("tailwindcss/plugin")
const defaultTheme = require("tailwindcss/defaultTheme")
const defaultVariants = require("./tailwind-defaultVariants")
function trimWhitespace(str) {
return str.split(/\s+/).join(" ").trim()
}
module.exports = {
purge: [
"./public/**/*.html",
"./src/**/*.js",
],
theme: {
extend: {
// borderRadius: {
// "75": "0.75rem",
// },
boxShadow: {
"hero-sm": trimWhitespace(`
${defaultTheme.boxShadow.xs},
${defaultTheme.boxShadow.sm}
`),
"hero": trimWhitespace(`
${defaultTheme.boxShadow.xs},
${defaultTheme.boxShadow.default}
`),
"hero-md": trimWhitespace(`
${defaultTheme.boxShadow.xs},
${defaultTheme.boxShadow.md}
`),
"hero-lg": trimWhitespace(`
${defaultTheme.boxShadow.xs},
${defaultTheme.boxShadow.lg}
`),
"hero-xl": trimWhitespace(`
${defaultTheme.boxShadow.xs},
${defaultTheme.boxShadow.xl}
`),
"hero-2xl": trimWhitespace(`
${defaultTheme.boxShadow.xs},
${defaultTheme.boxShadow["2xl"]}
`),
},
fontFamily: {
/* eslint-disable quotes */
mono: ['"Fira Code"', ...defaultTheme.fontFamily.mono],
sans: [...defaultTheme.fontFamily.sans.slice(0, 3), "Inter", ...defaultTheme.fontFamily.sans.slice(3)],
/* eslint-enable quotes */
},
},
screens: {
sm: (24 + +defaultTheme.screens.sm.slice(0, -2) + 24) + "px",
// => @media (min-width: 640px) { ... }
md: (24 + +defaultTheme.screens.md.slice(0, -2) + 24) + "px",
// => @media (min-width: 768px) { ... }
lg: (24 + +defaultTheme.screens.lg.slice(0, -2) + 24) + "px",
// => @media (min-width: 1024px) { ... }
xl: (24 + +defaultTheme.screens.xl.slice(0, -2) + 24) + "px",
// => @media (min-width: 1280px) { ... }
},
},
variants: {
...defaultVariants,
typography: [],
},
plugins: [
require("@tailwindcss/ui"),
// plugin(((flag = "dark-mode", prefix = "dark") => {
// return ({ addVariant, e }) => {
// addVariant(prefix, ({ modifySelectors }) => {
// modifySelectors(({ className }) => {
// return `.${flag} .${e(`${prefix}:${className}`)}`
// })
// })
// addVariant(`hover:${prefix}`, ({ modifySelectors }) => {
// modifySelectors(({ className }) => {
// return `.${flag} .${e(`hover:${prefix}:${className}`)}:hover`
// })
// })
// addVariant(`focus:${prefix}`, ({ modifySelectors }) => {
// modifySelectors(({ className }) => {
// return `.${flag} .${e(`focus:${prefix}:${className}`)}:focus`
// })
// })
// }
// })()),
],
}