-
Notifications
You must be signed in to change notification settings - Fork 3
/
tailwind.config.js
39 lines (35 loc) · 1.17 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
const defaultTheme = require('tailwindcss/defaultTheme');
const withOpacity =
(variable) =>
({ opacityValue }) =>
opacityValue === undefined
? `rgb(var(${variable}))`
: `rgb(var(${variable}) / ${opacityValue})`;
const getColorShades = (shades, name = 'primary') =>
shades.reduce(
(a, v) => ({ ...a, [v]: withOpacity(`--tw-clr-${name}-${v}`) }),
{}
);
module.exports = {
content: [
'./vendor/laravel/framework/src/Illuminate/Pagination/resources/views/*.blade.php',
'./storage/framework/views/*.php',
'./resources/views/**/*.blade.php',
'./resources/js/**/*.js',
],
darkMode: 'class', // or 'media' or 'class'
theme: {
extend: {
fontFamily: {
sans: ['Nunito', ...defaultTheme.fontFamily.sans],
primary: ['Roboto', ...defaultTheme.fontFamily.sans],
},
colors: {
// Customize it on globals.css :root
primary: getColorShades([50, 100, 200, 300, 400, 500, 600, 700]),
dark: '#222222',
},
},
},
plugins: [require('@tailwindcss/forms')],
};