Compare commits

...

1 Commits

Author SHA1 Message Date
ecfa3cd2c8 Add support to add blog entries on index 2023-11-17 21:00:46 -06:00
2 changed files with 36 additions and 1 deletions

View File

@@ -4,10 +4,12 @@
{{ partial "counter.html" . }} {{ partial "counter.html" . }}
{{ partial "blog.html" . }}
{{ partial "portfolio.html" . }} {{ partial "portfolio.html" . }}
{{ partial "testimonial.html" . }} {{ partial "testimonial.html" . }}
{{ partial "call-to-action.html" . }} {{ partial "call-to-action.html" . }}
{{ end }} {{ end }}

View File

@@ -0,0 +1,33 @@
{{ with .Site.Params.Blog }}
{{ if .enable }}
<section class="site-project" id="project">
<div class="container">
<div class="row">
<div class="col-12">
<div class="section-title">
<h2>{{ .title }}</h2>
<p>{{ .subtitle }}</p>
</div>
</div>
{{ range first 4 (where $.Site.RegularPages "Type" "blog") }}
<div class="col-lg-6 col-md-10 mx-auto">
<div class="site-project-item">
<div class="site-project-item-thumb">
<img src="{{ .Params.Image | absURL }}" alt="project-thumb">
</div>
<div class="site-project-item-content">
<span>{{ delimit .Params.category ", " }}</span>
<h3>{{ .Title }}</h3>
<a href="{{ .Permalink }}" class="read-more">{{ .Site.Params.blog.view_entry }}</a>
</div>
</div>
</div>
{{ end }}
<div class="col-12 text-center text-lg-left">
<a href="blog" class="site-project-cta">{{ .Site.Params.blog.read_more }}</a>
</div>
</div>
</div>
</section>
{{ end }}
{{ end }}