sgregoratto.me

Hugo files for www.sgregoratto.me
git clone git://git.sgregoratto.me/sgregoratto.me
Log | Files | Refs

commit 703c163a257f9a1e88cfcfea817f646a1f17afb7
parent f7dc417c9873fa40a3591e25946e973b216ee5bb
Author: Stephen Gregoratto <dev@sgregoratto.me>
Date:   Sat, 27 Apr 2019 17:23:27 +1000

Support hypenation and other CSS changes

Diffstat:
Mlayouts/partials/header.html | 2+-
Mstatic/css/style.css | 52+++++++++++++++++++++++++++++++++++++---------------
2 files changed, 38 insertions(+), 16 deletions(-)

diff --git a/layouts/partials/header.html b/layouts/partials/header.html @@ -1,5 +1,5 @@ <!DOCTYPE html> -<html> +<html lang="en-AU"> <head> <meta charset="utf-8"/> <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes"/> diff --git a/static/css/style.css b/static/css/style.css @@ -1,24 +1,46 @@ +p { + -webkit-hyphens: auto; + -webkit-hyphenate-limit-before: 3; + -webkit-hyphenate-limit-after: 3; + -webkit-hyphenate-limit-chars: 6 3 3; + -webkit-hyphenate-limit-lines: 2; + -webkit-hyphenate-limit-last: always; + -webkit-hyphenate-limit-zone: 8%; + + -moz-hyphens: auto; + -moz-hyphenate-limit-chars: 6 3 3; + -moz-hyphenate-limit-lines: 2; + -moz-hyphenate-limit-last: always; + -moz-hyphenate-limit-zone: 8%; + + -ms-hyphens: auto; + -ms-hyphenate-limit-chars: 6 3 3; + -ms-hyphenate-limit-lines: 2; + -ms-hyphenate-limit-last: always; + -ms-hyphenate-limit-zone: 8%; + + hyphens: auto; + hyphenate-limit-chars: 6 3 3; + hyphenate-limit-lines: 2; + hyphenate-limit-last: always; + hyphenate-limit-zone: 8%; +} body { - margin: 2rem auto; - max-width: 40em; - padding: 0 2em; + margin: auto; + max-width: 38rem; + padding: 2rem; width: auto; font-family: sans-serif; font-size: 1rem; border: none; vertical-align: baseline; } -h1 ,h2, h3, h4, h5, h6 { - line-height: 1.2; -} -.subtitle, .date { +header { + line-height: 0.9rem; font-weight: bold; } -.date { - font-weight: bold; +header .date { color: #555; - margin: 0; - padding: 0; } .footnotes { font-size: small; @@ -34,7 +56,7 @@ figure { } pre { background-color: #f2f2f2; - border: 0.1em solid #ccc; + border: 0.1rem solid #ccc; border-radius: .5em; margin: 0 0 10px; overflow: auto; @@ -44,9 +66,9 @@ pre { padding: 1em; } blockquote { - padding: 0 0 0em 2em; - margin: 0em; - border-left: 0.3em #aaa solid; + padding: 0 0 0rem 2rem; + margin: 0rem; + border-left: 0.3rem #aaa solid; color: #666; } blockquote p {