Skip to content

Commit e1ea133

Browse files
committed
style fixes
1 parent 18a4588 commit e1ea133

File tree

6 files changed

+16
-34
lines changed

6 files changed

+16
-34
lines changed

assets/css/style.css

Lines changed: 11 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@
6565
}
6666

6767
@font-face {
68-
font-family: 'Iosevka Web';
68+
font-family: 'Iosevka';
6969
font-weight: 400;
7070
font-style: normal;
7171
src: url('/static/fonts/iosevka-regular.woff2') format('woff2'),
@@ -74,7 +74,7 @@
7474
}
7575

7676
@font-face {
77-
font-family: 'Iosevka Web';
77+
font-family: 'Iosevka';
7878
font-weight: 400;
7979
font-style: italic;
8080
src: url('/static/fonts/iosevka-italic.woff2') format('woff2'),
@@ -83,7 +83,7 @@
8383
}
8484

8585
@font-face {
86-
font-family: 'Iosevka Web';
86+
font-family: 'Iosevka';
8787
font-weight: 700;
8888
font-style: normal;
8989
src: url('/static/fonts/iosevka-bold.woff2') format('woff2'),
@@ -92,7 +92,7 @@
9292
}
9393

9494
@font-face {
95-
font-family: 'Iosevka Web';
95+
font-family: 'Iosevka';
9696
font-weight: 700;
9797
font-style: italic;
9898
src: url('/static/fonts/iosevka-bolditalic.woff2') format('woff2'),
@@ -150,7 +150,6 @@ pre {
150150
}
151151

152152
pre code {
153-
counter-increment: line;
154153
display: block;
155154
background-color: rgb(238, 238, 238) !important
156155
}
@@ -160,22 +159,8 @@ p code {
160159
padding: 0 0.15rem;
161160
}
162161

163-
.hljs-ln-numbers {
164-
-webkit-touch-callout: none;
165-
-webkit-user-select: none;
166-
-khtml-user-select: none;
167-
-moz-user-select: none;
168-
-ms-user-select: none;
169-
user-select: none;
170-
171-
text-align: center;
172-
color: #999;
173-
vertical-align: top;
174-
padding-right: 1rem !important;
175-
}
176-
177162
code, pre {
178-
font-family: 'Iosevka Web', monospace;
163+
font-family: 'Iosevka', monospace;
179164
}
180165

181166
code {
@@ -237,7 +222,7 @@ input, textarea {
237222

238223
textarea {
239224
display: block;
240-
font-family: 'Iosevka Web', monospace;
225+
font-family: 'Iosevka', monospace;
241226
min-height: 100px;
242227
}
243228

@@ -296,12 +281,12 @@ body > .container:first-child {
296281

297282
#view-source {
298283
float: right;
299-
font-family: 'Iosevka Web', monospace;
284+
font-family: 'Iosevka', monospace;
300285
margin-top: -0.4rem;
301286
}
302287

303288
#monero {
304-
font-family: 'Iosevka Web', monospace;
289+
font-family: 'Iosevka', monospace;
305290
font-size: 0.8rem;
306291
}
307292

@@ -326,12 +311,12 @@ li:hover span.inset {
326311

327312
.post-list-date {
328313
text-alignt: right;
329-
font-family: 'Iosevka Web', monospace;
314+
font-family: 'Iosevka', monospace;
330315
font-size: 0.9rem;
331316
}
332317

333318
.post-date {
334-
font-family: 'Iosevka Web', monospace;
319+
font-family: 'Iosevka', monospace;
335320
font-size: 0.9rem;
336321
}
337322

@@ -353,7 +338,7 @@ li:hover span.inset {
353338
@media (max-width: 768px) {
354339
body > .container:first-child {
355340
padding-top: 1rem;
356-
padding-bottom: 10rem;
341+
padding-bottom: 18rem;
357342
}
358343

359344
.content {

assets/img/cc.png

475 Bytes
Loading

assets/js/author.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
function trimLines(s) {
2-
return s.split('\n').map(l => l.trim()).join('\n')
2+
return s.split('\n').map(l => l.trimEnd()).join('\n')
33
}
44

55
async function main() {

assets/js/highlightjs-line-numbers.min.js

Lines changed: 0 additions & 1 deletion
This file was deleted.

assets/js/script.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,13 @@ function main() {
22
// code
33
document.querySelectorAll('pre code').forEach(block => {
44
hljs.highlightBlock(block)
5-
hljs.lineNumbersBlock(block)
65
})
76

87
// math
98
renderMathInElement(document.body)
109

1110
// videos
12-
document.querySelectorAll('video').forEach(v => {
11+
document.querySelectorAll('video').forEach(async v => {
1312
v.addEventListener('pause', () => {
1413
if (v.autoplay) {
1514
v.play()

src/Lib/Server/Template.hs

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ instance ToHtml a => ToHtml (Template a) where
3232
let description = case descriptionM of
3333
Nothing -> "unsafePerformIO is the blog and personal website of Wilfred Denton."
3434
Just description' -> description'
35-
assetVer = "7"
35+
assetVer = "10"
3636
title_ $ toHtml title
3737
meta_ [charset_ "utf-8"]
3838
meta_ [name_ "description", content_ description]
@@ -59,8 +59,7 @@ instance ToHtml a => ToHtml (Template a) where
5959
script_ [src_ "/static/katex/katex.min.js"] ("" :: Text)
6060
script_ [src_ "/static/katex/auto-render.min.js"] ("" :: Text)
6161
script_ [src_ "/static/js/highlight.pack.js"] ("" :: Text)
62-
script_ [src_ "/static/js/highlightjs-line-numbers.min.js"] ("" :: Text)
63-
script_ [src_ $ "/static/js/script.js?=" <> assetVer, async_ "true"] ("" :: Text)
62+
script_ [src_ $ "/static/js/script.js?=" <> assetVer] ("" :: Text)
6463
script_ [src_ "https://www.googletagmanager.com/gtag/js?id=UA-131857401-1", async_ "true"] ("" :: Text)
6564
script_ "window.dataLayer = window.dataLayer || []; function gtag(){dataLayer.push(arguments);} gtag('js', new Date()); gtag('config', 'UA-131857401-1');"
6665
body_ $ do
@@ -87,7 +86,7 @@ instance ToHtml a => ToHtml (Template a) where
8786
img_
8887
[ alt_ "Creative Commons License",
8988
style_ "border-width:0",
90-
src_ "https://i.creativecommons.org/l/by-sa/3.0/us/80x15.png"
89+
src_ "/static/img/cc.png"
9190
]
9291
button_ [id_ "view-source", href_ "https://github.com/wilfreddenton/unsafePerformIO", target_ "_blank"] "</>"
9392

0 commit comments

Comments
 (0)