Skip to content

Commit 57c76ee

Browse files
Fix Tailwind CSS production build issues
- Replace old CSS with proper Tailwind directives - Import styles.css in Layout.astro to ensure Tailwind base styles load - Fix missing CSS in production builds while maintaining dev functionality 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <[email protected]>
1 parent 3d469d8 commit 57c76ee

File tree

2 files changed

+4
-108
lines changed

2 files changed

+4
-108
lines changed

src/layouts/Layout.astro

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
---
22
import CategoryLinks from '../components/CategoryLinks.astro';
3+
import '../styles.css';
34
45
export interface Props {
56
title: string;

src/styles.css

Lines changed: 3 additions & 108 deletions
Original file line numberDiff line numberDiff line change
@@ -1,108 +1,3 @@
1-
body {
2-
padding: 10px 20px;
3-
max-width: 960px;
4-
width: 100%;
5-
margin: 100px auto 500px;
6-
background: #0080a7;
7-
color: #fff;
8-
}
9-
10-
.nowrap {
11-
white-space: nowrap;
12-
}
13-
14-
@media screen and (prefers-reduced-motion: no-preference) {
15-
body {
16-
scroll-behavior: smooth;
17-
}
18-
}
19-
20-
svg {
21-
max-height: 150px;
22-
max-width: 90%;
23-
margin: 0 auto;
24-
fill: #fff;
25-
}
26-
27-
nav svg {
28-
max-height: 40px;
29-
max-width: 40px;
30-
fill: #0080a7;
31-
}
32-
33-
nav,
34-
nav a {
35-
color: #0080a7;
36-
}
37-
38-
.menu select {
39-
width: auto;
40-
}
41-
42-
hr {
43-
margin-top: 48px;
44-
border-top: 0;
45-
border-bottom: 1px solid #fff;
46-
}
47-
48-
section,
49-
.meta,
50-
footer {
51-
padding-top: 80px;
52-
}
53-
54-
.card {
55-
height: 100%;
56-
color: #333;
57-
}
58-
59-
button,
60-
.button {
61-
background-color: #0080a7;
62-
}
63-
64-
nav,
65-
nav a,
66-
.card a {
67-
color: #0080a7;
68-
}
69-
70-
nav a:hover,
71-
.card a:hover {
72-
color: #d42600;
73-
}
74-
75-
nav a.button:hover {
76-
color: #fff;
77-
}
78-
79-
.meta a,
80-
footer a {
81-
color: #fff;
82-
text-decoration: underline;
83-
}
84-
85-
.meta a.button,
86-
.category-links a.button {
87-
background-color: #fff;
88-
color: #0080a7;
89-
text-decoration: none;
90-
}
91-
92-
.meta a.button:hover,
93-
.pseudo.button:hover,
94-
.category-links a.button:hover {
95-
background-color: #37b4da;
96-
color: #fff;
97-
text-decoration: none;
98-
}
99-
100-
.category-links a {
101-
margin: 5px;
102-
}
103-
104-
@media only screen and (max-device-width: 600px) {
105-
nav span {
106-
display: none;
107-
}
108-
}
1+
@tailwind base;
2+
@tailwind components;
3+
@tailwind utilities;

0 commit comments

Comments
 (0)