|
|
|
@ -29,9 +29,15 @@ |
|
|
|
{{if .NewestBlogItem}} |
|
|
|
{{if .NewestBlogItem}} |
|
|
|
<div class="feature-image-container"> |
|
|
|
<div class="feature-image-container"> |
|
|
|
{{$item := .NewestBlogItem}} |
|
|
|
{{$item := .NewestBlogItem}} |
|
|
|
{{if $item.Image}} |
|
|
|
{{$profile := index $.Profiles $item.Author}} |
|
|
|
|
|
|
|
{{$image := "/static/GitCitadel_Icon_Gradient.svg"}} |
|
|
|
|
|
|
|
{{if and $item.Image (ne $item.Image "")}} |
|
|
|
|
|
|
|
{{$image = $item.Image}} |
|
|
|
|
|
|
|
{{else if and $profile $profile.Picture (ne $profile.Picture "")}} |
|
|
|
|
|
|
|
{{$image = $profile.Picture}} |
|
|
|
|
|
|
|
{{end}} |
|
|
|
<div class="feature-image-wrapper"> |
|
|
|
<div class="feature-image-wrapper"> |
|
|
|
<img src="{{$item.Image}}" alt="{{$item.Title}}" class="feature-image"> |
|
|
|
<img src="{{$image}}" alt="{{$item.Title}}" class="feature-image"> |
|
|
|
<div class="feature-image-overlay"> |
|
|
|
<div class="feature-image-overlay"> |
|
|
|
<h4 class="feature-image-title">{{$item.Title}}</h4> |
|
|
|
<h4 class="feature-image-title">{{$item.Title}}</h4> |
|
|
|
{{if $item.Summary}} |
|
|
|
{{if $item.Summary}} |
|
|
|
@ -39,20 +45,6 @@ |
|
|
|
{{end}} |
|
|
|
{{end}} |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
{{else}} |
|
|
|
|
|
|
|
{{$profile := index $.Profiles $item.Author}} |
|
|
|
|
|
|
|
{{if $profile.Picture}} |
|
|
|
|
|
|
|
<div class="feature-image-wrapper"> |
|
|
|
|
|
|
|
<img src="{{$profile.Picture}}" alt="{{$item.Title}}" class="feature-image"> |
|
|
|
|
|
|
|
<div class="feature-image-overlay"> |
|
|
|
|
|
|
|
<h4 class="feature-image-title">{{$item.Title}}</h4> |
|
|
|
|
|
|
|
{{if $item.Summary}} |
|
|
|
|
|
|
|
<p class="feature-image-summary">{{truncate $item.Summary 250}}</p> |
|
|
|
|
|
|
|
{{end}} |
|
|
|
|
|
|
|
</div> |
|
|
|
|
|
|
|
</div> |
|
|
|
|
|
|
|
{{end}} |
|
|
|
|
|
|
|
{{end}} |
|
|
|
|
|
|
|
</div> |
|
|
|
</div> |
|
|
|
{{end}} |
|
|
|
{{end}} |
|
|
|
<div class="feature-card-content"> |
|
|
|
<div class="feature-card-content"> |
|
|
|
@ -66,9 +58,15 @@ |
|
|
|
{{if .NewestArticleItem}} |
|
|
|
{{if .NewestArticleItem}} |
|
|
|
<div class="feature-image-container"> |
|
|
|
<div class="feature-image-container"> |
|
|
|
{{$item := .NewestArticleItem}} |
|
|
|
{{$item := .NewestArticleItem}} |
|
|
|
{{if $item.Image}} |
|
|
|
{{$profile := index $.Profiles $item.Author}} |
|
|
|
|
|
|
|
{{$image := "/static/GitCitadel_Icon_Gradient.svg"}} |
|
|
|
|
|
|
|
{{if and $item.Image (ne $item.Image "")}} |
|
|
|
|
|
|
|
{{$image = $item.Image}} |
|
|
|
|
|
|
|
{{else if and $profile $profile.Picture (ne $profile.Picture "")}} |
|
|
|
|
|
|
|
{{$image = $profile.Picture}} |
|
|
|
|
|
|
|
{{end}} |
|
|
|
<div class="feature-image-wrapper"> |
|
|
|
<div class="feature-image-wrapper"> |
|
|
|
<img src="{{$item.Image}}" alt="{{$item.Title}}" class="feature-image"> |
|
|
|
<img src="{{$image}}" alt="{{$item.Title}}" class="feature-image"> |
|
|
|
<div class="feature-image-overlay"> |
|
|
|
<div class="feature-image-overlay"> |
|
|
|
<h4 class="feature-image-title">{{$item.Title}}</h4> |
|
|
|
<h4 class="feature-image-title">{{$item.Title}}</h4> |
|
|
|
{{if $item.Summary}} |
|
|
|
{{if $item.Summary}} |
|
|
|
@ -76,20 +74,6 @@ |
|
|
|
{{end}} |
|
|
|
{{end}} |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
{{else}} |
|
|
|
|
|
|
|
{{$profile := index $.Profiles $item.Author}} |
|
|
|
|
|
|
|
{{if $profile.Picture}} |
|
|
|
|
|
|
|
<div class="feature-image-wrapper"> |
|
|
|
|
|
|
|
<img src="{{$profile.Picture}}" alt="{{$item.Title}}" class="feature-image"> |
|
|
|
|
|
|
|
<div class="feature-image-overlay"> |
|
|
|
|
|
|
|
<h4 class="feature-image-title">{{$item.Title}}</h4> |
|
|
|
|
|
|
|
{{if $item.Summary}} |
|
|
|
|
|
|
|
<p class="feature-image-summary">{{truncate $item.Summary 250}}</p> |
|
|
|
|
|
|
|
{{end}} |
|
|
|
|
|
|
|
</div> |
|
|
|
|
|
|
|
</div> |
|
|
|
|
|
|
|
{{end}} |
|
|
|
|
|
|
|
{{end}} |
|
|
|
|
|
|
|
</div> |
|
|
|
</div> |
|
|
|
{{end}} |
|
|
|
{{end}} |
|
|
|
<div class="feature-card-content"> |
|
|
|
<div class="feature-card-content"> |
|
|
|
|