tangled
alpha
login
or
join now
kacaii.dev
/
blog
0
fork
atom
💻 My personal website
blog.kacaii.dev/
blog
gleam
lustre
0
fork
atom
overview
issues
pulls
pipelines
:truck: move some styles to `input.css`
kacaii.dev
1 month ago
02963204
df193cfc
verified
This commit was signed with the committer's
known signature
.
kacaii.dev
SSH Key Fingerprint:
SHA256:n9v7QGNWHCUv1x/483hCtPUvTsVabU5PzC5CSJMUNtI=
1/1
deploy.yml
success
1m 17s
+229
-221
5 changed files
expand all
collapse all
unified
split
priv
dist
styles.css
input.css
src
blog
page
posts.gleam
recent_posts.gleam
blog.gleam
-209
priv/dist/styles.css
···
24
24
font-style: italic;
25
25
font-weight: bold;
26
26
}
27
27
-
28
28
-
:root {
29
29
-
--hover-glow: 120%;
30
30
-
--default-padding: 0.8rem;
31
31
-
--margin-top: 1rem;
32
32
-
--border-radius: 0.5rem;
33
33
-
34
34
-
/* Catpuccin */
35
35
-
--mocha-base: #1e1e2e;
36
36
-
--mocha-text: #cdd6f4;
37
37
-
--mocha-pink: #f5c2e7;
38
38
-
--mocha-mauve: #cba6f7;
39
39
-
--mocha-red: #f38ba8;
40
40
-
--mocha-maroon: #eba0ac;
41
41
-
--mocha-peach: #fab387;
42
42
-
--mocha-yellow: #f9e2af;
43
43
-
--mocha-green: #a6e3a1;
44
44
-
--mocha-teal: #94e2d5;
45
45
-
--mocha-sky: #89dceb;
46
46
-
--mocha-sapphire: #74c7ec;
47
47
-
--mocha-blue: #89b4fa;
48
48
-
--mocha-lavender: #b4befe;
49
49
-
--mocha-text: #cdd6f4;
50
50
-
--mocha-subtext1: #bac2de;
51
51
-
--mocha-subtext0: #a6adc8;
52
52
-
--mocha-overlay2: #9399b2;
53
53
-
--mocha-overlay1: #7f849c;
54
54
-
--mocha-overlay0: #6c7086;
55
55
-
--mocha-surface2: #585b70;
56
56
-
--mocha-surface1: #45475a;
57
57
-
--mocha-surface0: #313244;
58
58
-
--mocha-base: #1e1e2e;
59
59
-
--mocha-mantle: #181825;
60
60
-
--mocha-crust: #11111b;
61
61
-
}
62
62
-
63
63
-
@view-transition {
64
64
-
navigation: auto;
65
65
-
}
66
66
-
67
67
-
::view-transition-group(root) {
68
68
-
animation: none;
69
69
-
}
70
70
-
71
71
-
.post-content {
72
72
-
code {
73
73
-
font-size: 1.125rem;
74
74
-
line-height: 1.5;
75
75
-
font-family: maple-mono;
76
76
-
background-color: var(--mocha-mantle);
77
77
-
}
78
78
-
79
79
-
h1,
80
80
-
h2,
81
81
-
h3,
82
82
-
h4,
83
83
-
h5,
84
84
-
h6 {
85
85
-
font-weight: bold;
86
86
-
text-align: start;
87
87
-
}
88
88
-
89
89
-
h1 {
90
90
-
font-size: 2.5rem;
91
91
-
}
92
92
-
93
93
-
h2 {
94
94
-
font-size: 1.875rem;
95
95
-
}
96
96
-
97
97
-
h3 {
98
98
-
font-size: 1.5rem;
99
99
-
}
100
100
-
101
101
-
a:not(:has(sup)) {
102
102
-
text-decoration: underline;
103
103
-
text-underline-offset: 2px;
104
104
-
color: var(--mocha-lavender);
105
105
-
}
106
106
-
107
107
-
hr {
108
108
-
color: var(--mocha-surface0);
109
109
-
border: 1px solid;
110
110
-
}
111
111
-
112
112
-
section[role="doc-endnotes"] {
113
113
-
hr {
114
114
-
margin-bottom: var(--default-padding);
115
115
-
}
116
116
-
117
117
-
li {
118
118
-
list-style: numbered inside;
119
119
-
120
120
-
&::marker {
121
121
-
color: var(--mocha-surface0);
122
122
-
}
123
123
-
124
124
-
p {
125
125
-
display: inline;
126
126
-
}
127
127
-
}
128
128
-
129
129
-
a[role="doc-backlink"] {
130
130
-
display: none;
131
131
-
}
132
132
-
}
133
133
-
134
134
-
blockquote {
135
135
-
&.note {
136
136
-
border-color: var(--mocha-blue);
137
137
-
}
138
138
-
139
139
-
&.tip {
140
140
-
border-color: var(--mocha-green);
141
141
-
}
142
142
-
143
143
-
&.important {
144
144
-
border-color: var(--mocha-mauve);
145
145
-
}
146
146
-
147
147
-
&.warning {
148
148
-
border-color: var(--mocha-yellow);
149
149
-
}
150
150
-
151
151
-
&.caution {
152
152
-
border-color: var(--mocha-red);
153
153
-
}
154
154
-
155
155
-
padding: var(--default-padding);
156
156
-
background-color: var(--mocha-mantle);
157
157
-
border-left: solid 0.8rem;
158
158
-
border-color: var(--mocha-lavender);
159
159
-
border-radius: var(--border-radius);
160
160
-
}
161
161
-
162
162
-
/* CODE HIGHLIGHTS */
163
163
-
164
164
-
pre:has(code) {
165
165
-
padding: var(--default-padding);
166
166
-
background-color: var(--mocha-mantle);
167
167
-
overflow-x: scroll;
168
168
-
border-radius: var(--border-radius);
169
169
-
}
170
170
-
171
171
-
pre code {
172
172
-
.hl-comment {
173
173
-
color: #5f5f87;
174
174
-
font-style: italic;
175
175
-
}
176
176
-
177
177
-
.hl-function {
178
178
-
color: #89b4fa;
179
179
-
180
180
-
&:hover {
181
181
-
filter: brightness(var(--hover-glow));
182
182
-
}
183
183
-
}
184
184
-
185
185
-
.hl-keyword {
186
186
-
color: #cba6f7;
187
187
-
188
188
-
&:hover {
189
189
-
filter: brightness(var(--hover-glow));
190
190
-
}
191
191
-
}
192
192
-
193
193
-
.hl-module {
194
194
-
color: #cdd6f4;
195
195
-
196
196
-
&:hover {
197
197
-
filter: brightness(var(--hover-glow));
198
198
-
}
199
199
-
}
200
200
-
201
201
-
.hl-number {
202
202
-
color: #fab387;
203
203
-
204
204
-
&:hover {
205
205
-
filter: brightness(var(--hover-glow));
206
206
-
}
207
207
-
}
208
208
-
209
209
-
.hl-operator {
210
210
-
color: #89dceb;
211
211
-
212
212
-
&:hover {
213
213
-
filter: brightness(var(--hover-glow));
214
214
-
}
215
215
-
}
216
216
-
217
217
-
.hl-string {
218
218
-
color: #a6e3a1;
219
219
-
220
220
-
&:hover {
221
221
-
filter: brightness(var(--hover-glow));
222
222
-
}
223
223
-
}
224
224
-
225
225
-
.hl-variant {
226
226
-
color: #f9e2af;
227
227
-
228
228
-
&:hover {
229
229
-
filter: brightness(var(--hover-glow));
230
230
-
}
231
231
-
}
232
232
-
}
233
233
-
234
234
-
/* END OF CODE HIGHLIGHTS */
235
235
-
}
+221
priv/input.css
···
1
1
@import "tailwindcss";
2
2
@import "@catppuccin/tailwindcss/mocha.css";
3
3
+
4
4
+
@theme {
5
5
+
--hover-glow: 120%;
6
6
+
--default-padding: 0.8rem;
7
7
+
--margin-top: 1rem;
8
8
+
--border-radius: 0.5rem;
9
9
+
10
10
+
/* Catpuccin */
11
11
+
--mocha-base: #1e1e2e;
12
12
+
--mocha-text: #cdd6f4;
13
13
+
--mocha-pink: #f5c2e7;
14
14
+
--mocha-mauve: #cba6f7;
15
15
+
--mocha-red: #f38ba8;
16
16
+
--mocha-maroon: #eba0ac;
17
17
+
--mocha-peach: #fab387;
18
18
+
--mocha-yellow: #f9e2af;
19
19
+
--mocha-green: #a6e3a1;
20
20
+
--mocha-teal: #94e2d5;
21
21
+
--mocha-sky: #89dceb;
22
22
+
--mocha-sapphire: #74c7ec;
23
23
+
--mocha-blue: #89b4fa;
24
24
+
--mocha-lavender: #b4befe;
25
25
+
--mocha-text: #cdd6f4;
26
26
+
--mocha-subtext1: #bac2de;
27
27
+
--mocha-subtext0: #a6adc8;
28
28
+
--mocha-overlay2: #9399b2;
29
29
+
--mocha-overlay1: #7f849c;
30
30
+
--mocha-overlay0: #6c7086;
31
31
+
--mocha-surface2: #585b70;
32
32
+
--mocha-surface1: #45475a;
33
33
+
--mocha-surface0: #313244;
34
34
+
--mocha-base: #1e1e2e;
35
35
+
--mocha-mantle: #181825;
36
36
+
--mocha-crust: #11111b;
37
37
+
}
38
38
+
39
39
+
@layer components {
40
40
+
h1,
41
41
+
h2,
42
42
+
h3,
43
43
+
h4,
44
44
+
h5,
45
45
+
h6 {
46
46
+
font-weight: bold;
47
47
+
text-align: start;
48
48
+
}
49
49
+
50
50
+
h1 {
51
51
+
font-size: 2.25rem;
52
52
+
}
53
53
+
54
54
+
h2 {
55
55
+
font-size: 1.875rem;
56
56
+
}
57
57
+
58
58
+
h3 {
59
59
+
font-size: 1.5rem;
60
60
+
}
61
61
+
62
62
+
h4 {
63
63
+
font-size: 1.25rem;
64
64
+
}
65
65
+
66
66
+
h4 {
67
67
+
font-size: 1.125rem;
68
68
+
}
69
69
+
70
70
+
h5 {
71
71
+
font-size: 1rem;
72
72
+
}
73
73
+
74
74
+
h6 {
75
75
+
font-size: 0.875rem;
76
76
+
}
77
77
+
78
78
+
hr {
79
79
+
color: var(--mocha-surface0);
80
80
+
margin: 1rem 0;
81
81
+
border: 1px solid;
82
82
+
}
83
83
+
84
84
+
.post-content {
85
85
+
code {
86
86
+
font-size: 1.125rem;
87
87
+
line-height: 1.5;
88
88
+
font-family: maple-mono;
89
89
+
background-color: var(--mocha-mantle);
90
90
+
}
91
91
+
92
92
+
a:not(:has(sup)) {
93
93
+
text-decoration: underline;
94
94
+
text-underline-offset: 2px;
95
95
+
color: var(--mocha-lavender);
96
96
+
}
97
97
+
98
98
+
/* Footnotes */
99
99
+
section[role="doc-endnotes"] {
100
100
+
hr {
101
101
+
margin-bottom: var(--default-padding);
102
102
+
}
103
103
+
104
104
+
li {
105
105
+
list-style: numbered inside;
106
106
+
107
107
+
&::marker {
108
108
+
color: var(--mocha-surface0);
109
109
+
}
110
110
+
111
111
+
p {
112
112
+
display: inline;
113
113
+
}
114
114
+
}
115
115
+
116
116
+
a[role="doc-backlink"] {
117
117
+
display: none;
118
118
+
}
119
119
+
}
120
120
+
121
121
+
/* Github-style markdown quotes */
122
122
+
blockquote {
123
123
+
&.note {
124
124
+
border-color: var(--mocha-blue);
125
125
+
}
126
126
+
127
127
+
&.tip {
128
128
+
border-color: var(--mocha-green);
129
129
+
}
130
130
+
131
131
+
&.important {
132
132
+
border-color: var(--mocha-mauve);
133
133
+
}
134
134
+
135
135
+
&.warning {
136
136
+
border-color: var(--mocha-yellow);
137
137
+
}
138
138
+
139
139
+
&.caution {
140
140
+
border-color: var(--mocha-red);
141
141
+
}
142
142
+
143
143
+
padding: var(--default-padding);
144
144
+
background-color: var(--mocha-mantle);
145
145
+
border-left: solid 0.8rem;
146
146
+
border-color: var(--mocha-lavender);
147
147
+
border-radius: var(--border-radius);
148
148
+
}
149
149
+
150
150
+
/* CODE HIGHLIGHTS */
151
151
+
pre:has(code) {
152
152
+
padding: var(--default-padding);
153
153
+
background-color: var(--mocha-mantle);
154
154
+
overflow-x: scroll;
155
155
+
border-radius: var(--border-radius);
156
156
+
}
157
157
+
158
158
+
pre code {
159
159
+
.hl-comment {
160
160
+
color: #5f5f87;
161
161
+
font-style: italic;
162
162
+
}
163
163
+
164
164
+
.hl-function {
165
165
+
color: #89b4fa;
166
166
+
167
167
+
&:hover {
168
168
+
filter: brightness(var(--hover-glow));
169
169
+
}
170
170
+
}
171
171
+
172
172
+
.hl-keyword {
173
173
+
color: #cba6f7;
174
174
+
175
175
+
&:hover {
176
176
+
filter: brightness(var(--hover-glow));
177
177
+
}
178
178
+
}
179
179
+
180
180
+
.hl-module {
181
181
+
color: #cdd6f4;
182
182
+
183
183
+
&:hover {
184
184
+
filter: brightness(var(--hover-glow));
185
185
+
}
186
186
+
}
187
187
+
188
188
+
.hl-number {
189
189
+
color: #fab387;
190
190
+
191
191
+
&:hover {
192
192
+
filter: brightness(var(--hover-glow));
193
193
+
}
194
194
+
}
195
195
+
196
196
+
.hl-operator {
197
197
+
color: #89dceb;
198
198
+
199
199
+
&:hover {
200
200
+
filter: brightness(var(--hover-glow));
201
201
+
}
202
202
+
}
203
203
+
204
204
+
.hl-string {
205
205
+
color: #a6e3a1;
206
206
+
207
207
+
&:hover {
208
208
+
filter: brightness(var(--hover-glow));
209
209
+
}
210
210
+
}
211
211
+
212
212
+
.hl-variant {
213
213
+
color: #f9e2af;
214
214
+
215
215
+
&:hover {
216
216
+
filter: brightness(var(--hover-glow));
217
217
+
}
218
218
+
}
219
219
+
}
220
220
+
221
221
+
/* END OF CODE HIGHLIGHTS */
222
222
+
}
223
223
+
}
+2
-2
src/blog.gleam
···
66
66
67
67
let post_header =
68
68
html.header([class("hidden md:block")], [
69
69
-
html.h1([class("mb-1 text-4xl font-bold")], [html.text(title)]),
69
69
+
html.h1([], [html.text(title)]),
70
70
html.p([class("my-2")], [html.text(post.meta.description)]),
71
71
-
html.hr([class("border text-ctp-surface0")]),
71
71
+
html.hr([]),
72
72
])
73
73
74
74
let back_button_style =
+2
-4
src/blog/page/posts.gleam
···
43
43
44
44
html.li([li_styles], [
45
45
html.a([attr.href(post.meta.slug <> ".html")], [
46
46
-
html.h2([class("text-2xl font-bold text-pretty")], [
47
47
-
html.text(meta.title),
48
48
-
]),
46
46
+
html.h3([], [html.text(meta.title)]),
49
47
]),
50
48
51
49
html.p([class("my-2 text-ctp-text")], [html.text(str_date)]),
52
50
html.ul([class("flex flex-wrap gap-2")], list.map(meta.tags, tag_to_li)),
53
53
-
html.hr([class("my-4 border border-ctp-surface0")]),
51
51
+
html.hr([]),
54
52
])
55
53
}
56
54
+4
-6
src/blog/page/recent_posts.gleam
···
13
13
|> list.map(post_to_li)
14
14
15
15
let articles_section = html.ul([class("grid grid-cols-1 gap-2")], previews)
16
16
-
let section_title = html.h3([class("text-lg")], [html.text("Recent posts")])
16
16
+
let section_title = html.h4([], [html.text("Recent posts")])
17
17
let more_style = class("max-w-min underline text-md underline-offset-2")
18
18
-
let more = html.a([attr.href("articles.html"), more_style], [html.text("More")])
18
18
+
let more =
19
19
+
html.a([attr.href("articles.html"), more_style], [html.text("More")])
19
20
20
21
html.section([class("grid grid-cols-1 gap-2")], [
21
22
section_title,
···
41
42
let style = class("flex flex-col p-4 mx-auto w-full rounded-lg bg-ctp-mantle")
42
43
43
44
html.li([style], [
44
44
-
html.h3([class("font-bold text-pretty")], [
45
45
-
html.a([href], [html.text(meta.title)]),
46
46
-
]),
47
47
-
45
45
+
html.h3([], [html.a([href], [html.text(meta.title)])]),
48
46
html.p([], [html.text(str_date)]),
49
47
])
50
48
}