head.ejs 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="utf-8">
  5. <%
  6. var title = page.title;
  7. if (is_archive()) {
  8. title = __('index.archive');
  9. if (is_month()) {
  10. title += ': ' + page.year + '/' + page.month;
  11. } else if (is_year()) {
  12. title += ': ' + page.year;
  13. }
  14. } else if (is_category()) {
  15. title = __('index.category') + ': ' + page.category;
  16. } else if (is_tag()) {
  17. title = __('index.tag') + ': ' + page.tag;
  18. }
  19. %>
  20. <title><% if (title) { %><%= title %> | <% } %><%= config.title %></title>
  21. <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1" />
  22. <%- open_graph({
  23. image: thumbnail(page),
  24. fb_app_id: theme.miscellaneous.open_graph.fb_app_id,
  25. fb_admins: theme.miscellaneous.open_graph.fb_admins,
  26. twitter_id: theme.miscellaneous.open_graph.twitter_id,
  27. google_plus: theme.miscellaneous.open_graph.google_plus,
  28. }) %>
  29. <% if (theme.rss) { %>
  30. <link rel="alternative" href="<%- theme.rss %>" title="<%= config.title %>" type="application/atom+xml" />
  31. <% } %>
  32. <% if (theme.customize.favicon) { %>
  33. <link rel="icon" href="<%- url_for(theme.customize.favicon) %>" />
  34. <% } %>
  35. <%- css('vendor/font-awesome/css/font-awesome.min') %>
  36. <%- css('vendor/open-sans/styles') %>
  37. <%- css('vendor/source-code-pro/styles') %>
  38. <%- css('css/style') %>
  39. <%- js('vendor/jquery/2.1.3/jquery.min') %>
  40. <%- partial('plugin/scripts', { isHead: true }) %>
  41. </head>