This repository has been archived on 2024-04-08. You can view files and clone it, but cannot push or open issues or pull requests.
spdocker/themes/spd/layout/_partial/header.ejs

57 lines
2.0 KiB
Plaintext
Raw Normal View History

2018-03-07 04:58:54 +00:00
<!-- Modified by Yu-Hsuan Yen -->
<!-- Post Header -->
<style type="text/css">
header.intro-header{
<% if (is_home()) { %>
background-image: url('<%= config.root + config["header-img"] %>')
/*config*/
<%} else if (is_post()){%>
background-image: url('<%= page["header-img"] %>')
/*post*/
<%} else {%>
background-image: url('<%= config.root + page["header-img"] %>')
/*page*/
<%} %>
}
<% if (config.signature) {%>
#signature{
background-image: url('<%= config.root + config["signature-img"] %>');
}
<%}%>
</style>
<header class="intro-header" >
<!-- Signature -->
<div id="signature">
<div class="container">
<div class="row">
<div class="col-lg-8 col-lg-offset-2 col-md-10 col-md-offset-1">
<% if (is_post()) { %>
<div class="post-heading">
<div class="tags">
<% page.tags.forEach(function(tag){ %>
<a class="tag" href="<%= config.root %>tags/#<%= tag.name %>" title="<%= tag.name %>"><%= tag.name %></a>
<% }) %>
</div>
<h1><%= page.title %></h1>
<h2 class="subheading"><%= page.subtitle || "" %></h2>
<span class="meta">
Posted by <%- page.author || config.author %> on
<%= page.date.format(config.date_format) %>
</span>
</div>
<% } else { %>
<div class="site-heading">
<h1><%= page.title || config.title %></h1>
<!--<hr class="small">-->
<span class="subheading"><%= page.description || config.subtitle || "" %></span>
</div>
<% } %>
</div>
</div>
</div>
</div>
</header>