mirror of
https://github.com/prdlk/website.git
synced 2026-08-03 01:41:53 +00:00
feat(core): migrate to astro from next.js
This commit is contained in:
+91
-26
@@ -1,28 +1,93 @@
|
||||
import typographyPlugin from '@tailwindcss/typography'
|
||||
import { type Config } from 'tailwindcss'
|
||||
|
||||
import typographyStyles from './typography'
|
||||
import type { Config } from "tailwindcss";
|
||||
|
||||
export default {
|
||||
content: ['./src/**/*.{js,jsx,ts,tsx}'],
|
||||
darkMode: 'class',
|
||||
plugins: [typographyPlugin],
|
||||
theme: {
|
||||
fontSize: {
|
||||
xs: ['0.8125rem', { lineHeight: '1.5rem' }],
|
||||
sm: ['0.875rem', { lineHeight: '1.5rem' }],
|
||||
base: ['1rem', { lineHeight: '1.75rem' }],
|
||||
lg: ['1.125rem', { lineHeight: '1.75rem' }],
|
||||
xl: ['1.25rem', { lineHeight: '2rem' }],
|
||||
'2xl': ['1.5rem', { lineHeight: '2rem' }],
|
||||
'3xl': ['1.875rem', { lineHeight: '2.25rem' }],
|
||||
'4xl': ['2rem', { lineHeight: '2.5rem' }],
|
||||
'5xl': ['3rem', { lineHeight: '3.5rem' }],
|
||||
'6xl': ['3.75rem', { lineHeight: '1' }],
|
||||
'7xl': ['4.5rem', { lineHeight: '1' }],
|
||||
'8xl': ['6rem', { lineHeight: '1' }],
|
||||
'9xl': ['8rem', { lineHeight: '1' }],
|
||||
},
|
||||
typography: typographyStyles,
|
||||
},
|
||||
} satisfies Config
|
||||
plugins: [require("@tailwindcss/typography")],
|
||||
theme: {
|
||||
extend: {
|
||||
typography: () => ({
|
||||
DEFAULT: {
|
||||
css: {
|
||||
a: {
|
||||
textUnderlineOffset: "2px",
|
||||
"&:hover": {
|
||||
"@media (hover: hover)": {
|
||||
textDecorationColor: "var(--color-link)",
|
||||
textDecorationThickness: "2px",
|
||||
},
|
||||
},
|
||||
},
|
||||
blockquote: {
|
||||
borderLeftWidth: "0",
|
||||
},
|
||||
code: {
|
||||
border: "1px dotted #666",
|
||||
borderRadius: "2px",
|
||||
},
|
||||
kbd: {
|
||||
"&:where([data-theme='dark'], [data-theme='dark'] *)": {
|
||||
background: "var(--color-global-text)",
|
||||
},
|
||||
},
|
||||
hr: {
|
||||
borderTopStyle: "dashed",
|
||||
},
|
||||
strong: {
|
||||
fontWeight: "700",
|
||||
},
|
||||
sup: {
|
||||
marginInlineStart: "calc(var(--spacing) * 0.5)",
|
||||
a: {
|
||||
"&:after": {
|
||||
content: "']'",
|
||||
},
|
||||
"&:before": {
|
||||
content: "'['",
|
||||
},
|
||||
"&:hover": {
|
||||
"@media (hover: hover)": {
|
||||
color: "var(--color-link)",
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
/* Table */
|
||||
"tbody tr": {
|
||||
borderBottomWidth: "none",
|
||||
},
|
||||
tfoot: {
|
||||
borderTop: "1px dashed #666",
|
||||
},
|
||||
thead: {
|
||||
borderBottomWidth: "none",
|
||||
},
|
||||
"thead th": {
|
||||
borderBottom: "1px dashed #666",
|
||||
fontWeight: "700",
|
||||
},
|
||||
'th[align="center"], td[align="center"]': {
|
||||
"text-align": "center",
|
||||
},
|
||||
'th[align="right"], td[align="right"]': {
|
||||
"text-align": "right",
|
||||
},
|
||||
'th[align="left"], td[align="left"]': {
|
||||
"text-align": "left",
|
||||
},
|
||||
".expressive-code, .admonition, .github-card": {
|
||||
marginTop: "calc(var(--spacing)*4)",
|
||||
marginBottom: "calc(var(--spacing)*4)",
|
||||
},
|
||||
},
|
||||
},
|
||||
sm: {
|
||||
css: {
|
||||
code: {
|
||||
fontSize: "var(--text-sm)",
|
||||
fontWeight: "400",
|
||||
},
|
||||
},
|
||||
},
|
||||
}),
|
||||
},
|
||||
},
|
||||
} satisfies Config;
|
||||
|
||||
Reference in New Issue
Block a user