You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

144 lines
5.5 KiB

1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
  1. <!DOCTYPE html>
  2. <html lang="en">
  3. <head>
  4. <!-- Bing & Google Site Index-->
  5. <meta name="google-site-verification" content="B4hZCJh4Uz6qdaXiH65DRXUpjVTHBcblzZaXZjUo7AE" />
  6. <meta name="msvalidate.01" content="1C56B1EC58ADE4A5D59E7AF88A8AFE99" />
  7. <!-- Basic Page Needs
  8. –––––––––––––––––––––––––––––––––––––––––––––––––– -->
  9. <meta charset="utf-8">
  10. <%
  11. if (!config.author) {
  12. config.author = ""
  13. }
  14. var title = title = config.title;
  15. if (is_archive()){
  16. title = 'All Posts - ' + config.author;
  17. } else if (is_post()){
  18. title = page.title;
  19. } else if (is_page()){
  20. title = page.title + ' - ' + config.author;
  21. } else if (is_tag()){
  22. title = 'Posts Related to ' + page.tag;
  23. }
  24. %>
  25. <title><%= title %></title>
  26. <% if (config.sitemap) { %>
  27. <link rel="sitemap" href="<%-config.url + config.sitemap.path %>" />
  28. <% } %>
  29. <link rel="canonical" href="<%= url.replace(/index\.html$/, '').replace(/index\.html$/, '') %>">
  30. <% if (is_page()){ %>
  31. <meta name="description" content="<%= page.description %>">
  32. <% } else if (page.content){ %>
  33. <meta name="description" content="<%= strip_html(page.content).replace(/\n/g, " ").replace(/^\s*/, '').replace(/\s*$/, '').substring(0, 150) %>">
  34. <% } else { %>
  35. <meta name="description" content="<%= config.description %>">
  36. <% } %>
  37. <% if (config.keywords) { %>
  38. <meta name="keywords" content="<%= config.keywords %>">
  39. <% } %>
  40. <meta name="author" content="<%- config.author %>">
  41. <% if (is_post() || is_page()) { %>
  42. <meta property="og:image" content="<%-config.url + page.thumbnail %>">
  43. <% } else { %>
  44. <meta property="og:image" content="<%-config.url + theme.thumbnail %>">
  45. <% } %>
  46. <meta property="og:site_name" content="<%= config.title %>" />
  47. <meta property="og:type" content="article" />
  48. <meta property="og:title" content="<%= title %>" />
  49. <% if (is_page()){ %>
  50. <meta property="og:description" content="<%= page.description %>">
  51. <% } else if (page.content){ %>
  52. <meta property="og:description" content="<%= strip_html(page.content).replace(/\n/g, " ").replace(/^\s*/, '').replace(/\s*$/, '').substring(0, 150) %>">
  53. <% } else { %>
  54. <meta property="og:description" content="<%= config.description %>">
  55. <% } %>
  56. <meta property="og:url" content="<%= url.replace(/index\.html$/, '').replace(/index\.html$/, '') %>" />
  57. <meta name="twitter:card" content="summary_large_image">
  58. <meta name="twitter:title" content="<%= title %>">
  59. <% if (is_page()){ %>
  60. <meta name="twitter:description" content="<%= page.description %>">
  61. <% } else if (page.content){ %>
  62. <meta name="twitter:description" content="<%= strip_html(page.content).replace(/\n/g, " ").replace(/^\s*/, '').replace(/\s*$/, '').substring(0, 150) %>">
  63. <% } else { %>
  64. <meta name="twitter:description" content="<%= config.description %>">
  65. <% } %>
  66. <% if (is_post() || is_page()) { %>
  67. <meta name="twitter:image" content="<%-config.url + page.thumbnail %>">
  68. <% } else { %>
  69. <meta name="twitter:image" content="<%-config.url + theme.thumbnail %>">
  70. <% } %>
  71. <meta name="twitter:url" content="<%= url.replace(/index\.html$/, '').replace(/index\.html$/, '') %>" />
  72. <!-- Mobile Specific Metas
  73. –––––––––––––––––––––––––––––––––––––––––––––––––– -->
  74. <meta name="viewport" content="width=device-width, initial-scale=1">
  75. <!-- Preload fonts
  76. –––––––––––––––––––––––––––––––––––––––––––––––––– -->
  77. <link rel="preload" href="../fonts/dm-serif-display-v4-latin-regular.woff2" as="font" type="font/woff2" crossorigin>
  78. <link rel="preload" href="../fonts/inter-v2-latin-regular.woff2" as="font" type="font/woff2" crossorigin>
  79. <!-- CSS
  80. –––––––––––––––––––––––––––––––––––––––––––––––––– -->
  81. <%- css('css/normalize.css') %>
  82. <%- css('css/skeleton.css') %>
  83. <%- css('css/custom.css') %>
  84. <%- css('css/prism-dark.css') %>
  85. <%- css('css/prism-line-numbers.css') %>
  86. <!-- User css -->
  87. <% if (theme.usercss) { %>
  88. <%- css(theme.usercss) %>
  89. <% } %>
  90. <!-- Favicon
  91. –––––––––––––––––––––––––––––––––––––––––––––––––– -->
  92. <link rel="icon" type="image/png" href="<%- theme.favicon %>">
  93. <!-- Custom Theme Color Style
  94. –––––––––––––––––––––––––––––––––––––––––––––––––– -->
  95. <%- partial('partial/tcolor') %>
  96. <!-- Google Analytics (With Privacy Settings On)
  97. –––––––––––––––––––––––––––––––––––––––––––––––––– -->
  98. <%- partial('partial/google_analytics') %>
  99. </head>
  100. <body>
  101. <div class="container">
  102. <div class="row">
  103. <div>
  104. <%- partial('partial/header') %>
  105. <div class="trans">
  106. <%- body %>
  107. <%- partial('partial/footer') %>
  108. </div>
  109. </div>
  110. </div>
  111. </div>
  112. <script src="<%- theme.nanobar %>"></script>
  113. <script>
  114. var options = {
  115. classname: 'nanobar',
  116. id: 'myNanobar'
  117. };
  118. var nanobar = new Nanobar(options);
  119. nanobar.go(30);
  120. nanobar.go(76);
  121. nanobar.go(100);
  122. </script>
  123. </body>
  124. </html>