Skip to content

Commit

Permalink
Fix issue 302 (#304)
Browse files Browse the repository at this point in the history
  • Loading branch information
MyGiHu authored Jul 24, 2021
1 parent 1ed3af8 commit 73ba592
Showing 1 changed file with 20 additions and 23 deletions.
43 changes: 20 additions & 23 deletions layouts/partials/home/projects.html
Original file line number Diff line number Diff line change
Expand Up @@ -65,32 +65,29 @@ <h1 class="modal-card-title has-text-centered">{{ . }}</h1>
{{ end }}
{{ if .Params.project_timeframe }}
<p class="fa-xs">{{ .Params.project_timeframe }}</p>
{{ end }}
{{ with .Resources.ByType "image" }}
{{ $moreThenOneImage := gt (len .) 1 }}
{{ if $moreThenOneImage }}
<div class="owl-carousel owl-theme">
{{ end }}
{{ range sort . "Params.weight" }}
{{ $image := .Resize "640x" }}
{{ if $moreThenOneImage }}
<div class="item owl-height">
{{ end }}
<img src="{{ $image.Permalink }}" class="img-responsive" alt="{{ $image.Name }}">
{{ if $moreThenOneImage }}
</div>
{{ end }}
<section class="modal-card-body markdown">
{{ with .Resources.ByType "image" }}
{{ $moreThenOneImage := gt (len .) 1 }}
{{ if $moreThenOneImage }}
<div class="owl-carousel owl-theme">
{{ end }}
{{ range sort . "Params.weight" }}
{{ $image := .Resize "640x" }}
{{ if $moreThenOneImage }}
<div class="item owl-height">
{{ end }}
<img src="{{ $image.Permalink }}" class="img-responsive" alt="{{ $image.Name }}">
{{ if $moreThenOneImage }}
</div>
{{ end }}
{{ end }}
{{ if $moreThenOneImage }}
</div>
{{ end }}
{{ if $moreThenOneImage }}
</div>
{{ end }}
{{ end }}

{{ with .Content }}
<section class="modal-card-body markdown">
{{ . }}
{{ end }}
{{ .Content }}
</section>
{{ end }}
</div>
<button class="modal-close is-large" aria-label="close" data-target="#project-{{ $index }}"></button>
</div>
Expand Down

0 comments on commit 73ba592

Please sign in to comment.