jonbio/tailwind.config.js

72 lines
1.8 KiB
JavaScript
Raw Normal View History

2023-07-07 11:17:22 +08:00
// @ts-check
const { fontFamily } = require('tailwindcss/defaultTheme')
2021-01-09 17:50:45 +08:00
const colors = require('tailwindcss/colors')
2023-07-07 11:17:22 +08:00
/** @type {import("tailwindcss/types").Config } */
2021-01-09 17:50:45 +08:00
module.exports = {
2022-03-03 21:58:13 +08:00
content: [
'./node_modules/pliny/**/*.js',
2023-07-07 11:17:22 +08:00
'./app/**/*.{js,ts,jsx,tsx}',
'./pages/**/*.{js,ts,tsx}',
'./components/**/*.{js,ts,tsx}',
'./layouts/**/*.{js,ts,tsx}',
2022-03-03 21:58:13 +08:00
'./data/**/*.mdx',
],
2021-01-09 17:50:45 +08:00
darkMode: 'class',
theme: {
extend: {
lineHeight: {
11: '2.75rem',
12: '3rem',
13: '3.25rem',
14: '3.5rem',
},
fontFamily: {
sans: ['var(--font-space-grotesk)', ...fontFamily.sans],
2021-01-09 17:50:45 +08:00
},
colors: {
primary: colors.pink,
gray: colors.gray,
2021-01-09 17:50:45 +08:00
},
typography: ({ theme }) => ({
2021-01-09 17:50:45 +08:00
DEFAULT: {
css: {
a: {
color: theme('colors.primary.500'),
2021-01-09 17:50:45 +08:00
'&:hover': {
color: `${theme('colors.primary.600')}`,
2021-01-09 17:50:45 +08:00
},
code: { color: theme('colors.primary.400') },
2021-01-09 17:50:45 +08:00
},
'h1,h2': {
2021-01-09 17:50:45 +08:00
fontWeight: '700',
letterSpacing: theme('letterSpacing.tight'),
},
h3: {
fontWeight: '600',
2021-12-15 18:05:37 +08:00
},
2021-01-09 17:50:45 +08:00
code: {
color: theme('colors.indigo.500'),
2021-01-09 17:50:45 +08:00
},
},
},
invert: {
2021-01-09 17:50:45 +08:00
css: {
a: {
color: theme('colors.primary.500'),
2021-01-09 17:50:45 +08:00
'&:hover': {
color: `${theme('colors.primary.400')}`,
2021-01-09 17:50:45 +08:00
},
code: { color: theme('colors.primary.400') },
2021-01-09 17:50:45 +08:00
},
'h1,h2,h3,h4,h5,h6': {
2021-01-09 17:50:45 +08:00
color: theme('colors.gray.100'),
},
},
},
}),
},
},
plugins: [require('@tailwindcss/forms'), require('@tailwindcss/typography')],
}