1
0
Fork 0
mirror of https://git.sr.ht/~seirdy/seirdy.one synced 2024-11-10 00:12:09 +00:00

Optimal line length

This commit is contained in:
Rohan Kumar 2022-03-26 12:33:01 -07:00
parent fd576c9175
commit 82a63d9662
No known key found for this signature in database
GPG key ID: 1E892DB2A5F84479
2 changed files with 7 additions and 5 deletions

View file

@ -26,25 +26,26 @@
* default fonts, non-dark-mode colors, etc.
*/
html,
.e-content {
html {
/* Mobile screens benefit from greater line-spacing so links are
* further apart. Dyslexic users prefer the spacing too.
* <100dpi screens: sans-serif is better. Why did browsers settle
* on serif being the default??*/
font: 110%/1.5 sans-serif;
font: 100%/1.5 sans-serif;
/* WCAG recommends a max line width. Not everyone can resize the
* viewport. TODO: see if this should be reduced.
* Aligning to the center with space on both sides prevents accidental
* link activation on mobile devices.*/
margin: auto;
max-width: 48em;
max-width: 45em;
padding: 0 3%;
}
.e-content {
max-width: 40em;
max-width: 38em;
padding 0;
margin: auto;
}
/* narrow screens: reduce margin for blockquotes a lot, using

View file

@ -20,6 +20,7 @@
<span itemprop="wordCount">{{ .WordCount }}</span> words, a <span itemprop="timeRequired" content="PT{{ .ReadingTime }}M">{{ .ReadingTime }} minute</span> read
</small>
</header>
<hr>
<section class="e-content entry-content" itemprop="articleBody">
{{ partial "processed-content" . -}}
</section>