-
Notifications
You must be signed in to change notification settings - Fork 0
/
tailwind.config.js
68 lines (68 loc) · 1.88 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
function range(start, end, increment = 1) {
const count = Math.floor((end - start + increment) / increment);
return Array(count)
.fill(0)
.map((_, idx) => start + idx * increment);
}
const minFontSize = 5;
const maxFontSize = 80;
const minSpacingPixel = 0;
const maxSpacingPixel = 800;
const spacingPixelIncrement = 5;
const vhs = ['10vh', '20vh', '30vh', '40vh', '50vh', '60vh', '70vh', '80vh', '90vh', '100vh'];
module.exports = {
content: ['./src/**/*.{html,ts}'],
theme: {
// Extend default configurations
extend: {
colors: {
},
container: {
center: true,
},
},
// Override default configurations
fontWeight: {
normal: 400,
medium: 600,
bold: 700,
},
fontSize: {
...range(minFontSize, maxFontSize).reduce((merged, f) => ({ ...merged, [f]: `${f}px` }), {}),
},
spacing: {
...range(minSpacingPixel, maxSpacingPixel, spacingPixelIncrement).reduce(
(merged, f) => ({ ...merged, [f]: `${f}px` }),
{}
),
},
maxWidth: {
...range(minSpacingPixel, maxSpacingPixel, spacingPixelIncrement).reduce(
(merged, f) => ({ ...merged, [f]: `${f}px` }),
{}
),
},
minWidth: {
...range(minSpacingPixel, maxSpacingPixel, spacingPixelIncrement).reduce(
(merged, f) => ({ ...merged, [f]: `${f}px` }),
{}
),
},
maxHeight: {
...range(minSpacingPixel, maxSpacingPixel, spacingPixelIncrement).reduce(
(merged, f) => ({ ...merged, [f]: `${f}px` }),
{}
),
...vhs.reduce((merged, vh) => ({ ...merged, [vh]: vh }), {}),
},
minHeight: {
...range(minSpacingPixel, maxSpacingPixel, spacingPixelIncrement).reduce(
(merged, f) => ({ ...merged, [f]: `${f}px` }),
{}
),
...vhs.reduce((merged, vh) => ({ ...merged, [vh]: vh }), {}),
},
},
plugins: [
],
};