midou36o.github.io/unocss.config.ts

70 lines
1.3 KiB
TypeScript
Raw Normal View History

2023-01-19 22:35:09 +05:30
import {
defineConfig,
presetIcons,
presetTypography,
transformerVariantGroup,
transformerDirectives,
2023-01-23 08:44:11 +05:30
presetWind,
presetWebFonts
2023-07-25 07:40:31 +05:30
} from 'unocss';
2023-01-19 22:35:09 +05:30
2023-07-25 07:40:31 +05:30
import { extractorSvelte } from 'unocss';
2023-01-19 22:35:09 +05:30
export default defineConfig({
extractors: [extractorSvelte],
presets: [
presetIcons(),
presetTypography({
cssExtend: {
2023-07-25 07:40:31 +05:30
'h1,h2,h3,h4,h5,h6': {
'font-weight': '800'
2023-01-19 22:35:09 +05:30
}
}
}),
presetWind({
dark: 'media'
/* use dark: "class" when adding manual JS*/
2023-01-23 08:44:11 +05:30
}),
presetWebFonts({
provider: 'bunny',
fonts: {
2023-07-24 22:11:54 +05:30
sans: ['Outfit', 'Comic Sans MS'],
2023-07-25 07:40:31 +05:30
mono: ['Fira Code']
}
2023-01-19 22:35:09 +05:30
})
],
theme: {
fontFamily: {
2023-07-25 07:40:31 +05:30
primary: ['var(--font-primary)']
2023-01-19 22:35:09 +05:30
},
margin: {
2023-07-25 07:40:31 +05:30
'0-auto': '0 auto'
2023-01-19 22:35:09 +05:30
},
colors: {
2023-07-25 07:40:31 +05:30
accent: 'var(--accent)',
accentTranslucent: 'var(--accent-translucent)',
primary: 'var(--primary)',
secondary: 'var(--secondary)',
tertiary: 'var(--tertiary)',
text: 'var(--text)',
grey: 'var(--grey)',
alt: 'var(--alt)',
altText: 'var(--alt-text)'
2023-01-19 22:35:09 +05:30
},
breakpoints: {
2023-07-25 07:40:31 +05:30
sm: '640px',
md: '768px',
lg: '1024px',
xl: '1280px',
'2xl': '1536px',
nav: '1030px'
2023-01-19 22:35:09 +05:30
}
},
transformers: [transformerVariantGroup(), transformerDirectives()],
2023-07-25 07:40:31 +05:30
safelist: ['i-ic:outline-dark-mode', 'i-ic:outline-light-mode']
2023-01-19 22:35:09 +05:30
});