Add all tags to output

This commit is contained in:
Simon Detheridge 2023-10-18 12:39:54 +01:00
parent be9686d40e
commit 693bc08e61
Signed by: simon
GPG Key ID: 38640971DA1E704E
6 changed files with 37 additions and 21 deletions

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -66,9 +66,9 @@ production stylesheet in assets/built/screen.css
--color-border: rgb(0 0 0 / 0.08);
--color-dark-border: rgb(0 0 0 / 0.5);
--font-sans: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", "Roboto", "Oxygen", "Ubuntu", "Cantarell", "Fira Sans", "Droid Sans", "Helvetica Neue", sans-serif, "Font Awesome 6 Free", "Font Awesome 6 Brands";
--font-serif: "EB Garamond", Georgia, Times, serif;
--font-serif-alt: Georgia, Times, serif;
--font-mono: "JetBrains Mono", Menlo, Consolas, Monaco, "Liberation Mono", "Lucida Console", monospace;
--font-serif: "EB Garamond", Georgia, Times, serif, "Font Awesome 6 Free", "Font Awesome 6 Brands";
--font-serif-alt: Georgia, Times, serif, "Font Awesome 6 Free", "Font Awesome 6 Brands";
--font-mono: "JetBrains Mono", Menlo, Consolas, Monaco, "Liberation Mono", "Lucida Console", monospace, "Font Awesome 6 Free", "Font Awesome 6 Brands";
--container-width: 1320px;
--container-gap: clamp(24px, 1.7032rem + 1.9355vw, 48px);
--grid-gap: 42px;
@ -974,12 +974,10 @@ Search LOGO Login Subscribe
}
.gh-card-tag {
display: none;
margin-bottom: 4px;
font-size: 1.2rem;
font-weight: 500;
letter-spacing: 0.01em;
text-transform: uppercase;
}
.gh-card-title {
@ -1020,6 +1018,10 @@ Search LOGO Login Subscribe
margin-top: 12px;
}
.gh-card-wrapper > .gh-card-meta:not(:empty) ~ .gh-card-meta:not(:empty) {
margin-top: 7px;
}
.gh-card-author + .gh-card-date::before {
content: "—";
margin-right: 4px;
@ -1972,15 +1974,24 @@ Search LOGO Login Subscribe
.gh-article-header {
margin: clamp(40px, 3.64vw + 25.45px, 72px) 0 40px;
}
.gh-article-tags {
}
.gh-article-tag {
margin-bottom: 12px;
font-size: 1.3rem;
font-weight: 500;
letter-spacing: 0.01em;
text-transform: uppercase;
padding-right: 1em;
color: var(--ghost-accent-color);
}
.gh-article-tag::before {
content: " ";
font-weight: 900;
font-size: 0.8em;
padding-right: 0.3em;
}
.gh-article-title {
font-size: calc(clamp(3.4rem, 1.36vw + 2.85rem, 4.6rem) * var(--factor, 1));

View File

@ -23,7 +23,7 @@
{{#match @custom.header_style "Highlight"}}
{{#if @custom.show_featured_posts}}
{{#match posts.length ">=" 4}}
{{#get "posts" include="authors" limit="16"}}
{{#get "posts" include="authors,tags" limit="16"}}
{{#foreach posts from="5" limit="12"}}
{{> "post-card" lazyLoad=true}}
{{/foreach}}
@ -31,7 +31,7 @@
{{/match}}
{{else}}
{{#match posts.length ">=" 10}}
{{#get "posts" include="authors" limit="22"}}
{{#get "posts" include="authors,tags" limit="22"}}
{{#foreach posts from="11" limit="12"}}
{{> "post-card" lazyLoad=true}}
{{/foreach}}
@ -40,14 +40,14 @@
{{/if}}
{{else match @custom.header_style "Magazine"}}
{{#match posts.length ">=" 7}}
{{#get "posts" include="authors" limit="19"}}
{{#get "posts" include="authors,tags" limit="19"}}
{{#foreach posts from="8" limit="12"}}
{{> "post-card" lazyLoad=true}}
{{/foreach}}
{{/get}}
{{/match}}
{{else}}
{{#get "posts" include="authors" limit="12"}}
{{#get "posts" include="authors,tags" limit="12"}}
{{#foreach posts}}
{{> "post-card" lazyLoad=true}}
{{/foreach}}
@ -58,7 +58,7 @@
{{!-- All posts --}}
{{#match feed "index"}}
{{#match pagination.page 2}}
{{#get "posts" include="authors" limit=@config.posts_per_page as |recent|}}
{{#get "posts" include="authors,tags" limit=@config.posts_per_page as |recent|}}
{{#foreach recent}}
{{> "post-card"}}
{{/foreach}}

View File

@ -17,9 +17,6 @@
</figure>
{{/if}}
<div class="gh-card-wrapper">
{{#if primary_tag}}
<p class="gh-card-tag">{{primary_tag.name}}</p>
{{/if}}
<h3 class="gh-card-title is-title">{{title}}</h3>
{{#if excerpt}}
<p class="gh-card-excerpt is-body">{{excerpt}}</p>
@ -31,6 +28,15 @@
{{#if @custom.show_publish_date}}
<time class="gh-card-date" datetime="{{date format="YYYY-MM-DD"}}">{{date}}</time>
{{/if}}<!--
--></footer>
<footer class="gh-card-meta"><!--
--><div class="gh-card-tags">
Filed under:
{{#foreach tags}}
{{#if @index}}, {{/if}}
<span class="gh-card-tag">{{name}}</span>
{{/foreach}}
</div><!--
--></footer>
</div>
</a>

View File

@ -9,13 +9,12 @@
<header class="gh-article-header gh-canvas">
{{#if primary_tag}}
<a class="gh-article-tag" href="{{primary_tag.url}}">{{primary_tag.name}}</a>
{{/if}}
<div class="gh-article-tags">
{{#foreach tags}}
<a class="gh-article-tag" href="{{url}}">{{name}}</a>
{{/foreach}}
</div>
<h1 class="gh-article-title is-title">{{title}}</h1>
{{#if custom_excerpt}}
<p class="gh-article-excerpt is-body">{{custom_excerpt}}</p>
{{/if}}
<div class="gh-article-meta">
<div class="gh-article-author-image">