fix(layout): move 'Newer'/'Older' out of <a>

This commit is contained in:
MDLeom 2020-12-06 11:57:22 +00:00
parent 5a2994cff1
commit 005c3419d4
No known key found for this signature in database
GPG Key ID: 32D3E28E96A695E8
1 changed files with 17 additions and 17 deletions

View File

@ -1,26 +1,26 @@
<% if (post.prev || post.next) { %> <% if (post.prev || post.next) { %>
<nav id="article-nav" class="article-nav"> <nav id="article-nav" class="article-nav">
<% if (post.prev) { %> <span class="article-nav-link-wrap newer">
<a href="<%- url_for(post.prev.path) %>" id="article-nav-newer" class="article-nav-link-wrap newer"> <% if (post.prev) { %>
<strong class="article-nav-caption"><%= __('newer') %></strong> <strong><%= __('newer') %></strong>
<a href="<%- url_for(post.prev.path) %>">
<div class="article-nav-title"> <div class="article-nav-title">
<% if (post.prev.title) { %> <% if (post.prev.title) { %>
<%= post.prev.title %> <%= post.prev.title %>
<% } else { %> <% } else { %>
(no title) (no title)
<% } %> <% } %>
</div> </div>
</a> </a>
<% } else { %> <% } %>
<span id="article-nav-newer" class="article-nav-link-wrap newer"></span> </span>
<% } %> <span class="article-nav-link-wrap older">
<% if (post.next) { %> <% if (post.next) { %>
<a href="<%- url_for(post.next.path) %>" id="article-nav-older" class="article-nav-link-wrap older"> <strong><%= __('older') %></strong>
<strong class="article-nav-caption"><%= __('older') %></strong> <a href="<%- url_for(post.next.path) %>">
<div class="article-nav-title"><%= post.next.title %></div> <div class="article-nav-title"><%= post.next.title %></div>
</a> </a>
<% } else { %> <% } %>
<span id="article-nav-older" class="article-nav-link-wrap older"></span> </span>
<% } %>
</nav> </nav>
<% } %> <% } %>