From 003f0139d2d9f4d97d70f9396c76c23614bed612 Mon Sep 17 00:00:00 2001 From: Lars Bilke <lars.bilke@ufz.de> Date: Wed, 3 Jun 2020 20:43:42 +0200 Subject: [PATCH] [web] Fixed FontAwesome subset usage. --- web/layouts/partials/breadcrumb.html | 2 +- web/layouts/partials/components/news.html | 6 +----- web/layouts/partials/releases-single.html | 4 ++-- web/layouts/section/docs.html | 26 +++++++++++++++++++++-- web/layouts/section/releases.html | 4 ++-- 5 files changed, 30 insertions(+), 12 deletions(-) diff --git a/web/layouts/partials/breadcrumb.html b/web/layouts/partials/breadcrumb.html index c1c885ec593..e00934f5226 100644 --- a/web/layouts/partials/breadcrumb.html +++ b/web/layouts/partials/breadcrumb.html @@ -11,7 +11,7 @@ <li{{ if eq .p1 .p2 }} class="active"{{ end }}> <a href="{{ .p1.Permalink }}"> {{ if .p1.IsHome }} - <i class="fas fa-home"></i> + <i class="far fa-home"></i> {{ else }} {{ .p1.Title }} {{ end }} diff --git a/web/layouts/partials/components/news.html b/web/layouts/partials/components/news.html index 48d5595780b..bf14c476ce1 100644 --- a/web/layouts/partials/components/news.html +++ b/web/layouts/partials/components/news.html @@ -32,11 +32,7 @@ <li> <!-- Two weeks --> <a href="{{ .Permalink }}"> - - <span class="fa-layers fa-fw{{if gt (sub now.Unix .Lastmod.Unix) 1209600}} invisible{{end}}"> - <i class="fas fa-certificate"></i> - <span class="fa-layers-text fa-inverse" data-fa-transform="shrink-11.5 rotate--30" style="font-weight:900">NEW</span> - </span> + <i class="fa{{if gt (sub now.Unix .Lastmod.Unix) 1209600}}l{{else}}s{{end}} fa-plus-circle"></i> {{ .Title }} </a> </li> diff --git a/web/layouts/partials/releases-single.html b/web/layouts/partials/releases-single.html index fc58b60e3f4..afc5417cf5a 100644 --- a/web/layouts/partials/releases-single.html +++ b/web/layouts/partials/releases-single.html @@ -4,11 +4,11 @@ <p>Released on {{ dateFormat "Monday, Jan 2, 2006" .Params.release_date }}, <a href="{{ $gh_release }}"><i class="fab fa-github"></i> GitHub release</a></p> {{ if .Params.downloads }} <div class="note"> - <h3><i class="fal fa-download"></i> Benchmark downloads</h3> + <h3><i class="far fa-download"></i> Benchmark downloads</h3> <div class="flex"> <a href="https://github.com/ufz/ogs-data/archive/{{.Params.tag}}.zip"><i class="far fa-arrow-right"></i> Benchmark input files for OpenGeoSys {{ .Params.tag }}</a> </div> - <h3><i class="fal fa-download"></i> Binary downloads</h3> + <h3><i class="far fa-download"></i> Binary downloads</h3> <div class="flex"> {{ if .Params.downloads.win }} <div class="w-1/2"> diff --git a/web/layouts/section/docs.html b/web/layouts/section/docs.html index c4acd2c34e1..45de7c83dde 100644 --- a/web/layouts/section/docs.html +++ b/web/layouts/section/docs.html @@ -1,6 +1,5 @@ {{ define "main" }} <div class="container"> - {{ .Content }} {{ if ne .CurrentSection.RelPermalink "/docs/" }} <h2>{{ .CurrentSection.Title }} - All pages</h2> <ul> @@ -10,6 +9,29 @@ </ul> {{ else }} <!-- /docs --> + <div class="flex flex-wrap w-full mb-4 flex-col items-center text-center"> + {{ .Content }} + </div> + + <div class="flex flex-wrap -m-4"> + {{ range .Params.sections }} + <div class="xl:w-1/3 md:w-1/2 p-4 my-3"> + <div class="border border-gray-300 p-6 rounded-lg h-full"> + <h2 class="text-lg text-gray-900 font-medium title-font mb-2"> + <a href="{{ .url }}"> + {{ .name }} + {{ $url_first_char := substr .url 0 1 }} + {{ if not (eq $url_first_char "/") }} + <i class="text-xs align-top far fa-external-link"></i> + {{ end }} + </a> + </h2> + <p class="leading-relaxed text-base">{{ .text }}</p> + </div> + </div> + {{ end }} + </div> + <div class="flex flex-wrap"> {{ range .Params.sections }} <div class="w-full sm:w-1/2 lg:w-1/3 p-3 my-3"> @@ -18,7 +40,7 @@ {{ .name }} {{ $url_first_char := substr .url 0 1 }} {{ if not (eq $url_first_char "/") }} - <i class="text-xs align-top fas fa-external-link-alt"></i> + <i class="text-xs align-top far fa-external-link"></i> {{ end }} </a> </h2> diff --git a/web/layouts/section/releases.html b/web/layouts/section/releases.html index 474dd6f7f8f..6404212f61b 100644 --- a/web/layouts/section/releases.html +++ b/web/layouts/section/releases.html @@ -8,12 +8,12 @@ successfully tested by the continuous integration system it may be unstable or incomplete... </p> <div class="note"> - <h3><i class="fal fa-download"></i> Download</h3> + <h3><i class="far fa-download"></i> Download</h3> <p> Downloads for the current development version of OpenGeoSys can be found on our continuous integration system: </p> <p> - <a href="https://jenkins.opengeosys.org/job/ufz/job/ogs/job/master/lastSuccessfulBuild/artifact/build"><i class="fas fa-arrow-right"></i> Latest successful Jenkins Build with Downloads</a> <span class="text-sm text-gray-600"></span> + <a href="https://jenkins.opengeosys.org/job/ufz/job/ogs/job/master/lastSuccessfulBuild/artifact/build"><i class="far fa-arrow-right"></i> Latest successful Jenkins Build with Downloads</a> <span class="text-sm text-gray-600"></span> </p> </div> -- GitLab