Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/devcows/hugo-universal-theme.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSalim B <salim@posteo.de>2019-11-08 18:59:44 +0300
committerGuillermo Guerrero Ibarra <wolf.fox1985@gmail.com>2019-11-08 18:59:44 +0300
commit2c951590bce77f987b14efe59647f3e48a7dd435 (patch)
tree98855938d24fe97f469c60149faee628a452e270 /layouts
parent768e1973c203e7c81bf27827c881a6e797d731c2 (diff)
localize 404 page; allow Markdown at more places; clickable feature icons (#184)
* allow Markdown in clients (sub)title * localize 404 page * add Markdown support for recent posts title * allow Markdown in see_more section strings * allow Markdown in features names * make feature icons clickable (hyperlinks) * allow Markdown in credits strings; better bootstrapious link * make see_more section more flexible: avoid Hugo error(s) when `params.see_more.link_url` or `params.see_more.link_text` aren't defined * rename `link` key into `url` to be consistent: - since in the client YAML files the respective key is names `url`, I guess I should stick to that. - besides I've removed the one `#` I've specified as the URL in `data/features/webdesign.yaml`; originally that was intended as a "visual" hint that now it is easily possible to make the features clickable. but I guess that's not really necessary, if not even irritating. * layouts: remove double logo from 404 the changes in this commit are identical with timmn's commit 33ad328776eeb90f6d6793f7036fcb3338fb5155 * rename string to * translate remaining Catalan 404 strings * improve documentation of feature YAML files
Diffstat (limited to 'layouts')
-rw-r--r--layouts/404.html12
-rw-r--r--layouts/partials/clients.html4
-rw-r--r--layouts/partials/features.html30
-rw-r--r--layouts/partials/footer.html4
-rw-r--r--layouts/partials/recent_posts.html2
-rw-r--r--layouts/partials/see_more.html15
6 files changed, 37 insertions, 30 deletions
diff --git a/layouts/404.html b/layouts/404.html
index c4bab21..5f9be21 100644
--- a/layouts/404.html
+++ b/layouts/404.html
@@ -20,16 +20,10 @@
<div class="box">
- <p class="text-center">
- <a href="{{ .Site.BaseURL }}">
- <img src="{{ .Site.Params.logo }}" alt="{{ .Title }} logo">
- </a>
- </p>
-
- <h3>We are sorry - this page is not here anymore</h3>
- <h4 class="text-muted">Error 404 - Page not found</h4>
+ <h3>{{ i18n "404Message" | markdownify }}</h3>
+ <h4 class="text-muted">{{ i18n "404Error" | markdownify }}</h4>
- <p class="buttons"><a href="{{ .Site.BaseURL }}" class="btn btn-template-main"><i class="fas fa-home"></i> Go to Homepage</a>
+ <p class="buttons"><a href="{{ .Site.BaseURL }}" class="btn btn-template-main"><i class="fas fa-home"></i> {{ i18n "404NavHome" | markdownify }}</a>
</p>
</div>
diff --git a/layouts/partials/clients.html b/layouts/partials/clients.html
index a012367..fd68aeb 100644
--- a/layouts/partials/clients.html
+++ b/layouts/partials/clients.html
@@ -6,11 +6,11 @@
<div class="row">
<div class="col-md-12">
<div class="heading text-center">
- <h2>{{ .Site.Params.clients.title }}</h2>
+ <h2>{{ .Site.Params.clients.title | markdownify }}</h2>
</div>
<p class="lead">
- {{ .Site.Params.clients.subtitle }}
+ {{ .Site.Params.clients.subtitle | markdownify }}
</p>
<ul class="owl-carousel customers">
diff --git a/layouts/partials/features.html b/layouts/partials/features.html
index 9260d3f..f41f2a1 100644
--- a/layouts/partials/features.html
+++ b/layouts/partials/features.html
@@ -4,23 +4,29 @@
<section class="bar background-white">
<div class="container">
{{ range $index, $element := sort .Site.Data.features "weight" }}
- {{ if eq (mod $index 3) 0 }}
- <div class="col-md-12">
+ {{ if eq (mod $index 3) 0 }}
+ <div class="col-md-12">
<div class="row">
- {{ end }}
- <div class="col-md-4">
+ {{ end }}
+ <div class="col-md-4">
<div class="box-simple">
- <div class="icon">
- <i class="{{ .icon }}"></i>
- </div>
- <h3>{{ $element.name }}</h3>
+ {{ with $element.url }}
+ <a href="{{ $element.url }}">
+ {{ end }}
+ <div class="icon">
+ <i class="{{ .icon }}"></i>
+ </div>
+ {{ with $element.url }}
+ </a>
+ {{ end }}
+ <h3>{{ $element.name | markdownify }}</h3>
<p>{{ $element.description | markdownify }}</p>
</div>
</div>
- {{ if or (eq (mod $index 3) 2) (eq $index (sub (len $.Site.Data.features) 1 )) }}
- </div>
- </div>
- {{ end }}
+ {{ if or (eq (mod $index 3) 2) (eq $index (sub (len $.Site.Data.features) 1 )) }}
+ </div>
+ </div>
+ {{ end }}
{{ end }}
</div>
</section>
diff --git a/layouts/partials/footer.html b/layouts/partials/footer.html
index d830678..c7a880d 100644
--- a/layouts/partials/footer.html
+++ b/layouts/partials/footer.html
@@ -76,10 +76,10 @@ _________________________________________________________ -->
<p class="pull-left">{{ .Site.Params.copyright | safeHTML }}</p>
{{ end }}
<p class="pull-right">
- {{ i18n "templateBy" }} <a href="http://bootstrapious.com/free-templates">Bootstrapious</a>.
+ {{ i18n "templateBy" | markdownify }} <a href="https://bootstrapious.com/p/universal-business-e-commerce-template">Bootstrapious</a>.
<!-- Not removing this link is part of the licence conditions of the template. Thanks for understanding :) -->
- {{ i18n "portedBy" }} <a href="https://github.com/devcows/hugo-universal-theme">DevCows</a>
+ {{ i18n "portedBy" | markdownify }} <a href="https://github.com/devcows/hugo-universal-theme">DevCows</a>.
</p>
</div>
</div>
diff --git a/layouts/partials/recent_posts.html b/layouts/partials/recent_posts.html
index c46f959..2e4eba2 100644
--- a/layouts/partials/recent_posts.html
+++ b/layouts/partials/recent_posts.html
@@ -5,7 +5,7 @@
<div class="col-md-12">
<div class="heading text-center">
- <h2>{{ .Site.Params.recent_posts.title }}</h2>
+ <h2>{{ .Site.Params.recent_posts.title | markdownify }}</h2>
</div>
<p class="lead">
diff --git a/layouts/partials/see_more.html b/layouts/partials/see_more.html
index 08301c1..437d9d8 100644
--- a/layouts/partials/see_more.html
+++ b/layouts/partials/see_more.html
@@ -7,13 +7,20 @@
<div class="col-md-12">
<div class="icon icon-lg"><i class="{{ .Site.Params.see_more.icon }}"></i>
</div>
- <h3 class="text-uppercase">{{ .Site.Params.see_more.title }}</h3>
- <p class="lead">{{ .Site.Params.see_more.subtitle }}</p>
+ <h3 class="text-uppercase">{{ .Site.Params.see_more.title | markdownify }}</h3>
+ <p class="lead">{{ .Site.Params.see_more.subtitle | markdownify }}</p>
<p class="text-center">
- <a href="{{ .Site.Params.see_more.link_url }}" class="btn btn-template-transparent-black btn-lg">{{ .Site.Params.see_more.link_text }}</a>
+ {{ with .Site.Params.see_more.link_url }}
+ <a href="{{ . }}" class="btn btn-template-transparent-black btn-lg">
+ {{ end }}
+ {{ with .Site.Params.see_more.link_text }}
+ {{ . | markdownify }}
+ {{ end }}
+ {{ with .Site.Params.see_more.link_url }}
+ </a>
+ {{ end }}
</p>
</div>
-
</div>
</div>
</section>