Skip to content

Commit bc3646f

Browse files
committed
style: change post styles
1 parent 680e5e0 commit bc3646f

File tree

8 files changed

+1041
-750
lines changed

8 files changed

+1041
-750
lines changed

astro.config.mjs

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,15 @@ export default defineConfig({
1313

1414
markdown: {
1515
shikiConfig: {
16-
theme: "catppuccin-mocha",
16+
themes: {
17+
light: "catppuccin-latte",
18+
dark: "catppuccin-mocha",
19+
},
1720
wrap: true,
1821
},
1922
},
2023

2124
vite: {
2225
plugins: [tailwindcss()],
2326
},
24-
});
27+
});

package-lock.json

Lines changed: 16 additions & 16 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/layouts/Post.astro

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -14,24 +14,19 @@ const { title, description, pubDate, updatedDate } = Astro.props;
1414
<div class="title">
1515
<h1>{title}</h1>
1616
<div class="date">
17+
<em>
1718
Published on <FormattedDate date={pubDate} />
1819
{
1920
updatedDate && (
2021
<div class="last-updated-on">
2122
Last updated on <FormattedDate date={updatedDate} />
2223
</div>
2324
)
24-
}
25+
}</em>
2526
</div>
2627
<hr />
2728
</div>
2829
<slot />
2930
</div>
3031
</article>
3132
</Base>
32-
33-
<style>
34-
.date {
35-
font-style: italic;
36-
}
37-
</style>

src/styles/colors.css

Lines changed: 115 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,115 @@
1+
/* ============================================================================ */
2+
/* CATPPUCCIN COLORS */
3+
/* CATPPUCCIN LATTE - LIGHT MODE */
4+
/* CATPPUCCIN MOCHA - DARK MODE */
5+
/* ============================================================================ */
6+
7+
/* ---------------- Color Variables ---------------- */
8+
:root {
9+
/* Light Mode (Latte) */
10+
--rosewater: #dc8a78;
11+
--flamingo: #dd7878;
12+
--pink: #ea76cb;
13+
--mauve: #8839ef;
14+
--red: #d20f39;
15+
--maroon: #e64553;
16+
--peach: #fe640b;
17+
--yellow: #df8e1d;
18+
--green: #40a02b;
19+
--teal: #179299;
20+
--sky: #04a5e5;
21+
--sapphire: #209fb5;
22+
--blue: #1e66f5;
23+
--lavender: #7287fd;
24+
25+
--text: #4c4f69;
26+
--subtext1: #5c5f77;
27+
--subtext0: #6c6f85;
28+
--overlay2: #7c7f93;
29+
--overlay1: #8c8fa1;
30+
--overlay0: #9ca0b0;
31+
--surface2: #acb0be;
32+
--surface1: #bcc0cc;
33+
--surface0: #ccd0da;
34+
--base: #eff1f5;
35+
--mantle: #e6e9ef;
36+
--crust: #dce0e8;
37+
38+
/* Semantic Variables */
39+
--bg: var(--base);
40+
--mantle-bg: var(--mantle);
41+
--crust-bg: var(--crust);
42+
--surface0-bg: var(--surface0);
43+
--surface1-bg: var(--surface1);
44+
--surface2-bg: var(--surface2);
45+
--overlay0-color: var(--overlay0);
46+
--overlay1-color: var(--overlay1);
47+
--overlay2-color: var(--overlay2);
48+
49+
--text-primary: var(--text);
50+
--text-secondary: var(--subtext0);
51+
--text-tertiary: var(--subtext1);
52+
53+
--accent: var(--blue);
54+
--highlight: var(--peach);
55+
--success: var(--green);
56+
--error: var(--red);
57+
--warning: var(--yellow);
58+
--info: var(--sky);
59+
--muted: var(--overlay1);
60+
}
61+
62+
/* Dark Mode (Mocha) */
63+
@media (prefers-color-scheme: dark) {
64+
:root {
65+
--rosewater: #f5e0dc;
66+
--flamingo: #f2cdcd;
67+
--pink: #f5c2e7;
68+
--mauve: #cba6f7;
69+
--red: #f38ba8;
70+
--maroon: #eba0ac;
71+
--peach: #fab387;
72+
--yellow: #f9e2af;
73+
--green: #a6e3a1;
74+
--teal: #94e2d5;
75+
--sky: #89dceb;
76+
--sapphire: #74c7ec;
77+
--blue: #89b4fa;
78+
--lavender: #b4befe;
79+
80+
--text: #cdd6f4;
81+
--subtext1: #bac2de;
82+
--subtext0: #a6adc8;
83+
--overlay2: #9399b2;
84+
--overlay1: #7f849c;
85+
--overlay0: #6c7086;
86+
--surface2: #585b70;
87+
--surface1: #45475a;
88+
--surface0: #313244;
89+
--base: #1e1e2e;
90+
--mantle: #181825;
91+
--crust: #11111b;
92+
93+
--bg: var(--base);
94+
--mantle-bg: var(--mantle);
95+
--crust-bg: var(--crust);
96+
--surface0-bg: var(--surface0);
97+
--surface1-bg: var(--surface1);
98+
--surface2-bg: var(--surface2);
99+
--overlay0-color: var(--overlay0);
100+
--overlay1-color: var(--overlay1);
101+
--overlay2-color: var(--overlay2);
102+
103+
--text-primary: var(--text);
104+
--text-secondary: var(--subtext0);
105+
--text-tertiary: var(--subtext1);
106+
107+
--accent: var(--blue);
108+
--highlight: var(--peach);
109+
--success: var(--green);
110+
--error: var(--red);
111+
--warning: var(--yellow);
112+
--info: var(--sky);
113+
--muted: var(--overlay1);
114+
}
115+
}

0 commit comments

Comments
 (0)