From 78a6f5505d585fae4d32ae53304f7a1981263f4b Mon Sep 17 00:00:00 2001 From: Julien Dessaux Date: Mon, 16 Aug 2021 12:35:32 +0200 Subject: Switched to a solarized color scheme --- assets/footer.css | 6 +++--- assets/header.css | 10 +++------- assets/pagination.css | 21 +++++++++++++-------- assets/solarized.css | 36 ++++++++++++++++++++++++++++++++++++ config.toml | 21 +++++++++++++-------- layouts/_default/baseof.html | 3 ++- layouts/partials/nav.html | 4 ++-- layouts/partials/pagination.html | 4 ++-- 8 files changed, 74 insertions(+), 31 deletions(-) create mode 100644 assets/solarized.css diff --git a/assets/footer.css b/assets/footer.css index e27317c..dfcbbce 100644 --- a/assets/footer.css +++ b/assets/footer.css @@ -1,11 +1,11 @@ footer { - background-color: #30638e; + background-color: #002b36; padding: 10px; } footer p { - color: lightgray; + color: #859900; text-align: center; } footer a { - color: lightgray; + color: #859900; } diff --git a/assets/header.css b/assets/header.css index fc4c83e..5e45df4 100644 --- a/assets/header.css +++ b/assets/header.css @@ -1,5 +1,5 @@ header { - background-color: #30638e; + background-color: #002b36; } header nav ul { list-style-type: none; @@ -14,19 +14,15 @@ header nav ul li { } header nav ul li a { display: block; - color: lightgray; text-align: center; padding: 14px 16px; text-decoration: none; } -header nav ul li a:hover { - color: black; +.nav-menu-active { + background-color: #073642; } .nav-menu-title { float: left; text-transform: uppercase; font-weight: 700; } -.nav-menu-active { - color: white; -} diff --git a/assets/pagination.css b/assets/pagination.css index ba568fb..abcb0c3 100644 --- a/assets/pagination.css +++ b/assets/pagination.css @@ -3,6 +3,9 @@ list-style:none; border-radius:.25rem; } +.pagination li { + background-color: #002b36; +} .pagination li a { border:1px solid rgba(0,0,0,.1); position:relative; @@ -11,23 +14,25 @@ line-height:1.25; text-decoration: none; } -.pagination li:first-child a { +.pagination .pagination-enabled:first-child a { border-top-left-radius:.25rem; border-bottom-left-radius:.25rem } -.pagination li:last-child a { +.pagination .pagination-enabled:last-child a { border-top-right-radius:.25rem; border-bottom-right-radius:.25rem } -.pagination li a:hover { - color:#1e53a0; - background-color:#eee; +.pagination .pagination-enabled a:hover { + background-color: #073642; z-index: 999; } -.pagination-disabled { - color: lightgray; +.pagination-disabled a { + color: #839496; +} +.pagination-disabled a:hover { + color: #839496; } .pagination-active a { color: white; - background-color: #30638e; + background-color: #073642; } diff --git a/assets/solarized.css b/assets/solarized.css new file mode 100644 index 0000000..e00a93f --- /dev/null +++ b/assets/solarized.css @@ -0,0 +1,36 @@ +html { + background-color: #002b36; + color: #839496; +} +body { + background-color: #073642; +} +code { + background-color: #073642; +} +a { + color: #b58900; +} +a:visited { + color: #cb4b16; +} +a:hover { + color: #cb4b16; +} +h1 { + color: #dc322f; +} +h2, +h3, +h4, +h5, +h6 { + color: #859900; +} +pre { + background-color: #002b36; + color: #839496; +} +pre, code { + background-color: #002b36; +} diff --git a/config.toml b/config.toml index 27debbf..7294f53 100644 --- a/config.toml +++ b/config.toml @@ -7,14 +7,19 @@ enableGitInfo = true paginate = 32 rssLimit = 16 -# Highlighting config -pygmentsCodeFences = true -pygmentsUseClasses = false -# Use the new Chroma Go highlighter in Hugo. -pygmentsUseClassic = false -#pygmentsOptions = "linenos=table" -# See https://help.farbox.com/pygments.html -pygmentsStyle = "tango" +[markup] +[markup.highlight] +anchorLineNos = false +codeFences = true +guessSyntax = false +hl_Lines = '' +lineAnchors = '' +lineNoStart = 1 +lineNos = false +lineNumbersInTable = true +noClasses = true +style = 'solarized-dark' +tabWidth = 2 [permalinks] blog = "/:section/:year/:month/:day/:slug/" diff --git a/layouts/_default/baseof.html b/layouts/_default/baseof.html index 5b4f442..07920c1 100644 --- a/layouts/_default/baseof.html +++ b/layouts/_default/baseof.html @@ -14,7 +14,8 @@ {{- $home := resources.Get "home.css" -}} {{- $pagination := resources.Get "pagination.css" -}} {{- $footer := resources.Get "footer.css" -}} - {{- $allCss := slice $base $header $home $pagination $footer | resources.Concat "static/all.css" | fingerprint | minify -}} + {{- $solarized := resources.Get "solarized.css" -}} + {{- $allCss := slice $base $header $home $pagination $footer $solarized | resources.Concat "static/all.css" | fingerprint | minify -}} {{ range .AlternativeOutputFormats -}} diff --git a/layouts/partials/nav.html b/layouts/partials/nav.html index f54ae38..97f494e 100644 --- a/layouts/partials/nav.html +++ b/layouts/partials/nav.html @@ -12,8 +12,8 @@ {{- end -}} {{- $url := urls.Parse .URL -}} {{- $baseurl := urls.Parse $.Site.Params.Baseurl -}} -
  • - {{ .Name }} + + {{ .Name }}
  • {{ end }} diff --git a/layouts/partials/pagination.html b/layouts/partials/pagination.html index 7220408..e2724ec 100644 --- a/layouts/partials/pagination.html +++ b/layouts/partials/pagination.html @@ -2,7 +2,7 @@ {{- if gt $pag.TotalPages 1 -}}