mirror of https://github.com/theNewDynamic/gohugo-theme-ananke.git

Bud Parr
12.22.2017 426676fd3c4b8f095d455d5a8748051d0b9e9f2b
page layout [wip]
1 files added
7 files modified
65 ■■■■ changed files
layouts/_default/baseof.html 2 ●●● patch | view | raw | blame | history
layouts/_default/list.html 10 ●●●●● patch | view | raw | blame | history
layouts/_default/single.html 25 ●●●● patch | view | raw | blame | history
layouts/article/summary.html 2 ●●● patch | view | raw | blame | history
layouts/partials/page-header.html 2 ●●● patch | view | raw | blame | history
layouts/partials/site-header.html 2 ●●● patch | view | raw | blame | history
layouts/partials/site-navigation.html 2 ●●● patch | view | raw | blame | history
layouts/partials/summary.html 20 ●●●●● patch | view | raw | blame | history
layouts/_default/baseof.html
@@ -29,7 +29,7 @@
        {{ template "_internal/google_analytics_async.html" . }}
      {{ end }}
  </head>
  <body class="ma0 sans-serif bg-near-white">
  <body class="ma0 sans-serifTK avenir bg-near-white">
    {{ block "header" . }}{{ partial "site-header.html" .}}{{ end }}
    <main class="pb7" role="main">
      {{ block "main" . }}{{ end }}
layouts/_default/list.html
@@ -5,5 +5,13 @@
      {{ .Content }}
    </div>
  </article>
  <!-- w-100 w-40-ns -->
  {{ $section := .Paginate (where .Data.Pages "Section" .Section) }}
  <section class="flex-ns flex-wrap justify-around mt5">
    {{ range sort $section.Pages "Date" "desc"  }}
    {{ partial "summary.html" . }}
    {{ end }}
  </section>
  {{ template "_internal/pagination.html" . }}
{{ end }}
layouts/_default/single.html
@@ -1,14 +1,17 @@
{{ define "header" }}{{ partial "page-header.html" . }}{{ end }}
{{ define "main" }}
{{ $currentPageUrl := .URL }}
{{ $currentSection := where .Site.Pages "Section" .Section }}
{{ $currentSection := (where .Site.Pages "Section" .Section)  }}
<div class="flex flex-wrap">
  <aside class="w-20 pa4 bg-light-silver">
  <aside class="w-2f0 bg-light-gray">
    <ul>
      <li class="list b mb3">
        More {{ .Section }}
      </li>
      {{ range  $currentSection }}
      <li>
        <a href="{{ .URL }}" class="link">
      <li class="list f5 w-100 hover-bg-white nl1">
        <a href="{{ .URL }}" class="link black ph2 pv2 db">
            {{ .Title }}
        </a>
      </li>
@@ -24,9 +27,19 @@
    <h1>
      {{ .Title }} 
    </h1>
    <div class="nested-copy-line-height nested-links nested-img mid-gray measure-wide-l">
        {{ .Content | markdownify }}
    <div class="nested-copy-line-height f4 nested-linkfs nested-img mid-gray measure-wide-l">
        {{ .Content  }}
    </div>
  </article>
</div>
357edd
<style media="screen">
  p a {
    color: #2F6FC4;
          /*#357edd*/
  }
</style>
{{ end }}
layouts/article/summary.html
@@ -1,4 +1,4 @@
<div class="relative w-100 w-40-l mb4 bg-white nested-copy-line-height">
<div class="relative w-100 w-30-l mb4 bg-white nested-copy-line-height">
  <div class="bg-white mb3 pa4 gray overflow-hidden">
    {{ if .Date }}
layouts/partials/page-header.html
@@ -14,7 +14,7 @@
  </header>
{{ else }}
  <header>
    <div class="bg-near-blackTK bg-near-black">
    <div class="bg-near-blackTK bg-black">
      {{ partial "site-navigation.html" . }}
    </div>
  </header>
layouts/partials/site-header.html
@@ -16,7 +16,7 @@
  </header>
{{ else }}
  <header>
    <div class="pb3-m pb6-l bg-near-black">
    <div class="pb3-m pb6-l bg-black">
      {{ partial "site-navigation.html" . }}
      <div class="tc-l pv3 ph3 ph4-ns">
        <h1 class="f2 f-subheadline-l fw2 light-silver mb0 lh-title">
layouts/partials/site-navigation.html
@@ -1,7 +1,7 @@
<nav class="pv3 ph3 ph4-ns" role="navigation">
  <div class="flex-ns justify-between items-center">
    <a href="/" class="f3 fw8 hover-white no-underline white-90 dib">
    <a href="/" class="f3 fw2 hover-white no-underline white-90 dib">
      {{ .Site.Title }}
    </a>
    {{ if .Site.Menus.main }}
layouts/partials/summary.html
New file
@@ -0,0 +1,20 @@
<div class="relative w-100 mb4 bg-white nested-copy-line-height">
  <div class="bg-white mb3 pa4 gray overflow-hidden">
    <h1 class="f3 near-black">
      <a href="{{ .URL }}" class="link black dim">
        {{ .Title }}
      </a>
    </h1>
    <div class="nested-links f5 nested-copy-line-height">
      <p>
        {{ .Summary  }}
      </p>
    </div>
  </div>
</div>