aboutsummaryrefslogblamecommitdiff
path: root/layouts/index.html
blob: 014561c2ea30e2a3c9537b65c810ee46ad844125 (plain) (tree)
1
2
3
4
5
6
7
8
9


                       
                                                          



                                                   
                                                                       
                              
                                                                                                             

                     
                                                          













                                                                                          
{{ define "main" }}
<div class="container">
    <div class="row">
        <div class="col-xs-12 col-sm-12 col-md-4 sidebar">
            {{ if .Title }}
                <h1 class="post-title fw-semibold">
                    {{ .Title }}
                </h1>
                <img src="{{.Site.Params.Logo}}" alt="{{.Site.Title}}">
                {{ .Content }}
                <a href="/feed/" class="btn btn-primary">{{ partial "icon.html" "rss" }} Подписка</a>
            {{ end }}
        </div>
        <div class="col-xs-12 col-sm-12 col-md-8 content">
            {{ $pages := where .Site.RegularPages "Type" "in" .Site.Params.mainSections }}
            {{ $notHidden := where .Site.RegularPages "Params.hidden" "!=" true }}
            {{ $filtered := ($pages | intersect $notHidden) }}
            {{ $pag := .Paginate ($filtered) }}

            {{ $paginator := .Paginate .Pages 7 }}
            {{ range $paginator.Pages }}
            {{ partial "list.html" . }}
            {{ end }}
            <nav>{{ partial "pagination.html" . }}</nav>
        </div>
    </div>
</div>
{{ end }}