50 lines
1.8 KiB
JavaScript
50 lines
1.8 KiB
JavaScript
<!DOCTYPE html>
|
|
|
|
<% if (config.language){ %>
|
|
<html lang="<%= config.language %>">
|
|
<% } else { %>
|
|
<html lang="en">
|
|
<% }%>
|
|
|
|
<head>
|
|
<meta charset="utf-8" />
|
|
<% var title = page.title; if (is_archive()) { title = __('archive_a'); if
|
|
(is_month()) { title += ': ' + page.year + '/' + page.month; } else if
|
|
(is_year()) { title += ': ' + page.year; } } else if (is_category()) {
|
|
title = page.category; } else if (is_tag()) { title = __('tag') + ': ' +
|
|
page.tag; } %> <% if (page.keywords){ %>
|
|
<meta
|
|
name="keywords"
|
|
content="<%= page.keywords %>,<%= config.keywords %>"
|
|
/>
|
|
<% } else if (config.keywords){ %>
|
|
<meta name="keywords" content="<%= config.keywords %>" />
|
|
<% } %> <% if (page.description){ %>
|
|
<meta name="description" content="<%= page.description %>" />
|
|
<% } else if (config.description){ %>
|
|
<meta name="description" content="<%= config.description %>" />
|
|
<% } %>
|
|
<meta
|
|
name="viewport"
|
|
content="width=device-width, initial-scale=1, maximum-scale=1"
|
|
/>
|
|
<title><% if (title){ %><%= title %> | <% } %> <%= config.title %></title>
|
|
<% if (theme.favicon){ %>
|
|
<link rel="shortcut icon" href="<%- theme.favicon %>" />
|
|
<% } %> <%- css('dist/main') %>
|
|
<link
|
|
rel="stylesheet"
|
|
href="https://cdn.jsdelivr.net/gh/Shen-Yu/cdn/css/remixicon.min.css"
|
|
/>
|
|
<%- css('css/custom') %> <% if (theme.progressBar){ %>
|
|
<script src="https://cdn.jsdelivr.net/npm/pace-js@1.0.2/pace.min.js"></script>
|
|
<% } %> <%- partial('google-analytics') %> <%- partial('baidu-analytics')
|
|
%>
|
|
<!-- mermaid -->
|
|
<% if (theme.mermaid.enable) { %>
|
|
<script src="<%= theme.mermaid.cdn %>"></script>
|
|
<% } %>
|
|
</head>
|
|
</html>
|
|
</html>
|