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

github.com/Vimux/Binario.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVimux <Vimux@users.noreply.github.com>2022-03-20 15:11:17 +0300
committerGitHub <noreply@github.com>2022-03-20 15:11:17 +0300
commit8bd2f6f17ff54e2f307bbc961bc498854352296e (patch)
tree463ae5e14e444f8caf7a719f1284be4cf5dc74bc
parentee84631bbb99cd14c1958687ac602709b9208245 (diff)
parent69b90178c19a8ebff1ed322c5e49f4eaf397f7b3 (diff)
Merge pull request #62 from bugok/tags_meta
Add tags to entry/meta/tags
-rw-r--r--README.md5
-rw-r--r--i18n/en.yaml3
-rw-r--r--i18n/fr.yaml3
-rw-r--r--i18n/it.yaml3
-rw-r--r--i18n/pt-br.yaml3
-rw-r--r--i18n/pt.yaml3
-rw-r--r--layouts/partials/entry/meta/categories.html4
-rw-r--r--layouts/partials/entry/meta/tags.html11
8 files changed, 31 insertions, 4 deletions
diff --git a/README.md b/README.md
index c06c577..1476767 100644
--- a/README.md
+++ b/README.md
@@ -154,7 +154,7 @@ googleAnalytics = "" # Enable Google Analytics by entering your tracking id
hideNoPostsWarning = false # Don't show no posts empty state warning in main page, if true
[Params.Entry]
- meta = ["date", "categories"] # Enable meta fields in given order
+ meta = ["date", "categories", "tags"] # Enable meta fields in given order
toc = true # Enable Table of Contents
tocOpen = true # Open Table of Contents block. Optional
@@ -247,6 +247,7 @@ related: true # Enable/disable Related content for specific page
meta:
- date
- categories
+ - tags
featured:
url: image.jpg # relative path of the image
alt: A scale model of the Eiffel tower # alternate text for the image
@@ -316,7 +317,7 @@ may activate meta fields with `meta` parameter under the `[Params.Entry]` config
```toml
[Params.Entry]
- meta = ["date", "categories"]
+ meta = ["date", "categories", "tags"]
```
#### Related Content
diff --git a/i18n/en.yaml b/i18n/en.yaml
index 94b9a45..9369024 100644
--- a/i18n/en.yaml
+++ b/i18n/en.yaml
@@ -9,6 +9,9 @@
- id: meta_categories
translation: "Categories"
+- id: meta_tags
+ translation: "Tags"
+
# Share
- id: share-caption
translation: "Share on"
diff --git a/i18n/fr.yaml b/i18n/fr.yaml
index 792bafc..d98eee3 100644
--- a/i18n/fr.yaml
+++ b/i18n/fr.yaml
@@ -9,6 +9,9 @@
- id: meta_categories
translation: "Catégories"
+- id: meta_tags
+ translation: "Mots-clefs"
+
# Share
- id: share-caption
translation: "Partager sur"
diff --git a/i18n/it.yaml b/i18n/it.yaml
index 517a3df..edb11d9 100644
--- a/i18n/it.yaml
+++ b/i18n/it.yaml
@@ -9,6 +9,9 @@
- id: meta_categories
translation: "Categorie"
+- id: meta_tags
+ translation: "Tag"
+
# Share
- id: share-caption
translation: "Condividi su"
diff --git a/i18n/pt-br.yaml b/i18n/pt-br.yaml
index f92f1e4..5f61cc6 100644
--- a/i18n/pt-br.yaml
+++ b/i18n/pt-br.yaml
@@ -9,6 +9,9 @@
- id: meta_categories
translation: "Categorias"
+- id: meta_tags
+ translation: "Tags"
+
# Share
- id: share-caption
translation: "Campartilhar no"
diff --git a/i18n/pt.yaml b/i18n/pt.yaml
index 2012b9c..d1a6362 100644
--- a/i18n/pt.yaml
+++ b/i18n/pt.yaml
@@ -9,6 +9,9 @@
- id: meta_categories
translation: "Categorias"
+- id: meta_tags
+ translation: "Tags"
+
# Share
- id: share-caption
translation: "Campartilhar"
diff --git a/layouts/partials/entry/meta/categories.html b/layouts/partials/entry/meta/categories.html
index c9b353f..7c53849 100644
--- a/layouts/partials/entry/meta/categories.html
+++ b/layouts/partials/entry/meta/categories.html
@@ -1,5 +1,5 @@
{{- if .Params.categories }}
-<span class="entry__meta-categories meta-categories">
+<div class="entry__meta-categories meta-categories">
<span class="meta-categories__list">{{ T "meta_categories" }}:
{{- range $index, $category := .Params.categories }}{{ if gt $index 0 }}, {{ end }}
<a class="meta-categories__link" href="{{ "categories/" | relLangURL }}{{ . | urlize | lower }}/" rel="category">
@@ -7,5 +7,5 @@
</a>
{{- end }}
</span>
-</span>
+</div>
{{- end }} \ No newline at end of file
diff --git a/layouts/partials/entry/meta/tags.html b/layouts/partials/entry/meta/tags.html
new file mode 100644
index 0000000..4841655
--- /dev/null
+++ b/layouts/partials/entry/meta/tags.html
@@ -0,0 +1,11 @@
+{{- if .Params.tags }}
+<div class="entry__meta-tags meta-tags">
+ <span class="meta-tags__list">{{ T "meta_tags" }}:
+ {{- range $index, $category := .Params.tags }}{{ if gt $index 0 }}, {{ end }}
+ <a class="meta-tags__link" href="{{ " tags/" | relLangURL }}{{ . | urlize | lower }}/" rel="tag">
+ {{- . -}}
+ </a>
+ {{- end }}
+ </span>
+</div>
+{{- end }} \ No newline at end of file