_includes/header.html in sutty-minima-2.7.0rc3 vs _includes/header.html in sutty-minima-2.7.0rc6

- old
+ new

@@ -1,14 +1,24 @@ +{%- assign pages = site.posts | where: "layout", "page" -%} +{%- assign about = site.posts | find: 'layout', 'about' -%} + <header class="site-header"> <div class="wrapper"> - {%- assign default_paths = site.pages | map: "path" -%} - {%- assign page_paths = site.header_pages | default: default_paths -%} - {%- assign titles_size = site.pages | map: 'title' | join: '' | size -%} - <a class="site-title" rel="author" href="?#">{{ site.title | escape }}</a> - {%- if titles_size > 0 -%} + {% if about.logo.path %} + <a href="?#"> + <img + class="h-54" + src="{{ about.logo.path | thumbnail: nil, 54 | uri_escape }}" + alt="{{ about.logo.description | escape }}" /> + </a> + {% else %} + <a class="site-title" rel="author" href="?#">{{ site.title | escape }}</a> + {% endif %} + + {%- if pages.size > 0 -%} <nav class="site-nav"> <input type="checkbox" id="nav-trigger" class="nav-trigger" /> <label for="nav-trigger"> <span class="menu-icon"> <svg viewBox="0 0 18 15" width="18px" height="15px"> @@ -16,14 +26,11 @@ </svg> </span> </label> <div class="trigger"> - {%- for path in page_paths -%} - {%- assign my_page = site.pages | where: "path", path | first -%} - {%- if my_page.title -%} - <a class="page-link" href="{{ my_page.url }}">{{ my_page.title | escape }}</a> - {%- endif -%} + {%- for page in pages -%} + <a class="page-link" href="{{ page.url | uri_escape }}">{{ page.title | escape }}</a> {%- endfor -%} </div> </nav> {%- endif -%} </div>