Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: tailwind typescript config #154

Merged
merged 3 commits into from
Sep 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 7 additions & 4 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,13 +1,16 @@
# Mac Files
.DS_Store

# Build files
dist/
build/

# Dependency directories
node_modules/

# Astro Docs
.astro/

# Coverage directory used by tools like istanbul
coverage
*.lcov
*.lcov

# Mac Files
.DS_Store
2 changes: 1 addition & 1 deletion docs/src/layouts/Layout.astro
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import Footer from '../components/Footer.astro';
import GoogleAnalytics from '../components/GoogleAnalytics.astro';
import Navbar from '../components/Navbar.astro';
import '../app.css';
import '../styles/app.css';

import { siteMetadata } from '../constants';

Expand Down
File renamed without changes.
23 changes: 14 additions & 9 deletions docs/tailwind.config.cjs → docs/tailwind.config.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
/**@type {import("tailwindcss").Config} */
module.exports = {
import type { Config } from 'tailwindcss';
import TailwindCSSAnimate from 'tailwindcss-animate';
import TailwindCSSTypography from '@tailwindcss/typography';

const config: Config = {
darkMode: ['class', '[data-kb-theme="dark"]'],
content: ['./src/**/*.{astro,ts,tsx}'],
theme: {
Expand All @@ -11,20 +14,20 @@ module.exports = {
},
keyframes: {
'accordion-down': {
from: { height: 0 },
from: { height: '0' },
to: { height: 'var(--kb-accordion-content-height)' },
},
'accordion-up': {
from: { height: 'var(--kb-accordion-content-height)' },
to: { height: 0 },
to: { height: '0' },
},
'content-show': {
from: { opacity: 0, transform: 'scale(0.96)' },
to: { opacity: 1, transform: 'scale(1)' },
from: { opacity: '0', transform: 'scale(0.96)' },
to: { opacity: '1', transform: 'scale(1)' },
},
'content-hide': {
from: { opacity: 1, transform: 'scale(1)' },
to: { opacity: 0, transform: 'scale(0.96)' },
from: { opacity: '1', transform: 'scale(1)' },
to: { opacity: '0', transform: 'scale(0.96)' },
},
},
animation: {
Expand All @@ -35,5 +38,7 @@ module.exports = {
},
},
},
plugins: [require('tailwindcss-animate'), require('@tailwindcss/typography')],
plugins: [TailwindCSSAnimate, TailwindCSSTypography],
};

export default config;
4 changes: 2 additions & 2 deletions docs/ui.config.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
"tsx": true,
"componentDir": "./src/components/ui",
"tailwind": {
"config": "tailwind.config.cjs",
"css": "src/app.css"
"config": "tailwind.config.ts",
"css": "src/styles/app.css"
},
"aliases": {
"path": "~/*"
Expand Down