Added tags to posts

This commit is contained in:
Sharwin Patil 2025-01-20 23:17:26 -06:00
parent 6730553ccc
commit bdf2912487
4 changed files with 19 additions and 2 deletions

View file

@ -1,3 +1,13 @@
.github-button {
text-align: center;
background-color: transparent;
border: 1px solid transparent;
border-radius: 0.25rem;
color: get-light-color('muted-text-color');
background-color: get-light-color('bg-card');
}
body.kind-page {
background-color: get-light-color('bg-secondary');
position: relative;

View file

@ -127,6 +127,7 @@ params:
maxVisibleSections: 5
# Enable and configure blog posts
# site.Params.features.tags.enable
features:
readingTime:
enable: true
@ -134,6 +135,8 @@ params:
title: "Project Posts"
enable: true
showAuthor: true
tags:
enable: true
analytics:
enabled: true
services:

View file

@ -62,6 +62,11 @@
{{ if site.Params.features.tags.enable }}
{{partial "misc/tags.html" .Params.tags }}
{{ end }}
<!-- <div class="github-button">
<a href="https://github.com/Sharwin24/" target="_blank" class="btn btn-primary">
<i class="fab fa-github"></i> View on GitHub
</a>
</div> -->
<div class="post-content" id="post-content">
{{ .Page.Content }}
</div>

View file

@ -1,8 +1,7 @@
<div class="tags">
<ul style="padding-left: 0;">
{{ range . }}
{{ $url:= printf "tags/%s/" . }}
<li class="rounded"><a href="{{ $url | urlize | relLangURL }}" class="btn btn-sm btn-info">{{ . }}</a></li>
<li class="rounded"><a class="btn btn-sm btn-info">{{ . }}</a></li>
{{ end }}
</ul>
</div>