add latest version on top of single spec page

Signed-off-by: Toshaan Bharvani <toshaan@vantosh.com>
remotes/1720744104865095624/master
Toshaan Bharvani 4 years ago
parent ac9b4fc7f5
commit 73c67c0d66

@ -2,6 +2,9 @@


{{ partial "navbar.html" . }} {{ partial "navbar.html" . }}


{{ $filename := .File.BaseFileName }}
{{ $datafile := index $.Site.Data.specifications $filename }}

<main id="main"> <main id="main">


<section id="page" class="section-bg"> <section id="page" class="section-bg">
@ -11,6 +14,19 @@
<p class="section-description"></p> <p class="section-description"></p>
<span class="section-divider"></span> <span class="section-divider"></span>
</div> </div>
<div class="row">
<div class="col-lg-2">&nbsp;</div>
<div class="col-lg-4">
{{ if $datafile.versions }}
{{ range last 1 $datafile.versions }}
Latest version {{ .number }}
{{ end }}
{{ end }}
</div>
<div class="col-lg-4">
</div>
<div class="col-lg-2">&nbsp;</div>
</div>
<div class="row"> <div class="row">
<div class="col-lg-2">&nbsp;</div> <div class="col-lg-2">&nbsp;</div>
<div class="col-lg-8 content wow fadeInTop"> <div class="col-lg-8 content wow fadeInTop">
@ -25,8 +41,7 @@
{{ end }} {{ end }}
</div> </div>
</div> </div>
{{ $filename := .File.BaseFileName }}
{{ $datafile := index $.Site.Data.specifications $filename }}
{{ if $datafile.versions }} {{ if $datafile.versions }}
<div class="row"> <div class="row">
<div class="col-lg-12"> <div class="col-lg-12">

Loading…
Cancel
Save