Make home page sections dynamic and configurable

This commit is contained in:
hossainemruz 2020-06-28 22:23:33 +06:00
parent 8f99f05a98
commit 9a95163b7d
17 changed files with 227 additions and 177 deletions

View file

@ -1,21 +1,19 @@
<div class="container-fluid projects bg-dimmed anchor pb-5" id="projects">
{{ if .Site.Data.projects }}
<h1 class="text-center">Projects</h1>
<div class="container ml-auto text-center">
<div class="btn-group flex-wrap" role="group" id="project-filter-buttons">
{{ range .Site.Data.projects.buttons }}
<button type="button" class="btn btn-dark" data-filter="{{ .filter }}">
{{ .name }}
</button>
{{ end }}
</div>
<div class="container-fluid anchor pb-5" id="projects">
<h1 class="text-center">{{ .section.name }}</h1>
<div class="container ml-auto text-center">
<div class="btn-group flex-wrap" role="group" id="project-filter-buttons">
{{ range .buttons }}
<button type="button" class="btn btn-dark" data-filter="{{ .filter }}">
{{ .name }}
</button>
{{ end }}
</div>
<div class="container filtr-projects">
<div class="row" id="project-card-holder">
{{ range .Site.Data.projects.projects }}
{{ partial "cards/project" . }}
{{ end }}
</div>
</div>
<div class="container filtr-projects">
<div class="row" id="project-card-holder">
{{ range .projects }}
{{ partial "cards/project" . }}
{{ end }}
</div>
{{ end }}
</div>
</div>