-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtailwind.config.ts
98 lines (96 loc) · 3.02 KB
/
tailwind.config.ts
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
94
95
96
97
98
import { Config } from 'tailwindcss';
import animatePlugin from 'tailwindcss-animate';
const config = {
content: [
'./src/**/*.{html,js,jsx,ts,tsx,mdx}',
'./src/stories/**/*.{js,ts,jsx,tsx,mdx}',
],
prefix: 'sc-',
darkMode: ['class', 'html[class~="dark"]'],
theme: {
container: {
center: true,
padding: '2rem',
},
fontFamily: {
main: ['"Moderat-Light"', 'sans-serif'],
mainMedium: ['"Moderat"', 'sans-serif'],
mono: ['"SF Mono"', 'monospace'],
},
extend: {
height: {
// @ts-ignore Allowing a list for now
screen: ['100vh /* fallback for Opera, IE and etc. */', '100dvh'],
},
colors: {
border: 'hsl(var(--sc-border))',
input: 'hsl(var(--sc-input))',
ring: 'hsl(var(--sc-ring))',
background: 'hsl(var(--sc-background))',
foreground: 'hsl(var(--sc-foreground))',
primary: {
DEFAULT: 'hsl(var(--sc-primary))',
foreground: 'hsl(var(--sc-primary-foreground))',
},
secondary: {
DEFAULT: 'hsl(var(--sc-secondary))',
foreground: 'hsl(var(--sc-secondary-foreground))',
},
destructive: {
DEFAULT: 'hsl(var(--sc-destructive))',
foreground: 'hsl(var(--sc-destructive-foreground))',
},
muted: {
DEFAULT: 'hsl(var(--sc-muted))',
foreground: 'hsl(var(--sc-muted-foreground))',
},
accent: {
DEFAULT: 'hsl(var(--sc-accent))',
foreground: 'hsl(var(--sc-accent-foreground))',
},
popover: {
DEFAULT: 'hsl(var(--sc-popover))',
foreground: 'hsl(var(--sc-popover-foreground))',
},
card: {
DEFAULT: 'hsl(var(--sc-card))',
foreground: 'hsl(var(--sc-card-foreground))',
},
},
borderRadius: {
lg: 'var(--sc-radius)',
md: 'calc(var(--sc-radius) - 2px)',
sm: 'calc(var(--sc-radius) - 4px)',
},
keyframes: {
'hover-move': {
'0%': { transform: 'translateX(0)' },
'50%': { transform: 'translateX(-10px)' },
'100%': { transform: 'translateX(0)' },
},
'spring-back': {
'0%': { transform: 'translateX(0px)' },
'25%': { transform: 'translateX(-2px)' },
'50%': { transform: 'translateX(2px)' },
'100%': { transform: 'translateX(0px)' },
},
'spring-more': {
'0%': { transform: 'translateX(0px)' },
'25%': { transform: 'translateX(-2px)' },
'50%': { transform: 'translateX(7px)' },
'100%': { transform: 'translateX(5px)' },
},
},
animation: {
'hover-move': 'hover-move 0.5s ease-in-out forwards',
'spring-back': 'spring-back 0.5s ease-in-out forwards',
'spring-more': 'spring-more 0.5s ease-in-out forwards',
},
transitionTimingFunction: {
cubic: 'cubic-bezier(0.6, 0.6, 0, 1)',
},
},
},
plugins: [animatePlugin],
} satisfies Config;
export default config;